The module currently has a single README.md that covers basic usage but is outdated (still references D8/D9, contains stale TODOs) and doesn't document the architecture, API, hooks, or configuration in depth.

Add a MkDocs-based documentation site under docs/ with the following pages:

Proposed structure

  • index.md — Overview, features, requirements (Drupal 10.3+/11, Workflows, Webform)
  • installation.md — Composer install, enabling the module, creating a workflow with the "Webform workflow" type
  • usage.md — Adding the element to a webform, configuring states/transitions, access controls per transition, conditional logic to disable transitions, color configuration for states
  • email-handlers.md — Setting up the "Workflow transition email" handler, available tokens ([webform_workflow:transition-url:*], [webform_workflow:transition-link:*], secure token variants)
  • submission-filtering.md — Filtering results by workflow state (built-in list builder and webform_better_results integration)
  • api.mdWebformWorkflowsManager service methods, dispatched events (WebformSubmissionWorkflowTransitionEvent), alter hooks (hook_webform_workflow_element_access_alter, hook_webform_workflow_element_transition_access_alter)
  • architecture.md — OOP hook classes (EntityTypeHooks, FormHooks, ThemeHooks, TokenHooks, ResultsFilterHooks, WebformWorkflowsElementHooks), service wiring, #[Hook]/#[LegacyHook] pattern for Drupal 10.x/11.x compatibility
  • maestro-integration.md — Maestro module integration (if maestro is installed)
  • changelog.md — Migration notes for 2.1.0 (OOP migration, deprecated procedural functions)

Setup

  • Add mkdocs.yml at the module root
  • Use the Material for MkDocs theme
  • Migrate relevant content from README.md into the appropriate pages and modernize it (remove D7/D8/D9 references, update stale TODOs)
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

mably created an issue. See original summary.

mably’s picture

Status: Active » Needs review

  • mably committed eff4a8f6 on 2.x
    task: #3576293 Add MkDocs documentation site
    
    By: mably
    
mably’s picture

Status: Needs review » Fixed

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.