contentful-ui-extensions-sdk
Advanced tools
Comparing version 3.9.2 to 3.9.3
@@ -32,3 +32,3 @@ parcelRequire=function(e,r,t,n){var i,o="function"==typeof parcelRequire&&parcelRequire,u="function"==typeof require&&require;function f(t,n){if(!r[t]){if(!e[t]){var i="function"==typeof parcelRequire&&parcelRequire;if(!n&&i)return i(t,!0);if(o)return o(t,!0);if(u&&"string"==typeof t)return u(t);var c=new Error("Cannot find module '"+t+"'");throw c.code="MODULE_NOT_FOUND",c}p.resolve=function(r){return e[t][1][r]||r},p.cache={};var l=r[t]=new f.Module(t);e[t][0].call(l.exports,p,l,l.exports,this)}return r[t].exports;function p(e){return f(p.resolve(e))}}f.isParcelRequire=!0,f.Module=function(e){this.id=e,this.bundle=f,this.exports={}},f.modules=e,f.cache=r,f.parent=o,f.register=function(r,t){e[r]=[function(e,r){r.exports=t},{}]};for(var c=0;c<t.length;c++)try{f(t[c])}catch(e){i||(i=e)}if(t.length){var l=f(t[t.length-1]);"object"==typeof exports&&"undefined"!=typeof module?module.exports=l:"function"==typeof define&&define.amd?define(function(){return l}):n&&(this[n]=l)}if(parcelRequire=f,i)throw i;return f}({"pBGv":[function(require,module,exports) { | ||
},{}],"A2T1":[function(require,module,exports) { | ||
function t(t,n,r){return n in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,t}function n(t){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var r="preInstall",e="postInstall",o=function(t){return"object"===n(t)&&null!==t&&!Array.isArray(t)},u=function(t){return"function"==typeof t},l=function(t){return o(t)&&u(t.then)},a=function(t){if(!u(t))return Promise.resolve({});var n;try{n=t()}catch(e){return Promise.resolve(!1)}var r=n;return l(r)||(r=Promise.resolve(r)),r.then(function(t){return!(t instanceof Error||!1===t)&&(o(t)?t:{})},function(){return!1}).catch(function(){return!1})};module.exports=function(n){var o,l=(t(o={},r,null),t(o,e,null),o);return n.addHandler("appHook",function(t){var r=t.stage,e=t.installationRequestId;return a(l[r]).then(function(t){n.send("appHookResult",{stage:r,installationRequestId:e,result:t})})}),{isInstalled:function(){return n.call("callAppMethod","isInstalled")},getParameters:function(){return n.call("callAppMethod","getParameters")},getCurrentState:function(){return n.call("callAppMethod","getCurrentState")},onConfigure:function(t){!function(t,n){if(l[t])throw new Error("Cannot register a handler twice.");if(!u(n))throw new Error("Handler must be a function.");l[t]=n}(r,t)}}}; | ||
function t(t,n,e){return n in t?Object.defineProperty(t,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[n]=e,t}function n(t){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var e="preInstall",r="postInstall",o=function(t){return"object"===n(t)&&null!==t&&!Array.isArray(t)},u=function(t){return"function"==typeof t},l=function(t){return o(t)&&u(t.then)},a=function(t){if(!u(t))return Promise.resolve({});var n;try{n=t()}catch(r){return Promise.resolve(!1)}var e=n;return l(e)||(e=Promise.resolve(e)),e.then(function(t){return!(t instanceof Error||!1===t)&&(o(t)?t:{})},function(){return!1}).catch(function(){return!1})};module.exports=function(n){var o,l=(t(o={},e,null),t(o,r,null),o);return n.addHandler("appHook",function(t){var e=t.stage,r=t.installationRequestId;return a(l[e]).then(function(t){n.send("appHookResult",{stage:e,installationRequestId:r,result:t})})}),{isInstalled:function(){return n.call("callAppMethod","isInstalled")},getParameters:function(){return n.call("callAppMethod","getParameters")},getCurrentState:function(){return n.call("callAppMethod","getCurrentState")},onConfigure:function(t){!function(t,n){if(l[t])throw new Error("Cannot register a handler twice.");if(!u(n))throw new Error("Handler must be a function.");l[t]=n}(e,t)},isReady:function(){return n.call("callAppMethod","isReady")}}}; | ||
},{}],"CHnp":[function(require,module,exports) { | ||
@@ -35,0 +35,0 @@ module.exports={LOCATION_ENTRY_FIELD:"entry-field",LOCATION_ENTRY_FIELD_SIDEBAR:"entry-field-sidebar",LOCATION_ENTRY_SIDEBAR:"entry-sidebar",LOCATION_DIALOG:"dialog",LOCATION_ENTRY_EDITOR:"entry-editor",LOCATION_PAGE:"page",LOCATION_APP:"app"}; |
@@ -81,4 +81,7 @@ const HOOK_STAGE_PRE_INSTALL = 'preInstall' | ||
setHandler(HOOK_STAGE_PRE_INSTALL, handler) | ||
}, | ||
isReady() { | ||
return channel.call('callAppMethod', 'isReady') | ||
} | ||
} | ||
} |
{ | ||
"name": "contentful-ui-extensions-sdk", | ||
"description": "SDK to develop custom UI Extension for the Contentful Web App", | ||
"version": "3.9.2", | ||
"version": "3.9.3", | ||
"author": "Contentful GmbH", | ||
@@ -6,0 +6,0 @@ "license": "MIT", |
@@ -177,3 +177,3 @@ declare module 'contentful-ui-extensions-sdk' { | ||
type CollectionReponse<T> = { | ||
type CollectionResponse<T> = { | ||
items: T[]; | ||
@@ -188,3 +188,3 @@ total: number; | ||
getContentType: (id: string) => Promise<Object>; | ||
getContentTypes: () => Promise<CollectionReponse<Object>>; | ||
getContentTypes: () => Promise<CollectionResponse<Object>>; | ||
createContentType: (data: any) => Promise<Object>; | ||
@@ -196,3 +196,3 @@ updateContentType: (data: any) => Promise<Object>; | ||
getEntrySnapshots: (id: string) => Promise<any>; | ||
getEntries: (query?: SearchQuery) => Promise<CollectionReponse<Object>>; | ||
getEntries: (query?: SearchQuery) => Promise<CollectionResponse<Object>>; | ||
createEntry: (contentTypeId: string, data: any) => Promise<Object>; | ||
@@ -205,6 +205,6 @@ updateEntry: (data: any) => Promise<Object>; | ||
deleteEntry: (data: any) => Promise<Object>; | ||
getPublishedEntries: (query?: SearchQuery) => Promise<CollectionReponse<Object>>; | ||
getPublishedEntries: (query?: SearchQuery) => Promise<CollectionResponse<Object>>; | ||
getAsset: (id: string) => Promise<Object>; | ||
getAssets: (query?: SearchQuery) => Promise<CollectionReponse<Object>>; | ||
getAssets: (query?: SearchQuery) => Promise<CollectionResponse<Object>>; | ||
createAsset: (data: any) => Promise<Object>; | ||
@@ -218,3 +218,3 @@ updateAsset: (data: any) => Promise<Object>; | ||
unarchiveAsset: (data: any) => Promise<Object>; | ||
getPublishedAssets: (query?: SearchQuery) => Promise<CollectionReponse<Object>>; | ||
getPublishedAssets: (query?: SearchQuery) => Promise<CollectionResponse<Object>>; | ||
createUpload: (base64data: string) => void; | ||
@@ -224,3 +224,3 @@ waitUntilAssetProcessed: (assetId: string, locale: string) => void; | ||
/** Returns all users who belong to the space. */ | ||
getUsers: () => Promise<CollectionReponse<Object>>, | ||
getUsers: () => Promise<CollectionResponse<Object>>, | ||
@@ -449,9 +449,11 @@ /** Returns editor interface for a given content type */ | ||
/** Returns true if an App is installed **/ | ||
isInstalled: () => boolean | ||
isInstalled: () => Promise<boolean> | ||
/** Returns parameters of an App, null otherwise **/ | ||
getParameters: () => null | Object | ||
getParameters: () => Promise<null | Object> | ||
/** Returns current state of an App, null otherwise **/ | ||
getCurrentState: () => null | Object | ||
getCurrentState: () => Promise<null | Object> | ||
/** Registers a handler to be called to produce parameters and target state for an App **/ | ||
onConfigure: (handler: Function) => void | ||
onConfigure: (handler: Function) => Promise<void> | ||
/** Tells the web app that the app is loaded */ | ||
isReady: () => Promise<void> | ||
} | ||
@@ -458,0 +460,0 @@ } |
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
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
85041
1765
1
3