Skip to content

Commit

Permalink
add Chromatic to CI
Browse files Browse the repository at this point in the history
  • Loading branch information
yannbf committed May 6, 2024
1 parent fd903c2 commit 64fcd44
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 2 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/chromatic.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: "Chromatic"

on: push

jobs:
chromatic:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Install dependencies
run: pnpm install

- name: Run Chromatic
uses: chromaui/action@latest
with:
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
4 changes: 4 additions & 0 deletions chromatic.config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"projectId": "Project:66228a3205a9e64e345243d6",
"zip": true
}
4 changes: 2 additions & 2 deletions components/sidebar.stories.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Meta, StoryObj } from '@storybook/react'
import { notes } from '#prisma/mock-data';
import Sidebar from "./sidebar";
import { createNotes } from '#mocks/notes';

const meta = {
component: Sidebar,
Expand All @@ -11,7 +11,7 @@ export default meta;
type Story = StoryObj<typeof meta>
export const Default: Story = {
args: {
notes: notes,
notes: createNotes(),
children: null
}
}
Expand Down

0 comments on commit 64fcd44

Please sign in to comment.