buzzcasting-utils 1.8.8 → 1.9.1

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.
@@ -87,21 +87,16 @@ export declare interface Content {
87
87
  attr: MessagesAttr;
88
88
  }
89
89
 
90
- export declare interface Countries {
91
- type: string;
92
- geometries: CountriesGeometry[];
93
- }
94
-
95
90
  export declare interface CountriesGeometry {
96
- type: Type;
91
+ type: GeoType;
97
92
  arcs: Array<Array<number[] | number>>;
98
93
  id?: string;
99
94
  properties: CountryProperties;
100
95
  }
101
96
 
102
97
  export declare interface CountryObjects {
103
- countries: Countries;
104
- land: Land;
98
+ countries: GeoCountries;
99
+ land: GeoLand;
105
100
  }
106
101
 
107
102
  export declare interface CountryProperties {
@@ -128,11 +123,20 @@ declare enum CSS_2 {
128
123
  SLIDE = "color:black;background-color:yellow;padding:0 4px 0 4px;border-radius:5px;",
129
124
  STORAGE = "color:black;background-color:cyan;padding:0 4px 0 4px;border-radius:5px;",
130
125
  SUBSCRIBE = "color:white;background-color:dodgerblue;padding:0 4px 0 4px;border-radius:5px;",
131
- WIDGET = "color:gret;background-color:lemonchiffon;padding:0 4px 0 4px;border-radius:5px;",
126
+ WIDGET = "color:black;background-color:lemonchiffon;padding:0 4px 0 4px;border-radius:5px;",
132
127
  WS = "color:white;background-color:green;padding:0 4px 0 4px;border-radius:5px;"
133
128
  }
134
129
  export { CSS_2 as CSS }
135
130
 
131
+ /**
132
+ * Cloud
133
+ */
134
+ export declare interface Data {
135
+ dashboard: string;
136
+ type: string;
137
+ widget: string;
138
+ }
139
+
136
140
  export declare function deepMerge(objs: any): void;
137
141
 
138
142
  declare const escape_2: (htmlStr: string) => string;
@@ -218,8 +222,25 @@ export declare enum EVENTS {
218
222
 
219
223
  export declare function filterAttributes(attributes: NamedNodeMap): IFilteredAttributes;
220
224
 
225
+ export declare const flatten: (obj: any, res?: {}, parentKey?: string) => {};
226
+
221
227
  export declare function formatContent(message: IMessage, titleCss?: string): string;
222
228
 
229
+ export declare interface GeoCountries {
230
+ type: string;
231
+ geometries: CountriesGeometry[];
232
+ }
233
+
234
+ export declare interface GeoLand {
235
+ type: string;
236
+ geometries: LandGeometry[];
237
+ }
238
+
239
+ export declare enum GeoType {
240
+ MultiPolygon = "MultiPolygon",
241
+ Polygon = "Polygon"
242
+ }
243
+
223
244
  export declare const getGuid: () => string;
224
245
 
225
246
  export declare function getKey(query: IQuery): string;
@@ -243,7 +264,7 @@ export declare const HTMLtoDOM: (html: string, doc: any) => any;
243
264
 
244
265
  export declare const HTMLtoXML: (html: string) => string;
245
266
 
246
- export declare interface IAnimation {
267
+ declare interface IAnimation {
247
268
  items?: number;
248
269
  interval: number;
249
270
  animation: number;
@@ -285,11 +306,23 @@ export declare interface IBorders {
285
306
  lineWidth: number;
286
307
  }
287
308
 
309
+ /**
310
+ * Card
311
+ */
288
312
  export declare interface IBrand {
289
313
  show?: boolean;
290
314
  size?: string;
291
315
  }
292
316
 
317
+ declare interface IBubbles {
318
+ label: string;
319
+ size: string;
320
+ classlist: string;
321
+ force: number;
322
+ color: string;
323
+ multiplier: number;
324
+ }
325
+
293
326
  export declare interface ICardAttributes {
294
327
  layout?: "" | "none" | "base" | "globe" | "carousel";
295
328
  component: string;
@@ -341,12 +374,13 @@ export declare interface ICardAttributes {
341
374
  export declare interface ICardOptions {
342
375
  animation?: IAnimation;
343
376
  brand?: IBrand;
344
- css?: ICss;
377
+ css?: ICssCard;
345
378
  dateformat?: IDateFormat;
346
379
  debug?: boolean;
380
+ delay?: number;
347
381
  globe?: IGlobe;
348
382
  locale?: string;
349
- show?: IShow;
383
+ show?: IShowCard;
350
384
  }
351
385
 
352
386
  export declare interface ICategory {
@@ -367,77 +401,6 @@ export declare interface ICloud {
367
401
  previous_total: number;
368
402
  }
369
403
 
370
- export declare interface ICloudAnimation {
371
- interval: number;
372
- animation: number;
373
- speed: string;
374
- parentTag: string;
375
- }
376
-
377
- export declare interface ICloudBubbles {
378
- size: number;
379
- classlist: string;
380
- force: number;
381
- color: string;
382
- }
383
-
384
- export declare interface ICloudConfig {
385
- items?: number;
386
- chunk?: number;
387
- fixed?: number;
388
- abbreviate?: boolean;
389
- }
390
-
391
- export declare interface ICloudCss {
392
- arrowdown?: string;
393
- arrowup?: string;
394
- backdrop?: string;
395
- body?: string;
396
- brand?: string;
397
- change?: string;
398
- chart?: string;
399
- count?: string;
400
- container?: string;
401
- date?: string;
402
- down?: string;
403
- host?: string;
404
- image?: string;
405
- key?: string;
406
- legend?: string;
407
- title?: string;
408
- up?: string;
409
- widget?: string;
410
- dark?: boolean;
411
- }
412
-
413
- export declare interface ICloudD3 {
414
- globe: {
415
- colors: {
416
- arc: string;
417
- border: string;
418
- country: string;
419
- land: string;
420
- sphere: string;
421
- };
422
- settings?: {
423
- canvas?: string;
424
- card?: string;
425
- width?: number;
426
- height?: number;
427
- };
428
- };
429
- }
430
-
431
- export declare interface ICloudDateFormat {
432
- time?: string;
433
- date?: string;
434
- }
435
-
436
- export declare interface ICloudDimensions {
437
- width: number;
438
- height: number;
439
- }
440
-
441
404
  declare interface ICloudIndicators {
442
405
  total: number;
443
406
  positive: number;
@@ -449,7 +412,7 @@ declare interface ICloudIndicators {
449
412
  }
450
413
 
451
414
  export declare interface ICloudInfluencers {
452
- labels?: Label[];
415
+ labels?: InfluencerLabel[];
453
416
  title?: string;
454
417
  current?: ICloudInfluencersData[];
455
418
  previous?: ICloudInfluencersData[];
@@ -479,57 +442,43 @@ export declare interface ICloudInfluencersData {
479
442
  country: string;
480
443
  }
481
444
 
482
- export declare interface ICloudKpi {
483
- name: string;
484
- }
485
-
486
- export declare interface ICloudLegend {
487
- count?: {
488
- width?: string;
489
- height?: string;
490
- };
491
- key: {
492
- width: string;
493
- };
494
- width: string;
495
- position: string;
496
- gap?: {
497
- column: string;
498
- row: string;
499
- };
500
- show: {
501
- percentage: boolean;
502
- };
445
+ export declare interface ICloudOptions {
446
+ animation?: IAnimation;
447
+ component?: string;
448
+ css?: ICssCloud;
449
+ bubbles?: IBubbles;
450
+ config?: IConfig;
451
+ colors?: string;
452
+ data?: Data;
453
+ time?: ITime;
454
+ date?: IDate;
455
+ debug?: boolean;
456
+ dimensions?: IDimensions;
457
+ globe?: IGlobe;
458
+ highlight?: Highlight;
459
+ kpi?: Kpi;
460
+ legend?: ILegend;
461
+ pie?: IPie;
462
+ show?: IShowCloud;
463
+ words?: IWords;
503
464
  }
504
465
 
505
- export declare interface ICloudOptions {
506
- animation?: ICloudAnimation;
507
- css?: ICloudCss;
508
- d3?: ICloudD3;
509
- dateformat?: ICloudDateFormat;
510
- show?: ICloudShow;
511
- config?: ICloudConfig;
512
- colors?: string[];
513
- dimensions?: ICloudDimensions;
514
- pie?: ICloudPie;
515
- kpi?: ICloudKpi;
516
- legend?: ICloudLegend;
517
- bubbles?: ICloudBubbles;
518
- }
519
-
520
- export declare interface ICloudPie {
521
- radius: {
522
- inner: number;
523
- outer: number;
524
- };
525
- animation: {
526
- duration: number;
527
- };
466
+ declare interface IConfig {
467
+ fixed: number;
468
+ abbreviate: boolean;
469
+ chunk?: number;
470
+ items?: number;
471
+ label?: string;
528
472
  }
529
473
 
530
- export declare interface ICloudShow {
531
- brand?: boolean;
532
- date?: boolean;
474
+ export declare interface IContentsOptions {
475
+ css?: ICssContents;
476
+ date?: IDate;
477
+ globe?: IGlobe;
478
+ locale: string;
479
+ qr?: Qr;
480
+ time?: ITime;
481
+ youtube?: Youtube;
533
482
  }
534
483
 
535
484
  export declare interface ICountries {
@@ -544,16 +493,19 @@ export declare interface ICountry {
544
493
  fillStyle: string;
545
494
  }
546
495
 
547
- export declare interface ICss {
496
+ declare interface ICssCard {
548
497
  avatar?: string;
549
498
  backdrop?: string;
550
499
  body?: string;
500
+ bodylayout?: string;
551
501
  brand?: string;
502
+ canvas?: string;
552
503
  card?: string;
553
504
  container?: string;
554
505
  dark?: boolean;
555
506
  date?: string;
556
507
  dynamics?: string;
508
+ globe?: string;
557
509
  handle?: string;
558
510
  host?: string;
559
511
  image?: string;
@@ -567,6 +519,53 @@ export declare interface ICss {
567
519
  widget?: string;
568
520
  }
569
521
 
522
+ declare interface ICssCloud {
523
+ up: string;
524
+ down: string;
525
+ new: string;
526
+ arrowup: string;
527
+ arrowdown: string;
528
+ chart: string;
529
+ body: string;
530
+ brand: string;
531
+ count: string;
532
+ change: string;
533
+ highlight: string;
534
+ highlighted: string;
535
+ key: string;
536
+ host: string;
537
+ label: string;
538
+ legend: string;
539
+ row: string;
540
+ separator: string;
541
+ title: string;
542
+ widget: string;
543
+ words: string;
544
+ }
545
+
546
+ declare interface ICssContents {
547
+ body: string;
548
+ card: string;
549
+ globe?: string;
550
+ label: string;
551
+ widget: string;
552
+ }
553
+
554
+ declare interface ICssSeries {
555
+ arrowdown: string;
556
+ arrowup: string;
557
+ body: string;
558
+ brand: string;
559
+ change: string;
560
+ count: string;
561
+ down: string;
562
+ host: string;
563
+ label: string;
564
+ title: string;
565
+ up: string;
566
+ widget: string;
567
+ }
568
+
570
569
  export declare interface ID3Bubbles {
571
570
  size: number;
572
571
  force: number;
@@ -643,12 +642,21 @@ export declare interface IDashboards {
643
642
  dashboards: IDashboard[];
644
643
  }
645
644
 
646
- export declare interface IDateFormat {
645
+ declare interface IDate {
646
+ format: string;
647
+ }
648
+
649
+ declare interface IDateFormat {
647
650
  time?: string;
648
651
  date?: string;
649
652
  locale?: string;
650
653
  }
651
654
 
655
+ declare interface IDimensions {
656
+ width: number;
657
+ height: number;
658
+ }
659
+
652
660
  export declare interface IDynamics {
653
661
  engagement?: number;
654
662
  video_views?: number;
@@ -702,16 +710,38 @@ export declare interface IGeo {
702
710
  country: string;
703
711
  }
704
712
 
705
- export declare interface IGlobe {
706
- arc: string;
707
- border: string;
708
- country: string;
709
- land: string;
710
- sphere: string;
711
- canvas?: string;
712
- card?: string;
713
- width?: number;
714
- height?: number;
713
+ declare interface IGlobe {
714
+ width: number;
715
+ height: number;
716
+ arc: IGlobeArc;
717
+ border: IGlobeBorder;
718
+ country: IGlobeCountry;
719
+ land: IGlobeLand;
720
+ sphere: IGlobeSphere;
721
+ }
722
+
723
+ declare interface IGlobeArc {
724
+ stroke: string;
725
+ line: number;
726
+ }
727
+
728
+ declare interface IGlobeBorder {
729
+ stroke: string;
730
+ line: number;
731
+ }
732
+
733
+ declare interface IGlobeCountry {
734
+ fill: string;
735
+ }
736
+
737
+ declare interface IGlobeLand {
738
+ fill: string;
739
+ }
740
+
741
+ declare interface IGlobeSphere {
742
+ stroke: string;
743
+ line: number;
744
+ fill: string;
715
745
  }
716
746
 
717
747
  export declare interface IImage {
@@ -886,6 +916,33 @@ export declare interface ILayoutZones {
886
916
  ["x:string"]: ILayoutZone[];
887
917
  }
888
918
 
919
+ declare interface ILegend {
920
+ key: ILegendKey;
921
+ label: ILegendLabel;
922
+ count: ILegendCount;
923
+ width: string;
924
+ position: string;
925
+ show: IShowLegend;
926
+ gap: ILegendGap;
927
+ }
928
+
929
+ declare interface ILegendCount {
930
+ width: string;
931
+ }
932
+
933
+ declare interface ILegendGap {
934
+ column: string;
935
+ row: string;
936
+ }
937
+
938
+ declare interface ILegendKey {
939
+ width: string;
940
+ }
941
+
942
+ declare interface ILegendLabel {
943
+ width: string;
944
+ }
945
+
889
946
  export declare interface IMedium {
890
947
  type: string;
891
948
  url: string;
@@ -947,8 +1004,34 @@ export declare interface IModal {
947
1004
  timeout?: number;
948
1005
  }
949
1006
 
1007
+ export declare interface InfluencerLabel {
1008
+ label: string;
1009
+ count: number;
1010
+ info: string;
1011
+ }
1012
+
950
1013
  export declare const intToString: (num: any, digits?: number, abbreviate?: boolean, locale?: string) => string;
951
1014
 
1015
+ declare interface IPie {
1016
+ radius: IPieRadius;
1017
+ animation: IPieAnimation;
1018
+ }
1019
+
1020
+ /**
1021
+ * Animation Duration
1022
+ */
1023
+ declare interface IPieAnimation {
1024
+ duration: number;
1025
+ }
1026
+
1027
+ /**
1028
+ * inner and outer radius in px
1029
+ */
1030
+ declare interface IPieRadius {
1031
+ inner: number;
1032
+ outer: number;
1033
+ }
1034
+
952
1035
  export declare interface IPreference {
953
1036
  id: string;
954
1037
  value?: string;
@@ -1055,50 +1138,6 @@ export declare interface ISeries {
1055
1138
  timestamp?: number;
1056
1139
  }
1057
1140
 
1058
- export declare interface ISeriesConfig {
1059
- fixed?: number;
1060
- abbreviate?: boolean;
1061
- label?: string;
1062
- }
1063
-
1064
- export declare interface ISeriesCss {
1065
- arrowdown?: string;
1066
- arrowup?: string;
1067
- backdrop?: string;
1068
- body?: string;
1069
- brand?: string;
1070
- change?: string;
1071
- count?: string;
1072
- container?: string;
1073
- date?: string;
1074
- down?: string;
1075
- host?: string;
1076
- image?: string;
1077
- label?: string;
1078
- title?: string;
1079
- up?: string;
1080
- widget?: string;
1081
- dark?: boolean;
1082
- }
1083
-
1084
- export declare interface ISeriesD3 {
1085
- globe: {
1086
- colors: {
1087
- arc: string;
1088
- border: string;
1089
- country: string;
1090
- land: string;
1091
- sphere: string;
1092
- };
1093
- settings?: {
1094
- canvas?: string;
1095
- card?: string;
1096
- width?: number;
1097
- height?: number;
1098
- };
1099
- };
1100
- }
1101
-
1102
1141
  export declare interface ISeriesData {
1103
1142
  name?: string;
1104
1143
  label?: string;
@@ -1110,28 +1149,21 @@ export declare interface ISeriesData {
1110
1149
  previous_category?: number;
1111
1150
  }
1112
1151
 
1113
- export declare interface ISeriesDateFormat {
1114
- time?: string;
1115
- date?: string;
1116
- }
1117
-
1118
1152
  export declare interface ISeriesOptions {
1119
- css?: ISeriesCss;
1120
- d3?: ISeriesD3;
1121
- dateformat?: ISeriesDateFormat;
1122
- show?: ISeriesShow;
1123
- config?: ISeriesConfig;
1153
+ colors?: string;
1154
+ css?: ICssSeries;
1155
+ time?: ITime;
1156
+ date?: IDate;
1157
+ dimensions?: IDimensions;
1158
+ show?: IShowSeries;
1159
+ config?: IConfig;
1124
1160
  }
1125
1161
 
1126
- export declare interface ISeriesShow {
1127
- brand?: boolean;
1128
- date?: boolean;
1129
- }
1130
-
1131
- export declare interface IShow {
1162
+ declare interface IShowCard {
1132
1163
  approve?: boolean;
1133
1164
  avatar?: boolean;
1134
1165
  brand?: boolean;
1166
+ carousel?: boolean;
1135
1167
  date?: boolean;
1136
1168
  dynamics?: boolean;
1137
1169
  handle?: boolean;
@@ -1144,6 +1176,26 @@ export declare interface IShow {
1144
1176
  debug?: boolean;
1145
1177
  }
1146
1178
 
1179
+ declare interface IShowCloud {
1180
+ emojis: boolean;
1181
+ brand: boolean;
1182
+ date: boolean;
1183
+ gradient: boolean;
1184
+ hashtags: boolean;
1185
+ trend: boolean;
1186
+ }
1187
+
1188
+ declare interface IShowLegend {
1189
+ percentage: boolean;
1190
+ }
1191
+
1192
+ declare interface IShowSeries {
1193
+ brand: boolean;
1194
+ percentage: boolean;
1195
+ date: boolean;
1196
+ kpi: boolean;
1197
+ }
1198
+
1147
1199
  export declare interface ISlides {
1148
1200
  presentation: string;
1149
1201
  slides: any;
@@ -1194,6 +1246,10 @@ export declare interface IStorageOptions {
1194
1246
  workers?: boolean;
1195
1247
  }
1196
1248
 
1249
+ declare interface ITime {
1250
+ format: string;
1251
+ }
1252
+
1197
1253
  export declare interface ITopic {
1198
1254
  message_id: string;
1199
1255
  dashboard_id?: string;
@@ -1258,6 +1314,13 @@ export declare interface IWidgetSettings {
1258
1314
  component: IWidgetComponent;
1259
1315
  }
1260
1316
 
1317
+ declare interface IWords {
1318
+ duration: number;
1319
+ multiplier: number;
1320
+ padding: number;
1321
+ range: string;
1322
+ }
1323
+
1261
1324
  export declare const json2html: (json: any) => any;
1262
1325
 
1263
1326
  export declare interface JsonChild {
@@ -1267,23 +1330,30 @@ export declare interface JsonChild {
1267
1330
  child: JsonChild[];
1268
1331
  }
1269
1332
 
1270
- export declare interface Label {
1271
- label: string;
1272
- count: number;
1273
- info: string;
1274
- }
1275
-
1276
- export declare interface Land {
1277
- type: string;
1278
- geometries: LandGeometry[];
1333
+ export declare interface Kpi {
1334
+ name: string;
1279
1335
  }
1280
1336
 
1281
1337
  export declare interface LandGeometry {
1282
- type: Type;
1338
+ type: GeoType;
1283
1339
  arcs: Array<Array<number[]>>;
1284
1340
  }
1285
1341
 
1286
- export declare const log: (level: number | undefined, message: any[]) => void;
1342
+ /**
1343
+ * Send Message to worker, don't block the main thread
1344
+ *
1345
+ * @param level Log Level
1346
+ *
1347
+ * @returns
1348
+ */
1349
+ export declare const log: (level: number | string | undefined, message: any[]) => Promise<void>;
1350
+
1351
+ export declare const logging: {
1352
+ add: (level: number | string) => void;
1353
+ clear: () => void;
1354
+ delete: (level: number | string) => void;
1355
+ list: () => void;
1356
+ };
1287
1357
 
1288
1358
  export declare const maxifyCss: (css: string) => string;
1289
1359
 
@@ -1329,6 +1399,27 @@ export declare function moderation(options: IStorageOptions, query: IQuery): IQu
1329
1399
 
1330
1400
  export declare function numberFormatter(num: number, digits: number): string;
1331
1401
 
1402
+ /**
1403
+ * Series
1404
+ */
1405
+ export declare interface Percentage {
1406
+ count: boolean;
1407
+ change: boolean;
1408
+ }
1409
+
1410
+ /**
1411
+ * Contents
1412
+ */
1413
+ export declare interface Qr {
1414
+ text: string;
1415
+ correction: string;
1416
+ margin: number;
1417
+ scale: number;
1418
+ colorDark: string;
1419
+ colorLight: string;
1420
+ outputMode: string;
1421
+ }
1422
+
1332
1423
  export declare const randomColor: () => string;
1333
1424
 
1334
1425
  export declare const randomRGB: () => string;
@@ -1406,11 +1497,6 @@ export declare interface Transform {
1406
1497
  translate: number[];
1407
1498
  }
1408
1499
 
1409
- export declare enum Type {
1410
- MultiPolygon = "MultiPolygon",
1411
- Polygon = "Polygon"
1412
- }
1413
-
1414
1500
  export declare const typeCss: (query: IQuery | undefined) => string;
1415
1501
 
1416
1502
  export declare const uniq: (length?: number, existing?: never[]) => string;
@@ -1433,4 +1519,9 @@ export declare interface YAxis {
1433
1519
  type: string;
1434
1520
  }
1435
1521
 
1522
+ export declare interface Youtube {
1523
+ list: string;
1524
+ title: string;
1525
+ }
1526
+
1436
1527
  export { }