Skip to content
This repository was archived by the owner on Jan 30, 2026. It is now read-only.

feat: enhance FieldList component#4

Merged
caio-pizzol merged 1 commit intomainfrom
caio/sd-532-display-field-id-instead-of-alias-in-fields-list
Oct 9, 2025
Merged

feat: enhance FieldList component#4
caio-pizzol merged 1 commit intomainfrom
caio/sd-532-display-field-id-instead-of-alias-in-fields-list

Conversation

@caio-pizzol
Copy link
Contributor

@caio-pizzol caio-pizzol commented Oct 9, 2025

Note

Replaces the delete button with a top-right trash icon, shows field.id as primary with optional alias subtitle, removes tag display, and adds an alias tooltip.

  • UI — src/defaults/FieldList.tsx:
    • Item layout: Make item container position: relative; add title={field.alias} tooltip.
    • Delete control: Replace text button with absolute-positioned trash icon (top-right), hover color change, and click propagation stopped.
    • Field display: Show field.id as primary; render alias as smaller subtitle only when different; remove field.tag rendering.
    • Styling tweaks: Adjust spacing and flex alignment to accommodate new icon.

Written by Cursor Bugbot for commit 16a981c. This will update automatically on new commits. Configure here.

@linear
Copy link

linear bot commented Oct 9, 2025

SD-532 Display Field ID Instead of Alias in Fields List

Summary

Display the field ID instead of the alias in the FieldsList component for clearer identification.

Tasks

  • Modify src/defaults/FieldList.tsx to display field.id as the primary text instead of field.alias
  • Keep field.tag as the subtitle for additional context
  • Ensure the field ID is clearly visible and readable in the list UI
  • Update any related tests in src/__tests__/SuperDocTemplateBuilder.test.tsx that assert on displayed field names
  • Consider adding the alias as additional information if needed (e.g., as a tooltip or secondary text)

Notes

Currently the FieldList component at src/defaults/FieldList.tsx displays the human-readable alias (e.g., "Customer Name") as the main text. However, for template building purposes, showing the actual field id (e.g., "customer_name" or "field_1234567890") is more useful for users who need to reference these IDs in their systems. The TemplateField type has both id and alias properties - we should display the ID prominently while potentially keeping the alias available for context.

@caio-pizzol caio-pizzol merged commit 26ffd6f into main Oct 9, 2025
2 checks passed
@caio-pizzol caio-pizzol deleted the caio/sd-532-display-field-id-instead-of-alias-in-fields-list branch October 9, 2025 18:31
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant