Detect locale with is-china-user and show English copy for non-Chinese visitors.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
eric
2026-08-03 08:54:39 -05:00
parent 4c2101a87a
commit af0a430864
9 changed files with 233 additions and 20 deletions

8
pnpm-lock.yaml generated
View File

@@ -11,6 +11,9 @@ importers:
framer-motion:
specifier: ^12.36.0
version: 12.36.0(react-dom@19.2.3(react@19.2.3))(react@19.2.3)
is-china-user:
specifier: ^1.7.0
version: 1.7.0
lucide-react:
specifier: ^0.577.0
version: 0.577.0(react@19.2.3)
@@ -1254,6 +1257,9 @@ packages:
resolution: {integrity: sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==}
engines: {node: '>= 0.4'}
is-china-user@1.7.0:
resolution: {integrity: sha512-qVhmz+TwK8+WWtEILYZd9tgt7oNsVj0T6VaMqiUlGOltZ64/HTJ4iszNu2KBRM5marxN9BNiMcJjRENsJau6Aw==}
is-core-module@2.16.1:
resolution: {integrity: sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==}
engines: {node: '>= 0.4'}
@@ -3284,6 +3290,8 @@ snapshots:
is-callable@1.2.7: {}
is-china-user@1.7.0: {}
is-core-module@2.16.1:
dependencies:
hasown: 2.0.2