sibujs 4.11.0 → 4.12.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 (79) hide show
  1. package/README.md +2 -2
  2. package/dist/browser.cjs +1 -1
  3. package/dist/browser.js +4 -4
  4. package/dist/build.cjs +19 -1
  5. package/dist/build.js +13 -12
  6. package/dist/cdn.dev.global.js +12 -12
  7. package/dist/cdn.full.dev.global.js +13 -13
  8. package/dist/cdn.full.global.js +12 -12
  9. package/dist/cdn.global.js +12 -12
  10. package/dist/{chunk-FC6KCJSA.js → chunk-2F4PSJ5Z.js} +162 -67
  11. package/dist/{chunk-R244COCR.js → chunk-653KGQS2.js} +3 -3
  12. package/dist/chunk-AM6DZLBM.js +181 -0
  13. package/dist/{chunk-ADWDDJ5M.js → chunk-B2Y5BJSP.js} +1 -1
  14. package/dist/{chunk-KREPZR2U.js → chunk-CI4W6XAU.js} +4 -4
  15. package/dist/{chunk-NBBFF5VA.js → chunk-DFZL3AX7.js} +6 -6
  16. package/dist/{chunk-OJV2RW4D.js → chunk-EMB5PG7V.js} +1 -1
  17. package/dist/{chunk-3ACAAQIN.js → chunk-F2UWOZ6J.js} +4 -0
  18. package/dist/{chunk-REOAVT2M.js → chunk-HXT2RNH5.js} +1 -1
  19. package/dist/{chunk-F6B5CKF7.js → chunk-IHA62NGJ.js} +1 -1
  20. package/dist/{chunk-VZDMHDVA.js → chunk-LEUEKK4G.js} +2 -2
  21. package/dist/{chunk-WQ7M57JJ.js → chunk-LXBMVGVB.js} +3 -3
  22. package/dist/{chunk-RRKGQKPU.js → chunk-LYTUTXQP.js} +4 -4
  23. package/dist/{chunk-5IODQRR3.js → chunk-NAVLCP4S.js} +4 -4
  24. package/dist/{chunk-YXJHLMRH.js → chunk-NB7TFSJE.js} +5 -5
  25. package/dist/{chunk-5G53CC6L.js → chunk-QLG5IK7F.js} +4 -4
  26. package/dist/{chunk-KFJUMC3Q.js → chunk-RK7EPQPG.js} +1 -1
  27. package/dist/{chunk-LQ2C44YH.js → chunk-T5O2CUHV.js} +1 -1
  28. package/dist/{chunk-CHQPJY47.js → chunk-WFRQ6D7H.js} +1 -1
  29. package/dist/{chunk-3Z7AEJMQ.js → chunk-WH4U2VUE.js} +5 -3
  30. package/dist/{chunk-HMOPAC2Z.js → chunk-XX4BRMWF.js} +15 -3
  31. package/dist/{chunk-7V7VFT7E.js → chunk-ZJCHY2IB.js} +1 -1
  32. package/dist/{chunk-MCPL5WKQ.js → chunk-ZPY2UAKM.js} +3 -3
  33. package/dist/{chunk-DEUONJYR.js → chunk-ZTYCCBU3.js} +19 -11
  34. package/dist/data.cjs +1 -1
  35. package/dist/data.js +5 -5
  36. package/dist/devtools.cjs +1 -1
  37. package/dist/devtools.js +4 -4
  38. package/dist/ecosystem.cjs +9 -1
  39. package/dist/ecosystem.d.cts +1 -1
  40. package/dist/ecosystem.d.ts +1 -1
  41. package/dist/ecosystem.js +8 -8
  42. package/dist/extras.cjs +368 -154
  43. package/dist/extras.d.cts +2 -2
  44. package/dist/extras.d.ts +2 -2
  45. package/dist/extras.js +23 -22
  46. package/dist/index.cjs +19 -1
  47. package/dist/index.d.cts +91 -90
  48. package/dist/index.d.ts +91 -90
  49. package/dist/index.js +13 -12
  50. package/dist/motion.cjs +1 -1
  51. package/dist/motion.js +3 -3
  52. package/dist/patterns.cjs +1 -1
  53. package/dist/patterns.js +5 -5
  54. package/dist/performance.cjs +1 -1
  55. package/dist/performance.d.cts +2 -2
  56. package/dist/performance.d.ts +2 -2
  57. package/dist/performance.js +7 -6
  58. package/dist/plugins.cjs +344 -109
  59. package/dist/plugins.d.cts +1 -1
  60. package/dist/plugins.d.ts +1 -1
  61. package/dist/plugins.js +15 -12
  62. package/dist/{ssr-C8hgIAw7.d.cts → ssr-Db0Sgdu3.d.cts} +7 -4
  63. package/dist/{ssr-C8hgIAw7.d.ts → ssr-Db0Sgdu3.d.ts} +7 -4
  64. package/dist/{ssr-5OWAH3U2.js → ssr-VBM6J5SJ.js} +4 -2
  65. package/dist/ssr.cjs +346 -128
  66. package/dist/ssr.d.cts +1 -1
  67. package/dist/ssr.d.ts +1 -1
  68. package/dist/ssr.js +10 -9
  69. package/dist/{tagFactory-BL2fymez.d.ts → tagFactory-Bnd_Nph9.d.ts} +1 -1
  70. package/dist/{tagFactory-8qL9LCIx.d.cts → tagFactory-DkytnJws.d.cts} +1 -1
  71. package/dist/testing.cjs +1 -1
  72. package/dist/testing.js +2 -2
  73. package/dist/ui.cjs +251 -24
  74. package/dist/ui.d.cts +111 -1
  75. package/dist/ui.d.ts +111 -1
  76. package/dist/ui.js +130 -8
  77. package/dist/widgets.cjs +1 -1
  78. package/dist/widgets.js +6 -6
  79. package/package.json +1 -1
