Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

contentful-ui-extensions-sdk

Package Overview
Dependencies
Maintainers
11
Versions
195
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

contentful-ui-extensions-sdk - npm Package Compare versions

Comparing version 3.26.1 to 3.27.0-canary-openappconfig

CHANGELOG.md

2

dist/cf-extension-api.js

@@ -1,1 +0,1 @@

!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).contentfulExtension=t()}(this,(function(){"use strict";var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)};var t=function(){return(t=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 n(e){var t="function"==typeof Symbol&&e[Symbol.iterator],n=0;return t?t.call(e):{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}}}function r(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(e){o={error:e}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}function o(e){return this instanceof o?(this.v=e,this):new o(e)}function i(e,t,n){return e(n={path:t,exports:{},require:function(e,t){return function(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}(null==t&&n.path)}},n.exports),n.exports}function a(e){if(e.__esModule)return e;var t=Object.defineProperty({},"__esModule",{value:!0});return Object.keys(e).forEach((function(n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})})),t}var u=a(Object.freeze({__proto__:null,__extends:function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)},get __assign(){return t},__rest:function(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},__decorate:function(e,t,n,r){var o,i=arguments.length,a=i<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,r);else for(var u=e.length-1;u>=0;u--)(o=e[u])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a},__param:function(e,t){return function(n,r){t(n,r,e)}},__metadata:function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},__awaiter:function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(e){i(e)}}function u(e){try{l(r.throw(e))}catch(e){i(e)}}function l(e){e.done?o(e.value):new n((function(t){t(e.value)})).then(a,u)}l((r=r.apply(e,t||[])).next())}))},__generator:function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function u(i){return function(u){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,u])}}},__exportStar:function(e,t){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])},__values:n,__read:r,__spread:function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(r(arguments[t]));return e},__spreadArrays:function(){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],a=0,u=i.length;a<u;a++,o++)r[o]=i[a];return r},__await:o,__asyncGenerator:function(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r,i=n.apply(e,t||[]),a=[];return r={},u("next"),u("throw"),u("return"),r[Symbol.asyncIterator]=function(){return this},r;function u(e){i[e]&&(r[e]=function(t){return new Promise((function(n,r){a.push([e,t,n,r])>1||l(e,t)}))})}function l(e,t){try{(n=i[e](t)).value instanceof o?Promise.resolve(n.value.v).then(s,c):f(a[0][2],n)}catch(e){f(a[0][3],e)}var n}function s(e){l("next",e)}function c(e){l("throw",e)}function f(e,t){e(t),a.shift(),a.length&&l(a[0][0],a[0][1])}},__asyncDelegator:function(e){var t,n;return t={},r("next"),r("throw",(function(e){throw e})),r("return"),t[Symbol.iterator]=function(){return this},t;function r(r,i){t[r]=e[r]?function(t){return(n=!n)?{value:o(e[r](t)),done:"return"===r}:i?i(t):t}:i}},__asyncValues:function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,r=e[Symbol.asyncIterator];return r?r.call(e):(e=n(e),t={},o("next"),o("throw"),o("return"),t[Symbol.asyncIterator]=function(){return this},t);function o(n){t[n]=e[n]&&function(t){return new Promise((function(r,o){(function(e,t,n,r){Promise.resolve(r).then((function(t){e({value:t,done:n})}),t)})(r,o,(t=e[n](t)).done,t.value)}))}}},__makeTemplateObject:function(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e},__importStar:function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t},__importDefault:function(e){return e&&e.__esModule?e:{default:e}}})),l=i((function(e,t){var n;Object.defineProperty(t,"__esModule",{value:!0}),t.MemoizedSignal=t.Signal=void 0;var r=function(){function e(){this._id=0,this._listeners={}}return e.prototype.dispatch=function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];for(var r in this._listeners)(e=this._listeners)[r].apply(e,t)},e.prototype.attach=function(e){var t=this;if("function"!=typeof e)throw new Error("listener function expected");var n=this._id++;return this._listeners[n]=e,function(){return delete t._listeners[n]}},e}();t.Signal=r;var o="__private__memoized__arguments__",i=function(e){function t(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var i=e.call(this)||this;if(i[n]=[],!t.length)throw new Error("Initial value to be memoized expected");return i[o]=t,i}return u.__extends(t,e),t.prototype.dispatch=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];this[o]=t,e.prototype.dispatch.apply(this,t)},t.prototype.attach=function(t){var n=e.prototype.attach.call(this,t);return t.apply(void 0,this[o]),n},t}(r);t.MemoizedSignal=i,n=o})),s=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Channel=void 0,t.default=function(e,t){!function(e,t){function n(r){var o=r.data;"connect"===o.method&&(e.removeEventListener("message",n),t.apply(void 0,o.params))}e.addEventListener("message",n)}(e,(function(r,o){var i=new n(r.id,e);t(i,r,o)}))};var n=function(){function e(e,t){var n=this;this._messageHandlers={},this._responseHandlers={},this._send=function(e,t){var n=0;return function(r,o){var i=n++;return t.postMessage({source:e,id:i,method:r,params:o},"*"),i}}(e,t.parent),t.addEventListener("message",(function(e){n._handleMessage(e.data)}))}return e.prototype.call=function(e){for(var t=this,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];var o=this._send(e,n);return new Promise((function(e,n){t._responseHandlers[o]={resolve:e,reject:n}}))},e.prototype.send=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this._send(e,t)},e.prototype.addHandler=function(e,t){return e in this._messageHandlers||(this._messageHandlers[e]=new l.Signal),this._messageHandlers[e].attach(t)},e.prototype._handleMessage=function(e){if(e.method){var t=e.method,n=e.params,r=this._messageHandlers[t];r&&r.dispatch.apply(r,n)}else{var o=e.id,i=this._responseHandlers[o];if(!i)return;"result"in e?i.resolve(e.result):"error"in e&&i.reject(e.error),delete this._responseHandlers[o]}},e}();t.Channel=n})),c=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=u.__importDefault(s);t.default=function(e,t){var r,o=((r={promise:null,resolve:null}).promise=new Promise((function(e){r.resolve=e})),r);return o.promise.then((function(t){var n=t[0],r=e.document;r.addEventListener("focus",(function(){return n.send("setActive",!0)}),!0),r.addEventListener("blur",(function(){return n.send("setActive",!1)}),!0)})),n.default(e,(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return o.resolve(e)})),function(n,r){var i=void 0===r?{supressIframeWarning:!1}:r,a=i.makeCustomApi;i.supressIframeWarning||e.self!==e.top||console.error("Cannot use ui-extension-sdk outside of Contenful:\n\nIn order for the ui-extension-sdk to function correctly, your app needs to be run in an iframe in the Contentful Web App.\n\nLearn more about local development with the ui-extension-sdk here:\n https://www.contentful.com/developers/docs/extensibility/ui-extensions/faq/#how-can-i-use-the-ui-extension-sdk-locally"),o.promise.then((function(r){var o,i=r[0],u=r[1],l=r[2],s=t(i,u,e);"function"==typeof a&&(o=a(i,u)),l.forEach((function(e){i._handleMessage(e)})),n(s,o)}))}}})),f=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function e(e,t){var n=this;this.id=t.id,this.locale=t.locale,this.type=t.type,this.required=t.required,this.validations=t.validations,this.items=t.items,this._value=t.value,this._valueSignal=new l.MemoizedSignal(this._value),this._isDisabledSignal=new l.MemoizedSignal(void 0),this._schemaErrorsChangedSignal=new l.MemoizedSignal(void 0),this._channel=e,e.addHandler("valueChanged",(function(e,t,r){e!==n.id||t&&t!==n.locale||(n._value=r,n._valueSignal.dispatch(r))})),e.addHandler("isDisabledChangedForFieldLocale",(function(e,t,r){e===n.id&&t===n.locale&&n._isDisabledSignal.dispatch(r)})),e.addHandler("schemaErrorsChangedForFieldLocale",(function(e,t,r){e===n.id&&t===n.locale&&n._schemaErrorsChangedSignal.dispatch(r)}))}return e.prototype.getValue=function(){return this._value},e.prototype.setValue=function(e){return this._value=e,this._valueSignal.dispatch(e),this._channel.call("setValue",this.id,this.locale,e)},e.prototype.removeValue=function(){return this._value=void 0,this._channel.call("removeValue",this.id,this.locale)},e.prototype.setInvalid=function(e){return this._channel.call("setInvalid",e,this.locale)},e.prototype.onValueChanged=function(e){return this._valueSignal.attach(e)},e.prototype.onIsDisabledChanged=function(e){return this._isDisabledSignal.attach(e)},e.prototype.onSchemaErrorsChanged=function(e){return this._schemaErrorsChangedSignal.attach(e)},e}();t.default=n})),d=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=u.__importDefault(f),r=function(){function e(e,t,r){this.id=t.id,this.locales=t.locales,this.type=t.type,this.required=t.required,this.validations=t.validations,this.items=t.items,this._defaultLocale=r,this._fieldLocales=t.locales.reduce((function(r,o){var i,a=new n.default(e,{id:t.id,type:t.type,required:t.required,validations:t.validations,items:t.items,locale:o,value:t.values[o]});return u.__assign(u.__assign({},r),((i={})[o]=a,i))}),{}),this.assertHasLocale(r)}return e.prototype.getValue=function(e){return this._getFieldLocale(e).getValue()},e.prototype.setValue=function(e,t){return this._getFieldLocale(t).setValue(e)},e.prototype.removeValue=function(e){return this.setValue(void 0,e)},e.prototype.onValueChanged=function(e,t){var n=t||e;return t||(e=""),this._getFieldLocale(e).onValueChanged(n)},e.prototype.onIsDisabledChanged=function(e,t){var n=t||e;return t||(e=""),this._getFieldLocale(e).onIsDisabledChanged(n)},e.prototype._getFieldLocale=function(e){return e=e||this._defaultLocale,this.assertHasLocale(e),this._fieldLocales[e]},e.prototype.getForLocale=function(e){if(!e)throw new Error("getForLocale must be passed a locale");return this._getFieldLocale(e)},e.prototype.assertHasLocale=function(e){if(!this._fieldLocales[e])throw new Error('Unknown locale "'+e+'" for field "'+this.id+'"')},e}();t.default=r})),p=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n,r=e,o=r.document,i=r.MutationObserver,a=function(){s.updateHeight()},u=new i(a),l=!1,s={startAutoResizer:function(){if(s.updateHeight(),l)return;l=!0,u.observe(o.body,{attributes:!0,childList:!0,subtree:!0,characterData:!0}),e.addEventListener("resize",a)},stopAutoResizer:function(){if(!l)return;l=!1,u.disconnect(),e.removeEventListener("resize",a)},updateHeight:function(e){void 0===e&&(e=null);null===e&&(e=Math.ceil(o.documentElement.getBoundingClientRect().height));e!==n&&(t.send("setHeight",e),n=e)}};return s}})),h=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n,r){var o=t.sys,i=new l.MemoizedSignal(o),a=t.metadata;return e.addHandler("sysChanged",(function(e){o=e,i.dispatch(o)})),u.__assign({getSys:function(){return o},onSysChanged:function(e){return i.attach(e)},fields:n.reduce((function(e,t){return e[t.id]=r(t),e}),{})},a?{metadata:a}:{})}})),_=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=["getContentType","getEntry","getEntrySnapshots","getAsset","getEditorInterface","getPublishedEntries","getPublishedAssets","getContentTypes","getEntries","getEditorInterfaces","getAssets","createContentType","createEntry","createAsset","updateContentType","updateEntry","updateAsset","deleteContentType","deleteEntry","deleteAsset","publishEntry","publishAsset","unpublishEntry","unpublishAsset","archiveEntry","archiveAsset","unarchiveEntry","unarchiveAsset","createUpload","processAsset","waitUntilAssetProcessed","getUsers","getAllScheduledActions","getEntityScheduledActions","signRequest"];t.default=function(e,t,r){var o={};return n.forEach((function(t){"signRequest"===t&&r&&!r.app||(o[t]=function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return e.call("callSpaceMethod",t,n)})})),o.getCachedContentTypes=function(){return u.__spreadArrays(t)},o}})),y=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n=function(e){return"object"!=typeof(t=e)||null===t||Array.isArray(t)?{}:e;var t};t.default=function(e,t){return{openAlert:r.bind(null,"alert"),openConfirm:r.bind(null,"confirm"),openPrompt:r.bind(null,"prompt"),openExtension:o,openCurrentApp:i,openCurrent:function(e){return t.app?i(e):o(u.__assign(u.__assign({},e),{id:t.extension}))},selectSingleEntry:a.bind(null,"Entry",!1),selectSingleAsset:a.bind(null,"Asset",!1),selectMultipleEntries:a.bind(null,"Entry",!0),selectMultipleAssets:a.bind(null,"Asset",!0)};function r(t,r){return e.call("openDialog",t,n(r))}function o(r){if(r=n(r),(r=u.__assign(u.__assign({},r),{id:r.id||t.extension})).id)return e.call("openDialog","extension",r);throw new Error("Extension ID not provided.")}function i(r){if(r=n(r),t.app){var o=u.__assign(u.__assign({},r),{id:t.app});return e.call("openDialog","app",o)}throw new Error("Not in the app context.")}function a(t,r,o){return(o=n(o)).entityType=t,o.multiple=r,e.call("openDialog","entitySelector",o)}}})),v=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n=new l.MemoizedSignal(void 0),r=new l.MemoizedSignal(void 0);return e.addHandler("localeSettingsChanged",(function(e){n.dispatch(e)})),e.addHandler("showDisabledFieldsChanged",(function(e){r.dispatch(e)})),{editorInterface:t,onLocaleSettingsChanged:function(e){return n.attach(e)},onShowDisabledFieldsChanged:function(e){return r.attach(e)}}}})),g=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n=new l.Signal;return e.addHandler("navigateSlideIn",(function(e){n.dispatch(e)})),{openEntry:function(t,n){return e.call("navigateToContentEntity",u.__assign(u.__assign({},n),{entityType:"Entry",id:t}))},openNewEntry:function(t,n){return e.call("navigateToContentEntity",u.__assign(u.__assign({},n),{entityType:"Entry",id:null,contentTypeId:t}))},openBulkEditor:function(t,n){return e.call("navigateToBulkEditor",u.__assign({entryId:t},n))},openAsset:function(t,n){return e.call("navigateToContentEntity",u.__assign(u.__assign({},n),{entityType:"Asset",id:t}))},openNewAsset:function(t){return e.call("navigateToContentEntity",u.__assign(u.__assign({},t),{entityType:"Asset",id:null}))},openPageExtension:function(n){return e.call("navigateToPage",u.__assign({type:"extension",id:t.extension},n))},openCurrentAppPage:function(n){return e.call("navigateToPage",u.__assign({type:"app",id:t.app},n))},onSlideInNavigation:function(e){return n.attach(e)}}}})),m=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0});var n="preInstall",r="postInstall",o=function(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)},i=function(e){return"function"==typeof e},a=function(e){return console.error(e),Promise.resolve(!1)},u=function(e,t,n){if(!i(e))return Promise.resolve(t);var r;try{r=void 0===n?e():e(n)}catch(e){return a(e)}var u,l=r;return o(u=l)&&i(u.then)||(l=Promise.resolve(l)),l.then((function(e){return e instanceof Error?Promise.reject(e):!1!==e&&(o(e)?e:t)}),a).catch(a)};t.default=function(e){var t,o=((t={}).preInstall=null,t.postInstall=null,t),a=function(e,t){if(!i(t))throw new Error("Handler must be a function.");o[e]=t};return e.addHandler("appHook",(function(t){var i=t.stage,a=t.installationRequestId,l=t.err;return i===n?u(o[i],{}).then((function(t){return e.send("appHookResult",{stage:i,installationRequestId:a,result:t})})):i===r?u(o[i],void 0,l||null).then((function(){return e.send("appHookResult",{stage:i,installationRequestId:a})})):Promise.resolve()})),{setReady:function(){return e.call("callAppMethod","setReady")},isInstalled:function(){return e.call("callAppMethod","isInstalled")},getParameters:function(){return e.call("callAppMethod","getParameters")},getCurrentState:function(){return e.call("callAppMethod","getCurrentState")},onConfigure:function(e){a(n,e)},onConfigurationCompleted:function(e){a(r,e)}}}})),b=i((function(e,t){Object.defineProperty(t,"__esModule",{value:!0});t.default={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_CONFIG:"app-config"}})),w=i((function(e,t){var n;Object.defineProperty(t,"__esModule",{value:!0});var r=u.__importDefault(d),o=u.__importDefault(f),i=u.__importDefault(p),a=u.__importDefault(h),l=u.__importDefault(_),s=u.__importDefault(y),c=u.__importDefault(v),w=u.__importDefault(g),E=u.__importDefault(m),O=u.__importDefault(b),A=[C,T,function(e,t){var n=t.field;if(!n)throw new Error('FieldAPI called for location without "field" property defined.');return{field:new o.default(e,n)}},P,S],I=((n={})[O.default.LOCATION_ENTRY_FIELD]=A,n[O.default.LOCATION_ENTRY_FIELD_SIDEBAR]=A,n[O.default.LOCATION_ENTRY_SIDEBAR]=[C,T,P,S],n[O.default.LOCATION_ENTRY_EDITOR]=[C,T,P],n[O.default.LOCATION_DIALOG]=[C,function(e){return{close:function(t){return e.send("closeDialog",t)}}},S],n[O.default.LOCATION_PAGE]=[C],n[O.default.LOCATION_APP_CONFIG]=[C,function(e){return{app:E.default(e)}}],n);function C(e,t){var n=t.user,r=t.parameters,o=t.locales,i=t.ids,a=t.initialContentTypes,u=t.location||O.default.LOCATION_ENTRY_FIELD;return{location:{is:function(e){return u===e}},user:n,parameters:r,locales:{available:o.available,default:o.default,names:o.names,fallbacks:o.fallbacks,optional:o.optional,direction:o.direction},space:l.default(e,a,i),dialogs:s.default(e,i),navigator:w.default(e,i),notifier:{success:function(t){return e.send("notify",{type:"success",message:t})},error:function(t){return e.send("notify",{type:"error",message:t})}},ids:i,access:{can:function(t,n){return e.call("checkAccess",t,n)}}}}function S(e,t,n){return{window:i.default(n,e)}}function P(e,t){var n=t.editorInterface;return{editor:c.default(e,n)}}function T(e,t){var n=t.locales,o=t.contentType,i=t.entry,u=t.fieldInfo;return{contentType:o,entry:a.default(e,i,u,(function(t){return new r.default(e,t,n.default)}))}}t.default=function(e,t,n){return(I[t.location]||A).reduce((function(r,o){return u.__assign(u.__assign({},r),o(e,t,n))}),{})}})),E=u.__importDefault(c),O=u.__importDefault(w),A=u.__importDefault(b);return{init:E.default(window,O.default),locations:A.default}}));
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).contentfulExtension=t()}(this,(function(){"use strict";var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(t,n)};var t=function(){return(t=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 n(e){var t="function"==typeof Symbol&&e[Symbol.iterator],n=0;return t?t.call(e):{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}}}function r(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(e){o={error:e}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}function o(e){return this instanceof o?(this.v=e,this):new o(e)}function i(e){if(e.__esModule)return e;var t=Object.defineProperty({},"__esModule",{value:!0});return Object.keys(e).forEach((function(n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})})),t}function a(e){var t={exports:{}};return e(t,t.exports),t.exports}var l=i(Object.freeze({__proto__:null,__extends:function(t,n){function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)},get __assign(){return t},__rest:function(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},__decorate:function(e,t,n,r){var o,i=arguments.length,a=i<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,r);else for(var l=e.length-1;l>=0;l--)(o=e[l])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a},__param:function(e,t){return function(n,r){t(n,r,e)}},__metadata:function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},__awaiter:function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{s(r.next(e))}catch(e){i(e)}}function l(e){try{s(r.throw(e))}catch(e){i(e)}}function s(e){e.done?o(e.value):new n((function(t){t(e.value)})).then(a,l)}s((r=r.apply(e,t||[])).next())}))},__generator:function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function l(i){return function(l){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,l])}}},__exportStar:function(e,t){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])},__values:n,__read:r,__spread:function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(r(arguments[t]));return e},__spreadArrays:function(){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],a=0,l=i.length;a<l;a++,o++)r[o]=i[a];return r},__await:o,__asyncGenerator:function(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r,i=n.apply(e,t||[]),a=[];return r={},l("next"),l("throw"),l("return"),r[Symbol.asyncIterator]=function(){return this},r;function l(e){i[e]&&(r[e]=function(t){return new Promise((function(n,r){a.push([e,t,n,r])>1||s(e,t)}))})}function s(e,t){try{(n=i[e](t)).value instanceof o?Promise.resolve(n.value.v).then(u,c):f(a[0][2],n)}catch(e){f(a[0][3],e)}var n}function u(e){s("next",e)}function c(e){s("throw",e)}function f(e,t){e(t),a.shift(),a.length&&s(a[0][0],a[0][1])}},__asyncDelegator:function(e){var t,n;return t={},r("next"),r("throw",(function(e){throw e})),r("return"),t[Symbol.iterator]=function(){return this},t;function r(r,i){t[r]=e[r]?function(t){return(n=!n)?{value:o(e[r](t)),done:"return"===r}:i?i(t):t}:i}},__asyncValues:function(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,r=e[Symbol.asyncIterator];return r?r.call(e):(e=n(e),t={},o("next"),o("throw"),o("return"),t[Symbol.asyncIterator]=function(){return this},t);function o(n){t[n]=e[n]&&function(t){return new Promise((function(r,o){(function(e,t,n,r){Promise.resolve(r).then((function(t){e({value:t,done:n})}),t)})(r,o,(t=e[n](t)).done,t.value)}))}}},__makeTemplateObject:function(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e},__importStar:function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t},__importDefault:function(e){return e&&e.__esModule?e:{default:e}}})),s=a((function(e,t){var n;Object.defineProperty(t,"__esModule",{value:!0}),t.MemoizedSignal=t.Signal=void 0;var r=function(){function e(){this._id=0,this._listeners={}}return e.prototype.dispatch=function(){for(var e,t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];for(var r in this._listeners)(e=this._listeners)[r].apply(e,t)},e.prototype.attach=function(e){var t=this;if("function"!=typeof e)throw new Error("listener function expected");var n=this._id++;return this._listeners[n]=e,function(){return delete t._listeners[n]}},e}();t.Signal=r;var o="__private__memoized__arguments__",i=function(e){function t(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];var i=e.call(this)||this;if(i[n]=[],!t.length)throw new Error("Initial value to be memoized expected");return i[o]=t,i}return l.__extends(t,e),t.prototype.dispatch=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];this[o]=t,e.prototype.dispatch.apply(this,t)},t.prototype.attach=function(t){var n=e.prototype.attach.call(this,t);return t.apply(void 0,this[o]),n},t}(r);t.MemoizedSignal=i,n=o})),u=a((function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Channel=void 0,t.default=function(e,t){!function(e,t){function n(r){var o=r.data;"connect"===o.method&&(e.removeEventListener("message",n),t.apply(void 0,o.params))}e.addEventListener("message",n)}(e,(function(r,o){var i=new n(r.id,e);t(i,r,o)}))};var n=function(){function e(e,t){var n=this;this._messageHandlers={},this._responseHandlers={},this._send=function(e,t){var n=0;return function(r,o){var i=n++;return t.postMessage({source:e,id:i,method:r,params:o},"*"),i}}(e,t.parent),t.addEventListener("message",(function(e){n._handleMessage(e.data)}))}return e.prototype.call=function(e){for(var t=this,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];var o=this._send(e,n);return new Promise((function(e,n){t._responseHandlers[o]={resolve:e,reject:n}}))},e.prototype.send=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];this._send(e,t)},e.prototype.addHandler=function(e,t){return e in this._messageHandlers||(this._messageHandlers[e]=new s.Signal),this._messageHandlers[e].attach(t)},e.prototype._handleMessage=function(e){if(e.method){var t=e.method,n=e.params,r=this._messageHandlers[t];r&&r.dispatch.apply(r,n)}else{var o=e.id,i=this._responseHandlers[o];if(!i)return;"result"in e?i.resolve(e.result):"error"in e&&i.reject(e.error),delete this._responseHandlers[o]}},e}();t.Channel=n})),c=l.__importDefault(u);var f=function(e,t){var n,r=((n={promise:null,resolve:null}).promise=new Promise((function(e){n.resolve=e})),n);return r.promise.then((function(t){var n=t[0],r=e.document;r.addEventListener("focus",(function(){return n.send("setActive",!0)}),!0),r.addEventListener("blur",(function(){return n.send("setActive",!1)}),!0)})),c.default(e,(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return r.resolve(e)})),function(n,o){var i=void 0===o?{supressIframeWarning:!1}:o,a=i.makeCustomApi;i.supressIframeWarning||e.self!==e.top||console.error("Cannot use ui-extension-sdk outside of Contenful:\n\nIn order for the ui-extension-sdk to function correctly, your app needs to be run in an iframe in the Contentful Web App.\n\nLearn more about local development with the ui-extension-sdk here:\n https://www.contentful.com/developers/docs/extensibility/ui-extensions/faq/#how-can-i-use-the-ui-extension-sdk-locally"),r.promise.then((function(r){var o,i=r[0],l=r[1],s=r[2],u=t(i,l,e);"function"==typeof a&&(o=a(i,l)),s.forEach((function(e){i._handleMessage(e)})),n(u,o)}))}};var d=Object.defineProperty({default:f},"__esModule",{value:!0}),p=function(){function e(e,t){var n=this;this.id=t.id,this.locale=t.locale,this.type=t.type,this.required=t.required,this.validations=t.validations,this.items=t.items,this._value=t.value,this._valueSignal=new s.MemoizedSignal(this._value),this._isDisabledSignal=new s.MemoizedSignal(void 0),this._schemaErrorsChangedSignal=new s.MemoizedSignal(void 0),this._channel=e,e.addHandler("valueChanged",(function(e,t,r){e!==n.id||t&&t!==n.locale||(n._value=r,n._valueSignal.dispatch(r))})),e.addHandler("isDisabledChangedForFieldLocale",(function(e,t,r){e===n.id&&t===n.locale&&n._isDisabledSignal.dispatch(r)})),e.addHandler("schemaErrorsChangedForFieldLocale",(function(e,t,r){e===n.id&&t===n.locale&&n._schemaErrorsChangedSignal.dispatch(r)}))}return e.prototype.getValue=function(){return this._value},e.prototype.setValue=function(e){return this._value=e,this._valueSignal.dispatch(e),this._channel.call("setValue",this.id,this.locale,e)},e.prototype.removeValue=function(){return this._value=void 0,this._channel.call("removeValue",this.id,this.locale)},e.prototype.setInvalid=function(e){return this._channel.call("setInvalid",e,this.locale)},e.prototype.onValueChanged=function(e){return this._valueSignal.attach(e)},e.prototype.onIsDisabledChanged=function(e){return this._isDisabledSignal.attach(e)},e.prototype.onSchemaErrorsChanged=function(e){return this._schemaErrorsChangedSignal.attach(e)},e}(),h=Object.defineProperty({default:p},"__esModule",{value:!0}),_=l.__importDefault(h),y=function(){function e(e,t,n){this.id=t.id,this.locales=t.locales,this.type=t.type,this.required=t.required,this.validations=t.validations,this.items=t.items,this._defaultLocale=n,this._fieldLocales=t.locales.reduce((function(n,r){var o,i=new _.default(e,{id:t.id,type:t.type,required:t.required,validations:t.validations,items:t.items,locale:r,value:t.values[r]});return l.__assign(l.__assign({},n),((o={})[r]=i,o))}),{}),this.assertHasLocale(n)}return e.prototype.getValue=function(e){return this._getFieldLocale(e).getValue()},e.prototype.setValue=function(e,t){return this._getFieldLocale(t).setValue(e)},e.prototype.removeValue=function(e){return this.setValue(void 0,e)},e.prototype.onValueChanged=function(e,t){var n=t||e;return t||(e=""),this._getFieldLocale(e).onValueChanged(n)},e.prototype.onIsDisabledChanged=function(e,t){var n=t||e;return t||(e=""),this._getFieldLocale(e).onIsDisabledChanged(n)},e.prototype._getFieldLocale=function(e){return e=e||this._defaultLocale,this.assertHasLocale(e),this._fieldLocales[e]},e.prototype.getForLocale=function(e){if(!e)throw new Error("getForLocale must be passed a locale");return this._getFieldLocale(e)},e.prototype.assertHasLocale=function(e){if(!this._fieldLocales[e])throw new Error('Unknown locale "'+e+'" for field "'+this.id+'"')},e}(),v=Object.defineProperty({default:y},"__esModule",{value:!0});var g=function(e,t){var n,r=e,o=r.document,i=r.MutationObserver,a=function(){u.updateHeight()},l=new i(a),s=!1,u={startAutoResizer:function(){if(u.updateHeight(),s)return;s=!0,l.observe(o.body,{attributes:!0,childList:!0,subtree:!0,characterData:!0}),e.addEventListener("resize",a)},stopAutoResizer:function(){if(!s)return;s=!1,l.disconnect(),e.removeEventListener("resize",a)},updateHeight:function(e){void 0===e&&(e=null);null===e&&(e=Math.ceil(o.documentElement.getBoundingClientRect().height));e!==n&&(t.send("setHeight",e),n=e)}};return u},m=Object.defineProperty({default:g},"__esModule",{value:!0});var b=function(e,t,n,r){var o=t.sys,i=new s.MemoizedSignal(o),a=t.metadata;return e.addHandler("sysChanged",(function(e){o=e,i.dispatch(o)})),l.__assign({getSys:function(){return o},onSysChanged:function(e){return i.attach(e)},fields:n.reduce((function(e,t){return e[t.id]=r(t),e}),{})},a?{metadata:a}:{})},w=Object.defineProperty({default:b},"__esModule",{value:!0}),E=["getContentType","getEntry","getEntrySnapshots","getAsset","getEditorInterface","getPublishedEntries","getPublishedAssets","getContentTypes","getEntries","getEditorInterfaces","getAssets","createContentType","createEntry","createAsset","updateContentType","updateEntry","updateAsset","deleteContentType","deleteEntry","deleteAsset","publishEntry","publishAsset","unpublishEntry","unpublishAsset","archiveEntry","archiveAsset","unarchiveEntry","unarchiveAsset","createUpload","processAsset","waitUntilAssetProcessed","getUsers","getAllScheduledActions","getEntityScheduledActions","signRequest"];var O=function(e,t,n){var r={};return E.forEach((function(t){"signRequest"===t&&n&&!n.app||(r[t]=function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return e.call("callSpaceMethod",t,n)})})),r.getCachedContentTypes=function(){return l.__spreadArrays(t)},r},A=Object.defineProperty({default:O},"__esModule",{value:!0}),I=function(e){return"object"!=typeof(t=e)||null===t||Array.isArray(t)?{}:e;var t};var C=function(e,t){return{openAlert:n.bind(null,"alert"),openConfirm:n.bind(null,"confirm"),openPrompt:n.bind(null,"prompt"),openExtension:r,openCurrentApp:o,openCurrent:function(e){return t.app?o(e):r(l.__assign(l.__assign({},e),{id:t.extension}))},selectSingleEntry:i.bind(null,"Entry",!1),selectSingleAsset:i.bind(null,"Asset",!1),selectMultipleEntries:i.bind(null,"Entry",!0),selectMultipleAssets:i.bind(null,"Asset",!0)};function n(t,n){return e.call("openDialog",t,I(n))}function r(n){if(n=I(n),(n=l.__assign(l.__assign({},n),{id:n.id||t.extension})).id)return e.call("openDialog","extension",n);throw new Error("Extension ID not provided.")}function o(n){if(n=I(n),t.app){var r=l.__assign(l.__assign({},n),{id:t.app});return e.call("openDialog","app",r)}throw new Error("Not in the app context.")}function i(t,n,r){return(r=I(r)).entityType=t,r.multiple=n,e.call("openDialog","entitySelector",r)}},S=Object.defineProperty({default:C},"__esModule",{value:!0});var P=function(e,t){var n=new s.MemoizedSignal(void 0),r=new s.MemoizedSignal(void 0);return e.addHandler("localeSettingsChanged",(function(e){n.dispatch(e)})),e.addHandler("showDisabledFieldsChanged",(function(e){r.dispatch(e)})),{editorInterface:t,onLocaleSettingsChanged:function(e){return n.attach(e)},onShowDisabledFieldsChanged:function(e){return r.attach(e)}}},T=Object.defineProperty({default:P},"__esModule",{value:!0});var L=function(e,t){var n=new s.Signal;return e.addHandler("navigateSlideIn",(function(e){n.dispatch(e)})),{openEntry:function(t,n){return e.call("navigateToContentEntity",l.__assign(l.__assign({},n),{entityType:"Entry",id:t}))},openNewEntry:function(t,n){return e.call("navigateToContentEntity",l.__assign(l.__assign({},n),{entityType:"Entry",id:null,contentTypeId:t}))},openBulkEditor:function(t,n){return e.call("navigateToBulkEditor",l.__assign({entryId:t},n))},openAsset:function(t,n){return e.call("navigateToContentEntity",l.__assign(l.__assign({},n),{entityType:"Asset",id:t}))},openNewAsset:function(t){return e.call("navigateToContentEntity",l.__assign(l.__assign({},t),{entityType:"Asset",id:null}))},openPageExtension:function(n){return e.call("navigateToPage",l.__assign({type:"extension",id:t.extension},n))},openCurrentAppPage:function(n){return e.call("navigateToPage",l.__assign({type:"app",id:t.app},n))},openAppConfig:function(){return e.call("navigateToAppConfig")},onSlideInNavigation:function(e){return n.attach(e)}}},D=Object.defineProperty({default:L},"__esModule",{value:!0}),j="preInstall",x="postInstall",M=function(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)},R=function(e){return"function"==typeof e},N=function(e){return console.error(e),Promise.resolve(!1)},H=function(e,t,n){if(!R(e))return Promise.resolve(t);var r;try{r=void 0===n?e():e(n)}catch(e){return N(e)}var o,i=r;return M(o=i)&&R(o.then)||(i=Promise.resolve(i)),i.then((function(e){return e instanceof Error?Promise.reject(e):!1!==e&&(M(e)?e:t)}),N).catch(N)};var F,k=function(e){var t,n=((t={}).preInstall=null,t.postInstall=null,t),r=function(e,t){if(!R(t))throw new Error("Handler must be a function.");n[e]=t};return e.addHandler("appHook",(function(t){var r=t.stage,o=t.installationRequestId,i=t.err;return r===j?H(n[r],{}).then((function(t){return e.send("appHookResult",{stage:r,installationRequestId:o,result:t})})):r===x?H(n[r],void 0,i||null).then((function(){return e.send("appHookResult",{stage:r,installationRequestId:o})})):Promise.resolve()})),{setReady:function(){return e.call("callAppMethod","setReady")},isInstalled:function(){return e.call("callAppMethod","isInstalled")},getParameters:function(){return e.call("callAppMethod","getParameters")},getCurrentState:function(){return e.call("callAppMethod","getCurrentState")},onConfigure:function(e){r(j,e)},onConfigurationCompleted:function(e){r(x,e)}}},z=Object.defineProperty({default:k},"__esModule",{value:!0}),V={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_CONFIG:"app-config"},q=Object.defineProperty({default:V},"__esModule",{value:!0}),Y=l.__importDefault(v),G=l.__importDefault(h),B=l.__importDefault(m),U=l.__importDefault(w),W=l.__importDefault(A),J=l.__importDefault(S),K=l.__importDefault(T),Q=l.__importDefault(D),X=l.__importDefault(z),Z=l.__importDefault(q),$=[ne,ie,function(e,t){var n=t.field;if(!n)throw new Error('FieldAPI called for location without "field" property defined.');return{field:new G.default(e,n)}},oe,re],ee=((F={})[Z.default.LOCATION_ENTRY_FIELD]=$,F[Z.default.LOCATION_ENTRY_FIELD_SIDEBAR]=$,F[Z.default.LOCATION_ENTRY_SIDEBAR]=[ne,ie,oe,re],F[Z.default.LOCATION_ENTRY_EDITOR]=[ne,ie,oe],F[Z.default.LOCATION_DIALOG]=[ne,function(e){return{close:function(t){return e.send("closeDialog",t)}}},re],F[Z.default.LOCATION_PAGE]=[ne],F[Z.default.LOCATION_APP_CONFIG]=[ne,function(e){return{app:X.default(e)}}],F);var te=function(e,t,n){return(ee[t.location]||$).reduce((function(r,o){return l.__assign(l.__assign({},r),o(e,t,n))}),{})};function ne(e,t){var n=t.user,r=t.parameters,o=t.locales,i=t.ids,a=t.initialContentTypes,l=t.location||Z.default.LOCATION_ENTRY_FIELD;return{location:{is:function(e){return l===e}},user:n,parameters:r,locales:{available:o.available,default:o.default,names:o.names,fallbacks:o.fallbacks,optional:o.optional,direction:o.direction},space:W.default(e,a,i),dialogs:J.default(e,i),navigator:Q.default(e,i),notifier:{success:function(t){return e.send("notify",{type:"success",message:t})},error:function(t){return e.send("notify",{type:"error",message:t})}},ids:i,access:{can:function(t,n){return e.call("checkAccess",t,n)}}}}function re(e,t,n){return{window:B.default(n,e)}}function oe(e,t){var n=t.editorInterface;return{editor:K.default(e,n)}}function ie(e,t){var n=t.locales,r=t.contentType,o=t.entry,i=t.fieldInfo;return{contentType:r,entry:U.default(e,o,i,(function(t){return new Y.default(e,t,n.default)}))}}var ae=Object.defineProperty({default:te},"__esModule",{value:!0}),le=l.__importDefault(d),se=l.__importDefault(ae),ue=l.__importDefault(q);return{init:le.default(window,se.default),locations:ue.default}}));
{
"name": "contentful-ui-extensions-sdk",
"description": "SDK to develop custom UI Extension for the Contentful Web App",
"version": "3.26.1",
"version": "3.27.0-canary-openappconfig",
"author": "Contentful GmbH",

@@ -29,14 +29,19 @@ "license": "MIT",

"merge-report": "mochawesome-merge ./test/cypress/reports/separate-reports/*.json > ./test/cypress/reports/full_report.json",
"generate-report": "npx mochawesome-report-generator --reportDir test/cypress/reports test/cypress/reports/full_report.json"
"generate-report": "npx mochawesome-report-generator --reportDir test/cypress/reports test/cypress/reports/full_report.json",
"semantic-release": "semantic-release",
"publish-all": "node ./scripts/publish.js"
},
"devDependencies": {
"@rollup/plugin-commonjs": "16.0.0",
"@rollup/plugin-node-resolve": "10.0.0",
"@rollup/plugin-typescript": "6.1.0",
"@testing-library/cypress": "7.0.1",
"@testing-library/dom": "7.28.1",
"@rollup/plugin-commonjs": "17.0.0",
"@rollup/plugin-node-resolve": "11.0.1",
"@rollup/plugin-typescript": "8.1.0",
"@semantic-release/changelog": "5.0.1",
"@semantic-release/exec": "5.0.0",
"@semantic-release/git": "9.0.0",
"@testing-library/cypress": "7.0.3",
"@testing-library/dom": "7.29.1",
"@types/async-retry": "1.4.2",
"@types/chai-as-promised": "7.1.3",
"@types/cross-spawn": "6.0.2",
"@types/fs-extra": "9.0.4",
"@types/fs-extra": "9.0.6",
"@types/jsdom": "16.2.5",

@@ -46,4 +51,4 @@ "@types/nanoid": "2.1.0",

"@types/sinon-chai": "^3.2.5",
"@typescript-eslint/eslint-plugin": "4.8.2",
"@typescript-eslint/parser": "4.8.2",
"@typescript-eslint/eslint-plugin": "4.12.0",
"@typescript-eslint/parser": "4.12.0",
"async-retry": "1.3.1",

@@ -53,8 +58,8 @@ "babel-eslint": "10.1.0",

"chai-as-promised": "7.1.1",
"contentful-management": "7.3.0",
"contentful-management": "7.5.1",
"cross-spawn": "7.0.3",
"cypress": "5.6.0",
"cypress": "6.2.1",
"dotenv": "8.2.0",
"eslint": "7.14.0",
"eslint-config-prettier": "6.15.0",
"eslint": "7.17.0",
"eslint-config-prettier": "7.1.0",
"eslint-config-standard": "16.0.2",

@@ -64,10 +69,10 @@ "eslint-plugin-cypress": "2.11.2",

"eslint-plugin-node": "11.1.0",
"eslint-plugin-prettier": "3.1.4",
"eslint-plugin-prettier": "3.3.1",
"eslint-plugin-promise": "4.2.1",
"eslint-plugin-react": "7.21.5",
"eslint-plugin-react": "7.22.0",
"eslint-plugin-standard": "5.0.0",
"fs-extra": "9.0.1",
"husky": "4.3.0",
"husky": "4.3.6",
"jsdom": "16.4.0",
"lint-staged": "10.5.2",
"lint-staged": "10.5.3",
"mocha": "8.2.1",

@@ -77,11 +82,12 @@ "mochawesome": "6.2.1",

"mochawesome-report-generator": "5.1.0",
"nanoid": "3.1.18",
"prettier": "2.2.0",
"rollup": "2.33.3",
"nanoid": "3.1.20",
"prettier": "2.2.1",
"rollup": "2.36.1",
"rollup-plugin-terser": "7.0.2",
"sinon": "9.2.1",
"semantic-release": "17.3.1",
"sinon": "9.2.3",
"sinon-chai": "3.5.0",
"ts-mocha": "8.0.0",
"ts-node": "9.0.0",
"typescript": "4.1.2"
"ts-node": "9.1.1",
"typescript": "4.1.3"
},

