Amitkumar001 commited on
Commit
a1aa538
·
verified ·
1 Parent(s): 5c760db

Upload folder using huggingface_hub (part 4)

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. web/node_modules/arg/README.md +317 -0
  2. web/node_modules/arg/package.json +28 -0
  3. web/node_modules/autoprefixer/LICENSE +20 -0
  4. web/node_modules/autoprefixer/README.md +53 -0
  5. web/node_modules/autoprefixer/bin/autoprefixer +22 -0
  6. web/node_modules/autoprefixer/data/prefixes.js +1141 -0
  7. web/node_modules/autoprefixer/lib/at-rule.js +35 -0
  8. web/node_modules/autoprefixer/lib/autoprefixer.d.ts +95 -0
  9. web/node_modules/autoprefixer/lib/autoprefixer.js +164 -0
  10. web/node_modules/autoprefixer/lib/brackets.js +55 -0
  11. web/node_modules/autoprefixer/lib/browsers.js +79 -0
  12. web/node_modules/autoprefixer/lib/declaration.js +187 -0
  13. web/node_modules/autoprefixer/lib/hacks/align-content.js +49 -0
  14. web/node_modules/autoprefixer/lib/hacks/align-items.js +46 -0
  15. web/node_modules/autoprefixer/lib/hacks/align-self.js +56 -0
  16. web/node_modules/autoprefixer/lib/hacks/animation.js +17 -0
  17. web/node_modules/autoprefixer/lib/hacks/appearance.js +23 -0
  18. web/node_modules/autoprefixer/lib/hacks/autofill.js +26 -0
  19. web/node_modules/autoprefixer/lib/hacks/backdrop-filter.js +20 -0
  20. web/node_modules/autoprefixer/lib/hacks/background-clip.js +24 -0
  21. web/node_modules/autoprefixer/lib/hacks/background-size.js +23 -0
  22. web/node_modules/autoprefixer/lib/hacks/block-logical.js +40 -0
  23. web/node_modules/autoprefixer/lib/hacks/border-image.js +15 -0
  24. web/node_modules/autoprefixer/lib/hacks/border-radius.js +40 -0
  25. web/node_modules/autoprefixer/lib/hacks/break-props.js +63 -0
  26. web/node_modules/autoprefixer/lib/hacks/cross-fade.js +35 -0
  27. web/node_modules/autoprefixer/lib/hacks/display-flex.js +65 -0
  28. web/node_modules/autoprefixer/lib/hacks/display-grid.js +21 -0
  29. web/node_modules/autoprefixer/lib/hacks/file-selector-button.js +26 -0
  30. web/node_modules/autoprefixer/lib/hacks/filter-value.js +14 -0
  31. web/node_modules/autoprefixer/lib/hacks/filter.js +19 -0
  32. web/node_modules/autoprefixer/lib/hacks/flex-basis.js +39 -0
  33. web/node_modules/autoprefixer/lib/hacks/flex-direction.js +72 -0
  34. web/node_modules/autoprefixer/lib/hacks/flex-flow.js +53 -0
  35. web/node_modules/autoprefixer/lib/hacks/flex-grow.js +30 -0
  36. web/node_modules/autoprefixer/lib/hacks/flex-shrink.js +39 -0
  37. web/node_modules/autoprefixer/lib/hacks/flex-spec.js +19 -0
  38. web/node_modules/autoprefixer/lib/hacks/flex-wrap.js +19 -0
  39. web/node_modules/autoprefixer/lib/hacks/flex.js +54 -0
  40. web/node_modules/autoprefixer/lib/hacks/fullscreen.js +20 -0
  41. web/node_modules/autoprefixer/lib/hacks/gradient.js +460 -0
  42. web/node_modules/autoprefixer/lib/hacks/grid-area.js +34 -0
  43. web/node_modules/autoprefixer/lib/hacks/grid-column-align.js +28 -0
  44. web/node_modules/autoprefixer/lib/hacks/grid-end.js +52 -0
  45. web/node_modules/autoprefixer/lib/hacks/grid-row-align.js +28 -0
  46. web/node_modules/autoprefixer/lib/hacks/grid-row-column.js +33 -0
  47. web/node_modules/autoprefixer/lib/hacks/grid-rows-columns.js +125 -0
  48. web/node_modules/autoprefixer/lib/hacks/grid-start.js +33 -0
  49. web/node_modules/autoprefixer/lib/hacks/grid-template-areas.js +84 -0
  50. web/node_modules/autoprefixer/lib/hacks/grid-template.js +69 -0
