-
Notifications
You must be signed in to change notification settings - Fork 220
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
Added Classes to LinkRenderer #386
base: develop
Are you sure you want to change the base?
Added Classes to LinkRenderer #386
Conversation
hello @snakex64 i need added style to link like image or control in size arrow can inform me how can i do this ? |
Sorry mate, no idea! |
This is highly needed, and seeing that its not been merged after so long even though its such a simple addition doesn't leave one feeling very hopeful for this repository. |
Hello, sorry that this took A LOT of time for me to check it, I was dealing with some stuff. The "issue" I see in this PR is that I am trying not to put UI properties in the models (Core project) to separate the two, so I'm not sure what to do in this case... |
Hi everyone, I was looking for the exact same feature. I need to conditionally add a class to a The ideal approach, in my view, is to use a custom How can I do that? |
@zHaytam I apologize for my previous comment, it was insensitive and i will act better in the future. I still really want this feature so that we are able to individually style links between nodes. Right now you are only able to style all links at the same time as far as i know (except color). Perhaps its possible to add the "Classes" to the LinkModel instead, and then consume it in the LinkWidget , like we do with Color today? It would give us a way to target individual links for styling, or even behaviour with DOM manipulation. |
Hey! Never got a notification that you replied on here. Kinda forgot about it, I have been using my own fork for a while now. Do you have any idea how to allow modifying the look of the link renderer other than the proposed implementation ? Being able to change the look of the links is important in many cases. Thanks for your help, |
Hey, The way I see it, But the base model, as I pictured them, are just base, they should be UI-agnostic. Granted, we only have Blazor right now, but the logic can apply to different frameworks and I wanted to make it possible without changing or cross-using stuff in the projects. So I see 2 solutions:
What do you guys think? Again, sorry for the delay, life has been shit lately but it's getting better and better. |
I think going with my PR is the better call. It would make it possible to do what this PR is trying to solve while avoiding the Base models, with the only negative being that you have to use the css :has functionality to target the |
I added a "Classes" property to BaseLinkModel which is then used in the LinkRenderer. This allow users to add a css class to the element of a link