native-fn 1.0.43 → 1.0.45

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.
Files changed (44) hide show
  1. package/dist/native.cjs +28 -24
  2. package/dist/native.min.cjs +1 -1
  3. package/dist/native.min.mjs +1 -1
  4. package/dist/native.mjs +28 -24
  5. package/dist/native.umd.js +28 -24
  6. package/dist/native.umd.min.js +1 -1
  7. package/dist/plugin/app/index.cjs +77 -76
  8. package/dist/plugin/app/index.d.ts +5 -1
  9. package/dist/plugin/app/index.min.cjs +1 -1
  10. package/dist/plugin/app/index.min.mjs +1 -1
  11. package/dist/plugin/app/index.mjs +77 -76
  12. package/dist/plugin/app/index.umd.js +77 -76
  13. package/dist/plugin/app/index.umd.min.js +1 -1
  14. package/dist/plugin/app/src/plugin/app/types/app.d.ts +4 -0
  15. package/dist/plugin/app/src/utils/require.d.ts +1 -0
  16. package/dist/plugin/camera/index.cjs +27 -23
  17. package/dist/plugin/camera/index.min.cjs +1 -1
  18. package/dist/plugin/camera/index.min.mjs +1 -1
  19. package/dist/plugin/camera/index.mjs +27 -23
  20. package/dist/plugin/camera/index.umd.js +27 -23
  21. package/dist/plugin/camera/index.umd.min.js +1 -1
  22. package/dist/plugin/camera/src/plugin/app/types/app.d.ts +4 -0
  23. package/dist/plugin/camera/src/utils/require.d.ts +1 -0
  24. package/dist/plugin/clipboard/src/plugin/app/types/app.d.ts +4 -0
  25. package/dist/plugin/clipboard/src/utils/require.d.ts +1 -0
  26. package/dist/plugin/fullscreen/index.cjs +27 -23
  27. package/dist/plugin/fullscreen/index.min.cjs +1 -1
  28. package/dist/plugin/fullscreen/index.min.mjs +1 -1
  29. package/dist/plugin/fullscreen/index.mjs +27 -23
  30. package/dist/plugin/fullscreen/index.umd.js +27 -23
  31. package/dist/plugin/fullscreen/index.umd.min.js +1 -1
  32. package/dist/plugin/fullscreen/src/plugin/app/types/app.d.ts +4 -0
  33. package/dist/plugin/fullscreen/src/utils/require.d.ts +1 -0
  34. package/dist/plugin/theme/index.cjs +27 -23
  35. package/dist/plugin/theme/index.min.cjs +1 -1
  36. package/dist/plugin/theme/index.min.mjs +1 -1
  37. package/dist/plugin/theme/index.mjs +27 -23
  38. package/dist/plugin/theme/index.umd.js +27 -23
  39. package/dist/plugin/theme/index.umd.min.js +1 -1
  40. package/dist/plugin/theme/src/plugin/app/types/app.d.ts +4 -0
  41. package/dist/plugin/theme/src/utils/require.d.ts +1 -0
  42. package/dist/src/plugin/app/types/app.d.ts +4 -0
  43. package/dist/src/utils/require.d.ts +1 -0
  44. package/package.json +1 -1
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- function dynamicImport(moduleName) {
3
+ function require$1(moduleName) {
4
4
  if ('require' in globalThis && typeof globalThis.require === 'function') {
5
5
  try {
6
6
  return Promise.resolve(globalThis.require(moduleName));
@@ -9,13 +9,7 @@ function dynamicImport(moduleName) {
9
9
  return Promise.resolve(null);
10
10
  }
11
11
  }
12
- return import(moduleName)
13
- .then(function (module) {
14
- return (module.default || module);
15
- })
16
- .catch(function () {
17
- return Promise.resolve(null);
18
- });
12
+ return Promise.resolve(null);
19
13
  }
20
14
 
21
15
  var OS;
@@ -255,8 +249,18 @@ for (var i = 0; i < BROWSER_RESOLVER_MAP.length; i++) {
255
249
  break;
256
250
  }
257
251
  }
258
- if (Platform.isNodeJS) {
259
- dynamicImport('os')
252
+ if (typeof navigator !== 'undefined' && navigator.product === 'ReactNative') {
253
+ try {
254
+ import('react-native')
255
+ .then(function (reactNative) {
256
+ console.log(reactNative.Platform);
257
+ });
258
+ }
259
+ catch (_) {
260
+ }
261
+ }
262
+ else if (Platform.isNodeJS) {
263
+ require$1('os')
260
264
  .then(function (os) {
261
265
  if (os === null)
262
266
  return;
@@ -296,31 +300,31 @@ if (Platform.isNodeJS) {
296
300
  case 'darwin':
297
301
  Platform.os = OS.MacOS;
298
302
  if (version.major >= 24)
299
- Platform.osVersion = '' + (version.major - 9);
303
+ Platform.osVersion = '' + (version.major - 9) + '.' + version.minor + '.' + version.build;
300
304
  else if (version.major === 23)
301
- Platform.osVersion = '14';
305
+ Platform.osVersion = '14.' + version.minor + '.' + version.build;
302
306
  else if (version.major === 22)
303
- Platform.osVersion = '13';
307
+ Platform.osVersion = '13.' + version.minor + '.' + version.build;
304
308
  else if (version.major === 21)
305
- Platform.osVersion = '12';
309
+ Platform.osVersion = '12.' + version.minor + '.' + version.build;
306
310
  else if (version.major === 20)
307
- Platform.osVersion = '11';
311
+ Platform.osVersion = '11.' + version.minor + '.' + version.build;
308
312
  else if (version.major === 19)
309
- Platform.osVersion = '10.15';
313
+ Platform.osVersion = '10.15.' + version.minor;
310
314
  else if (version.major === 18)
311
- Platform.osVersion = '10.14';
315
+ Platform.osVersion = '10.14.' + version.minor;
312
316
  else if (version.major === 17)
313
- Platform.osVersion = '10.13';
317
+ Platform.osVersion = '10.13.' + version.minor;
314
318
  else if (version.major === 16)
315
- Platform.osVersion = '10.12';
319
+ Platform.osVersion = '10.12.' + version.minor;
316
320
  else if (version.major === 15)
317
- Platform.osVersion = '10.11';
321
+ Platform.osVersion = '10.11.' + version.minor;
318
322
  else if (version.major === 14)
319
- Platform.osVersion = '10.10';
323
+ Platform.osVersion = '10.10.' + version.minor;
320
324
  else if (version.major === 13)
321
- Platform.osVersion = '10.9';
325
+ Platform.osVersion = '10.9.' + version.minor;
322
326
  else if (version.major >= 5 && version.major <= 12)
323
- Platform.osVersion = '10.' + (version.major - 4);
327
+ Platform.osVersion = '10.' + (version.major - 4) + '.' + version.minor;
324
328
  else
325
329
  Platform.osVersion = release;
326
330
  break;
@@ -1 +1 @@
1
- "use strict";var e,i,o,n;!function(e){e.Unknown="Unknown",e.Android="Android",e.iOS="iOS",e.Windows="Windows",e.MacOS="MacOS"}(e||(e={})),function(e){e.Unknown="Unknown",e.Mobile="Mobile",e.Desktop="Desktop"}(i||(i={})),function(e){e.Unknown="Unknown",e.EdgeHTML="EdgeHTML",e.ArkWeb="ArkWeb",e.Blink="Blink",e.Presto="Presto",e.WebKit="WebKit",e.Trident="Trident",e.NetFront="NetFront",e.KHTML="KHTML",e.Tasman="Tasman",e.Gecko="Gecko"}(o||(o={})),function(e){e.Unknown="Unknown",e.Chrome="Chrome",e.Safari="Safari",e.Edge="Edge",e.Firefox="Firefox",e.Opera="Opera",e.IE="IE",e.SamsungInternet="SamsungInternet"}(n||(n={}));var r={device:i.Unknown,os:e.Unknown,osVersion:"",engine:o.Unknown,engineVersion:"",browser:n.Unknown,browserVersion:"",renderer:function(){if(void 0===globalThis.document)return"";var e=globalThis.document.createElement("canvas");if("function"!=typeof e.getContext)return"";var i=e.getContext("webgl2")||e.getContext("experimental-webgl")||e.getContext("webgl");if(null===i)return"";if(i instanceof WebGLRenderingContext||"getParameter"in i&&"function"==typeof i.getParameter){var o=i.getExtension("WEBGL_debug_renderer_info");return null===o?i.getParameter(i.RENDERER):i.getParameter(o.UNMASKED_RENDERER_WEBGL)}return""}(),userAgent:navigator.userAgent,isWebview:!1,isMobile:!1,isDesktop:!1,isStandalone:!1,isNodeJS:void 0!==globalThis.process&&void 0!==globalThis.process.versions&&void 0!==globalThis.process.versions.node},t=[[/windows nt (6\.[23]); arm/i,e.Windows,l],[/windows (?:phone|mobile|iot)(?: os)?[\/ ]?([\d.]*( se)?)/i,e.Windows,l],[/windows[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i,e.Windows,l],[/windows nt ?([\d.)]*)(?!.+xbox)/i,e.Windows,l],[/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d.;]*)/i,e.Windows,l],[/windows ce\/?([\d.]*)/i,e.Windows,l],[/[adehimnop]{4,7}\b(?:.*os (\w+) like mac|; opera)/i,e.iOS,d],[/(?:ios;fbsv|ios(?=.+ip(?:ad|hone))|ip(?:ad|hone)(?: |.+i(?:pad)?)os)[\/ ]([\w.]+)/i,e.iOS,d],[/cfnetwork\/.+darwin/i,e.iOS,d],[/mac os x ?([\w. ]*)/i,e.MacOS,d],[/(?:macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i,e.MacOS,d],[/droid ([\w.]+)\b.+(android[- ]x86)/i,e.Android],[/android\w*[-\/.; ]?([\d.]*)/i,e.Android]],a=[[/windows.+ edge\/([\w.]+)/i,o.EdgeHTML],[/arkweb\/([\w.]+)/i,o.ArkWeb],[/webkit\/537\.36.+chrome\/(?!27)([\w.]+)/i,o.Blink],[/presto\/([\w.]+)/i,o.Presto],[/webkit\/([\w.]+)/i,o.WebKit],[/trident\/([\w.]+)/i,o.Trident],[/netfront\/([\w.]+)/i,o.NetFront],[/khtml[\/ ]\(?([\w.]+)/i,o.KHTML],[/tasman[\/ ]\(?([\w.]+)/i,o.Tasman],[/rv:([\w.]{1,9})\b.+gecko/i,o.Gecko]],s=[[/\b(?:crmo|crios)\/([\w.]+)/i,n.Chrome],[/webview.+edge\/([\w.]+)/i,n.Edge],[/edg(?:e|ios|a)?\/([\w.]+)/i,n.Edge],[/opera mini\/([-\w.]+)/i,n.Opera],[/opera [mobileta]{3,6}\b.+version\/([-\w.]+)/i,n.Opera],[/opera(?:.+version\/|[\/ ]+)([\w.]+)/i,n.Opera],[/opios[\/ ]+([\w.]+)/i,n.Opera],[/\bop(?:rg)?x\/([\w.]+)/i,n.Opera],[/\bopr\/([\w.]+)/i,n.Opera],[/iemobile(?:browser|boat|jet)[\/ ]?([\d.]*)/i,n.IE],[/(?:ms|\()ie ([\w.]+)/i,n.IE],[/trident.+rv[: ]([\w.]{1,9})\b.+like gecko/i,n.IE],[/\bfocus\/([\w.]+)/i,n.Firefox],[/\bopt\/([\w.]+)/i,n.Opera],[/coast\/([\w.]+)/i,n.Opera],[/fxios\/([\w.-]+)/i,n.Firefox],[/samsungbrowser\/([\w.]+)/i,n.SamsungInternet],[/headlesschrome(?:\/([\w.]+)| )/i,n.Chrome],[/wv\).+chrome\/([\w.]+).+edgw\//i,n.Edge],[/ wv\).+(chrome)\/([\w.]+)/i,n.Chrome],[/chrome\/([\w.]+) mobile/i,n.Chrome],[/chrome\/v?([\w.]+)/i,n.Chrome],[/version\/([\w.,]+) .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/iphone .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/version\/([\w.,]+) .*safari/i,n.Safari],[/webkit.+?(?:mobile ?safari|safari)(\/[\w.]+)/i,n.Safari,"1"],[/(?:mobile|tablet);.*firefox\/([\w.-]+)/i,n.Firefox],[/mobile vr; rv:([\w.]+)\).+firefox/i,n.Firefox],[/firefox\/([\w.]+)/i,n.Firefox]];function l(e){if(void 0===e)return"";var i={"4.90":"ME","NT3.51":"NT 3.11","NT4.0":"NT 4.0","NT 5.0":"2000","NT 5.1":"XP","NT 5.2":"XP","NT 6.0":"Vista","NT 6.1":"7","NT 6.2":"8","NT 6.3":"8.1","NT 6.4":"10","NT 10.0":"10",ARM:"RT"}[e];return void 0!==i?i:e}function d(e){return void 0===e?"":e.replace(/_/g,".")}function c(e,i){return"function"==typeof i?i(e):"string"==typeof i?i:void 0===e?"":e}for(var m=0;m<t.length;m++){var w=(f=t[m])[0],u=f[1],p=f[2];if(null!==(g=r.userAgent.match(w))){r.os=u,r.osVersion=c(g[1],p),u===e.iOS||u===e.Android?r.device=i.Mobile:u!==e.Windows&&u!==e.MacOS||(r.device=i.Desktop);break}}for(m=0;m<a.length;m++){w=(f=a[m])[0];var b=f[1];p=f[2];if(null!==(g=r.userAgent.match(w))){r.engine=b,r.engineVersion=c(g[1],p);break}}for(m=0;m<s.length;m++){w=(f=s[m])[0];var f,g,h=f[1];p=f[2];if(null!==(g=r.userAgent.match(w))){r.browser=h,r.browserVersion=c(g[1],p);break}}function v(i){var o,n=function(){try{if(globalThis.top&&globalThis.top!==window)return globalThis.top.location.href,globalThis.top}catch(e){}return window}(),t=n.document;try{if(void 0===(o=function(e,i){if(void 0===i&&(i=!0),void 0!==globalThis.document){var o=globalThis.document.createElement(e);return"width"in o&&(o.width="0"),"height"in o&&(o.height="0"),"border"in o&&(o.border="0"),"frameBorder"in o&&(o.frameBorder="0"),"scrolling"in o&&(o.scrolling="no"),"cellPadding"in o&&(o.cellPadding="0"),"cellSpacing"in o&&(o.cellSpacing="0"),"frame"in o&&(o.frame="void"),"rules"in o&&(o.rules="none"),"noWrap"in o&&(o.noWrap=!0),o.tabIndex=-1,o.setAttribute("role","presentation"),i?(o.style.width="1px",o.style.height="1px"):(o.setAttribute("aria-hidden","true"),o.style.width="0",o.style.height="0",o.style.zIndex="-9999",o.style.display="none",o.style.visibility="hidden",o.style.pointerEvents="none"),o.style.position="absolute",o.style.top="0",o.style.left="0",o.style.padding="0",o.style.margin="0",o.style.border="none",o.style.outline="none",o.style.clip="rect(1px, 1px, 1px, 1px)",o.style.clipPath="inset(50%)",o.style.overflow="hidden",o.style.whiteSpace="nowrap",o}}("input")))return;if(o.type="file",o.tabIndex=-1,o.accept=i+"/*","capture"in HTMLInputElement.prototype)o.capture="user";else if(r.os===e.Android){var a="";"image"===i?a="camera":"video"===i&&(a="camcorder"),o.accept=i+"/*;capture="+a}t.body.appendChild(o),function(e,i){var o;void 0===i&&(i=window);try{o=new MouseEvent("click",{bubbles:!0,cancelable:!0,view:i})}catch(e){(o=globalThis.document.createEvent("MouseEvents")).initMouseEvent("click",!0,!0,i,0,0,0,0,0,!1,!1,!1,!1,0,null)}e.dispatchEvent(o)}(o,n)}catch(e){}}r.isNodeJS&&function(e){if("require"in globalThis&&"function"==typeof globalThis.require)try{return Promise.resolve(globalThis.require(e))}catch(e){return Promise.resolve(null)}return import(e).then((function(e){return e.default||e})).catch((function(){return Promise.resolve(null)}))}("os").then((function(i){if(null!==i){var o,n=i.platform(),t=i.release(),a=(o=t.split("."),{major:parseInt(o[0]||"0"),minor:parseInt(o[1]||"0"),build:parseInt(o[2]||"0")});switch(n){case"win32":r.os=e.Windows,r.osVersion=10===a.major&&0===a.minor&&a.build>=22e3?"11":10===a.major&&0===a.minor&&a.build<22e3?"10":6===a.major&&3===a.minor?"8.1":6===a.major&&2===a.minor?"8":6===a.major&&1===a.minor?"7":6===a.major&&0===a.minor?"Vista":5===a.major&&1===a.minor||5===a.major&&2===a.minor?"XP":5===a.major&&0===a.minor?"2000":4===a.major&&90===a.minor?"ME":4===a.major&&0===a.minor?"NT 4.0":3===a.major&&51===a.minor?"NT 3.11":t;break;case"darwin":r.os=e.MacOS,r.osVersion=a.major>=24?""+(a.major-9):23===a.major?"14":22===a.major?"13":21===a.major?"12":20===a.major?"11":19===a.major?"10.15":18===a.major?"10.14":17===a.major?"10.13":16===a.major?"10.12":15===a.major?"10.11":14===a.major?"10.10":13===a.major?"10.9":a.major>=5&&a.major<=12?"10."+(a.major-4):t;break;case"android":r.os=e.Android,r.osVersion=t;break;case"linux":/android/i.test(t)&&(r.os=e.Android,r.osVersion=t)}}})),void 0!==navigator.userAgentData&&void 0!==navigator.userAgentData.getHighEntropyValues&&navigator.userAgentData.getHighEntropyValues(["brands","fullVersionList","mobile","model","platform","platformVersion","architecture","formFactors","bitness","uaFullVersion","wow64"]).then((function(i){for(var o,n=i.fullVersionList||i.brands||[],t=i.platformVersion,a=0;a<n.length;a++){var s=null==(o=n[a])?{brand:"",version:""}:"string"==typeof o?{brand:o,version:""}:{brand:o.brand,version:o.version},l=s.brand,d=s.version;/not.a.brand/i.test(l)||"Chromium"===l&&(r.engineVersion=d)}"string"==typeof t&&(r.os===e.Windows&&parseInt(t.replace(/[^\d.]/g,"").split(".")[0],10)>=13?r.osVersion="11":r.osVersion=t)})),r.isMobile=r.device===i.Mobile,r.isDesktop=r.device===i.Desktop,r.isWebview=/; ?wv|applewebkit(?!.*safari)/i.test(r.userAgent),r.isStandalone=function(i){return"matchMedia"in globalThis&&(i===e.iOS?"standalone"in navigator&&!!navigator.standalone:globalThis.matchMedia("(display-mode: standalone)").matches)}(r.os);var k,T={open:function(i){switch(r.os){case e.Android:v(i);break;case e.iOS:(function(e,i){for(var o=e.split("."),n=i.split("."),r=Math.max(o.length,n.length),t=0;t<r;t++){var a=void 0,s=void 0;if((a=t<o.length?parseInt(o[t],10):0)>(s=t<n.length?parseInt(n[t],10):0))return 1;if(a<s)return-1}return 0})(r.osVersion,"10.3")>=0?v(i):alert(r.osVersion);case e.Windows:case e.MacOS:}}};!function(e){e.Image="image",e.Video="video"}(k||(k={}));var y={installed:!1,name:"Camera",module:T,Constants:{CameraType:k},Errors:{}};module.exports=y;
1
+ "use strict";var e,i,o,n;!function(e){e.Unknown="Unknown",e.Android="Android",e.iOS="iOS",e.Windows="Windows",e.MacOS="MacOS"}(e||(e={})),function(e){e.Unknown="Unknown",e.Mobile="Mobile",e.Desktop="Desktop"}(i||(i={})),function(e){e.Unknown="Unknown",e.EdgeHTML="EdgeHTML",e.ArkWeb="ArkWeb",e.Blink="Blink",e.Presto="Presto",e.WebKit="WebKit",e.Trident="Trident",e.NetFront="NetFront",e.KHTML="KHTML",e.Tasman="Tasman",e.Gecko="Gecko"}(o||(o={})),function(e){e.Unknown="Unknown",e.Chrome="Chrome",e.Safari="Safari",e.Edge="Edge",e.Firefox="Firefox",e.Opera="Opera",e.IE="IE",e.SamsungInternet="SamsungInternet"}(n||(n={}));var r={device:i.Unknown,os:e.Unknown,osVersion:"",engine:o.Unknown,engineVersion:"",browser:n.Unknown,browserVersion:"",renderer:function(){if(void 0===globalThis.document)return"";var e=globalThis.document.createElement("canvas");if("function"!=typeof e.getContext)return"";var i=e.getContext("webgl2")||e.getContext("experimental-webgl")||e.getContext("webgl");if(null===i)return"";if(i instanceof WebGLRenderingContext||"getParameter"in i&&"function"==typeof i.getParameter){var o=i.getExtension("WEBGL_debug_renderer_info");return null===o?i.getParameter(i.RENDERER):i.getParameter(o.UNMASKED_RENDERER_WEBGL)}return""}(),userAgent:navigator.userAgent,isWebview:!1,isMobile:!1,isDesktop:!1,isStandalone:!1,isNodeJS:void 0!==globalThis.process&&void 0!==globalThis.process.versions&&void 0!==globalThis.process.versions.node},t=[[/windows nt (6\.[23]); arm/i,e.Windows,l],[/windows (?:phone|mobile|iot)(?: os)?[\/ ]?([\d.]*( se)?)/i,e.Windows,l],[/windows[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i,e.Windows,l],[/windows nt ?([\d.)]*)(?!.+xbox)/i,e.Windows,l],[/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d.;]*)/i,e.Windows,l],[/windows ce\/?([\d.]*)/i,e.Windows,l],[/[adehimnop]{4,7}\b(?:.*os (\w+) like mac|; opera)/i,e.iOS,d],[/(?:ios;fbsv|ios(?=.+ip(?:ad|hone))|ip(?:ad|hone)(?: |.+i(?:pad)?)os)[\/ ]([\w.]+)/i,e.iOS,d],[/cfnetwork\/.+darwin/i,e.iOS,d],[/mac os x ?([\w. ]*)/i,e.MacOS,d],[/(?:macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i,e.MacOS,d],[/droid ([\w.]+)\b.+(android[- ]x86)/i,e.Android],[/android\w*[-\/.; ]?([\d.]*)/i,e.Android]],a=[[/windows.+ edge\/([\w.]+)/i,o.EdgeHTML],[/arkweb\/([\w.]+)/i,o.ArkWeb],[/webkit\/537\.36.+chrome\/(?!27)([\w.]+)/i,o.Blink],[/presto\/([\w.]+)/i,o.Presto],[/webkit\/([\w.]+)/i,o.WebKit],[/trident\/([\w.]+)/i,o.Trident],[/netfront\/([\w.]+)/i,o.NetFront],[/khtml[\/ ]\(?([\w.]+)/i,o.KHTML],[/tasman[\/ ]\(?([\w.]+)/i,o.Tasman],[/rv:([\w.]{1,9})\b.+gecko/i,o.Gecko]],s=[[/\b(?:crmo|crios)\/([\w.]+)/i,n.Chrome],[/webview.+edge\/([\w.]+)/i,n.Edge],[/edg(?:e|ios|a)?\/([\w.]+)/i,n.Edge],[/opera mini\/([-\w.]+)/i,n.Opera],[/opera [mobileta]{3,6}\b.+version\/([-\w.]+)/i,n.Opera],[/opera(?:.+version\/|[\/ ]+)([\w.]+)/i,n.Opera],[/opios[\/ ]+([\w.]+)/i,n.Opera],[/\bop(?:rg)?x\/([\w.]+)/i,n.Opera],[/\bopr\/([\w.]+)/i,n.Opera],[/iemobile(?:browser|boat|jet)[\/ ]?([\d.]*)/i,n.IE],[/(?:ms|\()ie ([\w.]+)/i,n.IE],[/trident.+rv[: ]([\w.]{1,9})\b.+like gecko/i,n.IE],[/\bfocus\/([\w.]+)/i,n.Firefox],[/\bopt\/([\w.]+)/i,n.Opera],[/coast\/([\w.]+)/i,n.Opera],[/fxios\/([\w.-]+)/i,n.Firefox],[/samsungbrowser\/([\w.]+)/i,n.SamsungInternet],[/headlesschrome(?:\/([\w.]+)| )/i,n.Chrome],[/wv\).+chrome\/([\w.]+).+edgw\//i,n.Edge],[/ wv\).+(chrome)\/([\w.]+)/i,n.Chrome],[/chrome\/([\w.]+) mobile/i,n.Chrome],[/chrome\/v?([\w.]+)/i,n.Chrome],[/version\/([\w.,]+) .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/iphone .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/version\/([\w.,]+) .*safari/i,n.Safari],[/webkit.+?(?:mobile ?safari|safari)(\/[\w.]+)/i,n.Safari,"1"],[/(?:mobile|tablet);.*firefox\/([\w.-]+)/i,n.Firefox],[/mobile vr; rv:([\w.]+)\).+firefox/i,n.Firefox],[/firefox\/([\w.]+)/i,n.Firefox]];function l(e){if(void 0===e)return"";var i={"4.90":"ME","NT3.51":"NT 3.11","NT4.0":"NT 4.0","NT 5.0":"2000","NT 5.1":"XP","NT 5.2":"XP","NT 6.0":"Vista","NT 6.1":"7","NT 6.2":"8","NT 6.3":"8.1","NT 6.4":"10","NT 10.0":"10",ARM:"RT"}[e];return void 0!==i?i:e}function d(e){return void 0===e?"":e.replace(/_/g,".")}function m(e,i){return"function"==typeof i?i(e):"string"==typeof i?i:void 0===e?"":e}for(var c=0;c<t.length;c++){var w=(g=t[c])[0],u=g[1],b=g[2];if(null!==(f=r.userAgent.match(w))){r.os=u,r.osVersion=m(f[1],b),u===e.iOS||u===e.Android?r.device=i.Mobile:u!==e.Windows&&u!==e.MacOS||(r.device=i.Desktop);break}}for(c=0;c<a.length;c++){w=(g=a[c])[0];var p=g[1];b=g[2];if(null!==(f=r.userAgent.match(w))){r.engine=p,r.engineVersion=m(f[1],b);break}}for(c=0;c<s.length;c++){w=(g=s[c])[0];var g,f,v=g[1];b=g[2];if(null!==(f=r.userAgent.match(w))){r.browser=v,r.browserVersion=m(f[1],b);break}}if("undefined"!=typeof navigator&&"ReactNative"===navigator.product)try{import("react-native").then((function(e){console.log(e.Platform)}))}catch(e){}else r.isNodeJS&&function(e){if("require"in globalThis&&"function"==typeof globalThis.require)try{return Promise.resolve(globalThis.require(e))}catch(e){return Promise.resolve(null)}return Promise.resolve(null)}("os").then((function(i){if(null!==i){var o,n=i.platform(),t=i.release(),a=(o=t.split("."),{major:parseInt(o[0]||"0"),minor:parseInt(o[1]||"0"),build:parseInt(o[2]||"0")});switch(n){case"win32":r.os=e.Windows,r.osVersion=10===a.major&&0===a.minor&&a.build>=22e3?"11":10===a.major&&0===a.minor&&a.build<22e3?"10":6===a.major&&3===a.minor?"8.1":6===a.major&&2===a.minor?"8":6===a.major&&1===a.minor?"7":6===a.major&&0===a.minor?"Vista":5===a.major&&1===a.minor||5===a.major&&2===a.minor?"XP":5===a.major&&0===a.minor?"2000":4===a.major&&90===a.minor?"ME":4===a.major&&0===a.minor?"NT 4.0":3===a.major&&51===a.minor?"NT 3.11":t;break;case"darwin":r.os=e.MacOS,r.osVersion=a.major>=24?a.major-9+"."+a.minor+"."+a.build:23===a.major?"14."+a.minor+"."+a.build:22===a.major?"13."+a.minor+"."+a.build:21===a.major?"12."+a.minor+"."+a.build:20===a.major?"11."+a.minor+"."+a.build:19===a.major?"10.15."+a.minor:18===a.major?"10.14."+a.minor:17===a.major?"10.13."+a.minor:16===a.major?"10.12."+a.minor:15===a.major?"10.11."+a.minor:14===a.major?"10.10."+a.minor:13===a.major?"10.9."+a.minor:a.major>=5&&a.major<=12?"10."+(a.major-4)+"."+a.minor:t;break;case"android":r.os=e.Android,r.osVersion=t;break;case"linux":/android/i.test(t)&&(r.os=e.Android,r.osVersion=t)}}}));function h(i){var o,n=function(){try{if(globalThis.top&&globalThis.top!==window)return globalThis.top.location.href,globalThis.top}catch(e){}return window}(),t=n.document;try{if(void 0===(o=function(e,i){if(void 0===i&&(i=!0),void 0!==globalThis.document){var o=globalThis.document.createElement(e);return"width"in o&&(o.width="0"),"height"in o&&(o.height="0"),"border"in o&&(o.border="0"),"frameBorder"in o&&(o.frameBorder="0"),"scrolling"in o&&(o.scrolling="no"),"cellPadding"in o&&(o.cellPadding="0"),"cellSpacing"in o&&(o.cellSpacing="0"),"frame"in o&&(o.frame="void"),"rules"in o&&(o.rules="none"),"noWrap"in o&&(o.noWrap=!0),o.tabIndex=-1,o.setAttribute("role","presentation"),i?(o.style.width="1px",o.style.height="1px"):(o.setAttribute("aria-hidden","true"),o.style.width="0",o.style.height="0",o.style.zIndex="-9999",o.style.display="none",o.style.visibility="hidden",o.style.pointerEvents="none"),o.style.position="absolute",o.style.top="0",o.style.left="0",o.style.padding="0",o.style.margin="0",o.style.border="none",o.style.outline="none",o.style.clip="rect(1px, 1px, 1px, 1px)",o.style.clipPath="inset(50%)",o.style.overflow="hidden",o.style.whiteSpace="nowrap",o}}("input")))return;if(o.type="file",o.tabIndex=-1,o.accept=i+"/*","capture"in HTMLInputElement.prototype)o.capture="user";else if(r.os===e.Android){var a="";"image"===i?a="camera":"video"===i&&(a="camcorder"),o.accept=i+"/*;capture="+a}t.body.appendChild(o),function(e,i){var o;void 0===i&&(i=window);try{o=new MouseEvent("click",{bubbles:!0,cancelable:!0,view:i})}catch(e){(o=globalThis.document.createEvent("MouseEvents")).initMouseEvent("click",!0,!0,i,0,0,0,0,0,!1,!1,!1,!1,0,null)}e.dispatchEvent(o)}(o,n)}catch(e){}}void 0!==navigator.userAgentData&&void 0!==navigator.userAgentData.getHighEntropyValues&&navigator.userAgentData.getHighEntropyValues(["brands","fullVersionList","mobile","model","platform","platformVersion","architecture","formFactors","bitness","uaFullVersion","wow64"]).then((function(i){for(var o,n=i.fullVersionList||i.brands||[],t=i.platformVersion,a=0;a<n.length;a++){var s=null==(o=n[a])?{brand:"",version:""}:"string"==typeof o?{brand:o,version:""}:{brand:o.brand,version:o.version},l=s.brand,d=s.version;/not.a.brand/i.test(l)||"Chromium"===l&&(r.engineVersion=d)}"string"==typeof t&&(r.os===e.Windows&&parseInt(t.replace(/[^\d.]/g,"").split(".")[0],10)>=13?r.osVersion="11":r.osVersion=t)})),r.isMobile=r.device===i.Mobile,r.isDesktop=r.device===i.Desktop,r.isWebview=/; ?wv|applewebkit(?!.*safari)/i.test(r.userAgent),r.isStandalone=function(i){return"matchMedia"in globalThis&&(i===e.iOS?"standalone"in navigator&&!!navigator.standalone:globalThis.matchMedia("(display-mode: standalone)").matches)}(r.os);var k,T={open:function(i){switch(r.os){case e.Android:h(i);break;case e.iOS:(function(e,i){for(var o=e.split("."),n=i.split("."),r=Math.max(o.length,n.length),t=0;t<r;t++){var a=void 0,s=void 0;if((a=t<o.length?parseInt(o[t],10):0)>(s=t<n.length?parseInt(n[t],10):0))return 1;if(a<s)return-1}return 0})(r.osVersion,"10.3")>=0?h(i):alert(r.osVersion);case e.Windows:case e.MacOS:}}};!function(e){e.Image="image",e.Video="video"}(k||(k={}));var y={installed:!1,name:"Camera",module:T,Constants:{CameraType:k},Errors:{}};module.exports=y;
@@ -1 +1 @@
1
- var e,i,o,n;!function(e){e.Unknown="Unknown",e.Android="Android",e.iOS="iOS",e.Windows="Windows",e.MacOS="MacOS"}(e||(e={})),function(e){e.Unknown="Unknown",e.Mobile="Mobile",e.Desktop="Desktop"}(i||(i={})),function(e){e.Unknown="Unknown",e.EdgeHTML="EdgeHTML",e.ArkWeb="ArkWeb",e.Blink="Blink",e.Presto="Presto",e.WebKit="WebKit",e.Trident="Trident",e.NetFront="NetFront",e.KHTML="KHTML",e.Tasman="Tasman",e.Gecko="Gecko"}(o||(o={})),function(e){e.Unknown="Unknown",e.Chrome="Chrome",e.Safari="Safari",e.Edge="Edge",e.Firefox="Firefox",e.Opera="Opera",e.IE="IE",e.SamsungInternet="SamsungInternet"}(n||(n={}));var r={device:i.Unknown,os:e.Unknown,osVersion:"",engine:o.Unknown,engineVersion:"",browser:n.Unknown,browserVersion:"",renderer:function(){if(void 0===globalThis.document)return"";var e=globalThis.document.createElement("canvas");if("function"!=typeof e.getContext)return"";var i=e.getContext("webgl2")||e.getContext("experimental-webgl")||e.getContext("webgl");if(null===i)return"";if(i instanceof WebGLRenderingContext||"getParameter"in i&&"function"==typeof i.getParameter){var o=i.getExtension("WEBGL_debug_renderer_info");return null===o?i.getParameter(i.RENDERER):i.getParameter(o.UNMASKED_RENDERER_WEBGL)}return""}(),userAgent:navigator.userAgent,isWebview:!1,isMobile:!1,isDesktop:!1,isStandalone:!1,isNodeJS:void 0!==globalThis.process&&void 0!==globalThis.process.versions&&void 0!==globalThis.process.versions.node},t=[[/windows nt (6\.[23]); arm/i,e.Windows,l],[/windows (?:phone|mobile|iot)(?: os)?[\/ ]?([\d.]*( se)?)/i,e.Windows,l],[/windows[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i,e.Windows,l],[/windows nt ?([\d.)]*)(?!.+xbox)/i,e.Windows,l],[/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d.;]*)/i,e.Windows,l],[/windows ce\/?([\d.]*)/i,e.Windows,l],[/[adehimnop]{4,7}\b(?:.*os (\w+) like mac|; opera)/i,e.iOS,d],[/(?:ios;fbsv|ios(?=.+ip(?:ad|hone))|ip(?:ad|hone)(?: |.+i(?:pad)?)os)[\/ ]([\w.]+)/i,e.iOS,d],[/cfnetwork\/.+darwin/i,e.iOS,d],[/mac os x ?([\w. ]*)/i,e.MacOS,d],[/(?:macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i,e.MacOS,d],[/droid ([\w.]+)\b.+(android[- ]x86)/i,e.Android],[/android\w*[-\/.; ]?([\d.]*)/i,e.Android]],a=[[/windows.+ edge\/([\w.]+)/i,o.EdgeHTML],[/arkweb\/([\w.]+)/i,o.ArkWeb],[/webkit\/537\.36.+chrome\/(?!27)([\w.]+)/i,o.Blink],[/presto\/([\w.]+)/i,o.Presto],[/webkit\/([\w.]+)/i,o.WebKit],[/trident\/([\w.]+)/i,o.Trident],[/netfront\/([\w.]+)/i,o.NetFront],[/khtml[\/ ]\(?([\w.]+)/i,o.KHTML],[/tasman[\/ ]\(?([\w.]+)/i,o.Tasman],[/rv:([\w.]{1,9})\b.+gecko/i,o.Gecko]],s=[[/\b(?:crmo|crios)\/([\w.]+)/i,n.Chrome],[/webview.+edge\/([\w.]+)/i,n.Edge],[/edg(?:e|ios|a)?\/([\w.]+)/i,n.Edge],[/opera mini\/([-\w.]+)/i,n.Opera],[/opera [mobileta]{3,6}\b.+version\/([-\w.]+)/i,n.Opera],[/opera(?:.+version\/|[\/ ]+)([\w.]+)/i,n.Opera],[/opios[\/ ]+([\w.]+)/i,n.Opera],[/\bop(?:rg)?x\/([\w.]+)/i,n.Opera],[/\bopr\/([\w.]+)/i,n.Opera],[/iemobile(?:browser|boat|jet)[\/ ]?([\d.]*)/i,n.IE],[/(?:ms|\()ie ([\w.]+)/i,n.IE],[/trident.+rv[: ]([\w.]{1,9})\b.+like gecko/i,n.IE],[/\bfocus\/([\w.]+)/i,n.Firefox],[/\bopt\/([\w.]+)/i,n.Opera],[/coast\/([\w.]+)/i,n.Opera],[/fxios\/([\w.-]+)/i,n.Firefox],[/samsungbrowser\/([\w.]+)/i,n.SamsungInternet],[/headlesschrome(?:\/([\w.]+)| )/i,n.Chrome],[/wv\).+chrome\/([\w.]+).+edgw\//i,n.Edge],[/ wv\).+(chrome)\/([\w.]+)/i,n.Chrome],[/chrome\/([\w.]+) mobile/i,n.Chrome],[/chrome\/v?([\w.]+)/i,n.Chrome],[/version\/([\w.,]+) .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/iphone .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/version\/([\w.,]+) .*safari/i,n.Safari],[/webkit.+?(?:mobile ?safari|safari)(\/[\w.]+)/i,n.Safari,"1"],[/(?:mobile|tablet);.*firefox\/([\w.-]+)/i,n.Firefox],[/mobile vr; rv:([\w.]+)\).+firefox/i,n.Firefox],[/firefox\/([\w.]+)/i,n.Firefox]];function l(e){if(void 0===e)return"";var i={"4.90":"ME","NT3.51":"NT 3.11","NT4.0":"NT 4.0","NT 5.0":"2000","NT 5.1":"XP","NT 5.2":"XP","NT 6.0":"Vista","NT 6.1":"7","NT 6.2":"8","NT 6.3":"8.1","NT 6.4":"10","NT 10.0":"10",ARM:"RT"}[e];return void 0!==i?i:e}function d(e){return void 0===e?"":e.replace(/_/g,".")}function c(e,i){return"function"==typeof i?i(e):"string"==typeof i?i:void 0===e?"":e}for(var m=0;m<t.length;m++){var w=(f=t[m])[0],u=f[1],p=f[2];if(null!==(g=r.userAgent.match(w))){r.os=u,r.osVersion=c(g[1],p),u===e.iOS||u===e.Android?r.device=i.Mobile:u!==e.Windows&&u!==e.MacOS||(r.device=i.Desktop);break}}for(m=0;m<a.length;m++){w=(f=a[m])[0];var b=f[1];p=f[2];if(null!==(g=r.userAgent.match(w))){r.engine=b,r.engineVersion=c(g[1],p);break}}for(m=0;m<s.length;m++){w=(f=s[m])[0];var f,g,h=f[1];p=f[2];if(null!==(g=r.userAgent.match(w))){r.browser=h,r.browserVersion=c(g[1],p);break}}function v(i){var o,n=function(){try{if(globalThis.top&&globalThis.top!==window)return globalThis.top.location.href,globalThis.top}catch(e){}return window}(),t=n.document;try{if(void 0===(o=function(e,i){if(void 0===i&&(i=!0),void 0!==globalThis.document){var o=globalThis.document.createElement(e);return"width"in o&&(o.width="0"),"height"in o&&(o.height="0"),"border"in o&&(o.border="0"),"frameBorder"in o&&(o.frameBorder="0"),"scrolling"in o&&(o.scrolling="no"),"cellPadding"in o&&(o.cellPadding="0"),"cellSpacing"in o&&(o.cellSpacing="0"),"frame"in o&&(o.frame="void"),"rules"in o&&(o.rules="none"),"noWrap"in o&&(o.noWrap=!0),o.tabIndex=-1,o.setAttribute("role","presentation"),i?(o.style.width="1px",o.style.height="1px"):(o.setAttribute("aria-hidden","true"),o.style.width="0",o.style.height="0",o.style.zIndex="-9999",o.style.display="none",o.style.visibility="hidden",o.style.pointerEvents="none"),o.style.position="absolute",o.style.top="0",o.style.left="0",o.style.padding="0",o.style.margin="0",o.style.border="none",o.style.outline="none",o.style.clip="rect(1px, 1px, 1px, 1px)",o.style.clipPath="inset(50%)",o.style.overflow="hidden",o.style.whiteSpace="nowrap",o}}("input")))return;if(o.type="file",o.tabIndex=-1,o.accept=i+"/*","capture"in HTMLInputElement.prototype)o.capture="user";else if(r.os===e.Android){var a="";"image"===i?a="camera":"video"===i&&(a="camcorder"),o.accept=i+"/*;capture="+a}t.body.appendChild(o),function(e,i){var o;void 0===i&&(i=window);try{o=new MouseEvent("click",{bubbles:!0,cancelable:!0,view:i})}catch(e){(o=globalThis.document.createEvent("MouseEvents")).initMouseEvent("click",!0,!0,i,0,0,0,0,0,!1,!1,!1,!1,0,null)}e.dispatchEvent(o)}(o,n)}catch(e){}}r.isNodeJS&&function(e){if("require"in globalThis&&"function"==typeof globalThis.require)try{return Promise.resolve(globalThis.require(e))}catch(e){return Promise.resolve(null)}return import(e).then((function(e){return e.default||e})).catch((function(){return Promise.resolve(null)}))}("os").then((function(i){if(null!==i){var o,n=i.platform(),t=i.release(),a=(o=t.split("."),{major:parseInt(o[0]||"0"),minor:parseInt(o[1]||"0"),build:parseInt(o[2]||"0")});switch(n){case"win32":r.os=e.Windows,r.osVersion=10===a.major&&0===a.minor&&a.build>=22e3?"11":10===a.major&&0===a.minor&&a.build<22e3?"10":6===a.major&&3===a.minor?"8.1":6===a.major&&2===a.minor?"8":6===a.major&&1===a.minor?"7":6===a.major&&0===a.minor?"Vista":5===a.major&&1===a.minor||5===a.major&&2===a.minor?"XP":5===a.major&&0===a.minor?"2000":4===a.major&&90===a.minor?"ME":4===a.major&&0===a.minor?"NT 4.0":3===a.major&&51===a.minor?"NT 3.11":t;break;case"darwin":r.os=e.MacOS,r.osVersion=a.major>=24?""+(a.major-9):23===a.major?"14":22===a.major?"13":21===a.major?"12":20===a.major?"11":19===a.major?"10.15":18===a.major?"10.14":17===a.major?"10.13":16===a.major?"10.12":15===a.major?"10.11":14===a.major?"10.10":13===a.major?"10.9":a.major>=5&&a.major<=12?"10."+(a.major-4):t;break;case"android":r.os=e.Android,r.osVersion=t;break;case"linux":/android/i.test(t)&&(r.os=e.Android,r.osVersion=t)}}})),void 0!==navigator.userAgentData&&void 0!==navigator.userAgentData.getHighEntropyValues&&navigator.userAgentData.getHighEntropyValues(["brands","fullVersionList","mobile","model","platform","platformVersion","architecture","formFactors","bitness","uaFullVersion","wow64"]).then((function(i){for(var o,n=i.fullVersionList||i.brands||[],t=i.platformVersion,a=0;a<n.length;a++){var s=null==(o=n[a])?{brand:"",version:""}:"string"==typeof o?{brand:o,version:""}:{brand:o.brand,version:o.version},l=s.brand,d=s.version;/not.a.brand/i.test(l)||"Chromium"===l&&(r.engineVersion=d)}"string"==typeof t&&(r.os===e.Windows&&parseInt(t.replace(/[^\d.]/g,"").split(".")[0],10)>=13?r.osVersion="11":r.osVersion=t)})),r.isMobile=r.device===i.Mobile,r.isDesktop=r.device===i.Desktop,r.isWebview=/; ?wv|applewebkit(?!.*safari)/i.test(r.userAgent),r.isStandalone=function(i){return"matchMedia"in globalThis&&(i===e.iOS?"standalone"in navigator&&!!navigator.standalone:globalThis.matchMedia("(display-mode: standalone)").matches)}(r.os);var k,T={open:function(i){switch(r.os){case e.Android:v(i);break;case e.iOS:(function(e,i){for(var o=e.split("."),n=i.split("."),r=Math.max(o.length,n.length),t=0;t<r;t++){var a=void 0,s=void 0;if((a=t<o.length?parseInt(o[t],10):0)>(s=t<n.length?parseInt(n[t],10):0))return 1;if(a<s)return-1}return 0})(r.osVersion,"10.3")>=0?v(i):alert(r.osVersion);case e.Windows:case e.MacOS:}}};!function(e){e.Image="image",e.Video="video"}(k||(k={}));var y={installed:!1,name:"Camera",module:T,Constants:{CameraType:k},Errors:{}};export{y as default};
1
+ var e,i,o,n;!function(e){e.Unknown="Unknown",e.Android="Android",e.iOS="iOS",e.Windows="Windows",e.MacOS="MacOS"}(e||(e={})),function(e){e.Unknown="Unknown",e.Mobile="Mobile",e.Desktop="Desktop"}(i||(i={})),function(e){e.Unknown="Unknown",e.EdgeHTML="EdgeHTML",e.ArkWeb="ArkWeb",e.Blink="Blink",e.Presto="Presto",e.WebKit="WebKit",e.Trident="Trident",e.NetFront="NetFront",e.KHTML="KHTML",e.Tasman="Tasman",e.Gecko="Gecko"}(o||(o={})),function(e){e.Unknown="Unknown",e.Chrome="Chrome",e.Safari="Safari",e.Edge="Edge",e.Firefox="Firefox",e.Opera="Opera",e.IE="IE",e.SamsungInternet="SamsungInternet"}(n||(n={}));var r={device:i.Unknown,os:e.Unknown,osVersion:"",engine:o.Unknown,engineVersion:"",browser:n.Unknown,browserVersion:"",renderer:function(){if(void 0===globalThis.document)return"";var e=globalThis.document.createElement("canvas");if("function"!=typeof e.getContext)return"";var i=e.getContext("webgl2")||e.getContext("experimental-webgl")||e.getContext("webgl");if(null===i)return"";if(i instanceof WebGLRenderingContext||"getParameter"in i&&"function"==typeof i.getParameter){var o=i.getExtension("WEBGL_debug_renderer_info");return null===o?i.getParameter(i.RENDERER):i.getParameter(o.UNMASKED_RENDERER_WEBGL)}return""}(),userAgent:navigator.userAgent,isWebview:!1,isMobile:!1,isDesktop:!1,isStandalone:!1,isNodeJS:void 0!==globalThis.process&&void 0!==globalThis.process.versions&&void 0!==globalThis.process.versions.node},t=[[/windows nt (6\.[23]); arm/i,e.Windows,l],[/windows (?:phone|mobile|iot)(?: os)?[\/ ]?([\d.]*( se)?)/i,e.Windows,l],[/windows[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i,e.Windows,l],[/windows nt ?([\d.)]*)(?!.+xbox)/i,e.Windows,l],[/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d.;]*)/i,e.Windows,l],[/windows ce\/?([\d.]*)/i,e.Windows,l],[/[adehimnop]{4,7}\b(?:.*os (\w+) like mac|; opera)/i,e.iOS,d],[/(?:ios;fbsv|ios(?=.+ip(?:ad|hone))|ip(?:ad|hone)(?: |.+i(?:pad)?)os)[\/ ]([\w.]+)/i,e.iOS,d],[/cfnetwork\/.+darwin/i,e.iOS,d],[/mac os x ?([\w. ]*)/i,e.MacOS,d],[/(?:macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i,e.MacOS,d],[/droid ([\w.]+)\b.+(android[- ]x86)/i,e.Android],[/android\w*[-\/.; ]?([\d.]*)/i,e.Android]],a=[[/windows.+ edge\/([\w.]+)/i,o.EdgeHTML],[/arkweb\/([\w.]+)/i,o.ArkWeb],[/webkit\/537\.36.+chrome\/(?!27)([\w.]+)/i,o.Blink],[/presto\/([\w.]+)/i,o.Presto],[/webkit\/([\w.]+)/i,o.WebKit],[/trident\/([\w.]+)/i,o.Trident],[/netfront\/([\w.]+)/i,o.NetFront],[/khtml[\/ ]\(?([\w.]+)/i,o.KHTML],[/tasman[\/ ]\(?([\w.]+)/i,o.Tasman],[/rv:([\w.]{1,9})\b.+gecko/i,o.Gecko]],s=[[/\b(?:crmo|crios)\/([\w.]+)/i,n.Chrome],[/webview.+edge\/([\w.]+)/i,n.Edge],[/edg(?:e|ios|a)?\/([\w.]+)/i,n.Edge],[/opera mini\/([-\w.]+)/i,n.Opera],[/opera [mobileta]{3,6}\b.+version\/([-\w.]+)/i,n.Opera],[/opera(?:.+version\/|[\/ ]+)([\w.]+)/i,n.Opera],[/opios[\/ ]+([\w.]+)/i,n.Opera],[/\bop(?:rg)?x\/([\w.]+)/i,n.Opera],[/\bopr\/([\w.]+)/i,n.Opera],[/iemobile(?:browser|boat|jet)[\/ ]?([\d.]*)/i,n.IE],[/(?:ms|\()ie ([\w.]+)/i,n.IE],[/trident.+rv[: ]([\w.]{1,9})\b.+like gecko/i,n.IE],[/\bfocus\/([\w.]+)/i,n.Firefox],[/\bopt\/([\w.]+)/i,n.Opera],[/coast\/([\w.]+)/i,n.Opera],[/fxios\/([\w.-]+)/i,n.Firefox],[/samsungbrowser\/([\w.]+)/i,n.SamsungInternet],[/headlesschrome(?:\/([\w.]+)| )/i,n.Chrome],[/wv\).+chrome\/([\w.]+).+edgw\//i,n.Edge],[/ wv\).+(chrome)\/([\w.]+)/i,n.Chrome],[/chrome\/([\w.]+) mobile/i,n.Chrome],[/chrome\/v?([\w.]+)/i,n.Chrome],[/version\/([\w.,]+) .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/iphone .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/version\/([\w.,]+) .*safari/i,n.Safari],[/webkit.+?(?:mobile ?safari|safari)(\/[\w.]+)/i,n.Safari,"1"],[/(?:mobile|tablet);.*firefox\/([\w.-]+)/i,n.Firefox],[/mobile vr; rv:([\w.]+)\).+firefox/i,n.Firefox],[/firefox\/([\w.]+)/i,n.Firefox]];function l(e){if(void 0===e)return"";var i={"4.90":"ME","NT3.51":"NT 3.11","NT4.0":"NT 4.0","NT 5.0":"2000","NT 5.1":"XP","NT 5.2":"XP","NT 6.0":"Vista","NT 6.1":"7","NT 6.2":"8","NT 6.3":"8.1","NT 6.4":"10","NT 10.0":"10",ARM:"RT"}[e];return void 0!==i?i:e}function d(e){return void 0===e?"":e.replace(/_/g,".")}function m(e,i){return"function"==typeof i?i(e):"string"==typeof i?i:void 0===e?"":e}for(var c=0;c<t.length;c++){var w=(f=t[c])[0],u=f[1],b=f[2];if(null!==(g=r.userAgent.match(w))){r.os=u,r.osVersion=m(g[1],b),u===e.iOS||u===e.Android?r.device=i.Mobile:u!==e.Windows&&u!==e.MacOS||(r.device=i.Desktop);break}}for(c=0;c<a.length;c++){w=(f=a[c])[0];var p=f[1];b=f[2];if(null!==(g=r.userAgent.match(w))){r.engine=p,r.engineVersion=m(g[1],b);break}}for(c=0;c<s.length;c++){w=(f=s[c])[0];var f,g,v=f[1];b=f[2];if(null!==(g=r.userAgent.match(w))){r.browser=v,r.browserVersion=m(g[1],b);break}}if("undefined"!=typeof navigator&&"ReactNative"===navigator.product)try{import("react-native").then((function(e){console.log(e.Platform)}))}catch(e){}else r.isNodeJS&&function(e){if("require"in globalThis&&"function"==typeof globalThis.require)try{return Promise.resolve(globalThis.require(e))}catch(e){return Promise.resolve(null)}return Promise.resolve(null)}("os").then((function(i){if(null!==i){var o,n=i.platform(),t=i.release(),a=(o=t.split("."),{major:parseInt(o[0]||"0"),minor:parseInt(o[1]||"0"),build:parseInt(o[2]||"0")});switch(n){case"win32":r.os=e.Windows,r.osVersion=10===a.major&&0===a.minor&&a.build>=22e3?"11":10===a.major&&0===a.minor&&a.build<22e3?"10":6===a.major&&3===a.minor?"8.1":6===a.major&&2===a.minor?"8":6===a.major&&1===a.minor?"7":6===a.major&&0===a.minor?"Vista":5===a.major&&1===a.minor||5===a.major&&2===a.minor?"XP":5===a.major&&0===a.minor?"2000":4===a.major&&90===a.minor?"ME":4===a.major&&0===a.minor?"NT 4.0":3===a.major&&51===a.minor?"NT 3.11":t;break;case"darwin":r.os=e.MacOS,r.osVersion=a.major>=24?a.major-9+"."+a.minor+"."+a.build:23===a.major?"14."+a.minor+"."+a.build:22===a.major?"13."+a.minor+"."+a.build:21===a.major?"12."+a.minor+"."+a.build:20===a.major?"11."+a.minor+"."+a.build:19===a.major?"10.15."+a.minor:18===a.major?"10.14."+a.minor:17===a.major?"10.13."+a.minor:16===a.major?"10.12."+a.minor:15===a.major?"10.11."+a.minor:14===a.major?"10.10."+a.minor:13===a.major?"10.9."+a.minor:a.major>=5&&a.major<=12?"10."+(a.major-4)+"."+a.minor:t;break;case"android":r.os=e.Android,r.osVersion=t;break;case"linux":/android/i.test(t)&&(r.os=e.Android,r.osVersion=t)}}}));function h(i){var o,n=function(){try{if(globalThis.top&&globalThis.top!==window)return globalThis.top.location.href,globalThis.top}catch(e){}return window}(),t=n.document;try{if(void 0===(o=function(e,i){if(void 0===i&&(i=!0),void 0!==globalThis.document){var o=globalThis.document.createElement(e);return"width"in o&&(o.width="0"),"height"in o&&(o.height="0"),"border"in o&&(o.border="0"),"frameBorder"in o&&(o.frameBorder="0"),"scrolling"in o&&(o.scrolling="no"),"cellPadding"in o&&(o.cellPadding="0"),"cellSpacing"in o&&(o.cellSpacing="0"),"frame"in o&&(o.frame="void"),"rules"in o&&(o.rules="none"),"noWrap"in o&&(o.noWrap=!0),o.tabIndex=-1,o.setAttribute("role","presentation"),i?(o.style.width="1px",o.style.height="1px"):(o.setAttribute("aria-hidden","true"),o.style.width="0",o.style.height="0",o.style.zIndex="-9999",o.style.display="none",o.style.visibility="hidden",o.style.pointerEvents="none"),o.style.position="absolute",o.style.top="0",o.style.left="0",o.style.padding="0",o.style.margin="0",o.style.border="none",o.style.outline="none",o.style.clip="rect(1px, 1px, 1px, 1px)",o.style.clipPath="inset(50%)",o.style.overflow="hidden",o.style.whiteSpace="nowrap",o}}("input")))return;if(o.type="file",o.tabIndex=-1,o.accept=i+"/*","capture"in HTMLInputElement.prototype)o.capture="user";else if(r.os===e.Android){var a="";"image"===i?a="camera":"video"===i&&(a="camcorder"),o.accept=i+"/*;capture="+a}t.body.appendChild(o),function(e,i){var o;void 0===i&&(i=window);try{o=new MouseEvent("click",{bubbles:!0,cancelable:!0,view:i})}catch(e){(o=globalThis.document.createEvent("MouseEvents")).initMouseEvent("click",!0,!0,i,0,0,0,0,0,!1,!1,!1,!1,0,null)}e.dispatchEvent(o)}(o,n)}catch(e){}}void 0!==navigator.userAgentData&&void 0!==navigator.userAgentData.getHighEntropyValues&&navigator.userAgentData.getHighEntropyValues(["brands","fullVersionList","mobile","model","platform","platformVersion","architecture","formFactors","bitness","uaFullVersion","wow64"]).then((function(i){for(var o,n=i.fullVersionList||i.brands||[],t=i.platformVersion,a=0;a<n.length;a++){var s=null==(o=n[a])?{brand:"",version:""}:"string"==typeof o?{brand:o,version:""}:{brand:o.brand,version:o.version},l=s.brand,d=s.version;/not.a.brand/i.test(l)||"Chromium"===l&&(r.engineVersion=d)}"string"==typeof t&&(r.os===e.Windows&&parseInt(t.replace(/[^\d.]/g,"").split(".")[0],10)>=13?r.osVersion="11":r.osVersion=t)})),r.isMobile=r.device===i.Mobile,r.isDesktop=r.device===i.Desktop,r.isWebview=/; ?wv|applewebkit(?!.*safari)/i.test(r.userAgent),r.isStandalone=function(i){return"matchMedia"in globalThis&&(i===e.iOS?"standalone"in navigator&&!!navigator.standalone:globalThis.matchMedia("(display-mode: standalone)").matches)}(r.os);var k,T={open:function(i){switch(r.os){case e.Android:h(i);break;case e.iOS:(function(e,i){for(var o=e.split("."),n=i.split("."),r=Math.max(o.length,n.length),t=0;t<r;t++){var a=void 0,s=void 0;if((a=t<o.length?parseInt(o[t],10):0)>(s=t<n.length?parseInt(n[t],10):0))return 1;if(a<s)return-1}return 0})(r.osVersion,"10.3")>=0?h(i):alert(r.osVersion);case e.Windows:case e.MacOS:}}};!function(e){e.Image="image",e.Video="video"}(k||(k={}));var y={installed:!1,name:"Camera",module:T,Constants:{CameraType:k},Errors:{}};export{y as default};
@@ -1,4 +1,4 @@
1
- function dynamicImport(moduleName) {
1
+ function require(moduleName) {
2
2
  if ('require' in globalThis && typeof globalThis.require === 'function') {
3
3
  try {
4
4
  return Promise.resolve(globalThis.require(moduleName));
@@ -7,13 +7,7 @@ function dynamicImport(moduleName) {
7
7
  return Promise.resolve(null);
8
8
  }
9
9
  }
10
- return import(moduleName)
11
- .then(function (module) {
12
- return (module.default || module);
13
- })
14
- .catch(function () {
15
- return Promise.resolve(null);
16
- });
10
+ return Promise.resolve(null);
17
11
  }
18
12
 
19
13
  var OS;
@@ -253,8 +247,18 @@ for (var i = 0; i < BROWSER_RESOLVER_MAP.length; i++) {
253
247
  break;
254
248
  }
255
249
  }
256
- if (Platform.isNodeJS) {
257
- dynamicImport('os')
250
+ if (typeof navigator !== 'undefined' && navigator.product === 'ReactNative') {
251
+ try {
252
+ import('react-native')
253
+ .then(function (reactNative) {
254
+ console.log(reactNative.Platform);
255
+ });
256
+ }
257
+ catch (_) {
258
+ }
259
+ }
260
+ else if (Platform.isNodeJS) {
261
+ require('os')
258
262
  .then(function (os) {
259
263
  if (os === null)
260
264
  return;
@@ -294,31 +298,31 @@ if (Platform.isNodeJS) {
294
298
  case 'darwin':
295
299
  Platform.os = OS.MacOS;
296
300
  if (version.major >= 24)
297
- Platform.osVersion = '' + (version.major - 9);
301
+ Platform.osVersion = '' + (version.major - 9) + '.' + version.minor + '.' + version.build;
298
302
  else if (version.major === 23)
299
- Platform.osVersion = '14';
303
+ Platform.osVersion = '14.' + version.minor + '.' + version.build;
300
304
  else if (version.major === 22)
301
- Platform.osVersion = '13';
305
+ Platform.osVersion = '13.' + version.minor + '.' + version.build;
302
306
  else if (version.major === 21)
303
- Platform.osVersion = '12';
307
+ Platform.osVersion = '12.' + version.minor + '.' + version.build;
304
308
  else if (version.major === 20)
305
- Platform.osVersion = '11';
309
+ Platform.osVersion = '11.' + version.minor + '.' + version.build;
306
310
  else if (version.major === 19)
307
- Platform.osVersion = '10.15';
311
+ Platform.osVersion = '10.15.' + version.minor;
308
312
  else if (version.major === 18)
309
- Platform.osVersion = '10.14';
313
+ Platform.osVersion = '10.14.' + version.minor;
310
314
  else if (version.major === 17)
311
- Platform.osVersion = '10.13';
315
+ Platform.osVersion = '10.13.' + version.minor;
312
316
  else if (version.major === 16)
313
- Platform.osVersion = '10.12';
317
+ Platform.osVersion = '10.12.' + version.minor;
314
318
  else if (version.major === 15)
315
- Platform.osVersion = '10.11';
319
+ Platform.osVersion = '10.11.' + version.minor;
316
320
  else if (version.major === 14)
317
- Platform.osVersion = '10.10';
321
+ Platform.osVersion = '10.10.' + version.minor;
318
322
  else if (version.major === 13)
319
- Platform.osVersion = '10.9';
323
+ Platform.osVersion = '10.9.' + version.minor;
320
324
  else if (version.major >= 5 && version.major <= 12)
321
- Platform.osVersion = '10.' + (version.major - 4);
325
+ Platform.osVersion = '10.' + (version.major - 4) + '.' + version.minor;
322
326
  else
323
327
  Platform.osVersion = release;
324
328
  break;
@@ -4,7 +4,7 @@
4
4
  (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Camera = factory());
5
5
  })(this, (function () { 'use strict';
6
6
 
7
- function dynamicImport(moduleName) {
7
+ function require(moduleName) {
8
8
  if ('require' in globalThis && typeof globalThis.require === 'function') {
9
9
  try {
10
10
  return Promise.resolve(globalThis.require(moduleName));
@@ -13,13 +13,7 @@
13
13
  return Promise.resolve(null);
14
14
  }
15
15
  }
16
- return import(moduleName)
17
- .then(function (module) {
18
- return (module.default || module);
19
- })
20
- .catch(function () {
21
- return Promise.resolve(null);
22
- });
16
+ return Promise.resolve(null);
23
17
  }
24
18
 
25
19
  var OS;
@@ -259,8 +253,18 @@
259
253
  break;
260
254
  }
261
255
  }
262
- if (Platform.isNodeJS) {
263
- dynamicImport('os')
256
+ if (typeof navigator !== 'undefined' && navigator.product === 'ReactNative') {
257
+ try {
258
+ import('react-native')
259
+ .then(function (reactNative) {
260
+ console.log(reactNative.Platform);
261
+ });
262
+ }
263
+ catch (_) {
264
+ }
265
+ }
266
+ else if (Platform.isNodeJS) {
267
+ require('os')
264
268
  .then(function (os) {
265
269
  if (os === null)
266
270
  return;
@@ -300,31 +304,31 @@
300
304
  case 'darwin':
301
305
  Platform.os = OS.MacOS;
302
306
  if (version.major >= 24)
303
- Platform.osVersion = '' + (version.major - 9);
307
+ Platform.osVersion = '' + (version.major - 9) + '.' + version.minor + '.' + version.build;
304
308
  else if (version.major === 23)
305
- Platform.osVersion = '14';
309
+ Platform.osVersion = '14.' + version.minor + '.' + version.build;
306
310
  else if (version.major === 22)
307
- Platform.osVersion = '13';
311
+ Platform.osVersion = '13.' + version.minor + '.' + version.build;
308
312
  else if (version.major === 21)
309
- Platform.osVersion = '12';
313
+ Platform.osVersion = '12.' + version.minor + '.' + version.build;
310
314
  else if (version.major === 20)
311
- Platform.osVersion = '11';
315
+ Platform.osVersion = '11.' + version.minor + '.' + version.build;
312
316
  else if (version.major === 19)
313
- Platform.osVersion = '10.15';
317
+ Platform.osVersion = '10.15.' + version.minor;
314
318
  else if (version.major === 18)
315
- Platform.osVersion = '10.14';
319
+ Platform.osVersion = '10.14.' + version.minor;
316
320
  else if (version.major === 17)
317
- Platform.osVersion = '10.13';
321
+ Platform.osVersion = '10.13.' + version.minor;
318
322
  else if (version.major === 16)
319
- Platform.osVersion = '10.12';
323
+ Platform.osVersion = '10.12.' + version.minor;
320
324
  else if (version.major === 15)
321
- Platform.osVersion = '10.11';
325
+ Platform.osVersion = '10.11.' + version.minor;
322
326
  else if (version.major === 14)
323
- Platform.osVersion = '10.10';
327
+ Platform.osVersion = '10.10.' + version.minor;
324
328
  else if (version.major === 13)
325
- Platform.osVersion = '10.9';
329
+ Platform.osVersion = '10.9.' + version.minor;
326
330
  else if (version.major >= 5 && version.major <= 12)
327
- Platform.osVersion = '10.' + (version.major - 4);
331
+ Platform.osVersion = '10.' + (version.major - 4) + '.' + version.minor;
328
332
  else
329
333
  Platform.osVersion = release;
330
334
  break;
@@ -1 +1 @@
1
- !function(e,i){"object"==typeof exports&&"undefined"!=typeof module?module.exports=i():"function"==typeof define&&define.amd?define(i):(e="undefined"!=typeof globalThis?globalThis:e||self).Camera=i()}(this,(function(){"use strict";var e,i,o,n;!function(e){e.Unknown="Unknown",e.Android="Android",e.iOS="iOS",e.Windows="Windows",e.MacOS="MacOS"}(e||(e={})),function(e){e.Unknown="Unknown",e.Mobile="Mobile",e.Desktop="Desktop"}(i||(i={})),function(e){e.Unknown="Unknown",e.EdgeHTML="EdgeHTML",e.ArkWeb="ArkWeb",e.Blink="Blink",e.Presto="Presto",e.WebKit="WebKit",e.Trident="Trident",e.NetFront="NetFront",e.KHTML="KHTML",e.Tasman="Tasman",e.Gecko="Gecko"}(o||(o={})),function(e){e.Unknown="Unknown",e.Chrome="Chrome",e.Safari="Safari",e.Edge="Edge",e.Firefox="Firefox",e.Opera="Opera",e.IE="IE",e.SamsungInternet="SamsungInternet"}(n||(n={}));var r={device:i.Unknown,os:e.Unknown,osVersion:"",engine:o.Unknown,engineVersion:"",browser:n.Unknown,browserVersion:"",renderer:function(){if(void 0===globalThis.document)return"";var e=globalThis.document.createElement("canvas");if("function"!=typeof e.getContext)return"";var i=e.getContext("webgl2")||e.getContext("experimental-webgl")||e.getContext("webgl");if(null===i)return"";if(i instanceof WebGLRenderingContext||"getParameter"in i&&"function"==typeof i.getParameter){var o=i.getExtension("WEBGL_debug_renderer_info");return null===o?i.getParameter(i.RENDERER):i.getParameter(o.UNMASKED_RENDERER_WEBGL)}return""}(),userAgent:navigator.userAgent,isWebview:!1,isMobile:!1,isDesktop:!1,isStandalone:!1,isNodeJS:void 0!==globalThis.process&&void 0!==globalThis.process.versions&&void 0!==globalThis.process.versions.node},t=[[/windows nt (6\.[23]); arm/i,e.Windows,l],[/windows (?:phone|mobile|iot)(?: os)?[\/ ]?([\d.]*( se)?)/i,e.Windows,l],[/windows[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i,e.Windows,l],[/windows nt ?([\d.)]*)(?!.+xbox)/i,e.Windows,l],[/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d.;]*)/i,e.Windows,l],[/windows ce\/?([\d.]*)/i,e.Windows,l],[/[adehimnop]{4,7}\b(?:.*os (\w+) like mac|; opera)/i,e.iOS,d],[/(?:ios;fbsv|ios(?=.+ip(?:ad|hone))|ip(?:ad|hone)(?: |.+i(?:pad)?)os)[\/ ]([\w.]+)/i,e.iOS,d],[/cfnetwork\/.+darwin/i,e.iOS,d],[/mac os x ?([\w. ]*)/i,e.MacOS,d],[/(?:macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i,e.MacOS,d],[/droid ([\w.]+)\b.+(android[- ]x86)/i,e.Android],[/android\w*[-\/.; ]?([\d.]*)/i,e.Android]],a=[[/windows.+ edge\/([\w.]+)/i,o.EdgeHTML],[/arkweb\/([\w.]+)/i,o.ArkWeb],[/webkit\/537\.36.+chrome\/(?!27)([\w.]+)/i,o.Blink],[/presto\/([\w.]+)/i,o.Presto],[/webkit\/([\w.]+)/i,o.WebKit],[/trident\/([\w.]+)/i,o.Trident],[/netfront\/([\w.]+)/i,o.NetFront],[/khtml[\/ ]\(?([\w.]+)/i,o.KHTML],[/tasman[\/ ]\(?([\w.]+)/i,o.Tasman],[/rv:([\w.]{1,9})\b.+gecko/i,o.Gecko]],s=[[/\b(?:crmo|crios)\/([\w.]+)/i,n.Chrome],[/webview.+edge\/([\w.]+)/i,n.Edge],[/edg(?:e|ios|a)?\/([\w.]+)/i,n.Edge],[/opera mini\/([-\w.]+)/i,n.Opera],[/opera [mobileta]{3,6}\b.+version\/([-\w.]+)/i,n.Opera],[/opera(?:.+version\/|[\/ ]+)([\w.]+)/i,n.Opera],[/opios[\/ ]+([\w.]+)/i,n.Opera],[/\bop(?:rg)?x\/([\w.]+)/i,n.Opera],[/\bopr\/([\w.]+)/i,n.Opera],[/iemobile(?:browser|boat|jet)[\/ ]?([\d.]*)/i,n.IE],[/(?:ms|\()ie ([\w.]+)/i,n.IE],[/trident.+rv[: ]([\w.]{1,9})\b.+like gecko/i,n.IE],[/\bfocus\/([\w.]+)/i,n.Firefox],[/\bopt\/([\w.]+)/i,n.Opera],[/coast\/([\w.]+)/i,n.Opera],[/fxios\/([\w.-]+)/i,n.Firefox],[/samsungbrowser\/([\w.]+)/i,n.SamsungInternet],[/headlesschrome(?:\/([\w.]+)| )/i,n.Chrome],[/wv\).+chrome\/([\w.]+).+edgw\//i,n.Edge],[/ wv\).+(chrome)\/([\w.]+)/i,n.Chrome],[/chrome\/([\w.]+) mobile/i,n.Chrome],[/chrome\/v?([\w.]+)/i,n.Chrome],[/version\/([\w.,]+) .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/iphone .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/version\/([\w.,]+) .*safari/i,n.Safari],[/webkit.+?(?:mobile ?safari|safari)(\/[\w.]+)/i,n.Safari,"1"],[/(?:mobile|tablet);.*firefox\/([\w.-]+)/i,n.Firefox],[/mobile vr; rv:([\w.]+)\).+firefox/i,n.Firefox],[/firefox\/([\w.]+)/i,n.Firefox]];function l(e){if(void 0===e)return"";var i={"4.90":"ME","NT3.51":"NT 3.11","NT4.0":"NT 4.0","NT 5.0":"2000","NT 5.1":"XP","NT 5.2":"XP","NT 6.0":"Vista","NT 6.1":"7","NT 6.2":"8","NT 6.3":"8.1","NT 6.4":"10","NT 10.0":"10",ARM:"RT"}[e];return void 0!==i?i:e}function d(e){return void 0===e?"":e.replace(/_/g,".")}function c(e,i){return"function"==typeof i?i(e):"string"==typeof i?i:void 0===e?"":e}for(var m=0;m<t.length;m++){var w=(b=t[m])[0],u=b[1],f=b[2];if(null!==(g=r.userAgent.match(w))){r.os=u,r.osVersion=c(g[1],f),u===e.iOS||u===e.Android?r.device=i.Mobile:u!==e.Windows&&u!==e.MacOS||(r.device=i.Desktop);break}}for(m=0;m<a.length;m++){w=(b=a[m])[0];var p=b[1];f=b[2];if(null!==(g=r.userAgent.match(w))){r.engine=p,r.engineVersion=c(g[1],f);break}}for(m=0;m<s.length;m++){w=(b=s[m])[0];var b,g,h=b[1];f=b[2];if(null!==(g=r.userAgent.match(w))){r.browser=h,r.browserVersion=c(g[1],f);break}}function v(i){var o,n=function(){try{if(globalThis.top&&globalThis.top!==window)return globalThis.top.location.href,globalThis.top}catch(e){}return window}(),t=n.document;try{if(void 0===(o=function(e,i){if(void 0===i&&(i=!0),void 0!==globalThis.document){var o=globalThis.document.createElement(e);return"width"in o&&(o.width="0"),"height"in o&&(o.height="0"),"border"in o&&(o.border="0"),"frameBorder"in o&&(o.frameBorder="0"),"scrolling"in o&&(o.scrolling="no"),"cellPadding"in o&&(o.cellPadding="0"),"cellSpacing"in o&&(o.cellSpacing="0"),"frame"in o&&(o.frame="void"),"rules"in o&&(o.rules="none"),"noWrap"in o&&(o.noWrap=!0),o.tabIndex=-1,o.setAttribute("role","presentation"),i?(o.style.width="1px",o.style.height="1px"):(o.setAttribute("aria-hidden","true"),o.style.width="0",o.style.height="0",o.style.zIndex="-9999",o.style.display="none",o.style.visibility="hidden",o.style.pointerEvents="none"),o.style.position="absolute",o.style.top="0",o.style.left="0",o.style.padding="0",o.style.margin="0",o.style.border="none",o.style.outline="none",o.style.clip="rect(1px, 1px, 1px, 1px)",o.style.clipPath="inset(50%)",o.style.overflow="hidden",o.style.whiteSpace="nowrap",o}}("input")))return;if(o.type="file",o.tabIndex=-1,o.accept=i+"/*","capture"in HTMLInputElement.prototype)o.capture="user";else if(r.os===e.Android){var a="";"image"===i?a="camera":"video"===i&&(a="camcorder"),o.accept=i+"/*;capture="+a}t.body.appendChild(o),function(e,i){var o;void 0===i&&(i=window);try{o=new MouseEvent("click",{bubbles:!0,cancelable:!0,view:i})}catch(e){(o=globalThis.document.createEvent("MouseEvents")).initMouseEvent("click",!0,!0,i,0,0,0,0,0,!1,!1,!1,!1,0,null)}e.dispatchEvent(o)}(o,n)}catch(e){}}r.isNodeJS&&function(e){if("require"in globalThis&&"function"==typeof globalThis.require)try{return Promise.resolve(globalThis.require(e))}catch(e){return Promise.resolve(null)}return import(e).then((function(e){return e.default||e})).catch((function(){return Promise.resolve(null)}))}("os").then((function(i){if(null!==i){var o,n=i.platform(),t=i.release(),a=(o=t.split("."),{major:parseInt(o[0]||"0"),minor:parseInt(o[1]||"0"),build:parseInt(o[2]||"0")});switch(n){case"win32":r.os=e.Windows,r.osVersion=10===a.major&&0===a.minor&&a.build>=22e3?"11":10===a.major&&0===a.minor&&a.build<22e3?"10":6===a.major&&3===a.minor?"8.1":6===a.major&&2===a.minor?"8":6===a.major&&1===a.minor?"7":6===a.major&&0===a.minor?"Vista":5===a.major&&1===a.minor||5===a.major&&2===a.minor?"XP":5===a.major&&0===a.minor?"2000":4===a.major&&90===a.minor?"ME":4===a.major&&0===a.minor?"NT 4.0":3===a.major&&51===a.minor?"NT 3.11":t;break;case"darwin":r.os=e.MacOS,r.osVersion=a.major>=24?""+(a.major-9):23===a.major?"14":22===a.major?"13":21===a.major?"12":20===a.major?"11":19===a.major?"10.15":18===a.major?"10.14":17===a.major?"10.13":16===a.major?"10.12":15===a.major?"10.11":14===a.major?"10.10":13===a.major?"10.9":a.major>=5&&a.major<=12?"10."+(a.major-4):t;break;case"android":r.os=e.Android,r.osVersion=t;break;case"linux":/android/i.test(t)&&(r.os=e.Android,r.osVersion=t)}}})),void 0!==navigator.userAgentData&&void 0!==navigator.userAgentData.getHighEntropyValues&&navigator.userAgentData.getHighEntropyValues(["brands","fullVersionList","mobile","model","platform","platformVersion","architecture","formFactors","bitness","uaFullVersion","wow64"]).then((function(i){for(var o,n=i.fullVersionList||i.brands||[],t=i.platformVersion,a=0;a<n.length;a++){var s=null==(o=n[a])?{brand:"",version:""}:"string"==typeof o?{brand:o,version:""}:{brand:o.brand,version:o.version},l=s.brand,d=s.version;/not.a.brand/i.test(l)||"Chromium"===l&&(r.engineVersion=d)}"string"==typeof t&&(r.os===e.Windows&&parseInt(t.replace(/[^\d.]/g,"").split(".")[0],10)>=13?r.osVersion="11":r.osVersion=t)})),r.isMobile=r.device===i.Mobile,r.isDesktop=r.device===i.Desktop,r.isWebview=/; ?wv|applewebkit(?!.*safari)/i.test(r.userAgent),r.isStandalone=function(i){return"matchMedia"in globalThis&&(i===e.iOS?"standalone"in navigator&&!!navigator.standalone:globalThis.matchMedia("(display-mode: standalone)").matches)}(r.os);var T,k={open:function(i){switch(r.os){case e.Android:v(i);break;case e.iOS:(function(e,i){for(var o=e.split("."),n=i.split("."),r=Math.max(o.length,n.length),t=0;t<r;t++){var a=void 0,s=void 0;if((a=t<o.length?parseInt(o[t],10):0)>(s=t<n.length?parseInt(n[t],10):0))return 1;if(a<s)return-1}return 0})(r.osVersion,"10.3")>=0?v(i):alert(r.osVersion);case e.Windows:case e.MacOS:}}};return function(e){e.Image="image",e.Video="video"}(T||(T={})),{installed:!1,name:"Camera",module:k,Constants:{CameraType:T},Errors:{}}}));
1
+ !function(e,i){"object"==typeof exports&&"undefined"!=typeof module?module.exports=i():"function"==typeof define&&define.amd?define(i):(e="undefined"!=typeof globalThis?globalThis:e||self).Camera=i()}(this,(function(){"use strict";var e,i,o,n;!function(e){e.Unknown="Unknown",e.Android="Android",e.iOS="iOS",e.Windows="Windows",e.MacOS="MacOS"}(e||(e={})),function(e){e.Unknown="Unknown",e.Mobile="Mobile",e.Desktop="Desktop"}(i||(i={})),function(e){e.Unknown="Unknown",e.EdgeHTML="EdgeHTML",e.ArkWeb="ArkWeb",e.Blink="Blink",e.Presto="Presto",e.WebKit="WebKit",e.Trident="Trident",e.NetFront="NetFront",e.KHTML="KHTML",e.Tasman="Tasman",e.Gecko="Gecko"}(o||(o={})),function(e){e.Unknown="Unknown",e.Chrome="Chrome",e.Safari="Safari",e.Edge="Edge",e.Firefox="Firefox",e.Opera="Opera",e.IE="IE",e.SamsungInternet="SamsungInternet"}(n||(n={}));var r={device:i.Unknown,os:e.Unknown,osVersion:"",engine:o.Unknown,engineVersion:"",browser:n.Unknown,browserVersion:"",renderer:function(){if(void 0===globalThis.document)return"";var e=globalThis.document.createElement("canvas");if("function"!=typeof e.getContext)return"";var i=e.getContext("webgl2")||e.getContext("experimental-webgl")||e.getContext("webgl");if(null===i)return"";if(i instanceof WebGLRenderingContext||"getParameter"in i&&"function"==typeof i.getParameter){var o=i.getExtension("WEBGL_debug_renderer_info");return null===o?i.getParameter(i.RENDERER):i.getParameter(o.UNMASKED_RENDERER_WEBGL)}return""}(),userAgent:navigator.userAgent,isWebview:!1,isMobile:!1,isDesktop:!1,isStandalone:!1,isNodeJS:void 0!==globalThis.process&&void 0!==globalThis.process.versions&&void 0!==globalThis.process.versions.node},t=[[/windows nt (6\.[23]); arm/i,e.Windows,l],[/windows (?:phone|mobile|iot)(?: os)?[\/ ]?([\d.]*( se)?)/i,e.Windows,l],[/windows[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i,e.Windows,l],[/windows nt ?([\d.)]*)(?!.+xbox)/i,e.Windows,l],[/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d.;]*)/i,e.Windows,l],[/windows ce\/?([\d.]*)/i,e.Windows,l],[/[adehimnop]{4,7}\b(?:.*os (\w+) like mac|; opera)/i,e.iOS,d],[/(?:ios;fbsv|ios(?=.+ip(?:ad|hone))|ip(?:ad|hone)(?: |.+i(?:pad)?)os)[\/ ]([\w.]+)/i,e.iOS,d],[/cfnetwork\/.+darwin/i,e.iOS,d],[/mac os x ?([\w. ]*)/i,e.MacOS,d],[/(?:macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i,e.MacOS,d],[/droid ([\w.]+)\b.+(android[- ]x86)/i,e.Android],[/android\w*[-\/.; ]?([\d.]*)/i,e.Android]],a=[[/windows.+ edge\/([\w.]+)/i,o.EdgeHTML],[/arkweb\/([\w.]+)/i,o.ArkWeb],[/webkit\/537\.36.+chrome\/(?!27)([\w.]+)/i,o.Blink],[/presto\/([\w.]+)/i,o.Presto],[/webkit\/([\w.]+)/i,o.WebKit],[/trident\/([\w.]+)/i,o.Trident],[/netfront\/([\w.]+)/i,o.NetFront],[/khtml[\/ ]\(?([\w.]+)/i,o.KHTML],[/tasman[\/ ]\(?([\w.]+)/i,o.Tasman],[/rv:([\w.]{1,9})\b.+gecko/i,o.Gecko]],s=[[/\b(?:crmo|crios)\/([\w.]+)/i,n.Chrome],[/webview.+edge\/([\w.]+)/i,n.Edge],[/edg(?:e|ios|a)?\/([\w.]+)/i,n.Edge],[/opera mini\/([-\w.]+)/i,n.Opera],[/opera [mobileta]{3,6}\b.+version\/([-\w.]+)/i,n.Opera],[/opera(?:.+version\/|[\/ ]+)([\w.]+)/i,n.Opera],[/opios[\/ ]+([\w.]+)/i,n.Opera],[/\bop(?:rg)?x\/([\w.]+)/i,n.Opera],[/\bopr\/([\w.]+)/i,n.Opera],[/iemobile(?:browser|boat|jet)[\/ ]?([\d.]*)/i,n.IE],[/(?:ms|\()ie ([\w.]+)/i,n.IE],[/trident.+rv[: ]([\w.]{1,9})\b.+like gecko/i,n.IE],[/\bfocus\/([\w.]+)/i,n.Firefox],[/\bopt\/([\w.]+)/i,n.Opera],[/coast\/([\w.]+)/i,n.Opera],[/fxios\/([\w.-]+)/i,n.Firefox],[/samsungbrowser\/([\w.]+)/i,n.SamsungInternet],[/headlesschrome(?:\/([\w.]+)| )/i,n.Chrome],[/wv\).+chrome\/([\w.]+).+edgw\//i,n.Edge],[/ wv\).+(chrome)\/([\w.]+)/i,n.Chrome],[/chrome\/([\w.]+) mobile/i,n.Chrome],[/chrome\/v?([\w.]+)/i,n.Chrome],[/version\/([\w.,]+) .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/iphone .*mobile(?:\/\w+ | ?)safari/i,n.Safari],[/version\/([\w.,]+) .*safari/i,n.Safari],[/webkit.+?(?:mobile ?safari|safari)(\/[\w.]+)/i,n.Safari,"1"],[/(?:mobile|tablet);.*firefox\/([\w.-]+)/i,n.Firefox],[/mobile vr; rv:([\w.]+)\).+firefox/i,n.Firefox],[/firefox\/([\w.]+)/i,n.Firefox]];function l(e){if(void 0===e)return"";var i={"4.90":"ME","NT3.51":"NT 3.11","NT4.0":"NT 4.0","NT 5.0":"2000","NT 5.1":"XP","NT 5.2":"XP","NT 6.0":"Vista","NT 6.1":"7","NT 6.2":"8","NT 6.3":"8.1","NT 6.4":"10","NT 10.0":"10",ARM:"RT"}[e];return void 0!==i?i:e}function d(e){return void 0===e?"":e.replace(/_/g,".")}function m(e,i){return"function"==typeof i?i(e):"string"==typeof i?i:void 0===e?"":e}for(var c=0;c<t.length;c++){var w=(p=t[c])[0],u=p[1],f=p[2];if(null!==(g=r.userAgent.match(w))){r.os=u,r.osVersion=m(g[1],f),u===e.iOS||u===e.Android?r.device=i.Mobile:u!==e.Windows&&u!==e.MacOS||(r.device=i.Desktop);break}}for(c=0;c<a.length;c++){w=(p=a[c])[0];var b=p[1];f=p[2];if(null!==(g=r.userAgent.match(w))){r.engine=b,r.engineVersion=m(g[1],f);break}}for(c=0;c<s.length;c++){w=(p=s[c])[0];var p,g,h=p[1];f=p[2];if(null!==(g=r.userAgent.match(w))){r.browser=h,r.browserVersion=m(g[1],f);break}}if("undefined"!=typeof navigator&&"ReactNative"===navigator.product)try{import("react-native").then((function(e){console.log(e.Platform)}))}catch(e){}else r.isNodeJS&&function(e){if("require"in globalThis&&"function"==typeof globalThis.require)try{return Promise.resolve(globalThis.require(e))}catch(e){return Promise.resolve(null)}return Promise.resolve(null)}("os").then((function(i){if(null!==i){var o,n=i.platform(),t=i.release(),a=(o=t.split("."),{major:parseInt(o[0]||"0"),minor:parseInt(o[1]||"0"),build:parseInt(o[2]||"0")});switch(n){case"win32":r.os=e.Windows,r.osVersion=10===a.major&&0===a.minor&&a.build>=22e3?"11":10===a.major&&0===a.minor&&a.build<22e3?"10":6===a.major&&3===a.minor?"8.1":6===a.major&&2===a.minor?"8":6===a.major&&1===a.minor?"7":6===a.major&&0===a.minor?"Vista":5===a.major&&1===a.minor||5===a.major&&2===a.minor?"XP":5===a.major&&0===a.minor?"2000":4===a.major&&90===a.minor?"ME":4===a.major&&0===a.minor?"NT 4.0":3===a.major&&51===a.minor?"NT 3.11":t;break;case"darwin":r.os=e.MacOS,r.osVersion=a.major>=24?a.major-9+"."+a.minor+"."+a.build:23===a.major?"14."+a.minor+"."+a.build:22===a.major?"13."+a.minor+"."+a.build:21===a.major?"12."+a.minor+"."+a.build:20===a.major?"11."+a.minor+"."+a.build:19===a.major?"10.15."+a.minor:18===a.major?"10.14."+a.minor:17===a.major?"10.13."+a.minor:16===a.major?"10.12."+a.minor:15===a.major?"10.11."+a.minor:14===a.major?"10.10."+a.minor:13===a.major?"10.9."+a.minor:a.major>=5&&a.major<=12?"10."+(a.major-4)+"."+a.minor:t;break;case"android":r.os=e.Android,r.osVersion=t;break;case"linux":/android/i.test(t)&&(r.os=e.Android,r.osVersion=t)}}}));function v(i){var o,n=function(){try{if(globalThis.top&&globalThis.top!==window)return globalThis.top.location.href,globalThis.top}catch(e){}return window}(),t=n.document;try{if(void 0===(o=function(e,i){if(void 0===i&&(i=!0),void 0!==globalThis.document){var o=globalThis.document.createElement(e);return"width"in o&&(o.width="0"),"height"in o&&(o.height="0"),"border"in o&&(o.border="0"),"frameBorder"in o&&(o.frameBorder="0"),"scrolling"in o&&(o.scrolling="no"),"cellPadding"in o&&(o.cellPadding="0"),"cellSpacing"in o&&(o.cellSpacing="0"),"frame"in o&&(o.frame="void"),"rules"in o&&(o.rules="none"),"noWrap"in o&&(o.noWrap=!0),o.tabIndex=-1,o.setAttribute("role","presentation"),i?(o.style.width="1px",o.style.height="1px"):(o.setAttribute("aria-hidden","true"),o.style.width="0",o.style.height="0",o.style.zIndex="-9999",o.style.display="none",o.style.visibility="hidden",o.style.pointerEvents="none"),o.style.position="absolute",o.style.top="0",o.style.left="0",o.style.padding="0",o.style.margin="0",o.style.border="none",o.style.outline="none",o.style.clip="rect(1px, 1px, 1px, 1px)",o.style.clipPath="inset(50%)",o.style.overflow="hidden",o.style.whiteSpace="nowrap",o}}("input")))return;if(o.type="file",o.tabIndex=-1,o.accept=i+"/*","capture"in HTMLInputElement.prototype)o.capture="user";else if(r.os===e.Android){var a="";"image"===i?a="camera":"video"===i&&(a="camcorder"),o.accept=i+"/*;capture="+a}t.body.appendChild(o),function(e,i){var o;void 0===i&&(i=window);try{o=new MouseEvent("click",{bubbles:!0,cancelable:!0,view:i})}catch(e){(o=globalThis.document.createEvent("MouseEvents")).initMouseEvent("click",!0,!0,i,0,0,0,0,0,!1,!1,!1,!1,0,null)}e.dispatchEvent(o)}(o,n)}catch(e){}}void 0!==navigator.userAgentData&&void 0!==navigator.userAgentData.getHighEntropyValues&&navigator.userAgentData.getHighEntropyValues(["brands","fullVersionList","mobile","model","platform","platformVersion","architecture","formFactors","bitness","uaFullVersion","wow64"]).then((function(i){for(var o,n=i.fullVersionList||i.brands||[],t=i.platformVersion,a=0;a<n.length;a++){var s=null==(o=n[a])?{brand:"",version:""}:"string"==typeof o?{brand:o,version:""}:{brand:o.brand,version:o.version},l=s.brand,d=s.version;/not.a.brand/i.test(l)||"Chromium"===l&&(r.engineVersion=d)}"string"==typeof t&&(r.os===e.Windows&&parseInt(t.replace(/[^\d.]/g,"").split(".")[0],10)>=13?r.osVersion="11":r.osVersion=t)})),r.isMobile=r.device===i.Mobile,r.isDesktop=r.device===i.Desktop,r.isWebview=/; ?wv|applewebkit(?!.*safari)/i.test(r.userAgent),r.isStandalone=function(i){return"matchMedia"in globalThis&&(i===e.iOS?"standalone"in navigator&&!!navigator.standalone:globalThis.matchMedia("(display-mode: standalone)").matches)}(r.os);var T,k={open:function(i){switch(r.os){case e.Android:v(i);break;case e.iOS:(function(e,i){for(var o=e.split("."),n=i.split("."),r=Math.max(o.length,n.length),t=0;t<r;t++){var a=void 0,s=void 0;if((a=t<o.length?parseInt(o[t],10):0)>(s=t<n.length?parseInt(n[t],10):0))return 1;if(a<s)return-1}return 0})(r.osVersion,"10.3")>=0?v(i):alert(r.osVersion);case e.Windows:case e.MacOS:}}};return function(e){e.Image="image",e.Video="video"}(T||(T={})),{installed:!1,name:"Camera",module:k,Constants:{CameraType:T},Errors:{}}}));
@@ -20,6 +20,10 @@ export declare interface MacOSAppInfo extends AppInfo {
20
20
  bundleId?: string;
21
21
  trackId?: string;
22
22
  }
23
+ export declare interface StoreInfo {
24
+ appStore?: string;
25
+ webStore?: string;
26
+ }
23
27
  export declare interface AppOpenOptions {
24
28
  [OS.Android]?: AndroidAppInfo;
25
29
  [OS.iOS]?: IOSAppInfo;
@@ -0,0 +1 @@
1
+ export default function require<T = any>(moduleName: string): Promise<T | null>;
@@ -20,6 +20,10 @@ export declare interface MacOSAppInfo extends AppInfo {
20
20
  bundleId?: string;
21
21
  trackId?: string;
22
22
  }
23
+ export declare interface StoreInfo {
24
+ appStore?: string;
25
+ webStore?: string;
26
+ }
23
27
  export declare interface AppOpenOptions {
24
28
  [OS.Android]?: AndroidAppInfo;
25
29
  [OS.iOS]?: IOSAppInfo;
@@ -0,0 +1 @@
1
+ export default function require<T = any>(moduleName: string): Promise<T | null>;
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- function dynamicImport(moduleName) {
3
+ function require$1(moduleName) {
4
4
  if ('require' in globalThis && typeof globalThis.require === 'function') {
5
5
  try {
6
6
  return Promise.resolve(globalThis.require(moduleName));
@@ -9,13 +9,7 @@ function dynamicImport(moduleName) {
9
9
  return Promise.resolve(null);
10
10
  }
11
11
  }
12
- return import(moduleName)
13
- .then(function (module) {
14
- return (module.default || module);
15
- })
16
- .catch(function () {
17
- return Promise.resolve(null);
18
- });
12
+ return Promise.resolve(null);
19
13
  }
20
14
 
21
15
  var OS;
@@ -255,8 +249,18 @@ for (var i = 0; i < BROWSER_RESOLVER_MAP.length; i++) {
255
249
  break;
256
250
  }
257
251
  }
258
- if (Platform.isNodeJS) {
259
- dynamicImport('os')
252
+ if (typeof navigator !== 'undefined' && navigator.product === 'ReactNative') {
253
+ try {
254
+ import('react-native')
255
+ .then(function (reactNative) {
256
+ console.log(reactNative.Platform);
257
+ });
258
+ }
259
+ catch (_) {
260
+ }
261
+ }
262
+ else if (Platform.isNodeJS) {
263
+ require$1('os')
260
264
  .then(function (os) {
261
265
  if (os === null)
262
266
  return;
@@ -296,31 +300,31 @@ if (Platform.isNodeJS) {
296
300
  case 'darwin':
297
301
  Platform.os = OS.MacOS;
298
302
  if (version.major >= 24)
299
- Platform.osVersion = '' + (version.major - 9);
303
+ Platform.osVersion = '' + (version.major - 9) + '.' + version.minor + '.' + version.build;
300
304
  else if (version.major === 23)
301
- Platform.osVersion = '14';
305
+ Platform.osVersion = '14.' + version.minor + '.' + version.build;
302
306
  else if (version.major === 22)
303
- Platform.osVersion = '13';
307
+ Platform.osVersion = '13.' + version.minor + '.' + version.build;
304
308
  else if (version.major === 21)
305
- Platform.osVersion = '12';
309
+ Platform.osVersion = '12.' + version.minor + '.' + version.build;
306
310
  else if (version.major === 20)
307
- Platform.osVersion = '11';
311
+ Platform.osVersion = '11.' + version.minor + '.' + version.build;
308
312
  else if (version.major === 19)
309
- Platform.osVersion = '10.15';
313
+ Platform.osVersion = '10.15.' + version.minor;
310
314
  else if (version.major === 18)
311
- Platform.osVersion = '10.14';
315
+ Platform.osVersion = '10.14.' + version.minor;
312
316
  else if (version.major === 17)
313
- Platform.osVersion = '10.13';
317
+ Platform.osVersion = '10.13.' + version.minor;
314
318
  else if (version.major === 16)
315
- Platform.osVersion = '10.12';
319
+ Platform.osVersion = '10.12.' + version.minor;
316
320
  else if (version.major === 15)
317
- Platform.osVersion = '10.11';
321
+ Platform.osVersion = '10.11.' + version.minor;
318
322
  else if (version.major === 14)
319
- Platform.osVersion = '10.10';
323
+ Platform.osVersion = '10.10.' + version.minor;
320
324
  else if (version.major === 13)
321
- Platform.osVersion = '10.9';
325
+ Platform.osVersion = '10.9.' + version.minor;
322
326
  else if (version.major >= 5 && version.major <= 12)
323
- Platform.osVersion = '10.' + (version.major - 4);
327
+ Platform.osVersion = '10.' + (version.major - 4) + '.' + version.minor;
324
328
  else
325
329
  Platform.osVersion = release;
326
330
  break;