diff --git a/.github/workflows/storybook.yml b/.github/workflows/storybook.yml index dcbc9d0088..009ffca7c0 100644 --- a/.github/workflows/storybook.yml +++ b/.github/workflows/storybook.yml @@ -50,12 +50,16 @@ jobs: - name: Install dependencies run: npm ci working-directory: ./frontend + - name: Build Storybook + run: ng run capellacollab:build-storybook + working-directory: ./frontend - name: Run Chromatic id: chromatic uses: chromaui/action@latest with: projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }} workingDir: ./frontend + storybookBuildDir: ./frontend/storybook-static - name: Create Storybook comment (initial) if: github.event_name == 'pull_request' uses: peter-evans/create-or-update-comment@v4 diff --git a/frontend/.gitignore b/frontend/.gitignore index bfa744f51e..29ccce3b64 100644 --- a/frontend/.gitignore +++ b/frontend/.gitignore @@ -60,6 +60,7 @@ Thumbs.db /playwright/.cache/ *storybook.log +storybook-static documentation.json .nx diff --git a/frontend/Makefile b/frontend/Makefile index 42daf9a0f1..d6f309fd2f 100644 --- a/frontend/Makefile +++ b/frontend/Makefile @@ -18,7 +18,10 @@ test: fi storybook: - ng run capellacollab:storybook --quiet + ng run capellacollab:storybook + +build-storybook: + ng run capellacollab:build-storybook openapi: python postprocess_openapi_schema.py diff --git a/frontend/angular.json b/frontend/angular.json index bfc13337a9..66d57b544d 100644 --- a/frontend/angular.json +++ b/frontend/angular.json @@ -144,6 +144,7 @@ "builder": "@storybook/angular:start-storybook", "options": { "configDir": ".storybook", + "quiet": true, "browserTarget": "capellacollab:build:development", "compodoc": true, "compodocArgs": ["-e", "json", "-d", "."], @@ -162,6 +163,8 @@ "builder": "@storybook/angular:build-storybook", "options": { "configDir": ".storybook", + "webpackStatsJson": true, + "browserTarget": "capellacollab:build:storybook", "compodoc": true, "compodocArgs": ["-e", "json", "-d", "."],