From 7e043734a85ffcc4b73e3a2733151b244edc0549 Mon Sep 17 00:00:00 2001 From: Adrian Llopart Date: Wed, 8 Jul 2026 09:47:47 +0200 Subject: [PATCH 1/2] Restore CodeQL workflow Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .github/workflows/codeql.yml | 32 +++++++++++++++++++++++++++ .github/workflows/promote-to-main.yml | 2 +- 2 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/codeql.yml diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml new file mode 100644 index 0000000..0b0ac6c --- /dev/null +++ b/.github/workflows/codeql.yml @@ -0,0 +1,32 @@ +name: CodeQL + +on: + push: + branches: [main, dev] + pull_request: + branches: [main, dev] + schedule: + - cron: "24 3 * * 1" + +permissions: + security-events: write + packages: read + actions: read + contents: read + +jobs: + analyze: + name: Analyze JavaScript + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v5 + + - name: Initialize CodeQL + uses: github/codeql-action/init@v4 + with: + languages: javascript-typescript + + - name: Perform CodeQL analysis + uses: github/codeql-action/analyze@v4 diff --git a/.github/workflows/promote-to-main.yml b/.github/workflows/promote-to-main.yml index 0335bc7..e049591 100644 --- a/.github/workflows/promote-to-main.yml +++ b/.github/workflows/promote-to-main.yml @@ -32,7 +32,7 @@ jobs: exit 1 - name: Checkout - uses: actions/checkout@v4 + uses: actions/checkout@v5 with: fetch-depth: 0 From 00717fef7647b362f6c56679d92132918d6278a7 Mon Sep 17 00:00:00 2001 From: Adrian Llopart <67589468+AdrianLlopart@users.noreply.github.com> Date: Wed, 8 Jul 2026 09:56:40 +0200 Subject: [PATCH 2/2] Add safe RSkills active fallback Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- src/components/RSkills.jsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/RSkills.jsx b/src/components/RSkills.jsx index d328f8c..f1ac014 100644 --- a/src/components/RSkills.jsx +++ b/src/components/RSkills.jsx @@ -125,6 +125,7 @@ function colorize(text) { } function colorVal(s) { const out = []; + // Match either a double-quoted string (group 1) or a number (integer/decimal, group 2). const re = /("[^"]*")|(\b\d+\.\d+\b|\b\d+\b)/g; let last = 0; let mm; @@ -148,7 +149,7 @@ export default function RSkills() { const [active, setActive] = useState(KINDS[0].kind); // Auto-cycle through the kinds every 3s until the user picks a tab. const [autoplay, setAutoplay] = useState(true); - const current = KINDS.find((k) => k.kind === active); + const current = KINDS.find((k) => k.kind === active) || KINDS[0]; useEffect(() => { if (!autoplay || reduce) return;