Skip to content

Add Workflow Transition Modal extension example#30

Merged
markus-moser merged 5 commits into
mainfrom
feat/workflow-modal-extension-example
Jun 1, 2026
Merged

Add Workflow Transition Modal extension example#30
markus-moser merged 5 commits into
mainfrom
feat/workflow-modal-extension-example

Conversation

@markus-moser
Copy link
Copy Markdown
Contributor

@markus-moser markus-moser commented Jun 1, 2026

Companion example for the Workflow Transition Modal extension points from pimcore/studio-ui-bundle#3647 (merged).

  • Frontend — adds a ReviewersField to the element.editor.workflow.modal.slots.center slot for the simple_approval / request_review transition.
  • Config — adds an example simple_approval workflow.
  • BackendWorkflowReviewersSubscriber appends the submitted reviewers to the workflow note.

Requires the canary SDK that includes #3647.

Companion example for the Workflow Transition Modal extension points
added in pimcore/studio-ui-bundle#3647.

Demonstrates injecting a custom 'Reviewers' field into the workflow
transition modal via the new center slot, and reading the submitted
values on the backend through a workflow.completed event subscriber
that enriches the workflow note.

- Frontend: WorkflowModalExtensionPlugin registers a ReviewersField
  component to element.editor.workflow.modal.slots.center, filtered to
  the simple_approval / request_review transition via useWorkflow.
- Config: example 'simple_approval' state_machine workflow.
- Backend: WorkflowReviewersSubscriber appends the requested reviewers
  to the workflow note on workflow.simple_approval.completed.request_review.
markus-moser and others added 4 commits June 1, 2026 09:50
- Bump @pimcore/studio-ui-bundle from the stale 1.0.0-canary.20260211
  pin to the 2026.1.4 stable release. This resolves the 4 pre-existing
  type errors on main (renamed DynamicTypeObjectLayout*/AbstractObjectLayout*
  symbols and the DynamicTypeGDPRProviderRegistry export) that have kept
  check-types red since April.
- Add temporary suppressions to the workflow-modal-extension example for
  the two symbols that only exist in pimcore/studio-ui-bundle#3647
  (the public useWorkflow export and the workflow.modal slot config),
  which is not yet in any published release. Each directive is marked
  with a TODO to remove it once #3647 ships and the SDK pin is bumped.

check-types, lint and build all pass locally against 2026.1.4.
studio-ui-bundle#3647 is now merged and published in
1.0.0-canary.20260601-121358-42aa95d, which exports the public
useWorkflow hook and the workflow.modal slot config the example uses.

- Pin @pimcore/studio-ui-bundle to that canary (exact, not a range:
  a >= range would resolve to stable 2026.1.4, which predates #3647).
- Remove the temporary @ts-expect-error / eslint-disable directives
  from the workflow-modal-extension example; it now type-checks and
  lints cleanly against the real SDK API.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant