immosquare-cleaner 0.1.40 → 0.1.41

Sign up to get free protection for your applications and to get access to all the features.
Files changed (121) hide show
  1. checksums.yaml +4 -4
  2. data/lib/immosquare-cleaner/version.rb +1 -1
  3. data/node_modules/@eslint/config-array/README.md +9 -3
  4. data/node_modules/@eslint/config-array/dist/cjs/index.cjs +1 -0
  5. data/node_modules/@eslint/config-array/dist/esm/index.js +1 -0
  6. data/node_modules/@eslint/config-array/package.json +2 -2
  7. data/node_modules/@eslint/eslintrc/node_modules/espree/LICENSE +25 -0
  8. data/node_modules/@eslint/eslintrc/node_modules/espree/README.md +244 -0
  9. data/node_modules/@eslint/eslintrc/node_modules/espree/dist/espree.cjs +883 -0
  10. data/node_modules/@eslint/eslintrc/node_modules/espree/espree.js +177 -0
  11. data/node_modules/@eslint/eslintrc/node_modules/espree/lib/espree.js +349 -0
  12. data/node_modules/@eslint/eslintrc/node_modules/espree/lib/features.js +27 -0
  13. data/node_modules/@eslint/eslintrc/node_modules/espree/lib/options.js +123 -0
  14. data/node_modules/@eslint/eslintrc/node_modules/espree/lib/token-translator.js +263 -0
  15. data/node_modules/@eslint/eslintrc/node_modules/espree/lib/version.js +3 -0
  16. data/node_modules/@eslint/eslintrc/node_modules/espree/node_modules/acorn/CHANGELOG.md +880 -0
  17. data/node_modules/@eslint/eslintrc/node_modules/espree/node_modules/acorn/LICENSE +21 -0
  18. data/node_modules/@eslint/eslintrc/node_modules/espree/node_modules/acorn/README.md +283 -0
  19. data/node_modules/@eslint/eslintrc/node_modules/espree/node_modules/acorn/bin/acorn +4 -0
  20. data/node_modules/@eslint/eslintrc/node_modules/espree/node_modules/acorn/dist/acorn.d.mts +857 -0
  21. data/node_modules/@eslint/eslintrc/node_modules/espree/node_modules/acorn/dist/acorn.d.ts +857 -0
  22. data/node_modules/@eslint/eslintrc/node_modules/espree/node_modules/acorn/dist/acorn.js +6002 -0
  23. data/node_modules/@eslint/eslintrc/node_modules/espree/node_modules/acorn/dist/acorn.mjs +5973 -0
  24. data/node_modules/@eslint/eslintrc/node_modules/espree/node_modules/acorn/dist/bin.js +90 -0
  25. data/node_modules/@eslint/eslintrc/node_modules/espree/node_modules/acorn/package.json +50 -0
  26. data/node_modules/@eslint/eslintrc/node_modules/espree/package.json +86 -0
  27. data/node_modules/@eslint/js/package.json +1 -1
  28. data/node_modules/@eslint-community/regexpp/index.d.ts +19 -5
  29. data/node_modules/@eslint-community/regexpp/index.js +138 -17
  30. data/node_modules/@eslint-community/regexpp/index.js.map +1 -1
  31. data/node_modules/@eslint-community/regexpp/index.mjs +138 -17
  32. data/node_modules/@eslint-community/regexpp/index.mjs.map +1 -1
  33. data/node_modules/@eslint-community/regexpp/package.json +1 -3
  34. data/node_modules/acorn/CHANGELOG.md +24 -0
  35. data/node_modules/acorn/README.md +5 -6
  36. data/node_modules/acorn/dist/acorn.d.mts +8 -9
  37. data/node_modules/acorn/dist/acorn.d.ts +8 -9
  38. data/node_modules/acorn/dist/acorn.js +92 -29
  39. data/node_modules/acorn/dist/acorn.mjs +92 -29
  40. data/node_modules/acorn/package.json +3 -3
  41. data/node_modules/eslint/README.md +7 -8
  42. data/node_modules/eslint/conf/ecma-version.js +1 -1
  43. data/node_modules/eslint/conf/globals.js +6 -1
  44. data/node_modules/eslint/lib/cli.js +23 -2
  45. data/node_modules/eslint/lib/eslint/eslint-helpers.js +5 -0
  46. data/node_modules/eslint/lib/eslint/eslint.js +16 -2
  47. data/node_modules/eslint/lib/eslint/legacy-eslint.js +14 -0
  48. data/node_modules/eslint/lib/languages/js/index.js +10 -5
  49. data/node_modules/eslint/lib/languages/js/source-code/source-code.js +16 -6
  50. data/node_modules/eslint/lib/linter/apply-disable-directives.js +6 -3
  51. data/node_modules/eslint/lib/linter/config-comment-parser.js +3 -16
  52. data/node_modules/eslint/lib/linter/linter.js +194 -149
  53. data/node_modules/eslint/lib/linter/node-event-generator.js +2 -4
  54. data/node_modules/eslint/lib/linter/vfile.js +7 -0
  55. data/node_modules/eslint/lib/options.js +13 -1
  56. data/node_modules/eslint/lib/rules/no-restricted-imports.js +12 -5
  57. data/node_modules/eslint/lib/rules/no-unused-vars.js +34 -32
  58. data/node_modules/eslint/lib/rules/no-useless-backreference.js +81 -31
  59. data/node_modules/eslint/lib/rules/utils/regular-expressions.js +1 -1
  60. data/node_modules/eslint/lib/shared/flags.js +26 -0
  61. data/node_modules/eslint/lib/shared/logging.js +10 -1
  62. data/node_modules/eslint/lib/shared/types.js +1 -1
  63. data/node_modules/eslint/package.json +9 -13
  64. data/node_modules/eslint-scope/dist/eslint-scope.cjs +2 -2
  65. data/node_modules/eslint-scope/lib/referencer.js +1 -1
  66. data/node_modules/eslint-scope/lib/version.js +1 -1
  67. data/node_modules/eslint-scope/package.json +2 -2
  68. data/node_modules/espree/README.md +5 -5
  69. data/node_modules/espree/dist/espree.cjs +62 -6
  70. data/node_modules/espree/espree.js +1 -4
  71. data/node_modules/espree/lib/options.js +3 -2
  72. data/node_modules/espree/lib/token-translator.js +1 -1
  73. data/node_modules/espree/lib/version.js +1 -1
  74. data/node_modules/espree/package.json +7 -7
  75. data/node_modules/js-tokens/CHANGELOG.md +17 -0
  76. data/node_modules/js-tokens/LICENSE +1 -1
  77. data/node_modules/js-tokens/README.md +25 -7
  78. data/node_modules/js-tokens/index.js +3 -3
  79. data/node_modules/js-tokens/package.json +5 -5
  80. data/node_modules/jscodeshift/CHANGELOG.md +5 -0
  81. data/node_modules/jscodeshift/bin/jscodeshift.js +1 -1
  82. data/node_modules/jscodeshift/package.json +1 -2
  83. data/node_modules/jscodeshift/website/index.htm +9 -0
  84. data/node_modules/prettier/LICENSE +35 -34
  85. data/node_modules/prettier/doc.js +2 -2
  86. data/node_modules/prettier/doc.mjs +2 -2
  87. data/node_modules/prettier/index.cjs +8 -8
  88. data/node_modules/prettier/index.d.ts +1 -2
  89. data/node_modules/prettier/index.mjs +636 -704
  90. data/node_modules/prettier/internal/cli.mjs +4 -4
  91. data/node_modules/prettier/package.json +1 -1
  92. data/node_modules/prettier/plugins/acorn.js +14 -12
  93. data/node_modules/prettier/plugins/acorn.mjs +14 -12
  94. data/node_modules/prettier/plugins/angular.js +1 -1
  95. data/node_modules/prettier/plugins/angular.mjs +1 -1
  96. data/node_modules/prettier/plugins/babel.js +10 -11
  97. data/node_modules/prettier/plugins/babel.mjs +10 -11
  98. data/node_modules/prettier/plugins/estree.js +27 -27
  99. data/node_modules/prettier/plugins/estree.mjs +27 -27
  100. data/node_modules/prettier/plugins/flow.js +15 -16
  101. data/node_modules/prettier/plugins/flow.mjs +15 -16
  102. data/node_modules/prettier/plugins/glimmer.js +5 -5
  103. data/node_modules/prettier/plugins/glimmer.mjs +5 -5
  104. data/node_modules/prettier/plugins/graphql.js +8 -8
  105. data/node_modules/prettier/plugins/graphql.mjs +8 -8
  106. data/node_modules/prettier/plugins/html.js +17 -17
  107. data/node_modules/prettier/plugins/html.mjs +17 -17
  108. data/node_modules/prettier/plugins/markdown.js +44 -44
  109. data/node_modules/prettier/plugins/markdown.mjs +44 -44
  110. data/node_modules/prettier/plugins/meriyah.js +4 -5
  111. data/node_modules/prettier/plugins/meriyah.mjs +4 -5
  112. data/node_modules/prettier/plugins/postcss.js +26 -26
  113. data/node_modules/prettier/plugins/postcss.mjs +26 -26
  114. data/node_modules/prettier/plugins/typescript.js +15 -20
  115. data/node_modules/prettier/plugins/typescript.mjs +15 -20
  116. data/node_modules/prettier/plugins/yaml.js +6 -6
  117. data/node_modules/prettier/plugins/yaml.mjs +6 -6
  118. data/node_modules/prettier/standalone.js +31 -30
  119. data/node_modules/prettier/standalone.mjs +28 -27
  120. data/package.json +4 -4
  121. metadata +24 -2
