diff --git a/core/api.txt b/core/api.txt index eab32d73ae..506dc9ba38 100644 --- a/core/api.txt +++ b/core/api.txt @@ -596,6 +596,7 @@ ion-input,css-prop,--color ion-input,css-prop,--highlight-color-focused ion-input,css-prop,--highlight-color-invalid ion-input,css-prop,--highlight-color-valid +ion-input,css-prop,--highlight-height ion-input,css-prop,--padding-bottom ion-input,css-prop,--padding-end ion-input,css-prop,--padding-start @@ -1291,6 +1292,7 @@ ion-select,css-prop,--border-width ion-select,css-prop,--highlight-color-focused ion-select,css-prop,--highlight-color-invalid ion-select,css-prop,--highlight-color-valid +ion-select,css-prop,--highlight-height ion-select,css-prop,--padding-bottom ion-select,css-prop,--padding-end ion-select,css-prop,--padding-start @@ -1424,6 +1426,7 @@ ion-textarea,css-prop,--color ion-textarea,css-prop,--highlight-color-focused ion-textarea,css-prop,--highlight-color-invalid ion-textarea,css-prop,--highlight-color-valid +ion-textarea,css-prop,--highlight-height ion-textarea,css-prop,--padding-bottom ion-textarea,css-prop,--padding-end ion-textarea,css-prop,--padding-start diff --git a/core/src/components/input/input.ios.scss b/core/src/components/input/input.ios.scss index 4f06328db0..d17929f701 100644 --- a/core/src/components/input/input.ios.scss +++ b/core/src/components/input/input.ios.scss @@ -4,6 +4,7 @@ :host { --border-width: #{$hairlines-width}; --border-color: #{$item-ios-border-color}; + --highlight-height: 0px; font-size: $input-ios-font-size; } diff --git a/core/src/components/input/input.md.outline.scss b/core/src/components/input/input.md.outline.scss index ea202b74ab..be54121d0e 100644 --- a/core/src/components/input/input.md.outline.scss +++ b/core/src/components/input/input.md.outline.scss @@ -43,7 +43,7 @@ * the input is focused. */ :host(.input-fill-outline.has-focus) { - --border-width: 2px; + --border-width: var(--highlight-height); --border-color: var(--highlight-color); } diff --git a/core/src/components/input/input.md.scss b/core/src/components/input/input.md.scss index f11e356259..f00e98db39 100644 --- a/core/src/components/input/input.md.scss +++ b/core/src/components/input/input.md.scss @@ -10,6 +10,7 @@ :host { --border-width: 1px; --border-color: #{$item-md-border-color}; + --highlight-height: 2px; font-size: $input-md-font-size; } @@ -73,7 +74,7 @@ position: absolute; width: 100%; - height: 2px; + height: var(--highlight-height); transform: scale(0); diff --git a/core/src/components/input/input.scss b/core/src/components/input/input.scss index 06877434e1..b8a9cabf2d 100644 --- a/core/src/components/input/input.scss +++ b/core/src/components/input/input.scss @@ -19,6 +19,7 @@ * @prop --placeholder-font-weight: Font weight of the input placeholder text * @prop --placeholder-opacity: Opacity of the input placeholder text * + * @prop --highlight-height: The height of the highlight on the input. Only applies to md mode. * @prop --highlight-color-focused: The color of the highlight on the input when focused * @prop --highlight-color-valid: The color of the highlight on the input when valid * @prop --highlight-color-invalid: The color of the highlight on the input when invalid diff --git a/core/src/components/input/test/highlight/index.html b/core/src/components/input/test/highlight/index.html index b69c4d5743..e5c72ec240 100644 --- a/core/src/components/input/test/highlight/index.html +++ b/core/src/components/input/test/highlight/index.html @@ -33,6 +33,13 @@ padding: 0; } } + + .custom { + --highlight-color-focused: purple; + --highlight-color-invalid: purple; + --highlight-color-valid: purple; + --highlight-height: 6px; + } @@ -174,6 +181,49 @@ +