create-bestax 3.1.0 → 3.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/display.js +2 -2
- package/dist/index.js +0 -0
- package/package.json +4 -2
- package/templates/skills/bestax-custom-component/SKILL.md +10 -15
- package/templates/skills/bestax-form/SKILL.md +1 -1
- package/templates/vite/README.md +6 -6
- package/templates/vite-ts/README.md +6 -6
- package/dist/__mocks__/chalk.d.ts +0 -14
- package/dist/__mocks__/chalk.d.ts.map +0 -1
- package/dist/__mocks__/chalk.js +0 -13
- package/dist/__mocks__/figures.d.ts +0 -9
- package/dist/__mocks__/figures.d.ts.map +0 -1
- package/dist/__mocks__/figures.js +0 -7
- package/dist/__mocks__/prompts.d.ts +0 -3
- package/dist/__mocks__/prompts.d.ts.map +0 -1
- package/dist/__mocks__/prompts.js +0 -3
package/dist/display.js
CHANGED
|
@@ -15,8 +15,8 @@ export function displaySuccess(targetDir) {
|
|
|
15
15
|
console.log(chalk.bold(MESSAGES.NEXT_STEPS));
|
|
16
16
|
console.log();
|
|
17
17
|
console.log(chalk.cyan(` cd ${targetDir}`));
|
|
18
|
-
console.log(chalk.cyan('
|
|
19
|
-
console.log(chalk.cyan('
|
|
18
|
+
console.log(chalk.cyan(' pnpm install'));
|
|
19
|
+
console.log(chalk.cyan(' pnpm dev'));
|
|
20
20
|
console.log();
|
|
21
21
|
console.log(chalk.gray(' Your app includes a beautiful logo-centric homepage'));
|
|
22
22
|
console.log(chalk.gray(' showcasing Bestax, Vite, and React branding.'));
|
package/dist/index.js
CHANGED
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-bestax",
|
|
3
|
-
"version": "3.1.
|
|
3
|
+
"version": "3.1.1",
|
|
4
4
|
"description": "Create a new bestax-bulma project",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -59,6 +59,7 @@
|
|
|
59
59
|
"prompts": "^2.4.2"
|
|
60
60
|
},
|
|
61
61
|
"devDependencies": {
|
|
62
|
+
"@jest/globals": "^30.0.0",
|
|
62
63
|
"@playwright/test": "^1.57.0",
|
|
63
64
|
"@types/fs-extra": "^11.0.4",
|
|
64
65
|
"@types/jest": "^30.0.0",
|
|
@@ -71,6 +72,7 @@
|
|
|
71
72
|
"wait-on": "^9.0.10"
|
|
72
73
|
},
|
|
73
74
|
"publishConfig": {
|
|
74
|
-
"access": "public"
|
|
75
|
+
"access": "public",
|
|
76
|
+
"provenance": true
|
|
75
77
|
}
|
|
76
78
|
}
|
|
@@ -74,12 +74,7 @@ import { classNames, usePrefixedClassNames } from '../helpers/classNames';
|
|
|
74
74
|
import { useBulmaClasses, BulmaClassesProps } from '../helpers/useBulmaClasses';
|
|
75
75
|
|
|
76
76
|
export type MyComponentColor =
|
|
77
|
-
| '
|
|
78
|
-
| 'link'
|
|
79
|
-
| 'info'
|
|
80
|
-
| 'success'
|
|
81
|
-
| 'warning'
|
|
82
|
-
| 'danger';
|
|
77
|
+
'primary' | 'link' | 'info' | 'success' | 'warning' | 'danger';
|
|
83
78
|
|
|
84
79
|
/**
|
|
85
80
|
* Props for the MyComponent component.
|
|
@@ -144,8 +139,8 @@ Rules that keep components consistent:
|
|
|
144
139
|
`is-medium` / `is-large` (see `Tabs.tsx`, `Control.tsx`). Do **not** reach for the `validSizes`
|
|
145
140
|
constant — that one is `'0'…'6' | 'auto'` and exists for **spacing** helpers, not element size.
|
|
146
141
|
- **Format before you lint.** The repo enforces Prettier and ESLint fails on unformatted code.
|
|
147
|
-
Run `
|
|
148
|
-
`
|
|
142
|
+
Run `pnpm exec prettier --write` on your new files (or `pnpm format` from the repo root) before
|
|
143
|
+
`pnpm lint`. Copy snippets as a starting point, then let Prettier normalize them.
|
|
149
144
|
|
|
150
145
|
See `references/api.md` for the full helper API and `references/patterns.md` for the complete
|
|
151
146
|
Dialog walkthrough.
|
|
@@ -325,7 +320,7 @@ import { MyComponent } from '@allxsmith/bestax-bulma';
|
|
|
325
320
|
````
|
|
326
321
|
|
|
327
322
|
> Note: the Docusaurus docs load the **built** dist CSS. After SCSS changes, run
|
|
328
|
-
> `cd bulma-ui &&
|
|
323
|
+
> `cd bulma-ui && pnpm build` before the new styles show up in the docs site (Storybook
|
|
329
324
|
> compiles SCSS live and does not need this).
|
|
330
325
|
|
|
331
326
|
## Wiring & build
|
|
@@ -346,10 +341,10 @@ Then build and verify:
|
|
|
346
341
|
|
|
347
342
|
```sh
|
|
348
343
|
cd bulma-ui
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
344
|
+
pnpm exec prettier --write src/components/MyComponent.tsx src/scss/components/_mycomponent.scss
|
|
345
|
+
pnpm lint
|
|
346
|
+
pnpm test
|
|
347
|
+
pnpm build # compiles JS + the bestax/extras CSS bundles
|
|
353
348
|
```
|
|
354
349
|
|
|
355
350
|
## Visually inspect it in a browser
|
|
@@ -358,7 +353,7 @@ Types and unit tests don't see layout. **Render the component and actually look
|
|
|
358
353
|
you call it done — spacing, padding, vertical centering, alignment, and every variant/state
|
|
359
354
|
(colors, sizes, hover/active, dark mode). Visual bugs hide from `tsc` and `@testing-library`.
|
|
360
355
|
|
|
361
|
-
1. Run a surface that renders it: `
|
|
356
|
+
1. Run a surface that renders it: `pnpm storybook` (compiles SCSS live) or the docs dev server.
|
|
362
357
|
2. Open the component and inspect it. If a browser-automation tool (claude-in-chrome, Playwright)
|
|
363
358
|
is available, drive the browser and screenshot each variant; otherwise open it yourself and
|
|
364
359
|
eyeball it.
|
|
@@ -384,6 +379,6 @@ Fix what you see, then re-inspect. A green test suite with a misaligned componen
|
|
|
384
379
|
- [ ] `docs/docs/api/components/mycomponent.md` — Overview / Import / Props / `tsx live`.
|
|
385
380
|
- [ ] `src/index.ts` exports the component (in the `./components/*` group).
|
|
386
381
|
- [ ] `scss/components/_index.scss` `@use`s the partial.
|
|
387
|
-
- [ ] Prettier-formatted, then `
|
|
382
|
+
- [ ] Prettier-formatted, then `pnpm lint && pnpm test && pnpm build` all pass.
|
|
388
383
|
- [ ] **Rendered and visually inspected in a browser** — centering/spacing/variants all look
|
|
389
384
|
right (not just green tests).
|
|
@@ -191,7 +191,7 @@ reinvent a control.** If you think a control is missing, check `bulma-ui/src/ind
|
|
|
191
191
|
## Visually inspect it in a browser
|
|
192
192
|
|
|
193
193
|
Forms have layout, spacing, and _stateful_ behavior that types and unit tests don't cover.
|
|
194
|
-
Before calling a form done, **render it and look at it**: run `
|
|
194
|
+
Before calling a form done, **render it and look at it**: run `pnpm storybook` (in `bulma-ui`)
|
|
195
195
|
or the docs dev server, open the form, and check field alignment/spacing, the help-text/error
|
|
196
196
|
states, and the validation flow (submit empty → fields turn `danger` with messages; fix → errors
|
|
197
197
|
clear). If claude-in-chrome or Playwright is available, drive the browser and screenshot the
|
package/templates/vite/README.md
CHANGED
|
@@ -5,16 +5,16 @@ This template provides a minimal setup to get React working in Vite with HMR and
|
|
|
5
5
|
## Getting Started
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
pnpm install
|
|
9
|
+
pnpm dev
|
|
10
10
|
```
|
|
11
11
|
|
|
12
12
|
## Available Scripts
|
|
13
13
|
|
|
14
|
-
- `
|
|
15
|
-
- `
|
|
16
|
-
- `
|
|
17
|
-
- `
|
|
14
|
+
- `pnpm dev` - Start development server
|
|
15
|
+
- `pnpm build` - Build for production
|
|
16
|
+
- `pnpm preview` - Preview production build
|
|
17
|
+
- `pnpm lint` - Run ESLint
|
|
18
18
|
|
|
19
19
|
## Features
|
|
20
20
|
|
|
@@ -5,16 +5,16 @@ This template provides a minimal setup to get React working in Vite with TypeScr
|
|
|
5
5
|
## Getting Started
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
pnpm install
|
|
9
|
+
pnpm dev
|
|
10
10
|
```
|
|
11
11
|
|
|
12
12
|
## Available Scripts
|
|
13
13
|
|
|
14
|
-
- `
|
|
15
|
-
- `
|
|
16
|
-
- `
|
|
17
|
-
- `
|
|
14
|
+
- `pnpm dev` - Start development server
|
|
15
|
+
- `pnpm build` - Build for production
|
|
16
|
+
- `pnpm preview` - Preview production build
|
|
17
|
+
- `pnpm lint` - Run ESLint
|
|
18
18
|
|
|
19
19
|
## Features
|
|
20
20
|
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
declare const chalk: {
|
|
2
|
-
yellow: (str: string) => string;
|
|
3
|
-
blue: (str: string) => string;
|
|
4
|
-
cyan: (str: string) => string;
|
|
5
|
-
magenta: (str: string) => string;
|
|
6
|
-
green: (str: string) => string;
|
|
7
|
-
red: (str: string) => string;
|
|
8
|
-
dim: (str: string) => string;
|
|
9
|
-
bold: {
|
|
10
|
-
cyan: (str: string) => string;
|
|
11
|
-
};
|
|
12
|
-
};
|
|
13
|
-
export default chalk;
|
|
14
|
-
//# sourceMappingURL=chalk.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"chalk.d.ts","sourceRoot":"","sources":["../../src/__mocks__/chalk.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,KAAK;kBACK,MAAM;gBACR,MAAM;gBACN,MAAM;mBACH,MAAM;iBACR,MAAM;eACR,MAAM;eACN,MAAM;;oBAEH,MAAM;;CAErB,CAAC;AAEF,eAAe,KAAK,CAAC"}
|
package/dist/__mocks__/chalk.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"figures.d.ts","sourceRoot":"","sources":["../../src/__mocks__/figures.ts"],"names":[],"mappings":";;;;;;;AAAA,wBAME"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"prompts.d.ts","sourceRoot":"","sources":["../../src/__mocks__/prompts.ts"],"names":[],"mappings":"AAEA,QAAA,MAAM,OAAO,+DAAY,CAAC;AAE1B,eAAe,OAAO,CAAC"}
|