@w6w/ui 0.2.60 → 0.2.62

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.
@@ -84,6 +84,11 @@ export interface StepStartState {
84
84
  foreach?: {
85
85
  item?: unknown;
86
86
  index?: number;
87
+ /** Nested loops: every enclosing For each by id, outermost first (innermost last). */
88
+ loops?: Record<string, {
89
+ item?: unknown;
90
+ index?: number;
91
+ }>;
87
92
  };
88
93
  /**
89
94
  * What upstream writers ("Write to state") put in the run state, folded from their saved tests
@@ -71,6 +71,10 @@ export interface ResolveScope {
71
71
  foreach?: {
72
72
  item?: unknown;
73
73
  index?: number;
74
+ loops?: Record<string, {
75
+ item?: unknown;
76
+ index?: number;
77
+ }>;
74
78
  };
75
79
  /**
76
80
  * The original flat `sampleValues` map, keyed by full ref string — checked
@@ -200,17 +200,23 @@ export declare function fetchSeedSources(listStepTests: (stepId: string) => Prom
200
200
  * ⚠️ Single-step scope only. A full run (`POST /workflows/:id/run`) builds its
201
201
  * own scope and is not affected by this.
202
202
  */
203
- export declare function startStateFromSeeds(seeds: SeedSource[], loop?: {
204
- item?: unknown;
205
- index?: number;
206
- },
203
+ export declare function startStateFromSeeds(seeds: SeedSource[], loop?: LoopSeedValue,
207
204
  /** Upstream state writes (`StateShape.written`) → the start state's `state`. */
208
205
  written?: Record<string, unknown>): StepStartState | undefined;
209
- /** The default `{ item, index }` a loop-body Test is seeded with: the sample item, index 0. */
210
- export declare function loopSeedFromSource(loop: ExpressionLoopSource | undefined): {
206
+ /**
207
+ * The iteration seed a loop-body Test is sent as `state.foreach`: the innermost `item` / `index`
208
+ * plus, when known, `loops` — every enclosing For each (outermost first, the innermost last).
209
+ */
210
+ export interface LoopSeedValue {
211
211
  item?: unknown;
212
212
  index?: number;
213
- } | undefined;
213
+ loops?: Record<string, {
214
+ item?: unknown;
215
+ index: number;
216
+ }>;
217
+ }
218
+ /** The default `{ item, index }` a loop-body Test is seeded with: the sample item, index 0. */
219
+ export declare function loopSeedFromSource(loop: ExpressionLoopSource | undefined): LoopSeedValue | undefined;
214
220
  /** The editable "Current item" text a loop's sample item starts as (`""` when there is none). */
215
221
  export declare function loopItemText(loop: ExpressionLoopSource | undefined): string;
216
222
  /**
package/dist/types.d.ts CHANGED
@@ -456,6 +456,12 @@ export interface AuthDef {
456
456
  }[];
457
457
  /** Present when `type === "serviceAccount"`: what credential it accepts and how it binds. */
458
458
  serviceAccount?: ServiceAccountConfig;
459
+ /**
460
+ * Credential contract ids a SHARED credential must have to be used for this auth. The server
461
+ * derives it for bearer / apiKey / basic auths; absent when empty (an older server, or an auth
462
+ * no shared contract fits). A `serviceAccount` auth keeps its list in `serviceAccount.accepts`.
463
+ */
464
+ accepts?: string[];
459
465
  /** OAuth2 endpoints (only present when type === "oauth2"). */
460
466
  oauth2?: Record<string, unknown>;
461
467
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@w6w/ui",
3
- "version": "0.2.60",
3
+ "version": "0.2.62",
4
4
  "description": "React components for w6w — central API management. Build plugins, apps and integrations on them.",
5
5
  "license": "MIT",
6
6
  "homepage": "https://w6w.io",
@@ -130,6 +130,14 @@
130
130
  white-space: pre-wrap;
131
131
  word-break: break-word;
132
132
  }
133
+ /* A `{columns, rows}` value shown as a table: the cells keep the viewer's mono
134
+ type, and a `null` cell recedes (`.w6w-muted`) but stays legible. */
135
+ .w6w-result-viewer-table {
136
+ font-family: var(--w6w-font-mono);
137
+ }
138
+ .w6w-result-viewer-null {
139
+ font-style: italic;
140
+ }
133
141
  /* One indent step per nesting level, and no list markers: the `<summary>`
134
142
  triangle already says "this node opens". */
135
143
  .w6w-json-children {
package/src/styles.css CHANGED
@@ -4610,6 +4610,16 @@ input.w6w-stepbuilder-search.w6w-stepbuilder-search:focus {
4610
4610
  word-break: break-word;
4611
4611
  }
4612
4612
 
4613
+ /* A `{columns, rows}` value shown as a table: the cells keep the viewer's mono
4614
+ type, and a `null` cell recedes (`.w6w-muted`) but stays legible. */
4615
+ .w6w-result-viewer-table {
4616
+ font-family: var(--w6w-font-mono);
4617
+ }
4618
+
4619
+ .w6w-result-viewer-null {
4620
+ font-style: italic;
4621
+ }
4622
+
4613
4623
  /* One indent step per nesting level, and no list markers: the `<summary>`
4614
4624
  triangle already says "this node opens". */
4615
4625
  .w6w-json-children {