bitboss-ui 2.1.73 → 2.1.75

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 (178) hide show
  1. package/dist/components/BbRows/BbRows.vue.d.ts +3 -3
  2. package/dist/components/BbTable/BbTable.vue.d.ts +30 -6
  3. package/dist/components/BbTable/types.d.ts +46 -28
  4. package/dist/components/BbTable/utils.d.ts +23 -0
  5. package/dist/composables/useBbConfig.d.ts +5 -1
  6. package/dist/index.css +1 -1
  7. package/dist/index107.js +9 -9
  8. package/dist/index112.js +1 -1
  9. package/dist/index114.js +1 -1
  10. package/dist/index120.js +1 -1
  11. package/dist/index122.js +326 -304
  12. package/dist/index13.js +64 -33
  13. package/dist/index130.js +1 -1
  14. package/dist/index132.js +4 -4
  15. package/dist/index134.js +1 -1
  16. package/dist/index136.js +2 -2
  17. package/dist/index15.js +5 -5
  18. package/dist/index17.js +3 -3
  19. package/dist/index19.js +8 -8
  20. package/dist/index21.js +14 -14
  21. package/dist/index217.js +1 -1
  22. package/dist/index218.js +1 -1
  23. package/dist/index219.js +4 -34
  24. package/dist/index220.js +13 -9
  25. package/dist/index221.js +20 -2
  26. package/dist/index222.js +201 -4
  27. package/dist/index224.js +127 -3
  28. package/dist/{index225.js → index226.js} +1 -1
  29. package/dist/index228.js +27 -15
  30. package/dist/index229.js +15 -49
  31. package/dist/index23.js +11 -11
  32. package/dist/index230.js +48 -12
  33. package/dist/index231.js +15 -3
  34. package/dist/index232.js +3 -12
  35. package/dist/index233.js +11 -15
  36. package/dist/index234.js +15 -12
  37. package/dist/index235.js +13 -13
  38. package/dist/index237.js +32 -3
  39. package/dist/index238.js +27 -19
  40. package/dist/index240.js +4 -0
  41. package/dist/index241.js +11 -127
  42. package/dist/index242.js +10 -0
  43. package/dist/index243.js +9 -10
  44. package/dist/index244.js +3 -3
  45. package/dist/index245.js +2 -4
  46. package/dist/index246.js +2 -5
  47. package/dist/index247.js +9 -5
  48. package/dist/index248.js +34 -5
  49. package/dist/index249.js +2 -5
  50. package/dist/index25.js +2 -2
  51. package/dist/index250.js +3 -2
  52. package/dist/index251.js +187 -5
  53. package/dist/index252.js +4 -8
  54. package/dist/index253.js +7 -266
  55. package/dist/index254.js +40 -51
  56. package/dist/index255.js +5 -52
  57. package/dist/index256.js +5 -32
  58. package/dist/index257.js +5 -60
  59. package/dist/index258.js +5 -3
  60. package/dist/index259.js +2 -188
  61. package/dist/index260.js +6 -3
  62. package/dist/index261.js +266 -16
  63. package/dist/index262.js +52 -12
  64. package/dist/index263.js +47 -101
  65. package/dist/index264.js +34 -0
  66. package/dist/index265.js +55 -95
  67. package/dist/index266.js +6 -0
  68. package/dist/index267.js +22 -228
  69. package/dist/index268.js +106 -3
  70. package/dist/index27.js +1 -1
  71. package/dist/index270.js +99 -15
  72. package/dist/index272.js +3 -5
  73. package/dist/index273.js +3 -5
  74. package/dist/index274.js +9 -2
  75. package/dist/index275.js +23 -33
  76. package/dist/index276.js +5 -28
  77. package/dist/index277.js +7 -0
  78. package/dist/index278.js +5 -2
  79. package/dist/index279.js +5 -2
  80. package/dist/index280.js +18 -2
  81. package/dist/index281.js +11 -6
  82. package/dist/index282.js +229 -7
  83. package/dist/index283.js +8 -9
  84. package/dist/index284.js +2 -23
  85. package/dist/index285.js +6 -22
  86. package/dist/index286.js +7 -7
  87. package/dist/index287.js +10 -9
  88. package/dist/index288.js +3 -67
  89. package/dist/index289.js +67 -2
  90. package/dist/index29.js +2 -2
  91. package/dist/index290.js +7 -9
  92. package/dist/index291.js +6 -5
  93. package/dist/index292.js +16 -8
  94. package/dist/index294.js +3 -4
  95. package/dist/index295.js +5 -0
  96. package/dist/index296.js +1 -1
  97. package/dist/index297.js +2 -2
  98. package/dist/index298.js +1 -1
  99. package/dist/index299.js +1 -1
  100. package/dist/index301.js +4 -4
  101. package/dist/index302.js +2 -280
  102. package/dist/index303.js +4 -2
  103. package/dist/index304.js +277 -13
  104. package/dist/index305.js +2 -2
  105. package/dist/index306.js +9 -9
  106. package/dist/index308.js +12 -23
  107. package/dist/index31.js +2 -2
  108. package/dist/index310.js +27 -2
  109. package/dist/index311.js +2 -2
  110. package/dist/index312.js +1 -1
  111. package/dist/index313.js +1 -1
  112. package/dist/index314.js +1 -1
  113. package/dist/index315.js +2 -3
  114. package/dist/index316.js +2 -3
  115. package/dist/index317.js +5 -4
  116. package/dist/index318.js +3 -719
  117. package/dist/index319.js +3 -366
  118. package/dist/index320.js +123 -55
  119. package/dist/index321.js +2 -5
  120. package/dist/index322.js +15 -3
  121. package/dist/index323.js +2 -3
  122. package/dist/index324.js +19 -2
  123. package/dist/index325.js +2 -125
  124. package/dist/index326.js +4 -2
  125. package/dist/index327.js +2 -15
  126. package/dist/index328.js +2 -2
  127. package/dist/index329.js +5 -18
  128. package/dist/index33.js +8 -8
  129. package/dist/index330.js +8 -2
  130. package/dist/index331.js +6 -2
  131. package/dist/index332.js +8 -6
  132. package/dist/index333.js +34 -6
  133. package/dist/index334.js +6 -5
  134. package/dist/index335.js +128 -6
  135. package/dist/index336.js +395 -16
  136. package/dist/index337.js +58 -9
  137. package/dist/index338.js +57 -14
  138. package/dist/index339.js +227 -7
  139. package/dist/index340.js +6 -5
  140. package/dist/index341.js +19 -8
  141. package/dist/index342.js +8 -34
  142. package/dist/index343.js +15 -6
  143. package/dist/index344.js +5 -129
  144. package/dist/index345.js +6 -397
  145. package/dist/index346.js +92 -46
  146. package/dist/index347.js +719 -93
  147. package/dist/index348.js +365 -57
  148. package/dist/index349.js +56 -57
  149. package/dist/index35.js +4 -4
  150. package/dist/index350.js +131 -225
  151. package/dist/index353.js +44 -131
  152. package/dist/index37.js +17 -17
  153. package/dist/index39.js +6 -6
  154. package/dist/index4.js +12 -10
  155. package/dist/index41.js +2 -2
  156. package/dist/index43.js +8 -8
  157. package/dist/index45.js +6 -6
  158. package/dist/index49.js +1 -1
  159. package/dist/index53.js +1 -1
  160. package/dist/index55.js +1 -1
  161. package/dist/index57.js +2 -2
  162. package/dist/index61.js +4 -4
  163. package/dist/index67.js +1 -1
  164. package/dist/index80.js +5 -5
  165. package/dist/index82.js +1 -1
  166. package/dist/index84.js +2 -2
  167. package/dist/index86.js +3 -3
  168. package/dist/index88.js +1 -1
  169. package/dist/index91.js +2 -2
  170. package/dist/index93.js +2 -2
  171. package/dist/index95.js +4 -4
  172. package/package.json +1 -1
  173. package/dist/index223.js +0 -4
  174. package/dist/index227.js +0 -31
  175. package/dist/index239.js +0 -203
  176. package/dist/index269.js +0 -8
  177. package/dist/index271.js +0 -7
  178. package/dist/index293.js +0 -13
