@parra/parra-js-sdk 0.2.100 → 0.2.101

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.
@@ -400,13 +400,23 @@ export interface CardsResponse {
400
400
  export declare enum QuestionType {
401
401
  choice = "choice",
402
402
  checkbox = "checkbox",
403
- rating = "rating"
403
+ rating = "rating",
404
+ text = "text",
405
+ rankedChoice = "ranked-choice"
404
406
  }
405
407
  export declare enum QuestionKind {
406
408
  radio = "radio",
407
409
  checkbox = "checkbox",
408
410
  star = "star",
409
- image = "image"
411
+ image = "image",
412
+ rating = "rating",
413
+ shortText = "short-text",
414
+ longText = "long-text",
415
+ emoji = "emoji",
416
+ boolean = "boolean",
417
+ slider = "slider",
418
+ rankedChoice = "ranked-choice",
419
+ tag = "tag"
410
420
  }
411
421
  export interface MutableChoiceQuestionOption {
412
422
  title: string;
@@ -460,8 +470,23 @@ export interface ImageQuestionBody {
460
470
  export interface MutableImageQuestionBody {
461
471
  options: Array<MutableImageQuestionOption>;
462
472
  }
463
- export declare type MutableQuestionData = MutableChoiceQuestionBody | MutableCheckboxQuestionBody | MutableImageQuestionBody;
464
- export declare type QuestionData = ChoiceQuestionBody | CheckboxQuestionBody | ImageQuestionBody;
473
+ export interface MutableRatingQuestionOption {
474
+ title: string;
475
+ value: number;
476
+ }
477
+ export interface RatingQuestionOption {
478
+ title: string;
479
+ value: number;
480
+ id: string;
481
+ }
482
+ export interface RatingQuestionBody {
483
+ options: Array<RatingQuestionOption>;
484
+ }
485
+ export interface MutableRatingQuestionBody {
486
+ options: Array<MutableRatingQuestionOption>;
487
+ }
488
+ export declare type MutableQuestionData = MutableChoiceQuestionBody | MutableCheckboxQuestionBody | MutableImageQuestionBody | MutableRatingQuestionBody;
489
+ export declare type QuestionData = ChoiceQuestionBody | CheckboxQuestionBody | ImageQuestionBody | RatingQuestionBody;
465
490
  export interface UpdateQuestionRequestBody {
466
491
  title: string;
467
492
  subtitle?: string | null;
@@ -534,7 +559,7 @@ export interface QuestionMetrics {
534
559
  type: QuestionType;
535
560
  data: QuestionMetricsData;
536
561
  }
537
- export declare type QuestionMetricsData = ChoiceQuestionMetricsBody | CheckboxQuestionMetricsBody | InageQuestionMetricsBody;
562
+ export declare type QuestionMetricsData = ChoiceQuestionMetricsBody | CheckboxQuestionMetricsBody | InageQuestionMetricsBody | RatingQuestionMetricsBody;
538
563
  export interface ChoiceQuestionMetricsBody {
539
564
  options: Array<ChoiceQuestionMetricsOption>;
540
565
  }
@@ -566,6 +591,15 @@ export interface ImageQuestionMetricsOption {
566
591
  image_asset_url: string;
567
592
  answer_count: number;
568
593
  }
594
+ export interface RatingQuestionMetricsBody {
595
+ options: Array<RatingQuestionMetricsOption>;
596
+ }
597
+ export interface RatingQuestionMetricsOption {
598
+ title: string;
599
+ value: number;
600
+ id: string;
601
+ answer_count: number;
602
+ }
569
603
  export interface Event {
570
604
  name: string;
571
605
  created_at: string | null;
package/dist/ParraAPI.js CHANGED
@@ -37,6 +37,8 @@ var QuestionType;
37
37
  QuestionType["choice"] = "choice";
38
38
  QuestionType["checkbox"] = "checkbox";
39
39
  QuestionType["rating"] = "rating";
40
+ QuestionType["text"] = "text";
41
+ QuestionType["rankedChoice"] = "ranked-choice";
40
42
  })(QuestionType = exports.QuestionType || (exports.QuestionType = {}));
41
43
  var QuestionKind;
42
44
  (function (QuestionKind) {
@@ -44,6 +46,14 @@ var QuestionKind;
44
46
  QuestionKind["checkbox"] = "checkbox";
45
47
  QuestionKind["star"] = "star";
46
48
  QuestionKind["image"] = "image";
49
+ QuestionKind["rating"] = "rating";
50
+ QuestionKind["shortText"] = "short-text";
51
+ QuestionKind["longText"] = "long-text";
52
+ QuestionKind["emoji"] = "emoji";
53
+ QuestionKind["boolean"] = "boolean";
54
+ QuestionKind["slider"] = "slider";
55
+ QuestionKind["rankedChoice"] = "ranked-choice";
56
+ QuestionKind["tag"] = "tag";
47
57
  })(QuestionKind = exports.QuestionKind || (exports.QuestionKind = {}));
48
58
  var QuestionStatus;
49
59
  (function (QuestionStatus) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@parra/parra-js-sdk",
3
- "version": "0.2.100",
3
+ "version": "0.2.101",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",