@adapttable/naive-ui 0.1.2 → 0.2.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.
Files changed (95) hide show
  1. package/README.md +14 -0
  2. package/dist/assistant-Cv8df2ti.js +355 -0
  3. package/dist/assistant-Cv8df2ti.js.map +1 -0
  4. package/dist/assistant-D6mc-LJl.cjs +378 -0
  5. package/dist/assistant-D6mc-LJl.cjs.map +1 -0
  6. package/dist/assistant.cjs +5 -354
  7. package/dist/assistant.d.cts.map +1 -1
  8. package/dist/assistant.d.ts.map +1 -1
  9. package/dist/assistant.js +1 -350
  10. package/dist/column-menu-DdWVP1hz.d.cts +23 -0
  11. package/dist/column-menu-DdWVP1hz.d.cts.map +1 -0
  12. package/dist/column-menu-DdWVP1hz.d.ts +23 -0
  13. package/dist/column-menu-DdWVP1hz.d.ts.map +1 -0
  14. package/dist/column-menu.d.cts +2 -23
  15. package/dist/column-menu.d.ts +2 -23
  16. package/dist/command-palette-vIegnqVo.js +112 -0
  17. package/dist/command-palette-vIegnqVo.js.map +1 -0
  18. package/dist/command-palette-ztI3qI2V.cjs +117 -0
  19. package/dist/command-palette-ztI3qI2V.cjs.map +1 -0
  20. package/dist/command-palette.cjs +2 -112
  21. package/dist/command-palette.js +1 -111
  22. package/dist/context-menu-BbhrjTZr.cjs +145 -0
  23. package/dist/context-menu-BbhrjTZr.cjs.map +1 -0
  24. package/dist/context-menu-DjYIQXhY.js +140 -0
  25. package/dist/context-menu-DjYIQXhY.js.map +1 -0
  26. package/dist/context-menu.cjs +2 -140
  27. package/dist/context-menu.js +1 -139
  28. package/dist/features.cjs +217 -0
  29. package/dist/features.d.cts +40 -0
  30. package/dist/features.d.ts +40 -0
  31. package/dist/features.js +36 -0
  32. package/dist/filters-BJ48GzqJ.d.ts +66 -0
  33. package/dist/filters-BJ48GzqJ.d.ts.map +1 -0
  34. package/dist/filters-C6DvAZ_T.d.cts +66 -0
  35. package/dist/filters-C6DvAZ_T.d.cts.map +1 -0
  36. package/dist/filters.d.cts +2 -66
  37. package/dist/filters.d.ts +2 -66
  38. package/dist/grouping-panel-BPaPG49S.cjs +151 -0
  39. package/dist/grouping-panel-BPaPG49S.cjs.map +1 -0
  40. package/dist/grouping-panel-CYUPSa0u.js +146 -0
  41. package/dist/grouping-panel-CYUPSa0u.js.map +1 -0
  42. package/dist/grouping-panel.cjs +3 -146
  43. package/dist/grouping-panel.js +2 -145
  44. package/dist/header-filters-CQg6clum.d.cts +52 -0
  45. package/dist/header-filters-CQg6clum.d.cts.map +1 -0
  46. package/dist/header-filters-CQg6clum.d.ts +52 -0
  47. package/dist/header-filters-CQg6clum.d.ts.map +1 -0
  48. package/dist/header-filters.d.cts +2 -52
  49. package/dist/header-filters.d.ts +2 -52
  50. package/dist/index.cjs +1 -1
  51. package/dist/index.js +1 -1
  52. package/dist/{mobile-Bc3-31-b.cjs → mobile-C2JUs6b_.cjs} +3 -2
  53. package/dist/mobile-C2JUs6b_.cjs.map +1 -0
  54. package/dist/{mobile-Dlwq8dB7.js → mobile-CC3NeIRK.js} +4 -3
  55. package/dist/mobile-CC3NeIRK.js.map +1 -0
  56. package/dist/preset.cjs +5 -5
  57. package/dist/preset.js +5 -5
  58. package/dist/renderers.cjs +1 -1
  59. package/dist/renderers.d.cts.map +1 -1
  60. package/dist/renderers.d.ts.map +1 -1
  61. package/dist/renderers.js +1 -1
  62. package/dist/row-reorder-BNYYEL8w.js +186 -0
  63. package/dist/row-reorder-BNYYEL8w.js.map +1 -0
  64. package/dist/row-reorder-BRySq2FF.cjs +191 -0
  65. package/dist/row-reorder-BRySq2FF.cjs.map +1 -0
  66. package/dist/row-reorder.cjs +2 -185
  67. package/dist/row-reorder.js +1 -185
  68. package/dist/side-panel-Bf4zBlYZ.cjs +64 -0
  69. package/dist/side-panel-Bf4zBlYZ.cjs.map +1 -0
  70. package/dist/side-panel-CLTgXUnb.js +59 -0
  71. package/dist/side-panel-CLTgXUnb.js.map +1 -0
  72. package/dist/side-panel.cjs +2 -59
  73. package/dist/side-panel.js +1 -58
  74. package/dist/styles.css +39 -39
  75. package/package.json +14 -3
  76. package/dist/assistant.cjs.map +0 -1
  77. package/dist/assistant.js.map +0 -1
  78. package/dist/column-menu.d.cts.map +0 -1
  79. package/dist/column-menu.d.ts.map +0 -1
  80. package/dist/command-palette.cjs.map +0 -1
  81. package/dist/command-palette.js.map +0 -1
  82. package/dist/context-menu.cjs.map +0 -1
  83. package/dist/context-menu.js.map +0 -1
  84. package/dist/filters.d.cts.map +0 -1
  85. package/dist/filters.d.ts.map +0 -1
  86. package/dist/grouping-panel.cjs.map +0 -1
  87. package/dist/grouping-panel.js.map +0 -1
  88. package/dist/header-filters.d.cts.map +0 -1
  89. package/dist/header-filters.d.ts.map +0 -1
  90. package/dist/mobile-Bc3-31-b.cjs.map +0 -1
  91. package/dist/mobile-Dlwq8dB7.js.map +0 -1
  92. package/dist/row-reorder.cjs.map +0 -1
  93. package/dist/row-reorder.js.map +0 -1
  94. package/dist/side-panel.cjs.map +0 -1
  95. package/dist/side-panel.js.map +0 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"grouping-panel-CYUPSa0u.js","names":["groupingPanel","grouping","bindingGroupingPanel","NaiveGroupingPanel"],"sources":["../src/grouping/naiveGroupingControls.ts","../src/grouping/NaiveGroupingPanel.vue","../src/grouping-panel.ts"],"sourcesContent":["import {\n type DataTableClassNames,\n type GroupingPanelSlots,\n toVueAttrs,\n} from \"@adapttable/vue/adapter\";\nimport { NCard, NCheckbox, NFlex, NTag, NText } from \"naive-ui\";\nimport { type ComputedRef, h } from \"vue\";\n\nimport { naiveButton } from \"../controls/button\";\nimport { naiveSelect } from \"../controls/select\";\nfunction aggregationOption(\n option: { value: string; label: string; checked: boolean },\n disabled: boolean | undefined,\n onToggle: (value: string, checked: boolean) => void\n) {\n return h(\n NCheckbox,\n {\n key: option.value,\n checked: option.checked,\n disabled,\n \"data-adapttable-part\": \"grouping-aggregation-option\",\n \"onUpdate:checked\": (checked: boolean) => onToggle(option.value, checked),\n },\n { default: () => option.label }\n );\n}\nexport function naiveGroupingControls(\n names: ComputedRef<DataTableClassNames>\n): GroupingPanelSlots {\n return {\n Surface: ({ children, label, mobile, ...attrs }) =>\n h(\n NCard,\n {\n ...toVueAttrs(attrs),\n size: \"small\",\n class: [\n \"adapttable-naive-ui-grouping-layout\",\n names.value.groupingPanel,\n ],\n role: \"group\",\n \"aria-label\": label,\n \"data-mobile\": mobile ? \"\" : undefined,\n },\n {\n default: () => [\n h(\n \"span\",\n { class: \"adapttable-naive-ui-grouping-layout-label\" },\n label\n ),\n children,\n ],\n }\n ),\n DropZone: ({ label, empty, active, dragging, dropProps, ...attrs }) =>\n h(\n NTag,\n {\n ...attrs,\n ...toVueAttrs({ ...dropProps }),\n class: names.value.groupingDropZone,\n \"aria-label\": label,\n \"data-empty\": empty ? \"\" : undefined,\n \"data-active\": active ? \"\" : undefined,\n \"data-dragging\": dragging ? \"\" : undefined,\n },\n { default: () => (empty ? label : \"\") }\n ),\n Chip: ({\n label,\n level,\n dragProps,\n keyboardProps,\n onRemove,\n removeLabel,\n ...attrs\n }) =>\n h(\n NFlex,\n {\n ...attrs,\n inline: true,\n align: \"center\",\n size: 4,\n class: names.value.groupingChip,\n \"data-level\": level,\n },\n {\n default: () => [\n naiveButton(\n {\n ...toVueAttrs({ ...dragProps }),\n ...toVueAttrs({ ...keyboardProps }),\n class: names.value.groupingChipHandle,\n \"data-adapttable-part\": \"grouping-chip-handle\",\n },\n `${level}. ${label}`\n ),\n naiveButton(\n {\n class: names.value.groupingChipRemove,\n \"aria-label\": removeLabel,\n \"data-adapttable-part\": \"grouping-chip-remove\",\n onClick: onRemove,\n },\n \"×\"\n ),\n ],\n }\n ),\n Select: ({ label, value, options, onChange, disabled, ...attrs }) =>\n naiveSelect({\n value,\n options:\n value === \"\"\n ? [{ value: \"\", label, disabled: true }, ...options]\n : options,\n onChange,\n attrs: {\n ...attrs,\n class:\n attrs[\"data-adapttable-part\"] === \"grouping-add\"\n ? names.value.groupingAdd\n : names.value.groupingAggregationOperation,\n disabled,\n \"aria-label\": label,\n placeholder: label,\n },\n }),\n RemoveZone: ({ label, active, dropProps, ...attrs }) =>\n h(\n NTag,\n {\n ...attrs,\n ...toVueAttrs({ ...dropProps }),\n class: names.value.groupingRemoveZone,\n \"aria-label\": label,\n \"data-active\": active ? \"\" : undefined,\n },\n { default: () => label }\n ),\n AggregationItem: ({ label, readOnly, readOnlyLabel, children, ...attrs }) =>\n h(\n NFlex,\n {\n ...attrs,\n inline: true,\n align: \"center\",\n class: names.value.groupingAggregationItem,\n \"data-read-only\": readOnly ? \"\" : undefined,\n },\n {\n default: () => [\n h(NText, null, { default: () => label }),\n readOnly ? h(NTag, null, { default: () => readOnlyLabel }) : null,\n children,\n ],\n }\n ),\n AggregationRemove: ({ label, onRemove, ...attrs }) =>\n naiveButton(\n {\n ...attrs,\n class: names.value.groupingAggregationRemove,\n \"aria-label\": label,\n onClick: onRemove,\n },\n \"×\"\n ),\n AggregationPicker: ({ label, options, onToggle, disabled, ...attrs }) =>\n h(\n NFlex,\n {\n ...attrs,\n role: \"group\",\n \"aria-label\": label,\n class: names.value.groupingAggregationAdd,\n },\n {\n default: () =>\n options.map((option) =>\n aggregationOption(option, disabled, onToggle)\n ),\n }\n ),\n AggregationRestore: ({ label, disabled, onRestore, ...attrs }) =>\n naiveButton(\n {\n ...attrs,\n class: names.value.groupingAggregationsRestore,\n disabled,\n onClick: onRestore,\n },\n label\n ),\n };\n}\n","<script setup lang=\"ts\" generic=\"TRow\">\nimport { type GroupingPanelProps } from \"@adapttable/vue\";\nimport {\n GroupingPanelChrome,\n useDataTableClassNames,\n} from \"@adapttable/vue/adapter\";\n\nimport { naiveGroupingControls } from \"./naiveGroupingControls\";\n\ndefineOptions({ name: \"NaiveGroupingPanel\" });\nconst props = defineProps<GroupingPanelProps<TRow>>();\nconst names = useDataTableClassNames();\nconst controls = naiveGroupingControls(names);\nconst Render = () =>\n GroupingPanelChrome({\n ...props,\n classNames: names.value,\n slots: controls,\n });\n\n// Declare no props so Vue forwards all root attributes, including id and data-*.\nconst renderProps: string[] = [];\nRender.props = renderProps;\n</script>\n\n<template>\n <Render />\n</template>\n\n<style>\n.adapttable-naive-ui-grouping-layout > .n-card-content {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 0.5rem;\n padding: 0.75rem 1rem;\n min-inline-size: 0;\n}\n.adapttable-naive-ui-grouping-layout-label,\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-aggregations\"]::before {\n font-size: 0.8125rem;\n font-weight: 600;\n color: var(--n-text-color);\n margin-inline-end: 0.5rem;\n}\n.adapttable-naive-ui-grouping-layout [data-adapttable-part=\"grouping-add\"] {\n flex: 0 1 15rem;\n inline-size: 15rem;\n min-inline-size: 0;\n max-inline-size: 100%;\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-aggregations\"] {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 0.75rem;\n flex-basis: 100%;\n min-inline-size: 0;\n margin: 0.25rem 0 0;\n padding: 0.75rem 0 0;\n border: 0;\n border-block-start: 1px solid var(--n-border-color);\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-aggregations\"]::before {\n content: attr(aria-label);\n}\n.adapttable-naive-ui-grouping-layout [data-adapttable-aggregation],\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-aggregation-item\"] {\n display: inline-flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 0.5rem;\n min-inline-size: 0;\n max-inline-size: 100%;\n margin: 0;\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-aggregation-operation\"] {\n flex: 0 1 8rem;\n inline-size: 8rem;\n min-inline-size: 0;\n max-inline-size: 100%;\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-aggregation-add\"] {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: 0.5rem 0.75rem;\n min-inline-size: 0;\n max-inline-size: 100%;\n margin: 0;\n padding: 0;\n border: 0;\n box-shadow: none;\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-aggregation-add\"]\n legend {\n float: inline-start;\n padding: 0;\n font-size: 0.8125rem;\n color: var(--n-text-color);\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-aggregation-add\"]\n label {\n display: inline-flex;\n align-items: center;\n gap: 0.375rem;\n margin: 0;\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-chip-remove\"],\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-aggregation-remove\"] {\n min-inline-size: 2rem;\n min-block-size: 2rem;\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-drop-zone\"]:not([data-empty]):not(\n [data-dragging]\n ):not([data-active]) {\n opacity: 0;\n}\n\n/* Keep insertion boundaries stable so the target never moves under the pointer. */\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-drop-zone\"] {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n flex: 0 0 auto;\n min-inline-size: 10px;\n min-block-size: 32px;\n block-size: auto;\n transition:\n border-color 120ms ease,\n background-color 120ms ease;\n margin-inline: 2px;\n padding: 0;\n border: 1px dashed color-mix(in srgb, currentColor 30%, transparent);\n border-radius: 4px;\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-drop-zone\"][data-empty] {\n min-inline-size: 9rem;\n min-block-size: 44px;\n padding: 0.5rem;\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-drop-zone\"][data-dragging] {\n opacity: 1;\n border-color: var(--adapttable-naive-primary, #18a058);\n background: color-mix(\n in srgb,\n var(--adapttable-naive-primary, #18a058) 8%,\n transparent\n );\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-drop-zone\"][data-active] {\n border-style: solid;\n border-color: var(--adapttable-naive-primary, #18a058);\n background: color-mix(\n in srgb,\n var(--adapttable-naive-primary, #18a058) 22%,\n transparent\n );\n outline: 2px solid var(--adapttable-naive-primary, #18a058);\n outline-offset: 1px;\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-chip-handle\"] {\n cursor: grab;\n}\n.adapttable-naive-ui-grouping-layout [data-grouping-dragging] {\n opacity: 0.5;\n cursor: grabbing;\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-remove-zone\"] {\n display: flex;\n flex: 1 1 100%;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n min-block-size: 44px;\n padding: 0.5rem 0.75rem;\n border: 1px dashed var(--adapttable-naive-error, #d03050);\n border-radius: 6px;\n color: var(--adapttable-naive-error, #d03050);\n font-size: 0.8125rem;\n}\n.adapttable-naive-ui-grouping-layout\n [data-adapttable-part=\"grouping-remove-zone\"][data-active] {\n background: color-mix(\n in srgb,\n var(--adapttable-naive-error, #d03050) 12%,\n transparent\n );\n border-style: solid;\n outline: 2px solid var(--adapttable-naive-error, #d03050);\n}\n</style>\n","import { type StaticTableFeature, type TableFeature } from \"@adapttable/vue\";\nimport {\n extendFeature,\n groupingPanelControlKey,\n slotRender,\n} from \"@adapttable/vue/adapter\";\nimport {\n type GroupingExtras,\n groupingPanel as bindingGroupingPanel,\n type StaticGroupingExtras,\n} from \"@adapttable/vue/features\";\nimport { h } from \"vue\";\n\nimport { grouping } from \"./grouping\";\nimport NaiveGroupingPanel from \"./grouping/NaiveGroupingPanel.vue\";\nexport type { GroupingPanelProps } from \"@adapttable/vue\";\nexport type { GroupingExtras } from \"@adapttable/vue/features\";\nexport function groupingPanel(\n initialGroupBy?: string | readonly string[],\n extras?: StaticGroupingExtras\n): StaticTableFeature;\nexport function groupingPanel<TRow>(\n initialGroupBy?: string | readonly string[],\n extras?: GroupingExtras<TRow>\n): TableFeature<TRow>;\nexport function groupingPanel<TRow>(\n initialGroupBy?: string | readonly string[],\n extras: GroupingExtras<TRow> = {}\n): TableFeature<TRow> {\n const ordinary = grouping<TRow>([], extras);\n return extendFeature(bindingGroupingPanel<TRow>(initialGroupBy, extras), [\n ...(ordinary.renders ?? []),\n slotRender(groupingPanelControlKey<TRow>(), (props) =>\n h(NaiveGroupingPanel<TRow>, { ...props })\n ),\n ]);\n}\n"],"mappings":"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"}
