@haruhimemoe/next-kit 0.9.0 → 0.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -6,6 +6,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [0.10.0] - 2026-10-05
10
+
11
+ ### Changed
12
+ - **Breaking.** `next-kit check`'s legal standard requires all five pages of the legal convention: `content/legal/{terms,privacy,your-privacy-rights,copyright,disclaimers}.mdx` (was terms and privacy only).
13
+
9
14
  ## [0.9.0] - 2026-10-05
10
15
 
11
16
  ### Added
@@ -104,7 +109,9 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
104
109
  - `@haruhimemoe/next-kit/auth-react`: `createSignedInMarker`, `createAccountStore`, `useAccount`, `createAccount`, `RestoreSignedIn` and `osuSignIn`.
105
110
  - `@haruhimemoe/next-kit/testing`: `startMemoryMongo`, `setupTestDb`, `setupMsw` and the fake osu! app env.
106
111
 
107
- [unreleased]: https://github.com/haruhimemoe/next-kit/compare/v0.8.0...HEAD
112
+ [unreleased]: https://github.com/haruhimemoe/next-kit/compare/v0.10.0...HEAD
113
+ [0.10.0]: https://github.com/haruhimemoe/next-kit/compare/v0.9.0...v0.10.0
114
+ [0.9.0]: https://github.com/haruhimemoe/next-kit/compare/v0.8.0...v0.9.0
108
115
  [0.8.0]: https://github.com/haruhimemoe/next-kit/compare/v0.7.0...v0.8.0
109
116
  [0.6.2]: https://github.com/haruhimemoe/next-kit/compare/v0.6.1...v0.6.2
110
117
  [0.6.1]: https://github.com/haruhimemoe/next-kit/compare/v0.6.0...v0.6.1
package/README.md CHANGED
@@ -228,7 +228,7 @@ Every app is checked against:
228
228
 
229
229
  - **crawl** (always): `robots.ts`, `sitemap.ts`, `llms.txt/route.ts`, `llms-full.txt/route.ts`, and `.well-known/security.txt/route.ts` (each also accepted as a route handler, like `robots.txt/route.ts`).
230
230
  - **brand** (always): `brand/page.tsx`.
231
- - **legal** (always): `legal/page.tsx`, `legal/[x]/page.tsx`, `legal/[x]/md/route.ts` (any dynamic segment name), and `content/legal/terms.mdx` plus `content/legal/privacy.mdx`.
231
+ - **legal** (always): `legal/page.tsx`, `legal/[x]/page.tsx`, `legal/[x]/md/route.ts` (any dynamic segment name), and the five legal convention pages: `content/legal/{terms,privacy,your-privacy-rights,copyright,disclaimers}.mdx`.
232
232
  - **docs**, once `src/app/api/v1` exists or any `content/docs` file does: `docs/page.tsx`, `docs/[x]/page.tsx`, `docs/[x]/md/route.ts`.
233
233
  - **guides**, only once a `content/guides` file exists: the same three files under `guides/`. An app with no guides is never asked for them.
234
234
  - **api**, once `src/app/api/v1` exists: `api/v1/me/route.ts`, `api/v1/openapi.json/route.ts`, `api/me/api-key/route.ts`, and `content/docs/api.mdx`.
@@ -2,14 +2,14 @@
2
2
  * @file src/check/standards.ts
3
3
  * @desc The routes and content files every haruhime app serves, checked against an app's route
4
4
  * file list (paths under src/app) and content file list (paths under content/). Crawl and
5
- * brand are always checked; legal always checks its three routes plus its two content
6
- * files; docs joins in once api/v1 exists or a content/docs file does; guides joins in
7
- * only once a content/guides file does; the API standard, once api/v1 exists, checks its
5
+ * brand are always checked; legal always checks its three routes plus the five pages of
6
+ * the legal convention (LEGAL_SLUGS); docs joins in once api/v1 exists or a content/docs
7
+ * file does; guides joins in only once a content/guides file does; the API standard, once api/v1 exists, checks its
8
8
  * three routes plus content/docs/api.mdx. Checks files only: the content registry itself
9
9
  * is never parsed.
10
10
  * @author David @dvhsh (https://dvh.sh)
11
11
  * @created Sat Oct 3, 2026
12
- * @modified Sun Oct 4, 2026
12
+ * @modified Mon Oct 5, 2026
13
13
  */
14
14
  /** One standard's outcome. `missing` entries carry their own prefix (src/app/... or content/...). */
15
15
  export type StandardResult = {
@@ -2,15 +2,16 @@
2
2
  * @file src/check/standards.ts
3
3
  * @desc The routes and content files every haruhime app serves, checked against an app's route
4
4
  * file list (paths under src/app) and content file list (paths under content/). Crawl and
5
- * brand are always checked; legal always checks its three routes plus its two content
6
- * files; docs joins in once api/v1 exists or a content/docs file does; guides joins in
7
- * only once a content/guides file does; the API standard, once api/v1 exists, checks its
5
+ * brand are always checked; legal always checks its three routes plus the five pages of
6
+ * the legal convention (LEGAL_SLUGS); docs joins in once api/v1 exists or a content/docs
7
+ * file does; guides joins in only once a content/guides file does; the API standard, once api/v1 exists, checks its
8
8
  * three routes plus content/docs/api.mdx. Checks files only: the content registry itself
9
9
  * is never parsed.
10
10
  * @author David @dvhsh (https://dvh.sh)
11
11
  * @created Sat Oct 3, 2026
12
- * @modified Sun Oct 4, 2026
12
+ * @modified Mon Oct 5, 2026
13
13
  */
14
+ import { LEGAL_SLUGS } from "../legal/types.js";
14
15
  /** A route under src/app, matched against any of `patterns`. */
15
16
  const route = (name, ...patterns) => ({
16
17
  missing: `src/app/${name}`,
@@ -37,8 +38,7 @@ const sectionRoutes = (section) => [
37
38
  ];
38
39
  const LEGAL = [
39
40
  ...sectionRoutes("legal"),
40
- content("legal/terms.mdx"),
41
- content("legal/privacy.mdx"),
41
+ ...LEGAL_SLUGS.map((slug) => content(`legal/${slug}.mdx`)),
42
42
  ];
43
43
  const DOCS = sectionRoutes("docs");
44
44
  const GUIDES = sectionRoutes("guides");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@haruhimemoe/next-kit",
3
- "version": "0.9.0",
3
+ "version": "0.10.0",
4
4
  "description": "The Next.js plumbing the haruhime.moe tools share: JSON route helpers, rate limits and budgets in MongoDB, bearer machine auth, zod env parsing, a connect-once MongoDB client with safe index builds, better-auth with osu! sign-in, the signed-in marker and account store for the browser, SEO: metadata, robots.txt, sitemaps, JSON-LD and llms.txt, and per-app API keys and the /api/v1 guard.",
5
5
  "keywords": [
6
6
  "nextjs",