wcz-layout 10.0.0 → 10.1.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.
Files changed (74) hide show
  1. package/dist/{AggregatedCell-BtKC5-m6.mjs → AggregatedCell-C7nAQyMO.mjs} +15 -2
  2. package/dist/AggregatedCell-C7nAQyMO.mjs.map +1 -0
  3. package/dist/{Approval-C-hF4jbT.mjs → Approval-DoD-GRRH.mjs} +18 -14
  4. package/dist/Approval-DoD-GRRH.mjs.map +1 -0
  5. package/dist/{Employee-DbdStvU0.d.mts → Employee-N9fRSnIl.d.mts} +30 -14
  6. package/dist/FileMeta-DDqUju1Y.mjs.map +1 -1
  7. package/dist/{LayoutTable-4DLs-NI-.d.mts → LayoutTable-DX9IaO8V.d.mts} +205 -197
  8. package/dist/RouterListItemButton-ULMlaQh6.mjs.map +1 -1
  9. package/dist/{approval-DFExxyAJ.mjs → approval-DiNOXd4B.mjs} +4 -4
  10. package/dist/approval-DiNOXd4B.mjs.map +1 -0
  11. package/dist/auth.mjs +4 -4
  12. package/dist/components.d.mts +1 -1
  13. package/dist/components.mjs +47 -21
  14. package/dist/components.mjs.map +1 -1
  15. package/dist/{createApi-CLYWCzR2.mjs → createApi-DGJJ4I_R.mjs} +3 -3
  16. package/dist/{createApi-CLYWCzR2.mjs.map → createApi-DGJJ4I_R.mjs.map} +1 -1
  17. package/dist/data/client.d.mts +183 -64
  18. package/dist/data/client.mjs +5 -5
  19. package/dist/data/client.mjs.map +1 -1
  20. package/dist/data/server.d.mts +1 -1
  21. package/dist/data/server.mjs +4 -4
  22. package/dist/{file-aSQto2rw.mjs → file-C14fhUeg.mjs} +4 -4
  23. package/dist/{file-aSQto2rw.mjs.map → file-C14fhUeg.mjs.map} +1 -1
  24. package/dist/{file-CZwQfvTU.mjs → file-C5BOj1q8.mjs} +4 -4
  25. package/dist/file-C5BOj1q8.mjs.map +1 -0
  26. package/dist/hooks.d.mts +1 -1
  27. package/dist/hooks.mjs +461 -452
  28. package/dist/hooks.mjs.map +1 -1
  29. package/dist/index.mjs +4 -4
  30. package/dist/index.mjs.map +1 -1
  31. package/dist/middleware.mjs +2 -2
  32. package/dist/middleware.mjs.map +1 -1
  33. package/dist/models.d.mts +22 -2
  34. package/dist/models.mjs +1 -1
  35. package/dist/{peoplesoft-BY_75WTS.d.mts → peoplesoft-BIdTNshE.d.mts} +2 -3
  36. package/dist/{peoplesoft-CQnc01Hc.mjs → peoplesoft-BkJMCcHb.mjs} +3 -3
  37. package/dist/peoplesoft-BkJMCcHb.mjs.map +1 -0
  38. package/dist/{providers-Dbl95AxR.mjs → providers-DrairEO2.mjs} +2 -2
  39. package/dist/providers-DrairEO2.mjs.map +1 -0
  40. package/dist/{tokens-D8CVIFTb.mjs → tokens-BLRreL1j.mjs} +3 -3
  41. package/dist/tokens-BLRreL1j.mjs.map +1 -0
  42. package/dist/{utils-KaM5VMTJ.mjs → utils-BUpDoqme.mjs} +13 -13
  43. package/dist/utils-BUpDoqme.mjs.map +1 -0
  44. package/dist/utils.mjs +1 -1
  45. package/package.json +16 -14
  46. package/skills/ai/SKILL.md +59 -0
  47. package/skills/client-db/SKILL.md +47 -43
  48. package/skills/db-schema/SKILL.md +6 -0
  49. package/skills/dialogs/SKILL.md +8 -6
  50. package/skills/forms/SKILL.md +19 -1
  51. package/skills/general/SKILL.md +21 -19
  52. package/skills/general/references/exports.md +6 -3
  53. package/skills/migrations/versions/migrate-v10-to-v11.md +1 -0
  54. package/skills/migrations/versions/migrate-v9-to-v10.md +26 -25
  55. package/skills/routing/SKILL.md +7 -4
  56. package/skills/server-functions/SKILL.md +8 -5
  57. package/skills/services/SKILL.md +1 -1
  58. package/skills/services/docs/approval.md +258 -257
  59. package/skills/services/docs/peoplesoft.md +4 -0
  60. package/skills/start/SKILL.md +3 -2
  61. package/skills/start/steps/02-project-name-setup.md +1 -1
  62. package/skills/start/steps/07-vault-setup.md +5 -4
  63. package/skills/table/SKILL.md +20 -31
  64. package/dist/AggregatedCell-BtKC5-m6.mjs.map +0 -1
  65. package/dist/Approval-C-hF4jbT.mjs.map +0 -1
  66. package/dist/approval-DFExxyAJ.mjs.map +0 -1
  67. package/dist/file-CZwQfvTU.mjs.map +0 -1
  68. package/dist/peoplesoft-CQnc01Hc.mjs.map +0 -1
  69. package/dist/providers-Dbl95AxR.mjs.map +0 -1
  70. package/dist/tokens-D8CVIFTb.mjs.map +0 -1
  71. package/dist/utils-KaM5VMTJ.mjs.map +0 -1
  72. package/skills/unslop/SKILL.md +0 -80
  73. /package/skills/start/steps/{10-gitlab-ci.md → 09-gitlab-ci.md} +0 -0
  74. /package/skills/start/steps/{09-commit.md → 10-commit.md} +0 -0