@@ -103,3 +109,35 @@ "husky": {

]
},
"release": {
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/changelog",
[
"@semantic-release/npm",
{
"npmPublish": false
}
],
[
"@semantic-release/exec",
{
"verifyConditionsCmd": "node ./scripts/verify.js",
"publishCmd": "npm run publish-all"
}
],
[
"@semantic-release/git",
{
"message": "chore: ${nextRelease.version} [skip ci]\n\n${nextRelease.notes}",
"assets": [
"CHANGELOG.md",
"package.json",
"package-lock.json"
]
}
],
"@semantic-release/github"
]
}
}

@@ -26,1 +26,14 @@ # Contentful UI Extensions SDK

[support system](https://www.contentful.com/support/).
## Development
### publish
A new package version is automatically published to npm using [semantic-release](https://github.com/semantic-release/semantic-release).
To manually publish the package, run `node ./scripts/publish.js`.
We always publish two packages with identical data:
- `contentful-ui-extensions-sdk`
- `@contentful/ui-extensions-sdk`

@@ -453,2 +453,3 @@ export declare type EntityType = 'Entry' | 'Asset';

}>;
openAppConfig: () => Promise<void>;
onSlideInNavigation: (fn: (slide: NavigatorSlideInfo) => void) => Function;

@@ -455,0 +456,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc