hubl/src/styles/base/form.scss

454 lines
9.4 KiB
SCSS
Raw Normal View History

2019-05-14 15:32:42 +00:00
.content-box {
&.with-form {
2019-05-14 15:32:42 +00:00
sib-form {
padding-bottom: 2.55rem;
}
h1 {
color: $color-233-18-29;
font-weight: bold;
font-size: 2rem;
text-align: center;
}
.fieldset {
border-bottom: 1px solid $color-221-51-90;
color: $color-233-18-29;
display: flex;
flex: 1 0 100%;
font-size: 1.8rem;
font-weight: 600;
padding-bottom: 1rem;
}
2019-05-14 15:32:42 +00:00
2019-05-14 16:19:30 +00:00
p.center {
margin: 0;
2019-05-14 15:32:42 +00:00
text-align: center;
}
[name$='-text'] {
font-size: 1.5rem;
margin-bottom: 2rem;
2019-05-14 15:32:42 +00:00
}
[name^='block-'] {
margin-bottom: 2.75rem;
}
form {
2019-05-14 15:32:42 +00:00
display: flex;
flex-direction: column;
}
sib-set-default {
clear: both;
display: flex;
flex-wrap: wrap;
max-width: 100%;
sib-form-label-text {
float: left;
width: 50%;
}
}
label {
display: flex;
flex-direction: column;
2019-06-07 09:01:34 +00:00
input:not([type='file']),
2019-06-07 09:01:34 +00:00
textarea {
-webkit-tap-highlight-color: $color-244-73-62;
background-color: $color-222-57-95;
2019-06-07 09:01:34 +00:00
box-sizing: border-box;
border: 2px solid $color-222-57-95;
color: $color-233-18-29;
2019-06-07 09:01:34 +00:00
/*flex: 1 1 0; Problem on Firefox for input type date*/
line-height: 1;
min-width: 0;
2019-06-07 09:01:34 +00:00
padding: 1rem;
}
input:not([type="search"]):not([type="file"]),
2019-06-07 09:01:34 +00:00
textarea {
border: 2px solid $color-222-57-95;
&:focus,
&:active {
border-bottom: 2px solid $color-244-73-62;
}
}
textarea {
height: 100px;
}
}
input[type='submit'] {
background-color: $color-233-18-29;
border: none;
border-radius: 100em;
color: $color-0-0-100;
cursor: pointer;
font-size: 1.4rem;
font-weight: bold;
margin-left: auto;
margin-top: 3.2rem;
padding: 0.55rem 2.5rem;
text-transform: uppercase;
}
/* CLASSES Peut-être à sortir de .content-box */
.block.team-form>form { /* circle-profile */
display: flex;
flex-direction: row;
label {
>.ss-main {
font-weight: normal;
min-width: 35vw;
text-transform: none;
>.ss-single-selected {
align-items: center;
background-color: #ebeffa;
border: none;
border-radius: 0px;
display: flex;
justify-content: flex-end;
min-height: 4.2rem;
padding-left: 1.2rem;
.ss-arrow {
font-size: 1.8rem;
margin: 0 18px 0 0;
span {
border: solid $color-244-73-62;
border-width: 0 2px 2px 0;
}
}
}
}
}
>input[type='submit'] {
background-color: transparent;
border: 1px solid #6157e5;
color: #6157e5;
font-size: 1.4rem;
align-self: flex-end;
margin-bottom: 0.6rem;
margin-left: 4.2rem;
}
}
.form-container>form {
margin-top: 2.7rem;
}
.form-label {
/*flex: 1 1 auto;*/
font-weight: 600;
&.is-dark label {
color: $color-216-4-22;
margin-top: 3rem;
&>*:nth-child(2) {
margin-top: 0.8rem;
}
}
&.is-light label {
color: $color-244-10-70;
margin-top: 1.8rem;
text-transform: uppercase;
&>*:nth-child(2) {
margin-top: 0.8rem;
}
}
}
.is-full-width {
flex: 1 1 100%;
}
.is-half-width {
box-sizing: border-box;
flex: 0 0 50%;
&:nth-child(even) {
padding-left: 1.7rem;
}
&:nth-child(odd) {
padding-right: 1.7rem;
}
}
/* WIDGETS SIB */
sib-form-auto-completion.member-select {
align-self: flex-end;
font-weight: normal;
.ss-single-selected {
background-color: $color-222-57-95;
border: none;
border-radius: 0px;
display: flex;
margin-top: 0.8rem;
min-height: 3.9rem;
padding-left: 1rem;
text-transform: none;
.ss-arrow span {
border: solid $color-244-73-62;
border-width: 0 2px 2px 0;
}
}
2019-06-07 09:01:34 +00:00
.ss-content .ss-list .ss-option {
text-transform: none;
}
}
sib-form-date {
2019-06-07 09:01:34 +00:00
input[type="date"] {
background-image: url("/images/calendar.svg");
background-position: right 12px top 50%;
background-repeat: no-repeat;
2019-06-07 09:01:34 +00:00
background-size: 1.4rem;
color: $color-213-4-50;
cursor: default;
2019-06-07 09:01:34 +00:00
font-size: 1.4rem;
margin-top: 1.6rem;
max-width: 50vw;
padding-right: 3rem; /* Needed to replace the close icon in FF when you are selecting a date */
padding-top: 1.2rem; /* Needed to center the close icon in FF when you are selecting a date */
position: relative;
2019-06-07 09:01:34 +00:00
&::-webkit-calendar-picker-indicator {
cursor: pointer;
opacity: 0;
position: absolute;
right: 8px;
}
&::-webkit-clear-button {
cursor: pointer;
2019-06-07 09:01:34 +00:00
margin-bottom: 5px; /* Needed to compensate padding-top: 1.2rem; for the close icon in FF */
margin-right: 5px;
}
&::-webkit-inner-spin-button {
2019-06-07 09:01:34 +00:00
display: none;
}
}
}
sib-form-file {
label {
align-items: baseline;
clear: both;
display: flex;
flex-direction: row;
flex-wrap: wrap;
max-width: 100%;
div {
width: 100%;
}
input[type='text'] {
box-sizing: border-box;
flex: 0 0 50%;
}
input[type='file'] {
box-sizing: border-box;
flex: 0 0 20%;
color: $color-244-73-62;
cursor: pointer;
padding-left: 3rem;
}
}
}
sib-multiple-form {
margin-top: 1.8rem;
}
sib-multiple-select {
sib-form-auto-completion > label {
display: flex;
flex-direction: column;
.ss-main {
font-weight: normal;
margin-bottom: 7.8rem;
margin-top: 1.6rem;
max-width: 50vw;
text-transform: none;
.ss-multi-selected {
align-items: center;
background-color: $color-222-57-95;
border: none;
border-radius: 0px;
display: flex;
justify-content: flex-end;
min-height: 4.2rem;
padding-left: 1.2rem;
.ss-add {
font-size: 1.8rem;
2019-06-07 09:01:34 +00:00
margin: 0 18px 0 0;
span.ss-plus {
background: $color-244-73-62;
&::after {
background: $color-244-73-62;
}
}
}
.ss-values {
background: transparent;
position: absolute;
top: 6rem;
width: 100%;
.ss-disabled {
color: transparent;
font-size: 1.4rem;
left: calc(1.2rem - 5px);
position: absolute;
top: calc(-6rem + 7px);
&::before {
color: $color-213-4-50;
content: "Select skills";
font-weight: normal;
}
}
2019-06-07 09:01:34 +00:00
.ss-value {
@extend .skill;
display: flex;
.ss-value-delete {
font-weight: normal;
}
}
}
}
}
}
}
/* CUSTOM WIDGETS */
2019-05-14 15:32:42 +00:00
hd-member-form {
width: 100%;
2019-05-14 15:32:42 +00:00
form {
2019-05-14 15:32:42 +00:00
display: flex;
flex-direction: column;
2019-05-14 15:32:42 +00:00
[name='member-form__input'] {
margin-bottom: 1rem;
}
2019-05-14 15:32:42 +00:00
sib-form-auto-completion {
float: left;
2019-05-14 15:32:42 +00:00
}
input[type='submit'] {
background-color: transparent;
border: 1px solid $color-244-73-62;
color: $color-244-73-62;
2019-05-14 15:32:42 +00:00
}
}
}
[widget='hd-project-members'] {
display: flex;
flex-wrap: wrap;
width: 100%;
2019-05-14 15:32:42 +00:00
&>label {
display: none;
}
2019-05-14 15:32:42 +00:00
&>div {
align-items: center;
border: 1px solid $color-43-100-50;
border-radius: 3px;
display: flex;
margin: 0 1.5rem 1.5rem 0;
padding: 2.2rem;
.member-info>div {
display: grid;
grid-template-areas: "avatar name"
"avatar role";
grid-column-gap: 15px;
margin-right: 15px;
2019-05-14 15:32:42 +00:00
}
&>button {
cursor: pointer;
background-color: transparent;
border: 1px solid $color-43-100-50;
border-radius: 50%;
color: $color-43-100-50;
height: 22px;
width: 22px;
2019-05-14 15:32:42 +00:00
}
}
&>button {
2019-05-14 15:32:42 +00:00
display: none;
}
sib-display-img {
grid-area: avatar;
align-items: center;
background-color: #e3e8ed;
border-radius: 50%;
display: flex;
height: 45px;
justify-content: center;
overflow: hidden;
width: 45px;
img {
height: 100%;
object-fit: cover;
object-position: center;
width: 100%;
2019-05-14 15:32:42 +00:00
}
}
sib-display-value:first-of-type {
font-weight: 600;
grid-area: name;
}
sib-display-value:last-of-type {
grid-area: role;
2019-05-14 15:32:42 +00:00
}
}
}
}