package/dist/plugins.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { A as Accessor } from './signal-EotCj4hS.js';
2
2
  import { C as Component$1, N as NodeChildren } from './types-CJFViL6Q.js';
3
- import { T as TrustedHTML } from './ssr-C8hgIAw7.js';
3
+ import { T as TrustedHTML } from './ssr-Db0Sgdu3.js';
4
4
  export { P as PluginContext, a as PluginInstallCancelledError, b as PluginRegistry, S as SibuPlugin, c as createPlugin, d as createPluginRegistry, i as inject, e as isPluginInstallCancelledError, p as plugin, r as resetPlugins, s as setDefaultPluginRegistry, t as triggerPluginError, f as triggerPluginMount, g as triggerPluginUnmount } from './plugin-DVgSnTfK.js';
5
5
  export { L as LazyModule, M as Migration, a as MigrationStorageError, P as PackageExportTarget, S as SemVer, V as VERSION, b as bundlerMetadata, c as checkCompatibility, d as compareSemVer, e as createBootSequence, f as createBundle, g as createMigrationRunner, h as createModuleRegistry, i as createSSRCache, j as createTestHarness, k as deferNonCritical, l as env, m as healthCheck, n as lazyModule, p as packageInfo, o as parseSemVer, q as preloadCritical, r as prerenderRoutes, s as satisfies } from './startup-BLfSeL15.js';
6
6
 
package/dist/plugins.js CHANGED
@@ -19,7 +19,7 @@ import {
19
19
  preloadCritical,
20
20
  prerenderRoutes,
21
21
  satisfies
22
- } from "./chunk-R244COCR.js";
22
+ } from "./chunk-653KGQS2.js";
23
23
  import {
24
24
  PluginInstallCancelledError,
25
25
  createPlugin,
@@ -35,12 +35,13 @@ import {
35
35
  } from "./chunk-J6FW5TV6.js";
36
36
  import {
37
37
  span
38
- } from "./chunk-LQ2C44YH.js";
38
+ } from "./chunk-T5O2CUHV.js";
39
39
  import {
40
40
  escapeScriptJson,
41
41
  renderToString,
42
42
  serializeHeadEntry
43
- } from "./chunk-FC6KCJSA.js";
43
+ } from "./chunk-2F4PSJ5Z.js";
44
+ import "./chunk-AM6DZLBM.js";
44
45
  import {
45
46
  isUnsafeKey,
46
47
  readOwnGlobal
@@ -48,17 +49,17 @@ import {
48
49
  import {
49
50
  appendChildren,
50
51
  resolveClassValue
51
- } from "./chunk-3Z7AEJMQ.js";
52
+ } from "./chunk-WH4U2VUE.js";
52
53
  import {
53
54
  setSafeAttribute
54
- } from "./chunk-HMOPAC2Z.js";
55
- import "./chunk-3ACAAQIN.js";
55
+ } from "./chunk-XX4BRMWF.js";
56
+ import "./chunk-F2UWOZ6J.js";
56
57
  import {
57
58
  globalSingleton
58
59
  } from "./chunk-7ZHH77QA.js";
