@stacksjs/defaults 0.75.233 → 0.75.237
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/ai/skills/stacks-auth/SKILL.md +9 -1
- package/ai/skills/stacks-dashboard/SKILL.md +2 -2
- package/ai/skills/stacks-database/SKILL.md +1 -1
- package/ai/skills/stacks-deploy/SKILL.md +3 -2
- package/ai/skills/stacks-migrations/SKILL.md +2 -2
- package/ai/skills/stacks-native/CATALOG.md +12 -12
- package/ai/skills/stacks-realtime/SKILL.md +16 -2
- package/ai/skills/stacks-router/SKILL.md +8 -0
- package/ai/skills/stacks-testing/SKILL.md +5 -0
- package/app/Actions/Monitoring/error-provider.ts +129 -12
- package/app/Models/Error.ts +21 -0
- package/ide/vscode/package.json +1 -1
- package/package.json +2 -2
- package/resources/components/Dashboard/Auth/AuthCard.stx +29 -0
- package/resources/components/Dashboard/Auth/ForgotPassword.stx +65 -79
- package/resources/components/Dashboard/Auth/Login.stx +73 -82
- package/resources/components/Dashboard/Auth/Register.stx +121 -135
- package/resources/components/Dashboard/Auth/ResetPassword.stx +88 -102
- package/resources/components/Dashboard/Buddy/BuddyAssistant.stx +11 -15
- package/resources/components/Dashboard/Commerce/CommerceCategoriesDashboard.stx +8 -20
- package/resources/components/Dashboard/Commerce/CommerceCouponsDashboard.stx +8 -20
- package/resources/components/Dashboard/Commerce/CommerceCustomersDashboard.stx +8 -20
- package/resources/components/Dashboard/Commerce/CommerceGiftCardsDashboard.stx +8 -20
- package/resources/components/Dashboard/Commerce/CommerceManufacturersDashboard.stx +13 -24
- package/resources/components/Dashboard/Commerce/CommerceOrdersDashboard.stx +8 -20
- package/resources/components/Dashboard/Commerce/CommerceOverviewDashboard.stx +17 -21
- package/resources/components/Dashboard/Commerce/CommercePaymentsDashboard.stx +7 -19
- package/resources/components/Dashboard/Commerce/CommercePosDashboard.stx +4 -16
- package/resources/components/Dashboard/Commerce/CommerceProductsDashboard.stx +8 -20
- package/resources/components/Dashboard/Commerce/CommerceReviewsDashboard.stx +7 -18
- package/resources/components/Dashboard/Commerce/CommerceTaxesDashboard.stx +13 -24
- package/resources/components/Dashboard/Commerce/CommerceUnitsDashboard.stx +13 -24
- package/resources/components/Dashboard/Commerce/CommerceVariantsDashboard.stx +7 -18
- package/resources/components/Dashboard/Commerce/Delivery/CouriersDashboard.stx +7 -13
- package/resources/components/Dashboard/Commerce/Delivery/DeliveryOverviewDashboard.stx +12 -16
- package/resources/components/Dashboard/Commerce/Delivery/DeliveryRoutesDashboard.stx +7 -13
- package/resources/components/Dashboard/Commerce/Delivery/DigitalDeliveriesDashboard.stx +7 -13
- package/resources/components/Dashboard/Commerce/Delivery/LicenseKeysDashboard.stx +7 -13
- package/resources/components/Dashboard/Commerce/Delivery/ShippingMethodsDashboard.stx +7 -13
- package/resources/components/Dashboard/Commerce/Delivery/ShippingRatesDashboard.stx +7 -13
- package/resources/components/Dashboard/Commerce/Delivery/ShippingZonesDashboard.stx +7 -13
- package/resources/components/Dashboard/Commerce/PrintDevicesDashboard.stx +8 -20
- package/resources/components/Dashboard/Commerce/PrintLogsDashboard.stx +7 -19
- package/resources/components/Dashboard/Commerce/ProductWaitlistDashboard.stx +12 -16
- package/resources/components/Dashboard/Commerce/RestaurantWaitlistDashboard.stx +12 -16
- package/resources/components/Dashboard/Deployments/DeploymentList.stx +17 -21
- package/resources/components/Dashboard/Marketing/AbandonedCartsDashboard.stx +6 -10
- package/resources/components/Dashboard/Marketing/CampaignsDashboard.stx +6 -10
- package/resources/components/Dashboard/Marketing/MarketingListsDashboard.stx +9 -13
- package/resources/components/Dashboard/Marketing/SocialPostsDashboard.stx +6 -10
- package/resources/components/Dashboard/Queue/QueueDashboard.stx +12 -16
- package/resources/components/Dashboard/Realtime/RealtimeDashboard.stx +6 -10
- package/resources/components/Dashboard/Releases/ReleaseDashboard.stx +6 -10
- package/resources/components/Dashboard/UI/MetricCards.stx +32 -0
- package/resources/components/Dashboard/UI/PageHeader.stx +25 -66
- package/resources/components/Dashboard/UI/Table.stx +79 -6
|
@@ -212,6 +212,14 @@ authenticated and CSRF protected.
|
|
|
212
212
|
|
|
213
213
|
## Authorization Gates (gate.ts)
|
|
214
214
|
|
|
215
|
+
Gate registrations, policies and before/after callbacks are shared by native
|
|
216
|
+
module copies in one JavaScript process, including separately bundled Actions.
|
|
217
|
+
`Gate.flush()` clears those registrations across every copy. This shares no
|
|
218
|
+
request identity, token or authorization decision. Native `AuthorizationResponse`
|
|
219
|
+
objects can cross bundle copies; arbitrary objects, forged prototypes and
|
|
220
|
+
accessor fields are rejected. A conflicting shared-state version/shape refuses
|
|
221
|
+
module initialization. This does not synchronize different processes or Workers.
|
|
222
|
+
|
|
215
223
|
### Gate Functions
|
|
216
224
|
- `define<T>(ability: string, callback: GateCallback<T>): void`
|
|
217
225
|
- `policy(model: string | { name }, policyClass: new () => Policy): void`
|
|
@@ -225,7 +233,7 @@ authenticated and CSRF protected.
|
|
|
225
233
|
- `all(abilities[], user, ...args): Promise<boolean>`
|
|
226
234
|
- `none(abilities[], user, ...args): Promise<boolean>`
|
|
227
235
|
- `authorize(ability, user, ...args): Promise<AuthorizationResponse>` - throws on deny
|
|
228
|
-
- `inspect(ability, user, ...args): Promise<AuthorizationResponse>` -
|
|
236
|
+
- `inspect(ability, user, ...args): Promise<AuthorizationResponse>` - detailed result; invalid callback returns throw
|
|
229
237
|
- `has(ability): boolean`
|
|
230
238
|
- `hasPolicy(model): boolean`
|
|
231
239
|
- `abilities(): string[]`
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: stacks-dashboard
|
|
3
|
-
description: Use when building or customizing the Stacks admin dashboard, including dashboard pages, model management views, analytics widgets, commerce dashboards, content management, settings panels, deployment monitoring, job/queue management, or the
|
|
3
|
+
description: Use when building or customizing the Stacks admin dashboard, including dashboard pages, model management views, analytics widgets, commerce dashboards, content management, settings panels, deployment monitoring, job/queue management, or the 414 built-in dashboard components. Covers the dashboard system at storage/framework/defaults/.
|
|
4
4
|
license: MIT
|
|
5
5
|
compatibility: Bun >= 1.3.0, TypeScript
|
|
6
6
|
allowed-tools: Read Edit Write Bash Grep Glob
|
|
@@ -8,7 +8,7 @@ allowed-tools: Read Edit Write Bash Grep Glob
|
|
|
8
8
|
|
|
9
9
|
# Stacks Dashboard
|
|
10
10
|
|
|
11
|
-
The Stacks admin dashboard provides a full-featured admin panel with 100+ route views,
|
|
11
|
+
The Stacks admin dashboard provides a full-featured admin panel with 100+ route views, 414 components, and a multi-section layout.
|
|
12
12
|
|
|
13
13
|
## Key Paths
|
|
14
14
|
- Dashboard components: `storage/framework/defaults/resources/components/Dashboard/`
|
|
@@ -12,7 +12,7 @@ allowed-tools: Read Edit Write Bash Grep Glob
|
|
|
12
12
|
- Database package: `storage/framework/core/database/src/`
|
|
13
13
|
- Configuration: `config/database.ts`
|
|
14
14
|
- QB config: `config/query-builder.ts`
|
|
15
|
-
- Migrations: `database/migrations/` (
|
|
15
|
+
- Migrations: `database/migrations/` (239 migration files, `.sql` format)
|
|
16
16
|
- QB state: `.qb/`
|
|
17
17
|
- ORM: `storage/framework/orm/`
|
|
18
18
|
|
|
@@ -53,8 +53,9 @@ a versioned `STACKS_DEPLOY_PREVIEW_JSON=` line for API and tool consumers.
|
|
|
53
53
|
|
|
54
54
|
Automated production deployments on GitHub Actions and ReviewOS require a full provider
|
|
55
55
|
commit SHA and branch ref. Before prerequisite setup, Buddy verifies the checkout against
|
|
56
|
-
that SHA
|
|
57
|
-
|
|
56
|
+
that SHA and accepts an unchanged origin head directly. If the head moved, Buddy fetches
|
|
57
|
+
the branch from `origin` (FETCH_HEAD only), completes shallow history and requires the
|
|
58
|
+
commit to be on it. Unavailable or still-shallow history stops deployment. Before shipping over SSH it
|
|
58
59
|
reads the release each site's `current` link serves and stops only when production
|
|
59
60
|
already runs a commit that landed after this one, so a deploy never goes backwards. A
|
|
60
61
|
verified commit newer than production deploys even when the head has moved on: requiring
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: stacks-migrations
|
|
3
|
-
description: Use when working with database migrations in a Stacks application - creating migration files, running migrations, fresh migration (drop + recreate), seeding after migration, migration file naming conventions, or the
|
|
3
|
+
description: Use when working with database migrations in a Stacks application - creating migration files, running migrations, fresh migration (drop + recreate), seeding after migration, migration file naming conventions, or the 239 built-in migration files. For the database API itself (queries, connections, SQL helpers), see stacks-database.
|
|
4
4
|
license: MIT
|
|
5
5
|
compatibility: Bun >= 1.3.0, TypeScript, SQLite >= 3.47.2
|
|
6
6
|
allowed-tools: Read Edit Write Bash Grep Glob
|
|
@@ -203,6 +203,6 @@ lossless widenings; reports everything destructive), then
|
|
|
203
203
|
- Do not commit a second snapshot under `.qb/`; that indicates a missing `snapshotDir` configuration
|
|
204
204
|
- If a generated SQLite migration rebuilds tables, test it against a copy of the current database and run `PRAGMA integrity_check` plus `PRAGMA foreign_key_check`
|
|
205
205
|
- `--seed` flag after `migrate:fresh` seeds the database with factory data
|
|
206
|
-
-
|
|
206
|
+
- 239 migration files exist by default for all framework models
|
|
207
207
|
- SQLite >= 3.47.2 is required (system requirement)
|
|
208
208
|
- For the database API (queries, connections), see the `stacks-database` skill
|
|
@@ -18,7 +18,7 @@ Browser runtime bindings are documented separately in `stacks-auto-imports`.
|
|
|
18
18
|
| `@stacksjs/api` | [`stacks-api`](../stacks-api/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/api/src/index.ts) | 9 |
|
|
19
19
|
| `@stacksjs/arrays` | [`stacks-arrays`](../stacks-arrays/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/arrays/src/index.ts) | 6 |
|
|
20
20
|
| `@stacksjs/audio` | [`stacks-audio`](../stacks-audio/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/audio/src/index.ts) | 2 |
|
|
21
|
-
| `@stacksjs/auth` | [`stacks-auth`](../stacks-auth/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/index.ts) |
|
|
21
|
+
| `@stacksjs/auth` | [`stacks-auth`](../stacks-auth/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/index.ts) | 119 |
|
|
22
22
|
| `@stacksjs/browser` | [`stacks-browser`](../stacks-browser/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/browser/src/index.ts) | 8 |
|
|
23
23
|
| `@stacksjs/browser-extension` | [`stacks-browser-extension`](../stacks-browser-extension/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/browser-extension/src/index.ts) | 7 |
|
|
24
24
|
| `@stacksjs/buddy` | [`stacks-buddy`](../stacks-buddy/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/buddy/src/index.ts) | 151 |
|
|
@@ -35,7 +35,7 @@ Browser runtime bindings are documented separately in `stacks-auto-imports`.
|
|
|
35
35
|
| `@stacksjs/composables` | [`stacks-composables`](../stacks-composables/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/composables/src/index.ts) | 18 |
|
|
36
36
|
| `@stacksjs/config` | [`stacks-config`](../stacks-config/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/config/src/index.ts) | 16 |
|
|
37
37
|
| `@stacksjs/cron` | [`stacks-cron`](../stacks-cron/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/cron/src/index.ts) | 4 |
|
|
38
|
-
| `@stacksjs/database` | [`stacks-database`](../stacks-database/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/index.ts) |
|
|
38
|
+
| `@stacksjs/database` | [`stacks-database`](../stacks-database/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/index.ts) | 125 |
|
|
39
39
|
| `@stacksjs/datetime` | [`stacks-datetime`](../stacks-datetime/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/datetime/src/index.ts) | 13 |
|
|
40
40
|
| `@stacksjs/defaults` | [`stacks-build`](../stacks-build/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/defaults/package.json) | 1 |
|
|
41
41
|
| `@stacksjs/deploy` | [`stacks-deploy`](../stacks-deploy/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/deploy/package.json) | 1 |
|
|
@@ -72,10 +72,10 @@ Browser runtime bindings are documented separately in `stacks-auto-imports`.
|
|
|
72
72
|
| `@stacksjs/push` | [`stacks-push`](../stacks-push/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/push/src/index.ts) | 6 |
|
|
73
73
|
| `@stacksjs/query-builder` | [`stacks-query-builder`](../stacks-query-builder/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/query-builder/src/index.ts) | 6 |
|
|
74
74
|
| `@stacksjs/queue` | [`stacks-queue`](../stacks-queue/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/queue/src/index.ts) | 48 |
|
|
75
|
-
| `@stacksjs/realtime` | [`stacks-realtime`](../stacks-realtime/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/realtime/src/index.ts) |
|
|
75
|
+
| `@stacksjs/realtime` | [`stacks-realtime`](../stacks-realtime/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/realtime/src/index.ts) | 12 |
|
|
76
76
|
| `@stacksjs/registry` | [`stacks-registry`](../stacks-registry/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/registry/src/index.ts) | 1 |
|
|
77
77
|
| `@stacksjs/repl` | [`stacks-repl`](../stacks-repl/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/repl/src/index.ts) | 2 |
|
|
78
|
-
| `@stacksjs/router` | [`stacks-router`](../stacks-router/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/index.ts) |
|
|
78
|
+
| `@stacksjs/router` | [`stacks-router`](../stacks-router/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/index.ts) | 92 |
|
|
79
79
|
| `@stacksjs/scheduler` | [`stacks-scheduler`](../stacks-scheduler/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/scheduler/src/index.ts) | 13 |
|
|
80
80
|
| `@stacksjs/search-engine` | [`stacks-search-engine`](../stacks-search-engine/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/search-engine/src/index.ts) | 10 |
|
|
81
81
|
| `@stacksjs/security` | [`stacks-security`](../stacks-security/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/index.ts) | 11 |
|
|
@@ -88,7 +88,7 @@ Browser runtime bindings are documented separately in `stacks-auto-imports`.
|
|
|
88
88
|
| `@stacksjs/socials` | [`stacks-socials`](../stacks-socials/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/socials/src/index.ts) | 17 |
|
|
89
89
|
| `@stacksjs/storage` | [`stacks-storage`](../stacks-storage/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/storage/src/index.ts) | 42 |
|
|
90
90
|
| `@stacksjs/strings` | [`stacks-strings`](../stacks-strings/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/strings/src/index.ts) | 7 |
|
|
91
|
-
| `@stacksjs/testing` | [`stacks-testing`](../stacks-testing/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/testing/src/index.ts) |
|
|
91
|
+
| `@stacksjs/testing` | [`stacks-testing`](../stacks-testing/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/testing/src/index.ts) | 17 |
|
|
92
92
|
| `@stacksjs/tinker` | [`stacks-repl`](../stacks-repl/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/tinker/src/index.ts) | 1 |
|
|
93
93
|
| `@stacksjs/tunnel` | [`stacks-tunnel`](../stacks-tunnel/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/tunnel/src/index.ts) | 1 |
|
|
94
94
|
| `@stacksjs/types` | [`stacks-types`](../stacks-types/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/types/src/index.ts) | 2 |
|
|
@@ -185,7 +185,7 @@ Declared runtime exports: `DEFAULT_ROLE_PACKS`, `createBqbRbacStore`, `generateT
|
|
|
185
185
|
|
|
186
186
|
Local source modules: [src/authentication.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/authentication.ts), [src/authenticator.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/authenticator.ts), [src/authorizable.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/authorizable.ts), [src/browser-session.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/browser-session.ts), [src/client.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/client.ts), [src/cookie-auth.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/cookie-auth.ts), [src/credential-user.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/credential-user.ts), [src/email-verification.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/email-verification.ts), [src/gate.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/gate.ts), [src/magic-link.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/magic-link.ts), [src/middleware.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/middleware.ts), [src/oauth-authorization-codes.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-authorization-codes.ts), [src/oauth-authorization-endpoint.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-authorization-endpoint.ts), [src/oauth-authorization-requests.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-authorization-requests.ts), [src/oauth-authorization-response.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-authorization-response.ts), [src/oauth-authorization.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-authorization.ts), [src/oauth-browser-session.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-browser-session.ts), [src/oauth-client-registration.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-client-registration.ts), [src/oauth-consent.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-consent.ts), [src/oauth-delegated-access.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-delegated-access.ts), [src/oauth-dynamic-registration.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-dynamic-registration.ts), [src/oauth-grants.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-grants.ts), [src/oauth-introspection.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-introspection.ts), [src/oauth-metadata.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-metadata.ts), [src/oauth-pkce.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-pkce.ts), [src/oauth-protected-resource.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-protected-resource.ts), [src/oauth-provider.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-provider.ts), [src/oauth-pruning.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-pruning.ts), [src/oauth-revocation.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-revocation.ts), [src/oauth-server.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-server.ts), [src/oauth-token-endpoint.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-token-endpoint.ts), [src/oauth-token-exchange.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-token-exchange.ts), [src/oauth-token-request.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-token-request.ts), [src/oauth-token-response.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/oauth-token-response.ts), [src/page-gate.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/page-gate.ts), [src/passkey.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/passkey.ts), [src/passkeys.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/passkeys.ts), [src/password/reset.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/password/reset.ts), [src/permissions.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/permissions.ts), [src/policy.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/policy.ts), [src/rate-limiter.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/rate-limiter.ts), [src/rbac-seed.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/rbac-seed.ts), [src/rbac-store-bqb.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/rbac-store-bqb.ts), [src/rbac.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/rbac.ts), [src/referrals.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/referrals.ts), [src/register.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/register.ts), [src/request-token.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/request-token.ts), [src/session-auth.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/session-auth.ts), [src/session-handoff.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/session-handoff.ts), [src/socials.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/socials.ts), [src/team.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/team.ts), [src/tokens.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/tokens.ts), [src/two-factor.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/two-factor.ts), [src/user.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/src/user.ts).
|
|
187
187
|
|
|
188
|
-
Evidence directory: [
|
|
188
|
+
Evidence directory: [119 retained tests](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/auth/tests). These files are evidence pointers, not a claim that all tests were run for this catalog.
|
|
189
189
|
|
|
190
190
|
### @stacksjs/browser
|
|
191
191
|
|
|
@@ -351,7 +351,7 @@ Declared runtime exports: `BUN_BROKEN_MYSQL_POOL_MESSAGE`, `BUN_BROKEN_POSTGRES_
|
|
|
351
351
|
|
|
352
352
|
Local source modules: [src/affected-rows.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/affected-rows.ts), [src/auth-tables.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/auth-tables.ts), [src/broken-pool.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/broken-pool.ts), [src/custom/index.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/custom/index.ts), [src/database.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/database.ts), [src/datetime-columns.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/datetime-columns.ts), [src/ddl-constraints.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/ddl-constraints.ts), [src/defaults.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/defaults.ts), [src/dialect.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/dialect.ts), [src/driver-config.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/driver-config.ts), [src/drivers/dynamodb.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/drivers/dynamodb.ts), [src/drivers/index.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/drivers/index.ts), [src/ensure-database.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/ensure-database.ts), [src/erd.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/erd.ts), [src/fk-audit.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/fk-audit.ts), [src/framework-renames.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/framework-renames.ts), [src/hand-written-migrations.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/hand-written-migrations.ts), [src/ignored-migrations.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/ignored-migrations.ts), [src/index-shape.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/index-shape.ts), [src/managed-columns.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/managed-columns.ts), [src/migration-dialect.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/migration-dialect.ts), [src/migration-ledger.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/migration-ledger.ts), [src/migration-names.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/migration-names.ts), [src/migration-path.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/migration-path.ts), [src/migrations.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/migrations.ts), [src/model-sources.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/model-sources.ts), [src/notification-tables.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/notification-tables.ts), [src/package-migrations.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/package-migrations.ts), [src/package-models.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/package-models.ts), [src/query-logger.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/query-logger.ts), [src/rbac-tables.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/rbac-tables.ts), [src/relation-columns.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/relation-columns.ts), [src/replicas.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/replicas.ts), [src/row-lock.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/row-lock.ts), [src/safe-migrations.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/safe-migrations.ts), [src/schema-align.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/schema-align.ts), [src/schema-drift.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/schema-drift.ts), [src/seeder.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/seeder.ts), [src/shadowed-models.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/shadowed-models.ts), [src/sql-helpers.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/sql-helpers.ts), [src/trait-tables.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/trait-tables.ts), [src/transaction-context.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/transaction-context.ts), [src/types.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/types.ts), [src/unique-audit.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/unique-audit.ts), [src/utc-defaults.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/utc-defaults.ts), [src/utils.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/utils.ts), [src/uuid-columns.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/uuid-columns.ts), [src/vschema.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/src/vschema.ts).
|
|
353
353
|
|
|
354
|
-
Evidence directory: [
|
|
354
|
+
Evidence directory: [125 retained tests](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/database/tests). These files are evidence pointers, not a claim that all tests were run for this catalog.
|
|
355
355
|
|
|
356
356
|
### @stacksjs/datetime
|
|
357
357
|
|
|
@@ -697,7 +697,7 @@ Declared runtime exports: `LegacyBroadcast`, `StacksChannel`, `channel`, `create
|
|
|
697
697
|
|
|
698
698
|
Local source modules: [src/broadcast.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/realtime/src/broadcast.ts), [src/channel.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/realtime/src/channel.ts), [src/emit.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/realtime/src/emit.ts), [src/replay-buffer.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/realtime/src/replay-buffer.ts), [src/server-instance.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/realtime/src/server-instance.ts), [src/stream.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/realtime/src/stream.ts), [src/ws.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/realtime/src/ws.ts).
|
|
699
699
|
|
|
700
|
-
Evidence directory: [
|
|
700
|
+
Evidence directory: [12 retained tests](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/realtime/tests). These files are evidence pointers, not a claim that all tests were run for this catalog.
|
|
701
701
|
|
|
702
702
|
### @stacksjs/registry
|
|
703
703
|
|
|
@@ -719,11 +719,11 @@ Evidence directory: [2 retained tests](https://github.com/stacksjs/stacks/blob/m
|
|
|
719
719
|
|
|
720
720
|
Guidance: [`stacks-router`](../stacks-router/SKILL.md). Source: [storage/framework/core/router/src/index.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/index.ts).
|
|
721
721
|
|
|
722
|
-
Declared runtime exports: `DASHBOARD_ROUTE_GROUPS`, `DEFAULT_ROUTE_BUNDLE_FEATURES`, `DEFAULT_ROUTE_REGISTRY`, `DatabaseSessionStore`, `EncryptedSessionStore`, `FileSessionStore`, `JSON_CONTENT_TYPE`, `MemorySessionStore`, `Middleware`, `PathParamError`, `RedisSessionStore`, `RequestBodyError`, `appRouteRegistry`, `assertRouteMiddlewareResolvable`, `bundleMounts`, `cacheRedisConnection`, `cacheRequestQuery`, `checkApplicationHealth`, `clearCsrfModuleCache`, `clearCurrentRequest`, `clearMiddlewareCache`, `clearRateLimit`, `clearRouteModelBindings`, `clearTrackedQueries`, `clientAddress`, `configureViewDirectories`, `createErrorResponse`, `createMiddlewareErrorResponse`, `createNotFoundResponse`, `createSessionStore`, `createStacksRouter`, `createStacksSessionStore`, `createTypedRouter`, `createValidationErrorResponse`, `dashboardGroupMiddleware`, `defineMiddleware`, `defineRouteModelBinding`, `describeUnknownDashboardGroups`, `disableViewRouting`, `enhanceRequest`, `fallbackStorage`, `findUnresolvableRouteMiddleware`, `getCurrentRequest`, `getQueryShapeCounts`, `getTraceId`, `installMiddlewareHotReload`, `isApiRequest`, `isRouterAction`, `listNamedRoutes`, `listRegisteredRoutes`, `listRootMountedAppRoutes`, `loadMiddlewareHandlers`, `loadRoutes`, `mountedDefaultRouteBundles`, `rateLimit`, `rateLimitScale`, `rateLimitStatus`, `readJsonBody`, `readTextBody`, `request`, `resetBootHooks`, `resetRateLimiters`, `resetSharedRateLimitStorage`, `resolveDashboardAccess`, `resolveRouteModel`, `route`, `routeModelBindings`, `routeParams`, `runBootHooks`, `runHealthProbes`, `runWithRequest`, `safePathParam`, `sanitizePathParam`, `scaledLimit`, `serve`, `serverResponse`, `setCurrentRequest`, `setRouteModelFallback`, `sharedRateLimitStorage`, `signUrl`, `signedUrl`, `stream`, `trackQuery`, `trustedProxies`, `url`, `useRateLimitStorage`, `verifySignedUrl`, `verifySignedUrlMiddleware`, `warnOnMultipleRouterInstances`, `withTraceId`, `wrapAction`.
|
|
722
|
+
Declared runtime exports: `DASHBOARD_ROUTE_GROUPS`, `DEFAULT_ROUTE_BUNDLE_FEATURES`, `DEFAULT_ROUTE_REGISTRY`, `DatabaseSessionStore`, `EncryptedSessionStore`, `FileSessionStore`, `JSON_CONTENT_TYPE`, `MemorySessionStore`, `Middleware`, `PathParamError`, `RedisSessionStore`, `RequestBodyError`, `appRouteRegistry`, `assertRouteMiddlewareResolvable`, `bundleMounts`, `cacheRedisConnection`, `cacheRequestQuery`, `checkApplicationHealth`, `clearCsrfModuleCache`, `clearCurrentRequest`, `clearMiddlewareCache`, `clearRateLimit`, `clearRouteModelBindings`, `clearTrackedQueries`, `clientAddress`, `configureViewDirectories`, `createErrorResponse`, `createMiddlewareErrorResponse`, `createNotFoundResponse`, `createSessionStore`, `createStacksRouter`, `createStacksSessionStore`, `createTypedRouter`, `createValidationErrorResponse`, `dashboardGroupMiddleware`, `defineMiddleware`, `defineRouteModelBinding`, `describeUnknownDashboardGroups`, `disableViewRouting`, `enhanceRequest`, `fallbackStorage`, `findUnresolvableRouteMiddleware`, `getCurrentRequest`, `getQueryShapeCounts`, `getTraceId`, `installMiddlewareHotReload`, `isApiRequest`, `isRouterAction`, `listNamedRoutes`, `listRegisteredRoutes`, `listRootMountedAppRoutes`, `loadMiddlewareHandlers`, `loadRoutes`, `mountedDefaultRouteBundles`, `parseJsonText`, `rateLimit`, `rateLimitScale`, `rateLimitStatus`, `readJsonBody`, `readTextBody`, `request`, `resetBootHooks`, `resetRateLimiters`, `resetSharedRateLimitStorage`, `resolveDashboardAccess`, `resolveRouteModel`, `route`, `routeModelBindings`, `routeParams`, `runBootHooks`, `runHealthProbes`, `runWithRequest`, `safePathParam`, `sanitizePathParam`, `scaledLimit`, `serve`, `serverResponse`, `setCurrentRequest`, `setRouteModelFallback`, `sharedRateLimitStorage`, `signUrl`, `signedUrl`, `stream`, `trackQuery`, `trustedProxies`, `url`, `useRateLimitStorage`, `verifySignedUrl`, `verifySignedUrlMiddleware`, `warnOnMultipleRouterInstances`, `withTraceId`, `wrapAction`.
|
|
723
723
|
|
|
724
|
-
Local source modules: [src/api-shape.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/api-shape.ts), [src/body.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/body.ts), [src/dashboard-access.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/dashboard-access.ts), [src/encrypted-session-store.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/encrypted-session-store.ts), [src/error-handler.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/error-handler.ts), [src/health.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/health.ts), [src/middleware.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/middleware.ts), [src/path-sanitize.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/path-sanitize.ts), [src/rate-limit.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/rate-limit.ts), [src/request-augmentation.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/request-augmentation.ts), [src/request-context.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/request-context.ts), [src/route-loader.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/route-loader.ts), [src/route-model-binding.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/route-model-binding.ts), [src/security-settings.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/security-settings.ts), [src/session-factory.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/session-factory.ts), [src/signed-url.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/signed-url.ts), [src/stacks-router.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/stacks-router.ts), [src/typed-router.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/typed-router.ts).
|
|
724
|
+
Local source modules: [src/api-shape.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/api-shape.ts), [src/body.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/body.ts), [src/dashboard-access.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/dashboard-access.ts), [src/encrypted-session-store.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/encrypted-session-store.ts), [src/error-handler.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/error-handler.ts), [src/health.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/health.ts), [src/json.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/json.ts), [src/middleware.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/middleware.ts), [src/path-sanitize.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/path-sanitize.ts), [src/rate-limit.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/rate-limit.ts), [src/request-augmentation.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/request-augmentation.ts), [src/request-context.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/request-context.ts), [src/route-loader.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/route-loader.ts), [src/route-model-binding.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/route-model-binding.ts), [src/security-settings.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/security-settings.ts), [src/session-factory.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/session-factory.ts), [src/signed-url.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/signed-url.ts), [src/stacks-router.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/stacks-router.ts), [src/typed-router.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/typed-router.ts).
|
|
725
725
|
|
|
726
|
-
Evidence directory: [
|
|
726
|
+
Evidence directory: [92 retained tests](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/tests). These files are evidence pointers, not a claim that all tests were run for this catalog.
|
|
727
727
|
|
|
728
728
|
### @stacksjs/scheduler
|
|
729
729
|
|
|
@@ -851,7 +851,7 @@ Read the entrypoint and package export map for re-exported or type-only surfaces
|
|
|
851
851
|
|
|
852
852
|
Local source modules: [src/console.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/testing/src/console.ts), [src/disposable-database.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/testing/src/disposable-database.ts), [src/events.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/testing/src/events.ts), [src/feature.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/testing/src/feature.ts), [src/isolated.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/testing/src/isolated.ts), [src/mail.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/testing/src/mail.ts), [src/time.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/testing/src/time.ts).
|
|
853
853
|
|
|
854
|
-
Evidence directory: [
|
|
854
|
+
Evidence directory: [17 retained tests](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/testing/tests). These files are evidence pointers, not a claim that all tests were run for this catalog.
|
|
855
855
|
|
|
856
856
|
### @stacksjs/tinker
|
|
857
857
|
|
|
@@ -385,10 +385,24 @@ single-process HTTP transport; it does not initialize Redis or a cluster.
|
|
|
385
385
|
|
|
386
386
|
`createBroadcastResponse({ channels, authorize, signal })` returns an SSE Response.
|
|
387
387
|
Select channel names on the server. Authorization is mandatory and runs before
|
|
388
|
-
subscription, before each event, and at every heartbeat.
|
|
389
|
-
|
|
388
|
+
subscription, before each event, and at every heartbeat. The callback retains the
|
|
389
|
+
subscriber's async context even when another request broadcasts. It must still
|
|
390
|
+
resolve current credentials, grants and expiry on every call; context binding
|
|
391
|
+
does not freeze authorization facts. Pass the request's abort signal. Cancellation, failed authorization and slow consumers remove the hook.
|
|
390
392
|
Streams bound both queued events and pending authorization work (64 by default).
|
|
391
393
|
|
|
394
|
+
Optional `onEnqueue(chunk, broadcast)` runs after successful native enqueue with
|
|
395
|
+
the exact queued Uint8Array and original `{ channel, event, data }` metadata.
|
|
396
|
+
Connected/heartbeat metadata is null. Do not mutate the chunk. This observes
|
|
397
|
+
local queue admission, not remote receipt or reader demand. Optional `onClose()`
|
|
398
|
+
runs once after removing the subscription, heartbeat and abort listener. These
|
|
399
|
+
callbacks are captured before initial authorization awaits, keep the subscriber's
|
|
400
|
+
async context and preserve their options receiver. They run synchronously;
|
|
401
|
+
enqueue observer throws or accidental promise rejections close the stream.
|
|
402
|
+
Close observer failures are contained. Initial unauthorized responses create no
|
|
403
|
+
subscription and do not notify close. The optional hooks leave wire bytes,
|
|
404
|
+
authorization, capacity and existing callers unchanged.
|
|
405
|
+
|
|
392
406
|
STX's `useBroadcastStream({ request, endpoint, onMessage, onConnected })` makes
|
|
393
407
|
fresh authenticated requests using the application's injected transport, reconnects
|
|
394
408
|
with backoff, and cancels on `close()`. Re-read durable state in `onConnected`;
|
|
@@ -98,6 +98,14 @@ route.group({ prefix: '/api/v1', middleware: ['auth', 'throttle'] }, () => {
|
|
|
98
98
|
- Action object: an imported action, passed directly — see typed routes below
|
|
99
99
|
- Controller: `'Controllers/UserController@index'` — calls controller method
|
|
100
100
|
|
|
101
|
+
Generated Action registries keep their source `.ts` targets. For current
|
|
102
|
+
`app/Actions/` files, the loader uses a colocated regular `.js` file only when
|
|
103
|
+
the exact source target is absent. An existing source always wins, including
|
|
104
|
+
when its import fails. Nested Actions and app overrides follow the same rule.
|
|
105
|
+
Packaged defaults, controllers and middleware keep their own resolution.
|
|
106
|
+
This supports native app-build output; it does not qualify a complete server
|
|
107
|
+
image or Docker deployment.
|
|
108
|
+
|
|
101
109
|
## The strings are typed
|
|
102
110
|
|
|
103
111
|
Action paths, middleware aliases and route names are all checked at compile
|
|
@@ -249,6 +249,11 @@ expect(pageAuditClean(report)).toBe(true) // no duplicate /api/ requests, failed
|
|
|
249
249
|
live-reload stream (`*/_stx/hmr*`) with a day-long retry so a save mid-run cannot reload the
|
|
250
250
|
page, accepts JavaScript dialogs and records them in `errors`, removes "HeadlessChrome" from the
|
|
251
251
|
user agent, and passes `--use-mock-keychain`. `profile` keeps one profile across relaunches.
|
|
252
|
+
- **One Chrome per process, a browser context per `launch()`**: same executable, headless mode
|
|
253
|
+
and `args` share the process; each launch gets its own cookies, storage, cache and service
|
|
254
|
+
workers (`Network.clearBrowserCookies` clears only its own). `close()` disposes the context and
|
|
255
|
+
the Chrome lingers 1.5 s for the next launch; `closeSharedBrowsers()` stops it now. `profile`,
|
|
256
|
+
`shared: false` or `STACKS_BROWSER_SHARED=0` get a Chrome of their own.
|
|
252
257
|
- **Pausing requests next to live reload.** Chrome keeps one `Fetch.enable` pattern set per
|
|
253
258
|
session (a second call replaces it, `Fetch.disable` drops all) and sends every paused request to
|
|
254
259
|
every listener, so the session layers them. `await cdp.intercept([{ urlPattern: '*/api/slow*' }],
|
|
@@ -20,16 +20,78 @@ import { HQ_READ_UNAVAILABLE, readThroughProvider, resolveDashboardDriver } from
|
|
|
20
20
|
*/
|
|
21
21
|
|
|
22
22
|
/**
|
|
23
|
-
* The
|
|
23
|
+
* The shapes the Errors section renders.
|
|
24
24
|
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
25
|
+
* These used to be derived from the local store:
|
|
26
|
+
*
|
|
27
|
+
* export type DashboardErrorRecord = NonNullable<Awaited<ReturnType<typeof errors.fetchById>>>
|
|
28
|
+
*
|
|
29
|
+
* which made the contract whatever `@stacksjs/commerce`'s ORM row happened to
|
|
30
|
+
* be. That is fine while the only provider IS the commerce store, and wrong
|
|
31
|
+
* the moment a second one exists: a remote provider has to be told what to
|
|
32
|
+
* serve, and "whatever a shopping package's table looks like this week" is
|
|
33
|
+
* not something anyone can be told (stacksjs/stacks#2921).
|
|
34
|
+
*
|
|
35
|
+
* Declared here instead, so the section's contract is a decision rather than
|
|
36
|
+
* a consequence. Field names are deliberately the ones already on the wire -
|
|
37
|
+
* these actions serialize straight to JSON and the dashboard reads
|
|
38
|
+
* `first_seen`, `last_seen` and `last_24h` today, so renaming them to
|
|
39
|
+
* camelCase would be a breaking change to a shipped response rather than the
|
|
40
|
+
* decoupling this is for.
|
|
29
41
|
*/
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
export type
|
|
42
|
+
|
|
43
|
+
/** Where a grouped error sits in the triage workflow. */
|
|
44
|
+
export type DashboardErrorStatus = 'unresolved' | 'resolved' | 'ignored'
|
|
45
|
+
|
|
46
|
+
export interface DashboardErrorRecord {
|
|
47
|
+
/**
|
|
48
|
+
* Opaque. A number from the local store's autoincrement, a string from a
|
|
49
|
+
* hosted one - bughq's issue ids are varchar (stacksjs/stacks#2915).
|
|
50
|
+
* Compare with `String(a.id) === String(b.id)` rather than `===`.
|
|
51
|
+
*/
|
|
52
|
+
id: string | number
|
|
53
|
+
type: string
|
|
54
|
+
message: string
|
|
55
|
+
stack: string | null
|
|
56
|
+
/**
|
|
57
|
+
* The HTTP status the error reported, and only that.
|
|
58
|
+
*
|
|
59
|
+
* It used to be overloaded: `resolveError` and `ignoreError` wrote 1 and 2
|
|
60
|
+
* into this column to mean resolved and ignored, which destroyed the status
|
|
61
|
+
* and meant a seeded error could never read as resolved. Split in
|
|
62
|
+
* stacksjs/stacks#2923; triage is `resolution` below.
|
|
63
|
+
*/
|
|
64
|
+
status: number | null
|
|
65
|
+
/** Where this error sits in triage. */
|
|
66
|
+
resolution: DashboardErrorStatus
|
|
67
|
+
/** Free text. Nothing in the dashboard reads it; it is carried, not shown. */
|
|
68
|
+
additional_info: string | null
|
|
69
|
+
created_at: string
|
|
70
|
+
updated_at: string | null
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export interface DashboardGroupedError {
|
|
74
|
+
/** Opaque, as on {@link DashboardErrorRecord}. */
|
|
75
|
+
id: string | number
|
|
76
|
+
type: string
|
|
77
|
+
message: string
|
|
78
|
+
stack: string | null
|
|
79
|
+
/** The triage state, unlike `status` on a single record. See above. */
|
|
80
|
+
status: DashboardErrorStatus
|
|
81
|
+
count: number
|
|
82
|
+
first_seen: string
|
|
83
|
+
last_seen: string
|
|
84
|
+
error_ids: number[]
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
export interface DashboardErrorStats {
|
|
88
|
+
total: number
|
|
89
|
+
unresolved: number
|
|
90
|
+
resolved: number
|
|
91
|
+
ignored: number
|
|
92
|
+
last_24h: number
|
|
93
|
+
trend: number
|
|
94
|
+
}
|
|
33
95
|
|
|
34
96
|
export interface DashboardErrorTimelinePoint {
|
|
35
97
|
hour: string
|
|
@@ -41,7 +103,7 @@ export interface DashboardErrorsProvider {
|
|
|
41
103
|
stats: () => Promise<DashboardErrorStats>
|
|
42
104
|
timeline: () => Promise<DashboardErrorTimelinePoint[]>
|
|
43
105
|
byGroup: (type: string, message: string) => Promise<DashboardErrorRecord[]>
|
|
44
|
-
byId: (id: number) => Promise<DashboardErrorRecord | undefined>
|
|
106
|
+
byId: (id: string | number) => Promise<DashboardErrorRecord | undefined>
|
|
45
107
|
}
|
|
46
108
|
|
|
47
109
|
/** Wraps a payload with the reason its section is empty. */
|
|
@@ -54,12 +116,67 @@ export type DashboardErrorsEnvelope<T> = { data: T } & Partial<DashboardProvider
|
|
|
54
116
|
* adding one here would convert today's error response into a misleading empty
|
|
55
117
|
* list, which is a behaviour change rather than the refactor this is meant to be.
|
|
56
118
|
*/
|
|
119
|
+
const ERROR_STATUSES: readonly DashboardErrorStatus[] = ['unresolved', 'resolved', 'ignored']
|
|
120
|
+
|
|
121
|
+
/**
|
|
122
|
+
* Narrow the store's `status` onto the three states the section renders.
|
|
123
|
+
*
|
|
124
|
+
* `fetchGrouped` types this as `string` while deriving it from exactly those
|
|
125
|
+
* three labels, so the widening is incidental. An unknown value reads as
|
|
126
|
+
* unresolved, which is the store's own default for a status it cannot
|
|
127
|
+
* interpret, and is the safe direction: an error wrongly shown as needing
|
|
128
|
+
* attention is noticed, one wrongly shown as handled is not.
|
|
129
|
+
*/
|
|
130
|
+
function toErrorStatus(value: string): DashboardErrorStatus {
|
|
131
|
+
return ERROR_STATUSES.includes(value as DashboardErrorStatus)
|
|
132
|
+
? value as DashboardErrorStatus
|
|
133
|
+
: 'unresolved'
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
/**
|
|
137
|
+
* The commerce row, as the section's contract.
|
|
138
|
+
*
|
|
139
|
+
* Written out rather than passed through. Every field here is currently an
|
|
140
|
+
* identity, and saying so explicitly is the point: when the store's shape
|
|
141
|
+
* next moves, this file stops compiling instead of quietly changing what a
|
|
142
|
+
* remote provider is required to match.
|
|
143
|
+
*/
|
|
144
|
+
function toGroupedError(row: Awaited<ReturnType<typeof errors.fetchGrouped>>[number]): DashboardGroupedError {
|
|
145
|
+
return {
|
|
146
|
+
id: row.id,
|
|
147
|
+
type: row.type,
|
|
148
|
+
message: row.message,
|
|
149
|
+
stack: row.stack,
|
|
150
|
+
status: toErrorStatus(row.status),
|
|
151
|
+
count: row.count,
|
|
152
|
+
first_seen: row.first_seen,
|
|
153
|
+
last_seen: row.last_seen,
|
|
154
|
+
error_ids: row.error_ids,
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
/**
|
|
159
|
+
* The local store's id for a requested one, or undefined when it cannot have it.
|
|
160
|
+
*
|
|
161
|
+
* Its ids are an autoincrement, so a non-integer id is not one of its rows
|
|
162
|
+
* rather than a bad request, and the caller answers 404. Route params arrive
|
|
163
|
+
* as strings even when the id is a number, which is why a numeric string is
|
|
164
|
+
* accepted (stacksjs/stacks#2915).
|
|
165
|
+
*/
|
|
166
|
+
export function localErrorId(id: string | number): number | undefined {
|
|
167
|
+
const numeric = typeof id === 'number' ? id : Number.parseInt(String(id), 10)
|
|
168
|
+
return Number.isInteger(numeric) ? numeric : undefined
|
|
169
|
+
}
|
|
170
|
+
|
|
57
171
|
export const localErrorsProvider: DashboardErrorsProvider = {
|
|
58
|
-
grouped: () => errors.fetchGrouped(),
|
|
172
|
+
grouped: async () => (await errors.fetchGrouped()).map(toGroupedError),
|
|
59
173
|
stats: () => errors.fetchStats(),
|
|
60
174
|
timeline: () => errors.fetchTimeline(),
|
|
61
175
|
byGroup: (type, message) => errors.fetchByGroup(type, message),
|
|
62
|
-
byId: id =>
|
|
176
|
+
byId: async (id) => {
|
|
177
|
+
const numeric = localErrorId(id)
|
|
178
|
+
return numeric === undefined ? undefined : errors.fetchById(numeric)
|
|
179
|
+
},
|
|
63
180
|
}
|
|
64
181
|
|
|
65
182
|
/**
|
|
@@ -125,6 +242,6 @@ export function readErrorsByGroup(type: string, message: string): Promise<Dashbo
|
|
|
125
242
|
return readErrors([], provider => provider.byGroup(type, message), Array.isArray)
|
|
126
243
|
}
|
|
127
244
|
|
|
128
|
-
export function readErrorById(id: number): Promise<DashboardErrorsEnvelope<DashboardErrorRecord | undefined>> {
|
|
245
|
+
export function readErrorById(id: string | number): Promise<DashboardErrorsEnvelope<DashboardErrorRecord | undefined>> {
|
|
129
246
|
return readErrors<DashboardErrorRecord | undefined>(undefined, provider => provider.byId(id), () => true)
|
|
130
247
|
}
|
package/app/Models/Error.ts
CHANGED
|
@@ -52,6 +52,16 @@ export default defineModel({
|
|
|
52
52
|
factory: faker => faker.system.filePath(),
|
|
53
53
|
},
|
|
54
54
|
|
|
55
|
+
/**
|
|
56
|
+
* The HTTP status the error carried, and only that.
|
|
57
|
+
*
|
|
58
|
+
* It used to mean two things: the factory seeds an HTTP status while
|
|
59
|
+
* `resolveGroup` wrote 1 and `ignoreGroup` wrote 2 into the same column
|
|
60
|
+
* to mean resolved and ignored. So resolving an error destroyed its
|
|
61
|
+
* status, and a seeded error could never read as resolved because no
|
|
62
|
+
* factory row is ever 1 (stacksjs/stacks#2923). Triage now lives in
|
|
63
|
+
* `resolution`.
|
|
64
|
+
*/
|
|
55
65
|
status: {
|
|
56
66
|
fillable: true,
|
|
57
67
|
validation: {
|
|
@@ -63,6 +73,17 @@ export default defineModel({
|
|
|
63
73
|
factory: faker => faker.number.int({ min: 400, max: 500 }),
|
|
64
74
|
},
|
|
65
75
|
|
|
76
|
+
/** Where this error sits in triage. Separate from `status`, see above. */
|
|
77
|
+
resolution: {
|
|
78
|
+
required: true,
|
|
79
|
+
fillable: true,
|
|
80
|
+
default: 'unresolved',
|
|
81
|
+
validation: {
|
|
82
|
+
rule: schema.enum(['unresolved', 'resolved', 'ignored']),
|
|
83
|
+
},
|
|
84
|
+
factory: () => 'unresolved',
|
|
85
|
+
},
|
|
86
|
+
|
|
66
87
|
additional_info: {
|
|
67
88
|
fillable: true,
|
|
68
89
|
validation: {
|
package/ide/vscode/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"publisher": "Stacks",
|
|
3
3
|
"name": "vscode-stacks",
|
|
4
4
|
"displayName": "Stacks",
|
|
5
|
-
"version": "0.75.
|
|
5
|
+
"version": "0.75.237",
|
|
6
6
|
"description": "Stacks, built into VS Code: stx templates, pickier linting and formatting, encrypted env files, the dev server preview and every buddy command. No other extensions required.",
|
|
7
7
|
"license": "MIT",
|
|
8
8
|
"funding": "https://github.com/sponsors/chrisbbreuer",
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@stacksjs/defaults",
|
|
3
3
|
"type": "module",
|
|
4
4
|
"sideEffects": false,
|
|
5
|
-
"version": "0.75.
|
|
5
|
+
"version": "0.75.237",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
8
8
|
"url": "git+https://github.com/stacksjs/stacks.git",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"dependencies": {
|
|
45
45
|
"@iconify-json/f7": "^1.2.2",
|
|
46
46
|
"@iconify-json/hugeicons": "^1.2.35",
|
|
47
|
-
"@stacksjs/mobile": "0.75.
|
|
47
|
+
"@stacksjs/mobile": "0.75.237",
|
|
48
48
|
"@stacksjs/sanitizer": "^0.2.534",
|
|
49
49
|
"@xterm/addon-fit": "^0.11.0",
|
|
50
50
|
"@xterm/xterm": "^6.0.0",
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
<script client>
|
|
2
|
+
/**
|
|
3
|
+
* The centred card the signed-out auth pages sit in.
|
|
4
|
+
*
|
|
5
|
+
* Login, Register, ForgotPassword and ResetPassword each carried this
|
|
6
|
+
* markup (stacksjs/stacks#2917): the same full-height centring, the same
|
|
7
|
+
* 24rem column, the same logo tile, and the same heading pair. They differ
|
|
8
|
+
* only in what goes below it, which is the slot.
|
|
9
|
+
*
|
|
10
|
+
* Four pages the user moves between in one flow is the worst place for a
|
|
11
|
+
* shell to drift, because the drift is visible as a jump between steps.
|
|
12
|
+
*/
|
|
13
|
+
const title = useReactiveProp('title', '')
|
|
14
|
+
const subtitle = useReactiveProp('subtitle', '')
|
|
15
|
+
</script>
|
|
16
|
+
|
|
17
|
+
<div class="flex items-center justify-center px-4 py-12 min-h-screen">
|
|
18
|
+
<div class="max-w-sm w-full">
|
|
19
|
+
<div class="mb-8 text-center">
|
|
20
|
+
<div class="inline-flex items-center justify-center mb-4 h-12 w-12 bg-gradient-to-br from-blue-500 to-blue-600 rounded-xl shadow-blue-500/25 shadow-lg">
|
|
21
|
+
<span class="h-7 w-7 text-white i-hugeicons-cube"></span>
|
|
22
|
+
</div>
|
|
23
|
+
<h1 class="font-semibold text-2xl text-neutral-900 dark:text-white">{{ title() }}</h1>
|
|
24
|
+
<p class="mt-2 text-neutral-500 text-sm dark:text-neutral-400">{{ subtitle() }}</p>
|
|
25
|
+
</div>
|
|
26
|
+
|
|
27
|
+
<slot />
|
|
28
|
+
</div>
|
|
29
|
+
</div>
|