@yselimcan/ui 0.0.7 → 0.0.9

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 (266) hide show
  1. package/dist/index.js +15277 -100
  2. package/dist/styles.css +1 -1
  3. package/package.json +9 -12
  4. package/dist/index10.js +0 -137
  5. package/dist/index100.js +0 -7
  6. package/dist/index101.js +0 -69
  7. package/dist/index102.js +0 -11
  8. package/dist/index103.js +0 -16
  9. package/dist/index104.js +0 -6
  10. package/dist/index105.js +0 -6
  11. package/dist/index106.js +0 -8
  12. package/dist/index107.js +0 -32
  13. package/dist/index108.js +0 -14
  14. package/dist/index109.js +0 -69
  15. package/dist/index11.js +0 -21
  16. package/dist/index110.js +0 -56
  17. package/dist/index111.js +0 -15
  18. package/dist/index112.js +0 -8
  19. package/dist/index113.js +0 -15
  20. package/dist/index114.js +0 -15
  21. package/dist/index115.js +0 -35
  22. package/dist/index116.js +0 -21
  23. package/dist/index117.js +0 -43
  24. package/dist/index118.js +0 -21
  25. package/dist/index119.js +0 -14
  26. package/dist/index12.js +0 -20
  27. package/dist/index120.js +0 -40
  28. package/dist/index121.js +0 -16
  29. package/dist/index122.js +0 -11
  30. package/dist/index123.js +0 -15
  31. package/dist/index124.js +0 -8
  32. package/dist/index125.js +0 -90
  33. package/dist/index126.js +0 -299
  34. package/dist/index127.js +0 -14
  35. package/dist/index128.js +0 -128
  36. package/dist/index129.js +0 -7
  37. package/dist/index13.js +0 -206
  38. package/dist/index130.js +0 -266
  39. package/dist/index131.js +0 -82
  40. package/dist/index132.js +0 -41
  41. package/dist/index133.js +0 -23
  42. package/dist/index134.js +0 -14
  43. package/dist/index135.js +0 -59
  44. package/dist/index136.js +0 -14
  45. package/dist/index137.js +0 -14
  46. package/dist/index138.js +0 -33
  47. package/dist/index139.js +0 -21
  48. package/dist/index14.js +0 -24
  49. package/dist/index140.js +0 -69
  50. package/dist/index141.js +0 -107
  51. package/dist/index142.js +0 -11
  52. package/dist/index143.js +0 -11
  53. package/dist/index144.js +0 -25
  54. package/dist/index145.js +0 -106
  55. package/dist/index146.js +0 -10
  56. package/dist/index147.js +0 -35
  57. package/dist/index148.js +0 -233
  58. package/dist/index149.js +0 -77
  59. package/dist/index15.js +0 -19
  60. package/dist/index150.js +0 -286
  61. package/dist/index151.js +0 -56
  62. package/dist/index152.js +0 -48
  63. package/dist/index153.js +0 -79
  64. package/dist/index154.js +0 -6
  65. package/dist/index155.js +0 -17
  66. package/dist/index156.js +0 -18
  67. package/dist/index157.js +0 -31
  68. package/dist/index158.js +0 -10
  69. package/dist/index159.js +0 -25
  70. package/dist/index16.js +0 -8
  71. package/dist/index160.js +0 -27
  72. package/dist/index161.js +0 -163
  73. package/dist/index162.js +0 -116
  74. package/dist/index163.js +0 -67
  75. package/dist/index164.js +0 -78
  76. package/dist/index165.js +0 -67
  77. package/dist/index166.js +0 -72
  78. package/dist/index167.js +0 -16
  79. package/dist/index168.js +0 -10
  80. package/dist/index169.js +0 -8
  81. package/dist/index17.js +0 -46
  82. package/dist/index170.js +0 -20
  83. package/dist/index171.js +0 -24
  84. package/dist/index172.js +0 -61
  85. package/dist/index173.js +0 -20
  86. package/dist/index174.js +0 -30
  87. package/dist/index175.js +0 -45
  88. package/dist/index176.js +0 -24
  89. package/dist/index177.js +0 -51
  90. package/dist/index178.js +0 -54
  91. package/dist/index179.js +0 -20
  92. package/dist/index18.js +0 -41
  93. package/dist/index180.js +0 -14
  94. package/dist/index181.js +0 -38
  95. package/dist/index182.js +0 -18
  96. package/dist/index183.js +0 -82
  97. package/dist/index184.js +0 -26
  98. package/dist/index185.js +0 -6
  99. package/dist/index186.js +0 -14
  100. package/dist/index187.js +0 -13
  101. package/dist/index188.js +0 -43
  102. package/dist/index189.js +0 -7
  103. package/dist/index19.js +0 -80
  104. package/dist/index190.js +0 -12
  105. package/dist/index191.js +0 -14
  106. package/dist/index192.js +0 -120
  107. package/dist/index193.js +0 -14
  108. package/dist/index194.js +0 -90
  109. package/dist/index195.js +0 -15
  110. package/dist/index196.js +0 -65
  111. package/dist/index197.js +0 -6
  112. package/dist/index198.js +0 -7
  113. package/dist/index199.js +0 -14
  114. package/dist/index20.js +0 -25
  115. package/dist/index200.js +0 -8
  116. package/dist/index201.js +0 -24
  117. package/dist/index202.js +0 -6
  118. package/dist/index203.js +0 -29
  119. package/dist/index204.js +0 -130
  120. package/dist/index205.js +0 -47
  121. package/dist/index206.js +0 -20
  122. package/dist/index207.js +0 -7
  123. package/dist/index208.js +0 -183
  124. package/dist/index209.js +0 -78
  125. package/dist/index21.js +0 -40
  126. package/dist/index210.js +0 -401
  127. package/dist/index211.js +0 -202
  128. package/dist/index212.js +0 -50
  129. package/dist/index213.js +0 -22
  130. package/dist/index214.js +0 -50
  131. package/dist/index215.js +0 -9
  132. package/dist/index216.js +0 -7
  133. package/dist/index217.js +0 -19
  134. package/dist/index218.js +0 -17
  135. package/dist/index219.js +0 -35
  136. package/dist/index22.js +0 -31
  137. package/dist/index220.js +0 -6
  138. package/dist/index221.js +0 -14
  139. package/dist/index222.js +0 -12
  140. package/dist/index223.js +0 -41
  141. package/dist/index224.js +0 -59
  142. package/dist/index225.js +0 -30
  143. package/dist/index226.js +0 -10
  144. package/dist/index227.js +0 -15
  145. package/dist/index228.js +0 -14
  146. package/dist/index229.js +0 -14
  147. package/dist/index23.js +0 -25
  148. package/dist/index230.js +0 -24
  149. package/dist/index231.js +0 -14
  150. package/dist/index232.js +0 -10
  151. package/dist/index233.js +0 -45
  152. package/dist/index234.js +0 -599
  153. package/dist/index235.js +0 -14
  154. package/dist/index236.js +0 -6
  155. package/dist/index237.js +0 -211
  156. package/dist/index238.js +0 -6
  157. package/dist/index239.js +0 -16
  158. package/dist/index24.js +0 -56
  159. package/dist/index240.js +0 -50
  160. package/dist/index241.js +0 -15
  161. package/dist/index242.js +0 -60
  162. package/dist/index243.js +0 -32
  163. package/dist/index244.js +0 -16
  164. package/dist/index245.js +0 -11
  165. package/dist/index246.js +0 -209
  166. package/dist/index247.js +0 -17
  167. package/dist/index248.js +0 -324
  168. package/dist/index249.js +0 -5
  169. package/dist/index25.js +0 -35
  170. package/dist/index250.js +0 -5
  171. package/dist/index251.js +0 -23
  172. package/dist/index252.js +0 -8
  173. package/dist/index253.js +0 -489
  174. package/dist/index254.js +0 -10
  175. package/dist/index255.js +0 -4
  176. package/dist/index256.js +0 -46
  177. package/dist/index257.js +0 -58
  178. package/dist/index258.js +0 -10
  179. package/dist/index259.js +0 -4
  180. package/dist/index26.js +0 -7
  181. package/dist/index260.js +0 -57
  182. package/dist/index261.js +0 -58
  183. package/dist/index262.js +0 -4
  184. package/dist/index263.js +0 -4
  185. package/dist/index264.js +0 -4
  186. package/dist/index265.js +0 -4
  187. package/dist/index27.js +0 -82
  188. package/dist/index28.js +0 -32
  189. package/dist/index29.js +0 -6
  190. package/dist/index3.js +0 -181
  191. package/dist/index30.js +0 -9
  192. package/dist/index31.js +0 -6
  193. package/dist/index32.js +0 -23
  194. package/dist/index33.js +0 -207
  195. package/dist/index34.js +0 -25
  196. package/dist/index35.js +0 -102
  197. package/dist/index36.js +0 -69
  198. package/dist/index37.js +0 -66
  199. package/dist/index38.js +0 -113
  200. package/dist/index39.js +0 -53
  201. package/dist/index4.js +0 -47
  202. package/dist/index40.js +0 -35
  203. package/dist/index41.js +0 -28
  204. package/dist/index42.js +0 -18
  205. package/dist/index43.js +0 -27
  206. package/dist/index44.js +0 -25
  207. package/dist/index45.js +0 -36
  208. package/dist/index46.js +0 -78
  209. package/dist/index47.js +0 -65
  210. package/dist/index48.js +0 -128
  211. package/dist/index49.js +0 -19
  212. package/dist/index5.js +0 -52
  213. package/dist/index50.js +0 -86
  214. package/dist/index51.js +0 -6
  215. package/dist/index52.js +0 -268
  216. package/dist/index53.js +0 -25
  217. package/dist/index54.js +0 -207
  218. package/dist/index55.js +0 -146
  219. package/dist/index56.js +0 -88
  220. package/dist/index57.js +0 -29
  221. package/dist/index58.js +0 -30
  222. package/dist/index59.js +0 -48
  223. package/dist/index6.js +0 -93
  224. package/dist/index60.js +0 -79
  225. package/dist/index61.js +0 -45
  226. package/dist/index62.js +0 -46
  227. package/dist/index63.js +0 -76
  228. package/dist/index64.js +0 -45
  229. package/dist/index65.js +0 -22
  230. package/dist/index66.js +0 -101
  231. package/dist/index67.js +0 -14
  232. package/dist/index68.js +0 -6
  233. package/dist/index69.js +0 -321
  234. package/dist/index7.js +0 -294
  235. package/dist/index70.js +0 -24
  236. package/dist/index71.js +0 -143
  237. package/dist/index72.js +0 -200
  238. package/dist/index73.js +0 -43
  239. package/dist/index74.js +0 -29
  240. package/dist/index75.js +0 -148
  241. package/dist/index76.js +0 -32
  242. package/dist/index77.js +0 -53
  243. package/dist/index78.js +0 -28
  244. package/dist/index79.js +0 -15
  245. package/dist/index8.js +0 -264
  246. package/dist/index80.js +0 -15
  247. package/dist/index81.js +0 -135
  248. package/dist/index82.js +0 -31
  249. package/dist/index83.js +0 -35
  250. package/dist/index84.js +0 -17
  251. package/dist/index85.js +0 -2765
  252. package/dist/index86.js +0 -92
  253. package/dist/index87.js +0 -57
  254. package/dist/index88.js +0 -14
  255. package/dist/index89.js +0 -98
  256. package/dist/index9.js +0 -197
  257. package/dist/index90.js +0 -21
  258. package/dist/index91.js +0 -18
  259. package/dist/index92.js +0 -35
  260. package/dist/index93.js +0 -14
  261. package/dist/index94.js +0 -136
  262. package/dist/index95.js +0 -30
  263. package/dist/index96.js +0 -11
  264. package/dist/index97.js +0 -7
  265. package/dist/index98.js +0 -15
  266. package/dist/index99.js +0 -25
