task: #3608460 Harden Figma API errors, rewrite README, add docs site + Pages, drop dead config
What/Why
Hardens, tests, and documents the AI Figma 1.0.x scaffold from #3608437 so it is reviewable:
- Ran a 10-iteration Playwright test pass against a fresh Drupal CMS ~2.0 site requiring
drupal/ai_figma:1.0.x-dev, covering the settings page, status report, permissions, SSRF validation, a live Figma 403 response, AI tool execution, and anonymous access. - Hardened
FigmaContextClientHTTP error handling to return a concise, user-facing message (e.g.403 Invalid token) instead of a raw exception dump. - Rewrote
README.mdto match the actual, minimal module (removed aspirational/inaccurate claims). - Added a
docs/MkDocs site plus a GitLab CIpagesjob publishing to https://project.pages.drupalcode.org/ai_figma/. - Removed vestigial builder-only config (
layouts,component_choices,content_roles,builder_order,default_layout,component_prefix) fromai_figma.settings.ymland its schema. - Cleaned up code comments and the
.info.ymldescription. - Install now seeds the editable Figma AI Context items when
ai_contextis present.
Issue
https://www.drupal.org/project/ai_figma/issues/3608460
AI usage disclosure
AI-Generated: Yes (Used Claude Code to run the Playwright test pass, harden the Figma HTTP error handling, rewrite the README, add the docs/ MkDocs site + Pages CI job, remove the dead builder-only config, and seed AI Context items on install; reviewed by Rajab Natshah.) Per the Policy on the use of AI when contributing to Drupal.
Status
Ready for review. Do not merge — awaiting human review and maintainer sign-off.
Checkpoints
- File an issue about this project
- Addition/Change/Update/Fix to this project
- Testing to ensure no regression
- Automated unit/functional testing coverage
- Developer Documentation support on feature change/addition
- User Guide Documentation support on feature change/addition
- UX/UI designer responsibilities
- Accessibility and Readability
- Reviewed by a human
- Code review by maintainers
- Full testing and approval
- Credit contributors
- Review with the product owner
- Update Release Notes
- Release
Edited by Rajab Natshah