flinker-dom 1.1.14 → 1.1.15
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/dist/esm/processor.js
CHANGED
|
@@ -108,6 +108,7 @@ export class StyleSheetProcessor {
|
|
|
108
108
|
this.list.forEach(c => { c.clear(); });
|
|
109
109
|
}
|
|
110
110
|
}
|
|
111
|
+
StyleSheetProcessor.echo = false;
|
|
111
112
|
export class PseudoClass {
|
|
112
113
|
constructor(type, styleSheet) {
|
|
113
114
|
this.type = type;
|
|
@@ -119,6 +120,8 @@ export class PseudoClass {
|
|
|
119
120
|
if (this.style) {
|
|
120
121
|
const rule = tag + '.' + className + (this.type === 'none' ? '' : this.type) + '{' + this.style + '}';
|
|
121
122
|
this.styleSheet.insertRule(rule);
|
|
123
|
+
if (StyleSheetProcessor.echo)
|
|
124
|
+
console.log(`StyleSheetProcessor: new rule: ${rule}`);
|
|
122
125
|
}
|
|
123
126
|
}
|
|
124
127
|
setValue(key, value, priority, appendToClassName = true) {
|
|
@@ -4,6 +4,7 @@ export type PseudoClassType = typeof pseudoClasses[number];
|
|
|
4
4
|
export declare class StyleSheetProcessor {
|
|
5
5
|
private readonly hash;
|
|
6
6
|
private readonly list;
|
|
7
|
+
static echo: boolean;
|
|
7
8
|
constructor(styleSheet: CSSStyleSheet);
|
|
8
9
|
setValue(to: PseudoClassType, key: string, value: string, priority: RulePriority, appendToClassName?: boolean): void;
|
|
9
10
|
valuesToHashSum(): string;
|