@bquery/bquery 1.4.0 → 1.6.0

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 (164) hide show
  1. package/README.md +586 -527
  2. package/dist/component/component.d.ts +13 -5
  3. package/dist/component/component.d.ts.map +1 -1
  4. package/dist/component/html.d.ts +40 -3
  5. package/dist/component/html.d.ts.map +1 -1
  6. package/dist/component/index.d.ts +4 -2
  7. package/dist/component/index.d.ts.map +1 -1
  8. package/dist/component/library.d.ts +34 -0
  9. package/dist/component/library.d.ts.map +1 -0
  10. package/dist/component/types.d.ts +132 -13
  11. package/dist/component/types.d.ts.map +1 -1
  12. package/dist/component-BEQgt5hl.js +600 -0
  13. package/dist/component-BEQgt5hl.js.map +1 -0
  14. package/dist/component.es.mjs +7 -184
  15. package/dist/config-DRmZZno3.js +40 -0
  16. package/dist/config-DRmZZno3.js.map +1 -0
  17. package/dist/core-BGQJVw0-.js +35 -0
  18. package/dist/core-BGQJVw0-.js.map +1 -0
  19. package/dist/core-CCEabVHl.js +648 -0
  20. package/dist/core-CCEabVHl.js.map +1 -0
  21. package/dist/core.es.mjs +45 -1261
  22. package/dist/effect-AFRW_Plg.js +84 -0
  23. package/dist/effect-AFRW_Plg.js.map +1 -0
  24. package/dist/full.d.ts +8 -8
  25. package/dist/full.d.ts.map +1 -1
  26. package/dist/full.es.mjs +101 -91
  27. package/dist/full.iife.js +173 -3
  28. package/dist/full.iife.js.map +1 -1
  29. package/dist/full.umd.js +173 -3
  30. package/dist/full.umd.js.map +1 -1
  31. package/dist/index.es.mjs +147 -139
  32. package/dist/motion/transition.d.ts +1 -1
  33. package/dist/motion/transition.d.ts.map +1 -1
  34. package/dist/motion/types.d.ts +11 -1
  35. package/dist/motion/types.d.ts.map +1 -1
  36. package/dist/motion-D9TcHxOF.js +415 -0
  37. package/dist/motion-D9TcHxOF.js.map +1 -0
  38. package/dist/motion.es.mjs +25 -361
  39. package/dist/object-qGpWr6-J.js +38 -0
  40. package/dist/object-qGpWr6-J.js.map +1 -0
  41. package/dist/platform/announcer.d.ts +59 -0
  42. package/dist/platform/announcer.d.ts.map +1 -0
  43. package/dist/platform/config.d.ts +92 -0
  44. package/dist/platform/config.d.ts.map +1 -0
  45. package/dist/platform/cookies.d.ts +45 -0
  46. package/dist/platform/cookies.d.ts.map +1 -0
  47. package/dist/platform/index.d.ts +8 -0
  48. package/dist/platform/index.d.ts.map +1 -1
  49. package/dist/platform/meta.d.ts +62 -0
  50. package/dist/platform/meta.d.ts.map +1 -0
  51. package/dist/platform-Dr9b6fsq.js +362 -0
  52. package/dist/platform-Dr9b6fsq.js.map +1 -0
  53. package/dist/platform.es.mjs +11 -248
  54. package/dist/reactive/async-data.d.ts +114 -0
  55. package/dist/reactive/async-data.d.ts.map +1 -0
  56. package/dist/reactive/index.d.ts +2 -2
  57. package/dist/reactive/index.d.ts.map +1 -1
  58. package/dist/reactive/signal.d.ts +2 -0
  59. package/dist/reactive/signal.d.ts.map +1 -1
  60. package/dist/reactive-DSkct0dO.js +254 -0
  61. package/dist/reactive-DSkct0dO.js.map +1 -0
  62. package/dist/reactive.es.mjs +18 -32
  63. package/dist/router-CbDhl8rS.js +188 -0
  64. package/dist/router-CbDhl8rS.js.map +1 -0
  65. package/dist/router.es.mjs +11 -200
  66. package/dist/sanitize-Bs2dkMby.js +313 -0
  67. package/dist/sanitize-Bs2dkMby.js.map +1 -0
  68. package/dist/security/constants.d.ts.map +1 -1
  69. package/dist/security/index.d.ts +4 -2
  70. package/dist/security/index.d.ts.map +1 -1
  71. package/dist/security/sanitize.d.ts +4 -1
  72. package/dist/security/sanitize.d.ts.map +1 -1
  73. package/dist/security/trusted-html.d.ts +53 -0
  74. package/dist/security/trusted-html.d.ts.map +1 -0
  75. package/dist/security.es.mjs +11 -56
  76. package/dist/store/define-store.d.ts +1 -1
  77. package/dist/store/define-store.d.ts.map +1 -1
  78. package/dist/store/mapping.d.ts +1 -1
  79. package/dist/store/mapping.d.ts.map +1 -1
  80. package/dist/store/persisted.d.ts +1 -1
  81. package/dist/store/persisted.d.ts.map +1 -1
  82. package/dist/store/types.d.ts +2 -2
  83. package/dist/store/types.d.ts.map +1 -1
  84. package/dist/store/watch.d.ts +1 -1
  85. package/dist/store/watch.d.ts.map +1 -1
  86. package/dist/store-BwDvI45q.js +263 -0
  87. package/dist/store-BwDvI45q.js.map +1 -0
  88. package/dist/store.es.mjs +12 -25
  89. package/dist/storybook/index.d.ts +37 -0
  90. package/dist/storybook/index.d.ts.map +1 -0
  91. package/dist/storybook.es.mjs +151 -0
  92. package/dist/storybook.es.mjs.map +1 -0
  93. package/dist/untrack-B0rVscTc.js +7 -0
  94. package/dist/untrack-B0rVscTc.js.map +1 -0
  95. package/dist/view-C70lA3vf.js +397 -0
  96. package/dist/view-C70lA3vf.js.map +1 -0
  97. package/dist/view.es.mjs +11 -430
  98. package/package.json +141 -132
  99. package/src/component/component.ts +524 -289
  100. package/src/component/html.ts +153 -53
  101. package/src/component/index.ts +50 -40
  102. package/src/component/library.ts +518 -0
  103. package/src/component/types.ts +256 -85
  104. package/src/core/collection.ts +628 -628
  105. package/src/core/element.ts +774 -774
  106. package/src/core/index.ts +48 -48
  107. package/src/core/utils/function.ts +151 -151
  108. package/src/full.ts +229 -187
  109. package/src/motion/animate.ts +113 -113
  110. package/src/motion/flip.ts +176 -176
  111. package/src/motion/scroll.ts +57 -57
  112. package/src/motion/spring.ts +150 -150
  113. package/src/motion/timeline.ts +246 -246
  114. package/src/motion/transition.ts +97 -51
  115. package/src/motion/types.ts +11 -1
  116. package/src/platform/announcer.ts +208 -0
  117. package/src/platform/config.ts +163 -0
  118. package/src/platform/cookies.ts +165 -0
  119. package/src/platform/index.ts +21 -0
  120. package/src/platform/meta.ts +168 -0
  121. package/src/platform/storage.ts +215 -215
  122. package/src/reactive/async-data.ts +486 -0
  123. package/src/reactive/core.ts +114 -114
  124. package/src/reactive/effect.ts +54 -54
  125. package/src/reactive/index.ts +15 -1
  126. package/src/reactive/internals.ts +122 -122
  127. package/src/reactive/signal.ts +9 -0
  128. package/src/security/constants.ts +3 -1
  129. package/src/security/index.ts +17 -10
  130. package/src/security/sanitize-core.ts +364 -364
  131. package/src/security/sanitize.ts +70 -66
  132. package/src/security/trusted-html.ts +71 -0
  133. package/src/store/define-store.ts +49 -48
  134. package/src/store/mapping.ts +74 -73
  135. package/src/store/persisted.ts +62 -61
  136. package/src/store/types.ts +92 -94
  137. package/src/store/watch.ts +53 -52
  138. package/src/storybook/index.ts +479 -0
  139. package/src/view/evaluate.ts +290 -290
  140. package/dist/batch-x7b2eZST.js +0 -13
  141. package/dist/batch-x7b2eZST.js.map +0 -1
  142. package/dist/component.es.mjs.map +0 -1
  143. package/dist/core-BhpuvPhy.js +0 -170
  144. package/dist/core-BhpuvPhy.js.map +0 -1
  145. package/dist/core.es.mjs.map +0 -1
  146. package/dist/full.es.mjs.map +0 -1
  147. package/dist/index.es.mjs.map +0 -1
  148. package/dist/motion.es.mjs.map +0 -1
  149. package/dist/persisted-DHoi3uEs.js +0 -278
  150. package/dist/persisted-DHoi3uEs.js.map +0 -1
  151. package/dist/platform.es.mjs.map +0 -1
  152. package/dist/reactive.es.mjs.map +0 -1
  153. package/dist/router.es.mjs.map +0 -1
  154. package/dist/sanitize-Cxvxa-DX.js +0 -283
  155. package/dist/sanitize-Cxvxa-DX.js.map +0 -1
  156. package/dist/security.es.mjs.map +0 -1
  157. package/dist/store.es.mjs.map +0 -1
  158. package/dist/type-guards-BdKlYYlS.js +0 -32
  159. package/dist/type-guards-BdKlYYlS.js.map +0 -1
  160. package/dist/untrack-DNnnqdlR.js +0 -6
  161. package/dist/untrack-DNnnqdlR.js.map +0 -1
  162. package/dist/view.es.mjs.map +0 -1
  163. package/dist/watch-DXXv3iAI.js +0 -58
  164. package/dist/watch-DXXv3iAI.js.map +0 -1
