voodoojs 0.4.6

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.
Files changed (54) hide show
  1. package/README.md +77 -0
  2. package/dist/chunk-234ZLC6W.js +401 -0
  3. package/dist/chunk-4HQEOXTK.js +10271 -0
  4. package/dist/chunk-5777LJVW.js +64 -0
  5. package/dist/chunk-5CKGDARU.js +1845 -0
  6. package/dist/chunk-A2UOVQBP.js +82 -0
  7. package/dist/chunk-E27NRARW.js +16 -0
  8. package/dist/chunk-JZIYRIY6.js +1196 -0
  9. package/dist/chunk-NNU6WOOU.js +641 -0
  10. package/dist/chunk-PQZEVFVZ.js +448 -0
  11. package/dist/chunk-RJUNPXQF.js +946 -0
  12. package/dist/chunk-U76IRJKH.js +72 -0
  13. package/dist/essential.cjs +13889 -0
  14. package/dist/essential.d.cts +24 -0
  15. package/dist/essential.d.ts +24 -0
  16. package/dist/essential.js +51 -0
  17. package/dist/gpu.cjs +2008 -0
  18. package/dist/gpu.d.cts +68 -0
  19. package/dist/gpu.d.ts +68 -0
  20. package/dist/gpu.js +273 -0
  21. package/dist/http.cjs +467 -0
  22. package/dist/http.d.cts +148 -0
  23. package/dist/http.d.ts +148 -0
  24. package/dist/http.js +7 -0
  25. package/dist/index-CaLD-0oh.d.cts +608 -0
  26. package/dist/index-CaLD-0oh.d.ts +608 -0
  27. package/dist/index-DTllqUtj.d.cts +261 -0
  28. package/dist/index-DTllqUtj.d.ts +261 -0
  29. package/dist/index.cjs +23063 -0
  30. package/dist/index.d.cts +1603 -0
  31. package/dist/index.d.ts +1603 -0
  32. package/dist/index.js +6924 -0
  33. package/dist/query-CKJ4oSpG.d.cts +1595 -0
  34. package/dist/query-DQFRmu3u.d.ts +1595 -0
  35. package/dist/reactivity.cjs +676 -0
  36. package/dist/reactivity.d.cts +188 -0
  37. package/dist/reactivity.d.ts +188 -0
  38. package/dist/reactivity.js +4 -0
  39. package/dist/socket.cjs +2685 -0
  40. package/dist/socket.d.cts +167 -0
  41. package/dist/socket.d.ts +167 -0
  42. package/dist/socket.js +238 -0
  43. package/dist/style-XEUAGGJK.js +5 -0
  44. package/dist/utils.cjs +397 -0
  45. package/dist/utils.d.cts +111 -0
  46. package/dist/utils.d.ts +111 -0
  47. package/dist/utils.js +4 -0
  48. package/dist/voodoo.core.js +8213 -0
  49. package/dist/voodoo.core.min.js +146 -0
  50. package/dist/voodoo.full.js +21193 -0
  51. package/dist/voodoo.full.min.js +1784 -0
  52. package/dist/voodoo.js +14185 -0
  53. package/dist/voodoo.min.js +420 -0
  54. package/package.json +127 -0
