@bridge-ui/vue 0.15.0 → 0.16.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.
- package/ai/AGENTS.md +1 -1
- package/ai/README.md +1 -1
- package/ai/llms.txt +0 -1
- package/ai/skills/bridge-ui-components/SKILL.md +2 -1
- package/ai/skills/bridge-ui-setup/SKILL.md +8 -8
- package/dist/Actions/Snackbar/BridgeSnackbarItem.vue_vue_type_script_setup_true_lang.js +42 -44
- package/dist/Actions/Snackbar/createBridgeSnackbarApi.js +1 -1
- package/dist/Adapters/index.d.ts +0 -1
- package/dist/Adapters/index.js +1 -2
- package/dist/Components/Accordion/composables/useAccordion.js +1 -1
- package/dist/Components/Autocomplete/composables/useAutocomplete.js +248 -258
- package/dist/Components/Chart/Chart.js +5 -0
- package/dist/Components/Chart/Chart.vue.d.ts +14 -0
- package/dist/Components/Chart/Chart.vue_vue_type_script_setup_true_lang.js +52 -0
- package/dist/Components/Chart/chart.types.d.ts +126 -0
- package/dist/Components/Chart/chartInjectionKey.d.ts +94 -0
- package/dist/Components/Chart/chartInjectionKey.js +10 -0
- package/dist/Components/Chart/composables/useChart.d.ts +40 -0
- package/dist/Components/Chart/composables/useChart.js +344 -0
- package/dist/Components/Chart/echartsChart.d.ts +14 -0
- package/dist/Components/Chart/echartsChart.js +199 -0
- package/dist/Components/Chart/index.d.ts +4 -0
- package/dist/Components/Chart/index.js +4 -0
- package/dist/Components/ChartAxis/ChartAxis.js +5 -0
- package/dist/Components/ChartAxis/ChartAxis.vue.d.ts +7 -0
- package/dist/Components/ChartAxis/ChartAxis.vue_vue_type_script_setup_true_lang.js +30 -0
- package/dist/Components/ChartAxis/chartAxis.types.d.ts +56 -0
- package/dist/Components/ChartAxis/composables/useChartAxis.d.ts +5 -0
- package/dist/Components/ChartAxis/composables/useChartAxis.js +28 -0
- package/dist/Components/ChartAxis/index.d.ts +3 -0
- package/dist/Components/ChartAxis/index.js +3 -0
- package/dist/Components/ChartLegend/ChartLegend.js +5 -0
- package/dist/Components/ChartLegend/ChartLegend.vue.d.ts +6 -0
- package/dist/Components/ChartLegend/ChartLegend.vue_vue_type_script_setup_true_lang.js +33 -0
- package/dist/Components/ChartLegend/chartLegend.types.d.ts +71 -0
- package/dist/Components/ChartLegend/composables/useChartLegend.d.ts +16 -0
- package/dist/Components/ChartLegend/composables/useChartLegend.js +98 -0
- package/dist/Components/ChartLegend/index.d.ts +3 -0
- package/dist/Components/ChartLegend/index.js +3 -0
- package/dist/Components/ChartSeries/ChartSeries.js +5 -0
- package/dist/Components/ChartSeries/ChartSeries.vue.d.ts +4 -0
- package/dist/Components/ChartSeries/ChartSeries.vue_vue_type_script_setup_true_lang.js +24 -0
- package/dist/Components/ChartSeries/chartSeries.types.d.ts +37 -0
- package/dist/Components/ChartSeries/composables/useChartSeries.d.ts +10 -0
- package/dist/Components/ChartSeries/composables/useChartSeries.js +29 -0
- package/dist/Components/ChartSeries/index.d.ts +3 -0
- package/dist/Components/ChartSeries/index.js +3 -0
- package/dist/Components/ChartTooltip/ChartTooltip.js +5 -0
- package/dist/Components/ChartTooltip/ChartTooltip.vue.d.ts +11 -0
- package/dist/Components/ChartTooltip/ChartTooltip.vue_vue_type_script_setup_true_lang.js +25 -0
- package/dist/Components/ChartTooltip/chartTooltip.types.d.ts +82 -0
- package/dist/Components/ChartTooltip/composables/useChartTooltip.d.ts +15 -0
- package/dist/Components/ChartTooltip/composables/useChartTooltip.js +110 -0
- package/dist/Components/ChartTooltip/index.d.ts +3 -0
- package/dist/Components/ChartTooltip/index.js +3 -0
- package/dist/Components/DataTable/DataTableCellContent.vue.d.ts +1 -5
- package/dist/Components/DataTable/DataTableCellContent.vue_vue_type_script_setup_true_lang.js +24 -25
- package/dist/Components/DataTable/composables/useDataTable.d.ts +1 -1
- package/dist/Components/DataTable/composables/useDataTable.js +76 -74
- package/dist/Components/DataTable/composables/useDataTablePagination.js +1 -1
- package/dist/Components/Drawer/Drawer.vue_vue_type_script_setup_true_lang.js +3 -4
- package/dist/Components/Menu/Menu.vue_vue_type_script_setup_true_lang.js +5 -3
- package/dist/Components/Modal/Modal.vue_vue_type_script_setup_true_lang.js +3 -4
- package/dist/Components/Pagination/composables/usePagination.js +1 -1
- package/dist/Components/RichTextEditor/RichTextEditor.vue.d.ts +1 -1
- package/dist/Components/RichTextEditor/RichTextEditor.vue_vue_type_script_setup_true_lang.js +17 -17
- package/dist/Components/RichTextEditor/composables/useRichTextEditor.d.ts +2 -2
- package/dist/Components/RichTextEditor/composables/useRichTextEditor.js +67 -73
- package/dist/Components/RichTextEditor/richTextEditor.types.d.ts +1 -1
- package/dist/Components/RichTextEditor/tiptapEditor.d.ts +111 -0
- package/dist/Components/RichTextEditor/tiptapEditor.js +121 -0
- package/dist/Components/Select/composables/useSelect.js +147 -157
- package/dist/Components/Snackbar/Snackbar.vue.d.ts +1 -1
- package/dist/Components/Snackbar/Snackbar.vue_vue_type_script_setup_true_lang.js +6 -7
- package/dist/Components/Stepper/composables/useStepper.js +1 -1
- package/dist/Components/Table/composables/useTableCell.d.ts +1 -1
- package/dist/Components/Tabs/composables/useTabs.js +1 -1
- package/dist/Components/ToggleGroup/composables/useToggleGroup.js +3 -3
- package/dist/Components/Tooltip/Tooltip.vue_vue_type_script_setup_true_lang.js +6 -4
- package/dist/augments.d.ts +19 -1
- package/dist/index.d.ts +0 -3
- package/dist/index.js +180 -183
- package/dist/theme.css +1 -1
- package/docs/README.md +3 -3
- package/docs/components/BridgeUIProvider.md +0 -17
- package/docs/components/Chart.md +252 -0
- package/docs/components/RichTextEditor.md +2 -23
- package/package.json +27 -6
- package/dist/Adapters/RichText/index.d.ts +0 -1
- package/dist/Adapters/RichText/index.js +0 -2
- package/dist/Adapters/RichText/mockRichTextAdapter.d.ts +0 -5
- package/dist/Adapters/RichText/useRichTextAdapter.d.ts +0 -12
- package/dist/Adapters/RichText/useRichTextAdapter.js +0 -13
|
@@ -211,7 +211,7 @@ function S(nt, rt, m) {
|
|
|
211
211
|
pageCount: y.value.pageCount,
|
|
212
212
|
totalCount: y.value.totalCount,
|
|
213
213
|
filteredCount: I.value.length
|
|
214
|
-
})), U = r(() => D.value), W = r(() => !!g.pagination || H.value !== void 0), Ct = r(() => U.value || W.value || V.value), wt = r(() => B.value.length === 0), Tt = r(() => e(S.value?.root, dt.value, { class: p({ [P.value ? "" : s(C.value, "root") ?? ""]: !0 }) })), Et = r(() => z.value.some((e) => !!e.stickyStyle)), G = o({
|
|
214
|
+
})), U = r(() => D.value), W = r(() => !!g.pagination || H.value !== void 0), Ct = r(() => U.value || W.value || V.value), wt = r(() => B.value.length === 0), Tt = r(() => e(S.value?.root, dt.value, { class: p({ [P.value ? "" : s(C.value, "root") ?? ""]: !0 }) })), Et = r(() => z.value.some((e) => e.ellipsis)), Dt = r(() => z.value.some((e) => !!e.stickyStyle)), G = o({
|
|
215
215
|
end: !1,
|
|
216
216
|
start: !1
|
|
217
217
|
}), K;
|
|
@@ -233,14 +233,14 @@ function S(nt, rt, m) {
|
|
|
233
233
|
Y.value !== e && (Y.value = e);
|
|
234
234
|
}));
|
|
235
235
|
}
|
|
236
|
-
function
|
|
236
|
+
function Ot(e) {
|
|
237
237
|
let t = e.el;
|
|
238
238
|
Z(t instanceof HTMLElement ? t : null);
|
|
239
239
|
}
|
|
240
|
-
function
|
|
240
|
+
function kt() {
|
|
241
241
|
Z(null);
|
|
242
242
|
}
|
|
243
|
-
function
|
|
243
|
+
function At(e) {
|
|
244
244
|
let t = S.value?.wrapper?.onScroll;
|
|
245
245
|
c(t) && t(e);
|
|
246
246
|
let n = e.currentTarget;
|
|
@@ -250,18 +250,18 @@ function S(nt, rt, m) {
|
|
|
250
250
|
let n = S.value?.wrapper?.[e];
|
|
251
251
|
c(n) && n(t);
|
|
252
252
|
}
|
|
253
|
-
function
|
|
253
|
+
function jt(e) {
|
|
254
254
|
Q("onVnodeMounted", e);
|
|
255
255
|
let t = e.el;
|
|
256
256
|
J(t instanceof HTMLElement ? t : null);
|
|
257
257
|
}
|
|
258
|
-
function
|
|
258
|
+
function Mt(e) {
|
|
259
259
|
Q("onVnodeUnmounted", e), J(null);
|
|
260
260
|
}
|
|
261
261
|
a(() => {
|
|
262
262
|
J(null), Z(null);
|
|
263
263
|
});
|
|
264
|
-
let
|
|
264
|
+
let Nt = r(() => ({
|
|
265
265
|
size: y.value.size,
|
|
266
266
|
variant: y.value.variant,
|
|
267
267
|
rounded: y.value.rounded,
|
|
@@ -276,9 +276,9 @@ function S(nt, rt, m) {
|
|
|
276
276
|
},
|
|
277
277
|
root: {
|
|
278
278
|
...S.value?.wrapper,
|
|
279
|
-
onScroll:
|
|
280
|
-
onVnodeMounted:
|
|
281
|
-
onVnodeUnmounted:
|
|
279
|
+
onScroll: At,
|
|
280
|
+
onVnodeMounted: jt,
|
|
281
|
+
onVnodeUnmounted: Mt
|
|
282
282
|
}
|
|
283
283
|
},
|
|
284
284
|
classes: {
|
|
@@ -290,18 +290,19 @@ function S(nt, rt, m) {
|
|
|
290
290
|
"relative z-40": y.value.loading && y.value.loadingVariant === "bar",
|
|
291
291
|
[s(C.value, "header") ?? ""]: !0
|
|
292
292
|
}),
|
|
293
|
-
table: p({
|
|
294
|
-
"border-separate border-spacing-0": Et.value && !N.value,
|
|
295
|
-
[s(C.value, "table") ?? ""]: !0
|
|
296
|
-
}),
|
|
297
293
|
root: p({
|
|
298
294
|
"overflow-auto": P.value,
|
|
299
295
|
[s(C.value, "wrapper") ?? ""]: !0,
|
|
300
296
|
[P.value ? s(C.value, "root") ?? "" : ""]: !0
|
|
297
|
+
}),
|
|
298
|
+
table: p({
|
|
299
|
+
"w-full table-fixed": Et.value,
|
|
300
|
+
"border-separate border-spacing-0": Dt.value && !N.value,
|
|
301
|
+
[s(C.value, "table") ?? ""]: !0
|
|
301
302
|
})
|
|
302
303
|
}
|
|
303
304
|
}));
|
|
304
|
-
function
|
|
305
|
+
function Pt(e, t = !1) {
|
|
305
306
|
let n = fe(e.width, e.isExpand || e.isSelection), r = t && N.value;
|
|
306
307
|
return {
|
|
307
308
|
...n ? {
|
|
@@ -317,16 +318,16 @@ function S(nt, rt, m) {
|
|
|
317
318
|
} : {}
|
|
318
319
|
};
|
|
319
320
|
}
|
|
320
|
-
function
|
|
321
|
+
function Ft(e) {
|
|
321
322
|
return e.isSelection || e.isExpand ? "center" : e.align ?? "start";
|
|
322
323
|
}
|
|
323
|
-
function
|
|
324
|
+
function It(e) {
|
|
324
325
|
return e.isSelection || e.isExpand ? "center" : e.align ?? "start";
|
|
325
326
|
}
|
|
326
|
-
function
|
|
327
|
+
function Lt(t) {
|
|
327
328
|
let n = t.isSelection || t.isExpand;
|
|
328
329
|
return e(S.value?.head, {}, {
|
|
329
|
-
style:
|
|
330
|
+
style: Pt(t, !0),
|
|
330
331
|
"aria-sort": t.sortable ? t.ariaSort : void 0,
|
|
331
332
|
class: p({
|
|
332
333
|
"min-w-0": !0,
|
|
@@ -339,12 +340,13 @@ function S(nt, rt, m) {
|
|
|
339
340
|
})
|
|
340
341
|
});
|
|
341
342
|
}
|
|
342
|
-
function
|
|
343
|
+
function Rt(t) {
|
|
343
344
|
let n = t.isSelection || t.isExpand;
|
|
344
345
|
return e(S.value?.cell, {}, {
|
|
345
|
-
style:
|
|
346
|
+
style: Pt(t),
|
|
346
347
|
class: p({
|
|
347
348
|
"min-w-0": !0,
|
|
349
|
+
"overflow-hidden": t.ellipsis,
|
|
348
350
|
"border-e-0": n,
|
|
349
351
|
"after:hidden": n,
|
|
350
352
|
[s(w.value, "cellSticky") ?? ""]: !!t.stickyStyle,
|
|
@@ -354,17 +356,17 @@ function S(nt, rt, m) {
|
|
|
354
356
|
})
|
|
355
357
|
});
|
|
356
358
|
}
|
|
357
|
-
let
|
|
359
|
+
let zt = r(() => e(S.value?.toolbar, {}, { class: p({
|
|
358
360
|
"flex items-center justify-between gap-3 pb-3": !0,
|
|
359
361
|
[s(C.value, "toolbar") ?? ""]: !0
|
|
360
|
-
}) })),
|
|
362
|
+
}) })), Bt = r(() => e(S.value?.empty, {}, { class: p({
|
|
361
363
|
"w-full": !0,
|
|
362
364
|
[s(C.value, "empty") ?? ""]: !0
|
|
363
|
-
}) })),
|
|
365
|
+
}) })), Vt = r(() => e(S.value?.loading, {}, { class: p({
|
|
364
366
|
"absolute inset-0 z-30 bg-white/50 dark:bg-dark-900/50": !0,
|
|
365
367
|
"flex items-center justify-center": y.value.loadingVariant !== "bar",
|
|
366
368
|
[s(C.value, "loading") ?? ""]: !0
|
|
367
|
-
}) })),
|
|
369
|
+
}) })), Ht = r(() => e({}, {}, { class: p({ "pointer-events-none absolute inset-x-0 top-0 z-40": !0 }) })), Ut = r(() => e({}, {}, { class: p({ "w-fit min-w-0 max-w-full": y.value.full === !1 }) })), Wt = r(() => e(S.value?.footer, {}, { class: p({
|
|
368
370
|
"w-0 min-w-full": y.value.full === !1,
|
|
369
371
|
"border-t border-dark-200 bg-dark-50 px-3 py-2.5 text-sm text-dark-600 dark:border-dark-700 dark:bg-dark-800 dark:text-dark-300": !0,
|
|
370
372
|
[s(C.value, "footer") ?? ""]: !0
|
|
@@ -373,13 +375,13 @@ function S(nt, rt, m) {
|
|
|
373
375
|
showPerPage: V.value,
|
|
374
376
|
inline: Y.value,
|
|
375
377
|
showSelected: U.value
|
|
376
|
-
})),
|
|
378
|
+
})), Gt = r(() => e(S.value?.selected, {}, { class: p({
|
|
377
379
|
grow: !$.value.stack,
|
|
378
380
|
"whitespace-nowrap text-sm text-dark-500 dark:text-dark-400": !0,
|
|
379
381
|
[s(C.value, "selected") ?? ""]: !0
|
|
380
|
-
}) })),
|
|
381
|
-
onVnodeMounted:
|
|
382
|
-
onVnodeUnmounted:
|
|
382
|
+
}) })), Kt = r(() => e({}, {}, {
|
|
383
|
+
onVnodeMounted: Ot,
|
|
384
|
+
onVnodeUnmounted: kt,
|
|
383
385
|
class: p({
|
|
384
386
|
"flex items-center gap-3 py-3 [&>*]:shrink-0": !0,
|
|
385
387
|
"flex-col": $.value.stack,
|
|
@@ -393,52 +395,52 @@ function S(nt, rt, m) {
|
|
|
393
395
|
[s(C.value, "pagination") ?? ""]: !0
|
|
394
396
|
})
|
|
395
397
|
}));
|
|
396
|
-
function
|
|
398
|
+
function qt(e) {
|
|
397
399
|
m.sorting.value = Qe(m.sorting.value ?? null, e);
|
|
398
400
|
}
|
|
399
|
-
function
|
|
401
|
+
function Jt(e, t) {
|
|
400
402
|
m.selection.value = qe(m.selection.value ?? [], e, t, y.value.selectionMode);
|
|
401
403
|
}
|
|
402
|
-
function
|
|
404
|
+
function Yt(e) {
|
|
403
405
|
m.perPage.value = e, m.page.value !== 1 && (m.page.value = 1);
|
|
404
406
|
}
|
|
405
|
-
function
|
|
407
|
+
function Xt(e) {
|
|
406
408
|
m.search.value = e, m.page.value !== 1 && (m.page.value = 1);
|
|
407
409
|
}
|
|
408
|
-
let
|
|
410
|
+
let Zt = r(() => ({
|
|
409
411
|
page: m.page.value ?? 1,
|
|
410
412
|
count: H.value ?? 1,
|
|
411
413
|
onPageChange: (e) => {
|
|
412
414
|
m.page.value = e;
|
|
413
415
|
}
|
|
414
|
-
})),
|
|
416
|
+
})), Qt = r(() => ({
|
|
415
417
|
perPage: M.value,
|
|
416
|
-
onPerPageChange:
|
|
418
|
+
onPerPageChange: Yt,
|
|
417
419
|
options: _e(M.value, y.value.perPageOptions)
|
|
418
|
-
})),
|
|
420
|
+
})), $t = r(() => ({
|
|
419
421
|
selectedCount: (m.selection.value ?? []).length,
|
|
420
422
|
totalCount: xe({
|
|
421
423
|
totalCount: y.value.totalCount,
|
|
422
424
|
filteredCount: I.value.length
|
|
423
425
|
})
|
|
424
426
|
}));
|
|
425
|
-
function
|
|
427
|
+
function en(e) {
|
|
426
428
|
m.selection.value = Xe(m.selection.value ?? [], R.value, e);
|
|
427
429
|
}
|
|
428
|
-
function
|
|
430
|
+
function tn(e, t, n) {
|
|
429
431
|
let r = s(E.value, e);
|
|
430
432
|
r?.filters && r.filters.length > 0 && (m.filters.value = Ge(m.filters.value, e, t)), Oe(r) && (m.columnSearch.value = Ke(m.columnSearch.value, e, n)), m.page.value !== 1 && (m.page.value = 1);
|
|
431
433
|
}
|
|
432
|
-
function
|
|
434
|
+
function nn(e, t) {
|
|
433
435
|
m.expanded.value = Ze(m.expanded.value ?? [], e, t);
|
|
434
436
|
}
|
|
435
|
-
function
|
|
437
|
+
function rn(e, t) {
|
|
436
438
|
m.hiddenColumns.value = Ye(m.hiddenColumns.value ?? [], e, t, l(T.value, "id"));
|
|
437
439
|
}
|
|
438
|
-
function
|
|
440
|
+
function an(e) {
|
|
439
441
|
m.hiddenColumns.value = e;
|
|
440
442
|
}
|
|
441
|
-
let
|
|
443
|
+
let on = r(() => {
|
|
442
444
|
if (!T.value.some((e) => e.summary !== void 0)) return null;
|
|
443
445
|
let e = l(I.value, "original");
|
|
444
446
|
return z.value.map((t) => {
|
|
@@ -459,62 +461,62 @@ function S(nt, rt, m) {
|
|
|
459
461
|
content: t.isSelection || t.isExpand ? null : n?.summary?.(e) ?? null
|
|
460
462
|
};
|
|
461
463
|
});
|
|
462
|
-
}),
|
|
464
|
+
}), sn = r(() => T.value.map((e) => ({
|
|
463
465
|
id: e.id,
|
|
464
466
|
hideable: e.hideable !== !1,
|
|
465
467
|
hidden: F.value.includes(e.id),
|
|
466
468
|
label: ce(e.header) ? e.header : e.id
|
|
467
|
-
}))),
|
|
469
|
+
}))), cn = r(() => Me(m.search.value, _?.vnode.props?.["onUpdate:search"] !== void 0, g.search !== void 0, y.value.showSearch));
|
|
468
470
|
return {
|
|
469
471
|
merged: y,
|
|
470
472
|
pageIds: R,
|
|
471
473
|
rowViews: B,
|
|
472
474
|
rootBind: Tt,
|
|
473
|
-
emptyBind:
|
|
475
|
+
emptyBind: Bt,
|
|
474
476
|
showEmpty: wt,
|
|
475
|
-
frameBind:
|
|
477
|
+
frameBind: Ut,
|
|
476
478
|
showPager: W,
|
|
477
|
-
tableProps:
|
|
478
|
-
footerBind:
|
|
479
|
-
showSearch:
|
|
480
|
-
getHeadBind:
|
|
479
|
+
tableProps: Nt,
|
|
480
|
+
footerBind: Wt,
|
|
481
|
+
showSearch: cn,
|
|
482
|
+
getHeadBind: Lt,
|
|
481
483
|
headerViews: z,
|
|
482
|
-
loadingBind:
|
|
483
|
-
onToggleRow:
|
|
484
|
-
toolbarBind:
|
|
485
|
-
getCellBind:
|
|
484
|
+
loadingBind: Vt,
|
|
485
|
+
onToggleRow: Jt,
|
|
486
|
+
toolbarBind: zt,
|
|
487
|
+
getCellBind: Rt,
|
|
486
488
|
columnCount: St,
|
|
487
489
|
clientPaged: j,
|
|
488
490
|
serverPaged: A,
|
|
489
491
|
showPerPage: V,
|
|
490
|
-
showToolbar: r(() => !!g.toolbar || !!g.toolbarActions || O.value ||
|
|
491
|
-
selectedBind:
|
|
492
|
+
showToolbar: r(() => !!g.toolbar || !!g.toolbarActions || O.value || cn.value),
|
|
493
|
+
selectedBind: Gt,
|
|
492
494
|
showSelected: U,
|
|
493
|
-
getHeadAlign:
|
|
494
|
-
getCellAlign:
|
|
495
|
-
onTogglePage:
|
|
496
|
-
onToggleSort:
|
|
497
|
-
summaryCells:
|
|
495
|
+
getHeadAlign: Ft,
|
|
496
|
+
getCellAlign: It,
|
|
497
|
+
onTogglePage: en,
|
|
498
|
+
onToggleSort: qt,
|
|
499
|
+
summaryCells: on,
|
|
498
500
|
showFooterBar: Ct,
|
|
499
501
|
expandEnabled: mt,
|
|
500
|
-
onChangeSearch:
|
|
501
|
-
loadingBarBind:
|
|
502
|
-
paginationBind:
|
|
502
|
+
onChangeSearch: Xt,
|
|
503
|
+
loadingBarBind: Ht,
|
|
504
|
+
paginationBind: Kt,
|
|
503
505
|
selectAllState: xt,
|
|
504
|
-
onToggleExpand:
|
|
505
|
-
visibilityItems:
|
|
506
|
-
onChangePerPage:
|
|
506
|
+
onToggleExpand: nn,
|
|
507
|
+
visibilityItems: sn,
|
|
508
|
+
onChangePerPage: Yt,
|
|
507
509
|
resolvedPerPage: M,
|
|
508
510
|
selectionEnabled: D,
|
|
509
|
-
perPageSlotProps:
|
|
510
|
-
selectedSlotProps:
|
|
511
|
+
perPageSlotProps: Qt,
|
|
512
|
+
selectedSlotProps: $t,
|
|
511
513
|
resolvedPageCount: H,
|
|
512
514
|
selectionMultiple: k,
|
|
513
515
|
visibilityEnabled: O,
|
|
514
|
-
paginationSlotProps:
|
|
515
|
-
onCommitColumnFilter:
|
|
516
|
-
onHiddenColumnsChange:
|
|
517
|
-
onToggleColumnVisibility:
|
|
516
|
+
paginationSlotProps: Zt,
|
|
517
|
+
onCommitColumnFilter: tn,
|
|
518
|
+
onHiddenColumnsChange: an,
|
|
519
|
+
onToggleColumnVisibility: rn,
|
|
518
520
|
loadingBar: r(() => y.value.loadingVariant === "bar")
|
|
519
521
|
};
|
|
520
522
|
}
|
|
@@ -31,7 +31,7 @@ function h(h, g, _, v) {
|
|
|
31
31
|
}), D = i(() => s(d, C.value.size)), O = i(() => s(u, C.value.rounded)), k = (e) => {
|
|
32
32
|
if (C.value.disabled) return;
|
|
33
33
|
let t = C.value.count ?? 0, n = Math.min(Math.max(1, e), Math.max(t, 1));
|
|
34
|
-
_.value = n, v("change", n)
|
|
34
|
+
_.value = n, v("change", n);
|
|
35
35
|
}, A = () => {
|
|
36
36
|
k(T.value - 1);
|
|
37
37
|
}, j = () => {
|
|
@@ -82,14 +82,13 @@ var g = /*@__PURE__*/ s({
|
|
|
82
82
|
});
|
|
83
83
|
l({ stackId: n(() => v.stackId ?? D.value) });
|
|
84
84
|
let O = n(() => b.value.teleportTo === !1), k = n(() => b.value.teleportTo === !1 ? "body" : b.value.teleportTo), A = n(() => v.hideBackdrop !== !0 && b.value.hideBackdrop !== !0);
|
|
85
|
-
return (e, n) =>
|
|
86
|
-
key: 0,
|
|
85
|
+
return (e, n) => (f(), r(t, {
|
|
87
86
|
to: k.value,
|
|
88
87
|
disabled: O.value
|
|
89
|
-
}, [
|
|
88
|
+
}, [m(x) ? (f(), a("div", d(u({ key: 0 }, m(S))), [A.value ? (f(), a("div", u({
|
|
90
89
|
key: 0,
|
|
91
90
|
"aria-hidden": "true"
|
|
92
|
-
}, m(w)), null, 16)) : i("", !0), o("div", d(c(m(T))), [o("div", u({ ref: m(E) }, m(C)), [p(e.$slots, "default")], 16)], 16)], 16)], 8, ["to", "disabled"]))
|
|
91
|
+
}, m(w)), null, 16)) : i("", !0), o("div", d(c(m(T))), [o("div", u({ ref: m(E) }, m(C)), [p(e.$slots, "default")], 16)], 16)], 16)) : i("", !0)], 8, ["to", "disabled"]));
|
|
93
92
|
}
|
|
94
93
|
});
|
|
95
94
|
//#endregion
|
|
@@ -68,11 +68,13 @@ var v = /*@__PURE__*/ l({
|
|
|
68
68
|
onClose: () => y("close"),
|
|
69
69
|
onShowChange: (e) => b.onShowChange?.(e)
|
|
70
70
|
}), k = i(() => S.value.teleportTo === !1), A = i(() => S.value.teleportTo === !1 ? "body" : S.value.teleportTo);
|
|
71
|
-
return (t, i) => (p(), s(n, null, [h(e)(h(v), "trigger") ? (p(), s("div", f(d({ key: 0 }, h(w))), [c("div", d({ ref: h(D) }, h(T)), [m(t.$slots, "trigger")], 16)], 16)) : o("", !0),
|
|
72
|
-
key: 1,
|
|
71
|
+
return (t, i) => (p(), s(n, null, [h(e)(h(v), "trigger") ? (p(), s("div", f(d({ key: 0 }, h(w))), [c("div", d({ ref: h(D) }, h(T)), [m(t.$slots, "trigger")], 16)], 16)) : o("", !0), (p(), a(r, {
|
|
73
72
|
to: A.value,
|
|
74
73
|
disabled: k.value
|
|
75
|
-
}, [
|
|
74
|
+
}, [h(C) ? (p(), s("div", d({
|
|
75
|
+
key: 0,
|
|
76
|
+
ref: h(O)
|
|
77
|
+
}, h(E)), [m(t.$slots, "default")], 16)) : o("", !0)], 8, ["to", "disabled"]))], 64));
|
|
76
78
|
}
|
|
77
79
|
});
|
|
78
80
|
//#endregion
|
|
@@ -80,14 +80,13 @@ var g = /*@__PURE__*/ s({
|
|
|
80
80
|
});
|
|
81
81
|
l({ stackId: n(() => v.stackId ?? D.value) });
|
|
82
82
|
let O = n(() => b.value.teleportTo === !1), k = n(() => b.value.teleportTo === !1 ? "body" : b.value.teleportTo), A = n(() => v.hideBackdrop !== !0 && b.value.hideBackdrop !== !0);
|
|
83
|
-
return (e, n) =>
|
|
84
|
-
key: 0,
|
|
83
|
+
return (e, n) => (f(), r(t, {
|
|
85
84
|
to: k.value,
|
|
86
85
|
disabled: O.value
|
|
87
|
-
}, [
|
|
86
|
+
}, [m(x) ? (f(), a("div", d(u({ key: 0 }, m(S))), [A.value ? (f(), a("div", u({
|
|
88
87
|
key: 0,
|
|
89
88
|
"aria-hidden": "true"
|
|
90
|
-
}, m(w)), null, 16)) : i("", !0), o("div", d(c(m(T))), [o("div", u({ ref: m(E) }, m(C)), [p(e.$slots, "default")], 16)], 16)], 16)], 8, ["to", "disabled"]))
|
|
89
|
+
}, m(w)), null, 16)) : i("", !0), o("div", d(c(m(T))), [o("div", u({ ref: m(E) }, m(C)), [p(e.$slots, "default")], 16)], 16)], 16)) : i("", !0)], 8, ["to", "disabled"]));
|
|
91
90
|
}
|
|
92
91
|
});
|
|
93
92
|
//#endregion
|
|
@@ -46,7 +46,7 @@ function _(_, v, y, b) {
|
|
|
46
46
|
}), j = i(() => m(d, E.value?.tokens?.size)), M = i(() => m(f, E.value?.tokens?.variant)), ee = i(() => m(l, E.value?.tokens?.color)), te = i(() => m(u, E.value?.tokens?.rounded)), N = i(() => s(j.value, T.value.size)), P = i(() => s(M.value, T.value.variant)), F = i(() => s(ee.value, T.value.color)), I = i(() => s(te.value, T.value.rounded)), L = (e) => {
|
|
47
47
|
if (T.value.disabled) return;
|
|
48
48
|
let t = T.value.count ?? 0, n = Math.min(Math.max(1, e), Math.max(t, 1));
|
|
49
|
-
y.value = n, b("change", n)
|
|
49
|
+
y.value = n, b("change", n);
|
|
50
50
|
}, R = () => {
|
|
51
51
|
if (!T.value.disabled) {
|
|
52
52
|
if (T.value.mode === "simple") {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { RichTextValue } from '@bridge-ui/core/
|
|
1
|
+
import { RichTextValue } from '@bridge-ui/core/Domain';
|
|
2
2
|
import { RichTextEditorOwnProps, RichTextEditorSlots } from './richTextEditor.types';
|
|
3
3
|
type __VLS_Slots = RichTextEditorSlots;
|
|
4
4
|
type __VLS_Props = RichTextEditorOwnProps;
|
package/dist/Components/RichTextEditor/RichTextEditor.vue_vue_type_script_setup_true_lang.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { hasNamedSlot as e, presentSlotNames as t } from "../../Utils/slotOrProp.js";
|
|
2
2
|
import { useOptionalModel as n } from "../../Utils/useOptionalModel.js";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import { FORM_FIELD_CHROME_SLOT_NAMES as
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import c from "
|
|
3
|
+
import r from "../Button/Button.js";
|
|
4
|
+
import i from "../ActionFooter/ActionFooter.js";
|
|
5
|
+
import { FORM_FIELD_CHROME_SLOT_NAMES as a } from "../FormField/formField.types.js";
|
|
6
|
+
import o from "../FormField/FormField.js";
|
|
7
|
+
import s from "../Menu/Menu.js";
|
|
8
|
+
import ee from "../TextField/TextField.js";
|
|
9
|
+
import { useRichTextEditor as c } from "./composables/useRichTextEditor.js";
|
|
10
10
|
import { Fragment as l, createBlock as u, createCommentVNode as d, createElementBlock as f, createElementVNode as p, createSlots as m, createVNode as h, defineComponent as g, guardReactiveProps as _, isRef as v, mergeModels as y, mergeProps as b, normalizeProps as x, openBlock as S, ref as C, renderList as w, renderSlot as T, unref as E, useModel as D, useTemplateRef as O, withCtx as k, withModifiers as A } from "vue";
|
|
11
11
|
//#region src/Components/RichTextEditor/RichTextEditor.vue?vue&type=script&setup=true&lang.ts
|
|
12
12
|
var j = { class: "flex min-h-0 min-w-0 flex-1 flex-col" }, M = { class: "flex w-64 flex-col" }, N = { class: "p-1.5" }, P = { class: "flex items-center justify-end gap-2 border-t border-dark-100 bg-dark-50 px-3 py-2 dark:border-dark-800 dark:bg-dark-950/40" }, F = /*@__PURE__*/ g({
|
|
@@ -51,24 +51,24 @@ var j = { class: "flex min-h-0 min-w-0 flex-1 flex-col" }, M = { class: "flex w-
|
|
|
51
51
|
}),
|
|
52
52
|
emits: /*@__PURE__*/ y(["update:modelValue"], ["update:modelValue"]),
|
|
53
53
|
setup(g, { emit: y }) {
|
|
54
|
-
let F = D(g, "modelValue"), I = y, L = g, R = O("content"), z = C(L.defaultValue), B = n(F, z), { color: V, slots: H, tools: U, linkHref: W, linkOpen: G, formField: K, linkAnchor: q, contentBind: J, confirmLink: Y, onToolClick: X, toolbarBind: Z, showToolbar: Q, linkUrlLabel: $, canConfirmLink: te, closeLinkEditor: ne, getToolbarButtonBind: re } =
|
|
55
|
-
return (n,
|
|
56
|
-
default: k(() => [p("div", j, [E(Q) ? (S(), f(l, { key: 0 }, [E(e)(E(H), "toolbar") ? T(n.$slots, "toolbar", { tools: E(U) }, void 0, void 0, 0) : (S(), f("div", x(b({ key: 1 }, E(Z))), [(S(!0), f(l, null, w(E(U), (e) => (S(), u(E(
|
|
54
|
+
let F = D(g, "modelValue"), I = y, L = g, R = O("content"), z = C(L.defaultValue), B = n(F, z), { color: V, slots: H, tools: U, linkHref: W, linkOpen: G, formField: K, linkAnchor: q, contentBind: J, confirmLink: Y, onToolClick: X, toolbarBind: Z, showToolbar: Q, linkUrlLabel: $, canConfirmLink: te, closeLinkEditor: ne, getToolbarButtonBind: re } = c(L, B, I, R);
|
|
55
|
+
return (n, c) => (S(), u(E(o), { field: E(K) }, m({
|
|
56
|
+
default: k(() => [p("div", j, [E(Q) ? (S(), f(l, { key: 0 }, [E(e)(E(H), "toolbar") ? T(n.$slots, "toolbar", { tools: E(U) }, void 0, void 0, 0) : (S(), f("div", x(b({ key: 1 }, E(Z))), [(S(!0), f(l, null, w(E(U), (e) => (S(), u(E(r), b({
|
|
57
57
|
key: e,
|
|
58
|
-
onMousedown:
|
|
59
|
-
}, { ref_for: !0 }, E(re)(e), { onClick: (t) => E(X)(e, t) }), null, 16, ["onClick"]))), 128))], 16))], 64)) : d("", !0), p("div", b({ ref: "content" }, E(J)), null, 16)]), h(E(
|
|
58
|
+
onMousedown: c[0] ||= A(() => {}, ["prevent"])
|
|
59
|
+
}, { ref_for: !0 }, E(re)(e), { onClick: (t) => E(X)(e, t) }), null, 16, ["onClick"]))), 128))], 16))], 64)) : d("", !0), p("div", b({ ref: "content" }, E(J)), null, 16)]), h(E(s), {
|
|
60
60
|
modelValue: E(G),
|
|
61
|
-
"onUpdate:modelValue":
|
|
61
|
+
"onUpdate:modelValue": c[2] ||= (e) => v(G) ? G.value = e : null,
|
|
62
62
|
"anchor-el": E(q),
|
|
63
63
|
placement: "bottom-start"
|
|
64
64
|
}, {
|
|
65
|
-
default: k(() => [p("div", M, [p("div", N, [h(E(
|
|
65
|
+
default: k(() => [p("div", M, [p("div", N, [h(E(ee), {
|
|
66
66
|
size: "sm",
|
|
67
67
|
type: "url",
|
|
68
68
|
class: "w-full",
|
|
69
69
|
color: E(V),
|
|
70
70
|
modelValue: E(W),
|
|
71
|
-
"onUpdate:modelValue":
|
|
71
|
+
"onUpdate:modelValue": c[1] ||= (e) => v(W) ? W.value = e : null,
|
|
72
72
|
autocomplete: "off",
|
|
73
73
|
"hide-error-message": "",
|
|
74
74
|
"aria-label": E($),
|
|
@@ -78,7 +78,7 @@ var j = { class: "flex min-h-0 min-w-0 flex-1 flex-col" }, M = { class: "flex w-
|
|
|
78
78
|
"modelValue",
|
|
79
79
|
"aria-label",
|
|
80
80
|
"placeholder"
|
|
81
|
-
])]), p("div", P, [h(E(
|
|
81
|
+
])]), p("div", P, [h(E(i), {
|
|
82
82
|
color: E(V),
|
|
83
83
|
onApply: E(Y),
|
|
84
84
|
onCancel: E(ne),
|
|
@@ -98,7 +98,7 @@ var j = { class: "flex min-h-0 min-w-0 flex-1 flex-col" }, M = { class: "flex w-
|
|
|
98
98
|
_: 1
|
|
99
99
|
}, 8, ["modelValue", "anchor-el"])]),
|
|
100
100
|
_: 2
|
|
101
|
-
}, [w(E(t)(E(
|
|
101
|
+
}, [w(E(t)(E(a), n.$slots), (e) => ({
|
|
102
102
|
name: e,
|
|
103
103
|
fn: k((t) => [T(n.$slots, e, x(_(t || {})))])
|
|
104
104
|
}))]), 1032, ["field"]));
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { Ref, SetupContext } from 'vue';
|
|
2
|
-
import { RichTextFormat, RichTextTool, RichTextValue } from '@bridge-ui/core/
|
|
2
|
+
import { RichTextFormat, RichTextTool, RichTextValue } from '@bridge-ui/core/Domain';
|
|
3
3
|
import { ButtonOwnProps } from '../../Button/button.types';
|
|
4
4
|
import { FormFieldOwnProps } from '../../FormField/formField.types';
|
|
5
5
|
import { RichTextEditorEmits, RichTextEditorOwnProps } from '../richTextEditor.types';
|
|
6
6
|
/**
|
|
7
|
-
* Composes FormField chrome
|
|
7
|
+
* Composes FormField chrome and the TipTap surface for Vue.
|
|
8
8
|
*/
|
|
9
9
|
export declare function useRichTextEditor(props: RichTextEditorOwnProps, model: Ref<undefined | RichTextValue>, emit: SetupContext<RichTextEditorEmits>["emit"], contentRef: Ref<null | undefined | HTMLDivElement>): {
|
|
10
10
|
color: import('vue').ComputedRef<NonNullable<keyof import('@bridge-ui/core/Tokens').FormFieldColor | undefined>>;
|