@@ -0,0 +1,263 @@
1
+ /**
2
+ * @fileoverview Translates tokens between Acorn format and Esprima format.
3
+ * @author Nicholas C. Zakas
4
+ */
5
+
6
+ //------------------------------------------------------------------------------
7
+ // Requirements
8
+ //------------------------------------------------------------------------------
9
+
10
+ // none!
11
+
12
+ //------------------------------------------------------------------------------
13
+ // Private
14
+ //------------------------------------------------------------------------------
15
+
16
+
17
+ // Esprima Token Types
18
+ const Token = {
19
+ Boolean: "Boolean",
20
+ EOF: "<end>",
21
+ Identifier: "Identifier",
22
+ PrivateIdentifier: "PrivateIdentifier",
23
+ Keyword: "Keyword",
24
+ Null: "Null",
25
+ Numeric: "Numeric",
26
+ Punctuator: "Punctuator",
27
+ String: "String",
28
+ RegularExpression: "RegularExpression",
29
+ Template: "Template",
30
+ JSXIdentifier: "JSXIdentifier",
31
+ JSXText: "JSXText"
32
+ };
33
+
34
+ /**
35
+ * Converts part of a template into an Esprima token.
36
+ * @param {AcornToken[]} tokens The Acorn tokens representing the template.
37
+ * @param {string} code The source code.
38
+ * @returns {EsprimaToken} The Esprima equivalent of the template token.
39
+ * @private
40
+ */
41
+ function convertTemplatePart(tokens, code) {
42
+ const firstToken = tokens[0],
43
+ lastTemplateToken = tokens[tokens.length - 1];
44
+
45
+ const token = {
46
+ type: Token.Template,
47
+ value: code.slice(firstToken.start, lastTemplateToken.end)
48
+ };
49
+
50
+ if (firstToken.loc) {
51
+ token.loc = {
52
+ start: firstToken.loc.start,
53
+ end: lastTemplateToken.loc.end
54
+ };
55
+ }
56
+
57
+ if (firstToken.range) {
58
+ token.start = firstToken.range[0];
59
+ token.end = lastTemplateToken.range[1];
60
+ token.range = [token.start, token.end];
61
+ }
62
+
63
+ return token;
64
+ }
65
+
66
+ /**
67
+ * Contains logic to translate Acorn tokens into Esprima tokens.
68
+ * @param {Object} acornTokTypes The Acorn token types.
69
+ * @param {string} code The source code Acorn is parsing. This is necessary
70
+ * to correct the "value" property of some tokens.
71
+ * @constructor
72
+ */
73
+ function TokenTranslator(acornTokTypes, code) {
74
+
75
+ // token types
76
+ this._acornTokTypes = acornTokTypes;
77
+
78
+ // token buffer for templates
79
+ this._tokens = [];
80
+
81
+ // track the last curly brace
82
+ this._curlyBrace = null;
83
+
84
+ // the source code
85
+ this._code = code;
86
+
87
+ }
88
+
89
+ TokenTranslator.prototype = {
90
+ constructor: TokenTranslator,
91
+
92
+ /**
93
+ * Translates a single Esprima token to a single Acorn token. This may be
94
+ * inaccurate due to how templates are handled differently in Esprima and
95
+ * Acorn, but should be accurate for all other tokens.
96
+ * @param {AcornToken} token The Acorn token to translate.
97
+ * @param {Object} extra Espree extra object.
98
+ * @returns {EsprimaToken} The Esprima version of the token.
99
+ */
100
+ translate(token, extra) {
101
+
102
+ const type = token.type,
103
+ tt = this._acornTokTypes;
104
+
105
+ if (type === tt.name) {
106
+ token.type = Token.Identifier;
107
+
108
+ // TODO: See if this is an Acorn bug
109
+ if (token.value === "static") {
110
+ token.type = Token.Keyword;
111
+ }
112
+
113
+ if (extra.ecmaVersion > 5 && (token.value === "yield" || token.value === "let")) {
114
+ token.type = Token.Keyword;
115
+ }
116
+
117
+ } else if (type === tt.privateId) {
118
+ token.type = Token.PrivateIdentifier;
119
+
120
+ } else if (type === tt.semi || type === tt.comma ||
121
+ type === tt.parenL || type === tt.parenR ||
122
+ type === tt.braceL || type === tt.braceR ||
123
+ type === tt.dot || type === tt.bracketL ||
124
+ type === tt.colon || type === tt.question ||
125
+ type === tt.bracketR || type === tt.ellipsis ||
126
+ type === tt.arrow || type === tt.jsxTagStart ||
127
+ type === tt.incDec || type === tt.starstar ||
128
+ type === tt.jsxTagEnd || type === tt.prefix ||
129
+ type === tt.questionDot ||
130
+ (type.binop && !type.keyword) ||
131
+ type.isAssign) {
132
+
133
+ token.type = Token.Punctuator;
134
+ token.value = this._code.slice(token.start, token.end);
135
+ } else if (type === tt.jsxName) {
136
+ token.type = Token.JSXIdentifier;
137
+ } else if (type.label === "jsxText" || type === tt.jsxAttrValueToken) {
138
+ token.type = Token.JSXText;
139
+ } else if (type.keyword) {
140
+ if (type.keyword === "true" || type.keyword === "false") {
141
+ token.type = Token.Boolean;
142
+ } else if (type.keyword === "null") {
143
+ token.type = Token.Null;
144
+ } else {
145
+ token.type = Token.Keyword;
146
+ }
147
+ } else if (type === tt.num) {
148
+ token.type = Token.Numeric;
149
+ token.value = this._code.slice(token.start, token.end);
150
+ } else if (type === tt.string) {
151
+
152
+ if (extra.jsxAttrValueToken) {
153
+ extra.jsxAttrValueToken = false;
154
+ token.type = Token.JSXText;
155
+ } else {
156
+ token.type = Token.String;
157
+ }
158
+
159
+ token.value = this._code.slice(token.start, token.end);
160
+ } else if (type === tt.regexp) {
161
+ token.type = Token.RegularExpression;
162
+ const value = token.value;
163
+
164
+ token.regex = {
165
+ flags: value.flags,
166
+ pattern: value.pattern
167
+ };
168
+ token.value = `/${value.pattern}/${value.flags}`;
169
+ }
170
+
171
+ return token;
172
+ },
173
+
174
+ /**
175
+ * Function to call during Acorn's onToken handler.
176
+ * @param {AcornToken} token The Acorn token.
177
+ * @param {Object} extra The Espree extra object.
178
+ * @returns {void}
179
+ */
180
+ onToken(token, extra) {
181
+
182
+ const tt = this._acornTokTypes,
183
+ tokens = extra.tokens,
184
+ templateTokens = this._tokens;
185
+
186
+ /**
187
+ * Flushes the buffered template tokens and resets the template
188
+ * tracking.
189
+ * @returns {void}
190
+ * @private
191
+ */
192
+ const translateTemplateTokens = () => {
193
+ tokens.push(convertTemplatePart(this._tokens, this._code));
194
+ this._tokens = [];
195
+ };
196
+
197
+ if (token.type === tt.eof) {
198
+
199
+ // might be one last curlyBrace
200
+ if (this._curlyBrace) {
201
+ tokens.push(this.translate(this._curlyBrace, extra));
202
+ }
203
+
204
+ return;
205
+ }
206
+
207
+ if (token.type === tt.backQuote) {
208
+
209
+ // if there's already a curly, it's not part of the template
210
+ if (this._curlyBrace) {
211
+ tokens.push(this.translate(this._curlyBrace, extra));
212
+ this._curlyBrace = null;
213
+ }
214
+
215
+ templateTokens.push(token);
216
+
217
+ // it's the end
218
+ if (templateTokens.length > 1) {
219
+ translateTemplateTokens();
220
+ }
221
+
222
+ return;
223
+ }
224
+ if (token.type === tt.dollarBraceL) {
225
+ templateTokens.push(token);
226
+ translateTemplateTokens();
227
+ return;
228
+ }
229
+ if (token.type === tt.braceR) {
230
+
231
+ // if there's already a curly, it's not part of the template
232
+ if (this._curlyBrace) {
233
+ tokens.push(this.translate(this._curlyBrace, extra));
234
+ }
235
+
236
+ // store new curly for later
237
+ this._curlyBrace = token;
238
+ return;
239
+ }
240
+ if (token.type === tt.template || token.type === tt.invalidTemplate) {
241
+ if (this._curlyBrace) {
242
+ templateTokens.push(this._curlyBrace);
243
+ this._curlyBrace = null;
244
+ }
245
+
246
+ templateTokens.push(token);
247
+ return;
248
+ }
249
+
250
+ if (this._curlyBrace) {
251
+ tokens.push(this.translate(this._curlyBrace, extra));
252
+ this._curlyBrace = null;
253
+ }
254
+
255
+ tokens.push(this.translate(token, extra));
256
+ }
257
+ };
258
+
259
+ //------------------------------------------------------------------------------
260
+ // Public
261
+ //------------------------------------------------------------------------------
262
+
263
+ export default TokenTranslator;
@@ -0,0 +1,3 @@
1
+ const version = "10.0.1";
2
+
3
+ export default version;