@dooherceg/tiptap-controlled-editor-with-table 0.0.9 → 0.0.11

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 (125) hide show
  1. package/dist/Combination-CO0ZtURs.js +1333 -0
  2. package/dist/assets/{components/tiptap-ui-primitive/badge/badge-colors.css → badge.css} +1 -1
  3. package/dist/assets/{components/tiptap-ui-primitive/button/button-colors.css → button.css} +1 -1
  4. package/dist/assets/simple-editor.css +1 -0
  5. package/dist/components/tiptap-node/horizontal-rule-node/horizontal-rule-node-extension.js +58 -6
  6. package/dist/components/tiptap-node/image-upload-node/image-upload-node.js +4 -5
  7. package/dist/components/tiptap-templates/simple/simple-editor.d.ts +3 -1
  8. package/dist/components/tiptap-templates/simple/simple-editor.js +1970 -201
  9. package/dist/components/tiptap-templates/simple/theme-toggle.js +7 -7
  10. package/dist/components/tiptap-ui/blockquote-button/blockquote-button.js +10 -10
  11. package/dist/components/tiptap-ui/color-highlight-button/color-highlight-button.js +5 -6
  12. package/dist/components/tiptap-ui/color-highlight-button/use-color-highlight.js +1 -1
  13. package/dist/components/tiptap-ui/color-highlight-popover/color-highlight-popover.js +16 -16
  14. package/dist/components/tiptap-ui/heading-button/heading-button.js +9 -9
  15. package/dist/components/tiptap-ui/heading-dropdown-menu/heading-dropdown-menu.js +37 -29
  16. package/dist/components/tiptap-ui/heading-dropdown-menu/use-heading-dropdown-menu.js +14 -13
  17. package/dist/components/tiptap-ui/image-upload-button/use-image-upload.js +16 -16
  18. package/dist/components/tiptap-ui/insert-table-button/insert-table-button.js +9 -9
  19. package/dist/components/tiptap-ui/link-popover/link-popover.js +13 -13
  20. package/dist/components/tiptap-ui/list-button/list-button.js +7 -7
  21. package/dist/components/tiptap-ui/list-dropdown-menu/list-dropdown-menu.js +24 -20
  22. package/dist/components/tiptap-ui/list-dropdown-menu/use-list-dropdown-menu.js +6 -5
  23. package/dist/components/tiptap-ui/table-actions-toolbar/table-actions-toolbar.js +28 -28
  24. package/dist/components/tiptap-ui-primitive/badge/badge.js +16 -19
  25. package/dist/components/tiptap-ui-primitive/button/button.js +19 -22
  26. package/dist/components/tiptap-ui-primitive/card/card.js +12 -13
  27. package/dist/components/tiptap-ui-primitive/dropdown-menu/dropdown-menu.js +1012 -39
  28. package/dist/components/tiptap-ui-primitive/input/input.js +6 -7
  29. package/dist/components/tiptap-ui-primitive/popover/popover.js +233 -24
  30. package/dist/components/tiptap-ui-primitive/separator/separator.js +8 -9
  31. package/dist/components/tiptap-ui-primitive/toolbar/toolbar.js +7 -8
  32. package/dist/components/tiptap-ui-primitive/tooltip/tooltip.js +1330 -84
  33. package/dist/floating-ui.react-dom-DgOuULHo.js +1334 -0
  34. package/dist/hooks/use-throttled-callback.js +108 -13
  35. package/dist/{node_modules/react-hotkeys-hook/packages/react-hotkeys-hook/dist/index.js → index-Bqw9S4qP.js} +55 -57
  36. package/package.json +1 -1
  37. package/dist/_virtual/_commonjsHelpers.js +0 -8
  38. package/dist/_virtual/index.js +0 -7
  39. package/dist/assets/components/tiptap-node/blockquote-node/blockquote-node.css +0 -1
  40. package/dist/assets/components/tiptap-node/code-block-node/code-block-node.css +0 -1
  41. package/dist/assets/components/tiptap-node/heading-node/heading-node.css +0 -1
  42. package/dist/assets/components/tiptap-node/horizontal-rule-node/horizontal-rule-node.css +0 -1
  43. package/dist/assets/components/tiptap-node/image-node/image-node.css +0 -1
  44. package/dist/assets/components/tiptap-node/list-node/list-node.css +0 -1
  45. package/dist/assets/components/tiptap-node/paragraph-node/paragraph-node.css +0 -1
  46. package/dist/assets/components/tiptap-templates/simple/simple-editor.css +0 -1
  47. package/dist/assets/components/tiptap-ui-primitive/badge/badge-group.css +0 -1
  48. package/dist/assets/components/tiptap-ui-primitive/badge/badge.css +0 -1
  49. package/dist/assets/components/tiptap-ui-primitive/button/button-group.css +0 -1
  50. package/dist/assets/components/tiptap-ui-primitive/button/button.css +0 -1
  51. package/dist/assets/styles/_keyframe-animations.css +0 -1
  52. package/dist/assets/styles/_variables.css +0 -1
  53. package/dist/node_modules/@floating-ui/core/dist/floating-ui.core.js +0 -527
  54. package/dist/node_modules/@floating-ui/dom/dist/floating-ui.dom.js +0 -402
  55. package/dist/node_modules/@floating-ui/react/dist/floating-ui.react.js +0 -932
  56. package/dist/node_modules/@floating-ui/react/dist/floating-ui.react.utils.js +0 -185
  57. package/dist/node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.js +0 -208
  58. package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.js +0 -136
  59. package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.js +0 -130
  60. package/dist/node_modules/@radix-ui/primitive/dist/index.js +0 -9
  61. package/dist/node_modules/@radix-ui/react-arrow/dist/index.js +0 -24
  62. package/dist/node_modules/@radix-ui/react-collection/dist/index.js +0 -48
  63. package/dist/node_modules/@radix-ui/react-compose-refs/dist/index.js +0 -29
  64. package/dist/node_modules/@radix-ui/react-context/dist/index.js +0 -53
  65. package/dist/node_modules/@radix-ui/react-direction/dist/index.js +0 -10
  66. package/dist/node_modules/@radix-ui/react-dismissable-layer/dist/index.js +0 -127
  67. package/dist/node_modules/@radix-ui/react-dropdown-menu/dist/index.js +0 -221
  68. package/dist/node_modules/@radix-ui/react-focus-guards/dist/index.js +0 -17
  69. package/dist/node_modules/@radix-ui/react-focus-scope/dist/index.js +0 -136
  70. package/dist/node_modules/@radix-ui/react-id/dist/index.js +0 -13
  71. package/dist/node_modules/@radix-ui/react-menu/dist/index.js +0 -636
  72. package/dist/node_modules/@radix-ui/react-popover/dist/index.js +0 -239
  73. package/dist/node_modules/@radix-ui/react-popper/dist/index.js +0 -219
  74. package/dist/node_modules/@radix-ui/react-portal/dist/index.js +0 -15
  75. package/dist/node_modules/@radix-ui/react-presence/dist/index.js +0 -70
  76. package/dist/node_modules/@radix-ui/react-primitive/dist/index.js +0 -36
  77. package/dist/node_modules/@radix-ui/react-roving-focus/dist/index.js +0 -183
  78. package/dist/node_modules/@radix-ui/react-slot/dist/index.js +0 -49
  79. package/dist/node_modules/@radix-ui/react-use-callback-ref/dist/index.js +0 -10
  80. package/dist/node_modules/@radix-ui/react-use-controllable-state/dist/index.js +0 -52
  81. package/dist/node_modules/@radix-ui/react-use-escape-keydown/dist/index.js +0 -14
  82. package/dist/node_modules/@radix-ui/react-use-layout-effect/dist/index.js +0 -6
  83. package/dist/node_modules/@radix-ui/react-use-size/dist/index.js +0 -27
  84. package/dist/node_modules/@tiptap/extension-highlight/dist/index.js +0 -84
  85. package/dist/node_modules/@tiptap/extension-horizontal-rule/dist/index.js +0 -57
  86. package/dist/node_modules/@tiptap/extension-image/dist/index.js +0 -128
  87. package/dist/node_modules/@tiptap/extension-list/dist/index.js +0 -713
  88. package/dist/node_modules/@tiptap/extension-subscript/dist/index.js +0 -40
  89. package/dist/node_modules/@tiptap/extension-superscript/dist/index.js +0 -40
  90. package/dist/node_modules/@tiptap/extension-table/dist/index.js +0 -380
  91. package/dist/node_modules/@tiptap/extension-text-align/dist/index.js +0 -46
  92. package/dist/node_modules/@tiptap/extension-typography/dist/index.js +0 -125
  93. package/dist/node_modules/@tiptap/extensions/dist/index.js +0 -288
  94. package/dist/node_modules/aria-hidden/dist/es2015/index.js +0 -52
  95. package/dist/node_modules/get-nonce/dist/es2015/index.js +0 -7
  96. package/dist/node_modules/lodash.throttle/index.js +0 -95
  97. package/dist/node_modules/react-remove-scroll/dist/es2015/Combination.js +0 -11
  98. package/dist/node_modules/react-remove-scroll/dist/es2015/SideEffect.js +0 -112
  99. package/dist/node_modules/react-remove-scroll/dist/es2015/UI.js +0 -31
  100. package/dist/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js +0 -16
  101. package/dist/node_modules/react-remove-scroll/dist/es2015/handleScroll.js +0 -68
  102. package/dist/node_modules/react-remove-scroll/dist/es2015/medium.js +0 -5
  103. package/dist/node_modules/react-remove-scroll/dist/es2015/sidecar.js +0 -7
  104. package/dist/node_modules/react-remove-scroll-bar/dist/es2015/component.js +0 -71
  105. package/dist/node_modules/react-remove-scroll-bar/dist/es2015/constants.js +0 -7
  106. package/dist/node_modules/react-remove-scroll-bar/dist/es2015/utils.js +0 -25
  107. package/dist/node_modules/react-style-singleton/dist/es2015/component.js +0 -11
  108. package/dist/node_modules/react-style-singleton/dist/es2015/hook.js +0 -15
  109. package/dist/node_modules/react-style-singleton/dist/es2015/singleton.js +0 -30
  110. package/dist/node_modules/tabbable/dist/index.esm.js +0 -197
  111. package/dist/node_modules/tslib/tslib.es6.js +0 -27
  112. package/dist/node_modules/use-callback-ref/dist/es2015/assignRef.js +0 -6
  113. package/dist/node_modules/use-callback-ref/dist/es2015/useMergeRef.js +0 -26
  114. package/dist/node_modules/use-callback-ref/dist/es2015/useRef.js +0 -25
  115. package/dist/node_modules/use-sidecar/dist/es2015/exports.js +0 -18
  116. package/dist/node_modules/use-sidecar/dist/es2015/medium.js +0 -67
  117. /package/dist/assets/{components/tiptap-ui-primitive/card/card.css → card.css} +0 -0
  118. /package/dist/assets/{components/tiptap-ui/color-highlight-button/color-highlight-button.css → color-highlight-button.css} +0 -0
  119. /package/dist/assets/{components/tiptap-ui-primitive/dropdown-menu/dropdown-menu.css → dropdown-menu.css} +0 -0
  120. /package/dist/assets/{components/tiptap-node/image-upload-node/image-upload-node.css → image-upload-node.css} +0 -0
  121. /package/dist/assets/{components/tiptap-ui-primitive/input/input.css → input.css} +0 -0
  122. /package/dist/assets/{components/tiptap-ui-primitive/popover/popover.css → popover.css} +0 -0
  123. /package/dist/assets/{components/tiptap-ui-primitive/separator/separator.css → separator.css} +0 -0
  124. /package/dist/assets/{components/tiptap-ui-primitive/toolbar/toolbar.css → toolbar.css} +0 -0
  125. /package/dist/assets/{components/tiptap-ui-primitive/tooltip/tooltip.css → tooltip.css} +0 -0
@@ -1,17 +1,16 @@
1
1
  import { jsx as r } from "react/jsx-runtime";
2
- import { cn as i } from "../../../lib/tiptap-utils.js";
3
- import '../../../assets/components/tiptap-ui-primitive/input/input.css';/* empty css */
4
- function a({ className: t, type: p, ...n }) {
5
- return /* @__PURE__ */ r("input", { type: p, className: i("tiptap-input", t), ...n });
2
+ import { cn as u } from "../../../lib/tiptap-utils.js";
3
+ import '../../../assets/input.css';function a({ className: t, type: p, ...n }) {
4
+ return /* @__PURE__ */ r("input", { type: p, className: u("tiptap-input", t), ...n });
6
5
  }
7
- function c({
6
+ function m({
8
7
  className: t,
9
8
  children: p,
10
9
  ...n
11
10
  }) {
12
- return /* @__PURE__ */ r("div", { className: i("tiptap-input-group", t), ...n, children: p });
11
+ return /* @__PURE__ */ r("div", { className: u("tiptap-input-group", t), ...n, children: p });
13
12
  }
14
13
  export {
15
14
  a as Input,
16
- c as InputGroup
15
+ m as InputGroup
17
16
  };
@@ -1,35 +1,244 @@
1
- import { jsx as r } from "react/jsx-runtime";
2
- import { Root as p, Trigger as i, Portal as m, Content as c } from "../../../node_modules/@radix-ui/react-popover/dist/index.js";
3
- import { cn as a } from "../../../lib/tiptap-utils.js";
4
- import '../../../assets/components/tiptap-ui-primitive/popover/popover.css';/* empty css */
5
- function v({
6
- ...o
7
- }) {
8
- return /* @__PURE__ */ r(p, { ...o });
1
+ import { jsx as s } from "react/jsx-runtime";
2
+ import * as p from "react";
3
+ import { c as O, u as $, R as L, a as G, b as H, d as _, P as x, e as P, A as w, f as E, g as j, h as K, i as U, j as V, k as W, F as Z, D as q, C as z, l as B } from "../../../Combination-CO0ZtURs.js";
4
+ import { cn as J } from "../../../lib/tiptap-utils.js";
5
+ import '../../../assets/popover.css';var R = "Popover", [b] = G(R, [
6
+ O
7
+ ]), g = O(), [Q, u] = b(R), F = (e) => {
8
+ const {
9
+ __scopePopover: n,
10
+ children: o,
11
+ open: a,
12
+ defaultOpen: r,
13
+ onOpenChange: t,
14
+ modal: c = !1
15
+ } = e, i = g(n), f = p.useRef(null), [v, h] = p.useState(!1), [C, l] = $({
16
+ prop: a,
17
+ defaultProp: r ?? !1,
18
+ onChange: t,
19
+ caller: R
20
+ });
21
+ return /* @__PURE__ */ s(L, { ...i, children: /* @__PURE__ */ s(
22
+ Q,
23
+ {
24
+ scope: n,
25
+ contentId: H(),
26
+ triggerRef: f,
27
+ open: C,
28
+ onOpenChange: l,
29
+ onOpenToggle: p.useCallback(() => l((m) => !m), [l]),
30
+ hasCustomAnchor: v,
31
+ onCustomAnchorAdd: p.useCallback(() => h(!0), []),
32
+ onCustomAnchorRemove: p.useCallback(() => h(!1), []),
33
+ modal: c,
34
+ children: o
35
+ }
36
+ ) });
37
+ };
38
+ F.displayName = R;
39
+ var N = "PopoverAnchor", X = p.forwardRef(
40
+ (e, n) => {
41
+ const { __scopePopover: o, ...a } = e, r = u(N, o), t = g(o), { onCustomAnchorAdd: c, onCustomAnchorRemove: i } = r;
42
+ return p.useEffect(() => (c(), () => i()), [c, i]), /* @__PURE__ */ s(w, { ...t, ...a, ref: n });
43
+ }
44
+ );
45
+ X.displayName = N;
46
+ var S = "PopoverTrigger", y = p.forwardRef(
47
+ (e, n) => {
48
+ const { __scopePopover: o, ...a } = e, r = u(S, o), t = g(o), c = _(n, r.triggerRef), i = /* @__PURE__ */ s(
49
+ x.button,
50
+ {
51
+ type: "button",
52
+ "aria-haspopup": "dialog",
53
+ "aria-expanded": r.open,
54
+ "aria-controls": r.contentId,
55
+ "data-state": I(r.open),
56
+ ...a,
57
+ ref: c,
58
+ onClick: P(e.onClick, r.onOpenToggle)
59
+ }
60
+ );
61
+ return r.hasCustomAnchor ? i : /* @__PURE__ */ s(w, { asChild: !0, ...t, children: i });
62
+ }
63
+ );
64
+ y.displayName = S;
65
+ var A = "PopoverPortal", [Y, ee] = b(A, {
66
+ forceMount: void 0
67
+ }), D = (e) => {
68
+ const { __scopePopover: n, forceMount: o, children: a, container: r } = e, t = u(A, n);
69
+ return /* @__PURE__ */ s(Y, { scope: n, forceMount: o, children: /* @__PURE__ */ s(E, { present: o || t.open, children: /* @__PURE__ */ s(j, { asChild: !0, container: r, children: a }) }) });
70
+ };
71
+ D.displayName = A;
72
+ var d = "PopoverContent", M = p.forwardRef(
73
+ (e, n) => {
74
+ const o = ee(d, e.__scopePopover), { forceMount: a = o.forceMount, ...r } = e, t = u(d, e.__scopePopover);
75
+ return /* @__PURE__ */ s(E, { present: a || t.open, children: t.modal ? /* @__PURE__ */ s(re, { ...r, ref: n }) : /* @__PURE__ */ s(te, { ...r, ref: n }) });
76
+ }
77
+ );
78
+ M.displayName = d;
79
+ var oe = V("PopoverContent.RemoveScroll"), re = p.forwardRef(
80
+ (e, n) => {
81
+ const o = u(d, e.__scopePopover), a = p.useRef(null), r = _(n, a), t = p.useRef(!1);
82
+ return p.useEffect(() => {
83
+ const c = a.current;
84
+ if (c) return K(c);
85
+ }, []), /* @__PURE__ */ s(U, { as: oe, allowPinchZoom: !0, children: /* @__PURE__ */ s(
86
+ k,
87
+ {
88
+ ...e,
89
+ ref: r,
90
+ trapFocus: o.open,
91
+ disableOutsidePointerEvents: !0,
92
+ onCloseAutoFocus: P(e.onCloseAutoFocus, (c) => {
93
+ c.preventDefault(), t.current || o.triggerRef.current?.focus();
94
+ }),
95
+ onPointerDownOutside: P(
96
+ e.onPointerDownOutside,
97
+ (c) => {
98
+ const i = c.detail.originalEvent, f = i.button === 0 && i.ctrlKey === !0, v = i.button === 2 || f;
99
+ t.current = v;
100
+ },
101
+ { checkForDefaultPrevented: !1 }
102
+ ),
103
+ onFocusOutside: P(
104
+ e.onFocusOutside,
105
+ (c) => c.preventDefault(),
106
+ { checkForDefaultPrevented: !1 }
107
+ )
108
+ }
109
+ ) });
110
+ }
111
+ ), te = p.forwardRef(
112
+ (e, n) => {
113
+ const o = u(d, e.__scopePopover), a = p.useRef(!1), r = p.useRef(!1);
114
+ return /* @__PURE__ */ s(
115
+ k,
116
+ {
117
+ ...e,
118
+ ref: n,
119
+ trapFocus: !1,
120
+ disableOutsidePointerEvents: !1,
121
+ onCloseAutoFocus: (t) => {
122
+ e.onCloseAutoFocus?.(t), t.defaultPrevented || (a.current || o.triggerRef.current?.focus(), t.preventDefault()), a.current = !1, r.current = !1;
123
+ },
124
+ onInteractOutside: (t) => {
125
+ e.onInteractOutside?.(t), t.defaultPrevented || (a.current = !0, t.detail.originalEvent.type === "pointerdown" && (r.current = !0));
126
+ const c = t.target;
127
+ o.triggerRef.current?.contains(c) && t.preventDefault(), t.detail.originalEvent.type === "focusin" && r.current && t.preventDefault();
128
+ }
129
+ }
130
+ );
131
+ }
132
+ ), k = p.forwardRef(
133
+ (e, n) => {
134
+ const {
135
+ __scopePopover: o,
136
+ trapFocus: a,
137
+ onOpenAutoFocus: r,
138
+ onCloseAutoFocus: t,
139
+ disableOutsidePointerEvents: c,
140
+ onEscapeKeyDown: i,
141
+ onPointerDownOutside: f,
142
+ onFocusOutside: v,
143
+ onInteractOutside: h,
144
+ ...C
145
+ } = e, l = u(d, o), m = g(o);
146
+ return W(), /* @__PURE__ */ s(
147
+ Z,
148
+ {
149
+ asChild: !0,
150
+ loop: !0,
151
+ trapped: a,
152
+ onMountAutoFocus: r,
153
+ onUnmountAutoFocus: t,
154
+ children: /* @__PURE__ */ s(
155
+ q,
156
+ {
157
+ asChild: !0,
158
+ disableOutsidePointerEvents: c,
159
+ onInteractOutside: h,
160
+ onEscapeKeyDown: i,
161
+ onPointerDownOutside: f,
162
+ onFocusOutside: v,
163
+ onDismiss: () => l.onOpenChange(!1),
164
+ children: /* @__PURE__ */ s(
165
+ z,
166
+ {
167
+ "data-state": I(l.open),
168
+ role: "dialog",
169
+ id: l.contentId,
170
+ ...m,
171
+ ...C,
172
+ ref: n,
173
+ style: {
174
+ ...C.style,
175
+ "--radix-popover-content-transform-origin": "var(--radix-popper-transform-origin)",
176
+ "--radix-popover-content-available-width": "var(--radix-popper-available-width)",
177
+ "--radix-popover-content-available-height": "var(--radix-popper-available-height)",
178
+ "--radix-popover-trigger-width": "var(--radix-popper-anchor-width)",
179
+ "--radix-popover-trigger-height": "var(--radix-popper-anchor-height)"
180
+ }
181
+ }
182
+ )
183
+ }
184
+ )
185
+ }
186
+ );
187
+ }
188
+ ), T = "PopoverClose", ne = p.forwardRef(
189
+ (e, n) => {
190
+ const { __scopePopover: o, ...a } = e, r = u(T, o);
191
+ return /* @__PURE__ */ s(
192
+ x.button,
193
+ {
194
+ type: "button",
195
+ ...a,
196
+ ref: n,
197
+ onClick: P(e.onClick, () => r.onOpenChange(!1))
198
+ }
199
+ );
200
+ }
201
+ );
202
+ ne.displayName = T;
203
+ var ae = "PopoverArrow", se = p.forwardRef(
204
+ (e, n) => {
205
+ const { __scopePopover: o, ...a } = e, r = g(o);
206
+ return /* @__PURE__ */ s(B, { ...r, ...a, ref: n });
207
+ }
208
+ );
209
+ se.displayName = ae;
210
+ function I(e) {
211
+ return e ? "open" : "closed";
9
212
  }
10
- function P({
11
- ...o
213
+ var ce = F, pe = y, ie = D, ue = M;
214
+ function ve({
215
+ ...e
12
216
  }) {
13
- return /* @__PURE__ */ r(i, { ...o });
217
+ return /* @__PURE__ */ s(ce, { ...e });
14
218
  }
15
- function l({
16
- className: o,
17
- align: t = "center",
18
- sideOffset: n = 4,
219
+ function Pe({
19
220
  ...e
20
221
  }) {
21
- return /* @__PURE__ */ r(m, { children: /* @__PURE__ */ r(
22
- c,
222
+ return /* @__PURE__ */ s(pe, { ...e });
223
+ }
224
+ function ge({
225
+ className: e,
226
+ align: n = "center",
227
+ sideOffset: o = 4,
228
+ ...a
229
+ }) {
230
+ return /* @__PURE__ */ s(ie, { children: /* @__PURE__ */ s(
231
+ ue,
23
232
  {
24
- align: t,
25
- sideOffset: n,
26
- className: a("tiptap-popover", o),
27
- ...e
233
+ align: n,
234
+ sideOffset: o,
235
+ className: J("tiptap-popover", e),
236
+ ...a
28
237
  }
29
238
  ) });
30
239
  }
31
240
  export {
32
- v as Popover,
33
- l as PopoverContent,
34
- P as PopoverTrigger
241
+ ve as Popover,
242
+ ge as PopoverContent,
243
+ Pe as PopoverTrigger
35
244
  };
@@ -1,18 +1,17 @@
1
- import { jsx as p } from "react/jsx-runtime";
2
- import { forwardRef as n } from "react";
3
- import '../../../assets/components/tiptap-ui-primitive/separator/separator.css';/* empty css */
1
+ import { jsx as n } from "react/jsx-runtime";
2
+ import { forwardRef as p } from "react";
4
3
  import { cn as s } from "../../../lib/tiptap-utils.js";
5
- const m = n(
6
- ({ decorative: a, orientation: r = "vertical", className: o, ...t }, i) => {
7
- const e = a ? { role: "none" } : { "aria-orientation": r === "vertical" ? r : void 0, role: "separator" };
8
- return /* @__PURE__ */ p(
4
+ import '../../../assets/separator.css';const m = p(
5
+ ({ decorative: a, orientation: r = "vertical", className: o, ...t }, e) => {
6
+ const i = a ? { role: "none" } : { "aria-orientation": r === "vertical" ? r : void 0, role: "separator" };
7
+ return /* @__PURE__ */ n(
9
8
  "div",
10
9
  {
11
10
  className: s("tiptap-separator", o),
12
11
  "data-orientation": r,
13
- ...e,
12
+ ...i,
14
13
  ...t,
15
- ref: i
14
+ ref: e
16
15
  }
17
16
  );
18
17
  }
@@ -1,11 +1,10 @@
1
1
  import { jsx as d } from "react/jsx-runtime";
2
2
  import { forwardRef as m, useRef as p, useState as f, useCallback as v, useEffect as l } from "react";
3
- import '../../../assets/components/tiptap-ui-primitive/toolbar/toolbar.css';/* empty css */
3
+ import { Separator as g } from "../separator/separator.js";
4
4
  import { cn as b } from "../../../lib/tiptap-utils.js";
5
- import { useMenuNavigation as g } from "../../../hooks/use-menu-navigation.js";
6
- import { useComposedRef as N } from "../../../hooks/use-composed-ref.js";
7
- import { Separator as S } from "../separator/separator.js";
8
- const T = (e) => {
5
+ import { useMenuNavigation as N } from "../../../hooks/use-menu-navigation.js";
6
+ import { useComposedRef as S } from "../../../hooks/use-composed-ref.js";
7
+ import '../../../assets/toolbar.css';const T = (e) => {
9
8
  const [r, s] = f([]), a = v(() => e.current ? Array.from(
10
9
  e.current.querySelectorAll(
11
10
  'button:not([disabled]), [role="button"]:not([disabled]), [tabindex="0"]:not([disabled])'
@@ -19,7 +18,7 @@ const T = (e) => {
19
18
  const i = new MutationObserver(o);
20
19
  return i.observe(t, { childList: !0, subtree: !0 }), () => i.disconnect();
21
20
  }, [a, e]);
22
- const { selectedIndex: n } = g({
21
+ const { selectedIndex: n } = N({
23
22
  containerRef: e,
24
23
  items: r,
25
24
  orientation: "horizontal",
@@ -44,7 +43,7 @@ const T = (e) => {
44
43
  }, [n, r]);
45
44
  }, x = m(
46
45
  ({ children: e, className: r, variant: s = "fixed", ...a }, n) => {
47
- const t = p(null), o = N(t, n);
46
+ const t = p(null), o = S(t, n);
48
47
  return T(t), /* @__PURE__ */ d(
49
48
  "div",
50
49
  {
@@ -74,7 +73,7 @@ const y = m(
74
73
  );
75
74
  y.displayName = "ToolbarGroup";
76
75
  const E = m(
77
- ({ ...e }, r) => /* @__PURE__ */ d(S, { ref: r, orientation: "vertical", decorative: !0, ...e })
76
+ ({ ...e }, r) => /* @__PURE__ */ d(g, { ref: r, orientation: "vertical", decorative: !0, ...e })
78
77
  );
79
78
  E.displayName = "ToolbarSeparator";
80
79
  export {