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

Rendering not always triggered when Sigma.js network displayed inside a <dialog> #1498

Open
vemonet opened this issue Dec 18, 2024 · 0 comments
Labels

Comments

@vemonet
Copy link

vemonet commented Dec 18, 2024

  • Sigma.js version : 3.0.0
  • Graphology version : 0.25.4
  • Operating system: Ubuntu 22.04
  • Web browser: have been seen on Zen browser 1.0.2-b.2 (Firefox 133.0.3) (64-bit) and Chromium Version 131.0.6778.139 (Official Build) (64-bit)

Steps to reproduce

  1. Go to https://sib-swiss.github.io/sparql-editor/
  2. Choose an endpoint URL for which classes overview is available: https://biosoda.unil.ch/emi/sparql/ or https://www.bgee.org/sparql/
  3. Click on the button Classes overview which will open a <dialog>
  4. Sometimes the network is directly displayed, sometimes not!
  5. When the network does not display all we need to do is to filter/unfilter a predicate, this triggers a renderer.refresh({skipIndexation: true}), which displays the network

Expected behavior

Network should be displayed consistently everytime I open the dialog

Actual behavior

Sometimes the network is directly displayed when the dialog is shown, sometimes not!

Note

My Sigma.js is implemented in a standard web component custom element using light DOM: https://github.com/sib-swiss/sparql-editor/blob/main/packages/sparql-overview/src/sparql-overview.ts (not sure if that can have an impact)

I have never seen this behavior when Sigma.js is used outside of a <dialog> which let me think this issue is specific to when Sigma.js is included in a dialog, e.g. in this page network not in a dialog always works: https://sib-swiss.github.io/sparql-editor/overview

I am planning to fix this by adding an event to my web component, so that I can trigger a rendering from outside of the component, when the button to open the dialog is clicked on.

But I was wondering if you might already know where this problem comes from @jacomyal ? Thanks a lot!

@vemonet vemonet added the bug label Dec 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant