adminforth 1.2.87 → 1.2.88
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/modules/restApi.js +9 -0
- package/dist/spa/.vscode/extensions.json +6 -0
- package/dist/spa/index.html +4 -4
- package/dist/spa/package-lock.json +6 -421
- package/dist/spa/package.json +2 -10
- package/dist/spa/public/favicon.ico +0 -0
- package/dist/spa/spa/.eslintrc.cjs +14 -0
- package/dist/spa/spa/.vscode/extensions.json +6 -0
- package/dist/spa/spa/README.md +39 -0
- package/dist/spa/spa/env.d.ts +1 -0
- package/dist/spa/spa/index.html +23 -0
- package/dist/spa/spa/package-lock.json +4573 -0
- package/dist/spa/spa/package.json +49 -0
- package/dist/spa/spa/postcss.config.js +6 -0
- package/dist/spa/spa/public/favicon.ico +0 -0
- package/dist/spa/spa/src/App.vue +314 -0
- package/dist/spa/spa/src/assets/base.css +0 -0
- package/dist/spa/spa/src/assets/logo.svg +19 -0
- package/dist/spa/spa/src/components/AcceptModal.vue +45 -0
- package/dist/spa/spa/src/components/Breadcrumbs.vue +40 -0
- package/dist/spa/spa/src/components/BreadcrumbsWithButtons.vue +26 -0
- package/dist/spa/spa/src/components/CustomDatePicker.vue +174 -0
- package/dist/spa/spa/src/components/CustomDateRangePicker.vue +218 -0
- package/dist/spa/spa/src/components/Dropdown.vue +168 -0
- package/dist/spa/spa/src/components/Filters.vue +222 -0
- package/dist/spa/spa/src/components/HelloWorld.vue +17 -0
- package/dist/spa/spa/src/components/MenuLink.vue +24 -0
- package/dist/spa/spa/src/components/ResourceForm.vue +289 -0
- package/dist/spa/{src → spa/src}/components/ResourceListTable.vue +3 -6
- package/dist/spa/spa/src/components/SingleSkeletLoader.vue +13 -0
- package/dist/spa/{src → spa/src}/components/Toast.vue +3 -9
- package/dist/spa/spa/src/components/ValueRenderer.vue +66 -0
- package/dist/spa/spa/src/components/icons/IconCalendar.vue +5 -0
- package/dist/spa/spa/src/components/icons/IconCommunity.vue +7 -0
- package/dist/spa/spa/src/components/icons/IconDocumentation.vue +7 -0
- package/dist/spa/spa/src/components/icons/IconEcosystem.vue +7 -0
- package/dist/spa/spa/src/components/icons/IconSupport.vue +7 -0
- package/dist/spa/spa/src/components/icons/IconTime.vue +5 -0
- package/dist/spa/spa/src/components/icons/IconTooling.vue +19 -0
- package/dist/spa/spa/src/index.scss +27 -0
- package/dist/spa/spa/src/main.ts +18 -0
- package/dist/spa/spa/src/router/index.ts +63 -0
- package/dist/spa/spa/src/stores/core.ts +144 -0
- package/dist/spa/spa/src/stores/modal.ts +48 -0
- package/dist/spa/spa/src/utils.ts +103 -0
- package/dist/spa/spa/src/views/CreateView.vue +156 -0
- package/dist/spa/spa/src/views/EditView.vue +157 -0
- package/dist/spa/spa/src/views/HomeView.vue +8 -0
- package/dist/spa/spa/src/views/ListView.vue +258 -0
- package/dist/spa/spa/src/views/LoginView.vue +143 -0
- package/dist/spa/spa/src/views/ResourceParent.vue +17 -0
- package/dist/spa/spa/src/views/ShowView.vue +184 -0
- package/dist/spa/spa/tailwind.config.js +17 -0
- package/dist/spa/spa/tsconfig.app.json +14 -0
- package/dist/spa/spa/tsconfig.json +11 -0
- package/dist/spa/spa/tsconfig.node.json +19 -0
- package/dist/spa/spa/vite.config.ts +56 -0
- package/dist/spa/src/App.vue +94 -236
- package/dist/spa/src/assets/base.css +0 -2
- package/dist/spa/src/assets/logo.svg +1 -19
- package/dist/spa/src/components/AcceptModal.vue +10 -3
- package/dist/spa/src/components/Breadcrumbs.vue +2 -3
- package/dist/spa/src/components/BreadcrumbsWithButtons.vue +1 -1
- package/dist/spa/src/components/CustomDatePicker.vue +10 -25
- package/dist/spa/src/components/CustomDateRangePicker.vue +5 -14
- package/dist/spa/src/components/Dropdown.vue +5 -19
- package/dist/spa/src/components/Filters.vue +38 -103
- package/dist/spa/src/components/MenuLink.vue +3 -3
- package/dist/spa/src/components/ResourceForm.vue +116 -205
- package/dist/spa/src/components/ValueRenderer.vue +8 -30
- package/dist/spa/src/index.scss +1 -2
- package/dist/spa/src/main.ts +2 -2
- package/dist/spa/src/router/index.ts +19 -29
- package/dist/spa/src/stores/core.ts +59 -65
- package/dist/spa/src/stores/modal.ts +3 -13
- package/dist/spa/src/utils.ts +10 -69
- package/dist/spa/src/views/CreateView.vue +16 -69
- package/dist/spa/src/views/EditView.vue +14 -68
- package/dist/spa/src/views/HomeView.vue +8 -0
- package/dist/spa/src/views/ListView.vue +371 -100
- package/dist/spa/src/views/LoginView.vue +29 -67
- package/dist/spa/src/views/ResourceParent.vue +2 -1
- package/dist/spa/src/views/ShowView.vue +25 -116
- package/dist/spa/tailwind.config.js +3 -8
- package/dist/spa/vite.config.ts +0 -13
- package/dist/types.js +30 -0
- package/modules/restApi.ts +14 -1
- package/package.json +1 -1
- package/spa/src/components/MenuLink.vue +3 -0
- package/types/AdminForthConfig.ts +6 -0
- package/dist/spa/src/types/AdminForthConfig.ts +0 -1477
- package/dist/spa/src/types/FrontendAPI.ts +0 -121
- /package/dist/spa/{public → spa/public}/assets/favicon.png +0 -0
- /package/dist/spa/{src → spa/src}/components/CustomRangePicker.vue +0 -0
- /package/dist/spa/{src → spa/src}/components/SkeleteLoader.vue +0 -0
- /package/dist/spa/{src → spa/src}/composables/useFrontendApi.ts +0 -0
- /package/dist/spa/{src → spa/src}/composables/useStores.ts +0 -0
- /package/dist/spa/{src → spa/src}/spa_types/core.ts +0 -0
- /package/dist/spa/{src → spa/src}/stores/filters.ts +0 -0
- /package/dist/spa/{src → spa/src}/stores/toast.ts +0 -0
- /package/dist/spa/{src → spa/src}/stores/user.ts +0 -0
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
export interface FrontendAPIInterface {
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Show a confirmation dialog
|
|
6
|
-
*
|
|
7
|
-
* The dialog will be displayed to the user
|
|
8
|
-
*
|
|
9
|
-
* Example:
|
|
10
|
-
*
|
|
11
|
-
* ```ts
|
|
12
|
-
* const isConfirmed = await window.adminforth.confirm({message: 'Are you sure?', yes: 'Yes', no: 'No'})
|
|
13
|
-
* if (isConfirmed) {
|
|
14
|
-
* your code...
|
|
15
|
-
* }
|
|
16
|
-
* ```
|
|
17
|
-
*
|
|
18
|
-
* @param params - The parameters of the dialog
|
|
19
|
-
* @returns A promise that resolves when the user confirms the dialog
|
|
20
|
-
*/
|
|
21
|
-
confirm(params:ConfirmParams ): Promise<void>;
|
|
22
|
-
/**
|
|
23
|
-
* Show an alert
|
|
24
|
-
*
|
|
25
|
-
* The alert will be displayed to the user
|
|
26
|
-
*
|
|
27
|
-
* Example:
|
|
28
|
-
*
|
|
29
|
-
* ```ts
|
|
30
|
-
* window.adminforth.alert({message: 'Hello', variant: 'success'})
|
|
31
|
-
* ```
|
|
32
|
-
*
|
|
33
|
-
* @param params - The parameters of the alert
|
|
34
|
-
*/
|
|
35
|
-
alert(params:AlertParams): void;
|
|
36
|
-
/**
|
|
37
|
-
* Add a filter to the list of filters.
|
|
38
|
-
* Works only when user located on the list page.
|
|
39
|
-
* Can be used to set filter from charts or other components in pageInjections.
|
|
40
|
-
*
|
|
41
|
-
* Example:
|
|
42
|
-
*
|
|
43
|
-
* ```ts
|
|
44
|
-
* window.adminforth.updateListFilter({field: 'name', operator: 'ilike', value: 'john'})
|
|
45
|
-
* ```
|
|
46
|
-
*
|
|
47
|
-
* @param filter - The filter to add
|
|
48
|
-
*/
|
|
49
|
-
setListFilter(filter: any): void;
|
|
50
|
-
/**
|
|
51
|
-
* Update a filter in the list of filters
|
|
52
|
-
*
|
|
53
|
-
* Example:
|
|
54
|
-
*
|
|
55
|
-
* ```ts
|
|
56
|
-
* window.adminforth.updateListFilter({field: 'name', operator: 'ilike', value: 'john'})
|
|
57
|
-
* ```
|
|
58
|
-
*
|
|
59
|
-
* @param filter - The filter to update
|
|
60
|
-
*/
|
|
61
|
-
updateListFilter(filter: any): void;
|
|
62
|
-
/**
|
|
63
|
-
* Clear all filters from the list
|
|
64
|
-
*/
|
|
65
|
-
clearListFilters(): void;
|
|
66
|
-
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
export type ConfirmParams = {
|
|
70
|
-
/**
|
|
71
|
-
* The message to display in the dialog
|
|
72
|
-
*/
|
|
73
|
-
message?: string;
|
|
74
|
-
/**
|
|
75
|
-
* The text to display in the "accept" button
|
|
76
|
-
*/
|
|
77
|
-
yes?: string;
|
|
78
|
-
/**
|
|
79
|
-
* The text to display in the "cancel" button
|
|
80
|
-
*/
|
|
81
|
-
no?: string;
|
|
82
|
-
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
export type AlertParams = {
|
|
86
|
-
/**
|
|
87
|
-
* The message to display in the alert
|
|
88
|
-
*/
|
|
89
|
-
message?: string;
|
|
90
|
-
|
|
91
|
-
/**
|
|
92
|
-
* The message to display in the alert as HTML (can be used instead of message)
|
|
93
|
-
*/
|
|
94
|
-
messageHtml?: string;
|
|
95
|
-
|
|
96
|
-
/**
|
|
97
|
-
* The variant of the alert
|
|
98
|
-
*/
|
|
99
|
-
variant?: AlertVariant | keyof typeof AlertVariant;
|
|
100
|
-
|
|
101
|
-
/**
|
|
102
|
-
* The timeout of the alert in seconds or 'unlimited' to keep the alert open until the user closes it.
|
|
103
|
-
* Default is 10 seconds;
|
|
104
|
-
*/
|
|
105
|
-
timeout?: number | 'unlimited';
|
|
106
|
-
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
export enum AlertVariant {
|
|
112
|
-
danger = 'danger',
|
|
113
|
-
success = 'success',
|
|
114
|
-
warning = 'warning',
|
|
115
|
-
info = 'info'
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|