WEB-2418: Restore padding in hero mobile layouts #112
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: Import design tokens | ||
|
Check failure on line 1 in .github/workflows/import-design-tokens.yml
|
||
| on: | ||
| workflow_dispatch: | ||
| inputs: | ||
| ref: | ||
| description: 'mistica-design repo changeset or branch' | ||
| required: false | ||
| default: 'production' | ||
| draft: | ||
| type: boolean | ||
| description: 'Create a draft PR' | ||
| required: false | ||
| default: false | ||
| branch: | ||
| description: 'Branch name for the PR. By default it is "import-design-tokens-${ref}"' | ||
| required: false | ||
| default: 'import-design-tokens-${{github.event.inputs.ref}}' | ||
| permissions: | ||
| contents: write | ||
| pull-requests: write | ||
| jobs: | ||
| import-design-tokens: | ||
| runs-on: ubuntu-latest | ||
| # Requires manual approval - uses GH_TOKEN_MISTICA to access private repo | ||
| environment: production | ||
| steps: | ||
| - uses: actions/checkout@v6 | ||
| with: | ||
| persist-credentials: false | ||
| - name: Validate ref input | ||
| id: validate | ||
| env: | ||
| REF_INPUT: ${{ github.event.inputs.ref }} | ||
| run: | | ||
| # Validate: only safe characters for git refs | ||
| if ! echo "$REF_INPUT" | grep -qE '^[a-zA-Z0-9._/-]+$'; then | ||
| echo "Error: Invalid ref format" | ||
| exit 1 | ||
| fi | ||
| echo "ref=$REF_INPUT" >> $GITHUB_OUTPUT | ||
| - name: Checkout mistica-design repo | ||
| uses: actions/checkout@v6 | ||
| with: | ||
| repository: Telefonica/mistica-design | ||
| path: '.github/mistica-design' | ||
| ref: ${{ steps.validate.outputs.ref }} | ||
| # Requires GH_TOKEN_MISTICA to access private Telefonica/mistica-design repo | ||
| token: ${{ secrets.GH_TOKEN_MISTICA }} | ||
| persist-credentials: false | ||
| - name: Install dependencies | ||
| env: | ||
| PUPPETEER_SKIP_CHROMIUM_DOWNLOAD: 'true' | ||
| run: yarn install --immutable --immutable-cache | ||
| - name: Generate skins from design tokens | ||
| run: cd packages/generate-design-tokens && yarn && node index.js | ||
| - name: Prettier | ||
| run: yarn prettier src/skins --write | ||
| - name: Create Pull Request | ||
| uses: peter-evans/create-pull-request@v5 | ||
| with: | ||
| token: ${{ secrets.GH_TOKEN_MISTICA }} | ||
| add-paths: 'src/skins' | ||
| commit-message: 'feat(skin): update design tokens' | ||
| title: 'feat(skin): update design tokens' | ||
| branch: ${{github.event.inputs.branch}} | ||
| reviewers: 'atabel,pladaria' | ||
| delete-branch: true | ||
| draft: ${{github.event.inputs.draft}} | ||