-
-
Notifications
You must be signed in to change notification settings - Fork 44
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
node image prevent to show node stroke #25
Comments
hi i use image as node and then when i want to use stroke for the same node it will be hide behind the image |
Hi @MohandesaliRahnema, |
thank you a lot you save my day
excuse me i have two another question
1- how can i have two image on a node for ex. i want to show os icon as a
small circle on right bottom of a node where the node has an image itself
for ex a node have status image via sub img to show os
2- the event that return on node click has no attr offsetx and offset on
event.target
best regards
…On Sun, Dec 19, 2021 at 3:15 PM dash14 ***@***.***> wrote:
Hi @MohandesaliRahnema <https://github.com/MohandesaliRahnema>,
I think it is possible to do this by inserting the circle that draws the
node stroke after the image.
I changed the node image example to do so. I hope this is helpful.
https://dash14.github.io/v-network-graph/examples/appearance.html#custom-node
—
Reply to this email directly, view it on GitHub
<#25 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AEAUS5VBX6UL36TINMF2DNLURXAVHANCNFSM5KLTJUAA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
As implemented in the example, the image is just an SVG
There are no offset attributes in SVG Element, so try using |
thank you very much
…On Mon, Dec 20, 2021 at 8:20 PM dash14 ***@***.***> wrote:
1- how can i have two image on a node
As implemented in the example, the image is just an SVG <image> tag.
You can put as many as you want between <template #override-node="..."> ~
</template>.
The display position of the placed element can be adjusted with x and y.
The coordinates of the center of the node are (0,0).
2- the event that return on node click has no attr offsetx and offset on
event.target
There are no offset attributes in SVG Element, so try using
getBoundingClientRect() or getBBox().
—
Reply to this email directly, view it on GitHub
<#25 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AEAUS5R2GQU47GRPWMC4TIDUR5NEJANCNFSM5KLTJUAA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
[image: image.png]
when i use two template for image i got above error
…On Tue, Dec 21, 2021 at 8:39 AM Ali Rahnema ***@***.***> wrote:
thank you very much
On Mon, Dec 20, 2021 at 8:20 PM dash14 ***@***.***> wrote:
> 1- how can i have two image on a node
>
> As implemented in the example, the image is just an SVG <image> tag.
> You can put as many as you want between <template #override-node="...">
> ~ </template>.
> The display position of the placed element can be adjusted with x and y.
> The coordinates of the center of the node are (0,0).
>
> 2- the event that return on node click has no attr offsetx and offset on
> event.target
>
> There are no offset attributes in SVG Element, so try using
> getBoundingClientRect() or getBBox().
>
> —
> Reply to this email directly, view it on GitHub
> <#25 (comment)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AEAUS5R2GQU47GRPWMC4TIDUR5NEJANCNFSM5KLTJUAA>
> .
> Triage notifications on the go with GitHub Mobile for iOS
> <https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
> or Android
> <https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
>
> You are receiving this because you were mentioned.Message ID:
> ***@***.***>
>
|
I can't see the image... I don't know how you are writing the code, so I'll guess. |
oh yahhhh...
thank you very much
…On Tue, Dec 21, 2021 at 7:33 PM dash14 ***@***.***> wrote:
I can't see the image... I don't know how you are writing the code, so
I'll guess.
Are you writing two <template template #override-node>?
This <template> is to replace a node, and can only be written once.
I think you want to use multiple tags (elements) to represent a node.
So please put two <image> inside one <template #override-node>.
—
Reply to this email directly, view it on GitHub
<#25 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AEAUS5VZYQ7I3ZNVORUEKG3USCQMNANCNFSM5KLTJUAA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Thanks for your reply. |
hii use image as node and then when i want to use storke for the same node it will be hide behind the image
how can i fix this issue
The text was updated successfully, but these errors were encountered: