Skip to content

Commit

Permalink
Merge pull request #241 from nickgros/PORTALS-2652
Browse files Browse the repository at this point in the history
  • Loading branch information
nickgros authored May 18, 2023
2 parents a716f41 + 5727e06 commit ad0f551
Show file tree
Hide file tree
Showing 6 changed files with 611 additions and 27 deletions.
18 changes: 0 additions & 18 deletions .github/workflows/build-docs.yml

This file was deleted.

29 changes: 29 additions & 0 deletions .github/workflows/deploy-to-chromatic.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: 'Deploy Storybook to Chromatic'

env:
NODE_OPTIONS: '--max-old-space-size=4096'

on:
push:
branches:
- main
pull_request_target:
branches:
- main

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3.1.0
with:
# Chromatic requires full git history to track changes
fetch-depth: 0
- uses: ./.github/actions/pnpm-setup-action
- name: Publish to Chromatic
uses: chromaui/action@v1
with:
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
workingDir: packages/synapse-react-client
exitZeroOnChanges: true
exitOnceUploaded: true
8 changes: 4 additions & 4 deletions .github/workflows/publish-docs.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: 'Publish Storybook'
name: 'Publish Storybook to GitHub Pages'

env:
NODE_OPTIONS: '--max-old-space-size=4096'
Expand All @@ -14,9 +14,9 @@ jobs:
steps:
- uses: actions/checkout@v3.1.0
- uses: ./.github/actions/pnpm-setup-action
- name: Build docs
run: pnpm nx run synapse-react-client:build:docs
- name: Deploy docs to GitHub Pages
- name: Build Storybook
run: pnpm nx run synapse-react-client:build:gh-pages
- name: Deploy to GitHub Pages
uses: JamesIves/github-pages-deploy-action@v4.4.1
with:
branch: gh-pages
Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,6 @@ jsconfig.json
apps/*/dist
packages/*/dist
storybook-static/
src/umd
src/umd

build-storybook.log
4 changes: 3 additions & 1 deletion packages/synapse-react-client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,7 @@
"babel-jest": "^29.4.3",
"babel-loader": "^8.2.5",
"buffer": "^6.0.3",
"chromatic": "^6.17.4",
"copyfiles": "^2.4.1",
"core-js": "^3.1.4",
"esbuild": "^0.17.11",
Expand Down Expand Up @@ -228,7 +229,8 @@
"build:esbuild": "rimraf dist/umd && node esbuild.config.mjs",
"serve:docs": "pnpm storybook",
"build:docs": "pnpm build:storybook",
"build:storybook": "storybook build && touch storybook-static/.nojekyll",
"build:build:gh-pages": "pnpm build-storybook && touch storybook-static/.nojekyll",
"build-storybook": "storybook build",
"link-src": "pnpm link && cd ./node_modules/react && pnpm link && cd ../react-router && pnpm link && cd ../react-router-dom && pnpm link && cd ../../",
"unlink-src": "pnpm unlink && cd ./node_modules/react && pnpm unlink && cd ../react-router && pnpm unlink && cd ../react-router-dom && pnpm unlink && cd ../../",
"storybook": "storybook dev -p 6060",
Expand Down
Loading

0 comments on commit ad0f551

Please sign in to comment.