@mgdis/core-ui-helpers 1.2.2 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (149) hide show
  1. package/dist/angular/index.cjs +27 -0
  2. package/dist/angular/index.cjs.map +1 -0
  3. package/dist/angular/index.d.ts +21 -0
  4. package/dist/angular/index.js +25 -0
  5. package/dist/angular/index.js.map +1 -0
  6. package/dist/angular/index.umd.js +33 -0
  7. package/dist/angular/index.umd.js.map +1 -0
  8. package/dist/locale/index.cjs +190 -0
  9. package/dist/locale/index.cjs.map +1 -0
  10. package/dist/locale/index.d.ts +110 -0
  11. package/dist/locale/index.js +181 -0
  12. package/dist/locale/index.js.map +1 -0
  13. package/dist/locale/index.umd.js +196 -0
  14. package/dist/locale/index.umd.js.map +1 -0
  15. package/dist/playwright/index.cjs +137 -0
  16. package/dist/playwright/index.cjs.map +1 -0
  17. package/dist/playwright/index.d.ts +39 -0
  18. package/dist/playwright/index.js +133 -0
  19. package/dist/playwright/index.js.map +1 -0
  20. package/dist/playwright/index.umd.js +143 -0
  21. package/dist/playwright/index.umd.js.map +1 -0
  22. package/dist/stencil/index.cjs +363 -0
  23. package/dist/stencil/index.cjs.map +1 -0
  24. package/dist/stencil/index.d.ts +222 -0
  25. package/dist/stencil/index.js +357 -0
  26. package/dist/stencil/index.js.map +1 -0
  27. package/dist/stencil/index.umd.js +369 -0
  28. package/dist/stencil/index.umd.js.map +1 -0
  29. package/dist/storybook/index.cjs +2335 -0
  30. package/dist/storybook/index.cjs.map +1 -0
  31. package/dist/storybook/index.d.ts +85 -0
  32. package/dist/storybook/index.js +2329 -0
  33. package/dist/storybook/index.js.map +1 -0
  34. package/dist/storybook/index.umd.js +2341 -0
  35. package/dist/storybook/index.umd.js.map +1 -0
  36. package/dist/tests/index.cjs +315 -0
  37. package/dist/tests/index.cjs.map +1 -0
  38. package/dist/tests/index.d.ts +100 -0
  39. package/dist/tests/index.js +309 -0
  40. package/dist/tests/index.js.map +1 -0
  41. package/dist/tests/index.umd.js +321 -0
  42. package/dist/tests/index.umd.js.map +1 -0
  43. package/dist/utils/index.cjs +441 -0
  44. package/dist/utils/index.cjs.map +1 -0
  45. package/dist/utils/index.d.ts +265 -0
  46. package/dist/utils/index.js +417 -0
  47. package/dist/utils/index.js.map +1 -0
  48. package/dist/utils/index.umd.js +447 -0
  49. package/dist/utils/index.umd.js.map +1 -0
  50. package/dist/vue/index.cjs +1935 -0
  51. package/dist/vue/index.cjs.map +1 -0
  52. package/dist/vue/index.d.ts +35 -0
  53. package/dist/vue/index.js +1933 -0
  54. package/dist/vue/index.js.map +1 -0
  55. package/dist/vue/index.umd.js +1941 -0
  56. package/dist/vue/index.umd.js.map +1 -0
  57. package/package.json +4 -1
  58. package/CHANGELOG.md +0 -101
  59. package/json-doc.test.json +0 -264
  60. package/rollup.config.mjs +0 -61
  61. package/src/angular/index.spec.ts +0 -8
  62. package/src/angular/index.ts +0 -1
  63. package/src/angular/mg-angular-logger/index.ts +0 -1
  64. package/src/angular/mg-angular-logger/mg-angular-logger.conf.ts +0 -3
  65. package/src/angular/mg-angular-logger/mg-angular-logger.spec.ts +0 -40
  66. package/src/angular/mg-angular-logger/mg-angular-logger.ts +0 -24
  67. package/src/locale/index.spec.ts +0 -24
  68. package/src/locale/index.ts +0 -1
  69. package/src/locale/locale.spec.ts +0 -291
  70. package/src/locale/locale.ts +0 -201
  71. package/src/playwright/config/index.ts +0 -43
  72. package/src/playwright/index.spec.ts +0 -16
  73. package/src/playwright/index.ts +0 -4
  74. package/src/playwright/utils/__snapshots__/utils.spec.ts.snap +0 -48
  75. package/src/playwright/utils/index.ts +0 -1
  76. package/src/playwright/utils/utils.spec.ts +0 -50
  77. package/src/playwright/utils/utils.ts +0 -77
  78. package/src/stencil/ide/__snapshots__/cem.spec.ts.snap +0 -248
  79. package/src/stencil/ide/__snapshots__/ide.spec.ts.snap +0 -414
  80. package/src/stencil/ide/cem.spec.ts +0 -35
  81. package/src/stencil/ide/cem.ts +0 -96
  82. package/src/stencil/ide/ide.spec.ts +0 -29
  83. package/src/stencil/ide/ide.ts +0 -221
  84. package/src/stencil/ide/index.ts +0 -2
  85. package/src/stencil/index.spec.ts +0 -16
  86. package/src/stencil/index.ts +0 -2
  87. package/src/stencil/normalize-boolean-attributes/index.ts +0 -1
  88. package/src/stencil/normalize-boolean-attributes/normalize-boolean-attributes.spec.ts +0 -63
  89. package/src/stencil/normalize-boolean-attributes/normalize-boolean-attributes.ts +0 -40
  90. package/src/storybook/index.spec.ts +0 -19
  91. package/src/storybook/index.ts +0 -1
  92. package/src/storybook/stencil/__snapshots__/stencil.spec.ts.snap +0 -329
  93. package/src/storybook/stencil/index.ts +0 -1
  94. package/src/storybook/stencil/stencil-shim.d.ts +0 -1
  95. package/src/storybook/stencil/stencil.conf.ts +0 -4
  96. package/src/storybook/stencil/stencil.spec.ts +0 -170
  97. package/src/storybook/stencil/stencil.ts +0 -377
  98. package/src/tests/index.spec.ts +0 -20
  99. package/src/tests/index.ts +0 -1
  100. package/src/tests/unit/__snapshots__/unit.spec.ts.snap +0 -52
  101. package/src/tests/unit/index.ts +0 -1
  102. package/src/tests/unit/unit.conf.ts +0 -16
  103. package/src/tests/unit/unit.spec.ts +0 -206
  104. package/src/tests/unit/unit.ts +0 -333
  105. package/src/utils/attributes/class-list/class-list.spec.ts +0 -36
  106. package/src/utils/attributes/class-list/class-list.ts +0 -51
  107. package/src/utils/attributes/class-list/index.ts +0 -1
  108. package/src/utils/attributes/id/id.spec.ts +0 -54
  109. package/src/utils/attributes/id/id.ts +0 -47
  110. package/src/utils/attributes/id/index.ts +0 -1
  111. package/src/utils/attributes/index.ts +0 -3
  112. package/src/utils/attributes/to-kebab-case/index.ts +0 -1
  113. package/src/utils/attributes/to-kebab-case/to-kebab-case.spec.ts +0 -29
  114. package/src/utils/attributes/to-kebab-case/to-kebab-case.ts +0 -23
  115. package/src/utils/components/__snapshots__/components.spec.ts.snap +0 -313
  116. package/src/utils/components/components.conf.ts +0 -11
  117. package/src/utils/components/components.spec.ts +0 -192
  118. package/src/utils/components/components.ts +0 -152
  119. package/src/utils/components/index.ts +0 -2
  120. package/src/utils/date/date.spec.ts +0 -12
  121. package/src/utils/date/date.ts +0 -20
  122. package/src/utils/date/index.ts +0 -1
  123. package/src/utils/elements/elements.spec.ts +0 -17
  124. package/src/utils/elements/elements.ts +0 -18
  125. package/src/utils/elements/index.ts +0 -1
  126. package/src/utils/index.spec.ts +0 -84
  127. package/src/utils/index.ts +0 -8
  128. package/src/utils/number/index.ts +0 -1
  129. package/src/utils/number/number.spec.ts +0 -14
  130. package/src/utils/number/number.ts +0 -6
  131. package/src/utils/object/index.ts +0 -2
  132. package/src/utils/object/object.conf.ts +0 -4
  133. package/src/utils/object/object.spec.ts +0 -110
  134. package/src/utils/object/object.ts +0 -27
  135. package/src/utils/string/index.ts +0 -1
  136. package/src/utils/string/string.spec.ts +0 -54
  137. package/src/utils/string/string.ts +0 -39
  138. package/src/utils/windows/index.ts +0 -1
  139. package/src/utils/windows/windows.spec.ts +0 -69
  140. package/src/utils/windows/windows.ts +0 -50
  141. package/src/vue/index.spec.ts +0 -8
  142. package/src/vue/index.ts +0 -1
  143. package/src/vue/mg-model/index.ts +0 -1
  144. package/src/vue/mg-model/mg-model.conf.ts +0 -6
  145. package/src/vue/mg-model/mg-model.spec.ts +0 -50
  146. package/src/vue/mg-model/mg-model.ts +0 -55
  147. package/tsconfig.json +0 -17
  148. package/typedoc.json +0 -14
  149. package/vitest.config.mts +0 -13
