@panneau/core 4.0.11 → 4.0.15
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/contexts.d.ts +450 -0
- package/{es → dist}/contexts.js +170 -170
- package/dist/hooks.d.ts +362 -0
- package/{es → dist}/hooks.js +60 -60
- package/dist/index.d.ts +502 -0
- package/{es → dist}/index.js +7 -258
- package/dist/utils.d.ts +207 -0
- package/{es → dist}/utils.js +56 -57
- package/package.json +23 -23
- package/es/types/core.d.ts +0 -133
- package/es/types/form.d.ts +0 -58
- package/es/types/index.d.ts +0 -20
- package/es/types/panneau.d.ts +0 -50
- package/es/types/resource.d.ts +0 -112
- package/lib/contexts.js +0 -1432
- package/lib/hooks.js +0 -1168
- package/lib/index.js +0 -1019
- package/lib/utils.js +0 -789
package/es/types/resource.d.ts
DELETED
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Resource Types
|
|
3
|
-
* TypeScript interfaces for resources, items, users, media, and other entities
|
|
4
|
-
*/
|
|
5
|
-
import { Field } from './form';
|
|
6
|
-
|
|
7
|
-
export interface Action {
|
|
8
|
-
id?: string;
|
|
9
|
-
component?: string;
|
|
10
|
-
label?: string | null;
|
|
11
|
-
icon?: string | null;
|
|
12
|
-
href?: string | null;
|
|
13
|
-
external?: boolean;
|
|
14
|
-
theme?: string;
|
|
15
|
-
target?: string;
|
|
16
|
-
onClick?: (() => void) | null;
|
|
17
|
-
endpoint?: string | null;
|
|
18
|
-
withConfirmation?: boolean;
|
|
19
|
-
[key: string]: unknown;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
export type ActionDefinition = string | Action;
|
|
23
|
-
|
|
24
|
-
type ActionValue = Item | Item[] | null;
|
|
25
|
-
|
|
26
|
-
/**
|
|
27
|
-
* Internationalization configuration
|
|
28
|
-
*/
|
|
29
|
-
export interface Intl {
|
|
30
|
-
locale?: string;
|
|
31
|
-
messages?: Record<string, string>;
|
|
32
|
-
values?: Record<string, string>;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
/**
|
|
36
|
-
* Resource definition
|
|
37
|
-
*/
|
|
38
|
-
export interface Resource {
|
|
39
|
-
id: string;
|
|
40
|
-
name: string;
|
|
41
|
-
intl?: Intl;
|
|
42
|
-
fields?: Field[];
|
|
43
|
-
forms?: Record<string, unknown>;
|
|
44
|
-
shows_in_navbar?: boolean;
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
/**
|
|
48
|
-
* Generic item (base interface for data items)
|
|
49
|
-
*/
|
|
50
|
-
export interface Item {
|
|
51
|
-
id: string;
|
|
52
|
-
[key: string]: unknown;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
/**
|
|
56
|
-
* User definition
|
|
57
|
-
*/
|
|
58
|
-
export interface User {
|
|
59
|
-
id?: number | string;
|
|
60
|
-
[key: string]: unknown;
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
/**
|
|
64
|
-
* Media file definition
|
|
65
|
-
*/
|
|
66
|
-
export interface Media {
|
|
67
|
-
id: string;
|
|
68
|
-
name: string;
|
|
69
|
-
type: string;
|
|
70
|
-
thumbnail_url?: string;
|
|
71
|
-
[key: string]: unknown;
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
/**
|
|
75
|
-
* Preview definition
|
|
76
|
-
*/
|
|
77
|
-
export interface Preview {
|
|
78
|
-
id?: string;
|
|
79
|
-
[key: string]: unknown;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
/**
|
|
83
|
-
* Modal definition
|
|
84
|
-
*/
|
|
85
|
-
export interface Modal {
|
|
86
|
-
name?: string;
|
|
87
|
-
[key: string]: unknown;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
/**
|
|
91
|
-
* Filter definition
|
|
92
|
-
*/
|
|
93
|
-
export interface Filter {
|
|
94
|
-
id?: string;
|
|
95
|
-
component?: string;
|
|
96
|
-
[key: string]: unknown;
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
/**
|
|
100
|
-
* Uppy configuration
|
|
101
|
-
*/
|
|
102
|
-
export interface Uppy {
|
|
103
|
-
tus?: Record<string, unknown>;
|
|
104
|
-
[key: string]: unknown;
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
/**
|
|
108
|
-
* Uppy instance
|
|
109
|
-
*/
|
|
110
|
-
export interface uppy {
|
|
111
|
-
[key: string]: unknown;
|
|
112
|
-
}
|