@@ -1,257 +1,258 @@
1
- # approval
2
-
3
- ## Client
4
-
5
- - Query:
6
- `approvalsQueryOptions`
7
- `approvalQueryOptions`
8
- - Mutation:
9
- `createApprovalMutationOptions`
10
- `approveApprovalMutationOptions`
11
- `resubmitApprovalMutationOptions`
12
- `withdrawApprovalMutationOptions`
13
- `cancelApprovalMutationOptions`
14
-
15
- ## Server
16
-
17
- - Fetch:
18
- `getApprovals`
19
- `getApproval`
20
- - Mutate:
21
- `createApproval`
22
- `approveApproval`
23
- `resubmitApproval`
24
- `withdrawApproval`
25
- `cancelApproval`
26
-
27
- ## Schemas/Models
28
-
29
- ```ts
30
- const ApprovalRequestType = z.enum(["Single", "Batch"]);
31
-
32
- const ApprovalStatus = z.enum([
33
- "WaitingForApproval",
34
- "Approved",
35
- "PartiallyApproved",
36
- "Rejected",
37
- "Withdrawn",
38
- "Cancelled",
39
- ]);
40
-
41
- const ApprovalStepResult = z.enum([
42
- "NotAvailable",
43
- "FutureApproval",
44
- "WaitingForApproval",
45
- "Approved",
46
- "Rejected",
47
- "Skipped",
48
- "Withdrawn",
49
- "Cancelled",
50
- ]);
51
-
52
- const StepApprovalOrder = z.enum(["Serial", "Parallel", "OneOfThem"]);
53
-
54
- const ApprovalEmployeeSchema = z.object({
55
- employeeId: z.string().trim().min(1).max(20),
56
- name: z.string().trim().min(1).max(50),
57
- email: z.email().min(1).max(100),
58
- });
59
-
60
- const ApprovalFlowStepSchema = z.object({
61
- id: z.uuid(),
62
- order: z.number(),
63
- approverRole: z.string().trim().min(1).max(100).default("Approver").optional(),
64
- approver: ApprovalEmployeeSchema,
65
- actualApprover: ApprovalEmployeeSchema.optional(),
66
- result: ApprovalStepResult.default("NotAvailable").optional(),
67
- resultDate: z.date().optional(),
68
- resultComment: z.string().trim().max(2000).optional(),
69
- });
70
-
71
- const ApprovalFlowSchema = z.object({
72
- id: z.uuid(),
73
- approvalStage: z.number(),
74
- batchSequence: z.number().optional(),
75
- approvalSequence: z.number(),
76
- stepApprovalOrder: StepApprovalOrder,
77
- steps: z.array(ApprovalFlowStepSchema),
78
- isActive: z.boolean().default(false).optional(),
79
- });
80
-
81
- const ApprovalCoRequestorGroupSchema = z.object({
82
- role: z.string().trim().min(1),
83
- email: z.email(),
84
- });
85
-
86
- const ApprovalCoRequestorEmployeeSchema = z.object({
87
- employeeId: z.string().trim().min(1),
88
- name: z.string().trim().min(1),
89
- email: z.email(),
90
- });
91
-
92
- const ApprovalCoRequestorPrincipalSchema = z.union([
93
- ApprovalCoRequestorGroupSchema,
94
- ApprovalCoRequestorEmployeeSchema,
95
- ]);
96
-
97
- const ApprovalCoRequestorPermissionsSchema = z.object({
98
- withdraw: z.boolean().default(false).optional(),
99
- cancel: z.boolean().default(false).optional(),
100
- });
101
-
102
- const ApprovalCoRequestorSchema = z.object({
103
- id: z.uuid(),
104
- principal: ApprovalCoRequestorPrincipalSchema,
105
- permissions: ApprovalCoRequestorPermissionsSchema,
106
- });
107
-
108
- const HqApprovalColSchema = z.object({
109
- title: z.string().optional(),
110
- text: z.string().optional(),
111
- textColor: z.string().optional(),
112
- textSize: z.string().optional(),
113
- });
114
-
115
- const HqApprovalRowSchema = z.object({ col: z.array(HqApprovalColSchema) });
116
-
117
- const HqApprovalSectionSchema = z.object({
118
- row: z.array(HqApprovalRowSchema),
119
- title: z.string().optional(),
120
- type: z.string().optional(),
121
- text: z.string().optional(),
122
- });
123
-
124
- const HqApprovalPageSchema = z.object({ section: z.array(HqApprovalSectionSchema) });
125
-
126
- const HqApprovalSummarySchema = z.object({ page: z.array(HqApprovalPageSchema) });
127
-
128
- const HqApprovalFormDataSchema = z.object({
129
- systemId: z.string().optional(),
130
- formType: z.string().optional(),
131
- formId: z.string().optional(),
132
- stepName: z.string().optional(),
133
- userId: z.string().optional(),
134
- title: z.string().optional(),
135
- subject: z.string().optional(),
136
- summary: HqApprovalSummarySchema.optional(),
137
- messageId: z.string().optional(),
138
- attachList: z.string().optional(),
139
- chkResult: z.string().optional(),
140
- apprSummary: z.string().optional(),
141
- approvalComment: z.string().optional(),
142
- });
143
-
144
- const HqApprovalHeaderSchema = z.object({
145
- serviceId: z.string().optional(),
146
- authorizationCode: z.string().optional(),
147
- dataCreatedTime: z.string().optional(),
148
- characterEnable: z.boolean().default(false).optional(),
149
- });
150
-
151
- const HqApprovalRequestSchema = z.object({
152
- header: HqApprovalHeaderSchema.optional(),
153
- formData: HqApprovalFormDataSchema.optional(),
154
- });
155
-
156
- const ApprovalSchema = z.object({
157
- id: z.uuid(),
158
- number: z.string().trim().max(30).optional(),
159
- applicationName: z.string().trim().min(1).max(50),
160
- type: ApprovalRequestType.default("Single").optional(),
161
- status: ApprovalStatus,
162
- created: z.date(),
163
- createdBy: z.custom<ApprovalEmployee>(),
164
- updated: z.date().optional(),
165
- updatedBy: z.custom<ApprovalEmployee>().optional(),
166
- approvalFlows: z.array(z.custom<ApprovalFlow>()).min(1),
167
- currentApprovers: z.array(z.custom<ApprovalEmployee>()),
168
- coRequestors: z.array(ApprovalCoRequestorSchema).optional(),
169
- });
170
-
171
- const GetApprovalsSchema = z.object({
172
- appName: z.string().min(1).max(255),
173
- status: ApprovalStatus.optional(),
174
- approverEmployeeId: z.string().min(1).max(20).optional(),
175
- stepResult: ApprovalStepResult.optional(),
176
- });
177
-
178
- const GetApprovalSchema = z.object({
179
- id: z.uuid(),
180
- });
181
-
182
- const CreateApprovalSchema = ApprovalSchema.pick({
183
- id: true,
184
- number: true,
185
- applicationName: true,
186
- type: true,
187
- status: true,
188
- approvalFlows: true,
189
- }).extend({
190
- emailBody: z.string().trim().min(1),
191
- hqApprovalRequest: HqApprovalRequestSchema.optional(),
192
- approvalFlows: z
193
- .array(
194
- ApprovalFlowSchema.pick({
195
- approvalStage: true,
196
- batchSequence: true,
197
- stepApprovalOrder: true,
198
- steps: true,
199
- }).extend({
200
- steps: z.array(ApprovalFlowStepSchema.pick({ approverRole: true, approver: true })),
201
- }),
202
- )
203
- .min(1),
204
- coRequestors: z.array(ApprovalCoRequestorSchema).optional(),
205
- });
206
-
207
- const ApproveApprovalSchema = z.object({
208
- id: z.uuid(),
209
- result: ApprovalStepResult,
210
- resultComment: z.string().trim().max(2000).optional(),
211
- emailBody: z.string().trim().min(1),
212
- });
213
-
214
- const ResubmitApprovalSchema = ApprovalSchema.pick({
215
- id: true,
216
- approvalFlows: true,
217
- }).extend({
218
- approvalFlows: z
219
- .array(
220
- ApprovalFlowSchema.pick({
221
- approvalStage: true,
222
- batchSequence: true,
223
- stepApprovalOrder: true,
224
- steps: true,
225
- }).extend({
226
- steps: z.array(ApprovalFlowStepSchema.pick({ approverRole: true, approver: true })),
227
- }),
228
- )
229
- .min(1),
230
- });
231
-
232
- const CancelApprovalSchema = z.object({
233
- id: z.uuid(),
234
- comment: z.string().trim().min(1).max(2000),
235
- emailBody: z.string().trim().min(1),
236
- });
237
-
238
- const WithdrawApprovalSchema = z.object({
239
- id: z.uuid(),
240
- comment: z.string().trim().min(1).max(2000),
241
- emailBody: z.string().trim().min(1),
242
- });
243
- ```
244
-
245
- ## Examples
246
-
247
- ```ts
248
- import { approvalQueryOptions, approveApprovalMutationOptions } from "wcz-layout/data/client";
249
- import { approveApproval } from "wcz-layout/data/server";
250
-
251
- // client
252
- const { data: approval } = useQuery(approvalQueryOptions({ id }));
253
- const { mutate: approve } = useMutation(approveApprovalMutationOptions({ queryClient }));
254
-
255
- // server
256
- await approveApproval({ data: { id, result: "Approved", emailBody } });
257
- ```
1
+ # approval
2
+
3
+ ## Client
4
+
5
+ - Query:
6
+ `approvalsQueryOptions`
7
+ `approvalQueryOptions`
8
+ - Mutation:
9
+ `createApprovalMutationOptions`
10
+ `approveApprovalMutationOptions`
11
+ `resubmitApprovalMutationOptions`
12
+ `withdrawApprovalMutationOptions`
13
+ `cancelApprovalMutationOptions`
14
+
15
+ ## Server
16
+
17
+ - Fetch:
18
+ `getApprovals`
19
+ `getApproval`
20
+ - Mutate:
21
+ `createApproval`
22
+ `approveApproval`
23
+ `resubmitApproval`
24
+ `withdrawApproval`
25
+ `cancelApproval`
26
+
27
+ ## Schemas/Models
28
+
29
+ ```ts
30
+ const ApprovalRequestType = z.enum(["Single", "Batch"]);
31
+
32
+ const ApprovalStatus = z.enum([
33
+ "WaitingForApproval",
34
+ "Approved",
35
+ "PartiallyApproved",
36
+ "Rejected",
37
+ "Withdrawn",
38
+ "Cancelled",
39
+ ]);
40
+
41
+ const ApprovalStepResult = z.enum([
42
+ "NotAvailable",
43
+ "FutureApproval",
44
+ "WaitingForApproval",
45
+ "Approved",
46
+ "Rejected",
47
+ "Skipped",
48
+ "Withdrawn",
49
+ "Cancelled",
50
+ ]);
51
+
52
+ const StepApprovalOrder = z.enum(["Serial", "Parallel", "OneOfThem"]);
53
+
54
+ const ApprovalEmployeeSchema = z.object({
55
+ employeeId: z.string().trim().min(1).max(20),
56
+ name: z.string().trim().min(1).max(50),
57
+ email: z.email().min(1).max(100),
58
+ });
59
+
60
+ const ApprovalFlowStepSchema = z.object({
61
+ id: z.uuid(),
62
+ order: z.number(),
63
+ approverRole: z.string().trim().min(1).max(100).default("Approver").optional(),
64
+ approver: ApprovalEmployeeSchema,
65
+ actualApprover: ApprovalEmployeeSchema.optional(),
66
+ result: ApprovalStepResult.default("NotAvailable").optional(),
67
+ resultDate: z.date().optional(),
68
+ resultComment: z.string().trim().max(2000).optional(),
69
+ });
70
+
71
+ const ApprovalFlowSchema = z.object({
72
+ id: z.uuid(),
73
+ approvalStage: z.number(),
74
+ batchSequence: z.number().optional(),
75
+ approvalSequence: z.number(),
76
+ stepApprovalOrder: StepApprovalOrder,
77
+ steps: z.array(ApprovalFlowStepSchema),
78
+ isActive: z.boolean().default(false).optional(),
79
+ });
80
+
81
+ const ApprovalCoRequestorGroupSchema = z.object({
82
+ role: z.string().trim().min(1),
83
+ email: z.email(),
84
+ });
85
+
86
+ const ApprovalCoRequestorEmployeeSchema = z.object({
87
+ employeeId: z.string().trim().min(1),
88
+ name: z.string().trim().min(1),
89
+ email: z.email(),
90
+ });
91
+
92
+ const ApprovalCoRequestorPrincipalSchema = z.union([
93
+ ApprovalCoRequestorGroupSchema,
94
+ ApprovalCoRequestorEmployeeSchema,
95
+ ]);
96
+
97
+ const ApprovalCoRequestorPermissionsSchema = z.object({
98
+ withdraw: z.boolean().default(false).optional(),
99
+ cancel: z.boolean().default(false).optional(),
100
+ });
101
+
102
+ const ApprovalCoRequestorSchema = z.object({
103
+ id: z.uuid(),
104
+ principal: ApprovalCoRequestorPrincipalSchema,
105
+ permissions: ApprovalCoRequestorPermissionsSchema,
106
+ });
107
+
108
+ const HqApprovalColSchema = z.object({
109
+ title: z.string().optional(),
110
+ text: z.string().optional(),
111
+ textColor: z.string().optional(),
112
+ textSize: z.string().optional(),
113
+ });
114
+
115
+ const HqApprovalRowSchema = z.object({ col: z.array(HqApprovalColSchema) });
116
+
117
+ const HqApprovalSectionSchema = z.object({
118
+ row: z.array(HqApprovalRowSchema),
119
+ title: z.string().optional(),
120
+ type: z.string().optional(),
121
+ text: z.string().optional(),
122
+ });
123
+
124
+ const HqApprovalPageSchema = z.object({ section: z.array(HqApprovalSectionSchema) });
125
+
126
+ const HqApprovalSummarySchema = z.object({ page: z.array(HqApprovalPageSchema) });
127
+
128
+ const HqApprovalFormDataSchema = z.object({
129
+ systemId: z.string().optional(),
130
+ formType: z.string().optional(),
131
+ formId: z.string().optional(),
132
+ stepName: z.string().optional(),
133
+ userId: z.string().optional(),
134
+ title: z.string().optional(),
135
+ subject: z.string().optional(),
136
+ summary: HqApprovalSummarySchema.optional(),
137
+ messageId: z.string().optional(),
138
+ attachList: z.string().optional(),
139
+ chkResult: z.string().optional(),
140
+ apprSummary: z.string().optional(),
141
+ approvalComment: z.string().optional(),
142
+ });
143
+
144
+ const HqApprovalHeaderSchema = z.object({
145
+ serviceId: z.string().optional(),
146
+ authorizationCode: z.string().optional(),
147
+ dataCreatedTime: z.string().optional(),
148
+ characterEnable: z.boolean().default(false).optional(),
149
+ });
150
+
151
+ const HqApprovalRequestSchema = z.object({
152
+ header: HqApprovalHeaderSchema.optional(),
153
+ formData: HqApprovalFormDataSchema.optional(),
154
+ });
155
+
156
+ const ApprovalSchema = z.object({
157
+ id: z.uuid(),
158
+ number: z.string().trim().min(1).max(30),
159
+ applicationName: z.string().trim().min(1).max(50),
160
+ type: ApprovalRequestType.default("Single").optional(),
161
+ status: ApprovalStatus,
162
+ created: z.date(),
163
+ createdBy: z.custom<ApprovalEmployee>(),
164
+ updated: z.date().optional(),
165
+ updatedBy: z.custom<ApprovalEmployee>().optional(),
166
+ approvalFlows: z.array(z.custom<ApprovalFlow>()).min(1),
167
+ currentApprovers: z.array(z.custom<ApprovalEmployee>()),
168
+ coRequestors: z.array(ApprovalCoRequestorSchema).optional(),
169
+ });
170
+
171
+ const GetApprovalsSchema = z.object({
172
+ appName: z.string().min(1).max(255),
173
+ status: ApprovalStatus.optional(),
174
+ approverEmployeeId: z.string().min(1).max(20).optional(),
175
+ stepResult: ApprovalStepResult.optional(),
176
+ });
177
+
178
+ const GetApprovalSchema = z.object({
179
+ id: z.uuid(),
180
+ });
181
+
182
+ const CreateApprovalSchema = ApprovalSchema.pick({
183
+ id: true,
184
+ number: true,
185
+ applicationName: true,
186
+ type: true,
187
+ status: true,
188
+ approvalFlows: true,
189
+ }).extend({
190
+ emailBody: z.string().trim().min(1),
191
+ hqApprovalRequest: HqApprovalRequestSchema.optional(),
192
+ approvalFlows: z
193
+ .array(
194
+ ApprovalFlowSchema.pick({
195
+ approvalStage: true,
196
+ batchSequence: true,
197
+ stepApprovalOrder: true,
198
+ steps: true,
199
+ }).extend({
200
+ steps: z.array(ApprovalFlowStepSchema.pick({ approverRole: true, approver: true })),
201
+ }),
202
+ )
203
+ .min(1),
204
+ coRequestors: z.array(ApprovalCoRequestorSchema).optional(),
205
+ });
206
+
207
+ const ApproveApprovalSchema = z.object({
208
+ id: z.uuid(),
209
+ result: ApprovalStepResult,
210
+ resultComment: z.string().trim().max(2000).optional(),
211
+ emailBody: z.string().trim().min(1),
212
+ });
213
+
214
+ const ResubmitApprovalSchema = ApprovalSchema.pick({
215
+ id: true,
216
+ approvalFlows: true,
217
+ }).extend({
218
+ emailBody: z.string().trim().min(1),
219
+ approvalFlows: z
220
+ .array(
221
+ ApprovalFlowSchema.pick({
222
+ approvalStage: true,
223
+ batchSequence: true,
224
+ stepApprovalOrder: true,
225
+ steps: true,
226
+ }).extend({
227
+ steps: z.array(ApprovalFlowStepSchema.pick({ approverRole: true, approver: true })),
228
+ }),
229
+ )
230
+ .min(1),
231
+ });
232
+
233
+ const CancelApprovalSchema = z.object({
234
+ id: z.uuid(),
235
+ comment: z.string().trim().min(1).max(2000),
236
+ emailBody: z.string().trim().min(1),
237
+ });
238
+
239
+ const WithdrawApprovalSchema = z.object({
240
+ id: z.uuid(),
241
+ comment: z.string().trim().min(1).max(2000),
242
+ emailBody: z.string().trim().min(1),
243
+ });
244
+ ```
245
+
246
+ ## Examples
247
+
248
+ ```ts
249
+ import { approvalQueryOptions, approveApprovalMutationOptions } from "wcz-layout/data/client";
250
+ import { approveApproval } from "wcz-layout/data/server";
251
+
252
+ // client
253
+ const { data: approval } = useQuery(approvalQueryOptions({ id }));
254
+ const { mutate: approve } = useMutation(approveApprovalMutationOptions({ queryClient }));
255
+
256
+ // server
257
+ await approveApproval({ data: { id, result: "Approved", emailBody } });
258
+ ```
@@ -13,11 +13,15 @@
13
13
  `employeeManagerQueryOptions`
