Skip to content

fix(cli): search's text icons label + icon-ask wording - #12618

Closed
josephfarina wants to merge 4 commits into
mainfrom
josephfarina/search-icon-text-package
Closed

josephfarina wants to merge 4 commits into
mainfrom
josephfarina/search-icon-text-package

Conversation

@josephfarina

Copy link
Copy Markdown
Contributor

Record change: none. Scope: text label + icon-ask wording.
Checks: the search command text tests (including the two-package case), search.icons, icon-sets-guide, doc-text-ascii, authoring-self-docs-match-types and pnpm check:knowledge pass locally with CI=1; with no icon set installed, search output is byte-identical to main.

User impact

An agent with two installed packages that each ship an icon set of the same name runs astryx search trash icon. The text icons block prints both entries as trash (glyphs): …, so they read as the same icon, and the bare set name is not enough to open either one.

Problem and solution fit

The text line used the set's bare name, while the JSON name already qualifies a set that two packages ship (@acme/glyphs/glyphs/trash). The text line now names the set the same way, so each line says which set it is and matches the reference its command uses.

Expected behavior and authority

spec:AST-084 FR7: a set name two packages ship needs the qualified form <package>/<set>. Search's JSON entries already follow it.

Smallest restoration

iconBlock in the search command labels each icon with the set part of its JSON name. A set no other package ships prints exactly as before. No JSON field, option or record changes.

The icon-sets guide and the experimental.iconSet field description now say what an icon ask is, in plain words: a query that uses the word icon or icons, names an installed icon set, or writes an icon's export name, as in trash icon, heroicons trash or SearchIcon; search then lists up to three installed icons that the ask's words find. The behavior is unchanged.

Evidence

  • Reproduction before the change: trash (glyphs): import {TrashIcon} from '@acme/glyphs'; and trash (glyphs): import {TrashIcon} from '@other/glyphs';
  • Result after the change: trash (@acme/glyphs/glyphs): … and trash (@other/glyphs/glyphs): …
  • Representative unchanged path: one installed set still prints trash (glyphs): import {TrashIcon} from '@acme/glyphs';
  • Regression test or other mutation-sensitive proof: the new search command text test fails before the change and passes after it.

Scope

Components: cli search text view

  • One defect is restored.
  • Separable contradictory or unsettled tagalongs were removed or split.
  • No new public API, visual representation, default, or interaction model is hidden under the bug-fix label.
  • Public text and artifacts contain no internal Meta context.

Testing

  • CI=1 locally: search command text tests (including the new two-package case), search.icons, icon-sets-guide, doc-text-ascii, authoring-self-docs-match-types, pnpm check:knowledge; no-pack search output compared byte for byte with main.

@vercel

vercel Bot commented Nov 18, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
astryx Ready Ready Preview Nov 18, 2026 5:32pm UTC

Request Review

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Nov 18, 2026
@astracat-bot

astracat-bot Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

AI review status for this pull request.

Review status Updated
🟢 Reviewed (for maintainers only) Nov 18, 2026, 5:33 PM UTC

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: CI has not finished on this head yet.

The icons block now labels a set that two installed packages ship as <package>/<set>, matching the JSON name and the reference astryx experimental icon accepts, and the new test fails on the base and passes here. One optional wording point: the plain-words icon-ask definition in the icon-sets guide and the experimental.iconSet description leaves out the spec's exception for component and hook names (Icon, IconButton), as the base text did.

Claims and files checked

