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

Cliparts are not visible in the frontend #12

Open
jonnitto opened this issue Oct 7, 2020 · 1 comment
Open

Cliparts are not visible in the frontend #12

jonnitto opened this issue Oct 7, 2020 · 1 comment

Comments

@jonnitto
Copy link

jonnitto commented Oct 7, 2020

If cliparts are used in a diagramm, there are visible in the backend, but not in the frontend.

image

If I create an image with the src of the svg, the cliparts will not show up, but if I include directly the SVG, everything looks fine:
image

@jonnitto
Copy link
Author

jonnitto commented Oct 7, 2020

Currently, I solved this with this Javascript:

[...document.querySelectorAll('.sandstorm-mxgraph-diagram img')].forEach(
    (image) => {
        fetch(image.src)
            .then((response) => response.text())
            .then((svg) => {
                image.parentNode.innerHTML = svg;
            })
            .catch(console.error.bind(console));
    }
);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant