@vef-framework-react/approval 2.26.0 → 2.27.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 (88) hide show
  1. package/dist/cjs/pages/category-page/index.cjs +1 -1
  2. package/dist/cjs/pages/delegation-page/form.cjs +1 -1
  3. package/dist/cjs/pages/delegation-page/index.cjs +1 -1
  4. package/dist/cjs/pages/flow-page/index.cjs +1 -1
  5. package/dist/cjs/pages/initiate-page/index.cjs +1 -1
  6. package/dist/cjs/pages/initiate-page/start-drawer.cjs +1 -1
  7. package/dist/cjs/pages/my-instances-page/index.cjs +1 -1
  8. package/dist/cjs/pages/task-center-page/index.cjs +1 -1
  9. package/dist/es/api/admin-api.js +1 -1
  10. package/dist/es/api/category-api.js +1 -1
  11. package/dist/es/api/delegation-api.js +1 -1
  12. package/dist/es/api/flow-api.js +1 -1
  13. package/dist/es/api/index.js +1 -1
  14. package/dist/es/api/instance-api.js +1 -1
  15. package/dist/es/api/my-api.js +1 -1
  16. package/dist/es/api/query.js +1 -1
  17. package/dist/es/components/action-dialog/index.js +1 -1
  18. package/dist/es/components/detail/action-modals.js +1 -1
  19. package/dist/es/components/detail/admin.js +1 -1
  20. package/dist/es/components/detail/drawer.js +1 -1
  21. package/dist/es/components/detail/index.js +1 -1
  22. package/dist/es/components/flow-graph/index.js +1 -1
  23. package/dist/es/components/flow-graph/node.js +1 -1
  24. package/dist/es/components/flow-graph/people-overlay.js +1 -1
  25. package/dist/es/components/flow-graph/people.js +1 -1
  26. package/dist/es/components/form-panel/index.js +1 -1
  27. package/dist/es/components/format.js +1 -1
  28. package/dist/es/components/icon.js +1 -1
  29. package/dist/es/components/index.js +1 -1
  30. package/dist/es/components/principal/index.js +1 -1
  31. package/dist/es/components/status/colors.js +1 -1
  32. package/dist/es/components/status/index.js +1 -1
  33. package/dist/es/components/status/labels.js +1 -1
  34. package/dist/es/components/timeline/index.js +1 -1
  35. package/dist/es/components/user/index.js +1 -1
  36. package/dist/es/index.js +1 -1
  37. package/dist/es/pages/admin-page/index.js +1 -1
  38. package/dist/es/pages/admin-page/instances.js +1 -1
  39. package/dist/es/pages/admin-page/metrics.js +1 -1
  40. package/dist/es/pages/admin-page/projections.js +1 -1
  41. package/dist/es/pages/admin-page/tasks.js +1 -1
  42. package/dist/es/pages/category-page/columns.js +1 -1
  43. package/dist/es/pages/category-page/form.js +1 -1
  44. package/dist/es/pages/category-page/index.js +2 -1
  45. package/dist/es/pages/delegation-page/columns.js +1 -1
  46. package/dist/es/pages/delegation-page/form.js +17 -14
  47. package/dist/es/pages/delegation-page/index.js +13 -13
  48. package/dist/es/pages/flow-page/columns.js +1 -1
  49. package/dist/es/pages/flow-page/designer/basic-step.js +1 -1
  50. package/dist/es/pages/flow-page/designer/flow-step.js +1 -1
  51. package/dist/es/pages/flow-page/designer/form-step.js +1 -1
  52. package/dist/es/pages/flow-page/designer/index.js +1 -1
  53. package/dist/es/pages/flow-page/designer/review-step.js +1 -1
  54. package/dist/es/pages/flow-page/designer/types.js +1 -1
  55. package/dist/es/pages/flow-page/index.js +3 -2
  56. package/dist/es/pages/flow-page/search.js +1 -1
  57. package/dist/es/pages/flow-page/versions.js +1 -1
  58. package/dist/es/pages/index.js +1 -1
  59. package/dist/es/pages/initiate-page/index.js +30 -32
  60. package/dist/es/pages/initiate-page/start-drawer.js +37 -42
  61. package/dist/es/pages/my-instances-page/index.js +30 -32
  62. package/dist/es/pages/task-center-page/index.js +26 -28
  63. package/dist/es/pages/task-center-page/search.js +1 -1
  64. package/dist/es/permissions.js +1 -1
  65. package/dist/es/plugins/form-context.js +1 -1
  66. package/dist/es/plugins/index.js +1 -1
  67. package/dist/es/types/enums.js +1 -1
  68. package/dist/es/types/index.js +1 -1
  69. package/dist/es/types/tenancy.js +1 -1
  70. package/dist/types/api/flow-api.d.ts +0 -3
  71. package/dist/types/api/my-api.d.ts +1 -4
  72. package/dist/types/pages/category-page/index.d.ts +2 -1
  73. package/dist/types/pages/category-page/props.d.ts +5 -4
  74. package/dist/types/pages/delegation-page/form.d.ts +5 -2
  75. package/dist/types/pages/delegation-page/index.d.ts +1 -1
  76. package/dist/types/pages/delegation-page/props.d.ts +5 -0
  77. package/dist/types/pages/flow-page/index.d.ts +2 -1
  78. package/dist/types/pages/flow-page/props.d.ts +5 -4
  79. package/dist/types/pages/initiate-page/index.d.ts +4 -9
  80. package/dist/types/pages/initiate-page/start-drawer.d.ts +1 -6
  81. package/dist/types/pages/my-instances-page/index.d.ts +1 -5
  82. package/dist/types/pages/task-center-page/index.d.ts +1 -5
  83. package/dist/types/types/category.d.ts +5 -4
  84. package/dist/types/types/flow.d.ts +5 -0
  85. package/dist/types/types/instance.d.ts +4 -9
  86. package/dist/types/types/my.d.ts +0 -4
  87. package/dist/types/types/tenancy.d.ts +5 -5
  88. package/package.json +7 -7
