Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
eafa962
refactor: update button variants to primary
timosville Jul 28, 2026
20ff9f3
ops: add functon to find colours
timosville Jul 28, 2026
fab54fa
increment: enhance ActionCard component with new disabled variant and…
timosville Jul 28, 2026
f0b337d
wip
timosville Jul 28, 2026
940f4af
Merge branch 'main' into sco-2751-refine-studio-colours-brand
timosville Jul 28, 2026
b48f4a8
increment: add ActionGrid component for quick actions and update styl…
timosville Jul 28, 2026
813b312
refactor: remove unused action links from dashboard and clean up imports
timosville Jul 28, 2026
2bce672
style: update stat-tile component styles
timosville Jul 29, 2026
b2c4bde
refactor: simplify dashboard layout by consolidating StatTiles and Ac…
timosville Jul 29, 2026
fa4ee5a
increment: add IndexTabs component and integrate into dashboard layout
timosville Jul 29, 2026
6631d2f
style: update icon colors and text styles in dashboard index
timosville Jul 29, 2026
598fdc5
refactor: replace Icon component with ArrowUp and ArrowDown
timosville Jul 29, 2026
ecf5bda
wip
timosville Jul 29, 2026
d5766ab
refactor: update translation progress data and improve date handling …
timosville Jul 29, 2026
559e718
Merge branch 'main' into sco-2751-refine-studio-colours-brand
timosville Jul 29, 2026
84ce374
increment: add AppFooter with Kit version
timosville Jul 29, 2026
f20dff5
increment: enhance AppLayout and AppFooter to conditionally display b…
timosville Jul 29, 2026
b226dd3
refactor: remove RingBlock component and update Ring component usage …
timosville Jul 29, 2026
2d90c71
style: update button variant and tint color in invitation components
timosville Jul 29, 2026
eb33542
style: update button variants to primary and adjust tab button styles…
timosville Jul 29, 2026
2216fdf
increment: update streams
timosville Jul 30, 2026
a2208a4
refactor: remove ToggleButton component and its associated story
timosville Jul 30, 2026
ad5c98b
style: update ListSwitcher button styles and replace icon with Grid3X3
timosville Jul 30, 2026
3b723b9
style: update story gallery buttons
timosville Jul 30, 2026
bc306c2
increment: add ResourceVisibilityBadge component and update visibilit…
timosville Jul 30, 2026
349ada0
style: adjustments in rich-listbox
timosville Jul 30, 2026
4b79ee7
refactor: replace DropUp component with NavRailLanguageSelector and u…
timosville Jul 30, 2026
542edba
refactor: enhance ActionCard and ActionGrid components by adding labe…
timosville Jul 30, 2026
f56f41b
style: update visibility titles in resource stories to indicate absen…
timosville Jul 30, 2026
41fd208
ops: add changelog for QA refinement of studio colors and update butt…
timosville Aug 10, 2026
3d1d601
style: change button variant from secondary to primary
timosville Aug 10, 2026
1919880
ops: update changelog with new components and button variant fixes
timosville Aug 10, 2026
c37b715
Merge branch 'main' into sco-2751-refine-studio-colours-brand
timosville Aug 10, 2026
b1f2a9f
style: update text color in resource empty state component
timosville Aug 10, 2026
47d7e56
refactor: use gray colour
timosville Aug 12, 2026
d8c961b
style: update color scheme for language selector component
timosville Aug 12, 2026
a81e1af
increment: add NavRailLanguageIndicator component and integrate it in…
timosville Aug 12, 2026
413bc69
style: update color scheme for invitation and user row components, an…
timosville Aug 12, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
128 changes: 128 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,128 @@
# AGENTS.md — @story-cms/kit

Instructions for AI coding agents (Codex, Cursor, Claude Code, Copilot, etc.) working in this repository.

## Project overview

**Journeys Studio Kit** (`@story-cms/kit`) is a publishable npm package that provides:

- **Frontend**: Vue 3 + Inertia.js UI components, field widgets, and Pinia stores
- **Backend**: AdonisJS 6 services, models, middleware, and scaffolding stubs
- **Documentation**: [Histoire](https://histoire.dev/) component stories (not Storybook)

This repo is the **kit library**, not a full CMS app. Client apps (e.g. `@bnap/cms`) consume the built package. Local development uses Histoire (`npm run dev`) to preview and document components.

## Repository map

| Path | Purpose |
|------|---------|
| `src/frontend/` | Vue components, stores, styles |
| `src/backend/` | Adonis services, models, middleware, stubs |
| `src/types.ts` | Shared TypeScript types |
| `tests/unit/` | Playwright unit tests |
| `tests/e2e/` | Playwright end-to-end tests |
| `scripts/` | Build helpers (e.g. color usage generator) |
| `.cursor/rules/` | Detailed, file-scoped Cursor rules (see index below) |

Full directory tree: `.cursor/rules/project-structure.mdc`

## Commands

```bash
npm run dev # Histoire dev server (component docs)
npm run build # types + frontend (Vite) + backend (tsc)
npm run ui:build # Frontend only
npm run backend:build # Backend only
npm run lint # ESLint
npm run lint:fix # ESLint with auto-fix
npm run test # Playwright unit tests
npm run test:e2e # Playwright e2e tests
npm run colors:usage # Regenerate colors.palette.ts + colors.usage.ts
npm run story:build # Build Histoire static site
npm run story:preview # Preview built Histoire site
```

Run `npm run colors:usage` after changing theme tokens in `tailwind.config.js` or color-class usage in the frontend.

## Frontend conventions

- Vue 3 **Composition API** with `<script setup lang="ts">`
- Component files: **kebab-case** (e.g. `action-card.vue`)
- Co-locate Histoire stories: `component-name.story.vue` beside the component
- Histoire **`group`** must match the folder (`dashboard`, `shared`, `widgets`, `stories`, `pages`, etc.) — see `histoire.config.ts`
- State: Pinia stores in `src/frontend/store/`
- Icons: `@lucide/vue` for new UI; legacy `shared/icon.vue` for existing icon names
- Styling: Tailwind utilities; studio brand tokens in `tailwind.config.js` (`studio-yellow`, `studio-lime`, `studio-green`, `studio-forest`, `studio-dark`, etc.)
- Export public components from `src/frontend/index.ts` when adding package surface

Field widgets live under `src/frontend/fields/` and use `commonProps` from `shared/helpers.ts`.

## Generated files — do not edit manually

| File | Regenerate with |
|------|-----------------|
| `src/frontend/shared/colors.palette.ts` | `npm run colors:usage` |
| `src/frontend/shared/colors.usage.ts` | `npm run colors:usage` |

## Backend conventions

- AdonisJS 6 + Lucid ORM
- Services: `src/backend/services/`
- Models: `src/backend/models/`
- Stubs for consumer apps: `src/backend/stubs/`

See `.cursor/rules/adonis.mdc` for backend patterns.

## Testing

- **Unit**: `tests/unit/*.ts` — run with `npm run test`
- **E2e**: `tests/e2e/*.ts` — run with `npm run test:e2e`
- After changing field components or shared UI, run relevant tests before claiming work is complete
- Component behavior can also be checked in Histoire (`npm run dev`)

## Commits and pull requests

Use [Conventional Commits](https://www.conventionalcommits.org/) with **project-specific types**:

| Type | Use for |
|------|---------|
| `feat` | New feature |
| `fix` | Bug fix |
| `increment` | Functional improvement (not feat/fix) |
| `ops` | Build, CI, tooling (not `chore`) |
| `qa` | Tests, docs (not `test`/`docs`) |
| `refactor` | Maintainability, no behavior change |
| `revert` | Revert a prior commit |

**Do not** use `chore`, `docs`, `test`, `ci`, or `build` — map them to the types above.

Format: `type: subject` — imperative, lowercase after colon, no trailing period.

**Only create git commits when explicitly asked.** Do not commit secrets (`.env`, credentials).

Full guide: `.cursor/rules/commit-messages.mdc`

## Agent workflow

1. **Minimize scope** — smallest correct diff; do not refactor unrelated code
2. **Match existing patterns** — read surrounding files before writing
3. **New UI components** — add or update a co-located `.story.vue`; pick the correct Histoire `group`
4. **Verify before done** — run lint, tests, or Histoire as appropriate; do not claim success without evidence
5. **Do not edit plan files** (`.cursor/plans/`) unless asked
6. **Read scoped rules** — when editing paths covered by `.cursor/rules/`, follow those rules

## Detailed rules index (Cursor)

| Rule file | Topic | Applies when |
|-----------|-------|--------------|
| `application-stack.mdc` | Stack, dependencies, scripts | Always (alwaysApply) |
| `commit-messages.mdc` | Commit format and types | Always |
| `project-structure.mdc` | Directory layout | Exploring or adding files |
| `vue-components.mdc` | Vue 3 patterns | `src/frontend/**/*.vue` |
| `histoire-stories.mdc` | Story conventions | `src/frontend/**/*.story.vue` |
| `css-styling.mdc` | CSS / Tailwind layers | `src/frontend/**/*.css` |
| `adonis.mdc` | AdonisJS backend | `src/backend/*` |
| `cursor-rules.mdc` | How to add/edit rules | Maintaining rules |
| `self-improvement.mdc` | When to update rules | Rule maintenance |

Cursor loads `.cursor/rules/*.mdc` automatically; this file complements those rules for tools that read `AGENTS.md`.
3 changes: 3 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@AGENTS.md

Detailed file-scoped rules live in `.cursor/rules/` — read the relevant `.mdc` files when editing matching paths.
Loading
Loading