catchup-library-web 2.6.20 → 2.6.22

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.mts CHANGED
@@ -925,13 +925,13 @@ declare const constructOutcomeActivityScoreList: (data: any) => any[];
925
925
  declare const constructCombinedOutcomeActivityScoreMapFromCombinedReport: (combinedCorporateAssessmentAssignmentReportMap: any) => any;
926
926
 
927
927
  declare const convertDataURLtoFile: (dataurl: string, filename: string) => File;
928
- declare const retrieveFileTypeFromAcceptedFormat: (format: string) => "IMAGE" | "AUDIO" | "PDF" | undefined;
928
+ declare const retrieveFileTypeFromAcceptedFormat: (format: string) => "IMAGE" | "VIDEO" | "AUDIO" | "PDF" | undefined;
929
929
  declare const retrieveFileTypeFromExtension: (format: string) => "" | "IMAGE" | "VIDEO" | "AUDIO" | "PDF";
930
930
  declare const retrieveFileTypeOptionList: (optionType: string) => {
931
931
  text: string;
932
932
  value: string;
933
933
  }[];
934
- declare const retrieveAcceptedFormats: (fileType: string) => "application/pdf" | "audio/mp3" | "image/jpeg, image/png, image/jpg, image/webp" | "video/mp4" | undefined;
934
+ declare const retrieveAcceptedFormats: (fileType: string) => "application/pdf" | "audio/mp3" | "image/jpeg, image/png, image/jpg, image/webp" | "video/mp4, video/webm, video/quicktime, video/x-msvideo" | undefined;
935
935
 
