diff --git a/.github/workflows/chromatic.yml b/.github/workflows/chromatic.yml new file mode 100644 index 000000000..d9a7cd6d6 --- /dev/null +++ b/.github/workflows/chromatic.yml @@ -0,0 +1,29 @@ +name: "Chromatic" + +on: push + +jobs: + chromatic: + name: Run Chromatic + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + with: + fetch-depth: 0 + - uses: actions/setup-node@v4 + with: + node-version: 20 + cache: "pnpm" + - name: Install dependencies + run: pnpm install + - name: Inject Doppler env vars + uses: dopplerhq/secrets-fetch-action@v1.2.0 + id: doppler + with: + doppler-token: ${{ secrets.DOPPLER_TOKEN }} + inject-env-vars: true + - name: Run Chromatic + uses: chromaui/action@latest + with: + projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }} diff --git a/apps/nextjs/.storybook/preview.tsx b/apps/nextjs/.storybook/preview.tsx index 72ce0b217..ff270b2e2 100644 --- a/apps/nextjs/.storybook/preview.tsx +++ b/apps/nextjs/.storybook/preview.tsx @@ -41,7 +41,7 @@ export const decorators: Decorator[] = [ RadixThemeDecorator, (Story) => ( <> - {/* TODO: use a mocked provider */} + {/* TODO: Mock tRPC calls with MSW */}