Editor's Path Properties has 'Stitch type' but the dropdown uses internal IDs ('satin', 'fill') instead of human-readable labels ('Satin Stitch (Tatami)', 'Fill Stitch (Tatami)') — user has to map IDs to display names in their head #348

Closed
opened 2026-10-04 03:55:35 +00:00 by Mark · 1 comment
Owner

Finding

grep -rn 'STITCH_LABELS\|userFacingStitch' src/components/workspace/pathDefaults.ts returns 5:

export const STITCH_LABELS: Record<UserFacingStitchType, string> = {
  satin: 'Satin',
  fill: 'Fill',
  running: 'Running',
  'cross-stitch': 'Cross Stitch',
  zigzag: 'Zigzag',
};

The labels are short ("Satin", "Fill"). The Help page uses more descriptive names ("Satin Stitch (Tatami)", "Fill Stitch (Tatami)", "Running Stitch", "Cross-Stitch", "Zigzag Stitch").

A user in the editor:

  • Sees "Satin", "Fill", "Running" in the dropdown
  • Reads the Help page: "Satin Stitch (Tatami)", "Fill Stitch (Tatami)", "Running Stitch"
  • Confused: are these the same thing?

The fix is to use the same labels in both places.

Where

  • pathDefaults.ts: STITCH_LABELS (5 short labels)
  • Help.tsx: stitchTypes array (5 long labels)
  • Mismatch: per the snippet earlier, the names are different

Suggested fix shape

  1. Single source of truth: define the labels in pathDefaults.ts:
export const STITCH_LABELS: Record<UserFacingStitchType, string> = {
  satin: 'Satin Stitch (Tatami)',
  fill: 'Fill Stitch (Tatami)',
  running: 'Running Stitch',
  'cross-stitch': 'Cross-Stitch',
  zigzag: 'Zigzag Stitch',
};
  1. Update Help page: import STITCH_LABELS from pathDefaults.ts and use the same names.

  2. UI: the editor's dropdown shows the long labels.

  3. Compact mode (per #267): the editor's compact path list shows the short label ("Satin") for space reasons; the right panel shows the long label.

Severity

Low. The user can map. New users notice the mismatch.

Discovered by

Gap analysis (2026-10-02) of editor/help consistency.

  • #297 (open) — Stitch type preview. Same surface; the preview is one aspect.
  • The pathDefaults.ts labels (per #198) are the source.
  • The Help page is the documentation; the editor is the implementation. They should match.
## Finding `grep -rn 'STITCH_LABELS\|userFacingStitch' src/components/workspace/pathDefaults.ts` returns 5: ```ts export const STITCH_LABELS: Record<UserFacingStitchType, string> = { satin: 'Satin', fill: 'Fill', running: 'Running', 'cross-stitch': 'Cross Stitch', zigzag: 'Zigzag', }; ``` The labels are short ("Satin", "Fill"). The Help page uses more descriptive names ("Satin Stitch (Tatami)", "Fill Stitch (Tatami)", "Running Stitch", "Cross-Stitch", "Zigzag Stitch"). A user in the editor: - Sees "Satin", "Fill", "Running" in the dropdown - Reads the Help page: "Satin Stitch (Tatami)", "Fill Stitch (Tatami)", "Running Stitch" - Confused: are these the same thing? The fix is to use the same labels in both places. ## Where - pathDefaults.ts: `STITCH_LABELS` (5 short labels) - Help.tsx: `stitchTypes` array (5 long labels) - Mismatch: per the snippet earlier, the names are different ## Suggested fix shape 1. **Single source of truth**: define the labels in `pathDefaults.ts`: ```ts export const STITCH_LABELS: Record<UserFacingStitchType, string> = { satin: 'Satin Stitch (Tatami)', fill: 'Fill Stitch (Tatami)', running: 'Running Stitch', 'cross-stitch': 'Cross-Stitch', zigzag: 'Zigzag Stitch', }; ``` 2. **Update Help page**: import `STITCH_LABELS` from `pathDefaults.ts` and use the same names. 3. **UI**: the editor's dropdown shows the long labels. 4. **Compact mode** (per #267): the editor's compact path list shows the short label ("Satin") for space reasons; the right panel shows the long label. ## Severity Low. The user can map. New users notice the mismatch. ## Discovered by Gap analysis (2026-10-02) of editor/help consistency. ## Related - #297 (open) — Stitch type preview. Same surface; the preview is one aspect. - The pathDefaults.ts labels (per #198) are the source. - The Help page is the documentation; the editor is the implementation. They should match.
Author
Owner

Closed by commit 5185648 on main: feat(#348) single source of truth for stitch labels.

STITCH_LABELS lives in pathDefaults.ts; PathDefaultsSection, Help.tsx, and EditorRightPanel now render from it. The 4 coming-soon types (Motif/Bean/Applique/Stem) keep their inline names — they are not in USER_FACING_STITCH_TYPES yet (#158).

Help page (Help.test.tsx) and PathDefaultsSection subtitle (issue-275.test.tsx) assertions updated for the long labels.

Closed by commit 5185648 on main: feat(#348) single source of truth for stitch labels. STITCH_LABELS lives in pathDefaults.ts; PathDefaultsSection, Help.tsx, and EditorRightPanel now render from it. The 4 coming-soon types (Motif/Bean/Applique/Stem) keep their inline names — they are not in USER_FACING_STITCH_TYPES yet (#158). Help page (Help.test.tsx) and PathDefaultsSection subtitle (issue-275.test.tsx) assertions updated for the long labels.
Mark closed this issue 2026-10-05 08:56:27 +00:00
Sign in to join this conversation.
No description provided.