@aerogel/core 0.0.0-next.7f6ed5a1f91688a86bf5ede2adc465e4fd6cfdea → 0.0.0-next.88c59e62f64db70aedfbc4c31b5bbc287be44483

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 (91) hide show
  1. package/dist/aerogel-core.cjs.js +1 -1
  2. package/dist/aerogel-core.cjs.js.map +1 -1
  3. package/dist/aerogel-core.d.ts +830 -104
  4. package/dist/aerogel-core.esm.js +1 -1
  5. package/dist/aerogel-core.esm.js.map +1 -1
  6. package/dist/virtual.d.ts +11 -0
  7. package/noeldemartin.config.js +4 -1
  8. package/package.json +7 -9
  9. package/src/bootstrap/bootstrap.test.ts +0 -56
  10. package/src/bootstrap/index.ts +12 -25
  11. package/src/bootstrap/options.ts +5 -1
  12. package/src/components/AGAppModals.vue +15 -0
  13. package/src/components/AGAppOverlays.vue +5 -7
  14. package/src/components/AGAppSnackbars.vue +13 -0
  15. package/src/components/basic/AGErrorMessage.vue +16 -0
  16. package/src/components/basic/AGLink.vue +9 -0
  17. package/src/components/basic/AGMarkdown.vue +21 -5
  18. package/src/components/basic/index.ts +3 -1
  19. package/src/components/constants.ts +8 -0
  20. package/src/components/forms/AGButton.vue +36 -3
  21. package/src/components/forms/AGCheckbox.vue +35 -0
  22. package/src/components/forms/AGInput.vue +8 -4
  23. package/src/components/forms/index.ts +4 -5
  24. package/src/components/headless/forms/AGHeadlessButton.vue +7 -7
  25. package/src/components/headless/forms/AGHeadlessInput.ts +2 -2
  26. package/src/components/headless/forms/AGHeadlessInput.vue +6 -6
  27. package/src/components/headless/forms/AGHeadlessInputError.vue +9 -5
  28. package/src/components/headless/forms/AGHeadlessInputInput.vue +20 -4
  29. package/src/components/headless/forms/AGHeadlessInputLabel.vue +16 -0
  30. package/src/components/headless/forms/AGHeadlessSelect.ts +31 -0
  31. package/src/components/headless/forms/AGHeadlessSelect.vue +45 -0
  32. package/src/components/headless/forms/AGHeadlessSelectButton.ts +3 -0
  33. package/src/components/headless/forms/AGHeadlessSelectLabel.ts +3 -0
  34. package/src/components/headless/forms/AGHeadlessSelectOption.ts +8 -0
  35. package/src/components/headless/forms/AGHeadlessSelectOptions.ts +3 -0
  36. package/src/components/headless/forms/index.ts +12 -4
  37. package/src/components/headless/index.ts +1 -0
  38. package/src/components/headless/modals/AGHeadlessModal.vue +5 -1
  39. package/src/components/headless/modals/AGHeadlessModalPanel.vue +10 -2
  40. package/src/components/headless/snackbars/AGHeadlessSnackbar.vue +10 -0
  41. package/src/components/headless/snackbars/index.ts +25 -0
  42. package/src/components/index.ts +4 -1
  43. package/src/components/modals/AGAlertModal.vue +12 -2
  44. package/src/components/modals/AGConfirmModal.vue +30 -0
  45. package/src/components/modals/AGErrorReportModal.ts +20 -0
  46. package/src/components/modals/AGErrorReportModal.vue +62 -0
  47. package/src/components/modals/AGErrorReportModalButtons.vue +109 -0
  48. package/src/components/modals/AGErrorReportModalTitle.vue +25 -0
  49. package/src/components/modals/AGLoadingModal.vue +19 -0
  50. package/src/components/modals/AGModal.ts +4 -0
  51. package/src/components/modals/AGModal.vue +23 -4
  52. package/src/components/modals/AGModalTitle.vue +9 -0
  53. package/src/components/modals/index.ts +20 -2
  54. package/src/components/snackbars/AGSnackbar.vue +42 -0
  55. package/src/components/snackbars/index.ts +3 -0
  56. package/src/directives/index.ts +19 -4
  57. package/src/errors/Errors.state.ts +31 -0
  58. package/src/errors/Errors.ts +183 -0
  59. package/src/errors/index.ts +59 -0
  60. package/src/forms/Form.test.ts +21 -0
  61. package/src/forms/Form.ts +41 -16
  62. package/src/forms/utils.ts +17 -0
  63. package/src/lang/Lang.ts +47 -8
  64. package/src/lang/index.ts +17 -76
  65. package/src/lang/utils.ts +4 -0
  66. package/src/main.ts +2 -0
  67. package/src/plugins/Plugin.ts +8 -0
  68. package/src/plugins/index.ts +26 -0
  69. package/src/services/App.state.ts +18 -0
  70. package/src/services/App.ts +20 -0
  71. package/src/services/Service.ts +157 -29
  72. package/src/services/index.ts +32 -7
  73. package/src/services/store.ts +27 -0
  74. package/src/types/virtual.d.ts +11 -0
  75. package/src/types/vite.d.ts +0 -2
  76. package/src/ui/UI.state.ts +12 -6
  77. package/src/ui/UI.ts +72 -10
  78. package/src/ui/index.ts +24 -14
  79. package/src/utils/composition/forms.ts +11 -0
  80. package/src/utils/composition/hooks.ts +9 -0
  81. package/src/utils/index.ts +3 -0
  82. package/src/utils/markdown.ts +11 -2
  83. package/src/utils/vue.ts +4 -2
  84. package/tsconfig.json +2 -10
  85. package/vite.config.ts +3 -6
  86. package/src/bootstrap/hooks.ts +0 -19
  87. package/src/lang/helpers.ts +0 -5
  88. package/src/models/index.ts +0 -18
  89. package/src/routing/index.ts +0 -33
  90. package/src/testing/stubs/lang/en.yaml +0 -1
  91. package/src/testing/stubs/models/User.ts +0 -3
@@ -1,16 +1,22 @@
1
+ import { ListboxButton as AGHeadlessSelectButton } from '@headlessui/vue';
2
+ import { ListboxLabel as AGHeadlessSelectLabel } from '@headlessui/vue';
3
+ import { ListboxOption as AGHeadlessSelectOption } from '@headlessui/vue';
4
+ import { ListboxOptions as AGHeadlessSelectOptions } from '@headlessui/vue';
1
5
  import { AllowedComponentProps } from 'vue';
2
- import type { App } from 'vue';
6
+ import type { App as App_2 } from 'vue';
3
7
  import type { Component } from 'vue';
4
8
  import { ComponentCustomProps } from 'vue';
5
9
  import { ComponentOptionsMixin } from 'vue';
10
+ import type { ComputedRef } from 'vue';
6
11
  import { Constructor } from '@noeldemartin/utils';
7
12
  import type { DeepReadonly } from 'vue';
8
13
  import { DefineComponent } from 'vue';
9
14
  import type { Directive } from 'vue';
10
15
  import { ExtractPropTypes } from 'vue';
11
16
  import { Facade } from '@noeldemartin/utils';
17
+ import type { GetClosureArgs } from '@noeldemartin/utils';
12
18
  import type { InjectionKey } from 'vue';
13
- import type { LocationQuery } from 'vue-router';
19
+ import type { JSError } from '@noeldemartin/utils';
14
20
  import { MagicObject } from '@noeldemartin/utils';
15
21
  import type { ObjectValues } from '@noeldemartin/utils';
16
22
  import { PromisedValue } from '@noeldemartin/utils';
@@ -18,22 +24,210 @@ import { PropType } from 'vue';
18
24
  import type { Ref } from 'vue';
