tool-shack 0.0.25 → 0.0.27
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -18,10 +18,8 @@ export const createElement = (tagName, props) => {
|
|
|
18
18
|
element.setAttribute(`aria-${ariaKey}`, ariaValue);
|
|
19
19
|
}
|
|
20
20
|
}
|
|
21
|
-
else if (
|
|
22
|
-
|
|
23
|
-
element.style[styleKey] = styleValue;
|
|
24
|
-
}
|
|
21
|
+
else if (key === 'style') {
|
|
22
|
+
Object.assign(element.style, props.style);
|
|
25
23
|
}
|
|
26
24
|
else if (key === 'children') {
|
|
27
25
|
const fragment = document.createDocumentFragment();
|
package/package.json
CHANGED
package/src/dom/createElement.ts
CHANGED
|
@@ -23,10 +23,8 @@ export const createElement = <T = HTMLElement>(
|
|
|
23
23
|
for (const [ariaKey, ariaValue] of Object.entries(props.aria!)) {
|
|
24
24
|
element.setAttribute(`aria-${ariaKey}`, ariaValue);
|
|
25
25
|
}
|
|
26
|
-
} else if (
|
|
27
|
-
|
|
28
|
-
(element.style as any)[styleKey] = styleValue;
|
|
29
|
-
}
|
|
26
|
+
} else if (key === 'style') {
|
|
27
|
+
Object.assign(element.style, props.style);
|
|
30
28
|
} else if (key === 'children') {
|
|
31
29
|
const fragment = document.createDocumentFragment();
|
|
32
30
|
for (const child of props.children!) {
|