Blazor-Diagrams / Blazor.Diagrams

A fully customizable and extensible all-purpose diagrams library for Blazor
https://blazor-diagrams.zhaytam.com
MIT License
919 stars 176 forks source link

Link Labels don't render on Firefox #377

Closed Mr-Technician closed 4 months ago

Mr-Technician commented 8 months ago

Link labels do not render at all when using Firefox. This can be reproduced on the Blazor Diagrams home page: image

Expected result: image

I have tested Firefox on (latest version except in the last case):

All cases had the same issue.

prof3000 commented 7 months ago

Good day, please how to make label link not blue background color, how to make nodemodel make background red or green. Best regards

zHaytam commented 7 months ago

Hello, I'll check this and get back to you!

Sycha commented 4 months ago

I have had the same problem. I found that firefox doesn't display foreignObject elements that don't have a height and width defined. I was able to create a work around by adding to the css of a parent component:

::deep foreignObject.diagram-link-label { width: 100vw; height: 100wh; }

There is probably another css attribute that can be set to remove the need to set a large width and height to stop label wrapping.

It still works on Edge and Chrome.

I hope that helps

zHaytam commented 4 months ago

1px seems to be enough since in CSS I already added overflow: visible;, I will add this to the next version!

Mr-Technician commented 4 months ago

Thanks! @zHaytam