14
14
  `employeeGeneralManagerQueryOptions`
15
15
  `companyGeneralManagerQueryOptions`
16
+ `searchEmployees`
17
+ `getEmployees`
18
+ `getActiveEmployees`
16
19
  - Department:
17
20
  `departmentsQueryOptions`
18
21
  `departmentByIdQueryOptions`
19
22
  `departmentManagerQueryOptions`
20
23
  `departmentEmployeesQueryOptions`
24
+ `getDepartments`
21
25
 
22
26
  ## Server
23
27
 
@@ -44,8 +44,9 @@ Then list all steps by name so the user can pick.
44
44
  | 6 | [06-entra-setup.md](steps/06-entra-setup.md) | Entra ID app registration |
45
45
  | 7 | [07-vault-setup.md](steps/07-vault-setup.md) | Vault secrets configuration |
46
46
  | 8 | [08-generate-favicon.md](steps/08-generate-favicon.md) | Generate and replace favicon |
47
- | 9 | [09-commit.md](steps/09-commit.md) | Commit and push to origin |
47
+ | 9 | [09-gitlab-ci.md](steps/09-gitlab-ci.md) | SAST setup before the first run |
48
+ | 10 | [10-commit.md](steps/10-commit.md) | Commit and push to origin |
48
49
 
