3 color: var(--field-placeholder-color);
5 opacity: 1; // For Firefox -_-v
8 $field-container: rem(260) !default;
12 display: inline-block;
17 block-size: rem($default-height-fields);
18 min-block-size: rem($default-height-fields); // To ensure minimum size when overriding block-size to 'auto'
19 padding-inline: em(16);
20 padding-block: em(6); // design want 34px height (actually 35 to avoid .5px)
21 border-radius: var(--border-radius-md);
22 border: 1px solid var(--field-norm);
23 background-color: var(--field-background-color);
24 color: var(--field-text-color);
26 filter: none; // fixes Firefox autofill color
28 0.15s easing(ease-out-quint),
29 visibility 0s; // Disable visibility transition due to auto focus, e.g. login form
33 block-size: auto; // crazy chrome bug in details (share drive modal)
37 @include media('<=xsmall') {
38 padding-inline: em(8);
41 @include media('<=small') {
42 font-size: max(16px, em($base-font-size));
46 font-size: em($base-font-size);
62 border-color: var(--field-hover);
63 background-color: var(--field-hover-background-color);
64 color: var(--field-hover-text-color);
70 &[aria-expanded='true']:not([aria-controls]) {
71 border-color: var(--focus-outline);
72 box-shadow: 0 0 0 #{$focus-ring-size} var(--focus-ring);
73 background-color: var(--field-focus-background-color);
74 color: var(--field-focus-text-color);
77 @supports selector(:focus-visible) {
79 // might seem useless for inputs like text (they DO trigger focus-visible), but will be useful for "fake" select (selectV2) - also separated for old Safaris < 15.3
80 border-color: var(--focus-outline);
81 box-shadow: 0 0 0 #{$focus-ring-size} var(--focus-ring);
82 background-color: var(--field-focus-background-color);
83 color: var(--field-focus-text-color);
88 border-color: var(--field-disabled);
89 background-color: var(--field-disabled-background-color);
90 color: var(--field-disabled-text-color);
93 &[aria-invalid='true']:not(:focus),
94 &[aria-invalid='true']:not(.ng-pristine) {
95 border-color: var(--signal-danger);
98 &.is-valid:not(:focus) {
99 border-color: var(--signal-success);
111 padding-inline-start: 2em;
113 &::-webkit-search-cancel-button {
119 padding-inline-end: 0.25em;
123 padding-inline-end: rem(6);
127 outline: 0; // focus is provided by input fields
138 @extend .text-ellipsis;
143 // Fix autofill state
144 input:-webkit-autofill,
145 textarea:-webkit-autofill,
146 select:-webkit-autofill {
147 // Trick to replace the background color
148 box-shadow: 0 0 0 1000px var(--field-background-color) inset !important;
149 -webkit-text-fill-color: var(--field-text-color) !important;
150 caret-color: var(--field-text-color) !important;
153 // Fix datalist display, remove browser default caret
154 [list]::-webkit-calendar-picker-indicator {
155 display: none !important; // had to use important otherwise not working -_-v
159 background: var(--select-background-color);
160 background-size: rem(15);
161 padding-inline: 1em rem(20);
162 text-overflow: ellipsis;
171 background-color: var(--background-weak);
175 /* hotfix for Chrome */
177 text-align-last: center;
188 transform 0.15s linear,
189 max-block-size 0.15s linear;
190 transform: scaleY(1);
191 transform-origin: top center;
194 transform: scaleY(0);
198 // general rule: if focus is on the field => don't display error yet
199 .field-icon-container:focus-within + .error-zone,
200 .field:focus + .error-zone {
201 transform: scaleY(0);
205 /* sizes/other modifiers */
207 padding: em(6); // useful for address group
211 padding-block: em(2); // design want 26px height (actually 27 to avoid .5px)
212 padding-inline: em(16);
216 padding-block: em(10); // design want 42px height (actually 43 to avoid .5px)
217 padding-inline: em(16);
221 border-color: var(--primary);
225 /* field with icon */
226 .field-icon-container {
227 @extend .field; // added focus-within inside on field for this fake-field :)
233 inline-size: calc(100% - 1.5em);
238 // for drive, to keep the same height
239 min-block-size: calc(#{rem($default-height-fields)} + 2px);
244 background-color: transparent;
251 .dropdown-content .select--inline-caret-option {
255 .field-icon-container--invalid:not(:focus-within) {
256 border-color: var(--signal-danger);
259 border-color: var(--signal-danger);
264 * REMOVE THIS IF POSSIBLE
267 /* @protonmail.com field */
269 .sign-layout-container .field--username.field--username {
270 padding-inline-end: var(--padding-right-field-above, 9em);
273 /* special stupid case for signup iframe challenge... not using same styles for the moment */
274 .sign-layout-container {
276 padding-block: em(10);
277 padding-inline: em(16); // design want 42px height (actually 41 to avoid .5px)
282 * Specific for input fields
283 * TO_CHECK if removable
288 inset-block-start: 0;
289 block-size: #{rem($default-height-fields)} !important; // height of field, need to override `.icon16p`
290 align-content: center;
294 inset-inline-end: 0.5em;
298 inset-inline-end: 1em;
301 padding-block-end: rem(2);
306 inset-inline-start: 0.5em;