From c62ad4bc68cf5573598f06b5491b67f53cb3c858 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 30 Nov 2026 01:48:41 +0000 Subject: [PATCH 1/2] chore(deps): update lint & format --- package.json | 8 +- pnpm-lock.yaml | 245 +++++++++++++++++++++++++------------------------ 2 files changed, 131 insertions(+), 122 deletions(-) diff --git a/package.json b/package.json index 0591e78f..a62da9d2 100644 --- a/package.json +++ b/package.json @@ -69,9 +69,9 @@ "@stylistic/eslint-plugin": "^5.10.0", "@types/node": "^24.10.1", "@vitest/coverage-v8": "4.1.11", - "eslint-plugin-unused-imports": "^4.3.0", + "eslint-plugin-unused-imports": "^4.4.1", "kiira": "0.7.1", - "knip": "^6.26.0", + "knip": "^6.49.0", "markdown-link-extractor": "^4.0.3", "nx": "23.1.1", "oxfmt": "^0.75.0", @@ -79,8 +79,8 @@ "oxlint-plugin-eslint": "^1.90.0", "oxlint-tsgolint": "^0.25.0", "premove": "^4.0.0", - "publint": "^0.3.15", - "sherif": "^1.9.0", + "publint": "^0.3.25", + "sherif": "^1.13.0", "tinyglobby": "^0.2.17", "ts-morph": "^28.0.0", "tsdown": "^0.23.4", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 87da7810..1ad8880c 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -24,14 +24,14 @@ importers: specifier: 4.1.11 version: 4.1.11(vitest@4.1.11) eslint-plugin-unused-imports: - specifier: ^4.3.0 + specifier: ^4.4.1 version: 4.4.1(eslint@10.12.0(jiti@2.7.0)(supports-color@7.2.0)) kiira: specifier: 0.7.1 version: 0.7.1 knip: - specifier: ^6.26.0 - version: 6.39.0 + specifier: ^6.49.0 + version: 6.49.0(@clack/prompts@1.8.1) markdown-link-extractor: specifier: ^4.0.3 version: 4.0.4 @@ -54,10 +54,10 @@ importers: specifier: ^4.0.0 version: 4.0.0 publint: - specifier: ^0.3.15 + specifier: ^0.3.25 version: 0.3.25 sherif: - specifier: ^1.9.0 + specifier: ^1.13.0 version: 1.13.0 tinyglobby: specifier: ^0.2.17 @@ -4070,137 +4070,137 @@ packages: '@oslojs/encoding@1.1.0': resolution: {integrity: sha512-70wQhgYmndg4GCPxPPxPGevRKqTIJ2Nh4OkiMWmDAVYsTQ+Ta7Sq+rPevXyXGdzr30/qZBnyOalCszoMxlyldQ==} - '@oxc-parser/binding-android-arm-eabi@0.150.0': - resolution: {integrity: sha512-oQef2Zu4Prz1KLKznz3HqZzU9uVoA5PMoDZuuLmqms7hKmKSAPzlaMnLllJq3t+rgKmfJJ2siPrpZfFrW06btw==} + '@oxc-parser/binding-android-arm-eabi@0.160.0': + resolution: {integrity: sha512-IGhHufQ5uRhivrpzCcUJ92Mj4kYyFVhghaWk9hgZP/b+7WxdzdhFqBbH+PwEcfssDdIW10YHXcFvWib3kMX4Zg==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [arm] os: [android] - '@oxc-parser/binding-android-arm64@0.150.0': - resolution: {integrity: sha512-B6ofpoFiAUwIZ0MJ2IgHPvZK8FAtL4qzSZRwOkAKIfxEobE1mQC8nDdiFZj7pUaJiVUVCsfkMsBJKedzO8rZvA==} + '@oxc-parser/binding-android-arm64@0.160.0': + resolution: {integrity: sha512-VxqVDFdTJG/QrJJ5pc/JIocKExtxCGcKf9qBsjIMS2VymVnHNdDu58d35pkgxIMFhxJ92YD79+66SBv86GXfCw==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [arm64] os: [android] - '@oxc-parser/binding-darwin-arm64@0.150.0': - resolution: {integrity: sha512-J+9IHKzx/bSz1JetOfD4zKXSK9sOm4/a7+0qomJODcTL6JsRXGeV/ZdkAPSIDydfFmWzYCraMlQEosSZEyBYkQ==} + '@oxc-parser/binding-darwin-arm64@0.160.0': + resolution: {integrity: sha512-W5ULJkX2YAZAi6h2gkWCZCq1Ws5ZTIejBXjQP3tdf/UOeJaNQes4Vo5659/szYrFoBTef+WWcOU4HaY3TT4OYQ==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [arm64] os: [darwin] - '@oxc-parser/binding-darwin-x64@0.150.0': - resolution: {integrity: sha512-v6IPfcAcSYrBWXV5Tce1DmxDMXLhEYpIIWiRFPJopgCVscZdLaV4MRQOUxvL3usQlw+yrwYOjBFB9IwBx+jUiQ==} + '@oxc-parser/binding-darwin-x64@0.160.0': + resolution: {integrity: sha512-NNV6qakT/DX8SLqpe/gJ2ab2yDVJ+y6DKdJrbyTAdkpMjTP1KljiUxtAwoKVlHVPqfGMFPpSHIU9yL3FAWG/3w==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [x64] os: [darwin] - '@oxc-parser/binding-freebsd-x64@0.150.0': - resolution: {integrity: sha512-AoR/4jD02HET0KO0yNT4nbTE+XJUxiO9jB1X/ycEjUE3WrIJ3IjV/Vf+gskhWLcqqeXfvNnkDtBR7epllAm88A==} + '@oxc-parser/binding-freebsd-x64@0.160.0': + resolution: {integrity: sha512-P1Ay7bTnFJarHefoBOOrzZ8ynRluk0w92p/+PwkAYgg38Fh5Z2eQN2slzYqODyNQRDd2YrdecLV038V6KmqfXw==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [x64] os: [freebsd] - '@oxc-parser/binding-linux-arm-gnueabihf@0.150.0': - resolution: {integrity: sha512-A/hycCFjLUrCmLoL5O/vBp40ohlaXO1Ta3v5hqYZxicYFs129wZmgZJggcW4mYGYbZebQLhup+N8JjeQl8qwyw==} + '@oxc-parser/binding-linux-arm-gnueabihf@0.160.0': + resolution: {integrity: sha512-jw16rzFMeyaGRTVoHTiKAe5qHa6T5v54GX0TGoAvbEskN+hQcK0pZQ+pi5n3yGZ7b1+vTF2eBuqQP98mgcd6XA==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [arm] os: [linux] - '@oxc-parser/binding-linux-arm-musleabihf@0.150.0': - resolution: {integrity: sha512-pbqahg1Pkz7J4RKmXm30s/iQu99hv64ayXCu8P4p75HcEH5azOdR4eGqiB6lFGkFR3mMpzaYsSKLkS8oJbjmeQ==} + '@oxc-parser/binding-linux-arm-musleabihf@0.160.0': + resolution: {integrity: sha512-B55bnJn8XMC8NDBbEsL6Za2ZuFx6RIG49GMSlHYfpIc2pWQ6sbJRwarP+iKXnPgpJ1N7wfOAotMp58NUYjzQaQ==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [arm] os: [linux] - '@oxc-parser/binding-linux-arm64-gnu@0.150.0': - resolution: {integrity: sha512-HV11aRbBQGwqv8bEo+K/6qr88uB4fEe1mhXncMhlVCrj+WpBSraxrUzHaPVmeQRU6x6x8v/3DuCbbo93rpp+fw==} + '@oxc-parser/binding-linux-arm64-gnu@0.160.0': + resolution: {integrity: sha512-YKVHxONDpWXTPfilLv2MKvaI7VbYnKHARr5wJ3KKKGk0OkauDc0tVFyZlKFwIy9+br46fh8AjTVCnz6+9gKxVA==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [arm64] os: [linux] libc: [glibc] - '@oxc-parser/binding-linux-arm64-musl@0.150.0': - resolution: {integrity: sha512-k6pVkJqALwtEuP4zukVhGRhdIy4+ofChUIUUsAHHyqDZlNsknmel3JjbggrJiWGaes6h/dIcWmEXsKW4SmK9oQ==} + '@oxc-parser/binding-linux-arm64-musl@0.160.0': + resolution: {integrity: sha512-uiVA0AemCVB3+oZ3JmjQCSEqiGIgl+o3+bLqORIfviJbyYlVUChoRh6cVbyyDG6zm4fW0RtQIdKq3fVYuNTA3Q==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [arm64] os: [linux] libc: [musl] - '@oxc-parser/binding-linux-ppc64-gnu@0.150.0': - resolution: {integrity: sha512-tEFg39mw/rHO5n8GK2DR4ZMFfsPQZtnQIPbsIpjoQRomJc/2tRfsCSmCT6gNit+NZGoeJG5aH9ATDH5bf0WnoQ==} + '@oxc-parser/binding-linux-ppc64-gnu@0.160.0': + resolution: {integrity: sha512-h/tr4lWGdRXs4rUktl84Z0CprQhdDlxN4D82/cCcoKr0Kb4TEIJriXZVqHPznp12/uBWcV+BiihUBPbeyZm1KQ==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [ppc64] os: [linux] libc: [glibc] - '@oxc-parser/binding-linux-riscv64-gnu@0.150.0': - resolution: {integrity: sha512-0JO7IFkoek6HqV589Menx3hJySNXi6quRhO4tq2P7kpEHKEXoDATnoPVUpn5B7gDH2KLkdo751N0uIrGJFCTCw==} + '@oxc-parser/binding-linux-riscv64-gnu@0.160.0': + resolution: {integrity: sha512-bA/Ba24KZYxorIUBHF2NbXM0OVY24xowGu4L0YBzpXhivt+ks1z8BT/c+BYGSfdFFqWrfNkC5TJjQGWdRkUHWQ==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [riscv64] os: [linux] libc: [glibc] - '@oxc-parser/binding-linux-riscv64-musl@0.150.0': - resolution: {integrity: sha512-7XPzREnyAS5wHU9aB+49Uaqgoo1gVCklHc3DRlc3fJy2tXD/eAJFN1QFz/crj+Ulup5P1+axNREF+/RGaB/IRA==} + '@oxc-parser/binding-linux-riscv64-musl@0.160.0': + resolution: {integrity: sha512-1uI9RghjO7/JQzkL9M/EDnG0Egy5z4v3k5TCUbPESZVUawHEmC52MMnCLe7f2CjMtiLjsm879CnO2HkRtsECNA==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [riscv64] os: [linux] libc: [musl] - '@oxc-parser/binding-linux-s390x-gnu@0.150.0': - resolution: {integrity: sha512-7n7ZxcbRWDFaTdyj8M8p0O9OfzoMKm8O6syBAIgcSutbOALq0Bb9G52Me+XH0anMLZV+NgXc726gqgG2q39vcQ==} + '@oxc-parser/binding-linux-s390x-gnu@0.160.0': + resolution: {integrity: sha512-1gaVKLXjT+UML8w8ypK93KUJurvUUmegqgQ/7qijDNpGCuogmTOIu0KgsYqL2hH//amY3AtfQhTTMlw9l363wA==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [s390x] os: [linux] libc: [glibc] - '@oxc-parser/binding-linux-x64-gnu@0.150.0': - resolution: {integrity: sha512-Vx0GSA9ZCRTUiczoEQnIIyXkMvtEY8uc6IiwLQtMe5ci2sXPqjrry0Ek5fsPP1k2kCzkML3ow9UOOEgnEDi7Bw==} + '@oxc-parser/binding-linux-x64-gnu@0.160.0': + resolution: {integrity: sha512-v44/JCrzpIof2jAJwF9W1j9l7mZKEaKihd8vBECBaNyIPcOiO4dtkeGX51MxnGmrJbsltdvTJb60VXLyMyAD2w==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [x64] os: [linux] libc: [glibc] - '@oxc-parser/binding-linux-x64-musl@0.150.0': - resolution: {integrity: sha512-ii4/9m3viDLssMnfXU7/Pni/3nYplApuGayceX4qsVGaqqQJCx3tHIH9M/HWIeSty5i8LjS21zPYT6lVIkwLxw==} + '@oxc-parser/binding-linux-x64-musl@0.160.0': + resolution: {integrity: sha512-NOT9x+x27Aitn+z6PggidaeHiKOpbglRXwzcHg+3VqbMT7nv/C3fnXKeVESy4o0u3Yb3mEocwPrtzlT5O53JSA==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [x64] os: [linux] libc: [musl] - '@oxc-parser/binding-openharmony-arm64@0.150.0': - resolution: {integrity: sha512-ZtoxX5rez36ZWkwtiEhjkCPnlTPoQ2I7lIL0IYZ1yjxMYohbvoOjBmUIZzrf9W/HouONq0omIfTeCWEY+R380w==} + '@oxc-parser/binding-openharmony-arm64@0.160.0': + resolution: {integrity: sha512-kXFdUqEkbB1E66dfqu7sk65w0CaDVp+uPeJ4eOacxBuVgKk/poy+b8/XpFfV443UNB8LUUvzgTzyWLxDQte2Dw==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [arm64] os: [openharmony] - '@oxc-parser/binding-win32-arm64-msvc@0.150.0': - resolution: {integrity: sha512-VqeRb5JX/bKYBrff7TUDvJyKY0914UzuCkuXIGxJS4FUmvMNfqkCbc7Sq90iMz9DlmAtlggwaBYQ9eg3h3ltiw==} + '@oxc-parser/binding-win32-arm64-msvc@0.160.0': + resolution: {integrity: sha512-tzYHz6BOwmKCY2c8txeV06CkMzwEVQhFwug8OR75q2UVRMfksf9yD5UBjAeauPEiFhzNogg1RRyk8UZ0bjMXvg==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [arm64] os: [win32] - '@oxc-parser/binding-win32-ia32-msvc@0.150.0': - resolution: {integrity: sha512-EPqJfeZ4Pgg2BJSsCV8GozxV0FDltRzpVtGVa1r2noJu1iu+opOw3gtBWXwIo9odCT/MdFfyHxdy0/CRqs3OqA==} + '@oxc-parser/binding-win32-ia32-msvc@0.160.0': + resolution: {integrity: sha512-vyYZ4gcWUPuPANDj66eBnZ7+CFzUU0pzX28a5armxejWxM7onM3awHkM4PB/al8eEZ3MH8l0AprX/1jXrfGh7Q==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [ia32] os: [win32] - '@oxc-parser/binding-win32-x64-msvc@0.150.0': - resolution: {integrity: sha512-n5YMzbqwPQqozbkrexi0lNZrUz5cnPHalYpFWe6Dau7AmKIWNo+y24IwzDuZEQtEdUHuKhXmMMih/MPjOI+CMw==} + '@oxc-parser/binding-win32-x64-msvc@0.160.0': + resolution: {integrity: sha512-KvENUAjmLfLBJBTF9yQ2wb5/DH41+FPM45oM7NMTgW0R3kN49NUj314SaDqqqkba+4cNTBt8NA2Ux5dekZB68w==} engines: {node: ^20.19.0 || >=22.12.0} cpu: [x64] os: [win32] - '@oxc-project/types@0.150.0': - resolution: {integrity: sha512-rDS5/31E9HfPl/CIzGrn0DOlvBbXFseQ5URJ9sYMfstbKLD/c6Gm9vmRzRGDdAXyOIL4zmO37lc9RIwYqVruZw==} - '@oxc-project/types@0.152.0': resolution: {integrity: sha512-oM/5rLBm2tPkg0iBgkH/FOeR3PCDpY19GTgAZjMFM8h9WI9VW7cLgzp6nwtarYKmovavIQZ+Fe/RKX/8C8O/Rw==} '@oxc-project/types@0.156.0': resolution: {integrity: sha512-1Duyg48TdJNdyhEB8Xn1L36bT9Pv6GUtlKjHxOys8xkaF/rQq3XJE+bAurSK/AgIz5mGFsb77cn9Pb20+WCScw==} + '@oxc-project/types@0.160.0': + resolution: {integrity: sha512-gw4k9syEmnckbOgw2A2FU1TBDdX9hfwV9jEn/uio65pguPzwWiXQS3OIJDMEhv9m06tj9XiEe6RoD0YA+LgreA==} + '@oxc-resolver/binding-android-arm-eabi@11.24.2': resolution: {integrity: sha512-y09e0L0SRI2OA2tUIrjBgoV3eH5hvUKXNkJqXmNo5V2WxIjyC7I7aJfRLMEVpA8yi95f90gFDvO0VMgrDw+vwA==} cpu: [arm] @@ -7022,9 +7022,9 @@ packages: resolution: {integrity: sha512-vKatAh4SlVfgbv+YtmhiRjhEMJsYpsG1Y2rMQtR+SVSbytsSD1YGzDIcrAJmdFec88u/+VoGmxnl+80gL1tRCQ==} engines: {node: '>= 6'} - formatly@0.7.1: - resolution: {integrity: sha512-ESuCEJE0SGgabl9q+zABI8LhJDmF+8nhpuqDzuM48HfJ9QTD5o6PqFJDFZY7w6f8xsh5lixuj5nJsQNvYOWvKQ==} - engines: {node: '>=18.3.0'} + formatly@0.12.3: + resolution: {integrity: sha512-jGtjZLVw6OXvfwqxrxYBc+x+CxmOcMT/KjZagmkrYCQTEtQxJPablRqZPFSNq75drNsHsadjb1djIsE9KE705w==} + engines: {node: ^20.12.0 || >=22} hasBin: true formdata-polyfill@4.0.10: @@ -7611,8 +7611,8 @@ packages: resolution: {integrity: sha512-dhG34DXATL5hSxJbIexCft8FChFXtmskoZYnoPWjXQuebWYCNkVeV3KkGegCK9CP1oswI/vQibS2GY7Em/sJJA==} engines: {node: '>= 8'} - knip@6.39.0: - resolution: {integrity: sha512-Y7g6Ve1ATMox1u1v+gx3z9LTlvzVLTJISm/LVn9TgBU4qc7OoC63AWGO8qCFPVDDdaqlYdXkDDvvO1METBfTRw==} + knip@6.49.0: + resolution: {integrity: sha512-8Gf4R0xcJx1NdNKfr6gOGgSVBE1flB+KHPKPybDTKJ/hPtnswxyFE7Zpsk71kBvzAKReezakbe3DbQ0qAT4vzA==} engines: {node: ^20.19.0 || >=22.12.0} hasBin: true @@ -8344,8 +8344,8 @@ packages: outdent@0.5.0: resolution: {integrity: sha512-/jHxFIzoMXdqPzTaCpFzAAWhpkSjZPF4Vsn6jAfNpmbH/ymsmd7Qc6VE9BGn0L6YMj6uwpQLxCECpus4ukKS9Q==} - oxc-parser@0.150.0: - resolution: {integrity: sha512-zwajKw1GUa57IOdafIS7/yOObGF2NihwIfZfs5yJTRprMSkiwhWOc/k+n8bwnUPbHr2/XsjfBO8KyTPaW3VpWg==} + oxc-parser@0.160.0: + resolution: {integrity: sha512-IIc9PydmdnTcH1hucWCHfTUbAuHWPDEs8+WlmW7td3jJnaYrbzvPQgcc99FEJc0gURrVU8EskpAr2VMyJ8VbzA==} engines: {node: ^20.19.0 || >=22.12.0} oxc-resolver@11.24.2: @@ -8456,6 +8456,15 @@ packages: resolution: {integrity: sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==} engines: {node: '>=8'} + parse-standard-args@0.3.0: + resolution: {integrity: sha512-SH663jox6V7vxSZgroZJw9DgvSbcNHWOnjHjgvsPyj0/+OIbFraNJyDQbA+ATaAUIi0OGAmV27bIGUgcAEM41g==} + engines: {node: '>=18.7.0'} + peerDependencies: + '@clack/prompts': '>=0.11' + peerDependenciesMeta: + '@clack/prompts': + optional: true + parse5-htmlparser2-tree-adapter@7.1.0: resolution: {integrity: sha512-ruw5xyKs6lrpo9x9rCZqZZnIUntICjQAd0Wsmp396Ul9lN/h+ifgVV1x1gZHi8euej6wTfpqX8j+BFQxF0NS/g==} @@ -9157,10 +9166,6 @@ packages: resolution: {integrity: sha512-dWUG8F5sIIARXih1DTaQAX4SsiTXhInKf1buxdY9DIg4ZYPZK5nGM1VRIYmEbDbsHt7USo99xSLFu5Q1IqTmsg==} engines: {node: '>= 18'} - smol-toml@1.9.0: - resolution: {integrity: sha512-hpd+HLON7HdZXqYchMM/+LaTTbdK0AU3NngIJ4KVyWbY9bfQqdL9cD+4yf6dUoU2Ap4VsU0JkQi6FxAI1B2mXQ==} - engines: {node: '>= 18'} - smol-toml@1.9.1: resolution: {integrity: sha512-j7WyPdf0CJoutMzMoPLF/bVXHtKZIT9Rb4eGeEbWw8X2t5oirjPgpL+OpaENZrILYaXqYwnVH+qgUwVbl+pUJQ==} engines: {node: '>= 18'} @@ -9500,8 +9505,8 @@ packages: ultrahtml@1.7.0: resolution: {integrity: sha512-2xRd0VHoAQE4M+vF/DvFFB7pUV0ZxTW1TLi7lHQWnF/Sb5TPeEUV/l+hxcNnGO00ZXGnR0voCMmYRKQf+rvJ2g==} - unbash@4.0.12: - resolution: {integrity: sha512-PnKvRX+Fbxl/usVlTr/31tXIOVAH+8OdC9qaxUQcvurwEnoc3Vk/ipi2Ce8IjMxzK9byfSGdsUBjqqJGc1o5lw==} + unbash@6.0.5: + resolution: {integrity: sha512-5P8o+nYRueKpHxmemofYqZRZCSWAi+Tqy31MQS8l/sT54Z+Axn55N9CnWPo19BxxJD4wYYf6RqlcURhWkrFXew==} engines: {node: '>=14'} unconfig-core@7.5.0: @@ -10085,9 +10090,6 @@ packages: zod@3.25.76: resolution: {integrity: sha512-gzUt/qt81nXsFGKIFcC3YnfEAx5NkunCfnDlvuBSSFS02bcXu4Lmea0AFIUwbLWxWPx3d9p8S5QoaujKcNQxcQ==} - zod@4.6.5: - resolution: {integrity: sha512-v5l/aFXZQeai4awLbOpSoHecE9UiMrnfx75tEXLjNonXVARxQ5mOeipTjROUchszUNCqnE+hqAMujRsRHsut2Q==} - zod@4.6.7: resolution: {integrity: sha512-g8W2D2kU6a8untc053fX1uVBKzM7yqAxW/3zwk83+6RyF2+SKOuV+c0wBDhUwzV1PaGapmZH+rmcUzPf+3CGwg==} @@ -11878,69 +11880,69 @@ snapshots: '@oslojs/encoding@1.1.0': {} - '@oxc-parser/binding-android-arm-eabi@0.150.0': + '@oxc-parser/binding-android-arm-eabi@0.160.0': optional: true - '@oxc-parser/binding-android-arm64@0.150.0': + '@oxc-parser/binding-android-arm64@0.160.0': optional: true - '@oxc-parser/binding-darwin-arm64@0.150.0': + '@oxc-parser/binding-darwin-arm64@0.160.0': optional: true - '@oxc-parser/binding-darwin-x64@0.150.0': + '@oxc-parser/binding-darwin-x64@0.160.0': optional: true - '@oxc-parser/binding-freebsd-x64@0.150.0': + '@oxc-parser/binding-freebsd-x64@0.160.0': optional: true - '@oxc-parser/binding-linux-arm-gnueabihf@0.150.0': + '@oxc-parser/binding-linux-arm-gnueabihf@0.160.0': optional: true - '@oxc-parser/binding-linux-arm-musleabihf@0.150.0': + '@oxc-parser/binding-linux-arm-musleabihf@0.160.0': optional: true - '@oxc-parser/binding-linux-arm64-gnu@0.150.0': + '@oxc-parser/binding-linux-arm64-gnu@0.160.0': optional: true - '@oxc-parser/binding-linux-arm64-musl@0.150.0': + '@oxc-parser/binding-linux-arm64-musl@0.160.0': optional: true - '@oxc-parser/binding-linux-ppc64-gnu@0.150.0': + '@oxc-parser/binding-linux-ppc64-gnu@0.160.0': optional: true - '@oxc-parser/binding-linux-riscv64-gnu@0.150.0': + '@oxc-parser/binding-linux-riscv64-gnu@0.160.0': optional: true - '@oxc-parser/binding-linux-riscv64-musl@0.150.0': + '@oxc-parser/binding-linux-riscv64-musl@0.160.0': optional: true - '@oxc-parser/binding-linux-s390x-gnu@0.150.0': + '@oxc-parser/binding-linux-s390x-gnu@0.160.0': optional: true - '@oxc-parser/binding-linux-x64-gnu@0.150.0': + '@oxc-parser/binding-linux-x64-gnu@0.160.0': optional: true - '@oxc-parser/binding-linux-x64-musl@0.150.0': + '@oxc-parser/binding-linux-x64-musl@0.160.0': optional: true - '@oxc-parser/binding-openharmony-arm64@0.150.0': + '@oxc-parser/binding-openharmony-arm64@0.160.0': optional: true - '@oxc-parser/binding-win32-arm64-msvc@0.150.0': + '@oxc-parser/binding-win32-arm64-msvc@0.160.0': optional: true - '@oxc-parser/binding-win32-ia32-msvc@0.150.0': + '@oxc-parser/binding-win32-ia32-msvc@0.160.0': optional: true - '@oxc-parser/binding-win32-x64-msvc@0.150.0': + '@oxc-parser/binding-win32-x64-msvc@0.160.0': optional: true - '@oxc-project/types@0.150.0': {} - '@oxc-project/types@0.152.0': {} '@oxc-project/types@0.156.0': {} + '@oxc-project/types@0.160.0': {} + '@oxc-resolver/binding-android-arm-eabi@11.24.2': optional: true @@ -15204,10 +15206,15 @@ snapshots: hasown: 2.0.4 mime-types: 2.1.35 - formatly@0.7.1: + formatly@0.12.3(@clack/prompts@1.8.1): dependencies: fd-package-json: 2.0.0 - package-manager-detector: 1.8.0 + package-manager-detector: 1.9.0 + parse-standard-args: 0.3.0(@clack/prompts@1.8.1) + tinyexec: 1.3.1 + zod: 4.6.7 + transitivePeerDependencies: + - '@clack/prompts' formdata-polyfill@4.0.10: dependencies: @@ -15818,21 +15825,21 @@ snapshots: klona@2.0.6: {} - knip@6.39.0: + knip@6.49.0(@clack/prompts@1.8.1): dependencies: - fdir: 6.5.0(picomatch@4.0.7) - formatly: 0.7.1 + formatly: 0.12.3(@clack/prompts@1.8.1) get-tsconfig: 4.14.3 jiti: 2.7.0 - oxc-parser: 0.150.0 + oxc-parser: 0.160.0 oxc-resolver: 11.24.2 picomatch: 4.0.7 - smol-toml: 1.9.0 + smol-toml: 1.9.1 strip-json-comments: 5.0.3 tinyglobby: 0.2.17 - unbash: 4.0.12 + unbash: 6.0.5 yaml: 2.9.1 - zod: 4.6.5 + transitivePeerDependencies: + - '@clack/prompts' layout-base@1.0.2: {} @@ -17032,29 +17039,29 @@ snapshots: outdent@0.5.0: {} - oxc-parser@0.150.0: + oxc-parser@0.160.0: dependencies: - '@oxc-project/types': 0.150.0 + '@oxc-project/types': 0.160.0 optionalDependencies: - '@oxc-parser/binding-android-arm-eabi': 0.150.0 - '@oxc-parser/binding-android-arm64': 0.150.0 - '@oxc-parser/binding-darwin-arm64': 0.150.0 - '@oxc-parser/binding-darwin-x64': 0.150.0 - '@oxc-parser/binding-freebsd-x64': 0.150.0 - '@oxc-parser/binding-linux-arm-gnueabihf': 0.150.0 - '@oxc-parser/binding-linux-arm-musleabihf': 0.150.0 - '@oxc-parser/binding-linux-arm64-gnu': 0.150.0 - '@oxc-parser/binding-linux-arm64-musl': 0.150.0 - '@oxc-parser/binding-linux-ppc64-gnu': 0.150.0 - '@oxc-parser/binding-linux-riscv64-gnu': 0.150.0 - '@oxc-parser/binding-linux-riscv64-musl': 0.150.0 - '@oxc-parser/binding-linux-s390x-gnu': 0.150.0 - '@oxc-parser/binding-linux-x64-gnu': 0.150.0 - '@oxc-parser/binding-linux-x64-musl': 0.150.0 - '@oxc-parser/binding-openharmony-arm64': 0.150.0 - '@oxc-parser/binding-win32-arm64-msvc': 0.150.0 - '@oxc-parser/binding-win32-ia32-msvc': 0.150.0 - '@oxc-parser/binding-win32-x64-msvc': 0.150.0 + '@oxc-parser/binding-android-arm-eabi': 0.160.0 + '@oxc-parser/binding-android-arm64': 0.160.0 + '@oxc-parser/binding-darwin-arm64': 0.160.0 + '@oxc-parser/binding-darwin-x64': 0.160.0 + '@oxc-parser/binding-freebsd-x64': 0.160.0 + '@oxc-parser/binding-linux-arm-gnueabihf': 0.160.0 + '@oxc-parser/binding-linux-arm-musleabihf': 0.160.0 + '@oxc-parser/binding-linux-arm64-gnu': 0.160.0 + '@oxc-parser/binding-linux-arm64-musl': 0.160.0 + '@oxc-parser/binding-linux-ppc64-gnu': 0.160.0 + '@oxc-parser/binding-linux-riscv64-gnu': 0.160.0 + '@oxc-parser/binding-linux-riscv64-musl': 0.160.0 + '@oxc-parser/binding-linux-s390x-gnu': 0.160.0 + '@oxc-parser/binding-linux-x64-gnu': 0.160.0 + '@oxc-parser/binding-linux-x64-musl': 0.160.0 + '@oxc-parser/binding-openharmony-arm64': 0.160.0 + '@oxc-parser/binding-win32-arm64-msvc': 0.160.0 + '@oxc-parser/binding-win32-ia32-msvc': 0.160.0 + '@oxc-parser/binding-win32-x64-msvc': 0.160.0 oxc-resolver@11.24.2: optionalDependencies: @@ -17217,6 +17224,12 @@ snapshots: json-parse-even-better-errors: 2.3.1 lines-and-columns: 1.2.4 + parse-standard-args@0.3.0(@clack/prompts@1.8.1): + dependencies: + '@standard-schema/spec': 1.1.0 + optionalDependencies: + '@clack/prompts': 1.8.1 + parse5-htmlparser2-tree-adapter@7.1.0: dependencies: domhandler: 5.0.3 @@ -18091,8 +18104,6 @@ snapshots: smol-toml@1.6.1: {} - smol-toml@1.9.0: {} - smol-toml@1.9.1: {} sonic-boom@4.2.1: @@ -18400,7 +18411,7 @@ snapshots: ultrahtml@1.7.0: {} - unbash@4.0.12: {} + unbash@6.0.5: {} unconfig-core@7.5.0: dependencies: @@ -18872,8 +18883,6 @@ snapshots: zod@3.25.76: {} - zod@4.6.5: {} - zod@4.6.7: {} zwitch@2.0.4: {} From 02072ab6ec324f3cac6744bfdd7a459a98eaa189 Mon Sep 17 00:00:00 2001 From: "autofix-ci[bot]" <114827586+autofix-ci[bot]@users.noreply.github.com> Date: Mon, 30 Nov 2026 01:50:51 +0000 Subject: [PATCH 2/2] ci: apply automated fixes --- .../skills/wordpress-to-tanstack-cms/SKILL.md | 6 +- README.md | 12 +- app/docs-preview/README.md | 20 +- app/docs-preview/scripts/ingest-docs.mjs | 60 +- app/docs-preview/scripts/preview.mjs | 16 +- app/docs-preview/src/byok.api.ts | 22 +- app/docs-preview/src/byok.server.ts | 5 +- app/docs-preview/src/cms.definition.ts | 18 +- .../src/components/docs-sidebar.tsx | 4 +- .../src/ingest-artifacts.server.ts | 4 +- app/docs-preview/src/lib/links.ts | 3 +- app/docs-preview/src/routes/ask.tsx | 8 +- app/docs-preview/src/routes/docs.$.tsx | 24 +- app/docs-preview/src/routes/report.tsx | 8 +- app/docs-preview/src/routes/search.tsx | 19 +- app/docs-preview/tests/read-only.test.ts | 12 +- app/prm/bakeoff/README.md | 22 +- app/prm/bakeoff/latest.json | 180 ++--- examples/wp-vs-tanstack/ADMIN-GAP-ANALYSIS.md | 107 +-- examples/wp-vs-tanstack/COMPARISON.md | 61 +- examples/wp-vs-tanstack/src/cms.config.ts | 41 +- examples/wp-vs-tanstack/src/cms.definition.ts | 21 +- examples/wp-vs-tanstack/src/cms.renderers.tsx | 123 +++- .../wp-vs-tanstack/src/routes/blog.slug.tsx | 37 +- examples/wp-vs-tanstack/src/routes/blog.tsx | 16 +- .../src/routes/pages.catchall.tsx | 15 +- examples/wp-vs-tanstack/src/seed-data.ts | 32 +- examples/wp-vs-tanstack/src/styles.css | 6 +- .../wordpress/docker-compose.yml | 12 +- .../wordpress/seed/content/about.html | 335 +++++++-- .../wordpress/seed/content/blog.html | 14 +- .../wordpress/seed/content/contact.html | 187 ++++- .../wordpress/seed/content/home.html | 347 ++++++++-- .../wordpress/seed/content/post-cooling.html | 125 +++- .../wordpress/seed/content/post-furnace.html | 115 +++- .../seed/content/post-waterheater.html | 120 +++- .../wordpress/seed/content/reviews.html | 296 ++++++-- .../wordpress/seed/content/services.html | 644 ++++++++++++++---- .../wp-vs-tanstack/wordpress/seed/custom.css | 10 +- kody/headless-api/scripts/local-smoke.mts | 44 +- kody/headless-api/src/cms.config.ts | 4 +- onboarding/apps/demo/src/styles.css | 4 +- onboarding/apps/demo/tests/demo.test.ts | 7 +- .../apps/demo/tests/entertainment.test.ts | 1 - .../apps/demo/tests/tanstack-ai.test.ts | 32 +- onboarding/packages/ai/src/tools.ts | 5 +- onboarding/packages/ai/src/turn.ts | 6 +- onboarding/packages/ai/tests/ai.test.ts | 7 +- onboarding/packages/core/src/define.ts | 4 +- onboarding/packages/core/src/machine.ts | 13 +- onboarding/packages/core/tests/core.test.ts | 84 +-- onboarding/packages/react/src/Wizard.tsx | 45 +- onboarding/packages/react/src/chat.tsx | 7 +- onboarding/packages/react/src/controls.tsx | 5 +- onboarding/packages/react/src/onboarding.css | 6 +- onboarding/packages/react/tests/form.test.tsx | 20 +- .../packages/react/tests/react.test.tsx | 16 +- packages/api/src/markdown.ts | 5 +- packages/api/src/ops.ts | 7 +- packages/api/src/start.ts | 4 +- packages/api/tests/health.test.ts | 52 +- packages/api/tests/releases.test.ts | 186 +++-- packages/cli/tests/cli.test.ts | 4 +- packages/cms-compat-wp/README.md | 6 +- packages/cms-compat-wp/src/connector.ts | 6 +- packages/cms-compat-wp/src/definition.ts | 5 +- .../cms-compat-wp/src/features/comments.ts | 18 +- packages/cms-compat-wp/src/index.ts | 6 +- packages/cms-compat-wp/tests/features.test.ts | 5 +- .../cms-compat-wp/tests/summarize.test.ts | 17 +- packages/cms-compat-wp/tsconfig.json | 7 +- packages/cms-connect-atproto/README.md | 16 +- packages/core/README.md | 16 +- packages/core/src/config.ts | 3 +- packages/core/src/server.ts | 5 +- packages/core/src/server/auth.ts | 13 +- .../core/src/server/content-migrations.ts | 6 +- packages/core/src/server/releases.ts | Bin 13976 -> 14064 bytes packages/core/src/server/storage.ts | 5 +- .../core/src/server/store/document-state.ts | 6 +- packages/core/src/storage/conformance.ts | 18 +- packages/core/tests/access-context.test.ts | 8 +- packages/core/tests/readiness.test.ts | 4 +- packages/core/tests/store.test.ts | 7 +- packages/core/tests/transfer.test.ts | 54 +- packages/search-cms/tests/cms.test.ts | 20 +- packages/store-postgres/package.json | 2 +- packages/store-postgres/src/index.ts | 10 +- packages/store-postgres/src/pglite.ts | 4 +- packages/store-postgres/tests/pglite.test.ts | 14 +- packages/ui-react/src/routes/dashboard.tsx | 4 +- packages/ui-react/src/routes/media.tsx | 12 +- packages/ui-react/src/routes/profile.tsx | 4 +- .../ui-react/tests/virtual-routes.test.ts | 3 +- 94 files changed, 2846 insertions(+), 1133 deletions(-) diff --git a/.claude/skills/wordpress-to-tanstack-cms/SKILL.md b/.claude/skills/wordpress-to-tanstack-cms/SKILL.md index d9647258..048ab2a1 100644 --- a/.claude/skills/wordpress-to-tanstack-cms/SKILL.md +++ b/.claude/skills/wordpress-to-tanstack-cms/SKILL.md @@ -241,7 +241,7 @@ letting "migrated" imply completeness. ## 8. Visual parity: reproducing the theme in userland -Migrating content reproduces the markup. Reproducing the *look* is separate work, +Migrating content reproduces the markup. Reproducing the _look_ is separate work, and it follows one firm rule that comes straight from the goal of a faithful port: **reproduce the WordPress design in the TanStack app's userland (theme tokens, block renderers, seed, a little config), and never edit WordPress to make @@ -290,7 +290,7 @@ breakpoint", default **921px** (`min-[921px]:`), not Tailwind's 768px. - **Headings use fixed px, not fluid sizes.** Gutenberg writes an inline `font-size` (for example a 54px hero `

`), and Astra does not scale inline sizes down, so the heading stays 54px at every width. A fluid - `clamp(…, 7vw, 54px)` on the ported side renders *smaller* at tablet widths; + `clamp(…, 7vw, 54px)` on the ported side renders _smaller_ at tablet widths; use the same fixed px. - **Card titles inherit the theme heading weight (about 600); section headings are explicit (often 800).** A card `

`/`

` with no explicit weight in the @@ -333,7 +333,7 @@ renders, and keep the arrays editable for the next site. ### Measure, do not eyeball -Load both sites in one window at the *same* width and diff `getComputedStyle` on +Load both sites in one window at the _same_ width and diff `getComputedStyle` on matching elements (font-family, size, weight, line-height, color, padding, and `grid-template-columns`). A window-width mismatch is the most common false "they don't match", so equalize width first. Browser-automation windows are often diff --git a/README.md b/README.md index e20d4e3a..49f4cbe4 100644 --- a/README.md +++ b/README.md @@ -217,12 +217,12 @@ TanStack CMS ships a 14-row starter catalog (12 application classes and 2 delive ## Examples -| Example | What it shows | -| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ | -| [`blog`](./examples/blog) | The reference app: posts, pages, blocks, AI editing, and the Playwright suite. | -| [`blog-voting`](./examples/blog-voting) | Extending the CMS with your own collections and routes (votes on posts). | -| [`db-sqlite`](./examples/db-sqlite), [`db-federated`](./examples/db-federated) | TanStack DB as the data layer: a writable CMS collection, and CMS copy joined with other services in one live query. | -| [`payload-after`](./examples/payload-after), [`astro-starlight-after`](./examples/astro-starlight-after), [`emdash-after`](./examples/emdash-after), [`wordpress-after`](./examples/wordpress-after) | Sites migrated from Payload, Astro Starlight, EmDash, and WordPress, each next to its `*-before` source. | +| Example | What it shows | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | +| [`blog`](./examples/blog) | The reference app: posts, pages, blocks, AI editing, and the Playwright suite. | +| [`blog-voting`](./examples/blog-voting) | Extending the CMS with your own collections and routes (votes on posts). | +| [`db-sqlite`](./examples/db-sqlite), [`db-federated`](./examples/db-federated) | TanStack DB as the data layer: a writable CMS collection, and CMS copy joined with other services in one live query. | +| [`payload-after`](./examples/payload-after), [`astro-starlight-after`](./examples/astro-starlight-after), [`emdash-after`](./examples/emdash-after), [`wordpress-after`](./examples/wordpress-after) | Sites migrated from Payload, Astro Starlight, EmDash, and WordPress, each next to its `*-before` source. | ## Migration skills diff --git a/app/docs-preview/README.md b/app/docs-preview/README.md index c55befb8..0a163dbb 100644 --- a/app/docs-preview/README.md +++ b/app/docs-preview/README.md @@ -68,16 +68,16 @@ flagged in the report, not mapped to blocks. ## Configuration -| Env var | Default | Purpose | -| --- | --- | --- | -| `DOCS_DIR` | — | The docs directory to ingest (or pass as the CLI arg). | -| `ANTHROPIC_API_KEY` | — | Enables `/ask`. Else set a key at `/ai-settings`. | -| `DOCS_PREVIEW_MODEL` | `claude-sonnet-4-6` | The Claude model for `/ask`. | -| `DOCS_PREVIEW_TITLE` | source dir name | The site title. | -| `DOCS_PREVIEW_DATA_DIR` | `.data-` | Where the PGlite store lives. | -| `DOCS_PREVIEW_INGEST_DIR` | `.ingest-` | Where ingest artifacts live. | - -**BYOK.** The AI chat takes a key from `ANTHROPIC_API_KEY` *or* one pasted at +| Env var | Default | Purpose | +| ------------------------- | ------------------- | ------------------------------------------------------ | +| `DOCS_DIR` | — | The docs directory to ingest (or pass as the CLI arg). | +| `ANTHROPIC_API_KEY` | — | Enables `/ask`. Else set a key at `/ai-settings`. | +| `DOCS_PREVIEW_MODEL` | `claude-sonnet-4-6` | The Claude model for `/ask`. | +| `DOCS_PREVIEW_TITLE` | source dir name | The site title. | +| `DOCS_PREVIEW_DATA_DIR` | `.data-` | Where the PGlite store lives. | +| `DOCS_PREVIEW_INGEST_DIR` | `.ingest-` | Where ingest artifacts live. | + +**BYOK.** The AI chat takes a key from `ANTHROPIC_API_KEY` _or_ one pasted at `/ai-settings` (stored in the data dir, local use only). With no key, `/ask` is disabled and says so — search and preview still work. diff --git a/app/docs-preview/scripts/ingest-docs.mjs b/app/docs-preview/scripts/ingest-docs.mjs index cceb1cfa..14ee3e4b 100644 --- a/app/docs-preview/scripts/ingest-docs.mjs +++ b/app/docs-preview/scripts/ingest-docs.mjs @@ -39,7 +39,9 @@ const CMS_EXPORT_VERSION = 1 // --------------------------------------------------------------------------- const docsDir = path.resolve(process.argv[2] || process.env.DOCS_DIR || '') const outDir = path.resolve( - process.argv[3] || process.env.DOCS_PREVIEW_OUT || path.join(process.cwd(), '.ingest'), + process.argv[3] || + process.env.DOCS_PREVIEW_OUT || + path.join(process.cwd(), '.ingest'), ) if (!process.argv[2] && !process.env.DOCS_DIR) { console.error('ingest-docs: pass a docs directory (argv or DOCS_DIR).') @@ -53,7 +55,13 @@ if (!existsSync(docsDir) || !statSync(docsDir).isDirectory()) { // --------------------------------------------------------------------------- // fs helpers // --------------------------------------------------------------------------- -const SKIP_DIRS = new Set(['node_modules', '.git', '.vitepress', 'dist', 'build']) +const SKIP_DIRS = new Set([ + 'node_modules', + '.git', + '.vitepress', + 'dist', + 'build', +]) /** Every file under `dir`, recursively, as absolute paths. */ function walk(dir, acc = []) { @@ -88,7 +96,10 @@ function toSlug(relPath) { /** A stable document id from a slug. */ function toId(slug) { if (slug === '/') return 'index' - return slug.replace(/[^a-z0-9]+/gi, '-').replace(/^-+|-+$/g, '').toLowerCase() + return slug + .replace(/[^a-z0-9]+/gi, '-') + .replace(/^-+|-+$/g, '') + .toLowerCase() } /** @@ -149,7 +160,8 @@ function readConfigNav() { const sections = [] // ordered [{ label, slugs: [slug...] }] const targets = [] // every `to` the config references const configFile = path.join(docsDir, 'config.json') - if (!existsSync(configFile)) return { bySlug, sections, targets, present: false } + if (!existsSync(configFile)) + return { bySlug, sections, targets, present: false } let config try { config = JSON.parse(readFileSync(configFile, 'utf8')) @@ -162,7 +174,10 @@ function readConfigNav() { const slugs = [] const addChild = (child) => { if (child.to != null) { - const slug = `/${String(child.to).replace(/^\/+/, '')}`.replace(/^\/\//, '/') + const slug = `/${String(child.to).replace(/^\/+/, '')}`.replace( + /^\/\//, + '/', + ) const norm = slug === '/' ? '/' : slug.replace(/^\//, '') targets.push(norm) if (!bySlug.has(norm)) { @@ -298,7 +313,8 @@ for (const abs of mdFiles) { id: toId(slug), slug, title, - description: typeof data.description === 'string' ? data.description : undefined, + description: + typeof data.description === 'string' ? data.description : undefined, section, sidebarLabel, sidebarOrder, @@ -493,19 +509,32 @@ if (configNav.present) { const pg = pageBySlug.get(slug) if (!pg) continue placed.add(slug) - navPages.push({ slug, title: pg.title, label: pg.sidebarLabel, framework: pg.framework }) + navPages.push({ + slug, + title: pg.title, + label: pg.sidebarLabel, + framework: pg.framework, + }) } if (navPages.length) navSections.push({ label: sec.label, pages: navPages }) } } const leftover = pages.filter((p) => !placed.has(p.slug)) const bySection = new Map() -for (const p of leftover.sort((a, b) => a.sidebarOrder - b.sidebarOrder || a.slug.localeCompare(b.slug))) { +for (const p of leftover.sort( + (a, b) => a.sidebarOrder - b.sidebarOrder || a.slug.localeCompare(b.slug), +)) { const list = bySection.get(p.section) ?? [] - list.push({ slug: p.slug, title: p.title, label: p.sidebarLabel, framework: p.framework }) + list.push({ + slug: p.slug, + title: p.title, + label: p.sidebarLabel, + framework: p.framework, + }) bySection.set(p.section, list) } -for (const [label, navPages] of bySection) navSections.push({ label, pages: navPages }) +for (const [label, navPages] of bySection) + navSections.push({ label, pages: navPages }) writeFileSync( path.join(outDir, 'nav.json'), @@ -518,7 +547,8 @@ for (const i of issues) issuesByKind[i.kind] = (issuesByKind[i.kind] ?? 0) + 1 const issuesBySeverity = { error: 0, warning: 0, info: 0 } for (const i of issues) issuesBySeverity[i.severity] += 1 const navSourceCounts = {} -for (const p of pages) navSourceCounts[p.navSource] = (navSourceCounts[p.navSource] ?? 0) + 1 +for (const p of pages) + navSourceCounts[p.navSource] = (navSourceCounts[p.navSource] ?? 0) + 1 const report = { generatedAt: exportedAt, @@ -548,7 +578,9 @@ writeFileSync( // --------------------------------------------------------------------------- console.log(`ingest-docs: ${docsDir}`) console.log(` pages: ${pages.length} (from ${mdFiles.length} files)`) -console.log(` sections: ${navSections.length}${configNav.present ? ' (config.json)' : ' (derived)'}`) +console.log( + ` sections: ${navSections.length}${configNav.present ? ' (config.json)' : ' (derived)'}`, +) console.log(` links: ${linksChecked} checked`) console.log(` assets: ${assetsReferenced} referenced`) console.log(` nav source: ${JSON.stringify(navSourceCounts)}`) @@ -556,4 +588,6 @@ console.log( ` issues: ${issues.length} — ${issuesBySeverity.error} error, ${issuesBySeverity.warning} warning, ${issuesBySeverity.info} info`, ) console.log(` ${JSON.stringify(issuesByKind)}`) -console.log(` → ${path.relative(process.cwd(), outDir)}/{cms-export,nav,ingest-report}.json`) +console.log( + ` → ${path.relative(process.cwd(), outDir)}/{cms-export,nav,ingest-report}.json`, +) diff --git a/app/docs-preview/scripts/preview.mjs b/app/docs-preview/scripts/preview.mjs index 40709fc1..b168e86b 100644 --- a/app/docs-preview/scripts/preview.mjs +++ b/app/docs-preview/scripts/preview.mjs @@ -16,7 +16,9 @@ import path from 'node:path' const docsDir = path.resolve(process.argv[2] || process.env.DOCS_DIR || '') if (!process.argv[2] && !process.env.DOCS_DIR) { - console.error('Usage: pnpm preview (or DOCS_DIR= pnpm preview)') + console.error( + 'Usage: pnpm preview (or DOCS_DIR= pnpm preview)', + ) process.exit(1) } if (!existsSync(docsDir) || !statSync(docsDir).isDirectory()) { @@ -43,7 +45,10 @@ const env = { function run(step, file, args) { console.log(`\n▸ ${step}`) - const r = spawnSync(process.execPath, [file, ...args], { stdio: 'inherit', env }) + const r = spawnSync(process.execPath, [file, ...args], { + stdio: 'inherit', + env, + }) if (r.status !== 0) { console.error(`\n✗ ${step} failed.`) process.exit(r.status ?? 1) @@ -63,9 +68,10 @@ run('Load into the CMS', 'scripts/load-export.mjs', [ console.log(`\n▸ Serving — http://localhost:3017 (Ctrl-C to stop)`) if (!process.env.ANTHROPIC_API_KEY && !process.env.ANTHROPIC_AUTH_TOKEN) { - console.log(' (no ANTHROPIC_API_KEY — /ask is off; set one or use /ai-settings)') + console.log( + ' (no ANTHROPIC_API_KEY — /ask is off; set one or use /ai-settings)', + ) } const serve = spawn('pnpm', ['dev'], { stdio: 'inherit', env }) serve.on('exit', (code) => process.exit(code ?? 0)) -for (const sig of ['SIGINT', 'SIGTERM']) - process.on(sig, () => serve.kill(sig)) +for (const sig of ['SIGINT', 'SIGTERM']) process.on(sig, () => serve.kill(sig)) diff --git a/app/docs-preview/src/byok.api.ts b/app/docs-preview/src/byok.api.ts index 30ba7f8e..3511439a 100644 --- a/app/docs-preview/src/byok.api.ts +++ b/app/docs-preview/src/byok.api.ts @@ -6,10 +6,12 @@ import { createServerFn } from '@tanstack/react-start' import { z } from 'zod' -export const byokStatus = createServerFn({ method: 'GET' }).handler(async () => { - const m = await import('./byok.server') - return { source: m.keySource(), model: m.resolveModel() } -}) +export const byokStatus = createServerFn({ method: 'GET' }).handler( + async () => { + const m = await import('./byok.server') + return { source: m.keySource(), model: m.resolveModel() } + }, +) export const byokSet = createServerFn({ method: 'POST' }) .validator(z.object({ key: z.string().min(1).max(500) })) @@ -19,8 +21,10 @@ export const byokSet = createServerFn({ method: 'POST' }) return { source: m.keySource(), model: m.resolveModel() } }) -export const byokClear = createServerFn({ method: 'POST' }).handler(async () => { - const m = await import('./byok.server') - m.clearStoredKey() - return { source: m.keySource(), model: m.resolveModel() } -}) +export const byokClear = createServerFn({ method: 'POST' }).handler( + async () => { + const m = await import('./byok.server') + m.clearStoredKey() + return { source: m.keySource(), model: m.resolveModel() } + }, +) diff --git a/app/docs-preview/src/byok.server.ts b/app/docs-preview/src/byok.server.ts index 7d2da06d..8f371916 100644 --- a/app/docs-preview/src/byok.server.ts +++ b/app/docs-preview/src/byok.server.ts @@ -50,7 +50,10 @@ export function getStoredKey(): string | undefined { export function setStoredKey(key: string): void { const dir = resolveDataDir() mkdirSync(dir, { recursive: true }) - writeFileSync(byokFile(), `${JSON.stringify({ anthropicKey: key.trim() }, null, 2)}\n`) + writeFileSync( + byokFile(), + `${JSON.stringify({ anthropicKey: key.trim() }, null, 2)}\n`, + ) } export function clearStoredKey(): void { diff --git a/app/docs-preview/src/cms.definition.ts b/app/docs-preview/src/cms.definition.ts index 3164543d..25077e7b 100644 --- a/app/docs-preview/src/cms.definition.ts +++ b/app/docs-preview/src/cms.definition.ts @@ -28,7 +28,10 @@ * to the source tree. There is no editing surface: this app ingests, renders, * searches, and answers questions about a corpus; it does not change it. */ -import { defineCmsDefinition, defineCollection } from '@tanstack/cms-core/definition' +import { + defineCmsDefinition, + defineCollection, +} from '@tanstack/cms-core/definition' /** The framework variants TanStack docs template with `{$framework}`. */ export const FRAMEWORKS = [ @@ -60,7 +63,8 @@ const collections = [ type: 'slug', nested: true, required: true, - description: 'Docs path, e.g. /guide/data-loading ("/" is the docs home)', + description: + 'Docs path, e.g. /guide/data-loading ("/" is the docs home)', }, { name: 'sidebarLabel', label: 'Sidebar label', type: 'text' }, { name: 'sidebarOrder', label: 'Sidebar order', type: 'number' }, @@ -81,7 +85,8 @@ const collections = [ name: 'sourcePath', label: 'Source path', type: 'text', - description: 'Original file, relative to the docs dir (read-only provenance)', + description: + 'Original file, relative to the docs dir (read-only provenance)', }, { name: 'navSource', @@ -91,7 +96,12 @@ const collections = [ description: 'Where this page’s nav placement came from', }, { name: 'blocks', label: 'Content', type: 'blocks' }, - { name: 'published', label: 'Published', type: 'boolean', defaultValue: true }, + { + name: 'published', + label: 'Published', + type: 'boolean', + defaultValue: true, + }, ], }), ] diff --git a/app/docs-preview/src/components/docs-sidebar.tsx b/app/docs-preview/src/components/docs-sidebar.tsx index 764365a4..c5202aa7 100644 --- a/app/docs-preview/src/components/docs-sidebar.tsx +++ b/app/docs-preview/src/components/docs-sidebar.tsx @@ -51,7 +51,9 @@ export function DocsSidebar({ } /** Flatten the nav into reading order, for prev/next. */ -export function flattenNav(nav: NavData | null): Array<{ slug: string; title: string }> { +export function flattenNav( + nav: NavData | null, +): Array<{ slug: string; title: string }> { if (!nav) return [] return nav.sections.flatMap((s) => s.pages.map((p) => ({ slug: p.slug, title: p.label || p.title })), diff --git a/app/docs-preview/src/ingest-artifacts.server.ts b/app/docs-preview/src/ingest-artifacts.server.ts index 58253738..e67c554c 100644 --- a/app/docs-preview/src/ingest-artifacts.server.ts +++ b/app/docs-preview/src/ingest-artifacts.server.ts @@ -48,7 +48,9 @@ export interface NavData { } export function ingestDir(): string { - return process.env.DOCS_PREVIEW_INGEST_DIR || path.join(process.cwd(), '.ingest') + return ( + process.env.DOCS_PREVIEW_INGEST_DIR || path.join(process.cwd(), '.ingest') + ) } function readJson(name: string): T | null { diff --git a/app/docs-preview/src/lib/links.ts b/app/docs-preview/src/lib/links.ts index d5abbe91..2eab56e3 100644 --- a/app/docs-preview/src/lib/links.ts +++ b/app/docs-preview/src/lib/links.ts @@ -9,8 +9,7 @@ const PREFIX = '/docs' /** Resolve a relative link target against a page's slug into a doc slug. */ export function resolveDocSlug(fromSlug: string, target: string): string { - const fromDir = - fromSlug === '/' ? [] : fromSlug.split('/').slice(0, -1) + const fromDir = fromSlug === '/' ? [] : fromSlug.split('/').slice(0, -1) const clean = target.replace(/\.mdx?$/i, '').replace(/\/index$/i, '') const stack = [...fromDir] for (const part of clean.split('/')) { diff --git a/app/docs-preview/src/routes/ask.tsx b/app/docs-preview/src/routes/ask.tsx index 818e2ab0..d6a0e53c 100644 --- a/app/docs-preview/src/routes/ask.tsx +++ b/app/docs-preview/src/routes/ask.tsx @@ -133,7 +133,9 @@ function AskPage() { {t.sources && t.sources.length ? (
- Sources: + + Sources: + {t.sources.map((slug) => ( Thinking…
+
+ Thinking… +
) : null} {error ? (
diff --git a/app/docs-preview/src/routes/docs.$.tsx b/app/docs-preview/src/routes/docs.$.tsx index 7cd84ce7..9f4904b1 100644 --- a/app/docs-preview/src/routes/docs.$.tsx +++ b/app/docs-preview/src/routes/docs.$.tsx @@ -4,7 +4,12 @@ * `nav.json` (config-first order) and the body renders read-only, with its * relative Markdown links rewritten to `/docs/` so cross-links work. */ -import { createFileRoute, Link, notFound, redirect } from '@tanstack/react-router' +import { + createFileRoute, + Link, + notFound, + redirect, +} from '@tanstack/react-router' import { cmsHead } from '@tanstack/cms-core' import { get, resolveRedirect } from '@tanstack/cms-api/start' import type { Doc } from '@tanstack/cms-core' @@ -38,7 +43,12 @@ export const Route = createFileRoute('/docs/$')({ if (match) throw redirect({ href: match.to, statusCode: match.status }) throw notFound() } - return { id: found.id, doc: found.doc, slug: String(found.doc.slug ?? locator), nav } + return { + id: found.id, + doc: found.doc, + slug: String(found.doc.slug ?? locator), + nav, + } }, head: ({ loaderData }) => { const data = loaderData as DocsPage | undefined @@ -91,14 +101,20 @@ function DocsReader() {
diff --git a/app/docs-preview/src/routes/search.tsx b/app/docs-preview/src/routes/search.tsx index 9f867da0..c9d4d35f 100644 --- a/app/docs-preview/src/routes/search.tsx +++ b/app/docs-preview/src/routes/search.tsx @@ -41,7 +41,9 @@ export const Route = createFileRoute('/search')({ slug: String(i.values?.slug ?? i.id), section: String(i.values?.section ?? 'Docs'), description: - typeof i.values?.description === 'string' ? i.values.description : undefined, + typeof i.values?.description === 'string' + ? i.values.description + : undefined, framework: Array.isArray(i.values?.framework) ? (i.values!.framework as Array) : [], @@ -55,7 +57,9 @@ function countBy(hits: Array, pick: (h: Hit) => Array) { const counts = new Map() for (const h of hits) for (const v of pick(h)) counts.set(v, (counts.get(v) ?? 0) + 1) - return [...counts.entries()].sort((a, b) => b[1] - a[1] || a[0].localeCompare(b[0])) + return [...counts.entries()].sort( + (a, b) => b[1] - a[1] || a[0].localeCompare(b[0]), + ) } function FacetGroup({ @@ -120,14 +124,21 @@ function SearchPage() { [hits], ) - function toggle(set: Set, setter: (s: Set) => void, v: string) { + function toggle( + set: Set, + setter: (s: Set) => void, + v: string, + ) { const next = new Set(set) next.has(v) ? next.delete(v) : next.add(v) setter(next) } return ( - +
{ e.preventDefault() diff --git a/app/docs-preview/tests/read-only.test.ts b/app/docs-preview/tests/read-only.test.ts index b01b7f07..8ce323b2 100644 --- a/app/docs-preview/tests/read-only.test.ts +++ b/app/docs-preview/tests/read-only.test.ts @@ -44,8 +44,12 @@ function runIngest() { encoding: 'utf8', }) expect(res.status, res.stderr).toBe(0) - const report = JSON.parse(readFileSync(path.join(out, 'ingest-report.json'), 'utf8')) - const cmsExport = JSON.parse(readFileSync(path.join(out, 'cms-export.json'), 'utf8')) + const report = JSON.parse( + readFileSync(path.join(out, 'ingest-report.json'), 'utf8'), + ) + const cmsExport = JSON.parse( + readFileSync(path.join(out, 'cms-export.json'), 'utf8'), + ) const nav = JSON.parse(readFileSync(path.join(out, 'nav.json'), 'utf8')) return { report, cmsExport, nav } } @@ -76,7 +80,9 @@ describe('preview-mode contract', () => { it('builds the sidebar from config.json order', () => { const { nav } = runIngest() - const start = nav.sections.find((s: { label: string }) => s.label === 'Start') + const start = nav.sections.find( + (s: { label: string }) => s.label === 'Start', + ) expect(start).toBeTruthy() expect(start.pages.map((p: { slug: string }) => p.slug)).toEqual([ 'overview', diff --git a/app/prm/bakeoff/README.md b/app/prm/bakeoff/README.md index 48f2699a..2ee1e367 100644 --- a/app/prm/bakeoff/README.md +++ b/app/prm/bakeoff/README.md @@ -5,15 +5,15 @@ - **Exa avg fact recall:** 100.0% · **Primary-domain hits:** 11/50 - **Tavily avg fact recall:** 67.5% · **Primary-domain hits:** 11/50 -| Subject | Exa | Tavily | Top Exa Source | -|---|---|---|---| -| Sunil Pai | 100% (2 primary) | 100% (2 primary) | `https://sunilpai.dev/about` | -| Kent C. Dodds | 100% (1 primary) | 75% (1 primary) | `https://github.com/kentcdodds` | +| Subject | Exa | Tavily | Top Exa Source | +| --------------- | ---------------- | ---------------- | ----------------------------------- | +| Sunil Pai | 100% (2 primary) | 100% (2 primary) | `https://sunilpai.dev/about` | +| Kent C. Dodds | 100% (1 primary) | 75% (1 primary) | `https://github.com/kentcdodds` | | David Khourshid | 100% (1 primary) | 100% (1 primary) | `https://github.com/davidkhourshid` | -| Victor Savkin | 100% (1 primary) | 67% (1 primary) | `https://github.com/victorsavkin` | -| Tanner Linsley | 100% (1 primary) | 67% (1 primary) | `https://github.com/tannerlinsley` | -| Eugene Sergueev | 100% (1 primary) | 67% (1 primary) | `https://github.com/eugenesergueev` | -| Dominik Kundel | 100% (1 primary) | 50% (1 primary) | `https://github.com/dominikkundel` | -| Maya Shavin | 100% (1 primary) | 50% (1 primary) | `https://github.com/mayashavin` | -| Kiriti Badam | 100% (1 primary) | 50% (1 primary) | `https://github.com/kiritibadam` | -| Sachin Malhotra | 100% (1 primary) | 50% (1 primary) | `https://github.com/sachinmalhotra` | +| Victor Savkin | 100% (1 primary) | 67% (1 primary) | `https://github.com/victorsavkin` | +| Tanner Linsley | 100% (1 primary) | 67% (1 primary) | `https://github.com/tannerlinsley` | +| Eugene Sergueev | 100% (1 primary) | 67% (1 primary) | `https://github.com/eugenesergueev` | +| Dominik Kundel | 100% (1 primary) | 50% (1 primary) | `https://github.com/dominikkundel` | +| Maya Shavin | 100% (1 primary) | 50% (1 primary) | `https://github.com/mayashavin` | +| Kiriti Badam | 100% (1 primary) | 50% (1 primary) | `https://github.com/kiritibadam` | +| Sachin Malhotra | 100% (1 primary) | 50% (1 primary) | `https://github.com/sachinmalhotra` | diff --git a/app/prm/bakeoff/latest.json b/app/prm/bakeoff/latest.json index 377319f5..bdc0dcea 100644 --- a/app/prm/bakeoff/latest.json +++ b/app/prm/bakeoff/latest.json @@ -20,12 +20,7 @@ "allowedUrlRate": 1, "primaryIdentityHits": 2, "factRecallRate": 1, - "matchedFacts": [ - "cloudflare", - "partykit", - "react", - "glamor" - ], + "matchedFacts": ["cloudflare", "partykit", "react", "glamor"], "sampleUrls": [ "https://sunilpai.dev/about", "https://kentcdodds.com/chats/01/20/sunil-pai" @@ -38,12 +33,7 @@ "allowedUrlRate": 1, "primaryIdentityHits": 2, "factRecallRate": 1, - "matchedFacts": [ - "cloudflare", - "partykit", - "react", - "glamor" - ], + "matchedFacts": ["cloudflare", "partykit", "react", "glamor"], "sampleUrls": [ "https://sunilpai.dev/about", "https://kentcdodds.com/chats/01/20/sunil-pai" @@ -59,15 +49,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 1, - "matchedFacts": [ - "epicweb", - "testing", - "kody", - "react" - ], - "sampleUrls": [ - "https://github.com/kentcdodds" - ] + "matchedFacts": ["epicweb", "testing", "kody", "react"], + "sampleUrls": ["https://github.com/kentcdodds"] }, "tavily": { "name": "Kent C. Dodds", @@ -76,14 +59,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 0.75, - "matchedFacts": [ - "epicweb", - "testing", - "kody" - ], - "sampleUrls": [ - "https://github.com/kentcdodds" - ] + "matchedFacts": ["epicweb", "testing", "kody"], + "sampleUrls": ["https://github.com/kentcdodds"] } }, { @@ -95,14 +72,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 1, - "matchedFacts": [ - "stately", - "xstate", - "state" - ], - "sampleUrls": [ - "https://github.com/davidkhourshid" - ] + "matchedFacts": ["stately", "xstate", "state"], + "sampleUrls": ["https://github.com/davidkhourshid"] }, "tavily": { "name": "David Khourshid", @@ -111,14 +82,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 1, - "matchedFacts": [ - "stately", - "xstate", - "state" - ], - "sampleUrls": [ - "https://github.com/davidkhourshid" - ] + "matchedFacts": ["stately", "xstate", "state"], + "sampleUrls": ["https://github.com/davidkhourshid"] } }, { @@ -130,14 +95,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 1, - "matchedFacts": [ - "nx", - "nrwl", - "monorepo" - ], - "sampleUrls": [ - "https://github.com/victorsavkin" - ] + "matchedFacts": ["nx", "nrwl", "monorepo"], + "sampleUrls": ["https://github.com/victorsavkin"] }, "tavily": { "name": "Victor Savkin", @@ -146,13 +105,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 0.6666666666666666, - "matchedFacts": [ - "nx", - "nrwl" - ], - "sampleUrls": [ - "https://github.com/victorsavkin" - ] + "matchedFacts": ["nx", "nrwl"], + "sampleUrls": ["https://github.com/victorsavkin"] } }, { @@ -164,14 +118,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 1, - "matchedFacts": [ - "tanstack", - "query", - "router" - ], - "sampleUrls": [ - "https://github.com/tannerlinsley" - ] + "matchedFacts": ["tanstack", "query", "router"], + "sampleUrls": ["https://github.com/tannerlinsley"] }, "tavily": { "name": "Tanner Linsley", @@ -180,13 +128,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 0.6666666666666666, - "matchedFacts": [ - "tanstack", - "query" - ], - "sampleUrls": [ - "https://github.com/tannerlinsley" - ] + "matchedFacts": ["tanstack", "query"], + "sampleUrls": ["https://github.com/tannerlinsley"] } }, { @@ -198,14 +141,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 1, - "matchedFacts": [ - "flo", - "ai", - "agent" - ], - "sampleUrls": [ - "https://github.com/eugenesergueev" - ] + "matchedFacts": ["flo", "ai", "agent"], + "sampleUrls": ["https://github.com/eugenesergueev"] }, "tavily": { "name": "Eugene Sergueev", @@ -214,13 +151,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 0.6666666666666666, - "matchedFacts": [ - "flo", - "ai" - ], - "sampleUrls": [ - "https://github.com/eugenesergueev" - ] + "matchedFacts": ["flo", "ai"], + "sampleUrls": ["https://github.com/eugenesergueev"] } }, { @@ -232,13 +164,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 1, - "matchedFacts": [ - "developer", - "experience" - ], - "sampleUrls": [ - "https://github.com/dominikkundel" - ] + "matchedFacts": ["developer", "experience"], + "sampleUrls": ["https://github.com/dominikkundel"] }, "tavily": { "name": "Dominik Kundel", @@ -247,12 +174,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 0.5, - "matchedFacts": [ - "developer" - ], - "sampleUrls": [ - "https://github.com/dominikkundel" - ] + "matchedFacts": ["developer"], + "sampleUrls": ["https://github.com/dominikkundel"] } }, { @@ -264,13 +187,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 1, - "matchedFacts": [ - "frontend", - "accessibility" - ], - "sampleUrls": [ - "https://github.com/mayashavin" - ] + "matchedFacts": ["frontend", "accessibility"], + "sampleUrls": ["https://github.com/mayashavin"] }, "tavily": { "name": "Maya Shavin", @@ -279,12 +197,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 0.5, - "matchedFacts": [ - "frontend" - ], - "sampleUrls": [ - "https://github.com/mayashavin" - ] + "matchedFacts": ["frontend"], + "sampleUrls": ["https://github.com/mayashavin"] } }, { @@ -296,13 +210,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 1, - "matchedFacts": [ - "runtime", - "ai" - ], - "sampleUrls": [ - "https://github.com/kiritibadam" - ] + "matchedFacts": ["runtime", "ai"], + "sampleUrls": ["https://github.com/kiritibadam"] }, "tavily": { "name": "Kiriti Badam", @@ -311,12 +220,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 0.5, - "matchedFacts": [ - "runtime" - ], - "sampleUrls": [ - "https://github.com/kiritibadam" - ] + "matchedFacts": ["runtime"], + "sampleUrls": ["https://github.com/kiritibadam"] } }, { @@ -328,13 +233,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 1, - "matchedFacts": [ - "observability", - "telemetry" - ], - "sampleUrls": [ - "https://github.com/sachinmalhotra" - ] + "matchedFacts": ["observability", "telemetry"], + "sampleUrls": ["https://github.com/sachinmalhotra"] }, "tavily": { "name": "Sachin Malhotra", @@ -343,12 +243,8 @@ "allowedUrlRate": 1, "primaryIdentityHits": 1, "factRecallRate": 0.5, - "matchedFacts": [ - "observability" - ], - "sampleUrls": [ - "https://github.com/sachinmalhotra" - ] + "matchedFacts": ["observability"], + "sampleUrls": ["https://github.com/sachinmalhotra"] } } ] diff --git a/examples/wp-vs-tanstack/ADMIN-GAP-ANALYSIS.md b/examples/wp-vs-tanstack/ADMIN-GAP-ANALYSIS.md index 66fac234..4f072db6 100644 --- a/examples/wp-vs-tanstack/ADMIN-GAP-ANALYSIS.md +++ b/examples/wp-vs-tanstack/ADMIN-GAP-ANALYSIS.md @@ -1,6 +1,6 @@ # Admin feature gaps — wp-admin vs TanStack CMS (Pass 2) -Pass 1 asked whether TanStack CMS can reproduce a fixed WordPress *design* in +Pass 1 asked whether TanStack CMS can reproduce a fixed WordPress _design_ in userland (it can). Pass 2 asks the authoring question: walk the **admin** of both builds of Summit Home Services and answer two things. @@ -35,7 +35,7 @@ Before the matrix, the one structural difference that colors everything else: th Layout and theme are code (`theme.tokens`, renderers), not an admin screen. Neither is strictly richer; they optimize for different things. Gutenberg optimizes -for *see-what-you-get* page building. TanStack optimizes for a *typed content model* +for _see-what-you-get_ page building. TanStack optimizes for a _typed content model_ that the same blocks render on the site, plus governance (review queue), AI/MCP, and per-field access. That trade shows up all through the matrix below. @@ -45,34 +45,34 @@ Status legend: **EXISTS** (shipped admin screen) · **PARTIAL** (present but thi than WP, or config-only) · **UI-GAP** (the engine exists in core, no stock screen surfaces it) · **MISSING** (no engine, no screen). -| wp-admin capability | TanStack CMS | Backing / note | -| --- | --- | --- | -| Dashboard / landing (At a Glance, Activity, Site Health) | **UI-GAP** | Bare `/cms` 404s; no landing. Counts/activity data exist (revisions, events). | -| Posts/Pages list (search, filter, sort, bulk, columns) | **EXISTS** | `/cms/content`; status tabs, search, configurable Columns, per-collection sections. | -| Content editor | **EXISTS** | `/cms/edit/$collection/$id`; field form + block list, 19 field widgets. | -| Scheduling (publish date) | **EXISTS** (ahead) | Inline `publishAt` **and** `unpublishAt` in the sidebar. | -| Revisions / restore | **EXISTS** (ahead) | Revisions panel with restore; WP revisions are per-post only. | -| Draft + review/approval workflow | **EXISTS** (ahead) | Review queue; WP has no native approval step. | -| Categories / Tags (hierarchical, usage counts) | **PARTIAL** | Relation/select fields; no term manager with counts (`schema.ts`). | -| Media Library (grid, upload, bulk, alt text) | **UI-GAP** | Core has an `asset` collection + media adapters + inline picker (`assets.ts`), but no dedicated gallery/manager screen. This example configures no assets, so there's no media route at all. | -| Comments — public + moderation (spam/approve/trash) | **MISSING** | Core comments are **editorial** (on documents, for reviewers), not public. No spam queue (`ops.ts add_comment`). | -| Menus / navigation builder (drag-order, locations) | **MISSING** | No menu primitive or editor; nav is hardcoded in `siteNav` (userland config). | -| Appearance → Customize (logo, colors, fonts, live preview) | **MISSING** | Theme is code (`theme.tokens`, `theme.fontLinks`); no branding screen. | -| Widgets | **N/A** | Block model; no widget areas. | -| Plugins — install/activate UI | **PARTIAL (by design)** | Plugins are code (`plugins: [...]`), no marketplace/installer UI. | -| Users — list, add, roles | **PARTIAL** | Settings maps identity→role and issues API keys; DB-user CRUD exists in core but isn't surfaced here. | -| Roles & permissions | **EXISTS** (ahead) | 4 roles + custom + collection + **field-level** access (`lib/access.ts`). | -| API keys for agents/integrations | **EXISTS** (ahead) | Per-key role + collection scope (Settings); WP has nothing equivalent. | -| Tools → Import / Export | **PARTIAL** | CLI `tanstack-cms import/export` + `@tanstack/cms-migrate-wp` engine; no admin screen. | -| Tools → Site Health / diagnostics | **MISSING** | No diagnostics panel. | -| Settings — General/Reading/Permalinks/Discussion | **PARTIAL** | Site config is code; Settings screen covers keys/access/activity only. | -| Permalinks / slugs / redirects | **EXISTS** (ahead) | `slug` fields, locators, `redirectsCollection`; a Redirects collection ships here. | -| SEO (title/description/OG/JSON-LD) | **EXISTS** (ahead) | Built in: `seoField`, `cmsHead`, `cmsJsonLd` (`lib/seo.ts`); stock WP needs a plugin. | -| Contact form builder | **MISSING** (UI) | No form designer; forms are a public route writing to a collection. | -| Contact form **entries** inbox | **PARTIAL (ahead here)** | This example stores leads in a **Contact Inquiries** collection; the WP install stores **nothing** (CF7 needs Flamingo). No dedicated inbox screen, but entries are browsable. | -| AI authoring agent | **EXISTS** (ahead) | `/cms/agent` + MCP/WebMCP (hidden here, AI not configured); WP has none. | -| Activity / audit log | **EXISTS** | Settings activity log + review audit trail. | -| User profile / preferences | **MISSING** | Only a theme toggle; no profile screen. | +| wp-admin capability | TanStack CMS | Backing / note | +| ---------------------------------------------------------- | ------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| Dashboard / landing (At a Glance, Activity, Site Health) | **UI-GAP** | Bare `/cms` 404s; no landing. Counts/activity data exist (revisions, events). | +| Posts/Pages list (search, filter, sort, bulk, columns) | **EXISTS** | `/cms/content`; status tabs, search, configurable Columns, per-collection sections. | +| Content editor | **EXISTS** | `/cms/edit/$collection/$id`; field form + block list, 19 field widgets. | +| Scheduling (publish date) | **EXISTS** (ahead) | Inline `publishAt` **and** `unpublishAt` in the sidebar. | +| Revisions / restore | **EXISTS** (ahead) | Revisions panel with restore; WP revisions are per-post only. | +| Draft + review/approval workflow | **EXISTS** (ahead) | Review queue; WP has no native approval step. | +| Categories / Tags (hierarchical, usage counts) | **PARTIAL** | Relation/select fields; no term manager with counts (`schema.ts`). | +| Media Library (grid, upload, bulk, alt text) | **UI-GAP** | Core has an `asset` collection + media adapters + inline picker (`assets.ts`), but no dedicated gallery/manager screen. This example configures no assets, so there's no media route at all. | +| Comments — public + moderation (spam/approve/trash) | **MISSING** | Core comments are **editorial** (on documents, for reviewers), not public. No spam queue (`ops.ts add_comment`). | +| Menus / navigation builder (drag-order, locations) | **MISSING** | No menu primitive or editor; nav is hardcoded in `siteNav` (userland config). | +| Appearance → Customize (logo, colors, fonts, live preview) | **MISSING** | Theme is code (`theme.tokens`, `theme.fontLinks`); no branding screen. | +| Widgets | **N/A** | Block model; no widget areas. | +| Plugins — install/activate UI | **PARTIAL (by design)** | Plugins are code (`plugins: [...]`), no marketplace/installer UI. | +| Users — list, add, roles | **PARTIAL** | Settings maps identity→role and issues API keys; DB-user CRUD exists in core but isn't surfaced here. | +| Roles & permissions | **EXISTS** (ahead) | 4 roles + custom + collection + **field-level** access (`lib/access.ts`). | +| API keys for agents/integrations | **EXISTS** (ahead) | Per-key role + collection scope (Settings); WP has nothing equivalent. | +| Tools → Import / Export | **PARTIAL** | CLI `tanstack-cms import/export` + `@tanstack/cms-migrate-wp` engine; no admin screen. | +| Tools → Site Health / diagnostics | **MISSING** | No diagnostics panel. | +| Settings — General/Reading/Permalinks/Discussion | **PARTIAL** | Site config is code; Settings screen covers keys/access/activity only. | +| Permalinks / slugs / redirects | **EXISTS** (ahead) | `slug` fields, locators, `redirectsCollection`; a Redirects collection ships here. | +| SEO (title/description/OG/JSON-LD) | **EXISTS** (ahead) | Built in: `seoField`, `cmsHead`, `cmsJsonLd` (`lib/seo.ts`); stock WP needs a plugin. | +| Contact form builder | **MISSING** (UI) | No form designer; forms are a public route writing to a collection. | +| Contact form **entries** inbox | **PARTIAL (ahead here)** | This example stores leads in a **Contact Inquiries** collection; the WP install stores **nothing** (CF7 needs Flamingo). No dedicated inbox screen, but entries are browsable. | +| AI authoring agent | **EXISTS** (ahead) | `/cms/agent` + MCP/WebMCP (hidden here, AI not configured); WP has none. | +| Activity / audit log | **EXISTS** | Settings activity log + review audit trail. | +| User profile / preferences | **MISSING** | Only a theme toggle; no profile screen. | ## 3. Where TanStack already leads @@ -88,6 +88,7 @@ and automation. ## 4. The gaps, grouped ### A. UI gaps — the engine exists, the stock admin doesn't surface it + 1. **Dashboard / landing.** `/cms` should greet you, not 404. 2. **Media Library browser.** The `asset` collection and media adapters exist; there's no grid-style browse/manage screen with upload and bulk actions. @@ -100,6 +101,7 @@ and automation. config instead of code (optional — many teams are happy leaving this in code). ### B. Genuinely absent — no engine primitive today + 5. **Menus / navigation as editable data.** No menu collection, ordering primitive, or editor. Nav is hardcoded per app. 6. **Public comments + moderation.** Editorial comments only; no public comments, @@ -110,7 +112,8 @@ and automation. 9. **Site Health / diagnostics.** Adapter connectivity, pending migrations, env. 10. **User profile / preferences screen.** -### C. WordPress-flavored compatibility — only relevant when coming *from* WP +### C. WordPress-flavored compatibility — only relevant when coming _from_ WP + 11. **WP import wizard** (admin UI over the existing migrate engine). 12. **CF7/Flamingo-style form builder + entries inbox.** 13. **Shortcode / Gutenberg-block ingestion** (migrate fidelity). @@ -136,25 +139,25 @@ and custom admin screens are built from the public `@tanstack/cms-ui-react/tools So the split is: **core gets the universal admin screens whose engine already exists; a WP-compat library gets the WordPress-shaped features.** -| # | Gap | Where | Why / how | -| --- | --- | --- | --- | -| 1 | Dashboard / landing | **CORE** | Universal; add an index route in `cms-ui-react` over existing counts/events. | -| 2 | Media Library browser | **CORE** | `asset` collection already backs it (`assets.ts`); needs a gallery screen. | -| 3 | Bulk-ops UI | **CORE — ✅ already shipped** | `BulkBar` already wires row selection to `bulkDocuments` (publish/unpublish/delete/restore/purge) in the content list. | -| 4 | Site-settings screen | **CORE (optional)** | A `siteSettings` singleton helper + screen; low priority. | -| 5 | Menus / navigation | **CORE helper + lib UI** | Ship a `navigationCollection()` authoring helper (like `redirectsCollection`); WP menu-location mapping lives in the lib. | -| 6 | Public comments + moderation | **LIBRARY** | Not universal (headless/marketing sites skip it). Plugin: comments collection + moderation `adminRoutes` + spam hook. | -| 7 | Taxonomy manager | **LIBRARY** (core helper optional) | Build on relation collections; counts/hierarchy UI as a plugin screen. | -| 8 | Theme / branding editor | **CORE (optional)** | A theme singleton + screen writing `theme.tokens`; or leave in code. | -| 9 | Site Health / diagnostics | **CORE (optional)** | Reads adapter/env state; low priority. | -| 10 | Profile / preferences | **CORE** | Small screen over the existing session/auth contract. | -| 11 | WP import wizard | **LIBRARY** | Add `adminNav` + `adminRoutes` over `cms-migrate-wp`. | -| 12 | Form builder + entries inbox | **LIBRARY** | Plugin: form-def collection + submissions collection + inbox `adminRoute` + spam `op`. The `forms-lead-capture` skill is the seed. | -| 13 | Shortcode / Gutenberg ingestion | **LIBRARY** | Part of `cms-migrate-wp` (shortcode→block, block-delimiter parse). | -| 14 | Old-WP-URL redirects | **LIBRARY** | Generate into the core `redirectsCollection` from WP permalink structure on import. | -| 15 | WP comment import | **LIBRARY** | Maps into the comments plugin (#6). | - -The core list is short on purpose: it's only the *universal* screens (dashboard, +| # | Gap | Where | Why / how | +| --- | ------------------------------- | ---------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| 1 | Dashboard / landing | **CORE** | Universal; add an index route in `cms-ui-react` over existing counts/events. | +| 2 | Media Library browser | **CORE** | `asset` collection already backs it (`assets.ts`); needs a gallery screen. | +| 3 | Bulk-ops UI | **CORE — ✅ already shipped** | `BulkBar` already wires row selection to `bulkDocuments` (publish/unpublish/delete/restore/purge) in the content list. | +| 4 | Site-settings screen | **CORE (optional)** | A `siteSettings` singleton helper + screen; low priority. | +| 5 | Menus / navigation | **CORE helper + lib UI** | Ship a `navigationCollection()` authoring helper (like `redirectsCollection`); WP menu-location mapping lives in the lib. | +| 6 | Public comments + moderation | **LIBRARY** | Not universal (headless/marketing sites skip it). Plugin: comments collection + moderation `adminRoutes` + spam hook. | +| 7 | Taxonomy manager | **LIBRARY** (core helper optional) | Build on relation collections; counts/hierarchy UI as a plugin screen. | +| 8 | Theme / branding editor | **CORE (optional)** | A theme singleton + screen writing `theme.tokens`; or leave in code. | +| 9 | Site Health / diagnostics | **CORE (optional)** | Reads adapter/env state; low priority. | +| 10 | Profile / preferences | **CORE** | Small screen over the existing session/auth contract. | +| 11 | WP import wizard | **LIBRARY** | Add `adminNav` + `adminRoutes` over `cms-migrate-wp`. | +| 12 | Form builder + entries inbox | **LIBRARY** | Plugin: form-def collection + submissions collection + inbox `adminRoute` + spam `op`. The `forms-lead-capture` skill is the seed. | +| 13 | Shortcode / Gutenberg ingestion | **LIBRARY** | Part of `cms-migrate-wp` (shortcode→block, block-delimiter parse). | +| 14 | Old-WP-URL redirects | **LIBRARY** | Generate into the core `redirectsCollection` from WP permalink structure on import. | +| 15 | WP comment import | **LIBRARY** | Maps into the comments plugin (#6). | + +The core list is short on purpose: it's only the _universal_ screens (dashboard, media, bulk-ops, profile) where the data layer is already built and the stock admin simply doesn't draw the screen yet. Everything WordPress-specific stays a plugin. @@ -189,6 +192,6 @@ WP-compatibility is a plugin problem, not a core problem. --- -*Method: live read-only walkthrough of both admins (WordPress 7.1.4 + Astra + CF7 at +_Method: live read-only walkthrough of both admins (WordPress 7.1.4 + Astra + CF7 at `:8080`, TanStack CMS at `:3020`), cross-checked against `packages/*`. WordPress was -not modified. See [`COMPARISON.md`](./COMPARISON.md) for Pass 1 (design parity).* +not modified. See [`COMPARISON.md`](./COMPARISON.md) for Pass 1 (design parity)._ diff --git a/examples/wp-vs-tanstack/COMPARISON.md b/examples/wp-vs-tanstack/COMPARISON.md index 3b8dfc02..36162262 100644 --- a/examples/wp-vs-tanstack/COMPARISON.md +++ b/examples/wp-vs-tanstack/COMPARISON.md @@ -14,7 +14,7 @@ is outlined at the end and not yet run. ### The question Earlier versions of this comparison were circular: the two sites were tuned to -the *same* hand-picked palette at the same time, so "they match" proved little. +the _same_ hand-picked palette at the same time, so "they match" proved little. This pass fixes that with a cleaner experiment: 1. **WordPress is the fixed reference.** It's a realistic small-business Astra @@ -33,16 +33,16 @@ This pass fixes that with a cleaner experiment: Measured with the browser's computed styles, both sites at the **same desktop width**, element by element: -| Element | WordPress | TanStack CMS | -| --- | --- | --- | -| Body | 16px / 1.65, Inter, `#475569` | 16px / 1.65, Inter, `#475569` | -| Headings | Poppins, `#0f172a` | Poppins, `#0f172a` | -| Logo | 26px / 600, Poppins, `#1e293b` | 26px / 600, Poppins, `#1e293b` | -| Nav link (active) | 16px / 400, Inter, `#045cb4` | 16px / 400, Inter, `#045cb4` | -| Hero H1 | 54px / 800, Poppins, lh 75.6 | 54px / 800, Poppins, lh 75.6 | -| Hero subheading | 20px, Inter, `#c7d2fe` | 20px, Inter, `#c7d2fe` | -| "What We Do" | 36px / 800, Poppins, `#0f172a` | 36px / 800, Poppins, `#0f172a` | -| Hero buttons | orange fill / blue, radius 4px | orange fill / blue, radius 4px | +| Element | WordPress | TanStack CMS | +| ----------------- | ------------------------------ | ------------------------------ | +| Body | 16px / 1.65, Inter, `#475569` | 16px / 1.65, Inter, `#475569` | +| Headings | Poppins, `#0f172a` | Poppins, `#0f172a` | +| Logo | 26px / 600, Poppins, `#1e293b` | 26px / 600, Poppins, `#1e293b` | +| Nav link (active) | 16px / 400, Inter, `#045cb4` | 16px / 400, Inter, `#045cb4` | +| Hero H1 | 54px / 800, Poppins, lh 75.6 | 54px / 800, Poppins, lh 75.6 | +| Hero subheading | 20px, Inter, `#c7d2fe` | 20px, Inter, `#c7d2fe` | +| "What We Do" | 36px / 800, Poppins, `#0f172a` | 36px / 800, Poppins, `#0f172a` | +| Hero buttons | orange fill / blue, radius 4px | orange fill / blue, radius 4px | Every page is reproduced with the same content and structure: Home, Services, About, Reviews, Contact (CF7 lead form on WP, a native form on TanStack), and a @@ -70,12 +70,12 @@ The two stacks have different responsive systems, so matching one width is not enough; the column counts have to switch at the same widths too. WordPress and Tailwind disagree by default: -| Width | Gutenberg columns | Tailwind `sm:`/`lg:` grid | -| --- | --- | --- | -| ≥1024px | all in one row | all in one row | -| 782–1023px | **all in one row** | **2-up** | -| 640–781px | **one column** | **2-up** | -| <640px | one column | one column | +| Width | Gutenberg columns | Tailwind `sm:`/`lg:` grid | +| ---------- | ------------------ | ------------------------- | +| ≥1024px | all in one row | all in one row | +| 782–1023px | **all in one row** | **2-up** | +| 640–781px | **one column** | **2-up** | +| <640px | one column | one column | A `wp-block-columns` stacks at a single breakpoint (`≤781px` → one column, `≥782px` → N across); there is no 2-up middle state. The renderers mirror that @@ -120,12 +120,12 @@ didn't change, so the shape holds, but re-measure after the redesign for exact numbers (both sites now also load the same two Google web fonts, which narrows the first-load-bytes gap). -| Metric | WordPress | TanStack CMS | Winner | -| --- | --- | --- | --- | -| TTFB (server render) | 71 ms | **20 ms** | TanStack | -| First Contentful Paint | 120 ms | **68 ms** | TanStack | -| DOM nodes | 193 | **98** | TanStack (half) | -| First-load transfer | **~44 KB** | ~160–185 KB (gzip/brotli) | WordPress | +| Metric | WordPress | TanStack CMS | Winner | +| ---------------------- | ---------- | ------------------------- | --------------- | +| TTFB (server render) | 71 ms | **20 ms** | TanStack | +| First Contentful Paint | 120 ms | **68 ms** | TanStack | +| DOM nodes | 193 | **98** | TanStack (half) | +| First-load transfer | **~44 KB** | ~160–185 KB (gzip/brotli) | WordPress | Reading it honestly: TanStack wins time-to-first-byte, first paint, and DOM weight; WordPress ships fewer first-load bytes because this is a deliberately @@ -148,9 +148,16 @@ pnpm --filter wp-vs-tanstack dev Measure computed styles in a page's console, both sites at the same width: ```js -const el = [...document.querySelectorAll('*')].find(e => e.textContent.trim() === 'What We Do') +const el = [...document.querySelectorAll('*')].find( + (e) => e.textContent.trim() === 'What We Do', +) const s = getComputedStyle(el) -;({ font: s.fontFamily, size: s.fontSize, weight: s.fontWeight, color: s.color }) +;({ + font: s.fontFamily, + size: s.fontSize, + weight: s.fontWeight, + color: s.color, +}) ``` #### Prod build note @@ -179,7 +186,7 @@ versus a **WordPress-compatibility library**. See [`ADMIN-GAP-ANALYSIS.md`](./ADMIN-GAP-ANALYSIS.md) for the full feature matrix and the core-vs-library recommendation. Short answer: the TanStack admin is ahead on governance (review queue, revisions, field-level roles, scheduling, AI/MCP), and -the wp-admin features it lacks are either a few *universal* screens whose engines -already exist (dashboard, media library, bulk-ops — core) or *WordPress-shaped* +the wp-admin features it lacks are either a few _universal_ screens whose engines +already exist (dashboard, media library, bulk-ops — core) or _WordPress-shaped_ features (menus, public comments, CF7 entries, importer) that fit a companion plugin without touching `packages/*`. diff --git a/examples/wp-vs-tanstack/src/cms.config.ts b/examples/wp-vs-tanstack/src/cms.config.ts index e862e5c0..6f925919 100644 --- a/examples/wp-vs-tanstack/src/cms.config.ts +++ b/examples/wp-vs-tanstack/src/cms.config.ts @@ -18,8 +18,18 @@ const blockTypes = [ { name: 'badge', label: 'Eyebrow / Badge', type: 'text' }, { name: 'heading', label: 'Heading', type: 'text', required: true }, { name: 'subheading', label: 'Subheading', type: 'textarea' }, - { name: 'minHeight', label: 'Min Height (px)', type: 'number', defaultValue: 320 }, - { name: 'headingSize', label: 'Heading Size (px)', type: 'number', defaultValue: 48 }, + { + name: 'minHeight', + label: 'Min Height (px)', + type: 'number', + defaultValue: 320, + }, + { + name: 'headingSize', + label: 'Heading Size (px)', + type: 'number', + defaultValue: 48, + }, { name: 'primaryLabel', label: 'Primary Button Label', type: 'text' }, { name: 'primaryHref', label: 'Primary Button Link', type: 'text' }, { name: 'secondaryLabel', label: 'Secondary Button Label', type: 'text' }, @@ -97,7 +107,12 @@ const blockTypes = [ fields: [ { name: 'heading', label: 'Heading', type: 'text' }, { name: 'intro', label: 'Intro', type: 'textarea' }, - { name: 'bigTitles', label: 'Large card titles (h3)', type: 'boolean', defaultValue: false }, + { + name: 'bigTitles', + label: 'Large card titles (h3)', + type: 'boolean', + defaultValue: false, + }, { name: 'surface', label: 'Background', @@ -152,8 +167,18 @@ const blockTypes = [ ], defaultValue: 'plain', }, - { name: 'card', label: 'Show as cards', type: 'boolean', defaultValue: true }, - { name: 'titleSize', label: 'Card Title Size (px)', type: 'number', defaultValue: 22 }, + { + name: 'card', + label: 'Show as cards', + type: 'boolean', + defaultValue: true, + }, + { + name: 'titleSize', + label: 'Card Title Size (px)', + type: 'number', + defaultValue: 22, + }, { name: 'items', label: 'Items', @@ -322,8 +347,10 @@ export const cms = defineCms(definition, { 'accent-soft': '#ffedd5', 'header-bg': '#ffffff', radius: '0.75rem', - 'font-body': "'Inter', -apple-system, system-ui, 'Segoe UI', Roboto, sans-serif", - 'font-heading': "'Poppins', -apple-system, system-ui, 'Segoe UI', sans-serif", + 'font-body': + "'Inter', -apple-system, system-ui, 'Segoe UI', Roboto, sans-serif", + 'font-heading': + "'Poppins', -apple-system, system-ui, 'Segoe UI', sans-serif", 'page-width': '1240px', 'content-width': '46rem', }, diff --git a/examples/wp-vs-tanstack/src/cms.definition.ts b/examples/wp-vs-tanstack/src/cms.definition.ts index bdb28462..3a42efb8 100644 --- a/examples/wp-vs-tanstack/src/cms.definition.ts +++ b/examples/wp-vs-tanstack/src/cms.definition.ts @@ -43,7 +43,12 @@ export const definition = defineCmsDefinition({ { name: 'title', label: 'Page Title', type: 'text', required: true }, { name: 'slug', label: 'Slug', type: 'slug', from: 'title' }, { name: 'blocks', label: 'Sections', type: 'blocks' }, - { name: 'published', label: 'Published', type: 'boolean', defaultValue: true }, + { + name: 'published', + label: 'Published', + type: 'boolean', + defaultValue: true, + }, seoField(), ], }), @@ -63,7 +68,12 @@ export const definition = defineCmsDefinition({ { name: 'title', label: 'Title', type: 'text', required: true }, { name: 'slug', label: 'Slug', type: 'slug', from: 'title' }, { name: 'excerpt', label: 'Excerpt', type: 'textarea' }, - { name: 'author', label: 'Author', type: 'text', defaultValue: 'Summit Home Services' }, + { + name: 'author', + label: 'Author', + type: 'text', + defaultValue: 'Summit Home Services', + }, { name: 'body', label: 'Body', type: 'markdown' }, { name: 'category', @@ -76,7 +86,12 @@ export const definition = defineCmsDefinition({ ], }, { name: 'publishedAt', label: 'Published Date', type: 'date' }, - { name: 'published', label: 'Published', type: 'boolean', defaultValue: true }, + { + name: 'published', + label: 'Published', + type: 'boolean', + defaultValue: true, + }, ], }), diff --git a/examples/wp-vs-tanstack/src/cms.renderers.tsx b/examples/wp-vs-tanstack/src/cms.renderers.tsx index 874c8e52..d379e7ed 100644 --- a/examples/wp-vs-tanstack/src/cms.renderers.tsx +++ b/examples/wp-vs-tanstack/src/cms.renderers.tsx @@ -157,7 +157,14 @@ export function PageTitleBar({ title }: { title: string }) { {/* WP/Astra prints the page title flush under the header (0px above) with 24px below before the content starts; match that, not a roomier bar. */} -

+

{title}

@@ -175,7 +182,8 @@ function Hero({ block }: BlockRendererProps) { const secondaryLabel = str(b, 'secondaryLabel') // Match the WordPress/Astra cover: a fixed min-height with the content // vertically centered, 48px padding, and a fixed heading size per page. - const minHeight = typeof b.minHeight === 'number' ? (b.minHeight as number) : 320 + const minHeight = + typeof b.minHeight === 'number' ? (b.minHeight as number) : 320 const headingSize = typeof b.headingSize === 'number' ? (b.headingSize as number) : 48 return ( @@ -280,9 +288,14 @@ function StatBar({ block }: BlockRendererProps) {
{list.map((it, i) => ( -

+

{str(it, 'icon') && {str(it, 'icon')}} - {str(it, 'emphasis')}{' '} + + {str(it, 'emphasis')} + {' '} {str(it, 'label')}

))} @@ -296,7 +309,10 @@ function SectionIntro({ block }: BlockRendererProps) { const left = str(b, 'align') === 'left' const soft = str(b, 'surface') === 'soft' return ( -
+
{str(b, 'eyebrow') && (

)} {str(b, 'subheading') && ( -

+

{str(b, 'subheading')}

)} @@ -335,7 +353,10 @@ function ServiceSection({ block }: BlockRendererProps) { // rather than the h4/18px used for sub-service cards. const bigTitles = b.bigTitles === true return ( -
+
{str(b, 'heading') && (

)} {str(b, 'intro') && ( -

{str(b, 'intro')}

+

+ {str(b, 'intro')} +

)}
{cards.map((c, i) => { - const bullets = (Array.isArray(c.bullets) ? c.bullets : []) as Array< - Record - > + const bullets = ( + Array.isArray(c.bullets) ? c.bullets : [] + ) as Array> return (
{str(c, 'title')}

) : (

{str(c, 'title')}

)} {str(c, 'body') && ( -

{str(c, 'body')}

+

+ {str(c, 'body')} +

)} {bullets.length > 0 && (
    @@ -406,7 +439,8 @@ function FeatureGrid({ block }: BlockRendererProps) { ? 'grid-cols-1 min-[782px]:grid-cols-4' : 'grid-cols-1 min-[782px]:grid-cols-3' const ctaLabel = str(b, 'ctaLabel') - const titleSize = typeof b.titleSize === 'number' ? (b.titleSize as number) : 22 + const titleSize = + typeof b.titleSize === 'number' ? (b.titleSize as number) : 22 return (
    @@ -443,7 +477,11 @@ function FeatureGrid({ block }: BlockRendererProps) { >

    {str(it, 'icon') && {str(it, 'icon')}} {str(it, 'title')} @@ -499,7 +537,10 @@ function Testimonials({ block }: BlockRendererProps) {
    “{str(it, 'quote')}”
    -
    +
    {str(it, 'name')} {str(it, 'city') && ( @@ -523,7 +564,10 @@ function CtaBand({ block }: BlockRendererProps) { const label2 = str(b, 'button2Label') const btnBg = navy ? ACCENT : NAVY return ( -
    +

    -
    +
    +
    {str(b, 'heading') && ( -

    +

    {str(b, 'heading')}

    )} @@ -602,10 +654,15 @@ function ContactSplit({ block }: BlockRendererProps) { {str(b, 'formTitle', 'Send Us a Message')}

    {str(b, 'formIntro') && ( -

    {str(b, 'formIntro')}

    +

    + {str(b, 'formIntro')} +

    )} {sent ? ( -

    +

    Thanks! A real local person will get right back to you.

    ) : ( @@ -616,7 +673,10 @@ function ContactSplit({ block }: BlockRendererProps) { setSent(true) }} > -