diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
commit | 26a029d407be480d791972afb5975cf62c9360a6 (patch) | |
tree | f435a8308119effd964b339f76abb83a57c29483 /toolkit/components/printing/content/toggle-group.css | |
parent | Initial commit. (diff) | |
download | firefox-26a029d407be480d791972afb5975cf62c9360a6.tar.xz firefox-26a029d407be480d791972afb5975cf62c9360a6.zip |
Adding upstream version 124.0.1.upstream/124.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | toolkit/components/printing/content/toggle-group.css | 79 |
1 files changed, 79 insertions, 0 deletions
diff --git a/toolkit/components/printing/content/toggle-group.css b/toolkit/components/printing/content/toggle-group.css new file mode 100644 index 0000000000..94922eb963 --- /dev/null +++ b/toolkit/components/printing/content/toggle-group.css @@ -0,0 +1,79 @@ +/* This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ + + +/* + * A radiogroup styled to hide the radio buttons + * and present tab-like labels as buttons + */ + +.toggle-group { + display: inline-flex; +} + +.toggle-group-label { + display: inline-flex; + align-items: center; + margin: 0; + padding: 6px 10px; + background-color: var(--in-content-button-background); +} + +.toggle-group-input { + position: absolute; + inset-inline-start: -100px; +} + +.toggle-group-label-iconic::before { + width: 16px; + height: 16px; + margin-inline-end: 5px; + -moz-context-properties: fill; + fill: currentColor; +} + +.toggle-group-label:first-of-type { + border-start-start-radius: 4px; + border-end-start-radius: 4px; +} + +.toggle-group-label:last-of-type { + border-start-end-radius: 4px; + border-end-end-radius: 4px; +} + +.toggle-group-input:disabled + .toggle-group-label { + opacity: 0.4; +} + +.toggle-group-input:enabled + .toggle-group-label:hover { + background-color: var(--in-content-button-background-hover); + color: var(--in-content-button-text-color-hover); +} + +.toggle-group-input:enabled + .toggle-group-label:hover:active { + background-color: var(--in-content-button-background-active); + color: var(--in-content-button-text-color-active); +} + +.toggle-group-input:focus-visible + .toggle-group-label { + outline: var(--in-content-focus-outline); + outline-offset: var(--in-content-focus-outline-offset); + z-index: 1; +} + +.toggle-group-input:checked + .toggle-group-label { + background-color: var(--in-content-primary-button-background); + color: var(--in-content-primary-button-text-color); +} + +.toggle-group-input:enabled:checked + .toggle-group-label:hover { + background-color: var(--in-content-primary-button-background-hover); + color: var(--in-content-primary-button-text-color-hover); +} + +.toggle-group-input:enabled:checked + .toggle-group-label:hover:active { + background-color: var(--in-content-primary-button-background-active); + color: var(--in-content-primary-button-text-color-active); +} |