@atscript/vue-table 0.1.105 → 0.1.107
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/dist/as-action-form-dialog.cjs +1 -1
- package/dist/as-action-form-dialog.mjs +1 -1
- package/dist/{as-action-menu-content-DsAb2Z1_.cjs → as-action-menu-content-C566-BZi.cjs} +1 -1
- package/dist/{as-action-menu-content-DEOJ4c9c.mjs → as-action-menu-content-QLqwcIyN.mjs} +1 -1
- package/dist/{as-config-dialog-BSYeHrVi.cjs → as-config-dialog-6QNcUtFs.cjs} +2 -2
- package/dist/{as-config-dialog-ejWEs-Mk.mjs → as-config-dialog-mz5oML3g.mjs} +2 -2
- package/dist/as-config-dialog.cjs +1 -1
- package/dist/as-config-dialog.mjs +1 -1
- package/dist/{as-confirm-dialog-DThHWg1q.mjs → as-confirm-dialog-Dj-nIpgR.mjs} +1 -1
- package/dist/{as-confirm-dialog-Ds0bsoxY.cjs → as-confirm-dialog-dnSPMGyB.cjs} +1 -1
- package/dist/as-confirm-dialog.cjs +1 -1
- package/dist/as-confirm-dialog.mjs +1 -1
- package/dist/{as-filter-dialog-C-Iw1pEJ.cjs → as-filter-dialog-BBMHtQRx.cjs} +7 -7
- package/dist/{as-filter-dialog-CtMsxzJG.mjs → as-filter-dialog-BFy5tg8o.mjs} +7 -7
- package/dist/as-filter-dialog.cjs +1 -1
- package/dist/as-filter-dialog.mjs +1 -1
- package/dist/{as-filter-field-r-vkcWBY.cjs → as-filter-field-BRSNhFa5.cjs} +3 -3
- package/dist/{as-filter-field-DPb7bhIf.mjs → as-filter-field-DiSwUOJG.mjs} +3 -3
- package/dist/as-filter-field.cjs +1 -1
- package/dist/as-filter-field.mjs +1 -1
- package/dist/{as-filters-CHtxp1Fx.cjs → as-filters-B82jw5f5.cjs} +3 -3
- package/dist/{as-filters-xplRbLmV.mjs → as-filters-N95wOVF4.mjs} +3 -3
- package/dist/as-filters.cjs +1 -1
- package/dist/as-filters.mjs +1 -1
- package/dist/{as-preset-dialog-DnK_Gi_z.mjs → as-preset-dialog-DZ106BdC.mjs} +1 -1
- package/dist/{as-preset-dialog-zsbgrl-D.cjs → as-preset-dialog-KUcH4G-M.cjs} +1 -1
- package/dist/as-preset-dialog.cjs +1 -1
- package/dist/as-preset-dialog.mjs +1 -1
- package/dist/{as-preset-picker-BuyHHYD6.mjs → as-preset-picker-DUEObd_i.mjs} +1 -1
- package/dist/{as-preset-picker-B2FVgmXk.cjs → as-preset-picker-DrhvxmxV.cjs} +1 -1
- package/dist/as-preset-picker.cjs +1 -1
- package/dist/as-preset-picker.mjs +1 -1
- package/dist/{as-row-actions-Cq_Eoxpn.mjs → as-row-actions-CrqYfsva.mjs} +2 -2
- package/dist/{as-row-actions-DJXX81aA.cjs → as-row-actions-DSsKbKGO.cjs} +2 -2
- package/dist/as-row-actions.cjs +1 -1
- package/dist/as-row-actions.mjs +1 -1
- package/dist/{as-table-BhtyI18Z.mjs → as-table-Bo2dAWTD.mjs} +10 -3
- package/dist/{as-table-GS-99KAe.cjs → as-table-MKVsJZxT.cjs} +10 -3
- package/dist/{as-table-actions-42ObwQBE.mjs → as-table-actions-CJfrl39w.mjs} +9 -4
- package/dist/{as-table-actions-CmvhBaZH.cjs → as-table-actions-_kHRpDah.cjs} +9 -4
- package/dist/as-table-actions.cjs +1 -1
- package/dist/as-table-actions.d.cts +1 -1
- package/dist/as-table-actions.d.mts +1 -1
- package/dist/as-table-actions.mjs +1 -1
- package/dist/{as-table-actions.vue-C36YeIUD.d.cts → as-table-actions.vue-CCCICVBr.d.cts} +1 -1
- package/dist/{as-table-actions.vue-CnL92_MD.d.mts → as-table-actions.vue-l3DnLVxA.d.mts} +1 -1
- package/dist/{as-table-base-BZV-Nd_X.mjs → as-table-base-BxruWtW2.mjs} +23 -6
- package/dist/{as-table-base-C1GvdzBY.cjs → as-table-base-D6VP4rrr.cjs} +23 -6
- package/dist/{as-table-header-cell-BRG9MJMO.cjs → as-table-header-cell-BeHbNQjP.cjs} +1 -1
- package/dist/{as-table-header-cell-CwFFk8f0.mjs → as-table-header-cell-xKGgCjbF.mjs} +1 -1
- package/dist/as-table-header-cell.cjs +1 -1
- package/dist/as-table-header-cell.mjs +1 -1
- package/dist/{as-table-root-DOE4CqP1.mjs → as-table-root-CqjewHJz.mjs} +4 -4
- package/dist/{as-table-root-CAuiC2K_.cjs → as-table-root-DFYbEtFF.cjs} +4 -4
- package/dist/as-table-root.cjs +1 -1
- package/dist/as-table-root.d.cts +1 -1
- package/dist/as-table-root.d.mts +1 -1
- package/dist/as-table-root.mjs +1 -1
- package/dist/{as-table-root.vue-Boq6pDr1.d.mts → as-table-root.vue-BjeThuub.d.mts} +4 -4
- package/dist/{as-table-root.vue-CYmnf5SH.d.cts → as-table-root.vue-BukHIoYu.d.cts} +4 -4
- package/dist/{as-table-status-D8DJYUYF.mjs → as-table-status-4OaguC5n.mjs} +81 -8
- package/dist/{as-table-status-DHgPM8vQ.cjs → as-table-status-Diyy3DFB.cjs} +86 -7
- package/dist/as-table.cjs +1 -1
- package/dist/as-table.d.cts +1 -1
- package/dist/as-table.d.mts +1 -1
- package/dist/as-table.mjs +1 -1
- package/dist/{as-table.vue-4NViMhLE.d.cts → as-table.vue-CDPbZQRG.d.cts} +13 -5
- package/dist/{as-table.vue-UzgniXai.d.mts → as-table.vue-DaVtNFIe.d.mts} +13 -5
- package/dist/{as-window-table-C1U2gHNy.mjs → as-window-table-BUrMxrbr.mjs} +139 -113
- package/dist/{as-window-table-C4jdyIdV.cjs → as-window-table-DtnaCKyR.cjs} +139 -113
- package/dist/as-window-table.cjs +1 -1
- package/dist/as-window-table.d.cts +1 -1
- package/dist/as-window-table.d.mts +1 -1
- package/dist/as-window-table.mjs +1 -1
- package/dist/{as-window-table.vue-BGz0OaFR.d.cts → as-window-table.vue-DvzoPu-B.d.cts} +13 -5
- package/dist/{as-window-table.vue-CuMQMCnY.d.mts → as-window-table.vue-Gs52IsYw.d.mts} +13 -5
- package/dist/index.cjs +17 -17
- package/dist/index.d.cts +4 -4
- package/dist/index.d.mts +4 -4
- package/dist/index.mjs +17 -17
- package/dist/{use-table-DCH9Sl8T.mjs → use-table-BDkSpj7h.mjs} +1 -1
- package/dist/{use-table-column-handlers-cm0GxR2u.mjs → use-table-column-handlers-CpiiIniD.mjs} +1 -2
- package/dist/{use-table-column-handlers-BgC4gUJV.cjs → use-table-column-handlers-ehreEzcx.cjs} +1 -2
- package/dist/{use-table-component-BIpRevq0.cjs → use-table-component-Bs1T8Mk3.cjs} +1 -1
- package/dist/{use-table-component-Be6w6eL4.mjs → use-table-component-D1Ea4qv_.mjs} +1 -1
- package/dist/{use-table-nav-bridge-jCmNrUfV.cjs → use-table-nav-bridge-DVAQCVrs.cjs} +1 -1
- package/dist/{use-table-nav-bridge-D5B1YBDN.mjs → use-table-nav-bridge-jZMWrBI8.mjs} +1 -1
- package/dist/{use-table-state-C8aMAtiS.mjs → use-table-state-C0m71e4n.mjs} +72 -23
- package/dist/{use-table-state-C3IJ8dJ4.cjs → use-table-state-CmTX31G4.cjs} +77 -22
- package/dist/{use-table-EVIJL8m4.cjs → use-table-w7Bpuk95.cjs} +1 -1
- package/package.json +6 -6
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { a as useTableContext, i as useRegisterMainActionListener } from "./use-table-state-
|
|
1
|
+
import { a as useTableContext, i as useRegisterMainActionListener } from "./use-table-state-C0m71e4n.mjs";
|
|
2
2
|
import { t as useSelectModeReset } from "./use-table-selection-C84z4OZy.mjs";
|
|
3
3
|
import { t as useHasEmitListener } from "./use-has-emit-listener-BTMDIv2e.mjs";
|
|
4
4
|
import { t as getCellValue } from "./get-cell-value-C8LLc_Rr.mjs";
|
|
5
|
-
import { a as
|
|
6
|
-
import { t as useTableColumnHandlers } from "./use-table-column-handlers-
|
|
5
|
+
import { a as useCellComponents, i as useRafBatch, n as as_table_header_default, o as useCellResolver, r as as_table_colgroup_default, t as as_table_status_default } from "./as-table-status-4OaguC5n.mjs";
|
|
6
|
+
import { t as useTableColumnHandlers } from "./use-table-column-handlers-CpiiIniD.mjs";
|
|
7
7
|
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createSlots, createVNode, defineComponent, guardReactiveProps, mergeProps, nextTick, normalizeClass, normalizeProps, normalizeStyle, onBeforeUnmount, onMounted, openBlock, ref, renderList, renderSlot, resolveDynamicComponent, unref, useSlots, watch, withCtx, withModifiers } from "vue";
|
|
8
8
|
import { DEFAULT_ROW_HEIGHT_PX, clampTopIndex, filledFilterCount } from "@atscript/ui-table";
|
|
9
9
|
import { useElementSize, useResizeObserver } from "@vueuse/core";
|
|
@@ -236,6 +236,11 @@ var as_window_table_base_default = /* @__PURE__ */ defineComponent({
|
|
|
236
236
|
enterAction: {
|
|
237
237
|
type: String,
|
|
238
238
|
required: false
|
|
239
|
+
},
|
|
240
|
+
headless: {
|
|
241
|
+
type: Boolean,
|
|
242
|
+
required: false,
|
|
243
|
+
default: false
|
|
239
244
|
}
|
|
240
245
|
},
|
|
241
246
|
emits: [
|
|
@@ -412,125 +417,139 @@ var as_window_table_base_default = /* @__PURE__ */ defineComponent({
|
|
|
412
417
|
role: "grid",
|
|
413
418
|
"aria-rowcount": unref(state).totalCount.value + 1,
|
|
414
419
|
"aria-multiselectable": __props.select === "multi" ? "true" : void 0
|
|
415
|
-
}, [
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
"enable-auto-fit": true,
|
|
428
|
-
"aria-rowindex": 1,
|
|
429
|
-
onSort: unref(onSort),
|
|
430
|
-
onHide: unref(onHide),
|
|
431
|
-
onFilter: unref(onFilter),
|
|
432
|
-
onFiltersOff: unref(onFiltersOff),
|
|
433
|
-
onResetWidth: unref(onResetWidth),
|
|
434
|
-
onReorder: unref(onReorder),
|
|
435
|
-
onResize: unref(state).setColumnWidth,
|
|
436
|
-
onSelectAllToggle
|
|
437
|
-
}, createSlots({ _: 2 }, [renderList(unref(state).columns.value, (col) => {
|
|
438
|
-
return {
|
|
439
|
-
name: `header-${col.path}`,
|
|
440
|
-
fn: withCtx((scope) => [renderSlot(_ctx.$slots, `header-${col.path}`, normalizeProps(guardReactiveProps(scope)))])
|
|
441
|
-
};
|
|
442
|
-
})]), 1032, [
|
|
443
|
-
"columns",
|
|
444
|
-
"sorters",
|
|
445
|
-
"filters",
|
|
446
|
-
"column-menu",
|
|
447
|
-
"column-widths",
|
|
448
|
-
"reorderable",
|
|
449
|
-
"resizable",
|
|
450
|
-
"column-min-width",
|
|
451
|
-
"has-select-column",
|
|
452
|
-
"select-all-state",
|
|
453
|
-
"onSort",
|
|
454
|
-
"onHide",
|
|
455
|
-
"onFilter",
|
|
456
|
-
"onFiltersOff",
|
|
457
|
-
"onResetWidth",
|
|
458
|
-
"onReorder",
|
|
459
|
-
"onResize"
|
|
460
|
-
]), createElementVNode("tbody", {
|
|
461
|
-
ref_key: "poolRef",
|
|
462
|
-
ref: poolRef,
|
|
463
|
-
class: "as-window-row-pool",
|
|
464
|
-
tabindex: "0",
|
|
465
|
-
"aria-activedescendant": unref(state).activeIndex.value >= 0 ? unref(state).rowId(unref(state).activeIndex.value) : "",
|
|
466
|
-
onWheel,
|
|
467
|
-
onKeydown,
|
|
468
|
-
onTouchstart: onTouchStart,
|
|
469
|
-
onTouchmove: withModifiers(onTouchMove, ["prevent"]),
|
|
470
|
-
onTouchend: onTouchEnd
|
|
471
|
-
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(visibleSlots.value, (slot) => {
|
|
472
|
-
return openBlock(), createElementBlock(Fragment, { key: `slot-${slot.s}` }, [slot.row !== void 0 ? (openBlock(), createElementBlock("tr", {
|
|
420
|
+
}, [
|
|
421
|
+
createVNode(as_table_colgroup_default, {
|
|
422
|
+
columns: unref(state).columns.value,
|
|
423
|
+
"column-widths": unref(state).columnWidths.value,
|
|
424
|
+
"has-select": hasValue.value,
|
|
425
|
+
"with-filler": true
|
|
426
|
+
}, null, 8, [
|
|
427
|
+
"columns",
|
|
428
|
+
"column-widths",
|
|
429
|
+
"has-select"
|
|
430
|
+
]),
|
|
431
|
+
!__props.headless ? (openBlock(), createBlock(as_table_header_default, {
|
|
473
432
|
key: 0,
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
"
|
|
478
|
-
"
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
433
|
+
columns: unref(state).columns.value,
|
|
434
|
+
sorters: unref(state).sorters.value,
|
|
435
|
+
filters: unref(state).filters.value,
|
|
436
|
+
"column-menu": __props.columnMenu,
|
|
437
|
+
"column-widths": unref(state).columnWidths.value,
|
|
438
|
+
reorderable: __props.reorderable,
|
|
439
|
+
resizable: __props.resizable,
|
|
440
|
+
"column-min-width": __props.columnMinWidth,
|
|
441
|
+
"has-select-column": hasValue.value,
|
|
442
|
+
"select-all-state": selectAllState.value,
|
|
443
|
+
"with-filler": true,
|
|
444
|
+
"enable-auto-fit": true,
|
|
445
|
+
"aria-rowindex": 1,
|
|
446
|
+
onSort: unref(onSort),
|
|
447
|
+
onHide: unref(onHide),
|
|
448
|
+
onFilter: unref(onFilter),
|
|
449
|
+
onFiltersOff: unref(onFiltersOff),
|
|
450
|
+
onResetWidth: unref(onResetWidth),
|
|
451
|
+
onReorder: unref(onReorder),
|
|
452
|
+
onResize: unref(state).setColumnWidth,
|
|
453
|
+
onSelectAllToggle
|
|
454
|
+
}, createSlots({ _: 2 }, [renderList(unref(state).columns.value, (col) => {
|
|
455
|
+
return {
|
|
456
|
+
name: `header-${col.path}`,
|
|
457
|
+
fn: withCtx((scope) => [renderSlot(_ctx.$slots, `header-${col.path}`, normalizeProps(guardReactiveProps(scope)))])
|
|
458
|
+
};
|
|
459
|
+
})]), 1032, [
|
|
460
|
+
"columns",
|
|
461
|
+
"sorters",
|
|
462
|
+
"filters",
|
|
463
|
+
"column-menu",
|
|
464
|
+
"column-widths",
|
|
465
|
+
"reorderable",
|
|
466
|
+
"resizable",
|
|
467
|
+
"column-min-width",
|
|
468
|
+
"has-select-column",
|
|
469
|
+
"select-all-state",
|
|
470
|
+
"onSort",
|
|
471
|
+
"onHide",
|
|
472
|
+
"onFilter",
|
|
473
|
+
"onFiltersOff",
|
|
474
|
+
"onResetWidth",
|
|
475
|
+
"onReorder",
|
|
476
|
+
"onResize"
|
|
477
|
+
])) : createCommentVNode("v-if", true),
|
|
478
|
+
createElementVNode("tbody", {
|
|
479
|
+
ref_key: "poolRef",
|
|
480
|
+
ref: poolRef,
|
|
481
|
+
class: "as-window-row-pool",
|
|
482
|
+
tabindex: "0",
|
|
483
|
+
"aria-activedescendant": unref(state).activeIndex.value >= 0 ? unref(state).rowId(unref(state).activeIndex.value) : "",
|
|
484
|
+
onWheel,
|
|
485
|
+
onKeydown,
|
|
486
|
+
onTouchstart: onTouchStart,
|
|
487
|
+
onTouchmove: withModifiers(onTouchMove, ["prevent"]),
|
|
488
|
+
onTouchend: onTouchEnd
|
|
489
|
+
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(visibleSlots.value, (slot) => {
|
|
490
|
+
return openBlock(), createElementBlock(Fragment, { key: `slot-${slot.s}` }, [slot.row !== void 0 ? (openBlock(), createElementBlock("tr", {
|
|
491
|
+
key: 0,
|
|
492
|
+
id: unref(state).rowId(unref(state).topIndex.value + slot.s),
|
|
493
|
+
class: normalizeClass(["as-window-data-row", { "as-table-row-active": unref(state).activeIndex.value === unref(state).topIndex.value + slot.s }]),
|
|
494
|
+
role: "row",
|
|
495
|
+
"aria-rowindex": unref(state).topIndex.value + slot.s + 2,
|
|
496
|
+
"aria-selected": slot.ariaSelected,
|
|
497
|
+
style: normalizeStyle(rowStyle.value),
|
|
498
|
+
onClick: ($event) => onRowClick(slot.row, $event, unref(state).topIndex.value + slot.s),
|
|
499
|
+
onDblclick: ($event) => onRowDblClick(slot.row, $event, unref(state).topIndex.value + slot.s)
|
|
500
|
+
}, [
|
|
501
|
+
hasValue.value ? (openBlock(), createElementBlock("td", _hoisted_5, [createElementVNode("span", {
|
|
502
|
+
class: normalizeClass(["as-table-checkbox", { "as-table-checkbox-checked": slot.selected }]),
|
|
503
|
+
role: "checkbox",
|
|
504
|
+
tabindex: "0",
|
|
505
|
+
"aria-checked": slot.selected ? "true" : "false"
|
|
506
|
+
}, [slot.selected ? (openBlock(), createElementBlock("span", _hoisted_7)) : createCommentVNode("v-if", true)], 10, _hoisted_6)])) : createCommentVNode("v-if", true),
|
|
507
|
+
unref(hasAnyCellBindings) ? (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(unref(state).columns.value, (col) => {
|
|
508
|
+
return openBlock(), createElementBlock(Fragment, { key: col.path }, [(openBlock(true), createElementBlock(Fragment, null, renderList([unref(cellResolver)(col, slot.row, unref(state).topIndex.value + slot.s)], (bindings) => {
|
|
509
|
+
return openBlock(), createElementBlock(Fragment, { key: 0 }, [cellSlotFlags.value[col.path] ? (openBlock(), createElementBlock("td", mergeProps({
|
|
510
|
+
key: 0,
|
|
511
|
+
role: "gridcell"
|
|
512
|
+
}, { ref_for: true }, bindings), [renderSlot(_ctx.$slots, `cell-${col.path}`, {
|
|
513
|
+
row: slot.row,
|
|
514
|
+
value: unref(getCellValue)(slot.row, col.path),
|
|
515
|
+
column: col
|
|
516
|
+
})], 16)) : (openBlock(), createBlock(resolveDynamicComponent(unref(cellComponents)[col.path]), mergeProps({
|
|
517
|
+
key: 1,
|
|
518
|
+
row: slot.row,
|
|
519
|
+
column: col,
|
|
520
|
+
role: "gridcell"
|
|
521
|
+
}, { ref_for: true }, bindings), null, 16, ["row", "column"]))], 64);
|
|
522
|
+
}), 128))], 64);
|
|
523
|
+
}), 128)) : (openBlock(true), createElementBlock(Fragment, { key: 2 }, renderList(unref(state).columns.value, (col) => {
|
|
524
|
+
return openBlock(), createElementBlock(Fragment, { key: col.path }, [cellSlotFlags.value[col.path] ? (openBlock(), createElementBlock("td", _hoisted_8, [renderSlot(_ctx.$slots, `cell-${col.path}`, {
|
|
495
525
|
row: slot.row,
|
|
496
526
|
value: unref(getCellValue)(slot.row, col.path),
|
|
497
527
|
column: col
|
|
498
|
-
})]
|
|
528
|
+
})])) : (openBlock(), createBlock(resolveDynamicComponent(unref(cellComponents)[col.path]), {
|
|
499
529
|
key: 1,
|
|
500
530
|
row: slot.row,
|
|
501
531
|
column: col,
|
|
502
532
|
role: "gridcell"
|
|
503
|
-
},
|
|
504
|
-
}), 128))
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
row: slot.row,
|
|
508
|
-
value: unref(getCellValue)(slot.row, col.path),
|
|
509
|
-
column: col
|
|
510
|
-
})])) : (openBlock(), createBlock(resolveDynamicComponent(unref(cellComponents)[col.path]), {
|
|
511
|
-
key: 1,
|
|
512
|
-
row: slot.row,
|
|
513
|
-
column: col,
|
|
533
|
+
}, null, 8, ["row", "column"]))], 64);
|
|
534
|
+
}), 128)),
|
|
535
|
+
_cache[1] || (_cache[1] = createElementVNode("td", {
|
|
536
|
+
class: "as-td-filler",
|
|
514
537
|
role: "gridcell"
|
|
515
|
-
}, null,
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
"has-select",
|
|
531
|
-
"errored"
|
|
532
|
-
]))], 64);
|
|
533
|
-
}), 128))], 40, _hoisted_3)], 8, _hoisted_2),
|
|
538
|
+
}, null, -1))
|
|
539
|
+
], 46, _hoisted_4)) : (openBlock(), createBlock(as_window_skeleton_row_default, {
|
|
540
|
+
key: 1,
|
|
541
|
+
columns: unref(state).columns.value,
|
|
542
|
+
"row-height": __props.rowHeight,
|
|
543
|
+
"has-select": hasValue.value,
|
|
544
|
+
errored: slot.errored
|
|
545
|
+
}, null, 8, [
|
|
546
|
+
"columns",
|
|
547
|
+
"row-height",
|
|
548
|
+
"has-select",
|
|
549
|
+
"errored"
|
|
550
|
+
]))], 64);
|
|
551
|
+
}), 128))], 40, _hoisted_3)
|
|
552
|
+
], 8, _hoisted_2),
|
|
534
553
|
createCommentVNode(" Error / empty placeholders render INSIDE the wrapper so they cover\n the empty pool body when there's nothing to show; suppressed during\n a `querying` refresh because the full-table overlay covers that case. "),
|
|
535
554
|
createVNode(as_table_status_default, {
|
|
536
555
|
"query-error": unref(state).queryError.value,
|
|
@@ -633,6 +652,11 @@ var as_window_table_default = /* @__PURE__ */ defineComponent({
|
|
|
633
652
|
type: [Boolean, Object],
|
|
634
653
|
required: false,
|
|
635
654
|
default: false
|
|
655
|
+
},
|
|
656
|
+
headless: {
|
|
657
|
+
type: Boolean,
|
|
658
|
+
required: false,
|
|
659
|
+
default: false
|
|
636
660
|
}
|
|
637
661
|
},
|
|
638
662
|
emits: [
|
|
@@ -682,6 +706,7 @@ var as_window_table_default = /* @__PURE__ */ defineComponent({
|
|
|
682
706
|
resizable: __props.resizable,
|
|
683
707
|
"column-min-width": __props.columnMinWidth,
|
|
684
708
|
select: __props.select,
|
|
709
|
+
headless: __props.headless,
|
|
685
710
|
"enter-action": __props.enterAction,
|
|
686
711
|
onRowClick: _cache[0] || (_cache[0] = (row, ev) => emit("row-click", row, ev)),
|
|
687
712
|
onRowDblclick: _cache[1] || (_cache[1] = (row, ev) => emit("row-dblclick", row, ev)),
|
|
@@ -699,6 +724,7 @@ var as_window_table_default = /* @__PURE__ */ defineComponent({
|
|
|
699
724
|
"resizable",
|
|
700
725
|
"column-min-width",
|
|
701
726
|
"select",
|
|
727
|
+
"headless",
|
|
702
728
|
"enter-action"
|
|
703
729
|
]), unref(state).querying.value ? (openBlock(), createElementBlock("div", _hoisted_1, [renderSlot(_ctx.$slots, "query-loading", {}, () => [_cache[2] || (_cache[2] = createElementVNode("span", {
|
|
704
730
|
class: "as-table-query-overlay-icon",
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
const require_use_table_state = require("./use-table-state-
|
|
1
|
+
const require_use_table_state = require("./use-table-state-CmTX31G4.cjs");
|
|
2
2
|
const require_use_table_selection = require("./use-table-selection-Cmiu1h4S.cjs");
|
|
3
3
|
const require_use_has_emit_listener = require("./use-has-emit-listener-hhOH8CBI.cjs");
|
|
4
4
|
const require_get_cell_value = require("./get-cell-value-4rHKP-TG.cjs");
|
|
5
|
-
const require_as_table_status = require("./as-table-status-
|
|
6
|
-
const require_use_table_column_handlers = require("./use-table-column-handlers-
|
|
5
|
+
const require_as_table_status = require("./as-table-status-Diyy3DFB.cjs");
|
|
6
|
+
const require_use_table_column_handlers = require("./use-table-column-handlers-ehreEzcx.cjs");
|
|
7
7
|
let vue = require("vue");
|
|
8
8
|
let _atscript_ui_table = require("@atscript/ui-table");
|
|
9
9
|
let _vueuse_core = require("@vueuse/core");
|
|
@@ -236,6 +236,11 @@ var as_window_table_base_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
236
236
|
enterAction: {
|
|
237
237
|
type: String,
|
|
238
238
|
required: false
|
|
239
|
+
},
|
|
240
|
+
headless: {
|
|
241
|
+
type: Boolean,
|
|
242
|
+
required: false,
|
|
243
|
+
default: false
|
|
239
244
|
}
|
|
240
245
|
},
|
|
241
246
|
emits: [
|
|
@@ -412,125 +417,139 @@ var as_window_table_base_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
412
417
|
role: "grid",
|
|
413
418
|
"aria-rowcount": (0, vue.unref)(state).totalCount.value + 1,
|
|
414
419
|
"aria-multiselectable": __props.select === "multi" ? "true" : void 0
|
|
415
|
-
}, [
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
"enable-auto-fit": true,
|
|
428
|
-
"aria-rowindex": 1,
|
|
429
|
-
onSort: (0, vue.unref)(onSort),
|
|
430
|
-
onHide: (0, vue.unref)(onHide),
|
|
431
|
-
onFilter: (0, vue.unref)(onFilter),
|
|
432
|
-
onFiltersOff: (0, vue.unref)(onFiltersOff),
|
|
433
|
-
onResetWidth: (0, vue.unref)(onResetWidth),
|
|
434
|
-
onReorder: (0, vue.unref)(onReorder),
|
|
435
|
-
onResize: (0, vue.unref)(state).setColumnWidth,
|
|
436
|
-
onSelectAllToggle
|
|
437
|
-
}, (0, vue.createSlots)({ _: 2 }, [(0, vue.renderList)((0, vue.unref)(state).columns.value, (col) => {
|
|
438
|
-
return {
|
|
439
|
-
name: `header-${col.path}`,
|
|
440
|
-
fn: (0, vue.withCtx)((scope) => [(0, vue.renderSlot)(_ctx.$slots, `header-${col.path}`, (0, vue.normalizeProps)((0, vue.guardReactiveProps)(scope)))])
|
|
441
|
-
};
|
|
442
|
-
})]), 1032, [
|
|
443
|
-
"columns",
|
|
444
|
-
"sorters",
|
|
445
|
-
"filters",
|
|
446
|
-
"column-menu",
|
|
447
|
-
"column-widths",
|
|
448
|
-
"reorderable",
|
|
449
|
-
"resizable",
|
|
450
|
-
"column-min-width",
|
|
451
|
-
"has-select-column",
|
|
452
|
-
"select-all-state",
|
|
453
|
-
"onSort",
|
|
454
|
-
"onHide",
|
|
455
|
-
"onFilter",
|
|
456
|
-
"onFiltersOff",
|
|
457
|
-
"onResetWidth",
|
|
458
|
-
"onReorder",
|
|
459
|
-
"onResize"
|
|
460
|
-
]), (0, vue.createElementVNode)("tbody", {
|
|
461
|
-
ref_key: "poolRef",
|
|
462
|
-
ref: poolRef,
|
|
463
|
-
class: "as-window-row-pool",
|
|
464
|
-
tabindex: "0",
|
|
465
|
-
"aria-activedescendant": (0, vue.unref)(state).activeIndex.value >= 0 ? (0, vue.unref)(state).rowId((0, vue.unref)(state).activeIndex.value) : "",
|
|
466
|
-
onWheel,
|
|
467
|
-
onKeydown,
|
|
468
|
-
onTouchstart: onTouchStart,
|
|
469
|
-
onTouchmove: (0, vue.withModifiers)(onTouchMove, ["prevent"]),
|
|
470
|
-
onTouchend: onTouchEnd
|
|
471
|
-
}, [((0, vue.openBlock)(true), (0, vue.createElementBlock)(vue.Fragment, null, (0, vue.renderList)(visibleSlots.value, (slot) => {
|
|
472
|
-
return (0, vue.openBlock)(), (0, vue.createElementBlock)(vue.Fragment, { key: `slot-${slot.s}` }, [slot.row !== void 0 ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("tr", {
|
|
420
|
+
}, [
|
|
421
|
+
(0, vue.createVNode)(require_as_table_status.as_table_colgroup_default, {
|
|
422
|
+
columns: (0, vue.unref)(state).columns.value,
|
|
423
|
+
"column-widths": (0, vue.unref)(state).columnWidths.value,
|
|
424
|
+
"has-select": hasValue.value,
|
|
425
|
+
"with-filler": true
|
|
426
|
+
}, null, 8, [
|
|
427
|
+
"columns",
|
|
428
|
+
"column-widths",
|
|
429
|
+
"has-select"
|
|
430
|
+
]),
|
|
431
|
+
!__props.headless ? ((0, vue.openBlock)(), (0, vue.createBlock)(require_as_table_status.as_table_header_default, {
|
|
473
432
|
key: 0,
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
"
|
|
478
|
-
"
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
433
|
+
columns: (0, vue.unref)(state).columns.value,
|
|
434
|
+
sorters: (0, vue.unref)(state).sorters.value,
|
|
435
|
+
filters: (0, vue.unref)(state).filters.value,
|
|
436
|
+
"column-menu": __props.columnMenu,
|
|
437
|
+
"column-widths": (0, vue.unref)(state).columnWidths.value,
|
|
438
|
+
reorderable: __props.reorderable,
|
|
439
|
+
resizable: __props.resizable,
|
|
440
|
+
"column-min-width": __props.columnMinWidth,
|
|
441
|
+
"has-select-column": hasValue.value,
|
|
442
|
+
"select-all-state": selectAllState.value,
|
|
443
|
+
"with-filler": true,
|
|
444
|
+
"enable-auto-fit": true,
|
|
445
|
+
"aria-rowindex": 1,
|
|
446
|
+
onSort: (0, vue.unref)(onSort),
|
|
447
|
+
onHide: (0, vue.unref)(onHide),
|
|
448
|
+
onFilter: (0, vue.unref)(onFilter),
|
|
449
|
+
onFiltersOff: (0, vue.unref)(onFiltersOff),
|
|
450
|
+
onResetWidth: (0, vue.unref)(onResetWidth),
|
|
451
|
+
onReorder: (0, vue.unref)(onReorder),
|
|
452
|
+
onResize: (0, vue.unref)(state).setColumnWidth,
|
|
453
|
+
onSelectAllToggle
|
|
454
|
+
}, (0, vue.createSlots)({ _: 2 }, [(0, vue.renderList)((0, vue.unref)(state).columns.value, (col) => {
|
|
455
|
+
return {
|
|
456
|
+
name: `header-${col.path}`,
|
|
457
|
+
fn: (0, vue.withCtx)((scope) => [(0, vue.renderSlot)(_ctx.$slots, `header-${col.path}`, (0, vue.normalizeProps)((0, vue.guardReactiveProps)(scope)))])
|
|
458
|
+
};
|
|
459
|
+
})]), 1032, [
|
|
460
|
+
"columns",
|
|
461
|
+
"sorters",
|
|
462
|
+
"filters",
|
|
463
|
+
"column-menu",
|
|
464
|
+
"column-widths",
|
|
465
|
+
"reorderable",
|
|
466
|
+
"resizable",
|
|
467
|
+
"column-min-width",
|
|
468
|
+
"has-select-column",
|
|
469
|
+
"select-all-state",
|
|
470
|
+
"onSort",
|
|
471
|
+
"onHide",
|
|
472
|
+
"onFilter",
|
|
473
|
+
"onFiltersOff",
|
|
474
|
+
"onResetWidth",
|
|
475
|
+
"onReorder",
|
|
476
|
+
"onResize"
|
|
477
|
+
])) : (0, vue.createCommentVNode)("v-if", true),
|
|
478
|
+
(0, vue.createElementVNode)("tbody", {
|
|
479
|
+
ref_key: "poolRef",
|
|
480
|
+
ref: poolRef,
|
|
481
|
+
class: "as-window-row-pool",
|
|
482
|
+
tabindex: "0",
|
|
483
|
+
"aria-activedescendant": (0, vue.unref)(state).activeIndex.value >= 0 ? (0, vue.unref)(state).rowId((0, vue.unref)(state).activeIndex.value) : "",
|
|
484
|
+
onWheel,
|
|
485
|
+
onKeydown,
|
|
486
|
+
onTouchstart: onTouchStart,
|
|
487
|
+
onTouchmove: (0, vue.withModifiers)(onTouchMove, ["prevent"]),
|
|
488
|
+
onTouchend: onTouchEnd
|
|
489
|
+
}, [((0, vue.openBlock)(true), (0, vue.createElementBlock)(vue.Fragment, null, (0, vue.renderList)(visibleSlots.value, (slot) => {
|
|
490
|
+
return (0, vue.openBlock)(), (0, vue.createElementBlock)(vue.Fragment, { key: `slot-${slot.s}` }, [slot.row !== void 0 ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("tr", {
|
|
491
|
+
key: 0,
|
|
492
|
+
id: (0, vue.unref)(state).rowId((0, vue.unref)(state).topIndex.value + slot.s),
|
|
493
|
+
class: (0, vue.normalizeClass)(["as-window-data-row", { "as-table-row-active": (0, vue.unref)(state).activeIndex.value === (0, vue.unref)(state).topIndex.value + slot.s }]),
|
|
494
|
+
role: "row",
|
|
495
|
+
"aria-rowindex": (0, vue.unref)(state).topIndex.value + slot.s + 2,
|
|
496
|
+
"aria-selected": slot.ariaSelected,
|
|
497
|
+
style: (0, vue.normalizeStyle)(rowStyle.value),
|
|
498
|
+
onClick: ($event) => onRowClick(slot.row, $event, (0, vue.unref)(state).topIndex.value + slot.s),
|
|
499
|
+
onDblclick: ($event) => onRowDblClick(slot.row, $event, (0, vue.unref)(state).topIndex.value + slot.s)
|
|
500
|
+
}, [
|
|
501
|
+
hasValue.value ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("td", _hoisted_5, [(0, vue.createElementVNode)("span", {
|
|
502
|
+
class: (0, vue.normalizeClass)(["as-table-checkbox", { "as-table-checkbox-checked": slot.selected }]),
|
|
503
|
+
role: "checkbox",
|
|
504
|
+
tabindex: "0",
|
|
505
|
+
"aria-checked": slot.selected ? "true" : "false"
|
|
506
|
+
}, [slot.selected ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("span", _hoisted_7)) : (0, vue.createCommentVNode)("v-if", true)], 10, _hoisted_6)])) : (0, vue.createCommentVNode)("v-if", true),
|
|
507
|
+
(0, vue.unref)(hasAnyCellBindings) ? ((0, vue.openBlock)(true), (0, vue.createElementBlock)(vue.Fragment, { key: 1 }, (0, vue.renderList)((0, vue.unref)(state).columns.value, (col) => {
|
|
508
|
+
return (0, vue.openBlock)(), (0, vue.createElementBlock)(vue.Fragment, { key: col.path }, [((0, vue.openBlock)(true), (0, vue.createElementBlock)(vue.Fragment, null, (0, vue.renderList)([(0, vue.unref)(cellResolver)(col, slot.row, (0, vue.unref)(state).topIndex.value + slot.s)], (bindings) => {
|
|
509
|
+
return (0, vue.openBlock)(), (0, vue.createElementBlock)(vue.Fragment, { key: 0 }, [cellSlotFlags.value[col.path] ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("td", (0, vue.mergeProps)({
|
|
510
|
+
key: 0,
|
|
511
|
+
role: "gridcell"
|
|
512
|
+
}, { ref_for: true }, bindings), [(0, vue.renderSlot)(_ctx.$slots, `cell-${col.path}`, {
|
|
513
|
+
row: slot.row,
|
|
514
|
+
value: (0, vue.unref)(require_get_cell_value.getCellValue)(slot.row, col.path),
|
|
515
|
+
column: col
|
|
516
|
+
})], 16)) : ((0, vue.openBlock)(), (0, vue.createBlock)((0, vue.resolveDynamicComponent)((0, vue.unref)(cellComponents)[col.path]), (0, vue.mergeProps)({
|
|
517
|
+
key: 1,
|
|
518
|
+
row: slot.row,
|
|
519
|
+
column: col,
|
|
520
|
+
role: "gridcell"
|
|
521
|
+
}, { ref_for: true }, bindings), null, 16, ["row", "column"]))], 64);
|
|
522
|
+
}), 128))], 64);
|
|
523
|
+
}), 128)) : ((0, vue.openBlock)(true), (0, vue.createElementBlock)(vue.Fragment, { key: 2 }, (0, vue.renderList)((0, vue.unref)(state).columns.value, (col) => {
|
|
524
|
+
return (0, vue.openBlock)(), (0, vue.createElementBlock)(vue.Fragment, { key: col.path }, [cellSlotFlags.value[col.path] ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("td", _hoisted_8, [(0, vue.renderSlot)(_ctx.$slots, `cell-${col.path}`, {
|
|
495
525
|
row: slot.row,
|
|
496
526
|
value: (0, vue.unref)(require_get_cell_value.getCellValue)(slot.row, col.path),
|
|
497
527
|
column: col
|
|
498
|
-
})]
|
|
528
|
+
})])) : ((0, vue.openBlock)(), (0, vue.createBlock)((0, vue.resolveDynamicComponent)((0, vue.unref)(cellComponents)[col.path]), {
|
|
499
529
|
key: 1,
|
|
500
530
|
row: slot.row,
|
|
501
531
|
column: col,
|
|
502
532
|
role: "gridcell"
|
|
503
|
-
},
|
|
504
|
-
}), 128))
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
row: slot.row,
|
|
508
|
-
value: (0, vue.unref)(require_get_cell_value.getCellValue)(slot.row, col.path),
|
|
509
|
-
column: col
|
|
510
|
-
})])) : ((0, vue.openBlock)(), (0, vue.createBlock)((0, vue.resolveDynamicComponent)((0, vue.unref)(cellComponents)[col.path]), {
|
|
511
|
-
key: 1,
|
|
512
|
-
row: slot.row,
|
|
513
|
-
column: col,
|
|
533
|
+
}, null, 8, ["row", "column"]))], 64);
|
|
534
|
+
}), 128)),
|
|
535
|
+
_cache[1] || (_cache[1] = (0, vue.createElementVNode)("td", {
|
|
536
|
+
class: "as-td-filler",
|
|
514
537
|
role: "gridcell"
|
|
515
|
-
}, null,
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
"has-select",
|
|
531
|
-
"errored"
|
|
532
|
-
]))], 64);
|
|
533
|
-
}), 128))], 40, _hoisted_3)], 8, _hoisted_2),
|
|
538
|
+
}, null, -1))
|
|
539
|
+
], 46, _hoisted_4)) : ((0, vue.openBlock)(), (0, vue.createBlock)(as_window_skeleton_row_default, {
|
|
540
|
+
key: 1,
|
|
541
|
+
columns: (0, vue.unref)(state).columns.value,
|
|
542
|
+
"row-height": __props.rowHeight,
|
|
543
|
+
"has-select": hasValue.value,
|
|
544
|
+
errored: slot.errored
|
|
545
|
+
}, null, 8, [
|
|
546
|
+
"columns",
|
|
547
|
+
"row-height",
|
|
548
|
+
"has-select",
|
|
549
|
+
"errored"
|
|
550
|
+
]))], 64);
|
|
551
|
+
}), 128))], 40, _hoisted_3)
|
|
552
|
+
], 8, _hoisted_2),
|
|
534
553
|
(0, vue.createCommentVNode)(" Error / empty placeholders render INSIDE the wrapper so they cover\n the empty pool body when there's nothing to show; suppressed during\n a `querying` refresh because the full-table overlay covers that case. "),
|
|
535
554
|
(0, vue.createVNode)(require_as_table_status.as_table_status_default, {
|
|
536
555
|
"query-error": (0, vue.unref)(state).queryError.value,
|
|
@@ -633,6 +652,11 @@ var as_window_table_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
633
652
|
type: [Boolean, Object],
|
|
634
653
|
required: false,
|
|
635
654
|
default: false
|
|
655
|
+
},
|
|
656
|
+
headless: {
|
|
657
|
+
type: Boolean,
|
|
658
|
+
required: false,
|
|
659
|
+
default: false
|
|
636
660
|
}
|
|
637
661
|
},
|
|
638
662
|
emits: [
|
|
@@ -682,6 +706,7 @@ var as_window_table_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
682
706
|
resizable: __props.resizable,
|
|
683
707
|
"column-min-width": __props.columnMinWidth,
|
|
684
708
|
select: __props.select,
|
|
709
|
+
headless: __props.headless,
|
|
685
710
|
"enter-action": __props.enterAction,
|
|
686
711
|
onRowClick: _cache[0] || (_cache[0] = (row, ev) => emit("row-click", row, ev)),
|
|
687
712
|
onRowDblclick: _cache[1] || (_cache[1] = (row, ev) => emit("row-dblclick", row, ev)),
|
|
@@ -699,6 +724,7 @@ var as_window_table_default = /* @__PURE__ */ (0, vue.defineComponent)({
|
|
|
699
724
|
"resizable",
|
|
700
725
|
"column-min-width",
|
|
701
726
|
"select",
|
|
727
|
+
"headless",
|
|
702
728
|
"enter-action"
|
|
703
729
|
]), (0, vue.unref)(state).querying.value ? ((0, vue.openBlock)(), (0, vue.createElementBlock)("div", _hoisted_1, [(0, vue.renderSlot)(_ctx.$slots, "query-loading", {}, () => [_cache[2] || (_cache[2] = (0, vue.createElementVNode)("span", {
|
|
704
730
|
class: "as-table-query-overlay-icon",
|
package/dist/as-window-table.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const require_as_window_table = require("./as-window-table-
|
|
1
|
+
const require_as_window_table = require("./as-window-table-DtnaCKyR.cjs");
|
|
2
2
|
module.exports = require_as_window_table.as_window_table_default;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as _default } from "./as-window-table.vue-
|
|
1
|
+
import { t as _default } from "./as-window-table.vue-DvzoPu-B.cjs";
|
|
2
2
|
export = _default;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as _default } from "./as-window-table.vue-
|
|
1
|
+
import { t as _default } from "./as-window-table.vue-Gs52IsYw.mjs";
|
|
2
2
|
export { _default as default };
|
package/dist/as-window-table.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as as_window_table_default } from "./as-window-table-
|
|
1
|
+
import { t as as_window_table_default } from "./as-window-table-BUrMxrbr.mjs";
|
|
2
2
|
export { as_window_table_default as default };
|