19
25
  import { RendererElement } from 'vue';
20
26
  import { RendererNode } from 'vue';
21
- import type { RouteParams } from 'vue-router';
22
27
  import type { UnwrapNestedRefs } from 'vue';
23
28
  import { VNode } from 'vue';
24
29
  import { VNodeProps } from 'vue';
25
30
 
31
+ declare interface AerogelOptions {
32
+ plugins?: Plugin_2[];
33
+ }
34
+
35
+ export declare const AGAlertModal: DefineComponent< {
36
+ title: {
37
+ type?: PropType<string | null> | undefined;
38
+ validator?(value: unknown): boolean;
39
+ } & {
40
+ default: string | (() => string | null) | null;
41
+ };
42
+ message: {
43
+ type?: PropType<string> | undefined;
44
+ validator?(value: unknown): boolean;
45
+ } & {
46
+ required: true;
47
+ };
48
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
49
+ [key: string]: any;
50
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
51
+ title: {
52
+ type?: PropType<string | null> | undefined;
53
+ validator?(value: unknown): boolean;
54
+ } & {
55
+ default: string | (() => string | null) | null;
56
+ };
57
+ message: {
58
+ type?: PropType<string> | undefined;
59
+ validator?(value: unknown): boolean;
60
+ } & {
61
+ required: true;
62
+ };
63
+ }>>, {
64
+ title: string | null;
65
+ }, {}>;
66
+
26
67
  export declare const AGAppLayout: DefineComponent< {}, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
27
68
  [key: string]: any;
28
69
  }>, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {}>>, {}, {}>;
29
70
 
30
- export declare const AGButton: DefineComponent< {}, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
71
+ export declare const AGAppOverlays: DefineComponent< {}, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
31
72
  [key: string]: any;
32
73
  }>, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {}>>, {}, {}>;
33
74
 
75
+ export declare const AGButton: DefineComponent< {
76
+ color: {
77
+ type?: PropType<"primary" | "secondary" | "danger" | "clear"> | undefined;
78
+ validator?(value: unknown): boolean;
79
+ } & {
80
+ default: "primary" | "secondary" | "danger" | "clear" | (() => "primary" | "secondary" | "danger" | "clear") | null;
81
+ };
82
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
83
+ [key: string]: any;
84
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
85
+ color: {
86
+ type?: PropType<"primary" | "secondary" | "danger" | "clear"> | undefined;
87
+ validator?(value: unknown): boolean;
88
+ } & {
89
+ default: "primary" | "secondary" | "danger" | "clear" | (() => "primary" | "secondary" | "danger" | "clear") | null;
90
+ };
91
+ }>>, {
92
+ color: "primary" | "secondary" | "danger" | "clear";
93
+ }, {}>;
94
+
95
+ export declare const AGCheckbox: DefineComponent< {
96
+ name: {
97
+ type?: PropType<string | null> | undefined;
98
+ validator?(value: unknown): boolean;
99
+ } & {
100
+ default: string | (() => string | null) | null;
101
+ };
102
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
103
+ [key: string]: any;
104
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
105
+ name: {
106
+ type?: PropType<string | null> | undefined;
107
+ validator?(value: unknown): boolean;
108
+ } & {
109
+ default: string | (() => string | null) | null;
110
+ };
111
+ }>>, {
112
+ name: string | null;
113
+ }, {}>;
114
+
115
+ export declare const AGConfirmModal: DefineComponent< {
116
+ title: {
117
+ type?: PropType<string | null> | undefined;
118
+ validator?(value: unknown): boolean;
119
+ } & {
120
+ default: string | (() => string | null) | null;
121
+ };
122
+ message: {
123
+ type?: PropType<string> | undefined;
124
+ validator?(value: unknown): boolean;
125
+ } & {
126
+ required: true;
127
+ };
128
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
129
+ [key: string]: any;
130
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
131
+ title: {
132
+ type?: PropType<string | null> | undefined;
133
+ validator?(value: unknown): boolean;
134
+ } & {
135
+ default: string | (() => string | null) | null;
136
+ };
137
+ message: {
138
+ type?: PropType<string> | undefined;
139
+ validator?(value: unknown): boolean;
140
+ } & {
141
+ required: true;
142
+ };
143
+ }>>, {
144
+ title: string | null;
145
+ }, {}>;
146
+
147
+ export declare const AGErrorMessage: DefineComponent< {
148
+ error: {
149
+ type?: PropType<unknown> | undefined;
150
+ validator?(value: unknown): boolean;
151
+ } & {
152
+ required: true;
153
+ };
154
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
155
+ [key: string]: any;
156
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
157
+ error: {
158
+ type?: PropType<unknown> | undefined;
159
+ validator?(value: unknown): boolean;
160
+ } & {
161
+ required: true;
162
+ };
163
+ }>>, {}, {}>;
164
+
165
+ export declare const AGErrorReportModalButtons: DefineComponent< {
166
+ report: {
167
+ type?: PropType<ErrorReport> | undefined;
168
+ validator?(value: unknown): boolean;
169
+ } & {
170
+ required: true;
171
+ };
172
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
173
+ [key: string]: any;
174
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
175
+ report: {
176
+ type?: PropType<ErrorReport> | undefined;
177
+ validator?(value: unknown): boolean;
178
+ } & {
179
+ required: true;
180
+ };
181
+ }>>, {}, {}>;
182
+
183
+ export declare const AGErrorReportModalTitle: DefineComponent< {
184
+ report: {
185
+ type?: PropType<ErrorReport> | undefined;
186
+ validator?(value: unknown): boolean;
187
+ } & {
188
+ required: true;
189
+ };
190
+ currentReport: {
191
+ type?: PropType<number | null> | undefined;
192
+ validator?(value: unknown): boolean;
193
+ } & {
194
+ default: number | (() => number | null) | null;
195
+ };
196
+ totalReports: {
197
+ type?: PropType<number | null> | undefined;
198
+ validator?(value: unknown): boolean;
199
+ } & {
200
+ default: number | (() => number | null) | null;
201
+ };
202
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
203
+ [key: string]: any;
204
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
205
+ report: {
206
+ type?: PropType<ErrorReport> | undefined;
207
+ validator?(value: unknown): boolean;
208
+ } & {
209
+ required: true;
210
+ };
211
+ currentReport: {
212
+ type?: PropType<number | null> | undefined;
213
+ validator?(value: unknown): boolean;
214
+ } & {
215
+ default: number | (() => number | null) | null;
216
+ };
217
+ totalReports: {
218
+ type?: PropType<number | null> | undefined;
219
+ validator?(value: unknown): boolean;
220
+ } & {
221
+ default: number | (() => number | null) | null;
222
+ };
223
+ }>>, {
224
+ currentReport: number | null;
225
+ totalReports: number | null;
226
+ }, {}>;
227
+
34
228
  export declare const AGForm: DefineComponent< {
35
229
  form: {
36
- type: PropType<Form<FormFieldDefinitions> | null>;
230
+ type?: PropType<Form<FormFieldDefinitions> | null> | undefined;
37
231
  validator?(value: unknown): boolean;
38
232
  } & {
39
233
  default: Form<FormFieldDefinitions> | (() => Form<FormFieldDefinitions> | null) | null;
@@ -42,7 +236,7 @@ default: Form<FormFieldDefinitions> | (() => Form<FormFieldDefinitions> | null)
42
236
  [key: string]: any;
43
237
  }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, "submit"[], "submit", VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
44
238
  form: {
45
- type: PropType<Form<FormFieldDefinitions> | null>;
239
+ type?: PropType<Form<FormFieldDefinitions> | null> | undefined;
46
240
  validator?(value: unknown): boolean;
47
241
  } & {
48
242
  default: Form<FormFieldDefinitions> | (() => Form<FormFieldDefinitions> | null) | null;
@@ -54,32 +248,38 @@ form: Form<FormFieldDefinitions> | null;
54
248
  }, {}>;
55
249
 
56
250
  export declare const AGHeadlessButton: DefineComponent< {
251
+ href: {
252
+ type?: PropType<string | null> | undefined;
253
+ validator?(value: unknown): boolean;
254
+ } & {
255
+ default: string | (() => string | null) | null;
256
+ };
57
257
  url: {
58
- type: PropType<string | null>;
258
+ type?: PropType<string | null> | undefined;
59
259
  validator?(value: unknown): boolean;
60
260
  } & {
61
261
  default: string | (() => string | null) | null;
62
262
  };
63
263
  route: {
64
- type: PropType<string | null>;
264
+ type?: PropType<string | null> | undefined;
65
265
  validator?(value: unknown): boolean;
66
266
  } & {
67
267
  default: string | (() => string | null) | null;
68
268
  };
69
269
  routeParams: {
70
- type: PropType<RouteParams>;
270
+ type?: PropType< {}> | undefined;
71
271
  validator?(value: unknown): boolean;
72
272
  } & {
73
- default: RouteParams | (() => RouteParams) | null;
273
+ default: {} | (() => {}) | null;
74
274
  };
75
275
  routeQuery: {
76
- type: PropType<LocationQuery>;
276
+ type?: PropType< {}> | undefined;
77
277
  validator?(value: unknown): boolean;
78
278
  } & {
79
- default: LocationQuery | (() => LocationQuery) | null;
279
+ default: {} | (() => {}) | null;
80
280
  };
81
281
  submit: {
82
- type: PropType<boolean>;
282
+ type?: PropType<boolean> | undefined;
83
283
  validator?(value: unknown): boolean;
84
284
  } & {
85
285
  default: boolean | (() => boolean) | null;
@@ -87,95 +287,130 @@ default: boolean | (() => boolean) | null;
87
287
  }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
88
288
  [key: string]: any;
89
289
  }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
290
+ href: {
291
+ type?: PropType<string | null> | undefined;
292
+ validator?(value: unknown): boolean;
293
+ } & {
294
+ default: string | (() => string | null) | null;
295
+ };
90
296
  url: {
91
- type: PropType<string | null>;
297
+ type?: PropType<string | null> | undefined;
92
298
  validator?(value: unknown): boolean;
93
299
  } & {
94
300
  default: string | (() => string | null) | null;
95
301
  };
96
302
  route: {
97
- type: PropType<string | null>;
303
+ type?: PropType<string | null> | undefined;
98
304
  validator?(value: unknown): boolean;
99
305
  } & {
100
306
  default: string | (() => string | null) | null;
101
307
  };
102
308
  routeParams: {
103
- type: PropType<RouteParams>;
309
+ type?: PropType< {}> | undefined;
104
310
  validator?(value: unknown): boolean;
105
311
  } & {
106
- default: RouteParams | (() => RouteParams) | null;
312
+ default: {} | (() => {}) | null;
107
313
  };
108
314
  routeQuery: {
109
- type: PropType<LocationQuery>;
315
+ type?: PropType< {}> | undefined;
110
316
  validator?(value: unknown): boolean;
111
317
  } & {
112
- default: LocationQuery | (() => LocationQuery) | null;
318
+ default: {} | (() => {}) | null;
113
319
  };
114
320
  submit: {
115
- type: PropType<boolean>;
321
+ type?: PropType<boolean> | undefined;
116
322
  validator?(value: unknown): boolean;
117
323
  } & {
118
324
  default: boolean | (() => boolean) | null;
119
325
  };
120
326
  }>>, {
327
+ href: string | null;
121
328
  url: string | null;
122
329
  route: string | null;
123
- routeParams: RouteParams;
124
- routeQuery: LocationQuery;
330
+ routeParams: {};
331
+ routeQuery: {};
125
332
  submit: boolean;
126
333
  }, {}>;
