From 33048b76029c54494c703ac679eebf142032a63a Mon Sep 17 00:00:00 2001 From: Your Name Date: Thu, 12 Mar 2026 14:44:12 +0800 Subject: [PATCH] feat: add public /riji app intro page --- app/riji/page.tsx | 150 +++++++++++++++++++++ proxy.ts | 11 +- riji/README.md | 36 +++++ riji/index.html | 333 ++++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 528 insertions(+), 2 deletions(-) create mode 100644 app/riji/page.tsx create mode 100644 riji/README.md create mode 100644 riji/index.html diff --git a/app/riji/page.tsx b/app/riji/page.tsx new file mode 100644 index 000000000..3505b0493 --- /dev/null +++ b/app/riji/page.tsx @@ -0,0 +1,150 @@ +import type { Metadata } from "next"; + +export const metadata: Metadata = { + title: "RiJi — Offline Journal & Private Notes", + description: + "RiJi is an offline-first journal and notes app that helps you record moments, thoughts, photos, and videos — privately and beautifully.", + openGraph: { + title: "RiJi — Offline Journal & Private Notes", + description: + "Capture your day, anytime. Offline-first journaling with private notes, photos & videos, and encrypted backups.", + }, +}; + +export default function RiJiIntroPage() { + return ( +
+
+
+
+ +
+ +
+

+ Page Title +

+

+ Capture your day, anytime. +

+

+ RiJi is an offline-first journal and notes app that helps you record moments, thoughts, + photos, and videos — privately and beautifully. +

+
+ +
+

+ Primary Highlights +

+
+ + + + + +
+
+ +
+

About

+
+

+ RiJi is designed for people who want a clean, private, and distraction-free place to + write daily notes. Whether you're journaling, keeping life records, or saving quick + thoughts, RiJi keeps everything organized and secure on your device. +

+
+
+ +
+

Features

+
+ + + + +
+
+ +
+ RiJi — Offline Journal & Private Notes + A simple public app intro page for review. +
+
+
+ ); +} + +function Card({ + title, + body, + className, +}: { + title: string; + body: string; + className?: string; +}) { + return ( +
+

{title}

+

{body}

+
+ ); +} + diff --git a/proxy.ts b/proxy.ts index 384db6ee8..8c2f055b5 100644 --- a/proxy.ts +++ b/proxy.ts @@ -233,8 +233,15 @@ export async function proxy(request: NextRequest) { process.env.AUTH_URL ?? `${request.nextUrl.protocol}//${request.headers.get("host") ?? request.nextUrl.host}`; - // 未登录用户允许访问 /(新版首页)、/login、/register,其余需要登录 - if (!token && !["/", "/login", "/register"].includes(pathname)) { + const isPublicPage = + pathname === "/" || + pathname === "/login" || + pathname === "/register" || + pathname === "/riji" || + pathname.startsWith("/riji/"); + + // 未登录用户允许访问公开页面,其余需要登录 + if (!token && !isPublicPage) { // 对于 API 路由的非 GET 请求,直接返回 401 JSON 响应(不重定向) if (pathname.startsWith("/api/") && request.method !== "GET") { return NextResponse.json( diff --git a/riji/README.md b/riji/README.md new file mode 100644 index 000000000..8d9a2a8f0 --- /dev/null +++ b/riji/README.md @@ -0,0 +1,36 @@ +# RiJi App Intro Page (Subpage) + +This folder contains a simple, single-page public app introduction website for **RiJi — Offline Journal & Private Notes**. + +## Publish as a subpage (Recommended) + +If you already have a GitHub Pages repo/site (with its own homepage), just copy the whole `riji/` folder into it. + +The page URL will be `.../riji/` (a subpage), for example: +- Project pages: `https://.github.io//riji/` +- User/org pages: `https://.github.io/riji/` + +## New repo, but still a subpage + +If you want a brand-new repo and still keep this as a subpage: + +1. Create a new GitHub repository (public). +2. Put this folder into the repo as `riji/index.html`. +3. (Optional) Add a tiny root `index.html` that redirects to `/riji/`. +4. In GitHub: **Settings → Pages → Build and deployment → Deploy from a branch** + - Branch: `main` + - Folder: `/ (root)` + +Example redirect file (optional): + +```html + + + +Redirecting… +Open RiJi page +``` + +## If you want it as the homepage instead + +Copy `riji/index.html` to the repo root as `index.html`. diff --git a/riji/index.html b/riji/index.html new file mode 100644 index 000000000..32ff72b93 --- /dev/null +++ b/riji/index.html @@ -0,0 +1,333 @@ + + + + + + RiJi — Offline Journal & Private Notes + + + + + + + +
+
+
+ +
+

RiJi — Offline Journal & Private Notes

+

Offline-first journaling, private notes, and encrypted backups.

+
+
+
+ +
+
+

Page Title

+

Capture your day, anytime.

+

+ RiJi is an offline-first journal and notes app that helps you record moments, thoughts, + photos, and videos — privately and beautifully. +

+
+ +
+

Primary Highlights

+
+
+

Offline First

+

Your notes stay available even without a network connection.

+
+
+

Private by Design

+

Protect selected notes with password and Face ID.

+
+
+

Photos & Videos

+

Add media to make every memory more vivid.

+
+
+

Timeline & Calendar

+

Review your life by date, timeline, or calendar view.

+
+
+

Backup & Restore

+

Export encrypted backups and restore anytime.

+
+
+
+ +
+

About

+
+

+ RiJi is designed for people who want a clean, private, and distraction-free place to + write daily notes. Whether you're journaling, keeping life records, or saving quick + thoughts, RiJi keeps everything organized and secure on your device. +

+
+
+ +
+

Features

+
+
+

Write Freely

+

Create and edit notes with text, images, and video attachments.

+
+
+

Stay Organized

+

Browse entries in a timeline or jump through dates in calendar view.

+
+
+

Protect What Matters

+

Lock private notes with a privacy password and Face ID.

+
+
+

Keep Control of Your Data

+

Export encrypted backups and restore them whenever needed.

+
+
+
+ + +
+
+ + +