Skip to content

Commit 1e829e6

Browse files
bloveclaude
andauthored
refactor: rename internal ngaf prefix to tplane (#741)
Full audit + rename of the legacy `ngaf` identifier prefix to `tplane` across all live code (npm scope stays `@threadplane/`; `tplane` chosen as the short brand prefix). Case-preserving: `ngaf`→`tplane`, `NGAF`→`TPLANE`. Scope (236 files): - CSS custom properties `--ngaf-chat-*` → `--tplane-chat-*` (theming API) - CSS classes / keyframes (`ngaf-chat-pulse`, etc.) - Telemetry events `ngaf:*` → `tplane:*` + PostHog dashboards/insights - Env vars `NGAF_TELEMETRY_*` → `TPLANE_TELEMETRY_*` - Stripe metadata keys `ngaf_tier_slug` / `ngaf_billing_cycle` → `tplane_*` - Misc identifiers, `environment.ngafLicense`, published docs Deliberately preserved: the live Vercel Blob bucket name `ngaf-website-assets` (real external resource) and historical docs/superpowers plans+specs / CHANGELOG (record of past work). No backwards-compat shims — live Stripe metadata, deployment env vars, and PostHog historical events require separate manual migration. Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 2618261 commit 1e829e6

236 files changed

Lines changed: 1787 additions & 1787 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

apps/cockpit/e2e/production-smoke.spec.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -160,9 +160,9 @@ test.describe('Production: canonical demo sends runtime telemetry', () => {
160160
});
161161

162162
for (const event of [
163-
'ngaf:runtime_request_created',
164-
'ngaf:stream_started',
165-
'ngaf:stream_ended',
163+
'tplane:runtime_request_created',
164+
'tplane:stream_started',
165+
'tplane:stream_ended',
166166
]) {
167167
await expect
168168
.poll(

apps/minting-service/src/lib/handlers.spec.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ function subscription(overrides: Partial<Stripe.Subscription> = {}): Stripe.Subs
5050
{
5151
quantity: 1,
5252
price: {
53-
metadata: { ngaf_tier_slug: 'developer_seat' },
53+
metadata: { tplane_tier_slug: 'developer_seat' },
5454
} as Stripe.Price,
5555
} as Stripe.SubscriptionItem,
5656
],
@@ -143,14 +143,14 @@ describe('handleSubscriptionCreated', () => {
143143
);
144144
});
145145

146-
it('reads tier from subscription.metadata.ngaf_tier_slug, overriding price metadata', async () => {
146+
it('reads tier from subscription.metadata.tplane_tier_slug, overriding price metadata', async () => {
147147
const sub = subscription({
148-
metadata: { ngaf_tier_slug: 'team' },
148+
metadata: { tplane_tier_slug: 'team' },
149149
items: {
150150
data: [
151151
{
152152
quantity: 5,
153-
price: { metadata: { ngaf_tier_slug: 'developer_seat' } } as Stripe.Price,
153+
price: { metadata: { tplane_tier_slug: 'developer_seat' } } as Stripe.Price,
154154
} as Stripe.SubscriptionItem,
155155
],
156156
} as Stripe.ApiList<Stripe.SubscriptionItem>,
@@ -201,7 +201,7 @@ describe('handleSubscriptionUpdated', () => {
201201
data: [
202202
{
203203
quantity: 3,
204-
price: { metadata: { ngaf_tier_slug: 'developer_seat' } } as Stripe.Price,
204+
price: { metadata: { tplane_tier_slug: 'developer_seat' } } as Stripe.Price,
205205
} as Stripe.SubscriptionItem,
206206
],
207207
} as Stripe.ApiList<Stripe.SubscriptionItem>,

apps/minting-service/src/lib/handlers.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ function readSubscriptionFacts(subscription: Stripe.Subscription): SubscriptionL
8181
const priceMetadata = (item.price?.metadata ?? {}) as Record<string, string>;
8282
const merged: Record<string, string> = {
8383
...priceMetadata,
84-
...(subMetadata['ngaf_tier_slug'] ? { ngaf_tier_slug: subMetadata['ngaf_tier_slug'] } : {}),
84+
...(subMetadata['tplane_tier_slug'] ? { tplane_tier_slug: subMetadata['tplane_tier_slug'] } : {}),
8585
};
8686
const tier = extractTier(merged);
8787
const quantity = item.quantity ?? 1;

apps/minting-service/src/lib/tier.spec.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,19 @@ import { extractTier, computeSeats } from './tier.js';
33

44
describe('extractTier', () => {
55
it('returns developer_seat from price metadata', () => {
6-
expect(extractTier({ ngaf_tier_slug: 'developer_seat' })).toBe('developer_seat');
6+
expect(extractTier({ tplane_tier_slug: 'developer_seat' })).toBe('developer_seat');
77
});
88

99
it('returns team from price metadata', () => {
10-
expect(extractTier({ ngaf_tier_slug: 'team' })).toBe('team');
10+
expect(extractTier({ tplane_tier_slug: 'team' })).toBe('team');
1111
});
1212

13-
it('throws when ngaf_tier_slug is missing', () => {
14-
expect(() => extractTier({})).toThrow(/ngaf_tier_slug/);
13+
it('throws when tplane_tier_slug is missing', () => {
14+
expect(() => extractTier({})).toThrow(/tplane_tier_slug/);
1515
});
1616

17-
it('throws when ngaf_tier_slug is an unknown value', () => {
18-
expect(() => extractTier({ ngaf_tier_slug: 'bogus' })).toThrow(/bogus/);
17+
it('throws when tplane_tier_slug is an unknown value', () => {
18+
expect(() => extractTier({ tplane_tier_slug: 'bogus' })).toThrow(/bogus/);
1919
});
2020

2121
it('throws when metadata is null', () => {

apps/minting-service/src/lib/tier.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import type { LicenseTier } from '@threadplane/licensing';
44
export type MintableTier = Extract<LicenseTier, 'developer_seat' | 'team'>;
55

66
const VALID_TIERS: readonly MintableTier[] = ['developer_seat', 'team'] as const;
7-
const METADATA_KEY = 'ngaf_tier_slug';
7+
const METADATA_KEY = 'tplane_tier_slug';
88

99
const TEAM_SEAT_COUNT = 5;
1010

apps/website/content/blog/2026-06-04-human-in-the-loop-ag-ui-agents-in-angular.mdx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -273,16 +273,16 @@ const WELCOME_SUGGESTIONS = [
273273
>
274274
<ng-template #body let-payload>
275275
<div style="display:flex; flex-direction:column; gap:6px;">
276-
<div><span style="color:var(--ngaf-chat-text-muted); margin-right:6px;">Amount</span><strong>{{ payload.amount | currency }}</strong></div>
277-
<div><span style="color:var(--ngaf-chat-text-muted); margin-right:6px;">Customer</span><code>{{ payload.customer_id }}</code></div>
276+
<div><span style="color:var(--tplane-chat-text-muted); margin-right:6px;">Amount</span><strong>{{ payload.amount | currency }}</strong></div>
277+
<div><span style="color:var(--tplane-chat-text-muted); margin-right:6px;">Customer</span><code>{{ payload.customer_id }}</code></div>
278278
@if (payload.reason) {
279-
<div style="font-style:italic; color:var(--ngaf-chat-text-muted); margin-top:4px;">{{ payload.reason }}</div>
279+
<div style="font-style:italic; color:var(--tplane-chat-text-muted); margin-top:4px;">{{ payload.reason }}</div>
280280
}
281281
@if (editing()) {
282282
<div style="margin-top:10px; display:flex; gap:6px; align-items:center;">
283-
<label style="color:var(--ngaf-chat-text-muted); font-size:12px;">Edit amount</label>
284-
<input type="number" step="0.01" [value]="editAmount() ?? payload.amount" (input)="editAmount.set(+($any($event.target).value))" style="padding:4px 8px; border:1px solid var(--ngaf-chat-separator); border-radius:6px; width:120px;" />
285-
<button type="button" (click)="submitEdit(payload)" style="padding:4px 10px; background:var(--ngaf-chat-primary); color:var(--ngaf-chat-on-primary); border:0; border-radius:6px; font-size:12px; cursor:pointer;">Save</button>
283+
<label style="color:var(--tplane-chat-text-muted); font-size:12px;">Edit amount</label>
284+
<input type="number" step="0.01" [value]="editAmount() ?? payload.amount" (input)="editAmount.set(+($any($event.target).value))" style="padding:4px 8px; border:1px solid var(--tplane-chat-separator); border-radius:6px; width:120px;" />
285+
<button type="button" (click)="submitEdit(payload)" style="padding:4px 10px; background:var(--tplane-chat-primary); color:var(--tplane-chat-on-primary); border:0; border-radius:6px; font-size:12px; cursor:pointer;">Save</button>
286286
</div>
287287
}
288288
</div>

apps/website/content/docs/chat/api/api-docs.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4740,7 +4740,7 @@
47404740
{
47414741
"name": "ChatWelcomeComponent",
47424742
"kind": "class",
4743-
"description": "Empty-state owner. Renders a centered greeting + slot-projected input +\noptional vertical suggestion rows. Mounted only when the parent chat has\nno messages and welcome is not disabled.\n\nSlots:\n [chatWelcomeTitle] — replaces the default <h1> \"How can I help?\"\n [chatWelcomeInput] — projects the chat input into the center column\n [chatWelcomeSuggestions] — projects suggestion rows below the input\n\nHost CSS variables (override on :host or any ancestor):\n --ngaf-chat-welcome-max-width default 36rem\n --ngaf-chat-welcome-gap default 1.25rem\n --ngaf-chat-welcome-padding default 24px",
4743+
"description": "Empty-state owner. Renders a centered greeting + slot-projected input +\noptional vertical suggestion rows. Mounted only when the parent chat has\nno messages and welcome is not disabled.\n\nSlots:\n [chatWelcomeTitle] — replaces the default <h1> \"How can I help?\"\n [chatWelcomeInput] — projects the chat input into the center column\n [chatWelcomeSuggestions] — projects suggestion rows below the input\n\nHost CSS variables (override on :host or any ancestor):\n --tplane-chat-welcome-max-width default 36rem\n --tplane-chat-welcome-gap default 1.25rem\n --tplane-chat-welcome-padding default 24px",
47444744
"params": [],
47454745
"examples": [],
47464746
"properties": [],
@@ -7279,7 +7279,7 @@
72797279
"name": "AgentRuntimeTelemetryEvent",
72807280
"kind": "type",
72817281
"description": "",
7282-
"signature": "\"ngaf:runtime_instance_created\" | \"ngaf:runtime_request_created\" | \"ngaf:stream_started\" | \"ngaf:stream_ended\" | \"ngaf:stream_errored\"",
7282+
"signature": "\"tplane:runtime_instance_created\" | \"tplane:runtime_request_created\" | \"tplane:stream_started\" | \"tplane:stream_ended\" | \"tplane:stream_errored\"",
72837283
"examples": []
72847284
},
72857285
{

apps/website/content/docs/chat/api/chat-config.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ A short string (typically one or two characters) for wrappers or components that
4242
provideChat({ avatarLabel: 'AI' });
4343
```
4444

45-
There is no avatar-specific CSS token. Use the shared `--ngaf-chat-*` tokens such as `--ngaf-chat-surface`, `--ngaf-chat-text`, and `--ngaf-chat-text-muted` to align chat surfaces with your app theme.
45+
There is no avatar-specific CSS token. Use the shared `--tplane-chat-*` tokens such as `--tplane-chat-surface`, `--tplane-chat-text`, and `--tplane-chat-text-muted` to align chat surfaces with your app theme.
4646

4747
### assistantName
4848

@@ -85,7 +85,7 @@ A signed license token from threadplane.ai. It is optional in development and sh
8585
**Example:**
8686

8787
```typescript
88-
provideChat({ license: environment.ngafLicense });
88+
provideChat({ license: environment.tplaneLicense });
8989
```
9090

9191
## Accessing ChatConfig at Runtime

apps/website/content/docs/chat/components/chat-input.mdx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -128,14 +128,14 @@ The component renders a `<form>` containing a `<textarea>` and a `<button>`. It
128128

129129
| Variable | Applied To |
130130
|----------|-----------|
131-
| `--ngaf-chat-surface-alt` | Form background |
132-
| `--ngaf-chat-separator` | Form border (unfocused) |
133-
| `--ngaf-chat-muted` | Form border (focused) |
134-
| `--ngaf-chat-radius-input` | Form border radius |
135-
| `--ngaf-chat-text` | Textarea text color |
136-
| `--ngaf-chat-font-family` | Textarea font |
137-
| `--ngaf-chat-primary` | Send button background |
138-
| `--ngaf-chat-on-primary` | Send button icon color |
131+
| `--tplane-chat-surface-alt` | Form background |
132+
| `--tplane-chat-separator` | Form border (unfocused) |
133+
| `--tplane-chat-muted` | Form border (focused) |
134+
| `--tplane-chat-radius-input` | Form border radius |
135+
| `--tplane-chat-text` | Textarea text color |
136+
| `--tplane-chat-font-family` | Textarea font |
137+
| `--tplane-chat-primary` | Send button background |
138+
| `--tplane-chat-on-primary` | Send button icon color |
139139

140140
## ARIA
141141

apps/website/content/docs/chat/components/chat-interrupt-panel.mdx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -103,13 +103,13 @@ The panel uses the chat theme's warning variables:
103103

104104
| Variable | Applied To |
105105
|----------|-----------|
106-
| `--ngaf-chat-warning-bg` | Panel background |
107-
| `--ngaf-chat-warning-text` | Header and message text |
108-
| `--ngaf-chat-separator` | Panel border |
109-
| `--ngaf-chat-radius-card` | Panel border radius |
110-
| `--ngaf-chat-surface-alt` | Action button backgrounds |
111-
| `--ngaf-chat-text` | Action button text |
112-
| `--ngaf-chat-text-muted` | Ignore button text |
106+
| `--tplane-chat-warning-bg` | Panel background |
107+
| `--tplane-chat-warning-text` | Header and message text |
108+
| `--tplane-chat-separator` | Panel border |
109+
| `--tplane-chat-radius-card` | Panel border radius |
110+
| `--tplane-chat-surface-alt` | Action button backgrounds |
111+
| `--tplane-chat-text` | Action button text |
112+
| `--tplane-chat-text-muted` | Ignore button text |
113113

114114
## Primitive Alternative: ChatInterruptComponent
115115

0 commit comments

Comments
 (0)