1 | "use strict";
|
2 | Object.defineProperty(exports, "__esModule", { value: true });
|
3 | exports.createElement = void 0;
|
4 | const g_1 = require("@antv/g");
|
5 | function createElement(descriptor) {
|
6 | const render = typeof descriptor === 'function' ? descriptor : descriptor.render;
|
7 | return class extends g_1.CustomElement {
|
8 | connectedCallback() {
|
9 | this.draw();
|
10 | }
|
11 | attributeChangedCallback() {
|
12 | this.draw();
|
13 | }
|
14 | draw() {
|
15 | render(this);
|
16 | }
|
17 | };
|
18 | }
|
19 | exports.createElement = createElement;
|
20 |
|
\ | No newline at end of file |