49
50
  ## Completion
50
51
 
51
- After step 9 succeeds, the workflow ends — no further action needed.
52
+ After step 10 succeeds, the workflow ends — no further action needed.
@@ -16,4 +16,4 @@ Using the full name, search-and-replace across the **entire workspace**:
16
16
  | `project-name` | kebab-case version (e.g. `user-input`) |
17
17
  | `Project Name` | Title Case version (e.g. `User Input`) |
18
18
 
19
- If a short name was provided, add it as the `short_name` property in `public/manifest.json`.
19
+ If a short name was provided, set the `short_name` property in `public/manifest.json` to it.
@@ -94,7 +94,8 @@ drizzle-kit reads them directly and never goes through Vault.
94
94
 
95
95
  `VAULT_SECRET_PATH` is the secret path **without** the mount point (`release`)
96
96
  and **including** the trailing `/default` — the app builds
97
- `/v1/<mount>/data/<VAULT_SECRET_PATH>` (see `src/lib/vite-plugin.ts`).
97
+ `/v1/<mount>/data/<VAULT_SECRET_PATH>` (the `viteWczLayout()` plugin from `wcz-layout/vite`
98
+ does this).
98
99
  `VAULT_MOUNT_POINT` defaults to `release` and only needs to be set if the
99
100
  engine is mounted elsewhere. If `VAULT_ADDRESS` is unset, Vault fetching is
