@cnamts/synapse 1.0.1 → 1.0.2
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/README.md +1 -1
- package/dist/{DateFilter-BmRuzQ9Z.js → DateFilter-YWOTbfeL.js} +1 -1
- package/dist/{NumberFilter-CnIPDHqx.js → NumberFilter-DMmMgALM.js} +1 -1
- package/dist/{PeriodFilter-CZwZ8CnQ.js → PeriodFilter-Bok5BHcn.js} +1 -1
- package/dist/SelectFilter-BKud2WhN.js +136 -0
- package/dist/{TextFilter-DTxZHJwX.js → TextFilter-DvMf2thH.js} +1 -1
- package/dist/components/Accordion/Accordion.d.ts +2 -1
- package/dist/components/Accordion/composables/useAccordionGroupCommunication.d.ts +5 -0
- package/dist/components/Accordion/composables/useAccordionKeyboardNavigation.d.ts +12 -0
- package/dist/components/Accordion/composables/useAccordionState.d.ts +13 -0
- package/dist/components/Customs/SyCheckbox/SyCheckbox.d.ts +85 -0
- package/dist/components/Customs/SyInputSelect/SyInputSelect.d.ts +2 -0
- package/dist/components/Customs/SySelect/SySelect.d.ts +33 -13
- package/dist/components/Customs/SyTextField/SyTextField.d.ts +2 -2
- package/dist/components/DatePicker/ComplexDatePicker/ComplexDatePicker.d.ts +1585 -1452
- package/dist/components/DatePicker/DatePicker/DatePicker.d.ts +16 -2
- package/dist/components/DatePicker/DateTextInput/DateTextInput.d.ts +3 -1
- package/dist/components/DatePicker/composables/index.d.ts +2 -0
- package/dist/components/DatePicker/composables/useAsteriskDisplay.d.ts +14 -0
- package/dist/components/DatePicker/composables/useDateAutoClamp.d.ts +16 -0
- package/dist/components/DatePicker/composables/useDateRangeInput.d.ts +1 -1
- package/dist/components/DatePicker/composables/useDisplayedDateString.d.ts +3 -0
- package/dist/components/DatePicker/composables/useInputBlurHandler.d.ts +1 -0
- package/dist/components/DatePicker/composables/useMonthButtonCustomization.d.ts +5 -2
- package/dist/components/NirField/NirField.d.ts +7 -3
- package/dist/components/NirField/nirValidation.d.ts +1 -1
- package/dist/components/PasswordField/PasswordField.d.ts +2 -0
- package/dist/components/PeriodField/PeriodField.d.ts +52 -8
- package/dist/components/PhoneField/PhoneField.d.ts +2 -2
- package/dist/components/RangeField/RangeField.d.ts +2 -0
- package/dist/components/SearchListField/SearchListField.d.ts +9 -0
- package/dist/components/SyTextArea/SyTextArea.d.ts +2 -0
- package/dist/components/Tables/SyServerTable/SyServerTable.d.ts +14 -9
- package/dist/components/Tables/SyTable/SyTable.d.ts +12 -7
- package/dist/components/Tables/common/SyTablePagination.d.ts +1636 -0
- package/dist/components/Tables/common/TableHeader.d.ts +2 -20
- package/dist/components/Tables/common/filters/SelectFilter.d.ts +5 -5
- package/dist/components/Tables/common/filters/getFilterComponent.d.ts +1 -0
- package/dist/components/Tables/common/filters/locales.d.ts +4 -0
- package/dist/components/Tables/common/filters/logics/date.d.ts +1 -0
- package/dist/components/Tables/common/filters/logics/number.d.ts +1 -0
- package/dist/components/Tables/common/filters/logics/period.d.ts +1 -0
- package/dist/components/Tables/common/filters/logics/select.d.ts +1 -0
- package/dist/components/Tables/common/filters/logics/text.d.ts +1 -0
- package/dist/components/Tables/common/locales.d.ts +21 -0
- package/dist/components/Tables/common/organizeColumns/OrganizeColumns.d.ts +267 -0
- package/dist/components/Tables/common/organizeColumns/sortHeaders.d.ts +2 -0
- package/dist/components/Tables/common/tableFilterUtils.d.ts +1 -0
- package/dist/components/Tables/common/tableStorageUtils.d.ts +41 -1
- package/dist/components/Tables/common/tableUtils.d.ts +42 -5
- package/dist/components/Tables/common/types.d.ts +19 -8
- package/dist/components/Tables/common/usePagination.d.ts +22 -0
- package/dist/components/Tables/common/useTableCheckbox.d.ts +20 -0
- package/dist/components/Tables/common/useTableHeaders.d.ts +76 -0
- package/dist/components/Tables/common/useTableItems.d.ts +24 -0
- package/dist/components/Tables/common/useTableOptions.d.ts +18 -0
- package/dist/components/ToolbarContainer/ToolbarContainer.d.ts +11 -0
- package/dist/components/UserMenuBtn/UserMenuBtn.d.ts +9 -2
- package/dist/components/index.d.ts +8 -6
- package/dist/design-system-v3.js +58 -56
- package/dist/design-system-v3.umd.cjs +22 -22
- package/dist/main-Cx8qG7YR.js +16344 -0
- package/dist/stories/Accessibilite/Vuetify/VuetifyItems.d.ts +14 -2
- package/dist/stories/DesignTokens/StylesTypographiques.stories.new.d.ts +8 -0
- package/dist/stories/DesignTokens/TypographyDisplay.d.ts +28 -0
- package/dist/stories/DesignTokens/vue-shims.d.ts +6 -0
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/src/common/imgs/accessibility-svgrepo-com.svg +4 -0
- package/src/components/Accordion/Accessibilite/AccessibilityGuide.mdx +249 -0
- package/src/components/Accordion/Accordion.vue +48 -76
- package/src/components/Accordion/composables/__tests__/useAccordionGroupCommunication.spec.ts +146 -0
- package/src/components/Accordion/composables/__tests__/useAccordionKeyboardNavigation.spec.ts +209 -0
- package/src/components/Accordion/composables/__tests__/useAccordionState.spec.ts +144 -0
- package/src/components/Accordion/composables/useAccordionGroupCommunication.ts +52 -0
- package/src/components/Accordion/composables/useAccordionKeyboardNavigation.ts +111 -0
- package/src/components/Accordion/composables/useAccordionState.ts +59 -0
- package/src/components/Accordion/tests/__snapshots__/accordion.spec.ts.snap +3 -0
- package/src/components/Customs/SyCheckbox/Accessibilite.mdx +303 -0
- package/src/components/Customs/SyCheckbox/SyCheckbox.mdx +50 -0
- package/src/components/Customs/SyCheckbox/SyCheckbox.stories.ts +630 -0
- package/src/components/Customs/SyCheckbox/SyCheckbox.vue +326 -0
- package/src/components/Customs/SyCheckbox/tests/SyCheckbox.spec.ts +201 -0
- package/src/components/Customs/SyInputSelect/SyInputSelect.stories.ts +1 -0
- package/src/components/Customs/SyInputSelect/SyInputSelect.vue +8 -1
- package/src/components/Customs/SySelect/SySelect.stories.ts +160 -0
- package/src/components/Customs/SySelect/SySelect.vue +291 -32
- package/src/components/Customs/SySelect/tests/SySelect.spec.ts +230 -0
- package/src/components/Customs/SyTextField/SyTextField.stories.ts +3 -2
- package/src/components/Customs/SyTextField/SyTextField.vue +19 -8
- package/src/components/DatePicker/ComplexDatePicker/ComplexDatePicker.stories.ts +241 -31
- package/src/components/DatePicker/ComplexDatePicker/ComplexDatePicker.vue +305 -57
- package/src/components/DatePicker/ComplexDatePicker/tests/ComplexDatePicker.events.spec.ts +161 -0
- package/src/components/DatePicker/ComplexDatePicker/tests/ComplexDatePicker.spec.ts +4 -2
- package/src/components/DatePicker/DatePicker/DatePicker.stories.ts +259 -137
- package/src/components/DatePicker/DatePicker/DatePicker.vue +153 -25
- package/src/components/DatePicker/DatePicker/tests/DatePicker.events.spec.ts +189 -0
- package/src/components/DatePicker/DatePicker/{DatePicker.spec.ts → tests/DatePicker.spec.ts} +1 -15
- package/src/components/DatePicker/DateTextInput/DateRange.stories.ts +24 -14
- package/src/components/DatePicker/DateTextInput/DateTextInput.events.spec.ts +148 -0
- package/src/components/DatePicker/DateTextInput/DateTextInput.spec.ts +3 -1
- package/src/components/DatePicker/DateTextInput/DateTextInput.vue +200 -5
- package/src/components/DatePicker/DateTextInput/NoCalendar.stories.ts +241 -31
- package/src/components/DatePicker/composables/index.ts +2 -0
- package/src/components/DatePicker/composables/tests/useDateAutoClamp.spec.ts +190 -0
- package/src/components/DatePicker/composables/tests/useInputBlurHandler.spec.ts +182 -4
- package/src/components/DatePicker/composables/tests/useMonthButtonCustomization.spec.ts +105 -80
- package/src/components/DatePicker/composables/useAsteriskDisplay.ts +31 -0
- package/src/components/DatePicker/composables/useDateAutoClamp.ts +136 -0
- package/src/components/DatePicker/composables/useDateRangeInput.ts +21 -18
- package/src/components/DatePicker/composables/useDisplayedDateString.ts +13 -1
- package/src/components/DatePicker/composables/useInputBlurHandler.ts +84 -20
- package/src/components/DatePicker/composables/useMonthButtonCustomization.ts +149 -51
- package/src/components/DiacriticPicker/DiacriticPicker.stories.ts +10 -0
- package/src/components/ErrorPage/Accessibilite.stories.ts +8 -0
- package/src/components/ErrorPage/ErrorPage.vue +12 -6
- package/src/components/ErrorPage/tests/__snapshots__/ErrorPage.spec.ts.snap +4 -4
- package/src/components/NirField/NirField.mdx +22 -9
- package/src/components/NirField/NirField.stories.ts +26 -2
- package/src/components/NirField/NirField.vue +209 -22
- package/src/components/NirField/nirValidation.ts +17 -3
- package/src/components/NirField/tests/NirField.spec.ts +2 -2
- package/src/components/NotFoundPage/Accessibilite.stories.ts +8 -0
- package/src/components/NotFoundPage/NotFoundPage.vue +2 -1
- package/src/components/NotFoundPage/tests/__snapshots__/NotFoundPage.spec.ts.snap +8 -6
- package/src/components/PaginatedTable/PaginatedTable.mdx +2 -0
- package/src/components/PasswordField/PasswordField.stories.ts +4 -0
- package/src/components/PasswordField/PasswordField.vue +3 -0
- package/src/components/PeriodField/PeriodField.vue +2 -0
- package/src/components/PhoneField/PhoneField.stories.ts +15 -15
- package/src/components/PhoneField/PhoneField.vue +1 -1
- package/src/components/RangeField/RangeField.stories.ts +9 -0
- package/src/components/RangeField/RangeField.vue +4 -0
- package/src/components/RangeField/tests/__snapshots__/RangeField.spec.ts.snap +12 -0
- package/src/components/SearchListField/SearchListField.vue +5 -0
- package/src/components/SyTextArea/SyTextArea.vue +3 -0
- package/src/components/SyTextArea/tests/SyTextArea.spec.ts +0 -1
- package/src/components/Tables/SyServerTable/FilterRules.stories.ts +632 -15
- package/src/components/Tables/SyServerTable/SyServerTable.mdx +15 -5
- package/src/components/Tables/SyServerTable/SyServerTable.stories.ts +2844 -1377
- package/src/components/Tables/SyServerTable/SyServerTable.vue +155 -66
- package/src/components/Tables/SyServerTable/tests/SyServerTable.spec.ts +256 -4
- package/src/components/Tables/SyTable/FilterRules.stories.ts +183 -0
- package/src/components/Tables/SyTable/SyTable.mdx +14 -4
- package/src/components/Tables/SyTable/SyTable.stories.ts +1265 -477
- package/src/components/Tables/SyTable/SyTable.vue +152 -72
- package/src/components/Tables/SyTable/tests/SyTable.spec.ts +366 -4
- package/src/components/Tables/common/SyTableFilter.vue +3 -56
- package/src/components/Tables/common/SyTablePagination.vue +375 -0
- package/src/components/Tables/common/TableHeader.vue +10 -26
- package/src/components/Tables/common/filters/SelectFilter.vue +131 -22
- package/src/components/Tables/common/filters/getFilterComponent.ts +54 -0
- package/src/components/Tables/common/filters/locales.ts +4 -0
- package/src/components/Tables/common/filters/logics/date.ts +12 -0
- package/src/components/Tables/common/filters/logics/number.ts +48 -0
- package/src/components/Tables/common/filters/logics/period.ts +25 -0
- package/src/components/Tables/common/filters/logics/select.ts +27 -0
- package/src/components/Tables/common/filters/logics/tests/TextFilterLogic.spec.ts +177 -0
- package/src/components/Tables/common/filters/logics/text.ts +62 -0
- package/src/components/Tables/common/filters/tests/TextFilter.spec.ts +11 -11
- package/src/components/Tables/common/locales.ts +24 -0
- package/src/components/Tables/common/organizeColumns/OrganizeColumns.vue +269 -0
- package/src/components/Tables/common/organizeColumns/sortHeaders.ts +9 -0
- package/src/components/Tables/common/tableFilterUtils.ts +43 -295
- package/src/components/Tables/common/tableStorageUtils.ts +27 -2
- package/src/components/Tables/common/tableStyles.scss +26 -0
- package/src/components/Tables/common/tableUtils.ts +3 -16
- package/src/components/Tables/common/tests/SyTablePagination.spec.ts +170 -0
- package/src/components/Tables/common/tests/filterByRange.spec.ts +215 -0
- package/src/components/Tables/common/tests/tableFilterUtils.spec.ts +0 -14
- package/src/components/Tables/common/tests/tableUtils.spec.ts +7 -51
- package/src/components/Tables/common/types.ts +17 -6
- package/src/components/Tables/common/usePagination.ts +83 -0
- package/src/components/Tables/common/useTableCheckbox.ts +58 -0
- package/src/components/Tables/common/useTableHeaders.ts +88 -0
- package/src/components/Tables/common/useTableItems.ts +87 -0
- package/src/components/Tables/common/useTableOptions.ts +93 -0
- package/src/components/ToolbarContainer/ToolbarContainer.mdx +16 -0
- package/src/components/ToolbarContainer/ToolbarContainer.stories.ts +675 -0
- package/src/components/ToolbarContainer/ToolbarContainer.vue +128 -0
- package/src/components/ToolbarContainer/tests/ToolbarContainer.spec.ts +156 -0
- package/src/components/UserMenuBtn/UserMenuBtn.stories.ts +74 -0
- package/src/components/UserMenuBtn/UserMenuBtn.vue +19 -17
- package/src/components/index.ts +8 -6
- package/src/stories/Accessibilite/Aculturation/AuditDesignSystem.mdx +293 -20
- package/src/stories/Accessibilite/Aculturation/SensibilisationAccessibilite.mdx +448 -54
- package/src/stories/Accessibilite/Audit/RGAA.mdx +231 -23
- package/src/stories/Accessibilite/Avancement/Avancement.mdx +591 -7
- package/src/stories/Accessibilite/Avancement/Avancement.stories.ts +139 -38
- package/src/stories/Accessibilite/Introduction.mdx +258 -18
- package/src/stories/Accessibilite/KitDePreAudit/Echantillonnage.mdx +221 -31
- package/src/stories/Accessibilite/KitDePreAudit/Introduction.mdx +204 -22
- package/src/stories/Accessibilite/KitDePreAudit/Outils/Introduction.mdx +537 -24
- package/src/stories/Accessibilite/KitDePreAudit/Outils/LecteursDEcran.mdx +577 -70
- package/src/stories/Accessibilite/KitDePreAudit/Outils/Tanaguru.mdx +382 -31
- package/src/stories/Accessibilite/KitDePreAudit/Preaudit.mdx +419 -81
- package/src/stories/Accessibilite/Vuetify/Vuetify.mdx +132 -6
- package/src/stories/Accessibilite/Vuetify/Vuetify.stories.ts +370 -146
- package/src/stories/Accessibilite/Vuetify/VuetifyItems.ts +35 -57
- package/src/stories/Demarrer/Accueil.stories.ts +20 -5
- package/src/stories/DesignTokens/StylesTypographiques.mdx +10 -9
- package/src/stories/DesignTokens/StylesTypographiques.stories.new.ts +397 -0
- package/src/stories/DesignTokens/StylesTypographiques.stories.ts +397 -0
- package/src/stories/DesignTokens/TypographyDisplay.vue +155 -0
- package/src/stories/DesignTokens/vue-shims.d.ts +6 -0
- package/src/stories/GuideDuDev/LesBreackingChanges.mdx +0 -2
- package/src/stories/GuideDuDev/MigrationDepuisBridge.mdx +1 -1
- package/src/stories/GuideDuDev/MigrationDepuisVue2.mdx +1 -1
- package/src/stories/GuideDuDev/PortailAgent.mdx +10 -0
- package/src/stories/GuideDuDev/PortailAgent.stories.ts +506 -0
- package/src/stories/GuideDuDev/Theme.mdx +41 -0
- package/dist/SelectFilter-Cj-GW2Cc.js +0 -97
- package/dist/main-WDqeoGM-.js +0 -14788
- package/src/components/PaginatedTable/tests/__snapshots__/PaginatedTable.spec.ts.snap +0 -886
- package/src/components/Tables/SyServerTable/tests/__snapshots__/SyServerTable.spec.ts.snap +0 -521
- package/src/components/Tables/SyTable/tests/__snapshots__/SyTable.spec.ts.snap +0 -521
- package/src/stories/DesignTokens/ThemePA.mdx +0 -35
|
@@ -1,25 +1,7 @@
|
|
|
1
1
|
import { VDataTable, VDataTableServer } from 'vuetify/components';
|
|
2
|
-
type TableColumn = {
|
|
3
|
-
key: string | null;
|
|
4
|
-
title?: string;
|
|
5
|
-
value: unknown;
|
|
6
|
-
sortable: boolean;
|
|
7
|
-
rowspan?: number;
|
|
8
|
-
colspan?: number;
|
|
9
|
-
width?: number | string;
|
|
10
|
-
sortBy?: string;
|
|
11
|
-
};
|
|
12
|
-
interface TableData {
|
|
13
|
-
columns: TableColumn[];
|
|
14
|
-
sortBy?: unknown;
|
|
15
|
-
someSelected?: boolean;
|
|
16
|
-
allSelected?: boolean;
|
|
17
|
-
getSortIcon: (column: unknown) => string | undefined;
|
|
18
|
-
toggleSort: (column: unknown) => void;
|
|
19
|
-
}
|
|
20
2
|
type __VLS_Props = {
|
|
21
|
-
column:
|
|
22
|
-
headerParams:
|
|
3
|
+
column: Parameters<VDataTable['$slots']['headers']>['0']['columns'][number];
|
|
4
|
+
headerParams: Parameters<VDataTable['$slots']['headers']>['0'];
|
|
23
5
|
table: VDataTable | VDataTableServer | null | undefined;
|
|
24
6
|
resizableColumns?: boolean;
|
|
25
7
|
storageKey?: string;
|
|
@@ -9,8 +9,8 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
9
9
|
default: () => never[];
|
|
10
10
|
};
|
|
11
11
|
filterValue: {
|
|
12
|
-
type: () => string | number | Record<string, unknown> | undefined;
|
|
13
|
-
default:
|
|
12
|
+
type: () => string | number | Record<string, unknown> | Array<string | number | Record<string, unknown>> | undefined | null;
|
|
13
|
+
default: null;
|
|
14
14
|
};
|
|
15
15
|
inputConfig: {
|
|
16
16
|
type: () => {
|
|
@@ -59,8 +59,8 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
59
59
|
default: () => never[];
|
|
60
60
|
};
|
|
61
61
|
filterValue: {
|
|
62
|
-
type: () => string | number | Record<string, unknown> | undefined;
|
|
63
|
-
default:
|
|
62
|
+
type: () => string | number | Record<string, unknown> | Array<string | number | Record<string, unknown>> | undefined | null;
|
|
63
|
+
default: null;
|
|
64
64
|
};
|
|
65
65
|
inputConfig: {
|
|
66
66
|
type: () => {
|
|
@@ -107,7 +107,7 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
107
107
|
clearable: boolean;
|
|
108
108
|
filters: FilterOption[];
|
|
109
109
|
backgroundColor: string;
|
|
110
|
-
filterValue: string | number | Record<string, unknown> | undefined;
|
|
110
|
+
filterValue: string | number | Record<string, unknown> | (string | number | Record<string, unknown>)[] | null | undefined;
|
|
111
111
|
inputConfig: {
|
|
112
112
|
disableErrorHandling?: boolean | undefined;
|
|
113
113
|
variant?: string | undefined;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function getFilterComponent(filterType?: string, filterOptions?: unknown): any;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function filter(itemValue: unknown, filterValue: unknown): boolean;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function filter(itemValue: unknown, filterValue: unknown): boolean;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function filter(itemValue: unknown, filterValue: unknown): boolean;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function filter(itemValue: unknown, filterValue: unknown): boolean;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export default function filter(itemValue: unknown, filterValue: unknown): boolean;
|
|
@@ -4,4 +4,25 @@ export declare const locales: {
|
|
|
4
4
|
columnOrder: (columnTitle: string) => string;
|
|
5
5
|
ResizableColumn: string;
|
|
6
6
|
resizeColumn: (columnTitle: string) => string;
|
|
7
|
+
selectAllRows: string;
|
|
8
|
+
selectRow: string;
|
|
9
|
+
pagination: {
|
|
10
|
+
itemsPerPageText: string;
|
|
11
|
+
previous: string;
|
|
12
|
+
next: string;
|
|
13
|
+
all: string;
|
|
14
|
+
showingItems: (start: number, end: number, total: number) => string;
|
|
15
|
+
pageText: (page: number) => string;
|
|
16
|
+
pageAriaLabel: (page: number) => string;
|
|
17
|
+
currentPageAriaLabel: (page: number) => string;
|
|
18
|
+
paginationNavAriaLabel: string;
|
|
19
|
+
};
|
|
20
|
+
reorganizeColumns: string;
|
|
21
|
+
close: string;
|
|
22
|
+
apply: string;
|
|
23
|
+
reorganizeColumnsTitle: string;
|
|
24
|
+
hideColumn: (columnTitle: string) => string;
|
|
25
|
+
showColumn: (columnTitle: string) => string;
|
|
26
|
+
moveColumnLeft: (columnTitle: string) => string;
|
|
27
|
+
moveColumnRight: (columnTitle: string) => string;
|
|
7
28
|
};
|
|
@@ -0,0 +1,267 @@
|
|
|
1
|
+
import { DataTableHeaders } from '../types';
|
|
2
|
+
type __VLS_PublicProps = {
|
|
3
|
+
'headers': DataTableHeaders[];
|
|
4
|
+
};
|
|
5
|
+
declare const _default: import('vue').DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
6
|
+
"update:headers": (value: DataTableHeaders[]) => any;
|
|
7
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
8
|
+
"onUpdate:headers"?: ((value: DataTableHeaders[]) => any) | undefined;
|
|
9
|
+
}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
10
|
+
items: (import('vue').CreateComponentPublicInstanceWithMixins<{
|
|
11
|
+
replace: boolean;
|
|
12
|
+
variant: "flat" | "outlined" | "text" | "plain" | "elevated" | "tonal";
|
|
13
|
+
exact: boolean;
|
|
14
|
+
nav: boolean;
|
|
15
|
+
style: import('vue').StyleValue;
|
|
16
|
+
disabled: boolean;
|
|
17
|
+
tag: string | import('vuetify/lib/types.mjs').JSXComponent<any>;
|
|
18
|
+
density: import('vuetify/lib/composables/density.mjs').Density;
|
|
19
|
+
tile: boolean;
|
|
20
|
+
slim: boolean;
|
|
21
|
+
ripple: boolean | {
|
|
22
|
+
class: string;
|
|
23
|
+
} | undefined;
|
|
24
|
+
} & {
|
|
25
|
+
link?: boolean | undefined;
|
|
26
|
+
height?: string | number | undefined;
|
|
27
|
+
width?: string | number | undefined;
|
|
28
|
+
active?: boolean | undefined;
|
|
29
|
+
border?: string | number | boolean | undefined;
|
|
30
|
+
color?: string | undefined;
|
|
31
|
+
maxHeight?: string | number | undefined;
|
|
32
|
+
maxWidth?: string | number | undefined;
|
|
33
|
+
minHeight?: string | number | undefined;
|
|
34
|
+
minWidth?: string | number | undefined;
|
|
35
|
+
value?: any;
|
|
36
|
+
title?: string | number | boolean | undefined;
|
|
37
|
+
class?: any;
|
|
38
|
+
theme?: string | undefined;
|
|
39
|
+
to?: string | import('vue-router').RouteLocationAsRelativeGeneric | import('vue-router').RouteLocationAsPathGeneric | undefined;
|
|
40
|
+
lines?: false | "one" | "two" | "three" | undefined;
|
|
41
|
+
onClick?: ((args_0: MouseEvent | KeyboardEvent) => void) | undefined;
|
|
42
|
+
onClickOnce?: ((args_0: MouseEvent) => void) | undefined;
|
|
43
|
+
href?: string | undefined;
|
|
44
|
+
elevation?: string | number | undefined;
|
|
45
|
+
rounded?: string | number | boolean | undefined;
|
|
46
|
+
baseColor?: string | undefined;
|
|
47
|
+
activeColor?: string | undefined;
|
|
48
|
+
prependIcon?: import('vuetify/lib/composables/icons.mjs').IconValue | undefined;
|
|
49
|
+
appendIcon?: import('vuetify/lib/composables/icons.mjs').IconValue | undefined;
|
|
50
|
+
activeClass?: string | undefined;
|
|
51
|
+
appendAvatar?: string | undefined;
|
|
52
|
+
prependAvatar?: string | undefined;
|
|
53
|
+
subtitle?: string | number | boolean | undefined;
|
|
54
|
+
} & {
|
|
55
|
+
$children?: import('vue').VNodeChild | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | {
|
|
56
|
+
prepend?: ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
57
|
+
append?: ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
58
|
+
default?: ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
59
|
+
title?: ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemTitleSlot) => import('vue').VNodeChild) | undefined;
|
|
60
|
+
subtitle?: ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSubtitleSlot) => import('vue').VNodeChild) | undefined;
|
|
61
|
+
};
|
|
62
|
+
'v-slots'?: {
|
|
63
|
+
prepend?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
64
|
+
append?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
65
|
+
default?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
66
|
+
title?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemTitleSlot) => import('vue').VNodeChild) | undefined;
|
|
67
|
+
subtitle?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSubtitleSlot) => import('vue').VNodeChild) | undefined;
|
|
68
|
+
} | undefined;
|
|
69
|
+
} & {
|
|
70
|
+
"v-slot:prepend"?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
71
|
+
"v-slot:append"?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
72
|
+
"v-slot:default"?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
73
|
+
"v-slot:title"?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemTitleSlot) => import('vue').VNodeChild) | undefined;
|
|
74
|
+
"v-slot:subtitle"?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSubtitleSlot) => import('vue').VNodeChild) | undefined;
|
|
75
|
+
} & {
|
|
76
|
+
onClick?: ((e: MouseEvent | KeyboardEvent) => any) | undefined;
|
|
77
|
+
}, {
|
|
78
|
+
activate: (activated: boolean, e?: Event | undefined) => void;
|
|
79
|
+
isActivated: import('vue').ComputedRef<boolean>;
|
|
80
|
+
isGroupActivator: boolean | undefined;
|
|
81
|
+
isSelected: import('vue').ComputedRef<boolean>;
|
|
82
|
+
list: {
|
|
83
|
+
hasPrepend: import('vue').Ref<boolean, boolean>;
|
|
84
|
+
updateHasPrepend: (value: boolean) => void;
|
|
85
|
+
} | null;
|
|
86
|
+
select: (selected: boolean, e?: Event | undefined) => void;
|
|
87
|
+
root: {
|
|
88
|
+
children: import('vue').Ref<Map<unknown, unknown[]>, Map<unknown, unknown[]>>;
|
|
89
|
+
parents: import('vue').Ref<Map<unknown, unknown>, Map<unknown, unknown>>;
|
|
90
|
+
activatable: import('vue').Ref<boolean, boolean>;
|
|
91
|
+
selectable: import('vue').Ref<boolean, boolean>;
|
|
92
|
+
opened: import('vue').Ref<Set<unknown>, Set<unknown>>;
|
|
93
|
+
activated: import('vue').Ref<Set<unknown>, Set<unknown>>;
|
|
94
|
+
selected: import('vue').Ref<Map<unknown, "off" | "indeterminate" | "on">, Map<unknown, "off" | "indeterminate" | "on">>;
|
|
95
|
+
selectedValues: import('vue').Ref<unknown[], unknown[]>;
|
|
96
|
+
register: (id: unknown, parentId: unknown, isGroup?: boolean | undefined) => void;
|
|
97
|
+
unregister: (id: unknown) => void;
|
|
98
|
+
open: (id: unknown, value: boolean, event?: Event | undefined) => void;
|
|
99
|
+
activate: (id: unknown, value: boolean, event?: Event | undefined) => void;
|
|
100
|
+
select: (id: unknown, value: boolean, event?: Event | undefined) => void;
|
|
101
|
+
openOnSelect: (id: unknown, value: boolean, event?: Event | undefined) => void;
|
|
102
|
+
getPath: (id: unknown) => unknown[];
|
|
103
|
+
};
|
|
104
|
+
id: import('vue').ComputedRef<{}>;
|
|
105
|
+
link: import('vuetify/lib/composables/router.mjs').UseLink;
|
|
106
|
+
}, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
107
|
+
click: (e: MouseEvent | KeyboardEvent) => true;
|
|
108
|
+
}, import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, {
|
|
109
|
+
replace: boolean;
|
|
110
|
+
link: boolean;
|
|
111
|
+
variant: "flat" | "outlined" | "text" | "plain" | "elevated" | "tonal";
|
|
112
|
+
exact: boolean;
|
|
113
|
+
active: boolean;
|
|
114
|
+
nav: boolean;
|
|
115
|
+
style: import('vue').StyleValue;
|
|
116
|
+
title: string | number | boolean;
|
|
117
|
+
disabled: boolean;
|
|
118
|
+
tag: string | import('vuetify/lib/types.mjs').JSXComponent<any>;
|
|
119
|
+
density: import('vuetify/lib/composables/density.mjs').Density;
|
|
120
|
+
rounded: string | number | boolean;
|
|
121
|
+
tile: boolean;
|
|
122
|
+
slim: boolean;
|
|
123
|
+
ripple: boolean | {
|
|
124
|
+
class: string;
|
|
125
|
+
} | undefined;
|
|
126
|
+
subtitle: string | number | boolean;
|
|
127
|
+
}, true, {}, import('vue').SlotsType<Partial<{
|
|
128
|
+
prepend: (arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNode<import('vue').RendererNode, import('vue').RendererElement, {
|
|
129
|
+
[key: string]: any;
|
|
130
|
+
}>[];
|
|
131
|
+
append: (arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNode<import('vue').RendererNode, import('vue').RendererElement, {
|
|
132
|
+
[key: string]: any;
|
|
133
|
+
}>[];
|
|
134
|
+
default: (arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNode<import('vue').RendererNode, import('vue').RendererElement, {
|
|
135
|
+
[key: string]: any;
|
|
136
|
+
}>[];
|
|
137
|
+
title: (arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemTitleSlot) => import('vue').VNode<import('vue').RendererNode, import('vue').RendererElement, {
|
|
138
|
+
[key: string]: any;
|
|
139
|
+
}>[];
|
|
140
|
+
subtitle: (arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSubtitleSlot) => import('vue').VNode<import('vue').RendererNode, import('vue').RendererElement, {
|
|
141
|
+
[key: string]: any;
|
|
142
|
+
}>[];
|
|
143
|
+
}>>, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {}, any, import('vue').ComponentProvideOptions, {
|
|
144
|
+
P: {};
|
|
145
|
+
B: {};
|
|
146
|
+
D: {};
|
|
147
|
+
C: {};
|
|
148
|
+
M: {};
|
|
149
|
+
Defaults: {};
|
|
150
|
+
}, {
|
|
151
|
+
replace: boolean;
|
|
152
|
+
variant: "flat" | "outlined" | "text" | "plain" | "elevated" | "tonal";
|
|
153
|
+
exact: boolean;
|
|
154
|
+
nav: boolean;
|
|
155
|
+
style: import('vue').StyleValue;
|
|
156
|
+
disabled: boolean;
|
|
157
|
+
tag: string | import('vuetify/lib/types.mjs').JSXComponent<any>;
|
|
158
|
+
density: import('vuetify/lib/composables/density.mjs').Density;
|
|
159
|
+
tile: boolean;
|
|
160
|
+
slim: boolean;
|
|
161
|
+
ripple: boolean | {
|
|
162
|
+
class: string;
|
|
163
|
+
} | undefined;
|
|
164
|
+
} & {
|
|
165
|
+
link?: boolean | undefined;
|
|
166
|
+
height?: string | number | undefined;
|
|
167
|
+
width?: string | number | undefined;
|
|
168
|
+
active?: boolean | undefined;
|
|
169
|
+
border?: string | number | boolean | undefined;
|
|
170
|
+
color?: string | undefined;
|
|
171
|
+
maxHeight?: string | number | undefined;
|
|
172
|
+
maxWidth?: string | number | undefined;
|
|
173
|
+
minHeight?: string | number | undefined;
|
|
174
|
+
minWidth?: string | number | undefined;
|
|
175
|
+
value?: any;
|
|
176
|
+
title?: string | number | boolean | undefined;
|
|
177
|
+
class?: any;
|
|
178
|
+
theme?: string | undefined;
|
|
179
|
+
to?: string | import('vue-router').RouteLocationAsRelativeGeneric | import('vue-router').RouteLocationAsPathGeneric | undefined;
|
|
180
|
+
lines?: false | "one" | "two" | "three" | undefined;
|
|
181
|
+
onClick?: ((args_0: MouseEvent | KeyboardEvent) => void) | undefined;
|
|
182
|
+
onClickOnce?: ((args_0: MouseEvent) => void) | undefined;
|
|
183
|
+
href?: string | undefined;
|
|
184
|
+
elevation?: string | number | undefined;
|
|
185
|
+
rounded?: string | number | boolean | undefined;
|
|
186
|
+
baseColor?: string | undefined;
|
|
187
|
+
activeColor?: string | undefined;
|
|
188
|
+
prependIcon?: import('vuetify/lib/composables/icons.mjs').IconValue | undefined;
|
|
189
|
+
appendIcon?: import('vuetify/lib/composables/icons.mjs').IconValue | undefined;
|
|
190
|
+
activeClass?: string | undefined;
|
|
191
|
+
appendAvatar?: string | undefined;
|
|
192
|
+
prependAvatar?: string | undefined;
|
|
193
|
+
subtitle?: string | number | boolean | undefined;
|
|
194
|
+
} & {
|
|
195
|
+
$children?: import('vue').VNodeChild | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | {
|
|
196
|
+
prepend?: ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
197
|
+
append?: ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
198
|
+
default?: ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
199
|
+
title?: ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemTitleSlot) => import('vue').VNodeChild) | undefined;
|
|
200
|
+
subtitle?: ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSubtitleSlot) => import('vue').VNodeChild) | undefined;
|
|
201
|
+
};
|
|
202
|
+
'v-slots'?: {
|
|
203
|
+
prepend?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
204
|
+
append?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
205
|
+
default?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
206
|
+
title?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemTitleSlot) => import('vue').VNodeChild) | undefined;
|
|
207
|
+
subtitle?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSubtitleSlot) => import('vue').VNodeChild) | undefined;
|
|
208
|
+
} | undefined;
|
|
209
|
+
} & {
|
|
210
|
+
"v-slot:prepend"?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
211
|
+
"v-slot:append"?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
212
|
+
"v-slot:default"?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSlot) => import('vue').VNodeChild) | undefined;
|
|
213
|
+
"v-slot:title"?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemTitleSlot) => import('vue').VNodeChild) | undefined;
|
|
214
|
+
"v-slot:subtitle"?: false | ((arg: import('vuetify/lib/components/VList/VListItem.mjs').ListItemSubtitleSlot) => import('vue').VNodeChild) | undefined;
|
|
215
|
+
} & {
|
|
216
|
+
onClick?: ((e: MouseEvent | KeyboardEvent) => any) | undefined;
|
|
217
|
+
}, {
|
|
218
|
+
activate: (activated: boolean, e?: Event | undefined) => void;
|
|
219
|
+
isActivated: import('vue').ComputedRef<boolean>;
|
|
220
|
+
isGroupActivator: boolean | undefined;
|
|
221
|
+
isSelected: import('vue').ComputedRef<boolean>;
|
|
222
|
+
list: {
|
|
223
|
+
hasPrepend: import('vue').Ref<boolean, boolean>;
|
|
224
|
+
updateHasPrepend: (value: boolean) => void;
|
|
225
|
+
} | null;
|
|
226
|
+
select: (selected: boolean, e?: Event | undefined) => void;
|
|
227
|
+
root: {
|
|
228
|
+
children: import('vue').Ref<Map<unknown, unknown[]>, Map<unknown, unknown[]>>;
|
|
229
|
+
parents: import('vue').Ref<Map<unknown, unknown>, Map<unknown, unknown>>;
|
|
230
|
+
activatable: import('vue').Ref<boolean, boolean>;
|
|
231
|
+
selectable: import('vue').Ref<boolean, boolean>;
|
|
232
|
+
opened: import('vue').Ref<Set<unknown>, Set<unknown>>;
|
|
233
|
+
activated: import('vue').Ref<Set<unknown>, Set<unknown>>;
|
|
234
|
+
selected: import('vue').Ref<Map<unknown, "off" | "indeterminate" | "on">, Map<unknown, "off" | "indeterminate" | "on">>;
|
|
235
|
+
selectedValues: import('vue').Ref<unknown[], unknown[]>;
|
|
236
|
+
register: (id: unknown, parentId: unknown, isGroup?: boolean | undefined) => void;
|
|
237
|
+
unregister: (id: unknown) => void;
|
|
238
|
+
open: (id: unknown, value: boolean, event?: Event | undefined) => void;
|
|
239
|
+
activate: (id: unknown, value: boolean, event?: Event | undefined) => void;
|
|
240
|
+
select: (id: unknown, value: boolean, event?: Event | undefined) => void;
|
|
241
|
+
openOnSelect: (id: unknown, value: boolean, event?: Event | undefined) => void;
|
|
242
|
+
getPath: (id: unknown) => unknown[];
|
|
243
|
+
};
|
|
244
|
+
id: import('vue').ComputedRef<{}>;
|
|
245
|
+
link: import('vuetify/lib/composables/router.mjs').UseLink;
|
|
246
|
+
}, {}, {}, {}, {
|
|
247
|
+
replace: boolean;
|
|
248
|
+
link: boolean;
|
|
249
|
+
variant: "flat" | "outlined" | "text" | "plain" | "elevated" | "tonal";
|
|
250
|
+
exact: boolean;
|
|
251
|
+
active: boolean;
|
|
252
|
+
nav: boolean;
|
|
253
|
+
style: import('vue').StyleValue;
|
|
254
|
+
title: string | number | boolean;
|
|
255
|
+
disabled: boolean;
|
|
256
|
+
tag: string | import('vuetify/lib/types.mjs').JSXComponent<any>;
|
|
257
|
+
density: import('vuetify/lib/composables/density.mjs').Density;
|
|
258
|
+
rounded: string | number | boolean;
|
|
259
|
+
tile: boolean;
|
|
260
|
+
slim: boolean;
|
|
261
|
+
ripple: boolean | {
|
|
262
|
+
class: string;
|
|
263
|
+
} | undefined;
|
|
264
|
+
subtitle: string | number | boolean;
|
|
265
|
+
}> | null)[];
|
|
266
|
+
}, any>;
|
|
267
|
+
export default _default;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Ref } from 'vue';
|
|
2
|
-
import { DataOptions } from './types';
|
|
2
|
+
import { DataOptions, DataTableHeaders } from './types';
|
|
3
3
|
/**
|
|
4
4
|
* Interface for column width storage
|
|
5
5
|
*/
|
|
@@ -17,6 +17,45 @@ export declare function useTableStorage({ prefix, suffix, serverItemsLength, opt
|
|
|
17
17
|
}): {
|
|
18
18
|
localOptions: Ref<{}, {}>;
|
|
19
19
|
columnWidths: Ref<ColumnWidthsStorage, ColumnWidthsStorage>;
|
|
20
|
+
headers: Ref<{
|
|
21
|
+
title?: string | undefined;
|
|
22
|
+
text?: string | undefined;
|
|
23
|
+
value?: string | undefined;
|
|
24
|
+
key?: string | undefined;
|
|
25
|
+
filterable?: boolean | undefined;
|
|
26
|
+
filterType?: import('./types').FilterType | undefined;
|
|
27
|
+
filterOptions?: {
|
|
28
|
+
text: string;
|
|
29
|
+
value: unknown;
|
|
30
|
+
}[] | undefined;
|
|
31
|
+
multiple?: boolean | undefined;
|
|
32
|
+
chips?: boolean | undefined;
|
|
33
|
+
sortable?: boolean | undefined;
|
|
34
|
+
hideMessages?: boolean | undefined;
|
|
35
|
+
dateFormat?: string | undefined;
|
|
36
|
+
align?: "start" | "end" | "center" | undefined;
|
|
37
|
+
order?: number | undefined;
|
|
38
|
+
hidden?: boolean | undefined;
|
|
39
|
+
}[] | undefined, DataTableHeaders[] | {
|
|
40
|
+
title?: string | undefined;
|
|
41
|
+
text?: string | undefined;
|
|
42
|
+
value?: string | undefined;
|
|
43
|
+
key?: string | undefined;
|
|
44
|
+
filterable?: boolean | undefined;
|
|
45
|
+
filterType?: import('./types').FilterType | undefined;
|
|
46
|
+
filterOptions?: {
|
|
47
|
+
text: string;
|
|
48
|
+
value: unknown;
|
|
49
|
+
}[] | undefined;
|
|
50
|
+
multiple?: boolean | undefined;
|
|
51
|
+
chips?: boolean | undefined;
|
|
52
|
+
sortable?: boolean | undefined;
|
|
53
|
+
hideMessages?: boolean | undefined;
|
|
54
|
+
dateFormat?: string | undefined;
|
|
55
|
+
align?: "start" | "end" | "center" | undefined;
|
|
56
|
+
order?: number | undefined;
|
|
57
|
+
hidden?: boolean | undefined;
|
|
58
|
+
}[] | undefined>;
|
|
20
59
|
storageKey: import('vue').ComputedRef<string>;
|
|
21
60
|
columnWidthsKey: import('vue').ComputedRef<string>;
|
|
22
61
|
setupLocalStorage: () => {
|
|
@@ -24,6 +63,7 @@ export declare function useTableStorage({ prefix, suffix, serverItemsLength, opt
|
|
|
24
63
|
initFromStorage: (defaultOptions: Record<string, unknown>) => void;
|
|
25
64
|
saveColumnWidths: (widths: ColumnWidthsStorage) => void;
|
|
26
65
|
updateColumnWidth: (columnKey: string, width: number | string) => void;
|
|
66
|
+
saveHeaders: (headers: DataTableHeaders[] | undefined) => void;
|
|
27
67
|
};
|
|
28
68
|
updateColumnWidth: (key: string, width: number | string) => void;
|
|
29
69
|
};
|
|
@@ -3,11 +3,10 @@ import { DataOptions, TableDensityType } from './types';
|
|
|
3
3
|
/**
|
|
4
4
|
* Crée et renvoie des fonctionnalités communes pour les tableaux
|
|
5
5
|
*/
|
|
6
|
-
export declare function useTableUtils({ tableId, prefix, suffix,
|
|
6
|
+
export declare function useTableUtils({ tableId, prefix, suffix, serverItemsLength, componentAttributes, options, }: {
|
|
7
7
|
tableId: string;
|
|
8
8
|
prefix: string;
|
|
9
9
|
suffix?: string;
|
|
10
|
-
itemsPerPage?: number;
|
|
11
10
|
caption?: string;
|
|
12
11
|
serverItemsLength?: number;
|
|
13
12
|
componentAttributes: Record<string, unknown>;
|
|
@@ -17,10 +16,9 @@ export declare function useTableUtils({ tableId, prefix, suffix, itemsPerPage, s
|
|
|
17
16
|
localOptions: Ref<{}, {}>;
|
|
18
17
|
columnWidths: Ref<import('./tableStorageUtils').ColumnWidthsStorage, import('./tableStorageUtils').ColumnWidthsStorage>;
|
|
19
18
|
storageKey: import('vue').ComputedRef<string>;
|
|
20
|
-
headers: import('vue').ComputedRef<any[] | undefined>;
|
|
21
19
|
optionsFacade: import('vue').ComputedRef<{
|
|
22
20
|
page: unknown;
|
|
23
|
-
itemsPerPage: number
|
|
21
|
+
itemsPerPage: number;
|
|
24
22
|
sortBy: import('./types').SortOptions[] | undefined;
|
|
25
23
|
groupBy: import('./types').SortOptions[] | undefined;
|
|
26
24
|
multiSort: boolean | undefined;
|
|
@@ -28,7 +26,6 @@ export declare function useTableUtils({ tableId, prefix, suffix, itemsPerPage, s
|
|
|
28
26
|
}>;
|
|
29
27
|
propsFacade: import('vue').ComputedRef<{
|
|
30
28
|
itemsLength?: number | undefined;
|
|
31
|
-
headers: any[] | undefined;
|
|
32
29
|
}>;
|
|
33
30
|
updateOptions: (tableOptions: Partial<DataOptions>) => void;
|
|
34
31
|
setupAccessibility: () => void;
|
|
@@ -37,6 +34,46 @@ export declare function useTableUtils({ tableId, prefix, suffix, itemsPerPage, s
|
|
|
37
34
|
initFromStorage: (defaultOptions: Record<string, unknown>) => void;
|
|
38
35
|
saveColumnWidths: (widths: import('./tableStorageUtils').ColumnWidthsStorage) => void;
|
|
39
36
|
updateColumnWidth: (columnKey: string, width: string | number) => void;
|
|
37
|
+
saveHeaders: (headers: import('./types').DataTableHeaders[] | undefined) => void;
|
|
40
38
|
};
|
|
41
39
|
updateColumnWidth: (key: string, width: string | number) => void;
|
|
40
|
+
headers: Ref<{
|
|
41
|
+
title?: string | undefined;
|
|
42
|
+
text?: string | undefined;
|
|
43
|
+
value?: string | undefined;
|
|
44
|
+
key?: string | undefined;
|
|
45
|
+
filterable?: boolean | undefined;
|
|
46
|
+
filterType?: import('./types').FilterType | undefined;
|
|
47
|
+
filterOptions?: {
|
|
48
|
+
text: string;
|
|
49
|
+
value: unknown;
|
|
50
|
+
}[] | undefined;
|
|
51
|
+
multiple?: boolean | undefined;
|
|
52
|
+
chips?: boolean | undefined;
|
|
53
|
+
sortable?: boolean | undefined;
|
|
54
|
+
hideMessages?: boolean | undefined;
|
|
55
|
+
dateFormat?: string | undefined;
|
|
56
|
+
align?: "start" | "end" | "center" | undefined;
|
|
57
|
+
order?: number | undefined;
|
|
58
|
+
hidden?: boolean | undefined;
|
|
59
|
+
}[] | undefined, import('./types').DataTableHeaders[] | {
|
|
60
|
+
title?: string | undefined;
|
|
61
|
+
text?: string | undefined;
|
|
62
|
+
value?: string | undefined;
|
|
63
|
+
key?: string | undefined;
|
|
64
|
+
filterable?: boolean | undefined;
|
|
65
|
+
filterType?: import('./types').FilterType | undefined;
|
|
66
|
+
filterOptions?: {
|
|
67
|
+
text: string;
|
|
68
|
+
value: unknown;
|
|
69
|
+
}[] | undefined;
|
|
70
|
+
multiple?: boolean | undefined;
|
|
71
|
+
chips?: boolean | undefined;
|
|
72
|
+
sortable?: boolean | undefined;
|
|
73
|
+
hideMessages?: boolean | undefined;
|
|
74
|
+
dateFormat?: string | undefined;
|
|
75
|
+
align?: "start" | "end" | "center" | undefined;
|
|
76
|
+
order?: number | undefined;
|
|
77
|
+
hidden?: boolean | undefined;
|
|
78
|
+
}[] | undefined>;
|
|
42
79
|
};
|
|
@@ -23,6 +23,7 @@ export interface DataOptions {
|
|
|
23
23
|
}
|
|
24
24
|
export type DataTableHeaders = {
|
|
25
25
|
title?: string;
|
|
26
|
+
text?: string;
|
|
26
27
|
value?: string;
|
|
27
28
|
key?: string;
|
|
28
29
|
filterable?: boolean;
|
|
@@ -31,8 +32,14 @@ export type DataTableHeaders = {
|
|
|
31
32
|
text: string;
|
|
32
33
|
value: unknown;
|
|
33
34
|
}>;
|
|
35
|
+
multiple?: boolean;
|
|
36
|
+
chips?: boolean;
|
|
37
|
+
sortable?: boolean;
|
|
34
38
|
hideMessages?: boolean;
|
|
35
39
|
dateFormat?: string;
|
|
40
|
+
align?: 'start' | 'end' | 'center';
|
|
41
|
+
order?: number;
|
|
42
|
+
hidden?: boolean;
|
|
36
43
|
};
|
|
37
44
|
export type TableColumnHeader = {
|
|
38
45
|
title?: string;
|
|
@@ -44,6 +51,8 @@ export type TableColumnHeader = {
|
|
|
44
51
|
text: string;
|
|
45
52
|
value: unknown;
|
|
46
53
|
}>;
|
|
54
|
+
multiple?: boolean;
|
|
55
|
+
chips?: boolean;
|
|
47
56
|
hideMessages?: boolean;
|
|
48
57
|
dateFormat?: string;
|
|
49
58
|
sort?: unknown;
|
|
@@ -53,28 +62,30 @@ export type TableColumnHeader = {
|
|
|
53
62
|
children?: unknown[];
|
|
54
63
|
[key: string]: unknown;
|
|
55
64
|
};
|
|
56
|
-
export
|
|
65
|
+
export type SyTableProps = {
|
|
57
66
|
items?: Record<string, unknown>[];
|
|
58
67
|
suffix: string;
|
|
59
|
-
itemsPerPage?: number;
|
|
60
68
|
caption?: string;
|
|
61
69
|
showFilters?: boolean;
|
|
62
|
-
headers?: DataTableHeaders[];
|
|
63
70
|
filterInputConfig?: Record<string, unknown>;
|
|
64
71
|
density?: TableDensityType;
|
|
65
72
|
striped?: boolean;
|
|
66
73
|
resizableColumns?: boolean;
|
|
67
|
-
|
|
68
|
-
|
|
74
|
+
enableColumnControls?: boolean;
|
|
75
|
+
headers?: DataTableHeaders[];
|
|
76
|
+
showSelect?: boolean;
|
|
77
|
+
};
|
|
78
|
+
export type SyServerTableProps = {
|
|
69
79
|
serverItemsLength: number;
|
|
70
80
|
items?: Record<string, unknown>[];
|
|
71
81
|
suffix: string;
|
|
72
|
-
itemsPerPage?: number;
|
|
73
82
|
caption?: string;
|
|
74
83
|
showFilters?: boolean;
|
|
75
|
-
headers?: DataTableHeaders[];
|
|
76
84
|
resizableColumns?: boolean;
|
|
77
85
|
filterInputConfig?: Record<string, unknown>;
|
|
78
86
|
density?: TableDensityType;
|
|
79
87
|
striped?: boolean;
|
|
80
|
-
|
|
88
|
+
enableColumnControls?: boolean;
|
|
89
|
+
headers?: DataTableHeaders[];
|
|
90
|
+
showSelect?: boolean;
|
|
91
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
import { DataOptions } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* Composable for managing table pagination
|
|
5
|
+
*
|
|
6
|
+
* @param options - Reactive reference to table options
|
|
7
|
+
* @param itemsLength - Total number of items (for client-side) or serverItemsLength (for server-side)
|
|
8
|
+
* @param table - Reference to the table component
|
|
9
|
+
* @param emit - Emit function for update:options event
|
|
10
|
+
* @returns Pagination utilities and computed properties
|
|
11
|
+
*/
|
|
12
|
+
export declare function usePagination({ options, itemsLength, table, emit, }: {
|
|
13
|
+
options: Ref<Partial<DataOptions>>;
|
|
14
|
+
itemsLength: Ref<number>;
|
|
15
|
+
table: Ref<unknown>;
|
|
16
|
+
emit: (event: 'update:options', options: Partial<DataOptions>) => void;
|
|
17
|
+
}): {
|
|
18
|
+
page: import('vue').WritableComputedRef<number, number>;
|
|
19
|
+
pageCount: import('vue').ComputedRef<number>;
|
|
20
|
+
itemsPerPageValue: import('vue').ComputedRef<number>;
|
|
21
|
+
updateItemsPerPage: (newItemsPerPage: number) => void;
|
|
22
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { MaybeRefOrGetter } from 'vue';
|
|
2
|
+
interface UseTableCheckboxOptions {
|
|
3
|
+
/**
|
|
4
|
+
* The items to be displayed in the table
|
|
5
|
+
*/
|
|
6
|
+
items: MaybeRefOrGetter<Record<string, unknown>[]>;
|
|
7
|
+
/**
|
|
8
|
+
* The model value for selected items
|
|
9
|
+
*/
|
|
10
|
+
modelValue: MaybeRefOrGetter<unknown[]>;
|
|
11
|
+
/**
|
|
12
|
+
* Function to update the model value
|
|
13
|
+
*/
|
|
14
|
+
updateModelValue: (value: unknown[]) => void;
|
|
15
|
+
}
|
|
16
|
+
export declare function useTableCheckbox(options: UseTableCheckboxOptions): {
|
|
17
|
+
getItemValue: (item: Record<string, unknown>) => {} | null;
|
|
18
|
+
toggleAllRows: () => void;
|
|
19
|
+
};
|
|
20
|
+
export {};
|