260.js 46.8 KB
(self.webpackChunk=self.webpackChunk||[]).push([[260],{1260:(t,e,n)=>{"use strict";n.r(e),n.d(e,{default:()=>u});var r=n(9714),i=n(5007),o=n(6119),s=n(3669);function a(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function l(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?a(Object(n),!0).forEach((function(e){c(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function c(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}const p={metaInfo:function(){return{title:this.campaign.name}},components:{Icon:i.Z,TextInput:o.Z,SelectInput:s.Z},layout:r.Z,props:{token:Object,variables:Array,dictionary:Object,campaign:Object,errors:Object},data:function(){return{variable:this.variables.length?null:"add",default_value:"",name:"",value:"",inputs:{}}},watch:{},methods:{add:function(){this.$inertia.post(this.route("token.campaign.variable.add",[this.token.id,this.dictionary.id,this.campaign.id]),{variable:this.variable,default_value:this.default_value,name:this.name,value:this.value}),this.name="",this.value=""},edit:function(t,e){var n=this;e.map((function(e){n.inputs=l(l({},n.inputs),{},c({},t,l(l({},n.inputs[t]),{},c({},e.name,{editable:!0,val:e.val}))))}))},editCancel:function(t,e){this.inputs=l(l({},this.inputs),{},c({},t,l(l({},this.inputs[t]),{},c({},e,l(l({},this.inputs[t][e]),{},{editable:!1})))))},save:function(t,e){var n=this,r={variable_id:t};e.map((function(e){r[e]=n.inputs[t][e].val,n.editCancel(t,e)})),-1===e.indexOf("name")?this.$inertia.post(this.route("token.campaign.variable.edit",[this.token.id,this.dictionary.id,this.campaign.id]),r):this.$inertia.post(this.route("variable.edit",[t]),r)},destroy:function(t){confirm("Are you sure you want to delete this campaign var?")&&this.$inertia.delete(this.route("variable.destroy",[t]))}}};const u=(0,n(1900).Z)(p,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("h1",{staticClass:"mb-8 font-bold text-3xl"},[n("inertia-link",{staticClass:"text-indigo-400 hover:text-indigo-600",attrs:{href:t.route("tokens")}},[t._v("\n            Tokens\n        ")]),t._v(" "),n("span",{staticClass:"text-indigo-400 font-medium"},[t._v("/")]),t._v(" "),n("inertia-link",{staticClass:"text-indigo-400 hover:text-indigo-600",attrs:{href:t.route("token.edit",t.token.id)}},[t._v("\n            "+t._s(t.token.login)+"\n        ")]),t._v(" "),n("span",{staticClass:"text-indigo-400 font-medium"},[t._v("/")]),t._v("\n        "+t._s(t.dictionary.name)+"\n        "),n("span",{staticClass:"text-indigo-400 font-medium"},[t._v("/")]),t._v("\n        "+t._s(t.campaign.name)+"\n    ")],1),t._v(" "),n("div",{staticClass:"mb-6 flex justify-between items-center"},[n("div",{staticClass:"mt-4 flex flex-wrap"},[n("select-input",{staticClass:"pr-6",attrs:{label:"Variable"},model:{value:t.variable,callback:function(e){t.variable=e},expression:"variable"}},[n("option",{attrs:{value:"add"}},[t._v("\n                    [Add new]\n                ")]),t._v(" "),t._l(t.variables,(function(e){return n("option",{key:e.id,domProps:{value:e.id}},[t._v("\n                    "+t._s(e.name)+"\n                ")])}))],2),t._v(" "),"add"===t.variable?n("text-input",{staticClass:"pr-6",attrs:{error:t.errors.name,label:"New variable name"},model:{value:t.name,callback:function(e){t.name=e},expression:"name"}}):t._e(),t._v(" "),"add"===t.variable?n("text-input",{staticClass:"pr-6",attrs:{error:t.errors.default_value,label:"New variable default value"},model:{value:t.default_value,callback:function(e){t.default_value=e},expression:"default_value"}}):t._e(),t._v(" "),n("text-input",{staticClass:"pr-6",attrs:{error:t.errors.value,label:"Campaign default value"},model:{value:t.value,callback:function(e){t.value=e},expression:"value"}}),t._v(" "),n("button",{staticClass:"btn-indigo hover:underline",attrs:{tabindex:"-1",type:"button"},on:{click:t.add}},[t._v("\n                Add\n            ")])],1)]),t._v(" "),n("div",{staticClass:"bg-white rounded-md shadow overflow-x-auto"},[n("table",{staticClass:"w-full whitespace-nowrap"},[t._m(0),t._v(" "),t._l(t.variables,(function(e){return n("tr",{key:e.id,staticClass:"hover:bg-gray-100 focus-within:bg-gray-100"},[n("td",{staticClass:"px-6 py-4 border-t"},[t.inputs[e.id]&&t.inputs[e.id].name&&t.inputs[e.id].name.editable?n("div",{staticClass:"inline-flex"},[n("text-input",{staticClass:"pr-6",attrs:{label:"Variable name"},model:{value:t.inputs[e.id].name.val,callback:function(n){t.$set(t.inputs[e.id].name,"val",n)},expression:"inputs[variable.id].name.val"}}),t._v(" "),n("text-input",{staticClass:"pr-6",attrs:{label:"Variable default value"},model:{value:t.inputs[e.id].default_value.val,callback:function(n){t.$set(t.inputs[e.id].default_value,"val",n)},expression:"inputs[variable.id].default_value.val"}}),t._v(" "),n("button",{staticClass:"btn-indigo hover:underline mr-6",attrs:{tabindex:"-1",type:"button"},on:{click:function(n){return t.save(e.id,["name","default_value"])}}},[t._v("\n\n                            Save\n                        ")]),t._v(" "),n("button",{staticClass:"btn-indigo hover:underline",attrs:{tabindex:"-1",type:"button"},on:{click:function(n){return t.editCancel(e.id,"name")}}},[t._v("\n\n                            Cancel\n                        ")])],1):n("div",{staticClass:"hover:text-indigo-500 focus:text-indigo-500 cursor-pointer",on:{click:function(n){return t.edit(e.id,[{name:"default_value",val:e.default_value},{name:"name",val:e.name}])}}},[t._v("\n                        "+t._s(e.name)+"\n                    ")])]),t._v(" "),n("td",{staticClass:"px-6 py-4 border-t"},[t.inputs[e.id]&&t.inputs[e.id].value&&t.inputs[e.id].value.editable?n("div",{staticClass:"inline-flex"},[n("text-input",{staticClass:"pr-6",attrs:{label:"Campaign default value"},model:{value:t.inputs[e.id].value.val,callback:function(n){t.$set(t.inputs[e.id].value,"val",n)},expression:"inputs[variable.id].value.val"}}),t._v(" "),n("button",{staticClass:"btn-indigo hover:underline mr-6",attrs:{tabindex:"-1",type:"button"},on:{click:function(n){return t.save(e.id,["value"])}}},[t._v("\n\n                            Save\n                        ")]),t._v(" "),n("button",{staticClass:"btn-indigo hover:underline",attrs:{tabindex:"-1",type:"button"},on:{click:function(n){return t.editCancel(e.id,"value")}}},[t._v("\n\n                            Cancel\n                        ")])],1):n("div",{staticClass:"hover:text-indigo-500 focus:text-indigo-500 cursor-pointer",on:{click:function(n){return t.edit(e.id,[{name:"value",val:e.dictionaryCampaign?e.dictionaryCampaign.value:""}])}}},[t._v("\n                        "+t._s(e.dictionaryCampaign?e.dictionaryCampaign.value:e.default_value)+"\n                    ")])]),t._v(" "),n("td",{staticClass:"px-6 py-4 border-t w-px"},[n("button",{staticClass:"px-4 flex items-center",attrs:{type:"button",tabindex:"-1"},on:{click:function(n){return t.destroy(e.id)}}},[n("icon",{staticClass:"block w-6 h-6 fill-gray-400",attrs:{name:"trash"}})],1)])])})),t._v(" "),0===t.variables.length?n("tr",[n("td",{staticClass:"border-t px-6 py-4",attrs:{colspan:"4"}},[t._v("No variables found.")])]):t._e()],2)])])}),[function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("tr",{staticClass:"text-left font-bold"},[n("th",{staticClass:"px-6 pt-6 pb-4"},[t._v("Name")]),t._v(" "),n("th",{staticClass:"px-6 pt-6 pb-4"},[t._v("Default value")])])}],!1,null,null,null).exports},381:(t,e,n)=>{"use strict";n.d(e,{Z:()=>ut});var r="undefined"!=typeof window&&"undefined"!=typeof document&&"undefined"!=typeof navigator,i=function(){for(var t=["Edge","Trident","Firefox"],e=0;e<t.length;e+=1)if(r&&navigator.userAgent.indexOf(t[e])>=0)return 1;return 0}();var o=r&&window.Promise?function(t){var e=!1;return function(){e||(e=!0,window.Promise.resolve().then((function(){e=!1,t()})))}}:function(t){var e=!1;return function(){e||(e=!0,setTimeout((function(){e=!1,t()}),i))}};function s(t){return t&&"[object Function]"==={}.toString.call(t)}function a(t,e){if(1!==t.nodeType)return[];var n=t.ownerDocument.defaultView.getComputedStyle(t,null);return e?n[e]:n}function l(t){return"HTML"===t.nodeName?t:t.parentNode||t.host}function c(t){if(!t)return document.body;switch(t.nodeName){case"HTML":case"BODY":return t.ownerDocument.body;case"#document":return t.body}var e=a(t),n=e.overflow,r=e.overflowX,i=e.overflowY;return/(auto|scroll|overlay)/.test(n+i+r)?t:c(l(t))}function p(t){return t&&t.referenceNode?t.referenceNode:t}var u=r&&!(!window.MSInputMethodContext||!document.documentMode),d=r&&/MSIE 10/.test(navigator.userAgent);function f(t){return 11===t?u:10===t?d:u||d}function h(t){if(!t)return document.documentElement;for(var e=f(10)?document.body:null,n=t.offsetParent||null;n===e&&t.nextElementSibling;)n=(t=t.nextElementSibling).offsetParent;var r=n&&n.nodeName;return r&&"BODY"!==r&&"HTML"!==r?-1!==["TH","TD","TABLE"].indexOf(n.nodeName)&&"static"===a(n,"position")?h(n):n:t?t.ownerDocument.documentElement:document.documentElement}function v(t){return null!==t.parentNode?v(t.parentNode):t}function m(t,e){if(!(t&&t.nodeType&&e&&e.nodeType))return document.documentElement;var n=t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_FOLLOWING,r=n?t:e,i=n?e:t,o=document.createRange();o.setStart(r,0),o.setEnd(i,0);var s,a,l=o.commonAncestorContainer;if(t!==l&&e!==l||r.contains(i))return"BODY"===(a=(s=l).nodeName)||"HTML"!==a&&h(s.firstElementChild)!==s?h(l):l;var c=v(t);return c.host?m(c.host,e):m(t,v(e).host)}function g(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"top",n="top"===e?"scrollTop":"scrollLeft",r=t.nodeName;if("BODY"===r||"HTML"===r){var i=t.ownerDocument.documentElement,o=t.ownerDocument.scrollingElement||i;return o[n]}return t[n]}function w(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=g(e,"top"),i=g(e,"left"),o=n?-1:1;return t.top+=r*o,t.bottom+=r*o,t.left+=i*o,t.right+=i*o,t}function b(t,e){var n="x"===e?"Left":"Top",r="Left"===n?"Right":"Bottom";return parseFloat(t["border"+n+"Width"])+parseFloat(t["border"+r+"Width"])}function x(t,e,n,r){return Math.max(e["offset"+t],e["scroll"+t],n["client"+t],n["offset"+t],n["scroll"+t],f(10)?parseInt(n["offset"+t])+parseInt(r["margin"+("Height"===t?"Top":"Left")])+parseInt(r["margin"+("Height"===t?"Bottom":"Right")]):0)}function y(t){var e=t.body,n=t.documentElement,r=f(10)&&getComputedStyle(n);return{height:x("Height",e,n,r),width:x("Width",e,n,r)}}var _=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")},C=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),k=function(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t},O=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};function E(t){return O({},t,{right:t.left+t.width,bottom:t.top+t.height})}function z(t){var e={};try{if(f(10)){e=t.getBoundingClientRect();var n=g(t,"top"),r=g(t,"left");e.top+=n,e.left+=r,e.bottom+=n,e.right+=r}else e=t.getBoundingClientRect()}catch(t){}var i={left:e.left,top:e.top,width:e.right-e.left,height:e.bottom-e.top},o="HTML"===t.nodeName?y(t.ownerDocument):{},s=o.width||t.clientWidth||i.width,l=o.height||t.clientHeight||i.height,c=t.offsetWidth-s,p=t.offsetHeight-l;if(c||p){var u=a(t);c-=b(u,"x"),p-=b(u,"y"),i.width-=c,i.height-=p}return E(i)}function M(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=f(10),i="HTML"===e.nodeName,o=z(t),s=z(e),l=c(t),p=a(e),u=parseFloat(p.borderTopWidth),d=parseFloat(p.borderLeftWidth);n&&i&&(s.top=Math.max(s.top,0),s.left=Math.max(s.left,0));var h=E({top:o.top-s.top-u,left:o.left-s.left-d,width:o.width,height:o.height});if(h.marginTop=0,h.marginLeft=0,!r&&i){var v=parseFloat(p.marginTop),m=parseFloat(p.marginLeft);h.top-=u-v,h.bottom-=u-v,h.left-=d-m,h.right-=d-m,h.marginTop=v,h.marginLeft=m}return(r&&!n?e.contains(l):e===l&&"BODY"!==l.nodeName)&&(h=w(h,e)),h}function L(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=t.ownerDocument.documentElement,r=M(t,n),i=Math.max(n.clientWidth,window.innerWidth||0),o=Math.max(n.clientHeight,window.innerHeight||0),s=e?0:g(n),a=e?0:g(n,"left"),l={top:s-r.top+r.marginTop,left:a-r.left+r.marginLeft,width:i,height:o};return E(l)}function H(t){var e=t.nodeName;if("BODY"===e||"HTML"===e)return!1;if("fixed"===a(t,"position"))return!0;var n=l(t);return!!n&&H(n)}function V(t){if(!t||!t.parentElement||f())return document.documentElement;for(var e=t.parentElement;e&&"none"===a(e,"transform");)e=e.parentElement;return e||document.documentElement}function $(t,e,n,r){var i=arguments.length>4&&void 0!==arguments[4]&&arguments[4],o={top:0,left:0},s=i?V(t):m(t,p(e));if("viewport"===r)o=L(s,i);else{var a=void 0;"scrollParent"===r?"BODY"===(a=c(l(e))).nodeName&&(a=t.ownerDocument.documentElement):a="window"===r?t.ownerDocument.documentElement:r;var u=M(a,s,i);if("HTML"!==a.nodeName||H(s))o=u;else{var d=y(t.ownerDocument),f=d.height,h=d.width;o.top+=u.top-u.marginTop,o.bottom=f+u.top,o.left+=u.left-u.marginLeft,o.right=h+u.left}}var v="number"==typeof(n=n||0);return o.left+=v?n:n.left||0,o.top+=v?n:n.top||0,o.right-=v?n:n.right||0,o.bottom-=v?n:n.bottom||0,o}function S(t){return t.width*t.height}function T(t,e,n,r,i){var o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0;if(-1===t.indexOf("auto"))return t;var s=$(n,r,o,i),a={top:{width:s.width,height:e.top-s.top},right:{width:s.right-e.right,height:s.height},bottom:{width:s.width,height:s.bottom-e.bottom},left:{width:e.left-s.left,height:s.height}},l=Object.keys(a).map((function(t){return O({key:t},a[t],{area:S(a[t])})})).sort((function(t,e){return e.area-t.area})),c=l.filter((function(t){var e=t.width,r=t.height;return e>=n.clientWidth&&r>=n.clientHeight})),p=c.length>0?c[0].key:l[0].key,u=t.split("-")[1];return p+(u?"-"+u:"")}function B(t,e,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=r?V(e):m(e,p(n));return M(n,i,r)}function j(t){var e=t.ownerDocument.defaultView.getComputedStyle(t),n=parseFloat(e.marginTop||0)+parseFloat(e.marginBottom||0),r=parseFloat(e.marginLeft||0)+parseFloat(e.marginRight||0);return{width:t.offsetWidth+r,height:t.offsetHeight+n}}function D(t){var e={left:"right",right:"left",bottom:"top",top:"bottom"};return t.replace(/left|right|bottom|top/g,(function(t){return e[t]}))}function N(t,e,n){n=n.split("-")[0];var r=j(t),i={width:r.width,height:r.height},o=-1!==["right","left"].indexOf(n),s=o?"top":"left",a=o?"left":"top",l=o?"height":"width",c=o?"width":"height";return i[s]=e[s]+e[l]/2-r[l]/2,i[a]=n===a?e[a]-r[c]:e[D(a)],i}function A(t,e){return Array.prototype.find?t.find(e):t.filter(e)[0]}function P(t,e,n){return(void 0===n?t:t.slice(0,function(t,e,n){if(Array.prototype.findIndex)return t.findIndex((function(t){return t[e]===n}));var r=A(t,(function(t){return t[e]===n}));return t.indexOf(r)}(t,"name",n))).forEach((function(t){t.function&&console.warn("`modifier.function` is deprecated, use `modifier.fn`!");var n=t.function||t.fn;t.enabled&&s(n)&&(e.offsets.popper=E(e.offsets.popper),e.offsets.reference=E(e.offsets.reference),e=n(e,t))})),e}function F(){if(!this.state.isDestroyed){var t={instance:this,styles:{},arrowStyles:{},attributes:{},flipped:!1,offsets:{}};t.offsets.reference=B(this.state,this.popper,this.reference,this.options.positionFixed),t.placement=T(this.options.placement,t.offsets.reference,this.popper,this.reference,this.options.modifiers.flip.boundariesElement,this.options.modifiers.flip.padding),t.originalPlacement=t.placement,t.positionFixed=this.options.positionFixed,t.offsets.popper=N(this.popper,t.offsets.reference,t.placement),t.offsets.popper.position=this.options.positionFixed?"fixed":"absolute",t=P(this.modifiers,t),this.state.isCreated?this.options.onUpdate(t):(this.state.isCreated=!0,this.options.onCreate(t))}}function Z(t,e){return t.some((function(t){var n=t.name;return t.enabled&&n===e}))}function U(t){for(var e=[!1,"ms","Webkit","Moz","O"],n=t.charAt(0).toUpperCase()+t.slice(1),r=0;r<e.length;r++){var i=e[r],o=i?""+i+n:t;if(void 0!==document.body.style[o])return o}return null}function W(){return this.state.isDestroyed=!0,Z(this.modifiers,"applyStyle")&&(this.popper.removeAttribute("x-placement"),this.popper.style.position="",this.popper.style.top="",this.popper.style.left="",this.popper.style.right="",this.popper.style.bottom="",this.popper.style.willChange="",this.popper.style[U("transform")]=""),this.disableEventListeners(),this.options.removeOnDestroy&&this.popper.parentNode.removeChild(this.popper),this}function I(t){var e=t.ownerDocument;return e?e.defaultView:window}function R(t,e,n,r){var i="BODY"===t.nodeName,o=i?t.ownerDocument.defaultView:t;o.addEventListener(e,n,{passive:!0}),i||R(c(o.parentNode),e,n,r),r.push(o)}function Y(t,e,n,r){n.updateBound=r,I(t).addEventListener("resize",n.updateBound,{passive:!0});var i=c(t);return R(i,"scroll",n.updateBound,n.scrollParents),n.scrollElement=i,n.eventsEnabled=!0,n}function q(){this.state.eventsEnabled||(this.state=Y(this.reference,this.options,this.state,this.scheduleUpdate))}function G(){var t,e;this.state.eventsEnabled&&(cancelAnimationFrame(this.scheduleUpdate),this.state=(t=this.reference,e=this.state,I(t).removeEventListener("resize",e.updateBound),e.scrollParents.forEach((function(t){t.removeEventListener("scroll",e.updateBound)})),e.updateBound=null,e.scrollParents=[],e.scrollElement=null,e.eventsEnabled=!1,e))}function X(t){return""!==t&&!isNaN(parseFloat(t))&&isFinite(t)}function J(t,e){Object.keys(e).forEach((function(n){var r="";-1!==["width","height","top","right","bottom","left"].indexOf(n)&&X(e[n])&&(r="px"),t.style[n]=e[n]+r}))}var K=r&&/Firefox/i.test(navigator.userAgent);function Q(t,e,n){var r=A(t,(function(t){return t.name===e})),i=!!r&&t.some((function(t){return t.name===n&&t.enabled&&t.order<r.order}));if(!i){var o="`"+e+"`",s="`"+n+"`";console.warn(s+" modifier is required by "+o+" modifier in order to work, be sure to include it before "+o+"!")}return i}var tt=["auto-start","auto","auto-end","top-start","top","top-end","right-start","right","right-end","bottom-end","bottom","bottom-start","left-end","left","left-start"],et=tt.slice(3);function nt(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=et.indexOf(t),r=et.slice(n+1).concat(et.slice(0,n));return e?r.reverse():r}var rt="flip",it="clockwise",ot="counterclockwise";function st(t,e,n,r){var i=[0,0],o=-1!==["right","left"].indexOf(r),s=t.split(/(\+|\-)/).map((function(t){return t.trim()})),a=s.indexOf(A(s,(function(t){return-1!==t.search(/,|\s/)})));s[a]&&-1===s[a].indexOf(",")&&console.warn("Offsets separated by white space(s) are deprecated, use a comma (,) instead.");var l=/\s*,\s*|\s+/,c=-1!==a?[s.slice(0,a).concat([s[a].split(l)[0]]),[s[a].split(l)[1]].concat(s.slice(a+1))]:[s];return(c=c.map((function(t,r){var i=(1===r?!o:o)?"height":"width",s=!1;return t.reduce((function(t,e){return""===t[t.length-1]&&-1!==["+","-"].indexOf(e)?(t[t.length-1]=e,s=!0,t):s?(t[t.length-1]+=e,s=!1,t):t.concat(e)}),[]).map((function(t){return function(t,e,n,r){var i=t.match(/((?:\-|\+)?\d*\.?\d*)(.*)/),o=+i[1],s=i[2];if(!o)return t;if(0===s.indexOf("%")){var a=void 0;switch(s){case"%p":a=n;break;case"%":case"%r":default:a=r}return E(a)[e]/100*o}if("vh"===s||"vw"===s)return("vh"===s?Math.max(document.documentElement.clientHeight,window.innerHeight||0):Math.max(document.documentElement.clientWidth,window.innerWidth||0))/100*o;return o}(t,i,e,n)}))}))).forEach((function(t,e){t.forEach((function(n,r){X(n)&&(i[e]+=n*("-"===t[r-1]?-1:1))}))})),i}var at={placement:"bottom",positionFixed:!1,eventsEnabled:!0,removeOnDestroy:!1,onCreate:function(){},onUpdate:function(){},modifiers:{shift:{order:100,enabled:!0,fn:function(t){var e=t.placement,n=e.split("-")[0],r=e.split("-")[1];if(r){var i=t.offsets,o=i.reference,s=i.popper,a=-1!==["bottom","top"].indexOf(n),l=a?"left":"top",c=a?"width":"height",p={start:k({},l,o[l]),end:k({},l,o[l]+o[c]-s[c])};t.offsets.popper=O({},s,p[r])}return t}},offset:{order:200,enabled:!0,fn:function(t,e){var n=e.offset,r=t.placement,i=t.offsets,o=i.popper,s=i.reference,a=r.split("-")[0],l=void 0;return l=X(+n)?[+n,0]:st(n,o,s,a),"left"===a?(o.top+=l[0],o.left-=l[1]):"right"===a?(o.top+=l[0],o.left+=l[1]):"top"===a?(o.left+=l[0],o.top-=l[1]):"bottom"===a&&(o.left+=l[0],o.top+=l[1]),t.popper=o,t},offset:0},preventOverflow:{order:300,enabled:!0,fn:function(t,e){var n=e.boundariesElement||h(t.instance.popper);t.instance.reference===n&&(n=h(n));var r=U("transform"),i=t.instance.popper.style,o=i.top,s=i.left,a=i[r];i.top="",i.left="",i[r]="";var l=$(t.instance.popper,t.instance.reference,e.padding,n,t.positionFixed);i.top=o,i.left=s,i[r]=a,e.boundaries=l;var c=e.priority,p=t.offsets.popper,u={primary:function(t){var n=p[t];return p[t]<l[t]&&!e.escapeWithReference&&(n=Math.max(p[t],l[t])),k({},t,n)},secondary:function(t){var n="right"===t?"left":"top",r=p[n];return p[t]>l[t]&&!e.escapeWithReference&&(r=Math.min(p[n],l[t]-("right"===t?p.width:p.height))),k({},n,r)}};return c.forEach((function(t){var e=-1!==["left","top"].indexOf(t)?"primary":"secondary";p=O({},p,u[e](t))})),t.offsets.popper=p,t},priority:["left","right","top","bottom"],padding:5,boundariesElement:"scrollParent"},keepTogether:{order:400,enabled:!0,fn:function(t){var e=t.offsets,n=e.popper,r=e.reference,i=t.placement.split("-")[0],o=Math.floor,s=-1!==["top","bottom"].indexOf(i),a=s?"right":"bottom",l=s?"left":"top",c=s?"width":"height";return n[a]<o(r[l])&&(t.offsets.popper[l]=o(r[l])-n[c]),n[l]>o(r[a])&&(t.offsets.popper[l]=o(r[a])),t}},arrow:{order:500,enabled:!0,fn:function(t,e){var n;if(!Q(t.instance.modifiers,"arrow","keepTogether"))return t;var r=e.element;if("string"==typeof r){if(!(r=t.instance.popper.querySelector(r)))return t}else if(!t.instance.popper.contains(r))return console.warn("WARNING: `arrow.element` must be child of its popper element!"),t;var i=t.placement.split("-")[0],o=t.offsets,s=o.popper,l=o.reference,c=-1!==["left","right"].indexOf(i),p=c?"height":"width",u=c?"Top":"Left",d=u.toLowerCase(),f=c?"left":"top",h=c?"bottom":"right",v=j(r)[p];l[h]-v<s[d]&&(t.offsets.popper[d]-=s[d]-(l[h]-v)),l[d]+v>s[h]&&(t.offsets.popper[d]+=l[d]+v-s[h]),t.offsets.popper=E(t.offsets.popper);var m=l[d]+l[p]/2-v/2,g=a(t.instance.popper),w=parseFloat(g["margin"+u]),b=parseFloat(g["border"+u+"Width"]),x=m-t.offsets.popper[d]-w-b;return x=Math.max(Math.min(s[p]-v,x),0),t.arrowElement=r,t.offsets.arrow=(k(n={},d,Math.round(x)),k(n,f,""),n),t},element:"[x-arrow]"},flip:{order:600,enabled:!0,fn:function(t,e){if(Z(t.instance.modifiers,"inner"))return t;if(t.flipped&&t.placement===t.originalPlacement)return t;var n=$(t.instance.popper,t.instance.reference,e.padding,e.boundariesElement,t.positionFixed),r=t.placement.split("-")[0],i=D(r),o=t.placement.split("-")[1]||"",s=[];switch(e.behavior){case rt:s=[r,i];break;case it:s=nt(r);break;case ot:s=nt(r,!0);break;default:s=e.behavior}return s.forEach((function(a,l){if(r!==a||s.length===l+1)return t;r=t.placement.split("-")[0],i=D(r);var c=t.offsets.popper,p=t.offsets.reference,u=Math.floor,d="left"===r&&u(c.right)>u(p.left)||"right"===r&&u(c.left)<u(p.right)||"top"===r&&u(c.bottom)>u(p.top)||"bottom"===r&&u(c.top)<u(p.bottom),f=u(c.left)<u(n.left),h=u(c.right)>u(n.right),v=u(c.top)<u(n.top),m=u(c.bottom)>u(n.bottom),g="left"===r&&f||"right"===r&&h||"top"===r&&v||"bottom"===r&&m,w=-1!==["top","bottom"].indexOf(r),b=!!e.flipVariations&&(w&&"start"===o&&f||w&&"end"===o&&h||!w&&"start"===o&&v||!w&&"end"===o&&m),x=!!e.flipVariationsByContent&&(w&&"start"===o&&h||w&&"end"===o&&f||!w&&"start"===o&&m||!w&&"end"===o&&v),y=b||x;(d||g||y)&&(t.flipped=!0,(d||g)&&(r=s[l+1]),y&&(o=function(t){return"end"===t?"start":"start"===t?"end":t}(o)),t.placement=r+(o?"-"+o:""),t.offsets.popper=O({},t.offsets.popper,N(t.instance.popper,t.offsets.reference,t.placement)),t=P(t.instance.modifiers,t,"flip"))})),t},behavior:"flip",padding:5,boundariesElement:"viewport",flipVariations:!1,flipVariationsByContent:!1},inner:{order:700,enabled:!1,fn:function(t){var e=t.placement,n=e.split("-")[0],r=t.offsets,i=r.popper,o=r.reference,s=-1!==["left","right"].indexOf(n),a=-1===["top","left"].indexOf(n);return i[s?"left":"top"]=o[n]-(a?i[s?"width":"height"]:0),t.placement=D(e),t.offsets.popper=E(i),t}},hide:{order:800,enabled:!0,fn:function(t){if(!Q(t.instance.modifiers,"hide","preventOverflow"))return t;var e=t.offsets.reference,n=A(t.instance.modifiers,(function(t){return"preventOverflow"===t.name})).boundaries;if(e.bottom<n.top||e.left>n.right||e.top>n.bottom||e.right<n.left){if(!0===t.hide)return t;t.hide=!0,t.attributes["x-out-of-boundaries"]=""}else{if(!1===t.hide)return t;t.hide=!1,t.attributes["x-out-of-boundaries"]=!1}return t}},computeStyle:{order:850,enabled:!0,fn:function(t,e){var n=e.x,r=e.y,i=t.offsets.popper,o=A(t.instance.modifiers,(function(t){return"applyStyle"===t.name})).gpuAcceleration;void 0!==o&&console.warn("WARNING: `gpuAcceleration` option moved to `computeStyle` modifier and will not be supported in future versions of Popper.js!");var s=void 0!==o?o:e.gpuAcceleration,a=h(t.instance.popper),l=z(a),c={position:i.position},p=function(t,e){var n=t.offsets,r=n.popper,i=n.reference,o=Math.round,s=Math.floor,a=function(t){return t},l=o(i.width),c=o(r.width),p=-1!==["left","right"].indexOf(t.placement),u=-1!==t.placement.indexOf("-"),d=e?p||u||l%2==c%2?o:s:a,f=e?o:a;return{left:d(l%2==1&&c%2==1&&!u&&e?r.left-1:r.left),top:f(r.top),bottom:f(r.bottom),right:d(r.right)}}(t,window.devicePixelRatio<2||!K),u="bottom"===n?"top":"bottom",d="right"===r?"left":"right",f=U("transform"),v=void 0,m=void 0;if(m="bottom"===u?"HTML"===a.nodeName?-a.clientHeight+p.bottom:-l.height+p.bottom:p.top,v="right"===d?"HTML"===a.nodeName?-a.clientWidth+p.right:-l.width+p.right:p.left,s&&f)c[f]="translate3d("+v+"px, "+m+"px, 0)",c[u]=0,c[d]=0,c.willChange="transform";else{var g="bottom"===u?-1:1,w="right"===d?-1:1;c[u]=m*g,c[d]=v*w,c.willChange=u+", "+d}var b={"x-placement":t.placement};return t.attributes=O({},b,t.attributes),t.styles=O({},c,t.styles),t.arrowStyles=O({},t.offsets.arrow,t.arrowStyles),t},gpuAcceleration:!0,x:"bottom",y:"right"},applyStyle:{order:900,enabled:!0,fn:function(t){var e,n;return J(t.instance.popper,t.styles),e=t.instance.popper,n=t.attributes,Object.keys(n).forEach((function(t){!1!==n[t]?e.setAttribute(t,n[t]):e.removeAttribute(t)})),t.arrowElement&&Object.keys(t.arrowStyles).length&&J(t.arrowElement,t.arrowStyles),t},onLoad:function(t,e,n,r,i){var o=B(i,e,t,n.positionFixed),s=T(n.placement,o,e,t,n.modifiers.flip.boundariesElement,n.modifiers.flip.padding);return e.setAttribute("x-placement",s),J(e,{position:n.positionFixed?"fixed":"absolute"}),n},gpuAcceleration:void 0}}},lt=function(){function t(e,n){var r=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};_(this,t),this.scheduleUpdate=function(){return requestAnimationFrame(r.update)},this.update=o(this.update.bind(this)),this.options=O({},t.Defaults,i),this.state={isDestroyed:!1,isCreated:!1,scrollParents:[]},this.reference=e&&e.jquery?e[0]:e,this.popper=n&&n.jquery?n[0]:n,this.options.modifiers={},Object.keys(O({},t.Defaults.modifiers,i.modifiers)).forEach((function(e){r.options.modifiers[e]=O({},t.Defaults.modifiers[e]||{},i.modifiers?i.modifiers[e]:{})})),this.modifiers=Object.keys(this.options.modifiers).map((function(t){return O({name:t},r.options.modifiers[t])})).sort((function(t,e){return t.order-e.order})),this.modifiers.forEach((function(t){t.enabled&&s(t.onLoad)&&t.onLoad(r.reference,r.popper,r.options,t,r.state)})),this.update();var a=this.options.eventsEnabled;a&&this.enableEventListeners(),this.state.eventsEnabled=a}return C(t,[{key:"update",value:function(){return F.call(this)}},{key:"destroy",value:function(){return W.call(this)}},{key:"enableEventListeners",value:function(){return q.call(this)}},{key:"disableEventListeners",value:function(){return G.call(this)}}]),t}();lt.Utils=("undefined"!=typeof window?window:n.g).PopperUtils,lt.placements=tt,lt.Defaults=at;const ct=lt,pt={props:{placement:{type:String,default:"bottom-end"},boundary:{type:String,default:"scrollParent"},autoClose:{type:Boolean,default:!0}},data:function(){return{show:!1}},watch:{show:function(t){var e=this;t?this.$nextTick((function(){e.popper=new ct(e.$el,e.$refs.dropdown,{placement:e.placement,modifiers:{preventOverflow:{boundariesElement:e.boundary}}})})):this.popper&&setTimeout((function(){return e.popper.destroy()}),100)}},mounted:function(){var t=this;document.addEventListener("keydown",(function(e){27===e.keyCode&&(t.show=!1)}))}};const ut=(0,n(1900).Z)(pt,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("button",{attrs:{type:"button"},on:{click:function(e){t.show=!0}}},[t._t("default"),t._v(" "),t.show?n("portal",{attrs:{to:"dropdown"}},[n("div",[n("div",{staticStyle:{position:"fixed",top:"0",right:"0",left:"0",bottom:"0","z-index":"99998",background:"black",opacity:".2"},on:{click:function(e){t.show=!1}}}),t._v(" "),n("div",{ref:"dropdown",staticStyle:{position:"absolute","z-index":"99999"},on:{click:function(e){e.stopPropagation(),t.show=!t.autoClose}}},[t._t("dropdown")],2)])]):t._e()],2)}),[],!1,null,null,null).exports},5007:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});const r={props:{name:String}};const i=(0,n(1900).Z)(r,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return"apple"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",width:"100",height:"100",viewBox:"0 0 100 100"}},[n("g",{attrs:{"fill-rule":"nonzero"}},[n("path",{attrs:{d:"M46.173 19.967C49.927-1.838 19.797-.233 14.538.21c-.429.035-.648.4-.483.8 2.004 4.825 14.168 31.66 32.118 18.957zm13.18 1.636c1.269-.891 1.35-1.614.047-2.453l-2.657-1.71c-.94-.607-1.685-.606-2.532.129-5.094 4.42-7.336 9.18-8.211 15.24 1.597.682 3.55.79 5.265.328 1.298-4.283 3.64-8.412 8.088-11.534z"}}),n("path",{attrs:{d:"M88.588 67.75c9.65-27.532-13.697-45.537-35.453-32.322-1.84 1.118-4.601 1.118-6.441 0-21.757-13.215-45.105 4.79-35.454 32.321 5.302 15.123 17.06 39.95 37.295 29.995.772-.38 1.986-.38 2.758 0 20.235 9.955 31.991-14.872 37.295-29.995z"}})])]):"book"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("path",{attrs:{d:"M6 4H5a1 1 0 1 1 0-2h11V1a1 1 0 0 0-1-1H4a2 2 0 0 0-2 2v16c0 1.1.9 2 2 2h12a2 2 0 0 0 2-2V5a1 1 0 0 0-1-1h-7v8l-2-2-2 2V4z"}})]):"cheveron-down"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("path",{attrs:{d:"M9.293 12.95l.707.707L15.657 8l-1.414-1.414L10 10.828 5.757 6.586 4.343 8z"}})]):"cheveron-right"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("polygon",{attrs:{points:"12.95 10.707 13.657 10 8 4.343 6.586 5.757 10.828 10 6.586 14.243 8 15.657 12.95 10.707"}})]):"dashboard"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("path",{attrs:{d:"M10 20a10 10 0 1 1 0-20 10 10 0 0 1 0 20zm-5.6-4.29a9.95 9.95 0 0 1 11.2 0 8 8 0 1 0-11.2 0zm6.12-7.64l3.02-3.02 1.41 1.41-3.02 3.02a2 2 0 1 1-1.41-1.41z"}})]):"location"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("path",{attrs:{d:"M10 20S3 10.87 3 7a7 7 0 1 1 14 0c0 3.87-7 13-7 13zm0-11a2 2 0 1 0 0-4 2 2 0 0 0 0 4z"}})]):"office"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",width:"100",height:"100",viewBox:"0 0 100 100"}},[n("path",{attrs:{"fill-rule":"evenodd",d:"M7 0h86v100H57.108V88.418H42.892V100H7V0zm9 64h11v15H16V64zm57 0h11v15H73V64zm-19 0h11v15H54V64zm-19 0h11v15H35V64zM16 37h11v15H16V37zm57 0h11v15H73V37zm-19 0h11v15H54V37zm-19 0h11v15H35V37zM16 11h11v15H16V11zm57 0h11v15H73V11zm-19 0h11v15H54V11zm-19 0h11v15H35V11z"}})]):"printer"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("path",{attrs:{d:"M4 16H0V6h20v10h-4v4H4v-4zm2-4v6h8v-6H6zM4 0h12v5H4V0zM2 8v2h2V8H2zm4 0v2h2V8H6z"}})]):"shopping-cart"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("path",{attrs:{d:"M4 2h16l-3 9H4a1 1 0 1 0 0 2h13v2H4a3 3 0 0 1 0-6h.33L3 5 2 2H0V0h3a1 1 0 0 1 1 1v1zm1 18a2 2 0 1 1 0-4 2 2 0 0 1 0 4zm10 0a2 2 0 1 1 0-4 2 2 0 0 1 0 4z"}})]):"store-front"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("path",{attrs:{d:"M18 9.87V20H2V9.87a4.25 4.25 0 0 0 3-.38V14h10V9.5a4.26 4.26 0 0 0 3 .37zM3 0h4l-.67 6.03A3.43 3.43 0 0 1 3 9C1.34 9 .42 7.73.95 6.15L3 0zm5 0h4l.7 6.3c.17 1.5-.91 2.7-2.42 2.7h-.56A2.38 2.38 0 0 1 7.3 6.3L8 0zm5 0h4l2.05 6.15C19.58 7.73 18.65 9 17 9a3.42 3.42 0 0 1-3.33-2.97L13 0z"}})]):"trash"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("path",{attrs:{d:"M6 2l2-2h4l2 2h4v2H2V2h4zM3 6h14l-1 14H4L3 6zm5 2v10h1V8H8zm3 0v10h1V8h-1z"}})]):"users"===t.name?n("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("path",{attrs:{d:"M7 8a4 4 0 1 1 0-8 4 4 0 0 1 0 8zm0 1c2.15 0 4.2.4 6.1 1.09L12 16h-1.25L10 20H4l-.75-4H2L.9 10.09A17.93 17.93 0 0 1 7 9zm8.31.17c1.32.18 2.59.48 3.8.92L18 16h-1.25L16 20h-3.96l.37-2h1.25l1.65-8.83zM13 0a4 4 0 1 1-1.33 7.76 5.96 5.96 0 0 0 0-7.52C12.1.1 12.53 0 13 0z"}})]):t._e()}),[],!1,null,null,null).exports},9714:(t,e,n)=>{"use strict";n.d(e,{Z:()=>d});var r=n(5007),i=n(3354),o=n(381);const s={components:{Icon:r.Z},methods:{isUrl:function(){for(var t=this.$page.url.substr(1),e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return""===n[0]?""===t:n.filter((function(e){return t.startsWith(e)})).length}}};var a=n(1900);const l=(0,a.Z)(s,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("div",{staticClass:"mb-4"},[n("inertia-link",{staticClass:"flex items-center group py-3",attrs:{href:t.route("dashboard")}},[n("icon",{staticClass:"w-4 h-4 mr-2",class:t.isUrl("")?"fill-white":"fill-indigo-400 group-hover:fill-white",attrs:{name:"dashboard"}}),t._v(" "),n("div",{class:t.isUrl("")?"text-white":"text-indigo-300 group-hover:text-white"},[t._v("Dashboard")])],1)],1),t._v(" "),n("div",{staticClass:"mb-4"},[n("inertia-link",{staticClass:"flex items-center group py-3",attrs:{href:t.route("tokens")}},[n("icon",{staticClass:"w-4 h-4 mr-2",class:t.isUrl("tokens")?"fill-white":"fill-indigo-400 group-hover:fill-white",attrs:{name:"office"}}),t._v(" "),n("div",{class:t.isUrl("tokens")?"text-white":"text-indigo-300 group-hover:text-white"},[t._v("Tokens")])],1)],1),t._v(" "),n("div",{staticClass:"mb-4"},[n("inertia-link",{staticClass:"flex items-center group py-3",attrs:{href:t.route("organizations")}},[n("icon",{staticClass:"w-4 h-4 mr-2",class:t.isUrl("organizations")?"fill-white":"fill-indigo-400 group-hover:fill-white",attrs:{name:"office"}}),t._v(" "),n("div",{class:t.isUrl("organizations")?"text-white":"text-indigo-300 group-hover:text-white"},[t._v("Organizations")])],1)],1),t._v(" "),n("div",{staticClass:"mb-4"},[n("inertia-link",{staticClass:"flex items-center group py-3",attrs:{href:t.route("contacts")}},[n("icon",{staticClass:"w-4 h-4 mr-2",class:t.isUrl("contacts")?"fill-white":"fill-indigo-400 group-hover:fill-white",attrs:{name:"users"}}),t._v(" "),n("div",{class:t.isUrl("contacts")?"text-white":"text-indigo-300 group-hover:text-white"},[t._v("Contacts")])],1)],1),t._v(" "),n("div",{staticClass:"mb-4"},[n("inertia-link",{staticClass:"flex items-center group py-3",attrs:{href:t.route("reports")}},[n("icon",{staticClass:"w-4 h-4 mr-2",class:t.isUrl("reports")?"fill-white":"fill-indigo-400 group-hover:fill-white",attrs:{name:"printer"}}),t._v(" "),n("div",{class:t.isUrl("reports")?"text-white":"text-indigo-300 group-hover:text-white"},[t._v("Reports")])],1)],1)])}),[],!1,null,null,null).exports;const c={data:function(){return{show:!0}},watch:{"$page.props.flash":{handler:function(){this.show=!0},deep:!0}}};const p=(0,a.Z)(c,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[t.$page.props.flash.success&&t.show?n("div",{staticClass:"mb-8 flex items-center justify-between bg-green-500 rounded max-w-3xl"},[n("div",{staticClass:"flex items-center"},[n("svg",{staticClass:"ml-4 mr-2 flex-shrink-0 w-4 h-4 fill-white",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("polygon",{attrs:{points:"0 11 2 9 7 14 18 3 20 5 7 18"}})]),t._v(" "),n("div",{staticClass:"py-4 text-white text-sm font-medium"},[t._v(t._s(t.$page.props.flash.success))])]),t._v(" "),n("button",{staticClass:"group mr-2 p-2",attrs:{type:"button"},on:{click:function(e){t.show=!1}}},[n("svg",{staticClass:"block w-2 h-2 fill-green-800 group-hover:fill-white",attrs:{xmlns:"http://www.w3.org/2000/svg",width:"235.908",height:"235.908",viewBox:"278.046 126.846 235.908 235.908"}},[n("path",{attrs:{d:"M506.784 134.017c-9.56-9.56-25.06-9.56-34.62 0L396 210.18l-76.164-76.164c-9.56-9.56-25.06-9.56-34.62 0-9.56 9.56-9.56 25.06 0 34.62L361.38 244.8l-76.164 76.165c-9.56 9.56-9.56 25.06 0 34.62 9.56 9.56 25.06 9.56 34.62 0L396 279.42l76.164 76.165c9.56 9.56 25.06 9.56 34.62 0 9.56-9.56 9.56-25.06 0-34.62L430.62 244.8l76.164-76.163c9.56-9.56 9.56-25.06 0-34.62z"}})])])]):t._e(),t._v(" "),(t.$page.props.flash.error||Object.keys(t.$page.props.errors).length>0)&&t.show?n("div",{staticClass:"mb-8 flex items-center justify-between bg-red-400 rounded max-w-3xl"},[n("div",{staticClass:"flex items-center"},[n("svg",{staticClass:"ml-4 mr-2 flex-shrink-0 w-4 h-4 fill-white",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("path",{attrs:{d:"M2.93 17.07A10 10 0 1 1 17.07 2.93 10 10 0 0 1 2.93 17.07zm1.41-1.41A8 8 0 1 0 15.66 4.34 8 8 0 0 0 4.34 15.66zm9.9-8.49L11.41 10l2.83 2.83-1.41 1.41L10 11.41l-2.83 2.83-1.41-1.41L8.59 10 5.76 7.17l1.41-1.41L10 8.59l2.83-2.83 1.41 1.41z"}})]),t._v(" "),t.$page.props.flash.error?n("div",{staticClass:"py-4 text-white text-sm font-medium"},[t._v(t._s(t.$page.props.flash.error))]):n("div",{staticClass:"py-4 text-white text-sm font-medium"},[1===Object.keys(t.$page.props.errors).length?n("span",[t._v("There is one form error.")]):n("span",[t._v("There are "+t._s(Object.keys(t.$page.props.errors).length)+" form errors.")])])]),t._v(" "),n("button",{staticClass:"group mr-2 p-2",attrs:{type:"button"},on:{click:function(e){t.show=!1}}},[n("svg",{staticClass:"block w-2 h-2 fill-red-800 group-hover:fill-white",attrs:{xmlns:"http://www.w3.org/2000/svg",width:"235.908",height:"235.908",viewBox:"278.046 126.846 235.908 235.908"}},[n("path",{attrs:{d:"M506.784 134.017c-9.56-9.56-25.06-9.56-34.62 0L396 210.18l-76.164-76.164c-9.56-9.56-25.06-9.56-34.62 0-9.56 9.56-9.56 25.06 0 34.62L361.38 244.8l-76.164 76.165c-9.56 9.56-9.56 25.06 0 34.62 9.56 9.56 25.06 9.56 34.62 0L396 279.42l76.164 76.165c9.56 9.56 25.06 9.56 34.62 0 9.56-9.56 9.56-25.06 0-34.62L430.62 244.8l76.164-76.163c9.56-9.56 9.56-25.06 0-34.62z"}})])])]):t._e()])}),[],!1,null,null,null).exports,u={components:{Dropdown:o.Z,FlashMessages:p,Icon:r.Z,Logo:i.Z,MainMenu:l}};const d=(0,a.Z)(u,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[n("portal-target",{attrs:{name:"dropdown",slim:""}}),t._v(" "),n("div",{staticClass:"md:flex md:flex-col"},[n("div",{staticClass:"md:h-screen md:flex md:flex-col"},[n("div",{staticClass:"md:flex md:flex-shrink-0"},[n("div",{staticClass:"bg-indigo-900 md:flex-shrink-0 md:w-56 px-6 py-4 flex items-center justify-between md:justify-center"},[n("inertia-link",{staticClass:"mt-1",attrs:{href:"/"}},[n("logo",{staticClass:"fill-white",attrs:{width:"120",height:"28"}})],1),t._v(" "),n("dropdown",{staticClass:"md:hidden",attrs:{placement:"bottom-end"}},[n("svg",{staticClass:"fill-white w-6 h-6",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"}},[n("path",{attrs:{d:"M0 3h20v2H0V3zm0 6h20v2H0V9zm0 6h20v2H0v-2z"}})]),t._v(" "),n("div",{staticClass:"mt-2 px-8 py-4 shadow-lg bg-indigo-800 rounded",attrs:{slot:"dropdown"},slot:"dropdown"},[n("main-menu")],1)])],1),t._v(" "),n("div",{staticClass:"bg-white border-b w-full p-4 md:py-0 md:px-12 text-sm md:text-md flex justify-between items-center"},[n("div",{staticClass:"mt-1 mr-4"},[t._v(t._s(t.$page.props.auth.user.account.name))]),t._v(" "),n("dropdown",{staticClass:"mt-1",attrs:{placement:"bottom-end"}},[n("div",{staticClass:"flex items-center cursor-pointer select-none group"},[n("div",{staticClass:"text-gray-700 group-hover:text-indigo-600 focus:text-indigo-600 mr-1 whitespace-nowrap"},[n("span",[t._v(t._s(t.$page.props.auth.user.first_name))]),t._v(" "),n("span",{staticClass:"hidden md:inline"},[t._v(t._s(t.$page.props.auth.user.last_name))])]),t._v(" "),n("icon",{staticClass:"w-5 h-5 group-hover:fill-indigo-600 fill-gray-700 focus:fill-indigo-600",attrs:{name:"cheveron-down"}})],1),t._v(" "),n("div",{staticClass:"mt-2 py-2 shadow-xl bg-white rounded text-sm",attrs:{slot:"dropdown"},slot:"dropdown"},[n("inertia-link",{staticClass:"block px-6 py-2 hover:bg-indigo-500 hover:text-white",attrs:{href:t.route("users.edit",t.$page.props.auth.user.id)}},[t._v("My Profile")]),t._v(" "),n("inertia-link",{staticClass:"block px-6 py-2 hover:bg-indigo-500 hover:text-white",attrs:{href:t.route("users")}},[t._v("Manage Users")]),t._v(" "),n("inertia-link",{staticClass:"block px-6 py-2 hover:bg-indigo-500 hover:text-white w-full text-left",attrs:{href:t.route("logout"),method:"post",as:"button"}},[t._v("Logout")])],1)])],1)]),t._v(" "),n("div",{staticClass:"md:flex md:flex-grow md:overflow-hidden"},[n("main-menu",{staticClass:"hidden md:block bg-indigo-800 flex-shrink-0 w-56 p-12 overflow-y-auto"}),t._v(" "),n("div",{staticClass:"md:flex-1 px-4 py-8 md:p-12 md:overflow-y-auto",attrs:{"scroll-region":""}},[n("flash-messages"),t._v(" "),t._t("default")],2)],1)])])],1)}),[],!1,null,null,null).exports},3354:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=(0,n(1900).Z)({},(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("svg",{attrs:{viewBox:"0 0 1185 266",xmlns:"http://www.w3.org/2000/svg"}},[n("path",{attrs:{d:"M77.463 265c-19.497 0-35.318-15.405-35.318-34.39v-22.054C17.987 202.676 0 181.326 0 155.948V55.206C0 25.291 24.946 1 55.668 1h154.664C241.054 1 266 25.29 266 55.206v100.806c0 29.916-24.946 54.206-55.668 54.206H145.67c-2.823 0-5.383 1.407-6.827 3.58-10.7 17.067-24.158 31.897-39.98 43.915-6.236 4.794-13.654 7.287-21.4 7.287zM55.701 27.336c-15.771 0-28.65 12.465-28.65 27.87v100.806c0 15.342 12.813 27.87 28.65 27.87 7.49 0 13.536 5.881 13.536 13.168v33.624c0 4.922 4.272 7.99 8.214 7.99 1.709 0 3.286-.575 4.732-1.662 13.273-10.1 24.576-22.565 33.578-36.947 6.309-10.036 17.743-16.237 29.965-16.237h64.727c15.77 0 28.65-12.464 28.65-27.87V55.206c0-15.341-12.814-27.87-28.65-27.87H55.7z"}}),t._v(" "),n("path",{attrs:{d:"M395.752 2.4c37.152 0 65.088 27.936 65.088 64.8 0 36.576-27.936 64.8-65.088 64.8h-46.368v72H322.6V2.4h73.152zm0 104.544c22.176 0 38.592-16.992 38.592-39.744 0-23.04-16.416-39.744-38.592-39.744h-46.368v79.488h46.368zM502.6 33.792c-9.504 0-16.992-7.488-16.992-16.704 0-9.216 7.488-16.992 16.992-16.992 9.216 0 16.704 7.776 16.704 16.992 0 9.216-7.488 16.704-16.704 16.704zM489.928 204V60h25.056v144h-25.056zM625 56.256c33.696 0 55.872 22.464 55.872 59.328V204h-25.056v-86.976c0-23.616-13.536-36.864-35.712-36.864-23.04 0-41.76 13.536-41.76 47.52V204h-25.056V60h25.056v20.736C589 63.744 604.84 56.256 625 56.256zM835.24 60h24.768v137.952c0 44.928-36 67.392-73.44 67.392-32.256 0-56.448-12.384-68.256-35.136l21.888-12.384c6.624 13.536 18.72 24.192 46.944 24.192 29.952 0 48.096-16.992 48.096-44.064v-20.448c-11.52 17.568-29.952 28.8-54.144 28.8-40.896 0-73.44-33.12-73.44-75.168 0-41.76 32.544-74.88 73.44-74.88 24.192 0 42.624 10.944 54.144 28.512V60zm-51.264 122.4c29.088 0 51.264-22.176 51.264-51.264 0-28.8-22.176-50.976-51.264-50.976-29.088 0-51.264 22.176-51.264 50.976 0 29.088 22.176 51.264 51.264 51.264zM946.8 205.08c-28.21 0-45.63-20.8-41.08-48.88 4.42-27.17 26.91-46.28 53.56-46.28 19.37 0 31.59 9.36 38.35 22.36l-23.79 12.61c-3.25-5.85-9.1-9.49-16.9-9.49-12.35 0-23.14 9.23-25.35 22.1-2.08 11.83 4.29 22.1 17.16 22.1 8.06 0 13.91-4.03 18.59-10.14l21.58 13.65c-9.36 13.78-24.44 21.97-42.12 21.97zm126.36-59.93c-1.95 11.18-8.58 19.5-18.2 24.44l11.7 33.28h-26l-9.36-28.6h-8.32l-5.07 28.6h-26l16.12-91h36.4c18.33 0 32.24 13.65 28.73 33.28zm-43.42-9.36l-2.99 16.9h10.66c5.07.13 8.84-2.99 9.75-8.32.91-5.33-1.82-8.58-7.02-8.58h-10.4zM1184.05 112l-15.99 91h-26l7.67-43.81-25.48 33.54h-2.34l-14.82-35.23-7.93 45.5h-26l15.99-91h26l13.65 37.31 27.95-37.31h27.3z"}})])}),[],!1,null,null,null).exports},3669:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});const r={inheritAttrs:!1,props:{id:{type:String,default:function(){return"select-input-".concat(this._uid)}},value:[String,Number,Boolean],label:String,error:String},data:function(){return{selected:this.value}},watch:{selected:function(t){this.$emit("input",t)}},methods:{focus:function(){this.$refs.input.focus()},select:function(){this.$refs.input.select()}}};const i=(0,n(1900).Z)(r,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[t.label?n("label",{staticClass:"form-label",attrs:{for:t.id}},[t._v(t._s(t.label)+":")]):t._e(),t._v(" "),n("select",t._b({directives:[{name:"model",rawName:"v-model",value:t.selected,expression:"selected"}],ref:"input",staticClass:"form-select",class:{error:t.error},attrs:{id:t.id},on:{change:function(e){var n=Array.prototype.filter.call(e.target.options,(function(t){return t.selected})).map((function(t){return"_value"in t?t._value:t.value}));t.selected=e.target.multiple?n:n[0]}}},"select",t.$attrs,!1),[t._t("default")],2),t._v(" "),t.error?n("div",{staticClass:"form-error"},[t._v(t._s(t.error))]):t._e()])}),[],!1,null,null,null).exports},6119:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});const r={inheritAttrs:!1,props:{id:{type:String,default:function(){return"text-input-".concat(this._uid)}},type:{type:String,default:"text"},value:String,label:String,error:String,readonly:Boolean},methods:{focus:function(){this.$refs.input.focus()},select:function(){this.$refs.input.select()},setSelectionRange:function(t,e){this.$refs.input.setSelectionRange(t,e)}}};const i=(0,n(1900).Z)(r,(function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",[t.label?n("label",{staticClass:"form-label",attrs:{for:t.id}},[t._v(t._s(t.label)+":")]):t._e(),t._v(" "),n("input",t._b({ref:"input",staticClass:"form-input",class:{error:t.error},attrs:{id:t.id,readonly:t.readonly,type:t.type},domProps:{value:t.value},on:{input:function(e){return t.$emit("input",e.target.value)}}},"input",t.$attrs,!1)),t._v(" "),t.error?n("div",{staticClass:"form-error"},[t._v(t._s(t.error))]):t._e()])}),[],!1,null,null,null).exports},1900:(t,e,n)=>{"use strict";function r(t,e,n,r,i,o,s,a){var l,c="function"==typeof t?t.options:t;if(e&&(c.render=e,c.staticRenderFns=n,c._compiled=!0),r&&(c.functional=!0),o&&(c._scopeId="data-v-"+o),s?(l=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),i&&i.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(s)},c._ssrRegister=l):i&&(l=a?function(){i.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:i),l)if(c.functional){c._injectStyles=l;var p=c.render;c.render=function(t,e){return l.call(e),p(t,e)}}else{var u=c.beforeCreate;c.beforeCreate=u?[].concat(u,l):[l]}return{exports:t,options:c}}n.d(e,{Z:()=>r})}}]);