@rxdi/lit-html 0.7.137 → 0.7.140
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.
package/README.md
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.Component = void 0;
|
|
4
4
|
const lit_html_1 = require("../lit-html/lit-html");
|
|
5
|
-
const helpers_1 = require("./helpers");
|
|
6
5
|
const legacyCustomElement = (tagName, clazz, options) => {
|
|
7
6
|
window.customElements.define(tagName, clazz, options);
|
|
8
7
|
return clazz;
|
|
@@ -73,8 +72,9 @@ const customElement = (tag, config = {}) => (Base) => {
|
|
|
73
72
|
}
|
|
74
73
|
render() {
|
|
75
74
|
var _a;
|
|
76
|
-
if ((_a = config.
|
|
77
|
-
|
|
75
|
+
if ((_a = config.modifiers) === null || _a === void 0 ? void 0 : _a.length) {
|
|
76
|
+
const pipe = (...fns) => (x) => fns.reduce((v, f) => f.call(this, v), x);
|
|
77
|
+
return pipe(...(config.modifiers.map(v => v['modifier'])))(config.template.call(this));
|
|
78
78
|
}
|
|
79
79
|
return config.template.call(this);
|
|
80
80
|
}
|
package/package.json
CHANGED