Skip to content

Ibx 11236 use ds btn component#1838

Open
tischsoic wants to merge 218 commits intomainfrom
IBX-11236-use-ds-btn-component
Open

Ibx 11236 use ds btn component#1838
tischsoic wants to merge 218 commits intomainfrom
IBX-11236-use-ds-btn-component

Conversation

@tischsoic
Copy link
Copy Markdown
Contributor

🎫 Issue IBX-XXXXX

Description:

For QA:

Documentation:

@tischsoic tischsoic self-assigned this Feb 26, 2026
@tischsoic tischsoic force-pushed the IBX-11236-use-ds-btn-component branch from 30c24df to 5c13474 Compare March 2, 2026 07:58
@tischsoic tischsoic force-pushed the IBX-11236-use-ds-btn-component branch 2 times, most recently from 69e583a to 2ccfc8f Compare March 8, 2026 22:07
@tischsoic tischsoic force-pushed the IBX-11236-use-ds-btn-component branch 3 times, most recently from 0b21d42 to 7f4c061 Compare March 23, 2026 12:01
tischsoic and others added 14 commits March 24, 2026 10:39
Migrate filter buttons and edit translation buttons to use the
design system twig:ibexa:button component for consistent styling.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Automated migration tool for migrating legacy UI components to design system.

Features:
- Chunk-based processing with OpenCode CLI integration
- Automatic branch creation for isolated migrations
- Retry logic with automatic rollback on failure
- Frontend validation (yarn test) integration
- Progress tracking, logging, and error reporting
- Component-agnostic architecture (supports buttons, badges, etc.)

Components:
- migrate-buttons.sh: Bash orchestrator (789 LOC)
- MIGRATION_RULES.md: Button migration guide with variant mappings
- BUTTON_MIGRATION_PLAN.txt: Chunk definitions and file inventory
- .claude/: Skills and settings for AI-assisted migrations
- .button-migration/: Working directory for logs and state

Usage:
  ./migrate-buttons.sh --chunk CHUNK_03
  ./migrate-buttons.sh --start-from 5
  ./migrate-buttons.sh --dry-run

See: MIGRATION_RULES.md, BUTTON_MIGRATION_PLAN.txt
- Move BUTTON_MIGRATION_PLAN.txt → migrations/button/
- Move MIGRATION_RULES.md → migrations/button/
- Move prompts/ → migrations/button/prompts/
- Add .migration-state/ for runtime tracking (gitignored)
- Prepare structure for multi-component migrations (badges, etc.)
Rewrite of bash script with enhanced features:

Features:
- Component-agnostic architecture (buttons, badges, alerts, etc.)
- Automatic branch isolation (migrate/buttons, migrate/badges)
- Type-safe with comprehensive TypeScript types
- Modular library structure (git, opencode, validation, etc.)
- Skip-on-failure with progress tracking
- Real-time output streaming
- Colored logging with progress indicators

Structure:
- scripts/migrate-component.ts - Main orchestrator
- scripts/lib/ - Modular utilities (9 modules)
- scripts/config/ - Component configurations
- scripts/types.ts - TypeScript definitions

Usage:
  cd scripts/
  npm run migrate:button -- --chunk CHUNK_03
  npm run migrate:badge -- --chunk CHUNK_01

Branch Strategy:
- Migrations run on isolated branches (migrate/*)
- Never merged back to base branch
- Clean separation of tool commits vs migration commits

Removed:
- migrate-buttons.sh (789 LOC bash script)
- .button-migration/ working directory

See: scripts/README.md
…stem-twig

- Replace 1 button-styled link with <twig:ibexa:link variant="button">
- Map to primary button type
- Preserve ibexa-btn--login class
- Preserve translation strings and href path

Refs: BUTTON_MIGRATION_PLAN.md
- Replace 1 button-styled link with <twig:ibexa:link variant="button">
- Map ghost style to tertiary type with small size
- Add edit icon (icon="edit", icon_size="small-medium")
- Preserve conditional rendering logic

Refs: BUTTON_MIGRATION_PLAN.md
…esign-system-twig

- Replace 2 button-styled links with <twig:ibexa:link variant="button">
- Back button: tertiary with back icon
- Sign in button: primary type
- Preserve custom classes and translations

Refs: BUTTON_MIGRATION_PLAN.md
…twig

- Replace 1 show more/less toggle button with <twig:ibexa:button>
- Map ghost style to tertiary type with small size
- Add arrow-caret-down icon
- Preserve custom classes and complex nested label structure

Refs: BUTTON_MIGRATION_PLAN.md
…m-twig

- Replace 1 upload file button with <twig:ibexa:button>
- Map to secondary button type
- Preserve conditional disabled state
- Preserve custom data-source classes and nested label

Refs: BUTTON_MIGRATION_PLAN.md
- Remove double curly braces from :disabled attribute
- Twig component attributes with colon prefix should not have {{ }}

Refs: BUTTON_MIGRATION_PLAN.md
- Replace legacy button-styled link with <twig:ibexa:link variant="button">
- Replace legacy button with <twig:ibexa:button>
- Migrate continue link (primary type)
- Migrate cancel button (secondary type, modal dismiss)
- Preserve modal dismiss functionality via attr parameter
- Replace legacy ghost button link with <twig:ibexa:link variant="button">
- Migrate download button for binary file field (ghost type, download icon)
- Preserve download attribute and ml-4 spacing class
Updates the shared admin Symfony form theme to default button and submit widgets to DS button classes, while preserving Symfony-generated attributes and behavior.

Also updates the content create submit override to use DS classes so the extra actions footer stays visually consistent.
@tischsoic tischsoic force-pushed the IBX-11236-use-ds-btn-component branch from 7f4c061 to 7bbd081 Compare March 24, 2026 09:39
@sonarqubecloud
Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants