typed-dom
Advanced tools
Comparing version 0.0.267 to 0.0.268
@@ -145,2 +145,3 @@ import { Symbol, document } from 'spica/global'; | ||
}); | ||
el[name.toLowerCase()] ??= ''; | ||
} | ||
@@ -147,0 +148,0 @@ continue; |
{ | ||
"name": "typed-dom", | ||
"version": "0.0.267", | ||
"version": "0.0.268", | ||
"description": "A value-level and type-level DOM builder.", | ||
@@ -62,8 +62,8 @@ "private": false, | ||
"karma-mocha": "^2.0.1", | ||
"mocha": "^9.2.2", | ||
"npm-check-updates": "^12.5.9", | ||
"mocha": "^10.0.0", | ||
"npm-check-updates": "^12.5.11", | ||
"power-assert": "^1.6.1", | ||
"spica": "0.0.524", | ||
"spica": "0.0.530", | ||
"tsify": "^5.0.4", | ||
"typescript": "4.6.3", | ||
"typescript": "4.6.4", | ||
"vinyl-buffer": "^1.0.1", | ||
@@ -70,0 +70,0 @@ "vinyl-source-stream": "^2.0.0" |
@@ -360,8 +360,8 @@ # typed-dom | ||
<T extends keyof HTMLElementTagNameMap>( | ||
factory: Factory<HTMLElementTagNameMap>, | ||
html: Factory<HTMLElementTagNameMap>, | ||
tag: T, | ||
attrs: Attrs, | ||
_: Attrs, | ||
children: K, | ||
) => | ||
factory(tag, void Object.assign<Attrs, Attrs>(attrs, { | ||
html(tag, { | ||
onmutate: ev => | ||
@@ -372,3 +372,3 @@ void i18n.init((err, t) => | ||
: t(children, data) ?? `{% Failed to translate "${children}". %}`), | ||
})); | ||
}); | ||
@@ -375,0 +375,0 @@ const el = Trans.span('Greeting', bind({ name: 'world' })); |
@@ -76,3 +76,3 @@ import { Symbol } from 'spica/global'; | ||
const el = elem(tag, factory, attrs, children); | ||
return new Elem(tag, el, attrs, children, container?.(el)); | ||
return new Elem(tag, el, children, container?.(el)); | ||
}; | ||
@@ -79,0 +79,0 @@ } |
@@ -74,3 +74,2 @@ import { Event } from 'spica/global'; | ||
public readonly element: E, | ||
attrs: Attrs, | ||
children: C, | ||
@@ -80,5 +79,5 @@ container: Element | ShadowRoot = element, | ||
const events = this[privates.events]; | ||
events.mutate = (attrs?.['onmutate'] ?? attrs?.['onMutate']) != null; | ||
events.connect = (attrs?.['onconnect'] ?? attrs?.['onConnect']) != null; | ||
events.disconnect = (attrs?.['ondisconnect'] ?? attrs?.['onDisconnect']) != null; | ||
events.mutate = element['onmutate'] != null; | ||
events.connect = element['onconnect'] != null; | ||
events.disconnect = element['ondisconnect'] != null; | ||
this[privates.children] = children; | ||
@@ -85,0 +84,0 @@ this[privates.container] = container; |
@@ -145,2 +145,3 @@ import { Symbol, document } from 'spica/global'; | ||
}); | ||
el[name.toLowerCase()] ??= ''; | ||
} | ||
@@ -147,0 +148,0 @@ continue; |
@@ -582,8 +582,8 @@ import { API, Shadow, HTML, SVG, El, Attrs, Factory, shadow, html } from '../..'; | ||
<T extends keyof HTMLElementTagNameMap>( | ||
factory: Factory<HTMLElementTagNameMap>, | ||
html: Factory<HTMLElementTagNameMap>, | ||
tag: T, | ||
attrs: Attrs, | ||
_: Attrs, | ||
children: K, | ||
) => | ||
factory(tag, void Object.assign<Attrs, Attrs>(attrs, { | ||
html(tag, { | ||
onmutate: ev => | ||
@@ -594,3 +594,3 @@ void i18n.init((err, t) => | ||
: t(children, data) ?? `{% Failed to translate "${children}". %}`), | ||
})); | ||
}); | ||
@@ -597,0 +597,0 @@ const el = Trans.span('Greeting', bind({ name: 'world' })); |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
673366
15845