@spectrum-css/textfield
Version:
The Spectrum CSS textfield component
47 lines (38 loc) • 1.97 kB
CSS
/*!
* Copyright 2024 Adobe. All rights reserved.
*
* This file is licensed to you under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. You may obtain a copy
* of the License at <http://www.apache.org/licenses/LICENSE-2.0>
*
* Unless required by applicable law or agreed to in writing, software distributed under
* the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
* OF ANY KIND, either express or implied. See the License for the specific language
* governing permissions and limitations under the License.
*/
@container style(--system: spectrum) {
.spectrum-Textfield {
--spectrum-textfield-background-color: var(--spectrum-gray-25);
--spectrum-textfield-background-color-disabled: var(--spectrum-gray-25);
--spectrum-textfield-border-color: var(--spectrum-gray-500);
--spectrum-textfield-border-color-hover: var(--spectrum-gray-600);
--spectrum-textfield-border-color-focus: var(--spectrum-gray-800);
--spectrum-textfield-border-color-focus-hover: var(--spectrum-gray-900);
--spectrum-textfield-border-color-keyboard-focus: var(--spectrum-gray-800);
--spectrum-textfield-border-color-disabled: var(--spectrum-gray-300);
--spectrum-textfield-border-width: var(--spectrum-border-width-100);
--spectrum-textfield-icon-spacing-block-invalid: var(--spectrum-component-top-to-workflow-icon-100);
&.spectrum-Textfield--sizeS {
--spectrum-textfield-icon-spacing-block-invalid: var(--spectrum-component-top-to-workflow-icon-75);
}
&.spectrum-Textfield--sizeL {
--spectrum-textfield-icon-spacing-block-invalid: var(--spectrum-component-top-to-workflow-icon-200);
}
&.spectrum-Textfield--sizeXL {
--spectrum-textfield-icon-spacing-block-invalid: var(--spectrum-component-top-to-workflow-icon-300);
}
&.spectrum-Textfield--quiet {
--spectrum-textfield-border-color-disabled: var(--spectrum-gray-300);
}
}
}