zimudec / wn-wizard-plugin
Multi-page wizard component for Winter CMS with server-side gating, per-step validation and a privacy-first session store
Package info
github.com/zimudec/wn-wizard-plugin
Type:winter-plugin
pkg:composer/zimudec/wn-wizard-plugin
Requires
- php: ^8.2
- composer/installers: ~1.0
- winter/wn-cms-module: ^1.2
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
README
A multi-page wizard component for Winter CMS: three levels of configuration, per-step validation, and a privacy-first session store. No build step, no jQuery, no Bootstrap — the framework serves the fingerprinted assets and the stylesheet sits in a CSS cascade layer your theme can override.
Requirements
- PHP 8.2 or higher
- Winter CMS 1.2 or higher
Installation
composer require zimudec/wn-wizard-plugin
A First Wizard
Add the component to a page whose URL declares an optional step parameter, then set the steps from the Inspector:
title = "Survey"
url = "/survey/:step?"
layout = "default"
==
{% component 'wizard' %}
With steps = "step-1|step-2|step-3" the wizard serves /survey/step-1 through
/survey/step-3, gates the steps the user has not reached, and advances on its own.
To declare the steps, their fields and their validation rules in code instead, call define()
from the page. The complete example is the
configuration quickstart.
Documentation
The full documentation is indexed in docs/documentation.md. Every page
has a Spanish version with the same name and the .es suffix.
- Installation
- Configuration
- Validation
- Navigation
- Session
- Programmatic Control
- Customization
- Privacy
- Accessibility
- Standards and References
- Upgrade Guide
Upgrading from 1.x
2.0 is a breaking release, and the 1.x branch stays frozen for critical fixes. The
configuration, the handlers, the session key and the partials all change — see the
upgrade guide with side-by-side examples.
Testing
php artisan winter:test -p zimudec.wizard
License
MIT — see LICENSE.