@@ -2,7 +2,8 @@ import { ApprovalFlowPageProps } from './props';
2
2
  export { FlowDesignerDrawer, type FlowDesignerDrawerProps } from './designer';
3
3
  export type { ApprovalFlowPageProps } from './props';
4
4
  /**
5
- * Full-page flow management: the flow list with label filtering, the
5
+ * Full-page flow management of one tenant's flows (`tenantId`): the flow list
6
+ * with label filtering, the
6
7
  * full-screen designer (settings → form → graph → review, deployed and
7
8
  * optionally published in one chain), version history, and activation.
8
9
  * Designer and toggle mutations invalidate the list query, so the table
@@ -7,10 +7,11 @@ export interface ApprovalFlowPageProps {
7
7
  */
8
8
  permissions?: Partial<FlowPermissionCodes>;
9
9
  /**
10
- * The tenant new flows are created under. Multi-tenant hosts pass the
11
- * current tenant; single-tenant deployments keep the backend default. A
12
- * super-admin passes `SHARED_TENANT_ID` to create shared flows, offered to
13
- * every tenant.
10
+ * The tenant whose flows the page manages: the list shows them, and new
11
+ * flows are created under it. Flows are managed across tenants, gated by
12
+ * the permissions, so whoever may manage flows may pass any tenant —
13
+ * `SHARED_TENANT_ID` manages the shared flows, offered to every tenant.
14
+ * Single-tenant deployments keep the default.
14
15
  *
15
16
  * @default "default"
16
17
  */
@@ -1,11 +1,5 @@
1
1
  export { StartInstanceDrawer, type StartInstanceDrawerProps } from './start-drawer';
