Repository navigation
docs: new-component checklist, bounded CLAUDE.md deltas, /pre-pr command #269
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,58 @@ | ||||||||||||||||||||||||||
| # New component checklist | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| The definition of complete for adding a component to `@allxsmith/bestax-bulma` — for humans | ||||||||||||||||||||||||||
| and AI agents alike. `pnpm check:conformance` and CI enforce most of it; this file is the | ||||||||||||||||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
What: This checklist (and three other files in this PR) present Why it matters: These files are the machine-followable spec read by AI agents and CodeRabbit (root All five references to the phantom script
Fix: Either add the
Suggested change
|
||||||||||||||||||||||||||
| full sequence. Conventions live in the folder `CLAUDE.md`s; templates in | ||||||||||||||||||||||||||
| `skills/bestax-custom-component/references/library-contributor.md`. | ||||||||||||||||||||||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Broken reference: What: This points readers to Why it matters: An agent or contributor following this checklist chases a dead path and can't find the templates it promises. Fix:
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Broken template reference — What: This points readers to Why it matters: The first thing this checklist tells an agent/contributor to open for templates is a dead path. The worked-example templates actually live in Fix:
Suggested change
|
||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| ## 0. Classify first — everything below forks on this | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| | | Stock Bulma (in the Bulma v1 spec) | Extra / "Beyond Bulma" | | ||||||||||||||||||||||||||
| | ---------------- | -------------------------------------- | ----------------------------------------------------------------- | | ||||||||||||||||||||||||||
| | Prerequisite | — | Issue discussion first (component proposal) | | ||||||||||||||||||||||||||
| | SCSS | **None** — Bulma provides the CSS | Partial required (register-vars pattern) | | ||||||||||||||||||||||||||
| | Homepage listing | `docs/src/data/componentCategories.js` | `docs/src/components/EnhancedAddons/index.js` + SVG in `icons.js` | | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| Before building anything: scan `skills/bestax-custom-component/references/component-catalog.md` | ||||||||||||||||||||||||||
| for an existing component or synonym. If one fits, use or extend it. | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| ## 1. The artifacts | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| - [ ] `bulma-ui/src/<folder>/Foo.tsx` — helper props via `useBulmaClasses`, own classes via | ||||||||||||||||||||||||||
| `usePrefixedClassNames`, spread `rest` | ||||||||||||||||||||||||||
| - [ ] `bulma-ui/src/<folder>/__tests__/Foo.test.tsx` — 99% all metrics; must include a | ||||||||||||||||||||||||||
| `ConfigProvider classPrefix` test (pattern: `Reveal.test.tsx`) | ||||||||||||||||||||||||||
| - [ ] `bulma-ui/src/<folder>/Foo.stories.tsx` — import types from `@storybook/react-vite`; | ||||||||||||||||||||||||||
| `tags: ['autodocs']`; a `description` on every argType; no inline `style={{}}` | ||||||||||||||||||||||||||
| - [ ] _(extras only)_ `bulma-ui/src/scss/<folder>/_foo.scss` + `@use 'foo';` in that folder's | ||||||||||||||||||||||||||
| `_index.scss` — see `bulma-ui/src/scss/CLAUDE.md` | ||||||||||||||||||||||||||
| - [ ] `docs/docs/api/<folder>/foo.md` — mirror `docs/docs/api/components/avatar.md`; | ||||||||||||||||||||||||||
| frontmatter `title:` = the exact exported name (the catalog generator parses it) | ||||||||||||||||||||||||||
| - [ ] Export in `bulma-ui/src/index.ts`, then `pnpm gen:catalog` | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| ## 2. Listing surfaces (the step everyone misses) | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| - [ ] `### Foo` section on the category guide page (`docs/docs/guides/library/components.md` | ||||||||||||||||||||||||||
| or `form.md`) — one prose sentence + a `tsx live` example | ||||||||||||||||||||||||||
| - [ ] Homepage: **exactly one** surface per the table above — never both. Plural group | ||||||||||||||||||||||||||
| containers (`Avatars`) are not listed as cards; the guide page lists them. | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| ## 3. Skills sync (same PR, always) | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| - [ ] Themeable (SCSS partial or color/size props)? Add rows to | ||||||||||||||||||||||||||
| `skills/bestax-theming/references/themeable-components.md` and its new `--bulma-*` vars | ||||||||||||||||||||||||||
| to `css-variables.md` | ||||||||||||||||||||||||||
| - [ ] Changed shared helper props? Update `skills/bestax-custom-component/references/api.md` | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| ## 4. Gates | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| - [ ] `pnpm check:conformance` and `pnpm gen:catalog:check` | ||||||||||||||||||||||||||
| - [ ] `pnpm all` (build, typecheck, test+coverage, bundle:stats, lint, format, storybook build) | ||||||||||||||||||||||||||
| - [ ] Works on **React 18 and 19** — CI runs both majors; avoid single-major APIs | ||||||||||||||||||||||||||
| - [ ] Visually inspect every variant in Storybook, light and dark mode | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| ## 5. Before opening the PR | ||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||
| - [ ] Re-read your full diff against this checklist — each miss a reviewer catches costs a | ||||||||||||||||||||||||||
| review round | ||||||||||||||||||||||||||
| - [ ] Conventional commit with scope: `feat(bulma-ui): add Foo` | ||||||||||||||||||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pnpm check:conformancedoes not exist — 🟠 Major · CorrectnessWhat: This checklist and three CLAUDE.md files present
pnpm check:conformanceas a real, CI-enforced gate, but no such npm script, CI step, or implementing file exists in the repo.Why it matters: These files are read by humans and AI agents (Claude Action, CodeRabbit). An agent following the checklist runs
pnpm check:conformancein §4 →ERR_PNPM_NO_SCRIPT→ the "gate" hard-fails on a command that was never added. Worse, the docs assert CI enforces house conventions through it, so a reader believes conventions are checked when nothing checks them.Evidence
package.jsonscripts: onlygen:catalog/gen:catalog:check— nocheck:conformance.grep -rniI conformance(excluding node_modules/.git) matches only the docs being added/edited here — no script or workflow..github/workflows/ci.ymlsteps: gen:catalog:check, build, typecheck, test, test:coverage, bundle:stats, lint, format:check, audit, build-storybook, + React 18/19 matrix. No conformance step and no story/docs "existence" check.Referenced (all currently false):
CONTRIBUTING-COMPONENTS.md:4and:49CLAUDE.md("House conventions fail viapnpm check:conformance")bulma-ui/CLAUDE.md:31("CI'scheck:conformanceenforces")docs/CLAUDE.md:37("check:conformanceenforces the required sections")Fix: Either land the
check:conformancescript + CI step in this PR, or reword every reference to describe it as proposed/not-yet-implemented (and drop the "CI enforces" / "CI only checks that a story and docs page exist" claims until the check is real).