100
101
  skipped silently (plain local-dev fallback).
@@ -109,6 +110,6 @@ DATABASE_URL=<kept — local dev DB or QAS, per user choice>
109
110
  DATABASE_AUTO_MIGRATE=<kept>
110
111
  ```
111
112
 
112
- After writing, verify end-to-end: start the dev server (or replicate the
113
- login + fetch from `src/lib/vite-plugin.ts`) and confirm all expected keys
114
- come back from Vault.
113
+ After writing, verify end-to-end: start the dev server — `viteWczLayout()`
114
+ logs in and loads the Vault secrets into `process.env` during `vp dev` — and
115
+ confirm that every expected key comes back from Vault.
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: table
3
- description: "Use when building or changing a data table, grid, or list page. Covers useLayoutTable, LayoutTable, createLayoutColumnHelper, column definitions and headers, cell formatters, filter variants, sorting, row selection and bulk actions, per-row actions, pagination, footer aggregation."
3
+ description: "Use when building or changing a data table. Covers useLayoutTable, LayoutTable, createLayoutColumnHelper, column definitions and headers, cell formatters, filter variants, sorting, row selection and bulk actions, per-row actions, pagination, footer aggregation."
4
4
  metadata:
5
5
  type: convention
6
6
  library: wcz-layout
@@ -15,49 +15,36 @@ metadata:
15
15
 
16
16
  ## Rules
17
17
 
18
- - For selection and actions display columns, always set `size: 50`,
19
- `enableResizing: false`, and `enableCellSelection: false`.
20
- - Create the column helper once at module scope, outside the component:
21
- `const columnHelper = createLayoutColumnHelper<Todo>()`. Wrap the array in
22
- `columnHelper.columns([...])` so each column keeps its own value type.
23
18
  - Build the instance with `useLayoutTable({ data, columns })` and pass it to
24
19
  `<LayoutTable table={table} />`. Rows are keyed by `row.id`, so every row object
25
20
  needs an `id`.
21
+ - For selection and actions display columns, always set `size: 50`,
22
+ `enableResizing: false`, and `enableCellSelection: false`. An actions column
23
+ that shows more than one button needs about 40px more per extra button.
26
24
  - Render cells with the bound components off the render prop
27
25
  (`cell.ValueCell`, `NumberCell`, `DateCell`, `DateTimeCell`, `BooleanCell`)
28
26
  instead of raw JSX. They carry the alignment, the number and date locale, and
29
27
  the noWrap behaviour. Write raw JSX only when the cell is a link or
30
28
  another interactive element.
31
- - Set `meta.variant` for non-text filters. Omission means `"text"`.
32
29
  - Give `meta.label` to any column whose `header` is not a plain string. A string
33
30
  header supplies the label automatically; a function or JSX header leaves the
34
31
  header menu and column selector without a label; the filter picker falls back to
35
- `column.id`. `meta` has four keys: `label`, `align`, `variant`, `options`.
32
+ `column.id`. `meta` has five keys: `label`, `align`, `variant`, `options`, `flex`.
33
+ - `meta.flex` makes a column share the width left over from the sized columns, in
34
+ proportion like CSS `flex-grow`. `size` stays its minimum width. Resizing the column
35
+ pins it to a fixed width.
36
+ - Wrap the table in `Fullscreen` when it is the only content on the page.
37
+ - Props: `title`, `actions`, `showToolbar`,
38
+ `loading`, `pagination`, `pageSizeOptions`, `onRowClick`, `onRowDoubleClick`,
39
+ `sx`, and the `disableSearch` / `disableColumnFilter` / `disableColumnSelector` /
40
+ `disableColumnMenu` escape hatches.
41
+ - Rows and columns virtualize by default.
42
+ - Set `meta.variant` for non-text filters. Omission means `"text"`.
36
43
  - Do not enumerate `meta.options` for a free-text column. `select` and
37
44
  `multi-select` read their options from the faceted unique values, so the choices
38
45
  track the data. Pass explicit string options when labels differ from stored values or
39
46
  the UI needs a fixed list. Derive database-enum options from `enumValues`, never a
40
47
  second hand-written list.
41
- - Translate every `header`. The table's own strings come from the app's
42
- `src/lib/locales/*.json` under `Layout.Table`. See the `general` skill for the
43
- setup step: the app owns the whole `Layout` namespace, not just `Layout.Table`.
44
- - Wrap the table in `Fullscreen` when it is the only content on the page.
45
- - Rows and columns virtualize by default. Pass `pagination` for page-based navigation.
46
- Virtualization reduces rendered DOM; it does not reduce fetched data or replace
47
- server-side pagination. Column virtualization
48
- switches off for grouped header rows and while `loading`, which is a real perf
49
- cliff on wide tables that use `columnHelper.group`.
50
- - Props go on `LayoutTable`, not on a slot: `title`, `actions`, `showToolbar`,
51
- `loading`, `pagination`, `pageSizeOptions`, `onRowClick`, `onRowDoubleClick`,
52
- `sx`, and the `disableSearch` / `disableColumnFilter` / `disableColumnSelector` /
53
- `disableColumnMenu` escape hatches.
54
- - Omit the second `useLayoutTable` selector when passing its result to `LayoutTable`; the
55
- renderer requires the full selected state.
56
- - For bulk actions read `table.getSelectedRowIds()` and clear with
57
- `table.resetRowSelection()`. For per-row actions add a `display` column rendering
58
- `cell.ActionsCell` with a `RowAction[]`.
59
- - A footer total needs both halves: `aggregationFn` on the column and
60
- `footer: ({ header }) => <header.AggregationFooter />`.
61
48
 
62
49
  ## Example
63
50
 
@@ -86,6 +73,7 @@ function RouteComponent() {
86
73
  cell: ({ cell }) => <cell.SelectCell />,
87
74
  size: 50,
88
75
  enableResizing: false,
76
+ enableCellSelection: false,
89
77
  }),
90
78
  columnHelper.accessor("name", {
91
79
  header: t("Todo.Name"),
@@ -221,15 +209,16 @@ columnHelper.display({
221
209
  {
222
210
  label: t("Delete"),
223
211
  icon: <Delete fontSize="small" />,
224
- divider: true,
212
+ showInMenu: true,
225
213
  onClick: (row) => remove(row.id),
226
214
  },
227
215
  ]}
228
216
  />
229
217
  ),
230
- size: 60,
218
+ size: 50,
231
219
  enableResizing: false,
232
- }),
220
+ enableCellSelection: false,
221
+ });
233
222
  ```
234
223
 
235
224
  ### Other bound components