@teleporthq/teleport-plugin-css 0.20.6 → 0.21.0
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/__tests__/referenced-styles.ts +1 -1
- package/__tests__/style-sheet.ts +4 -4
- package/dist/cjs/index.d.ts +3 -2
- package/dist/cjs/index.js +52 -48
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/style-sheet.d.ts +0 -1
- package/dist/cjs/style-sheet.js +2 -3
- package/dist/cjs/style-sheet.js.map +1 -1
- package/dist/cjs/tsconfig.tsbuildinfo +1 -1
- package/dist/esm/index.d.ts +3 -2
- package/dist/esm/index.js +52 -48
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/style-sheet.d.ts +0 -1
- package/dist/esm/style-sheet.js +2 -3
- package/dist/esm/style-sheet.js.map +1 -1
- package/dist/esm/tsconfig.tsbuildinfo +1 -1
- package/package.json +5 -5
- package/src/index.ts +62 -71
- package/src/style-sheet.ts +6 -6
|
@@ -100,7 +100,7 @@ describe('Referenced Styles for inlined and project-referenced with Templates (H
|
|
|
100
100
|
expect(cssFile).toBeDefined()
|
|
101
101
|
expect(cssFile.content).toContain('width')
|
|
102
102
|
expect(cssFile.content).toContain('@media(max-width: 991px)')
|
|
103
|
-
expect(nodeReference.properties.class).toBe('container
|
|
103
|
+
expect(nodeReference.properties.class).toBe('container primaryButton')
|
|
104
104
|
})
|
|
105
105
|
})
|
|
106
106
|
|
package/__tests__/style-sheet.ts
CHANGED
|
@@ -84,14 +84,14 @@ describe('plugin-css-style-sheet', () => {
|
|
|
84
84
|
--blue-600: #6b7db3;
|
|
85
85
|
}
|
|
86
86
|
`)
|
|
87
|
-
expect(content).toContain(`.
|
|
87
|
+
expect(content).toContain(`.conditionalButton:hover {
|
|
88
88
|
background: var(--blue-500);
|
|
89
89
|
}
|
|
90
90
|
`)
|
|
91
91
|
expect(content).toContain(`color: var(--red-500)`)
|
|
92
|
-
expect(content).toContain('.
|
|
93
|
-
expect(content).toContain('
|
|
94
|
-
expect(content).toContain('.
|
|
92
|
+
expect(content).toContain('.primaryButton')
|
|
93
|
+
expect(content).toContain('secondaryButton')
|
|
94
|
+
expect(content).toContain('.conditionalButton:hover')
|
|
95
95
|
expect(content).toContain('@media(max-width: 991px)')
|
|
96
96
|
expect(content).not.toContain('5ecfa1233b8e50f60ea2b64b')
|
|
97
97
|
})
|
package/dist/cjs/index.d.ts
CHANGED
|
@@ -10,8 +10,9 @@ interface CSSPluginConfig {
|
|
|
10
10
|
templateStyle: 'html' | 'jsx';
|
|
11
11
|
declareDependency: 'import' | 'decorator' | 'none';
|
|
12
12
|
dynamicVariantPrefix?: string;
|
|
13
|
+
staticPropReferences?: boolean;
|
|
13
14
|
}
|
|
14
|
-
|
|
15
|
-
export { createStyleSheetPlugin };
|
|
15
|
+
declare const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig>;
|
|
16
|
+
export { createStyleSheetPlugin, createCSSPlugin };
|
|
16
17
|
declare const _default: ComponentPlugin;
|
|
17
18
|
export default _default;
|
package/dist/cjs/index.js
CHANGED
|
@@ -70,7 +70,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
70
70
|
}
|
|
71
71
|
};
|
|
72
72
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
73
|
-
exports.
|
|
73
|
+
exports.createCSSPlugin = exports.createStyleSheetPlugin = void 0;
|
|
74
74
|
var teleport_shared_1 = require("@teleporthq/teleport-shared");
|
|
75
75
|
var teleport_plugin_common_1 = require("@teleporthq/teleport-plugin-common");
|
|
76
76
|
var types = __importStar(require("@babel/types"));
|
|
@@ -78,16 +78,14 @@ var teleport_types_1 = require("@teleporthq/teleport-types");
|
|
|
78
78
|
var style_sheet_1 = require("./style-sheet");
|
|
79
79
|
Object.defineProperty(exports, "createStyleSheetPlugin", { enumerable: true, get: function () { return style_sheet_1.createStyleSheetPlugin; } });
|
|
80
80
|
var createCSSPlugin = function (config) {
|
|
81
|
-
var _a = config || {}, _b = _a.chunkName, chunkName = _b === void 0 ? 'style-chunk' : _b, _c = _a.templateChunkName, templateChunkName = _c === void 0 ? 'template-chunk' : _c, _d = _a.componentDecoratorChunkName, componentDecoratorChunkName = _d === void 0 ? 'component-decorator' : _d, _e = _a.inlineStyleAttributeKey, inlineStyleAttributeKey = _e === void 0 ? 'style' : _e, _f = _a.classAttributeName, classAttributeName = _f === void 0 ? 'class' : _f, _g = _a.templateStyle, templateStyle = _g === void 0 ? 'html' : _g, _h = _a.declareDependency, declareDependency = _h === void 0 ? 'none' : _h, _j = _a.forceScoping, forceScoping = _j === void 0 ? false : _j, dynamicVariantPrefix = _a.dynamicVariantPrefix;
|
|
81
|
+
var _a = config || {}, _b = _a.chunkName, chunkName = _b === void 0 ? 'style-chunk' : _b, _c = _a.templateChunkName, templateChunkName = _c === void 0 ? 'template-chunk' : _c, _d = _a.componentDecoratorChunkName, componentDecoratorChunkName = _d === void 0 ? 'component-decorator' : _d, _e = _a.inlineStyleAttributeKey, inlineStyleAttributeKey = _e === void 0 ? 'style' : _e, _f = _a.classAttributeName, classAttributeName = _f === void 0 ? 'class' : _f, _g = _a.templateStyle, templateStyle = _g === void 0 ? 'html' : _g, _h = _a.declareDependency, declareDependency = _h === void 0 ? 'none' : _h, _j = _a.forceScoping, forceScoping = _j === void 0 ? false : _j, dynamicVariantPrefix = _a.dynamicVariantPrefix, _k = _a.staticPropReferences, staticPropReferences = _k === void 0 ? false : _k;
|
|
82
82
|
var cssPlugin = function (structure) { return __awaiter(void 0, void 0, void 0, function () {
|
|
83
|
-
var uidl, chunks, dependencies, options, node, _a, componentStyleSet, _b,
|
|
84
|
-
return __generator(this, function (
|
|
83
|
+
var uidl, chunks, dependencies, options, node, _a, componentStyleSet, _b, propDefinitions, _c, projectStyleSet, _d, _e, _f, tokens, isRootComponent, _g, _h, styleSetDefinitions, projectStyleSheetName, projectStyleSheetPath, templateChunk, componentDecoratorChunk, templateLookup, propsPrefix, cssMap, mediaStylesMap, cssFileName, decoratorAST, decoratorParam;
|
|
84
|
+
return __generator(this, function (_j) {
|
|
85
85
|
uidl = structure.uidl, chunks = structure.chunks, dependencies = structure.dependencies, options = structure.options;
|
|
86
|
-
node = uidl.node, _a = uidl.styleSetDefinitions, componentStyleSet = _a === void 0 ? {} : _a;
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
componentFileName = teleport_shared_1.UIDLUtils.getComponentFileName(uidl) // Filename used to enforce dash case naming
|
|
90
|
-
;
|
|
86
|
+
node = uidl.node, _a = uidl.styleSetDefinitions, componentStyleSet = _a === void 0 ? {} : _a, _b = uidl.propDefinitions, propDefinitions = _b === void 0 ? {} : _b;
|
|
87
|
+
_c = options || {}, projectStyleSet = _c.projectStyleSet, _d = _c.designLanguage, _e = _d === void 0 ? {} : _d, _f = _e.tokens, tokens = _f === void 0 ? {} : _f, isRootComponent = _c.isRootComponent;
|
|
88
|
+
_g = projectStyleSet || {}, _h = _g.styleSetDefinitions, styleSetDefinitions = _h === void 0 ? {} : _h, projectStyleSheetName = _g.fileName, projectStyleSheetPath = _g.path;
|
|
91
89
|
if (isRootComponent) {
|
|
92
90
|
if (Object.keys(tokens).length > 0 || Object.keys(styleSetDefinitions).length > 0) {
|
|
93
91
|
dependencies[projectStyleSheetName] = {
|
|
@@ -113,30 +111,16 @@ var createCSSPlugin = function (config) {
|
|
|
113
111
|
var classNamesToAppend = new Set();
|
|
114
112
|
var dynamicVariantsToAppend = new Set();
|
|
115
113
|
var _c = element.style, style = _c === void 0 ? {} : _c, key = element.key, _d = element.referencedStyles, referencedStyles = _d === void 0 ? {} : _d, dependency = element.dependency, _e = element.attrs, attrs = _e === void 0 ? {} : _e, elementType = element.elementType;
|
|
114
|
+
var elementClassName = teleport_shared_1.StringUtils.camelCaseToDashCase(key);
|
|
116
115
|
if (forceScoping && (dependency === null || dependency === void 0 ? void 0 : dependency.type) === 'local') {
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
if (((_a = attribute.name) === null || _a === void 0 ? void 0 : _a.name) === attr &&
|
|
126
|
-
((_b = attribute.value) === null || _b === void 0 ? void 0 : _b.value)) {
|
|
127
|
-
;
|
|
128
|
-
attribute.value.value = "".concat(compStyleName_1, "-").concat(teleport_shared_1.StringUtils.camelCaseToDashCase(attribute.value.value));
|
|
129
|
-
}
|
|
130
|
-
});
|
|
131
|
-
}
|
|
132
|
-
if (templateStyle === 'html') {
|
|
133
|
-
var compInstanceNode = templateLookup[key];
|
|
134
|
-
if (!(compInstanceNode === null || compInstanceNode === void 0 ? void 0 : compInstanceNode.properties[attr])) {
|
|
135
|
-
return;
|
|
136
|
-
}
|
|
137
|
-
compInstanceNode.properties[attr] = "".concat(compStyleName_1, "-").concat(teleport_shared_1.StringUtils.camelCaseToDashCase(String(compInstanceNode.properties[attr])));
|
|
138
|
-
}
|
|
139
|
-
}
|
|
116
|
+
teleport_plugin_common_1.StyleBuilders.setPropValueForCompStyle({
|
|
117
|
+
attrs: attrs,
|
|
118
|
+
key: key,
|
|
119
|
+
jsxNodesLookup: templateLookup,
|
|
120
|
+
templateStyle: templateStyle,
|
|
121
|
+
getClassName: function (styleName) {
|
|
122
|
+
return getClassName(forceScoping, teleport_shared_1.StringUtils.camelCaseToDashCase(elementType), styleName);
|
|
123
|
+
},
|
|
140
124
|
});
|
|
141
125
|
}
|
|
142
126
|
if (Object.keys(style).length === 0 &&
|
|
@@ -148,10 +132,7 @@ var createCSSPlugin = function (config) {
|
|
|
148
132
|
if (!root) {
|
|
149
133
|
throw new teleport_types_1.PluginCSS("Node - ".concat(key, " is missing from the template chunk"));
|
|
150
134
|
}
|
|
151
|
-
var
|
|
152
|
-
var className = forceScoping // when the framework doesn't provide automating scoping for classNames
|
|
153
|
-
? "".concat(componentFileName, "-").concat(elementClassName)
|
|
154
|
-
: elementClassName;
|
|
135
|
+
var className = getClassName(forceScoping, uidl.name, elementClassName);
|
|
155
136
|
var _f = teleport_shared_1.UIDLUtils.splitDynamicAndStaticStyles(style), staticStyles = _f.staticStyles, dynamicStyles = _f.dynamicStyles, tokenStyles = _f.tokenStyles;
|
|
156
137
|
if (Object.keys(staticStyles).length > 0 || Object.keys(tokenStyles).length > 0) {
|
|
157
138
|
var collectedStyles = __assign(__assign({}, teleport_plugin_common_1.StyleUtils.getContentOfStyleObject(staticStyles)), teleport_plugin_common_1.StyleUtils.getCSSVariablesContentFromTokenStyles(tokenStyles));
|
|
@@ -174,6 +155,7 @@ var createCSSPlugin = function (config) {
|
|
|
174
155
|
}
|
|
175
156
|
Object.values(referencedStyles).forEach(function (styleRef) {
|
|
176
157
|
var _a;
|
|
158
|
+
var _b;
|
|
177
159
|
switch (styleRef.content.mapType) {
|
|
178
160
|
case 'inlined': {
|
|
179
161
|
var filtredStyles = teleport_shared_1.UIDLUtils.splitDynamicAndStaticStyles(styleRef.content.styles);
|
|
@@ -182,7 +164,10 @@ var createCSSPlugin = function (config) {
|
|
|
182
164
|
var conditionType = condition.conditionType;
|
|
183
165
|
if (conditionType === 'screen-size') {
|
|
184
166
|
var maxWidth = condition.maxWidth;
|
|
185
|
-
|
|
167
|
+
if (!mediaStylesMap[String(maxWidth)]) {
|
|
168
|
+
mediaStylesMap[String(maxWidth)] = [];
|
|
169
|
+
}
|
|
170
|
+
mediaStylesMap[String(maxWidth)].push((_a = {}, _a[className] = collectedStyles, _a));
|
|
186
171
|
}
|
|
187
172
|
if (condition.conditionType === 'element-state') {
|
|
188
173
|
cssMap.push(teleport_plugin_common_1.StyleBuilders.createCSSClassWithSelector(className, "&:".concat(condition.content), collectedStyles));
|
|
@@ -192,20 +177,34 @@ var createCSSPlugin = function (config) {
|
|
|
192
177
|
}
|
|
193
178
|
case 'component-referenced': {
|
|
194
179
|
if (styleRef.content.content.type === 'static') {
|
|
195
|
-
classNamesToAppend.add(String(
|
|
196
|
-
? "".concat(componentFileName, "-").concat(teleport_shared_1.StringUtils.camelCaseToDashCase(String(styleRef.content.content.content)))
|
|
197
|
-
: styleRef.content.content.content));
|
|
180
|
+
classNamesToAppend.add(String(styleRef.content.content.content));
|
|
198
181
|
}
|
|
199
182
|
if (styleRef.content.content.type === 'dynamic' &&
|
|
200
183
|
styleRef.content.content.content.referenceType === 'prop') {
|
|
201
|
-
|
|
202
|
-
|
|
184
|
+
var defaultPropValue = (_b = propDefinitions[styleRef.content.content.content.id]) === null || _b === void 0 ? void 0 : _b.defaultValue;
|
|
185
|
+
if (defaultPropValue) {
|
|
186
|
+
/* Changing the default value of the prop.
|
|
187
|
+
When forceScoping is enabled the classnames change. So, we need to change the default prop too. */
|
|
188
|
+
propDefinitions[styleRef.content.content.content.id].defaultValue = getClassName(forceScoping, uidl.name, String(defaultPropValue));
|
|
189
|
+
}
|
|
190
|
+
if (staticPropReferences) {
|
|
191
|
+
if (!defaultPropValue) {
|
|
192
|
+
return;
|
|
193
|
+
}
|
|
194
|
+
if (staticPropReferences) {
|
|
195
|
+
classNamesToAppend.add(getClassName(forceScoping, uidl.name, String(defaultPropValue)));
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
else {
|
|
199
|
+
dynamicVariantsToAppend.add(styleRef.content.content.content.id);
|
|
203
200
|
}
|
|
204
|
-
dynamicVariantsToAppend.add(styleRef.content.content.content.id);
|
|
205
201
|
}
|
|
206
202
|
if (styleRef.content.content.type === 'dynamic' &&
|
|
207
203
|
styleRef.content.content.content.referenceType === 'comp') {
|
|
208
|
-
|
|
204
|
+
if (!componentStyleSet[styleRef.content.content.content.id]) {
|
|
205
|
+
throw new teleport_types_1.PluginCSS("Node ".concat(elementType, " is referring to a comp style instance ").concat(styleRef.content.content.content.id, " which is missing."));
|
|
206
|
+
}
|
|
207
|
+
classNamesToAppend.add(getClassName(forceScoping, uidl.name, String(styleRef.content.content.content.id)));
|
|
209
208
|
}
|
|
210
209
|
return;
|
|
211
210
|
}
|
|
@@ -215,11 +214,11 @@ var createCSSPlugin = function (config) {
|
|
|
215
214
|
if (!referedStyle) {
|
|
216
215
|
throw new teleport_types_1.PluginCSS("Style used from global stylesheet is missing - ".concat(content.referenceId));
|
|
217
216
|
}
|
|
218
|
-
classNamesToAppend.add(
|
|
217
|
+
classNamesToAppend.add(content.referenceId);
|
|
219
218
|
return;
|
|
220
219
|
}
|
|
221
220
|
default: {
|
|
222
|
-
throw new teleport_types_1.PluginCSS("
|
|
221
|
+
throw new teleport_types_1.PluginCSS("Un-supported style reference ".concat(JSON.stringify(styleRef.content, null, 2)));
|
|
223
222
|
}
|
|
224
223
|
}
|
|
225
224
|
});
|
|
@@ -244,7 +243,7 @@ var createCSSPlugin = function (config) {
|
|
|
244
243
|
}
|
|
245
244
|
});
|
|
246
245
|
if (Object.keys(componentStyleSet).length > 0) {
|
|
247
|
-
teleport_plugin_common_1.StyleBuilders.generateStylesFromStyleSetDefinitions(componentStyleSet, cssMap, mediaStylesMap,
|
|
246
|
+
teleport_plugin_common_1.StyleBuilders.generateStylesFromStyleSetDefinitions(componentStyleSet, cssMap, mediaStylesMap, function (styleName) { return getClassName(forceScoping, uidl.name, styleName); });
|
|
248
247
|
}
|
|
249
248
|
if (Object.keys(mediaStylesMap).length > 0) {
|
|
250
249
|
cssMap.push.apply(cssMap, teleport_plugin_common_1.StyleBuilders.generateMediaStyle(mediaStylesMap));
|
|
@@ -283,7 +282,7 @@ var createCSSPlugin = function (config) {
|
|
|
283
282
|
return cssPlugin;
|
|
284
283
|
};
|
|
285
284
|
exports.createCSSPlugin = createCSSPlugin;
|
|
286
|
-
exports.default =
|
|
285
|
+
exports.default = createCSSPlugin();
|
|
287
286
|
var createDynamicInlineStyle = function (styles) {
|
|
288
287
|
return Object.keys(styles)
|
|
289
288
|
.map(function (styleKey) {
|
|
@@ -291,4 +290,9 @@ var createDynamicInlineStyle = function (styles) {
|
|
|
291
290
|
})
|
|
292
291
|
.join(', ');
|
|
293
292
|
};
|
|
293
|
+
var getClassName = function (scoping, uidlName, nodeStyleName) {
|
|
294
|
+
return scoping
|
|
295
|
+
? teleport_shared_1.StringUtils.camelCaseToDashCase("".concat(uidlName, "-").concat(nodeStyleName))
|
|
296
|
+
: teleport_shared_1.StringUtils.camelCaseToDashCase(nodeStyleName);
|
|
297
|
+
};
|
|
294
298
|
//# sourceMappingURL=index.js.map
|
package/dist/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+DAAoE;AACpE,6EAAmG;AACnG,kDAAqC;AACrC,6DAWmC;AACnC,6CAAsD;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,+DAAoE;AACpE,6EAAmG;AACnG,kDAAqC;AACrC,6DAWmC;AACnC,6CAAsD;AA0V7C,uGA1VA,oCAAsB,OA0VA;AA3U/B,IAAM,eAAe,GAA4C,UAAC,MAAM;IAChE,IAAA,KAWF,MAAM,IAAI,EAAE,EAVd,iBAAyB,EAAzB,SAAS,mBAAG,aAAa,KAAA,EACzB,yBAAoC,EAApC,iBAAiB,mBAAG,gBAAgB,KAAA,EACpC,mCAAmD,EAAnD,2BAA2B,mBAAG,qBAAqB,KAAA,EACnD,+BAAiC,EAAjC,uBAAuB,mBAAG,OAAO,KAAA,EACjC,0BAA4B,EAA5B,kBAAkB,mBAAG,OAAO,KAAA,EAC5B,qBAAsB,EAAtB,aAAa,mBAAG,MAAM,KAAA,EACtB,yBAA0B,EAA1B,iBAAiB,mBAAG,MAAM,KAAA,EAC1B,oBAAoB,EAApB,YAAY,mBAAG,KAAK,KAAA,EACpB,oBAAoB,0BAAA,EACpB,4BAA4B,EAA5B,oBAAoB,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,EAAE,SAAS;oBACf,QAAQ,EAAE,yBAAQ,CAAC,GAAG;oBACtB,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC;oBAC1B,SAAS,EAAE,EAAE;iBACd,CAAC,CAAA;aACH;YAED,sBAAO,SAAS,EAAA;;SACjB,CAAA;IAED,OAAO,SAAS,CAAA;AAClB,CAAC,CAAA;AAEgC,0CAAe;AAEhD,kBAAe,eAAe,EAAE,CAAA;AAEhC,IAAM,wBAAwB,GAAG,UAAC,MAA4B;IAC5D,OAAO,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC;SACvB,GAAG,CAAC,UAAC,QAAQ;QACZ,OAAO,UAAG,QAAQ,eAAM,MAAM,CAAC,QAAQ,CAA0B,CAAC,OAAO,CAAC,EAAE,CAAE,CAAA;IAChF,CAAC,CAAC;SACD,IAAI,CAAC,IAAI,CAAC,CAAA;AACf,CAAC,CAAA;AAED,IAAM,YAAY,GAAG,UAAC,OAAgB,EAAE,QAAgB,EAAE,aAAqB;IAC7E,OAAO,OAAO;QACZ,CAAC,CAAC,6BAAW,CAAC,mBAAmB,CAAC,UAAG,QAAQ,cAAI,aAAa,CAAE,CAAC;QACjE,CAAC,CAAC,6BAAW,CAAC,mBAAmB,CAAC,aAAa,CAAC,CAAA;AACpD,CAAC,CAAA"}
|
package/dist/cjs/style-sheet.js
CHANGED
|
@@ -39,9 +39,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
39
39
|
exports.createStyleSheetPlugin = void 0;
|
|
40
40
|
var teleport_plugin_common_1 = require("@teleporthq/teleport-plugin-common");
|
|
41
41
|
var teleport_types_1 = require("@teleporthq/teleport-types");
|
|
42
|
-
var teleport_shared_1 = require("@teleporthq/teleport-shared");
|
|
43
42
|
var createStyleSheetPlugin = function (config) {
|
|
44
|
-
var
|
|
43
|
+
var fileName = (config || { fileName: 'style' }).fileName;
|
|
45
44
|
var styleSheetPlugin = function (structure) { return __awaiter(void 0, void 0, void 0, function () {
|
|
46
45
|
var uidl, chunks, _a, styleSetDefinitions, _b, _c, _d, tokens, cssMap, mediaStylesMap;
|
|
47
46
|
return __generator(this, function (_e) {
|
|
@@ -57,7 +56,7 @@ var createStyleSheetPlugin = function (config) {
|
|
|
57
56
|
cssMap.push(teleport_plugin_common_1.StyleBuilders.createCSSClassWithSelector('@global', ':root', teleport_plugin_common_1.StyleUtils.getTokensContentFromTokensObject(tokens)));
|
|
58
57
|
}
|
|
59
58
|
if (Object.keys(styleSetDefinitions).length > 0) {
|
|
60
|
-
teleport_plugin_common_1.StyleBuilders.generateStylesFromStyleSetDefinitions(styleSetDefinitions, cssMap, mediaStylesMap,
|
|
59
|
+
teleport_plugin_common_1.StyleBuilders.generateStylesFromStyleSetDefinitions(styleSetDefinitions, cssMap, mediaStylesMap, function (styleName) { return styleName; });
|
|
61
60
|
}
|
|
62
61
|
cssMap.push.apply(cssMap, teleport_plugin_common_1.StyleBuilders.generateMediaStyle(mediaStylesMap));
|
|
63
62
|
if (cssMap.length === 0) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"style-sheet.js","sourceRoot":"","sources":["../../src/style-sheet.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6EAA8E;AAC9E,6DAKmC;
|
|
1
|
+
{"version":3,"file":"style-sheet.js","sourceRoot":"","sources":["../../src/style-sheet.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6EAA8E;AAC9E,6DAKmC;AAM5B,IAAM,sBAAsB,GAA6C,UAAC,MAAM;IAC7E,IAAA,QAAQ,GAAK,CAAA,MAAM,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,CAAA,SAApC,CAAoC;IACpD,IAAM,gBAAgB,GAAoB,UAAO,SAAS;;;YAChD,IAAI,GAAa,SAAS,KAAtB,EAAE,MAAM,GAAK,SAAS,OAAd,CAAc;YAC1B,KAAmE,IAAI,oBA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AS,CAAC,MAAM;gBACtB,QAAQ,EAAE,yBAAQ,CAAC,GAAG;gBACtB,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC;gBAC1B,SAAS,EAAE,EAAE;aACd,CAAC,CAAA;YAEF,sBAAO,SAAS,EAAA;;SACjB,CAAA;IACD,OAAO,gBAAgB,CAAA;AACzB,CAAC,CAAA;AA1DY,QAAA,sBAAsB,0BA0DlC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"program":{"fileNames":["../../../../node_modules/typescript/lib/lib.es5.d.ts","../../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../../node_modules/typescript/lib/lib.dom.d.ts","../../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../../../teleport-types/dist/cjs/uidl.d.ts","../../../teleport-types/dist/cjs/generators.d.ts","../../../teleport-types/dist/cjs/errors.d.ts","../../../teleport-types/dist/cjs/vuidl.d.ts","../../../teleport-types/dist/cjs/index.d.ts","../../../teleport-shared/dist/cjs/constants/index.d.ts","../../../teleport-shared/dist/cjs/utils/string-utils.d.ts","../../../teleport-shared/dist/cjs/utils/uidl-utils.d.ts","../../../teleport-shared/dist/cjs/index.d.ts","../../../../node_modules/@babel/types/lib/index.d.ts","../../../teleport-plugin-common/dist/cjs/builders/ast-builders.d.ts","../../../teleport-plugin-common/dist/cjs/utils/parsed-ast.d.ts","../../../teleport-plugin-common/dist/cjs/builders/style-builders.d.ts","../../../teleport-plugin-common/dist/cjs/builders/hast-builders.d.ts","../../../teleport-plugin-common/dist/cjs/utils/ast-utils.d.ts","../../../teleport-plugin-common/dist/cjs/utils/style-utils.d.ts","../../../teleport-plugin-common/dist/cjs/utils/hast-utils.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-html/types.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-html/index.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-jsx/types.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-jsx/index.d.ts","../../../teleport-plugin-common/dist/cjs/index.d.ts","../../src/style-sheet.ts","../../src/index.ts","../../../../node_modules/@types/node/assert/strict.d.ts","../../../../node_modules/@types/node/globals.d.ts","../../../../node_modules/@types/node/async_hooks.d.ts","../../../../node_modules/@types/node/buffer.d.ts","../../../../node_modules/@types/node/child_process.d.ts","../../../../node_modules/@types/node/cluster.d.ts","../../../../node_modules/@types/node/console.d.ts","../../../../node_modules/@types/node/constants.d.ts","../../../../node_modules/@types/node/crypto.d.ts","../../../../node_modules/@types/node/dgram.d.ts","../../../../node_modules/@types/node/diagnostic_channel.d.ts","../../../../node_modules/@types/node/dns.d.ts","../../../../node_modules/@types/node/dns/promises.d.ts","../../../../node_modules/@types/node/domain.d.ts","../../../../node_modules/@types/node/events.d.ts","../../../../node_modules/@types/node/fs.d.ts","../../../../node_modules/@types/node/fs/promises.d.ts","../../../../node_modules/@types/node/http.d.ts","../../../../node_modules/@types/node/http2.d.ts","../../../../node_modules/@types/node/https.d.ts","../../../../node_modules/@types/node/inspector.d.ts","../../../../node_modules/@types/node/module.d.ts","../../../../node_modules/@types/node/net.d.ts","../../../../node_modules/@types/node/os.d.ts","../../../../node_modules/@types/node/path.d.ts","../../../../node_modules/@types/node/perf_hooks.d.ts","../../../../node_modules/@types/node/process.d.ts","../../../../node_modules/@types/node/punycode.d.ts","../../../../node_modules/@types/node/querystring.d.ts","../../../../node_modules/@types/node/readline.d.ts","../../../../node_modules/@types/node/repl.d.ts","../../../../node_modules/@types/node/stream.d.ts","../../../../node_modules/@types/node/stream/promises.d.ts","../../../../node_modules/@types/node/string_decoder.d.ts","../../../../node_modules/@types/node/timers.d.ts","../../../../node_modules/@types/node/timers/promises.d.ts","../../../../node_modules/@types/node/tls.d.ts","../../../../node_modules/@types/node/trace_events.d.ts","../../../../node_modules/@types/node/tty.d.ts","../../../../node_modules/@types/node/url.d.ts","../../../../node_modules/@types/node/util.d.ts","../../../../node_modules/@types/node/util/types.d.ts","../../../../node_modules/@types/node/v8.d.ts","../../../../node_modules/@types/node/vm.d.ts","../../../../node_modules/@types/node/worker_threads.d.ts","../../../../node_modules/@types/node/zlib.d.ts","../../../../node_modules/@types/node/globals.global.d.ts","../../../../node_modules/@types/node/wasi.d.ts","../../../../node_modules/@types/node/ts3.6/base.d.ts","../../../../node_modules/@types/node/assert.d.ts","../../../../node_modules/@types/node/base.d.ts","../../../../node_modules/@types/node/index.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/cleanupSemantic.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/types.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/diffLines.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/printDiffs.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/index.d.ts","../../../../node_modules/@types/jest/node_modules/pretty-format/build/types.d.ts","../../../../node_modules/@types/jest/node_modules/pretty-format/build/index.d.ts","../../../../node_modules/@types/jest/index.d.ts","../../../../node_modules/@types/jest/ts3.2/index.d.ts"],"fileInfos":[{"version":"3ac1b83264055b28c0165688fda6dfcc39001e9e7828f649299101c23ad0a0c3","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06",{"version":"72704b10d97777e15f1a581b73f88273037ef752d2e50b72287bd0a90af64fe6","affectsGlobalScope":true},{"version":"d8996609230d17e90484a2dd58f22668f9a05a3bfe00bfb1d6271171e54a31fb","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"c5c05907c02476e4bde6b7e76a79ffcd948aedd14b6a8f56e4674221b0417398","affectsGlobalScope":true},{"version":"0d5f52b3174bee6edb81260ebcd792692c32c81fd55499d69531496f3f2b25e7","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"75ec0bdd727d887f1b79ed6619412ea72ba3c81d92d0787ccb64bab18d261f14","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"1b3fe904465430e030c93239a348f05e1be80640d91f2f004c3512c2c2c89f34","affectsGlobalScope":true},{"version":"10bbdc1981b8d9310ee75bfac28ee0477bb2353e8529da8cff7cb26c409cb5e8","affectsGlobalScope":true},"42bf51402b690782aa9e6e437a2fb56a4de94c6f53fbb1728acff2dfd12df74a","18d176af12d389165c4ce64a4f3c365448f1a1beaccbef9a05793992160c89f4","d49a625c30294f92976c954fffb2bcc2faeb81957148a363969ee742a43e2913","c4a042f3df0f5855fbd2ba352d7b0a581a478737b60f306fbb253dceaaa981d2","cd619820771edb23926bb084906215ab9c491255fa707488d15748b38909b747","28b22326000119f53de35f67ce3096ef475a2224274162b1283ef8718e1efdb5","18aecf77d74ed15ae1e875a0d43f2aa85387794fc447b2bc3c8ab7e2224d0ac6","0dab32de48eb8cf6149f776ef25cae2e68580fb8a55419dba27f022381fdd87a","d2ff55204dd4868d11a163c207d4fbe8d99cbf8cb36fa90d2a2f0bfc802b4d38","2ff9995137f3e5d68971388ec58af0c79721626323884513f9f5e2e996ac1fdd","b0900ff47d065c568038fc21d06685e58b7932750f22c49bb5cc4c18bdd35aa3","634d90459c22c0d82376bd48246b99b4a33fe56bc94c15874d1dac1e8a577d75","f735cc9f46bef33ef3c3e45308fbe6e5c9c1b917d6724d989c046bed3db5c3ed","cb33f5a5c73598b92f9aa13a0cf4d0df2dc38f05da11e4ad2fd8f0a735b3b09e","cd7c7f7b87c5e6ddb24a061393d5df9dbb0a926f3499e6f1a7f3d1da0ced3fcb","cf4ba36b05e7a6194696ffcace1710d29bb681b77a20b9b09460707ea3fcecd5","79fb51af7dc378dfaa66da7791d2c91560a151fa74da9f466d9fb60f5f9ccb39","c84d0840044a735055b7911998976dab071cde1ee160f551f2d845aea5630e2e","3465b9608c725b6a4c35b154f636011da24525a137d73976f1222c624cd9ce40","3594cd8018f215116e41c6f05c6fc9e6845a60c74753cdd1a9521d52f9ac0f2a","50ffd0c3b71cdca0f2c5004b39d876a494648c953079f07d257d679a7b95d40a","0772ec3b64f51bbe952d514e28b9aa3355a5322d1c242d93b3e67292dc7bae7c","0f4ea9054b0e97f125c66e5cf4f97ec9aebc2ac76d8b333c62247310e4a4fb26","169bc0f9735d02878beeee9f64066dceef4b1b0eb5ebee88202532b0dd948f4e","c7bdc99177a2a94d25fb13722adaaf5b3291bf70b4d1b27584ba189dd3889ba3",{"version":"d1c92b66c4105659fcad4eb76a1481f7311033e117d0678a1ec545e8ddb8d4c6","affectsGlobalScope":true},"e23424b97418eca3226fd24de079f1203eb70360622e4e093af2aff14d4be6ec","dee93c07b4df5e26010dc9ec4cdf4d6e4076bb4474d2a8371529217c8b2740a4","ed40f2f184db052dc8df62d1f199823c8bbccc487c0a2a7c54eeea0badcf4378","04eaa93bd75f937f9184dcb95a7983800c5770cf8ddd8ac0f3734dc02f5b20ef",{"version":"c8155caf28fc7b0a564156a5df28ad8a844a3bd32d331d148d8f3ce88025c870","affectsGlobalScope":true},"45ac321f2e15d268fd74a90ddaa6467dcaaff2c5b13f95b4b85831520fb7a491","dfc747ab8dd5f623055a4c26fd35e8cceca869fd3f1cf09701c941ca3679665a","c9f5f2920ff61d7158417b8440d5181ddc34a3dfef811a5677dd8a9fb91471e9","5cc0a492da3602510b8f5ed1852b1e0390002780d8758fbc8c0cd023ca7085f8","ec7dafafe751a5121f8f1c80201ebe7e7238c47e6329280a73c4d1ca4bb7fa28","64debeb10e4b7ae4ec9e89bfb4e04c6101ab98c3cc806d14e5488607cfec2753",{"version":"2866a528b2708aa272ec3eaafd3c980abb23aec1ef831cfc5eb2186b98c37ce5","affectsGlobalScope":true},{"version":"a5782d6cea81fe43d2db7ed41e789458c933ab3ab60602f7b5b14c4da3370496","affectsGlobalScope":true},"f258ba66915f0196ec344bc53afe1888240bbcc855ebd151b6cc072275533319","6194335ee3353f7226ba31f31d6301d0c6be87228419c0a08976ccd9d4f1213e","3ac12a54cfaa84683506db8d4cf779135a271d9f0ec18930cf53e61fbeea0c5d","cf3d3b087d1a8a3355eec47d206162c75e912315b9b5c1cd49fda93e948fb80a","36f316c066c4a72dd6f19fec49a074f935744fc9ccbe75c87ebc07fb2feb9062","42176966283d3835c34278b9b5c0f470d484c0c0c6a55c20a2c916a1ce69b6e8","0cff7901aedfe78e314f7d44088f07e2afa1b6e4f0473a4169b8456ca2fb245d","ec70fd6f8a9a83f850dab2960a6789e93d5b034b354a16814cad5daabf62a360","e2236264a811ed1d09a2487a433e8f5216ae62378cf233954ae220cf886f6717","3ec1e108d587a5661ec790db607f482605ba9f3830e118ce578e3ffa3c42e22b","100b3bb9d39d2b1b5340f1bf45a52e94ef1692b45232b4ba00fac5c3cc56d331",{"version":"04fe7e7d8008887943260af1fde2bfd4877e0dc57bf634e0f0b2f3d1794dfd11","affectsGlobalScope":true},"7f77304372efe3c9967e5f9ea2061f1b4bf41dc3cda3c83cdd676f2e5af6b7e6","992c6f6be16c0a1d2eec13ece33adeea2c747ba27fcd078353a8f4bb5b4fea58","2597718d91e306949d89e285bf34c44192014ef541c3bd7cbb825c022749e974","a6b0abdb67d63ebe964ba5fee31bc3daf10c12eecd46b24d778426010c04c67e","ac4801ebc2355ba32329070123b1cd15891bf71b41dcaf9e75b4744832126a59","fd2298fba0640e7295e7bd545e2dfbfcccbb00c27019e501c87965a02bbdebf6","4fd3c4debadce3e9ab9dec3eb45f7f5e2e3d4ad65cf975a6d938d883cfb25a50","71ddd49185b68f27bfac127ef5d22cb2672c278e53e5370d9020ef50ca9c377d","b1ea7a6eaa7608e0e0529aebd323b526a79c6c05a4e519ae5c779675004dcdf1","9fcb033a6208485d8f3fadde31eb5cbcaf99149cff3e40c0dc53ebc6d0dff4e9","7df562288f949945cf69c21cd912100c2afedeeb7cdb219085f7f4b46cb7dde4","9d16690485ff1eb4f6fc57aebe237728fd8e03130c460919da3a35f4d9bd97f5","dcc6910d95a3625fd2b0487fda055988e46ab46c357a1b3618c27b4a8dd739c9","f4149f1aa299474c7040a35fe8f8ac2ad078cc1b190415adc1fff3ed52d490ea","3730099ed008776216268a97771de31753ef71e0a7d0ec650f588cba2a06ce44","8d649dbc429d7139a1d9a14ea2bf8af1dc089e0a879447539587463d4b6c248c","60c9e27816ec8ac8df7240598bb086e95b47edfb454c5cbf4003c812e0ed6e39","e361aecf17fc4034b4c122a1564471cdcd22ef3a51407803cb5a5fc020c04d02","4926467de88a92a4fc9971d8c6f21b91eca1c0e7fc2a46cc4638ab9440c73875",{"version":"2708349d5a11a5c2e5f3a0765259ebe7ee00cdcc8161cb9990cb4910328442a1","affectsGlobalScope":true},"fc0ae4a8ad3c762b96f9d2c3700cb879a373458cb0bf3175478e3b4f85f7ef2f","fabbec378e1ddd86fcf2662e716c2b8318acedb664ee3a4cba6f9e8ee8269cf1","b3593bd345ebea5e4d0a894c03251a3774b34df3d6db57075c18e089a599ba76","e61a21e9418f279bc480394a94d1581b2dee73747adcbdef999b6737e34d721b","efd55e8ca79171bf26c0d0e30221cb8ee1f5a31dd0c791ec4b2e886f42bab124","e222104af6cb9415238ad358488b74d76eceeff238c1268ec6e85655b05341da","69da61a7b5093dac77fa3bec8be95dcf9a74c95a0e9161edb98bb24e30e439d2","eba230221317c985ab1953ccc3edc517f248b37db4fef7875cb2c8d08aff7be7","b83e796810e475da3564c6515bc0ae9577070596a33d89299b7d99f94ecfd921","b4439890c168d646357928431100daac5cbdee1d345a34e6bf6eca9f3abe22bc","5d72971a459517c44c1379dab9ed248e87a61ba0a1e0f25c9d67e1e640cd9a09","02d734976af36f4273d930bea88b3e62adf6b078cf120c1c63d49aa8d8427c5c",{"version":"f624e578325b8c58e55b30c998b1f4c3ec1b61a9fa66373da4250c89b7880d44","affectsGlobalScope":true},{"version":"d3002f620eab4bf6476c9da5c0efb2041d46f7df8b3032a5631bd206abef2c75","affectsGlobalScope":true}],"options":{"allowSyntheticDefaultImports":true,"declaration":true,"emitDecoratorMetadata":true,"esModuleInterop":true,"experimentalDecorators":true,"module":1,"noImplicitAny":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","sourceMap":true,"target":1},"fileIdsList":[[109,111],[105,106],[105,106,107,108],[110],[112],[102],[101,102],[56,61],[67,68,75,84],[57,67,75],[93],[61,68,76],[84,89],[64,67,75],[65],[64],[67],[67,69,84,92],[67,68,84],[75,84,92],[67,68,70,75,84,89,92],[70,84,89,92],[103],[92],[64,67,84],[77],[55],[91],[82,93,96],[67,85],[84],[87],[61,75],[53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100],[75],[81],[94],[56,61,67,69,78,84,92,96],[33,38],[33],[33,38,40],[39,40,41,42,43,44,45,46,47,48,49],[33,46],[33,38,48],[33,37,38,50,51],[33,37,50],[34,35,36],[29],[29,30,31,32]],"referencedMap":[[112,1],[107,2],[109,3],[108,2],[111,4],[113,5],[53,6],[103,7],[56,8],[57,9],[58,10],[59,11],[60,12],[61,13],[62,14],[64,15],[65,16],[66,17],[67,17],[68,18],[69,19],[70,20],[71,21],[72,22],[104,23],[73,17],[74,24],[75,25],[77,26],[78,27],[79,28],[82,17],[83,29],[84,30],[85,31],[87,17],[88,32],[89,33],[101,34],[91,35],[92,36],[93,37],[95,31],[97,38],[98,31],[39,39],[42,40],[41,41],[50,42],[47,43],[46,40],[49,44],[48,39],[43,41],[45,40],[44,40],[52,45],[51,46],[34,40],[37,47],[36,40],[30,48],[33,49],[32,48]],"exportedModulesMap":[[112,1],[107,2],[109,3],[108,2],[111,4],[113,5],[53,6],[103,7],[56,8],[57,9],[58,10],[59,11],[60,12],[61,13],[62,14],[64,15],[65,16],[66,17],[67,17],[68,18],[69,19],[70,20],[71,21],[72,22],[104,23],[73,17],[74,24],[75,25],[77,26],[78,27],[79,28],[82,17],[83,29],[84,30],[85,31],[87,17],[88,32],[89,33],[101,34],[91,35],[92,36],[93,37],[95,31],[97,38],[98,31],[39,39],[42,40],[41,41],[50,42],[47,43],[46,40],[49,44],[48,39],[43,41],[45,40],[44,40],[52,45],[51,46],[34,40],[37,47],[36,40],[30,48],[33,49],[32,48]],"semanticDiagnosticsPerFile":[38,112,105,107,109,108,106,111,110,113,102,53,55,103,56,57,58,59,60,61,62,63,64,65,66,67,68,69,54,99,70,71,72,104,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,101,91,92,93,94,95,96,100,97,98,6,8,7,2,9,10,11,12,13,14,15,16,3,4,20,17,18,19,21,22,23,5,24,25,26,27,1,28,39,42,41,50,47,46,49,48,43,45,40,44,52,51,34,37,35,36,31,30,33,29,32]},"version":"4.6.2"}
|
|
1
|
+
{"program":{"fileNames":["../../../../node_modules/typescript/lib/lib.es5.d.ts","../../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../../node_modules/typescript/lib/lib.dom.d.ts","../../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../../../teleport-types/dist/cjs/uidl.d.ts","../../../teleport-types/dist/cjs/generators.d.ts","../../../teleport-types/dist/cjs/errors.d.ts","../../../teleport-types/dist/cjs/vuidl.d.ts","../../../teleport-types/dist/cjs/index.d.ts","../../../teleport-shared/dist/cjs/constants/index.d.ts","../../../teleport-shared/dist/cjs/utils/string-utils.d.ts","../../../teleport-shared/dist/cjs/utils/uidl-utils.d.ts","../../../teleport-shared/dist/cjs/index.d.ts","../../../../node_modules/@babel/types/lib/index.d.ts","../../../teleport-plugin-common/dist/cjs/builders/ast-builders.d.ts","../../../teleport-plugin-common/dist/cjs/utils/parsed-ast.d.ts","../../../teleport-plugin-common/dist/cjs/builders/style-builders.d.ts","../../../teleport-plugin-common/dist/cjs/builders/hast-builders.d.ts","../../../teleport-plugin-common/dist/cjs/utils/ast-utils.d.ts","../../../teleport-plugin-common/dist/cjs/utils/style-utils.d.ts","../../../teleport-plugin-common/dist/cjs/utils/hast-utils.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-html/types.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-html/index.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-jsx/types.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-jsx/index.d.ts","../../../teleport-plugin-common/dist/cjs/index.d.ts","../../src/style-sheet.ts","../../src/index.ts","../../../../node_modules/@types/node/assert/strict.d.ts","../../../../node_modules/@types/node/globals.d.ts","../../../../node_modules/@types/node/async_hooks.d.ts","../../../../node_modules/@types/node/buffer.d.ts","../../../../node_modules/@types/node/child_process.d.ts","../../../../node_modules/@types/node/cluster.d.ts","../../../../node_modules/@types/node/console.d.ts","../../../../node_modules/@types/node/constants.d.ts","../../../../node_modules/@types/node/crypto.d.ts","../../../../node_modules/@types/node/dgram.d.ts","../../../../node_modules/@types/node/diagnostic_channel.d.ts","../../../../node_modules/@types/node/dns.d.ts","../../../../node_modules/@types/node/dns/promises.d.ts","../../../../node_modules/@types/node/domain.d.ts","../../../../node_modules/@types/node/events.d.ts","../../../../node_modules/@types/node/fs.d.ts","../../../../node_modules/@types/node/fs/promises.d.ts","../../../../node_modules/@types/node/http.d.ts","../../../../node_modules/@types/node/http2.d.ts","../../../../node_modules/@types/node/https.d.ts","../../../../node_modules/@types/node/inspector.d.ts","../../../../node_modules/@types/node/module.d.ts","../../../../node_modules/@types/node/net.d.ts","../../../../node_modules/@types/node/os.d.ts","../../../../node_modules/@types/node/path.d.ts","../../../../node_modules/@types/node/perf_hooks.d.ts","../../../../node_modules/@types/node/process.d.ts","../../../../node_modules/@types/node/punycode.d.ts","../../../../node_modules/@types/node/querystring.d.ts","../../../../node_modules/@types/node/readline.d.ts","../../../../node_modules/@types/node/repl.d.ts","../../../../node_modules/@types/node/stream.d.ts","../../../../node_modules/@types/node/stream/promises.d.ts","../../../../node_modules/@types/node/string_decoder.d.ts","../../../../node_modules/@types/node/timers.d.ts","../../../../node_modules/@types/node/timers/promises.d.ts","../../../../node_modules/@types/node/tls.d.ts","../../../../node_modules/@types/node/trace_events.d.ts","../../../../node_modules/@types/node/tty.d.ts","../../../../node_modules/@types/node/url.d.ts","../../../../node_modules/@types/node/util.d.ts","../../../../node_modules/@types/node/util/types.d.ts","../../../../node_modules/@types/node/v8.d.ts","../../../../node_modules/@types/node/vm.d.ts","../../../../node_modules/@types/node/worker_threads.d.ts","../../../../node_modules/@types/node/zlib.d.ts","../../../../node_modules/@types/node/globals.global.d.ts","../../../../node_modules/@types/node/wasi.d.ts","../../../../node_modules/@types/node/ts3.6/base.d.ts","../../../../node_modules/@types/node/assert.d.ts","../../../../node_modules/@types/node/base.d.ts","../../../../node_modules/@types/node/index.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/cleanupSemantic.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/types.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/diffLines.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/printDiffs.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/index.d.ts","../../../../node_modules/@types/jest/node_modules/pretty-format/build/types.d.ts","../../../../node_modules/@types/jest/node_modules/pretty-format/build/index.d.ts","../../../../node_modules/@types/jest/index.d.ts","../../../../node_modules/@types/jest/ts3.2/index.d.ts"],"fileInfos":[{"version":"3ac1b83264055b28c0165688fda6dfcc39001e9e7828f649299101c23ad0a0c3","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06",{"version":"72704b10d97777e15f1a581b73f88273037ef752d2e50b72287bd0a90af64fe6","affectsGlobalScope":true},{"version":"d8996609230d17e90484a2dd58f22668f9a05a3bfe00bfb1d6271171e54a31fb","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"c5c05907c02476e4bde6b7e76a79ffcd948aedd14b6a8f56e4674221b0417398","affectsGlobalScope":true},{"version":"0d5f52b3174bee6edb81260ebcd792692c32c81fd55499d69531496f3f2b25e7","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"75ec0bdd727d887f1b79ed6619412ea72ba3c81d92d0787ccb64bab18d261f14","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"1b3fe904465430e030c93239a348f05e1be80640d91f2f004c3512c2c2c89f34","affectsGlobalScope":true},{"version":"10bbdc1981b8d9310ee75bfac28ee0477bb2353e8529da8cff7cb26c409cb5e8","affectsGlobalScope":true},"d58cb8e3308641cdc84644105bd3d594045b356af29fd10d5a74f42c1a8396ad","18d176af12d389165c4ce64a4f3c365448f1a1beaccbef9a05793992160c89f4","d49a625c30294f92976c954fffb2bcc2faeb81957148a363969ee742a43e2913","c4a042f3df0f5855fbd2ba352d7b0a581a478737b60f306fbb253dceaaa981d2","cd619820771edb23926bb084906215ab9c491255fa707488d15748b38909b747","28b22326000119f53de35f67ce3096ef475a2224274162b1283ef8718e1efdb5","18aecf77d74ed15ae1e875a0d43f2aa85387794fc447b2bc3c8ab7e2224d0ac6","0dab32de48eb8cf6149f776ef25cae2e68580fb8a55419dba27f022381fdd87a","d2ff55204dd4868d11a163c207d4fbe8d99cbf8cb36fa90d2a2f0bfc802b4d38","2ff9995137f3e5d68971388ec58af0c79721626323884513f9f5e2e996ac1fdd","b0900ff47d065c568038fc21d06685e58b7932750f22c49bb5cc4c18bdd35aa3","634d90459c22c0d82376bd48246b99b4a33fe56bc94c15874d1dac1e8a577d75","b179b68aed28f107ab90bc0b15cecee4388c612203e5b848df805c8dae3e3071","cb33f5a5c73598b92f9aa13a0cf4d0df2dc38f05da11e4ad2fd8f0a735b3b09e","cd7c7f7b87c5e6ddb24a061393d5df9dbb0a926f3499e6f1a7f3d1da0ced3fcb","cf4ba36b05e7a6194696ffcace1710d29bb681b77a20b9b09460707ea3fcecd5","79fb51af7dc378dfaa66da7791d2c91560a151fa74da9f466d9fb60f5f9ccb39","c84d0840044a735055b7911998976dab071cde1ee160f551f2d845aea5630e2e","3465b9608c725b6a4c35b154f636011da24525a137d73976f1222c624cd9ce40","3594cd8018f215116e41c6f05c6fc9e6845a60c74753cdd1a9521d52f9ac0f2a","50ffd0c3b71cdca0f2c5004b39d876a494648c953079f07d257d679a7b95d40a","0772ec3b64f51bbe952d514e28b9aa3355a5322d1c242d93b3e67292dc7bae7c","9e8ea4d6289073492eb213e308241228e2419402d138abad4a38a57c39c22806","4e0767065599bee38275285a73e6be0b2b09efc920547c08e45dc8a94bc7b7a4","c7bdc99177a2a94d25fb13722adaaf5b3291bf70b4d1b27584ba189dd3889ba3",{"version":"d1c92b66c4105659fcad4eb76a1481f7311033e117d0678a1ec545e8ddb8d4c6","affectsGlobalScope":true},"e23424b97418eca3226fd24de079f1203eb70360622e4e093af2aff14d4be6ec","dee93c07b4df5e26010dc9ec4cdf4d6e4076bb4474d2a8371529217c8b2740a4","ed40f2f184db052dc8df62d1f199823c8bbccc487c0a2a7c54eeea0badcf4378","04eaa93bd75f937f9184dcb95a7983800c5770cf8ddd8ac0f3734dc02f5b20ef",{"version":"c8155caf28fc7b0a564156a5df28ad8a844a3bd32d331d148d8f3ce88025c870","affectsGlobalScope":true},"45ac321f2e15d268fd74a90ddaa6467dcaaff2c5b13f95b4b85831520fb7a491","dfc747ab8dd5f623055a4c26fd35e8cceca869fd3f1cf09701c941ca3679665a","c9f5f2920ff61d7158417b8440d5181ddc34a3dfef811a5677dd8a9fb91471e9","5cc0a492da3602510b8f5ed1852b1e0390002780d8758fbc8c0cd023ca7085f8","ec7dafafe751a5121f8f1c80201ebe7e7238c47e6329280a73c4d1ca4bb7fa28","64debeb10e4b7ae4ec9e89bfb4e04c6101ab98c3cc806d14e5488607cfec2753",{"version":"2866a528b2708aa272ec3eaafd3c980abb23aec1ef831cfc5eb2186b98c37ce5","affectsGlobalScope":true},{"version":"a5782d6cea81fe43d2db7ed41e789458c933ab3ab60602f7b5b14c4da3370496","affectsGlobalScope":true},"f258ba66915f0196ec344bc53afe1888240bbcc855ebd151b6cc072275533319","6194335ee3353f7226ba31f31d6301d0c6be87228419c0a08976ccd9d4f1213e","3ac12a54cfaa84683506db8d4cf779135a271d9f0ec18930cf53e61fbeea0c5d","cf3d3b087d1a8a3355eec47d206162c75e912315b9b5c1cd49fda93e948fb80a","36f316c066c4a72dd6f19fec49a074f935744fc9ccbe75c87ebc07fb2feb9062","42176966283d3835c34278b9b5c0f470d484c0c0c6a55c20a2c916a1ce69b6e8","0cff7901aedfe78e314f7d44088f07e2afa1b6e4f0473a4169b8456ca2fb245d","ec70fd6f8a9a83f850dab2960a6789e93d5b034b354a16814cad5daabf62a360","e2236264a811ed1d09a2487a433e8f5216ae62378cf233954ae220cf886f6717","3ec1e108d587a5661ec790db607f482605ba9f3830e118ce578e3ffa3c42e22b","100b3bb9d39d2b1b5340f1bf45a52e94ef1692b45232b4ba00fac5c3cc56d331",{"version":"04fe7e7d8008887943260af1fde2bfd4877e0dc57bf634e0f0b2f3d1794dfd11","affectsGlobalScope":true},"7f77304372efe3c9967e5f9ea2061f1b4bf41dc3cda3c83cdd676f2e5af6b7e6","992c6f6be16c0a1d2eec13ece33adeea2c747ba27fcd078353a8f4bb5b4fea58","2597718d91e306949d89e285bf34c44192014ef541c3bd7cbb825c022749e974","a6b0abdb67d63ebe964ba5fee31bc3daf10c12eecd46b24d778426010c04c67e","ac4801ebc2355ba32329070123b1cd15891bf71b41dcaf9e75b4744832126a59","fd2298fba0640e7295e7bd545e2dfbfcccbb00c27019e501c87965a02bbdebf6","4fd3c4debadce3e9ab9dec3eb45f7f5e2e3d4ad65cf975a6d938d883cfb25a50","71ddd49185b68f27bfac127ef5d22cb2672c278e53e5370d9020ef50ca9c377d","b1ea7a6eaa7608e0e0529aebd323b526a79c6c05a4e519ae5c779675004dcdf1","9fcb033a6208485d8f3fadde31eb5cbcaf99149cff3e40c0dc53ebc6d0dff4e9","7df562288f949945cf69c21cd912100c2afedeeb7cdb219085f7f4b46cb7dde4","9d16690485ff1eb4f6fc57aebe237728fd8e03130c460919da3a35f4d9bd97f5","dcc6910d95a3625fd2b0487fda055988e46ab46c357a1b3618c27b4a8dd739c9","f4149f1aa299474c7040a35fe8f8ac2ad078cc1b190415adc1fff3ed52d490ea","3730099ed008776216268a97771de31753ef71e0a7d0ec650f588cba2a06ce44","8d649dbc429d7139a1d9a14ea2bf8af1dc089e0a879447539587463d4b6c248c","60c9e27816ec8ac8df7240598bb086e95b47edfb454c5cbf4003c812e0ed6e39","e361aecf17fc4034b4c122a1564471cdcd22ef3a51407803cb5a5fc020c04d02","4926467de88a92a4fc9971d8c6f21b91eca1c0e7fc2a46cc4638ab9440c73875",{"version":"2708349d5a11a5c2e5f3a0765259ebe7ee00cdcc8161cb9990cb4910328442a1","affectsGlobalScope":true},"fc0ae4a8ad3c762b96f9d2c3700cb879a373458cb0bf3175478e3b4f85f7ef2f","fabbec378e1ddd86fcf2662e716c2b8318acedb664ee3a4cba6f9e8ee8269cf1","b3593bd345ebea5e4d0a894c03251a3774b34df3d6db57075c18e089a599ba76","e61a21e9418f279bc480394a94d1581b2dee73747adcbdef999b6737e34d721b","efd55e8ca79171bf26c0d0e30221cb8ee1f5a31dd0c791ec4b2e886f42bab124","e222104af6cb9415238ad358488b74d76eceeff238c1268ec6e85655b05341da","69da61a7b5093dac77fa3bec8be95dcf9a74c95a0e9161edb98bb24e30e439d2","eba230221317c985ab1953ccc3edc517f248b37db4fef7875cb2c8d08aff7be7","b83e796810e475da3564c6515bc0ae9577070596a33d89299b7d99f94ecfd921","b4439890c168d646357928431100daac5cbdee1d345a34e6bf6eca9f3abe22bc","5d72971a459517c44c1379dab9ed248e87a61ba0a1e0f25c9d67e1e640cd9a09","02d734976af36f4273d930bea88b3e62adf6b078cf120c1c63d49aa8d8427c5c",{"version":"f624e578325b8c58e55b30c998b1f4c3ec1b61a9fa66373da4250c89b7880d44","affectsGlobalScope":true},{"version":"d3002f620eab4bf6476c9da5c0efb2041d46f7df8b3032a5631bd206abef2c75","affectsGlobalScope":true}],"options":{"allowSyntheticDefaultImports":true,"declaration":true,"emitDecoratorMetadata":true,"esModuleInterop":true,"experimentalDecorators":true,"module":1,"noImplicitAny":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","sourceMap":true,"target":1},"fileIdsList":[[109,111],[105,106],[105,106,107,108],[110],[112],[102],[101,102],[56,61],[67,68,75,84],[57,67,75],[93],[61,68,76],[84,89],[64,67,75],[65],[64],[67],[67,69,84,92],[67,68,84],[75,84,92],[67,68,70,75,84,89,92],[70,84,89,92],[103],[92],[64,67,84],[77],[55],[91],[82,93,96],[67,85],[84],[87],[61,75],[53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100],[75],[81],[94],[56,61,67,69,78,84,92,96],[33,38],[33],[33,38,40],[39,40,41,42,43,44,45,46,47,48,49],[33,46],[33,38,48],[33,37,38,50,51],[33,50],[34,35,36],[29],[29,30,31,32]],"referencedMap":[[112,1],[107,2],[109,3],[108,2],[111,4],[113,5],[53,6],[103,7],[56,8],[57,9],[58,10],[59,11],[60,12],[61,13],[62,14],[64,15],[65,16],[66,17],[67,17],[68,18],[69,19],[70,20],[71,21],[72,22],[104,23],[73,17],[74,24],[75,25],[77,26],[78,27],[79,28],[82,17],[83,29],[84,30],[85,31],[87,17],[88,32],[89,33],[101,34],[91,35],[92,36],[93,37],[95,31],[97,38],[98,31],[39,39],[42,40],[41,41],[50,42],[47,43],[46,40],[49,44],[48,39],[43,41],[45,40],[44,40],[52,45],[51,46],[34,40],[37,47],[36,40],[30,48],[33,49],[32,48]],"exportedModulesMap":[[112,1],[107,2],[109,3],[108,2],[111,4],[113,5],[53,6],[103,7],[56,8],[57,9],[58,10],[59,11],[60,12],[61,13],[62,14],[64,15],[65,16],[66,17],[67,17],[68,18],[69,19],[70,20],[71,21],[72,22],[104,23],[73,17],[74,24],[75,25],[77,26],[78,27],[79,28],[82,17],[83,29],[84,30],[85,31],[87,17],[88,32],[89,33],[101,34],[91,35],[92,36],[93,37],[95,31],[97,38],[98,31],[39,39],[42,40],[41,41],[50,42],[47,43],[46,40],[49,44],[48,39],[43,41],[45,40],[44,40],[52,45],[51,46],[34,40],[37,47],[36,40],[30,48],[33,49],[32,48]],"semanticDiagnosticsPerFile":[38,112,105,107,109,108,106,111,110,113,102,53,55,103,56,57,58,59,60,61,62,63,64,65,66,67,68,69,54,99,70,71,72,104,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,101,91,92,93,94,95,96,100,97,98,6,8,7,2,9,10,11,12,13,14,15,16,3,4,20,17,18,19,21,22,23,5,24,25,26,27,1,28,39,42,41,50,47,46,49,48,43,45,40,44,52,51,34,37,35,36,31,30,33,29,32]},"version":"4.6.2"}
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -10,8 +10,9 @@ interface CSSPluginConfig {
|
|
|
10
10
|
templateStyle: 'html' | 'jsx';
|
|
11
11
|
declareDependency: 'import' | 'decorator' | 'none';
|
|
12
12
|
dynamicVariantPrefix?: string;
|
|
13
|
+
staticPropReferences?: boolean;
|
|
13
14
|
}
|
|
14
|
-
|
|
15
|
-
export { createStyleSheetPlugin };
|
|
15
|
+
declare const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig>;
|
|
16
|
+
export { createStyleSheetPlugin, createCSSPlugin };
|
|
16
17
|
declare const _default: ComponentPlugin;
|
|
17
18
|
export default _default;
|
package/dist/esm/index.js
CHANGED
|
@@ -50,17 +50,15 @@ import { StyleUtils, StyleBuilders, HASTUtils, ASTUtils } from '@teleporthq/tele
|
|
|
50
50
|
import * as types from '@babel/types';
|
|
51
51
|
import { ChunkType, FileType, PluginCSS, } from '@teleporthq/teleport-types';
|
|
52
52
|
import { createStyleSheetPlugin } from './style-sheet';
|
|
53
|
-
|
|
54
|
-
var _a = config || {}, _b = _a.chunkName, chunkName = _b === void 0 ? 'style-chunk' : _b, _c = _a.templateChunkName, templateChunkName = _c === void 0 ? 'template-chunk' : _c, _d = _a.componentDecoratorChunkName, componentDecoratorChunkName = _d === void 0 ? 'component-decorator' : _d, _e = _a.inlineStyleAttributeKey, inlineStyleAttributeKey = _e === void 0 ? 'style' : _e, _f = _a.classAttributeName, classAttributeName = _f === void 0 ? 'class' : _f, _g = _a.templateStyle, templateStyle = _g === void 0 ? 'html' : _g, _h = _a.declareDependency, declareDependency = _h === void 0 ? 'none' : _h, _j = _a.forceScoping, forceScoping = _j === void 0 ? false : _j, dynamicVariantPrefix = _a.dynamicVariantPrefix;
|
|
53
|
+
var createCSSPlugin = function (config) {
|
|
54
|
+
var _a = config || {}, _b = _a.chunkName, chunkName = _b === void 0 ? 'style-chunk' : _b, _c = _a.templateChunkName, templateChunkName = _c === void 0 ? 'template-chunk' : _c, _d = _a.componentDecoratorChunkName, componentDecoratorChunkName = _d === void 0 ? 'component-decorator' : _d, _e = _a.inlineStyleAttributeKey, inlineStyleAttributeKey = _e === void 0 ? 'style' : _e, _f = _a.classAttributeName, classAttributeName = _f === void 0 ? 'class' : _f, _g = _a.templateStyle, templateStyle = _g === void 0 ? 'html' : _g, _h = _a.declareDependency, declareDependency = _h === void 0 ? 'none' : _h, _j = _a.forceScoping, forceScoping = _j === void 0 ? false : _j, dynamicVariantPrefix = _a.dynamicVariantPrefix, _k = _a.staticPropReferences, staticPropReferences = _k === void 0 ? false : _k;
|
|
55
55
|
var cssPlugin = function (structure) { return __awaiter(void 0, void 0, void 0, function () {
|
|
56
|
-
var uidl, chunks, dependencies, options, node, _a, componentStyleSet, _b,
|
|
57
|
-
return __generator(this, function (
|
|
56
|
+
var uidl, chunks, dependencies, options, node, _a, componentStyleSet, _b, propDefinitions, _c, projectStyleSet, _d, _e, _f, tokens, isRootComponent, _g, _h, styleSetDefinitions, projectStyleSheetName, projectStyleSheetPath, templateChunk, componentDecoratorChunk, templateLookup, propsPrefix, cssMap, mediaStylesMap, cssFileName, decoratorAST, decoratorParam;
|
|
57
|
+
return __generator(this, function (_j) {
|
|
58
58
|
uidl = structure.uidl, chunks = structure.chunks, dependencies = structure.dependencies, options = structure.options;
|
|
59
|
-
node = uidl.node, _a = uidl.styleSetDefinitions, componentStyleSet = _a === void 0 ? {} : _a;
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
componentFileName = UIDLUtils.getComponentFileName(uidl) // Filename used to enforce dash case naming
|
|
63
|
-
;
|
|
59
|
+
node = uidl.node, _a = uidl.styleSetDefinitions, componentStyleSet = _a === void 0 ? {} : _a, _b = uidl.propDefinitions, propDefinitions = _b === void 0 ? {} : _b;
|
|
60
|
+
_c = options || {}, projectStyleSet = _c.projectStyleSet, _d = _c.designLanguage, _e = _d === void 0 ? {} : _d, _f = _e.tokens, tokens = _f === void 0 ? {} : _f, isRootComponent = _c.isRootComponent;
|
|
61
|
+
_g = projectStyleSet || {}, _h = _g.styleSetDefinitions, styleSetDefinitions = _h === void 0 ? {} : _h, projectStyleSheetName = _g.fileName, projectStyleSheetPath = _g.path;
|
|
64
62
|
if (isRootComponent) {
|
|
65
63
|
if (Object.keys(tokens).length > 0 || Object.keys(styleSetDefinitions).length > 0) {
|
|
66
64
|
dependencies[projectStyleSheetName] = {
|
|
@@ -86,30 +84,16 @@ export var createCSSPlugin = function (config) {
|
|
|
86
84
|
var classNamesToAppend = new Set();
|
|
87
85
|
var dynamicVariantsToAppend = new Set();
|
|
88
86
|
var _c = element.style, style = _c === void 0 ? {} : _c, key = element.key, _d = element.referencedStyles, referencedStyles = _d === void 0 ? {} : _d, dependency = element.dependency, _e = element.attrs, attrs = _e === void 0 ? {} : _e, elementType = element.elementType;
|
|
87
|
+
var elementClassName = StringUtils.camelCaseToDashCase(key);
|
|
89
88
|
if (forceScoping && (dependency === null || dependency === void 0 ? void 0 : dependency.type) === 'local') {
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
if (((_a = attribute.name) === null || _a === void 0 ? void 0 : _a.name) === attr &&
|
|
99
|
-
((_b = attribute.value) === null || _b === void 0 ? void 0 : _b.value)) {
|
|
100
|
-
;
|
|
101
|
-
attribute.value.value = "".concat(compStyleName_1, "-").concat(StringUtils.camelCaseToDashCase(attribute.value.value));
|
|
102
|
-
}
|
|
103
|
-
});
|
|
104
|
-
}
|
|
105
|
-
if (templateStyle === 'html') {
|
|
106
|
-
var compInstanceNode = templateLookup[key];
|
|
107
|
-
if (!(compInstanceNode === null || compInstanceNode === void 0 ? void 0 : compInstanceNode.properties[attr])) {
|
|
108
|
-
return;
|
|
109
|
-
}
|
|
110
|
-
compInstanceNode.properties[attr] = "".concat(compStyleName_1, "-").concat(StringUtils.camelCaseToDashCase(String(compInstanceNode.properties[attr])));
|
|
111
|
-
}
|
|
112
|
-
}
|
|
89
|
+
StyleBuilders.setPropValueForCompStyle({
|
|
90
|
+
attrs: attrs,
|
|
91
|
+
key: key,
|
|
92
|
+
jsxNodesLookup: templateLookup,
|
|
93
|
+
templateStyle: templateStyle,
|
|
94
|
+
getClassName: function (styleName) {
|
|
95
|
+
return getClassName(forceScoping, StringUtils.camelCaseToDashCase(elementType), styleName);
|
|
96
|
+
},
|
|
113
97
|
});
|
|
114
98
|
}
|
|
115
99
|
if (Object.keys(style).length === 0 &&
|
|
@@ -121,10 +105,7 @@ export var createCSSPlugin = function (config) {
|
|
|
121
105
|
if (!root) {
|
|
122
106
|
throw new PluginCSS("Node - ".concat(key, " is missing from the template chunk"));
|
|
123
107
|
}
|
|
124
|
-
var
|
|
125
|
-
var className = forceScoping // when the framework doesn't provide automating scoping for classNames
|
|
126
|
-
? "".concat(componentFileName, "-").concat(elementClassName)
|
|
127
|
-
: elementClassName;
|
|
108
|
+
var className = getClassName(forceScoping, uidl.name, elementClassName);
|
|
128
109
|
var _f = UIDLUtils.splitDynamicAndStaticStyles(style), staticStyles = _f.staticStyles, dynamicStyles = _f.dynamicStyles, tokenStyles = _f.tokenStyles;
|
|
129
110
|
if (Object.keys(staticStyles).length > 0 || Object.keys(tokenStyles).length > 0) {
|
|
130
111
|
var collectedStyles = __assign(__assign({}, StyleUtils.getContentOfStyleObject(staticStyles)), StyleUtils.getCSSVariablesContentFromTokenStyles(tokenStyles));
|
|
@@ -147,6 +128,7 @@ export var createCSSPlugin = function (config) {
|
|
|
147
128
|
}
|
|
148
129
|
Object.values(referencedStyles).forEach(function (styleRef) {
|
|
149
130
|
var _a;
|
|
131
|
+
var _b;
|
|
150
132
|
switch (styleRef.content.mapType) {
|
|
151
133
|
case 'inlined': {
|
|
152
134
|
var filtredStyles = UIDLUtils.splitDynamicAndStaticStyles(styleRef.content.styles);
|
|
@@ -155,7 +137,10 @@ export var createCSSPlugin = function (config) {
|
|
|
155
137
|
var conditionType = condition.conditionType;
|
|
156
138
|
if (conditionType === 'screen-size') {
|
|
157
139
|
var maxWidth = condition.maxWidth;
|
|
158
|
-
|
|
140
|
+
if (!mediaStylesMap[String(maxWidth)]) {
|
|
141
|
+
mediaStylesMap[String(maxWidth)] = [];
|
|
142
|
+
}
|
|
143
|
+
mediaStylesMap[String(maxWidth)].push((_a = {}, _a[className] = collectedStyles, _a));
|
|
159
144
|
}
|
|
160
145
|
if (condition.conditionType === 'element-state') {
|
|
161
146
|
cssMap.push(StyleBuilders.createCSSClassWithSelector(className, "&:".concat(condition.content), collectedStyles));
|
|
@@ -165,20 +150,34 @@ export var createCSSPlugin = function (config) {
|
|
|
165
150
|
}
|
|
166
151
|
case 'component-referenced': {
|
|
167
152
|
if (styleRef.content.content.type === 'static') {
|
|
168
|
-
classNamesToAppend.add(String(
|
|
169
|
-
? "".concat(componentFileName, "-").concat(StringUtils.camelCaseToDashCase(String(styleRef.content.content.content)))
|
|
170
|
-
: styleRef.content.content.content));
|
|
153
|
+
classNamesToAppend.add(String(styleRef.content.content.content));
|
|
171
154
|
}
|
|
172
155
|
if (styleRef.content.content.type === 'dynamic' &&
|
|
173
156
|
styleRef.content.content.content.referenceType === 'prop') {
|
|
174
|
-
|
|
175
|
-
|
|
157
|
+
var defaultPropValue = (_b = propDefinitions[styleRef.content.content.content.id]) === null || _b === void 0 ? void 0 : _b.defaultValue;
|
|
158
|
+
if (defaultPropValue) {
|
|
159
|
+
/* Changing the default value of the prop.
|
|
160
|
+
When forceScoping is enabled the classnames change. So, we need to change the default prop too. */
|
|
161
|
+
propDefinitions[styleRef.content.content.content.id].defaultValue = getClassName(forceScoping, uidl.name, String(defaultPropValue));
|
|
162
|
+
}
|
|
163
|
+
if (staticPropReferences) {
|
|
164
|
+
if (!defaultPropValue) {
|
|
165
|
+
return;
|
|
166
|
+
}
|
|
167
|
+
if (staticPropReferences) {
|
|
168
|
+
classNamesToAppend.add(getClassName(forceScoping, uidl.name, String(defaultPropValue)));
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
else {
|
|
172
|
+
dynamicVariantsToAppend.add(styleRef.content.content.content.id);
|
|
176
173
|
}
|
|
177
|
-
dynamicVariantsToAppend.add(styleRef.content.content.content.id);
|
|
178
174
|
}
|
|
179
175
|
if (styleRef.content.content.type === 'dynamic' &&
|
|
180
176
|
styleRef.content.content.content.referenceType === 'comp') {
|
|
181
|
-
|
|
177
|
+
if (!componentStyleSet[styleRef.content.content.content.id]) {
|
|
178
|
+
throw new PluginCSS("Node ".concat(elementType, " is referring to a comp style instance ").concat(styleRef.content.content.content.id, " which is missing."));
|
|
179
|
+
}
|
|
180
|
+
classNamesToAppend.add(getClassName(forceScoping, uidl.name, String(styleRef.content.content.content.id)));
|
|
182
181
|
}
|
|
183
182
|
return;
|
|
184
183
|
}
|
|
@@ -188,11 +187,11 @@ export var createCSSPlugin = function (config) {
|
|
|
188
187
|
if (!referedStyle) {
|
|
189
188
|
throw new PluginCSS("Style used from global stylesheet is missing - ".concat(content.referenceId));
|
|
190
189
|
}
|
|
191
|
-
classNamesToAppend.add(
|
|
190
|
+
classNamesToAppend.add(content.referenceId);
|
|
192
191
|
return;
|
|
193
192
|
}
|
|
194
193
|
default: {
|
|
195
|
-
throw new PluginCSS("
|
|
194
|
+
throw new PluginCSS("Un-supported style reference ".concat(JSON.stringify(styleRef.content, null, 2)));
|
|
196
195
|
}
|
|
197
196
|
}
|
|
198
197
|
});
|
|
@@ -217,7 +216,7 @@ export var createCSSPlugin = function (config) {
|
|
|
217
216
|
}
|
|
218
217
|
});
|
|
219
218
|
if (Object.keys(componentStyleSet).length > 0) {
|
|
220
|
-
StyleBuilders.generateStylesFromStyleSetDefinitions(componentStyleSet, cssMap, mediaStylesMap,
|
|
219
|
+
StyleBuilders.generateStylesFromStyleSetDefinitions(componentStyleSet, cssMap, mediaStylesMap, function (styleName) { return getClassName(forceScoping, uidl.name, styleName); });
|
|
221
220
|
}
|
|
222
221
|
if (Object.keys(mediaStylesMap).length > 0) {
|
|
223
222
|
cssMap.push.apply(cssMap, StyleBuilders.generateMediaStyle(mediaStylesMap));
|
|
@@ -255,7 +254,7 @@ export var createCSSPlugin = function (config) {
|
|
|
255
254
|
}); };
|
|
256
255
|
return cssPlugin;
|
|
257
256
|
};
|
|
258
|
-
export { createStyleSheetPlugin };
|
|
257
|
+
export { createStyleSheetPlugin, createCSSPlugin };
|
|
259
258
|
export default createCSSPlugin();
|
|
260
259
|
var createDynamicInlineStyle = function (styles) {
|
|
261
260
|
return Object.keys(styles)
|
|
@@ -264,4 +263,9 @@ var createDynamicInlineStyle = function (styles) {
|
|
|
264
263
|
})
|
|
265
264
|
.join(', ');
|
|
266
265
|
};
|
|
266
|
+
var getClassName = function (scoping, uidlName, nodeStyleName) {
|
|
267
|
+
return scoping
|
|
268
|
+
? StringUtils.camelCaseToDashCase("".concat(uidlName, "-").concat(nodeStyleName))
|
|
269
|
+
: StringUtils.camelCaseToDashCase(nodeStyleName);
|
|
270
|
+
};
|
|
267
271
|
//# sourceMappingURL=index.js.map
|
package/dist/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAA;AACpE,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,oCAAoC,CAAA;AACnG,OAAO,KAAK,KAAK,MAAM,cAAc,CAAA;AACrC,OAAO,EAKL,SAAS,EACT,QAAQ,EAIR,SAAS,GACV,MAAM,4BAA4B,CAAA;AACnC,OAAO,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAA;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,6BAA6B,CAAA;AACpE,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,oCAAoC,CAAA;AACnG,OAAO,KAAK,KAAK,MAAM,cAAc,CAAA;AACrC,OAAO,EAKL,SAAS,EACT,QAAQ,EAIR,SAAS,GACV,MAAM,4BAA4B,CAAA;AACnC,OAAO,EAAE,sBAAsB,EAA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AAQ,cAAI,aAAa,CAAE,CAAC;QACjE,CAAC,CAAC,WAAW,CAAC,mBAAmB,CAAC,aAAa,CAAC,CAAA;AACpD,CAAC,CAAA"}
|
package/dist/esm/style-sheet.js
CHANGED
|
@@ -36,9 +36,8 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
36
36
|
};
|
|
37
37
|
import { StyleUtils, StyleBuilders } from '@teleporthq/teleport-plugin-common';
|
|
38
38
|
import { ChunkType, FileType, } from '@teleporthq/teleport-types';
|
|
39
|
-
import { UIDLUtils } from '@teleporthq/teleport-shared';
|
|
40
39
|
export var createStyleSheetPlugin = function (config) {
|
|
41
|
-
var
|
|
40
|
+
var fileName = (config || { fileName: 'style' }).fileName;
|
|
42
41
|
var styleSheetPlugin = function (structure) { return __awaiter(void 0, void 0, void 0, function () {
|
|
43
42
|
var uidl, chunks, _a, styleSetDefinitions, _b, _c, _d, tokens, cssMap, mediaStylesMap;
|
|
44
43
|
return __generator(this, function (_e) {
|
|
@@ -54,7 +53,7 @@ export var createStyleSheetPlugin = function (config) {
|
|
|
54
53
|
cssMap.push(StyleBuilders.createCSSClassWithSelector('@global', ':root', StyleUtils.getTokensContentFromTokensObject(tokens)));
|
|
55
54
|
}
|
|
56
55
|
if (Object.keys(styleSetDefinitions).length > 0) {
|
|
57
|
-
StyleBuilders.generateStylesFromStyleSetDefinitions(styleSetDefinitions, cssMap, mediaStylesMap,
|
|
56
|
+
StyleBuilders.generateStylesFromStyleSetDefinitions(styleSetDefinitions, cssMap, mediaStylesMap, function (styleName) { return styleName; });
|
|
58
57
|
}
|
|
59
58
|
cssMap.push.apply(cssMap, StyleBuilders.generateMediaStyle(mediaStylesMap));
|
|
60
59
|
if (cssMap.length === 0) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"style-sheet.js","sourceRoot":"","sources":["../../src/style-sheet.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAA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U,CAAC,gCAAgC,CAAC,MAAM,CAAC,CACpD,CACF,CAAA;aACF;YAED,IAAI,MAAM,CAAC,IAAI,CAAC,mBAAmB,CAAC,CAAC,MAAM,GAAG,CAAC,EAAE;gBAC/C,aAAa,CAAC,qCAAqC,CACjD,mBAAmB,EACnB,MAAM,EACN,cAAc,EACd,UAAC,SAAiB,IAAK,OAAA,SAAS,EAAT,CAAS,CACjC,CAAA;aACF;YAED,MAAM,CAAC,IAAI,OAAX,MAAM,EAAS,aAAa,CAAC,kBAAkB,CAAC,cAAc,CAAC,EAAC;YAEhE,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC,EAAE;gBACvB,sBAAO,SAAS,EAAA;aACjB;YAED,IAAI,CAAC,aAAa,GAAG,IAAI,CAAC,aAAa,IAAI,EAAE,CAAA;YAC7C,IAAI,CAAC,aAAa,CAAC,aAAa,GAAG,QAAQ,CAAA;YAE3C,MAAM,CAAC,IAAI,CAAC;gBACV,IAAI,EAAE,QAAQ;gBACd,IAAI,EAAE,SAAS,CAAC,MAAM;gBACtB,QAAQ,EAAE,QAAQ,CAAC,GAAG;gBACtB,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC;gBAC1B,SAAS,EAAE,EAAE;aACd,CAAC,CAAA;YAEF,sBAAO,SAAS,EAAA;;SACjB,CAAA;IACD,OAAO,gBAAgB,CAAA;AACzB,CAAC,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"program":{"fileNames":["../../../../node_modules/typescript/lib/lib.es5.d.ts","../../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../../node_modules/typescript/lib/lib.dom.d.ts","../../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../../../teleport-types/dist/cjs/uidl.d.ts","../../../teleport-types/dist/cjs/generators.d.ts","../../../teleport-types/dist/cjs/errors.d.ts","../../../teleport-types/dist/cjs/vuidl.d.ts","../../../teleport-types/dist/cjs/index.d.ts","../../../teleport-shared/dist/cjs/constants/index.d.ts","../../../teleport-shared/dist/cjs/utils/string-utils.d.ts","../../../teleport-shared/dist/cjs/utils/uidl-utils.d.ts","../../../teleport-shared/dist/cjs/index.d.ts","../../../../node_modules/@babel/types/lib/index.d.ts","../../../teleport-plugin-common/dist/cjs/builders/ast-builders.d.ts","../../../teleport-plugin-common/dist/cjs/utils/parsed-ast.d.ts","../../../teleport-plugin-common/dist/cjs/builders/style-builders.d.ts","../../../teleport-plugin-common/dist/cjs/builders/hast-builders.d.ts","../../../teleport-plugin-common/dist/cjs/utils/ast-utils.d.ts","../../../teleport-plugin-common/dist/cjs/utils/style-utils.d.ts","../../../teleport-plugin-common/dist/cjs/utils/hast-utils.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-html/types.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-html/index.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-jsx/types.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-jsx/index.d.ts","../../../teleport-plugin-common/dist/cjs/index.d.ts","../../src/style-sheet.ts","../../src/index.ts","../../../../node_modules/@types/node/assert/strict.d.ts","../../../../node_modules/@types/node/globals.d.ts","../../../../node_modules/@types/node/async_hooks.d.ts","../../../../node_modules/@types/node/buffer.d.ts","../../../../node_modules/@types/node/child_process.d.ts","../../../../node_modules/@types/node/cluster.d.ts","../../../../node_modules/@types/node/console.d.ts","../../../../node_modules/@types/node/constants.d.ts","../../../../node_modules/@types/node/crypto.d.ts","../../../../node_modules/@types/node/dgram.d.ts","../../../../node_modules/@types/node/diagnostic_channel.d.ts","../../../../node_modules/@types/node/dns.d.ts","../../../../node_modules/@types/node/dns/promises.d.ts","../../../../node_modules/@types/node/domain.d.ts","../../../../node_modules/@types/node/events.d.ts","../../../../node_modules/@types/node/fs.d.ts","../../../../node_modules/@types/node/fs/promises.d.ts","../../../../node_modules/@types/node/http.d.ts","../../../../node_modules/@types/node/http2.d.ts","../../../../node_modules/@types/node/https.d.ts","../../../../node_modules/@types/node/inspector.d.ts","../../../../node_modules/@types/node/module.d.ts","../../../../node_modules/@types/node/net.d.ts","../../../../node_modules/@types/node/os.d.ts","../../../../node_modules/@types/node/path.d.ts","../../../../node_modules/@types/node/perf_hooks.d.ts","../../../../node_modules/@types/node/process.d.ts","../../../../node_modules/@types/node/punycode.d.ts","../../../../node_modules/@types/node/querystring.d.ts","../../../../node_modules/@types/node/readline.d.ts","../../../../node_modules/@types/node/repl.d.ts","../../../../node_modules/@types/node/stream.d.ts","../../../../node_modules/@types/node/stream/promises.d.ts","../../../../node_modules/@types/node/string_decoder.d.ts","../../../../node_modules/@types/node/timers.d.ts","../../../../node_modules/@types/node/timers/promises.d.ts","../../../../node_modules/@types/node/tls.d.ts","../../../../node_modules/@types/node/trace_events.d.ts","../../../../node_modules/@types/node/tty.d.ts","../../../../node_modules/@types/node/url.d.ts","../../../../node_modules/@types/node/util.d.ts","../../../../node_modules/@types/node/util/types.d.ts","../../../../node_modules/@types/node/v8.d.ts","../../../../node_modules/@types/node/vm.d.ts","../../../../node_modules/@types/node/worker_threads.d.ts","../../../../node_modules/@types/node/zlib.d.ts","../../../../node_modules/@types/node/globals.global.d.ts","../../../../node_modules/@types/node/wasi.d.ts","../../../../node_modules/@types/node/ts3.6/base.d.ts","../../../../node_modules/@types/node/assert.d.ts","../../../../node_modules/@types/node/base.d.ts","../../../../node_modules/@types/node/index.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/cleanupSemantic.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/types.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/diffLines.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/printDiffs.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/index.d.ts","../../../../node_modules/@types/jest/node_modules/pretty-format/build/types.d.ts","../../../../node_modules/@types/jest/node_modules/pretty-format/build/index.d.ts","../../../../node_modules/@types/jest/index.d.ts","../../../../node_modules/@types/jest/ts3.2/index.d.ts"],"fileInfos":[{"version":"3ac1b83264055b28c0165688fda6dfcc39001e9e7828f649299101c23ad0a0c3","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06",{"version":"72704b10d97777e15f1a581b73f88273037ef752d2e50b72287bd0a90af64fe6","affectsGlobalScope":true},{"version":"d8996609230d17e90484a2dd58f22668f9a05a3bfe00bfb1d6271171e54a31fb","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"c5c05907c02476e4bde6b7e76a79ffcd948aedd14b6a8f56e4674221b0417398","affectsGlobalScope":true},{"version":"0d5f52b3174bee6edb81260ebcd792692c32c81fd55499d69531496f3f2b25e7","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"75ec0bdd727d887f1b79ed6619412ea72ba3c81d92d0787ccb64bab18d261f14","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"1b3fe904465430e030c93239a348f05e1be80640d91f2f004c3512c2c2c89f34","affectsGlobalScope":true},{"version":"10bbdc1981b8d9310ee75bfac28ee0477bb2353e8529da8cff7cb26c409cb5e8","affectsGlobalScope":true},"42bf51402b690782aa9e6e437a2fb56a4de94c6f53fbb1728acff2dfd12df74a","18d176af12d389165c4ce64a4f3c365448f1a1beaccbef9a05793992160c89f4","d49a625c30294f92976c954fffb2bcc2faeb81957148a363969ee742a43e2913","c4a042f3df0f5855fbd2ba352d7b0a581a478737b60f306fbb253dceaaa981d2","cd619820771edb23926bb084906215ab9c491255fa707488d15748b38909b747","28b22326000119f53de35f67ce3096ef475a2224274162b1283ef8718e1efdb5","18aecf77d74ed15ae1e875a0d43f2aa85387794fc447b2bc3c8ab7e2224d0ac6","0dab32de48eb8cf6149f776ef25cae2e68580fb8a55419dba27f022381fdd87a","d2ff55204dd4868d11a163c207d4fbe8d99cbf8cb36fa90d2a2f0bfc802b4d38","2ff9995137f3e5d68971388ec58af0c79721626323884513f9f5e2e996ac1fdd","b0900ff47d065c568038fc21d06685e58b7932750f22c49bb5cc4c18bdd35aa3","634d90459c22c0d82376bd48246b99b4a33fe56bc94c15874d1dac1e8a577d75","f735cc9f46bef33ef3c3e45308fbe6e5c9c1b917d6724d989c046bed3db5c3ed","cb33f5a5c73598b92f9aa13a0cf4d0df2dc38f05da11e4ad2fd8f0a735b3b09e","cd7c7f7b87c5e6ddb24a061393d5df9dbb0a926f3499e6f1a7f3d1da0ced3fcb","cf4ba36b05e7a6194696ffcace1710d29bb681b77a20b9b09460707ea3fcecd5","79fb51af7dc378dfaa66da7791d2c91560a151fa74da9f466d9fb60f5f9ccb39","c84d0840044a735055b7911998976dab071cde1ee160f551f2d845aea5630e2e","3465b9608c725b6a4c35b154f636011da24525a137d73976f1222c624cd9ce40","3594cd8018f215116e41c6f05c6fc9e6845a60c74753cdd1a9521d52f9ac0f2a","50ffd0c3b71cdca0f2c5004b39d876a494648c953079f07d257d679a7b95d40a","0772ec3b64f51bbe952d514e28b9aa3355a5322d1c242d93b3e67292dc7bae7c","0f4ea9054b0e97f125c66e5cf4f97ec9aebc2ac76d8b333c62247310e4a4fb26","169bc0f9735d02878beeee9f64066dceef4b1b0eb5ebee88202532b0dd948f4e","c7bdc99177a2a94d25fb13722adaaf5b3291bf70b4d1b27584ba189dd3889ba3",{"version":"d1c92b66c4105659fcad4eb76a1481f7311033e117d0678a1ec545e8ddb8d4c6","affectsGlobalScope":true},"e23424b97418eca3226fd24de079f1203eb70360622e4e093af2aff14d4be6ec","dee93c07b4df5e26010dc9ec4cdf4d6e4076bb4474d2a8371529217c8b2740a4","ed40f2f184db052dc8df62d1f199823c8bbccc487c0a2a7c54eeea0badcf4378","04eaa93bd75f937f9184dcb95a7983800c5770cf8ddd8ac0f3734dc02f5b20ef",{"version":"c8155caf28fc7b0a564156a5df28ad8a844a3bd32d331d148d8f3ce88025c870","affectsGlobalScope":true},"45ac321f2e15d268fd74a90ddaa6467dcaaff2c5b13f95b4b85831520fb7a491","dfc747ab8dd5f623055a4c26fd35e8cceca869fd3f1cf09701c941ca3679665a","c9f5f2920ff61d7158417b8440d5181ddc34a3dfef811a5677dd8a9fb91471e9","5cc0a492da3602510b8f5ed1852b1e0390002780d8758fbc8c0cd023ca7085f8","ec7dafafe751a5121f8f1c80201ebe7e7238c47e6329280a73c4d1ca4bb7fa28","64debeb10e4b7ae4ec9e89bfb4e04c6101ab98c3cc806d14e5488607cfec2753",{"version":"2866a528b2708aa272ec3eaafd3c980abb23aec1ef831cfc5eb2186b98c37ce5","affectsGlobalScope":true},{"version":"a5782d6cea81fe43d2db7ed41e789458c933ab3ab60602f7b5b14c4da3370496","affectsGlobalScope":true},"f258ba66915f0196ec344bc53afe1888240bbcc855ebd151b6cc072275533319","6194335ee3353f7226ba31f31d6301d0c6be87228419c0a08976ccd9d4f1213e","3ac12a54cfaa84683506db8d4cf779135a271d9f0ec18930cf53e61fbeea0c5d","cf3d3b087d1a8a3355eec47d206162c75e912315b9b5c1cd49fda93e948fb80a","36f316c066c4a72dd6f19fec49a074f935744fc9ccbe75c87ebc07fb2feb9062","42176966283d3835c34278b9b5c0f470d484c0c0c6a55c20a2c916a1ce69b6e8","0cff7901aedfe78e314f7d44088f07e2afa1b6e4f0473a4169b8456ca2fb245d","ec70fd6f8a9a83f850dab2960a6789e93d5b034b354a16814cad5daabf62a360","e2236264a811ed1d09a2487a433e8f5216ae62378cf233954ae220cf886f6717","3ec1e108d587a5661ec790db607f482605ba9f3830e118ce578e3ffa3c42e22b","100b3bb9d39d2b1b5340f1bf45a52e94ef1692b45232b4ba00fac5c3cc56d331",{"version":"04fe7e7d8008887943260af1fde2bfd4877e0dc57bf634e0f0b2f3d1794dfd11","affectsGlobalScope":true},"7f77304372efe3c9967e5f9ea2061f1b4bf41dc3cda3c83cdd676f2e5af6b7e6","992c6f6be16c0a1d2eec13ece33adeea2c747ba27fcd078353a8f4bb5b4fea58","2597718d91e306949d89e285bf34c44192014ef541c3bd7cbb825c022749e974","a6b0abdb67d63ebe964ba5fee31bc3daf10c12eecd46b24d778426010c04c67e","ac4801ebc2355ba32329070123b1cd15891bf71b41dcaf9e75b4744832126a59","fd2298fba0640e7295e7bd545e2dfbfcccbb00c27019e501c87965a02bbdebf6","4fd3c4debadce3e9ab9dec3eb45f7f5e2e3d4ad65cf975a6d938d883cfb25a50","71ddd49185b68f27bfac127ef5d22cb2672c278e53e5370d9020ef50ca9c377d","b1ea7a6eaa7608e0e0529aebd323b526a79c6c05a4e519ae5c779675004dcdf1","9fcb033a6208485d8f3fadde31eb5cbcaf99149cff3e40c0dc53ebc6d0dff4e9","7df562288f949945cf69c21cd912100c2afedeeb7cdb219085f7f4b46cb7dde4","9d16690485ff1eb4f6fc57aebe237728fd8e03130c460919da3a35f4d9bd97f5","dcc6910d95a3625fd2b0487fda055988e46ab46c357a1b3618c27b4a8dd739c9","f4149f1aa299474c7040a35fe8f8ac2ad078cc1b190415adc1fff3ed52d490ea","3730099ed008776216268a97771de31753ef71e0a7d0ec650f588cba2a06ce44","8d649dbc429d7139a1d9a14ea2bf8af1dc089e0a879447539587463d4b6c248c","60c9e27816ec8ac8df7240598bb086e95b47edfb454c5cbf4003c812e0ed6e39","e361aecf17fc4034b4c122a1564471cdcd22ef3a51407803cb5a5fc020c04d02","4926467de88a92a4fc9971d8c6f21b91eca1c0e7fc2a46cc4638ab9440c73875",{"version":"2708349d5a11a5c2e5f3a0765259ebe7ee00cdcc8161cb9990cb4910328442a1","affectsGlobalScope":true},"fc0ae4a8ad3c762b96f9d2c3700cb879a373458cb0bf3175478e3b4f85f7ef2f","fabbec378e1ddd86fcf2662e716c2b8318acedb664ee3a4cba6f9e8ee8269cf1","b3593bd345ebea5e4d0a894c03251a3774b34df3d6db57075c18e089a599ba76","e61a21e9418f279bc480394a94d1581b2dee73747adcbdef999b6737e34d721b","efd55e8ca79171bf26c0d0e30221cb8ee1f5a31dd0c791ec4b2e886f42bab124","e222104af6cb9415238ad358488b74d76eceeff238c1268ec6e85655b05341da","69da61a7b5093dac77fa3bec8be95dcf9a74c95a0e9161edb98bb24e30e439d2","eba230221317c985ab1953ccc3edc517f248b37db4fef7875cb2c8d08aff7be7","b83e796810e475da3564c6515bc0ae9577070596a33d89299b7d99f94ecfd921","b4439890c168d646357928431100daac5cbdee1d345a34e6bf6eca9f3abe22bc","5d72971a459517c44c1379dab9ed248e87a61ba0a1e0f25c9d67e1e640cd9a09","02d734976af36f4273d930bea88b3e62adf6b078cf120c1c63d49aa8d8427c5c",{"version":"f624e578325b8c58e55b30c998b1f4c3ec1b61a9fa66373da4250c89b7880d44","affectsGlobalScope":true},{"version":"d3002f620eab4bf6476c9da5c0efb2041d46f7df8b3032a5631bd206abef2c75","affectsGlobalScope":true}],"options":{"allowSyntheticDefaultImports":true,"declaration":true,"emitDecoratorMetadata":true,"esModuleInterop":true,"experimentalDecorators":true,"module":99,"noImplicitAny":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","sourceMap":true,"target":1},"fileIdsList":[[109,111],[105,106],[105,106,107,108],[110],[112],[102],[101,102],[56,61],[67,68,75,84],[57,67,75],[93],[61,68,76],[84,89],[64,67,75],[65],[64],[67],[67,69,84,92],[67,68,84],[75,84,92],[67,68,70,75,84,89,92],[70,84,89,92],[103],[92],[64,67,84],[77],[55],[91],[82,93,96],[67,85],[84],[87],[61,75],[53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100],[75],[81],[94],[56,61,67,69,78,84,92,96],[33,38],[33],[33,38,40],[39,40,41,42,43,44,45,46,47,48,49],[33,46],[33,38,48],[33,37,38,50,51],[33,37,50],[34,35,36],[29],[29,30,31,32]],"referencedMap":[[112,1],[107,2],[109,3],[108,2],[111,4],[113,5],[53,6],[103,7],[56,8],[57,9],[58,10],[59,11],[60,12],[61,13],[62,14],[64,15],[65,16],[66,17],[67,17],[68,18],[69,19],[70,20],[71,21],[72,22],[104,23],[73,17],[74,24],[75,25],[77,26],[78,27],[79,28],[82,17],[83,29],[84,30],[85,31],[87,17],[88,32],[89,33],[101,34],[91,35],[92,36],[93,37],[95,31],[97,38],[98,31],[39,39],[42,40],[41,41],[50,42],[47,43],[46,40],[49,44],[48,39],[43,41],[45,40],[44,40],[52,45],[51,46],[34,40],[37,47],[36,40],[30,48],[33,49],[32,48]],"exportedModulesMap":[[112,1],[107,2],[109,3],[108,2],[111,4],[113,5],[53,6],[103,7],[56,8],[57,9],[58,10],[59,11],[60,12],[61,13],[62,14],[64,15],[65,16],[66,17],[67,17],[68,18],[69,19],[70,20],[71,21],[72,22],[104,23],[73,17],[74,24],[75,25],[77,26],[78,27],[79,28],[82,17],[83,29],[84,30],[85,31],[87,17],[88,32],[89,33],[101,34],[91,35],[92,36],[93,37],[95,31],[97,38],[98,31],[39,39],[42,40],[41,41],[50,42],[47,43],[46,40],[49,44],[48,39],[43,41],[45,40],[44,40],[52,45],[51,46],[34,40],[37,47],[36,40],[30,48],[33,49],[32,48]],"semanticDiagnosticsPerFile":[38,112,105,107,109,108,106,111,110,113,102,53,55,103,56,57,58,59,60,61,62,63,64,65,66,67,68,69,54,99,70,71,72,104,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,101,91,92,93,94,95,96,100,97,98,6,8,7,2,9,10,11,12,13,14,15,16,3,4,20,17,18,19,21,22,23,5,24,25,26,27,1,28,39,42,41,50,47,46,49,48,43,45,40,44,52,51,34,37,35,36,31,30,33,29,32]},"version":"4.6.2"}
|
|
1
|
+
{"program":{"fileNames":["../../../../node_modules/typescript/lib/lib.es5.d.ts","../../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../../node_modules/typescript/lib/lib.dom.d.ts","../../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../../../teleport-types/dist/cjs/uidl.d.ts","../../../teleport-types/dist/cjs/generators.d.ts","../../../teleport-types/dist/cjs/errors.d.ts","../../../teleport-types/dist/cjs/vuidl.d.ts","../../../teleport-types/dist/cjs/index.d.ts","../../../teleport-shared/dist/cjs/constants/index.d.ts","../../../teleport-shared/dist/cjs/utils/string-utils.d.ts","../../../teleport-shared/dist/cjs/utils/uidl-utils.d.ts","../../../teleport-shared/dist/cjs/index.d.ts","../../../../node_modules/@babel/types/lib/index.d.ts","../../../teleport-plugin-common/dist/cjs/builders/ast-builders.d.ts","../../../teleport-plugin-common/dist/cjs/utils/parsed-ast.d.ts","../../../teleport-plugin-common/dist/cjs/builders/style-builders.d.ts","../../../teleport-plugin-common/dist/cjs/builders/hast-builders.d.ts","../../../teleport-plugin-common/dist/cjs/utils/ast-utils.d.ts","../../../teleport-plugin-common/dist/cjs/utils/style-utils.d.ts","../../../teleport-plugin-common/dist/cjs/utils/hast-utils.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-html/types.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-html/index.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-jsx/types.d.ts","../../../teleport-plugin-common/dist/cjs/node-handlers/node-to-jsx/index.d.ts","../../../teleport-plugin-common/dist/cjs/index.d.ts","../../src/style-sheet.ts","../../src/index.ts","../../../../node_modules/@types/node/assert/strict.d.ts","../../../../node_modules/@types/node/globals.d.ts","../../../../node_modules/@types/node/async_hooks.d.ts","../../../../node_modules/@types/node/buffer.d.ts","../../../../node_modules/@types/node/child_process.d.ts","../../../../node_modules/@types/node/cluster.d.ts","../../../../node_modules/@types/node/console.d.ts","../../../../node_modules/@types/node/constants.d.ts","../../../../node_modules/@types/node/crypto.d.ts","../../../../node_modules/@types/node/dgram.d.ts","../../../../node_modules/@types/node/diagnostic_channel.d.ts","../../../../node_modules/@types/node/dns.d.ts","../../../../node_modules/@types/node/dns/promises.d.ts","../../../../node_modules/@types/node/domain.d.ts","../../../../node_modules/@types/node/events.d.ts","../../../../node_modules/@types/node/fs.d.ts","../../../../node_modules/@types/node/fs/promises.d.ts","../../../../node_modules/@types/node/http.d.ts","../../../../node_modules/@types/node/http2.d.ts","../../../../node_modules/@types/node/https.d.ts","../../../../node_modules/@types/node/inspector.d.ts","../../../../node_modules/@types/node/module.d.ts","../../../../node_modules/@types/node/net.d.ts","../../../../node_modules/@types/node/os.d.ts","../../../../node_modules/@types/node/path.d.ts","../../../../node_modules/@types/node/perf_hooks.d.ts","../../../../node_modules/@types/node/process.d.ts","../../../../node_modules/@types/node/punycode.d.ts","../../../../node_modules/@types/node/querystring.d.ts","../../../../node_modules/@types/node/readline.d.ts","../../../../node_modules/@types/node/repl.d.ts","../../../../node_modules/@types/node/stream.d.ts","../../../../node_modules/@types/node/stream/promises.d.ts","../../../../node_modules/@types/node/string_decoder.d.ts","../../../../node_modules/@types/node/timers.d.ts","../../../../node_modules/@types/node/timers/promises.d.ts","../../../../node_modules/@types/node/tls.d.ts","../../../../node_modules/@types/node/trace_events.d.ts","../../../../node_modules/@types/node/tty.d.ts","../../../../node_modules/@types/node/url.d.ts","../../../../node_modules/@types/node/util.d.ts","../../../../node_modules/@types/node/util/types.d.ts","../../../../node_modules/@types/node/v8.d.ts","../../../../node_modules/@types/node/vm.d.ts","../../../../node_modules/@types/node/worker_threads.d.ts","../../../../node_modules/@types/node/zlib.d.ts","../../../../node_modules/@types/node/globals.global.d.ts","../../../../node_modules/@types/node/wasi.d.ts","../../../../node_modules/@types/node/ts3.6/base.d.ts","../../../../node_modules/@types/node/assert.d.ts","../../../../node_modules/@types/node/base.d.ts","../../../../node_modules/@types/node/index.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/cleanupSemantic.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/types.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/diffLines.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/printDiffs.d.ts","../../../../node_modules/@types/jest/node_modules/jest-diff/build/index.d.ts","../../../../node_modules/@types/jest/node_modules/pretty-format/build/types.d.ts","../../../../node_modules/@types/jest/node_modules/pretty-format/build/index.d.ts","../../../../node_modules/@types/jest/index.d.ts","../../../../node_modules/@types/jest/ts3.2/index.d.ts"],"fileInfos":[{"version":"3ac1b83264055b28c0165688fda6dfcc39001e9e7828f649299101c23ad0a0c3","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06",{"version":"72704b10d97777e15f1a581b73f88273037ef752d2e50b72287bd0a90af64fe6","affectsGlobalScope":true},{"version":"d8996609230d17e90484a2dd58f22668f9a05a3bfe00bfb1d6271171e54a31fb","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"c5c05907c02476e4bde6b7e76a79ffcd948aedd14b6a8f56e4674221b0417398","affectsGlobalScope":true},{"version":"0d5f52b3174bee6edb81260ebcd792692c32c81fd55499d69531496f3f2b25e7","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"75ec0bdd727d887f1b79ed6619412ea72ba3c81d92d0787ccb64bab18d261f14","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"1b3fe904465430e030c93239a348f05e1be80640d91f2f004c3512c2c2c89f34","affectsGlobalScope":true},{"version":"10bbdc1981b8d9310ee75bfac28ee0477bb2353e8529da8cff7cb26c409cb5e8","affectsGlobalScope":true},"d58cb8e3308641cdc84644105bd3d594045b356af29fd10d5a74f42c1a8396ad","18d176af12d389165c4ce64a4f3c365448f1a1beaccbef9a05793992160c89f4","d49a625c30294f92976c954fffb2bcc2faeb81957148a363969ee742a43e2913","c4a042f3df0f5855fbd2ba352d7b0a581a478737b60f306fbb253dceaaa981d2","cd619820771edb23926bb084906215ab9c491255fa707488d15748b38909b747","28b22326000119f53de35f67ce3096ef475a2224274162b1283ef8718e1efdb5","18aecf77d74ed15ae1e875a0d43f2aa85387794fc447b2bc3c8ab7e2224d0ac6","0dab32de48eb8cf6149f776ef25cae2e68580fb8a55419dba27f022381fdd87a","d2ff55204dd4868d11a163c207d4fbe8d99cbf8cb36fa90d2a2f0bfc802b4d38","2ff9995137f3e5d68971388ec58af0c79721626323884513f9f5e2e996ac1fdd","b0900ff47d065c568038fc21d06685e58b7932750f22c49bb5cc4c18bdd35aa3","634d90459c22c0d82376bd48246b99b4a33fe56bc94c15874d1dac1e8a577d75","b179b68aed28f107ab90bc0b15cecee4388c612203e5b848df805c8dae3e3071","cb33f5a5c73598b92f9aa13a0cf4d0df2dc38f05da11e4ad2fd8f0a735b3b09e","cd7c7f7b87c5e6ddb24a061393d5df9dbb0a926f3499e6f1a7f3d1da0ced3fcb","cf4ba36b05e7a6194696ffcace1710d29bb681b77a20b9b09460707ea3fcecd5","79fb51af7dc378dfaa66da7791d2c91560a151fa74da9f466d9fb60f5f9ccb39","c84d0840044a735055b7911998976dab071cde1ee160f551f2d845aea5630e2e","3465b9608c725b6a4c35b154f636011da24525a137d73976f1222c624cd9ce40","3594cd8018f215116e41c6f05c6fc9e6845a60c74753cdd1a9521d52f9ac0f2a","50ffd0c3b71cdca0f2c5004b39d876a494648c953079f07d257d679a7b95d40a","0772ec3b64f51bbe952d514e28b9aa3355a5322d1c242d93b3e67292dc7bae7c","9e8ea4d6289073492eb213e308241228e2419402d138abad4a38a57c39c22806","4e0767065599bee38275285a73e6be0b2b09efc920547c08e45dc8a94bc7b7a4","c7bdc99177a2a94d25fb13722adaaf5b3291bf70b4d1b27584ba189dd3889ba3",{"version":"d1c92b66c4105659fcad4eb76a1481f7311033e117d0678a1ec545e8ddb8d4c6","affectsGlobalScope":true},"e23424b97418eca3226fd24de079f1203eb70360622e4e093af2aff14d4be6ec","dee93c07b4df5e26010dc9ec4cdf4d6e4076bb4474d2a8371529217c8b2740a4","ed40f2f184db052dc8df62d1f199823c8bbccc487c0a2a7c54eeea0badcf4378","04eaa93bd75f937f9184dcb95a7983800c5770cf8ddd8ac0f3734dc02f5b20ef",{"version":"c8155caf28fc7b0a564156a5df28ad8a844a3bd32d331d148d8f3ce88025c870","affectsGlobalScope":true},"45ac321f2e15d268fd74a90ddaa6467dcaaff2c5b13f95b4b85831520fb7a491","dfc747ab8dd5f623055a4c26fd35e8cceca869fd3f1cf09701c941ca3679665a","c9f5f2920ff61d7158417b8440d5181ddc34a3dfef811a5677dd8a9fb91471e9","5cc0a492da3602510b8f5ed1852b1e0390002780d8758fbc8c0cd023ca7085f8","ec7dafafe751a5121f8f1c80201ebe7e7238c47e6329280a73c4d1ca4bb7fa28","64debeb10e4b7ae4ec9e89bfb4e04c6101ab98c3cc806d14e5488607cfec2753",{"version":"2866a528b2708aa272ec3eaafd3c980abb23aec1ef831cfc5eb2186b98c37ce5","affectsGlobalScope":true},{"version":"a5782d6cea81fe43d2db7ed41e789458c933ab3ab60602f7b5b14c4da3370496","affectsGlobalScope":true},"f258ba66915f0196ec344bc53afe1888240bbcc855ebd151b6cc072275533319","6194335ee3353f7226ba31f31d6301d0c6be87228419c0a08976ccd9d4f1213e","3ac12a54cfaa84683506db8d4cf779135a271d9f0ec18930cf53e61fbeea0c5d","cf3d3b087d1a8a3355eec47d206162c75e912315b9b5c1cd49fda93e948fb80a","36f316c066c4a72dd6f19fec49a074f935744fc9ccbe75c87ebc07fb2feb9062","42176966283d3835c34278b9b5c0f470d484c0c0c6a55c20a2c916a1ce69b6e8","0cff7901aedfe78e314f7d44088f07e2afa1b6e4f0473a4169b8456ca2fb245d","ec70fd6f8a9a83f850dab2960a6789e93d5b034b354a16814cad5daabf62a360","e2236264a811ed1d09a2487a433e8f5216ae62378cf233954ae220cf886f6717","3ec1e108d587a5661ec790db607f482605ba9f3830e118ce578e3ffa3c42e22b","100b3bb9d39d2b1b5340f1bf45a52e94ef1692b45232b4ba00fac5c3cc56d331",{"version":"04fe7e7d8008887943260af1fde2bfd4877e0dc57bf634e0f0b2f3d1794dfd11","affectsGlobalScope":true},"7f77304372efe3c9967e5f9ea2061f1b4bf41dc3cda3c83cdd676f2e5af6b7e6","992c6f6be16c0a1d2eec13ece33adeea2c747ba27fcd078353a8f4bb5b4fea58","2597718d91e306949d89e285bf34c44192014ef541c3bd7cbb825c022749e974","a6b0abdb67d63ebe964ba5fee31bc3daf10c12eecd46b24d778426010c04c67e","ac4801ebc2355ba32329070123b1cd15891bf71b41dcaf9e75b4744832126a59","fd2298fba0640e7295e7bd545e2dfbfcccbb00c27019e501c87965a02bbdebf6","4fd3c4debadce3e9ab9dec3eb45f7f5e2e3d4ad65cf975a6d938d883cfb25a50","71ddd49185b68f27bfac127ef5d22cb2672c278e53e5370d9020ef50ca9c377d","b1ea7a6eaa7608e0e0529aebd323b526a79c6c05a4e519ae5c779675004dcdf1","9fcb033a6208485d8f3fadde31eb5cbcaf99149cff3e40c0dc53ebc6d0dff4e9","7df562288f949945cf69c21cd912100c2afedeeb7cdb219085f7f4b46cb7dde4","9d16690485ff1eb4f6fc57aebe237728fd8e03130c460919da3a35f4d9bd97f5","dcc6910d95a3625fd2b0487fda055988e46ab46c357a1b3618c27b4a8dd739c9","f4149f1aa299474c7040a35fe8f8ac2ad078cc1b190415adc1fff3ed52d490ea","3730099ed008776216268a97771de31753ef71e0a7d0ec650f588cba2a06ce44","8d649dbc429d7139a1d9a14ea2bf8af1dc089e0a879447539587463d4b6c248c","60c9e27816ec8ac8df7240598bb086e95b47edfb454c5cbf4003c812e0ed6e39","e361aecf17fc4034b4c122a1564471cdcd22ef3a51407803cb5a5fc020c04d02","4926467de88a92a4fc9971d8c6f21b91eca1c0e7fc2a46cc4638ab9440c73875",{"version":"2708349d5a11a5c2e5f3a0765259ebe7ee00cdcc8161cb9990cb4910328442a1","affectsGlobalScope":true},"fc0ae4a8ad3c762b96f9d2c3700cb879a373458cb0bf3175478e3b4f85f7ef2f","fabbec378e1ddd86fcf2662e716c2b8318acedb664ee3a4cba6f9e8ee8269cf1","b3593bd345ebea5e4d0a894c03251a3774b34df3d6db57075c18e089a599ba76","e61a21e9418f279bc480394a94d1581b2dee73747adcbdef999b6737e34d721b","efd55e8ca79171bf26c0d0e30221cb8ee1f5a31dd0c791ec4b2e886f42bab124","e222104af6cb9415238ad358488b74d76eceeff238c1268ec6e85655b05341da","69da61a7b5093dac77fa3bec8be95dcf9a74c95a0e9161edb98bb24e30e439d2","eba230221317c985ab1953ccc3edc517f248b37db4fef7875cb2c8d08aff7be7","b83e796810e475da3564c6515bc0ae9577070596a33d89299b7d99f94ecfd921","b4439890c168d646357928431100daac5cbdee1d345a34e6bf6eca9f3abe22bc","5d72971a459517c44c1379dab9ed248e87a61ba0a1e0f25c9d67e1e640cd9a09","02d734976af36f4273d930bea88b3e62adf6b078cf120c1c63d49aa8d8427c5c",{"version":"f624e578325b8c58e55b30c998b1f4c3ec1b61a9fa66373da4250c89b7880d44","affectsGlobalScope":true},{"version":"d3002f620eab4bf6476c9da5c0efb2041d46f7df8b3032a5631bd206abef2c75","affectsGlobalScope":true}],"options":{"allowSyntheticDefaultImports":true,"declaration":true,"emitDecoratorMetadata":true,"esModuleInterop":true,"experimentalDecorators":true,"module":99,"noImplicitAny":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./","sourceMap":true,"target":1},"fileIdsList":[[109,111],[105,106],[105,106,107,108],[110],[112],[102],[101,102],[56,61],[67,68,75,84],[57,67,75],[93],[61,68,76],[84,89],[64,67,75],[65],[64],[67],[67,69,84,92],[67,68,84],[75,84,92],[67,68,70,75,84,89,92],[70,84,89,92],[103],[92],[64,67,84],[77],[55],[91],[82,93,96],[67,85],[84],[87],[61,75],[53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100],[75],[81],[94],[56,61,67,69,78,84,92,96],[33,38],[33],[33,38,40],[39,40,41,42,43,44,45,46,47,48,49],[33,46],[33,38,48],[33,37,38,50,51],[33,50],[34,35,36],[29],[29,30,31,32]],"referencedMap":[[112,1],[107,2],[109,3],[108,2],[111,4],[113,5],[53,6],[103,7],[56,8],[57,9],[58,10],[59,11],[60,12],[61,13],[62,14],[64,15],[65,16],[66,17],[67,17],[68,18],[69,19],[70,20],[71,21],[72,22],[104,23],[73,17],[74,24],[75,25],[77,26],[78,27],[79,28],[82,17],[83,29],[84,30],[85,31],[87,17],[88,32],[89,33],[101,34],[91,35],[92,36],[93,37],[95,31],[97,38],[98,31],[39,39],[42,40],[41,41],[50,42],[47,43],[46,40],[49,44],[48,39],[43,41],[45,40],[44,40],[52,45],[51,46],[34,40],[37,47],[36,40],[30,48],[33,49],[32,48]],"exportedModulesMap":[[112,1],[107,2],[109,3],[108,2],[111,4],[113,5],[53,6],[103,7],[56,8],[57,9],[58,10],[59,11],[60,12],[61,13],[62,14],[64,15],[65,16],[66,17],[67,17],[68,18],[69,19],[70,20],[71,21],[72,22],[104,23],[73,17],[74,24],[75,25],[77,26],[78,27],[79,28],[82,17],[83,29],[84,30],[85,31],[87,17],[88,32],[89,33],[101,34],[91,35],[92,36],[93,37],[95,31],[97,38],[98,31],[39,39],[42,40],[41,41],[50,42],[47,43],[46,40],[49,44],[48,39],[43,41],[45,40],[44,40],[52,45],[51,46],[34,40],[37,47],[36,40],[30,48],[33,49],[32,48]],"semanticDiagnosticsPerFile":[38,112,105,107,109,108,106,111,110,113,102,53,55,103,56,57,58,59,60,61,62,63,64,65,66,67,68,69,54,99,70,71,72,104,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,101,91,92,93,94,95,96,100,97,98,6,8,7,2,9,10,11,12,13,14,15,16,3,4,20,17,18,19,21,22,23,5,24,25,26,27,1,28,39,42,41,50,47,46,49,48,43,45,40,44,52,51,34,37,35,36,31,30,33,29,32]},"version":"4.6.2"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@teleporthq/teleport-plugin-css",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.21.0",
|
|
4
4
|
"description": "A plugin for creating the styles into external css files",
|
|
5
5
|
"author": "teleportHQ",
|
|
6
6
|
"license": "MIT",
|
|
@@ -25,9 +25,9 @@
|
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"@babel/types": "^7.5.5",
|
|
28
|
-
"@teleporthq/teleport-plugin-common": "^0.
|
|
29
|
-
"@teleporthq/teleport-shared": "^0.
|
|
30
|
-
"@teleporthq/teleport-types": "^0.
|
|
28
|
+
"@teleporthq/teleport-plugin-common": "^0.21.0",
|
|
29
|
+
"@teleporthq/teleport-shared": "^0.21.0",
|
|
30
|
+
"@teleporthq/teleport-types": "^0.21.0"
|
|
31
31
|
},
|
|
32
|
-
"gitHead": "
|
|
32
|
+
"gitHead": "dd790cfb393fbdb560646eded5a9d6111e43b6ad"
|
|
33
33
|
}
|
package/src/index.ts
CHANGED
|
@@ -25,9 +25,10 @@ interface CSSPluginConfig {
|
|
|
25
25
|
templateStyle: 'html' | 'jsx'
|
|
26
26
|
declareDependency: 'import' | 'decorator' | 'none'
|
|
27
27
|
dynamicVariantPrefix?: string
|
|
28
|
+
staticPropReferences?: boolean
|
|
28
29
|
}
|
|
29
30
|
|
|
30
|
-
|
|
31
|
+
const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig> = (config) => {
|
|
31
32
|
const {
|
|
32
33
|
chunkName = 'style-chunk',
|
|
33
34
|
templateChunkName = 'template-chunk',
|
|
@@ -38,18 +39,18 @@ export const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig> = (config)
|
|
|
38
39
|
declareDependency = 'none',
|
|
39
40
|
forceScoping = false,
|
|
40
41
|
dynamicVariantPrefix,
|
|
42
|
+
staticPropReferences = false,
|
|
41
43
|
} = config || {}
|
|
42
44
|
|
|
43
45
|
const cssPlugin: ComponentPlugin = async (structure) => {
|
|
44
46
|
const { uidl, chunks, dependencies, options } = structure
|
|
45
|
-
const { node, styleSetDefinitions: componentStyleSet = {} } = uidl
|
|
47
|
+
const { node, styleSetDefinitions: componentStyleSet = {}, propDefinitions = {} } = uidl
|
|
46
48
|
const { projectStyleSet, designLanguage: { tokens = {} } = {}, isRootComponent } = options || {}
|
|
47
49
|
const {
|
|
48
50
|
styleSetDefinitions = {},
|
|
49
51
|
fileName: projectStyleSheetName,
|
|
50
52
|
path: projectStyleSheetPath,
|
|
51
53
|
} = projectStyleSet || {}
|
|
52
|
-
const componentFileName = UIDLUtils.getComponentFileName(uidl) // Filename used to enforce dash case naming
|
|
53
54
|
|
|
54
55
|
if (isRootComponent) {
|
|
55
56
|
if (Object.keys(tokens).length > 0 || Object.keys(styleSetDefinitions).length > 0) {
|
|
@@ -80,7 +81,10 @@ export const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig> = (config)
|
|
|
80
81
|
: ('' as string)
|
|
81
82
|
|
|
82
83
|
const cssMap: string[] = []
|
|
83
|
-
const mediaStylesMap: Record<
|
|
84
|
+
const mediaStylesMap: Record<
|
|
85
|
+
string,
|
|
86
|
+
Array<{ [x: string]: Record<string, string | number> }>
|
|
87
|
+
> = {}
|
|
84
88
|
|
|
85
89
|
UIDLUtils.traverseElements(node, (element) => {
|
|
86
90
|
const classNamesToAppend: Set<string> = new Set()
|
|
@@ -93,42 +97,16 @@ export const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig> = (config)
|
|
|
93
97
|
attrs = {},
|
|
94
98
|
elementType,
|
|
95
99
|
} = element
|
|
100
|
+
const elementClassName = StringUtils.camelCaseToDashCase(key)
|
|
96
101
|
|
|
97
102
|
if (forceScoping && dependency?.type === 'local') {
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
(attribute: types.JSXAttribute) => {
|
|
106
|
-
if (
|
|
107
|
-
attribute.name?.name === attr &&
|
|
108
|
-
(attribute.value as types.StringLiteral)?.value
|
|
109
|
-
) {
|
|
110
|
-
;(
|
|
111
|
-
attribute.value as types.StringLiteral
|
|
112
|
-
).value = `${compStyleName}-${StringUtils.camelCaseToDashCase(
|
|
113
|
-
(attribute.value as types.StringLiteral).value
|
|
114
|
-
)}`
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
)
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
if (templateStyle === 'html') {
|
|
121
|
-
const compInstanceNode = templateLookup[key] as HastNode
|
|
122
|
-
if (!compInstanceNode?.properties[attr]) {
|
|
123
|
-
return
|
|
124
|
-
}
|
|
125
|
-
compInstanceNode.properties[
|
|
126
|
-
attr
|
|
127
|
-
] = `${compStyleName}-${StringUtils.camelCaseToDashCase(
|
|
128
|
-
String(compInstanceNode.properties[attr])
|
|
129
|
-
)}`
|
|
130
|
-
}
|
|
131
|
-
}
|
|
103
|
+
StyleBuilders.setPropValueForCompStyle({
|
|
104
|
+
attrs,
|
|
105
|
+
key,
|
|
106
|
+
jsxNodesLookup: templateLookup,
|
|
107
|
+
templateStyle,
|
|
108
|
+
getClassName: (styleName: string) =>
|
|
109
|
+
getClassName(forceScoping, StringUtils.camelCaseToDashCase(elementType), styleName),
|
|
132
110
|
})
|
|
133
111
|
}
|
|
134
112
|
|
|
@@ -145,10 +123,7 @@ export const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig> = (config)
|
|
|
145
123
|
throw new PluginCSS(`Node - ${key} is missing from the template chunk`)
|
|
146
124
|
}
|
|
147
125
|
|
|
148
|
-
const
|
|
149
|
-
const className = forceScoping // when the framework doesn't provide automating scoping for classNames
|
|
150
|
-
? `${componentFileName}-${elementClassName}`
|
|
151
|
-
: elementClassName
|
|
126
|
+
const className = getClassName(forceScoping, uidl.name, elementClassName)
|
|
152
127
|
|
|
153
128
|
const { staticStyles, dynamicStyles, tokenStyles } =
|
|
154
129
|
UIDLUtils.splitDynamicAndStaticStyles(style)
|
|
@@ -198,10 +173,10 @@ export const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig> = (config)
|
|
|
198
173
|
const { conditionType } = condition
|
|
199
174
|
if (conditionType === 'screen-size') {
|
|
200
175
|
const { maxWidth } = condition as UIDLStyleMediaQueryScreenSizeCondition
|
|
201
|
-
mediaStylesMap[maxWidth]
|
|
202
|
-
|
|
203
|
-
[className]: collectedStyles,
|
|
176
|
+
if (!mediaStylesMap[String(maxWidth)]) {
|
|
177
|
+
mediaStylesMap[String(maxWidth)] = []
|
|
204
178
|
}
|
|
179
|
+
mediaStylesMap[String(maxWidth)].push({ [className]: collectedStyles })
|
|
205
180
|
}
|
|
206
181
|
|
|
207
182
|
if (condition.conditionType === 'element-state') {
|
|
@@ -220,38 +195,52 @@ export const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig> = (config)
|
|
|
220
195
|
|
|
221
196
|
case 'component-referenced': {
|
|
222
197
|
if (styleRef.content.content.type === 'static') {
|
|
223
|
-
classNamesToAppend.add(
|
|
224
|
-
String(
|
|
225
|
-
forceScoping && styleRef.content.content.content
|
|
226
|
-
? `${componentFileName}-${StringUtils.camelCaseToDashCase(
|
|
227
|
-
String(styleRef.content.content.content)
|
|
228
|
-
)}`
|
|
229
|
-
: styleRef.content.content.content
|
|
230
|
-
)
|
|
231
|
-
)
|
|
198
|
+
classNamesToAppend.add(String(styleRef.content.content.content))
|
|
232
199
|
}
|
|
233
200
|
|
|
234
201
|
if (
|
|
235
202
|
styleRef.content.content.type === 'dynamic' &&
|
|
236
203
|
styleRef.content.content.content.referenceType === 'prop'
|
|
237
204
|
) {
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
205
|
+
const defaultPropValue =
|
|
206
|
+
propDefinitions[styleRef.content.content.content.id]?.defaultValue
|
|
207
|
+
|
|
208
|
+
if (defaultPropValue) {
|
|
209
|
+
/* Changing the default value of the prop.
|
|
210
|
+
When forceScoping is enabled the classnames change. So, we need to change the default prop too. */
|
|
211
|
+
propDefinitions[styleRef.content.content.content.id].defaultValue = getClassName(
|
|
212
|
+
forceScoping,
|
|
213
|
+
uidl.name,
|
|
214
|
+
String(defaultPropValue)
|
|
244
215
|
)
|
|
245
216
|
}
|
|
246
217
|
|
|
247
|
-
|
|
218
|
+
if (staticPropReferences) {
|
|
219
|
+
if (!defaultPropValue) {
|
|
220
|
+
return
|
|
221
|
+
}
|
|
222
|
+
if (staticPropReferences) {
|
|
223
|
+
classNamesToAppend.add(
|
|
224
|
+
getClassName(forceScoping, uidl.name, String(defaultPropValue))
|
|
225
|
+
)
|
|
226
|
+
}
|
|
227
|
+
} else {
|
|
228
|
+
dynamicVariantsToAppend.add(styleRef.content.content.content.id)
|
|
229
|
+
}
|
|
248
230
|
}
|
|
249
231
|
|
|
250
232
|
if (
|
|
251
233
|
styleRef.content.content.type === 'dynamic' &&
|
|
252
234
|
styleRef.content.content.content.referenceType === 'comp'
|
|
253
235
|
) {
|
|
254
|
-
|
|
236
|
+
if (!componentStyleSet[styleRef.content.content.content.id]) {
|
|
237
|
+
throw new PluginCSS(
|
|
238
|
+
`Node ${elementType} is referring to a comp style instance ${styleRef.content.content.content.id} which is missing.`
|
|
239
|
+
)
|
|
240
|
+
}
|
|
241
|
+
classNamesToAppend.add(
|
|
242
|
+
getClassName(forceScoping, uidl.name, String(styleRef.content.content.content.id))
|
|
243
|
+
)
|
|
255
244
|
}
|
|
256
245
|
|
|
257
246
|
return
|
|
@@ -265,17 +254,14 @@ export const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig> = (config)
|
|
|
265
254
|
`Style used from global stylesheet is missing - ${content.referenceId}`
|
|
266
255
|
)
|
|
267
256
|
}
|
|
268
|
-
|
|
257
|
+
|
|
258
|
+
classNamesToAppend.add(content.referenceId)
|
|
269
259
|
return
|
|
270
260
|
}
|
|
271
261
|
|
|
272
262
|
default: {
|
|
273
263
|
throw new PluginCSS(
|
|
274
|
-
`
|
|
275
|
-
styleRef.content,
|
|
276
|
-
null,
|
|
277
|
-
2
|
|
278
|
-
)}`
|
|
264
|
+
`Un-supported style reference ${JSON.stringify(styleRef.content, null, 2)}`
|
|
279
265
|
)
|
|
280
266
|
}
|
|
281
267
|
}
|
|
@@ -321,8 +307,7 @@ export const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig> = (config)
|
|
|
321
307
|
componentStyleSet,
|
|
322
308
|
cssMap,
|
|
323
309
|
mediaStylesMap,
|
|
324
|
-
|
|
325
|
-
forceScoping
|
|
310
|
+
(styleName: string) => getClassName(forceScoping, uidl.name, styleName)
|
|
326
311
|
)
|
|
327
312
|
}
|
|
328
313
|
|
|
@@ -374,7 +359,7 @@ export const createCSSPlugin: ComponentPluginFactory<CSSPluginConfig> = (config)
|
|
|
374
359
|
return cssPlugin
|
|
375
360
|
}
|
|
376
361
|
|
|
377
|
-
export { createStyleSheetPlugin }
|
|
362
|
+
export { createStyleSheetPlugin, createCSSPlugin }
|
|
378
363
|
|
|
379
364
|
export default createCSSPlugin()
|
|
380
365
|
|
|
@@ -385,3 +370,9 @@ const createDynamicInlineStyle = (styles: UIDLStyleDefinitions) => {
|
|
|
385
370
|
})
|
|
386
371
|
.join(', ')
|
|
387
372
|
}
|
|
373
|
+
|
|
374
|
+
const getClassName = (scoping: boolean, uidlName: string, nodeStyleName: string) => {
|
|
375
|
+
return scoping
|
|
376
|
+
? StringUtils.camelCaseToDashCase(`${uidlName}-${nodeStyleName}`)
|
|
377
|
+
: StringUtils.camelCaseToDashCase(nodeStyleName)
|
|
378
|
+
}
|
package/src/style-sheet.ts
CHANGED
|
@@ -5,15 +5,13 @@ import {
|
|
|
5
5
|
ChunkType,
|
|
6
6
|
FileType,
|
|
7
7
|
} from '@teleporthq/teleport-types'
|
|
8
|
-
import { UIDLUtils } from '@teleporthq/teleport-shared'
|
|
9
8
|
|
|
10
9
|
interface StyleSheetPlugin {
|
|
11
10
|
fileName?: string
|
|
12
|
-
forceScoping?: boolean
|
|
13
11
|
}
|
|
14
12
|
|
|
15
13
|
export const createStyleSheetPlugin: ComponentPluginFactory<StyleSheetPlugin> = (config) => {
|
|
16
|
-
const { fileName
|
|
14
|
+
const { fileName } = config || { fileName: 'style' }
|
|
17
15
|
const styleSheetPlugin: ComponentPlugin = async (structure) => {
|
|
18
16
|
const { uidl, chunks } = structure
|
|
19
17
|
const { styleSetDefinitions = {}, designLanguage: { tokens = {} } = {} } = uidl
|
|
@@ -26,7 +24,10 @@ export const createStyleSheetPlugin: ComponentPluginFactory<StyleSheetPlugin> =
|
|
|
26
24
|
}
|
|
27
25
|
|
|
28
26
|
const cssMap: string[] = []
|
|
29
|
-
const mediaStylesMap: Record<
|
|
27
|
+
const mediaStylesMap: Record<
|
|
28
|
+
string,
|
|
29
|
+
Array<{ [x: string]: Record<string, string | number> }>
|
|
30
|
+
> = {}
|
|
30
31
|
|
|
31
32
|
if (Object.keys(tokens).length > 0) {
|
|
32
33
|
cssMap.push(
|
|
@@ -43,8 +44,7 @@ export const createStyleSheetPlugin: ComponentPluginFactory<StyleSheetPlugin> =
|
|
|
43
44
|
styleSetDefinitions,
|
|
44
45
|
cssMap,
|
|
45
46
|
mediaStylesMap,
|
|
46
|
-
|
|
47
|
-
forceScoping
|
|
47
|
+
(styleName: string) => styleName
|
|
48
48
|
)
|
|
49
49
|
}
|
|
50
50
|
|