fix(mobile): critical mobile fixes — overflow, indentation, sticky he… #78
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: Deploy Site | |
| on: | |
| # Triggered when us-code data changes are pushed | |
| workflow_dispatch: | |
| push: | |
| branches: [main] | |
| paths: | |
| - 'apps/web/**' | |
| env: | |
| FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true | |
| permissions: | |
| contents: read | |
| pages: write | |
| id-token: write | |
| concurrency: | |
| group: pages | |
| cancel-in-progress: false | |
| jobs: | |
| build: | |
| runs-on: ${{ vars.RUNNER_LABEL || 'ubuntu-latest' }} | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| with: | |
| submodules: true | |
| - name: Fetch full submodule history (needed for diff generation) | |
| run: | | |
| cd apps/web/content-data | |
| git fetch --tags --force --unshallow 2>/dev/null || git fetch --tags --force | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@fc06bc1257f339d1d5d8b3a19a8cae5388b55320 # v5.0.0 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0 | |
| with: | |
| node-version: 22 | |
| cache: pnpm | |
| - name: Install dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Get submodule commit for cache key | |
| id: submodule-ref | |
| run: echo "sha=$(git -C apps/web/content-data rev-parse HEAD)" >> "$GITHUB_OUTPUT" | |
| - name: Restore diff cache | |
| uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0 | |
| with: | |
| path: apps/web/public/diffs/ | |
| key: diffs-${{ steps.submodule-ref.outputs.sha }} | |
| restore-keys: | | |
| diffs- | |
| - name: Generate static diffs (incremental) | |
| run: npx tsx scripts/generate-diffs.ts --repo apps/web/content-data --output apps/web/public/diffs/ | |
| - name: Build site | |
| run: pnpm --filter @civic-source/web build | |
| - name: Upload artifact | |
| uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b # v4.0.0 | |
| with: | |
| path: apps/web/dist | |
| deploy: | |
| needs: build | |
| runs-on: ubuntu-latest | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| steps: | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5.0.0 | |
| lighthouse: | |
| needs: deploy | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Lighthouse audit | |
| uses: treosh/lighthouse-ci-action@2f8dda6cf4de7d73b29853c3f29e73a01e297bd8 # v12.1.0 | |
| with: | |
| urls: | | |
| https://civic-source.github.io/us-code-tracker/ | |
| https://civic-source.github.io/us-code-tracker/browse/title-18/ | |
| budgetPath: '' | |
| temporaryPublicStorage: true | |
| - name: Report scores | |
| if: always() | |
| run: | | |
| echo "## Lighthouse Scores" >> "$GITHUB_STEP_SUMMARY" | |
| echo "Audit completed after deploy. Check artifacts for full report." >> "$GITHUB_STEP_SUMMARY" |