Commit 920ec5ad authored by Clément's avatar Clément

update: retro compat "solid" → "sib" prefix

parent 353df68c
Pipeline #7353 passed with stages
in 8 minutes and 39 seconds
......@@ -1315,9 +1315,9 @@
"dev": true
},
"@hapi/hoek": {
"version": "8.5.0",
"resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-8.5.0.tgz",
"integrity": "sha512-7XYT10CZfPsH7j9F1Jmg1+d0ezOux2oM2GfArAzLwWe4mE2Dr3hVjsAL6+TFY49RRJlCdJDMw3nJsLFroTc8Kw==",
"version": "8.5.1",
"resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-8.5.1.tgz",
"integrity": "sha512-yN7kbciD87WzLGc5539Tn0sApjyiGHAJgKvG9W8C7O+6c7qmoQMfVs0W4bX17eqz6C78QJqqFrtgdK5EWf6Qow==",
"dev": true
},
"@hapi/joi": {
......
......@@ -11,19 +11,6 @@ export class Sib {
const component = ComponentFactory.build(componentDefinition);
const cls = this.toElement(component);
defineComponent(component.name, cls);
if (component.name.startsWith('solid-')) {
const sibTagName = component.name.replace(/^solid-/, 'sib-');
customElements.define(
sibTagName,
class extends cls {
constructor() {
console.warn(`${sibTagName} is deprecated, please use ${component.name} insteed`)
super()
}
}
);
}
}
protected static toElement(component: ComponentConstructorInterface): typeof HTMLElement {
......
import { BaseWidget } from './baseWidget.js';
import { defineComponent } from '../libs/helpers.js';
export const widgetFactory = (
tagName: string,
......@@ -20,21 +21,6 @@ export const widgetFactory = (
return childTemplate;
}
};
customElements.define(tagName, cls);
if (tagName.startsWith('solid-')) {
const sibTagName = tagName.replace(/^solid-/, 'sib-');
customElements.define(
sibTagName,
class extends cls {
constructor() {
console.warn(
`${sibTagName} is deprecated, please use ${tagName} insteed`,
);
super();
}
},
);
}
defineComponent(tagName, cls);
return cls;
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment