@cuemath/leap 3.0.22-aa1 → 3.0.22-aa12

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.
Files changed (124) hide show
  1. package/dist/_virtual/_commonjsHelpers.js +4 -24
  2. package/dist/_virtual/_commonjsHelpers.js.map +1 -1
  3. package/dist/features/cue-canvas/cue-cavas-styled.js +30 -27
  4. package/dist/features/cue-canvas/cue-cavas-styled.js.map +1 -1
  5. package/dist/features/cue-canvas/sidebar/homework/homework-request.js +26 -18
  6. package/dist/features/cue-canvas/sidebar/homework/homework-request.js.map +1 -1
  7. package/dist/features/cue-canvas/sidebar/homework/homework.js +29 -48
  8. package/dist/features/cue-canvas/sidebar/homework/homework.js.map +1 -1
  9. package/dist/features/cue-canvas/sidebar/puzzles/utils.js +68 -67
  10. package/dist/features/cue-canvas/sidebar/puzzles/utils.js.map +1 -1
  11. package/dist/index.d.ts +0 -2
  12. package/dist/index.js +487 -489
  13. package/dist/index.js.map +1 -1
  14. package/package.json +1 -1
  15. package/dist/_virtual/___vite-browser-external.js +0 -7
  16. package/dist/_virtual/___vite-browser-external.js.map +0 -1
  17. package/dist/_virtual/__vite-browser-external.js +0 -5
  18. package/dist/_virtual/__vite-browser-external.js.map +0 -1
  19. package/dist/_virtual/index2.js +0 -5
  20. package/dist/_virtual/index2.js.map +0 -1
  21. package/dist/_virtual/picocolors.browser.js +0 -5
  22. package/dist/_virtual/picocolors.browser.js.map +0 -1
  23. package/dist/_virtual/symbols.js +0 -5
  24. package/dist/_virtual/symbols.js.map +0 -1
  25. package/dist/assets/line-icons/icons/hw.js +0 -32
  26. package/dist/assets/line-icons/icons/hw.js.map +0 -1
  27. package/dist/node_modules/@emotion/unitless/dist/emotion-unitless.esm.js +0 -53
  28. package/dist/node_modules/@emotion/unitless/dist/emotion-unitless.esm.js.map +0 -1
  29. package/dist/node_modules/camelize/index.js +0 -44
  30. package/dist/node_modules/camelize/index.js.map +0 -1
  31. package/dist/node_modules/css-color-keywords/colors.json.js +0 -298
  32. package/dist/node_modules/css-color-keywords/colors.json.js.map +0 -1
  33. package/dist/node_modules/css-color-keywords/index.js +0 -6
  34. package/dist/node_modules/css-color-keywords/index.js.map +0 -1
  35. package/dist/node_modules/css-to-react-native/index.js +0 -397
  36. package/dist/node_modules/css-to-react-native/index.js.map +0 -1
  37. package/dist/node_modules/nanoid/non-secure/index.js +0 -16
  38. package/dist/node_modules/nanoid/non-secure/index.js.map +0 -1
  39. package/dist/node_modules/picocolors/picocolors.browser.js +0 -11
  40. package/dist/node_modules/picocolors/picocolors.browser.js.map +0 -1
  41. package/dist/node_modules/postcss/lib/at-rule.js +0 -20
  42. package/dist/node_modules/postcss/lib/at-rule.js.map +0 -1
  43. package/dist/node_modules/postcss/lib/comment.js +0 -13
  44. package/dist/node_modules/postcss/lib/comment.js.map +0 -1
  45. package/dist/node_modules/postcss/lib/container.js +0 -226
  46. package/dist/node_modules/postcss/lib/container.js.map +0 -1
  47. package/dist/node_modules/postcss/lib/css-syntax-error.js +0 -45
  48. package/dist/node_modules/postcss/lib/css-syntax-error.js.map +0 -1
  49. package/dist/node_modules/postcss/lib/declaration.js +0 -16
  50. package/dist/node_modules/postcss/lib/declaration.js.map +0 -1
  51. package/dist/node_modules/postcss/lib/document.js +0 -22
  52. package/dist/node_modules/postcss/lib/document.js.map +0 -1
  53. package/dist/node_modules/postcss/lib/fromJSON.js +0 -43
  54. package/dist/node_modules/postcss/lib/fromJSON.js.map +0 -1
  55. package/dist/node_modules/postcss/lib/input.js +0 -134
  56. package/dist/node_modules/postcss/lib/input.js.map +0 -1
  57. package/dist/node_modules/postcss/lib/lazy-result.js +0 -347
  58. package/dist/node_modules/postcss/lib/lazy-result.js.map +0 -1
  59. package/dist/node_modules/postcss/lib/list.js +0 -22
  60. package/dist/node_modules/postcss/lib/list.js.map +0 -1
  61. package/dist/node_modules/postcss/lib/map-generator.js +0 -167
  62. package/dist/node_modules/postcss/lib/map-generator.js.map +0 -1
  63. package/dist/node_modules/postcss/lib/no-work-result.js +0 -90
  64. package/dist/node_modules/postcss/lib/no-work-result.js.map +0 -1
  65. package/dist/node_modules/postcss/lib/node.js +0 -216
  66. package/dist/node_modules/postcss/lib/node.js.map +0 -1
  67. package/dist/node_modules/postcss/lib/parse.js +0 -23
  68. package/dist/node_modules/postcss/lib/parse.js.map +0 -1
  69. package/dist/node_modules/postcss/lib/parser.js +0 -318
  70. package/dist/node_modules/postcss/lib/parser.js.map +0 -1
  71. package/dist/node_modules/postcss/lib/postcss.js +0 -30
  72. package/dist/node_modules/postcss/lib/postcss.js.map +0 -1
  73. package/dist/node_modules/postcss/lib/postcss2.js +0 -76
  74. package/dist/node_modules/postcss/lib/postcss2.js.map +0 -1
  75. package/dist/node_modules/postcss/lib/previous-map.js +0 -89
  76. package/dist/node_modules/postcss/lib/previous-map.js.map +0 -1
  77. package/dist/node_modules/postcss/lib/processor.js +0 -42
  78. package/dist/node_modules/postcss/lib/processor.js.map +0 -1
  79. package/dist/node_modules/postcss/lib/result.js +0 -27
  80. package/dist/node_modules/postcss/lib/result.js.map +0 -1
  81. package/dist/node_modules/postcss/lib/root.js +0 -38
  82. package/dist/node_modules/postcss/lib/root.js.map +0 -1
  83. package/dist/node_modules/postcss/lib/rule.js +0 -22
  84. package/dist/node_modules/postcss/lib/rule.js.map +0 -1
  85. package/dist/node_modules/postcss/lib/stringifier.js +0 -193
  86. package/dist/node_modules/postcss/lib/stringifier.js.map +0 -1
  87. package/dist/node_modules/postcss/lib/stringify.js +0 -11
  88. package/dist/node_modules/postcss/lib/stringify.js.map +0 -1
  89. package/dist/node_modules/postcss/lib/symbols.js +0 -7
  90. package/dist/node_modules/postcss/lib/symbols.js.map +0 -1
  91. package/dist/node_modules/postcss/lib/tokenize.js +0 -110
  92. package/dist/node_modules/postcss/lib/tokenize.js.map +0 -1
  93. package/dist/node_modules/postcss/lib/warn-once.js +0 -8
  94. package/dist/node_modules/postcss/lib/warn-once.js.map +0 -1
  95. package/dist/node_modules/postcss/lib/warning.js +0 -22
  96. package/dist/node_modules/postcss/lib/warning.js.map +0 -1
  97. package/dist/node_modules/postcss-value-parser/lib/index.js +0 -22
  98. package/dist/node_modules/postcss-value-parser/lib/index.js.map +0 -1
  99. package/dist/node_modules/postcss-value-parser/lib/parse.js +0 -115
  100. package/dist/node_modules/postcss-value-parser/lib/parse.js.map +0 -1
  101. package/dist/node_modules/postcss-value-parser/lib/stringify.js +0 -18
  102. package/dist/node_modules/postcss-value-parser/lib/stringify.js.map +0 -1
  103. package/dist/node_modules/postcss-value-parser/lib/unit.js +0 -37
  104. package/dist/node_modules/postcss-value-parser/lib/unit.js.map +0 -1
  105. package/dist/node_modules/postcss-value-parser/lib/walk.js +0 -9
  106. package/dist/node_modules/postcss-value-parser/lib/walk.js.map +0 -1
  107. package/dist/node_modules/styled-components/native/dist/styled-components.native.esm.js +0 -473
  108. package/dist/node_modules/styled-components/native/dist/styled-components.native.esm.js.map +0 -1
  109. package/dist/node_modules/stylis/src/Enum.js +0 -13
  110. package/dist/node_modules/stylis/src/Enum.js.map +0 -1
  111. package/dist/node_modules/stylis/src/Middleware.js +0 -48
  112. package/dist/node_modules/stylis/src/Middleware.js.map +0 -1
  113. package/dist/node_modules/stylis/src/Parser.js +0 -115
  114. package/dist/node_modules/stylis/src/Parser.js.map +0 -1
  115. package/dist/node_modules/stylis/src/Prefixer.js +0 -151
  116. package/dist/node_modules/stylis/src/Prefixer.js.map +0 -1
  117. package/dist/node_modules/stylis/src/Serializer.js +0 -28
  118. package/dist/node_modules/stylis/src/Serializer.js.map +0 -1
  119. package/dist/node_modules/stylis/src/Tokenizer.js +0 -138
  120. package/dist/node_modules/stylis/src/Tokenizer.js.map +0 -1
  121. package/dist/node_modules/stylis/src/Utility.js +0 -57
  122. package/dist/node_modules/stylis/src/Utility.js.map +0 -1
  123. package/dist/node_modules/tslib/tslib.es6.js +0 -19
  124. package/dist/node_modules/tslib/tslib.es6.js.map +0 -1
