Combo with custom icon? #3435
Replies: 7 comments 5 replies
-
Thanks @cliffordfajardo ! Combo in G6 is not perfect yet. I'm working on 2 related features recently:
Polishing the combo mechanism is one of the target of G6 in this year, and all the requirements, ideas, and contributions are welcome!! I will finish the two features I mentioned above in a month. To avoid the code conflicts, I suggest contributors to do something related after that. Before that, maybe getting familiar with core/Item/node, core/item/combo, core/element/combo, and the APIs related in core/graph/graph and core/controller/item will be helpful. Thanks again! |
Beta Was this translation helpful? Give feedback.
-
We published G6 v4.6.0-beta.1 today (2022.2.11):
here goes a demo with uncombo/combo interactions, and the layout keeps stable It is still a beta version, the usage could be found here:
|
Beta Was this translation helpful? Give feedback.
-
Hi @Yanyan-Wang
I'm having trouble finding an example online or when searching github for this use case custom icon for the combo (like in concept image shown above) @pomelo-nwu - mentioned this:
|
Beta Was this translation helpful? Give feedback.
-
@cliffordfajardo We had a similar problem on our project but decided to migrate from combos to nodes with all the custom rendering we need. But that requires manual positioning of inner nodes (in our case it's good). |
Beta Was this translation helpful? Give feedback.
-
Hi, all. The combo supports image icon for collapsed status now (v4.6.8). See docs here: https://g6.antv.vision/en/docs/manual/middle/elements/combos/defaultCombo#collapsedsubstituteicon |
Beta Was this translation helpful? Give feedback.
-
Code Sandbox Link: https://codesandbox.io/s/amazing-shape-fdvf5f?file=/App.tsx |
Beta Was this translation helpful? Give feedback.
-
Hi everyone! @Yanyan-Wang Did combos make it into Graphin? Would you please share a minimum example? Thank you for your effort! |
Beta Was this translation helpful? Give feedback.
-
Hi @Yanyan-Wang,
Is it currently possible to render a combo with a custom icon like in the reference example below?
If not ^, what type of work would it take to implement this feature?
New Combo features?
allow user to specify an image icon for the combo
when the icon representing the combo clicks the image transitions away and the real combo content is revealed
allow user to add a halo / icon to the edges of the combo (top-left, top-right, bottom-left, bottom-right)
rectangular-combos-beta.mp4
CleanShot.2022-01-10.at.19.22.30.mp4
Reference article:
Beta Was this translation helpful? Give feedback.
All reactions