@shivaedev/work-board 0.14.1 → 0.15.0
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/CHANGELOG.md +26 -0
- package/README.md +1 -1
- package/assets/agent.js +1 -1
- package/assets/native.js +25 -25
- package/assets/react.js +38 -37
- package/dist/browser/diagnostics/schema.d.ts +15 -12
- package/dist/browser/diagnostics/schema.d.ts.map +1 -1
- package/dist/browser/diagnostics/schema.js +12 -2
- package/dist/browser/diagnostics/schema.js.map +1 -1
- package/dist/browser/views/remaining.d.ts +20 -12
- package/dist/browser/views/remaining.d.ts.map +1 -1
- package/dist/client/client.d.ts +1 -0
- package/dist/client/client.d.ts.map +1 -1
- package/dist/client/client.js +1 -1
- package/dist/client/client.js.map +1 -1
- package/dist/client/formStatus.d.ts +12 -0
- package/dist/client/formStatus.d.ts.map +1 -0
- package/dist/client/formStatus.js +27 -0
- package/dist/client/formStatus.js.map +1 -0
- package/dist/client/react/BoardShell.d.ts.map +1 -1
- package/dist/client/react/BoardShell.js +15 -21
- package/dist/client/react/BoardShell.js.map +1 -1
- package/dist/client/react/DocumentContext.d.ts.map +1 -1
- package/dist/client/react/DocumentContext.js +6 -3
- package/dist/client/react/DocumentContext.js.map +1 -1
- package/dist/client/react/FormContext.d.ts +5 -0
- package/dist/client/react/FormContext.d.ts.map +1 -0
- package/dist/client/react/FormContext.js +10 -0
- package/dist/client/react/FormContext.js.map +1 -0
- package/dist/client/react/LiveControls.d.ts +4 -3
- package/dist/client/react/LiveControls.d.ts.map +1 -1
- package/dist/client/react/LiveControls.js +5 -19
- package/dist/client/react/LiveControls.js.map +1 -1
- package/dist/client/react/MainLocationContext.d.ts +3 -0
- package/dist/client/react/MainLocationContext.d.ts.map +1 -0
- package/dist/client/react/MainLocationContext.js +7 -0
- package/dist/client/react/MainLocationContext.js.map +1 -0
- package/dist/client/react/ProjectionFrame.d.ts +1 -2
- package/dist/client/react/ProjectionFrame.d.ts.map +1 -1
- package/dist/client/react/ProjectionFrame.js +10 -4
- package/dist/client/react/ProjectionFrame.js.map +1 -1
- package/dist/client/react/ReadingLibrary.d.ts.map +1 -1
- package/dist/client/react/ReadingLibrary.js +7 -8
- package/dist/client/react/ReadingLibrary.js.map +1 -1
- package/dist/client/react/SystemPage.d.ts.map +1 -1
- package/dist/client/react/SystemPage.js +2 -1
- package/dist/client/react/SystemPage.js.map +1 -1
- package/dist/client/react/TodayOptions.d.ts.map +1 -1
- package/dist/client/react/TodayOptions.js +23 -14
- package/dist/client/react/TodayOptions.js.map +1 -1
- package/dist/client/react/VisualViewer.d.ts.map +1 -1
- package/dist/client/react/VisualViewer.js +6 -5
- package/dist/client/react/VisualViewer.js.map +1 -1
- package/dist/client/react/boardRouter.d.ts +3 -2
- package/dist/client/react/boardRouter.d.ts.map +1 -1
- package/dist/client/react/boardRouter.js +2 -1
- package/dist/client/react/boardRouter.js.map +1 -1
- package/dist/client/react/createResponse.d.ts +32 -4
- package/dist/client/react/createResponse.d.ts.map +1 -1
- package/dist/client/react/createResponse.js +7 -28
- package/dist/client/react/createResponse.js.map +1 -1
- package/dist/client/react/diagnosticsValues.d.ts.map +1 -1
- package/dist/client/react/diagnosticsValues.js +5 -7
- package/dist/client/react/diagnosticsValues.js.map +1 -1
- package/dist/client/react/entry.d.ts.map +1 -1
- package/dist/client/react/entry.js +2 -34
- package/dist/client/react/entry.js.map +1 -1
- package/dist/client/react/githubLimited.d.ts +3 -0
- package/dist/client/react/githubLimited.d.ts.map +1 -0
- package/dist/client/react/githubLimited.js +4 -0
- package/dist/client/react/githubLimited.js.map +1 -0
- package/dist/client/react/loadProjection.d.ts +135 -135
- package/dist/client/react/loadRemaining.d.ts +37 -29
- package/dist/client/react/loadRemaining.d.ts.map +1 -1
- package/dist/client/react/mainLocation.d.ts +4 -2
- package/dist/client/react/mainLocation.d.ts.map +1 -1
- package/dist/client/react/mainLocation.js +1 -8
- package/dist/client/react/mainLocation.js.map +1 -1
- package/dist/client/react/mountBoard.d.ts +3 -0
- package/dist/client/react/mountBoard.d.ts.map +1 -0
- package/dist/client/react/mountBoard.js +45 -0
- package/dist/client/react/mountBoard.js.map +1 -0
- package/dist/client/react/navigationLocation.d.ts +1 -1
- package/dist/client/react/navigationLocation.d.ts.map +1 -1
- package/dist/client/react/navigationLocation.js +1 -1
- package/dist/client/react/navigationLocation.js.map +1 -1
- package/dist/client/react/retryPage.d.ts +2 -1
- package/dist/client/react/retryPage.d.ts.map +1 -1
- package/dist/client/react/retryPage.js +3 -4
- package/dist/client/react/retryPage.js.map +1 -1
- package/dist/client/react/useBoardNavigation.d.ts.map +1 -1
- package/dist/client/react/useBoardNavigation.js +18 -8
- package/dist/client/react/useBoardNavigation.js.map +1 -1
- package/dist/client/react/useDocumentPage.d.ts +1 -1
- package/dist/client/react/useDocumentPage.d.ts.map +1 -1
- package/dist/client/react/useDocumentPage.js +9 -6
- package/dist/client/react/useDocumentPage.js.map +1 -1
- package/dist/client/react/useHandoffForm.d.ts +56 -30
- package/dist/client/react/useHandoffForm.d.ts.map +1 -1
- package/dist/client/react/useHandoffForm.js +19 -30
- package/dist/client/react/useHandoffForm.js.map +1 -1
- package/dist/client/react/useResponseForm.d.ts +72 -43
- package/dist/client/react/useResponseForm.d.ts.map +1 -1
- package/dist/client/react/useResponseForm.js +20 -17
- package/dist/client/react/useResponseForm.js.map +1 -1
- package/dist/client/react/visualSources.d.ts.map +1 -1
- package/dist/client/react/visualSources.js +10 -8
- package/dist/client/react/visualSources.js.map +1 -1
- package/dist/client/saveFailure.d.ts +8 -0
- package/dist/client/saveFailure.d.ts.map +1 -0
- package/dist/client/saveFailure.js +8 -0
- package/dist/client/saveFailure.js.map +1 -0
- package/dist/diagnostics/daemonContract.d.ts +65 -38
- package/dist/diagnostics/daemonContract.d.ts.map +1 -1
- package/dist/diagnostics/daemonContract.js +2 -1
- package/dist/diagnostics/daemonContract.js.map +1 -1
- package/dist/diagnostics/health.d.ts +10 -0
- package/dist/diagnostics/health.d.ts.map +1 -1
- package/dist/diagnostics/health.js +2 -0
- package/dist/diagnostics/health.js.map +1 -1
- package/dist/diagnostics/source.d.ts +55 -36
- package/dist/diagnostics/source.d.ts.map +1 -1
- package/dist/diagnostics/source.js +1 -2
- package/dist/diagnostics/source.js.map +1 -1
- package/dist/rpc/contract.d.ts +60 -36
- package/dist/rpc/contract.d.ts.map +1 -1
- package/dist/rpc/handoffContract.d.ts +8 -8
- package/dist/server/diagnostics/daemon.d.ts +41 -25
- package/dist/server/diagnostics/daemon.d.ts.map +1 -1
- package/dist/server/diagnostics/fleetHealth.d.ts +10 -0
- package/dist/server/diagnostics/fleetHealth.d.ts.map +1 -1
- package/dist/server/diagnostics/githubLimits.d.ts +12 -13
- package/dist/server/diagnostics/githubLimits.d.ts.map +1 -1
- package/dist/server/diagnostics/githubLimits.js +6 -6
- package/dist/server/diagnostics/githubLimits.js.map +1 -1
- package/dist/server/integration/diagnostics.d.ts +74 -38
- package/dist/server/integration/diagnostics.d.ts.map +1 -1
- package/dist/server/mcp/client.d.ts +589 -581
- package/dist/server/mcp/client.d.ts.map +1 -1
- package/dist/server/mcp/queries.d.ts +60 -36
- package/dist/server/mcp/queries.d.ts.map +1 -1
- package/dist/server/metadata/fields.js +1 -1
- package/dist/server/metadata/fields.js.map +1 -1
- package/dist/server/packageInfo.d.ts +1 -1
- package/dist/server/packageInfo.js +1 -1
- package/dist/server/views/remainingQueries.d.ts +20 -12
- package/dist/server/views/remainingQueries.d.ts.map +1 -1
- package/package.json +7 -6
- package/src/browser/diagnostics/schema.ts +12 -2
- package/src/client/client.ts +2 -1
- package/src/client/formStatus.ts +35 -0
- package/src/client/react/BoardShell.tsx +19 -26
- package/src/client/react/DocumentContext.tsx +6 -3
- package/src/client/react/FormContext.ts +13 -0
- package/src/client/react/LiveControls.tsx +5 -25
- package/src/client/react/MainLocationContext.ts +8 -0
- package/src/client/react/ProjectionFrame.tsx +13 -5
- package/src/client/react/ReadingLibrary.tsx +7 -8
- package/src/client/react/SystemPage.tsx +2 -1
- package/src/client/react/TodayOptions.tsx +40 -33
- package/src/client/react/VisualViewer.tsx +6 -6
- package/src/client/react/boardRouter.ts +3 -2
- package/src/client/react/createResponse.ts +10 -35
- package/src/client/react/diagnosticsValues.tsx +20 -12
- package/src/client/react/entry.tsx +2 -37
- package/src/client/react/githubLimited.ts +5 -0
- package/src/client/react/mainLocation.ts +5 -8
- package/src/client/react/mountBoard.tsx +49 -0
- package/src/client/react/navigationLocation.ts +2 -2
- package/src/client/react/retryPage.ts +4 -4
- package/src/client/react/useBoardNavigation.ts +20 -8
- package/src/client/react/useDocumentPage.ts +12 -6
- package/src/client/react/useHandoffForm.ts +25 -33
- package/src/client/react/useResponseForm.ts +20 -18
- package/src/client/react/visualSources.ts +10 -8
- package/src/client/saveFailure.ts +14 -0
- package/src/diagnostics/daemonContract.ts +2 -1
- package/src/diagnostics/health.ts +2 -0
- package/src/diagnostics/source.ts +1 -2
- package/src/server/diagnostics/githubLimits.ts +9 -11
- package/src/server/metadata/fields.ts +1 -1
- package/src/server/packageInfo.ts +1 -1
- package/dist/client/handoffs/failureStatus.d.ts +0 -2
- package/dist/client/handoffs/failureStatus.d.ts.map +0 -1
- package/dist/client/handoffs/failureStatus.js +0 -7
- package/dist/client/handoffs/failureStatus.js.map +0 -1
- package/dist/client/responses/failure.d.ts +0 -5
- package/dist/client/responses/failure.d.ts.map +0 -1
- package/dist/client/responses/failure.js +0 -13
- package/dist/client/responses/failure.js.map +0 -1
- package/dist/server/diagnostics/readCommand.d.ts +0 -4
- package/dist/server/diagnostics/readCommand.d.ts.map +0 -1
- package/dist/server/diagnostics/readCommand.js +0 -20
- package/dist/server/diagnostics/readCommand.js.map +0 -1
- package/src/client/handoffs/failureStatus.ts +0 -6
- package/src/client/responses/failure.ts +0 -13
- package/src/server/diagnostics/readCommand.ts +0 -24
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../src/server/mcp/client.ts"],"names":[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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8KAElB;AACD,MAAM,MAAM,WAAW,GAAG,MAAM,CAAC,OAAO,CAAC,UAAU,CAAC,OAAO,UAAU,CAAC,CAAC,CAAC;AASxE,wBAAgB,SAAS,CAAC,CAAC,EAAE,CAAC,EAAE,SAAS,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,MAAM,EAAE,WAAW,KAAK,MAAM,CAAC,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,2CAkBpG"}
|
|
@@ -223,6 +223,16 @@ export declare const needsYou: (client: import("effect/rpc/RpcClient").RpcClient
|
|
|
223
223
|
readonly state: import("effect/Schema").Literal<"ready">;
|
|
224
224
|
readonly value: import("effect/Schema").Struct<{
|
|
225
225
|
readonly concurrency: import("effect/Schema").Int;
|
|
226
|
+
readonly github: import("effect/Schema").optional<import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
227
|
+
readonly limit: import("effect/Schema").Int;
|
|
228
|
+
readonly limitedBy: import("effect/Schema").NullOr<import("effect/Schema").Literals<readonly ["rate-limit", "reserve"]>>;
|
|
229
|
+
readonly limitedUntil: import("effect/Schema").NullOr<import("effect/Schema").Number>;
|
|
230
|
+
readonly observedAt: import("effect/Schema").Number;
|
|
231
|
+
readonly remaining: import("effect/Schema").Int;
|
|
232
|
+
readonly reset: import("effect/Schema").Int;
|
|
233
|
+
readonly resource: import("effect/Schema").String;
|
|
234
|
+
readonly used: import("effect/Schema").Int;
|
|
235
|
+
}>>>;
|
|
226
236
|
readonly lastCapacityRejection: import("effect/Schema").NullOr<import("effect/Schema").Struct<{
|
|
227
237
|
readonly at: import("effect/Schema").Number;
|
|
228
238
|
readonly cause: import("effect/Schema").String;
|
|
@@ -247,18 +257,16 @@ export declare const needsYou: (client: import("effect/rpc/RpcClient").RpcClient
|
|
|
247
257
|
readonly github: import("effect/Schema").Union<readonly [import("effect/Schema").Struct<{
|
|
248
258
|
readonly observedAt: import("effect/Schema").Number;
|
|
249
259
|
readonly state: import("effect/Schema").Literal<"ready">;
|
|
250
|
-
readonly value: import("effect/Schema").Struct<{
|
|
251
|
-
readonly
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
readonly
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
}>;
|
|
261
|
-
}>;
|
|
260
|
+
readonly value: import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
261
|
+
readonly limit: import("effect/Schema").Int;
|
|
262
|
+
readonly limitedBy: import("effect/Schema").NullOr<import("effect/Schema").Literals<readonly ["rate-limit", "reserve"]>>;
|
|
263
|
+
readonly limitedUntil: import("effect/Schema").NullOr<import("effect/Schema").Number>;
|
|
264
|
+
readonly observedAt: import("effect/Schema").Number;
|
|
265
|
+
readonly remaining: import("effect/Schema").Int;
|
|
266
|
+
readonly reset: import("effect/Schema").Int;
|
|
267
|
+
readonly resource: import("effect/Schema").String;
|
|
268
|
+
readonly used: import("effect/Schema").Int;
|
|
269
|
+
}>>;
|
|
262
270
|
}>, import("effect/Schema").Struct<{
|
|
263
271
|
readonly cause: import("effect/Schema").String;
|
|
264
272
|
readonly observedAt: import("effect/Schema").Number;
|
|
@@ -2267,6 +2275,16 @@ export declare const overview: (client: import("effect/rpc/RpcClient").RpcClient
|
|
|
2267
2275
|
readonly state: import("effect/Schema").Literal<"ready">;
|
|
2268
2276
|
readonly value: import("effect/Schema").Struct<{
|
|
2269
2277
|
readonly concurrency: import("effect/Schema").Int;
|
|
2278
|
+
readonly github: import("effect/Schema").optional<import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
2279
|
+
readonly limit: import("effect/Schema").Int;
|
|
2280
|
+
readonly limitedBy: import("effect/Schema").NullOr<import("effect/Schema").Literals<readonly ["rate-limit", "reserve"]>>;
|
|
2281
|
+
readonly limitedUntil: import("effect/Schema").NullOr<import("effect/Schema").Number>;
|
|
2282
|
+
readonly observedAt: import("effect/Schema").Number;
|
|
2283
|
+
readonly remaining: import("effect/Schema").Int;
|
|
2284
|
+
readonly reset: import("effect/Schema").Int;
|
|
2285
|
+
readonly resource: import("effect/Schema").String;
|
|
2286
|
+
readonly used: import("effect/Schema").Int;
|
|
2287
|
+
}>>>;
|
|
2270
2288
|
readonly lastCapacityRejection: import("effect/Schema").NullOr<import("effect/Schema").Struct<{
|
|
2271
2289
|
readonly at: import("effect/Schema").Number;
|
|
2272
2290
|
readonly cause: import("effect/Schema").String;
|
|
@@ -2291,18 +2309,16 @@ export declare const overview: (client: import("effect/rpc/RpcClient").RpcClient
|
|
|
2291
2309
|
readonly github: import("effect/Schema").Union<readonly [import("effect/Schema").Struct<{
|
|
2292
2310
|
readonly observedAt: import("effect/Schema").Number;
|
|
2293
2311
|
readonly state: import("effect/Schema").Literal<"ready">;
|
|
2294
|
-
readonly value: import("effect/Schema").Struct<{
|
|
2295
|
-
readonly
|
|
2296
|
-
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
|
|
2300
|
-
readonly
|
|
2301
|
-
|
|
2302
|
-
|
|
2303
|
-
|
|
2304
|
-
}>;
|
|
2305
|
-
}>;
|
|
2312
|
+
readonly value: import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
2313
|
+
readonly limit: import("effect/Schema").Int;
|
|
2314
|
+
readonly limitedBy: import("effect/Schema").NullOr<import("effect/Schema").Literals<readonly ["rate-limit", "reserve"]>>;
|
|
2315
|
+
readonly limitedUntil: import("effect/Schema").NullOr<import("effect/Schema").Number>;
|
|
2316
|
+
readonly observedAt: import("effect/Schema").Number;
|
|
2317
|
+
readonly remaining: import("effect/Schema").Int;
|
|
2318
|
+
readonly reset: import("effect/Schema").Int;
|
|
2319
|
+
readonly resource: import("effect/Schema").String;
|
|
2320
|
+
readonly used: import("effect/Schema").Int;
|
|
2321
|
+
}>>;
|
|
2306
2322
|
}>, import("effect/Schema").Struct<{
|
|
2307
2323
|
readonly cause: import("effect/Schema").String;
|
|
2308
2324
|
readonly observedAt: import("effect/Schema").Number;
|
|
@@ -4467,6 +4483,16 @@ export declare const item: (client: import("effect/rpc/RpcClient").RpcClient.Fla
|
|
|
4467
4483
|
readonly state: import("effect/Schema").Literal<"ready">;
|
|
4468
4484
|
readonly value: import("effect/Schema").Struct<{
|
|
4469
4485
|
readonly concurrency: import("effect/Schema").Int;
|
|
4486
|
+
readonly github: import("effect/Schema").optional<import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
4487
|
+
readonly limit: import("effect/Schema").Int;
|
|
4488
|
+
readonly limitedBy: import("effect/Schema").NullOr<import("effect/Schema").Literals<readonly ["rate-limit", "reserve"]>>;
|
|
4489
|
+
readonly limitedUntil: import("effect/Schema").NullOr<import("effect/Schema").Number>;
|
|
4490
|
+
readonly observedAt: import("effect/Schema").Number;
|
|
4491
|
+
readonly remaining: import("effect/Schema").Int;
|
|
4492
|
+
readonly reset: import("effect/Schema").Int;
|
|
4493
|
+
readonly resource: import("effect/Schema").String;
|
|
4494
|
+
readonly used: import("effect/Schema").Int;
|
|
4495
|
+
}>>>;
|
|
4470
4496
|
readonly lastCapacityRejection: import("effect/Schema").NullOr<import("effect/Schema").Struct<{
|
|
4471
4497
|
readonly at: import("effect/Schema").Number;
|
|
4472
4498
|
readonly cause: import("effect/Schema").String;
|
|
@@ -4491,18 +4517,16 @@ export declare const item: (client: import("effect/rpc/RpcClient").RpcClient.Fla
|
|
|
4491
4517
|
readonly github: import("effect/Schema").Union<readonly [import("effect/Schema").Struct<{
|
|
4492
4518
|
readonly observedAt: import("effect/Schema").Number;
|
|
4493
4519
|
readonly state: import("effect/Schema").Literal<"ready">;
|
|
4494
|
-
readonly value: import("effect/Schema").Struct<{
|
|
4495
|
-
readonly
|
|
4496
|
-
|
|
4497
|
-
|
|
4498
|
-
|
|
4499
|
-
|
|
4500
|
-
readonly
|
|
4501
|
-
|
|
4502
|
-
|
|
4503
|
-
|
|
4504
|
-
}>;
|
|
4505
|
-
}>;
|
|
4520
|
+
readonly value: import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
4521
|
+
readonly limit: import("effect/Schema").Int;
|
|
4522
|
+
readonly limitedBy: import("effect/Schema").NullOr<import("effect/Schema").Literals<readonly ["rate-limit", "reserve"]>>;
|
|
4523
|
+
readonly limitedUntil: import("effect/Schema").NullOr<import("effect/Schema").Number>;
|
|
4524
|
+
readonly observedAt: import("effect/Schema").Number;
|
|
4525
|
+
readonly remaining: import("effect/Schema").Int;
|
|
4526
|
+
readonly reset: import("effect/Schema").Int;
|
|
4527
|
+
readonly resource: import("effect/Schema").String;
|
|
4528
|
+
readonly used: import("effect/Schema").Int;
|
|
4529
|
+
}>>;
|
|
4506
4530
|
}>, import("effect/Schema").Struct<{
|
|
4507
4531
|
readonly cause: import("effect/Schema").String;
|
|
4508
4532
|
readonly observedAt: import("effect/Schema").Number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"queries.d.ts","sourceRoot":"","sources":["../../../src/server/mcp/queries.ts"],"names":[],"mappings":"AAAA,OAAO,EAAS,MAAM,EAAE,MAAM,QAAQ,CAAC;AAOvC,eAAO,MAAM,QAAQ
|
|
1
|
+
{"version":3,"file":"queries.d.ts","sourceRoot":"","sources":["../../../src/server/mcp/queries.ts"],"names":[],"mappings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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kUAef,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Option, Schema } from "effect";
|
|
2
2
|
import { Metadata } from "#metadata/schema.ts";
|
|
3
3
|
const addonOwners = {
|
|
4
|
-
fleet: ["fleet", "fleet-launch", "fleet-deliverable"],
|
|
4
|
+
fleet: ["fleet", "fleet-launch", "fleet-deliverable", "fleet-priority"],
|
|
5
5
|
};
|
|
6
6
|
const addonFields = new Set(Object.values(addonOwners).flat());
|
|
7
7
|
const schemas = new Map(Object.entries(Metadata.to.fields));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fields.js","sourceRoot":"","sources":["../../../src/server/metadata/fields.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AACxC,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAG/C,MAAM,WAAW,GAAgD;IAChE,KAAK,EAAE,CAAC,OAAO,EAAE,cAAc,EAAE,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"fields.js","sourceRoot":"","sources":["../../../src/server/metadata/fields.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EAAE,IAAI,EAAE,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,EAAE,OAAO,EAAE,iBAAiB,KAAK,qCAAqC,EAAE,CAAC,CAAC;YAC3H,SAAS;QACV,CAAC;QACD,MAAM,OAAO,GAAG,MAAM,CAAC,mBAAmB,CAAC,MAAM,EAAE,EAAE,gBAAgB,EAAE,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC;QACzF,IAAI,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,EAAE,CAAC;YAC5B,WAAW,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,EAAE,OAAO,EAAE,WAAW,KAAK,yDAAyD,EAAE,CAAC,CAAC;QAC1I,CAAC;aAAM,CAAC;YACP,MAAM,CAAC,GAAG,CAAC,GAAG,OAAO,CAAC,KAAK,CAAC;QAC7B,CAAC;IACF,CAAC;IACD,OAAO,EAAE,WAAW,EAAE,MAAM,EAAE,MAAM,CAAC,iBAAiB,CAAC,MAAM,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC;AAC3F,CAAC"}
|
|
@@ -25,6 +25,16 @@ export declare function remainingQueries({ changes, document, index, writable }:
|
|
|
25
25
|
}>;
|
|
26
26
|
fleet: import("#diagnostics/source.ts").Observation<{
|
|
27
27
|
readonly concurrency: number;
|
|
28
|
+
readonly github?: readonly {
|
|
29
|
+
readonly limit: number;
|
|
30
|
+
readonly limitedBy: "rate-limit" | "reserve" | null;
|
|
31
|
+
readonly limitedUntil: number | null;
|
|
32
|
+
readonly observedAt: number;
|
|
33
|
+
readonly remaining: number;
|
|
34
|
+
readonly reset: number;
|
|
35
|
+
readonly resource: string;
|
|
36
|
+
readonly used: number;
|
|
37
|
+
}[] | undefined;
|
|
28
38
|
readonly lastCapacityRejection: {
|
|
29
39
|
readonly at: number;
|
|
30
40
|
readonly cause: string;
|
|
@@ -41,18 +51,16 @@ export declare function remainingQueries({ changes, document, index, writable }:
|
|
|
41
51
|
readonly orchestrator: number;
|
|
42
52
|
};
|
|
43
53
|
}>;
|
|
44
|
-
github: import("#diagnostics/source.ts").Observation<{
|
|
45
|
-
readonly
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
readonly
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
};
|
|
55
|
-
}>;
|
|
54
|
+
github: import("#diagnostics/source.ts").Observation<readonly {
|
|
55
|
+
readonly limit: number;
|
|
56
|
+
readonly limitedBy: "rate-limit" | "reserve" | null;
|
|
57
|
+
readonly limitedUntil: number | null;
|
|
58
|
+
readonly observedAt: number;
|
|
59
|
+
readonly remaining: number;
|
|
60
|
+
readonly reset: number;
|
|
61
|
+
readonly resource: string;
|
|
62
|
+
readonly used: number;
|
|
63
|
+
}[]>;
|
|
56
64
|
};
|
|
57
65
|
}, never, never>;
|
|
58
66
|
handoff: (url: string) => Effect.Effect<{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remainingQueries.d.ts","sourceRoot":"","sources":["../../../src/server/views/remainingQueries.ts"],"names":[],"mappings":"AAAA,OAAO,EAAS,MAAM,EAAE,MAAM,QAAQ,CAAC;AAEvC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,6BAA6B,CAAC;AAInE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAEpE,wBAAgB,gBAAgB,CAC/B,EAAE,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,EAAE,cAAc,EACtD,QAAQ,EAAE;IACT,QAAQ,CAAC,WAAW,EAAE,OAAO,WAAW,CAAC,OAAO,CAAC;IACjD,QAAQ,CAAC,SAAS,EAAE,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;;;;;;;;;;;;;;;;;;;IAcrB,MAAM,QAAQ,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAapB,KAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAEN"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shivaedev/work-board",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.15.0",
|
|
4
4
|
"description": "Serve a folder of markdown files as a live local page that updates in place when a file changes",
|
|
5
5
|
"homepage": "https://github.com/ShivaeDev/platform/tree/main/packages/work-board#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -442,7 +442,7 @@
|
|
|
442
442
|
"dependencies": {
|
|
443
443
|
"@shivaedev/effect-contract": "0.5.1",
|
|
444
444
|
"@shivaedev/effect-service": "0.3.0",
|
|
445
|
-
"@shivaedev/platform": "0.14.
|
|
445
|
+
"@shivaedev/platform": "0.14.2",
|
|
446
446
|
"mdast-util-directive": "3.1.1",
|
|
447
447
|
"mermaid": "12.1.0",
|
|
448
448
|
"react": "19.3.0",
|
|
@@ -464,12 +464,13 @@
|
|
|
464
464
|
"@shivaedev/effect-form": "0.4.0",
|
|
465
465
|
"@shivaedev/effect-react": "0.4.1",
|
|
466
466
|
"@shivaedev/effect-test": "0.5.0",
|
|
467
|
-
"@shivaedev/quality": "0.
|
|
467
|
+
"@shivaedev/quality": "0.23.0",
|
|
468
|
+
"@shivaedev/test-story": "0.5.0",
|
|
468
469
|
"@tailwindcss/vite": "4.3.3",
|
|
469
470
|
"@tanstack/react-router": "1.170.41",
|
|
470
471
|
"@types/hast": "3.0.5",
|
|
471
472
|
"@types/mdast": "4.0.4",
|
|
472
|
-
"@types/node": "24.19.
|
|
473
|
+
"@types/node": "24.19.2",
|
|
473
474
|
"@types/react": "19.3.0",
|
|
474
475
|
"@types/react-dom": "19.3.0",
|
|
475
476
|
"@typescript/native": "npm:typescript@7.0.2",
|
|
@@ -479,11 +480,11 @@
|
|
|
479
480
|
"effect": "4.0.4",
|
|
480
481
|
"esbuild": "0.28.2",
|
|
481
482
|
"happy-dom": "20.14.6",
|
|
482
|
-
"lucide-react": "1.
|
|
483
|
+
"lucide-react": "1.55.0",
|
|
483
484
|
"tailwind-merge": "3.7.0",
|
|
484
485
|
"tailwindcss": "4.3.3",
|
|
485
486
|
"typescript": "npm:@typescript/typescript6@6.0.2",
|
|
486
|
-
"vite": "8.3.
|
|
487
|
+
"vite": "8.3.4",
|
|
487
488
|
"vitest": "5.0.3"
|
|
488
489
|
},
|
|
489
490
|
"peerDependencies": {
|
|
@@ -8,9 +8,19 @@ export type UsageWindow = typeof UsageWindow.Type;
|
|
|
8
8
|
export const CodexLimits = Schema.Struct({ primary: Schema.NullOr(UsageWindow), secondary: Schema.NullOr(UsageWindow) });
|
|
9
9
|
export type CodexLimits = typeof CodexLimits.Type;
|
|
10
10
|
const Count = Schema.Int.check(Schema.isGreaterThanOrEqualTo(0));
|
|
11
|
-
|
|
11
|
+
const Timestamp = Schema.Number.check(Schema.isFinite(), Schema.isGreaterThanOrEqualTo(0), Schema.isLessThanOrEqualTo(8_640_000_000_000_000));
|
|
12
|
+
export const GithubWindow = Schema.Struct({
|
|
13
|
+
limit: Count,
|
|
14
|
+
limitedBy: Schema.NullOr(Schema.Literals(["rate-limit", "reserve"])),
|
|
15
|
+
limitedUntil: Schema.NullOr(Timestamp),
|
|
16
|
+
observedAt: Timestamp,
|
|
17
|
+
remaining: Count,
|
|
18
|
+
reset: Count.check(Schema.isLessThanOrEqualTo(8_640_000_000_000)),
|
|
19
|
+
resource: Schema.String.check(Schema.isMinLength(1), Schema.isMaxLength(100)),
|
|
20
|
+
used: Count,
|
|
21
|
+
});
|
|
12
22
|
export type GithubWindow = typeof GithubWindow.Type;
|
|
13
|
-
export const GithubLimits = Schema.
|
|
23
|
+
export const GithubLimits = Schema.Array(GithubWindow).check(Schema.isMaxLength(50));
|
|
14
24
|
export type GithubLimits = typeof GithubLimits.Type;
|
|
15
25
|
|
|
16
26
|
export type Observation<A> =
|
package/src/client/client.ts
CHANGED
|
@@ -32,6 +32,7 @@ export interface BrowserClient {
|
|
|
32
32
|
readonly registry: AtomRegistry.AtomRegistry;
|
|
33
33
|
readonly responses: BoundContract<typeof responseContract>;
|
|
34
34
|
readonly run: <A, E>(effect: Effect.Effect<A, E, Reader>, signal?: AbortSignal) => Promise<A>;
|
|
35
|
+
readonly runtime: Atom.AtomRuntime<Reader>;
|
|
35
36
|
readonly updates: ReturnType<typeof live<Reader, InternalServerError | RpcClientError, never>>;
|
|
36
37
|
}
|
|
37
38
|
|
|
@@ -85,5 +86,5 @@ export function browserClient(url: string, options: ResumeOptions = {}): Browser
|
|
|
85
86
|
return result.success;
|
|
86
87
|
}
|
|
87
88
|
const responses = bind(responseContract, Client);
|
|
88
|
-
return { api, handoffs: bind(handoffContract, Client), mutate, read, registry, responses, run, updates };
|
|
89
|
+
return { api, handoffs: bind(handoffContract, Client), mutate, read, registry, responses, run, runtime: Client.runtime, updates };
|
|
89
90
|
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { Option } from "effect";
|
|
2
|
+
import type { SaveState } from "@shivaedev/effect-react/save-state.ts";
|
|
3
|
+
import { type SaveFailure, saveFailure } from "./saveFailure.ts";
|
|
4
|
+
|
|
5
|
+
export type DraftInteraction = "draft" | "cleared" | "submitted";
|
|
6
|
+
export function formStatus<A>(
|
|
7
|
+
state: Pick<SaveState<SaveFailure>, "saving" | "failure"> & { readonly created: Option.Option<A> },
|
|
8
|
+
interaction: DraftInteraction,
|
|
9
|
+
kind: "response" | "handoff",
|
|
10
|
+
saved: (value: A) => string,
|
|
11
|
+
): { readonly outcome: string | undefined; readonly text: string } {
|
|
12
|
+
if (state.saving) {
|
|
13
|
+
return {
|
|
14
|
+
outcome: "pending",
|
|
15
|
+
text: kind === "response" ? "Pending: registering reviewed context, then recording response…" : "Pending: preparing the local handoff file…",
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
if (interaction === "submitted") {
|
|
19
|
+
if (Option.isSome(state.failure)) {
|
|
20
|
+
return saveFailure(state.failure.value, kind);
|
|
21
|
+
}
|
|
22
|
+
if (Option.isSome(state.created)) {
|
|
23
|
+
return { outcome: "saved", text: saved(state.created.value) };
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
const ready = kind === "handoff" ? "Draft ready. Review and preview before preparing the file." : "";
|
|
27
|
+
return {
|
|
28
|
+
outcome: undefined,
|
|
29
|
+
text: interaction === "cleared" ? `Draft cleared. Saved ${kind === "response" ? "responses" : "handoffs"} are unchanged.` : ready,
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export function responseSaved(id: string, dirty: boolean) {
|
|
34
|
+
return `Saved: responses/${id}.md. This records feedback, not acceptance.${dirty ? " Your current draft remains unsaved." : ""}`;
|
|
35
|
+
}
|
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
import { useRouterState } from "@tanstack/react-router";
|
|
2
2
|
import { Option } from "effect";
|
|
3
3
|
import type * as AtomRegistry from "effect/reactivity/AtomRegistry";
|
|
4
|
-
import {
|
|
4
|
+
import { useEffect, useState } from "react";
|
|
5
5
|
import { useQuery } from "@shivaedev/effect-react/result-state.ts";
|
|
6
6
|
import type { BrowserClient } from "#client/client.ts";
|
|
7
7
|
import { navigationQuery } from "#client/page/routeQuery.ts";
|
|
8
8
|
import { AgeTicker } from "./Age.tsx";
|
|
9
9
|
import { FleetMain } from "./FleetMain.tsx";
|
|
10
|
+
import { FormContext } from "./FormContext.ts";
|
|
10
11
|
import { Header } from "./Header.tsx";
|
|
11
12
|
import { LiveControls } from "./LiveControls.tsx";
|
|
12
|
-
import {
|
|
13
|
+
import { MainLocationContext, useMainLocation } from "./MainLocationContext.ts";
|
|
14
|
+
import { emptyMainLocation, type MainLocation } from "./mainLocation.ts";
|
|
13
15
|
import { PhoneNavigation } from "./PhoneNavigation.tsx";
|
|
14
16
|
import { ReadingLibrary } from "./ReadingLibrary.tsx";
|
|
15
17
|
import { SearchDialog } from "./SearchDialog.tsx";
|
|
@@ -30,61 +32,51 @@ export interface ShellOptions {
|
|
|
30
32
|
readonly registry: AtomRegistry.AtomRegistry;
|
|
31
33
|
}
|
|
32
34
|
export function BoardShell(options: ShellOptions) {
|
|
33
|
-
const
|
|
35
|
+
const [main, onPage] = useState(emptyMainLocation);
|
|
36
|
+
return (
|
|
37
|
+
<MainLocationContext.Provider value={main}>
|
|
38
|
+
<BoardWorkspace {...options} onPage={onPage} />
|
|
39
|
+
</MainLocationContext.Provider>
|
|
40
|
+
);
|
|
41
|
+
}
|
|
42
|
+
function BoardWorkspace(options: ShellOptions & { readonly onPage: (location: MainLocation) => void }) {
|
|
43
|
+
const { api, ready, client, onPage } = options;
|
|
44
|
+
const main = useMainLocation();
|
|
34
45
|
const appearance = useAppearance();
|
|
35
46
|
const sidebar = useSidebar(appearance);
|
|
36
47
|
const status = useBoardNavigation(options);
|
|
37
48
|
const search = useSearchDialog();
|
|
38
49
|
const [libraryOpen, setLibraryOpen] = useState(false);
|
|
39
50
|
const location = useRouterState({ select: (state) => state.location });
|
|
40
|
-
const [main, setMain] = useState<MainLocation>({ file: "", view: "" });
|
|
41
51
|
const query = useQuery(navigationQuery(api), { keepPreviousData: true });
|
|
42
52
|
const data = Option.getOrUndefined(query.data);
|
|
43
|
-
const onPage = useCallback((next: MainLocation) => setMain((previous) => (sameMainLocation(previous, next) ? previous : next)), []);
|
|
44
53
|
useEffect(() => {
|
|
45
54
|
function start() {
|
|
46
55
|
const doc = document.getElementById("doc");
|
|
47
56
|
const context = doc?.querySelector<HTMLElement>(".item-context");
|
|
48
|
-
if (data &&
|
|
57
|
+
if (data && main.route && (!context || context.dataset.readingReady === "true")) {
|
|
49
58
|
ready?.();
|
|
50
59
|
}
|
|
51
60
|
}
|
|
52
61
|
start();
|
|
53
|
-
document.addEventListener("board-page", start);
|
|
54
62
|
document.addEventListener("board-reading-ready", start);
|
|
55
63
|
return () => {
|
|
56
|
-
document.removeEventListener("board-page", start);
|
|
57
64
|
document.removeEventListener("board-reading-ready", start);
|
|
58
65
|
};
|
|
59
|
-
}, [ready, data]);
|
|
60
|
-
useEffect(() => {
|
|
61
|
-
function sync() {
|
|
62
|
-
const doc = document.getElementById("doc");
|
|
63
|
-
if (doc) {
|
|
64
|
-
onPage(displayedLocation(doc));
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
document.addEventListener("board-page", sync);
|
|
68
|
-
return () => document.removeEventListener("board-page", sync);
|
|
69
|
-
}, [onPage]);
|
|
66
|
+
}, [ready, data, main]);
|
|
70
67
|
useEffect(() => {
|
|
71
68
|
if (data) {
|
|
72
69
|
document.dispatchEvent(new Event("board-index-change"));
|
|
73
70
|
}
|
|
74
71
|
}, [data]);
|
|
75
72
|
const live = client ? (
|
|
76
|
-
<LiveControls
|
|
77
|
-
client={client}
|
|
78
|
-
current={location.pathname + location.searchStr}
|
|
79
|
-
navigationFailed={Option.isSome(query.cause)}
|
|
80
|
-
navigationPending={query.pending}
|
|
81
|
-
/>
|
|
73
|
+
<LiveControls client={client} navigationFailed={Option.isSome(query.cause)} navigationPending={query.pending} />
|
|
82
74
|
) : (
|
|
83
75
|
<span className="font-mono text-muted-foreground text-xs" id={shellIds.live} role="status">
|
|
84
76
|
connecting
|
|
85
77
|
</span>
|
|
86
78
|
);
|
|
87
|
-
|
|
79
|
+
const content = (
|
|
88
80
|
<AgeTicker>
|
|
89
81
|
<ReadingLibrary api={api} close={() => setLibraryOpen(false)} open={libraryOpen}>
|
|
90
82
|
<a className="sr-only rounded-md bg-background p-3 focus:not-sr-only focus:absolute focus:z-50" href="#doc">
|
|
@@ -133,4 +125,5 @@ export function BoardShell(options: ShellOptions) {
|
|
|
133
125
|
</ReadingLibrary>
|
|
134
126
|
</AgeTicker>
|
|
135
127
|
);
|
|
128
|
+
return client ? <FormContext.Provider value={client}>{content}</FormContext.Provider> : content;
|
|
136
129
|
}
|
|
@@ -4,12 +4,17 @@ import { Tabs } from "#client/react/components/ui/Tabs.tsx";
|
|
|
4
4
|
import { Age } from "./Age.tsx";
|
|
5
5
|
import { DocumentMetadata } from "./DocumentMetadata.tsx";
|
|
6
6
|
import { DocumentSource } from "./DocumentSource.tsx";
|
|
7
|
+
import { useMainLocation } from "./MainLocationContext.ts";
|
|
7
8
|
|
|
8
9
|
export function DocumentContext({ document: data }: { readonly document: Document }) {
|
|
10
|
+
const page = useMainLocation();
|
|
9
11
|
const [headings, setHeadings] = useState<readonly { readonly id: string; readonly title: string; readonly depth: number }[]>([]);
|
|
10
12
|
const contextRef = useRef<HTMLElement>(null);
|
|
11
13
|
const [tab, setTab] = useState("details");
|
|
12
14
|
useEffect(() => {
|
|
15
|
+
if (page.route && page.projection === "document" && page.file !== data.file) {
|
|
16
|
+
return;
|
|
17
|
+
}
|
|
13
18
|
function outline() {
|
|
14
19
|
const entries = [
|
|
15
20
|
...(contextRef.current
|
|
@@ -21,10 +26,8 @@ export function DocumentContext({ document: data }: { readonly document: Documen
|
|
|
21
26
|
.map((heading) => ({ depth: Number(heading.tagName.slice(1)), id: heading.id, title: heading.textContent?.replace(/#$/u, "") ?? "" }));
|
|
22
27
|
setHeadings((current) => (JSON.stringify(current) === JSON.stringify(entries) ? current : entries));
|
|
23
28
|
}
|
|
24
|
-
document.addEventListener("board-page", outline);
|
|
25
29
|
outline();
|
|
26
|
-
|
|
27
|
-
}, []);
|
|
30
|
+
}, [page, data]);
|
|
28
31
|
|
|
29
32
|
useLayoutEffect(() => {
|
|
30
33
|
const context = contextRef.current;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { createContext, useContext } from "react";
|
|
2
|
+
import type { BrowserClient } from "#client/client.ts";
|
|
3
|
+
|
|
4
|
+
export type FormClient = Pick<BrowserClient, "handoffs" | "responses" | "runtime">;
|
|
5
|
+
export const FormContext = createContext<FormClient | undefined>(undefined);
|
|
6
|
+
|
|
7
|
+
export function useFormClient() {
|
|
8
|
+
const client = useContext(FormContext);
|
|
9
|
+
if (!client) {
|
|
10
|
+
throw new Error("Board forms require the shell's RPC client");
|
|
11
|
+
}
|
|
12
|
+
return client;
|
|
13
|
+
}
|
|
@@ -1,26 +1,21 @@
|
|
|
1
1
|
import { useAtomValue } from "@effect/atom-react";
|
|
2
2
|
import { Option } from "effect";
|
|
3
3
|
import * as Atom from "effect/reactivity/Atom";
|
|
4
|
-
import { useEffect, useMemo
|
|
4
|
+
import { useEffect, useMemo } from "react";
|
|
5
5
|
import { useQuery } from "@shivaedev/effect-react/result-state.ts";
|
|
6
6
|
import type { BrowserClient } from "#client/client.ts";
|
|
7
7
|
import { activeRead } from "./activeRead.ts";
|
|
8
8
|
import { liveStatus } from "./liveStatus.ts";
|
|
9
|
+
import { useMainLocation } from "./MainLocationContext.ts";
|
|
9
10
|
import { shellIds } from "./shellIds.ts";
|
|
10
11
|
|
|
11
12
|
const opening = Atom.make({ failed: false, pending: true });
|
|
12
|
-
interface Page {
|
|
13
|
-
readonly kind: string;
|
|
14
|
-
readonly url: string;
|
|
15
|
-
}
|
|
16
13
|
export function LiveControls({
|
|
17
14
|
client,
|
|
18
|
-
current,
|
|
19
15
|
navigationPending,
|
|
20
16
|
navigationFailed,
|
|
21
17
|
}: {
|
|
22
|
-
readonly client: BrowserClient;
|
|
23
|
-
readonly current: string;
|
|
18
|
+
readonly client: Pick<BrowserClient, "api" | "registry"> & { readonly updates: Pick<BrowserClient["updates"], "paused" | "status"> };
|
|
24
19
|
readonly navigationPending: boolean;
|
|
25
20
|
readonly navigationFailed: boolean;
|
|
26
21
|
}) {
|
|
@@ -28,23 +23,8 @@ export function LiveControls({
|
|
|
28
23
|
const paused = useAtomValue(client.updates.paused);
|
|
29
24
|
const watcher = useQuery(client.api.watcher.query());
|
|
30
25
|
const watching = Option.getOrUndefined(watcher.data)?.watching === true;
|
|
31
|
-
const
|
|
32
|
-
|
|
33
|
-
function sync() {
|
|
34
|
-
const doc = document.getElementById("doc");
|
|
35
|
-
if (doc?.dataset.route !== current) {
|
|
36
|
-
return;
|
|
37
|
-
}
|
|
38
|
-
setPage({
|
|
39
|
-
kind: doc?.dataset.projection ?? "document",
|
|
40
|
-
url: current,
|
|
41
|
-
});
|
|
42
|
-
}
|
|
43
|
-
sync();
|
|
44
|
-
document.addEventListener("board-page", sync);
|
|
45
|
-
return () => document.removeEventListener("board-page", sync);
|
|
46
|
-
}, [current]);
|
|
47
|
-
const atom = useMemo(() => (page ? activeRead(client.api, page.kind, page.url) : opening), [client, page]);
|
|
26
|
+
const page = useMainLocation();
|
|
27
|
+
const atom = useMemo(() => (page.route ? activeRead(client.api, page.projection, page.route) : opening), [client, page.projection, page.route]);
|
|
48
28
|
const reading = useAtomValue(atom);
|
|
49
29
|
const displayed = liveStatus({
|
|
50
30
|
connection: status.connection,
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { createContext, useContext } from "react";
|
|
2
|
+
import { emptyMainLocation } from "./mainLocation.ts";
|
|
3
|
+
|
|
4
|
+
export const MainLocationContext = createContext(emptyMainLocation);
|
|
5
|
+
|
|
6
|
+
export function useMainLocation() {
|
|
7
|
+
return useContext(MainLocationContext);
|
|
8
|
+
}
|