127
334
 
128
335
  export declare const AGHeadlessInput: DefineComponent< {
129
336
  as: {
130
- type: PropType<string | null>;
337
+ type?: PropType<string> | undefined;
131
338
  validator?(value: unknown): boolean;
132
339
  } & {
133
- default: string | (() => string | null) | null;
340
+ default: string | (() => string) | null;
134
341
  };
135
342
  name: {
136
- type: PropType<string | null>;
343
+ type?: PropType<string | null> | undefined;
137
344
  validator?(value: unknown): boolean;
138
345
  } & {
139
346
  default: string | (() => string | null) | null;
140
347
  };
141
348
  modelValue: {
142
- type: PropType<string | null>;
349
+ type?: PropType<string | number | boolean | null> | undefined;
143
350
  validator?(value: unknown): boolean;
144
351
  } & {
145
- default: string | (() => string | null) | null;
352
+ default: string | number | boolean | (() => string | number | boolean | null) | null;
146
353
  };
147
354
  }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
148
355
  [key: string]: any;
149
356
  }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, "update:modelValue"[], "update:modelValue", VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
150
357
  as: {
151
- type: PropType<string | null>;
358
+ type?: PropType<string> | undefined;
152
359
  validator?(value: unknown): boolean;
153
360
  } & {
154
- default: string | (() => string | null) | null;
361
+ default: string | (() => string) | null;
155
362
  };
156
363
  name: {
157
- type: PropType<string | null>;
364
+ type?: PropType<string | null> | undefined;
158
365
  validator?(value: unknown): boolean;
159
366
  } & {
160
367
  default: string | (() => string | null) | null;
161
368
  };
162
369
  modelValue: {
163
- type: PropType<string | null>;
370
+ type?: PropType<string | number | boolean | null> | undefined;
164
371
  validator?(value: unknown): boolean;
165
372
  } & {
166
- default: string | (() => string | null) | null;
373
+ default: string | number | boolean | (() => string | number | boolean | null) | null;
167
374
  };
168
375
  }>> & {
169
376
  "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
170
377
  }, {
171
- as: string | null;
378
+ as: string;
172
379
  name: string | null;
173
- modelValue: string | null;
380
+ modelValue: string | number | boolean | null;
174
381
  }, {}>;
175
382
 
383
+ export declare const AGHeadlessInputError: DefineComponent< {}, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
384
+ [key: string]: any;
385
+ }>, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {}>>, {}, {}>;
386
+
387
+ export declare const AGHeadlessInputInput: DefineComponent< {
388
+ type: {
389
+ type?: PropType<string> | undefined;
390
+ validator?(value: unknown): boolean;
391
+ } & {
392
+ default: string | (() => string) | null;
393
+ };
394
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
395
+ [key: string]: any;
396
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
397
+ type: {
398
+ type?: PropType<string> | undefined;
399
+ validator?(value: unknown): boolean;
400
+ } & {
401
+ default: string | (() => string) | null;
402
+ };
403
+ }>>, {
404
+ type: string;
405
+ }, {}>;
406
+
407
+ export declare const AGHeadlessInputLabel: DefineComponent< {}, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
408
+ [key: string]: any;
409
+ }>, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {}>>, {}, {}>;
410
+
176
411
  export declare const AGHeadlessModal: DefineComponent< {
177
412
  cancellable: {
178
- type: PropType<boolean>;
413
+ type?: PropType<boolean> | undefined;
179
414
  validator?(value: unknown): boolean;
180
415
  } & {
181
416
  default: boolean | (() => boolean) | null;
@@ -184,7 +419,7 @@ default: boolean | (() => boolean) | null;
184
419
  [key: string]: any;
185
420
  }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
186
421
  cancellable: {
187
- type: PropType<boolean>;
422
+ type?: PropType<boolean> | undefined;
188
423
  validator?(value: unknown): boolean;
189
424
  } & {
190
425
  default: boolean | (() => boolean) | null;
@@ -199,7 +434,7 @@ export declare const AGHeadlessModalPanel: DefineComponent< {}, (_ctx: any, _
199
434
 
200
435
  export declare const AGHeadlessModalTitle: DefineComponent< {
201
436
  as: {
202
- type: PropType<string>;
437
+ type?: PropType<string> | undefined;
203
438
  validator?(value: unknown): boolean;
204
439
  } & {
205
440
  default: string | (() => string) | null;
@@ -208,7 +443,7 @@ default: string | (() => string) | null;
208
443
  [key: string]: any;
209
444
  }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
210
445
  as: {
211
- type: PropType<string>;
446
+ type?: PropType<string> | undefined;
212
447
  validator?(value: unknown): boolean;
213
448
  } & {
214
449
  default: string | (() => string) | null;
@@ -217,9 +452,68 @@ default: string | (() => string) | null;
217
452
  as: string;
218
453
  }, {}>;
219
454
 
455
+ export declare const AGHeadlessSelect: DefineComponent< {
456
+ options: {
457
+ type?: PropType<SelectOptionValue[]> | undefined;
458
+ validator?(value: unknown): boolean;
459
+ } & {
460
+ required: true;
461
+ };
462
+ name: {
463
+ type?: PropType<string | null> | undefined;
464
+ validator?(value: unknown): boolean;
465
+ } & {
466
+ default: string | (() => string | null) | null;
467
+ };
468
+ modelValue: {
469
+ type?: PropType<SelectOptionValue> | undefined;
470
+ validator?(value: unknown): boolean;
471
+ } & {
472
+ default: SelectOptionValue | (() => SelectOptionValue);
473
+ };
474
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
475
+ [key: string]: any;
476
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, "update:modelValue"[], "update:modelValue", VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
477
+ options: {
478
+ type?: PropType<SelectOptionValue[]> | undefined;
479
+ validator?(value: unknown): boolean;
480
+ } & {
481
+ required: true;
482
+ };
483
+ name: {
484
+ type?: PropType<string | null> | undefined;
485
+ validator?(value: unknown): boolean;
486
+ } & {
487
+ default: string | (() => string | null) | null;
488
+ };
489
+ modelValue: {
490
+ type?: PropType<SelectOptionValue> | undefined;
491
+ validator?(value: unknown): boolean;
492
+ } & {
493
+ default: SelectOptionValue | (() => SelectOptionValue);
494
+ };
495
+ }>> & {
496
+ "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
497
+ }, {
498
+ name: string | null;
499
+ modelValue: SelectOptionValue;
500
+ }, {}>;
501
+
502
+ export { AGHeadlessSelectButton }
503
+
504
+ export { AGHeadlessSelectLabel }
505
+
506
+ export { AGHeadlessSelectOption }
507
+
508
+ export { AGHeadlessSelectOptions }
509
+
510
+ export declare const AGHeadlessSnackbar: DefineComponent< {}, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
511
+ [key: string]: any;
512
+ }>, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {}>>, {}, {}>;
513
+
220
514
  export declare const AGInput: DefineComponent< {
221
515
  name: {
222
- type: PropType<string | null>;
516
+ type?: PropType<string | null> | undefined;
223
517
  validator?(value: unknown): boolean;
224
518
  } & {
225
519
  default: string | (() => string | null) | null;
@@ -228,7 +522,7 @@ default: string | (() => string | null) | null;
228
522
  [key: string]: any;
229
523
  }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
230
524
  name: {
231
- type: PropType<string | null>;
525
+ type?: PropType<string | null> | undefined;
232
526
  validator?(value: unknown): boolean;
233
527
  } & {
234
528
  default: string | (() => string | null) | null;
@@ -237,15 +531,57 @@ default: string | (() => string | null) | null;
237
531
  name: string | null;
238
532
  }, {}>;
239
533
 
534
+ export declare const AGLink: DefineComponent< {}, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
535
+ [key: string]: any;
536
+ }>, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {}>>, {}, {}>;
537
+
538
+ export declare const AGLoadingModal: DefineComponent< {
539
+ message: {
540
+ type?: PropType<string | null> | undefined;
541
+ validator?(value: unknown): boolean;
542
+ } & {
543
+ default: string | (() => string | null) | null;
544
+ };
545
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
546
+ [key: string]: any;
547
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
548
+ message: {
549
+ type?: PropType<string | null> | undefined;
550
+ validator?(value: unknown): boolean;
551
+ } & {
552
+ default: string | (() => string | null) | null;
553
+ };
554
+ }>>, {
555
+ message: string | null;
556
+ }, {}>;
557
+
240
558
  export declare const AGMarkdown: DefineComponent< {
559
+ as: {
560
+ type?: PropType<string | null> | undefined;
561
+ validator?(value: unknown): boolean;
562
+ } & {
563
+ default: string | (() => string | null) | null;
564
+ };
565
+ inline: {
566
+ type?: PropType<boolean> | undefined;
567
+ validator?(value: unknown): boolean;
568
+ } & {
569
+ default: boolean | (() => boolean) | null;
570
+ };
241
571
  langKey: {
242
- type: PropType<string | null>;
572
+ type?: PropType<string | null> | undefined;
243
573
  validator?(value: unknown): boolean;
244
574
  } & {
245
575
  default: string | (() => string | null) | null;
246
576
  };
577
+ langParams: {
578
+ type?: PropType<Record<string, unknown> | null> | undefined;
579
+ validator?(value: unknown): boolean;
580
+ } & {
581
+ default: Record<string, unknown> | (() => Record<string, unknown> | null) | null;
582
+ };
247
583
  text: {
248
- type: PropType<string | null>;
584
+ type?: PropType<string | null> | undefined;
249
585
  validator?(value: unknown): boolean;
250
586
  } & {
251
587
  default: string | (() => string | null) | null;
@@ -253,36 +589,73 @@ default: string | (() => string | null) | null;
253
589
  }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
254
590
  [key: string]: any;
255
591
  }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
592
+ as: {
593
+ type?: PropType<string | null> | undefined;
594
+ validator?(value: unknown): boolean;
595
+ } & {
596
+ default: string | (() => string | null) | null;
597
+ };
598
+ inline: {
599
+ type?: PropType<boolean> | undefined;
600
+ validator?(value: unknown): boolean;
601
+ } & {
602
+ default: boolean | (() => boolean) | null;
603
+ };
256
604
  langKey: {
257
- type: PropType<string | null>;
605
+ type?: PropType<string | null> | undefined;
258
606
  validator?(value: unknown): boolean;
259
607
  } & {
260
608
  default: string | (() => string | null) | null;
261
609
  };
610
+ langParams: {
611
+ type?: PropType<Record<string, unknown> | null> | undefined;
612
+ validator?(value: unknown): boolean;
613
+ } & {
614
+ default: Record<string, unknown> | (() => Record<string, unknown> | null) | null;
615
+ };
262
616
  text: {
263
- type: PropType<string | null>;
617
+ type?: PropType<string | null> | undefined;
264
618
  validator?(value: unknown): boolean;
265
619
  } & {
266
620
  default: string | (() => string | null) | null;
267
621
  };
268
622
  }>>, {
623
+ as: string | null;
624
+ inline: boolean;
269
625
  langKey: string | null;
626
+ langParams: Record<string, unknown> | null;
270
627
  text: string | null;
271
628
  }, {}>;
272
629
 
273
- export declare const AGModal: DefineComponent< {}, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
630
+ export declare const AGModal: DefineComponent< {
631
+ cancellable: {
632
+ type?: PropType<boolean> | undefined;
633
+ validator?(value: unknown): boolean;
634
+ } & {
635
+ default: boolean | (() => boolean) | null;
636
+ };
637
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
274
638
  [key: string]: any;
275
- }>, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {}>>, {}, {}>;
639
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
640
+ cancellable: {
641
+ type?: PropType<boolean> | undefined;
642
+ validator?(value: unknown): boolean;
643
+ } & {
644
+ default: boolean | (() => boolean) | null;
645
+ };
646
+ }>>, {
647
+ cancellable: boolean;
648
+ }, {}>;
276
649
 
277
650
  export declare const AGModalContext: DefineComponent< {
278
651
  modal: {
279
- type: PropType<Modal<unknown>>;
652
+ type?: PropType<Modal<unknown>> | undefined;
280
653
  validator?(value: unknown): boolean;
281
654
  } & {
282
655
  required: true;
283
656
  };
284
657
  childIndex: {
285
- type: PropType<number>;
658
+ type?: PropType<number> | undefined;
286
659
  validator?(value: unknown): boolean;
287
660
  } & {
288
661
  required: true;
@@ -291,59 +664,247 @@ required: true;
291
664
  [key: string]: any;
292
665
  }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
293
666
  modal: {
294
- type: PropType<Modal<unknown>>;
667
+ type?: PropType<Modal<unknown>> | undefined;
295
668
  validator?(value: unknown): boolean;
296
669
  } & {
297
670
  required: true;
298
671
  };
299
672
  childIndex: {
300
- type: PropType<number>;
673
+ type?: PropType<number> | undefined;
301
674
  validator?(value: unknown): boolean;
302
675
  } & {
303
676
  required: true;
304
677
  };
305
678
  }>>, {}, {}>;
306
679
 
680
+ export declare const AGModalTitle: DefineComponent< {}, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
681
+ [key: string]: any;
682
+ }>, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {}>>, {}, {}>;
683
+
684
+ export declare const AGSnackbar: DefineComponent< {
685
+ id: {
686
+ type?: PropType<string> | undefined;
687
+ validator?(value: unknown): boolean;
688
+ } & {
689
+ required: true;
690
+ };
691
+ message: {
692
+ type?: PropType<string> | undefined;
693
+ validator?(value: unknown): boolean;
694
+ } & {
695
+ required: true;
696
+ };
697
+ actions: {
698
+ type?: PropType<SnackbarAction[]> | undefined;
699
+ validator?(value: unknown): boolean;
700
+ } & {
701
+ default: SnackbarAction[] | (() => SnackbarAction[]) | null;
702
+ };
703
+ color: {
704
+ type?: PropType<"secondary" | "danger"> | undefined;
705
+ validator?(value: unknown): boolean;
706
+ } & {
707
+ default: "secondary" | "danger" | (() => "secondary" | "danger") | null;
708
+ };
709
+ }, (_ctx: any, _cache: any) => VNode<RendererNode, RendererElement, {
710
+ [key: string]: any;
711
+ }>, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, VNodeProps & AllowedComponentProps & ComponentCustomProps, Readonly<ExtractPropTypes< {
712
+ id: {
713
+ type?: PropType<string> | undefined;
714
+ validator?(value: unknown): boolean;
715
+ } & {
716
+ required: true;
717
+ };
718
+ message: {
719
+ type?: PropType<string> | undefined;
720
+ validator?(value: unknown): boolean;
721
+ } & {
722
+ required: true;
723
+ };
724
+ actions: {
725
+ type?: PropType<SnackbarAction[]> | undefined;
726
+ validator?(value: unknown): boolean;
727
+ } & {
728
+ default: SnackbarAction[] | (() => SnackbarAction[]) | null;
729
+ };
730
+ color: {
731
+ type?: PropType<"secondary" | "danger"> | undefined;
732
+ validator?(value: unknown): boolean;
733
+ } & {
734
+ default: "secondary" | "danger" | (() => "secondary" | "danger") | null;
735
+ };
736
+ }>>, {
737
+ actions: SnackbarAction[];
738
+ color: "secondary" | "danger";
739
+ }, {}>;
740
+
741
+ export declare const App: Facade<AppService, Constructor<AppService>>;
742
+
743
+ export declare class AppService extends _default_2 {
744
+ plugin<T extends Plugin_2 = Plugin_2>(name: string): T | null;
745
+ protected boot(): Promise<void>;
746
+ }
747
+
307
748
  export declare function arrayProp<T>(defaultValue?: () => T[]): OptionalProp<T[]>;