2
2
  export interface ApprovalInitiatePageProps {
3
- /**
4
- * The tenant to offer and start flows in. Only a super-admin's choice
5
- * counts — omitted, their own tenant; everyone else is always offered their
6
- * own tenant's flows plus the shared ones (`SHARED_TENANT_ID`).
7
- */
8
- tenantId?: string;
9
3
  /**
10
4
  * A fixed label pre-filter (e.g. `{ mobile: "" }` to offer only
11
5
  * mobile-initiable flows). Combined with the user's own label filter.
@@ -21,8 +15,9 @@ export interface ApprovalInitiatePageProps {
21
15
  onStarted?: () => void;
22
16
  }
23
17
  /**
24
- * The initiation portal: every flow the current user may start, grouped by
25
- * category, searchable by keyword and label. Clicking a card opens the start
18
+ * The initiation portal: every flow the current user may start — its tenant's
19
+ * own flows plus the shared ones — grouped by category, searchable by keyword
20
+ * and label. Clicking a card opens the start
26
21
  * drawer with the published form.
27
22
  */
28
- export declare function ApprovalInitiatePage({ tenantId, labels, title, onStarted }: ApprovalInitiatePageProps): import("@emotion/react/jsx-runtime").JSX.Element;
23
+ export declare function ApprovalInitiatePage({ labels, title, onStarted }: ApprovalInitiatePageProps): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -3,11 +3,6 @@ export interface StartInstanceDrawerProps {
3
3
  * The flow to start; `null` keeps the drawer closed.
4
4
  */
5
5
  flowCode: string | null;
6
- /**
7
- * The tenant to start in. Only a super-admin's choice counts — omitted,
8
- * their own tenant; everyone else always starts in their own tenant.
9
- */
10
- tenantId?: string;
11
6
  /**
12
7
  * Prefilled business reference for business-bound flows started from a
13
8
  * host business page.
@@ -24,4 +19,4 @@ export interface StartInstanceDrawerProps {
24
19
  * start-gate (`my.get_start_form`) and submits `instance.start` with the
25
20
  * renderer-validated form data.
26
21
  */
27
- export declare function StartInstanceDrawer({ flowCode, tenantId, businessRef, onClose, onStarted }: StartInstanceDrawerProps): import("@emotion/react/jsx-runtime").JSX.Element;
22
+ export declare function StartInstanceDrawer({ flowCode, businessRef, onClose, onStarted }: StartInstanceDrawerProps): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -1,9 +1,5 @@
1
1
  import { ReactNode } from 'react';
2
2
  export interface ApprovalMyInstancesPageProps {
3
- /**
4
- * Scope the lists to one tenant; omit for the caller's full view.
5
- */
6
- tenantId?: string;
7
3
  /**
8
4
  * Optional page title rendered above each list.
9
5
  */
@@ -13,4 +9,4 @@ export interface ApprovalMyInstancesPageProps {
13
9
  * My submissions and my carbon copies. Returned submissions resubmit from
14
10
  * the detail drawer; opening an unread CC marks it read.
15
11
  */
16
- export declare function ApprovalMyInstancesPage({ tenantId, title }: ApprovalMyInstancesPageProps): import("@emotion/react/jsx-runtime").JSX.Element;
12
+ export declare function ApprovalMyInstancesPage({ title }: ApprovalMyInstancesPageProps): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -1,9 +1,5 @@
1
1
  import { ReactNode } from 'react';
2
2
  export interface ApprovalTaskCenterPageProps {
3
- /**
4
- * Scope the lists to one tenant; omit for the caller's full view.
5
- */
6
- tenantId?: string;
7
3
  /**
8
4
  * Optional page title rendered above each list.
9
5
  */
@@ -14,4 +10,4 @@ export interface ApprovalTaskCenterPageProps {
14
10
  * shows the full detail with the action bar; completing an action refreshes
15
11
  * both the list and the pending badge.
16
12
  */
17
- export declare function ApprovalTaskCenterPage({ tenantId, title }: ApprovalTaskCenterPageProps): import("@emotion/react/jsx-runtime").JSX.Element;
13
+ export declare function ApprovalTaskCenterPage({ title }: ApprovalTaskCenterPageProps): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -35,13 +35,14 @@ export interface CategorySearch {
35
35
  name?: string;
36
36
  isActive?: boolean;
37
37
  /**
38
- * Narrows a super-admin's read to one tenant — `SHARED_TENANT_ID` for the
39
- * shared categories. Everyone else always reads their own tenant.
38
+ * Narrows the read to one tenant's categories — `SHARED_TENANT_ID` for the
39
+ * shared ones. Omitted, every tenant's are read: categories are managed
40
+ * across tenants, gated by permission.
40
41
  */
41
42
  tenantId?: string;
42
43
  /**
43
- * Adds the shared categories to the tenant's own — what a picker scoping a
44
- * delegation needs, since shared flows sit under shared categories.
44
+ * Adds the shared categories to the named tenant's — what a picker scoping
45
+ * a delegation needs, since shared flows sit under shared categories.
45
46
  */
46
47
  includeShared?: boolean;
47
48
  }
@@ -186,6 +186,11 @@ export interface ToggleFlowActiveParams {
186
186
  * equality predicates, AND-combined across pairs.
187
187
  */
188
188
  export interface FlowSearch {
189
+ /**
190
+ * Narrows the list to one tenant's flows — `SHARED_TENANT_ID` for the
191
+ * shared ones. Omitted, every tenant's are listed: flows are managed across
192
+ * tenants, gated by permission.
193
+ */
189
194
  tenantId?: string;
190
195
  categoryId?: string;
191
196
  keyword?: string;
@@ -1,16 +1,11 @@
1
1
  import { AddAssigneeType, ProcessTaskAction } from './enums';
2
2
  /**
3
- * Parameters for `approval/instance.start`. `formData` is the form
4
- * renderer's submit payload, validated server-side against the version's
5
- * derived field list.
3
+ * Parameters for `approval/instance.start`. The instance runs in the tenant
4
+ * the caller acts in, from that tenant's own flows or the shared ones.
5
+ * `formData` is the form renderer's submit payload, validated server-side
6
+ * against the version's derived field list.
6
7
  */
7
8
  export interface StartInstanceParams {
8
- /**
9
- * The tenant the instance runs in. Only a super-admin's choice counts —
10
- * omitted, their own tenant; everyone else always starts in their own
11
- * tenant, from its own flows or the shared ones.
12
- */
13
- tenantId?: string;
14
9
  flowCode: string;
15
10
  /**
16
11
  * Opaque reference to the bound business record; required by convention for
@@ -192,7 +192,6 @@ export interface MyInstanceDetail {
192
192
  * Search parameters for `approval/my.find_available_flows`.
193
193
  */
194
194
  export interface AvailableFlowSearch {
195
- tenantId?: string;
196
195
  keyword?: string;
197
196
  labels?: Record<string, string>;
198
197
  }
@@ -200,7 +199,6 @@ export interface AvailableFlowSearch {
200
199
  * Search parameters for `approval/my.find_initiated`.
201
200
  */
202
201
  export interface InitiatedInstanceSearch {
203
- tenantId?: string;
204
202
  status?: InstanceStatus;
205
203
  keyword?: string;
206
204
  }
@@ -210,7 +208,6 @@ export interface InitiatedInstanceSearch {
210
208
  * filters AND together.
211
209
  */
212
210
  export interface MyTaskSearch {
213
- tenantId?: string;
214
211
  /**
215
212
  * Matches the instance title by substring.
216
213
  */
@@ -249,6 +246,5 @@ export interface CompletedTaskSearch extends MyTaskSearch {
249
246
  * Search parameters for `approval/my.find_cc_records`.
250
247
  */
251
248
  export interface MyCCRecordSearch {
252
- tenantId?: string;
253
249
  isRead?: boolean;
254
250
  }
@@ -5,10 +5,10 @@
5
5
  * takes its place within that tenant — and each instance of it runs in, and
6
6
  * belongs to, the tenant that started it.
7
7
  *
8
- * Only super-admins create and change shared definitions: pass it as the
9
- * `tenantId` of `ApprovalFlowPage` / `ApprovalCategoryPage` to manage them. A
10
- * shared flow sits under a shared category and routes no task or CC to
11
- * specific people, which the flow designer enforces once the flow's tenant is
12
- * this one.
8
+ * Shared definitions are managed like any other, gated by the flow and
9
+ * category permissions: pass it as the `tenantId` of `ApprovalFlowPage` /
10
+ * `ApprovalCategoryPage` to manage them. A shared flow sits under a shared
11
+ * category and routes no task or CC to specific people, which the flow
12
+ * designer enforces once the flow's tenant is this one.
13
13
  */
14
14
  export declare const SHARED_TENANT_ID = "0";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vef-framework-react/approval",
3
- "version": "2.26.0",
3
+ "version": "2.27.0",
4
4
  "private": false,
5
5
  "description": "Approval engine pages and runtime components for VEF framework",
6
6
  "keywords": [
@@ -44,12 +44,12 @@
44
44
  "@xyflow/react": "^12.11.1",
45
45
  "dayjs": "^1.11.0",
46
46
  "lucide-react": "^1.23.0",
47
- "@vef-framework-react/approval-flow-editor": "2.26.0",
48
- "@vef-framework-react/approval-form-bridge": "2.26.0",
49
- "@vef-framework-react/core": "2.26.0",
50
- "@vef-framework-react/components": "2.26.0",
51
- "@vef-framework-react/form-editor": "2.26.0",
52
- "@vef-framework-react/shared": "2.26.0"
47
+ "@vef-framework-react/approval-flow-editor": "2.27.0",
48
+ "@vef-framework-react/core": "2.27.0",
49
+ "@vef-framework-react/components": "2.27.0",
50
+ "@vef-framework-react/shared": "2.27.0",
51
+ "@vef-framework-react/form-editor": "2.27.0",
52
+ "@vef-framework-react/approval-form-bridge": "2.27.0"
53
53
  },
54
54
  "devDependencies": {
55
55
  "react": "^19.2.7"