@stapel/search-react 0.11.0 → 0.13.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.
Files changed (125) hide show
  1. package/CHANGELOG.md +178 -0
  2. package/MODULE.md +118 -3
  3. package/README.md +42 -0
  4. package/dist/api/generated/schema.d.ts +60 -6
  5. package/dist/api/generated/schema.d.ts.map +1 -1
  6. package/dist/api/searchApi.d.ts +13 -6
  7. package/dist/api/searchApi.d.ts.map +1 -1
  8. package/dist/api/searchApi.js.map +1 -1
  9. package/dist/api/types.d.ts +107 -1
  10. package/dist/api/types.d.ts.map +1 -1
  11. package/dist/api/types.js +29 -0
  12. package/dist/api/types.js.map +1 -1
  13. package/dist/default/FacetPanelPane.d.ts +13 -2
  14. package/dist/default/FacetPanelPane.d.ts.map +1 -1
  15. package/dist/default/FacetPanelPane.js +3 -1
  16. package/dist/default/FacetPanelPane.js.map +1 -1
  17. package/dist/default/FilterChips.d.ts +88 -3
  18. package/dist/default/FilterChips.d.ts.map +1 -1
  19. package/dist/default/FilterChips.js +161 -13
  20. package/dist/default/FilterChips.js.map +1 -1
  21. package/dist/default/LocationSummaryLine.d.ts.map +1 -1
  22. package/dist/default/LocationSummaryLine.js +1 -1
  23. package/dist/default/LocationSummaryLine.js.map +1 -1
  24. package/dist/default/SearchBox.d.ts.map +1 -1
  25. package/dist/default/SearchBox.js +74 -4
  26. package/dist/default/SearchBox.js.map +1 -1
  27. package/dist/default/SearchPage.d.ts +29 -1
  28. package/dist/default/SearchPage.d.ts.map +1 -1
  29. package/dist/default/SearchPage.js +25 -10
  30. package/dist/default/SearchPage.js.map +1 -1
  31. package/dist/default/SearchResultCard.d.ts.map +1 -1
  32. package/dist/default/SearchResultCard.js +83 -37
  33. package/dist/default/SearchResultCard.js.map +1 -1
  34. package/dist/default/SearchResultsPane.d.ts +22 -0
  35. package/dist/default/SearchResultsPane.d.ts.map +1 -1
  36. package/dist/default/SearchResultsPane.js +2 -2
  37. package/dist/default/SearchResultsPane.js.map +1 -1
  38. package/dist/default/SortSelect.d.ts +23 -0
  39. package/dist/default/SortSelect.d.ts.map +1 -1
  40. package/dist/default/SortSelect.js +29 -9
  41. package/dist/default/SortSelect.js.map +1 -1
  42. package/dist/default/cardPhotos.d.ts +65 -0
  43. package/dist/default/cardPhotos.d.ts.map +1 -0
  44. package/dist/default/cardPhotos.js +127 -0
  45. package/dist/default/cardPhotos.js.map +1 -0
  46. package/dist/default/index.d.ts +2 -2
  47. package/dist/default/index.d.ts.map +1 -1
  48. package/dist/default/index.js +1 -1
  49. package/dist/default/index.js.map +1 -1
  50. package/dist/headless/FacetPanel.d.ts +10 -0
  51. package/dist/headless/FacetPanel.d.ts.map +1 -1
  52. package/dist/headless/FacetPanel.js +9 -1
  53. package/dist/headless/FacetPanel.js.map +1 -1
  54. package/dist/headless/useFacetLabels.d.ts +39 -0
  55. package/dist/headless/useFacetLabels.d.ts.map +1 -0
  56. package/dist/headless/useFacetLabels.js +129 -0
  57. package/dist/headless/useFacetLabels.js.map +1 -0
  58. package/dist/headless/useSearchBox.d.ts +71 -0
  59. package/dist/headless/useSearchBox.d.ts.map +1 -1
  60. package/dist/headless/useSearchBox.js +67 -2
  61. package/dist/headless/useSearchBox.js.map +1 -1
  62. package/dist/i18n/es.d.ts.map +1 -1
  63. package/dist/i18n/es.js +10 -0
  64. package/dist/i18n/es.js.map +1 -1
  65. package/dist/i18n/keys.d.ts +55 -0
  66. package/dist/i18n/keys.d.ts.map +1 -1
  67. package/dist/i18n/keys.js +67 -0
  68. package/dist/i18n/keys.js.map +1 -1
  69. package/dist/i18n/ru.d.ts.map +1 -1
  70. package/dist/i18n/ru.js +12 -0
  71. package/dist/i18n/ru.js.map +1 -1
  72. package/dist/index.d.ts +7 -5
  73. package/dist/index.d.ts.map +1 -1
  74. package/dist/index.js +4 -3
  75. package/dist/index.js.map +1 -1
  76. package/dist/model/queries.d.ts +6 -5
  77. package/dist/model/queries.d.ts.map +1 -1
  78. package/dist/model/queries.js +4 -3
  79. package/dist/model/queries.js.map +1 -1
  80. package/dist/model/queryKeys.d.ts +12 -0
  81. package/dist/model/queryKeys.d.ts.map +1 -1
  82. package/dist/model/queryKeys.js +7 -0
  83. package/dist/model/queryKeys.js.map +1 -1
  84. package/dist/model/runtime.d.ts +40 -3
  85. package/dist/model/runtime.d.ts.map +1 -1
  86. package/dist/model/runtime.js +2 -1
  87. package/dist/model/runtime.js.map +1 -1
  88. package/dist/nav/manifest.d.ts +21 -0
  89. package/dist/nav/manifest.d.ts.map +1 -1
  90. package/dist/nav/manifest.js +3 -2
  91. package/dist/nav/manifest.js.map +1 -1
  92. package/dist/state/facets.d.ts +56 -15
  93. package/dist/state/facets.d.ts.map +1 -1
  94. package/dist/state/facets.js +101 -27
  95. package/dist/state/facets.js.map +1 -1
  96. package/llms.txt +3 -3
  97. package/manifest.json +33 -4
  98. package/nav-manifest.json +4 -3
  99. package/package.json +11 -11
  100. package/src/analytics/generated/events.json +1 -1
  101. package/src/api/generated/schema.ts +60 -6
  102. package/src/api/searchApi.ts +13 -6
  103. package/src/api/types.ts +115 -1
  104. package/src/default/FacetPanelPane.tsx +16 -2
  105. package/src/default/FilterChips.tsx +285 -38
  106. package/src/default/LocationSummaryLine.tsx +6 -1
  107. package/src/default/SearchBox.tsx +134 -6
  108. package/src/default/SearchPage.tsx +79 -5
  109. package/src/default/SearchResultCard.tsx +157 -71
  110. package/src/default/SearchResultsPane.tsx +48 -11
  111. package/src/default/SortSelect.tsx +70 -9
  112. package/src/default/cardPhotos.ts +195 -0
  113. package/src/default/index.ts +10 -2
  114. package/src/headless/FacetPanel.tsx +20 -1
  115. package/src/headless/useFacetLabels.ts +172 -0
  116. package/src/headless/useSearchBox.ts +132 -5
  117. package/src/i18n/es.ts +11 -0
  118. package/src/i18n/keys.ts +69 -0
  119. package/src/i18n/ru.ts +13 -0
  120. package/src/index.ts +22 -3
  121. package/src/model/queries.ts +6 -5
  122. package/src/model/queryKeys.ts +23 -0
  123. package/src/model/runtime.ts +43 -4
  124. package/src/nav/manifest.ts +24 -2
  125. package/src/state/facets.ts +123 -39
package/CHANGELOG.md CHANGED
@@ -1,5 +1,183 @@
1
1
  # @stapel/search-react
2
2
 
3
+ ## 0.13.0
4
+
5
+ ### Minor Changes
6
+
7
+ - e76ab28: The default SERP card draws the photos — the whole gallery, not one, and not none.
8
+
9
+ `<SearchResultCard>` read `card.image` as an object with a `url` key and fell
10
+ back to `card.image_url`. Neither is a shape this fleet emits, so **every
11
+ consumer that did not pass its own `renderCard` got a card with no photo at
12
+ all**:
13
+
14
+ - `image_url` is a convention nothing in the fleet writes. It was declared in
15
+ `GENERIC_CARD_FIELDS`, drawn in the demos from a data URI, and never once
16
+ served by a backend.
17
+ - `card.image` IS emitted — `stapel-classified`'s search projection stores it —
18
+ and it is a plain `<type>/<hash>` CDN reference **string**, not an object.
19
+ - the one rich shape that exists (chat's subject card, which serves the same
20
+ CDN render descriptor its attachments carry) has `ref` + `variants[]` and no
21
+ top-level `url`, so the `"url" in rich` guard rejected it too.
22
+
23
+ **What the card reads now** (`default/cardPhotos.ts`, unit-tested as data):
24
+ `images[]` first — the whole seller-ordered gallery `stapel-classified` 0.7.0
25
+ projects, capped by its `CARD_IMAGES_LIMIT` — with the singular `image` as the
26
+ fallback for a doc type that never grew a list. Never both: `image` IS
27
+ `images[0]`, so reading the singular after the list would draw the first photo
28
+ twice. Each entry may be a CDN reference, a URL the doc type stored itself (a
29
+ reference is `<type>/<hash>`: no scheme, no leading slash, so the two are told
30
+ apart by shape and never by a guess), or a render descriptor, whose whole
31
+ variant ladder survives so `<Image>` still has tiers to choose between.
32
+
33
+ **How a reference becomes a picture: a new `resolveImage` seam** on
34
+ `createSearchRuntime`, the same seam `@stapel/listings-react` states and the
35
+ same function a container passes to both. No contract in this fleet resolves a
36
+ stranger's reference — stapel-cdn's `file/exists/` is owner-scoped — so the
37
+ deployment hands its own knowledge in once rather than having a library invent
38
+ a URL convention nobody agreed to.
39
+
40
+ **A gallery is a strip.** Two or more photos render as a `<SkinCarousel>` with
41
+ the peek and the position indicator (one photo gets neither: a sliver of a next
42
+ slide is an affordance for something that is not there). The strip is a
43
+ **sibling** of the card's anchor, never a child — a horizontal swipe that ends
44
+ inside an `<a>` can be delivered as a click, which is the defect that makes
45
+ phone galleries unusable.
46
+
47
+ **Three honest answers about a photo, drawn as three different things.** A card
48
+ with no photo field reserves nothing (a text corpus is not a gallery with holes
49
+ in it); a card whose references nothing resolved draws the well and _says_ the
50
+ photo is unavailable — that is what an unwired `resolveImage` looks like, and a
51
+ sentence gets it fixed where an empty grey box does not; anything else is the
52
+ strip.
53
+
54
+ BREAKING for a host that stored `card.image_url`: that field is no longer read
55
+ (nothing in the fleet wrote it). Store the URL in `image`/`images` instead — a
56
+ stored URL still needs no resolver.
57
+
58
+ New i18n keys in all three bundles: `search.results.photos`,
59
+ `search.results.photo_alt`, `search.results.photo_unavailable`.
60
+
61
+ ## 0.12.0
62
+
63
+ ### Minor Changes
64
+
65
+ - 8d1e20f: The phone dock stops truncating its labels, stops covering the footer, and the
66
+ phone SERP gets a one-line toolbar instead of four stacked rows.
67
+
68
+ **A compact label for a compact chrome.** `NavEntry.shortLabelKey` (core) is an
69
+ optional second i18n key a manifest declares when its menu label cannot fit a
70
+ dock cell. A five-item dock at 390px gives each destination about ten
71
+ characters, and a label written for a menu row ellipsizes mid-word — a
72
+ destination a person has to guess at, which is the one thing a dock must not
73
+ produce. A key and not a length hint, because which words survive the cut is a
74
+ translator's judgement: the useful short form of "Post a listing" is the verb,
75
+ of "My listings" the noun, and no truncation rule finds either. `resolveNav`
76
+ carries it through, `<NavDock>` prints it and keeps the LONG label as the
77
+ link's accessible name; `listings-react` declares one for `compose` and `mine`.
78
+ The dock also drops its inter-cell gap and one inset step — 24px given back to
79
+ five labels — and `scripts/gen-nav-manifest.mjs` validates the new field.
80
+
81
+ **The clearance belongs to the page, not the content.** The island is fixed
82
+ over the last thing on the page, and the last thing is the footer. Reserving
83
+ `DOCK_CLEARANCE` on `<Layout.Content>` cleared the final card and left the
84
+ footer's legal links permanently under the island. `<PublicShell>` reserves it
85
+ on the page column instead, and only when `dockRenders(nav)` says an island
86
+ will actually be drawn — a one-entry nav used to get a strip of empty page
87
+ under a dock nobody rendered.
88
+
89
+ **A phone toolbar that is one row.** `<SearchResultsPane header="compact">`
90
+ gives the toolbar its own line and puts the count directly above the cards as
91
+ their caption, with the heading visually hidden but still in the document
92
+ outline; the banner shape (heading | count + toolbar) is unchanged and
93
+ remains the default. `<SortSelect compact>` drops the caption and the 200px
94
+ floor so the control shares a row, and moves the blocked `distance` option's
95
+ REASON into the option's own label — on a phone, where that refusal is most
96
+ common, a separate reason row costs a band of viewport above the first result.
97
+ `<FilterChips>` takes `geoChip={false}` for a surface that already states the
98
+ location above it (the phone SERP mounts `<LocationSummaryLine>`, and the two
99
+ together asked about one filter twice), and renders NOTHING when it would be a
100
+ row of one button — a free-text query has no category, so the server returns no
101
+ facet plan, and the row was a lone circle floating between two working filter
102
+ affordances. `<LocationSummaryLine>` says "Filters", not "All filters": that
103
+ end of the row shares 390px with a place name.
104
+
105
+ **Tiles say which category they are.** `<CategoryTileGrid>` draws the
106
+ category's own initial where art is missing, instead of a muted disc. A live
107
+ catalogue put nine identical grey discs on one landing — every category there
108
+ carries an empty `carousel_icon`, which is the state every catalogue is in
109
+ until somebody uploads art — and a grid of them reads as nine images still
110
+ loading. A letter cannot be mistaken for a pending image, and every tile
111
+ differs from every other.
112
+
113
+ **`visuallyHidden`** (tokens-antd `/skin`) is the fleet's one off-screen-but-
114
+ announced style. It was written twice before, in `calendar-react` and
115
+ `search-react`, and the two disagreed on `clip-path` versus the deprecated
116
+ `clip`; both now import it.
117
+
118
+ - aa79a97: The result list gets a chip row a person can use, chips that print copy, a
119
+ category narrowing, and a search box that can reach a category.
120
+
121
+ **A facet a person cannot filter by is not a chip.** `FACETABLE_FEATURE_TYPES`
122
+ / `isFacetableFeature` decide from the category's own schema — the select
123
+ family, `bool`, and `attributes-react`'s own `VOCABULARY_BACKED_TYPES`,
124
+ imported rather than retyped. `imei` and `video_file_url` leave both the chip
125
+ row and the panel. Two edges are held on purpose: a group with NO feature def
126
+ is KEPT (the schema slot is optional, and treating silence as "not facetable"
127
+ would empty the row for every host that never threaded it), and a slug the URL
128
+ already filters on is kept whatever its type, or a shared link would narrow a
129
+ search with nothing on screen to widen it again.
130
+
131
+ **The row's leading edge is the filters people use.** `orderChipFilters` sorts
132
+ applied-first, then by band: core ranges (`facet_meta.core_ranges`), then
133
+ counted facet groups, then the category's numeric attributes. A live
134
+ classified deployment led with battery health and four delivery dimensions;
135
+ it now leads with category, price, condition and brand. Nothing is deleted —
136
+ `facet_meta.skipped` means the counter hit its field cap, not that the axis
137
+ is unfilterable, and `r.<slug>` still answers for a skipped slug, so removing
138
+ one on that signal would delete a working filter on a capacity report.
139
+
140
+ **A chip prints copy, not a storage slug.** Precedence, now answer-first:
141
+ `facet_labels` (the server saw the write-time snapshot) → the def's inline
142
+ `options` → the host's `resolveFacetLabels` → the raw value. The host seam is
143
+ batched per group through `useQueries`, cached, deduplicated across the three
144
+ components that read the panel, and given the query's own `AbortSignal`; it is
145
+ asked only about values nothing else named and cannot overwrite one that was.
146
+ A value nothing resolves keeps printing itself — a chip that silently drops an
147
+ option is worse than one showing a slug.
148
+
149
+ **A category narrowing on the row.** `renderCategoryFilter` and the new
150
+ `categoryLabel` reach `<FilterChips>` as the LEADING chip, opening the same
151
+ sheet every other chip does. There is no category facet on any server and the
152
+ index has no read path for one, so nothing here synthesizes counts. `hasChips`
153
+ now renders a row holding only the category chip and still renders nothing for
154
+ a row holding only the sliders circle.
155
+
156
+ **The search box offers CATEGORIES.** stapel-search 0.7.0's `/suggest` answers
157
+ a destination per row — the full ancestor path, the live count behind it, and
158
+ a `category` string to pass verbatim to `/query`. `useSearchBox` surfaces
159
+ `categories`, `categoriesUnavailable`, `categoryCountsUnknown` and
160
+ `chooseCategory`, and `<SearchBox>` draws them as a labelled group above the
161
+ term suggestions, each row printing the whole trail (which is what tells three
162
+ same-named leaves apart) and its counted sentence. Choosing one clears the
163
+ query text: keeping it would land the person on that section intersected with
164
+ a title search for the word that found it, which is fewer results than the
165
+ number they just tapped. A zero-count row is dropped — an empty section is a
166
+ dead end dressed as a destination — except under `category_rollup`, where the
167
+ zeroes mean the ancestry never arrived and it is the NUMBERS that are omitted.
168
+ `SuggestAnswer` deliberately widens the generated response type, whose fields
169
+ are all required: a pair typed against it would compile while reading
170
+ `undefined` from a field the compiler swore was there. An older server that
171
+ sends no `categories` key, and one that reports `category_suggestions` in
172
+ `degraded`, both draw no group at all — never an empty one, and nothing
173
+ anywhere says the catalogue has no matches.
174
+
175
+ **Nav labels.** `search.results` stopped borrowing `search.results.title` from
176
+ the results heading: one key was carrying the name of a DESTINATION and the
177
+ name of a LIST, and they diverge the moment the destination is a tab.
178
+ `search.nav.results` / `search.nav.ranking` are the nav's own, and the
179
+ disclosure entry declares a `shortLabelKey` for a phone dock.
180
+
3
181
  ## 0.11.0
