Skip to content

Fix VideoEffects Pane reseting focus when an item is selected #23416

Fix VideoEffects Pane reseting focus when an item is selected

Fix VideoEffects Pane reseting focus when an item is selected #23416

name: 'Publish Chromatic'
on:
pull_request:
paths:
- packages/storybook/**
- packages/react-components/**
- packages/react-composites/**
- packages/communication-react/**
push:
branches: [main]
workflow_dispatch:
# cancel workflow when a newer version of the workflow is triggered on the same github ref
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
chromatic_deployment:
name: Publish Chromatic
runs-on: ubuntu-latest
permissions:
packages: write
pull-requests: write
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Use Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20.x
- name: Restore node_modules from cache
uses: actions/cache@v3
with:
path: common/temp/pnpm-store
key: ${{ runner.os }}-${{ hashFiles('common/config/rush/pnpm-lock.yaml') }}
- name: Install Rush
run: npm install -g @microsoft/rush@$(jq -r '.rushVersion' "rush.json")
- name: Install Dependencies
run: rush install --max-install-attempts 3
- name: Publish Chromatic
id: publish_chromatic
uses: chromaui/action@v1
with:
workingDir: ./packages/storybook
buildScriptName: build:dev
token: ${{ secrets.GITHUB_TOKEN }}
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
allowConsoleErrors: true
- name: Format storybook URL
id: storybook_url
# Get the url from chromatic job then remove the iframe.html at the end of the url (this looks like a bug)
run: |
storybookurl=${{ steps.publish_chromatic.outputs.storybookUrl }}
echo "Storybook URL before: $storybookurl"
newurl=${storybookurl/%iframe.html}
echo "Storybook URL after: $newurl"
echo "url=$newurl" >> $GITHUB_OUTPUT
- name: Add Storybook URL as Issue Comment
if: github.event_name == 'pull_request'
uses: actions/github-script@v3
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
github.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: 'Storybook URL ${{ steps.storybook_url.outputs.url }}'
})