@wgalleti/primevue-components 1.17.1 → 1.19.0

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 (39) hide show
  1. package/dist/components/charts/WChart.vue.d.ts +1 -1
  2. package/dist/components/crud/WCrudView.vue.d.ts +88 -39
  3. package/dist/components/form/WDatePicker.vue.d.ts +3 -1
  4. package/dist/components/ui/WCheckList.vue.d.ts +1 -1
  5. package/dist/components/ui/WKpiCard.vue.d.ts +2 -2
  6. package/dist/components/ui/WMapSelect.vue.d.ts +1 -1
  7. package/dist/components/ui/WMeter.vue.d.ts +2 -2
  8. package/dist/components-BG5SUm-f.cjs +25 -0
  9. package/dist/components-BG5SUm-f.cjs.map +1 -0
  10. package/dist/{components-lO0I43CU.js → components-DDidEKfp.js} +1921 -1640
  11. package/dist/components-DDidEKfp.js.map +1 -0
  12. package/dist/components.cjs +1 -1
  13. package/dist/components.js +1 -1
  14. package/dist/{composables-BYOQ7IBQ.js → composables-BEcmxiCQ.js} +2 -2
  15. package/dist/{composables-BYOQ7IBQ.js.map → composables-BEcmxiCQ.js.map} +1 -1
  16. package/dist/{composables-B5lQK7vG.cjs → composables-D013e6u-.cjs} +2 -2
  17. package/dist/{composables-B5lQK7vG.cjs.map → composables-D013e6u-.cjs.map} +1 -1
  18. package/dist/composables.cjs +1 -1
  19. package/dist/composables.js +2 -2
  20. package/dist/index.cjs +1 -1
  21. package/dist/index.d.ts +1 -1
  22. package/dist/index.js +3 -3
  23. package/dist/primevue-components.css +1 -1
  24. package/dist/types/column.d.ts +30 -1
  25. package/dist/types/crudGroup.d.ts +11 -0
  26. package/dist/types/index.d.ts +1 -0
  27. package/dist/useFormKeyboardNav-Dzczvgce.js +493 -0
  28. package/dist/useFormKeyboardNav-Dzczvgce.js.map +1 -0
  29. package/dist/useFormKeyboardNav-wNRvUJ1H.cjs +3 -0
  30. package/dist/useFormKeyboardNav-wNRvUJ1H.cjs.map +1 -0
  31. package/package.json +1 -1
  32. package/skill/references/crud.md +2 -0
  33. package/dist/components-BOnwAcU6.cjs +0 -25
  34. package/dist/components-BOnwAcU6.cjs.map +0 -1
  35. package/dist/components-lO0I43CU.js.map +0 -1
  36. package/dist/useFormKeyboardNav-P-sZq9cy.cjs +0 -3
  37. package/dist/useFormKeyboardNav-P-sZq9cy.cjs.map +0 -1
  38. package/dist/useFormKeyboardNav-wVvZqL_0.js +0 -658
  39. package/dist/useFormKeyboardNav-wVvZqL_0.js.map +0 -1
@@ -31,9 +31,9 @@ declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {},
31
31
  onSelect?: ((event: ChartSelectEvent) => any) | undefined;
