@wix/himalaya-cli 0.1799.0 → 0.1800.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.
@@ -3330,6 +3330,48 @@ export interface TopBarConfig {
3330
3330
  /** RFC 0066 amendment "Title, leading and trailing completion" — "" / "auto" (default) | "leading" | "center".
3331
3331
  * Unknown values read as "auto". Per screen; `NavigationConfig.topBarTitleAlign` is the app-wide twin. */
3332
3332
  titleAlign?: string;
3333
+ /** RFC 0066 amendment "Bar types, styles, search, save and modes" — the tone of the cover image under an
3334
+ * `style: "immersive"` bar: "" / "dark" (default, white icons) | "light" (`#1A1B20` icons). Unknown ⇒ "dark". */
3335
+ coverTone?: string;
3336
+ /** RFC 0066 amendment "Bar types, styles, search, save and modes" (cover to solid) — a transparent or immersive bar stays
3337
+ * clear until this edge, then fades to its fill over 24pt. Unset ⇒ the 0→8pt ramp of a transparent bar. */
3338
+ solidAfter?: TopBarScrollEdge;
3339
+ /** RFC 0066 amendment "Bar types, styles, search, save and modes" — selection mode. */
3340
+ selection?: TopBarSelection;
3341
+ /** RFC 0066 amendment "Bar types, styles, search, save and modes" — edit mode. Uses `dirtyPath`. */
3342
+ edit?: TopBarEdit;
3343
+ }
3344
+ /** RFC 0066 amendment "Bar types, styles, search, save and modes" — where a transparent or immersive bar turns solid.
3345
+ * The fade starts when the bottom edge of the content node `nodeId` reaches the bar's bottom edge; with no
3346
+ * `nodeId`, or one the screen does not have, at the scroll `offset` (points). Both unset ⇒ 0. */
3347
+ export interface TopBarScrollEdge {
3348
+ nodeId?: string;
3349
+ offset?: number;
3350
+ }
3351
+ /** RFC 0066 amendment — selection mode. While `activePath` is truthy the bar shows Close (`onClose`), the count
3352
+ * title and the bulk `items`, which are disabled while the count is 0. */
3353
+ export interface TopBarSelection {
3354
+ /** `$service:` bool. Unset or unresolved ⇒ false: no mode. */
3355
+ activePath?: string;
3356
+ /** `$service:` number of selected items. Unresolved ⇒ 0. */
3357
+ countPath?: string;
3358
+ /** "{count}" is replaced by the count. "" ⇒ the localized "{count} selected". */
3359
+ titleFormat?: string;
3360
+ /** Close: the worker clears the selection and sets `activePath` false. */
3361
+ onClose?: Action;
3362
+ /** Bulk actions. iOS draws them in a bottom toolbar; Android two icons + More Actions. */
3363
+ items?: ToolbarItem[];
3364
+ /** Optional Select all: in More Actions on Android, a bar item on iOS and web. */
3365
+ selectAll?: ToolbarItem;
3366
+ }
3367
+ /** RFC 0066 amendment — edit mode. Outside the mode the bar shows Edit (`onEdit`); in it Done (`onDone`, disabled
3368
+ * until `TopBarConfig.dirtyPath` is truthy) and Cancel (`onCancel`, which asks to discard first when dirty). */
3369
+ export interface TopBarEdit {
3370
+ /** `$service:` bool. Unset or unresolved ⇒ false: not editing. */
3371
+ activePath?: string;
3372
+ onEdit?: Action;
3373
+ onDone?: Action;
3374
+ onCancel?: Action;
3333
3375
  }
3334
3376
  /** RFC 0066 §1 (+ its "top-bar gap items" amendment) — one top-bar item. Test id `toolbar.<id>`
3335
3377
  * (`toolbar-<id>` on web and React Native). Every tap carries an existing `Action`
@@ -3369,6 +3411,10 @@ export interface ToolbarItem {
3369
3411
  * the item's `onTap` and `onLongPress` fire. `avatarsPath` resolves on the screen, like the other
3370
3412
  * top-bar bindings. An "overflow" item draws its label row instead. */
3371
3413
  avatarStrip?: AvatarStripProps;
3414
+ /** RFC 0066 amendment "Bar types, styles, search, save and modes" — with `loadingPath` truthy for 30 s the shell
3415
+ * stops the spinner and dispatches this; the worker shows the failed state. Unset ⇒ the spinner stays.
3416
+ * "Still saving…" shows under the bar at 10 s either way. */
3417
+ onLoadingTimeout?: Action;
3372
3418
  }
3373
3419
  /** RFC 0066 amendment — an avatar item. Images are absolute https URLs (resolve a Wix
3374
3420
  * media id with `wixMediaUrl` before publishing). */