59
60
  import {
60
61
  effect
61
- } from "./chunk-OJV2RW4D.js";
62
+ } from "./chunk-EMB5PG7V.js";
62
63
  import {
63
64
  sanitizeUrl,
64
65
  stripControlChars
@@ -69,14 +70,14 @@ import {
69
70
  import "./chunk-5HZXGZ6T.js";
70
71
  import {
71
72
  signal
72
- } from "./chunk-F6B5CKF7.js";
73
+ } from "./chunk-IHA62NGJ.js";
73
74
  import {
74
75
  bindOwnerScope,
75
76
  getOwnerScope,
76
77
  runWithOwnerScope,
77
78
  track,
78
79
  untracked
79
- } from "./chunk-ADWDDJ5M.js";
80
+ } from "./chunk-B2Y5BJSP.js";
80
81
  import {
81
82
  devWarn,
82
83
  dispose,
@@ -1080,7 +1081,9 @@ var _SibuRouter = class _SibuRouter {
1080
1081
  }
1081
1082
  updateHistory(to, options) {
1082
1083
  const search = serializeQuery(to.queryAll);
1083
- const fullPath = this.options.base + to.path + (search ? `?${search}` : "") + (to.hash ? `#${to.hash}` : "");
1084
+ const routeUrl = to.path + (search ? `?${search}` : "") + (to.hash ? `#${to.hash}` : "");
1085
+ const loc = globalThis.location;
1086
+ const fullPath = this.options.mode === "hash" ? `${loc ? loc.pathname + loc.search : ""}#${routeUrl}` : this.options.base + routeUrl;
1084
1087
  const h = globalThis.history;
1085
1088
  if (!h) return;
1086
1089
  if (options.replace) {
@@ -1855,7 +1858,7 @@ function RouterLink(props, children) {
1855
1858
  const targetPath = normalizePathname(hrefPathRaw);
1856
1859
  const targetQuery = queryIdentity(hrefQueryRaw);
1857
1860
  const link = document.createElement("a");
1858
- link.href = href;
1861
+ link.href = kind === "internal" && _routerRef.current["options"].mode === "hash" ? `#${href}` : href;
1859
1862
  if (target) {
1860
1863
  link.target = target;
1861
1864
  if (target === "_blank") {
@@ -2446,7 +2449,7 @@ function hydrateRouter(routes, options) {
2446
2449
  const liveUrl = `${window.location.pathname}${window.location.search}${window.location.hash}`;
2447
2450
  const resolved = resolveServerRoute(liveUrl, routes);
2448
2451
  const bootstrapEpoch = __getNavigationEpoch();
2449
- import("./ssr-5OWAH3U2.js").then(async ({ hydrate }) => {
2452
+ import("./ssr-VBM6J5SJ.js").then(async ({ hydrate }) => {
2450
2453
  const { replaceChildrenSafely } = await import("./dispose-GEIG2KOF.js");
2451
2454
  if (__getNavigationEpoch() !== bootstrapEpoch) return;
2452
2455
  if (resolved.component) {
@@ -1,10 +1,13 @@
1
1
  /**
2
- * Converts an HTMLElement tree to an HTML string for server-side rendering.
2
+ * Converts an element tree to an HTML string for server-side rendering.
3
+ * HTML, SVG and MathML elements are serialized; SVG and MathML keep the case
4
+ * of their tag and attribute names and their `xlink:` / `xml:` prefixes.
3
5
  *
4
6
  * Security: attribute names are validated, `on*` handlers are dropped,
5
- * URL-bearing attributes are routed through `sanitizeUrl`, and attribute
6
- * values are escaped against both `"` and `'`. `<script>` and `<style>`
7
- * tags are stripped from the serialized output.
7
+ * URL-bearing attributes are routed through `sanitizeUrl`, attribute
8
+ * values are escaped against both `"` and `'`, and an SVG animation may not
9
+ * target a URL or handler attribute. `<script>` and `<style>` tags are
10
+ * stripped from the serialized output.
8
11
  */
9
12
  declare function renderToString(element: HTMLElement | DocumentFragment | Node): string;
10
13
  interface HydrateOptions {
@@ -1,10 +1,13 @@
1
1
  /**
2
- * Converts an HTMLElement tree to an HTML string for server-side rendering.
2
+ * Converts an element tree to an HTML string for server-side rendering.
3
+ * HTML, SVG and MathML elements are serialized; SVG and MathML keep the case
4
+ * of their tag and attribute names and their `xlink:` / `xml:` prefixes.
3
5
  *
4
6
  * Security: attribute names are validated, `on*` handlers are dropped,
5
- * URL-bearing attributes are routed through `sanitizeUrl`, and attribute
6
- * values are escaped against both `"` and `'`. `<script>` and `<style>`
7
- * tags are stripped from the serialized output.
7
+ * URL-bearing attributes are routed through `sanitizeUrl`, attribute
8
+ * values are escaped against both `"` and `'`, and an SVG animation may not
9
+ * target a URL or handler attribute. `<script>` and `<style>` tags are
10
+ * stripped from the serialized output.
8
11
  */
9
12
  declare function renderToString(element: HTMLElement | DocumentFragment | Node): string;
10
13
  interface HydrateOptions {
@@ -17,9 +17,11 @@ import {
17
17
  ssrSuspense,
18
18
  suspenseSwapScript,
19
19
  trustHTML
20
- } from "./chunk-FC6KCJSA.js";
20
+ } from "./chunk-2F4PSJ5Z.js";
21
+ import "./chunk-AM6DZLBM.js";
21
22
  import "./chunk-62BDYGAG.js";
22
- import "./chunk-3ACAAQIN.js";
23
+ import "./chunk-F2UWOZ6J.js";
24
+ import "./chunk-7ZHH77QA.js";
23
25
  import "./chunk-EXXSN3BW.js";
24
26
  import "./chunk-7XHATCIH.js";
25
27
  import "./chunk-NYNYSPK7.js";