4
182
 
5
183
  ### Minor Changes
package/MODULE.md CHANGED
@@ -112,9 +112,13 @@ are props, not dependencies (spec §6.2 items 1–2):
112
112
 
113
113
  - **`renderCard`** — `<ListingCard>` from `@stapel/listings-react/default`. The
114
114
  generic card here is a working default over a documented set of conventional
115
- `card` fields (`title`, `price`, `currency`, `location`, `image_url`), because
116
- `SearchItem.card` is deliberately free-form: "stored row fields, so a result
117
- page costs one query".
115
+ `card` fields (`title`, `price`, `currency`, `location`, `images`, `image`,
116
+ `url`), because `SearchItem.card` is deliberately free-form: "stored row
117
+ fields, so a result page costs one query". `images` is the whole gallery in
118
+ seller order (stapel-classified 0.7.0) and `image` is `images[0]`; both hold
119
+ opaque `<type>/<hash>` CDN references, so the card draws them through the
120
+ runtime's `resolveImage` seam — the same seam `@stapel/listings-react`
121
+ states, and the same function a container passes to both.
118
122
  - **`categoryFeatures`** — the category's feature schema, from
119
123
  `categories-react`. The server sends `{value: count}` and no labels; the
120
124
  captions are translation keys in that schema.
@@ -126,6 +130,117 @@ carries facet values as index TERMS (strings), so `facetOptionLabel` coerces
126
130
  back into the shape each type's formatter expects: `select` is a list even for