@@ -3829,9 +3875,10 @@ export interface SearchableConfig {
3829
3875
  onCancel?: Action;
3830
3876
  /** `$service:` bool: the search is busy. */
3831
3877
  loadingPath?: string;
3832
- /** Static suggestions. On the wire for a later release: no shell draws them yet (RFC 0010 decision 11). */
3878
+ /** Static suggestions, shown while the user types (RFC 0066 amendment "Bar types, styles, search, save and modes").
3879
+ * The validator warns until every shell draws them. */
3833
3880
  suggestions?: SearchSuggestion[];
3834
- /** `$service:` array of `{ id, label, icon? }`. Not drawn yet (decision 11). */
3881
+ /** `$service:` array of `{ id, label, icon? }`. */
3835
3882
  suggestionsPath?: string;
3836
3883
  /** `args.id` (+ `args.label`) of the tapped suggestion; a static suggestion's own `onTap` wins. */
3837
3884
  onSuggestionTap?: Action;
@@ -3841,6 +3888,18 @@ export interface SearchableConfig {
3841
3888
  scopePath?: string;
3842
3889
  /** `args.selectedId`. */
3843
3890
  onScopeChange?: Action;
3891
+ /** RFC 0066 amendment "Bar types, styles, search, save and modes" — `$service:` array of recent query strings,
3892
+ * shown while the query is empty. None ⇒ an empty area, no message. */
3893
+ recentsPath?: string;
3894
+ /** `args.value` (the recent query). Unset ⇒ the shell puts the query in the field and runs `onSubmit`. */
3895
+ onRecentTap?: Action;
3896
+ /** Clears the recents. Unset ⇒ no Clear control. */
3897
+ onClearRecents?: Action;
3898
+ /** `$service:` "" (results, default) | "empty" ("No results", the query kept) | "error" (the message and
3899
+ * Try Again). Unknown ⇒ "". */
3900
+ resultsStatePath?: string;
3901
+ /** Try Again of the error state. Unset ⇒ `onSubmit` with the same query. */
3902
+ onRetry?: Action;
3844
3903
  }
3845
3904
  /** RFC 0066 §2 — one static search suggestion (`SearchableConfig.suggestions`). */
3846
3905
  export interface SearchSuggestion {
@@ -485,6 +485,75 @@ export declare const screenDescriptorSchema: {
485
485
  readonly titleAlign: {
486
486
  readonly type: "string";
487
487
  };
488
+ readonly coverTone: {
489
+ readonly type: "string";
490
+ };
491
+ readonly solidAfter: {
492
+ readonly $ref: "#/$defs/topBarScrollEdge";
493
+ };
494
+ readonly selection: {
495
+ readonly $ref: "#/$defs/topBarSelection";
496
+ };
497
+ readonly edit: {
498
+ readonly $ref: "#/$defs/topBarEdit";
499
+ };
500
+ };
501
+ };
502
+ readonly topBarScrollEdge: {
503
+ readonly type: "object";
504
+ readonly additionalProperties: false;
505
+ readonly properties: {
506
+ readonly nodeId: {
507
+ readonly type: "string";
508
+ };
509
+ readonly offset: {
510
+ readonly type: "number";
511
+ };
512
+ };
513
+ };
514
+ readonly topBarSelection: {
515
+ readonly type: "object";
516
+ readonly additionalProperties: false;
517
+ readonly properties: {
518
+ readonly activePath: {
519
+ readonly type: "string";
520
+ };
521
+ readonly countPath: {
522
+ readonly type: "string";
523
+ };
524
+ readonly titleFormat: {
525
+ readonly type: "string";
526
+ };
527
+ readonly onClose: {
528
+ readonly $ref: "#/$defs/action";
529
+ };
530
+ readonly items: {
531
+ readonly type: "array";
532
+ readonly items: {
533
+ readonly $ref: "#/$defs/toolbarItem";
534
+ };
535
+ };
536
+ readonly selectAll: {
537
+ readonly $ref: "#/$defs/toolbarItem";
538
+ };
539
+ };
540
+ };
541
+ readonly topBarEdit: {
542
+ readonly type: "object";
543
+ readonly additionalProperties: false;
544
+ readonly properties: {
545
+ readonly activePath: {
546
+ readonly type: "string";
547
+ };
548
+ readonly onEdit: {
549
+ readonly $ref: "#/$defs/action";
550
+ };
551
+ readonly onDone: {
552
+ readonly $ref: "#/$defs/action";
553
+ };
554
+ readonly onCancel: {
555
+ readonly $ref: "#/$defs/action";
556
+ };
488
557
  };
489
558
  };
490
559
  readonly searchableConfig: {
@@ -542,6 +611,21 @@ export declare const screenDescriptorSchema: {
542
611
  readonly onScopeChange: {
543
612
  readonly $ref: "#/$defs/action";
544
613
  };
614
+ readonly recentsPath: {
615
+ readonly type: "string";
616
+ };
617
+ readonly onRecentTap: {
618
+ readonly $ref: "#/$defs/action";
619
+ };
620
+ readonly onClearRecents: {
621
+ readonly $ref: "#/$defs/action";
622
+ };
623
+ readonly resultsStatePath: {
624
+ readonly type: "string";
625
+ };
626
+ readonly onRetry: {
627
+ readonly $ref: "#/$defs/action";
628
+ };
545
629
  };
546
630
  };
547
631
  readonly searchSuggestion: {
@@ -638,6 +722,9 @@ export declare const screenDescriptorSchema: {
638
722
  readonly avatarStrip: {
639
723
  readonly $ref: "#/$defs/toolbarAvatarStrip";
640
724
  };
725
+ readonly onLoadingTimeout: {
726
+ readonly $ref: "#/$defs/action";
727
+ };
641
728
  };
642
729
  };
643
730
  readonly toolbarAvatarStrip: {
@@ -2067,6 +2154,75 @@ export declare const widgetSnapshotSchema: {
2067
2154
  readonly titleAlign: {
2068
2155
  readonly type: "string";
2069
2156
  };
2157
+ readonly coverTone: {
2158
+ readonly type: "string";
2159
+ };
2160
+ readonly solidAfter: {
2161
+ readonly $ref: "#/$defs/topBarScrollEdge";
2162
+ };
2163
+ readonly selection: {
2164
+ readonly $ref: "#/$defs/topBarSelection";
2165
+ };
2166
+ readonly edit: {
2167
+ readonly $ref: "#/$defs/topBarEdit";
2168
+ };
2169
+ };
2170
+ };
2171
+ readonly topBarScrollEdge: {
2172
+ readonly type: "object";
2173
+ readonly additionalProperties: false;
2174
+ readonly properties: {
2175
+ readonly nodeId: {
2176
+ readonly type: "string";
2177
+ };
2178
+ readonly offset: {
2179
+ readonly type: "number";
2180
+ };
2181
+ };
2182
+ };
2183
+ readonly topBarSelection: {
2184
+ readonly type: "object";
2185
+ readonly additionalProperties: false;
2186
+ readonly properties: {
2187
+ readonly activePath: {
2188
+ readonly type: "string";
2189
+ };
2190
+ readonly countPath: {
2191
+ readonly type: "string";
2192
+ };
2193
+ readonly titleFormat: {
2194
+ readonly type: "string";
2195
+ };
2196
+ readonly onClose: {
2197
+ readonly $ref: "#/$defs/action";
2198
+ };
2199
+ readonly items: {
2200
+ readonly type: "array";
2201
+ readonly items: {
2202
+ readonly $ref: "#/$defs/toolbarItem";
2203
+ };
2204
+ };
2205
+ readonly selectAll: {
2206
+ readonly $ref: "#/$defs/toolbarItem";
2207
+ };
2208
+ };
2209
+ };
2210
+ readonly topBarEdit: {
2211
+ readonly type: "object";
2212
+ readonly additionalProperties: false;
2213
+ readonly properties: {
2214
+ readonly activePath: {
2215
+ readonly type: "string";
2216
+ };
2217
+ readonly onEdit: {
2218
+ readonly $ref: "#/$defs/action";
2219
+ };
2220
+ readonly onDone: {
2221
+ readonly $ref: "#/$defs/action";
2222
+ };
2223
+ readonly onCancel: {
2224
+ readonly $ref: "#/$defs/action";
2225
+ };
2070
2226
  };
2071
2227
  };
2072
2228
  readonly searchableConfig: {
@@ -2124,6 +2280,21 @@ export declare const widgetSnapshotSchema: {
2124
2280
  readonly onScopeChange: {
2125
2281
  readonly $ref: "#/$defs/action";
2126
2282
  };
2283
+ readonly recentsPath: {
2284
+ readonly type: "string";
2285
+ };
2286
+ readonly onRecentTap: {
2287
+ readonly $ref: "#/$defs/action";
2288
+ };
2289
+ readonly onClearRecents: {
2290
+ readonly $ref: "#/$defs/action";
2291
+ };
2292
+ readonly resultsStatePath: {
2293
+ readonly type: "string";
2294
+ };
2295
+ readonly onRetry: {
2296
+ readonly $ref: "#/$defs/action";
2297
+ };
2127
2298
  };
2128
2299
  };
2129
2300
  readonly searchSuggestion: {
@@ -2220,6 +2391,9 @@ export declare const widgetSnapshotSchema: {
2220
2391
  readonly avatarStrip: {
2221
2392
  readonly $ref: "#/$defs/toolbarAvatarStrip";
2222
2393
  };
2394
+ readonly onLoadingTimeout: {
2395
+ readonly $ref: "#/$defs/action";
2396
+ };
2223
2397
  };
2224
2398
  };
2225
2399
  readonly toolbarAvatarStrip: {
@@ -9259,11 +9259,47 @@ var screenDescriptorSchema = {
9259
9259
  dirtyPath: { type: "string" },
9260
9260
  // RFC 0066 amendment "long press, bar visibility, tab-bar visibility" (field 15).
9261
9261
  visibilityPath: { type: "string" },
9262
- // RFC 0066 amendment "Title, leading and trailing completion" (field 17; 16 is `cover_tone`).
9263
- titleAlign: { type: "string" }
9262
+ // RFC 0066 amendment "Title, leading and trailing completion" (field 17).
9263
+ titleAlign: { type: "string" },
9264
+ // RFC 0066 amendment "Bar types, styles, search, save and modes" (fields 16, 18–20).
9265
+ coverTone: { type: "string" },
9266
+ solidAfter: { $ref: "#/$defs/topBarScrollEdge" },
9267
+ selection: { $ref: "#/$defs/topBarSelection" },
9268
+ edit: { $ref: "#/$defs/topBarEdit" }
9264
9269
  }
9265
9270
  },
9266
- // RFC 0010 "Native top-bar search" (SearchableConfig fields 1–15). `placement` stays a free string.
9271
+ topBarScrollEdge: {
9272
+ type: "object",
9273
+ additionalProperties: false,
9274
+ properties: {
9275
+ nodeId: { type: "string" },
9276
+ offset: { type: "number" }
9277
+ }
9278
+ },
9279
+ topBarSelection: {
9280
+ type: "object",
9281
+ additionalProperties: false,
9282
+ properties: {
9283
+ activePath: { type: "string" },
9284
+ countPath: { type: "string" },
9285
+ titleFormat: { type: "string" },
9286
+ onClose: { $ref: "#/$defs/action" },
9287
+ items: { type: "array", items: { $ref: "#/$defs/toolbarItem" } },
9288
+ selectAll: { $ref: "#/$defs/toolbarItem" }
9289
+ }
9290
+ },
9291
+ topBarEdit: {
9292
+ type: "object",
9293
+ additionalProperties: false,
9294
+ properties: {
9295
+ activePath: { type: "string" },
9296
+ onEdit: { $ref: "#/$defs/action" },
9297
+ onDone: { $ref: "#/$defs/action" },
9298
+ onCancel: { $ref: "#/$defs/action" }
9299
+ }
9300
+ },
9301
+ // RFC 0010 "Native top-bar search" (SearchableConfig fields 1–15) + RFC 0066 amendment "Bar types, styles,
9302
+ // search, save and modes" (16–20). `placement` and the results state stay free strings.
9267
9303
  searchableConfig: {
9268
9304
  type: "object",
9269
9305
  additionalProperties: false,
@@ -9282,7 +9318,12 @@ var screenDescriptorSchema = {
9282
9318
  onSuggestionTap: { $ref: "#/$defs/action" },
9283
9319
  scopes: { type: "array", items: { $ref: "#/$defs/searchScope" } },
9284
9320
  scopePath: { type: "string" },
9285
- onScopeChange: { $ref: "#/$defs/action" }
9321
+ onScopeChange: { $ref: "#/$defs/action" },
9322
+ recentsPath: { type: "string" },
9323
+ onRecentTap: { $ref: "#/$defs/action" },
9324
+ onClearRecents: { $ref: "#/$defs/action" },
9325
+ resultsStatePath: { type: "string" },
9326
+ onRetry: { $ref: "#/$defs/action" }
9286
9327
  }
9287
9328
  },
9288
9329
  searchSuggestion: {
@@ -9328,7 +9369,9 @@ var screenDescriptorSchema = {
9328
9369
  onLongPress: { $ref: "#/$defs/action" },
9329
9370
  badge: { $ref: "#/$defs/navBadge" },
9330
9371
  // RFC 0066 amendment "Top-bar avatar strip" (field 16) — the AvatarStrip props, drawn in the bar.
9331
- avatarStrip: { $ref: "#/$defs/toolbarAvatarStrip" }
9372
+ avatarStrip: { $ref: "#/$defs/toolbarAvatarStrip" },
9373
+ // RFC 0066 amendment "Bar types, styles, search, save and modes" (field 17).
9374
+ onLoadingTimeout: { $ref: "#/$defs/action" }
9332
9375
  }
9333
9376
  },
9334
9377
  // The proto `AvatarStripProps` as a toolbar item carries it. `caption`, `ringGradient` and `onTap` are
@@ -7271,11 +7271,47 @@ var screenDescriptorSchema = {
7271
7271
  dirtyPath: { type: "string" },
7272
7272
  // RFC 0066 amendment "long press, bar visibility, tab-bar visibility" (field 15).
7273
7273
  visibilityPath: { type: "string" },
7274
- // RFC 0066 amendment "Title, leading and trailing completion" (field 17; 16 is `cover_tone`).
7275
- titleAlign: { type: "string" }
7274
+ // RFC 0066 amendment "Title, leading and trailing completion" (field 17).
7275
+ titleAlign: { type: "string" },
7276
+ // RFC 0066 amendment "Bar types, styles, search, save and modes" (fields 16, 18–20).
7277
+ coverTone: { type: "string" },
7278
+ solidAfter: { $ref: "#/$defs/topBarScrollEdge" },
7279
+ selection: { $ref: "#/$defs/topBarSelection" },
7280
+ edit: { $ref: "#/$defs/topBarEdit" }
7276
7281
  }
7277
7282
  },
