Repository navigation
feat(PowerSearch): an operator opts into value-only matches in the typeahead - #14163
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
AI review status for this pull request.
|
e0e5ac1 to
6743a90
Compare
bb5b99e to
7a8f794
Compare
|
/approve-spec 7a8f794 |
…peahead
An operator's new isValueOnlyMatchAllowed suggests its complete filters
for a typed value with no field label before it (component:PowerSearch
FR27-FR29, AR7, DEC-8). Typing "fiction" offers "Genre is Fiction"
after the field and field-and-operator rows.
- Free-text rows for string and string_list operators without a source,
enum and enum_list values by word start under the shared fold, and
the items of an operator's search source.
- At most three rows per field from two characters (or the field's
typeaheadMinQueryLength), then a "More {field} matching '{text}'"
row that opens the value editor on the text through the opening
query. None counts toward maxSearchResults.
- Each distinct source is asked once per query after the text rests
150 ms; its field's rows append in config order once it settles, and
a superseded query cancels the hold and any working source.
- A field's isValueMatchAllowed: false turns these rows off, and an
opt-in under it warns once in development.
- The value-only code loads on first intent (the field's focus or a
typed query) on a field whose config opts an operator in, so a page
that opts none in pays for its wiring alone; a query typed while it
loads lists its other rows at once.
- The sheet presentation's content search keeps its suggestions.
The FR27-FR29 status cells move from the implementation gap to their
evidence.
There was a problem hiding this comment.
Changes requested. The feature itself reads clean against the current PowerSearch requirements — the option, the row planning, the 150 ms source hold and the "More" row match FR27–FR29, AR7 and DEC-8 — but two things need your attention before it can be approved.
- The changeset, the
PowerSearch.doc.mjsexample and the new story all say the "More {field} matching '{text}'" row "opens its value editor on the typed text"; for anenumoperator the editor is aSelectorthat opens on its full list with the text dropped, as FR29 requires and as your own test "opens an enum field More row on the Selector, with no query" asserts, so please bound that sentence in.changeset/powersearch-value-only-matches.md:5,packages/core/src/PowerSearch/PowerSearch.doc.mjs:218andapps/storybook/stories/PowerSearch.stories.tsx:1677the way your pull-request description already does. architecture:component-import-boundariesINV10 asks a pull request that adds an optional feature to report the first-load gzip delta on a page that renders the component without it, andvalueOnlyMatches.tsis imported unconditionally byPowerSearch.tsxandusePowerSearchSource.ts, so please report the base-against-head number for a page that renders PowerSearch with no operator opted in; if it is over 0.3 KB, the feature takes INV7's own-import route or a deferred load (DEC-1).
Two non-blocking notes: PowerSearch now builds a second typeahead source for the sheet on every render while only one of the two is ever used, and two of the added comments run past INV29's one-topic, short-sentence rule.
Claims and files checked
Review mode: full; reason: no-earlier-review
Claims:
- A new optional operator flag suggests that operator's complete filters for a typed value alone — verified (
types.ts:299; unit test "lists a free-text row and enum rows by word start, whole label first, after the other rows"). - A
stringorstring_listoperator with no source offers the typed text, and astringoperator with a source offers only source rows — verified (valueOnlyMatches.ts:194-204; unit test "gives a string search-source operator only source rows, even with isArbitraryStringAllowed"). enumandenum_listvalues match by word start, ignoring case and accents, whole label first — verified (shared type-to-select fold; unit test "folds case, accents, stroked letters and Turkish İ when matching").- Each distinct source is asked once per query, once the text has rested 150 ms, and its rows append below the others — verified (unit test "shows the rows that need no source at once and asks each source once after 150 ms"; "appends source fields in config order whatever order they answer in").
- A field shows at most three rows, from two characters or its
typeaheadMinQueryLength— verified (unit tests "needs two characters, or the field typeaheadMinQueryLength" and "shows at most three rows per field…"). - The "More" row opens that field's value editor on the typed text — false for an
enumoperator (first finding above). - Value-only rows and "More" rows do not count toward
maxSearchResults— verified (unit test of the same name). - The option is off by default, so a config that opts no operator in keeps every list as it is — verified (
usePowerSearchSource.ts:241; unit test "lists nothing more for an operator that does not opt in"). - A field's
isValueMatchAllowed: falseturns the rows off, and an opt-in under it warns once in development — verified (component test "warns once in development…"; unit test "adds nothing, and asks no source…"). - The sheet presentation's content search does not list them — verified (the sheet keeps a source built without the option,
PowerSearch.tsx:644and:1759). - Only the one optional boolean is added to the public surface — verified (the package's
PowerSearchandPowerSearch/utilsentry points export neither the aux-data type nor the edit popover). - The record change touches the FR27–FR29 status cells only — verified (row-by-row comparison with the base; no requirement text differs).
- The new unit tests fail on the base without the source changes — reported; not run in this review and no CI job ran at this revision.
- The listed local commands (unit tests, typecheck, lint, the i18n catalog checks,
review:pre,specs:for --diff) passed — reported.
Files:
.changeset/powersearch-value-only-matches.md— first finding.packages/core/src/PowerSearch/PowerSearch.doc.mjs— first finding.apps/storybook/stories/PowerSearch.stories.tsx— first finding; the story config and its slow source are otherwise clear.packages/core/src/PowerSearch/valueOnlyMatches.ts— clear.packages/core/src/PowerSearch/usePowerSearchSource.ts— clear; one comment note.packages/core/src/PowerSearch/PowerSearch.tsx— clear; the duplicate source and one comment note.packages/core/src/PowerSearch/PowerSearchEditPopover.tsx— clear.packages/core/src/PowerSearch/types.ts— clear.packages/core/locales/en.json— clear.docs/specs/components/PowerSearch/PowerSearch.spec.md— clear.packages/core/src/PowerSearch/usePowerSearchSource.test.ts— clear.packages/core/src/PowerSearch/PowerSearch.test.tsx— clear.
7a8f794 to
a09a7de
Compare
|
/approve-spec a09a7de |
6743a90 to
d58d40a
Compare
a09a7de to
e6c5795
Compare
|
/approve-spec e6c5795 |
e6c5795 to
cc833fb
Compare
|
/approve-spec cc833fb |
PR Analysis Report🔎 Preview ·
|
| Component | Size | LoC | Visual · A11y · RTL |
|---|---|---|---|
| PowerSearch · Storybook | 326.7 kB (+142 B) · 27.8 kB CSS (0) | 7,906 (+602) | ✓ · ✓ · ✓ |
| Tokenizer · Storybook | 118.4 kB (+133 B) · 22.4 kB CSS (0) | 2,691 (+11) | ✓ · ✓ · ✓ |
| BaseTypeahead | 88.2 kB (+97 B) · 12.3 kB CSS (0) | — | ✓ · ✓ · ✓ |
2 more components
| Component | Size | LoC | Visual · A11y · RTL |
|---|---|---|---|
| Typeahead | 99.7 kB (+94 B) · 14.8 kB CSS (0) | — | ✓ · ✓ · ✓ |
| TypeaheadItem | 6.7 kB (0) · 3.6 kB CSS (0) | — | ✓ · ✓ · ✓ |
Package size: @astryxdesign/core 8.16 MB packed (+17.4 kB); no new dependencies.
API changes: core +3 · ~0 · −0
3 API changes (advisory)
| Package | Where | Signature | Usage | |
|---|---|---|---|---|
| + | core |
. · Types · interface PowerSearchOperatorBase |
isValueOnlyMatchAllowed?: boolean = false |
import type {PowerSearchOperatorBase} from '@astryxdesign/core'; const x: PowerSearchOperatorBase = {isValueOnlyMatchAllowed: …} |
| + | core |
. · Types · interface PowerSearchOperatorWithI18nKey |
isValueOnlyMatchAllowed?: boolean = false |
import type {PowerSearchOperatorWithI18nKey} from '@astryxdesign/core'; const x: PowerSearchOperatorWithI18nKey = {isValueOnlyMatchAllowed: …} |
| + | core |
. · Types · interface PowerSearchOperatorWithLabel |
isValueOnlyMatchAllowed?: boolean = false |
import type {PowerSearchOperatorWithLabel} from '@astryxdesign/core'; const x: PowerSearchOperatorWithLabel = {isValueOnlyMatchAllowed: …} |
Touched components checked; for the full suites, add ci:run-visual for Visual, ci:run-a11y for Accessibility, ci:run-rtl for RTL.
Generated by PR Enrichment workflow | View full report
There was a problem hiding this comment.
Changes requested.
- Miss:
sourceItemValueinpackages/core/src/PowerSearch/valueOnlyMatches.ts:252-271copies what each value editor stores for a picked item:PowerSearchValueEditor.tsx:182forstring,:269forstring_list, and:929-941forentity_list, including thephotoround-trip. A later change to what an editor stores would silently miss value-only rows, which must commit exactly that value. Please move the per-type conversion into one PowerSearch helper that the three editors andsourceItemValueall call.
The duplicated module loader from the last round is fixed: the value-only module now loads through createModuleLoader. Everything else checks out against the PowerSearch requirements. The 30 new value-only tests and the PowerSearch, Typeahead and Tokenizer suites pass when run locally, while CI's heavy jobs are deferred at this head. The first-load size measured locally is −64 B gzip on a PowerSearch page that does not use the option. This pull request sits on #14159 in its stack, so it lands only after that one is approved as well.
Claims and files checked
Review mode: full; reason: history
Claims checked against the code:
- A new optional operator flag, off by default, suggests complete filters for a typed value alone, after the field and field-and-operator rows: verified (
types.ts:290-299,valueOnlyMatches.ts:144-246; tests "lists a free-text row and enum rows by word start…" and "keeps the field and field-and-operator rows first"). - A
stringorstring_listoperator without a source offers the typed text, anenumorenum_listoperator offers values with a word that starts with the text, ignoring case and accents, whole-label matches first, and a source operator offers the source's items: verified (valueOnlyMatches.ts:103-132,185-214; the ranking, fold, mid-word and search-source tests). - A query counts as value-only when it neither equals a field label nor starts with one plus a space: verified (
valueOnlyMatches.ts:86-94; test "answers no label-led query, in any case"). - Each distinct source is asked once per query, after the text rests 150 ms, and its rows append below the others in config order; a rejecting source adds nothing; a superseded query cancels a working source; two operators sharing a source make one call: verified (
valueOnlyMatches.ts:416-502; the five search-source tests and "asks a source once for a word typed within 150 ms…"). - At most three rows per field from two characters, or the field's minimum, then a "More" row: verified (
valueOnlyMatches.ts:159-167,335-352; tests "needs two characters…" and "shows at most three rows per field…"). - The "More" row opens the field's editor: a text field holds the text as its value, an editor that searches opens on it, and an
enumSelector opens on its full list: verified (PowerSearch.tsx:1051-1068; the three "More" row tests, plus a local check of a text field's "More" row). - The opening query reaches only the editor of the field and operator the "More" row opened, and never a custom Editor override: verified (
PowerSearchEditPopover.tsx:739-746,PowerSearch.tsx:1410-1423). - Value-only rows do not count toward
maxSearchResults: verified (usePowerSearchSource.ts:237; test "does not count value-only rows toward maxSearchResults"). - The content field's default operator adds no row while the content-search row shows: verified (
valueOnlyMatches.ts:154-158,174-179; test "keeps the content-search row first…"). - Highlight, row ids, busy state and one count announcement are kept: verified (test "lists the rows that need no source at once, then the source field…").
- Choosing a value row commits its filter like a field-prefixed row: verified (
PowerSearch.tsx:1040-1047; test "commits a chosen value row as one filter…"). - A field that turns value matches off gets no value-only rows and asks no source, and an opt-in under it warns once in development, naming the field and operator: verified (
valueOnlyMatches.ts:161-167,PowerSearch.tsx:639-652; both tests). - Row text comes from three catalog messages a locale can reorder: verified (
en.json; test "reads each row as one catalog message a locale can reorder"). - The value-only code loads through the shared module loader on focus or a typed query. A query typed meanwhile lists its other rows at once. A config with no opt-in never loads it: verified (
valueOnlyMatchLoader.ts:16-44,usePowerSearchSource.ts:237-279; the four "before the module loads" tests). - A config with no opt-in lists and announces exactly as before: verified (
usePowerSearchSource.ts:237-240returns the unchanged rows). - The sheet presentation's content search does not list value-only rows: verified (
PowerSearch.tsx:673-687gives the sheet's source no value-only options, and only PowerSearch's own two modules import the value-only code). - The only public change is the optional flag on the operator base type: verified (API surface generator run locally: the flag on the base type and the two operator types that extend it, nothing else).
- The record changes only the three status cells: verified (cell-by-cell compare with the main branch).
- The release note is a feature patch: verified against the PowerSearch record's release class for this option.
- First-load size table, −102 B gzip on the PowerSearch page: reported; measured locally at −64 B gzip, under the 0.3 KB limit.
- The new tests fail on the base without the source changes: reported.
- Typecheck, lint, formatting, i18n, knowledge and changeset checks: reported; CI's lint and typecheck pass at this head.
Files visited in this pull request's own increment (13):
packages/core/src/PowerSearch/valueOnlyMatches.ts: the finding above.packages/core/src/PowerSearch/valueOnlyMatchLoader.ts: clear; the earlier loader finding is fixed.packages/core/src/PowerSearch/usePowerSearchSource.ts: clear.packages/core/src/PowerSearch/PowerSearch.tsx: clear.packages/core/src/PowerSearch/PowerSearchEditPopover.tsx: clear.packages/core/src/PowerSearch/types.ts: clear.packages/core/src/PowerSearch/PowerSearch.test.tsx: clear.packages/core/src/PowerSearch/usePowerSearchSource.test.ts: clear.packages/core/src/PowerSearch/PowerSearch.doc.mjs: clear.apps/storybook/stories/PowerSearch.stories.tsx: clear.packages/core/locales/en.json: clear..changeset/powersearch-value-only-matches.md: clear.docs/specs/components/PowerSearch/PowerSearch.spec.md: clear; three status cells, no requirement text changed.
111a645 to
113fc7d
Compare
|
/approve-spec 113fc7d |
There was a problem hiding this comment.
Approved pending CI: the heavy checks (test-node, test-ui, test-build, typecheck, docsite-build, build-storybook) are still running on this head, with no failure so far, so this is not ready to merge yet. No blocking findings remain — the copied item-to-value conversion from the last review is fixed, now that the string, string_list and entity_list editors and the value-only rows all commit through searchItemValues.ts. As part of a stack, this pull request lands only once #14159 below it is approved too.
- Non-blocking:
DEFAULT_MAX_OPERATOR_MENU_ITEMS = 10(PowerSearch.tsx:138) andVALUE_ONLY_SOURCE_DELAY_MS = 150(valueOnlyMatches.ts:54) restate the value editors' ownmaxMenuItemsanddebounceMs, which FR28 ties together; one shared constant per pair would keep them in step if an editor's bound or delay changes. - Non-blocking: the first-load table in the description reports −102 B gzip for the PowerSearch page; measured here on this head with
pnpm size:pagesit is −34 B (+2,619 B minified), the same pass against the 0.3 KB limit, so the numbers in the table are worth refreshing.
Claims and files checked
Review mode: full; reason: history
Claims (title, description, changesets):
- Title: an operator opts into value-only matches in the typeahead — verified; the sheet presentation gets the source without the option (
PowerSearch.tsx:675-684). - The option is off by default, per operator — verified; the planner acts only on
=== true(valueOnlyMatches.ts:176), andtypes.ts:299makes it optional. - A value-only query is one that neither equals a visible field label nor starts with one plus a space — verified by
isValueOnlyQuery(valueOnlyMatches.ts:91-99) and the "answers no label-led query, in any case" test. isValueMatchAllowed: falseand the two-character ortypeaheadMinQueryLengthminimum gate each field — verified byvalueOnlyMatches.ts:167-174and two tests.stringandstring_listwithout a source add a free-text row, andstring_listwithisArbitraryStringAllowedas well — verified (valueOnlyMatches.ts:190-200) and asserted in the search-source case.enumandenum_listvalues match by word start under the shared fold, whole label first — verified bymatchEnumValues(:108-139) overfoldForTypeahead, with the accents, stroked-letter and Turkish dotted-i test.- While the content-search row shows, the content field's default operator adds none — verified by
:179-184and its test. - Source operators add source rows — verified by the five "search sources" cases.
- Rows append after the capped typed rows and never count toward
maxSearchResults— verified; the cap is applied first (usePowerSearchSource.ts:237), and the three-field test with a cap of two lists every value-only row. - At most three rows per field, then a "More {field} matching '{text}'" row — verified (
valueOnlyMatches.ts:338-353) and asserted with its operator and text. - Each distinct source is asked once, 150 ms after the text rests; shared sources are one call — verified with fake timers (one call at 150 ms, none at 149 ms).
- A search-source field's rows append once its sources and every earlier one settle, in config order — verified by the out-of-order answer test.
- A rejecting source adds nothing and removes nothing shown — verified.
- Cancel drops the hold and cancels a working source — verified; only sources still working are cancelled (
valueOnlyMatches.ts:488-499). - The highlight, its id, the busy state and one count announcement survive appended rows — verified by the first
PowerSearch.test.tsxcase, which keeps the active option's id and announces "6 results" once. - Choosing a value row commits one filter, clears the text and closes the list — verified.
- A "More" row opens the first hidden row's operator: a text field holds the text as its value, a searching editor as its query, an
enumSelector on its full list — verified by three tests plus a probe run here for the text field. - An opt-in under
isValueMatchAllowed: falseadds nothing, asks no source and warns once in development, naming the field and the operator — verified. - Three new catalog messages let a locale reorder the parts — verified by the reordering-override test and the catalog checks.
- The value-only code loads through Core's shared module loader on first intent, and a page that opts no operator in never loads it — verified by
valueOnlyMatchLoader.ts:28-44and the four "before the module loads" cases. - The sheet presentation's content search is unchanged and FR30 follows later — verified; the record's FR30 gap note is untouched.
- Only one public member is added, with no other prop, type, default or export change — verified by the API generator run here: three rows, all the same new member on the operator base and its two variants.
- The changeset's sentence that an editor which searches opens on the typed text, with an
enumfield's editor on its full list — verified; it matches the tests. - Record touched: FR27–FR29 status cells only — verified by a cell-by-cell comparison with the current record; the requirement and authority cells are identical.
- First-load size table — reported; measured here as −34 B gzip rather than −102 B, with the same pass.
- The new tests fail on the base without the source changes — reported; not re-run on the base here.
- The listed test, lint, typecheck and knowledge commands — reported; the PowerSearch, Typeahead, Tokenizer and i18n suites (1,354 tests), the changeset check and both i18n checks were run here and pass.
Files (this pull request's own increment, 16 of 16 read):
packages/core/src/PowerSearch/valueOnlyMatches.ts— clear.packages/core/src/PowerSearch/valueOnlyMatchLoader.ts— clear.packages/core/src/PowerSearch/searchItemValues.ts— clear; it is what fixes the earlier finding.packages/core/src/PowerSearch/usePowerSearchSource.ts— clear.packages/core/src/PowerSearch/PowerSearch.tsx— non-blocking note on the restated menu-item default.packages/core/src/PowerSearch/PowerSearchEditPopover.tsx— clear.packages/core/src/PowerSearch/PowerSearchValueEditor.tsx— clear.packages/core/src/PowerSearch/types.ts— clear.packages/core/src/PowerSearch/PowerSearch.test.tsx— clear.packages/core/src/PowerSearch/usePowerSearchSource.test.ts— clear.packages/core/src/PowerSearch/PowerSearch.doc.mjs— clear; the earlier wording findings are fixed.apps/storybook/stories/PowerSearch.stories.tsx— clear; the story's values do produce the rows its comment names.packages/core/locales/en.json— clear..changeset/powersearch-value-only-matches.md— clear.docs/specs/components/PowerSearch/PowerSearch.spec.md— clear; status cells only, approved on this head.internal/eslint-plugin-astryx/no-comment-provenance.baseline.json— clear; the removed entry follows the editor comment that moved.
113fc7d to
2a1d5e1
Compare
|
/approve-spec 2a1d5e1 |
There was a problem hiding this comment.
This pull request is reviewed as part of its stack; see the review on #14170.
2a1d5e1 to
62a1687
Compare
|
/approve-spec 62a1687 |
There was a problem hiding this comment.
This pull request is reviewed as part of its stack; see the review on #14170.
62a1687 to
e9badf2
Compare
|
/approve-spec e9badf2 |
There was a problem hiding this comment.
This pull request is reviewed as part of its stack; see the review on #14170.
e9badf2 to
3544bb1
Compare
|
/approve-spec 3544bb1 |
There was a problem hiding this comment.
This pull request is reviewed as part of its stack; see the review on #14170.
|
/approve-spec 3544bb1 |
3544bb1 to
5b6d962
Compare
|
/approve-spec 5b6d962 |
There was a problem hiding this comment.
This pull request is reviewed as part of its stack; see the review on #14170.
Stack: #14163 -> #14185 -> #14170
This pull request is the bottom of the stack, on main. It builds on the package-internal opening query that #14159 merged.
User need
A person who knows a value but not which field holds it ("fiction", "jane") gets nothing from PowerSearch today unless they type the field label first. An operator that opts in now answers the value alone with complete filters (
Genre is Fiction,Owner is any of Jane Doe) after the field and field-and-operator rows, so the filter is one pick away. The option is off by default, per operator, because a value-only row is a product choice (it can send typed text to a search source).Problem and solution fit
PowerSearchOperatorBase.isValueOnlyMatchAllowed(stable, optional, default off;component:PowerSearchDEC-8, "Public concepts").valueOnlyMatches.tsplans which fields and opted-in operators answer a value-only query (FR27): a query that neither equals a visible field label nor starts with one plus a space; the field'sisValueMatchAllowed: falseand the length minimum (two characters, ortypeaheadMinQueryLength) gate each field;string/string_listwithout a source add a free-text row (andstring_listwithisArbitraryStringAllowed);enum/enum_listmatch values by word start under the shared type-to-select fold (architecture:internationalizationINV17), whole label first, then label start, then the rest; source operators add source rows; while the content-search row shows, the content field's default operator adds none.usePowerSearchSourceappends those rows after the capped typed rows (they never count towardmaxSearchResults), field by field, no-source fields first, at most three per field, with a "More {field} matching '{text}'" row after a field's rows when it has more (FR29). With a search-source field, the rows that need no source list at once throughcontext.update; after the text rests 150 ms each distinct source is asked once; a search-source field's rows append, all together, once its sources and every earlier search-source field's have settled; a rejecting source adds nothing;canceldrops the hold and cancels a working source (FR28). BaseTypeahead keeps the highlight, ids, busy state and the one count announcement (spec:AST-092FR2, FR4–FR8, AR7).enumSelector opens on its full list.isValueMatchAllowed: falseadds nothing, asks no source, and warns once in development, naming the field and the operator.@astryx.powersearch.valueOnlyMatch.{text,value,more}), so a locale can reorder the parts (INV1a).valueOnlyMatches.ts) loads through Core's shared module loader (createModuleLoader) on first intent (architecture:component-import-boundariesDEC-1): the field's focus, or a typed query, on a field whose config opts an operator in. A query typed while it loads lists its other rows at once and its value-only matches once it lands. A page whose config opts no operator in never loads it.Current specification
component:PowerSearchFR27–FR29, AR7, AV7, DEC-8 (current);component:BaseTypeaheadFR1, FR3, FR5, FR18;spec:AST-092FR2, FR4–FR8. This PR moves the FR27–FR29 status cells from "Implementation gap" to the evidence they now have.Public delta and caller burden
isValueOnlyMatchAllowed?: booleanonPowerSearchOperatorBase(so on everyPowerSearchOperator). No other prop, type, default or export changes.Changeset:
[feat]patch (spec:AST-017FR5; DEC-8).Design and alternatives
DEC-8 records the decision and its rejected alternatives (a config-level switch, a second operator prop, grouped headings, a silent cap). Implementation choices:
architecture:component-import-boundariesINV7's own-import route does not fit; INV10's other route, a load on first intent, keeps an unused option within the 0.3 KB allowance (numbers below).spec:AST-092leaves a delayed remote request to its source; the main field's debounce stays zero, so field rows and no-source rows show at once.searchItemValues.ts, the helpers thestring,string_listandentity_listvalue editors now call for a picked item (thephotoround-trip included), so a row commits what its editor would store.components.Editor.Evidence
Focused unit tests, failing on the base without the source changes:
usePowerSearchSource.test.ts"value-only matches": before the module loads, a config with no opt-in loads nothing, focus (the bootstrap) starts the load, a query typed meanwhile lists its other rows at once and its value-only matches once the module lands, and a query superseded while it loads is dropped; no opt-in; free-text and enum rows with whole-label and label-start ranking; no mid-word match; case, accents, stroked letters and Turkish İ; no label-led query in any case; the two-character default andtypeaheadMinQueryLengthabove and below two;isValueMatchAllowed: false(no row, no source call); three rows then a More row with its operator and text;maxSearchResults2 with three contributing fields; content-search row first and the content field's free-text row gone; with deferred sources: no-source rows at once, one call per shared source after 150 ms, entity, string and string_list values; config order kept when two source fields answer out of order; a rejecting source; a superseded query (no call before the hold, a working source cancelled);maxOperatorMenuItems; astringsource operator withisArbitraryStringAllowed(source rows only).PowerSearch.test.tsx"value-only matches": the rendered flat listbox (no group), the first row highlighted througharia-activedescendant, appended rows keeping its id, one count announced after the source settles counting the More row; a chosen value row committing one filter, clearing the text and closing the list; Enter on the content search while a source is pending, and a composing Enter choosing nothing; Escape keeping the text with a pending answer not reopening the list; a More row reached by the arrow keys opening the entity Tokenizer on the text; anenumMore row opening the Selector with no query; anenum_listMore row opening its Tokenizer searching the text; a reordering locale message; the development warning once, with no source call; one source call for a word typed within 150 ms while the other rows show at once.PowerSearch.stories.tsx(a slow people source shows rows appending).First-load size (
architecture:component-import-boundariesINV10)pnpm size:pages --base <#14159 head, now on main> --head <this head> --page powersearch=PowerSearch --unused-on powersearch(esbuild, minified / gzip bytes): the option is unused on every page.PASS: the powersearch page grows −49 B gzip without the feature (INV10 limit: 307 B).The split point adds first-load chunks, which is where the minified bytes go; with the value-only module bundled eagerly the same page grew +1,893 B gzip.Whole stack, measured from
mainto the top of the stack on a PowerSearch page that does not useisValueOnlyMatchAllowed:| powersearch (PowerSearch) | 994,250 / 328,970 | 997,053 / 329,093 | +2,803 / +123 |, which isPASS ... +123 B gzip without the feature (INV10 limit: 307 B). The engineering owner ruled that the opening-query wiring counts toward this allowance.Scope
Components: PowerSearch
PowerSearch.doc.mjsexample, the type's JSDoc, a story; no migration: the option is new and off.)Writing rubric results
Record touched:
component:PowerSearchFR27–FR29 (status cells only).Testing
vitest run --project ui packages/core/src/PowerSearch/ packages/core/src/i18n/ packages/core/src/Typeahead/ packages/core/src/Tokenizer/tsc --noEmitfor core, eslint and Prettier on the changed files,node scripts/check-i18n-catalog.mjs,node scripts/generate-i18n-runtime.mjs --check,pnpm check:knowledge,node scripts/check-changesets.mjs,pnpm review:pre(no findings),pnpm specs:for --diff(no concern-routed claim).