308
749
 
309
750
  declare type BaseProp<T> = {
310
- type: PropType<T>;
751
+ type?: PropType<T>;
311
752
  validator?(value: unknown): boolean;
312
753
  };
313
754
 
755
+ export declare function booleanInput(defaultValue?: boolean): FormFieldDefinition<typeof FormFieldTypes.Boolean>;
756
+
314
757
  export declare function booleanProp(defaultValue?: boolean): OptionalProp<boolean>;
315
758
 
316
- export declare function bootServices(app: App, services: Record<string, Service>): Promise<void>;
759
+ export declare function bootServices(app: App_2, services: Record<string, Service>): Promise<void>;
317
760
 
318
- export declare function bootstrapApplication(rootComponent: Component, options?: BootstrapOptions): Promise<void>;
761
+ export declare function bootstrapApplication(rootComponent: Component, options?: AerogelOptions): Promise<void>;
319
762
 
320
- declare interface BootstrapOptions {
321
- }
763
+ export declare type Color = (typeof Colors)[keyof typeof Colors];
764
+
765
+ export declare const Colors: {
766
+ readonly Primary: "primary";
767
+ readonly Secondary: "secondary";
768
+ readonly Danger: "danger";
769
+ readonly Clear: "clear";
770
+ };
771
+
772
+ export declare type ComponentProps = Record<string, unknown>;
322
773
 
323
774
  export declare function componentRef<T>(): Ref<UnwrapNestedRefs<T> | undefined>;
324
775
 
325
- declare const _default: Constructor<State> & Constructor<Service<DefaultServiceState>> & Service;
776
+ export declare type ComputedStateDefinition<TState extends ServiceState, TComputedState extends ServiceState> = {
777
+ [K in keyof TComputedState]: (state: TState) => TComputedState[K];
778
+ } & ThisType<{
779
+ readonly [K in keyof TComputedState]: TComputedState[K];
780
+ }>;
781
+
782
+ declare const _default: Constructor< {
783
+ logs: ErrorReportLog[];
784
+ startupErrors: ErrorReport[];
785
+ }> & Constructor< {
786
+ hasErrors: boolean;
787
+ hasNewErrors: boolean;
788
+ hasStartupErrors: boolean;
789
+ }> & Constructor<Service< {
790
+ logs: ErrorReportLog[];
791
+ startupErrors: ErrorReport[];
792
+ }, {
793
+ hasErrors: boolean;
794
+ hasNewErrors: boolean;
795
+ hasStartupErrors: boolean;
796
+ }, Partial<{
797
+ logs: ErrorReportLog[];
798
+ startupErrors: ErrorReport[];
799
+ }>>>;
800
+
801
+ declare const _default_2: Constructor< {
802
+ plugins: Record<string, Plugin_2>;
803
+ environment: "production" | "development" | "testing";
804
+ sourceUrl: string | undefined;
805
+ isMounted: boolean;
806
+ }> & Constructor< {
807
+ development: boolean;
808
+ testing: boolean;
809
+ }> & Constructor<Service< {
810
+ plugins: Record<string, Plugin_2>;
811
+ environment: "production" | "development" | "testing";
812
+ sourceUrl: string | undefined;
813
+ isMounted: boolean;
814
+ }, {
815
+ development: boolean;
816
+ testing: boolean;
817
+ }, Partial<{
818
+ plugins: Record<string, Plugin_2>;
819
+ environment: "production" | "development" | "testing";
820
+ sourceUrl: string | undefined;
821
+ isMounted: boolean;
822
+ }>>>;
823
+
824
+ declare const _default_3: Constructor< {
825
+ modals: Modal<unknown>[];
826
+ snackbars: Snackbar[];
827
+ }> & Constructor< {}> & Constructor<Service< {
828
+ modals: Modal<unknown>[];
829
+ snackbars: Snackbar[];
830
+ }, {}, Partial<{
831
+ modals: Modal<unknown>[];
832
+ snackbars: Snackbar[];
833
+ }>>>;
326
834
 