7278
- // RFC 0010 "Native top-bar search" (SearchableConfig fields 1–15). `placement` stays a free string.
7283
+ topBarScrollEdge: {
7284
+ type: "object",
7285
+ additionalProperties: false,
7286
+ properties: {
7287
+ nodeId: { type: "string" },
7288
+ offset: { type: "number" }
7289
+ }
7290
+ },
7291
+ topBarSelection: {
7292
+ type: "object",
7293
+ additionalProperties: false,
7294
+ properties: {
7295
+ activePath: { type: "string" },
7296
+ countPath: { type: "string" },
7297
+ titleFormat: { type: "string" },
7298
+ onClose: { $ref: "#/$defs/action" },
7299
+ items: { type: "array", items: { $ref: "#/$defs/toolbarItem" } },
7300
+ selectAll: { $ref: "#/$defs/toolbarItem" }
7301
+ }
7302
+ },
7303
+ topBarEdit: {
7304
+ type: "object",
7305
+ additionalProperties: false,
7306
+ properties: {
7307
+ activePath: { type: "string" },
7308
+ onEdit: { $ref: "#/$defs/action" },
7309
+ onDone: { $ref: "#/$defs/action" },
7310
+ onCancel: { $ref: "#/$defs/action" }
7311
+ }
7312
+ },
7313
+ // RFC 0010 "Native top-bar search" (SearchableConfig fields 1–15) + RFC 0066 amendment "Bar types, styles,
7314
+ // search, save and modes" (16–20). `placement` and the results state stay free strings.
7279
7315
  searchableConfig: {
7280
7316
  type: "object",
7281
7317
  additionalProperties: false,
@@ -7294,7 +7330,12 @@ var screenDescriptorSchema = {
7294
7330
  onSuggestionTap: { $ref: "#/$defs/action" },
7295
7331
  scopes: { type: "array", items: { $ref: "#/$defs/searchScope" } },
7296
7332
  scopePath: { type: "string" },
7297
- onScopeChange: { $ref: "#/$defs/action" }
7333
+ onScopeChange: { $ref: "#/$defs/action" },
7334
+ recentsPath: { type: "string" },
7335
+ onRecentTap: { $ref: "#/$defs/action" },
7336
+ onClearRecents: { $ref: "#/$defs/action" },
7337
+ resultsStatePath: { type: "string" },
7338
+ onRetry: { $ref: "#/$defs/action" }
7298
7339
  }
7299
7340
  },
7300
7341
  searchSuggestion: {
@@ -7340,7 +7381,9 @@ var screenDescriptorSchema = {
7340
7381
  onLongPress: { $ref: "#/$defs/action" },
7341
7382
  badge: { $ref: "#/$defs/navBadge" },
7342
7383
  // RFC 0066 amendment "Top-bar avatar strip" (field 16) — the AvatarStrip props, drawn in the bar.
7343
- avatarStrip: { $ref: "#/$defs/toolbarAvatarStrip" }
7384
+ avatarStrip: { $ref: "#/$defs/toolbarAvatarStrip" },
7385
+ // RFC 0066 amendment "Bar types, styles, search, save and modes" (field 17).
7386
+ onLoadingTimeout: { $ref: "#/$defs/action" }
7344
7387
  }
7345
7388
  },
7346
7389
  // The proto `AvatarStripProps` as a toolbar item carries it. `caption`, `ringGradient` and `onTap` are