@@ -0,0 +1,1603 @@
1
+ import { c as core, V as VoodooCollection } from './query-CKJ4oSpG.cjs';
2
+ export { A as App, a as AppOptions, C as ComponentDefinition, D as DirectiveBinding, b as DirectiveHooks, P as PRIORITY, R as Resource, d as ResourceOptions, S as Scope, e as VoodooConfig, f as VoodooPlugin, g as VoodooRuntimeError, h as VoodooSyntaxError, i as addCleanup, j as allStores, k as allowedGlobals, l as cache, m as clearParseCache, n as config, o as cookie, p as createApp, q as createResource, r as defineComponent, s as defineDirective, t as destroy, u as documentReady, v as ensureTokens, w as enter, x as evaluate, y as fadeIn, z as fadeOut, B as findScope, E as fromHtml, F as getScope, G as injectStyle, H as instances, I as leave, J as magic, K as magics, L as mountComponent, M as parse, N as query, O as ready, Q as refresh, T as removeStore, q as resource, U as rootScope, W as session, X as slideDown, Y as slideUp, Z as start, _ as storage, $ as store, a0 as storeNames, a1 as stringify, a2 as theme, a3 as toast, a4 as tokenize, a5 as url, a6 as viewTransition, a7 as walk, a8 as whenElement, a9 as whenReady } from './query-CKJ4oSpG.cjs';
3
+ export { EffectScope, computed, effect, effectScope, flushSync, isReactive, markRaw, nextTick, reactive, ref, shallowRef, stop, toRaw, unref, watch, watchEffect } from './reactivity.cjs';
4
+ export { HttpError, HttpMethod, HttpResponse, RequestConfig, http, request } from './http.cjs';
5
+ export { R as RoomOptions, a as RoomState, S as SocketMessage, b as SocketOptions, c as SocketRoom, d as SocketState, e as SocketTransport, V as VoodooSocket, f as createSocket, s as socket, g as socketSupported } from './index-DTllqUtj.cjs';
6
+ export { x as GpuClock, y as GpuCompute, A as GpuContext, C as GpuEffect, I as GpuSurface, M as GpuUniforms, a4 as gpu, ab as reflectWgsl } from './index-CaLD-0oh.cjs';
7
+ export { DebouncedFunction, FormatOptions, capitalize, chunk, clone, debounce, device, escapeHtml, formatCurrency, formatDate, formatFileSize, formatNumber, formatPercent, get, groupBy, isBrowser, matchesMedia, memoize, merge, once, parseDuration, random, relativeTime, sample, set, setFormatDefaults, sleep, slugify, sortBy, stripTags, throttle, titleCase, truncate, uid, unique, uuid } from './utils.cjs';
8
+
9
+ /**
10
+ * @module directives/ui
11
+ *
12
+ * Declarative UI components. Everything here works by writing HTML only:
13
+ * no JavaScript needed to have dropdowns, tabs, sidebars, tooltips, command palette and more.
14
+ *
15
+ * ```html
16
+ * <button v-dropdown="#menu">Actions</button>
17
+ * <div id="menu" v-dropdown-menu>
18
+ * <button v-copy="PROMO10">Copy coupon</button>
19
+ * </div>
20
+ * ```
21
+ *
22
+ * Accessibility is not optional in this module: each component manages ARIA roles,
23
+ * keyboard navigation, focus visibility, and Escape key closure.
24
+ */
25
+
26
+ interface HotkeyOptions {
27
+ /** Fires even when focus is in a text field. Default `false`. */
28
+ allowInInput?: boolean;
29
+ /** Prevents browser default behavior. Default `true`. */
30
+ preventDefault?: boolean;
31
+ }
32
+ /**
33
+ * Registers a global keyboard shortcut.
34
+ *
35
+ * ```js
36
+ * const stop = V.hotkey('ctrl+k', () => openSearch())
37
+ * stop() // removes the shortcut
38
+ * ```
39
+ *
40
+ * Accepts combinations (`ctrl+shift+p`, `alt+1`, `meta+k`, `mod+s`), isolated keys
41
+ * (`?`, `Escape`) and multiple combos separated by comma. Unmodified combos don't
42
+ * fire when focus is in a text field, to avoid interfering with typing.
43
+ *
44
+ * @param combo key combination
45
+ * @param handler function executed when the shortcut is triggered
46
+ * @param options behavior adjustments
47
+ * @returns function that removes the shortcut
48
+ */
49
+ declare function hotkey(combo: string, handler: (event: KeyboardEvent) => void, options?: HotkeyOptions): () => void;
50
+
51
+ /**
52
+ * @module sound
53
+ *
54
+ * Native sound, no files, no dependencies.
55
+ *
56
+ * Effects are synthesized on the fly with the Web Audio API, so there is no
57
+ * download, no audio folder, and the cost in bytes is nearly zero.
58
+ * You can also play your own file whenever you want.
59
+ *
60
+ * ```html
61
+ * <button v-sound="click">Save</button>
62
+ * <button v-sound="success" v-post="/api/orders">Complete</button>
63
+ * <a v-sound:mouseenter="hover" href="/prices">Prices</a>
64
+ * <input v-sound:input="type">
65
+ * ```
66
+ *
67
+ * ```js
68
+ * V.sound.play('success')
69
+ * V.sound.note('do', 300)
70
+ * V.sound.melody(['do', 'mi', 'sol'], 140)
71
+ * V.sound.volume(0.4)
72
+ * V.sound.mute()
73
+ * ```
74
+ *
75
+ * Rules of good behavior that the module follows on its own:
76
+ *
77
+ * - no browser lets audio play before the user interacts, so the
78
+ * context is only created on the first gesture;
79
+ * - those who enable `prefers-reduced-motion` usually prefer less stimulation, so the
80
+ * default volume drops by half in that case;
81
+ * - the mute preference is saved and applies on future visits.
82
+ */
83
+ type WaveformShape = 'sine' | 'square' | 'sawtooth' | 'triangle';
84
+ interface Layer {
85
+ /** Initial frequency in hertz. */
86
+ frequencia: number;
87
+ /** Final frequency, for the sound to slide. Absent keeps the initial. */
88
+ ate?: number;
89
+ /** Duration in seconds. */
90
+ duracao: number;
91
+ /** Relative volume of the layer, from 0 to 1. */
92
+ volume?: number;
93
+ forma?: WaveformShape;
94
+ /** Delay in seconds from the start of the effect. */
95
+ atraso?: number;
96
+ /** Volume rise time, in seconds. */
97
+ ataque?: number;
98
+ }
99
+ interface Effect {
100
+ camadas: Layer[];
101
+ /** Volume of the entire effect, from 0 to 1. */
102
+ volume?: number;
103
+ }
104
+ /**
105
+ * Library of effects. Each one was designed to be short and discrete:
106
+ * interface sound exists to confirm an action, not to draw attention.
107
+ */
108
+ declare const efeitos: Record<string, Effect>;
109
+ interface PlayOptions {
110
+ /** Relative volume, from 0 to 1. Multiplies the master volume. */
111
+ volume?: number;
112
+ /** Multiplies the frequency of all layers, making the sound higher. */
113
+ tom?: number;
114
+ }
115
+ declare const sound: {
116
+ /**
117
+ * Plays an effect by name, or a file by path.
118
+ *
119
+ * ```js
120
+ * V.sound.play('success')
121
+ * V.sound.play('/audio/ding.mp3')
122
+ * V.sound.play('click', { volume: 0.5 })
123
+ * ```
124
+ */
125
+ play(name: string, options?: PlayOptions): void;
126
+ /**
127
+ * Plays a pure frequency.
128
+ *
129
+ * ```js
130
+ * V.sound.tone(440, 300)
131
+ * ```
132
+ *
133
+ * @param frequency hertz
134
+ * @param duration milliseconds
135
+ */
136
+ tone(frequency: number, duration?: number, options?: PlayOptions & {
137
+ forma?: WaveformShape;
138
+ }): void;
139
+ /**
140
+ * Plays a note by name.
141
+ *
142
+ * ```js
143
+ * V.sound.note('la', 300)
144
+ * V.sound.note('do5', 200)
145
+ * ```
146
+ */
147
+ note(name: string, duration?: number, options?: PlayOptions): void;
148
+ /**
149
+ * Plays a sequence of notes.
150
+ *
151
+ * ```js
152
+ * V.sound.melody(['do', 'mi', 'sol', 'do5'], 140)
153
+ * ```
154
+ *
155
+ * @param notes note names, or frequencies in hertz
156
+ * @param interval milliseconds between one note and the next
157
+ */
158
+ melody(notes: Array<string | number>, interval?: number, options?: PlayOptions): void;
159
+ /**
160
+ * Reads or adjusts the master volume, from 0 to 1. The choice is saved.
161
+ *
162
+ * ```js
163
+ * V.sound.volume() // read
164
+ * V.sound.volume(0.6) // adjust
165
+ * ```
166
+ */
167
+ volume(value?: number): number;
168
+ /** Mutes sound. Pass `false` to unmute. */
169
+ mute(value?: boolean): void;
170
+ /** Unmutes sound. */
171
+ unmute(): void;
172
+ /** Toggles between muted and unmuted, and returns the new state. */
173
+ toggle(): boolean;
174
+ /** `true` when muted. */
175
+ readonly muted: boolean;
176
+ /** Names of all available effects. */
177
+ readonly names: string[];
178
+ /**
179
+ * Registers a custom effect.
180
+ *
181
+ * ```js
182
+ * V.sound.define('myWarning', {
183
+ * volume: 0.5,
184
+ * camadas: [
185
+ * { frequencia: 700, duracao: 0.1 },
186
+ * { frequencia: 900, duracao: 0.2, atraso: 0.08 }
187
+ * ]
188
+ * })
189
+ * ```
190
+ */
191
+ define(name: string, effect: Effect): void;
192
+ /** Preloads a file to avoid delay on first play. */
193
+ preload(...urls: string[]): void;
194
+ };
195
+
196
+ /** Target accepted by `animate` and `stagger`. */
197
+ type MotionTarget = Element | ArrayLike<Element> | string | null | undefined;
198
+ /** Value of an animated property. */
199
+ type MotionValue = number | string;
200
+ /**
201
+ * Map of animated properties. A single value uses the current state as the
202
+ * starting point. A pair `[from, to]` defines both extremes.
203
+ */
204
+ type MotionKeyframes = Record<string, MotionValue | [MotionValue, MotionValue]>;
205
+ /** Progress curve. Takes and returns numbers normally between 0 and 1. */
206
+ type EasingFunction = (t: number) => number;
207
+ /** Control returned by any animation. */
208
+ interface AnimationControl {
209
+ /** Stops the animation at the current point, without firing `onComplete`. */
210
+ stop(): void;
211
+ /** Resolves when the animation finishes or is interrupted. */
212
+ finished: Promise<void>;
213
+ }
214
+ /** Physical parameters of the spring. */
215
+ interface SpringConfig {
216
+ /** Spring stiffness. Higher = faster. Default 170. */
217
+ stiffness?: number;
218
+ /** Damping. Higher = less oscillation. Default 26. */
219
+ damping?: number;
220
+ /** Mass of the body. Higher = slower and heavier. Default 1. */
221
+ mass?: number;
222
+ /** Initial velocity, in units per second. */
223
+ velocity?: number;
224
+ /** Distance considered at rest. */
225
+ restDelta?: number;
226
+ /** Velocity considered at rest. */
227
+ restSpeed?: number;
228
+ }
229
+ /** Options for `animate`. */
230
+ interface AnimateOptions {
231
+ /** Duration in milliseconds. Ignored when `spring` is active. Default 400. */
232
+ duration?: number;
233
+ /** Wait before starting, in milliseconds. */
234
+ delay?: number;
235
+ /** Name of a known easing or custom function. */
236
+ easing?: EasingName | EasingFunction | string;
237
+ /** Use spring physics instead of tween. `true` accepts defaults. */
238
+ spring?: boolean | SpringConfig;
239
+ /** Extra repetitions. `2` plays three times total. */
240
+ repeat?: number;
241
+ /** Behavior of each repetition. */
242
+ repeatType?: 'loop' | 'reverse' | 'mirror';
243
+ /** Ignores `prefers-reduced-motion`. Reserve for essential animations. */
244
+ force?: boolean;
245
+ /** Called each frame with progress, which can exceed 1 for springs. */
246
+ onUpdate?(progress: number): void;
247
+ /** Called when the animation finishes naturally. */
248
+ onComplete?(): void;
249
+ }
250
+ /** Options for `stagger`. */
251
+ interface StaggerOptions extends AnimateOptions {
252
+ /** Delay added to each list item, in milliseconds. Default 60. */
253
+ delay?: number;
254
+ /** Where the wave starts. Default `first`. */
255
+ from?: 'first' | 'last' | 'center';
256
+ /** Delay applied before the first item in the wave. */
257
+ start?: number;
258
+ }
259
+ /** Options for `spring`. */
260
+ interface SpringOptions extends SpringConfig {
261
+ /** Receives the interpolated value each frame. */
262
+ onUpdate?(value: number): void;
263
+ /** Called when the spring comes to rest. */
264
+ onComplete?(): void;
265
+ }
266
+ /** Options for `inView`. */
267
+ interface InViewOptions {
268
+ /** Turns off the observer after the first entry. Default `true`. */
269
+ once?: boolean;
270
+ /** Observer margin, in the format of `rootMargin`. */
271
+ margin?: string;
272
+ /** Visible fraction required, or `any` and `all`. Default 0.25. */
273
+ amount?: number | 'any' | 'all';
274
+ /** Observer root. Default is the viewport. */
275
+ root?: Element | null;
276
+ }
277
+ /**
278
+ * Object that mixes animated properties and animation options, in the format
279
+ * used by presets and directives.
280
+ */
281
+ interface MotionVariant extends AnimateOptions {
282
+ [property: string]: unknown;
283
+ }
284
+ /**
285
+ * Ready-made progress curves. All take and return values between 0 and 1,
286
+ * except `easeOutBack` and `anticipate`, which exceed the range on purpose
287
+ * to give a sense of weight.
288
+ */
289
+ declare const easings: {
290
+ /** Constant progress. */
291
+ linear(t: number): number;
292
+ /** Starts slow and accelerates. */
293
+ easeIn(t: number): number;
294
+ /** Starts fast and decelerates. The default choice for entries. */
295
+ easeOut(t: number): number;
296
+ /** Accelerates at the start and brakes at the end. */
297
+ easeInOut(t: number): number;
298
+ /** Overshoots the target and comes back, giving a slight exaggeration at the end. */
299
+ easeOutBack(t: number): number;
300
+ /** Very long deceleration, good for large entries. */
301
+ easeOutExpo(t: number): number;
302
+ /** Pulls back slightly before advancing, like taking a running start. */
303
+ anticipate(t: number): number;
304
+ /** Bounces when reaching the target. */
305
+ bounce(t: number): number;
306
+ };
307
+ /** Names accepted in the `easing` option. */
308
+ type EasingName = keyof typeof easings;
309
+ /**
310
+ * Animates one or multiple elements.
311
+ *
312
+ * ```js
313
+ * V.animate('.card', { opacity: [0, 1], y: [24, 0] }, { duration: 420 })
314
+ * const control = V.animate(el, { scale: 1.2 }, { spring: { stiffness: 300 } })
315
+ * await control.finished
316
+ * ```
317
+ *
318
+ * @param target element, list of elements, or CSS selector
319
+ * @param keyframes animated properties, with single value or `[from, to]` pair
320
+ * @param options duration, delay, easing, spring, and repetition
321
+ */
322
+ declare function animate(target: MotionTarget, keyframes: MotionKeyframes, options?: AnimateOptions): AnimationControl;
323
+ /**
324
+ * Integrates a real spring between two numbers and delivers the value each frame.
325
+ * Does not touch the DOM, so it works for both styles and counters,
326
+ * smooth scrolling, or any other numeric value.
327
+ *
328
+ * ```js
329
+ * V.spring(0, 320, { stiffness: 210, damping: 22, onUpdate: (v) => bar.style.width = v + 'px' })
330
+ * ```
331
+ */
332
+ declare function spring(from: number, to: number, options?: SpringOptions): AnimationControl;
333
+ /**
334
+ * Animates an entire list with progressive delay between items.
335
+ *
336
+ * ```js
337
+ * V.stagger('.card', V.motionPresets.fadeUp, { delay: 70, from: 'center' })
338
+ * ```
339
+ *
340
+ * @param targets elements, list, or CSS selector
341
+ * @param keyframes animated properties
342
+ * @param options `delay` is the step between items and `start` is the delay for the entire wave
343
+ */
344
+ declare function stagger(targets: MotionTarget, keyframes: MotionKeyframes, options?: StaggerOptions): AnimationControl;
345
+ /**
346
+ * Fires a callback when the element enters the viewport.
347
+ *
348
+ * The callback can return a cleanup function, executed when the element
349
+ * leaves the viewport. This allows mounting and unmounting effects effortlessly.
350
+ *
351
+ * ```js
352
+ * const stop = V.inView(section, () => section.classList.add('active'), { once: true })
353
+ * ```
354
+ *
355
+ * @returns function that stops the observation
356
+ */
357
+ declare function inView(el: Element, callback: (entry: IntersectionObserverEntry) => void | (() => void), options?: InViewOptions): () => void;
358
+ /**
359
+ * Reports from 0 to 1 as the element crosses the screen. Equals 0 when the top
360
+ * of the element touches the bottom of the viewport and 1 when its bottom exits the top.
361
+ *
362
+ * ```js
363
+ * V.scrollProgress(section, (p) => bar.style.width = (p * 100) + '%')
364
+ * ```
365
+ *
366
+ * @returns function that stops the observation
367
+ */
368
+ declare function scrollProgress(el: Element, callback: (progress: number) => void): () => void;
369
+ /** All presets gathered for lookup by name. */
370
+ declare const motionPresets: Record<string, MotionVariant>;
371
+
372
+ /**
373
+ * @module charts
374
+ *
375
+ * Charts in pure SVG, with no external dependencies. All drawing is
376
+ * generated as text and delivered to the container at once, which keeps
377
+ * redrawing cheap even with data changing every frame.
378
+ *
379
+ * The module follows three commitments:
380
+ *
381
+ * - responsive, with `viewBox`, `preserveAspectRatio`, and `ResizeObserver`;
382
+ * - accessible, with `role="img"`, descriptive `aria-label`, and `<title>` per shape;
383
+ * - themeable, using `--v-*` variables to work in light and dark modes.
384
+ *
385
+ * ```html
386
+ * <div v-chart="{ type: 'line', data: sales, labels: months, smooth: true }"></div>
387
+ * <div v-chart="sales" v-chart-type="bar"></div>
388
+ * ```
389
+ */
390
+ /** Supported chart types. */
391
+ type ChartType = 'line' | 'area' | 'bar' | 'column' | 'stacked' | 'pie' | 'donut' | 'sparkline' | 'radar' | 'scatter' | 'progress';
392
+ /** Format applied to displayed values. */
393
+ type ChartFormat = 'number' | 'currency' | 'percent';
394
+ /** Named point. `x` and `y` are used only by `scatter`. */
395
+ interface ChartPoint {
396
+ label?: string;
397
+ value?: number;
398
+ x?: number;
399
+ y?: number;
400
+ }
401
+ /** Named series, used in charts with multiple lines or bars. */
402
+ interface ChartSeriesInput {
403
+ name: string;
404
+ data: number[];
405
+ color?: string;
406
+ }
407
+ /** Formats accepted in `options.data`. */
408
+ type ChartData = number | number[] | ChartPoint[] | ChartSeriesInput[];
409
+ /** Configuration of a chart. */
410
+ interface ChartOptions {
411
+ /** Chart type. Default `line`. */
412
+ type?: ChartType;
413
+ /** Data, in any of the accepted formats. */
414
+ data: ChartData;
415
+ /** Category axis labels. */
416
+ labels?: string[];
417
+ /** Name of the single series, used in legend and tooltip. */
418
+ name?: string;
419
+ /** Palette. When absent, uses brand colors. */
420
+ colors?: string[];
421
+ /** Height in pixels. Varies by type when absent. */
422
+ height?: number;
423
+ /** Width used when the container has no measurement yet. */
424
+ width?: number;
425
+ /** Grid lines and value axis labels. Default `true`. */
426
+ showGrid?: boolean;
427
+ /** Clickable legend. Default `true` when it makes sense for the type. */
428
+ showLegend?: boolean;
429
+ /** Writes the value of each point, bar, or slice. */
430
+ showValues?: boolean;
431
+ /** Animates drawing on entry. Default `true`. */
432
+ animate?: boolean;
433
+ /** Smooth curves in lines and areas, with Catmull-Rom to Bezier. */
434
+ smooth?: boolean;
435
+ /** Scale ceiling. In `progress` defines the value equivalent to 100 percent. */
436
+ max?: number;
437
+ /** Scale floor. */
438
+ min?: number;
439
+ /** Value formatting. Default `number`. */
440
+ format?: ChartFormat;
441
+ /** Tooltip on mouse over. Default `true`. */
442
+ tooltip?: boolean;
443
+ }
444
+ /** Control returned by `renderChart`. */
445
+ interface ChartInstance {
446
+ /** Container where the chart was drawn. */
447
+ el: HTMLElement;
448
+ /** Options currently in use. */
449
+ readonly options: ChartOptions;
450
+ /** Applies new options and redraws. */
451
+ update(next: Partial<ChartOptions>): void;
452
+ /** Removes listeners, observers, and generated content. */
453
+ destroy(): void;
454
+ }
455
+ /**
456
+ * Formats a value according to `options.format`. The `percent` format only
457
+ * adds the symbol, because in a dashboard the data usually already comes in the 0 to 100 scale.
458
+ */
459
+ declare function formatChartValue(value: number, format?: ChartFormat): string;
460
+ /**
461
+ * Draws a chart inside an element and returns instance control.
462
+ *
463
+ * ```js
464
+ * const chart = V.renderChart(document.querySelector('#sales'), {
465
+ * type: 'area',
466
+ * data: [12, 19, 8, 25, 30],
467
+ * labels: ['Jan', 'Feb', 'Mar', 'Apr', 'May'],
468
+ * smooth: true,
469
+ * })
470
+ * chart.update({ data: newData })
471
+ * ```
472
+ *
473
+ * @param el container that receives the SVG. Previous content is replaced.
474
+ * @param options type, data, and visual adjustments
475
+ */
476
+ declare function renderChart(el: HTMLElement, options: ChartOptions): ChartInstance;
477
+ /** Everything from the module gathered, to expose as `V.charts`. */
478
+ declare const charts: {
479
+ render: typeof renderChart;
480
+ format: typeof formatChartValue;
481
+ colors: string[];
482
+ };
483
+
484
+ /**
485
+ * @module runtime/magics
486
+ *
487
+ * Magic variables: global values available inside any `v-*` expression,
488
+ * without needing to declare anything.
489
+ *
490
+ * ```html
491
+ * <button v-click="$toast.success('Saved!')">Save</button>
492
+ * <div v-show="$screen.mobile">You're on mobile</div>
493
+ * <p v-show="!$network.online">You're offline.</p>
494
+ * <span>{ $store.cart.total }</span>
495
+ * ```
496
+ */
497
+ declare const screen: {
498
+ width: number;
499
+ height: number;
500
+ mobile: boolean;
501
+ tablet: boolean;
502
+ desktop: boolean;
503
+ portrait: boolean;
504
+ landscape: boolean;
505
+ /** Check an arbitrary media query. */
506
+ matches(query: string): boolean;
507
+ };
508
+ declare const network: {
509
+ online: boolean;
510
+ /** Connection type reported by the browser, when available. */
511
+ type: string;
512
+ /** `true` when the user requested data saving mode. */
513
+ saveData: boolean;
514
+ slow: boolean;
515
+ };
516
+ declare const clipboard: {
517
+ /** Copy text, with fallback for browsers without the modern API. */
518
+ copy(text: string): Promise<boolean>;
519
+ /** Read clipboard content, when the user allows. */
520
+ read(): Promise<string>;
521
+ };
522
+
523
+ /**
524
+ * @module ui/dialog
525
+ *
526
+ * Accessible dialog engine: generic modal, `alert`, `confirm`, and `prompt`.
527
+ *
528
+ * All share the same core: darkened backdrop, scroll lock, focus trapped
529
+ * within the panel, focus restored on close, closing via Escape or backdrop
530
+ * click, entrance and exit animations, and stacking of multiple open dialogs
531
+ * at the same time.
532
+ *
533
+ * ```js
534
+ * V.modal.open('#login')
535
+ * await V.alert('File uploaded.')
536
+ * if (await V.confirm('Delete the order?')) remove()
537
+ * const name = await V.prompt('What should we call you?')
538
+ * ```
539
+ *
540
+ * ```html
541
+ * <button v-modal="#login">Sign in</button>
542
+ * <div id="login" v-modal-content>
543
+ * <h2>Sign in</h2>
544
+ * <button v-modal-close>Close</button>
545
+ * </div>
546
+ * <button v-confirm="Delete for real?" v-click="remove()">Delete</button>
547
+ * ```
548
+ */
549
+ /** Button texts and default messages, all configurable. */
550
+ interface DialogLabels {
551
+ confirm: string;
552
+ cancel: string;
553
+ ok: string;
554
+ close: string;
555
+ /** Message used by `v-confirm` when the attribute is empty. */
556
+ confirmQuestion: string;
557
+ /** Error shown by `prompt` when the required field is empty. */
558
+ required: string;
559
+ }
560
+ declare const settings: {
561
+ /** Duration of entrance and exit animation, in milliseconds. */
562
+ duration: number;
563
+ /** Default size of dialogs created by `dialog()`. */
564
+ size: DialogSize;
565
+ };
566
+ type DialogSize = 'sm' | 'md' | 'lg' | 'xl' | 'full';
567
+ type DialogTone = 'default' | 'success' | 'warning' | 'danger';
568
+ type DialogIcon = 'info' | 'success' | 'warning' | 'danger' | 'question' | 'none';
569
+ /** Common options for any dialog. */
570
+ interface ModalOptions {
571
+ /** Close when clicking the darkened backdrop. Default `true`. */
572
+ closeOnBackdrop?: boolean;
573
+ /** Close when pressing Escape. Default `true`. */
574
+ closeOnEscape?: boolean;
575
+ /** Maximum width of the panel. Default `md`. */
576
+ size?: DialogSize;
577
+ /** Vertical alignment. Default `center`. */
578
+ position?: 'center' | 'top';
579
+ /** Lock page scrolling while open. Default `true`. */
580
+ lockScroll?: boolean;
581
+ /** Restore focus to the previous element on close. Default `true`. */
582
+ restoreFocus?: boolean;
583
+ /** Show the close button in the corner. Default `true`. */
584
+ closable?: boolean;
585
+ /** Remove background, border, and shadow from the panel. */
586
+ plain?: boolean;
587
+ /** Extra classes applied to the panel. */
588
+ className?: string;
589
+ /** Selector or element that receives initial focus. */
590
+ initialFocus?: string | HTMLElement | null;
591
+ /** Label read by screen readers when there is no visible title. */
592
+ ariaLabel?: string;
593
+ onOpen?(handle: DialogHandle): void;
594
+ onClose?(result: unknown, handle: DialogHandle): void;
595
+ }
596
+ /** Control of an open dialog. */
597
+ interface DialogHandle {
598
+ id: string;
599
+ /** Fixed layer covering the screen. */
600
+ root: HTMLElement;
601
+ /** Panel where the content appears. */
602
+ panel: HTMLElement;
603
+ /** Panel body, useful for injecting content after opening. */
604
+ body: HTMLElement;
605
+ /** Key used by `modal.close('#login')`. */
606
+ key: string | null;
607
+ /** Page element adopted by the dialog, if any. */
608
+ source: HTMLElement | null;
609
+ /** Close the dialog, resolving `closed` with the result. */
610
+ close(result?: unknown): void;
611
+ /** Resolved when the dialog finishes closing. */
612
+ closed: Promise<unknown>;
613
+ }
614
+ /**
615
+ * Control of modals created from elements already on the page.
616
+ *
617
+ * ```js
618
+ * V.modal.open('#login', { size: 'sm' })
619
+ * V.modal.close('#login')
620
+ * V.modal.isOpen()
621
+ * ```
622
+ */
623
+ declare const modal: {
624
+ /** Open a page element as a modal. Accepts a selector or the element itself. */
625
+ open(target: string | HTMLElement, options?: ModalOptions): DialogHandle | null;
626
+ /** Close the indicated modal, or the one at the top of the stack. */
627
+ close(target?: string | HTMLElement, result?: unknown): void;
628
+ /** Close all open dialogs, from top to bottom. */
629
+ closeAll(result?: unknown): void;
630
+ /** Open if closed, close if open. */
631
+ toggle(target: string | HTMLElement, options?: ModalOptions): DialogHandle | null;
632
+ /** Check if a specific modal, or any, is open. */
633
+ isOpen(target?: string | HTMLElement): boolean;
634
+ /** Open dialogs, from oldest to newest. */
635
+ readonly opened: DialogHandle[];
636
+ /** Number of open dialogs. */
637
+ readonly count: number;
638
+ /** Adjust animation duration and default size. */
639
+ configure(options: Partial<typeof settings>): void;
640
+ /** Change the default button texts. */
641
+ labels(next: Partial<DialogLabels>): DialogLabels;
642
+ };
643
+ /** Button shown in a dialog footer. */
644
+ interface DialogButton {
645
+ label: string;
646
+ /** Value delivered by the promise when this button is clicked. */
647
+ value?: unknown;
648
+ variant?: 'primary' | 'secondary' | 'ghost' | 'danger' | 'success';
649
+ /** Close the dialog on click. Default `true`. */
650
+ close?: boolean;
651
+ /** Receive focus as soon as the dialog opens. */
652
+ autofocus?: boolean;
653
+ /** Execute before closing. Return `false` to keep the dialog open. */
654
+ onClick?(handle: DialogHandle): unknown;
655
+ }
656
+ /** Options for `V.dialog()`. */
657
+ interface DialogOptions extends ModalOptions {
658
+ title?: string;
659
+ description?: string;
660
+ /** Plain text body, inserted without interpreting HTML. */
661
+ text?: string;
662
+ /** Body HTML. Use only with your own content. */
663
+ html?: string;
664
+ /** Ready node to become the body, useful for hand-built forms. */
665
+ node?: Node;
666
+ buttons?: DialogButton[];
667
+ icon?: DialogIcon;
668
+ tone?: DialogTone;
669
+ }
670
+ /**
671
+ * Generic dialog with title, description, content, and buttons.
672
+ *
673
+ * ```js
674
+ * const choice = await V.dialog({
675
+ * title: 'Publish now?',
676
+ * description: 'The change will be visible to everyone.',
677
+ * buttons: [
678
+ * { label: 'Cancel', variant: 'secondary', value: null },
679
+ * { label: 'Publish', variant: 'primary', value: 'publish', autofocus: true }
680
+ * ]
681
+ * })
682
+ * ```
683
+ *
684
+ * @returns the `value` of the clicked button, or `null` when the dialog is dismissed
685
+ */
686
+ declare function dialog<T = unknown>(options: DialogOptions): Promise<T | null>;
687
+ /** Options for `V.alert()`. */
688
+ interface AlertOptions extends ModalOptions {
689
+ title?: string;
690
+ description?: string;
691
+ icon?: DialogIcon;
692
+ tone?: DialogTone;
693
+ /** Text of the single button. Default `OK`. */
694
+ confirmLabel?: string;
695
+ }
696
+ /**
697
+ * Alert with a single button.
698
+ *
699
+ * ```js
700
+ * await V.alert('Order sent successfully.', { icon: 'success' })
701
+ * ```
702
+ */
703
+ declare function alert(message: string, options?: AlertOptions): Promise<void>;
704
+ /** Options for `V.confirm()`. */
705
+ interface ConfirmOptions extends ModalOptions {
706
+ title?: string;
707
+ description?: string;
708
+ icon?: DialogIcon;
709
+ tone?: DialogTone;
710
+ confirmLabel?: string;
711
+ cancelLabel?: string;
712
+ /** Shortcut for `tone: 'danger'`, with red button. */
713
+ danger?: boolean;
714
+ }
715
+ /**
716
+ * Yes or no question.
717
+ *
718
+ * ```js
719
+ * if (await V.confirm('Delete the order?', { danger: true })) remove()
720
+ * ```
721
+ */
722
+ declare function confirm(message: string, options?: ConfirmOptions): Promise<boolean>;
723
+ /** Types accepted by the `prompt` field. */
724
+ type PromptType = 'text' | 'password' | 'email' | 'number' | 'textarea';
725
+ /** Options for `V.prompt()`. */
726
+ interface PromptOptions extends ModalOptions {
727
+ title?: string;
728
+ description?: string;
729
+ icon?: DialogIcon;
730
+ type?: PromptType;
731
+ /** Initial field value. */
732
+ value?: string;
733
+ placeholder?: string;
734
+ hint?: string;
735
+ required?: boolean;
736
+ confirmLabel?: string;
737
+ cancelLabel?: string;
738
+ /** Return a message to block submission, or `null` to allow. */
739
+ validate?(value: string): string | null | undefined;
740
+ }
741
+ /**
742
+ * Question expecting text input. The field opens focused and validation keeps
743
+ * the dialog open until the value is accepted.
744
+ *
745
+ * ```js
746
+ * const email = await V.prompt('Contact email', {
747
+ * type: 'email',
748
+ * required: true,
749
+ * validate: (v) => v.includes('@') ? null : 'Please enter a valid email.'
750
+ * })
751
+ * ```
752
+ *
753
+ * @returns the typed text, or `null` when the user cancels
754
+ */
755
+ declare function prompt(label: string, options?: PromptOptions): Promise<string | null>;
756
+
757
+ /**
758
+ * @module ui/palette
759
+ *
760
+ * Voodoo's configurable palette. From a few base colors, the function generates
761
+ * the complete scale of tones (50 to 900), the dark theme version, and the text
762
+ * color with the best contrast over each color, all written as CSS variables in
763
+ * `:root`.
764
+ *
765
+ * The calculation happens in OKLCH, a perceptually uniform color space: steps with
766
+ * the same difference in luminance appear equally distant to the eye, which does not
767
+ * happen in HSL. The text color uses the real WCAG relative luminance calculation,
768
+ * so the result is always readable.
769
+ *
770
+ * ```js
771
+ * V.palette({ primary: '#6D3BF5', accent: '#FF3D8B', radius: '12px', font: 'Inter' })
772
+ * V.palette({ preset: 'ocean' })
773
+ * ```
774
+ */
775
+ /** Color in sRGB space, with channels from 0 to 255. */
776
+ interface RgbColor {
777
+ r: number;
778
+ g: number;
779
+ b: number;
780
+ }
781
+ /** Color in OKLCH: perceptual luminance (0 to 1), chroma and hue in degrees. */
782
+ interface OklchColor {
783
+ l: number;
784
+ c: number;
785
+ h: number;
786
+ }
787
+ /**
788
+ * Read a color written as `#abc`, `#aabbcc`, `rgb(...)` or `hsl(...)`.
789
+ * Returns `null` when the text does not describe a known color.
790
+ */
791
+ declare function parseColor(input: string): RgbColor | null;
792
+ /** Convert sRGB to OKLCH. */
793
+ declare function rgbToOklch(color: RgbColor): OklchColor;
794
+ /**
795
+ * Convert OKLCH to sRGB. Colors outside the monitor's gamut gradually lose chroma
796
+ * until they fit, which preserves hue and luminance instead of clipping channels
797
+ * and changing the perceived color.
798
+ */
799
+ declare function oklchToRgb(color: OklchColor): RgbColor;
800
+ /** Write an sRGB color as `#rrggbb`. */
801
+ declare function toHex(color: RgbColor): string;
802
+ /** Write an sRGB color as `rgba(r, g, b, alpha)`. */
803
+ declare function toRgba(color: RgbColor, alpha: number): string;
804
+ /** WCAG contrast ratio between two colors, from 1 to 21. */
805
+ declare function contrastRatio(a: RgbColor | string, b: RgbColor | string): number;
806
+ /**
807
+ * Choose black or white for text over the given color, comparing the real
808
+ * contrast ratio of the two options.
809
+ */
810
+ declare function contrastText(color: RgbColor | string): string;
811
+ /** Scale of tones for a color, with steps from 50 to 900. */
812
+ type ColorScale = Record<string, string>;
813
+ /**
814
+ * Generate the scale for a base color.
815
+ *
816
+ * @param color base color in any format accepted by `parseColor`
817
+ * @param dark when `true`, generates the dark theme scale (inverted roles)
818
+ */
819
+ declare function colorScale(color: string | RgbColor, dark?: boolean): ColorScale;
820
+ /** Set of base colors for a preset. */
821
+ interface PaletteColors {
822
+ primary: string;
823
+ accent: string;
824
+ success: string;
825
+ warning: string;
826
+ danger: string;
827
+ info: string;
828
+ /** Color that tints backgrounds, texts, and borders. Default: hue of primary. */
829
+ neutral?: string;
830
+ }
831
+ /** Names of ready-made presets. */
832
+ type PresetName = 'violeta' | 'oceano' | 'floresta' | 'poente' | 'grafite';
833
+ /** Options accepted by `V.palette()`. */
834
+ interface PaletteOptions extends Partial<PaletteColors> {
835
+ /** Preset used as starting point. Provided colors override it. */
836
+ preset?: PresetName;
837
+ /** Border radius, like `12px` or `0.75rem`. */
838
+ radius?: string;
839
+ /** Primary font family. The page remains responsible for loading the font. */
840
+ font?: string;
841
+ /** Monospaced font family used by `VCodeBlock`. */
842
+ monoFont?: string;
843
+ /** Save the choice in localStorage. Default `true`. */
844
+ persist?: boolean;
845
+ }
846
+ /** Resolved palette, with all scales calculated. */
847
+ interface ResolvedPalette {
848
+ colors: PaletteColors;
849
+ radius: string;
850
+ font: string;
851
+ monoFont: string;
852
+ /** Light theme scales, by color name. */
853
+ light: Record<string, ColorScale>;
854
+ /** Dark theme scales, by color name. */
855
+ dark: Record<string, ColorScale>;
856
+ /** Text color over each base color, calculated by WCAG. */
857
+ contrast: Record<string, string>;
858
+ css: string;
859
+ }
860
+ /**
861
+ * Apply a palette. Generates the scales, writes CSS variables to `:root`,
862
+ * creates dark theme versions, and saves the choice in localStorage.
863
+ *
864
+ * ```js
865
+ * V.palette({ primary: '#6D3BF5', accent: '#FF3D8B', radius: '12px', font: 'Inter' })
866
+ * ```
867
+ *
868
+ * @returns the resolved palette, with scales and generated CSS
869
+ */
870
+ declare function applyPalette(options?: PaletteOptions): ResolvedPalette;
871
+ /**
872
+ * Apply the palette saved in localStorage, or the default preset when there is no
873
+ * previous choice. Called automatically by UI components.
874
+ */
875
+ declare function initPalette(): ResolvedPalette;
876
+ /** Ensure that palette variables exist before any component. */
877
+ declare function ensurePalette(): void;
878
+ /**
879
+ * Voodoo's palette. Call as a function to apply, or use the attached utilities
880
+ * to inspect colors and contrast.
881
+ *
882
+ * ```js
883
+ * V.palette({ preset: 'oceano' })
884
+ * V.palette.scale('#6D3BF5')['700']
885
+ * V.palette.contrastText('#FFB35C') // '#000000'
886
+ * ```
887
+ */
888
+ declare const palette: typeof applyPalette & {
889
+ /** Ready-made presets, indexed by name. */
890
+ presets: Record<PresetName, PaletteColors>;
891
+ /** Names of available presets. */
892
+ readonly names: PresetName[];
893
+ /** Palette in use, or `null` before the first application. */
894
+ readonly current: ResolvedPalette | null;
895
+ /** Options used in the last application. */
896
+ readonly options: PaletteOptions | null;
897
+ /** Apply the saved palette, or the default when there is nothing saved. */
898
+ init: typeof initPalette;
899
+ /** Ensure variables exist, without overwriting what has already been applied. */
900
+ ensure: typeof ensurePalette;
901
+ /** Return to the default preset and clear the saved choice. */
902
+ reset(): ResolvedPalette;
903
+ /** Change only the preset, maintaining current radius and font. */
904
+ use(name: PresetName): ResolvedPalette;
905
+ /** Scale of tones for any color. */
906
+ scale: typeof colorScale;
907
+ /** Black or white, depending on the best WCAG contrast over the color. */
908
+ contrastText: typeof contrastText;
909
+ /** WCAG contrast ratio between two colors. */
910
+ contrastRatio: typeof contrastRatio;
911
+ /** WCAG relative luminance of a color. */
912
+ luminance(color: string | RgbColor): number;
913
+ /** Converters exposed for those who want to generate derived colors. */
914
+ convert: {
915
+ parseColor: typeof parseColor;
916
+ rgbToOklch: typeof rgbToOklch;
917
+ oklchToRgb: typeof oklchToRgb;
918
+ toHex: typeof toHex;
919
+ toRgba: typeof toRgba;
920
+ };
921
+ };
922
+
923
+ /**
924
+ * @module router
925
+ *
926
+ * Single-page application router with no external dependencies.
927
+ *
928
+ * Two modes: `history`, which uses the History API and clean URLs, and `hash`, which
929
+ * stores the route after `#` and works even when opening the file directly from disk.
930
+ *
931
+ * ```js
932
+ * V.router({
933
+ * mode: 'history',
934
+ * base: '/',
935
+ * routes: {
936
+ * '/': { component: 'home', title: 'Inicio' },
937
+ * '/usuarios': { component: 'users' },
938
+ * '/usuarios/:id': { component: 'user-detail' },
939
+ * '/posts/:slug?': { view: '/partials/post.html' },
940
+ * '*': { component: 'not-found' }
941
+ * },
942
+ * beforeEach(to, from) { return true },
943
+ * afterEach(to, from) {}
944
+ * })
945
+ * ```
946
+ *
947
+ * ```html
948
+ * <nav>
949
+ * <a v-link href="/">Inicio</a>
950
+ * <a v-link href="/usuarios">Usuarios</a>
951
+ * </nav>
952
+ * <main v-router-view>Carregando...</main>
953
+ * ```
954
+ */
955
+ /** Definition of a route, associated with a pattern like `/usuarios/:id`. */
956
+ interface RouteRecord {
957
+ /** Name of the registered component that will be mounted inside `v-router-view`. */
958
+ component?: string;
959
+ /** URL of remote HTML loaded and inserted in place of the component. */
960
+ view?: string;
961
+ /** Title applied to `document.title` when entering the route. */
962
+ title?: string;
963
+ /** Route name, useful for `$route.name` and for navigation by name. */
964
+ name?: string;
965
+ /** Free-form data of the route, available in `$route.meta`. */
966
+ meta?: Record<string, unknown>;
967
+ /** Redirects to another path as soon as the route matches. */
968
+ redirect?: string;
969
+ /** Guard exclusive to this route, executed before the global `beforeEach`. */
970
+ beforeEnter?: NavigationGuard;
971
+ }
972
+ /** Current route state. It is the object exposed by `$route`. */
973
+ interface RouteLocation {
974
+ /** Path without query and without hash, always starting with a slash. */
975
+ path: string;
976
+ /** Full path, with query and hash. */
977
+ fullPath: string;
978
+ /** Parameters extracted from the pattern, like `{ id: '42' }`. */
979
+ params: Record<string, string>;
980
+ /** Query string already converted to an object. */
981
+ query: Record<string, string>;
982
+ /** URL anchor, without the `#`. */
983
+ hash: string;
984
+ /** Name declared in the matched route. */
985
+ name: string;
986
+ /** Metadata declared in the matched route. */
987
+ meta: Record<string, unknown>;
988
+ /** Pattern that matched, like `/usuarios/:id`. `null` when nothing matched. */
989
+ matched: string | null;
990
+ }
991
+ /**
992
+ * Navigation guard. Return `false` to cancel, a string to redirect,
993
+ * or `true`, `undefined`, or nothing to allow passage.
994
+ */
995
+ type NavigationGuard = (to: RouteLocation, from: RouteLocation) => boolean | string | void | Promise<boolean | string | void>;
996
+ /** Hook executed after navigation is completed. */
997
+ type NavigationHook = (to: RouteLocation, from: RouteLocation) => void;
998
+ /**
999
+ * Scroll control. Return the desired vertical position, or `false` to
1000
+ * handle scrolling manually.
1001
+ */
1002
+ type ScrollBehavior = (to: RouteLocation, from: RouteLocation, saved: number | null) => number | false | void;
1003
+ interface RouterOptions {
1004
+ /** `history` uses clean URLs, `hash` stores the route after `#`. */
1005
+ mode?: 'history' | 'hash';
1006
+ /** Common prefix for all routes in `history` mode. Default `/`. */
1007
+ base?: string;
1008
+ /** Map of pattern to route definition. */
1009
+ routes: Record<string, RouteRecord>;
1010
+ /** Global guard executed before each navigation. */
1011
+ beforeEach?: NavigationGuard;
1012
+ /** Global hook executed after each navigation. */
1013
+ afterEach?: NavigationHook;
1014
+ /** Class applied by `v-link` when the route starts with the target. */
1015
+ linkActiveClass?: string;
1016
+ /** Class applied by `v-link` when the route is exactly the target. */
1017
+ linkExactActiveClass?: string;
1018
+ /** Uses the View Transitions API when switching pages. Default `true`. */
1019
+ transition?: boolean;
1020
+ /** Title template, with `%s` in place of the route title. */
1021
+ titleTemplate?: string;
1022
+ /** Fine control of scrolling after each navigation. */
1023
+ scrollBehavior?: ScrollBehavior;
1024
+ }
1025
+ interface NavigateOptions {
1026
+ /** Replaces the current history entry instead of stacking a new one. */
1027
+ replace?: boolean;
1028
+ /** Extra state saved in the history entry. */
1029
+ state?: Record<string, unknown>;
1030
+ /** Disables automatic scrolling for this navigation. */
1031
+ scroll?: boolean;
1032
+ /** Navigates even when the target is the same as the current route. */
1033
+ force?: boolean;
1034
+ }
1035
+ /**
1036
+ * Current route, reactive. Any expression that reads `$route` updates itself
1037
+ * when navigation happens.
1038
+ */
1039
+ declare const route: RouteLocation;
1040
+ /**
1041
+ * Navigates to a path without reloading the page.
1042
+ *
1043
+ * ```js
1044
+ * await V.navigate('/usuarios/42')
1045
+ * await V.navigate('/login', { replace: true })
1046
+ * ```
1047
+ *
1048
+ * @returns `true` when navigation happened, `false` when a guard canceled.
1049
+ */
1050
+ declare function navigate(target: string, options?: NavigateOptions): Promise<boolean>;
1051
+ interface RouterApi {
1052
+ (options: RouterOptions): RouterApi;
1053
+ /** Current route, reactive. */
1054
+ readonly current: RouteLocation;
1055
+ /** Stacks a new entry in history. */
1056
+ push(target: string, options?: NavigateOptions): Promise<boolean>;
1057
+ /** Replaces the current history entry. */
1058
+ replace(target: string, options?: NavigateOptions): Promise<boolean>;
1059
+ /** Alias of `push`, same function exposed in `V.navigate`. */
1060
+ navigate(target: string, options?: NavigateOptions): Promise<boolean>;
1061
+ /** Goes back one entry in history. */
1062
+ back(): void;
1063
+ /** Goes forward one entry in history. */
1064
+ forward(): void;
1065
+ /** Goes `delta` entries in history. */
1066
+ go(delta: number): void;
1067
+ /** Resolves a destination without navigating. */
1068
+ resolve(target: string): RouteLocation;
1069
+ addRoute(pattern: string, record: RouteRecord): void;
1070
+ removeRoute(pattern: string): void;
1071
+ /** Registered patterns, from most specific to least specific. */
1072
+ patterns(): string[];
1073
+ /** Disconnects the history listeners. */
1074
+ stop(): void;
1075
+ clearViewCache(url?: string): void;
1076
+ /** `true` after `V.router({...})` is called. */
1077
+ readonly ready: boolean;
1078
+ }
1079
+ declare const router: RouterApi;
1080
+
1081
+ /**
1082
+ * @module i18n
1083
+ *
1084
+ * Reactive internationalization. Changing the language doesn't reload the page: all text
1085
+ * that went through `t()` and all number, currency, and date formatters update themselves
1086
+ * because everything reads the same reactive state.
1087
+ *
1088
+ * ```js
1089
+ * V.i18n({
1090
+ * locale: 'pt-BR',
1091
+ * fallback: 'en',
1092
+ * messages: {
1093
+ * 'pt-BR': { comum: { salvar: 'Salvar' }, itens: 'nenhum item | {n} item | {n} itens' },
1094
+ * 'en': { comum: { salvar: 'Save' } }
1095
+ * }
1096
+ * })
1097
+ * ```
1098
+ *
1099
+ * ```html
1100
+ * <button v-t="comum.salvar"></button>
1101
+ * <span v-t="itens" v-t-params="{ n: carrinho.length }"></span>
1102
+ * <abbr v-t:title="comum.dica">?</abbr>
1103
+ * <button v-locale="en">English</button>
1104
+ * <span>{ $t('comum.salvar') } em { $locale }</span>
1105
+ * ```
1106
+ */
1107
+ /** Message tree for a language. Accepts nesting at any level. */
1108
+ interface MessageTree {
1109
+ [key: string]: string | MessageTree;
1110
+ }
1111
+ /** Values used in the interpolation of `{key}`. */
1112
+ type TranslateParams = Record<string, unknown> | number;
1113
+ interface I18nOptions {
1114
+ /** Initial language. Loses to the saved language and to the detected language. */
1115
+ locale?: string;
1116
+ /** Language used when the key doesn't exist in the current language. */
1117
+ fallback?: string;
1118
+ /** Messages per language. */
1119
+ messages?: Record<string, MessageTree>;
1120
+ /** Default currency of `c()`. Falls to `config.currency`. */
1121
+ currency?: string;
1122
+ /** Saves the chosen language in localStorage. Default `true`. */
1123
+ persist?: boolean | string;
1124
+ /** Detects the browser's language when nothing was saved. Default `true`. */
1125
+ detect?: boolean;
1126
+ /** URL template for on-demand loading, with `{locale}`. */
1127
+ loadPath?: string;
1128
+ }
1129
+ /**
1130
+ * Translates a key in the current language.
1131
+ *
1132
+ * The search tries the current language, then similar languages, then the fallback,
1133
+ * and if nothing exists, returns the key itself, which is always better than empty
1134
+ * text on the screen.
1135
+ *
1136
+ * ```js
1137
+ * t('comum.salvar') // 'Salvar'
1138
+ * t('ola', { nome: 'Ana' }) // 'Ola, Ana!'
1139
+ * t('itens', { n: 3 }) // '3 itens'
1140
+ * t('itens', 3) // shortcut for the same case
1141
+ * ```
1142
+ */
1143
+ declare function t(key: string, params?: TranslateParams): string;
1144
+ /** `true` when the key exists in the current language or in the fallback. */
1145
+ declare function te(key: string, locale?: string): boolean;
1146
+ /** Formats a number in the current language. */
1147
+ declare function n(value: number | string, options?: Intl.NumberFormatOptions): string;
1148
+ /** Formats a value as currency in the current language. */
1149
+ declare function c(value: number | string, currency?: string): string;
1150
+ /** Formats a date in the current language. Accepts preset or text mask. */
1151
+ declare function d(value: Date | string | number, format?: string | Intl.DateTimeFormatOptions): string;
1152
+ /** Relative time in the current language, like 'ha 5 minutos'. */
1153
+ declare function rt(value: Date | string | number): string;
1154
+ /** Active language. */
1155
+ declare function getLocale(): string;
1156
+ /** Messages of a language, or of the current language when none is provided. */
1157
+ declare function messagesOf(locale?: string): MessageTree;
1158
+ /**
1159
+ * Adds messages to a language, merging with what already exists.
1160
+ * Returns the language itself, for chaining.
1161
+ */
1162
+ declare function addMessages(locale: string, messages: MessageTree): string;
1163
+ /**
1164
+ * Loads messages on demand.
1165
+ *
1166
+ * ```js
1167
+ * await V.i18n.loadMessages('es', '/i18n/es.json')
1168
+ * await V.i18n.loadMessages('es', { comum: { salvar: 'Guardar' } })
1169
+ * ```
1170
+ */
1171
+ declare function loadMessages(locale: string, source: string | MessageTree): Promise<void>;
1172
+ /**
1173
+ * Changes the active language. The entire page updates immediately without reloading.
1174
+ *
1175
+ * When `loadPath` was configured and the language doesn't have messages yet, the file
1176
+ * is fetched in the background and the promise resolves when it arrives.
1177
+ */
1178
+ declare function setLocale(locale: string): Promise<void>;
1179
+ /**
1180
+ * Chooses the best browser language among those that exist.
1181
+ * Returns `null` when no browser language has messages.
1182
+ */
1183
+ declare function detectLocale(): string | null;
1184
+ interface I18nApi {
1185
+ (options?: I18nOptions): I18nApi;
1186
+ /** Active language, reactive when read within an effect. */
1187
+ readonly locale: string;
1188
+ /** Language used when the key doesn't exist in the current language. */
1189
+ readonly fallback: string;
1190
+ /** Languages with loaded messages. */
1191
+ readonly locales: string[];
1192
+ t: typeof t;
1193
+ te: typeof te;
1194
+ n: typeof n;
1195
+ c: typeof c;
1196
+ d: typeof d;
1197
+ rt: typeof rt;
1198
+ setLocale: typeof setLocale;
1199
+ getLocale: typeof getLocale;
1200
+ addMessages: typeof addMessages;
1201
+ loadMessages: typeof loadMessages;
1202
+ messagesOf: typeof messagesOf;
1203
+ detectLocale: typeof detectLocale;
1204
+ }
1205
+ /**
1206
+ * The i18n object is a callable function that also loads the API. Dynamic accesses
1207
+ * are copied with getOwnPropertyDescriptors, which keeps each getter alive. With
1208
+ * Object.assign they would be executed once and the language would be frozen at
1209
+ * the initial value.
1210
+ */
1211
+ declare const i18n: I18nApi;
1212
+
1213
+ /**
1214
+ * @module forms/validate
1215
+ *
1216
+ * Validation engine with extensible rule registration, messages in Portuguese,
1217
+ * and automatic error presentation in HTML.
1218
+ *
1219
+ * ```html
1220
+ * <form v-submit="/api/users" v-validate>
1221
+ * <input name="email" v-required v-email>
1222
+ * <input name="cpf" v-cpf v-error-message="Informe um CPF real.">
1223
+ * </form>
1224
+ * ```
1225
+ */
1226
+ /** Elements that validation understands as form fields. */
1227
+ type FormField = HTMLInputElement | HTMLTextAreaElement | HTMLSelectElement;
1228
+ /** Rule result: `true` approves, `false` rejects, text rejects with message. */
1229
+ type ValidatorResult = boolean | string;
1230
+ /** Rule function. Receives the value as text, parameter, and the field itself. */
1231
+ type ValidatorFn = (value: string, param: string | undefined, el: FormField) => ValidatorResult | Promise<ValidatorResult>;
1232
+ interface FieldValidationResult {
1233
+ valid: boolean;
1234
+ message?: string;
1235
+ rule?: string;
1236
+ }
1237
+ interface FormValidationResult {
1238
+ valid: boolean;
1239
+ errors: Record<string, string>;
1240
+ }
1241
+ interface SerializeOptions {
1242
+ /** Force output as `FormData`, even without files. */
1243
+ formData?: boolean;
1244
+ /** Include disabled fields. Default `false`. */
1245
+ includeDisabled?: boolean;
1246
+ /** Remove spaces at text ends. Default `true`. */
1247
+ trim?: boolean;
1248
+ /** Convert numeric fields to `number`. Default `true`. */
1249
+ numbers?: boolean;
1250
+ }
1251
+ /**
1252
+ * Registers a validation rule and creates the `v-validate-<name>` directive.
1253
+ *
1254
+ * ```js
1255
+ * V.validator('par', (value) => Number(value) % 2 === 0, 'Informe um numero par.')
1256
+ * ```
1257
+ */
1258
+ declare function validator(name: string, fn: ValidatorFn, defaultMessage?: string): void;
1259
+ /** Clears all visible errors from a form. */
1260
+ declare function clearErrors(form: HTMLElement): void;
1261
+ /**
1262
+ * Applies server errors to the HTML. Messages without a corresponding field
1263
+ * appear in a summary at the top of the form.
1264
+ */
1265
+ declare function showFormErrors(form: HTMLElement, errors: unknown): Record<string, string>;
1266
+ /**
1267
+ * General shortcut: validates an entire form or a single field, deciding
1268
+ * based on the element type received.
1269
+ *
1270
+ * ```js
1271
+ * await V.validate(document.forms[0]) // { valid, errors }
1272
+ * await V.validate(document.querySelector('#email')) // { valid, message }
1273
+ * ```
1274
+ */
1275
+ declare function validate(target: HTMLElement | FormField): Promise<FormValidationResult | FieldValidationResult>;
1276
+ /**
1277
+ * Transforms the form into a JavaScript object, respecting names like
1278
+ * `user[address][street]` and `tags[]`. Returns `FormData` when a file is
1279
+ * selected or when `options.formData` is true.
1280
+ */
1281
+ declare function serializeForm(form: HTMLElement, options?: SerializeOptions): Record<string, unknown> | FormData;
1282
+
1283
+ /**
1284
+ * @module forms/mask
1285
+ *
1286
+ * Input masks that preserve cursor position, even when the user edits the middle
1287
+ * of text or deletes a separator.
1288
+ *
1289
+ * ```html
1290
+ * <input v-mask="cpf">
1291
+ * <input v-mask="(99) 99999-9999">
1292
+ * <input v-mask.unmask="cpf" v-model="form.cpf">
1293
+ * <input v-mask-currency="R$ " v-mask-decimals="2">
1294
+ * ```
1295
+ */
1296
+ /** Function that formats a raw value. Used by dynamic masks. */
1297
+ type MaskResolver = (value: string) => string;
1298
+ /** A mask is either a character pattern or a formatting function. */
1299
+ type MaskPattern = string | MaskResolver;
1300
+ /** Named masks available for `v-mask` and `applyMask`. */
1301
+ declare const masks: Map<string, MaskPattern>;
1302
+ /**
1303
+ * Registers a named mask.
1304
+ *
1305
+ * ```js
1306
+ * V.registerMask('processo', '9999999-99.9999.9.99.9999')
1307
+ * V.registerMask('reverso', (v) => v.split('').reverse().join(''))
1308
+ * ```
1309
+ */
1310
+ declare function registerMask(name: string, patternOrFn: MaskPattern): void;
1311
+ interface CurrencyMaskOptions {
1312
+ /** Text before the number. Default `R$ `. */
1313
+ prefix?: string;
1314
+ /** Text after the number. */
1315
+ suffix?: string;
1316
+ /** Decimal places. Default `2`. */
1317
+ decimals?: number;
1318
+ /** Decimal separator. Default `,`. */
1319
+ decimal?: string;
1320
+ /** Thousands separator. Default `.`. */
1321
+ thousands?: string;
1322
+ }
1323
+ /**
1324
+ * Formats a value as currency, typing right-to-left.
1325
+ *
1326
+ * ```js
1327
+ * V.maskCurrency('123456') // 'R$ 1.234,56'
1328
+ * ```
1329
+ */
1330
+ declare function maskCurrency(value: string, options?: CurrencyMaskOptions): string;
1331
+ /** Formats percentage with two decimal places in the same style as currency. */
1332
+ declare function maskPercent(value: string, decimals?: number): string;
1333
+ /**
1334
+ * Applies a mask to a value. The pattern can be a registered mask name or
1335
+ * a character pattern.
1336
+ *
1337
+ * Tokens: `9` digit, `A` letter, `S` alphanumeric, `*` any character, `\` escape.
1338
+ *
1339
+ * ```js
1340
+ * V.applyMask('12345678901', 'cpf') // '123.456.789-01'
1341
+ * V.applyMask('1234', '99-99') // '12-34'
1342
+ * ```
1343
+ */
1344
+ declare function applyMask(value: string, pattern: string): string;
1345
+ /**
1346
+ * Removes formatting. For numeric masks, returns the number as text,
1347
+ * ready to become a `Number`.
1348
+ *
1349
+ * ```js
1350
+ * V.unmask('123.456.789-01') // '12345678901'
1351
+ * V.unmask('R$ 1.234,56', 'currency') // '1234.56'
1352
+ * ```
1353
+ */
1354
+ declare function unmask(value: string, pattern?: string): string;
1355
+ /**
1356
+ * Public shortcut to masks. Can be called as a function and also loads the
1357
+ * module utilities.
1358
+ *
1359
+ * ```js
1360
+ * V.mask('12345678901', 'cpf') // '123.456.789-01'
1361
+ * V.mask.register('placa', 'AAA9A99')
1362
+ * V.mask.currency('123456') // 'R$ 1.234,56'
1363
+ * ```
1364
+ */
1365
+ declare const mask: ((value: string, pattern: string) => string) & {
1366
+ apply: typeof applyMask;
1367
+ unmask: typeof unmask;
1368
+ register: typeof registerMask;
1369
+ currency: typeof maskCurrency;
1370
+ percent: typeof maskPercent;
1371
+ presets: Map<string, MaskPattern>;
1372
+ };
1373
+
1374
+ /**
1375
+ * @module devtools/bus
1376
+ *
1377
+ * Event bus for devtools. Lives in a separate file from the inspector to remain
1378
+ * tree-shakeable: code that only reports activity pays minimal bytes, and the
1379
+ * visual panel only enters the bundle when `xray()` is actually imported.
1380
+ *
1381
+ * Emitting with no registered listeners costs a `Map` lookup and nothing more,
1382
+ * so any module can report activity safely.
1383
+ *
1384
+ * ```ts
1385
+ * import { devtoolsBus } from '../devtools/bus';
1386
+ *
1387
+ * // Reporting a network request from a directive:
1388
+ * const start = performance.now();
1389
+ * const data = await http.get('/api/users');
1390
+ * devtoolsBus.emit('network', {
1391
+ * method: 'GET',
1392
+ * url: '/api/users',
1393
+ * status: 200,
1394
+ * ok: true,
1395
+ * duration: performance.now() - start,
1396
+ * source: 'v-get',
1397
+ * });
1398
+ * ```
1399
+ */
1400
+ /** Network request reported to the devtools Network tab. */
1401
+ interface DevtoolsNetworkEvent {
1402
+ /** HTTP method in uppercase, like `GET` or `POST`. */
1403
+ method: string;
1404
+ /** Final URL of the request. */
1405
+ url: string;
1406
+ /** Status code, when the response arrived. */
1407
+ status?: number;
1408
+ /** `true` when the response was successful. */
1409
+ ok?: boolean;
1410
+ /** Duration in milliseconds. */
1411
+ duration?: number;
1412
+ /** Error message, when the request failed. */
1413
+ error?: string;
1414
+ /** Who triggered it, like `v-get`, `http` or `router`. */
1415
+ source?: string;
1416
+ }
1417
+ /** DOM event triggered by a directive, shown in the Events tab. */
1418
+ interface DevtoolsDomEvent {
1419
+ /** Event name, like `click` or `submit`. */
1420
+ type: string;
1421
+ /** Element that received the event. */
1422
+ el?: Element | null;
1423
+ /** Expression or detail associated, for display purposes only. */
1424
+ detail?: unknown;
1425
+ /** Who reported it, like `v-on` or `component.emit`. */
1426
+ source?: string;
1427
+ }
1428
+ /** Route change reported by the router. */
1429
+ interface DevtoolsNavigationEvent {
1430
+ from: string;
1431
+ to: string;
1432
+ /** `true` when a guard cancelled the navigation. */
1433
+ cancelled?: boolean;
1434
+ /** Matched route pattern, if any. */
1435
+ matched?: string | null;
1436
+ }
1437
+ /** Locale change reported by the i18n module. */
1438
+ interface DevtoolsLocaleEvent {
1439
+ from: string;
1440
+ to: string;
1441
+ }
1442
+ /** Reactive update reported manually by a module. */
1443
+ interface DevtoolsUpdateEvent {
1444
+ el?: Element | null;
1445
+ /** Name of the key that changed, when known. */
1446
+ key?: string;
1447
+ source?: string;
1448
+ }
1449
+ /** Map of event types accepted by the bus. */
1450
+ interface DevtoolsEventMap {
1451
+ network: DevtoolsNetworkEvent;
1452
+ event: DevtoolsDomEvent;
1453
+ navigation: DevtoolsNavigationEvent;
1454
+ locale: DevtoolsLocaleEvent;
1455
+ update: DevtoolsUpdateEvent;
1456
+ }
1457
+ type DevtoolsEventType = keyof DevtoolsEventMap;
1458
+ /**
1459
+ * Simple publish-subscribe bus used by devtools.
1460
+ *
1461
+ * To report a network request from another module, emit the `network` type
1462
+ * with `{ method, url, status, ok, duration, source }`. The devtools Network
1463
+ * tab lists everything that arrives through it, even when the request did not
1464
+ * go through Voodoo's `http` client.
1465
+ */
1466
+ declare const devtoolsBus: {
1467
+ /** Publishes an event. With no listeners, the call is practically free. */
1468
+ emit<K extends DevtoolsEventType>(type: K, data: DevtoolsEventMap[K]): void;
1469
+ /** Subscribes to an event type. Returns the function that unsubscribes. */
1470
+ on<K extends DevtoolsEventType>(type: K, callback: (data: DevtoolsEventMap[K]) => void): () => void;
1471
+ /** Cancels a specific subscription. */
1472
+ off<K extends DevtoolsEventType>(type: K, callback: (data: DevtoolsEventMap[K]) => void): void;
1473
+ /** Removes all listeners of a type or all listeners. */
1474
+ clear(type?: DevtoolsEventType): void;
1475
+ /** Number of listeners registered for a type. */
1476
+ count(type: DevtoolsEventType): number;
1477
+ };
1478
+
1479
+ /**
1480
+ * @module devtools/xray
1481
+ *
1482
+ * Visual reactivity inspector for Voodoo. Runs inside the page itself, without
1483
+ * browser extension or server.
1484
+ *
1485
+ * When enabled, it outlines every element with directives, shows a card with
1486
+ * that element's scope, opens a panel with tabs for state, components, stores,
1487
+ * events, network and performance, and flashes the element every time a
1488
+ * reactive effect writes to it. That's the x-ray effect: you can see reactivity
1489
+ * happening.
1490
+ *
1491
+ * ```js
1492
+ * V.xray() // toggle
1493
+ * V.xray(true) // force enable
1494
+ * ```
1495
+ *
1496
+ * The module registers nothing when imported. No listeners, no styles, and no
1497
+ * timers exist before the first call, so it's tree-shakeable and costs nothing
1498
+ * in production.
1499
+ */
1500
+
1501
+ /** Enables the inspector. Calling twice doesn't duplicate anything. */
1502
+ declare function enableXray(): void;
1503
+ /** Disables the inspector and returns the page to its original state. */
1504
+ declare function disableXray(): void;
1505
+ /** `true` when the inspector is enabled. */
1506
+ declare function isXrayEnabled(): boolean;
1507
+ /**
1508
+ * Enables and disables the visual reactivity inspector.
1509
+ *
1510
+ * ```js
1511
+ * V.xray() // toggle
1512
+ * V.xray(true) // enable
1513
+ * V.xray(false) // disable
1514
+ * ```
1515
+ *
1516
+ * The first call also installs the `Ctrl+Shift+X` shortcut.
1517
+ *
1518
+ * @param force enable or disable explicitly. Without argument, toggles.
1519
+ * @returns the state after the call.
1520
+ */
1521
+ declare function xray(force?: boolean): boolean;
1522
+
1523
+ /**
1524
+ * @module devtools/launcher
1525
+ *
1526
+ * Floating widget for devtools.
1527
+ *
1528
+ * The `xray` inspector always existed, but only opened via console call. This
1529
+ * module adds a button to the page itself: it appears when devtools are on,
1530
+ * shows live activity, and opens the full panel with a click.
1531
+ *
1532
+ * Enable via HTML without writing any JavaScript:
1533
+ *
1534
+ * ```html
1535
+ * <script src="voodoo.full.min.js" devtools defer></script>
1536
+ * ```
1537
+ *
1538
+ * Equivalent forms also work: `data-devtools`, `devtools="true"` and
1539
+ * `window.VOODOO_DEVTOOLS = true` before loading.
1540
+ *
1541
+ * Enable via JavaScript:
1542
+ *
1543
+ * ```js
1544
+ * V.devtoolsWidget() // toggle
1545
+ * V.devtoolsWidget(true) // show
1546
+ * V.devtoolsWidget(false) // hide
1547
+ * ```
1548
+ *
1549
+ * The module does nothing when imported: no listeners, no styles, and
1550
+ * no timers exist before the first call to `mountDevtoolsWidget()`.
1551
+ */
1552
+ /** Shows the floating widget. Calling twice doesn't duplicate anything. */
1553
+ declare function mountDevtoolsWidget(): void;
1554
+ /** Removes the widget and all listeners it created. */
1555
+ declare function unmountDevtoolsWidget(): void;
1556
+ /** `true` when the widget is on screen. */
1557
+ declare function isDevtoolsWidgetMounted(): boolean;
1558
+ /**
1559
+ * Shows and hides the devtools floating widget.
1560
+ *
1561
+ * ```js
1562
+ * V.devtoolsWidget() // toggle
1563
+ * V.devtoolsWidget(true) // show
1564
+ * V.devtoolsWidget(false) // hide
1565
+ * ```
1566
+ *
1567
+ * @param force show or hide explicitly. Without argument, toggles.
1568
+ * @returns the state after the call.
1569
+ */
1570
+ declare function devtoolsWidget(force?: boolean): boolean;
1571
+
1572
+ /**
1573
+ * Voodoo.js
1574
+ * JavaScript feels like magic.
1575
+ *
1576
+ * Entry point for bundlers. Importing this module does not touch the DOM: the page
1577
+ * is initialized by `browser.ts`, used in the CDN build, or an explicit call to
1578
+ * `V.start()`.
1579
+ *
1580
+ * ```ts
1581
+ * import V from 'voodoojs'
1582
+ * V.start()
1583
+ * ```
1584
+ *
1585
+ * ```ts
1586
+ * import { reactive, http, toast } from 'voodoojs'
1587
+ * ```
1588
+ */
1589
+
1590
+ /**
1591
+ * `V` is at once a function and an object.
1592
+ *
1593
+ * ```js
1594
+ * V('#list .item').addClass('active') // chainable collection
1595
+ * V.toast.success('Done') // services
1596
+ * ```
1597
+ */
1598
+ interface Voodoo extends Omit<typeof core, never> {
1599
+ (input?: unknown, context?: unknown): VoodooCollection;
1600
+ }
1601
+ declare const V: Voodoo;
1602
+
1603
+ export { V, type Voodoo, VoodooCollection, alert, animate, applyMask, charts, clearErrors, clipboard, confirm, V as default, devtoolsBus, devtoolsWidget, dialog, disableXray, easings, enableXray, getLocale, hotkey, i18n, inView, isDevtoolsWidgetMounted, isXrayEnabled, mask, masks, modal, motionPresets, mountDevtoolsWidget, navigate, network, palette, prompt, registerMask, renderChart, route, router, screen, scrollProgress, serializeForm, setLocale, showFormErrors, sound, efeitos as soundEffects, spring, stagger, t, unmask, unmountDevtoolsWidget, validate, validator, xray };