@vkontakte/vk-bridge
Advanced tools
Comparing version 2.6.4 to 2.7.0
@@ -1,2 +0,2 @@ | ||
!function(){"use strict";var a=function(){return(a=Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var p in t=arguments[n])Object.prototype.hasOwnProperty.call(t,p)&&(e[p]=t[p]);return e}).apply(this,arguments)};function d(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var o=Array(e),p=0;for(t=0;t<n;t++)for(var r=arguments[t],i=0,a=r.length;i<a;i++,p++)o[p]=r[i];return o}function b(r,e){var o,p,i=(o={current:0,next:function(){return++this.current}},p={},{add:function(e,t){var n=null!=t?t:o.next();return p[n]=e,n},resolve:function(e,t,n){var o=p[e];o&&(n(t)?o.resolve(t):o.reject(t),p[e]=null)}});return e(function(e){if(e.detail&&e.detail.data&&"object"==typeof e.detail.data&&"request_id"in e.detail.data){var t=e.detail.data,n=t.request_id,o=function(e,t){var n={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var p=0;for(o=Object.getOwnPropertySymbols(e);p<o.length;p++)t.indexOf(o[p])<0&&Object.prototype.propertyIsEnumerable.call(e,o[p])&&(n[o[p]]=e[o[p]])}return n}(t,["request_id"]);n&&i.resolve(n,o,function(e){return!("error_type"in e)})}}),function(o,p){return void 0===p&&(p={}),new Promise(function(e,t){var n=i.add({resolve:e,reject:t},p.request_id);r(o,a(a({},p),{request_id:n}))})}}var e="undefined"!=typeof window,u=Boolean(e&&window.AndroidBridge),l=Boolean(e&&window.webkit&&window.webkit.messageHandlers&&window.webkit.messageHandlers.VKWebAppClose),A=Boolean(e&&window.ReactNativeWebView&&"function"==typeof window.ReactNativeWebView.postMessage),c=e&&!u&&!l,t=c&&/(^\?|&)vk_platform=mobile_web(&|$)/.test(location.search),w=c?"message":"VKWebAppEvent",f=d(["VKWebAppInit","VKWebAppGetCommunityAuthToken","VKWebAppAddToCommunity","VKWebAppAddToHomeScreenInfo","VKWebAppClose","VKWebAppCopyText","VKWebAppCreateHash","VKWebAppGetUserInfo","VKWebAppSetLocation","VKWebAppSendToClient","VKWebAppGetClientVersion","VKWebAppGetPhoneNumber","VKWebAppGetEmail","VKWebAppGetGroupInfo","VKWebAppGetGeodata","VKWebAppGetCommunityToken","VKWebAppGetConfig","VKWebAppGetLaunchParams","VKWebAppSetTitle","VKWebAppGetAuthToken","VKWebAppCallAPIMethod","VKWebAppJoinGroup","VKWebAppLeaveGroup","VKWebAppAllowMessagesFromGroup","VKWebAppDenyNotifications","VKWebAppAllowNotifications","VKWebAppOpenPayForm","VKWebAppOpenApp","VKWebAppShare","VKWebAppShowWallPostBox","VKWebAppScroll","VKWebAppShowOrderBox","VKWebAppShowLeaderBoardBox","VKWebAppShowInviteBox","VKWebAppShowRequestBox","VKWebAppAddToFavorites","VKWebAppShowCommunityWidgetPreviewBox","VKWebAppShowStoryBox","VKWebAppStorageGet","VKWebAppStorageGetKeys","VKWebAppStorageSet","VKWebAppFlashGetInfo","VKWebAppSubscribeStoryApp","VKWebAppOpenWallPost","VKWebAppCheckAllowedScopes","VKWebAppCheckNativeAds","VKWebAppShowNativeAds","VKWebAppRetargetingPixel","VKWebAppConversionHit","VKWebAppShowSubscriptionBox","VKWebAppCheckSurvey","VKWebAppShowSurvey"],c&&!t?["VKWebAppResizeWindow","VKWebAppAddToMenu","VKWebAppShowInstallPushBox","VKWebAppGetFriends"]:["VKWebAppShowImages"]),W=e?window.AndroidBridge:void 0,V=l?window.webkit.messageHandlers:void 0,K=c?parent:void 0;var n,o,p,r,i,s,v,m,S,y;function h(e,t){var n=t||{bubbles:!1,cancelable:!1,detail:void 0},o=document.createEvent("CustomEvent");return o.initCustomEvent(e,!!n.bubbles,!!n.cancelable,n.detail),o}(o=n=n||{}).REWARD="reward",o.INTERSTITIAL="interstitial",(r=p=p||{}).CAMERA="camera",r.LOCATION="location",r.PHOTO="photo",(s=i=i||{}).RU="ru",s.UK="uk",s.UA="ua",s.EN="en",s.BE="be",s.KZ="kz",s.PT="pt",s.ES="es",(m=v=v||{}).ADMIN="admin",m.EDITOR="editor",m.MEMBER="member",m.MODER="moder",m.NONE="none",(y=S=S||{}).DESKTOP_WEB="desktop_web",y.MOBILE_WEB="mobile_web",y.MOBILE_ANDROID="mobile_android",y.MOBILE_ANDROID_MESSENGER="mobile_android_messenger",y.MOBILE_IPHONE="mobile_iphone",y.MOBILE_IPHONE_MESSENGER="mobile_iphone_messenger",y.MOBILE_IPAD="mobile_ipad","undefined"==typeof window||window.CustomEvent||(window.CustomEvent=(h.prototype=Event.prototype,h));var E=function(n){var r=void 0,i=[];function e(e){i.push(e)}function t(){return l||u}function o(){return c&&window.parent!==window}function p(){return t()||o()}function a(t){if(l||u)return d(i).map(function(e){return e.call(null,t)});var e=null==t?void 0:t.data;if(c&&e){if(A&&"string"==typeof e)try{e=JSON.parse(e)}catch(e){}var n=e.type,o=e.data,p=e.frameId;n&&("SetSupportedHandlers"!==n?"VKWebAppSettings"!==n?d(i).map(function(e){return e({detail:{type:n,data:o}})}):r=p:o.supportedHandlers)}}A&&/(android)/i.test(navigator.userAgent)?document.addEventListener(w,a):"undefined"!=typeof window&&"addEventListener"in window&&window.addEventListener(w,a);var s=b(function(e,t){W&&W[e]?W[e](JSON.stringify(t)):V&&V[e]&&"function"==typeof V[e].postMessage?V[e].postMessage(t):A?window.ReactNativeWebView.postMessage(JSON.stringify({handler:e,params:t})):K&&"function"==typeof K.postMessage&&K.postMessage({handler:e,params:t,type:"vk-connect",webFrameId:r,connectVersion:n},"*")},e);return{send:s,sendPromise:s,subscribe:e,unsubscribe:function(e){var t=i.indexOf(e);-1<t&&i.splice(t,1)},supports:function(e){return u?!(!W||"function"!=typeof W[e]):l?!(!V||!V[e]||"function"!=typeof V[e].postMessage):c&&-1<f.indexOf(e)},isWebView:t,isIframe:o,isEmbedded:p,isStandalone:function(){return!p()}}}("2.6.4");window.vkBridge=window.vkConnect=E}(); | ||
!function(){"use strict";var a=function(){return(a=Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var p in t=arguments[n])Object.prototype.hasOwnProperty.call(t,p)&&(e[p]=t[p]);return e}).apply(this,arguments)};function d(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var o=Array(e),p=0;for(t=0;t<n;t++)for(var r=arguments[t],i=0,a=r.length;i<a;i++,p++)o[p]=r[i];return o}function b(r,e){var o,p,i=(o={current:0,next:function(){return++this.current}},p={},{add:function(e,t){var n=null!=t?t:o.next();return p[n]=e,n},resolve:function(e,t,n){var o=p[e];o&&(n(t)?o.resolve(t):o.reject(t),p[e]=null)}});return e(function(e){if(e.detail&&e.detail.data&&"object"==typeof e.detail.data&&"request_id"in e.detail.data){var t=e.detail.data,n=t.request_id,o=function(e,t){var n={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var p=0;for(o=Object.getOwnPropertySymbols(e);p<o.length;p++)t.indexOf(o[p])<0&&Object.prototype.propertyIsEnumerable.call(e,o[p])&&(n[o[p]]=e[o[p]])}return n}(t,["request_id"]);n&&i.resolve(n,o,function(e){return!("error_type"in e)})}}),function(o,p){return void 0===p&&(p={}),new Promise(function(e,t){var n=i.add({resolve:e,reject:t},p.request_id);r(o,a(a({},p),{request_id:n}))})}}var e="undefined"!=typeof window,u=Boolean(e&&window.AndroidBridge),l=Boolean(e&&window.webkit&&window.webkit.messageHandlers&&window.webkit.messageHandlers.VKWebAppClose),A=Boolean(e&&window.ReactNativeWebView&&"function"==typeof window.ReactNativeWebView.postMessage),c=e&&!u&&!l,t=c&&/(^\?|&)vk_platform=mobile_web(&|$)/.test(location.search),w=c?"message":"VKWebAppEvent",f=d(["VKWebAppInit","VKWebAppGetCommunityAuthToken","VKWebAppAddToCommunity","VKWebAppAddToHomeScreenInfo","VKWebAppClose","VKWebAppCopyText","VKWebAppCreateHash","VKWebAppGetUserInfo","VKWebAppSetLocation","VKWebAppSendToClient","VKWebAppGetClientVersion","VKWebAppGetPhoneNumber","VKWebAppGetEmail","VKWebAppGetGroupInfo","VKWebAppGetGeodata","VKWebAppGetCommunityToken","VKWebAppGetConfig","VKWebAppGetLaunchParams","VKWebAppSetTitle","VKWebAppGetAuthToken","VKWebAppCallAPIMethod","VKWebAppJoinGroup","VKWebAppLeaveGroup","VKWebAppAllowMessagesFromGroup","VKWebAppDenyNotifications","VKWebAppAllowNotifications","VKWebAppOpenPayForm","VKWebAppOpenApp","VKWebAppShare","VKWebAppShowWallPostBox","VKWebAppScroll","VKWebAppShowOrderBox","VKWebAppShowLeaderBoardBox","VKWebAppShowInviteBox","VKWebAppShowRequestBox","VKWebAppAddToFavorites","VKWebAppShowCommunityWidgetPreviewBox","VKWebAppShowStoryBox","VKWebAppStorageGet","VKWebAppStorageGetKeys","VKWebAppStorageSet","VKWebAppFlashGetInfo","VKWebAppSubscribeStoryApp","VKWebAppOpenWallPost","VKWebAppCheckAllowedScopes","VKWebAppCheckNativeAds","VKWebAppShowNativeAds","VKWebAppRetargetingPixel","VKWebAppConversionHit","VKWebAppShowSubscriptionBox","VKWebAppCheckSurvey","VKWebAppShowSurvey","VKWebAppScrollTop","VKWebAppScrollTopStart","VKWebAppScrollTopStop"],c&&!t?["VKWebAppResizeWindow","VKWebAppAddToMenu","VKWebAppShowInstallPushBox","VKWebAppGetFriends"]:["VKWebAppShowImages"]),W=e?window.AndroidBridge:void 0,V=l?window.webkit.messageHandlers:void 0,K=c?parent:void 0;var n,o,p,r,i,s,v,m,S,y;function h(e,t){var n=t||{bubbles:!1,cancelable:!1,detail:void 0},o=document.createEvent("CustomEvent");return o.initCustomEvent(e,!!n.bubbles,!!n.cancelable,n.detail),o}(o=n=n||{}).REWARD="reward",o.INTERSTITIAL="interstitial",(r=p=p||{}).CAMERA="camera",r.LOCATION="location",r.PHOTO="photo",(s=i=i||{}).RU="ru",s.UK="uk",s.UA="ua",s.EN="en",s.BE="be",s.KZ="kz",s.PT="pt",s.ES="es",(m=v=v||{}).ADMIN="admin",m.EDITOR="editor",m.MEMBER="member",m.MODER="moder",m.NONE="none",(y=S=S||{}).DESKTOP_WEB="desktop_web",y.MOBILE_WEB="mobile_web",y.MOBILE_ANDROID="mobile_android",y.MOBILE_ANDROID_MESSENGER="mobile_android_messenger",y.MOBILE_IPHONE="mobile_iphone",y.MOBILE_IPHONE_MESSENGER="mobile_iphone_messenger",y.MOBILE_IPAD="mobile_ipad","undefined"==typeof window||window.CustomEvent||(window.CustomEvent=(h.prototype=Event.prototype,h));var E=function(n){var r=void 0,i=[];function e(e){i.push(e)}function t(){return l||u}function o(){return c&&window.parent!==window}function p(){return t()||o()}function a(t){if(l||u)return d(i).map(function(e){return e.call(null,t)});var e=null==t?void 0:t.data;if(c&&e){if(A&&"string"==typeof e)try{e=JSON.parse(e)}catch(e){}var n=e.type,o=e.data,p=e.frameId;n&&("SetSupportedHandlers"!==n?"VKWebAppSettings"!==n?d(i).map(function(e){return e({detail:{type:n,data:o}})}):r=p:o.supportedHandlers)}}A&&/(android)/i.test(navigator.userAgent)?document.addEventListener(w,a):"undefined"!=typeof window&&"addEventListener"in window&&window.addEventListener(w,a);var s=b(function(e,t){W&&W[e]?W[e](JSON.stringify(t)):V&&V[e]&&"function"==typeof V[e].postMessage?V[e].postMessage(t):A?window.ReactNativeWebView.postMessage(JSON.stringify({handler:e,params:t})):K&&"function"==typeof K.postMessage&&K.postMessage({handler:e,params:t,type:"vk-connect",webFrameId:r,connectVersion:n},"*")},e);return{send:s,sendPromise:s,subscribe:e,unsubscribe:function(e){var t=i.indexOf(e);-1<t&&i.splice(t,1)},supports:function(e){return u?!(!W||"function"!=typeof W[e]):l?!(!V||!V[e]||"function"!=typeof V[e].postMessage):c&&-1<f.indexOf(e)},isWebView:t,isIframe:o,isEmbedded:p,isStandalone:function(){return!p()}}}("2.7.0");window.vkBridge=window.vkConnect=E}(); | ||
//# sourceMappingURL=browser.min.js.map |
@@ -203,3 +203,6 @@ /*! ***************************************************************************** | ||
'VKWebAppCheckSurvey', | ||
'VKWebAppShowSurvey' | ||
'VKWebAppShowSurvey', | ||
'VKWebAppScrollTop', | ||
'VKWebAppScrollTopStart', | ||
'VKWebAppScrollTopStop' | ||
], (IS_DESKTOP_VK ? ['VKWebAppResizeWindow', 'VKWebAppAddToMenu', 'VKWebAppShowInstallPushBox', 'VKWebAppGetFriends'] : ['VKWebAppShowImages'])); | ||
@@ -412,3 +415,3 @@ /** Android VK Bridge interface. */ | ||
var version = "2.6.4"; | ||
var version = "2.7.0"; | ||
@@ -415,0 +418,0 @@ var EAdsFormats; |
@@ -1,2 +0,2 @@ | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var __assign=function(){return(__assign=Object.assign||function(e){for(var n,t=1,r=arguments.length;t<r;t++)for(var o in n=arguments[t])Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o]);return e}).apply(this,arguments)};function __rest(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)n.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(t[r[o]]=e[r[o]])}return t}function __spreadArrays(){for(var e=0,n=0,t=arguments.length;n<t;n++)e+=arguments[n].length;var r=Array(e),o=0;for(n=0;n<t;n++)for(var i=arguments[n],p=0,a=i.length;p<a;p++,o++)r[o]=i[p];return r}function createCounter(){return{current:0,next:function(){return++this.current}}}function createRequestResolver(){var r=createCounter(),o={};return{add:function(e,n){var t=null!=n?n:r.next();return o[t]=e,t},resolve:function(e,n,t){var r=o[e];r&&(t(n)?r.resolve(n):r.reject(n),o[e]=null)}}}function promisifySend(i,e){var p=createRequestResolver();return e(function(e){if(e.detail&&e.detail.data&&"object"==typeof e.detail.data&&"request_id"in e.detail.data){var n=e.detail.data,t=n.request_id,r=__rest(n,["request_id"]);t&&p.resolve(t,r,function(e){return!("error_type"in e)})}}),function(r,o){return void 0===o&&(o={}),new Promise(function(e,n){var t=p.add({resolve:e,reject:n},o.request_id);i(r,__assign(__assign({},o),{request_id:t}))})}}var webSdkHandlers,IS_CLIENT_SIDE="undefined"!=typeof window,IS_ANDROID_WEBVIEW=Boolean(IS_CLIENT_SIDE&&window.AndroidBridge),IS_IOS_WEBVIEW=Boolean(IS_CLIENT_SIDE&&window.webkit&&window.webkit.messageHandlers&&window.webkit.messageHandlers.VKWebAppClose),IS_REACT_NATIVE_WEBVIEW=Boolean(IS_CLIENT_SIDE&&window.ReactNativeWebView&&"function"==typeof window.ReactNativeWebView.postMessage),IS_WEB=IS_CLIENT_SIDE&&!IS_ANDROID_WEBVIEW&&!IS_IOS_WEBVIEW,IS_MVK=IS_WEB&&/(^\?|&)vk_platform=mobile_web(&|$)/.test(location.search),IS_DESKTOP_VK=IS_WEB&&!IS_MVK,EVENT_TYPE=IS_WEB?"message":"VKWebAppEvent",DESKTOP_METHODS=__spreadArrays(["VKWebAppInit","VKWebAppGetCommunityAuthToken","VKWebAppAddToCommunity","VKWebAppAddToHomeScreenInfo","VKWebAppClose","VKWebAppCopyText","VKWebAppCreateHash","VKWebAppGetUserInfo","VKWebAppSetLocation","VKWebAppSendToClient","VKWebAppGetClientVersion","VKWebAppGetPhoneNumber","VKWebAppGetEmail","VKWebAppGetGroupInfo","VKWebAppGetGeodata","VKWebAppGetCommunityToken","VKWebAppGetConfig","VKWebAppGetLaunchParams","VKWebAppSetTitle","VKWebAppGetAuthToken","VKWebAppCallAPIMethod","VKWebAppJoinGroup","VKWebAppLeaveGroup","VKWebAppAllowMessagesFromGroup","VKWebAppDenyNotifications","VKWebAppAllowNotifications","VKWebAppOpenPayForm","VKWebAppOpenApp","VKWebAppShare","VKWebAppShowWallPostBox","VKWebAppScroll","VKWebAppShowOrderBox","VKWebAppShowLeaderBoardBox","VKWebAppShowInviteBox","VKWebAppShowRequestBox","VKWebAppAddToFavorites","VKWebAppShowCommunityWidgetPreviewBox","VKWebAppShowStoryBox","VKWebAppStorageGet","VKWebAppStorageGetKeys","VKWebAppStorageSet","VKWebAppFlashGetInfo","VKWebAppSubscribeStoryApp","VKWebAppOpenWallPost","VKWebAppCheckAllowedScopes","VKWebAppCheckNativeAds","VKWebAppShowNativeAds","VKWebAppRetargetingPixel","VKWebAppConversionHit","VKWebAppShowSubscriptionBox","VKWebAppCheckSurvey","VKWebAppShowSurvey"],IS_DESKTOP_VK?["VKWebAppResizeWindow","VKWebAppAddToMenu","VKWebAppShowInstallPushBox","VKWebAppGetFriends"]:["VKWebAppShowImages"]),androidBridge=IS_CLIENT_SIDE?window.AndroidBridge:void 0,iosBridge=IS_IOS_WEBVIEW?window.webkit.messageHandlers:void 0,webBridge=IS_WEB?parent:void 0;function createVKBridge(t){var i=void 0,p=[];function e(e){p.push(e)}function n(){return IS_IOS_WEBVIEW||IS_ANDROID_WEBVIEW}function r(){return IS_WEB&&window.parent!==window}function o(){return n()||r()}function a(n){if(IS_IOS_WEBVIEW||IS_ANDROID_WEBVIEW)return __spreadArrays(p).map(function(e){return e.call(null,n)});var e=null==n?void 0:n.data;if(IS_WEB&&e){if(IS_REACT_NATIVE_WEBVIEW&&"string"==typeof e)try{e=JSON.parse(e)}catch(e){}var t=e.type,r=e.data,o=e.frameId;t&&("SetSupportedHandlers"!==t?"VKWebAppSettings"!==t?__spreadArrays(p).map(function(e){return e({detail:{type:t,data:r}})}):i=o:webSdkHandlers=r.supportedHandlers)}}IS_REACT_NATIVE_WEBVIEW&&/(android)/i.test(navigator.userAgent)?document.addEventListener(EVENT_TYPE,a):"undefined"!=typeof window&&"addEventListener"in window&&window.addEventListener(EVENT_TYPE,a);var s=promisifySend(function(e,n){androidBridge&&androidBridge[e]?androidBridge[e](JSON.stringify(n)):iosBridge&&iosBridge[e]&&"function"==typeof iosBridge[e].postMessage?iosBridge[e].postMessage(n):IS_REACT_NATIVE_WEBVIEW?window.ReactNativeWebView.postMessage(JSON.stringify({handler:e,params:n})):webBridge&&"function"==typeof webBridge.postMessage&&webBridge.postMessage({handler:e,params:n,type:"vk-connect",webFrameId:i,connectVersion:t},"*")},e);return{send:s,sendPromise:s,subscribe:e,unsubscribe:function(e){var n=p.indexOf(e);-1<n&&p.splice(n,1)},supports:function(e){return IS_ANDROID_WEBVIEW?!(!androidBridge||"function"!=typeof androidBridge[e]):IS_IOS_WEBVIEW?!(!iosBridge||!iosBridge[e]||"function"!=typeof iosBridge[e].postMessage):!!IS_WEB&&-1<DESKTOP_METHODS.indexOf(e)},isWebView:n,isIframe:r,isEmbedded:o,isStandalone:function(){return!o()}}}function createCustomEventPolyfill(){function e(e,n){var t=n||{bubbles:!1,cancelable:!1,detail:void 0},r=document.createEvent("CustomEvent");return r.initCustomEvent(e,!!t.bubbles,!!t.cancelable,t.detail),r}return e.prototype=Event.prototype,e}var version="2.6.4";function applyMiddleware(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];return r.includes(void 0)||r.includes(null)?applyMiddleware.apply(void 0,r.filter(function(e){return"function"==typeof e})):function(t){if(0===r.length)return t;var e,n={subscribe:t.subscribe,send:function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return t.send.apply(t,e)}};return e=r.filter(function(e){return"function"==typeof e}).map(function(e){return e(n)}).reduce(function(n,t){return function(e){return n(t(e))}})(t.send),__assign(__assign({},t),{send:e})}}!function(e){e.REWARD="reward",e.INTERSTITIAL="interstitial"}(exports.EAdsFormats||(exports.EAdsFormats={})),function(e){e.CAMERA="camera",e.LOCATION="location",e.PHOTO="photo"}(exports.EGrantedPermission||(exports.EGrantedPermission={})),function(e){e.RU="ru",e.UK="uk",e.UA="ua",e.EN="en",e.BE="be",e.KZ="kz",e.PT="pt",e.ES="es"}(exports.EGetLaunchParamsResponseLanguages||(exports.EGetLaunchParamsResponseLanguages={})),function(e){e.ADMIN="admin",e.EDITOR="editor",e.MEMBER="member",e.MODER="moder",e.NONE="none"}(exports.EGetLaunchParamsResponseGroupRole||(exports.EGetLaunchParamsResponseGroupRole={})),function(e){e.DESKTOP_WEB="desktop_web",e.MOBILE_WEB="mobile_web",e.MOBILE_ANDROID="mobile_android",e.MOBILE_ANDROID_MESSENGER="mobile_android_messenger",e.MOBILE_IPHONE="mobile_iphone",e.MOBILE_IPHONE_MESSENGER="mobile_iphone_messenger",e.MOBILE_IPAD="mobile_ipad"}(exports.EGetLaunchParamsResponsePlatforms||(exports.EGetLaunchParamsResponsePlatforms={})),"undefined"==typeof window||window.CustomEvent||(window.CustomEvent=createCustomEventPolyfill());var bridge=createVKBridge(version);exports.applyMiddleware=applyMiddleware,exports.default=bridge; | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var __assign=function(){return(__assign=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function __rest(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}function __spreadArrays(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),o=0;for(t=0;t<n;t++)for(var i=arguments[t],p=0,a=i.length;p<a;p++,o++)r[o]=i[p];return r}function createCounter(){return{current:0,next:function(){return++this.current}}}function createRequestResolver(){var r=createCounter(),o={};return{add:function(e,t){var n=null!=t?t:r.next();return o[n]=e,n},resolve:function(e,t,n){var r=o[e];r&&(n(t)?r.resolve(t):r.reject(t),o[e]=null)}}}function promisifySend(i,e){var p=createRequestResolver();return e(function(e){if(e.detail&&e.detail.data&&"object"==typeof e.detail.data&&"request_id"in e.detail.data){var t=e.detail.data,n=t.request_id,r=__rest(t,["request_id"]);n&&p.resolve(n,r,function(e){return!("error_type"in e)})}}),function(r,o){return void 0===o&&(o={}),new Promise(function(e,t){var n=p.add({resolve:e,reject:t},o.request_id);i(r,__assign(__assign({},o),{request_id:n}))})}}var webSdkHandlers,IS_CLIENT_SIDE="undefined"!=typeof window,IS_ANDROID_WEBVIEW=Boolean(IS_CLIENT_SIDE&&window.AndroidBridge),IS_IOS_WEBVIEW=Boolean(IS_CLIENT_SIDE&&window.webkit&&window.webkit.messageHandlers&&window.webkit.messageHandlers.VKWebAppClose),IS_REACT_NATIVE_WEBVIEW=Boolean(IS_CLIENT_SIDE&&window.ReactNativeWebView&&"function"==typeof window.ReactNativeWebView.postMessage),IS_WEB=IS_CLIENT_SIDE&&!IS_ANDROID_WEBVIEW&&!IS_IOS_WEBVIEW,IS_MVK=IS_WEB&&/(^\?|&)vk_platform=mobile_web(&|$)/.test(location.search),IS_DESKTOP_VK=IS_WEB&&!IS_MVK,EVENT_TYPE=IS_WEB?"message":"VKWebAppEvent",DESKTOP_METHODS=__spreadArrays(["VKWebAppInit","VKWebAppGetCommunityAuthToken","VKWebAppAddToCommunity","VKWebAppAddToHomeScreenInfo","VKWebAppClose","VKWebAppCopyText","VKWebAppCreateHash","VKWebAppGetUserInfo","VKWebAppSetLocation","VKWebAppSendToClient","VKWebAppGetClientVersion","VKWebAppGetPhoneNumber","VKWebAppGetEmail","VKWebAppGetGroupInfo","VKWebAppGetGeodata","VKWebAppGetCommunityToken","VKWebAppGetConfig","VKWebAppGetLaunchParams","VKWebAppSetTitle","VKWebAppGetAuthToken","VKWebAppCallAPIMethod","VKWebAppJoinGroup","VKWebAppLeaveGroup","VKWebAppAllowMessagesFromGroup","VKWebAppDenyNotifications","VKWebAppAllowNotifications","VKWebAppOpenPayForm","VKWebAppOpenApp","VKWebAppShare","VKWebAppShowWallPostBox","VKWebAppScroll","VKWebAppShowOrderBox","VKWebAppShowLeaderBoardBox","VKWebAppShowInviteBox","VKWebAppShowRequestBox","VKWebAppAddToFavorites","VKWebAppShowCommunityWidgetPreviewBox","VKWebAppShowStoryBox","VKWebAppStorageGet","VKWebAppStorageGetKeys","VKWebAppStorageSet","VKWebAppFlashGetInfo","VKWebAppSubscribeStoryApp","VKWebAppOpenWallPost","VKWebAppCheckAllowedScopes","VKWebAppCheckNativeAds","VKWebAppShowNativeAds","VKWebAppRetargetingPixel","VKWebAppConversionHit","VKWebAppShowSubscriptionBox","VKWebAppCheckSurvey","VKWebAppShowSurvey","VKWebAppScrollTop","VKWebAppScrollTopStart","VKWebAppScrollTopStop"],IS_DESKTOP_VK?["VKWebAppResizeWindow","VKWebAppAddToMenu","VKWebAppShowInstallPushBox","VKWebAppGetFriends"]:["VKWebAppShowImages"]),androidBridge=IS_CLIENT_SIDE?window.AndroidBridge:void 0,iosBridge=IS_IOS_WEBVIEW?window.webkit.messageHandlers:void 0,webBridge=IS_WEB?parent:void 0;function createVKBridge(n){var i=void 0,p=[];function e(e){p.push(e)}function t(){return IS_IOS_WEBVIEW||IS_ANDROID_WEBVIEW}function r(){return IS_WEB&&window.parent!==window}function o(){return t()||r()}function a(t){if(IS_IOS_WEBVIEW||IS_ANDROID_WEBVIEW)return __spreadArrays(p).map(function(e){return e.call(null,t)});var e=null==t?void 0:t.data;if(IS_WEB&&e){if(IS_REACT_NATIVE_WEBVIEW&&"string"==typeof e)try{e=JSON.parse(e)}catch(e){}var n=e.type,r=e.data,o=e.frameId;n&&("SetSupportedHandlers"!==n?"VKWebAppSettings"!==n?__spreadArrays(p).map(function(e){return e({detail:{type:n,data:r}})}):i=o:webSdkHandlers=r.supportedHandlers)}}IS_REACT_NATIVE_WEBVIEW&&/(android)/i.test(navigator.userAgent)?document.addEventListener(EVENT_TYPE,a):"undefined"!=typeof window&&"addEventListener"in window&&window.addEventListener(EVENT_TYPE,a);var s=promisifySend(function(e,t){androidBridge&&androidBridge[e]?androidBridge[e](JSON.stringify(t)):iosBridge&&iosBridge[e]&&"function"==typeof iosBridge[e].postMessage?iosBridge[e].postMessage(t):IS_REACT_NATIVE_WEBVIEW?window.ReactNativeWebView.postMessage(JSON.stringify({handler:e,params:t})):webBridge&&"function"==typeof webBridge.postMessage&&webBridge.postMessage({handler:e,params:t,type:"vk-connect",webFrameId:i,connectVersion:n},"*")},e);return{send:s,sendPromise:s,subscribe:e,unsubscribe:function(e){var t=p.indexOf(e);-1<t&&p.splice(t,1)},supports:function(e){return IS_ANDROID_WEBVIEW?!(!androidBridge||"function"!=typeof androidBridge[e]):IS_IOS_WEBVIEW?!(!iosBridge||!iosBridge[e]||"function"!=typeof iosBridge[e].postMessage):!!IS_WEB&&-1<DESKTOP_METHODS.indexOf(e)},isWebView:t,isIframe:r,isEmbedded:o,isStandalone:function(){return!o()}}}function createCustomEventPolyfill(){function e(e,t){var n=t||{bubbles:!1,cancelable:!1,detail:void 0},r=document.createEvent("CustomEvent");return r.initCustomEvent(e,!!n.bubbles,!!n.cancelable,n.detail),r}return e.prototype=Event.prototype,e}var version="2.7.0";function applyMiddleware(){for(var r=[],e=0;e<arguments.length;e++)r[e]=arguments[e];return r.includes(void 0)||r.includes(null)?applyMiddleware.apply(void 0,r.filter(function(e){return"function"==typeof e})):function(n){if(0===r.length)return n;var e,t={subscribe:n.subscribe,send:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return n.send.apply(n,e)}};return e=r.filter(function(e){return"function"==typeof e}).map(function(e){return e(t)}).reduce(function(t,n){return function(e){return t(n(e))}})(n.send),__assign(__assign({},n),{send:e})}}!function(e){e.REWARD="reward",e.INTERSTITIAL="interstitial"}(exports.EAdsFormats||(exports.EAdsFormats={})),function(e){e.CAMERA="camera",e.LOCATION="location",e.PHOTO="photo"}(exports.EGrantedPermission||(exports.EGrantedPermission={})),function(e){e.RU="ru",e.UK="uk",e.UA="ua",e.EN="en",e.BE="be",e.KZ="kz",e.PT="pt",e.ES="es"}(exports.EGetLaunchParamsResponseLanguages||(exports.EGetLaunchParamsResponseLanguages={})),function(e){e.ADMIN="admin",e.EDITOR="editor",e.MEMBER="member",e.MODER="moder",e.NONE="none"}(exports.EGetLaunchParamsResponseGroupRole||(exports.EGetLaunchParamsResponseGroupRole={})),function(e){e.DESKTOP_WEB="desktop_web",e.MOBILE_WEB="mobile_web",e.MOBILE_ANDROID="mobile_android",e.MOBILE_ANDROID_MESSENGER="mobile_android_messenger",e.MOBILE_IPHONE="mobile_iphone",e.MOBILE_IPHONE_MESSENGER="mobile_iphone_messenger",e.MOBILE_IPAD="mobile_ipad"}(exports.EGetLaunchParamsResponsePlatforms||(exports.EGetLaunchParamsResponsePlatforms={})),"undefined"==typeof window||window.CustomEvent||(window.CustomEvent=createCustomEventPolyfill());var bridge=createVKBridge(version);exports.applyMiddleware=applyMiddleware,exports.default=bridge; | ||
//# sourceMappingURL=index.js.map |
@@ -1,2 +0,2 @@ | ||
!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports):"function"==typeof define&&define.amd?define(["exports"],n):n((e=e||self).vkBridge={})}(this,function(e){"use strict";var a=function(){return(a=Object.assign||function(e){for(var n,t=1,o=arguments.length;t<o;t++)for(var r in n=arguments[t])Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r]);return e}).apply(this,arguments)};function d(){for(var e=0,n=0,t=arguments.length;n<t;n++)e+=arguments[n].length;var o=Array(e),r=0;for(n=0;n<t;n++)for(var p=arguments[n],i=0,a=p.length;i<a;i++,r++)o[r]=p[i];return o}function u(p,e){var o,r,i=(o={current:0,next:function(){return++this.current}},r={},{add:function(e,n){var t=null!=n?n:o.next();return r[t]=e,t},resolve:function(e,n,t){var o=r[e];o&&(t(n)?o.resolve(n):o.reject(n),r[e]=null)}});return e(function(e){if(e.detail&&e.detail.data&&"object"==typeof e.detail.data&&"request_id"in e.detail.data){var n=e.detail.data,t=n.request_id,o=function(e,n){var t={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&n.indexOf(o)<0&&(t[o]=e[o]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(o=Object.getOwnPropertySymbols(e);r<o.length;r++)n.indexOf(o[r])<0&&Object.prototype.propertyIsEnumerable.call(e,o[r])&&(t[o[r]]=e[o[r]])}return t}(n,["request_id"]);t&&i.resolve(t,o,function(e){return!("error_type"in e)})}}),function(o,r){return void 0===r&&(r={}),new Promise(function(e,n){var t=i.add({resolve:e,reject:n},r.request_id);p(o,a(a({},r),{request_id:t}))})}}var n="undefined"!=typeof window,b=Boolean(n&&window.AndroidBridge),l=Boolean(n&&window.webkit&&window.webkit.messageHandlers&&window.webkit.messageHandlers.VKWebAppClose),c=Boolean(n&&window.ReactNativeWebView&&"function"==typeof window.ReactNativeWebView.postMessage),f=n&&!b&&!l,t=f&&/(^\?|&)vk_platform=mobile_web(&|$)/.test(location.search),A=f?"message":"VKWebAppEvent",w=d(["VKWebAppInit","VKWebAppGetCommunityAuthToken","VKWebAppAddToCommunity","VKWebAppAddToHomeScreenInfo","VKWebAppClose","VKWebAppCopyText","VKWebAppCreateHash","VKWebAppGetUserInfo","VKWebAppSetLocation","VKWebAppSendToClient","VKWebAppGetClientVersion","VKWebAppGetPhoneNumber","VKWebAppGetEmail","VKWebAppGetGroupInfo","VKWebAppGetGeodata","VKWebAppGetCommunityToken","VKWebAppGetConfig","VKWebAppGetLaunchParams","VKWebAppSetTitle","VKWebAppGetAuthToken","VKWebAppCallAPIMethod","VKWebAppJoinGroup","VKWebAppLeaveGroup","VKWebAppAllowMessagesFromGroup","VKWebAppDenyNotifications","VKWebAppAllowNotifications","VKWebAppOpenPayForm","VKWebAppOpenApp","VKWebAppShare","VKWebAppShowWallPostBox","VKWebAppScroll","VKWebAppShowOrderBox","VKWebAppShowLeaderBoardBox","VKWebAppShowInviteBox","VKWebAppShowRequestBox","VKWebAppAddToFavorites","VKWebAppShowCommunityWidgetPreviewBox","VKWebAppShowStoryBox","VKWebAppStorageGet","VKWebAppStorageGetKeys","VKWebAppStorageSet","VKWebAppFlashGetInfo","VKWebAppSubscribeStoryApp","VKWebAppOpenWallPost","VKWebAppCheckAllowedScopes","VKWebAppCheckNativeAds","VKWebAppShowNativeAds","VKWebAppRetargetingPixel","VKWebAppConversionHit","VKWebAppShowSubscriptionBox","VKWebAppCheckSurvey","VKWebAppShowSurvey"],f&&!t?["VKWebAppResizeWindow","VKWebAppAddToMenu","VKWebAppShowInstallPushBox","VKWebAppGetFriends"]:["VKWebAppShowImages"]),W=n?window.AndroidBridge:void 0,m=l?window.webkit.messageHandlers:void 0,v=f?parent:void 0;var o,r,p,i,s;function V(e,n){var t=n||{bubbles:!1,cancelable:!1,detail:void 0},o=document.createEvent("CustomEvent");return o.initCustomEvent(e,!!t.bubbles,!!t.cancelable,t.detail),o}(o=e.EAdsFormats||(e.EAdsFormats={})).REWARD="reward",o.INTERSTITIAL="interstitial",(r=e.EGrantedPermission||(e.EGrantedPermission={})).CAMERA="camera",r.LOCATION="location",r.PHOTO="photo",(p=e.EGetLaunchParamsResponseLanguages||(e.EGetLaunchParamsResponseLanguages={})).RU="ru",p.UK="uk",p.UA="ua",p.EN="en",p.BE="be",p.KZ="kz",p.PT="pt",p.ES="es",(i=e.EGetLaunchParamsResponseGroupRole||(e.EGetLaunchParamsResponseGroupRole={})).ADMIN="admin",i.EDITOR="editor",i.MEMBER="member",i.MODER="moder",i.NONE="none",(s=e.EGetLaunchParamsResponsePlatforms||(e.EGetLaunchParamsResponsePlatforms={})).DESKTOP_WEB="desktop_web",s.MOBILE_WEB="mobile_web",s.MOBILE_ANDROID="mobile_android",s.MOBILE_ANDROID_MESSENGER="mobile_android_messenger",s.MOBILE_IPHONE="mobile_iphone",s.MOBILE_IPHONE_MESSENGER="mobile_iphone_messenger",s.MOBILE_IPAD="mobile_ipad","undefined"==typeof window||window.CustomEvent||(window.CustomEvent=(V.prototype=Event.prototype,V));var K=function(t){var p=void 0,i=[];function e(e){i.push(e)}function n(){return l||b}function o(){return f&&window.parent!==window}function r(){return n()||o()}function a(n){if(l||b)return d(i).map(function(e){return e.call(null,n)});var e=null==n?void 0:n.data;if(f&&e){if(c&&"string"==typeof e)try{e=JSON.parse(e)}catch(e){}var t=e.type,o=e.data,r=e.frameId;t&&("SetSupportedHandlers"!==t?"VKWebAppSettings"!==t?d(i).map(function(e){return e({detail:{type:t,data:o}})}):p=r:o.supportedHandlers)}}c&&/(android)/i.test(navigator.userAgent)?document.addEventListener(A,a):"undefined"!=typeof window&&"addEventListener"in window&&window.addEventListener(A,a);var s=u(function(e,n){W&&W[e]?W[e](JSON.stringify(n)):m&&m[e]&&"function"==typeof m[e].postMessage?m[e].postMessage(n):c?window.ReactNativeWebView.postMessage(JSON.stringify({handler:e,params:n})):v&&"function"==typeof v.postMessage&&v.postMessage({handler:e,params:n,type:"vk-connect",webFrameId:p,connectVersion:t},"*")},e);return{send:s,sendPromise:s,subscribe:e,unsubscribe:function(e){var n=i.indexOf(e);-1<n&&i.splice(n,1)},supports:function(e){return b?!(!W||"function"!=typeof W[e]):l?!(!m||!m[e]||"function"!=typeof m[e].postMessage):f&&-1<w.indexOf(e)},isWebView:n,isIframe:o,isEmbedded:r,isStandalone:function(){return!r()}}}("2.6.4");e.applyMiddleware=function e(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];return o.includes(void 0)||o.includes(null)?e.apply(void 0,o.filter(function(e){return"function"==typeof e})):function(t){if(0===o.length)return t;var e,n={subscribe:t.subscribe,send:function(){for(var e=[],n=0;n<arguments.length;n++)e[n]=arguments[n];return t.send.apply(t,e)}};return e=o.filter(function(e){return"function"==typeof e}).map(function(e){return e(n)}).reduce(function(n,t){return function(e){return n(t(e))}})(t.send),a(a({},t),{send:e})}},e.default=K,Object.defineProperty(e,"__esModule",{value:!0})}); | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=e||self).vkBridge={})}(this,function(e){"use strict";var a=function(){return(a=Object.assign||function(e){for(var t,n=1,o=arguments.length;n<o;n++)for(var r in t=arguments[n])Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e}).apply(this,arguments)};function d(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var o=Array(e),r=0;for(t=0;t<n;t++)for(var p=arguments[t],i=0,a=p.length;i<a;i++,r++)o[r]=p[i];return o}function u(p,e){var o,r,i=(o={current:0,next:function(){return++this.current}},r={},{add:function(e,t){var n=null!=t?t:o.next();return r[n]=e,n},resolve:function(e,t,n){var o=r[e];o&&(n(t)?o.resolve(t):o.reject(t),r[e]=null)}});return e(function(e){if(e.detail&&e.detail.data&&"object"==typeof e.detail.data&&"request_id"in e.detail.data){var t=e.detail.data,n=t.request_id,o=function(e,t){var n={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(o=Object.getOwnPropertySymbols(e);r<o.length;r++)t.indexOf(o[r])<0&&Object.prototype.propertyIsEnumerable.call(e,o[r])&&(n[o[r]]=e[o[r]])}return n}(t,["request_id"]);n&&i.resolve(n,o,function(e){return!("error_type"in e)})}}),function(o,r){return void 0===r&&(r={}),new Promise(function(e,t){var n=i.add({resolve:e,reject:t},r.request_id);p(o,a(a({},r),{request_id:n}))})}}var t="undefined"!=typeof window,l=Boolean(t&&window.AndroidBridge),b=Boolean(t&&window.webkit&&window.webkit.messageHandlers&&window.webkit.messageHandlers.VKWebAppClose),c=Boolean(t&&window.ReactNativeWebView&&"function"==typeof window.ReactNativeWebView.postMessage),f=t&&!l&&!b,n=f&&/(^\?|&)vk_platform=mobile_web(&|$)/.test(location.search),A=f?"message":"VKWebAppEvent",W=d(["VKWebAppInit","VKWebAppGetCommunityAuthToken","VKWebAppAddToCommunity","VKWebAppAddToHomeScreenInfo","VKWebAppClose","VKWebAppCopyText","VKWebAppCreateHash","VKWebAppGetUserInfo","VKWebAppSetLocation","VKWebAppSendToClient","VKWebAppGetClientVersion","VKWebAppGetPhoneNumber","VKWebAppGetEmail","VKWebAppGetGroupInfo","VKWebAppGetGeodata","VKWebAppGetCommunityToken","VKWebAppGetConfig","VKWebAppGetLaunchParams","VKWebAppSetTitle","VKWebAppGetAuthToken","VKWebAppCallAPIMethod","VKWebAppJoinGroup","VKWebAppLeaveGroup","VKWebAppAllowMessagesFromGroup","VKWebAppDenyNotifications","VKWebAppAllowNotifications","VKWebAppOpenPayForm","VKWebAppOpenApp","VKWebAppShare","VKWebAppShowWallPostBox","VKWebAppScroll","VKWebAppShowOrderBox","VKWebAppShowLeaderBoardBox","VKWebAppShowInviteBox","VKWebAppShowRequestBox","VKWebAppAddToFavorites","VKWebAppShowCommunityWidgetPreviewBox","VKWebAppShowStoryBox","VKWebAppStorageGet","VKWebAppStorageGetKeys","VKWebAppStorageSet","VKWebAppFlashGetInfo","VKWebAppSubscribeStoryApp","VKWebAppOpenWallPost","VKWebAppCheckAllowedScopes","VKWebAppCheckNativeAds","VKWebAppShowNativeAds","VKWebAppRetargetingPixel","VKWebAppConversionHit","VKWebAppShowSubscriptionBox","VKWebAppCheckSurvey","VKWebAppShowSurvey","VKWebAppScrollTop","VKWebAppScrollTopStart","VKWebAppScrollTopStop"],f&&!n?["VKWebAppResizeWindow","VKWebAppAddToMenu","VKWebAppShowInstallPushBox","VKWebAppGetFriends"]:["VKWebAppShowImages"]),w=t?window.AndroidBridge:void 0,V=b?window.webkit.messageHandlers:void 0,m=f?parent:void 0;var o,r,p,i,s;function K(e,t){var n=t||{bubbles:!1,cancelable:!1,detail:void 0},o=document.createEvent("CustomEvent");return o.initCustomEvent(e,!!n.bubbles,!!n.cancelable,n.detail),o}(o=e.EAdsFormats||(e.EAdsFormats={})).REWARD="reward",o.INTERSTITIAL="interstitial",(r=e.EGrantedPermission||(e.EGrantedPermission={})).CAMERA="camera",r.LOCATION="location",r.PHOTO="photo",(p=e.EGetLaunchParamsResponseLanguages||(e.EGetLaunchParamsResponseLanguages={})).RU="ru",p.UK="uk",p.UA="ua",p.EN="en",p.BE="be",p.KZ="kz",p.PT="pt",p.ES="es",(i=e.EGetLaunchParamsResponseGroupRole||(e.EGetLaunchParamsResponseGroupRole={})).ADMIN="admin",i.EDITOR="editor",i.MEMBER="member",i.MODER="moder",i.NONE="none",(s=e.EGetLaunchParamsResponsePlatforms||(e.EGetLaunchParamsResponsePlatforms={})).DESKTOP_WEB="desktop_web",s.MOBILE_WEB="mobile_web",s.MOBILE_ANDROID="mobile_android",s.MOBILE_ANDROID_MESSENGER="mobile_android_messenger",s.MOBILE_IPHONE="mobile_iphone",s.MOBILE_IPHONE_MESSENGER="mobile_iphone_messenger",s.MOBILE_IPAD="mobile_ipad","undefined"==typeof window||window.CustomEvent||(window.CustomEvent=(K.prototype=Event.prototype,K));var v=function(n){var p=void 0,i=[];function e(e){i.push(e)}function t(){return b||l}function o(){return f&&window.parent!==window}function r(){return t()||o()}function a(t){if(b||l)return d(i).map(function(e){return e.call(null,t)});var e=null==t?void 0:t.data;if(f&&e){if(c&&"string"==typeof e)try{e=JSON.parse(e)}catch(e){}var n=e.type,o=e.data,r=e.frameId;n&&("SetSupportedHandlers"!==n?"VKWebAppSettings"!==n?d(i).map(function(e){return e({detail:{type:n,data:o}})}):p=r:o.supportedHandlers)}}c&&/(android)/i.test(navigator.userAgent)?document.addEventListener(A,a):"undefined"!=typeof window&&"addEventListener"in window&&window.addEventListener(A,a);var s=u(function(e,t){w&&w[e]?w[e](JSON.stringify(t)):V&&V[e]&&"function"==typeof V[e].postMessage?V[e].postMessage(t):c?window.ReactNativeWebView.postMessage(JSON.stringify({handler:e,params:t})):m&&"function"==typeof m.postMessage&&m.postMessage({handler:e,params:t,type:"vk-connect",webFrameId:p,connectVersion:n},"*")},e);return{send:s,sendPromise:s,subscribe:e,unsubscribe:function(e){var t=i.indexOf(e);-1<t&&i.splice(t,1)},supports:function(e){return l?!(!w||"function"!=typeof w[e]):b?!(!V||!V[e]||"function"!=typeof V[e].postMessage):f&&-1<W.indexOf(e)},isWebView:t,isIframe:o,isEmbedded:r,isStandalone:function(){return!r()}}}("2.7.0");e.applyMiddleware=function e(){for(var o=[],t=0;t<arguments.length;t++)o[t]=arguments[t];return o.includes(void 0)||o.includes(null)?e.apply(void 0,o.filter(function(e){return"function"==typeof e})):function(n){if(0===o.length)return n;var e,t={subscribe:n.subscribe,send:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return n.send.apply(n,e)}};return e=o.filter(function(e){return"function"==typeof e}).map(function(e){return e(t)}).reduce(function(t,n){return function(e){return t(n(e))}})(n.send),a(a({},n),{send:e})}},e.default=v,Object.defineProperty(e,"__esModule",{value:!0})}); | ||
//# sourceMappingURL=index.umd.js.map |
@@ -198,3 +198,3 @@ /** Type of the Personal Card */ | ||
*/ | ||
export declare type AppearanceSchemeType = 'vkcom_light' | 'vkcom_dark' | 'client_light' | 'client_dark' | 'space_gray' | 'bright_light'; | ||
export declare type AppearanceSchemeType = 'vkcom_light' | 'vkcom_dark' | 'space_gray' | 'bright_light'; | ||
/** | ||
@@ -260,13 +260,21 @@ * Vibration type for Taptic Engine | ||
}; | ||
/** | ||
* Update config type for mvk (mobile browser). | ||
*/ | ||
export declare type MVKUpdateConfigData = { | ||
/** Server API host for direct requests. */ | ||
/** Default fields for config response on all platforms */ | ||
export declare type DefaultUpdateConfigData = { | ||
api_host: string; | ||
/** App_id of opened app */ | ||
app_id: string; | ||
/** Native app appearance */ | ||
appearance: AppearanceType; | ||
/** Native app scheme */ | ||
scheme: AppearanceSchemeType; | ||
}; | ||
export declare type VKUpdateConfigData = { | ||
/** Server API host for direct requests. */ | ||
api_host: string; | ||
/** Config response for native platforms */ | ||
export declare type MobileUpdateConfigData = DefaultUpdateConfigData & { | ||
/** Client type */ | ||
app: 'vkclient' | 'vkme'; | ||
/** Safe area insets. iOS only */ | ||
insets?: Insets; | ||
}; | ||
/** Config response for m.vk.com and vk.com */ | ||
export declare type SharedUpdateConfigData = DefaultUpdateConfigData & { | ||
/** window.innerWidth of the parent window */ | ||
@@ -276,18 +284,14 @@ viewport_width: number; | ||
viewport_height: number; | ||
scheme: AppearanceSchemeType; | ||
/** Server API host for direct requests. */ | ||
api_host: string; | ||
}; | ||
/** | ||
* Update config type data for mobile clients and desktop. | ||
*/ | ||
export declare type DefaultUpdateConfigData = { | ||
app: 'vkclient' | 'vkme'; | ||
app_id: string; | ||
appearance: AppearanceType; | ||
scheme: AppearanceSchemeType; | ||
insets: Insets; | ||
/** Config response for m.vk.com (mobile browser) */ | ||
export declare type MVKUpdateConfigData = SharedUpdateConfigData; | ||
/** Config response for vk.com (full web) */ | ||
export declare type VKUpdateConfigData = SharedUpdateConfigData & { | ||
/** Is app opened in layer */ | ||
is_layer: boolean; | ||
}; | ||
/** | ||
* Update config data | ||
*/ | ||
export declare type ParentConfigData = DefaultUpdateConfigData | MVKUpdateConfigData | VKUpdateConfigData; | ||
/** Update config data */ | ||
export declare type ParentConfigData = MobileUpdateConfigData | MVKUpdateConfigData | VKUpdateConfigData; | ||
export declare type WidgetPreviewRequestOptions = { | ||
@@ -778,2 +782,5 @@ /** Widget type */ | ||
}; | ||
export declare type ScrollTopResponse = { | ||
scrollTop: number; | ||
}; | ||
/** | ||
@@ -952,2 +959,5 @@ * Map of types of request props of VK Bridge methods | ||
VKWebAppShowSurvey: {}; | ||
VKWebAppScrollTop: {}; | ||
VKWebAppScrollTopStart: {}; | ||
VKWebAppScrollTopStop: {}; | ||
}; | ||
@@ -1234,2 +1244,9 @@ /** | ||
}; | ||
VKWebAppScrollTop: ScrollTopResponse; | ||
VKWebAppScrollTopStart: { | ||
result: true; | ||
}; | ||
VKWebAppScrollTopStop: { | ||
result: true; | ||
}; | ||
}; | ||
@@ -1243,3 +1260,3 @@ declare type EventReceiveNames<T extends keyof RequestPropsMap, R extends string, F extends string> = Record<T, { | ||
*/ | ||
export declare type ReceiveEventMap = EventReceiveNames<'VKWebAppInit', 'VKWebAppInitResult', 'VKWebAppInitFailed'> & EventReceiveNames<'VKWebAppAddToCommunity', 'VKWebAppAddToCommunityResult', 'VKWebAppAddToCommunityFailed'> & EventReceiveNames<'VKWebAppAddToHomeScreen', 'VKWebAppAddToHomeScreenResult', 'VKWebAppAddToHomeScreenFailed'> & EventReceiveNames<'VKWebAppAddToHomeScreenInfo', 'VKWebAppAddToHomeScreenInfoResult', 'VKWebAppAddToHomeScreenInfoFailed'> & EventReceiveNames<'VKWebAppAllowMessagesFromGroup', 'VKWebAppAllowMessagesFromGroupResult', 'VKWebAppAllowMessagesFromGroupFailed'> & EventReceiveNames<'VKWebAppAllowNotifications', 'VKWebAppAllowNotificationsResult', 'VKWebAppAllowNotificationsFailed'> & EventReceiveNames<'OKWebAppCallAPIMethod', 'OKWebAppCallAPIMethodResult', 'OKWebAppCallAPIMethodFailed'> & EventReceiveNames<'VKWebAppCallAPIMethod', 'VKWebAppCallAPIMethodResult', 'VKWebAppCallAPIMethodFailed'> & EventReceiveNames<'VKWebAppCopyText', 'VKWebAppCopyTextResult', 'VKWebAppCopyTextFailed'> & EventReceiveNames<'VKWebAppCreateHash', 'VKWebAppCreateHashResult', 'VKWebAppCreateHashFailed'> & EventReceiveNames<'VKWebAppDownloadFile', 'VKWebAppDownloadFileResult', 'VKWebAppDownloadFileFailed'> & EventReceiveNames<'VKWebAppGetAuthToken', 'VKWebAppAccessTokenReceived', 'VKWebAppAccessTokenFailed'> & EventReceiveNames<'VKWebAppClose', 'VKWebAppCloseResult', 'VKWebAppCloseFailed'> & EventReceiveNames<'VKWebAppOpenApp', 'VKWebAppOpenAppResult', 'VKWebAppOpenAppFailed'> & EventReceiveNames<'VKWebAppDenyNotifications', 'VKWebAppDenyNotificationsResult', 'VKWebAppDenyNotificationsFailed'> & EventReceiveNames<'VKWebAppFlashGetInfo', 'VKWebAppFlashGetInfoResult', 'VKWebAppFlashGetInfoFailed'> & EventReceiveNames<'VKWebAppFlashSetLevel', 'VKWebAppFlashSetLevelResult', 'VKWebAppFlashSetLevelFailed'> & EventReceiveNames<'VKWebAppGetClientVersion', 'VKWebAppGetClientVersionResult', 'VKWebAppGetClientVersionFailed'> & EventReceiveNames<'VKWebAppGetCommunityToken', 'VKWebAppGetCommunityTokenResult', 'VKWebAppGetCommunityTokenFailed'> & EventReceiveNames<'VKWebAppGetConfig', 'VKWebAppGetConfigResult', 'VKWebAppGetConfigFailed'> & EventReceiveNames<'VKWebAppGetLaunchParams', 'VKWebAppGetLaunchParamsResult', 'VKWebAppGetLaunchParamsFailed'> & EventReceiveNames<'VKWebAppAudioPause', 'VKWebAppAudioPauseResult', 'VKWebAppAudioPauseFailed'> & EventReceiveNames<'VKWebAppGetEmail', 'VKWebAppGetEmailResult', 'VKWebAppGetEmailFailed'> & EventReceiveNames<'VKWebAppGetFriends', 'VKWebAppGetFriendsResult', 'VKWebAppGetFriendsFailed'> & EventReceiveNames<'VKWebAppGetGeodata', 'VKWebAppGetGeodataResult', 'VKWebAppGetGeodataFailed'> & EventReceiveNames<'VKWebAppGetGrantedPermissions', 'VKWebAppGetGrantedPermissionsResult', 'VKWebAppGetGrantedPermissionsFailed'> & EventReceiveNames<'VKWebAppGetPersonalCard', 'VKWebAppGetPersonalCardResult', 'VKWebAppGetPersonalCardFailed'> & EventReceiveNames<'VKWebAppGetPhoneNumber', 'VKWebAppGetPhoneNumberResult', 'VKWebAppGetPhoneNumberFailed'> & EventReceiveNames<'VKWebAppGetUserInfo', 'VKWebAppGetUserInfoResult', 'VKWebAppGetUserInfoFailed'> & EventReceiveNames<'VKWebAppJoinGroup', 'VKWebAppJoinGroupResult', 'VKWebAppJoinGroupFailed'> & EventReceiveNames<'VKWebAppLeaveGroup', 'VKWebAppLeaveGroupResult', 'VKWebAppLeaveGroupFailed'> & EventReceiveNames<'VKWebAppAddToMenu', 'VKWebAppAddToMenuResult', 'VKWebAppAddToMenuFailed'> & EventReceiveNames<'VKWebAppOpenCodeReader', 'VKWebAppOpenCodeReaderResult', 'VKWebAppOpenCodeReaderFailed'> & EventReceiveNames<'VKWebAppOpenContacts', 'VKWebAppOpenContactsResult', 'VKWebAppOpenContactsFailed'> & EventReceiveNames<'VKWebAppOpenPayForm', 'VKWebAppOpenPayFormResult', 'VKWebAppOpenPayFormFailed'> & EventReceiveNames<'VKWebAppOpenQR', 'VKWebAppOpenQRResult', 'VKWebAppOpenQRFailed'> & EventReceiveNames<'VKWebAppResizeWindow', 'VKWebAppResizeWindowResult', 'VKWebAppResizeWindowFailed'> & EventReceiveNames<'VKWebAppScroll', 'VKWebAppScrollResult', 'VKWebAppScrollFailed'> & EventReceiveNames<'VKWebAppSendToClient', 'VKWebAppSendToClientResult', 'VKWebAppSendToClientFailed'> & EventReceiveNames<'VKWebAppSetLocation', 'VKWebAppSetLocationResult', 'VKWebAppSetLocationFailed'> & EventReceiveNames<'VKWebAppSetViewSettings', 'VKWebAppSetViewSettingsResult', 'VKWebAppSetViewSettingsFailed'> & EventReceiveNames<'VKWebAppShare', 'VKWebAppShareResult', 'VKWebAppShareFailed'> & EventReceiveNames<'VKWebAppShowCommunityWidgetPreviewBox', 'VKWebAppShowCommunityWidgetPreviewBoxResult', 'VKWebAppShowCommunityWidgetPreviewBoxFailed'> & EventReceiveNames<'VKWebAppShowImages', 'VKWebAppShowImagesResult', 'VKWebAppShowImagesFailed'> & EventReceiveNames<'VKWebAppShowInviteBox', 'VKWebAppShowInviteBoxResult', 'VKWebAppShowInviteBoxFailed'> & EventReceiveNames<'VKWebAppShowLeaderBoardBox', 'VKWebAppShowLeaderBoardBoxResult', 'VKWebAppShowLeaderBoardBoxFailed'> & EventReceiveNames<'VKWebAppShowMessageBox', 'VKWebAppShowMessageBoxResult', 'VKWebAppShowMessageBoxFailed'> & EventReceiveNames<'VKWebAppShowNativeAds', 'VKWebAppShowNativeAdsResult', 'VKWebAppShowNativeAdsFailed'> & EventReceiveNames<'VKWebAppCheckNativeAds', 'VKWebAppCheckNativeAdsResult', 'VKWebAppCheckNativeAdsFailed'> & EventReceiveNames<'VKWebAppShowOrderBox', 'VKWebAppShowOrderBoxResult', 'VKWebAppShowOrderBoxFailed'> & EventReceiveNames<'VKWebAppShowRequestBox', 'VKWebAppShowRequestBoxResult', 'VKWebAppShowRequestBoxFailed'> & EventReceiveNames<'VKWebAppShowWallPostBox', 'VKWebAppShowWallPostBoxResult', 'VKWebAppShowWallPostBoxFailed'> & EventReceiveNames<'VKWebAppOpenWallPost', 'VKWebAppOpenWallPostResult', 'VKWebAppOpenWallPostFailed'> & EventReceiveNames<'VKWebAppStorageGet', 'VKWebAppStorageGetResult', 'VKWebAppStorageGetFailed'> & EventReceiveNames<'VKWebAppStorageGetKeys', 'VKWebAppStorageGetKeysResult', 'VKWebAppStorageGetKeysFailed'> & EventReceiveNames<'VKWebAppStorageSet', 'VKWebAppStorageSetResult', 'VKWebAppStorageSetFailed'> & EventReceiveNames<'VKWebAppTapticImpactOccurred', 'VKWebAppTapticImpactOccurredResult', 'VKWebAppTapticImpactOccurredFailed'> & EventReceiveNames<'VKWebAppTapticNotificationOccurred', 'VKWebAppTapticNotificationOccurredResult', 'VKWebAppTapticNotificationOccurredFailed'> & EventReceiveNames<'VKWebAppTapticSelectionChanged', 'VKWebAppTapticSelectionChangedResult', 'VKWebAppTapticSelectionChangedFailed'> & EventReceiveNames<'VKWebAppAddToFavorites', 'VKWebAppAddToFavoritesResult', 'VKWebAppAddToFavoritesFailed'> & EventReceiveNames<'VKWebAppSendPayload', 'VKWebAppSendPayloadResult', 'VKWebAppSendPayloadFailed'> & EventReceiveNames<'VKWebAppDisableSwipeBack', 'VKWebAppDisableSwipeBackResult', 'VKWebAppDisableSwipeBackFailed'> & EventReceiveNames<'VKWebAppEnableSwipeBack', 'VKWebAppEnableSwipeBackResult', 'VKWebAppEnableSwipeBackFailed'> & EventReceiveNames<'VKWebAppSetSwipeSettings', 'VKWebAppSetSwipeSettingsResult', 'VKWebAppSetSwipeSettingsFailed'> & EventReceiveNames<'VKWebAppShowStoryBox', 'VKWebAppShowStoryBoxResult', 'VKWebAppShowStoryBoxFailed'> & EventReceiveNames<'VKWebAppAccelerometerStart', 'VKWebAppAccelerometerStartResult', 'VKWebAppAccelerometerStartFailed'> & EventReceiveNames<'VKWebAppAccelerometerStop', 'VKWebAppAccelerometerStopResult', 'VKWebAppAccelerometerStopFailed'> & EventReceiveNames<'VKWebAppGyroscopeStart', 'VKWebAppGyroscopeStartResult', 'VKWebAppGyroscopeStartFailed'> & EventReceiveNames<'VKWebAppGyroscopeStop', 'VKWebAppGyroscopeStopResult', 'VKWebAppGyroscopeStopFailed'> & EventReceiveNames<'VKWebAppDeviceMotionStart', 'VKWebAppDeviceMotionStartResult', 'VKWebAppDeviceMotionStartFailed'> & EventReceiveNames<'VKWebAppDeviceMotionStop', 'VKWebAppDeviceMotionStopResult', 'VKWebAppDeviceMotionStopFailed'> & EventReceiveNames<'VKWebAppSubscribeStoryApp', 'VKWebAppSubscribeStoryAppResult', 'VKWebAppSubscribeStoryAppFailed'> & EventReceiveNames<'VKWebAppGetGroupInfo', 'VKWebAppGetGroupInfoResult', 'VKWebAppGetGroupInfoFailed'> & EventReceiveNames<'VKWebAppRetargetingPixel', 'VKWebAppRetargetingPixelResult', 'VKWebAppRetargetingPixelFailed'> & EventReceiveNames<'VKWebAppCheckAllowedScopes', 'VKWebAppCheckAllowedScopesResult', 'VKWebAppCheckAllowedScopesFailed'> & EventReceiveNames<'VKWebAppCheckSurvey', 'VKWebAppCheckSurveyResult', 'VKWebAppCheckSurveyFailed'> & EventReceiveNames<'VKWebAppShowSurvey', 'VKWebAppShowSurveyResult', 'VKWebAppShowSurveyFailed'> & EventReceiveNames<'VKWebAppConversionHit', 'VKWebAppConversionHitResult', 'VKWebAppConversionHitFailed'>; | ||
export declare type ReceiveEventMap = EventReceiveNames<'VKWebAppInit', 'VKWebAppInitResult', 'VKWebAppInitFailed'> & EventReceiveNames<'VKWebAppAddToCommunity', 'VKWebAppAddToCommunityResult', 'VKWebAppAddToCommunityFailed'> & EventReceiveNames<'VKWebAppAddToHomeScreen', 'VKWebAppAddToHomeScreenResult', 'VKWebAppAddToHomeScreenFailed'> & EventReceiveNames<'VKWebAppAddToHomeScreenInfo', 'VKWebAppAddToHomeScreenInfoResult', 'VKWebAppAddToHomeScreenInfoFailed'> & EventReceiveNames<'VKWebAppAllowMessagesFromGroup', 'VKWebAppAllowMessagesFromGroupResult', 'VKWebAppAllowMessagesFromGroupFailed'> & EventReceiveNames<'VKWebAppAllowNotifications', 'VKWebAppAllowNotificationsResult', 'VKWebAppAllowNotificationsFailed'> & EventReceiveNames<'OKWebAppCallAPIMethod', 'OKWebAppCallAPIMethodResult', 'OKWebAppCallAPIMethodFailed'> & EventReceiveNames<'VKWebAppCallAPIMethod', 'VKWebAppCallAPIMethodResult', 'VKWebAppCallAPIMethodFailed'> & EventReceiveNames<'VKWebAppCopyText', 'VKWebAppCopyTextResult', 'VKWebAppCopyTextFailed'> & EventReceiveNames<'VKWebAppCreateHash', 'VKWebAppCreateHashResult', 'VKWebAppCreateHashFailed'> & EventReceiveNames<'VKWebAppDownloadFile', 'VKWebAppDownloadFileResult', 'VKWebAppDownloadFileFailed'> & EventReceiveNames<'VKWebAppGetAuthToken', 'VKWebAppAccessTokenReceived', 'VKWebAppAccessTokenFailed'> & EventReceiveNames<'VKWebAppClose', 'VKWebAppCloseResult', 'VKWebAppCloseFailed'> & EventReceiveNames<'VKWebAppOpenApp', 'VKWebAppOpenAppResult', 'VKWebAppOpenAppFailed'> & EventReceiveNames<'VKWebAppDenyNotifications', 'VKWebAppDenyNotificationsResult', 'VKWebAppDenyNotificationsFailed'> & EventReceiveNames<'VKWebAppFlashGetInfo', 'VKWebAppFlashGetInfoResult', 'VKWebAppFlashGetInfoFailed'> & EventReceiveNames<'VKWebAppFlashSetLevel', 'VKWebAppFlashSetLevelResult', 'VKWebAppFlashSetLevelFailed'> & EventReceiveNames<'VKWebAppGetClientVersion', 'VKWebAppGetClientVersionResult', 'VKWebAppGetClientVersionFailed'> & EventReceiveNames<'VKWebAppGetCommunityToken', 'VKWebAppGetCommunityTokenResult', 'VKWebAppGetCommunityTokenFailed'> & EventReceiveNames<'VKWebAppGetConfig', 'VKWebAppGetConfigResult', 'VKWebAppGetConfigFailed'> & EventReceiveNames<'VKWebAppGetLaunchParams', 'VKWebAppGetLaunchParamsResult', 'VKWebAppGetLaunchParamsFailed'> & EventReceiveNames<'VKWebAppAudioPause', 'VKWebAppAudioPauseResult', 'VKWebAppAudioPauseFailed'> & EventReceiveNames<'VKWebAppGetEmail', 'VKWebAppGetEmailResult', 'VKWebAppGetEmailFailed'> & EventReceiveNames<'VKWebAppGetFriends', 'VKWebAppGetFriendsResult', 'VKWebAppGetFriendsFailed'> & EventReceiveNames<'VKWebAppGetGeodata', 'VKWebAppGetGeodataResult', 'VKWebAppGetGeodataFailed'> & EventReceiveNames<'VKWebAppGetGrantedPermissions', 'VKWebAppGetGrantedPermissionsResult', 'VKWebAppGetGrantedPermissionsFailed'> & EventReceiveNames<'VKWebAppGetPersonalCard', 'VKWebAppGetPersonalCardResult', 'VKWebAppGetPersonalCardFailed'> & EventReceiveNames<'VKWebAppGetPhoneNumber', 'VKWebAppGetPhoneNumberResult', 'VKWebAppGetPhoneNumberFailed'> & EventReceiveNames<'VKWebAppGetUserInfo', 'VKWebAppGetUserInfoResult', 'VKWebAppGetUserInfoFailed'> & EventReceiveNames<'VKWebAppJoinGroup', 'VKWebAppJoinGroupResult', 'VKWebAppJoinGroupFailed'> & EventReceiveNames<'VKWebAppLeaveGroup', 'VKWebAppLeaveGroupResult', 'VKWebAppLeaveGroupFailed'> & EventReceiveNames<'VKWebAppAddToMenu', 'VKWebAppAddToMenuResult', 'VKWebAppAddToMenuFailed'> & EventReceiveNames<'VKWebAppOpenCodeReader', 'VKWebAppOpenCodeReaderResult', 'VKWebAppOpenCodeReaderFailed'> & EventReceiveNames<'VKWebAppOpenContacts', 'VKWebAppOpenContactsResult', 'VKWebAppOpenContactsFailed'> & EventReceiveNames<'VKWebAppOpenPayForm', 'VKWebAppOpenPayFormResult', 'VKWebAppOpenPayFormFailed'> & EventReceiveNames<'VKWebAppOpenQR', 'VKWebAppOpenQRResult', 'VKWebAppOpenQRFailed'> & EventReceiveNames<'VKWebAppResizeWindow', 'VKWebAppResizeWindowResult', 'VKWebAppResizeWindowFailed'> & EventReceiveNames<'VKWebAppScroll', 'VKWebAppScrollResult', 'VKWebAppScrollFailed'> & EventReceiveNames<'VKWebAppSendToClient', 'VKWebAppSendToClientResult', 'VKWebAppSendToClientFailed'> & EventReceiveNames<'VKWebAppSetLocation', 'VKWebAppSetLocationResult', 'VKWebAppSetLocationFailed'> & EventReceiveNames<'VKWebAppSetViewSettings', 'VKWebAppSetViewSettingsResult', 'VKWebAppSetViewSettingsFailed'> & EventReceiveNames<'VKWebAppShare', 'VKWebAppShareResult', 'VKWebAppShareFailed'> & EventReceiveNames<'VKWebAppShowCommunityWidgetPreviewBox', 'VKWebAppShowCommunityWidgetPreviewBoxResult', 'VKWebAppShowCommunityWidgetPreviewBoxFailed'> & EventReceiveNames<'VKWebAppShowImages', 'VKWebAppShowImagesResult', 'VKWebAppShowImagesFailed'> & EventReceiveNames<'VKWebAppShowInviteBox', 'VKWebAppShowInviteBoxResult', 'VKWebAppShowInviteBoxFailed'> & EventReceiveNames<'VKWebAppShowLeaderBoardBox', 'VKWebAppShowLeaderBoardBoxResult', 'VKWebAppShowLeaderBoardBoxFailed'> & EventReceiveNames<'VKWebAppShowMessageBox', 'VKWebAppShowMessageBoxResult', 'VKWebAppShowMessageBoxFailed'> & EventReceiveNames<'VKWebAppShowNativeAds', 'VKWebAppShowNativeAdsResult', 'VKWebAppShowNativeAdsFailed'> & EventReceiveNames<'VKWebAppCheckNativeAds', 'VKWebAppCheckNativeAdsResult', 'VKWebAppCheckNativeAdsFailed'> & EventReceiveNames<'VKWebAppShowOrderBox', 'VKWebAppShowOrderBoxResult', 'VKWebAppShowOrderBoxFailed'> & EventReceiveNames<'VKWebAppShowRequestBox', 'VKWebAppShowRequestBoxResult', 'VKWebAppShowRequestBoxFailed'> & EventReceiveNames<'VKWebAppShowWallPostBox', 'VKWebAppShowWallPostBoxResult', 'VKWebAppShowWallPostBoxFailed'> & EventReceiveNames<'VKWebAppOpenWallPost', 'VKWebAppOpenWallPostResult', 'VKWebAppOpenWallPostFailed'> & EventReceiveNames<'VKWebAppStorageGet', 'VKWebAppStorageGetResult', 'VKWebAppStorageGetFailed'> & EventReceiveNames<'VKWebAppStorageGetKeys', 'VKWebAppStorageGetKeysResult', 'VKWebAppStorageGetKeysFailed'> & EventReceiveNames<'VKWebAppStorageSet', 'VKWebAppStorageSetResult', 'VKWebAppStorageSetFailed'> & EventReceiveNames<'VKWebAppTapticImpactOccurred', 'VKWebAppTapticImpactOccurredResult', 'VKWebAppTapticImpactOccurredFailed'> & EventReceiveNames<'VKWebAppTapticNotificationOccurred', 'VKWebAppTapticNotificationOccurredResult', 'VKWebAppTapticNotificationOccurredFailed'> & EventReceiveNames<'VKWebAppTapticSelectionChanged', 'VKWebAppTapticSelectionChangedResult', 'VKWebAppTapticSelectionChangedFailed'> & EventReceiveNames<'VKWebAppAddToFavorites', 'VKWebAppAddToFavoritesResult', 'VKWebAppAddToFavoritesFailed'> & EventReceiveNames<'VKWebAppSendPayload', 'VKWebAppSendPayloadResult', 'VKWebAppSendPayloadFailed'> & EventReceiveNames<'VKWebAppDisableSwipeBack', 'VKWebAppDisableSwipeBackResult', 'VKWebAppDisableSwipeBackFailed'> & EventReceiveNames<'VKWebAppEnableSwipeBack', 'VKWebAppEnableSwipeBackResult', 'VKWebAppEnableSwipeBackFailed'> & EventReceiveNames<'VKWebAppSetSwipeSettings', 'VKWebAppSetSwipeSettingsResult', 'VKWebAppSetSwipeSettingsFailed'> & EventReceiveNames<'VKWebAppShowStoryBox', 'VKWebAppShowStoryBoxResult', 'VKWebAppShowStoryBoxFailed'> & EventReceiveNames<'VKWebAppAccelerometerStart', 'VKWebAppAccelerometerStartResult', 'VKWebAppAccelerometerStartFailed'> & EventReceiveNames<'VKWebAppAccelerometerStop', 'VKWebAppAccelerometerStopResult', 'VKWebAppAccelerometerStopFailed'> & EventReceiveNames<'VKWebAppGyroscopeStart', 'VKWebAppGyroscopeStartResult', 'VKWebAppGyroscopeStartFailed'> & EventReceiveNames<'VKWebAppGyroscopeStop', 'VKWebAppGyroscopeStopResult', 'VKWebAppGyroscopeStopFailed'> & EventReceiveNames<'VKWebAppDeviceMotionStart', 'VKWebAppDeviceMotionStartResult', 'VKWebAppDeviceMotionStartFailed'> & EventReceiveNames<'VKWebAppDeviceMotionStop', 'VKWebAppDeviceMotionStopResult', 'VKWebAppDeviceMotionStopFailed'> & EventReceiveNames<'VKWebAppSubscribeStoryApp', 'VKWebAppSubscribeStoryAppResult', 'VKWebAppSubscribeStoryAppFailed'> & EventReceiveNames<'VKWebAppGetGroupInfo', 'VKWebAppGetGroupInfoResult', 'VKWebAppGetGroupInfoFailed'> & EventReceiveNames<'VKWebAppRetargetingPixel', 'VKWebAppRetargetingPixelResult', 'VKWebAppRetargetingPixelFailed'> & EventReceiveNames<'VKWebAppCheckAllowedScopes', 'VKWebAppCheckAllowedScopesResult', 'VKWebAppCheckAllowedScopesFailed'> & EventReceiveNames<'VKWebAppCheckSurvey', 'VKWebAppCheckSurveyResult', 'VKWebAppCheckSurveyFailed'> & EventReceiveNames<'VKWebAppShowSurvey', 'VKWebAppShowSurveyResult', 'VKWebAppShowSurveyFailed'> & EventReceiveNames<'VKWebAppConversionHit', 'VKWebAppConversionHitResult', 'VKWebAppConversionHitFailed'> & EventReceiveNames<'VKWebAppScrollTop', 'VKWebAppScrollTopResult', 'VKWebAppScrollTopFailed'> & EventReceiveNames<'VKWebAppScrollTopStart', 'VKWebAppScrollTopStartResult', 'VKWebAppScrollTopStop'> & EventReceiveNames<'VKWebAppScrollTopStop', 'VKWebAppScrollTopStopResult', 'VKWebAppScrollTopStopFailed'>; | ||
export {}; |
{ | ||
"name": "@vkontakte/vk-bridge", | ||
"version": "2.6.4", | ||
"version": "2.7.0", | ||
"description": "Connects a Mini App with VK client", | ||
@@ -22,18 +22,2 @@ "license": "MIT", | ||
}, | ||
"contributors": [ | ||
{ | ||
"name": "Tim Chaptykov", | ||
"email": "tim.chaptykov@gmail.com", | ||
"url": "https://vk.com/tc" | ||
}, | ||
{ | ||
"name": "Gleb Vorontsov", | ||
"email": "vorontsov.gleb@gmail.com", | ||
"url": "https://vk.com/boy" | ||
}, | ||
{ | ||
"name": "Danakt Frost", | ||
"url": "https://danakt.com" | ||
} | ||
], | ||
"repository": { | ||
@@ -40,0 +24,0 @@ "type": "git", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
361812
2228