@cat-factory/kernel 0.254.0 → 0.255.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.
|
@@ -53,6 +53,36 @@ export interface DocumentSourceProvider {
|
|
|
53
53
|
resolveImplicitConnection?(workspaceId: string): Promise<NormalizedConnection | null>;
|
|
54
54
|
/** Resolve a stable page id from raw user input (a bare id or a page URL); null if unparseable. */
|
|
55
55
|
parseRef(input: string): string | null;
|
|
56
|
+
/**
|
|
57
|
+
* The canonical web URL for a page id, rebuilt WITHOUT a fetch: what a pasted share link is
|
|
58
|
+
* trimmed to once its title segment and tracking params are dropped. It is the half of
|
|
59
|
+
* {@link parseRef} an attach surface needs to SHOW someone what their paste resolved to,
|
|
60
|
+
* before any credential is spent or any row is written.
|
|
61
|
+
*
|
|
62
|
+
* OPTIONAL, and the absence is a real fact rather than an unimplemented method: a Confluence
|
|
63
|
+
* page id needs the connection's site base URL and a Linear document id the workspace slug,
|
|
64
|
+
* neither of which the id carries, so those providers can only answer by fetching. The GitHub
|
|
65
|
+
* docs source omits it for a different reason worth keeping distinct: the id carries everything
|
|
66
|
+
* a link needs EXCEPT the host, and the host is a deployment fact (a GitLab-backed deployment
|
|
67
|
+
* reaches the same source through the VCS adapter), so any URL built here would name the wrong
|
|
68
|
+
* one half the time. A caller renders the id itself in all these cases; it must NOT read the
|
|
69
|
+
* absence as a failed resolution.
|
|
70
|
+
*/
|
|
71
|
+
canonicalUrl?(externalId: string): string | null;
|
|
72
|
+
/**
|
|
73
|
+
* The narrowing qualifier `input` carried that {@link parseRef}'s id does NOT cover, or null.
|
|
74
|
+
*
|
|
75
|
+
* A design source's ref grammar is two-level: a file/project, optionally narrowed to a
|
|
76
|
+
* frame/screen. When the qualifier is one the parser cannot read, `parseRef` deliberately falls
|
|
77
|
+
* back to the CONTAINER rather than guessing which frame was meant, which silently widens the
|
|
78
|
+
* reference from one frame to the whole file. That widening is invisible in the result (a valid
|
|
79
|
+
* id, a valid canonical URL), so the provider that dropped it is the only thing that can say so.
|
|
80
|
+
*
|
|
81
|
+
* OPTIONAL: a source with a single-level grammar has no narrowing to drop, and its absence means
|
|
82
|
+
* exactly that. Implemented by the design sources (Figma, Zeplin). PURE, taking the same raw
|
|
83
|
+
* input `parseRef` took, so it costs a pre-flight nothing.
|
|
84
|
+
*/
|
|
85
|
+
droppedScope?(input: string, externalId: string): string | null;
|
|
56
86
|
/**
|
|
57
87
|
* Fetch a single page by its id using the connection credentials. `workspaceId` is
|
|
58
88
|
* the workspace on whose behalf the read happens: a provider that authenticates
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"document-source.d.ts","sourceRoot":"","sources":["../../src/ports/document-source.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,kBAAkB,EAClB,wBAAwB,EACxB,oBAAoB,EACrB,MAAM,oBAAoB,CAAA;AAC3B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,iCAAiC,CAAA;AACxE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAA;AAahE,qEAAqE;AACrE,MAAM,MAAM,mBAAmB,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;AAExD,0EAA0E;AAC1E,MAAM,WAAW,eAAe;IAC9B,2CAA2C;IAC3C,UAAU,EAAE,MAAM,CAAA;IAClB,KAAK,EAAE,MAAM,CAAA;IACb,qCAAqC;IACrC,GAAG,EAAE,MAAM,CAAA;IACX,iFAAiF;IACjF,IAAI,EAAE,MAAM,CAAA;IACZ;;;;;;;OAOG;IACH,OAAO,EAAE,MAAM,CAAA;CAChB;AAED,kEAAkE;AAClE,MAAM,WAAW,oBAAoB;IACnC,0DAA0D;IAC1D,WAAW,EAAE,mBAAmB,CAAA;IAChC,4EAA4E;IAC5E,KAAK,EAAE,MAAM,CAAA;CACd;AAED,MAAM,WAAW,sBAAsB;IACrC,yCAAyC;IACzC,QAAQ,CAAC,IAAI,EAAE,kBAAkB,C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AA;CACjC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cat-factory/kernel",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.255.0",
|
|
4
4
|
"description": "Shared vocabulary, pure logic, and port interfaces for the Agent Architecture Board.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"ai": "^7.0.51",
|
|
28
28
|
"yaml": "^2.9.0",
|
|
29
|
-
"@cat-factory/contracts": "0.
|
|
29
|
+
"@cat-factory/contracts": "0.256.0"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@stryker-mutator/core": "9.6.1",
|