pull/14685/head
Dominic Gannaway 2 years ago
parent aa2654d633
commit 05d4a9e0f3

@ -0,0 +1,8 @@
{#if true}
<g>
<rect x="20" y="10" width="50" height="50" fill="yellow"/>
</g>
{:else}
<div>lol</div>
{/if}

@ -0,0 +1,14 @@
import { test, ok } from '../../test';
export default test({
html: `<svg height="200px" viewBox="0 0 100 100" width="200px"><g><rect fill="yellow" height="50" width="50" x="20" y="10"></rect></g></svg>`,
test({ assert, target }) {
const g = target.querySelector('g');
const rect = target.querySelector('rect');
ok(g);
ok(rect);
assert.equal(g.namespaceURI, 'http://www.w3.org/2000/svg');
assert.equal(rect.namespaceURI, 'http://www.w3.org/2000/svg');
}
});

@ -0,0 +1,7 @@
<script>
import Child from "./Child.svelte";
</script>
<svg viewBox="0 0 100 100" width="200px" height="200px">
<Child />
</svg>
Loading…
Cancel
Save