web/node_modules/arg/README.md ADDED
@@ -0,0 +1,317 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Arg
2
+
3
+ `arg` is an unopinionated, no-frills CLI argument parser.
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ npm install arg
9
+ ```
10
+
11
+ ## Usage
12
+
13
+ `arg()` takes either 1 or 2 arguments:
14
+
15
+ 1. Command line specification object (see below)
16
+ 2. Parse options (_Optional_, defaults to `{permissive: false, argv: process.argv.slice(2), stopAtPositional: false}`)
17
+
18
+ It returns an object with any values present on the command-line (missing options are thus
19
+ missing from the resulting object). Arg performs no validation/requirement checking - we
20
+ leave that up to the application.
21
+
22
+ All parameters that aren't consumed by options (commonly referred to as "extra" parameters)
23
+ are added to `result._`, which is _always_ an array (even if no extra parameters are passed,
24
+ in which case an empty array is returned).
25
+
26
+ ```javascript
27
+ const arg = require('arg');
28
+
29
+ // `options` is an optional parameter
30
+ const args = arg(
31
+ spec,
32
+ (options = { permissive: false, argv: process.argv.slice(2) })
33
+ );
34
+ ```
35
+
36
+ For example:
37
+
38
+ ```console
39
+ $ node ./hello.js --verbose -vvv --port=1234 -n 'My name' foo bar --tag qux --tag=qix -- --foobar
40
+ ```
41
+
42
+ ```javascript
43
+ // hello.js
44
+ const arg = require('arg');
45
+
46
+ const args = arg({
47
+ // Types
48
+ '--help': Boolean,
49
+ '--version': Boolean,
50
+ '--verbose': arg.COUNT, // Counts the number of times --verbose is passed
51
+ '--port': Number, // --port <number> or --port=<number>
52
+ '--name': String, // --name <string> or --name=<string>
53
+ '--tag': [String], // --tag <string> or --tag=<string>
54
+
55
+ // Aliases
56
+ '-v': '--verbose',
57
+ '-n': '--name', // -n <string>; result is stored in --name
58
+ '--label': '--name' // --label <string> or --label=<string>;
59
+ // result is stored in --name
60
+ });
61
+
62
+ console.log(args);
63
+ /*
64
+ {
65
+ _: ["foo", "bar", "--foobar"],
66
+ '--port': 1234,
67
+ '--verbose': 4,
68
+ '--name': "My name",
69
+ '--tag': ["qux", "qix"]
70
+ }
71
+ */
72
+ ```
73
+
74
+ The values for each key=&gt;value pair is either a type (function or [function]) or a string (indicating an alias).
75
+
76
+ - In the case of a function, the string value of the argument's value is passed to it,
77
+ and the return value is used as the ultimate value.
78
+
79
+ - In the case of an array, the only element _must_ be a type function. Array types indicate
80
+ that the argument may be passed multiple times, and as such the resulting value in the returned
81
+ object is an array with all of the values that were passed using the specified flag.
82
+
83
+ - In the case of a string, an alias is established. If a flag is passed that matches the _key_,
84
+ then the _value_ is substituted in its place.
85
+
86
+ Type functions are passed three arguments:
87
+
88
+ 1. The parameter value (always a string)
89
+ 2. The parameter name (e.g. `--label`)
90
+ 3. The previous value for the destination (useful for reduce-like operations or for supporting `-v` multiple times, etc.)
91
+
92
+ This means the built-in `String`, `Number`, and `Boolean` type constructors "just work" as type functions.
93
+
94
+ Note that `Boolean` and `[Boolean]` have special treatment - an option argument is _not_ consumed or passed, but instead `true` is
95
+ returned. These options are called "flags".
96
+
97
+ For custom handlers that wish to behave as flags, you may pass the function through `arg.flag()`:
98
+
99
+ ```javascript
100
+ const arg = require('arg');
101
+
102
+ const argv = [
103
+ '--foo',
104
+ 'bar',
105
+ '-ff',
106
+ 'baz',
107
+ '--foo',
108
+ '--foo',
109
+ 'qux',
110
+ '-fff',
111
+ 'qix'
112
+ ];
113
+
114
+ function myHandler(value, argName, previousValue) {
115
+ /* `value` is always `true` */
116
+ return 'na ' + (previousValue || 'batman!');
117
+ }
118
+
119
+ const args = arg(
120
+ {
121
+ '--foo': arg.flag(myHandler),
122
+ '-f': '--foo'
123
+ },
124
+ {
125
+ argv
126
+ }
127
+ );
128
+
129
+ console.log(args);
130
+ /*
131
+ {
132
+ _: ['bar', 'baz', 'qux', 'qix'],
133
+ '--foo': 'na na na na na na na na batman!'
134
+ }
135
+ */
136
+ ```
137
+
138
+ As well, `arg` supplies a helper argument handler called `arg.COUNT`, which equivalent to a `[Boolean]` argument's `.length`
139
+ property - effectively counting the number of times the boolean flag, denoted by the key, is passed on the command line..
140
+ For example, this is how you could implement `ssh`'s multiple levels of verbosity (`-vvvv` being the most verbose).
141
+
142
+ ```javascript
143
+ const arg = require('arg');
144
+
145
+ const argv = ['-AAAA', '-BBBB'];
146
+
147
+ const args = arg(
148
+ {
149
+ '-A': arg.COUNT,
150
+ '-B': [Boolean]
151
+ },
152
+ {
153
+ argv
154
+ }
155
+ );
156
+
157
+ console.log(args);
158
+ /*
159
+ {
160
+ _: [],
161
+ '-A': 4,
162
+ '-B': [true, true, true, true]
163
+ }
164
+ */
165
+ ```
166
+
167
+ ### Options
168
+
169
+ If a second parameter is specified and is an object, it specifies parsing options to modify the behavior of `arg()`.
170
+
171
+ #### `argv`
172
+
173
+ If you have already sliced or generated a number of raw arguments to be parsed (as opposed to letting `arg`
174
+ slice them from `process.argv`) you may specify them in the `argv` option.
175
+
176
+ For example:
177
+
178
+ ```javascript
179
+ const args = arg(
180
+ {
181
+ '--foo': String
182
+ },
183
+ {
184
+ argv: ['hello', '--foo', 'world']
185
+ }
186
+ );
187
+ ```
188
+
189
+ results in:
190
+
191
+ ```javascript
192
+ const args = {
193
+ _: ['hello'],
194
+ '--foo': 'world'
195
+ };
196
+ ```
197
+
198
+ #### `permissive`
199
+
200
+ When `permissive` set to `true`, `arg` will push any unknown arguments
201
+ onto the "extra" argument array (`result._`) instead of throwing an error about
202
+ an unknown flag.
203
+
204
+ For example:
205
+
206
+ ```javascript
207
+ const arg = require('arg');
208
+
209
+ const argv = [
210
+ '--foo',
211
+ 'hello',
212
+ '--qux',
213
+ 'qix',
214
+ '--bar',
215
+ '12345',
216
+ 'hello again'
217
+ ];
218
+
219
+ const args = arg(
220
+ {
221
+ '--foo': String,
222
+ '--bar': Number
223
+ },
224
+ {
225
+ argv,
226
+ permissive: true
227
+ }
228
+ );
229
+ ```
230
+
231
+ results in:
232
+
233
+ ```javascript
234
+ const args = {
235
+ _: ['--qux', 'qix', 'hello again'],
236
+ '--foo': 'hello',
237
+ '--bar': 12345
238
+ };
239
+ ```
240
+
241
+ #### `stopAtPositional`
242
+
243
+ When `stopAtPositional` is set to `true`, `arg` will halt parsing at the first
244
+ positional argument.
245
+
246
+ For example:
247
+
248
+ ```javascript
249
+ const arg = require('arg');
250
+
251
+ const argv = ['--foo', 'hello', '--bar'];
252
+
253
+ const args = arg(
254
+ {
255
+ '--foo': Boolean,
256
+ '--bar': Boolean
257
+ },
258
+ {
259
+ argv,
260
+ stopAtPositional: true
261
+ }
262
+ );
263
+ ```
264
+
265
+ results in:
266
+
267
+ ```javascript
268
+ const args = {
269
+ _: ['hello', '--bar'],
270
+ '--foo': true
271
+ };
272
+ ```
273
+
274
+ ### Errors
275
+
276
+ Some errors that `arg` throws provide a `.code` property in order to aid in recovering from user error, or to
277
+ differentiate between user error and developer error (bug).
278
+
279
+ ##### ARG_UNKNOWN_OPTION
280
+
281
+ If an unknown option (not defined in the spec object) is passed, an error with code `ARG_UNKNOWN_OPTION` will be thrown:
282
+
283
+ ```js
284
+ // cli.js
285
+ try {
286
+ require('arg')({ '--hi': String });
287
+ } catch (err) {
288
+ if (err.code === 'ARG_UNKNOWN_OPTION') {
289
+ console.log(err.message);
290
+ } else {
291
+ throw err;
292
+ }
293
+ }
294
+ ```
295
+
296
+ ```shell
297
+ node cli.js --extraneous true
298
+ Unknown or unexpected option: --extraneous
299
+ ```
300
+
301
+ # FAQ
302
+
303
+ A few questions and answers that have been asked before:
304
+
305
+ ### How do I require an argument with `arg`?
306
+
307
+ Do the assertion yourself, such as:
308
+
309
+ ```javascript
310
+ const args = arg({ '--name': String });
311
+
312
+ if (!args['--name']) throw new Error('missing required argument: --name');
313
+ ```
314
+
315
+ # License
316
+
317
+ Released under the [MIT License](LICENSE.md).
web/node_modules/arg/package.json ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "name": "arg",
3
+ "version": "5.0.2",
4
+ "description": "Unopinionated, no-frills CLI argument parser",
5
+ "main": "index.js",
6
+ "types": "index.d.ts",
7
+ "repository": "vercel/arg",
8
+ "author": "Josh Junon <junon@wavetilt.com>",
9
+ "license": "MIT",
10
+ "files": [
11
+ "index.js",
12
+ "index.d.ts"
13
+ ],
14
+ "scripts": {
15
+ "test": "WARN_EXIT=1 jest --coverage -w 2"
16
+ },
17
+ "devDependencies": {
18
+ "chai": "^4.1.1",
19
+ "jest": "^27.0.6",
20
+ "prettier": "^2.3.2"
21
+ },
22
+ "prettier": {
23
+ "arrowParens": "always",
24
+ "singleQuote": true,
25
+ "tabWidth": 2,
26
+ "trailingComma": "none"
27
+ }
28
+ }
web/node_modules/autoprefixer/LICENSE ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ The MIT License (MIT)
2
+
3
+ Copyright 2013 Andrey Sitnik <andrey@sitnik.es>
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy of
6
+ this software and associated documentation files (the "Software"), to deal in
7
+ the Software without restriction, including without limitation the rights to
8
+ use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
9
+ the Software, and to permit persons to whom the Software is furnished to do so,
10
+ subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
17
+ FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
18
+ COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
19
+ IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
20
+ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
web/node_modules/autoprefixer/README.md ADDED
@@ -0,0 +1,53 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Autoprefixer [![Cult Of Martians][cult-img]][cult]
2
+
3
+ <img align="right" width="94" height="71"
4
+ src="https://postcss.github.io/autoprefixer/logo.svg"
5
+ title="Autoprefixer logo by Anton Lovchikov">
6
+
7
+ [PostCSS] plugin to parse CSS and add vendor prefixes to CSS rules using values
8
+ from [Can I Use]. It is recommended by Google and used in Twitter and Alibaba.
9
+
10
+ Write your CSS rules without vendor prefixes (in fact, forget about them
11
+ entirely):
12
+
13
+ ```css
14
+ ::placeholder {
15
+ color: gray;
16
+ }
17
+
18
+ .image {
19
+ width: stretch;
20
+ }
21
+ ```
22
+
23
+ Autoprefixer will use the data based on current browser popularity and property
24
+ support to apply prefixes for you. You can try the [interactive demo]
25
+ of Autoprefixer.
26
+
27
+ ```css
28
+ ::-moz-placeholder {
29
+ color: gray;
30
+ }
31
+ ::placeholder {
32
+ color: gray;
33
+ }
34
+
35
+ .image {
36
+ width: -moz-available;
37
+ width: -webkit-fill-available;
38
+ width: stretch;
39
+ }
40
+ ```
41
+
42
+ Twitter account for news and releases: [@autoprefixer].
43
+
44
+ <a href="https://evilmartians.com/?utm_source=autoprefixer">
45
+ <img src="https://evilmartians.com/badges/sponsored-by-evil-martians.svg" alt="Sponsored by Evil Martians" width="236" height="54">
46
+ </a>
47
+
48
+ [interactive demo]: https://autoprefixer.github.io/
49
+ [@autoprefixer]: https://twitter.com/autoprefixer
50
+ [Can I Use]: https://caniuse.com/
51
+ [cult-img]: https://cultofmartians.com/assets/badges/badge.svg
52
+ [PostCSS]: https://github.com/postcss/postcss
53
+ [cult]: https://cultofmartians.com/tasks/autoprefixer-grid.html
web/node_modules/autoprefixer/bin/autoprefixer ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/usr/bin/env node
2
+
3
+ let mode = process.argv[2]
4
+ if (mode === '--info') {
5
+ process.stdout.write(require('../')().info() + '\n')
6
+ } else if (mode === '--version') {
7
+ process.stdout.write(
8
+ 'autoprefixer ' + require('../package.json').version + '\n'
9
+ )
10
+ } else {
11
+ process.stdout.write(
12
+ 'autoprefix\n' +
13
+ '\n' +
14
+ 'Options:\n' +
15
+ ' --info Show target browsers and used prefixes\n' +
16
+ ' --version Show version number\n' +
17
+ ' --help Show help\n' +
18
+ '\n' +
19
+ 'Usage:\n' +
20
+ ' autoprefixer --info\n'
21
+ )
22
+ }
web/node_modules/autoprefixer/data/prefixes.js ADDED
@@ -0,0 +1,1141 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let unpack = require('caniuse-lite/dist/unpacker/feature')
2
+
3
+ function browsersSort(a, b) {
4
+ a = a.split(' ')
5
+ b = b.split(' ')
6
+ if (a[0] > b[0]) {
7
+ return 1
8
+ } else if (a[0] < b[0]) {
9
+ return -1
10
+ } else {
11
+ return Math.sign(parseFloat(a[1]) - parseFloat(b[1]))
12
+ }
13
+ }
14
+
15
+ // Convert Can I Use data
16
+ function f(data, opts, callback) {
17
+ data = unpack(data)
18
+
19
+ if (!callback) {
20
+ ;[callback, opts] = [opts, {}]
21
+ }
22
+
23
+ let match = opts.match || /\sx($|\s)/
24
+ let need = []
25
+
26
+ for (let browser in data.stats) {
27
+ let versions = data.stats[browser]
28
+ for (let version in versions) {
29
+ let support = versions[version]
30
+ if (support.match(match)) {
31
+ need.push(browser + ' ' + version)
32
+ }
33
+ }
34
+ }
35
+
36
+ callback(need.sort(browsersSort))
37
+ }
38
+
39
+ // Add data for all properties
40
+ let result = {}
41
+
42
+ function prefix(names, data) {
43
+ for (let name of names) {
44
+ result[name] = Object.assign({}, data)
45
+ }
46
+ }
47
+
48
+ function add(names, data) {
49
+ for (let name of names) {
50
+ result[name].browsers = result[name].browsers
51
+ .concat(data.browsers)
52
+ .sort(browsersSort)
53
+ }
54
+ }
55
+
56
+ module.exports = result
57
+
58
+ // Border Radius
59
+ let prefixBorderRadius = require('caniuse-lite/data/features/border-radius')
60
+
61
+ f(prefixBorderRadius, browsers =>
62
+ prefix(
63
+ [
64
+ 'border-radius',
65
+ 'border-top-left-radius',
66
+ 'border-top-right-radius',
67
+ 'border-bottom-right-radius',
68
+ 'border-bottom-left-radius'
69
+ ],
70
+ {
71
+ browsers,
72
+ feature: 'border-radius',
73
+ mistakes: ['-khtml-', '-ms-', '-o-']
74
+ }
75
+ )
76
+ )
77
+
78
+ // Box Shadow
79
+ let prefixBoxshadow = require('caniuse-lite/data/features/css-boxshadow')
80
+
81
+ f(prefixBoxshadow, browsers =>
82
+ prefix(['box-shadow'], {
83
+ browsers,
84
+ feature: 'css-boxshadow',
85
+ mistakes: ['-khtml-']
86
+ })
87
+ )
88
+
89
+ // Animation
90
+ let prefixAnimation = require('caniuse-lite/data/features/css-animation')
91
+
92
+ f(prefixAnimation, browsers =>
93
+ prefix(
94
+ [
95
+ 'animation',
96
+ 'animation-name',
97
+ 'animation-duration',
98
+ 'animation-delay',
99
+ 'animation-direction',
100
+ 'animation-fill-mode',
101
+ 'animation-iteration-count',
102
+ 'animation-play-state',
103
+ 'animation-timing-function',
104
+ '@keyframes'
105
+ ],
106
+ {
107
+ browsers,
108
+ feature: 'css-animation',
109
+ mistakes: ['-khtml-', '-ms-']
110
+ }
111
+ )
112
+ )
113
+
114
+ // Transition
115
+ let prefixTransition = require('caniuse-lite/data/features/css-transitions')
116
+
117
+ f(prefixTransition, browsers =>
118
+ prefix(
119
+ [
120
+ 'transition',
121
+ 'transition-property',
122
+ 'transition-duration',
123
+ 'transition-delay',
124
+ 'transition-timing-function'
125
+ ],
126
+ {
127
+ browsers,
128
+ feature: 'css-transitions',
129
+ mistakes: ['-khtml-', '-ms-']
130
+ }
131
+ )
132
+ )
133
+
134
+ // Transform 2D
135
+ let prefixTransform2d = require('caniuse-lite/data/features/transforms2d')
136
+
137
+ f(prefixTransform2d, browsers =>
138
+ prefix(['transform', 'transform-origin'], {
139
+ browsers,
140
+ feature: 'transforms2d'
141
+ })
142
+ )
143
+
144
+ // Transform 3D
145
+ let prefixTransforms3d = require('caniuse-lite/data/features/transforms3d')
146
+
147
+ f(prefixTransforms3d, browsers => {
148
+ prefix(['perspective', 'perspective-origin'], {
149
+ browsers,
150
+ feature: 'transforms3d'
151
+ })
152
+ return prefix(['transform-style'], {
153
+ browsers,
154
+ feature: 'transforms3d',
155
+ mistakes: ['-ms-', '-o-']
156
+ })
157
+ })
158
+
159
+ f(prefixTransforms3d, { match: /y\sx|y\s#2/ }, browsers =>
160
+ prefix(['backface-visibility'], {
161
+ browsers,
162
+ feature: 'transforms3d',
163
+ mistakes: ['-ms-', '-o-']
164
+ })
165
+ )
166
+
167
+ // Gradients
168
+ let prefixGradients = require('caniuse-lite/data/features/css-gradients')
169
+
170
+ f(prefixGradients, { match: /y\sx/ }, browsers =>
171
+ prefix(
172
+ [
173
+ 'linear-gradient',
174
+ 'repeating-linear-gradient',
175
+ 'radial-gradient',
176
+ 'repeating-radial-gradient'
177
+ ],
178
+ {
179
+ browsers,
180
+ feature: 'css-gradients',
181
+ mistakes: ['-ms-'],
182
+ props: [
183
+ 'background',
184
+ 'background-image',
185
+ 'border-image',
186
+ 'mask',
187
+ 'list-style',
188
+ 'list-style-image',
189
+ 'content',
190
+ 'mask-image'
191
+ ]
192
+ }
193
+ )
194
+ )
195
+
196
+ f(prefixGradients, { match: /a\sx/ }, browsers => {
197
+ browsers = browsers.map(i => {
198
+ if (/firefox|op/.test(i)) {
199
+ return i
200
+ } else {
201
+ return `${i} old`
202
+ }
203
+ })
204
+ return add(
205
+ [
206
+ 'linear-gradient',
207
+ 'repeating-linear-gradient',
208
+ 'radial-gradient',
209
+ 'repeating-radial-gradient'
210
+ ],
211
+ {
212
+ browsers,
213
+ feature: 'css-gradients'
214
+ }
215
+ )
216
+ })
217
+
218
+ // Box sizing
219
+ let prefixBoxsizing = require('caniuse-lite/data/features/css3-boxsizing')
220
+
221
+ f(prefixBoxsizing, browsers =>
222
+ prefix(['box-sizing'], {
223
+ browsers,
224
+ feature: 'css3-boxsizing'
225
+ })
226
+ )
227
+
228
+ // Filter Effects
229
+ let prefixFilters = require('caniuse-lite/data/features/css-filters')
230
+
231
+ f(prefixFilters, browsers =>
232
+ prefix(['filter'], {
233
+ browsers,
234
+ feature: 'css-filters'
235
+ })
236
+ )
237
+
238
+ // filter() function
239
+ let prefixFilterFunction = require('caniuse-lite/data/features/css-filter-function')
240
+
241
+ f(prefixFilterFunction, browsers =>
242
+ prefix(['filter-function'], {
243
+ browsers,
244
+ feature: 'css-filter-function',
245
+ props: [
246
+ 'background',
247
+ 'background-image',
248
+ 'border-image',
249
+ 'mask',
250
+ 'list-style',
251
+ 'list-style-image',
252
+ 'content',
253
+ 'mask-image'
254
+ ]
255
+ })
256
+ )
257
+
258
+ // Backdrop-filter
259
+ let prefixBackdropFilter = require('caniuse-lite/data/features/css-backdrop-filter')
260
+
261
+ f(prefixBackdropFilter, { match: /y\sx|y\s#2/ }, browsers =>
262
+ prefix(['backdrop-filter'], {
263
+ browsers,
264
+ feature: 'css-backdrop-filter'
265
+ })
266
+ )
267
+
268
+ // element() function
269
+ let prefixElementFunction = require('caniuse-lite/data/features/css-element-function')
270
+
271
+ f(prefixElementFunction, browsers =>
272
+ prefix(['element'], {
273
+ browsers,
274
+ feature: 'css-element-function',
275
+ props: [
276
+ 'background',
277
+ 'background-image',
278
+ 'border-image',
279
+ 'mask',
280
+ 'list-style',
281
+ 'list-style-image',
282
+ 'content',
283
+ 'mask-image'
284
+ ]
285
+ })
286
+ )
287
+
288
+ // Multicolumns
289
+ let prefixMulticolumns = require('caniuse-lite/data/features/multicolumn')
290
+
291
+ f(prefixMulticolumns, browsers => {
292
+ prefix(
293
+ [
294
+ 'columns',
295
+ 'column-width',
296
+ 'column-gap',
297
+ 'column-rule',
298
+ 'column-rule-color',
299
+ 'column-rule-width',
300
+ 'column-count',
301
+ 'column-rule-style',
302
+ 'column-span',
303
+ 'column-fill'
304
+ ],
305
+ {
306
+ browsers,
307
+ feature: 'multicolumn'
308
+ }
309
+ )
310
+
311
+ let noff = browsers.filter(i => !/firefox/.test(i))
312
+ prefix(['break-before', 'break-after', 'break-inside'], {
313
+ browsers: noff,
314
+ feature: 'multicolumn'
315
+ })
316
+ })
317
+
318
+ // User select
319
+ let prefixUserSelect = require('caniuse-lite/data/features/user-select-none')
320
+
321
+ f(prefixUserSelect, browsers =>
322
+ prefix(['user-select'], {
323
+ browsers,
324
+ feature: 'user-select-none',
325
+ mistakes: ['-khtml-']
326
+ })
327
+ )
328
+
329
+ // Flexible Box Layout
330
+ let prefixFlexbox = require('caniuse-lite/data/features/flexbox')
331
+
332
+ f(prefixFlexbox, { match: /a\sx/ }, browsers => {
333
+ browsers = browsers.map(i => {
334
+ if (/ie|firefox/.test(i)) {
335
+ return i
336
+ } else {
337
+ return `${i} 2009`
338
+ }
339
+ })
340
+ prefix(['display-flex', 'inline-flex'], {
341
+ browsers,
342
+ feature: 'flexbox',
343
+ props: ['display']
344
+ })
345
+ prefix(['flex', 'flex-grow', 'flex-shrink', 'flex-basis'], {
346
+ browsers,
347
+ feature: 'flexbox'
348
+ })
349
+ prefix(
350
+ [
351
+ 'flex-direction',
352
+ 'flex-wrap',
353
+ 'flex-flow',
354
+ 'justify-content',
355
+ 'order',
356
+ 'align-items',
357
+ 'align-self',
358
+ 'align-content'
359
+ ],
360
+ {
361
+ browsers,
362
+ feature: 'flexbox'
363
+ }
364
+ )
365
+ })
366
+
367
+ f(prefixFlexbox, { match: /y\sx/ }, browsers => {
368
+ add(['display-flex', 'inline-flex'], {
369
+ browsers,
370
+ feature: 'flexbox'
371
+ })
372
+ add(['flex', 'flex-grow', 'flex-shrink', 'flex-basis'], {
373
+ browsers,
374
+ feature: 'flexbox'
375
+ })
376
+ add(
377
+ [
378
+ 'flex-direction',
379
+ 'flex-wrap',
380
+ 'flex-flow',
381
+ 'justify-content',
382
+ 'order',
383
+ 'align-items',
384
+ 'align-self',
385
+ 'align-content'
386
+ ],
387
+ {
388
+ browsers,
389
+ feature: 'flexbox'
390
+ }
391
+ )
392
+ })
393
+
394
+ // calc() unit
395
+ let prefixCalc = require('caniuse-lite/data/features/calc')
396
+
397
+ f(prefixCalc, browsers =>
398
+ prefix(['calc'], {
399
+ browsers,
400
+ feature: 'calc',
401
+ props: ['*']
402
+ })
403
+ )
404
+
405
+ // Background options
406
+ let prefixBackgroundOptions = require('caniuse-lite/data/features/background-img-opts')
407
+
408
+ f(prefixBackgroundOptions, browsers =>
409
+ prefix(['background-origin', 'background-size'], {
410
+ browsers,
411
+ feature: 'background-img-opts'
412
+ })
413
+ )
414
+
415
+ // background-clip: text
416
+ let prefixBackgroundClipText = require('caniuse-lite/data/features/background-clip-text')
417
+
418
+ f(prefixBackgroundClipText, browsers =>
419
+ prefix(['background-clip'], {
420
+ browsers,
421
+ feature: 'background-clip-text'
422
+ })
423
+ )
424
+
425
+ // Font feature settings
426
+ let prefixFontFeature = require('caniuse-lite/data/features/font-feature')
427
+
428
+ f(prefixFontFeature, browsers =>
429
+ prefix(
430
+ [
431
+ 'font-feature-settings',
432
+ 'font-variant-ligatures',
433
+ 'font-language-override'
434
+ ],
435
+ {
436
+ browsers,
437
+ feature: 'font-feature'
438
+ }
439
+ )
440
+ )
441
+
442
+ // CSS font-kerning property
443
+ let prefixFontKerning = require('caniuse-lite/data/features/font-kerning')
444
+
445
+ f(prefixFontKerning, browsers =>
446
+ prefix(['font-kerning'], {
447
+ browsers,
448
+ feature: 'font-kerning'
449
+ })
450
+ )
451
+
452
+ // Border image
453
+ let prefixBorderImage = require('caniuse-lite/data/features/border-image')
454
+
455
+ f(prefixBorderImage, browsers =>
456
+ prefix(['border-image'], {
457
+ browsers,
458
+ feature: 'border-image'
459
+ })
460
+ )
461
+
462
+ // Selection selector
463
+ let prefixSelection = require('caniuse-lite/data/features/css-selection')
464
+
465
+ f(prefixSelection, browsers =>
466
+ prefix(['::selection'], {
467
+ browsers,
468
+ feature: 'css-selection',
469
+ selector: true
470
+ })
471
+ )
472
+
473
+ // Placeholder selector
474
+ let prefixPlaceholder = require('caniuse-lite/data/features/css-placeholder')
475
+
476
+ f(prefixPlaceholder, browsers => {
477
+ prefix(['::placeholder'], {
478
+ browsers: browsers.concat(['ie 10 old', 'ie 11 old', 'firefox 18 old']),
479
+ feature: 'css-placeholder',
480
+ selector: true
481
+ })
482
+ })
483
+
484
+ // Placeholder-shown selector
485
+ let prefixPlaceholderShown = require('caniuse-lite/data/features/css-placeholder-shown')
486
+
487
+ f(prefixPlaceholderShown, browsers => {
488
+ prefix([':placeholder-shown'], {
489
+ browsers,
490
+ feature: 'css-placeholder-shown',
491
+ selector: true
492
+ })
493
+ })
494
+
495
+ // Hyphenation
496
+ let prefixHyphens = require('caniuse-lite/data/features/css-hyphens')
497
+
498
+ f(prefixHyphens, browsers =>
499
+ prefix(['hyphens'], {
500
+ browsers,
501
+ feature: 'css-hyphens'
502
+ })
503
+ )
504
+
505
+ // Fullscreen selector
506
+ let prefixFullscreen = require('caniuse-lite/data/features/fullscreen')
507
+
508
+ f(prefixFullscreen, browsers =>
509
+ prefix([':fullscreen'], {
510
+ browsers,
511
+ feature: 'fullscreen',
512
+ selector: true
513
+ })
514
+ )
515
+
516
+ // ::backdrop pseudo-element
517
+ // https://caniuse.com/mdn-css_selectors_backdrop
518
+ let prefixBackdrop = require('caniuse-lite/data/features/mdn-css-backdrop-pseudo-element')
519
+
520
+ f(prefixBackdrop, browsers =>
521
+ prefix(['::backdrop'], {
522
+ browsers,
523
+ feature: 'backdrop',
524
+ selector: true
525
+ })
526
+ )
527
+
528
+ // File selector button
529
+ let prefixFileSelectorButton = require('caniuse-lite/data/features/css-file-selector-button')
530
+
531
+ f(prefixFileSelectorButton, browsers =>
532
+ prefix(['::file-selector-button'], {
533
+ browsers,
534
+ feature: 'file-selector-button',
535
+ selector: true
536
+ })
537
+ )
538
+
539
+ // :autofill
540
+ let prefixAutofill = require('caniuse-lite/data/features/css-autofill')
541
+
542
+ f(prefixAutofill, browsers =>
543
+ prefix([':autofill'], {
544
+ browsers,
545
+ feature: 'css-autofill',
546
+ selector: true
547
+ })
548
+ )
549
+
550
+ // Tab size
551
+ let prefixTabsize = require('caniuse-lite/data/features/css3-tabsize')
552
+
553
+ f(prefixTabsize, browsers =>
554
+ prefix(['tab-size'], {
555
+ browsers,
556
+ feature: 'css3-tabsize'
557
+ })
558
+ )
559
+
560
+ // Intrinsic & extrinsic sizing
561
+ let prefixIntrinsic = require('caniuse-lite/data/features/intrinsic-width')
562
+
563
+ let sizeProps = [
564
+ 'width',
565
+ 'min-width',
566
+ 'max-width',
567
+ 'height',
568
+ 'min-height',
569
+ 'max-height',
570
+ 'inline-size',
571
+ 'min-inline-size',
572
+ 'max-inline-size',
573
+ 'block-size',
574
+ 'min-block-size',
575
+ 'max-block-size',
576
+ 'grid',
577
+ 'grid-template',
578
+ 'grid-template-rows',
579
+ 'grid-template-columns',
580
+ 'grid-auto-columns',
581
+ 'grid-auto-rows'
582
+ ]
583
+
584
+ f(prefixIntrinsic, browsers =>
585
+ prefix(['max-content', 'min-content'], {
586
+ browsers,
587
+ feature: 'intrinsic-width',
588
+ props: sizeProps
589
+ })
590
+ )
591
+
592
+ f(prefixIntrinsic, { match: /x|\s#4/ }, browsers =>
593
+ prefix(['fill', 'fill-available'], {
594
+ browsers,
595
+ feature: 'intrinsic-width',
596
+ props: sizeProps
597
+ })
598
+ )
599
+
600
+ f(prefixIntrinsic, { match: /x|\s#5/ }, browsers => {
601
+ let ffFix = browsers.filter(i => {
602
+ let [name, version] = i.split(' ')
603
+ if (name === 'firefox' || name === 'and_ff') {
604
+ return parseInt(version) < 94
605
+ } else {
606
+ return true
607
+ }
608
+ })
609
+ return prefix(['fit-content'], {
610
+ browsers: ffFix,
611
+ feature: 'intrinsic-width',
612
+ props: sizeProps
613
+ })
614
+ })
615
+
616
+ // Stretch value
617
+
618
+ let prefixStretch = require('caniuse-lite/data/features/css-width-stretch')
619
+
620
+ f(prefixStretch, browsers => {
621
+ f(prefixIntrinsic, { match: /x|\s#2/ }, firefox => {
622
+ browsers = browsers.concat(firefox)
623
+ })
624
+ return prefix(['stretch'], {
625
+ browsers,
626
+ feature: 'css-width-stretch',
627
+ props: sizeProps
628
+ })
629
+ })
630
+
631
+ // Zoom cursors
632
+ let prefixCursorsNew = require('caniuse-lite/data/features/css3-cursors-newer')
633
+
634
+ f(prefixCursorsNew, browsers =>
635
+ prefix(['zoom-in', 'zoom-out'], {
636
+ browsers,
637
+ feature: 'css3-cursors-newer',
638
+ props: ['cursor']
639
+ })
640
+ )
641
+
642
+ // Grab cursors
643
+ let prefixCursorsGrab = require('caniuse-lite/data/features/css3-cursors-grab')
644
+
645
+ f(prefixCursorsGrab, browsers =>
646
+ prefix(['grab', 'grabbing'], {
647
+ browsers,
648
+ feature: 'css3-cursors-grab',
649
+ props: ['cursor']
650
+ })
651
+ )
652
+
653
+ // Sticky position
654
+ let prefixSticky = require('caniuse-lite/data/features/css-sticky')
655
+
656
+ f(prefixSticky, browsers =>
657
+ prefix(['sticky'], {
658
+ browsers,
659
+ feature: 'css-sticky',
660
+ props: ['position']
661
+ })
662
+ )
663
+
664
+ // Pointer Events
665
+ let prefixPointer = require('caniuse-lite/data/features/pointer')
666
+
667
+ f(prefixPointer, browsers =>
668
+ prefix(['touch-action'], {
669
+ browsers,
670
+ feature: 'pointer'
671
+ })
672
+ )
673
+
674
+ // Text decoration
675
+ let prefixDecoration = require('caniuse-lite/data/features/text-decoration')
676
+
677
+ f(prefixDecoration, { match: /x.*#[235]/ }, browsers =>
678
+ prefix(['text-decoration-skip', 'text-decoration-skip-ink'], {
679
+ browsers,
680
+ feature: 'text-decoration'
681
+ })
682
+ )
683
+
684
+ let prefixDecorationShorthand = require('caniuse-lite/data/features/mdn-text-decoration-shorthand')
685
+
686
+ f(prefixDecorationShorthand, browsers =>
687
+ prefix(['text-decoration'], {
688
+ browsers,
689
+ feature: 'text-decoration'
690
+ })
691
+ )
692
+
693
+ let prefixDecorationColor = require('caniuse-lite/data/features/mdn-text-decoration-color')
694
+
695
+ f(prefixDecorationColor, browsers =>
696
+ prefix(['text-decoration-color'], {
697
+ browsers,
698
+ feature: 'text-decoration'
699
+ })
700
+ )
701
+
702
+ let prefixDecorationLine = require('caniuse-lite/data/features/mdn-text-decoration-line')
703
+
704
+ f(prefixDecorationLine, browsers =>
705
+ prefix(['text-decoration-line'], {
706
+ browsers,
707
+ feature: 'text-decoration'
708
+ })
709
+ )
710
+
711
+ let prefixDecorationStyle = require('caniuse-lite/data/features/mdn-text-decoration-style')
712
+
713
+ f(prefixDecorationStyle, browsers =>
714
+ prefix(['text-decoration-style'], {
715
+ browsers,
716
+ feature: 'text-decoration'
717
+ })
718
+ )
719
+
720
+ // Text Size Adjust
721
+ let prefixTextSizeAdjust = require('caniuse-lite/data/features/text-size-adjust')
722
+
723
+ f(prefixTextSizeAdjust, browsers =>
724
+ prefix(['text-size-adjust'], {
725
+ browsers,
726
+ feature: 'text-size-adjust'
727
+ })
728
+ )
729
+
730
+ // CSS Masks
731
+ let prefixCssMasks = require('caniuse-lite/data/features/css-masks')
732
+
733
+ f(prefixCssMasks, browsers => {
734
+ prefix(
735
+ [
736
+ 'mask-clip',
737
+ 'mask-composite',
738
+ 'mask-image',
739
+ 'mask-origin',
740
+ 'mask-repeat',
741
+ 'mask-border-repeat',
742
+ 'mask-border-source'
743
+ ],
744
+ {
745
+ browsers,
746
+ feature: 'css-masks'
747
+ }
748
+ )
749
+ prefix(
750
+ [
751
+ 'mask',
752
+ 'mask-position',
753
+ 'mask-position-x',
754
+ 'mask-position-y',
755
+ 'mask-size',
756
+ 'mask-border',
757
+ 'mask-border-outset',
758
+ 'mask-border-width',
759
+ 'mask-border-slice'
760
+ ],
761
+ {
762
+ browsers,
763
+ feature: 'css-masks'
764
+ }
765
+ )
766
+ })
767
+
768
+ // CSS clip-path property
769
+ let prefixClipPath = require('caniuse-lite/data/features/css-clip-path')
770
+
771
+ f(prefixClipPath, browsers =>
772
+ prefix(['clip-path'], {
773
+ browsers,
774
+ feature: 'css-clip-path'
775
+ })
776
+ )
777
+
778
+ // Fragmented Borders and Backgrounds
779
+ let prefixBoxdecoration = require('caniuse-lite/data/features/css-boxdecorationbreak')
780
+
781
+ f(prefixBoxdecoration, browsers =>
782
+ prefix(['box-decoration-break'], {
783
+ browsers,
784
+ feature: 'css-boxdecorationbreak'
785
+ })
786
+ )
787
+
788
+ // CSS3 object-fit/object-position
789
+ let prefixObjectFit = require('caniuse-lite/data/features/object-fit')
790
+
791
+ f(prefixObjectFit, browsers =>
792
+ prefix(['object-fit', 'object-position'], {
793
+ browsers,
794
+ feature: 'object-fit'
795
+ })
796
+ )
797
+
798
+ // CSS Shapes
799
+ let prefixShapes = require('caniuse-lite/data/features/css-shapes')
800
+
801
+ f(prefixShapes, browsers =>
802
+ prefix(['shape-margin', 'shape-outside', 'shape-image-threshold'], {
803
+ browsers,
804
+ feature: 'css-shapes'
805
+ })
806
+ )
807
+
808
+ // CSS3 text-overflow
809
+ let prefixTextOverflow = require('caniuse-lite/data/features/text-overflow')
810
+
811
+ f(prefixTextOverflow, browsers =>
812
+ prefix(['text-overflow'], {
813
+ browsers,
814
+ feature: 'text-overflow'
815
+ })
816
+ )
817
+
818
+ // Viewport at-rule
819
+ let prefixDeviceadaptation = require('caniuse-lite/data/features/css-deviceadaptation')
820
+
821
+ f(prefixDeviceadaptation, browsers =>
822
+ prefix(['@viewport'], {
823
+ browsers,
824
+ feature: 'css-deviceadaptation'
825
+ })
826
+ )
827
+
828
+ // Resolution Media Queries
829
+ let prefixResolut = require('caniuse-lite/data/features/css-media-resolution')
830
+
831
+ f(prefixResolut, { match: /( x($| )|a #2)/ }, browsers =>
832
+ prefix(['@resolution'], {
833
+ browsers,
834
+ feature: 'css-media-resolution'
835
+ })
836
+ )
837
+
838
+ // CSS text-align-last
839
+ let prefixTextAlignLast = require('caniuse-lite/data/features/css-text-align-last')
840
+
841
+ f(prefixTextAlignLast, browsers =>
842
+ prefix(['text-align-last'], {
843
+ browsers,
844
+ feature: 'css-text-align-last'
845
+ })
846
+ )
847
+
848
+ // Crisp Edges Image Rendering Algorithm
849
+ let prefixCrispedges = require('caniuse-lite/data/features/css-crisp-edges')
850
+
851
+ f(prefixCrispedges, { match: /y x|a x #1/ }, browsers =>
852
+ prefix(['pixelated'], {
853
+ browsers,
854
+ feature: 'css-crisp-edges',
855
+ props: ['image-rendering']
856
+ })
857
+ )
858
+
859
+ f(prefixCrispedges, { match: /a x #2/ }, browsers =>
860
+ prefix(['image-rendering'], {
861
+ browsers,
862
+ feature: 'css-crisp-edges'
863
+ })
864
+ )
865
+
866
+ // Logical Properties
867
+ let prefixLogicalProps = require('caniuse-lite/data/features/css-logical-props')
868
+
869
+ f(prefixLogicalProps, browsers =>
870
+ prefix(
871
+ [
872
+ 'border-inline-start',
873
+ 'border-inline-end',
874
+ 'margin-inline-start',
875
+ 'margin-inline-end',
876
+ 'padding-inline-start',
877
+ 'padding-inline-end'
878
+ ],
879
+ {
880
+ browsers,
881
+ feature: 'css-logical-props'
882
+ }
883
+ )
884
+ )
885
+
886
+ f(prefixLogicalProps, { match: /x\s#2/ }, browsers =>
887
+ prefix(
888
+ [
889
+ 'border-block-start',
890
+ 'border-block-end',
891
+ 'margin-block-start',
892
+ 'margin-block-end',
893
+ 'padding-block-start',
894
+ 'padding-block-end'
895
+ ],
896
+ {
897
+ browsers,
898
+ feature: 'css-logical-props'
899
+ }
900
+ )
901
+ )
902
+
903
+ // CSS appearance
904
+ let prefixAppearance = require('caniuse-lite/data/features/css-appearance')
905
+
906
+ f(prefixAppearance, { match: /#2|x/ }, browsers =>
907
+ prefix(['appearance'], {
908
+ browsers,
909
+ feature: 'css-appearance'
910
+ })
911
+ )
912
+
913
+ // CSS Scroll snap points
914
+ let prefixSnappoints = require('caniuse-lite/data/features/css-snappoints')
915
+
916
+ f(prefixSnappoints, browsers =>
917
+ prefix(
918
+ [
919
+ 'scroll-snap-type',
920
+ 'scroll-snap-coordinate',
921
+ 'scroll-snap-destination',
922
+ 'scroll-snap-points-x',
923
+ 'scroll-snap-points-y'
924
+ ],
925
+ {
926
+ browsers,
927
+ feature: 'css-snappoints'
928
+ }
929
+ )
930
+ )
931
+
932
+ // CSS Regions
933
+ let prefixRegions = require('caniuse-lite/data/features/css-regions')
934
+
935
+ f(prefixRegions, browsers =>
936
+ prefix(['flow-into', 'flow-from', 'region-fragment'], {
937
+ browsers,
938
+ feature: 'css-regions'
939
+ })
940
+ )
941
+
942
+ // CSS image-set
943
+ let prefixImageSet = require('caniuse-lite/data/features/css-image-set')
944
+
945
+ f(prefixImageSet, browsers =>
946
+ prefix(['image-set'], {
947
+ browsers,
948
+ feature: 'css-image-set',
949
+ props: [
950
+ 'background',
951
+ 'background-image',
952
+ 'border-image',
953
+ 'cursor',
954
+ 'mask',
955
+ 'mask-image',
956
+ 'list-style',
957
+ 'list-style-image',
958
+ 'content'
959
+ ]
960
+ })
961
+ )
962
+
963
+ // Writing Mode
964
+ let prefixWritingMode = require('caniuse-lite/data/features/css-writing-mode')
965
+
966
+ f(prefixWritingMode, { match: /a|x/ }, browsers =>
967
+ prefix(['writing-mode'], {
968
+ browsers,
969
+ feature: 'css-writing-mode'
970
+ })
971
+ )
972
+
973
+ // Cross-Fade Function
974
+ let prefixCrossFade = require('caniuse-lite/data/features/css-cross-fade')
975
+
976
+ f(prefixCrossFade, browsers =>
977
+ prefix(['cross-fade'], {
978
+ browsers,
979
+ feature: 'css-cross-fade',
980
+ props: [
981
+ 'background',
982
+ 'background-image',
983
+ 'border-image',
984
+ 'mask',
985
+ 'list-style',
986
+ 'list-style-image',
987
+ 'content',
988
+ 'mask-image'
989
+ ]
990
+ })
991
+ )
992
+
993
+ // Read Only selector
994
+ let prefixReadOnly = require('caniuse-lite/data/features/css-read-only-write')
995
+
996
+ f(prefixReadOnly, browsers =>
997
+ prefix([':read-only', ':read-write'], {
998
+ browsers,
999
+ feature: 'css-read-only-write',
1000
+ selector: true
1001
+ })
1002
+ )
1003
+
1004
+ // Text Emphasize
1005
+ let prefixTextEmphasis = require('caniuse-lite/data/features/text-emphasis')
1006
+
1007
+ f(prefixTextEmphasis, browsers =>
1008
+ prefix(
1009
+ [
1010
+ 'text-emphasis',
1011
+ 'text-emphasis-position',
1012
+ 'text-emphasis-style',
1013
+ 'text-emphasis-color'
1014
+ ],
1015
+ {
1016
+ browsers,
1017
+ feature: 'text-emphasis'
1018
+ }
1019
+ )
1020
+ )
1021
+
1022
+ // CSS Grid Layout
1023
+ let prefixGrid = require('caniuse-lite/data/features/css-grid')
1024
+
1025
+ f(prefixGrid, browsers => {
1026
+ prefix(['display-grid', 'inline-grid'], {
1027
+ browsers,
1028
+ feature: 'css-grid',
1029
+ props: ['display']
1030
+ })
1031
+ prefix(
1032
+ [
1033
+ 'grid-template-columns',
1034
+ 'grid-template-rows',
1035
+ 'grid-row-start',
1036
+ 'grid-column-start',
1037
+ 'grid-row-end',
1038
+ 'grid-column-end',
1039
+ 'grid-row',
1040
+ 'grid-column',
1041
+ 'grid-area',
1042
+ 'grid-template',
1043
+ 'grid-template-areas',
1044
+ 'place-self'
1045
+ ],
1046
+ {
1047
+ browsers,
1048
+ feature: 'css-grid'
1049
+ }
1050
+ )
1051
+ })
1052
+
1053
+ f(prefixGrid, { match: /a x/ }, browsers =>
1054
+ prefix(['grid-column-align', 'grid-row-align'], {
1055
+ browsers,
1056
+ feature: 'css-grid'
1057
+ })
1058
+ )
1059
+
1060
+ // CSS text-spacing
1061
+ let prefixTextSpacing = require('caniuse-lite/data/features/css-text-spacing')
1062
+
1063
+ f(prefixTextSpacing, browsers =>
1064
+ prefix(['text-spacing'], {
1065
+ browsers,
1066
+ feature: 'css-text-spacing'
1067
+ })
1068
+ )
1069
+
1070
+ // :any-link selector
1071
+ let prefixAnyLink = require('caniuse-lite/data/features/css-any-link')
1072
+
1073
+ f(prefixAnyLink, browsers =>
1074
+ prefix([':any-link'], {
1075
+ browsers,
1076
+ feature: 'css-any-link',
1077
+ selector: true
1078
+ })
1079
+ )
1080
+
1081
+ // unicode-bidi
1082
+
1083
+ let bidiIsolate = require('caniuse-lite/data/features/mdn-css-unicode-bidi-isolate')
1084
+
1085
+ f(bidiIsolate, browsers =>
1086
+ prefix(['isolate'], {
1087
+ browsers,
1088
+ feature: 'css-unicode-bidi',
1089
+ props: ['unicode-bidi']
1090
+ })
1091
+ )
1092
+
1093
+ let bidiPlaintext = require('caniuse-lite/data/features/mdn-css-unicode-bidi-plaintext')
1094
+
1095
+ f(bidiPlaintext, browsers =>
1096
+ prefix(['plaintext'], {
1097
+ browsers,
1098
+ feature: 'css-unicode-bidi',
1099
+ props: ['unicode-bidi']
1100
+ })
1101
+ )
1102
+
1103
+ let bidiOverride = require('caniuse-lite/data/features/mdn-css-unicode-bidi-isolate-override')
1104
+
1105
+ f(bidiOverride, { match: /y x/ }, browsers =>
1106
+ prefix(['isolate-override'], {
1107
+ browsers,
1108
+ feature: 'css-unicode-bidi',
1109
+ props: ['unicode-bidi']
1110
+ })
1111
+ )
1112
+
1113
+ // overscroll-behavior selector
1114
+ let prefixOverscroll = require('caniuse-lite/data/features/css-overscroll-behavior')
1115
+
1116
+ f(prefixOverscroll, { match: /a #1/ }, browsers =>
1117
+ prefix(['overscroll-behavior'], {
1118
+ browsers,
1119
+ feature: 'css-overscroll-behavior'
1120
+ })
1121
+ )
1122
+
1123
+ // text-orientation
1124
+ let prefixTextOrientation = require('caniuse-lite/data/features/css-text-orientation')
1125
+
1126
+ f(prefixTextOrientation, browsers =>
1127
+ prefix(['text-orientation'], {
1128
+ browsers,
1129
+ feature: 'css-text-orientation'
1130
+ })
1131
+ )
1132
+
1133
+ // print-color-adjust
1134
+ let prefixPrintAdjust = require('caniuse-lite/data/features/css-print-color-adjust')
1135
+
1136
+ f(prefixPrintAdjust, browsers =>
1137
+ prefix(['print-color-adjust', 'color-adjust'], {
1138
+ browsers,
1139
+ feature: 'css-print-color-adjust'
1140
+ })
1141
+ )
web/node_modules/autoprefixer/lib/at-rule.js ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Prefixer = require('./prefixer')
2
+
3
+ class AtRule extends Prefixer {
4
+ /**
5
+ * Clone and add prefixes for at-rule
6
+ */
7
+ add(rule, prefix) {
8
+ let prefixed = prefix + rule.name
9
+
10
+ let already = rule.parent.some(
11
+ i => i.name === prefixed && i.params === rule.params
12
+ )
13
+ if (already) {
14
+ return undefined
15
+ }
16
+
17
+ let cloned = this.clone(rule, { name: prefixed })
18
+ return rule.parent.insertBefore(rule, cloned)
19
+ }
20
+
21
+ /**
22
+ * Clone node with prefixes
23
+ */
24
+ process(node) {
25
+ let parent = this.parentPrefix(node)
26
+
27
+ for (let prefix of this.prefixes) {
28
+ if (!parent || parent === prefix) {
29
+ this.add(node, prefix)
30
+ }
31
+ }
32
+ }
33
+ }
34
+
35
+ module.exports = AtRule
web/node_modules/autoprefixer/lib/autoprefixer.d.ts ADDED
@@ -0,0 +1,95 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { Stats } from 'browserslist'
2
+ import { Plugin } from 'postcss'
3
+
4
+ declare function autoprefixer<T extends string[]>(
5
+ ...args: [...T, autoprefixer.Options]
6
+ ): Plugin & autoprefixer.ExportedAPI
7
+
8
+ declare function autoprefixer(
9
+ browsers: string[],
10
+ options?: autoprefixer.Options
11
+ ): Plugin & autoprefixer.ExportedAPI
12
+
13
+ declare function autoprefixer(
14
+ options?: autoprefixer.Options
15
+ ): Plugin & autoprefixer.ExportedAPI
16
+
17
+ declare namespace autoprefixer {
18
+ type GridValue = 'autoplace' | 'no-autoplace'
19
+
20
+ interface Options {
21
+ /** environment for `Browserslist` */
22
+ env?: string
23
+
24
+ /** should Autoprefixer use Visual Cascade, if CSS is uncompressed */
25
+ cascade?: boolean
26
+
27
+ /** should Autoprefixer add prefixes. */
28
+ add?: boolean
29
+
30
+ /** should Autoprefixer [remove outdated] prefixes */
31
+ remove?: boolean
32
+
33
+ /** should Autoprefixer add prefixes for @supports parameters. */
34
+ supports?: boolean
35
+
36
+ /** should Autoprefixer add prefixes for flexbox properties */
37
+ flexbox?: boolean | 'no-2009'
38
+
39
+ /** should Autoprefixer add IE 10-11 prefixes for Grid Layout properties */
40
+ grid?: boolean | GridValue
41
+
42
+ /** custom usage statistics for > 10% in my stats browsers query */
43
+ stats?: Stats
44
+
45
+ /**
46
+ * list of queries for target browsers.
47
+ * Try to not use it.
48
+ * The best practice is to use `.browserslistrc` config or `browserslist` key in `package.json`
49
+ * to share target browsers with Babel, ESLint and Stylelint
50
+ */
51
+ overrideBrowserslist?: string | string[]
52
+
53
+ /** do not raise error on unknown browser version in `Browserslist` config. */
54
+ ignoreUnknownVersions?: boolean
55
+ }
56
+
57
+ interface ExportedAPI {
58
+ /** Autoprefixer data */
59
+ data: {
60
+ browsers: { [browser: string]: object | undefined }
61
+ prefixes: { [prefixName: string]: object | undefined }
62
+ }
63
+
64
+ /** Autoprefixer default browsers */
65
+ defaults: string[]
66
+
67
+ /** Inspect with default Autoprefixer */
68
+ info(options?: { from?: string }): string
69
+
70
+ options: Options
71
+
72
+ browsers: string | string[]
73
+ }
74
+
75
+ /** Autoprefixer data */
76
+ let data: ExportedAPI['data']
77
+
78
+ /** Autoprefixer default browsers */
79
+ let defaults: ExportedAPI['defaults']
80
+
81
+ /** Inspect with default Autoprefixer */
82
+ let info: ExportedAPI['info']
83
+
84
+ let postcss: true
85
+ }
86
+
87
+ declare global {
88
+ namespace NodeJS {
89
+ interface ProcessEnv {
90
+ AUTOPREFIXER_GRID?: autoprefixer.GridValue
91
+ }
92
+ }
93
+ }
94
+
95
+ export = autoprefixer
web/node_modules/autoprefixer/lib/autoprefixer.js ADDED
@@ -0,0 +1,164 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let browserslist = require('browserslist')
2
+ let { agents } = require('caniuse-lite/dist/unpacker/agents')
3
+ let pico = require('picocolors')
4
+
5
+ let dataPrefixes = require('../data/prefixes')
6
+ let Browsers = require('./browsers')
7
+ let getInfo = require('./info')
8
+ let Prefixes = require('./prefixes')
9
+
10
+ let autoprefixerData = { browsers: agents, prefixes: dataPrefixes }
11
+
12
+ const WARNING =
13
+ '\n' +
14
+ ' Replace Autoprefixer `browsers` option to Browserslist config.\n' +
15
+ ' Use `browserslist` key in `package.json` or `.browserslistrc` file.\n' +
16
+ '\n' +
17
+ ' Using `browsers` option can cause errors. Browserslist config can\n' +
18
+ ' be used for Babel, Autoprefixer, postcss-normalize and other tools.\n' +
19
+ '\n' +
20
+ ' If you really need to use option, rename it to `overrideBrowserslist`.\n' +
21
+ '\n' +
22
+ ' Learn more at:\n' +
23
+ ' https://github.com/browserslist/browserslist#readme\n' +
24
+ ' https://twitter.com/browserslist\n' +
25
+ '\n'
26
+
27
+ function isPlainObject(obj) {
28
+ return Object.prototype.toString.apply(obj) === '[object Object]'
29
+ }
30
+
31
+ let cache = new Map()
32
+
33
+ function timeCapsule(result, prefixes) {
34
+ if (prefixes.browsers.selected.length === 0) {
35
+ return
36
+ }
37
+ if (prefixes.add.selectors.length > 0) {
38
+ return
39
+ }
40
+ if (Object.keys(prefixes.add).length > 2) {
41
+ return
42
+ }
43
+ /* c8 ignore next 11 */
44
+ result.warn(
45
+ 'Autoprefixer target browsers do not need any prefixes.' +
46
+ 'You do not need Autoprefixer anymore.\n' +
47
+ 'Check your Browserslist config to be sure that your targets ' +
48
+ 'are set up correctly.\n' +
49
+ '\n' +
50
+ ' Learn more at:\n' +
51
+ ' https://github.com/postcss/autoprefixer#readme\n' +
52
+ ' https://github.com/browserslist/browserslist#readme\n' +
53
+ '\n'
54
+ )
55
+ }
56
+
57
+ module.exports = plugin
58
+
59
+ function plugin(...reqs) {
60
+ let options
61
+ if (reqs.length === 1 && isPlainObject(reqs[0])) {
62
+ options = reqs[0]
63
+ reqs = undefined
64
+ } else if (reqs.length === 0 || (reqs.length === 1 && !reqs[0])) {
65
+ reqs = undefined
66
+ } else if (reqs.length <= 2 && (Array.isArray(reqs[0]) || !reqs[0])) {
67
+ options = reqs[1]
68
+ reqs = reqs[0]
69
+ } else if (typeof reqs[reqs.length - 1] === 'object') {
70
+ options = reqs.pop()
71
+ }
72
+
73
+ if (!options) {
74
+ options = {}
75
+ }
76
+
77
+ if (options.browser) {
78
+ throw new Error(
79
+ 'Change `browser` option to `overrideBrowserslist` in Autoprefixer'
80
+ )
81
+ } else if (options.browserslist) {
82
+ throw new Error(
83
+ 'Change `browserslist` option to `overrideBrowserslist` in Autoprefixer'
84
+ )
85
+ }
86
+
87
+ if (options.overrideBrowserslist) {
88
+ reqs = options.overrideBrowserslist
89
+ } else if (options.browsers) {
90
+ if (typeof console !== 'undefined' && console.warn) {
91
+ console.warn(
92
+ pico.red(WARNING.replace(/`[^`]+`/g, i => pico.yellow(i.slice(1, -1))))
93
+ )
94
+ }
95
+ reqs = options.browsers
96
+ }
97
+
98
+ let brwlstOpts = {
99
+ env: options.env,
100
+ ignoreUnknownVersions: options.ignoreUnknownVersions,
101
+ stats: options.stats
102
+ }
103
+
104
+ function loadPrefixes(opts) {
105
+ let d = autoprefixerData
106
+ let browsers = new Browsers(d.browsers, reqs, opts, brwlstOpts)
107
+ let key = browsers.selected.join(', ') + JSON.stringify(options)
108
+
109
+ if (!cache.has(key)) {
110
+ cache.set(key, new Prefixes(d.prefixes, browsers, options))
111
+ }
112
+
113
+ return cache.get(key)
114
+ }
115
+
116
+ return {
117
+ browsers: reqs,
118
+
119
+ info(opts) {
120
+ opts = opts || {}
121
+ opts.from = opts.from || process.cwd()
122
+ return getInfo(loadPrefixes(opts))
123
+ },
124
+
125
+ options,
126
+
127
+ postcssPlugin: 'autoprefixer',
128
+ prepare(result) {
129
+ let prefixes = loadPrefixes({
130
+ env: options.env,
131
+ from: result.opts.from
132
+ })
133
+
134
+ return {
135
+ OnceExit(root) {
136
+ timeCapsule(result, prefixes)
137
+ if (options.remove !== false) {
138
+ prefixes.processor.remove(root, result)
139
+ }
140
+ if (options.add !== false) {
141
+ prefixes.processor.add(root, result)
142
+ }
143
+ }
144
+ }
145
+ }
146
+ }
147
+ }
148
+
149
+ plugin.postcss = true
150
+
151
+ /**
152
+ * Autoprefixer data
153
+ */
154
+ plugin.data = autoprefixerData
155
+
156
+ /**
157
+ * Autoprefixer default browsers
158
+ */
159
+ plugin.defaults = browserslist.defaults
160
+
161
+ /**
162
+ * Inspect with default Autoprefixer
163
+ */
164
+ plugin.info = () => plugin().info()
web/node_modules/autoprefixer/lib/brackets.js ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ function last(array) {
2
+ return array[array.length - 1]
3
+ }
4
+
5
+ let brackets = {
6
+ /**
7
+ * Parse string to nodes tree
8
+ */
9
+ parse(str) {
10
+ let current = ['']
11
+ let stack = [current]
12
+
13
+ for (let sym of str) {
14
+ if (sym === '(') {
15
+ current = ['']
16
+ last(stack).push(current)
17
+ stack.push(current)
18
+ continue
19
+ }
20
+
21
+ if (sym === ')') {
22
+ if (stack.length > 1) {
23
+ stack.pop()
24
+ current = last(stack)
25
+ current.push('')
26
+ } else {
27
+ current[current.length - 1] += sym
28
+ }
29
+ continue
30
+ }
31
+
32
+ current[current.length - 1] += sym
33
+ }
34
+
35
+ return stack[0]
36
+ },
37
+
38
+ /**
39
+ * Generate output string by nodes tree
40
+ */
41
+ stringify(ast) {
42
+ let result = ''
43
+ for (let i of ast) {
44
+ if (typeof i === 'object') {
45
+ result += `(${brackets.stringify(i)})`
46
+ continue
47
+ }
48
+
49
+ result += i
50
+ }
51
+ return result
52
+ }
53
+ }
54
+
55
+ module.exports = brackets
web/node_modules/autoprefixer/lib/browsers.js ADDED
@@ -0,0 +1,79 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let browserslist = require('browserslist')
2
+ let { agents } = require('caniuse-lite/dist/unpacker/agents')
3
+
4
+ let utils = require('./utils')
5
+
6
+ class Browsers {
7
+ constructor(data, requirements, options, browserslistOpts) {
8
+ this.data = data
9
+ this.options = options || {}
10
+ this.browserslistOpts = browserslistOpts || {}
11
+ this.selected = this.parse(requirements)
12
+ }
13
+
14
+ /**
15
+ * Return all prefixes for default browser data
16
+ */
17
+ static prefixes() {
18
+ if (this.prefixesCache) {
19
+ return this.prefixesCache
20
+ }
21
+
22
+ this.prefixesCache = []
23
+ for (let name in agents) {
24
+ this.prefixesCache.push(`-${agents[name].prefix}-`)
25
+ }
26
+
27
+ this.prefixesCache = utils
28
+ .uniq(this.prefixesCache)
29
+ .sort((a, b) => b.length - a.length)
30
+
31
+ return this.prefixesCache
32
+ }
33
+
34
+ /**
35
+ * Check is value contain any possible prefix
36
+ */
37
+ static withPrefix(value) {
38
+ if (!this.prefixesRegexp) {
39
+ this.prefixesRegexp = new RegExp(this.prefixes().join('|'))
40
+ }
41
+
42
+ return this.prefixesRegexp.test(value)
43
+ }
44
+
45
+ /**
46
+ * Is browser is selected by requirements
47
+ */
48
+ isSelected(browser) {
49
+ return this.selected.includes(browser)
50
+ }
51
+
52
+ /**
53
+ * Return browsers selected by requirements
54
+ */
55
+ parse(requirements) {
56
+ let opts = {}
57
+ for (let i in this.browserslistOpts) {
58
+ opts[i] = this.browserslistOpts[i]
59
+ }
60
+ opts.path = this.options.from
61
+ return browserslist(requirements, opts)
62
+ }
63
+
64
+ /**
65
+ * Return prefix for selected browser
66
+ */
67
+ prefix(browser) {
68
+ let [name, version] = browser.split(' ')
69
+ let data = this.data[name]
70
+
71
+ let prefix = data.prefix_exceptions && data.prefix_exceptions[version]
72
+ if (!prefix) {
73
+ prefix = data.prefix
74
+ }
75
+ return `-${prefix}-`
76
+ }
77
+ }
78
+
79
+ module.exports = Browsers
web/node_modules/autoprefixer/lib/declaration.js ADDED
@@ -0,0 +1,187 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Browsers = require('./browsers')
2
+ let Prefixer = require('./prefixer')
3
+ let utils = require('./utils')
4
+
5
+ class Declaration extends Prefixer {
6
+ /**
7
+ * Clone and add prefixes for declaration
8
+ */
9
+ add(decl, prefix, prefixes, result) {
10
+ let prefixed = this.prefixed(decl.prop, prefix)
11
+ if (
12
+ this.isAlready(decl, prefixed) ||
13
+ this.otherPrefixes(decl.value, prefix)
14
+ ) {
15
+ return undefined
16
+ }
17
+ return this.insert(decl, prefix, prefixes, result)
18
+ }
19
+
20
+ /**
21
+ * Calculate indentation to create visual cascade
22
+ */
23
+ calcBefore(prefixes, decl, prefix = '') {
24
+ let max = this.maxPrefixed(prefixes, decl)
25
+ let diff = max - utils.removeNote(prefix).length
26
+
27
+ let before = decl.raw('before')
28
+ if (diff > 0) {
29
+ before += Array(diff).fill(' ').join('')
30
+ }
31
+
32
+ return before
33
+ }
34
+
35
+ /**
36
+ * Always true, because we already get prefixer by property name
37
+ */
38
+ check(/* decl */) {
39
+ return true
40
+ }
41
+
42
+ /**
43
+ * Clone and insert new declaration
44
+ */
45
+ insert(decl, prefix, prefixes) {
46
+ let cloned = this.set(this.clone(decl), prefix)
47
+ if (!cloned) return undefined
48
+
49
+ let already = decl.parent.some(
50
+ i => i.prop === cloned.prop && i.value === cloned.value
51
+ )
52
+ if (already) {
53
+ return undefined
54
+ }
55
+
56
+ if (this.needCascade(decl)) {
57
+ cloned.raws.before = this.calcBefore(prefixes, decl, prefix)
58
+ }
59
+ return decl.parent.insertBefore(decl, cloned)
60
+ }
61
+
62
+ /**
63
+ * Did this declaration has this prefix above
64
+ */
65
+ isAlready(decl, prefixed) {
66
+ let already = this.all.group(decl).up(i => i.prop === prefixed)
67
+ if (!already) {
68
+ already = this.all.group(decl).down(i => i.prop === prefixed)
69
+ }
70
+ return already
71
+ }
72
+
73
+ /**
74
+ * Return maximum length of possible prefixed property
75
+ */
76
+ maxPrefixed(prefixes, decl) {
77
+ if (decl._autoprefixerMax) {
78
+ return decl._autoprefixerMax
79
+ }
80
+
81
+ let max = 0
82
+ for (let prefix of prefixes) {
83
+ prefix = utils.removeNote(prefix)
84
+ if (prefix.length > max) {
85
+ max = prefix.length
86
+ }
87
+ }
88
+ decl._autoprefixerMax = max
89
+
90
+ return decl._autoprefixerMax
91
+ }
92
+
93
+ /**
94
+ * Should we use visual cascade for prefixes
95
+ */
96
+ needCascade(decl) {
97
+ if (!decl._autoprefixerCascade) {
98
+ decl._autoprefixerCascade =
99
+ this.all.options.cascade !== false && decl.raw('before').includes('\n')
100
+ }
101
+ return decl._autoprefixerCascade
102
+ }
103
+
104
+ /**
105
+ * Return unprefixed version of property
106
+ */
107
+ normalize(prop) {
108
+ return prop
109
+ }
110
+
111
+ /**
112
+ * Return list of prefixed properties to clean old prefixes
113
+ */
114
+ old(prop, prefix) {
115
+ return [this.prefixed(prop, prefix)]
116
+ }
117
+
118
+ /**
119
+ * Check `value`, that it contain other prefixes, rather than `prefix`
120
+ */
121
+ otherPrefixes(value, prefix) {
122
+ for (let other of Browsers.prefixes()) {
123
+ if (other === prefix) {
124
+ continue
125
+ }
126
+ if (value.includes(other)) {
127
+ return value.replace(/var\([^)]+\)/, '').includes(other)
128
+ }
129
+ }
130
+ return false
131
+ }
132
+
133
+ /**
134
+ * Return prefixed version of property
135
+ */
136
+ prefixed(prop, prefix) {
137
+ return prefix + prop
138
+ }
139
+
140
+ /**
141
+ * Add spaces for visual cascade
142
+ */
143
+ process(decl, result) {
144
+ if (!this.needCascade(decl)) {
145
+ super.process(decl, result)
146
+ return
147
+ }
148
+
149
+ let prefixes = super.process(decl, result)
150
+
151
+ if (!prefixes || !prefixes.length) {
152
+ return
153
+ }
154
+
155
+ this.restoreBefore(decl)
156
+ decl.raws.before = this.calcBefore(prefixes, decl)
157
+ }
158
+
159
+ /**
160
+ * Remove visual cascade
161
+ */
162
+ restoreBefore(decl) {
163
+ let lines = decl.raw('before').split('\n')
164
+ let min = lines[lines.length - 1]
165
+
166
+ this.all.group(decl).up(prefixed => {
167
+ let array = prefixed.raw('before').split('\n')
168
+ let last = array[array.length - 1]
169
+ if (last.length < min.length) {
170
+ min = last
171
+ }
172
+ })
173
+
174
+ lines[lines.length - 1] = min
175
+ decl.raws.before = lines.join('\n')
176
+ }
177
+
178
+ /**
179
+ * Set prefix to declaration
180
+ */
181
+ set(decl, prefix) {
182
+ decl.prop = this.prefixed(decl.prop, prefix)
183
+ return decl
184
+ }
185
+ }
186
+
187
+ module.exports = Declaration
web/node_modules/autoprefixer/lib/hacks/align-content.js ADDED
@@ -0,0 +1,49 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let flexSpec = require('./flex-spec')
3
+
4
+ class AlignContent extends Declaration {
5
+ /**
6
+ * Return property name by final spec
7
+ */
8
+ normalize() {
9
+ return 'align-content'
10
+ }
11
+
12
+ /**
13
+ * Change property name for 2012 spec
14
+ */
15
+ prefixed(prop, prefix) {
16
+ let spec
17
+ ;[spec, prefix] = flexSpec(prefix)
18
+ if (spec === 2012) {
19
+ return prefix + 'flex-line-pack'
20
+ }
21
+ return super.prefixed(prop, prefix)
22
+ }
23
+
24
+ /**
25
+ * Change value for 2012 spec and ignore prefix for 2009
26
+ */
27
+ set(decl, prefix) {
28
+ let spec = flexSpec(prefix)[0]
29
+ if (spec === 2012) {
30
+ decl.value = AlignContent.oldValues[decl.value] || decl.value
31
+ return super.set(decl, prefix)
32
+ }
33
+ if (spec === 'final') {
34
+ return super.set(decl, prefix)
35
+ }
36
+ return undefined
37
+ }
38
+ }
39
+
40
+ AlignContent.names = ['align-content', 'flex-line-pack']
41
+
42
+ AlignContent.oldValues = {
43
+ 'flex-end': 'end',
44
+ 'flex-start': 'start',
45
+ 'space-around': 'distribute',
46
+ 'space-between': 'justify'
47
+ }
48
+
49
+ module.exports = AlignContent
web/node_modules/autoprefixer/lib/hacks/align-items.js ADDED
@@ -0,0 +1,46 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let flexSpec = require('./flex-spec')
3
+
4
+ class AlignItems extends Declaration {
5
+ /**
6
+ * Return property name by final spec
7
+ */
8
+ normalize() {
9
+ return 'align-items'
10
+ }
11
+
12
+ /**
13
+ * Change property name for 2009 and 2012 specs
14
+ */
15
+ prefixed(prop, prefix) {
16
+ let spec
17
+ ;[spec, prefix] = flexSpec(prefix)
18
+ if (spec === 2009) {
19
+ return prefix + 'box-align'
20
+ }
21
+ if (spec === 2012) {
22
+ return prefix + 'flex-align'
23
+ }
24
+ return super.prefixed(prop, prefix)
25
+ }
26
+
27
+ /**
28
+ * Change value for 2009 and 2012 specs
29
+ */
30
+ set(decl, prefix) {
31
+ let spec = flexSpec(prefix)[0]
32
+ if (spec === 2009 || spec === 2012) {
33
+ decl.value = AlignItems.oldValues[decl.value] || decl.value
34
+ }
35
+ return super.set(decl, prefix)
36
+ }
37
+ }
38
+
39
+ AlignItems.names = ['align-items', 'flex-align', 'box-align']
40
+
41
+ AlignItems.oldValues = {
42
+ 'flex-end': 'end',
43
+ 'flex-start': 'start'
44
+ }
45
+
46
+ module.exports = AlignItems
web/node_modules/autoprefixer/lib/hacks/align-self.js ADDED
@@ -0,0 +1,56 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let flexSpec = require('./flex-spec')
3
+
4
+ class AlignSelf extends Declaration {
5
+ check(decl) {
6
+ return (
7
+ decl.parent &&
8
+ !decl.parent.some(i => {
9
+ return i.prop && i.prop.startsWith('grid-')
10
+ })
11
+ )
12
+ }
13
+
14
+ /**
15
+ * Return property name by final spec
16
+ */
17
+ normalize() {
18
+ return 'align-self'
19
+ }
20
+
21
+ /**
22
+ * Change property name for 2012 specs
23
+ */
24
+ prefixed(prop, prefix) {
25
+ let spec
26
+ ;[spec, prefix] = flexSpec(prefix)
27
+ if (spec === 2012) {
28
+ return prefix + 'flex-item-align'
29
+ }
30
+ return super.prefixed(prop, prefix)
31
+ }
32
+
33
+ /**
34
+ * Change value for 2012 spec and ignore prefix for 2009
35
+ */
36
+ set(decl, prefix) {
37
+ let spec = flexSpec(prefix)[0]
38
+ if (spec === 2012) {
39
+ decl.value = AlignSelf.oldValues[decl.value] || decl.value
40
+ return super.set(decl, prefix)
41
+ }
42
+ if (spec === 'final') {
43
+ return super.set(decl, prefix)
44
+ }
45
+ return undefined
46
+ }
47
+ }
48
+
49
+ AlignSelf.names = ['align-self', 'flex-item-align']
50
+
51
+ AlignSelf.oldValues = {
52
+ 'flex-end': 'end',
53
+ 'flex-start': 'start'
54
+ }
55
+
56
+ module.exports = AlignSelf
web/node_modules/autoprefixer/lib/hacks/animation.js ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+
3
+ class Animation extends Declaration {
4
+ /**
5
+ * Don’t add prefixes for modern values.
6
+ */
7
+ check(decl) {
8
+ return !decl.value.split(/\s+/).some(i => {
9
+ let lower = i.toLowerCase()
10
+ return lower === 'reverse' || lower === 'alternate-reverse'
11
+ })
12
+ }
13
+ }
14
+
15
+ Animation.names = ['animation', 'animation-direction']
16
+
17
+ module.exports = Animation
web/node_modules/autoprefixer/lib/hacks/appearance.js ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let utils = require('../utils')
3
+
4
+ class Appearance extends Declaration {
5
+ constructor(name, prefixes, all) {
6
+ super(name, prefixes, all)
7
+
8
+ if (this.prefixes) {
9
+ this.prefixes = utils.uniq(
10
+ this.prefixes.map(i => {
11
+ if (i === '-ms-') {
12
+ return '-webkit-'
13
+ }
14
+ return i
15
+ })
16
+ )
17
+ }
18
+ }
19
+ }
20
+
21
+ Appearance.names = ['appearance']
22
+
23
+ module.exports = Appearance
web/node_modules/autoprefixer/lib/hacks/autofill.js ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Selector = require('../selector')
2
+ let utils = require('../utils')
3
+
4
+ class Autofill extends Selector {
5
+ constructor(name, prefixes, all) {
6
+ super(name, prefixes, all)
7
+
8
+ if (this.prefixes) {
9
+ this.prefixes = utils.uniq(this.prefixes.map(() => '-webkit-'))
10
+ }
11
+ }
12
+
13
+ /**
14
+ * Return different selectors depend on prefix
15
+ */
16
+ prefixed(prefix) {
17
+ if (prefix === '-webkit-') {
18
+ return ':-webkit-autofill'
19
+ }
20
+ return `:${prefix}autofill`
21
+ }
22
+ }
23
+
24
+ Autofill.names = [':autofill']
25
+
26
+ module.exports = Autofill
web/node_modules/autoprefixer/lib/hacks/backdrop-filter.js ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let utils = require('../utils')
3
+
4
+ class BackdropFilter extends Declaration {
5
+ constructor(name, prefixes, all) {
6
+ super(name, prefixes, all)
7
+
8
+ if (this.prefixes) {
9
+ this.prefixes = utils.uniq(
10
+ this.prefixes.map(i => {
11
+ return i === '-ms-' ? '-webkit-' : i
12
+ })
13
+ )
14
+ }
15
+ }
16
+ }
17
+
18
+ BackdropFilter.names = ['backdrop-filter']
19
+
20
+ module.exports = BackdropFilter
web/node_modules/autoprefixer/lib/hacks/background-clip.js ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let utils = require('../utils')
3
+
4
+ class BackgroundClip extends Declaration {
5
+ constructor(name, prefixes, all) {
6
+ super(name, prefixes, all)
7
+
8
+ if (this.prefixes) {
9
+ this.prefixes = utils.uniq(
10
+ this.prefixes.map(i => {
11
+ return i === '-ms-' ? '-webkit-' : i
12
+ })
13
+ )
14
+ }
15
+ }
16
+
17
+ check(decl) {
18
+ return decl.value.toLowerCase() === 'text'
19
+ }
20
+ }
21
+
22
+ BackgroundClip.names = ['background-clip']
23
+
24
+ module.exports = BackgroundClip
web/node_modules/autoprefixer/lib/hacks/background-size.js ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+
3
+ class BackgroundSize extends Declaration {
4
+ /**
5
+ * Duplication parameter for -webkit- browsers
6
+ */
7
+ set(decl, prefix) {
8
+ let value = decl.value.toLowerCase()
9
+ if (
10
+ prefix === '-webkit-' &&
11
+ !value.includes(' ') &&
12
+ value !== 'contain' &&
13
+ value !== 'cover'
14
+ ) {
15
+ decl.value = decl.value + ' ' + decl.value
16
+ }
17
+ return super.set(decl, prefix)
18
+ }
19
+ }
20
+
21
+ BackgroundSize.names = ['background-size']
22
+
23
+ module.exports = BackgroundSize
web/node_modules/autoprefixer/lib/hacks/block-logical.js ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+
3
+ class BlockLogical extends Declaration {
4
+ /**
5
+ * Return property name by spec
6
+ */
7
+ normalize(prop) {
8
+ if (prop.includes('-before')) {
9
+ return prop.replace('-before', '-block-start')
10
+ }
11
+ return prop.replace('-after', '-block-end')
12
+ }
13
+
14
+ /**
15
+ * Use old syntax for -moz- and -webkit-
16
+ */
17
+ prefixed(prop, prefix) {
18
+ if (prop.includes('-start')) {
19
+ return prefix + prop.replace('-block-start', '-before')
20
+ }
21
+ return prefix + prop.replace('-block-end', '-after')
22
+ }
23
+ }
24
+
25
+ BlockLogical.names = [
26
+ 'border-block-start',
27
+ 'border-block-end',
28
+ 'margin-block-start',
29
+ 'margin-block-end',
30
+ 'padding-block-start',
31
+ 'padding-block-end',
32
+ 'border-before',
33
+ 'border-after',
34
+ 'margin-before',
35
+ 'margin-after',
36
+ 'padding-before',
37
+ 'padding-after'
38
+ ]
39
+
40
+ module.exports = BlockLogical
web/node_modules/autoprefixer/lib/hacks/border-image.js ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+
3
+ class BorderImage extends Declaration {
4
+ /**
5
+ * Remove fill parameter for prefixed declarations
6
+ */
7
+ set(decl, prefix) {
8
+ decl.value = decl.value.replace(/\s+fill(\s)/, '$1')
9
+ return super.set(decl, prefix)
10
+ }
11
+ }
12
+
13
+ BorderImage.names = ['border-image']
14
+
15
+ module.exports = BorderImage
web/node_modules/autoprefixer/lib/hacks/border-radius.js ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+
3
+ class BorderRadius extends Declaration {
4
+ /**
5
+ * Return unprefixed version of property
6
+ */
7
+ normalize(prop) {
8
+ return BorderRadius.toNormal[prop] || prop
9
+ }
10
+
11
+ /**
12
+ * Change syntax, when add Mozilla prefix
13
+ */
14
+ prefixed(prop, prefix) {
15
+ if (prefix === '-moz-') {
16
+ return prefix + (BorderRadius.toMozilla[prop] || prop)
17
+ }
18
+ return super.prefixed(prop, prefix)
19
+ }
20
+ }
21
+
22
+ BorderRadius.names = ['border-radius']
23
+
24
+ BorderRadius.toMozilla = {}
25
+ BorderRadius.toNormal = {}
26
+
27
+ for (let ver of ['top', 'bottom']) {
28
+ for (let hor of ['left', 'right']) {
29
+ let normal = `border-${ver}-${hor}-radius`
30
+ let mozilla = `border-radius-${ver}${hor}`
31
+
32
+ BorderRadius.names.push(normal)
33
+ BorderRadius.names.push(mozilla)
34
+
35
+ BorderRadius.toMozilla[normal] = mozilla
36
+ BorderRadius.toNormal[mozilla] = normal
37
+ }
38
+ }
39
+
40
+ module.exports = BorderRadius
web/node_modules/autoprefixer/lib/hacks/break-props.js ADDED
@@ -0,0 +1,63 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+
3
+ class BreakProps extends Declaration {
4
+ /**
5
+ * Don’t prefix some values
6
+ */
7
+ insert(decl, prefix, prefixes) {
8
+ if (decl.prop !== 'break-inside') {
9
+ return super.insert(decl, prefix, prefixes)
10
+ }
11
+ if (/region/i.test(decl.value) || /page/i.test(decl.value)) {
12
+ return undefined
13
+ }
14
+ return super.insert(decl, prefix, prefixes)
15
+ }
16
+
17
+ /**
18
+ * Return property name by final spec
19
+ */
20
+ normalize(prop) {
21
+ if (prop.includes('inside')) {
22
+ return 'break-inside'
23
+ }
24
+ if (prop.includes('before')) {
25
+ return 'break-before'
26
+ }
27
+ return 'break-after'
28
+ }
29
+
30
+ /**
31
+ * Change name for -webkit- and -moz- prefix
32
+ */
33
+ prefixed(prop, prefix) {
34
+ return `${prefix}column-${prop}`
35
+ }
36
+
37
+ /**
38
+ * Change prefixed value for avoid-column and avoid-page
39
+ */
40
+ set(decl, prefix) {
41
+ if (
42
+ (decl.prop === 'break-inside' && decl.value === 'avoid-column') ||
43
+ decl.value === 'avoid-page'
44
+ ) {
45
+ decl.value = 'avoid'
46
+ }
47
+ return super.set(decl, prefix)
48
+ }
49
+ }
50
+
51
+ BreakProps.names = [
52
+ 'break-inside',
53
+ 'page-break-inside',
54
+ 'column-break-inside',
55
+ 'break-before',
56
+ 'page-break-before',
57
+ 'column-break-before',
58
+ 'break-after',
59
+ 'page-break-after',
60
+ 'column-break-after'
61
+ ]
62
+
63
+ module.exports = BreakProps
web/node_modules/autoprefixer/lib/hacks/cross-fade.js ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let list = require('postcss').list
2
+
3
+ let Value = require('../value')
4
+
5
+ class CrossFade extends Value {
6
+ replace(string, prefix) {
7
+ return list
8
+ .space(string)
9
+ .map(value => {
10
+ if (value.slice(0, +this.name.length + 1) !== this.name + '(') {
11
+ return value
12
+ }
13
+
14
+ let close = value.lastIndexOf(')')
15
+ let after = value.slice(close + 1)
16
+ let args = value.slice(this.name.length + 1, close)
17
+
18
+ if (prefix === '-webkit-') {
19
+ let match = args.match(/\d*.?\d+%?/)
20
+ if (match) {
21
+ args = args.slice(match[0].length).trim()
22
+ args += `, ${match[0]}`
23
+ } else {
24
+ args += ', 0.5'
25
+ }
26
+ }
27
+ return prefix + this.name + '(' + args + ')' + after
28
+ })
29
+ .join(' ')
30
+ }
31
+ }
32
+
33
+ CrossFade.names = ['cross-fade']
34
+
35
+ module.exports = CrossFade
web/node_modules/autoprefixer/lib/hacks/display-flex.js ADDED
@@ -0,0 +1,65 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let OldValue = require('../old-value')
2
+ let Value = require('../value')
3
+ let flexSpec = require('./flex-spec')
4
+
5
+ class DisplayFlex extends Value {
6
+ constructor(name, prefixes) {
7
+ super(name, prefixes)
8
+ if (name === 'display-flex') {
9
+ this.name = 'flex'
10
+ }
11
+ }
12
+
13
+ /**
14
+ * Faster check for flex value
15
+ */
16
+ check(decl) {
17
+ return decl.prop === 'display' && decl.value === this.name
18
+ }
19
+
20
+ /**
21
+ * Change value for old specs
22
+ */
23
+ old(prefix) {
24
+ let prefixed = this.prefixed(prefix)
25
+ if (!prefixed) return undefined
26
+ return new OldValue(this.name, prefixed)
27
+ }
28
+
29
+ /**
30
+ * Return value by spec
31
+ */
32
+ prefixed(prefix) {
33
+ let spec, value
34
+ ;[spec, prefix] = flexSpec(prefix)
35
+
36
+ if (spec === 2009) {
37
+ if (this.name === 'flex') {
38
+ value = 'box'
39
+ } else {
40
+ value = 'inline-box'
41
+ }
42
+ } else if (spec === 2012) {
43
+ if (this.name === 'flex') {
44
+ value = 'flexbox'
45
+ } else {
46
+ value = 'inline-flexbox'
47
+ }
48
+ } else if (spec === 'final') {
49
+ value = this.name
50
+ }
51
+
52
+ return prefix + value
53
+ }
54
+
55
+ /**
56
+ * Add prefix to value depend on flebox spec version
57
+ */
58
+ replace(string, prefix) {
59
+ return this.prefixed(prefix)
60
+ }
61
+ }
62
+
63
+ DisplayFlex.names = ['display-flex', 'inline-flex']
64
+
65
+ module.exports = DisplayFlex
web/node_modules/autoprefixer/lib/hacks/display-grid.js ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Value = require('../value')
2
+
3
+ class DisplayGrid extends Value {
4
+ constructor(name, prefixes) {
5
+ super(name, prefixes)
6
+ if (name === 'display-grid') {
7
+ this.name = 'grid'
8
+ }
9
+ }
10
+
11
+ /**
12
+ * Faster check for flex value
13
+ */
14
+ check(decl) {
15
+ return decl.prop === 'display' && decl.value === this.name
16
+ }
17
+ }
18
+
19
+ DisplayGrid.names = ['display-grid', 'inline-grid']
20
+
21
+ module.exports = DisplayGrid
web/node_modules/autoprefixer/lib/hacks/file-selector-button.js ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Selector = require('../selector')
2
+ let utils = require('../utils')
3
+
4
+ class FileSelectorButton extends Selector {
5
+ constructor(name, prefixes, all) {
6
+ super(name, prefixes, all)
7
+
8
+ if (this.prefixes) {
9
+ this.prefixes = utils.uniq(this.prefixes.map(() => '-webkit-'))
10
+ }
11
+ }
12
+
13
+ /**
14
+ * Return different selectors depend on prefix
15
+ */
16
+ prefixed(prefix) {
17
+ if (prefix === '-webkit-') {
18
+ return '::-webkit-file-upload-button'
19
+ }
20
+ return `::${prefix}file-selector-button`
21
+ }
22
+ }
23
+
24
+ FileSelectorButton.names = ['::file-selector-button']
25
+
26
+ module.exports = FileSelectorButton
web/node_modules/autoprefixer/lib/hacks/filter-value.js ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Value = require('../value')
2
+
3
+ class FilterValue extends Value {
4
+ constructor(name, prefixes) {
5
+ super(name, prefixes)
6
+ if (name === 'filter-function') {
7
+ this.name = 'filter'
8
+ }
9
+ }
10
+ }
11
+
12
+ FilterValue.names = ['filter', 'filter-function']
13
+
14
+ module.exports = FilterValue
web/node_modules/autoprefixer/lib/hacks/filter.js ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+
3
+ class Filter extends Declaration {
4
+ /**
5
+ * Check is it Internet Explorer filter
6
+ */
7
+ check(decl) {
8
+ let v = decl.value
9
+ return (
10
+ !v.toLowerCase().includes('alpha(') &&
11
+ !v.includes('DXImageTransform.Microsoft') &&
12
+ !v.includes('data:image/svg+xml')
13
+ )
14
+ }
15
+ }
16
+
17
+ Filter.names = ['filter']
18
+
19
+ module.exports = Filter
web/node_modules/autoprefixer/lib/hacks/flex-basis.js ADDED
@@ -0,0 +1,39 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let flexSpec = require('./flex-spec')
3
+
4
+ class FlexBasis extends Declaration {
5
+ /**
6
+ * Return property name by final spec
7
+ */
8
+ normalize() {
9
+ return 'flex-basis'
10
+ }
11
+
12
+ /**
13
+ * Return flex property for 2012 spec
14
+ */
15
+ prefixed(prop, prefix) {
16
+ let spec
17
+ ;[spec, prefix] = flexSpec(prefix)
18
+ if (spec === 2012) {
19
+ return prefix + 'flex-preferred-size'
20
+ }
21
+ return super.prefixed(prop, prefix)
22
+ }
23
+
24
+ /**
25
+ * Ignore 2009 spec and use flex property for 2012
26
+ */
27
+ set(decl, prefix) {
28
+ let spec
29
+ ;[spec, prefix] = flexSpec(prefix)
30
+ if (spec === 2012 || spec === 'final') {
31
+ return super.set(decl, prefix)
32
+ }
33
+ return undefined
34
+ }
35
+ }
36
+
37
+ FlexBasis.names = ['flex-basis', 'flex-preferred-size']
38
+
39
+ module.exports = FlexBasis
web/node_modules/autoprefixer/lib/hacks/flex-direction.js ADDED
@@ -0,0 +1,72 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let flexSpec = require('./flex-spec')
3
+
4
+ class FlexDirection extends Declaration {
5
+ /**
6
+ * Use two properties for 2009 spec
7
+ */
8
+ insert(decl, prefix, prefixes) {
9
+ let spec
10
+ ;[spec, prefix] = flexSpec(prefix)
11
+ if (spec !== 2009) {
12
+ return super.insert(decl, prefix, prefixes)
13
+ }
14
+ let already = decl.parent.some(
15
+ i =>
16
+ i.prop === prefix + 'box-orient' || i.prop === prefix + 'box-direction'
17
+ )
18
+ if (already) {
19
+ return undefined
20
+ }
21
+
22
+ let v = decl.value
23
+ let dir, orient
24
+ if (v === 'inherit' || v === 'initial' || v === 'unset') {
25
+ orient = v
26
+ dir = v
27
+ } else {
28
+ orient = v.includes('row') ? 'horizontal' : 'vertical'
29
+ dir = v.includes('reverse') ? 'reverse' : 'normal'
30
+ }
31
+
32
+ let cloned = this.clone(decl)
33
+ cloned.prop = prefix + 'box-orient'
34
+ cloned.value = orient
35
+ if (this.needCascade(decl)) {
36
+ cloned.raws.before = this.calcBefore(prefixes, decl, prefix)
37
+ }
38
+ decl.parent.insertBefore(decl, cloned)
39
+
40
+ cloned = this.clone(decl)
41
+ cloned.prop = prefix + 'box-direction'
42
+ cloned.value = dir
43
+ if (this.needCascade(decl)) {
44
+ cloned.raws.before = this.calcBefore(prefixes, decl, prefix)
45
+ }
46
+ return decl.parent.insertBefore(decl, cloned)
47
+ }
48
+
49
+ /**
50
+ * Return property name by final spec
51
+ */
52
+ normalize() {
53
+ return 'flex-direction'
54
+ }
55
+
56
+ /**
57
+ * Clean two properties for 2009 spec
58
+ */
59
+ old(prop, prefix) {
60
+ let spec
61
+ ;[spec, prefix] = flexSpec(prefix)
62
+ if (spec === 2009) {
63
+ return [prefix + 'box-orient', prefix + 'box-direction']
64
+ } else {
65
+ return super.old(prop, prefix)
66
+ }
67
+ }
68
+ }
69
+
70
+ FlexDirection.names = ['flex-direction', 'box-direction', 'box-orient']
71
+
72
+ module.exports = FlexDirection
web/node_modules/autoprefixer/lib/hacks/flex-flow.js ADDED
@@ -0,0 +1,53 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let flexSpec = require('./flex-spec')
3
+
4
+ class FlexFlow extends Declaration {
5
+ /**
6
+ * Use two properties for 2009 spec
7
+ */
8
+ insert(decl, prefix, prefixes) {
9
+ let spec
10
+ ;[spec, prefix] = flexSpec(prefix)
11
+ if (spec !== 2009) {
12
+ return super.insert(decl, prefix, prefixes)
13
+ }
14
+ let values = decl.value
15
+ .split(/\s+/)
16
+ .filter(i => i !== 'wrap' && i !== 'nowrap' && 'wrap-reverse')
17
+ if (values.length === 0) {
18
+ return undefined
19
+ }
20
+
21
+ let already = decl.parent.some(
22
+ i =>
23
+ i.prop === prefix + 'box-orient' || i.prop === prefix + 'box-direction'
24
+ )
25
+ if (already) {
26
+ return undefined
27
+ }
28
+
29
+ let value = values[0]
30
+ let orient = value.includes('row') ? 'horizontal' : 'vertical'
31
+ let dir = value.includes('reverse') ? 'reverse' : 'normal'
32
+
33
+ let cloned = this.clone(decl)
34
+ cloned.prop = prefix + 'box-orient'
35
+ cloned.value = orient
36
+ if (this.needCascade(decl)) {
37
+ cloned.raws.before = this.calcBefore(prefixes, decl, prefix)
38
+ }
39
+ decl.parent.insertBefore(decl, cloned)
40
+
41
+ cloned = this.clone(decl)
42
+ cloned.prop = prefix + 'box-direction'
43
+ cloned.value = dir
44
+ if (this.needCascade(decl)) {
45
+ cloned.raws.before = this.calcBefore(prefixes, decl, prefix)
46
+ }
47
+ return decl.parent.insertBefore(decl, cloned)
48
+ }
49
+ }
50
+
51
+ FlexFlow.names = ['flex-flow', 'box-direction', 'box-orient']
52
+
53
+ module.exports = FlexFlow
web/node_modules/autoprefixer/lib/hacks/flex-grow.js ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let flexSpec = require('./flex-spec')
3
+
4
+ class Flex extends Declaration {
5
+ /**
6
+ * Return property name by final spec
7
+ */
8
+ normalize() {
9
+ return 'flex'
10
+ }
11
+
12
+ /**
13
+ * Return flex property for 2009 and 2012 specs
14
+ */
15
+ prefixed(prop, prefix) {
16
+ let spec
17
+ ;[spec, prefix] = flexSpec(prefix)
18
+ if (spec === 2009) {
19
+ return prefix + 'box-flex'
20
+ }
21
+ if (spec === 2012) {
22
+ return prefix + 'flex-positive'
23
+ }
24
+ return super.prefixed(prop, prefix)
25
+ }
26
+ }
27
+
28
+ Flex.names = ['flex-grow', 'flex-positive']
29
+
30
+ module.exports = Flex
web/node_modules/autoprefixer/lib/hacks/flex-shrink.js ADDED
@@ -0,0 +1,39 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let flexSpec = require('./flex-spec')
3
+
4
+ class FlexShrink extends Declaration {
5
+ /**
6
+ * Return property name by final spec
7
+ */
8
+ normalize() {
9
+ return 'flex-shrink'
10
+ }
11
+
12
+ /**
13
+ * Return flex property for 2012 spec
14
+ */
15
+ prefixed(prop, prefix) {
16
+ let spec
17
+ ;[spec, prefix] = flexSpec(prefix)
18
+ if (spec === 2012) {
19
+ return prefix + 'flex-negative'
20
+ }
21
+ return super.prefixed(prop, prefix)
22
+ }
23
+
24
+ /**
25
+ * Ignore 2009 spec and use flex property for 2012
26
+ */
27
+ set(decl, prefix) {
28
+ let spec
29
+ ;[spec, prefix] = flexSpec(prefix)
30
+ if (spec === 2012 || spec === 'final') {
31
+ return super.set(decl, prefix)
32
+ }
33
+ return undefined
34
+ }
35
+ }
36
+
37
+ FlexShrink.names = ['flex-shrink', 'flex-negative']
38
+
39
+ module.exports = FlexShrink
web/node_modules/autoprefixer/lib/hacks/flex-spec.js ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /**
2
+ * Return flexbox spec versions by prefix
3
+ */
4
+ module.exports = function (prefix) {
5
+ let spec
6
+ if (prefix === '-webkit- 2009' || prefix === '-moz-') {
7
+ spec = 2009
8
+ } else if (prefix === '-ms-') {
9
+ spec = 2012
10
+ } else if (prefix === '-webkit-') {
11
+ spec = 'final'
12
+ }
13
+
14
+ if (prefix === '-webkit- 2009') {
15
+ prefix = '-webkit-'
16
+ }
17
+
18
+ return [spec, prefix]
19
+ }
web/node_modules/autoprefixer/lib/hacks/flex-wrap.js ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let flexSpec = require('./flex-spec')
3
+
4
+ class FlexWrap extends Declaration {
5
+ /**
6
+ * Don't add prefix for 2009 spec
7
+ */
8
+ set(decl, prefix) {
9
+ let spec = flexSpec(prefix)[0]
10
+ if (spec !== 2009) {
11
+ return super.set(decl, prefix)
12
+ }
13
+ return undefined
14
+ }
15
+ }
16
+
17
+ FlexWrap.names = ['flex-wrap']
18
+
19
+ module.exports = FlexWrap
web/node_modules/autoprefixer/lib/hacks/flex.js ADDED
@@ -0,0 +1,54 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let list = require('postcss').list
2
+
3
+ let Declaration = require('../declaration')
4
+ let flexSpec = require('./flex-spec')
5
+
6
+ class Flex extends Declaration {
7
+ /**
8
+ * Return property name by final spec
9
+ */
10
+ normalize() {
11
+ return 'flex'
12
+ }
13
+
14
+ /**
15
+ * Change property name for 2009 spec
16
+ */
17
+ prefixed(prop, prefix) {
18
+ let spec
19
+ ;[spec, prefix] = flexSpec(prefix)
20
+ if (spec === 2009) {
21
+ return prefix + 'box-flex'
22
+ }
23
+ return super.prefixed(prop, prefix)
24
+ }
25
+
26
+ /**
27
+ * Spec 2009 supports only first argument
28
+ * Spec 2012 disallows unitless basis
29
+ */
30
+ set(decl, prefix) {
31
+ let spec = flexSpec(prefix)[0]
32
+ if (spec === 2009) {
33
+ decl.value = list.space(decl.value)[0]
34
+ decl.value = Flex.oldValues[decl.value] || decl.value
35
+ return super.set(decl, prefix)
36
+ }
37
+ if (spec === 2012) {
38
+ let components = list.space(decl.value)
39
+ if (components.length === 3 && components[2] === '0') {
40
+ decl.value = components.slice(0, 2).concat('0px').join(' ')
41
+ }
42
+ }
43
+ return super.set(decl, prefix)
44
+ }
45
+ }
46
+
47
+ Flex.names = ['flex', 'box-flex']
48
+
49
+ Flex.oldValues = {
50
+ auto: '1',
51
+ none: '0'
52
+ }
53
+
54
+ module.exports = Flex
web/node_modules/autoprefixer/lib/hacks/fullscreen.js ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Selector = require('../selector')
2
+
3
+ class Fullscreen extends Selector {
4
+ /**
5
+ * Return different selectors depend on prefix
6
+ */
7
+ prefixed(prefix) {
8
+ if (prefix === '-webkit-') {
9
+ return ':-webkit-full-screen'
10
+ }
11
+ if (prefix === '-moz-') {
12
+ return ':-moz-full-screen'
13
+ }
14
+ return `:${prefix}fullscreen`
15
+ }
16
+ }
17
+
18
+ Fullscreen.names = [':fullscreen']
19
+
20
+ module.exports = Fullscreen
web/node_modules/autoprefixer/lib/hacks/gradient.js ADDED
@@ -0,0 +1,460 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let parser = require('postcss-value-parser')
2
+
3
+ let OldValue = require('../old-value')
4
+ let utils = require('../utils')
5
+ let Value = require('../value')
6
+
7
+ const IS_DIRECTION = /top|left|right|bottom/gi
8
+
9
+ class Gradient extends Value {
10
+ /**
11
+ * Do not add non-webkit prefixes for list-style and object
12
+ */
13
+ add(decl, prefix) {
14
+ let p = decl.prop
15
+ if (p.includes('mask')) {
16
+ if (prefix === '-webkit-' || prefix === '-webkit- old') {
17
+ return super.add(decl, prefix)
18
+ }
19
+ } else if (
20
+ p === 'list-style' ||
21
+ p === 'list-style-image' ||
22
+ p === 'content'
23
+ ) {
24
+ if (prefix === '-webkit-' || prefix === '-webkit- old') {
25
+ return super.add(decl, prefix)
26
+ }
27
+ } else {
28
+ return super.add(decl, prefix)
29
+ }
30
+ return undefined
31
+ }
32
+
33
+ /**
34
+ * Get div token from exists parameters
35
+ */
36
+ cloneDiv(params) {
37
+ for (let i of params) {
38
+ if (i.type === 'div' && i.value === ',') {
39
+ return i
40
+ }
41
+ }
42
+ return { after: ' ', type: 'div', value: ',' }
43
+ }
44
+
45
+ /**
46
+ * Change colors syntax to old webkit
47
+ */
48
+ colorStops(params) {
49
+ let result = []
50
+ for (let i = 0; i < params.length; i++) {
51
+ let pos
52
+ let param = params[i]
53
+ let item
54
+ if (i === 0) {
55
+ continue
56
+ }
57
+
58
+ if (param.length === 0) {
59
+ continue
60
+ }
61
+
62
+ let color = parser.stringify(param[0])
63
+ if (param[1] && param[1].type === 'word') {
64
+ pos = param[1].value
65
+ } else if (param[2] && param[2].type === 'word') {
66
+ pos = param[2].value
67
+ }
68
+
69
+ let stop
70
+ if (i === 1 && (!pos || pos === '0%')) {
71
+ stop = `from(${color})`
72
+ } else if (i === params.length - 1 && (!pos || pos === '100%')) {
73
+ stop = `to(${color})`
74
+ } else if (pos) {
75
+ stop = `color-stop(${pos}, ${color})`
76
+ } else {
77
+ stop = `color-stop(${color})`
78
+ }
79
+
80
+ let div = param[param.length - 1]
81
+ params[i] = [{ type: 'word', value: stop }]
82
+ if (div && div.type === 'div' && div.value === ',') {
83
+ item = params[i].push(div)
84
+ }
85
+ result.push(item)
86
+ }
87
+ return result
88
+ }
89
+
90
+ /**
91
+ * Change new direction to old
92
+ */
93
+ convertDirection(params) {
94
+ if (params.length > 0) {
95
+ if (params[0].value === 'to') {
96
+ this.fixDirection(params)
97
+ } else if (params[0].value.includes('deg')) {
98
+ this.fixAngle(params)
99
+ } else if (this.isRadial(params)) {
100
+ this.fixRadial(params)
101
+ }
102
+ }
103
+ return params
104
+ }
105
+
106
+ /**
107
+ * Add 90 degrees
108
+ */
109
+ fixAngle(params) {
110
+ let first = params[0].value
111
+ first = parseFloat(first)
112
+ first = Math.abs(450 - first) % 360
113
+ first = this.roundFloat(first, 3)
114
+ params[0].value = `${first}deg`
115
+ }
116
+
117
+ /**
118
+ * Replace `to top left` to `bottom right`
119
+ */
120
+ fixDirection(params) {
121
+ params.splice(0, 2)
122
+
123
+ for (let param of params) {
124
+ if (param.type === 'div') {
125
+ break
126
+ }
127
+ if (param.type === 'word') {
128
+ param.value = this.revertDirection(param.value)
129
+ }
130
+ }
131
+ }
132
+
133
+ /**
134
+ * Fix radial direction syntax
135
+ */
136
+ fixRadial(params) {
137
+ let first = []
138
+ let second = []
139
+ let a, b, c, i, next
140
+
141
+ for (i = 0; i < params.length - 2; i++) {
142
+ a = params[i]
143
+ b = params[i + 1]
144
+ c = params[i + 2]
145
+ if (a.type === 'space' && b.value === 'at' && c.type === 'space') {
146
+ next = i + 3
147
+ break
148
+ } else {
149
+ first.push(a)
150
+ }
151
+ }
152
+
153
+ let div
154
+ for (i = next; i < params.length; i++) {
155
+ if (params[i].type === 'div') {
156
+ div = params[i]
157
+ break
158
+ } else {
159
+ second.push(params[i])
160
+ }
161
+ }
162
+
163
+ params.splice(0, i, ...second, div, ...first)
164
+ }
165
+
166
+ /**
167
+ * Look for at word
168
+ */
169
+ isRadial(params) {
170
+ let state = 'before'
171
+ for (let param of params) {
172
+ if (state === 'before' && param.type === 'space') {
173
+ state = 'at'
174
+ } else if (state === 'at' && param.value === 'at') {
175
+ state = 'after'
176
+ } else if (state === 'after' && param.type === 'space') {
177
+ return true
178
+ } else if (param.type === 'div') {
179
+ break
180
+ } else {
181
+ state = 'before'
182
+ }
183
+ }
184
+ return false
185
+ }
186
+
187
+ /**
188
+ * Replace old direction to new
189
+ */
190
+ newDirection(params) {
191
+ if (!params[0]) {
192
+ return params
193
+ }
194
+ if (params[0].value === 'to') {
195
+ return params
196
+ }
197
+ IS_DIRECTION.lastIndex = 0 // reset search index of global regexp
198
+ if (!IS_DIRECTION.test(params[0].value)) {
199
+ return params
200
+ }
201
+
202
+ params.unshift(
203
+ {
204
+ type: 'word',
205
+ value: 'to'
206
+ },
207
+ {
208
+ type: 'space',
209
+ value: ' '
210
+ }
211
+ )
212
+
213
+ for (let i = 2; i < params.length; i++) {
214
+ if (params[i].type === 'div') {
215
+ break
216
+ }
217
+ if (params[i].type === 'word') {
218
+ params[i].value = this.revertDirection(params[i].value)
219
+ }
220
+ }
221
+
222
+ return params
223
+ }
224
+
225
+ /**
226
+ * Normalize angle
227
+ */
228
+ normalize(nodes, gradientName) {
229
+ if (!nodes[0]) return nodes
230
+
231
+ if (/-?\d+(.\d+)?grad/.test(nodes[0].value)) {
232
+ nodes[0].value = this.normalizeUnit(nodes[0].value, 400)
233
+ } else if (/-?\d+(.\d+)?rad/.test(nodes[0].value)) {
234
+ nodes[0].value = this.normalizeUnit(nodes[0].value, 2 * Math.PI)
235
+ } else if (/-?\d+(.\d+)?turn/.test(nodes[0].value)) {
236
+ nodes[0].value = this.normalizeUnit(nodes[0].value, 1)
237
+ } else if (nodes[0].value.includes('deg')) {
238
+ let num = parseFloat(nodes[0].value)
239
+ num = ((num % 360) + 360) % 360
240
+ nodes[0].value = `${num}deg`
241
+ }
242
+
243
+ if (
244
+ gradientName === 'linear-gradient' ||
245
+ gradientName === 'repeating-linear-gradient'
246
+ ) {
247
+ let direction = nodes[0].value
248
+
249
+ // Unitless zero for `<angle>` values are allowed in CSS gradients and transforms.
250
+ // Spec: https://github.com/w3c/csswg-drafts/commit/602789171429b2231223ab1e5acf8f7f11652eb3
251
+ if (direction === '0deg' || direction === '0') {
252
+ nodes = this.replaceFirst(nodes, 'to', ' ', 'top')
253
+ } else if (direction === '90deg') {
254
+ nodes = this.replaceFirst(nodes, 'to', ' ', 'right')
255
+ } else if (direction === '180deg') {
256
+ nodes = this.replaceFirst(nodes, 'to', ' ', 'bottom') // default value
257
+ } else if (direction === '270deg') {
258
+ nodes = this.replaceFirst(nodes, 'to', ' ', 'left')
259
+ }
260
+ }
261
+
262
+ return nodes
263
+ }
264
+
265
+ /**
266
+ * Convert angle unit to deg
267
+ */
268
+ normalizeUnit(str, full) {
269
+ let num = parseFloat(str)
270
+ let deg = (num / full) * 360
271
+ return `${deg}deg`
272
+ }
273
+
274
+ /**
275
+ * Remove old WebKit gradient too
276
+ */
277
+ old(prefix) {
278
+ if (prefix === '-webkit-') {
279
+ let type
280
+ if (this.name === 'linear-gradient') {
281
+ type = 'linear'
282
+ } else if (this.name === 'repeating-linear-gradient') {
283
+ type = 'repeating-linear'
284
+ } else if (this.name === 'repeating-radial-gradient') {
285
+ type = 'repeating-radial'
286
+ } else {
287
+ type = 'radial'
288
+ }
289
+ let string = '-gradient'
290
+ let regexp = utils.regexp(
291
+ `-webkit-(${type}-gradient|gradient\\(\\s*${type})`,
292
+ false
293
+ )
294
+
295
+ return new OldValue(this.name, prefix + this.name, string, regexp)
296
+ } else {
297
+ return super.old(prefix)
298
+ }
299
+ }
300
+
301
+ /**
302
+ * Change direction syntax to old webkit
303
+ */
304
+ oldDirection(params) {
305
+ let div = this.cloneDiv(params[0])
306
+
307
+ if (!params[0][0] || params[0][0].value !== 'to') {
308
+ return params.unshift([
309
+ { type: 'word', value: Gradient.oldDirections.bottom },
310
+ div
311
+ ])
312
+ } else {
313
+ let words = []
314
+ for (let node of params[0].slice(2)) {
315
+ if (node.type === 'word') {
316
+ words.push(node.value.toLowerCase())
317
+ }
318
+ }
319
+
320
+ words = words.join(' ')
321
+ let old = Gradient.oldDirections[words] || words
322
+
323
+ params[0] = [{ type: 'word', value: old }, div]
324
+ return params[0]
325
+ }
326
+ }
327
+
328
+ /**
329
+ * Convert to old webkit syntax
330
+ */
331
+ oldWebkit(node) {
332
+ let { nodes } = node
333
+ let string = parser.stringify(node.nodes)
334
+
335
+ if (this.name !== 'linear-gradient') {
336
+ return false
337
+ }
338
+ if (nodes.length === 0) {
339
+ return false
340
+ }
341
+ if (nodes[0] && nodes[0].value.includes('deg')) {
342
+ return false
343
+ }
344
+ if (
345
+ string.includes('px') ||
346
+ string.includes('-corner') ||
347
+ string.includes('-side')
348
+ ) {
349
+ return false
350
+ }
351
+ if (string.includes('var(')) {
352
+ return false
353
+ }
354
+
355
+ let params = [[]]
356
+ for (let i of nodes) {
357
+ params[params.length - 1].push(i)
358
+ if (i.type === 'div' && i.value === ',') {
359
+ params.push([])
360
+ }
361
+ }
362
+
363
+ this.oldDirection(params)
364
+ this.colorStops(params)
365
+
366
+ node.nodes = []
367
+ for (let param of params) {
368
+ node.nodes.push(...param)
369
+ }
370
+
371
+ node.nodes.unshift(
372
+ { type: 'word', value: 'linear' },
373
+ this.cloneDiv(node.nodes)
374
+ )
375
+ node.value = '-webkit-gradient'
376
+
377
+ return true
378
+ }
379
+
380
+ /**
381
+ * Change degrees for webkit prefix
382
+ */
383
+ replace(string, prefix) {
384
+ let ast = parser(string)
385
+ for (let node of ast.nodes) {
386
+ let gradientName = this.name // gradient name
387
+ if (node.type === 'function' && node.value === gradientName) {
388
+ node.nodes = this.newDirection(node.nodes)
389
+ node.nodes = this.normalize(node.nodes, gradientName)
390
+ if (prefix === '-webkit- old') {
391
+ let changes = this.oldWebkit(node)
392
+ if (!changes) {
393
+ return false
394
+ }
395
+ } else {
396
+ node.nodes = this.convertDirection(node.nodes)
397
+ node.value = prefix + node.value
398
+ }
399
+ }
400
+ }
401
+ return ast.toString()
402
+ }
403
+
404
+ /**
405
+ * Replace first token
406
+ */
407
+ replaceFirst(params, ...words) {
408
+ let prefix = words.map(i => {
409
+ if (i === ' ') {
410
+ return { type: 'space', value: i }
411
+ }
412
+ return { type: 'word', value: i }
413
+ })
414
+ return prefix.concat(params.slice(1))
415
+ }
416
+
417
+ revertDirection(word) {
418
+ return Gradient.directions[word.toLowerCase()] || word
419
+ }
420
+
421
+ /**
422
+ * Round float and save digits under dot
423
+ */
424
+ roundFloat(float, digits) {
425
+ return parseFloat(float.toFixed(digits))
426
+ }
427
+ }
428
+
429
+ Gradient.names = [
430
+ 'linear-gradient',
431
+ 'repeating-linear-gradient',
432
+ 'radial-gradient',
433
+ 'repeating-radial-gradient'
434
+ ]
435
+
436
+ Gradient.directions = {
437
+ bottom: 'top',
438
+ left: 'right',
439
+ right: 'left',
440
+ top: 'bottom' // default value
441
+ }
442
+
443
+ // Direction to replace
444
+ Gradient.oldDirections = {
445
+ 'bottom': 'left top, left bottom',
446
+ 'bottom left': 'right top, left bottom',
447
+ 'bottom right': 'left top, right bottom',
448
+ 'left': 'right top, left top',
449
+
450
+ 'left bottom': 'right top, left bottom',
451
+ 'left top': 'right bottom, left top',
452
+ 'right': 'left top, right top',
453
+ 'right bottom': 'left top, right bottom',
454
+ 'right top': 'left bottom, right top',
455
+ 'top': 'left bottom, left top',
456
+ 'top left': 'right bottom, left top',
457
+ 'top right': 'left bottom, right top'
458
+ }
459
+
460
+ module.exports = Gradient
web/node_modules/autoprefixer/lib/hacks/grid-area.js ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let utils = require('./grid-utils')
3
+
4
+ class GridArea extends Declaration {
5
+ /**
6
+ * Translate grid-area to separate -ms- prefixed properties
7
+ */
8
+ insert(decl, prefix, prefixes, result) {
9
+ if (prefix !== '-ms-') return super.insert(decl, prefix, prefixes)
10
+
11
+ let values = utils.parse(decl)
12
+
13
+ let [rowStart, rowSpan] = utils.translate(values, 0, 2)
14
+ let [columnStart, columnSpan] = utils.translate(values, 1, 3)
15
+
16
+ ;[
17
+ ['grid-row', rowStart],
18
+ ['grid-row-span', rowSpan],
19
+ ['grid-column', columnStart],
20
+ ['grid-column-span', columnSpan]
21
+ ].forEach(([prop, value]) => {
22
+ utils.insertDecl(decl, prop, value)
23
+ })
24
+
25
+ utils.warnTemplateSelectorNotFound(decl, result)
26
+ utils.warnIfGridRowColumnExists(decl, result)
27
+
28
+ return undefined
29
+ }
30
+ }
31
+
32
+ GridArea.names = ['grid-area']
33
+
34
+ module.exports = GridArea
web/node_modules/autoprefixer/lib/hacks/grid-column-align.js ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+
3
+ class GridColumnAlign extends Declaration {
4
+ /**
5
+ * Do not prefix flexbox values
6
+ */
7
+ check(decl) {
8
+ return !decl.value.includes('flex-') && decl.value !== 'baseline'
9
+ }
10
+
11
+ /**
12
+ * Change IE property back
13
+ */
14
+ normalize() {
15
+ return 'justify-self'
16
+ }
17
+
18
+ /**
19
+ * Change property name for IE
20
+ */
21
+ prefixed(prop, prefix) {
22
+ return prefix + 'grid-column-align'
23
+ }
24
+ }
25
+
26
+ GridColumnAlign.names = ['grid-column-align']
27
+
28
+ module.exports = GridColumnAlign
web/node_modules/autoprefixer/lib/hacks/grid-end.js ADDED
@@ -0,0 +1,52 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let { isPureNumber } = require('../utils')
3
+
4
+ class GridEnd extends Declaration {
5
+ /**
6
+ * Change repeating syntax for IE
7
+ */
8
+ insert(decl, prefix, prefixes, result) {
9
+ if (prefix !== '-ms-') return super.insert(decl, prefix, prefixes)
10
+
11
+ let clonedDecl = this.clone(decl)
12
+
13
+ let startProp = decl.prop.replace(/end$/, 'start')
14
+ let spanProp = prefix + decl.prop.replace(/end$/, 'span')
15
+
16
+ if (decl.parent.some(i => i.prop === spanProp)) {
17
+ return undefined
18
+ }
19
+
20
+ clonedDecl.prop = spanProp
21
+
22
+ if (decl.value.includes('span')) {
23
+ clonedDecl.value = decl.value.replace(/span\s/i, '')
24
+ } else {
25
+ let startDecl
26
+ decl.parent.walkDecls(startProp, d => {
27
+ startDecl = d
28
+ })
29
+ if (startDecl) {
30
+ if (isPureNumber(startDecl.value)) {
31
+ let value = Number(decl.value) - Number(startDecl.value) + ''
32
+ clonedDecl.value = value
33
+ } else {
34
+ return undefined
35
+ }
36
+ } else {
37
+ decl.warn(
38
+ result,
39
+ `Can not prefix ${decl.prop} (${startProp} is not found)`
40
+ )
41
+ }
42
+ }
43
+
44
+ decl.cloneBefore(clonedDecl)
45
+
46
+ return undefined
47
+ }
48
+ }
49
+
50
+ GridEnd.names = ['grid-row-end', 'grid-column-end']
51
+
52
+ module.exports = GridEnd
web/node_modules/autoprefixer/lib/hacks/grid-row-align.js ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+
3
+ class GridRowAlign extends Declaration {
4
+ /**
5
+ * Do not prefix flexbox values
6
+ */
7
+ check(decl) {
8
+ return !decl.value.includes('flex-') && decl.value !== 'baseline'
9
+ }
10
+
11
+ /**
12
+ * Change IE property back
13
+ */
14
+ normalize() {
15
+ return 'align-self'
16
+ }
17
+
18
+ /**
19
+ * Change property name for IE
20
+ */
21
+ prefixed(prop, prefix) {
22
+ return prefix + 'grid-row-align'
23
+ }
24
+ }
25
+
26
+ GridRowAlign.names = ['grid-row-align']
27
+
28
+ module.exports = GridRowAlign
web/node_modules/autoprefixer/lib/hacks/grid-row-column.js ADDED
@@ -0,0 +1,33 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let utils = require('./grid-utils')
3
+
4
+ class GridRowColumn extends Declaration {
5
+ /**
6
+ * Translate grid-row / grid-column to separate -ms- prefixed properties
7
+ */
8
+ insert(decl, prefix, prefixes) {
9
+ if (prefix !== '-ms-') return super.insert(decl, prefix, prefixes)
10
+
11
+ let values = utils.parse(decl)
12
+ let [start, span] = utils.translate(values, 0, 1)
13
+
14
+ let hasStartValueSpan = values[0] && values[0].includes('span')
15
+
16
+ if (hasStartValueSpan) {
17
+ span = values[0].join('').replace(/\D/g, '')
18
+ }
19
+
20
+ ;[
21
+ [decl.prop, start],
22
+ [`${decl.prop}-span`, span]
23
+ ].forEach(([prop, value]) => {
24
+ utils.insertDecl(decl, prop, value)
25
+ })
26
+
27
+ return undefined
28
+ }
29
+ }
30
+
31
+ GridRowColumn.names = ['grid-row', 'grid-column']
32
+
33
+ module.exports = GridRowColumn
web/node_modules/autoprefixer/lib/hacks/grid-rows-columns.js ADDED
@@ -0,0 +1,125 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let Processor = require('../processor')
3
+ let {
4
+ autoplaceGridItems,
5
+ getGridGap,
6
+ inheritGridGap,
7
+ prefixTrackProp,
8
+ prefixTrackValue
9
+ } = require('./grid-utils')
10
+
11
+ class GridRowsColumns extends Declaration {
12
+ insert(decl, prefix, prefixes, result) {
13
+ if (prefix !== '-ms-') return super.insert(decl, prefix, prefixes)
14
+
15
+ let { parent, prop, value } = decl
16
+ let isRowProp = prop.includes('rows')
17
+ let isColumnProp = prop.includes('columns')
18
+
19
+ let hasGridTemplate = parent.some(
20
+ i => i.prop === 'grid-template' || i.prop === 'grid-template-areas'
21
+ )
22
+
23
+ /**
24
+ * Not to prefix rows declaration if grid-template(-areas) is present
25
+ */
26
+ if (hasGridTemplate && isRowProp) {
27
+ return false
28
+ }
29
+
30
+ let processor = new Processor({ options: {} })
31
+ let status = processor.gridStatus(parent, result)
32
+ let gap = getGridGap(decl)
33
+ gap = inheritGridGap(decl, gap) || gap
34
+
35
+ let gapValue = isRowProp ? gap.row : gap.column
36
+
37
+ if ((status === 'no-autoplace' || status === true) && !hasGridTemplate) {
38
+ gapValue = null
39
+ }
40
+
41
+ let prefixValue = prefixTrackValue({
42
+ gap: gapValue,
43
+ value
44
+ })
45
+
46
+ /**
47
+ * Insert prefixes
48
+ */
49
+ decl.cloneBefore({
50
+ prop: prefixTrackProp({ prefix, prop }),
51
+ value: prefixValue
52
+ })
53
+
54
+ let autoflow = parent.nodes.find(i => i.prop === 'grid-auto-flow')
55
+ let autoflowValue = 'row'
56
+
57
+ if (autoflow && !processor.disabled(autoflow, result)) {
58
+ autoflowValue = autoflow.value.trim()
59
+ }
60
+ if (status === 'autoplace') {
61
+ /**
62
+ * Show warning if grid-template-rows decl is not found
63
+ */
64
+ let rowDecl = parent.nodes.find(i => i.prop === 'grid-template-rows')
65
+
66
+ if (!rowDecl && hasGridTemplate) {
67
+ return undefined
68
+ } else if (!rowDecl && !hasGridTemplate) {
69
+ decl.warn(
70
+ result,
71
+ 'Autoplacement does not work without grid-template-rows property'
72
+ )
73
+ return undefined
74
+ }
75
+
76
+ /**
77
+ * Show warning if grid-template-columns decl is not found
78
+ */
79
+ let columnDecl = parent.nodes.find(i => {
80
+ return i.prop === 'grid-template-columns'
81
+ })
82
+ if (!columnDecl && !hasGridTemplate) {
83
+ decl.warn(
84
+ result,
85
+ 'Autoplacement does not work without grid-template-columns property'
86
+ )
87
+ }
88
+
89
+ /**
90
+ * Autoplace grid items
91
+ */
92
+ if (isColumnProp && !hasGridTemplate) {
93
+ autoplaceGridItems(decl, result, gap, autoflowValue)
94
+ }
95
+ }
96
+
97
+ return undefined
98
+ }
99
+
100
+ /**
101
+ * Change IE property back
102
+ */
103
+ normalize(prop) {
104
+ return prop.replace(/^grid-(rows|columns)/, 'grid-template-$1')
105
+ }
106
+
107
+ /**
108
+ * Change property name for IE
109
+ */
110
+ prefixed(prop, prefix) {
111
+ if (prefix === '-ms-') {
112
+ return prefixTrackProp({ prefix, prop })
113
+ }
114
+ return super.prefixed(prop, prefix)
115
+ }
116
+ }
117
+
118
+ GridRowsColumns.names = [
119
+ 'grid-template-rows',
120
+ 'grid-template-columns',
121
+ 'grid-rows',
122
+ 'grid-columns'
123
+ ]
124
+
125
+ module.exports = GridRowsColumns
web/node_modules/autoprefixer/lib/hacks/grid-start.js ADDED
@@ -0,0 +1,33 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+
3
+ class GridStart extends Declaration {
4
+ /**
5
+ * Do not add prefix for unsupported value in IE
6
+ */
7
+ check(decl) {
8
+ let value = decl.value
9
+ return !value.includes('/') && !value.includes('span')
10
+ }
11
+
12
+ /**
13
+ * Return a final spec property
14
+ */
15
+ normalize(prop) {
16
+ return prop.replace('-start', '')
17
+ }
18
+
19
+ /**
20
+ * Change property name for IE
21
+ */
22
+ prefixed(prop, prefix) {
23
+ let result = super.prefixed(prop, prefix)
24
+ if (prefix === '-ms-') {
25
+ result = result.replace('-start', '')
26
+ }
27
+ return result
28
+ }
29
+ }
30
+
31
+ GridStart.names = ['grid-row-start', 'grid-column-start']
32
+
33
+ module.exports = GridStart
web/node_modules/autoprefixer/lib/hacks/grid-template-areas.js ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let {
3
+ getGridGap,
4
+ inheritGridGap,
5
+ parseGridAreas,
6
+ prefixTrackProp,
7
+ prefixTrackValue,
8
+ warnGridGap,
9
+ warnMissedAreas
10
+ } = require('./grid-utils')
11
+
12
+ function getGridRows(tpl) {
13
+ return tpl
14
+ .trim()
15
+ .slice(1, -1)
16
+ .split(/["']\s*["']?/g)
17
+ }
18
+
19
+ class GridTemplateAreas extends Declaration {
20
+ /**
21
+ * Translate grid-template-areas to separate -ms- prefixed properties
22
+ */
23
+ insert(decl, prefix, prefixes, result) {
24
+ if (prefix !== '-ms-') return super.insert(decl, prefix, prefixes)
25
+
26
+ let hasColumns = false
27
+ let hasRows = false
28
+ let parent = decl.parent
29
+ let gap = getGridGap(decl)
30
+ gap = inheritGridGap(decl, gap) || gap
31
+
32
+ // remove already prefixed rows
33
+ // to prevent doubling prefixes
34
+ parent.walkDecls(/-ms-grid-rows/, i => i.remove())
35
+
36
+ // add empty tracks to rows
37
+ parent.walkDecls(/grid-template-(rows|columns)/, trackDecl => {
38
+ if (trackDecl.prop === 'grid-template-rows') {
39
+ hasRows = true
40
+ let { prop, value } = trackDecl
41
+ trackDecl.cloneBefore({
42
+ prop: prefixTrackProp({ prefix, prop }),
43
+ value: prefixTrackValue({ gap: gap.row, value })
44
+ })
45
+ } else {
46
+ hasColumns = true
47
+ }
48
+ })
49
+
50
+ let gridRows = getGridRows(decl.value)
51
+
52
+ if (hasColumns && !hasRows && gap.row && gridRows.length > 1) {
53
+ decl.cloneBefore({
54
+ prop: '-ms-grid-rows',
55
+ raws: {},
56
+ value: prefixTrackValue({
57
+ gap: gap.row,
58
+ value: `repeat(${gridRows.length}, auto)`
59
+ })
60
+ })
61
+ }
62
+
63
+ // warnings
64
+ warnGridGap({
65
+ decl,
66
+ gap,
67
+ hasColumns,
68
+ result
69
+ })
70
+
71
+ let areas = parseGridAreas({
72
+ gap,
73
+ rows: gridRows
74
+ })
75
+
76
+ warnMissedAreas(areas, decl, result)
77
+
78
+ return decl
79
+ }
80
+ }
81
+
82
+ GridTemplateAreas.names = ['grid-template-areas']
83
+
84
+ module.exports = GridTemplateAreas
web/node_modules/autoprefixer/lib/hacks/grid-template.js ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ let Declaration = require('../declaration')
2
+ let {
3
+ getGridGap,
4
+ inheritGridGap,
5
+ parseTemplate,
6
+ warnGridGap,
7
+ warnMissedAreas
8
+ } = require('./grid-utils')
9
+
10
+ class GridTemplate extends Declaration {
11
+ /**
12
+ * Translate grid-template to separate -ms- prefixed properties
13
+ */
14
+ insert(decl, prefix, prefixes, result) {
15
+ if (prefix !== '-ms-') return super.insert(decl, prefix, prefixes)
16
+
17
+ if (decl.parent.some(i => i.prop === '-ms-grid-rows')) {
18
+ return undefined
19
+ }
20
+
21
+ let gap = getGridGap(decl)
22
+
23
+ /**
24
+ * we must insert inherited gap values in some cases:
25
+ * if we are inside media query && if we have no grid-gap value
26
+ */
27
+ let inheritedGap = inheritGridGap(decl, gap)
28
+
29
+ let { areas, columns, rows } = parseTemplate({
30
+ decl,
31
+ gap: inheritedGap || gap
32
+ })
33
+
34
+ let hasAreas = Object.keys(areas).length > 0
35
+ let hasRows = Boolean(rows)
36
+ let hasColumns = Boolean(columns)
37
+
38
+ warnGridGap({
39
+ decl,
40
+ gap,
41
+ hasColumns,
42
+ result
43
+ })
44
+
45
+ warnMissedAreas(areas, decl, result)
46
+
47
+ if ((hasRows && hasColumns) || hasAreas) {
48
+ decl.cloneBefore({
49
+ prop: '-ms-grid-rows',
50
+ raws: {},
51
+ value: rows
52
+ })
53
+ }
54
+
55
+ if (hasColumns) {
56
+ decl.cloneBefore({
57
+ prop: '-ms-grid-columns',
58
+ raws: {},
59
+ value: columns
60
+ })
61
+ }
62
+
63
+ return decl
64
+ }
65
+ }
66
+
67
+ GridTemplate.names = ['grid-template']
68
+
69
+ module.exports = GridTemplate