Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add slot for more buttons in the result list items #1140

Open
santilland opened this issue Jul 26, 2024 · 2 comments
Open

Add slot for more buttons in the result list items #1140

santilland opened this issue Jul 26, 2024 · 2 comments
Labels
enhancement New feature or request help wanted Extra attention is needed itemfilter

Comments

@santilland
Copy link
Member

In eodash we want to add comparison buttons to list items, i can imagine other use cases where someone might want to add additional functionality to a result item, such as item information or custom button functionality.
Having a slot to add potentially other such things could be convenient.

@santilland santilland added enhancement New feature or request itemfilter labels Jul 26, 2024
@silvester-pari
Copy link
Collaborator

I am not sure if adding buttons to the result items is a good idea UX-wise, since it might become confusing to the user. Selecting an item is a clear primary action, but adding a secondary action needs some UX considerations first, and then we can think about implementation.
The issue I can think of with slots is that potentially this gives "too much power" to the parent app and can potentially destroy the layout; in e.g. layercontrol we have the "tools" that can be enabled/disabled, something like this might make more sense. Or we let the developer create a secondary action, and the icon and callback function can be defined 🤔

@santilland
Copy link
Member Author

I feel like there are many applications where UI elements are created that provide slots to extend them, for example, drop down menus, or other types of "list creations". In my opinion the results list is really a very similar thing, where a developer using the library would want to add something, such as images, icons, colors?. Thinking about it it might be even interesting to have a slot for before and for after the text.
One could in the olden times do it with css selectors, but that gets tricky within the shadow-root, right?
Maybe we can tag EOxElements issues/ideas to be discussed in a larger round to see what others think or so, e.g. dailies?

@santilland santilland added the help wanted Extra attention is needed label Aug 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed itemfilter
Projects
None yet
Development

No branches or pull requests

2 participants