Files
web/packages/design-system/lib/components/Label/label.module.css
Bianca Widstam 5f2e215508 Merged in fix/SW-2188-disable-fields-logged-in-user-enter-details (pull request #2595)
fix(SW-2188): disable enter details fields when logged in

* fix(SW-2188): disable enter details fields when logged in


Approved-by: Anton Gunnarsson
2025-08-05 11:54:41 +00:00

97 lines
2.5 KiB
CSS

.label {
font-family:
var(--Body-Paragraph-Font-family), var(--Body-Paragraph-Font-fallback);
font-size: var(--Body-Paragraph-Size);
font-weight: var(--Body-Paragraph-Font-weight);
letter-spacing: var(--Body-Paragraph-Letter-spacing);
text-transform: unset;
line-height: 1.5;
text-decoration: none;
transition: font-size 100ms ease;
text-align: left;
color: var(--Text-Interactive-Placeholder);
user-select: none;
}
.small {
font-family: var(--Label-Font-family), var(--Label-Font-fallback);
font-size: var(--Label-Size);
font-weight: var(--Label-Font-weight);
letter-spacing: var(--Label-Letter-spacing);
text-transform: unset;
line-height: 1.5;
text-decoration: none;
}
.discreet {
font-family:
var(--Body-Supporting-text-Font-family),
var(--Body-Supporting-text-Font-fallback);
font-size: var(--Body-Supporting-text-Size);
font-weight: var(--Body-Supporting-text-Font-weight-2);
letter-spacing: var(--Body-Supporting-text-Letter-spacing);
text-transform: unset;
line-height: 1.4;
text-decoration: none;
color: var(--Text-Default);
order: unset;
}
.required:after {
content: ' *';
}
input:focus ~ .label,
input:placeholder-shown ~ .label,
input[value]:not([value='']) ~ .label,
textarea:focus ~ .label,
textarea:placeholder-shown ~ .label,
textarea[value]:not([value='']) ~ .label,
.selected {
font-family: var(--Label-Font-family), var(--Label-Font-fallback);
font-size: var(--Label-Size);
font-weight: var(--Label-Font-weight);
letter-spacing: var(--Label-Letter-spacing);
text-transform: unset;
line-height: 1.5;
text-decoration: none;
margin-bottom: var(--Space-x025);
}
.label.disabled,
input:disabled ~ .label,
textarea:disabled ~ .label {
color: var(--Text-Interactive-Disabled);
}
@media (hover: hover) {
input:active:not(:disabled) ~ .label {
font-family: var(--Label-Font-family), var(--Label-Font-fallback);
font-size: var(--Label-Size);
font-weight: var(--Label-Font-weight);
letter-spacing: var(--Label-Letter-spacing);
text-transform: unset;
line-height: 1.5;
text-decoration: none;
margin-bottom: var(--Space-x025);
}
}
/* Legacy selector for deprecated select component */
:global(.select-container)[data-disabled] .label {
color: var(--Text-Interactive-Disabled);
}
:global(.select-button) .label {
order: unset;
}
:global(.select-container)[data-open='true'] .label:not(.discreet),
:global(.react-aria-SelectValue):has(:nth-child(2)) .label:not(.discreet) {
font-size: 12px;
}