package/dist/index13.js CHANGED
@@ -1,7 +1,8 @@
1
- import { defineComponent as C, computed as a, createBlock as u, openBlock as i, mergeProps as c, withCtx as d, renderSlot as f, createTextVNode as p, toDisplayString as v, resolveDynamicComponent as b } from "vue";
2
- import S from "./index219.js";
3
- import { useFrameworkDetection as k } from "./index220.js";
4
- const P = /* @__PURE__ */ C({
1
+ import { defineComponent as w, getCurrentInstance as P, computed as r, createBlock as c, openBlock as i, mergeProps as f, withCtx as v, renderSlot as d, createTextVNode as p, toDisplayString as h, resolveDynamicComponent as b } from "vue";
2
+ import R from "./index248.js";
3
+ import { useFrameworkDetection as _ } from "./index247.js";
4
+ import { _config as g } from "./index4.js";
5
+ const D = /* @__PURE__ */ w({
5
6
  __name: "BaseButton",
6
7
  props: {
7
8
  activeClass: {},
@@ -31,15 +32,45 @@ const P = /* @__PURE__ */ C({
31
32
  to: {},
32
33
  type: { default: "button" }
33
34
  },
34
- setup(y) {
35
- const e = y, { isInertia: o } = k(), r = a(() => !!(e.href && o && !e.disabled && !e.target || e.to && !e.disabled)), n = a(() => !!(e.href || e.to && e.disabled)), s = a(() => ({
35
+ setup(C) {
36
+ const e = C, { isInertia: a } = _(), S = P(), n = r(() => {
37
+ const t = S?.proxy?.$page?.url;
38
+ if (t)
39
+ try {
40
+ return new URL(t, "http://localhost").pathname;
41
+ } catch {
42
+ return;
43
+ }
44
+ }), k = r(() => {
45
+ if (!a || !e.href || !n.value) return !1;
46
+ try {
47
+ return new URL(e.href, "http://localhost").pathname === n.value;
48
+ } catch {
49
+ return !1;
50
+ }
51
+ }), A = r(() => {
52
+ if (!a || !e.href || !n.value) return !1;
53
+ try {
54
+ return n.value.startsWith(
55
+ new URL(e.href, "http://localhost").pathname
56
+ );
57
+ } catch {
58
+ return !1;
59
+ }
60
+ }), s = r(() => !!(e.href && a && !e.disabled && !e.target || e.to && !e.disabled)), o = r(() => !!(e.href || e.to && e.disabled)), m = r(
61
+ () => e.activeClass ?? g.linkActiveClass
62
+ ), y = r(
63
+ () => e.exactActiveClass ?? g.linkExactActiveClass
64
+ ), l = r(() => ({
36
65
  "base-btn": !0,
37
66
  "base-btn--block": e.block,
38
- "base-btn--disabled": e.disabled
39
- })), m = () => ({
67
+ "base-btn--disabled": e.disabled,
68
+ [m.value]: A.value,
69
+ [y.value]: k.value
70
+ })), B = () => ({
40
71
  disabled: e.disabled,
41
72
  type: e.type
42
- }), g = () => {
73
+ }), F = () => {
43
74
  if (e.disabled)
44
75
  return {
45
76
  "aria-disabled": !0,
@@ -50,42 +81,42 @@ const P = /* @__PURE__ */ C({
50
81
  href: e.href,
51
82
  target: e.target
52
83
  };
53
- return o && (t.data = e.data, t.headers = e.headers, t.method = e.method, t.onBefore = e.onBefore, t.onCancel = e.onCancel, t.onCancelToken = e.onCancelToken, t.onFinish = e.onFinish, t.only = e.only, t.onProgress = e.onProgress, t.onStart = e.onStart, t.onSuccess = e.onSuccess, t.preserveScroll = e.preserveScroll, t.preserveState = e.preserveState, t.queryStringArrayFormat = e.queryStringArrayFormat, t.replace = e.replace), t;
54
- }, h = () => ({
55
- activeClass: e.activeClass,
84
+ return a && (t.data = e.data, t.headers = e.headers, t.method = e.method, t.onBefore = e.onBefore, t.onCancel = e.onCancel, t.onCancelToken = e.onCancelToken, t.onFinish = e.onFinish, t.only = e.only, t.onProgress = e.onProgress, t.onStart = e.onStart, t.onSuccess = e.onSuccess, t.preserveScroll = e.preserveScroll, t.preserveState = e.preserveState, t.queryStringArrayFormat = e.queryStringArrayFormat, t.replace = e.replace), t;
85
+ }, x = () => ({
86
+ activeClass: m.value,
56
87
  ariaCurrentValue: e.ariaCurrentValue,
57
- exactActiveClass: e.exactActiveClass,
88
+ exactActiveClass: y.value,
58
89
  replace: e.replace,
59
90
  target: e.target,
60
91
  to: e.to
61
- }), l = a(() => !r.value && !n.value ? m() : n.value || r.value && o ? g() : r.value ? h() : {});
62
- return (t, B) => r.value ? (i(), u(S, c({
92
+ }), u = r(() => !s.value && !o.value ? B() : o.value || s.value && a ? F() : s.value ? x() : {});
93
+ return (t, $) => s.value ? (i(), c(R, f({
63
94
  key: 0,
64
- class: s.value
65
- }, l.value), {
66
- default: d(() => [
67
- f(t.$slots, "default", {}, () => [
68
- p(v(t.text), 1)
95
+ class: l.value
96
+ }, u.value), {
97
+ default: v(() => [
98
+ d(t.$slots, "default", {}, () => [
99
+ p(h(t.text), 1)
69
100
  ])
70
101
  ]),
71
102
  _: 3
72
- }, 16, ["class"])) : n.value ? (i(), u(b("a"), c({
103
+ }, 16, ["class"])) : o.value ? (i(), c(b("a"), f({
73
104
  key: 1,
74
- class: s.value
75
- }, l.value), {
76
- default: d(() => [
77
- f(t.$slots, "default", {}, () => [
78
- p(v(t.text), 1)
105
+ class: l.value
106
+ }, u.value), {
107
+ default: v(() => [
108
+ d(t.$slots, "default", {}, () => [
109
+ p(h(t.text), 1)
79
110
  ])
80
111
  ]),
81
112
  _: 3
82
- }, 16, ["class"])) : (i(), u(b(t.tag), c({
113
+ }, 16, ["class"])) : (i(), c(b(t.tag), f({
83
114
  key: 2,
84
- class: s.value
85
- }, l.value), {
86
- default: d(() => [
87
- f(t.$slots, "default", {}, () => [
88
- p(v(t.text), 1)
115
+ class: l.value
116
+ }, u.value), {
117
+ default: v(() => [
118
+ d(t.$slots, "default", {}, () => [
119
+ p(h(t.text), 1)
89
120
  ])
90
121
  ]),
91
122
  _: 3
@@ -93,5 +124,5 @@ const P = /* @__PURE__ */ C({
93
124
  }
94
125
  });
95
126
  export {
96
- P as default
127
+ D as default
97
128
  };
package/dist/index130.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as a, createElementBlock as o, openBlock as e, normalizeClass as c, createVNode as l, TransitionGroup as m, withCtx as i, Fragment as p, renderList as u, unref as r, createBlock as f, mergeProps as _ } from "vue";
2
2
  import { useToast as d, state as k } from "./index11.js";
3
- import b from "./index288.js";
3
+ import b from "./index289.js";
4
4
  const $ = /* @__PURE__ */ a({
5
5
  __name: "BbToast",
6
6
  props: {
package/dist/index132.js CHANGED
@@ -1,14 +1,14 @@
1
1
  import { defineComponent as R, mergeModels as U, ref as L, computed as v, useTemplateRef as W, useModel as x, watch as m, onBeforeUnmount as F, createElementBlock as I, openBlock as g, Fragment as _, renderSlot as k, createCommentVNode as C, createVNode as j, normalizeProps as q, mergeProps as B, withCtx as T, createElementVNode as f, normalizeStyle as G, createBlock as H, unref as J } from "vue";
2
2
  import { useId as K } from "./index8.js";
3
- import { useLocale as Q } from "./index235.js";
3
+ import { useLocale as Q } from "./index220.js";
4
4
  import { useUntil as X } from "./index236.js";
5
5
  import Y from "./index13.js";
6
6
  /* empty css */
7
- import Z from "./index241.js";
7
+ import Z from "./index224.js";
8
8
  /* empty css */
9
9
  import { useElementSize as ee } from "./index141.js";
10
- import { extractDomContainer as V } from "./index245.js";
11
- import { parseWidthString as te } from "./index285.js";
10
+ import { extractDomContainer as V } from "./index266.js";
11
+ import { parseWidthString as te } from "./index267.js";
12
12
  const ce = /* @__PURE__ */ R({
13
13
  inheritAttrs: !1,
14
14
  __name: "BbTooltip",
package/dist/index134.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as $, computed as g, resolveComponent as y, createElementBlock as f, openBlock as i, Fragment as k, renderList as h, normalizeClass as b, createElementVNode as s, renderSlot as t, createVNode as v, createSlots as B, withCtx as _, mergeProps as C } from "vue";
2
- import { flattenTree as T } from "./index291.js";
2
+ import { flattenTree as T } from "./index276.js";
3
3
  const w = { class: "bb-tree-row" }, E = { class: "bb-tree-main-content" }, N = /* @__PURE__ */ $({
4
4
  __name: "BbTree",
5
5
  props: {
package/dist/index136.js CHANGED
@@ -5,8 +5,8 @@ import u from "./index86.js";
5
5
  /* empty css */
6
6
  import I from "./index114.js";
7
7
  /* empty css */
8
- import N from "./index275.js";
9
- import g from "./index276.js";
8
+ import N from "./index237.js";
9
+ import g from "./index238.js";
10
10
  /* empty css */
11
11
  const h = { class: "bb-common-input-inner-container__prefix" }, B = { class: "bb-common-input-inner-container__suffix" }, R = /* @__PURE__ */ k({
12
12
  __name: "CommonInputInnerContainer",
package/dist/index15.js CHANGED
@@ -1,15 +1,15 @@
1
1
  import { defineComponent as H, ref as s, computed as M, createBlock as D, openBlock as E, normalizeClass as I, withCtx as l, createVNode as d, unref as u, withDirectives as L, createElementVNode as p, mergeProps as _, renderSlot as r, withModifiers as q, normalizeStyle as N } from "vue";
2
- import { isHex as z } from "./index237.js";
2
+ import { isHex as z } from "./index219.js";
3
3
  import { isNotNil as F } from "./index144.js";
4
4
  import { useId as S } from "./index8.js";
5
- import { useLocale as U } from "./index235.js";
6
- import { vMaska as A } from "./index238.js";
7
- import K from "./index239.js";
5
+ import { useLocale as U } from "./index220.js";
6
+ import { vMaska as A } from "./index221.js";
7
+ import K from "./index222.js";
8
8
  /* empty css */
9
9
  import O from "./index136.js";
10
10
  /* empty css */
11
11
  import P from "./index138.js";
12
- import T from "./index241.js";
12
+ import T from "./index224.js";
13
13
  /* empty css */
14
14
  const j = ["id", "aria-describedby", "aria-invalid", "autocomplete", "autofocus", "disabled", "name", "placeholder", "readonly", "required", "value"], G = ["aria-label"], J = { class: "bb-common-input-inner-container__suffix" }, ie = /* @__PURE__ */ H({
15
15
  __name: "BaseColorInput",
package/dist/index17.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { defineComponent as _, ref as i, computed as t, watch as F, createElementBlock as p, openBlock as h, normalizeProps as d, guardReactiveProps as f, createCommentVNode as L, createElementVNode as s, mergeProps as k, renderSlot as M } from "vue";
2
- import { isCssColor as y } from "./index221.js";
3
- import { booleanishToBoolean as q } from "./index223.js";
4
- import { isEqual as A } from "./index224.js";
2
+ import { isCssColor as y } from "./index240.js";
3
+ import { booleanishToBoolean as q } from "./index245.js";
4
+ import { isEqual as A } from "./index273.js";
5
5
  const N = {
6
6
  "aria-hidden": "true",
7
7
  class: "bb-base-checkbox-container"
package/dist/index19.js CHANGED
@@ -1,15 +1,15 @@
1
1
  import { defineComponent as z, ref as B, toRef as p, computed as G, createBlock as R, openBlock as W, unref as T, withCtx as n, renderSlot as s, normalizeProps as f, guardReactiveProps as h, createVNode as K, mergeProps as w } from "vue";
2
2
  import N from "./index17.js";
3
3
  /* empty css */
4
- import U from "./index225.js";
4
+ import U from "./index226.js";
5
5
  /* empty css */
6
- import { useItemsGetter as q } from "./index227.js";
7
- import { useIndexById as C } from "./index228.js";
8
- import { useBaseOptions as J } from "./index229.js";
9
- import { useCoherence as Q } from "./index230.js";
10
- import { hash as X } from "./index231.js";
11
- import { useHashedWatcher as $ } from "./index232.js";
12
- import { usePrefill as Y } from "./index233.js";
6
+ import { useItemsGetter as q } from "./index228.js";
7
+ import { useIndexById as C } from "./index229.js";
8
+ import { useBaseOptions as J } from "./index230.js";
9
+ import { useCoherence as Q } from "./index231.js";
10
+ import { hash as X } from "./index232.js";
11
+ import { useHashedWatcher as $ } from "./index233.js";
12
+ import { usePrefill as Y } from "./index234.js";
13
13
  const ce = /* @__PURE__ */ z({
14
14
  __name: "BaseCheckboxGroup",
15
15
  props: {
package/dist/index21.js CHANGED
@@ -5,20 +5,20 @@ import { _config as Q } from "./index4.js";
5
5
  import { useId as X } from "./index8.js";
6
6
  import b from "./index13.js";
7
7
  /* empty css */
8
- import d from "./index246.js";
9
- import ee from "./index247.js";
10
- import ae from "./index248.js";
11
- import te from "./index249.js";
12
- import { hash as B } from "./index231.js";
13
- import { last as le } from "./index250.js";
14
- import { validateDateFormat as L } from "./index251.js";
15
- import { useLogger as oe } from "./index252.js";
16
- import re from "./index253.js";
17
- import se from "./index254.js";
18
- import de from "./index255.js";
19
- import S from "./index256.js";
20
- import ie from "./index257.js";
21
- import { useLocale as ne } from "./index235.js";
8
+ import d from "./index255.js";
9
+ import ee from "./index256.js";
10
+ import ae from "./index257.js";
11
+ import te from "./index258.js";
12
+ import { hash as B } from "./index232.js";
13
+ import { last as le } from "./index259.js";
14
+ import { validateDateFormat as L } from "./index260.js";
15
+ import { useLogger as oe } from "./index242.js";
16
+ import re from "./index261.js";
17
+ import se from "./index262.js";
18
+ import de from "./index263.js";
19
+ import S from "./index264.js";
20
+ import ie from "./index265.js";
21
+ import { useLocale as ne } from "./index220.js";
22
22
  const ue = { class: "bb-base-date-picker" }, me = { class: "bb-base-date-picker__body" }, ce = { class: "bb-base-date-picker__controls" }, pe = { class: "sr-only" }, fe = { class: "sr-only" }, be = { class: "sr-only" }, ve = {
23
23
  style: { transform: "rotate(180deg)" },
24
24
  viewBox: "0 0 24 24",
package/dist/index217.js CHANGED
@@ -1,4 +1,4 @@
1
- import { getType as t } from "./index317.js";
1
+ import { getType as t } from "./index326.js";
2
2
  function o(r) {
3
3
  return t(r) === "Array";
4
4
  }
package/dist/index218.js CHANGED
@@ -1,4 +1,4 @@
1
- import { getType as o } from "./index317.js";
1
+ import { getType as o } from "./index326.js";
2
2
  function c(e) {
3
3
  if (o(e) !== "Object")
4
4
  return !1;
package/dist/index219.js CHANGED
@@ -1,36 +1,6 @@
1
- import { defineComponent as a, resolveComponent as o, createBlock as u, openBlock as l, resolveDynamicComponent as m, unref as c, withCtx as p, renderSlot as f } from "vue";
2
- import { _config as e } from "./index4.js";
3
- import { useLogger as i } from "./index252.js";
4
- import { useFrameworkDetection as k } from "./index220.js";
5
- const y = /* @__PURE__ */ a({
6
- __name: "RouterComponent",
7
- setup(g) {
8
- const { isInertia: r, isNuxt: s } = k();
9
- let t;
10
- if (r) {
11
- if (t = o(e.inertiaLinkName), typeof t == "string") {
12
- const { warn: n } = i();
13
- n(
14
- `Inertia link component "${e.inertiaLinkName}" could not be resolved. Ensure you app registers a link component with the name "${e.inertiaLinkName}" or set bitboss-ui config key "inertiaLinkName" to the correct value globally. Please visit ${e.documentationURL}/getting-started to resolve setup issues in bitboss-ui.`
15
- );
16
- }
17
- } else if (s) {
18
- if (t = o(e.nuxtLinkName), typeof t == "string") {
19
- const { warn: n } = i();
20
- n(
21
- `Nuxt link component "${e.nuxtLinkName}" could not be resolved. Ensure you app registers a link component with the name "${e.nuxtLinkName}" or set bitboss-ui config key "nuxtLinkName" to the correct value globally. Please visit ${e.documentationURL}/getting-started to resolve setup issues in bitboss-ui.`
22
- );
23
- }
24
- } else
25
- t = "router-link";
26
- return (n, d) => (l(), u(m(c(t)), null, {
27
- default: p(() => [
28
- f(n.$slots, "default")
29
- ]),
30
- _: 3
31
- }));
32
- }
33
- });
1
+ function x(e) {
2
+ return /^#([A-Fa-f0-9]{6})$/.test(e);
3
+ }
34
4
  export {
35
- y as default
5
+ x as isHex
36
6
  };
package/dist/index220.js CHANGED
@@ -1,11 +1,15 @@
1
- import { getCurrentInstance as e } from "vue";
2
- const s = () => {
3
- const t = e(), n = !!t?.proxy?.$inertia, r = !!t?.proxy?.$nuxt;
4
- return {
5
- isInertia: n,
6
- isNuxt: r
7
- };
8
- };
1
+ import { locales as t } from "./index297.js";
2
+ import { _config as m } from "./index4.js";
3
+ import { get as c } from "./index241.js";
4
+ import { readonly as l, computed as n } from "vue";
5
+ const p = (o, ...r) => l(
6
+ n(() => c(t[m.locale], o).replace(
7
+ /\{(\d+)\}/g,
8
+ (a, e) => r[e]
9
+ ))
10
+ ), d = () => ({
11
+ t: p
12
+ });
9
13
  export {
10
- s as useFrameworkDetection
14
+ d as useLocale
11
15
  };
package/dist/index221.js CHANGED
@@ -1,4 +1,22 @@
1
- const s = (r) => !!r && !!r.match(/^(#|var\(--|(rgb|hsl)a?\()/);
1
+ import { MaskInput as r } from "./index251.js";
2
+ const u = /* @__PURE__ */ new WeakMap(), p = (a, n) => {
3
+ if (a.arg == null || a.instance == null) return;
4
+ const s = "setup" in a.instance.$.type;
5
+ a.arg in a.instance ? a.instance[a.arg] = n : s && console.warn("Maska: please expose `%s` using defineExpose", a.arg);
6
+ }, k = (a, n) => {
7
+ var s;
8
+ const t = a instanceof HTMLInputElement ? a : a.querySelector("input");
9
+ if (t == null || t?.type === "file") return;
10
+ let e = {};
11
+ if (n.value != null && (e = typeof n.value == "string" ? { mask: n.value } : { ...n.value }), n.arg != null) {
12
+ const l = (o) => {
13
+ const i = n.modifiers.unmasked ? o.unmasked : n.modifiers.completed ? o.completed : o.masked;
14
+ p(n, i);
15
+ };
16
+ e.onMaska = e.onMaska == null ? l : Array.isArray(e.onMaska) ? [...e.onMaska, l] : [e.onMaska, l];
17
+ }
18
+ u.has(t) ? (s = u.get(t)) == null || s.update(e) : u.set(t, new r(t, e));
19
+ };
2
20
  export {
3
- s as isCssColor
21
+ k as vMaska
4
22
  };
package/dist/index222.js CHANGED
@@ -1,6 +1,203 @@
1
- import { curry as e } from "./index294.js";
2
- const t = (n, o, r) => n(r) ? o(r) : r, s = e(t);
1
+ import { defineComponent as j, ref as s, onMounted as J, watch as Q, createElementBlock as M, openBlock as S, createElementVNode as x, createTextVNode as L, createCommentVNode as B, toDisplayString as y, unref as w } from "vue";
2
+ import { hexToRgb as K } from "./index330.js";
3
+ import { getHueFromRGB as F } from "./index331.js";
4
+ import { hslToHex as b } from "./index332.js";
5
+ import { useLocale as Z } from "./index220.js";
6
+ const ee = {
7
+ id: "mainCanvasDesc",
8
+ "aria-live": "polite",
9
+ class: "sr-only"
10
+ }, te = { key: 0 }, ae = {
11
+ id: "hueCanvasDesc",
12
+ "aria-live": "polite",
13
+ class: "sr-only"
14
+ }, ne = { key: 0 }, ue = /* @__PURE__ */ j({
15
+ __name: "ColorPallette",
16
+ props: {
17
+ modelValue: {}
18
+ },
19
+ emits: ["update:modelValue"],
20
+ setup(N, { emit: O }) {
21
+ const _ = N, f = O, { t: h } = Z(), o = s(_.modelValue), d = s(
22
+ b(F(...K(o.value ?? "#ff0000")), 100, 50)
23
+ ), T = s(null), i = s(null), r = s(null), l = s({ x: 0, y: 0 }), u = s({ x: 0 }), p = s(!1), P = s(!1), q = () => {
24
+ const e = i.value, t = r.value;
25
+ !e || !t || (e.width = e.offsetWidth, e.height = e.offsetHeight, t.width = t.offsetWidth, t.height = t.offsetHeight, v(), g());
26
+ }, R = () => {
27
+ const e = i.value;
28
+ return e ? e.getContext("2d", { willReadFrequently: !0 }) : null;
29
+ }, v = () => {
30
+ const e = i.value;
31
+ if (!e) return;
32
+ const t = R();
33
+ if (!t) return;
34
+ t.clearRect(0, 0, e.width, e.height);
35
+ const a = t.createLinearGradient(0, 0, e.width, 0);
36
+ a.addColorStop(0, d.value), a.addColorStop(1, "#ffffff");
37
+ const n = t.createLinearGradient(0, 0, 0, e.height);
38
+ n.addColorStop(0, "transparent"), n.addColorStop(1, "#000000"), t.fillStyle = a, t.fillRect(0, 0, e.width, e.height), t.fillStyle = n, t.globalCompositeOperation = "multiply", t.fillRect(0, 0, e.width, e.height), t.globalCompositeOperation = "source-over", t.fillStyle = "#000000", t.strokeStyle = "#000000", t.lineWidth = 1;
39
+ }, m = () => {
40
+ const e = R();
41
+ e && (e.beginPath(), e.arc(
42
+ l.value.x,
43
+ l.value.y,
44
+ 8,
45
+ 0,
46
+ 2 * Math.PI
47
+ ), e.strokeStyle = "#ffffff", e.lineWidth = 2, e.stroke(), e.beginPath(), e.arc(
48
+ l.value.x,
49
+ l.value.y,
50
+ 7,
51
+ 0,
52
+ 2 * Math.PI
53
+ ), e.strokeStyle = "#000000", e.lineWidth = 1, e.stroke(), e.globalCompositeOperation = "source-over");
54
+ }, D = () => {
55
+ const e = r.value;
56
+ return e ? e.getContext("2d", { willReadFrequently: !0 }) : null;
57
+ }, g = () => {
58
+ const e = r.value;
59
+ if (!e) return;
60
+ const t = D();
61
+ if (!t) return;
62
+ const a = t.createLinearGradient(0, 0, e.width, 0);
63
+ for (let n = 0; n <= 360; n += 60)
64
+ a.addColorStop(n / 360, `hsl(${n}, 100%, 50%)`);
65
+ a.addColorStop(1, "hsl(360, 100%, 50%)"), t.fillStyle = a, t.fillRect(0, 0, e.width, e.height), H(), t.fillStyle = "#000000", t.strokeStyle = "#000000", t.lineWidth = 1;
66
+ }, H = () => {
67
+ const e = r.value;
68
+ if (!e) return;
69
+ const t = D();
70
+ if (!t) return;
71
+ const a = 10, n = 16, c = u.value.x - a / 2, k = e.height / 2 - n / 2;
72
+ t.beginPath(), t.roundRect(c, k, a, n, 2), t.strokeStyle = "lightgray", t.stroke(), t.fillStyle = "#ffffff", t.fill();
73
+ }, E = (e) => {
74
+ const t = i.value;
75
+ t && (t.setPointerCapture(e.pointerId), p.value = !0, I(e));
76
+ }, U = (e) => {
77
+ const t = r.value;
78
+ t && (t.setPointerCapture(e.pointerId), P.value = !0, V(e));
79
+ }, I = (e) => {
80
+ const t = i.value;
81
+ if (!t) return;
82
+ const a = t.getBoundingClientRect(), n = Math.max(0, Math.min(t.width - 1, e.clientX - a.left)), c = Math.max(0, Math.min(t.height - 1, e.clientY - a.top));
83
+ l.value = { x: n, y: c }, v(), m(), o.value = C(), f("update:modelValue", o.value);
84
+ }, V = (e) => {
85
+ const t = r.value;
86
+ if (!t) return;
87
+ const a = t.getBoundingClientRect(), n = Math.max(0, Math.min(t.width - 1, e.clientX - a.left));
88
+ u.value = { x: n };
89
+ const c = n / t.width * 360;
90
+ d.value = b(c, 100, 50), g(), v(), m(), o.value = C(), f("update:modelValue", o.value);
91
+ }, G = (e) => {
92
+ p.value ? I(e) : P.value && V(e);
93
+ }, W = (e) => {
94
+ const t = p.value ? i.value : r.value;
95
+ t && t.releasePointerCapture(e.pointerId), p.value = !1, P.value = !1;
96
+ }, X = (e) => {
97
+ switch (e.key) {
98
+ case "ArrowUp":
99
+ l.value.y = Math.max(0, l.value.y - 5);
100
+ break;
101
+ case "ArrowDown":
102
+ l.value.y = Math.min(
103
+ i.value?.height ?? 0,
104
+ l.value.y + 5
105
+ );
106
+ break;
107
+ case "ArrowLeft":
108
+ l.value.x = Math.max(0, l.value.x - 5);
109
+ break;
110
+ case "ArrowRight":
111
+ l.value.x = Math.min(
112
+ i.value?.width ?? 0,
113
+ l.value.x + 5
114
+ );
115
+ break;
116
+ default:
117
+ return;
118
+ }
119
+ v(), m(), o.value = C(), f("update:modelValue", o.value), e.preventDefault();
120
+ }, $ = (e) => {
121
+ switch (e.key) {
122
+ case "ArrowLeft":
123
+ u.value.x = Math.max(0, u.value.x - 5);
124
+ break;
125
+ case "ArrowRight":
126
+ u.value.x = Math.min(
127
+ r.value?.width ?? 0,
128
+ u.value.x + 5
129
+ );
130
+ break;
131
+ default:
132
+ return;
133
+ }
134
+ const a = u.value.x / (r.value?.width ?? 1) * 360;
135
+ d.value = b(a, 100, 50), g(), H(), v(), m(), o.value = C(), f("update:modelValue", o.value), e.preventDefault();
136
+ };
137
+ J(() => {
138
+ q(), A(o.value ?? "#ff0000");
139
+ }), Q(
140
+ () => _.modelValue,
141
+ (e) => {
142
+ !e || e === o.value || (o.value = e, A(e), g(), v());
143
+ }
144
+ );
145
+ const C = () => {
146
+ const e = i.value;
147
+ if (!e) return "#ffffff";
148
+ const t = e.getContext("2d");
149
+ if (!t) return "#ffffff";
150
+ const { x: a, y: n } = l.value, c = t.getImageData(a, n, 1, 1).data, [k, z, Y] = c;
151
+ return `#${((1 << 24) + (k << 16) + (z << 8) + Y).toString(16).slice(1)}`;
152
+ };
153
+ function A(e) {
154
+ const t = F(...K(e));
155
+ d.value = b(t, 100, 50), u.value.x = t / 360 * (r.value?.width ?? 0);
156
+ }
157
+ return (e, t) => (S(), M("span", {
158
+ ref_key: "paletteRef",
159
+ ref: T,
160
+ "aria-label": "Color Picker",
161
+ class: "bb-color-palette",
162
+ role: "application"
163
+ }, [
164
+ x("canvas", {
165
+ ref_key: "mainCanvasRef",
166
+ ref: i,
167
+ "aria-describedby": "mainCanvasDesc",
168
+ "aria-label": "Main Color Selection",
169
+ class: "bb-color-palette__canvas",
170
+ role: "application",
171
+ tabindex: "0",
172
+ onKeydown: X,
173
+ onPointerdown: E,
174
+ onPointermove: G,
175
+ onPointerup: W
176
+ }, null, 544),
177
+ x("span", ee, [
178
+ L(y(w(h)("colorInput.mainCanvasDesc")) + " ", 1),
179
+ o.value ? (S(), M("span", te, y(w(h)("colorInput.mainCanvasSelectedColor", o.value)), 1)) : B("", !0)
180
+ ]),
181
+ x("canvas", {
182
+ ref_key: "hueCanvasRef",
183
+ ref: r,
184
+ "aria-describedby": "hueCanvasDesc",
185
+ "aria-label": "Hue Selection",
186
+ class: "bb-color-palette__hue-canvas",
187
+ role: "application",
188
+ tabindex: "0",
189
+ onKeydown: $,
190
+ onPointerdown: U,
191
+ onPointermove: G,
192
+ onPointerup: W
193
+ }, null, 544),
194
+ x("span", ae, [
195
+ L(y(w(h)("colorInput.hueCanvasDesc")) + " ", 1),
196
+ d.value ? (S(), M("span", ne, y(w(h)("colorInput.hueCanvasSelectedHue", d.value)), 1)) : B("", !0)
197
+ ])
198
+ ], 512));
199
+ }
200
+ });
3
201
  export {
4
- t as baseWhen,
5
- s as when
202
+ ue as default
6
203
  };