diff --git a/CLAUDE.md b/CLAUDE.md index 1baa231..f9c544e 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -693,6 +693,14 @@ Server-side via `q` query parameter. `ListQuery` extracts it, repos apply `LIKE` - Prefer `if`/`else` and `switch` over ternaries; never nest ternaries - **Inline `onclick` + global arrow functions** for pages with imperative JS — do not use `DOMContentLoaded` + `addEventListener` +### Copy & UI Text + +- **No second-person pronouns** — never use "you", "your", "you're" in user-facing strings (templates, CLI output, error messages, docs). Use imperative tone or impersonal phrasing instead. + - "Browse all your coffee data" → "Browse all coffee data" + - "Lets you sign in" → "Enables sign-in" + - "Your browser does not support" → "This browser does not support" + - "you won't see it again" → "it will not be shown again" + ### Naming & Conventions - **Method naming**: `order_clause()` for sort query builders (not `sort_clause`) diff --git a/README.md b/README.md index 7e05917..9b4121d 100644 --- a/README.md +++ b/README.md @@ -46,8 +46,8 @@ No users found. Register the first user at: This link expires in 1 hour. ``` -Open that URL, choose a display name, and register a passkey. This creates your account and -signs you in. +Open that URL, choose a display name, and register a passkey. This creates an account and +signs in automatically. ### CLI Authentication @@ -55,12 +55,12 @@ To use the CLI or API for write operations, create a token via browser handoff: ```bash brewlog token create --name "my-cli-token" -# Browser opens → authenticate with your passkey → token printed once +# Browser opens → authenticate with a passkey → token printed once export BREWLOG_URL="http://localhost:3000" export BREWLOG_TOKEN="" -# Now you can create data from the CLI +# Create data from the CLI brewlog roaster add --name "Radical Roasters" --country "United Kingdom" ``` @@ -75,7 +75,7 @@ directory is loaded automatically via [dotenvy](https://crates.io/crates/dotenvy | Variable | Purpose | Default | | ------------------------ | ------------------------------------------------------ | --------------------- | -| `BREWLOG_RP_ID` | WebAuthn Relying Party ID (your domain) | **required** | +| `BREWLOG_RP_ID` | WebAuthn Relying Party ID (server domain) | **required** | | `BREWLOG_RP_ORIGIN` | WebAuthn Relying Party origin (full URL) | **required** | | `BREWLOG_DATABASE_URL` | Database connection string | `sqlite://brewlog.db` | | `BREWLOG_BIND_ADDRESS` | Server bind address | `127.0.0.1:3000` | diff --git a/src/main.rs b/src/main.rs index 5751a22..64bcc8b 100644 --- a/src/main.rs +++ b/src/main.rs @@ -87,14 +87,14 @@ async fn run_server(command: ServeCommand) -> Result<()> { let openrouter_api_key = command.openrouter_api_key.ok_or_else(|| { anyhow::anyhow!( "BREWLOG_OPENROUTER_API_KEY is required. Set this environment variable \ - to your OpenRouter API key for AI-powered extraction features." + to an OpenRouter API key for AI-powered extraction features." ) })?; let foursquare_api_key = command.foursquare_api_key.ok_or_else(|| { anyhow::anyhow!( "BREWLOG_FOURSQUARE_API_KEY is required. Set this environment variable \ - to your Foursquare API key for nearby cafe search." + to a Foursquare API key for nearby cafe search." ) })?; diff --git a/src/presentation/cli/tokens.rs b/src/presentation/cli/tokens.rs index 4edf5e7..f04de92 100644 --- a/src/presentation/cli/tokens.rs +++ b/src/presentation/cli/tokens.rs @@ -102,7 +102,7 @@ pub async fn create_token(client: &BrewlogClient, cmd: CreateTokenCommand) -> Re println!("Token Name: {}", cmd.name); println!("\nSave this token securely - it will not be shown again:"); println!("\n{token}"); - println!("\nExport it in your environment:"); + println!("\nExport it as an environment variable:"); println!(" export BREWLOG_TOKEN={token}"); Ok(()) @@ -159,7 +159,7 @@ async fn run_callback_server( let _ = sender.send(token); } - Html("

Authenticated

You can close this window and return to the terminal.

".to_string()) + Html("

Authenticated

This window can be closed. Return to the terminal.

".to_string()) } }), ); diff --git a/templates/pages/add.html b/templates/pages/add.html index 166511f..773e0c5 100644 --- a/templates/pages/add.html +++ b/templates/pages/add.html @@ -266,8 +266,8 @@ {% else if grinder_options.is_empty() || brewer_options.is_empty() %}
-

Add your gear first

-

Brews need a grinder and brewer. Add your gear to enable this form.

+

Add gear first

+

Brews need a grinder and brewer. Add gear to enable this form.

{% else %}
@@ -449,7 +449,7 @@