@projectwallace/css-analyzer 7.3.0 → 7.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -44,7 +44,21 @@ export function analyze(css: string, options?: Options): {
44
44
  };
45
45
  };
46
46
  };
47
- atrules: {
47
+ atrules: ({
48
+ total: number;
49
+ totalUnique: number;
50
+ uniquenessRatio: number;
51
+ unique: Record<string, number>;
52
+ } & ({
53
+ uniqueWithLocations: Record<string, {
54
+ line: number;
55
+ column: number;
56
+ offset: number;
57
+ length: number;
58
+ }[]>;
59
+ } | {
60
+ uniqueWithLocations?: undefined;
61
+ })) & {
48
62
  fontface: {
49
63
  total: number;
50
64
  totalUnique: number;
@@ -261,7 +275,6 @@ export function analyze(css: string, options?: Options): {
261
275
  } | {
262
276
  uniqueWithLocations?: undefined;
263
277
  });
264
- total: number;
265
278
  complexity: {
266
279
  min: number | undefined;
267
280
  max: number | undefined;
@@ -277,9 +290,23 @@ export function analyze(css: string, options?: Options): {
277
290
  mode: number;
278
291
  range: number;
279
292
  sum: number;
280
- } & {
293
+ } & ({
281
294
  items: number[];
282
- };
295
+ } & ({
296
+ total: number;
297
+ totalUnique: number;
298
+ uniquenessRatio: number;
299
+ unique: Record<string, number>;
300
+ } & ({
301
+ uniqueWithLocations: Record<string, {
302
+ line: number;
303
+ column: number;
304
+ offset: number;
305
+ length: number;
306
+ }[]>;
307
+ } | {
308
+ uniqueWithLocations?: undefined;
309
+ })));
283
310
  };
284
311
  rules: {
285
312
  total: number;
@@ -318,9 +345,23 @@ export function analyze(css: string, options?: Options): {
318
345
  mode: number;
319
346
  range: number;
320
347
  sum: number;
321
- } & {
348
+ } & ({
322
349
  items: number[];
323
- };
350
+ } & ({
351
+ total: number;
352
+ totalUnique: number;
353
+ uniquenessRatio: number;
354
+ unique: Record<string, number>;
355
+ } & ({
356
+ uniqueWithLocations: Record<string, {
357
+ line: number;
358
+ column: number;
359
+ offset: number;
360
+ length: number;
361
+ }[]>;
362
+ } | {
363
+ uniqueWithLocations?: undefined;
364
+ })));
324
365
  selectors: {
325
366
  min: number | undefined;
326
367
  max: number | undefined;
@@ -433,9 +474,23 @@ export function analyze(css: string, options?: Options): {
433
474
  mode: number;
434
475
  range: number;
435
476
  sum: number;
436
- } & {
477
+ } & ({
437
478
  items: number[];
438
- };
479
+ } & ({
480
+ total: number;
481
+ totalUnique: number;
482
+ uniquenessRatio: number;
483
+ unique: Record<string, number>;
484
+ } & ({
485
+ uniqueWithLocations: Record<string, {
486
+ line: number;
487
+ column: number;
488
+ offset: number;
489
+ length: number;
490
+ }[]>;
491
+ } | {
492
+ uniqueWithLocations?: undefined;
493
+ })));
439
494
  id: ({
440
495
  total: number;
441
496
  totalUnique: number;
@@ -560,9 +615,23 @@ export function analyze(css: string, options?: Options): {
560
615
  mode: number;
561
616
  range: number;
562
617
  sum: number;
563
- } & {
618
+ } & ({
564
619
  items: number[];
565
- };
620
+ } & ({
621
+ total: number;
622
+ totalUnique: number;
623
+ uniquenessRatio: number;
624
+ unique: Record<string, number>;
625
+ } & ({
626
+ uniqueWithLocations: Record<string, {
627
+ line: number;
628
+ column: number;
629
+ offset: number;
630
+ length: number;
631
+ }[]>;
632
+ } | {
633
+ uniqueWithLocations?: undefined;
634
+ })));
566
635
  };
567
636
  properties: ({
568
637
  total: number;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@projectwallace/css-analyzer",
3
3
  "description": "The best CSS analyzer out there. Check design tokens, complexity, specificity, performance and more.",
4
- "version": "7.3.0",
4
+ "version": "7.5.0",
5
5
  "author": "Bart Veneman",
6
6
  "repository": {
7
7
  "type": "git",