@hina-ui/vue 1.7.9 → 1.7.11
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/dist/index.js +283 -92
- package/dist/index.js.map +1 -1
- package/dist/shared/behavior/spoiler/painter.ts +87 -60
- package/dist/shared/behavior/spoiler/worklet.ts +7 -9
- package/dist/shared/lib/command-palette/match.ts +17 -4
- package/dist/shared/lib/virtual/choices.ts +2 -1
- package/dist/shared/styles/motion.css +7 -1
- package/dist/shared/styles/spoiler.css +6 -0
- package/dist/shared/styles/typography.css +18 -3
- package/dist/shared/variants/command-palette.ts +12 -0
- package/dist/shared/variants/virtual-list.ts +8 -0
- package/dist/types/shared/src/behavior/spoiler/painter.d.ts +10 -9
- package/dist/types/shared/src/behavior/spoiler/painter.d.ts.map +1 -1
- package/dist/types/shared/src/behavior/spoiler/worklet.d.ts.map +1 -1
- package/dist/types/shared/src/lib/command-palette/match.d.ts +9 -0
- package/dist/types/shared/src/lib/command-palette/match.d.ts.map +1 -1
- package/dist/types/shared/src/lib/virtual/choices.d.ts +4 -0
- package/dist/types/shared/src/lib/virtual/choices.d.ts.map +1 -1
- package/dist/types/shared/src/variants/command-palette.d.ts +3 -0
- package/dist/types/shared/src/variants/command-palette.d.ts.map +1 -1
- package/dist/types/shared/src/variants/virtual-list.d.ts +2 -0
- package/dist/types/shared/src/variants/virtual-list.d.ts.map +1 -1
- package/dist/types/vue/src/components/command-palette/CommandPalette.vue.d.ts +2 -1
- package/dist/types/vue/src/components/command-palette/CommandPalette.vue.d.ts.map +1 -1
- package/dist/types/vue/src/components/command-palette/CommandPalettePanel.vue.d.ts +2 -1
- package/dist/types/vue/src/components/command-palette/CommandPalettePanel.vue.d.ts.map +1 -1
- package/dist/types/vue/src/components/command-palette/composables/useCommandItems.d.ts +6 -1
- package/dist/types/vue/src/components/command-palette/composables/useCommandItems.d.ts.map +1 -1
- package/dist/types/vue/src/components/command-palette/types.d.ts +3 -0
- package/dist/types/vue/src/components/command-palette/types.d.ts.map +1 -1
- package/dist/types/vue/src/components/command-palette/utils/match.d.ts +1 -1
- package/dist/types/vue/src/components/command-palette/utils/match.d.ts.map +1 -1
- package/dist/types/vue/src/components/virtual-list/VirtualChoices.vue.d.ts +4 -1
- package/dist/types/vue/src/components/virtual-list/VirtualChoices.vue.d.ts.map +1 -1
- package/dist/types/vue/src/index.d.ts +1 -1
- package/dist/types/vue/src/index.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/components/command-palette/CommandPalette.vue +8 -0
- package/src/components/command-palette/CommandPalettePanel.vue +85 -3
- package/src/components/command-palette/composables/useCommandItems.ts +19 -13
- package/src/components/command-palette/types.ts +4 -0
- package/src/components/command-palette/utils/match.ts +1 -0
- package/src/components/virtual-list/VirtualChoices.vue +39 -6
- package/src/index.ts +1 -0
|
@@ -32,26 +32,50 @@ const DEFAULTS = {
|
|
|
32
32
|
accent: '0 0% 20%',
|
|
33
33
|
} as const
|
|
34
34
|
|
|
35
|
+
export const SPOILER_WORKLET_INPUTS = [
|
|
36
|
+
'--hn-nz-t',
|
|
37
|
+
'--hn-nz-stop',
|
|
38
|
+
'--hn-nz-fade',
|
|
39
|
+
'--hn-nz-gap',
|
|
40
|
+
'--hn-nz-accent',
|
|
41
|
+
'--hn-nz-words',
|
|
42
|
+
'--hn-nz-density',
|
|
43
|
+
] as const
|
|
44
|
+
|
|
35
45
|
const BLOCK_MAX_TILE = 293
|
|
36
46
|
const INLINE_MAX_TILE = 333
|
|
37
47
|
const GAP_RATIO = 8
|
|
38
48
|
const DEFAULT_FADE_S = 1.5
|
|
49
|
+
const CLOCK_S = 3600
|
|
50
|
+
|
|
51
|
+
const painters = new WeakMap<Element, SpoilerPainter>()
|
|
52
|
+
let viewport: IntersectionObserver | undefined
|
|
53
|
+
|
|
54
|
+
function watchViewport() {
|
|
55
|
+
viewport ??= new IntersectionObserver(entries => {
|
|
56
|
+
for (const entry of entries) painters.get(entry.target)?.setInView(entry.isIntersecting)
|
|
57
|
+
})
|
|
58
|
+
return viewport
|
|
59
|
+
}
|
|
39
60
|
|
|
40
61
|
export class SpoilerPainter {
|
|
41
62
|
readonly el: HTMLElement
|
|
42
63
|
maxFPS: number = DEFAULTS.fps
|
|
43
64
|
|
|
44
|
-
private
|
|
45
|
-
private
|
|
46
|
-
private
|
|
47
|
-
private
|
|
48
|
-
private fadeS = 0
|
|
65
|
+
private clock: Animation | null = null
|
|
66
|
+
private settle: ReturnType<typeof setTimeout> | undefined
|
|
67
|
+
private running = false
|
|
68
|
+
private inView = false
|
|
49
69
|
private hidden = false
|
|
50
70
|
private destroyed = false
|
|
51
71
|
|
|
52
72
|
constructor(el: HTMLElement, options: SpoilerPainterOptions = {}) {
|
|
53
73
|
registerSpoilerWorklet()
|
|
54
74
|
this.el = el
|
|
75
|
+
painters.set(el, this)
|
|
76
|
+
watchViewport().observe(el)
|
|
77
|
+
this.setFade(0)
|
|
78
|
+
this.setTstop(null)
|
|
55
79
|
this.update(options)
|
|
56
80
|
}
|
|
57
81
|
|
|
@@ -68,13 +92,19 @@ export class SpoilerPainter {
|
|
|
68
92
|
}: SpoilerPainterOptions = {}) {
|
|
69
93
|
if (this.destroyed) return
|
|
70
94
|
|
|
71
|
-
|
|
95
|
+
const maxFPS = prefersReducedMotion() ? 0 : fps
|
|
96
|
+
if (maxFPS !== this.maxFPS) {
|
|
97
|
+
this.maxFPS = maxFPS
|
|
98
|
+
if (maxFPS > 0) this.clock?.effect?.updateTiming({ easing: this.easing() })
|
|
99
|
+
else this.stopClock()
|
|
100
|
+
}
|
|
72
101
|
|
|
73
102
|
this.el.style.setProperty('--hn-nz-density', String(density))
|
|
74
103
|
this.el.style.setProperty('--hn-nz-accent', accent)
|
|
75
104
|
|
|
76
105
|
const isBlockElement = getComputedStyle(this.el).getPropertyValue('display') !== 'inline'
|
|
77
106
|
this.useBackgroundStyle('auto', 'auto', false)
|
|
107
|
+
this.el.style.setProperty('--hn-nz-gap', '0px 0px')
|
|
78
108
|
|
|
79
109
|
if (isBlockElement) {
|
|
80
110
|
this.el.style.setProperty('--hn-nz-words', 'false')
|
|
@@ -109,23 +139,21 @@ export class SpoilerPainter {
|
|
|
109
139
|
this.el.style.background = `paint(hn-spoiler) ${repeatAndPosition} / ${w} ${h}`
|
|
110
140
|
}
|
|
111
141
|
|
|
112
|
-
private
|
|
113
|
-
|
|
114
|
-
this.el.style.setProperty('--hn-nz-fade', `${value}s`)
|
|
142
|
+
private easing() {
|
|
143
|
+
return `steps(${Math.round(CLOCK_S * this.maxFPS)})`
|
|
115
144
|
}
|
|
116
145
|
|
|
117
|
-
private
|
|
118
|
-
this.
|
|
119
|
-
this.
|
|
146
|
+
private time() {
|
|
147
|
+
const elapsed = Number(this.clock?.currentTime ?? 0) / 1000
|
|
148
|
+
return this.maxFPS > 0 ? Math.floor(elapsed * this.maxFPS) / this.maxFPS : 0
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
private setFade(value: number) {
|
|
152
|
+
this.el.style.setProperty('--hn-nz-fade', `${value}s`)
|
|
120
153
|
}
|
|
121
154
|
|
|
122
155
|
private setTstop(value: number | null) {
|
|
123
|
-
this.
|
|
124
|
-
if (value !== null) {
|
|
125
|
-
this.el.style.setProperty('--hn-nz-stop', value.toFixed(3))
|
|
126
|
-
} else {
|
|
127
|
-
this.el.style.removeProperty('--hn-nz-stop')
|
|
128
|
-
}
|
|
156
|
+
this.el.style.setProperty('--hn-nz-stop', value === null ? 'Infinity' : value.toFixed(3))
|
|
129
157
|
}
|
|
130
158
|
|
|
131
159
|
private parseFade(value: number | boolean | undefined) {
|
|
@@ -133,13 +161,40 @@ export class SpoilerPainter {
|
|
|
133
161
|
return value === true || value === undefined ? DEFAULT_FADE_S : Number(value)
|
|
134
162
|
}
|
|
135
163
|
|
|
164
|
+
private sync() {
|
|
165
|
+
if (!this.clock) return
|
|
166
|
+
if (this.running && this.inView) this.clock.play()
|
|
167
|
+
else this.clock.pause()
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
private stopClock() {
|
|
171
|
+
clearTimeout(this.settle)
|
|
172
|
+
this.settle = undefined
|
|
173
|
+
this.clock?.cancel()
|
|
174
|
+
this.clock = null
|
|
175
|
+
this.running = false
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
setInView(value: boolean) {
|
|
179
|
+
if (this.destroyed || value === this.inView) return
|
|
180
|
+
this.inView = value
|
|
181
|
+
this.sync()
|
|
182
|
+
}
|
|
183
|
+
|
|
136
184
|
hide(animate?: number | boolean) {
|
|
137
185
|
if (this.destroyed) return
|
|
138
186
|
this.hidden = true
|
|
139
187
|
this.setFade(this.parseFade(animate))
|
|
140
188
|
this.setTstop(null)
|
|
141
|
-
this.
|
|
142
|
-
this.
|
|
189
|
+
this.stopClock()
|
|
190
|
+
if (this.maxFPS <= 0) return
|
|
191
|
+
this.clock = this.el.animate({ '--hn-nz-t': [0, CLOCK_S] } as PropertyIndexedKeyframes, {
|
|
192
|
+
duration: CLOCK_S * 1000,
|
|
193
|
+
easing: this.easing(),
|
|
194
|
+
iterations: Infinity,
|
|
195
|
+
})
|
|
196
|
+
this.running = true
|
|
197
|
+
this.sync()
|
|
143
198
|
}
|
|
144
199
|
|
|
145
200
|
reveal(animate?: number | boolean) {
|
|
@@ -147,51 +202,23 @@ export class SpoilerPainter {
|
|
|
147
202
|
this.hidden = false
|
|
148
203
|
const duration = this.parseFade(animate)
|
|
149
204
|
this.setFade(duration)
|
|
150
|
-
this.setTstop(this.
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
const shouldStop = this.tstop !== null && this.t > this.tstop + this.fadeS
|
|
157
|
-
|
|
158
|
-
if (this.maxFPS > 0 && !shouldStop) {
|
|
159
|
-
this.raf = requestAnimationFrame(this.frame)
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
const dt = now - this.t0
|
|
163
|
-
if (dt > 0 && dt < 1000 / this.maxFPS) return
|
|
164
|
-
|
|
165
|
-
this.setT(this.t + dt / 1000)
|
|
166
|
-
this.t0 = now
|
|
167
|
-
}
|
|
168
|
-
|
|
169
|
-
private startAnimation() {
|
|
170
|
-
this.t0 = performance.now()
|
|
171
|
-
this.frame(this.t0)
|
|
172
|
-
}
|
|
173
|
-
|
|
174
|
-
private stopAnimation() {
|
|
175
|
-
if (this.raf !== null) {
|
|
176
|
-
cancelAnimationFrame(this.raf)
|
|
177
|
-
this.raf = null
|
|
205
|
+
this.setTstop(this.time())
|
|
206
|
+
clearTimeout(this.settle)
|
|
207
|
+
const stop = () => {
|
|
208
|
+
this.settle = undefined
|
|
209
|
+
this.running = false
|
|
210
|
+
this.sync()
|
|
178
211
|
}
|
|
212
|
+
if (duration <= 0) stop()
|
|
213
|
+
else this.settle = setTimeout(stop, duration * 1000 + 1000 / this.maxFPS)
|
|
179
214
|
}
|
|
180
215
|
|
|
181
216
|
destroy() {
|
|
182
217
|
this.destroyed = true
|
|
183
|
-
this.
|
|
218
|
+
this.stopClock()
|
|
219
|
+
viewport?.unobserve(this.el)
|
|
220
|
+
painters.delete(this.el)
|
|
184
221
|
this.el.style.removeProperty('background')
|
|
185
|
-
for (const prop of
|
|
186
|
-
'--hn-nz-t',
|
|
187
|
-
'--hn-nz-stop',
|
|
188
|
-
'--hn-nz-fade',
|
|
189
|
-
'--hn-nz-gap',
|
|
190
|
-
'--hn-nz-words',
|
|
191
|
-
'--hn-nz-density',
|
|
192
|
-
'--hn-nz-accent',
|
|
193
|
-
]) {
|
|
194
|
-
this.el.style.removeProperty(prop)
|
|
195
|
-
}
|
|
222
|
+
for (const prop of SPOILER_WORKLET_INPUTS) this.el.style.removeProperty(prop)
|
|
196
223
|
}
|
|
197
224
|
}
|
|
@@ -11,10 +11,6 @@ const workletMain = () => {
|
|
|
11
11
|
0x7fffffff
|
|
12
12
|
|
|
13
13
|
const pol2vec = (l: number, a = 0) => [l * M.cos(a), l * M.sin(a)] as const
|
|
14
|
-
const vecmag = ([x, y]: readonly number[]) => M.sqrt(x! * x! + y! * y!)
|
|
15
|
-
const vecnorm = ([x, y]: readonly number[], l = vecmag([x!, y!])) =>
|
|
16
|
-
l === 0 ? ([0, 0] as const) : ([x! / l, y! / l] as const)
|
|
17
|
-
|
|
18
14
|
const trapezoidalWave = (l: number, a: number, b: number) => {
|
|
19
15
|
const s = M.max(a, l - b)
|
|
20
16
|
return (t: number) => {
|
|
@@ -144,20 +140,21 @@ const workletMain = () => {
|
|
|
144
140
|
|
|
145
141
|
ctx.clearRect(0, 0, size.width, size.height)
|
|
146
142
|
|
|
143
|
+
const l = parseInt(accent[2] ?? '0')
|
|
144
|
+
const ldir = l > 50 ? -1 : 1
|
|
145
|
+
const hue = `hsl(${accent[0]} ${accent[1]} `
|
|
146
|
+
|
|
147
147
|
for (let i = 0; i < world.n; ++i) {
|
|
148
148
|
const x0 = hgap + wordDist(rand())
|
|
149
149
|
const y0 = rand(vgap, height - vgap)
|
|
150
150
|
const v0mag = rand(vmin, vmax)
|
|
151
151
|
const size0 = rand(1, 1 + sizedev)
|
|
152
152
|
|
|
153
|
-
const l = parseInt(accent[2] ?? '0')
|
|
154
|
-
const ldir = l > 50 ? -1 : 1
|
|
155
153
|
const lightness = M.floor(clamp(0, l + ldir * rand(0, 30), 100))
|
|
156
154
|
|
|
157
155
|
const v0 = pol2vec(v0mag, rand(0, M.PI * 2))
|
|
158
156
|
const vx0 = v0[0]
|
|
159
157
|
const vy0 = v0[1]
|
|
160
|
-
vecnorm(v0)
|
|
161
158
|
|
|
162
159
|
const shape = rand() > 0.5 ? 'square' : 'circle'
|
|
163
160
|
const lifetime = rand(0.3, 1.5)
|
|
@@ -175,12 +172,13 @@ const workletMain = () => {
|
|
|
175
172
|
const y = y0 + vy0 * t
|
|
176
173
|
|
|
177
174
|
const fade = animateFadeInOut(world, i, fadeDuration)
|
|
178
|
-
const alpha = fade * (1 - t / lifetime)
|
|
175
|
+
const alpha = M.round(fade * (1 - t / lifetime) * 100)
|
|
179
176
|
const psize = fade * (size0 * visibilityFn(t))
|
|
177
|
+
if (alpha <= 0 || psize <= 0) continue
|
|
180
178
|
|
|
179
|
+
ctx.fillStyle = `${hue}${lightness}% / ${alpha}%)`
|
|
181
180
|
for (const [wx, wy] of cycleBounds([x, y], [width, height], psize / 2)) {
|
|
182
181
|
ctx.beginPath()
|
|
183
|
-
ctx.fillStyle = `hsl(${accent[0]} ${accent[1]} ${lightness}% / ${M.round(alpha * 100)}%)`
|
|
184
182
|
if (shape === 'square') {
|
|
185
183
|
ctx.rect(wx!, wy!, psize, psize)
|
|
186
184
|
} else {
|
|
@@ -18,6 +18,7 @@ export interface CommandMatch<T extends CommandMatchable = CommandMatchable> {
|
|
|
18
18
|
export interface CommandSection<T extends CommandMatchable = CommandMatchable> {
|
|
19
19
|
key: string
|
|
20
20
|
label?: string
|
|
21
|
+
group?: CommandGroupOf<T>
|
|
21
22
|
matches: CommandMatch<T>[]
|
|
22
23
|
}
|
|
23
24
|
|
|
@@ -56,6 +57,17 @@ function rank<T extends CommandMatchable>(items: T[], query: string): Scored<T>[
|
|
|
56
57
|
.sort((a, b) => b.score - a.score)
|
|
57
58
|
}
|
|
58
59
|
|
|
60
|
+
export function layoutCommandSections<T extends CommandMatchable>(sections: CommandSection<T>[]) {
|
|
61
|
+
let row = 1
|
|
62
|
+
const placed = sections.map(section => {
|
|
63
|
+
const span = section.matches.length + (section.group ? 1 : 0)
|
|
64
|
+
const entry = { section, row, span }
|
|
65
|
+
row += span
|
|
66
|
+
return entry
|
|
67
|
+
})
|
|
68
|
+
return { rows: Math.max(row - 1, 1), sections: placed }
|
|
69
|
+
}
|
|
70
|
+
|
|
59
71
|
export function filterCommands<T extends CommandMatchable>(
|
|
60
72
|
items: ReadonlyArray<T | CommandGroupOf<T>>,
|
|
61
73
|
query: string,
|
|
@@ -63,12 +75,13 @@ export function filterCommands<T extends CommandMatchable>(
|
|
|
63
75
|
const q = query.trim().toLowerCase()
|
|
64
76
|
const sections: ScoredSection<T>[] = []
|
|
65
77
|
let loose: T[] = []
|
|
66
|
-
const push = (
|
|
78
|
+
const push = (group: CommandGroupOf<T> | undefined, entries: T[]) => {
|
|
67
79
|
const ranked = rank(entries, q)
|
|
68
80
|
if (ranked.length === 0) return
|
|
69
81
|
sections.push({
|
|
70
82
|
key: String(sections.length),
|
|
71
|
-
label,
|
|
83
|
+
label: group?.label,
|
|
84
|
+
group,
|
|
72
85
|
best: ranked[0]!.score,
|
|
73
86
|
matches: ranked.map(({ item, start, end }) => ({ item, start, end })),
|
|
74
87
|
})
|
|
@@ -84,11 +97,11 @@ export function filterCommands<T extends CommandMatchable>(
|
|
|
84
97
|
continue
|
|
85
98
|
}
|
|
86
99
|
flush()
|
|
87
|
-
push(entry
|
|
100
|
+
push(entry, entry.items)
|
|
88
101
|
}
|
|
89
102
|
flush()
|
|
90
103
|
if (q) sections.sort((a, b) => b.best - a.best)
|
|
91
|
-
return sections.map(({ key, label, matches }) => ({ key, label, matches }))
|
|
104
|
+
return sections.map(({ key, label, group, matches }) => ({ key, label, group, matches }))
|
|
92
105
|
}
|
|
93
106
|
|
|
94
107
|
export interface CommandMatchRange {
|
|
@@ -6,6 +6,7 @@ export interface ChoiceRow<T> {
|
|
|
6
6
|
label: string
|
|
7
7
|
option?: T
|
|
8
8
|
group?: number
|
|
9
|
+
source?: { label: string; options: T[] }
|
|
9
10
|
position: number
|
|
10
11
|
}
|
|
11
12
|
|
|
@@ -28,7 +29,7 @@ export function choiceRows<T extends SelectOption>(
|
|
|
28
29
|
const options = item.options.filter(option => !query || contains(option.label, query))
|
|
29
30
|
if (!options.length) return
|
|
30
31
|
const group = result.length
|
|
31
|
-
result.push({ key: `group:${groupIndex}`, label: item.label, position: 0 })
|
|
32
|
+
result.push({ key: `group:${groupIndex}`, label: item.label, source: item, position: 0 })
|
|
32
33
|
for (const option of options)
|
|
33
34
|
result.push({
|
|
34
35
|
key: choiceKey(option.value),
|
|
@@ -510,8 +510,14 @@
|
|
|
510
510
|
}
|
|
511
511
|
}
|
|
512
512
|
|
|
513
|
+
@layer components {
|
|
514
|
+
.hn-anim-collapse {
|
|
515
|
+
display: flow-root;
|
|
516
|
+
}
|
|
517
|
+
}
|
|
518
|
+
|
|
513
519
|
@utility hn-anim-collapse {
|
|
514
|
-
overflow:
|
|
520
|
+
overflow: clip;
|
|
515
521
|
&[data-state='open'] {
|
|
516
522
|
animation: hn-collapse-in var(--hn-duration-base) var(--hn-ease-move);
|
|
517
523
|
}
|
|
@@ -6,10 +6,25 @@
|
|
|
6
6
|
letter-spacing: var(--hn-tracking-tight);
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
+
@layer base {
|
|
10
|
+
:where(
|
|
11
|
+
.text-accent-on,
|
|
12
|
+
.text-neutral-solid-on,
|
|
13
|
+
.text-success-on,
|
|
14
|
+
.text-warning-on,
|
|
15
|
+
.text-danger-on,
|
|
16
|
+
.text-info-on
|
|
17
|
+
) {
|
|
18
|
+
--hn-on-solid-fill: transparent;
|
|
19
|
+
--hn-on-solid-border: color-mix(in oklab, currentColor 40%, transparent);
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
|
|
9
23
|
@utility hn-code {
|
|
10
24
|
font-family: var(--hn-font-mono);
|
|
11
25
|
font-size: 0.875em;
|
|
12
|
-
background-color: var(--hn-bg-inset);
|
|
26
|
+
background-color: var(--hn-on-solid-fill, var(--hn-bg-inset));
|
|
27
|
+
box-shadow: inset 0 0 0 1px var(--hn-on-solid-border, transparent);
|
|
13
28
|
border-radius: var(--hn-radius-sm);
|
|
14
29
|
padding: 0.125em 0.375em;
|
|
15
30
|
}
|
|
@@ -144,8 +159,8 @@
|
|
|
144
159
|
@utility hn-kbd {
|
|
145
160
|
font-family: var(--hn-font-mono);
|
|
146
161
|
font-size: 0.8125em;
|
|
147
|
-
background-color: var(--hn-surface);
|
|
148
|
-
border: 1px solid var(--hn-border);
|
|
162
|
+
background-color: var(--hn-on-solid-fill, var(--hn-surface));
|
|
163
|
+
border: 1px solid var(--hn-on-solid-border, var(--hn-border));
|
|
149
164
|
border-block-end-width: 2px;
|
|
150
165
|
border-radius: var(--hn-radius-sm);
|
|
151
166
|
padding: 0.0625em 0.375em;
|
|
@@ -44,6 +44,18 @@ export const commandEmpty = tv({
|
|
|
44
44
|
base: 'text-muted px-4 py-8 text-center text-sm',
|
|
45
45
|
})
|
|
46
46
|
|
|
47
|
+
export const commandHeading = tv({
|
|
48
|
+
base: 'text-muted flex min-h-7 items-center justify-between gap-2 px-2.5 text-xs font-medium',
|
|
49
|
+
})
|
|
50
|
+
|
|
51
|
+
export const commandGrid = tv({
|
|
52
|
+
base: 'grid grid-cols-[minmax(0,1fr)] p-1',
|
|
53
|
+
})
|
|
54
|
+
|
|
55
|
+
export const commandGridRows = tv({
|
|
56
|
+
base: 'col-start-1 grid grid-rows-subgrid',
|
|
57
|
+
})
|
|
58
|
+
|
|
47
59
|
export const commandStatus = tv({
|
|
48
60
|
base: 'border-line text-muted shrink-0 border-t px-4 py-2 text-center text-sm',
|
|
49
61
|
})
|
|
@@ -14,6 +14,14 @@ export const virtualListContent = tv({
|
|
|
14
14
|
},
|
|
15
15
|
})
|
|
16
16
|
|
|
17
|
+
export const virtualChoiceHeadings = tv({
|
|
18
|
+
base: 'pointer-events-none absolute inset-0 z-1 p-[inherit]',
|
|
19
|
+
})
|
|
20
|
+
|
|
21
|
+
export const virtualChoiceHeading = tv({
|
|
22
|
+
base: 'pointer-events-auto absolute inset-x-0',
|
|
23
|
+
})
|
|
24
|
+
|
|
17
25
|
export const virtualListItem = tv({
|
|
18
26
|
base: 'flow-root min-w-0 shrink-0',
|
|
19
27
|
variants: {
|
|
@@ -7,29 +7,30 @@ export interface SpoilerPainterOptions {
|
|
|
7
7
|
mimicWords?: boolean;
|
|
8
8
|
accent?: string;
|
|
9
9
|
}
|
|
10
|
+
export declare const SPOILER_WORKLET_INPUTS: readonly ["--hn-nz-t", "--hn-nz-stop", "--hn-nz-fade", "--hn-nz-gap", "--hn-nz-accent", "--hn-nz-words", "--hn-nz-density"];
|
|
10
11
|
export declare class SpoilerPainter {
|
|
11
12
|
readonly el: HTMLElement;
|
|
12
13
|
maxFPS: number;
|
|
13
|
-
private
|
|
14
|
-
private
|
|
15
|
-
private
|
|
16
|
-
private
|
|
17
|
-
private fadeS;
|
|
14
|
+
private clock;
|
|
15
|
+
private settle;
|
|
16
|
+
private running;
|
|
17
|
+
private inView;
|
|
18
18
|
private hidden;
|
|
19
19
|
private destroyed;
|
|
20
20
|
constructor(el: HTMLElement, options?: SpoilerPainterOptions);
|
|
21
21
|
get isHidden(): boolean;
|
|
22
22
|
update({ fps, gap, density, mimicWords, accent, }?: SpoilerPainterOptions): void;
|
|
23
23
|
private useBackgroundStyle;
|
|
24
|
+
private easing;
|
|
25
|
+
private time;
|
|
24
26
|
private setFade;
|
|
25
|
-
private setT;
|
|
26
27
|
private setTstop;
|
|
27
28
|
private parseFade;
|
|
29
|
+
private sync;
|
|
30
|
+
private stopClock;
|
|
31
|
+
setInView(value: boolean): void;
|
|
28
32
|
hide(animate?: number | boolean): void;
|
|
29
33
|
reveal(animate?: number | boolean): void;
|
|
30
|
-
private frame;
|
|
31
|
-
private startAnimation;
|
|
32
|
-
private stopAnimation;
|
|
33
34
|
destroy(): void;
|
|
34
35
|
}
|
|
35
36
|
//# sourceMappingURL=painter.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"painter.d.ts","sourceRoot":"","sources":["../../../../../../../shared/src/behavior/spoiler/painter.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,uBAAuB,SAC0D,CAAA;AAI9F,wBAAgB,sBAAsB,SAQrC;AAED,MAAM,WAAW,qBAAqB;IACpC,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB;
|
|
1
|
+
{"version":3,"file":"painter.d.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
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"worklet.d.ts","sourceRoot":"","sources":["../../../../../../../shared/src/behavior/spoiler/worklet.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"worklet.d.ts","sourceRoot":"","sources":["../../../../../../../shared/src/behavior/spoiler/worklet.ts"],"names":[],"mappings":"AAoMA,eAAO,MAAM,aAAa,QAAkC,CAAA"}
|
|
@@ -15,8 +15,17 @@ export interface CommandMatch<T extends CommandMatchable = CommandMatchable> {
|
|
|
15
15
|
export interface CommandSection<T extends CommandMatchable = CommandMatchable> {
|
|
16
16
|
key: string;
|
|
17
17
|
label?: string;
|
|
18
|
+
group?: CommandGroupOf<T>;
|
|
18
19
|
matches: CommandMatch<T>[];
|
|
19
20
|
}
|
|
21
|
+
export declare function layoutCommandSections<T extends CommandMatchable>(sections: CommandSection<T>[]): {
|
|
22
|
+
rows: number;
|
|
23
|
+
sections: {
|
|
24
|
+
section: CommandSection<T>;
|
|
25
|
+
row: number;
|
|
26
|
+
span: number;
|
|
27
|
+
}[];
|
|
28
|
+
};
|
|
20
29
|
export declare function filterCommands<T extends CommandMatchable>(items: ReadonlyArray<T | CommandGroupOf<T>>, query: string): CommandSection<T>[];
|
|
21
30
|
export interface CommandMatchRange {
|
|
22
31
|
start: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"match.d.ts","sourceRoot":"","sources":["../../../../../../../shared/src/lib/command-palette/match.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,MAAM,CAAA;IACb,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAA;CACpB;AAED,MAAM,WAAW,cAAc,CAAC,CAAC;IAC/B,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,CAAC,EAAE,CAAA;CACX;AAED,MAAM,WAAW,YAAY,CAAC,CAAC,SAAS,gBAAgB,GAAG,gBAAg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EAAE,OAAO,EACf,MAAM,EAAE,MAAM,mCAKf;AAED,wBAAgB,qBAAqB,CAAC,GAAG,GAAE,MAAM,MAAyB;;;gBAU1D,MAAM;EAOrB;AAED,MAAM,MAAM,eAAe,GAAG,UAAU,CAAC,OAAO,qBAAqB,CAAC,CAAA;AAEtE,MAAM,WAAW,cAAc;IAC7B,GAAG,EAAE,MAAM,CAAA;IACX,OAAO,EAAE,OAAO,CAAA;IAChB,OAAO,EAAE,OAAO,CAAA;IAChB,MAAM,EAAE,OAAO,CAAA;IACf,QAAQ,EAAE,OAAO,CAAA;CAClB;AAED,MAAM,MAAM,eAAe,GACvB;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,GAChB;IAAE,IAAI,EAAE,YAAY,CAAA;CAAE,GACtB;IAAE,IAAI,EAAE,QAAQ,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,GACjC;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAA;CAAE,CAAA;AAEpC,wBAAgB,eAAe,CAC7B,KAAK,EAAE,cAAc,EACrB,KAAK,EAAE;IACL,MAAM,EAAE,MAAM,SAAS,MAAM,EAAE,CAAA;IAC/B,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,EAAE,MAAM,CAAA;IACf,KAAK,EAAE,OAAO,CAAA;IACd,QAAQ,EAAE,OAAO,CAAA;IACjB,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAA;IACpC,SAAS,EAAE,eAAe,CAAA;CAC3B,GACA,eAAe,CAwCjB"}
|
|
@@ -19,5 +19,8 @@ export declare const commandItemBody: import("tailwind-variants").TVReturnType<{
|
|
|
19
19
|
export declare const commandItemMatch: import("tailwind-variants").TVReturnType<{} | {} | {}, undefined, "text-accent-text font-medium", {} | {}, undefined, import("tailwind-variants").TVReturnTypeLike<unknown, undefined>>;
|
|
20
20
|
export declare const commandItemHint: import("tailwind-variants").TVReturnType<{} | {} | {}, undefined, "ms-auto flex shrink-0 items-center gap-1", {} | {}, undefined, import("tailwind-variants").TVReturnTypeLike<unknown, undefined>>;
|
|
21
21
|
export declare const commandEmpty: import("tailwind-variants").TVReturnType<{} | {} | {}, undefined, "text-muted px-4 py-8 text-center text-sm", {} | {}, undefined, import("tailwind-variants").TVReturnTypeLike<unknown, undefined>>;
|
|
22
|
+
export declare const commandHeading: import("tailwind-variants").TVReturnType<{} | {} | {}, undefined, "text-muted flex min-h-7 items-center justify-between gap-2 px-2.5 text-xs font-medium", {} | {}, undefined, import("tailwind-variants").TVReturnTypeLike<unknown, undefined>>;
|
|
23
|
+
export declare const commandGrid: import("tailwind-variants").TVReturnType<{} | {} | {}, undefined, "grid grid-cols-[minmax(0,1fr)] p-1", {} | {}, undefined, import("tailwind-variants").TVReturnTypeLike<unknown, undefined>>;
|
|
24
|
+
export declare const commandGridRows: import("tailwind-variants").TVReturnType<{} | {} | {}, undefined, "col-start-1 grid grid-rows-subgrid", {} | {}, undefined, import("tailwind-variants").TVReturnTypeLike<unknown, undefined>>;
|
|
22
25
|
export declare const commandStatus: import("tailwind-variants").TVReturnType<{} | {} | {}, undefined, "border-line text-muted shrink-0 border-t px-4 py-2 text-center text-sm", {} | {}, undefined, import("tailwind-variants").TVReturnTypeLike<unknown, undefined>>;
|
|
23
26
|
//# sourceMappingURL=command-palette.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"command-palette.d.ts","sourceRoot":"","sources":["../../../../../../shared/src/variants/command-palette.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,cAAc,kRAEzB,CAAA;AAEF,eAAO,MAAM,WAAW;;;;;;;;;;;;cAUtB,CAAA;AAEF,eAAO,MAAM,eAAe,yQAE1B,CAAA;AAEF,eAAO,MAAM,YAAY,qPAEvB,CAAA;AAEF,eAAO,MAAM,WAAW,qLAEtB,CAAA;AAEF,eAAO,MAAM,eAAe,yLAE1B,CAAA;AAEF,eAAO,MAAM,gBAAgB,yLAE3B,CAAA;AAEF,eAAO,MAAM,eAAe,qMAE1B,CAAA;AAEF,eAAO,MAAM,YAAY,qMAEvB,CAAA;AAEF,eAAO,MAAM,aAAa,mOAExB,CAAA"}
|
|
1
|
+
{"version":3,"file":"command-palette.d.ts","sourceRoot":"","sources":["../../../../../../shared/src/variants/command-palette.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,cAAc,kRAEzB,CAAA;AAEF,eAAO,MAAM,WAAW;;;;;;;;;;;;cAUtB,CAAA;AAEF,eAAO,MAAM,eAAe,yQAE1B,CAAA;AAEF,eAAO,MAAM,YAAY,qPAEvB,CAAA;AAEF,eAAO,MAAM,WAAW,qLAEtB,CAAA;AAEF,eAAO,MAAM,eAAe,yLAE1B,CAAA;AAEF,eAAO,MAAM,gBAAgB,yLAE3B,CAAA;AAEF,eAAO,MAAM,eAAe,qMAE1B,CAAA;AAEF,eAAO,MAAM,YAAY,qMAEvB,CAAA;AAEF,eAAO,MAAM,cAAc,kPAEzB,CAAA;AAEF,eAAO,MAAM,WAAW,+LAEtB,CAAA;AAEF,eAAO,MAAM,eAAe,+LAE1B,CAAA;AAEF,eAAO,MAAM,aAAa,mOAExB,CAAA"}
|
|
@@ -15,6 +15,8 @@ export declare const virtualListContent: import("tailwind-variants").TVReturnTyp
|
|
|
15
15
|
horizontal: "flex-row";
|
|
16
16
|
};
|
|
17
17
|
}, undefined>>;
|
|
18
|
+
export declare const virtualChoiceHeadings: import("tailwind-variants").TVReturnType<{} | {} | {}, undefined, "pointer-events-none absolute inset-0 z-1 p-[inherit]", {} | {}, undefined, import("tailwind-variants").TVReturnTypeLike<unknown, undefined>>;
|
|
19
|
+
export declare const virtualChoiceHeading: import("tailwind-variants").TVReturnType<{} | {} | {}, undefined, "pointer-events-auto absolute inset-x-0", {} | {}, undefined, import("tailwind-variants").TVReturnTypeLike<unknown, undefined>>;
|
|
18
20
|
export declare const virtualListItem: import("tailwind-variants").TVReturnType<{
|
|
19
21
|
orientation: {
|
|
20
22
|
vertical: "w-full";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"virtual-list.d.ts","sourceRoot":"","sources":["../../../../../../shared/src/variants/virtual-list.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,WAAW,0NAEtB,CAAA;AAEF,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;cAQ7B,CAAA;AAEF,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;cAQ1B,CAAA;AAEF,eAAO,MAAM,iBAAiB,mOAE5B,CAAA"}
|
|
1
|
+
{"version":3,"file":"virtual-list.d.ts","sourceRoot":"","sources":["../../../../../../shared/src/variants/virtual-list.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,WAAW,0NAEtB,CAAA;AAEF,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;cAQ7B,CAAA;AAEF,eAAO,MAAM,qBAAqB,iNAEhC,CAAA;AAEF,eAAO,MAAM,oBAAoB,mMAE/B,CAAA;AAEF,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;cAQ1B,CAAA;AAEF,eAAO,MAAM,iBAAiB,mOAE5B,CAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { VirtualizeOptions } from '../../lib/virtual/types';
|
|
2
|
-
import type { CommandEmptySlotProps, CommandItem, CommandItems, CommandItemSlotProps } from './types';
|
|
2
|
+
import type { CommandEmptySlotProps, CommandHeadingSlotProps, CommandItem, CommandItems, CommandItemSlotProps } from './types';
|
|
3
3
|
declare const __VLS_export: <T = unknown>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
4
4
|
props: import("vue").PublicProps & __VLS_PrettifyLocal<({
|
|
5
5
|
items: CommandItems<T>;
|
|
@@ -28,6 +28,7 @@ declare const __VLS_export: <T = unknown>(__VLS_props: NonNullable<Awaited<typeo
|
|
|
28
28
|
default?(): unknown;
|
|
29
29
|
input?(): unknown;
|
|
30
30
|
item?(props: CommandItemSlotProps<T>): unknown;
|
|
31
|
+
heading?(props: CommandHeadingSlotProps<T>): unknown;
|
|
31
32
|
loading?(): unknown;
|
|
32
33
|
empty?(props: CommandEmptySlotProps): unknown;
|
|
33
34
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CommandPalette.vue.d.ts","sourceRoot":"","sources":["../../../../../../src/components/command-palette/CommandPalette.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CommandPalette.vue.d.ts","sourceRoot":"","sources":["../../../../../../src/components/command-palette/CommandPalette.vue"],"names":[],"mappings":"AA+JE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAA;AAKhE,OAAO,KAAK,EACV,qBAAqB,EACrB,uBAAuB,EACvB,WAAW,EACX,YAAY,EACZ,oBAAoB,EACrB,MAAM,SAAS,CAAA;AAEhB,QAAA,MAAM,YAAY,GAAK,CAAC,GAAG,OAAO,EACnC,aAAa,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,EAC9D,YAAY,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC,EAC3G,gBAAgB,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,EAClE;WAkYO,OAAO,KAAK,EAAE,WAAW,GAAG,mBAAmB,CAAC;eA9X3C,YAAY,CAAC,CAAC,CAAC;qBACT,iBAAiB;sBAChB,MAAM;gBACZ,MAAM;iBACL,MAAM;uBACA,OAAO;kBACZ,OAAO;wBACD,OAAO;iBACd,OAAO;gBACR,MAAM;;eAkDX,OAAO;iBACL,MAAM;;;;;KAkU0E,CAAC,GAAG,CAAC,OAAO,UAAU,SAAS;QAAE,oBAAoB,EAAE,MAAM,CAAC,CAAA;KAAE,GAAG,CAAC,GAAG,EAAE,CAAC;YAC5J,CAAC,OAAO,EAAE,EAAE,KAAK,IAAI;WACtB,GAAG;;oBA5WK,OAAO;kBACT,OAAO;qBACJ,oBAAoB,CAAC,CAAC,CAAC,GAAG,OAAO;wBAC9B,uBAAuB,CAAC,CAAC,CAAC,GAAG,OAAO;oBACxC,OAAO;sBACL,qBAAqB,GAAG,OAAO;;UAyW1C,wJAAoC;EAEvC,KACQ,OAAO,KAAK,EAAE,KAAK,GAAG;IAAE,KAAK,CAAC,EAAE,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAA;CAAI,CAAC;wBACpE,OAAO,YAAY;AAAxC,wBAAyC;AACzC,KAAK,mBAAmB,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,GAAG,GAAG;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG;KAAG,CAAC,IAAI,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,CAAC,GAAG,EAAE,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { VirtualizeOptions } from '../../lib/virtual/types';
|
|
2
|
-
import type { CommandEmptySlotProps, CommandItem, CommandItems, CommandItemSlotProps } from './types';
|
|
2
|
+
import type { CommandEmptySlotProps, CommandHeadingSlotProps, CommandItem, CommandItems, CommandItemSlotProps } from './types';
|
|
3
3
|
declare const __VLS_export: <T = unknown>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
4
4
|
props: import("vue").PublicProps & __VLS_PrettifyLocal<({
|
|
5
5
|
items: CommandItems<T>;
|
|
@@ -25,6 +25,7 @@ declare const __VLS_export: <T = unknown>(__VLS_props: NonNullable<Awaited<typeo
|
|
|
25
25
|
default?(): unknown;
|
|
26
26
|
input?(): unknown;
|
|
27
27
|
item?(props: CommandItemSlotProps<T>): unknown;
|
|
28
|
+
heading?(props: CommandHeadingSlotProps<T>): unknown;
|
|
28
29
|
loading?(): unknown;
|
|
29
30
|
empty?(props: CommandEmptySlotProps): unknown;
|
|
30
31
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CommandPalettePanel.vue.d.ts","sourceRoot":"","sources":["../../../../../../src/components/command-palette/CommandPalettePanel.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CommandPalettePanel.vue.d.ts","sourceRoot":"","sources":["../../../../../../src/components/command-palette/CommandPalettePanel.vue"],"names":[],"mappings":"AA8QE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAA;AAehE,OAAO,KAAK,EACV,qBAAqB,EAErB,uBAAuB,EACvB,WAAW,EACX,YAAY,EACZ,oBAAoB,EACrB,MAAM,SAAS,CAAA;AAIhB,QAAA,MAAM,YAAY,GAAK,CAAC,GAAG,OAAO,EACnC,aAAa,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,OAAO,CAAC,EAC9D,YAAY,mBAAmB,CAAC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC,EAC3G,gBAAgB,WAAW,CAAC,OAAO,CAAC,OAAO,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,EAClE;WAspBO,OAAO,KAAK,EAAE,WAAW,GAAG,mBAAmB,CAAC;eAlpB7C,YAAY,CAAC,CAAC,CAAC;qBACT,iBAAiB;eACvB,MAAM;sBACC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