@@ -1,147 +1,4 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_button = require("./button-CaakTzYM.cjs");
3
- const require_select = require("./select-C8UKnsWO.cjs");
4
- const require_grouping = require("./grouping.cjs");
5
- require("@adapttable/vue");
6
- let _adapttable_vue_adapter = require("@adapttable/vue/adapter");
7
- let _adapttable_vue_features = require("@adapttable/vue/features");
8
- let vue = require("vue");
9
- let naive_ui = require("naive-ui");
10
- //#region src/grouping/naiveGroupingControls.ts
11
- function aggregationOption(option, disabled, onToggle) {
12
- return (0, vue.h)(naive_ui.NCheckbox, {
13
- key: option.value,
14
- checked: option.checked,
15
- disabled,
16
- "data-adapttable-part": "grouping-aggregation-option",
17
- "onUpdate:checked": (checked) => onToggle(option.value, checked)
18
- }, { default: () => option.label });
19
- }
20
- function naiveGroupingControls(names) {
21
- return {
22
- Surface: ({ children, label, mobile, ...attrs }) => (0, vue.h)(naive_ui.NCard, {
23
- ...(0, _adapttable_vue_adapter.toVueAttrs)(attrs),
24
- size: "small",
25
- class: ["adapttable-naive-ui-grouping-layout", names.value.groupingPanel],
26
- role: "group",
27
- "aria-label": label,
28
- "data-mobile": mobile ? "" : void 0
29
- }, { default: () => [(0, vue.h)("span", { class: "adapttable-naive-ui-grouping-layout-label" }, label), children] }),
30
- DropZone: ({ label, empty, active, dragging, dropProps, ...attrs }) => (0, vue.h)(naive_ui.NTag, {
31
- ...attrs,
32
- ...(0, _adapttable_vue_adapter.toVueAttrs)({ ...dropProps }),
33
- class: names.value.groupingDropZone,
34
- "aria-label": label,
35
- "data-empty": empty ? "" : void 0,
36
- "data-active": active ? "" : void 0,
37
- "data-dragging": dragging ? "" : void 0
38
- }, { default: () => empty ? label : "" }),
39
- Chip: ({ label, level, dragProps, keyboardProps, onRemove, removeLabel, ...attrs }) => (0, vue.h)(naive_ui.NFlex, {
40
- ...attrs,
41
- inline: true,
42
- align: "center",
43
- size: 4,
44
- class: names.value.groupingChip,
45
- "data-level": level
46
- }, { default: () => [require_button.naiveButton({
47
- ...(0, _adapttable_vue_adapter.toVueAttrs)({ ...dragProps }),
48
- ...(0, _adapttable_vue_adapter.toVueAttrs)({ ...keyboardProps }),
49
- class: names.value.groupingChipHandle,
50
- "data-adapttable-part": "grouping-chip-handle"
51
- }, `${level}. ${label}`), require_button.naiveButton({
52
- class: names.value.groupingChipRemove,
53
- "aria-label": removeLabel,
54
- "data-adapttable-part": "grouping-chip-remove",
55
- onClick: onRemove
56
- }, "×")] }),
57
- Select: ({ label, value, options, onChange, disabled, ...attrs }) => require_select.naiveSelect({
58
- value,
59
- options: value === "" ? [{
60
- value: "",
61
- label,
62
- disabled: true
63
- }, ...options] : options,
64
- onChange,
65
- attrs: {
66
- ...attrs,
67
- class: attrs["data-adapttable-part"] === "grouping-add" ? names.value.groupingAdd : names.value.groupingAggregationOperation,
68
- disabled,
69
- "aria-label": label,
70
- placeholder: label
71
- }
72
- }),
73
- RemoveZone: ({ label, active, dropProps, ...attrs }) => (0, vue.h)(naive_ui.NTag, {
74
- ...attrs,
75
- ...(0, _adapttable_vue_adapter.toVueAttrs)({ ...dropProps }),
76
- class: names.value.groupingRemoveZone,
77
- "aria-label": label,
78
- "data-active": active ? "" : void 0
79
- }, { default: () => label }),
80
- AggregationItem: ({ label, readOnly, readOnlyLabel, children, ...attrs }) => (0, vue.h)(naive_ui.NFlex, {
81
- ...attrs,
82
- inline: true,
83
- align: "center",
84
- class: names.value.groupingAggregationItem,
85
- "data-read-only": readOnly ? "" : void 0
86
- }, { default: () => [
87
- (0, vue.h)(naive_ui.NText, null, { default: () => label }),
88
- readOnly ? (0, vue.h)(naive_ui.NTag, null, { default: () => readOnlyLabel }) : null,
89
- children
90
- ] }),
91
- AggregationRemove: ({ label, onRemove, ...attrs }) => require_button.naiveButton({
92
- ...attrs,
93
- class: names.value.groupingAggregationRemove,
94
- "aria-label": label,
95
- onClick: onRemove
96
- }, "×"),
97
- AggregationPicker: ({ label, options, onToggle, disabled, ...attrs }) => (0, vue.h)(naive_ui.NFlex, {
98
- ...attrs,
99
- role: "group",
100
- "aria-label": label,
101
- class: names.value.groupingAggregationAdd
102
- }, { default: () => options.map((option) => aggregationOption(option, disabled, onToggle)) }),
103
- AggregationRestore: ({ label, disabled, onRestore, ...attrs }) => require_button.naiveButton({
104
- ...attrs,
105
- class: names.value.groupingAggregationsRestore,
106
- disabled,
107
- onClick: onRestore
108
- }, label)
109
- };
110
- }
111
- //#endregion
112
- //#region src/grouping/NaiveGroupingPanel.vue
113
- const _sfc_main = /*@__PURE__*/ (0, vue.defineComponent)({
114
- name: "NaiveGroupingPanel",
115
- __name: "NaiveGroupingPanel",
116
- props: {
117
- state: {},
118
- columns: {},
119
- labels: {},
120
- mobile: { type: Boolean },
121
- dir: {}
122
- },
123
- setup(__props) {
124
- const props = __props;
125
- const names = (0, _adapttable_vue_adapter.useDataTableClassNames)();
126
- const controls = naiveGroupingControls(names);
127
- const Render = () => (0, _adapttable_vue_adapter.GroupingPanelChrome)({
128
- ...props,
129
- classNames: names.value,
130
- slots: controls
131
- });
132
- Render.props = [];
133
- return (_ctx, _cache) => {
134
- return (0, vue.openBlock)(), (0, vue.createBlock)(Render);
135
- };
136
- }
137
- });
138
- //#endregion
139
- //#region src/grouping-panel.ts
140
- function groupingPanel(initialGroupBy, extras = {}) {
141
- const ordinary = require_grouping.grouping([], extras);
142
- return (0, _adapttable_vue_adapter.extendFeature)((0, _adapttable_vue_features.groupingPanel)(initialGroupBy, extras), [...ordinary.renders ?? [], (0, _adapttable_vue_adapter.slotRender)((0, _adapttable_vue_adapter.groupingPanelControlKey)(), (props) => (0, vue.h)(_sfc_main, { ...props }))]);
143
- }
144
- //#endregion
145
- exports.groupingPanel = groupingPanel;
146
-
147
- //# sourceMappingURL=grouping-panel.cjs.map
2
+ require("./grouping.cjs");
3
+ const require_grouping_panel = require("./grouping-panel-BPaPG49S.cjs");
4
+ exports.groupingPanel = require_grouping_panel.groupingPanel;
@@ -1,146 +1,3 @@
1
- import { t as naiveButton } from "./button-BxXdDW7A.js";
2
- import { t as naiveSelect } from "./select-Bgc5ttop.js";
3
- import { grouping as grouping$1 } from "./grouping.js";
4
- import "@adapttable/vue";
5
- import { GroupingPanelChrome, extendFeature, groupingPanelControlKey, slotRender, toVueAttrs, useDataTableClassNames } from "@adapttable/vue/adapter";
6
- import { groupingPanel as groupingPanel$1 } from "@adapttable/vue/features";
7
- import { createBlock, defineComponent, h, openBlock } from "vue";
8
- import { NCard, NCheckbox, NFlex, NTag, NText } from "naive-ui";
9
- //#region src/grouping/naiveGroupingControls.ts
10
- function aggregationOption(option, disabled, onToggle) {
11
- return h(NCheckbox, {
12
- key: option.value,
13
- checked: option.checked,
14
- disabled,
15
- "data-adapttable-part": "grouping-aggregation-option",
16
- "onUpdate:checked": (checked) => onToggle(option.value, checked)
17
- }, { default: () => option.label });
18
- }
19
- function naiveGroupingControls(names) {
20
- return {
21
- Surface: ({ children, label, mobile, ...attrs }) => h(NCard, {
22
- ...toVueAttrs(attrs),
23
- size: "small",
24
- class: ["adapttable-naive-ui-grouping-layout", names.value.groupingPanel],
25
- role: "group",
26
- "aria-label": label,
27
- "data-mobile": mobile ? "" : void 0
28
- }, { default: () => [h("span", { class: "adapttable-naive-ui-grouping-layout-label" }, label), children] }),
29
- DropZone: ({ label, empty, active, dragging, dropProps, ...attrs }) => h(NTag, {
30
- ...attrs,
31
- ...toVueAttrs({ ...dropProps }),
32
- class: names.value.groupingDropZone,
33
- "aria-label": label,
34
- "data-empty": empty ? "" : void 0,
35
- "data-active": active ? "" : void 0,
36
- "data-dragging": dragging ? "" : void 0
37
- }, { default: () => empty ? label : "" }),
38
- Chip: ({ label, level, dragProps, keyboardProps, onRemove, removeLabel, ...attrs }) => h(NFlex, {
39
- ...attrs,
40
- inline: true,
41
- align: "center",
42
- size: 4,
43
- class: names.value.groupingChip,
44
- "data-level": level
45
- }, { default: () => [naiveButton({
46
- ...toVueAttrs({ ...dragProps }),
47
- ...toVueAttrs({ ...keyboardProps }),
48
- class: names.value.groupingChipHandle,
49
- "data-adapttable-part": "grouping-chip-handle"
50
- }, `${level}. ${label}`), naiveButton({
51
- class: names.value.groupingChipRemove,
52
- "aria-label": removeLabel,
53
- "data-adapttable-part": "grouping-chip-remove",
54
- onClick: onRemove
55
- }, "×")] }),
56
- Select: ({ label, value, options, onChange, disabled, ...attrs }) => naiveSelect({
57
- value,
58
- options: value === "" ? [{
59
- value: "",
60
- label,
61
- disabled: true
62
- }, ...options] : options,
63
- onChange,
64
- attrs: {
65
- ...attrs,
66
- class: attrs["data-adapttable-part"] === "grouping-add" ? names.value.groupingAdd : names.value.groupingAggregationOperation,
67
- disabled,
68
- "aria-label": label,
69
- placeholder: label
70
- }
71
- }),
72
- RemoveZone: ({ label, active, dropProps, ...attrs }) => h(NTag, {
73
- ...attrs,
74
- ...toVueAttrs({ ...dropProps }),
75
- class: names.value.groupingRemoveZone,
76
- "aria-label": label,
77
- "data-active": active ? "" : void 0
78
- }, { default: () => label }),
79
- AggregationItem: ({ label, readOnly, readOnlyLabel, children, ...attrs }) => h(NFlex, {
80
- ...attrs,
81
- inline: true,
82
- align: "center",
83
- class: names.value.groupingAggregationItem,
84
- "data-read-only": readOnly ? "" : void 0
85
- }, { default: () => [
86
- h(NText, null, { default: () => label }),
87
- readOnly ? h(NTag, null, { default: () => readOnlyLabel }) : null,
88
- children
89
- ] }),
90
- AggregationRemove: ({ label, onRemove, ...attrs }) => naiveButton({
91
- ...attrs,
92
- class: names.value.groupingAggregationRemove,
93
- "aria-label": label,
94
- onClick: onRemove
95
- }, "×"),
96
- AggregationPicker: ({ label, options, onToggle, disabled, ...attrs }) => h(NFlex, {
97
- ...attrs,
98
- role: "group",
99
- "aria-label": label,
100
- class: names.value.groupingAggregationAdd
101
- }, { default: () => options.map((option) => aggregationOption(option, disabled, onToggle)) }),
102
- AggregationRestore: ({ label, disabled, onRestore, ...attrs }) => naiveButton({
103
- ...attrs,
104
- class: names.value.groupingAggregationsRestore,
105
- disabled,
106
- onClick: onRestore
107
- }, label)
108
- };
109
- }
110
- //#endregion
111
- //#region src/grouping/NaiveGroupingPanel.vue
112
- const _sfc_main = /*@__PURE__*/ defineComponent({
113
- name: "NaiveGroupingPanel",
114
- __name: "NaiveGroupingPanel",
115
- props: {
116
- state: {},
117
- columns: {},
118
- labels: {},
119
- mobile: { type: Boolean },
120
- dir: {}
121
- },
122
- setup(__props) {
123
- const props = __props;
124
- const names = useDataTableClassNames();
125
- const controls = naiveGroupingControls(names);
126
- const Render = () => GroupingPanelChrome({
127
- ...props,
128
- classNames: names.value,
129
- slots: controls
130
- });
131
- Render.props = [];
132
- return (_ctx, _cache) => {
133
- return openBlock(), createBlock(Render);
134
- };
135
- }
136
- });
137
- //#endregion
138
- //#region src/grouping-panel.ts
139
- function groupingPanel(initialGroupBy, extras = {}) {
140
- const ordinary = grouping$1([], extras);
141
- return extendFeature(groupingPanel$1(initialGroupBy, extras), [...ordinary.renders ?? [], slotRender(groupingPanelControlKey(), (props) => h(_sfc_main, { ...props }))]);
142
- }
143
- //#endregion
1
+ import "./grouping.js";
2
+ import { t as groupingPanel } from "./grouping-panel-CYUPSa0u.js";
144
3
  export { groupingPanel };