327
835
  export declare type DefaultServices = typeof defaultServices;
328
836
 
329
837
  declare const defaultServices: {
330
- $events: Facade<EventsService>;
838
+ $app: Facade<AppService, Constructor<AppService>>;
839
+ $events: Facade<EventsService, Constructor<EventsService>>;
331
840
  };
332
841
 
333
- export declare type DefaultServiceState = {};
842
+ export declare type DefaultServiceState = any;
334
843
 
335
844
  export declare function defineDirective(directive: Directive): Directive;
336
845
 
337
- export declare function defineServiceState<State extends ServiceState>(options: {
846
+ export declare function definePlugin<T extends Plugin_2>(plugin: T): T;
847
+
848
+ export declare function defineServiceState<State extends ServiceState = ServiceState, ComputedState extends ServiceState = {}>(options: {
849
+ name: string;
338
850
  initialState: State;
339
- }): Constructor<State> & ServiceConstructor;
851
+ persist?: (keyof State)[];
852
+ computed?: ComputedStateDefinition<State, ComputedState>;
853
+ serialize?: (state: Partial<State>) => Partial<State>;
854
+ }): Constructor<State> & Constructor<ComputedState> & Constructor<Service<State, ComputedState, Partial<State>>>;
340
855
 
341
856
  export declare function enumProp<Enum extends Record<string, unknown>>(enumeration: Enum, defaultValue?: Enum[keyof Enum]): OptionalProp<Enum[keyof Enum]>;
342
857
 
858
+ export declare type ErrorHandler = (error: ErrorSource) => boolean;
859
+
860
+ export declare interface ErrorReport {
861
+ title: string;
862
+ description?: string;
863
+ details?: string;
864
+ error?: Error | JSError | unknown;
865
+ }
866
+
867
+ export declare interface ErrorReportLog {
868
+ report: ErrorReport;
869
+ seen: boolean;
870
+ date: Date;
871
+ }
872
+
873
+ export declare const errorReportModalProps: {
874
+ reports: {
875
+ type?: PropType<ErrorReport[]> | undefined;
876
+ validator?(value: unknown): boolean;
877
+ } & {
878
+ required: true;
879
+ };
880
+ };
881
+
882
+ export declare const Errors: Facade<ErrorsService, Constructor<ErrorsService>>;
883
+
884
+ export declare type ErrorSource = string | Error | JSError | unknown;
885
+
886
+ declare class ErrorsService extends _default {
887
+ forceReporting: boolean;
888
+ private enabled;
889
+ enable(): void;
890
+ disable(): void;
891
+ inspect(error: ErrorSource | ErrorReport[]): Promise<void>;
892
+ report(error: ErrorSource, message?: string): Promise<void>;
893
+ see(report: ErrorReport): void;
894
+ seeAll(): void;
895
+ getErrorMessage(error: ErrorSource): string;
896
+ private logError;
897
+ private createErrorReport;
898
+ private createStartupErrorReport;
899
+ private createErrorReportFromError;
900
+ }
901
+
902
+ export declare type ErrorsServices = typeof services;
903
+
343
904
  declare type EventListener_2<T = unknown> = (payload: T) => unknown;
344
905
  export { EventListener_2 as EventListener }
345
906
 
346
- export declare const Events: Facade<EventsService>;
907
+ export declare const Events: Facade<EventsService, Constructor<EventsService>>;
347
908
 
348
909
  export declare interface EventsPayload {
349
910
  }
@@ -370,6 +931,8 @@ export declare type EventWithPayload = {
370
931
  [K in keyof EventsPayload]: EventsPayload[K] extends void ? never : K;
371
932
  }[keyof EventsPayload];
372
933
 
934
+ export declare function extractSelectProps<T extends Record<keyof typeof selectProps, unknown>>(componentProps: T): Pick<T, keyof typeof selectProps>;
935
+
373
936
  declare class Form<Fields extends FormFieldDefinitions = FormFieldDefinitions> extends MagicObject {
374
937
  errors: DeepReadonly<UnwrapNestedRefs<FormErrors<Fields>>>;
375
938
  private _fields;
@@ -383,16 +946,22 @@ declare class Form<Fields extends FormFieldDefinitions = FormFieldDefinitions> e
383
946
  setFieldValue<T extends keyof Fields>(field: T, value: FormData_2<Fields>[T]): void;
384
947
  getFieldValue<T extends keyof Fields>(field: T): GetFormFieldValue<Fields[T]['type']>;
385
948
  validate(): boolean;
949
+ reset(options?: {
950
+ keepData?: boolean;
951
+ keepErrors?: boolean;
952
+ }): void;
386
953
  submit(): boolean;
387
954
  protected __get(property: string): unknown;
388
955
  protected __set(property: string, value: unknown): void;
389
956
  private getFieldErrors;
390
957
  private getInitialData;
391
958
  private getInitialErrors;
959
+ private resetData;
960
+ private resetErrors;
392
961
  }
393
962
 
394
963
  declare type FormData_2<T> = {
395
- [k in keyof T]: T[k] extends FormFieldDefinition<infer TType, infer TRules> ? TRules extends 'required' ? GetFormFieldValue<TType> : GetFormFieldValue<TType> | null : never;
964
+ -readonly [k in keyof T]: T[k] extends FormFieldDefinition<infer TType, infer TRules> ? TRules extends 'required' ? GetFormFieldValue<TType> : GetFormFieldValue<TType> | null : never;
396
965
  };
397
966
  export { FormData_2 as FormData }
398
967
 
@@ -413,45 +982,81 @@ export declare type FormFieldType = ObjectValues<typeof FormFieldTypes>;
413
982
  export declare const FormFieldTypes: {
414
983
  readonly String: "string";
415
984
  readonly Number: "number";
985
+ readonly Boolean: "boolean";
986
+ readonly Object: "object";
416
987
  };
417
988
 
418
- export declare type GetFormFieldValue<TType> = TType extends typeof FormFieldTypes.String ? string : TType extends typeof FormFieldTypes.Number ? number : never;
989
+ export declare type GetFormFieldValue<TType> = TType extends typeof FormFieldTypes.String ? string : TType extends typeof FormFieldTypes.Number ? number : TType extends typeof FormFieldTypes.Boolean ? boolean : TType extends typeof FormFieldTypes.Object ? object : never;
990
+
991
+ export declare interface IAGErrorReportModalButtonsDefaultSlotProps {
992
+ id: string;
993
+ description: string;
994
+ iconComponent: Component;
995
+ url?: string;
996
+ handler?(): void;
997
+ }
998
+
999
+ export declare interface IAGHeadlessInput {
1000
+ id: string;
1001
+ value: ComputedRef<string | number | boolean | null>;
1002
+ errors: DeepReadonly<Ref<string[] | null>>;
1003
+ update(value: string | number | boolean | null): void;
1004
+ }
419
1005
 
