mirror of
https://github.com/shoelace-style/webawesome.git
synced 2026-01-12 12:09:26 +00:00
Use 100% width for text field and select labels (#599)
This commit is contained in:
@@ -5,11 +5,30 @@ label {
|
||||
font-weight: var(--wa-form-control-label-font-weight);
|
||||
line-height: var(--wa-form-control-label-line-height);
|
||||
position: relative;
|
||||
}
|
||||
|
||||
label + :is(input:not([type='checkbox'], [type='radio']), textarea, select),
|
||||
label > :is(input:not([type='checkbox'], [type='radio']), textarea, select) {
|
||||
margin-block-start: var(--wa-space-xs);
|
||||
&:has(
|
||||
input:not(
|
||||
[type='button'],
|
||||
[type='checkbox'],
|
||||
[type='color'],
|
||||
[type='file'],
|
||||
[type='hidden'],
|
||||
[type='image'],
|
||||
[type='radio'],
|
||||
[type='range'],
|
||||
[type='reset'],
|
||||
[type='submit']
|
||||
),
|
||||
textarea,
|
||||
select
|
||||
) {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
& + :is(input:not([type='checkbox'], [type='radio']), textarea, select),
|
||||
& > :is(input:not([type='checkbox'], [type='radio']), textarea, select) {
|
||||
margin-block-start: var(--wa-space-xs);
|
||||
}
|
||||
}
|
||||
|
||||
/* Fieldsets */
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/* Label */
|
||||
:is([part~='form-control-label'], [part~='label']):has(*:not(:empty)) {
|
||||
display: block;
|
||||
display: inline-block;
|
||||
color: var(--wa-form-control-label-color);
|
||||
font-weight: var(--wa-form-control-label-font-weight);
|
||||
line-height: var(--wa-form-control-label-line-height);
|
||||
|
||||
Reference in New Issue
Block a user