---
name: CI

on:
  pull_request:
  workflow_dispatch:

jobs:
  ci:
    name: CI
    runs-on: ubuntu-22.04
    steps:
      - name: Checkout Repository
        uses: actions/checkout@v4

      - name: Setup Node
        uses: actions/setup-node@v4
        with:
          node-version-file: ".node-version"

      - name: Install dependencies
        run: npm ci

      - name: Run Prettier
        run: npm run prettier:check

      - name: Run ESLint
        run: npm run lint

      - name: Run stylelint
        run: npm run stylelint

      - name: Test build
        run: npm run build