936
936
  declare const retrieveTokenUsageTypeOptionList: () => {
937
937
  text: string;
package/dist/index.d.ts CHANGED
@@ -925,13 +925,13 @@ declare const constructOutcomeActivityScoreList: (data: any) => any[];
925
925
  declare const constructCombinedOutcomeActivityScoreMapFromCombinedReport: (combinedCorporateAssessmentAssignmentReportMap: any) => any;
926
926
 
927
927
  declare const convertDataURLtoFile: (dataurl: string, filename: string) => File;
928
- declare const retrieveFileTypeFromAcceptedFormat: (format: string) => "IMAGE" | "AUDIO" | "PDF" | undefined;
928
+ declare const retrieveFileTypeFromAcceptedFormat: (format: string) => "IMAGE" | "VIDEO" | "AUDIO" | "PDF" | undefined;
929
929
  declare const retrieveFileTypeFromExtension: (format: string) => "" | "IMAGE" | "VIDEO" | "AUDIO" | "PDF";
930
930
  declare const retrieveFileTypeOptionList: (optionType: string) => {
931
931
  text: string;
932
932
  value: string;
933
933
  }[];
934
- declare const retrieveAcceptedFormats: (fileType: string) => "application/pdf" | "audio/mp3" | "image/jpeg, image/png, image/jpg, image/webp" | "video/mp4" | undefined;
934
+ declare const retrieveAcceptedFormats: (fileType: string) => "application/pdf" | "audio/mp3" | "image/jpeg, image/png, image/jpg, image/webp" | "video/mp4, video/webm, video/quicktime, video/x-msvideo" | undefined;
935
935
 
936
936
  declare const retrieveTokenUsageTypeOptionList: () => {
937
937
  text: string;
package/dist/index.js CHANGED
@@ -6633,6 +6633,8 @@ var retrieveFileTypeFromAcceptedFormat = (format) => {
6633
6633
  return "IMAGE";
6634
6634
  } else if (format === "audio/mp3") {
6635
6635
  return "AUDIO";
6636
+ } else if (format === "video/mp4" || format === "video/webm" || format === "video/quicktime" || format === "video/x-msvideo") {
6637
+ return "VIDEO";
6636
6638
  }
6637
6639
  };
6638
6640
  var retrieveFileTypeFromExtension = (format) => {
@@ -6701,7 +6703,7 @@ var retrieveAcceptedFormats = (fileType) => {
6701
6703
  if (fileType === "IMAGE") {
6702
6704
  return "image/jpeg, image/png, image/jpg, image/webp";
6703
6705
  } else if (fileType === "VIDEO") {
6704
- return "video/mp4";
6706
+ return "video/mp4, video/webm, video/quicktime, video/x-msvideo";
6705
6707
  } else if (fileType === "AUDIO") {
6706
6708
  return "audio/mp3";
6707
6709
  } else if (fileType === "PDF") {
@@ -6731,7 +6733,7 @@ var OpenEndedActivityMaterialContent = ({
6731
6733
  src: answerMapAnswer,
6732
6734
  alt: "document",
6733
6735
  size: "custom",
6734
- className: "w-[80%] rounded-catchup-xlarge max-h-[50vh] object-contain"
6736
+ className: "w-full rounded-catchup-xlarge max-h-[50vh] object-contain"
6735
6737
  }
6736
6738
  ) });
6737
6739
  } else if (fileType === "PDF") {
@@ -6751,7 +6753,7 @@ var OpenEndedActivityMaterialContent = ({
6751
6753
  return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("div", { className: "flex flex-col justify-center items-center my-5", children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
6752
6754
  "video",
6753
6755
  {
6754
- className: "w-[80%] rounded-catchup-xlarge max-h-[50vh]",
6756
+ className: "w-full rounded-catchup-xlarge max-h-[50vh]",
6755
6757
  src: answerMapAnswer,
6756
6758
  controls: true
6757
6759
  }
@@ -6782,7 +6784,7 @@ var OpenEndedActivityMaterialContent = ({
6782
6784
  src: answerMapAnswer,
6783
6785
  alt: "document",
6784
6786
  size: "custom",
6785
- className: "w-[80%] rounded-catchup-xlarge max-h-[50vh] object-contain"
6787
+ className: "w-full rounded-catchup-xlarge max-h-[50vh] object-contain"
6786
6788
  }
6787
6789
  ) }) : fileType === "PDF" ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("div", { className: "flex flex-col justify-center items-center my-5", children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(BasePDF_default, { file: answerMapAnswer }) }) : null });
6788
6790
  };
@@ -6804,7 +6806,7 @@ var OpenEndedActivityMaterialContent = ({
6804
6806
  return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("div", { className: "flex flex-col justify-center items-center my-5", children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
6805
6807
  "video",
6806
6808
  {
6807
- className: "w-[80%] rounded-catchup-xlarge max-h-[50vh]",
6809
+ className: "w-full rounded-catchup-xlarge max-h-[50vh]",
6808
6810
  src: answerMapAnswer,
6809
6811
  controls: true
6810
6812
  }
package/dist/index.mjs CHANGED
@@ -6395,6 +6395,8 @@ var retrieveFileTypeFromAcceptedFormat = (format) => {
6395
6395
  return "IMAGE";
6396
6396
  } else if (format === "audio/mp3") {
6397
6397
  return "AUDIO";
6398
+ } else if (format === "video/mp4" || format === "video/webm" || format === "video/quicktime" || format === "video/x-msvideo") {
6399
+ return "VIDEO";
6398
6400
  }
6399
6401
  };
6400
6402
  var retrieveFileTypeFromExtension = (format) => {
@@ -6463,7 +6465,7 @@ var retrieveAcceptedFormats = (fileType) => {
6463
6465
  if (fileType === "IMAGE") {
6464
6466
  return "image/jpeg, image/png, image/jpg, image/webp";
6465
6467
  } else if (fileType === "VIDEO") {
6466
- return "video/mp4";
6468
+ return "video/mp4, video/webm, video/quicktime, video/x-msvideo";
6467
6469
  } else if (fileType === "AUDIO") {
6468
6470
  return "audio/mp3";
6469
6471
  } else if (fileType === "PDF") {
@@ -6493,7 +6495,7 @@ var OpenEndedActivityMaterialContent = ({
6493
6495
  src: answerMapAnswer,
6494
6496
  alt: "document",
6495
6497
  size: "custom",
6496
- className: "w-[80%] rounded-catchup-xlarge max-h-[50vh] object-contain"
6498
+ className: "w-full rounded-catchup-xlarge max-h-[50vh] object-contain"
6497
6499
  }
6498
6500
  ) });
6499
6501
  } else if (fileType === "PDF") {
@@ -6513,7 +6515,7 @@ var OpenEndedActivityMaterialContent = ({
6513
6515
  return /* @__PURE__ */ jsx40("div", { className: "flex flex-col justify-center items-center my-5", children: /* @__PURE__ */ jsx40(
6514
6516
  "video",
6515
6517
  {
6516
- className: "w-[80%] rounded-catchup-xlarge max-h-[50vh]",
6518
+ className: "w-full rounded-catchup-xlarge max-h-[50vh]",
6517
6519
  src: answerMapAnswer,
6518
6520
  controls: true
6519
6521
  }
@@ -6544,7 +6546,7 @@ var OpenEndedActivityMaterialContent = ({
6544
6546
  src: answerMapAnswer,
6545
6547
  alt: "document",
6546
6548
  size: "custom",
6547
- className: "w-[80%] rounded-catchup-xlarge max-h-[50vh] object-contain"
6549
+ className: "w-full rounded-catchup-xlarge max-h-[50vh] object-contain"
6548
6550
  }
6549
6551
  ) }) : fileType === "PDF" ? /* @__PURE__ */ jsx40("div", { className: "flex flex-col justify-center items-center my-5", children: /* @__PURE__ */ jsx40(BasePDF_default, { file: answerMapAnswer }) }) : null });
6550
6552
  };
@@ -6566,7 +6568,7 @@ var OpenEndedActivityMaterialContent = ({
6566
6568
  return /* @__PURE__ */ jsx40("div", { className: "flex flex-col justify-center items-center my-5", children: /* @__PURE__ */ jsx40(
6567
6569
  "video",
6568
6570
  {
6569
- className: "w-[80%] rounded-catchup-xlarge max-h-[50vh]",
6571
+ className: "w-full rounded-catchup-xlarge max-h-[50vh]",
6570
6572
  src: answerMapAnswer,
6571
6573
  controls: true
6572
6574
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "catchup-library-web",
3
- "version": "2.6.20",
3
+ "version": "2.6.22",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {
@@ -29,7 +29,7 @@ const OpenEndedActivityMaterialContent = ({
29
29
  src={answerMapAnswer}
30
30
  alt="document"
31
31
  size="custom"
32
- className="w-[80%] rounded-catchup-xlarge max-h-[50vh] object-contain"
32
+ className="w-full rounded-catchup-xlarge max-h-[50vh] object-contain"
33
33
  />
34
34
  </div>
35
35
  );
@@ -50,7 +50,7 @@ const OpenEndedActivityMaterialContent = ({
50
50
  return (
51
51
  <div className="flex flex-col justify-center items-center my-5">
52
52
  <video
53
- className="w-[80%] rounded-catchup-xlarge max-h-[50vh]"
53
+ className="w-full rounded-catchup-xlarge max-h-[50vh]"
54
54
  src={answerMapAnswer}
55
55
  controls
56
56
  />
@@ -84,7 +84,7 @@ const OpenEndedActivityMaterialContent = ({
84
84
  src={answerMapAnswer}
85
85
  alt="document"
86
86
  size="custom"
87
- className="w-[80%] rounded-catchup-xlarge max-h-[50vh] object-contain"
87
+ className="w-full rounded-catchup-xlarge max-h-[50vh] object-contain"
88
88
  />
89
89
  </div>
90
90
  ) : fileType === "PDF" ? (
@@ -115,7 +115,7 @@ const OpenEndedActivityMaterialContent = ({
115
115
  return (
116
116
  <div className="flex flex-col justify-center items-center my-5">
117
117
  <video
118
- className="w-[80%] rounded-catchup-xlarge max-h-[50vh]"
118
+ className="w-full rounded-catchup-xlarge max-h-[50vh]"
119
119
  src={answerMapAnswer}
120
120
  controls
121
121
  />
@@ -24,6 +24,13 @@ export const retrieveFileTypeFromAcceptedFormat = (format: string) => {
24
24
  return "IMAGE";
25
25
  } else if (format === "audio/mp3") {
26
26
  return "AUDIO";
27
+ } else if (
28
+ format === "video/mp4" ||
29
+ format === "video/webm" ||
30
+ format === "video/quicktime" ||
31
+ format === "video/x-msvideo"
32
+ ) {
33
+ return "VIDEO";
27
34
  }
28
35
  };
29
36
 
@@ -105,7 +112,7 @@ export const retrieveAcceptedFormats = (fileType: string) => {
105
112
  if (fileType === "IMAGE") {
106
113
  return "image/jpeg, image/png, image/jpg, image/webp";
107
114
  } else if (fileType === "VIDEO") {
108
- return "video/mp4";
115
+ return "video/mp4, video/webm, video/quicktime, video/x-msvideo";
109
116
  } else if (fileType === "AUDIO") {
110
117
  return "audio/mp3";
111
118
  } else if (fileType === "PDF") {