@@ -0,0 +1,369 @@
1
+ (function (global, factory) {
2
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
3
+ typeof define === 'function' && define.amd ? define(['exports'], factory) :
4
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.CoreUiHelpers = global.CoreUiHelpers || {}, global.CoreUiHelpers.stencil = {})));
5
+ })(this, (function (exports) { 'use strict';
6
+
7
+ /**
8
+ * Retrieve Component Storybook URL from file path
9
+ * @param storybookBaseUrl - Storybook Base URL
10
+ * @param filePath - Component file path
11
+ * @returns Component Storybook URL
12
+ */
13
+ const getStorybookUrl = (storybookBaseUrl, filePath) => {
14
+ if (!filePath) {
15
+ return;
16
+ }
17
+ const split = filePath.split('/');
18
+ return `${storybookBaseUrl}${split.slice(2, split.length - 1).join('-')}--docs`;
19
+ };
20
+
21
+ /**
22
+ * Retrieve Component source URL from file path
23
+ * @param sourcesBaseUrl - Source base URL
24
+ * @param filePath - Component file path
25
+ * @returns Component source URL
26
+ */
27
+ const getSourcesUrl = (sourcesBaseUrl, filePath) => {
28
+ if (!filePath) {
29
+ return;
30
+ }
31
+ return `${sourcesBaseUrl}${filePath}`;
32
+ };
33
+ /**
34
+ * Get Component element description.
35
+ *
36
+ * Neither WebStorm nor VS Code render the structured `attributes` /
37
+ * `js.properties` arrays in the tag-level quick-doc — they only show this
38
+ * markdown description. So the attribute and property listings have to live
39
+ * here, even though they're redundant with the structured arrays used by the
40
+ * inline autocomplete.
41
+ * @param component - Component
42
+ * @returns Component element description
43
+ */
44
+ const getElementDescription = (component) => {
45
+ let description = component.overview ? `${component.overview}\n\n` : '';
46
+ const attributes = component.props.filter(({ attr }) => attr !== undefined);
47
+ if (attributes.length) {
48
+ description += `Attributes:\n`;
49
+ description += attributes.map(({ attr, docs }) => `- \`${attr}\`: ${docs}\n`).join('');
50
+ description += '\n';
51
+ }
52
+ const properties = component.props.filter(({ attr }) => attr === undefined);
53
+ if (properties.length) {
54
+ description += `Properties:\n`;
55
+ description += properties.map(({ name, docs }) => `- \`${name}\`: ${docs}\n`).join('');
56
+ description += '\n';
57
+ }
58
+ if (component.methods.length) {
59
+ description += `Methods:\n`;
60
+ description += component.methods.map(({ name, docs }) => `- \`${name}\`: ${docs}\n`).join('');
61
+ description += '\n';
62
+ }
63
+ if (component.events.length) {
64
+ description += `Events:\n`;
65
+ description += component.events.map(({ event, docs }) => `- \`${event}\`: ${docs}\n`).join('');
66
+ description += '\n';
67
+ }
68
+ if (component.listeners.length) {
69
+ description += `Listeners:\n`;
70
+ description += component.listeners.map(({ event }) => `- \`${event}\`\n`).join('');
71
+ description += '\n';
72
+ }
73
+ if (component.slots.length) {
74
+ description += `Slots:\n`;
75
+ description += component.slots
76
+ .map(({ name, docs }) => {
77
+ const label = name ? `\`${name}\`` : 'default';
78
+ return `- ${label}: ${docs}\n`;
79
+ })
80
+ .join('');
81
+ description += '\n';
82
+ }
83
+ return description;
84
+ };
85
+ /**
86
+ * Get Props Description
87
+ * @param prop - Component Property
88
+ * @returns Props Description
89
+ */
90
+ const getAttributeDescription = (prop) => {
91
+ return `${prop.docs}\n\nType: \`${prop.type}\``;
92
+ };
93
+ /**
94
+ * Generate Web Types metadata for IntelliJ's IDE
95
+ * @param name - Library name
96
+ * @param version - Library version
97
+ * @param jsonDocs - Stencil JSON doc
98
+ * @param storybookBaseUrl - Storybook Base Url
99
+ * @returns Web Types metadata
100
+ * @example
101
+ * ```ts
102
+ * const webTypesJson = webTypesGenerator('@mgdis/mg-components', '1.0.0', jsonDocs, 'https://storybook.example.com');
103
+ * ```
104
+ */
105
+ const webTypesGenerator = (name, version, jsonDocs, storybookBaseUrl) => ({
106
+ $schema: 'https://json.schemastore.org/web-types',
107
+ name,
108
+ version,
109
+ 'description-markup': 'markdown',
110
+ contributions: {
111
+ html: {
112
+ elements: jsonDocs.components.map((component) => {
113
+ const docUrl = getStorybookUrl(storybookBaseUrl, component.filePath);
114
+ return {
115
+ name: component.tag,
116
+ description: getElementDescription(component),
117
+ 'doc-url': docUrl,
118
+ attributes: component.props
119
+ .filter((prop) => prop.attr)
120
+ .map((prop) => ({
121
+ name: prop.attr,
122
+ description: getAttributeDescription(prop),
123
+ 'doc-url': docUrl,
124
+ value: {
125
+ type: prop.type,
126
+ default: prop.default,
127
+ required: prop.required,
128
+ },
129
+ })),
130
+ js: {
131
+ properties: component.props
132
+ .filter((prop) => prop.attr === undefined)
133
+ .map((prop) => ({
134
+ name: prop.name,
135
+ description: getAttributeDescription(prop),
136
+ 'doc-url': docUrl,
137
+ value: {
138
+ type: prop.type,
139
+ default: prop.default,
140
+ required: prop.required,
141
+ },
142
+ })),
143
+ events: component.events.map((event) => ({
144
+ name: event.event,
145
+ description: event.docs,
146
+ })),
147
+ },
148
+ css: {
149
+ properties: component.styles.map((style) => ({
150
+ name: style.name,
151
+ description: style.docs,
152
+ })),
153
+ },
154
+ };
155
+ }),
156
+ },
157
+ },
158
+ });
159
+ /**
160
+ * Create Storybook Reference
161
+ * @param storybookBaseUrl - Storybook Base Url
162
+ * @param filePath - Component file path
163
+ * @returns Storybook Reference
164
+ */
165
+ const getReferences = (storybookBaseUrl, sourceBaseUrl, filePath) => {
166
+ return [
167
+ { name: 'Storybook', url: getStorybookUrl(storybookBaseUrl, filePath) },
168
+ { name: 'Sources', url: getSourcesUrl(sourceBaseUrl, filePath) },
169
+ ];
170
+ };
171
+ /**
172
+ * Get Property possible values
173
+ * @param prop - Component Property
174
+ * @returns Property possible values
175
+ */
176
+ const getValues = (prop) => {
177
+ // Only values Array where all objects have a value seems to be usefull
178
+ if (prop.values.some(({ value }) => value === undefined)) {
179
+ return;
180
+ }
181
+ return prop.values.map(({ value }) => ({ name: value }));
182
+ };
183
+ /**
184
+ * Generate custom HTML datasets for VS Code
185
+ * @param jsonDocs - Stencil JSON doc
186
+ * @param storybookBaseUrl - Storybook Base Url
187
+ * @returns custom HTML datasets
188
+ * @example
189
+ * ```ts
190
+ * const customDataJson = vsCodeGenerator(jsonDocs, 'https://storybook.example.com', 'https://sources.example.com');
191
+ * ```
192
+ */
193
+ const vsCodeGenerator = (jsonDocs, storybookBaseUrl, sourceBaseUrl) => ({
194
+ version: 1.1,
195
+ tags: jsonDocs.components.map((component) => {
196
+ const references = getReferences(storybookBaseUrl, sourceBaseUrl, component.filePath);
197
+ return {
198
+ name: component.tag,
199
+ description: getElementDescription(component),
200
+ attributes: component.props
201
+ .filter((prop) => prop.attr !== undefined)
202
+ .map((prop) => ({
203
+ name: prop.attr,
204
+ description: getAttributeDescription(prop),
205
+ values: getValues(prop),
206
+ references,
207
+ })),
208
+ references,
209
+ };
210
+ }),
211
+ globalAttributes: [],
212
+ valueSets: [],
213
+ });
214
+ /**
215
+ * Generate custom CSS datasets for VS Code
216
+ * @param jsonDocs - Stencil JSON doc
217
+ * @returns custom CSS datasets
218
+ * @example
219
+ * ```ts
220
+ * const customDataJson = vsCodeCssGenerator(jsonDocs);
221
+ * ```
222
+ */
223
+ const vsCodeCssGenerator = (jsonDocs) => ({
224
+ version: 1.1,
225
+ properties: jsonDocs.components.flatMap((component) => component.styles.map((style) => ({
226
+ name: style.name,
227
+ description: style.docs,
228
+ }))),
229
+ });
230
+
231
+ /**
232
+ * Convert a Stencil component's JsonDocs into a CEM v2 module entry.
233
+ * @param component - Stencil component doc
234
+ * @returns CEM module
235
+ */
236
+ const componentToModule = (component) => {
237
+ const className = component.tag
238
+ .split('-')
239
+ .map((part) => part.charAt(0).toUpperCase() + part.slice(1))
240
+ .join('');
241
+ const attributes = component.props
242
+ .filter((prop) => prop.attr !== undefined)
243
+ .map((prop) => ({
244
+ name: prop.attr,
245
+ description: prop.docs,
246
+ type: { text: prop.type },
247
+ ...(prop.default !== undefined && { default: prop.default }),
248
+ fieldName: prop.name,
249
+ }));
250
+ const fieldMembers = component.props.map((prop) => ({
251
+ kind: 'field',
252
+ name: prop.name,
253
+ description: prop.docs,
254
+ type: { text: prop.type },
255
+ ...(prop.default !== undefined && { default: prop.default }),
256
+ ...(prop.attr !== undefined && { attribute: prop.attr }),
257
+ }));
258
+ const methodMembers = component.methods.map((method) => ({
259
+ kind: 'method',
260
+ name: method.name,
261
+ description: method.docs,
262
+ }));
263
+ return {
264
+ kind: 'javascript-module',
265
+ path: component.filePath ?? '',
266
+ declarations: [
267
+ {
268
+ kind: 'class',
269
+ name: className,
270
+ tagName: component.tag,
271
+ customElement: true,
272
+ description: component.overview ?? '',
273
+ attributes,
274
+ members: [...fieldMembers, ...methodMembers],
275
+ events: component.events.map((event) => ({
276
+ name: event.event,
277
+ description: event.docs,
278
+ type: { text: `CustomEvent<${event.detail}>` },
279
+ })),
280
+ slots: component.slots.map((slot) => ({
281
+ name: slot.name,
282
+ description: slot.docs,
283
+ })),
284
+ cssProperties: component.styles.map((style) => ({
285
+ name: style.name,
286
+ description: style.docs,
287
+ })),
288
+ cssParts: component.parts.map((part) => ({
289
+ name: part.name,
290
+ description: part.docs,
291
+ })),
292
+ },
293
+ ],
294
+ exports: [
295
+ {
296
+ kind: 'custom-element-definition',
297
+ name: component.tag,
298
+ declaration: {
299
+ name: className,
300
+ module: component.filePath ?? '',
301
+ },
302
+ },
303
+ ],
304
+ };
305
+ };
306
+ /**
307
+ * Generate a Custom Elements Manifest v2 from Stencil JSON docs.
308
+ * @param jsonDocs - Stencil JSON doc
309
+ * @returns CEM v2
310
+ * @example
311
+ * ```ts
312
+ * const cem = cemGenerator(jsonDocs);
313
+ * ```
314
+ */
315
+ const cemGenerator = (jsonDocs) => ({
316
+ schemaVersion: '2.0.0',
317
+ readme: '',
318
+ modules: jsonDocs.components.map(componentToModule),
319
+ });
320
+
321
+ /**
322
+ * Per the HTML spec, a boolean attribute is `true` whenever it is present on the
323
+ * element, regardless of its value (including `="false"`). Stencil's default Prop
324
+ * parser converts the string `"false"` to the boolean `false`, which breaks this
325
+ * contract for consumers writing markup. Call this helper from `componentWillLoad`
326
+ * to re-normalize every present attribute that maps to a boolean-typed Prop.
327
+ *
328
+ * Iterates the host element's attributes and, for each one whose camelCase name
329
+ * matches a `typeof === 'boolean'` Prop on the instance, rewrites the attribute
330
+ * to `''` — Stencil's parser then turns that into `true` via the standard
331
+ * attribute → prop pipeline (no need for `mutable: true` on the Prop, since the
332
+ * write goes through Stencil's internal setter, not through user code).
333
+ *
334
+ * Non-boolean Props and non-Prop attributes (`class`, `id`, ...) are skipped
335
+ * naturally by the type check.
336
+ *
337
+ * @param target - the component instance (must expose `element` via `@Element()`)
338
+ *
339
+ * @example
340
+ * ```typescript
341
+ * @Component({ tag: 'my-input' })
342
+ * export class MyInput {
343
+ * @Element() element: HTMLMyInputElement;
344
+ * @Prop() readonly = false;
345
+ * @Prop() disabled = false;
346
+ *
347
+ * componentWillLoad() {
348
+ * normalizeBooleanAttributes(this);
349
+ * }
350
+ * }
351
+ * ```
352
+ */
353
+ const normalizeBooleanAttributes = (target) => {
354
+ for (const attr of Array.from(target.element.attributes)) {
355
+ const propName = attr.name.replace(/-([a-z])/g, (_, c) => c.toUpperCase());
356
+ if (typeof target[propName] === 'boolean') {
357
+ target.element.setAttribute(attr.name, '');
358
+ }
359
+ }
360
+ };
361
+
362
+ exports.cemGenerator = cemGenerator;
363
+ exports.normalizeBooleanAttributes = normalizeBooleanAttributes;
364
+ exports.vsCodeCssGenerator = vsCodeCssGenerator;
365
+ exports.vsCodeGenerator = vsCodeGenerator;
366
+ exports.webTypesGenerator = webTypesGenerator;
367
+
368
+ }));
369
+ //# sourceMappingURL=index.umd.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.umd.js","sources":["../../src/storybook/stencil/stencil.ts","../../src/stencil/ide/ide.ts","../../src/stencil/ide/cem.ts","../../src/stencil/normalize-boolean-attributes/normalize-boolean-attributes.ts"],"sourcesContent":[null,null,null,null],"names":[],"mappings":";;;;;;IA6JA;;;;;IAKG;IACI,MAAM,eAAe,GAAG,CAAC,gBAAwB,EAAE,QAA4B,KAAwB;QAC5G,IAAI,CAAC,QAAQ,EAAE;YACb;QACF;QACA,MAAM,KAAK,GAAG,QAAQ,CAAC,KAAK,CAAC,GAAG,CAAC;QACjC,OAAO,CAAA,EAAG,gBAAgB,CAAA,EAAG,KAAK,CAAC,KAAK,CAAC,CAAC,EAAE,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAA,MAAA,CAAQ;IACjF,CAAC;;ICtKD;;;;;IAKG;IACH,MAAM,aAAa,GAAG,CAAC,cAAsB,EAAE,QAA4B,KAAwB;QACjG,IAAI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