fix(super-editor): keep the context menu within the editor viewport and scroll area #3535
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI Demos | |
| on: | |
| pull_request: | |
| paths: | |
| - '.github/workflows/ci-demos.yml' | |
| - 'package.json' | |
| - 'pnpm-lock.yaml' | |
| - 'pnpm-workspace.yaml' | |
| - '.nvmrc' | |
| - 'demos/**' | |
| - 'packages/superdoc/**' | |
| - 'packages/react/**' | |
| - 'packages/super-editor/**' | |
| - 'packages/layout-engine/**' | |
| - 'shared/**' | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: pnpm/action-setup@v4 | |
| with: | |
| package_json_file: package.json | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: '20' | |
| cache: 'pnpm' | |
| cache-dependency-path: pnpm-lock.yaml | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Build superdoc | |
| run: pnpm build:superdoc | |
| - name: Build @superdoc-dev/react | |
| # custom-ui imports the React wrapper from its dist/. | |
| # Other demos don't need this; cheap enough to run unconditionally. | |
| run: pnpm --filter @superdoc-dev/react run build | |
| - name: Pack build artifact | |
| run: tar -czf demos-build-dist.tgz packages/superdoc/dist packages/react/dist | |
| - name: Upload build artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: demos-build-dist-${{ github.run_id }} | |
| path: demos-build-dist.tgz | |
| if-no-files-found: error | |
| smoke-test: | |
| needs: build | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| demo: | |
| - contract-templates | |
| - custom-ui | |
| - docx-from-html | |
| - fields-source | |
| - grading-papers | |
| # - html-editor # broken: imports unpublished superdoc/super-editor/style.css subpath | |
| - linked-sections | |
| - nextjs-ssr | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: pnpm/action-setup@v4 | |
| with: | |
| package_json_file: package.json | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: '20' | |
| cache: 'pnpm' | |
| cache-dependency-path: pnpm-lock.yaml | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Download build artifact | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: demos-build-dist-${{ github.run_id }} | |
| path: . | |
| - name: Restore build artifact | |
| run: tar -xzf demos-build-dist.tgz | |
| - name: Resolve Playwright version | |
| id: playwright-version | |
| working-directory: demos/__tests__ | |
| run: echo "version=$(pnpm exec playwright --version | awk '{print $2}')" >> "$GITHUB_OUTPUT" | |
| - name: Restore Playwright Chromium cache | |
| id: playwright-cache | |
| uses: actions/cache@v5 | |
| with: | |
| path: ~/.cache/ms-playwright | |
| key: playwright-${{ runner.os }}-${{ steps.playwright-version.outputs.version }}-chromium | |
| - name: Install Playwright Chromium | |
| if: steps.playwright-cache.outputs.cache-hit != 'true' | |
| working-directory: demos/__tests__ | |
| run: pnpm exec playwright install --with-deps chromium | |
| - name: Install Playwright system dependencies | |
| if: steps.playwright-cache.outputs.cache-hit == 'true' | |
| working-directory: demos/__tests__ | |
| run: pnpm exec playwright install-deps chromium | |
| - name: Run smoke test | |
| working-directory: demos/__tests__ | |
| run: DEMO=${{ matrix.demo }} npx playwright test | |
| validate: | |
| name: CI Demos / validate | |
| if: always() | |
| needs: [smoke-test] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check results | |
| run: | | |
| if [[ "${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') || contains(needs.*.result, 'skipped') }}" == "true" ]]; then | |
| echo "One or more required jobs did not succeed." | |
| exit 1 | |
| fi |