@@ -1,347 +0,0 @@
1
- import "./symbols.js";
2
- import { m as w } from "./map-generator.js";
3
- import { s as E } from "./stringify.js";
4
- import { c as v } from "./container.js";
5
- import { d as x } from "./document.js";
6
- import { w as S } from "./warn-once.js";
7
- import { r as P } from "./result.js";
8
- import { p as O } from "./parse.js";
9
- import { r as R } from "./root.js";
10
- import { __exports as I } from "../../../_virtual/symbols.js";
11
- let { isClean: l, my: C } = I, b = w, A = E, D = v, L = x, V = S, m = P, _ = O, k = R;
12
- const N = {
13
- atrule: "AtRule",
14
- comment: "Comment",
15
- decl: "Declaration",
16
- document: "Document",
17
- root: "Root",
18
- rule: "Rule"
19
- }, T = {
20
- AtRule: !0,
21
- AtRuleExit: !0,
22
- Comment: !0,
23
- CommentExit: !0,
24
- Declaration: !0,
25
- DeclarationExit: !0,
26
- Document: !0,
27
- DocumentExit: !0,
28
- Once: !0,
29
- OnceExit: !0,
30
- postcssPlugin: !0,
31
- prepare: !0,
32
- Root: !0,
33
- RootExit: !0,
34
- Rule: !0,
35
- RuleExit: !0
36
- }, j = {
37
- Once: !0,
38
- postcssPlugin: !0,
39
- prepare: !0
40
- }, a = 0;
41
- function f(o) {
42
- return typeof o == "object" && typeof o.then == "function";
43
- }
44
- function d(o) {
45
- let e = !1, t = N[o.type];
46
- return o.type === "decl" ? e = o.prop.toLowerCase() : o.type === "atrule" && (e = o.name.toLowerCase()), e && o.append ? [
47
- t,
48
- t + "-" + e,
49
- a,
50
- t + "Exit",
51
- t + "Exit-" + e
52
- ] : e ? [t, t + "-" + e, t + "Exit", t + "Exit-" + e] : o.append ? [t, a, t + "Exit"] : [t, t + "Exit"];
53
- }
54
- function g(o) {
55
- let e;
56
- return o.type === "document" ? e = ["Document", a, "DocumentExit"] : o.type === "root" ? e = ["Root", a, "RootExit"] : e = d(o), {
57
- eventIndex: 0,
58
- events: e,
59
- iterator: 0,
60
- node: o,
61
- visitorIndex: 0,
62
- visitors: []
63
- };
64
- }
65
- function c(o) {
66
- return o[l] = !1, o.nodes && o.nodes.forEach((e) => c(e)), o;
67
- }
68
- let y = {};
69
- class u {
70
- constructor(e, t, r) {
71
- this.stringified = !1, this.processed = !1;
72
- let s;
73
- if (typeof t == "object" && t !== null && (t.type === "root" || t.type === "document"))
74
- s = c(t);
75
- else if (t instanceof u || t instanceof m)
76
- s = c(t.root), t.map && (typeof r.map > "u" && (r.map = {}), r.map.inline || (r.map.inline = !1), r.map.prev = t.map);
77
- else {
78
- let i = _;
79
- r.syntax && (i = r.syntax.parse), r.parser && (i = r.parser), i.parse && (i = i.parse);
80
- try {
81
- s = i(t, r);
82
- } catch (n) {
83
- this.processed = !0, this.error = n;
84
- }
85
- s && !s[C] && D.rebuild(s);
86
- }
87
- this.result = new m(e, s, r), this.helpers = { ...y, postcss: y, result: this.result }, this.plugins = this.processor.plugins.map((i) => typeof i == "object" && i.prepare ? { ...i, ...i.prepare(this.result) } : i);
88
- }
89
- async() {
90
- return this.error ? Promise.reject(this.error) : this.processed ? Promise.resolve(this.result) : (this.processing || (this.processing = this.runAsync()), this.processing);
91
- }
92
- catch(e) {
93
- return this.async().catch(e);
94
- }
95
- finally(e) {
96
- return this.async().then(e, e);
97
- }
98
- getAsyncError() {
99
- throw new Error("Use process(css).then(cb) to work with async plugins");
100
- }
101
- handleError(e, t) {
102
- let r = this.result.lastPlugin;
103
- try {
104
- if (t && t.addToError(e), this.error = e, e.name === "CssSyntaxError" && !e.plugin)
105
- e.plugin = r.postcssPlugin, e.setMessage();
106
- else if (r.postcssVersion && process.env.NODE_ENV !== "production") {
107
- let s = r.postcssPlugin, i = r.postcssVersion, n = this.result.processor.version, h = i.split("."), p = n.split(".");
108
- (h[0] !== p[0] || parseInt(h[1]) > parseInt(p[1])) && console.error(
109
- "Unknown error from PostCSS plugin. Your current PostCSS version is " + n + ", but " + s + " uses " + i + ". Perhaps this is the source of the error below."
110
- );
111
- }
112
- } catch (s) {
113
- console && console.error && console.error(s);
114
- }
115
- return e;
116
- }
117
- prepareVisitors() {
118
- this.listeners = {};
119
- let e = (t, r, s) => {
120
- this.listeners[r] || (this.listeners[r] = []), this.listeners[r].push([t, s]);
121
- };
122
- for (let t of this.plugins)
123
- if (typeof t == "object")
124
- for (let r in t) {
125
- if (!T[r] && /^[A-Z]/.test(r))
126
- throw new Error(
127
- `Unknown event ${r} in ${t.postcssPlugin}. Try to update PostCSS (${this.processor.version} now).`
128
- );
129
- if (!j[r])
130
- if (typeof t[r] == "object")
131
- for (let s in t[r])
132
- s === "*" ? e(t, r, t[r][s]) : e(
133
- t,
134
- r + "-" + s.toLowerCase(),
135
- t[r][s]
136
- );
137
- else typeof t[r] == "function" && e(t, r, t[r]);
138
- }
139
- this.hasListener = Object.keys(this.listeners).length > 0;
140
- }
141
- async runAsync() {
142
- this.plugin = 0;
143
- for (let e = 0; e < this.plugins.length; e++) {
144
- let t = this.plugins[e], r = this.runOnRoot(t);
145
- if (f(r))
146
- try {
147
- await r;
148
- } catch (s) {
149
- throw this.handleError(s);
150
- }
151
- }
152
- if (this.prepareVisitors(), this.hasListener) {
153
- let e = this.result.root;
154
- for (; !e[l]; ) {
155
- e[l] = !0;
156
- let t = [g(e)];
157
- for (; t.length > 0; ) {
158
- let r = this.visitTick(t);
159
- if (f(r))
160
- try {
161
- await r;
162
- } catch (s) {
163
- let i = t[t.length - 1].node;
164
- throw this.handleError(s, i);
165
- }
166
- }
167
- }
168
- if (this.listeners.OnceExit)
169
- for (let [t, r] of this.listeners.OnceExit) {
170
- this.result.lastPlugin = t;
171
- try {
172
- if (e.type === "document") {
173
- let s = e.nodes.map(
174
- (i) => r(i, this.helpers)
175
- );
176
- await Promise.all(s);
177
- } else
178
- await r(e, this.helpers);
179
- } catch (s) {
180
- throw this.handleError(s);
181
- }
182
- }
183
- }
184
- return this.processed = !0, this.stringify();
185
- }
186
- runOnRoot(e) {
187
- this.result.lastPlugin = e;
188
- try {
189
- if (typeof e == "object" && e.Once) {
190
- if (this.result.root.type === "document") {
191
- let t = this.result.root.nodes.map(
192
- (r) => e.Once(r, this.helpers)
193
- );
194
- return f(t[0]) ? Promise.all(t) : t;
195
- }
196
- return e.Once(this.result.root, this.helpers);
197
- } else if (typeof e == "function")
198
- return e(this.result.root, this.result);
199
- } catch (t) {
200
- throw this.handleError(t);
201
- }
202
- }
203
- stringify() {
204
- if (this.error) throw this.error;
205
- if (this.stringified) return this.result;
206
- this.stringified = !0, this.sync();
207
- let e = this.result.opts, t = A;
208
- e.syntax && (t = e.syntax.stringify), e.stringifier && (t = e.stringifier), t.stringify && (t = t.stringify);
209
- let s = new b(t, this.result.root, this.result.opts).generate();
210
- return this.result.css = s[0], this.result.map = s[1], this.result;
211
- }
212
- sync() {
213
- if (this.error) throw this.error;
214
- if (this.processed) return this.result;
215
- if (this.processed = !0, this.processing)
216
- throw this.getAsyncError();
217
- for (let e of this.plugins) {
218
- let t = this.runOnRoot(e);
219
- if (f(t))
220
- throw this.getAsyncError();
221
- }
222
- if (this.prepareVisitors(), this.hasListener) {
223
- let e = this.result.root;
224
- for (; !e[l]; )
225
- e[l] = !0, this.walkSync(e);
226
- if (this.listeners.OnceExit)
227
- if (e.type === "document")
228
- for (let t of e.nodes)
229
- this.visitSync(this.listeners.OnceExit, t);
230
- else
231
- this.visitSync(this.listeners.OnceExit, e);
232
- }
233
- return this.result;
234
- }
235
- then(e, t) {
236
- return process.env.NODE_ENV !== "production" && ("from" in this.opts || V(
237
- "Without `from` option PostCSS could generate wrong source map and will not find Browserslist config. Set it to CSS file path or to `undefined` to prevent this warning."
238
- )), this.async().then(e, t);
239
- }
240
- toString() {
241
- return this.css;
242
- }
243
- visitSync(e, t) {
244
- for (let [r, s] of e) {
245
- this.result.lastPlugin = r;
246
- let i;
247
- try {
248
- i = s(t, this.helpers);
249
- } catch (n) {
250
- throw this.handleError(n, t.proxyOf);
251
- }
252
- if (t.type !== "root" && t.type !== "document" && !t.parent)
253
- return !0;
254
- if (f(i))
255
- throw this.getAsyncError();
256
- }
257
- }
258
- visitTick(e) {
259
- let t = e[e.length - 1], { node: r, visitors: s } = t;
260
- if (r.type !== "root" && r.type !== "document" && !r.parent) {
261
- e.pop();
262
- return;
263
- }
264
- if (s.length > 0 && t.visitorIndex < s.length) {
265
- let [n, h] = s[t.visitorIndex];
266
- t.visitorIndex += 1, t.visitorIndex === s.length && (t.visitors = [], t.visitorIndex = 0), this.result.lastPlugin = n;
267
- try {
268
- return h(r.toProxy(), this.helpers);
269
- } catch (p) {
270
- throw this.handleError(p, r);
271
- }
272
- }
273
- if (t.iterator !== 0) {
274
- let n = t.iterator, h;
275
- for (; h = r.nodes[r.indexes[n]]; )
276
- if (r.indexes[n] += 1, !h[l]) {
277
- h[l] = !0, e.push(g(h));
278
- return;
279
- }
280
- t.iterator = 0, delete r.indexes[n];
281
- }
282
- let i = t.events;
283
- for (; t.eventIndex < i.length; ) {
284
- let n = i[t.eventIndex];
285
- if (t.eventIndex += 1, n === a) {
286
- r.nodes && r.nodes.length && (r[l] = !0, t.iterator = r.getIterator());
287
- return;
288
- } else if (this.listeners[n]) {
289
- t.visitors = this.listeners[n];
290
- return;
291
- }
292
- }
293
- e.pop();
294
- }
295
- walkSync(e) {
296
- e[l] = !0;
297
- let t = d(e);
298
- for (let r of t)
299
- if (r === a)
300
- e.nodes && e.each((s) => {
301
- s[l] || this.walkSync(s);
302
- });
303
- else {
304
- let s = this.listeners[r];
305
- if (s && this.visitSync(s, e.toProxy()))
306
- return;
307
- }
308
- }
309
- warnings() {
310
- return this.sync().warnings();
311
- }
312
- get content() {
313
- return this.stringify().content;
314
- }
315
- get css() {
316
- return this.stringify().css;
317
- }
318
- get map() {
319
- return this.stringify().map;
320
- }
321
- get messages() {
322
- return this.sync().messages;
323
- }
324
- get opts() {
325
- return this.result.opts;
326
- }
327
- get processor() {
328
- return this.result.processor;
329
- }
330
- get root() {
331
- return this.sync().root;
332
- }
333
- get [Symbol.toStringTag]() {
334
- return "LazyResult";
335
- }
336
- }
337
- u.registerPostcss = (o) => {
338
- y = o;
339
- };
340
- var q = u;
341
- u.default = u;
342
- k.registerLazyResult(u);
343
- L.registerLazyResult(u);
344
- export {
345
- q as l
346
- };
347
- //# sourceMappingURL=lazy-result.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"lazy-result.js","sources":["../../../../node_modules/postcss/lib/lazy-result.js"],"sourcesContent":["'use strict'\n\nlet { isClean, my } = require('./symbols')\nlet MapGenerator = require('./map-generator')\nlet stringify = require('./stringify')\nlet Container = require('./container')\nlet Document = require('./document')\nlet warnOnce = require('./warn-once')\nlet Result = require('./result')\nlet parse = require('./parse')\nlet Root = require('./root')\n\nconst TYPE_TO_CLASS_NAME = {\n atrule: 'AtRule',\n comment: 'Comment',\n decl: 'Declaration',\n document: 'Document',\n root: 'Root',\n rule: 'Rule'\n}\n\nconst PLUGIN_PROPS = {\n AtRule: true,\n AtRuleExit: true,\n Comment: true,\n CommentExit: true,\n Declaration: true,\n DeclarationExit: true,\n Document: true,\n DocumentExit: true,\n Once: true,\n OnceExit: true,\n postcssPlugin: true,\n prepare: true,\n Root: true,\n RootExit: true,\n Rule: true,\n RuleExit: true\n}\n\nconst NOT_VISITORS = {\n Once: true,\n postcssPlugin: true,\n prepare: true\n}\n\nconst CHILDREN = 0\n\nfunction isPromise(obj) {\n return typeof obj === 'object' && typeof obj.then === 'function'\n}\n\nfunction getEvents(node) {\n let key = false\n let type = TYPE_TO_CLASS_NAME[node.type]\n if (node.type === 'decl') {\n key = node.prop.toLowerCase()\n } else if (node.type === 'atrule') {\n key = node.name.toLowerCase()\n }\n\n if (key && node.append) {\n return [\n type,\n type + '-' + key,\n CHILDREN,\n type + 'Exit',\n type + 'Exit-' + key\n ]\n } else if (key) {\n return [type, type + '-' + key, type + 'Exit', type + 'Exit-' + key]\n } else if (node.append) {\n return [type, CHILDREN, type + 'Exit']\n } else {\n return [type, type + 'Exit']\n }\n}\n\nfunction toStack(node) {\n let events\n if (node.type === 'document') {\n events = ['Document', CHILDREN, 'DocumentExit']\n } else if (node.type === 'root') {\n events = ['Root', CHILDREN, 'RootExit']\n } else {\n events = getEvents(node)\n }\n\n return {\n eventIndex: 0,\n events,\n iterator: 0,\n node,\n visitorIndex: 0,\n visitors: []\n }\n}\n\nfunction cleanMarks(node) {\n node[isClean] = false\n if (node.nodes) node.nodes.forEach(i => cleanMarks(i))\n return node\n}\n\nlet postcss = {}\n\nclass LazyResult {\n constructor(processor, css, opts) {\n this.stringified = false\n this.processed = false\n\n let root\n if (\n typeof css === 'object' &&\n css !== null &&\n (css.type === 'root' || css.type === 'document')\n ) {\n root = cleanMarks(css)\n } else if (css instanceof LazyResult || css instanceof Result) {\n root = cleanMarks(css.root)\n if (css.map) {\n if (typeof opts.map === 'undefined') opts.map = {}\n if (!opts.map.inline) opts.map.inline = false\n opts.map.prev = css.map\n }\n } else {\n let parser = parse\n if (opts.syntax) parser = opts.syntax.parse\n if (opts.parser) parser = opts.parser\n if (parser.parse) parser = parser.parse\n\n try {\n root = parser(css, opts)\n } catch (error) {\n this.processed = true\n this.error = error\n }\n\n if (root && !root[my]) {\n /* c8 ignore next 2 */\n Container.rebuild(root)\n }\n }\n\n this.result = new Result(processor, root, opts)\n this.helpers = { ...postcss, postcss, result: this.result }\n this.plugins = this.processor.plugins.map(plugin => {\n if (typeof plugin === 'object' && plugin.prepare) {\n return { ...plugin, ...plugin.prepare(this.result) }\n } else {\n return plugin\n }\n })\n }\n\n async() {\n if (this.error) return Promise.reject(this.error)\n if (this.processed) return Promise.resolve(this.result)\n if (!this.processing) {\n this.processing = this.runAsync()\n }\n return this.processing\n }\n\n catch(onRejected) {\n return this.async().catch(onRejected)\n }\n\n finally(onFinally) {\n return this.async().then(onFinally, onFinally)\n }\n\n getAsyncError() {\n throw new Error('Use process(css).then(cb) to work with async plugins')\n }\n\n handleError(error, node) {\n let plugin = this.result.lastPlugin\n try {\n if (node) node.addToError(error)\n this.error = error\n if (error.name === 'CssSyntaxError' && !error.plugin) {\n error.plugin = plugin.postcssPlugin\n error.setMessage()\n } else if (plugin.postcssVersion) {\n if (process.env.NODE_ENV !== 'production') {\n let pluginName = plugin.postcssPlugin\n let pluginVer = plugin.postcssVersion\n let runtimeVer = this.result.processor.version\n let a = pluginVer.split('.')\n let b = runtimeVer.split('.')\n\n if (a[0] !== b[0] || parseInt(a[1]) > parseInt(b[1])) {\n // eslint-disable-next-line no-console\n console.error(\n 'Unknown error from PostCSS plugin. Your current PostCSS ' +\n 'version is ' +\n runtimeVer +\n ', but ' +\n pluginName +\n ' uses ' +\n pluginVer +\n '. Perhaps this is the source of the error below.'\n )\n }\n }\n }\n } catch (err) {\n /* c8 ignore next 3 */\n // eslint-disable-next-line no-console\n if (console && console.error) console.error(err)\n }\n return error\n }\n\n prepareVisitors() {\n this.listeners = {}\n let add = (plugin, type, cb) => {\n if (!this.listeners[type]) this.listeners[type] = []\n this.listeners[type].push([plugin, cb])\n }\n for (let plugin of this.plugins) {\n if (typeof plugin === 'object') {\n for (let event in plugin) {\n if (!PLUGIN_PROPS[event] && /^[A-Z]/.test(event)) {\n throw new Error(\n `Unknown event ${event} in ${plugin.postcssPlugin}. ` +\n `Try to update PostCSS (${this.processor.version} now).`\n )\n }\n if (!NOT_VISITORS[event]) {\n if (typeof plugin[event] === 'object') {\n for (let filter in plugin[event]) {\n if (filter === '*') {\n add(plugin, event, plugin[event][filter])\n } else {\n add(\n plugin,\n event + '-' + filter.toLowerCase(),\n plugin[event][filter]\n )\n }\n }\n } else if (typeof plugin[event] === 'function') {\n add(plugin, event, plugin[event])\n }\n }\n }\n }\n }\n this.hasListener = Object.keys(this.listeners).length > 0\n }\n\n async runAsync() {\n this.plugin = 0\n for (let i = 0; i < this.plugins.length; i++) {\n let plugin = this.plugins[i]\n let promise = this.runOnRoot(plugin)\n if (isPromise(promise)) {\n try {\n await promise\n } catch (error) {\n throw this.handleError(error)\n }\n }\n }\n\n this.prepareVisitors()\n if (this.hasListener) {\n let root = this.result.root\n while (!root[isClean]) {\n root[isClean] = true\n let stack = [toStack(root)]\n while (stack.length > 0) {\n let promise = this.visitTick(stack)\n if (isPromise(promise)) {\n try {\n await promise\n } catch (e) {\n let node = stack[stack.length - 1].node\n throw this.handleError(e, node)\n }\n }\n }\n }\n\n if (this.listeners.OnceExit) {\n for (let [plugin, visitor] of this.listeners.OnceExit) {\n this.result.lastPlugin = plugin\n try {\n if (root.type === 'document') {\n let roots = root.nodes.map(subRoot =>\n visitor(subRoot, this.helpers)\n )\n\n await Promise.all(roots)\n } else {\n await visitor(root, this.helpers)\n }\n } catch (e) {\n throw this.handleError(e)\n }\n }\n }\n }\n\n this.processed = true\n return this.stringify()\n }\n\n runOnRoot(plugin) {\n this.result.lastPlugin = plugin\n try {\n if (typeof plugin === 'object' && plugin.Once) {\n if (this.result.root.type === 'document') {\n let roots = this.result.root.nodes.map(root =>\n plugin.Once(root, this.helpers)\n )\n\n if (isPromise(roots[0])) {\n return Promise.all(roots)\n }\n\n return roots\n }\n\n return plugin.Once(this.result.root, this.helpers)\n } else if (typeof plugin === 'function') {\n return plugin(this.result.root, this.result)\n }\n } catch (error) {\n throw this.handleError(error)\n }\n }\n\n stringify() {\n if (this.error) throw this.error\n if (this.stringified) return this.result\n this.stringified = true\n\n this.sync()\n\n let opts = this.result.opts\n let str = stringify\n if (opts.syntax) str = opts.syntax.stringify\n if (opts.stringifier) str = opts.stringifier\n if (str.stringify) str = str.stringify\n\n let map = new MapGenerator(str, this.result.root, this.result.opts)\n let data = map.generate()\n this.result.css = data[0]\n this.result.map = data[1]\n\n return this.result\n }\n\n sync() {\n if (this.error) throw this.error\n if (this.processed) return this.result\n this.processed = true\n\n if (this.processing) {\n throw this.getAsyncError()\n }\n\n for (let plugin of this.plugins) {\n let promise = this.runOnRoot(plugin)\n if (isPromise(promise)) {\n throw this.getAsyncError()\n }\n }\n\n this.prepareVisitors()\n if (this.hasListener) {\n let root = this.result.root\n while (!root[isClean]) {\n root[isClean] = true\n this.walkSync(root)\n }\n if (this.listeners.OnceExit) {\n if (root.type === 'document') {\n for (let subRoot of root.nodes) {\n this.visitSync(this.listeners.OnceExit, subRoot)\n }\n } else {\n this.visitSync(this.listeners.OnceExit, root)\n }\n }\n }\n\n return this.result\n }\n\n then(onFulfilled, onRejected) {\n if (process.env.NODE_ENV !== 'production') {\n if (!('from' in this.opts)) {\n warnOnce(\n 'Without `from` option PostCSS could generate wrong source map ' +\n 'and will not find Browserslist config. Set it to CSS file path ' +\n 'or to `undefined` to prevent this warning.'\n )\n }\n }\n return this.async().then(onFulfilled, onRejected)\n }\n\n toString() {\n return this.css\n }\n\n visitSync(visitors, node) {\n for (let [plugin, visitor] of visitors) {\n this.result.lastPlugin = plugin\n let promise\n try {\n promise = visitor(node, this.helpers)\n } catch (e) {\n throw this.handleError(e, node.proxyOf)\n }\n if (node.type !== 'root' && node.type !== 'document' && !node.parent) {\n return true\n }\n if (isPromise(promise)) {\n throw this.getAsyncError()\n }\n }\n }\n\n visitTick(stack) {\n let visit = stack[stack.length - 1]\n let { node, visitors } = visit\n\n if (node.type !== 'root' && node.type !== 'document' && !node.parent) {\n stack.pop()\n return\n }\n\n if (visitors.length > 0 && visit.visitorIndex < visitors.length) {\n let [plugin, visitor] = visitors[visit.visitorIndex]\n visit.visitorIndex += 1\n if (visit.visitorIndex === visitors.length) {\n visit.visitors = []\n visit.visitorIndex = 0\n }\n this.result.lastPlugin = plugin\n try {\n return visitor(node.toProxy(), this.helpers)\n } catch (e) {\n throw this.handleError(e, node)\n }\n }\n\n if (visit.iterator !== 0) {\n let iterator = visit.iterator\n let child\n while ((child = node.nodes[node.indexes[iterator]])) {\n node.indexes[iterator] += 1\n if (!child[isClean]) {\n child[isClean] = true\n stack.push(toStack(child))\n return\n }\n }\n visit.iterator = 0\n delete node.indexes[iterator]\n }\n\n let events = visit.events\n while (visit.eventIndex < events.length) {\n let event = events[visit.eventIndex]\n visit.eventIndex += 1\n if (event === CHILDREN) {\n if (node.nodes && node.nodes.length) {\n node[isClean] = true\n visit.iterator = node.getIterator()\n }\n return\n } else if (this.listeners[event]) {\n visit.visitors = this.listeners[event]\n return\n }\n }\n stack.pop()\n }\n\n walkSync(node) {\n node[isClean] = true\n let events = getEvents(node)\n for (let event of events) {\n if (event === CHILDREN) {\n if (node.nodes) {\n node.each(child => {\n if (!child[isClean]) this.walkSync(child)\n })\n }\n } else {\n let visitors = this.listeners[event]\n if (visitors) {\n if (this.visitSync(visitors, node.toProxy())) return\n }\n }\n }\n }\n\n warnings() {\n return this.sync().warnings()\n }\n\n get content() {\n return this.stringify().content\n }\n\n get css() {\n return this.stringify().css\n }\n\n get map() {\n return this.stringify().map\n }\n\n get messages() {\n return this.sync().messages\n }\n\n get opts() {\n return this.result.opts\n }\n\n get processor() {\n return this.result.processor\n }\n\n get root() {\n return this.sync().root\n }\n\n get [Symbol.toStringTag]() {\n return 'LazyResult'\n }\n}\n\nLazyResult.registerPostcss = dependant => {\n postcss = dependant\n}\n\nmodule.exports = LazyResult\nLazyResult.default = LazyResult\n\nRoot.registerLazyResult(LazyResult)\nDocument.registerLazyResult(LazyResult)\n"],"names":["isClean","my","require$$0","MapGenerator","require$$1","stringify","require$$2","Container","require$$3","Document","require$$4","warnOnce","require$$5","Result","require$$6","parse","require$$7","Root","require$$8","TYPE_TO_CLASS_NAME","PLUGIN_PROPS","NOT_VISITORS","CHILDREN","isPromise","obj","getEvents","node","key","type","toStack","events","cleanMarks","i","postcss","LazyResult","processor","css","opts","root","parser","error","plugin","onRejected","onFinally","pluginName","pluginVer","runtimeVer","a","b","err","add","cb","event","filter","promise","stack","e","visitor","roots","subRoot","str","data","onFulfilled","visitors","visit","iterator","child","dependant","lazyResult"],"mappings":";;;;;;;;;;AAEA,IAAI,EAAE,SAAAA,GAAS,IAAAC,EAAE,IAAKC,GAClBC,IAAeC,GACfC,IAAYC,GACZC,IAAYC,GACZC,IAAWC,GACXC,IAAWC,GACXC,IAASC,GACTC,IAAQC,GACRC,IAAOC;AAEX,MAAMC,IAAqB;AAAA,EACzB,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,MAAM;AAAA,EACN,UAAU;AAAA,EACV,MA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CAAAwC,MAAS;AACjB,UAAKA,EAAMlE,CAAO,KAAG,KAAK,SAASkE,CAAK;AAAA,QACpD,CAAW;AAAA,WAEE;AACL,YAAIH,IAAW,KAAK,UAAUX,CAAK;AACnC,YAAIW,KACE,KAAK,UAAUA,GAAUrC,EAAK,QAAS,CAAA;AAAG;AAAA,MAEjD;AAAA,EAEJ;AAAA,EAED,WAAW;AACT,WAAO,KAAK,KAAM,EAAC,SAAU;AAAA,EAC9B;AAAA,EAED,IAAI,UAAU;AACZ,WAAO,KAAK,UAAS,EAAG;AAAA,EACzB;AAAA,EAED,IAAI,MAAM;AACR,WAAO,KAAK,UAAS,EAAG;AAAA,EACzB;AAAA,EAED,IAAI,MAAM;AACR,WAAO,KAAK,UAAS,EAAG;AAAA,EACzB;AAAA,EAED,IAAI,WAAW;AACb,WAAO,KAAK,KAAI,EAAG;AAAA,EACpB;AAAA,EAED,IAAI,OAAO;AACT,WAAO,KAAK,OAAO;AAAA,EACpB;AAAA,EAED,IAAI,YAAY;AACd,WAAO,KAAK,OAAO;AAAA,EACpB;AAAA,EAED,IAAI,OAAO;AACT,WAAO,KAAK,KAAI,EAAG;AAAA,EACpB;AAAA,EAED,KAAK,OAAO,WAAW,IAAI;AACzB,WAAO;AAAA,EACR;AACH;AAEAQ,EAAW,kBAAkB,CAAAiC,MAAa;AACxC,EAAAlC,IAAUkC;AACZ;AAEA,IAAAC,IAAiBlC;AACjBA,EAAW,UAAUA;AAErBjB,EAAK,mBAAmBiB,CAAU;AAClCzB,EAAS,mBAAmByB,CAAU;","x_google_ignoreList":[0]}
@@ -1,22 +0,0 @@
1
- let s = {
2
- comma(t) {
3
- return s.split(t, [","], !0);
4
- },
5
- space(t) {
6
- let i = [" ", `
7
- `, " "];
8
- return s.split(t, i);
9
- },
10
- split(t, i, c) {
11
- let r = [], l = "", a = !1, f = 0, u = !1, n = "", p = !1;
12
- for (let e of t)
13
- p ? p = !1 : e === "\\" ? p = !0 : u ? e === n && (u = !1) : e === '"' || e === "'" ? (u = !0, n = e) : e === "(" ? f += 1 : e === ")" ? f > 0 && (f -= 1) : f === 0 && i.includes(e) && (a = !0), a ? (l !== "" && r.push(l.trim()), l = "", a = !1) : l += e;
14
- return (c || l !== "") && r.push(l.trim()), r;
15
- }
16
- };
17
- var o = s;
18
- s.default = s;
19
- export {
20
- o as l
21
- };
22
- //# sourceMappingURL=list.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"list.js","sources":["../../../../node_modules/postcss/lib/list.js"],"sourcesContent":["'use strict'\n\nlet list = {\n comma(string) {\n return list.split(string, [','], true)\n },\n\n space(string) {\n let spaces = [' ', '\\n', '\\t']\n return list.split(string, spaces)\n },\n\n split(string, separators, last) {\n let array = []\n let current = ''\n let split = false\n\n let func = 0\n let inQuote = false\n let prevQuote = ''\n let escape = false\n\n for (let letter of string) {\n if (escape) {\n escape = false\n } else if (letter === '\\\\') {\n escape = true\n } else if (inQuote) {\n if (letter === prevQuote) {\n inQuote = false\n }\n } else if (letter === '\"' || letter === \"'\") {\n inQuote = true\n prevQuote = letter\n } else if (letter === '(') {\n func += 1\n } else if (letter === ')') {\n if (func > 0) func -= 1\n } else if (func === 0) {\n if (separators.includes(letter)) split = true\n }\n\n if (split) {\n if (current !== '') array.push(current.trim())\n current = ''\n split = false\n } else {\n current += letter\n }\n }\n\n if (last || current !== '') array.push(current.trim())\n return array\n }\n}\n\nmodule.exports = list\nlist.default = list\n"],"names":["list","string","spaces","separators","last","array","current","split","func","inQuote","prevQuote","escape","letter","list_1"],"mappings":"AAEA,IAAIA,IAAO;AAAA,EACT,MAAMC,GAAQ;AACZ,WAAOD,EAAK,MAAMC,GAAQ,CAAC,GAAG,GAAG,EAAI;AAAA,EACtC;AAAA,EAED,MAAMA,GAAQ;AACZ,QAAIC,IAAS,CAAC,KAAK;AAAA,GAAM,GAAI;AAC7B,WAAOF,EAAK,MAAMC,GAAQC,CAAM;AAAA,EACjC;AAAA,EAED,MAAMD,GAAQE,GAAYC,GAAM;AAC9B,QAAIC,IAAQ,CAAE,GACVC,IAAU,IACVC,IAAQ,IAERC,IAAO,GACPC,IAAU,IACVC,IAAY,IACZC,IAAS;AAEb,aAASC,KAAUX;AACjB,MAAIU,IACFA,IAAS,KACAC,MAAW,OACpBD,IAAS,KACAF,IACLG,MAAWF,MACbD,IAAU,MAEHG,MAAW,OAAOA,MAAW,OACtCH,IAAU,IACVC,IAAYE,KACHA,MAAW,MACpBJ,KAAQ,IACCI,MAAW,MAChBJ,IAAO,MAAGA,KAAQ,KACbA,MAAS,KACdL,EAAW,SAASS,CAAM,MAAGL,IAAQ,KAGvCA,KACED,MAAY,MAAID,EAAM,KAAKC,EAAQ,MAAM,GAC7CA,IAAU,IACVC,IAAQ,MAERD,KAAWM;AAIf,YAAIR,KAAQE,MAAY,OAAID,EAAM,KAAKC,EAAQ,MAAM,GAC9CD;AAAA,EACR;AACH;AAEA,IAAAQ,IAAiBb;AACjBA,EAAK,UAAUA;","x_google_ignoreList":[0]}
@@ -1,167 +0,0 @@
1
- import l from "../../../_virtual/___vite-browser-external.js";
2
- import { i as M } from "./input.js";
3
- let { SourceMapConsumer: f, SourceMapGenerator: n } = l, { dirname: a, relative: g, resolve: d, sep: v } = l, { pathToFileURL: c } = l, U = M, O = !!(f && n), S = !!(a && d && g && v);
4
- class C {
5
- constructor(t, e, s, i) {
6
- this.stringify = t, this.mapOpts = s.map || {}, this.root = e, this.opts = s, this.css = i, this.originalCSS = i, this.usesFileUrls = !this.mapOpts.from && this.mapOpts.absolute, this.memoizedFileURLs = /* @__PURE__ */ new Map(), this.memoizedPaths = /* @__PURE__ */ new Map(), this.memoizedURLs = /* @__PURE__ */ new Map();
7
- }
8
- addAnnotation() {
9
- let t;
10
- this.isInline() ? t = "data:application/json;base64," + this.toBase64(this.map.toString()) : typeof this.mapOpts.annotation == "string" ? t = this.mapOpts.annotation : typeof this.mapOpts.annotation == "function" ? t = this.mapOpts.annotation(this.opts.to, this.root) : t = this.outputFile() + ".map";
11
- let e = `
12
- `;
13
- this.css.includes(`\r
14
- `) && (e = `\r
15
- `), this.css += e + "/*# sourceMappingURL=" + t + " */";
16
- }
17
- applyPrevMaps() {
18
- for (let t of this.previous()) {
19
- let e = this.toUrl(this.path(t.file)), s = t.root || a(t.file), i;
20
- this.mapOpts.sourcesContent === !1 ? (i = new f(t.text), i.sourcesContent && (i.sourcesContent = null)) : i = t.consumer(), this.map.applySourceMap(i, e, this.toUrl(this.path(s)));
21
- }
22
- }
23
- clearAnnotation() {
24
- if (this.mapOpts.annotation !== !1)
25
- if (this.root) {
26
- let t;
27
- for (let e = this.root.nodes.length - 1; e >= 0; e--)
28
- t = this.root.nodes[e], t.type === "comment" && t.text.indexOf("# sourceMappingURL=") === 0 && this.root.removeChild(e);
29
- } else this.css && (this.css = this.css.replace(/\n*\/\*#[\S\s]*?\*\/$/gm, ""));
30
- }
31
- generate() {
32
- if (this.clearAnnotation(), S && O && this.isMap())
33
- return this.generateMap();
34
- {
35
- let t = "";
36
- return this.stringify(this.root, (e) => {
37
- t += e;
38
- }), [t];
39
- }
40
- }
41
- generateMap() {
42
- if (this.root)
43
- this.generateString();
44
- else if (this.previous().length === 1) {
45
- let t = this.previous()[0].consumer();
46
- t.file = this.outputFile(), this.map = n.fromSourceMap(t, {
47
- ignoreInvalidMapping: !0
48
- });
49
- } else
50
- this.map = new n({
51
- file: this.outputFile(),
52
- ignoreInvalidMapping: !0
53
- }), this.map.addMapping({
54
- generated: { column: 0, line: 1 },
55
- original: { column: 0, line: 1 },
56
- source: this.opts.from ? this.toUrl(this.path(this.opts.from)) : "<no source>"
57
- });
58
- return this.isSourcesContent() && this.setSourcesContent(), this.root && this.previous().length > 0 && this.applyPrevMaps(), this.isAnnotation() && this.addAnnotation(), this.isInline() ? [this.css] : [this.css, this.map];
59
- }
60
- generateString() {
61
- this.css = "", this.map = new n({
62
- file: this.outputFile(),
63
- ignoreInvalidMapping: !0
64
- });
65
- let t = 1, e = 1, s = "<no source>", i = {
66
- generated: { column: 0, line: 0 },
67
- original: { column: 0, line: 0 },
68
- source: ""
69
- }, p, h;
70
- this.stringify(this.root, (r, o, u) => {
71
- if (this.css += r, o && u !== "end" && (i.generated.line = t, i.generated.column = e - 1, o.source && o.source.start ? (i.source = this.sourcePath(o), i.original.line = o.source.start.line, i.original.column = o.source.start.column - 1, this.map.addMapping(i)) : (i.source = s, i.original.line = 1, i.original.column = 0, this.map.addMapping(i))), p = r.match(/\n/g), p ? (t += p.length, h = r.lastIndexOf(`
72
- `), e = r.length - h) : e += r.length, o && u !== "start") {
73
- let m = o.parent || { raws: {} };
74
- (!(o.type === "decl" || o.type === "atrule" && !o.nodes) || o !== m.last || m.raws.semicolon) && (o.source && o.source.end ? (i.source = this.sourcePath(o), i.original.line = o.source.end.line, i.original.column = o.source.end.column - 1, i.generated.line = t, i.generated.column = e - 2, this.map.addMapping(i)) : (i.source = s, i.original.line = 1, i.original.column = 0, i.generated.line = t, i.generated.column = e - 1, this.map.addMapping(i)));
75
- }
76
- });
77
- }
78
- isAnnotation() {
79
- return this.isInline() ? !0 : typeof this.mapOpts.annotation < "u" ? this.mapOpts.annotation : this.previous().length ? this.previous().some((t) => t.annotation) : !0;
80
- }
81
- isInline() {
82
- if (typeof this.mapOpts.inline < "u")
83
- return this.mapOpts.inline;
84
- let t = this.mapOpts.annotation;
85
- return typeof t < "u" && t !== !0 ? !1 : this.previous().length ? this.previous().some((e) => e.inline) : !0;
86
- }
87
- isMap() {
88
- return typeof this.opts.map < "u" ? !!this.opts.map : this.previous().length > 0;
89
- }
90
- isSourcesContent() {
91
- return typeof this.mapOpts.sourcesContent < "u" ? this.mapOpts.sourcesContent : this.previous().length ? this.previous().some((t) => t.withContent()) : !0;
92
- }
93
- outputFile() {
94
- return this.opts.to ? this.path(this.opts.to) : this.opts.from ? this.path(this.opts.from) : "to.css";
95
- }
96
- path(t) {
97
- if (this.mapOpts.absolute || t.charCodeAt(0) === 60 || /^\w+:\/\//.test(t)) return t;
98
- let e = this.memoizedPaths.get(t);
99
- if (e) return e;
100
- let s = this.opts.to ? a(this.opts.to) : ".";
101
- typeof this.mapOpts.annotation == "string" && (s = a(d(s, this.mapOpts.annotation)));
102
- let i = g(s, t);
103
- return this.memoizedPaths.set(t, i), i;
104
- }
105
- previous() {
106
- if (!this.previousMaps)
107
- if (this.previousMaps = [], this.root)
108
- this.root.walk((t) => {
109
- if (t.source && t.source.input.map) {
110
- let e = t.source.input.map;
111
- this.previousMaps.includes(e) || this.previousMaps.push(e);
112
- }
113
- });
114
- else {
115
- let t = new U(this.originalCSS, this.opts);
116
- t.map && this.previousMaps.push(t.map);
117
- }
118
- return this.previousMaps;
119
- }
120
- setSourcesContent() {
121
- let t = {};
122
- if (this.root)
123
- this.root.walk((e) => {
124
- if (e.source) {
125
- let s = e.source.input.from;
126
- if (s && !t[s]) {
127
- t[s] = !0;
128
- let i = this.usesFileUrls ? this.toFileUrl(s) : this.toUrl(this.path(s));
129
- this.map.setSourceContent(i, e.source.input.css);
130
- }
131
- }
132
- });
133
- else if (this.css) {
134
- let e = this.opts.from ? this.toUrl(this.path(this.opts.from)) : "<no source>";
135
- this.map.setSourceContent(e, this.css);
136
- }
137
- }
138
- sourcePath(t) {
139
- return this.mapOpts.from ? this.toUrl(this.mapOpts.from) : this.usesFileUrls ? this.toFileUrl(t.source.input.from) : this.toUrl(this.path(t.source.input.from));
140
- }
141
- toBase64(t) {
142
- return Buffer ? Buffer.from(t).toString("base64") : window.btoa(unescape(encodeURIComponent(t)));
143
- }
144
- toFileUrl(t) {
145
- let e = this.memoizedFileURLs.get(t);
146
- if (e) return e;
147
- if (c) {
148
- let s = c(t).toString();
149
- return this.memoizedFileURLs.set(t, s), s;
150
- } else
151
- throw new Error(
152
- "`map.absolute` option is not available in this PostCSS build"
153
- );
154
- }
155
- toUrl(t) {
156
- let e = this.memoizedURLs.get(t);
157
- if (e) return e;
158
- v === "\\" && (t = t.replace(/\\/g, "/"));
159
- let s = encodeURI(t).replace(/[#?]/g, encodeURIComponent);
160
- return this.memoizedURLs.set(t, s), s;
161
- }
162
- }
163
- var I = C;
164
- export {
165
- I as m
166
- };
167
- //# sourceMappingURL=map-generator.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"map-generator.js","sources":["../../../../node_modules/postcss/lib/map-generator.js"],"sourcesContent":["'use strict'\n\nlet { SourceMapConsumer, SourceMapGenerator } = require('source-map-js')\nlet { dirname, relative, resolve, sep } = require('path')\nlet { pathToFileURL } = require('url')\n\nlet Input = require('./input')\n\nlet sourceMapAvailable = Boolean(SourceMapConsumer && SourceMapGenerator)\nlet pathAvailable = Boolean(dirname && resolve && relative && sep)\n\nclass MapGenerator {\n constructor(stringify, root, opts, cssString) {\n this.stringify = stringify\n this.mapOpts = opts.map || {}\n this.root = root\n this.opts = opts\n this.css = cssString\n this.originalCSS = cssString\n this.usesFileUrls = !this.mapOpts.from && this.mapOpts.absolute\n\n this.memoizedFileURLs = new Map()\n this.memoizedPaths = new Map()\n this.memoizedURLs = new Map()\n }\n\n addAnnotation() {\n let content\n\n if (this.isInline()) {\n content =\n 'data:application/json;base64,' + this.toBase64(this.map.toString())\n } else if (typeof this.mapOpts.annotation === 'string') {\n content = this.mapOpts.annotation\n } else if (typeof this.mapOpts.annotation === 'function') {\n content = this.mapOpts.annotation(this.opts.to, this.root)\n } else {\n content = this.outputFile() + '.map'\n }\n let eol = '\\n'\n if (this.css.includes('\\r\\n')) eol = '\\r\\n'\n\n this.css += eol + '/*# sourceMappingURL=' + content + ' */'\n }\n\n applyPrevMaps() {\n for (let prev of this.previous()) {\n let from = this.toUrl(this.path(prev.file))\n let root = prev.root || dirname(prev.file)\n let map\n\n if (this.mapOpts.sourcesContent === false) {\n map = new SourceMapConsumer(prev.text)\n if (map.sourcesContent) {\n map.sourcesContent = null\n }\n } else {\n map = prev.consumer()\n }\n\n this.map.applySourceMap(map, from, this.toUrl(this.path(root)))\n }\n }\n\n clearAnnotation() {\n if (this.mapOpts.annotation === false) return\n\n if (this.root) {\n let node\n for (let i = this.root.nodes.length - 1; i >= 0; i--) {\n node = this.root.nodes[i]\n if (node.type !== 'comment') continue\n if (node.text.indexOf('# sourceMappingURL=') === 0) {\n this.root.removeChild(i)\n }\n }\n } else if (this.css) {\n this.css = this.css.replace(/\\n*\\/\\*#[\\S\\s]*?\\*\\/$/gm, '')\n }\n }\n\n generate() {\n this.clearAnnotation()\n if (pathAvailable && sourceMapAvailable && this.isMap()) {\n return this.generateMap()\n } else {\n let result = ''\n this.stringify(this.root, i => {\n result += i\n })\n return [result]\n }\n }\n\n generateMap() {\n if (this.root) {\n this.generateString()\n } else if (this.previous().length === 1) {\n let prev = this.previous()[0].consumer()\n prev.file = this.outputFile()\n this.map = SourceMapGenerator.fromSourceMap(prev, {\n ignoreInvalidMapping: true\n })\n } else {\n this.map = new SourceMapGenerator({\n file: this.outputFile(),\n ignoreInvalidMapping: true\n })\n this.map.addMapping({\n generated: { column: 0, line: 1 },\n original: { column: 0, line: 1 },\n source: this.opts.from\n ? this.toUrl(this.path(this.opts.from))\n : '<no source>'\n })\n }\n\n if (this.isSourcesContent()) this.setSourcesContent()\n if (this.root && this.previous().length > 0) this.applyPrevMaps()\n if (this.isAnnotation()) this.addAnnotation()\n\n if (this.isInline()) {\n return [this.css]\n } else {\n return [this.css, this.map]\n }\n }\n\n generateString() {\n this.css = ''\n this.map = new SourceMapGenerator({\n file: this.outputFile(),\n ignoreInvalidMapping: true\n })\n\n let line = 1\n let column = 1\n\n let noSource = '<no source>'\n let mapping = {\n generated: { column: 0, line: 0 },\n original: { column: 0, line: 0 },\n source: ''\n }\n\n let lines, last\n this.stringify(this.root, (str, node, type) => {\n this.css += str\n\n if (node && type !== 'end') {\n mapping.generated.line = line\n mapping.generated.column = column - 1\n if (node.source && node.source.start) {\n mapping.source = this.sourcePath(node)\n mapping.original.line = node.source.start.line\n mapping.original.column = node.source.start.column - 1\n this.map.addMapping(mapping)\n } else {\n mapping.source = noSource\n mapping.original.line = 1\n mapping.original.column = 0\n this.map.addMapping(mapping)\n }\n }\n\n lines = str.match(/\\n/g)\n if (lines) {\n line += lines.length\n last = str.lastIndexOf('\\n')\n column = str.length - last\n } else {\n column += str.length\n }\n\n if (node && type !== 'start') {\n let p = node.parent || { raws: {} }\n let childless =\n node.type === 'decl' || (node.type === 'atrule' && !node.nodes)\n if (!childless || node !== p.last || p.raws.semicolon) {\n if (node.source && node.source.end) {\n mapping.source = this.sourcePath(node)\n mapping.original.line = node.source.end.line\n mapping.original.column = node.source.end.column - 1\n mapping.generated.line = line\n mapping.generated.column = column - 2\n this.map.addMapping(mapping)\n } else {\n mapping.source = noSource\n mapping.original.line = 1\n mapping.original.column = 0\n mapping.generated.line = line\n mapping.generated.column = column - 1\n this.map.addMapping(mapping)\n }\n }\n }\n })\n }\n\n isAnnotation() {\n if (this.isInline()) {\n return true\n }\n if (typeof this.mapOpts.annotation !== 'undefined') {\n return this.mapOpts.annotation\n }\n if (this.previous().length) {\n return this.previous().some(i => i.annotation)\n }\n return true\n }\n\n isInline() {\n if (typeof this.mapOpts.inline !== 'undefined') {\n return this.mapOpts.inline\n }\n\n let annotation = this.mapOpts.annotation\n if (typeof annotation !== 'undefined' && annotation !== true) {\n return false\n }\n\n if (this.previous().length) {\n return this.previous().some(i => i.inline)\n }\n return true\n }\n\n isMap() {\n if (typeof this.opts.map !== 'undefined') {\n return !!this.opts.map\n }\n return this.previous().length > 0\n }\n\n isSourcesContent() {\n if (typeof this.mapOpts.sourcesContent !== 'undefined') {\n return this.mapOpts.sourcesContent\n }\n if (this.previous().length) {\n return this.previous().some(i => i.withContent())\n }\n return true\n }\n\n outputFile() {\n if (this.opts.to) {\n return this.path(this.opts.to)\n } else if (this.opts.from) {\n return this.path(this.opts.from)\n } else {\n return 'to.css'\n }\n }\n\n path(file) {\n if (this.mapOpts.absolute) return file\n if (file.charCodeAt(0) === 60 /* `<` */) return file\n if (/^\\w+:\\/\\//.test(file)) return file\n let cached = this.memoizedPaths.get(file)\n if (cached) return cached\n\n let from = this.opts.to ? dirname(this.opts.to) : '.'\n\n if (typeof this.mapOpts.annotation === 'string') {\n from = dirname(resolve(from, this.mapOpts.annotation))\n }\n\n let path = relative(from, file)\n this.memoizedPaths.set(file, path)\n\n return path\n }\n\n previous() {\n if (!this.previousMaps) {\n this.previousMaps = []\n if (this.root) {\n this.root.walk(node => {\n if (node.source && node.source.input.map) {\n let map = node.source.input.map\n if (!this.previousMaps.includes(map)) {\n this.previousMaps.push(map)\n }\n }\n })\n } else {\n let input = new Input(this.originalCSS, this.opts)\n if (input.map) this.previousMaps.push(input.map)\n }\n }\n\n return this.previousMaps\n }\n\n setSourcesContent() {\n let already = {}\n if (this.root) {\n this.root.walk(node => {\n if (node.source) {\n let from = node.source.input.from\n if (from && !already[from]) {\n already[from] = true\n let fromUrl = this.usesFileUrls\n ? this.toFileUrl(from)\n : this.toUrl(this.path(from))\n this.map.setSourceContent(fromUrl, node.source.input.css)\n }\n }\n })\n } else if (this.css) {\n let from = this.opts.from\n ? this.toUrl(this.path(this.opts.from))\n : '<no source>'\n this.map.setSourceContent(from, this.css)\n }\n }\n\n sourcePath(node) {\n if (this.mapOpts.from) {\n return this.toUrl(this.mapOpts.from)\n } else if (this.usesFileUrls) {\n return this.toFileUrl(node.source.input.from)\n } else {\n return this.toUrl(this.path(node.source.input.from))\n }\n }\n\n toBase64(str) {\n if (Buffer) {\n return Buffer.from(str).toString('base64')\n } else {\n return window.btoa(unescape(encodeURIComponent(str)))\n }\n }\n\n toFileUrl(path) {\n let cached = this.memoizedFileURLs.get(path)\n if (cached) return cached\n\n if (pathToFileURL) {\n let fileURL = pathToFileURL(path).toString()\n this.memoizedFileURLs.set(path, fileURL)\n\n return fileURL\n } else {\n throw new Error(\n '`map.absolute` option is not available in this PostCSS build'\n )\n }\n }\n\n toUrl(path) {\n let cached = this.memoizedURLs.get(path)\n if (cached) return cached\n\n if (sep === '\\\\') {\n path = path.replace(/\\\\/g, '/')\n }\n\n let url = encodeURI(path).replace(/[#?]/g, encodeURIComponent)\n this.memoizedURLs.set(path, url)\n\n return url\n }\n}\n\nmodule.exports = MapGenerator\n"],"names":["SourceMapConsumer","SourceMapGenerator","require$$0","dirname","relative","resolve","sep","require$$1","pathToFileURL","require$$2","Input","require$$3","sourceMapAvailable","pathAvailable","MapGenerator","stringify","root","opts","cssString","content","eol","prev","from","map","node","i","result","line","column","noSource","mapping","lines","last","str","type","p","annotation","file","cached","path","input","already","fromUrl","fileURL","url","mapGenerator"],"mappings":";;AAEA,IAAI,EAAE,mBAAAA,GAAmB,oBAAAC,EAAkB,IAAKC,GAC5C,EAAE,SAAAC,GAAS,UAAAC,GAAU,SAAAC,GAAS,KAAAC,EAAK,IAAGC,GACtC,EAAE,eAAAC,EAAe,IAAGC,GAEpBC,IAAQC,GAERC,IAAqB,GAAQZ,KAAqBC,IAClDY,IAAgB,GAAQV,KAAWE,KAAWD,KAAYE;AAE9D,MAAMQ,EAAa;AAAA,EACjB,YAAYC,GAAWC,GAAMC,GAAMC,GAAW;AAC5C,SAAK,YAAYH,GACjB,KAAK,UAAUE,EAAK,OAAO,CAAE,GAC7B,KAAK,OAAOD,GACZ,KAAK,OAAOC,GACZ,KAAK,MAAMC,GACX,KAAK,cAAcA,GACnB,KAAK,eAAe,CAAC,KAAK,QAAQ,QAAQ,KAAK,QAAQ,UAEvD,KAAK,mBAAmB,oBAAI,IAAK,GACjC,KAAK,gBAAgB,oBAAI,IAAK,GAC9B,KAAK,eAAe,oBAAI,IAAK;AAAA,EAC9B;AAAA,EAED,gBAAgB;AACd,QAAIC;AAEJ,IAAI,KAAK,aACPA,IACE,kCAAkC,KAAK,SAAS,KAAK,IAAI,SAAQ,CAAE,IAC5D,OAAO,KAAK,QAAQ,cAAe,WAC5CA,IAAU,KAAK,QAAQ,aACd,OAAO,KAAK,QAAQ,cAAe,aAC5CA,IAAU,KAAK,QAAQ,WAAW,KAAK,KAAK,IAAI,KAAK,IAAI,IAEzDA,IAAU,KAAK,WAAU,IAAK;AAEhC,QAAIC,IAAM;AAAA;AAC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