fix: use exported variable for input height

This commit is contained in:
Christian Andolf
2025-06-16 14:03:56 +02:00
parent 603c7dd2bf
commit c476f29512
3 changed files with 17 additions and 8 deletions

View File

@@ -1,3 +1,6 @@
@value globals: "../../styles/globals.css";
@value inputContainerHeight, inputExpandedHeight from globals;
.container {
align-content: center;
background-color: var(--Surface-Primary-Default);
@@ -5,7 +8,7 @@
border-radius: var(--Corner-radius-md);
display: grid;
min-width: 0; /* allow shrinkage */
height: 56px;
height: inputContainerHeight;
padding: 0 var(--Space-x15);
box-sizing: border-box;
cursor: text;
@@ -43,7 +46,7 @@
&:focus,
&:placeholder-shown,
&[value]:not([value='']) {
height: 24px;
height: inputExpandedHeight;
outline: none;
}
@@ -54,7 +57,7 @@
@media (hover: hover) {
.input:active:not(:disabled) {
height: 24px;
height: inputExpandedHeight;
outline: none;
}
}

View File

@@ -1,9 +1,12 @@
@value globals: "../../styles/globals.css";
@value inputContainerHeight, inputExpandedHeight from globals;
.select {
position: relative;
background-color: var(--Surface-UI-Fill-Default);
border: 1px solid var(--Border-Interactive-Default);
border-radius: var(--Corner-radius-md);
height: 56px;
height: inputContainerHeight;
box-sizing: border-box;
&[data-required] .label::after {
@@ -15,7 +18,7 @@
}
.selectedText {
min-height: 24px;
min-height: inputExpandedHeight;
}
}
&[data-focused] {
@@ -27,7 +30,7 @@
outline: none;
}
.input {
min-height: 24px;
min-height: inputExpandedHeight;
}
.label {
color: var(--Text-Interactive-Focus);
@@ -84,7 +87,7 @@
width: 100%;
&[value]:not([value='']) {
min-height: 24px;
min-height: inputExpandedHeight;
}
}
@@ -95,7 +98,7 @@
}
.selectedText:not(:empty) {
min-height: 24px;
min-height: inputExpandedHeight;
}
.displayText {

View File

@@ -1,3 +1,6 @@
@value inputContainerHeight: 56px;
@value inputExpandedHeight: 24px;
* {
margin: 0;
}