420
1006
  export declare interface IAGHeadlessModal extends IAGModal {
421
1007
  }
422
1008
 
1009
+ export declare interface IAGHeadlessSelect {
1010
+ value: ComputedRef<SelectOptionValue | undefined>;
1011
+ options: SelectOptionValue[];
1012
+ update(value: string | number | boolean | null): void;
1013
+ }
1014
+
1015
+ export declare type IAGHeadlessSelectOptionSlotProps = {
1016
+ active: boolean;
1017
+ selected: boolean;
1018
+ };
1019
+
423
1020
  export declare interface IAGModal {
424
1021
  cancellable: Ref<boolean>;
425
1022
  close(): Promise<void>;
426
1023
  }
427
1024
 
1025
+ export declare interface IAGModalContext {
1026
+ modal: Ref<Modal>;
1027
+ childIndex: Ref<number>;
1028
+ }
1029
+
1030
+ export declare interface IAGModalSlotProps {
1031
+ close(result?: unknown): Promise<void>;
1032
+ }
1033
+
428
1034
  export declare function injectOrFail<T>(key: InjectionKey<T> | string, errorMessage?: string): T;
429
1035
 
430
1036
  export declare function injectReactive<T extends object>(key: InjectionKey<T> | string): UnwrapNestedRefs<T> | undefined;
431
1037
 
432
1038
  export declare function injectReactiveOrFail<T extends object>(key: InjectionKey<T> | string, errorMessage?: string): UnwrapNestedRefs<T>;
433
1039
 
434
- export declare const Lang: Facade<LangService>;
1040
+ export declare function installPlugins(plugins: Plugin_2[], ...args: GetClosureArgs<Plugin_2['install']>): Promise<void>;
435
1041
 
436
- export declare function lang(key: string, parameters?: Record<string, unknown>): string;
1042
+ export declare const Lang: Facade<LangService, Constructor<LangService>>;
437
1043
 
