@celestia-island/hikari 0.43.10 → 0.43.13
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/package.json +1 -1
- package/src/components/HkAboutModal.scss +12 -1
- package/src/components/HkAdaptiveDialog.scss +2 -2
- package/src/components/HkAffixPicker.scss +55 -27
- package/src/components/HkAlert.scss +35 -31
- package/src/components/HkAltSignIn.scss +10 -4
- package/src/components/HkAuthMethodList.scss +5 -5
- package/src/components/HkAuthSubmitButton.scss +3 -3
- package/src/components/HkAvatar.scss +10 -49
- package/src/components/HkBadge.scss +6 -9
- package/src/components/HkBlockingToast.scss +27 -10
- package/src/components/HkBoard.scss +26 -6
- package/src/components/HkBreadcrumb.scss +82 -268
- package/src/components/HkButton.scss +26 -3
- package/src/components/HkCaptchaWidget.scss +2 -3
- package/src/components/HkCard.scss +14 -8
- package/src/components/HkCheckbox.scss +11 -9
- package/src/components/HkColorPicker.scss +22 -8
- package/src/components/HkContextRing.scss +8 -4
- package/src/components/HkCookieConsent.scss +12 -3
- package/src/components/HkDatePicker.scss +49 -65
- package/src/components/HkDateTimePicker.scss +48 -31
- package/src/components/HkDivider.scss +14 -15
- package/src/components/HkDraggableGrid.scss +41 -11
- package/src/components/HkDraggableList.scss +22 -11
- package/src/components/HkDrawer.scss +24 -4
- package/src/components/HkEmptyState.scss +10 -11
- package/src/components/HkErrorLanding.scss +5 -5
- package/src/components/HkExpansionPanel.scss +6 -2
- package/src/components/HkFab.scss +29 -12
- package/src/components/HkFileBrowserDialog.scss +21 -10
- package/src/components/HkFileField.scss +20 -9
- package/src/components/HkFilePickerField.scss +12 -6
- package/src/components/HkGaugeRing.scss +8 -0
- package/src/components/HkHoverRevealAction.scss +30 -12
- package/src/components/HkIcon.scss +0 -18
- package/src/components/HkIconButton.scss +29 -62
- package/src/components/HkIconButtonVars.scss +8 -28
- package/src/components/HkImageLightbox.scss +4 -3
- package/src/components/HkImagePreview.scss +17 -9
- package/src/components/HkImageViewer.scss +8 -0
- package/src/components/HkInput.scss +28 -28
- package/src/components/HkJsonTree.scss +13 -9
- package/src/components/HkKeywordSearchModal.scss +40 -29
- package/src/components/HkLabel.scss +8 -3
- package/src/components/HkListTransition.scss +16 -1
- package/src/components/HkLoadMore.scss +11 -2
- package/src/components/HkLocalizedInput.scss +11 -11
- package/src/components/HkLogWindow.scss +22 -4
- package/src/components/HkLogo.scss +12 -3
- package/src/components/HkMarkdownRenderer.scss +19 -13
- package/src/components/HkMediaControlBar.scss +2 -4
- package/src/components/HkMediaSlider.scss +0 -2
- package/src/components/HkMenu.scss +32 -20
- package/src/components/HkMenuIdentityItem.scss +3 -3
- package/src/components/HkMinimap.scss +23 -8
- package/src/components/HkModal.scss +17 -20
- package/src/components/HkModalBreadcrumb.scss +25 -6
- package/src/components/HkModelTag.scss +23 -13
- package/src/components/HkNavItem.scss +27 -14
- package/src/components/HkNumberInput.scss +25 -21
- package/src/components/HkPageHeader.scss +7 -6
- package/src/components/HkPasswordInput.scss +36 -36
- package/src/components/HkPhaseTransition.scss +16 -0
- package/src/components/HkPhoneInput.scss +10 -5
- package/src/components/HkPickerPane.scss +32 -5
- package/src/components/HkPlaceholderMarquee.scss +7 -2
- package/src/components/HkPlaceholderMarquee.test.ts +27 -0
- package/src/components/HkPlaceholderMarquee.tsx +14 -6
- package/src/components/HkPopover.scss +18 -10
- package/src/components/HkPopupSelect.scss +28 -7
- package/src/components/HkProgressBar.scss +29 -7
- package/src/components/HkProgressDialog.scss +4 -2
- package/src/components/HkProgressRing.scss +7 -14
- package/src/components/HkProtocolModal.scss +0 -3
- package/src/components/HkQrCode.scss +2 -2
- package/src/components/HkRadio.scss +15 -6
- package/src/components/HkRichInput.scss +29 -13
- package/src/components/HkRollingNumber.scss +14 -6
- package/src/components/HkScrollContainer.scss +20 -8
- package/src/components/HkSearchInput.scss +12 -10
- package/src/components/HkSecretRevealModal.scss +11 -1
- package/src/components/HkSelect.scss +35 -17
- package/src/components/HkSelectionGrid.scss +41 -20
- package/src/components/HkSelectionWaterfall.scss +21 -9
- package/src/components/HkShareBar.scss +14 -5
- package/src/components/HkSidebar.scss +23 -9
- package/src/components/HkSkeleton.scss +16 -8
- package/src/components/HkSlider.scss +12 -2
- package/src/components/HkSpinner.scss +15 -9
- package/src/components/HkSplash.scss +10 -10
- package/src/components/HkStatCard.scss +7 -3
- package/src/components/HkStatusPill.scss +4 -7
- package/src/components/HkStepFlow.scss +24 -4
- package/src/components/HkSwitch.scss +41 -9
- package/src/components/HkTable.scss +25 -20
- package/src/components/HkTabs.scss +40 -26
- package/src/components/HkTag.scss +35 -29
- package/src/components/HkTagInput.scss +22 -16
- package/src/components/HkTextarea.scss +8 -6
- package/src/components/HkThemeToggle.scss +28 -18
- package/src/components/HkTimeline.scss +46 -29
- package/src/components/HkTimeline.test.tsx +39 -0
- package/src/components/HkTimeline.tsx +16 -2
- package/src/components/HkTitleBar.scss +16 -7
- package/src/components/HkToast.scss +40 -10
- package/src/components/HkTokenUsagePanel.scss +11 -6
- package/src/components/HkToolBlock.scss +23 -11
- package/src/components/HkTooltip.scss +5 -9
- package/src/components/HkTree.scss +26 -35
- package/src/components/HkVoiceInputPopup.scss +11 -6
- package/src/components/HkWindowedItem.scss +3 -9
- package/src/components/HkZoomToolbar.scss +12 -10
- package/src/components/_menu-item.scss +4 -3
- package/src/components/window-close.scss +8 -13
- package/src/composables/layoutGeometry.test.ts +177 -0
- package/src/composables/layoutGeometry.ts +231 -0
- package/src/composables/useOverlayScrollbar.test.ts +32 -0
- package/src/composables/useOverlayScrollbar.ts +9 -1
- package/src/composables/usePointerReorder.test.ts +5 -2
- package/src/composables/usePointerReorder.ts +83 -147
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
z-index: var(--hk-fab-z, 40);
|
|
8
8
|
display: flex;
|
|
9
9
|
align-items: center;
|
|
10
|
-
gap: 0.5rem;
|
|
10
|
+
gap: var(--space-8, 0.5rem);
|
|
11
11
|
pointer-events: none;
|
|
12
12
|
|
|
13
13
|
&[data-positioning="fixed"] { position: fixed; }
|
|
@@ -15,15 +15,15 @@
|
|
|
15
15
|
// Layout axis follows the expansion direction (DOM order [actions, main]).
|
|
16
16
|
&[data-expand="up"] { flex-direction: column; }
|
|
17
17
|
&[data-expand="down"] { flex-direction: column-reverse; }
|
|
18
|
-
&[data-expand="left"] { flex-direction: row; }
|
|
18
|
+
&[data-expand="left"] { flex-direction: row; } // row = initial value
|
|
19
19
|
&[data-expand="right"] { flex-direction: row-reverse; }
|
|
20
20
|
|
|
21
21
|
// Base insets: safe-area aware, extended by --hk-fab-offset-*.
|
|
22
|
-
--_hk-fab-x: max(0.875rem, env(safe-area-inset-left, 0px));
|
|
23
|
-
--_hk-fab-y: max(0.875rem, env(safe-area-inset-bottom, 0px));
|
|
22
|
+
--_hk-fab-x: max(var(--space-14, 0.875rem), env(safe-area-inset-left, 0px));
|
|
23
|
+
--_hk-fab-y: max(var(--space-14, 0.875rem), env(safe-area-inset-bottom, 0px));
|
|
24
24
|
|
|
25
25
|
&[data-corner$="-right"] {
|
|
26
|
-
--_hk-fab-x: max(0.875rem, env(safe-area-inset-right, 0px));
|
|
26
|
+
--_hk-fab-x: max(var(--space-14, 0.875rem), env(safe-area-inset-right, 0px));
|
|
27
27
|
right: calc(var(--_hk-fab-x) + var(--hk-fab-offset-x, 0px));
|
|
28
28
|
}
|
|
29
29
|
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
&[data-corner^="top"] {
|
|
35
|
-
--_hk-fab-y: max(0.875rem, env(safe-area-inset-top, 0px));
|
|
35
|
+
--_hk-fab-y: max(var(--space-14, 0.875rem), env(safe-area-inset-top, 0px));
|
|
36
36
|
top: calc(var(--_hk-fab-y) + var(--hk-fab-offset-y, 0px));
|
|
37
37
|
}
|
|
38
38
|
|
|
@@ -87,7 +87,7 @@ $sizes: (sm: 34px, md: 42px, lg: 50px);
|
|
|
87
87
|
color: var(--hi-color-text-secondary, #555);
|
|
88
88
|
background: color-mix(in srgb, var(--hi-color-surface, #fff) 78%, transparent);
|
|
89
89
|
border: 1px solid color-mix(in srgb, var(--hi-color-border, rgba(0, 0, 0, 0.12)) 25%, transparent);
|
|
90
|
-
backdrop-filter: blur(4px); // chip language shared with autotag pills
|
|
90
|
+
backdrop-filter: blur(var(--blur-xs, 4px)); // chip language shared with autotag pills
|
|
91
91
|
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.14);
|
|
92
92
|
|
|
93
93
|
&:hover:not(:disabled) { background: color-mix(in srgb, var(--hi-color-surface, #fff) 92%, transparent); }
|
|
@@ -120,12 +120,12 @@ $sizes: (sm: 34px, md: 42px, lg: 50px);
|
|
|
120
120
|
display: inline-flex;
|
|
121
121
|
align-items: center;
|
|
122
122
|
justify-content: center;
|
|
123
|
-
gap: 0.375rem;
|
|
123
|
+
gap: var(--space-6, 0.375rem);
|
|
124
124
|
appearance: none;
|
|
125
125
|
-webkit-appearance: none;
|
|
126
|
-
padding: 0 0.5rem;
|
|
127
|
-
min-width: 2rem;
|
|
128
|
-
height: 2rem;
|
|
126
|
+
padding: 0 var(--space-8, 0.5rem);
|
|
127
|
+
min-width: var(--space-32, 2rem);
|
|
128
|
+
height: var(--space-32, 2rem);
|
|
129
129
|
font-size: 0.6875rem;
|
|
130
130
|
letter-spacing: 0.02em;
|
|
131
131
|
white-space: nowrap;
|
|
@@ -134,7 +134,7 @@ $sizes: (sm: 34px, md: 42px, lg: 50px);
|
|
|
134
134
|
border: 1px solid color-mix(in srgb, var(--hi-color-border, rgba(0, 0, 0, 0.12)) 25%, transparent);
|
|
135
135
|
border-radius: var(--hi-radius-full, 9999px);
|
|
136
136
|
cursor: pointer;
|
|
137
|
-
backdrop-filter: blur(4px);
|
|
137
|
+
backdrop-filter: blur(var(--blur-xs, 4px));
|
|
138
138
|
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
|
|
139
139
|
opacity: 0;
|
|
140
140
|
transform: scale(0.4);
|
|
@@ -148,6 +148,8 @@ $sizes: (sm: 34px, md: 42px, lg: 50px);
|
|
|
148
148
|
|
|
149
149
|
&:focus-visible { outline: 2px solid var(--hi-color-primary, #7aa2f7); outline-offset: 1px; }
|
|
150
150
|
&:disabled { opacity: 0.35; cursor: not-allowed; }
|
|
151
|
+
// 82%→94% mirrors the main glass hover ladder (78%→92%).
|
|
152
|
+
&:hover:not(:disabled) { background: color-mix(in srgb, var(--hi-color-surface, #fff) 94%, transparent); }
|
|
151
153
|
}
|
|
152
154
|
|
|
153
155
|
// Staggered reveal while expanded (CSS only, via nth-child delay).
|
|
@@ -156,7 +158,22 @@ $sizes: (sm: 34px, md: 42px, lg: 50px);
|
|
|
156
158
|
opacity: 1;
|
|
157
159
|
transform: scale(1);
|
|
158
160
|
|
|
161
|
+
// Press feedback lives inside the expanded rule on purpose: at equal
|
|
162
|
+
// specificity a base-level :active would lose to scale(1) above.
|
|
163
|
+
&:active:not(:disabled) { transform: scale(0.94); }
|
|
164
|
+
|
|
159
165
|
@for $i from 1 through 6 {
|
|
160
166
|
&:nth-child(#{$i}) { transition-delay: #{($i - 1) * 30}ms; }
|
|
161
167
|
}
|
|
162
168
|
}
|
|
169
|
+
|
|
170
|
+
@media (prefers-reduced-motion: reduce) {
|
|
171
|
+
.hk-fab-button,
|
|
172
|
+
.hk-fab-mini {
|
|
173
|
+
transition: none;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.hk-fab[data-expanded="true"] .hk-fab-mini {
|
|
177
|
+
transition-delay: 0s;
|
|
178
|
+
}
|
|
179
|
+
}
|
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
/* "/" separators between segments (the root crumb renders its own). */
|
|
73
73
|
& + .hk-file-browser-crumb::before {
|
|
74
74
|
content: "/";
|
|
75
|
-
margin-
|
|
75
|
+
margin-inline-end: var(--space-4);
|
|
76
76
|
color: color-mix(in srgb, rgb(var(--color-muted)) 60%, transparent);
|
|
77
77
|
}
|
|
78
78
|
|
|
@@ -229,7 +229,7 @@
|
|
|
229
229
|
display: flex;
|
|
230
230
|
align-items: center;
|
|
231
231
|
gap: var(--space-8);
|
|
232
|
-
margin-
|
|
232
|
+
margin-inline-start: auto;
|
|
233
233
|
}
|
|
234
234
|
|
|
235
235
|
/* Compact type-filter select (HkSelect trigger inside). */
|
|
@@ -261,7 +261,7 @@
|
|
|
261
261
|
color var(--duration-normal) var(--ease-standard);
|
|
262
262
|
|
|
263
263
|
& + .hk-file-browser-layout-btn {
|
|
264
|
-
border-
|
|
264
|
+
border-inline-start: 1px solid var(--border-subtle);
|
|
265
265
|
}
|
|
266
266
|
|
|
267
267
|
&:hover:not([data-active]) {
|
|
@@ -382,7 +382,7 @@
|
|
|
382
382
|
gap: var(--space-8);
|
|
383
383
|
align-items: center;
|
|
384
384
|
padding: var(--space-6) var(--space-12);
|
|
385
|
-
text-align:
|
|
385
|
+
text-align: start;
|
|
386
386
|
}
|
|
387
387
|
|
|
388
388
|
.hk-file-browser-list-head {
|
|
@@ -416,9 +416,12 @@
|
|
|
416
416
|
background: var(--c-primary-subtle);
|
|
417
417
|
}
|
|
418
418
|
|
|
419
|
+
// Keyboard focus is drawn INSIDE the border box (HkSelectionGrid model):
|
|
420
|
+
// rows scroll beneath the sticky list head (position: sticky + opaque
|
|
421
|
+
// surface bg), which shaves the top edge of an outer spread ring.
|
|
419
422
|
&:focus-visible {
|
|
420
|
-
|
|
421
|
-
outline:
|
|
423
|
+
outline: 2px solid rgb(var(--color-primary));
|
|
424
|
+
outline-offset: -2px;
|
|
422
425
|
}
|
|
423
426
|
|
|
424
427
|
&[data-selected] {
|
|
@@ -431,6 +434,12 @@
|
|
|
431
434
|
}
|
|
432
435
|
}
|
|
433
436
|
|
|
437
|
+
/* RTL mirrors the physical-left selection bar (house pattern:
|
|
438
|
+
* HkDraggableGrid.scss flips its inset insertion markers the same way). */
|
|
439
|
+
[dir="rtl"] .hk-file-browser-row[data-selected] {
|
|
440
|
+
box-shadow: inset -2px 0 0 rgb(var(--color-primary));
|
|
441
|
+
}
|
|
442
|
+
|
|
434
443
|
.hk-file-browser-col-name {
|
|
435
444
|
overflow: hidden;
|
|
436
445
|
white-space: nowrap;
|
|
@@ -442,7 +451,7 @@
|
|
|
442
451
|
overflow: hidden;
|
|
443
452
|
white-space: nowrap;
|
|
444
453
|
text-overflow: ellipsis;
|
|
445
|
-
text-align:
|
|
454
|
+
text-align: end;
|
|
446
455
|
font-size: var(--text-xs);
|
|
447
456
|
color: rgb(var(--color-muted));
|
|
448
457
|
}
|
|
@@ -466,7 +475,7 @@
|
|
|
466
475
|
border-radius: var(--radius-md);
|
|
467
476
|
background: transparent;
|
|
468
477
|
font-family: inherit;
|
|
469
|
-
text-align:
|
|
478
|
+
text-align: start;
|
|
470
479
|
cursor: pointer;
|
|
471
480
|
transition:
|
|
472
481
|
background-color var(--duration-normal) var(--ease-standard),
|
|
@@ -476,9 +485,11 @@
|
|
|
476
485
|
border-color: var(--c-primary-medium);
|
|
477
486
|
}
|
|
478
487
|
|
|
488
|
+
// Same inside-the-border-box focus ring as the list rows: grid tiles
|
|
489
|
+
// also scroll beneath the sticky list head in the modal scroller.
|
|
479
490
|
&:focus-visible {
|
|
480
|
-
|
|
481
|
-
outline:
|
|
491
|
+
outline: 2px solid rgb(var(--color-primary));
|
|
492
|
+
outline-offset: -2px;
|
|
482
493
|
}
|
|
483
494
|
|
|
484
495
|
&[data-selected] {
|
|
@@ -12,8 +12,8 @@
|
|
|
12
12
|
}
|
|
13
13
|
|
|
14
14
|
.hk-file-field-required {
|
|
15
|
-
margin-
|
|
16
|
-
color: var(--hi-color-danger);
|
|
15
|
+
margin-inline-start: var(--space-4);
|
|
16
|
+
color: var(--hi-color-danger, #f85149);
|
|
17
17
|
}
|
|
18
18
|
|
|
19
19
|
.hk-file-box {
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
&[data-error] {
|
|
37
|
-
border-color: var(--hi-color-danger);
|
|
37
|
+
border-color: var(--hi-color-danger, #f85149);
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
&[data-disabled] {
|
|
@@ -54,13 +54,24 @@
|
|
|
54
54
|
border: 0;
|
|
55
55
|
color: rgb(var(--color-text));
|
|
56
56
|
font: inherit;
|
|
57
|
-
text-align:
|
|
57
|
+
text-align: start;
|
|
58
58
|
cursor: pointer;
|
|
59
|
+
transition: background-color var(--duration-normal) var(--ease-standard);
|
|
60
|
+
|
|
61
|
+
/* Pressable primary affordance (real <button> in the tsx) — the house
|
|
62
|
+
* quiet-trigger hover/active wash (cf. HkSelect option rows). */
|
|
63
|
+
&:hover:not(:disabled) {
|
|
64
|
+
background: var(--c-primary-subtle, rgb(var(--color-primary) / 8%));
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
&:active:not(:disabled) {
|
|
68
|
+
background: var(--c-primary-dim, rgb(var(--color-primary) / 10%));
|
|
69
|
+
}
|
|
59
70
|
|
|
60
71
|
&:focus-visible {
|
|
61
|
-
outline: 2px solid var(--hi-color-primary);
|
|
72
|
+
outline: 2px solid var(--hi-color-primary, #58a6ff);
|
|
62
73
|
outline-offset: 2px;
|
|
63
|
-
border-radius: var(--radius-xs);
|
|
74
|
+
border-radius: var(--radius-xs, 2px);
|
|
64
75
|
}
|
|
65
76
|
|
|
66
77
|
&:disabled {
|
|
@@ -96,7 +107,7 @@
|
|
|
96
107
|
padding: 0;
|
|
97
108
|
background: transparent;
|
|
98
109
|
border: 0;
|
|
99
|
-
border-radius: var(--radius-xs);
|
|
110
|
+
border-radius: var(--radius-xs, 2px);
|
|
100
111
|
color: rgb(var(--color-text) / 55%);
|
|
101
112
|
cursor: pointer;
|
|
102
113
|
|
|
@@ -106,7 +117,7 @@
|
|
|
106
117
|
}
|
|
107
118
|
|
|
108
119
|
&:focus-visible {
|
|
109
|
-
outline: 2px solid var(--hi-color-primary);
|
|
120
|
+
outline: 2px solid var(--hi-color-primary, #58a6ff);
|
|
110
121
|
outline-offset: 1px;
|
|
111
122
|
}
|
|
112
123
|
}
|
|
@@ -132,5 +143,5 @@
|
|
|
132
143
|
}
|
|
133
144
|
|
|
134
145
|
.hk-file-field-error {
|
|
135
|
-
color: var(--hi-color-danger);
|
|
146
|
+
color: var(--hi-color-danger, #f85149);
|
|
136
147
|
}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
@use "./hikari-vars" as vars;
|
|
2
|
+
|
|
1
3
|
.hk-file-picker-field {
|
|
2
4
|
display: block;
|
|
3
5
|
}
|
|
@@ -26,10 +28,14 @@
|
|
|
26
28
|
|
|
27
29
|
&:focus-within {
|
|
28
30
|
border-color: color-mix(in srgb, rgb(var(--color-text)) 38%, transparent);
|
|
31
|
+
/* Visible keyboard focus ring on the text input (which sets
|
|
32
|
+
* outline: none) — sibling pattern: the inline-rename input pairs
|
|
33
|
+
* border shift + var(--shadow-focus). */
|
|
34
|
+
box-shadow: var(--shadow-focus);
|
|
29
35
|
}
|
|
30
36
|
|
|
31
37
|
&[data-error] {
|
|
32
|
-
border-color: var(--hi-color-danger);
|
|
38
|
+
border-color: var(--hi-color-danger, #f85149);
|
|
33
39
|
}
|
|
34
40
|
|
|
35
41
|
&[data-disabled] {
|
|
@@ -47,9 +53,9 @@
|
|
|
47
53
|
justify-content: center;
|
|
48
54
|
width: 1.75rem;
|
|
49
55
|
height: 1.75rem;
|
|
50
|
-
border-radius: var(--radius-xs);
|
|
51
|
-
background: color-mix(in srgb, var(--hi-color-primary) 14%, transparent);
|
|
52
|
-
color: var(--hi-color-primary);
|
|
56
|
+
border-radius: var(--radius-xs, 2px);
|
|
57
|
+
background: color-mix(in srgb, var(--hi-color-primary, #58a6ff) 14%, transparent);
|
|
58
|
+
color: var(--hi-color-primary, #58a6ff);
|
|
53
59
|
pointer-events: none;
|
|
54
60
|
}
|
|
55
61
|
|
|
@@ -70,7 +76,7 @@
|
|
|
70
76
|
|
|
71
77
|
/* Paths are code — mono by default, opt out with :mono="false". */
|
|
72
78
|
.hk-file-picker-box[data-mono] & {
|
|
73
|
-
font-family: var(--font-mono,
|
|
79
|
+
font-family: var(--font-mono, vars.$hikari-font-family-mono);
|
|
74
80
|
}
|
|
75
81
|
|
|
76
82
|
&:disabled {
|
|
@@ -88,6 +94,6 @@
|
|
|
88
94
|
color: rgb(var(--color-text) / 60%);
|
|
89
95
|
|
|
90
96
|
&[data-error] {
|
|
91
|
-
color: var(--hi-color-danger);
|
|
97
|
+
color: var(--hi-color-danger, #f85149);
|
|
92
98
|
}
|
|
93
99
|
}
|
|
@@ -2,3 +2,11 @@
|
|
|
2
2
|
position: relative;
|
|
3
3
|
display: inline-flex;
|
|
4
4
|
}
|
|
5
|
+
|
|
6
|
+
// The 0.8s dash sweep rides an INLINE transition on the progress circles
|
|
7
|
+
// (HkGaugeRing.tsx), so the guard needs !important to beat it.
|
|
8
|
+
@media (prefers-reduced-motion: reduce) {
|
|
9
|
+
.hk-gauge-ring circle {
|
|
10
|
+
transition: none !important;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
@@ -27,14 +27,28 @@
|
|
|
27
27
|
transform 0.15s cubic-bezier(0.16, 1, 0.3, 1);
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
+
/* Revealed state, shared by the tsx-managed hover/touch reveal
|
|
31
|
+
(.is-revealed) and keyboard focus anywhere in the wrapper
|
|
32
|
+
(:focus-within) — without the focus path the extension's real
|
|
33
|
+
buttons stay tab-reachable yet invisible (HkTabs renders its
|
|
34
|
+
add actions there). */
|
|
35
|
+
.hk-hover-reveal.is-revealed > .hk-hover-reveal-extension,
|
|
36
|
+
.hk-hover-reveal:focus-within > .hk-hover-reveal-extension {
|
|
37
|
+
opacity: 1;
|
|
38
|
+
pointer-events: auto;
|
|
39
|
+
}
|
|
40
|
+
|
|
30
41
|
.hk-hover-reveal[data-placement="right"] > .hk-hover-reveal-extension {
|
|
42
|
+
/* Anchors stay PHYSICAL on purpose: placement is a physical prop
|
|
43
|
+
(consumers pass literal left/right) and the slide transforms below
|
|
44
|
+
are physical too — logical axes here would mirror the box in RTL
|
|
45
|
+
while the motion still slides the old way. */
|
|
31
46
|
left: 100%;
|
|
32
47
|
top: 50%;
|
|
33
48
|
transform: translate(-4px, -50%);
|
|
34
49
|
}
|
|
35
|
-
.hk-hover-reveal[data-placement="right"].is-revealed > .hk-hover-reveal-extension
|
|
36
|
-
|
|
37
|
-
pointer-events: auto;
|
|
50
|
+
.hk-hover-reveal[data-placement="right"].is-revealed > .hk-hover-reveal-extension,
|
|
51
|
+
.hk-hover-reveal[data-placement="right"]:focus-within > .hk-hover-reveal-extension {
|
|
38
52
|
transform: translate(4px, -50%);
|
|
39
53
|
}
|
|
40
54
|
|
|
@@ -43,9 +57,8 @@
|
|
|
43
57
|
top: 50%;
|
|
44
58
|
transform: translate(4px, -50%);
|
|
45
59
|
}
|
|
46
|
-
.hk-hover-reveal[data-placement="left"].is-revealed > .hk-hover-reveal-extension
|
|
47
|
-
|
|
48
|
-
pointer-events: auto;
|
|
60
|
+
.hk-hover-reveal[data-placement="left"].is-revealed > .hk-hover-reveal-extension,
|
|
61
|
+
.hk-hover-reveal[data-placement="left"]:focus-within > .hk-hover-reveal-extension {
|
|
49
62
|
transform: translate(-4px, -50%);
|
|
50
63
|
}
|
|
51
64
|
|
|
@@ -54,9 +67,8 @@
|
|
|
54
67
|
top: 100%;
|
|
55
68
|
transform: translate(-50%, -4px);
|
|
56
69
|
}
|
|
57
|
-
.hk-hover-reveal[data-placement="bottom"].is-revealed > .hk-hover-reveal-extension
|
|
58
|
-
|
|
59
|
-
pointer-events: auto;
|
|
70
|
+
.hk-hover-reveal[data-placement="bottom"].is-revealed > .hk-hover-reveal-extension,
|
|
71
|
+
.hk-hover-reveal[data-placement="bottom"]:focus-within > .hk-hover-reveal-extension {
|
|
60
72
|
transform: translate(-50%, 4px);
|
|
61
73
|
}
|
|
62
74
|
|
|
@@ -65,8 +77,14 @@
|
|
|
65
77
|
bottom: 100%;
|
|
66
78
|
transform: translate(-50%, 4px);
|
|
67
79
|
}
|
|
68
|
-
.hk-hover-reveal[data-placement="top"].is-revealed > .hk-hover-reveal-extension
|
|
69
|
-
|
|
70
|
-
pointer-events: auto;
|
|
80
|
+
.hk-hover-reveal[data-placement="top"].is-revealed > .hk-hover-reveal-extension,
|
|
81
|
+
.hk-hover-reveal[data-placement="top"]:focus-within > .hk-hover-reveal-extension {
|
|
71
82
|
transform: translate(-50%, -4px);
|
|
72
83
|
}
|
|
84
|
+
|
|
85
|
+
/* Reduced motion: keep the opacity fade, drop the transform slide. */
|
|
86
|
+
@media (prefers-reduced-motion: reduce) {
|
|
87
|
+
.hk-hover-reveal-extension {
|
|
88
|
+
transition: opacity 0.15s ease;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
@@ -118,21 +118,3 @@
|
|
|
118
118
|
.hk-icon-muted {
|
|
119
119
|
color: var(--hi-color-text-secondary);
|
|
120
120
|
}
|
|
121
|
-
|
|
122
|
-
// ------
|
|
123
|
-
// Transitions
|
|
124
|
-
// ------
|
|
125
|
-
|
|
126
|
-
.hk-icon-transition {
|
|
127
|
-
transition: color 150ms ease-in-out;
|
|
128
|
-
|
|
129
|
-
svg path,
|
|
130
|
-
svg circle,
|
|
131
|
-
svg rect,
|
|
132
|
-
svg ellipse,
|
|
133
|
-
svg polygon,
|
|
134
|
-
svg polyline,
|
|
135
|
-
svg line {
|
|
136
|
-
transition: fill 150ms ease-in-out, stroke 150ms ease-in-out;
|
|
137
|
-
}
|
|
138
|
-
}
|
|
@@ -6,14 +6,15 @@
|
|
|
6
6
|
// Hikari IconButton Component - FUI Styling
|
|
7
7
|
// Three-layer CSS variable system:
|
|
8
8
|
// - Layer1: Foundation variables (foundation.scss)
|
|
9
|
-
// - Layer2: Component variables (
|
|
9
|
+
// - Layer2: Component variables (HkIconButtonVars.scss)
|
|
10
10
|
// - Custom: Runtime overrides via AnimationBuilder
|
|
11
11
|
//
|
|
12
|
-
// NOTE:
|
|
12
|
+
// NOTE: This sheet now carries baseline hover/press feedback via the
|
|
13
|
+
// --hi-icon-button-* active vars; hosts can out-rank it (see below).
|
|
13
14
|
// ------
|
|
14
15
|
|
|
15
16
|
.hk-icon-button {
|
|
16
|
-
// Layer2 variables are defined in
|
|
17
|
+
// Layer2 variables are defined in HkIconButtonVars.scss
|
|
17
18
|
|
|
18
19
|
// Layout
|
|
19
20
|
display: inline-flex;
|
|
@@ -22,7 +23,6 @@
|
|
|
22
23
|
flex-shrink: 0;
|
|
23
24
|
padding: 0;
|
|
24
25
|
line-height: 0;
|
|
25
|
-
gap: 0;
|
|
26
26
|
|
|
27
27
|
// Size - use CSS variables
|
|
28
28
|
width: var(--hi-icon-button-size);
|
|
@@ -54,85 +54,48 @@
|
|
|
54
54
|
// Transitions - use CSS variables
|
|
55
55
|
transition: var(--hi-icon-button-transition);
|
|
56
56
|
|
|
57
|
-
//
|
|
57
|
+
// Resting transform stays none and the press keeps it that way — the
|
|
58
|
+
// press feedback is the background wash only.
|
|
58
59
|
|
|
59
60
|
// Cursor
|
|
60
61
|
cursor: pointer;
|
|
61
62
|
|
|
62
|
-
// Focus state - only outline, no color changes
|
|
63
|
+
// Focus state - only outline, no color changes (the glyph color var is
|
|
64
|
+
// identical at rest, so re-declaring it here would be a no-op)
|
|
63
65
|
&:focus-visible {
|
|
64
66
|
outline: 2px solid var(--hi-icon-button-border-color-focus);
|
|
65
67
|
outline-offset: 2px;
|
|
66
|
-
color: var(--hi-icon-button-icon-color);
|
|
67
|
-
|
|
68
|
-
.hk-icon-button-icon {
|
|
69
|
-
color: var(--hi-icon-button-icon-color);
|
|
70
|
-
}
|
|
71
68
|
}
|
|
72
69
|
|
|
73
70
|
// Disabled state
|
|
74
71
|
&:disabled {
|
|
75
72
|
background: var(--hi-icon-button-bg-disabled);
|
|
76
|
-
color: var(--hi-icon-button-icon-color-disabled);
|
|
77
73
|
cursor: not-allowed;
|
|
78
74
|
pointer-events: none;
|
|
79
75
|
}
|
|
80
76
|
|
|
81
|
-
//
|
|
82
|
-
|
|
83
|
-
//
|
|
84
|
-
//
|
|
85
|
-
//
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
&.hk-icon-button-40 {
|
|
92
|
-
// Size variables are already set by the classes in icon-button-vars.scss
|
|
77
|
+
// Hover / press feedback. The old contract deferred these to the
|
|
78
|
+
// Rust-side Glow wrapper, but Vue-library hosts render no Glow
|
|
79
|
+
// (window-close.scss and the lightbox close each had to paint their
|
|
80
|
+
// own tint). These defaults consume the designed active vars from
|
|
81
|
+
// HkIconButtonVars.scss; :where() keeps both rules at (0,1,0) so any
|
|
82
|
+
// host hover paint — .hk-window-close's (0,3,0) tint, the lightbox
|
|
83
|
+
// chip's (0,4,0) re-assertion — still outranks them (zero-specificity
|
|
84
|
+
// guard pattern from styles/theme/base.scss).
|
|
85
|
+
&:where(:hover:not(:disabled):not(:active)) {
|
|
86
|
+
background: var(--hi-icon-button-bg-hover, var(--hi-icon-button-bg-active));
|
|
93
87
|
}
|
|
94
88
|
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
// ------
|
|
98
|
-
|
|
99
|
-
&.hk-icon-button-ghost,
|
|
100
|
-
&.hk-icon-button-borderless {
|
|
101
|
-
// Variables defined in icon-button-vars.scss
|
|
89
|
+
&:where(:active:not(:disabled)) {
|
|
90
|
+
background: var(--hi-icon-button-bg-active);
|
|
102
91
|
}
|
|
103
92
|
|
|
104
93
|
// ------
|
|
105
|
-
//
|
|
94
|
+
// Size/variant hooks carry no rules here: .hk-icon-button-16/24/32/36/40
|
|
95
|
+
// and -ghost/-borderless/-primary/-secondary/-danger/-success get all of
|
|
96
|
+
// their custom properties from HkIconButtonVars.scss.
|
|
106
97
|
// ------
|
|
107
98
|
|
|
108
|
-
&.hk-icon-button-primary {
|
|
109
|
-
// Variables defined in icon-button-vars.scss
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
// ------
|
|
113
|
-
// Variant: Secondary (solid secondary color)
|
|
114
|
-
// ------
|
|
115
|
-
|
|
116
|
-
&.hk-icon-button-secondary {
|
|
117
|
-
// Variables defined in icon-button-vars.scss
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
// ------
|
|
121
|
-
// Variant: Danger (solid danger color)
|
|
122
|
-
// ------
|
|
123
|
-
|
|
124
|
-
&.hk-icon-button-danger {
|
|
125
|
-
// Variables defined in icon-button-vars.scss
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
// ------
|
|
129
|
-
// Variant: Success (solid success color)
|
|
130
|
-
// ------
|
|
131
|
-
|
|
132
|
-
&.hk-icon-button-success {
|
|
133
|
-
// Variables defined in icon-button-vars.scss
|
|
134
|
-
}
|
|
135
|
-
|
|
136
99
|
// ------
|
|
137
100
|
// Icon Styles - Use CSS Variables
|
|
138
101
|
// ------
|
|
@@ -169,8 +132,12 @@
|
|
|
169
132
|
&:disabled .hk-icon-button-icon {
|
|
170
133
|
color: var(--hi-icon-button-icon-color-disabled);
|
|
171
134
|
}
|
|
135
|
+
}
|
|
172
136
|
|
|
173
|
-
|
|
174
|
-
|
|
137
|
+
// The transition above drives the press transform; snap it under reduced
|
|
138
|
+
// motion (house pattern: HkFab.scss / HkExpansionPanel.scss).
|
|
139
|
+
@media (prefers-reduced-motion: reduce) {
|
|
140
|
+
.hk-icon-button {
|
|
141
|
+
transition: none;
|
|
175
142
|
}
|
|
176
143
|
}
|
|
@@ -2,9 +2,10 @@
|
|
|
2
2
|
// Layer2 - IconButton Component Variables
|
|
3
3
|
//
|
|
4
4
|
// This file defines component-level CSS variables for the IconButton component.
|
|
5
|
-
// These variables can be overridden
|
|
5
|
+
// These variables can be overridden by host theme layers.
|
|
6
6
|
//
|
|
7
|
-
// NOTE: Hover
|
|
7
|
+
// NOTE: Hover feedback is not styled in this layer; window-close.scss adds
|
|
8
|
+
// its own hover grammar for close controls.
|
|
8
9
|
// Only base, active, and disabled states are defined.
|
|
9
10
|
|
|
10
11
|
// ------
|
|
@@ -26,18 +27,14 @@
|
|
|
26
27
|
--hi-icon-button-bg-active: var(--hi-bg-surface-dark);
|
|
27
28
|
--hi-icon-button-bg-disabled: rgba(128, 128, 128, 0.1);
|
|
28
29
|
|
|
29
|
-
// Border Colors
|
|
30
|
-
--hi-icon-button-border-color: transparent;
|
|
30
|
+
// Border Colors (focus ring only; the base button draws no border)
|
|
31
31
|
--hi-icon-button-border-color-focus: var(--hi-border-color-focus);
|
|
32
32
|
|
|
33
|
-
// Shadow & Glow (used by Glow wrapper)
|
|
34
|
-
--hi-icon-button-glow: var(--hi-glow-color);
|
|
35
|
-
|
|
36
33
|
// ------
|
|
37
34
|
// 2. Border Radius System
|
|
38
35
|
// ------
|
|
39
36
|
|
|
40
|
-
--hi-icon-button-radius: 4px;
|
|
37
|
+
--hi-icon-button-radius: var(--radius-sm, 4px);
|
|
41
38
|
|
|
42
39
|
// ------
|
|
43
40
|
// 3. Animation System
|
|
@@ -45,15 +42,13 @@
|
|
|
45
42
|
|
|
46
43
|
// Duration
|
|
47
44
|
--hi-icon-button-duration: var(--hi-duration-fast);
|
|
48
|
-
--hi-icon-button-duration-active: var(--hi-duration-instant);
|
|
49
45
|
|
|
50
46
|
// Easing
|
|
51
47
|
--hi-icon-button-easing: var(--hi-ease-default);
|
|
52
48
|
|
|
53
|
-
// Transition
|
|
54
|
-
--hi-icon-button-transition:
|
|
55
|
-
|
|
56
|
-
transform var(--hi-icon-button-duration-active) var(--hi-icon-button-easing);
|
|
49
|
+
// Transition (background only; CSS applies no transform to the button)
|
|
50
|
+
--hi-icon-button-transition: background-color var(--hi-icon-button-duration)
|
|
51
|
+
var(--hi-icon-button-easing);
|
|
57
52
|
|
|
58
53
|
// ------
|
|
59
54
|
// 4. Size System
|
|
@@ -61,13 +56,6 @@
|
|
|
61
56
|
|
|
62
57
|
--hi-icon-button-size: 40px;
|
|
63
58
|
--hi-icon-button-icon-size: var(--hi-icon-size-sm);
|
|
64
|
-
|
|
65
|
-
// ------
|
|
66
|
-
// 5. Transform System
|
|
67
|
-
// ------
|
|
68
|
-
|
|
69
|
-
--hi-icon-button-transform: none;
|
|
70
|
-
--hi-icon-button-transform-active: scale(0.95);
|
|
71
59
|
}
|
|
72
60
|
|
|
73
61
|
// ------
|
|
@@ -108,11 +96,7 @@
|
|
|
108
96
|
--hi-icon-button-icon-color: var(--hi-color-text-secondary);
|
|
109
97
|
--hi-icon-button-icon-color-active: var(--hi-color-text-secondary);
|
|
110
98
|
|
|
111
|
-
--hi-icon-button-bg: transparent;
|
|
112
99
|
--hi-icon-button-bg-active: var(--hi-color-gray-20, rgba(128, 128, 128, 0.2));
|
|
113
|
-
|
|
114
|
-
--hi-icon-button-border-color: transparent;
|
|
115
|
-
--hi-icon-button-glow: var(--hi-glow-color);
|
|
116
100
|
}
|
|
117
101
|
|
|
118
102
|
// ------
|
|
@@ -131,7 +115,6 @@
|
|
|
131
115
|
--hi-icon-button-bg-active: var(--hi-color-primary-dark);
|
|
132
116
|
|
|
133
117
|
--hi-icon-button-border-color-focus: var(--hi-color-primary);
|
|
134
|
-
--hi-icon-button-glow: var(--hi-glow-color);
|
|
135
118
|
}
|
|
136
119
|
|
|
137
120
|
// ------
|
|
@@ -146,7 +129,6 @@
|
|
|
146
129
|
--hi-icon-button-bg-active: var(--hi-color-secondary-dark);
|
|
147
130
|
|
|
148
131
|
--hi-icon-button-border-color-focus: var(--hi-color-secondary);
|
|
149
|
-
--hi-icon-button-glow: var(--hi-glow-color);
|
|
150
132
|
}
|
|
151
133
|
|
|
152
134
|
// ------
|
|
@@ -161,7 +143,6 @@
|
|
|
161
143
|
--hi-icon-button-bg-active: var(--hi-color-danger-dark);
|
|
162
144
|
|
|
163
145
|
--hi-icon-button-border-color-focus: var(--hi-color-danger);
|
|
164
|
-
--hi-icon-button-glow: var(--hi-glow-color);
|
|
165
146
|
}
|
|
166
147
|
|
|
167
148
|
// ------
|
|
@@ -176,5 +157,4 @@
|
|
|
176
157
|
--hi-icon-button-bg-active: var(--hi-color-success-dark);
|
|
177
158
|
|
|
178
159
|
--hi-icon-button-border-color-focus: var(--hi-color-success);
|
|
179
|
-
--hi-icon-button-glow: var(--hi-glow-color);
|
|
180
160
|
}
|