videomail-client 11.1.0 → 11.1.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.
- package/dist/cjs/index.cjs +8 -16
- package/dist/esm/client.d.ts +1 -1
- package/dist/esm/index.d.ts +10 -17
- package/dist/esm/index.js +8 -13
- package/dist/esm/resource.d.ts +1 -1
- package/dist/esm/types/Videomail.d.ts +2 -2
- package/dist/esm/types/events/index.d.ts +1 -1
- package/dist/esm/wrappers/container.d.ts +1 -1
- package/dist/esm/wrappers/form.d.ts +1 -1
- package/dist/esm/wrappers/visuals/replay.d.ts +1 -1
- package/dist/umd/index.js +8 -14
- package/package.json +8 -8
package/dist/cjs/index.cjs
CHANGED
|
@@ -10324,8 +10324,7 @@ var __webpack_exports__ = {};
|
|
|
10324
10324
|
"use strict";
|
|
10325
10325
|
__webpack_require__.r(__webpack_exports__);
|
|
10326
10326
|
__webpack_require__.d(__webpack_exports__, {
|
|
10327
|
-
VideomailClient: ()=>src_client
|
|
10328
|
-
VideoType: ()=>VideoType_VideoType
|
|
10327
|
+
VideomailClient: ()=>src_client
|
|
10329
10328
|
});
|
|
10330
10329
|
const constants = {
|
|
10331
10330
|
SITE_NAME_LABEL: "x-videomail-site-name",
|
|
@@ -10488,7 +10487,7 @@ var __webpack_exports__ = {};
|
|
|
10488
10487
|
var client = __webpack_require__("./node_modules/superagent/lib/client.js");
|
|
10489
10488
|
var client_default = /*#__PURE__*/ __webpack_require__.n(client);
|
|
10490
10489
|
var package_namespaceObject = {
|
|
10491
|
-
rE: "11.1.
|
|
10490
|
+
rE: "11.1.1"
|
|
10492
10491
|
};
|
|
10493
10492
|
var defined = __webpack_require__("./node_modules/defined/index.js");
|
|
10494
10493
|
var defined_default = /*#__PURE__*/ __webpack_require__.n(defined);
|
|
@@ -13640,7 +13639,7 @@ var __webpack_exports__ = {};
|
|
|
13640
13639
|
else obj[key] = value;
|
|
13641
13640
|
return obj;
|
|
13642
13641
|
}
|
|
13643
|
-
const FALLBACK_VIDEO_TYPE =
|
|
13642
|
+
const FALLBACK_VIDEO_TYPE = "mp4";
|
|
13644
13643
|
class Browser_Browser {
|
|
13645
13644
|
isIOS() {
|
|
13646
13645
|
return "iOS" === this.result.os.name;
|
|
@@ -13678,10 +13677,10 @@ var __webpack_exports__ = {};
|
|
|
13678
13677
|
}
|
|
13679
13678
|
getVideoType(video) {
|
|
13680
13679
|
if (!this.videoType) {
|
|
13681
|
-
if (media_canPlayType(video,
|
|
13682
|
-
else if (media_canPlayType(video,
|
|
13680
|
+
if (media_canPlayType(video, "mp4")) this.videoType = "mp4";
|
|
13681
|
+
else if (media_canPlayType(video, "webm")) this.videoType = "webm";
|
|
13683
13682
|
}
|
|
13684
|
-
if (
|
|
13683
|
+
if ("webm" !== this.videoType && "mp4" !== this.videoType) this.videoType = FALLBACK_VIDEO_TYPE;
|
|
13685
13684
|
if ("" === this.videoType.trim()) this.videoType = FALLBACK_VIDEO_TYPE;
|
|
13686
13685
|
return this.videoType;
|
|
13687
13686
|
}
|
|
@@ -17882,10 +17881,10 @@ var __webpack_exports__ = {};
|
|
|
17882
17881
|
}
|
|
17883
17882
|
}
|
|
17884
17883
|
setMp4Source(src, bustCache) {
|
|
17885
|
-
this.setVideoSource(
|
|
17884
|
+
this.setVideoSource("mp4", src, bustCache);
|
|
17886
17885
|
}
|
|
17887
17886
|
setWebMSource(src, bustCache) {
|
|
17888
|
-
this.setVideoSource(
|
|
17887
|
+
this.setVideoSource("webm", src, bustCache);
|
|
17889
17888
|
}
|
|
17890
17889
|
getVideoType() {
|
|
17891
17890
|
if (!this.replayElement) return;
|
|
@@ -18815,16 +18814,9 @@ var __webpack_exports__ = {};
|
|
|
18815
18814
|
client_define_property(VideomailClient, "ENC_TYPE_APP_JSON", constants["public"].ENC_TYPE_APP_JSON);
|
|
18816
18815
|
client_define_property(VideomailClient, "ENC_TYPE_FORM", constants["public"].ENC_TYPE_FORM);
|
|
18817
18816
|
const src_client = VideomailClient;
|
|
18818
|
-
var VideoType_VideoType = /*#__PURE__*/ function(VideoType1) {
|
|
18819
|
-
VideoType1["WebM"] = "webm";
|
|
18820
|
-
VideoType1["MP4"] = "mp4";
|
|
18821
|
-
return VideoType1;
|
|
18822
|
-
}({});
|
|
18823
18817
|
})();
|
|
18824
|
-
exports.VideoType = __webpack_exports__.VideoType;
|
|
18825
18818
|
exports.VideomailClient = __webpack_exports__.VideomailClient;
|
|
18826
18819
|
for(var __webpack_i__ in __webpack_exports__)if (-1 === [
|
|
18827
|
-
"VideoType",
|
|
18828
18820
|
"VideomailClient"
|
|
18829
18821
|
].indexOf(__webpack_i__)) exports[__webpack_i__] = __webpack_exports__[__webpack_i__];
|
|
18830
18822
|
Object.defineProperty(exports, '__esModule', {
|
package/dist/esm/client.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { PartialVideomailClientOptions } from "./types/options";
|
|
2
|
-
import Videomail from "./types/Videomail";
|
|
2
|
+
import type { Videomail } from "./types/Videomail";
|
|
3
3
|
import Despot from "./util/Despot";
|
|
4
4
|
export interface StartOverParams {
|
|
5
5
|
keepHidden?: boolean | undefined;
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -1,19 +1,12 @@
|
|
|
1
1
|
import VideomailClient from "./client";
|
|
2
|
-
import { Command, CommandArgs } from "./types/command";
|
|
3
|
-
import DeliveryRecord from "./types/DeliveryRecord";
|
|
4
|
-
import { EmailAddress, EmailAddresses } from "./types/EmailAddress";
|
|
5
|
-
import { FullVideomailErrorData, VideomailErrorData } from "./types/error";
|
|
6
|
-
import VideomailEvents from "./types/events";
|
|
7
|
-
import { VideomailClientOptions } from "./types/options";
|
|
8
|
-
import RecordingStats from "./types/RecordingStats";
|
|
9
|
-
import
|
|
2
|
+
import type { Command, CommandArgs } from "./types/command";
|
|
3
|
+
import type DeliveryRecord from "./types/DeliveryRecord";
|
|
4
|
+
import type { EmailAddress, EmailAddresses } from "./types/EmailAddress";
|
|
5
|
+
import type { FullVideomailErrorData, VideomailErrorData } from "./types/error";
|
|
6
|
+
import type VideomailEvents from "./types/events";
|
|
7
|
+
import type { VideomailClientOptions } from "./types/options";
|
|
8
|
+
import type RecordingStats from "./types/RecordingStats";
|
|
9
|
+
import type { PartialVideomail, Videomail } from "./types/Videomail";
|
|
10
10
|
import { VideoType } from "./types/VideoType";
|
|
11
|
-
export type { Videomail };
|
|
12
|
-
export
|
|
13
|
-
export type { RecordingStats };
|
|
14
|
-
export type { VideomailClientOptions };
|
|
15
|
-
export { VideomailClient, VideoType };
|
|
16
|
-
export type { FullVideomailErrorData, PartialVideomail, VideomailErrorData };
|
|
17
|
-
export type { Command, CommandArgs };
|
|
18
|
-
export type { DeliveryRecord };
|
|
19
|
-
export type { EmailAddress, EmailAddresses };
|
|
11
|
+
export type { Command, CommandArgs, DeliveryRecord, EmailAddress, EmailAddresses, FullVideomailErrorData, PartialVideomail, RecordingStats, Videomail, VideomailClientOptions, VideomailErrorData, VideomailEvents, VideoType, };
|
|
12
|
+
export { VideomailClient };
|
package/dist/esm/index.js
CHANGED
|
@@ -3454,20 +3454,15 @@ const constants = {
|
|
|
3454
3454
|
}
|
|
3455
3455
|
};
|
|
3456
3456
|
var package_namespaceObject = {
|
|
3457
|
-
rE: "11.1.
|
|
3457
|
+
rE: "11.1.1"
|
|
3458
3458
|
};
|
|
3459
|
-
var VideoType_VideoType = /*#__PURE__*/ function(VideoType1) {
|
|
3460
|
-
VideoType1["WebM"] = "webm";
|
|
3461
|
-
VideoType1["MP4"] = "mp4";
|
|
3462
|
-
return VideoType1;
|
|
3463
|
-
}({});
|
|
3464
3459
|
function canPlayType_canPlayType(video, type) {
|
|
3465
3460
|
const canPlayType = video.canPlayType(`video/${type}`);
|
|
3466
3461
|
if ("" === canPlayType) return false;
|
|
3467
3462
|
return canPlayType;
|
|
3468
3463
|
}
|
|
3469
3464
|
const media_canPlayType = canPlayType_canPlayType;
|
|
3470
|
-
const FALLBACK_VIDEO_TYPE =
|
|
3465
|
+
const FALLBACK_VIDEO_TYPE = "mp4";
|
|
3471
3466
|
class Browser {
|
|
3472
3467
|
options;
|
|
3473
3468
|
result;
|
|
@@ -3514,10 +3509,10 @@ class Browser {
|
|
|
3514
3509
|
}
|
|
3515
3510
|
getVideoType(video) {
|
|
3516
3511
|
if (!this.videoType) {
|
|
3517
|
-
if (media_canPlayType(video,
|
|
3518
|
-
else if (media_canPlayType(video,
|
|
3512
|
+
if (media_canPlayType(video, "mp4")) this.videoType = "mp4";
|
|
3513
|
+
else if (media_canPlayType(video, "webm")) this.videoType = "webm";
|
|
3519
3514
|
}
|
|
3520
|
-
if (
|
|
3515
|
+
if ("webm" !== this.videoType && "mp4" !== this.videoType) this.videoType = FALLBACK_VIDEO_TYPE;
|
|
3521
3516
|
if ("" === this.videoType.trim()) this.videoType = FALLBACK_VIDEO_TYPE;
|
|
3522
3517
|
return this.videoType;
|
|
3523
3518
|
}
|
|
@@ -7308,10 +7303,10 @@ class Replay extends util_Despot {
|
|
|
7308
7303
|
}
|
|
7309
7304
|
}
|
|
7310
7305
|
setMp4Source(src, bustCache) {
|
|
7311
|
-
this.setVideoSource(
|
|
7306
|
+
this.setVideoSource("mp4", src, bustCache);
|
|
7312
7307
|
}
|
|
7313
7308
|
setWebMSource(src, bustCache) {
|
|
7314
|
-
this.setVideoSource(
|
|
7309
|
+
this.setVideoSource("webm", src, bustCache);
|
|
7315
7310
|
}
|
|
7316
7311
|
getVideoType() {
|
|
7317
7312
|
if (!this.replayElement) return;
|
|
@@ -8199,4 +8194,4 @@ class VideomailClient extends util_Despot {
|
|
|
8199
8194
|
}
|
|
8200
8195
|
}
|
|
8201
8196
|
const client = VideomailClient;
|
|
8202
|
-
export {
|
|
8197
|
+
export { client as VideomailClient };
|
package/dist/esm/resource.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import Response from "superagent/lib/node/response";
|
|
2
2
|
import { VideomailClientOptions } from "./types/options";
|
|
3
|
-
import
|
|
3
|
+
import type { PartialVideomail, Videomail } from "./types/Videomail";
|
|
4
4
|
import VideomailError from "./util/error/VideomailError";
|
|
5
5
|
import { FormInputs } from "./wrappers/form";
|
|
6
6
|
declare class Resource {
|
|
@@ -53,5 +53,5 @@ interface Videomail {
|
|
|
53
53
|
rejectedCc?: DeliveryRecord;
|
|
54
54
|
rejectedBcc?: DeliveryRecord;
|
|
55
55
|
}
|
|
56
|
-
|
|
57
|
-
export
|
|
56
|
+
type PartialVideomail = PartialDeep<Videomail>;
|
|
57
|
+
export type { PartialVideomail, Videomail };
|
|
@@ -2,7 +2,7 @@ import Response from "superagent/lib/node/response";
|
|
|
2
2
|
import VideomailError from "../../util/error/VideomailError";
|
|
3
3
|
import { FormReadyParams } from "../../wrappers/container";
|
|
4
4
|
import RecordingStats from "../RecordingStats";
|
|
5
|
-
import Videomail from "../Videomail";
|
|
5
|
+
import type { Videomail } from "../Videomail";
|
|
6
6
|
export interface UserMediaReadyParams {
|
|
7
7
|
switchingFacingMode?: ConstrainDOMString | undefined;
|
|
8
8
|
recordWhenReady?: boolean | undefined;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./../styles/main.styl";
|
|
2
2
|
import { ShowParams, StartOverParams } from "../client";
|
|
3
3
|
import { VideomailClientOptions } from "../types/options";
|
|
4
|
-
import Videomail from "../types/Videomail";
|
|
4
|
+
import type { Videomail } from "../types/Videomail";
|
|
5
5
|
import Despot from "../util/Despot";
|
|
6
6
|
import { FormInputs, FormMethod } from "./form";
|
|
7
7
|
interface BuildOptions {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { VideomailClientOptions } from "../types/options";
|
|
2
|
-
import Videomail from "../types/Videomail";
|
|
2
|
+
import type { Videomail } from "../types/Videomail";
|
|
3
3
|
import Despot from "../util/Despot";
|
|
4
4
|
import Container from "./container";
|
|
5
5
|
export type FormInputs = Record<string, string>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { VideomailClientOptions } from "../../types/options";
|
|
2
|
-
import Videomail from "../../types/Videomail";
|
|
2
|
+
import type { Videomail } from "../../types/Videomail";
|
|
3
3
|
import { VideoType } from "../../types/VideoType";
|
|
4
4
|
import Despot from "../../util/Despot";
|
|
5
5
|
import { UnloadParams } from "../container";
|
package/dist/umd/index.js
CHANGED
|
@@ -10330,8 +10330,7 @@
|
|
|
10330
10330
|
"use strict";
|
|
10331
10331
|
__webpack_require__.r(__webpack_exports__);
|
|
10332
10332
|
__webpack_require__.d(__webpack_exports__, {
|
|
10333
|
-
VideomailClient: ()=>src_client
|
|
10334
|
-
VideoType: ()=>VideoType_VideoType
|
|
10333
|
+
VideomailClient: ()=>src_client
|
|
10335
10334
|
});
|
|
10336
10335
|
const constants = {
|
|
10337
10336
|
SITE_NAME_LABEL: "x-videomail-site-name",
|
|
@@ -10494,7 +10493,7 @@
|
|
|
10494
10493
|
var client = __webpack_require__("./node_modules/superagent/lib/client.js");
|
|
10495
10494
|
var client_default = /*#__PURE__*/ __webpack_require__.n(client);
|
|
10496
10495
|
var package_namespaceObject = {
|
|
10497
|
-
rE: "11.1.
|
|
10496
|
+
rE: "11.1.1"
|
|
10498
10497
|
};
|
|
10499
10498
|
var defined = __webpack_require__("./node_modules/defined/index.js");
|
|
10500
10499
|
var defined_default = /*#__PURE__*/ __webpack_require__.n(defined);
|
|
@@ -13636,7 +13635,7 @@
|
|
|
13636
13635
|
return canPlayType;
|
|
13637
13636
|
}
|
|
13638
13637
|
const media_canPlayType = canPlayType_canPlayType;
|
|
13639
|
-
const FALLBACK_VIDEO_TYPE =
|
|
13638
|
+
const FALLBACK_VIDEO_TYPE = "mp4";
|
|
13640
13639
|
class Browser {
|
|
13641
13640
|
options;
|
|
13642
13641
|
result;
|
|
@@ -13683,10 +13682,10 @@
|
|
|
13683
13682
|
}
|
|
13684
13683
|
getVideoType(video) {
|
|
13685
13684
|
if (!this.videoType) {
|
|
13686
|
-
if (media_canPlayType(video,
|
|
13687
|
-
else if (media_canPlayType(video,
|
|
13685
|
+
if (media_canPlayType(video, "mp4")) this.videoType = "mp4";
|
|
13686
|
+
else if (media_canPlayType(video, "webm")) this.videoType = "webm";
|
|
13688
13687
|
}
|
|
13689
|
-
if (
|
|
13688
|
+
if ("webm" !== this.videoType && "mp4" !== this.videoType) this.videoType = FALLBACK_VIDEO_TYPE;
|
|
13690
13689
|
if ("" === this.videoType.trim()) this.videoType = FALLBACK_VIDEO_TYPE;
|
|
13691
13690
|
return this.videoType;
|
|
13692
13691
|
}
|
|
@@ -17670,10 +17669,10 @@
|
|
|
17670
17669
|
}
|
|
17671
17670
|
}
|
|
17672
17671
|
setMp4Source(src, bustCache) {
|
|
17673
|
-
this.setVideoSource(
|
|
17672
|
+
this.setVideoSource("mp4", src, bustCache);
|
|
17674
17673
|
}
|
|
17675
17674
|
setWebMSource(src, bustCache) {
|
|
17676
|
-
this.setVideoSource(
|
|
17675
|
+
this.setVideoSource("webm", src, bustCache);
|
|
17677
17676
|
}
|
|
17678
17677
|
getVideoType() {
|
|
17679
17678
|
if (!this.replayElement) return;
|
|
@@ -18561,11 +18560,6 @@
|
|
|
18561
18560
|
}
|
|
18562
18561
|
}
|
|
18563
18562
|
const src_client = VideomailClient;
|
|
18564
|
-
var VideoType_VideoType = /*#__PURE__*/ function(VideoType1) {
|
|
18565
|
-
VideoType1["WebM"] = "webm";
|
|
18566
|
-
VideoType1["MP4"] = "mp4";
|
|
18567
|
-
return VideoType1;
|
|
18568
|
-
}({});
|
|
18569
18563
|
})();
|
|
18570
18564
|
return __webpack_exports__;
|
|
18571
18565
|
})());
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "videomail-client",
|
|
3
|
-
"version": "11.1.
|
|
3
|
+
"version": "11.1.1",
|
|
4
4
|
"description": "A wicked npm package to record videos directly in the browser, wohooo!",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"webcam",
|
|
@@ -79,11 +79,11 @@
|
|
|
79
79
|
"@rsbuild/plugin-node-polyfill": "1.4.2",
|
|
80
80
|
"@rsbuild/plugin-stylus": "1.2.0",
|
|
81
81
|
"@rsdoctor/rspack-plugin": "1.2.3",
|
|
82
|
-
"@rslib/core": "0.
|
|
83
|
-
"@storybook/addon-a11y": "9.1.
|
|
84
|
-
"@storybook/addon-docs": "9.1.
|
|
85
|
-
"@storybook/addon-links": "9.1.
|
|
86
|
-
"@storybook/html": "9.1.
|
|
82
|
+
"@rslib/core": "0.13.3",
|
|
83
|
+
"@storybook/addon-a11y": "9.1.8",
|
|
84
|
+
"@storybook/addon-docs": "9.1.8",
|
|
85
|
+
"@storybook/addon-links": "9.1.8",
|
|
86
|
+
"@storybook/html": "9.1.8",
|
|
87
87
|
"@tsconfig/node22": "22.0.2",
|
|
88
88
|
"@tsconfig/strictest": "2.0.6",
|
|
89
89
|
"@types/defined": "1.0.2",
|
|
@@ -104,7 +104,7 @@
|
|
|
104
104
|
"eslint-plugin-regexp": "2.10.0",
|
|
105
105
|
"eslint-plugin-security": "3.0.1",
|
|
106
106
|
"eslint-plugin-simple-import-sort": "12.1.1",
|
|
107
|
-
"eslint-plugin-storybook": "9.1.
|
|
107
|
+
"eslint-plugin-storybook": "9.1.8",
|
|
108
108
|
"globals": "16.4.0",
|
|
109
109
|
"jsdom": "27.0.0",
|
|
110
110
|
"msw": "2.11.1",
|
|
@@ -114,7 +114,7 @@
|
|
|
114
114
|
"prettier-plugin-packagejson": "2.5.19",
|
|
115
115
|
"prettier-plugin-sh": "0.18.0",
|
|
116
116
|
"release-it": "19.0.5",
|
|
117
|
-
"storybook": "9.1.
|
|
117
|
+
"storybook": "9.1.8",
|
|
118
118
|
"storybook-html-rsbuild": "2.0.4",
|
|
119
119
|
"type-fest": "5.0.1",
|
|
120
120
|
"typescript": "5.9.2",
|