package/dist/index35.js DELETED
@@ -1,102 +0,0 @@
1
- "use client";
2
- import * as a from "react";
3
- import { useIsoLayoutEffect as U } from "./index97.js";
4
- import { useStableCallback as _ } from "./index95.js";
5
- import { inertValue as j } from "./index129.js";
6
- import { useScrollLock as B } from "./index141.js";
7
- import { useComboboxRootContext as F, useComboboxDerivedItemsContext as z, useComboboxFloatingContext as T } from "./index223.js";
8
- import { ComboboxPositionerContext as W } from "./index227.js";
9
- import { useAnchorPositioning as q } from "./index130.js";
10
- import { popupStateMapping as G } from "./index120.js";
11
- import { useComboboxPortalContext as J } from "./index228.js";
12
- import { DROPDOWN_COLLISION_AVOIDANCE as K } from "./index133.js";
13
- import { useRenderElement as Q } from "./index87.js";
14
- import { selectors as t } from "./index224.js";
15
- import { InternalBackdrop as X } from "./index132.js";
16
- import { jsxs as Y, jsx as Z } from "react/jsx-runtime";
17
- import { useStore as n } from "./index182.js";
18
- const $ = /* @__PURE__ */ a.forwardRef(function(c, u) {
19
- const {
20
- render: eo,
21
- className: to,
22
- anchor: f,
23
- positionMethod: g = "absolute",
24
- side: b = "bottom",
25
- align: h = "center",
26
- sideOffset: x = 0,
27
- alignOffset: C = 0,
28
- collisionBoundary: P = "clipping-ancestors",
29
- collisionPadding: y = 5,
30
- arrowPadding: E = 5,
31
- sticky: w = !1,
32
- disableAnchorTracking: S = !1,
33
- collisionAvoidance: v = K,
34
- ...I
35
- } = c, e = F(), {
36
- filteredItems: M
37
- } = z(), R = T(), A = J(), l = n(e, t.modal), r = n(e, t.open), i = n(e, t.mounted), O = n(e, t.openMethod), d = n(e, t.triggerElement), m = n(e, t.inputElement), N = n(e, t.inputInsidePopup), p = M.length === 0, o = q({
38
- anchor: f ?? (N ? d : m),
39
- floatingRootContext: R,
40
- positionMethod: g,
41
- mounted: i,
42
- side: b,
43
- sideOffset: x,
44
- align: h,
45
- alignOffset: C,
46
- arrowPadding: E,
47
- collisionBoundary: P,
48
- collisionPadding: y,
49
- sticky: w,
50
- disableAnchorTracking: S,
51
- keepMounted: A,
52
- collisionAvoidance: v,
53
- lazyFlip: !0
54
- });
55
- B(r && l && O !== "touch", d);
56
- const k = a.useMemo(() => {
57
- const s = {
58
- ...o.positionerStyles
59
- };
60
- return r || (s.pointerEvents = "none"), {
61
- role: "presentation",
62
- hidden: !i,
63
- style: s
64
- };
65
- }, [r, i, o.positionerStyles]), H = a.useMemo(() => ({
66
- open: r,
67
- side: o.side,
68
- align: o.align,
69
- anchorHidden: o.anchorHidden,
70
- empty: p
71
- }), [r, o.side, o.align, o.anchorHidden, p]);
72
- U(() => {
73
- e.set("popupSide", o.side);
74
- }, [e, o.side]);
75
- const D = a.useMemo(() => ({
76
- side: o.side,
77
- align: o.align,
78
- arrowRef: o.arrowRef,
79
- arrowUncentered: o.arrowUncentered,
80
- arrowStyles: o.arrowStyles,
81
- anchorHidden: o.anchorHidden,
82
- isPositioned: o.isPositioned
83
- }), [o.side, o.align, o.arrowRef, o.arrowUncentered, o.arrowStyles, o.anchorHidden, o.isPositioned]), L = _((s) => {
84
- e.set("positionerElement", s);
85
- }), V = Q("div", c, {
86
- state: H,
87
- ref: [u, L],
88
- props: [k, I],
89
- stateAttributesMapping: G
90
- });
91
- return /* @__PURE__ */ Y(W.Provider, {
92
- value: D,
93
- children: [i && l && /* @__PURE__ */ Z(X, {
94
- inert: j(!r),
95
- cutout: m ?? d
96
- }), V]
97
- });
98
- });
99
- process.env.NODE_ENV !== "production" && ($.displayName = "ComboboxPositioner");
100
- export {
101
- $ as ComboboxPositioner
102
- };
package/dist/index36.js DELETED
@@ -1,69 +0,0 @@
1
- "use client";
2
- import * as g from "react";
3
- import { useRenderElement as v } from "./index87.js";
4
- import { useComboboxRootContext as P, useComboboxFloatingContext as S, useComboboxDerivedItemsContext as D } from "./index223.js";
5
- import { selectors as e } from "./index224.js";
6
- import { popupStateMapping as y } from "./index120.js";
7
- import { useComboboxPositionerContext as N } from "./index227.js";
8
- import { useOpenChangeComplete as T } from "./index118.js";
9
- import { transitionStatusMapping as H } from "./index121.js";
10
- import { getDisabledMountTransitionStyles as O } from "./index124.js";
11
- import { jsx as j } from "react/jsx-runtime";
12
- import { FloatingFocusManager as w } from "./index126.js";
13
- import { useStore as n } from "./index182.js";
14
- import { getTarget as A, contains as V } from "./index166.js";
15
- const _ = {
16
- ...y,
17
- ...H
18
- }, k = /* @__PURE__ */ g.forwardRef(function(u, b) {
19
- const {
20
- render: z,
21
- className: B,
22
- initialFocus: m,
23
- finalFocus: c,
24
- ...C
25
- } = u, t = P(), o = N(), x = S(), {
26
- filteredItems: F
27
- } = D(), h = n(t, e.mounted), s = n(t, e.open), l = n(t, e.openMethod), p = n(t, e.transitionStatus), i = n(t, e.inputInsidePopup), I = n(t, e.inputElement), d = F.length === 0;
28
- T({
29
- open: s,
30
- ref: t.state.popupRef,
31
- onComplete() {
32
- s && t.state.onOpenChangeComplete(!0);
33
- }
34
- });
35
- const R = g.useMemo(() => ({
36
- open: s,
37
- side: o.side,
38
- align: o.align,
39
- anchorHidden: o.anchorHidden,
40
- transitionStatus: p,
41
- empty: d
42
- }), [s, o.side, o.align, o.anchorHidden, p, d]), M = v("div", u, {
43
- state: R,
44
- ref: [b, t.state.popupRef],
45
- props: [{
46
- role: i ? "dialog" : "presentation",
47
- tabIndex: -1,
48
- onFocus(r) {
49
- const f = A(r.nativeEvent);
50
- l !== "touch" && (V(t.state.listElement, f) || f === r.currentTarget) && t.state.inputRef.current?.focus();
51
- }
52
- }, O(p), C],
53
- stateAttributesMapping: _
54
- }), E = m === void 0 ? i ? (r) => r === "touch" ? t.state.popupRef.current : I : !1 : m;
55
- let a;
56
- return c != null ? a = c : a = i ? void 0 : !1, /* @__PURE__ */ j(w, {
57
- context: x,
58
- disabled: !h,
59
- modal: !i,
60
- openInteractionType: l,
61
- initialFocus: E,
62
- returnFocus: a,
63
- children: M
64
- });
65
- });
66
- process.env.NODE_ENV !== "production" && (k.displayName = "ComboboxPopup");
67
- export {
68
- k as ComboboxPopup
69
- };
package/dist/index37.js DELETED
@@ -1,66 +0,0 @@
1
- "use client";
2
- import * as r from "react";
3
- import { useStableCallback as u } from "./index95.js";
4
- import { useRenderElement as A } from "./index87.js";
5
- import { useComboboxRootContext as K, useComboboxFloatingContext as _, useComboboxDerivedItemsContext as j } from "./index223.js";
6
- import { useComboboxPositionerContext as B } from "./index227.js";
7
- import { selectors as t } from "./index224.js";
8
- import { ComboboxCollection as F } from "./index42.js";
9
- import { CompositeList as V } from "./index131.js";
10
- import { jsx as d } from "react/jsx-runtime";
11
- import { useStore as o } from "./index182.js";
12
- import { stopEvent as q } from "./index225.js";
13
- const G = /* @__PURE__ */ r.forwardRef(function(i, p) {
14
- var l;
15
- const {
16
- render: J,
17
- className: Q,
18
- children: s,
19
- ...b
20
- } = i, e = K(), C = _(), x = !!B(!0), {
21
- filteredItems: v
22
- } = j(), R = o(e, t.items), E = o(e, t.labelsRef), y = o(e, t.listRef), g = o(e, t.selectionMode), I = o(e, t.grid), h = o(e, t.popupProps), P = o(e, t.disabled), k = o(e, t.readOnly), L = o(e, t.virtualized), M = g === "multiple", c = v.length === 0, D = u((n) => {
23
- e.set("positionerElement", n);
24
- }), N = u((n) => {
25
- e.set("listElement", n);
26
- }), w = r.useMemo(() => typeof s == "function" ? l || (l = /* @__PURE__ */ d(F, {
27
- children: s
28
- })) : s, [s]), O = r.useMemo(() => ({
29
- empty: c
30
- }), [c]), S = C.useState("floatingId"), m = A("div", i, {
31
- state: O,
32
- ref: [p, N, x ? null : D],
33
- props: [h, {
34
- children: w,
35
- tabIndex: -1,
36
- id: S,
37
- role: I ? "grid" : "listbox",
38
- "aria-multiselectable": M ? "true" : void 0,
39
- onKeyDown(n) {
40
- if (!(P || k) && n.key === "Enter") {
41
- const a = e.state.activeIndex;
42
- if (a == null)
43
- return;
44
- q(n);
45
- const z = n.nativeEvent, f = e.state.listRef.current[a];
46
- f && (e.state.selectionEventRef.current = z, f.click(), e.state.selectionEventRef.current = null);
47
- }
48
- },
49
- onKeyDownCapture() {
50
- e.state.keyboardActiveRef.current = !0;
51
- },
52
- onPointerMoveCapture() {
53
- e.state.keyboardActiveRef.current = !1;
54
- }
55
- }, b]
56
- });
57
- return L ? m : /* @__PURE__ */ d(V, {
58
- elementsRef: y,
59
- labelsRef: R ? void 0 : E,
60
- children: m
61
- });
62
- });
63
- process.env.NODE_ENV !== "production" && (G.displayName = "ComboboxList");
64
- export {
65
- G as ComboboxList
66
- };
package/dist/index38.js DELETED
@@ -1,113 +0,0 @@
1
- "use client";
2
- import * as l from "react";
3
- import * as j from "react-dom";
4
- import { useIsoLayoutEffect as C } from "./index97.js";
5
- import { useComboboxRootContext as U, useComboboxDerivedItemsContext as W } from "./index223.js";
6
- import { useCompositeListItem as _, IndexGuessBehavior as H } from "./index110.js";
7
- import { useRenderElement as J } from "./index87.js";
8
- import { ComboboxItemContext as K } from "./index231.js";
9
- import { selectors as n } from "./index224.js";
10
- import { useComboboxRowContext as Q } from "./index232.js";
11
- import { findItemIndex as X, compareItemEquality as Y } from "./index179.js";
12
- import { jsx as Z } from "react/jsx-runtime";
13
- import { useButton as ee } from "./index86.js";
14
- import { useStore as s } from "./index182.js";
15
- const te = /* @__PURE__ */ l.memo(/* @__PURE__ */ l.forwardRef(function(E, M) {
16
- const {
17
- render: ne,
18
- className: se,
19
- value: i = null,
20
- index: a,
21
- disabled: c = !1,
22
- nativeButton: O = !1,
23
- ...w
24
- } = E, m = l.useRef(!1), x = l.useRef(null), b = _({
25
- index: a,
26
- textRef: x,
27
- indexGuessBehavior: H.GuessFromOrder
28
- }), e = U(), B = Q(), {
29
- flatFilteredItems: q
30
- } = W(), P = s(e, n.open), I = s(e, n.selectionMode), S = s(e, n.readOnly), v = s(e, n.virtualized), R = s(e, n.isItemEqualToValue), V = I !== "none", o = a ?? (v ? X(q, i, R) : b.index), u = b.index !== -1, g = s(e, n.id), f = s(e, n.isActive, o), N = s(e, n.isSelected, i), p = s(e, n.items), A = s(e, n.getItemProps), y = l.useRef(null), F = g != null && u ? `${g}-${o}` : void 0, d = N && V;
31
- C(() => {
32
- if (!(u && (v || a != null)))
33
- return;
34
- const r = e.state.listRef.current;
35
- return r[o] = y.current, () => {
36
- delete r[o];
37
- };
38
- }, [u, v, o, a, e]), C(() => {
39
- if (!u || p)
40
- return;
41
- const t = e.state.valuesRef.current;
42
- return t[o] = i, I !== "none" && e.state.allValuesRef.current.push(i), () => {
43
- delete t[o];
44
- };
45
- }, [u, p, o, i, e, I]), C(() => {
46
- if (!P) {
47
- m.current = !1;
48
- return;
49
- }
50
- if (!u || p)
51
- return;
52
- const t = e.state.selectedValue, r = Array.isArray(t) ? t[t.length - 1] : t;
53
- Y(r, i, R) && e.set("selectedIndex", o);
54
- }, [u, p, P, e, o, i, R]);
55
- const G = l.useMemo(() => ({
56
- disabled: c,
57
- selected: d,
58
- highlighted: f
59
- }), [c, d, f]), h = A({
60
- active: f,
61
- selected: d
62
- });
63
- h.id = void 0, h.onFocus = void 0;
64
- const {
65
- getButtonProps: k,
66
- buttonRef: z
67
- } = ee({
68
- disabled: c,
69
- focusableWhenDisabled: !0,
70
- native: O
71
- });
72
- function D(t) {
73
- function r() {
74
- e.state.handleSelection(t, i);
75
- }
76
- e.state.submitOnItemClick ? (j.flushSync(r), e.state.requestSubmit()) : r();
77
- }
78
- const L = {
79
- id: F,
80
- role: B ? "gridcell" : "option",
81
- "aria-disabled": c || void 0,
82
- "aria-selected": V ? d : void 0,
83
- // Focusable items steal focus from the input upon mouseup.
84
- // Warn if the user renders a natively focusable element like `<button>`,
85
- // as it should be a `<div>` instead.
86
- tabIndex: void 0,
87
- onPointerDownCapture(t) {
88
- m.current = !0, t.preventDefault();
89
- },
90
- onClick(t) {
91
- c || S || D(t.nativeEvent);
92
- },
93
- onMouseUp(t) {
94
- const r = m.current;
95
- m.current = !1, !(c || S || t.button !== 0 || r || !f) && D(t.nativeEvent);
96
- }
97
- }, T = J("div", E, {
98
- ref: [z, M, b.ref, y],
99
- state: G,
100
- props: [h, L, w, k]
101
- }), $ = l.useMemo(() => ({
102
- selected: d,
103
- textRef: x
104
- }), [d, x]);
105
- return /* @__PURE__ */ Z(K.Provider, {
106
- value: $,
107
- children: T
108
- });
109
- }));
110
- process.env.NODE_ENV !== "production" && (te.displayName = "ComboboxItem");
111
- export {
112
- te as ComboboxItem
113
- };
package/dist/index39.js DELETED
@@ -1,53 +0,0 @@
1
- "use client";
2
- import * as t from "react";
3
- import { useComboboxItemContext as d } from "./index231.js";
4
- import { useTransitionStatus as b } from "./index117.js";
5
- import { useOpenChangeComplete as I } from "./index118.js";
6
- import { useRenderElement as C } from "./index87.js";
7
- import { transitionStatusMapping as R } from "./index121.js";
8
- import { jsx as x } from "react/jsx-runtime";
9
- const M = /* @__PURE__ */ t.forwardRef(function(o, r) {
10
- const s = o.keepMounted ?? !1, {
11
- selected: i
12
- } = d();
13
- return s || i ? /* @__PURE__ */ x(p, {
14
- ...o,
15
- ref: r
16
- }) : null;
17
- });
18
- process.env.NODE_ENV !== "production" && (M.displayName = "ComboboxItemIndicator");
19
- const p = /* @__PURE__ */ t.memo(/* @__PURE__ */ t.forwardRef((n, o) => {
20
- const {
21
- render: r,
22
- className: s,
23
- keepMounted: i,
24
- ...m
25
- } = n, {
26
- selected: e
27
- } = d(), a = t.useRef(null), {
28
- transitionStatus: u,
29
- setMounted: c
30
- } = b(e), f = t.useMemo(() => ({
31
- selected: e,
32
- transitionStatus: u
33
- }), [e, u]), l = C("span", n, {
34
- ref: [o, a],
35
- state: f,
36
- props: [{
37
- "aria-hidden": !0,
38
- children: "✔️"
39
- }, m],
40
- stateAttributesMapping: R
41
- });
42
- return I({
43
- open: e,
44
- ref: a,
45
- onComplete() {
46
- e || c(!1);
47
- }
48
- }), l;
49
- }));
50
- process.env.NODE_ENV !== "production" && (p.displayName = "Inner");
51
- export {
52
- M as ComboboxItemIndicator
53
- };
package/dist/index4.js DELETED
@@ -1,47 +0,0 @@
1
- import { cva as a } from "./index25.js";
2
- import { cn as o } from "./index16.js";
3
- import { useRender as n } from "./index26.js";
4
- import { mergeProps as d } from "./index27.js";
5
- const s = a(
6
- "h-5 gap-1 rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium transition-all has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&>svg]:size-3! inline-flex items-center justify-center w-fit whitespace-nowrap shrink-0 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-colors overflow-hidden group/badge",
7
- {
8
- variants: {
9
- variant: {
10
- default: "bg-primary text-primary-foreground [a]:hover:bg-primary/80",
11
- secondary: "bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",
12
- destructive: "bg-destructive/10 [a]:hover:bg-destructive/20 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 text-destructive dark:bg-destructive/20",
13
- outline: "border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground",
14
- ghost: "hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50",
15
- link: "text-primary underline-offset-4 hover:underline"
16
- }
17
- },
18
- defaultVariants: {
19
- variant: "default"
20
- }
21
- }
22
- );
23
- function l({
24
- className: r,
25
- variant: e = "default",
26
- render: t,
27
- ...i
28
- }) {
29
- return n({
30
- defaultTagName: "span",
31
- props: d(
32
- {
33
- className: o(s({ className: r, variant: e }))
34
- },
35
- i
36
- ),
37
- render: t,
38
- state: {
39
- slot: "badge",
40
- variant: e
41
- }
42
- });
43
- }
44
- export {
45
- l as Badge,
46
- s as badgeVariants
47
- };
package/dist/index40.js DELETED
@@ -1,35 +0,0 @@
1
- "use client";
2
- import * as r from "react";
3
- import { useRenderElement as u } from "./index87.js";
4
- import { ComboboxGroupContext as c } from "./index229.js";
5
- import { GroupCollectionProvider as d } from "./index230.js";
6
- import { jsx as s } from "react/jsx-runtime";
7
- const b = /* @__PURE__ */ r.forwardRef(function(t, i) {
8
- const {
9
- render: x,
10
- className: C,
11
- items: e,
12
- ...l
13
- } = t, [o, m] = r.useState(), p = r.useMemo(() => ({
14
- labelId: o,
15
- setLabelId: m,
16
- items: e
17
- }), [o, m, e]), a = u("div", t, {
18
- ref: i,
19
- props: [{
20
- role: "group",
21
- "aria-labelledby": o
22
- }, l]
23
- }), n = /* @__PURE__ */ s(c.Provider, {
24
- value: p,
25
- children: a
26
- });
27
- return e ? /* @__PURE__ */ s(d, {
28
- items: e,
29
- children: n
30
- }) : n;
31
- });
32
- process.env.NODE_ENV !== "production" && (b.displayName = "ComboboxGroup");
33
- export {
34
- b as ComboboxGroup
35
- };
package/dist/index41.js DELETED
@@ -1,28 +0,0 @@
1
- "use client";
2
- import * as n from "react";
3
- import { useIsoLayoutEffect as i } from "./index97.js";
4
- import { useBaseUiId as p } from "./index112.js";
5
- import { useComboboxGroupContext as u } from "./index229.js";
6
- import { useRenderElement as a } from "./index87.js";
7
- const d = /* @__PURE__ */ n.forwardRef(function(r, t) {
8
- const {
9
- render: b,
10
- className: c,
11
- id: s,
12
- ...m
13
- } = r, {
14
- setLabelId: e
15
- } = u(), o = p(s);
16
- return i(() => (e(o), () => {
17
- e(void 0);
18
- }), [o, e]), a("div", r, {
19
- ref: t,
20
- props: [{
21
- id: o
22
- }, m]
23
- });
24
- });
25
- process.env.NODE_ENV !== "production" && (d.displayName = "ComboboxGroupLabel");
26
- export {
27
- d as ComboboxGroupLabel
28
- };
package/dist/index42.js DELETED
@@ -1,18 +0,0 @@
1
- "use client";
2
- import * as m from "react";
3
- import { useComboboxDerivedItemsContext as i } from "./index223.js";
4
- import { useGroupCollectionContext as s } from "./index230.js";
5
- import { jsx as c } from "react/jsx-runtime";
6
- function f(e) {
7
- const {
8
- children: r
9
- } = e, {
10
- filteredItems: n
11
- } = i(), o = s(), t = o ? o.items : n;
12
- return t ? /* @__PURE__ */ c(m.Fragment, {
13
- children: t.map(r)
14
- }) : null;
15
- }
16
- export {
17
- f as ComboboxCollection
18
- };
package/dist/index43.js DELETED
@@ -1,27 +0,0 @@
1
- "use client";
2
- import * as i from "react";
3
- import { useRenderElement as l } from "./index87.js";
4
- import { useComboboxDerivedItemsContext as a, useComboboxRootContext as c } from "./index223.js";
5
- const p = /* @__PURE__ */ i.forwardRef(function(e, o) {
6
- const {
7
- render: b,
8
- className: f,
9
- children: t,
10
- ...r
11
- } = e, {
12
- filteredItems: s
13
- } = a(), m = c(), n = s.length === 0 ? t : null;
14
- return l("div", e, {
15
- ref: [o, m.state.emptyRef],
16
- props: [{
17
- children: n,
18
- role: "status",
19
- "aria-live": "polite",
20
- "aria-atomic": !0
21
- }, r]
22
- });
23
- });
24
- process.env.NODE_ENV !== "production" && (p.displayName = "ComboboxEmpty");
25
- export {
26
- p as ComboboxEmpty
27
- };
package/dist/index44.js DELETED
@@ -1,25 +0,0 @@
1
- "use client";
2
- import * as o from "react";
3
- import { useRenderElement as s } from "./index87.js";
4
- const i = /* @__PURE__ */ o.forwardRef(function(r, t) {
5
- const {
6
- className: m,
7
- render: c,
8
- orientation: e = "horizontal",
9
- ...a
10
- } = r, n = o.useMemo(() => ({
11
- orientation: e
12
- }), [e]);
13
- return s("div", r, {
14
- state: n,
15
- ref: t,
16
- props: [{
17
- role: "separator",
18
- "aria-orientation": e
19
- }, a]
20
- });
21
- });
22
- process.env.NODE_ENV !== "production" && (i.displayName = "Separator");
23
- export {
24
- i as Separator
25
- };
package/dist/index45.js DELETED
@@ -1,36 +0,0 @@
1
- "use client";
2
- import * as e from "react";
3
- import { useRenderElement as h } from "./index87.js";
4
- import { ComboboxChipsContext as u } from "./index226.js";
5
- import { CompositeList as C } from "./index131.js";
6
- import { useComboboxRootContext as l } from "./index223.js";
7
- import { selectors as a } from "./index224.js";
8
- import { jsx as n } from "react/jsx-runtime";
9
- import { useStore as x } from "./index182.js";
10
- const b = /* @__PURE__ */ e.forwardRef(function(i, m) {
11
- const {
12
- render: g,
13
- className: v,
14
- ...p
15
- } = i, r = l(), f = x(r, a.open), [o, t] = e.useState(void 0);
16
- f && o !== void 0 && t(void 0);
17
- const s = e.useRef([]), c = h("div", i, {
18
- ref: [m, r.state.chipsContainerRef],
19
- props: p
20
- }), d = e.useMemo(() => ({
21
- highlightedChipIndex: o,
22
- setHighlightedChipIndex: t,
23
- chipsRef: s
24
- }), [o, t, s]);
25
- return /* @__PURE__ */ n(u.Provider, {
26
- value: d,
27
- children: /* @__PURE__ */ n(C, {
28
- elementsRef: s,
29
- children: c
30
- })
31
- });
32
- });
33
- process.env.NODE_ENV !== "production" && (b.displayName = "ComboboxChips");
34
- export {
35
- b as ComboboxChips
36
- };