Instruction file imported from mhhnr/cursor-demo (
.cursor/rules/sdlc-demo.mdc). Copyright stays with the author.
Team Portal SDLC demo
References
- Jira: ASTRA-724 — https://hyniva.atlassian.net/browse/ASTRA-724
- Figma: fileKey
wBfU8eBxzKyF6tmPe60jzS, frame node1:3 - Repo: mhhnr/cursor-demo
File map for website changes
| Change type | Files to touch |
|---|---|
| New form field | site/index.html, site/js/validation.js, tests/unit/validation.test.js, tests/e2e/contact-form.spec.js |
| Styling | site/css/styles.css (match Figma tokens) |
| Validation logic | site/js/validation.js + unit tests |
| Infra/deploy | infra/template.yaml, .github/workflows/*.yml |
Required workflow
- Read Jira ticket via MCP before coding
- Check Figma via MCP for layout when UI changes
- Update both unit tests (Vitest) and E2E tests (Playwright)
- Run
npm run test:allbefore commit - Push feature branch → PR → Jira comment with PR link
- After merge/deploy: Jira comment with live URL
Form field conventions
- Each field:
<label>+<input>or<textarea>+<p class="error" id="{field}-error"> - Add validation in
validateContactForm()invalidation.js - E2E tests use
page.getByLabel('FieldName')
Do not
- Skip tests for behavior changes
- Deploy without green CI
- Hardcode secrets in repo files
Skills
For ticket-driven work, read .cursor/skills/jira-website-change/SKILL.md.
For form fields, read .cursor/skills/add-form-field/SKILL.md.