import { describe, expect, test } from 'bun:test' import { sceneNodesToTailwindJSX } from '#dom-css/index' import { makeGraph, pageId, tw } from './helpers' describe('Tailwind JSX structure', () => { test('layer names cannot add attributes', () => { const graph = makeGraph() const node = graph.createNode('RECTANGLE', pageId(graph), { name: 'a" onClick={alert(1)} x="', width: 100, height: 48 }) expect(tw(graph, node.id)).toStartWith( '
Hello World
') expect(jsx).not.toContain('