@bridge-ds/core 0.3.0 → 0.4.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/dist/audit/index.js +1 -1
- package/dist/{component-spec-IRFGJ7XK.js → component-spec-cvrSvIZj.js} +160 -160
- package/dist/{component-spec-IRFGJ7XK.js.map → component-spec-cvrSvIZj.js.map} +1 -1
- package/dist/css-overrides.d.ts +11 -0
- package/dist/explorations-github.d.ts +4 -1
- package/dist/explorations.d.ts +6 -0
- package/dist/github-client.d.ts +5 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +676 -392
- package/dist/index.js.map +1 -1
- package/dist/{layered-DGate4nv.js → layered-BnbmToGs.js} +10 -10
- package/dist/{layered-DGate4nv.js.map → layered-BnbmToGs.js.map} +1 -1
- package/dist/node/index.js +3 -3
- package/dist/{report-tNzTriGF.js → report-Bf2HEr9t.js} +2 -2
- package/dist/{report-tNzTriGF.js.map → report-Bf2HEr9t.js.map} +1 -1
- package/dist/token-combine.d.ts +78 -0
- package/dist/token-merge.d.ts +72 -0
- package/package.json +1 -1
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type ResolveContext } from './resolver';
|
|
2
|
+
import type { TokenSet } from './token-set';
|
|
3
|
+
/** CSS value of a resolved DTCG value, the way tokens.css writes it. */
|
|
4
|
+
export declare function cssOf(type: string, value: unknown): string | undefined;
|
|
5
|
+
export declare const cssVarOf: (path: string) => string;
|
|
6
|
+
/**
|
|
7
|
+
* CSS custom properties to set on a scope so it renders `proposed` instead of `head`: every token whose resolved value
|
|
8
|
+
* differs in that context. Setting resolved values (not var() references) keeps chains correct even when the original
|
|
9
|
+
* variable is declared on an ancestor.
|
|
10
|
+
*/
|
|
11
|
+
export declare function previewOverrides(head: TokenSet, proposed: TokenSet, ctx: ResolveContext): Record<string, string>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { BridgeConfig } from './config';
|
|
2
|
-
import { type Exploration, type ExplorationStatus, type ExplorationTryIt, type PromotionPlan } from './explorations';
|
|
2
|
+
import { type Exploration, type ExplorationSource, type ExplorationStatus, type ExplorationTryIt, type PromotionPlan } from './explorations';
|
|
3
3
|
import { type GitHubClient, type PullRequestSummary } from './github-client';
|
|
4
4
|
import { type BranchPreview, type PreviewApps } from './previews';
|
|
5
5
|
export interface ExplorationSettings {
|
|
@@ -26,6 +26,9 @@ export interface ExplorationSummary {
|
|
|
26
26
|
status: ExplorationStatus;
|
|
27
27
|
draft: boolean;
|
|
28
28
|
author: string;
|
|
29
|
+
/** Where it was started and the AI agent that started it, when the exploration block says so. */
|
|
30
|
+
source?: ExplorationSource | undefined;
|
|
31
|
+
agent?: string | undefined;
|
|
29
32
|
updatedAt: string;
|
|
30
33
|
/** Head commit of the branch. */
|
|
31
34
|
headSha: string;
|
package/dist/explorations.d.ts
CHANGED
|
@@ -13,6 +13,8 @@ export declare const EXPLORATION_TIER_LABEL = "Exploration (not mergeable)";
|
|
|
13
13
|
export declare const EXPLORATION_CHECK = "Exploration not merged as is";
|
|
14
14
|
export type ExplorationUseCase = 'user-test' | 'stakeholder-demo' | 'ab-idea' | 'terminal' | 'other';
|
|
15
15
|
export type ExplorationStatus = 'active' | 'promoted' | 'closed';
|
|
16
|
+
/** Where an exploration was started: Bridge Studio, the Figma plugin, the CLI or the MCP server (an AI agent). */
|
|
17
|
+
export type ExplorationSource = 'studio' | 'figma' | 'cli' | 'mcp';
|
|
16
18
|
export declare const EXPLORATION_USE_CASES: {
|
|
17
19
|
value: ExplorationUseCase;
|
|
18
20
|
label: string;
|
|
@@ -33,6 +35,10 @@ export interface Exploration {
|
|
|
33
35
|
author?: string | undefined;
|
|
34
36
|
/** ISO date it started. */
|
|
35
37
|
startedAt?: string | undefined;
|
|
38
|
+
/** Where it was started, so Studio says "You" only for what the viewer started there. */
|
|
39
|
+
source?: ExplorationSource | undefined;
|
|
40
|
+
/** The AI agent that started it ("claude"), when one did: the GitHub account alone cannot tell. */
|
|
41
|
+
agent?: string | undefined;
|
|
36
42
|
}
|
|
37
43
|
/** "Denser data tables!" -> "denser-data-tables". Up to 40 characters, cut at a word boundary. Empty when nothing is left. */
|
|
38
44
|
export declare function explorationSlug(name: string): string;
|
package/dist/github-client.d.ts
CHANGED
|
@@ -272,6 +272,11 @@ export declare class GitHubClient {
|
|
|
272
272
|
* markPullRequestReadyForReview, with the same token (pull requests: write).
|
|
273
273
|
*/
|
|
274
274
|
markReadyForReview(n: number): Promise<void>;
|
|
275
|
+
/**
|
|
276
|
+
* Turns an open pull request back into a draft: the GraphQL mutation convertPullRequestToDraft (REST cannot set
|
|
277
|
+
* `draft` either), same token. No-op when it is already a draft.
|
|
278
|
+
*/
|
|
279
|
+
convertToDraft(n: number): Promise<void>;
|
|
275
280
|
createPullRequest(input: {
|
|
276
281
|
title: string;
|
|
277
282
|
head: string;
|
package/dist/index.d.ts
CHANGED
|
@@ -10,6 +10,9 @@ export * from './wcag';
|
|
|
10
10
|
export * from './validators';
|
|
11
11
|
export * from './id-map';
|
|
12
12
|
export * from './diff-engine';
|
|
13
|
+
export * from './token-merge';
|
|
14
|
+
export * from './token-combine';
|
|
15
|
+
export * from './css-overrides';
|
|
13
16
|
export * from './compose';
|
|
14
17
|
export * from './risk';
|
|
15
18
|
export * from './pr-composer';
|