Review mode: full; reason: no-earlier-review

  • Claims:
    • Changeset: a set name that two installed packages ship prints with its package, as the JSON name does, and a set no other package ships prints as before. Verified by search.mjs:236 and the new test in search.test.mjs, both halves.
    • No knowledge record changes. Verified: no file under docs/ changes.
    • The listed tests and the knowledge check pass. Verified: the search command, search icons, icon-sets guide, doc-text ASCII and authoring self-docs tests pass (76 tests), and the knowledge check passes.
    • With no icon set installed, search output is unchanged. Verified: iconBlock returns nothing without icons (search.mjs:226), and the no-set search icons test passes.
    • Before the change both entries print trash (glyphs): …, and the bare name opens neither. Verified by a base run of the new test; astryx experimental icon glyphs/trash exits 1 in the two-package fixture.
    • The JSON name already qualifies a shared set, as the spec requires for a name two packages ship. Verified at packages/cli/api/search/_icons.mjs:58.
    • No JSON field, option or record changes. Verified: the JSON icons answer is the same on base and head, and no command doc or type changes.
    • The guide and the field description say what an icon ask is, and the behavior is unchanged. Verified, with the non-blocking wording note above; no detection code changes.
    • The new test fails before the change and passes after it. Verified by a red-first run.
    • One defect, no hidden API, visual, default or interaction change, and no internal context in public text. Verified over the diff, the commits and the description.
  • Files:
    • .changeset/search-icon-text-package.md: clear.
    • packages/cli/assets/docs/tree/icon-sets.doc.mjs: clear, with the non-blocking wording note.
    • packages/cli/authoring/config/config.doc.mjs: clear, with the same note; consistent with the guide.
    • packages/cli/clients/cli/commands/search.mjs: clear.
    • packages/cli/clients/cli/commands/search.test.mjs: clear.

Automated review (maintainer link)

@github-actions

github-actions Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

PR Analysis Report

🔎 Preview · 26435ed

Storybook · Sandbox · built from this PR's head

Package size: @astryxdesign/cli 5.47 MB packed (+542 B); no new dependencies.

Not run on this PR: add ci:run-visual for Visual, ci:run-a11y for Accessibility, ci:run-rtl for RTL.


Generated by PR Enrichment workflow | View full report

@josephfarina
josephfarina force-pushed the josephfarina/search-icon-text-package branch from 7ea06c2 to efab67e Compare November 18, 2026 12:10

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the label fix is right, but the new icon-ask definitions in two places leave out the with an icon reading that main now ships.

  • Regression: packages/cli/assets/docs/tree/icon-sets.doc.mjs:35 and packages/cli/authoring/config/config.doc.mjs:83 define an icon ask as any query that uses the word icon or icons, but search lists no icons for card with an icon or avatar with icon when its results hold a component (AST-084 FR11), as the guide's own table row at line 541 says, so add that exception to both definitions.

The two-package label change itself checks out: the new test fails on the base with two trash (glyphs) lines and passes on this head. While editing those two sentences, consider also naming the component and hook exception (Icon, IconButton) that the spec states.

Claims and files checked

Review mode: full; reason: rebase

  • Claim: no knowledge record changes. Verified: no record file is in the diff.
  • Claim: the listed tests and the knowledge check pass. Verified: the five test files (78 tests) and the knowledge check pass on this head.
  • Claim: with no icon set installed, search output is unchanged. Verified: the icons block is empty without an icons section (search.mjs:226).
  • Claim: before the change, two packages that ship glyphs print trash (glyphs) twice. Verified: the new test fails that way on the base.
  • Claim: the JSON name already qualifies a shared set. Verified: api/search/_icons.mjs:71.
  • Claim: the label uses the set part of name, and a set no other package ships prints as before. Verified: search.mjs:236 and the single-set case in search.test.mjs.
  • Claim: no JSON field, option or record changes. Verified.
  • Claim: the guide and the experimental.iconSet field now say what an icon ask is. False for with an icon queries at icon-sets.doc.mjs:35 and config.doc.mjs:83; correct in the guide's table row at line 541.
  • Claim: search lists up to three installed icons the ask's words find, with behavior unchanged. Verified: the section limit is 3 and the docs edits change no code.
  • Claim: the new test fails before the change and passes after it. Verified.
  • Changeset: names a shared set with its package as the JSON name does, and a set no other package ships prints as before. Verified by the new test.
  • File .changeset/search-icon-text-package.md: clear.
  • File packages/cli/assets/docs/tree/icon-sets.doc.mjs: finding at line 35; line 541 clear.
  • File packages/cli/authoring/config/config.doc.mjs: finding at line 83.
  • File packages/cli/clients/cli/commands/search.mjs: clear.
  • File packages/cli/clients/cli/commands/search.test.mjs: clear.

Automated review (maintainer link)

@josephfarina

Copy link
Copy Markdown
Contributor Author

/approve-spec 1be70e4

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the label fix is right and its new test proves it, but the new icon-ask definitions state the with exception more broadly than search applies it.

  • The definitions in packages/cli/assets/docs/tree/icon-sets.doc.mjs (line 35) and packages/cli/authoring/config/config.doc.mjs (line 83) say an icon right after with asks for no icon whenever the results hold a component or template, but search still lists icons when of or for follows (card with an icon of a star, as the guide's own table row at line 541 says), so add that condition to both strings.

Suggested wording for both strings: "and an icon or icons right after with (only a, an or the between) that no of or for follows, when the results hold a component or template (card with an icon; card with an icon of a star still asks)."

Claims and files checked

Review mode: incremental; reason: none

  • Claim (changeset): the icons block names a set two installed packages ship with its package, as the JSON name does, and a set no other package ships prints as before. Verified by search.mjs:236 and the new test.
  • Claim: no knowledge record changes. Verified, since the diff touches no record.
  • Claim: before the change, two packages that ship one set name printed two identical trash (glyphs) lines. Verified: the new test fails on the base with exactly those lines.
  • Claim: after the change the lines read trash (@acme/glyphs/glyphs) and trash (@other/glyphs/glyphs), and one installed set still prints trash (glyphs). Verified by the new test on the head.
  • Claim: the JSON name already qualifies a set name two packages ship, as the icon-sets spec requires. Verified at api/search/_icons.mjs:71.
  • Claim: no JSON field, option or record changes. Verified.
  • Claim: the guide and the config field now define an icon ask in plain words, and the behavior does not change. The behavior claim is verified, because only doc strings change. The definitions' with exception is false when of or for follows (finding above).
  • Claim: the new test fails before the change and passes after it. Verified.
  • Claim: with no icon set installed, search output is unchanged. Verified: search.mjs:226 is unchanged, and the no-icon-set search test passes.
  • Claim: the listed checks pass. Verified on the head for the new text test, the search icons tests, the icon-sets guide, doc ASCII, authoring docs against types, and the knowledge check.
  • Claim: no new public API, default or interaction model, and no internal context in public text. Verified.
  • File .changeset/search-icon-text-package.md: clear.
  • File packages/cli/clients/cli/commands/search.mjs: clear.
  • File packages/cli/clients/cli/commands/search.test.mjs: clear.
  • File packages/cli/assets/docs/tree/icon-sets.doc.mjs: finding at line 35; the table row at line 541 is clear and agrees with the code.
  • File packages/cli/authoring/config/config.doc.mjs: finding at line 83.

Automated review (maintainer link)

@josephfarina

Copy link
Copy Markdown
Contributor Author

/approve-spec 02b9fb5

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: CI has not finished on this head yet.

The text Icons block now names a set that two installed packages ship as <package>/<set>, matching the JSON name, and the new test fails before the change and passes after it. Both icon-ask definitions now state the with exception the way search applies it, including that card with an icon of a star still asks for icons. Nothing else is needed from you.

Claims and files checked

Review mode: incremental; reason: none

  • Claim (changeset): the icons block names a set two installed packages ship with its package, as the JSON name does, and a set no other package ships prints as before. Verified by search.mjs:236 and the new test.
  • Claim: no knowledge record changes. Verified: the diff touches no record.
  • Claim: before the change, two packages that ship one set name printed two identical trash (glyphs) lines. Verified: the new test fails on the base with exactly those lines.
  • Claim: after the change the lines read trash (@acme/glyphs/glyphs) and trash (@other/glyphs/glyphs), and one installed set still prints trash (glyphs). Verified by the new test on the head.
  • Claim: the JSON name already qualifies a set name two packages ship, as the icon-sets spec requires. Verified at api/search/_icons.mjs:71 and by the search icons tests.
  • Claim: no JSON field, option or record changes. Verified.
  • Claim: the guide and the config field now say what an icon ask is in plain words, and the behavior is unchanged. Verified: both definitions match the spec and the icon-ask code, and only doc strings change.
  • Claim: the new test fails before the change and passes after it. Verified.
  • Claim: with no icon set installed, search output is byte-identical to before. Verified: base and head print the same bytes for eight queries.
  • Claim: the listed checks pass. Verified on the head: the new text test, the search icons tests, the icon-sets guide, doc ASCII, authoring docs against types, and the knowledge check.
  • Claim: no new public API, default or interaction model, and no internal context in public text. Verified.
  • File .changeset/search-icon-text-package.md: clear.
  • File packages/cli/clients/cli/commands/search.mjs: clear.
  • File packages/cli/clients/cli/commands/search.test.mjs: clear.
  • File packages/cli/assets/docs/tree/icon-sets.doc.mjs: clear; the overview at line 35 and the table row at line 541 agree with each other and with the code.
  • File packages/cli/authoring/config/config.doc.mjs: clear.

Automated review (maintainer link)

A set two installed packages ship prints as <package>/<set>, as the entry's
JSON name does, so the two lines differ. Every other line is unchanged.
… ask is

An icon ask is a query that uses the word icon or icons, names an installed
icon set, or writes an icon's export name (trash icon, heroicons trash,
SearchIcon); search then lists up to three installed icons the ask's words
find.
…o icon

