create-bestax 3.4.0 → 3.5.0
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/constants.d.ts +2 -1
- package/dist/constants.d.ts.map +1 -1
- package/dist/constants.js +23 -1
- package/dist/project-creator.d.ts.map +1 -1
- package/dist/project-creator.js +2 -1
- package/package.json +1 -1
- package/templates/skills/bestax-custom-component/references/component-catalog.md +2 -2
- package/templates/skills/bestax-layout-scaffold/references/layout-components.md +3 -2
package/dist/constants.d.ts
CHANGED
|
@@ -22,8 +22,9 @@ export declare const MESSAGES: {
|
|
|
22
22
|
readonly PROJECT_CREATED: "✔ Done! Project created successfully.";
|
|
23
23
|
readonly NEXT_STEPS: "Next steps:";
|
|
24
24
|
readonly HAPPY_CODING: "Happy coding! 🎉";
|
|
25
|
-
readonly SKILLS_ADDED: "✔ Installed bestax AI skills into .claude/skills/ (+ CLAUDE.md)";
|
|
25
|
+
readonly SKILLS_ADDED: "✔ Installed bestax AI skills into .claude/skills/ (+ CLAUDE.md, .claude/launch.json)";
|
|
26
26
|
};
|
|
27
|
+
export declare const LAUNCH_JSON: string;
|
|
27
28
|
export declare const PROMPTS: {
|
|
28
29
|
readonly PROJECT_NAME: "Project name:";
|
|
29
30
|
readonly SELECT_FRAMEWORK: "Select a framework:";
|
package/dist/constants.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,OAAO,KAAK,CAAC,MAAM,CAAC;CAC5B;AAED,eAAO,MAAM,SAAS,EAAE,QAAQ,EAG/B,CAAC;AAEF,eAAO,MAAM,oBAAoB,kBAAkB,CAAC;AACpD,eAAO,MAAM,u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AS,GACpB,aAAa,MAAM,EACnB,8BAA8B,eAAe,KAC5C,MAoEF,CAAC;AAEF,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,OAAO,KAAK,CAAC,MAAM,CAAC;IAC3B,WAAW,CAAC,EAAE,MAAM,CAAC;IAIrB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B;AAED,eAAO,MAAM,cAAc,EAAE,WAAW,EA6CvC,CAAC;AAEF,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,EAAE,OAAO,KAAK,CAAC,MAAM,CAAC;IAC3B,eAAe,EAAE,MAAM,CAAC;IACxB,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAED,eAAO,MAAM,aAAa,EAAE,WAAW,EA4CtC,CAAC"}
|
package/dist/constants.js
CHANGED
|
@@ -23,8 +23,26 @@ export const MESSAGES = {
|
|
|
23
23
|
PROJECT_CREATED: '✔ Done! Project created successfully.',
|
|
24
24
|
NEXT_STEPS: 'Next steps:',
|
|
25
25
|
HAPPY_CODING: 'Happy coding! 🎉',
|
|
26
|
-
SKILLS_ADDED: '✔ Installed bestax AI skills into .claude/skills/ (+ CLAUDE.md)',
|
|
26
|
+
SKILLS_ADDED: '✔ Installed bestax AI skills into .claude/skills/ (+ CLAUDE.md, .claude/launch.json)',
|
|
27
27
|
};
|
|
28
|
+
// Dev-server manifest written into .claude/ with the skills opt-in so Claude
|
|
29
|
+
// Code's browser preview (`preview_start`) can boot the app by name instead of
|
|
30
|
+
// rediscovering the dev command from package.json. `npm` is deliberately
|
|
31
|
+
// package-manager-neutral (`npm run dev` works whichever PM installed the
|
|
32
|
+
// project), and `--strictPort` stops Vite from silently auto-incrementing to
|
|
33
|
+
// 5174 when 5173 is busy — a mismatch with the declared `port` must fail
|
|
34
|
+
// loudly, not point the preview at nothing.
|
|
35
|
+
export const LAUNCH_JSON = JSON.stringify({
|
|
36
|
+
version: '0.0.1',
|
|
37
|
+
configurations: [
|
|
38
|
+
{
|
|
39
|
+
name: 'dev',
|
|
40
|
+
runtimeExecutable: 'npm',
|
|
41
|
+
runtimeArgs: ['run', 'dev', '--', '--strictPort'],
|
|
42
|
+
port: 5173,
|
|
43
|
+
},
|
|
44
|
+
],
|
|
45
|
+
}, null, 2) + '\n';
|
|
28
46
|
export const PROMPTS = {
|
|
29
47
|
PROJECT_NAME: 'Project name:',
|
|
30
48
|
SELECT_FRAMEWORK: 'Select a framework:',
|
|
@@ -97,6 +115,10 @@ automatically when the task matches:
|
|
|
97
115
|
|
|
98
116
|
Prefer the library's components and these skills over hand-written Bulma markup or custom CSS.
|
|
99
117
|
|
|
118
|
+
\`.claude/launch.json\` declares this app's dev server for Claude Code's browser preview
|
|
119
|
+
(\`npm run dev\` on port 5173, \`--strictPort\`) — start it from there rather than rediscovering
|
|
120
|
+
the command.
|
|
121
|
+
|
|
100
122
|
## Docs
|
|
101
123
|
|
|
102
124
|
- Docs site: https://bestax.io
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"project-creator.d.ts","sourceRoot":"","sources":["../src/project-creator.ts"],"names":[],"mappings":"AA2BA,OAAO,
|
|
1
|
+
{"version":3,"file":"project-creator.d.ts","sourceRoot":"","sources":["../src/project-creator.ts"],"names":[],"mappings":"AA2BA,OAAO,EAOL,KAAK,eAAe,EACrB,MAAM,gBAAgB,CAAC;AAIxB,MAAM,WAAW,aAAa;IAC5B,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAA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AAU,GAAG,OAAO,CAAC,IAAI,CAAC;CAwIvE"}
|
package/dist/project-creator.js
CHANGED
|
@@ -6,7 +6,7 @@ import { checkDirectoryExists, isDirectoryEmpty, emptyDirectory, ensureDirectory
|
|
|
6
6
|
import { promptProjectName, promptOverwriteDirectory, promptTemplate, promptIconLibrary, promptBulmaFlavor, promptInstallSkills, } from './prompts.js';
|
|
7
7
|
import { displayHeader, displaySuccess, displayError, displayCancelled, } from './display.js';
|
|
8
8
|
import { validateProjectName } from './validators.js';
|
|
9
|
-
import { MESSAGES, ICON_LIBRARIES, BULMA_FLAVORS, CLAUDE_MD, CONFIG_PROVIDER_ICON_VALUES, } from './constants.js';
|
|
9
|
+
import { MESSAGES, ICON_LIBRARIES, BULMA_FLAVORS, CLAUDE_MD, LAUNCH_JSON, CONFIG_PROVIDER_ICON_VALUES, } from './constants.js';
|
|
10
10
|
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
11
11
|
export class ProjectCreator {
|
|
12
12
|
templatesDir;
|
|
@@ -52,6 +52,7 @@ export class ProjectCreator {
|
|
|
52
52
|
return;
|
|
53
53
|
}
|
|
54
54
|
await fs.copy(skillsSrc, path.join(targetPath, '.claude', 'skills'));
|
|
55
|
+
await fs.writeFile(path.join(targetPath, '.claude', 'launch.json'), LAUNCH_JSON);
|
|
55
56
|
await fs.writeFile(path.join(targetPath, 'CLAUDE.md'), CLAUDE_MD(projectName, options));
|
|
56
57
|
console.log(chalk.green(MESSAGES.SKILLS_ADDED));
|
|
57
58
|
}
|
package/package.json
CHANGED
|
@@ -14,8 +14,8 @@ instead of hand-writing markup.
|
|
|
14
14
|
(`m`/`p` spacing, `textColor`/`bgColor`, `textAlign`, `display`, flex, …) —
|
|
15
15
|
documented once in `references/api.md`.
|
|
16
16
|
- **Compound components** expose sub-parts via dot access (e.g. `Card.Header`,
|
|
17
|
-
`Navbar.Item`, `Tabs.Tab`, `Hero.Body`); see the
|
|
18
|
-
full set.
|
|
17
|
+
`Navbar.Item`, `Tabs.Tab`, `Hero.Body`, `Columns.Column`, `Table.Tr`); see the
|
|
18
|
+
component's linked page for the full set.
|
|
19
19
|
- Raw `*Base` form exports (`InputBase`, `SelectBase`, `TextAreaBase`, …) are
|
|
20
20
|
escape-hatch variants of the convenience wrappers above them; see the Form docs.
|
|
21
21
|
|
|
@@ -91,7 +91,8 @@ Every component also accepts the shared Bulma helper props (`m`/`p` spacing, `te
|
|
|
91
91
|
|
|
92
92
|
## Columns / Column
|
|
93
93
|
|
|
94
|
-
The responsive grid. `Columns` is the row; `Column` is a cell
|
|
94
|
+
The responsive grid. `Columns` is the row; `Column` is a cell (also reachable as
|
|
95
|
+
`Columns.Column`).
|
|
95
96
|
|
|
96
97
|
**Columns**
|
|
97
98
|
|
|
@@ -156,7 +157,7 @@ the column's auto height). Make the `Column` a flex container and let the card g
|
|
|
156
157
|
|
|
157
158
|
## Grid / Cell
|
|
158
159
|
|
|
159
|
-
Bulma's CSS Grid. **Preferred for uniform grids** — same-shaped items in a repeating pattern
|
|
160
|
+
Bulma's CSS Grid (`Cell` is also reachable as `Grid.Cell`). **Preferred for uniform grids** — same-shaped items in a repeating pattern
|
|
160
161
|
(card grids, galleries, dashboards): CSS Grid gives **equal-height cells for free** (per row —
|
|
161
162
|
each row's cells match its tallest), with no flex recipe needed. Reach for `Columns`/`Column` instead when you need proportional or
|
|
162
163
|
per-breakpoint column _sizes_ (a 2/3 + 1/3 split, different counts per breakpoint).
|