videomail-client 4.0.0 → 5.0.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/TODO.md +3 -3
- package/package.json +1 -1
- package/prototype/js/videomail-client.js +43 -7
- package/prototype/js/videomail-client.min.js +1 -1
- package/prototype/js/videomail-client.min.js.map +1 -1
- package/src/js/util/browser.js +39 -1
- package/src/js/wrappers/visuals/recorder.js +2 -1
- package/src/js/wrappers/visuals/replay.js +0 -2
package/TODO.md
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
### TODOs
|
|
2
2
|
| Filename | line # | TODO
|
|
3
3
|
|:------|:------:|:------
|
|
4
|
-
| src/js/wrappers/container.js | 324 | figure out how to fire dom's onload event again
|
|
5
|
-
| src/js/wrappers/container.js | 325 | or how to run all the scripts over again
|
|
6
|
-
| src/js/wrappers/optionsWrapper.js | 27 | fix this, it's not really an option
|
|
7
4
|
| src/js/util/audioRecorder.js | 11 | code needs rewrite
|
|
8
5
|
| src/js/util/eventEmitter.js | 6 | MAKE EVENT EMITTING IN DESPOT NOT GLOBAL BUT BY CONTAINER ID INSTEAD
|
|
9
6
|
| src/js/util/eventEmitter.js | 43 | have this emitted through a configuration because it is pretty noisy
|
|
10
7
|
| src/js/util/humanize.js | 4 | get rid of this class and use those imports directly
|
|
8
|
+
| src/js/wrappers/container.js | 324 | figure out how to fire dom's onload event again
|
|
9
|
+
| src/js/wrappers/container.js | 325 | or how to run all the scripts over again
|
|
10
|
+
| src/js/wrappers/optionsWrapper.js | 27 | fix this, it's not really an option
|
|
11
11
|
| src/js/wrappers/visuals/recorder.js | 582 | in https://github.com/binarykitchen/videomail-client/issues/142
|
|
12
12
|
| src/js/wrappers/visuals/recorder.js | 619 | retry with navigator.getUserMedia_() maybe?
|
|
13
13
|
| src/js/wrappers/visuals/recorder.js | 759 | commented out because for some reasons server does not accept such a long
|
package/package.json
CHANGED
|
@@ -25866,7 +25866,7 @@ function wrappy (fn, cb) {
|
|
|
25866
25866
|
},{}],343:[function(_dereq_,module,exports){
|
|
25867
25867
|
module.exports={
|
|
25868
25868
|
"name": "videomail-client",
|
|
25869
|
-
"version": "
|
|
25869
|
+
"version": "5.0.0",
|
|
25870
25870
|
"description": "A wicked npm package to record videos directly in the browser, wohooo!",
|
|
25871
25871
|
"author": "Michael Heuberger <michael.heuberger@binarykitchen.com>",
|
|
25872
25872
|
"contributors": [
|
|
@@ -26993,6 +26993,7 @@ var Browser = function Browser(options) {
|
|
|
26993
26993
|
var isHTTPS = options.fakeHttps || window.location.protocol === 'https:';
|
|
26994
26994
|
var okBrowser = chromeBased || firefox || isAndroid || isOpera || isEdge || isOkSafari || isOkIOS;
|
|
26995
26995
|
var self = this;
|
|
26996
|
+
var videoType;
|
|
26996
26997
|
|
|
26997
26998
|
function getRecommendation() {
|
|
26998
26999
|
var warning;
|
|
@@ -27044,8 +27045,7 @@ var Browser = function Browser(options) {
|
|
|
27044
27045
|
}
|
|
27045
27046
|
|
|
27046
27047
|
return warning;
|
|
27047
|
-
}
|
|
27048
|
-
|
|
27048
|
+
}
|
|
27049
27049
|
|
|
27050
27050
|
this.canRecord = function () {
|
|
27051
27051
|
var hasNavigator = typeof navigator !== 'undefined';
|
|
@@ -27129,6 +27129,43 @@ var Browser = function Browser(options) {
|
|
|
27129
27129
|
return err;
|
|
27130
27130
|
};
|
|
27131
27131
|
|
|
27132
|
+
function canPlayType(video, type) {
|
|
27133
|
+
var canPlayType;
|
|
27134
|
+
|
|
27135
|
+
if (video && video.canPlayType) {
|
|
27136
|
+
canPlayType = video.canPlayType('video/' + type);
|
|
27137
|
+
} // definitely cannot be played here
|
|
27138
|
+
|
|
27139
|
+
|
|
27140
|
+
if (canPlayType === '') {
|
|
27141
|
+
return false;
|
|
27142
|
+
}
|
|
27143
|
+
|
|
27144
|
+
return canPlayType;
|
|
27145
|
+
}
|
|
27146
|
+
|
|
27147
|
+
this.getVideoType = function (video) {
|
|
27148
|
+
if (!video) {
|
|
27149
|
+
// no type without video
|
|
27150
|
+
return;
|
|
27151
|
+
}
|
|
27152
|
+
|
|
27153
|
+
if (!videoType) {
|
|
27154
|
+
if (canPlayType(video, 'webm')) {
|
|
27155
|
+
videoType = 'webm';
|
|
27156
|
+
} else if (canPlayType(video, 'mp4')) {
|
|
27157
|
+
videoType = 'mp4';
|
|
27158
|
+
}
|
|
27159
|
+
}
|
|
27160
|
+
|
|
27161
|
+
if (!videoType || videoType === '') {
|
|
27162
|
+
// just as a fallback
|
|
27163
|
+
videoType = 'webm';
|
|
27164
|
+
}
|
|
27165
|
+
|
|
27166
|
+
return videoType;
|
|
27167
|
+
};
|
|
27168
|
+
|
|
27132
27169
|
this.getNoAccessIssue = function () {
|
|
27133
27170
|
var message = 'Unable to access webcam';
|
|
27134
27171
|
var explanation;
|
|
@@ -31843,7 +31880,8 @@ var Recorder = function Recorder(visuals, replay) {
|
|
|
31843
31880
|
avgInterval: getAvgInterval(),
|
|
31844
31881
|
wantedInterval: 1e3 / options.video.fps,
|
|
31845
31882
|
intervalSum: getIntervalSum(),
|
|
31846
|
-
framesCount: framesCount
|
|
31883
|
+
framesCount: framesCount,
|
|
31884
|
+
videoType: replay.getVideoType()
|
|
31847
31885
|
};
|
|
31848
31886
|
|
|
31849
31887
|
if (options.isAudioEnabled()) {
|
|
@@ -32427,9 +32465,7 @@ var Replay = function Replay(parentElement, options) {
|
|
|
32427
32465
|
if (videomail) {
|
|
32428
32466
|
if (videomail.webm) {
|
|
32429
32467
|
this.setWebMSource(videomail.webm);
|
|
32430
|
-
}
|
|
32431
|
-
// for compatibility and documentation
|
|
32432
|
-
|
|
32468
|
+
}
|
|
32433
32469
|
|
|
32434
32470
|
if (videomail.mp4) {
|
|
32435
32471
|
this.setMp4Source(videomail.mp4);
|