145
-
146
- //# sourceMappingURL=grouping-panel.js.map
@@ -0,0 +1,52 @@
1
+ import { StaticTableFeature } from "@adapttable/vue";
2
+ import { FilterHeaderControlOptions, FilterHeaderControlOptions as FilterHeaderControlOptions$1, FilterHeaderControlProps, FilterHeaderRowProps, FilterHeaderRowProps as FilterHeaderRowProps$1, HeaderFilterOptions } from "@adapttable/vue/adapter";
3
+ //#region src/filters/NaiveFilterHeaderControl.vue.d.ts
4
+ declare const __VLS_export$2: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal$2<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
5
+ props: import("vue").PublicProps & __VLS_PrettifyLocal$2<FilterHeaderControlOptions<TRow>> & (typeof globalThis extends {
6
+ __VLS_PROPS_FALLBACK: infer P;
7
+ } ? P : {});
8
+ expose: (exposed: {}) => void;
9
+ attrs: any;
10
+ slots: {};
11
+ emit: {};
12
+ }>) => import("vue").VNode & {
13
+ __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
14
+ };
15
+ declare const _default$2: typeof __VLS_export$2;
16
+ type __VLS_PrettifyLocal$2<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
17
+ //#endregion
18
+ //#region src/filters/NaiveFilterHeaderRow.vue.d.ts
19
+ declare const __VLS_export$1: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal$1<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
20
+ props: import("vue").PublicProps & __VLS_PrettifyLocal$1<FilterHeaderRowProps<TRow>> & (typeof globalThis extends {
21
+ __VLS_PROPS_FALLBACK: infer P;
22
+ } ? P : {});
23
+ expose: (exposed: {}) => void;
24
+ attrs: any;
25
+ slots: {};
26
+ emit: {};
27
+ }>) => import("vue").VNode & {
28
+ __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
29
+ };
30
+ declare const _default$1: typeof __VLS_export$1;
31
+ type __VLS_PrettifyLocal$1<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
32
+ //#endregion
33
+ //#region src/filters/NaiveHeaderFilter.vue.d.ts
34
+ declare const __VLS_export: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
35
+ props: import("vue").PublicProps & __VLS_PrettifyLocal<HeaderFilterOptions<TRow>> & (typeof globalThis extends {
36
+ __VLS_PROPS_FALLBACK: infer P;
37
+ } ? P : {});
38
+ expose: (exposed: {}) => void;
39
+ attrs: any;
40
+ slots: {};
41
+ emit: {};
42
+ }>) => import("vue").VNode & {
43
+ __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
44
+ };
45
+ declare const _default: typeof __VLS_export;
46
+ type __VLS_PrettifyLocal<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
47
+ //#endregion
48
+ //#region src/header-filters.d.ts
49
+ declare function headerFilters(): StaticTableFeature;
50
+ //#endregion
51
+ export { _default as a, headerFilters as i, FilterHeaderControlProps as n, _default$1 as o, FilterHeaderRowProps$1 as r, _default$2 as s, FilterHeaderControlOptions$1 as t };
52
+ //# sourceMappingURL=header-filters-CQg6clum.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"header-filters-CQg6clum.d.cts","names":[],"sources":["../src/filters/NaiveFilterHeaderControl.vue","../src/filters/NaiveFilterHeaderRow.vue","../src/filters/NaiveHeaderFilter.vue","../src/header-filters.ts"],"mappings":";;;cAgEM,iBAAiB,MACtB,aAAa,YAAY,eAAe,wBACxC,YAAY,sBAAoB,KAAK,YAAY,eAAe,6CAChE,gBAAgB,YAAY,eAAe,yBAC3C,cAAA;EAiEO,qBAAc,cAAc,sBAAmB,2BAAA,iBAA8B;IAAqB,4BAA4B;MAAM;EACnI,SAAC;EACF;EACA;EACD;qBAGmB;EAAU,QAAQ,YAAY,eAAe;;cAClD,mBAAO;KACvB,sBAAoB,MAAM,mBAAmB,WAAW,IAAI,EAAE,WAAW,WAAW,KAAK,IAAI,EAAE;;;cCxG9F,iBAAiB,MACtB,aAAa,YAAY,eAAe,wBACxC,YAAY,sBAAoB,KAAK,YAAY,eAAe,6CAChE,gBAAgB,YAAY,eAAe,yBAC3C,cAAA;EAkDO,qBAAc,cAAc,sBAAmB,qBAAA,iBAA8B;IAAqB,4BAA4B;MAAM;EACnI,SAAC;EACF;EACA;EACD;qBAGmB;EAAU,QAAQ,YAAY,eAAe;;cAClD,mBAAO;KACvB,sBAAoB,MAAM,mBAAmB,WAAW,IAAI,EAAE,WAAW,WAAW,KAAK,IAAI,EAAE;;;cClC9F,eAAiB,MACtB,aAAa,YAAY,eAAe,wBACxC,YAAY,oBAAoB,KAAK,YAAY,eAAe,6CAChE,gBAAgB,YAAY,eAAe,yBAC3C,cAAA;EAgEO,qBAAc,cAAc,oBAAmB,oBAAA,iBAA8B;IAAqB,4BAA4B;MAAM;EACnI,SAAC;EACF;EACA;EACD;qBAGmB;EAAU,QAAQ,YAAY,eAAe;;cAClD,iBAAO;KACvB,oBAAoB,MAAM,mBAAmB,WAAW,IAAI,EAAE,WAAW,WAAW,KAAK,IAAI,EAAE;;;iBCrIpF,iBAAiB"}
@@ -0,0 +1,52 @@
1
+ import { StaticTableFeature } from "@adapttable/vue";
2
+ import { FilterHeaderControlOptions, FilterHeaderControlOptions as FilterHeaderControlOptions$1, FilterHeaderControlProps, FilterHeaderRowProps, FilterHeaderRowProps as FilterHeaderRowProps$1, HeaderFilterOptions } from "@adapttable/vue/adapter";
3
+ //#region src/filters/NaiveFilterHeaderControl.vue.d.ts
4
+ declare const __VLS_export$2: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal$2<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
5
+ props: import("vue").PublicProps & __VLS_PrettifyLocal$2<FilterHeaderControlOptions<TRow>> & (typeof globalThis extends {
6
+ __VLS_PROPS_FALLBACK: infer P;
7
+ } ? P : {});
8
+ expose: (exposed: {}) => void;
9
+ attrs: any;
10
+ slots: {};
11
+ emit: {};
12
+ }>) => import("vue").VNode & {
13
+ __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
14
+ };
15
+ declare const _default$2: typeof __VLS_export$2;
16
+ type __VLS_PrettifyLocal$2<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
17
+ //#endregion
18
+ //#region src/filters/NaiveFilterHeaderRow.vue.d.ts
19
+ declare const __VLS_export$1: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal$1<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
20
+ props: import("vue").PublicProps & __VLS_PrettifyLocal$1<FilterHeaderRowProps<TRow>> & (typeof globalThis extends {
21
+ __VLS_PROPS_FALLBACK: infer P;
22
+ } ? P : {});
23
+ expose: (exposed: {}) => void;
24
+ attrs: any;
25
+ slots: {};
26
+ emit: {};
27
+ }>) => import("vue").VNode & {
28
+ __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
29
+ };
30
+ declare const _default$1: typeof __VLS_export$1;
31
+ type __VLS_PrettifyLocal$1<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
32
+ //#endregion
33
+ //#region src/filters/NaiveHeaderFilter.vue.d.ts
34
+ declare const __VLS_export: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
35
+ props: import("vue").PublicProps & __VLS_PrettifyLocal<HeaderFilterOptions<TRow>> & (typeof globalThis extends {
36
+ __VLS_PROPS_FALLBACK: infer P;
37
+ } ? P : {});
38
+ expose: (exposed: {}) => void;
39
+ attrs: any;
40
+ slots: {};
41
+ emit: {};
42
+ }>) => import("vue").VNode & {
43
+ __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
44
+ };
45
+ declare const _default: typeof __VLS_export;
46
+ type __VLS_PrettifyLocal<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
47
+ //#endregion
48
+ //#region src/header-filters.d.ts
49
+ declare function headerFilters(): StaticTableFeature;
50
+ //#endregion
51
+ export { _default as a, headerFilters as i, FilterHeaderControlProps as n, _default$1 as o, FilterHeaderRowProps$1 as r, _default$2 as s, FilterHeaderControlOptions$1 as t };
52
+ //# sourceMappingURL=header-filters-CQg6clum.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"header-filters-CQg6clum.d.ts","names":[],"sources":["../src/filters/NaiveFilterHeaderControl.vue","../src/filters/NaiveFilterHeaderRow.vue","../src/filters/NaiveHeaderFilter.vue","../src/header-filters.ts"],"mappings":";;;cAgEM,iBAAiB,MACtB,aAAa,YAAY,eAAe,wBACxC,YAAY,sBAAoB,KAAK,YAAY,eAAe,6CAChE,gBAAgB,YAAY,eAAe,yBAC3C,cAAA;EAiEO,qBAAc,cAAc,sBAAmB,2BAAA,iBAA8B;IAAqB,4BAA4B;MAAM;EACnI,SAAC;EACF;EACA;EACD;qBAGmB;EAAU,QAAQ,YAAY,eAAe;;cAClD,mBAAO;KACvB,sBAAoB,MAAM,mBAAmB,WAAW,IAAI,EAAE,WAAW,WAAW,KAAK,IAAI,EAAE;;;cCxG9F,iBAAiB,MACtB,aAAa,YAAY,eAAe,wBACxC,YAAY,sBAAoB,KAAK,YAAY,eAAe,6CAChE,gBAAgB,YAAY,eAAe,yBAC3C,cAAA;EAkDO,qBAAc,cAAc,sBAAmB,qBAAA,iBAA8B;IAAqB,4BAA4B;MAAM;EACnI,SAAC;EACF;EACA;EACD;qBAGmB;EAAU,QAAQ,YAAY,eAAe;;cAClD,mBAAO;KACvB,sBAAoB,MAAM,mBAAmB,WAAW,IAAI,EAAE,WAAW,WAAW,KAAK,IAAI,EAAE;;;cClC9F,eAAiB,MACtB,aAAa,YAAY,eAAe,wBACxC,YAAY,oBAAoB,KAAK,YAAY,eAAe,6CAChE,gBAAgB,YAAY,eAAe,yBAC3C,cAAA;EAgEO,qBAAc,cAAc,oBAAmB,oBAAA,iBAA8B;IAAqB,4BAA4B;MAAM;EACnI,SAAC;EACF;EACA;EACD;qBAGmB;EAAU,QAAQ,YAAY,eAAe;;cAClD,iBAAO;KACvB,oBAAoB,MAAM,mBAAmB,WAAW,IAAI,EAAE,WAAW,WAAW,KAAK,IAAI,EAAE;;;iBCrIpF,iBAAiB"}
@@ -1,52 +1,2 @@
1
- import { StaticTableFeature } from "@adapttable/vue";
2
- import { FilterHeaderControlOptions, FilterHeaderControlOptions as FilterHeaderControlOptions$1, FilterHeaderControlProps, FilterHeaderRowProps, FilterHeaderRowProps as FilterHeaderRowProps$1, HeaderFilterOptions } from "@adapttable/vue/adapter";
3
- //#region src/filters/NaiveFilterHeaderControl.vue.d.ts
4
- declare const __VLS_export$2: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal$2<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
5
- props: import("vue").PublicProps & __VLS_PrettifyLocal$2<FilterHeaderControlOptions$1<TRow>> & (typeof globalThis extends {
6
- __VLS_PROPS_FALLBACK: infer P;
7
- } ? P : {});
8
- expose: (exposed: {}) => void;
9
- attrs: any;
10
- slots: {};
11
- emit: {};
12
- }>) => import("vue").VNode & {
13
- __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
14
- };
15
- declare const _default: typeof __VLS_export$2;
16
- type __VLS_PrettifyLocal$2<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
17
- //#endregion
18
- //#region src/filters/NaiveFilterHeaderRow.vue.d.ts
19
- declare const __VLS_export$1: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal$1<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
20
- props: import("vue").PublicProps & __VLS_PrettifyLocal$1<FilterHeaderRowProps$1<TRow>> & (typeof globalThis extends {
21
- __VLS_PROPS_FALLBACK: infer P;
22
- } ? P : {});
23
- expose: (exposed: {}) => void;
24
- attrs: any;
25
- slots: {};
26
- emit: {};
27
- }>) => import("vue").VNode & {
28
- __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
29
- };
30
- declare const _default$1: typeof __VLS_export$1;
31
- type __VLS_PrettifyLocal$1<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
32
- //#endregion
33
- //#region src/filters/NaiveHeaderFilter.vue.d.ts
34
- declare const __VLS_export: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
35
- props: import("vue").PublicProps & __VLS_PrettifyLocal<HeaderFilterOptions<TRow>> & (typeof globalThis extends {
36
- __VLS_PROPS_FALLBACK: infer P;
37
- } ? P : {});
38
- expose: (exposed: {}) => void;
39
- attrs: any;
40
- slots: {};
41
- emit: {};
42
- }>) => import("vue").VNode & {
43
- __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
44
- };
45
- declare const _default$2: typeof __VLS_export;
46
- type __VLS_PrettifyLocal<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
47
- //#endregion
48
- //#region src/header-filters.d.ts
49
- declare function headerFilters(): StaticTableFeature;
50
- //#endregion
51
- export { _default as FilterHeaderControl, type FilterHeaderControlOptions, type FilterHeaderControlProps, _default$1 as FilterHeaderRow, type FilterHeaderRowProps, _default$2 as NaiveHeaderFilter, headerFilters };
52
- //# sourceMappingURL=header-filters.d.cts.map
1
+ import { a as _default$2, i as headerFilters, n as FilterHeaderControlProps, o as _default$1, r as FilterHeaderRowProps, s as _default, t as FilterHeaderControlOptions } from "./header-filters-CQg6clum.cjs";
2
+ export { _default as FilterHeaderControl, type FilterHeaderControlOptions, type FilterHeaderControlProps, _default$1 as FilterHeaderRow, type FilterHeaderRowProps, _default$2 as NaiveHeaderFilter, headerFilters };
@@ -1,52 +1,2 @@
1
- import { StaticTableFeature } from "@adapttable/vue";
2
- import { FilterHeaderControlOptions, FilterHeaderControlOptions as FilterHeaderControlOptions$1, FilterHeaderControlProps, FilterHeaderRowProps, FilterHeaderRowProps as FilterHeaderRowProps$1, HeaderFilterOptions } from "@adapttable/vue/adapter";
3
- //#region src/filters/NaiveFilterHeaderControl.vue.d.ts
4
- declare const __VLS_export$2: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal$2<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
5
- props: import("vue").PublicProps & __VLS_PrettifyLocal$2<FilterHeaderControlOptions$1<TRow>> & (typeof globalThis extends {
6
- __VLS_PROPS_FALLBACK: infer P;
7
- } ? P : {});
8
- expose: (exposed: {}) => void;
9
- attrs: any;
10
- slots: {};
11
- emit: {};
12
- }>) => import("vue").VNode & {
13
- __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
14
- };
15
- declare const _default: typeof __VLS_export$2;
16
- type __VLS_PrettifyLocal$2<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
17
- //#endregion
18
- //#region src/filters/NaiveFilterHeaderRow.vue.d.ts
19
- declare const __VLS_export$1: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal$1<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
20
- props: import("vue").PublicProps & __VLS_PrettifyLocal$1<FilterHeaderRowProps$1<TRow>> & (typeof globalThis extends {
21
- __VLS_PROPS_FALLBACK: infer P;
22
- } ? P : {});
23
- expose: (exposed: {}) => void;
24
- attrs: any;
25
- slots: {};
26
- emit: {};
27
- }>) => import("vue").VNode & {
28
- __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
29
- };
30
- declare const _default$1: typeof __VLS_export$1;
31
- type __VLS_PrettifyLocal$1<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
32
- //#endregion
33
- //#region src/filters/NaiveHeaderFilter.vue.d.ts
34
- declare const __VLS_export: <TRow>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
35
- props: import("vue").PublicProps & __VLS_PrettifyLocal<HeaderFilterOptions<TRow>> & (typeof globalThis extends {
36
- __VLS_PROPS_FALLBACK: infer P;
37
- } ? P : {});
38
- expose: (exposed: {}) => void;
39
- attrs: any;
40
- slots: {};
41
- emit: {};
42
- }>) => import("vue").VNode & {
43
- __ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
44
- };
45
- declare const _default$2: typeof __VLS_export;
46
- type __VLS_PrettifyLocal<T> = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};
47
- //#endregion
48
- //#region src/header-filters.d.ts
49
- declare function headerFilters(): StaticTableFeature;
50
- //#endregion
51
- export { _default as FilterHeaderControl, type FilterHeaderControlOptions, type FilterHeaderControlProps, _default$1 as FilterHeaderRow, type FilterHeaderRowProps, _default$2 as NaiveHeaderFilter, headerFilters };
52
- //# sourceMappingURL=header-filters.d.ts.map
1
+ import { a as _default$2, i as headerFilters, n as FilterHeaderControlProps, o as _default$1, r as FilterHeaderRowProps, s as _default, t as FilterHeaderControlOptions } from "./header-filters-CQg6clum.js";
2
+ export { _default as FilterHeaderControl, type FilterHeaderControlOptions, type FilterHeaderControlProps, _default$1 as FilterHeaderRow, type FilterHeaderRowProps, _default$2 as NaiveHeaderFilter, headerFilters };
package/dist/index.cjs CHANGED
@@ -2,7 +2,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_button = require("./button-CaakTzYM.cjs");
3
3
  const require_input = require("./input-DPQy4L2b.cjs");
4
4
  const require_classNames = require("./classNames-CR71pIAv.cjs");
5
- const require_mobile = require("./mobile-Bc3-31-b.cjs");
5
+ const require_mobile = require("./mobile-C2JUs6b_.cjs");
6
6
  const require_rowActionsSlot = require("./rowActionsSlot-B48S_yZD.cjs");
7
7
  const require_select = require("./select-C8UKnsWO.cjs");
8
8
  let _adapttable_vue_adapter = require("@adapttable/vue/adapter");
package/dist/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { n as naiveElement, t as naiveButton } from "./button-BxXdDW7A.js";
2
2
  import { t as naiveInput } from "./input-DZI_oY9v.js";
3
3
  import { t as naiveClassNames } from "./classNames-2CRJjDRZ.js";
4
- import { n as NaiveDesktopTable, r as naiveTableControls, t as NaiveMobileCards } from "./mobile-Dlwq8dB7.js";
4
+ import { n as NaiveDesktopTable, r as naiveTableControls, t as NaiveMobileCards } from "./mobile-CC3NeIRK.js";
5
5
  import { n as rowActionsControlKey, t as ROW_ACTIONS_CONTROL } from "./rowActionsSlot-YWkCOo5W.js";
6
6
  import { t as naiveSelect } from "./select-Bgc5ttop.js";
7
7
  import { DataTableSurfaceChrome, GROUP_ROW, defaultConfirm, groupRowSlotKey, provideDataTableClassNames, renderFeatureSlot, useDataTableShell } from "@adapttable/vue/adapter";
@@ -174,7 +174,8 @@ function NaiveDesktopTable(props) {
174
174
  colspan: item.colSpan,
175
175
  rowspan: item.rowSpan,
176
176
  class: names.columnGroup,
177
- "data-adapttable-part": "header-group-cell"
177
+ "data-adapttable-part": "header-group-cell",
178
+ style: { textAlign: (0, _adapttable_vue_adapter.groupedHeaderAlign)(item.cell.align) }
178
179
  }, () => [(0, _adapttable_vue_adapter.columnGroupHeaderCaption)(item.cell), toggle ? requireControl(controls.ColumnGroupToggle, "ColumnGroupToggle")({
179
180
  ...toggle,
180
181
  className: names.columnGroupToggle
@@ -433,4 +434,4 @@ Object.defineProperty(exports, "naiveTableControls", {
433
434
  }
434
435
  });
435
436
 
436
- //# sourceMappingURL=mobile-Bc3-31-b.cjs.map
437
+ //# sourceMappingURL=mobile-C2JUs6b_.cjs.map