macbetter 0.0.0-stage → 0.1.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +201 -0
- package/README.md +92 -2
- package/dist/components/accessory-tile.d.ts +50 -0
- package/dist/components/accessory-tile.js +46 -0
- package/dist/components/activity-indicator.d.ts +15 -0
- package/dist/components/activity-indicator.js +15 -0
- package/dist/components/alert.d.ts +29 -0
- package/dist/components/alert.js +30 -0
- package/dist/components/artwork.d.ts +44 -0
- package/dist/components/artwork.js +935 -0
- package/dist/components/automation-row.d.ts +24 -0
- package/dist/components/automation-row.js +12 -0
- package/dist/components/avatar.d.ts +33 -0
- package/dist/components/avatar.js +45 -0
- package/dist/components/badge.d.ts +24 -0
- package/dist/components/badge.js +19 -0
- package/dist/components/button.d.ts +20 -0
- package/dist/components/button.js +10 -0
- package/dist/components/calendar.d.ts +30 -0
- package/dist/components/calendar.js +47 -0
- package/dist/components/camera-view.d.ts +40 -0
- package/dist/components/camera-view.js +44 -0
- package/dist/components/card.d.ts +14 -0
- package/dist/components/card.js +21 -0
- package/dist/components/carousel.d.ts +18 -0
- package/dist/components/carousel.js +33 -0
- package/dist/components/checkbox.d.ts +13 -0
- package/dist/components/checkbox.js +16 -0
- package/dist/components/code-field.d.ts +16 -0
- package/dist/components/code-field.js +29 -0
- package/dist/components/color-well.d.ts +23 -0
- package/dist/components/color-well.js +27 -0
- package/dist/components/combo-box.d.ts +42 -0
- package/dist/components/combo-box.js +102 -0
- package/dist/components/command-palette.d.ts +33 -0
- package/dist/components/command-palette.js +55 -0
- package/dist/components/context-menu.d.ts +9 -0
- package/dist/components/context-menu.js +15 -0
- package/dist/components/date-picker.d.ts +53 -0
- package/dist/components/date-picker.js +86 -0
- package/dist/components/device-frame.d.ts +18 -0
- package/dist/components/device-frame.js +16 -0
- package/dist/components/dialog.d.ts +27 -0
- package/dist/components/dialog.js +35 -0
- package/dist/components/disclosure.d.ts +32 -0
- package/dist/components/disclosure.js +35 -0
- package/dist/components/dock.d.ts +28 -0
- package/dist/components/dock.js +80 -0
- package/dist/components/door-control.d.ts +20 -0
- package/dist/components/door-control.js +43 -0
- package/dist/components/energy-readout.d.ts +32 -0
- package/dist/components/energy-readout.js +27 -0
- package/dist/components/field.d.ts +28 -0
- package/dist/components/field.js +32 -0
- package/dist/components/gauge.d.ts +25 -0
- package/dist/components/gauge.js +42 -0
- package/dist/components/glass.d.ts +34 -0
- package/dist/components/glass.js +31 -0
- package/dist/components/home-backdrop.d.ts +23 -0
- package/dist/components/home-backdrop.js +12 -0
- package/dist/components/home-section.d.ts +19 -0
- package/dist/components/home-section.js +21 -0
- package/dist/components/home-status.d.ts +24 -0
- package/dist/components/home-status.js +14 -0
- package/dist/components/hover-card.d.ts +14 -0
- package/dist/components/hover-card.js +16 -0
- package/dist/components/level-control.d.ts +19 -0
- package/dist/components/level-control.js +13 -0
- package/dist/components/light-color-picker.d.ts +33 -0
- package/dist/components/light-color-picker.js +56 -0
- package/dist/components/list.d.ts +42 -0
- package/dist/components/list.js +42 -0
- package/dist/components/listbox.d.ts +16 -0
- package/dist/components/listbox.js +28 -0
- package/dist/components/lock-control.d.ts +20 -0
- package/dist/components/lock-control.js +35 -0
- package/dist/components/menu-bar.d.ts +14 -0
- package/dist/components/menu-bar.js +16 -0
- package/dist/components/menu.d.ts +40 -0
- package/dist/components/menu.js +54 -0
- package/dist/components/navigation-bar.d.ts +24 -0
- package/dist/components/navigation-bar.js +54 -0
- package/dist/components/outline.d.ts +21 -0
- package/dist/components/outline.js +40 -0
- package/dist/components/page-control.d.ts +10 -0
- package/dist/components/page-control.js +8 -0
- package/dist/components/popover.d.ts +16 -0
- package/dist/components/popover.js +24 -0
- package/dist/components/progress.d.ts +27 -0
- package/dist/components/progress.js +27 -0
- package/dist/components/radio.d.ts +16 -0
- package/dist/components/radio.js +13 -0
- package/dist/components/rating.d.ts +10 -0
- package/dist/components/rating.js +12 -0
- package/dist/components/scene-tile.d.ts +22 -0
- package/dist/components/scene-tile.js +13 -0
- package/dist/components/scroll-view.d.ts +21 -0
- package/dist/components/scroll-view.js +13 -0
- package/dist/components/search-field.d.ts +16 -0
- package/dist/components/search-field.js +12 -0
- package/dist/components/secure-field.d.ts +23 -0
- package/dist/components/secure-field.js +21 -0
- package/dist/components/segmented-control.d.ts +12 -0
- package/dist/components/segmented-control.js +10 -0
- package/dist/components/select.d.ts +45 -0
- package/dist/components/select.js +79 -0
- package/dist/components/sensor-readout.d.ts +29 -0
- package/dist/components/sensor-readout.js +12 -0
- package/dist/components/separator.d.ts +14 -0
- package/dist/components/separator.js +11 -0
- package/dist/components/setup-code.d.ts +29 -0
- package/dist/components/setup-code.js +47 -0
- package/dist/components/sheet.d.ts +31 -0
- package/dist/components/sheet.js +51 -0
- package/dist/components/sidebar.d.ts +30 -0
- package/dist/components/sidebar.js +26 -0
- package/dist/components/slider.d.ts +27 -0
- package/dist/components/slider.js +43 -0
- package/dist/components/split-view.d.ts +11 -0
- package/dist/components/split-view.js +13 -0
- package/dist/components/squircle.d.ts +41 -0
- package/dist/components/squircle.js +63 -0
- package/dist/components/stepper.d.ts +30 -0
- package/dist/components/stepper.js +28 -0
- package/dist/components/switch.d.ts +10 -0
- package/dist/components/switch.js +10 -0
- package/dist/components/tab-bar.d.ts +20 -0
- package/dist/components/tab-bar.js +17 -0
- package/dist/components/table.d.ts +49 -0
- package/dist/components/table.js +179 -0
- package/dist/components/tabs.d.ts +16 -0
- package/dist/components/tabs.js +19 -0
- package/dist/components/text-area.d.ts +14 -0
- package/dist/components/text-area.js +9 -0
- package/dist/components/text-field.d.ts +26 -0
- package/dist/components/text-field.js +23 -0
- package/dist/components/thermostat-control.d.ts +30 -0
- package/dist/components/thermostat-control.js +139 -0
- package/dist/components/toast.d.ts +30 -0
- package/dist/components/toast.js +114 -0
- package/dist/components/toggle.d.ts +21 -0
- package/dist/components/toggle.js +19 -0
- package/dist/components/token-field.d.ts +31 -0
- package/dist/components/token-field.js +78 -0
- package/dist/components/toolbar.d.ts +27 -0
- package/dist/components/toolbar.js +39 -0
- package/dist/components/tooltip.d.ts +11 -0
- package/dist/components/tooltip.js +18 -0
- package/dist/components/window.d.ts +56 -0
- package/dist/components/window.js +61 -0
- package/dist/index.d.ts +78 -0
- package/dist/index.js +79 -0
- package/dist/lib/cx.d.ts +9 -0
- package/dist/lib/cx.js +14 -0
- package/dist/lib/derive.d.ts +53 -0
- package/dist/lib/derive.js +255 -0
- package/dist/lib/field-glyphs.d.ts +13 -0
- package/dist/lib/field-glyphs.js +28 -0
- package/dist/lib/menu-glyphs.d.ts +6 -0
- package/dist/lib/menu-glyphs.js +15 -0
- package/dist/lib/platform.d.ts +18 -0
- package/dist/lib/platform.js +17 -0
- package/dist/lib/squircle.d.ts +23 -0
- package/dist/lib/squircle.js +69 -0
- package/dist/lib/theme.d.ts +42 -0
- package/dist/lib/theme.js +62 -0
- package/dist/styles/base.css +115 -0
- package/dist/styles/components/accessory-tile.css +461 -0
- package/dist/styles/components/activity-indicator.css +63 -0
- package/dist/styles/components/alert.css +433 -0
- package/dist/styles/components/artwork.css +380 -0
- package/dist/styles/components/automation-row.css +52 -0
- package/dist/styles/components/avatar.css +230 -0
- package/dist/styles/components/badge.css +204 -0
- package/dist/styles/components/button.css +298 -0
- package/dist/styles/components/calendar.css +287 -0
- package/dist/styles/components/camera-view.css +239 -0
- package/dist/styles/components/card.css +100 -0
- package/dist/styles/components/carousel.css +210 -0
- package/dist/styles/components/checkbox.css +212 -0
- package/dist/styles/components/code-field.css +163 -0
- package/dist/styles/components/color-well.css +452 -0
- package/dist/styles/components/combo-box.css +222 -0
- package/dist/styles/components/command-palette.css +379 -0
- package/dist/styles/components/context-menu.css +43 -0
- package/dist/styles/components/date-picker.css +356 -0
- package/dist/styles/components/device-frame.css +194 -0
- package/dist/styles/components/dialog.css +366 -0
- package/dist/styles/components/disclosure.css +197 -0
- package/dist/styles/components/dock.css +404 -0
- package/dist/styles/components/door-control.css +187 -0
- package/dist/styles/components/energy-readout.css +161 -0
- package/dist/styles/components/field.css +175 -0
- package/dist/styles/components/gauge.css +239 -0
- package/dist/styles/components/glass.css +113 -0
- package/dist/styles/components/home-backdrop.css +81 -0
- package/dist/styles/components/home-section.css +100 -0
- package/dist/styles/components/home-status.css +215 -0
- package/dist/styles/components/hover-card.css +145 -0
- package/dist/styles/components/index.css +75 -0
- package/dist/styles/components/level-control.css +247 -0
- package/dist/styles/components/light-color-picker.css +94 -0
- package/dist/styles/components/list.css +411 -0
- package/dist/styles/components/listbox.css +168 -0
- package/dist/styles/components/lock-control.css +164 -0
- package/dist/styles/components/menu-bar.css +94 -0
- package/dist/styles/components/menu.css +454 -0
- package/dist/styles/components/navigation-bar.css +248 -0
- package/dist/styles/components/outline.css +248 -0
- package/dist/styles/components/page-control.css +127 -0
- package/dist/styles/components/popover.css +186 -0
- package/dist/styles/components/progress.css +228 -0
- package/dist/styles/components/radio.css +281 -0
- package/dist/styles/components/rating.css +122 -0
- package/dist/styles/components/scene-tile.css +295 -0
- package/dist/styles/components/scroll-view.css +195 -0
- package/dist/styles/components/search-field.css +128 -0
- package/dist/styles/components/secure-field.css +189 -0
- package/dist/styles/components/segmented-control.css +183 -0
- package/dist/styles/components/select.css +290 -0
- package/dist/styles/components/sensor-readout.css +231 -0
- package/dist/styles/components/separator.css +62 -0
- package/dist/styles/components/setup-code.css +138 -0
- package/dist/styles/components/sheet.css +345 -0
- package/dist/styles/components/sidebar.css +261 -0
- package/dist/styles/components/slider.css +208 -0
- package/dist/styles/components/split-view.css +75 -0
- package/dist/styles/components/squircle.css +44 -0
- package/dist/styles/components/stepper.css +278 -0
- package/dist/styles/components/switch.css +115 -0
- package/dist/styles/components/tab-bar.css +223 -0
- package/dist/styles/components/table.css +313 -0
- package/dist/styles/components/tabs.css +262 -0
- package/dist/styles/components/text-area.css +94 -0
- package/dist/styles/components/text-field.css +294 -0
- package/dist/styles/components/thermostat-control.css +214 -0
- package/dist/styles/components/toast.css +418 -0
- package/dist/styles/components/toggle.css +312 -0
- package/dist/styles/components/token-field.css +193 -0
- package/dist/styles/components/toolbar.css +370 -0
- package/dist/styles/components/tooltip.css +69 -0
- package/dist/styles/components/window.css +428 -0
- package/dist/styles/index.css +17 -0
- package/dist/styles/materials.css +263 -0
- package/dist/styles/platforms.css +214 -0
- package/dist/styles/themes/ember.css +24 -0
- package/dist/styles/themes/graphite.css +16 -0
- package/dist/styles/themes/nebula.css +16 -0
- package/dist/styles/themes/system.css +28 -0
- package/dist/styles/tokens.css +299 -0
- package/package.json +82 -3
|
@@ -0,0 +1,262 @@
|
|
|
1
|
+
/* Tabs — the macOS tab view: a segmented strip on the edge of a framed panel. */
|
|
2
|
+
|
|
3
|
+
:where(:root, [data-platform="macos"]) {
|
|
4
|
+
--mb-tabs-height: 24px;
|
|
5
|
+
--mb-tabs-padding: 12px;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
:where([data-platform="ios"], [data-platform="ipados"]) {
|
|
9
|
+
--mb-tabs-height: 34px;
|
|
10
|
+
--mb-tabs-padding: 14px;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.mb-tabs {
|
|
14
|
+
--mb-tabs-inset: 2px;
|
|
15
|
+
--mb-tabs-radius: var(--mb-control-radius);
|
|
16
|
+
|
|
17
|
+
display: flex;
|
|
18
|
+
flex-direction: column;
|
|
19
|
+
min-width: 0;
|
|
20
|
+
color: var(--mb-label);
|
|
21
|
+
font: var(--mb-text-body);
|
|
22
|
+
letter-spacing: var(--mb-tracking-body);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.mb-tabs-list {
|
|
26
|
+
position: relative;
|
|
27
|
+
z-index: 1;
|
|
28
|
+
isolation: isolate;
|
|
29
|
+
display: inline-flex;
|
|
30
|
+
flex: none;
|
|
31
|
+
align-self: center;
|
|
32
|
+
align-items: stretch;
|
|
33
|
+
max-width: 100%;
|
|
34
|
+
height: var(--mb-tabs-height);
|
|
35
|
+
padding: var(--mb-tabs-inset);
|
|
36
|
+
border-radius: var(--mb-tabs-radius);
|
|
37
|
+
background: var(--mb-bg-secondary);
|
|
38
|
+
box-shadow: inset 0 0 0 var(--mb-hairline) var(--mb-separator);
|
|
39
|
+
font: var(--mb-control-font);
|
|
40
|
+
user-select: none;
|
|
41
|
+
-webkit-user-select: none;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/* The strip sits on a solid backing so the panel's frame doesn't show through it. */
|
|
45
|
+
.mb-tabs-list::before {
|
|
46
|
+
content: "";
|
|
47
|
+
position: absolute;
|
|
48
|
+
z-index: -2;
|
|
49
|
+
inset: 0;
|
|
50
|
+
border-radius: inherit;
|
|
51
|
+
background: var(--mb-fill-tertiary);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.mb-tabs-indicator {
|
|
55
|
+
position: absolute;
|
|
56
|
+
z-index: -1;
|
|
57
|
+
top: var(--active-tab-top, 0);
|
|
58
|
+
left: var(--active-tab-left, 0);
|
|
59
|
+
width: var(--active-tab-width, 0);
|
|
60
|
+
height: var(--active-tab-height, 0);
|
|
61
|
+
border-radius: calc(var(--mb-tabs-radius) - var(--mb-tabs-inset));
|
|
62
|
+
background: light-dark(#ffffff, color-mix(in oklch, var(--mb-tint) 46%, var(--mb-bg)));
|
|
63
|
+
box-shadow:
|
|
64
|
+
0 0 0 var(--mb-hairline) var(--mb-separator),
|
|
65
|
+
0 1px 2px var(--mb-shadow-color),
|
|
66
|
+
0 2px 6px -2px var(--mb-shadow-color);
|
|
67
|
+
transition:
|
|
68
|
+
left var(--mb-spring-snappy-duration) var(--mb-spring-snappy),
|
|
69
|
+
top var(--mb-spring-snappy-duration) var(--mb-spring-snappy),
|
|
70
|
+
width var(--mb-spring-snappy-duration) var(--mb-spring-snappy),
|
|
71
|
+
height var(--mb-spring-snappy-duration) var(--mb-spring-snappy);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.mb-tabs-indicator[data-activation-direction="none"] {
|
|
75
|
+
transition: none;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.mb-tabs-tab {
|
|
79
|
+
position: relative;
|
|
80
|
+
display: inline-flex;
|
|
81
|
+
flex: 0 1 auto;
|
|
82
|
+
align-items: center;
|
|
83
|
+
justify-content: center;
|
|
84
|
+
gap: var(--mb-control-gap);
|
|
85
|
+
min-width: 0;
|
|
86
|
+
margin: 0;
|
|
87
|
+
padding: 0 var(--mb-tabs-padding);
|
|
88
|
+
border: 0;
|
|
89
|
+
border-radius: calc(var(--mb-tabs-radius) - var(--mb-tabs-inset));
|
|
90
|
+
background: transparent;
|
|
91
|
+
color: var(--mb-label);
|
|
92
|
+
font: inherit;
|
|
93
|
+
letter-spacing: inherit;
|
|
94
|
+
white-space: nowrap;
|
|
95
|
+
text-decoration: none;
|
|
96
|
+
cursor: default;
|
|
97
|
+
touch-action: manipulation;
|
|
98
|
+
transition: color var(--mb-duration-fast) var(--mb-ease-out), opacity var(--mb-duration-fast) var(--mb-ease-out);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.mb-tabs-tab::after {
|
|
102
|
+
content: "";
|
|
103
|
+
position: absolute;
|
|
104
|
+
inset: 50% auto auto 50%;
|
|
105
|
+
width: 100%;
|
|
106
|
+
height: max(100%, var(--mb-hit-target));
|
|
107
|
+
translate: -50% -50%;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.mb-tabs-tab-icon {
|
|
111
|
+
display: inline-flex;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.mb-tabs-tab-icon :where(svg) {
|
|
115
|
+
width: var(--mb-icon-size);
|
|
116
|
+
height: var(--mb-icon-size);
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
:where([dir="rtl"]) .mb-tabs-tab-icon[data-mirror] {
|
|
120
|
+
scale: -1 1;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.mb-tabs-tab[data-selected] {
|
|
124
|
+
font-weight: 600;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
@media (hover: hover) and (pointer: fine) {
|
|
128
|
+
.mb-tabs-tab:not([data-selected]):hover {
|
|
129
|
+
background: var(--mb-fill-quaternary);
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.mb-tabs-tab:not([data-selected]):active {
|
|
134
|
+
opacity: 0.6;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.mb-tabs-tab:focus-visible {
|
|
138
|
+
outline: var(--mb-focus-ring-width) solid var(--mb-focus-ring);
|
|
139
|
+
outline-offset: -1px;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
.mb-tabs-tab[data-disabled] {
|
|
143
|
+
opacity: 0.4;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
/* Bordered: the strip straddles the top edge of a recessed, framed box. */
|
|
147
|
+
.mb-tabs[data-variant="bordered"] > .mb-tabs-list {
|
|
148
|
+
margin-bottom: calc(var(--mb-tabs-height) / -2);
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.mb-tabs-panel {
|
|
152
|
+
min-width: 0;
|
|
153
|
+
outline: none;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.mb-tabs[data-variant="bordered"] > .mb-tabs-panel {
|
|
157
|
+
padding: calc(var(--mb-tabs-height) / 2 + var(--mb-space-6)) var(--mb-space-7) var(--mb-space-7);
|
|
158
|
+
border-radius: var(--mb-radius-md);
|
|
159
|
+
background: light-dark(rgb(0 0 0 / 0.03), rgb(255 255 255 / 0.03));
|
|
160
|
+
box-shadow: inset 0 0 0 var(--mb-hairline) var(--mb-separator-strong);
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
.mb-tabs[data-variant="plain"] > .mb-tabs-panel {
|
|
164
|
+
padding-top: var(--mb-space-6);
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
.mb-tabs-panel:focus-visible {
|
|
168
|
+
outline: var(--mb-focus-ring-width) solid var(--mb-focus-ring);
|
|
169
|
+
outline-offset: var(--mb-focus-ring-offset);
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
/* Plain: no track and no frame; a soft capsule slides behind the selected label. */
|
|
173
|
+
.mb-tabs[data-variant="plain"] > .mb-tabs-list {
|
|
174
|
+
align-self: flex-start;
|
|
175
|
+
background: transparent;
|
|
176
|
+
box-shadow: none;
|
|
177
|
+
gap: var(--mb-space-1);
|
|
178
|
+
--mb-tabs-radius: var(--mb-radius-full);
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
.mb-tabs[data-variant="plain"] > .mb-tabs-list::before {
|
|
182
|
+
content: none;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
.mb-tabs[data-variant="plain"] .mb-tabs-indicator {
|
|
186
|
+
background: var(--mb-fill);
|
|
187
|
+
box-shadow: none;
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
.mb-tabs[data-variant="plain"] .mb-tabs-tab {
|
|
191
|
+
color: var(--mb-label-secondary);
|
|
192
|
+
font-weight: 500;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
.mb-tabs[data-variant="plain"] .mb-tabs-tab[data-selected] {
|
|
196
|
+
color: var(--mb-label);
|
|
197
|
+
font-weight: 600;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
/* Vertical */
|
|
201
|
+
.mb-tabs[data-orientation="vertical"] {
|
|
202
|
+
flex-direction: row;
|
|
203
|
+
gap: var(--mb-space-6);
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
.mb-tabs-list[data-orientation="vertical"] {
|
|
207
|
+
flex-direction: column;
|
|
208
|
+
align-self: flex-start;
|
|
209
|
+
height: auto;
|
|
210
|
+
margin-bottom: 0;
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
.mb-tabs-list[data-orientation="vertical"] .mb-tabs-tab {
|
|
214
|
+
justify-content: flex-start;
|
|
215
|
+
min-height: calc(var(--mb-tabs-height) - var(--mb-tabs-inset) * 2);
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
.mb-tabs[data-orientation="vertical"] > .mb-tabs-panel {
|
|
219
|
+
flex: 1;
|
|
220
|
+
margin: 0;
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
/* Touch: a full-width segmented control above the content, as iOS and iPadOS present it. */
|
|
224
|
+
@scope ([data-platform="ios"], [data-platform="ipados"]) to (:scope [data-platform]) {
|
|
225
|
+
.mb-tabs-list[data-orientation="horizontal"] {
|
|
226
|
+
display: flex;
|
|
227
|
+
align-self: stretch;
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
.mb-tabs-list[data-orientation="horizontal"] .mb-tabs-tab {
|
|
231
|
+
flex: 1 1 0;
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
.mb-tabs[data-variant="bordered"] > .mb-tabs-list {
|
|
235
|
+
margin-bottom: var(--mb-space-6);
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
.mb-tabs[data-variant="bordered"] > .mb-tabs-panel {
|
|
239
|
+
padding: var(--mb-space-6);
|
|
240
|
+
border-radius: var(--mb-group-radius);
|
|
241
|
+
background: var(--mb-bg-grouped-secondary);
|
|
242
|
+
box-shadow: none;
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
.mb-tabs-list:has(.mb-tabs-tab[data-selected]:active) .mb-tabs-indicator {
|
|
246
|
+
scale: 0.96;
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
/* Continuous corners on the bordered panel. */
|
|
251
|
+
@supports (corner-shape: squircle) {
|
|
252
|
+
.mb-tabs[data-variant="bordered"] > .mb-tabs-panel {
|
|
253
|
+
corner-shape: var(--mb-corner-shape);
|
|
254
|
+
border-radius: calc(var(--mb-radius-md) * var(--mb-corner-factor));
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
@scope ([data-platform="ios"], [data-platform="ipados"]) to (:scope [data-platform]) {
|
|
258
|
+
.mb-tabs[data-variant="bordered"] > .mb-tabs-panel {
|
|
259
|
+
border-radius: calc(var(--mb-group-radius) * var(--mb-corner-factor));
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
/* Text Area — the text field, several lines tall, growing with what's typed. */
|
|
2
|
+
|
|
3
|
+
:where(:root, [data-platform="macos"]) {
|
|
4
|
+
--mb-text-area-pad-block: 5px;
|
|
5
|
+
--mb-text-area-line: 16px;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
:where([data-platform="ios"], [data-platform="ipados"]) {
|
|
9
|
+
--mb-text-area-pad-block: 11px;
|
|
10
|
+
--mb-text-area-line: 22px;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.mb-text-area {
|
|
14
|
+
--mb-text-area-bg: var(--mb-text-field-auto-bg);
|
|
15
|
+
--mb-text-area-edge: var(--mb-text-field-auto-edge);
|
|
16
|
+
--mb-text-area-ring: var(--mb-focus-ring);
|
|
17
|
+
|
|
18
|
+
display: block;
|
|
19
|
+
box-sizing: border-box;
|
|
20
|
+
width: 100%;
|
|
21
|
+
min-width: 0;
|
|
22
|
+
min-height: calc(var(--mb-text-area-min-rows, 3) * var(--mb-text-area-line) + var(--mb-text-area-pad-block) * 2);
|
|
23
|
+
max-height: calc(var(--mb-text-area-max-rows, 10) * var(--mb-text-area-line) + var(--mb-text-area-pad-block) * 2);
|
|
24
|
+
margin: 0;
|
|
25
|
+
padding: var(--mb-text-area-pad-block) var(--mb-text-field-padding);
|
|
26
|
+
border: 0;
|
|
27
|
+
border-radius: var(--mb-text-field-radius);
|
|
28
|
+
background: var(--mb-text-area-bg);
|
|
29
|
+
box-shadow: var(--mb-text-area-edge);
|
|
30
|
+
color: var(--mb-label);
|
|
31
|
+
font: var(--mb-text-field-font);
|
|
32
|
+
line-height: var(--mb-text-area-line);
|
|
33
|
+
letter-spacing: var(--mb-tracking-body);
|
|
34
|
+
caret-color: var(--mb-accent);
|
|
35
|
+
resize: none;
|
|
36
|
+
overflow-y: auto;
|
|
37
|
+
scrollbar-width: thin;
|
|
38
|
+
appearance: none;
|
|
39
|
+
outline: var(--mb-focus-ring-width) solid transparent;
|
|
40
|
+
outline-offset: 2px;
|
|
41
|
+
transition:
|
|
42
|
+
outline-color var(--mb-duration-fast) var(--mb-ease-out),
|
|
43
|
+
outline-offset var(--mb-duration-fast) var(--mb-ease-out);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.mb-text-area[data-variant="bordered"] {
|
|
47
|
+
--mb-text-area-bg: var(--mb-bg-field);
|
|
48
|
+
--mb-text-area-edge: inset 0 0 0 var(--mb-hairline) var(--mb-control-border),
|
|
49
|
+
inset 0 0.5px 1px light-dark(rgb(0 0 0 / 0.07), rgb(0 0 0 / 0.2));
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.mb-text-area[data-variant="filled"] {
|
|
53
|
+
--mb-text-area-bg: var(--mb-fill-tertiary);
|
|
54
|
+
--mb-text-area-edge: inset 0 0 0 0 transparent;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.mb-text-area[data-variant="plain"] {
|
|
58
|
+
--mb-text-area-bg: transparent;
|
|
59
|
+
--mb-text-area-edge: inset 0 0 0 0 transparent;
|
|
60
|
+
padding-inline: 0;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.mb-text-area::placeholder {
|
|
64
|
+
color: var(--mb-field-placeholder);
|
|
65
|
+
opacity: 1;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.mb-text-area:focus {
|
|
69
|
+
outline-color: var(--mb-text-area-ring);
|
|
70
|
+
outline-offset: 0px;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.mb-text-area:is([data-invalid], [aria-invalid="true"]) {
|
|
74
|
+
--mb-text-area-edge: inset 0 0 0 1px var(--mb-destructive);
|
|
75
|
+
--mb-text-area-ring: color-mix(in oklch, var(--mb-destructive) 80%, transparent);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.mb-text-area:is([data-disabled], :disabled) {
|
|
79
|
+
--mb-text-area-bg: var(--mb-fill-quaternary);
|
|
80
|
+
--mb-text-area-edge: inset 0 0 0 var(--mb-hairline) var(--mb-separator);
|
|
81
|
+
color: var(--mb-label-tertiary);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
@scope ([data-platform="ios"], [data-platform="ipados"]) to (:scope [data-platform]) {
|
|
85
|
+
.mb-text-area[data-variant="plain"]:focus {
|
|
86
|
+
outline-color: transparent;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
@media (prefers-contrast: more) {
|
|
91
|
+
.mb-text-area[data-variant="filled"] {
|
|
92
|
+
--mb-text-area-edge: inset 0 0 0 1px var(--mb-control-border);
|
|
93
|
+
}
|
|
94
|
+
}
|
|
@@ -0,0 +1,294 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Text Field — macOS: a white rounded rectangle with a hairline edge and the
|
|
3
|
+
* accent halo while editing. iOS: a filled gray field, or no chrome at all in a
|
|
4
|
+
* list row. The --mb-text-field-* variables are shared by every text control.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
:where(:root, [data-platform="macos"]) {
|
|
8
|
+
--mb-text-field-radius-sm: 5px;
|
|
9
|
+
--mb-text-field-radius: var(--mb-radius-sm);
|
|
10
|
+
--mb-text-field-radius-lg: var(--mb-radius-md);
|
|
11
|
+
--mb-text-field-padding-sm: 6px;
|
|
12
|
+
--mb-text-field-padding: 8px;
|
|
13
|
+
--mb-text-field-padding-lg: 10px;
|
|
14
|
+
--mb-text-field-font-sm: 400 11px/14px var(--mb-font);
|
|
15
|
+
--mb-text-field-font: 400 13px/16px var(--mb-font);
|
|
16
|
+
--mb-text-field-font-lg: 400 15px/20px var(--mb-font);
|
|
17
|
+
--mb-text-field-icon: 14px;
|
|
18
|
+
--mb-text-field-gap: 5px;
|
|
19
|
+
/* What "auto" draws: the bordered field on a Mac. */
|
|
20
|
+
--mb-text-field-auto-bg: var(--mb-bg-field);
|
|
21
|
+
--mb-text-field-auto-edge: inset 0 0 0 var(--mb-hairline) var(--mb-control-border),
|
|
22
|
+
inset 0 0.5px 1px light-dark(rgb(0 0 0 / 0.07), rgb(0 0 0 / 0.2));
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
:where([data-platform="ios"], [data-platform="ipados"]) {
|
|
26
|
+
--mb-text-field-radius-sm: var(--mb-radius-md);
|
|
27
|
+
--mb-text-field-radius: 10px;
|
|
28
|
+
--mb-text-field-radius-lg: var(--mb-radius-lg);
|
|
29
|
+
--mb-text-field-padding-sm: 10px;
|
|
30
|
+
--mb-text-field-padding: 12px;
|
|
31
|
+
--mb-text-field-padding-lg: 14px;
|
|
32
|
+
--mb-text-field-font-sm: 400 15px/20px var(--mb-font);
|
|
33
|
+
--mb-text-field-font: 400 17px/22px var(--mb-font);
|
|
34
|
+
--mb-text-field-font-lg: 400 17px/22px var(--mb-font);
|
|
35
|
+
--mb-text-field-icon: 17px;
|
|
36
|
+
--mb-text-field-gap: 6px;
|
|
37
|
+
/* …and the filled gray field on touch. */
|
|
38
|
+
--mb-text-field-auto-bg: var(--mb-fill-tertiary);
|
|
39
|
+
--mb-text-field-auto-edge: inset 0 0 0 0 transparent;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
/*
|
|
43
|
+
* --mb-placeholder (tertiary label) reads 3.7:1 on a filled field in light mode;
|
|
44
|
+
* every text control uses this darker prompt so it holds 4.5:1.
|
|
45
|
+
*/
|
|
46
|
+
:is(.mb-text-field, .mb-text-field-group, .mb-search-field, .mb-secure-field, .mb-text-area, .mb-token-field) {
|
|
47
|
+
--mb-field-placeholder: light-dark(
|
|
48
|
+
color-mix(in oklch, var(--mb-ink) 64%, transparent),
|
|
49
|
+
color-mix(in oklch, var(--mb-ink) 60%, transparent)
|
|
50
|
+
);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.mb-text-field,
|
|
54
|
+
.mb-text-field-group {
|
|
55
|
+
--mb-text-field-h: var(--mb-control-height);
|
|
56
|
+
--mb-text-field-r: var(--mb-text-field-radius);
|
|
57
|
+
--mb-text-field-pad: var(--mb-text-field-padding);
|
|
58
|
+
--mb-text-field-bg: var(--mb-text-field-auto-bg);
|
|
59
|
+
--mb-text-field-edge: var(--mb-text-field-auto-edge);
|
|
60
|
+
--mb-text-field-ring: var(--mb-focus-ring);
|
|
61
|
+
|
|
62
|
+
position: relative;
|
|
63
|
+
box-sizing: border-box;
|
|
64
|
+
min-width: 0;
|
|
65
|
+
height: var(--mb-text-field-h);
|
|
66
|
+
margin: 0;
|
|
67
|
+
padding: 0 var(--mb-text-field-pad);
|
|
68
|
+
border: 0;
|
|
69
|
+
border-radius: var(--mb-text-field-r);
|
|
70
|
+
background: var(--mb-text-field-bg);
|
|
71
|
+
box-shadow: var(--mb-text-field-edge);
|
|
72
|
+
color: var(--mb-label);
|
|
73
|
+
font: var(--mb-text-field-font);
|
|
74
|
+
letter-spacing: var(--mb-tracking-body);
|
|
75
|
+
caret-color: var(--mb-accent);
|
|
76
|
+
outline: var(--mb-focus-ring-width) solid transparent;
|
|
77
|
+
outline-offset: 2px;
|
|
78
|
+
transition:
|
|
79
|
+
outline-color var(--mb-duration-fast) var(--mb-ease-out),
|
|
80
|
+
outline-offset var(--mb-duration-fast) var(--mb-ease-out),
|
|
81
|
+
background-color var(--mb-duration-fast) var(--mb-ease-out),
|
|
82
|
+
box-shadow var(--mb-duration-fast) var(--mb-ease-out);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.mb-text-field {
|
|
86
|
+
display: block;
|
|
87
|
+
width: 100%;
|
|
88
|
+
appearance: none;
|
|
89
|
+
-webkit-appearance: none;
|
|
90
|
+
text-overflow: ellipsis;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.mb-text-field-group {
|
|
94
|
+
display: flex;
|
|
95
|
+
align-items: center;
|
|
96
|
+
gap: var(--mb-text-field-gap);
|
|
97
|
+
width: 100%;
|
|
98
|
+
cursor: text;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
:is(.mb-text-field, .mb-text-field-group)[data-size="sm"] {
|
|
102
|
+
--mb-text-field-h: var(--mb-control-height-sm);
|
|
103
|
+
--mb-text-field-r: var(--mb-text-field-radius-sm);
|
|
104
|
+
--mb-text-field-pad: var(--mb-text-field-padding-sm);
|
|
105
|
+
font: var(--mb-text-field-font-sm);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
:is(.mb-text-field, .mb-text-field-group)[data-size="lg"] {
|
|
109
|
+
--mb-text-field-h: var(--mb-control-height-lg);
|
|
110
|
+
--mb-text-field-r: var(--mb-text-field-radius-lg);
|
|
111
|
+
--mb-text-field-pad: var(--mb-text-field-padding-lg);
|
|
112
|
+
font: var(--mb-text-field-font-lg);
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
:is(.mb-text-field, .mb-text-field-group)[data-variant="bordered"] {
|
|
116
|
+
--mb-text-field-bg: var(--mb-bg-field);
|
|
117
|
+
--mb-text-field-edge: inset 0 0 0 var(--mb-hairline) var(--mb-control-border),
|
|
118
|
+
inset 0 0.5px 1px light-dark(rgb(0 0 0 / 0.07), rgb(0 0 0 / 0.2));
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
:is(.mb-text-field, .mb-text-field-group)[data-variant="filled"] {
|
|
122
|
+
--mb-text-field-bg: var(--mb-fill-tertiary);
|
|
123
|
+
--mb-text-field-edge: inset 0 0 0 0 transparent;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
:is(.mb-text-field, .mb-text-field-group)[data-variant="plain"] {
|
|
127
|
+
--mb-text-field-bg: transparent;
|
|
128
|
+
--mb-text-field-edge: inset 0 0 0 0 transparent;
|
|
129
|
+
--mb-text-field-pad: 0px;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.mb-text-field::placeholder {
|
|
133
|
+
color: var(--mb-field-placeholder);
|
|
134
|
+
opacity: 1;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
/* macOS draws the halo the moment a field starts editing, by mouse or keyboard. */
|
|
138
|
+
.mb-text-field:focus,
|
|
139
|
+
.mb-text-field-group:has(.mb-text-field:focus) {
|
|
140
|
+
outline-color: var(--mb-text-field-ring);
|
|
141
|
+
outline-offset: 0px;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
.mb-text-field-group .mb-text-field:focus {
|
|
145
|
+
outline: none;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
/* Invalid: the edge and the halo turn red, as on every Apple platform. */
|
|
149
|
+
:is(.mb-text-field, .mb-text-field-group):is([data-invalid], [aria-invalid="true"]),
|
|
150
|
+
.mb-text-field-group:has(.mb-text-field:is([data-invalid], [aria-invalid="true"])) {
|
|
151
|
+
--mb-text-field-edge: inset 0 0 0 1px var(--mb-destructive);
|
|
152
|
+
--mb-text-field-ring: color-mix(in oklch, var(--mb-destructive) 80%, transparent);
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
:is(.mb-text-field, .mb-text-field-group)[data-variant="plain"]:is([data-invalid], [aria-invalid="true"]),
|
|
156
|
+
.mb-text-field-group[data-variant="plain"]:has(.mb-text-field:is([data-invalid], [aria-invalid="true"])) {
|
|
157
|
+
--mb-text-field-edge: inset 0 0 0 0 transparent;
|
|
158
|
+
color: var(--mb-destructive-text);
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
:is(.mb-text-field, .mb-text-field-group):is([data-disabled], :disabled) {
|
|
162
|
+
color: var(--mb-label-tertiary);
|
|
163
|
+
cursor: default;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
:is(.mb-text-field, .mb-text-field-group):is([data-disabled], :disabled):not([data-variant="plain"]) {
|
|
167
|
+
--mb-text-field-bg: var(--mb-fill-quaternary);
|
|
168
|
+
--mb-text-field-edge: inset 0 0 0 var(--mb-hairline) var(--mb-separator);
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
/* Inside a group the input is only the text: the group draws the field around it. */
|
|
172
|
+
.mb-text-field-group .mb-text-field {
|
|
173
|
+
flex: 1 1 auto;
|
|
174
|
+
width: auto;
|
|
175
|
+
height: 100%;
|
|
176
|
+
padding: 0;
|
|
177
|
+
border-radius: 0;
|
|
178
|
+
background: transparent;
|
|
179
|
+
box-shadow: none;
|
|
180
|
+
color: inherit;
|
|
181
|
+
font: inherit;
|
|
182
|
+
letter-spacing: inherit;
|
|
183
|
+
outline: none;
|
|
184
|
+
transition: none;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
.mb-text-field-adornment {
|
|
188
|
+
display: inline-flex;
|
|
189
|
+
flex: none;
|
|
190
|
+
align-items: center;
|
|
191
|
+
gap: 4px;
|
|
192
|
+
color: var(--mb-label-secondary);
|
|
193
|
+
white-space: nowrap;
|
|
194
|
+
/* "https://" keeps its own direction in a right-to-left field. */
|
|
195
|
+
unicode-bidi: plaintext;
|
|
196
|
+
user-select: none;
|
|
197
|
+
-webkit-user-select: none;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
.mb-text-field-adornment :where(svg) {
|
|
201
|
+
width: var(--mb-text-field-icon);
|
|
202
|
+
height: var(--mb-text-field-icon);
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
/* The clear button is xmark.circle.fill: a tertiary glyph that grows a pointer target. */
|
|
206
|
+
.mb-text-field-clear,
|
|
207
|
+
.mb-search-field-clear {
|
|
208
|
+
position: relative;
|
|
209
|
+
display: inline-flex;
|
|
210
|
+
flex: none;
|
|
211
|
+
align-items: center;
|
|
212
|
+
justify-content: center;
|
|
213
|
+
width: var(--mb-text-field-icon);
|
|
214
|
+
height: var(--mb-text-field-icon);
|
|
215
|
+
margin: 0;
|
|
216
|
+
margin-inline-end: -2px;
|
|
217
|
+
padding: 0;
|
|
218
|
+
border: 0;
|
|
219
|
+
border-radius: 50%;
|
|
220
|
+
background: transparent;
|
|
221
|
+
color: var(--mb-label-tertiary);
|
|
222
|
+
cursor: default;
|
|
223
|
+
-webkit-tap-highlight-color: transparent;
|
|
224
|
+
transition:
|
|
225
|
+
color var(--mb-duration-fast) var(--mb-ease-out),
|
|
226
|
+
scale var(--mb-spring-snappy-duration) var(--mb-spring-snappy),
|
|
227
|
+
opacity var(--mb-duration-fast) var(--mb-ease-out);
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
@starting-style {
|
|
231
|
+
.mb-text-field-clear,
|
|
232
|
+
.mb-search-field-clear {
|
|
233
|
+
scale: 0.5;
|
|
234
|
+
opacity: 0;
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
.mb-text-field-clear::after,
|
|
239
|
+
.mb-search-field-clear::after {
|
|
240
|
+
content: "";
|
|
241
|
+
position: absolute;
|
|
242
|
+
inset: 50% auto auto 50%;
|
|
243
|
+
width: var(--mb-hit-target);
|
|
244
|
+
height: var(--mb-hit-target);
|
|
245
|
+
translate: -50% -50%;
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
.mb-text-field-clear :where(svg),
|
|
249
|
+
.mb-search-field-clear :where(svg) {
|
|
250
|
+
width: 100%;
|
|
251
|
+
height: 100%;
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
@media (hover: hover) and (pointer: fine) {
|
|
255
|
+
.mb-text-field-clear:hover,
|
|
256
|
+
.mb-search-field-clear:hover {
|
|
257
|
+
color: var(--mb-label-secondary);
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
.mb-text-field-clear:active,
|
|
262
|
+
.mb-search-field-clear:active {
|
|
263
|
+
color: var(--mb-label);
|
|
264
|
+
scale: 0.9;
|
|
265
|
+
transition-duration: 0ms;
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
.mb-text-field-clear:focus-visible,
|
|
269
|
+
.mb-search-field-clear:focus-visible {
|
|
270
|
+
outline: 2px solid var(--mb-focus-ring);
|
|
271
|
+
outline-offset: 1px;
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
/* Touch: a plain field in a list row shows its caret, not a halo. */
|
|
275
|
+
@scope ([data-platform="ios"], [data-platform="ipados"]) to (:scope [data-platform]) {
|
|
276
|
+
:is(.mb-text-field, .mb-text-field-group)[data-variant="plain"]:focus,
|
|
277
|
+
.mb-text-field-group[data-variant="plain"]:has(.mb-text-field:focus) {
|
|
278
|
+
outline-color: transparent;
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
/*
|
|
283
|
+
* A filled field is a faint fill with no edge, as on iOS. Under Increase
|
|
284
|
+
* Contrast it gains an edge that holds 3:1 against the surface.
|
|
285
|
+
*/
|
|
286
|
+
@media (prefers-contrast: more) {
|
|
287
|
+
:where([data-platform="ios"], [data-platform="ipados"]) {
|
|
288
|
+
--mb-text-field-auto-edge: inset 0 0 0 1px var(--mb-control-border);
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
:is(.mb-text-field, .mb-text-field-group)[data-variant="filled"] {
|
|
292
|
+
--mb-text-field-edge: inset 0 0 0 1px var(--mb-control-border);
|
|
293
|
+
}
|
|
294
|
+
}
|