[2.0.0-alpha3] Component with same labels: how to differentiate?

Created on 27 May 2024, 6 months ago
Updated 22 June 2024, 5 months ago

Problem/Motivation

With SDC, it is more common to have a few components the same name in component lists:

  • because components can be provided by any activated modules and themes (only activated modules, the active theme and its parent in UI Patterns 1.x)
  • because component override is less common, it must be manually decided with the "replaces" property (automatic if same plugin ID in UI Patterns 1.x)

For example, let's take those 2 extensions:

  • "Foo", with "Card" & "Button" components
  • "Beautiful" theme, with "Hero" & "Button" components, which is the current active theme

I have those 4 components, with duplicated "Button", so it is confusing:

  • Button
  • Button
  • Card
  • Hero

Proposed resolution

Proposals:

  • check duplicate labels for all components, and add the extension label in between parenthesis only for duplicated
    • Button (Beautiful)
    • Button (Foo)
    • Card
    • Hero
  • add the extension label in between parenthesis only for components which are not from the active theme
    • Button
    • Button (Foo)
    • Card (Foo)
    • Hero
  • both together
    • Button
    • Button (Foo)
    • Card
    • Hero

Remaining tasks

Let's talk all together before doing anything

User interface changes

Yes, it gets better

API changes

I don't think so

πŸ“Œ Task
Status

Fixed

Version

2.0

Component

Code

Created by

πŸ‡«πŸ‡·France pdureau Paris

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024