package/dist/core.es.mjs CHANGED
@@ -1,1264 +1,48 @@
1
- import { s as f } from "./sanitize-Cxvxa-DX.js";
2
- const g = (n) => Array.isArray(n) ? n : [n], l = (n, e) => {
3
- for (const t of n)
4
- e(t);
5
- }, p = (n) => f(n), w = (n, e) => {
6
- n.innerHTML = f(e);
7
- }, y = (n) => {
8
- const e = document.createElement("template");
9
- return e.innerHTML = f(n), e.content.firstElementChild ?? document.createElement("div");
10
- }, b = (n, e, t) => {
11
- if (typeof e == "string") {
12
- n.insertAdjacentHTML(t, f(e));
13
- return;
14
- }
15
- const r = g(e), i = t === "afterbegin" || t === "afterend" ? r.slice().reverse() : r;
16
- l(i, (o) => {
17
- n.insertAdjacentElement(t, o);
18
- });
19
- };
20
- class h {
21
- /**
22
- * Creates a new BQueryElement wrapper.
23
- * @param element - The DOM element to wrap
24
- */
25
- constructor(e) {
26
- this.element = e, this.delegatedHandlers = /* @__PURE__ */ new Map();
27
- }
28
- /**
29
- * Exposes the raw DOM element when direct access is needed.
30
- * Use sparingly; prefer the wrapper methods for consistency.
31
- */
32
- get raw() {
33
- return this.element;
34
- }
35
- /**
36
- * Exposes the underlying DOM element.
37
- * Provided for spec compatibility and read-only access.
38
- */
39
- get node() {
40
- return this.element;
41
- }
42
- /** Add one or more classes. */
43
- addClass(...e) {
44
- return this.element.classList.add(...e), this;
45
- }
46
- /** Remove one or more classes. */
47
- removeClass(...e) {
48
- return this.element.classList.remove(...e), this;
49
- }
50
- /** Toggle a class by name. */
51
- toggleClass(e, t) {
52
- return this.element.classList.toggle(e, t), this;
53
- }
54
- /** Get or set an attribute. */
55
- attr(e, t) {
56
- return t === void 0 ? this.element.getAttribute(e) ?? "" : (this.element.setAttribute(e, t), this);
57
- }
58
- /** Remove an attribute. */
59
- removeAttr(e) {
60
- return this.element.removeAttribute(e), this;
61
- }
62
- /** Toggle an attribute on/off. */
63
- toggleAttr(e, t) {
64
- const r = this.element.hasAttribute(e);
65
- return t ?? !r ? this.element.setAttribute(e, "") : this.element.removeAttribute(e), this;
66
- }
67
- /** Get or set a property. */
68
- prop(e, t) {
69
- return t === void 0 ? this.element[e] : (this.element[e] = t, this);
70
- }
71
- /** Read or write data attributes in camelCase. */
72
- data(e, t) {
73
- const r = e.replace(/[A-Z]/g, (s) => `-${s.toLowerCase()}`);
74
- return t === void 0 ? this.element.getAttribute(`data-${r}`) ?? "" : (this.element.setAttribute(`data-${r}`, t), this);
75
- }
76
- /** Get or set text content. */
77
- text(e) {
78
- return e === void 0 ? this.element.textContent ?? "" : (this.element.textContent = e, this);
79
- }
80
- /** Set HTML content using a sanitized string. */
81
- /**
82
- * Sets sanitized HTML content on the element.
83
- * Uses the security module to sanitize input and prevent XSS attacks.
84
- *
85
- * @param value - The HTML string to set (will be sanitized)
86
- * @returns The instance for method chaining
87
- *
88
- * @example
89
- * ```ts
90
- * $('#content').html('<strong>Hello</strong>');
91
- * ```
92
- */
93
- html(e) {
94
- return w(this.element, e), this;
95
- }
96
- /**
97
- * Sets HTML content without sanitization.
98
- * Use only when you trust the HTML source completely.
99
- *
100
- * @param value - The raw HTML string to set
101
- * @returns The instance for method chaining
102
- *
103
- * @warning This method bypasses XSS protection. Use with caution.
104
- */
105
- htmlUnsafe(e) {
106
- return this.element.innerHTML = e, this;
107
- }
108
- css(e, t) {
109
- if (typeof e == "string") {
110
- if (t !== void 0)
111
- return this.element.style.setProperty(e, t), this;
112
- const r = this.element.ownerDocument?.defaultView;
113
- return !r || typeof r.getComputedStyle != "function" ? "" : r.getComputedStyle(this.element).getPropertyValue(e);
114
- }
115
- for (const [r, s] of Object.entries(e))
116
- this.element.style.setProperty(r, s);
117
- return this;
118
- }
119
- /**
120
- * Appends HTML or elements to the end of the element.
121
- *
122
- * @param content - HTML string or element(s) to append
123
- * @returns The instance for method chaining
124
- */
125
- append(e) {
126
- return this.insertContent(e, "beforeend"), this;
127
- }
128
- /**
129
- * Prepends HTML or elements to the beginning of the element.
130
- *
131
- * @param content - HTML string or element(s) to prepend
132
- * @returns The instance for method chaining
133
- */
134
- prepend(e) {
135
- return this.insertContent(e, "afterbegin"), this;
136
- }
137
- /**
138
- * Inserts content before this element.
139
- *
140
- * @param content - HTML string or element(s) to insert
141
- * @returns The instance for method chaining
142
- */
143
- before(e) {
144
- return this.insertContent(e, "beforebegin"), this;
145
- }
146
- /**
147
- * Inserts content after this element.
148
- *
149
- * @param content - HTML string or element(s) to insert
150
- * @returns The instance for method chaining
151
- */
152
- after(e) {
153
- return this.insertContent(e, "afterend"), this;
154
- }
155
- /**
156
- * Wraps the element with the specified wrapper element or tag.
157
- *
158
- * @param wrapper - Tag name string or Element to wrap with
159
- * @returns The instance for method chaining
160
- *
161
- * @example
162
- * ```ts
163
- * $('#content').wrap('div'); // Wraps with <div>
164
- * $('#content').wrap(document.createElement('section'));
165
- * ```
166
- */
167
- wrap(e) {
168
- const t = typeof e == "string" ? document.createElement(e) : e;
169
- return this.element.parentNode?.insertBefore(t, this.element), t.appendChild(this.element), this;
170
- }
171
- /**
172
- * Removes the parent element, keeping this element in its place.
173
- * Essentially the opposite of wrap().
174
- *
175
- * **Important**: This method only moves the current element out of its parent
176
- * before removing the parent. Any sibling elements will be removed along with
177
- * the parent. For unwrapping multiple siblings, use a collection: `$$(siblings).unwrap()`.
178
- *
179
- * @returns The instance for method chaining
180
- *
181
- * @example
182
- * ```ts
183
- * // Before: <div><span id="text">Hello</span></div>
184
- * $('#text').unwrap();
185
- * // After: <span id="text">Hello</span>
186
- * ```
187
- */
188
- unwrap() {
189
- const e = this.element.parentElement;
190
- return e && e.parentNode && (e.parentNode.insertBefore(this.element, e), e.remove()), this;
191
- }
192
- /**
193
- * Replaces this element with new content.
194
- *
195
- * @param content - HTML string (sanitized) or Element to replace with
196
- * @returns A new BQueryElement wrapping the replacement element
197
- *
198
- * @example
199
- * ```ts
200
- * const newEl = $('#old').replaceWith('<div id="new">Replaced</div>');
201
- * ```
202
- */
203
- replaceWith(e) {
204
- const t = typeof e == "string" ? y(e) : e;
205
- return this.element.replaceWith(t), new h(t);
206
- }
207
- /**
208
- * Scrolls the element into view with configurable behavior.
209
- *
210
- * @param options - ScrollIntoView options or boolean for legacy behavior
211
- * @returns The instance for method chaining
212
- *
213
- * @example
214
- * ```ts
215
- * $('#section').scrollTo(); // Smooth scroll
216
- * $('#section').scrollTo({ behavior: 'instant', block: 'start' });
217
- * ```
218
- */
219
- scrollTo(e = { behavior: "smooth" }) {
220
- return this.element.scrollIntoView(e), this;
221
- }
222
- /**
223
- * Removes the element from the DOM.
224
- *
225
- * @returns The instance for method chaining (though element is now detached)
226
- */
227
- remove() {
228
- return this.element.remove(), this;
229
- }
230
- /**
231
- * Clears all child nodes from the element.
232
- *
233
- * @returns The instance for method chaining
234
- */
235
- empty() {
236
- return this.element.innerHTML = "", this;
237
- }
238
- /**
239
- * Clones the element, optionally with all descendants.
240
- *
241
- * @param deep - If true, clone all descendants (default: true)
242
- * @returns A new BQueryElement wrapping the cloned element
243
- */
244
- clone(e = !0) {
245
- return new h(this.element.cloneNode(e));
246
- }
247
- /**
248
- * Finds all descendant elements matching the selector.
249
- *
250
- * @param selector - CSS selector to match
251
- * @returns Array of matching elements
252
- */
253
- find(e) {
254
- return Array.from(this.element.querySelectorAll(e));
255
- }
256
- /**
257
- * Finds the first descendant element matching the selector.
258
- *
259
- * @param selector - CSS selector to match
260
- * @returns The first matching element or null
261
- */
262
- findOne(e) {
263
- return this.element.querySelector(e);
264
- }
265
- /**
266
- * Finds the closest ancestor matching the selector.
267
- *
268
- * @param selector - CSS selector to match
269
- * @returns The matching ancestor or null
270
- */
271
- closest(e) {
272
- return this.element.closest(e);
273
- }
274
- /**
275
- * Gets the parent element.
276
- *
277
- * @returns The parent element or null
278
- */
279
- parent() {
280
- return this.element.parentElement;
281
- }
282
- /**
283
- * Gets all child elements.
284
- *
285
- * @returns Array of child elements
286
- */
287
- children() {
288
- return Array.from(this.element.children);
289
- }
290
- /**
291
- * Gets all sibling elements.
292
- *
293
- * @returns Array of sibling elements (excluding this element)
294
- */
295
- siblings() {
296
- const e = this.element.parentElement;
297
- return e ? Array.from(e.children).filter((t) => t !== this.element) : [];
298
- }
299
- /**
300
- * Gets the next sibling element.
301
- *
302
- * @returns The next sibling element or null
303
- */
304
- next() {
305
- return this.element.nextElementSibling;
306
- }
307
- /**
308
- * Gets the previous sibling element.
309
- *
310
- * @returns The previous sibling element or null
311
- */
312
- prev() {
313
- return this.element.previousElementSibling;
314
- }
315
- /**
316
- * Adds an event listener.
317
- *
318
- * @param event - Event type to listen for
319
- * @param handler - Event handler function
320
- * @returns The instance for method chaining
321
- */
322
- on(e, t) {
323
- return this.element.addEventListener(e, t), this;
324
- }
325
- /**
326
- * Adds a one-time event listener that removes itself after firing.
327
- *
328
- * @param event - Event type to listen for
329
- * @param handler - Event handler function
330
- * @returns The instance for method chaining
331
- */
332
- once(e, t) {
333
- return this.element.addEventListener(e, t, { once: !0 }), this;
334
- }
335
- /**
336
- * Removes an event listener.
337
- *
338
- * @param event - Event type
339
- * @param handler - The handler to remove
340
- * @returns The instance for method chaining
341
- */
342
- off(e, t) {
343
- return this.element.removeEventListener(e, t), this;
344
- }
345
- /**
346
- * Triggers a custom event on the element.
347
- *
348
- * @param event - Event type to trigger
349
- * @param detail - Optional detail data to include with the event
350
- * @returns The instance for method chaining
351
- */
352
- trigger(e, t) {
353
- return this.element.dispatchEvent(new CustomEvent(e, { detail: t, bubbles: !0, cancelable: !0 })), this;
354
- }
355
- /**
356
- * Adds a delegated event listener that only triggers for matching descendants.
357
- * More efficient than adding listeners to many elements individually.
358
- *
359
- * Use `undelegate()` to remove the listener later.
360
- *
361
- * @param event - Event type to listen for
362
- * @param selector - CSS selector to match against event targets
363
- * @param handler - Event handler function, receives the matched element as context
364
- * @returns The instance for method chaining
365
- *
366
- * @example
367
- * ```ts
368
- * // Instead of adding listeners to each button:
369
- * const handler = (e, target) => console.log('Clicked:', target.textContent);
370
- * $('#list').delegate('click', '.item', handler);
371
- *
372
- * // Later, remove the delegated listener:
373
- * $('#list').undelegate('click', '.item', handler);
374
- * ```
375
- */
376
- delegate(e, t, r) {
377
- const s = `${e}:${t}`, i = (o) => {
378
- const u = o.target.closest(t);
379
- u && this.element.contains(u) && r(o, u);
380
- };
381
- return this.delegatedHandlers.has(s) || this.delegatedHandlers.set(s, /* @__PURE__ */ new Map()), this.delegatedHandlers.get(s).set(r, i), this.element.addEventListener(e, i), this;
382
- }
383
- /**
384
- * Removes a delegated event listener previously added with `delegate()`.
385
- *
386
- * @param event - Event type that was registered
387
- * @param selector - CSS selector that was used
388
- * @param handler - The original handler function passed to delegate()
389
- * @returns The instance for method chaining
390
- *
391
- * @example
392
- * ```ts
393
- * const handler = (e, target) => console.log('Clicked:', target.textContent);
394
- * $('#list').delegate('click', '.item', handler);
395
- *
396
- * // Remove the delegated listener:
397
- * $('#list').undelegate('click', '.item', handler);
398
- * ```
399
- */
400
- undelegate(e, t, r) {
401
- const s = `${e}:${t}`, i = this.delegatedHandlers.get(s);
402
- if (i) {
403
- const o = i.get(r);
404
- o && (this.element.removeEventListener(e, o), i.delete(r), i.size === 0 && this.delegatedHandlers.delete(s));
405
- }
406
- return this;
407
- }
408
- /**
409
- * Checks if the element matches a CSS selector.
410
- *
411
- * @param selector - CSS selector to match against
412
- * @returns True if the element matches the selector
413
- */
414
- matches(e) {
415
- return this.element.matches(e);
416
- }
417
- /**
418
- * Alias for `matches()`. Checks if the element matches a CSS selector.
419
- *
420
- * @param selector - CSS selector to match against
421
- * @returns True if the element matches the selector
422
- *
423
- * @example
424
- * ```ts
425
- * if ($('#el').is('.active')) {
426
- * console.log('Element is active');
427
- * }
428
- * ```
429
- */
430
- is(e) {
431
- return this.matches(e);
432
- }
433
- /**
434
- * Checks if the element has a specific class.
435
- *
436
- * @param className - Class name to check
437
- * @returns True if the element has the class
438
- */
439
- hasClass(e) {
440
- return this.element.classList.contains(e);
441
- }
442
- /**
443
- * Shows the element by removing the hidden attribute and setting display.
444
- *
445
- * @param display - Optional display value (default: '')
446
- * @returns The instance for method chaining
447
- */
448
- show(e = "") {
449
- return this.element.removeAttribute("hidden"), this.element.style.display = e, this;
450
- }
451
- /**
452
- * Hides the element by setting display to 'none'.
453
- *
454
- * @returns The instance for method chaining
455
- */
456
- hide() {
457
- return this.element.style.display = "none", this;
458
- }
459
- /**
460
- * Toggles the visibility of the element.
461
- *
462
- * @param force - Optional force show (true) or hide (false)
463
- * @returns The instance for method chaining
464
- */
465
- toggle(e) {
466
- const t = this.element.style.display === "none";
467
- return e ?? t ? this.show() : this.hide();
468
- }
469
- /**
470
- * Focuses the element.
471
- *
472
- * @returns The instance for method chaining
473
- */
474
- focus() {
475
- return this.element.focus(), this;
476
- }
477
- /**
478
- * Blurs (unfocuses) the element.
479
- *
480
- * @returns The instance for method chaining
481
- */
482
- blur() {
483
- return this.element.blur(), this;
484
- }
485
- /**
486
- * Gets or sets the value of form elements.
487
- *
488
- * @param newValue - Optional value to set
489
- * @returns The current value when getting, or the instance when setting
490
- */
491
- val(e) {
492
- const t = this.element;
493
- return e === void 0 ? t.value ?? "" : (t.value = e, this);
494
- }
495
- /**
496
- * Serializes form data to a plain object.
497
- * Only works on form elements; returns empty object for non-forms.
498
- *
499
- * @returns Object with form field names as keys and values
500
- *
501
- * @example
502
- * ```ts
503
- * // For a form with <input name="email" value="test@example.com">
504
- * const data = $('#myForm').serialize();
505
- * // { email: 'test@example.com' }
506
- * ```
507
- */
508
- serialize() {
509
- const e = this.element;
510
- if (e.tagName.toLowerCase() !== "form")
511
- return {};
512
- const t = {}, r = new FormData(e);
513
- for (const [s, i] of r.entries())
514
- if (typeof i == "string")
515
- if (s in t) {
516
- const o = t[s];
517
- Array.isArray(o) ? o.push(i) : t[s] = [o, i];
518
- } else
519
- t[s] = i;
520
- return t;
521
- }
522
- /**
523
- * Serializes form data to a URL-encoded query string.
524
- *
525
- * @returns URL-encoded string suitable for form submission
526
- *
527
- * @example
528
- * ```ts
529
- * const queryString = $('#myForm').serializeString();
530
- * // 'email=test%40example.com&name=John'
531
- * ```
532
- */
533
- serializeString() {
534
- const e = this.element;
535
- if (e.tagName.toLowerCase() !== "form")
536
- return "";
537
- const t = new FormData(e), r = new URLSearchParams();
538
- for (const [s, i] of t.entries())
539
- typeof i == "string" && r.append(s, i);
540
- return r.toString();
541
- }
542
- /**
543
- * Gets the bounding client rectangle of the element.
544
- *
545
- * @returns The element's bounding rectangle
546
- */
547
- rect() {
548
- return this.element.getBoundingClientRect();
549
- }
550
- /**
551
- * Gets the offset dimensions (width, height, top, left).
552
- *
553
- * @returns Object with offset dimensions
554
- */
555
- offset() {
556
- const e = this.element;
557
- return {
558
- width: e.offsetWidth,
559
- height: e.offsetHeight,
560
- top: e.offsetTop,
561
- left: e.offsetLeft
562
- };
563
- }
564
- /**
565
- * Internal method to insert content at a specified position.
566
- * @internal
567
- */
568
- insertContent(e, t) {
569
- b(this.element, e, t);
570
- }
571
- }
572
- class c {
573
- /**
574
- * Creates a new collection wrapper.
575
- * @param elements - Array of DOM elements to wrap
576
- */
577
- constructor(e) {
578
- this.elements = e, this.delegatedHandlers = /* @__PURE__ */ new WeakMap();
579
- }
580
- /**
581
- * Gets the number of elements in the collection.
582
- */
583
- get length() {
584
- return this.elements.length;
585
- }
586
- /**
587
- * Gets the first element in the collection, if any.
588
- * @internal
589
- */
590
- first() {
591
- return this.elements[0];
592
- }
593
- /**
594
- * Gets a single element as a BQueryElement wrapper.
595
- *
596
- * @param index - Zero-based index of the element
597
- * @returns BQueryElement wrapper or undefined if out of range
598
- */
599
- eq(e) {
600
- const t = this.elements[e];
601
- return t ? new h(t) : void 0;
602
- }
603
- /**
604
- * Gets the first element as a BQueryElement wrapper.
605
- *
606
- * @returns BQueryElement wrapper or undefined if empty
607
- */
608
- firstEl() {
609
- return this.eq(0);
610
- }
611
- /**
612
- * Gets the last element as a BQueryElement wrapper.
613
- *
614
- * @returns BQueryElement wrapper or undefined if empty
615
- */
616
- lastEl() {
617
- return this.eq(this.elements.length - 1);
618
- }
619
- /**
620
- * Iterates over each element in the collection.
621
- *
622
- * @param callback - Function to call for each wrapped element
623
- * @returns The instance for method chaining
624
- */
625
- each(e) {
626
- return this.elements.forEach((t, r) => {
627
- e(new h(t), r);
628
- }), this;
629
- }
630
- /**
631
- * Maps each element to a new value.
632
- *
633
- * @param callback - Function to transform each element
634
- * @returns Array of transformed values
635
- */
636
- map(e) {
637
- return this.elements.map(e);
638
- }
639
- /**
640
- * Filters elements based on a predicate.
641
- *
642
- * @param predicate - Function to test each element
643
- * @returns New BQueryCollection with matching elements
644
- */
645
- filter(e) {
646
- return new c(this.elements.filter(e));
647
- }
648
- /**
649
- * Reduces the collection to a single value.
650
- *
651
- * @param callback - Reducer function
652
- * @param initialValue - Initial accumulator value
653
- * @returns Accumulated result
654
- */
655
- reduce(e, t) {
656
- return this.elements.reduce(e, t);
657
- }
658
- /**
659
- * Converts the collection to an array of BQueryElement wrappers.
660
- *
661
- * @returns Array of BQueryElement instances
662
- */
663
- toArray() {
664
- return this.elements.map((e) => new h(e));
665
- }
666
- /** Add one or more classes to all elements. */
667
- addClass(...e) {
668
- return l(this.elements, (t) => t.classList.add(...e)), this;
669
- }
670
- /** Remove one or more classes from all elements. */
671
- removeClass(...e) {
672
- return l(this.elements, (t) => t.classList.remove(...e)), this;
673
- }
674
- /** Toggle a class on all elements. */
675
- toggleClass(e, t) {
676
- return l(this.elements, (r) => r.classList.toggle(e, t)), this;
677
- }
678
- /**
679
- * Sets an attribute on all elements or gets from first.
680
- *
681
- * @param name - Attribute name
682
- * @param value - Value to set (optional)
683
- * @returns Attribute value when getting, instance when setting
684
- */
685
- attr(e, t) {
686
- return t === void 0 ? this.first()?.getAttribute(e) ?? "" : (l(this.elements, (r) => r.setAttribute(e, t)), this);
687
- }
688
- /**
689
- * Removes an attribute from all elements.
690
- *
691
- * @param name - Attribute name to remove
692
- * @returns The instance for method chaining
693
- */
694
- removeAttr(e) {
695
- return l(this.elements, (t) => t.removeAttribute(e)), this;
696
- }
697
- /** Toggle an attribute on all elements. */
698
- toggleAttr(e, t) {
699
- return l(this.elements, (r) => {
700
- const s = r.hasAttribute(e);
701
- t ?? !s ? r.setAttribute(e, "") : r.removeAttribute(e);
702
- }), this;
703
- }
704
- /**
705
- * Sets text content on all elements or gets from first.
706
- *
707
- * @param value - Text to set (optional)
708
- * @returns Text content when getting, instance when setting
709
- */
710
- text(e) {
711
- return e === void 0 ? this.first()?.textContent ?? "" : (l(this.elements, (t) => {
712
- t.textContent = e;
713
- }), this);
714
- }
715
- /**
716
- * Sets sanitized HTML on all elements or gets from first.
717
- *
718
- * @param value - HTML to set (optional, will be sanitized)
719
- * @returns HTML content when getting, instance when setting
720
- */
721
- html(e) {
722
- if (e === void 0)
723
- return this.first()?.innerHTML ?? "";
724
- const t = p(e);
725
- return l(this.elements, (r) => {
726
- r.innerHTML = t;
727
- }), this;
728
- }
729
- /**
730
- * Sets HTML on all elements without sanitization.
731
- *
732
- * @param value - Raw HTML to set
733
- * @returns The instance for method chaining
734
- * @warning Bypasses XSS protection
735
- */
736
- htmlUnsafe(e) {
737
- return l(this.elements, (t) => {
738
- t.innerHTML = e;
739
- }), this;
740
- }
741
- /** Append content to all elements. */
742
- append(e) {
743
- return this.insertAll(e, "beforeend"), this;
744
- }
745
- /** Prepend content to all elements. */
746
- prepend(e) {
747
- return this.insertAll(e, "afterbegin"), this;
748
- }
749
- /** Insert content before all elements. */
750
- before(e) {
751
- return this.insertAll(e, "beforebegin"), this;
752
- }
753
- /** Insert content after all elements. */
754
- after(e) {
755
- return this.insertAll(e, "afterend"), this;
756
- }
757
- css(e, t) {
758
- if (typeof e == "string") {
759
- if (t !== void 0)
760
- return l(this.elements, (i) => {
761
- i.style.setProperty(e, t);
762
- }), this;
763
- const r = this.first();
764
- if (!r)
765
- return "";
766
- const s = r.ownerDocument?.defaultView;
767
- return !s || typeof s.getComputedStyle != "function" ? "" : s.getComputedStyle(r).getPropertyValue(e);
768
- }
769
- return l(this.elements, (r) => {
770
- for (const [s, i] of Object.entries(e))
771
- r.style.setProperty(s, i);
772
- }), this;
773
- }
774
- /** Wrap each element with a wrapper element or tag. */
775
- wrap(e) {
776
- return this.elements.forEach((t, r) => {
777
- const s = typeof e == "string" ? document.createElement(e) : r === 0 ? e : e.cloneNode(!0);
778
- t.parentNode?.insertBefore(s, t), s.appendChild(t);
779
- }), this;
780
- }
781
- /**
782
- * Remove the parent element of each element, keeping the elements in place.
783
- *
784
- * **Important**: This method unwraps ALL children of each parent element,
785
- * not just the elements in the collection. If you call `unwrap()` on a
786
- * collection containing only some children of a parent, all siblings will
787
- * also be unwrapped. This behavior is consistent with jQuery's `.unwrap()`.
788
- *
789
- * @returns The collection for chaining
790
- *
791
- * @example
792
- * ```ts
793
- * // HTML: <div><section><span>A</span><span>B</span></section></div>
794
- * const spans = $$('span');
795
- * spans.unwrap(); // Removes <section>, both spans move to <div>
796
- * // Result: <div><span>A</span><span>B</span></div>
797
- * ```
798
- */
799
- unwrap() {
800
- const e = /* @__PURE__ */ new Set();
801
- for (const t of this.elements)
802
- t.parentElement && e.add(t.parentElement);
803
- return e.forEach((t) => {
804
- const r = t.parentNode;
805
- if (r) {
806
- for (; t.firstChild; )
807
- r.insertBefore(t.firstChild, t);
808
- t.remove();
809
- }
810
- }), this;
811
- }
812
- /** Replace each element with provided content. */
813
- replaceWith(e) {
814
- const t = [];
815
- return this.elements.forEach((r, s) => {
816
- const i = typeof e == "string" ? y(e) : s === 0 ? e : e.cloneNode(!0);
817
- r.replaceWith(i), t.push(i);
818
- }), new c(t);
819
- }
820
- /**
821
- * Shows all elements.
822
- *
823
- * @param display - Optional display value (default: '')
824
- * @returns The instance for method chaining
825
- */
826
- show(e = "") {
827
- return l(this.elements, (t) => {
828
- t.removeAttribute("hidden"), t.style.display = e;
829
- }), this;
830
- }
831
- /**
832
- * Hides all elements.
833
- *
834
- * @returns The instance for method chaining
835
- */
836
- hide() {
837
- return l(this.elements, (e) => {
838
- e.style.display = "none";
839
- }), this;
840
- }
841
- /**
842
- * Adds an event listener to all elements.
843
- *
844
- * @param event - Event type
845
- * @param handler - Event handler
846
- * @returns The instance for method chaining
847
- */
848
- on(e, t) {
849
- return l(this.elements, (r) => r.addEventListener(e, t)), this;
850
- }
851
- /**
852
- * Adds a one-time event listener to all elements.
853
- *
854
- * @param event - Event type
855
- * @param handler - Event handler
856
- * @returns The instance for method chaining
857
- */
858
- once(e, t) {
859
- return l(this.elements, (r) => r.addEventListener(e, t, { once: !0 })), this;
860
- }
861
- /**
862
- * Removes an event listener from all elements.
863
- *
864
- * @param event - Event type
865
- * @param handler - The handler to remove
866
- * @returns The instance for method chaining
867
- */
868
- off(e, t) {
869
- return l(this.elements, (r) => r.removeEventListener(e, t)), this;
870
- }
871
- /**
872
- * Triggers a custom event on all elements.
873
- *
874
- * @param event - Event type
875
- * @param detail - Optional event detail
876
- * @returns The instance for method chaining
877
- */
878
- trigger(e, t) {
879
- return l(this.elements, (r) => {
880
- r.dispatchEvent(new CustomEvent(e, { detail: t, bubbles: !0, cancelable: !0 }));
881
- }), this;
882
- }
883
- /**
884
- * Adds a delegated event listener to all elements.
885
- * Events are delegated to matching descendants.
886
- *
887
- * Use `undelegate()` to remove the listener later.
888
- *
889
- * @param event - Event type to listen for
890
- * @param selector - CSS selector to match against event targets
891
- * @param handler - Event handler function
892
- * @returns The instance for method chaining
893
- *
894
- * @example
895
- * ```ts
896
- * const handler = (e, target) => console.log('Clicked:', target.textContent);
897
- * $$('.container').delegate('click', '.item', handler);
898
- *
899
- * // Later, remove the delegated listener:
900
- * $$('.container').undelegate('click', '.item', handler);
901
- * ```
902
- */
903
- delegate(e, t, r) {
904
- const s = `${e}:${t}`;
905
- return l(this.elements, (i) => {
906
- const o = (a) => {
907
- const m = a.target.closest(t);
908
- m && i.contains(m) && r(a, m);
909
- };
910
- this.delegatedHandlers.has(i) || this.delegatedHandlers.set(i, /* @__PURE__ */ new Map());
911
- const u = this.delegatedHandlers.get(i);
912
- u.has(s) || u.set(s, /* @__PURE__ */ new Map()), u.get(s).set(r, o), i.addEventListener(e, o);
913
- }), this;
914
- }
915
- /**
916
- * Removes a delegated event listener previously added with `delegate()`.
917
- *
918
- * @param event - Event type that was registered
919
- * @param selector - CSS selector that was used
920
- * @param handler - The original handler function passed to delegate()
921
- * @returns The instance for method chaining
922
- *
923
- * @example
924
- * ```ts
925
- * const handler = (e, target) => console.log('Clicked:', target.textContent);
926
- * $$('.container').delegate('click', '.item', handler);
927
- *
928
- * // Remove the delegated listener:
929
- * $$('.container').undelegate('click', '.item', handler);
930
- * ```
931
- */
932
- undelegate(e, t, r) {
933
- const s = `${e}:${t}`;
934
- return l(this.elements, (i) => {
935
- const o = this.delegatedHandlers.get(i);
936
- if (!o) return;
937
- const u = o.get(s);
938
- if (!u) return;
939
- const a = u.get(r);
940
- a && (i.removeEventListener(e, a), u.delete(r), u.size === 0 && o.delete(s), o.size === 0 && this.delegatedHandlers.delete(i));
941
- }), this;
942
- }
943
- /**
944
- * Finds all descendant elements matching the selector across all elements
945
- * in the collection. Returns a new BQueryCollection with the results.
946
- *
947
- * @param selector - CSS selector to match
948
- * @returns A new BQueryCollection with all matching descendants
949
- *
950
- * @example
951
- * ```ts
952
- * $$('.container').find('.item').addClass('highlight');
953
- * ```
954
- */
955
- find(e) {
956
- const t = /* @__PURE__ */ new Set(), r = [];
957
- for (const s of this.elements) {
958
- const i = s.querySelectorAll(e);
959
- for (let o = 0; o < i.length; o++)
960
- t.has(i[o]) || (t.add(i[o]), r.push(i[o]));
961
- }
962
- return new c(r);
963
- }
964
- /**
965
- * Removes all elements from the DOM.
966
- *
967
- * @returns The instance for method chaining
968
- */
969
- remove() {
970
- return l(this.elements, (e) => e.remove()), this;
971
- }
972
- /**
973
- * Clears all child nodes from all elements.
974
- *
975
- * @returns The instance for method chaining
976
- */
977
- empty() {
978
- return l(this.elements, (e) => {
979
- e.innerHTML = "";
980
- }), this;
981
- }
982
- /** @internal */
983
- insertAll(e, t) {
984
- if (typeof e == "string") {
985
- const s = p(e);
986
- l(this.elements, (i) => {
987
- i.insertAdjacentHTML(t, s);
988
- });
989
- return;
990
- }
991
- const r = g(e);
992
- this.elements.forEach((s, i) => {
993
- const o = i === 0 ? r : r.map((u) => u.cloneNode(!0));
994
- b(s, o, t);
995
- });
996
- }
997
- }
998
- const oe = (n) => {
999
- if (typeof n != "string")
1000
- return new h(n);
1001
- const e = document.querySelector(n);
1002
- if (!e)
1003
- throw new Error(`bQuery: element not found for selector "${n}"`);
1004
- return new h(e);
1005
- }, le = (n) => Array.isArray(n) ? new c(n) : n instanceof NodeList ? new c(Array.from(n)) : new c(Array.from(document.querySelectorAll(n)));
1006
- function E(n) {
1007
- return n == null ? [] : Array.isArray(n) ? n : [n];
1008
- }
1009
- function C(n) {
1010
- return Array.from(new Set(n));
1011
- }
1012
- function L(n, e) {
1013
- if (e <= 0) return [];
1014
- const t = [];
1015
- for (let r = 0; r < n.length; r += e)
1016
- t.push(n.slice(r, r + e));
1017
- return t;
1018
- }
1019
- function v(n) {
1020
- return n.filter(Boolean);
1021
- }
1022
- function H(n) {
1023
- const e = [];
1024
- for (const t of n)
1025
- Array.isArray(t) ? e.push(...t) : e.push(t);
1026
- return e;
1027
- }
1028
- function N(n, e) {
1029
- let t;
1030
- return Object.assign(
1031
- (...s) => {
1032
- t !== void 0 && clearTimeout(t), t = setTimeout(() => {
1033
- t = void 0, n(...s);
1034
- }, e);
1035
- },
1036
- {
1037
- cancel: () => {
1038
- t !== void 0 && (clearTimeout(t), t = void 0);
1039
- }
1040
- }
1041
- );
1042
- }
1043
- function S(n, e) {
1044
- let t = 0;
1045
- return Object.assign(
1046
- (...s) => {
1047
- const i = Date.now();
1048
- i - t >= e && (t = i, n(...s));
1049
- },
1050
- {
1051
- cancel: () => {
1052
- t = 0;
1053
- }
1054
- }
1055
- );
1056
- }
1057
- function $(n) {
1058
- let e = !1, t;
1059
- return (...r) => (e || (t = n(...r), e = !0), t);
1060
- }
1061
- function M() {
1062
- }
1063
- function j(n = "bQuery") {
1064
- return `${n}_${Math.random().toString(36).slice(2, 9)}`;
1065
- }
1066
- function O(n) {
1067
- return new Promise((e) => setTimeout(e, n));
1068
- }
1069
- function T(n, e) {
1070
- try {
1071
- return JSON.parse(n);
1072
- } catch {
1073
- return e;
1074
- }
1075
- }
1076
- function P(n) {
1077
- return n == null ? !0 : typeof n == "string" ? n.trim().length === 0 : Array.isArray(n) ? n.length === 0 : typeof n == "object" ? Object.keys(n).length === 0 : !1;
1078
- }
1079
- function k(n, e) {
1080
- return Math.floor(Math.random() * (e - n + 1)) + n;
1081
- }
1082
- function z(n, e, t) {
1083
- return Math.min(Math.max(n, e), t);
1084
- }
1085
- function D(n, e, t, r = !0) {
1086
- return r ? n >= e && n <= t : n > e && n < t;
1087
- }
1088
- function q(n, e = 0) {
1089
- const t = typeof n == "number" ? n : Number(n);
1090
- return Number.isNaN(t) ? e : t;
1091
- }
1092
- function d(n) {
1093
- return Object.prototype.toString.call(n) === "[object Object]";
1094
- }
1095
- function x(n) {
1096
- return n === "__proto__" || n === "constructor" || n === "prototype";
1097
- }
1098
- function R(n) {
1099
- return typeof structuredClone == "function" ? structuredClone(n) : JSON.parse(JSON.stringify(n));
1100
- }
1101
- function A(...n) {
1102
- const e = {};
1103
- for (const t of n)
1104
- for (const [r, s] of Object.entries(t))
1105
- x(r) || (d(s) && d(e[r]) ? e[r] = A(
1106
- e[r],
1107
- s
1108
- ) : e[r] = s);
1109
- return e;
1110
- }
1111
- function B(n, e) {
1112
- const t = {};
1113
- for (const r of e)
1114
- r in n && (t[r] = n[r]);
1115
- return t;
1116
- }
1117
- function W(n, e) {
1118
- const t = { ...n };
1119
- for (const r of e)
1120
- delete t[r];
1121
- return t;
1122
- }
1123
- function F(n, e) {
1124
- return Object.prototype.hasOwnProperty.call(n, e);
1125
- }
1126
- function U(n) {
1127
- return n && n.charAt(0).toUpperCase() + n.slice(1);
1128
- }
1129
- function J(n) {
1130
- return n.replace(/([a-z])([A-Z])/g, "$1-$2").replace(/[\s_]+/g, "-").toLowerCase();
1131
- }
1132
- function V(n) {
1133
- return n.replace(/[-_\s]+(.)?/g, (e, t) => t ? t.toUpperCase() : "").replace(/^[A-Z]/, (e) => e.toLowerCase());
1134
- }
1135
- function _(n, e, t = "…") {
1136
- if (e <= 0) return "";
1137
- if (n.length <= e) return n;
1138
- const r = Math.max(0, e - t.length);
1139
- return `${n.slice(0, r)}${t}`;
1140
- }
1141
- function I(n) {
1142
- return n.normalize("NFD").replace(/[\u0300-\u036f]/g, "").replace(/[^\w\s-]/g, "").trim().replace(/[\s_-]+/g, "-").toLowerCase();
1143
- }
1144
- function Z(n) {
1145
- return n.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
1146
- }
1147
- function K(n) {
1148
- return typeof Element < "u" && n instanceof Element;
1149
- }
1150
- function G(n) {
1151
- return !!(n && typeof n == "object" && "elements" in n);
1152
- }
1153
- function X(n) {
1154
- return typeof n == "function";
1155
- }
1156
- function Y(n) {
1157
- return typeof n == "string";
1158
- }
1159
- function Q(n) {
1160
- return typeof n == "number" && !Number.isNaN(n);
1161
- }
1162
- function ee(n) {
1163
- return typeof n == "boolean";
1164
- }
1165
- function te(n) {
1166
- return Array.isArray(n);
1167
- }
1168
- function ne(n) {
1169
- return n instanceof Date;
1170
- }
1171
- function re(n) {
1172
- return !!(n && (n instanceof Promise || typeof n == "object" && "then" in n && typeof n.then == "function"));
1173
- }
1174
- function se(n) {
1175
- return typeof n == "object" && n !== null;
1176
- }
1177
- const ue = {
1178
- clone: R,
1179
- merge: A,
1180
- pick: B,
1181
- omit: W,
1182
- hasOwn: F,
1183
- debounce: N,
1184
- throttle: S,
1185
- once: $,
1186
- noop: M,
1187
- uid: j,
1188
- isElement: K,
1189
- isCollection: G,
1190
- isEmpty: P,
1191
- isPlainObject: d,
1192
- isFunction: X,
1193
- isString: Y,
1194
- isNumber: Q,
1195
- isBoolean: ee,
1196
- isArray: te,
1197
- isDate: ne,
1198
- isPromise: re,
1199
- isObject: se,
1200
- parseJson: T,
1201
- sleep: O,
1202
- randomInt: k,
1203
- clamp: z,
1204
- inRange: D,
1205
- toNumber: q,
1206
- capitalize: U,
1207
- toKebabCase: J,
1208
- toCamelCase: V,
1209
- truncate: _,
1210
- slugify: I,
1211
- escapeRegExp: Z,
1212
- ensureArray: E,
1213
- unique: C,
1214
- chunk: L,
1215
- compact: v,
1216
- flatten: H
1217
- };
1
+ import { A as a, C as e, D as i, E as t, F as o, I as n, L as r, M as l, N as c, O as m, P as u, R as p, S as b, T as y, _ as g, a as C, b as f, c as E, d, f as h, g as O, h as j, i as k, j as x, k as A, l as B, m as N, n as P, o as R, p as $, r as w, s as D, t as F, u as I, v as Q, w as S, x as q, y as v } from "./core-CCEabVHl.js";
2
+ import { a as J, i as K, n as L, o as M, r as T, t as _ } from "./object-qGpWr6-J.js";
1218
3
  export {
1219
- oe as $,
1220
- le as $$,
1221
- c as BQueryCollection,
1222
- h as BQueryElement,
1223
- U as capitalize,
1224
- L as chunk,
1225
- z as clamp,
1226
- R as clone,
1227
- v as compact,
1228
- N as debounce,
1229
- E as ensureArray,
1230
- Z as escapeRegExp,
1231
- H as flatten,
1232
- F as hasOwn,
1233
- D as inRange,
1234
- te as isArray,
1235
- ee as isBoolean,
1236
- G as isCollection,
1237
- ne as isDate,
1238
- K as isElement,
1239
- P as isEmpty,
1240
- X as isFunction,
1241
- Q as isNumber,
1242
- se as isObject,
1243
- d as isPlainObject,
1244
- re as isPromise,
1245
- Y as isString,
1246
- A as merge,
1247
- M as noop,
1248
- W as omit,
1249
- $ as once,
1250
- T as parseJson,
1251
- B as pick,
1252
- k as randomInt,
1253
- O as sleep,
1254
- I as slugify,
1255
- S as throttle,
1256
- V as toCamelCase,
1257
- J as toKebabCase,
4
+ o as $,
5
+ n as $$,
6
+ r as BQueryCollection,
7
+ p as BQueryElement,
8
+ h as capitalize,
9
+ a as chunk,
10
+ Q as clamp,
11
+ _ as clone,
12
+ x as compact,
13
+ t as debounce,
14
+ l as ensureArray,
15
+ $ as escapeRegExp,
16
+ c as flatten,
17
+ L as hasOwn,
18
+ v as inRange,
19
+ P as isArray,
20
+ w as isBoolean,
21
+ k as isCollection,
22
+ C as isDate,
23
+ R as isElement,
24
+ b as isEmpty,
25
+ D as isFunction,
26
+ E as isNumber,
27
+ B as isObject,
28
+ T as isPlainObject,
29
+ I as isPromise,
30
+ d as isString,
31
+ K as merge,
32
+ i as noop,
33
+ J as omit,
34
+ m as once,
35
+ e as parseJson,
36
+ M as pick,
37
+ f as randomInt,
38
+ S as sleep,
39
+ N as slugify,
40
+ A as throttle,
41
+ j as toCamelCase,
42
+ O as toKebabCase,
1258
43
  q as toNumber,
1259
- _ as truncate,
1260
- j as uid,
1261
- C as unique,
1262
- ue as utils
44
+ g as truncate,
45
+ y as uid,
46
+ u as unique,
47
+ F as utils
1263
48
  };
1264
- //# sourceMappingURL=core.es.mjs.map