package/dist/cli.mjs CHANGED
@@ -4411,6 +4411,7 @@ var init_himi_package = __esm({
4411
4411
  var ICON_VIEW_BOX, ICON_STROKE_WIDTH, ICON_FALLBACK, ICON_CATALOG, ICON_NORMALIZED_INDEX, ICON_NAMES;
4412
4412
  var init_icon_catalog_generated = __esm({
4413
4413
  "../../core/ts/src/icon-catalog.generated.ts"() {
4414
+ "use strict";
4414
4415
  init_define_HHP_CATALOG();
4415
4416
  ICON_VIEW_BOX = 24;
4416
4417
  ICON_STROKE_WIDTH = 2;
@@ -19120,11 +19121,47 @@ var init_validator = __esm({
19120
19121
  dirtyPath: { type: "string" },
19121
19122
  // RFC 0066 amendment "long press, bar visibility, tab-bar visibility" (field 15).
19122
19123
  visibilityPath: { type: "string" },
19123
- // RFC 0066 amendment "Title, leading and trailing completion" (field 17; 16 is `cover_tone`).
19124
- titleAlign: { type: "string" }
19124
+ // RFC 0066 amendment "Title, leading and trailing completion" (field 17).
19125
+ titleAlign: { type: "string" },
19126
+ // RFC 0066 amendment "Bar types, styles, search, save and modes" (fields 16, 18–20).
19127
+ coverTone: { type: "string" },
19128
+ solidAfter: { $ref: "#/$defs/topBarScrollEdge" },
19129
+ selection: { $ref: "#/$defs/topBarSelection" },
19130
+ edit: { $ref: "#/$defs/topBarEdit" }
19131
+ }
19132
+ },
19133
+ topBarScrollEdge: {
19134
+ type: "object",
19135
+ additionalProperties: false,
19136
+ properties: {
19137
+ nodeId: { type: "string" },
19138
+ offset: { type: "number" }
19125
19139
  }
19126
19140
  },
19127
- // RFC 0010 "Native top-bar search" (SearchableConfig fields 1–15). `placement` stays a free string.
19141
+ topBarSelection: {
19142
+ type: "object",
19143
+ additionalProperties: false,
19144
+ properties: {
19145
+ activePath: { type: "string" },
19146
+ countPath: { type: "string" },
19147
+ titleFormat: { type: "string" },
19148
+ onClose: { $ref: "#/$defs/action" },
19149
+ items: { type: "array", items: { $ref: "#/$defs/toolbarItem" } },
19150
+ selectAll: { $ref: "#/$defs/toolbarItem" }
19151
+ }
19152
+ },
19153
+ topBarEdit: {
19154
+ type: "object",
19155
+ additionalProperties: false,
19156
+ properties: {
19157
+ activePath: { type: "string" },
19158
+ onEdit: { $ref: "#/$defs/action" },
19159
+ onDone: { $ref: "#/$defs/action" },
19160
+ onCancel: { $ref: "#/$defs/action" }
19161
+ }
19162
+ },
19163
+ // RFC 0010 "Native top-bar search" (SearchableConfig fields 1–15) + RFC 0066 amendment "Bar types, styles,
19164
+ // search, save and modes" (16–20). `placement` and the results state stay free strings.
19128
19165
  searchableConfig: {
19129
19166
  type: "object",
19130
19167
  additionalProperties: false,
@@ -19143,7 +19180,12 @@ var init_validator = __esm({
19143
19180
  onSuggestionTap: { $ref: "#/$defs/action" },
19144
19181
  scopes: { type: "array", items: { $ref: "#/$defs/searchScope" } },
19145
19182
  scopePath: { type: "string" },
19146
- onScopeChange: { $ref: "#/$defs/action" }
19183
+ onScopeChange: { $ref: "#/$defs/action" },
19184
+ recentsPath: { type: "string" },
19185
+ onRecentTap: { $ref: "#/$defs/action" },
19186
+ onClearRecents: { $ref: "#/$defs/action" },
19187
+ resultsStatePath: { type: "string" },
19188
+ onRetry: { $ref: "#/$defs/action" }
19147
19189
  }
19148
19190
  },
19149
19191
  searchSuggestion: {
@@ -19189,7 +19231,9 @@ var init_validator = __esm({
19189
19231
  onLongPress: { $ref: "#/$defs/action" },
19190
19232
  badge: { $ref: "#/$defs/navBadge" },
19191
19233
  // RFC 0066 amendment "Top-bar avatar strip" (field 16) — the AvatarStrip props, drawn in the bar.
19192
- avatarStrip: { $ref: "#/$defs/toolbarAvatarStrip" }
19234
+ avatarStrip: { $ref: "#/$defs/toolbarAvatarStrip" },
19235
+ // RFC 0066 amendment "Bar types, styles, search, save and modes" (field 17).
19236
+ onLoadingTimeout: { $ref: "#/$defs/action" }
19193
19237
  }
19194
19238
  },
19195
19239
  // The proto `AvatarStripProps` as a toolbar item carries it. `caption`, `ringGradient` and `onTap` are
@@ -20223,7 +20267,13 @@ var init_declared_navigation_lint = __esm({
20223
20267
  "onRemove",
20224
20268
  "onCreate",
20225
20269
  "onCancel",
20226
- "onSubmit"
20270
+ "onSubmit",
20271
+ // RFC 0066 amendment "Bar types, styles, search, save and modes": the mode buttons and the recent-search rows.
20272
+ "onClose",
20273
+ "onEdit",
20274
+ "onDone",
20275
+ "onRecentTap",
20276
+ "onClearRecents"
20227
20277
  ]);
20228
20278
  tapField = (at2) => {
20229
20279
  const m2 = /(?:^|\.)([A-Za-z]+)(?:\[\d+\])?\.actionId$/.exec(at2);
@@ -23897,6 +23947,47 @@ function topBarFindings(descriptor) {
23897
23947
  out2.push({ path: `topBar.items[${idx}].badge`, ruleCode: "top_bar_badge_on_overflow", message: `An item in More Actions (${i2.placement === "overflow" ? '`placement: "overflow"`' : "moved there because the bar has more than two trailing slots (R2)"}) has a \`badge\`, and the menu row draws none. Move the item to a visible slot, or put the count in its \`label\`` });
23898
23948
  }
23899
23949
  });
23950
+ const setStr = (v2) => typeof v2 === "string" && v2 !== "";
23951
+ if (setStr(b3.coverTone)) {
23952
+ if (b3.style !== "immersive") {
23953
+ out2.push({ path: "topBar.coverTone", ruleCode: "top_bar_cover_tone_not_immersive", message: `\`coverTone\` is set, but \`style\` is ${JSON.stringify(b3.style ?? "")}, not "immersive". Only an immersive bar floats over a cover image, so every shell ignores the tone. Set \`style: "immersive"\`, or remove \`coverTone\`` });
23954
+ }
23955
+ if (!TOP_BAR_COVER_TONE_VALUES.has(b3.coverTone)) {
23956
+ out2.push({ path: "topBar.coverTone", ruleCode: "top_bar_unknown_cover_tone", message: `\`coverTone\` ${JSON.stringify(b3.coverTone)} is not a known value, so every shell reads it as "dark" (white icons). Use "dark" or "light"` });
23957
+ }
23958
+ }
23959
+ const solidAfter = b3.solidAfter;
23960
+ if (solidAfter && typeof solidAfter === "object" && !Array.isArray(solidAfter)) {
23961
+ if (!TOP_BAR_SCROLL_STYLES.has(String(b3.style ?? ""))) {
23962
+ out2.push({ path: "topBar.solidAfter", ruleCode: "top_bar_solid_after_opaque", message: `\`solidAfter\` is set, but \`style\` is ${JSON.stringify(b3.style ?? "")}. An opaque bar is solid from the start, so it is ignored. Set \`style: "transparent"\` or \`"immersive"\`, or remove \`solidAfter\`` });
23963
+ }
23964
+ const nodeId = solidAfter.nodeId;
23965
+ if (setStr(nodeId) && !nodeId.includes("$") && !componentNodes(descriptor).some((v2) => v2.node.id === nodeId)) {
23966
+ const raw = solidAfter.offset;
23967
+ const fallback = typeof raw === "number" && Number.isFinite(raw) ? Math.max(0, raw) : 0;
23968
+ const what = fallback === 0 ? "so the bar starts to fill as soon as the screen scrolls" : `so the bar stays clear for ${fallback}pt of scroll and then fades in, whatever the hero's height`;
23969
+ out2.push({ path: "topBar.solidAfter.nodeId", ruleCode: "top_bar_solid_after_unknown_node", message: `\`solidAfter.nodeId\` ${JSON.stringify(nodeId)} names no component on this screen. Every shell falls back to offset ${fallback}, ${what}. Give the hero image (or the node whose bottom edge ends the clear bar) this \`id\`` });
23970
+ }
23971
+ }
23972
+ const block = (v2) => v2 && typeof v2 === "object" && !Array.isArray(v2) ? v2 : null;
23973
+ for (const mode of ["selection", "edit"]) {
23974
+ const m2 = block(b3[mode]);
23975
+ if (m2 && !setStr(m2.activePath)) {
23976
+ out2.push({ path: `topBar.${mode}`, ruleCode: "top_bar_mode_no_active_path", message: `\`${mode}\` has no \`activePath\`, so the mode is never on and no shell draws it. Bind \`activePath\` to a \`$service:\` bool that the worker sets while the screen is in ${mode === "selection" ? "selection" : "edit"} mode` });
23977
+ }
23978
+ }
23979
+ const sel = block(b3.selection);
23980
+ const timed = [
23981
+ ...items.map((i2, idx) => [`topBar.items[${idx}]`, i2]),
23982
+ ...Array.isArray(sel?.items) ? sel.items.map((i2, idx) => [`topBar.selection.items[${idx}]`, i2]) : [],
23983
+ ...sel?.selectAll != null ? [["topBar.selection.selectAll", sel.selectAll]] : []
23984
+ ];
23985
+ for (const [at2, raw] of timed) {
23986
+ const i2 = raw;
23987
+ if (i2 && typeof i2 === "object" && i2.onLoadingTimeout != null && !setStr(i2.loadingPath)) {
23988
+ out2.push({ path: `${at2}.onLoadingTimeout`, ruleCode: "top_bar_loading_timeout_no_loading_path", message: "`onLoadingTimeout` is set on an item with no `loadingPath`. The 30-second timer runs only while `loadingPath` is truthy, so it never fires. Bind `loadingPath` to the busy flag of this item's own action (the save, the delete)" });
23989
+ }
23990
+ }
23900
23991
  const notHttps = (v2) => {
23901
23992
  if (typeof v2 !== "string" || v2 === "") return false;
23902
23993
  if (!/^https:\/\/[^/?#\s]/i.test(v2)) return true;
@@ -23966,6 +24057,16 @@ function topBarFindings(descriptor) {
23966
24057
  if (scopeKeys.length > 0) {
23967
24058
  out2.push({ path: `topBar.searchable.${scopeKeys[0]}`, ruleCode: "top_bar_search_scopes_not_drawn", message: `Search scopes are on the wire for a later release: no shell draws ${scopeKeys.join(", ")} yet (RFC 0010). Draw scope controls as the screen's own content` });
23968
24059
  }
24060
+ const stateKeys = ["resultsStatePath", "recentsPath"].filter((k3) => setStr(s5[k3]));
24061
+ if (stateKeys.length > 0 && s5.onChange == null && s5.onSubmit == null) {
24062
+ out2.push({ path: `topBar.searchable.${stateKeys[0]}`, ruleCode: "top_bar_search_states_no_query", message: `\`${stateKeys.join("`, `")}\` ${stateKeys.length > 1 ? "are" : "is"} set on a search with no \`onChange\` or \`onSubmit\`, so no query reaches the worker and the states never change. Add the handler that runs the search` });
24063
+ }
24064
+ if (s5.onRetry != null && !setStr(s5.resultsStatePath)) {
24065
+ out2.push({ path: "topBar.searchable.onRetry", ruleCode: "top_bar_search_retry_no_state", message: "`onRetry` is set with no `resultsStatePath`. Try Again shows only in the error state, which `resultsStatePath` reports, so it never shows. Bind `resultsStatePath`" });
24066
+ }
24067
+ if ((s5.onRecentTap != null || s5.onClearRecents != null) && !setStr(s5.recentsPath)) {
24068
+ out2.push({ path: `topBar.searchable.${s5.onRecentTap != null ? "onRecentTap" : "onClearRecents"}`, ruleCode: "top_bar_search_recents_no_path", message: "`onRecentTap` / `onClearRecents` is set with no `recentsPath`, so no recent search is drawn and nothing can be tapped or cleared. Bind `recentsPath`" });
24069
+ }
23969
24070
  for (const key4 of TOP_BAR_SEARCH_BINDINGS) {
23970
24071
  const v2 = s5[key4];
23971
24072
  if (typeof v2 === "string" && v2.startsWith("$local:")) {
@@ -25145,7 +25246,7 @@ function validateAppWebViewInstances(screens, opts) {
25145
25246
  ];
25146
25247
  return webViewEmbeddedIssues(findings).map((issue3, i2) => ({ ...issue3, screenId: findings[i2].screenId }));
25147
25248
  }
25148
- var CRAWL_BLOCKING_PASSES, BOOT_EVAL_TIMEOUT_MS, BUNDLE_FILENAME, DRIFT_PROBES, DEVICE_NETWORK_WITHHELD, DEVICE_STRIPPED_HOST_GLOBALS, DEVICE_WITHHELD, DEVICE_PARITY_CANDIDATES, DEVICE_PARITY_WITHHELD, defaultEvaluator, bootEvaluator, actionEvaluator, NATIVE_PROP_ENUMS, KNOWN_PROPS, IN_ARRAY_BINDING_PROPS, SERVICE_SIGIL, INTEGER_PROPS, NESTED_COMPONENT_SLOTS, NESTED_SLOT_DECODE_KILL, NATIVE_REQUIRED_PROPS, bareNestedClass, NATIVE_NESTED_CLASSES, NATIVE_MODIFIERS_CLASS, NATIVE_NESTED_SCALARS, NATIVE_DESCRIPTOR_CLASS, NATIVE_DESCRIPTOR_NESTED, NATIVE_NESTED_PROPS, LENIENT_TOP_BAR_BLOCKS, MODIFIER_KEYS, INTEGER_MODIFIERS, MODIFIER_KINDS, SCHEMA_SCORED_NODES, CORE_PACKAGES, LEGACY_UNSCORED_KEYS, DYNAMIC_PLACEHOLDER, LITERAL_ONLY_PROPS, SERVICE_ONLY_BINDING_PROPS, WHOLE_VALUE_BINDING, EMBEDDED_BINDING, OPTIONS_BINDING_PROPS, EDITOR_SERVICE_NAME, SHEET_PLACEMENTS, UNSAFE_TO_RECURSE_DEPTH, TOP_BAR_TRAILING_LIMIT, TOP_BAR_NON_TRAILING, TOP_BAR_TITLE_ALIGN_VALUES, TOP_BAR_TITLE_DISPLAY_VALUES, TOP_BAR_SEARCH_BINDINGS, TOP_BAR_SEARCH_GATE, PRESS_PROPS, PRESS_OWNING_SLOTS, TAB_BAR_KINDS_WITHOUT_BOTTOM_TABS, ORIENTATION_NAMES, DEFAULT_ENVELOPE, BUTTON_STYLES, PROP_VALUE_ENUMS, PROP_VALUE_DEFAULTS, EMPTY_STATE_ACTION_STYLES, EMPTY_STATE_ACTION_SIZES;
25249
+ var CRAWL_BLOCKING_PASSES, BOOT_EVAL_TIMEOUT_MS, BUNDLE_FILENAME, DRIFT_PROBES, DEVICE_NETWORK_WITHHELD, DEVICE_STRIPPED_HOST_GLOBALS, DEVICE_WITHHELD, DEVICE_PARITY_CANDIDATES, DEVICE_PARITY_WITHHELD, defaultEvaluator, bootEvaluator, actionEvaluator, NATIVE_PROP_ENUMS, KNOWN_PROPS, IN_ARRAY_BINDING_PROPS, SERVICE_SIGIL, INTEGER_PROPS, NESTED_COMPONENT_SLOTS, NESTED_SLOT_DECODE_KILL, NATIVE_REQUIRED_PROPS, bareNestedClass, NATIVE_NESTED_CLASSES, NATIVE_MODIFIERS_CLASS, NATIVE_NESTED_SCALARS, NATIVE_DESCRIPTOR_CLASS, NATIVE_DESCRIPTOR_NESTED, NATIVE_NESTED_PROPS, LENIENT_TOP_BAR_BLOCKS, MODIFIER_KEYS, INTEGER_MODIFIERS, MODIFIER_KINDS, SCHEMA_SCORED_NODES, CORE_PACKAGES, LEGACY_UNSCORED_KEYS, DYNAMIC_PLACEHOLDER, LITERAL_ONLY_PROPS, SERVICE_ONLY_BINDING_PROPS, WHOLE_VALUE_BINDING, EMBEDDED_BINDING, OPTIONS_BINDING_PROPS, EDITOR_SERVICE_NAME, SHEET_PLACEMENTS, UNSAFE_TO_RECURSE_DEPTH, TOP_BAR_TRAILING_LIMIT, TOP_BAR_NON_TRAILING, TOP_BAR_TITLE_ALIGN_VALUES, TOP_BAR_TITLE_DISPLAY_VALUES, TOP_BAR_COVER_TONE_VALUES, TOP_BAR_SCROLL_STYLES, TOP_BAR_SEARCH_BINDINGS, TOP_BAR_SEARCH_GATE, PRESS_PROPS, PRESS_OWNING_SLOTS, TAB_BAR_KINDS_WITHOUT_BOTTOM_TABS, ORIENTATION_NAMES, DEFAULT_ENVELOPE, BUTTON_STYLES, PROP_VALUE_ENUMS, PROP_VALUE_DEFAULTS, EMPTY_STATE_ACTION_STYLES, EMPTY_STATE_ACTION_SIZES;
25149
25250
  var init_validate_descriptor_core = __esm({
25150
25251
  "../../core/dev-server/src/validate-descriptor.core.ts"() {
25151
25252
  init_define_HHP_CATALOG();
@@ -26343,7 +26444,9 @@ var init_validate_descriptor_core = __esm({
26343
26444
  TOP_BAR_NON_TRAILING = /* @__PURE__ */ new Set(["leading", "principal", "bottom", "keyboard", "overflow"]);
26344
26445
  TOP_BAR_TITLE_ALIGN_VALUES = /* @__PURE__ */ new Set(["", "auto", "leading", "center"]);
26345
26446
  TOP_BAR_TITLE_DISPLAY_VALUES = /* @__PURE__ */ new Set(["", "automatic", "large", "inline", "hidden"]);
26346
- TOP_BAR_SEARCH_BINDINGS = ["valuePath", "focusPath", "loadingPath", "suggestionsPath", "scopePath"];
26447
+ TOP_BAR_COVER_TONE_VALUES = /* @__PURE__ */ new Set(["", "dark", "light"]);
26448
+ TOP_BAR_SCROLL_STYLES = /* @__PURE__ */ new Set(["transparent", "immersive"]);
26449
+ TOP_BAR_SEARCH_BINDINGS = ["valuePath", "focusPath", "loadingPath", "suggestionsPath", "scopePath", "recentsPath", "resultsStatePath"];
26347
26450
  TOP_BAR_SEARCH_GATE = "$env:topBarSearch";
26348
26451
  PRESS_PROPS = /* @__PURE__ */ new Set(["action", "onTap"]);
26349
26452
  PRESS_OWNING_SLOTS = /* @__PURE__ */ new Set(["anchor", "submitButton"]);
@@ -40430,7 +40533,6 @@ function resolveIdiom(tokens2, ctx = {}) {
40430
40533
  var IDIOM_CONTEXTS, UNSAFE_KEYS;
40431
40534
  var init_idiom = __esm({
40432
40535
  "../../core/ts/src/idiom.ts"() {
40433
- "use strict";
40434
40536
  init_define_HHP_CATALOG();
40435
40537
  IDIOM_CONTEXTS = {
40436
40538
  ios: { native: ["ios"] },
@@ -180760,6 +180862,33 @@ var init_surface_lint = __esm({
180760
180862
  }
180761
180863
  });
180762
180864
 
180865
+ // ../../core/ts/src/top-bar-fill.ts
180866
+ function topBarFill(color) {
180867
+ const fill2 = color.slice(0, 7).toUpperCase();
180868
+ const light = contrastRatio4(fill2, TOP_BAR_LIGHT_FOREGROUND);
180869
+ const dark = contrastRatio4(fill2, TOP_BAR_DARK_FOREGROUND);
180870
+ const foreground = light >= dark ? TOP_BAR_LIGHT_FOREGROUND : TOP_BAR_DARK_FOREGROUND;
180871
+ const drawn = deriveAccentText(fill2, foreground);
180872
+ return {
180873
+ fill: fill2,
180874
+ foreground,
180875
+ ratio: round2(Math.max(light, dark)),
180876
+ drawn,
180877
+ drawnRatio: round2(contrastRatio4(drawn, foreground)),
180878
+ nudged: drawn !== fill2
180879
+ };
180880
+ }
180881
+ var TOP_BAR_DARK_FOREGROUND, TOP_BAR_LIGHT_FOREGROUND, round2;
180882
+ var init_top_bar_fill = __esm({
180883
+ "../../core/ts/src/top-bar-fill.ts"() {
180884
+ init_define_HHP_CATALOG();
180885
+ init_brand_color_math();
180886
+ TOP_BAR_DARK_FOREGROUND = "#1A1B20";
180887
+ TOP_BAR_LIGHT_FOREGROUND = "#FFFFFF";
180888
+ round2 = (n2) => Math.round(n2 * 100) / 100;
180889
+ }
180890
+ });
180891
+
180763
180892
  // src/token-lint.ts
180764
180893
  import { existsSync as existsSync68, readFileSync as readFileSync74 } from "node:fs";
180765
180894
  import { join as join64 } from "node:path";
@@ -180994,6 +181123,8 @@ function tokenColorIssues(dir, tokensPathOverride) {
180994
181123
  }
180995
181124
  const base2 = contrastFindings(colors);
180996
181125
  for (const f2 of base2) (f2.invisible ? error : warn4)(`${tokensPath}: ${f2.render(f2.schemes)}`);
181126
+ for (const message5 of topBarFillWarnings(colors)) warn4(`${tokensPath}: ${message5}`);
181127
+ const baseBarKeys = topBarFillNudgedKeys(colors);
180997
181128
  if (idiom !== null && typeof idiom === "object" && !Array.isArray(idiom)) {
180998
181129
  const seen = new Set(base2.flatMap((f2) => f2.schemes.map((s5) => `${f2.key}|${s5}`)));
180999
181130
  for (const [overlay, layer] of Object.entries(idiom)) {
@@ -181004,10 +181135,39 @@ function tokenColorIssues(dir, tokensPathOverride) {
181004
181135
  const added = f2.schemes.filter((s5) => !seen.has(`${f2.key}|${s5}`));
181005
181136
  if (added.length) (f2.invisible ? error : warn4)(`${tokensPath}: under the idiom.${overlay} overlay, ${f2.render(added)}`);
181006
181137
  }
181138
+ for (const message5 of topBarFillWarnings(merged, baseBarKeys)) {
181139
+ warn4(`${tokensPath}: under the idiom.${overlay} overlay, ${message5}`);
181140
+ }
181007
181141
  }
181008
181142
  }
181009
181143
  return issues;
181010
181144
  }
181145
+ function topBarFillNudgedKeys(colors) {
181146
+ const keys2 = /* @__PURE__ */ new Set();
181147
+ for (const scheme of SCHEMES) {
181148
+ const hex2 = schemeValue(colors.accentPrimary, scheme);
181149
+ if (hex2 && topBarFill(hex2).nudged) keys2.add(`${topBarFill(hex2).fill}|${scheme}`);
181150
+ }
181151
+ return keys2;
181152
+ }
181153
+ function topBarFillWarnings(colors, already = /* @__PURE__ */ new Set()) {
181154
+ const token = colors.accentPrimary;
181155
+ const byValue = /* @__PURE__ */ new Map();
181156
+ for (const scheme of SCHEMES) {
181157
+ const hex2 = schemeValue(token, scheme);
181158
+ if (hex2 && !already.has(`${topBarFill(hex2).fill}|${scheme}`)) byValue.set(hex2, [...byValue.get(hex2) ?? [], scheme]);
181159
+ }
181160
+ const out2 = [];
181161
+ for (const [hex2, schemes] of byValue) {
181162
+ const fill2 = topBarFill(hex2);
181163
+ if (!fill2.nudged) continue;
181164
+ const where = schemes.length === SCHEMES.length ? "" : ` (in ${schemes.join(" / ")})`;
181165
+ out2.push(
181166
+ `colors.accentPrimary ${fill2.fill}${where} reaches only ${fill2.ratio.toFixed(2)}:1 with ${fill2.foreground} text, under ${AA_TEXT}:1. A brand top bar draws ${fill2.drawn} instead (${fill2.drawnRatio.toFixed(2)}:1; RFC 0066 S-CONTR). ${TOP_BAR_LOW_CONTRAST_MESSAGE}`
181167
+ );
181168
+ }
181169
+ return out2;
181170
+ }
181011
181171
  function schemeValue(token, scheme) {
181012
181172
  let v2 = token;
181013
181173
  if (token !== null && typeof token === "object" && !Array.isArray(token)) {
@@ -181172,7 +181332,7 @@ function accentOnSurfacesFor(fgName, role, colors, declared, findings) {
181172
181332
  }
181173
181333
  }
181174
181334
  }
181175
- var INTEGER_TOKEN_FIELDS, INTEGER_TOKEN_MAPS, AA_TEXT, INVISIBLE_TEXT, CONTRAST_PAIRS, SCHEMES, channels3, toHex2, mixHex, onLightSide, SURFACE_TEXT_USE, SURFACE_TEXT_TOKENS;
181335
+ var INTEGER_TOKEN_FIELDS, INTEGER_TOKEN_MAPS, TOP_BAR_LOW_CONTRAST_MESSAGE, AA_TEXT, INVISIBLE_TEXT, CONTRAST_PAIRS, SCHEMES, channels3, toHex2, mixHex, onLightSide, SURFACE_TEXT_USE, SURFACE_TEXT_TOKENS;
181176
181336
  var init_token_lint = __esm({
181177
181337
  "src/token-lint.ts"() {
181178
181338
  init_define_HHP_CATALOG();
@@ -181180,12 +181340,14 @@ var init_token_lint = __esm({
181180
181340
  init_token_colors();
181181
181341
  init_idiom();
181182
181342
  init_brand_color_math();
181343
+ init_top_bar_fill();
181183
181344
  INTEGER_TOKEN_FIELDS = [
181184
181345
  { group: "typography", field: "size", unit: "points" },
181185
181346
  { group: "typography", field: "weight", unit: "a font weight such as 400 or 700" },
181186
181347
  { group: "motions", field: "duration", unit: "milliseconds" }
181187
181348
  ];
181188
181349
  INTEGER_TOKEN_MAPS = ["spacing", "radius"];
181350
+ TOP_BAR_LOW_CONTRAST_MESSAGE = "Text on this color may be hard to read. We adjusted the top bar so members can read it.";
181189
181351
  AA_TEXT = 4.5;
181190
181352
  INVISIBLE_TEXT = 1.5;
181191
181353
  CONTRAST_PAIRS = [
@@ -190240,6 +190402,21 @@ __export(nav_lint_exports, {
190240
190402
  navSharedIdErrors: () => navSharedIdErrors,
190241
190403
  pushRouteAdvisories: () => pushRouteAdvisories
190242
190404
  });
190405
+ function screenOnlyDefaultMessage(key4, value2) {
190406
+ const at2 = `navigation.topBarDefault.${key4}`;
190407
+ switch (key4) {
190408
+ case "scrollBehavior":
190409
+ return `${at2} ${JSON.stringify(value2)} makes the bar of EVERY screen that sets no \`topBar\` hide on scroll, forms and presented screens included. Set \`topBar.scrollBehavior\` on the screens that scroll long content.`;
190410
+ case "coverTone":
190411
+ case "solidAfter":
190412
+ return `${at2} describes one screen's cover image (its tone, or the node the bar turns solid after), but the default is copied onto every screen that sets no \`topBar\`, and those have a different hero or none. Set \`topBar.${key4}\` on the screen that draws the cover.`;
190413
+ case "selection":
190414
+ case "edit":
190415
+ return `${at2} is a mode bound to one screen's state: the default is copied onto every screen that sets no \`topBar\`, and each would resolve its \`activePath\` against its own worker. Set \`topBar.${key4}\` on the screen that has the mode.`;
190416
+ default:
190417
+ return `${at2} is a binding to one screen's state: the default is copied onto every screen that sets no \`topBar\`, and each would resolve it against its own worker. Set \`topBar.${key4}\` on the screen that owns the value.`;
190418
+ }
190419
+ }
190243
190420
  async function navIssues(dir, strict) {
190244
190421
  const issues = [];
190245
190422
  const push = (severity, ruleCode, message5) => issues.push({ screen: null, pass: "nav", severity, message: message5, ruleCode });
@@ -190384,11 +190561,8 @@ async function navIssues(dir, strict) {
190384
190561
  if (isPlainObject4(topBarDefault)) {
190385
190562
  for (const key4 of SCREEN_ONLY_TOP_BAR_KEYS) {
190386
190563
  const value2 = topBarDefault[key4];
190387
- if (value2 === void 0 || value2 === null || value2 === "" || key4 === "scrollBehavior" && value2 === "pinned") continue;
190388
- warn4(
190389
- "nav-topbar-default-screen-field",
190390
- key4 === "scrollBehavior" ? `navigation.topBarDefault.scrollBehavior ${JSON.stringify(value2)} makes the bar of EVERY screen that sets no \`topBar\` hide on scroll, forms and presented screens included. Set \`topBar.scrollBehavior\` on the screens that scroll long content.` : `navigation.topBarDefault.${key4} is a binding to one screen's state: the default is copied onto every screen that sets no \`topBar\`, and each would resolve it against its own worker. Set \`topBar.${key4}\` on the screen that owns the value.`
190391
- );
190564
+ if (value2 === void 0 || value2 === null || value2 === "" || key4 === "scrollBehavior" && value2 === "pinned" || key4 === "coverTone" && value2 === "dark") continue;
190565
+ warn4("nav-topbar-default-screen-field", screenOnlyDefaultMessage(key4, value2));
190392
190566
  }
190393
190567
  }
190394
190568
  if (isPlainObject4(topBarDefault)) {
@@ -190647,7 +190821,7 @@ var init_nav_lint = __esm({
190647
190821
  "deepLinkPatterns",
190648
190822
  "linkableScreens"
190649
190823
  ];
190650
- SCREEN_ONLY_TOP_BAR_KEYS = ["scrollBehavior", "dirtyPath", "visibilityPath"];
190824
+ SCREEN_ONLY_TOP_BAR_KEYS = ["scrollBehavior", "dirtyPath", "visibilityPath", "coverTone", "solidAfter", "selection", "edit"];
190651
190825
  isPlainObject4 = (v2) => typeof v2 === "object" && v2 !== null && !Array.isArray(v2);
190652
190826
  itemCount = (v2) => isPlainObject4(v2) && Array.isArray(v2.items) ? v2.items.length : 0;
190653
190827
  }
@@ -421,6 +421,13 @@ Concrete patterns lifted from real usage:
421
421
  - **Row with a leading label and trailing detail** — `hstack({ spacing: 8, children: [ icon, text, spacer(), trailingText ] })`. The `spacer()` does the push; don't hand-pad.
422
422
  - **Fill-width controls share a row** — put fill-width controls in **one** `HStack` and let them share it (weight/flex), rather than stacking `fillMaxWidth` elements. This is a real iOS↔Android parity requirement, not a preference — a full-width control alone in an HStack renders differently across platforms.
423
423
  - **A screen that owns its top bar (search beside back)** — set `topBar: { leading: "none" }` and put the row in `stickyHeader`: `hstack([ iconButton({ icon: "arrow_left", accessibilityLabel: "Back", action: { actionId: "nav.back", presentation: "back" } }), withModifiers(textField({ placeholder: "Search", … }), { weight: 1 }) ])`. With **both** set, every shell draws no bar and no back control of its own (iOS hides the system bar, Android floats no chevron and reserves no band, web hides its bar on every look), so the row is the only top bar. `leading: "none"` without a `stickyHeader` keeps the bar's title and trailing actions but drops the back control (and the hamburger, for that screen). System back — hardware, gesture, edge swipe, browser — still pops. Any other `leading` value keeps today's chrome; demo: `gallery_search_topbar`, linked from the gallery's "Lists & data".
424
+ - **Top-bar styles and modes (contract only for now — check the status table before you rely on one)** — the bar, not your content, draws these; declare them on `topBar`:
425
+ - *Root titles:* `titleDisplay: "large"` on a tab root (a large title that collapses as you scroll; lists), `"inline"` for short task screens. `""` keeps today's look.
426
+ - *Cover:* `style: "immersive"` with your hero as the first content node, plus `coverTone: "dark"` (white icons, the default) or `"light"` — pick it from the image under the bar, not the theme. Add `solidAfter: { nodeId: "<hero id>" }` to turn the bar solid once the hero scrolls away; `style: "transparent"` alone fills over the first 8pt.
427
+ - *Brand fill:* `background: { token: "accentPrimary" }`. The shell picks white or `#1A1B20` text and darkens or lightens a mid-tone just enough for 4.5:1; `himi validate` says so when your brand colour needs it.
428
+ - *Search states:* bind `searchable.recentsPath` (recent queries while the field is empty) and `searchable.resultsStatePath` (`"empty"` / `"error"`); the bar draws "No results" and the error with Try Again (`onRetry`). Do not draw these in the page.
429
+ - *Still saving:* give Save an `onLoadingTimeout` next to its `loadingPath`; the shell shows "Still saving…" at 10 s and calls it at 30 s so the worker can show the failed state.
430
+ - *Modes:* `selection: { activePath, countPath, onClose, items }` for bulk actions ("3 selected"), `edit: { activePath, onEdit, onDone, onCancel }` with `dirtyPath` for in-place editing. Bind each `activePath` to a worker bool; the bar swaps itself while it is true.
424
431
  - **Cell list** — one `Section` with `inset: true` and a `header`, its children the `ListItem` cells; the cells own their own dividers and padding. A schedule, a service menu and a session list are this shape too, not a `Card` around each item.
425
432
  - **Photo tile** — `vstack({ spacing: 6, alignment: "leading", children: [ image({ url, fillWidth: true, aspectRatio: 0.8, contentMode: "fill", placeholder: "surfaceSecondary", contentDescription }) + cornerRadius 8, text(name, "body"), text(price, "callout", { color: "textSecondary" }) ] })` with `modifiers.onTap` on the stack, inside `grid({ columns: 2, columnsMedium: 3, columnsExpanded: 4, spacing: 12 })`. A shelf is the same tile at a fixed `width` (about 110) in `lazyList({ horizontal: true, spacing: 12 })`.
426
433
  - **A website page with native UI around it** — `vstack({ children: [ header, sitePage(site, { path: "/book-online" }), stickyBar ] })`, where `site` is the app's `site` block (a `SiteShellConfig`) and `sitePage` comes from `@wix/himalaya/sdui`. It emits a `WebView` with `role: "primary"`, `fill`, its own scrolling, `modifiers.weight: 1` and the site preset as its config (the same URL and behaviour a site-shell tab gets; `webView: { … }` overrides it). `title` becomes the page's accessible name (`modifiers.accessibilityLabel`, which every `WebView` needs); without one the site's host is used. The weight gives the page only the height the header and bar leave. Put it at the screen root or directly in a root `VStack`, `HStack` or `ZStack`, and use one per screen. The validator rejects it inside a `LazyList`, `Pager`, `Carousel` or `CollapsingHeader`, or with its weight removed. A site-shell app already gets this form: `siteScreens(site)` gives each page both forms in one descriptor, the Tier-3 screen every app binary renders plus this tree in `payload`, which a newer binary draws instead. To put native UI around one page of a site-shell app and keep it working on older binaries, use `dualFormSiteScreen(defineSiteTab(site, page), vstack({ children: [ header, sitePage(site, { path: page.path, title: page.title }), stickyBar ] }))`. The page inside must load the same URL, with the same config and the same native capability scope (`capabilitiesRequired`), as the Tier-3 screen; `sitePage` scopes a page to no capability, as a site tab is. The validator checks all three (`dual_form_mismatch`), and the screen can carry no `logicBundle`. Older binaries draw only the Tier-3 page, without the header and bar. `siteScreens(site, { form: "node" })` serves the node form alone, for an app whose binaries all support it, and `desugarSiteScreen(descriptor)` converts one Tier-3 site screen. To let native UI follow the page (a cart badge, the page title), give the screen a `logicBundle` that declares `"webview"` and write `sitePage(site, { path, bridge: "worker" })`: the page talks to the worker through `@wix/himalaya/webview-page`, and the worker answers with `@himalaya/webview` ([webview-page-sdk.md](webview-page-sdk.md#a-site-page-that-talks-to-its-screens-worker)). Such a screen carries a worker, so it is a node-form screen (`sdui_layout`), not a dual-form one.
@@ -1604,7 +1604,7 @@
1604
1604
  "name": "TopBarConfig",
1605
1605
  "kind": "interface",
1606
1606
  "jsdoc": "/** The shell-owned top bar. The shell paints\n * `ScreenDescriptor.title` and computes the leading slot (back XOR menu) from\n * nav depth; this adds the trailing action cluster + leading/style overrides.\n * Lives on `ScreenDescriptor.topBar` (authoritative) and\n * `NavigationConfig.topBarDefault` (app-level fallback, fully replaced). */",
1607
- "decl": "export interface TopBarConfig {\n /** Trailing (right-edge) actions, authored order = leading→trailing. */\n actions?: TopBarAction[];\n /** Leading override: \"\" | \"auto\" (shell-computed) | \"back\" | \"menu\" | \"none\". */\n leading?: string;\n /** Content-under-bar: \"\" | \"opaque\" (default) | \"transparent\" | \"immersive\". */\n style?: string;\n /** Toolbar items (drawn after the legacy `actions`). */\n items?: ToolbarItem[];\n /** \"\" / \"automatic\" (default) | \"large\" | \"inline\" | \"hidden\". `\"hidden\"` draws no title and keeps\n * the title as the screen name for screen readers (amendment \"Title, leading and trailing completion\"). */\n titleDisplay?: string;\n /** The literal subtitle (the fallback for `subtitlePath`). */\n subtitle?: string;\n /** \"\" / \"visible\" (default) | \"hidden\". */\n visibility?: string;\n /** Bar fill token. iOS 26 keeps the system glass (amendment R12). */\n background?: TokenRef;\n /** \"Native top-bar search\" — the screen's search, drawn by whoever draws its bar natively (an embed's host\n * today: iOS `himalayaEmbedSearch`, Android `ProvideHimalayaEmbedSearch`). Read per screen only. */\n searchable?: SearchableConfig;\n /** amendment — the screen's logo; overrides `NavigationConfig.topBarLogo`. */\n logo?: TopBarLogo;\n /** amendment — the title as a menu. */\n titleMenu?: TopBarTitleMenu;\n /** amendment — live subtitle (`$service:`); `subtitle` is the fallback. */\n subtitlePath?: string;\n /** amendment — \"\" / \"pinned\" (default) | \"hide_on_scroll\". */\n scrollBehavior?: string;\n /** amendment — truthy ⇒ leaving the presentation asks to discard. Unset/unresolved ⇒ false. */\n dirtyPath?: string;\n /** amendment — live `visibility` (`$service:`). Resolves to \"visible\" | \"hidden\";\n * anything else, or unresolved, falls back to `visibility`. Not a truthy boolean. */\n visibilityPath?: string;\n /** amendment \"Title, leading and trailing completion\" — \"\" / \"auto\" (default) | \"leading\" | \"center\".\n * Unknown values read as \"auto\". Per screen; `NavigationConfig.topBarTitleAlign` is the app-wide twin. */\n titleAlign?: string;\n}",
1607
+ "decl": "export interface TopBarConfig {\n /** Trailing (right-edge) actions, authored order = leading→trailing. */\n actions?: TopBarAction[];\n /** Leading override: \"\" | \"auto\" (shell-computed) | \"back\" | \"menu\" | \"none\". */\n leading?: string;\n /** Content-under-bar: \"\" | \"opaque\" (default) | \"transparent\" | \"immersive\". */\n style?: string;\n /** Toolbar items (drawn after the legacy `actions`). */\n items?: ToolbarItem[];\n /** \"\" / \"automatic\" (default) | \"large\" | \"inline\" | \"hidden\". `\"hidden\"` draws no title and keeps\n * the title as the screen name for screen readers (amendment \"Title, leading and trailing completion\"). */\n titleDisplay?: string;\n /** The literal subtitle (the fallback for `subtitlePath`). */\n subtitle?: string;\n /** \"\" / \"visible\" (default) | \"hidden\". */\n visibility?: string;\n /** Bar fill token. iOS 26 keeps the system glass (amendment R12). */\n background?: TokenRef;\n /** \"Native top-bar search\" — the screen's search, drawn by whoever draws its bar natively (an embed's host\n * today: iOS `himalayaEmbedSearch`, Android `ProvideHimalayaEmbedSearch`). Read per screen only. */\n searchable?: SearchableConfig;\n /** amendment — the screen's logo; overrides `NavigationConfig.topBarLogo`. */\n logo?: TopBarLogo;\n /** amendment — the title as a menu. */\n titleMenu?: TopBarTitleMenu;\n /** amendment — live subtitle (`$service:`); `subtitle` is the fallback. */\n subtitlePath?: string;\n /** amendment — \"\" / \"pinned\" (default) | \"hide_on_scroll\". */\n scrollBehavior?: string;\n /** amendment — truthy ⇒ leaving the presentation asks to discard. Unset/unresolved ⇒ false. */\n dirtyPath?: string;\n /** amendment — live `visibility` (`$service:`). Resolves to \"visible\" | \"hidden\";\n * anything else, or unresolved, falls back to `visibility`. Not a truthy boolean. */\n visibilityPath?: string;\n /** amendment \"Title, leading and trailing completion\" — \"\" / \"auto\" (default) | \"leading\" | \"center\".\n * Unknown values read as \"auto\". Per screen; `NavigationConfig.topBarTitleAlign` is the app-wide twin. */\n titleAlign?: string;\n /** amendment \"Bar types, styles, search, save and modes\" — the tone of the cover image under an\n * `style: \"immersive\"` bar: \"\" / \"dark\" (default, white icons) | \"light\" (`#1A1B20` icons). Unknown ⇒ \"dark\". */\n coverTone?: string;\n /** amendment \"Bar types, styles, search, save and modes\" (cover to solid) — a transparent or immersive bar stays\n * clear until this edge, then fades to its fill over 24pt. Unset ⇒ the 0→8pt ramp of a transparent bar. */\n solidAfter?: TopBarScrollEdge;\n /** amendment \"Bar types, styles, search, save and modes\" — selection mode. */\n selection?: TopBarSelection;\n /** amendment \"Bar types, styles, search, save and modes\" — edit mode. Uses `dirtyPath`. */\n edit?: TopBarEdit;\n}",
1608
1608
  "verificationChecked": true
1609
1609
  },
1610
1610
  {
@@ -1681,7 +1681,7 @@
1681
1681
  "name": "ToolbarItem",
1682
1682
  "kind": "interface",
1683
1683
  "jsdoc": "/** One top-bar item. Test id `toolbar.<id>`\n * (`toolbar-<id>` on web and React Native). Every tap carries an existing `Action`\n *. Bindings are `$service:` sentinels resolved by the screen host. */",
1684
- "decl": "export interface ToolbarItem {\n id: string;\n /** \"leading\" | \"trailing\" (default) | \"principal\" | \"bottom\" | \"keyboard\" | \"overflow\". */\n placement?: string;\n /** Text button when there is no icon; the accessible name always. */\n label?: string;\n icon?: IconRef;\n onTap?: Action;\n /** \"\" | \"cancel\" | \"confirm\" | \"destructive\". */\n role?: string;\n disabled?: boolean;\n /** OR'd with `disabled`. For Save, bind \"nothing to save\" (e.g. `cannotSave`), never the dirty flag. */\n disabledPath?: string;\n /** Non-empty ⇒ the item opens a menu. */\n menu?: MenuItem[];\n /** \"principal\" only: a custom title view. */\n content?: Component;\n /** Truthy ⇒ a progress indicator replaces the item. Unset/unresolved ⇒ false. */\n loadingPath?: string;\n /** Set ⇒ the item draws an avatar; `label` stays the accessible name (\"Profile\" by default). */\n avatar?: ToolbarAvatar;\n /** Live label; `label` is the fallback. */\n labelPath?: string;\n /** Long press (touch), secondary click (pointer) or the \"More options\" accessibility action.\n * Never also fires `onTap`; ignored while disabled or loading, in More Actions, and with a `menu`. */\n onLongPress?: Action;\n /** amendment \"Title, leading and trailing completion\" — dot or count overlay. Ignored on an\n * \"overflow\" item. `badge.countLabel` is the noun the shell speaks after the count. */\n badge?: NavBadge;\n /** amendment \"Top-bar avatar strip\" — set ⇒ the item draws overlapping circular avatars\n * instead of its icon or label: size 20 and 3 visible plus a \"+N\" bubble unless set. `label` stays the\n * accessible name (\"Members, 5\"). The strip's `caption`, `ringGradient` and `onTap` are ignored in the bar:\n * the item's `onTap` and `onLongPress` fire. `avatarsPath` resolves on the screen, like the other\n * top-bar bindings. An \"overflow\" item draws its label row instead. */\n avatarStrip?: AvatarStripProps;\n}",
1684
+ "decl": "export interface ToolbarItem {\n id: string;\n /** \"leading\" | \"trailing\" (default) | \"principal\" | \"bottom\" | \"keyboard\" | \"overflow\". */\n placement?: string;\n /** Text button when there is no icon; the accessible name always. */\n label?: string;\n icon?: IconRef;\n onTap?: Action;\n /** \"\" | \"cancel\" | \"confirm\" | \"destructive\". */\n role?: string;\n disabled?: boolean;\n /** OR'd with `disabled`. For Save, bind \"nothing to save\" (e.g. `cannotSave`), never the dirty flag. */\n disabledPath?: string;\n /** Non-empty ⇒ the item opens a menu. */\n menu?: MenuItem[];\n /** \"principal\" only: a custom title view. */\n content?: Component;\n /** Truthy ⇒ a progress indicator replaces the item. Unset/unresolved ⇒ false. */\n loadingPath?: string;\n /** Set ⇒ the item draws an avatar; `label` stays the accessible name (\"Profile\" by default). */\n avatar?: ToolbarAvatar;\n /** Live label; `label` is the fallback. */\n labelPath?: string;\n /** Long press (touch), secondary click (pointer) or the \"More options\" accessibility action.\n * Never also fires `onTap`; ignored while disabled or loading, in More Actions, and with a `menu`. */\n onLongPress?: Action;\n /** amendment \"Title, leading and trailing completion\" — dot or count overlay. Ignored on an\n * \"overflow\" item. `badge.countLabel` is the noun the shell speaks after the count. */\n badge?: NavBadge;\n /** amendment \"Top-bar avatar strip\" — set ⇒ the item draws overlapping circular avatars\n * instead of its icon or label: size 20 and 3 visible plus a \"+N\" bubble unless set. `label` stays the\n * accessible name (\"Members, 5\"). The strip's `caption`, `ringGradient` and `onTap` are ignored in the bar:\n * the item's `onTap` and `onLongPress` fire. `avatarsPath` resolves on the screen, like the other\n * top-bar bindings. An \"overflow\" item draws its label row instead. */\n avatarStrip?: AvatarStripProps;\n /** amendment \"Bar types, styles, search, save and modes\" — with `loadingPath` truthy for 30 s the shell\n * stops the spinner and dispatches this; the worker shows the failed state. Unset ⇒ the spinner stays.\n * \"Still saving…\" shows under the bar at 10 s either way. */\n onLoadingTimeout?: Action;\n}",
1685
1685
  "verificationChecked": true
1686
1686
  },
1687
1687
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/himalaya-cli",
3
- "version": "0.1799.0",
3
+ "version": "0.1800.0",
4
4
  "type": "module",
5
5
  "description": "himi — the Himalaya authoring CLI. Build a Tier-5 content package on your own machine, push it to the production serve as a draft, preview it on web + Himi Player, and read worker logs back — the remote dev loop. Wraps @himalaya/serve-cli for transport.",
6
6
  "keywords": [
@@ -82,5 +82,5 @@
82
82
  "artifactId": "himalaya-cli"
83
83
  }
84
84
  },
85
- "falconPackageHash": "1a0c1ae9a8c6e2d248299c6cacc3dd8a06c5cf27dc0de7048925b263"
85
+ "falconPackageHash": "69b6e5032ee503e212d5d13fca9d6d106a0e85a1d66e128549eb2681"
86
86
  }