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,287 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Calendar — Apple's graphical date picker: a month title with chevrons, a
|
|
3
|
+
* weekday row, circular days. Today is accent text, the pick an accent circle,
|
|
4
|
+
* a range a continuous band between two circles.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
:where(:root, [data-platform="macos"]) {
|
|
8
|
+
--mb-calendar-cell-width: 32px;
|
|
9
|
+
--mb-calendar-cell-height: 30px;
|
|
10
|
+
--mb-calendar-circle: 26px;
|
|
11
|
+
--mb-calendar-day-font: 400 13px/1 var(--mb-font);
|
|
12
|
+
--mb-calendar-heading-font: 600 13px/16px var(--mb-font);
|
|
13
|
+
--mb-calendar-weekday-font: 500 11px/14px var(--mb-font);
|
|
14
|
+
--mb-calendar-weekday-color: var(--mb-label-secondary);
|
|
15
|
+
--mb-calendar-step-size: 22px;
|
|
16
|
+
--mb-calendar-step-icon: 11px;
|
|
17
|
+
--mb-calendar-step-color: var(--mb-label-secondary);
|
|
18
|
+
--mb-calendar-gap: 8px;
|
|
19
|
+
|
|
20
|
+
--mb-calendar-cell-width-sm: 26px;
|
|
21
|
+
--mb-calendar-cell-height-sm: 24px;
|
|
22
|
+
--mb-calendar-circle-sm: 21px;
|
|
23
|
+
--mb-calendar-day-font-sm: 400 12px/1 var(--mb-font);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
:where([data-platform="ios"], [data-platform="ipados"]) {
|
|
27
|
+
--mb-calendar-cell-width: 46px;
|
|
28
|
+
--mb-calendar-cell-height: 44px;
|
|
29
|
+
--mb-calendar-circle: 40px;
|
|
30
|
+
--mb-calendar-day-font: 400 20px/1 var(--mb-font);
|
|
31
|
+
--mb-calendar-heading-font: 600 17px/22px var(--mb-font);
|
|
32
|
+
--mb-calendar-weekday-font: 600 13px/18px var(--mb-font);
|
|
33
|
+
/* UIKit's tertiary label is under 4.5:1 at 13pt; secondary keeps the quiet look and passes. */
|
|
34
|
+
--mb-calendar-weekday-color: var(--mb-label-secondary);
|
|
35
|
+
--mb-calendar-step-size: 44px;
|
|
36
|
+
--mb-calendar-step-icon: 20px;
|
|
37
|
+
--mb-calendar-step-color: var(--mb-accent-text);
|
|
38
|
+
--mb-calendar-gap: 6px;
|
|
39
|
+
|
|
40
|
+
--mb-calendar-cell-width-sm: 42px;
|
|
41
|
+
--mb-calendar-cell-height-sm: 40px;
|
|
42
|
+
--mb-calendar-circle-sm: 36px;
|
|
43
|
+
--mb-calendar-day-font-sm: 400 17px/1 var(--mb-font);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.mb-calendar {
|
|
47
|
+
--mb-calendar-w: var(--mb-calendar-cell-width);
|
|
48
|
+
--mb-calendar-h: var(--mb-calendar-cell-height);
|
|
49
|
+
--mb-calendar-d: var(--mb-calendar-circle);
|
|
50
|
+
--mb-calendar-font: var(--mb-calendar-day-font);
|
|
51
|
+
--mb-calendar-band: color-mix(in oklch, var(--mb-accent) light-dark(20%, 30%), transparent);
|
|
52
|
+
|
|
53
|
+
display: inline-flex;
|
|
54
|
+
flex-direction: column;
|
|
55
|
+
gap: var(--mb-calendar-gap);
|
|
56
|
+
color: var(--mb-label);
|
|
57
|
+
font: var(--mb-text-body);
|
|
58
|
+
user-select: none;
|
|
59
|
+
-webkit-user-select: none;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.mb-calendar[data-size="sm"] {
|
|
63
|
+
--mb-calendar-w: var(--mb-calendar-cell-width-sm);
|
|
64
|
+
--mb-calendar-h: var(--mb-calendar-cell-height-sm);
|
|
65
|
+
--mb-calendar-d: var(--mb-calendar-circle-sm);
|
|
66
|
+
--mb-calendar-font: var(--mb-calendar-day-font-sm);
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.mb-calendar[data-disabled] {
|
|
70
|
+
opacity: 0.45;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.mb-calendar-header {
|
|
74
|
+
display: flex;
|
|
75
|
+
align-items: center;
|
|
76
|
+
justify-content: space-between;
|
|
77
|
+
gap: 8px;
|
|
78
|
+
min-height: var(--mb-calendar-step-size);
|
|
79
|
+
padding-inline-start: calc((var(--mb-calendar-w) - var(--mb-calendar-d)) / 2 + 2px);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.mb-calendar-heading {
|
|
83
|
+
margin: 0;
|
|
84
|
+
color: var(--mb-label);
|
|
85
|
+
font: var(--mb-calendar-heading-font);
|
|
86
|
+
letter-spacing: var(--mb-tracking-body);
|
|
87
|
+
font-variant-numeric: tabular-nums;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.mb-calendar-nav {
|
|
91
|
+
display: flex;
|
|
92
|
+
align-items: center;
|
|
93
|
+
gap: 2px;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.mb-calendar-step {
|
|
97
|
+
position: relative;
|
|
98
|
+
display: inline-flex;
|
|
99
|
+
align-items: center;
|
|
100
|
+
justify-content: center;
|
|
101
|
+
width: var(--mb-calendar-step-size);
|
|
102
|
+
height: var(--mb-calendar-step-size);
|
|
103
|
+
margin: 0;
|
|
104
|
+
padding: 0;
|
|
105
|
+
border: 0;
|
|
106
|
+
border-radius: var(--mb-radius-sm);
|
|
107
|
+
background: transparent;
|
|
108
|
+
color: var(--mb-calendar-step-color);
|
|
109
|
+
cursor: default;
|
|
110
|
+
-webkit-tap-highlight-color: transparent;
|
|
111
|
+
transition:
|
|
112
|
+
background-color var(--mb-duration-fast) var(--mb-ease-out),
|
|
113
|
+
opacity var(--mb-duration-fast) var(--mb-ease-out);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.mb-calendar-chevron {
|
|
117
|
+
width: var(--mb-calendar-step-icon);
|
|
118
|
+
height: var(--mb-calendar-step-icon);
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
.mb-calendar-step::after {
|
|
122
|
+
content: "";
|
|
123
|
+
position: absolute;
|
|
124
|
+
inset: 50% auto auto 50%;
|
|
125
|
+
width: max(100%, var(--mb-hit-target));
|
|
126
|
+
height: max(100%, var(--mb-hit-target));
|
|
127
|
+
translate: -50% -50%;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
:where([dir="rtl"]) .mb-calendar-chevron {
|
|
131
|
+
scale: -1 1;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
@media (hover: hover) and (pointer: fine) {
|
|
135
|
+
.mb-calendar-step:hover {
|
|
136
|
+
background: var(--mb-fill-tertiary);
|
|
137
|
+
color: var(--mb-label);
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.mb-calendar-step:active {
|
|
142
|
+
background: var(--mb-fill-secondary);
|
|
143
|
+
transition-duration: 0ms;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
.mb-calendar-step[data-disabled] {
|
|
147
|
+
opacity: 0.3;
|
|
148
|
+
pointer-events: none;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
@scope ([data-platform="ios"], [data-platform="ipados"]) to (:scope [data-platform]) {
|
|
152
|
+
.mb-calendar-step:active {
|
|
153
|
+
background: transparent;
|
|
154
|
+
opacity: 0.4;
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
.mb-calendar-months {
|
|
159
|
+
display: flex;
|
|
160
|
+
flex-wrap: wrap;
|
|
161
|
+
gap: 20px;
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
.mb-calendar-grid {
|
|
165
|
+
border-collapse: collapse;
|
|
166
|
+
border-spacing: 0;
|
|
167
|
+
table-layout: fixed;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.mb-calendar-weekday {
|
|
171
|
+
width: var(--mb-calendar-w);
|
|
172
|
+
height: calc(var(--mb-calendar-h) * 0.7);
|
|
173
|
+
padding: 0;
|
|
174
|
+
color: var(--mb-calendar-weekday-color);
|
|
175
|
+
font: var(--mb-calendar-weekday-font);
|
|
176
|
+
letter-spacing: var(--mb-tracking-caption);
|
|
177
|
+
text-align: center;
|
|
178
|
+
text-transform: uppercase;
|
|
179
|
+
vertical-align: middle;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
.mb-calendar-day {
|
|
183
|
+
position: relative;
|
|
184
|
+
z-index: 0;
|
|
185
|
+
width: var(--mb-calendar-w);
|
|
186
|
+
height: var(--mb-calendar-h);
|
|
187
|
+
padding: 0;
|
|
188
|
+
text-align: center;
|
|
189
|
+
vertical-align: middle;
|
|
190
|
+
color: var(--mb-label);
|
|
191
|
+
cursor: default;
|
|
192
|
+
outline: none;
|
|
193
|
+
-webkit-tap-highlight-color: transparent;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
.mb-calendar-day-label {
|
|
197
|
+
display: inline-grid;
|
|
198
|
+
place-items: center;
|
|
199
|
+
width: var(--mb-calendar-d);
|
|
200
|
+
height: var(--mb-calendar-d);
|
|
201
|
+
border-radius: 50%;
|
|
202
|
+
font: var(--mb-calendar-font);
|
|
203
|
+
font-variant-numeric: tabular-nums;
|
|
204
|
+
transition:
|
|
205
|
+
background-color var(--mb-duration-fast) var(--mb-ease-out),
|
|
206
|
+
color var(--mb-duration-fast) var(--mb-ease-out),
|
|
207
|
+
scale var(--mb-spring-snappy-duration) var(--mb-spring-snappy);
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
@media (hover: hover) and (pointer: fine) {
|
|
211
|
+
.mb-calendar-day:not([data-disabled], [data-selected]):hover .mb-calendar-day-label {
|
|
212
|
+
background: var(--mb-fill-tertiary);
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
.mb-calendar-day:not([data-disabled]):active .mb-calendar-day-label {
|
|
217
|
+
scale: 0.9;
|
|
218
|
+
transition-duration: 0ms, 0ms, var(--mb-duration-instant);
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
.mb-calendar-day[data-today] .mb-calendar-day-label {
|
|
222
|
+
color: var(--mb-accent-text);
|
|
223
|
+
font-weight: 600;
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
.mb-calendar-day[data-outside] {
|
|
227
|
+
color: var(--mb-label-quaternary);
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
.mb-calendar-day[data-disabled] {
|
|
231
|
+
color: var(--mb-label-quaternary);
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
.mb-calendar-day[data-unavailable] {
|
|
235
|
+
color: var(--mb-label-quaternary);
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
/* The pick: a filled accent circle. A range's ends are picks too; its middle is the band. */
|
|
239
|
+
.mb-calendar-day[data-selected]:not([data-range-middle]) .mb-calendar-day-label,
|
|
240
|
+
.mb-calendar-day:is([data-range-start], [data-range-end]) .mb-calendar-day-label {
|
|
241
|
+
background: var(--mb-accent);
|
|
242
|
+
color: var(--mb-on-accent);
|
|
243
|
+
font-weight: 600;
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
.mb-calendar-day:is([data-range-start], [data-range-middle], [data-range-end])::before {
|
|
247
|
+
content: "";
|
|
248
|
+
position: absolute;
|
|
249
|
+
z-index: -1;
|
|
250
|
+
inset-block: calc((var(--mb-calendar-h) - var(--mb-calendar-d)) / 2);
|
|
251
|
+
inset-inline: 0;
|
|
252
|
+
background: var(--mb-calendar-band);
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
.mb-calendar-day[data-preview]:is([data-range-start], [data-range-middle], [data-range-end])::before {
|
|
256
|
+
background: color-mix(in oklch, var(--mb-accent) light-dark(11%, 16%), transparent);
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
.mb-calendar-day[data-range-start]::before {
|
|
260
|
+
inset-inline-start: 50%;
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
.mb-calendar-day[data-range-end]::before {
|
|
264
|
+
inset-inline-end: 50%;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
.mb-calendar-day[data-range-start][data-range-end]::before {
|
|
268
|
+
display: none;
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
/* The band rounds off where a week wraps. */
|
|
272
|
+
.mb-calendar-day[data-range-middle]:first-child::before {
|
|
273
|
+
inset-inline-start: calc((var(--mb-calendar-w) - var(--mb-calendar-d)) / 2);
|
|
274
|
+
border-start-start-radius: var(--mb-radius-full);
|
|
275
|
+
border-end-start-radius: var(--mb-radius-full);
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
.mb-calendar-day[data-range-middle]:last-child::before {
|
|
279
|
+
inset-inline-end: calc((var(--mb-calendar-w) - var(--mb-calendar-d)) / 2);
|
|
280
|
+
border-start-end-radius: var(--mb-radius-full);
|
|
281
|
+
border-end-end-radius: var(--mb-radius-full);
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
.mb-calendar-day:focus-visible .mb-calendar-day-label {
|
|
285
|
+
outline: var(--mb-focus-ring-width) solid var(--mb-focus-ring);
|
|
286
|
+
outline-offset: 1px;
|
|
287
|
+
}
|
|
@@ -0,0 +1,239 @@
|
|
|
1
|
+
/* Camera view — a camera's picture with its name and state in the corners. Without a picture it shows an
|
|
2
|
+
abstract placeholder (Artwork's lens variant), never a drawn place. The HIG says not to block camera images,
|
|
3
|
+
so the badges stay small and at the edges, and the controls sit on a soft scrim along the bottom. */
|
|
4
|
+
|
|
5
|
+
:where(:root, [data-platform="macos"]) {
|
|
6
|
+
--mb-camera-view-radius: 12px;
|
|
7
|
+
--mb-camera-view-inset: 8px;
|
|
8
|
+
--mb-camera-view-name-font: 600 12px/15px var(--mb-font);
|
|
9
|
+
--mb-camera-view-badge-font: 600 11px/14px var(--mb-font);
|
|
10
|
+
--mb-camera-tile-width: 220px;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
:where([data-platform="ios"], [data-platform="ipados"]) {
|
|
14
|
+
--mb-camera-view-radius: 18px;
|
|
15
|
+
--mb-camera-view-inset: 10px;
|
|
16
|
+
--mb-camera-view-name-font: 600 14px/18px var(--mb-font);
|
|
17
|
+
--mb-camera-view-badge-font: 600 12px/15px var(--mb-font);
|
|
18
|
+
--mb-camera-tile-width: 260px;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.mb-camera-view {
|
|
22
|
+
/* Text over the picture is white on a dark scrim in either color scheme, as it is over video in Apple's apps. */
|
|
23
|
+
--mb-camera-view-scrim: rgb(0 0 0 / 0.5);
|
|
24
|
+
|
|
25
|
+
position: relative;
|
|
26
|
+
display: block;
|
|
27
|
+
box-sizing: border-box;
|
|
28
|
+
width: 100%;
|
|
29
|
+
aspect-ratio: 16 / 9;
|
|
30
|
+
margin: 0;
|
|
31
|
+
overflow: hidden;
|
|
32
|
+
border-radius: var(--mb-camera-view-radius);
|
|
33
|
+
background: rgb(0 0 0);
|
|
34
|
+
color: white;
|
|
35
|
+
isolation: isolate;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.mb-camera-view-frame {
|
|
39
|
+
position: absolute;
|
|
40
|
+
inset: 0;
|
|
41
|
+
display: block;
|
|
42
|
+
transition: filter var(--mb-duration-slow) var(--mb-ease-out);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.mb-camera-view-frame > :where(svg, img, video, canvas) {
|
|
46
|
+
display: block;
|
|
47
|
+
width: 100%;
|
|
48
|
+
height: 100%;
|
|
49
|
+
object-fit: cover;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.mb-camera-view[data-state="offline"] .mb-camera-view-frame {
|
|
53
|
+
filter: grayscale(1) brightness(0.35) blur(6px);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.mb-camera-view[data-state="connecting"] .mb-camera-view-frame {
|
|
57
|
+
filter: brightness(0.7);
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/* The placeholder, or any Artwork you pass, fills the frame whatever its aspect. */
|
|
61
|
+
.mb-camera-view-frame > .mb-artwork {
|
|
62
|
+
position: absolute;
|
|
63
|
+
inset: 0;
|
|
64
|
+
inline-size: 100%;
|
|
65
|
+
block-size: 100%;
|
|
66
|
+
aspect-ratio: auto;
|
|
67
|
+
border-radius: 0;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.mb-camera-view-frame > .mb-artwork::after {
|
|
71
|
+
display: none;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
/* Name and room, top leading, on a gradient that fades into the picture. */
|
|
75
|
+
.mb-camera-view-caption {
|
|
76
|
+
position: absolute;
|
|
77
|
+
z-index: 1;
|
|
78
|
+
inset-block-start: 0;
|
|
79
|
+
inset-inline: 0;
|
|
80
|
+
display: flex;
|
|
81
|
+
align-items: baseline;
|
|
82
|
+
gap: 6px;
|
|
83
|
+
padding: var(--mb-camera-view-inset) calc(var(--mb-camera-view-inset) + 70px) 18px var(--mb-camera-view-inset);
|
|
84
|
+
background: linear-gradient(to bottom, rgb(0 0 0 / 0.5), rgb(0 0 0 / 0));
|
|
85
|
+
pointer-events: none;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
:where([dir="rtl"]) .mb-camera-view-caption {
|
|
89
|
+
padding-inline: var(--mb-camera-view-inset) calc(var(--mb-camera-view-inset) + 70px);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.mb-camera-view-name,
|
|
93
|
+
.mb-camera-view-room {
|
|
94
|
+
overflow: hidden;
|
|
95
|
+
font: var(--mb-camera-view-name-font);
|
|
96
|
+
letter-spacing: var(--mb-tracking-caption);
|
|
97
|
+
white-space: nowrap;
|
|
98
|
+
text-overflow: ellipsis;
|
|
99
|
+
text-shadow: 0 1px 2px rgb(0 0 0 / 0.4);
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.mb-camera-view-room {
|
|
103
|
+
flex: none;
|
|
104
|
+
font-weight: 400;
|
|
105
|
+
opacity: 0.85;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
/* Live, or the time of the still, top trailing. */
|
|
109
|
+
.mb-camera-view-badges {
|
|
110
|
+
position: absolute;
|
|
111
|
+
z-index: 1;
|
|
112
|
+
inset-block-start: var(--mb-camera-view-inset);
|
|
113
|
+
inset-inline-end: var(--mb-camera-view-inset);
|
|
114
|
+
display: flex;
|
|
115
|
+
align-items: center;
|
|
116
|
+
gap: 6px;
|
|
117
|
+
pointer-events: none;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.mb-camera-view-time,
|
|
121
|
+
.mb-camera-view-live {
|
|
122
|
+
display: inline-flex;
|
|
123
|
+
align-items: center;
|
|
124
|
+
gap: 4px;
|
|
125
|
+
padding: 2px 7px;
|
|
126
|
+
border-radius: var(--mb-radius-full);
|
|
127
|
+
background: var(--mb-camera-view-scrim);
|
|
128
|
+
font: var(--mb-camera-view-badge-font);
|
|
129
|
+
letter-spacing: var(--mb-tracking-caption);
|
|
130
|
+
font-variant-numeric: tabular-nums;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.mb-camera-view-live {
|
|
134
|
+
text-transform: uppercase;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
/* The dot is red, and the word says Live: the state never rests on the color. */
|
|
138
|
+
.mb-camera-view-live-dot {
|
|
139
|
+
display: block;
|
|
140
|
+
width: 6px;
|
|
141
|
+
height: 6px;
|
|
142
|
+
border-radius: 50%;
|
|
143
|
+
background: oklch(from var(--mb-red) 0.66 0.22 h);
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
.mb-camera-view-spinner {
|
|
147
|
+
color: white;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.mb-camera-view-offline {
|
|
151
|
+
position: absolute;
|
|
152
|
+
z-index: 1;
|
|
153
|
+
inset: 0;
|
|
154
|
+
display: grid;
|
|
155
|
+
place-items: center;
|
|
156
|
+
padding: 12px;
|
|
157
|
+
font: var(--mb-camera-view-name-font);
|
|
158
|
+
letter-spacing: var(--mb-tracking-caption);
|
|
159
|
+
text-align: center;
|
|
160
|
+
opacity: 0.9;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
.mb-camera-view-controls {
|
|
164
|
+
position: absolute;
|
|
165
|
+
z-index: 1;
|
|
166
|
+
inset-block-end: 0;
|
|
167
|
+
inset-inline: 0;
|
|
168
|
+
display: flex;
|
|
169
|
+
align-items: center;
|
|
170
|
+
justify-content: center;
|
|
171
|
+
gap: 12px;
|
|
172
|
+
padding: 24px var(--mb-camera-view-inset) var(--mb-camera-view-inset);
|
|
173
|
+
background: linear-gradient(to top, rgb(0 0 0 / 0.45), rgb(0 0 0 / 0));
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
/* As a tile in the Cameras row. */
|
|
177
|
+
.mb-camera-tile {
|
|
178
|
+
flex: none;
|
|
179
|
+
width: var(--mb-camera-tile-width);
|
|
180
|
+
padding: 0;
|
|
181
|
+
border: 0;
|
|
182
|
+
font: inherit;
|
|
183
|
+
text-align: start;
|
|
184
|
+
cursor: default;
|
|
185
|
+
-webkit-tap-highlight-color: transparent;
|
|
186
|
+
transition: scale var(--mb-spring-snappy-duration) var(--mb-spring-snappy);
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
.mb-camera-tile:focus-visible {
|
|
190
|
+
outline: var(--mb-focus-ring-width) solid var(--mb-focus-ring);
|
|
191
|
+
outline-offset: 2px;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
@media (hover: hover) and (pointer: fine) {
|
|
195
|
+
.mb-camera-tile:hover .mb-camera-view-frame {
|
|
196
|
+
filter: brightness(1.08);
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
@scope ([data-platform="ios"], [data-platform="ipados"]) to (:scope [data-platform]) {
|
|
201
|
+
.mb-camera-tile:active {
|
|
202
|
+
scale: 0.97;
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
@supports (corner-shape: squircle) {
|
|
207
|
+
.mb-camera-view {
|
|
208
|
+
corner-shape: var(--mb-corner-shape);
|
|
209
|
+
border-radius: calc(var(--mb-camera-view-radius) * var(--mb-corner-factor));
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
@media (prefers-reduced-transparency: reduce) {
|
|
214
|
+
:where(:root:not([data-transparency="full"])) {
|
|
215
|
+
.mb-camera-view-time,
|
|
216
|
+
.mb-camera-view-live {
|
|
217
|
+
background: rgb(0 0 0 / 0.78);
|
|
218
|
+
-webkit-backdrop-filter: none;
|
|
219
|
+
backdrop-filter: none;
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
@media (prefers-contrast: more) {
|
|
225
|
+
.mb-camera-view-time,
|
|
226
|
+
.mb-camera-view-live {
|
|
227
|
+
background: rgb(0 0 0 / 0.85);
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
.mb-camera-view-caption {
|
|
231
|
+
background: linear-gradient(to bottom, rgb(0 0 0 / 0.75), rgb(0 0 0 / 0));
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
@media (forced-colors: active) {
|
|
236
|
+
.mb-camera-view {
|
|
237
|
+
border: 1px solid CanvasText;
|
|
238
|
+
}
|
|
239
|
+
}
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
/* Card — a content container: a macOS group box, or an iOS grouped cell or widget. */
|
|
2
|
+
|
|
3
|
+
:where(:root, [data-platform="macos"]) {
|
|
4
|
+
--mb-card-padding: 16px;
|
|
5
|
+
--mb-card-gap: 12px;
|
|
6
|
+
--mb-card-radius: var(--mb-radius-lg);
|
|
7
|
+
--mb-card-title-font: 600 13px/16px var(--mb-font);
|
|
8
|
+
--mb-card-description-font: 400 12px/15px var(--mb-font);
|
|
9
|
+
--mb-card-grouped-bg: var(--mb-fill-quaternary);
|
|
10
|
+
--mb-card-grouped-edge: var(--mb-separator);
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
:where([data-platform="ios"], [data-platform="ipados"]) {
|
|
14
|
+
--mb-card-padding: 16px;
|
|
15
|
+
--mb-card-gap: 14px;
|
|
16
|
+
--mb-card-radius: var(--mb-group-radius);
|
|
17
|
+
--mb-card-title-font: 600 17px/22px var(--mb-font);
|
|
18
|
+
--mb-card-description-font: 400 15px/20px var(--mb-font);
|
|
19
|
+
--mb-card-grouped-bg: var(--mb-bg-grouped-secondary);
|
|
20
|
+
--mb-card-grouped-edge: transparent;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.mb-card {
|
|
24
|
+
--mb-card-bg: var(--mb-card-grouped-bg);
|
|
25
|
+
|
|
26
|
+
position: relative;
|
|
27
|
+
box-sizing: border-box;
|
|
28
|
+
display: flex;
|
|
29
|
+
flex-direction: column;
|
|
30
|
+
gap: var(--mb-card-gap);
|
|
31
|
+
min-width: 0;
|
|
32
|
+
padding: var(--mb-card-padding);
|
|
33
|
+
border-radius: var(--mb-card-radius);
|
|
34
|
+
background: var(--mb-card-bg);
|
|
35
|
+
color: var(--mb-label);
|
|
36
|
+
box-shadow: inset 0 0 0 var(--mb-hairline) var(--mb-card-grouped-edge);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
/* Apple's corners are continuous: the curve eases into the straight edge. */
|
|
40
|
+
@supports (corner-shape: squircle) {
|
|
41
|
+
.mb-card {
|
|
42
|
+
corner-shape: var(--mb-corner-shape);
|
|
43
|
+
border-radius: calc(var(--mb-card-radius) * var(--mb-corner-factor));
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.mb-card[data-variant="elevated"] {
|
|
48
|
+
--mb-card-bg: var(--mb-bg-elevated);
|
|
49
|
+
box-shadow:
|
|
50
|
+
0 0 0 var(--mb-hairline) var(--mb-glass-border),
|
|
51
|
+
var(--mb-shadow-2);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.mb-card[data-variant="material"] {
|
|
55
|
+
--mb-card-bg: var(--mb-material-regular);
|
|
56
|
+
-webkit-backdrop-filter: var(--mb-material-filter);
|
|
57
|
+
backdrop-filter: var(--mb-material-filter);
|
|
58
|
+
box-shadow: var(--mb-glass-rim), 0 0 0 var(--mb-hairline) var(--mb-glass-border), var(--mb-shadow-2);
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.mb-card[data-variant="outline"] {
|
|
62
|
+
--mb-card-bg: transparent;
|
|
63
|
+
box-shadow: inset 0 0 0 1px var(--mb-separator-strong);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.mb-card-header {
|
|
67
|
+
display: flex;
|
|
68
|
+
flex-direction: column;
|
|
69
|
+
gap: 2px;
|
|
70
|
+
min-width: 0;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.mb-card-title {
|
|
74
|
+
margin: 0;
|
|
75
|
+
color: var(--mb-label);
|
|
76
|
+
font: var(--mb-card-title-font);
|
|
77
|
+
letter-spacing: var(--mb-tracking-body);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.mb-card-description {
|
|
81
|
+
margin: 0;
|
|
82
|
+
color: var(--mb-label-secondary);
|
|
83
|
+
font: var(--mb-card-description-font);
|
|
84
|
+
letter-spacing: var(--mb-tracking-caption);
|
|
85
|
+
text-wrap: pretty;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.mb-card-content {
|
|
89
|
+
min-width: 0;
|
|
90
|
+
font: var(--mb-text-body);
|
|
91
|
+
letter-spacing: var(--mb-tracking-body);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.mb-card-footer {
|
|
95
|
+
display: flex;
|
|
96
|
+
flex-wrap: wrap;
|
|
97
|
+
align-items: center;
|
|
98
|
+
justify-content: flex-end;
|
|
99
|
+
gap: var(--mb-space-4);
|
|
100
|
+
}
|