@vuetify/v0 1.1.0 → 1.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +13 -0
- package/dist/{adapter-Butx_2UU.d.mts → adapter-BXunW_mw.d.mts} +1 -1
- package/dist/{createPagination-B5dfqY-a.mjs → adapter-BiQV5j8B.mjs} +98 -3
- package/dist/adapter-ClB-53_F.d.mts +62 -0
- package/dist/adapter-CrRJuxRk.mjs +21 -0
- package/dist/{adapter-hq9YlPOF.d.mts → adapter-FckJSz_o.d.mts} +2 -2
- package/dist/{adapter-_srNCBEi.d.mts → adapter-PDTe5nFT.d.mts} +6 -7
- package/dist/browser/index.d.ts +15918 -13714
- package/dist/browser/index.js +16708 -14105
- package/dist/components/index.d.mts +2 -2
- package/dist/components/index.mjs +2 -2
- package/dist/{components-B2BZ1B3K.mjs → components-MCFhfNlt.mjs} +8234 -6307
- package/dist/composables/index.d.mts +22 -20
- package/dist/composables/index.mjs +37 -34
- package/dist/{composables-DONBl_c9.mjs → composables-8xtFVviy.mjs} +32 -1061
- package/dist/{consola-BPGkJp_q.d.mts → consola-CdMU53rU.d.mts} +1 -1
- package/dist/constants/index.d.mts +1 -1
- package/dist/constants/index.mjs +1 -1
- package/dist/{createDataTable-DgyHBfAr.mjs → createDataTable-OCGnpy-N.mjs} +24 -8
- package/dist/{createGroup-BXKKcb9-.mjs → createGroup-DtVYu-VY.mjs} +14 -3
- package/dist/createPlugin-Oo6t-vBw.mjs +157 -0
- package/dist/{createRegistry-B9cOWny2.mjs → createRegistry-DSQiALGi.mjs} +3 -3
- package/dist/{createSelection-CWE554_g.mjs → createSelection-TB5oK1FG.mjs} +2 -1
- package/dist/{createSingle-Dz-1Iv7u.mjs → createSingle-CV1qigP2.mjs} +1 -1
- package/dist/{createTokens-C4qcW2Kv.mjs → createTokens-B0CqJEL6.mjs} +2 -2
- package/dist/data-table/adapters/client/index.d.mts +1 -1
- package/dist/data-table/adapters/client/index.mjs +1 -1
- package/dist/data-table/adapters/index.d.mts +4 -4
- package/dist/data-table/adapters/index.mjs +4 -4
- package/dist/data-table/adapters/server/index.d.mts +1 -1
- package/dist/data-table/adapters/server/index.mjs +1 -1
- package/dist/data-table/adapters/virtual/index.d.mts +1 -1
- package/dist/data-table/adapters/virtual/index.mjs +1 -1
- package/dist/data-table/index.d.mts +5 -5
- package/dist/data-table/index.mjs +5 -5
- package/dist/date/index.d.mts +1 -1
- package/dist/date/index.mjs +2 -2
- package/dist/features/adapters/flagsmith/index.d.mts +1 -1
- package/dist/features/adapters/flagsmith/index.mjs +1 -1
- package/dist/features/adapters/launchdarkly/index.d.mts +1 -1
- package/dist/features/adapters/launchdarkly/index.mjs +1 -1
- package/dist/features/adapters/posthog/index.d.mts +1 -1
- package/dist/features/adapters/posthog/index.mjs +2 -2
- package/dist/features/index.d.mts +2 -2
- package/dist/features/index.mjs +2 -2
- package/dist/{flagsmith-DA2GCyGv.d.mts → flagsmith-DcIDrI7_.d.mts} +1 -1
- package/dist/{globals-CtaXlEOI.mjs → globals-wvVdMRFF.mjs} +1 -1
- package/dist/{index-DCtHbY0a.d.mts → index-3bThcqCN.d.mts} +25 -20
- package/dist/{index-QnpcDsV7.d.mts → index-3vvA76pZ.d.mts} +2 -2
- package/dist/{index-RGiSdjYt.d.mts → index-4Z38WhA9.d.mts} +9 -3
- package/dist/{index-CTl0cGH6.d.mts → index-BTdCsSz0.d.mts} +7264 -5608
- package/dist/{index-DF0tMI2_.d.mts → index-CORslci7.d.mts} +121 -2
- package/dist/{index-Dc7lKT6q.d.mts → index-Dgkt7Ve9.d.mts} +494 -131
- package/dist/index.d.mts +25 -24
- package/dist/index.mjs +40 -37
- package/dist/json/attributes.json +500 -0
- package/dist/json/importMap.json +92 -0
- package/dist/json/tags.json +237 -0
- package/dist/json/web-types.json +1553 -97
- package/dist/{launchdarkly-Bp8p9PMD.d.mts → launchdarkly-CUzunYol.d.mts} +1 -1
- package/dist/locale/adapters/index.d.mts +2 -2
- package/dist/locale/adapters/index.mjs +2 -2
- package/dist/locale/adapters/v0/index.d.mts +1 -1
- package/dist/locale/adapters/v0/index.mjs +1 -1
- package/dist/locale/adapters/vue-i18n/index.d.mts +1 -1
- package/dist/locale/adapters/vue-i18n/index.mjs +1 -1
- package/dist/locale/index.d.mts +3 -3
- package/dist/locale/index.mjs +3 -3
- package/dist/locale/messages/en/index.d.mts +6 -0
- package/dist/locale/messages/en/index.mjs +2 -0
- package/dist/logger/adapters/consola/index.d.mts +1 -1
- package/dist/logger/adapters/index.d.mts +4 -4
- package/dist/logger/adapters/index.mjs +1 -1
- package/dist/logger/adapters/pino/index.d.mts +1 -1
- package/dist/logger/adapters/v0/index.d.mts +1 -1
- package/dist/logger/adapters/v0/index.mjs +1 -1
- package/dist/logger/index.d.mts +5 -5
- package/dist/logger/index.mjs +2 -2
- package/dist/notifications/index.d.mts +1 -1
- package/dist/notifications/index.mjs +2 -2
- package/dist/palettes/ant/index.d.mts +1 -1
- package/dist/palettes/index.d.mts +3 -3
- package/dist/palettes/material/index.d.mts +1 -1
- package/dist/palettes/md1/index.d.mts +1 -1
- package/dist/palettes/md2/index.d.mts +1 -1
- package/dist/palettes/radix/index.d.mts +1 -1
- package/dist/palettes/tailwind/index.d.mts +1 -1
- package/dist/permissions/adapters/index.d.mts +1 -1
- package/dist/permissions/adapters/index.mjs +1 -1
- package/dist/permissions/adapters/v0/index.d.mts +1 -1
- package/dist/permissions/adapters/v0/index.mjs +1 -1
- package/dist/permissions/index.d.mts +1 -1
- package/dist/permissions/index.mjs +2 -2
- package/dist/{pino-B6BI1AOK.d.mts → pino-DjeWBFnj.d.mts} +1 -1
- package/dist/popover/adapters/floating-ui/index.d.mts +25 -0
- package/dist/popover/adapters/floating-ui/index.mjs +98 -0
- package/dist/popover/index.d.mts +3 -0
- package/dist/popover/index.mjs +3 -0
- package/dist/{posthog-sFqk0bGy.d.mts → posthog-CJAYssdr.d.mts} +1 -1
- package/dist/rules/index.d.mts +1 -1
- package/dist/rules/index.mjs +1 -1
- package/dist/{server-DbtTGb67.d.mts → server-5vbJ7GGs.d.mts} +2 -2
- package/dist/{server-D5BJBjB0.mjs → server-m7iD1vOr.mjs} +1 -2
- package/dist/storage/adapters/index.d.mts +2 -2
- package/dist/storage/adapters/index.mjs +1 -1
- package/dist/storage/adapters/memory/index.d.mts +1 -1
- package/dist/storage/adapters/memory/index.mjs +1 -1
- package/dist/storage/index.d.mts +3 -3
- package/dist/storage/index.mjs +2 -2
- package/dist/theme/adapters/index.d.mts +1 -1
- package/dist/theme/adapters/index.mjs +3 -3
- package/dist/theme/adapters/unhead/index.d.mts +1 -1
- package/dist/theme/adapters/unhead/index.mjs +1 -1
- package/dist/theme/adapters/v0/index.d.mts +1 -1
- package/dist/theme/adapters/v0/index.mjs +1 -1
- package/dist/theme/index.d.mts +2 -2
- package/dist/theme/index.mjs +4 -4
- package/dist/types/index.d.mts +1 -1
- package/dist/{unhead-BAWCwNOF.mjs → unhead-SyU953Pt.mjs} +2 -2
- package/dist/{useEventListener-DSOeDtC-.mjs → useEventListener-hF6R2p6X.mjs} +2 -2
- package/dist/useFeatures-CTpkM6hV.mjs +221 -0
- package/dist/{useLocale-D-V0DENN.mjs → useLocale-D-iWu08b.mjs} +4 -4
- package/dist/{useLogger-CbvzXCWb.mjs → useLogger-CDsgHbzO.mjs} +5 -159
- package/dist/{useNotifications-Cqg3uDz0.mjs → useNotifications-DhNjvRt1.mjs} +57 -154
- package/dist/{usePermissions-BTdUVyQe.mjs → usePermissions-CKe8xcvz.mjs} +4 -4
- package/dist/usePopover-DyAdne_S.mjs +421 -0
- package/dist/{useRovingFocus-g6ifibLg.mjs → useRovingFocus-D0OOozbe.mjs} +1169 -553
- package/dist/{useRules-DEiHd_eY.mjs → useRules-DA8bNhNq.mjs} +3 -2
- package/dist/{useStorage-BSfQfDbg.mjs → useStorage-D9c6xx4N.mjs} +5 -4
- package/dist/useTheme-BrXA5VBp.mjs +445 -0
- package/dist/useTimer-DLtkRCHw.mjs +151 -0
- package/dist/utilities/index.d.mts +2 -2
- package/dist/utilities/index.mjs +204 -2
- package/dist/{v0-BnUwMaOv.d.mts → v0-C09lR5fc.d.mts} +1 -1
- package/dist/{v0-CveVV6On.mjs → v0-CaTmC7C4.mjs} +2 -2
- package/dist/{v0-rSxMW8FJ.d.mts → v0-DfFK-p4X.d.mts} +1 -1
- package/dist/{v0-CCWHeKJM.mjs → v0-DpFVF6pD.mjs} +1 -1
- package/dist/{v0-DotXXGXU.d.mts → v0-GI9U-rPA.d.mts} +2 -2
- package/dist/{v0-CZBkpQjr.mjs → v0-cC-WxCLd.mjs} +2 -2
- package/dist/{v0-A4GLojAr.mjs → v0-yZ2ZUtVF.mjs} +1 -2
- package/dist/{virtual-DFvOoeG6.mjs → virtual-Bbu26O_h.mjs} +1 -2
- package/dist/{virtual-C-NsLue0.d.mts → virtual-JIdFLpTQ.d.mts} +2 -2
- package/package.json +8 -1
- package/dist/adapter-CVoWg0sw.mjs +0 -99
- package/dist/useFeatures-YJmONiU7.mjs +0 -124
- package/dist/useTheme-C0_i__N6.mjs +0 -162
- /package/dist/{adapter-CTsckKAR.mjs → adapter-8UADsA3-.mjs} +0 -0
- /package/dist/{adapter-BCtceV3b.mjs → adapter-BuSfpxur.mjs} +0 -0
- /package/dist/{adapter-Bc0yPSfo.d.mts → adapter-D5nT3bLw.d.mts} +0 -0
- /package/dist/{adapter-bwZo7b5p.mjs → adapter-D8zizQVP.mjs} +0 -0
- /package/dist/{adapter-q1sRACUc.mjs → adapter-TiGrumDi.mjs} +0 -0
- /package/dist/{adapter-BYzU4Ey5.d.mts → adapter-ryk5H6YZ.d.mts} +0 -0
- /package/dist/{index-CROz1VSV.d.mts → index-CX869wwk.d.mts} +0 -0
- /package/dist/{index-FtE8MXJ_.d.mts → index-CsuikFeJ.d.mts} +0 -0
- /package/dist/{index-DidZKN6S.d.mts → index-Djhiy3nS.d.mts} +0 -0
- /package/dist/{index-CyNk9FpR.d.mts → index-DtiaWx5U.d.mts} +0 -0
- /package/dist/{index-DXMlYoiQ.d.mts → index-H_hl6-4b.d.mts} +0 -0
- /package/dist/{index-BgCkepP_.d.mts → index-u_qSc2xS.d.mts} +0 -0
- /package/dist/{memory-DbyZeNjg.d.mts → memory-B7z1RR9r.d.mts} +0 -0
- /package/dist/{memory-BJjkQzxs.mjs → memory-CR6zvuaP.mjs} +0 -0
- /package/dist/{toArray-C89ZaEuF.mjs → toArray-MY9Kb1Qy.mjs} +0 -0
- /package/dist/{v0-UNyykD27.mjs → v0-Ch0yBKEj.mjs} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as ID, c as V0ErrorCode, l as V0ErrorDetails, r as DeepPartial } from "./index-
|
|
1
|
+
import { a as ID, c as V0ErrorCode, l as V0ErrorDetails, r as DeepPartial } from "./index-DtiaWx5U.mjs";
|
|
2
2
|
|
|
3
3
|
//#region src/utilities/color.d.ts
|
|
4
4
|
interface RGB {
|
|
@@ -19,6 +19,77 @@ declare function rgbToHex({
|
|
|
19
19
|
declare function apca(text: RGB, background: RGB): number;
|
|
20
20
|
declare function foreground(hex: string): string;
|
|
21
21
|
//#endregion
|
|
22
|
+
//#region src/utilities/diacritics.d.ts
|
|
23
|
+
/**
|
|
24
|
+
* @module utilities/diacritics
|
|
25
|
+
*
|
|
26
|
+
* @remarks
|
|
27
|
+
* Accent-folding search primitives. Pure string transforms — no DOM, no state,
|
|
28
|
+
* no reactivity. Powers the `ignoreAccents` option of `toHighlight` and any
|
|
29
|
+
* filter that wants a plain query to reach accented text.
|
|
30
|
+
*/
|
|
31
|
+
/**
|
|
32
|
+
* A `[start, end]` index pair where `end` is exclusive (matches
|
|
33
|
+
* `String.prototype.slice` convention).
|
|
34
|
+
*
|
|
35
|
+
* @example
|
|
36
|
+
* ```ts
|
|
37
|
+
* import type { MatchRange } from '@vuetify/v0'
|
|
38
|
+
*
|
|
39
|
+
* const ranges: MatchRange[] = [[0, 5], [12, 17]]
|
|
40
|
+
* ```
|
|
41
|
+
*/
|
|
42
|
+
type MatchRange = readonly [number, number];
|
|
43
|
+
/**
|
|
44
|
+
* Which side of a comparison has its accents folded before matching.
|
|
45
|
+
*
|
|
46
|
+
* - `'query'` — folds the query, so typing `café` finds plain `cafe`
|
|
47
|
+
* - `'target'` — folds the text, so typing `cafe` finds accented `café`
|
|
48
|
+
* - `true` — both sides fold, so any accent variant matches any other
|
|
49
|
+
* - `false` — neither folds, exact match only
|
|
50
|
+
*
|
|
51
|
+
* `'query'` and `'target'` fold only one side, but a spelling that already
|
|
52
|
+
* agrees on both sides still matches verbatim — folding one side never
|
|
53
|
+
* hides a match the other side already has. They still don't fold each
|
|
54
|
+
* other's accents together, so `café` won't match `cafè` under either.
|
|
55
|
+
*/
|
|
56
|
+
type IgnoreAccents = boolean | 'query' | 'target';
|
|
57
|
+
interface FindMatchRangesOptions {
|
|
58
|
+
ignoreCase?: boolean;
|
|
59
|
+
ignoreAccents?: IgnoreAccents;
|
|
60
|
+
matchAll?: boolean;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Finds `[start, end]` index pairs where `query` occurs in `text`, optionally
|
|
64
|
+
* folding accents on either side. Returned indices always address the original
|
|
65
|
+
* `text`, even when folding or case-conversion changed its length.
|
|
66
|
+
*
|
|
67
|
+
* Directional folding (`'query'` or `'target'`) only transforms one side, but
|
|
68
|
+
* a spelling that's already identical on both sides — accents and all — is
|
|
69
|
+
* merged in verbatim, so folding one side never hides a match the other side
|
|
70
|
+
* already has.
|
|
71
|
+
*
|
|
72
|
+
* @param text The string to search.
|
|
73
|
+
* @param query The term to look for. An empty query yields no ranges.
|
|
74
|
+
* @param options Optional `ignoreCase`, `ignoreAccents`, `matchAll`.
|
|
75
|
+
* @returns Ranges into `text`, where `end` is exclusive.
|
|
76
|
+
*
|
|
77
|
+
* @example
|
|
78
|
+
* ```ts
|
|
79
|
+
* import { findMatchRanges } from '@vuetify/v0'
|
|
80
|
+
*
|
|
81
|
+
* findMatchRanges('Zürich', 'zurich', { ignoreCase: true, ignoreAccents: true })
|
|
82
|
+
* // [[0, 6]]
|
|
83
|
+
*
|
|
84
|
+
* findMatchRanges('Łódź', 'Lo', { ignoreAccents: 'target' })
|
|
85
|
+
* // [[0, 2]]
|
|
86
|
+
*
|
|
87
|
+
* findMatchRanges('… Kraków …', 'Kraków', { ignoreAccents: 'query' })
|
|
88
|
+
* // [[2, 8]] — typing the exact accented name always finds itself
|
|
89
|
+
* ```
|
|
90
|
+
*/
|
|
91
|
+
declare function findMatchRanges(text: string, query: string, options?: FindMatchRangesOptions): MatchRange[];
|
|
92
|
+
//#endregion
|
|
22
93
|
//#region src/utilities/errors.d.ts
|
|
23
94
|
/**
|
|
24
95
|
* Structured error thrown by v0 internals.
|
|
@@ -263,6 +334,21 @@ declare function isArray<T>(item: T | NoInfer<T[]>): item is 0 extends (1 & T) ?
|
|
|
263
334
|
* ```
|
|
264
335
|
*/
|
|
265
336
|
declare function isElement(item: unknown): item is Element;
|
|
337
|
+
/**
|
|
338
|
+
* Resolve the deepest focused element, piercing open shadow roots.
|
|
339
|
+
*
|
|
340
|
+
* `document.activeElement` returns the shadow *host* when focus is inside an
|
|
341
|
+
* open shadow root — walk down through open roots so focus/keyboard logic
|
|
342
|
+
* resolves the real focused element (e.g. a control inside a custom element).
|
|
343
|
+
* Returns the same value as `document.activeElement` in light DOM, and `null`
|
|
344
|
+
* under SSR. Closed shadow roots can't be traversed.
|
|
345
|
+
*
|
|
346
|
+
* @example
|
|
347
|
+
* ```ts
|
|
348
|
+
* const active = getActiveElement()
|
|
349
|
+
* ```
|
|
350
|
+
*/
|
|
351
|
+
declare function getActiveElement(): Element | null;
|
|
266
352
|
/**
|
|
267
353
|
* Checks if a value is null
|
|
268
354
|
*
|
|
@@ -449,6 +535,39 @@ declare function clamp(value: number, min?: number, max?: number): number;
|
|
|
449
535
|
* ```
|
|
450
536
|
*/
|
|
451
537
|
declare function range(length: number, start?: number): number[];
|
|
538
|
+
/**
|
|
539
|
+
* Parses a CSS pixel length into a number
|
|
540
|
+
*
|
|
541
|
+
* @param value The resolved CSS length, e.g. `getComputedStyle(el).marginLeft`
|
|
542
|
+
* @param fallback The value to return when `value` does not parse (default: 0)
|
|
543
|
+
* @returns The parsed number, or `fallback`
|
|
544
|
+
*
|
|
545
|
+
* @remarks
|
|
546
|
+
* Built for reading `getComputedStyle` output, where a length that does not
|
|
547
|
+
* apply resolves to `''` or `'auto'` rather than to a number. An unparseable
|
|
548
|
+
* length returns `fallback`; a length that legitimately parses to `0` returns
|
|
549
|
+
* `0`. That distinction is why this exists — `Number.parseFloat(v) || 0`
|
|
550
|
+
* collapses both cases onto `0`, which is only correct when the fallback is
|
|
551
|
+
* itself `0`.
|
|
552
|
+
*
|
|
553
|
+
* Only the leading number is read, matching `Number.parseFloat`, so any unit
|
|
554
|
+
* suffix is ignored. Values `getComputedStyle` never returns — percentages,
|
|
555
|
+
* `calc()` expressions, multi-value shorthands — are out of scope.
|
|
556
|
+
*
|
|
557
|
+
* @example
|
|
558
|
+
* ```ts
|
|
559
|
+
* pxToNumber('16px') // 16
|
|
560
|
+
* pxToNumber('0px') // 0
|
|
561
|
+
* pxToNumber('-4.5px') // -4.5
|
|
562
|
+
* pxToNumber('auto') // 0
|
|
563
|
+
* pxToNumber(undefined) // 0
|
|
564
|
+
*
|
|
565
|
+
* // A non-zero fallback is the case `|| 0` cannot express
|
|
566
|
+
* pxToNumber('auto', 100) // 100
|
|
567
|
+
* pxToNumber('0px', 100) // 0
|
|
568
|
+
* ```
|
|
569
|
+
*/
|
|
570
|
+
declare function pxToNumber(value: string | undefined, fallback?: number): number;
|
|
452
571
|
/**
|
|
453
572
|
* Resolves an iterable of IDs to their items via a getter,
|
|
454
573
|
* filtering out any that return undefined.
|
|
@@ -469,4 +588,4 @@ declare function resolveIndexes(items: Iterable<{
|
|
|
469
588
|
declare function instanceExists(): boolean;
|
|
470
589
|
declare function instanceName(): string | undefined;
|
|
471
590
|
//#endregion
|
|
472
|
-
export {
|
|
591
|
+
export { MatchRange as A, resolveIds as C, isV0Error as D, V0Error as E, hexToRgb as F, rgbToHex as I, apca as M, foreground as N, FindMatchRangesOptions as O, RGB as P, range as S, useId as T, isSymbol as _, getActiveElement as a, mergeDeep as b, isElement as c, isNull as d, isNullOrUndefined as f, isString as g, isPrimitive as h, clamp as i, findMatchRanges as j, IgnoreAccents as k, isFunction as l, isObject as m, instanceName as n, isArray as o, isNumber as p, UNSAFE_KEYS as r, isBoolean as s, instanceExists as t, isNaN as u, isThenable as v, resolveIndexes as w, pxToNumber as x, isUndefined as y };
|