commandbar 1.6.15 → 1.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,10 @@
1
+ import Launcher, { getControlKey } from 'commandbar-launcher';
1
2
  import { CommandBarClientSDK } from '../../internal/src/client/CommandBarClientSDK';
2
3
  export { default as init } from './init';
3
4
  export { initProxySDK as initProxy } from '../../internal/src/client/proxy';
4
5
  export { snippet } from './snippet';
5
6
  export { CommandBarClientSDK };
7
+ export { Launcher, getControlKey };
6
8
  declare global {
7
9
  interface Window {
8
10
  CommandBar: CommandBarClientSDK;
@@ -1 +1,2 @@
1
- !function(t,r){"object"==typeof exports&&"object"==typeof module?module.exports=r():"function"==typeof define&&define.amd?define([],r):"object"==typeof exports?exports.commandbar=r():t.commandbar=r()}(this,(function(){return(()=>{var t={296:(t,r,e)=>{"use strict";var o=e(102),n=e(307),i=e(339),a=e(957),s=e(246),c=t.exports=function(t,r){var e,n,c,u,l;return arguments.length<2||"string"!=typeof t?(u=r,r=t,t=null):u=arguments[2],o(t)?(e=s.call(t,"c"),n=s.call(t,"e"),c=s.call(t,"w")):(e=c=!0,n=!1),l={value:r,configurable:e,enumerable:n,writable:c},u?i(a(u),l):l};c.gs=function(t,r,e){var c,u,l,f;return"string"!=typeof t?(l=e,e=r,r=t,t=null):l=arguments[3],o(r)?n(r)?o(e)?n(e)||(l=e,e=void 0):e=void 0:(l=r,r=e=void 0):r=void 0,o(t)?(c=s.call(t,"c"),u=s.call(t,"e")):(c=!0,u=!1),f={get:r,set:e,configurable:c,enumerable:u},l?i(a(l),f):f}},817:t=>{"use strict";t.exports=function(){}},339:(t,r,e)=>{"use strict";t.exports=e(994)()?Object.assign:e(963)},994:t=>{"use strict";t.exports=function(){var t,r=Object.assign;return"function"==typeof r&&(r(t={foo:"raz"},{bar:"dwa"},{trzy:"trzy"}),t.foo+t.bar+t.trzy==="razdwatrzy")}},963:(t,r,e)=>{"use strict";var o=e(450),n=e(836),i=Math.max;t.exports=function(t,r){var e,a,s,c=i(arguments.length,2);for(t=Object(n(t)),s=function(o){try{t[o]=r[o]}catch(t){e||(e=t)}},a=1;a<c;++a)o(r=arguments[a]).forEach(s);if(void 0!==e)throw e;return t}},349:(t,r,e)=>{"use strict";var o=e(817)();t.exports=function(t){return t!==o&&null!==t}},450:(t,r,e)=>{"use strict";t.exports=e(446)()?Object.keys:e(177)},446:t=>{"use strict";t.exports=function(){try{return Object.keys("primitive"),!0}catch(t){return!1}}},177:(t,r,e)=>{"use strict";var o=e(349),n=Object.keys;t.exports=function(t){return n(o(t)?Object(t):t)}},957:(t,r,e)=>{"use strict";var o=e(349),n=Array.prototype.forEach,i=Object.create,a=function(t,r){var e;for(e in t)r[e]=t[e]};t.exports=function(t){var r=i(null);return n.call(arguments,(function(t){o(t)&&a(Object(t),r)})),r}},836:(t,r,e)=>{"use strict";var o=e(349);t.exports=function(t){if(!o(t))throw new TypeError("Cannot use null or undefined");return t}},246:(t,r,e)=>{"use strict";t.exports=e(711)()?String.prototype.contains:e(370)},711:t=>{"use strict";var r="razdwatrzy";t.exports=function(){return"function"==typeof r.contains&&!0===r.contains("dwa")&&!1===r.contains("foo")}},370:t=>{"use strict";var r=String.prototype.indexOf;t.exports=function(t){return r.call(this,t,arguments[1])>-1}},992:(t,r,e)=>{"use strict";e(98).polyfill()},98:t=>{"use strict";function r(t,r){if(null==t)throw new TypeError("Cannot convert first argument to object");for(var e=Object(t),o=1;o<arguments.length;o++){var n=arguments[o];if(null!=n)for(var i=Object.keys(Object(n)),a=0,s=i.length;a<s;a++){var c=i[a],u=Object.getOwnPropertyDescriptor(n,c);void 0!==u&&u.enumerable&&(e[c]=n[c])}}return e}t.exports={assign:r,polyfill:function(){Object.assign||Object.defineProperty(Object,"assign",{enumerable:!1,configurable:!0,writable:!0,value:r})}}},769:(t,r,e)=>{"use strict";e(614)()||Object.defineProperty(e(119),"Symbol",{value:e(798),configurable:!0,enumerable:!1,writable:!0})},614:(t,r,e)=>{"use strict";var o=e(119),n={object:!0,symbol:!0};t.exports=function(){var t,r=o.Symbol;if("function"!=typeof r)return!1;t=r("test symbol");try{String(t)}catch(t){return!1}return!!n[typeof r.iterator]&&!!n[typeof r.toPrimitive]&&!!n[typeof r.toStringTag]}},64:t=>{"use strict";t.exports=function(t){return!!t&&("symbol"==typeof t||!!t.constructor&&"Symbol"===t.constructor.name&&"Symbol"===t[t.constructor.toStringTag])}},573:(t,r,e)=>{"use strict";var o=e(296),n=Object.create,i=Object.defineProperty,a=Object.prototype,s=n(null);t.exports=function(t){for(var r,e,n=0;s[t+(n||"")];)++n;return s[t+=n||""]=!0,i(a,r="@@"+t,o.gs(null,(function(t){e||(e=!0,i(this,r,o(t)),e=!1)}))),r}},572:(t,r,e)=>{"use strict";var o=e(296),n=e(119).Symbol;t.exports=function(t){return Object.defineProperties(t,{hasInstance:o("",n&&n.hasInstance||t("hasInstance")),isConcatSpreadable:o("",n&&n.isConcatSpreadable||t("isConcatSpreadable")),iterator:o("",n&&n.iterator||t("iterator")),match:o("",n&&n.match||t("match")),replace:o("",n&&n.replace||t("replace")),search:o("",n&&n.search||t("search")),species:o("",n&&n.species||t("species")),split:o("",n&&n.split||t("split")),toPrimitive:o("",n&&n.toPrimitive||t("toPrimitive")),toStringTag:o("",n&&n.toStringTag||t("toStringTag")),unscopables:o("",n&&n.unscopables||t("unscopables"))})}},781:(t,r,e)=>{"use strict";var o=e(296),n=e(11),i=Object.create(null);t.exports=function(t){return Object.defineProperties(t,{for:o((function(r){return i[r]?i[r]:i[r]=t(String(r))})),keyFor:o((function(t){var r;for(r in n(t),i)if(i[r]===t)return r}))})}},798:(t,r,e)=>{"use strict";var o,n,i,a=e(296),s=e(11),c=e(119).Symbol,u=e(573),l=e(572),f=e(781),p=Object.create,d=Object.defineProperties,m=Object.defineProperty;if("function"==typeof c)try{String(c()),i=!0}catch(t){}else c=null;n=function(t){if(this instanceof n)throw new TypeError("Symbol is not a constructor");return o(t)},t.exports=o=function t(r){var e;if(this instanceof t)throw new TypeError("Symbol is not a constructor");return i?c(r):(e=p(n.prototype),r=void 0===r?"":String(r),d(e,{__description__:a("",r),__name__:a("",u(r))}))},l(o),f(o),d(n.prototype,{constructor:a(o),toString:a("",(function(){return this.__name__}))}),d(o.prototype,{toString:a((function(){return"Symbol ("+s(this).__description__+")"})),valueOf:a((function(){return s(this)}))}),m(o.prototype,o.toPrimitive,a("",(function(){var t=s(this);return"symbol"==typeof t?t:t.toString()}))),m(o.prototype,o.toStringTag,a("c","Symbol")),m(n.prototype,o.toStringTag,a("c",o.prototype[o.toStringTag])),m(n.prototype,o.toPrimitive,a("c",o.prototype[o.toPrimitive]))},11:(t,r,e)=>{"use strict";var o=e(64);t.exports=function(t){if(!o(t))throw new TypeError(t+" is not a symbol");return t}},308:t=>{var r=function(){if("object"==typeof self&&self)return self;if("object"==typeof window&&window)return window;throw new Error("Unable to resolve global `this`")};t.exports=function(){if(this)return this;try{Object.defineProperty(Object.prototype,"__global__",{get:function(){return this},configurable:!0})}catch(t){return r()}try{return __global__||r()}finally{delete Object.prototype.__global__}}()},119:(t,r,e)=>{"use strict";t.exports=e(801)()?globalThis:e(308)},801:t=>{"use strict";t.exports=function(){return"object"==typeof globalThis&&!!globalThis&&globalThis.Array===Array}},656:(t,r,e)=>{"use strict";var o;(o="undefined"!=typeof process&&"[object process]"==={}.toString.call(process)||"undefined"!=typeof navigator&&"ReactNative"===navigator.product?e.g:self).Proxy||(o.Proxy=e(659)(),o.Proxy.revocable=o.Proxy.revocable)},659:t=>{t.exports=function(){let t,r=null;function e(t){return!!t&&("object"==typeof t||"function"==typeof t)}function o(t){if(null!==t&&!e(t))throw new TypeError("Object prototype may only be an Object or null: "+t)}const n=Object,i=Boolean(n.create)||!({__proto__:null}instanceof n),a=n.create||(i?function(t){return o(t),{__proto__:t}}:function(t){if(o(t),null===t)throw new SyntaxError("Native Object.create is required to create objects with null prototype");var r=function(){};return r.prototype=t,new r}),s=function(){return null},c=n.getPrototypeOf||([].__proto__===Array.prototype?function(t){const r=t.__proto__;return e(r)?r:null}:s);return t=function(u,l){if(void 0===(this&&this instanceof t?this.constructor:void 0))throw new TypeError("Constructor Proxy requires 'new'");if(!e(u)||!e(l))throw new TypeError("Cannot create proxy with a non-object as target or handler");let f=function(){};r=function(){u=null,f=function(t){throw new TypeError(`Cannot perform '${t}' on a proxy that has been revoked`)}},setTimeout((function(){r=null}),0);const p=l;l={get:null,set:null,apply:null,construct:null};for(let t in p){if(!(t in l))throw new TypeError(`Proxy polyfill does not support trap '${t}'`);l[t]=p[t]}"function"==typeof p&&(l.apply=p.apply.bind(p));const d=c(u);let m,y=!1,b=!1;"function"==typeof u?(m=function(){const t=this&&this.constructor===m,r=Array.prototype.slice.call(arguments);return f(t?"construct":"apply"),t&&l.construct?l.construct.call(this,u,r):!t&&l.apply?l.apply(u,this,r):t?(r.unshift(u),new(u.bind.apply(u,r))):u.apply(this,r)},y=!0):u instanceof Array?(m=[],b=!0):m=i||null!==d?a(d):{};const _=l.get?function(t){return f("get"),l.get(this,t,m)}:function(t){return f("get"),this[t]},v=l.set?function(t,r){f("set"),l.set(this,t,r,m)}:function(t,r){f("set"),this[t]=r},g=n.getOwnPropertyNames(u),h={};g.forEach((function(t){if((y||b)&&t in m)return;const r=n.getOwnPropertyDescriptor(u,t),e={enumerable:Boolean(r.enumerable),get:_.bind(u,t),set:v.bind(u,t)};n.defineProperty(m,t,e),h[t]=!0}));let S=!0;if(y||b){const t=n.setPrototypeOf||([].__proto__===Array.prototype?function(t,r){return o(r),t.__proto__=r,t}:s);d&&t(m,d)||(S=!1)}if(l.get||!S)for(let t in u)h[t]||n.defineProperty(m,t,{get:_.bind(u,t)});return n.seal(u),n.seal(m),m},t.revocable=function(e,o){return{proxy:new t(e,o),revoke:r}},t}},14:function(t,r,e){"use strict";var o=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(r,"__esModule",{value:!0}),r.CommandBarClientSDK=r.snippet=r.initProxy=r.init=void 0;var n=e(343);Object.defineProperty(r,"CommandBarClientSDK",{enumerable:!0,get:function(){return n.CommandBarClientSDK}});var i=e(956);Object.defineProperty(r,"init",{enumerable:!0,get:function(){return o(i).default}});var a=e(737);Object.defineProperty(r,"initProxy",{enumerable:!0,get:function(){return a.initProxySDK}});var s=e(890);Object.defineProperty(r,"snippet",{enumerable:!0,get:function(){return s.snippet}})},956:function(t,r,e){"use strict";var o=this&&this.__assign||function(){return o=Object.assign||function(t){for(var r,e=1,o=arguments.length;e<o;e++)for(var n in r=arguments[e])Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n]);return t},o.apply(this,arguments)};Object.defineProperty(r,"__esModule",{value:!0}),e(656),e(992),e(769);var n=e(737),i=e(207),a=function(t){if("complete"===document.readyState){var r=function(t){var r="https://api.commandbar.com",e=[],o=localStorage.getItem("commandbar.lc");o&&o.includes("local")&&(r="http://localhost:8000");var n=r+"/latest/"+t;return o&&e.push("lc="+o),e.push("version=2"),n+"?"+e.join("&")}(t),e=document.createElement("script");e.type="text/javascript",e.async=!0,e.src=r,document.head.appendChild(e)}else window.addEventListener("load",a.bind(null,t),{capture:!1,once:!0})},s={debug:!1};r.default=function(t,r){var e;void 0===r&&(r=s);var c=o(o({},s),r);t?(null===(e=(0,n.getProxySDK)()[i._configuration])||void 0===e?void 0:e.uuid)?console.warn("CommandBar init was called more than once. Skipping the redundant initialization..."):(c.debug&&console.log("CommandBar init...",{environment:r.environment,version:r.version}),(0,n.getProxySDK)()[i._configuration]={uuid:t,environment:r.environment,version:r.version,config:r.config},a(t)):console.error("No org specified for CommandBar.init")}},890:(t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.snippet=void 0,r.snippet=function(t){var r=["Object.assign","Symbol","Symbol.for"].join("%2C"),e=window;function o(t,r){void 0===r&&(r=!1),"complete"!==document.readyState&&window.addEventListener("load",o.bind(null,t,r),{capture:!1,once:!0});var e=document.createElement("script");e.type="text/javascript",e.async=r,e.src=t,document.head.appendChild(e)}function n(){var r;if(void 0===e.CommandBar){delete e.__CommandBarBootstrap__;var n=Symbol.for("CommandBar::configuration"),i=Symbol.for("CommandBar::orgConfig"),a=Symbol.for("CommandBar::disposed"),s=Symbol.for("CommandBar::isProxy"),c=Symbol.for("CommandBar::queue"),u=Symbol.for("CommandBar::unwrap"),l=[],f=localStorage.getItem("commandbar.lc"),p=f&&f.includes("local")?"http://localhost:8000":"https://api.commandbar.com",d=Object.assign(((r={})[n]={uuid:t},r[i]={},r[a]=!1,r[s]=!0,r[c]=new Array,r[u]=function(){return d},r),e.CommandBar),m=["addCommand","boot"],y=d;Object.assign(d,{shareCallbacks:function(){return{}},shareContext:function(){return{}}}),e.CommandBar=new Proxy(d,{get:function(t,r){return r in y?d[r]:m.includes(r)?function(){var t=Array.prototype.slice.call(arguments);return new Promise((function(e,o){t.unshift(r,e,o),d[c].push(t)}))}:function(){var t=Array.prototype.slice.call(arguments);t.unshift(r),d[c].push(t)}}}),null!==f&&l.push("lc=".concat(f)),l.push("version=2"),o("".concat(p,"/latest/").concat(t,"?").concat(l.join("&")),!0)}}void 0===Object.assign||"undefined"==typeof Symbol||void 0===Symbol.for?(e.__CommandBarBootstrap__=n,o("https://polyfill.io/v3/polyfill.min.js?version=3.101.0&callback=__CommandBarBootstrap__&features="+r)):n()}},343:(t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.DEFAULT_INSTANCE_ATTRIBUTES=r.ASYNC_METHODS=void 0,r.ASYNC_METHODS=["addCommand","boot"],r.DEFAULT_INSTANCE_ATTRIBUTES={canOpenEditor:!0,formFactor:{type:"modal"}}},737:(t,r,e)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.initProxySDK=r.getProxySDK=void 0;var o=e(314),n=e(343),i=e(207);function a(){var t,r,e,o,a=window.CommandBar,s=window.CommandBar;Array.isArray(null==a?void 0:a.q)||"string"==typeof(null==a?void 0:a.uid)?(e=null==a?void 0:a.uid,o=null==a?void 0:a.q):(e=null===(r=null==s?void 0:s[i._configuration])||void 0===r?void 0:r.uuid,o=null==s?void 0:s[i._queue]);var c=((t={})[i._configuration]={uuid:"string"==typeof e?e:""},t[i._disposed]=!1,t[i._isProxy]=!0,t[i._queue]=Array.isArray(o)?o:[],t[i._unwrap]=function(){return c},t),u=c;Object.assign(c,{shareCallbacks:function(){return{}},shareContext:function(){return{}}}),window.CommandBar=new Proxy(c,{get:function(t,r){return r in u?u[r]:n.ASYNC_METHODS.includes(r)?function(){var t=Array.prototype.slice.call(arguments);return new Promise((function(e,o){t.unshift(r,e,o),c[i._queue].push(t)}))}:function(){var t=Array.prototype.slice.call(arguments);t.unshift(r),c[i._queue].push(t)}}})}r.getProxySDK=function(){var t=window.CommandBar;return((0,o.isDisposed)(t)||"boolean"!=typeof t[i._isProxy])&&a(),window.CommandBar[i._unwrap]()},r.initProxySDK=a},207:(t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r._userAttributes=r._user=r._unwrap=r._state=r._showMessage=r._showGuide=r._shareProgrammaticCommands=r._shareContextSettings=r._setEditorVisible=r._setTestMode=r._setPreviewMode=r._setDashboard=r._search=r._reporter=r._report=r._reloadNudges=r._reloadPlaceholders=r._reloadOrganization=r._reloadCommands=r._queue=r._programmaticTheme=r._perf=r._orgConfig=r._loadEditor=r._isProxy=r._instanceAttributes=r._disposed=r._dispose=r._dispatch=r._configUser=r._configure=r._configuration=r._access=void 0,r._access=Symbol.for("CommandBar::access"),r._configuration=Symbol.for("CommandBar::configuration"),r._configure=Symbol.for("CommandBar::configure"),r._configUser=Symbol.for("CommandBar::configUser"),r._dispatch=Symbol.for("CommandBar::dispatch"),r._dispose=Symbol.for("CommandBar::dispose"),r._disposed=Symbol.for("CommandBar::disposed"),r._instanceAttributes=Symbol.for("CommandBar::instanceAttributes"),r._isProxy=Symbol.for("CommandBar::isProxy"),r._loadEditor=Symbol.for("CommandBar::loadEditor"),r._orgConfig=Symbol.for("CommandBar::orgConfig"),r._perf=Symbol.for("CommandBar::perf"),r._programmaticTheme=Symbol.for("CommandBar::programmaticTheme"),r._queue=Symbol.for("CommandBar::queue"),r._reloadCommands=Symbol.for("CommandBar::reloadCommands"),r._reloadOrganization=Symbol.for("CommandBar::reloadOrganization"),r._reloadPlaceholders=Symbol.for("CommandBar::reloadPlaceholders"),r._reloadNudges=Symbol.for("CommandBar::reloadNudges"),r._report=Symbol.for("CommandBar::report"),r._reporter=Symbol.for("CommandBar::reporter"),r._search=Symbol.for("CommandBar::search"),r._setDashboard=Symbol.for("CommandBar::setDashboard"),r._setPreviewMode=Symbol.for("CommandBar::setPreviewMode"),r._setTestMode=Symbol.for("CommandBar::setTestMode"),r._setEditorVisible=Symbol.for("CommandBar::setEditorVisible"),r._shareContextSettings=Symbol.for("CommandBar::shareContextSettings"),r._shareProgrammaticCommands=Symbol.for("CommandBar::shareProgrammaticCommands"),r._showGuide=Symbol.for("CommandBar::showGuide"),r._showMessage=Symbol.for("CommandBar::showMessage"),r._state=Symbol.for("CommandBar::state"),r._unwrap=Symbol.for("CommandBar::unwrap"),r._user=Symbol.for("CommandBar::user"),r._userAttributes=Symbol.for("CommandBar::userAttributes")},314:(t,r,e)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),r.dispose=r.isDisposed=r.isDisposable=void 0;var o=e(207),n=function(t){return void 0!==t&&void 0!==t.dispose},i=function(t){return void 0!==t&&void 0!==t[o._dispose]};r.isDisposable=function(t){return void 0===t||n(t)||i(t)},r.isDisposed=function(t){return void 0===t||n(t)&&!0===t._disposed||i(t)&&!0===t[o._disposed]},r.dispose=function(t){void 0!==t&&(i(t)?t[o._dispose]():t.dispose())}},111:(t,r,e)=>{"use strict";var o=e(666);t.exports=function(t){if("function"!=typeof t)return!1;if(!hasOwnProperty.call(t,"length"))return!1;try{if("number"!=typeof t.length)return!1;if("function"!=typeof t.call)return!1;if("function"!=typeof t.apply)return!1}catch(t){return!1}return!o(t)}},617:(t,r,e)=>{"use strict";var o=e(102),n={object:!0,function:!0,undefined:!0};t.exports=function(t){return!!o(t)&&hasOwnProperty.call(n,typeof t)}},307:(t,r,e)=>{"use strict";var o=e(111),n=/^\s*class[\s{/}]/,i=Function.prototype.toString;t.exports=function(t){return!!o(t)&&!n.test(i.call(t))}},666:(t,r,e)=>{"use strict";var o=e(617);t.exports=function(t){if(!o(t))return!1;try{return!!t.constructor&&t.constructor.prototype===t}catch(t){return!1}}},102:t=>{"use strict";t.exports=function(t){return null!=t}}},r={};function e(o){var n=r[o];if(void 0!==n)return n.exports;var i=r[o]={exports:{}};return t[o].call(i.exports,i,i.exports,e),i.exports}return e.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),e(14)})()}));
1
+ /*! For license information please see index.js.LICENSE.txt */
2
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.commandbar=t():e.commandbar=t()}(this,(()=>(()=>{var e={857:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>d,getControlKey:()=>p});var o=r(378),n=function(){return["WINDOWS","ANDROID","LINUX"].includes(function(){if("undefined"!=typeof window){var e=window.navigator.userAgent,t=window.navigator.platform,r="MAC";return-1!==["Macintosh","MacIntel","MacPPC","Mac68K"].indexOf(t)?r="MAC":-1!==["iPhone","iPad","iPod"].indexOf(t)?r="IOS":-1!==["Win32","Win64","Windows","WinCE"].indexOf(t)?r="WINDOWS":/Android/.test(e)?r="ANDROID":/Linux/.test(t)&&(r="LINUX"),r}}())?"Ctrl":"⌘"},i={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},a=o.createContext&&o.createContext(i),u=function(){return u=Object.assign||function(e){for(var t,r=1,o=arguments.length;r<o;r++)for(var n in t=arguments[r])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},u.apply(this,arguments)};function s(e){return e&&e.map((function(e,t){return o.createElement(e.tag,u({key:t},e.attr),s(e.child))}))}function c(e){return function(t){return o.createElement(l,u({attr:u({},e.attr)},t),s(e.child))}}function l(e){var t=function(t){var r,n=e.size||t.size||"1em";t.className&&(r=t.className),e.className&&(r=(r?r+" ":"")+e.className);var i=e.attr,a=e.title,s=function(e,t){var r={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.indexOf(o)<0&&(r[o]=e[o]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(o=Object.getOwnPropertySymbols(e);n<o.length;n++)t.indexOf(o[n])<0&&(r[o[n]]=e[o[n]])}return r}(e,["attr","title"]);return o.createElement("svg",u({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},t.attr,i,s,{className:r,style:u({color:e.color||t.color},t.style,e.style),height:n,width:n,xmlns:"http://www.w3.org/2000/svg"}),a&&o.createElement("title",null,a),e.children)};return void 0!==a?o.createElement(a.Consumer,null,(function(e){return t(e)})):t(i)}function f(e){return c({tag:"svg",attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0 0 11.6 0l43.6-43.5a8.2 8.2 0 0 0 0-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z"}}]})(e)}var p=n;const d=function(e){var t=e.text,r=e.style;return o.createElement("div",{id:"commandbar-user-launcher-component",className:"commandbar-user-launcher",style:r||{},onClick:function(){var e,t;null===(e=window)||void 0===e||null===(t=e.CommandBar)||void 0===t||t.open()}},o.createElement("div",{className:"commandbar-user-launcher__content"},o.createElement("div",{className:"commandbar-user-launcher__prefix"},o.createElement(f,null),"  ",t||"Find anything"),!/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)&&o.createElement("div",{className:"commandbar-user-launcher__suffix"},o.createElement("span",{style:{marginRight:3},className:"commandbar-user-launcher__tag"},n()),o.createElement("span",{style:{marginRight:3}},"+"),o.createElement("span",{className:"commandbar-user-launcher__tag "},"K"))))}},296:(e,t,r)=>{"use strict";var o=r(102),n=r(307),i=r(339),a=r(957),u=r(246);(e.exports=function(e,t){var r,n,s,c,l;return arguments.length<2||"string"!=typeof e?(c=t,t=e,e=null):c=arguments[2],o(e)?(r=u.call(e,"c"),n=u.call(e,"e"),s=u.call(e,"w")):(r=s=!0,n=!1),l={value:t,configurable:r,enumerable:n,writable:s},c?i(a(c),l):l}).gs=function(e,t,r){var s,c,l,f;return"string"!=typeof e?(l=r,r=t,t=e,e=null):l=arguments[3],o(t)?n(t)?o(r)?n(r)||(l=r,r=void 0):r=void 0:(l=t,t=r=void 0):t=void 0,o(e)?(s=u.call(e,"c"),c=u.call(e,"e")):(s=!0,c=!1),f={get:t,set:r,configurable:s,enumerable:c},l?i(a(l),f):f}},817:e=>{"use strict";e.exports=function(){}},339:(e,t,r)=>{"use strict";e.exports=r(994)()?Object.assign:r(963)},994:e=>{"use strict";e.exports=function(){var e,t=Object.assign;return"function"==typeof t&&(t(e={foo:"raz"},{bar:"dwa"},{trzy:"trzy"}),e.foo+e.bar+e.trzy==="razdwatrzy")}},963:(e,t,r)=>{"use strict";var o=r(450),n=r(836),i=Math.max;e.exports=function(e,t){var r,a,u,s=i(arguments.length,2);for(e=Object(n(e)),u=function(o){try{e[o]=t[o]}catch(e){r||(r=e)}},a=1;a<s;++a)o(t=arguments[a]).forEach(u);if(void 0!==r)throw r;return e}},349:(e,t,r)=>{"use strict";var o=r(817)();e.exports=function(e){return e!==o&&null!==e}},450:(e,t,r)=>{"use strict";e.exports=r(446)()?Object.keys:r(177)},446:e=>{"use strict";e.exports=function(){try{return Object.keys("primitive"),!0}catch(e){return!1}}},177:(e,t,r)=>{"use strict";var o=r(349),n=Object.keys;e.exports=function(e){return n(o(e)?Object(e):e)}},957:(e,t,r)=>{"use strict";var o=r(349),n=Array.prototype.forEach,i=Object.create,a=function(e,t){var r;for(r in e)t[r]=e[r]};e.exports=function(e){var t=i(null);return n.call(arguments,(function(e){o(e)&&a(Object(e),t)})),t}},836:(e,t,r)=>{"use strict";var o=r(349);e.exports=function(e){if(!o(e))throw new TypeError("Cannot use null or undefined");return e}},246:(e,t,r)=>{"use strict";e.exports=r(711)()?String.prototype.contains:r(370)},711:e=>{"use strict";var t="razdwatrzy";e.exports=function(){return"function"==typeof t.contains&&!0===t.contains("dwa")&&!1===t.contains("foo")}},370:e=>{"use strict";var t=String.prototype.indexOf;e.exports=function(e){return t.call(this,e,arguments[1])>-1}},992:(e,t,r)=>{"use strict";r(98).polyfill()},98:e=>{"use strict";function t(e,t){if(null==e)throw new TypeError("Cannot convert first argument to object");for(var r=Object(e),o=1;o<arguments.length;o++){var n=arguments[o];if(null!=n)for(var i=Object.keys(Object(n)),a=0,u=i.length;a<u;a++){var s=i[a],c=Object.getOwnPropertyDescriptor(n,s);void 0!==c&&c.enumerable&&(r[s]=n[s])}}return r}e.exports={assign:t,polyfill:function(){Object.assign||Object.defineProperty(Object,"assign",{enumerable:!1,configurable:!0,writable:!0,value:t})}}},769:(e,t,r)=>{"use strict";r(614)()||Object.defineProperty(r(119),"Symbol",{value:r(798),configurable:!0,enumerable:!1,writable:!0})},614:(e,t,r)=>{"use strict";var o=r(119),n={object:!0,symbol:!0};e.exports=function(){var e,t=o.Symbol;if("function"!=typeof t)return!1;e=t("test symbol");try{String(e)}catch(e){return!1}return!!n[typeof t.iterator]&&!!n[typeof t.toPrimitive]&&!!n[typeof t.toStringTag]}},64:e=>{"use strict";e.exports=function(e){return!!e&&("symbol"==typeof e||!!e.constructor&&"Symbol"===e.constructor.name&&"Symbol"===e[e.constructor.toStringTag])}},573:(e,t,r)=>{"use strict";var o=r(296),n=Object.create,i=Object.defineProperty,a=Object.prototype,u=n(null);e.exports=function(e){for(var t,r,n=0;u[e+(n||"")];)++n;return u[e+=n||""]=!0,i(a,t="@@"+e,o.gs(null,(function(e){r||(r=!0,i(this,t,o(e)),r=!1)}))),t}},572:(e,t,r)=>{"use strict";var o=r(296),n=r(119).Symbol;e.exports=function(e){return Object.defineProperties(e,{hasInstance:o("",n&&n.hasInstance||e("hasInstance")),isConcatSpreadable:o("",n&&n.isConcatSpreadable||e("isConcatSpreadable")),iterator:o("",n&&n.iterator||e("iterator")),match:o("",n&&n.match||e("match")),replace:o("",n&&n.replace||e("replace")),search:o("",n&&n.search||e("search")),species:o("",n&&n.species||e("species")),split:o("",n&&n.split||e("split")),toPrimitive:o("",n&&n.toPrimitive||e("toPrimitive")),toStringTag:o("",n&&n.toStringTag||e("toStringTag")),unscopables:o("",n&&n.unscopables||e("unscopables"))})}},781:(e,t,r)=>{"use strict";var o=r(296),n=r(11),i=Object.create(null);e.exports=function(e){return Object.defineProperties(e,{for:o((function(t){return i[t]?i[t]:i[t]=e(String(t))})),keyFor:o((function(e){var t;for(t in n(e),i)if(i[t]===e)return t}))})}},798:(e,t,r)=>{"use strict";var o,n,i,a=r(296),u=r(11),s=r(119).Symbol,c=r(573),l=r(572),f=r(781),p=Object.create,d=Object.defineProperties,m=Object.defineProperty;if("function"==typeof s)try{String(s()),i=!0}catch(e){}else s=null;n=function(e){if(this instanceof n)throw new TypeError("Symbol is not a constructor");return o(e)},e.exports=o=function e(t){var r;if(this instanceof e)throw new TypeError("Symbol is not a constructor");return i?s(t):(r=p(n.prototype),t=void 0===t?"":String(t),d(r,{__description__:a("",t),__name__:a("",c(t))}))},l(o),f(o),d(n.prototype,{constructor:a(o),toString:a("",(function(){return this.__name__}))}),d(o.prototype,{toString:a((function(){return"Symbol ("+u(this).__description__+")"})),valueOf:a((function(){return u(this)}))}),m(o.prototype,o.toPrimitive,a("",(function(){var e=u(this);return"symbol"==typeof e?e:e.toString()}))),m(o.prototype,o.toStringTag,a("c","Symbol")),m(n.prototype,o.toStringTag,a("c",o.prototype[o.toStringTag])),m(n.prototype,o.toPrimitive,a("c",o.prototype[o.toPrimitive]))},11:(e,t,r)=>{"use strict";var o=r(64);e.exports=function(e){if(!o(e))throw new TypeError(e+" is not a symbol");return e}},308:e=>{var t=function(){if("object"==typeof self&&self)return self;if("object"==typeof window&&window)return window;throw new Error("Unable to resolve global `this`")};e.exports=function(){if(this)return this;try{Object.defineProperty(Object.prototype,"__global__",{get:function(){return this},configurable:!0})}catch(e){return t()}try{return __global__||t()}finally{delete Object.prototype.__global__}}()},119:(e,t,r)=>{"use strict";e.exports=r(801)()?globalThis:r(308)},801:e=>{"use strict";e.exports=function(){return"object"==typeof globalThis&&!!globalThis&&globalThis.Array===Array}},525:e=>{"use strict";var t=Object.getOwnPropertySymbols,r=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function n(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach((function(e){o[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},o)).join("")}catch(e){return!1}}()?Object.assign:function(e,i){for(var a,u,s=n(e),c=1;c<arguments.length;c++){for(var l in a=Object(arguments[c]))r.call(a,l)&&(s[l]=a[l]);if(t){u=t(a);for(var f=0;f<u.length;f++)o.call(a,u[f])&&(s[u[f]]=a[u[f]])}}return s}},656:(e,t,r)=>{"use strict";var o;(o="undefined"!=typeof process&&"[object process]"==={}.toString.call(process)||"undefined"!=typeof navigator&&"ReactNative"===navigator.product?r.g:self).Proxy||(o.Proxy=r(659)(),o.Proxy.revocable=o.Proxy.revocable)},659:e=>{e.exports=function(){let e,t=null;function r(e){return!!e&&("object"==typeof e||"function"==typeof e)}function o(e){if(null!==e&&!r(e))throw new TypeError("Object prototype may only be an Object or null: "+e)}const n=Object,i=Boolean(n.create)||!({__proto__:null}instanceof n),a=n.create||(i?function(e){return o(e),{__proto__:e}}:function(e){if(o(e),null===e)throw new SyntaxError("Native Object.create is required to create objects with null prototype");var t=function(){};return t.prototype=e,new t}),u=function(){return null},s=n.getPrototypeOf||([].__proto__===Array.prototype?function(e){const t=e.__proto__;return r(t)?t:null}:u);return e=function(c,l){if(void 0===(this&&this instanceof e?this.constructor:void 0))throw new TypeError("Constructor Proxy requires 'new'");if(!r(c)||!r(l))throw new TypeError("Cannot create proxy with a non-object as target or handler");let f=function(){};t=function(){c=null,f=function(e){throw new TypeError(`Cannot perform '${e}' on a proxy that has been revoked`)}},setTimeout((function(){t=null}),0);const p=l;l={get:null,set:null,apply:null,construct:null};for(let e in p){if(!(e in l))throw new TypeError(`Proxy polyfill does not support trap '${e}'`);l[e]=p[e]}"function"==typeof p&&(l.apply=p.apply.bind(p));const d=s(c);let m,y=!1,b=!1;"function"==typeof c?(m=function(){const e=this&&this.constructor===m,t=Array.prototype.slice.call(arguments);return f(e?"construct":"apply"),e&&l.construct?l.construct.call(this,c,t):!e&&l.apply?l.apply(c,this,t):e?(t.unshift(c),new(c.bind.apply(c,t))):c.apply(this,t)},y=!0):c instanceof Array?(m=[],b=!0):m=i||null!==d?a(d):{};const v=l.get?function(e){return f("get"),l.get(this,e,m)}:function(e){return f("get"),this[e]},_=l.set?function(e,t){f("set"),l.set(this,e,t,m)}:function(e,t){f("set"),this[e]=t},h=n.getOwnPropertyNames(c),g={};h.forEach((function(e){if((y||b)&&e in m)return;const t=n.getOwnPropertyDescriptor(c,e),r={enumerable:Boolean(t.enumerable),get:v.bind(c,e),set:_.bind(c,e)};n.defineProperty(m,e,r),g[e]=!0}));let S=!0;if(y||b){const e=n.setPrototypeOf||([].__proto__===Array.prototype?function(e,t){return o(t),e.__proto__=t,e}:u);d&&e(m,d)||(S=!1)}if(l.get||!S)for(let e in c)g[e]||n.defineProperty(m,e,{get:v.bind(c,e)});return n.seal(c),n.seal(m),m},e.revocable=function(r,o){return{proxy:new e(r,o),revoke:t}},e}},535:(e,t,r)=>{"use strict";var o=r(525),n=60103,i=60106;t.Fragment=60107,t.StrictMode=60108,t.Profiler=60114;var a=60109,u=60110,s=60112;t.Suspense=60113;var c=60115,l=60116;if("function"==typeof Symbol&&Symbol.for){var f=Symbol.for;n=f("react.element"),i=f("react.portal"),t.Fragment=f("react.fragment"),t.StrictMode=f("react.strict_mode"),t.Profiler=f("react.profiler"),a=f("react.provider"),u=f("react.context"),s=f("react.forward_ref"),t.Suspense=f("react.suspense"),c=f("react.memo"),l=f("react.lazy")}var p="function"==typeof Symbol&&Symbol.iterator;function d(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var m={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},y={};function b(e,t,r){this.props=e,this.context=t,this.refs=y,this.updater=r||m}function v(){}function _(e,t,r){this.props=e,this.context=t,this.refs=y,this.updater=r||m}b.prototype.isReactComponent={},b.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error(d(85));this.updater.enqueueSetState(this,e,t,"setState")},b.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},v.prototype=b.prototype;var h=_.prototype=new v;h.constructor=_,o(h,b.prototype),h.isPureReactComponent=!0;var g={current:null},S=Object.prototype.hasOwnProperty,w={key:!0,ref:!0,__self:!0,__source:!0};function C(e,t,r){var o,i={},a=null,u=null;if(null!=t)for(o in void 0!==t.ref&&(u=t.ref),void 0!==t.key&&(a=""+t.key),t)S.call(t,o)&&!w.hasOwnProperty(o)&&(i[o]=t[o]);var s=arguments.length-2;if(1===s)i.children=r;else if(1<s){for(var c=Array(s),l=0;l<s;l++)c[l]=arguments[l+2];i.children=c}if(e&&e.defaultProps)for(o in s=e.defaultProps)void 0===i[o]&&(i[o]=s[o]);return{$$typeof:n,type:e,key:a,ref:u,props:i,_owner:g.current}}function O(e){return"object"==typeof e&&null!==e&&e.$$typeof===n}var j=/\/+/g;function P(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function x(e,t,r,o,a){var u=typeof e;"undefined"!==u&&"boolean"!==u||(e=null);var s=!1;if(null===e)s=!0;else switch(u){case"string":case"number":s=!0;break;case"object":switch(e.$$typeof){case n:case i:s=!0}}if(s)return a=a(s=e),e=""===o?"."+P(s,0):o,Array.isArray(a)?(r="",null!=e&&(r=e.replace(j,"$&/")+"/"),x(a,t,r,"",(function(e){return e}))):null!=a&&(O(a)&&(a=function(e,t){return{$$typeof:n,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}(a,r+(!a.key||s&&s.key===a.key?"":(""+a.key).replace(j,"$&/")+"/")+e)),t.push(a)),1;if(s=0,o=""===o?".":o+":",Array.isArray(e))for(var c=0;c<e.length;c++){var l=o+P(u=e[c],c);s+=x(u,t,r,l,a)}else if(l=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=p&&e[p]||e["@@iterator"])?e:null}(e),"function"==typeof l)for(e=l.call(e),c=0;!(u=e.next()).done;)s+=x(u=u.value,t,r,l=o+P(u,c++),a);else if("object"===u)throw t=""+e,Error(d(31,"[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t));return s}function E(e,t,r){if(null==e)return e;var o=[],n=0;return x(e,o,"","",(function(e){return t.call(r,e,n++)})),o}function B(e){if(-1===e._status){var t=e._result;t=t(),e._status=0,e._result=t,t.then((function(t){0===e._status&&(t=t.default,e._status=1,e._result=t)}),(function(t){0===e._status&&(e._status=2,e._result=t)}))}if(1===e._status)return e._result;throw e._result}var T={current:null};function A(){var e=T.current;if(null===e)throw Error(d(321));return e}var M={ReactCurrentDispatcher:T,ReactCurrentBatchConfig:{transition:0},ReactCurrentOwner:g,IsSomeRendererActing:{current:!1},assign:o};t.Children={map:E,forEach:function(e,t,r){E(e,(function(){t.apply(this,arguments)}),r)},count:function(e){var t=0;return E(e,(function(){t++})),t},toArray:function(e){return E(e,(function(e){return e}))||[]},only:function(e){if(!O(e))throw Error(d(143));return e}},t.Component=b,t.PureComponent=_,t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=M,t.cloneElement=function(e,t,r){if(null==e)throw Error(d(267,e));var i=o({},e.props),a=e.key,u=e.ref,s=e._owner;if(null!=t){if(void 0!==t.ref&&(u=t.ref,s=g.current),void 0!==t.key&&(a=""+t.key),e.type&&e.type.defaultProps)var c=e.type.defaultProps;for(l in t)S.call(t,l)&&!w.hasOwnProperty(l)&&(i[l]=void 0===t[l]&&void 0!==c?c[l]:t[l])}var l=arguments.length-2;if(1===l)i.children=r;else if(1<l){c=Array(l);for(var f=0;f<l;f++)c[f]=arguments[f+2];i.children=c}return{$$typeof:n,type:e.type,key:a,ref:u,props:i,_owner:s}},t.createContext=function(e,t){return void 0===t&&(t=null),(e={$$typeof:u,_calculateChangedBits:t,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null}).Provider={$$typeof:a,_context:e},e.Consumer=e},t.createElement=C,t.createFactory=function(e){var t=C.bind(null,e);return t.type=e,t},t.createRef=function(){return{current:null}},t.forwardRef=function(e){return{$$typeof:s,render:e}},t.isValidElement=O,t.lazy=function(e){return{$$typeof:l,_payload:{_status:-1,_result:e},_init:B}},t.memo=function(e,t){return{$$typeof:c,type:e,compare:void 0===t?null:t}},t.useCallback=function(e,t){return A().useCallback(e,t)},t.useContext=function(e,t){return A().useContext(e,t)},t.useDebugValue=function(){},t.useEffect=function(e,t){return A().useEffect(e,t)},t.useImperativeHandle=function(e,t,r){return A().useImperativeHandle(e,t,r)},t.useLayoutEffect=function(e,t){return A().useLayoutEffect(e,t)},t.useMemo=function(e,t){return A().useMemo(e,t)},t.useReducer=function(e,t,r){return A().useReducer(e,t,r)},t.useRef=function(e){return A().useRef(e)},t.useState=function(e){return A().useState(e)},t.version="17.0.2"},378:(e,t,r)=>{"use strict";e.exports=r(535)},14:function(e,t,r){"use strict";var o=this&&this.__createBinding||(Object.create?function(e,t,r,o){void 0===o&&(o=r);var n=Object.getOwnPropertyDescriptor(t,r);n&&!("get"in n?!t.__esModule:n.writable||n.configurable)||(n={enumerable:!0,get:function(){return t[r]}}),Object.defineProperty(e,o,n)}:function(e,t,r,o){void 0===o&&(o=r),e[o]=t[r]}),n=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.prototype.hasOwnProperty.call(e,r)&&o(t,e,r);return n(t,e),t},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.getControlKey=t.Launcher=t.CommandBarClientSDK=t.snippet=t.initProxy=t.init=void 0;var u=i(r(857));t.Launcher=u.default,Object.defineProperty(t,"getControlKey",{enumerable:!0,get:function(){return u.getControlKey}});var s=r(343);Object.defineProperty(t,"CommandBarClientSDK",{enumerable:!0,get:function(){return s.CommandBarClientSDK}});var c=r(956);Object.defineProperty(t,"init",{enumerable:!0,get:function(){return a(c).default}});var l=r(737);Object.defineProperty(t,"initProxy",{enumerable:!0,get:function(){return l.initProxySDK}});var f=r(890);Object.defineProperty(t,"snippet",{enumerable:!0,get:function(){return f.snippet}})},956:function(e,t,r){"use strict";var o=this&&this.__assign||function(){return o=Object.assign||function(e){for(var t,r=1,o=arguments.length;r<o;r++)for(var n in t=arguments[r])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},o.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),r(656),r(992),r(769);var n=r(737),i=r(207),a=function(e){if("complete"===document.readyState){var t=function(e){var t="https://api.commandbar.com",r=[],o=localStorage.getItem("commandbar.lc");o&&o.includes("local")&&(t="http://localhost:8000");var n=t+"/latest/"+e;return o&&r.push("lc="+o),r.push("version=2"),n+"?"+r.join("&")}(e),r=document.createElement("script");r.type="text/javascript",r.async=!0,r.src=t,document.head.appendChild(r)}else window.addEventListener("load",a.bind(null,e),{capture:!1,once:!0})},u={debug:!1};t.default=function(e,t){var r;void 0===t&&(t=u);var s=o(o({},u),t);e?(null===(r=(0,n.getProxySDK)()[i._configuration])||void 0===r?void 0:r.uuid)?console.warn("CommandBar init was called more than once. Skipping the redundant initialization..."):(s.debug&&console.log("CommandBar init...",{environment:t.environment,version:t.version}),(0,n.getProxySDK)()[i._configuration]={uuid:e,environment:t.environment,version:t.version,config:t.config},a(e)):console.error("No org specified for CommandBar.init")}},890:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.snippet=void 0;var o=r(207);t.snippet=function(e){var t=["Object.assign","Symbol","Symbol.for"].join("%2C"),r=window;function n(e,t){void 0===t&&(t=!1),"complete"!==document.readyState&&window.addEventListener("load",n.bind(null,e,t),{capture:!1,once:!0});var r=document.createElement("script");r.type="text/javascript",r.async=t,r.src=e,document.head.appendChild(r)}function i(){var t;if(void 0===r.CommandBar){delete r.__CommandBarBootstrap__;var i=Symbol.for("CommandBar::configuration"),a=Symbol.for("CommandBar::orgConfig"),u=Symbol.for("CommandBar::disposed"),s=Symbol.for("CommandBar::isProxy"),c=Symbol.for("CommandBar::queue"),l=Symbol.for("CommandBar::unwrap"),f=[],p=localStorage.getItem("commandbar.lc"),d=p&&p.includes("local")?"http://localhost:8000":"https://api.commandbar.com",m=Object.assign(((t={})[i]={uuid:e},t[a]={},t[u]=!1,t[s]=!0,t[c]=new Array,t[l]=function(){return m},t[o._eventSubscriptions]=void 0,t),r.CommandBar),y=["addCommand","boot","addEventSubscriber"],b=m;Object.assign(m,{shareCallbacks:function(){return{}},shareContext:function(){return{}}}),r.CommandBar=new Proxy(m,{get:function(e,t){return t in b?m[t]:y.includes(t)?function(){var e=Array.prototype.slice.call(arguments);return new Promise((function(r,o){e.unshift(t,r,o),m[c].push(e)}))}:function(){var e=Array.prototype.slice.call(arguments);e.unshift(t),m[c].push(e)}}}),null!==p&&f.push("lc=".concat(p)),f.push("version=2"),n("".concat(d,"/latest/").concat(e,"?").concat(f.join("&")),!0)}}void 0===Object.assign||"undefined"==typeof Symbol||void 0===Symbol.for?(r.__CommandBarBootstrap__=i,n("https://polyfill.io/v3/polyfill.min.js?version=3.101.0&callback=__CommandBarBootstrap__&features="+t)):i()}},343:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_INSTANCE_ATTRIBUTES=t.ASYNC_METHODS=void 0,t.ASYNC_METHODS=["addCommand","boot","addEventSubscriber"],t.DEFAULT_INSTANCE_ATTRIBUTES={canOpenEditor:!0,formFactor:{type:"modal"}}},737:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.initProxySDK=t.getProxySDK=void 0;var o=r(314),n=r(343),i=r(207);function a(){var e,t,r,o,a=window.CommandBar,u=window.CommandBar;Array.isArray(null==a?void 0:a.q)||"string"==typeof(null==a?void 0:a.uid)?(r=null==a?void 0:a.uid,o=null==a?void 0:a.q):(r=null===(t=null==u?void 0:u[i._configuration])||void 0===t?void 0:t.uuid,o=null==u?void 0:u[i._queue]);var s=((e={})[i._configuration]={uuid:"string"==typeof r?r:""},e[i._disposed]=!1,e[i._isProxy]=!0,e[i._queue]=Array.isArray(o)?o:[],e[i._unwrap]=function(){return s},e[i._eventSubscriptions]=void 0,e),c=s;Object.assign(s,{shareCallbacks:function(){return{}},shareContext:function(){return{}}}),window.CommandBar=new Proxy(s,{get:function(e,t){return t in c?c[t]:n.ASYNC_METHODS.includes(t)?function(){var e=Array.prototype.slice.call(arguments);return new Promise((function(r,o){e.unshift(t,r,o),s[i._queue].push(e)}))}:function(){var e=Array.prototype.slice.call(arguments);e.unshift(t),s[i._queue].push(e)}}})}t.getProxySDK=function(){var e=window.CommandBar;return((0,o.isDisposed)(e)||"boolean"!=typeof e[i._isProxy])&&a(),window.CommandBar[i._unwrap]()},t.initProxySDK=a},207:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t._eventSubscriptions=t._userAttributes=t._user=t._unwrap=t._state=t._showMessage=t._showGuide=t._shareProgrammaticCommands=t._shareContextSettings=t._setEditorVisible=t._setTestMode=t._setPreviewMode=t._setDashboard=t._search=t._reporter=t._report=t._reloadNudges=t._reloadPlaceholders=t._reloadOrganization=t._reloadCommands=t._queue=t._programmaticTheme=t._perf=t._orgConfig=t._loadEditor=t._isProxy=t._instanceAttributes=t._disposed=t._dispose=t._dispatch=t._configUser=t._configure=t._configuration=t._access=void 0,t._access=Symbol.for("CommandBar::access"),t._configuration=Symbol.for("CommandBar::configuration"),t._configure=Symbol.for("CommandBar::configure"),t._configUser=Symbol.for("CommandBar::configUser"),t._dispatch=Symbol.for("CommandBar::dispatch"),t._dispose=Symbol.for("CommandBar::dispose"),t._disposed=Symbol.for("CommandBar::disposed"),t._instanceAttributes=Symbol.for("CommandBar::instanceAttributes"),t._isProxy=Symbol.for("CommandBar::isProxy"),t._loadEditor=Symbol.for("CommandBar::loadEditor"),t._orgConfig=Symbol.for("CommandBar::orgConfig"),t._perf=Symbol.for("CommandBar::perf"),t._programmaticTheme=Symbol.for("CommandBar::programmaticTheme"),t._queue=Symbol.for("CommandBar::queue"),t._reloadCommands=Symbol.for("CommandBar::reloadCommands"),t._reloadOrganization=Symbol.for("CommandBar::reloadOrganization"),t._reloadPlaceholders=Symbol.for("CommandBar::reloadPlaceholders"),t._reloadNudges=Symbol.for("CommandBar::reloadNudges"),t._report=Symbol.for("CommandBar::report"),t._reporter=Symbol.for("CommandBar::reporter"),t._search=Symbol.for("CommandBar::search"),t._setDashboard=Symbol.for("CommandBar::setDashboard"),t._setPreviewMode=Symbol.for("CommandBar::setPreviewMode"),t._setTestMode=Symbol.for("CommandBar::setTestMode"),t._setEditorVisible=Symbol.for("CommandBar::setEditorVisible"),t._shareContextSettings=Symbol.for("CommandBar::shareContextSettings"),t._shareProgrammaticCommands=Symbol.for("CommandBar::shareProgrammaticCommands"),t._showGuide=Symbol.for("CommandBar::showGuide"),t._showMessage=Symbol.for("CommandBar::showMessage"),t._state=Symbol.for("CommandBar::state"),t._unwrap=Symbol.for("CommandBar::unwrap"),t._user=Symbol.for("CommandBar::user"),t._userAttributes=Symbol.for("CommandBar::userAttributes"),t._eventSubscriptions=Symbol.for("CommandBar::eventSubscriptions")},314:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.dispose=t.isDisposed=t.isDisposable=void 0;var o=r(207),n=function(e){return void 0!==e&&void 0!==e.dispose},i=function(e){return void 0!==e&&void 0!==e[o._dispose]};t.isDisposable=function(e){return void 0===e||n(e)||i(e)},t.isDisposed=function(e){return void 0===e||n(e)&&!0===e._disposed||i(e)&&!0===e[o._disposed]},t.dispose=function(e){void 0!==e&&(i(e)?e[o._dispose]():e.dispose())}},111:(e,t,r)=>{"use strict";var o=r(666);e.exports=function(e){if("function"!=typeof e)return!1;if(!hasOwnProperty.call(e,"length"))return!1;try{if("number"!=typeof e.length)return!1;if("function"!=typeof e.call)return!1;if("function"!=typeof e.apply)return!1}catch(e){return!1}return!o(e)}},617:(e,t,r)=>{"use strict";var o=r(102),n={object:!0,function:!0,undefined:!0};e.exports=function(e){return!!o(e)&&hasOwnProperty.call(n,typeof e)}},307:(e,t,r)=>{"use strict";var o=r(111),n=/^\s*class[\s{/}]/,i=Function.prototype.toString;e.exports=function(e){return!!o(e)&&!n.test(i.call(e))}},666:(e,t,r)=>{"use strict";var o=r(617);e.exports=function(e){if(!o(e))return!1;try{return!!e.constructor&&e.constructor.prototype===e}catch(e){return!1}}},102:e=>{"use strict";e.exports=function(e){return null!=e}}},t={};function r(o){var n=t[o];if(void 0!==n)return n.exports;var i=t[o]={exports:{}};return e[o].call(i.exports,i,i.exports,r),i.exports}return r.d=(e,t)=>{for(var o in t)r.o(t,o)&&!r.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r(14)})()));
@@ -0,0 +1,14 @@
1
+ /*
2
+ object-assign
3
+ (c) Sindre Sorhus
4
+ @license MIT
5
+ */
6
+
7
+ /** @license React v17.0.2
8
+ * react.production.min.js
9
+ *
10
+ * Copyright (c) Facebook, Inc. and its affiliates.
11
+ *
12
+ * This source code is licensed under the MIT license found in the
13
+ * LICENSE file in the root directory of this source tree.
14
+ */
@@ -1,9 +1,11 @@
1
+ import { DetailPreviewType } from '../middleware/detailPreview';
1
2
  export declare type DataRow = {
2
3
  icon?: string;
3
4
  category?: string;
4
5
  label?: string;
5
6
  description?: string;
6
7
  __actionIcon?: string;
8
+ __image?: string;
7
9
  __heading?: string;
8
10
  /** @deprecated Use \_\_heading */
9
11
  __breadcrumbs?: string;
@@ -49,6 +51,7 @@ export interface AddContextOptions {
49
51
  * specify a custom icon for every object by setting an `.icon` field.
50
52
  */
51
53
  defaultIcon?: string;
54
+ detail?: DetailPreviewType;
52
55
  /** The value key of `key` objects you want to use to display the object's description (subtext under label). */
53
56
  descriptionKey?: string;
54
57
  /** The value key of `key` objects you want to use to display the object's label. */
@@ -91,6 +94,7 @@ export interface ArgumentOptions {
91
94
  * specify a custom icon for every object by setting an `.icon` field.
92
95
  */
93
96
  defaultIcon?: string;
97
+ detail?: DetailPreviewType;
94
98
  /**
95
99
  * A list of object fields to be searched. If a custom `searchFunction` is provided, matches will be highlighted in
96
100
  * these fields. Field names will be transformed from _camelCase_ or _snake_case_ into _Sentence case_.
@@ -1,10 +1,11 @@
1
1
  import { AddContextOptions, ArgumentOptions, DataRow, RecordOptions } from './AddContextOptions';
2
- import { EventHandler } from './EventHandler';
2
+ import { EventHandler, EventSubscriber } from './EventHandler';
3
3
  import { ICommandFromClientType } from '../middleware/ICommandFromClientType';
4
4
  import { IResourceSettings } from '../middleware/IResourceSettings';
5
- import { ICommandCategoryType, DetailPreviewType, DataRowMedata, ISkinType } from '../middleware/types';
5
+ import { ICommandCategoryType, DetailPreviewType, ISkinType } from '../middleware/types';
6
+ import { DataRowMetadata } from '../middleware/detailPreview';
6
7
  export type { DataRow } from './AddContextOptions';
7
- export type { DataRowMedata } from '../middleware/types';
8
+ export type { DataRowMetadata } from '../middleware/types';
8
9
  export declare const ASYNC_METHODS: Array<keyof CommandBarClientSDK>;
9
10
  export declare type BootOptions = string | (UserAttributes & {
10
11
  id: string;
@@ -47,6 +48,19 @@ export declare type RecordsOrArgumentListLoader = (chosenValues?: undefined | Re
47
48
  export declare type CallbackMap = {
48
49
  [name: string]: CallbackFunction<any, any>;
49
50
  };
51
+ export declare type CustomComponent = {
52
+ mount: (node: HTMLElement) => CustomComponentInstance;
53
+ };
54
+ export declare type CustomComponentInstance = {
55
+ render: (data: DataRow, metadata: DataRowMetadata) => void;
56
+ unmount: () => void;
57
+ };
58
+ export declare type NudgeHandler = ({ slug, content, onClick, timeout, }: {
59
+ slug: string;
60
+ content: string;
61
+ onClick: () => void;
62
+ timeout: number | null;
63
+ }) => void;
50
64
  export declare type CommandBarClientSDK = Readonly<{
51
65
  /**
52
66
  * Adds a callback function to CommandBar. The callback function provided is mapped to `callbackKey`, and can be
@@ -112,11 +126,13 @@ export declare type CommandBarClientSDK = Readonly<{
112
126
  addContext(key: string, initialValue: unknown, options?: AddContextOptions): void;
113
127
  /** @deprecated Use setContext instead. */
114
128
  addContext(ctx: Metadata): void;
129
+ /** @deprecated Use addEventSubscriber instead. */
130
+ addEventHandler(eventHandler: EventHandler): Promise<void>;
115
131
  /**
116
132
  * Captures CommandBar events to be handled in your code / stored in your database. Ask the CommandBar team if you're
117
133
  * interested in this feature.
118
134
  *
119
- * @param eventHandler A function for handling events generated by CommandBar. It should have the following signature:
135
+ * @param eventSubscriber A function for handling events generated by CommandBar. It should have the following signature:
120
136
  * * `eventName`: The name of the event type. Here are the different event types:
121
137
  * * `opened`: Bar open
122
138
  * * `closed`: Bar close. When the bar is closed with input text, it triggers both a `closed` event and a
@@ -129,8 +145,9 @@ export declare type CommandBarClientSDK = Readonly<{
129
145
  * * `shortcut_edited`: When a user assigns or edits a command's shortcut
130
146
  * * `eventData`: Event attributes (will differ based on the type of event). In addition to the data below, any
131
147
  * [eventData you pass to .boot()](https://app.commandbar.com/sdk#boot-eventdata) will be added to each event.
148
+ * @returns A function to remove the event handler
132
149
  */
133
- addEventHandler(eventHandler: EventHandler): Promise<void>;
150
+ addEventSubscriber(eventSubscriber: EventSubscriber): Promise<() => void>;
134
151
  /**
135
152
  * Captures Nudges to be handled by your code. Nudges are a way to send a messages to the user.
136
153
  * They are defined in the editor with a trigger and conditions. When the trigger occurs, and the conditions are met,
@@ -144,12 +161,7 @@ export declare type CommandBarClientSDK = Readonly<{
144
161
  * * `onClick`: The default on click behavior for the nudge. E.g., if a nudge is defined in the editor
145
162
  * to execute a command on click, then calling `onClick` will execute that command.
146
163
  **/
147
- addNudgeHandler(nudgeHandler: ({ slug, content, onClick, timeout, }: {
148
- slug: string;
149
- content: string;
150
- onClick: () => void;
151
- timeout: number | null;
152
- }) => void): void;
164
+ addNudgeHandler(nudgeHandler: NudgeHandler): void;
153
165
  /**
154
166
  * Add a record action for a key
155
167
  *
@@ -233,7 +245,9 @@ export declare type CommandBarClientSDK = Readonly<{
233
245
  * * `row` {any}
234
246
  * * `node` {any}
235
247
  */
236
- generateDetailPreview(fn: (data: DataRow, metadata: DataRowMedata) => undefined | DetailPreviewType): void;
248
+ generateDetailPreview(fn: (data: DataRow, metadata: DataRowMetadata) => undefined | DetailPreviewType): void;
249
+ addComponent(key: string, name: string, component: CustomComponent): void;
250
+ removeComponent(key: string): void;
237
251
  /**
238
252
  * Returns an array returning all commands that fit the optional filter function. By default, all commands are returned
239
253
  * @param filter A function that filters out commands based on its properties. These are:
@@ -323,6 +337,12 @@ export declare type CommandBarClientSDK = Readonly<{
323
337
  * callback keys, and the values are the supplied functions.
324
338
  */
325
339
  shareCallbacks(): Record<string, CallbackFunction<unknown>>;
340
+ /**
341
+ * Returns dictionary representing the Custom Components currently defined (via addComponent).
342
+ *
343
+ * The keys represent component keys, and the value is the name of the component.
344
+ */
345
+ shareComponentNamesByKey(): Record<string, string>;
326
346
  /** Returns the key value dictionary representing the current state of context */
327
347
  shareContext(): Metadata;
328
348
  /**
@@ -1,6 +1,6 @@
1
1
  import { OrgConfig } from './OrgConfig';
2
2
  import { SDKConfig } from './CommandBarSDK';
3
- import { _configuration, _disposed, _isProxy, _queue, _reporter, _unwrap, _orgConfig } from './symbols';
3
+ import { _configuration, _disposed, _isProxy, _queue, _reporter, _unwrap, _orgConfig, _eventSubscriptions } from './symbols';
4
4
  /**
5
5
  * A proxy object that absorbs function calls into a queue that can be later consumed. The queue contains the name of
6
6
  * properties accessed for function calls including any arguments passed.
@@ -43,6 +43,7 @@ export interface CommandBarProxyGlobal {
43
43
  [_configuration]?: Partial<SDKConfig>;
44
44
  [_orgConfig]?: OrgConfig;
45
45
  [_reporter]?: any;
46
+ [_eventSubscriptions]: undefined;
46
47
  }
47
48
  /** Tests if the given object is a "proxy" SDK object that has not yet been upgraded to a client SDK object. */
48
49
  export declare function isProxySDK(x: unknown): x is CommandBarProxySDK;
@@ -1,10 +1,11 @@
1
1
  import { CommandBarClientSDK, InstanceAttributes, Metadata } from './CommandBarClientSDK';
2
2
  import { EVENT_NAME } from './AnalyticsEventTypes';
3
3
  import { SentryReporter } from './SentryReporter';
4
- import { _access, _configuration, _configure, _configUser, _dispose, _disposed, _userAttributes, _isProxy, _loadEditor, _orgConfig, _perf, _programmaticTheme, _reloadCommands, _reloadOrganization, _reloadPlaceholders, _reloadNudges, _report, _reporter, _search, _setDashboard, _setPreviewMode, _setTestMode, _showGuide, _showMessage, _user, _instanceAttributes, _setEditorVisible, _shareContextSettings, _shareProgrammaticCommands } from './symbols';
4
+ import { _access, _configuration, _configure, _configUser, _dispose, _disposed, _eventSubscriptions, _userAttributes, _isProxy, _loadEditor, _orgConfig, _perf, _programmaticTheme, _reloadCommands, _reloadOrganization, _reloadPlaceholders, _reloadNudges, _report, _reporter, _search, _setDashboard, _setPreviewMode, _setTestMode, _showGuide, _showMessage, _user, _instanceAttributes, _setEditorVisible, _shareContextSettings, _shareProgrammaticCommands } from './symbols';
5
5
  import { SDKConfig } from './SDKConfig';
6
6
  import { ICommandType, IResourceSettingsByContextKey } from '../middleware/types';
7
7
  import { OrgConfig } from './OrgConfig';
8
+ import { EventSubscriber } from './EventHandler';
8
9
  export type { SDKConfig } from './SDKConfig';
9
10
  export interface CommandBarSDK extends CommandBarClientSDK {
10
11
  [_access]: string | undefined;
@@ -15,6 +16,7 @@ export interface CommandBarSDK extends CommandBarClientSDK {
15
16
  [_search]: string;
16
17
  [_user]: string | undefined;
17
18
  [_userAttributes]: Metadata | undefined;
19
+ [_eventSubscriptions]: Map<symbol, EventSubscriber> | undefined;
18
20
  /** @deprecated */
19
21
  readonly [_configure]: (uuid: string) => void;
20
22
  readonly [_configuration]: SDKConfig;
@@ -1,4 +1,12 @@
1
+ interface EventCommandDetailsBase {
2
+ icon: string | null;
3
+ }
4
+ interface EventLinkCommandDetails {
5
+ url: string;
6
+ }
7
+ export declare type EventCommandDetails = EventCommandDetailsBase | EventLinkCommandDetails;
1
8
  export interface AbandonedSearchEvent {
9
+ type: 'abandoned_search';
2
10
  /** Event data passed for `abandoned_search` events (deadends). */
3
11
  /** The id of the currently active command, if there is one. */
4
12
  command?: number;
@@ -9,7 +17,7 @@ export interface AbandonedSearchEvent {
9
17
  /** The context key of the currently active resource, if there is one. */
10
18
  resource?: string;
11
19
  /** The trigger for the deadend. */
12
- type: 'Backspaced' | 'Closed with text' | 'Resetting search';
20
+ trigger: 'Backspaced' | 'Closed with text' | 'Resetting search';
13
21
  /** The number of {CommandOptions, ParameterOptions}, if there are any. */
14
22
  results?: {
15
23
  numCommands: number;
@@ -19,6 +27,7 @@ export interface AbandonedSearchEvent {
19
27
  previousCommands?: string[];
20
28
  }
21
29
  export interface ClosedEvent {
30
+ type: 'closed';
22
31
  /** Event data passed for `command_execution` events. */
23
32
  /** The user's input text when the bar was closed. */
24
33
  inputText: string;
@@ -26,6 +35,7 @@ export interface ClosedEvent {
26
35
  shortcut?: boolean;
27
36
  }
28
37
  export interface CommandExecutionEvent {
38
+ type: 'command_execution';
29
39
  /** Event data passed for `command_execution` events. */
30
40
  /** The category id of the command. Only provided if the command has a category. */
31
41
  category?: string | number | null;
@@ -52,8 +62,10 @@ export interface CommandExecutionEvent {
52
62
  commandType?: 'admin' | 'link' | 'script' | 'clickByXpath' | 'clickBySelector' | 'click' | 'callback' | 'builtin' | 'webhook' | 'request' | 'video' | 'helpdoc' | 'appcues';
53
63
  /** Selected arguments */
54
64
  selections?: Record<string, unknown>;
65
+ commandDetails: EventCommandDetails;
55
66
  }
56
67
  export interface EndUserShortcutChangedEvent {
68
+ type: 'shortcut_edited';
57
69
  /** Event data passed for `command_execution` events. */
58
70
  /** The category id of the command. Only provided if the command has a category. */
59
71
  category?: number | null;
@@ -72,10 +84,12 @@ export interface EndUserShortcutChangedEvent {
72
84
  defaultShortcut: string;
73
85
  }
74
86
  export interface CommandSuggestionEvent {
87
+ type: 'command_suggestion';
75
88
  /** The text of the suggestion. */
76
89
  text: string;
77
90
  }
78
91
  export interface OpenedEvent {
92
+ type: 'opened';
79
93
  /** Event data passed for `command_execution` events. */
80
94
  /**
81
95
  * The entrypoint through which the bar was opened.
@@ -92,10 +106,13 @@ export interface OpenedEvent {
92
106
  }
93
107
  export declare type OpenedEventTrigger = OpenedEvent['trigger'];
94
108
  export interface NoResultsForQueryEvent {
109
+ type: 'no_results_for_query';
95
110
  /** Event data passed for `no_results_for_query` event */
96
111
  /** The user's input text when the no results state was reached. */
97
112
  inputText: string;
98
113
  }
99
- export declare type EventData = AbandonedSearchEvent | ClosedEvent | CommandExecutionEvent | CommandSuggestionEvent | OpenedEvent | NoResultsForQueryEvent;
114
+ export declare type EventData = AbandonedSearchEvent | ClosedEvent | CommandExecutionEvent | CommandSuggestionEvent | OpenedEvent | NoResultsForQueryEvent | EndUserShortcutChangedEvent;
100
115
  export declare type EventHandler = (eventName: EventType, eventData: EventData) => void;
116
+ export declare type EventSubscriber = EventHandler;
101
117
  export declare type EventType = 'abandoned_search' | 'command_suggestion' | 'command_execution' | 'opened' | 'closed' | 'no_results_for_query' | 'client_error' | 'shortcut_edited';
118
+ export {};
@@ -31,3 +31,4 @@ export declare const _state: unique symbol;
31
31
  export declare const _unwrap: unique symbol;
32
32
  export declare const _user: unique symbol;
33
33
  export declare const _userAttributes: unique symbol;
34
+ export declare const _eventSubscriptions: unique symbol;
@@ -58,6 +58,14 @@ export declare const CommandFromClientV: t.IntersectionC<[t.TypeC<{
58
58
  object: t.StringC;
59
59
  hoverTooltip: t.BooleanC;
60
60
  operation: t.UnionC<[t.LiteralC<"router">, t.LiteralC<"self">, t.LiteralC<"blank">, t.UndefinedC]>;
61
+ }>]>]>, t.IntersectionC<[t.TypeC<{
62
+ type: t.LiteralC<"helpdoc">;
63
+ value: t.StringC;
64
+ }>, t.IntersectionC<[t.TypeC<{}>, t.PartialC<{
65
+ commandType: t.UnionC<[t.LiteralC<"independent">, t.LiteralC<"object">, t.LiteralC<"help">]>;
66
+ object: t.StringC;
67
+ hoverTooltip: t.BooleanC;
68
+ operation: t.UnionC<[t.LiteralC<"router">, t.LiteralC<"self">, t.LiteralC<"blank">, t.UndefinedC]>;
61
69
  }>]>]>]>;
62
70
  text: t.StringC;
63
71
  }>, t.PartialC<{
@@ -207,6 +215,7 @@ export declare const CommandFromClientV: t.IntersectionC<[t.TypeC<{
207
215
  }>]>]>>;
208
216
  category: t.UnionC<[t.NumberC, t.StringC, t.NullC]>;
209
217
  icon: t.UnionC<[t.StringC, t.NullC]>;
218
+ image: t.UnionC<[t.StringC, t.NullC]>;
210
219
  celebrate: t.UnionC<[t.BooleanC, t.PartialC<{
211
220
  angle: t.NumberC;
212
221
  spread: t.NumberC;
@@ -283,12 +292,12 @@ export declare const CommandFromClientV: t.IntersectionC<[t.TypeC<{
283
292
  availability_expression: t.ArrayC<t.Type<import("./helpers/rules").RuleExpression, import("./helpers/rules").RuleExpression, unknown>>;
284
293
  recommend_expression: t.ArrayC<t.Type<import("./helpers/rules").RuleExpression, import("./helpers/rules").RuleExpression, unknown>>;
285
294
  detail: t.UnionC<[t.StringC, t.IntersectionC<[t.TypeC<{
286
- type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.NullC]>;
295
+ type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.LiteralC<"component">]>;
287
296
  value: t.StringC;
288
297
  }>, t.PartialC<{
289
298
  position: t.UnionC<[t.LiteralC<"inline">, t.LiteralC<"popover">]>;
290
299
  }>]>, t.ArrayC<t.IntersectionC<[t.TypeC<{
291
- type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.NullC]>;
300
+ type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.LiteralC<"component">]>;
292
301
  value: t.StringC;
293
302
  }>, t.PartialC<{
294
303
  position: t.UnionC<[t.LiteralC<"inline">, t.LiteralC<"popover">]>;
@@ -24,6 +24,7 @@ declare const OrganizationAdditionalV: t.TypeC<{
24
24
  unfurl: t.BooleanC;
25
25
  description_field: t.StringC;
26
26
  icon: t.StringC;
27
+ image: t.StringC;
27
28
  sort_key: t.NumberC;
28
29
  max_options_count: t.UnionC<[t.NumberC, t.NullC]>;
29
30
  sortFunction: t.AnyC;
@@ -38,6 +39,17 @@ declare const OrganizationAdditionalV: t.TypeC<{
38
39
  search_tab_instruction: t.UnionC<[t.StringC, t.NullC]>;
39
40
  setting_pin_to_bottom: t.BooleanC;
40
41
  track_recents: t.BooleanC;
42
+ detail: t.UnionC<[t.NullC, t.StringC, t.IntersectionC<[t.TypeC<{
43
+ type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.LiteralC<"component">]>;
44
+ value: t.StringC;
45
+ }>, t.PartialC<{
46
+ position: t.UnionC<[t.LiteralC<"inline">, t.LiteralC<"popover">]>;
47
+ }>]>, t.ArrayC<t.UnionC<[t.StringC, t.IntersectionC<[t.TypeC<{
48
+ type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.LiteralC<"component">]>;
49
+ value: t.StringC;
50
+ }>, t.PartialC<{
51
+ position: t.UnionC<[t.LiteralC<"inline">, t.LiteralC<"popover">]>;
52
+ }>]>]>>]>;
41
53
  }>>;
42
54
  should_show_onboarding: t.BooleanC;
43
55
  last_snippet_request: t.UnionC<[t.StringC, t.NullC]>;
@@ -93,6 +105,7 @@ export declare const OrganizationV: t.IntersectionC<[t.IntersectionC<[t.TypeC<{
93
105
  unfurl: t.BooleanC;
94
106
  description_field: t.StringC;
95
107
  icon: t.StringC;
108
+ image: t.StringC;
96
109
  sort_key: t.NumberC;
97
110
  max_options_count: t.UnionC<[t.NumberC, t.NullC]>;
98
111
  sortFunction: t.AnyC;
@@ -107,6 +120,17 @@ export declare const OrganizationV: t.IntersectionC<[t.IntersectionC<[t.TypeC<{
107
120
  search_tab_instruction: t.UnionC<[t.StringC, t.NullC]>;
108
121
  setting_pin_to_bottom: t.BooleanC;
109
122
  track_recents: t.BooleanC;
123
+ detail: t.UnionC<[t.NullC, t.StringC, t.IntersectionC<[t.TypeC<{
124
+ type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.LiteralC<"component">]>;
125
+ value: t.StringC;
126
+ }>, t.PartialC<{
127
+ position: t.UnionC<[t.LiteralC<"inline">, t.LiteralC<"popover">]>;
128
+ }>]>, t.ArrayC<t.UnionC<[t.StringC, t.IntersectionC<[t.TypeC<{
129
+ type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.LiteralC<"component">]>;
130
+ value: t.StringC;
131
+ }>, t.PartialC<{
132
+ position: t.UnionC<[t.LiteralC<"inline">, t.LiteralC<"popover">]>;
133
+ }>]>]>>]>;
110
134
  }>>;
111
135
  should_show_onboarding: t.BooleanC;
112
136
  last_snippet_request: t.UnionC<[t.StringC, t.NullC]>;
@@ -16,6 +16,7 @@ export declare const ResourceSettingsV: t.PartialC<{
16
16
  unfurl: t.BooleanC;
17
17
  description_field: t.StringC;
18
18
  icon: t.StringC;
19
+ image: t.StringC;
19
20
  sort_key: t.NumberC;
20
21
  max_options_count: t.UnionC<[t.NumberC, t.NullC]>;
21
22
  sortFunction: t.AnyC;
@@ -30,6 +31,17 @@ export declare const ResourceSettingsV: t.PartialC<{
30
31
  search_tab_instruction: t.UnionC<[t.StringC, t.NullC]>;
31
32
  setting_pin_to_bottom: t.BooleanC;
32
33
  track_recents: t.BooleanC;
34
+ detail: t.UnionC<[t.NullC, t.StringC, t.IntersectionC<[t.TypeC<{
35
+ type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.LiteralC<"component">]>;
36
+ value: t.StringC;
37
+ }>, t.PartialC<{
38
+ position: t.UnionC<[t.LiteralC<"inline">, t.LiteralC<"popover">]>;
39
+ }>]>, t.ArrayC<t.UnionC<[t.StringC, t.IntersectionC<[t.TypeC<{
40
+ type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.LiteralC<"component">]>;
41
+ value: t.StringC;
42
+ }>, t.PartialC<{
43
+ position: t.UnionC<[t.LiteralC<"inline">, t.LiteralC<"popover">]>;
44
+ }>]>]>>]>;
33
45
  }>;
34
46
  export declare const ResourceSettingsByContextKeyV: t.RecordC<t.StringC, t.PartialC<{
35
47
  name: t.StringC;
@@ -44,6 +56,7 @@ export declare const ResourceSettingsByContextKeyV: t.RecordC<t.StringC, t.Parti
44
56
  unfurl: t.BooleanC;
45
57
  description_field: t.StringC;
46
58
  icon: t.StringC;
59
+ image: t.StringC;
47
60
  sort_key: t.NumberC;
48
61
  max_options_count: t.UnionC<[t.NumberC, t.NullC]>;
49
62
  sortFunction: t.AnyC;
@@ -58,4 +71,15 @@ export declare const ResourceSettingsByContextKeyV: t.RecordC<t.StringC, t.Parti
58
71
  search_tab_instruction: t.UnionC<[t.StringC, t.NullC]>;
59
72
  setting_pin_to_bottom: t.BooleanC;
60
73
  track_recents: t.BooleanC;
74
+ detail: t.UnionC<[t.NullC, t.StringC, t.IntersectionC<[t.TypeC<{
75
+ type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.LiteralC<"component">]>;
76
+ value: t.StringC;
77
+ }>, t.PartialC<{
78
+ position: t.UnionC<[t.LiteralC<"inline">, t.LiteralC<"popover">]>;
79
+ }>]>, t.ArrayC<t.UnionC<[t.StringC, t.IntersectionC<[t.TypeC<{
80
+ type: t.UnionC<[t.LiteralC<"plaintext">, t.LiteralC<"markdown">, t.LiteralC<"html">, t.LiteralC<"react">, t.LiteralC<"video">, t.LiteralC<"component">]>;
81
+ value: t.StringC;
82
+ }>, t.PartialC<{
83
+ position: t.UnionC<[t.LiteralC<"inline">, t.LiteralC<"popover">]>;
84
+ }>]>]>>]>;
61
85
  }>>;