Examples
FormEmbedModal (Google Forms example)
Provider-agnostic modal trigger pattern. The trigger is an anchor so no-JS fallback navigation still opens in a new tab.
Live example
Replace the example Google Forms URL with the live provider URL. The same component is used for JotForm and other providers.
Controlled mode example
Use controlled mode when page logic needs to open/close the form modal from non-anchor UI controls.
What to validate
- JS on: main CTA opens modal and the in-modal "Open in new tab" link works.
- Cmd/Ctrl/Shift/Alt click on trigger opens form directly in a new tab.
- JS off: trigger anchor opens the provider URL in a new tab (`target="_blank"` + `rel`).
- Controlled mode works when modal is opened from external page state.
- No duplicate fallback links in no-JS (helper link must be `js-only`, <noscript> remains).
- Page-level helper text uses the standard wording exactly.