@simple-table/vue 3.0.0-beta.15 → 3.0.0-beta.16

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/cjs/index.js CHANGED
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("vue"),r=require("simple-table-core");function n(e,r){var n={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&r.indexOf(t)<0&&(n[t]=e[t]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(t=Object.getOwnPropertySymbols(e);o<t.length;o++)r.indexOf(t[o])<0&&Object.prototype.propertyIsEnumerable.call(e,t[o])&&(n[t[o]]=e[t[o]])}return n}function t(r){return n=>{const t=document.createElement("div");return e.render(e.h(r,n),t),t}}function o(r){const n=document.createElement("div");return e.render(r,n),n}function d(r){const n=document.createElement("div");e.render(r,n);const t=n.innerHTML;return e.render(null,n),t}function l(e){return"object"==typeof e||"function"==typeof e}function i(e){const{cellRenderer:r,headerRenderer:o,children:d,nestedTable:l}=e,c=n(e,["cellRenderer","headerRenderer","children","nestedTable"]),s=Object.assign({},c);if(r&&(s.cellRenderer="object"==typeof r?t(r):r),o&&(s.headerRenderer="object"==typeof o?t(o):o),d&&(s.children=d.map(i)),l){const e=Object.assign(Object.assign({},l),{rows:[]});s.nestedTable=a(e)}return s}function a(e){const{defaultHeaders:r,footerRenderer:a,emptyStateRenderer:c,errorStateRenderer:s,loadingStateRenderer:u,tableEmptyStateRenderer:f,headerDropdown:p,columnEditorConfig:m,icons:b}=e,R=n(e,["defaultHeaders","footerRenderer","emptyStateRenderer","errorStateRenderer","loadingStateRenderer","tableEmptyStateRenderer","headerDropdown","columnEditorConfig","icons"]),y=Object.assign(Object.assign({},R),{defaultHeaders:r.map(i)});if(void 0!==a&&(y.footerRenderer="object"==typeof a?t(a):a),void 0!==c)if(l(c))y.emptyStateRenderer=t(c);else{const e=c;y.emptyStateRenderer=()=>o(e)}if(void 0!==s)if(l(s))y.errorStateRenderer=t(s);else{const e=s;y.errorStateRenderer=()=>o(e)}if(void 0!==u)if(l(u))y.loadingStateRenderer=t(u);else{const e=u;y.loadingStateRenderer=()=>o(e)}return void 0!==f&&(y.tableEmptyStateRenderer=null===f?null:f instanceof HTMLElement||"string"==typeof f?f:o(f)),void 0!==p&&(y.headerDropdown=t(p)),void 0!==m&&(y.columnEditorConfig=function(e){const{rowRenderer:r}=e,o=n(e,["rowRenderer"]);return Object.assign(Object.assign({},o),r?{rowRenderer:t(r)}:{})}(m)),void 0!==b&&(y.icons=function(e){const r={};for(const[n,t]of Object.entries(e))null!=t&&(r[n]="string"==typeof t||t instanceof HTMLElement||t instanceof SVGElement?t:d(t));return r}(b)),y}function c(r){const n={};for(const t in r)n[e.camelize(t)]=""===r[t]||r[t];return n}"function"==typeof SuppressedError&&SuppressedError;const s=e.defineComponent({name:"SimpleTable",props:{},inheritAttrs:!1,setup(n,{attrs:t,expose:o}){const d=e.ref(null);let l=null;return e.onMounted(()=>{d.value&&(l=new r.SimpleTableVanilla(d.value,a(c(t))),l.mount())}),e.onUpdated(()=>{null==l||l.update(a(c(t)))}),e.onUnmounted(()=>{null==l||l.destroy(),l=null}),o({getAPI:()=>{var e;return null!==(e=null==l?void 0:l.getAPI())&&void 0!==e?e:null}}),()=>e.h("div",{ref:d})}});exports.SimpleTable=s;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("vue"),r=require("simple-table-core");function n(e,r){var n={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&r.indexOf(t)<0&&(n[t]=e[t]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(t=Object.getOwnPropertySymbols(e);o<t.length;o++)r.indexOf(t[o])<0&&Object.prototype.propertyIsEnumerable.call(e,t[o])&&(n[t[o]]=e[t[o]])}return n}function t(r){return n=>{const t=document.createElement("div");return e.render(e.h(r,n),t),t}}function o(r){const n=document.createElement("div");return e.render(r,n),n}function d(r){const n=document.createElement("div");e.render(r,n);const t=n.innerHTML;return e.render(null,n),t}function l(e){return"object"==typeof e||"function"==typeof e}function i(e){const{cellRenderer:r,headerRenderer:o,children:d,nestedTable:l}=e,a=n(e,["cellRenderer","headerRenderer","children","nestedTable"]),s=Object.assign({},a);if(r&&(s.cellRenderer="object"==typeof r?t(r):r),o&&(s.headerRenderer="object"==typeof o?t(o):o),d&&(s.children=d.map(i)),l){const e=Object.assign(Object.assign({},l),{rows:[]});s.nestedTable=c(e)}return s}function c(e){const{defaultHeaders:r,footerRenderer:c,emptyStateRenderer:a,errorStateRenderer:s,loadingStateRenderer:u,tableEmptyStateRenderer:f,headerDropdown:p,columnEditorConfig:m,icons:b}=e,R=n(e,["defaultHeaders","footerRenderer","emptyStateRenderer","errorStateRenderer","loadingStateRenderer","tableEmptyStateRenderer","headerDropdown","columnEditorConfig","icons"]),y=Object.assign(Object.assign({},R),{defaultHeaders:r.map(i)});if(void 0!==c&&(y.footerRenderer="object"==typeof c?t(c):c),void 0!==a)if(l(a))y.emptyStateRenderer=t(a);else{const e=a;y.emptyStateRenderer=()=>o(e)}if(void 0!==s)if(l(s))y.errorStateRenderer=t(s);else{const e=s;y.errorStateRenderer=()=>o(e)}if(void 0!==u)if(l(u))y.loadingStateRenderer=t(u);else{const e=u;y.loadingStateRenderer=()=>o(e)}return void 0!==f&&(y.tableEmptyStateRenderer=null===f?null:f instanceof HTMLElement||"string"==typeof f?f:o(f)),void 0!==p&&(y.headerDropdown=t(p)),void 0!==m&&(y.columnEditorConfig=function(e){const{rowRenderer:r,customRenderer:o}=e,d=n(e,["rowRenderer","customRenderer"]);return Object.assign(Object.assign(Object.assign({},d),r?{rowRenderer:t(r)}:{}),o?{customRenderer:t(o)}:{})}(m)),void 0!==b&&(y.icons=function(e){const r={};for(const[n,t]of Object.entries(e))null!=t&&(r[n]="string"==typeof t||t instanceof HTMLElement||t instanceof SVGElement?t:d(t));return r}(b)),y}function a(r){const n={};for(const t in r)n[e.camelize(t)]=""===r[t]||r[t];return n}"function"==typeof SuppressedError&&SuppressedError;const s=e.defineComponent({name:"SimpleTable",props:{},inheritAttrs:!1,setup(n,{attrs:t,expose:o}){const d=e.ref(null);let l=null;return e.onMounted(()=>{d.value&&(l=new r.SimpleTableVanilla(d.value,c(a(t))),l.mount())}),e.onUpdated(()=>{null==l||l.update(c(a(t)))}),e.onUnmounted(()=>{null==l||l.destroy(),l=null}),o({getAPI:()=>{var e;return null!==(e=null==l?void 0:l.getAPI())&&void 0!==e?e:null}}),()=>e.h("div",{ref:d})}});exports.SimpleTable=s;
2
2
  //# sourceMappingURL=index.js.map
package/dist/index.es.js CHANGED
@@ -1,2 +1,2 @@
1
- import{render as e,h as t,defineComponent as r,ref as n,onMounted as o,onUpdated as d,onUnmounted as i,camelize as l}from"vue";import{SimpleTableVanilla as c}from"simple-table-core";function a(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r}function s(r){return n=>{const o=document.createElement("div");return e(t(r,n),o),o}}function u(t){const r=document.createElement("div");return e(t,r),r}function f(t){const r=document.createElement("div");e(t,r);const n=r.innerHTML;return e(null,r),n}function p(e){return"object"==typeof e||"function"==typeof e}function m(e){const{cellRenderer:t,headerRenderer:r,children:n,nestedTable:o}=e,d=a(e,["cellRenderer","headerRenderer","children","nestedTable"]),i=Object.assign({},d);if(t&&(i.cellRenderer="object"==typeof t?s(t):t),r&&(i.headerRenderer="object"==typeof r?s(r):r),n&&(i.children=n.map(m)),o){const e=Object.assign(Object.assign({},o),{rows:[]});i.nestedTable=b(e)}return i}function b(e){const{defaultHeaders:t,footerRenderer:r,emptyStateRenderer:n,errorStateRenderer:o,loadingStateRenderer:d,tableEmptyStateRenderer:i,headerDropdown:l,columnEditorConfig:c,icons:b}=e,R=a(e,["defaultHeaders","footerRenderer","emptyStateRenderer","errorStateRenderer","loadingStateRenderer","tableEmptyStateRenderer","headerDropdown","columnEditorConfig","icons"]),y=Object.assign(Object.assign({},R),{defaultHeaders:t.map(m)});if(void 0!==r&&(y.footerRenderer="object"==typeof r?s(r):r),void 0!==n)if(p(n))y.emptyStateRenderer=s(n);else{const e=n;y.emptyStateRenderer=()=>u(e)}if(void 0!==o)if(p(o))y.errorStateRenderer=s(o);else{const e=o;y.errorStateRenderer=()=>u(e)}if(void 0!==d)if(p(d))y.loadingStateRenderer=s(d);else{const e=d;y.loadingStateRenderer=()=>u(e)}return void 0!==i&&(y.tableEmptyStateRenderer=null===i?null:i instanceof HTMLElement||"string"==typeof i?i:u(i)),void 0!==l&&(y.headerDropdown=s(l)),void 0!==c&&(y.columnEditorConfig=function(e){const{rowRenderer:t}=e,r=a(e,["rowRenderer"]);return Object.assign(Object.assign({},r),t?{rowRenderer:s(t)}:{})}(c)),void 0!==b&&(y.icons=function(e){const t={};for(const[r,n]of Object.entries(e))null!=n&&(t[r]="string"==typeof n||n instanceof HTMLElement||n instanceof SVGElement?n:f(n));return t}(b)),y}function R(e){const t={};for(const r in e)t[l(r)]=""===e[r]||e[r];return t}"function"==typeof SuppressedError&&SuppressedError;const y=r({name:"SimpleTable",props:{},inheritAttrs:!1,setup(e,{attrs:r,expose:l}){const a=n(null);let s=null;return o(()=>{a.value&&(s=new c(a.value,b(R(r))),s.mount())}),d(()=>{null==s||s.update(b(R(r)))}),i(()=>{null==s||s.destroy(),s=null}),l({getAPI:()=>{var e;return null!==(e=null==s?void 0:s.getAPI())&&void 0!==e?e:null}}),()=>t("div",{ref:a})}});export{y as SimpleTable};
1
+ import{render as e,h as r,defineComponent as t,ref as n,onMounted as o,onUpdated as d,onUnmounted as i,camelize as l}from"vue";import{SimpleTableVanilla as c}from"simple-table-core";function s(e,r){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&r.indexOf(n)<0&&(t[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)r.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(t[n[o]]=e[n[o]])}return t}function a(t){return n=>{const o=document.createElement("div");return e(r(t,n),o),o}}function u(r){const t=document.createElement("div");return e(r,t),t}function f(r){const t=document.createElement("div");e(r,t);const n=t.innerHTML;return e(null,t),n}function p(e){return"object"==typeof e||"function"==typeof e}function m(e){const{cellRenderer:r,headerRenderer:t,children:n,nestedTable:o}=e,d=s(e,["cellRenderer","headerRenderer","children","nestedTable"]),i=Object.assign({},d);if(r&&(i.cellRenderer="object"==typeof r?a(r):r),t&&(i.headerRenderer="object"==typeof t?a(t):t),n&&(i.children=n.map(m)),o){const e=Object.assign(Object.assign({},o),{rows:[]});i.nestedTable=R(e)}return i}function R(e){const{defaultHeaders:r,footerRenderer:t,emptyStateRenderer:n,errorStateRenderer:o,loadingStateRenderer:d,tableEmptyStateRenderer:i,headerDropdown:l,columnEditorConfig:c,icons:R}=e,b=s(e,["defaultHeaders","footerRenderer","emptyStateRenderer","errorStateRenderer","loadingStateRenderer","tableEmptyStateRenderer","headerDropdown","columnEditorConfig","icons"]),y=Object.assign(Object.assign({},b),{defaultHeaders:r.map(m)});if(void 0!==t&&(y.footerRenderer="object"==typeof t?a(t):t),void 0!==n)if(p(n))y.emptyStateRenderer=a(n);else{const e=n;y.emptyStateRenderer=()=>u(e)}if(void 0!==o)if(p(o))y.errorStateRenderer=a(o);else{const e=o;y.errorStateRenderer=()=>u(e)}if(void 0!==d)if(p(d))y.loadingStateRenderer=a(d);else{const e=d;y.loadingStateRenderer=()=>u(e)}return void 0!==i&&(y.tableEmptyStateRenderer=null===i?null:i instanceof HTMLElement||"string"==typeof i?i:u(i)),void 0!==l&&(y.headerDropdown=a(l)),void 0!==c&&(y.columnEditorConfig=function(e){const{rowRenderer:r,customRenderer:t}=e,n=s(e,["rowRenderer","customRenderer"]);return Object.assign(Object.assign(Object.assign({},n),r?{rowRenderer:a(r)}:{}),t?{customRenderer:a(t)}:{})}(c)),void 0!==R&&(y.icons=function(e){const r={};for(const[t,n]of Object.entries(e))null!=n&&(r[t]="string"==typeof n||n instanceof HTMLElement||n instanceof SVGElement?n:f(n));return r}(R)),y}function b(e){const r={};for(const t in e)r[l(t)]=""===e[t]||e[t];return r}"function"==typeof SuppressedError&&SuppressedError;const y=t({name:"SimpleTable",props:{},inheritAttrs:!1,setup(e,{attrs:t,expose:l}){const s=n(null);let a=null;return o(()=>{s.value&&(a=new c(s.value,R(b(t))),a.mount())}),d(()=>{null==a||a.update(R(b(t)))}),i(()=>{null==a||a.destroy(),a=null}),l({getAPI:()=>{var e;return null!==(e=null==a?void 0:a.getAPI())&&void 0!==e?e:null}}),()=>r("div",{ref:s})}});export{y as SimpleTable};
2
2
  //# sourceMappingURL=index.es.js.map
@@ -1,5 +1,7 @@
1
1
  import { SimpleTableConfig } from "../../types/SimpleTableConfig";
2
2
  import { CustomTheme } from "../../types/CustomTheme";
3
+ import { ColumnEditorRowRenderer } from "../../types/ColumnEditorRowRendererProps";
4
+ import { ColumnEditorCustomRenderer } from "../../types/ColumnEditorCustomRendererProps";
3
5
  import HeaderObject, { Accessor } from "../../types/HeaderObject";
4
6
  export interface ResolvedIcons {
5
7
  drag: string | HTMLElement | SVGSVGElement;
@@ -18,7 +20,8 @@ export interface MergedColumnEditorConfig {
18
20
  searchPlaceholder: string;
19
21
  allowColumnPinning: boolean;
20
22
  searchFunction?: (header: HeaderObject, searchText: string) => boolean;
21
- rowRenderer?: any;
23
+ rowRenderer?: ColumnEditorRowRenderer;
24
+ customRenderer?: ColumnEditorCustomRenderer;
22
25
  }
23
26
  export declare class TableInitializer {
24
27
  static resolveIcons(config: SimpleTableConfig): ResolvedIcons;
@@ -31,6 +31,7 @@ import type HeaderRendererProps from "./types/HeaderRendererProps";
31
31
  import type { HeaderRenderer, HeaderRendererComponents } from "./types/HeaderRendererProps";
32
32
  import type ColumnEditorRowRendererProps from "./types/ColumnEditorRowRendererProps";
33
33
  import type { ColumnEditorRowRenderer, ColumnEditorRowRendererComponents } from "./types/ColumnEditorRowRendererProps";
34
+ import type { ColumnEditorCustomRendererProps, ColumnEditorCustomRenderer } from "./types/ColumnEditorCustomRendererProps";
34
35
  import type HeaderDropdownProps from "./types/HeaderDropdownProps";
35
36
  import type { HeaderDropdown } from "./types/HeaderDropdownProps";
36
37
  import type { RowButtonProps } from "./types/RowButton";
@@ -45,4 +46,4 @@ import type { SimpleTableProps } from "./types/SimpleTableProps";
45
46
  import type { RowId } from "./types/RowId";
46
47
  import type { PinnedSectionsState } from "./types/PinnedSectionsState";
47
48
  export { SimpleTableVanilla };
48
- export type { Accessor, AggregationConfig, AggregationType, BoundingBox, Cell, CellChangeProps, CellClickProps, CellRenderer, CellRendererProps, CellValue, ChartOptions, ColumnEditorConfig, ColumnEditorRowRenderer, ColumnEditorRowRendererComponents, ColumnEditorRowRendererProps, ColumnEditorSearchFunction, ColumnType, ColumnVisibilityState, Comparator, ComparatorProps, CustomTheme, CustomThemeProps, DragHandlerProps, EmptyStateRenderer, EmptyStateRendererProps, EnumOption, ErrorStateRenderer, ErrorStateRendererProps, ExportToCSVProps, ExportValueGetter, ExportValueProps, FilterCondition, FooterRendererProps, GetRowId, GetRowIdParams, IconsConfig, LoadingStateRenderer, LoadingStateRendererProps, HeaderDropdown, HeaderDropdownProps, HeaderObject, HeaderRenderer, HeaderRendererProps, HeaderRendererComponents, OnRowGroupExpandProps, OnSortProps, QuickFilterConfig, QuickFilterGetter, QuickFilterGetterProps, QuickFilterMode, Row, RowButtonProps, RowId, RowSelectionChangeProps, RowState, SetHeaderRenameProps, SharedTableProps, ShowWhen, SimpleTableConfig, SimpleTableProps, SortColumn, TableAPI, TableFilterState, TableHeaderProps, TableRefType, TableRowProps, Theme, PinnedSectionsState, UpdateDataProps, ValueFormatter, ValueFormatterProps, ValueGetter, ValueGetterProps, };
49
+ export type { Accessor, AggregationConfig, AggregationType, BoundingBox, Cell, CellChangeProps, CellClickProps, CellRenderer, CellRendererProps, CellValue, ChartOptions, ColumnEditorConfig, ColumnEditorCustomRenderer, ColumnEditorCustomRendererProps, ColumnEditorRowRenderer, ColumnEditorRowRendererComponents, ColumnEditorRowRendererProps, ColumnEditorSearchFunction, ColumnType, ColumnVisibilityState, Comparator, ComparatorProps, CustomTheme, CustomThemeProps, DragHandlerProps, EmptyStateRenderer, EmptyStateRendererProps, EnumOption, ErrorStateRenderer, ErrorStateRendererProps, ExportToCSVProps, ExportValueGetter, ExportValueProps, FilterCondition, FooterRendererProps, GetRowId, GetRowIdParams, IconsConfig, LoadingStateRenderer, LoadingStateRendererProps, HeaderDropdown, HeaderDropdownProps, HeaderObject, HeaderRenderer, HeaderRendererProps, HeaderRendererComponents, OnRowGroupExpandProps, OnSortProps, QuickFilterConfig, QuickFilterGetter, QuickFilterGetterProps, QuickFilterMode, Row, RowButtonProps, RowId, RowSelectionChangeProps, RowState, SetHeaderRenameProps, SharedTableProps, ShowWhen, SimpleTableConfig, SimpleTableProps, SortColumn, TableAPI, TableFilterState, TableHeaderProps, TableRefType, TableRowProps, Theme, PinnedSectionsState, UpdateDataProps, ValueFormatter, ValueFormatterProps, ValueGetter, ValueGetterProps, };
@@ -1,5 +1,6 @@
1
1
  import HeaderObject from "./HeaderObject";
2
2
  import { ColumnEditorRowRenderer } from "./ColumnEditorRowRendererProps";
3
+ import { ColumnEditorCustomRenderer } from "./ColumnEditorCustomRendererProps";
3
4
  /**
4
5
  * Custom search function for filtering columns in the column editor
5
6
  * @param header - The header object to check
@@ -26,7 +27,9 @@ export interface ColumnEditorConfig {
26
27
  allowColumnPinning?: boolean;
27
28
  /** Custom renderer for column editor row layout to reposition icons and labels */
28
29
  rowRenderer?: ColumnEditorRowRenderer;
30
+ /** Custom renderer for the entire column editor panel. Receives pre-built sections (search, list, reset) and headers. */
31
+ customRenderer?: ColumnEditorCustomRenderer;
29
32
  }
30
- export declare const DEFAULT_COLUMN_EDITOR_CONFIG: Required<Omit<ColumnEditorConfig, "searchFunction" | "rowRenderer">>;
33
+ export declare const DEFAULT_COLUMN_EDITOR_CONFIG: Required<Omit<ColumnEditorConfig, "searchFunction" | "rowRenderer" | "customRenderer">>;
31
34
  /** Column editor config with defaults applied (text, searchEnabled, searchPlaceholder are required) */
32
- export type MergedColumnEditorConfig = Required<Pick<ColumnEditorConfig, "text" | "searchEnabled" | "searchPlaceholder" | "allowColumnPinning">> & Pick<ColumnEditorConfig, "searchFunction" | "rowRenderer">;
35
+ export type MergedColumnEditorConfig = Required<Pick<ColumnEditorConfig, "text" | "searchEnabled" | "searchPlaceholder" | "allowColumnPinning">> & Pick<ColumnEditorConfig, "searchFunction" | "rowRenderer" | "customRenderer">;
@@ -0,0 +1,14 @@
1
+ import type HeaderObject from "./HeaderObject";
2
+ export interface ColumnEditorCustomRendererProps {
3
+ /** The current headers array */
4
+ headers: HeaderObject[];
5
+ /** Pre-built search input section, or null if search is disabled */
6
+ searchSection: HTMLElement | null;
7
+ /** Pre-built column list section with drag-and-drop, checkboxes, etc. */
8
+ listSection: HTMLElement;
9
+ /** Pre-built reset button section, or null if no default headers are configured */
10
+ resetSection: HTMLElement | null;
11
+ /** Function to reset columns to their default configuration */
12
+ resetColumns?: () => void;
13
+ }
14
+ export type ColumnEditorCustomRenderer = (props: ColumnEditorCustomRendererProps) => HTMLElement | string | null;
@@ -1,3 +1,3 @@
1
1
  export { default as SimpleTable } from "./SimpleTable";
2
- export type { SimpleTableVueProps, TableInstance, VueHeaderObject, VueColumnEditorConfig, VueIconsConfig, VueIconElement, VueCellRenderer, VueHeaderRenderer, VueFooterRenderer, VueHeaderDropdown, VueColumnEditorRowRenderer, VueLoadingStateRenderer, VueErrorStateRenderer, VueEmptyStateRenderer, } from "./types";
3
- export type { Accessor, AggregationConfig, AggregationType, BoundingBox, Cell, CellChangeProps, CellClickProps, CellRendererProps, CellValue, ChartOptions, ColumnEditorConfig, ColumnEditorRowRenderer, ColumnEditorRowRendererComponents, ColumnEditorRowRendererProps, ColumnEditorSearchFunction, ColumnType, ColumnVisibilityState, Comparator, ComparatorProps, CustomTheme, CustomThemeProps, DragHandlerProps, EmptyStateRenderer, EmptyStateRendererProps, EnumOption, ErrorStateRenderer, ErrorStateRendererProps, ExportToCSVProps, ExportValueGetter, ExportValueProps, FilterCondition, FooterRendererProps, GetRowId, GetRowIdParams, HeaderDropdown, HeaderDropdownProps, HeaderObject, HeaderRenderer, HeaderRendererComponents, HeaderRendererProps, IconsConfig, LoadingStateRenderer, LoadingStateRendererProps, OnRowGroupExpandProps, OnSortProps, QuickFilterConfig, QuickFilterGetter, QuickFilterGetterProps, QuickFilterMode, Row, RowButtonProps, RowId, RowSelectionChangeProps, RowState, SetHeaderRenameProps, SharedTableProps, ShowWhen, SimpleTableConfig, SimpleTableProps, SortColumn, TableAPI, TableFilterState, TableHeaderProps, TableRowProps, Theme, UpdateDataProps, ValueFormatter, ValueFormatterProps, ValueGetter, ValueGetterProps, } from "simple-table-core";
2
+ export type { SimpleTableVueProps, TableInstance, VueHeaderObject, VueColumnEditorConfig, VueIconsConfig, VueIconElement, VueCellRenderer, VueHeaderRenderer, VueFooterRenderer, VueHeaderDropdown, VueColumnEditorRowRenderer, VueColumnEditorCustomRenderer, VueLoadingStateRenderer, VueErrorStateRenderer, VueEmptyStateRenderer, } from "./types";
3
+ export type { Accessor, AggregationConfig, AggregationType, BoundingBox, Cell, CellChangeProps, CellClickProps, CellRendererProps, CellValue, ChartOptions, ColumnEditorConfig, ColumnEditorRowRenderer, ColumnEditorRowRendererComponents, ColumnEditorCustomRenderer, ColumnEditorCustomRendererProps, ColumnEditorRowRendererProps, ColumnEditorSearchFunction, ColumnType, ColumnVisibilityState, Comparator, ComparatorProps, CustomTheme, CustomThemeProps, DragHandlerProps, EmptyStateRenderer, EmptyStateRendererProps, EnumOption, ErrorStateRenderer, ErrorStateRendererProps, ExportToCSVProps, ExportValueGetter, ExportValueProps, FilterCondition, FooterRendererProps, GetRowId, GetRowIdParams, HeaderDropdown, HeaderDropdownProps, HeaderObject, HeaderRenderer, HeaderRendererComponents, HeaderRendererProps, IconsConfig, LoadingStateRenderer, LoadingStateRendererProps, OnRowGroupExpandProps, OnSortProps, QuickFilterConfig, QuickFilterGetter, QuickFilterGetterProps, QuickFilterMode, Row, RowButtonProps, RowId, RowSelectionChangeProps, RowState, SetHeaderRenameProps, SharedTableProps, ShowWhen, SimpleTableConfig, SimpleTableProps, SortColumn, TableAPI, TableFilterState, TableHeaderProps, TableRowProps, Theme, UpdateDataProps, ValueFormatter, ValueFormatterProps, ValueGetter, ValueGetterProps, } from "simple-table-core";
@@ -1,5 +1,5 @@
1
1
  import type { Component, VNode } from "vue";
2
- import type { SimpleTableProps, SimpleTableConfig, HeaderObject, TableAPI, CellRendererProps, HeaderRendererProps, FooterRendererProps, LoadingStateRendererProps, ErrorStateRendererProps, EmptyStateRendererProps, HeaderDropdownProps, ColumnEditorRowRendererProps, ColumnEditorConfig } from "simple-table-core";
2
+ import type { SimpleTableProps, SimpleTableConfig, HeaderObject, TableAPI, CellRendererProps, HeaderRendererProps, FooterRendererProps, LoadingStateRendererProps, ErrorStateRendererProps, EmptyStateRendererProps, HeaderDropdownProps, ColumnEditorRowRendererProps, ColumnEditorCustomRendererProps, ColumnEditorConfig } from "simple-table-core";
3
3
  export interface TableInstance {
4
4
  mount(): void;
5
5
  update(config: Partial<SimpleTableConfig>): void;
@@ -25,11 +25,13 @@ export type VueHeaderRenderer = Component<HeaderRendererProps>;
25
25
  export type VueFooterRenderer = Component<FooterRendererProps>;
26
26
  export type VueHeaderDropdown = Component<HeaderDropdownProps>;
27
27
  export type VueColumnEditorRowRenderer = Component<ColumnEditorRowRendererProps>;
28
+ export type VueColumnEditorCustomRenderer = Component<ColumnEditorCustomRendererProps>;
28
29
  export type VueLoadingStateRenderer = Component<LoadingStateRendererProps> | VNode;
29
30
  export type VueErrorStateRenderer = Component<ErrorStateRendererProps> | VNode;
30
31
  export type VueEmptyStateRenderer = Component<EmptyStateRendererProps> | VNode;
31
- export interface VueColumnEditorConfig extends Omit<ColumnEditorConfig, "rowRenderer"> {
32
+ export interface VueColumnEditorConfig extends Omit<ColumnEditorConfig, "rowRenderer" | "customRenderer"> {
32
33
  rowRenderer?: VueColumnEditorRowRenderer;
34
+ customRenderer?: VueColumnEditorCustomRenderer;
33
35
  }
34
36
  export interface VueHeaderObject extends Omit<HeaderObject, "cellRenderer" | "headerRenderer" | "children" | "nestedTable"> {
35
37
  cellRenderer?: VueCellRenderer;
@@ -48,4 +50,4 @@ export interface SimpleTableVueProps extends Omit<SimpleTableProps, "tableRef" |
48
50
  columnEditorConfig?: VueColumnEditorConfig;
49
51
  icons?: VueIconsConfig;
50
52
  }
51
- export type { CellRendererProps, HeaderRendererProps, FooterRendererProps, LoadingStateRendererProps, ErrorStateRendererProps, EmptyStateRendererProps, HeaderDropdownProps, ColumnEditorRowRendererProps, };
53
+ export type { CellRendererProps, HeaderRendererProps, FooterRendererProps, LoadingStateRendererProps, ErrorStateRendererProps, EmptyStateRendererProps, HeaderDropdownProps, ColumnEditorRowRendererProps, ColumnEditorCustomRendererProps, };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@simple-table/vue",
3
- "version": "3.0.0-beta.15",
3
+ "version": "3.0.0-beta.16",
4
4
  "main": "dist/cjs/index.js",
5
5
  "module": "dist/index.es.js",
6
6
  "types": "dist/types/vue/src/index.d.ts",
@@ -28,7 +28,7 @@
28
28
  "vue": ">=3.0.0"
29
29
  },
30
30
  "dependencies": {
31
- "simple-table-core": "3.0.0-beta.15"
31
+ "simple-table-core": "3.0.0-beta.16"
32
32
  },
33
33
  "devDependencies": {
34
34
  "@rollup/plugin-alias": "4.0.0",