438
- export declare interface LangOptions {
439
- messages: Record<string, unknown>;
440
- defaultLocale?: string;
441
- fallbackLocale?: string;
1044
+ export declare interface LangProvider {
1045
+ translate(key: string, parameters?: Record<string, unknown>): string;
442
1046
  }
443
1047
 
444
1048
  declare class LangService extends Service {
445
- private i18n?;
446
- setup(): void;
1049
+ private provider;
1050
+ constructor();
1051
+ setProvider(provider: LangProvider): void;
447
1052
  translate(key: string, parameters?: Record<string, unknown>): string;
1053
+ translateWithDefault(key: string, defaultMessage: string): string;
1054
+ translateWithDefault(key: string, parameters: Record<string, unknown>, defaultMessage: string): string;
448
1055
  }
449
1056
 
450
- export declare type LangServices = typeof services;
451
-
452
- export declare type LazyMessages = () => Promise<Record<string, unknown>>;
1057
+ export declare type LangServices = typeof services_2;
453
1058
 
454
- export declare function mixedProp<T>(type: PropType<T>): OptionalProp<T | null>;
1059
+ export declare function mixedProp<T>(type?: PropType<T>): OptionalProp<T | null>;
455
1060
 
456
1061
  declare interface Modal<T = unknown> {
457
1062
  id: string;
@@ -478,12 +1083,22 @@ export declare function objectProp<T = Object>(): OptionalProp<T | null>;
478
1083
 
479
1084
  export declare function objectProp<T>(defaultValue: () => T): OptionalProp<T>;
480
1085
 
1086
+ export declare function onCleanMounted(operation: () => Function): void;
1087
+
481
1088
  declare type OptionalProp<T> = BaseProp<T> & {
482
1089
  default: T | (() => T) | null;
483
1090
  };
484
1091
 
1092
+ declare interface Plugin_2 {
1093
+ name?: string;
1094
+ install(app: App_2, options: AerogelOptions): void | Promise<void>;
1095
+ }
1096
+ export { Plugin_2 as Plugin }
1097
+
485
1098
  export declare function requiredArrayProp<T>(): RequiredProp<T[]>;
486
1099
 
1100
+ export declare function requiredBooleanInput(defaultValue?: boolean): FormFieldDefinition<typeof FormFieldTypes.Boolean, 'required'>;
1101
+
487
1102
  export declare function requiredEnumProp<Enum extends Record<string, unknown>>(enumeration: Enum): RequiredProp<Enum[keyof Enum]>;
488
1103
 
489
1104
  export declare function requiredMixedProp<T>(type: PropType<T>): RequiredProp<T>;
@@ -502,21 +1117,42 @@ export declare function requiredStringInput(defaultValue?: string): FormFieldDef
502
1117
 
503
1118
  export declare function requiredStringProp(): RequiredProp<string>;
504
1119
 
505
- export declare class Service<State extends ServiceState = DefaultServiceState> extends MagicObject {
506
- protected _namespace: string;
1120
+ export declare type SelectOptionValue = string | number | boolean | object | null;
1121
+
1122
+ export declare const selectProps: {
1123
+ options: {
1124
+ type?: PropType<SelectOptionValue[]> | undefined;
1125
+ validator?(value: unknown): boolean;
1126
+ } & {
1127
+ required: true;
1128
+ };
1129
+ };
1130
+
1131
+ export declare class Service<State extends ServiceState = DefaultServiceState, ComputedState extends ServiceState = {}, ServiceStorage extends Partial<State> = Partial<State>> extends MagicObject {
1132
+ static persist: string[];
1133
+ protected _name: string;
507
1134
  private _booted;
508
- private _state;
1135
+ private _computedStateKeys;
1136
+ private _store?;
509
1137
  constructor();
510
1138
  get booted(): PromisedValue<void>;
511
- launch(namespace?: string): Promise<void>;
1139
+ launch(): Promise<void>;
1140
+ hasState<P extends keyof State>(property: P): boolean;
1141
+ getState(): State;
1142
+ getState<P extends keyof State>(property: P): State[P];
1143
+ setState<P extends keyof State>(property: P, value: State[P]): void;
1144
+ setState(state: Partial<State>): void;
512
1145
  protected __get(property: string): unknown;
513
1146
  protected __set(property: string, value: unknown): void;
514
- protected hasState<P extends keyof State>(property: P): boolean;
515
- protected getState(): State;
516
- protected getState<P extends keyof State>(property: P): State[P];
517
- protected setState(state: Partial<State>): void;
1147
+ protected onStateUpdated(state: Partial<State>): void;
1148
+ protected usesStore(): boolean;
1149
+ protected getName(): string | null;
518
1150
  protected getInitialState(): State;
1151
+ protected getComputedStateDefinition(): ComputedStateDefinition<State, ComputedState>;
1152
+ protected serializePersistedState(state: Partial<State>): Partial<State>;
1153
+ protected frameworkBoot(): Promise<void>;
519
1154
  protected boot(): Promise<void>;
1155
+ protected restorePersistedState(): void;
520
1156
  }
521
1157
 
522
1158
  export declare type ServiceConstructor<T extends Service = Service> = Constructor<T> & typeof Service;
@@ -525,70 +1161,160 @@ export declare interface Services extends DefaultServices {
525
1161
  }
526
1162
 
527
1163
  declare const services: {
528
- $lang: Facade<LangService>;
1164
+ $errors: Facade<ErrorsService, Constructor<ErrorsService>>;
529
1165
  };
530
1166
 
531
1167
  declare const services_2: {
532
- $ui: Facade<UIService>;
1168
+ $lang: Facade<LangService, Constructor<LangService>>;
1169
+ };
1170
+
1171
+ declare const services_3: {
1172
+ $ui: Facade<UIService, Constructor<UIService>>;
533
1173
  };
534
1174
 
535
1175
  export declare type ServiceState = Record<string, any>;
536
1176
 
537
- declare interface State {
538
- modals: Modal[];
1177
+ declare interface ShowSnackbarOptions {
1178
+ component?: Component;
1179
+ color?: SnackbarColor;
1180
+ actions?: SnackbarAction[];
1181
+ }
1182
+
1183
+ declare interface Snackbar {
1184
+ id: string;
1185
+ component: Component;
1186
+ properties: Record<string, unknown>;
539
1187
  }
540
1188
 
1189
+ export declare interface SnackbarAction {
1190
+ text: string;
1191
+ dismiss?: boolean;
1192
+ handler?(): unknown;
1193
+ }
1194
+
1195
+ export declare type SnackbarColor = (typeof SnackbarColors)[keyof typeof SnackbarColors];
1196
+
1197
+ export declare const SnackbarColors: Omit<{
1198
+ readonly Primary: "primary";
1199
+ readonly Secondary: "secondary";
1200
+ readonly Danger: "danger";
1201
+ readonly Clear: "clear";
1202
+ }, "Primary" | "Clear">;
1203
+
1204
+ export declare const snackbarProps: {
1205
+ id: {
1206
+ type?: PropType<string> | undefined;
1207
+ validator?(value: unknown): boolean;
1208
+ } & {
1209
+ required: true;
1210
+ };
1211
+ message: {
1212
+ type?: PropType<string> | undefined;
1213
+ validator?(value: unknown): boolean;
1214
+ } & {
1215
+ required: true;
1216
+ };
1217
+ actions: {
1218
+ type?: PropType<SnackbarAction[]> | undefined;
1219
+ validator?(value: unknown): boolean;
1220
+ } & {
1221
+ default: SnackbarAction[] | (() => SnackbarAction[]) | null;
1222
+ };
1223
+ color: {
1224
+ type?: PropType<"secondary" | "danger"> | undefined;
1225
+ validator?(value: unknown): boolean;
1226
+ } & {
1227
+ default: "secondary" | "danger" | (() => "secondary" | "danger") | null;
1228
+ };
1229
+ };
1230
+
541
1231
  export declare function stringInput(defaultValue?: string): FormFieldDefinition<typeof FormFieldTypes.String>;
542
1232
 
543
1233
  export declare function stringProp(): OptionalProp<string | null>;
544
1234
 
545
1235
  export declare function stringProp(defaultValue: string): OptionalProp<string>;
546
1236
 
547
- export declare const UI: Facade<UIService>;
1237
+ export declare const translate: (key: string, parameters?: Record<string, unknown> | undefined) => string;
1238
+
1239
+ export declare const translateWithDefault: {
1240
+ (key: string, defaultMessage: string): string;
1241
+ (key: string, parameters: Record<string, unknown>, defaultMessage: string): string;
1242
+ };
1243
+
1244
+ export declare const UI: Facade<UIService, Constructor<UIService>>;
548
1245
 
549
1246
  export declare type UIComponent = ObjectValues<typeof UIComponents>;
550
1247
 
551
1248
  export declare const UIComponents: {
552
1249
  readonly AlertModal: "alert-modal";
1250
+ readonly ConfirmModal: "confirm-modal";
1251
+ readonly ErrorReportModal: "error-report-modal";
1252
+ readonly LoadingModal: "loading-modal";
1253
+ readonly Snackbar: "snackbar";
553
1254
  };
554
1255
 
555
- declare class UIService extends _default {
1256
+ declare class UIService extends _default_3 {
556
1257
  private modalCallbacks;
557
1258
  private components;
1259
+ requireComponent(name: UIComponent): Component;
558
1260
  alert(message: string): void;
1261
+ alert(title: string, message: string): void;
1262
+ confirm(message: string): Promise<boolean>;
1263
+ confirm(title: string, message: string): Promise<boolean>;
1264
+ loading<T>(operation: Promise<T>): Promise<T>;
1265
+ loading<T>(message: string, operation: Promise<T>): Promise<T>;
1266
+ showSnackbar(message: string, options?: ShowSnackbarOptions): void;
1267
+ hideSnackbar(id: string): void;
559
1268
  registerComponent(name: UIComponent, component: Component): void;
560
1269
  openModal<TModalComponent extends ModalComponent>(component: TModalComponent, properties?: ModalProperties<TModalComponent>): Promise<Modal<ModalResult<TModalComponent>>>;
561
1270
  closeModal(id: string, result?: unknown): Promise<void>;
562
1271
  protected boot(): Promise<void>;
563
- private requireComponent;
564
1272
  private watchModalEvents;
565
1273
  }
566
1274
 
567
- export declare type UIServices = typeof services_2;
1275
+ export declare type UIServices = typeof services_3;
568
1276
 
569
1277
  export declare type UnknownEvent<T> = T extends keyof EventsPayload ? never : T;
570
1278
 
1279
+ export declare function useErrorReportModalProps(): typeof errorReportModalProps;
1280
+
1281
+ export declare function useEvent<Event extends EventWithoutPayload>(event: Event, listener: () => unknown): void;
1282
+
1283
+ export declare function useEvent<Event extends EventWithPayload>(event: Event, listener: EventListener_2<EventsPayload[Event]>): void;
1284
+
1285
+ export declare function useEvent<Event extends string>(event: UnknownEvent<Event>, listener: EventListener_2): void;
1286
+
571
1287
  export declare function useForm<const T extends FormFieldDefinitions>(fields: T): Form<T> & FormData_2<T>;
572
1288
 
1289
+ export declare function useInputAttrs(): [ComputedRef<{}>, ComputedRef<unknown>];
1290
+
1291
+ export declare function useSelectProps(): typeof selectProps;
1292
+
1293
+ export declare function useSnackbarProps(): typeof snackbarProps;
1294
+
573
1295
  export { }
574
1296
 
575
- interface BootstrapOptions {
576
- lang?: LangOptions;
577
- langMessages?: Record<string, unknown>;
1297
+ interface AerogelOptions {
1298
+ directives?: Record<string, Directive>;
578
1299
  }
579
1300
 
580
- interface Services extends LangServices {}
581
-
582
- interface BootstrapOptions {
583
- models?: Record<string, Record<string, unknown>>;
1301
+ interface AerogelOptions {
1302
+ handleError?(error: ErrorSource): boolean;
584
1303
  }
585
1304
 
586
- interface BootstrapOptions {
587
- routes?: RouteRecordRaw[];
588
- basePath?: string;
1305
+ export interface Services extends ErrorsServices {}
1306
+
1307
+ export interface Services extends LangServices {}
1308
+
1309
+ declare module '@vue/runtime-core' {
1310
+ interface ComponentCustomProperties {
1311
+ $td: typeof translateWithDefault;
589
1312
  }
1313
+ }
590
1314
 
591
- import type { RouteRecordRaw } from 'vue-router';
1315
+ interface AerogelOptions {
1316
+ services?: Record<string, Service>;
1317
+ }
592
1318
 
593
1319
  declare module '@vue/runtime-core' {
594
1320
  interface ComponentCustomProperties extends Services {}
@@ -602,8 +1328,8 @@ declare module '@vue/runtime-core' {
602
1328
  'show-modal': { id: string };
603
1329
  }
604
1330
 
605
- interface BootstrapOptions {
1331
+ interface AerogelOptions {
606
1332
  components?: Partial<Record<UIComponent, Component>>;
607
1333
  }
608
1334
 
609
- interface Services extends UIServices {}
1335
+ export interface Services extends UIServices {}