32
32
  }>, {
33
33
  emptyMessage: string;
34
+ empty: boolean;
34
35
  loading: boolean;
35
36
  height: string;
36
- empty: boolean;
37
37
  print: boolean;
38
38
  renderer: "canvas" | "svg";
39
39
  clickable: boolean;
@@ -38,6 +38,9 @@ type __VLS_Props = {
38
38
  * trocar entre `auto` e `fit` depois de montado não é suportado.
39
39
  */
40
40
  cardMode?: 'auto' | 'never' | 'always' | 'fit';
41
+ /** Linhas compostas (opt-in): linha de duas alturas pelo token de densidade, sem réguas
42
+ * verticais, cabeçalho leve e fixo; nos cards a coluna `identity` vira o título. */
43
+ composed?: boolean;
41
44
  /** Cards "sem moldura": remove o chrome padrão do card (borda/sombra/padding/
42
45
  * seleção) para o slot `#card` desenhar o card inteiro (ex.: um card de design
43
46
  * próprio). O wrapper vira só a célula do grid. */
@@ -52,73 +55,106 @@ type __VLS_Props = {
52
55
  /** Chave de persistência do estado de coluna (visibilidade) em localStorage.
53
56
  * Opt-in: quando definida, exibe o seletor de colunas e persiste o que foi ocultado. */
54
57
  persistState?: string;
58
+ /** Agrupa as linhas sob cabeçalhos recolhíveis, na tabela e nos cards: nome do campo ou
59
+ * função que dá a chave do grupo. Os grupos seguem a ordem da primeira aparição em
60
+ * `crud.items`; para ordenar, use `transformItems` ou a ordenação da API. A lista é lazy:
61
+ * agrupa o que veio na página, então um grupo pode continuar na página seguinte. */
62
+ groupBy?: string | ((item: Record<string, unknown>) => string);
63
+ /** Rótulo do grupo; default a própria chave ("Sem grupo" quando vazia). */
64
+ groupLabel?: (groupKey: string, items: Record<string, unknown>[]) => string;
55
65
  };
56
66
  /**
57
67
  * Rola a tabela até a linha cujo pk é `value` — o par do `v-model:selectedRow`
58
68
  * para o sentido "de fora para dentro" (selecionou no mapa/gráfico, a linha
59
69
  * aparece). Só alcança a página atual: linha em outra página não é buscada — é
60
70
  * do consumidor decidir o que fazer nesse caso (a lista é lazy). Com linhas de
61
- * expansão abertas o índice DOM diverge do índice do item; aí não rola.
71
+ * expansão abertas o índice DOM diverge do índice do item; aí não rola. Linha em
72
+ * grupo recolhido: abre o grupo antes de rolar.
62
73
  */
63
74
  declare function scrollToRow(value: unknown): void;
64
75
  type __VLS_ModelProps = {
65
76
  'selectedRow'?: Record<string, unknown> | null;
77
+ 'collapsedGroups'?: string[];
66
78
  };
67
79
  type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
68
80
  declare var __VLS_1: {}, __VLS_10: {}, __VLS_12: {
69
81
  selected: any[];
70
82
  crud: CrudManagerReturn<any>;
71
- }, __VLS_65: {}, __VLS_95: {}, __VLS_104: {}, __VLS_157: {}, __VLS_177: `column-${string}`, __VLS_178: {
83
+ }, __VLS_66: {}, __VLS_96: {}, __VLS_105: {}, __VLS_172: {}, __VLS_175: {
84
+ groupKey: string;
85
+ label: string;
86
+ items: Record<string, unknown>[];
87
+ count: number;
88
+ collapsed: boolean;
89
+ }, __VLS_177: {
90
+ groupKey: string;
91
+ label: string;
92
+ items: Record<string, unknown>[];
93
+ count: number;
94
+ collapsed: boolean;
95
+ }, __VLS_202: `column-${string}`, __VLS_203: {
72
96
  data: any;
73
97
  value: any;
74
- }, __VLS_214: {
98
+ }, __VLS_239: {
75
99
  data: any;
76
100
  crud: CrudManagerReturn<any>;
77
- }, __VLS_217: {
78
- data: any;
79
- }, __VLS_237: {}, __VLS_267: {}, __VLS_276: {}, __VLS_306: {}, __VLS_308: {
101
+ }, __VLS_242: {
80
102
  data: any;
103
+ }, __VLS_262: {}, __VLS_292: {}, __VLS_301: {}, __VLS_345: {}, __VLS_347: {
104
+ groupKey: string;
105
+ label: string;
106
+ items: Record<string, unknown>[];
107
+ count: number;
108
+ collapsed: boolean;
109
+ }, __VLS_349: {
110
+ groupKey: string;
111
+ label: string;
112
+ items: Record<string, unknown>[];
113
+ count: number;
114
+ collapsed: boolean;
115
+ }, __VLS_356: {
116
+ data: Record<string, unknown>;
81
117
  crud: CrudManagerReturn<any>;
82
118
  columns: ColumnDef[];
83
119
  index: number;
84
- }, __VLS_311: `column-${string}`, __VLS_312: {
85
- data: any;
86
- value: any;
87
- }, __VLS_326: {
88
- data: any;
120
+ }, __VLS_359: `column-${string}`, __VLS_360: {
121
+ data: Record<string, unknown>;
122
+ value: unknown;
123
+ }, __VLS_374: {
124
+ data: Record<string, unknown>;
89
125
  crud: CrudManagerReturn<any>;
90
- }, __VLS_349: {
126
+ }, __VLS_397: {
91
127
  selected: Record<string, unknown> | null;
92
128
  crud: CrudManagerReturn<any>;
93
- }, __VLS_372: {
129
+ }, __VLS_420: {
94
130
  crud: CrudManagerReturn<any>;
95
131
  dialogWidth: string;
96
- }, __VLS_386: `field-${string}`, __VLS_387: {
132
+ }, __VLS_434: `field-${string}`, __VLS_435: {
97
133
  field: FieldDef;
98
134
  formData: Record<string, unknown>;
99
135
  isEditing: boolean;
100
136
  fieldId: string;
101
137
  setFormField: (f: string, v: unknown) => void;
102
- }, __VLS_391: `image-${string}`, __VLS_392: {
138
+ }, __VLS_439: `image-${string}`, __VLS_440: {
103
139
  field: FieldDef;
104
140
  formData: Record<string, unknown>;
105
- }, __VLS_395: {
141
+ }, __VLS_443: {
106
142
  formData: Record<string, unknown>;
107
143
  isEditing: boolean;
108
- }, __VLS_398: {
144
+ }, __VLS_446: {
109
145
  formData: Record<string, unknown>;
110
146
  isEditing: boolean;
111
- }, __VLS_406: {
147
+ }, __VLS_454: {
112
148
  item: Record<string, unknown> | null;
113
149
  };
114
150
  type __VLS_Slots = {} & {
115
- [K in NonNullable<typeof __VLS_177>]?: (props: typeof __VLS_178) => any;
151
+ [K in NonNullable<typeof __VLS_202>]?: (props: typeof __VLS_203) => any;
116
152
  } & {
117
- [K in NonNullable<typeof __VLS_311>]?: (props: typeof __VLS_312) => any;
153
+ [K in NonNullable<typeof __VLS_359>]?: (props: typeof __VLS_360) => any;
118
154
  } & {
119
- [K in NonNullable<typeof __VLS_386>]?: (props: typeof __VLS_387) => any;
155
+ [K in NonNullable<typeof __VLS_434>]?: (props: typeof __VLS_435) => any;
120
156
  } & {
121
- [K in NonNullable<typeof __VLS_391>]?: (props: typeof __VLS_392) => any;
157
+ [K in NonNullable<typeof __VLS_439>]?: (props: typeof __VLS_440) => any;
122
158
  } & {
123
159
  'header-actions'?: (props: typeof __VLS_1) => any;
124
160
  } & {
@@ -126,39 +162,47 @@ type __VLS_Slots = {} & {
126
162
  } & {
127
163
  'bulk-actions'?: (props: typeof __VLS_12) => any;
128
164
  } & {
129
- 'toolbar-start'?: (props: typeof __VLS_65) => any;
165
+ 'toolbar-start'?: (props: typeof __VLS_66) => any;
166
+ } & {
167
+ 'toolbar-filters'?: (props: typeof __VLS_96) => any;
168
+ } & {
169
+ 'toolbar-actions'?: (props: typeof __VLS_105) => any;
170
+ } & {
171
+ empty?: (props: typeof __VLS_172) => any;
172
+ } & {
173
+ 'group-header'?: (props: typeof __VLS_175) => any;
130
174
  } & {
131
- 'toolbar-filters'?: (props: typeof __VLS_95) => any;
175
+ 'group-meta'?: (props: typeof __VLS_177) => any;
132
176
  } & {
133
- 'toolbar-actions'?: (props: typeof __VLS_104) => any;
177
+ 'row-actions'?: (props: typeof __VLS_239) => any;
134
178
  } & {
135
- empty?: (props: typeof __VLS_157) => any;
179
+ expansion?: (props: typeof __VLS_242) => any;
136
180
  } & {
137
- 'row-actions'?: (props: typeof __VLS_214) => any;
181
+ 'toolbar-start'?: (props: typeof __VLS_262) => any;
138
182
  } & {
139
- expansion?: (props: typeof __VLS_217) => any;
183
+ 'toolbar-filters'?: (props: typeof __VLS_292) => any;
140
184
  } & {
141
- 'toolbar-start'?: (props: typeof __VLS_237) => any;
185
+ 'toolbar-actions'?: (props: typeof __VLS_301) => any;
142
186
  } & {
143
- 'toolbar-filters'?: (props: typeof __VLS_267) => any;
187
+ empty?: (props: typeof __VLS_345) => any;
144
188
  } & {
145
- 'toolbar-actions'?: (props: typeof __VLS_276) => any;
189
+ 'group-header'?: (props: typeof __VLS_347) => any;
146
190
  } & {
147
- empty?: (props: typeof __VLS_306) => any;
191
+ 'group-meta'?: (props: typeof __VLS_349) => any;
148
192
  } & {
149
- card?: (props: typeof __VLS_308) => any;
193
+ card?: (props: typeof __VLS_356) => any;
150
194
  } & {
151
- 'row-actions'?: (props: typeof __VLS_326) => any;
195
+ 'row-actions'?: (props: typeof __VLS_374) => any;
152
196
  } & {
153
- 'rail-actions'?: (props: typeof __VLS_349) => any;
197
+ 'rail-actions'?: (props: typeof __VLS_397) => any;
154
198
  } & {
155
- 'form-dialog'?: (props: typeof __VLS_372) => any;
199
+ 'form-dialog'?: (props: typeof __VLS_420) => any;
156
200
  } & {
157
- 'after-fields'?: (props: typeof __VLS_395) => any;
201
+ 'after-fields'?: (props: typeof __VLS_443) => any;
158
202
  } & {
159
- aside?: (props: typeof __VLS_398) => any;
203
+ aside?: (props: typeof __VLS_446) => any;
160
204
  } & {
161
- 'delete-message'?: (props: typeof __VLS_406) => any;
205
+ 'delete-message'?: (props: typeof __VLS_454) => any;
162
206
  };
163
207
  declare const __VLS_base: import('vue').DefineComponent<__VLS_PublicProps, {
164
208
  scrollToRow: typeof scrollToRow;
@@ -168,12 +212,14 @@ declare const __VLS_base: import('vue').DefineComponent<__VLS_PublicProps, {
168
212
  "row-collapse": (data: unknown) => any;
169
213
  print: (data: Record<string, unknown>) => any;
170
214
  "update:selectedRow": (value: Record<string, unknown> | null) => any;
215
+ "update:collapsedGroups": (value: string[]) => any;
171
216
  }, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
172
217
  "onRow-click"?: ((data: Record<string, unknown>) => any) | undefined;
173
218
  "onRow-expand"?: ((data: unknown) => any) | undefined;
174
219
  "onRow-collapse"?: ((data: unknown) => any) | undefined;
175
220
  onPrint?: ((data: Record<string, unknown>) => any) | undefined;
176
221
  "onUpdate:selectedRow"?: ((value: Record<string, unknown> | null) => any) | undefined;
222
+ "onUpdate:collapsedGroups"?: ((value: string[]) => any) | undefined;
177
223
  }>, {
178
224
  dialogWidth: string;
179
225
  showHeader: boolean;
@@ -190,12 +236,15 @@ declare const __VLS_base: import('vue').DefineComponent<__VLS_PublicProps, {
190
236
  defaultView: "table" | "cards";
191
237
  cardFields: number;
192
238
  cardMode: "auto" | "never" | "always" | "fit";
239
+ composed: boolean;
193
240
  actionRail: boolean;
194
241
  showPrint: boolean;
195
242
  exportCsv: boolean;
196
243
  csvFilename: string;
197
244
  csvScope: "all" | "page";
198
245
  csvPageSize: number;
246
+ groupBy: string | ((item: Record<string, unknown>) => string);
247
+ groupLabel: (groupKey: string, items: Record<string, unknown>[]) => string;
199
248
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
200
249
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
201
250
  declare const _default: typeof __VLS_export;
@@ -3,7 +3,9 @@ import { DateValueFormat } from '../../composables/useDateInput';
3
3
  * Campo de data pt-BR padronizado.
4
4
  * - Exibe `DD/MM/YYYY` (ou `DD/MM/YYYY HH:mm` com `showTime`) e salva `YYYY-MM-DD`.
5
5
  * - Digitação direta com máscara: `30051988` vira `30/05/1988`.
6
- * - Ícone de calendário abre o seletor (Hoje / Limpar).
6
+ * - Ícone de calendário abre o seletor (Hoje / Limpar). Com `showTime` o seletor não fecha ao
7
+ * escolher (falta a hora): os atalhos viram "Agora" / "Limpar" à esquerda e um **OK** à
8
+ * direita confirma e fecha, devolvendo o foco ao campo. `Esc` fecha sem mudar nada.
7
9
  * - `F2` preenche a data de hoje.
8
10
  * - `autonow`: no mount, se o valor for `null`, preenche hoje; senão mantém.
9
11
  */
@@ -19,8 +19,8 @@ type __VLS_Slots = {} & {
19
19
  };
20
20
  declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {
21
21
  emptyMessage: string;
22
- showCount: boolean;
23
22
  items: CheckListItem[];
23
+ showCount: boolean;
24
24
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
25
25
  declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
26
26
  declare const _default: typeof __VLS_export;
@@ -44,9 +44,9 @@ type __VLS_Slots = {} & {
44
44
  footer?: (props: typeof __VLS_36) => any;
45
45
  };
46
46
  declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
47
- click: (event: KeyboardEvent | MouseEvent) => any;
47
+ click: (event: MouseEvent | KeyboardEvent) => any;
48
48
  }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
49
- onClick?: ((event: KeyboardEvent | MouseEvent) => any) | undefined;
49
+ onClick?: ((event: MouseEvent | KeyboardEvent) => any) | undefined;
50
50
  }>, {
51
51
  size: "default" | "compact";
52
52
  tint: "icon" | "value";
@@ -237,8 +237,8 @@ declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {
237
237
  height: string;
238
238
  readonly: boolean;
239
239
  selectionMode: MapSelectSelectionMode;
240
- features: MapSelectFeature[];
241
240
  collapsed: boolean;
241
+ features: MapSelectFeature[];
242
242
  scopeGeometry: MapSelectGeometry | null;
243
243
  tileUrl: string;
244
244
  tileAttribution: string;
@@ -29,9 +29,9 @@ type __VLS_Slots = {} & {
29
29
  hint?: (props: typeof __VLS_8) => any;
30
30
  };
31
31
  declare const __VLS_base: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
32
- click: (event: KeyboardEvent | MouseEvent) => any;
32
+ click: (event: MouseEvent | KeyboardEvent) => any;
33
33
  }, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
34
- onClick?: ((event: KeyboardEvent | MouseEvent) => any) | undefined;
34
+ onClick?: ((event: MouseEvent | KeyboardEvent) => any) | undefined;
35
35
  }>, {
36
36
  size: "default" | "compact";
37
37
  notation: "compact" | "standard";