A word that is the exact name of a component or hook, and an icon or icons
right after with when the results hold a component or template, ask for no
icon, as AST-084 FR11 and the guide's search row say.
…of/for parts

An icon or icons right after with (only a, an or the between) that no of or
for follows asks for no icon when the results hold a component or template;
card with an icon of a star still asks.
@josephfarina
josephfarina force-pushed the josephfarina/search-icon-text-package branch from 02b9fb5 to 26435ed Compare November 18, 2026 17:15
@josephfarina

Copy link
Copy Markdown
Contributor Author

/approve-spec 26435ed

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: CI has not finished on this head yet.

The text Icons block now names a set that two installed packages ship as <package>/<set>, matching the JSON name, and the new test fails before the change and passes after it. The icon-ask definitions in the icon-sets guide and the experimental.iconSet reference match how search decides when to list icons. Nothing else is needed from you.

Claims and files checked

Review mode: full; reason: rebase

  • Claim (changeset): the icons block names a set two installed packages ship with its package, as the JSON name does, and a set no other package ships prints as before. Verified by search.mjs:236 and the new test.
  • Claim: no knowledge record changes. Verified: the diff touches no record.
  • Claim: before the change, two packages that ship one set name printed two identical trash (glyphs) lines, and the bare set name opens neither icon. Verified: the new test fails on the base with exactly those lines, and astryx experimental icon glyphs/trash asks for the package.
  • Claim: after the change the lines read trash (@acme/glyphs/glyphs) and trash (@other/glyphs/glyphs), and one installed set still prints trash (glyphs). Verified by the new test on the head.
  • Claim: the JSON name already qualifies a set name two packages ship, as the icon-sets spec requires. Verified at api/search/_icons.mjs:71; the JSON is the same before and after.
  • Claim: no JSON field, option or record changes. Verified.
  • Claim: the guide and the config field now say what an icon ask is in plain words, and the behavior is unchanged. Verified: the definitions match the icon-ask code and the spec, and only doc strings change.
  • Claim: the new test fails before the change and passes after it. Verified.
  • Claim: with no icon set installed, search output is byte-identical to before. Verified for eleven queries in text and JSON.
  • Claim: the listed checks pass. Verified on the head: the search command tests, the search icons tests, the icon-sets guide, doc ASCII, authoring docs against types, and the knowledge check.
  • Claim: no new public API, default or interaction model, and no internal context in public text. Verified.
  • File .changeset/search-icon-text-package.md: clear.
  • File packages/cli/assets/docs/tree/icon-sets.doc.mjs: clear; the overview and the search row agree with each other and with the code.
  • File packages/cli/authoring/config/config.doc.mjs: clear.
  • File packages/cli/clients/cli/commands/search.mjs: clear.
  • File packages/cli/clients/cli/commands/search.test.mjs: clear.

Automated review (maintainer link)

josephfarina added a commit that referenced this pull request Nov 19, 2026
- #12618 fix(cli): search's text icons label + icon-ask wording
  Author: @josephfarina
- #12688 docs(cli): experimental icon sets — explain the icon model in one place
  Author: @josephfarina
- #12123 fix(core): MultiSelector search trigger no longer carries aria-required
  Author: @josephfarina
@josephfarina

Copy link
Copy Markdown
Contributor Author

Landed in #12844.

@github-actions
github-actions Bot deleted the josephfarina/search-icon-text-package branch November 20, 2026 06:05

This branch was successfully deployed

1 active deployment
Preview — 26435edd Deployed Nov 18, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant