![]() Here's a breakdown of the changes: 1. **`AccountPage.vue`**: * I replaced the main heading with `VHeading`. * I updated the loading spinner to `VSpinner`. * I converted the error alert to `VAlert` with an action button. * I refactored the Profile, Password, and Notifications sections to use `VCard` for their structure. * The form elements within these cards (name, email, passwords) now use `VFormField` and `VInput`. * Action buttons like "Save Changes" and "Change Password" are now `VButton` with an integrated `VSpinner` for loading states. * The notification preferences list uses `VList` and `VListItem`, with each preference toggle converted to `VToggleSwitch`. 2. **`GroupDetailPage.vue`**: * I updated the page-level loading spinner, error alert, and main heading to `VSpinner`, `VAlert`, and `VHeading`. * I refactored the "Group Members", "Invite Members", "Chores", and "Expenses" sections from custom "neo-card" styling to use `VCard`. * Headers within these cards use `VHeading` and action buttons use `VButton` (I kept Material Icons where `VIcon` wasn't a direct replacement). * Lists of members, chores, and expenses now use `VList` and `VListItem`. * Buttons within list items (e.g., "Remove member") are `VButton` with `VSpinner`. * Role indicators and frequency/split type "chips" are now `VBadge` components, and I updated the helper functions to return VBadge-compatible variants. * The "Invite Members" form elements (input for code, copy button) use `VFormField`, `VInput`, and `VButton`. * I simplified empty states within card bodies using `VIcon` and text. 3. **`ListDetailPage.vue`**: This complex page required several steps to refactor: * **Page-Level & Header:** I updated the loading state to `VSpinner`, the error alert to `VAlert`, and the main title to `VHeading`. Header action buttons are `VButton` with icons, and the list status is `VBadge`. * **Modals:** I converted all five custom modals (OCR, Confirmation, Edit Item, Settle Share, Cost Summary shell) to use `VModal`. Internal forms and actions within these modals now use `VFormField`, `VInput`, `VButton`, `VSpinner`, `VList`, `VListItem`, and `VAlert` as appropriate. I removed the `onClickOutside` logic. * **Main Items List:** The loading state uses `VCard` with `VSpinner`, and the empty state uses `VCard variant="empty-state"`. The list itself is now a `VCard` containing a `VList`. Each item is a `VListItem` with internal content refactored to use `VCheckbox`, `VInput` (for price), and `VButton` with `VIcon` for actions. * **Add Item Form:** I re-structured this below the items list, using `VFormField`, `VInput`, and `VButton` with `VIcon`. * **Expenses Section:** The main card uses `VCard` with `VHeading` and `VButton` in the header. Loading/error/empty states use `VSpinner`, `VAlert`, `VIcon`. The expenses list is `VList`, with each expense item as a `VListItem`. Statuses are `VBadge`. This refactoring significantly increases the usage of the Valerie UI component library across these key application pages. This should help create a more consistent experience for you and make development smoother. Next, I'll focus on the Chores-related pages. |
||
---|---|---|
.. | ||
.storybook | ||
.vscode | ||
dev-dist | ||
e2e | ||
public | ||
src | ||
.editorconfig | ||
.env | ||
.gitattributes | ||
.gitignore | ||
.prettierrc.json | ||
Dockerfile | ||
Dockerfile.prod | ||
env.d.ts | ||
eslint.config.ts | ||
index.html | ||
package-lock.json | ||
package.json | ||
playwright.config.ts | ||
README.md | ||
tsconfig.app.json | ||
tsconfig.json | ||
tsconfig.node.json | ||
tsconfig.vitest.json | ||
vite.config.ts | ||
vitest.config.ts |
fe
This template should help get you started developing with Vue 3 in Vite.
Recommended IDE Setup
VSCode + Volar (and disable Vetur).
Type Support for .vue
Imports in TS
TypeScript cannot handle type information for .vue
imports by default, so we replace the tsc
CLI with vue-tsc
for type checking. In editors, we need Volar to make the TypeScript language service aware of .vue
types.
Customize configuration
See Vite Configuration Reference.
Project Setup
npm install
Compile and Hot-Reload for Development
npm run dev
Type-Check, Compile and Minify for Production
npm run build
Run Unit Tests with Vitest
npm run test:unit
Run End-to-End Tests with Playwright
# Install browsers for the first run
npx playwright install
# When testing on CI, must build the project first
npm run build
# Runs the end-to-end tests
npm run test:e2e
# Runs the tests only on Chromium
npm run test:e2e -- --project=chromium
# Runs the tests of a specific file
npm run test:e2e -- tests/example.spec.ts
# Runs the tests in debug mode
npm run test:e2e -- --debug
Lint with ESLint
npm run lint