127
131
  one value, `date` is a Unix timestamp integer, `int`/`float` are numbers.
128
132
 
133
+ ## The search box reaches the catalogue
134
+
135
+ Until stapel-search 0.7.0 `/suggest` answered title prefixes only, so typing a
136
+ word that names a SECTION answered listing titles and nothing else — the search
137
+ field could not reach a category at all. 0.7.0 makes the answer two-part and
138
+ `categories` is the primary half:
139
+
140
+ | field | what it is |
141
+ |---|---|
142
+ | `path` | display names root→leaf — the only thing telling three same-named leaves apart |
143
+ | `category` | the ancestry as ids joined with `/`, to pass VERBATIM as the `category` parameter |
144
+ | `count` | live listings under it, descendants included — the number the SERP reports |
145
+ | `id` / `slug` / `name` / `depth` / `match` | identity, and how the name matched (informational; ranking is by `count`) |
146
+
147
+ `useSearchBox` surfaces them as `categories`, and `<SearchBox>` draws them as
148
+ their own labelled group ABOVE the terms, each row printing the path and the
149
+ count (a plural family — Russian needs four endings). Selecting one calls
150
+ `chooseCategory`, which writes `{ q: "", category: entry.category }` in ONE
151
+ patch: the server's own joined string, never a path the client reassembled, and
152
+ the text goes with it because the row quoted the section's count and the
153
+ destination has to show that count rather than the section intersected with a
154
+ title search.
155
+
156
+ Three honesty rules ride along:
157
+
158
+ - **absent key ⇒ today's behaviour.** Every member of `SuggestAnswer` but
159
+ `backend` is optional. The generated `SuggestResponse` declares 0.7.0's five
160
+ new fields required, which is true of one server and false of the others a
161
+ storefront is deployed against.
162
+ - **`degraded: ["category_suggestions"]` ⇒ no group at all.** An empty group
163
+ under a heading is the box claiming the catalogue has no such section — a
164
+ claim the answer never made. Not a banner either: the reader is mid-word and
165
+ a missing provider is the operator's business.
166
+ - **`degraded: ["category_rollup"]` ⇒ rows without numbers.** Every count reads
167
+ `0` because the ancestry never arrived, so the counts are dropped and the
168
+ destinations kept. Outside that case a `count: 0` row is filtered out: the
169
+ server really does return empty sections, and following one is a dead end
170
+ dressed as a destination.
171
+
172
+ ## Which counted slugs are filters, and who names their values
173
+
174
+ The facet plan is derived from the leaf category's feature defs and the counter
175
+ counts what is indexed, so a real classified answer carries `imei` and
176
+ `video_file_url` beside `condition` and `vendor`. Neither is a filter: an
177
+ identifier is unique per document and a URL is free text, and a chip offering
178
+ one IMEI with a count of one crowds a 390px row.
179
+
180
+ `FACETABLE_FEATURE_TYPES` is the verdict, read by value TYPE from the same
181
+ `categoryFeatures` schema everything else here reads — the select family, the
182
+ vocabulary-backed family (`VOCABULARY_BACKED_TYPES`, imported rather than
183
+ retyped) and `bool`. Two rules keep it honest:
184
+
185
+ - a slug with **no feature def** is KEPT. `categoryFeatures` is optional, a
186
+ feature can be retired after the write that indexed it, and answering "not
187
+ facetable" for silence would empty the row for every host that never threaded
188
+ the schema through;
189
+ - a slug the **URL already filters on** is KEPT whatever the schema now says,
190
+ or a link narrows the search with nothing on screen to widen it.
191
+
192
+ Captions have four sources, in this order, and none of them invents one:
193
+
194
+ 1. the answer's `facet_labels` (stapel-search 0.4.0+) — the server saw the
195
+ write-time snapshot;
196
+ 2. the feature def's inline `options` table;
197
+ 3. **`resolveFacetLabels`** — a host seam, `(slug, feature, values[]) →
198
+ Promise<{value: caption}>`, batched per group, cached, given the query's own
199
+ `AbortSignal`. It exists because a `ref_select` config carries a POINTER to a
200
+ vocabulary (`optionsRef`) and no options, and reading that vocabulary is the
201
+ host's business, not a search package's;
202
+ 4. the raw value — a value nobody names keeps printing itself rather than
203
+ disappearing, because a chip that silently drops an option is worse than one
204
+ showing a slug.
205
+
206
+ Set on `<SearchPage>`, it reaches both filter surfaces: the desktop panel and
207
+ the phone chip row read one `useFacetPanel`, so they cannot print two words for
208
+ one value.
209
+
210
+ ## The chip row's order is the row's product
211
+
212
+ At 390px about four chips fit before the fold. On a live phone category the
213
+ first seven were battery health, four parcel dimensions and two wholesale
214
+ counts — numeric attributes the category happens to declare, drawn ahead of the
215
+ price, the condition and the vendor.
216
+
217
+ That is an ordering defect and it is fixed as one. Nothing in a feature def
218
+ separates `akb` from `weight_for_delivery`, and the next category's `int`
219
+ attribute is `mileage`, so `orderChipFilters` re-ranks and deletes nothing:
220
+
221
+ 1. the category chip, then the location chip — the two host-slot filters;
222
+ 2. everything APPLIED, in band order — a constraint you set must be reachable
223
+ without a flick;
224
+ 3. then, unapplied: **core range axes** (`facet_meta.core_ranges`, the server
225
+ declaring an axis that exists for every document), **counted facet groups**
226
+ (the server counted them for this search and each carries its remaining
227
+ counts), then **the category's numeric attributes**, which nothing ranks.
228
+
229
+ The sort is stable, so an authored option order survives to the row. Deleting
230
+ band 3 was considered and rejected: the only server signal that names a slug is
231
+ `facet_meta.skipped`, and that means the counter hit `MAX_FACET_FIELDS` — not
232
+ that a person cannot filter by it. `r.<slug>` still answers for a skipped slug.
233
+
234
+ ## The chip row's leading chip is the category
235
+
236
+ There is no category facet on the server and no read path for one, so nothing
237
+ here synthesizes counts. What the SERP offers instead is a narrowing: the host's
238
+ `renderCategoryFilter` — the same slot the panel takes — becomes the FIRST chip
239
+ of the phone row, opening in the same sheet as every other chip, labelled with
240
+ `categoryLabel` (or the path's last segment) when the search is narrowed and
241
+ with the filter's own name when it is not. A host that fills no such slot gets
242
+ the row exactly as it was.
243
+
129
244
  ## Honesty flags are not decoration
130
245
 
131
246
  Four independent signals, all surfaced:
package/README.md CHANGED
@@ -83,6 +83,20 @@ two members, shaped exactly like react-router's `useSearchParams()`. `./router`
83
83
  ships that binding; a Next.js app, a hash router or a plain `URLSearchParams` in
84
84
  a test satisfy the same seam.
85
85
 
86
+ ## The search box reaches the catalogue, not only the titles
87
+
88
+ `GET /suggest` (stapel-search 0.7.0) answers CATEGORIES as well as title
89
+ prefixes, so typing a section's name offers the section. `<SearchBox>` draws
90
+ them as their own group above the terms — each row the ancestor path plus its
91
+ live listing count, which is the only way to tell three same-named leaves
92
+ apart — and selecting one narrows the SERP using the server's own `category`
93
+ string, verbatim.
94
+
95
+ An older server sends no `categories` key and the box behaves exactly as it
96
+ did. When the answer says `degraded: ["category_suggestions"]` the group is
97
+ absent rather than empty: an empty group under a heading would claim the
98
+ catalogue has no such section.
99
+
86
100
  ## Facets are drill-down, and the panel says so
87
101
 
88
102
  Each facet is counted over the candidates **with its own filter removed**
@@ -99,6 +113,34 @@ category's feature schema. Hand that schema in and the options read as words:
99
113
 
100
114
  Without it, options read as raw index terms. Never as blanks.
101
115
 
116
+ That schema also decides **which counted slugs are filters at all**: a plan
117
+ derived from a category counts what is indexed, so a real answer carries `imei`
118
+ and `video_file_url` beside `condition` and `vendor`. Only the bounded option
119
+ types (`FACETABLE_FEATURE_TYPES`) get a chip. A slug with no feature def is
120
+ kept — silence is not a verdict — and so is any slug the URL already filters on,
121
+ so a link can always be widened again.
122
+
123
+ A `ref_select` facet carries a POINTER to a vocabulary and no options, and a
124
+ server older than stapel-search 0.4.0 sends no `facet_labels` to cover for it.
125
+ `resolveFacetLabels` is the host seam that names those values — batched per
126
+ group, cached, aborted on supersession:
127
+
128
+ ```tsx
129
+ <SearchPage
130
+ categoryFeatures={features}
131
+ resolveFacetLabels={async ({ slug, feature, values }, { signal }) =>
132
+ await vocabulary.captions(feature, values, { signal })
133
+ }
134
+ renderCategoryFilter={(slot) => <CategoryPickerField {...slot} />}
135
+ categoryLabel={currentCategory?.name}
136
+ />
137
+ ```
138
+
139
+ Precedence is `facet_labels` → the schema's inline `options` → this resolver →
140
+ the raw value; a value nobody names keeps printing itself. `renderCategoryFilter`
141
+ also becomes the leading chip of the phone filter row, which is where the
142
+ catalogue's deeper levels are chosen on a result list.
143
+
102
144
  ## What the server admits, the screen repeats
103
145
 
104
146
  | The envelope says | The page says |
@@ -99,13 +99,24 @@ export interface paths {
99
99
  cookie?: never;
100
100
  };
101
101
  /**
102
- * Title prefixes from the index
103
- * @description ``GET /search/api/v1/suggest`` — title prefixes out of the index.
102
+ * Type-ahead: category paths with live counts, plus title prefixes
103
+ * @description ``GET /search/api/v1/suggest`` — what to offer under the search box.
104
104
  *
105
- * Not out of a query log: no query log is kept, which is a privacy
105
+ * ``categories`` is the primary half: each row is a destination with its
106
+ * full ancestor path and the number of listings a buyer would actually
107
+ * see there, ranked by that number. ``terms`` is the title-prefix half.
108
+ *
109
+ * Neither comes from a query log: no query log is kept, which is a privacy
106
110
  * decision before it is a product one, and on day one there would be
107
111
  * nothing in it anyway.
108
112
  *
113
+ * The answer is public, identical for every reader and requested on every
114
+ * keystroke, so it carries ``Cache-Control: public`` and an ``ETag``. This
115
+ * is the module's first conditional read — ``query`` has none, because a
116
+ * SERP answer embeds ``took_ms`` and a cursor and would revalidate to a
117
+ * miss every time. Here the payload is deliberately free of anything that
118
+ * varies with the clock.
119
+ *
109
120
  * **Permissions:** `AllowAny`
110
121
  */
111
122
  get: operations["search_api_v1_suggest_retrieve"];
@@ -121,6 +132,30 @@ export interface paths {
121
132
  export type webhooks = Record<string, never>;
122
133
  export interface components {
123
134
  schemas: {
135
+ /** @description One destination in the dropdown, ready to render and ready to follow. */
136
+ CategorySuggestion: {
137
+ /** @description Category id. */
138
+ id: number;
139
+ /** @description Category slug. */
140
+ slug: string;
141
+ /** @description The category's own display name. */
142
+ name: string;
143
+ /** @description Display names root->leaf, e.g. ['Мужская одежда', 'Шорты']. This is what distinguishes three categories that share a name. */
144
+ path: string[];
145
+ /** @description The ancestry as ids joined with '/'. Pass it verbatim as the `category` parameter of /query — do not re-join path segments yourself. */
146
+ category: string;
147
+ /** @description Live listings a buyer would see under this category, descendants included — the same number the SERP reports for it. */
148
+ count: number;
149
+ /** @description Number of segments in `path`. */
150
+ depth: number;
151
+ /**
152
+ * @description How the name matched. Informational; ranking is by `count`.
153
+ *
154
+ * * `prefix` - prefix
155
+ * * `substring` - substring
156
+ */
157
+ match: components["schemas"]["MatchEnum"];
158
+ };
124
159
  /** @description Captions for one slug's option codes. */
125
160
  FacetLabels: {
126
161
  /** @description True when `values` holds translation KEYS to run through the catalogue; false when it holds literal captions. The reader cannot tell by looking — `b.apple` and `Б/у` are both strings. */
@@ -152,6 +187,12 @@ export interface components {
152
187
  lag_seconds?: number | null;
153
188
  stale_reason?: string;
154
189
  };
190
+ /**
191
+ * @description * `prefix` - prefix
192
+ * * `substring` - substring
193
+ * @enum {string}
194
+ */
195
+ MatchEnum: "prefix" | "substring";
155
196
  /** @description The P2B Art. 5 disclosure, generated from the scorer registry. */
156
197
  RankingResponse: {
157
198
  doc_type: string;
@@ -239,7 +280,16 @@ export interface components {
239
280
  took_ms: number;
240
281
  };
241
282
  SuggestResponse: {
283
+ /** @description Destinations, ranked by live listing count desc, then depth, then name. */
284
+ categories: components["schemas"]["CategorySuggestion"][];
285
+ /** @description Title prefixes from the index. */
286
+ terms: string[];
287
+ /** @description Deprecated alias of `terms`, kept for one minor. */
242
288
  items: string[];
289
+ /** @description Which dictionary answered — the same resolution /query reports. */
290
+ language: string;
291
+ /** @description What this answer could not do: `category_suggestions` (no provider for category names), `category_rollup` (no ancestry, so counts would read 0). */
292
+ degraded: string[];
243
293
  backend: string;
244
294
  };
245
295
  };
@@ -369,11 +419,15 @@ export interface operations {
369
419
  };
370
420
  search_api_v1_suggest_retrieve: {
371
421
  parameters: {
372
- query: {
422
+ query?: {
423
+ /** @description Language of the query: picks the dictionary, so «shorty» reaches «шорты». Falls back to Accept-Language, then DEFAULT_LANGUAGE. */
424
+ lang?: string;
425
+ /** @description Rows per half. Capped by MAX_SUGGEST_LIMIT. */
373
426
  limit?: number;
374
- /** @description Title prefix. */
427
+ /** @description What the buyer has typed so far. */
375
428
  q?: string;
376
- type: string;
429
+ /** @description Registered doc_type. Optional when exactly one type is registered — a type-ahead should not have to name the only corpus there is. */
430
+ type?: string;
377
431
  };
378
432
  header?: never;
379
433
  path?: never;
@@ -1 +1 @@
1
- {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/api/generated/schema.ts"],"names":[],"mappings":"AAGA,MAAM,WAAW,KAAK;IAClB,uBAAuB,EAAE;QACrB,UAAU,EAAE;YACR,KAAK,CAAC,EAAE,KAAK,CAAC;YAC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AAC,CAAC;aAClE,CAAC;SACL,CAAC;QACF,SAAS,EAAE;YACP,GAAG,EAAE;gBACD,OAAO,EAAE;oBACL,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;iBAC3B,CAAC;gBACF,OAAO,EAAE;oBACL,kBAAkB,EAAE,UAAU,CAAC,SAAS,CAAC,CAAC,iBAAiB,CAAC,CAAC;iBAChE,CAAC;aACL,CAAC;SACL,CAAC;KACL,CAAC;IACF,8BAA8B,EAAE;QAC5B,UAAU,EAAE;YACR,KAAK,EAAE;gBACH,KAAK,CAAC,EAAE,MAAM,CAAC;gBACf,iCAAiC;gBACjC,CAAC,CAAC,EAAE,MAAM,CAAC;gBACX,IAAI,EAAE,MAAM,CAAC;aAChB,CAAC;YACF,MAAM,CAAC,EAAE,KAAK,CAAC;YACf,IAAI,CAAC,EAAE,KAAK,CAAC;YACb,MAAM,CAAC,EAAE,KAAK,CAAC;SAClB,CAAC;QACF,WAAW,CAAC,EAAE,KAAK,CAAC;QACpB,SAAS,EAAE;YACP,GAAG,EAAE;gBACD,OAAO,EAAE;oBACL,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;iBAC3B,CAAC;gBACF,OAAO,EAAE;oBACL,kBAAkB,EAAE,UAAU,CAAC,SAAS,CAAC,CAAC,iBAAiB,CAAC,CAAC;iBAChE,CAAC;aACL,CAAC;SACL,CAAC;KACL,CAAC;CACL"}
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/api/generated/schema.ts"],"names":[],"mappings":"AAGA,MAAM,WAAW,KAAK;IAClB,uBAAuB,EAAE;QACrB,UAAU,EAAE;YACR,KAAK,CAAC,EAAE,KAAK,CAAC;YACd,MAAM,CAAC,EAAE,KAAK,CAAC;YACf,IAAI,CAAC,EAAE,KAAK,CAAC;YACb,MAAM,CAAC,EAAE,KAAK,CAAC;SAClB,CAAC;QACF;;;;;WAKG;QACH,GAAG,EAAE,UAAU,CAAC,+BAA+B,CAAC,CAAC;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YACb,MAAM,CAAC,EAAE,KAAK,CAAC;SAClB,CAAC;QACF,WAAW,CAAC,EAAE,KAAK,CAAC;QACpB,SAAS,EAAE;YACP,GAAG,EAAE;gBACD,OAAO,EAAE;oBACL,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;iBAC3B,CAAC;gBACF,OAAO,EAAE;oBACL,kBAAkB,EAAE,UAAU,CAAC,SAAS,CAAC,CAAC,iBAAiB,CAAC,CAAC;iBAChE,CAAC;aACL,CAAC;SACL,CAAC;KACL,CAAC;CACL"}
@@ -1,5 +1,5 @@
1
1
  import type { StapelClient } from "@stapel/core";
2
- import type { RankingResponse, SearchQueryState, SearchResponse, SuggestParams, SuggestResponse } from "./types.js";
2
+ import type { RankingResponse, SearchQueryState, SearchResponse, SuggestAnswer, SuggestParams } from "./types.js";
3
3
  /**
4
4
  * The pair's typed operation surface — one method per stapel-search endpoint a
5
5
  * storefront may call, bound to the injected {@link StapelClient} (the
@@ -43,14 +43,21 @@ export interface SearchApi {
43
43
  readonly signal?: AbortSignal;
44
44
  }): Promise<SearchResponse>;
45
45
  /**
46
- * Title-prefix suggestions. Typed and callable, but this pair ships NO hook
47
- * and no autocomplete widget over it (spec §4.2 defers the debounce +
48
- * keyboard work). A host that wants one today calls this directly rather
49
- * than waiting for a version of the pair that has it.
46
+ * What to offer under the search box: CATEGORIES first, then title-prefix
47
+ * terms (stapel-search 0.7.0).
48
+ *
49
+ * Neither half comes from a query log the module keeps none, which is a
50
+ * privacy decision before it is a product one — so every suggestion is a
51
+ * destination or a search that has results.
52
+ *
53
+ * Typed as {@link SuggestAnswer} rather than as the generated
54
+ * `SuggestResponse`: a build regenerated against a pre-0.7.0 schema would
55
+ * otherwise hide the categories half from the compiler. See that type for
56
+ * why every member but `backend` is optional.
50
57
  */
51
58
  suggest(params: SuggestParams, options?: {
52
59
  readonly signal?: AbortSignal;
53
- }): Promise<SuggestResponse>;
60
+ }): Promise<SuggestAnswer>;
54
61
  /**
55
62
  * The P2B Art. 5 ranking disclosure for a doc type: which parameters rank
56
63
  * results, their weights, and — per parameter — whether the configured
@@ -1 +1 @@
1
- {"version":3,"file":"searchApi.d.ts","sourceRoot":"","sources":["../../src/api/searchApi.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,KAAK,EACV,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,aAAa,EACb,eAAe,EAChB,MAAM,YAAY,CAAC;AAEpB;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAC;IAE9B;;;;;;;;;;;;OAYG;IACH,KAAK,CACH,KAAK,EAAE,gBAAgB,EACvB,OAAO,CAAC,EAAE;QAAE,QAAQ,CAAC,MAAM,CAAC,EAAE,WAAW,CAAA;KAAE,GAC1C,OAAO,CAAC,cAAc,CAAC,CAAC;IAE3B;;;;;OAKG;IACH,OAAO,CACL,MAAM,EAAE,aAAa,EACrB,OAAO,CAAC,EAAE;QAAE,QAAQ,CAAC,MAAM,CAAC,EAAE,WAAW,CAAA;KAAE,GAC1C,OAAO,CAAC,eAAe,CAAC,CAAC;IAE5B;;;;;;OAMG;IACH,OAAO,CACL,IAAI,CAAC,EAAE,MAAM,EACb,OAAO,CAAC,EAAE;QAAE,QAAQ,CAAC,MAAM,CAAC,EAAE,WAAW,CAAA;KAAE,GAC1C,OAAO,CAAC,eAAe,CAAC,CAAC;CAC7B;AAED;;;;;;;;;GASG;AACH,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,gBAAgB,GACtB,MAAM,CACP,MAAM,EACN,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,SAAS,GAAG,SAAS,CAAC,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC,EAAE,CAC/E,CA+CA;AAED,wBAAgB,eAAe,CAAC,MAAM,EAAE,YAAY,GAAG,SAAS,CA0B/D"}
1
+ {"version":3,"file":"searchApi.d.ts","sourceRoot":"","sources":["../../src/api/searchApi.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,KAAK,EACV,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,aAAa,EACb,aAAa,EACd,MAAM,YAAY,CAAC;AAEpB;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,MAAM,EAAE,YAAY,CAAC;IAE9B;;;;;;;;;;;;OAYG;IACH,KAAK,CACH,KAAK,EAAE,gBAAgB,EACvB,OAAO,CAAC,EAAE;QAAE,QAAQ,CAAC,MAAM,CAAC,EAAE,WAAW,CAAA;KAAE,GAC1C,OAAO,CAAC,cAAc,CAAC,CAAC;IAE3B;;;;;;;;;;;;OAYG;IACH,OAAO,CACL,MAAM,EAAE,aAAa,EACrB,OAAO,CAAC,EAAE;QAAE,QAAQ,CAAC,MAAM,CAAC,EAAE,WAAW,CAAA;KAAE,GAC1C,OAAO,CAAC,aAAa,CAAC,CAAC;IAE1B;;;;;;OAMG;IACH,OAAO,CACL,IAAI,CAAC,EAAE,MAAM,EACb,OAAO,CAAC,EAAE;QAAE,QAAQ,CAAC,MAAM,CAAC,EAAE,WAAW,CAAA;KAAE,GAC1C,OAAO,CAAC,eAAe,CAAC,CAAC;CAC7B;AAED;;;;;;;;;GASG;AACH,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,gBAAgB,GACtB,MAAM,CACP,MAAM,EACN,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,SAAS,GAAG,SAAS,CAAC,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC,EAAE,CAC/E,CA+CA;AAED,wBAAgB,eAAe,CAAC,MAAM,EAAE,YAAY,GAAG,SAAS,CA0B/D"}
@@ -1 +1 @@
1
- {"version":3,"file":"searchApi.js","sourceRoot":"","sources":["../../src/api/searchApi.ts"],"names":[],"mappings":"AA8E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