2025-03-22 10:19:15 +00:00

1 line
754 KiB
JavaScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

(self.webpackChunklaravel_nova=self.webpackChunklaravel_nova||[]).push([[895],{12327:(e,t,r)=>{"use strict";var o=r(15542),i=r(50436),l=r(94335);function a(){const e=l.A.create();return e.defaults.headers.common["X-Requested-With"]="XMLHttpRequest",e.defaults.headers.common["X-CSRF-TOKEN"]=document.head.querySelector('meta[name="csrf-token"]').content,e.interceptors.response.use((e=>e),(e=>{if(l.A.isCancel(e))return Promise.reject(e);const t=e.response,{status:r,data:{redirect:o}}=t;if(r>=500&&Nova.$emit("error",e.response.data.message),401===r){if(null!=o)return void(location.href=o);Nova.redirectToLogin()}return 403===r&&Nova.visit("/403"),419===r&&Nova.$emit("token-expired"),Promise.reject(e)})),e}var n=r(15237),s=r.n(n);r(47216),r(16792),r(98e3),r(10386),r(13684),r(17246),r(20496),r(12082),r(48460),r(40576),r(73012),r(83838),r(71275),r(29532),r(11956),r(12520);var c=r(59977);var d=r(73333),u=r(13152),p=r.n(u);function h(e){return e&&(e=e.replace("_","-"),Object.values(p()).forEach((t=>{let r=t.languageTag;e!==r&&e!==r.substr(0,2)||d.A.registerLanguage(t)})),d.A.setLanguage(e)),d.A.setDefaults({thousandSeparated:!0}),d.A}var m=r(83488),f=r.n(m),v=r(71086),g=r.n(v);var y=r(29726),b=(r(403),r(84058)),k=r.n(b),w=r(55808),C=r.n(w);const x={class:"text-2xl"},N={class:"text-lg leading-normal"};const B={class:"flex justify-center h-screen"},S=["dusk"],V={class:"flex flex-col md:flex-row justify-center items-center space-y-4 md:space-y-0 md:space-x-20",role:"alert"},R={class:"md:w-[20rem] md:shrink-0 space-y-2 md:space-y-4"},E=Object.assign({name:"ErrorLayout"},{__name:"ErrorLayout",props:{status:{type:String,default:"403"}},setup:e=>(t,r)=>{const o=(0,y.resolveComponent)("ErrorPageIcon"),i=(0,y.resolveComponent)("Link");return(0,y.openBlock)(),(0,y.createElementBlock)("div",B,[(0,y.createElementVNode)("div",{class:"z-50 flex items-center justify-center p-6",dusk:`${e.status}-error-page`},[(0,y.createElementVNode)("div",V,[(0,y.createVNode)(o,{class:"shrink-0 md:w-[20rem]"}),(0,y.createElementVNode)("div",R,[(0,y.renderSlot)(t.$slots,"default"),(0,y.createVNode)(i,{href:t.$url("/"),class:"inline-flex items-center focus:outline-none focus:ring rounded border-2 border-primary-300 dark:border-gray-500 hover:border-primary-500 active:border-primary-400 dark:hover:border-gray-400 dark:active:border-gray-300 bg-white dark:bg-transparent text-primary-500 dark:text-gray-400 px-3 py-2 h-9 font-bold tracking-wide uppercase",tabindex:"0",replace:""},{default:(0,y.withCtx)((()=>[(0,y.createTextVNode)((0,y.toDisplayString)(t.__("Go Home")),1)])),_:1},8,["href"])])])],8,S)])}});var _=r(66262);const O=(0,_.A)(E,[["__file","ErrorLayout.vue"]]),F={components:{ErrorLayout:O}},D=(0,_.A)(F,[["render",function(e,t,r,o,i,l){const a=(0,y.resolveComponent)("Head"),n=(0,y.resolveComponent)("ErrorLayout");return(0,y.openBlock)(),(0,y.createBlock)(n,{status:"404"},{default:(0,y.withCtx)((()=>[(0,y.createVNode)(a,{title:"Page Not Found"}),t[0]||(t[0]=(0,y.createElementVNode)("h1",{class:"text-[5rem] md:text-[4rem] font-normal leading-none"},"404",-1)),(0,y.createElementVNode)("p",x,(0,y.toDisplayString)(e.__("Whoops"))+"…",1),(0,y.createElementVNode)("p",N,(0,y.toDisplayString)(e.__("We're lost in space. The page you were trying to view does not exist.")),1)])),_:1})}],["__file","CustomError404.vue"]]),A={class:"text-2xl"},P={class:"text-lg leading-normal"};const T={components:{ErrorLayout:O}},I=(0,_.A)(T,[["render",function(e,t,r,o,i,l){const a=(0,y.resolveComponent)("Head"),n=(0,y.resolveComponent)("ErrorLayout");return(0,y.openBlock)(),(0,y.createBlock)(n,{status:"403"},{default:(0,y.withCtx)((()=>[(0,y.createVNode)(a,{title:"Forbidden"}),t[0]||(t[0]=(0,y.createElementVNode)("h1",{class:"text-[5rem] md:text-[4rem] font-normal leading-none"},"403",-1)),(0,y.createElementVNode)("p",A,(0,y.toDisplayString)(e.__("Hold Up!")),1),(0,y.createElementVNode)("p",P,(0,y.toDisplayString)(e.__("The government won't let us show you what's behind these doors"))+"… ",1)])),_:1})}],["__file","CustomError403.vue"]]),M={class:"text-[5rem] md:text-[4rem] font-normal leading-none"},j={class:"text-2xl"},$={class:"text-lg leading-normal"};const z={components:{ErrorLayout:O}},L=(0,_.A)(z,[["render",function(e,t,r,o,i,l){const a=(0,y.resolveComponent)("Head"),n=(0,y.resolveComponent)("ErrorLayout");return(0,y.openBlock)(),(0,y.createBlock)(n,null,{default:(0,y.withCtx)((()=>[(0,y.createVNode)(a,{title:"Error"}),(0,y.createElementVNode)("h1",M,(0,y.toDisplayString)(e.__(":-(")),1),(0,y.createElementVNode)("p",j,(0,y.toDisplayString)(e.__("Whoops"))+"…",1),(0,y.createElementVNode)("p",$,(0,y.toDisplayString)(e.__("Nova experienced an unrecoverable error.")),1)])),_:1})}],["__file","CustomAppError.vue"]]),U=["innerHTML"],q=["aria-label","aria-expanded"],H={class:"flex gap-2 mb-6"},K={key:1,class:"inline-flex items-center gap-2 ml-auto"};var W=r(53110),Q=r(35229),G=r(30043),Z=r(66278);function J(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function Y(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?J(Object(r),!0).forEach((function(t){X(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):J(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function X(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const ee={name:"ResourceIndex",mixins:[Q.pJ,Q.Tu,Q.k6,Q.Nw,Q.dn,Q.vS,Q.Kx,Q.Ye,Q.XJ,Q.IJ],props:{shouldOverrideMeta:{type:Boolean,default:!1},shouldEnableShortcut:{type:Boolean,default:!1}},data:()=>({lenses:[],sortable:!0,actionCanceller:null}),async created(){this.resourceInformation&&(!0===this.shouldEnableShortcut&&(Nova.addShortcut("c",this.handleKeydown),Nova.addShortcut("mod+a",this.toggleSelectAll),Nova.addShortcut("mod+shift+a",this.toggleSelectAllMatching)),this.getLenses(),Nova.$on("refresh-resources",this.getResources),Nova.$on("resources-detached",this.getAuthorizationToRelate),null!==this.actionCanceller&&this.actionCanceller())},beforeUnmount(){this.shouldEnableShortcut&&(Nova.disableShortcut("c"),Nova.disableShortcut("mod+a"),Nova.disableShortcut("mod+shift+a")),Nova.$off("refresh-resources",this.getResources),Nova.$off("resources-detached",this.getAuthorizationToRelate),null!==this.actionCanceller&&this.actionCanceller()},methods:Y(Y({},(0,Z.i0)(["fetchPolicies"])),{},{handleKeydown(e){this.authorizedToCreate&&"INPUT"!==e.target.tagName&&"TEXTAREA"!==e.target.tagName&&"true"!==e.target.contentEditable&&Nova.visit(`/resources/${this.resourceName}/new`)},getResources(){this.shouldBeCollapsed?this.loading=!1:(this.loading=!0,this.resourceResponseError=null,this.$nextTick((()=>(this.clearResourceSelections(),(0,G.minimum)(Nova.request().get("/nova-api/"+this.resourceName,{params:this.resourceRequestQueryString,cancelToken:new W.qm((e=>{this.canceller=e}))}),300).then((({data:e})=>{this.resources=[],this.resourceResponse=e,this.resources=e.resources,this.softDeletes=e.softDeletes,this.perPage=e.per_page,this.sortable=e.sortable,this.handleResourcesLoaded()})).catch((e=>{if(!(0,W.FZ)(e))throw this.loading=!1,this.resourceResponseError=e,e}))))))},getAuthorizationToRelate(){if(!this.shouldBeCollapsed&&(this.authorizedToCreate||"belongsToMany"===this.relationshipType||"morphToMany"===this.relationshipType))return this.viaResource?Nova.request().get("/nova-api/"+this.resourceName+"/relate-authorization?viaResource="+this.viaResource+"&viaResourceId="+this.viaResourceId+"&viaRelationship="+this.viaRelationship+"&relationshipType="+this.relationshipType).then((e=>{this.authorizedToRelate=e.data.authorized})):this.authorizedToRelate=!0},getLenses(){if(this.lenses=[],!this.viaResource)return Nova.request().get("/nova-api/"+this.resourceName+"/lenses").then((e=>{this.lenses=e.data}))},getActions(){if(null!==this.actionCanceller&&this.actionCanceller(),this.actions=[],this.pivotActions=null,!this.shouldBeCollapsed)return Nova.request().get(`/nova-api/${this.resourceName}/actions`,{params:{viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,relationshipType:this.relationshipType,display:"index",resources:this.selectAllMatchingChecked?"all":this.selectedResourceIds,pivots:this.selectAllMatchingChecked?null:this.selectedPivotIds},cancelToken:new W.qm((e=>{this.actionCanceller=e}))}).then((e=>{this.actions=e.data.actions,this.pivotActions=e.data.pivotActions,this.resourceHasSoleActions=e.data.counts.sole>0,this.resourceHasActions=e.data.counts.resource>0})).catch((e=>{if(!(0,W.FZ)(e))throw e}))},getAllMatchingResourceCount(){Nova.request().get("/nova-api/"+this.resourceName+"/count",{params:this.resourceRequestQueryString}).then((e=>{this.allMatchingResourceCount=e.data.count}))},loadMore(){return null===this.currentPageLoadMore&&(this.currentPageLoadMore=this.currentPage),this.currentPageLoadMore=this.currentPageLoadMore+1,(0,G.minimum)(Nova.request().get("/nova-api/"+this.resourceName,{params:Y(Y({},this.resourceRequestQueryString),{},{page:this.currentPageLoadMore})}),300).then((({data:e})=>{this.resourceResponse=e,this.resources=[...this.resources,...e.resources],null!==e.total?this.allMatchingResourceCount=e.total:this.getAllMatchingResourceCount(),Nova.$emit("resources-loaded",{resourceName:this.resourceName,mode:this.isRelation?"related":"index"})}))},async handleCollapsableChange(){this.loading=!0,this.toggleCollapse(),this.collapsed?this.loading=!1:(this.filterHasLoaded?await this.getResources():(await this.initializeFilters(null),this.hasFilters||await this.getResources()),await this.getAuthorizationToRelate(),await this.getActions(),this.restartPolling())}}),computed:{actionQueryString(){return{currentSearch:this.currentSearch,encodedFilters:this.encodedFilters,currentTrashed:this.currentTrashed,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship}},shouldBeCollapsed(){return this.collapsed&&null!=this.viaRelationship},collapsedByDefault(){return this.field?.collapsedByDefault??!1},cardsEndpoint(){return`/nova-api/${this.resourceName}/cards`},resourceRequestQueryString(){return{search:this.currentSearch,filters:this.encodedFilters,orderBy:this.currentOrderBy,orderByDirection:this.currentOrderByDirection,perPage:this.currentPerPage,trashed:this.currentTrashed,page:this.currentPage,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,viaResourceRelationship:this.viaResourceRelationship,relationshipType:this.relationshipType}},canShowDeleteMenu(){return Boolean(this.authorizedToDeleteSelectedResources||this.authorizedToForceDeleteSelectedResources||this.authorizedToRestoreSelectedResources||this.selectAllMatchingChecked)},headingTitle(){return this.initialLoading?"&nbsp;":this.isRelation&&this.field?this.field.name:null!==this.resourceResponse?this.resourceResponse.label:this.resourceInformation.label}}},te=(0,_.A)(ee,[["render",function(e,t,r,o,i,l){const a=(0,y.resolveComponent)("Head"),n=(0,y.resolveComponent)("Cards"),s=(0,y.resolveComponent)("CollapseButton"),c=(0,y.resolveComponent)("Heading"),d=(0,y.resolveComponent)("IndexSearchInput"),u=(0,y.resolveComponent)("ActionDropdown"),p=(0,y.resolveComponent)("CreateResourceButton"),h=(0,y.resolveComponent)("ResourceTableToolbar"),m=(0,y.resolveComponent)("IndexErrorDialog"),f=(0,y.resolveComponent)("IndexEmptyDialog"),v=(0,y.resolveComponent)("ResourceTable"),g=(0,y.resolveComponent)("ResourcePagination"),b=(0,y.resolveComponent)("LoadingView"),k=(0,y.resolveComponent)("Card");return(0,y.openBlock)(),(0,y.createBlock)(b,{loading:e.initialLoading,dusk:e.resourceName+"-index-component","data-relationship":e.viaRelationship},{default:(0,y.withCtx)((()=>[r.shouldOverrideMeta&&e.resourceInformation?((0,y.openBlock)(),(0,y.createBlock)(a,{key:0,title:e.__(`${e.resourceInformation.label}`)},null,8,["title"])):(0,y.createCommentVNode)("",!0),e.shouldShowCards?((0,y.openBlock)(),(0,y.createBlock)(n,{key:1,cards:e.cards,"resource-name":e.resourceName},null,8,["cards","resource-name"])):(0,y.createCommentVNode)("",!0),(0,y.createVNode)(c,{level:1,class:(0,y.normalizeClass)(["mb-3 flex items-center",{"mt-6":e.shouldShowCards&&e.cards.length>0}]),dusk:"index-heading"},{default:(0,y.withCtx)((()=>[(0,y.createElementVNode)("span",{innerHTML:l.headingTitle},null,8,U),!e.loading&&e.viaRelationship?((0,y.openBlock)(),(0,y.createElementBlock)("button",{key:0,onClick:t[0]||(t[0]=(...e)=>l.handleCollapsableChange&&l.handleCollapsableChange(...e)),class:"rounded border border-transparent h-6 w-6 ml-1 inline-flex items-center justify-center focus:outline-none focus:ring ring-primary-200","aria-label":e.__("Toggle Collapsed"),"aria-expanded":!1===l.shouldBeCollapsed?"true":"false"},[(0,y.createVNode)(s,{collapsed:l.shouldBeCollapsed},null,8,["collapsed"])],8,q)):(0,y.createCommentVNode)("",!0)])),_:1},8,["class"]),l.shouldBeCollapsed?(0,y.createCommentVNode)("",!0):((0,y.openBlock)(),(0,y.createElementBlock)(y.Fragment,{key:2},[(0,y.createElementVNode)("div",H,[e.resourceInformation&&e.resourceInformation.searchable?((0,y.openBlock)(),(0,y.createBlock)(d,{key:0,searchable:e.resourceInformation&&e.resourceInformation.searchable,modelValue:e.search,"onUpdate:modelValue":t[1]||(t[1]=t=>e.search=t)},null,8,["searchable","modelValue"])):(0,y.createCommentVNode)("",!0),e.availableStandaloneActions.length>0||e.authorizedToCreate||e.authorizedToRelate?((0,y.openBlock)(),(0,y.createElementBlock)("div",K,[e.availableStandaloneActions.length>0?((0,y.openBlock)(),(0,y.createBlock)(u,{key:0,onActionExecuted:e.handleActionExecuted,"resource-name":e.resourceName,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"relationship-type":e.relationshipType,actions:e.availableStandaloneActions,"selected-resources":e.selectedResourcesForActionSelector,"trigger-dusk-attribute":"index-standalone-action-dropdown"},null,8,["onActionExecuted","resource-name","via-resource","via-resource-id","via-relationship","relationship-type","actions","selected-resources"])):(0,y.createCommentVNode)("",!0),(0,y.createVNode)(p,{label:e.createButtonLabel,"singular-name":e.singularName,"resource-name":e.resourceName,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"relationship-type":e.relationshipType,"authorized-to-create":e.authorizedToCreate,"authorized-to-relate":e.authorizedToRelate,class:"shrink-0"},null,8,["label","singular-name","resource-name","via-resource","via-resource-id","via-relationship","relationship-type","authorized-to-create","authorized-to-relate"])])):(0,y.createCommentVNode)("",!0)]),(0,y.createVNode)(k,null,{default:(0,y.withCtx)((()=>[(0,y.createVNode)(h,{"action-query-string":l.actionQueryString,"all-matching-resource-count":e.allMatchingResourceCount,"authorized-to-delete-any-resources":e.authorizedToDeleteAnyResources,"authorized-to-delete-selected-resources":e.authorizedToDeleteSelectedResources,"authorized-to-force-delete-any-resources":e.authorizedToForceDeleteAnyResources,"authorized-to-force-delete-selected-resources":e.authorizedToForceDeleteSelectedResources,"authorized-to-restore-any-resources":e.authorizedToRestoreAnyResources,"authorized-to-restore-selected-resources":e.authorizedToRestoreSelectedResources,"available-actions":e.availableActions,"clear-selected-filters":e.clearSelectedFilters,"close-delete-modal":e.closeDeleteModal,"currently-polling":e.currentlyPolling,"current-page-count":e.resources.length,"delete-all-matching-resources":e.deleteAllMatchingResources,"delete-selected-resources":e.deleteSelectedResources,"filter-changed":e.filterChanged,"force-delete-all-matching-resources":e.forceDeleteAllMatchingResources,"force-delete-selected-resources":e.forceDeleteSelectedResources,"get-resources":l.getResources,"has-filters":e.hasFilters,"have-standalone-actions":e.haveStandaloneActions,lenses:e.lenses,loading:e.resourceResponse&&e.loading,"per-page-options":e.perPageOptions,"per-page":e.perPage,"pivot-actions":e.pivotActions,"pivot-name":e.pivotName,resources:e.resources,"resource-information":e.resourceInformation,"resource-name":e.resourceName,"restore-all-matching-resources":e.restoreAllMatchingResources,"restore-selected-resources":e.restoreSelectedResources,"select-all-matching-checked":e.selectAllMatchingResources,onDeselect:e.deselectAllResources,"selected-resources":e.selectedResources,"selected-resources-for-action-selector":e.selectedResourcesForActionSelector,"should-show-action-selector":e.shouldShowActionSelector,"should-show-checkboxes":e.shouldShowSelectAllCheckboxes,"should-show-delete-menu":e.shouldShowDeleteMenu,"should-show-polling-toggle":e.shouldShowPollingToggle,"soft-deletes":e.softDeletes,onStartPolling:e.startPolling,onStopPolling:e.stopPolling,"toggle-select-all-matching":e.toggleSelectAllMatching,"toggle-select-all":e.toggleSelectAll,"toggle-polling":e.togglePolling,"trashed-changed":e.trashedChanged,"trashed-parameter":e.trashedParameter,trashed:e.trashed,"update-per-page-changed":e.updatePerPageChanged,"via-many-to-many":e.viaManyToMany,"via-resource":e.viaResource},null,8,["action-query-string","all-matching-resource-count","authorized-to-delete-any-resources","authorized-to-delete-selected-resources","authorized-to-force-delete-any-resources","authorized-to-force-delete-selected-resources","authorized-to-restore-any-resources","authorized-to-restore-selected-resources","available-actions","clear-selected-filters","close-delete-modal","currently-polling","current-page-count","delete-all-matching-resources","delete-selected-resources","filter-changed","force-delete-all-matching-resources","force-delete-selected-resources","get-resources","has-filters","have-standalone-actions","lenses","loading","per-page-options","per-page","pivot-actions","pivot-name","resources","resource-information","resource-name","restore-all-matching-resources","restore-selected-resources","select-all-matching-checked","onDeselect","selected-resources","selected-resources-for-action-selector","should-show-action-selector","should-show-checkboxes","should-show-delete-menu","should-show-polling-toggle","soft-deletes","onStartPolling","onStopPolling","toggle-select-all-matching","toggle-select-all","toggle-polling","trashed-changed","trashed-parameter","trashed","update-per-page-changed","via-many-to-many","via-resource"]),(0,y.createVNode)(b,{loading:e.loading,variant:e.resourceResponse?"overlay":"default"},{default:(0,y.withCtx)((()=>[null!=e.resourceResponseError?((0,y.openBlock)(),(0,y.createBlock)(m,{key:0,resource:e.resourceInformation,onClick:l.getResources},null,8,["resource","onClick"])):((0,y.openBlock)(),(0,y.createElementBlock)(y.Fragment,{key:1},[e.loading||e.resources.length?(0,y.createCommentVNode)("",!0):((0,y.openBlock)(),(0,y.createBlock)(f,{key:0,"create-button-label":e.createButtonLabel,"singular-name":e.singularName,"resource-name":e.resourceName,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"relationship-type":e.relationshipType,"authorized-to-create":e.authorizedToCreate,"authorized-to-relate":e.authorizedToRelate},null,8,["create-button-label","singular-name","resource-name","via-resource","via-resource-id","via-relationship","relationship-type","authorized-to-create","authorized-to-relate"])),(0,y.createVNode)(v,{"authorized-to-relate":e.authorizedToRelate,"resource-name":e.resourceName,resources:e.resources,"singular-name":e.singularName,"selected-resources":e.selectedResources,"selected-resource-ids":e.selectedResourceIds,"actions-are-available":e.allActions.length>0,"should-show-checkboxes":e.shouldShowCheckboxes,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"relationship-type":e.relationshipType,"update-selection-status":e.updateSelectionStatus,sortable:e.sortable,onOrder:e.orderByField,onResetOrderBy:e.resetOrderBy,onDelete:e.deleteResources,onRestore:e.restoreResources,onActionExecuted:e.handleActionExecuted,ref:"resourceTable"},null,8,["authorized-to-relate","resource-name","resources","singular-name","selected-resources","selected-resource-ids","actions-are-available","should-show-checkboxes","via-resource","via-resource-id","via-relationship","relationship-type","update-selection-status","sortable","onOrder","onResetOrderBy","onDelete","onRestore","onActionExecuted"]),e.shouldShowPagination?((0,y.openBlock)(),(0,y.createBlock)(g,{key:1,"pagination-component":e.paginationComponent,"has-next-page":e.hasNextPage,"has-previous-page":e.hasPreviousPage,"load-more":l.loadMore,"select-page":e.selectPage,"total-pages":e.totalPages,"current-page":e.currentPage,"per-page":e.perPage,"resource-count-label":e.resourceCountLabel,"current-resource-count":e.currentResourceCount,"all-matching-resource-count":e.allMatchingResourceCount},null,8,["pagination-component","has-next-page","has-previous-page","load-more","select-page","total-pages","current-page","per-page","resource-count-label","current-resource-count","all-matching-resource-count"])):(0,y.createCommentVNode)("",!0)],64))])),_:1},8,["loading","variant"])])),_:1})],64))])),_:1},8,["loading","dusk","data-relationship"])}],["__file","Index.vue"]]),re={key:1},oe=["dusk"],ie={key:0,class:"md:flex items-center mb-3"},le={class:"flex flex-auto truncate items-center"},ae={class:"ml-auto flex items-center"};var ne=r(74640);function se(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function ce(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?se(Object(r),!0).forEach((function(t){de(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):se(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function de(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const ue={components:{Button:ne.Button},mixins:[Q.k6,Q.Ye],props:ce({shouldOverrideMeta:{type:Boolean,default:!1},showViewLink:{type:Boolean,default:!1},shouldEnableShortcut:{type:Boolean,default:!1},showActionDropdown:{type:Boolean,default:!0}},(0,Q.rr)(["resourceName","resourceId","viaResource","viaResourceId","viaRelationship","relationshipType"])),data:()=>({initialLoading:!0,loading:!0,title:null,resource:null,panels:[],actions:[],actionValidationErrors:new Q.I}),created(){if(Nova.missingResource(this.resourceName))return Nova.visit("/404");!0===this.shouldEnableShortcut&&Nova.addShortcut("e",this.handleKeydown)},beforeUnmount(){!0===this.shouldEnableShortcut&&Nova.disableShortcut("e")},mounted(){this.initializeComponent()},methods:ce(ce({},(0,Z.i0)(["startImpersonating"])),{},{handleResourceLoaded(){this.loading=!1,Nova.$emit("resource-loaded",{resourceName:this.resourceName,resourceId:this.resourceId.toString(),mode:"detail"})},handleKeydown(e){this.resource.authorizedToUpdate&&"INPUT"!=e.target.tagName&&"TEXTAREA"!=e.target.tagName&&"true"!=e.target.contentEditable&&Nova.visit(`/resources/${this.resourceName}/${this.resourceId}/edit`)},async initializeComponent(){await this.getResource(),await this.getActions(),this.initialLoading=!1},getResource(){return this.loading=!0,this.panels=null,this.resource=null,(0,G.minimum)(Nova.request().get("/nova-api/"+this.resourceName+"/"+this.resourceId,{params:{viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,relationshipType:this.relationshipType}})).then((({data:{title:e,panels:t,resource:r}})=>{this.title=e,this.panels=t,this.resource=r,this.handleResourceLoaded()})).catch((e=>{if(e.response.status>=500)Nova.$emit("error",e.response.data.message);else if(404===e.response.status&&this.initialLoading)Nova.visit("/404");else if(403!==e.response.status){if(401===e.response.status)return Nova.redirectToLogin();Nova.error(this.__("This resource no longer exists")),Nova.visit(`/resources/${this.resourceName}`)}else Nova.visit("/403")}))},async getActions(){this.actions=[];try{const e=await Nova.request().get("/nova-api/"+this.resourceName+"/actions",{params:{resourceId:this.resourceId,editing:!0,editMode:"create",display:"detail"}});this.actions=e.data?.actions}catch(e){Nova.error(this.__("Unable to load actions for this resource"))}},async actionExecuted(){await this.getResource(),await this.getActions()},resolveComponentName:e=>null==e.prefixComponent||e.prefixComponent?"detail-"+e.component:e.component}),computed:ce(ce({},(0,Z.L8)(["currentUser"])),{},{canBeImpersonated(){return this.currentUser.canImpersonate&&this.resource.authorizedToImpersonate},shouldShowActionDropdown(){return this.resource&&(this.actions.length>0||this.canModifyResource)&&this.showActionDropdown},canModifyResource(){return this.resource.authorizedToReplicate||this.canBeImpersonated||this.resource.authorizedToDelete&&!this.resource.softDeleted||this.resource.authorizedToRestore&&this.resource.softDeleted||this.resource.authorizedToForceDelete},isActionDetail(){return"action-events"===this.resourceName},cardsEndpoint(){return`/nova-api/${this.resourceName}/cards`},extraCardParams(){return{resourceId:this.resourceId}}})},pe=(0,_.A)(ue,[["render",function(e,t,r,o,i,l){const a=(0,y.resolveComponent)("Head"),n=(0,y.resolveComponent)("Cards"),s=(0,y.resolveComponent)("Heading"),c=(0,y.resolveComponent)("Badge"),d=(0,y.resolveComponent)("DetailActionDropdown"),u=(0,y.resolveComponent)("Button"),p=(0,y.resolveComponent)("Link"),h=(0,y.resolveComponent)("LoadingView"),m=(0,y.resolveDirective)("tooltip");return(0,y.openBlock)(),(0,y.createBlock)(h,{loading:e.initialLoading},{default:(0,y.withCtx)((()=>[r.shouldOverrideMeta&&e.resourceInformation&&e.title?((0,y.openBlock)(),(0,y.createBlock)(a,{key:0,title:e.__(":resource Details: :title",{resource:e.resourceInformation.singularLabel,title:e.title})},null,8,["title"])):(0,y.createCommentVNode)("",!0),e.shouldShowCards&&e.hasDetailOnlyCards?((0,y.openBlock)(),(0,y.createElementBlock)("div",re,[e.cards.length>0?((0,y.openBlock)(),(0,y.createBlock)(n,{key:0,cards:e.cards,"only-on-detail":!0,resource:e.resource,"resource-id":e.resourceId,"resource-name":e.resourceName},null,8,["cards","resource","resource-id","resource-name"])):(0,y.createCommentVNode)("",!0)])):(0,y.createCommentVNode)("",!0),(0,y.createElementVNode)("div",{class:(0,y.normalizeClass)({"mt-6":e.shouldShowCards&&e.hasDetailOnlyCards&&e.cards.length>0}),dusk:e.resourceName+"-detail-component"},[((0,y.openBlock)(!0),(0,y.createElementBlock)(y.Fragment,null,(0,y.renderList)(e.panels,(t=>((0,y.openBlock)(),(0,y.createBlock)((0,y.resolveDynamicComponent)(l.resolveComponentName(t)),{key:t.id,panel:t,resource:e.resource,"resource-id":e.resourceId,"resource-name":e.resourceName,class:(0,y.normalizeClass)({"mb-8":t.fields.length>0})},{default:(0,y.withCtx)((()=>[t.showToolbar?((0,y.openBlock)(),(0,y.createElementBlock)("div",ie,[(0,y.createElementVNode)("div",le,[(0,y.createVNode)(s,{level:1,textContent:(0,y.toDisplayString)(t.name),dusk:`${t.name}-detail-heading`},null,8,["textContent","dusk"]),e.resource.softDeleted?((0,y.openBlock)(),(0,y.createBlock)(c,{key:0,label:e.__("Soft Deleted"),class:"bg-red-100 text-red-500 dark:bg-red-400 dark:text-red-900 rounded px-2 py-0.5 ml-3"},null,8,["label"])):(0,y.createCommentVNode)("",!0)]),(0,y.createElementVNode)("div",ae,[l.shouldShowActionDropdown?((0,y.openBlock)(),(0,y.createBlock)(d,{key:0,resource:e.resource,actions:e.actions,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"resource-name":e.resourceName,class:"mt-1 md:mt-0 md:ml-2 md:mr-2",onActionExecuted:l.actionExecuted,onResourceDeleted:l.getResource,onResourceRestored:l.getResource},null,8,["resource","actions","via-resource","via-resource-id","via-relationship","resource-name","onActionExecuted","onResourceDeleted","onResourceRestored"])):(0,y.createCommentVNode)("",!0),r.showViewLink?(0,y.withDirectives)(((0,y.openBlock)(),(0,y.createBlock)(p,{key:1,href:e.$url(`/resources/${e.resourceName}/${e.resourceId}`),class:"rounded hover:bg-gray-200 dark:hover:bg-gray-800 focus:outline-none focus:ring",dusk:"view-resource-button",tabindex:"1"},{default:(0,y.withCtx)((()=>[(0,y.createVNode)(u,{as:"span",variant:"ghost",icon:"eye"})])),_:1},8,["href"])),[[m,{placement:"bottom",distance:10,skidding:0,content:e.__("View")}]]):(0,y.createCommentVNode)("",!0),e.resource.authorizedToUpdate?(0,y.withDirectives)(((0,y.openBlock)(),(0,y.createBlock)(p,{key:2,href:e.$url(`/resources/${e.resourceName}/${e.resourceId}/edit`),class:"rounded hover:bg-gray-200 dark:hover:bg-gray-800 focus:outline-none focus:ring",dusk:"edit-resource-button",tabindex:"1"},{default:(0,y.withCtx)((()=>[(0,y.createVNode)(u,{as:"span",variant:"ghost",icon:"pencil-square"})])),_:1},8,["href"])),[[m,{placement:"bottom",distance:10,skidding:0,content:e.__("Edit")}]]):(0,y.createCommentVNode)("",!0)])])):(0,y.createCommentVNode)("",!0)])),_:2},1032,["panel","resource","resource-id","resource-name","class"])))),128))],10,oe)])),_:1},8,["loading"])}],["__file","Detail.vue"]]),he=["data-form-unique-id"],me={key:0,dusk:"via-resource-field",class:"field-wrapper flex flex-col md:flex-row border-b border-gray-100 dark:border-gray-700"},fe={class:"w-1/5 px-8 py-6"},ve=["for"],ge={class:"py-6 px-8 w-1/2"},ye={class:"inline-block font-bold text-gray-500 pt-2"},be={class:"flex items-center"},ke={key:0,class:"flex items-center"},we={key:0,class:"mr-3"},Ce=["src"],xe={class:"flex items-center"},Ne={key:0,class:"flex-none mr-3"},Be=["src"],Se={class:"flex-auto"},Ve={key:0},Re={key:1},Ee={value:"",disabled:"",selected:""},_e={class:"flex flex-col md:flex-row md:items-center justify-center md:justify-end space-y-2 md:space-y-0 space-x-3"};var Oe=r(52191),Fe=r(15101),De=r.n(Fe);function Ae(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function Pe(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Ae(Object(r),!0).forEach((function(t){Te(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ae(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function Te(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const Ie={components:{Button:ne.Button},mixins:[Q.c_,Q.B5,Q.Bz,Q.zJ,Q.rd],props:{resourceName:{type:String,required:!0},resourceId:{required:!0},relatedResourceName:{type:String,required:!0},viaResource:{default:""},viaResourceId:{default:""},parentResource:{type:Object},viaRelationship:{default:""},polymorphic:{default:!1}},data:()=>({initialLoading:!0,loading:!0,submittedViaAttachAndAttachAnother:!1,submittedViaAttachResource:!1,field:null,softDeletes:!1,fields:[],selectedResourceId:null,relationModalOpen:!1,initializingWithExistingResource:!1}),created(){if(Nova.missingResource(this.resourceName))return Nova.visit("/404")},mounted(){this.initializeComponent()},methods:Pe(Pe({},(0,Z.i0)(["fetchPolicies"])),{},{initializeComponent(){this.softDeletes=!1,this.disableWithTrashed(),this.clearSelection(),this.getField(),this.getPivotFields(),this.resetErrors()},handlePivotFieldsLoaded(){this.loading=!1,Object.values(this.fields).forEach((e=>{e.fill=()=>""}))},getField(){this.field=null,Nova.request().get("/nova-api/"+this.resourceName+"/field/"+this.viaRelationship,{params:{relatable:!0}}).then((({data:e})=>{this.field=e,this.field.searchable?this.determineIfSoftDeletes():this.getAvailableResources(),this.initialLoading=!1}))},getPivotFields(){this.fields=[],this.loading=!0,Nova.request().get("/nova-api/"+this.resourceName+"/"+this.resourceId+"/creation-pivot-fields/"+this.relatedResourceName,{params:{editing:!0,editMode:"attach",viaRelationship:this.viaRelationship}}).then((({data:e})=>{this.fields=e,this.handlePivotFieldsLoaded()}))},getAvailableResources(e=""){return Nova.$progress.start(),Oe.A.fetchAvailableResources(this.resourceName,this.resourceId,this.relatedResourceName,{params:{search:e,current:this.selectedResourceId,first:this.initializingWithExistingResource,withTrashed:this.withTrashed,component:this.field.component,viaRelationship:this.viaRelationship}}).then((e=>{Nova.$progress.done(),this.isSearchable&&(this.initializingWithExistingResource=!1),this.availableResources=e.data.resources,this.withTrashed=e.data.withTrashed,this.softDeletes=e.data.softDeletes})).catch((e=>{Nova.$progress.done()}))},determineIfSoftDeletes(){Nova.request().get("/nova-api/"+this.relatedResourceName+"/soft-deletes").then((e=>{this.softDeletes=e.data.softDeletes}))},async attachResource(){this.submittedViaAttachResource=!0;try{await this.attachRequest(),this.submittedViaAttachResource=!1,await this.fetchPolicies(),Nova.success(this.__("The resource was attached!")),Nova.visit(`/resources/${this.resourceName}/${this.resourceId}`)}catch(e){window.scrollTo(0,0),this.submittedViaAttachResource=!1,this.handleOnCreateResponseError(e)}},async attachAndAttachAnother(){this.submittedViaAttachAndAttachAnother=!0;try{await this.attachRequest(),window.scrollTo(0,0),this.disableNavigateBackUsingHistory(),this.submittedViaAttachAndAttachAnother=!1,await this.fetchPolicies(),this.initializeComponent()}catch(e){this.submittedViaAttachAndAttachAnother=!1,this.handleOnCreateResponseError(e)}},cancelAttachingResource(){this.handleProceedingToPreviousPage(),this.proceedToPreviousPage(`/resources/${this.resourceName}/${this.resourceId}`)},attachRequest(){return Nova.request().post(this.attachmentEndpoint,this.attachmentFormData(),{params:{editing:!0,editMode:"attach"}})},attachmentFormData(){return De()(new FormData,(e=>{Object.values(this.fields).forEach((t=>{t.fill(e)})),this.selectedResourceId?e.append(this.relatedResourceName,this.selectedResourceId??""):e.append(this.relatedResourceName,""),e.append(this.relatedResourceName+"_trashed",this.withTrashed),e.append("viaRelationship",this.viaRelationship)}))},toggleWithTrashed(){this.withTrashed=!this.withTrashed,this.isSearchable||this.getAvailableResources()},onUpdateFormStatus(){},handleSetResource({id:e}){this.closeRelationModal(),this.selectedResourceId=e,this.initializingWithExistingResource=!0,this.getAvailableResources()},openRelationModal(){Nova.$emit("create-relation-modal-opened"),this.relationModalOpen=!0},closeRelationModal(){this.relationModalOpen=!1,Nova.$emit("create-relation-modal-closed")},clearResourceSelection(){this.clearSelection(),this.isSearchable||(this.initializingWithExistingResource=!1,this.getAvailableResources())},isSelectedResourceId(e){return null!=e&&e?.toString()===this.selectedResourceId?.toString()}}),computed:{attachmentEndpoint(){return this.polymorphic?"/nova-api/"+this.resourceName+"/"+this.resourceId+"/attach-morphed/"+this.relatedResourceName:"/nova-api/"+this.resourceName+"/"+this.resourceId+"/attach/"+this.relatedResourceName},relatedResourceLabel(){if(this.field)return this.field.singularLabel},isSearchable(){return this.field.searchable},isWorking(){return this.submittedViaAttachResource||this.submittedViaAttachAndAttachAnother},headingTitle(){return this.__("Attach :resource",{resource:this.relatedResourceLabel})},shouldShowTrashed(){return Boolean(this.softDeletes)&&!this.field.readonly&&this.field.displaysWithTrashed},authorizedToCreate(){return Nova.config("resources").find((e=>e.uriKey==this.field.resourceName))?.authorizedToCreate||!1},canShowNewRelationModal(){return this.field.showCreateRelationButton&&this.authorizedToCreate},selectedResource(){return this.availableResources.find((e=>this.isSelectedResourceId(e.value)))}}},Me=(0,_.A)(Ie,[["render",function(e,t,r,o,i,l){const a=(0,y.resolveComponent)("Head"),n=(0,y.resolveComponent)("Heading"),s=(0,y.resolveComponent)("SearchInput"),c=(0,y.resolveComponent)("SelectControl"),d=(0,y.resolveComponent)("Button"),u=(0,y.resolveComponent)("CreateRelationModal"),p=(0,y.resolveComponent)("TrashedCheckbox"),h=(0,y.resolveComponent)("DefaultField"),m=(0,y.resolveComponent)("LoadingView"),f=(0,y.resolveComponent)("Card");return(0,y.openBlock)(),(0,y.createBlock)(m,{loading:e.initialLoading},{default:(0,y.withCtx)((()=>[l.relatedResourceLabel?((0,y.openBlock)(),(0,y.createBlock)(a,{key:0,title:e.__("Attach :resource",{resource:l.relatedResourceLabel})},null,8,["title"])):(0,y.createCommentVNode)("",!0),(0,y.createVNode)(n,{class:"mb-3",textContent:(0,y.toDisplayString)(e.__("Attach :resource",{resource:l.relatedResourceLabel})),dusk:"attach-heading"},null,8,["textContent"]),e.field?((0,y.openBlock)(),(0,y.createElementBlock)("form",{key:1,onSubmit:t[2]||(t[2]=(0,y.withModifiers)(((...e)=>l.attachResource&&l.attachResource(...e)),["prevent"])),onChange:t[3]||(t[3]=(...e)=>l.onUpdateFormStatus&&l.onUpdateFormStatus(...e)),"data-form-unique-id":e.formUniqueId,autocomplete:"off"},[(0,y.createVNode)(f,{class:"mb-8"},{default:(0,y.withCtx)((()=>[r.parentResource?((0,y.openBlock)(),(0,y.createElementBlock)("div",me,[(0,y.createElementVNode)("div",fe,[(0,y.createElementVNode)("label",{for:r.parentResource.name,class:"inline-block text-gray-500 pt-2 leading-tight"},(0,y.toDisplayString)(r.parentResource.name),9,ve)]),(0,y.createElementVNode)("div",ge,[(0,y.createElementVNode)("span",ye,(0,y.toDisplayString)(r.parentResource.display),1)])])):(0,y.createCommentVNode)("",!0),(0,y.createVNode)(h,{field:e.field,errors:e.validationErrors,"show-help-text":!0},{field:(0,y.withCtx)((()=>[(0,y.createElementVNode)("div",be,[e.field.searchable?((0,y.openBlock)(),(0,y.createBlock)(s,{key:0,modelValue:e.selectedResourceId,"onUpdate:modelValue":t[0]||(t[0]=t=>e.selectedResourceId=t),onSelected:e.selectResource,onInput:e.performSearch,onClear:l.clearResourceSelection,options:e.availableResources,debounce:e.field.debounce,trackBy:"value",autocomplete:e.field.autocomplete,class:"w-full",dusk:`${e.field.resourceName}-search-input`},{option:(0,y.withCtx)((({selected:t,option:r})=>[(0,y.createElementVNode)("div",xe,[r.avatar?((0,y.openBlock)(),(0,y.createElementBlock)("div",Ne,[(0,y.createElementVNode)("img",{src:r.avatar,class:"w-8 h-8 rounded-full block"},null,8,Be)])):(0,y.createCommentVNode)("",!0),(0,y.createElementVNode)("div",Se,[(0,y.createElementVNode)("div",{class:(0,y.normalizeClass)(["text-sm font-semibold leading-5",{"text-white":t}])},(0,y.toDisplayString)(r.display),3),e.field.withSubtitles?((0,y.openBlock)(),(0,y.createElementBlock)("div",{key:0,class:(0,y.normalizeClass)(["mt-1 text-xs font-semibold leading-5 text-gray-500",{"text-white":t}])},[r.subtitle?((0,y.openBlock)(),(0,y.createElementBlock)("span",Ve,(0,y.toDisplayString)(r.subtitle),1)):((0,y.openBlock)(),(0,y.createElementBlock)("span",Re,(0,y.toDisplayString)(e.__("No additional information...")),1))],2)):(0,y.createCommentVNode)("",!0)])])])),default:(0,y.withCtx)((()=>[l.selectedResource?((0,y.openBlock)(),(0,y.createElementBlock)("div",ke,[l.selectedResource.avatar?((0,y.openBlock)(),(0,y.createElementBlock)("div",we,[(0,y.createElementVNode)("img",{src:l.selectedResource.avatar,class:"w-8 h-8 rounded-full block"},null,8,Ce)])):(0,y.createCommentVNode)("",!0),(0,y.createTextVNode)(" "+(0,y.toDisplayString)(l.selectedResource.display),1)])):(0,y.createCommentVNode)("",!0)])),_:1},8,["modelValue","onSelected","onInput","onClear","options","debounce","autocomplete","dusk"])):((0,y.openBlock)(),(0,y.createBlock)(c,{key:1,modelValue:e.selectedResourceId,"onUpdate:modelValue":t[1]||(t[1]=t=>e.selectedResourceId=t),onSelected:e.selectResource,options:e.availableResources,label:"display",class:(0,y.normalizeClass)(["w-full",{"form-control-bordered-error":e.validationErrors.has(e.field.attribute)}]),dusk:"attachable-select"},{default:(0,y.withCtx)((()=>[(0,y.createElementVNode)("option",Ee,(0,y.toDisplayString)(e.__("Choose :resource",{resource:l.relatedResourceLabel})),1)])),_:1},8,["modelValue","onSelected","options","class"])),l.canShowNewRelationModal?((0,y.openBlock)(),(0,y.createBlock)(d,{key:2,ariant:"link",size:"small","leading-icon":"plus-circle",onClick:l.openRelationModal,class:"ml-2",dusk:`${e.field.attribute}-inline-create`},null,8,["onClick","dusk"])):(0,y.createCommentVNode)("",!0)]),(0,y.createVNode)(u,{show:l.canShowNewRelationModal&&e.relationModalOpen,onSetResource:l.handleSetResource,onCreateCancelled:l.closeRelationModal,"resource-name":e.field.resourceName,"resource-id":r.resourceId,"via-relationship":r.viaRelationship,"via-resource":r.viaResource,"via-resource-id":r.viaResourceId},null,8,["show","onSetResource","onCreateCancelled","resource-name","resource-id","via-relationship","via-resource","via-resource-id"]),l.shouldShowTrashed?((0,y.openBlock)(),(0,y.createBlock)(p,{key:0,class:"mt-3","resource-name":e.field.resourceName,checked:e.withTrashed,onInput:l.toggleWithTrashed},null,8,["resource-name","checked","onInput"])):(0,y.createCommentVNode)("",!0)])),_:1},8,["field","errors"]),(0,y.createVNode)(m,{loading:e.loading},{default:(0,y.withCtx)((()=>[((0,y.openBlock)(!0),(0,y.createElementBlock)(y.Fragment,null,(0,y.renderList)(e.fields,(t=>((0,y.openBlock)(),(0,y.createElementBlock)("div",{key:t.uniqueKey},[((0,y.openBlock)(),(0,y.createBlock)((0,y.resolveDynamicComponent)(`form-${t.component}`),{"resource-name":r.resourceName,"resource-id":r.resourceId,"related-resource-name":r.relatedResourceName,field:t,"form-unique-id":e.formUniqueId,errors:e.validationErrors,"via-resource":r.viaResource,"via-resource-id":r.viaResourceId,"via-relationship":r.viaRelationship,"show-help-text":!0},null,8,["resource-name","resource-id","related-resource-name","field","form-unique-id","errors","via-resource","via-resource-id","via-relationship"]))])))),128))])),_:1},8,["loading"])])),_:1}),(0,y.createElementVNode)("div",_e,[(0,y.createVNode)(d,{dusk:"cancel-attach-button",onClick:l.cancelAttachingResource,label:e.__("Cancel"),variant:"ghost"},null,8,["onClick","label"]),(0,y.createVNode)(d,{dusk:"attach-and-attach-another-button",onClick:(0,y.withModifiers)(l.attachAndAttachAnother,["prevent"]),disabled:l.isWorking,loading:e.submittedViaAttachAndAttachAnother},{default:(0,y.withCtx)((()=>[(0,y.createTextVNode)((0,y.toDisplayString)(e.__("Attach & Attach Another")),1)])),_:1},8,["onClick","disabled","loading"]),(0,y.createVNode)(d,{type:"submit",dusk:"attach-button",disabled:l.isWorking,loading:e.submittedViaAttachResource},{default:(0,y.withCtx)((()=>[(0,y.createTextVNode)((0,y.toDisplayString)(e.__("Attach :resource",{resource:l.relatedResourceLabel})),1)])),_:1},8,["disabled","loading"])])],40,he)):(0,y.createCommentVNode)("",!0)])),_:1},8,["loading"])}],["__file","Attach.vue"]]),je=["data-form-unique-id"],$e={key:0,dusk:"via-resource-field",class:"field-wrapper flex flex-col md:flex-row border-b border-gray-100 dark:border-gray-700"},ze={class:"w-1/5 px-8 py-6"},Le=["for"],Ue={class:"py-6 px-8 w-1/2"},qe={class:"inline-block font-bold text-gray-500 pt-2"},He={value:"",disabled:"",selected:""},Ke={class:"flex flex-col mt-3 md:mt-6 md:flex-row items-center justify-center md:justify-end"};function We(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function Qe(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?We(Object(r),!0).forEach((function(t){Ge(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):We(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function Ge(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const Ze={components:{Button:ne.Button},mixins:[Q.c_,Q.B5,Q.Bz,Q.zJ,Q.rd],provide(){return{removeFile:this.removeFile}},props:{resourceName:{type:String,required:!0},resourceId:{required:!0},relatedResourceName:{type:String,required:!0},relatedResourceId:{required:!0},viaResource:{default:""},viaResourceId:{default:""},parentResource:{type:Object},viaRelationship:{default:""},viaPivotId:{default:null},polymorphic:{default:!1}},data:()=>({initialLoading:!0,loading:!0,submittedViaUpdateAndContinueEditing:!1,submittedViaUpdateAttachedResource:!1,field:null,softDeletes:!1,fields:[],selectedResourceId:null,lastRetrievedAt:null,title:null}),created(){if(Nova.missingResource(this.resourceName))return Nova.visit("/404")},mounted(){this.initializeComponent()},methods:Qe(Qe({},(0,Z.i0)(["fetchPolicies"])),{},{async initializeComponent(){this.softDeletes=!1,this.disableWithTrashed(),this.clearSelection(),await this.getField(),await this.getPivotFields(),await this.getAvailableResources(),this.resetErrors(),this.selectedResourceId=this.relatedResourceId,this.updateLastRetrievedAtTimestamp()},removeFile(e){const{resourceName:t,resourceId:r,relatedResourceName:o,relatedResourceId:i,viaRelationship:l}=this;Nova.request().delete(`/nova-api/${t}/${r}/${o}/${i}/field/${e}?viaRelationship=${l}`)},handlePivotFieldsLoaded(){this.loading=!1,Object.values(this.fields).forEach((e=>{e&&(e.fill=()=>"")}))},async getField(){this.field=null;const{data:e}=await Nova.request().get("/nova-api/"+this.resourceName+"/field/"+this.viaRelationship,{params:{relatable:!0}});this.field=e,this.field.searchable&&this.determineIfSoftDeletes(),this.initialLoading=!1},async getPivotFields(){this.fields=[];const{data:{title:e,fields:t}}=await Nova.request().get(`/nova-api/${this.resourceName}/${this.resourceId}/update-pivot-fields/${this.relatedResourceName}/${this.relatedResourceId}`,{params:{editing:!0,editMode:"update-attached",viaRelationship:this.viaRelationship,viaPivotId:this.viaPivotId}}).catch((e=>{404!=e.response.status||Nova.visit("/404")}));this.title=e,this.fields=t,this.handlePivotFieldsLoaded()},async getAvailableResources(e=""){Nova.$progress.start();try{const t=await Oe.A.fetchAvailableResources(this.resourceName,this.resourceId,this.relatedResourceName,{params:{search:e,current:this.relatedResourceId,first:!0,withTrashed:this.withTrashed,component:this.field.component,viaRelationship:this.viaRelationship}});this.availableResources=t.data.resources,this.withTrashed=t.data.withTrashed,this.softDeletes=t.data.softDeletes}catch(e){}Nova.$progress.done()},determineIfSoftDeletes(){Nova.request().get("/nova-api/"+this.relatedResourceName+"/soft-deletes").then((e=>{this.softDeletes=e.data.softDeletes}))},async updateAttachedResource(){this.submittedViaUpdateAttachedResource=!0;try{await this.updateRequest(),this.submittedViaUpdateAttachedResource=!1,await this.fetchPolicies(),Nova.success(this.__("The resource was updated!")),Nova.visit(`/resources/${this.resourceName}/${this.resourceId}`)}catch(e){window.scrollTo(0,0),this.submittedViaUpdateAttachedResource=!1,this.handleOnUpdateResponseError(e)}},async updateAndContinueEditing(){this.submittedViaUpdateAndContinueEditing=!0;try{await this.updateRequest(),window.scrollTo(0,0),this.disableNavigateBackUsingHistory(),this.submittedViaUpdateAndContinueEditing=!1,Nova.success(this.__("The resource was updated!")),this.initializeComponent()}catch(e){this.submittedViaUpdateAndContinueEditing=!1,this.handleOnUpdateResponseError(e)}},cancelUpdatingAttachedResource(){this.handleProceedingToPreviousPage(),this.proceedToPreviousPage(`/resources/${this.resourceName}/${this.resourceId}`)},updateRequest(){return Nova.request().post(`/nova-api/${this.resourceName}/${this.resourceId}/update-attached/${this.relatedResourceName}/${this.relatedResourceId}`,this.updateAttachmentFormData(),{params:{editing:!0,editMode:"update-attached",viaPivotId:this.viaPivotId}})},updateAttachmentFormData(){return De()(new FormData,(e=>{Object.values(this.fields).forEach((t=>{t.fill(e)})),e.append("viaRelationship",this.viaRelationship),this.selectedResourceId?e.append(this.relatedResourceName,this.selectedResourceId??""):e.append(this.relatedResourceName,""),e.append(this.relatedResourceName+"_trashed",this.withTrashed),e.append("_retrieved_at",this.lastRetrievedAt)}))},toggleWithTrashed(){this.withTrashed=!this.withTrashed,this.isSearchable||this.getAvailableResources()},updateLastRetrievedAtTimestamp(){this.lastRetrievedAt=Math.floor((new Date).getTime()/1e3)},onUpdateFormStatus(){},isSelectedResourceId(e){return null!=e&&e?.toString()===this.selectedResourceId?.toString()}}),computed:{attachmentEndpoint(){return this.polymorphic?"/nova-api/"+this.resourceName+"/"+this.resourceId+"/attach-morphed/"+this.relatedResourceName:"/nova-api/"+this.resourceName+"/"+this.resourceId+"/attach/"+this.relatedResourceName},relatedResourceLabel(){if(this.field)return this.field.singularLabel},isSearchable(){return this.field.searchable},isWorking(){return this.submittedViaUpdateAttachedResource||this.submittedViaUpdateAndContinueEditing},selectedResource(){return this.availableResources.find((e=>this.isSelectedResourceId(e.value)))}}},Je=(0,_.A)(Ze,[["render",function(e,t,r,o,i,l){const a=(0,y.resolveComponent)("Head"),n=(0,y.resolveComponent)("Heading"),s=(0,y.resolveComponent)("SelectControl"),c=(0,y.resolveComponent)("DefaultField"),d=(0,y.resolveComponent)("LoadingView"),u=(0,y.resolveComponent)("Card"),p=(0,y.resolveComponent)("Button");return(0,y.openBlock)(),(0,y.createBlock)(d,{loading:e.initialLoading},{default:(0,y.withCtx)((()=>[l.relatedResourceLabel&&e.title?((0,y.openBlock)(),(0,y.createBlock)(a,{key:0,title:e.__("Update attached :resource: :title",{resource:l.relatedResourceLabel,title:e.title})},null,8,["title"])):(0,y.createCommentVNode)("",!0),l.relatedResourceLabel&&e.title?((0,y.openBlock)(),(0,y.createBlock)(n,{key:1,class:"mb-3"},{default:(0,y.withCtx)((()=>[(0,y.createTextVNode)((0,y.toDisplayString)(e.__("Update attached :resource: :title",{resource:l.relatedResourceLabel,title:e.title})),1)])),_:1})):(0,y.createCommentVNode)("",!0),e.field?((0,y.openBlock)(),(0,y.createElementBlock)("form",{key:2,onSubmit:t[1]||(t[1]=(0,y.withModifiers)(((...e)=>l.updateAttachedResource&&l.updateAttachedResource(...e)),["prevent"])),onChange:t[2]||(t[2]=(...e)=>l.onUpdateFormStatus&&l.onUpdateFormStatus(...e)),"data-form-unique-id":e.formUniqueId,autocomplete:"off"},[(0,y.createVNode)(u,{class:"mb-8"},{default:(0,y.withCtx)((()=>[r.parentResource?((0,y.openBlock)(),(0,y.createElementBlock)("div",$e,[(0,y.createElementVNode)("div",ze,[(0,y.createElementVNode)("label",{for:r.parentResource.name,class:"inline-block text-gray-500 pt-2 leading-tight"},(0,y.toDisplayString)(r.parentResource.name),9,Le)]),(0,y.createElementVNode)("div",Ue,[(0,y.createElementVNode)("span",qe,(0,y.toDisplayString)(r.parentResource.display),1)])])):(0,y.createCommentVNode)("",!0),(0,y.createVNode)(c,{field:e.field,errors:e.validationErrors,"show-help-text":!0},{field:(0,y.withCtx)((()=>[(0,y.createVNode)(s,{modelValue:e.selectedResourceId,"onUpdate:modelValue":t[0]||(t[0]=t=>e.selectedResourceId=t),onSelected:e.selectResource,options:e.availableResources,disabled:"",label:"display",class:(0,y.normalizeClass)(["w-full",{"form-control-bordered-error":e.validationErrors.has(e.field.attribute)}]),dusk:"attachable-select"},{default:(0,y.withCtx)((()=>[(0,y.createElementVNode)("option",He,(0,y.toDisplayString)(e.__("Choose :field",{field:e.field.name})),1)])),_:1},8,["modelValue","onSelected","options","class"])])),_:1},8,["field","errors"]),(0,y.createVNode)(d,{loading:e.loading},{default:(0,y.withCtx)((()=>[((0,y.openBlock)(!0),(0,y.createElementBlock)(y.Fragment,null,(0,y.renderList)(e.fields,(t=>((0,y.openBlock)(),(0,y.createElementBlock)("div",{key:t.uniqueKey},[((0,y.openBlock)(),(0,y.createBlock)((0,y.resolveDynamicComponent)("form-"+t.component),{"resource-name":r.resourceName,"resource-id":r.resourceId,field:t,"form-unique-id":e.formUniqueId,errors:e.validationErrors,"related-resource-name":r.relatedResourceName,"related-resource-id":r.relatedResourceId,"via-resource":r.viaResource,"via-resource-id":r.viaResourceId,"via-relationship":r.viaRelationship,"show-help-text":!0},null,8,["resource-name","resource-id","field","form-unique-id","errors","related-resource-name","related-resource-id","via-resource","via-resource-id","via-relationship"]))])))),128))])),_:1},8,["loading"])])),_:1}),(0,y.createElementVNode)("div",Ke,[(0,y.createVNode)(p,{dusk:"cancel-update-attached-button",onClick:l.cancelUpdatingAttachedResource,label:e.__("Cancel"),variant:"ghost"},null,8,["onClick","label"]),(0,y.createVNode)(p,{class:"mr-3",dusk:"update-and-continue-editing-button",onClick:(0,y.withModifiers)(l.updateAndContinueEditing,["prevent"]),disabled:l.isWorking,loading:e.submittedViaUpdateAndContinueEditing},{default:(0,y.withCtx)((()=>[(0,y.createTextVNode)((0,y.toDisplayString)(e.__("Update & Continue Editing")),1)])),_:1},8,["onClick","disabled","loading"]),(0,y.createVNode)(p,{dusk:"update-button",type:"submit",disabled:l.isWorking,loading:e.submittedViaUpdateAttachedResource},{default:(0,y.withCtx)((()=>[(0,y.createTextVNode)((0,y.toDisplayString)(e.__("Update :resource",{resource:l.relatedResourceLabel})),1)])),_:1},8,["disabled","loading"])])],40,je)):(0,y.createCommentVNode)("",!0)])),_:1},8,["loading"])}],["__file","UpdateAttached.vue"]]);function Ye(e,t,r){r.keys().forEach((o=>{const i=r(o),l=C()(k()(o.split("/").pop().replace(/\.\w+$/,"")));e.component(t+l,i.default||i)}))}var Xe=r(6411),et=r.n(Xe),tt=r(70393);const rt={state:()=>({baseUri:"/nova",currentUser:null,currentUserPasswordConfirmed:null,mainMenu:[],userMenu:[],breadcrumbs:[],resources:[],version:"5.x",mainMenuShown:!1,canLeaveModal:!0,validLicense:!0,queryStringParams:{},compiledQueryStringParams:""}),getters:{currentUser:e=>e.currentUser,currentUserPasswordConfirmed:e=>e.currentUserPasswordConfirmed??!1,currentVersion:e=>e.version,mainMenu:e=>e.mainMenu,userMenu:e=>e.userMenu,breadcrumbs:e=>e.breadcrumbs,mainMenuShown:e=>e.mainMenuShown,canLeaveModal:e=>e.canLeaveModal,validLicense:e=>e.validLicense,queryStringParams:e=>e.queryStringParams},mutations:{allowLeavingModal(e){e.canLeaveModal=!0},preventLeavingModal(e){e.canLeaveModal=!1},toggleMainMenu(e){e.mainMenuShown=!e.mainMenuShown,localStorage.setItem("nova.mainMenu.open",e.mainMenuShown)}},actions:{async login({commit:e,dispatch:t},{email:r,password:o,remember:i}){await Nova.request().post(Nova.url("/login"),{email:r,password:o,remember:i})},async logout({state:e},t){let r=null;return r=!Nova.config("withAuthentication")&&t?await Nova.request().post(t):await Nova.request().post(Nova.url("/logout")),r?.data?.redirect||null},async startImpersonating({},{resource:e,resourceId:t}){let r=null;r=await Nova.request().post("/nova-api/impersonate",{resource:e,resourceId:t});let o=r?.data?.redirect||null;null===o?Nova.visit("/"):location.href=o},async stopImpersonating({}){let e=null;e=await Nova.request().delete("/nova-api/impersonate");let t=e?.data?.redirect||null;null===t?Nova.visit("/"):location.href=t},async confirmedPasswordStatus({state:e,dispatch:t}){const{data:{confirmed:r}}=await Nova.request().get(Nova.url("/user-security/confirmed-password-status"));t(r?"passwordConfirmed":"passwordUnconfirmed")},async passwordConfirmed({state:e,dispatch:t}){e.currentUserPasswordConfirmed=!0,setTimeout((()=>t("passwordUnconfirmed")),5e5)},async passwordUnconfirmed({state:e}){e.currentUserPasswordConfirmed=!1},async assignPropsFromInertia({state:e,dispatch:t}){const r=(0,c.N5)().props;let o=r.novaConfig||Nova.appConfig,{resources:i,base:l,version:a,mainMenu:n,userMenu:s}=o,d=r.currentUser,u=r.validLicense,p=r.breadcrumbs;Nova.appConfig=o,e.breadcrumbs=p||[],e.currentUser=d,e.validLicense=u,e.resources=i,e.baseUri=l,e.version=a,e.mainMenu=n,e.userMenu=s,t("syncQueryString")},async fetchPolicies({state:e,dispatch:t}){await t("assignPropsFromInertia")},async syncQueryString({state:e}){let t=new URLSearchParams(window.location.search);e.queryStringParams=Object.fromEntries(t.entries()),e.compiledQueryStringParams=t.toString()},async updateQueryString({state:e},t){let r=new URLSearchParams(window.location.search),o=await c.QB.decryptHistory(),i=null;return Object.entries(t).forEach((([e,t])=>{(0,tt.A)(t)?r.set(e,t||""):r.delete(e)})),e.compiledQueryStringParams!==r.toString()&&(o.url!==`${window.location.pathname}?${r}`&&(i=`${window.location.pathname}?${r}`),e.compiledQueryStringParams=r.toString()),Nova.$emit("query-string-changed",r),e.queryStringParams=Object.fromEntries(r.entries()),new Promise(((e,t)=>{e({searchParams:r,nextUrl:i,page:o})}))}}},ot={state:()=>({notifications:[],notificationsShown:!1,unreadNotifications:!1}),getters:{notifications:e=>e.notifications,notificationsShown:e=>e.notificationsShown,unreadNotifications:e=>e.unreadNotifications},mutations:{toggleNotifications(e){e.notificationsShown=!e.notificationsShown,localStorage.setItem("nova.mainMenu.open",e.notificationsShown)}},actions:{async fetchNotifications({state:e}){const{data:{notifications:t,unread:r}}=await Nova.request().get("/nova-api/nova-notifications");e.notifications=t,e.unreadNotifications=r},async markNotificationAsUnread({state:e,dispatch:t},r){await Nova.request().post(`/nova-api/nova-notifications/${r}/unread`),t("fetchNotifications")},async markNotificationAsRead({state:e,dispatch:t},r){await Nova.request().post(`/nova-api/nova-notifications/${r}/read`),t("fetchNotifications")},async deleteNotification({state:e,dispatch:t},r){await Nova.request().delete(`/nova-api/nova-notifications/${r}`),t("fetchNotifications")},async deleteAllNotifications({state:e,dispatch:t},r){await Nova.request().delete("/nova-api/nova-notifications"),t("fetchNotifications")},async markAllNotificationsAsRead({state:e,dispatch:t},r){await Nova.request().post("/nova-api/nova-notifications/read-all"),t("fetchNotifications")}}};function it(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function lt(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?it(Object(r),!0).forEach((function(t){at(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):it(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function at(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var nt=r(88055),st=r.n(nt),ct=r(76135),dt=r.n(ct),ut=r(7309),pt=r.n(ut),ht=r(87612),mt=r.n(ht),ft=r(40860),vt=r.n(ft),gt=r(21783);const yt={namespaced:!0,state:()=>({filters:[],originalFilters:[]}),getters:{filters:e=>e.filters,originalFilters:e=>e.originalFilters,hasFilters:e=>Boolean(e.filters.length>0),currentFilters:(e,t)=>mt()(e.filters).map((e=>({[e.class]:e.currentValue}))),currentEncodedFilters:(e,t)=>btoa((0,gt.L)(JSON.stringify(t.currentFilters))),filtersAreApplied:(e,t)=>t.activeFilterCount>0,activeFilterCount:(e,t)=>vt()(e.filters,((e,r)=>{const o=t.getOriginalFilter(r.class),i=JSON.stringify(o.currentValue);return JSON.stringify(r.currentValue)==i?e:e+1}),0),getFilter:e=>t=>pt()(e.filters,(e=>e.class==t)),getOriginalFilter:e=>t=>pt()(e.originalFilters,(e=>e.class==t)),getOptionsForFilter:(e,t)=>e=>{const r=t.getFilter(e);return r?r.options:[]},filterOptionValue:(e,t)=>(e,r)=>{const o=t.getFilter(e);return pt()(o.currentValue,((e,t)=>t==r))}},actions:{async fetchFilters({commit:e,state:t},r){let{resourceName:o,lens:i=!1}=r,{viaResource:l,viaResourceId:a,viaRelationship:n,relationshipType:s}=r,c={params:{viaResource:l,viaResourceId:a,viaRelationship:n,relationshipType:s}};const{data:d}=i?await Nova.request().get("/nova-api/"+o+"/lens/"+i+"/filters",c):await Nova.request().get("/nova-api/"+o+"/filters",c);e("storeFilters",d)},async resetFilterState({commit:e,getters:t}){dt()(t.originalFilters,(t=>{e("updateFilterState",{filterClass:t.class,value:t.currentValue})}))},async initializeCurrentFilterValuesFromQueryString({commit:e,getters:t},r){if(r){const t=JSON.parse(atob(r));dt()(t,(t=>{if(t.hasOwnProperty("class")&&t.hasOwnProperty("value"))e("updateFilterState",{filterClass:t.class,value:t.value});else for(let r in t)e("updateFilterState",{filterClass:r,value:t[r]})}))}}},mutations:{updateFilterState(e,{filterClass:t,value:r}){const o=pt()(e.filters,(e=>e.class==t));null!=o&&(o.currentValue=r)},storeFilters(e,t){e.filters=t,e.originalFilters=st()(t)},clearFilters(e){e.filters=[],e.originalFilters=[]}}};var bt=r(5947),kt=r.n(bt),wt=r(63218),Ct=r(44377),xt=r.n(Ct),Nt=r(85015),Bt=r.n(Nt),St=r(90179),Vt=r.n(St),Rt=r(52647),Et=r(51504),_t=r.n(Et),Ot=r(65835),Ft=r(99820),Dt=r(5620);const At={class:"bg-white dark:bg-gray-800 flex items-center h-14 shadow-b dark:border-b dark:border-gray-700"},Pt={class:"hidden lg:w-60 shrink-0 md:flex items-center"},Tt={class:"flex flex-1 px-4 sm:px-8 lg:px-12"},It={class:"isolate relative flex items-center pl-6 ml-auto"},Mt={class:"relative z-50"},jt={class:"relative z-[40] hidden md:flex ml-2"},$t={key:0,class:"lg:hidden w-60"},zt={class:"fixed inset-0 flex z-50"},Lt={ref:"modalContent",class:"bg-white dark:bg-gray-800 relative flex flex-col max-w-xxs w-full"},Ut={class:"absolute top-0 right-0 -mr-12 pt-2"},qt=["aria-label"],Ht={class:"px-2 border-b border-gray-200 dark:border-gray-700"},Kt={class:"flex flex-col gap-2 justify-between h-full py-3 px-3 overflow-x-auto"},Wt={class:"py-1"},Qt={class:"mt-auto"},Gt={__name:"MainHeader",setup(e){const t=(0,Z.Pj)(),r=(0,y.useTemplateRef)("modalContent"),{activate:o,deactivate:i}=(0,Dt.r)(r,{initialFocus:!0,allowOutsideClick:!1,escapeDeactivates:!1}),l=()=>t.commit("toggleMainMenu"),a=(0,y.computed)((()=>Nova.config("globalSearchEnabled"))),n=(0,y.computed)((()=>Nova.config("notificationCenterEnabled"))),s=(0,y.computed)((()=>t.getters.mainMenuShown)),c=(0,y.computed)((()=>Nova.config("appName")));return(0,y.watch)((()=>s.value),(e=>{if(!0===e)return document.body.classList.add("overflow-y-hidden"),void Nova.pauseShortcuts();document.body.classList.remove("overflow-y-hidden"),Nova.resumeShortcuts(),i()})),(0,y.onBeforeUnmount)((()=>{document.body.classList.remove("overflow-hidden"),Nova.resumeShortcuts(),i()})),(e,t)=>{const r=(0,y.resolveComponent)("AppLogo"),o=(0,y.resolveComponent)("Link"),i=(0,y.resolveComponent)("GlobalSearch"),d=(0,y.resolveComponent)("ThemeDropdown"),u=(0,y.resolveComponent)("NotificationCenter"),p=(0,y.resolveComponent)("UserMenu"),h=(0,y.resolveComponent)("MainMenu"),m=(0,y.resolveComponent)("MobileUserMenu");return(0,y.openBlock)(),(0,y.createElementBlock)("div",null,[(0,y.createElementVNode)("header",At,[(0,y.createVNode)((0,y.unref)(ne.Button),{icon:"bars-3",class:"lg:hidden ml-1",variant:"action",onClick:(0,y.withModifiers)(l,["prevent"]),"aria-label":e.__("Toggle Sidebar"),"aria-expanded":s.value?"true":"false"},null,8,["aria-label","aria-expanded"]),(0,y.createElementVNode)("div",Pt,[(0,y.createVNode)(o,{href:e.$url("/"),class:"text-gray-900 hover:text-gray-500 active:text-gray-900 dark:text-gray-400 dark:hover:text-gray-300 dark:active:text-gray-500 h-12 rounded-lg flex items-center ml-2 focus:ring focus:ring-inset focus:outline-none ring-primary-200 dark:ring-gray-600 px-4","aria-label":c.value},{default:(0,y.withCtx)((()=>[(0,y.createVNode)(r,{class:"h-6"})])),_:1},8,["href","aria-label"]),(0,y.createVNode)((0,y.unref)(Ft.default))]),(0,y.createElementVNode)("div",Tt,[a.value?((0,y.openBlock)(),(0,y.createBlock)(i,{key:0,class:"relative",dusk:"global-search-component"})):(0,y.createCommentVNode)("",!0),(0,y.createElementVNode)("div",It,[(0,y.createVNode)(d),(0,y.createElementVNode)("div",Mt,[n.value?((0,y.openBlock)(),(0,y.createBlock)(u,{key:0})):(0,y.createCommentVNode)("",!0)]),(0,y.createElementVNode)("div",jt,[(0,y.createVNode)(p)])])])]),((0,y.openBlock)(),(0,y.createBlock)(y.Teleport,{to:"body"},[(0,y.createVNode)(y.Transition,{"enter-active-class":"transition duration-100 ease-out","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"transition duration-200 ease-in","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:(0,y.withCtx)((()=>[s.value?((0,y.openBlock)(),(0,y.createElementBlock)("div",$t,[(0,y.createElementVNode)("div",zt,[(0,y.createElementVNode)("div",{class:"fixed inset-0","aria-hidden":"true"},[(0,y.createElementVNode)("div",{onClick:l,class:"absolute inset-0 bg-gray-600/75 dark:bg-gray-900/75"})]),(0,y.createElementVNode)("div",Lt,[(0,y.createElementVNode)("div",Ut,[(0,y.createElementVNode)("button",{onClick:(0,y.withModifiers)(l,["prevent"]),class:"ml-1 flex items-center justify-center h-10 w-10 rounded-full focus:outline-none focus:ring-2 focus:ring-inset focus:ring-white","aria-label":e.__("Close Sidebar")},t[0]||(t[0]=[(0,y.createElementVNode)("svg",{class:"h-6 w-6 text-white",xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","aria-hidden":"true"},[(0,y.createElementVNode)("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)]),8,qt)]),(0,y.createElementVNode)("div",Ht,[(0,y.createVNode)(o,{href:e.$url("/"),class:"text-gray-900 hover:text-gray-500 active:text-gray-900 dark:text-gray-400 dark:hover:text-gray-300 dark:active:text-gray-500 h-12 px-2 rounded-lg flex items-center focus:ring focus:ring-inset focus:outline-none","aria-label":c.value},{default:(0,y.withCtx)((()=>[(0,y.createVNode)(r,{class:"h-6"})])),_:1},8,["href","aria-label"])]),(0,y.createElementVNode)("div",Kt,[(0,y.createElementVNode)("div",Wt,[(0,y.createVNode)(h,{"data-screen":"responsive"})]),(0,y.createElementVNode)("div",Qt,[(0,y.createVNode)(m)])]),t[1]||(t[1]=(0,y.createElementVNode)("div",{class:"shrink-0 w-14","aria-hidden":"true"},null,-1))],512)])])):(0,y.createCommentVNode)("",!0)])),_:1})]))])}}},Zt=(0,_.A)(Gt,[["__file","MainHeader.vue"]]),Jt=["innerHTML"],Yt=Object.assign({name:"Footer"},{__name:"Footer",setup(e){const t=(0,y.computed)((()=>Nova.config("footer")));return(e,r)=>((0,y.openBlock)(),(0,y.createElementBlock)("div",{class:"mt-8 leading-normal text-xs text-gray-500 space-y-1",innerHTML:t.value},null,8,Jt))}}),Xt=(0,_.A)(Yt,[["__file","Footer.vue"]]),er={id:"nova"},tr={dusk:"content"},rr={class:"hidden lg:block lg:absolute left-0 bottom-0 lg:top-[56px] lg:bottom-auto w-60 px-3 py-8"},or={class:"p-4 md:py-8 md:px-12 lg:ml-60 space-y-8"},ir=Object.assign({name:"AppLayout"},{__name:"AppLayout",setup(e){const{__:t}=(0,Ot.B)(),r=e=>{Nova.error(e)},o=()=>{Nova.$toasted.show(t("Sorry, your session has expired."),{action:{onClick:()=>Nova.redirectToLogin(),text:t("Reload")},duration:null,type:"error"}),setTimeout((()=>{Nova.redirectToLogin()}),5e3)},i=(0,y.computed)((()=>Nova.config("breadcrumbsEnabled")));return(0,y.onMounted)((()=>{Nova.$on("error",r),Nova.$on("token-expired",o)})),(0,y.onBeforeUnmount)((()=>{Nova.$off("error",r),Nova.$off("token-expired",o)})),(e,t)=>{const r=(0,y.resolveComponent)("MainMenu"),o=(0,y.resolveComponent)("Breadcrumbs"),l=(0,y.resolveComponent)("FadeTransition");return(0,y.openBlock)(),(0,y.createElementBlock)("div",er,[(0,y.createVNode)((0,y.unref)(Zt)),(0,y.createElementVNode)("div",tr,[(0,y.createElementVNode)("div",rr,[(0,y.createVNode)(r,{class:"pb-24","data-screen":"desktop"})]),(0,y.createElementVNode)("div",or,[i.value?((0,y.openBlock)(),(0,y.createBlock)(o,{key:0})):(0,y.createCommentVNode)("",!0),(0,y.createVNode)(l,null,{default:(0,y.withCtx)((()=>[(0,y.renderSlot)(e.$slots,"default")])),_:3}),(0,y.createVNode)((0,y.unref)(Xt))])])])}}}),lr=(0,_.A)(ir,[["__file","AppLayout.vue"]]);var ar=r(91272),nr=r(80833);const{parseColor:sr}=r(50098);!function(){function e(e,t){clearTimeout(t.timeout),s().off(window,"mouseup",t.hurry),s().off(window,"keyup",t.hurry)}s().defineMode("htmltwig",(function(e,t){return s().overlayMode(s().getMode(e,t.backdrop||"text/html"),s().getMode(e,"twig"))})),s().defineOption("autoRefresh",!1,(function(t,r){t.state.autoRefresh&&(e(t,t.state.autoRefresh),t.state.autoRefresh=null),r&&0==t.display.wrapper.offsetHeight&&function(t,r){function o(){t.display.wrapper.offsetHeight?(e(t,r),t.display.lastWrapHeight!=t.display.wrapper.clientHeight&&t.refresh()):r.timeout=setTimeout(o,r.delay)}r.timeout=setTimeout(o,r.delay),r.hurry=function(){clearTimeout(r.timeout),r.timeout=setTimeout(o,50)},s().on(window,"mouseup",r.hurry),s().on(window,"keyup",r.hurry)}(t,t.state.autoRefresh={delay:r.delay||250})}))}();const cr=new(_t());class dr{constructor(e){this.bootingCallbacks=[],this.appConfig=e,this.useShortcuts=!0,this.pages={"Nova.Attach":r(35694).A,"Nova.ConfirmPassword":r(32987).A,"Nova.Create":r(86796).A,"Nova.Dashboard":r(95008).A,"Nova.Detail":r(46351).A,"Nova.EmailVerification":r(48199).A,"Nova.UserSecurity":r(99962).A,"Nova.Error":r(36653).A,"Nova.Error403":r(17922).A,"Nova.Error404":r(47873).A,"Nova.ForgotPassword":r(75203).A,"Nova.Index":r(85915).A,"Nova.Lens":r(79714).A,"Nova.Login":r(6511).A,"Nova.Replicate":r(73464).A,"Nova.ResetPassword":r(74234).A,"Nova.TwoFactorChallenge":r(19791).A,"Nova.Update":r(59856).A,"Nova.UpdateAttached":r(96731).A},this.$toasted=new Rt.A({theme:"nova",position:e.rtlEnabled?"bottom-left":"bottom-right",duration:6e3}),this.$progress=kt(),this.$router=c.QB,!0===e.debug&&(this.$testing={timezone:e=>{ar.wB.defaultZoneName=e}}),this.__started=!1,this.__booted=!1,this.__liftOff=!1}booting(e){this.bootingCallbacks.push(e)}boot(){if(!this.__started||!this.__liftOff||this.__booted)return;var e,t;this.debug("engage thrusters"),this.store=(0,Z.y$)(lt(lt({},rt),{},{modules:{nova:{namespaced:!0,modules:{notifications:ot}}}})),this.bootingCallbacks.forEach((e=>e(this.app,this.store))),this.bootingCallbacks=[],this.registerStoreModules(),this.app.mixin(o.A),e=this,t=this.store,c.QB.on("before",(()=>{(async()=>{e.debug("Syncing Inertia props to the store via `inertia:before`..."),await t.dispatch("assignPropsFromInertia")})()})),c.QB.on("navigate",(()=>{(async()=>{e.debug("Syncing Inertia props to the store via `inertia:navigate`..."),await t.dispatch("assignPropsFromInertia")})()})),c.QB.on("start",(()=>e.$progress.start())),c.QB.on("finish",(()=>e.$progress.done())),this.app.mixin({methods:{$url:(e,t)=>this.url(e,t)}}),this.component("Link",c.N_),this.component("InertiaLink",c.N_),this.component("Head",c.p3),function(e){e.component("CustomError403",I),e.component("CustomError404",D),e.component("CustomAppError",L),e.component("ResourceIndex",te),e.component("ResourceDetail",pe),e.component("AttachResource",Me),e.component("UpdateAttachedResource",Je);const t=r(60630);t.keys().forEach((r=>{const o=t(r),i=C()(k()(r.split("/").pop().replace(/\.\w+$/,"")));e.component(i,o.default||o)}))}(this),function(e){Ye(e,"Index",r(49020)),Ye(e,"Detail",r(11079)),Ye(e,"Form",r(67970)),Ye(e,"Filter",r(77978)),Ye(e,"Preview",r(87092))}(this),this.app.mount(this.mountTo);let i=et().prototype.stopCallback;et().prototype.stopCallback=(e,t,r)=>!this.useShortcuts||i.call(this,e,t,r),et().init(),this.applyTheme(),this.log("All systems go..."),this.__booted=!0}booted(e){e(this.app,this.store)}async countdown(){this.log("Initiating Nova countdown...");const e=this.config("appName");await(0,c.sj)({title:t=>t?`${t} - ${e}`:e,progress:!1,resolve:e=>{const t=null!=this.pages[e]?this.pages[e]:r(47873).A;return t.layout=t.layout||lr,t},setup:({el:e,App:t,props:r,plugin:o})=>{this.debug("engine start"),this.mountTo=e,this.app=(0,y.createApp)({render:()=>(0,y.h)(t,r)}),this.app.use(o),this.app.use(wt.Ay,{preventOverflow:!0,flip:!0,themes:{Nova:{$extend:"tooltip",triggers:["click"],autoHide:!0,placement:"bottom",html:!0}}})}}).then((()=>{this.__started=!0,this.debug("engine ready"),this.boot()}))}liftOff(){this.log("We have lift off!");let e=null;new MutationObserver((()=>{const t=document.documentElement.classList,r=t.contains("dark")?"dark":"light";r!==e&&(this.$emit("nova-theme-switched",{theme:r,element:t}),e=r)})).observe(document.documentElement,{attributes:!0,attributeOldValue:!0,attributeFilter:["class"]}),this.config("notificationCenterEnabled")&&(this.notificationPollingInterval=setInterval((()=>{document.hasFocus()&&this.$emit("refresh-notifications")}),this.config("notificationPollingInterval"))),this.__liftOff=!0,this.boot()}config(e){return this.appConfig[e]}form(e){return new i.l(e,{http:this.request()})}request(e=null){let t=a();return null!=e?t(e):t}url(e,t){return"/"===e&&(e=this.config("initialPath")),function(e,t,r){let o=new URLSearchParams(g()(r||{},f())).toString();return"/"==e&&t.startsWith("/")&&(e=""),e+t+(o.length>0?`?${o}`:"")}(this.config("base"),e,t)}hasSecurityFeatures(){const e=this.config("fortifyFeatures");return e.includes("update-passwords")||e.includes("two-factor-authentication")}$on(...e){cr.on(...e)}$once(...e){cr.once(...e)}$off(...e){cr.off(...e)}$emit(...e){cr.emit(...e)}missingResource(e){return null==this.config("resources").find((t=>t.uriKey===e))}addShortcut(e,t){et().bind(e,t)}disableShortcut(e){et().unbind(e)}pauseShortcuts(){this.useShortcuts=!1}resumeShortcuts(){this.useShortcuts=!0}registerStoreModules(){this.app.use(this.store),this.config("resources").forEach((e=>{this.store.registerModule(e.uriKey,yt)}))}inertia(e,t){this.pages[e]=t}component(e,t){null==this.app._context.components[e]&&this.app.component(e,t)}hasComponent(e){return Boolean(null!=this.app._context.components[C()(k()(e))])}info(e){this.$toasted.show(e,{type:"info"})}error(e){this.$toasted.show(e,{type:"error"})}success(e){this.$toasted.show(e,{type:"success"})}warning(e){this.$toasted.show(e,{type:"warning"})}formatNumber(e,t){const r=h(document.querySelector('meta[name="locale"]').content)(e);return void 0!==t?r.format(t):r.format()}log(e,t="log"){console[t]("[NOVA]",e)}debug(e,t="log"){!0===(this.config("debug")??!1)&&("error"===t?console.error(e):this.log(e,t))}redirectToLogin(){const e=!this.config("withAuthentication")&&this.config("customLoginPath")?this.config("customLoginPath"):this.url("/login");this.visit({remote:!0,url:e})}visit(e,t={}){const r=t?.openInNewTab||null;if(Bt()(e))c.QB.visit(this.url(e),Vt()(t,["openInNewTab"]));else if(Bt()(e.url)&&e.hasOwnProperty("remote")){if(!0===e.remote)return void(!0===r?window.open(e.url,"_blank"):window.location=e.url);c.QB.visit(e.url,Vt()(t,["openInNewTab"]))}}applyTheme(){const e=this.config("brandColors");if(Object.keys(e).length>0){const t=document.createElement("style");let r=Object.keys(e).reduce(((t,r)=>{let o=e[r],i=sr(o);if(i){let e=sr(nr.GB.toRGBA(function(e){let t=xt()(Array.from(e.mode).map(((t,r)=>[t,e.color[r]])));void 0!==e.alpha&&(t.a=e.alpha);return t}(i)));return t+`\n --colors-primary-${r}: ${`${e.color.join(" ")} / ${e.alpha}`};`}return t+`\n --colors-primary-${r}: ${o};`}),"");t.innerHTML=`:root {${r}\n}`,document.head.append(t)}}}r(76486);window.Vue=r(29726),window.LaravelNova=r(80510),window.LaravelNovaUtil=r(30043),window.createNovaApp=e=>new dr(e)},65703:(e,t,r)=>{"use strict";r.d(t,{d:()=>f});var o=r(35229),i=r(29726),l=r(87612),a=r.n(l),n=r(23805),s=r.n(n),c=r(15101),d=r.n(c),u=r(44826),p=r.n(u),h=r(65835);const{__:m}=(0,h.B)();function f(e,t,r){const l=(0,i.reactive)({working:!1,errors:new o.I,actionModalVisible:!1,responseModalVisible:!1,selectedActionKey:"",endpoint:e.endpoint||`/nova-api/${e.resourceName}/action`,actionResponseData:null}),n=(0,i.computed)((()=>e.selectedResources)),c=(0,i.computed)((()=>{if(l.selectedActionKey)return u.value.find((e=>e.uriKey===l.selectedActionKey))})),u=(0,i.computed)((()=>e.actions.concat(e.pivotActions?.actions||[]))),h=(0,i.computed)((()=>r.getters[`${e.resourceName}/currentEncodedFilters`])),f=(0,i.computed)((()=>e.viaRelationship?e.viaRelationship+"_search":e.resourceName+"_search")),v=(0,i.computed)((()=>r.getters.queryStringParams[f.value]||"")),g=(0,i.computed)((()=>e.viaRelationship?e.viaRelationship+"_trashed":e.resourceName+"_trashed")),y=(0,i.computed)((()=>r.getters.queryStringParams[g.value]||"")),b=(0,i.computed)((()=>e.actions.filter((e=>n.value.length>0&&!e.standalone)))),k=(0,i.computed)((()=>e.pivotActions?e.pivotActions.actions.filter((e=>0!==n.value.length||e.standalone)):[])),w=(0,i.computed)((()=>k.value.length>0)),C=(0,i.computed)((()=>w.value&&Boolean(e.pivotActions.actions.find((e=>e===c.value))))),x=(0,i.computed)((()=>({action:l.selectedActionKey,pivotAction:C.value,search:v.value,filters:h.value,trashed:y.value,viaResource:e.viaResource,viaResourceId:e.viaResourceId,viaRelationship:e.viaRelationship}))),N=(0,i.computed)((()=>d()(new FormData,(e=>{if("all"===n.value)e.append("resources","all");else{let t=a()(n.value.map((e=>s()(e)?e.id.pivotValue:null)));n.value.forEach((t=>e.append("resources[]",s()(t)?t.id.value:t))),"all"!==n.value&&!0===C.value&&t.length>0&&t.forEach((t=>e.append("pivots[]",t)))}c.value.fields.forEach((t=>{t.fill(e)}))}))));function B(){c.value.withoutConfirmation?O():S()}function S(){l.actionModalVisible=!0}function V(){l.actionModalVisible=!1}function R(){l.responseModalVisible=!0}function E(e){t("actionExecuted"),Nova.$emit("action-executed"),"function"==typeof e&&e()}function _(e){if(e.danger)return Nova.error(e.danger);Nova.success(e.message||m("The action was executed successfully."))}function O(e){l.working=!0,Nova.$progress.start();let t=c.value.responseType??"json";Nova.request({method:"post",url:l.endpoint,params:x.value,data:N.value,responseType:t}).then((async t=>{V(),F(t.data,t.headers,e)})).catch((e=>{e.response&&422===e.response.status&&("blob"===t?e.response.data.text().then((e=>{l.errors=new o.I(JSON.parse(e).errors)})):l.errors=new o.I(e.response.data.errors),Nova.error(m("There was a problem executing the action.")))})).finally((()=>{l.working=!1,Nova.$progress.done()}))}function F(e,t,r){let o=t["content-disposition"];if(e instanceof Blob&&null==o&&"application/json"===e.type)e.text().then((e=>{F(JSON.parse(e),t)}));else{if(e instanceof Blob)return E((async()=>{let t="unknown";if(o){let e=o.split(";")[1].match(/filename=(.+)/);2===e.length&&(t=p()(e[1],'"'))}await(0,i.nextTick)((()=>{let r=window.URL.createObjectURL(new Blob([e])),o=document.createElement("a");o.href=r,o.setAttribute("download",t),document.body.appendChild(o),o.click(),o.remove(),window.URL.revokeObjectURL(r)}))}));if(e.modal)return l.actionResponseData=e,_(e),R();if(e.download)return E((async()=>{_(e),await(0,i.nextTick)((()=>{let t=document.createElement("a");t.href=e.download,t.download=e.name,document.body.appendChild(t),t.click(),document.body.removeChild(t)}))}));if(e.deleted)return E((()=>_(e)));if(e.redirect){if(e.openInNewTab)return E((()=>window.open(e.redirect,"_blank")));window.location=e.redirect}if(e.visit)return _(e),Nova.visit({url:Nova.url(e.visit.path,e.visit.options),remote:!1});E((()=>_(e)))}}return{errors:(0,i.computed)((()=>l.errors)),working:(0,i.computed)((()=>l.working)),actionModalVisible:(0,i.computed)((()=>l.actionModalVisible)),responseModalVisible:(0,i.computed)((()=>l.responseModalVisible)),selectedActionKey:(0,i.computed)((()=>l.selectedActionKey)),determineActionStrategy:B,setSelectedActionKey:function(e){l.selectedActionKey=e},openConfirmationModal:S,closeConfirmationModal:V,openResponseModal:R,closeResponseModal:function(){l.responseModalVisible=!1},handleActionClick:function(e){l.selectedActionKey=e,B()},selectedAction:c,allActions:u,availableActions:b,availablePivotActions:k,executeAction:O,actionResponseData:(0,i.computed)((()=>l.actionResponseData))}}},10646:(e,t,r)=>{"use strict";r.d(t,{g:()=>i});var o=r(29726);function i(e){const t=(0,o.ref)(!1),r=(0,o.ref)([]);return{startedDrag:t,handleOnDragEnter:()=>t.value=!0,handleOnDragLeave:()=>t.value=!1,handleOnDrop:t=>{r.value=t.dataTransfer.files,e("fileChanged",t.dataTransfer.files)}}}},65835:(e,t,r)=>{"use strict";r.d(t,{B:()=>i});var o=r(42740);function i(){return{__:(e,t)=>(0,o.A)(e,t)}}},38402:(e,t,r)=>{"use strict";r.d(t,{y:()=>i});var o=r(29726);function i(e={attribute:"default",fields:[]},t=null){const r={},i=(0,o.ref)(0);e.fields.forEach((e=>{r[e.attribute]=e.visible}));const l=e=>{i.value=Object.values(e).filter((e=>!0===e)).length};return l(r),{handleFieldShown:e=>{r[e]=!0,null!==t&&t("field-shown",e),l(r)},handleFieldHidden:e=>{r[e]=!1,null!==t&&t("field-shown",e),l(r)},visibleFieldsCount:i}}},96040:(e,t,r)=>{"use strict";r.d(t,{A:()=>o});class o{constructor(e,t){this.attribute=e,this.formData=t,this.localFormData=new FormData}append(e,...t){this.localFormData.append(e,...t),this.formData.append(this.name(e),...t)}delete(e){this.localFormData.delete(e),this.formData.delete(this.name(e))}entries(){return this.localFormData.entries()}get(e){return this.localFormData.get(e)}getAll(e){return this.localFormData.getAll(e)}has(e){return this.localFormData.has(e)}keys(){return this.localFormData.keys()}set(e,...t){this.localFormData.set(e,...t),this.formData.set(this.name(e),...t)}values(){return this.localFormData.values()}name(e){let[t,...r]=e.split("[");return null!=r&&r.length>0?`${this.attribute}[${t}][${r.join("[")}`:`${this.attribute}[${e}]`}slug(e){return`${this.attribute}.${e}`}}},43665:(e,t,r)=>{"use strict";r.d(t,{A:()=>o});const o={emits:["actionExecuted"],props:["resourceName","resourceId","resource","panel"],methods:{actionExecuted(){this.$emit("actionExecuted")}}}},70821:(e,t,r)=>{"use strict";r.d(t,{A:()=>l,T:()=>i});const o={methods:{copyValueToClipboard(e){if(navigator.clipboard)navigator.clipboard.writeText(e);else if(window.clipboardData)window.clipboardData.setData("Text",e);else{let t=document.createElement("input"),[r,o]=[document.documentElement.scrollTop,document.documentElement.scrollLeft];document.body.appendChild(t),t.value=e,t.focus(),t.select(),document.documentElement.scrollTop=r,document.documentElement.scrollLeft=o,document.execCommand("copy"),t.remove()}}}};function i(){return{copyValueToClipboard:e=>o.methods.copyValueToClipboard(e)}}const l=o},67564:(e,t,r)=>{"use strict";r.d(t,{A:()=>x});var o=r(53110),i=r(38221),l=r.n(i),a=r(52420),n=r.n(a),s=r(58156),c=r.n(s),d=r(83488),u=r.n(d),p=r(62193),h=r.n(p),m=r(71086),f=r.n(m),v=r(19377),g=r(87941),y=r(70393),b=r(21783);function k(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function w(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?k(Object(r),!0).forEach((function(t){C(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):k(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function C(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const x={extends:v.A,emits:["field-shown","field-hidden"],props:w(w({},(0,g.r)(["shownViaNewRelationModal","field","viaResource","viaResourceId","viaRelationship","resourceName","resourceId","relatedResourceName","relatedResourceId"])),{},{syncEndpoint:{type:String,required:!1}}),data:()=>({dependentFieldDebouncer:null,canceller:null,watchedFields:{},watchedEvents:{},syncedField:null,pivot:!1,editMode:"create"}),created(){this.dependentFieldDebouncer=l()((e=>e()),50)},mounted(){(0,y.A)(this.relatedResourceName)?(this.pivot=!0,(0,y.A)(this.relatedResourceId)?this.editMode="update-attached":this.editMode="attach"):(0,y.A)(this.resourceId)&&(this.editMode="update"),h()(this.dependsOn)||n()(this.dependsOn,((e,t)=>{this.watchedEvents[t]=e=>{this.watchedFields[t]=e,this.dependentFieldDebouncer((()=>{this.watchedFields[t]=e,this.syncField()}))},this.watchedFields[t]=e,Nova.$on(this.getFieldAttributeChangeEventName(t),this.watchedEvents[t])}))},beforeUnmount(){null!==this.canceller&&this.canceller(),h()(this.watchedEvents)||n()(this.watchedEvents,((e,t)=>{Nova.$off(this.getFieldAttributeChangeEventName(t),e)}))},methods:{setInitialValue(){this.value=void 0!==this.currentField.value&&null!==this.currentField.value?this.currentField.value:this.value},fillIfVisible(e,t,r){this.currentlyIsVisible&&e.append(t,r)},syncField(){null!==this.canceller&&this.canceller(),Nova.request().patch(this.syncEndpoint||this.syncFieldEndpoint,this.dependentFieldValues,{params:f()({editing:!0,editMode:this.editMode,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,field:this.fieldAttribute,inline:this.shownViaNewRelationModal,component:this.field.dependentComponentKey},u()),cancelToken:new o.qm((e=>{this.canceller=e}))}).then((e=>{let t=JSON.parse(JSON.stringify(this.currentField)),r=this.currentlyIsVisible;this.syncedField=e.data,this.syncedField.visible!==r&&this.$emit(!0===this.syncedField.visible?"field-shown":"field-hidden",this.fieldAttribute),null==this.syncedField.value?(this.syncedField.value=t.value,this.revertSyncedFieldToPreviousValue(t)):this.setInitialValue();let o=!this.syncedFieldValueHasNotChanged();this.onSyncedField(),this.syncedField.dependentShouldEmitChangesEvent&&o&&this.emitOnSyncedFieldValueChange()})).catch((e=>{if(!(0,o.FZ)(e))throw e}))},revertSyncedFieldToPreviousValue(e){},onSyncedField(){},emitOnSyncedFieldValueChange(){this.emitFieldValueChange(this.field.attribute,this.currentField.value)},syncedFieldValueHasNotChanged(){const e=this.currentField.value;return(0,y.A)(e)?!(0,y.A)(this.value):null!=e&&e?.toString()===this.value?.toString()}},computed:{currentField(){return this.syncedField||this.field},currentlyIsVisible(){return this.currentField.visible},currentlyIsReadonly(){return null!==this.syncedField?Boolean(this.syncedField.readonly||c()(this.syncedField,"extraAttributes.readonly")):Boolean(this.field.readonly||c()(this.field,"extraAttributes.readonly"))},dependsOn(){return this.field.dependsOn||[]},currentFieldValues(){return{[this.fieldAttribute]:this.value}},dependentFieldValues(){return w(w({},this.currentFieldValues),this.watchedFields)},encodedDependentFieldValues(){return btoa((0,b.L)(JSON.stringify(this.dependentFieldValues)))},syncFieldEndpoint(){return"update-attached"===this.editMode?`/nova-api/${this.resourceName}/${this.resourceId}/update-pivot-fields/${this.relatedResourceName}/${this.relatedResourceId}`:"attach"===this.editMode?`/nova-api/${this.resourceName}/${this.resourceId}/creation-pivot-fields/${this.relatedResourceName}`:"update"===this.editMode?`/nova-api/${this.resourceName}/${this.resourceId}/update-fields`:`/nova-api/${this.resourceName}/creation-fields`}}}},33362:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});var o=r(70393),i=r(56449),l=r.n(i);const a={props:["field"],methods:{isEqualsToValue(e){return l()(this.field.value)&&(0,o.A)(e)?Boolean(this.field.value.includes(e)||this.field.value.includes(e.toString())):Boolean(this.field.value===e||this.field.value?.toString()===e||this.field.value===e?.toString()||this.field.value?.toString()===e?.toString())}},computed:{fieldAttribute(){return this.field.attribute},fieldHasValue(){return(0,o.A)(this.field.value)},usesCustomizedDisplay(){return this.field.usesCustomizedDisplay&&(0,o.A)(this.field.displayedAs)},fieldHasValueOrCustomizedDisplay(){return this.usesCustomizedDisplay||this.fieldHasValue},fieldValue(){return this.fieldHasValueOrCustomizedDisplay?String(this.field.displayedAs??this.field.value):null},shouldDisplayAsHtml(){return this.field.asHtml}}}},98868:(e,t,r)=>{"use strict";r.d(t,{A:()=>o});const o={props:{formUniqueId:{type:String}},methods:{emitFieldValue(e,t){Nova.$emit(`${e}-value`,t),!0===this.hasFormUniqueId&&Nova.$emit(`${this.formUniqueId}-${e}-value`,t)},emitFieldValueChange(e,t){Nova.$emit(`${e}-change`,t),!0===this.hasFormUniqueId&&Nova.$emit(`${this.formUniqueId}-${e}-change`,t)},getFieldAttributeValueEventName(e){return!0===this.hasFormUniqueId?`${this.formUniqueId}-${e}-value`:`${e}-value`},getFieldAttributeChangeEventName(e){return!0===this.hasFormUniqueId?`${this.formUniqueId}-${e}-change`:`${e}-change`}},computed:{fieldAttribute(){return this.field.attribute},hasFormUniqueId(){return null!=this.formUniqueId&&""!==this.formUniqueId},fieldAttributeValueEventName(){return this.getFieldAttributeValueEventName(this.fieldAttribute)},fieldAttributeChangeEventName(){return this.getFieldAttributeChangeEventName(this.fieldAttribute)}}}},19377:(e,t,r)=>{"use strict";r.d(t,{A:()=>s});var o=r(58156),i=r.n(o),l=r(87941);function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function n(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const s={extends:r(98868).A,props:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?a(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({},(0,l.r)(["nested","shownViaNewRelationModal","field","viaResource","viaResourceId","viaRelationship","resourceName","resourceId","showHelpText","mode"])),emits:["field-changed"],data(){return{value:this.fieldDefaultValue()}},created(){this.setInitialValue()},mounted(){this.field.fill=this.fill,Nova.$on(this.fieldAttributeValueEventName,this.listenToValueChanges)},beforeUnmount(){Nova.$off(this.fieldAttributeValueEventName,this.listenToValueChanges)},methods:{setInitialValue(){this.value=void 0!==this.field.value&&null!==this.field.value?this.field.value:this.fieldDefaultValue()},fieldDefaultValue:()=>"",fill(e){this.fillIfVisible(e,this.fieldAttribute,String(this.value))},fillIfVisible(e,t,r){this.isVisible&&e.append(t,r)},handleChange(e){this.value=e.target.value,this.field&&(this.emitFieldValueChange(this.fieldAttribute,this.value),this.$emit("field-changed"))},beforeRemove(){},listenToValueChanges(e){this.value=e}},computed:{currentField(){return this.field},fullWidthContent(){return this.currentField.fullWidth||this.field.fullWidth},placeholder(){return this.currentField.placeholder||this.field.name},isVisible(){return this.field.visible},isReadonly(){return Boolean(this.field.readonly||i()(this.field,"extraAttributes.readonly"))},isActionRequest(){return["action-fullscreen","action-modal"].includes(this.mode)}}}},45506:(e,t,r)=>{"use strict";r.d(t,{A:()=>l});var o=r(87941),i=r(50436);const l={emits:["file-upload-started","file-upload-finished"],props:(0,o.r)(["resourceName"]),async created(){if(this.field.withFiles){const{data:{draftId:e}}=await Nova.request().get(`/nova-api/${this.resourceName}/field-attachment/${this.fieldAttribute}/draftId`);this.draftId=e}},data:()=>({draftId:null,files:[],filesToRemove:[]}),methods:{uploadAttachment(e,{onUploadProgress:t,onCompleted:r,onFailure:o}){const l=new FormData;if(l.append("Content-Type",e.type),l.append("attachment",e),l.append("draftId",this.draftId),null==t&&(t=()=>{}),null==o&&(o=()=>{}),null==r)throw"Missing onCompleted parameter";this.$emit("file-upload-started"),Nova.request().post(`/nova-api/${this.resourceName}/field-attachment/${this.fieldAttribute}`,l,{onUploadProgress:t}).then((({data:{path:e,url:t}})=>{this.files.push({path:e,url:t});const o=r(e,t);return this.$emit("file-upload-finished"),o})).catch((e=>{if(o(e),422==e.response.status){const t=new i.I(e.response.data.errors);Nova.error(this.__("An error occurred while uploading the file: :error",{error:t.first("attachment")}))}else Nova.error(this.__("An error occurred while uploading the file."))}))},flagFileForRemoval(e){const t=this.files.findIndex((t=>t.url===e));-1===t?this.filesToRemove.push({url:e}):this.filesToRemove.push(this.files[t])},unflagFileForRemoval(e){const t=this.filesToRemove.findIndex((t=>t.url===e));-1!==t&&this.filesToRemove.splice(t,1)},clearAttachments(){this.field.withFiles&&Nova.request().delete(`/nova-api/${this.resourceName}/field-attachment/${this.fieldAttribute}/${this.draftId}`).then((e=>{})).catch((e=>{}))},clearFilesMarkedForRemoval(){this.field.withFiles&&this.filesToRemove.forEach((e=>{Nova.debug("deleting",e),Nova.request().delete(`/nova-api/${this.resourceName}/field-attachment/${this.fieldAttribute}`,{params:{attachment:e.path,attachmentUrl:e.url,draftId:this.draftId}}).then((e=>{})).catch((e=>{}))}))},fillAttachmentDraftId(e){let t=this.fieldAttribute,[r,...o]=t.split("[");if(null!=o&&o.length>0){let e=o.pop();t=o.length>0?`${r}[${o.join("[")}[${e.slice(0,-1)}DraftId]`:`${r}[${e.slice(0,-1)}DraftId]`}else t=`${t}DraftId`;this.fillIfVisible(e,t,this.draftId)}}}},38019:(e,t,r)=>{"use strict";r.d(t,{A:()=>l});var o=r(87941),i=r(70393);const l={props:(0,o.r)(["field","resourceName","resourceId","viaResource","viaResourceId","viaRelationship","relatedResourceName","relatedResourceId","mode"]),methods:{async fetchPreviewContent(e){Nova.$progress.start();let t=null==this.resourceId?"create":"update",r=null==this.resourceId?`/nova-api/${this.resourceName}/field/${this.field.attribute}/preview`:`/nova-api/${this.resourceName}/${this.resourceId}/field/${this.field.attribute}/preview`;(0,i.A)(this.relatedResourceName)&&(t=null==this.relatedResourceId?"attach":"update-attached",r=`${r}/${this.relatedResourceName}`);const{data:{preview:o}}=await Nova.request().post(r,{value:e},{params:{editing:!0,editMode:t,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship}});return Nova.$progress.done(),o}}}},27409:(e,t,r)=>{"use strict";r.d(t,{A:()=>i});var o=r(50436);const i={props:{formUniqueId:{type:String}},data:()=>({validationErrors:new o.I}),methods:{handleResponseError(e){Nova.debug(e,"error"),void 0===e.response||500==e.response.status?Nova.error(this.__("There was a problem submitting the form.")):422==e.response.status?(this.validationErrors=new o.I(e.response.data.errors),Nova.error(this.__("There was a problem submitting the form."))):Nova.error(this.__("There was a problem submitting the form.")+' "'+e.response.statusText+'"')},handleOnCreateResponseError(e){this.handleResponseError(e)},handleOnUpdateResponseError(e){e.response&&409==e.response.status?Nova.error(this.__("Another user has updated this resource since this page was loaded. Please refresh the page and try again.")):this.handleResponseError(e)},resetErrors(){this.validationErrors=new o.I}}}},24852:(e,t,r)=>{"use strict";r.d(t,{A:()=>i});var o=r(38402);const i={emits:["field-shown","field-hidden"],data:()=>({visibleFieldsForPanel:null}),created(){this.visibleFieldsForPanel=(0,o.y)(this.panel,this.$emit)},methods:{handleFieldShown(e){this.visibleFieldsForPanel.handleFieldShown(e)},handleFieldHidden(e){this.visibleFieldsForPanel.handleFieldHidden(e)}},computed:{visibleFieldsCount(){return this.visibleFieldsForPanel.visibleFieldsCount}}}},64116:(e,t,r)=>{"use strict";r.d(t,{A:()=>o});const o={data:()=>({isWorking:!1,fileUploadsCount:0}),methods:{handleFileUploadFinished(){this.fileUploadsCount--,this.fileUploadsCount<1&&(this.fileUploadsCount=0,this.isWorking=!1)},handleFileUploadStarted(){this.isWorking=!0,this.fileUploadsCount++}}}},95816:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});var o=r(87941),i=r(50436);function l(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function a(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const n={props:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?l(Object(r),!0).forEach((function(t){a(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):l(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({errors:{default:()=>new i.I}},(0,o.r)(["field"])),inject:{index:{default:null},viaParent:{default:null}},data:()=>({errorClass:"form-control-bordered-error"}),computed:{errorClasses(){return this.hasError?[this.errorClass]:[]},fieldAttribute(){return this.field.attribute},validationKey(){return this.nestedValidationKey||this.field.validationKey},hasError(){return this.errors.has(this.validationKey)},firstError(){if(this.hasError)return this.errors.first(this.validationKey)},nestedAttribute(){if(this.viaParent)return`${this.viaParent}[${this.index}][${this.field.attribute}]`},nestedValidationKey(){if(this.viaParent)return`${this.viaParent}.${this.index}.fields.${this.field.attribute}`}}}},65256:(e,t,r)=>{"use strict";r.d(t,{A:()=>o});const o={props:{loadCards:{type:Boolean,default:!0}},data:()=>({cards:[]}),created(){this.fetchCards()},watch:{cardsEndpoint(){this.fetchCards()}},methods:{async fetchCards(){if(this.loadCards){const{data:e}=await Nova.request().get(this.cardsEndpoint,{params:this.extraCardParams});this.cards=e}}},computed:{shouldShowCards(){return this.cards.length>0},hasDetailOnlyCards(){return this.cards.filter((e=>1==e.onlyOnDetail)).length>0},extraCardParams:()=>null}}},48016:(e,t,r)=>{"use strict";r.d(t,{A:()=>o});const o={computed:{resourceInformation(){return Nova.config("resources").find((e=>e.uriKey===this.resourceName))||null},viaResourceInformation(){if(this.viaResource)return Nova.config("resources").find((e=>e.uriKey===this.viaResource))||null},authorizedToCreate(){return!(["hasOneThrough","hasManyThrough"].indexOf(this.relationshipType)>=0)&&(this.resourceInformation?.authorizedToCreate||!1)}}}},15542:(e,t,r)=>{"use strict";r.d(t,{A:()=>i});var o=r(42740);const i={methods:{__:(e,t)=>(0,o.A)(e,t)}}},47965:(e,t,r)=>{"use strict";r.d(t,{A:()=>i});var o=r(86681);const i={props:{card:{type:Object,required:!0},dashboard:{type:String,required:!1},resourceName:{type:String,default:""},resourceId:{type:[Number,String],default:""},lens:{type:String,default:""}},created(){Nova.$on("metric-refresh",this.fetch),Nova.$on("resources-deleted",this.fetch),Nova.$on("resources-detached",this.fetch),Nova.$on("resources-restored",this.fetch),this.card.refreshWhenActionRuns&&Nova.$on("action-executed",this.fetch)},beforeUnmount(){Nova.$off("metric-refresh",this.fetch),Nova.$off("resources-deleted",this.fetch),Nova.$off("resources-detached",this.fetch),Nova.$off("resources-restored",this.fetch),Nova.$off("action-executed",this.fetch)},methods:{fetch(){this.loading=!0,(0,o.A)(Nova.request().get(this.metricEndpoint,this.metricPayload)).then(this.handleFetchCallback())},handleFetchCallback:()=>()=>{}},computed:{metricEndpoint(){const e=""!==this.lens?`/lens/${this.lens}`:"";return this.resourceName&&this.resourceId?`/nova-api/${this.resourceName}${e}/${this.resourceId}/metrics/${this.card.uriKey}`:this.resourceName?`/nova-api/${this.resourceName}${e}/metrics/${this.card.uriKey}`:`/nova-api/dashboards/cards/${this.dashboard}/metrics/${this.card.uriKey}`},metricPayload:()=>({})}}},79497:(e,t,r)=>{"use strict";r.d(t,{A:()=>i});var o=r(70393);const i={data:()=>({navigateBackUsingHistory:!0}),methods:{enableNavigateBackUsingHistory(){this.navigateBackUsingHistory=!1},disableNavigateBackUsingHistory(){this.navigateBackUsingHistory=!1},handleProceedingToPreviousPage(e=!1){e&&this.navigateBackUsingHistory&&window.history.back()},proceedToPreviousPage(e){(0,o.A)(e)?Nova.visit(e):Nova.visit("/")}}}},95094:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});var o=r(66278);function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function l(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach((function(t){a(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function a(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const n={props:{show:{type:Boolean,default:!1}},methods:l(l({},(0,o.PY)(["allowLeavingModal","preventLeavingModal"])),{},{updateModalStatus(){this.preventLeavingModal()},handlePreventModalAbandonment(e,t){if(!this.canLeaveModal)return window.confirm(this.__("Do you really want to leave? You have unsaved changes."))?(this.allowLeavingModal(),void e()):void t();e()}}),computed:l({},(0,o.L8)(["canLeaveModal"]))}},35229:(e,t,r)=>{"use strict";r.d(t,{x7:()=>i.A,pJ:()=>E,nl:()=>l.A,Tu:()=>h,Gj:()=>v.A,I:()=>me.I,IR:()=>K,S0:()=>W.A,pF:()=>Y,c_:()=>O.A,zB:()=>F.A,Qy:()=>D.A,Vo:()=>A.A,B5:()=>g.A,sK:()=>X.A,qR:()=>y.A,_w:()=>P.A,k6:()=>z.A,Kx:()=>he,Z4:()=>k,XJ:()=>V,Ye:()=>R.A,vS:()=>T,je:()=>_.A,Nw:()=>ee,dn:()=>te,Bz:()=>$,rd:()=>a.A,Uf:()=>n.A,IJ:()=>re,zJ:()=>I,rr:()=>o.r});var o=r(87941),i=r(43665),l=r(70821),a=r(79497),n=r(95094),s=r(87612),c=r.n(s);function d(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function u(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?d(Object(r),!0).forEach((function(t){p(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):d(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function p(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const h={methods:{openDeleteModal(){this.deleteModalOpen=!0},deleteResources(e,t=null){return this.viaManyToMany?this.detachResources(e):Nova.request({url:"/nova-api/"+this.resourceName,method:"delete",params:u(u({},this.deletableQueryString),{resources:m(e)})}).then(t||(()=>{this.getResources()})).then((()=>{Nova.$emit("resources-deleted")})).finally((()=>{this.deleteModalOpen=!1}))},deleteSelectedResources(){this.deleteResources(this.selectedResources)},deleteAllMatchingResources(){return this.viaManyToMany?this.detachAllMatchingResources():Nova.request({url:this.deleteAllMatchingResourcesEndpoint,method:"delete",params:u(u({},this.deletableQueryString),{resources:"all"})}).then((()=>{this.getResources()})).then((()=>{Nova.$emit("resources-deleted")})).finally((()=>{this.deleteModalOpen=!1}))},detachResources(e){return Nova.request({url:"/nova-api/"+this.resourceName+"/detach",method:"delete",params:u(u(u({},this.deletableQueryString),{resources:m(e)}),{pivots:f(e)})}).then((()=>{this.getResources()})).then((()=>{Nova.$emit("resources-detached")})).finally((()=>{this.deleteModalOpen=!1}))},detachAllMatchingResources(){return Nova.request({url:"/nova-api/"+this.resourceName+"/detach",method:"delete",params:u(u({},this.deletableQueryString),{resources:"all"})}).then((()=>{this.getResources()})).then((()=>{Nova.$emit("resources-detached")})).finally((()=>{this.deleteModalOpen=!1}))},forceDeleteResources(e,t=null){return Nova.request({url:"/nova-api/"+this.resourceName+"/force",method:"delete",params:u(u({},this.deletableQueryString),{resources:m(e)})}).then(t||(()=>{this.getResources()})).then((()=>{Nova.$emit("resources-deleted")})).finally((()=>{this.deleteModalOpen=!1}))},forceDeleteSelectedResources(){this.forceDeleteResources(this.selectedResources)},forceDeleteAllMatchingResources(){return Nova.request({url:this.forceDeleteSelectedResourcesEndpoint,method:"delete",params:u(u({},this.deletableQueryString),{resources:"all"})}).then((()=>{this.getResources()})).then((()=>{Nova.$emit("resources-deleted")})).finally((()=>{this.deleteModalOpen=!1}))},restoreResources(e,t=null){return Nova.request({url:"/nova-api/"+this.resourceName+"/restore",method:"put",params:u(u({},this.deletableQueryString),{resources:m(e)})}).then(t||(()=>{this.getResources()})).then((()=>{Nova.$emit("resources-restored")})).finally((()=>{this.restoreModalOpen=!1}))},restoreSelectedResources(){this.restoreResources(this.selectedResources)},restoreAllMatchingResources(){return Nova.request({url:this.restoreAllMatchingResourcesEndpoint,method:"put",params:u(u({},this.deletableQueryString),{resources:"all"})}).then((()=>{this.getResources()})).then((()=>{Nova.$emit("resources-restored")})).finally((()=>{this.restoreModalOpen=!1}))}},computed:{deleteAllMatchingResourcesEndpoint(){return this.lens?"/nova-api/"+this.resourceName+"/lens/"+this.lens:"/nova-api/"+this.resourceName},forceDeleteSelectedResourcesEndpoint(){return this.lens?"/nova-api/"+this.resourceName+"/lens/"+this.lens+"/force":"/nova-api/"+this.resourceName+"/force"},restoreAllMatchingResourcesEndpoint(){return this.lens?"/nova-api/"+this.resourceName+"/lens/"+this.lens+"/restore":"/nova-api/"+this.resourceName+"/restore"},deletableQueryString(){return{search:this.currentSearch,filters:this.encodedFilters,trashed:this.currentTrashed,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship}}}};function m(e){return e.map((e=>e.id.value))}function f(e){return c()(e.map((e=>e.id.pivotValue)))}var v=r(67564),g=r(27409),y=r(64116),b=r(30043);const k={computed:{userTimezone:()=>Nova.config("userTimezone")||Nova.config("timezone"),usesTwelveHourTime(){let e=(new Intl.DateTimeFormat).resolvedOptions().locale;return 12===(0,b.hourCycle)(e)}}};var w=r(66278),C=r(5187),x=r.n(C);function N(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function B(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?N(Object(r),!0).forEach((function(t){S(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):N(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function S(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const V={async created(){this.syncQueryString()},methods:B(B({},(0,w.i0)(["syncQueryString","updateQueryString"])),{},{pushAfterUpdatingQueryString(e){return this.updateQueryString(e).then((({searchParams:e,nextUrl:t,page:r})=>(x()(t)||Nova.$router.push({component:r.component,url:t,encryptHistory:r.encryptHistory,preserveScroll:!0,preserveState:!0}),new Promise(((o,i)=>{o({searchParams:e,nextUrl:t,page:r})})))))},visitAfterUpdatingQueryString(e){return this.updateQueryString(e).then((({searchParams:e,nextUrl:t})=>(x()(t)||Nova.$router.visit(t),new Promise(((r,o)=>{r({searchParams:e,nextUrl:t,page})})))))}}),computed:(0,w.L8)(["queryStringParams"])};var R=r(48016);r(15542);const E={props:{collapsable:{type:Boolean,default:!0}},data:()=>({collapsed:!1}),created(){const e=localStorage.getItem(this.localStorageKey);"undefined"!==e&&!0===this.collapsable&&(this.collapsed=JSON.parse(e)??this.collapsedByDefault)},unmounted(){localStorage.setItem(this.localStorageKey,this.collapsed)},methods:{toggleCollapse(){this.collapsed=!this.collapsed,localStorage.setItem(this.localStorageKey,this.collapsed)}},computed:{ariaExpanded(){return!1===this.collapsed?"true":"false"},shouldBeCollapsed(){return this.collapsed},localStorageKey(){return`nova.navigation.${this.item.key}.collapsed`},collapsedByDefault:()=>!1}};var _=r(47965),O=r(98868),F=r(19377),D=r(45506),A=r(38019),P=r(95816);const T={props:(0,o.r)(["resourceName","viaRelationship"]),computed:{localStorageKey(){let e=this.resourceName;return this.viaRelationship&&(e=`${e}.${this.viaRelationship}`),`nova.resources.${e}.collapsed`}}},I={data:()=>({withTrashed:!1}),methods:{toggleWithTrashed(){this.withTrashed=!this.withTrashed},enableWithTrashed(){this.withTrashed=!0},disableWithTrashed(){this.withTrashed=!1}}};var M=r(38221),j=r.n(M);const $={data:()=>({search:"",selectedResourceId:null,availableResources:[]}),methods:{selectResource(e){this.selectedResourceId=e.value,this.field&&("function"==typeof this.emitFieldValueChange?this.emitFieldValueChange(this.fieldAttribute,this.selectedResourceId):Nova.$emit(this.fieldAttribute+"-change",this.selectedResourceId))},handleSearchCleared(){this.availableResources=[]},clearSelection(){this.selectedResourceId=null,this.availableResources=[],this.field&&("function"==typeof this.emitFieldValueChange?this.emitFieldValueChange(this.fieldAttribute,null):Nova.$emit(this.fieldAttribute+"-change",null))},performSearch(e){this.search=e;const t=e.trim();""!=t&&this.searchDebouncer((()=>{this.getAvailableResources(t)}),500)},searchDebouncer:j()((e=>e()),500)}};var z=r(65256),L=r(42194),U=r.n(L);function q(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function H(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const K={computed:{suggestionsId(){return`${this.fieldAttribute}-list`},suggestions(){let e=null!=this.syncedField?this.syncedField:this.field;return null==e.suggestions?[]:e.suggestions},suggestionsAttributes(){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?q(Object(r),!0).forEach((function(t){H(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):q(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({},U()({list:this.suggestions.length>0?this.suggestionsId:null},(e=>null==e)))}}};var W=r(33362),Q=r(83488),G=r.n(Q),Z=r(71086),J=r.n(Z);const Y={data:()=>({filterHasLoaded:!1,filterIsActive:!1}),watch:{encodedFilters(e){Nova.$emit("filter-changed",[e])}},methods:{async clearSelectedFilters(e){e?await this.$store.dispatch(`${this.resourceName}/resetFilterState`,{resourceName:this.resourceName,lens:e}):await this.$store.dispatch(`${this.resourceName}/resetFilterState`,{resourceName:this.resourceName}),this.pushAfterUpdatingQueryString({[this.pageParameter]:1,[this.filterParameter]:""}),Nova.$emit("filter-reset")},filterChanged(){(this.$store.getters[`${this.resourceName}/filtersAreApplied`]||this.filterIsActive)&&(this.filterIsActive=!0,this.pushAfterUpdatingQueryString({[this.pageParameter]:1,[this.filterParameter]:this.encodedFilters}))},async initializeFilters(e){!0!==this.filterHasLoaded&&(this.$store.commit(`${this.resourceName}/clearFilters`),await this.$store.dispatch(`${this.resourceName}/fetchFilters`,J()({resourceName:this.resourceName,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,relationshipType:this.relationshipType,lens:e},G())),await this.initializeState(e),this.filterHasLoaded=!0)},async initializeState(e){this.initialEncodedFilters?await this.$store.dispatch(`${this.resourceName}/initializeCurrentFilterValuesFromQueryString`,this.initialEncodedFilters):await this.$store.dispatch(`${this.resourceName}/resetFilterState`,{resourceName:this.resourceName,lens:e})}},computed:{filterParameter(){return`${this.resourceName}_filter`},encodedFilters(){return this.$store.getters[`${this.resourceName}/currentEncodedFilters`]}}};var X=r(24852);const ee={methods:{selectPreviousPage(){this.pushAfterUpdatingQueryString({[this.pageParameter]:this.currentPage-1})},selectNextPage(){this.pushAfterUpdatingQueryString({[this.pageParameter]:this.currentPage+1})}},computed:{currentPage(){return parseInt(this.queryStringParams[this.pageParameter]||1)}}},te={data:()=>({perPage:25}),methods:{initializePerPageFromQueryString(){this.perPage=this.currentPerPage},perPageChanged(){this.pushAfterUpdatingQueryString({[this.perPageParameter]:this.perPage})}},computed:{currentPerPage(){return this.queryStringParams[this.perPageParameter]||25}}},re={data:()=>({pollingListener:null,currentlyPolling:!1}),beforeUnmount(){this.stopPolling()},methods:{initializePolling(){if(this.currentlyPolling=this.currentlyPolling||this.resourceResponse.polling,this.currentlyPolling&&null===this.pollingListener)return this.startPolling()},togglePolling(){this.currentlyPolling?this.stopPolling():this.startPolling()},stopPolling(){this.pollingListener&&(clearInterval(this.pollingListener),this.pollingListener=null),this.currentlyPolling=!1},startPolling(){this.pollingListener=setInterval((()=>{let e=this.selectedResources??[];document.hasFocus()&&document.querySelectorAll("[data-modal-open]").length<1&&e.length<1&&this.getResources()}),this.pollingInterval),this.currentlyPolling=!0},restartPolling(){!0===this.currentlyPolling&&(this.stopPolling(),this.startPolling())}},computed:{initiallyPolling(){return this.resourceResponse.polling},pollingInterval(){return this.resourceResponse.pollingInterval},shouldShowPollingToggle(){return this.resourceResponse&&this.resourceResponse.showPollingToggle||!1}}};var oe=r(29726),ie=r(7309),le=r.n(ie),ae=r(79859),ne=r.n(ae),se=r(55808),ce=r.n(se);function de(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function ue(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?de(Object(r),!0).forEach((function(t){pe(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):de(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function pe(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const he={mixins:[Y,V],props:ue(ue({},(0,o.r)(["resourceName","viaResource","viaResourceId","viaRelationship","relationshipType","disablePagination"])),{},{field:{type:Object},initialPerPage:{type:Number,required:!1}}),provide(){return{resourceHasId:(0,oe.computed)((()=>this.resourceHasId)),authorizedToViewAnyResources:(0,oe.computed)((()=>this.authorizedToViewAnyResources)),authorizedToUpdateAnyResources:(0,oe.computed)((()=>this.authorizedToUpdateAnyResources)),authorizedToDeleteAnyResources:(0,oe.computed)((()=>this.authorizedToDeleteAnyResources)),authorizedToRestoreAnyResources:(0,oe.computed)((()=>this.authorizedToRestoreAnyResources)),selectedResourcesCount:(0,oe.computed)((()=>this.selectedResources.length)),selectAllChecked:(0,oe.computed)((()=>this.selectAllChecked)),selectAllMatchingChecked:(0,oe.computed)((()=>this.selectAllMatchingChecked)),selectAllOrSelectAllMatchingChecked:(0,oe.computed)((()=>this.selectAllOrSelectAllMatchingChecked)),selectAllAndSelectAllMatchingChecked:(0,oe.computed)((()=>this.selectAllAndSelectAllMatchingChecked)),selectAllIndeterminate:(0,oe.computed)((()=>this.selectAllIndeterminate)),orderByParameter:(0,oe.computed)((()=>this.orderByParameter)),orderByDirectionParameter:(0,oe.computed)((()=>this.orderByDirectionParameter))}},data:()=>({actions:[],allMatchingResourceCount:0,authorizedToRelate:!1,canceller:null,currentPageLoadMore:null,deleteModalOpen:!1,initialLoading:!0,loading:!0,orderBy:"",orderByDirection:"",pivotActions:null,resourceHasId:!0,resourceHasActions:!1,resourceHasSoleActions:!1,resourceResponse:null,resourceResponseError:null,resources:[],search:"",selectAllMatchingResources:!1,selectedResources:[],softDeletes:!1,trashed:""}),async created(){if(Nova.missingResource(this.resourceName))return Nova.visit("/404");const e=j()((e=>e()),this.resourceInformation.debounce);this.initializeSearchFromQueryString(),this.initializePerPageFromQueryString(),this.initializeTrashedFromQueryString(),this.initializeOrderingFromQueryString(),await this.initializeFilters(this.lens||null),await this.getResources(),this.isLensView||await this.getAuthorizationToRelate(),this.getActions(),this.initialLoading=!1,this.$watch((()=>this.lens+this.resourceName+this.encodedFilters+this.currentSearch+this.currentPage+this.currentPerPage+this.currentOrderBy+this.currentOrderByDirection+this.currentTrashed),(()=>{null!==this.canceller&&this.canceller(),1===this.currentPage&&(this.currentPageLoadMore=null),this.getResources()})),this.$watch("search",(t=>{this.search=t,e((()=>this.performSearch()))}))},beforeUnmount(){null!==this.canceller&&this.canceller()},methods:{handleResourcesLoaded(){this.loading=!1,this.isLensView||null===this.resourceResponse.total?this.getAllMatchingResourceCount():this.allMatchingResourceCount=this.resourceResponse.total,Nova.$emit("resources-loaded",this.isLensView?{resourceName:this.resourceName,lens:this.lens,mode:"lens"}:{resourceName:this.resourceName,mode:this.isRelation?"related":"index"}),this.initializePolling()},selectAllResources(){this.selectedResources=this.resources.slice(0)},toggleSelectAll(e){e&&e.preventDefault(),this.selectAllChecked?this.clearResourceSelections():this.selectAllResources(),this.getActions()},toggleSelectAllMatching(e){e&&e.preventDefault(),this.selectAllMatchingResources?this.selectAllMatchingResources=!1:(this.selectAllResources(),this.selectAllMatchingResources=!0),this.getActions()},deselectAllResources(e){e&&e.preventDefault(),this.clearResourceSelections(),this.getActions()},updateSelectionStatus(e){if(ne()(this.selectedResources,e)){const t=this.selectedResources.indexOf(e);t>-1&&this.selectedResources.splice(t,1)}else this.selectedResources.push(e);this.selectAllMatchingResources=!1,this.getActions()},clearResourceSelections(){this.selectAllMatchingResources=!1,this.selectedResources=[]},orderByField(e){let t="asc"==this.currentOrderByDirection?"desc":"asc";this.currentOrderBy!=e.sortableUriKey&&(t="asc"),this.pushAfterUpdatingQueryString({[this.orderByParameter]:e.sortableUriKey,[this.orderByDirectionParameter]:t})},resetOrderBy(e){this.pushAfterUpdatingQueryString({[this.orderByParameter]:e.sortableUriKey,[this.orderByDirectionParameter]:null})},initializeSearchFromQueryString(){this.search=this.currentSearch},initializeOrderingFromQueryString(){this.orderBy=this.currentOrderBy,this.orderByDirection=this.currentOrderByDirection},initializeTrashedFromQueryString(){this.trashed=this.currentTrashed},trashedChanged(e){this.trashed=e,this.pushAfterUpdatingQueryString({[this.trashedParameter]:this.trashed})},updatePerPageChanged(e){this.perPage=e,this.perPageChanged()},selectPage(e){this.pushAfterUpdatingQueryString({[this.pageParameter]:e})},initializePerPageFromQueryString(){this.perPage=this.queryStringParams[this.perPageParameter]||this.initialPerPage||this.resourceInformation?.perPageOptions[0]||null},closeDeleteModal(){this.deleteModalOpen=!1},performSearch(){this.pushAfterUpdatingQueryString({[this.pageParameter]:1,[this.searchParameter]:this.search})},handleActionExecuted(){this.fetchPolicies(),this.getResources()}},computed:{hasFilters(){return this.$store.getters[`${this.resourceName}/hasFilters`]},pageParameter(){return this.viaRelationship?`${this.viaRelationship}_page`:`${this.resourceName}_page`},selectAllChecked(){return this.selectedResources.length==this.resources.length},selectAllIndeterminate(){return Boolean(this.selectAllChecked||this.selectAllMatchingChecked)&&Boolean(!this.selectAllAndSelectAllMatchingChecked)},selectAllAndSelectAllMatchingChecked(){return this.selectAllChecked&&this.selectAllMatchingChecked},selectAllOrSelectAllMatchingChecked(){return this.selectAllChecked||this.selectAllMatchingChecked},selectAllMatchingChecked(){return this.selectAllMatchingResources},selectedResourceIds(){return this.selectedResources.map((e=>e.id.value))},selectedPivotIds(){return this.selectedResources.map((e=>e.id.pivotValue??null))},currentSearch(){return this.queryStringParams[this.searchParameter]||""},currentOrderBy(){return this.queryStringParams[this.orderByParameter]||""},currentOrderByDirection(){return this.queryStringParams[this.orderByDirectionParameter]||null},currentTrashed(){return this.queryStringParams[this.trashedParameter]||""},viaManyToMany(){return"belongsToMany"==this.relationshipType||"morphToMany"==this.relationshipType},isRelation(){return Boolean(this.viaResourceId&&this.viaRelationship)},singularName(){return this.isRelation&&this.field?ce()(this.field.singularLabel):this.resourceInformation?ce()(this.resourceInformation.singularLabel):void 0},hasResources(){return Boolean(this.resources.length>0)},hasLenses(){return Boolean(this.lenses.length>0)},shouldShowCards(){return Boolean(this.cards.length>0&&!this.isRelation)},shouldShowSelectAllCheckboxes(){return!1!==this.hasResources&&(!1!==this.resourceHasId&&(!(!this.authorizedToDeleteAnyResources&&!this.canShowDeleteMenu)||(!0===this.resourceHasActions||void 0)))},shouldShowCheckboxes(){return this.hasResources&&this.resourceHasId&&Boolean(this.resourceHasActions||this.resourceHasSoleActions||this.authorizedToDeleteAnyResources||this.canShowDeleteMenu)},shouldShowDeleteMenu(){return Boolean(this.selectedResources.length>0)&&this.canShowDeleteMenu},authorizedToDeleteSelectedResources(){return Boolean(le()(this.selectedResources,(e=>e.authorizedToDelete)))},authorizedToForceDeleteSelectedResources(){return Boolean(le()(this.selectedResources,(e=>e.authorizedToForceDelete)))},authorizedToViewAnyResources(){return this.resources.length>0&&this.resourceHasId&&Boolean(le()(this.resources,(e=>e.authorizedToView)))},authorizedToUpdateAnyResources(){return this.resources.length>0&&this.resourceHasId&&Boolean(le()(this.resources,(e=>e.authorizedToUpdate)))},authorizedToDeleteAnyResources(){return this.resources.length>0&&this.resourceHasId&&Boolean(le()(this.resources,(e=>e.authorizedToDelete)))},authorizedToForceDeleteAnyResources(){return this.resources.length>0&&this.resourceHasId&&Boolean(le()(this.resources,(e=>e.authorizedToForceDelete)))},authorizedToRestoreSelectedResources(){return this.resourceHasId&&Boolean(le()(this.selectedResources,(e=>e.authorizedToRestore)))},authorizedToRestoreAnyResources(){return this.resources.length>0&&this.resourceHasId&&Boolean(le()(this.resources,(e=>e.authorizedToRestore)))},encodedFilters(){return this.$store.getters[`${this.resourceName}/currentEncodedFilters`]},initialEncodedFilters(){return this.queryStringParams[this.filterParameter]||""},paginationComponent:()=>`pagination-${Nova.config("pagination")||"links"}`,hasNextPage(){return Boolean(this.resourceResponse&&this.resourceResponse.next_page_url)},hasPreviousPage(){return Boolean(this.resourceResponse&&this.resourceResponse.prev_page_url)},totalPages(){return Math.ceil(this.allMatchingResourceCount/this.currentPerPage)},resourceCountLabel(){const e=this.perPage*(this.currentPage-1);return this.resources.length&&`${Nova.formatNumber(e+1)}-${Nova.formatNumber(e+this.resources.length)} ${this.__("of")} ${Nova.formatNumber(this.allMatchingResourceCount)}`},currentPerPage(){return this.perPage},perPageOptions(){if(this.resourceResponse)return this.resourceResponse.per_page_options},createButtonLabel(){return this.resourceInformation?this.resourceInformation.createButtonLabel:this.__("Create")},resourceRequestQueryString(){const e={search:this.currentSearch,filters:this.encodedFilters,orderBy:this.currentOrderBy,orderByDirection:this.currentOrderByDirection,perPage:this.currentPerPage,trashed:this.currentTrashed,page:this.currentPage,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,viaResourceRelationship:this.viaResourceRelationship,relationshipType:this.relationshipType};return this.lensName||(e.viaRelationship=this.viaRelationship),e},shouldShowActionSelector(){return this.selectedResources.length>0||this.haveStandaloneActions},isLensView(){return""!==this.lens&&null!=this.lens&&null!=this.lens},shouldShowPagination(){return!0!==this.disablePagination&&this.resourceResponse&&(this.hasResources||this.hasPreviousPage)},currentResourceCount(){return this.resources.length},searchParameter(){return this.viaRelationship?`${this.viaRelationship}_search`:`${this.resourceName}_search`},orderByParameter(){return this.viaRelationship?`${this.viaRelationship}_order`:`${this.resourceName}_order`},orderByDirectionParameter(){return this.viaRelationship?`${this.viaRelationship}_direction`:`${this.resourceName}_direction`},trashedParameter(){return this.viaRelationship?`${this.viaRelationship}_trashed`:`${this.resourceName}_trashed`},perPageParameter(){return this.viaRelationship?`${this.viaRelationship}_per_page`:`${this.resourceName}_per_page`},haveStandaloneActions(){return this.allActions.filter((e=>!0===e.standalone)).length>0},availableActions(){return this.actions},hasPivotActions(){return this.pivotActions&&this.pivotActions.actions.length>0},pivotName(){return this.pivotActions?this.pivotActions.name:""},actionsAreAvailable(){return this.allActions.length>0},allActions(){return this.hasPivotActions?this.actions.concat(this.pivotActions.actions):this.actions},availableStandaloneActions(){return this.allActions.filter((e=>!0===e.standalone))},selectedResourcesForActionSelector(){return this.selectAllMatchingChecked?"all":this.selectedResources}}};var me=r(50436)},80510:(e,t,r)=>{"use strict";r.r(t),r.d(t,{BehavesAsPanel:()=>n.A,CopiesToClipboard:()=>i.A,DependentFormField:()=>s.A,Errors:()=>C.I,FieldValue:()=>m.A,FormEvents:()=>f.A,FormField:()=>v.A,HandlesFieldAttachments:()=>g.A,HandlesFieldPreviews:()=>y.A,HandlesFormRequest:()=>c.A,HandlesPanelVisibility:()=>w.A,HandlesUploads:()=>d.A,HandlesValidationErrors:()=>b.A,HasCards:()=>k.A,InteractsWithResourceInformation:()=>u.A,Localization:()=>p.A,MetricBehavior:()=>h.A,PreventsFormAbandonment:()=>l.A,PreventsModalAbandonment:()=>a.A,mapProps:()=>o.r,useCopyValueToClipboard:()=>i.T,useLocalization:()=>x.B});var o=r(87941),i=r(70821),l=r(79497),a=r(95094),n=r(43665),s=r(67564),c=r(27409),d=r(64116),u=r(48016),p=r(15542),h=r(47965),m=r(33362),f=r(98868),v=r(19377),g=r(45506),y=r(38019),b=r(95816),k=r(65256),w=r(24852),C=r(50436),x=r(65835)},87941:(e,t,r)=>{"use strict";r.d(t,{r:()=>a});var o=r(44383),i=r.n(o);const l={nested:{type:Boolean,default:!1},preventInitialLoading:{type:Boolean,default:!1},showHelpText:{type:Boolean,default:!1},shownViaNewRelationModal:{type:Boolean,default:!1},resourceId:{type:[Number,String]},resourceName:{type:String},relatedResourceId:{type:[Number,String]},relatedResourceName:{type:String},field:{type:Object,required:!0},viaResource:{type:String,required:!1},viaResourceId:{type:[String,Number],required:!1},viaRelationship:{type:String,required:!1},relationshipType:{type:String,default:""},shouldOverrideMeta:{type:Boolean,default:!1},disablePagination:{type:Boolean,default:!1},clickAction:{type:String,default:"view",validator:e=>["edit","select","ignore","detail"].includes(e)},mode:{type:String,default:"form",validator:e=>["form","modal","action-modal","action-fullscreen"].includes(e)}};function a(e){return i()(l,e)}},1242:(e,t,r)=>{"use strict";r.d(t,{A:()=>o});const o={fetchAvailableResources:(e,t,r)=>Nova.request().get(`/nova-api/${e}/associatable/${t}`,r),determineIfSoftDeletes:e=>Nova.request().get(`/nova-api/${e}/soft-deletes`)}},52191:(e,t,r)=>{"use strict";r.d(t,{A:()=>i});var o=r(70393);const i={fetchAvailableResources(e,t,r,i){const l=(0,o.A)(t)?`/nova-api/${e}/${t}/attachable/${r}`:`/nova-api/${e}/attachable/${r}`;return Nova.request().get(l,i)},determineIfSoftDeletes:e=>Nova.request().get(`/nova-api/${e}/soft-deletes`)}},25019:(e,t,r)=>{"use strict";r.d(t,{A:()=>o});const o={fetchAvailableResources:(e,t)=>Nova.request().get(`/nova-api/${e}/search`,t),determineIfSoftDeletes:e=>Nova.request().get(`/nova-api/${e}/soft-deletes`)}},50436:(e,t,r)=>{"use strict";r.d(t,{I:()=>p,l:()=>u});const o=["__http","__options","__validateRequestType","clear","data","delete","errors","getError","getErrors","hasError","initial","onFail","only","onSuccess","patch","populate","post","processing","successful","put","reset","submit","withData","withErrors","withOptions"];function i(e){if(-1!==o.indexOf(e))throw new Error(`Field name ${e} isn't allowed to be used in a Form or Errors instance.`)}function l(e){return e instanceof File||e instanceof FileList}function a(e,t){for(const r in t)e[r]=n(t[r])}function n(e){if(null===e)return null;if(l(e))return e;if(Array.isArray(e)){const t=[];for(const r in e)e.hasOwnProperty(r)&&(t[r]=n(e[r]));return t}if("object"==typeof e){const t={};for(const r in e)e.hasOwnProperty(r)&&(t[r]=n(e[r]));return t}return e}function s(e,t=new FormData,r=null){if(null===e||"undefined"===e||0===e.length)return t.append(r,e);for(const o in e)e.hasOwnProperty(o)&&d(t,c(r,o),e[o]);return t}function c(e,t){return e?e+"["+t+"]":t}function d(e,t,r){return r instanceof Date?e.append(t,r.toISOString()):r instanceof File?e.append(t,r,r.name):"boolean"==typeof r?e.append(t,r?"1":"0"):null===r?e.append(t,""):"object"!=typeof r?e.append(t,r):void s(r,e,t)}class u{constructor(e={},t={}){this.processing=!1,this.successful=!1,this.withData(e).withOptions(t).withErrors({})}withData(e){var t;t=e,"[object Array]"===Object.prototype.toString.call(t)&&(e=e.reduce(((e,t)=>(e[t]="",e)),{})),this.setInitialValues(e),this.errors=new p,this.processing=!1,this.successful=!1;for(const t in e)i(t),this[t]=e[t];return this}withErrors(e){return this.errors=new p(e),this}withOptions(e){this.__options={resetOnSuccess:!0},e.hasOwnProperty("resetOnSuccess")&&(this.__options.resetOnSuccess=e.resetOnSuccess),e.hasOwnProperty("onSuccess")&&(this.onSuccess=e.onSuccess),e.hasOwnProperty("onFail")&&(this.onFail=e.onFail);const t="undefined"!=typeof window&&window.axios;if(this.__http=e.http||t||r(86425),!this.__http)throw new Error("No http library provided. Either pass an http option, or install axios.");return this}data(){const e={};for(const t in this.initial)e[t]=this[t];return e}only(e){return e.reduce(((e,t)=>(e[t]=this[t],e)),{})}reset(){a(this,this.initial),this.errors.clear()}setInitialValues(e){this.initial={},a(this.initial,e)}populate(e){return Object.keys(e).forEach((t=>{i(t),this.hasOwnProperty(t)&&a(this,{[t]:e[t]})})),this}clear(){for(const e in this.initial)this[e]="";this.errors.clear()}post(e){return this.submit("post",e)}put(e){return this.submit("put",e)}patch(e){return this.submit("patch",e)}delete(e){return this.submit("delete",e)}submit(e,t){return this.__validateRequestType(e),this.errors.clear(),this.processing=!0,this.successful=!1,new Promise(((r,o)=>{this.__http[e](t,this.hasFiles()?s(this.data()):this.data()).then((e=>{this.processing=!1,this.onSuccess(e.data),r(e.data)})).catch((e=>{this.processing=!1,this.onFail(e),o(e)}))}))}hasFiles(){for(const e in this.initial)if(this.hasFilesDeep(this[e]))return!0;return!1}hasFilesDeep(e){if(null===e)return!1;if("object"==typeof e)for(const t in e)if(e.hasOwnProperty(t)&&this.hasFilesDeep(e[t]))return!0;if(Array.isArray(e))for(const t in e)if(e.hasOwnProperty(t))return this.hasFilesDeep(e[t]);return l(e)}onSuccess(e){this.successful=!0,this.__options.resetOnSuccess&&this.reset()}onFail(e){this.successful=!1,e.response&&e.response.data.errors&&this.errors.record(e.response.data.errors)}hasError(e){return this.errors.has(e)}getError(e){return this.errors.first(e)}getErrors(e){return this.errors.get(e)}__validateRequestType(e){const t=["get","delete","head","post","put","patch"];if(-1===t.indexOf(e))throw new Error(`\`${e}\` is not a valid request type, must be one of: \`${t.join("`, `")}\`.`)}static create(e={}){return(new u).withData(e)}}class p{constructor(e={}){this.record(e)}all(){return this.errors}has(e){let t=this.errors.hasOwnProperty(e);if(!t){t=Object.keys(this.errors).filter((t=>t.startsWith(`${e}.`)||t.startsWith(`${e}[`))).length>0}return t}first(e){return this.get(e)[0]}get(e){return this.errors[e]||[]}any(e=[]){if(0===e.length)return Object.keys(this.errors).length>0;let t={};return e.forEach((e=>t[e]=this.get(e))),t}record(e={}){this.errors=e}clear(e){if(!e)return void(this.errors={});let t=Object.assign({},this.errors);Object.keys(t).filter((t=>t===e||t.startsWith(`${e}.`)||t.startsWith(`${e}[`))).forEach((e=>delete t[e])),this.errors=t}}},21783:(e,t,r)=>{"use strict";function o(e){return e.replace(/[^\0-~]/g,(e=>"\\u"+("000"+e.charCodeAt().toString(16)).slice(-4)))}r.d(t,{L:()=>o})},70393:(e,t,r)=>{"use strict";function o(e){return Boolean(null!=e&&""!==e)}r.d(t,{A:()=>o})},30043:(e,t,r)=>{"use strict";r.r(t),r.d(t,{filled:()=>o.A,hourCycle:()=>i,increaseOrDecrease:()=>l,minimum:()=>a.A,singularOrPlural:()=>u});var o=r(70393);function i(e){let t=Intl.DateTimeFormat(e,{hour:"numeric"}).resolvedOptions().hourCycle;return"h23"==t||"h24"==t?24:12}function l(e,t){return 0===t?null:e>t?(e-t)/Math.abs(t)*100:(t-e)/Math.abs(t)*-100}var a=r(86681),n=r(23727),s=r.n(n),c=r(85015),d=r.n(c);function u(e,t){return d()(t)&&null==t.match(/^(.*)[A-Za-zÀ-ÖØ-öø-ÿ]$/)?t:e>1||0==e?s().pluralize(t):s().singularize(t)}},42740:(e,t,r)=>{"use strict";function o(e,t){let r=Nova.config("translations")[e]?Nova.config("translations")[e]:e;return Object.entries(t??{}).forEach((([e,t])=>{if(e=new String(e),null===t)return void console.error(`Translation '${r}' for key '${e}' contains a null replacement.`);t=new String(t);const o=[":"+e,":"+e.toUpperCase(),":"+e.charAt(0).toUpperCase()+e.slice(1)],i=[t,t.toUpperCase(),t.charAt(0).toUpperCase()+t.slice(1)];for(let e=o.length-1;e>=0;e--)r=r.replace(o[e],i[e])})),r}r.d(t,{A:()=>o})},86681:(e,t,r)=>{"use strict";function o(e,t=100){return Promise.all([e,new Promise((e=>{setTimeout((()=>e()),t)}))]).then((e=>e[0]))}r.d(t,{A:()=>o})},43478:()=>{},65215:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726),i=r(65703),l=r(66278);const a={value:"",disabled:"",selected:""},n={__name:"ActionSelector",props:{width:{type:String,default:"auto"},pivotName:{type:String,default:null},resourceName:{},viaResource:{},viaResourceId:{},viaRelationship:{},relationshipType:{},pivotActions:{type:Object,default:()=>({name:"Pivot",actions:[]})},actions:{type:Array,default:[]},selectedResources:{type:[Array,String],default:()=>[]},endpoint:{type:String,default:null},triggerDuskAttribute:{type:String,default:null}},emits:["actionExecuted"],setup(e,{emit:t}){const r=t,n=e,s=(0,o.ref)(""),c=(0,l.Pj)(),{errors:d,actionModalVisible:u,responseModalVisible:p,openConfirmationModal:h,closeConfirmationModal:m,closeResponseModal:f,handleActionClick:v,selectedAction:g,setSelectedActionKey:y,determineActionStrategy:b,working:k,executeAction:w,availableActions:C,availablePivotActions:x,actionResponseData:N}=(0,i.d)(n,r,c);(0,o.watch)(s,(e=>{""!=e&&(y(e),b(),(0,o.nextTick)((()=>s.value="")))}));const B=(0,o.computed)((()=>[...C.value.map((e=>({value:e.uriKey,label:e.name,disabled:!1===e.authorizedToRun}))),...x.value.map((e=>({group:n.pivotName,value:e.uriKey,label:e.name,disabled:!1===e.authorizedToRun})))]));return(t,r)=>{const i=(0,o.resolveComponent)("SelectControl");return(0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,null,[B.value.length>0?((0,o.openBlock)(),(0,o.createBlock)(i,(0,o.mergeProps)({key:0},t.$attrs,{ref:"actionSelectControl",modelValue:s.value,"onUpdate:modelValue":r[0]||(r[0]=e=>s.value=e),options:B.value,size:"xs",class:{"max-w-[6rem]":"auto"===e.width,"w-full":"full"===e.width},dusk:"action-select","aria-label":t.__("Select Action")}),{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("option",a,(0,o.toDisplayString)(t.__("Actions")),1)])),_:1},16,["modelValue","options","class","aria-label"])):(0,o.createCommentVNode)("",!0),(0,o.unref)(u)?((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)((0,o.unref)(g)?.component),{key:1,class:"text-left",show:(0,o.unref)(u),working:(0,o.unref)(k),"selected-resources":e.selectedResources,"resource-name":e.resourceName,action:(0,o.unref)(g),errors:(0,o.unref)(d),onConfirm:(0,o.unref)(w),onClose:(0,o.unref)(m)},null,40,["show","working","selected-resources","resource-name","action","errors","onConfirm","onClose"])):(0,o.createCommentVNode)("",!0),(0,o.unref)(p)?((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)((0,o.unref)(N)?.modal),{key:2,show:(0,o.unref)(p),onConfirm:(0,o.unref)(f),onClose:(0,o.unref)(f),data:(0,o.unref)(N)},null,40,["show","onConfirm","onClose","data"])):(0,o.createCommentVNode)("",!0)],64)}}};const s=(0,r(66262).A)(n,[["__file","ActionSelector.vue"]])},72172:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i=Object.assign({inheritAttrs:!1},{__name:"AppLogo",setup(e){const t=(0,o.computed)((()=>Nova.config("logo")));return(e,r)=>{const i=(0,o.resolveComponent)("PassthroughLogo");return t.value?((0,o.openBlock)(),(0,o.createBlock)(i,{key:0,logo:t.value,class:(0,o.normalizeClass)(e.$attrs.class)},null,8,["logo","class"])):((0,o.openBlock)(),(0,o.createElementBlock)("svg",{key:1,class:(0,o.normalizeClass)([e.$attrs.class,"h-6"]),viewBox:"0 0 204 37",xmlns:"http://www.w3.org/2000/svg"},r[0]||(r[0]=[(0,o.createStaticVNode)('<defs><radialGradient cx="-4.619%" cy="6.646%" fx="-4.619%" fy="6.646%" r="101.342%" gradientTransform="matrix(.8299 .53351 -.5579 .79363 .03 .038)" id="a"><stop stop-color="#00FFC4" offset="0%"></stop><stop stop-color="#00E1FF" offset="100%"></stop></radialGradient></defs><g fill-rule="nonzero" fill="none"><path d="M30.343 9.99a14.757 14.757 0 0 1 .046 20.972 18.383 18.383 0 0 1-13.019 5.365A18.382 18.382 0 0 1 3.272 29.79c7.209 5.955 17.945 5.581 24.713-1.118a11.477 11.477 0 0 0 0-16.345c-4.56-4.514-11.953-4.514-16.513 0a4.918 4.918 0 0 0 0 7.006 5.04 5.04 0 0 0 7.077 0 1.68 1.68 0 0 1 2.359 0 1.639 1.639 0 0 1 0 2.333 8.4 8.4 0 0 1-11.794 0 8.198 8.198 0 0 1 0-11.674c5.861-5.805 15.366-5.805 21.229 0ZM17.37 0a18.38 18.38 0 0 1 14.097 6.538C24.257.583 13.52.958 6.756 7.653v.002a11.477 11.477 0 0 0 0 16.346c4.558 4.515 11.95 4.515 16.51 0a4.918 4.918 0 0 0 0-7.005 5.04 5.04 0 0 0-7.077 0 1.68 1.68 0 0 1-2.358 0 1.639 1.639 0 0 1 0-2.334 8.4 8.4 0 0 1 11.794 0 8.198 8.198 0 0 1 0 11.674c-5.862 5.805-15.367 5.805-21.23 0a14.756 14.756 0 0 1-.02-20.994A18.383 18.383 0 0 1 17.37 0Z" fill="url(#a)"></path><path d="M59.211 27.49a1.68 1.68 0 0 0 1.69-1.69 1.68 1.68 0 0 0-1.69-1.69h-6.88V12.306c0-1.039-.82-1.86-1.86-1.86-1.037 0-1.858.821-1.858 1.86v13.325c0 1.039.82 1.858 1.859 1.858h8.74Zm9.318-13.084c2.004 0 3.453.531 4.37 1.448.965.967 1.4 2.39 1.4 4.13v5.888c0 .99-.798 1.763-1.787 1.763-1.062 0-1.763-.749-1.763-1.52v-.026c-.893.99-2.123 1.642-3.91 1.642-2.438 0-4.441-1.4-4.441-3.959v-.048c0-2.824 2.148-4.128 5.214-4.128a9.195 9.195 0 0 1 3.163.532v-.218c0-1.521-.944-2.366-2.777-2.366a8.416 8.416 0 0 0-2.535.361 1.525 1.525 0 0 1-.53.098c-.846 0-1.521-.652-1.521-1.496 0-.635.394-1.203.989-1.425 1.16-.435 2.414-.676 4.128-.676Zm-.05 7.387c-1.567 0-2.533.628-2.533 1.786v.047c0 .99.821 1.57 2.005 1.57h-.001l.195-.004c1.541-.066 2.59-.915 2.672-2.113l.005-.151v-.653c-.628-.289-1.448-.482-2.342-.482Zm10.817 5.842c1.014 0 1.833-.82 1.833-1.835v-3.428c0-2.607 1.04-4.03 2.898-4.465.748-.17 1.375-.75 1.375-1.714 0-1.04-.652-1.787-1.785-1.787-1.088 0-1.956 1.159-2.486 2.415v-.58a1.835 1.835 0 1 0-3.67 0v9.56c0 1.013.82 1.833 1.833 1.833l.002.001Zm13.01-13.229c2.005 0 3.453.531 4.37 1.448.965.967 1.4 2.39 1.4 4.13v5.888c0 .99-.797 1.763-1.786 1.763-1.063 0-1.763-.749-1.763-1.52v-.026c-.893.99-2.123 1.643-3.911 1.643-2.438-.001-4.44-1.401-4.44-3.96v-.048c0-2.824 2.148-4.128 5.214-4.128a9.195 9.195 0 0 1 3.162.532v-.218c0-1.521-.943-2.366-2.776-2.366a8.416 8.416 0 0 0-2.535.361 1.525 1.525 0 0 1-.53.098c-.847 0-1.522-.652-1.522-1.496 0-.635.395-1.203.99-1.425 1.16-.435 2.413-.676 4.127-.676Zm-.048 7.387c-1.568 0-2.534.628-2.534 1.786v.047c0 .99.821 1.57 2.003 1.57 1.714 0 2.872-.94 2.872-2.268v-.653c-.627-.289-1.447-.482-2.341-.482Zm14.17 5.963c.99 0 1.667-.653 2.076-1.593l3.959-9.15c.072-.169.194-.555.194-.869a1.736 1.736 0 0 0-1.764-1.738c-.965 0-1.472.628-1.712 1.255l-2.825 7.556-2.775-7.508c-.267-.748-.798-1.303-1.788-1.303-.989 0-1.786.845-1.786 1.714 0 .338.097.652.194.894l3.959 9.149c.41.965 1.086 1.593 2.075 1.593h.194-.001Zm13.977-13.447c4.321 0 6.228 3.55 6.228 6.228 0 1.063-.748 1.763-1.714 1.763h-7.265c.362 1.665 1.52 2.535 3.162 2.535a4.237 4.237 0 0 0 2.607-.87 1.37 1.37 0 0 1 .894-.29c.82 0 1.423.63 1.423 1.449 0 .483-.216.846-.483 1.086-1.134.967-2.607 1.57-4.49 1.57-3.886 0-6.758-2.728-6.758-6.687v-.047c0-3.695 2.63-6.737 6.396-6.737Zm0 2.945c-1.52 0-2.51 1.086-2.8 2.753h5.528c-.217-1.642-1.183-2.753-2.728-2.753Zm11.033 10.381c1.014 0 1.833-.82 1.833-1.835V11.556a1.834 1.834 0 0 0-3.668 0V25.8c0 1.014.82 1.833 1.833 1.833l.002.003Zm14.75 0c1.013 0 1.833-.82 1.833-1.835v-9.053l7.435 9.753c.507.653 1.039 1.086 1.93 1.086h.123c1.037 0 1.858-.82 1.858-1.858V12.283a1.835 1.835 0 0 0-3.67 0v8.713l-7.17-9.415c-.505-.651-1.037-1.086-1.93-1.086h-.386c-1.038 0-1.859.821-1.859 1.859v13.445c0 1.014.82 1.836 1.834 1.836h.001Zm23.244-13.326c4.007 0 6.976 2.97 6.976 6.687v.048c0 3.719-2.993 6.735-7.024 6.735-4.007 0-6.976-2.97-6.976-6.686v-.047c0-3.719 2.993-6.737 7.024-6.737Zm-.048 3.163c-2.1 0-3.355 1.617-3.355 3.524v.048c0 1.907 1.375 3.573 3.403 3.573 2.1 0 3.355-1.617 3.355-3.524v-.049c0-1.905-1.375-3.572-3.403-3.572Zm14.798 10.284c.99 0 1.664-.653 2.076-1.593l3.958-9.15c.072-.169.195-.555.195-.869a1.736 1.736 0 0 0-1.764-1.738c-.966 0-1.473.628-1.713 1.255l-2.825 7.556-2.777-7.508c-.264-.748-.796-1.303-1.786-1.303-.989 0-1.786.845-1.786 1.714 0 .338.097.652.194.894l3.959 9.149c.41.965 1.086 1.593 2.075 1.593h.194Zm13.76-13.35c2.003 0 3.451.531 4.368 1.448.967.967 1.4 2.39 1.4 4.13v5.888c0 .99-.796 1.763-1.786 1.763-1.061 0-1.761-.749-1.761-1.52v-.026c-.894.99-2.126 1.642-3.91 1.642-2.44 0-4.444-1.4-4.444-3.959v-.048c0-2.824 2.149-4.128 5.215-4.128a9.195 9.195 0 0 1 3.162.532v-.218c0-1.521-.942-2.366-2.776-2.366a8.416 8.416 0 0 0-2.535.361 1.52 1.52 0 0 1-.53.098c-.845 0-1.522-.652-1.522-1.496 0-.636.395-1.204.99-1.425 1.159-.435 2.415-.676 4.129-.676Zm-.049 7.387c-1.57 0-2.535.628-2.535 1.786v.047c0 .99.821 1.57 2.004 1.57 1.714 0 2.873-.94 2.873-2.268v-.653c-.628-.289-1.449-.482-2.342-.482Z" class="fill-current text-gray-600 dark:text-white"></path></g>',2)]),2))}}});const l=(0,r(66262).A)(i,[["__file","AppLogo.vue"]])},39383:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i=["src"],l={__name:"Avatar",props:{src:{type:String},rounded:{type:Boolean,default:!0},small:{type:Boolean},medium:{type:Boolean},large:{type:Boolean}},setup(e){const t=e,r=(0,o.computed)((()=>[t.small&&"w-6 h-6",t.medium&&!t.small&&!t.large&&"w-8 h-8",t.large&&"w-12 h-12",t.rounded&&"rounded-full"]));return(t,l)=>((0,o.openBlock)(),(0,o.createElementBlock)("img",{src:e.src,class:(0,o.normalizeClass)(r.value)},null,10,i))}};const a=(0,r(66262).A)(l,[["__file","Avatar.vue"]])},62953:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i=Object.assign({inheritAttrs:!1},{__name:"Backdrop",props:{show:{type:Boolean,default:!1}},setup(e){const t=(0,o.ref)(),r=()=>{t.value=window.scrollY};return(0,o.onMounted)((()=>{r(),document.addEventListener("scroll",r)})),(0,o.onBeforeUnmount)((()=>{document.removeEventListener("scroll",r)})),(r,i)=>(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createElementBlock)("div",(0,o.mergeProps)(r.$attrs,{class:"absolute inset-0 h-full",style:{top:`${t.value}px`}}),null,16)),[[o.vShow,e.show]])}});const l=(0,r(66262).A)(i,[["__file","Backdrop.vue"]])},57091:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={__name:"Badge",props:{label:{type:[Boolean,String],required:!1},extraClasses:{type:[Array,String],required:!1}},setup:e=>(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("span",{class:(0,o.normalizeClass)(["inline-flex items-center whitespace-nowrap min-h-6 px-2 rounded-full uppercase text-xs font-bold",e.extraClasses])},[(0,o.renderSlot)(t.$slots,"icon"),(0,o.renderSlot)(t.$slots,"default",{},(()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.label),1)]))],2))};const l=(0,r(66262).A)(i,[["__file","Badge.vue"]])},82958:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"h-4 inline-flex items-center justify-center font-bold rounded-full px-2 text-mono text-xs ml-1 bg-primary-100 text-primary-800 dark:bg-primary-500 dark:text-gray-800"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("span",i,[(0,o.renderSlot)(e.$slots,"default")])}],["__file","CircleBadge.vue"]])},95564:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function l(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach((function(t){a(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function a(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const n={emits:["change"],props:{resourceName:{type:String,required:!0},filter:Object,option:Object,label:{default:"name"}},methods:{labelFor(e){return e[this.label]||""},updateCheckedState(e,t){let r=l(l({},this.filter.currentValue),{},{[e]:t});this.$store.commit(`${this.resourceName}/updateFilterState`,{filterClass:this.filter.class,value:r}),this.$emit("change")}},computed:{isChecked(){return 1==this.$store.getters[`${this.resourceName}/filterOptionValue`](this.filter.class,this.option.value)}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("CheckboxWithLabel");return(0,o.openBlock)(),(0,o.createBlock)(n,{dusk:`${r.option.value}-checkbox`,checked:a.isChecked,onInput:t[0]||(t[0]=e=>a.updateCheckedState(r.option.value,e.target.checked))},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(a.labelFor(r.option)),1)])),_:1},8,["dusk","checked"])}],["__file","BooleanOption.vue"]])},1780:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726),i=r(38221),l=r.n(i);const a={__name:"CopyButton",props:{rounded:{type:Boolean,default:!0},withIcon:{type:Boolean,default:!0}},setup(e){const t=(0,o.ref)(!1),r=l()((()=>{t.value=!t.value,setTimeout((()=>t.value=!t.value),2e3)}),2e3,{leading:!0,trailing:!1});return(i,l)=>{const a=(0,o.resolveComponent)("CopyIcon");return(0,o.openBlock)(),(0,o.createElementBlock)("button",{type:"button",onClick:l[0]||(l[0]=(...e)=>(0,o.unref)(r)&&(0,o.unref)(r)(...e)),class:(0,o.normalizeClass)(["inline-flex items-center px-2 space-x-1 -mx-2 text-gray-500 dark:text-gray-400 hover:bg-gray-100 hover:text-gray-500 active:text-gray-600 dark:hover:bg-gray-900",{"rounded-lg":!e.rounded,"rounded-full":e.rounded}])},[(0,o.renderSlot)(i.$slots,"default"),e.withIcon?((0,o.openBlock)(),(0,o.createBlock)(a,{key:0,copied:t.value},null,8,["copied"])):(0,o.createCommentVNode)("",!0)],2)}}};const n=(0,r(66262).A)(a,[["__file","CopyButton.vue"]])},77518:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function l(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach((function(t){a(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function a(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const n=Object.assign({inheritAttrs:!1},{__name:"InertiaButton",props:{size:{type:String,default:"md",validator:e=>["sm","md"].includes(e)},variant:{type:String,default:"button",validator:e=>["button","outline"].includes(e)}},setup(e){const t=e,r=(0,o.computed)((()=>"button"===t.variant?{"shadow rounded focus:outline-none ring-primary-200 dark:ring-gray-600 focus:ring bg-primary-500 hover:bg-primary-400 active:bg-primary-600 text-white dark:text-gray-800 inline-flex items-center font-bold":!0,"px-4 h-9 text-sm":"md"===t.size,"px-3 h-7 text-xs":"sm"===t.size}:"focus:outline-none ring-primary-200 dark:ring-gray-600 focus:ring-2 rounded border-2 border-gray-200 dark:border-gray-500 hover:border-primary-500 active:border-primary-400 dark:hover:border-gray-400 dark:active:border-gray-300 bg-white dark:bg-transparent text-primary-500 dark:text-gray-400 px-3 h-9 inline-flex items-center font-bold"));return(e,t)=>{const i=(0,o.resolveComponent)("Link");return(0,o.openBlock)(),(0,o.createBlock)(i,(0,o.mergeProps)(l(l({},e.$props),e.$attrs),{class:r.value}),{default:(0,o.withCtx)((()=>[(0,o.renderSlot)(e.$slots,"default")])),_:3},16,["class"])}}});const s=(0,r(66262).A)(n,[["__file","InertiaButton.vue"]])},23105:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726),i=r(74640);const l={type:"button",class:"space-x-1 cursor-pointer focus:outline-none focus:ring ring-primary-200 dark:ring-gray-600 focus:ring-offset-4 dark:focus:ring-offset-gray-800 rounded-lg mx-auto text-primary-500 font-bold link-default px-3 rounded-b-lg flex items-center"},a={__name:"InvertedButton",props:{iconType:{type:String,default:"plus-circle"}},setup:e=>(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("button",l,[(0,o.createVNode)((0,o.unref)(i.Icon),{name:e.iconType,class:"inline-block"},null,8,["name"]),(0,o.createElementVNode)("span",null,[(0,o.renderSlot)(t.$slots,"default")])]))};const n=(0,r(66262).A)(a,[["__file","InvertedButton.vue"]])},61070:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"relative overflow-hidden bg-white dark:bg-gray-800 rounded-lg shadow"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.renderSlot)(e.$slots,"default")])}],["__file","Card.vue"]])},40506:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:{card:{type:Object,required:!0},resource:{type:Object,required:!1},dashboard:{type:String,required:!1},resourceName:{type:String,default:""},resourceId:{type:[Number,String],default:""},lens:{lens:String,default:""}},computed:{widthClass(){return{full:"md:col-span-12","1/3":"md:col-span-4","1/2":"md:col-span-6","1/4":"md:col-span-3","2/3":"md:col-span-8","3/4":"md:col-span-9"}[this.card.width]},heightClass(){return"fixed"==this.card.height?"min-h-40":""}}};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){return(0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(r.card.component),{class:(0,o.normalizeClass)([[a.widthClass,a.heightClass],"h-full"]),key:`${r.card.component}.${r.card.uriKey}`,card:r.card,dashboard:r.dashboard,resource:r.resource,resourceName:r.resourceName,resourceId:r.resourceId,lens:r.lens},null,8,["class","card","dashboard","resource","resourceName","resourceId","lens"])}],["__file","CardWrapper.vue"]])},90581:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={key:1,class:"grid md:grid-cols-12 gap-6"};var l=r(35229),a=r(70393);const n={mixins:[l.pJ],props:{cards:Array,resource:{type:Object,required:!1},dashboard:{type:String,required:!1},resourceName:{type:String,default:""},resourceId:{type:[Number,String],default:""},onlyOnDetail:{type:Boolean,default:!1},lens:{lens:String,default:""}},data:()=>({collapsed:!1}),computed:{filteredCards(){return this.onlyOnDetail?this.cards.filter((e=>1==e.onlyOnDetail)):this.cards.filter((e=>0==e.onlyOnDetail))},localStorageKey(){let e=this.resourceName;return e=(0,a.A)(this.dashboard)?`dashboard.${this.dashboard}`:(0,a.A)(this.lens)?`lens.${e}.${this.lens}`:(0,a.A)(this.resourceId)?`resource.${e}.${this.resourceId}`:`resource.${e}`,`nova.cards.${e}.collapsed`}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("CollapseButton"),c=(0,o.resolveComponent)("CardWrapper");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[n.filteredCards.length>1?((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:0,onClick:t[0]||(t[0]=(...t)=>e.toggleCollapse&&e.toggleCollapse(...t)),class:"md:hidden h-8 py-3 mb-3 uppercase tracking-widest font-bold text-xs inline-flex items-center justify-center focus:outline-none focus:ring-primary-200 border-1 border-primary-500 focus:ring focus:ring-offset-4 focus:ring-offset-gray-100 dark:ring-gray-600 dark:focus:ring-offset-gray-900 rounded"},[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(e.collapsed?e.__("Show Cards"):e.__("Hide Cards")),1),(0,o.createVNode)(s,{class:"ml-1",collapsed:e.collapsed},null,8,["collapsed"])])):(0,o.createCommentVNode)("",!0),n.filteredCards.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(n.filteredCards,(t=>(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(c,{card:t,dashboard:r.dashboard,resource:r.resource,"resource-name":r.resourceName,"resource-id":r.resourceId,key:`${t.component}.${t.uriKey}`,lens:r.lens},null,8,["card","dashboard","resource","resource-name","resource-id","lens"])),[[o.vShow,!e.collapsed]]))),128))])):(0,o.createCommentVNode)("",!0)])}],["__file","Cards.vue"]])},29433:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>k});var o=r(29726);const i={class:"flex justify-center items-center"},l={class:"w-full"},a={class:"md:grid md:grid-cols-2"},n={class:"border-r border-b border-gray-200 dark:border-gray-700"},s=["href"],c={class:"border-b border-gray-200 dark:border-gray-700"},d=["href"],u={class:"border-r border-b border-gray-200 dark:border-gray-700"},p=["href"],h={class:"border-b border-gray-200 dark:border-gray-700"},m=["href"],f={class:"border-r md:border-b-0 border-b border-gray-200 dark:border-gray-700"},v=["href"],g={class:"md:border-b-0 border-b border-gray-200 dark:border-gray-700"},y=["href"],b=Object.assign({name:"Help"},{__name:"HelpCard",props:{card:Object},setup(e){const t=(0,o.computed)((()=>{const e=Nova.config("version").split(".");return e.splice(-2),`${e}.0`}));function r(e){return`https://nova.laravel.com/docs/${t.value}/${e}`}return(e,t)=>{const b=(0,o.resolveComponent)("Heading"),k=(0,o.resolveComponent)("Card");return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("div",l,[(0,o.createVNode)(b,null,{default:(0,o.withCtx)((()=>t[0]||(t[0]=[(0,o.createTextVNode)("Get Started")]))),_:1}),t[19]||(t[19]=(0,o.createElementVNode)("p",{class:"leading-tight mt-3"}," Welcome to Nova! Get familiar with Nova and explore its features in the documentation: ",-1)),(0,o.createVNode)(k,{class:"mt-8"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",a,[(0,o.createElementVNode)("div",n,[(0,o.createElementVNode)("a",{href:r("resources"),class:"no-underline flex p-6"},[t[3]||(t[3]=(0,o.createElementVNode)("div",{class:"flex justify-center w-11 shrink-0 mr-6"},[(0,o.createElementVNode)("svg",{class:"text-primary-500 dark:text-primary-600",xmlns:"http://www.w3.org/2000/svg",width:"40",height:"40",viewBox:"0 0 40 40"},[(0,o.createElementVNode)("path",{class:"fill-current",d:"M31.51 25.86l7.32 7.31c1.0110617 1.0110616 1.4059262 2.4847161 1.035852 3.865852-.3700742 1.3811359-1.4488641 2.4599258-2.83 2.83-1.3811359.3700742-2.8547904-.0247903-3.865852-1.035852l-7.31-7.32c-7.3497931 4.4833975-16.89094893 2.7645226-22.21403734-4.0019419-5.3230884-6.7664645-4.74742381-16.4441086 1.34028151-22.53181393C11.0739495-1.11146115 20.7515936-1.68712574 27.5180581 3.63596266 34.2845226 8.95905107 36.0033975 18.5002069 31.52 25.85l-.01.01zm-3.99 4.5l7.07 7.05c.7935206.6795536 1.9763883.6338645 2.7151264-.1048736.7387381-.7387381.7844272-1.9216058.1048736-2.7151264l-7.06-7.07c-.8293081 1.0508547-1.7791453 2.0006919-2.83 2.83v.01zM17 32c8.2842712 0 15-6.7157288 15-15 0-8.28427125-6.7157288-15-15-15C8.71572875 2 2 8.71572875 2 17c0 8.2842712 6.71572875 15 15 15zm0-2C9.82029825 30 4 24.1797017 4 17S9.82029825 4 17 4c7.1797017 0 13 5.8202983 13 13s-5.8202983 13-13 13zm0-2c6.0751322 0 11-4.9248678 11-11S23.0751322 6 17 6 6 10.9248678 6 17s4.9248678 11 11 11z"})])],-1)),(0,o.createElementVNode)("div",null,[(0,o.createVNode)(b,{level:3},{default:(0,o.withCtx)((()=>t[1]||(t[1]=[(0,o.createTextVNode)("Resources")]))),_:1}),t[2]||(t[2]=(0,o.createElementVNode)("p",{class:"leading-normal mt-3"}," Nova's resource manager allows you to quickly view and manage your Eloquent model records directly from Nova's intuitive interface. ",-1))])],8,s)]),(0,o.createElementVNode)("div",c,[(0,o.createElementVNode)("a",{href:r("actions/defining-actions.html"),class:"no-underline flex p-6"},[t[6]||(t[6]=(0,o.createElementVNode)("div",{class:"flex justify-center w-11 shrink-0 mr-6"},[(0,o.createElementVNode)("svg",{class:"text-primary-500 dark:text-primary-600",xmlns:"http://www.w3.org/2000/svg",width:"44",height:"44",viewBox:"0 0 44 44"},[(0,o.createElementVNode)("path",{class:"fill-current",d:"M22 44C9.8497355 44 0 34.1502645 0 22S9.8497355 0 22 0s22 9.8497355 22 22-9.8497355 22-22 22zm0-2c11.045695 0 20-8.954305 20-20S33.045695 2 22 2 2 10.954305 2 22s8.954305 20 20 20zm3-24h5c.3638839-.0007291.6994429.1962627.8761609.5143551.176718.3180924.1666987.707072-.0261609 1.0156449l-10 16C20.32 36.38 19 36 19 35v-9h-5c-.3638839.0007291-.6994429-.1962627-.8761609-.5143551-.176718-.3180924-.1666987-.707072.0261609-1.0156449l10-16C23.68 7.62 25 8 25 9v9zm3.2 2H24c-.5522847 0-1-.4477153-1-1v-6.51L15.8 24H20c.5522847 0 1 .4477153 1 1v6.51L28.2 20z"})])],-1)),(0,o.createElementVNode)("div",null,[(0,o.createVNode)(b,{level:3},{default:(0,o.withCtx)((()=>t[4]||(t[4]=[(0,o.createTextVNode)("Actions")]))),_:1}),t[5]||(t[5]=(0,o.createElementVNode)("p",{class:"leading-normal mt-3"}," Actions perform tasks on a single record or an entire batch of records. Have an action that takes a while? No problem. Nova can queue them using Laravel's powerful queue system. ",-1))])],8,d)]),(0,o.createElementVNode)("div",u,[(0,o.createElementVNode)("a",{href:r("filters/defining-filters.html"),class:"no-underline flex p-6"},[t[9]||(t[9]=(0,o.createElementVNode)("div",{class:"flex justify-center w-11 shrink-0 mr-6"},[(0,o.createElementVNode)("svg",{class:"text-primary-500 dark:text-primary-600",xmlns:"http://www.w3.org/2000/svg",width:"38",height:"38",viewBox:"0 0 38 38"},[(0,o.createElementVNode)("path",{class:"fill-current",d:"M36 4V2H2v6.59l13.7 13.7c.1884143.1846305.296243.4362307.3.7v11.6l6-6v-5.6c.003757-.2637693.1115857-.5153695.3-.7L36 8.6V6H19c-.5522847 0-1-.44771525-1-1s.4477153-1 1-1h17zM.3 9.7C.11158574 9.51536954.00375705 9.26376927 0 9V1c0-.55228475.44771525-1 1-1h36c.5522847 0 1 .44771525 1 1v8c-.003757.26376927-.1115857.51536954-.3.7L24 23.42V29c-.003757.2637693-.1115857.5153695-.3.7l-8 8c-.2857003.2801197-.7108712.3629755-1.0808485.210632C14.2491743 37.7582884 14.0056201 37.4000752 14 37V23.4L.3 9.71V9.7z"})])],-1)),(0,o.createElementVNode)("div",null,[(0,o.createVNode)(b,{level:3},{default:(0,o.withCtx)((()=>t[7]||(t[7]=[(0,o.createTextVNode)("Filters")]))),_:1}),t[8]||(t[8]=(0,o.createElementVNode)("p",{class:"leading-normal mt-3"}," Write custom filters for your resource indexes to offer your users quick glances at different segments of your data. ",-1))])],8,p)]),(0,o.createElementVNode)("div",h,[(0,o.createElementVNode)("a",{href:r("lenses/defining-lenses.html"),class:"no-underline flex p-6"},[t[12]||(t[12]=(0,o.createElementVNode)("div",{class:"flex justify-center w-11 shrink-0 mr-6"},[(0,o.createElementVNode)("svg",{class:"text-primary-500 dark:text-primary-600",xmlns:"http://www.w3.org/2000/svg",width:"36",height:"36",viewBox:"0 0 36 36"},[(0,o.createElementVNode)("path",{class:"fill-current",d:"M4 8C1.790861 8 0 6.209139 0 4s1.790861-4 4-4 4 1.790861 4 4-1.790861 4-4 4zm0-2c1.1045695 0 2-.8954305 2-2s-.8954305-2-2-2-2 .8954305-2 2 .8954305 2 2 2zm0 16c-2.209139 0-4-1.790861-4-4s1.790861-4 4-4 4 1.790861 4 4-1.790861 4-4 4zm0-2c1.1045695 0 2-.8954305 2-2s-.8954305-2-2-2-2 .8954305-2 2 .8954305 2 2 2zm0 16c-2.209139 0-4-1.790861-4-4s1.790861-4 4-4 4 1.790861 4 4-1.790861 4-4 4zm0-2c1.1045695 0 2-.8954305 2-2s-.8954305-2-2-2-2 .8954305-2 2 .8954305 2 2 2zm9-31h22c.5522847 0 1 .44771525 1 1s-.4477153 1-1 1H13c-.5522847 0-1-.44771525-1-1s.4477153-1 1-1zm0 14h22c.5522847 0 1 .4477153 1 1s-.4477153 1-1 1H13c-.5522847 0-1-.4477153-1-1s.4477153-1 1-1zm0 14h22c.5522847 0 1 .4477153 1 1s-.4477153 1-1 1H13c-.5522847 0-1-.4477153-1-1s.4477153-1 1-1z"})])],-1)),(0,o.createElementVNode)("div",null,[(0,o.createVNode)(b,{level:3},{default:(0,o.withCtx)((()=>t[10]||(t[10]=[(0,o.createTextVNode)("Lenses")]))),_:1}),t[11]||(t[11]=(0,o.createElementVNode)("p",{class:"leading-normal mt-3"}," Need to customize a resource list a little more than a filter can provide? No problem. Add lenses to your resource to take full control over the entire Eloquent query. ",-1))])],8,m)]),(0,o.createElementVNode)("div",f,[(0,o.createElementVNode)("a",{href:r("metrics/defining-metrics.html"),class:"no-underline flex p-6"},[t[15]||(t[15]=(0,o.createElementVNode)("div",{class:"flex justify-center w-11 shrink-0 mr-6"},[(0,o.createElementVNode)("svg",{class:"text-primary-500 dark:text-primary-600",xmlns:"http://www.w3.org/2000/svg",width:"37",height:"36",viewBox:"0 0 37 36"},[(0,o.createElementVNode)("path",{class:"fill-current",d:"M2 27h3c1.1045695 0 2 .8954305 2 2v5c0 1.1045695-.8954305 2-2 2H2c-1.1045695 0-2-.8954305-2-2v-5c0-1.1.9-2 2-2zm0 2v5h3v-5H2zm10-11h3c1.1045695 0 2 .8954305 2 2v14c0 1.1045695-.8954305 2-2 2h-3c-1.1045695 0-2-.8954305-2-2V20c0-1.1.9-2 2-2zm0 2v14h3V20h-3zM22 9h3c1.1045695 0 2 .8954305 2 2v23c0 1.1045695-.8954305 2-2 2h-3c-1.1045695 0-2-.8954305-2-2V11c0-1.1.9-2 2-2zm0 2v23h3V11h-3zM32 0h3c1.1045695 0 2 .8954305 2 2v32c0 1.1045695-.8954305 2-2 2h-3c-1.1045695 0-2-.8954305-2-2V2c0-1.1.9-2 2-2zm0 2v32h3V2h-3z"})])],-1)),(0,o.createElementVNode)("div",null,[(0,o.createVNode)(b,{level:3},{default:(0,o.withCtx)((()=>t[13]||(t[13]=[(0,o.createTextVNode)("Metrics")]))),_:1}),t[14]||(t[14]=(0,o.createElementVNode)("p",{class:"leading-normal mt-3"}," Nova makes it painless to quickly display custom metrics for your application. To put the cherry on top, weve included query helpers to make it all easy as pie. ",-1))])],8,v)]),(0,o.createElementVNode)("div",g,[(0,o.createElementVNode)("a",{href:r("customization/cards.html"),class:"no-underline flex p-6"},[t[18]||(t[18]=(0,o.createElementVNode)("div",{class:"flex justify-center w-11 shrink-0 mr-6"},[(0,o.createElementVNode)("svg",{class:"text-primary-500 dark:text-primary-600",xmlns:"http://www.w3.org/2000/svg",width:"36",height:"36",viewBox:"0 0 36 36"},[(0,o.createElementVNode)("path",{class:"fill-current",d:"M29 7h5c.5522847 0 1 .44771525 1 1s-.4477153 1-1 1h-5v5c0 .5522847-.4477153 1-1 1s-1-.4477153-1-1V9h-5c-.5522847 0-1-.44771525-1-1s.4477153-1 1-1h5V2c0-.55228475.4477153-1 1-1s1 .44771525 1 1v5zM4 0h8c2.209139 0 4 1.790861 4 4v8c0 2.209139-1.790861 4-4 4H4c-2.209139 0-4-1.790861-4-4V4c0-2.209139 1.790861-4 4-4zm0 2c-1.1045695 0-2 .8954305-2 2v8c0 1.1.9 2 2 2h8c1.1045695 0 2-.8954305 2-2V4c0-1.1045695-.8954305-2-2-2H4zm20 18h8c2.209139 0 4 1.790861 4 4v8c0 2.209139-1.790861 4-4 4h-8c-2.209139 0-4-1.790861-4-4v-8c0-2.209139 1.790861-4 4-4zm0 2c-1.1045695 0-2 .8954305-2 2v8c0 1.1.9 2 2 2h8c1.1045695 0 2-.8954305 2-2v-8c0-1.1045695-.8954305-2-2-2h-8zM4 20h8c2.209139 0 4 1.790861 4 4v8c0 2.209139-1.790861 4-4 4H4c-2.209139 0-4-1.790861-4-4v-8c0-2.209139 1.790861-4 4-4zm0 2c-1.1045695 0-2 .8954305-2 2v8c0 1.1.9 2 2 2h8c1.1045695 0 2-.8954305 2-2v-8c0-1.1045695-.8954305-2-2-2H4z"})])],-1)),(0,o.createElementVNode)("div",null,[(0,o.createVNode)(b,{level:3},{default:(0,o.withCtx)((()=>t[16]||(t[16]=[(0,o.createTextVNode)("Cards")]))),_:1}),t[17]||(t[17]=(0,o.createElementVNode)("p",{class:"leading-normal mt-3"}," Nova offers CLI generators for scaffolding your own custom cards. Well give you a Vue component and infinite possibilities. ",-1))])],8,y)])])])),_:1})])])}}});const k=(0,r(66262).A)(b,[["__file","HelpCard.vue"]])},63136:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i=["disabled","checked"],l={__name:"Checkbox",props:{checked:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:["input"],setup:e=>(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("input",{type:"checkbox",class:"checkbox",disabled:e.disabled,checked:e.checked,onChange:r[0]||(r[0]=e=>t.$emit("input",e)),onClick:r[1]||(r[1]=(0,o.withModifiers)((()=>{}),["stop"]))},null,40,i))};const a=(0,r(66262).A)(l,[["__file","Checkbox.vue"]])},35893:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"flex items-center select-none space-x-2"};const l={emits:["input"],props:{checked:Boolean,name:{type:String,required:!1},disabled:{type:Boolean,default:!1}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("Checkbox");return(0,o.openBlock)(),(0,o.createElementBlock)("label",i,[(0,o.createVNode)(s,{onInput:t[0]||(t[0]=t=>e.$emit("input",t)),checked:r.checked,name:r.name,disabled:r.disabled},null,8,["checked","name","disabled"]),(0,o.renderSlot)(e.$slots,"default")])}],["__file","CheckboxWithLabel.vue"]])},65764:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:{collapsed:{type:Boolean,default:!1}}};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("IconArrow");return(0,o.openBlock)(),(0,o.createBlock)(n,{class:(0,o.normalizeClass)(["transform",{"ltr:-rotate-90 rtl:rotate-90":r.collapsed}])},null,8,["class"])}],["__file","CollapseButton.vue"]])},96813:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726),i=r(66278),l=r(1882),a=r.n(l);const n={__name:"ConfirmsPassword",props:{modal:{default:"ConfirmsPasswordModal"},required:{type:Boolean,default:!0},mode:{type:String,default:"timeout",validator:(e,t)=>["always","timeout"].includes(e)},title:{type:[String,null],default:null},content:{type:[String,null],default:null},button:{type:[String,null],default:null}},emits:["confirmed"],setup(e,{emit:t}){const r=t,l=e,{confirming:n,confirmed:s,confirmingPassword:c,passwordConfirmed:d,cancelConfirming:u}=function(e){const t=(0,i.Pj)(),r=(0,o.ref)(!1),l=(0,o.computed)((()=>t.getters.currentUserPasswordConfirmed)),n=()=>{r.value=!1,e("confirmed"),t.dispatch("passwordConfirmed")};return{confirming:r,confirmed:l,confirmingPassword:({verifyUsing:e,confirmedUsing:o,mode:i,required:s})=>(null==l&&t.dispatch("confirmedPasswordStatus"),null==o&&(o=()=>n()),"always"===i?(r.value=!0,void(a()(e)&&e())):!1===s||!0===l.value?(r.value=!1,void(a()(o)&&o())):(r.value=!0,void(a()(e)&&e()))),passwordConfirmed:n,cancelConfirming:()=>{r.value=!1,t.dispatch("passwordUnconfirmed")}}}(r),p=e=>{c({mode:l.mode,required:l.required})};return(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("span",null,[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(e.modal),{show:(0,o.unref)(n),title:e.title,content:e.content,button:e.button,onConfirm:(0,o.unref)(d),onClose:(0,o.unref)(u)},null,40,["show","title","content","button","onConfirm","onClose"])),!(0,o.unref)(s)&&!t.$slots.unconfirmed||(0,o.unref)(s)&&!t.$slots.confirmed?((0,o.openBlock)(),(0,o.createElementBlock)("span",{key:0,onClick:(0,o.withModifiers)(p,["stop"])},[(0,o.renderSlot)(t.$slots,"default")])):(0,o.createCommentVNode)("",!0),(0,o.unref)(s)?(0,o.renderSlot)(t.$slots,"confirmed",{key:2}):((0,o.openBlock)(),(0,o.createElementBlock)("span",{key:1,onClick:(0,o.withModifiers)(p,["stop"])},[(0,o.renderSlot)(t.$slots,"unconfirmed")]))]))}};const s=(0,r(66262).A)(n,[["__file","ConfirmsPassword.vue"]])},89042:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>v});var o=r(29726),i=r(94394),l=r.n(i),a=r(90179),n=r.n(a);function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function c(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){d(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function d(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const u=["data-disabled"],p=["label"],h=["selected"],m=["selected"],f=Object.assign({inheritAttrs:!1},{__name:"MultiSelectControl",props:(0,o.mergeModels)({hasError:{type:Boolean,default:!1},label:{default:"label"},options:{type:Array,default:[]},disabled:{type:Boolean,default:!1},size:{type:String,default:"md",validator:e=>["xxs","xs","sm","md"].includes(e)}},{modelValue:{},modelModifiers:{}}),emits:(0,o.mergeModels)(["selected"],["update:modelValue"]),setup(e,{emit:t}){const r=t,i=e,a=(0,o.useModel)(e,"modelValue"),s=(0,o.useAttrs)(),d=((0,o.useTemplateRef)("selectControl"),e=>i.label instanceof Function?i.label(e):e[i.label]),f=e=>c(c({},e.attrs||{}),{value:e.value}),v=e=>a.value.indexOf(e.value)>-1,g=e=>{let t=Object.values(e.target.options).filter((e=>e.selected)).map((e=>e.value)),o=(i.options??[]).filter((e=>t.includes(e.value)||t.includes(e.value.toString())));a.value=o.map((e=>e.value)),r("selected",o)},y=(0,o.computed)((()=>n()(s,["class"]))),b=(0,o.computed)((()=>l()(i.options,(e=>e.group||""))));return(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(["flex relative",t.$attrs.class])},[(0,o.createElementVNode)("select",(0,o.mergeProps)(y.value,{ref:"selectControl",onChange:g,class:["w-full min-h-[10rem] block form-control form-control-bordered form-input",{"h-8 text-xs":"sm"===e.size,"h-7 text-xs":"xs"===e.size,"h-6 text-xs":"xxs"===e.size,"form-control-bordered-error":e.hasError,"form-input-disabled":e.disabled}],multiple:"","data-disabled":e.disabled?"true":null}),[(0,o.renderSlot)(t.$slots,"default"),((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(b.value,((e,t)=>((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,null,[t?((0,o.openBlock)(),(0,o.createElementBlock)("optgroup",{label:t,key:t},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("option",(0,o.mergeProps)({ref_for:!0},f(e),{key:e.value,selected:v(e)}),(0,o.toDisplayString)(d(e)),17,h)))),128))],8,p)):((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,{key:1},(0,o.renderList)(e,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("option",(0,o.mergeProps)({ref_for:!0},f(e),{key:e.value,selected:v(e)}),(0,o.toDisplayString)(d(e)),17,m)))),128))],64)))),256))],16,u)],2))}});const v=(0,r(66262).A)(f,[["__file","MultiSelectControl.vue"]])},99138:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>g});var o=r(29726),i=r(94394),l=r.n(i),a=r(90179),n=r.n(a);function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function c(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){d(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function d(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const u=["value","disabled","data-disabled"],p=["label"],h=["selected","disabled"],m=["selected","disabled"],f={class:"pointer-events-none absolute inset-y-0 right-[11px] flex items-center"},v=Object.assign({inheritAttrs:!1},{__name:"SelectControl",props:(0,o.mergeModels)({hasError:{type:Boolean,default:!1},label:{default:"label"},value:{default:null},options:{type:Array,default:[]},disabled:{type:Boolean,default:!1},size:{type:String,default:"md",validator:e=>["xxs","xs","sm","md"].includes(e)}},{modelValue:{},modelModifiers:{}}),emits:(0,o.mergeModels)(["selected"],["update:modelValue"]),setup(e,{expose:t,emit:r}){const i=r,a=e,s=(0,o.useModel)(e,"modelValue"),d=(0,o.useAttrs)(),v=(0,o.useTemplateRef)("selectControl");(0,o.onBeforeMount)((()=>{null==s.value&&null!=a.value&&(s.value=a.value)}));const g=e=>a.label instanceof Function?a.label(e):e[a.label],y=e=>c(c({},e.attrs||{}),{value:e.value}),b=e=>e.value==s.value,k=e=>!0===e.disabled,w=e=>{let t=e.target.value,r=a.options.find((e=>t===e.value||t===e.value.toString()));s.value=r?.value??a.value,i("selected",r)},C=(0,o.computed)((()=>n()(d,["class"]))),x=(0,o.computed)((()=>l()(a.options,(e=>e.group||""))));return t({resetSelection:()=>{v.value.selectedIndex=0}}),(t,r)=>{const i=(0,o.resolveComponent)("IconArrow");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(["flex relative",t.$attrs.class])},[(0,o.createElementVNode)("select",(0,o.mergeProps)(C.value,{value:s.value,onChange:w,class:["w-full block form-control form-control-bordered form-input",{"h-8 text-xs":"sm"===e.size,"h-7 text-xs":"xs"===e.size,"h-6 text-xs":"xxs"===e.size,"form-control-bordered-error":e.hasError,"form-input-disabled":e.disabled}],ref:"selectControl",disabled:e.disabled,"data-disabled":e.disabled?"true":null}),[(0,o.renderSlot)(t.$slots,"default"),((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(x.value,((e,t)=>((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,null,[t?((0,o.openBlock)(),(0,o.createElementBlock)("optgroup",{label:t,key:t},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("option",(0,o.mergeProps)({ref_for:!0},y(e),{key:e.value,selected:b(e),disabled:k(e)}),(0,o.toDisplayString)(g(e)),17,h)))),128))],8,p)):((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,{key:1},(0,o.renderList)(e,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("option",(0,o.mergeProps)({ref_for:!0},y(e),{key:e.value,selected:b(e),disabled:k(e)}),(0,o.toDisplayString)(g(e)),17,m)))),128))],64)))),256))],16,u),(0,o.createElementVNode)("span",f,[(0,o.createVNode)(i)])],2)}}});const g=(0,r(66262).A)(v,[["__file","SelectControl.vue"]])},72522:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>v});var o=r(29726);const i=["data-form-unique-id"],l={class:"space-y-4"},a={class:"flex flex-col md:flex-row md:items-center justify-center md:justify-end space-y-2 md:space-y-0 md:space-x-3"};var n=r(35229),s=r(66278),c=r(74640),d=r(15101),u=r.n(d);function p(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function h(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?p(Object(r),!0).forEach((function(t){m(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):p(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function m(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const f={components:{Button:c.Button},emits:["resource-created","resource-created-and-adding-another","create-cancelled","update-form-status","finished-loading"],mixins:[n.B5,n.qR,n.Ye],props:h({mode:{type:String,default:"form",validator:e=>["modal","form"].includes(e)},fromResourceId:{default:null}},(0,n.rr)(["resourceName","viaResource","viaResourceId","viaRelationship","shouldOverrideMeta"])),data:()=>({relationResponse:null,loading:!0,submittedViaCreateResourceAndAddAnother:!1,submittedViaCreateResource:!1,fields:[],panels:[]}),async created(){if(Nova.missingResource(this.resourceName))return Nova.visit("/404");if(this.isRelation){const{data:e}=await Nova.request().get("/nova-api/"+this.viaResource+"/field/"+this.viaRelationship,{params:{resourceName:this.resourceName,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship}});this.relationResponse=e,this.isHasOneRelationship&&this.alreadyFilled&&(Nova.error(this.__("The HasOne relationship has already been filled.")),Nova.visit(`/resources/${this.viaResource}/${this.viaResourceId}`)),this.isHasOneThroughRelationship&&this.alreadyFilled&&(Nova.error(this.__("The HasOneThrough relationship has already been filled.")),Nova.visit(`/resources/${this.viaResource}/${this.viaResourceId}`))}this.getFields(),"form"!==this.mode&&this.allowLeavingModal()},methods:h(h(h({},(0,s.PY)(["allowLeavingModal","preventLeavingModal"])),(0,s.i0)(["fetchPolicies"])),{},{handleResourceLoaded(){this.loading=!1,this.$emit("finished-loading"),Nova.$emit("resource-loaded",{resourceName:this.resourceName,resourceId:null,mode:"create"})},async getFields(){this.panels=[],this.fields=[];const{data:{panels:e,fields:t}}=await Nova.request().get(`/nova-api/${this.resourceName}/creation-fields`,{params:{editing:!0,editMode:"create",inline:this.shownViaNewRelationModal,fromResourceId:this.fromResourceId,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship}});this.panels=e,this.fields=t,this.handleResourceLoaded()},async submitViaCreateResource(e){e.preventDefault(),this.submittedViaCreateResource=!0,this.submittedViaCreateResourceAndAddAnother=!1,await this.createResource()},async submitViaCreateResourceAndAddAnother(){this.submittedViaCreateResourceAndAddAnother=!0,this.submittedViaCreateResource=!1,await this.createResource()},async createResource(){if(this.isWorking=!0,this.$refs.form.reportValidity())try{const{data:{redirect:e,id:t}}=await this.createRequest();if("form"!==this.mode&&this.allowLeavingModal(),await this.fetchPolicies(),Nova.success(this.__("The :resource was created!",{resource:this.resourceInformation.singularLabel.toLowerCase()})),!this.submittedViaCreateResource)return window.scrollTo(0,0),this.$emit("resource-created-and-adding-another",{id:t}),this.getFields(),this.resetErrors(),this.submittedViaCreateAndAddAnother=!1,this.submittedViaCreateResource=!1,void(this.isWorking=!1);this.$emit("resource-created",{id:t,redirect:e})}catch(e){window.scrollTo(0,0),this.submittedViaCreateAndAddAnother=!1,this.submittedViaCreateResource=!0,this.isWorking=!1,"form"!==this.mode&&this.preventLeavingModal(),this.handleOnCreateResponseError(e)}this.submittedViaCreateAndAddAnother=!1,this.submittedViaCreateResource=!0,this.isWorking=!1},createRequest(){return Nova.request().post(`/nova-api/${this.resourceName}`,this.createResourceFormData(),{params:{editing:!0,editMode:"create"}})},createResourceFormData(){return u()(new FormData,(e=>{this.panels.forEach((t=>{t.fields.forEach((t=>{t.fill(e)}))})),null!=this.fromResourceId&&e.append("fromResourceId",this.fromResourceId),e.append("viaResource",this.viaResource),e.append("viaResourceId",this.viaResourceId),e.append("viaRelationship",this.viaRelationship)}))},onUpdateFormStatus(){this.$emit("update-form-status")}}),computed:{wasSubmittedViaCreateResource(){return this.isWorking&&this.submittedViaCreateResource},wasSubmittedViaCreateResourceAndAddAnother(){return this.isWorking&&this.submittedViaCreateResourceAndAddAnother},singularName(){return this.relationResponse?this.relationResponse.singularLabel:this.resourceInformation.singularLabel},createButtonLabel(){return this.resourceInformation.createButtonLabel},isRelation(){return Boolean(this.viaResourceId&&this.viaRelationship)},shownViaNewRelationModal(){return"modal"===this.mode},inFormMode(){return"form"===this.mode},canAddMoreResources(){return this.authorizedToCreate},alreadyFilled(){return this.relationResponse&&this.relationResponse.alreadyFilled},isHasOneRelationship(){return this.relationResponse&&this.relationResponse.hasOneRelationship},isHasOneThroughRelationship(){return this.relationResponse&&this.relationResponse.hasOneThroughRelationship},shouldShowAddAnotherButton(){return Boolean(this.inFormMode&&!this.alreadyFilled)&&!Boolean(this.isHasOneRelationship||this.isHasOneThroughRelationship)}}};const v=(0,r(66262).A)(f,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("Head"),u=(0,o.resolveComponent)("Button"),p=(0,o.resolveComponent)("LoadingView");return(0,o.openBlock)(),(0,o.createBlock)(p,{loading:e.loading},{default:(0,o.withCtx)((()=>[e.shouldOverrideMeta&&e.resourceInformation?((0,o.openBlock)(),(0,o.createBlock)(d,{key:0,title:e.__("Create :resource",{resource:e.resourceInformation.singularLabel})},null,8,["title"])):(0,o.createCommentVNode)("",!0),e.panels?((0,o.openBlock)(),(0,o.createElementBlock)("form",{key:1,class:"space-y-8",onSubmit:t[1]||(t[1]=(...e)=>c.submitViaCreateResource&&c.submitViaCreateResource(...e)),onChange:t[2]||(t[2]=(...e)=>c.onUpdateFormStatus&&c.onUpdateFormStatus(...e)),"data-form-unique-id":e.formUniqueId,autocomplete:"off",ref:"form"},[(0,o.createElementVNode)("div",l,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.panels,(t=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)("form-"+t.component),{key:t.id,onFieldChanged:c.onUpdateFormStatus,onFileUploadStarted:e.handleFileUploadStarted,onFileUploadFinished:e.handleFileUploadFinished,"shown-via-new-relation-modal":c.shownViaNewRelationModal,panel:t,name:t.name,dusk:`${t.attribute}-panel`,"resource-name":e.resourceName,fields:t.fields,"form-unique-id":e.formUniqueId,mode:r.mode,"validation-errors":e.validationErrors,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"show-help-text":!0},null,40,["onFieldChanged","onFileUploadStarted","onFileUploadFinished","shown-via-new-relation-modal","panel","name","dusk","resource-name","fields","form-unique-id","mode","validation-errors","via-resource","via-resource-id","via-relationship"])))),128))]),(0,o.createElementVNode)("div",a,[(0,o.createVNode)(u,{onClick:t[0]||(t[0]=t=>e.$emit("create-cancelled")),variant:"ghost",label:e.__("Cancel"),disabled:e.isWorking,dusk:"cancel-create-button"},null,8,["label","disabled"]),c.shouldShowAddAnotherButton?((0,o.openBlock)(),(0,o.createBlock)(u,{key:0,onClick:c.submitViaCreateResourceAndAddAnother,label:e.__("Create & Add Another"),loading:c.wasSubmittedViaCreateResourceAndAddAnother,dusk:"create-and-add-another-button"},null,8,["onClick","label","loading"])):(0,o.createCommentVNode)("",!0),(0,o.createVNode)(u,{type:"submit",dusk:"create-button",onClick:c.submitViaCreateResource,label:c.createButtonLabel,disabled:e.isWorking,loading:c.wasSubmittedViaCreateResource},null,8,["onClick","label","disabled","loading"])])],40,i)):(0,o.createCommentVNode)("",!0)])),_:1},8,["loading"])}],["__file","CreateForm.vue"]])},76037:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726),i=r(65835);const l={key:0},a={class:"hidden md:inline-block"},n={class:"inline-block md:hidden"},s={class:"hidden md:inline-block"},c={class:"inline-block md:hidden"},d={__name:"CreateResourceButton",props:{type:{type:String,default:"button",validator:e=>["button","outline-button"].includes(e)},label:{},singularName:{},resourceName:{},viaResource:{},viaResourceId:{},viaRelationship:{},relationshipType:{},authorizedToCreate:{},authorizedToRelate:{},alreadyFilled:{type:Boolean,default:!1}},setup(e){const{__:t}=(0,i.B)(),r=e,d=(0,o.computed)((()=>["belongsToMany","morphToMany"].includes(r.relationshipType)&&r.authorizedToRelate)),u=(0,o.computed)((()=>r.authorizedToCreate&&r.authorizedToRelate&&!r.alreadyFilled)),p=(0,o.computed)((()=>d||u));return(r,i)=>{const h=(0,o.resolveComponent)("InertiaButton");return p.value?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[d.value?((0,o.openBlock)(),(0,o.createBlock)(h,{key:0,class:"shrink-0",dusk:"attach-button",href:r.$url(`/resources/${e.viaResource}/${e.viaResourceId}/attach/${e.resourceName}`,{viaRelationship:e.viaRelationship,polymorphic:"morphToMany"===e.relationshipType?"1":"0"})},{default:(0,o.withCtx)((()=>[(0,o.renderSlot)(r.$slots,"default",{},(()=>[(0,o.createElementVNode)("span",a,(0,o.toDisplayString)((0,o.unref)(t)("Attach :resource",{resource:e.singularName})),1),(0,o.createElementVNode)("span",n,(0,o.toDisplayString)((0,o.unref)(t)("Attach")),1)]))])),_:3},8,["href"])):u.value?((0,o.openBlock)(),(0,o.createBlock)(h,{key:1,class:"shrink-0 h-9 px-4 focus:outline-none ring-primary-200 dark:ring-gray-600 focus:ring text-white dark:text-gray-800 inline-flex items-center font-bold",dusk:"create-button",href:r.$url(`/resources/${e.resourceName}/new`,{viaResource:e.viaResource,viaResourceId:e.viaResourceId,viaRelationship:e.viaRelationship,relationshipType:e.relationshipType})},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",s,(0,o.toDisplayString)(e.label),1),(0,o.createElementVNode)("span",c,(0,o.toDisplayString)((0,o.unref)(t)("Create")),1)])),_:1},8,["href"])):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0)}}};const u=(0,r(66262).A)(d,[["__file","CreateResourceButton.vue"]])},57199:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={key:0,class:"text-red-500 text-sm"};var l=r(35229);function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function n(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const s={mixins:[l._w],props:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?a(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({field:{type:Object,required:!0},fieldName:{type:String},showErrors:{type:Boolean,default:!0},fullWidthContent:{type:Boolean,default:!1},labelFor:{default:null}},(0,l.rr)(["showHelpText"])),computed:{fieldWrapperClasses(){return["space-y-2","md:flex @md/modal:flex","md:flex-row @md/modal:flex-row","md:space-y-0 @md/modal:space-y-0",this.field.withLabel&&!this.field.inline&&(this.field.compact?"py-3":"py-5"),this.field.stacked&&"md:flex-col @md/modal:flex-col md:space-y-2 @md/modal:space-y-2"]},labelClasses(){return["w-full",this.field.compact?"!px-3":"px-6",!this.field.stacked&&"md:mt-2 @md/modal:mt-2",this.field.stacked&&!this.field.inline&&"md:px-8 @md/modal:px-8",!this.field.stacked&&!this.field.inline&&"md:px-8 @md/modal:px-8",this.field.compact&&"md:!px-6 @md/modal:!px-6",!this.field.stacked&&!this.field.inline&&"md:w-1/5 @md/modal:w-1/5"]},controlWrapperClasses(){return["w-full space-y-2",this.field.compact?"!px-3":"px-6",this.field.compact&&"md:!px-4 @md/modal:!px-4",this.field.stacked&&!this.field.inline&&"md:px-8 @md/modal:px-8",!this.field.stacked&&!this.field.inline&&"md:px-8 @md/modal:px-8",!this.field.stacked&&!this.field.inline&&!this.field.fullWidth&&"md:w-3/5 @md/modal:w-3/5",this.field.stacked&&!this.field.inline&&!this.field.fullWidth&&"md:w-3/5 @md/modal:w-3/5",!this.field.stacked&&!this.field.inline&&this.field.fullWidth&&"md:w-4/5 @md/modal:w-4/5"]},fieldLabel(){return""===this.fieldName?"":this.fieldName||this.field.name||this.field.singularLabel},shouldShowHelpText(){return this.showHelpText&&this.field.helpText?.length>0}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("FormLabel"),c=(0,o.resolveComponent)("HelpText");return r.field.visible?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,class:(0,o.normalizeClass)(n.fieldWrapperClasses)},[r.field.withLabel?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,class:(0,o.normalizeClass)(n.labelClasses)},[(0,o.renderSlot)(e.$slots,"default",{},(()=>[(0,o.createVNode)(s,{"label-for":r.labelFor||r.field.uniqueKey,class:(0,o.normalizeClass)(["space-x-1",{"mb-2":n.shouldShowHelpText}])},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(n.fieldLabel),1),r.field.required?((0,o.openBlock)(),(0,o.createElementBlock)("span",i,(0,o.toDisplayString)(e.__("*")),1)):(0,o.createCommentVNode)("",!0)])),_:1},8,["label-for","class"])]))],2)):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(n.controlWrapperClasses)},[(0,o.renderSlot)(e.$slots,"field"),r.showErrors&&e.hasError?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,class:"help-text-error"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.firstError),1)])),_:1})):(0,o.createCommentVNode)("",!0),n.shouldShowHelpText?((0,o.openBlock)(),(0,o.createBlock)(c,{key:1,class:"help-text",innerHTML:r.field.helpText},null,8,["innerHTML"])):(0,o.createCommentVNode)("",!0)],2)],2)):(0,o.createCommentVNode)("",!0)}],["__file","DefaultField.vue"]])},52613:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>d});var o=r(29726);const i={key:0,class:"h-9"},l={class:"py-1"},a=["textContent"];var n=r(74640),s=r(35229);const c={components:{Button:n.Button},emits:["close","deleteAllMatching","deleteSelected","forceDeleteAllMatching","forceDeleteSelected","restoreAllMatching","restoreSelected"],mixins:[s.XJ],props:["allMatchingResourceCount","allMatchingSelected","authorizedToDeleteAnyResources","authorizedToDeleteSelectedResources","authorizedToForceDeleteAnyResources","authorizedToForceDeleteSelectedResources","authorizedToRestoreAnyResources","authorizedToRestoreSelectedResources","resources","selectedResources","show","softDeletes","trashedParameter","viaManyToMany"],data:()=>({deleteSelectedModalOpen:!1,forceDeleteSelectedModalOpen:!1,restoreModalOpen:!1}),mounted(){document.addEventListener("keydown",this.handleEscape),Nova.$on("close-dropdowns",this.handleClosingDropdown)},beforeUnmount(){document.removeEventListener("keydown",this.handleEscape),Nova.$off("close-dropdowns",this.handleClosingDropdown)},methods:{confirmDeleteSelectedResources(){this.deleteSelectedModalOpen=!0},confirmForceDeleteSelectedResources(){this.forceDeleteSelectedModalOpen=!0},confirmRestore(){this.restoreModalOpen=!0},closeDeleteSelectedModal(){this.deleteSelectedModalOpen=!1},closeForceDeleteSelectedModal(){this.forceDeleteSelectedModalOpen=!1},closeRestoreModal(){this.restoreModalOpen=!1},deleteSelectedResources(){this.$emit(this.allMatchingSelected?"deleteAllMatching":"deleteSelected")},forceDeleteSelectedResources(){this.$emit(this.allMatchingSelected?"forceDeleteAllMatching":"forceDeleteSelected")},restoreSelectedResources(){this.$emit(this.allMatchingSelected?"restoreAllMatching":"restoreSelected")},handleEscape(e){this.show&&27==e.keyCode&&this.close()},close(){this.$emit("close")},handleClosingDropdown(){this.deleteSelectedModalOpen=!1,this.forceDeleteSelectedModalOpen=!1,this.restoreModalOpen=!1}},computed:{trashedOnlyMode(){return"only"==this.queryStringParams[this.trashedParameter]},hasDropDownMenuItems(){return this.shouldShowDeleteItem||this.shouldShowRestoreItem||this.shouldShowForceDeleteItem},shouldShowDeleteItem(){return!this.trashedOnlyMode&&Boolean(this.authorizedToDeleteSelectedResources||this.allMatchingSelected)},shouldShowRestoreItem(){return this.softDeletes&&!this.viaManyToMany&&(this.softDeletedResourcesSelected||this.allMatchingSelected)&&(this.authorizedToRestoreSelectedResources||this.allMatchingSelected)},shouldShowForceDeleteItem(){return this.softDeletes&&!this.viaManyToMany&&(this.authorizedToForceDeleteSelectedResources||this.allMatchingSelected)},selectedResourcesCount(){return this.allMatchingSelected?this.allMatchingResourceCount:this.selectedResources.length},softDeletedResourcesSelected(){return Boolean(null!=this.selectedResources.find((e=>e.softDeleted)))}}};const d=(0,r(66262).A)(c,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("Button"),u=(0,o.resolveComponent)("CircleBadge"),p=(0,o.resolveComponent)("DropdownMenuItem"),h=(0,o.resolveComponent)("DropdownMenu"),m=(0,o.resolveComponent)("Dropdown"),f=(0,o.resolveComponent)("DeleteResourceModal"),v=(0,o.resolveComponent)("ModalHeader"),g=(0,o.resolveComponent)("ModalContent"),y=(0,o.resolveComponent)("RestoreResourceModal");return c.hasDropDownMenuItems?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createVNode)(m,null,{menu:(0,o.withCtx)((()=>[(0,o.createVNode)(h,{class:"px-1",width:"250"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("nav",l,[c.shouldShowDeleteItem?((0,o.openBlock)(),(0,o.createBlock)(p,{key:0,as:"button",class:"border-none",dusk:"delete-selected-button",onClick:(0,o.withModifiers)(c.confirmDeleteSelectedResources,["prevent"])},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__(r.viaManyToMany?"Detach Selected":"Delete Selected"))+" ",1),(0,o.createVNode)(u,null,{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(c.selectedResourcesCount),1)])),_:1})])),_:1},8,["onClick"])):(0,o.createCommentVNode)("",!0),c.shouldShowRestoreItem?((0,o.openBlock)(),(0,o.createBlock)(p,{key:1,as:"button",dusk:"restore-selected-button",onClick:(0,o.withModifiers)(c.confirmRestore,["prevent"])},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Restore Selected"))+" ",1),(0,o.createVNode)(u,null,{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(c.selectedResourcesCount),1)])),_:1})])),_:1},8,["onClick"])):(0,o.createCommentVNode)("",!0),c.shouldShowForceDeleteItem?((0,o.openBlock)(),(0,o.createBlock)(p,{key:2,as:"button",dusk:"force-delete-selected-button",onClick:(0,o.withModifiers)(c.confirmForceDeleteSelectedResources,["prevent"])},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Force Delete Selected"))+" ",1),(0,o.createVNode)(u,null,{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(c.selectedResourcesCount),1)])),_:1})])),_:1},8,["onClick"])):(0,o.createCommentVNode)("",!0)])])),_:1})])),default:(0,o.withCtx)((()=>[(0,o.createVNode)(d,{variant:"ghost",padding:"tight",icon:"trash","trailing-icon":"chevron-down","aria-label":e.__("Trash Dropdown")},null,8,["aria-label"])])),_:1}),(0,o.createVNode)(f,{mode:r.viaManyToMany?"detach":"delete",show:r.selectedResources.length>0&&e.deleteSelectedModalOpen,onClose:c.closeDeleteSelectedModal,onConfirm:c.deleteSelectedResources},null,8,["mode","show","onClose","onConfirm"]),(0,o.createVNode)(f,{show:r.selectedResources.length>0&&e.forceDeleteSelectedModalOpen,mode:"delete",onClose:c.closeForceDeleteSelectedModal,onConfirm:c.forceDeleteSelectedResources},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(v,{textContent:(0,o.toDisplayString)(e.__("Force Delete Resource"))},null,8,["textContent"]),(0,o.createVNode)(g,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("p",{class:"leading-normal",textContent:(0,o.toDisplayString)(e.__("Are you sure you want to force delete the selected resources?"))},null,8,a)])),_:1})])),_:1},8,["show","onClose","onConfirm"]),(0,o.createVNode)(y,{show:r.selectedResources.length>0&&e.restoreModalOpen,onClose:c.closeRestoreModal,onConfirm:c.restoreSelectedResources},null,8,["show","onClose","onConfirm"])])):(0,o.createCommentVNode)("",!0)}],["__file","DeleteMenu.vue"]])},71786:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"block mx-auto mb-6",xmlns:"http://www.w3.org/2000/svg",width:"100",height:"2",viewBox:"0 0 100 2"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("svg",i,t[0]||(t[0]=[(0,o.createElementVNode)("path",{fill:"#D8E3EC",d:"M0 0h100v2H0z"},null,-1)]))}],["__file","DividerLine.vue"]])},28213:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>f});var o=r(29726),i=r(74640),l=r(65835),a=r(10646);const n=["dusk","multiple","accept","disabled"],s={class:"space-y-4"},c={key:0,class:"grid grid-cols-4 gap-x-6 gap-y-2"},d=["onKeydown"],u={class:"flex items-center space-x-4 pointer-events-none"},p={class:"text-center pointer-events-none"},h={class:"pointer-events-none text-center text-sm text-gray-500 dark:text-gray-400 font-semibold"},m=Object.assign({inheritAttrs:!1},{__name:"DropZone",props:{files:{type:Array,default:[]},multiple:{type:Boolean,default:!1},rounded:{type:Boolean,default:!1},acceptedTypes:{type:String,default:null},disabled:{type:Boolean,default:!1}},emits:["fileChanged","fileRemoved"],setup(e,{emit:t}){const r=t,m=e,{__:f}=(0,l.B)(),{startedDrag:v,handleOnDragEnter:g,handleOnDragLeave:y}=(0,a.g)(r),b=(0,o.ref)([]),k=(0,o.ref)(),w=()=>k.value.click(),C=e=>{b.value=m.multiple?e.dataTransfer.files:[e.dataTransfer.files[0]],r("fileChanged",b.value)},x=()=>{b.value=m.multiple?k.value.files:[k.value.files[0]],r("fileChanged",b.value),k.value.files=null};return(t,l)=>{const a=(0,o.resolveComponent)("FilePreviewBlock");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.createElementVNode)("input",{class:"visually-hidden",dusk:t.$attrs["input-dusk"],onChange:(0,o.withModifiers)(x,["prevent"]),type:"file",ref_key:"fileInput",ref:k,multiple:e.multiple,accept:e.acceptedTypes,disabled:e.disabled,tabindex:"-1"},null,40,n),(0,o.createElementVNode)("div",s,[e.files.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",c,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.files,((i,l)=>((0,o.openBlock)(),(0,o.createBlock)(a,{key:l,file:i,onRemoved:()=>(e=>{r("fileRemoved",e),k.value.files=null,k.value.value=null})(l),rounded:e.rounded,dusk:t.$attrs.dusk},null,8,["file","onRemoved","rounded","dusk"])))),128))])):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",{tabindex:"0",role:"button",onClick:w,onKeydown:[(0,o.withKeys)((0,o.withModifiers)(w,["prevent"]),["space"]),(0,o.withKeys)((0,o.withModifiers)(w,["prevent"]),["enter"])],class:(0,o.normalizeClass)(["focus:outline-none focus:!border-primary-500 block cursor-pointer p-4 bg-gray-50 dark:bg-gray-900 dark:hover:bg-gray-900 border-4 border-dashed hover:border-gray-300 dark:border-gray-700 dark:hover:border-gray-600 rounded-lg",{"border-gray-300 dark:border-gray-600":(0,o.unref)(v)}]),onDragenter:l[0]||(l[0]=(0,o.withModifiers)(((...e)=>(0,o.unref)(g)&&(0,o.unref)(g)(...e)),["prevent"])),onDragleave:l[1]||(l[1]=(0,o.withModifiers)(((...e)=>(0,o.unref)(y)&&(0,o.unref)(y)(...e)),["prevent"])),onDragover:l[2]||(l[2]=(0,o.withModifiers)((()=>{}),["prevent"])),onDrop:(0,o.withModifiers)(C,["prevent"])},[(0,o.createElementVNode)("div",u,[(0,o.createElementVNode)("p",p,[(0,o.createVNode)((0,o.unref)(i.Button),{as:"div","leading-icon":e.multiple?"arrow-up-on-square-stack":"arrow-up-tray"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.multiple?(0,o.unref)(f)("Choose Files"):(0,o.unref)(f)("Choose File")),1)])),_:1},8,["leading-icon"])]),(0,o.createElementVNode)("p",h,(0,o.toDisplayString)(e.multiple?(0,o.unref)(f)("Drop files or click to choose"):(0,o.unref)(f)("Drop file or click to choose")),1)])],42,d)])])}}});const f=(0,r(66262).A)(m,[["__file","DropZone.vue"]])},84547:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>v});var o=r(29726),i=r(74640);var l=r(65835);const a={class:"h-full flex items-start justify-center"},n={class:"relative w-full"},s=["dusk"],c={class:"bg-gray-50 dark:bg-gray-700 relative aspect-square flex items-center justify-center border-2 border-gray-200 dark:border-gray-700 overflow-hidden rounded-lg"},d={key:0,class:"absolute inset-0 flex items-center justify-center"},u=["src"],p={key:2},h={class:"rounded bg-gray-200 border-2 border-gray-200 p-4"},m={class:"font-semibold text-xs mt-1"},f=Object.assign({inheritAttrs:!1},{__name:"FilePreviewBlock",props:{file:{type:Object},removable:{type:Boolean,default:!0}},emits:["removed"],setup(e){const t=e,{__:r}=(0,l.B)(),f=(0,o.computed)((()=>t.file.processing?r("Uploading")+" ("+t.file.progress+"%)":t.file.name)),v=(0,o.computed)((()=>t.file.processing?t.file.progress:100)),{previewUrl:g,isImage:y}=function(e){const t=["image/avif","image/gif","image/jpeg","image/png","image/svg+xml","image/webp"],r=(0,o.computed)((()=>t.includes(e.value.type)?"image":"other")),i=(0,o.computed)((()=>URL.createObjectURL(e.value.originalFile))),l=(0,o.computed)((()=>"image"===r.value));return{imageTypes:t,isImage:l,type:r,previewUrl:i}}((0,o.toRef)(t,"file"));return(t,l)=>{const b=(0,o.resolveComponent)("ProgressBar"),k=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createElementBlock)("div",a,[(0,o.createElementVNode)("div",n,[e.removable?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:0,type:"button",class:"absolute z-20 top-[-10px] right-[-9px] rounded-full shadow bg-white dark:bg-gray-800 text-center flex items-center justify-center h-[20px] w-[21px]",onClick:l[0]||(l[0]=(0,o.withModifiers)((e=>t.$emit("removed")),["stop"])),dusk:t.$attrs.dusk},[(0,o.createVNode)((0,o.unref)(i.Icon),{name:"x-circle",type:"solid",class:"text-gray-800 dark:text-gray-200"})],8,s)),[[k,(0,o.unref)(r)("Remove")]]):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",c,[e.file.processing?((0,o.openBlock)(),(0,o.createElementBlock)("div",d,[(0,o.createVNode)(b,{title:f.value,class:"mx-4",color:"bg-green-500",value:v.value},null,8,["title","value"]),l[1]||(l[1]=(0,o.createElementVNode)("div",{class:"bg-primary-900 opacity-5 absolute inset-0"},null,-1))])):(0,o.createCommentVNode)("",!0),(0,o.unref)(y)?((0,o.openBlock)(),(0,o.createElementBlock)("img",{key:1,src:(0,o.unref)(g),class:"aspect-square object-scale-down"},null,8,u)):((0,o.openBlock)(),(0,o.createElementBlock)("div",p,[(0,o.createElementVNode)("div",h,[(0,o.createVNode)((0,o.unref)(i.Icon),{name:"document-text",class:"!w-[50px] !h-[50px]"})])]))]),(0,o.createElementVNode)("p",m,(0,o.toDisplayString)(e.file.name),1)])])}}});const v=(0,r(66262).A)(f,[["__file","FilePreviewBlock.vue"]])},80636:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726),i=r(74640),l=r(65835),a=r(10646);const n={class:"space-y-4"},s={key:0,class:"grid grid-cols-4 gap-x-6"},c={class:"flex items-center space-x-4"},d={class:"text-center pointer-events-none"},u={class:"pointer-events-none text-center text-sm text-gray-500 dark:text-gray-400 font-semibold"},p={__name:"SingleDropZone",props:{files:Array,handleClick:Function},emits:["fileChanged","fileRemoved"],setup(e,{emit:t}){const r=t,{__:p}=(0,l.B)(),{startedDrag:h,handleOnDragEnter:m,handleOnDragLeave:f,handleOnDrop:v}=(0,a.g)(r);return(t,l)=>{const a=(0,o.resolveComponent)("FilePreviewBlock");return(0,o.openBlock)(),(0,o.createElementBlock)("div",n,[e.files.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",s,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.files,((e,t)=>((0,o.openBlock)(),(0,o.createBlock)(a,{key:t,file:e,onRemoved:()=>function(e){r("fileRemoved",e)}(t)},null,8,["file","onRemoved"])))),128))])):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",{onClick:l[0]||(l[0]=(...t)=>e.handleClick&&e.handleClick(...t)),class:(0,o.normalizeClass)(["cursor-pointer p-4 bg-gray-50 dark:bg-gray-900 dark:hover:bg-gray-900 border-4 border-dashed hover:border-gray-300 dark:hover:border-gray-600 rounded-lg",(0,o.unref)(h)?"border-gray-300 dark:border-gray-600":"border-gray-200 dark:border-gray-700"]),onDragenter:l[1]||(l[1]=(0,o.withModifiers)(((...e)=>(0,o.unref)(m)&&(0,o.unref)(m)(...e)),["prevent"])),onDragleave:l[2]||(l[2]=(0,o.withModifiers)(((...e)=>(0,o.unref)(f)&&(0,o.unref)(f)(...e)),["prevent"])),onDragover:l[3]||(l[3]=(0,o.withModifiers)((()=>{}),["prevent"])),onDrop:l[4]||(l[4]=(0,o.withModifiers)(((...e)=>(0,o.unref)(v)&&(0,o.unref)(v)(...e)),["prevent"]))},[(0,o.createElementVNode)("div",c,[(0,o.createElementVNode)("p",d,[(0,o.createVNode)((0,o.unref)(i.Button),{as:"div"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)((0,o.unref)(p)("Choose a file")),1)])),_:1})]),(0,o.createElementVNode)("p",u,(0,o.toDisplayString)(t.multiple?(0,o.unref)(p)("Drop files or click to choose"):(0,o.unref)(p)("Drop file or click to choose")),1)])],34)])}}};const h=(0,r(66262).A)(p,[["__file","SingleDropZone.vue"]])},46644:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726),i=r(74640),l=r(66278),a=r(65703),n=r(84787);const s={class:"px-1 divide-y divide-gray-100 dark:divide-gray-800 divide-solid"},c={key:0},d={class:"py-1"},u={__name:"ActionDropdown",props:{resource:{},resourceName:{},viaResource:{},viaResourceId:{},viaRelationship:{},relationshipType:{},actions:{type:Array,default:[]},selectedResources:{type:[Array,String],default:()=>[]},endpoint:{type:String,default:null},triggerDuskAttribute:{type:String,default:null},showHeadings:{type:Boolean,default:!1}},emits:["actionExecuted"],setup(e,{emit:t}){const r=t,u=e,p=(0,l.Pj)(),{errors:h,actionModalVisible:m,responseModalVisible:f,openConfirmationModal:v,closeConfirmationModal:g,closeResponseModal:y,handleActionClick:b,selectedAction:k,working:w,executeAction:C,actionResponseData:x}=(0,a.d)(u,r,p),N=()=>C((()=>r("actionExecuted"))),B=()=>{y(),r("actionExecuted")},S=()=>{y(),r("actionExecuted")};return(t,r)=>{const l=(0,o.resolveComponent)("DropdownMenuItem"),a=(0,o.resolveComponent)("ScrollWrap"),u=(0,o.resolveComponent)("DropdownMenu"),p=(0,o.resolveComponent)("Dropdown"),v=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.unref)(m)?((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)((0,o.unref)(k)?.component),{key:0,show:(0,o.unref)(m),class:"text-left",working:(0,o.unref)(w),"selected-resources":e.selectedResources,"resource-name":e.resourceName,action:(0,o.unref)(k),errors:(0,o.unref)(h),onConfirm:N,onClose:(0,o.unref)(g)},null,40,["show","working","selected-resources","resource-name","action","errors","onClose"])):(0,o.createCommentVNode)("",!0),(0,o.unref)(f)?((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)((0,o.unref)(x)?.modal),{key:1,show:(0,o.unref)(f),onConfirm:B,onClose:S,data:(0,o.unref)(x)},null,40,["show","data"])):(0,o.createCommentVNode)("",!0),(0,o.createVNode)(p,null,{default:(0,o.withCtx)((()=>[(0,o.renderSlot)(t.$slots,"trigger",{},(()=>[(0,o.withDirectives)((0,o.createVNode)((0,o.unref)(i.Button),{onClick:r[0]||(r[0]=(0,o.withModifiers)((()=>{}),["stop"])),dusk:e.triggerDuskAttribute,variant:"ghost",icon:"ellipsis-horizontal"},null,8,["dusk"]),[[v,t.__("Actions")]])]))])),menu:(0,o.withCtx)((()=>[(0,o.createVNode)(u,{width:"auto"},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(a,{height:250},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("nav",s,[(0,o.renderSlot)(t.$slots,"menu"),e.actions.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",c,[e.showHeadings?((0,o.openBlock)(),(0,o.createBlock)(n.default,{key:0},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(t.__("User Actions")),1)])),_:1})):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",d,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.actions,(e=>((0,o.openBlock)(),(0,o.createBlock)(l,{key:e.uriKey,"data-action-id":e.uriKey,as:"button",class:"border-none",onClick:()=>(e=>{!1!==e.authorizedToRun&&b(e.uriKey)})(e),title:e.name,disabled:!1===e.authorizedToRun},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.name),1)])),_:2},1032,["data-action-id","onClick","title","disabled"])))),128))])])):(0,o.createCommentVNode)("",!0)])])),_:3})])),_:3})])),_:3})])}}};const p=(0,r(66262).A)(u,[["__file","ActionDropdown.vue"]])},30013:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i={key:0},l={class:"py-1"};var a=r(66278),n=r(35229);function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function c(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){d(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function d(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const u={emits:["actionExecuted","resource-deleted","resource-restored"],inheritAttrs:!1,mixins:[n.Tu,n.Ye],props:c({resource:{type:Object},actions:{type:Array},viaManyToMany:{type:Boolean}},(0,n.rr)(["resourceName","viaResource","viaResourceId","viaRelationship"])),data:()=>({deleteModalOpen:!1,restoreModalOpen:!1,forceDeleteModalOpen:!1}),methods:c(c({},(0,a.i0)(["startImpersonating"])),{},{async confirmDelete(){this.deleteResources([this.resource],(e=>{Nova.success(this.__("The :resource was deleted!",{resource:this.resourceInformation.singularLabel.toLowerCase()})),e&&e.data&&e.data.redirect?Nova.visit(e.data.redirect):this.resource.softDeletes?(this.closeDeleteModal(),this.$emit("resource-deleted")):Nova.visit(`/resources/${this.resourceName}`)}))},openDeleteModal(){this.deleteModalOpen=!0},closeDeleteModal(){this.deleteModalOpen=!1},async confirmRestore(){this.restoreResources([this.resource],(()=>{Nova.success(this.__("The :resource was restored!",{resource:this.resourceInformation.singularLabel.toLowerCase()})),this.closeRestoreModal(),this.$emit("resource-restored")}))},openRestoreModal(){this.restoreModalOpen=!0},closeRestoreModal(){this.restoreModalOpen=!1},async confirmForceDelete(){this.forceDeleteResources([this.resource],(e=>{Nova.success(this.__("The :resource was deleted!",{resource:this.resourceInformation.singularLabel.toLowerCase()})),e&&e.data&&e.data.redirect?Nova.visit(e.data.redirect):Nova.visit(`/resources/${this.resourceName}`)}))},openForceDeleteModal(){this.forceDeleteModalOpen=!0},closeForceDeleteModal(){this.forceDeleteModalOpen=!1}}),computed:(0,a.L8)(["currentUser"])};const p=(0,r(66262).A)(u,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("DropdownMenuHeading"),d=(0,o.resolveComponent)("DropdownMenuItem"),u=(0,o.resolveComponent)("ActionDropdown"),p=(0,o.resolveComponent)("DeleteResourceModal"),h=(0,o.resolveComponent)("RestoreResourceModal");return(0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,null,[r.resource?((0,o.openBlock)(),(0,o.createBlock)(u,{key:0,resource:r.resource,actions:r.actions,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"resource-name":e.resourceName,onActionExecuted:t[1]||(t[1]=t=>e.$emit("actionExecuted")),"selected-resources":[r.resource.id.value],"trigger-dusk-attribute":`${r.resource.id.value}-control-selector`,"show-headings":!0},{menu:(0,o.withCtx)((()=>[r.resource.authorizedToReplicate||e.currentUser.canImpersonate&&r.resource.authorizedToImpersonate||r.resource.authorizedToDelete&&!r.resource.softDeleted||r.resource.authorizedToRestore&&r.resource.softDeleted||r.resource.authorizedToForceDelete?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createVNode)(c,null,{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Actions")),1)])),_:1}),(0,o.createElementVNode)("div",l,[r.resource.authorizedToReplicate?((0,o.openBlock)(),(0,o.createBlock)(d,{key:0,dusk:`${r.resource.id.value}-replicate-button`,href:e.$url(`/resources/${e.resourceName}/${r.resource.id.value}/replicate`,{viaResource:e.viaResource,viaResourceId:e.viaResourceId,viaRelationship:e.viaRelationship}),title:e.__("Replicate")},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Replicate")),1)])),_:1},8,["dusk","href","title"])):(0,o.createCommentVNode)("",!0),e.currentUser.canImpersonate&&r.resource.authorizedToImpersonate?((0,o.openBlock)(),(0,o.createBlock)(d,{key:1,as:"button",dusk:`${r.resource.id.value}-impersonate-button`,onClick:t[0]||(t[0]=(0,o.withModifiers)((t=>e.startImpersonating({resource:e.resourceName,resourceId:r.resource.id.value})),["prevent"])),title:e.__("Impersonate")},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Impersonate")),1)])),_:1},8,["dusk","title"])):(0,o.createCommentVNode)("",!0),r.resource.authorizedToDelete&&!r.resource.softDeleted?((0,o.openBlock)(),(0,o.createBlock)(d,{key:2,dusk:"open-delete-modal-button",onClick:(0,o.withModifiers)(s.openDeleteModal,["prevent"])},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Delete Resource")),1)])),_:1},8,["onClick"])):(0,o.createCommentVNode)("",!0),r.resource.authorizedToRestore&&r.resource.softDeleted?((0,o.openBlock)(),(0,o.createBlock)(d,{key:3,as:"button",dusk:"open-restore-modal-button",onClick:(0,o.withModifiers)(s.openRestoreModal,["prevent"])},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Restore Resource")),1)])),_:1},8,["onClick"])):(0,o.createCommentVNode)("",!0),r.resource.authorizedToForceDelete?((0,o.openBlock)(),(0,o.createBlock)(d,{key:4,as:"button",dusk:"open-force-delete-modal-button",onClick:(0,o.withModifiers)(s.openForceDeleteModal,["prevent"])},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Force Delete Resource")),1)])),_:1},8,["onClick"])):(0,o.createCommentVNode)("",!0)])])):(0,o.createCommentVNode)("",!0)])),_:1},8,["resource","actions","via-resource","via-resource-id","via-relationship","resource-name","selected-resources","trigger-dusk-attribute"])):(0,o.createCommentVNode)("",!0),(0,o.createVNode)(p,{show:e.deleteModalOpen,mode:"delete",onClose:s.closeDeleteModal,onConfirm:s.confirmDelete},null,8,["show","onClose","onConfirm"]),(0,o.createVNode)(h,{show:e.restoreModalOpen,onClose:s.closeRestoreModal,onConfirm:s.confirmRestore},null,8,["show","onClose","onConfirm"]),(0,o.createVNode)(p,{show:e.forceDeleteModalOpen,mode:"force delete",onClose:s.closeForceDeleteModal,onConfirm:s.confirmForceDelete},null,8,["show","onClose","onConfirm"])],64)}],["__file","DetailActionDropdown.vue"]])},36663:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(69956),i=r(18491),l=r(29726),a=r(5620);function n(e){return e?e.flatMap((e=>e.type===l.Fragment?n(e.children):[e])):[]}var s=r(96433);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function d(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function u(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const p={emits:["menu-opened","menu-closed"],inheritAttrs:!1,props:{offset:{type:[Number,String],default:5},placement:{type:String,default:"bottom-start"},boundary:{type:String,default:"viewPort"},dusk:{type:String,default:null},shouldCloseOnBlur:{type:Boolean,default:!0}},setup(e,{slots:t}){const r=(0,l.ref)(!1),c=(0,l.ref)(null),u=(0,l.ref)(null),p=(0,l.ref)(null),h=(0,l.useId)(),{activate:m,deactivate:f}=(0,a.r)(p,{initialFocus:!1,allowOutsideClick:!0}),v=(0,l.ref)(!0),g=(0,l.computed)((()=>!0===r.value&&!0===v.value)),y=()=>{v.value=!1},b=()=>{v.value=!0};var k;k=()=>r.value=!1,(0,s.MLh)(document,"keydown",(e=>{"Escape"===e.key&&k()}));const w=(0,l.computed)((()=>`nova-ui-dropdown-button-${h}`)),C=(0,l.computed)((()=>`nova-ui-dropdown-menu-${h}`)),x=(0,l.computed)((()=>Nova.config("rtlEnabled")?{"auto-start":"auto-end","auto-end":"auto-start","top-start":"top-end","top-end":"top-start","bottom-start":"bottom-end","bottom-end":"bottom-start","right-start":"right-end","right-end":"right-start","left-start":"left-end","left-end":"left-start"}[e.placement]:e.placement)),{floatingStyles:N}=(0,o.we)(c,p,{whileElementsMounted:i.ll,placement:x.value,middleware:[(0,i.cY)(e.offset),(0,i.UU)(),(0,i.BN)({padding:5}),(0,i.Ej)()]});return(0,l.watch)((()=>g),(async e=>{await(0,l.nextTick)(),e?m():f()})),(0,l.onMounted)((()=>{Nova.$on("disable-focus-trap",y),Nova.$on("enable-focus-trap",b)})),(0,l.onBeforeUnmount)((()=>{Nova.$off("disable-focus-trap",y),Nova.$off("enable-focus-trap",b),v.value=!1})),()=>{const o=n(t.default()),[i,...a]=o,s=(0,l.mergeProps)(d(d({},i.props),{id:w.value,"aria-expanded":!0===r.value?"true":"false","aria-haspopup":"true","aria-controls":C.value,onClick:(0,l.withModifiers)((()=>{r.value=!r.value}),["stop"])})),h=(0,l.cloneVNode)(i,s);for(const e in s)e.startsWith("on")&&(h.props||={},h.props[e]=s[e]);return(0,l.h)("div",{dusk:e.dusk},[(0,l.h)("span",{ref:c},h),(0,l.h)(l.Teleport,{to:"body"},(0,l.h)(l.Transition,{enterActiveClass:"transition duration-0 ease-out",enterFromClass:"opacity-0",enterToClass:"opacity-100",leaveActiveClass:"transition duration-300 ease-in",leaveFromClass:"opacity-100",leaveToClass:"opacity-0"},(()=>[r.value?(0,l.h)("div",{ref:u,dusk:"dropdown-teleported"},[(0,l.h)("div",{ref:p,id:C.value,"aria-labelledby":w.value,tabindex:"0",class:"relative z-[70]",style:N.value,"data-menu-open":r.value,dusk:"dropdown-menu",onClick:()=>e.shouldCloseOnBlur?r.value=!1:null},t.menu()),(0,l.h)("div",{class:"z-[69] fixed inset-0",dusk:"dropdown-overlay",onClick:()=>r.value=!1})]):null])))])}}};const h=(0,r(66262).A)(p,[["__file","Dropdown.vue"]])},41600:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={__name:"DropdownMenu",props:{width:{type:[Number,String],default:120}},setup(e){const t=e,r=(0,o.computed)((()=>({width:"auto"===t.width?"auto":`${t.width}px`})));return(t,i)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{style:(0,o.normalizeStyle)(r.value),class:(0,o.normalizeClass)(["select-none overflow-hidden bg-white dark:bg-gray-900 shadow-lg rounded-lg border border-gray-200 dark:border-gray-700",{"max-w-sm lg:max-w-lg":"auto"===e.width}])},[(0,o.renderSlot)(t.$slots,"default")],6))}};const l=(0,r(66262).A)(i,[["__file","DropdownMenu.vue"]])},84787:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"mt-3 px-3 text-xs font-bold"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("h3",i,[(0,o.renderSlot)(e.$slots,"default")])}],["__file","DropdownMenuHeading.vue"]])},73020:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function l(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach((function(t){a(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function a(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const n={props:{as:{type:String,default:"external",validator:e=>["button","external","form-button","link"].includes(e)},disabled:{type:Boolean,default:!1},size:{type:String,default:"small",validator:e=>["small","large"].includes(e)}},computed:{component(){return{button:"button",external:"a",link:"Link","form-button":"FormButton"}[this.as]},defaultAttributes(){return l(l({},this.$attrs),{disabled:"button"===this.as&&!0===this.disabled||null,type:"button"===this.as?"button":null})}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,i,l,a){return(0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(a.component),(0,o.mergeProps)(a.defaultAttributes,{class:["block w-full text-left px-3 focus:outline-none rounded truncate whitespace-nowrap",{"text-sm py-1.5":"small"===r.size,"text-sm py-2":"large"===r.size,"hover:bg-gray-50 dark:hover:bg-gray-800 focus:ring cursor-pointer":!r.disabled,"text-gray-400 dark:text-gray-700 cursor-default":r.disabled,"text-gray-500 active:text-gray-600 dark:text-gray-500 dark:hover:text-gray-400 dark:active:text-gray-600":!r.disabled}]}),{default:(0,o.withCtx)((()=>[(0,o.renderSlot)(e.$slots,"default")])),_:3},16,["class"])}],["__file","DropdownMenuItem.vue"]])},58909:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726);const i={key:0},l={class:"py-1"};var a=r(35229),n=r(66278);function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function c(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const d={components:{Button:r(74640).Button},emits:["actionExecuted","show-preview"],props:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){c(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({resource:{type:Object},actions:{type:Array},viaManyToMany:{type:Boolean}},(0,a.rr)(["resourceName","viaResource","viaResourceId","viaRelationship"])),methods:(0,n.i0)(["startImpersonating"]),computed:(0,n.L8)(["currentUser"])};const u=(0,r(66262).A)(d,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Button"),d=(0,o.resolveComponent)("DropdownMenuHeading"),u=(0,o.resolveComponent)("DropdownMenuItem"),p=(0,o.resolveComponent)("ActionDropdown");return(0,o.openBlock)(),(0,o.createBlock)(p,{resource:r.resource,actions:r.actions,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"resource-name":e.resourceName,onActionExecuted:t[2]||(t[2]=t=>e.$emit("actionExecuted")),"selected-resources":[r.resource.id.value],"show-headings":!0},{trigger:(0,o.withCtx)((()=>[(0,o.createVNode)(c,{variant:"action",icon:"ellipsis-horizontal",dusk:`${r.resource.id.value}-control-selector`},null,8,["dusk"])])),menu:(0,o.withCtx)((()=>[r.resource.authorizedToView&&r.resource.previewHasFields||r.resource.authorizedToReplicate||e.currentUser.canImpersonate&&r.resource.authorizedToImpersonate?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createVNode)(d,null,{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Actions")),1)])),_:1}),(0,o.createElementVNode)("div",l,[r.resource.authorizedToView&&r.resource.previewHasFields?((0,o.openBlock)(),(0,o.createBlock)(u,{key:0,dusk:`${r.resource.id.value}-preview-button`,as:"button",onClick:t[0]||(t[0]=(0,o.withModifiers)((t=>e.$emit("show-preview")),["prevent"])),title:e.__("Preview")},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Preview")),1)])),_:1},8,["dusk","title"])):(0,o.createCommentVNode)("",!0),r.resource.authorizedToReplicate?((0,o.openBlock)(),(0,o.createBlock)(u,{key:1,dusk:`${r.resource.id.value}-replicate-button`,href:e.$url(`/resources/${e.resourceName}/${r.resource.id.value}/replicate`,{viaResource:e.viaResource,viaResourceId:e.viaResourceId,viaRelationship:e.viaRelationship}),title:e.__("Replicate")},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Replicate")),1)])),_:1},8,["dusk","href","title"])):(0,o.createCommentVNode)("",!0),e.currentUser.canImpersonate&&r.resource.authorizedToImpersonate?((0,o.openBlock)(),(0,o.createBlock)(u,{key:2,as:"button",dusk:`${r.resource.id.value}-impersonate-button`,onClick:t[1]||(t[1]=(0,o.withModifiers)((t=>e.startImpersonating({resource:e.resourceName,resourceId:r.resource.id.value})),["prevent"])),title:e.__("Impersonate")},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Impersonate")),1)])),_:1},8,["dusk","title"])):(0,o.createCommentVNode)("",!0)])])):(0,o.createCommentVNode)("",!0)])),_:1},8,["resource","actions","via-resource","via-resource-id","via-relationship","resource-name","selected-resources"])}],["__file","InlineActionDropdown.vue"]])},81518:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726),i=r(30043),l=r(74640);const a={key:0,ref:"selectedStatus",class:"rounded-lg h-9 inline-flex items-center text-gray-600 dark:text-gray-400"},n={class:"inline-flex items-center gap-1 pl-1"},s={class:"font-bold"},c={class:"p-4 flex flex-col items-start gap-4"},d={__name:"SelectAllDropdown",props:{currentPageCount:{type:Number,default:0},allMatchingResourceCount:{type:Number,default:0}},emits:["toggle-select-all","toggle-select-all-matching","deselect"],setup(e){const t=(0,o.inject)("selectedResourcesCount"),r=(0,o.inject)("selectAllChecked"),d=(0,o.inject)("selectAllMatchingChecked"),u=(0,o.inject)("selectAllAndSelectAllMatchingChecked"),p=(0,o.inject)("selectAllOrSelectAllMatchingChecked"),h=(0,o.inject)("selectAllIndeterminate");return(m,f)=>{const v=(0,o.resolveComponent)("CircleBadge"),g=(0,o.resolveComponent)("DropdownMenu"),y=(0,o.resolveComponent)("Dropdown");return(0,o.openBlock)(),(0,o.createBlock)(y,{placement:"bottom-start",dusk:"select-all-dropdown"},{menu:(0,o.withCtx)((()=>[(0,o.createVNode)(g,{direction:"ltr",width:"250"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",c,[(0,o.createVNode)((0,o.unref)(l.Checkbox),{onChange:f[1]||(f[1]=e=>m.$emit("toggle-select-all")),"model-value":(0,o.unref)(r),dusk:"select-all-button"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(m.__("Select this page")),1),(0,o.createVNode)(v,null,{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.currentPageCount),1)])),_:1})])),_:1},8,["model-value"]),(0,o.createVNode)((0,o.unref)(l.Checkbox),{onChange:f[2]||(f[2]=e=>m.$emit("toggle-select-all-matching")),"model-value":(0,o.unref)(d),dusk:"select-all-matching-button"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(m.__("Select all")),1),(0,o.createVNode)(v,{dusk:"select-all-matching-count"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.allMatchingResourceCount),1)])),_:1})])])),_:1},8,["model-value"])])])),_:1})])),default:(0,o.withCtx)((()=>[(0,o.createVNode)((0,o.unref)(l.Button),{variant:"ghost","trailing-icon":"chevron-down",class:(0,o.normalizeClass)(["-ml-1",{"enabled:bg-gray-700/5 dark:enabled:bg-gray-950":(0,o.unref)(p)||(0,o.unref)(t)>0}]),dusk:"select-all-dropdown-trigger"},{default:(0,o.withCtx)((()=>[(0,o.createVNode)((0,o.unref)(l.Checkbox),{"aria-label":m.__("Select this page"),indeterminate:(0,o.unref)(h),"model-value":(0,o.unref)(u),class:"pointer-events-none",dusk:"select-all-indicator",tabindex:"-1"},null,8,["aria-label","indeterminate","model-value"]),(0,o.unref)(t)>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",a,[(0,o.createElementVNode)("span",n,[(0,o.createElementVNode)("span",s,(0,o.toDisplayString)(m.__(":amount selected",{amount:(0,o.unref)(d)?e.allMatchingResourceCount:(0,o.unref)(t),label:(0,o.unref)(i.singularOrPlural)((0,o.unref)(t),"resources")})),1)]),(0,o.createVNode)((0,o.unref)(l.Button),{onClick:f[0]||(f[0]=(0,o.withModifiers)((e=>m.$emit("deselect")),["stop"])),variant:"link",icon:"x-circle",size:"small",state:"mellow",class:"-mr-2","aria-label":m.__("Deselect All"),dusk:"deselect-all-button"},null,8,["aria-label"])],512)):(0,o.createCommentVNode)("",!0)])),_:1},8,["class"])])),_:1})}}};const u=(0,r(66262).A)(d,[["__file","SelectAllDropdown.vue"]])},32657:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i={class:"flex flex-col py-1 px-1"};var l=r(74640);const a={components:{Button:l.Button,Icon:l.Icon},data:()=>({theme:"system",listener:null,matcher:window.matchMedia("(prefers-color-scheme: dark)"),themes:["light","dark"]}),mounted(){Nova.config("themeSwitcherEnabled")?(this.themes.includes(localStorage.novaTheme)&&(this.theme=localStorage.novaTheme),this.listener=()=>{"system"===this.theme&&this.applyColorScheme()},this.matcher.addEventListener("change",this.listener)):localStorage.removeItem("novaTheme")},beforeUnmount(){Nova.config("themeSwitcherEnabled")&&this.matcher.removeEventListener("change",this.listener)},watch:{theme(e){"light"===e&&(localStorage.novaTheme="light",document.documentElement.classList.remove("dark")),"dark"===e&&(localStorage.novaTheme="dark",document.documentElement.classList.add("dark")),"system"===e&&(localStorage.removeItem("novaTheme"),this.applyColorScheme())}},methods:{applyColorScheme(){Nova.config("themeSwitcherEnabled")&&(window.matchMedia("(prefers-color-scheme: dark)").matches?document.documentElement.classList.add("dark"):document.documentElement.classList.remove("dark"))},toggleLightTheme(){this.theme="light"},toggleDarkTheme(){this.theme="dark"},toggleSystemTheme(){this.theme="system"}},computed:{themeSwitcherEnabled:()=>Nova.config("themeSwitcherEnabled"),themeIcon(){return{light:"sun",dark:"moon",system:"computer-desktop"}[this.theme]},themeColor(){return{light:"text-primary-500",dark:"dark:text-primary-500",system:""}[this.theme]}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("Button"),c=(0,o.resolveComponent)("Icon"),d=(0,o.resolveComponent)("DropdownMenuItem"),u=(0,o.resolveComponent)("DropdownMenu"),p=(0,o.resolveComponent)("Dropdown");return n.themeSwitcherEnabled?((0,o.openBlock)(),(0,o.createBlock)(p,{key:0,placement:"bottom-end"},{menu:(0,o.withCtx)((()=>[(0,o.createVNode)(u,{width:"auto"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("nav",i,[(0,o.createVNode)(d,{as:"button",size:"small",class:"flex items-center gap-2",onClick:n.toggleLightTheme},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(c,{name:"sun",type:"micro"}),(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(e.__("Light")),1)])),_:1},8,["onClick"]),(0,o.createVNode)(d,{as:"button",class:"flex items-center gap-2",onClick:n.toggleDarkTheme},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(c,{name:"moon",type:"micro"}),(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(e.__("Dark")),1)])),_:1},8,["onClick"]),(0,o.createVNode)(d,{as:"button",class:"flex items-center gap-2",onClick:n.toggleSystemTheme},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(c,{name:"computer-desktop",type:"micro"}),(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(e.__("System")),1)])),_:1},8,["onClick"])])])),_:1})])),default:(0,o.withCtx)((()=>[(0,o.createVNode)(s,{variant:"action",icon:n.themeIcon,class:(0,o.normalizeClass)(n.themeColor)},null,8,["icon","class"])])),_:1})):(0,o.createCommentVNode)("",!0)}],["__file","ThemeDropdown.vue"]])},30422:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>d});var o=r(29726);const i={key:0,class:"break-normal"},l=["innerHTML"],a={key:1,class:"break-normal"},n=["innerHTML"],s={key:2};const c={props:{plainText:{type:Boolean,default:!1},shouldShow:{type:Boolean,default:!1},content:{type:String}},data:()=>({expanded:!1}),methods:{toggle(){this.expanded=!this.expanded}},computed:{hasContent(){return""!==this.content&&null!==this.content},showHideLabel(){return this.expanded?this.__("Hide Content"):this.__("Show Content")}}};const d=(0,r(66262).A)(c,[["render",function(e,t,r,c,d,u){return r.shouldShow&&u.hasContent?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["prose prose-sm dark:prose-invert text-gray-500 dark:text-gray-400",{"whitespace-pre-wrap":r.plainText}]),innerHTML:r.content},null,10,l)])):u.hasContent?((0,o.openBlock)(),(0,o.createElementBlock)("div",a,[e.expanded?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,class:(0,o.normalizeClass)(["prose prose-sm dark:prose-invert max-w-none text-gray-500 dark:text-gray-400",{"whitespace-pre-wrap":r.plainText}]),innerHTML:r.content},null,10,n)):(0,o.createCommentVNode)("",!0),r.shouldShow?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:1,type:"button",onClick:t[0]||(t[0]=(...e)=>u.toggle&&u.toggle(...e)),class:(0,o.normalizeClass)(["link-default",{"mt-6":e.expanded}]),"aria-role":"button",tabindex:"0"},(0,o.toDisplayString)(u.showHideLabel),3))])):((0,o.openBlock)(),(0,o.createElementBlock)("div",s,"—"))}],["__file","Excerpt.vue"]])},27284:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={},l=(0,r(66262).A)(i,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createBlock)(o.Transition,{"enter-active-class":"transition duration-100 ease-out","enter-from-class":"transform opacity-0","enter-to-class":"transform opacity-100","leave-active-class":"transition duration-200 ease-out","leave-from-class":"transform opacity-100","leave-to-class":"transform opacity-0",mode:"out-in"},{default:(0,o.withCtx)((()=>[(0,o.renderSlot)(e.$slots,"default")])),_:3})}],["__file","FadeTransition.vue"]])},46854:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={__name:"FieldWrapper",props:{stacked:{type:Boolean,default:!1}},setup:e=>(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(["flex flex-col",{"md:flex-row":!e.stacked}])},[(0,o.renderSlot)(t.$slots,"default")],2))};const l=(0,r(66262).A)(i,[["__file","FieldWrapper.vue"]])},15604:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i={class:"divide-y divide-gray-200 dark:divide-gray-800 divide-solid"},l={key:0,class:"bg-gray-100"};const a={components:{Button:r(74640).Button},emits:["filter-changed","clear-selected-filters","trashed-changed","per-page-changed"],props:{activeFilterCount:Number,filters:Array,filtersAreApplied:Boolean,lens:{type:String,default:""},perPage:[String,Number],perPageOptions:Array,resourceName:String,softDeletes:Boolean,trashed:{type:String,validator:e=>["","with","only"].includes(e)},viaResource:String},methods:{handleFilterChanged(e){if(e){const{filterClass:t,value:r}=e;t&&(Nova.debug(`Updating filter state ${t}: ${r}`),this.$store.commit(`${this.resourceName}/updateFilterState`,{filterClass:t,value:r}))}this.$emit("filter-changed")},handleClearSelectedFiltersClick(){Nova.$emit("clear-filter-values"),setTimeout((()=>{this.$emit("trashed-changed",""),this.$emit("clear-selected-filters")}),500)}},computed:{filtersWithTrashedAreApplied(){return this.filtersAreApplied||""!==this.trashed},activeFilterWithTrashedCount(){const e=""!==this.trashed?1:0;return this.activeFilterCount+e},trashedValue:{set(e){let t=e?.target?.value||e;this.$emit("trashed-changed",t)},get(){return this.trashed}},perPageValue:{set(e){let t=e?.target?.value||e;this.$emit("per-page-changed",t)},get(){return this.perPage}},perPageOptionsForFilter(){return this.perPageOptions.map((e=>({value:e,label:e})))}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Button"),d=(0,o.resolveComponent)("SelectControl"),u=(0,o.resolveComponent)("FilterContainer"),p=(0,o.resolveComponent)("ScrollWrap"),h=(0,o.resolveComponent)("DropdownMenu"),m=(0,o.resolveComponent)("Dropdown");return(0,o.openBlock)(),(0,o.createBlock)(m,{dusk:"filter-selector","should-close-on-blur":!1},{menu:(0,o.withCtx)((()=>[(0,o.createVNode)(h,{width:"260",dusk:"filter-menu"},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(p,{height:350,class:"bg-white dark:bg-gray-900"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[s.filtersWithTrashedAreApplied?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[(0,o.createElementVNode)("button",{class:"py-2 w-full block text-xs uppercase tracking-wide text-center text-gray-500 dark:bg-gray-800 dark:hover:bg-gray-700 font-bold focus:outline-none focus:text-primary-500",onClick:t[0]||(t[0]=(...e)=>s.handleClearSelectedFiltersClick&&s.handleClearSelectedFiltersClick(...e))},(0,o.toDisplayString)(e.__("Reset Filters")),1)])):(0,o.createCommentVNode)("",!0),((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.filters,((e,t)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:`${e.class}-${t}`},[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(e.component),{"filter-key":e.class,lens:r.lens,"resource-name":r.resourceName,onChange:s.handleFilterChanged},null,40,["filter-key","lens","resource-name","onChange"]))])))),128)),r.softDeletes?((0,o.openBlock)(),(0,o.createBlock)(u,{key:1,dusk:"filter-soft-deletes"},{filter:(0,o.withCtx)((()=>[(0,o.createVNode)(d,{modelValue:s.trashedValue,"onUpdate:modelValue":t[1]||(t[1]=e=>s.trashedValue=e),options:[{value:"",label:"—"},{value:"with",label:e.__("With Trashed")},{value:"only",label:e.__("Only Trashed")}],dusk:"trashed-select",size:"sm"},null,8,["modelValue","options"])])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(e.__("Trashed")),1)])),_:1})):(0,o.createCommentVNode)("",!0),r.viaResource?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createBlock)(u,{key:2,dusk:"filter-per-page"},{filter:(0,o.withCtx)((()=>[(0,o.createVNode)(d,{modelValue:s.perPageValue,"onUpdate:modelValue":t[2]||(t[2]=e=>s.perPageValue=e),options:s.perPageOptionsForFilter,dusk:"per-page-select",size:"sm"},null,8,["modelValue","options"])])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(e.__("Per Page")),1)])),_:1}))])])),_:1})])),_:1})])),default:(0,o.withCtx)((()=>[(0,o.createVNode)(c,{variant:s.filtersWithTrashedAreApplied?"solid":"ghost",dusk:"filter-selector-button",icon:"funnel","trailing-icon":"chevron-down",padding:"tight",label:s.activeFilterWithTrashedCount>0?s.activeFilterWithTrashedCount:"","aria-label":e.__("Filter Dropdown")},null,8,["variant","label","aria-label"])])),_:1})}],["__file","FilterMenu.vue"]])},10255:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"space-y-2 mt-2"};const l={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},options(){return this.$store.getters[`${this.resourceName}/getOptionsForFilter`](this.filterKey)}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("BooleanOption"),c=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(c,null,{filter:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(n.options,(i=>((0,o.openBlock)(),(0,o.createBlock)(s,{key:i.value,"resource-name":r.resourceName,filter:n.filter,option:i,label:"label",onChange:t[0]||(t[0]=t=>e.$emit("change")),dusk:`${n.filter.uniqueKey}-${i.value}-option`},null,8,["resource-name","filter","option","dusk"])))),128))])])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(n.filter.name),1)])),_:1})}],["__file","BooleanFilter.vue"]])},2891:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i=["value","placeholder","dusk"];const l={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},methods:{handleChange(e){let t=e.target.value;this.$store.commit(`${this.resourceName}/updateFilterState`,{filterClass:this.filterKey,value:t}),this.$emit("change")}},computed:{placeholder(){return this.filter.placeholder||this.__("Choose date")},filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},value(){return this.filter.currentValue},options(){return this.$store.getters[`${this.resourceName}/getOptionsForFilter`](this.filterKey)}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(s,null,{filter:(0,o.withCtx)((()=>[(0,o.createElementVNode)("input",{ref:"dateField",onChange:t[0]||(t[0]=(...e)=>n.handleChange&&n.handleChange(...e)),type:"date",name:"date-filter",value:n.value,autocomplete:"off",class:"w-full h-8 flex form-control form-input form-control-bordered text-xs",placeholder:n.placeholder,dusk:n.filter.uniqueKey},null,40,i)])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(n.filter.name),1)])),_:1})}],["__file","DateFilter.vue"]])},56138:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={class:"pt-2 pb-3"},l={class:"px-3 text-xs uppercase font-bold tracking-wide"},a={class:"mt-1 px-3"};const n={},s=(0,r(66262).A)(n,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("h3",l,[(0,o.renderSlot)(e.$slots,"default")]),(0,o.createElementVNode)("div",a,[(0,o.renderSlot)(e.$slots,"filter")])])}],["__file","FilterContainer.vue"]])},84183:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726);const i={key:0,class:"flex items-center"},l={class:"flex items-center"},a={class:"flex-auto"},n=["selected"];var s=r(38221),c=r.n(s);const d={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},data:()=>({value:null,debouncedEventEmitter:null,search:"",availableOptions:[]}),created(){this.debouncedEventEmitter=c()((()=>this.emitFilterChange()),500),this.initializeComponent(),Nova.$on("filter-active",this.handleClosingInactiveSearchInputs)},mounted(){Nova.$on("filter-reset",this.handleFilterReset)},beforeUnmount(){Nova.$off("filter-active",this.handleClosingInactiveSearchInputs),Nova.$off("filter-reset",this.handleFilterReset)},watch:{value(){this.debouncedEventEmitter()}},methods:{initializeComponent(){this.filter.currentValue&&this.setCurrentFilterValue()},setCurrentFilterValue(){this.value=this.filter.currentValue},emitFilterChange(){this.$store.commit(`${this.resourceName}/updateFilterState`,{filterClass:this.filterKey,value:this.value??""}),this.$emit("change")},handleShowingActiveSearchInput(){Nova.$emit("filter-active",this.filterKey)},closeSearchableRef(){this.$refs.searchable&&this.$refs.searchable.close()},handleClosingInactiveSearchInputs(e){e!==this.filterKey&&this.closeSearchableRef()},handleClearSearchInput(){this.clearSelection()},handleFilterReset(){""==this.filter.currentValue&&(this.clearSelection(),this.closeSearchableRef(),this.initializeComponent())},clearSelection(){this.value=null,this.availableOptions=[]},performSearch(e){this.search=e;const t=e.trim();""!=t&&this.searchOptions(t)},searchOptions(e){this.availableOptions=this.options.filter((t=>t.label?.includes(e)))},searchDebouncer:c()((e=>e()),500)},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},options(){return this.filter.options},isSearchable(){return this.filter.searchable},selectedOption(){return this.options.find((e=>this.value===e.value||this.value===e.value.toString()))}}};const u=(0,r(66262).A)(d,[["render",function(e,t,r,s,c,d){const u=(0,o.resolveComponent)("SearchInput"),p=(0,o.resolveComponent)("SelectControl"),h=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(h,null,{filter:(0,o.withCtx)((()=>[d.isSearchable?((0,o.openBlock)(),(0,o.createBlock)(u,{key:0,ref:"searchable",modelValue:e.value,"onUpdate:modelValue":t[0]||(t[0]=t=>e.value=t),onInput:d.performSearch,onClear:d.handleClearSearchInput,onShown:d.handleShowingActiveSearchInput,options:e.availableOptions,clearable:!0,trackBy:"value",mode:"modal",class:"w-full",dusk:`${d.filter.uniqueKey}-search-input`},{option:(0,o.withCtx)((({selected:e,option:t})=>[(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("div",a,[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["text-sm font-semibold leading-normal",{"text-white dark:text-gray-900":e}])},(0,o.toDisplayString)(t.label),3)])])])),default:(0,o.withCtx)((()=>[d.selectedOption?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,(0,o.toDisplayString)(d.selectedOption.label),1)):(0,o.createCommentVNode)("",!0)])),_:1},8,["modelValue","onInput","onClear","onShown","options","dusk"])):d.options.length>0?((0,o.openBlock)(),(0,o.createBlock)(p,{key:1,modelValue:e.value,"onUpdate:modelValue":t[1]||(t[1]=t=>e.value=t),options:d.options,size:"sm",label:"label",class:"w-full block",dusk:d.filter.uniqueKey},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("option",{value:"",selected:""==e.value},(0,o.toDisplayString)(e.__("—")),9,n)])),_:1},8,["modelValue","options","dusk"])):(0,o.createCommentVNode)("",!0)])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(d.filter.name),1)])),_:1})}],["__file","SelectFilter.vue"]])},81433:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i=["action"],l=["name","value"],a=["value"],n=Object.assign({inheritAttrs:!1},{__name:"FormButton",props:{href:{type:String,required:!0},method:{type:String,required:!0},data:{type:Object,required:!1,default:{}},headers:{type:Object,required:!1,default:null},component:{type:String,default:"button"}},setup(e){const t=e;function r(e){null!=t.headers&&(e.preventDefault(),Nova.$router.visit(t.href,{method:t.method,data:t.data,headers:t.headers}))}return(t,n)=>((0,o.openBlock)(),(0,o.createElementBlock)("form",{action:e.href,method:"POST",onSubmit:r,dusk:"form-button"},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.data,((e,t)=>((0,o.openBlock)(),(0,o.createElementBlock)("input",{type:"hidden",name:t,value:e},null,8,l)))),256)),"POST"!==e.method?((0,o.openBlock)(),(0,o.createElementBlock)("input",{key:0,type:"hidden",name:"_method",value:e.method},null,8,a)):(0,o.createCommentVNode)("",!0),((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(e.component),(0,o.mergeProps)(t.$attrs,{type:"submit"}),{default:(0,o.withCtx)((()=>[(0,o.renderSlot)(t.$slots,"default")])),_:3},16))],40,i))}});const s=(0,r(66262).A)(n,[["__file","FormButton.vue"]])},62415:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i=["for"],l={__name:"FormLabel",props:{labelFor:{type:String,required:!1}},setup:e=>(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("label",{for:e.labelFor,class:"inline-block leading-tight"},[(0,o.renderSlot)(t.$slots,"default")],8,i))};const a=(0,r(66262).A)(l,[["__file","FormLabel.vue"]])},36623:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>R});var o=r(29726);const i={class:"flex items-center w-full max-w-xs h-12"},l={class:"flex-1 relative"},a={class:"relative z-10",ref:"searchInput"},n=["placeholder","aria-label","aria-expanded"],s={ref:"results",class:"w-full max-w-lg z-10"},c={key:0,class:"bg-white dark:bg-gray-800 py-6 rounded-lg shadow-lg w-full mt-2 max-h-[calc(100vh-5em)] overflow-x-hidden overflow-y-auto"},d={key:1,dusk:"global-search-results",class:"bg-white dark:bg-gray-800 rounded-lg shadow-lg w-full mt-2 max-h-[calc(100vh-5em)] overflow-x-hidden overflow-y-auto",ref:"container"},u={class:"text-xs font-bold uppercase tracking-wide bg-gray-300 dark:bg-gray-900 py-2 px-3"},p=["dusk","onClick"],h=["src"],m={class:"flex-auto text-left"},f={key:0,class:"text-xs mt-1"},v={key:2,dusk:"global-search-empty-results",class:"bg-white dark:bg-gray-800 overflow-hidden rounded-lg shadow-lg w-full mt-2 max-h-search overflow-y-auto"},g={class:"text-xs font-bold uppercase tracking-wide bg-40 py-4 px-3"};var y=r(98234),b=r(53110),k=r(74640),w=r(38221),C=r.n(w),x=r(50014),N=r.n(x);function B(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function S(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const V={components:{Icon:k.Icon},data:()=>({searchFunction:null,canceller:null,showOverlay:!1,loading:!1,resultsVisible:!1,searchTerm:"",results:[],selected:0}),watch:{searchTerm(e){null!==this.canceller&&this.canceller(),""===e?(this.resultsVisible=!1,this.selected=-1,this.results=[]):this.search()},resultsVisible(e){!0!==e?document.body.classList.remove("overflow-y-hidden"):document.body.classList.add("overflow-y-hidden")}},created(){this.searchFunction=C()((async()=>{if(this.showOverlay=!0,this.$nextTick((()=>{this.popper=(0,y.n4)(this.$refs.searchInput,this.$refs.results,{placement:"bottom-start",boundary:"viewPort",modifiers:[{name:"offset",options:{offset:[0,8]}}]})})),""===this.searchTerm)return this.canceller(),this.resultsVisible=!1,void(this.results=[]);this.resultsVisible=!0,this.loading=!0,this.results=[],this.selected=0;try{const{data:r}=await(e=this.searchTerm,t=e=>this.canceller=e,Nova.request().get("/nova-api/search",{params:{search:e},cancelToken:new b.qm((e=>t(e)))}));this.results=r,this.loading=!1}catch(e){if((0,b.FZ)(e))return;throw this.loading=!1,e}var e,t}),Nova.config("debounce"))},mounted(){Nova.addShortcut("/",(()=>(this.focusSearch(),!1)))},beforeUnmount(){null!==this.canceller&&this.canceller(),this.resultsVisible=!1,Nova.disableShortcut("/")},methods:{async focusSearch(){this.results.length>0&&(this.showOverlay=!0,this.resultsVisible=!0,await this.popper.update()),this.$refs.input.focus()},closeSearch(){this.$refs.input.blur(),this.resultsVisible=!1,this.showOverlay=!1},search(){this.searchFunction()},move(e){if(this.results.length){let t=this.selected+e;t<0?(this.selected=this.results.length-1,this.updateScrollPosition()):t>this.results.length-1?(this.selected=0,this.updateScrollPosition()):t>=0&&t<this.results.length&&(this.selected=t,this.updateScrollPosition())}},updateScrollPosition(){const e=this.$refs.selected,t=this.$refs.container;this.$nextTick((()=>{e&&(e[0].offsetTop>t.scrollTop+t.clientHeight-e[0].clientHeight&&(t.scrollTop=e[0].offsetTop+e[0].clientHeight-t.clientHeight),e[0].offsetTop<t.scrollTop&&(t.scrollTop=e[0].offsetTop))}))},goToCurrentlySelectedResource(e){if(!e.isComposing&&229!==e.keyCode&&""!==this.searchTerm){const e=this.indexedResults.find((e=>e.index===this.selected));this.goToSelectedResource(e,!1)}},goToSelectedResource(e,t=!1){if(null!==this.canceller&&this.canceller(),this.closeSearch(),null==e)return;let r=Nova.url(`/resources/${e.resourceName}/${e.resourceId}`);"edit"===e.linksTo&&(r+="/edit"),t?window.open(r,"_blank"):Nova.visit({url:r,remote:!1})}},computed:{indexedResults(){return this.results.map(((e,t)=>function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?B(Object(r),!0).forEach((function(t){S(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):B(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({index:t},e)))},formattedGroups(){return N()(this.indexedResults.map((e=>({resourceName:e.resourceName,resourceTitle:e.resourceTitle}))),"resourceName")},formattedResults(){return this.formattedGroups.map((e=>({resourceName:e.resourceName,resourceTitle:e.resourceTitle,items:this.indexedResults.filter((t=>t.resourceName===e.resourceName))})))}}};const R=(0,r(66262).A)(V,[["render",function(e,t,r,y,b,k){const w=(0,o.resolveComponent)("Icon"),C=(0,o.resolveComponent)("Loader"),x=(0,o.resolveComponent)("Backdrop");return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("div",a,[(0,o.createVNode)(w,{name:"magnifying-glass",type:"mini",class:"absolute ml-2 text-gray-400",style:{top:"4px"}}),(0,o.withDirectives)((0,o.createElementVNode)("input",{dusk:"global-search",ref:"input",onKeydown:[t[0]||(t[0]=(0,o.withKeys)((0,o.withModifiers)(((...e)=>k.goToCurrentlySelectedResource&&k.goToCurrentlySelectedResource(...e)),["stop"]),["enter"])),t[1]||(t[1]=(0,o.withKeys)((0,o.withModifiers)(((...e)=>k.closeSearch&&k.closeSearch(...e)),["stop"]),["esc"])),t[2]||(t[2]=(0,o.withKeys)((0,o.withModifiers)((e=>k.move(1)),["prevent"]),["down"])),t[3]||(t[3]=(0,o.withKeys)((0,o.withModifiers)((e=>k.move(-1)),["prevent"]),["up"]))],"onUpdate:modelValue":t[4]||(t[4]=t=>e.searchTerm=t),onFocus:t[5]||(t[5]=(...e)=>k.focusSearch&&k.focusSearch(...e)),type:"search",placeholder:e.__("Press / to search"),class:"appearance-none rounded-full h-8 pl-10 w-full bg-gray-100 dark:bg-gray-900 dark:focus:bg-gray-800 focus:bg-white focus:outline-none focus:ring focus:ring-primary-200 dark:focus:ring-gray-600",role:"search","aria-label":e.__("Search"),"aria-expanded":!0===e.resultsVisible?"true":"false",spellcheck:"false"},null,40,n),[[o.vModelText,e.searchTerm]])],512),((0,o.openBlock)(),(0,o.createBlock)(o.Teleport,{to:"body"},[(0,o.createVNode)(o.Transition,{"enter-active-class":"transition duration-100 ease-out","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"transition duration-200 ease-in","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:(0,o.withCtx)((()=>[(0,o.withDirectives)((0,o.createElementVNode)("div",s,[e.loading?((0,o.openBlock)(),(0,o.createElementBlock)("div",c,[(0,o.createVNode)(C,{class:"text-gray-300",width:"40"})])):(0,o.createCommentVNode)("",!0),e.results.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",d,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(k.formattedResults,(t=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:t.resourceTitle},[(0,o.createElementVNode)("h3",u,(0,o.toDisplayString)(t.resourceTitle),1),(0,o.createElementVNode)("ul",null,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(t.items,(t=>((0,o.openBlock)(),(0,o.createElementBlock)("li",{key:t.resourceName+" "+t.index,ref_for:!0,ref:t.index===e.selected?"selected":null},[(0,o.createElementVNode)("button",{dusk:t.resourceName+" "+t.index,onClick:[(0,o.withModifiers)((e=>k.goToSelectedResource(t,!1)),["exact"]),(0,o.withModifiers)((e=>k.goToSelectedResource(t,!0)),["ctrl"]),(0,o.withModifiers)((e=>k.goToSelectedResource(t,!0)),["meta"])],class:(0,o.normalizeClass)(["w-full flex items-center hover:bg-gray-100 dark:hover:bg-gray-700 text-gray-600 hover:text-gray-500 dark:text-gray-400 dark:hover:text-gray-300 py-2 px-3 no-underline font-normal",{"bg-white dark:bg-gray-800":e.selected!==t.index,"bg-gray-100 dark:bg-gray-700":e.selected===t.index}])},[t.avatar?((0,o.openBlock)(),(0,o.createElementBlock)("img",{key:0,src:t.avatar,class:(0,o.normalizeClass)(["flex-none h-8 w-8 mr-3",{"rounded-full":t.rounded,rounded:!t.rounded}])},null,10,h)):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",m,[(0,o.createElementVNode)("p",null,(0,o.toDisplayString)(t.title),1),t.subTitle?((0,o.openBlock)(),(0,o.createElementBlock)("p",f,(0,o.toDisplayString)(t.subTitle),1)):(0,o.createCommentVNode)("",!0)])],10,p)])))),128))])])))),128))],512)):(0,o.createCommentVNode)("",!0),e.loading||0!==e.results.length?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createElementBlock)("div",v,[(0,o.createElementVNode)("h3",g,(0,o.toDisplayString)(e.__("No Results Found.")),1)]))],512),[[o.vShow,e.resultsVisible]])])),_:1}),(0,o.createVNode)(o.Transition,{"enter-active-class":"transition duration-100 ease-out","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"transition duration-200 ease-in","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(x,{onClick:k.closeSearch,show:e.showOverlay,class:"bg-gray-500/75 dark:bg-gray-900/75 z-0"},null,8,["onClick","show"])])),_:1})]))])])}],["__file","GlobalSearch.vue"]])},13750:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={1:"font-normal text-xl md:text-xl",2:"font-normal md:text-xl",3:"uppercase tracking-wide font-bold text-xs",4:"font-normal md:text-2xl"},l={props:{dusk:{type:String,default:"heading"},level:{default:1,type:Number}},computed:{component(){return"h"+this.level},classes(){return i[this.level]}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,i,l,a){return(0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(a.component),{class:(0,o.normalizeClass)(a.classes),dusk:r.dusk},{default:(0,o.withCtx)((()=>[(0,o.renderSlot)(e.$slots,"default")])),_:3},8,["class","dusk"])}],["__file","Heading.vue"]])},91303:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"help-text"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("p",i,[(0,o.renderSlot)(e.$slots,"default")])}],["__file","HelpText.vue"]])},6491:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726),i=r(74640);const l={key:0,class:"absolute right-0 bottom-0 p-2 z-20"},a=["innerHTML"],n={__name:"HelpTextTooltip",props:{text:{type:String},width:{type:[Number,String]}},setup:e=>(t,r)=>{const n=(0,o.resolveComponent)("TooltipContent"),s=(0,o.resolveComponent)("Tooltip");return e.text?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[(0,o.createElementVNode)("span",{class:"sr-only",innerHTML:e.text},null,8,a),(0,o.createVNode)(s,{triggers:["click"],placement:"top-start"},{content:(0,o.withCtx)((()=>[(0,o.createVNode)(n,{innerHTML:e.text,"max-width":e.width},null,8,["innerHTML","max-width"])])),default:(0,o.withCtx)((()=>[(0,o.createVNode)((0,o.unref)(i.Icon),{name:"question-mark-circle",type:"mini",class:"cursor-pointer text-gray-400 dark:text-gray-500"})])),_:1})])):(0,o.createCommentVNode)("",!0)}};const s=(0,r(66262).A)(n,[["__file","HelpTextTooltip.vue"]])},92407:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726),i=r(74640);const l={__name:"CopyIcon",props:{copied:{type:Boolean,default:!1}},setup(e){const t=e,r=(0,o.computed)((()=>!0===t.copied?"check-circle":"clipboard")),l=(0,o.computed)((()=>!0===t.copied?"text-green-500":"text-gray-400 dark:text-gray-500"));return(e,t)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(i.Icon),{name:r.value,type:"micro",class:(0,o.normalizeClass)(["!w-3 !h-3",l.value])},null,8,["name","class"]))}};const a=(0,r(66262).A)(l,[["__file","CopyIcon.vue"]])},74960:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("svg",i,t[0]||(t[0]=[(0,o.createElementVNode)("path",{d:"M3 19V1h8a5 5 0 0 1 3.88 8.16A5.5 5.5 0 0 1 11.5 19H3zm7.5-8H7v5h3.5a2.5 2.5 0 1 0 0-5zM7 4v4h3a2 2 0 1 0 0-4H7z"},null,-1)]))}],["__file","IconBold.vue"]])},76825:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("svg",i,t[0]||(t[0]=[(0,o.createElementVNode)("path",{d:"M2.8 15.8L0 13v7h7l-2.8-2.8 4.34-4.32-1.42-1.42L2.8 15.8zM17.2 4.2L20 7V0h-7l2.8 2.8-4.34 4.32 1.42 1.42L17.2 4.2zm-1.4 13L13 20h7v-7l-2.8 2.8-4.32-4.34-1.42 1.42 4.33 4.33zM4.2 2.8L7 0H0v7l2.8-2.8 4.32 4.34 1.42-1.42L4.2 2.8z"},null,-1)]))}],["__file","IconFullScreen.vue"]])},57404:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("svg",i,t[0]||(t[0]=[(0,o.createElementVNode)("path",{d:"M0 4c0-1.1.9-2 2-2h16a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V4zm11 9l-3-3-6 6h16l-5-5-2 2zm4-4a2 2 0 1 0 0-4 2 2 0 0 0 0 4z"},null,-1)]))}],["__file","IconImage.vue"]])},87446:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("svg",i,t[0]||(t[0]=[(0,o.createElementVNode)("path",{d:"M8 1h9v2H8V1zm3 2h3L8 17H5l6-14zM2 17h9v2H2v-2z"},null,-1)]))}],["__file","IconItalic.vue"]])},48309:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("svg",i,t[0]||(t[0]=[(0,o.createElementVNode)("path",{d:"M9.26 13a2 2 0 0 1 .01-2.01A3 3 0 0 0 9 5H5a3 3 0 0 0 0 6h.08a6.06 6.06 0 0 0 0 2H5A5 5 0 0 1 5 3h4a5 5 0 0 1 .26 10zm1.48-6a2 2 0 0 1-.01 2.01A3 3 0 0 0 11 15h4a3 3 0 0 0 0-6h-.08a6.06 6.06 0 0 0 0-2H15a5 5 0 0 1 0 10h-4a5 5 0 0 1-.26-10z"},null,-1)]))}],["__file","IconLink.vue"]])},49467:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 530 560"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("svg",i,t[0]||(t[0]=[(0,o.createStaticVNode)('<g fill="none" fill-rule="evenodd" transform="translate(4 10)"><path fill="#DDE4EB" d="M0 185a19.4 19.4 0 0 1 19.4-19.4h37.33a19.4 19.4 0 0 0 0-38.8H45.08a19.4 19.4 0 1 1 0-38.8h170.84a19.4 19.4 0 0 1 0 38.8h-6.87a19.4 19.4 0 0 0 0 38.8h42.55a19.4 19.4 0 0 1 0 38.8H19.4A19.4 19.4 0 0 1 0 185z"></path><g stroke-width="2" transform="rotate(-30 383.9199884 -24.79114317)"><rect width="32.4" height="9.19" x="12.47" y="3.8" fill="#FFF" stroke="#0D2B3E" rx="4.6"></rect><rect width="32.4" height="14.79" x="1" y="1" fill="#FFF" stroke="#0D2B3E" rx="7.39"></rect><ellipse cx="8.6" cy="8.39" stroke="#4A90E2" rx="7.6" ry="7.39" style="mix-blend-mode:multiply;"></ellipse></g><path fill="#E0EEFF" d="M94 198.256L106.6 191l22.4 16.744L116.4 215zM48 164.256L60.6 157 83 173.744 70.4 181z" opacity=".58"></path><path stroke="#0D2B3E" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M88 188l9 7-9-7zm-15-11l5 3-5-3z"></path><path stroke="#4A90E2" stroke-width="2" d="M92.82 198.36l20.65 15.44 10.71-6.16-20.65-15.44-10.71 6.16zM119 211l-22-17 22 17zm-72.18-46.64l20.65 15.44 10.71-6.16-20.65-15.44-10.71 6.16zM73 178l-22-17 22 17z"></path><path stroke="#8DDCFF" stroke-linecap="round" stroke-width="2" d="M117 176a14 14 0 0 0-14-14m10 15a10 10 0 0 0-10-10"></path><ellipse cx="258" cy="441" fill="#FFF" rx="250" ry="90"></ellipse><path fill="#FFF" fill-rule="nonzero" stroke="#0D2B3E" stroke-width="2" d="M195.95992276 433.88207738c-.7613033-1.55811337-1.97677352-5.39619.01107483-6.1324365 1.97685786-.72734656 2.77032762 2.34241006 4.31210683 4.22387675 2.92231431 3.57504952 6.28818967 5.22592295 11.14145652 5.73602185 1.77024897.18606067 3.51532102.0376574 5.19229942-.41955529a3.17 3.17 0 0 1 3.89461497 2.16898002 3.12 3.12 0 0 1-2.19463454 3.85169823c-2.43329264.66931826-4.97971626.88432232-7.54558275.61463889-7.06110546-.7421521-11.79595772-3.81390631-14.81133528-10.04322395z"></path><g stroke="#0D2B3E" stroke-width="2"><path fill="#FFF" fill-rule="nonzero" d="M228.66635404 453.35751889l3.48444585 6.7411525a11.71 11.71 0 0 0-3.36066168 18.19840799l3.157266 3.1573203-8.52104352 8.55618006-.29468882-6.6673277a19.31 19.31 0 0 1 5.53468217-29.98573315z"></path><path d="M221.75370493 481.33823157l5.9097851-4.56727928"></path></g><g stroke="#0D2B3E" stroke-width="2"><path fill="#FFF" fill-rule="nonzero" d="M217.43675157 454.38903415l-.38056208 7.58726384a10.25 10.25 0 0 0-10.62036709 8.5642456l.04580558 4.00318647-11.36366293-.10613565 3.84834642-5.16425501a17.82 17.82 0 0 1 18.46098491-14.88104957z"></path><path d="M199.40986905 468.0735658l7.07551171 1.72015522"></path></g><path fill="#E5F7FF" d="M233.41788355 435.98904264l3.14268919.33030994-3.01041974 28.64223059-3.1426892-.33030995z"></path><path stroke="#7ED7FF" stroke-width="2" d="M218.1633805 433.70198413l13.07796292 1.37454929 1.09127716-10.38280859a6.575 6.575 0 0 0-13.07796293-1.37454929l-1.09127715 10.38280859z"></path><path fill="#FFF" stroke="#0D2B3E" stroke-width="2" d="M221.02136188 434.25374714l.64389533-6.12625487a3.59 3.59 0 1 1 7.130722.74946908l-.64389534 6.12625488"></path><path stroke="#0D2B3E" stroke-width="2" d="M235.80327328 436.92350283l-20.28824667-2.13238065-2.86721575 27.27973559 20.28824667 2.13238065 2.86721575-27.2797356z"></path><path fill="#FFF" stroke="#0D2B3E" stroke-width="2" d="M215.51502661 434.79112218l-2.86721575 27.27973559 17.1555027 1.80311599 2.86721575-27.2797356-17.1555027-1.80311598z"></path><path fill="#FFF" stroke="#0D2B3E" stroke-width="2" d="M214.36589556 440.07997818l-1.09905036.88999343-1.17489993 11.1784261 11.15853567 1.17280937 1.09905036-.88999344 1.17385464-11.16848088-11.16848088-1.17385464z"></path><path fill="#FFF" fill-rule="nonzero" stroke="#0D2B3E" stroke-width="2" d="M245.62684398 462.24908175c-.41742893 1.6755456-1.95466376 5.39523768-3.94116941 4.68369338-1.99645087-.71258958-.63076284-3.56546466-.5955535-6.00514913.06313174-4.61870267-1.45795198-8.03642184-4.8492445-11.55015704-1.23234204-1.2858589-2.67505657-2.29217634-4.24858182-3.01059006a3.17 3.17 0 0 1-1.5730205-4.16725407 3.12 3.12 0 0 1 4.14422777-1.54527542c2.29328456 1.04544055 4.3804078 2.52169139 6.1770892 4.36961887 4.93145874 5.12354512 6.58580412 10.52606688 4.87526226 17.2340134z"></path><path stroke="#233242" stroke-width="2" d="M518 372.93A1509.66 1509.66 0 0 0 261 351c-87.62 0-173.5 7.51-257 21.93"></path><circle cx="51" cy="107" r="6" fill="#9AC2F0"></circle><path stroke="#031836" stroke-linecap="round" stroke-width="2" d="M48 116a6 6 0 1 0-6-6"></path><circle cx="501" cy="97" r="6" fill="#9AC2F0"></circle><path stroke="#031836" stroke-linecap="round" stroke-width="2" d="M498 106a6 6 0 1 0-6-6"></path><path fill="#031836" d="M305.75 0h.5a1 1 0 0 1 1 1v8a1 1 0 0 1-1 1h-.5a1 1 0 0 1-1-1V1a1 1 0 0 1 1-1zM321 14.75v.5a1 1 0 0 1-1 1h-8a1 1 0 0 1-1-1v-.5a1 1 0 0 1 1-1h8a1 1 0 0 1 1 1zM306.25 30h-.5a1 1 0 0 1-1-1v-8a1 1 0 0 1 1-1h.5a1 1 0 0 1 1 1v8a1 1 0 0 1-1 1zM291 15.25v-.5a1 1 0 0 1 1-1h8a1 1 0 0 1 1 1v.5a1 1 0 0 1-1 1h-8a1 1 0 0 1-1-1z"></path><path fill="#DDE4EB" d="M446 107.5a16.5 16.5 0 0 0 16.5 16.5h44a16.5 16.5 0 0 1 0 33h-143a16.5 16.5 0 0 1 0-33 16.5 16.5 0 0 0 0-33h-66a16.5 16.5 0 0 1 0-33h165a16.5 16.5 0 0 1 0 33 16.5 16.5 0 0 0-16.5 16.5z"></path><circle cx="458" cy="186" r="4" fill="#031836"></circle><circle cx="138" cy="16" r="4" fill="#031836"></circle><path stroke="#233242" stroke-width="2" d="M58 364.86l67.93-67.93a10 10 0 0 1 14.14 0L196 352.86m139-18l36.93-36.93a10 10 0 0 1 14.14 0L451 362.86"></path><path stroke="#233242" stroke-width="2" d="M176 332.86l70.93-71.84a10 10 0 0 1 14.19-.05L345 344.86"></path><g stroke-width="2" transform="rotate(-87 355.051 43.529)"><ellipse cx="10.28" cy="27.49" fill="#FFF" stroke="#0D2B3E" rx="9.21" ry="19.26"></ellipse><path fill="#FFF" stroke="#0D2B3E" d="M25.66 54.03c-7.52 0-13.62-12.1-13.62-27.02S18.14 0 25.66 0H96.1c7.22 0 14.15 2.85 19.26 7.91l19.26 19.1-19.26 19.1a27.35 27.35 0 0 1-19.26 7.92H25.66z"></path><path fill="#FFF" stroke="#4A90E2" d="M98.09 54.22c-7.52 0-13.62-12.1-13.62-27.02s6.1-27 13.62-27"></path><ellipse cx="59.59" cy="27.27" stroke="#4A90E2" rx="16.34" ry="16.21"></ellipse><ellipse cx="59.59" cy="27.27" fill="#FFF" stroke="#0D2B3E" rx="12.26" ry="12.16"></ellipse></g><g stroke="#233242" stroke-width="2" transform="translate(456 396)"><ellipse cx="30" cy="10" rx="20" ry="10"></ellipse><path d="M0 15c0 8.28 13.43 15 30 15m12.39-1.33C52.77 26.3 60 21.07 60 15"></path></g><g stroke="#233242" stroke-width="2" transform="translate(276 520)"><ellipse cx="20" cy="6.67" rx="13.33" ry="6.67"></ellipse><path d="M0 10c0 5.52 8.95 10 20 10m8.26-.89C35.18 17.54 40 14.05 40 10"></path></g><g stroke="#233242" stroke-width="2" transform="translate(186 370)"><ellipse cx="15" cy="5" rx="10" ry="5"></ellipse><path d="M0 7.5C0 11.64 6.72 15 15 15m6.2-.67c5.19-1.18 8.8-3.8 8.8-6.83"></path></g><ellipse cx="58" cy="492" fill="#202C3A" rx="3" ry="2"></ellipse><ellipse cx="468" cy="492" fill="#202C3A" rx="3" ry="2"></ellipse><ellipse cx="388" cy="392" fill="#202C3A" rx="3" ry="2"></ellipse><ellipse cx="338" cy="452" fill="#202C3A" rx="3" ry="2"></ellipse><g stroke="#233242" stroke-width="2" transform="translate(46 406)"><ellipse cx="40" cy="13.33" rx="26.67" ry="13.33"></ellipse><path d="M0 20c0 11.05 17.9 20 40 20m16.51-1.78C70.37 35.08 80 28.1 80 20"></path></g><g stroke="#0D2B3E" stroke-width="2"><path d="M299 378l-21 42m35-36l-21 42m4-42l14 6m-17 0l14 6m-17 0l14 6m-17 0l14 6m-17 0l14 6m-17 0l14 6"></path></g><circle cx="341" cy="155" r="25" stroke="#233242" stroke-width="2"></circle><circle cx="342" cy="156" r="20" fill="#FFF"></circle><path stroke="#233242" stroke-width="2" d="M321.56 140.5c-7.66.32-13 2.37-13.97 6-1.78 6.66 11.9 16.12 30.58 21.13 18.67 5 35.25 3.65 37.04-3.02.96-3.58-2.54-7.96-8.88-12.03"></path></g>',1)]))}],["__file","ErrorPageIcon.vue"]])},21449:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726),i=r(74640);const l={__name:"IconArrow",setup:e=>(e,t)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(i.Icon),{class:"shrink-0 text-gray-700 dark:text-gray-400",name:"chevron-down",type:"mini"}))};const a=(0,r(66262).A)(l,[["__file","IconArrow.vue"]])},16018:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726),i=r(74640);const l={__name:"IconBoolean",props:{value:{type:Boolean,default:!1},nullable:{type:Boolean,default:!1},type:{type:String,default:"solid",required:!1}},setup(e){const t=e,r=(0,o.computed)((()=>!0===t.value?"check-circle":null===t.value&&!0===t.nullable?"minus-circle":"x-circle")),l=(0,o.computed)((()=>!0===t.value?"text-green-500":null===t.value&&!0===t.nullable?"text-gray-200 dark:text-gray-800":"text-red-500"));return(t,a)=>((0,o.openBlock)(),(0,o.createElementBlock)("span",null,[(0,o.createVNode)((0,o.unref)(i.Icon),{name:r.value,type:e.type,class:(0,o.normalizeClass)(l.value)},null,8,["name","type","class"])]))}};const a=(0,r(66262).A)(l,[["__file","IconBoolean.vue"]])},18711:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={class:"ml-2"};function l(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function a(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?l(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):l(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function n(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const s={props:{resourceName:{type:String,required:!0},filter:Object,option:Object,label:{default:"name"}},methods:{labelFor(e){return e[this.label]||""},updateCheckedState(e,t){let r=a(a({},this.filter.currentValue),{},{[e]:t});this.$store.commit(`${this.resourceName}/updateFilterState`,{filterClass:this.filter.class,value:r}),this.$emit("change")}},computed:{currentValue(){let e=this.$store.getters[`${this.resourceName}/filterOptionValue`](this.filter.class,this.option.value);return null!=e?e:null},isChecked(){return 1==this.currentValue},nextValue(){let e=this.currentValue;return!0!==e&&(!1!==e||null)}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("IconBoolean");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:"flex items-center",onClick:t[0]||(t[0]=e=>n.updateCheckedState(r.option.value,n.nextValue))},[(0,o.createVNode)(s,{value:n.currentValue,nullable:!0},null,8,["value"]),(0,o.createElementVNode)("span",i,(0,o.toDisplayString)(n.labelFor(r.option)),1)])}],["__file","IconBooleanOption.vue"]])},47833:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i=["fill"],l={__name:"Loader",props:{width:{type:[Number,String],required:!1,default:50},fillColor:{type:String,required:!1,default:"currentColor"}},setup:e=>(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("svg",{class:"mx-auto block",style:(0,o.normalizeStyle)({width:`${e.width}px`}),viewBox:"0 0 120 30",xmlns:"http://www.w3.org/2000/svg",fill:e.fillColor},r[0]||(r[0]=[(0,o.createStaticVNode)('<circle cx="15" cy="15" r="15"><animate attributeName="r" from="15" to="15" begin="0s" dur="0.8s" values="15;9;15" calcMode="linear" repeatCount="indefinite"></animate><animate attributeName="fill-opacity" from="1" to="1" begin="0s" dur="0.8s" values="1;.5;1" calcMode="linear" repeatCount="indefinite"></animate></circle><circle cx="60" cy="15" r="9" fill-opacity="0.3"><animate attributeName="r" from="9" to="9" begin="0s" dur="0.8s" values="9;15;9" calcMode="linear" repeatCount="indefinite"></animate><animate attributeName="fill-opacity" from="0.5" to="0.5" begin="0s" dur="0.8s" values=".5;1;.5" calcMode="linear" repeatCount="indefinite"></animate></circle><circle cx="105" cy="15" r="15"><animate attributeName="r" from="15" to="15" begin="0s" dur="0.8s" values="15;9;15" calcMode="linear" repeatCount="indefinite"></animate><animate attributeName="fill-opacity" from="1" to="1" begin="0s" dur="0.8s" values="1;.5;1" calcMode="linear" repeatCount="indefinite"></animate></circle>',3)]),12,i))};const a=(0,r(66262).A)(l,[["__file","Loader.vue"]])},12617:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726),i=r(74640),l=r(65835);function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function n(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?a(Object(r),!0).forEach((function(t){s(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function s(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const c={key:0},d=["src"],u=["href"],p=Object.assign({inheritAttrs:!1},{__name:"ImageLoader",props:{src:{type:String},maxWidth:{type:Number,default:320},rounded:{type:Boolean,default:!1},aspect:{type:String,default:"aspect-auto",validator:e=>["aspect-auto","aspect-square"].includes(e)}},setup(e){const{__:t}=(0,l.B)(),r=e,a=(0,o.ref)(!1),s=(0,o.ref)(!1),p=()=>a.value=!0,h=()=>{s.value=!0,Nova.log(`${t("The image could not be loaded.")}: ${r.src}`)},m=(0,o.computed)((()=>[r.rounded&&"rounded-full"])),f=(0,o.computed)((()=>n(n({"max-width":`${r.maxWidth}px`},"aspect-square"===r.aspect&&{width:`${r.maxWidth}px`}),"aspect-square"===r.aspect&&{height:`${r.maxWidth}px`})));return(r,l)=>{const a=(0,o.resolveDirective)("tooltip");return s.value?((0,o.openBlock)(),(0,o.createElementBlock)("a",{key:1,href:e.src},[(0,o.withDirectives)((0,o.createVNode)((0,o.unref)(i.Icon),{name:"exclamation-circle",class:"text-red-500"},null,512),[[a,(0,o.unref)(t)("The image could not be loaded.")]])],8,u)):((0,o.openBlock)(),(0,o.createElementBlock)("span",c,[(0,o.createElementVNode)("img",{class:(0,o.normalizeClass)(m.value),style:(0,o.normalizeStyle)(f.value),src:e.src,onLoad:p,onError:h},null,46,d)]))}}});const h=(0,r(66262).A)(p,[["__file","ImageLoader.vue"]])},73289:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726),i=r(65835);const l=["dusk"],a={class:"flex flex-col justify-center items-center px-6 space-y-3"},n={class:"text-base font-normal"},s={class:"hidden md:inline-block"},c={class:"inline-block md:hidden"},d={__name:"IndexEmptyDialog",props:["create-button-label","singularName","resourceName","viaResource","viaResourceId","viaRelationship","relationshipType","authorizedToCreate","authorizedToRelate"],setup(e){const{__:t}=(0,i.B)(),r=e,d=(0,o.computed)((()=>p.value||u.value)),u=(0,o.computed)((()=>("belongsToMany"===r.relationshipType||"morphToMany"===r.relationshipType)&&r.authorizedToRelate)),p=(0,o.computed)((()=>r.authorizedToCreate&&r.authorizedToRelate&&!r.alreadyFilled)),h=(0,o.computed)((()=>u.value?t("Attach :resource",{resource:r.singularName}):r.createButtonLabel)),m=(0,o.computed)((()=>u.value?Nova.url(`/resources/${r.viaResource}/${r.viaResourceId}/attach/${r.resourceName}`,{viaRelationship:r.viaRelationship,polymorphic:"morphToMany"===r.relationshipType?"1":"0"}):p.value?Nova.url(`/resources/${r.resourceName}/new`,{viaResource:r.viaResource,viaResourceId:r.viaResourceId,viaRelationship:r.viaRelationship,relationshipType:r.relationshipType}):void 0));return(r,i)=>{const p=(0,o.resolveComponent)("InertiaButton");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:"flex flex-col justify-center items-center px-6 py-8 space-y-6",dusk:`${e.resourceName}-empty-dialog`},[(0,o.createElementVNode)("div",a,[i[0]||(i[0]=(0,o.createElementVNode)("svg",{class:"inline-block text-gray-300 dark:text-gray-500",xmlns:"http://www.w3.org/2000/svg",width:"65",height:"51",viewBox:"0 0 65 51"},[(0,o.createElementVNode)("path",{class:"fill-current",d:"M56 40h2c.552285 0 1 .447715 1 1s-.447715 1-1 1h-2v2c0 .552285-.447715 1-1 1s-1-.447715-1-1v-2h-2c-.552285 0-1-.447715-1-1s.447715-1 1-1h2v-2c0-.552285.447715-1 1-1s1 .447715 1 1v2zm-5.364125-8H38v8h7.049375c.350333-3.528515 2.534789-6.517471 5.5865-8zm-5.5865 10H6c-3.313708 0-6-2.686292-6-6V6c0-3.313708 2.686292-6 6-6h44c3.313708 0 6 2.686292 6 6v25.049375C61.053323 31.5511 65 35.814652 65 41c0 5.522847-4.477153 10-10 10-5.185348 0-9.4489-3.946677-9.950625-9zM20 30h16v-8H20v8zm0 2v8h16v-8H20zm34-2v-8H38v8h16zM2 30h16v-8H2v8zm0 2v4c0 2.209139 1.790861 4 4 4h12v-8H2zm18-12h16v-8H20v8zm34 0v-8H38v8h16zM2 20h16v-8H2v8zm52-10V6c0-2.209139-1.790861-4-4-4H6C3.790861 2 2 3.790861 2 6v4h52zm1 39c4.418278 0 8-3.581722 8-8s-3.581722-8-8-8-8 3.581722-8 8 3.581722 8 8 8z"})],-1)),(0,o.createElementVNode)("h3",n,(0,o.toDisplayString)((0,o.unref)(t)("No :resource matched the given criteria.",{resource:e.singularName})),1)]),d.value?((0,o.openBlock)(),(0,o.createBlock)(p,{key:0,variant:"outline",href:m.value,class:"shrink-0",dusk:"create-button"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",s,(0,o.toDisplayString)(h.value),1),(0,o.createElementVNode)("span",c,(0,o.toDisplayString)(u.value?(0,o.unref)(t)("Attach"):(0,o.unref)(t)("Create")),1)])),_:1},8,["href"])):(0,o.createCommentVNode)("",!0)],8,l)}}};const u=(0,r(66262).A)(d,[["__file","IndexEmptyDialog.vue"]])},96735:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726),i=r(74640);const l={class:"text-base font-normal mt-3"},a={__name:"IndexErrorDialog",props:{resource:{type:Object,required:!0}},emits:["click"],setup:e=>(t,r)=>{const a=(0,o.resolveComponent)("Card");return(0,o.openBlock)(),(0,o.createBlock)(a,{class:"flex flex-col justify-center items-center px-6 py-8"},{default:(0,o.withCtx)((()=>[r[1]||(r[1]=(0,o.createElementVNode)("svg",{class:"inline-block text-gray-300 dark:text-gray-500",xmlns:"http://www.w3.org/2000/svg",width:"65",height:"51",viewBox:"0 0 65 51"},[(0,o.createElementVNode)("path",{class:"fill-current",d:"M56 40h2c.552285 0 1 .447715 1 1s-.447715 1-1 1h-2v2c0 .552285-.447715 1-1 1s-1-.447715-1-1v-2h-2c-.552285 0-1-.447715-1-1s.447715-1 1-1h2v-2c0-.552285.447715-1 1-1s1 .447715 1 1v2zm-5.364125-8H38v8h7.049375c.350333-3.528515 2.534789-6.517471 5.5865-8zm-5.5865 10H6c-3.313708 0-6-2.686292-6-6V6c0-3.313708 2.686292-6 6-6h44c3.313708 0 6 2.686292 6 6v25.049375C61.053323 31.5511 65 35.814652 65 41c0 5.522847-4.477153 10-10 10-5.185348 0-9.4489-3.946677-9.950625-9zM20 30h16v-8H20v8zm0 2v8h16v-8H20zm34-2v-8H38v8h16zM2 30h16v-8H2v8zm0 2v4c0 2.209139 1.790861 4 4 4h12v-8H2zm18-12h16v-8H20v8zm34 0v-8H38v8h16zM2 20h16v-8H2v8zm52-10V6c0-2.209139-1.790861-4-4-4H6C3.790861 2 2 3.790861 2 6v4h52zm1 39c4.418278 0 8-3.581722 8-8s-3.581722-8-8-8-8 3.581722-8 8 3.581722 8 8 8z"})],-1)),(0,o.createElementVNode)("h3",l,(0,o.toDisplayString)(t.__("Failed to load :resource!",{resource:t.__(`${e.resource.label}`)})),1),(0,o.createVNode)((0,o.unref)(i.Button),{class:"shrink-0 mt-6",onClick:r[0]||(r[0]=e=>t.$emit("click")),variant:"outline",label:t.__("Reload")},null,8,["label"])])),_:1})}};const n=(0,r(66262).A)(a,[["__file","IndexErrorDialog.vue"]])},87853:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"text-xs font-semibold text-gray-400 text-right space-x-1"},l={__name:"CharacterCounter",props:{count:{type:Number},limit:{type:Number}},setup(e){const t=e,r=(0,o.computed)((()=>t.count/t.limit)),l=(0,o.computed)((()=>r.value>.7&&r.value<=.9)),a=(0,o.computed)((()=>r.value>.9));return(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("p",i,[(0,o.createElementVNode)("span",{class:(0,o.normalizeClass)({"text-red-500":a.value,"text-yellow-500":l.value})},(0,o.toDisplayString)(e.count),3),r[0]||(r[0]=(0,o.createElementVNode)("span",null,"/",-1)),(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(e.limit),1)]))}};const a=(0,r(66262).A)(l,[["__file","CharacterCounter.vue"]])},36706:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>y});var o=r(29726),i=r(98234),l=r(38221),a=r.n(l),n=r(58156),s=r.n(n),c=r(96433);const d=["dusk"],u={class:"relative"},p=["onKeydown","disabled","placeholder","autocomplete","aria-expanded"],h=["dusk"],m=["dusk"],f={key:0,class:"px-3 py-2"},v=["dusk","onClick"],g=Object.assign({inheritAttrs:!1},{__name:"ComboBoxInput",props:(0,o.mergeModels)({autocomplete:{type:String,required:!1,default:null},dusk:{type:String},error:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},placeholder:{type:String,default:"Search"},options:{type:Array,default:[]},loading:{type:Boolean,default:!1},debounce:{type:Number,default:500},trackBy:{type:String}},{modelValue:{type:Array,default:[]},modelModifiers:{}}),emits:(0,o.mergeModels)(["clear","input","selected"],["update:modelValue"]),setup(e,{expose:t,emit:r}){const l=r,n=e,g=a()((e=>e()),n.debounce),y=(0,o.useModel)(e,"modelValue"),b=(0,o.ref)(null),k=(0,o.useTemplateRef)("searchInput"),w=(0,o.useTemplateRef)("searchResultsContainer"),C=(0,o.useTemplateRef)("searchResultsDropdown"),x=(0,o.useTemplateRef)("searchInputContainer"),N=(0,o.useTemplateRef)("selectedOption"),B=(0,o.ref)(""),S=(0,o.ref)(!1),V=(0,o.ref)(0);(0,c.MLh)(document,"keydown",(e=>{S.value&&[9,27].includes(e.keyCode)?setTimeout((()=>O()),50):e.composed&&[13,229].includes(e.keyCode)&&(B.value=e.target.value)})),(0,o.watch)(B,(e=>{e&&(S.value=!0),V.value=0,w.value?w.value.scrollTop=0:(0,o.nextTick)((()=>w.value.scrollTop=0)),g((()=>l("input",e)))})),(0,o.watch)(S,(e=>!0===e?(0,o.nextTick)((()=>{b.value=(0,i.n4)(k.value,C.value,{placement:"bottom-start",onFirstUpdate:()=>{x.value.scrollTop=x.value.scrollHeight,P()}})})):b.value.destroy()));const R=(0,o.computed)((()=>k.value?.offsetWidth));function E(e){return s()(e,n.trackBy)}function _(){S.value=!0}function O(){S.value=!1}function F(e){let t=V.value+e;t>=0&&t<n.options.length&&(V.value=t,(0,o.nextTick)((()=>P())))}function D(e){const t=y.value.filter((t=>t.value===e.value));l("selected",e),(0,o.nextTick)((()=>O())),B.value="",0===t.length&&y.value.push(e)}function A(e){if(e.isComposing||229===e.keyCode)return;var t;D((t=V.value,n.options[t]))}function P(){N.value&&(N.value.offsetTop>w.value.scrollTop+w.value.clientHeight-N.value.clientHeight&&(w.value.scrollTop=N.value.offsetTop+N.value.clientHeight-w.value.clientHeight),N.value.offsetTop<w.value.scrollTop&&(w.value.scrollTop=N.value.offsetTop))}return t({open:_,close:O,choose:D,remove:function(e){y.value.splice(e,1)},clear:function(){V.value=null,O(),l("clear"),y.value=[]},move:F}),(t,r)=>{const i=(0,o.resolveComponent)("Loader"),l=(0,o.resolveComponent)("Backdrop");return(0,o.openBlock)(),(0,o.createElementBlock)("div",(0,o.mergeProps)({ref:"searchInputContainer"},t.$attrs,{dusk:e.dusk}),[(0,o.createElementVNode)("div",u,[(0,o.withDirectives)((0,o.createElementVNode)("input",{onClick:(0,o.withModifiers)(_,["stop"]),onKeydown:[(0,o.withKeys)((0,o.withModifiers)(A,["prevent"]),["enter"]),r[0]||(r[0]=(0,o.withKeys)((0,o.withModifiers)((e=>F(1)),["prevent"]),["down"])),r[1]||(r[1]=(0,o.withKeys)((0,o.withModifiers)((e=>F(-1)),["prevent"]),["up"]))],class:(0,o.normalizeClass)(["w-full block form-control form-input form-control-bordered",{"form-control-bordered-error":e.error}]),"onUpdate:modelValue":r[2]||(r[2]=e=>B.value=e),disabled:e.disabled,ref:"searchInput",tabindex:"0",type:"search",placeholder:t.__(e.placeholder),autocomplete:e.autocomplete,spellcheck:"false","aria-expanded":!0===S.value?"true":"false"},null,42,p),[[o.vModelText,B.value]])]),((0,o.openBlock)(),(0,o.createBlock)(o.Teleport,{to:"body"},[S.value?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,ref:"searchResultsDropdown",style:{zIndex:2e3},dusk:`${e.dusk}-dropdown`},[(0,o.withDirectives)((0,o.createElementVNode)("div",{class:"rounded-lg px-0 bg-white dark:bg-gray-900 shadow border border-gray-200 dark:border-gray-700 my-1 overflow-hidden",style:(0,o.normalizeStyle)({width:R.value+"px",zIndex:2e3})},[(0,o.createElementVNode)("div",{ref:"searchResultsContainer",class:"relative overflow-y-scroll text-sm divide-y divide-gray-100 dark:divide-gray-800",tabindex:"-1",style:{"max-height":"155px"},dusk:`${e.dusk}-results`},[e.loading?((0,o.openBlock)(),(0,o.createElementBlock)("div",f,[(0,o.createVNode)(i,{width:"30"})])):((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,{key:1},(0,o.renderList)(e.options,((r,i)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{dusk:`${e.dusk}-result-${i}`,onClick:(0,o.withModifiers)((e=>D(r)),["stop"]),ref_for:!0,ref:e=>function(e,t){V.value===e&&(N.value=t)}(i,e),key:E(r),class:(0,o.normalizeClass)(["px-3 py-1.5 cursor-pointer",{[`search-input-item-${i}`]:!0,"hover:bg-gray-100 dark:hover:bg-gray-800":i!==V.value,"bg-primary-500 text-white dark:text-gray-900":i===V.value}])},[(0,o.renderSlot)(t.$slots,"option",{option:r,selected:i===V.value,dusk:`${e.dusk}-result-${i}`})],10,v)))),128))],8,m)],4),[[o.vShow,e.loading||e.options.length>0]])],8,h)):(0,o.createCommentVNode)("",!0),(0,o.createVNode)(l,{onClick:O,show:S.value,class:"z-[35]"},null,8,["show"])]))],16,d)}}});const y=(0,r(66262).A)(g,[["__file","ComboBoxInput.vue"]])},26762:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726),i=r(74640),l=r(65835);const a={class:"relative h-9 w-full md:w-1/3 md:shrink-0"},n={__name:"IndexSearchInput",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(e){const{__:t}=(0,l.B)(),r=(0,o.useModel)(e,"modelValue");return(e,l)=>{const n=(0,o.resolveComponent)("RoundInput");return(0,o.openBlock)(),(0,o.createElementBlock)("div",a,[(0,o.createVNode)((0,o.unref)(i.Icon),{name:"magnifying-glass",type:"mini",class:"absolute ml-2 text-gray-400 top-[4px]"}),(0,o.createVNode)(n,{dusk:"search-input",class:"bg-white dark:bg-gray-800 shadow dark:focus:bg-gray-800",placeholder:(0,o.unref)(t)("Search"),type:"search",modelValue:r.value,"onUpdate:modelValue":l[0]||(l[0]=e=>r.value=e),spellcheck:"false","aria-label":(0,o.unref)(t)("Search"),"data-role":"resource-search-input"},null,8,["placeholder","modelValue","aria-label"])])}}};const s=(0,r(66262).A)(n,[["__file","IndexSearchInput.vue"]])},40902:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function l(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const a=Object.assign({inheritAttrs:!1},{__name:"RoundInput",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(e){const t=(0,o.useModel)(e,"modelValue");return(e,r)=>(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createElementBlock)("input",(0,o.mergeProps)(function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach((function(t){l(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({},e.$attrs),{"onUpdate:modelValue":r[0]||(r[0]=e=>t.value=e),class:"appearance-none rounded-full h-8 pl-10 w-full focus:bg-white focus:outline-none focus:ring ring-primary-200 dark:ring-gray-600"}),null,16)),[[o.vModelDynamic,t.value]])}});const n=(0,r(66262).A)(a,[["__file","RoundInput.vue"]])},21760:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>B});var o=r(29726),i=r(98234),l=r(38221),a=r.n(l),n=r(58156),s=r.n(n),c=r(24713),d=r.n(c),u=r(35229),p=r(96433);function h(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function m(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const f=["dusk"],v=["onKeydown","tabindex","aria-expanded","dusk"],g={key:0,class:"pointer-events-none absolute inset-y-0 right-[11px] flex items-center"},y={class:"text-gray-400 dark:text-gray-400"},b=["dusk"],k=["dusk"],w=["disabled","onKeydown","autocomplete","placeholder"],C=["dusk"],x=["dusk","onClick"],N=Object.assign({inheritAttrs:!1},{__name:"SearchInput",props:(0,o.mergeModels)(function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?h(Object(r),!0).forEach((function(t){m(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):h(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({autocomplete:{type:String,required:!1,default:null},dusk:{type:String,required:!0},disabled:{type:Boolean,default:!1},readOnly:{type:Boolean,default:!1},options:{},trackBy:{type:String,required:!0},error:{type:Boolean,default:!1},boundary:{},debounce:{type:Number,default:500},clearable:{type:Boolean,default:!0}},(0,u.rr)(["mode"])),{modelValue:{},modelModifiers:{}}),emits:(0,o.mergeModels)(["clear","input","shown","closed","selected"],["update:modelValue"]),setup(e,{expose:t,emit:r}){const l=r,n=e,c=(0,o.useModel)(e,"modelValue"),u=a()((e=>e()),n.debounce),h=(0,o.ref)(!1),m=(0,o.ref)(""),N=(0,o.ref)(0),B=(0,o.ref)(null),S=(0,o.ref)(null),V=(0,o.useTemplateRef)("container"),R=(0,o.useTemplateRef)("dropdown"),E=(0,o.useTemplateRef)("input"),_=(0,o.useTemplateRef)("search"),O=(0,o.useTemplateRef)("selected");function F(e){return s()(e,n.trackBy)}function D(){n.disabled||n.readOnly||(h.value=!0,m.value="",l("shown"))}function A(){h.value=!1,l("closed")}function P(){n.disabled||(N.value=null,l("clear",null))}function T(e){let t=N.value+e;t>=0&&t<n.options.length&&(N.value=t,I())}function I(){(0,o.nextTick)((()=>{O.value&&O.value[0]&&(O.value[0].offsetTop>V.value.scrollTop+V.value.clientHeight-O.value[0].clientHeight&&(V.value.scrollTop=O.value[0].offsetTop+O.value[0].clientHeight-V.value.clientHeight),O.value[0].offsetTop<V.value.scrollTop&&(V.value.scrollTop=O.value[0].offsetTop))}))}function M(e){if(!e.isComposing&&229!==e.keyCode&&void 0!==n.options[N.value]){let e=n.options[N.value];c.value=F(e),l("selected",e),E.value.focus(),(0,o.nextTick)((()=>A()))}}(0,o.watch)(m,(e=>{N.value=0,V.value?V.value.scrollTop=0:(0,o.nextTick)((()=>{V.value.scrollTop=0})),u((()=>{l("input",e)}))})),(0,o.watch)(h,(e=>{if(e){let e=d()(n.options,[n.trackBy,s()(c.value,n.trackBy)]);-1!==e&&(N.value=e),S.value=E.value.offsetWidth,Nova.$emit("disable-focus-trap"),(0,o.nextTick)((()=>{B.value=(0,i.n4)(E.value,R.value,{placement:"bottom-start",onFirstUpdate:e=>{V.value.scrollTop=V.value.scrollHeight,I(),_.value.focus()}})}))}else B.value&&B.value.destroy(),Nova.$emit("enable-focus-trap"),E.value.focus()})),(0,p.MLh)(document,"keydown",(e=>{h.value&&[9,27].includes(e.keyCode)?setTimeout((()=>A()),50):e.composed&&[13,229].includes(e.keyCode)&&(m.value=e.target.value)}));const j=(0,o.computed)((()=>""==c.value||null==c.value||!n.clearable));return t({open:D,close:A,clear:P,move:T}),(t,r)=>{const i=(0,o.resolveComponent)("IconArrow"),a=(0,o.resolveComponent)("Backdrop");return(0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,null,[(0,o.createElementVNode)("div",(0,o.mergeProps)(t.$attrs,{class:"relative",dusk:e.dusk,ref:"searchInputContainer"}),[(0,o.createElementVNode)("div",{ref:"input",onClick:(0,o.withModifiers)(D,["stop"]),onKeydown:[(0,o.withKeys)((0,o.withModifiers)(D,["prevent"]),["space"]),(0,o.withKeys)((0,o.withModifiers)(D,["prevent"]),["down"]),(0,o.withKeys)((0,o.withModifiers)(D,["prevent"]),["up"])],class:(0,o.normalizeClass)([{"ring dark:border-gray-500 dark:ring-gray-700":h.value,"form-input-border-error":e.error,"bg-gray-50 dark:bg-gray-700":e.disabled||e.readOnly},"relative flex items-center form-control form-input form-control-bordered form-select pr-6"]),tabindex:h.value?-1:0,"aria-expanded":!0===h.value?"true":"false",dusk:`${e.dusk}-selected`},[j.value&&!e.disabled?((0,o.openBlock)(),(0,o.createElementBlock)("span",g,[(0,o.createVNode)(i)])):(0,o.createCommentVNode)("",!0),(0,o.renderSlot)(t.$slots,"default",{},(()=>[(0,o.createElementVNode)("div",y,(0,o.toDisplayString)(t.__("Click to choose")),1)]))],42,v),j.value||e.disabled?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:0,type:"button",onClick:P,tabindex:"-1",class:"absolute p-2 inline-block right-[4px]",style:{top:"6px"},dusk:`${e.dusk}-clear-button`},r[3]||(r[3]=[(0,o.createElementVNode)("svg",{class:"block fill-current icon h-2 w-2",xmlns:"http://www.w3.org/2000/svg",viewBox:"278.046 126.846 235.908 235.908"},[(0,o.createElementVNode)("path",{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"})],-1)]),8,b))],16,f),((0,o.openBlock)(),(0,o.createBlock)(o.Teleport,{to:"body"},[h.value?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,ref:"dropdown",class:"rounded-lg px-0 bg-white dark:bg-gray-900 shadow border border-gray-200 dark:border-gray-700 absolute top-0 left-0 my-1 overflow-hidden",style:(0,o.normalizeStyle)({width:S.value+"px",zIndex:2e3}),dusk:`${e.dusk}-dropdown`},[(0,o.withDirectives)((0,o.createElementVNode)("input",{disabled:e.disabled||e.readOnly,"onUpdate:modelValue":r[0]||(r[0]=e=>m.value=e),ref:"search",onKeydown:[(0,o.withKeys)((0,o.withModifiers)(M,["prevent"]),["enter"]),r[1]||(r[1]=(0,o.withKeys)((0,o.withModifiers)((e=>T(1)),["prevent"]),["down"])),r[2]||(r[2]=(0,o.withKeys)((0,o.withModifiers)((e=>T(-1)),["prevent"]),["up"]))],class:"h-10 outline-none w-full px-3 text-sm leading-normal bg-white dark:bg-gray-700 rounded-t border-b border-gray-200 dark:border-gray-800",tabindex:"-1",type:"search",autocomplete:e.autocomplete,spellcheck:"false",placeholder:t.__("Search")},null,40,w),[[o.vModelText,m.value]]),(0,o.createElementVNode)("div",{ref:"container",class:"relative overflow-y-scroll text-sm",tabindex:"-1",style:{"max-height":"155px"},dusk:`${e.dusk}-results`},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.options,((r,i)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{dusk:`${e.dusk}-result-${i}`,key:F(r),ref_for:!0,ref:i===N.value?"selected":"unselected",onClick:(0,o.withModifiers)((e=>function(e){N.value=d()(n.options,[n.trackBy,s()(e,n.trackBy)]),c.value=F(e),l("selected",e),E.value.blur(),(0,o.nextTick)((()=>A()))}(r)),["stop"]),class:(0,o.normalizeClass)(["px-3 py-1.5 cursor-pointer z-[50]",{"border-t border-gray-100 dark:border-gray-700":0!==i,[`search-input-item-${i}`]:!0,"hover:bg-gray-100 dark:hover:bg-gray-800":i!==N.value,"bg-primary-500 text-white dark:text-gray-900":i===N.value}])},[(0,o.renderSlot)(t.$slots,"option",{option:r,selected:i===N.value})],10,x)))),128))],8,C)],12,k)):(0,o.createCommentVNode)("",!0),(0,o.createVNode)(a,{onClick:A,show:h.value,style:{zIndex:1999}},null,8,["show"])]))],64)}}});const B=(0,r(66262).A)(N,[["__file","SearchInput.vue"]])},76402:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726);const i={class:"flex items-center"},l={key:0,class:"flex-none mr-3"},a=["src"],n={class:"flex-auto"},s={key:0},c={key:1},d={__name:"SearchInputResult",props:{option:{type:Object,required:!0},selected:{type:Boolean,default:!1},withSubtitles:{type:Boolean,default:!0}},setup:e=>(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[e.option.avatar?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[(0,o.createElementVNode)("img",{src:e.option.avatar,class:"w-8 h-8 rounded-full block"},null,8,a)])):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",n,[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["text-sm font-semibold leading-normal",{"text-white dark:text-gray-900":e.selected}])},(0,o.toDisplayString)(e.option.display),3),e.withSubtitles?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,class:(0,o.normalizeClass)(["text-xs font-semibold leading-normal text-gray-500",{"text-white dark:text-gray-700":e.selected}])},[e.option.subtitle?((0,o.openBlock)(),(0,o.createElementBlock)("span",s,(0,o.toDisplayString)(e.option.subtitle),1)):((0,o.openBlock)(),(0,o.createElementBlock)("span",c,(0,o.toDisplayString)(t.__("No additional information...")),1))],2)):(0,o.createCommentVNode)("",!0)])]))};const u=(0,r(66262).A)(d,[["__file","SearchInputResult.vue"]])},24511:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726),i=r(74640);const l={class:"py-1"},a={__name:"LensSelector",props:["resourceName","lenses"],setup:e=>(t,r)=>{const a=(0,o.resolveComponent)("DropdownMenuItem"),n=(0,o.resolveComponent)("ScrollWrap"),s=(0,o.resolveComponent)("DropdownMenu"),c=(0,o.resolveComponent)("Dropdown");return(0,o.openBlock)(),(0,o.createBlock)(c,{placement:"bottom-end"},{menu:(0,o.withCtx)((()=>[(0,o.createVNode)(s,{class:"divide-y divide-gray-100 dark:divide-gray-800 divide-solid px-1",width:"auto"},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(n,{height:250},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",l,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.lenses,(r=>((0,o.openBlock)(),(0,o.createBlock)(a,{key:r.uriKey,href:t.$url(`/resources/${e.resourceName}/lens/${r.uriKey}`),as:"link",class:"px-3 py-2 hover:bg-gray-50 dark:hover:bg-gray-800"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.name),1)])),_:2},1032,["href"])))),128))])])),_:1})])),_:1})])),default:(0,o.withCtx)((()=>[(0,o.createVNode)((0,o.unref)(i.Button),{variant:"ghost",padding:"tight",icon:"queue-list","trailing-icon":"chevron-down","aria-label":t.__("Lens Dropdown")},null,8,["aria-label"])])),_:1})}};const n=(0,r(66262).A)(a,[["__file","LensSelector.vue"]])},99820:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726),i=r(66278);const l={key:0,href:"https://nova.laravel.com/licenses",class:"inline-block text-red-500 text-xs font-bold mt-1 text-center uppercase"},a={__name:"LicenseWarning",setup(e){const t=(0,i.Pj)(),r=(0,o.computed)((()=>t.getters.validLicense));return(e,t)=>r.value?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createElementBlock)("a",l,(0,o.toDisplayString)(e.__("Unregistered")),1))}};const n=(0,r(66262).A)(a,[["__file","LicenseWarning.vue"]])},89204:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"absolute inset-0 z-30 flex items-center justify-center rounded-lg bg-white dark:bg-gray-800"},l={__name:"LoadingCard",props:{loading:{type:Boolean,default:!0}},setup:e=>(t,r)=>{const l=(0,o.resolveComponent)("Loader"),a=(0,o.resolveComponent)("Card");return(0,o.openBlock)(),(0,o.createBlock)(a,{class:"isolate"},{default:(0,o.withCtx)((()=>[(0,o.withDirectives)((0,o.createElementVNode)("div",i,[(0,o.createVNode)(l,{class:"text-gray-300",width:"30"})],512),[[o.vShow,e.loading]]),(0,o.renderSlot)(t.$slots,"default")])),_:3})}};const a=(0,r(66262).A)(l,[["__file","LoadingCard.vue"]])},5983:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={key:0,dusk:"loading-view",class:"absolute inset-0 z-20 bg-white/75 dark:bg-gray-800/75 flex items-center justify-center p-6"},l={__name:"LoadingView",props:{loading:{type:Boolean,default:!0},variant:{type:String,validator:e=>["default","overlay"].includes(e),default:"default"}},setup:e=>(t,r)=>{const l=(0,o.resolveComponent)("Loader");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(["relative",{"overflow-hidden":e.loading}])},["default"===e.variant?((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:0},[e.loading?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,dusk:"loading-view",class:(0,o.normalizeClass)({"flex items-center justify-center z-30 p-6":"default"===e.variant,"absolute inset-0 z-30 bg-white/75 flex items-center justify-center p-6":"overlay"===e.variant}),style:{"min-height":"220px"}},[(0,o.createVNode)(l,{class:"text-gray-300"})],2)):(0,o.renderSlot)(t.$slots,"default",{key:1})],64)):(0,o.createCommentVNode)("",!0),"overlay"===e.variant?((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:1},[e.loading?((0,o.openBlock)(),(0,o.createElementBlock)("div",i)):(0,o.createCommentVNode)("",!0),(0,o.renderSlot)(t.$slots,"default")],64)):(0,o.createCommentVNode)("",!0)],2)}};const a=(0,r(66262).A)(l,[["__file","LoadingView.vue"]])},1085:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>B});var o=r(29726),i=r(10646),l=r(65835),a=r(15237),n=r.n(a),s=r(38221),c=r.n(s);function d(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function u(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?d(Object(r),!0).forEach((function(t){p(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):d(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function p(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const{__:h}=(0,l.B)(),m=(e,{props:t,emitter:r,isFocused:i,filesUploadingCount:l,filesUploadedCount:a,files:n})=>{const s=e.getDoc();return{setValue(e){s.setValue(e),this.refresh()},focus(){i.value=!0},refresh(){(0,o.nextTick)((()=>e.refresh()))},insert(e){let t=s.getCursor();s.replaceRange(e,{line:t.line,ch:t.ch})},insertAround(e,t){if(s.somethingSelected()){const r=s.getSelection();s.replaceSelection(e+r+t)}else{let r=s.getCursor();s.replaceRange(e+t,{line:r.line,ch:r.ch}),s.setCursor({line:r.line,ch:r.ch+e.length})}},insertBefore(e,t){if(s.somethingSelected()){s.listSelections().forEach((r=>{const o=[r.head.line,r.anchor.line].sort();for(let t=o[0];t<=o[1];t++)s.replaceRange(e,{line:t,ch:0});s.setCursor({line:o[0],ch:t||0})}))}else{let r=s.getCursor();s.replaceRange(e,{line:r.line,ch:0}),s.setCursor({line:r.line,ch:t||0})}},uploadAttachment(e){if(null!=t.uploader){l.value=l.value+1;const o=`![Uploading ${e.name}…]()`;this.insert(o),t.uploader(e,{onCompleted:(e,t)=>{let i=s.getValue();i=i.replace(o,`![${e}](${t})`),s.setValue(i),r("change",i),a.value=a.value+1},onFailure:e=>{l.value=l.value-1}})}}}},f=(e,t,{props:r,emitter:i,isFocused:l,files:a,filesUploadingCount:n,filesUploadedCount:s})=>{const d=e.getDoc(),u=/!\[[^\]]*\]\(([^\)]+)\)/gm;e.on("focus",(()=>l.value=!0)),e.on("blur",(()=>l.value=!1)),d.on("change",((e,t)=>{"setValue"!==t.origin&&i("change",e.getValue())})),d.on("change",c()(((e,t)=>{const r=[...e.getValue().matchAll(u)].map((e=>e[1])).filter((e=>{try{return new URL(e),!0}catch{return!1}}));a.value.filter((e=>!r.includes(e))).filter(((e,t,r)=>r.indexOf(e)===t)).forEach((e=>i("file-removed",e))),r.filter((e=>!a.value.includes(e))).filter(((e,t,r)=>r.indexOf(e)===t)).forEach((e=>i("file-added",e))),a.value=r}),1e3)),e.on("paste",((e,r)=>{(e=>{if(e.clipboardData&&e.clipboardData.items){const r=e.clipboardData.items;for(let o=0;o<r.length;o++)-1!==r[o].type.indexOf("image")&&(t.uploadAttachment(r[o].getAsFile()),e.preventDefault())}})(r)})),(0,o.watch)(l,((t,r)=>{!0===t&&!1===r&&e.focus()}))},v=(e,{emitter:t,props:r,isEditable:o,isFocused:i,isFullScreen:l,filesUploadingCount:a,filesUploadedCount:s,files:c,unmountMarkdownEditor:d})=>{const p=n().fromTextArea(e.value,{tabSize:4,indentWithTabs:!0,lineWrapping:!0,mode:"markdown",viewportMargin:1/0,extraKeys:{Enter:"newlineAndIndentContinueMarkdownList"},readOnly:r.readonly,autoRefresh:!0}),h=(p.getDoc(),m(p,{props:r,emitter:t,isFocused:i,filesUploadingCount:a,filesUploadedCount:s,files:c})),v=((e,{isEditable:t,isFullScreen:r})=>({bold(){t&&e.insertAround("**","**")},italicize(){t&&e.insertAround("*","*")},image(){t&&e.insertBefore("![](url)",2)},link(){t&&e.insertAround("[","](url)")},toggleFullScreen(){r.value=!r.value,e.refresh()},fullScreen(){r.value=!0,e.refresh()},exitFullScreen(){r.value=!1,e.refresh()}}))(h,{isEditable:o,isFullScreen:l});return((e,t)=>{const r={"Cmd-B":"bold","Cmd-I":"italicize","Cmd-Alt-I":"image","Cmd-K":"link",F11:"fullScreen",Esc:"exitFullScreen"};Object.entries(r).forEach((([o,i])=>{const l=o.replace("Cmd-",n().keyMap.default==n().keyMap.macDefault?"Cmd-":"Ctrl-");e.options.extraKeys[l]=t[r[o]].bind(void 0)}))})(p,v),f(p,h,{props:r,emitter:t,isFocused:i,files:c,filesUploadingCount:a,filesUploadedCount:s}),h.refresh(),{editor:p,unmount:()=>{p.toTextArea(),d()},actions:u(u(u({},h),v),{},{handle(e,t){r.readonly||(i.value=!0,v[t].call(e))}})}};function g(e,t){const r=(0,o.ref)(!1),i=(0,o.ref)(!1),l=(0,o.ref)(""),a=(0,o.ref)("write"),n=(0,o.ref)(h("Attach files by dragging & dropping, selecting or pasting them.")),s=(0,o.ref)([]),c=(0,o.ref)(0),d=(0,o.ref)(0),u=(0,o.computed)((()=>t.readonly&&"write"==a.value)),p=()=>{r.value=!1,i.value=!1,a.value="write",l.value="",c.value=0,d.value=0,s.value=[]};return null!=t.uploader&&(0,o.watch)([d,c],(([e,t])=>{n.value=t>e?h("Uploading files... (:current/:total)",{current:e,total:t}):h("Attach files by dragging & dropping, selecting or pasting them.")})),{createMarkdownEditor:(o,l)=>v.call(o,l,{emitter:e,props:t,isEditable:u,isFocused:i,isFullScreen:r,filesUploadingCount:c,filesUploadedCount:d,files:s,unmountMarkdownEditor:p}),isFullScreen:r,isFocused:i,isEditable:u,visualMode:a,previewContent:l,statusContent:n,files:s}}const y=["dusk"],b={class:"w-full flex items-center content-center"},k=["dusk"],w={class:"p-4"},C=["dusk"],x=["dusk","innerHTML"],N={__name:"MarkdownEditor",props:{attribute:{type:String,required:!0},readonly:{type:Boolean,default:!1},previewer:{type:[Object,Function],required:!1,default:null},uploader:{type:[Object,Function],required:!1,default:null}},emits:["initialize","change","fileRemoved","fileAdded"],setup(e,{expose:t,emit:r}){const{__:a}=(0,l.B)(),n=r,s=e,{createMarkdownEditor:c,isFullScreen:d,isFocused:u,isEditable:p,visualMode:h,previewContent:m,statusContent:f}=g(n,s);let v=null;const N=(0,o.useTemplateRef)("theTextarea"),B=(0,o.useTemplateRef)("fileInput"),S=()=>B.value.click(),V=()=>{if(s.uploader&&v.actions){const e=B.value.files;for(let t=0;t<e.length;t++)v.actions.uploadAttachment(e[t]);B.value.files=null}},{startedDrag:R,handleOnDragEnter:E,handleOnDragLeave:_}=(0,i.g)(n),O=e=>{if(s.uploader&&v.actions){const t=e.dataTransfer.files;for(let e=0;e<t.length;e++)-1!==t[e].type.indexOf("image")&&v.actions.uploadAttachment(t[e])}};(0,o.onMounted)((()=>{v=c(this,N),n("initialize")})),(0,o.onBeforeUnmount)((()=>v.unmount()));const F=()=>{h.value="write",v.actions.refresh()},D=async()=>{m.value=await s.previewer(v.editor.getValue()??""),h.value="preview"},A=e=>{v.actions.handle(this,e)};return t({setValue(e){v?.actions&&v.actions.setValue(e)},setOption(e,t){v?.editor&&v.editor.setOption(e,t)}}),(t,r)=>{const i=(0,o.resolveComponent)("MarkdownEditorToolbar");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{dusk:e.attribute,class:(0,o.normalizeClass)(["bg-white dark:bg-gray-900 rounded-lg",{"markdown-fullscreen fixed inset-0 z-50 overflow-x-hidden overflow-y-auto":(0,o.unref)(d),"form-input form-control-bordered px-0 overflow-hidden":!(0,o.unref)(d),"outline-none ring ring-primary-100 dark:ring-gray-700":(0,o.unref)(u)}]),onDragenter:r[1]||(r[1]=(0,o.withModifiers)(((...e)=>(0,o.unref)(E)&&(0,o.unref)(E)(...e)),["prevent"])),onDragleave:r[2]||(r[2]=(0,o.withModifiers)(((...e)=>(0,o.unref)(_)&&(0,o.unref)(_)(...e)),["prevent"])),onDragover:r[3]||(r[3]=(0,o.withModifiers)((()=>{}),["prevent"])),onDrop:(0,o.withModifiers)(O,["prevent"])},[(0,o.createElementVNode)("header",{class:(0,o.normalizeClass)(["bg-white dark:bg-gray-900 flex items-center content-center justify-between border-b border-gray-200 dark:border-gray-700",{"fixed top-0 w-full z-10":(0,o.unref)(d),"bg-gray-100":e.readonly}])},[(0,o.createElementVNode)("div",b,[(0,o.createElementVNode)("button",{type:"button",class:(0,o.normalizeClass)([{"text-primary-500 font-bold":"write"===(0,o.unref)(h)},"ml-1 px-3 h-10 focus:outline-none focus:ring ring-primary-200 dark:ring-gray-600"]),onClick:(0,o.withModifiers)(F,["stop"])},(0,o.toDisplayString)((0,o.unref)(a)("Write")),3),e.previewer?((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:0,type:"button",class:(0,o.normalizeClass)([{"text-primary-500 font-bold":"preview"===(0,o.unref)(h)},"px-3 h-10 focus:outline-none focus:ring ring-primary-200 dark:ring-gray-600"]),onClick:(0,o.withModifiers)(D,["stop"])},(0,o.toDisplayString)((0,o.unref)(a)("Preview")),3)):(0,o.createCommentVNode)("",!0)]),e.readonly?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createBlock)(i,{key:0,onAction:A,dusk:"markdown-toolbar"}))],2),(0,o.withDirectives)((0,o.createElementVNode)("div",{onClick:r[0]||(r[0]=e=>u.value=!0),class:(0,o.normalizeClass)(["dark:bg-gray-900",{"mt-6":(0,o.unref)(d),"readonly bg-gray-100":e.readonly}]),dusk:(0,o.unref)(d)?"markdown-fullscreen-editor":"markdown-editor"},[(0,o.createElementVNode)("div",w,[(0,o.createElementVNode)("textarea",{ref:"theTextarea",class:(0,o.normalizeClass)({"bg-gray-100":e.readonly})},null,2)]),e.uploader?((0,o.openBlock)(),(0,o.createElementBlock)("label",{key:0,onChange:(0,o.withModifiers)(S,["prevent"]),class:(0,o.normalizeClass)(["cursor-pointer block bg-gray-100 dark:bg-gray-700 text-gray-400 text-xxs px-2 py-1",{hidden:(0,o.unref)(d)}]),dusk:`${e.attribute}-file-picker`},[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)((0,o.unref)(f)),1),(0,o.createElementVNode)("input",{ref:"fileInput",type:"file",class:"hidden",accept:"image/*",multiple:!0,onChange:(0,o.withModifiers)(V,["prevent"])},null,544)],42,C)):(0,o.createCommentVNode)("",!0)],10,k),[[o.vShow,"write"==(0,o.unref)(h)]]),(0,o.withDirectives)((0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["prose prose-sm dark:prose-invert overflow-auto max-w-none p-4",{"mt-6":(0,o.unref)(d)}]),dusk:(0,o.unref)(d)?"markdown-fullscreen-previewer":"markdown-previewer",innerHTML:(0,o.unref)(m)},null,10,x),[[o.vShow,"preview"==(0,o.unref)(h)]])],42,y)}}};const B=(0,r(66262).A)(N,[["__file","MarkdownEditor.vue"]])},24143:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i={class:"flex items-center"},l=["onClick"],a={__name:"MarkdownEditorToolbar",emits:["action"],setup(e,{emit:t}){const r=t,a=(0,o.computed)((()=>[{name:"bold",action:"bold",icon:"icon-bold"},{name:"italicize",action:"italicize",icon:"icon-italic"},{name:"link",action:"link",icon:"icon-link"},{name:"image",action:"image",icon:"icon-image"},{name:"fullScreen",action:"toggleFullScreen",icon:"icon-full-screen"}]));return(e,t)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(a.value,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:e.action,onClick:(0,o.withModifiers)((t=>{return o=e.action,void r("action",o);var o}),["prevent"]),type:"button",class:"rounded-none w-10 h-10 fill-gray-500 dark:fill-gray-400 hover:fill-gray-700 dark:hover:fill-gray-600 active:fill-gray-800 inline-flex items-center justify-center px-2 text-sm border-l border-gray-200 dark:border-gray-700 focus:outline-none focus:ring ring-primary-200 dark:ring-gray-600"},[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(e.icon),{dusk:e.action,class:"w-4 h-4"},null,8,["dusk"]))],8,l)))),128))]))}};const n=(0,r(66262).A)(a,[["__file","MarkdownEditorToolbar.vue"]])},25787:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>d});var o=r(29726),i=r(74640),l=r(66278);const a={key:0,class:"text-gray-500 font-semibold","aria-label":"breadcrumb",dusk:"breadcrumbs"},n={class:"flex items-center"},s={key:1},c={__name:"Breadcrumbs",setup(e){const t=(0,l.Pj)(),r=(0,o.computed)((()=>t.getters.breadcrumbs)),c=(0,o.computed)((()=>r.value.length>0));return(e,t)=>{const l=(0,o.resolveComponent)("Link");return c.value?((0,o.openBlock)(),(0,o.createElementBlock)("nav",a,[(0,o.createElementVNode)("ol",null,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.value,((t,a)=>((0,o.openBlock)(),(0,o.createElementBlock)("li",(0,o.mergeProps)({key:a,ref_for:!0},{"aria-current":a===r.value.length-1?"page":null},{class:"inline-block"}),[(0,o.createElementVNode)("div",n,[null!==t.path&&a<r.value.length-1?((0,o.openBlock)(),(0,o.createBlock)(l,{key:0,href:e.$url(t.path),class:"link-default"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(t.name),1)])),_:2},1032,["href"])):((0,o.openBlock)(),(0,o.createElementBlock)("span",s,(0,o.toDisplayString)(t.name),1)),a<r.value.length-1?((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(i.Icon),{key:2,name:"chevron-right",type:"micro",class:"mx-2 text-gray-300 dark:text-gray-700"})):(0,o.createCommentVNode)("",!0)])],16)))),128))])])):(0,o.createCommentVNode)("",!0)}}};const d=(0,r(66262).A)(c,[["__file","Breadcrumbs.vue"]])},43134:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726),i=r(66278);const l={key:0,class:"sidebar-menu space-y-6",dusk:"sidebar-menu",role:"navigation"},a=Object.assign({name:"MainMenu"},{__name:"MainMenu",setup(e){const t=(0,i.Pj)(),r=(0,o.computed)((()=>t.getters.mainMenu)),a=(0,o.computed)((()=>r.value.length>0));return(e,t)=>a.value?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.value,((e,t)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(e.component),{key:e.key,item:e},null,8,["item"])))),128))])):(0,o.createCommentVNode)("",!0)}});const n=(0,r(66262).A)(a,[["__file","MainMenu.vue"]])},16839:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={key:0},l={class:"flex-1 flex items-center w-full tracking-wide uppercase font-bold text-left text-xs px-3 py-1"},a={key:0,class:"inline-flex items-center justify-center shrink-0 w-6 h-6"},n={key:0};const s={mixins:[r(35229).pJ],props:["item"],methods:{handleClick(){this.item.collapsable&&this.toggleCollapse()}},computed:{component(){return this.item.items.length>0?"div":"h3"},displayAsButton(){return this.item.items.length>0&&this.item.collapsable},collapsedByDefault(){return this.item?.collapsedByDefault??!1}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,s,c,d){const u=(0,o.resolveComponent)("CollapseButton");return r.item.items.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("h4",{onClick:t[0]||(t[0]=(0,o.withModifiers)(((...e)=>d.handleClick&&d.handleClick(...e)),["prevent"])),class:(0,o.normalizeClass)(["flex items-center px-1 py-1 rounded text-left text-gray-500",{"cursor-pointer hover:bg-gray-200 dark:hover:bg-gray-800":d.displayAsButton,"font-bold text-primary-500 dark:text-primary-500":r.item.active}])},[t[1]||(t[1]=(0,o.createElementVNode)("span",{class:"inline-block shrink-0 w-6 h-6"},null,-1)),(0,o.createElementVNode)("span",l,(0,o.toDisplayString)(r.item.name),1),r.item.collapsable?((0,o.openBlock)(),(0,o.createElementBlock)("span",a,[(0,o.createVNode)(u,{collapsed:e.collapsed,to:r.item.path},null,8,["collapsed","to"])])):(0,o.createCommentVNode)("",!0)],2),e.collapsed?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createElementBlock)("div",n,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.item.items,(e=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(e.component),{key:e.name,item:e},null,8,["item"])))),128))]))])):(0,o.createCommentVNode)("",!0)}],["__file","MenuGroup.vue"]])},12899:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>g});var o=r(29726);const i={class:"flex-1 flex items-center w-full px-3 text-sm"},l={class:"inline-block h-6 shrink-0"};var a=r(83488),n=r.n(a),s=r(42194),c=r.n(s),d=r(71086),u=r.n(d),p=r(66278);function h(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function m(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?h(Object(r),!0).forEach((function(t){f(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):h(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function f(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const v={props:{item:{type:Object,required:!0}},methods:m(m({},(0,p.PY)(["toggleMainMenu"])),{},{handleClick(){this.mainMenuShown&&this.toggleMainMenu()}}),computed:m(m({},(0,p.L8)(["mainMenuShown"])),{},{requestMethod(){return this.item.method||"GET"},component(){return"GET"!==this.requestMethod?"FormButton":!0!==this.item.external?"Link":"a"},linkAttributes(){let e=this.requestMethod;return u()(c()({href:this.item.path,method:"GET"!==e?e:null,headers:this.item.headers||null,data:this.item.data||null,rel:"a"===this.component?"noreferrer noopener":null,target:this.item.target||null},(e=>null===e)),n())}})};const g=(0,r(66262).A)(v,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Badge");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(s.component),(0,o.mergeProps)(s.linkAttributes,{class:["w-full flex min-h-8 px-1 py-1 rounded text-left text-gray-500 dark:text-gray-500 focus:outline-none focus:ring focus:ring-primary-200 dark:focus:ring-gray-600 cursor-pointer hover:bg-gray-200 dark:hover:bg-gray-800",{"font-bold text-primary-500 dark:text-primary-500":r.item.active}],"data-active-link":r.item.active,onClick:s.handleClick}),{default:(0,o.withCtx)((()=>[t[0]||(t[0]=(0,o.createElementVNode)("span",{class:"inline-block shrink-0 w-6 h-6"},null,-1)),(0,o.createElementVNode)("span",i,(0,o.toDisplayString)(r.item.name),1),(0,o.createElementVNode)("span",l,[r.item.badge?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,"extra-classes":r.item.badge.typeClass},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.item.badge.value),1)])),_:1},8,["extra-classes"])):(0,o.createCommentVNode)("",!0)])])),_:1},16,["data-active-link","class","onClick"]))])}],["__file","MenuItem.vue"]])},21081:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"sidebar-list"},l={__name:"MenuList",props:{item:{type:Object}},setup:e=>(t,r)=>{const l=(0,o.resolveComponent)("MenuItem");return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.item.items,(e=>((0,o.openBlock)(),(0,o.createBlock)(l,{key:e.key,item:e},null,8,["item"])))),128))])}};const a=(0,r(66262).A)(l,[["__file","MenuList.vue"]])},84372:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>g});var o=r(29726);const i={key:0,class:"relative"},l={class:"inline-block shrink-0 w-6 h-6"},a={class:"flex-1 flex items-center w-full px-3 text-base"},n={class:"inline-block h-6 shrink-0"},s={key:0,class:"inline-flex items-center justify-center shrink-0 w-6 h-6"},c={key:0,class:"mt-1 flex flex-col"};var d=r(74640),u=r(35229),p=r(66278);function h(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function m(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?h(Object(r),!0).forEach((function(t){f(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):h(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function f(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const v={components:{Icon:d.Icon},mixins:[u.pJ],props:{item:{type:Object,required:!0}},methods:m(m({},(0,p.PY)(["toggleMainMenu"])),{},{handleClick(){this.item.collapsable&&this.toggleCollapse(),this.mainMenuShown&&"button"!==this.component&&this.toggleMainMenu()}}),computed:m(m({},(0,p.L8)(["mainMenuShown"])),{},{component(){return this.item.path?"Link":this.item.items.length>0&&this.item.collapsable?"button":"h3"},displayAsButton(){return["Link","button"].includes(this.component)},collapsedByDefault(){return this.item?.collapsedByDefault??!1}})};const g=(0,r(66262).A)(v,[["render",function(e,t,r,d,u,p){const h=(0,o.resolveComponent)("Icon"),m=(0,o.resolveComponent)("Badge"),f=(0,o.resolveComponent)("CollapseButton");return r.item.path||r.item.items.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(p.component),{href:r.item.path??null,onClick:(0,o.withModifiers)(p.handleClick,["prevent"]),tabindex:p.displayAsButton?0:null,class:(0,o.normalizeClass)(["w-full flex items-start px-1 py-1 rounded text-left text-gray-500 dark:text-gray-500 focus:outline-none focus:ring focus:ring-primary-200 dark:focus:ring-gray-600",{"cursor-pointer hover:bg-gray-200 dark:hover:bg-gray-800":p.displayAsButton,"font-bold text-primary-500 dark:text-primary-500":r.item.active}])},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",l,[(0,o.createVNode)(h,{name:r.item.icon,class:"inline-block"},null,8,["name"])]),(0,o.createElementVNode)("span",a,(0,o.toDisplayString)(r.item.name),1),(0,o.createElementVNode)("span",n,[r.item.badge?((0,o.openBlock)(),(0,o.createBlock)(m,{key:0,"extra-classes":r.item.badge.typeClass},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.item.badge.value),1)])),_:1},8,["extra-classes"])):(0,o.createCommentVNode)("",!0)]),r.item.collapsable?((0,o.openBlock)(),(0,o.createElementBlock)("span",s,[(0,o.createVNode)(f,{collapsed:e.collapsed,to:r.item.path},null,8,["collapsed","to"])])):(0,o.createCommentVNode)("",!0)])),_:1},8,["href","onClick","tabindex","class"])),r.item.items.length>0&&!e.collapsed?((0,o.openBlock)(),(0,o.createElementBlock)("div",c,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.item.items,(e=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(e.component),{key:e.name,item:e},null,8,["item"])))),128))])):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0)}],["__file","MenuSection.vue"]])},29033:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726);const i={class:"h-6 flex mb-3 text-sm font-bold"},l={class:"ml-auto font-semibold text-gray-400 text-xs"},a={class:"flex min-h-[90px]"};var n=r(38221),s=r.n(n),c=r(31126),d=r.n(c),u=r(27717);r(27554);const p={name:"BasePartitionMetric",props:{loading:Boolean,title:String,helpText:{},helpWidth:{},chartData:Array,legendsHeight:{type:String,default:"fixed"}},data:()=>({chartist:null,resizeObserver:null}),watch:{chartData:function(e,t){this.renderChart()}},created(){const e=s()((e=>e()),Nova.config("debounce"));this.resizeObserver=new ResizeObserver((t=>{e((()=>{this.renderChart()}))}))},mounted(){this.chartist=new u.rW(this.$refs.chart,this.formattedChartData,{donut:!0,donutWidth:10,startAngle:270,showLabel:!1}),this.chartist.on("draw",(e=>{"slice"===e.type&&e.element.attr({style:`stroke-width: 10px; stroke: ${e.meta.color} !important;`})})),this.resizeObserver.observe(this.$refs.chart)},beforeUnmount(){this.resizeObserver.unobserve(this.$refs.chart)},methods:{renderChart(){this.chartist.update(this.formattedChartData)},getItemColor:(e,t)=>"string"==typeof e.color?e.color:(e=>["#F5573B","#F99037","#F2CB22","#8FC15D","#098F56","#47C1BF","#1693EB","#6474D7","#9C6ADE","#E471DE"][e])(t)},computed:{chartClasses:()=>[],formattedChartData(){return{labels:this.formattedLabels,series:this.formattedData}},formattedItems(){return this.chartData.map(((e,t)=>({label:e.label,value:Nova.formatNumber(e.value),color:this.getItemColor(e,t),percentage:Nova.formatNumber(String(e.percentage))})))},formattedLabels(){return this.chartData.map((e=>e.label))},formattedData(){return this.chartData.map(((e,t)=>({value:e.value,meta:{color:this.getItemColor(e,t)}})))},formattedTotal(){let e=this.currentTotal.toFixed(2),t=Math.round(e);return t.toFixed(2)==e?Nova.formatNumber(new String(t)):Nova.formatNumber(new String(e))},currentTotal(){return d()(this.chartData,"value")}}};const h=(0,r(66262).A)(p,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("HelpTextTooltip"),u=(0,o.resolveComponent)("LoadingCard");return(0,o.openBlock)(),(0,o.createBlock)(u,{loading:r.loading,class:"px-6 py-4"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("h3",i,[(0,o.createTextVNode)((0,o.toDisplayString)(r.title)+" ",1),(0,o.createElementVNode)("span",l,"("+(0,o.toDisplayString)(c.formattedTotal)+" "+(0,o.toDisplayString)(e.__("total"))+")",1)]),(0,o.createVNode)(d,{text:r.helpText,width:r.helpWidth},null,8,["text","width"]),(0,o.createElementVNode)("div",a,[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["flex-1 overflow-hidden overflow-y-auto",{"max-h-[90px]":"fixed"===r.legendsHeight}])},[(0,o.createElementVNode)("ul",null,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(c.formattedItems,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("li",{key:e.color,class:"text-xs leading-normal"},[(0,o.createElementVNode)("span",{class:"inline-block rounded-full w-2 h-2 mr-2",style:(0,o.normalizeStyle)({backgroundColor:e.color})},null,4),(0,o.createTextVNode)((0,o.toDisplayString)(e.label)+" ("+(0,o.toDisplayString)(e.value)+" - "+(0,o.toDisplayString)(e.percentage)+"%) ",1)])))),128))])],2),(0,o.createElementVNode)("div",{ref:"chart",class:(0,o.normalizeClass)(["flex-none rounded-b-lg ct-chart mr-4 w-[90px] h-[90px]",{invisible:this.currentTotal<=0}])},null,2)])])),_:1},8,["loading"])}],["__file","BasePartitionMetric.vue"]])},39157:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726);const i={class:"h-6 flex items-center mb-4"},l={class:"flex-1 mr-3 leading-tight text-sm font-bold"},a={class:"flex-none text-right"},n={class:"text-gray-500 font-medium inline-block"},s={key:0,class:"text-sm"},c={class:"flex items-center text-4xl mb-4"},d={class:"flex h-full justify-center items-center flex-grow-1 mb-4"};var u=r(30043);const p={name:"BaseProgressMetric",props:{loading:{default:!0},title:{},helpText:{},helpWidth:{},maxWidth:{},target:{},value:{},percentage:{},format:{type:String,default:"(0[.]00a)"},avoid:{type:Boolean,default:!1},prefix:"",suffix:"",suffixInflection:{type:Boolean,default:!0}},computed:{isNullValue(){return null==this.value},formattedValue(){if(!this.isNullValue){const e=Nova.formatNumber(new String(this.value),this.format);return`${this.prefix}${e}`}return""},formattedSuffix(){return!1===this.suffixInflection?this.suffix:(0,u.singularOrPlural)(this.value,this.suffix)},bgClass(){return this.avoid?this.percentage>60?"bg-yellow-500":"bg-green-300":this.percentage>60?"bg-green-500":"bg-yellow-300"}}};const h=(0,r(66262).A)(p,[["render",function(e,t,r,u,p,h){const m=(0,o.resolveComponent)("HelpTextTooltip"),f=(0,o.resolveComponent)("ProgressBar"),v=(0,o.resolveComponent)("LoadingCard");return(0,o.openBlock)(),(0,o.createBlock)(v,{loading:r.loading,class:"flex flex-col px-6 py-4"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("h3",l,(0,o.toDisplayString)(r.title),1),(0,o.createVNode)(m,{text:r.helpText,width:r.helpWidth},null,8,["text","width"]),(0,o.createElementVNode)("div",a,[(0,o.createElementVNode)("span",n,[(0,o.createTextVNode)((0,o.toDisplayString)(h.formattedValue)+" ",1),r.suffix?((0,o.openBlock)(),(0,o.createElementBlock)("span",s,(0,o.toDisplayString)(h.formattedSuffix),1)):(0,o.createCommentVNode)("",!0)])])]),(0,o.createElementVNode)("p",c,(0,o.toDisplayString)(r.percentage)+"%",1),(0,o.createElementVNode)("div",d,[(0,o.createVNode)(f,{title:h.formattedValue,color:h.bgClass,value:r.percentage},null,8,["title","color","value"])])])),_:1},8,["loading"])}],["__file","BaseProgressMetric.vue"]])},28104:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>v});var o=r(29726);const i={class:"h-6 flex items-center mb-4"},l={class:"mr-3 leading-tight text-sm font-bold"},a={class:"flex items-center text-4xl mb-4"},n={key:0,class:"ml-2 text-sm font-bold"},s={ref:"chart",class:"absolute inset-0 rounded-b-lg ct-chart",style:{top:"60%"}};var c=r(38221),d=r.n(c),u=r(30043),p=r(27717),h=(r(27554),r(399)),m=r.n(h);r(55809);const f={name:"BaseTrendMetric",emits:["selected"],props:{loading:Boolean,title:{},helpText:{},helpWidth:{},value:{},chartData:{},maxWidth:{},prefix:"",suffix:"",suffixInflection:{type:Boolean,default:!0},ranges:{type:Array,default:()=>[]},selectedRangeKey:[String,Number],format:{type:String,default:"0[.]00a"}},data:()=>({chartist:null,resizeObserver:null}),watch:{selectedRangeKey:function(e,t){this.renderChart()},chartData:function(e,t){this.renderChart()}},created(){const e=d()((e=>e()),Nova.config("debounce"));this.resizeObserver=new ResizeObserver((t=>{e((()=>{this.renderChart()}))}))},mounted(){const e=Math.min(...this.chartData),t=Math.max(...this.chartData),r=e>=0?0:e;this.chartist=new p.bl(this.$refs.chart,{series:this.chartData},{lineSmooth:p.lc.none(),fullWidth:!0,showPoint:!0,showLine:!0,showArea:!0,chartPadding:{top:10,right:0,bottom:0,left:0},low:e,high:t,areaBase:r,axisX:{showGrid:!1,showLabel:!0,offset:0},axisY:{showGrid:!1,showLabel:!0,offset:0},plugins:[m()({pointClass:"ct-point",anchorToPoint:!1}),m()({pointClass:"ct-point__left",anchorToPoint:!1,tooltipOffset:{x:50,y:-20}}),m()({pointClass:"ct-point__right",anchorToPoint:!1,tooltipOffset:{x:-50,y:-20}})]}),this.chartist.on("draw",(e=>{"point"===e.type&&(e.element.attr({"ct:value":this.transformTooltipText(e.value.y)}),e.element.addClass(this.transformTooltipClass(e.axisX.ticks.length,e.index)??""))})),this.resizeObserver.observe(this.$refs.chart)},beforeUnmount(){this.resizeObserver.unobserve(this.$refs.chart)},methods:{renderChart(){this.chartist.update(this.chartData)},transformTooltipText(e){let t=Nova.formatNumber(new String(e),this.format);if(this.prefix)return`${this.prefix}${t}`;if(this.suffix){return`${t} ${this.suffixInflection?(0,u.singularOrPlural)(e,this.suffix):this.suffix}`}return`${t}`},transformTooltipClass:(e,t)=>t<2?"ct-point__left":t>e-3?"ct-point__right":"ct-point"},computed:{isNullValue(){return null==this.value},formattedValue(){if(!this.isNullValue){const e=Nova.formatNumber(new String(this.value),this.format);return`${this.prefix}${e}`}return""},formattedSuffix(){return!1===this.suffixInflection?this.suffix:(0,u.singularOrPlural)(this.value,this.suffix)}}};const v=(0,r(66262).A)(f,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("HelpTextTooltip"),h=(0,o.resolveComponent)("SelectControl"),m=(0,o.resolveComponent)("LoadingCard");return(0,o.openBlock)(),(0,o.createBlock)(m,{loading:r.loading,class:"px-6 py-4"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("h3",l,(0,o.toDisplayString)(r.title),1),(0,o.createVNode)(p,{text:r.helpText,width:r.helpWidth},null,8,["text","width"]),r.ranges.length>0?((0,o.openBlock)(),(0,o.createBlock)(h,{key:0,value:r.selectedRangeKey,"onUpdate:modelValue":t[0]||(t[0]=t=>e.$emit("selected",t)),options:r.ranges,size:"xxs",class:"ml-auto w-[6rem] shrink-0","aria-label":e.__("Select Ranges")},null,8,["value","options","aria-label"])):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("p",a,[(0,o.createTextVNode)((0,o.toDisplayString)(u.formattedValue)+" ",1),r.suffix?((0,o.openBlock)(),(0,o.createElementBlock)("span",n,(0,o.toDisplayString)(u.formattedSuffix),1)):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("div",s,null,512)])),_:1},8,["loading"])}],["__file","BaseTrendMetric.vue"]])},32983:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>x});var o=r(29726);const i={class:"h-6 flex items-center mb-4"},l={class:"mr-3 leading-tight text-sm font-bold"},a={class:"flex items-center mb-4 space-x-4"},n={key:0,class:"rounded-lg bg-primary-500 text-white h-14 w-14 flex items-center justify-center"},s={key:0,class:"ml-2 text-sm font-bold"},c={class:"flex items-center font-bold text-sm"},d={key:0,xmlns:"http://www.w3.org/2000/svg",class:"text-red-500 stroke-current mr-2",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},u={key:1,class:"text-green-500 stroke-current mr-2",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},p={key:2},h={key:0},m={key:1},f={key:3,class:"text-gray-400 font-semibold"},v={key:0},g={key:1},y={key:2};var b=r(74640),k=r(35229),w=r(30043);const C={name:"BaseValueMetric",components:{Icon:b.Icon},mixins:[k.nl],emits:["selected"],props:{loading:{default:!0},copyable:{default:!1},title:{},helpText:{},helpWidth:{},icon:{type:String},maxWidth:{},previous:{},value:{},prefix:"",suffix:"",suffixInflection:{default:!0},selectedRangeKey:[String,Number],ranges:{type:Array,default:()=>[]},format:{type:String,default:"(0[.]00a)"},tooltipFormat:{type:String,default:"(0[.]00)"},zeroResult:{default:!1}},data:()=>({copied:!1}),methods:{handleCopyClick(){this.copyable&&(this.copied=!0,this.copyValueToClipboard(this.tooltipFormattedValue),setTimeout((()=>{this.copied=!1}),2e3))}},computed:{growthPercentage(){return Math.abs(this.increaseOrDecrease)},increaseOrDecrease(){return 0===this.previous||null==this.previous||0===this.value?0:(0,w.increaseOrDecrease)(this.value,this.previous).toFixed(2)},increaseOrDecreaseLabel(){switch(Math.sign(this.increaseOrDecrease)){case 1:return"Increase";case 0:return"Constant";case-1:return"Decrease"}},sign(){switch(Math.sign(this.increaseOrDecrease)){case 1:return"+";case 0:return"";case-1:return"-"}},isNullValue(){return null==this.value},isNullPreviousValue(){return null==this.previous},formattedValue(){return this.isNullValue?"":this.prefix+Nova.formatNumber(new String(this.value),this.format)},tooltipFormattedValue(){return this.isNullValue?"":this.value},tooltipFormattedPreviousValue(){return this.isNullPreviousValue?"":this.previous},formattedSuffix(){return!1===this.suffixInflection?this.suffix:(0,w.singularOrPlural)(this.value,this.suffix)}}};const x=(0,r(66262).A)(C,[["render",function(e,t,r,b,k,w){const C=(0,o.resolveComponent)("HelpTextTooltip"),x=(0,o.resolveComponent)("SelectControl"),N=(0,o.resolveComponent)("Icon"),B=(0,o.resolveComponent)("LoadingCard"),S=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createBlock)(B,{loading:r.loading,class:"px-6 py-4"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("h3",l,(0,o.toDisplayString)(r.title),1),(0,o.createVNode)(C,{text:r.helpText,width:r.helpWidth},null,8,["text","width"]),r.ranges.length>0?((0,o.openBlock)(),(0,o.createBlock)(x,{key:0,value:r.selectedRangeKey,"onUpdate:modelValue":t[0]||(t[0]=t=>e.$emit("selected",t)),options:r.ranges,size:"xxs",class:"ml-auto w-[6rem] shrink-0","aria-label":e.__("Select Ranges")},null,8,["value","options","aria-label"])):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("div",a,[r.icon?((0,o.openBlock)(),(0,o.createElementBlock)("div",n,[(0,o.createVNode)(N,{name:r.icon,class:"inline-block"},null,8,["name"])])):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",null,[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(r.copyable?"CopyButton":"p"),{onClick:w.handleCopyClick,class:"flex items-center text-4xl",rounded:!1},{default:(0,o.withCtx)((()=>[(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createElementBlock)("span",null,[(0,o.createTextVNode)((0,o.toDisplayString)(w.formattedValue),1)])),[[S,`${w.tooltipFormattedValue}`]]),r.suffix?((0,o.openBlock)(),(0,o.createElementBlock)("span",s,(0,o.toDisplayString)(w.formattedSuffix),1)):(0,o.createCommentVNode)("",!0)])),_:1},8,["onClick"])),(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.createElementVNode)("p",c,["Decrease"===w.increaseOrDecreaseLabel?((0,o.openBlock)(),(0,o.createElementBlock)("svg",d,t[1]||(t[1]=[(0,o.createElementVNode)("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M13 17h8m0 0V9m0 8l-8-8-4 4-6-6"},null,-1)]))):(0,o.createCommentVNode)("",!0),"Increase"===w.increaseOrDecreaseLabel?((0,o.openBlock)(),(0,o.createElementBlock)("svg",u,t[2]||(t[2]=[(0,o.createElementVNode)("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M13 7h8m0 0v8m0-8l-8 8-4-4-6 6"},null,-1)]))):(0,o.createCommentVNode)("",!0),0!==w.increaseOrDecrease?((0,o.openBlock)(),(0,o.createElementBlock)("span",p,[0!==w.growthPercentage?((0,o.openBlock)(),(0,o.createElementBlock)("span",h,(0,o.toDisplayString)(w.growthPercentage)+"% "+(0,o.toDisplayString)(e.__(w.increaseOrDecreaseLabel)),1)):((0,o.openBlock)(),(0,o.createElementBlock)("span",m,(0,o.toDisplayString)(e.__("No Increase")),1))])):((0,o.openBlock)(),(0,o.createElementBlock)("span",f,["0"===r.previous&&"0"!==r.value?((0,o.openBlock)(),(0,o.createElementBlock)("span",v,(0,o.toDisplayString)(e.__("No Prior Data")),1)):(0,o.createCommentVNode)("",!0),"0"!==r.value||"0"===r.previous||r.zeroResult?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createElementBlock)("span",g,(0,o.toDisplayString)(e.__("No Current Data")),1)),"0"!=r.value||"0"!=r.previous||r.zeroResult?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createElementBlock)("span",y,(0,o.toDisplayString)(e.__("No Data")),1))]))])])),[[S,`${w.tooltipFormattedPreviousValue}`]])])])])),_:1},8,["loading"])}],["__file","BaseValueMetric.vue"]])},99543:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726);const i={class:"group"},l={class:"text-base text-gray-500 truncate"},a={class:"text-gray-400 text-xs truncate"},n={class:"flex justify-end items-center text-gray-400"},s={class:"py-1"};var c=r(74640),d=r(42194),u=r.n(d);const p={components:{Button:c.Button,Icon:c.Icon},props:{row:{type:Object,required:!0}},methods:{actionAttributes(e){let t=e.method||"GET";return e.external&&"GET"==e.method?{as:"external",href:e.path,name:e.name,title:e.name,target:e.target||null,external:!0}:u()({as:"GET"===t?"link":"form-button",href:e.path,method:"GET"!==t?t:null,data:e.data||null,headers:e.headers||null},(e=>null===e))}},computed:{rowClasses:()=>["py-2"]}};const h=(0,r(66262).A)(p,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("Icon"),h=(0,o.resolveComponent)("Button"),m=(0,o.resolveComponent)("DropdownMenuItem"),f=(0,o.resolveComponent)("ScrollWrap"),v=(0,o.resolveComponent)("DropdownMenu"),g=(0,o.resolveComponent)("Dropdown");return(0,o.openBlock)(),(0,o.createElementBlock)("tr",i,[r.row.icon?((0,o.openBlock)(),(0,o.createElementBlock)("td",{key:0,class:(0,o.normalizeClass)(["pl-6 w-14 pr-2",{[r.row.iconClass]:!0,[u.rowClasses]:!0,"text-gray-400 dark:text-gray-600":!r.row.iconClass}])},[(0,o.createVNode)(p,{name:r.row.icon,class:"inline-block"},null,8,["name"])],2)):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("td",{class:(0,o.normalizeClass)(["px-2 w-auto",{[u.rowClasses]:!0,"pl-6":!r.row.icon,"pr-6":!r.row.editUrl||!r.row.viewUrl}])},[(0,o.createElementVNode)("h2",l,(0,o.toDisplayString)(r.row.title),1),(0,o.createElementVNode)("p",a,(0,o.toDisplayString)(r.row.subtitle),1)],2),r.row.actions.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("td",{key:1,class:(0,o.normalizeClass)(["text-right pr-4 w-12",u.rowClasses])},[(0,o.createElementVNode)("div",n,[(0,o.createVNode)(g,null,{menu:(0,o.withCtx)((()=>[(0,o.createVNode)(v,{width:"auto",class:"px-1"},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(f,{height:250,class:"divide-y divide-gray-100 dark:divide-gray-800 divide-solid"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",s,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.row.actions,((e,t)=>((0,o.openBlock)(),(0,o.createBlock)(m,(0,o.mergeProps)({key:t,ref_for:!0},u.actionAttributes(e)),{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.name),1)])),_:2},1040)))),128))])])),_:1})])),_:1})])),default:(0,o.withCtx)((()=>[(0,o.createVNode)(h,{icon:"ellipsis-horizontal",variant:"action","aria-label":e.__("Resource Row Dropdown")},null,8,["aria-label"])])),_:1})])],2)):(0,o.createCommentVNode)("",!0)])}],["__file","MetricTableRow.vue"]])},64903:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={mixins:[r(35229).je],data:()=>({loading:!0,chartData:[]}),watch:{resourceId(){this.fetch()}},created(){this.fetch()},mounted(){this.card&&!0===this.card.refreshWhenFiltersChange&&(Nova.$on("filter-changed",this.fetch),Nova.$on("filter-reset",this.fetch))},beforeUnmount(){this.card&&!0===this.card.refreshWhenFiltersChange&&(Nova.$off("filter-changed",this.fetch),Nova.$off("filter-reset",this.fetch))},methods:{handleFetchCallback(){return({data:{value:{value:e}}})=>{this.chartData=e,this.loading=!1}}},computed:{metricPayload(){const e={params:{}};return!Nova.missingResource(this.resourceName)&&this.card&&!0===this.card.refreshWhenFiltersChange&&(e.params.filter=this.$store.getters[`${this.resourceName}/currentEncodedFilters`]),e}}};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("BasePartitionMetric");return(0,o.openBlock)(),(0,o.createBlock)(n,{title:e.card.name,"help-text":e.card.helpText,"help-width":e.card.helpWidth,"chart-data":e.chartData,loading:e.loading,"legends-height":e.card.height},null,8,["title","help-text","help-width","chart-data","loading","legends-height"])}],["__file","PartitionMetric.vue"]])},98825:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);var i=r(35229);const l={name:"ProgressMetric",mixins:[i.Z4,i.je],data:()=>({loading:!0,format:"(0[.]00a)",avoid:!1,prefix:"",suffix:"",suffixInflection:!0,value:0,target:0,percentage:0,zeroResult:!1}),watch:{resourceId(){this.fetch()}},created(){this.hasRanges&&(this.selectedRangeKey=this.card.selectedRangeKey||this.card.ranges[0].value),this.fetch()},mounted(){this.card&&!0===this.card.refreshWhenFiltersChange&&(Nova.$on("filter-changed",this.fetch),Nova.$on("filter-reset",this.fetch))},beforeUnmount(){this.card&&!0===this.card.refreshWhenFiltersChange&&(Nova.$off("filter-changed",this.fetch),Nova.$off("filter-reset",this.fetch))},methods:{handleFetchCallback(){return({data:{value:{value:e,target:t,percentage:r,prefix:o,suffix:i,suffixInflection:l,format:a,avoid:n}}})=>{this.value=e,this.target=t,this.percentage=r,this.format=a||this.format,this.avoid=n,this.prefix=o||this.prefix,this.suffix=i||this.suffix,this.suffixInflection=l,this.loading=!1}}},computed:{metricPayload(){const e={params:{timezone:this.userTimezone}};return!Nova.missingResource(this.resourceName)&&this.card&&!0===this.card.refreshWhenFiltersChange&&(e.params.filter=this.$store.getters[`${this.resourceName}/currentEncodedFilters`]),e}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("BaseProgressMetric");return(0,o.openBlock)(),(0,o.createBlock)(n,{title:e.card.name,"help-text":e.card.helpText,"help-width":e.card.helpWidth,target:e.target,value:e.value,percentage:e.percentage,prefix:e.prefix,suffix:e.suffix,"suffix-inflection":e.suffixInflection,format:e.format,avoid:e.avoid,loading:e.loading},null,8,["title","help-text","help-width","target","value","percentage","prefix","suffix","suffix-inflection","format","avoid","loading"])}],["__file","ProgressMetric.vue"]])},33796:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>m});var o=r(29726);const i={class:"h-6 flex items-center px-6 mb-4"},l={class:"mr-3 leading-tight text-sm font-bold"},a={class:"mb-5 pb-4"},n={key:0,class:"overflow-hidden overflow-x-auto relative"},s={class:"w-full table-default table-fixed"},c={class:"border-t border-b border-gray-100 dark:border-gray-700 divide-y divide-gray-100 dark:divide-gray-700"},d={key:1,class:"flex flex-col items-center justify-between px-6 gap-2"},u={class:"font-normal text-center py-4"};var p=r(35229);const h={name:"TableCard",mixins:[p.Z4,p.je],data:()=>({loading:!0,value:[]}),watch:{resourceId(){this.fetch()}},created(){this.fetch()},mounted(){this.card&&!0===this.card.refreshWhenFiltersChange&&(Nova.$on("filter-changed",this.fetch),Nova.$on("filter-reset",this.fetch))},beforeUnmount(){this.card&&!0===this.card.refreshWhenFiltersChange&&(Nova.$off("filter-changed",this.fetch),Nova.$off("filter-reset",this.fetch))},methods:{handleFetchCallback(){return({data:{value:e}})=>{this.value=e,this.loading=!1}}},computed:{metricPayload(){const e={params:{timezone:this.userTimezone}};return!Nova.missingResource(this.resourceName)&&this.card&&!0===this.card.refreshWhenFiltersChange&&(e.params.filter=this.$store.getters[`${this.resourceName}/currentEncodedFilters`]),e}}};const m=(0,r(66262).A)(h,[["render",function(e,t,r,p,h,m){const f=(0,o.resolveComponent)("HelpTextTooltip"),v=(0,o.resolveComponent)("MetricTableRow"),g=(0,o.resolveComponent)("LoadingCard");return(0,o.openBlock)(),(0,o.createBlock)(g,{loading:e.loading,class:"pt-4"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("h3",l,(0,o.toDisplayString)(e.card.name),1),(0,o.createVNode)(f,{text:e.card.helpText,width:e.card.helpWidth},null,8,["text","width"])]),(0,o.createElementVNode)("div",a,[e.value.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",n,[(0,o.createElementVNode)("table",s,[(0,o.createElementVNode)("tbody",c,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.value,(e=>((0,o.openBlock)(),(0,o.createBlock)(v,{row:e},null,8,["row"])))),256))])])])):((0,o.openBlock)(),(0,o.createElementBlock)("div",d,[(0,o.createElementVNode)("p",u,(0,o.toDisplayString)(e.card.emptyText),1)]))])])),_:1},8,["loading"])}],["__file","TableMetric.vue"]])},1740:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);var i=r(35229);const l={name:"TrendMetric",mixins:[i.Z4,i.je],data:()=>({loading:!0,value:"",data:[],format:"(0[.]00a)",prefix:"",suffix:"",suffixInflection:!0,selectedRangeKey:null}),watch:{resourceId(){this.fetch()}},created(){this.hasRanges&&(this.selectedRangeKey=this.card.selectedRangeKey||this.card.ranges[0].value),this.fetch()},mounted(){this.card&&!0===this.card.refreshWhenFiltersChange&&(Nova.$on("filter-changed",this.fetch),Nova.$on("filter-reset",this.fetch))},beforeUnmount(){this.card&&!0===this.card.refreshWhenFiltersChange&&(Nova.$off("filter-changed",this.fetch),Nova.$off("filter-reset",this.fetch))},methods:{handleRangeSelected(e){this.selectedRangeKey=e,this.fetch()},handleFetchCallback(){return({data:{value:{labels:e,trend:t,value:r,prefix:o,suffix:i,suffixInflection:l,format:a}}})=>{this.value=r,this.labels=Object.keys(t),this.data={labels:Object.keys(t),series:[Object.entries(t).map((([e,t])=>({meta:`${e}`,value:t})))]},this.format=a||this.format,this.prefix=o||this.prefix,this.suffix=i||this.suffix,this.suffixInflection=l,this.loading=!1}}},computed:{hasRanges(){return this.card.ranges.length>0},metricPayload(){const e={params:{timezone:this.userTimezone,twelveHourTime:this.usesTwelveHourTime}};return!Nova.missingResource(this.resourceName)&&this.card&&!0===this.card.refreshWhenFiltersChange&&(e.params.filter=this.$store.getters[`${this.resourceName}/currentEncodedFilters`]),this.hasRanges&&(e.params.range=this.selectedRangeKey),e}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("BaseTrendMetric");return(0,o.openBlock)(),(0,o.createBlock)(n,{onSelected:a.handleRangeSelected,title:e.card.name,"help-text":e.card.helpText,"help-width":e.card.helpWidth,value:e.value,"chart-data":e.data,ranges:e.card.ranges,format:e.format,prefix:e.prefix,suffix:e.suffix,"suffix-inflection":e.suffixInflection,"selected-range-key":e.selectedRangeKey,loading:e.loading},null,8,["onSelected","title","help-text","help-width","value","chart-data","ranges","format","prefix","suffix","suffix-inflection","selected-range-key","loading"])}],["__file","TrendMetric.vue"]])},58937:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);var i=r(35229);const l={name:"ValueMetric",mixins:[i.Z4,i.je],data:()=>({loading:!0,copyable:!1,format:"(0[.]00a)",tooltipFormat:"(0[.]00)",value:0,previous:0,prefix:"",suffix:"",suffixInflection:!0,selectedRangeKey:null,zeroResult:!1}),watch:{resourceId(){this.fetch()}},created(){this.hasRanges&&(this.selectedRangeKey=this.card.selectedRangeKey||this.card.ranges[0].value),this.fetch()},mounted(){this.card&&!0===this.card.refreshWhenFiltersChange&&(Nova.$on("filter-changed",this.fetch),Nova.$on("filter-reset",this.fetch))},beforeUnmount(){this.card&&!0===this.card.refreshWhenFiltersChange&&(Nova.$off("filter-changed",this.fetch),Nova.$off("filter-reset",this.fetch))},methods:{handleRangeSelected(e){this.selectedRangeKey=e,this.fetch()},handleFetchCallback(){return({data:{value:{copyable:e,value:t,previous:r,prefix:o,suffix:i,suffixInflection:l,format:a,tooltipFormat:n,zeroResult:s}}})=>{this.copyable=e,this.value=t,this.format=a||this.format,this.tooltipFormat=n||this.tooltipFormat,this.prefix=o||this.prefix,this.suffix=i||this.suffix,this.suffixInflection=l,this.zeroResult=s||this.zeroResult,this.previous=r,this.loading=!1}}},computed:{hasRanges(){return this.card.ranges.length>0},metricPayload(){const e={params:{timezone:this.userTimezone}};return!Nova.missingResource(this.resourceName)&&this.card&&!0===this.card.refreshWhenFiltersChange&&(e.params.filter=this.$store.getters[`${this.resourceName}/currentEncodedFilters`]),this.hasRanges&&(e.params.range=this.selectedRangeKey),e}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("BaseValueMetric");return(0,o.openBlock)(),(0,o.createBlock)(n,{onSelected:a.handleRangeSelected,title:e.card.name,copyable:e.copyable,"help-text":e.card.helpText,"help-width":e.card.helpWidth,icon:e.card.icon,previous:e.previous,value:e.value,ranges:e.card.ranges,format:e.format,"tooltip-format":e.tooltipFormat,prefix:e.prefix,suffix:e.suffix,"suffix-inflection":e.suffixInflection,"selected-range-key":e.selectedRangeKey,loading:e.loading,"zero-result":e.zeroResult},null,8,["onSelected","title","copyable","help-text","help-width","icon","previous","value","ranges","format","tooltip-format","prefix","suffix","suffix-inflection","selected-range-key","loading","zero-result"])}],["__file","ValueMetric.vue"]])},61462:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>S});var o=r(29726),i=r(66278),l=r(74640),a=r(57091),n=r(83488),s=r.n(n),c=r(42194),d=r.n(c),u=r(71086),p=r.n(u),h=r(65835),m=r(59977);function f(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function v(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?f(Object(r),!0).forEach((function(t){g(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):f(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function g(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const y={class:"md:hidden bg-gray-100 dark:bg-gray-900/30 rounded-lg py-4 px-2"},b={class:"flex flex-col gap-2"},k={class:"inline-flex items-center shrink-0 gap-2 px-2"},w=["alt","src"],C={class:"font-bold whitespace-nowrap"},x={class:"flex flex-col"},N={key:0,class:"mr-1"},B={__name:"MobileUserMenu",setup(e){const{__:t}=(0,h.B)(),r=(0,i.Pj)(),n=(0,o.computed)((()=>r.getters.userMenu.map((e=>{let t=e.method||"GET",r={href:e.path};return e.external&&"GET"===t?{component:"a",props:v(v({},r),{},{target:e.target||null}),name:e.name,external:e.external,on:{}}:{component:"GET"===t?"a":"FormButton",props:p()(d()(v(v({},r),{},{method:"GET"!==t?t:null,data:e.data||null,headers:e.headers||null}),(e=>null===e)),s()),external:e.external,name:e.name,on:{},badge:e.badge}})))),c=(0,o.computed)((()=>r.getters.currentUser?.name||r.getters.currentUser?.email||t("Nova User"))),u=(0,o.computed)((()=>Nova.config("customLogoutPath"))),f=(0,o.computed)((()=>!0===Nova.config("withAuthentication")||!1!==u.value)),g=(0,o.computed)((()=>Nova.hasSecurityFeatures())),B=()=>{confirm(t("Are you sure you want to stop impersonating?"))&&r.dispatch("stopImpersonating")},S=()=>{Nova.visit("/user-security")},V=async()=>{confirm(t("Are you sure you want to log out?"))&&r.dispatch("logout",Nova.config("customLogoutPath")).then((e=>{null===e?Nova.redirectToLogin():location.href=e})).catch((()=>m.QB.reload()))};return(e,i)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",y,[(0,o.createElementVNode)("div",b,[(0,o.createElementVNode)("div",k,[(0,o.unref)(r).getters.currentUser?.impersonating?((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(l.Icon),{key:0,name:"finger-print",type:"solid"})):(0,o.unref)(r).getters.currentUser?.avatar?((0,o.openBlock)(),(0,o.createElementBlock)("img",{key:1,alt:(0,o.unref)(t)(":name's Avatar",{name:c.value}),src:(0,o.unref)(r).getters.currentUser?.avatar,class:"rounded-full w-7 h-7"},null,8,w)):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("span",C,(0,o.toDisplayString)(c.value),1)]),(0,o.createElementVNode)("nav",x,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(n.value,(e=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(e.component),(0,o.mergeProps)({key:e.path,ref_for:!0},e.props,(0,o.toHandlers)(e.on),{class:"py-2 px-2 text-gray-600 dark:text-gray-400 hover:opacity-50"}),{default:(0,o.withCtx)((()=>[e.badge?((0,o.openBlock)(),(0,o.createElementBlock)("span",N,[(0,o.createVNode)(a.default,{"extra-classes":e.badge.typeClass},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.badge.value),1)])),_:2},1032,["extra-classes"])])):(0,o.createCommentVNode)("",!0),(0,o.createTextVNode)(" "+(0,o.toDisplayString)(e.name),1)])),_:2},1040)))),128)),(0,o.unref)(r).getters.currentUser?.impersonating?((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:0,type:"button",onClick:B,class:"block w-full py-2 px-2 text-gray-600 dark:text-gray-400 hover:opacity-50 text-left"},(0,o.toDisplayString)((0,o.unref)(t)("Stop Impersonating")),1)):(0,o.createCommentVNode)("",!0),g.value?((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:1,type:"button",onClick:S,class:"block w-full py-2 px-2 text-gray-600 dark:text-gray-400 hover:opacity-50 text-left"},(0,o.toDisplayString)((0,o.unref)(t)("User Security")),1)):(0,o.createCommentVNode)("",!0),f.value?((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:2,onClick:V,type:"button",class:"block w-full py-2 px-2 text-gray-600 dark:text-gray-400 hover:opacity-50 text-left"},(0,o.toDisplayString)((0,o.unref)(t)("Logout")),1)):(0,o.createCommentVNode)("",!0)])])]))}};const S=(0,r(66262).A)(B,[["__file","MobileUserMenu.vue"]])},75713:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i=["data-form-unique-id"],l={key:1},a={class:"flex items-center ml-auto"};var n=r(35229),s=r(23805),c=r.n(s),d=r(25542);const u={components:{Button:r(74640).Button},emits:["confirm","close"],mixins:[n.Uf],props:{action:{type:Object,required:!0},endpoint:{type:String,required:!1},errors:{type:Object,required:!0},resourceName:{type:String,required:!0},selectedResources:{type:[Array,String],required:!0},show:{type:Boolean,default:!1},working:Boolean},data:()=>({loading:!0,formUniqueId:(0,d.L)()}),created(){document.addEventListener("keydown",this.handleKeydown)},mounted(){this.loading=!1},beforeUnmount(){document.removeEventListener("keydown",this.handleKeydown)},methods:{onUpdateFormStatus(){this.updateModalStatus()},onUpdateFieldStatus(){this.onUpdateFormStatus()},handlePreventModalAbandonmentOnClose(e){this.handlePreventModalAbandonment((()=>{this.$emit("close")}),(()=>{e.stopPropagation()}))}},computed:{syncEndpoint(){let e=new URLSearchParams({action:this.action.uriKey});return"all"===this.selectedResources?e.append("resources","all"):this.selectedResources.forEach((t=>{e.append("resources[]",c()(t)?t.id.value:t)})),(this.endpoint||`/nova-api/${this.resourceName}/action`)+"?"+e.toString()},usesFocusTrap(){return!1===this.loading&&this.action.fields.length>0}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("ModalHeader"),u=(0,o.resolveComponent)("Button"),p=(0,o.resolveComponent)("ModalFooter"),h=(0,o.resolveComponent)("Modal");return(0,o.openBlock)(),(0,o.createBlock)(h,{show:r.show,onCloseViaEscape:c.handlePreventModalAbandonmentOnClose,role:"dialog",size:r.action.modalSize,"modal-style":r.action.modalStyle,"use-focus-trap":c.usesFocusTrap},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("form",{ref:"theForm",autocomplete:"off",onChange:t[1]||(t[1]=(...e)=>c.onUpdateFormStatus&&c.onUpdateFormStatus(...e)),onSubmit:t[2]||(t[2]=(0,o.withModifiers)((t=>e.$emit("confirm")),["prevent","stop"])),"data-form-unique-id":e.formUniqueId,class:(0,o.normalizeClass)(["bg-white dark:bg-gray-800",{"rounded-lg shadow-lg overflow-hidden space-y-6":"window"===r.action.modalStyle,"flex flex-col justify-between h-full":"fullscreen"===r.action.modalStyle}])},[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["space-y-6",{"overflow-hidden overflow-y-auto":"fullscreen"===r.action.modalStyle}])},[(0,o.createVNode)(d,{textContent:(0,o.toDisplayString)(r.action.name)},null,8,["textContent"]),r.action.confirmText?((0,o.openBlock)(),(0,o.createElementBlock)("p",{key:0,class:(0,o.normalizeClass)(["px-8",{"text-red-500":r.action.destructive}])},(0,o.toDisplayString)(r.action.confirmText),3)):(0,o.createCommentVNode)("",!0),r.action.fields.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.action.fields,(t=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{class:"action",key:t.attribute},[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)("form-"+t.component),{errors:r.errors,"resource-name":r.resourceName,field:t,"show-help-text":!0,"form-unique-id":e.formUniqueId,mode:"fullscreen"===r.action.modalStyle?"action-fullscreen":"action-modal","sync-endpoint":c.syncEndpoint,onFieldChanged:c.onUpdateFieldStatus},null,40,["errors","resource-name","field","form-unique-id","mode","sync-endpoint","onFieldChanged"]))])))),128))])):(0,o.createCommentVNode)("",!0)],2),(0,o.createVNode)(p,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",a,[(0,o.createVNode)(u,{variant:"link",state:"mellow",onClick:t[0]||(t[0]=t=>e.$emit("close")),dusk:"cancel-action-button",class:"ml-auto mr-3"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.action.cancelButtonText),1)])),_:1}),(0,o.createVNode)(u,{ref:"runButton",type:"submit",loading:r.working,variant:"solid",state:r.action.destructive?"danger":"default",dusk:"confirm-action-button"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.action.confirmButtonText),1)])),_:1},8,["loading","state"])])])),_:1})],42,i)])),_:1},8,["show","onCloseViaEscape","size","modal-style","use-focus-trap"])}],["__file","ConfirmActionModal.vue"]])},48619:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={class:"bg-white dark:bg-gray-800 rounded-lg shadow-lg overflow-hidden",style:{width:"460px"}},l={class:"leading-tight"},a={class:"ml-auto"};const n={components:{Button:r(74640).Button},emits:["confirm","close"],props:{show:{type:Boolean,default:!1}},data:()=>({working:!1}),watch:{show(e){!1===e&&(this.working=!1)}},methods:{handleClose(){this.working=!1,this.$emit("close")},handleConfirm(){this.working=!0,this.$emit("confirm")}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("ModalHeader"),u=(0,o.resolveComponent)("ModalContent"),p=(0,o.resolveComponent)("Button"),h=(0,o.resolveComponent)("ModalFooter"),m=(0,o.resolveComponent)("Modal");return(0,o.openBlock)(),(0,o.createBlock)(m,{show:r.show,role:"alertdialog",size:"md"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createVNode)(d,{textContent:(0,o.toDisplayString)(e.__("Delete File"))},null,8,["textContent"]),(0,o.createVNode)(u,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("p",l,(0,o.toDisplayString)(e.__("Are you sure you want to delete this file?")),1)])),_:1}),(0,o.createVNode)(h,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",a,[(0,o.createVNode)(p,{variant:"link",state:"mellow",onClick:(0,o.withModifiers)(c.handleClose,["prevent"]),class:"mr-3",dusk:"cancel-upload-delete-button"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Cancel")),1)])),_:1},8,["onClick"]),(0,o.createVNode)(p,{onClick:(0,o.withModifiers)(c.handleConfirm,["prevent"]),ref:"confirmButton",dusk:"confirm-upload-delete-button",loading:e.working,state:"danger",label:e.__("Delete")},null,8,["onClick","loading","label"])])])),_:1})])])),_:1},8,["show"])}],["__file","ConfirmUploadRemovalModal.vue"]])},80245:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726);const i={class:"space-y-6"},l={class:"px-8"},a={class:"px-8 mb-6"},n=["placeholder","disabled"],s={class:"flex items-center ml-auto"};var c=r(35229);const d={components:{Button:r(74640).Button},emits:["confirm","close"],mixins:[c.Uf],props:{show:{type:Boolean,default:!1},title:{type:String,default:null},content:{type:String,default:null},button:{type:String,default:null}},data:()=>({form:Nova.form({password:""}),loading:!1,completed:!1}),methods:{async submit(){try{let{redirect:e}=await this.form.post(Nova.url("/user-security/confirm-password"));this.completed=!0,this.$emit("confirm")}catch(e){500===e.response?.status&&Nova.error(this.__("There was a problem submitting the form."))}this.form.password="",this.$refs.passwordInput.focus()},handlePreventModalAbandonmentOnClose(e){this.handlePreventModalAbandonment((()=>{this.handleClose()}),(()=>{e.stopPropagation()}))},handleClose(){this.form.password="",this.$emit("close")}}};const u=(0,r(66262).A)(d,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("ModalHeader"),h=(0,o.resolveComponent)("HelpText"),m=(0,o.resolveComponent)("Button"),f=(0,o.resolveComponent)("ModalFooter"),v=(0,o.resolveComponent)("Modal");return(0,o.openBlock)(),(0,o.createBlock)(v,{show:r.show,onCloseViaEscape:u.handlePreventModalAbandonmentOnClose,role:"dialog",size:"2xl","modal-style":"window","use-focus-trap":r.show},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("form",{ref:"theForm",autocomplete:"off",onSubmit:t[1]||(t[1]=(0,o.withModifiers)(((...e)=>u.submit&&u.submit(...e)),["prevent","stop"])),class:"bg-white dark:bg-gray-800 rounded-lg shadow-lg overflow-hidden space-y-6"},[(0,o.createElementVNode)("div",i,[(0,o.createVNode)(p,{textContent:(0,o.toDisplayString)(e.__(r.title??"Confirm Password"))},null,8,["textContent"]),(0,o.createElementVNode)("p",l,(0,o.toDisplayString)(e.__(r.content??"For your security, please confirm your password to continue.")),1),(0,o.createElementVNode)("div",a,[(0,o.withDirectives)((0,o.createElementVNode)("input",{"onUpdate:modelValue":t[0]||(t[0]=t=>e.form.password=t),ref:"passwordInput",class:(0,o.normalizeClass)(["form-control form-input form-control-bordered w-full",{"form-control-bordered-error":e.form.errors.has("password")}]),placeholder:e.__("Password"),type:"password",name:"password",disabled:!r.show,required:"",autocomplete:"current-password"},null,10,n),[[o.vModelText,e.form.password]]),e.form.errors.has("password")?((0,o.openBlock)(),(0,o.createBlock)(h,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.form.errors.first("password")),1)])),_:1})):(0,o.createCommentVNode)("",!0)])]),(0,o.createVNode)(f,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",s,[(0,o.createVNode)(m,{variant:"link",state:"mellow",disabled:e.loading,onClick:u.handleClose,dusk:"cancel-confirm-password-button",class:"ml-auto mr-3"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Cancel")),1)])),_:1},8,["disabled","onClick"]),(0,o.createVNode)(m,{ref:"runButton",type:"submit",variant:"solid",state:"default",loading:e.loading,disabled:e.completed,dusk:"submit-confirm-password-button"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__(r.button??"Confirm")),1)])),_:1},8,["loading","disabled"])])])),_:1})],544)])),_:1},8,["show","onCloseViaEscape","use-focus-trap"])}],["__file","ConfirmsPasswordModal.vue"]])},6347:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={class:"bg-gray-100 dark:bg-gray-700 rounded-lg shadow-lg overflow-hidden p-8"};var l=r(35229),a=r(3056);const n={emits:["set-resource","create-cancelled"],mixins:[l.Uf],components:{CreateResource:a.A},props:{show:{type:Boolean,default:!1},size:{type:String,default:"2xl"},resourceName:{},resourceId:{},viaResource:{},viaResourceId:{},viaRelationship:{}},data:()=>({loading:!0}),methods:{handleRefresh(e){this.$emit("set-resource",e)},handleCreateCancelled(){return this.$emit("create-cancelled")},handlePreventModalAbandonmentOnClose(e){this.handlePreventModalAbandonment((()=>{this.handleCreateCancelled()}),(()=>{e.stopPropagation()}))}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("CreateResource"),c=(0,o.resolveComponent)("Modal");return(0,o.openBlock)(),(0,o.createBlock)(c,{dusk:"new-relation-modal",show:r.show,onCloseViaEscape:n.handlePreventModalAbandonmentOnClose,size:r.size,"use-focus-trap":!e.loading},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createVNode)(s,{"resource-name":r.resourceName,onCreateCancelled:n.handleCreateCancelled,onFinishedLoading:t[0]||(t[0]=t=>e.$nextTick((()=>e.loading=!1))),onRefresh:n.handleRefresh,mode:"modal","resource-id":"","via-relationship":"","via-resource-id":"","via-resource":""},null,8,["resource-name","onCreateCancelled","onRefresh"])])])),_:1},8,["show","onCloseViaEscape","size","use-focus-trap"])}],["__file","CreateRelationModal.vue"]])},24916:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>d});var o=r(29726);const i={class:"leading-normal"},l={class:"ml-auto"};var a=r(74640),n=r(90128),s=r.n(n);const c={components:{Button:a.Button},emits:["confirm","close"],props:{show:{type:Boolean,default:!1},mode:{type:String,default:"delete",validator:e=>["force delete","delete","detach"].includes(e)}},data:()=>({working:!1}),watch:{show(e){!1===e&&(this.working=!1)}},methods:{handleClose(){this.$emit("close"),this.working=!1},handleConfirm(){this.$emit("confirm"),this.working=!0}},computed:{uppercaseMode(){return s()(this.mode)}}};const d=(0,r(66262).A)(c,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("ModalHeader"),d=(0,o.resolveComponent)("ModalContent"),u=(0,o.resolveComponent)("Button"),p=(0,o.resolveComponent)("ModalFooter"),h=(0,o.resolveComponent)("Modal");return(0,o.openBlock)(),(0,o.createBlock)(h,{show:r.show,role:"alertdialog",size:"sm"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("form",{onSubmit:t[0]||(t[0]=(0,o.withModifiers)(((...e)=>s.handleConfirm&&s.handleConfirm(...e)),["prevent"])),class:"mx-auto bg-white dark:bg-gray-800 rounded-lg shadow-lg overflow-hidden"},[(0,o.renderSlot)(e.$slots,"default",{},(()=>[(0,o.createVNode)(c,{textContent:(0,o.toDisplayString)(e.__(`${s.uppercaseMode} Resource`))},null,8,["textContent"]),(0,o.createVNode)(d,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("p",i,(0,o.toDisplayString)(e.__("Are you sure you want to "+r.mode+" the selected resources?")),1)])),_:1})])),(0,o.createVNode)(p,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",l,[(0,o.createVNode)(u,{variant:"link",state:"mellow",onClick:(0,o.withModifiers)(s.handleClose,["prevent"]),class:"mr-3",dusk:"cancel-delete-button"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Cancel")),1)])),_:1},8,["onClick"]),(0,o.createVNode)(u,{type:"submit",ref:"confirmButton",dusk:"confirm-delete-button",loading:e.working,state:"danger",label:e.__(s.uppercaseMode)},null,8,["loading","label"])])])),_:1})],32)])),_:3},8,["show"])}],["__file","DeleteResourceModal.vue"]])},41488:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726),i=r(66278),l=r(87612),a=r.n(l),n=r(90179),s=r.n(n),c=r(5620),d=r(96433);const u=["role","data-modal-open","aria-modal"],p=Object.assign({inheritAttrs:!1},{__name:"Modal",props:{show:{type:Boolean,default:!1},size:{type:String,default:"xl",validator:e=>["sm","md","lg","xl","2xl","3xl","4xl","5xl","6xl","7xl"].includes(e)},modalStyle:{type:String,default:"window"},role:{type:String,default:"dialog"},useFocusTrap:{type:Boolean,default:!0}},emits:["showing","closing","close-via-escape"],setup(e,{emit:t}){const r=(0,o.useTemplateRef)("modalContent"),l=(0,o.useAttrs)(),n=t,p=e,h=(0,o.ref)(!0),m=(0,o.computed)((()=>p.useFocusTrap&&!0===h.value)),{activate:f,deactivate:v}=(0,c.r)(r,{immediate:!1,allowOutsideClick:!0,escapeDeactivates:!1});(0,o.watch)((()=>p.show),(e=>k(e))),(0,o.watch)(m,(e=>{try{e?(0,o.nextTick)((()=>f())):v()}catch(e){}})),(0,d.MLh)(document,"keydown",(e=>{"Escape"===e.key&&!0===p.show&&n("close-via-escape",e)}));const g=()=>{h.value=!1},y=()=>{h.value=!0};(0,o.onMounted)((()=>{Nova.$on("disable-focus-trap",g),Nova.$on("enable-focus-trap",y),!0===p.show&&k(!0)})),(0,o.onBeforeUnmount)((()=>{document.body.classList.remove("overflow-hidden"),Nova.resumeShortcuts(),Nova.$off("disable-focus-trap",g),Nova.$off("enable-focus-trap",y),h.value=!1}));const b=(0,i.Pj)();async function k(e){!0===e?(n("showing"),document.body.classList.add("overflow-hidden"),Nova.pauseShortcuts(),h.value=!0):(h.value=!1,n("closing"),document.body.classList.remove("overflow-hidden"),Nova.resumeShortcuts()),b.commit("allowLeavingModal")}const w=(0,o.computed)((()=>s()(l,["class"]))),C=(0,o.computed)((()=>({sm:"max-w-sm",md:"max-w-md",lg:"max-w-lg",xl:"max-w-xl","2xl":"max-w-2xl","3xl":"max-w-3xl","4xl":"max-w-4xl","5xl":"max-w-5xl","6xl":"max-w-6xl","7xl":"max-w-7xl"}))),x=(0,o.computed)((()=>{let e="window"===p.modalStyle?C.value:{};return a()([e[p.size]??null,"fullscreen"===p.modalStyle?"h-full":"",l.class])}));return(t,r)=>((0,o.openBlock)(),(0,o.createBlock)(o.Teleport,{to:"body"},[e.show?((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:0},[(0,o.createElementVNode)("div",(0,o.mergeProps)(w.value,{class:["modal fixed inset-0 z-[60]",{"px-3 md:px-0 py-3 md:py-6 overflow-x-hidden overflow-y-auto":"window"===e.modalStyle,"h-full":"fullscreen"===e.modalStyle}],role:e.role,"data-modal-open":e.show,"aria-modal":e.show}),[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["@container/modal relative mx-auto z-20",x.value]),ref:"modalContent"},[(0,o.renderSlot)(t.$slots,"default")],2)],16,u),r[0]||(r[0]=(0,o.createElementVNode)("div",{class:"fixed inset-0 z-[55] bg-gray-500/75 dark:bg-gray-900/75",dusk:"modal-backdrop"},null,-1))],64)):(0,o.createCommentVNode)("",!0)]))}});const h=(0,r(66262).A)(p,[["__file","Modal.vue"]])},23772:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"py-3 px-8"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.renderSlot)(e.$slots,"default")])}],["__file","ModalContent.vue"]])},51434:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"bg-gray-100 dark:bg-gray-700 px-6 py-3 flex"};const l={},a=(0,r(66262).A)(l,[["render",function(e,t){return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.renderSlot)(e.$slots,"default")])}],["__file","ModalFooter.vue"]])},62532:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={},l=(0,r(66262).A)(i,[["render",function(e,t){const r=(0,o.resolveComponent)("Heading");return(0,o.openBlock)(),(0,o.createBlock)(r,{level:3,class:"border-b border-gray-100 dark:border-gray-700 py-4 px-8"},{default:(0,o.withCtx)((()=>[(0,o.renderSlot)(e.$slots,"default")])),_:3})}],["__file","ModalHeader.vue"]])},22308:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726);const i={key:0,class:"ml-auto bg-red-50 text-red-500 py-0.5 px-2 rounded-full text-xs"},l={key:0},a={class:"ml-auto"};var n=r(74640),s=r(35229),c=r(30043);function d(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function u(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const p={components:{Button:n.Button,Icon:n.Icon},emits:["close"],props:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?d(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):d(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({show:{type:Boolean,default:!1}},(0,s.rr)(["resourceName","resourceId"])),data:()=>({loading:!0,title:null,resource:null}),async created(){await this.getResource()},mounted(){Nova.$emit("close-dropdowns")},methods:{getResource(){return this.resource=null,(0,c.minimum)(Nova.request().get(`/nova-api/${this.resourceName}/${this.resourceId}/preview`)).then((({data:{title:e,resource:t}})=>{this.title=e,this.resource=t,this.loading=!1})).catch((e=>{if(e.response.status>=500)Nova.$emit("error",e.response.data.message);else if(404!==e.response.status)if(403!==e.response.status){if(401===e.response.status)return Nova.redirectToLogin();Nova.error(this.__("This resource no longer exists")),Nova.visit(`/resources/${this.resourceName}`)}else Nova.visit("/403");else Nova.visit("/404")}))},componentName:e=>Nova.hasComponent(`preview-${e.component}`)?`preview-${e.component}`:`detail-${e.component}`},computed:{modalTitle(){return`${this.__("Previewing")} ${this.title}`},viewResourceDetailTitle(){return this.__("View :resource",{resource:this.title??""})}}};const h=(0,r(66262).A)(p,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("Icon"),u=(0,o.resolveComponent)("Link"),p=(0,o.resolveComponent)("ModalHeader"),h=(0,o.resolveComponent)("ModalContent"),m=(0,o.resolveComponent)("Button"),f=(0,o.resolveComponent)("ModalFooter"),v=(0,o.resolveComponent)("LoadingView"),g=(0,o.resolveComponent)("Modal");return(0,o.openBlock)(),(0,o.createBlock)(g,{show:r.show,onCloseViaEscape:t[1]||(t[1]=t=>e.$emit("close")),role:"alertdialog",size:"2xl","use-focus-trap":!1},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(v,{loading:e.loading,class:"mx-auto bg-white dark:bg-gray-800 rounded-lg shadow-lg overflow-hidden"},{default:(0,o.withCtx)((()=>[(0,o.renderSlot)(e.$slots,"default",{},(()=>[(0,o.createVNode)(p,{class:"flex items-center"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,[(0,o.createTextVNode)((0,o.toDisplayString)(c.modalTitle)+" ",1),e.resource&&e.resource.softDeleted?((0,o.openBlock)(),(0,o.createElementBlock)("span",i,(0,o.toDisplayString)(e.__("Soft Deleted")),1)):(0,o.createCommentVNode)("",!0)]),(0,o.createVNode)(u,{dusk:"detail-preview-button",href:e.$url(`/resources/${e.resourceName}/${e.resourceId}`),class:"ml-auto",alt:c.viewResourceDetailTitle},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(d,{name:"arrow-right"})])),_:1},8,["href","alt"])])),_:1}),(0,o.createVNode)(h,{class:"px-8 divide-y divide-gray-100 dark:divide-gray-800"},{default:(0,o.withCtx)((()=>[e.resource?((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:0},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.resource.fields,((t,r)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(c.componentName(t)),{key:r,index:r,"resource-name":e.resourceName,"resource-id":e.resourceId,resource:e.resource,field:t},null,8,["index","resource-name","resource-id","resource","field"])))),128)),0==e.resource.fields.length?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,(0,o.toDisplayString)(e.__("There are no fields to display.")),1)):(0,o.createCommentVNode)("",!0)],64)):(0,o.createCommentVNode)("",!0)])),_:1})])),(0,o.createVNode)(f,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",a,[e.resource?((0,o.openBlock)(),(0,o.createBlock)(m,{key:0,dusk:"confirm-preview-button",onClick:t[0]||(t[0]=(0,o.withModifiers)((t=>e.$emit("close")),["prevent"])),label:e.__("Close")},null,8,["label"])):(0,o.createCommentVNode)("",!0)])])),_:1})])),_:3},8,["loading"])])),_:3},8,["show"])}],["__file","PreviewResourceModal.vue"]])},71368:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i={class:"leading-normal"},l={class:"ml-auto"};const a={components:{Button:r(74640).Button},emits:["confirm","close"],props:{show:{type:Boolean,default:!1}},data:()=>({working:!1}),watch:{show(e){!1===e&&(this.working=!1)}},methods:{handleClose(){this.$emit("close"),this.working=!1},handleConfirm(){this.$emit("confirm"),this.working=!0}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("ModalHeader"),d=(0,o.resolveComponent)("ModalContent"),u=(0,o.resolveComponent)("Button"),p=(0,o.resolveComponent)("ModalFooter"),h=(0,o.resolveComponent)("Modal");return(0,o.openBlock)(),(0,o.createBlock)(h,{show:r.show,size:"sm"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("form",{onSubmit:t[0]||(t[0]=(0,o.withModifiers)(((...e)=>s.handleConfirm&&s.handleConfirm(...e)),["prevent"])),class:"bg-white dark:bg-gray-800 rounded-lg shadow-lg overflow-hidden",style:{width:"460px"}},[(0,o.renderSlot)(e.$slots,"default",{},(()=>[(0,o.createVNode)(c,{textContent:(0,o.toDisplayString)(e.__("Restore Resource"))},null,8,["textContent"]),(0,o.createVNode)(d,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("p",i,(0,o.toDisplayString)(e.__("Are you sure you want to restore the selected resources?")),1)])),_:1})])),(0,o.createVNode)(p,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",l,[(0,o.createVNode)(u,{variant:"link",state:"mellow",onClick:(0,o.withModifiers)(s.handleClose,["prevent"]),class:"mr-3",dusk:"cancel-restore-button"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Cancel")),1)])),_:1},8,["onClick"]),(0,o.createVNode)(u,{type:"submit",ref:"confirmButton",dusk:"confirm-restore-button",loading:e.working},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Restore")),1)])),_:1},8,["loading"])])])),_:1})],32)])),_:3},8,["show"])}],["__file","RestoreResourceModal.vue"]])},14197:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726),i=r(74640);const l=["dusk"],a={class:"shrink-0"},n={class:"flex-auto space-y-4"},s={class:"flex items-center"},c={class:"flex-auto"},d={class:"mr-1 text-gray-600 dark:text-gray-400 leading-normal break-words"},u=["title"],p=Object.assign({name:"MessageNotification"},{__name:"MessageNotification",props:{notification:{type:Object,required:!0}},emits:["toggle-mark-as-read","toggle-notifications"],setup(e,{emit:t}){const r=t,p=e,h=(0,o.computed)((()=>p.notification.icon)),m=(0,o.computed)((()=>p.notification.actionUrl));function f(){r("toggle-mark-as-read"),r("toggle-notifications"),function(){if(m.value)Nova.visit(p.notification.actionUrl,{openInNewTab:p.notification.openInNewTab||!1})}()}return(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{class:"relative flex items-start px-4 gap-4",dusk:`notification-${e.notification.id}`},[(0,o.createElementVNode)("div",a,[(0,o.createVNode)((0,o.unref)(i.Icon),{name:h.value,class:(0,o.normalizeClass)(["inline-block",e.notification.iconClass])},null,8,["name","class"])]),(0,o.createElementVNode)("div",n,[(0,o.createElementVNode)("div",null,[(0,o.createElementVNode)("div",s,[(0,o.createElementVNode)("div",c,[(0,o.createElementVNode)("p",d,(0,o.toDisplayString)(e.notification.message),1)])]),(0,o.createElementVNode)("p",{class:"mt-1 text-xs",title:e.notification.created_at},(0,o.toDisplayString)(e.notification.created_at_friendly),9,u)]),m.value?((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(i.Button),{key:0,onClick:f,label:e.notification.actionText,size:"small"},null,8,["label"])):(0,o.createCommentVNode)("",!0)])],8,l))}});const h=(0,r(66262).A)(p,[["__file","MessageNotification.vue"]])},70261:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>N});var o=r(29726);const i={class:"relative"},l=["innerHTML"],a={key:1,class:"absolute border-[3px] border-white dark:border-gray-800 top-0 right-[3px] inline-block bg-primary-500 rounded-full w-4 h-4"},n={key:0,class:"fixed flex inset-0 z-20"},s={class:"relative divide-y divide-gray-200 dark:divide-gray-700 shadow bg-gray-100 dark:bg-gray-800 w-[20rem] ml-auto border-b border-gray-200 dark:border-gray-700 overflow-x-hidden overflow-y-scroll"},c={key:0,class:"bg-white dark:bg-gray-800 flex items-center h-14 px-4"},d={class:"ml-auto"},u={class:"py-1 px-1"},p={key:2,class:"py-12"},h={class:"mt-3 text-center"},m={class:"mt-6 px-4 text-center"};var f=r(66278),v=r(74640);function g(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function y(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?g(Object(r),!0).forEach((function(t){b(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):g(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function b(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const{mapMutations:k,mapActions:w,mapGetters:C}=(0,f.$t)("nova"),x={components:{Button:v.Button},created(){this.fetchNotifications()},watch:{notificationsShown(e){!0!==e?document.body.classList.remove("overflow-y-hidden"):document.body.classList.add("overflow-y-hidden")}},mounted(){Nova.$on("refresh-notifications",(()=>this.fetchNotifications()))},beforeUnmount(){document.body.classList.remove("overflow-y-hidden")},methods:y(y(y({},k(["toggleMainMenu","toggleNotifications"])),w(["fetchNotifications","deleteNotification","deleteAllNotifications","markNotificationAsRead","markAllNotificationsAsRead"])),{},{handleDeleteAllNotifications(){confirm(this.__("Are you sure you want to delete all the notifications?"))&&this.deleteAllNotifications()}}),computed:y(y({},C(["mainMenuShown","notificationsShown","notifications","unreadNotifications"])),{},{shouldShowUnreadCount:()=>Nova.config("showUnreadCountInNotificationCenter")})};const N=(0,r(66262).A)(x,[["render",function(e,t,r,f,v,g){const y=(0,o.resolveComponent)("Button"),b=(0,o.resolveComponent)("Heading"),k=(0,o.resolveComponent)("DropdownMenuItem"),w=(0,o.resolveComponent)("DropdownMenu"),C=(0,o.resolveComponent)("Dropdown"),x=(0,o.resolveComponent)("NotificationList");return(0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,null,[(0,o.createElementVNode)("div",i,[(0,o.createVNode)(y,{variant:"action",icon:"bell",onClick:(0,o.withModifiers)(e.toggleNotifications,["stop"]),dusk:"notifications-dropdown"},{default:(0,o.withCtx)((()=>[e.unreadNotifications?((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:0},[g.shouldShowUnreadCount?((0,o.openBlock)(),(0,o.createElementBlock)("span",{key:0,innerHTML:e.unreadNotifications>99?"99+":e.unreadNotifications,class:"font-black tracking-normal absolute border-[3px] border-white dark:border-gray-800 top-[-5px] left-[15px] inline-flex items-center justify-center bg-primary-500 rounded-full text-white text-xxs p-[0px] px-1 min-w-[26px]"},null,8,l)):((0,o.openBlock)(),(0,o.createElementBlock)("span",a))],64)):(0,o.createCommentVNode)("",!0)])),_:1},8,["onClick"])]),((0,o.openBlock)(),(0,o.createBlock)(o.Teleport,{to:"body"},[(0,o.createVNode)(o.Transition,{"enter-active-class":"transition duration-100 ease-out","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"transition duration-200 ease-in","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:(0,o.withCtx)((()=>[e.notificationsShown?((0,o.openBlock)(),(0,o.createElementBlock)("div",n,[(0,o.createElementVNode)("div",{onClick:t[0]||(t[0]=(...t)=>e.toggleNotifications&&e.toggleNotifications(...t)),class:"absolute inset-0 bg-gray-600/75 dark:bg-gray-900/75",dusk:"notifications-backdrop"}),(0,o.createElementVNode)("div",s,[e.notifications.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("nav",c,[(0,o.createVNode)(b,{level:3,class:"ml-1"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Notifications")),1)])),_:1}),(0,o.createElementVNode)("div",d,[(0,o.createVNode)(C,null,{default:(0,o.withCtx)((()=>[(0,o.createVNode)(y,{dusk:"notification-center-action-dropdown",variant:"ghost",icon:"ellipsis-horizontal"})])),menu:(0,o.withCtx)((()=>[(0,o.createVNode)(w,{width:"200"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",u,[(0,o.createVNode)(k,{as:"button",onClick:e.markAllNotificationsAsRead},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Mark all as Read")),1)])),_:1},8,["onClick"]),(0,o.createVNode)(k,{as:"button",onClick:g.handleDeleteAllNotifications},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Delete all notifications")),1)])),_:1},8,["onClick"])])])),_:1})])),_:1})])])):(0,o.createCommentVNode)("",!0),e.notifications.length>0?((0,o.openBlock)(),(0,o.createBlock)(x,{key:1,notifications:e.notifications},null,8,["notifications"])):((0,o.openBlock)(),(0,o.createElementBlock)("div",p,[t[1]||(t[1]=(0,o.createElementVNode)("p",{class:"text-center"},[(0,o.createElementVNode)("svg",{class:"inline-block text-gray-300 dark:text-gray-500",xmlns:"http://www.w3.org/2000/svg",width:"65",height:"51",viewBox:"0 0 65 51"},[(0,o.createElementVNode)("path",{class:"fill-current",d:"M56 40h2c.552285 0 1 .447715 1 1s-.447715 1-1 1h-2v2c0 .552285-.447715 1-1 1s-1-.447715-1-1v-2h-2c-.552285 0-1-.447715-1-1s.447715-1 1-1h2v-2c0-.552285.447715-1 1-1s1 .447715 1 1v2zm-5.364125-8H38v8h7.049375c.350333-3.528515 2.534789-6.517471 5.5865-8zm-5.5865 10H6c-3.313708 0-6-2.686292-6-6V6c0-3.313708 2.686292-6 6-6h44c3.313708 0 6 2.686292 6 6v25.049375C61.053323 31.5511 65 35.814652 65 41c0 5.522847-4.477153 10-10 10-5.185348 0-9.4489-3.946677-9.950625-9zM20 30h16v-8H20v8zm0 2v8h16v-8H20zm34-2v-8H38v8h16zM2 30h16v-8H2v8zm0 2v4c0 2.209139 1.790861 4 4 4h12v-8H2zm18-12h16v-8H20v8zm34 0v-8H38v8h16zM2 20h16v-8H2v8zm52-10V6c0-2.209139-1.790861-4-4-4H6C3.790861 2 2 3.790861 2 6v4h52zm1 39c4.418278 0 8-3.581722 8-8s-3.581722-8-8-8-8 3.581722-8 8 3.581722 8 8 8z"})])],-1)),(0,o.createElementVNode)("p",h,(0,o.toDisplayString)(e.__("There are no new notifications.")),1),(0,o.createElementVNode)("p",m,[(0,o.createVNode)(y,{variant:"solid",onClick:e.toggleNotifications,label:e.__("Close")},null,8,["onClick","label"])])]))])])):(0,o.createCommentVNode)("",!0)])),_:1})]))],64)}],["__file","NotificationCenter.vue"]])},15001:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726),i=r(74640),l=r(66278);const a={class:"divide-y divide-gray-200 dark:divide-gray-600",dusk:"notifications-content"},n={class:"relative bg-white dark:bg-gray-800 transition transition-colors flex flex-col gap-2 pt-4 pb-2"},s={key:0,class:"absolute rounded-full top-[20px] right-[16px] bg-primary-500 w-[5px] h-[5px]"},c={class:"ml-12"},d={class:"flex items-start"},u={__name:"NotificationList",props:{notifications:{type:Array}},setup(e){const t=(0,l.Pj)();function r(e){e.read_at?t.dispatch("nova/markNotificationAsUnread",e.id):t.dispatch("nova/markNotificationAsRead",e.id)}function u(e){t.dispatch("nova/deleteNotification",e.id)}return(l,p)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",a,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.notifications,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:e.id,class:"dark:border-gray-600"},[(0,o.createElementVNode)("div",n,[e.read_at?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createElementBlock)("span",s)),((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(e.component||"MessageNotification"),{notification:e,onDeleteNotification:t=>u(e),onToggleNotifications:p[0]||(p[0]=e=>(0,o.unref)(t).commit("nova/toggleNotifications")),onToggleMarkAsRead:t=>r(e)},null,40,["notification","onDeleteNotification","onToggleMarkAsRead"])),(0,o.createElementVNode)("div",c,[(0,o.createElementVNode)("div",d,[(0,o.createVNode)((0,o.unref)(i.Button),{onClick:t=>r(e),dusk:"mark-as-read-button",variant:"link",state:"mellow",size:"small",label:e.read_at?l.__("Mark Unread"):l.__("Mark Read")},null,8,["onClick","label"]),(0,o.createVNode)((0,o.unref)(i.Button),{onClick:t=>u(e),dusk:"delete-button",variant:"link",state:"mellow",size:"small",label:l.__("Delete")},null,8,["onClick","label"])])])])])))),128))]))}};const p=(0,r(66262).A)(u,[["__file","NotificationList.vue"]])},84661:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i={class:"rounded-b-lg font-bold flex items-center"},l={class:"flex text-sm"},a=["disabled"],n=["disabled"],s=["disabled","onClick","dusk"],c=["disabled"],d=["disabled"];const u={emits:["page"],props:{page:{type:Number,required:!0},pages:{type:Number,default:0},next:{type:Boolean,default:!1},previous:{type:Boolean,default:!1}},data:()=>({linksDisabled:!1}),mounted(){Nova.$on("resources-loaded",this.listenToResourcesLoaded)},beforeUnmount(){Nova.$off("resources-loaded",this.listenToResourcesLoaded)},methods:{selectPage(e){this.page!=e&&(this.linksDisabled=!0,this.$emit("page",e))},selectPreviousPage(){this.selectPage(this.page-1)},selectNextPage(){this.selectPage(this.page+1)},listenToResourcesLoaded(){this.linksDisabled=!1}},computed:{hasPreviousPages:function(){return this.page>1},hasMorePages:function(){return this.page<this.pages},printPages(){const e=Math.min(Math.max(3,this.page),this.pages-2),t=Math.max(e-2,1),r=Math.min(e+2,this.pages);let o=[];for(let e=t;e<=r;++e)e>0&&o.push(e);return o}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,u,p,h){return(0,o.openBlock)(),(0,o.createElementBlock)("nav",i,[(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("button",{disabled:!h.hasPreviousPages||e.linksDisabled,class:(0,o.normalizeClass)(["border-r border-gray-200 dark:border-gray-700 text-xl h-9 min-w-9 px-2 rounded-bl-lg focus:outline-none focus:bg-gray-50 hover:bg-gray-50 dark:hover:bg-gray-700",{"text-gray-500":h.hasPreviousPages,"text-gray-500":!h.hasPreviousPages||e.linksDisabled}]),rel:"first",onClick:t[0]||(t[0]=(0,o.withModifiers)((e=>h.selectPage(1)),["prevent"])),dusk:"first"}," « ",10,a),(0,o.createElementVNode)("button",{disabled:!h.hasPreviousPages||e.linksDisabled,class:(0,o.normalizeClass)(["border-r border-gray-200 dark:border-gray-700 text-xl h-9 min-w-9 px-2 focus:outline-none focus:bg-gray-50 hover:bg-gray-50 dark:hover:bg-gray-700",{"text-gray-500":h.hasPreviousPages,"text-gray-500":!h.hasPreviousPages||e.linksDisabled}]),rel:"prev",onClick:t[1]||(t[1]=(0,o.withModifiers)((e=>h.selectPreviousPage()),["prevent"])),dusk:"previous"}," ",10,n),((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(h.printPages,(t=>((0,o.openBlock)(),(0,o.createElementBlock)("button",{disabled:e.linksDisabled,key:t,class:(0,o.normalizeClass)(["border-r border-gray-200 dark:border-gray-700 h-9 min-w-9 px-2 focus:outline-none focus:bg-gray-50 hover:bg-gray-50 dark:hover:bg-gray-700",{"text-gray-500":r.page!==t,"text-gray-500 bg-gray-50 dark:bg-gray-700":r.page===t}]),onClick:(0,o.withModifiers)((e=>h.selectPage(t)),["prevent"]),dusk:`page:${t}`},(0,o.toDisplayString)(t),11,s)))),128)),(0,o.createElementVNode)("button",{disabled:!h.hasMorePages||e.linksDisabled,class:(0,o.normalizeClass)(["border-r border-gray-200 dark:border-gray-700 text-xl h-9 min-w-9 px-2 focus:outline-none focus:bg-gray-50 hover:bg-gray-50 dark:hover:bg-gray-700",{"text-gray-500":h.hasMorePages,"text-gray-500":!h.hasMorePages||e.linksDisabled}]),rel:"next",onClick:t[2]||(t[2]=(0,o.withModifiers)((e=>h.selectNextPage()),["prevent"])),dusk:"next"}," ",10,c),(0,o.createElementVNode)("button",{disabled:!h.hasMorePages||e.linksDisabled,class:(0,o.normalizeClass)(["border-r border-gray-200 dark:border-gray-700 text-xl h-9 min-w-9 px-2 focus:outline-none focus:bg-gray-50 hover:bg-gray-50 dark:hover:bg-gray-700",{"text-gray-500":h.hasMorePages,"text-gray-500":!h.hasMorePages||e.linksDisabled}]),rel:"last",onClick:t[3]||(t[3]=(0,o.withModifiers)((e=>h.selectPage(r.pages)),["prevent"])),dusk:"last"}," » ",10,d)]),(0,o.renderSlot)(e.$slots,"default")])}],["__file","PaginationLinks.vue"]])},55623:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={class:"bg-20 h-9 px-3 text-center rounded-b-lg flex items-center justify-between"},l={class:"leading-normal text-sm text-gray-500"},a={key:0,class:"leading-normal text-sm"},n={class:"leading-normal text-sm text-gray-500"};const s={emits:["load-more"],props:{currentResourceCount:{type:Number,required:!0},allMatchingResourceCount:{type:Number,required:!0},resourceCountLabel:{type:String,required:!0},perPage:{type:[Number,String],required:!0},page:{type:Number,required:!0},pages:{type:Number,default:0},next:{type:Boolean,default:!1},previous:{type:Boolean,default:!1}},methods:{loadMore(){this.$emit("load-more")}},computed:{buttonLabel(){return this.__("Load :perPage More",{perPage:Nova.formatNumber(this.perPage)})},allResourcesLoaded(){return this.currentResourceCount==this.allMatchingResourceCount},resourceTotalCountLabel(){return Nova.formatNumber(this.allMatchingResourceCount)}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,s,c,d){return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("p",l,(0,o.toDisplayString)(r.resourceCountLabel),1),d.allResourcesLoaded?((0,o.openBlock)(),(0,o.createElementBlock)("p",a,(0,o.toDisplayString)(e.__("All resources loaded.")),1)):((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:1,onClick:t[0]||(t[0]=(...e)=>d.loadMore&&d.loadMore(...e)),class:"h-9 focus:outline-none focus:ring ring-inset rounded-lg px-4 font-bold text-primary-500 hover:text-primary-600 active:text-primary-400"},(0,o.toDisplayString)(d.buttonLabel),1)),(0,o.createElementVNode)("p",n,(0,o.toDisplayString)(e.__(":amount Total",{amount:d.resourceTotalCountLabel})),1)])}],["__file","PaginationLoadMore.vue"]])},9320:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={class:"rounded-b-lg"},l={class:"flex justify-between items-center"},a=["disabled"],n=["disabled"];const s={emits:["page"],props:{currentResourceCount:{type:Number,required:!0},allMatchingResourceCount:{type:Number,required:!0},resourceCountLabel:{type:[Number,String],required:!0},page:{type:Number,required:!0},pages:{type:Number,default:0},next:{type:Boolean,default:!1},previous:{type:Boolean,default:!1}},data:()=>({linksDisabled:!1}),mounted(){Nova.$on("resources-loaded",this.listenToResourcesLoaded)},beforeUnmount(){Nova.$off("resources-loaded",this.listenToResourcesLoaded)},methods:{selectPreviousPage(){this.selectPage(this.page-1)},selectNextPage(){this.selectPage(this.page+1)},selectPage(e){this.linksDisabled=!0,this.$emit("page",e)},listenToResourcesLoaded(){this.linksDisabled=!1}},computed:{hasPreviousPages:function(){return this.previous},hasMorePages:function(){return this.next}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,s,c,d){return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("nav",l,[(0,o.createElementVNode)("button",{disabled:!d.hasPreviousPages||e.linksDisabled,class:(0,o.normalizeClass)(["text-xs font-bold py-3 px-4 focus:outline-none rounded-bl-lg focus:ring focus:ring-inset",{"text-primary-500 hover:text-primary-400 active:text-primary-600":d.hasPreviousPages,"text-gray-300 dark:text-gray-600":!d.hasPreviousPages||e.linksDisabled}]),rel:"prev",onClick:t[0]||(t[0]=(0,o.withModifiers)(((...e)=>d.selectPreviousPage&&d.selectPreviousPage(...e)),["prevent"])),dusk:"previous"},(0,o.toDisplayString)(e.__("Previous")),11,a),(0,o.renderSlot)(e.$slots,"default"),(0,o.createElementVNode)("button",{disabled:!d.hasMorePages||e.linksDisabled,class:(0,o.normalizeClass)(["text-xs font-bold py-3 px-4 focus:outline-none rounded-br-lg focus:ring focus:ring-inset",{"text-primary-500 hover:text-primary-400 active:text-primary-600":d.hasMorePages,"text-gray-300 dark:text-gray-600":!d.hasMorePages||e.linksDisabled}]),rel:"next",onClick:t[1]||(t[1]=(0,o.withModifiers)(((...e)=>d.selectNextPage&&d.selectNextPage(...e)),["prevent"])),dusk:"next"},(0,o.toDisplayString)(e.__("Next")),11,n)])])}],["__file","PaginationSimple.vue"]])},75268:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"border-t border-gray-200 dark:border-gray-700"};const l={props:["paginationComponent","hasNextPage","hasPreviousPage","loadMore","selectPage","totalPages","currentPage","perPage","resourceCountLabel","currentResourceCount","allMatchingResourceCount"]};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(r.paginationComponent),{next:r.hasNextPage,previous:r.hasPreviousPage,onLoadMore:r.loadMore,onPage:r.selectPage,pages:r.totalPages,page:r.currentPage,"per-page":r.perPage,"resource-count-label":r.resourceCountLabel,"current-resource-count":r.currentResourceCount,"all-matching-resource-count":r.allMatchingResourceCount},{default:(0,o.withCtx)((()=>[r.resourceCountLabel?((0,o.openBlock)(),(0,o.createElementBlock)("span",{key:0,class:(0,o.normalizeClass)(["text-xs px-4",{"ml-auto hidden md:inline":"pagination-links"===r.paginationComponent}])},(0,o.toDisplayString)(r.resourceCountLabel),3)):(0,o.createCommentVNode)("",!0)])),_:1},40,["next","previous","onLoadMore","onPage","pages","page","per-page","resource-count-label","current-resource-count","all-matching-resource-count"]))])}],["__file","ResourcePagination.vue"]])},57228:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i=["dusk"],l={class:(0,o.normalizeClass)(["md:w-1/4 @sm/peekable:w-1/4 @md/modal:w-1/4","md:py-3 @sm/peekable:py-3 @md/modal:py-3"])},a={class:"font-normal @sm/peekable:break-all"},n={key:1,class:"flex items-center"},s=["innerHTML"],c={key:3};var d=r(35229);const u={mixins:[d.nl,d.S0],props:{index:{type:Number,required:!0},field:{type:Object,required:!0},fieldName:{type:String,default:""}},methods:{copy(){this.copyValueToClipboard(this.field.value)}},computed:{label(){return this.fieldName||this.field.name}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,d,u,p){const h=(0,o.resolveComponent)("CopyButton"),m=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(["flex flex-col -mx-6 px-6 py-2 space-y-2",["md:flex-row @sm/peekable:flex-row @md/modal:flex-row","md:py-0 @sm/peekable:py-0 @md/modal:py-0","md:space-y-0 @sm/peekable:space-y-0 @md/modal:space-y-0"]]),dusk:r.field.attribute},[(0,o.createElementVNode)("div",l,[(0,o.renderSlot)(e.$slots,"default",{},(()=>[(0,o.createElementVNode)("h4",a,[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(p.label),1)])]))]),(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["break-all",["md:w-3/4 @sm/peekable:w-3/4 @md/modal:w-3/4","md:py-3 @sm/peekable:py-3 md/modal:py-3","lg:break-words @md/peekable:break-words @lg/modal:break-words"]])},[(0,o.renderSlot)(e.$slots,"value",{},(()=>[e.fieldValue&&r.field.copyable&&!e.shouldDisplayAsHtml?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(h,{key:0,onClick:(0,o.withModifiers)(p.copy,["prevent","stop"])},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",{ref:"theFieldValue"},(0,o.toDisplayString)(e.fieldValue),513)])),_:1},8,["onClick"])),[[m,e.__("Copy to clipboard")]]):!e.fieldValue||r.field.copyable||e.shouldDisplayAsHtml?e.fieldValue&&!r.field.copyable&&e.shouldDisplayAsHtml?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:2,innerHTML:e.fieldValue},null,8,s)):((0,o.openBlock)(),(0,o.createElementBlock)("p",c,"—")):((0,o.openBlock)(),(0,o.createElementBlock)("p",n,(0,o.toDisplayString)(e.fieldValue),1))]))])],8,i)}],["__file","PanelItem.vue"]])},29627:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["logo"],inheritAttrs:!1,render(){let e=document.createDocumentFragment(),t=document.createElement("span");t.innerHTML=this.$props.logo,e.appendChild(t);const r=this.$attrs.class.split(" ").filter(String);return e.querySelector("svg").classList.add(...r),(0,o.h)("span",{innerHTML:t.innerHTML})}};const l=(0,r(66262).A)(i,[["__file","PassthroughLogo.vue"]])},5112:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i=["title"],l={__name:"ProgressBar",props:{title:{type:String,required:!0},color:{type:String,required:!0},value:{type:[String,Number],required:!0}},setup:e=>(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{class:"bg-gray-200 dark:bg-gray-900 w-full overflow-hidden h-4 flex rounded-full",title:e.title},[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(e.color),style:(0,o.normalizeStyle)(`width:${e.value}%`)},null,6)],8,i))};const a=(0,r(66262).A)(l,[["__file","ProgressBar.vue"]])},84227:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726),i=r(58059),l=r.n(i),a=r(30043);const n={class:"bg-white dark:bg-gray-900 text-gray-500 dark:text-gray-400"},s={key:0,class:"p-3"},c={key:1,class:"min-w-[24rem] max-w-2xl"},d={key:0,class:"@container/peekable divide-y divide-gray-100 dark:divide-gray-800 rounded-lg py-1"},u={key:1,class:"p-3 text-center dark:text-gray-400"},p={__name:"RelationPeek",props:["resource","resourceName","resourceId"],setup(e){const t=(0,o.ref)(!0),r=(0,o.ref)(null),i=l()((()=>async function(){t.value=!0;try{const{data:{resource:{fields:e}}}=await(0,a.minimum)(Nova.request().get(`/nova-api/${p.resourceName}/${p.resourceId}/peek`),500);r.value=e}catch(e){Nova.debug(e,"error")}finally{t.value=!1}}())),p=e;return(l,a)=>{const p=(0,o.resolveComponent)("Loader"),h=(0,o.resolveComponent)("Tooltip");return(0,o.openBlock)(),(0,o.createBlock)(h,{triggers:["hover"],popperTriggers:["hover"],placement:"top-start",theme:"plain",onTooltipShow:(0,o.unref)(i),"show-group":`${e.resourceName}-${e.resourceId}-peek`,"auto-hide":!0},{default:(0,o.withCtx)((()=>[(0,o.renderSlot)(l.$slots,"default")])),content:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",n,[t.value?((0,o.openBlock)(),(0,o.createElementBlock)("div",s,[(0,o.createVNode)(p,{width:"30"})])):((0,o.openBlock)(),(0,o.createElementBlock)("div",c,[r.value.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",d,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.value,((t,r)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(`detail-${t.component}`),{class:"mx-0",key:r,index:r,"resource-name":e.resourceName,"resource-id":e.resourceId,field:t},null,8,["index","resource-name","resource-id","field"])))),128))])):((0,o.openBlock)(),(0,o.createElementBlock)("p",u,(0,o.toDisplayString)(l.__("There's nothing configured to show here.")),1))]))])])),_:3},8,["onTooltipShow","show-group"])}}};const h=(0,r(66262).A)(p,[["__file","RelationPeek.vue"]])},34324:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726),i=r(74640),l=r(65835),a=r(44377),n=r.n(a);const s={class:"bg-white dark:bg-gray-800 border border-gray-200 dark:border-gray-700 rounded divide-y divide-gray-200 dark:divide-gray-700"},c={class:"flex items-center bg-gray-50 dark:bg-gray-800 py-2 px-3 rounded-t"},d={class:"flex items-center space-x-2"},u={class:"grid grid-cols-full divide-y divide-gray-100 dark:divide-gray-700"},p={__name:"RepeaterRow",props:{field:{type:Object,required:!0},index:{type:Number,required:!0},item:{type:Object,required:!0},errors:{type:Object,required:!0},sortable:{type:Boolean,required:!1},viaParent:{type:String}},emits:["click","move-up","move-down","file-deleted"],setup(e,{emit:t}){const r=e,a=t,{__:p}=(0,l.B)();(0,o.provide)("viaParent",(0,o.computed)((()=>r.viaParent))),(0,o.provide)("index",(0,o.computed)((()=>r.index)));const h=r.item.fields.map((e=>e.attribute)),m=n()(h.map((e=>[`fields.${e}`,(0,o.ref)(null)]))),f=(0,o.inject)("resourceName"),v=(0,o.inject)("resourceId"),g=(0,o.inject)("shownViaNewRelationModal"),y=(0,o.inject)("viaResource"),b=(0,o.inject)("viaResourceId"),k=(0,o.inject)("viaRelationship"),w=()=>r.item.confirmBeforeRemoval?confirm(p("Are you sure you want to remove this item?"))?C():null:C(),C=()=>{Object.keys(m).forEach((async e=>{})),a("click",r.index)};return(t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",s,[(0,o.createElementVNode)("div",c,[(0,o.createElementVNode)("div",d,[e.sortable?((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(i.Button),{key:0,as:"div",size:"small",icon:"arrow-up",variant:"ghost",padding:"tight",onClick:r[0]||(r[0]=r=>t.$emit("move-up",e.index)),dusk:"row-move-up-button"})):(0,o.createCommentVNode)("",!0),e.sortable?((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(i.Button),{key:1,as:"div",size:"small",icon:"arrow-down",variant:"ghost",padding:"tight",onClick:r[1]||(r[1]=r=>t.$emit("move-down",e.index)),dusk:"row-move-down-button"})):(0,o.createCommentVNode)("",!0)]),(0,o.createVNode)((0,o.unref)(i.Button),{as:"div",size:"small",icon:"trash",variant:"ghost",padding:"tight",onClick:(0,o.withModifiers)(w,["stop","prevent"]),dusk:"row-delete-button",class:"ml-auto"})]),(0,o.createElementVNode)("div",u,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.item.fields,((i,l)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:i.uniqueKey},[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)("form-"+i.component),{ref_for:!0,ref:(0,o.unref)(m)[`fields.${i.attribute}`],field:i,index:l,errors:e.errors,"show-help-text":!0,onFileDeleted:r[2]||(r[2]=e=>t.$emit("file-deleted")),nested:!0,"resource-name":(0,o.unref)(f),"resource-id":(0,o.unref)(v),"shown-via-new-relation-modal":(0,o.unref)(g),"via-resource":(0,o.unref)(y),"via-resource-id":(0,o.unref)(b),"via-relationship":(0,o.unref)(k)},null,40,["field","index","errors","resource-name","resource-id","shown-via-new-relation-modal","via-resource","via-resource-id","via-relationship"]))])))),128))])]))}};const h=(0,r(66262).A)(p,[["__file","RepeaterRow.vue"]])},55293:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={class:"overflow-hidden overflow-x-auto relative"},l={key:0,class:"w-full divide-y divide-gray-100 dark:divide-gray-700",dusk:"resource-table"},a={class:"divide-y divide-gray-100 dark:divide-gray-700"};const n={emits:["actionExecuted","delete","restore","order","reset-order-by"],mixins:[r(35229).Ye],props:{authorizedToRelate:{type:Boolean,required:!0},resourceName:{default:null},resources:{default:[]},singularName:{type:String,required:!0},selectedResources:{default:[]},selectedResourceIds:{},shouldShowCheckboxes:{type:Boolean,default:!1},actionsAreAvailable:{type:Boolean,default:!1},viaResource:{default:null},viaResourceId:{default:null},viaRelationship:{default:null},relationshipType:{default:null},updateSelectionStatus:{type:Function},actionsEndpoint:{default:null},sortable:{type:Boolean,default:!1}},data:()=>({selectAllResources:!1,selectAllMatching:!1,resourceCount:null}),methods:{deleteResource(e){this.$emit("delete",[e])},restoreResource(e){this.$emit("restore",[e])},requestOrderByChange(e){this.$emit("order",e)},resetOrderBy(e){this.$emit("reset-order-by",e)}},computed:{fields(){if(this.resources)return this.resources[0].fields},viaManyToMany(){return"belongsToMany"==this.relationshipType||"morphToMany"==this.relationshipType},shouldShowColumnBorders(){return this.resourceInformation.showColumnBorders},tableStyle(){return this.resourceInformation.tableStyle},clickAction(){return this.resourceInformation.clickAction}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("ResourceTableHeader"),u=(0,o.resolveComponent)("ResourceTableRow");return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[r.resources.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("table",l,[(0,o.createVNode)(d,{"resource-name":r.resourceName,fields:c.fields,"should-show-column-borders":c.shouldShowColumnBorders,"should-show-checkboxes":r.shouldShowCheckboxes,sortable:r.sortable,onOrder:c.requestOrderByChange,onResetOrderBy:c.resetOrderBy},null,8,["resource-name","fields","should-show-column-borders","should-show-checkboxes","sortable","onOrder","onResetOrderBy"]),(0,o.createElementVNode)("tbody",a,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.resources,((i,l)=>((0,o.openBlock)(),(0,o.createBlock)(u,{onActionExecuted:t[0]||(t[0]=t=>e.$emit("actionExecuted")),"actions-are-available":r.actionsAreAvailable,"actions-endpoint":r.actionsEndpoint,checked:r.selectedResources.indexOf(i)>-1,"click-action":c.clickAction,"delete-resource":c.deleteResource,key:`${i.id.value}-items-${l}`,"relationship-type":r.relationshipType,"resource-name":r.resourceName,resource:i,"restore-resource":c.restoreResource,"selected-resources":r.selectedResources,"should-show-checkboxes":r.shouldShowCheckboxes,"should-show-column-borders":c.shouldShowColumnBorders,"table-style":c.tableStyle,testId:`${r.resourceName}-items-${l}`,"update-selection-status":r.updateSelectionStatus,"via-many-to-many":c.viaManyToMany,"via-relationship":r.viaRelationship,"via-resource-id":r.viaResourceId,"via-resource":r.viaResource},null,8,["actions-are-available","actions-endpoint","checked","click-action","delete-resource","relationship-type","resource-name","resource","restore-resource","selected-resources","should-show-checkboxes","should-show-column-borders","table-style","testId","update-selection-status","via-many-to-many","via-relationship","via-resource-id","via-resource"])))),128))])])):(0,o.createCommentVNode)("",!0)])}],["__file","ResourceTable.vue"]])},50101:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>d});var o=r(29726);const i={class:"bg-gray-50 dark:bg-gray-800"},l={class:"sr-only"},a={key:1},n={class:"uppercase text-xxs tracking-wide px-2 py-2"},s={class:"sr-only"};const c={name:"ResourceTableHeader",emits:["order","reset-order-by"],props:{resourceName:String,shouldShowColumnBorders:Boolean,shouldShowCheckboxes:Boolean,fields:{type:[Object,Array]},sortable:Boolean},data:()=>({initializingWithShowCheckboxes:!1}),beforeMount(){this.initializingWithShowCheckboxes=this.shouldShowCheckboxes},methods:{requestOrderByChange(e){this.$emit("order",e)},resetOrderBy(e){this.$emit("reset-order-by",e)}}};const d=(0,r(66262).A)(c,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("SortableIcon");return(0,o.openBlock)(),(0,o.createElementBlock)("thead",i,[(0,o.createElementVNode)("tr",null,[e.initializingWithShowCheckboxes?((0,o.openBlock)(),(0,o.createElementBlock)("th",{key:0,class:(0,o.normalizeClass)(["w-[1%] white-space-nowrap uppercase bg-gray-50 dark:bg-gray-800 text-xxs text-gray-500 tracking-wide pl-5 pr-2 py-2",{"border-r border-gray-200 dark:border-gray-600":r.shouldShowColumnBorders}])},[(0,o.createElementVNode)("span",l,(0,o.toDisplayString)(e.__("Selected Resources")),1)],2)):(0,o.createCommentVNode)("",!0),((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.fields,((e,t)=>((0,o.openBlock)(),(0,o.createElementBlock)("th",{key:e.uniqueKey,class:(0,o.normalizeClass)(["uppercase text-gray-500 text-xxs tracking-wide py-2",{[`text-${e.textAlign}`]:!0,"border-r border-gray-200 dark:border-gray-600":r.shouldShowColumnBorders,"px-6":0==t&&!r.shouldShowCheckboxes,"px-2":0!=t||r.shouldShowCheckboxes,"whitespace-nowrap":!e.wrapping}])},[r.sortable&&e.sortable?((0,o.openBlock)(),(0,o.createBlock)(p,{key:0,onSort:t=>u.requestOrderByChange(e),onReset:t=>u.resetOrderBy(e),"resource-name":r.resourceName,"uri-key":e.sortableUriKey},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.indexName),1)])),_:2},1032,["onSort","onReset","resource-name","uri-key"])):((0,o.openBlock)(),(0,o.createElementBlock)("span",a,(0,o.toDisplayString)(e.indexName),1))],2)))),128)),(0,o.createElementVNode)("th",n,[(0,o.createElementVNode)("span",s,(0,o.toDisplayString)(e.__("Controls")),1)])])])}],["__file","ResourceTableHeader.vue"]])},79344:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>v});var o=r(29726);const i=["data-pivot-id","dusk"],l={class:"flex items-center justify-end space-x-0 text-gray-400"},a={class:"flex items-center gap-1"},n={class:"flex items-center gap-1"},s={class:"leading-normal"};var c=r(59977),d=r(66278),u=r(74640);function p(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function h(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?p(Object(r),!0).forEach((function(t){m(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):p(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function m(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const f={components:{Button:u.Button,Checkbox:u.Checkbox,Icon:u.Icon},emits:["actionExecuted"],inject:["resourceHasId","authorizedToViewAnyResources","authorizedToUpdateAnyResources","authorizedToDeleteAnyResources","authorizedToRestoreAnyResources"],props:["actionsAreAvailable","actionsEndpoint","checked","clickAction","deleteResource","queryString","relationshipType","resource","resourceName","resourcesSelected","restoreResource","selectedResources","shouldShowCheckboxes","shouldShowColumnBorders","tableStyle","testId","updateSelectionStatus","viaManyToMany","viaRelationship","viaResource","viaResourceId"],data:()=>({commandPressed:!1,deleteModalOpen:!1,restoreModalOpen:!1,previewModalOpen:!1,initializingWithShowCheckboxes:!1}),beforeMount(){this.initializingWithShowCheckboxes=this.shouldShowCheckboxes,this.isSelected=this.selectedResources.indexOf(this.resource)>-1},mounted(){window.addEventListener("keydown",this.handleKeydown),window.addEventListener("keyup",this.handleKeyup)},beforeUnmount(){window.removeEventListener("keydown",this.handleKeydown),window.removeEventListener("keyup",this.handleKeyup)},methods:{toggleSelection(){this.updateSelectionStatus(this.resource)},handleKeydown(e){"Meta"!==e.key&&"Control"!==e.key||(this.commandPressed=!0)},handleKeyup(e){"Meta"!==e.key&&"Control"!==e.key||(this.commandPressed=!1)},handleClick(e){return!1===this.resourceHasId?void 0:"edit"===this.clickAction?this.navigateToEditView(e):"select"===this.clickAction?this.toggleSelection():"ignore"===this.clickAction?void 0:"detail"===this.clickAction?this.navigateToDetailView(e):"preview"===this.clickAction?this.navigateToPreviewView(e):this.navigateToDetailView(e)},navigateToDetailView(e){this.resource.authorizedToView&&(this.commandPressed?window.open(this.viewURL,"_blank"):c.QB.visit(this.viewURL))},navigateToEditView(e){this.resource.authorizedToUpdate&&(this.commandPressed?window.open(this.updateURL,"_blank"):c.QB.visit(this.updateURL))},navigateToPreviewView(e){this.resource.authorizedToView&&this.openPreviewModal()},openPreviewModal(){this.previewModalOpen=!0},closePreviewModal(){this.previewModalOpen=!1},openDeleteModal(){this.deleteModalOpen=!0},confirmDelete(){this.deleteResource(this.resource),this.closeDeleteModal()},closeDeleteModal(){this.deleteModalOpen=!1},openRestoreModal(){this.restoreModalOpen=!0},confirmRestore(){this.restoreResource(this.resource),this.closeRestoreModal()},closeRestoreModal(){this.restoreModalOpen=!1}},computed:h(h({},(0,d.L8)(["currentUser"])),{},{updateURL(){return this.viaManyToMany?this.$url(`/resources/${this.viaResource}/${this.viaResourceId}/edit-attached/${this.resourceName}/${this.resource.id.value}`,{viaRelationship:this.viaRelationship,viaPivotId:this.resource.id.pivotValue}):this.$url(`/resources/${this.resourceName}/${this.resource.id.value}/edit`,{viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship})},viewURL(){return this.$url(`/resources/${this.resourceName}/${this.resource.id.value}`)},availableActions(){return this.resource.actions.filter((e=>e.showOnTableRow))},shouldShowTight(){return"tight"===this.tableStyle},clickableRow(){return!1!==this.resourceHasId&&("edit"===this.clickAction?this.resource.authorizedToUpdate:"select"===this.clickAction?this.shouldShowCheckboxes:"ignore"!==this.clickAction&&("detail"===this.clickAction||this.clickAction,this.resource.authorizedToView))},shouldShowActionDropdown(){return this.availableActions.length>0||this.userHasAnyOptions},shouldShowPreviewLink(){return this.resource.authorizedToView&&this.resource.previewHasFields},userHasAnyOptions(){return this.resourceHasId&&(this.resource.authorizedToReplicate||this.shouldShowPreviewLink||this.canBeImpersonated)},canBeImpersonated(){return this.currentUser.canImpersonate&&this.resource.authorizedToImpersonate}})};const v=(0,r(66262).A)(f,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("Checkbox"),h=(0,o.resolveComponent)("InlineActionDropdown"),m=(0,o.resolveComponent)("Icon"),f=(0,o.resolveComponent)("Link"),v=(0,o.resolveComponent)("Button"),g=(0,o.resolveComponent)("DeleteResourceModal"),y=(0,o.resolveComponent)("ModalHeader"),b=(0,o.resolveComponent)("ModalContent"),k=(0,o.resolveComponent)("RestoreResourceModal"),w=(0,o.resolveComponent)("PreviewResourceModal"),C=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,null,[(0,o.createElementVNode)("tr",{"data-pivot-id":r.resource.id.pivotValue,onClick:t[4]||(t[4]=(0,o.withModifiers)(((...e)=>u.handleClick&&u.handleClick(...e)),["stop","prevent"])),class:(0,o.normalizeClass)(["group",{"divide-x divide-gray-100 dark:divide-gray-700":r.shouldShowColumnBorders}]),dusk:`${r.resource.id.value}-row`},[e.initializingWithShowCheckboxes?((0,o.openBlock)(),(0,o.createElementBlock)("td",{key:0,onClick:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),class:(0,o.normalizeClass)(["w-[1%] white-space-nowrap pl-5 pr-5 dark:bg-gray-800 group-hover:bg-gray-50 dark:group-hover:bg-gray-900",{"py-2":!u.shouldShowTight,"cursor-pointer":r.resource.authorizedToView}])},[r.shouldShowCheckboxes?((0,o.openBlock)(),(0,o.createBlock)(p,{key:0,"model-value":r.checked,onChange:u.toggleSelection,dusk:`${r.resource.id.value}-checkbox`,"aria-label":e.__("Select Resource :title",{title:r.resource.title})},null,8,["model-value","onChange","dusk","aria-label"])):(0,o.createCommentVNode)("",!0)],2)):(0,o.createCommentVNode)("",!0),((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.resource.fields,((e,t)=>((0,o.openBlock)(),(0,o.createElementBlock)("td",{key:e.uniqueKey,class:(0,o.normalizeClass)(["dark:bg-gray-800 group-hover:bg-gray-50 dark:group-hover:bg-gray-900",{"px-6":0===t&&!r.shouldShowCheckboxes,"px-2":0!==t||r.shouldShowCheckboxes,"py-2":!u.shouldShowTight,"whitespace-nowrap":!e.wrapping,"cursor-pointer":u.clickableRow}])},[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)("index-"+e.component),{class:(0,o.normalizeClass)(`text-${e.textAlign}`),field:e,resource:r.resource,"resource-name":r.resourceName,"via-resource":r.viaResource,"via-resource-id":r.viaResourceId},null,8,["class","field","resource","resource-name","via-resource","via-resource-id"]))],2)))),128)),(0,o.createElementVNode)("td",{class:(0,o.normalizeClass)([{"py-2":!u.shouldShowTight,"cursor-pointer":r.resource.authorizedToView},"px-2 w-[1%] white-space-nowrap text-right align-middle dark:bg-gray-800 group-hover:bg-gray-50 dark:group-hover:bg-gray-900"])},[(0,o.createElementVNode)("div",l,[u.shouldShowActionDropdown?((0,o.openBlock)(),(0,o.createBlock)(h,{key:0,actions:u.availableActions,endpoint:r.actionsEndpoint,resource:r.resource,"resource-name":r.resourceName,"via-many-to-many":r.viaManyToMany,"via-resource":r.viaResource,"via-resource-id":r.viaResourceId,"via-relationship":r.viaRelationship,onActionExecuted:t[1]||(t[1]=t=>e.$emit("actionExecuted")),onShowPreview:u.navigateToPreviewView},null,8,["actions","endpoint","resource","resource-name","via-many-to-many","via-resource","via-resource-id","via-relationship","onShowPreview"])):(0,o.createCommentVNode)("",!0),u.authorizedToViewAnyResources?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(f,{key:1,as:r.resource.authorizedToView?"a":"button",href:u.viewURL,disabled:!r.resource.authorizedToView||null,onClick:t[2]||(t[2]=(0,o.withModifiers)((()=>{}),["stop"])),class:(0,o.normalizeClass)(["inline-flex items-center justify-center h-9 w-9",r.resource.authorizedToView?"text-gray-500 dark:text-gray-400 hover:[&:not(:disabled)]:text-primary-500 dark:hover:[&:not(:disabled)]:text-primary-500":"disabled:cursor-not-allowed disabled:opacity-50"]),dusk:`${r.resource.id.value}-view-button`,"aria-label":e.__("View")},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",a,[(0,o.createElementVNode)("span",null,[(0,o.createVNode)(m,{name:"eye"})])])])),_:1},8,["as","href","disabled","class","dusk","aria-label"])),[[C,e.__("View"),void 0,{click:!0}]]):(0,o.createCommentVNode)("",!0),u.authorizedToUpdateAnyResources?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(f,{key:2,as:r.resource.authorizedToUpdate?"a":"button",href:u.updateURL,disabled:!r.resource.authorizedToUpdate||null,onClick:t[3]||(t[3]=(0,o.withModifiers)((()=>{}),["stop"])),class:(0,o.normalizeClass)(["inline-flex items-center justify-center h-9 w-9",r.resource.authorizedToUpdate?"text-gray-500 dark:text-gray-400 hover:[&:not(:disabled)]:text-primary-500 dark:hover:[&:not(:disabled)]:text-primary-500":"disabled:cursor-not-allowed disabled:opacity-50"]),dusk:r.viaManyToMany?`${r.resource.id.value}-edit-attached-button`:`${r.resource.id.value}-edit-button`,"aria-label":r.viaManyToMany?e.__("Edit Attached"):e.__("Edit")},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",n,[(0,o.createElementVNode)("span",null,[(0,o.createVNode)(m,{name:"pencil-square"})])])])),_:1},8,["as","href","disabled","class","dusk","aria-label"])),[[C,r.viaManyToMany?e.__("Edit Attached"):e.__("Edit"),void 0,{click:!0}]]):(0,o.createCommentVNode)("",!0),!u.authorizedToDeleteAnyResources||r.resource.softDeleted&&!r.viaManyToMany?(0,o.createCommentVNode)("",!0):(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(v,{key:3,onClick:(0,o.withModifiers)(u.openDeleteModal,["stop"]),"aria-label":e.__(r.viaManyToMany?"Detach":"Delete"),dusk:`${r.resource.id.value}-delete-button`,icon:"trash",variant:"action",disabled:!r.resource.authorizedToDelete},null,8,["onClick","aria-label","dusk","disabled"])),[[C,e.__(r.viaManyToMany?"Detach":"Delete"),void 0,{click:!0}]]),u.authorizedToRestoreAnyResources&&r.resource.softDeleted&&!r.viaManyToMany?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(v,{key:4,"aria-label":e.__("Restore"),disabled:!r.resource.authorizedToRestore,dusk:`${r.resource.id.value}-restore-button`,type:"button",onClick:(0,o.withModifiers)(u.openRestoreModal,["stop"]),icon:"arrow-path",variant:"action"},null,8,["aria-label","disabled","dusk","onClick"])),[[C,e.__("Restore"),void 0,{click:!0}]]):(0,o.createCommentVNode)("",!0),(0,o.createVNode)(g,{mode:r.viaManyToMany?"detach":"delete",show:e.deleteModalOpen,onClose:u.closeDeleteModal,onConfirm:u.confirmDelete},null,8,["mode","show","onClose","onConfirm"]),(0,o.createVNode)(k,{show:e.restoreModalOpen,onClose:u.closeRestoreModal,onConfirm:u.confirmRestore},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(y,{textContent:(0,o.toDisplayString)(e.__("Restore Resource"))},null,8,["textContent"]),(0,o.createVNode)(b,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("p",s,(0,o.toDisplayString)(e.__("Are you sure you want to restore this resource?")),1)])),_:1})])),_:1},8,["show","onClose","onConfirm"])])],2)],10,i),e.previewModalOpen?((0,o.openBlock)(),(0,o.createBlock)(w,{key:0,"resource-id":r.resource.id.value,"resource-name":r.resourceName,show:e.previewModalOpen,onClose:u.closePreviewModal,onConfirm:u.closePreviewModal},null,8,["resource-id","resource-name","show","onClose","onConfirm"])):(0,o.createCommentVNode)("",!0)],64)}],["__file","ResourceTableRow.vue"]])},15404:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>d});var o=r(29726);const i={class:"flex items-center flex-1"},l={class:"md:ml-3"},a={class:"h-9 ml-auto flex items-center pr-2 md:pr-3"},n={class:"hidden md:flex px-2"},s={key:0,class:"flex items-center md:hidden px-2 pt-3 mt-2 md:mt-0 border-t border-gray-200 dark:border-gray-700"};const c={components:{Button:r(74640).Button},emits:["start-polling","stop-polling","deselect"],props:["actionsEndpoint","actionQueryString","allMatchingResourceCount","authorizedToDeleteAnyResources","authorizedToDeleteSelectedResources","authorizedToForceDeleteAnyResources","authorizedToForceDeleteSelectedResources","authorizedToRestoreAnyResources","authorizedToRestoreSelectedResources","availableActions","clearSelectedFilters","closeDeleteModal","currentlyPolling","deleteAllMatchingResources","deleteSelectedResources","filterChanged","forceDeleteAllMatchingResources","forceDeleteSelectedResources","getResources","hasFilters","haveStandaloneActions","lenses","lens","isLensView","perPage","perPageOptions","pivotActions","pivotName","resources","resourceInformation","resourceName","currentPageCount","restoreAllMatchingResources","restoreSelectedResources","selectAllChecked","selectAllMatchingChecked","selectedResources","selectedResourcesForActionSelector","shouldShowActionSelector","shouldShowCheckboxes","shouldShowDeleteMenu","shouldShowPollingToggle","softDeletes","toggleSelectAll","toggleSelectAllMatching","togglePolling","trashed","trashedChanged","trashedParameter","updatePerPageChanged","viaManyToMany","viaResource","loading"],computed:{filters(){return this.$store.getters[`${this.resourceName}/filters`]},filtersAreApplied(){return this.$store.getters[`${this.resourceName}/filtersAreApplied`]},activeFilterCount(){return this.$store.getters[`${this.resourceName}/activeFilterCount`]},filterPerPageOptions(){if(this.resourceInformation)return this.perPageOptions||this.resourceInformation.perPageOptions}}};const d=(0,r(66262).A)(c,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("SelectAllDropdown"),h=(0,o.resolveComponent)("ActionSelector"),m=(0,o.resolveComponent)("Button"),f=(0,o.resolveComponent)("LensSelector"),v=(0,o.resolveComponent)("FilterMenu"),g=(0,o.resolveComponent)("DeleteMenu");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(["flex flex-col md:flex-row md:items-center",{"py-3 border-b border-gray-200 dark:border-gray-700":r.shouldShowCheckboxes||r.shouldShowDeleteMenu||r.softDeletes||!r.viaResource||r.hasFilters||r.haveStandaloneActions}])},[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("div",l,[r.shouldShowCheckboxes?((0,o.openBlock)(),(0,o.createBlock)(p,{key:0,"all-matching-resource-count":r.allMatchingResourceCount,"current-page-count":r.currentPageCount,onToggleSelectAll:r.toggleSelectAll,onToggleSelectAllMatching:r.toggleSelectAllMatching,onDeselect:t[0]||(t[0]=t=>e.$emit("deselect"))},null,8,["all-matching-resource-count","current-page-count","onToggleSelectAll","onToggleSelectAllMatching"])):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("div",a,[(0,o.createElementVNode)("div",n,[r.shouldShowActionSelector?((0,o.openBlock)(),(0,o.createBlock)(h,{key:0,"resource-name":r.resourceName,"via-resource":r.actionQueryString.viaResource,"via-resource-id":r.actionQueryString.viaResourceId,"via-relationship":r.actionQueryString.viaRelationship,actions:r.availableActions,"pivot-actions":r.pivotActions,"pivot-name":r.pivotName,endpoint:r.actionsEndpoint,"selected-resources":r.selectedResourcesForActionSelector,onActionExecuted:r.getResources},null,8,["resource-name","via-resource","via-resource-id","via-relationship","actions","pivot-actions","pivot-name","endpoint","selected-resources","onActionExecuted"])):(0,o.createCommentVNode)("",!0)]),r.shouldShowPollingToggle?((0,o.openBlock)(),(0,o.createBlock)(m,{key:0,onClick:r.togglePolling,icon:"clock",variant:"link",state:r.currentlyPolling?"default":"mellow"},null,8,["onClick","state"])):(0,o.createCommentVNode)("",!0),r.lenses?.length>0?((0,o.openBlock)(),(0,o.createBlock)(f,{key:1,"resource-name":r.resourceName,lenses:r.lenses},null,8,["resource-name","lenses"])):(0,o.createCommentVNode)("",!0),u.filters.length>0||r.softDeletes||!r.viaResource?((0,o.openBlock)(),(0,o.createBlock)(v,{key:2,"active-filter-count":u.activeFilterCount,"filters-are-applied":u.filtersAreApplied,filters:u.filters,"per-page-options":u.filterPerPageOptions,"per-page":r.perPage,"resource-name":r.resourceName,"soft-deletes":r.softDeletes,trashed:r.trashed,"via-resource":r.viaResource,onClearSelectedFilters:t[1]||(t[1]=e=>r.clearSelectedFilters(r.lens||null)),onFilterChanged:r.filterChanged,onPerPageChanged:r.updatePerPageChanged,onTrashedChanged:r.trashedChanged},null,8,["active-filter-count","filters-are-applied","filters","per-page-options","per-page","resource-name","soft-deletes","trashed","via-resource","onFilterChanged","onPerPageChanged","onTrashedChanged"])):(0,o.createCommentVNode)("",!0),r.shouldShowDeleteMenu?((0,o.openBlock)(),(0,o.createBlock)(g,{key:3,class:"flex",dusk:"delete-menu","soft-deletes":r.softDeletes,resources:r.resources,"selected-resources":r.selectedResources,"via-many-to-many":r.viaManyToMany,"all-matching-resource-count":r.allMatchingResourceCount,"all-matching-selected":r.selectAllMatchingChecked,"authorized-to-delete-selected-resources":r.authorizedToDeleteSelectedResources,"authorized-to-force-delete-selected-resources":r.authorizedToForceDeleteSelectedResources,"authorized-to-delete-any-resources":r.authorizedToDeleteAnyResources,"authorized-to-force-delete-any-resources":r.authorizedToForceDeleteAnyResources,"authorized-to-restore-selected-resources":r.authorizedToRestoreSelectedResources,"authorized-to-restore-any-resources":r.authorizedToRestoreAnyResources,onDeleteSelected:r.deleteSelectedResources,onDeleteAllMatching:r.deleteAllMatchingResources,onForceDeleteSelected:r.forceDeleteSelectedResources,onForceDeleteAllMatching:r.forceDeleteAllMatchingResources,onRestoreSelected:r.restoreSelectedResources,onRestoreAllMatching:r.restoreAllMatchingResources,onClose:r.closeDeleteModal,"trashed-parameter":r.trashedParameter},null,8,["soft-deletes","resources","selected-resources","via-many-to-many","all-matching-resource-count","all-matching-selected","authorized-to-delete-selected-resources","authorized-to-force-delete-selected-resources","authorized-to-delete-any-resources","authorized-to-force-delete-any-resources","authorized-to-restore-selected-resources","authorized-to-restore-any-resources","onDeleteSelected","onDeleteAllMatching","onForceDeleteSelected","onForceDeleteAllMatching","onRestoreSelected","onRestoreAllMatching","onClose","trashed-parameter"])):(0,o.createCommentVNode)("",!0)])]),r.shouldShowActionSelector?((0,o.openBlock)(),(0,o.createElementBlock)("div",s,[(0,o.createVNode)(h,{width:"full","resource-name":r.resourceName,"via-resource":r.actionQueryString.viaResource,"via-resource-id":r.actionQueryString.viaResourceId,"via-relationship":r.actionQueryString.viaRelationship,actions:r.availableActions,"pivot-actions":r.pivotActions,"pivot-name":r.pivotName,endpoint:r.actionsEndpoint,"selected-resources":r.selectedResourcesForActionSelector,onActionExecuted:r.getResources},null,8,["resource-name","via-resource","via-resource-id","via-relationship","actions","pivot-actions","pivot-name","endpoint","selected-resources","onActionExecuted"])])):(0,o.createCommentVNode)("",!0)],2)}],["__file","ResourceTableToolbar.vue"]])},96279:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={__name:"ScrollWrap",props:{height:{type:Number,default:288}},setup(e){const t=e,r=(0,o.computed)((()=>({maxHeight:`${t.height}px`})));return(e,t)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{class:"scroll-wrap overflow-x-hidden overflow-y-auto",style:(0,o.normalizeStyle)(r.value)},[(0,o.renderSlot)(e.$slots,"default")],4))}};const l=(0,r(66262).A)(i,[["__file","ScrollWrap.vue"]])},33025:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i=["dusk","aria-sort"],l={class:"inline-flex font-sans font-bold uppercase text-xxs tracking-wide text-gray-500"},a={class:"ml-2 shrink-0",xmlns:"http://www.w3.org/2000/svg",width:"8",height:"14",viewBox:"0 0 8 14"};const n={emits:["sort","reset"],mixins:[r(35229).XJ],props:{resourceName:String,uriKey:String},inject:["orderByParameter","orderByDirectionParameter"],methods:{handleClick(){this.isSorted&&this.isDescDirection?this.$emit("reset"):this.$emit("sort",{key:this.uriKey,direction:this.direction})}},computed:{isDescDirection(){return"desc"==this.direction},isAscDirection(){return"asc"==this.direction},ascClass(){return this.isSorted&&this.isDescDirection?"fill-gray-500 dark:fill-gray-300":"fill-gray-300 dark:fill-gray-500"},descClass(){return this.isSorted&&this.isAscDirection?"fill-gray-500 dark:fill-gray-300":"fill-gray-300 dark:fill-gray-500"},isSorted(){return this.sortColumn==this.uriKey&&["asc","desc"].includes(this.direction)},sortKey(){return this.orderByParameter},sortColumn(){return this.queryStringParams[this.sortKey]},directionKey(){return this.orderByDirectionParameter},direction(){return this.queryStringParams[this.directionKey]},notSorted(){return!this.isSorted},ariaSort(){return this.isDescDirection?"descending":this.isAscDirection?"ascending":"none"}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,n,s,c){return(0,o.openBlock)(),(0,o.createElementBlock)("button",{type:"button",onClick:t[0]||(t[0]=(0,o.withModifiers)(((...e)=>c.handleClick&&c.handleClick(...e)),["prevent"])),class:"cursor-pointer inline-flex items-center focus:outline-none focus:ring ring-primary-200 dark:ring-gray-600 rounded",dusk:"sort-"+r.uriKey,"aria-sort":c.ariaSort},[(0,o.createElementVNode)("span",l,[(0,o.renderSlot)(e.$slots,"default")]),((0,o.openBlock)(),(0,o.createElementBlock)("svg",a,[(0,o.createElementVNode)("path",{class:(0,o.normalizeClass)(c.descClass),d:"M1.70710678 4.70710678c-.39052429.39052429-1.02368927.39052429-1.41421356 0-.3905243-.39052429-.3905243-1.02368927 0-1.41421356l3-3c.39052429-.3905243 1.02368927-.3905243 1.41421356 0l3 3c.39052429.39052429.39052429 1.02368927 0 1.41421356-.39052429.39052429-1.02368927.39052429-1.41421356 0L4 2.41421356 1.70710678 4.70710678z"},null,2),(0,o.createElementVNode)("path",{class:(0,o.normalizeClass)(c.ascClass),d:"M6.29289322 9.29289322c.39052429-.39052429 1.02368927-.39052429 1.41421356 0 .39052429.39052429.39052429 1.02368928 0 1.41421358l-3 3c-.39052429.3905243-1.02368927.3905243-1.41421356 0l-3-3c-.3905243-.3905243-.3905243-1.02368929 0-1.41421358.3905243-.39052429 1.02368927-.39052429 1.41421356 0L4 11.5857864l2.29289322-2.29289318z"},null,2)]))],8,i)}],["__file","SortableIcon.vue"]])},19078:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"flex flex-wrap gap-2"},l={__name:"TagGroup",props:{resourceName:{type:String},tags:{type:Array,default:[]},limit:{type:[Number,Boolean],default:!1},editable:{type:Boolean,default:!0},withPreview:{type:Boolean,default:!1}},setup(e){const t=e,r=(0,o.ref)(!1),l=(0,o.computed)((()=>!1!==t.limit&&t.tags.length>t.limit&&!r.value)),a=(0,o.computed)((()=>!1===t.limit||r.value?t.tags:t.tags.slice(0,t.limit)));function n(){r.value=!0}return(t,r)=>{const s=(0,o.resolveComponent)("TagGroupItem"),c=(0,o.resolveComponent)("Icon"),d=(0,o.resolveComponent)("Badge"),u=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(a.value,((r,i)=>((0,o.openBlock)(),(0,o.createBlock)(s,{key:i,tag:r,index:i,"resource-name":e.resourceName,editable:e.editable,"with-preview":e.withPreview,onTagRemoved:e=>t.$emit("tag-removed",e)},null,8,["tag","index","resource-name","editable","with-preview","onTagRemoved"])))),128)),l.value?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(d,{key:0,onClick:(0,o.withModifiers)(n,["stop"]),class:"cursor-pointer bg-primary-50 dark:bg-primary-500 text-primary-600 dark:text-gray-900 space-x-1"},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(c,{type:"dots-horizontal",width:"16",height:"16"})])),_:1})),[[u,t.__("Show more")]]):(0,o.createCommentVNode)("",!0)])}}};const a=(0,r(66262).A)(l,[["__file","TagGroup.vue"]])},40229:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726),i=r(74640);const l={__name:"TagGroupItem",props:{resourceName:{type:String},index:{type:Number,required:!0},tag:{type:Object,required:!0},editable:{type:Boolean,default:!0},withSubtitles:{type:Boolean,default:!0},withPreview:{type:Boolean,default:!1}},emits:["tag-removed","click"],setup(e){const t=(0,o.ref)(!1),r=e;function l(){r.withPreview&&(t.value=!t.value)}return(r,a)=>{const n=(0,o.resolveComponent)("Badge"),s=(0,o.resolveComponent)("PreviewResourceModal");return(0,o.openBlock)(),(0,o.createElementBlock)("button",{type:"button",onClick:(0,o.withModifiers)(l,["stop"]),class:(0,o.normalizeClass)(["appearance-none inline-flex items-center text-left rounded-lg",{"hover:opacity-50":e.withPreview,"!cursor-default":!e.withPreview}])},[(0,o.createVNode)(n,{class:(0,o.normalizeClass)(["bg-primary-50 dark:bg-primary-500 text-primary-600 dark:text-gray-900 space-x-1",{"!pl-2 !pr-1":e.editable}])},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(e.tag.display),1),e.editable?((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:0,onClick:a[0]||(a[0]=(0,o.withModifiers)((t=>r.$emit("tag-removed",e.index)),["stop"])),type:"button",class:"opacity-50 hover:opacity-75 dark:opacity-100 dark:hover:opacity-50"},[(0,o.createVNode)((0,o.unref)(i.Icon),{name:"x-mark",type:"micro"})])):(0,o.createCommentVNode)("",!0)])),_:1},8,["class"]),e.withPreview?((0,o.openBlock)(),(0,o.createBlock)(s,{key:0,onClose:l,show:t.value,"resource-id":e.tag.value,"resource-name":e.resourceName},null,8,["show","resource-id","resource-name"])):(0,o.createCommentVNode)("",!0)],2)}}};const a=(0,r(66262).A)(l,[["__file","TagGroupItem.vue"]])},17039:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={__name:"TagList",props:{resourceName:{type:String},tags:{type:Array,default:[]},editable:{type:Boolean,default:!0},withSubtitles:{type:Boolean,default:!0},withPreview:{type:Boolean,default:!1}},emits:["tag-removed","click"],setup:e=>(t,r)=>{const i=(0,o.resolveComponent)("TagListItem");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.tags,((r,l)=>((0,o.openBlock)(),(0,o.createBlock)(i,{key:l,index:l,tag:r,"resource-name":e.resourceName,editable:e.editable,"with-subtitles":e.withSubtitles,"with-preview":e.withPreview,onTagRemoved:e=>t.$emit("tag-removed",e)},null,8,["index","tag","resource-name","editable","with-subtitles","with-preview","onTagRemoved"])))),128))])}};const l=(0,r(66262).A)(i,[["__file","TagList.vue"]])},99973:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726),i=r(74640);const l={class:"flex items-center space-x-3"},a={class:"text-xs font-semibold"},n={key:0,class:"text-xs"},s={__name:"TagListItem",props:{resourceName:{type:String},index:{type:Number,required:!0},tag:{type:Object,required:!0},editable:{type:Boolean,default:!0},withSubtitles:{type:Boolean,default:!0},withPreview:{type:Boolean,default:!1}},emits:["tag-removed","click"],setup(e){const t=(0,o.ref)(!1),r=e;function s(){r.withPreview&&(t.value=!t.value)}return(r,c)=>{const d=(0,o.resolveComponent)("Avatar"),u=(0,o.resolveComponent)("PreviewResourceModal");return(0,o.openBlock)(),(0,o.createElementBlock)("button",{type:"button",onClick:(0,o.withModifiers)(s,["stop"]),class:(0,o.normalizeClass)(["block w-full flex items-center text-left rounded px-1 py-1",{"hover:bg-gray-50 dark:hover:bg-gray-700":e.withPreview,"!cursor-default":!e.withPreview}])},[(0,o.createElementVNode)("div",l,[e.tag.avatar?((0,o.openBlock)(),(0,o.createBlock)(d,{key:0,src:e.tag.avatar,rounded:!0,medium:""},null,8,["src"])):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",null,[(0,o.createElementVNode)("p",a,(0,o.toDisplayString)(e.tag.display),1),e.withSubtitles?((0,o.openBlock)(),(0,o.createElementBlock)("p",n,(0,o.toDisplayString)(e.tag.subtitle),1)):(0,o.createCommentVNode)("",!0)])]),e.editable?((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:0,onClick:c[0]||(c[0]=(0,o.withModifiers)((t=>r.$emit("tag-removed",e.index)),["stop"])),type:"button",class:"flex inline-flex items-center justify-center appearance-none cursor-pointer ml-auto text-red-500 hover:text-red-600 active:outline-none focus:ring focus:ring-primary-200 focus:outline-none rounded"},[(0,o.createVNode)((0,o.unref)(i.Icon),{name:"minus-circle",type:"solid",class:"hover:opacity-50"})])):(0,o.createCommentVNode)("",!0),e.withPreview?((0,o.openBlock)(),(0,o.createBlock)(u,{key:1,onClose:s,show:t.value,"resource-id":e.tag.value,"resource-name":e.resourceName},null,8,["show","resource-id","resource-name"])):(0,o.createCommentVNode)("",!0)],2)}}};const c=(0,r(66262).A)(s,[["__file","TagListItem.vue"]])},69793:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function l(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach((function(t){a(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function a(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const n=l(l({},r(63218).Ie),{},{emits:["tooltip-show","tooltip-hide"],props:{distance:{type:Number,default:0},skidding:{type:Number,default:3},triggers:{type:Array,default:["hover"]},placement:{type:String,default:"top"},boundary:{type:String,default:"window"},preventOverflow:{type:Boolean,default:!0},theme:{type:String,default:"Nova"}}});const s=(0,r(66262).A)(n,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("VDropdown");return(0,o.openBlock)(),(0,o.createBlock)(n,{triggers:r.triggers,distance:r.distance,skidding:r.skidding,placement:r.placement,boundary:r.boundary,"prevent-overflow":r.preventOverflow,"handle-resize":!0,theme:r.theme,onShow:t[0]||(t[0]=t=>e.$emit("tooltip-show")),onHide:t[1]||(t[1]=t=>e.$emit("tooltip-hide"))},{popper:(0,o.withCtx)((()=>[(0,o.renderSlot)(e.$slots,"content")])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,[(0,o.renderSlot)(e.$slots,"default")])])),_:3},8,["triggers","distance","skidding","placement","boundary","prevent-overflow","theme"])}],["__file","Tooltip.vue"]])},18384:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:{maxWidth:{default:"auto"}},computed:{defaultAttributes(){return{class:this.$attrs.class||"px-3 py-2 text-sm leading-normal",style:{maxWidth:"auto"===this.maxWidth?this.maxWidth:`${this.maxWidth}px`}}}}};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){return(0,o.openBlock)(),(0,o.createElementBlock)("div",(0,o.normalizeProps)((0,o.guardReactiveProps)(a.defaultAttributes)),[(0,o.renderSlot)(e.$slots,"default")],16)}],["__file","TooltipContent.vue"]])},25882:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function l(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach((function(t){a(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function a(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const n=Object.assign({inheritAttrs:!1},{__name:"TrashedCheckbox",props:{resourceName:String,withTrashed:Boolean},emits:["input"],setup:e=>(t,r)=>{const i=(0,o.resolveComponent)("CheckboxWithLabel");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.createVNode)(i,(0,o.mergeProps)(l({},t.$attrs),{dusk:`${e.resourceName}-with-trashed-checkbox`,checked:e.withTrashed,onInput:r[0]||(r[0]=e=>t.$emit("input"))}),{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(t.__("With Trashed")),1)])),_:1},16,["dusk","checked"])])}});const s=(0,r(66262).A)(n,[["__file","TrashedCheckbox.vue"]])},46199:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i=["input","placeholder"],l=["name","id","value"];var a=r(25542);r(8507),r(18028);const n={name:"trix-vue",inheritAttrs:!1,emits:["change","file-added","file-removed"],props:{name:{type:String},value:{type:String},placeholder:{type:String},withFiles:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1}},data:()=>({uid:(0,a.L)(),loading:!0}),methods:{initialize(){this.disabled&&this.$refs.theEditor.setAttribute("contenteditable",!1),this.loading=!1},handleChange(){this.loading||this.$emit("change",this.$refs.theEditor.value)},handleFileAccept(e){this.withFiles||e.preventDefault()},handleAddFile(e){this.$emit("file-added",e)},handleRemoveFile(e){this.$emit("file-removed",e)}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,a,n,s){return(0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,null,[(0,o.createElementVNode)("trix-editor",(0,o.mergeProps)({ref:"theEditor",onKeydown:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),input:e.uid},e.$attrs,{onTrixChange:t[1]||(t[1]=(...e)=>s.handleChange&&s.handleChange(...e)),onTrixInitialize:t[2]||(t[2]=(...e)=>s.initialize&&s.initialize(...e)),onTrixAttachmentAdd:t[3]||(t[3]=(...e)=>s.handleAddFile&&s.handleAddFile(...e)),onTrixAttachmentRemove:t[4]||(t[4]=(...e)=>s.handleRemoveFile&&s.handleRemoveFile(...e)),onTrixFileAccept:t[5]||(t[5]=(...e)=>s.handleFileAccept&&s.handleFileAccept(...e)),placeholder:r.placeholder,class:"trix-content prose !max-w-full prose-sm dark:prose-invert"}),null,16,i),(0,o.createElementVNode)("input",{type:"hidden",name:r.name,id:e.uid,value:r.value},null,8,l)],64)}],["__file","Trix.vue"]])},60465:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>R});var o=r(29726);const i={class:"inline-flex items-center shrink-0 gap-2"},l={class:"hidden lg:inline-block"},a=["alt","src"],n={class:"whitespace-nowrap"},s={class:"py-1"},c={class:"divide-y divide-gray-100 dark:divide-gray-700"},d={key:0},u={key:0,class:"mr-1"},p={key:1,class:"flex items-center"},h=["alt","src"],m={class:"whitespace-nowrap"};var f=r(74640),v=r(66278),g=r(59977),y=r(83488),b=r.n(y),k=r(42194),w=r.n(k),C=r(71086),x=r.n(C);function N(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function B(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?N(Object(r),!0).forEach((function(t){S(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):N(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function S(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const V={components:{Button:f.Button,Icon:f.Icon},props:{mobile:{type:Boolean,default:!1}},methods:B(B(B({},(0,v.i0)(["logout","stopImpersonating"])),(0,v.PY)(["toggleMainMenu"])),{},{async attempt(){confirm(this.__("Are you sure you want to log out?"))&&this.logout(Nova.config("customLogoutPath")).then((e=>{null===e?Nova.redirectToLogin():location.href=e})).catch((e=>{g.QB.reload()}))},visitUserSecurityPage(){Nova.visit("/user-security")},handleStopImpersonating(){confirm(this.__("Are you sure you want to stop impersonating?"))&&this.stopImpersonating()},handleUserMenuClosed(){!0===this.mobile&&this.toggleMainMenu()}}),computed:B(B({},(0,v.L8)(["currentUser","userMenu"])),{},{userName(){return this.currentUser.name||this.currentUser.email||this.__("Nova User")},formattedItems(){return this.userMenu.map((e=>{let t=e.method||"GET",r={href:e.path};return e.external&&"GET"==t?{component:"DropdownMenuItem",props:B(B({},r),{},{target:e.target||null}),name:e.name,external:e.external,on:{}}:{component:"DropdownMenuItem",props:x()(w()(B(B({},r),{},{method:"GET"!==t?t:null,data:e.data||null,headers:e.headers||null,as:"GET"===t?"link":"form-button"}),(e=>null===e)),b()),external:e.external,name:e.name,on:{},badge:e.badge}}))},hasUserMenu(){return this.currentUser&&(this.formattedItems.length>0||this.supportsAuthentication||this.currentUser.impersonating)},supportsAuthentication(){return!0===Nova.config("withAuthentication")||!1!==this.customLogoutPath},supportsUserSecurity:()=>Nova.hasSecurityFeatures(),customLogoutPath:()=>Nova.config("customLogoutPath"),dropdownPlacement(){return!0===this.mobile?"top-start":"bottom-end"}})};const R=(0,r(66262).A)(V,[["render",function(e,t,r,f,v,g){const y=(0,o.resolveComponent)("Icon"),b=(0,o.resolveComponent)("Button"),k=(0,o.resolveComponent)("Badge"),w=(0,o.resolveComponent)("DropdownMenuItem"),C=(0,o.resolveComponent)("DropdownMenu"),x=(0,o.resolveComponent)("Dropdown");return g.hasUserMenu?((0,o.openBlock)(),(0,o.createBlock)(x,{key:0,onMenuClosed:g.handleUserMenuClosed,placement:g.dropdownPlacement},{menu:(0,o.withCtx)((()=>[(0,o.createVNode)(C,{width:"200",class:"px-1"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("nav",s,[(0,o.createElementVNode)("div",c,[g.formattedItems.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",d,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(g.formattedItems,(e=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(e.component),(0,o.mergeProps)({key:e.path,ref_for:!0},e.props,(0,o.toHandlers)(e.on)),{default:(0,o.withCtx)((()=>[e.badge?((0,o.openBlock)(),(0,o.createElementBlock)("span",u,[(0,o.createVNode)(k,{"extra-classes":e.badge.typeClass},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.badge.value),1)])),_:2},1032,["extra-classes"])])):(0,o.createCommentVNode)("",!0),(0,o.createTextVNode)(" "+(0,o.toDisplayString)(e.name),1)])),_:2},1040)))),128))])):(0,o.createCommentVNode)("",!0),e.currentUser.impersonating?((0,o.openBlock)(),(0,o.createBlock)(w,{key:1,as:"button",onClick:g.handleStopImpersonating},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Stop Impersonating")),1)])),_:1},8,["onClick"])):(0,o.createCommentVNode)("",!0),g.supportsUserSecurity?((0,o.openBlock)(),(0,o.createBlock)(w,{key:2,as:"button",onClick:g.visitUserSecurityPage},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("User Security")),1)])),_:1},8,["onClick"])):(0,o.createCommentVNode)("",!0),g.supportsAuthentication?((0,o.openBlock)(),(0,o.createBlock)(w,{key:3,as:"button",onClick:g.attempt},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Logout")),1)])),_:1},8,["onClick"])):(0,o.createCommentVNode)("",!0)])])])),_:1})])),default:(0,o.withCtx)((()=>[(0,o.createVNode)(b,{class:"block shrink-0",variant:"ghost",padding:"tight","trailing-icon":"chevron-down"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",i,[(0,o.createElementVNode)("span",l,[e.currentUser.impersonating?((0,o.openBlock)(),(0,o.createBlock)(y,{key:0,name:"finger-print",type:"solid",class:"!w-7 !h-7"})):e.currentUser.avatar?((0,o.openBlock)(),(0,o.createElementBlock)("img",{key:1,alt:e.__(":name's Avatar",{name:g.userName}),src:e.currentUser.avatar,class:"rounded-full w-7 h-7"},null,8,a)):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("span",n,(0,o.toDisplayString)(g.userName),1)])])),_:1})])),_:1},8,["onMenuClosed","placement"])):e.currentUser?((0,o.openBlock)(),(0,o.createElementBlock)("div",p,[e.currentUser.avatar?((0,o.openBlock)(),(0,o.createElementBlock)("img",{key:0,alt:e.__(":name's Avatar",{name:g.userName}),src:e.currentUser.avatar,class:"rounded-full w-8 h-8 mr-3"},null,8,h)):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("span",m,(0,o.toDisplayString)(g.userName),1)])):(0,o.createCommentVNode)("",!0)}],["__file","UserMenu.vue"]])},21073:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>R});var o=r(29726);const i={class:"mt-10 sm:mt-0 mb-6"},l={class:"md:grid md:grid-cols-3 md:gap-6"},a={class:"md:col-span-1 flex justify-between"},n={class:"px-4 sm:px-0"},s={class:"my-3 text-sm text-gray-600"},c={class:"grid grid-cols-6 gap-6"},d={class:"col-span-full sm:col-span-4"},u={class:"mt-6"},p={key:0,class:"col-span-6 sm:col-span-4"},h={key:0},m={class:"mt-4 max-w-xl text-sm"},f={key:0,class:"font-semibold"},v={key:1},g=["innerHTML"],y={key:0,class:"mt-4 max-w-xl text-sm"},b={class:"font-semibold"},k=["innerHTML"],w={key:1,class:"mt-4"},C={key:1},x={class:"mt-4 max-w-xl text-sm"},N={class:"font-semibold"},B={class:"grid gap-1 max-w-xl mt-4 px-4 py-4 font-mono text-sm bg-gray-100 dark:bg-gray-900 dark:text-gray-100 rounded-lg"},S={class:"col-span-full sm:col-span-4"};const V={name:"UserSecurityTwoFactorAuthentication",components:{Button:r(74640).Button},props:{options:{type:Object,required:!0},user:{type:Object,required:!0}},data:()=>({confirmationForm:Nova.form({code:""}),confirming:!1,enabling:!1,disabling:!1,qrCode:null,setupKey:null,recoveryCodes:[]}),methods:{enableTwoFactorAuthentication(){this.enabling=!0,Nova.request().post(Nova.url("/user-security/two-factor-authentication")).then((()=>{Nova.$router.reload({only:["user"],onSuccess:()=>Promise.all([this.showQrCode(),this.showSetupKey(),this.showRecoveryCodes()])})})).finally((()=>{this.enabling=!1,this.confirming=this.requiresConfirmation}))},showQrCode(){return Nova.request().get(Nova.url("/user-security/two-factor-qr-code")).then((e=>{this.qrCode=e.data.svg}))},showSetupKey(){return Nova.request().get(Nova.url("/user-security/two-factor-secret-key")).then((e=>{this.setupKey=e.data.secretKey}))},showRecoveryCodes(){return Nova.request().get(Nova.url("/user-security/two-factor-recovery-codes")).then((e=>{this.recoveryCodes=e.data}))},confirmTwoFactorAuthentication(){this.confirmationForm.post(Nova.url("/user-security/confirmed-two-factor-authentication")).then((e=>{this.confirming=!1,this.qrCode=null,this.setupKey=null}))},regenerateRecoveryCodes(){Nova.request().post(Nova.url("/user-security/two-factor-recovery-codes")).then((()=>this.showRecoveryCodes()))},disableTwoFactorAuthentication(){this.disabling=!0,Nova.request().delete(Nova.url("/user-security/two-factor-authentication")).then((()=>{this.disabling=!1,this.confirming=!1,Nova.$router.reload({only:["user"]})}))}},computed:{twoFactorEnabled(){return!this.enabling&&this.user.two_factor_enabled},requiresConfirmPassword(){return this.options?.confirmPassword??!1},requiresConfirmation(){return this.options?.confirm??!1}}};const R=(0,r(66262).A)(V,[["render",function(e,t,r,V,R,E){const _=(0,o.resolveComponent)("Heading"),O=(0,o.resolveComponent)("HelpText"),F=(0,o.resolveComponent)("Button"),D=(0,o.resolveComponent)("ConfirmsPassword"),A=(0,o.resolveComponent)("Card");return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("div",a,[(0,o.createElementVNode)("div",n,[(0,o.createVNode)(_,{level:3,textContent:(0,o.toDisplayString)(e.__("Two Factor Authentication"))},null,8,["textContent"]),(0,o.createElementVNode)("p",s,(0,o.toDisplayString)(e.__("Add additional security to your account using two factor authentication.")),1)])]),(0,o.createVNode)(A,{class:"md:col-span-2 p-6"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",c,[(0,o.createElementVNode)("div",d,[E.twoFactorEnabled&&!R.confirming?((0,o.openBlock)(),(0,o.createBlock)(_,{key:0,level:4,textContent:(0,o.toDisplayString)(e.__("You have enabled two factor authentication.")),class:"text-lg font-medium"},null,8,["textContent"])):E.twoFactorEnabled&&R.confirming?((0,o.openBlock)(),(0,o.createBlock)(_,{key:1,level:4,textContent:(0,o.toDisplayString)(e.__("Finish enabling two factor authentication.")),class:"text-lg font-medium"},null,8,["textContent"])):((0,o.openBlock)(),(0,o.createBlock)(_,{key:2,level:4,textContent:(0,o.toDisplayString)(e.__("You have not enabled two factor authentication.")),class:"text-lg font-medium"},null,8,["textContent"])),(0,o.createElementVNode)("p",u,(0,o.toDisplayString)(e.__("When two factor authentication is enabled, you will be prompted for a secure, random token during authentication. You may retrieve this token from your phone's Google Authenticator application.")),1)]),E.twoFactorEnabled?((0,o.openBlock)(),(0,o.createElementBlock)("div",p,[R.qrCode?((0,o.openBlock)(),(0,o.createElementBlock)("div",h,[(0,o.createElementVNode)("div",m,[R.confirming||R.disabling?((0,o.openBlock)(),(0,o.createElementBlock)("p",f,(0,o.toDisplayString)(e.__("To finish enabling two factor authentication, scan the following QR code using your phone's authenticator application or enter the setup key and provide the generated OTP code.")),1)):((0,o.openBlock)(),(0,o.createElementBlock)("p",v,(0,o.toDisplayString)(e.__("Two factor authentication is now enabled. Scan the following QR code using your phone's authenticator application or enter the setup key.")),1))]),(0,o.createElementVNode)("div",{class:"mt-4 p-2 inline-block bg-white",innerHTML:R.qrCode},null,8,g),R.setupKey?((0,o.openBlock)(),(0,o.createElementBlock)("div",y,[(0,o.createElementVNode)("p",b,[t[2]||(t[2]=(0,o.createTextVNode)(" Setup Key: ")),(0,o.createElementVNode)("span",{innerHTML:R.setupKey},null,8,k)])])):(0,o.createCommentVNode)("",!0),R.confirming?((0,o.openBlock)(),(0,o.createElementBlock)("div",w,[t[3]||(t[3]=(0,o.createElementVNode)("label",{class:"block mb-2",for:"code"},"Code",-1)),(0,o.withDirectives)((0,o.createElementVNode)("input",{id:"code","onUpdate:modelValue":t[0]||(t[0]=e=>R.confirmationForm.code=e),type:"text",name:"code",class:(0,o.normalizeClass)(["form-control form-input form-control-bordered w-full",{"form-control-bordered-error":R.confirmationForm.errors.has("code")}]),inputmode:"numeric",autofocus:"",autocomplete:"one-time-code",onKeyup:t[1]||(t[1]=(0,o.withKeys)(((...e)=>E.confirmTwoFactorAuthentication&&E.confirmTwoFactorAuthentication(...e)),["enter"]))},null,34),[[o.vModelText,R.confirmationForm.code]]),R.confirmationForm.errors.has("code")?((0,o.openBlock)(),(0,o.createBlock)(O,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(R.confirmationForm.errors.first("code")),1)])),_:1})):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0),R.recoveryCodes.length>0&&!R.confirming&&!R.disabling?((0,o.openBlock)(),(0,o.createElementBlock)("div",C,[(0,o.createElementVNode)("div",x,[(0,o.createElementVNode)("p",N,(0,o.toDisplayString)(e.__("Store these recovery codes in a secure password manager. They can be used to recover access to your account if your two factor authentication device is lost.")),1)]),(0,o.createElementVNode)("div",B,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(R.recoveryCodes,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:e},(0,o.toDisplayString)(e),1)))),128))])])):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",S,[E.twoFactorEnabled?((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:1},[R.confirming?((0,o.openBlock)(),(0,o.createBlock)(F,{key:0,loading:R.confirmationForm.processing||R.enabling,disabled:R.enabling,label:e.__("Confirm"),onClick:E.confirmTwoFactorAuthentication,class:"inline-flex items-center me-3"},null,8,["loading","disabled","label","onClick"])):(0,o.createCommentVNode)("",!0),(0,o.createVNode)(D,{onConfirmed:E.regenerateRecoveryCodes},{default:(0,o.withCtx)((()=>[R.recoveryCodes.length>0&&!R.confirming?((0,o.openBlock)(),(0,o.createBlock)(F,{key:0,variant:"outline",label:e.__("Regenerate Recovery Codes"),class:"inline-flex items-center me-3"},null,8,["label"])):(0,o.createCommentVNode)("",!0)])),_:1},8,["onConfirmed"]),(0,o.createVNode)(D,{onConfirmed:E.showRecoveryCodes},{default:(0,o.withCtx)((()=>[0!==R.recoveryCodes.length||R.confirming?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createBlock)(F,{key:0,variant:"outline",label:e.__("Show Recovery Codes"),class:"inline-flex items-center me-3"},null,8,["label"]))])),_:1},8,["onConfirmed"]),R.confirming?((0,o.openBlock)(),(0,o.createBlock)(F,{key:1,loading:R.disabling,disabled:R.disabling,variant:"ghost",label:e.__("Cancel"),onClick:E.disableTwoFactorAuthentication,class:"inline-flex items-center me-3"},null,8,["loading","disabled","label","onClick"])):(0,o.createCommentVNode)("",!0),(0,o.createVNode)(D,{mode:E.requiresConfirmPassword?"always":"timeout",onConfirmed:E.disableTwoFactorAuthentication},{default:(0,o.withCtx)((()=>[R.confirming?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createBlock)(F,{key:0,loading:R.disabling,disabled:R.disabling,state:"danger",label:e.__("Disable"),class:"inline-flex items-center me-3"},null,8,["loading","disabled","label"]))])),_:1},8,["mode","onConfirmed"])],64)):((0,o.openBlock)(),(0,o.createBlock)(D,{key:0,mode:E.requiresConfirmPassword?"always":"timeout",onConfirmed:E.enableTwoFactorAuthentication},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(F,{loading:R.enabling,disabled:R.enabling,label:e.__("Enable"),class:"inline-flex items-center me-3"},null,8,["loading","disabled","label"])])),_:1},8,["mode","onConfirmed"]))])])])),_:1})])])}],["__file","UserSecurityTwoFactorAuthentication.vue"]])},39699:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>k});var o=r(29726);const i={class:"mt-10 sm:mt-0 mb-6"},l={class:"md:grid md:grid-cols-3 md:gap-6"},a={class:"md:col-span-1 flex justify-between"},n={class:"px-4 sm:px-0"},s={class:"my-3 text-sm text-gray-600"},c={class:"mt-6 px-6 grid grid-cols-6 gap-6"},d={class:"col-span-full sm:col-span-4"},u={class:"mt-6"},p={class:"col-span-6 sm:col-span-4"},h={class:"block mb-2",for:"current_password"},m={class:"col-span-6 sm:col-span-4"},f={class:"block mb-2",for:"password"},v={class:"col-span-6 sm:col-span-4"},g={class:"block mb-2",for:"password_confirmation"},y={class:"bg-gray-100 dark:bg-gray-700 px-6 py-3 mt-6 flex justify-end"};const b={name:"UserSecurityUpdatePasswords",components:{Button:r(74640).Button},data:()=>({form:Nova.form({current_password:"",password:"",password_confirmation:""})}),methods:{updatePassword(){this.form.put(Nova.url("/user-security/password")).then((e=>{Nova.$toasted.show(this.__("Your password has been updated."),{duration:null,type:"success"})})).catch((e=>{500===e.response?.status&&Nova.error(this.__("There was a problem submitting the form."))}))}}};const k=(0,r(66262).A)(b,[["render",function(e,t,r,b,k,w){const C=(0,o.resolveComponent)("Heading"),x=(0,o.resolveComponent)("HelpText"),N=(0,o.resolveComponent)("Button"),B=(0,o.resolveComponent)("Card");return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("div",a,[(0,o.createElementVNode)("div",n,[(0,o.createVNode)(C,{level:3,textContent:(0,o.toDisplayString)(e.__("Update Password"))},null,8,["textContent"]),(0,o.createElementVNode)("p",s,(0,o.toDisplayString)(e.__("Ensure your account is using a long, random password to stay secure.")),1)])]),(0,o.createVNode)(B,{class:"md:col-span-2 pt-6"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("form",{onSubmit:t[3]||(t[3]=(0,o.withModifiers)(((...e)=>w.updatePassword&&w.updatePassword(...e)),["prevent"]))},[(0,o.createElementVNode)("div",c,[(0,o.createElementVNode)("div",d,[(0,o.createVNode)(C,{level:4,textContent:(0,o.toDisplayString)(e.__("Update Password")),class:"text-lg font-medium"},null,8,["textContent"]),(0,o.createElementVNode)("p",u,(0,o.toDisplayString)(e.__("Ensure your account is using a long, random password to stay secure.")),1)]),(0,o.createElementVNode)("div",p,[(0,o.createElementVNode)("label",h,(0,o.toDisplayString)(e.__("Current Password")),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{"onUpdate:modelValue":t[0]||(t[0]=t=>e.form.current_password=t),id:"current_password",name:"current_password",type:"password",autocomplete:"current-password",class:(0,o.normalizeClass)(["form-control form-input form-control-bordered w-full",{"form-control-bordered-error":e.form.errors.has("current_password")}])},null,2),[[o.vModelText,e.form.current_password]]),e.form.errors.has("current_password")?((0,o.openBlock)(),(0,o.createBlock)(x,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.form.errors.first("current_password")),1)])),_:1})):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("div",m,[(0,o.createElementVNode)("label",f,(0,o.toDisplayString)(e.__("Password")),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{"onUpdate:modelValue":t[1]||(t[1]=t=>e.form.password=t),id:"password",name:"password",type:"password",autocomplete:"new-password",class:(0,o.normalizeClass)(["form-control form-input form-control-bordered w-full",{"form-control-bordered-error":e.form.errors.has("password")}])},null,2),[[o.vModelText,e.form.password]]),e.form.errors.has("password")?((0,o.openBlock)(),(0,o.createBlock)(x,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.form.errors.first("password")),1)])),_:1})):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("div",v,[(0,o.createElementVNode)("label",g,(0,o.toDisplayString)(e.__("Confirm Password")),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{"onUpdate:modelValue":t[2]||(t[2]=t=>e.form.password_confirmation=t),id:"password_confirmation",name:"password_confirmation",type:"password",autocomplete:"new-password",class:(0,o.normalizeClass)(["form-control form-input form-control-bordered w-full",{"form-control-bordered-error":e.form.errors.has("password_confirmation")}])},null,2),[[o.vModelText,e.form.password_confirmation]]),e.form.errors.has("password_confirmation")?((0,o.openBlock)(),(0,o.createBlock)(x,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.form.errors.first("password_confirmation")),1)])),_:1})):(0,o.createCommentVNode)("",!0)])]),(0,o.createElementVNode)("div",y,[(0,o.createVNode)(N,{type:"submit",loading:e.form.processing,label:e.__("Save")},null,8,["loading","label"])])],32)])),_:1})])])}],["__file","UserSecurityUpdatePasswords.vue"]])},2202:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i=["src"],l={key:1},a={key:2,class:"flex items-center text-sm mt-3"},n=["dusk"],s={class:"class mt-1"};var c=r(74640),d=r(35229);const u={components:{Icon:c.Icon},mixins:[d.S0],props:["index","resource","resourceName","resourceId","field"],methods:{download(){const{resourceName:e,resourceId:t}=this,r=this.field.attribute;let o=document.createElement("a");o.href=`/nova-api/${e}/${t}/download/${r}`,o.download="download",document.body.appendChild(o),o.click(),document.body.removeChild(o)}},computed:{hasPreviewableAudio(){return null!=this.field.previewUrl},shouldShowToolbar(){return Boolean(this.field.downloadable&&this.fieldHasValue)},defaultAttributes(){return{src:this.field.previewUrl,autoplay:this.field.autoplay,preload:this.field.preload}}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("Icon"),h=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(h,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[u.hasPreviewableAudio?((0,o.openBlock)(),(0,o.createElementBlock)("audio",(0,o.mergeProps)({key:0},u.defaultAttributes,{class:"w-full",src:r.field.previewUrl,controls:"",controlslist:"nodownload"}),null,16,i)):(0,o.createCommentVNode)("",!0),u.hasPreviewableAudio?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createElementBlock)("span",l,"—")),u.shouldShowToolbar?((0,o.openBlock)(),(0,o.createElementBlock)("p",a,[r.field.downloadable?((0,o.openBlock)(),(0,o.createElementBlock)("a",{key:0,dusk:r.field.attribute+"-download-link",onKeydown:t[0]||(t[0]=(0,o.withKeys)((0,o.withModifiers)(((...e)=>u.download&&u.download(...e)),["prevent"]),["enter"])),onClick:t[1]||(t[1]=(0,o.withModifiers)(((...e)=>u.download&&u.download(...e)),["prevent"])),tabindex:"0",class:"cursor-pointer text-gray-500 inline-flex items-center"},[(0,o.createVNode)(p,{name:"download",type:"micro",class:"mr-2"}),(0,o.createElementVNode)("span",s,(0,o.toDisplayString)(e.__("Download")),1)],40,n)):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0)])),_:1},8,["index","field"])}],["__file","AudioField.vue"]])},77421:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={key:0,class:"mr-1 -ml-1"};const l={components:{Icon:r(74640).Icon},props:["index","resource","resourceName","resourceId","field"]};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("Icon"),c=(0,o.resolveComponent)("Badge"),d=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(d,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[(0,o.createVNode)(c,{class:"mt-1",label:r.field.label,"extra-classes":r.field.typeClass},{icon:(0,o.withCtx)((()=>[r.field.icon?((0,o.openBlock)(),(0,o.createElementBlock)("span",i,[(0,o.createVNode)(s,{name:r.field.icon,type:"solid",class:"inline-block"},null,8,["name"])])):(0,o.createCommentVNode)("",!0)])),_:1},8,["label","extra-classes"])])),_:1},8,["index","field"])}],["__file","BadgeField.vue"]])},71818:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={key:0},l={key:1},a={key:2};const n={props:["index","resource","resourceName","resourceId","field"]};const s=(0,r(66262).A)(n,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("Link"),u=(0,o.resolveComponent)("RelationPeek"),p=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(p,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[r.field.viewable&&r.field.value?((0,o.openBlock)(),(0,o.createElementBlock)("span",i,[r.field.peekable&&r.field.hasFieldsToPeekAt?((0,o.openBlock)(),(0,o.createBlock)(u,{key:0,"resource-name":r.field.resourceName,"resource-id":r.field.belongsToId,resource:r.resource},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(d,{onClick:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),href:e.$url(`/resources/${r.field.resourceName}/${r.field.belongsToId}`),class:"link-default"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.field.value),1)])),_:1},8,["href"])])),_:1},8,["resource-name","resource-id","resource"])):((0,o.openBlock)(),(0,o.createBlock)(d,{key:1,href:e.$url(`/resources/${r.field.resourceName}/${r.field.belongsToId}`),class:"link-default"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.field.value),1)])),_:1},8,["href"]))])):r.field.value?((0,o.openBlock)(),(0,o.createElementBlock)("p",l,(0,o.toDisplayString)(r.field.value),1)):((0,o.openBlock)(),(0,o.createElementBlock)("p",a,"—"))])),_:1},8,["index","field"])}],["__file","BelongsToField.vue"]])},40605:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={emits:["actionExecuted"],props:["resourceName","resourceId","resource","field"],methods:{actionExecuted(){this.$emit("actionExecuted")}}};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("ResourceIndex");return(0,o.openBlock)(),(0,o.createBlock)(n,{field:r.field,"resource-name":r.field.resourceName,"via-resource":r.resourceName,"via-resource-id":r.resourceId,"via-relationship":r.field.belongsToManyRelationship,"relationship-type":"belongsToMany",onActionExecuted:a.actionExecuted,"load-cards":!1,initialPerPage:r.field.perPage||5,"should-override-meta":!1,collapsable:r.field.collapsable},null,8,["field","resource-name","via-resource","via-resource-id","via-relationship","onActionExecuted","initialPerPage","collapsable"])}],["__file","BelongsToManyField.vue"]])},3001:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["index","resource","resourceName","resourceId","field"],computed:{label(){return 1==this.field.value?this.__("Yes"):this.__("No")}}};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("IconBoolean"),s=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(s,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[(0,o.createVNode)(n,{value:r.field.value,nullable:r.field.nullable},null,8,["value","nullable"])])),_:1},8,["index","field"])}],["__file","BooleanField.vue"]])},35336:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i={key:0,class:"space-y-2"},l={key:1};const a={props:["index","resource","resourceName","resourceId","field"],data:()=>({value:[],classes:{true:"text-green-500",false:"text-red-500"}}),created(){this.field.value=this.field.value||{},this.value=this.field.options.filter((e=>(!0!==this.field.hideFalseValues||!1!==e.checked)&&(!0!==this.field.hideTrueValues||!0!==e.checked))).map((e=>({name:e.name,label:e.label,checked:this.field.value[e.name]||!1})))}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("IconBoolean"),d=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(d,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[e.value.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("ul",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.value,((t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("li",{key:r,class:(0,o.normalizeClass)(["flex items-center rounded-full font-bold text-sm leading-tight space-x-2",e.classes[t.checked]])},[(0,o.createVNode)(c,{class:"flex-none",value:t.checked},null,8,["value"]),(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(t.label),1)],2)))),128))])):((0,o.openBlock)(),(0,o.createElementBlock)("span",l,(0,o.toDisplayString)(this.field.noValueText),1))])),_:1},8,["index","field"])}],["__file","BooleanGroupField.vue"]])},35480:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726);const i={key:0,class:"px-0 overflow-hidden form-input form-control-bordered"},l={ref:"theTextarea"},a={key:1};var n=r(15237),s=r.n(n);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function d(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function u(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const p={mixins:[r(35229).S0],props:["index","resource","resourceName","resourceId","field"],codemirror:null,mounted(){const e=this.fieldValue;if(null!==e){const t=d(d({tabSize:4,indentWithTabs:!0,lineWrapping:!0,lineNumbers:!0,theme:"dracula"},this.field.options),{},{readOnly:!0,tabindex:"-1"});this.codemirror=s().fromTextArea(this.$refs.theTextarea,t),this.codemirror?.getDoc().setValue(e),this.codemirror?.setSize("100%",this.field.height)}}};const h=(0,r(66262).A)(p,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(d,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[e.fieldValue?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("textarea",l,null,512)])):((0,o.openBlock)(),(0,o.createElementBlock)("p",a,"—"))])),_:1},8,["index","field"])}],["__file","CodeField.vue"]])},12310:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"rounded-lg inline-flex items-center justify-center border border-60 p-1"};const l={props:["index","resource","resourceName","resourceId","field"]};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(s,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("span",{class:"block w-6 h-6",style:(0,o.normalizeStyle)({borderRadius:"5px",backgroundColor:r.field.value})},null,4)])])),_:1},8,["index","field"])}],["__file","ColorField.vue"]])},43175:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["index","resource","resourceName","resourceId","field"]};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(n,{index:r.index,field:r.field},null,8,["index","field"])}],["__file","CurrencyField.vue"]])},46960:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i=["title"],l={key:1};var a=r(91272);const n={mixins:[r(35229).S0],props:["index","resource","resourceName","resourceId","field"],computed:{formattedDate(){if(this.field.usesCustomizedDisplay)return this.field.displayedAs;return a.c9.fromISO(this.field.value).toLocaleString({year:"numeric",month:"2-digit",day:"2-digit"})}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(c,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[e.fieldHasValue||e.usesCustomizedDisplay?((0,o.openBlock)(),(0,o.createElementBlock)("p",{key:0,title:r.field.value},(0,o.toDisplayString)(s.formattedDate),9,i)):((0,o.openBlock)(),(0,o.createElementBlock)("p",l,"—"))])),_:1},8,["index","field"])}],["__file","DateField.vue"]])},74405:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i=["title"],l={key:1};var a=r(91272);const n={mixins:[r(35229).S0],props:["index","resource","resourceName","resourceId","field"],computed:{formattedDateTime(){return this.usesCustomizedDisplay?this.field.displayedAs:a.c9.fromISO(this.field.value).setZone(this.timezone).toLocaleString({year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",timeZoneName:"short"})},timezone:()=>Nova.config("userTimezone")||Nova.config("timezone")}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(c,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[e.fieldHasValue||e.usesCustomizedDisplay?((0,o.openBlock)(),(0,o.createElementBlock)("p",{key:0,title:r.field.value},(0,o.toDisplayString)(s.formattedDateTime),9,i)):((0,o.openBlock)(),(0,o.createElementBlock)("p",l,"—"))])),_:1},8,["index","field"])}],["__file","DateTimeField.vue"]])},69556:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={key:0,class:"flex items-center"},l=["href"],a={key:1};var n=r(35229);const s={mixins:[n.nl,n.S0],props:["index","resource","resourceName","resourceId","field"],methods:{copy(){this.copyValueToClipboard(this.field.value)}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("CopyButton"),u=(0,o.resolveComponent)("PanelItem"),p=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createBlock)(u,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[e.fieldHasValue?((0,o.openBlock)(),(0,o.createElementBlock)("p",i,[(0,o.createElementVNode)("a",{href:`mailto:${r.field.value}`,class:"link-default"},(0,o.toDisplayString)(e.fieldValue),9,l),e.fieldHasValue&&r.field.copyable&&!e.shouldDisplayAsHtml?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(d,{key:0,onClick:(0,o.withModifiers)(c.copy,["prevent","stop"]),class:"mx-0"},null,8,["onClick"])),[[p,e.__("Copy to clipboard")]]):(0,o.createCommentVNode)("",!0)])):((0,o.openBlock)(),(0,o.createElementBlock)("p",a,"—"))])),_:1},8,["index","field"])}],["__file","EmailField.vue"]])},92048:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i={key:1,class:"break-words"},l={key:2},a={key:3,class:"flex items-center text-sm mt-3"},n=["dusk"],s={class:"class mt-1"};var c=r(74640),d=r(35229);const u={components:{Icon:c.Icon},mixins:[d.S0],props:["index","resource","resourceName","resourceId","field"],methods:{download(){const{resourceName:e,resourceId:t}=this,r=this.fieldAttribute;let o=document.createElement("a");o.href=`/nova-api/${e}/${t}/download/${r}`,o.download="download",document.body.appendChild(o),o.click(),document.body.removeChild(o)}},computed:{hasValue(){return Boolean(this.field.value||this.imageUrl)},shouldShowLoader(){return this.imageUrl},shouldShowToolbar(){return Boolean(this.field.downloadable&&this.hasValue)},imageUrl(){return this.field.previewUrl||this.field.thumbnailUrl},isVaporField(){return"vapor-file-field"===this.field.component}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("ImageLoader"),h=(0,o.resolveComponent)("Icon"),m=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(m,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[u.shouldShowLoader?((0,o.openBlock)(),(0,o.createBlock)(p,{key:0,src:u.imageUrl,maxWidth:r.field.maxWidth||r.field.detailWidth,rounded:r.field.rounded,aspect:r.field.aspect},null,8,["src","maxWidth","rounded","aspect"])):(0,o.createCommentVNode)("",!0),e.fieldValue&&!u.imageUrl?((0,o.openBlock)(),(0,o.createElementBlock)("span",i,(0,o.toDisplayString)(e.fieldValue),1)):(0,o.createCommentVNode)("",!0),e.fieldValue||u.imageUrl?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createElementBlock)("span",l,"—")),u.shouldShowToolbar?((0,o.openBlock)(),(0,o.createElementBlock)("p",a,[r.field.downloadable?((0,o.openBlock)(),(0,o.createElementBlock)("a",{key:0,dusk:r.field.attribute+"-download-link",onKeydown:t[0]||(t[0]=(0,o.withKeys)((0,o.withModifiers)(((...e)=>u.download&&u.download(...e)),["prevent"]),["enter"])),onClick:t[1]||(t[1]=(0,o.withModifiers)(((...e)=>u.download&&u.download(...e)),["prevent"])),tabindex:"0",class:"cursor-pointer text-gray-500 inline-flex items-center"},[(0,o.createVNode)(h,{name:"download",type:"micro",class:"mr-2"}),(0,o.createElementVNode)("span",s,(0,o.toDisplayString)(e.__("Download")),1)],40,n)):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0)])),_:1},8,["index","field"])}],["__file","FileField.vue"]])},70813:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function l(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach((function(t){a(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function a(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const n={emits:["actionExecuted"],props:l(l({},(0,r(35229).rr)(["resourceName","resourceId","field"])),{},{resource:{}}),methods:{actionExecuted(){this.$emit("actionExecuted")}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("ResourceIndex");return(0,o.openBlock)(),(0,o.createBlock)(n,{field:e.field,"resource-name":e.field.resourceName,"via-resource":e.resourceName,"via-resource-id":e.resourceId,"via-relationship":e.field.hasManyRelationship,"relationship-type":"hasMany",onActionExecuted:a.actionExecuted,"load-cards":!1,initialPerPage:e.field.perPage||5,"should-override-meta":!1,collapsable:e.field.collapsable},null,8,["field","resource-name","via-resource","via-resource-id","via-relationship","onActionExecuted","initialPerPage","collapsable"])}],["__file","HasManyField.vue"]])},70425:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={emits:["actionExecuted"],props:["resourceName","resourceId","resource","field"],methods:{actionExecuted(){this.$emit("actionExecuted")}}};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("ResourceIndex");return(0,o.openBlock)(),(0,o.createBlock)(n,{field:r.field,"resource-name":r.field.resourceName,"via-resource":r.resourceName,"via-resource-id":r.resourceId,"via-relationship":r.field.hasManyThroughRelationship,"relationship-type":"hasManyThrough",onActionExecuted:a.actionExecuted,"load-cards":!1,initialPerPage:r.field.perPage||5,"should-override-meta":!1,collapsable:r.field.collapsable},null,8,["field","resource-name","via-resource","via-resource-id","via-relationship","onActionExecuted","initialPerPage","collapsable"])}],["__file","HasManyThroughField.vue"]])},7746:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i=["dusk","data-relationship"],l={key:1};const a={props:["resourceName","resourceId","resource","field"],data:()=>({showActionDropdown:!0}),computed:{authorizedToCreate(){return this.field.authorizedToCreate},createButtonLabel(){return this.field.createButtonLabel},hasRelation(){return null!=this.field.hasOneId},singularName(){return this.field.singularLabel},viaResourceId(){return this.resource.id.value},viaRelationship(){return this.field.hasOneRelationship}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Heading"),d=(0,o.resolveComponent)("IndexEmptyDialog"),u=(0,o.resolveComponent)("Card"),p=(0,o.resolveComponent)("ResourceDetail");return r.field.authorizedToView?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,class:"relative",dusk:r.field.resourceName+"-index-component","data-relationship":s.viaRelationship},[s.hasRelation?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[(0,o.createVNode)(p,{"resource-name":r.field.resourceName,"resource-id":r.field.hasOneId,"via-resource":r.resourceName,"via-resource-id":s.viaResourceId,"via-relationship":s.viaRelationship,"relationship-type":r.field.relationshipType,"show-action-dropdown":e.showActionDropdown,"show-view-link":!0},null,8,["resource-name","resource-id","via-resource","via-resource-id","via-relationship","relationship-type","show-action-dropdown"])])):((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:0},[(0,o.createVNode)(c,{level:1,class:"mb-3 flex items-center"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.field.singularLabel),1)])),_:1}),(0,o.createVNode)(u,null,{default:(0,o.withCtx)((()=>[(0,o.createVNode)(d,{"create-button-label":s.createButtonLabel,"singular-name":s.singularName,"resource-name":r.field.resourceName,"via-resource":r.resourceName,"via-resource-id":s.viaResourceId,"via-relationship":s.viaRelationship,"relationship-type":r.field.relationshipType,"authorized-to-create":s.authorizedToCreate,"authorized-to-relate":!0},null,8,["create-button-label","singular-name","resource-name","via-resource","via-resource-id","via-relationship","relationship-type","authorized-to-create"])])),_:1})],64))],8,i)):(0,o.createCommentVNode)("",!0)}],["__file","HasOneField.vue"]])},8588:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i=["dusk","data-relationship"],l={key:1};const a={props:["resourceName","resourceId","resource","field"],computed:{authorizedToCreate(){return this.field.authorizedToCreate},createButtonLabel(){return this.field.createButtonLabel},hasRelation(){return null!=this.field.hasOneThroughId},singularName(){return this.field.singularLabel},viaResourceId(){return this.resource.id.value},viaRelationship(){return this.field.hasOneThroughRelationship}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Heading"),d=(0,o.resolveComponent)("IndexEmptyDialog"),u=(0,o.resolveComponent)("Card"),p=(0,o.resolveComponent)("ResourceDetail");return r.field.authorizedToView?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,class:"relative",dusk:r.field.resourceName+"-index-component","data-relationship":s.viaRelationship},[s.hasRelation?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[(0,o.createVNode)(p,{"resource-name":r.field.resourceName,"resource-id":r.field.hasOneThroughId,"via-resource":r.resourceName,"via-resource-id":s.viaResourceId,"via-relationship":s.viaRelationship,"relationship-type":r.field.relationshipType,"show-view-link":!0},null,8,["resource-name","resource-id","via-resource","via-resource-id","via-relationship","relationship-type"])])):((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:0},[(0,o.createVNode)(c,{level:1,class:"mb-3 flex items-center"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.field.singularLabel),1)])),_:1}),(0,o.createVNode)(u,null,{default:(0,o.withCtx)((()=>[(0,o.createVNode)(d,{"create-button-label":s.createButtonLabel,"singular-name":s.singularName,"resource-name":r.field.resourceName,"via-resource":r.resourceName,"via-resource-id":s.viaResourceId,"via-relationship":s.viaRelationship,"relationship-type":r.field.relationshipType,"authorized-to-create":!1,"authorized-to-relate":!1},null,8,["create-button-label","singular-name","resource-name","via-resource","via-resource-id","via-relationship","relationship-type"])])),_:1})],64))],8,i)):(0,o.createCommentVNode)("",!0)}],["__file","HasOneThroughField.vue"]])},26949:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={class:"w-full py-4 px-6"},l=["innerHTML"],a={key:2};var n=r(70393);const s={props:["index","resource","resourceName","resourceId","field"],computed:{fieldValue(){return!!(0,n.A)(this.field.value)&&String(this.field.value)},shouldDisplayAsHtml(){return this.field.asHtml}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("Heading");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(["-mx-6",{"border-t border-gray-100 dark:border-gray-700":0!==r.index,"-mt-2":0===r.index}])},[(0,o.createElementVNode)("div",i,[(0,o.renderSlot)(e.$slots,"value",{},(()=>[c.fieldValue&&!c.shouldDisplayAsHtml?((0,o.openBlock)(),(0,o.createBlock)(d,{key:0,level:3},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(c.fieldValue),1)])),_:1})):c.fieldValue&&c.shouldDisplayAsHtml?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:1,innerHTML:r.field.value},null,8,l)):((0,o.openBlock)(),(0,o.createElementBlock)("p",a,"—"))]))])],2)}],["__file","HeadingField.vue"]])},41968:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"hidden"};const l={props:["index","resource","resourceName","resourceId","field"]};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){return(0,o.openBlock)(),(0,o.createElementBlock)("div",i)}],["__file","HiddenField.vue"]])},13699:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["index","resource","resourceName","resourceId","field"]};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(n,{index:r.index,field:r.field},null,8,["index","field"])}],["__file","IdField.vue"]])},16979:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"bg-gray-50 dark:bg-gray-700 overflow-hidden key-value-items"};const l={props:["index","resource","resourceName","resourceId","field"],data:()=>({theData:[]}),created(){this.theData=Object.entries(this.field.value||{}).map((([e,t])=>({key:`${e}`,value:t})))}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("FormKeyValueHeader"),c=(0,o.resolveComponent)("FormKeyValueItem"),d=(0,o.resolveComponent)("FormKeyValueTable"),u=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(u,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[e.theData.length>0?((0,o.openBlock)(),(0,o.createBlock)(d,{key:0,"edit-mode":!1,class:"overflow-hidden"},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(s,{"key-label":r.field.keyLabel,"value-label":r.field.valueLabel},null,8,["key-label","value-label"]),(0,o.createElementVNode)("div",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.theData,((e,t)=>((0,o.openBlock)(),(0,o.createBlock)(c,{index:t,item:e,"edit-mode":!1,key:e.key},null,8,["index","item"])))),128))])])),_:1})):(0,o.createCommentVNode)("",!0)])),_:1},8,["index","field"])}],["__file","KeyValueField.vue"]])},21199:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["index","resource","resourceName","resourceId","field"],computed:{excerpt(){return this.field.previewFor}}};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("Excerpt"),s=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(s,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[(0,o.createVNode)(n,{content:a.excerpt,"should-show":r.field.shouldShow},null,8,["content","should-show"])])),_:1},8,["index","field"])}],["__file","MarkdownField.vue"]])},50769:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={key:1},l={key:2},a={key:3};const n={props:["index","resourceName","resourceId","field"]};const s=(0,r(66262).A)(n,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("Link"),u=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(u,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[r.field.viewable&&r.field.value?((0,o.openBlock)(),(0,o.createBlock)(d,{key:0,href:e.$url(`/resources/${r.field.resourceName}/${r.field.morphToId}`),class:"no-underline font-bold link-default"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.field.name)+": "+(0,o.toDisplayString)(r.field.value)+" ("+(0,o.toDisplayString)(r.field.resourceLabel)+") ",1)])),_:1},8,["href"])):r.field.morphToId&&null!==r.field.resourceLabel?((0,o.openBlock)(),(0,o.createElementBlock)("p",i,(0,o.toDisplayString)(r.field.name)+": "+(0,o.toDisplayString)(r.field.morphToId)+" ("+(0,o.toDisplayString)(r.field.resourceLabel)+") ",1)):r.field.morphToId&&null===r.field.resourceLabel?((0,o.openBlock)(),(0,o.createElementBlock)("p",l,(0,o.toDisplayString)(r.field.morphToType)+": "+(0,o.toDisplayString)(r.field.morphToId),1)):((0,o.openBlock)(),(0,o.createElementBlock)("p",a,"—"))])),_:1},8,["index","field"])}],["__file","MorphToActionTargetField.vue"]])},18318:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={key:0},l={key:1},a={key:2};const n={props:["index","resource","resourceName","resourceId","field"]};const s=(0,r(66262).A)(n,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("Link"),u=(0,o.resolveComponent)("RelationPeek"),p=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(p,{index:r.index,field:r.field,"field-name":r.field.name},{value:(0,o.withCtx)((()=>[r.field.viewable&&r.field.value?((0,o.openBlock)(),(0,o.createElementBlock)("span",i,[r.field.peekable&&r.field.hasFieldsToPeekAt?((0,o.openBlock)(),(0,o.createBlock)(u,{key:0,"resource-name":r.field.resourceName,"resource-id":r.field.morphToId,resource:r.resource},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(d,{onClick:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),href:e.$url(`/resources/${r.field.resourceName}/${r.field.morphToId}`),class:"link-default"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.field.resourceLabel)+": "+(0,o.toDisplayString)(r.field.value),1)])),_:1},8,["href"])])),_:1},8,["resource-name","resource-id","resource"])):((0,o.openBlock)(),(0,o.createBlock)(d,{key:1,href:e.$url(`/resources/${r.field.resourceName}/${r.field.morphToId}`),class:"link-default"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.field.resourceLabel)+": "+(0,o.toDisplayString)(r.field.value),1)])),_:1},8,["href"]))])):r.field.value?((0,o.openBlock)(),(0,o.createElementBlock)("p",l,(0,o.toDisplayString)(r.field.resourceLabel||r.field.morphToType)+": "+(0,o.toDisplayString)(r.field.value),1)):((0,o.openBlock)(),(0,o.createElementBlock)("p",a,"—"))])),_:1},8,["index","field","field-name"])}],["__file","MorphToField.vue"]])},59958:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={emits:["actionExecuted"],props:["resourceName","resourceId","resource","field"],methods:{actionExecuted(){this.$emit("actionExecuted")}}};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("ResourceIndex");return(0,o.openBlock)(),(0,o.createBlock)(n,{field:r.field,"resource-name":r.field.resourceName,"via-resource":r.resourceName,"via-resource-id":r.resourceId,"via-relationship":r.field.morphToManyRelationship,"relationship-type":"morphToMany",onActionExecuted:a.actionExecuted,"load-cards":!1,initialPerPage:r.field.perPage||5,"should-override-meta":!1,collapsable:r.field.collapsable},null,8,["field","resource-name","via-resource","via-resource-id","via-relationship","onActionExecuted","initialPerPage","collapsable"])}],["__file","MorphToManyField.vue"]])},89535:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i=["textContent"];const l={mixins:[r(35229).S0],props:["index","resource","resourceName","resourceId","field"],computed:{fieldValues(){let e=[];return this.field.options.forEach((t=>{this.isEqualsToValue(t.value)&&e.push(t.label)})),e}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(s,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(n.fieldValues,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("span",{textContent:(0,o.toDisplayString)(e),class:"inline-block text-sm mb-1 mr-2 px-2 py-0 bg-primary-500 text-white dark:text-gray-900 rounded"},null,8,i)))),256))])),_:1},8,["index","field"])}],["__file","MultiSelectField.vue"]])},73437:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726);const i=["dusk"],l={class:"flex items-center"},a=["aria-label","aria-expanded"],n=["innerHTML"],s={key:0,class:"-mx-6 border-t border-gray-100 dark:border-gray-700 text-center rounded-b"};var c=r(35229);const d={mixins:[c.pJ,c.x7],methods:{resolveComponentName:e=>e.prefixComponent?"detail-"+e.component:e.component,showAllFields(){return this.panel.limit=0}},computed:{localStorageKey(){return`nova.panels.${this.panel.attribute}.collapsed`},collapsedByDefault(){return this.panel?.collapsedByDefault??!1},fields(){return this.panel.limit>0?this.panel.fields.slice(0,this.panel.limit):this.panel.fields},shouldShowShowAllFieldsButton(){return this.panel.limit>0}}};const u=(0,r(66262).A)(d,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("Heading"),h=(0,o.resolveComponent)("CollapseButton"),m=(0,o.resolveComponent)("Card");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{dusk:`${e.panel.attribute}-panel`},[(0,o.renderSlot)(e.$slots,"default",{},(()=>[(0,o.createElementVNode)("div",l,[(0,o.createVNode)(p,{level:1,textContent:(0,o.toDisplayString)(e.panel.name)},null,8,["textContent"]),e.panel.collapsable?((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:0,onClick:t[0]||(t[0]=(...t)=>e.toggleCollapse&&e.toggleCollapse(...t)),class:"rounded border border-transparent h-6 w-6 ml-1 inline-flex items-center justify-center focus:outline-none focus:ring focus:ring-primary-200","aria-label":e.__("Toggle Collapsed"),"aria-expanded":!1===e.collapsed?"true":"false"},[(0,o.createVNode)(h,{collapsed:e.collapsed},null,8,["collapsed"])],8,a)):(0,o.createCommentVNode)("",!0)]),e.panel.helpText&&!e.collapsed?((0,o.openBlock)(),(0,o.createElementBlock)("p",{key:0,class:(0,o.normalizeClass)(["text-gray-500 text-sm font-semibold italic",e.panel.helpText?"mt-1":"mt-3"]),innerHTML:e.panel.helpText},null,10,n)):(0,o.createCommentVNode)("",!0)])),!e.collapsed&&u.fields.length>0?((0,o.openBlock)(),(0,o.createBlock)(m,{key:0,class:"mt-3 py-2 px-6 divide-y divide-gray-100 dark:divide-gray-700"},{default:(0,o.withCtx)((()=>[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(u.fields,((t,r)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(u.resolveComponentName(t)),{key:r,index:r,"resource-name":e.resourceName,"resource-id":e.resourceId,resource:e.resource,field:t,onActionExecuted:e.actionExecuted},null,40,["index","resource-name","resource-id","resource","field","onActionExecuted"])))),128)),u.shouldShowShowAllFieldsButton?((0,o.openBlock)(),(0,o.createElementBlock)("div",s,[(0,o.createElementVNode)("button",{type:"button",class:"block w-full text-sm link-default font-bold py-2 -mb-2",onClick:t[1]||(t[1]=(...e)=>u.showAllFields&&u.showAllFields(...e))},(0,o.toDisplayString)(e.__("Show All Fields")),1)])):(0,o.createCommentVNode)("",!0)])),_:1})):(0,o.createCommentVNode)("",!0)],8,i)}],["__file","Panel.vue"]])},16181:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["index","resource","resourceName","resourceId","field"]};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(n,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>t[0]||(t[0]=[(0,o.createElementVNode)("p",null," ········· ",-1)]))),_:1},8,["index","field"])}],["__file","PasswordField.vue"]])},63726:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i=["dusk"];const l={mixins:[r(35229).x7],computed:{field(){return this.panel.fields[0]}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){return(0,o.openBlock)(),(0,o.createElementBlock)("div",{dusk:`${e.panel.attribute}-relationship-panel`},[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(`detail-${n.field.component}`),{key:`${n.field.attribute}:${e.resourceId}`,"resource-name":e.resourceName,"resource-id":e.resourceId,resource:e.resource,field:n.field,onActionExecuted:e.actionExecuted},null,40,["resource-name","resource-id","resource","field","onActionExecuted"]))],8,i)}],["__file","RelationshipPanel.vue"]])},22092:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>d});var o=r(29726);const i=["dusk"],l={class:"bg-white dark:bg-gray-800 border border-gray-200 dark:border-gray-700 rounded divide-y divide-gray-200 dark:divide-gray-700"},a={class:"grid grid-cols-full divide-y divide-gray-100 dark:divide-gray-700 px-6"},n={key:1};var s=r(35229);const c={mixins:[s.x7,s.S0],props:["index","resource","resourceName","resourceId","field"],methods:{resolveComponentName:e=>e.prefixComponent?"detail-"+e.component:e.component},computed:{fieldHasValue(){return this.field.value.length>0}}};const d=(0,r(66262).A)(c,[["render",function(e,t,r,s,c,d){const u=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(u,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[d.fieldHasValue?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,class:"space-y-4",dusk:e.fieldAttribute},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.field.value,(t=>((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[(0,o.createElementVNode)("div",a,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(t.fields,((t,i)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",null,[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(d.resolveComponentName(t)),{key:r.index,index:r.index,"resource-name":r.resourceName,"resource-id":r.resourceId,resource:r.resource,field:t,onActionExecuted:e.actionExecuted},null,40,["index","resource-name","resource-id","resource","field","onActionExecuted"]))])))),256))])])))),256))],8,i)):((0,o.openBlock)(),(0,o.createElementBlock)("p",n,"—"))])),_:1},8,["index","field"])}],["__file","RepeaterField.vue"]])},89032:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["index","resource","resourceName","resourceId","field"]};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(n,{index:r.index,field:r.field},null,8,["index","field"])}],["__file","SelectField.vue"]])},79175:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>i});const o={extends:r(21738).default};const i=(0,r(66262).A)(o,[["__file","SlugField.vue"]])},71788:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);var i=r(27717);r(27554);const l={props:["index","resource","resourceName","resourceId","field"],data:()=>({chartist:null}),watch:{"field.data":function(e,t){this.renderChart()}},methods:{renderChart(){this.chartist.update(this.field.data)}},mounted(){const e=this.chartStyle;this.chartist=new e(this.$refs.chart,{series:[this.field.data]},{height:this.chartHeight,width:this.chartWidth,showPoint:!1,fullWidth:!0,chartPadding:{top:0,right:0,bottom:0,left:0},axisX:{showGrid:!1,showLabel:!1,offset:0},axisY:{showGrid:!1,showLabel:!1,offset:0}})},computed:{hasData(){return this.field.data.length>0},chartStyle(){let e=this.field.chartStyle.toLowerCase();return["line","bar"].includes(e)&&"line"!==e?i.Es:i.bl},chartHeight(){return this.field.height?`${this.field.height}px`:"120px"},chartWidth(){if(this.field.width)return`${this.field.width}px`}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(n,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",{ref:"chart",class:"ct-chart",style:(0,o.normalizeStyle)({width:a.chartWidth,height:a.chartHeight})},null,4)])),_:1},8,["index","field"])}],["__file","SparklineField.vue"]])},58403:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={key:1};const l={props:["index","resource","resourceName","resourceId","field"],computed:{hasValue(){return this.field.lines}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(s,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[n.hasValue?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,class:(0,o.normalizeClass)([`text-${r.field.textAlign}`,"leading-normal"])},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.field.lines,(e=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(`index-${e.component}`),{key:e.value,field:e,resourceName:r.resourceName},null,8,["field","resourceName"])))),128))],2)):((0,o.openBlock)(),(0,o.createElementBlock)("p",i,"—"))])),_:1},8,["index","field"])}],["__file","StackField.vue"]])},12136:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={class:"mr-1 -ml-1"},l={key:1};var a=r(74640),n=r(35229);const s={components:{Icon:a.Icon},mixins:[n.S0],props:["index","resource","resourceName","resourceId","field"]};const c=(0,r(66262).A)(s,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Loader"),d=(0,o.resolveComponent)("Icon"),u=(0,o.resolveComponent)("Badge"),p=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(p,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[e.fieldHasValue?((0,o.openBlock)(),(0,o.createBlock)(u,{key:0,class:(0,o.normalizeClass)(["whitespace-nowrap inline-flex items-center",r.field.typeClass])},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",i,["loading"==r.field.type?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,width:"20",class:"mr-1"})):(0,o.createCommentVNode)("",!0),"failed"==r.field.type?((0,o.openBlock)(),(0,o.createBlock)(d,{key:1,name:"exclamation-circle",type:"solid"})):(0,o.createCommentVNode)("",!0),"success"==r.field.type?((0,o.openBlock)(),(0,o.createBlock)(d,{key:2,name:"check-circle",type:"solid"})):(0,o.createCommentVNode)("",!0)]),(0,o.createTextVNode)(" "+(0,o.toDisplayString)(e.fieldValue),1)])),_:1},8,["class"])):((0,o.openBlock)(),(0,o.createElementBlock)("span",l,"—"))])),_:1},8,["index","field"])}],["__file","StatusField.vue"]])},91167:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>v});var o=r(29726),i=r(35229),l=r(14788),a=r(42877),n=r.n(a);function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function c(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const d=["dusk"],u=["innerHTML"],p=["dusk"],h={class:"capitalize"},m={class:"divide-y divide-gray-100 dark:divide-gray-700"},f={__name:"TabsPanel",props:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){c(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({name:{type:String,default:"Panel"},panel:{type:Object,required:!0},resource:{type:Object,required:!0}},(0,i.rr)(["mode","resourceName","resourceId","relatedResourceName","relatedResourceId","viaResource","viaResourceId","viaRelationship"])),emits:["actionExecuted"],setup(e){const t=e,r=(0,o.computed)((()=>t.panel.fields.reduce(((e,t)=>(t.tab?.attribute in e||(!0===t?.collapsable&&(t.collapsable=!1),e[t.tab.attribute]={name:t.tab,attribute:t.tab.attribute,position:t.tab.position,init:!1,listable:t.tab.listable,fields:[],meta:t.tab.meta,classes:"fields-tab"},["belongs-to-many-field","has-many-field","has-many-through-field","has-one-through-field","morph-to-many-field"].includes(t.component)&&(e[t.tab.attribute].classes="relationship-tab")),e[t.tab.attribute].fields.push(t),e)),{})));function i(e){return n()(e,[e=>e.position],["asc"])}function a(e){return e.prefixComponent?`detail-${e.component}`:e.component}return(t,n)=>{const s=(0,o.resolveComponent)("Heading");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:"tab-group",dusk:`${e.panel.attribute}-tab-panel`},[(0,o.createElementVNode)("div",null,[e.panel.showTitle?((0,o.openBlock)(),(0,o.createBlock)(s,{key:0,level:1,textContent:(0,o.toDisplayString)(e.panel.name)},null,8,["textContent"])):(0,o.createCommentVNode)("",!0),e.panel.helpText?((0,o.openBlock)(),(0,o.createElementBlock)("p",{key:1,class:(0,o.normalizeClass)(["text-gray-500 text-sm font-semibold italic",e.panel.helpText?"mt-2":"mt-3"]),innerHTML:e.panel.helpText},null,10,u)):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["tab-card",[e.panel.showTitle&&!e.panel.showToolbar?"mt-3":""]])},[(0,o.createVNode)((0,o.unref)(l.fu),null,{default:(0,o.withCtx)((()=>[(0,o.createVNode)((0,o.unref)(l.wb),{"aria-label":e.panel.name,class:"tab-menu divide-x dark:divide-gray-700 border-l-gray-200 border-r-gray-200 border-t-gray-200 border-b-gray-200 dark:border-l-gray-700 dark:border-r-gray-700 dark:border-t-gray-700 dark:border-b-gray-700"},{default:(0,o.withCtx)((()=>[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(i(r.value),((e,t)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(l.oz),{as:"template",key:t},{default:(0,o.withCtx)((({selected:t})=>[(0,o.createElementVNode)("button",{dusk:`${e.attribute}-tab-trigger`,class:(0,o.normalizeClass)([[t?"active text-primary-500 font-bold border-b-2 !border-b-primary-500":"text-gray-600 hover:text-gray-800 dark:text-gray-400 hover:dark:text-gray-200"],"tab-item"])},[(0,o.createElementVNode)("span",h,(0,o.toDisplayString)(e.meta.name),1)],10,p)])),_:2},1024)))),128))])),_:1},8,["aria-label"]),(0,o.createVNode)((0,o.unref)(l.T2),null,{default:(0,o.withCtx)((()=>[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(i(r.value),((r,i)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(l.Kp),{key:i,label:r.name,dusk:`${r.attribute}-tab-content`,class:(0,o.normalizeClass)([r.attribute,r.classes,"tab"])},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",m,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.fields,((i,l)=>((0,o.openBlock)(),(0,o.createBlock)(o.KeepAlive,{key:l},[((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(a(i)),{class:(0,o.normalizeClass)({"remove-bottom-border":l===r.fields.length-1}),field:i,index:l,resource:e.resource,"resource-id":t.resourceId,"resource-name":t.resourceName,onActionExecuted:n[0]||(n[0]=e=>t.$emit("actionExecuted"))},null,40,["class","field","index","resource","resource-id","resource-name"]))],1024)))),128))])])),_:2},1032,["label","dusk","class"])))),128))])),_:1})])),_:1})],2)],8,d)}}};const v=(0,r(66262).A)(f,[["__file","TabsPanel.vue"]])},82141:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={key:0};const l={props:["index","resource","resourceName","resourceId","field"]};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("TagGroup"),c=(0,o.resolveComponent)("TagList"),d=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(d,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[r.field.value.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,["group"===r.field.style?((0,o.openBlock)(),(0,o.createBlock)(s,{key:0,tags:r.field.value,"resource-name":r.field.resourceName,editable:!1,"with-preview":r.field.withPreview},null,8,["tags","resource-name","with-preview"])):(0,o.createCommentVNode)("",!0),"list"===r.field.style?((0,o.openBlock)(),(0,o.createBlock)(c,{key:1,tags:r.field.value,"resource-name":r.field.resourceName,editable:!1,"with-preview":r.field.withPreview},null,8,["tags","resource-name","with-preview"])):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0)])),_:1},8,["index","field"])}],["__file","TagField.vue"]])},21738:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["index","resource","resourceName","resourceId","field"]};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(n,{index:r.index,field:r.field},null,8,["index","field"])}],["__file","TextField.vue"]])},29765:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["index","resource","resourceName","resourceId","field"]};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("Excerpt"),s=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(s,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[(0,o.createVNode)(n,{content:r.field.value,"plain-text":!0,"should-show":r.field.shouldShow},null,8,["content","should-show"])])),_:1},8,["index","field"])}],["__file","TextareaField.vue"]])},96134:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["index","resource","resourceName","resourceId","field"]};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("Excerpt"),s=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(s,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[(0,o.createVNode)(n,{content:r.field.value,"should-show":r.field.shouldShow},null,8,["content","should-show"])])),_:1},8,["index","field"])}],["__file","TrixField.vue"]])},69928:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={key:0},l=["href"],a=["innerHTML"],n={key:2};const s={mixins:[r(35229).S0],props:["index","resource","resourceName","resourceId","field"]};const c=(0,r(66262).A)(s,[["render",function(e,t,r,s,c,d){const u=(0,o.resolveComponent)("PanelItem");return(0,o.openBlock)(),(0,o.createBlock)(u,{index:r.index,field:r.field},{value:(0,o.withCtx)((()=>[e.fieldHasValue&&!e.shouldDisplayAsHtml?((0,o.openBlock)(),(0,o.createElementBlock)("p",i,[(0,o.createElementVNode)("a",{class:"link-default",href:r.field.value,rel:"noreferrer noopener",target:"_blank"},(0,o.toDisplayString)(e.fieldValue),9,l)])):e.fieldValue&&e.shouldDisplayAsHtml?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:1,innerHTML:e.fieldValue},null,8,a)):((0,o.openBlock)(),(0,o.createElementBlock)("p",n,"—"))])),_:1},8,["index","field"])}],["__file","UrlField.vue"]])},92135:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>i});const o={extends:r(2202).default};const i=(0,r(66262).A)(o,[["__file","VaporAudioField.vue"]])},57562:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>i});const o={extends:r(92048).default};const i=(0,r(66262).A)(o,[["__file","VaporFileField.vue"]])},53941:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(83240),i=r(1242);function l(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function a(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?l(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):l(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function n(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const s={extends:o.default,methods:{getAvailableResources(e){let t=this.queryParams;return null!=e&&(t.first=!1,t.current=null,t.search=e),i.A.fetchAvailableResources(this.filter.resourceName,this.field.attribute,{params:a(a({},t),{},{component:this.field.component,viaRelationship:this.filter.viaRelationship})}).then((({data:{resources:e,softDeletes:t,withTrashed:r}})=>{this.isSearchable||(this.withTrashed=r),this.availableResources=e,this.softDeletes=t}))}}};const c=(0,r(66262).A)(s,[["__file","BelongsToField.vue"]])},43460:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"block"};const l={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},methods:{handleChange(){let e=this.nextValue(this.value);this.$emit("change",{filterClass:this.filterKey,value:e??""})},nextValue:e=>!0!==e&&(!1!==e||null)},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},field(){return this.filter.field},value(){let e=this.filter.currentValue;return!0===e||!1===e?e:null}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("IconBoolean"),c=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(c,null,{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",null,[(0,o.createElementVNode)("label",i,(0,o.toDisplayString)(n.filter.name),1),(0,o.createElementVNode)("button",{type:"button",onClick:t[0]||(t[0]=(...e)=>n.handleChange&&n.handleChange(...e)),class:"p-0 m-0"},[(0,o.createVNode)(s,{class:"mt-2",value:n.value,nullable:!0,dusk:n.filter.uniqueKey},null,8,["value","dusk"])])])])),_:1})}],["__file","BooleanField.vue"]])},28514:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"space-y-2"};const l={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},field(){return this.filter.field}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("IconBooleanOption"),c=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(c,null,{filter:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(n.field.options,(i=>((0,o.openBlock)(),(0,o.createBlock)(s,{dusk:`${n.filter.uniqueKey}-${i.value}-option`,"resource-name":r.resourceName,key:i.value,filter:n.filter,option:i,onChange:t[0]||(t[0]=t=>e.$emit("change")),label:"label"},null,8,["dusk","resource-name","filter","option"])))),128))])])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(n.filter.name),1)])),_:1})}],["__file","BooleanGroupField.vue"]])},78430:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>k});var o=r(29726);const i={class:"block"},l={class:"uppercase text-xs font-bold tracking-wide"},a=["dusk"],n={class:"block mt-2"},s={class:"uppercase text-xs font-bold tracking-wide"},c=["dusk"];var d=r(91272),u=r(38221),p=r.n(u),h=r(90179),m=r.n(h),f=r(70393);function v(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function g(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?v(Object(r),!0).forEach((function(t){y(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):v(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function y(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const b={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},data:()=>({startValue:null,endValue:null,debouncedEventEmitter:null}),created(){this.debouncedEventEmitter=p()((()=>this.emitFilterChange()),500),this.setCurrentFilterValue()},mounted(){Nova.$on("filter-reset",this.handleFilterReset)},beforeUnmount(){Nova.$off("filter-reset",this.handleFilterReset)},watch:{startValue(){this.debouncedEventEmitter()},endValue(){this.debouncedEventEmitter()}},methods:{setCurrentFilterValue(){let[e,t]=this.filter.currentValue||[null,null];this.startValue=(0,f.A)(e)?this.fromDateTimeISO(e).toISODate():null,this.endValue=(0,f.A)(t)?this.fromDateTimeISO(t).toISODate():null},validateFilter(e,t){return[e=(0,f.A)(e)?this.toDateTimeISO(e):null,t=(0,f.A)(t)?this.toDateTimeISO(t):null]},emitFilterChange(){this.$emit("change",{filterClass:this.filterKey,value:this.validateFilter(this.startValue,this.endValue)})},handleFilterReset(){this.$refs.startField.value="",this.$refs.endField.value="",this.setCurrentFilterValue()},fromDateTimeISO:e=>d.c9.fromISO(e),toDateTimeISO:e=>d.c9.fromISO(e).toISODate()},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},field(){return this.filter.field},startExtraAttributes(){const e=m()(this.field.extraAttributes,["readonly"]);return g({type:this.field.type||"date",placeholder:this.__("Start")},e)},endExtraAttributes(){const e=m()(this.field.extraAttributes,["readonly"]);return g({type:this.field.type||"date",placeholder:this.__("End")},e)}}};const k=(0,r(66262).A)(b,[["render",function(e,t,r,d,u,p){const h=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(h,null,{filter:(0,o.withCtx)((()=>[(0,o.createElementVNode)("label",i,[(0,o.createElementVNode)("span",l,(0,o.toDisplayString)(`${p.filter.name} - ${e.__("From")}`),1),(0,o.withDirectives)((0,o.createElementVNode)("input",(0,o.mergeProps)({ref:"startField","onUpdate:modelValue":t[0]||(t[0]=t=>e.startValue=t)},p.startExtraAttributes,{class:"w-full flex form-control form-input form-control-bordered",dusk:`${p.filter.uniqueKey}-range-start`}),null,16,a),[[o.vModelDynamic,e.startValue]])]),(0,o.createElementVNode)("label",n,[(0,o.createElementVNode)("span",s,(0,o.toDisplayString)(`${p.filter.name} - ${e.__("To")}`),1),(0,o.withDirectives)((0,o.createElementVNode)("input",(0,o.mergeProps)({ref:"endField","onUpdate:modelValue":t[1]||(t[1]=t=>e.endValue=t)},p.endExtraAttributes,{class:"w-full flex form-control form-input form-control-bordered",dusk:`${p.filter.uniqueKey}-range-end`}),null,16,c),[[o.vModelDynamic,e.endValue]])])])),_:1})}],["__file","DateField.vue"]])},94299:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>v});var o=r(29726);const i={class:"flex flex-col gap-2"},l={class:"flex flex-col gap-2"},a={class:"uppercase text-xs font-bold tracking-wide"},n=["placeholder","dusk"],s={class:"flex flex-col gap-2"},c={class:"uppercase text-xs font-bold tracking-wide"},d=["placeholder","dusk"];var u=r(91272),p=r(38221),h=r.n(p),m=r(70393);const f={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},data:()=>({startValue:null,endValue:null,debouncedEventEmitter:null}),created(){this.debouncedEventEmitter=h()((()=>this.emitFilterChange()),500),this.setCurrentFilterValue()},mounted(){Nova.$on("filter-reset",this.handleFilterReset)},beforeUnmount(){Nova.$off("filter-reset",this.handleFilterReset)},watch:{startValue(){this.debouncedEventEmitter()},endValue(){this.debouncedEventEmitter()}},methods:{setCurrentFilterValue(){let[e,t]=this.filter.currentValue||[null,null];this.startValue=(0,m.A)(e)?u.c9.fromISO(e).toFormat("yyyy-MM-dd'T'HH:mm"):null,this.endValue=(0,m.A)(t)?u.c9.fromISO(t).toFormat("yyyy-MM-dd'T'HH:mm"):null},validateFilter(e,t){return[e=(0,m.A)(e)?this.toDateTimeISO(e,"start"):null,t=(0,m.A)(t)?this.toDateTimeISO(t,"end"):null]},emitFilterChange(){this.$emit("change",{filterClass:this.filterKey,value:this.validateFilter(this.startValue,this.endValue)})},handleFilterReset(){this.$refs.startField.value="",this.$refs.endField.value="",this.setCurrentFilterValue()},fromDateTimeISO(e){return u.c9.fromISO(e,{setZone:!0}).setZone(this.timezone).toISO()},toDateTimeISO(e){return u.c9.fromISO(e,{zone:this.timezone,setZone:!0}).setZone(Nova.config("timezone")).toISO()}},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},field(){return this.filter.field},timezone:()=>Nova.config("userTimezone")||Nova.config("timezone")}};const v=(0,r(66262).A)(f,[["render",function(e,t,r,u,p,h){const m=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(m,null,{filter:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("label",l,[(0,o.createElementVNode)("span",a,(0,o.toDisplayString)(`${h.filter.name} - ${e.__("From")}`),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{ref:"startField","onUpdate:modelValue":t[0]||(t[0]=t=>e.startValue=t),type:"datetime-local",class:"w-full flex form-control form-input form-control-bordered",placeholder:e.__("Start"),dusk:`${h.filter.uniqueKey}-range-start`},null,8,n),[[o.vModelText,e.startValue]])]),(0,o.createElementVNode)("label",s,[(0,o.createElementVNode)("span",c,(0,o.toDisplayString)(`${h.filter.name} - ${e.__("To")}`),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{ref:"endField","onUpdate:modelValue":t[1]||(t[1]=t=>e.endValue=t),type:"datetime-local",class:"w-full flex form-control form-input form-control-bordered",placeholder:e.__("End"),dusk:`${h.filter.uniqueKey}-range-end`},null,8,d),[[o.vModelText,e.endValue]])])])])),_:1})}],["__file","DateTimeField.vue"]])},83240:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>y});var o=r(29726);const i={key:0,class:"flex items-center"},l={key:0,class:"mr-3"},a=["src"],n={class:"flex items-center"},s={key:0,class:"flex-none mr-3"},c=["src"],d={class:"flex-auto"},u={key:0},p={key:1};var h=r(35229),m=r(25019),f=r(38221),v=r.n(f);const g={emits:["change"],mixins:[h.Bz],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},data:()=>({availableResources:[],selectedResourceId:"",softDeletes:!1,withTrashed:!1,search:"",debouncedEventEmitter:null}),mounted(){Nova.$on("filter-reset",this.handleFilterReset),this.initializeComponent()},created(){this.debouncedEventEmitter=v()((()=>this.emitFilterChange()),500),Nova.$on("filter-active",this.handleClosingInactiveSearchInputs)},beforeUnmount(){Nova.$off("filter-active",this.handleClosingInactiveSearchInputs),Nova.$off("filter-reset",this.handleFilterReset)},watch:{selectedResourceId(){this.debouncedEventEmitter()}},methods:{initializeComponent(){let e=!1;this.filter.currentValue&&(this.selectedResourceId=this.filter.currentValue,!0===this.isSearchable&&(e=!0)),this.isSearchable&&!e||this.getAvailableResources()},getAvailableResources(e){let t=this.queryParams;return null!=e&&(t.first=!1,t.current=null,t.search=e),m.A.fetchAvailableResources(this.field.resourceName,{params:t}).then((({data:{resources:e,softDeletes:t,withTrashed:r}})=>{this.isSearchable||(this.withTrashed=r),this.availableResources=e,this.softDeletes=t}))},handleShowingActiveSearchInput(){Nova.$emit("filter-active",this.filterKey)},closeSearchableRef(){this.$refs.searchable&&this.$refs.searchable.close()},handleClosingInactiveSearchInputs(e){e!==this.filterKey&&this.closeSearchableRef()},handleClearSelection(){this.clearSelection()},emitFilterChange(){this.$emit("change",{filterClass:this.filterKey,value:this.selectedResourceId??""})},handleFilterReset(){""===this.filter.currentValue&&(this.selectedResourceId="",this.availableResources=[],this.closeSearchableRef(),this.initializeComponent())}},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},field(){return this.filter.field},shouldShowFilter(){return this.isSearchable||!this.isSearchable&&this.availableResources.length>0},isSearchable(){return this.field.searchable},queryParams(){return{current:this.selectedResourceId,first:this.selectedResourceId&&this.isSearchable,search:this.search,withTrashed:this.withTrashed}},selectedResource(){return this.availableResources.find((e=>e.value===this.selectedResourceId))}}};const y=(0,r(66262).A)(g,[["render",function(e,t,r,h,m,f){const v=(0,o.resolveComponent)("SearchInput"),g=(0,o.resolveComponent)("SelectControl"),y=(0,o.resolveComponent)("FilterContainer");return f.shouldShowFilter?((0,o.openBlock)(),(0,o.createBlock)(y,{key:0},{filter:(0,o.withCtx)((()=>[f.isSearchable?((0,o.openBlock)(),(0,o.createBlock)(v,{key:0,ref:"searchable",modelValue:e.selectedResourceId,"onUpdate:modelValue":t[0]||(t[0]=t=>e.selectedResourceId=t),onInput:e.performSearch,onClear:f.handleClearSelection,onShown:f.handleShowingActiveSearchInput,options:e.availableResources,debounce:f.field.debounce,clearable:!0,trackBy:"value",mode:"modal",class:"w-full",dusk:`${f.filter.uniqueKey}-search-input`},{option:(0,o.withCtx)((({selected:t,option:r})=>[(0,o.createElementVNode)("div",n,[r.avatar?((0,o.openBlock)(),(0,o.createElementBlock)("div",s,[(0,o.createElementVNode)("img",{src:r.avatar,class:"w-8 h-8 rounded-full block"},null,8,c)])):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",d,[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["text-sm font-semibold leading-normal",{"text-white dark:text-gray-900":t}])},(0,o.toDisplayString)(r.display),3),f.field.withSubtitles?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,class:(0,o.normalizeClass)(["text-xs font-semibold leading-normal text-gray-500",{"text-white dark:text-gray-700":t}])},[r.subtitle?((0,o.openBlock)(),(0,o.createElementBlock)("span",u,(0,o.toDisplayString)(r.subtitle),1)):((0,o.openBlock)(),(0,o.createElementBlock)("span",p,(0,o.toDisplayString)(e.__("No additional information...")),1))],2)):(0,o.createCommentVNode)("",!0)])])])),default:(0,o.withCtx)((()=>[f.selectedResource?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[f.selectedResource.avatar?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[(0,o.createElementVNode)("img",{src:f.selectedResource.avatar,class:"w-8 h-8 rounded-full block"},null,8,a)])):(0,o.createCommentVNode)("",!0),(0,o.createTextVNode)(" "+(0,o.toDisplayString)(f.selectedResource.display),1)])):(0,o.createCommentVNode)("",!0)])),_:1},8,["modelValue","onInput","onClear","onShown","options","debounce","dusk"])):e.availableResources.length>0?((0,o.openBlock)(),(0,o.createBlock)(g,{key:1,modelValue:e.selectedResourceId,"onUpdate:modelValue":t[1]||(t[1]=t=>e.selectedResourceId=t),options:e.availableResources,label:"display",dusk:f.filter.uniqueKey},{default:(0,o.withCtx)((()=>t[2]||(t[2]=[(0,o.createElementVNode)("option",{value:"",selected:""},"—",-1)]))),_:1},8,["modelValue","options","dusk"])):(0,o.createCommentVNode)("",!0)])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(f.filter.name),1)])),_:1})):(0,o.createCommentVNode)("",!0)}],["__file","EloquentField.vue"]])},34245:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i=["id","dusk"];var l=r(38221),a=r.n(l),n=r(90179),s=r.n(n);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function d(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const u={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},data:()=>({value:null,debouncedEventEmitter:null}),created(){this.debouncedEventEmitter=a()((()=>this.emitFilterChange()),500),this.setCurrentFilterValue()},mounted(){Nova.$on("filter-reset",this.setCurrentFilterValue)},beforeUnmount(){Nova.$off("filter-reset",this.setCurrentFilterValue)},watch:{value(){this.debouncedEventEmitter()}},methods:{setCurrentFilterValue(){this.value=this.filter.currentValue},emitFilterChange(){this.$emit("change",{filterClass:this.filterKey,value:this.value})}},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},field(){return this.filter.field},extraAttributes(){const e=s()(this.field.extraAttributes,["readonly"]);return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){d(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({type:this.field.type||"email",pattern:this.field.pattern,placeholder:this.field.placeholder||this.field.name},e)}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(s,null,{filter:(0,o.withCtx)((()=>[(0,o.withDirectives)((0,o.createElementVNode)("input",(0,o.mergeProps)({class:"w-full form-control form-input form-control-bordered"},n.extraAttributes,{"onUpdate:modelValue":t[0]||(t[0]=t=>e.value=t),id:n.filter.uniqueKey,dusk:n.filter.uniqueKey}),null,16,i),[[o.vModelDynamic,e.value]])])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(n.filter.name),1)])),_:1})}],["__file","EmailField.vue"]])},86951:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i=["selected"];var l=r(38221),a=r.n(l);const n={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},data:()=>({value:null,debouncedEventEmitter:null}),created(){this.debouncedEventEmitter=a()((()=>this.emitFilterChange()),500),this.setCurrentFilterValue()},mounted(){Nova.$on("filter-reset",this.setCurrentFilterValue)},beforeUnmount(){Nova.$off("filter-reset",this.setCurrentFilterValue)},watch:{value(){this.debouncedEventEmitter()}},methods:{setCurrentFilterValue(){let e=this.field.morphToTypes.find((e=>e.type===this.filter.currentValue));this.value=null!=e?e.value:""},emitFilterChange(){let e=this.field.morphToTypes.find((e=>e.value===this.value));this.$emit("change",{filterClass:this.filterKey,value:null!=e?e.type:""})}},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},field(){return this.filter.field},hasMorphToTypes(){return this.field.morphToTypes.length>0}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("SelectControl"),c=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(c,null,{filter:(0,o.withCtx)((()=>[(0,o.createVNode)(s,{modelValue:e.value,"onUpdate:modelValue":t[0]||(t[0]=t=>e.value=t),options:n.field.morphToTypes,label:"singularLabel",dusk:n.filter.uniqueKey},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("option",{value:"",selected:""===e.value},"—",8,i)])),_:1},8,["modelValue","options","dusk"])])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(n.filter.name),1)])),_:1})}],["__file","MorphToField.vue"]])},33011:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i=["selected"];var l=r(38221),a=r.n(l);const n={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},data:()=>({value:null,debouncedHandleChange:null}),created(){this.debouncedHandleChange=a()((()=>this.handleFilterChange()),500),this.setCurrentFilterValue()},mounted(){Nova.$on("filter-reset",this.setCurrentFilterValue)},beforeUnmount(){Nova.$off("filter-reset",this.setCurrentFilterValue)},methods:{setCurrentFilterValue(){this.value=this.filter.currentValue},handleFilterChange(){this.$emit("change",{filterClass:this.filterKey,value:this.value})}},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},field(){return this.filter.field}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("MultiSelectControl"),c=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(c,null,{filter:(0,o.withCtx)((()=>[(0,o.createVNode)(s,{modelValue:e.value,"onUpdate:modelValue":[t[0]||(t[0]=t=>e.value=t),e.debouncedHandleChange],options:n.field.options,dusk:n.filter.uniqueKey},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("option",{value:"",selected:""===e.value},"—",8,i)])),_:1},8,["modelValue","onUpdate:modelValue","options","dusk"])])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(n.filter.name),1)])),_:1})}],["__file","MultiSelectField.vue"]])},72482:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>w});var o=r(29726);const i={class:"block"},l={class:"uppercase text-xs font-bold tracking-wide"},a=["dusk"],n={class:"block mt-2"},s={class:"uppercase text-xs font-bold tracking-wide"},c=["dusk"];var d=r(38221),u=r.n(d),p=r(90179),h=r.n(p),m=r(99374),f=r.n(m),v=r(70393);function g(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function y(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?g(Object(r),!0).forEach((function(t){b(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):g(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function b(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const k={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},data:()=>({startValue:null,endValue:null,debouncedHandleChange:null}),created(){this.debouncedHandleChange=u()((()=>this.handleChange()),500),this.setCurrentFilterValue()},mounted(){Nova.$on("filter-reset",this.setCurrentFilterValue)},beforeUnmount(){Nova.$off("filter-reset",this.setCurrentFilterValue)},watch:{startValue(){this.debouncedHandleChange()},endValue(){this.debouncedHandleChange()}},methods:{setCurrentFilterValue(){let[e,t]=this.filter.currentValue||[null,null];this.startValue=(0,v.A)(e)?f()(e):null,this.endValue=(0,v.A)(t)?f()(t):null},validateFilter(e,t){return e=(0,v.A)(e)?f()(e):null,t=(0,v.A)(t)?f()(t):null,null!==e&&this.field.min&&this.field.min>e&&(e=f()(this.field.min)),null!==t&&this.field.max&&this.field.max<t&&(t=f()(this.field.max)),[e,t]},handleChange(){this.$emit("change",{filterClass:this.filterKey,value:this.validateFilter(this.startValue,this.endValue)})}},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},field(){return this.filter.field},startExtraAttributes(){const e=h()(this.field.extraAttributes,["readonly"]);return y({type:this.field.type||"number",min:this.field.min,max:this.field.max,step:this.field.step,pattern:this.field.pattern,placeholder:this.__("Min")},e)},endExtraAttributes(){const e=h()(this.field.extraAttributes,["readonly"]);return y({type:this.field.type||"number",min:this.field.min,max:this.field.max,step:this.field.step,pattern:this.field.pattern,placeholder:this.__("Max")},e)}}};const w=(0,r(66262).A)(k,[["render",function(e,t,r,d,u,p){const h=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(h,null,{filter:(0,o.withCtx)((()=>[(0,o.createElementVNode)("label",i,[(0,o.createElementVNode)("span",l,(0,o.toDisplayString)(`${p.filter.name} - ${e.__("From")}`),1),(0,o.withDirectives)((0,o.createElementVNode)("input",(0,o.mergeProps)({class:"w-full block form-control form-input form-control-bordered","onUpdate:modelValue":t[0]||(t[0]=t=>e.startValue=t),dusk:`${p.filter.uniqueKey}-range-start`},p.startExtraAttributes),null,16,a),[[o.vModelDynamic,e.startValue]])]),(0,o.createElementVNode)("label",n,[(0,o.createElementVNode)("span",s,(0,o.toDisplayString)(`${p.filter.name} - ${e.__("To")}`),1),(0,o.withDirectives)((0,o.createElementVNode)("input",(0,o.mergeProps)({class:"w-full block form-control form-input form-control-bordered","onUpdate:modelValue":t[1]||(t[1]=t=>e.endValue=t),dusk:`${p.filter.uniqueKey}-range-end`},p.endExtraAttributes),null,16,c),[[o.vModelDynamic,e.endValue]])])])),_:1})}],["__file","NumberField.vue"]])},71595:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={key:0,class:"flex items-center"},l=["selected"];var a=r(38221),n=r.n(a);const s={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},data:()=>({search:"",value:null,debouncedHandleChange:null}),mounted(){Nova.$on("filter-reset",this.handleFilterReset)},created(){this.debouncedHandleChange=n()((()=>this.handleFilterChange()),500),this.value=this.filter.currentValue},beforeUnmount(){Nova.$off("filter-reset",this.handleFilterReset)},watch:{value(){this.debouncedHandleChange()}},methods:{performSearch(e){this.search=e},clearSelection(){this.value="",this.$refs.searchable&&this.$refs.searchable.close()},handleFilterChange(){this.$emit("change",{filterClass:this.filterKey,value:this.value??""})},handleFilterReset(){""===this.filter.currentValue&&this.clearSelection()}},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},field(){return this.filter.field},isSearchable(){return this.field.searchable},filteredOptions(){return this.field.options.filter((e=>e.label.toString().toLowerCase().indexOf(this.search.toLowerCase())>-1))},selectedOption(){return this.field.options.find((e=>this.value===e.value||this.value===e.value.toString()))}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("SearchInput"),d=(0,o.resolveComponent)("SelectControl"),u=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(u,null,{filter:(0,o.withCtx)((()=>[s.isSearchable?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,ref:"searchable",modelValue:e.value,"onUpdate:modelValue":t[0]||(t[0]=t=>e.value=t),onInput:s.performSearch,onClear:s.clearSelection,options:s.filteredOptions,clearable:!0,trackBy:"value",mode:"modal",class:"w-full",dusk:`${s.filter.uniqueKey}-search-input`},{option:(0,o.withCtx)((({option:e,selected:t})=>[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["flex items-center text-sm font-semibold leading-5",{"text-white":t}])},(0,o.toDisplayString)(e.label),3)])),default:(0,o.withCtx)((()=>[s.selectedOption?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,(0,o.toDisplayString)(s.selectedOption.label),1)):(0,o.createCommentVNode)("",!0)])),_:1},8,["modelValue","onInput","onClear","options","dusk"])):((0,o.openBlock)(),(0,o.createBlock)(d,{key:1,modelValue:e.value,"onUpdate:modelValue":t[1]||(t[1]=t=>e.value=t),options:s.field?.options??[],dusk:s.filter.uniqueKey},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("option",{value:"",selected:""===e.value},"—",8,l)])),_:1},8,["modelValue","options","dusk"]))])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(s.filter.name),1)])),_:1})}],["__file","SelectField.vue"]])},85645:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>m});var o=r(29726);const i=["value","id","dusk","list"],l=["id"],a=["value"];var n=r(38221),s=r.n(n),c=r(90179),d=r.n(c);function u(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function p(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const h={emits:["change"],props:{resourceName:{type:String,required:!0},filterKey:{type:String,required:!0},lens:String},data:()=>({value:null,debouncedEventEmitter:null}),created(){this.debouncedEventEmitter=s()((()=>this.emitChange()),500),this.setCurrentFilterValue()},mounted(){Nova.debug("Mounting <FilterMenu>"),Nova.$on("filter-reset",this.setCurrentFilterValue)},beforeUnmount(){Nova.debug("Unmounting <FilterMenu>"),Nova.$off("filter-reset",this.setCurrentFilterValue)},methods:{setCurrentFilterValue(){this.value=this.filter.currentValue},handleChange(e){this.value=e.target.value,this.debouncedEventEmitter()},emitChange(){this.$emit("change",{filterClass:this.filterKey,value:this.value})}},computed:{filter(){return this.$store.getters[`${this.resourceName}/getFilter`](this.filterKey)},field(){return this.filter.field},extraAttributes(){const e=d()(this.field.extraAttributes,["readonly"]);return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?u(Object(r),!0).forEach((function(t){p(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):u(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({type:this.field.type||"text",min:this.field.min,max:this.field.max,step:this.field.step,pattern:this.field.pattern,placeholder:this.field.placeholder||this.field.name},e)}}};const m=(0,r(66262).A)(h,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("FilterContainer");return(0,o.openBlock)(),(0,o.createBlock)(d,null,{filter:(0,o.withCtx)((()=>[(0,o.createElementVNode)("input",(0,o.mergeProps)({class:"w-full form-control form-input form-control-bordered",onInput:t[0]||(t[0]=(...e)=>c.handleChange&&c.handleChange(...e)),value:e.value,id:c.field.uniqueKey,dusk:`${c.field.uniqueKey}-filter`},c.extraAttributes,{list:`${c.field.uniqueKey}-list`}),null,16,i),c.field.suggestions&&c.field.suggestions.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("datalist",{key:0,id:`${c.field.uniqueKey}-list`},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(c.field.suggestions,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("option",{key:e,value:e},null,8,a)))),128))],8,l)):(0,o.createCommentVNode)("",!0)])),default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(c.filter.name),1)])),_:1})}],["__file","TextField.vue"]])},77054:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>i});const o={extends:r(22988).default,computed:{isVaporField:()=>!1}};const i=(0,r(66262).A)(o,[["__file","AudioField.vue"]])},14056:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>v});var o=r(29726);const i={class:"flex items-center"},l={key:0,class:"flex items-center"},a={key:0,class:"mr-3"},n=["src"],s=["disabled"];var c=r(74640),d=r(35229),u=r(1242),p=r(24713),h=r.n(p),m=r(70393);const f={components:{Button:c.Button},mixins:[d.Gj,d._w,d.XJ,d.Bz,d.zJ],props:{resourceId:{}},data:()=>({availableResources:[],initializingWithExistingResource:!1,createdViaRelationModal:!1,selectedResourceId:null,softDeletes:!1,withTrashed:!1,search:"",relationModalOpen:!1}),mounted(){this.initializeComponent()},methods:{initializeComponent(){this.withTrashed=!1,this.selectedResourceId=this.currentField.value,this.editingExistingResource?(this.initializingWithExistingResource=!0,this.selectedResourceId=this.currentField.belongsToId):this.viaRelatedResource&&(this.initializingWithExistingResource=!0,this.selectedResourceId=this.viaResourceId),this.shouldSelectInitialResource?(this.useSearchInput||(this.initializingWithExistingResource=!1),this.getAvailableResources()):!this.isSearchable&&this.currentlyIsVisible&&this.getAvailableResources(),this.determineIfSoftDeletes(),this.field.fill=this.fill},fieldDefaultValue:()=>null,fill(e){this.fillIfVisible(e,this.fieldAttribute,this.selectedResourceId??""),this.fillIfVisible(e,`${this.fieldAttribute}_trashed`,this.withTrashed)},getAvailableResources(){return Nova.$progress.start(),u.A.fetchAvailableResources(this.resourceName,this.fieldAttribute,{params:this.queryParams}).then((({data:{resources:e,softDeletes:t,withTrashed:r}})=>{if(!this.initializingWithExistingResource&&this.isSearchable||(this.withTrashed=r),this.viaRelatedResource){if(!e.find((e=>this.isSelectedResourceId(e.value)))&&!this.shouldIgnoreViaRelatedResource)return Nova.visit("/404")}this.useSearchInput&&(this.initializingWithExistingResource=!1),this.availableResources=e,this.softDeletes=t})).finally((()=>{Nova.$progress.done()}))},determineIfSoftDeletes(){return u.A.determineIfSoftDeletes(this.field.resourceName).then((e=>{this.softDeletes=e.data.softDeletes}))},isNumeric:e=>!isNaN(parseFloat(e))&&isFinite(e),toggleWithTrashed(){let e;(0,m.A)(this.selectedResourceId)&&(e=this.selectedResourceId),this.withTrashed=!this.withTrashed,this.selectedResourceId=null,this.useSearchInput||this.getAvailableResources().then((()=>{let t=h()(this.availableResources,(t=>t.value===e));this.selectedResourceId=t>-1?e:null}))},openRelationModal(){Nova.$emit("create-relation-modal-opened"),this.relationModalOpen=!0},closeRelationModal(){this.relationModalOpen=!1,Nova.$emit("create-relation-modal-closed")},handleSetResource({id:e}){this.closeRelationModal(),this.selectedResourceId=e,this.initializingWithExistingResource=!0,this.createdViaRelationModal=!0,this.getAvailableResources().then((()=>{this.emitFieldValueChange(this.fieldAttribute,this.selectedResourceId)}))},performResourceSearch(e){this.useSearchInput?this.performSearch(e):this.search=e},clearResourceSelection(){const e=this.selectedResourceId;this.clearSelection(),this.viaRelatedResource&&!this.createdViaRelationModal?this.pushAfterUpdatingQueryString({viaResource:null,viaResourceId:null,viaRelationship:null,relationshipType:null}).then((()=>{Nova.$router.reload({onSuccess:()=>{this.initializingWithExistingResource=!1,this.initializeComponent()}})})):(this.createdViaRelationModal?(this.selectedResourceId=e,this.createdViaRelationModal=!1,this.initializingWithExistingResource=!0):this.editingExistingResource&&(this.initializingWithExistingResource=!1),this.isSearchable&&!this.shouldLoadFirstResource||!this.currentlyIsVisible||this.getAvailableResources())},revertSyncedFieldToPreviousValue(e){this.syncedField.belongsToId=e.belongsToId},onSyncedField(){this.viaRelatedResource||this.initializeComponent()},emitOnSyncedFieldValueChange(){this.viaRelatedResource||this.emitFieldValueChange(this.fieldAttribute,this.selectedResourceId)},syncedFieldValueHasNotChanged(){return this.isSelectedResourceId(this.currentField.value)},isSelectedResourceId(e){return null!=e&&e?.toString()===this.selectedResourceId?.toString()}},computed:{editingExistingResource(){return(0,m.A)(this.field.belongsToId)},viaRelatedResource(){return Boolean(this.viaResource===this.field.resourceName&&this.field.reverse&&this.viaResourceId)},shouldSelectInitialResource(){return Boolean(this.editingExistingResource||this.viaRelatedResource||this.currentField.value)},isSearchable(){return Boolean(this.currentField.searchable)},queryParams(){return{current:this.selectedResourceId,first:this.shouldLoadFirstResource,search:this.search,withTrashed:this.withTrashed,resourceId:this.resourceId,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,component:this.field.dependentComponentKey,dependsOn:this.encodedDependentFieldValues,editing:!0,editMode:(0,m.A)(this.resourceId)?"update":"create"}},shouldLoadFirstResource(){return this.initializingWithExistingResource&&!this.shouldIgnoreViaRelatedResource||Boolean(this.currentlyIsReadonly&&this.selectedResourceId)},shouldShowTrashed(){return this.softDeletes&&!this.viaRelatedResource&&!this.currentlyIsReadonly&&this.currentField.displaysWithTrashed},authorizedToCreate(){return Nova.config("resources").find((e=>e.uriKey===this.field.resourceName)).authorizedToCreate},canShowNewRelationModal(){return this.currentField.showCreateRelationButton&&!this.shownViaNewRelationModal&&!this.viaRelatedResource&&!this.currentlyIsReadonly&&this.authorizedToCreate},placeholder(){return this.currentField.placeholder||this.__("—")},filteredResources(){return this.isSearchable?this.availableResources:this.availableResources.filter((e=>e.display.toLowerCase().indexOf(this.search.toLowerCase())>-1||new String(e.value).indexOf(this.search)>-1))},shouldIgnoreViaRelatedResource(){return this.viaRelatedResource&&(0,m.A)(this.search)},useSearchInput(){return this.isSearchable||this.viaRelatedResource},selectedResource(){return this.availableResources.find((e=>this.isSelectedResourceId(e.value)))}}};const v=(0,r(66262).A)(f,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("SearchInputResult"),h=(0,o.resolveComponent)("SearchInput"),m=(0,o.resolveComponent)("SelectControl"),f=(0,o.resolveComponent)("Button"),v=(0,o.resolveComponent)("CreateRelationModal"),g=(0,o.resolveComponent)("TrashedCheckbox"),y=(0,o.resolveComponent)("DefaultField"),b=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createBlock)(y,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[u.useSearchInput?((0,o.openBlock)(),(0,o.createBlock)(h,{key:0,modelValue:e.selectedResourceId,"onUpdate:modelValue":t[0]||(t[0]=t=>e.selectedResourceId=t),onSelected:e.selectResource,onInput:u.performResourceSearch,onClear:u.clearResourceSelection,options:u.filteredResources,"has-error":e.hasError,debounce:e.currentField.debounce,disabled:e.currentlyIsReadonly,clearable:e.currentField.nullable||u.editingExistingResource||u.viaRelatedResource||e.createdViaRelationModal,trackBy:"value",mode:e.mode,autocomplete:e.currentField.autocomplete,class:"w-full",dusk:`${e.field.resourceName}-search-input`},{option:(0,o.withCtx)((({selected:t,option:r})=>[(0,o.createVNode)(p,{option:r,selected:t,"with-subtitles":e.currentField.withSubtitles},null,8,["option","selected","with-subtitles"])])),default:(0,o.withCtx)((()=>[u.selectedResource?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[u.selectedResource.avatar?((0,o.openBlock)(),(0,o.createElementBlock)("div",a,[(0,o.createElementVNode)("img",{src:u.selectedResource.avatar,class:"w-8 h-8 rounded-full block"},null,8,n)])):(0,o.createCommentVNode)("",!0),(0,o.createTextVNode)(" "+(0,o.toDisplayString)(u.selectedResource.display),1)])):(0,o.createCommentVNode)("",!0)])),_:1},8,["modelValue","onSelected","onInput","onClear","options","has-error","debounce","disabled","clearable","mode","autocomplete","dusk"])):((0,o.openBlock)(),(0,o.createBlock)(m,{key:1,modelValue:e.selectedResourceId,"onUpdate:modelValue":t[1]||(t[1]=t=>e.selectedResourceId=t),onSelected:e.selectResource,options:e.availableResources,"has-error":e.hasError,disabled:e.currentlyIsReadonly,label:"display",class:"w-full",dusk:`${e.field.resourceName}-select`},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("option",{value:"",selected:"",disabled:!e.currentField.nullable},(0,o.toDisplayString)(u.placeholder),9,s)])),_:1},8,["modelValue","onSelected","options","has-error","disabled","dusk"])),u.canShowNewRelationModal?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(f,{key:2,variant:"link",size:"small","leading-icon":"plus-circle",onClick:u.openRelationModal,dusk:`${e.field.attribute}-inline-create`},null,8,["onClick","dusk"])),[[b,e.__("Create :resource",{resource:e.field.singularLabel})]]):(0,o.createCommentVNode)("",!0)]),(0,o.createVNode)(v,{show:u.canShowNewRelationModal&&e.relationModalOpen,size:e.field.modalSize,onSetResource:u.handleSetResource,onCreateCancelled:u.closeRelationModal,"resource-name":e.field.resourceName,"resource-id":r.resourceId,"via-relationship":e.viaRelationship,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId},null,8,["show","size","onSetResource","onCreateCancelled","resource-name","resource-id","via-relationship","via-resource","via-resource-id"]),u.shouldShowTrashed?((0,o.openBlock)(),(0,o.createBlock)(g,{key:0,class:"mt-3","resource-name":e.field.resourceName,checked:e.withTrashed,onInput:u.toggleWithTrashed},null,8,["resource-name","checked","onInput"])):(0,o.createCommentVNode)("",!0)])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","BelongsToField.vue"]])},36938:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);var i=r(74640),l=r(35229);const a={components:{Checkbox:i.Checkbox},mixins:[l._w,l.Gj],methods:{setInitialValue(){this.value=this.currentField.value??this.value},fieldDefaultValue:()=>!1,fill(e){this.fillIfVisible(e,this.fieldAttribute,this.trueValue)},toggle(){this.value=!this.value,this.field&&this.emitFieldValueChange(this.fieldAttribute,this.value)}},computed:{checked(){return Boolean(this.value)},trueValue(){return+this.checked}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("Checkbox"),s=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(s,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createVNode)(n,{disabled:e.currentlyIsReadonly,dusk:e.currentField.uniqueKey,id:e.currentField.uniqueKey,"model-value":a.checked,name:e.field.name,onChange:a.toggle,class:"mt-2"},null,8,["disabled","dusk","id","model-value","name","onChange"])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","BooleanField.vue"]])},6461:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>f});var o=r(29726);const i={class:"space-y-2"};var l=r(35229),a=r(7309),n=r.n(a),s=r(44377),c=r.n(s),d=r(55378),u=r.n(d),p=r(55364),h=r.n(p);const m={mixins:[l._w,l.Gj],data:()=>({value:{}}),methods:{setInitialValue(){let e=h()(this.finalPayload,this.currentField.value||{});this.value=this.currentField.options.map((t=>({name:t.name,label:t.label,checked:e[t.name]||!1})))},fill(e){this.fillIfVisible(e,this.fieldAttribute,JSON.stringify(this.finalPayload))},toggle(e,t){n()(this.value,(e=>e.name==t.name)).checked=e.target.checked,this.field&&this.emitFieldValueChange(this.fieldAttribute,JSON.stringify(this.finalPayload))},onSyncedField(){this.setInitialValue()}},computed:{finalPayload(){return c()(u()(this.value,(e=>[e.name,e.checked])))}}};const f=(0,r(66262).A)(m,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("CheckboxWithLabel"),c=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(c,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.value,(t=>((0,o.openBlock)(),(0,o.createBlock)(s,{key:t.name,name:t.name,checked:t.checked,onInput:e=>n.toggle(e,t),disabled:e.currentlyIsReadonly},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(t.label),1)])),_:2},1032,["name","checked","onInput","disabled"])))),128))])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","BooleanGroupField.vue"]])},61907:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i=["id"];var l=r(15237),a=r.n(l),n=r(35229);function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function c(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){d(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function d(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const u={mixins:[n._w,n.Gj],codemirror:null,mounted(){this.setInitialValue(),this.isVisible&&this.handleShowingComponent()},watch:{currentlyIsVisible(e,t){!0===e&&!1===t?this.$nextTick((()=>this.handleShowingComponent())):!1===e&&!0===t&&this.handleHidingComponent()}},methods:{handleShowingComponent(){const e=c(c({tabSize:4,indentWithTabs:!0,lineWrapping:!0,lineNumbers:!0,theme:"dracula",autoRefresh:!0},{readOnly:this.currentlyIsReadonly}),this.currentField.options);this.codemirror=a().fromTextArea(this.$refs.theTextarea,e),this.codemirror.getDoc().setValue(this.value??this.currentField.value),this.codemirror.setSize("100%",this.currentField.height),this.codemirror.getDoc().on("change",((e,t)=>{this.value=e.getValue(),this.field&&this.emitFieldValueChange(this.fieldAttribute,this.value)}))},handleHidingComponent(){this.codemirror=null},onSyncedField(){this.codemirror&&this.codemirror.getDoc().setValue(this.currentField.value)}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(s,{field:e.currentField,errors:e.errors,"full-width-content":e.fullWidthContent,"show-help-text":e.showHelpText},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("textarea",{ref:"theTextarea",id:e.currentField.uniqueKey,class:"w-full h-auto py-3 form-control form-input form-control-bordered"},null,8,i)])),_:1},8,["field","errors","full-width-content","show-help-text"])}],["__file","CodeField.vue"]])},3210:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726);const i=["value","id","dusk","disabled"],l=["id"],a=["value"];var n=r(35229);function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function c(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const d={mixins:[n.Gj,n.IR,n._w],computed:{defaultAttributes(){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){c(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({class:this.errorClasses},this.suggestionsAttributes)}}};const u=(0,r(66262).A)(d,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(d,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("input",(0,o.mergeProps)(c.defaultAttributes,{class:"p-2 form-control form-input form-control-bordered bg-white",type:"color",onInput:t[0]||(t[0]=(...t)=>e.handleChange&&e.handleChange(...t)),value:e.value,id:e.currentField.uniqueKey,dusk:e.field.attribute,disabled:e.currentlyIsReadonly}),null,16,i),e.suggestions.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("datalist",{key:0,id:e.suggestionsId},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.suggestions,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("option",{key:e,value:e},null,8,a)))),128))],8,l)):(0,o.createCommentVNode)("",!0)])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","ColorField.vue"]])},72366:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726);const i={class:"flex flex-wrap items-stretch w-full relative"},l={class:"flex -mr-px"},a={class:"flex items-center leading-normal rounded rounded-r-none border border-r-0 border-gray-300 dark:border-gray-700 px-3 whitespace-nowrap bg-gray-100 dark:bg-gray-800 text-gray-500 text-sm font-bold"},n=["id","value","disabled","dusk"];var s=r(35229);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function d(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function u(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const p={mixins:[s._w,s.Gj],props:["resourceName","resourceId","field"],computed:{defaultAttributes(){return{type:"number",min:this.currentField.min,max:this.currentField.max,step:this.currentField.step,pattern:this.currentField.pattern,placeholder:this.placeholder,class:this.errorClasses}},extraAttributes(){return d(d({},this.defaultAttributes),this.currentField.extraAttributes)}}};const h=(0,r(66262).A)(p,[["render",function(e,t,r,s,c,d){const u=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(u,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("span",a,(0,o.toDisplayString)(e.currentField.currency),1)]),(0,o.createElementVNode)("input",(0,o.mergeProps)(d.extraAttributes,{id:e.currentField.uniqueKey,value:e.value,disabled:e.currentlyIsReadonly,onInput:t[0]||(t[0]=(...t)=>e.handleChange&&e.handleChange(...t)),class:"flex-shrink flex-grow flex-auto leading-normal w-px flex-1 rounded-l-none form-control form-input form-control-bordered",dusk:r.field.attribute}),null,16,n)])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","CurrencyField.vue"]])},18166:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={class:"flex items-center"},l=["id","dusk","name","value","disabled","min","max","step"];var a=r(91272),n=r(35229);const s={mixins:[n._w,n.Gj],methods:{setInitialValue(){null!=this.currentField.value&&(this.value=a.c9.fromISO(this.currentField.value||this.value).toISODate())},fill(e){this.currentlyIsVisible&&this.fillIfVisible(e,this.fieldAttribute,this.value)},handleChange(e){this.value=e?.target?.value??e,this.field&&this.emitFieldValueChange(this.fieldAttribute,this.value)}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(c,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("input",{type:"date",class:(0,o.normalizeClass)(["w-56 form-control form-input form-control-bordered",e.errorClasses]),ref:"dateTimePicker",id:e.currentField.uniqueKey,dusk:e.field.attribute,name:e.field.name,value:e.value,disabled:e.currentlyIsReadonly,onChange:t[0]||(t[0]=(...e)=>s.handleChange&&s.handleChange(...e)),min:e.currentField.min,max:e.currentField.max,step:e.currentField.step},null,42,l)])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","DateField.vue"]])},23019:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726);const i={class:"flex items-center"},l=["id","dusk","name","value","disabled","min","max","step"],a={class:"ml-3"};var n=r(91272),s=r(35229),c=r(70393);const d={mixins:[s._w,s.Gj],data:()=>({formattedDate:""}),methods:{setInitialValue(){if(null!=this.currentField.value){let e=n.c9.fromISO(this.currentField.value||this.value,{zone:Nova.config("timezone")});this.value=e.toString(),e=e.setZone(this.timezone),this.formattedDate=[e.toISODate(),e.toFormat(this.timeFormat)].join("T")}},fill(e){if(this.fillIfVisible(e,this.fieldAttribute,this.value||""),this.currentlyIsVisible&&(0,c.A)(this.value)){let e=n.c9.fromISO(this.value,{zone:this.timezone});this.formattedDate=[e.toISODate(),e.toFormat(this.timeFormat)].join("T")}},handleChange(e){let t=e?.target?.value??e;if((0,c.A)(t)){let e=n.c9.fromISO(t,{zone:this.timezone});this.value=e.setZone(Nova.config("timezone")).toString()}else this.value=this.fieldDefaultValue();this.field&&this.emitFieldValueChange(this.fieldAttribute,this.value)}},computed:{timeFormat(){return this.currentField.step%60==0?"HH:mm":"HH:mm:ss"},timezone:()=>Nova.config("userTimezone")||Nova.config("timezone")}};const u=(0,r(66262).A)(d,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(d,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("input",{type:"datetime-local",class:(0,o.normalizeClass)(["w-56 form-control form-input form-control-bordered",e.errorClasses]),ref:"dateTimePicker",id:e.currentField.uniqueKey,dusk:e.field.attribute,name:e.field.name,value:e.formattedDate,disabled:e.currentlyIsReadonly,onChange:t[0]||(t[0]=(...e)=>c.handleChange&&c.handleChange(...e)),min:e.currentField.min,max:e.currentField.max,step:e.currentField.step},null,42,l),(0,o.createElementVNode)("span",a,(0,o.toDisplayString)(c.timezone),1)])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","DateTimeField.vue"]])},36078:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i=["value","id","disabled","autocomplete","dusk"];var l=r(35229);function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function n(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const s={mixins:[l._w,l.Gj],computed:{extraAttributes(){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?a(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({type:this.currentField.type||"email",pattern:this.currentField.pattern,placeholder:this.placeholder,class:this.errorClasses},this.currentField.extraAttributes)}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(s,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("input",(0,o.mergeProps)(n.extraAttributes,{value:e.value,id:e.currentField.uniqueKey,disabled:e.currentlyIsReadonly,onInput:t[0]||(t[0]=(...t)=>e.handleChange&&e.handleChange(...t)),class:"w-full form-control form-input form-control-bordered",autocomplete:e.currentField.autocomplete,dusk:e.field.attribute}),null,16,i)])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","EmailField.vue"]])},22988:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i={class:"space-y-4"},l={key:0,class:"grid grid-cols-4 gap-x-6 gap-y-2"};var a=r(35229),n=r(96040),s=r(99300),c=r.n(s);function d(e){return{name:e.name,extension:e.name.split(".").pop(),type:e.type,originalFile:e,vapor:!1,processing:!1,progress:0}}const u={emits:["file-upload-started","file-upload-finished","file-deleted"],mixins:[a._w,a.Gj],inject:["removeFile"],expose:["beforeRemove"],data:()=>({previewFile:null,file:null,removeModalOpen:!1,missing:!1,deleted:!1,uploadErrors:new a.I,vaporFile:{key:"",uuid:"",filename:"",extension:""},uploadProgress:0,startedDrag:!1,uploadModalShown:!1}),async mounted(){this.preparePreviewImage(),this.field.fill=e=>{let t=this.fieldAttribute;this.file&&!this.isVaporField&&e.append(t,this.file.originalFile,this.file.name),this.file&&this.isVaporField&&(e.append(t,this.file.name),this.fillVaporFilePayload(e,t))}},methods:{preparePreviewImage(){this.hasValue&&this.imageUrl&&this.fetchPreviewImage(),this.hasValue&&!this.imageUrl&&(this.previewFile=d({name:this.currentField.value,type:this.currentField.value.split(".").pop()}))},async fetchPreviewImage(){let e=await fetch(this.imageUrl),t=await e.blob();this.previewFile=d(new File([t],this.currentField.value,{type:t.type}))},handleFileChange(e){this.file=d(e[0]),this.isVaporField&&(this.file.vapor=!0,this.uploadVaporFiles())},uploadVaporFiles(){this.file.processing=!0,this.$emit("file-upload-started"),c().store(this.file.originalFile,{progress:e=>{this.file.progress=Math.round(100*e)}}).then((e=>{this.vaporFile.key=e.key,this.vaporFile.uuid=e.uuid,this.vaporFile.filename=this.file.name,this.vaporFile.extension=this.file.extension,this.file.processing=!1,this.file.progress=100,this.$emit("file-upload-finished")})).catch((e=>{403===e.response.status&&Nova.error(this.__("Sorry! You are not authorized to perform this action."))}))},confirmRemoval(){this.removeModalOpen=!0},closeRemoveModal(){this.removeModalOpen=!1},beforeRemove(){this.removeUploadedFile()},async removeUploadedFile(){try{await this.removeFile(this.fieldAttribute),this.$emit("file-deleted"),this.deleted=!0,this.file=null,Nova.success(this.__("The file was deleted!"))}catch(e){422===e.response?.status&&(this.uploadErrors=new a.I(e.response.data.errors))}finally{this.closeRemoveModal()}},fillVaporFilePayload(e,t){const r=e instanceof n.A?e.slug(t):t,o=e instanceof n.A?e.formData:e;o.append(`vaporFile[${r}][key]`,this.vaporFile.key),o.append(`vaporFile[${r}][uuid]`,this.vaporFile.uuid),o.append(`vaporFile[${r}][filename]`,this.vaporFile.filename),o.append(`vaporFile[${r}][extension]`,this.vaporFile.extension)}},computed:{files(){return this.file?[this.file]:[]},hasError(){return this.uploadErrors.has(this.fieldAttribute)},firstError(){if(this.hasError)return this.uploadErrors.first(this.fieldAttribute)},idAttr(){return this.labelFor},labelFor(){let e=this.resourceName;return this.relatedResourceName&&(e+="-"+this.relatedResourceName),`file-${e}-${this.fieldAttribute}`},hasValue(){return Boolean(this.field.value||this.imageUrl)&&!Boolean(this.deleted)&&!Boolean(this.missing)},shouldShowLoader(){return!Boolean(this.deleted)&&Boolean(this.imageUrl)},shouldShowField(){return Boolean(!this.currentlyIsReadonly)},shouldShowRemoveButton(){return Boolean(this.currentField.deletable&&!this.currentlyIsReadonly)},imageUrl(){return this.currentField.previewUrl||this.currentField.thumbnailUrl},isVaporField(){return"vapor-file-field"===this.currentField.component}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("FilePreviewBlock"),d=(0,o.resolveComponent)("ConfirmUploadRemovalModal"),u=(0,o.resolveComponent)("DropZone"),p=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(p,{field:e.currentField,"label-for":s.labelFor,errors:e.errors,"show-help-text":!e.isReadonly&&e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[s.hasValue&&e.previewFile&&0===s.files.length?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[e.previewFile?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,file:e.previewFile,removable:s.shouldShowRemoveButton,onRemoved:s.confirmRemoval,rounded:e.field.rounded,dusk:`${e.field.attribute}-delete-link`},null,8,["file","removable","onRemoved","rounded","dusk"])):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0),(0,o.createVNode)(d,{show:e.removeModalOpen,onConfirm:s.removeUploadedFile,onClose:s.closeRemoveModal},null,8,["show","onConfirm","onClose"]),s.shouldShowField?((0,o.openBlock)(),(0,o.createBlock)(u,{key:1,files:s.files,onFileChanged:s.handleFileChange,onFileRemoved:t[0]||(t[0]=t=>e.file=null),rounded:e.field.rounded,"accepted-types":e.field.acceptedTypes,disabled:e.file?.processing,dusk:`${e.field.attribute}-delete-link`,"input-dusk":e.field.attribute},null,8,["files","onFileChanged","rounded","accepted-types","disabled","dusk","input-dusk"])):(0,o.createCommentVNode)("",!0)])])),_:1},8,["field","label-for","errors","show-help-text","full-width-content"])}],["__file","FileField.vue"]])},58116:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>k});var o=r(29726);const i={key:1,class:"flex flex-col justify-center items-center px-6 py-8"},l=["dusk"],a={class:"hidden md:inline-block"},n={class:"inline-block md:hidden"};var s=r(35229),c=r(96040),d=r(55378),u=r.n(d),p=r(48081),h=r.n(p),m=r(15101),f=r.n(m);function v(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function g(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?v(Object(r),!0).forEach((function(t){y(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):v(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function y(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const b={emits:["field-changed","update-last-retrieved-at-timestamp","file-upload-started","file-upload-finished"],mixins:[s._w,s.zB],provide(){return{removeFile:this.removeFile}},props:g(g({},(0,s.rr)(["resourceName","resourceId","viaResource","viaResourceId","viaRelationship"])),{},{field:{type:Object},formUniqueId:{type:String},errors:{type:Object,required:!0}}),data(){return{loading:!1,isEditing:null!==this.field.hasOneId||!0===this.field.required,fields:[]}},mounted(){this.initializeComponent()},methods:{initializeComponent(){this.getFields(),this.field.fill=this.fill},removeFile(e){const{resourceName:t,resourceId:r}=this;Nova.request().delete(`/nova-api/${t}/${r}/field/${e}`)},fill(e){this.isEditing&&this.isVisible&&f()(new c.A(this.fieldAttribute,e),(e=>{this.availableFields.forEach((t=>{t.fill(e)}))}))},async getFields(){this.loading=!0,this.panels=[],this.fields=[];try{const{data:{title:e,panels:t,fields:r}}=await Nova.request().get(this.getFieldsEndpoint,{params:{editing:!0,editMode:this.editMode,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,relationshipType:this.field.relationshipType}});this.fields=u()(r,(e=>(e.resourceName!==this.field.from.viaResource||"belongsTo"!==e.relationshipType||"create"!==this.editMode&&e.belongsToId.toString()!==this.field.from.viaResourceId.toString()?"morphTo"===e.relationshipType&&("create"===this.editMode||e.resourceName===this.field.from.viaResource&&e.morphToId.toString()===this.field.from.viaResourceId.toString())&&(e.visible=!1,e.fill=()=>{}):(e.visible=!1,e.fill=()=>{}),e.validationKey=`${this.fieldAttribute}.${e.validationKey}`,e))),this.loading=!1,Nova.$emit("resource-loaded",{resourceName:this.resourceName,resourceId:this.resourceId?this.resourceId.toString():null,mode:this.editMode})}catch(e){[403,404].includes(e.response.status)&&Nova.error(this.__("There was a problem fetching the resource."))}},showEditForm(){this.isEditing=!0},handleFileDeleted(){this.$emit("update-last-retrieved-at-timestamp")}},computed:{availableFields(){return h()(this.fields,(e=>["relationship-panel"].includes(e.component)&&["hasOne","morphOne"].includes(e.fields[0].relationshipType)||e.readonly))},getFieldsEndpoint(){return"update"===this.editMode?`/nova-api/${this.resourceName}/${this.resourceId}/update-fields`:`/nova-api/${this.resourceName}/creation-fields`},editMode(){return null===this.field.hasOneId?"create":"update"}}};const k=(0,r(66262).A)(b,[["render",function(e,t,r,s,c,d){const u=(0,o.resolveComponent)("LoadingView"),p=(0,o.resolveComponent)("Card");return(0,o.openBlock)(),(0,o.createBlock)(p,null,{default:(0,o.withCtx)((()=>[(0,o.createVNode)(u,{loading:c.loading},{default:(0,o.withCtx)((()=>[c.isEditing?((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,{key:0},(0,o.renderList)(d.availableFields,((i,l)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(`form-${i.component}`),{index:l,key:l,errors:r.errors,"resource-id":e.resourceId,"resource-name":e.resourceName,field:i,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"shown-via-new-relation-modal":!1,"form-unique-id":r.formUniqueId,onFieldChanged:t[0]||(t[0]=t=>e.$emit("field-changed")),onFileDeleted:d.handleFileDeleted,onFileUploadStarted:t[1]||(t[1]=t=>e.$emit("file-upload-started")),onFileUploadFinished:t[2]||(t[2]=t=>e.$emit("file-upload-finished")),"show-help-text":e.showHelpText},null,40,["index","errors","resource-id","resource-name","field","via-resource","via-resource-id","via-relationship","form-unique-id","onFileDeleted","show-help-text"])))),128)):((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("button",{class:"focus:outline-none focus:ring rounded border-2 border-primary-300 dark:border-gray-500 hover:border-primary-500 active:border-primary-400 dark:hover:border-gray-400 dark:active:border-gray-300 bg-white dark:bg-transparent text-primary-500 dark:text-gray-400 px-3 h-9 inline-flex items-center font-bold shrink-0",dusk:`create-${r.field.attribute}-relation-button`,onClick:t[3]||(t[3]=(0,o.withModifiers)(((...e)=>d.showEditForm&&d.showEditForm(...e)),["prevent"])),type:"button"},[(0,o.createElementVNode)("span",a,(0,o.toDisplayString)(e.__("Create :resource",{resource:r.field.singularLabel})),1),(0,o.createElementVNode)("span",n,(0,o.toDisplayString)(e.__("Create")),1)],8,l)]))])),_:1},8,["loading"])])),_:1})}],["__file","HasOneField.vue"]])},79899:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i=["innerHTML"];const l={mixins:[r(35229).Gj],props:{index:{type:Number},resourceName:{type:String,require:!0},field:{type:Object,require:!0},errors:{type:Object,required:!0}},methods:{fillIfVisible(e,t,r){}},computed:{classes:()=>["remove-last-margin-bottom","leading-normal","w-full","py-4","px-8"],shouldDisplayAsHtml(){return this.currentField.asHtml||!1}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("Heading"),c=(0,o.resolveComponent)("FieldWrapper");return e.currentField.visible?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0},{default:(0,o.withCtx)((()=>[n.shouldDisplayAsHtml?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,innerHTML:e.currentField.value,class:(0,o.normalizeClass)(n.classes)},null,10,i)):((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:1,class:(0,o.normalizeClass)(n.classes)},[(0,o.createVNode)(s,{level:3},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.currentField.value),1)])),_:1})],2))])),_:1})):(0,o.createCommentVNode)("",!0)}],["__file","HeadingField.vue"]])},6970:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={class:"hidden"},l=["dusk","value"];var a=r(35229);const n={mixins:[a.Gj,a._w]};const s=(0,r(66262).A)(n,[["render",function(e,t,r,a,n,s){return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("input",{dusk:e.field.attribute,type:"hidden",value:e.value},null,8,l)])}],["__file","HiddenField.vue"]])},18053:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>y});var o=r(29726);const i={class:"bg-white dark:bg-gray-800 overflow-hidden key-value-items"},l={class:"flex items-center justify-center"};var a=r(24713),n=r.n(a),s=r(44377),c=r.n(s),d=r(48081),u=r.n(d),p=r(15101),h=r.n(p),m=r(35229),f=r(74640);function v(){var e=function(){return(65536*(1+Math.random())|0).toString(16).substring(1)};return e()+e()+"-"+e()+"-"+e()+"-"+e()+"-"+e()+e()+e()}const g={mixins:[m._w,m.Gj],components:{Button:f.Button},data:()=>({theData:[]}),mounted(){this.populateKeyValueData()},methods:{populateKeyValueData(){this.theData=Object.entries(this.value||{}).map((([e,t])=>({id:v(),key:`${e}`,value:t})))},fill(e){this.fillIfVisible(e,this.fieldAttribute,JSON.stringify(this.finalPayload))},addRow(){return h()(v(),(e=>(this.theData=[...this.theData,{id:e,key:"",value:""}],e)))},addRowAndSelect(){return this.selectRow(this.addRow())},removeRow(e){return h()(n()(this.theData,(t=>t.id===e)),(e=>this.theData.splice(e,1)))},selectRow(e){return this.$nextTick((()=>{this.$refs[e][0].handleKeyFieldFocus()}))},onSyncedField(){this.populateKeyValueData()}},computed:{finalPayload(){return c()(u()(this.theData.map((e=>e&&e.key?[e.key,e.value]:void 0)),(e=>void 0===e)))}}};const y=(0,r(66262).A)(g,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("FormKeyValueHeader"),d=(0,o.resolveComponent)("FormKeyValueItem"),u=(0,o.resolveComponent)("FormKeyValueTable"),p=(0,o.resolveComponent)("Button"),h=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(h,{field:e.currentField,errors:e.errors,"full-width-content":e.fullWidthContent||["modal","action-modal"].includes(e.mode),"show-help-text":e.showHelpText},{field:(0,o.withCtx)((()=>[(0,o.withDirectives)((0,o.createVNode)(u,{"edit-mode":!e.currentlyIsReadonly,"can-delete-row":e.currentField.canDeleteRow},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(c,{"key-label":e.currentField.keyLabel,"value-label":e.currentField.valueLabel},null,8,["key-label","value-label"]),(0,o.createElementVNode)("div",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.theData,((t,r)=>((0,o.openBlock)(),(0,o.createBlock)(d,{index:r,onRemoveRow:s.removeRow,item:t,key:t.id,ref_for:!0,ref:t.id,"read-only":e.currentlyIsReadonly,"read-only-keys":e.currentField.readonlyKeys,"can-delete-row":e.currentField.canDeleteRow},null,8,["index","onRemoveRow","item","read-only","read-only-keys","can-delete-row"])))),128))])])),_:1},8,["edit-mode","can-delete-row"]),[[o.vShow,e.theData.length>0]]),(0,o.createElementVNode)("div",l,[e.currentlyIsReadonly||e.currentField.readonlyKeys||!e.currentField.canAddRow?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createBlock)(p,{key:0,onClick:s.addRowAndSelect,dusk:`${e.field.attribute}-add-key-value`,"leading-icon":"plus-circle",variant:"link"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.currentField.actionText),1)])),_:1},8,["onClick","dusk"]))])])),_:1},8,["field","errors","full-width-content","show-help-text"])}],["__file","KeyValueField.vue"]])},99682:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={class:"bg-gray-100 dark:bg-gray-800 rounded-t-lg flex border-b border-gray-200 dark:border-gray-700"},l={class:"bg-clip w-48 uppercase font-bold text-xxs text-gray-500 tracking-wide px-3 py-2"},a={class:"bg-clip flex-grow uppercase font-bold text-xxs text-gray-500 tracking-wide px-3 py-2 border-l border-gray-200 dark:border-gray-700"};const n={props:{keyLabel:{type:String},valueLabel:{type:String}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,n,s,c){return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("div",l,(0,o.toDisplayString)(r.keyLabel),1),(0,o.createElementVNode)("div",a,(0,o.toDisplayString)(r.valueLabel),1)])}],["__file","KeyValueHeader.vue"]])},5226:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i={key:0,class:"flex items-center key-value-item"},l={class:"flex flex-grow border-b border-gray-200 dark:border-gray-700 key-value-fields"},a=["dusk","readonly","tabindex"],n=["dusk","readonly","tabindex"],s={key:0,class:"flex items-center h-11 w-11 absolute -right-[50px]"};var c=r(89692),d=r.n(c);const u={components:{Button:r(74640).Button},emits:["remove-row"],props:{index:Number,item:Object,editMode:{type:Boolean,default:!0},readOnly:{type:Boolean,default:!1},readOnlyKeys:{type:Boolean,default:!1},canDeleteRow:{type:Boolean,default:!0}},mounted(){this.$nextTick((()=>{d()(this.$refs.keyField),d()(this.$refs.valueField)}))},methods:{handleKeyFieldFocus(){d()(this.$refs.keyField),this.$refs.keyField.select()},handleValueFieldFocus(){d()(this.$refs.valueField),this.$refs.valueField.select()}},computed:{isNotObject(){return!(this.item.value instanceof Object)},isEditable(){return!this.readOnly},defaultBackgroundColors:()=>"bg-white dark:bg-gray-900",disabledBackgroundColors(){return!0===this.editMode?"bg-gray-50 dark:bg-gray-700":this.defaultBackgroundColors}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("Button");return u.isNotObject?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["flex-none w-48",[!u.isEditable||r.readOnlyKeys?u.disabledBackgroundColors:u.defaultBackgroundColors,!0===r.editMode?"cursor-text":"cursor-default"]]),onClick:t[2]||(t[2]=(...e)=>u.handleKeyFieldFocus&&u.handleKeyFieldFocus(...e))},[(0,o.withDirectives)((0,o.createElementVNode)("textarea",{rows:"1",dusk:`key-value-key-${r.index}`,"onUpdate:modelValue":t[0]||(t[0]=e=>r.item.key=e),onFocus:t[1]||(t[1]=(...e)=>u.handleKeyFieldFocus&&u.handleKeyFieldFocus(...e)),ref:"keyField",type:"text",class:(0,o.normalizeClass)(["font-mono text-xs resize-none block w-full px-3 py-3 dark:text-gray-400 bg-clip-border",[!u.isEditable||r.readOnlyKeys?`${u.disabledBackgroundColors} focus:outline-none cursor-normal`:u.defaultBackgroundColors,!0===r.editMode?"hover:bg-20 focus:bg-white dark:focus:bg-gray-900 focus:outline-none focus:ring focus:ring-inset":"focus:outline-none cursor-default"]]),readonly:!u.isEditable||r.readOnlyKeys,tabindex:!u.isEditable||r.readOnlyKeys?-1:0,style:{"background-clip":"border-box"}},null,42,a),[[o.vModelText,r.item.key]])],2),(0,o.createElementVNode)("div",{onClick:t[5]||(t[5]=(...e)=>u.handleValueFieldFocus&&u.handleValueFieldFocus(...e)),class:(0,o.normalizeClass)(["flex-grow border-l border-gray-200 dark:border-gray-700",[u.isEditable?u.defaultBackgroundColors:u.disabledBackgroundColors,!0===r.editMode?"cursor-text":"cursor-default"]])},[(0,o.withDirectives)((0,o.createElementVNode)("textarea",{rows:"1",dusk:`key-value-value-${r.index}`,"onUpdate:modelValue":t[3]||(t[3]=e=>r.item.value=e),onFocus:t[4]||(t[4]=(...e)=>u.handleValueFieldFocus&&u.handleValueFieldFocus(...e)),ref:"valueField",type:"text",class:(0,o.normalizeClass)(["font-mono text-xs block w-full px-3 py-3 dark:text-gray-400 bg-clip-border",[u.isEditable?u.defaultBackgroundColors:`${u.disabledBackgroundColors} focus:outline-none cursor-normal`,!0===r.editMode?"hover:bg-20 focus:bg-white dark:focus:bg-gray-900 focus:outline-none focus:ring focus:ring-inset":"focus:outline-none cursor-default"]]),readonly:!u.isEditable,tabindex:u.isEditable?0:-1},null,42,n),[[o.vModelText,r.item.value]])],2)]),u.isEditable&&r.canDeleteRow?((0,o.openBlock)(),(0,o.createElementBlock)("div",s,[(0,o.createVNode)(p,{onClick:t[6]||(t[6]=t=>e.$emit("remove-row",r.item.id)),dusk:`remove-key-value-${r.index}`,variant:"link",size:"small",state:"danger",type:"button",tabindex:"0",title:e.__("Delete"),icon:"minus-circle"},null,8,["dusk","title"])])):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0)}],["__file","KeyValueItem.vue"]])},83420:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:{canDeleteRow:{type:Boolean,default:!0},editMode:{type:Boolean,default:!0}}};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(["relative rounded-lg rounded-b-lg bg-gray-100 dark:bg-gray-800 bg-clip border border-gray-200 dark:border-gray-700",{"mr-11":r.editMode&&r.canDeleteRow}])},[(0,o.renderSlot)(e.$slots,"default")],2)}],["__file","KeyValueTable.vue"]])},19399:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);var i=r(35229);const l={mixins:[i._w,i.Qy,i.Vo,i.Gj],props:(0,i.rr)(["resourceName","resourceId","mode"]),beforeUnmount(){Nova.$off(this.fieldAttributeValueEventName,this.listenToValueChanges),this.clearAttachments(),this.clearFilesMarkedForRemoval()},methods:{initialize(){this.$refs.theMarkdownEditor.setValue(this.value??this.currentField.value),Nova.$on(this.fieldAttributeValueEventName,this.listenToValueChanges)},fill(e){this.fillIfVisible(e,this.fieldAttribute,this.value||""),this.fillAttachmentDraftId(e)},handleFileRemoved(e){this.flagFileForRemoval(e)},handleFileAdded(e){this.unflagFileForRemoval(e)},handleChange(e){this.value=e,this.field&&this.emitFieldValueChange(this.fieldAttribute,this.value)},onSyncedField(){this.currentlyIsVisible&&this.$refs.theMarkdownEditor&&(this.$refs.theMarkdownEditor.setValue(this.currentField.value??this.value),this.$refs.theMarkdownEditor.setOption("readOnly",this.currentlyIsReadonly))},listenToValueChanges(e){this.currentlyIsVisible&&this.$refs.theMarkdownEditor.setValue(e),this.handleChange(e)}},computed:{previewer(){if(!this.isActionRequest)return this.fetchPreviewContent},uploader(){if(!this.isActionRequest&&this.field.withFiles)return this.uploadAttachment}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("MarkdownEditor"),s=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(s,{field:e.currentField,errors:e.errors,"full-width-content":e.fullWidthContent,"show-help-text":e.showHelpText},{field:(0,o.withCtx)((()=>[(0,o.withDirectives)((0,o.createVNode)(n,{ref:"theMarkdownEditor",class:(0,o.normalizeClass)({"form-control-bordered-error":e.hasError}),attribute:e.field.attribute,previewer:a.previewer,uploader:a.uploader,readonly:e.currentlyIsReadonly,onFileRemoved:a.handleFileRemoved,onFileAdded:a.handleFileAdded,onInitialize:a.initialize,onChange:a.handleChange},null,8,["class","attribute","previewer","uploader","readonly","onFileRemoved","onFileAdded","onInitialize","onChange"]),[[o.vShow,e.currentlyIsVisible]])])),_:1},8,["field","errors","full-width-content","show-help-text"])}],["__file","MarkdownField.vue"]])},69976:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>V});var o=r(29726);const i={class:"border-b border-gray-100 dark:border-gray-700"},l={key:0,class:"flex relative"},a=["disabled","dusk","value"],n=["disabled"],s=["value","selected"],c={class:"pointer-events-none absolute inset-y-0 right-[11px] flex items-center"},d={key:1,class:"flex items-center select-none mt-2"},u={class:"flex items-center mb-3"},p={key:0,class:"flex items-center"},h={key:0,class:"mr-3"},m=["src"],f={class:"flex items-center"},v={key:0,class:"flex-none mr-3"},g=["src"],y={class:"flex-auto"},b={key:0},k={key:1},w=["disabled","selected"];var C=r(74640);const x={fetchAvailableResources(e,t,r){if(void 0===e||null==t||null==r)throw new Error("please pass the right things");return Nova.request().get(`/nova-api/${e}/morphable/${t}`,r)},determineIfSoftDeletes:e=>Nova.request().get(`/nova-api/${e}/soft-deletes`)};var N=r(35229),B=r(70393);const S={components:{Button:C.Button},mixins:[N.Gj,N._w,N.XJ,N.Bz,N.zJ],data:()=>({resourceType:"",initializingWithExistingResource:!1,createdViaRelationModal:!1,softDeletes:!1,selectedResourceId:null,search:"",relationModalOpen:!1,withTrashed:!1}),mounted(){this.initializeComponent()},methods:{initializeComponent(){this.selectedResourceId=this.field.value,this.editingExistingResource?(this.initializingWithExistingResource=!0,this.resourceType=this.field.morphToType,this.selectedResourceId=this.field.morphToId):this.viaRelatedResource&&(this.initializingWithExistingResource=!0,this.resourceType=this.viaResource,this.selectedResourceId=this.viaResourceId),this.shouldSelectInitialResource&&(!this.resourceType&&this.field.defaultResource&&(this.resourceType=this.field.defaultResource),this.getAvailableResources()),this.resourceType&&this.determineIfSoftDeletes(),this.field.fill=this.fill},selectResourceFromSelectOrSearch(e){this.field&&this.emitFieldValueChange(`${this.fieldAttribute}_type`,this.resourceType),this.selectResource(e)},fill(e){this.selectedResourceId&&this.resourceType?(this.fillIfVisible(e,this.fieldAttribute,this.selectedResourceId??""),this.fillIfVisible(e,`${this.fieldAttribute}_type`,this.resourceType)):(this.fillIfVisible(e,this.fieldAttribute,""),this.fillIfVisible(e,`${this.fieldAttribute}_type`,"")),this.fillIfVisible(e,`${this.fieldAttribute}_trashed`,this.withTrashed)},getAvailableResources(e=""){return Nova.$progress.start(),x.fetchAvailableResources(this.resourceName,this.fieldAttribute,{params:this.queryParams}).then((({data:{resources:e,softDeletes:t,withTrashed:r}})=>{!this.initializingWithExistingResource&&this.isSearchable||(this.withTrashed=r),this.isSearchable&&(this.initializingWithExistingResource=!1),this.availableResources=e,this.softDeletes=t})).finally((()=>{Nova.$progress.done()}))},onSyncedField(){this.resourceType!==this.currentField.morphToType&&this.refreshResourcesForTypeChange(this.currentField.morphToType)},determineIfSoftDeletes(){return x.determineIfSoftDeletes(this.resourceType).then((({data:{softDeletes:e}})=>this.softDeletes=e))},async refreshResourcesForTypeChange(e){this.resourceType=e?.target?.value??e,this.availableResources=[],this.selectedResourceId=null,this.withTrashed=!1,this.softDeletes=!1,this.determineIfSoftDeletes(),!this.isSearchable&&this.resourceType&&this.getAvailableResources().then((()=>{this.emitFieldValueChange(`${this.fieldAttribute}_type`,this.resourceType),this.emitFieldValueChange(this.fieldAttribute,null)}))},toggleWithTrashed(){(0,B.A)(this.selectedResourceId)||(this.withTrashed=!this.withTrashed,this.isSearchable||this.getAvailableResources())},openRelationModal(){Nova.$emit("create-relation-modal-opened"),this.relationModalOpen=!0},closeRelationModal(){this.relationModalOpen=!1,Nova.$emit("create-relation-modal-closed")},handleSetResource({id:e}){this.closeRelationModal(),this.selectedResourceId=e,this.createdViaRelationModal=!0,this.initializingWithExistingResource=!0,this.getAvailableResources().then((()=>{this.emitFieldValueChange(`${this.fieldAttribute}_type`,this.resourceType),this.emitFieldValueChange(this.fieldAttribute,this.selectedResourceId)}))},performResourceSearch(e){this.useSearchInput?this.performSearch(e):this.search=e},clearResourceSelection(){this.clearSelection(),this.viaRelatedResource&&!this.createdViaRelationModal?this.pushAfterUpdatingQueryString({viaResource:null,viaResourceId:null,viaRelationship:null,relationshipType:null}).then((()=>{Nova.$router.reload({onSuccess:()=>{this.initializingWithExistingResource=!1,this.initializeComponent()}})})):(this.createdViaRelationModal&&(this.createdViaRelationModal=!1,this.initializingWithExistingResource=!1),this.getAvailableResources())},isSelectedResourceId(e){return null!=e&&e?.toString()===this.selectedResourceId?.toString()}},computed:{editingExistingResource(){return Boolean(this.field.morphToId&&this.field.morphToType)},viaRelatedResource(){return Boolean(null!=this.currentField.morphToTypes.find((e=>e.value==this.viaResource))&&this.viaResource&&this.viaResourceId&&this.currentField.reverse)},shouldSelectInitialResource(){return Boolean(this.editingExistingResource||this.viaRelatedResource||Boolean(this.field.value&&this.field.defaultResource))},isSearchable(){return Boolean(this.currentField.searchable)},shouldLoadFirstResource(){return(this.useSearchInput&&!this.shouldIgnoreViaRelatedResource&&this.shouldSelectInitialResource||this.createdViaRelationModal)&&this.initializingWithExistingResource},queryParams(){return{type:this.resourceType,current:this.selectedResourceId,first:this.shouldLoadFirstResource,search:this.search,withTrashed:this.withTrashed,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,component:this.field.dependentComponentKey,dependsOn:this.encodedDependentFieldValues,editing:!0,editMode:null==this.resourceId||""===this.resourceId?"create":"update"}},fieldName(){return this.field.name},fieldTypeName(){return this.resourceType&&this.currentField.morphToTypes.find((e=>e.value==this.resourceType))?.singularLabel||""},hasMorphToTypes(){return this.currentField.morphToTypes.length>0},authorizedToCreate(){return Nova.config("resources").find((e=>e.uriKey==this.resourceType))?.authorizedToCreate||!1},canShowNewRelationModal(){return this.currentField.showCreateRelationButton&&this.resourceType&&!this.shownViaNewRelationModal&&!this.viaRelatedResource&&!this.currentlyIsReadonly&&this.authorizedToCreate},shouldShowTrashed(){return this.softDeletes&&!this.viaRelatedResource&&!this.currentlyIsReadonly&&this.currentField.displaysWithTrashed},currentFieldValues(){return{[this.fieldAttribute]:this.value,[`${this.fieldAttribute}_type`]:this.resourceType}},filteredResources(){return this.isSearchable?this.availableResources:this.availableResources.filter((e=>e.display.toLowerCase().indexOf(this.search.toLowerCase())>-1||new String(e.value).indexOf(this.search)>-1))},shouldIgnoresViaRelatedResource(){return this.viaRelatedResource&&(0,B.A)(this.search)},useSearchInput(){return this.isSearchable||this.viaRelatedResource},selectedResource(){return this.availableResources.find((e=>this.isSelectedResourceId(e.value)))}}};const V=(0,r(66262).A)(S,[["render",function(e,t,r,C,x,N){const B=(0,o.resolveComponent)("IconArrow"),S=(0,o.resolveComponent)("DefaultField"),V=(0,o.resolveComponent)("SearchInput"),R=(0,o.resolveComponent)("SelectControl"),E=(0,o.resolveComponent)("Button"),_=(0,o.resolveComponent)("CreateRelationModal"),O=(0,o.resolveComponent)("TrashedCheckbox");return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createVNode)(S,{field:e.currentField,"show-errors":!1,"field-name":N.fieldName,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[N.hasMorphToTypes?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[(0,o.createElementVNode)("select",{disabled:N.viaRelatedResource&&!N.shouldIgnoresViaRelatedResource||e.currentlyIsReadonly,dusk:`${e.field.attribute}-type`,value:e.resourceType,onChange:t[0]||(t[0]=(...e)=>N.refreshResourcesForTypeChange&&N.refreshResourcesForTypeChange(...e)),class:"w-full block form-control form-input form-control-bordered"},[(0,o.createElementVNode)("option",{value:"",selected:"",disabled:!e.currentField.nullable},(0,o.toDisplayString)(e.__("Choose Type")),9,n),((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.currentField.morphToTypes,(t=>((0,o.openBlock)(),(0,o.createElementBlock)("option",{key:t.value,value:t.value,selected:e.resourceType==t.value},(0,o.toDisplayString)(t.singularLabel),9,s)))),128))],40,a),(0,o.createElementVNode)("span",c,[(0,o.createVNode)(B)])])):((0,o.openBlock)(),(0,o.createElementBlock)("label",d,(0,o.toDisplayString)(e.__("There are no available options for this resource.")),1))])),_:1},8,["field","field-name","show-help-text","full-width-content"]),N.hasMorphToTypes?((0,o.openBlock)(),(0,o.createBlock)(S,{key:0,field:e.currentField,errors:e.errors,"show-help-text":!1,"field-name":N.fieldTypeName,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",u,[N.useSearchInput?((0,o.openBlock)(),(0,o.createBlock)(V,{key:0,modelValue:e.selectedResourceId,"onUpdate:modelValue":t[1]||(t[1]=t=>e.selectedResourceId=t),onSelected:N.selectResourceFromSelectOrSearch,onInput:N.performResourceSearch,onClear:N.clearResourceSelection,options:N.filteredResources,disabled:e.currentlyIsReadonly,debounce:e.currentField.debounce,clearable:e.currentField.nullable||N.editingExistingResource||N.viaRelatedResource||e.createdViaRelationModal,trackBy:"value",mode:e.mode,autocomplete:e.currentField.autocomplete,class:"w-full",dusk:`${e.field.attribute}-search-input`},{option:(0,o.withCtx)((({selected:t,option:r})=>[(0,o.createElementVNode)("div",f,[r.avatar?((0,o.openBlock)(),(0,o.createElementBlock)("div",v,[(0,o.createElementVNode)("img",{src:r.avatar,class:"w-8 h-8 rounded-full block"},null,8,g)])):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",y,[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["text-sm font-semibold leading-5",{"text-white":t}])},(0,o.toDisplayString)(r.display),3),e.currentField.withSubtitles?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,class:(0,o.normalizeClass)(["mt-1 text-xs font-semibold leading-5 text-gray-500",{"text-white":t}])},[r.subtitle?((0,o.openBlock)(),(0,o.createElementBlock)("span",b,(0,o.toDisplayString)(r.subtitle),1)):((0,o.openBlock)(),(0,o.createElementBlock)("span",k,(0,o.toDisplayString)(e.__("No additional information...")),1))],2)):(0,o.createCommentVNode)("",!0)])])])),default:(0,o.withCtx)((()=>[N.selectedResource?((0,o.openBlock)(),(0,o.createElementBlock)("div",p,[N.selectedResource.avatar?((0,o.openBlock)(),(0,o.createElementBlock)("div",h,[(0,o.createElementVNode)("img",{src:N.selectedResource.avatar,class:"w-8 h-8 rounded-full block"},null,8,m)])):(0,o.createCommentVNode)("",!0),(0,o.createTextVNode)(" "+(0,o.toDisplayString)(N.selectedResource.display),1)])):(0,o.createCommentVNode)("",!0)])),_:1},8,["modelValue","onSelected","onInput","onClear","options","disabled","debounce","clearable","mode","autocomplete","dusk"])):((0,o.openBlock)(),(0,o.createBlock)(R,{key:1,modelValue:e.selectedResourceId,"onUpdate:modelValue":t[2]||(t[2]=t=>e.selectedResourceId=t),onSelected:N.selectResourceFromSelectOrSearch,options:e.availableResources,disabled:!e.resourceType||e.currentlyIsReadonly,label:"display",class:(0,o.normalizeClass)(["w-full",{"form-control-bordered-error":e.hasError}]),dusk:`${e.field.attribute}-select`},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("option",{value:"",disabled:!e.currentField.nullable,selected:""===e.selectedResourceId},(0,o.toDisplayString)(e.__("Choose"))+" "+(0,o.toDisplayString)(N.fieldTypeName),9,w)])),_:1},8,["modelValue","onSelected","options","disabled","class","dusk"])),N.canShowNewRelationModal?((0,o.openBlock)(),(0,o.createBlock)(E,{key:2,variant:"link",size:"small","leading-icon":"plus-circle",onClick:N.openRelationModal,class:"ml-2",dusk:`${e.field.attribute}-inline-create`},null,8,["onClick","dusk"])):(0,o.createCommentVNode)("",!0)]),N.canShowNewRelationModal?((0,o.openBlock)(),(0,o.createBlock)(_,{key:0,show:e.relationModalOpen,size:e.field.modalSize,onSetResource:N.handleSetResource,onCreateCancelled:N.closeRelationModal,"resource-name":e.resourceType,"via-relationship":e.viaRelationship,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId},null,8,["show","size","onSetResource","onCreateCancelled","resource-name","via-relationship","via-resource","via-resource-id"])):(0,o.createCommentVNode)("",!0),N.shouldShowTrashed?((0,o.openBlock)(),(0,o.createBlock)(O,{key:1,class:"mt-3","resource-name":e.field.attribute,checked:e.withTrashed,onInput:N.toggleWithTrashed},null,8,["resource-name","checked","onInput"])):(0,o.createCommentVNode)("",!0)])),_:1},8,["field","errors","field-name","full-width-content"])):(0,o.createCommentVNode)("",!0)])}],["__file","MorphToField.vue"]])},6629:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>d});var o=r(29726);const i=["selected","disabled"];var l=r(35229),a=r(55364),n=r.n(a),s=r(70393);const c={mixins:[l._w,l.Gj],data:()=>({search:""}),methods:{setInitialValue(){let e=void 0!==this.currentField.value&&null!==this.currentField.value&&""!==this.currentField.value?n()(this.currentField.value||[],this.value):this.value,t=(this.currentField.options??[]).filter((t=>e.includes(t.value)||e.includes(t.value.toString())));this.value=t.map((e=>e.value))},fieldDefaultValue:()=>[],fill(e){this.fillIfVisible(e,this.fieldAttribute,JSON.stringify(this.value))},performSearch(e){this.search=e},handleChange(e){this.field&&this.emitFieldValueChange(this.fieldAttribute,this.value)},onSyncedField(){this.setInitialValue()}},computed:{filteredOptions(){return(this.currentField.options??[]).filter((e=>e.label.toString().toLowerCase().indexOf(this.search.toLowerCase())>-1))},placeholder(){return this.currentField.placeholder||this.__("Choose an option")},hasValue(){return Boolean(!(void 0===this.value||null===this.value||""===this.value))},shouldShowPlaceholder(){return(0,s.A)(this.currentField.placeholder)||this.currentField.nullable}}};const d=(0,r(66262).A)(c,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("MultiSelectControl"),c=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(c,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createVNode)(s,{id:e.currentField.uniqueKey,dusk:e.field.attribute,modelValue:e.value,"onUpdate:modelValue":[t[0]||(t[0]=t=>e.value=t),n.handleChange],class:(0,o.normalizeClass)(["w-full",e.errorClasses]),options:e.currentField.options,disabled:e.currentlyIsReadonly},{default:(0,o.withCtx)((()=>[n.shouldShowPlaceholder?((0,o.openBlock)(),(0,o.createElementBlock)("option",{key:0,value:"",selected:!n.hasValue,disabled:!e.currentField.nullable},(0,o.toDisplayString)(n.placeholder),9,i)):(0,o.createCommentVNode)("",!0)])),_:1},8,["id","dusk","modelValue","onUpdate:modelValue","class","options","disabled"])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","MultiSelectField.vue"]])},82437:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726);const i=["dusk"],l=["innerHTML"];var a=r(35229);function n(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function s(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?n(Object(r),!0).forEach((function(t){c(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):n(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function c(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const d={name:"FormPanel",mixins:[a.sK],emits:["field-changed","update-last-retrieved-at-timestamp","file-deleted","file-upload-started","file-upload-finished"],props:s(s({},(0,a.rr)(["mode"])),{},{shownViaNewRelationModal:{type:Boolean,default:!1},showHelpText:{type:Boolean,default:!1},panel:{type:Object,required:!0},name:{default:"Panel"},dusk:{type:String},fields:{type:Array,default:[]},formUniqueId:{type:String},validationErrors:{type:Object,required:!0},resourceName:{type:String,required:!0},resourceId:{type:[Number,String]},relatedResourceName:{type:String},relatedResourceId:{type:[Number,String]},viaResource:{type:String},viaResourceId:{type:[Number,String]},viaRelationship:{type:String}}),methods:{handleFileDeleted(){this.$emit("update-last-retrieved-at-timestamp")}}};const u=(0,r(66262).A)(d,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Heading"),d=(0,o.resolveComponent)("Card");return r.panel.fields.length>0?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,dusk:`${r.panel.attribute}-panel`},[(0,o.createVNode)(c,{level:1,class:(0,o.normalizeClass)(r.panel.helpText?"mb-2":"mb-3"),dusk:`${r.dusk}-heading`},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.panel.name),1)])),_:1},8,["class","dusk"]),r.panel.helpText?((0,o.openBlock)(),(0,o.createElementBlock)("p",{key:0,class:"text-gray-500 text-sm font-semibold italic mb-3",innerHTML:r.panel.helpText},null,8,l)):(0,o.createCommentVNode)("",!0),(0,o.createVNode)(d,{class:"divide-y divide-gray-100 dark:divide-gray-700"},{default:(0,o.withCtx)((()=>[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.panel.fields,((i,l)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(`form-${i.component}`),{index:l,key:l,errors:r.validationErrors,"resource-id":r.resourceId,"resource-name":r.resourceName,"related-resource-name":r.relatedResourceName,"related-resource-id":r.relatedResourceId,field:i,"via-resource":r.viaResource,"via-resource-id":r.viaResourceId,"via-relationship":r.viaRelationship,"shown-via-new-relation-modal":r.shownViaNewRelationModal,"form-unique-id":r.formUniqueId,mode:e.mode,onFieldShown:e.handleFieldShown,onFieldHidden:e.handleFieldHidden,onFieldChanged:t[0]||(t[0]=t=>e.$emit("field-changed")),onFileDeleted:s.handleFileDeleted,onFileUploadStarted:t[1]||(t[1]=t=>e.$emit("file-upload-started")),onFileUploadFinished:t[2]||(t[2]=t=>e.$emit("file-upload-finished")),"show-help-text":r.showHelpText},null,40,["index","errors","resource-id","resource-name","related-resource-name","related-resource-id","field","via-resource","via-resource-id","via-relationship","shown-via-new-relation-modal","form-unique-id","mode","onFieldShown","onFieldHidden","onFileDeleted","show-help-text"])))),128))])),_:1})],8,i)),[[o.vShow,e.visibleFieldsCount>0]]):(0,o.createCommentVNode)("",!0)}],["__file","Panel.vue"]])},13662:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i=["id","dusk","placeholder","autocomplete","disabled"];var l=r(35229);const a={mixins:[l._w,l.Gj]};const n=(0,r(66262).A)(a,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(s,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.withDirectives)((0,o.createElementVNode)("input",{id:e.currentField.uniqueKey,dusk:e.field.attribute,type:"password","onUpdate:modelValue":t[0]||(t[0]=t=>e.value=t),class:(0,o.normalizeClass)(["w-full form-control form-input form-control-bordered",e.errorClasses]),placeholder:e.placeholder,autocomplete:e.currentField.autocomplete,disabled:e.currentlyIsReadonly},null,10,i),[[o.vModelText,e.value]])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","PasswordField.vue"]])},52568:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i={key:0},l=["innerHTML"];var a=r(25542),n=r(35229);function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function c(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){d(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function d(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const u={name:"FormRelationshipPanel",emits:["field-changed","update-last-retrieved-at-timestamp","file-upload-started","file-upload-finished","file-deleted"],mixins:[n.x7],props:c(c({shownViaNewRelationModal:{type:Boolean,default:!1},showHelpText:{type:Boolean,default:!1},panel:{type:Object,required:!0},name:{default:"Relationship Panel"}},(0,n.rr)(["mode"])),{},{fields:{type:Array,default:[]},formUniqueId:{type:String},validationErrors:{type:Object,required:!0},resourceName:{type:String,required:!0},resourceId:{type:[Number,String]},viaResource:{type:String},viaResourceId:{type:[Number,String]},viaRelationship:{type:String}}),data:()=>({relationFormUniqueId:(0,a.L)()}),mounted(){this.field.authorizedToCreate||(this.field.fill=()=>{})},methods:{handleFileDeleted(){this.$emit("update-last-retrieved-at-timestamp")}},computed:{field(){return this.panel.fields[0]},relationId(){if(["hasOne","morphOne"].includes(this.field.relationshipType))return this.field.hasOneId}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Heading");return s.field.authorizedToCreate?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createVNode)(c,{level:4,class:(0,o.normalizeClass)(r.panel.helpText?"mb-2":"mb-3")},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.panel.name),1)])),_:1},8,["class"]),r.panel.helpText?((0,o.openBlock)(),(0,o.createElementBlock)("p",{key:0,class:"text-gray-500 text-sm font-semibold italic mb-3",innerHTML:r.panel.helpText},null,8,l)):(0,o.createCommentVNode)("",!0),((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(`form-${s.field.component}`),{errors:r.validationErrors,"resource-id":s.relationId,"resource-name":s.field.resourceName,field:s.field,"via-resource":s.field.from.viaResource,"via-resource-id":s.field.from.viaResourceId,"via-relationship":s.field.from.viaRelationship,"form-unique-id":e.relationFormUniqueId,mode:e.mode,onFieldChanged:t[0]||(t[0]=t=>e.$emit("field-changed")),onFileDeleted:s.handleFileDeleted,onFileUploadStarted:t[1]||(t[1]=t=>e.$emit("file-upload-started")),onFileUploadFinished:t[2]||(t[2]=t=>e.$emit("file-upload-finished")),"show-help-text":r.showHelpText},null,40,["errors","resource-id","resource-name","field","via-resource","via-resource-id","via-relationship","form-unique-id","mode","onFileDeleted","show-help-text"]))])):(0,o.createCommentVNode)("",!0)}],["__file","RelationshipPanel.vue"]])},7275:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726);const i=["dusk"];var l=r(74640),a=r(35229),n=r(88055),s=r.n(n),c=r(25542);const d={components:{Button:l.Button,Icon:l.Icon},mixins:[a.zB,a._w],provide(){return{removeFile:this.removeFile,shownViaNewRelationModal:(0,o.computed)((()=>this.shownViaNewRelationModal)),viaResource:(0,o.computed)((()=>this.viaResource)),viaResourceId:(0,o.computed)((()=>this.viaResourceId)),viaRelationship:(0,o.computed)((()=>this.viaRelationship)),resourceName:(0,o.computed)((()=>this.resourceName)),resourceId:(0,o.computed)((()=>this.resourceId))}},data:()=>({valueMap:new WeakMap}),beforeMount(){this.value.map((e=>(this.valueMap.set(e,(0,c.L)()),e)))},methods:{fieldDefaultValue:()=>[],removeFile(e){const{resourceName:t,resourceId:r,relatedResourceName:o,relatedResourceId:i,viaRelationship:l}=this,a=l&&o&&i?`/nova-api/${t}/${r}/${o}/${i}/field/${e}?viaRelationship=${l}`:`/nova-api/${t}/${r}/field/${e}`;Nova.request().delete(a)},fill(e){this.finalPayload.forEach(((t,r)=>{const o=`${this.fieldAttribute}[${r}]`;e.append(`${o}[type]`,t.type),Object.keys(t.fields).forEach((r=>{e.append(`${o}[fields][${r}]`,t.fields[r])}))}))},addItem(e){const t=this.currentField.repeatables.find((t=>t.type===e)),r=s()(t);this.valueMap.set(r,(0,c.L)()),this.value.push(r)},removeItem(e){const t=this.value.splice(e,1);this.valueMap.delete(t)},moveUp(e){const t=this.value.splice(e,1);this.value.splice(Math.max(0,e-1),0,t[0])},moveDown(e){const t=this.value.splice(e,1);this.value.splice(Math.min(this.value.length,e+1),0,t[0])}},computed:{finalPayload(){return this.value.map((e=>{const t=new FormData,r={};e.fields.forEach((e=>e.fill&&e.fill(t)));for(const e of t.entries())r[e[0]]=e[1];return{type:e.type,fields:r}}))}}};const u=(0,r(66262).A)(d,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("RepeaterRow"),c=(0,o.resolveComponent)("Button"),d=(0,o.resolveComponent)("Icon"),u=(0,o.resolveComponent)("DropdownMenuItem"),p=(0,o.resolveComponent)("DropdownMenu"),h=(0,o.resolveComponent)("Dropdown"),m=(0,o.resolveComponent)("InvertedButton"),f=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(f,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[e.value.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,class:"space-y-4",dusk:e.fieldAttribute},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.value,((t,r)=>((0,o.openBlock)(),(0,o.createBlock)(s,{dusk:`${r}-repeater-row`,"data-repeater-id":e.valueMap.get(t),item:t,index:r,key:e.valueMap.get(t),onClick:n.removeItem,errors:e.errors,sortable:e.currentField.sortable&&e.value.length>1,onMoveUp:n.moveUp,onMoveDown:n.moveDown,field:e.currentField,"via-parent":e.fieldAttribute},null,8,["dusk","data-repeater-id","item","index","onClick","errors","sortable","onMoveUp","onMoveDown","field","via-parent"])))),128))],8,i)):(0,o.createCommentVNode)("",!0),(0,o.createElementVNode)("div",null,[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["text-center",{"bg-gray-50 dark:bg-gray-900 rounded-lg border-4 dark:border-gray-600 border-dashed py-3":0===e.value.length}])},[e.currentField.repeatables.length>1?((0,o.openBlock)(),(0,o.createBlock)(h,{key:0},{menu:(0,o.withCtx)((()=>[(0,o.createVNode)(p,{class:"py-1"},{default:(0,o.withCtx)((()=>[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.currentField.repeatables,(e=>((0,o.openBlock)(),(0,o.createBlock)(u,{onClick:()=>n.addItem(e.type),as:"button",class:"space-x-2"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,[(0,o.createVNode)(d,{name:e.icon,type:"solid",class:"inline-block"},null,8,["name"])]),(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(e.singularLabel),1)])),_:2},1032,["onClick"])))),256))])),_:1})])),default:(0,o.withCtx)((()=>[(0,o.createVNode)(c,{variant:"link","leading-icon":"plus-circle","trailing-icon":"chevron-down"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Add item")),1)])),_:1})])),_:1})):((0,o.openBlock)(),(0,o.createBlock)(m,{key:1,onClick:t[0]||(t[0]=t=>n.addItem(e.currentField.repeatables[0].type)),type:"button"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(e.__("Add :resource",{resource:e.currentField.repeatables[0].singularLabel})),1)])),_:1}))],2)])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","RepeaterField.vue"]])},48924:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>d});var o=r(29726);const i={key:0,class:"flex items-center"},l=["disabled"];var a=r(35229),n=r(56170),s=r.n(n);const c={mixins:[a._w,a.Gj],data:()=>({value:null,search:""}),created(){this.value=this.field.value??this.fieldDefaultValue()},methods:{fieldDefaultValue:()=>null,fill(e){this.fillIfVisible(e,this.fieldAttribute,this.value??"")},performSearch(e){this.search=e},clearSelection(){this.value=this.fieldDefaultValue(),this.field&&this.emitFieldValueChange(this.fieldAttribute,this.value)},selectOption(e){null!=e?this.field&&this.emitFieldValueChange(this.fieldAttribute,this.value):this.clearSelection()},selectedValueFromOption(e){this.value=e?.value??this.fieldDefaultValue(),this.selectOption(e)},onSyncedField(){let e=null,t=!1;this.selectedOption&&(t=!0,e=this.currentField.options.find((e=>e.value===this.selectedOption.value)));let r=this.currentField.options.find((e=>e.value==this.currentField.value));if(null==e)return this.clearSelection(),void(this.currentField.value?this.selectedValueFromOption(r):t&&!this.currentField.nullable&&this.selectedValueFromOption(s()(this.currentField.options)));e&&r?this.selectedValueFromOption(r):this.selectedValueFromOption(e)}},computed:{isSearchable(){return this.currentField.searchable},filteredOptions(){return this.currentField.options.filter((e=>e.label.toString().toLowerCase().indexOf(this.search.toLowerCase())>-1))},placeholder(){return this.currentField.placeholder||this.__("Choose an option")},hasValue(){return Boolean(!(void 0===this.value||null===this.value||""===this.value))},selectedOption(){return this.currentField.options.find((e=>this.value===e.value||this.value===e.value.toString()))}}};const d=(0,r(66262).A)(c,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("SearchInput"),d=(0,o.resolveComponent)("SelectControl"),u=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(u,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[!e.currentlyIsReadonly&&s.isSearchable?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,modelValue:e.value,"onUpdate:modelValue":t[0]||(t[0]=t=>e.value=t),onSelected:s.selectOption,onInput:s.performSearch,onClear:s.clearSelection,options:s.filteredOptions,disabled:e.currentlyIsReadonly,"has-error":e.hasError,clearable:e.currentField.nullable,trackBy:"value",mode:e.mode,class:"w-full",dusk:`${e.field.attribute}-search-input`,autocomplete:e.currentField.autocomplete},{default:(0,o.withCtx)((()=>[s.selectedOption?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,(0,o.toDisplayString)(s.selectedOption.label),1)):(0,o.createCommentVNode)("",!0)])),option:(0,o.withCtx)((({selected:e,option:t})=>[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["flex items-center text-sm font-semibold leading-5",{"text-white":e}])},(0,o.toDisplayString)(t.label),3)])),_:1},8,["modelValue","onSelected","onInput","onClear","options","disabled","has-error","clearable","mode","dusk","autocomplete"])):((0,o.openBlock)(),(0,o.createBlock)(d,{key:1,modelValue:e.value,"onUpdate:modelValue":t[1]||(t[1]=t=>e.value=t),onSelected:s.selectOption,options:e.currentField.options,"has-error":e.hasError,disabled:e.currentlyIsReadonly,id:e.field.attribute,class:"w-full",dusk:e.field.attribute},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("option",{value:"",selected:"",disabled:!e.currentField.nullable},(0,o.toDisplayString)(s.placeholder),9,l)])),_:1},8,["modelValue","onSelected","options","has-error","disabled","id","dusk"]))])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","SelectField.vue"]])},81909:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i={class:"flex items-center"},l=["id","disabled","dusk"];var a=r(35229),n=r(38221),s=r.n(n);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function d(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const u={mixins:[a.Vo,a._w,a.zB],data:()=>({isListeningToChanges:!1,debouncedHandleChange:null}),mounted(){this.shouldRegisterInitialListener&&this.registerChangeListener()},beforeUnmount(){this.removeChangeListener()},methods:{registerChangeListener(){Nova.$on(this.eventName,s()(this.handleChange,250)),this.isListeningToChanges=!0},removeChangeListener(){!0===this.isListeningToChanges&&Nova.$off(this.eventName)},async handleChange(e){this.value=await this.fetchPreviewContent(e)},toggleCustomizeClick(){if(this.field.readonly)return this.removeChangeListener(),this.isListeningToChanges=!1,this.field.readonly=!1,this.field.extraAttributes.readonly=!1,this.field.showCustomizeButton=!1,void this.$refs.theInput.focus();this.registerChangeListener(),this.field.readonly=!0,this.field.extraAttributes.readonly=!0}},computed:{shouldRegisterInitialListener(){return!this.field.updating},eventName(){return this.getFieldAttributeChangeEventName(this.field.from)},placeholder(){return this.field.placeholder??null},extraAttributes(){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){d(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({class:this.errorClasses,placeholder:this.placeholder},this.field.extraAttributes)}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(c,{field:e.field,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.withDirectives)((0,o.createElementVNode)("input",(0,o.mergeProps)(s.extraAttributes,{ref:"theInput","onUpdate:modelValue":t[0]||(t[0]=t=>e.value=t),id:e.field.uniqueKey,disabled:e.isReadonly,class:"w-full form-control form-input form-control-bordered",dusk:e.field.attribute,autocomplete:"off",spellcheck:"false"}),null,16,l),[[o.vModelDynamic,e.value]]),e.field.showCustomizeButton?((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:0,class:"rounded inline-flex text-sm ml-3 link-default",type:"button",onClick:t[1]||(t[1]=(...e)=>s.toggleCustomizeClick&&s.toggleCustomizeClick(...e))},(0,o.toDisplayString)(e.__("Customize")),1)):(0,o.createCommentVNode)("",!0)])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","SlugField.vue"]])},48080:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i=["id","type","min","max","step","placeholder","autocomplete"];var l=r(35229);const a={mixins:[l._w,l.Gj],computed:{inputType(){return this.currentField.type||"text"},inputStep(){return this.currentField.step},inputMin(){return this.currentField.min},inputMax(){return this.currentField.max}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(s,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.withDirectives)((0,o.createElementVNode)("input",{id:e.currentField.uniqueKey,type:n.inputType,min:n.inputMin,max:n.inputMax,step:n.inputStep,"onUpdate:modelValue":t[0]||(t[0]=t=>e.value=t),class:(0,o.normalizeClass)(["w-full form-control form-input form-control-bordered",e.errorClasses]),placeholder:e.placeholder,autocomplete:e.currentField.autocomplete},null,10,i),[[o.vModelDynamic,e.value]])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","StatusField.vue"]])},19736:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>w});var o=r(29726),i=r(35229),l=r(38402),a=r(14788),n=r(39754),s=r.n(n),c=r(79859),d=r.n(c),u=r(42877),p=r.n(u);function h(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function m(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const f=["dusk"],v=["innerHTML"],g=["dusk","disabled"],y={class:"capitalize"},b={class:"divide-y divide-gray-100 dark:divide-gray-700"},k={__name:"TabsPanel",props:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?h(Object(r),!0).forEach((function(t){m(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):h(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({name:{type:String,default:"Panel"},panel:{type:Object,required:!0},fields:{type:Array,default:[]},formUniqueId:{type:String,required:!1},validationErrors:{type:Object,required:!1}},(0,i.rr)(["shownViaNewRelationModal","mode","resourceName","resourceId","relatedResourceName","relatedResourceId","viaResource","viaResourceId","viaRelationship"])),emits:["field-changed","field-shown","field-hidden","update-last-retrieved-at-timestamp","file-upload-started","file-upload-finished"],setup(e,{emit:t}){const r=t,i=e,n=(0,o.computed)((()=>{const e=i.panel.fields.reduce(((e,t)=>(t.tab?.attribute in e||(e[t.tab.attribute]={name:t.tab.name,attribute:t.tab.attribute,position:t.tab.position,init:!1,listable:t.tab.listable,fields:[],meta:t.tab.meta,classes:"fields-tab",visibleFieldsForPanel:null,hasErrors:!1},["belongs-to-many-field","has-many-field","has-many-through-field","has-one-through-field","morph-to-many-field"].includes(t.component)&&(e[t.tab.attribute].classes="relationship-tab")),e[t.tab.attribute].fields.push(t),e)),{});return s()(e,(e=>{const t=Object.keys(i.validationErrors.errors).some((t=>d()(e.fields.map((e=>e.attribute)),t)));e.hasErrors=t,e.visibleFieldsForPanel=(0,l.y)(e,r)})),e}));function c(e){return Object.values(p()(e,[e=>e.position],["asc"]))}function u(e){return e.prefixComponent?`form-${e.component}`:e.component}function h(e){return"hasOne"===e.relationshipType||"morphOne"===e.relationshipType?e.hasOneId:this.resourceId}return(t,r)=>{const i=(0,o.resolveComponent)("Heading");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:"tab-group",dusk:`${e.panel.attribute}-tab-panel`},[(0,o.createElementVNode)("div",null,[e.panel.showTitle?((0,o.openBlock)(),(0,o.createBlock)(i,{key:0,level:1,textContent:(0,o.toDisplayString)(e.panel.name)},null,8,["textContent"])):(0,o.createCommentVNode)("",!0),e.panel.helpText?((0,o.openBlock)(),(0,o.createElementBlock)("p",{key:1,class:(0,o.normalizeClass)(["text-gray-500 text-sm font-semibold italic",e.panel.helpText?"mt-2":"mt-3"]),innerHTML:e.panel.helpText},null,10,v)):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["tab-card",[e.panel.showTitle&&!e.panel.showToolbar?"mt-3":""]])},[(0,o.createVNode)((0,o.unref)(a.fu),null,{default:(0,o.withCtx)((()=>[(0,o.createVNode)((0,o.unref)(a.wb),{"aria-label":e.panel.name,class:"tab-menu divide-x dark:divide-gray-700 border-l-gray-200 border-r-gray-200 border-t-gray-200 border-b-gray-200 dark:border-l-gray-700 dark:border-r-gray-700 dark:border-t-gray-700 dark:border-b-gray-700"},{default:(0,o.withCtx)((()=>[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(c(n.value),((e,t)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(a.oz),{as:"template",key:t,disabled:0==e.visibleFieldsForPanel.visibleFieldsCount.value},{default:(0,o.withCtx)((({selected:t,disabled:r})=>[(0,o.createElementVNode)("button",{class:(0,o.normalizeClass)([[t?"active text-primary-500 font-bold border-b-2 "+(e.hasErrors?"!border-b-red-500":"!border-b-primary-500"):0==e.visibleFieldsForPanel.visibleFieldsCount.value?"cursor-not-allowed text-gray-600/60 dark:text-gray-400/60":"text-gray-600 hover:text-gray-800 dark:text-gray-400 hover:dark:text-gray-200",e.hasErrors?"!text-red-500":""],"tab-item"]),dusk:`${e.attribute}-tab-trigger`,disabled:0==e.visibleFieldsForPanel.visibleFieldsCount.value},[(0,o.createElementVNode)("span",y,(0,o.toDisplayString)(e.meta.name),1)],10,g)])),_:2},1032,["disabled"])))),128))])),_:1},8,["aria-label"]),(0,o.createVNode)((0,o.unref)(a.T2),null,{default:(0,o.withCtx)((()=>[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(c(n.value),((i,l)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(a.Kp),{key:l,label:i.name,dusk:`${i.attribute}-tab-content`,class:(0,o.normalizeClass)([i.attribute,"tab fields-tab"]),unmount:!1},{default:(0,o.withCtx)((()=>[((0,o.openBlock)(),(0,o.createBlock)(o.KeepAlive,null,[(0,o.createElementVNode)("div",b,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(i.fields,((l,a)=>((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:a},[l.from?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(u(l)),{key:0,field:l,"form-unique-id":e.formUniqueId,errors:e.validationErrors,"resource-name":t.resourceName,"resource-id":t.resourceId,"related-resource-name":t.relatedResourceName,"related-resource-id":t.relatedResourceId,"shown-via-new-relation-modal":t.shownViaNewRelationModal,"via-resource":t.viaResource,"via-resource-id":t.viaResourceId,"via-relationship":t.viaRelationship,onFieldChanged:r[0]||(r[0]=e=>t.$emit("field-changed")),onFieldShown:i.visibleFieldsForPanel.handleFieldShown,onFieldHidden:i.visibleFieldsForPanel.handleFieldHidden,onFileDeleted:r[1]||(r[1]=e=>t.$emit("update-last-retrieved-at-timestamp")),onFileUploadStarted:r[2]||(r[2]=e=>t.$emit("file-upload-started")),onFileUploadFinished:r[3]||(r[3]=e=>t.$emit("file-upload-finished")),"show-help-text":null!=l.helpText,class:(0,o.normalizeClass)({"remove-bottom-border":a===i.fields.length-1})},null,40,["field","form-unique-id","errors","resource-name","resource-id","related-resource-name","related-resource-id","shown-via-new-relation-modal","via-resource","via-resource-id","via-relationship","onFieldShown","onFieldHidden","show-help-text","class"])),l.from?((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(u(l)),{key:1,field:l,"form-unique-id":t.relationFormUniqueId,errors:e.validationErrors,"resource-name":l.resourceName,"resource-id":h(l),"via-resource":l.from.viaResource,"via-resource-id":l.from.viaResourceId,"via-relationship":l.from.viaRelationship,onFieldChanged:r[4]||(r[4]=e=>t.$emit("field-changed")),onFieldShown:i.visibleFieldsForPanel.handleFieldShown,onFieldHidden:i.visibleFieldsForPanel.handleFieldHidden,onFileDeleted:r[5]||(r[5]=e=>t.$emit("update-last-retrieved-at-timestamp")),onFileUploadStarted:r[6]||(r[6]=e=>t.$emit("file-upload-started")),onFileUploadFinished:r[7]||(r[7]=e=>t.$emit("file-upload-finished")),"show-help-text":null!=l.helpText,class:(0,o.normalizeClass)({"remove-bottom-border":a===i.fields.length-1})},null,40,["field","form-unique-id","errors","resource-name","resource-id","via-resource","via-resource-id","via-relationship","onFieldShown","onFieldHidden","show-help-text","class"])):(0,o.createCommentVNode)("",!0)],64)))),128))])],1024))])),_:2},1032,["label","dusk","class"])))),128))])),_:1})])),_:1})],2)],8,f)}}};const w=(0,r(66262).A)(k,[["__file","TabsPanel.vue"]])},13868:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>w});var o=r(29726);const i={class:"space-y-4"},l={class:"flex items-center"},a=["dusk"];var n=r(74640),s=r(52191),c=r(25019),d=r(17039),u=r(76402),p=r(22308),h=r(35229),m=r(30043),f=r(56170),v=r.n(f);function g(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function y(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?g(Object(r),!0).forEach((function(t){b(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):g(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function b(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const k={components:{Button:n.Button,PreviewResourceModal:p.default,SearchInputResult:u.default,TagList:d.default},mixins:[h.Gj,h.Bz,h._w],props:y({},(0,h.rr)(["resourceId"])),data:()=>({relationModalOpen:!1,search:"",value:[],tags:[],loading:!1}),mounted(){this.currentField.preload&&this.getAvailableResources()},methods:{performSearch(e){this.search=e;const t=e.trim();this.searchDebouncer((()=>{this.getAvailableResources(t)}),500)},fill(e){this.fillIfVisible(e,this.currentField.attribute,this.value.length>0?JSON.stringify(this.value):"")},getAvailableResources(e=""){this.loading=!0;const t={search:e,current:null,first:!1,withTrashed:!1};return(0,m.minimum)(s.A.fetchAvailableResources(this.resourceName,this.resourceId,this.currentField.resourceName,{params:y(y({},t),{},{component:this.currentField.component,viaRelationship:this.currentField.attribute})}).then((({data:{resources:e}})=>{this.tags=e})).finally((()=>{this.loading=!1})),250)},handleSetResource({id:e}){const t={search:"",current:e,first:!0};c.A.fetchAvailableResources(this.currentField.resourceName,{params:t}).then((({data:{resources:e}})=>{this.$refs.searchable.choose(v()(e))})).finally((()=>{this.closeRelationModal()}))},removeResource(e){this.$refs.searchable.remove(e)},openRelationModal(){this.relationModalOpen=!0},closeRelationModal(){this.relationModalOpen=!1}}};const w=(0,r(66262).A)(k,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("SearchInputResult"),u=(0,o.resolveComponent)("ComboBoxInput"),p=(0,o.resolveComponent)("Button"),h=(0,o.resolveComponent)("TagList"),m=(0,o.resolveComponent)("TagGroup"),f=(0,o.resolveComponent)("CreateRelationModal"),v=(0,o.resolveComponent)("DefaultField"),g=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createBlock)(v,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("div",l,[(0,o.createVNode)(u,{ref:"searchable",modelValue:e.value,"onUpdate:modelValue":t[0]||(t[0]=t=>e.value=t),onInput:c.performSearch,error:e.hasError,debounce:e.field.debounce,options:e.tags,placeholder:"Search",autocomplete:e.currentField.autocomplete,trackBy:"value",disabled:e.currentlyIsReadonly,loading:e.loading,class:"w-full",dusk:`${e.field.resourceName}-search-input`},{option:(0,o.withCtx)((({dusk:t,selected:r,option:i})=>[(0,o.createVNode)(d,{option:i,selected:r,"with-subtitles":e.field.withSubtitles,dusk:t},null,8,["option","selected","with-subtitles","dusk"])])),_:1},8,["modelValue","onInput","error","debounce","options","autocomplete","disabled","loading","dusk"]),e.field.showCreateRelationButton?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(p,{key:0,variant:"link",size:"small","leading-icon":"plus-circle",onClick:c.openRelationModal,dusk:`${e.field.attribute}-inline-create`,tabindex:"0"},null,8,["onClick","dusk"])),[[g,e.__("Create :resource",{resource:e.field.singularLabel})]]):(0,o.createCommentVNode)("",!0)]),e.value.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,dusk:`${e.field.attribute}-selected-tags`},["list"===e.field.style?((0,o.openBlock)(),(0,o.createBlock)(h,{key:0,tags:e.value,onTagRemoved:t[1]||(t[1]=e=>c.removeResource(e)),"resource-name":e.field.resourceName,editable:!e.currentlyIsReadonly,"with-preview":e.field.withPreview},null,8,["tags","resource-name","editable","with-preview"])):(0,o.createCommentVNode)("",!0),"group"===e.field.style?((0,o.openBlock)(),(0,o.createBlock)(m,{key:1,tags:e.value,onTagRemoved:t[2]||(t[2]=e=>c.removeResource(e)),"resource-name":e.field.resourceName,editable:!e.currentlyIsReadonly,"with-preview":e.field.withPreview},null,8,["tags","resource-name","editable","with-preview"])):(0,o.createCommentVNode)("",!0)],8,a)):(0,o.createCommentVNode)("",!0)]),(0,o.createVNode)(f,{"resource-name":e.field.resourceName,show:e.field.showCreateRelationButton&&e.relationModalOpen,size:e.field.modalSize,onSetResource:c.handleSetResource,onCreateCancelled:t[3]||(t[3]=t=>e.relationModalOpen=!1)},null,8,["resource-name","show","size","onSetResource"])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","TagField.vue"]])},35841:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>h});var o=r(29726);const i={class:"space-y-1"},l=["value","id","dusk","disabled","autocomplete","maxlength"],a=["id"],n=["value"];var s=r(35229);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function d(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function u(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const p={mixins:[s.Gj,s.IR,s._w],computed:{defaultAttributes(){return d({type:this.currentField.type||"text",class:this.errorClasses,min:this.currentField.min,max:this.currentField.max,step:this.currentField.step,pattern:this.currentField.pattern,placeholder:this.placeholder},this.suggestionsAttributes)},extraAttributes(){return d(d({},this.defaultAttributes),this.currentField.extraAttributes)}}};const h=(0,r(66262).A)(p,[["render",function(e,t,r,s,c,d){const u=(0,o.resolveComponent)("CharacterCounter"),p=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(p,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("input",(0,o.mergeProps)(d.extraAttributes,{class:"w-full form-control form-input form-control-bordered",onInput:t[0]||(t[0]=(...t)=>e.handleChange&&e.handleChange(...t)),value:e.value,id:e.currentField.uniqueKey,dusk:e.field.attribute,disabled:e.currentlyIsReadonly,autocomplete:e.currentField.autocomplete,maxlength:e.field.enforceMaxlength?e.field.maxlength:-1}),null,16,l),e.suggestions.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("datalist",{key:0,id:e.suggestionsId},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.suggestions,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("option",{key:e,value:e},null,8,n)))),128))],8,a)):(0,o.createCommentVNode)("",!0),e.field.maxlength?((0,o.openBlock)(),(0,o.createBlock)(u,{key:1,count:e.value.length,limit:e.field.maxlength},null,8,["count","limit"])):(0,o.createCommentVNode)("",!0)])])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","TextField.vue"]])},75649:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var o=r(29726);const i={class:"space-y-1"},l=["id","value","maxlength","dusk"];var a=r(35229);function n(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function s(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?n(Object(r),!0).forEach((function(t){c(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):n(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function c(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const d={mixins:[a._w,a.Gj],computed:{defaultAttributes(){return{rows:this.currentField.rows,class:this.errorClasses,placeholder:this.placeholder}},extraAttributes(){return s(s({},this.defaultAttributes),this.currentField.extraAttributes)}}};const u=(0,r(66262).A)(d,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("CharacterCounter"),d=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(d,{field:e.currentField,errors:e.errors,"full-width-content":e.fullWidthContent,"show-help-text":e.showHelpText},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,[(0,o.createElementVNode)("textarea",(0,o.mergeProps)(s.extraAttributes,{id:e.currentField.uniqueKey,value:e.value,maxlength:e.field.enforceMaxlength?e.field.maxlength:-1,onInput:t[0]||(t[0]=(...t)=>e.handleChange&&e.handleChange(...t)),class:"w-full h-auto py-3 block form-control form-input form-control-bordered",dusk:e.field.attribute}),null,16,l),e.field.maxlength?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,count:e.value.length,limit:e.field.maxlength},null,8,["count","limit"])):(0,o.createCommentVNode)("",!0)])])),_:1},8,["field","errors","full-width-content","show-help-text"])}],["__file","TextareaField.vue"]])},98385:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);var i=r(35229);function l(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function a(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const n={emits:["field-changed"],mixins:[i._w,i.Qy,i.Gj],data:()=>({trixIndex:0}),mounted(){Nova.$on(this.fieldAttributeValueEventName,this.listenToValueChanges)},beforeUnmount(){Nova.$off(this.fieldAttributeValueEventName,this.listenToValueChanges),this.clearAttachments(),this.clearFilesMarkedForRemoval()},methods:{handleChange(e){this.value=e,this.$emit("field-changed")},fill(e){this.fillIfVisible(e,this.fieldAttribute,this.value||""),this.fillAttachmentDraftId(e)},handleFileAdded({attachment:e}){if(e.file){const t=(t,r)=>e.setAttributes({url:r,href:r}),r=t=>{e.setUploadProgress(Math.round(100*t.loaded/t.total))};this.uploadAttachment(e.file,{onCompleted:t,onUploadProgress:r})}else this.unflagFileForRemoval(e.attachment.attributes.values.url)},handleFileRemoved({attachment:{attachment:e}}){this.flagFileForRemoval(e.attributes.values.url)},onSyncedField(){this.handleChange(this.currentField.value??this.value),this.trixIndex++},listenToValueChanges(e){this.trixIndex++}},computed:{extraAttributes(){return function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?l(Object(r),!0).forEach((function(t){a(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):l(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({placeholder:this.placeholder},this.currentField.extraAttributes)}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("Trix"),s=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(s,{field:e.currentField,errors:e.errors,"full-width-content":e.fullWidthContent,key:e.trixIndex,"show-help-text":e.showHelpText},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(["rounded-lg",{disabled:e.currentlyIsReadonly}])},[(0,o.createVNode)(n,(0,o.mergeProps)(a.extraAttributes,{name:"trixman",value:e.value,"with-files":e.currentField.withFiles,disabled:e.currentlyIsReadonly,onChange:a.handleChange,onFileAdded:a.handleFileAdded,onFileRemoved:a.handleFileRemoved,class:["rounded-lg",{"form-control-bordered-error":e.hasError}]}),null,16,["value","with-files","disabled","onChange","onFileAdded","onFileRemoved","class"])],2)])),_:1},8,["field","errors","full-width-content","show-help-text"])}],["__file","TrixField.vue"]])},54185:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>p});var o=r(29726);const i=["id","value","disabled","list","autocomplete","dusk"],l=["id"],a=["value"];var n=r(35229);function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function c(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?s(Object(r),!0).forEach((function(t){d(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function d(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const u={mixins:[n._w,n.Gj],computed:{defaultAttributes(){return{type:this.currentField.type||"text",min:this.currentField.min,max:this.currentField.max,step:this.currentField.step,pattern:this.currentField.pattern,placeholder:this.placeholder,class:this.errorClasses}},extraAttributes(){return c(c({},this.defaultAttributes),this.currentField.extraAttributes)}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("DefaultField");return(0,o.openBlock)(),(0,o.createBlock)(d,{field:e.currentField,errors:e.errors,"show-help-text":e.showHelpText,"full-width-content":e.fullWidthContent},{field:(0,o.withCtx)((()=>[(0,o.createElementVNode)("input",(0,o.mergeProps)(c.extraAttributes,{id:e.currentField.uniqueKey,type:"url",value:e.value,onInput:t[0]||(t[0]=(...t)=>e.handleChange&&e.handleChange(...t)),disabled:e.currentlyIsReadonly,list:`${e.field.attribute}-list`,class:"w-full form-control form-input form-control-bordered",autocomplete:e.currentField.autocomplete,dusk:e.field.attribute}),null,16,i),e.currentField.suggestions&&e.currentField.suggestions.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("datalist",{key:0,id:`${e.field.attribute}-list`},[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.currentField.suggestions,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("option",{key:e,value:e},null,8,a)))),128))],8,l)):(0,o.createCommentVNode)("",!0)])),_:1},8,["field","errors","show-help-text","full-width-content"])}],["__file","UrlField.vue"]])},16192:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>i});const o={extends:r(22988).default,computed:{isVaporField:()=>!0}};const i=(0,r(66262).A)(o,[["__file","VaporAudioField.vue"]])},50531:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>i});const o={extends:r(22988).default,computed:{isVaporField:()=>!0}};const i=(0,r(66262).A)(o,[["__file","VaporFileField.vue"]])},43032:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i=["src"];const l={mixins:[r(35229).S0],props:["viaResource","viaResourceId","resourceName","field"],computed:{hasPreviewableAudio(){return null!=this.field.previewUrl},defaultAttributes(){return{autoplay:!1,preload:this.field.preload}},alignmentClass(){return{left:"items-center justify-start",center:"items-center justify-center",right:"items-center justify-end"}[this.field.textAlign]}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)([n.alignmentClass,"flex"])},[n.hasPreviewableAudio?((0,o.openBlock)(),(0,o.createElementBlock)("audio",(0,o.mergeProps)({key:0},n.defaultAttributes,{class:"rounded rounded-full",src:r.field.previewUrl,controls:"",controlslist:"nodownload"}),null,16,i)):((0,o.openBlock)(),(0,o.createElementBlock)("p",{key:1,class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},"—",2))],2)}],["__file","AudioField.vue"]])},51086:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={key:0,class:"mr-1 -ml-1"};const l={components:{Icon:r(74640).Icon},props:["resourceName","viaResource","viaResourceId","field"]};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("Icon"),c=(0,o.resolveComponent)("Badge");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.createVNode)(c,{label:r.field.label,"extra-classes":r.field.typeClass},{icon:(0,o.withCtx)((()=>[r.field.icon?((0,o.openBlock)(),(0,o.createElementBlock)("span",i,[(0,o.createVNode)(s,{name:r.field.icon,type:"solid",class:"inline-block"},null,8,["name"])])):(0,o.createCommentVNode)("",!0)])),_:1},8,["label","extra-classes"])])}],["__file","BadgeField.vue"]])},99723:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={key:0},l={key:1},a={key:2},n={__name:"BelongsToField",props:{resource:{type:Object},resourceName:{type:String},field:{type:Object}},setup:e=>(t,r)=>{const n=(0,o.resolveComponent)("Link"),s=(0,o.resolveComponent)("RelationPeek");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${e.field.textAlign}`)},[(0,o.createElementVNode)("span",null,[e.field.viewable&&e.field.value?((0,o.openBlock)(),(0,o.createElementBlock)("span",i,[e.field.peekable&&e.field.hasFieldsToPeekAt?((0,o.openBlock)(),(0,o.createBlock)(s,{key:0,"resource-name":e.field.resourceName,"resource-id":e.field.belongsToId,resource:e.resource},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(n,{onClick:r[0]||(r[0]=(0,o.withModifiers)((()=>{}),["stop"])),href:t.$url(`/resources/${e.field.resourceName}/${e.field.belongsToId}`),class:"link-default"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.field.value),1)])),_:1},8,["href"])])),_:1},8,["resource-name","resource-id","resource"])):((0,o.openBlock)(),(0,o.createBlock)(n,{key:1,onClick:r[1]||(r[1]=(0,o.withModifiers)((()=>{}),["stop"])),href:t.$url(`/resources/${e.field.resourceName}/${e.field.belongsToId}`),class:"link-default"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.field.value),1)])),_:1},8,["href"]))])):e.field.value?((0,o.openBlock)(),(0,o.createElementBlock)("span",l,(0,o.toDisplayString)(e.field.value),1)):((0,o.openBlock)(),(0,o.createElementBlock)("span",a,"—"))])],2)}};const s=(0,r(66262).A)(n,[["__file","BelongsToField.vue"]])},95915:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["resourceName","field"]};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("IconBoolean");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[(0,o.createVNode)(n,{value:r.field.value,nullable:r.field.nullable,class:"inline-block"},null,8,["value","nullable"])],2)}],["__file","BooleanField.vue"]])},55371:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={key:0,class:"max-w-xxs space-y-2 py-3 px-4"},l={class:"ml-1"},a={key:1,class:"max-w-xxs space-2 py-3 px-4 rounded-full text-sm leading-tight"};const n={components:{Button:r(74640).Button},props:["resourceName","field"],data:()=>({value:[],classes:{true:"text-green-500",false:"text-red-500"}}),created(){this.field.value=this.field.value||{},this.value=this.field.options.filter((e=>(!0!==this.field.hideFalseValues||!1!==e.checked)&&(!0!==this.field.hideTrueValues||!0!==e.checked))).map((e=>({name:e.name,label:e.label,checked:this.field.value[e.name]||!1})))}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("Button"),u=(0,o.resolveComponent)("IconBoolean"),p=(0,o.resolveComponent)("DropdownMenu"),h=(0,o.resolveComponent)("Dropdown");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[(0,o.createVNode)(h,null,{menu:(0,o.withCtx)((()=>[(0,o.createVNode)(p,{width:"auto"},{default:(0,o.withCtx)((()=>[e.value.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("ul",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.value,((t,r)=>((0,o.openBlock)(),(0,o.createElementBlock)("li",{key:r,class:(0,o.normalizeClass)(["flex items-center rounded-full font-bold text-sm leading-tight space-x-2",e.classes[t.checked]])},[(0,o.createVNode)(u,{class:"flex-none",value:t.checked},null,8,["value"]),(0,o.createElementVNode)("span",l,(0,o.toDisplayString)(t.label),1)],2)))),128))])):((0,o.openBlock)(),(0,o.createElementBlock)("span",a,(0,o.toDisplayString)(r.field.noValueText),1))])),_:1})])),default:(0,o.withCtx)((()=>[(0,o.createVNode)(d,{variant:"link"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("View")),1)])),_:1})])),_:1})],2)}],["__file","BooleanGroupField.vue"]])},84706:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"rounded inline-flex items-center justify-center border border-60",style:{borderRadius:"4px",padding:"2px"}};const l={props:["resourceName","field"]};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[(0,o.createElementVNode)("span",i,[(0,o.createElementVNode)("span",{class:"block w-4 h-4",style:(0,o.normalizeStyle)({borderRadius:"2px",backgroundColor:r.field.value})},null,4)])],2)}],["__file","ColorField.vue"]])},41129:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i=["innerHTML"],l={key:1},a={key:1};const n={mixins:[r(35229).S0],props:["resourceName","field"]};const s=(0,r(66262).A)(n,[["render",function(e,t,r,n,s,c){return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[e.fieldValue?((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:0},[e.shouldDisplayAsHtml?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,onClick:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),innerHTML:e.fieldValue},null,8,i)):((0,o.openBlock)(),(0,o.createElementBlock)("span",l,(0,o.toDisplayString)(e.fieldValue),1))],64)):((0,o.openBlock)(),(0,o.createElementBlock)("p",a,"—"))])}],["__file","CurrencyField.vue"]])},81871:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={key:0,class:"whitespace-nowrap"},l={key:1};var a=r(91272);const n={mixins:[r(35229).S0],props:["resourceName","field"],computed:{formattedDate(){if(this.field.usesCustomizedDisplay)return this.field.displayedAs;return a.c9.fromISO(this.field.value).toLocaleString({year:"numeric",month:"2-digit",day:"2-digit"})}}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,a,n,s){return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.createElementVNode)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[e.fieldHasValue?((0,o.openBlock)(),(0,o.createElementBlock)("span",i,(0,o.toDisplayString)(s.formattedDate),1)):((0,o.openBlock)(),(0,o.createElementBlock)("span",l,"—"))],2)])}],["__file","DateField.vue"]])},9952:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i=["title"],l={key:1};var a=r(91272);const n={mixins:[r(35229).S0],props:["resourceName","field"],computed:{formattedDate(){return this.usesCustomizedDisplay?this.field.displayedAs:a.c9.fromISO(this.field.value).setZone(this.timezone).toLocaleString({year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",timeZoneName:"short"})},timezone:()=>Nova.config("userTimezone")||Nova.config("timezone")}};const s=(0,r(66262).A)(n,[["render",function(e,t,r,a,n,s){return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[e.fieldHasValue||e.usesCustomizedDisplay?((0,o.openBlock)(),(0,o.createElementBlock)("span",{key:0,class:"whitespace-nowrap",title:r.field.value},(0,o.toDisplayString)(s.formattedDate),9,i)):((0,o.openBlock)(),(0,o.createElementBlock)("span",l,"—"))],2)}],["__file","DateTimeField.vue"]])},13785:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={key:0,class:"flex items-center"},l=["href"],a={key:1};var n=r(35229);const s={mixins:[n.nl,n.S0],props:["resourceName","field"],methods:{copy(){this.copyValueToClipboard(this.field.value)}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("CopyButton"),u=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[e.fieldHasValue?((0,o.openBlock)(),(0,o.createElementBlock)("p",i,[e.fieldHasValue?((0,o.openBlock)(),(0,o.createElementBlock)("a",{key:0,onClick:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),href:`mailto:${r.field.value}`,class:"link-default whitespace-nowrap"},(0,o.toDisplayString)(e.fieldValue),9,l)):(0,o.createCommentVNode)("",!0),e.fieldHasValue&&r.field.copyable&&!e.shouldDisplayAsHtml?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(d,{key:1,onClick:(0,o.withModifiers)(c.copy,["prevent","stop"]),class:"mx-0"},null,8,["onClick"])),[[u,e.__("Copy to clipboard")]]):(0,o.createCommentVNode)("",!0)])):((0,o.openBlock)(),(0,o.createElementBlock)("p",a,"—"))],2)}],["__file","EmailField.vue"]])},48242:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={key:1,class:"break-words"};const l={mixins:[r(35229).S0],props:["viaResource","viaResourceId","resourceName","field"],data:()=>({loading:!1}),computed:{shouldShowLoader(){return this.imageUrl},imageUrl(){return this.field?.thumbnailUrl||this.field?.previewUrl},alignmentClass(){return{left:"items-center justify-start",center:"items-center justify-center",right:"items-center justify-end"}[this.field.textAlign]}}};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){const s=(0,o.resolveComponent)("ImageLoader"),c=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)([n.alignmentClass,"flex"])},[n.shouldShowLoader?((0,o.openBlock)(),(0,o.createBlock)(s,{key:0,src:n.imageUrl,"max-width":r.field.maxWidth||r.field.indexWidth,rounded:r.field.rounded,aspect:r.field.aspect},null,8,["src","max-width","rounded","aspect"])):(0,o.createCommentVNode)("",!0),e.usesCustomizedDisplay&&!n.imageUrl?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createElementBlock)("span",i,[(0,o.createTextVNode)((0,o.toDisplayString)(r.field.displayedAs),1)])),[[c,r.field.value]]):(0,o.createCommentVNode)("",!0),e.usesCustomizedDisplay||n.imageUrl?(0,o.createCommentVNode)("",!0):(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createElementBlock)("p",{key:2,class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},t[0]||(t[0]=[(0,o.createTextVNode)(" — ")]),2)),[[c,r.field.value]])],2)}],["__file","FileField.vue"]])},81173:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["field","viaResource","viaResourceId","resourceName"]};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){return(0,o.openBlock)(),(0,o.createElementBlock)("span")}],["__file","HeadingField.vue"]])},76439:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var o=r(29726);const i={class:"hidden"};const l={props:["resourceName","field"]};const a=(0,r(66262).A)(l,[["render",function(e,t,r,l,a,n){return(0,o.openBlock)(),(0,o.createElementBlock)("div",i)}],["__file","HiddenField.vue"]])},21451:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i={key:1},l={key:2};const a={mixins:[r(35229).S0],props:["resource","resourceName","field"],computed:{isPivot(){return null!=this.field.pivotValue},authorizedToView(){return this.resource?.authorizedToView??!1}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Link");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[e.fieldHasValue&&!s.isPivot&&s.authorizedToView?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,onClick:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),href:e.$url(`/resources/${r.resourceName}/${r.field.value}`),class:"link-default"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.fieldValue),1)])),_:1},8,["href"])):e.fieldHasValue||s.isPivot?((0,o.openBlock)(),(0,o.createElementBlock)("p",i,(0,o.toDisplayString)(r.field.pivotValue||e.fieldValue),1)):((0,o.openBlock)(),(0,o.createElementBlock)("p",l,"—"))],2)}],["__file","IdField.vue"]])},24549:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i=["innerHTML"],l={key:1};const a={mixins:[r(35229).S0],props:["resourceName","field"]};const n=(0,r(66262).A)(a,[["render",function(e,t,r,a,n,s){return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[e.fieldValue?((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:0},[e.shouldDisplayAsHtml?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,onClick:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),innerHTML:e.fieldValue},null,8,i)):((0,o.openBlock)(),(0,o.createElementBlock)("span",{key:1,class:(0,o.normalizeClass)(["whitespace-nowrap",r.field.classes])},(0,o.toDisplayString)(e.fieldValue),3))],64)):((0,o.openBlock)(),(0,o.createElementBlock)("p",l,"—"))],2)}],["__file","LineField.vue"]])},25736:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i={key:1},l={key:2};const a={props:["resourceName","viaResource","viaResourceId","field"],computed:{isResourceBeingViewed(){return this.field.morphToType==this.viaResource&&this.field.morphToId==this.viaResourceId}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Link");return r.field.viewable&&r.field.value&&!s.isResourceBeingViewed?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,onClick:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),href:e.$url(`/resources/${r.field.resourceName}/${r.field.morphToId}`),class:(0,o.normalizeClass)(["no-underline text-primary-500 font-bold",`text-${r.field.textAlign}`])},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.field.resourceLabel)+": "+(0,o.toDisplayString)(r.field.value),1)])),_:1},8,["href","class"])):r.field.value?((0,o.openBlock)(),(0,o.createElementBlock)("span",i,(0,o.toDisplayString)(r.field.resourceLabel||r.field.morphToType)+": "+(0,o.toDisplayString)(r.field.value),1)):((0,o.openBlock)(),(0,o.createElementBlock)("span",l,"—"))}],["__file","MorphToActionTargetField.vue"]])},59219:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i={key:0},l={key:1},a={key:2},n={__name:"MorphToField",props:{resource:{type:Object},resourceName:{type:String},field:{type:Object}},setup:e=>(t,r)=>{const n=(0,o.resolveComponent)("Link"),s=(0,o.resolveComponent)("RelationPeek");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${e.field.textAlign}`)},[(0,o.createElementVNode)("span",null,[e.field.viewable&&e.field.value?((0,o.openBlock)(),(0,o.createElementBlock)("span",i,[e.field.peekable&&e.field.hasFieldsToPeekAt?((0,o.openBlock)(),(0,o.createBlock)(s,{key:0,"resource-name":e.field.resourceName,"resource-id":e.field.morphToId,resource:e.resource},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(n,{onClick:r[0]||(r[0]=(0,o.withModifiers)((()=>{}),["stop"])),href:t.$url(`/resources/${e.field.resourceName}/${e.field.morphToId}`),class:"link-default"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.field.resourceLabel)+": "+(0,o.toDisplayString)(e.field.value),1)])),_:1},8,["href"])])),_:1},8,["resource-name","resource-id","resource"])):((0,o.openBlock)(),(0,o.createBlock)(n,{key:1,onClick:r[1]||(r[1]=(0,o.withModifiers)((()=>{}),["stop"])),href:t.$url(`/resources/${e.field.resourceName}/${e.field.morphToId}`),class:"link-default"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.field.resourceLabel)+": "+(0,o.toDisplayString)(e.field.value),1)])),_:1},8,["href"]))])):e.field.value?((0,o.openBlock)(),(0,o.createElementBlock)("span",l,(0,o.toDisplayString)(e.field.resourceLabel||e.field.morphToType)+": "+(0,o.toDisplayString)(e.field.value),1)):((0,o.openBlock)(),(0,o.createElementBlock)("span",a,"—"))])],2)}};const s=(0,r(66262).A)(n,[["__file","MorphToField.vue"]])},8947:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i=["textContent"],l={key:1};const a={mixins:[r(35229).S0],props:["resourceName","field"],computed:{hasValues(){return this.fieldValues.length>0},fieldValues(){let e=[];return this.field.options.forEach((t=>{this.isEqualsToValue(t.value)&&e.push(t.label)})),e}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,a,n,s){return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[s.hasValues?((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,{key:0},(0,o.renderList)(s.fieldValues,(e=>((0,o.openBlock)(),(0,o.createElementBlock)("span",{textContent:(0,o.toDisplayString)(e),class:"inline-block text-sm mb-1 mr-2 px-2 py-0 bg-primary-500 text-white dark:text-gray-900 rounded"},null,8,i)))),256)):((0,o.openBlock)(),(0,o.createElementBlock)("p",l,"—"))])}],["__file","MultiSelectField.vue"]])},46750:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>l});var o=r(29726);const i={props:["resourceName","field"]};const l=(0,r(66262).A)(i,[["render",function(e,t,r,i,l,a){return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},t[0]||(t[0]=[(0,o.createElementVNode)("span",{class:"font-bold"}," · · · · · · · · ",-1)]),2)}],["__file","PasswordField.vue"]])},61775:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>s});var o=r(29726);const i=["innerHTML"],l={key:1,class:"whitespace-nowrap"},a={key:1};const n={mixins:[r(35229).S0],props:["resourceName","field"]};const s=(0,r(66262).A)(n,[["render",function(e,t,r,n,s,c){return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[e.fieldValue?((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:0},[e.shouldDisplayAsHtml?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,onClick:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),innerHTML:e.fieldValue},null,8,i)):((0,o.openBlock)(),(0,o.createElementBlock)("span",l,(0,o.toDisplayString)(e.fieldValue),1))],64)):((0,o.openBlock)(),(0,o.createElementBlock)("p",a,"—"))],2)}],["__file","SelectField.vue"]])},42212:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>i});const o={extends:r(89250).default};const i=(0,r(66262).A)(o,[["__file","SlugField.vue"]])},46086:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i={key:0};var l=r(27717);r(27554);const a={props:["resourceName","field"],data:()=>({chartist:null}),watch:{"field.data":function(e,t){this.renderChart()}},methods:{renderChart(){this.chartist.update(this.field.data)}},mounted(){const e=this.chartStyle;this.chartist=new e(this.$refs.chart,{series:[this.field.data]},{height:this.chartHeight,width:this.chartWidth,showPoint:!1,fullWidth:!0,chartPadding:{top:0,right:0,bottom:0,left:0},axisX:{showGrid:!1,showLabel:!1,offset:0},axisY:{showGrid:!1,showLabel:!1,offset:0}})},computed:{hasData(){return this.field.data.length>0},chartStyle(){let e=this.field.chartStyle.toLowerCase();return["line","bar"].includes(e)&&"line"!==e?l.Es:l.bl},chartHeight(){return this.field.height||50},chartWidth(){return this.field.width||100}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,l,a,n){return n.hasData?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("div",{ref:"chart",class:"ct-chart",style:(0,o.normalizeStyle)({width:n.chartWidth,height:n.chartHeight})},null,4)])):(0,o.createCommentVNode)("",!0)}],["__file","SparklineField.vue"]])},95328:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i={key:0,class:"leading-normal"},l={key:1};const a={props:["resourceName","field"],computed:{hasValue(){return this.field.lines}}};const n=(0,r(66262).A)(a,[["render",function(e,t,r,a,n,s){return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[s.hasValue?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(r.field.lines,(e=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)(`index-${e.component}`),{key:e.value,class:"whitespace-nowrap",field:e,resourceName:r.resourceName},null,8,["field","resourceName"])))),128))])):((0,o.openBlock)(),(0,o.createElementBlock)("p",l,"—"))],2)}],["__file","StackField.vue"]])},7187:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i={class:"flex items-center"},l={class:"mr-1 -ml-1"};var a=r(74640),n=r(35229);const s={components:{Icon:a.Icon},mixins:[n.S0],props:["resourceName","field"],computed:{typeClasses(){return["center"===this.field.textAlign&&"mx-auto","right"===this.field.textAlign&&"ml-auto mr-0","left"===this.field.textAlign&&"ml-0 mr-auto",this.field.typeClass]}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Loader"),d=(0,o.resolveComponent)("Icon"),u=(0,o.resolveComponent)("Badge");return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createVNode)(u,{class:(0,o.normalizeClass)(["whitespace-nowrap flex items-center",s.typeClasses])},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",l,["loading"==r.field.type?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,width:"20",class:"mr-1"})):(0,o.createCommentVNode)("",!0),"failed"==r.field.type?((0,o.openBlock)(),(0,o.createBlock)(d,{key:1,name:"exclamation-circle",type:"solid"})):(0,o.createCommentVNode)("",!0),"success"==r.field.type?((0,o.openBlock)(),(0,o.createBlock)(d,{key:2,name:"check-circle",type:"solid"})):(0,o.createCommentVNode)("",!0)]),(0,o.createTextVNode)(" "+(0,o.toDisplayString)(e.fieldValue),1)])),_:1},8,["class"])])}],["__file","StatusField.vue"]])},25565:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});var o=r(29726);const i={class:"p-2"},l={key:1};const a={components:{Button:r(74640).Button},props:["index","resource","resourceName","resourceId","field"]};const n=(0,r(66262).A)(a,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Button"),d=(0,o.resolveComponent)("TagList"),u=(0,o.resolveComponent)("TagGroup"),p=(0,o.resolveComponent)("DropdownMenu"),h=(0,o.resolveComponent)("Dropdown");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[r.field.value.length>0?((0,o.openBlock)(),(0,o.createBlock)(h,{key:0},{menu:(0,o.withCtx)((()=>[(0,o.createVNode)(p,{width:"auto"},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("div",i,["list"===r.field.style?((0,o.openBlock)(),(0,o.createBlock)(d,{key:0,tags:r.field.value,"resource-name":r.field.resourceName,editable:!1,"with-preview":r.field.withPreview},null,8,["tags","resource-name","with-preview"])):(0,o.createCommentVNode)("",!0),"group"===r.field.style?((0,o.openBlock)(),(0,o.createBlock)(u,{key:1,tags:r.field.value,"resource-name":r.field.resourceName,editable:!1,"with-preview":r.field.withPreview},null,8,["tags","resource-name","with-preview"])):(0,o.createCommentVNode)("",!0)])])),_:1})])),default:(0,o.withCtx)((()=>[(0,o.createVNode)(c,{variant:"link"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("View")),1)])),_:1})])),_:1})):((0,o.openBlock)(),(0,o.createElementBlock)("p",l,"—"))],2)}],["__file","TagField.vue"]])},89250:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>d});var o=r(29726);const i={key:1,class:"whitespace-nowrap"},l=["innerHTML"],a={key:3},n={key:1};var s=r(35229);const c={mixins:[s.nl,s.S0],props:["resourceName","field"],methods:{copy(){this.copyValueToClipboard(this.field.value)}}};const d=(0,r(66262).A)(c,[["render",function(e,t,r,s,c,d){const u=(0,o.resolveComponent)("CopyButton"),p=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[e.fieldValue?((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:0},[e.fieldHasValueOrCustomizedDisplay&&r.field.copyable&&!e.shouldDisplayAsHtml?(0,o.withDirectives)(((0,o.openBlock)(),(0,o.createBlock)(u,{key:0,onClick:(0,o.withModifiers)(d.copy,["prevent","stop"])},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",{ref:"theFieldValue"},(0,o.toDisplayString)(e.fieldValue),513)])),_:1},8,["onClick"])),[[p,e.__("Copy to clipboard")]]):!e.fieldHasValueOrCustomizedDisplay||r.field.copyable||e.shouldDisplayAsHtml?e.fieldHasValueOrCustomizedDisplay&&!r.field.copyable&&e.shouldDisplayAsHtml?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:2,onClick:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),innerHTML:e.fieldValue},null,8,l)):((0,o.openBlock)(),(0,o.createElementBlock)("p",a,"—")):((0,o.openBlock)(),(0,o.createElementBlock)("span",i,(0,o.toDisplayString)(e.fieldValue),1))],64)):((0,o.openBlock)(),(0,o.createElementBlock)("p",n,"—"))],2)}],["__file","TextField.vue"]])},51466:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>c});var o=r(29726);const i=["innerHTML"],l={key:1,class:"whitespace-nowrap"},a=["href"],n={key:1};const s={mixins:[r(35229).S0],props:["resourceName","field"]};const c=(0,r(66262).A)(s,[["render",function(e,t,r,s,c,d){return(0,o.openBlock)(),(0,o.createElementBlock)("div",{class:(0,o.normalizeClass)(`text-${r.field.textAlign}`)},[e.fieldHasValue?((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:0},[e.shouldDisplayAsHtml?((0,o.openBlock)(),(0,o.createElementBlock)("div",{key:0,onClick:t[0]||(t[0]=(0,o.withModifiers)((()=>{}),["stop"])),innerHTML:e.fieldValue},null,8,i)):((0,o.openBlock)(),(0,o.createElementBlock)("span",l,[(0,o.createElementVNode)("a",{class:"link-default",href:r.field.value,rel:"noreferrer noopener",target:"_blank",onClick:t[1]||(t[1]=(0,o.withModifiers)((()=>{}),["stop"]))},(0,o.toDisplayString)(e.fieldValue),9,a)]))],64)):((0,o.openBlock)(),(0,o.createElementBlock)("p",n,"—"))],2)}],["__file","UrlField.vue"]])},35656:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>i});const o={extends:r(43032).default};const i=(0,r(66262).A)(o,[["__file","VaporAudioField.vue"]])},22104:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>i});const o={extends:r(48242).default};const i=(0,r(66262).A)(o,[["__file","VaporFileField.vue"]])},64087:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>i});const o={extends:r(7746).default,data:()=>({showActionDropdown:!1})};const i=(0,r(66262).A)(o,[["__file","HasOneField.vue"]])},3526:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});var o=r(29726);const i={class:"py-6 px-1 md:px-2 lg:px-6"},l={class:"mx-auto py-8 max-w-sm flex justify-center"},a=Object.assign({name:"Auth"},{__name:"Auth",setup:e=>(e,t)=>{const r=(0,o.resolveComponent)("AppLogo");return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createElementVNode)("div",l,[(0,o.createVNode)(r,{class:"h-8"})]),(0,o.renderSlot)(e.$slots,"default")])}});const n=(0,r(66262).A)(a,[["__file","Auth.vue"]])},28162:(e,t,r)=>{"use strict";r.d(t,{A:()=>l});var o=r(29726);const i=Object.assign({name:"Guest"},{__name:"Guest",setup:e=>(e,t)=>((0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.renderSlot)(e.$slots,"default")]))});const l=(0,r(66262).A)(i,[["__file","Guest.vue"]])},36653:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});var o=r(29726),i=r(28162);const l=Object.assign({name:"AppErrorPage",layout:i.A},{__name:"AppError",setup:e=>(e,t)=>{const r=(0,o.resolveComponent)("CustomAppError");return(0,o.openBlock)(),(0,o.createBlock)(r)}});const a=(0,r(66262).A)(l,[["__file","AppError.vue"]])},35694:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});var o=r(29726);var i=r(25542);const l={name:"Attach",props:{resourceName:{type:String,required:!0},resourceId:{required:!0},relatedResourceName:{type:String,required:!0},viaResource:{default:""},viaResourceId:{default:""},parentResource:{type:Object},viaRelationship:{default:""},polymorphic:{default:!1}},data:()=>({formUniqueId:(0,i.L)()})};const a=(0,r(66262).A)(l,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("AttachResource");return(0,o.openBlock)(),(0,o.createBlock)(n,{"resource-name":r.resourceName,"resource-id":r.resourceId,"related-resource-name":r.relatedResourceName,"via-resource":r.viaResource,"via-resource-id":r.viaResourceId,"parent-resource":r.parentResource,"via-relationship":r.viaRelationship,polymorphic:r.polymorphic,"form-unique-id":e.formUniqueId},null,8,["resource-name","resource-id","related-resource-name","via-resource","via-resource-id","parent-resource","via-relationship","polymorphic","form-unique-id"])}],["__file","Attach.vue"]])},32987:(e,t,r)=>{"use strict";r.d(t,{A:()=>p});var o=r(29726);const i={class:"text-2xl text-center font-normal mb-6"},l={class:"mb-6"},a={class:"block mb-2"},n={class:"mb-6"},s=["placeholder"];var c=r(3526),d=r(74640);const u={layout:c.A,components:{Button:d.Button},data:()=>({form:Nova.form({password:""}),completed:!1}),methods:{async submit(){try{let{redirect:e}=await this.form.post(Nova.url("/user-security/confirm-password"));this.completed=!0;let t={url:Nova.url("/"),remote:!0};null!=e&&(t={url:e,remote:!0}),Nova.visit(t)}catch(e){500===e.response?.status&&Nova.error(this.__("There was a problem submitting the form."))}this.form.password="",this.$refs.passwordInput.focus()}}};const p=(0,r(66262).A)(u,[["render",function(e,t,r,c,d,u){const p=(0,o.resolveComponent)("Head"),h=(0,o.resolveComponent)("DividerLine"),m=(0,o.resolveComponent)("HelpText"),f=(0,o.resolveComponent)("Button");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.createVNode)(p,{title:e.__("Secure Area")},null,8,["title"]),(0,o.createElementVNode)("form",{onSubmit:t[1]||(t[1]=(0,o.withModifiers)(((...e)=>u.submit&&u.submit(...e)),["prevent"])),class:"bg-white dark:bg-gray-800 shadow rounded-lg p-8 w-[25rem] mx-auto"},[(0,o.createElementVNode)("h2",i,(0,o.toDisplayString)(e.__("Secure Area")),1),(0,o.createVNode)(h),(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("p",a,(0,o.toDisplayString)(e.__("This is a secure area of the application. Please confirm your password before continuing.")),1)]),(0,o.createElementVNode)("div",n,[(0,o.withDirectives)((0,o.createElementVNode)("input",{"onUpdate:modelValue":t[0]||(t[0]=t=>e.form.password=t),ref:"passwordInput",class:(0,o.normalizeClass)(["form-control form-input form-control-bordered w-full",{"form-control-bordered-error":e.form.errors.has("password")}]),placeholder:e.__("Password"),type:"password",name:"password",required:"",autocomplete:"current-password",autofocus:""},null,10,s),[[o.vModelText,e.form.password]]),e.form.errors.has("password")?((0,o.openBlock)(),(0,o.createBlock)(m,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.form.errors.first("password")),1)])),_:1})):(0,o.createCommentVNode)("",!0)]),(0,o.createVNode)(f,{class:"w-full flex justify-center",type:"submit",loading:e.form.processing,disabled:e.completed},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Confirm")),1)])),_:1},8,["loading","disabled"])],32)])}],["__file","ConfirmPassword.vue"]])},86796:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});var o=r(29726),i=r(35229),l=r(3056);const a=Object.assign({name:"Create"},{__name:"Create",props:(0,i.rr)(["resourceName","viaResource","viaResourceId","viaRelationship"]),setup:e=>(e,t)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(l.A),{"resource-name":e.resourceName,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,mode:"form"},null,8,["resource-name","via-resource","via-resource-id","via-relationship"]))});const n=(0,r(66262).A)(a,[["__file","Create.vue"]])},95008:(e,t,r)=>{"use strict";r.d(t,{A:()=>p});var o=r(29726);const i={key:0,class:"flex items-center"},l={key:1};var a=r(74640),n=r(30043);const s={components:{Icon:a.Icon},props:{name:{type:String,required:!1,default:"main"}},data:()=>({loading:!0,label:"",cards:[],showRefreshButton:!1,isHelpCard:!1}),created(){this.fetchDashboard()},methods:{async fetchDashboard(){this.loading=!0;try{const{data:{label:e,cards:t,showRefreshButton:r,isHelpCard:o}}=await(0,n.minimum)(Nova.request().get(this.dashboardEndpoint,{params:this.extraCardParams}),200);this.loading=!1,this.label=e,this.cards=t,this.showRefreshButton=r,this.isHelpCard=o}catch(e){if(401==e.response.status)return Nova.redirectToLogin();Nova.visit("/404")}},refreshDashboard(){Nova.$emit("metric-refresh")}},computed:{dashboardEndpoint(){return`/nova-api/dashboards/${this.name}`},shouldShowCards(){return this.cards.length>0},extraCardParams:()=>null}};var c=r(66262);const d=(0,c.A)(s,[["render",function(e,t,r,a,n,s){const c=(0,o.resolveComponent)("Head"),d=(0,o.resolveComponent)("Heading"),u=(0,o.resolveComponent)("Icon"),p=(0,o.resolveComponent)("Cards"),h=(0,o.resolveComponent)("LoadingView"),m=(0,o.resolveDirective)("tooltip");return(0,o.openBlock)(),(0,o.createBlock)(h,{loading:e.loading,dusk:"dashboard-"+this.name,class:"space-y-3"},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(c,{title:e.label},null,8,["title"]),e.label&&!e.isHelpCard||e.showRefreshButton?((0,o.openBlock)(),(0,o.createElementBlock)("div",i,[e.label&&!e.isHelpCard?((0,o.openBlock)(),(0,o.createBlock)(d,{key:0},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__(e.label)),1)])),_:1})):(0,o.createCommentVNode)("",!0),e.showRefreshButton?((0,o.openBlock)(),(0,o.createElementBlock)("button",{key:1,onClick:t[0]||(t[0]=(0,o.withModifiers)(((...e)=>s.refreshDashboard&&s.refreshDashboard(...e)),["stop"])),type:"button",class:"ml-1 hover:opacity-50 active:ring",tabindex:"0"},[(0,o.withDirectives)((0,o.createVNode)(u,{name:"refresh",type:"mini",class:"!w-3 !h-3 text-gray-500 dark:text-gray-400"},null,512),[[m,e.__("Refresh")]])])):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0),s.shouldShowCards?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[e.cards.length>0?((0,o.openBlock)(),(0,o.createBlock)(p,{key:0,dashboard:r.name,cards:e.cards},null,8,["dashboard","cards"])):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0)])),_:1},8,["loading","dusk"])}],["__file","Dashboard.vue"]]),u=Object.assign({name:"Dashboard"},{__name:"Dashboard",props:{name:{type:String,required:!1,default:"main"}},setup:e=>(t,r)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(d),{name:e.name},null,8,["name"]))}),p=(0,c.A)(u,[["__file","Dashboard.vue"]])},46351:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});var o=r(29726),i=r(35229);const l=Object.assign({name:"Detail"},{__name:"Detail",props:(0,i.rr)(["resourceName","resourceId"]),setup:e=>(e,t)=>{const r=(0,o.resolveComponent)("ResourceDetail");return(0,o.openBlock)(),(0,o.createBlock)(r,{resourceName:e.resourceName,resourceId:e.resourceId,shouldOverrideMeta:!0,shouldEnableShortcut:!0},null,8,["resourceName","resourceId"])}});const a=(0,r(66262).A)(l,[["__file","Detail.vue"]])},48199:(e,t,r)=>{"use strict";r.d(t,{A:()=>d});var o=r(29726);const i={class:"text-2xl text-center font-normal mb-6"},l={class:"mb-6"},a={class:"block mb-2"};var n=r(3526),s=r(74640);const c={layout:n.A,components:{Button:s.Button},props:{status:{type:String}},data(){return{form:Nova.form({}),verificationStatus:this.status}},watch:{status(e){this.verificationStatus=e},verificationStatus(e){"verification-link-sent"===e&&Nova.$toasted.show(this.__("A new verification link has been sent to the email address you provided in your profile settings."),{duration:null,type:"success"})}},methods:{async submit(){let{status:e}=await this.form.post(Nova.url("/email/verification-notification"));this.verificationStatus=e}},computed:{completed(){return"verification-link-sent"===this.verificationStatus}}};const d=(0,r(66262).A)(c,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("Head"),u=(0,o.resolveComponent)("DividerLine"),p=(0,o.resolveComponent)("Button");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.createVNode)(d,{title:e.__("Email Verification")},null,8,["title"]),(0,o.createElementVNode)("form",{onSubmit:t[0]||(t[0]=(0,o.withModifiers)(((...e)=>c.submit&&c.submit(...e)),["prevent"])),class:"bg-white dark:bg-gray-800 shadow rounded-lg p-8 w-[25rem] mx-auto"},[(0,o.createElementVNode)("h2",i,(0,o.toDisplayString)(e.__("Email Verification")),1),(0,o.createVNode)(u),(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("p",a,(0,o.toDisplayString)(e.__("Before continuing, could you verify your email address by clicking on the link we just emailed to you? If you didn't receive the email, we will gladly send you another.")),1)]),(0,o.createVNode)(p,{type:"submit",loading:s.form.processing,disabled:c.completed,class:"w-full flex justify-center"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Resend Verification Email")),1)])),_:1},8,["loading","disabled"])],32)])}],["__file","EmailVerification.vue"]])},17922:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});var o=r(29726),i=r(28162);const l=Object.assign({name:"Error403Page",layout:i.A},{__name:"Error403",setup:e=>(e,t)=>{const r=(0,o.resolveComponent)("CustomError403");return(0,o.openBlock)(),(0,o.createBlock)(r)}});const a=(0,r(66262).A)(l,[["__file","Error403.vue"]])},47873:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});var o=r(29726),i=r(28162);const l=Object.assign({name:"Error404Page",layout:i.A},{__name:"Error404",setup:e=>(e,t)=>{const r=(0,o.resolveComponent)("CustomError404");return(0,o.openBlock)(),(0,o.createBlock)(r)}});const a=(0,r(66262).A)(l,[["__file","Error404.vue"]])},75203:(e,t,r)=>{"use strict";r.d(t,{A:()=>d});var o=r(29726);const i={class:"text-2xl text-center font-normal mb-6"},l={class:"mb-6"},a={class:"block mb-2",for:"email"};var n=r(3526),s=r(74640);const c={layout:n.A,components:{Button:s.Button},data:()=>({form:Nova.form({email:""})}),methods:{async attempt(){const{message:e}=await this.form.post(Nova.url("/password/email"));Nova.$toasted.show(e,{action:{onClick:()=>Nova.redirectToLogin(),text:this.__("Reload")},duration:null,type:"success"}),setTimeout((()=>Nova.redirectToLogin()),5e3)}},computed:{supportsPasswordReset:()=>Nova.config("withPasswordReset"),forgotPasswordPath:()=>Nova.config("forgotPasswordPath")}};const d=(0,r(66262).A)(c,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("Head"),u=(0,o.resolveComponent)("DividerLine"),p=(0,o.resolveComponent)("HelpText"),h=(0,o.resolveComponent)("Button"),m=(0,o.resolveComponent)("LoadingView");return(0,o.openBlock)(),(0,o.createBlock)(m,{loading:!1},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(d,{title:e.__("Forgot Password")},null,8,["title"]),(0,o.createElementVNode)("form",{onSubmit:t[1]||(t[1]=(0,o.withModifiers)(((...e)=>c.attempt&&c.attempt(...e)),["prevent"])),class:"bg-white dark:bg-gray-800 shadow rounded-lg p-8 w-[25rem] mx-auto"},[(0,o.createElementVNode)("h2",i,(0,o.toDisplayString)(e.__("Forgot your password?")),1),(0,o.createVNode)(u),(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("label",a,(0,o.toDisplayString)(e.__("Email Address")),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{"onUpdate:modelValue":t[0]||(t[0]=t=>e.form.email=t),class:(0,o.normalizeClass)(["w-full form-control form-input form-control-bordered",{"form-control-bordered-error":e.form.errors.has("email")}]),id:"email",type:"email",name:"email",required:"",autofocus:""},null,2),[[o.vModelText,e.form.email]]),e.form.errors.has("email")?((0,o.openBlock)(),(0,o.createBlock)(p,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.form.errors.first("email")),1)])),_:1})):(0,o.createCommentVNode)("",!0)]),(0,o.createVNode)(h,{class:"w-full flex justify-center",type:"submit",loading:e.form.processing},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Send Password Reset Link")),1)])),_:1},8,["loading"])],32)])),_:1})}],["__file","ForgotPassword.vue"]])},85915:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});var o=r(29726),i=r(35229);const l=Object.assign({name:"Index"},{__name:"Index",props:(0,i.rr)(["resourceName"]),setup:e=>(e,t)=>{const r=(0,o.resolveComponent)("ResourceIndex");return(0,o.openBlock)(),(0,o.createBlock)(r,{resourceName:e.resourceName,shouldOverrideMeta:!0,shouldEnableShortcut:!0,collapsable:!1},null,8,["resourceName"])}});const a=(0,r(66262).A)(l,[["__file","Index.vue"]])},79714:(e,t,r)=>{"use strict";r.d(t,{A:()=>y});var o=r(29726),i=r(35229);const l={key:2,class:"flex items-center mb-6"};var a=r(53110),n=r(30043),s=r(66278);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function d(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){u(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function u(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const p={mixins:[i.k6,i.Tu,i.Nw,i.dn,i.Kx,i.Ye,i.XJ,i.IJ],name:"Lens",props:{lens:{type:String,required:!0},searchable:{type:Boolean,required:!0}},data:()=>({actionCanceller:null,resourceHasId:!1}),async created(){this.resourceInformation&&(this.getActions(),Nova.$on("refresh-resources",this.getResources))},beforeUnmount(){Nova.$off("refresh-resources",this.getResources),null!==this.actionCanceller&&this.actionCanceller()},methods:d(d({},(0,s.i0)(["fetchPolicies"])),{},{getResources(){this.loading=!0,this.resourceResponseError=null,this.$nextTick((()=>(this.clearResourceSelections(),(0,n.minimum)(Nova.request().get("/nova-api/"+this.resourceName+"/lens/"+this.lens,{params:this.resourceRequestQueryString,cancelToken:new a.qm((e=>{this.canceller=e}))}),300).then((({data:e})=>{this.resources=[],this.resourceResponse=e,this.resources=e.resources,this.softDeletes=e.softDeletes,this.perPage=e.per_page,this.resourceHasId=Boolean(e.hasId),this.handleResourcesLoaded()})).catch((e=>{if(!(0,a.FZ)(e))throw this.loading=!1,this.resourceResponseError=e,e})))))},getActions(){null!==this.actionCanceller&&this.actionCanceller(),this.actions=[],this.pivotActions=null,Nova.request().get(`/nova-api/${this.resourceName}/lens/${this.lens}/actions`,{params:{viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,relationshipType:this.relationshipType,display:"index",resources:this.selectAllMatchingChecked?"all":this.selectedResourceIds},cancelToken:new a.qm((e=>{this.actionCanceller=e}))}).then((e=>{this.actions=e.data.actions,this.pivotActions=e.data.pivotActions,this.resourceHasSoleActions=e.data.counts.sole>0,this.resourceHasActions=e.data.counts.resource>0})).catch((e=>{if(!(0,a.FZ)(e))throw e}))},getAllMatchingResourceCount(){Nova.request().get("/nova-api/"+this.resourceName+"/lens/"+this.lens+"/count",{params:this.resourceRequestQueryString}).then((e=>{this.allMatchingResourceCount=e.data.count}))},loadMore(){return null===this.currentPageLoadMore&&(this.currentPageLoadMore=this.currentPage),this.currentPageLoadMore=this.currentPageLoadMore+1,(0,n.minimum)(Nova.request().get("/nova-api/"+this.resourceName+"/lens/"+this.lens,{params:d(d({},this.resourceRequestQueryString),{},{page:this.currentPageLoadMore})}),300).then((({data:e})=>{this.resourceResponse=e,this.resources=[...this.resources,...e.resources],this.getAllMatchingResourceCount(),Nova.$emit("resources-loaded",{resourceName:this.resourceName,lens:this.lens,mode:"lens"})}))}}),computed:{actionQueryString(){return{currentSearch:this.currentSearch,encodedFilters:this.encodedFilters,currentTrashed:this.currentTrashed,viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship}},actionsAreAvailable(){return this.allActions.length>0&&this.resourceHasId},lensActionEndpoint(){return`/nova-api/${this.resourceName}/lens/${this.lens}/action`},cardsEndpoint(){return`/nova-api/${this.resourceName}/lens/${this.lens}/cards`},canShowDeleteMenu(){return this.resourceHasId&&Boolean(this.authorizedToDeleteSelectedResources||this.authorizedToForceDeleteSelectedResources||this.authorizedToDeleteAnyResources||this.authorizedToForceDeleteAnyResources||this.authorizedToRestoreSelectedResources||this.authorizedToRestoreAnyResources)},lensName(){if(this.resourceResponse)return this.resourceResponse.name}}};var h=r(66262);const m=(0,h.A)(p,[["render",function(e,t,r,i,a,n){const s=(0,o.resolveComponent)("Head"),c=(0,o.resolveComponent)("Cards"),d=(0,o.resolveComponent)("Heading"),u=(0,o.resolveComponent)("IndexSearchInput"),p=(0,o.resolveComponent)("ActionDropdown"),h=(0,o.resolveComponent)("ResourceTableToolbar"),m=(0,o.resolveComponent)("IndexErrorDialog"),f=(0,o.resolveComponent)("IndexEmptyDialog"),v=(0,o.resolveComponent)("ResourceTable"),g=(0,o.resolveComponent)("ResourcePagination"),y=(0,o.resolveComponent)("LoadingView"),b=(0,o.resolveComponent)("Card");return(0,o.openBlock)(),(0,o.createBlock)(y,{loading:e.initialLoading,dusk:r.lens+"-lens-component"},{default:(0,o.withCtx)((()=>[(0,o.createVNode)(s,{title:n.lensName},null,8,["title"]),e.shouldShowCards?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,cards:e.cards,"resource-name":e.resourceName,lens:r.lens},null,8,["cards","resource-name","lens"])):(0,o.createCommentVNode)("",!0),e.resourceResponse?((0,o.openBlock)(),(0,o.createBlock)(d,{key:1,class:(0,o.normalizeClass)(["mb-3",{"mt-6":e.shouldShowCards}]),textContent:(0,o.toDisplayString)(n.lensName),dusk:"lens-heading"},null,8,["class","textContent"])):(0,o.createCommentVNode)("",!0),r.searchable||e.availableStandaloneActions.length>0?((0,o.openBlock)(),(0,o.createElementBlock)("div",l,[r.searchable?((0,o.openBlock)(),(0,o.createBlock)(u,{key:0,searchable:r.searchable,modelValue:e.search,"onUpdate:modelValue":t[0]||(t[0]=t=>e.search=t)},null,8,["searchable","modelValue"])):(0,o.createCommentVNode)("",!0),e.availableStandaloneActions.length>0?((0,o.openBlock)(),(0,o.createBlock)(p,{key:1,onActionExecuted:t[1]||(t[1]=()=>e.fetchPolicies()),class:"ml-auto","resource-name":e.resourceName,"via-resource":"","via-resource-id":"","via-relationship":"","relationship-type":"",actions:e.availableStandaloneActions,"selected-resources":e.selectedResourcesForActionSelector,endpoint:n.lensActionEndpoint},null,8,["resource-name","actions","selected-resources","endpoint"])):(0,o.createCommentVNode)("",!0)])):(0,o.createCommentVNode)("",!0),(0,o.createVNode)(b,null,{default:(0,o.withCtx)((()=>[(0,o.createVNode)(h,{"actions-endpoint":n.lensActionEndpoint,"action-query-string":n.actionQueryString,"all-matching-resource-count":e.allMatchingResourceCount,"authorized-to-delete-any-resources":e.authorizedToDeleteAnyResources,"authorized-to-delete-selected-resources":e.authorizedToDeleteSelectedResources,"authorized-to-force-delete-any-resources":e.authorizedToForceDeleteAnyResources,"authorized-to-force-delete-selected-resources":e.authorizedToForceDeleteSelectedResources,"authorized-to-restore-any-resources":e.authorizedToRestoreAnyResources,"authorized-to-restore-selected-resources":e.authorizedToRestoreSelectedResources,"available-actions":e.availableActions,"clear-selected-filters":e.clearSelectedFilters,"close-delete-modal":e.closeDeleteModal,"currently-polling":e.currentlyPolling,"delete-all-matching-resources":e.deleteAllMatchingResources,"delete-selected-resources":e.deleteSelectedResources,"filter-changed":e.filterChanged,"force-delete-all-matching-resources":e.forceDeleteAllMatchingResources,"force-delete-selected-resources":e.forceDeleteSelectedResources,"get-resources":n.getResources,"has-filters":e.hasFilters,"have-standalone-actions":e.haveStandaloneActions,lens:r.lens,"is-lens-view":e.isLensView,"per-page-options":e.perPageOptions,"per-page":e.perPage,"pivot-actions":e.pivotActions,"pivot-name":e.pivotName,resources:e.resources,"resource-information":e.resourceInformation,"resource-name":e.resourceName,"restore-all-matching-resources":e.restoreAllMatchingResources,"restore-selected-resources":e.restoreSelectedResources,"current-page-count":e.resources.length,"select-all-checked":e.selectAllChecked,"select-all-matching-checked":e.selectAllMatchingResources,onDeselect:e.deselectAllResources,"selected-resources":e.selectedResources,"selected-resources-for-action-selector":e.selectedResourcesForActionSelector,"should-show-action-selector":e.shouldShowActionSelector,"should-show-checkboxes":e.shouldShowSelectAllCheckboxes,"should-show-delete-menu":e.shouldShowDeleteMenu,"should-show-polling-toggle":e.shouldShowPollingToggle,"soft-deletes":e.softDeletes,onStartPolling:e.startPolling,onStopPolling:e.stopPolling,"toggle-select-all-matching":e.toggleSelectAllMatching,"toggle-select-all":e.toggleSelectAll,"toggle-polling":e.togglePolling,"trashed-changed":e.trashedChanged,"trashed-parameter":e.trashedParameter,trashed:e.trashed,"update-per-page-changed":e.updatePerPageChanged,"via-many-to-many":e.viaManyToMany,"via-resource":e.viaResource},null,8,["actions-endpoint","action-query-string","all-matching-resource-count","authorized-to-delete-any-resources","authorized-to-delete-selected-resources","authorized-to-force-delete-any-resources","authorized-to-force-delete-selected-resources","authorized-to-restore-any-resources","authorized-to-restore-selected-resources","available-actions","clear-selected-filters","close-delete-modal","currently-polling","delete-all-matching-resources","delete-selected-resources","filter-changed","force-delete-all-matching-resources","force-delete-selected-resources","get-resources","has-filters","have-standalone-actions","lens","is-lens-view","per-page-options","per-page","pivot-actions","pivot-name","resources","resource-information","resource-name","restore-all-matching-resources","restore-selected-resources","current-page-count","select-all-checked","select-all-matching-checked","onDeselect","selected-resources","selected-resources-for-action-selector","should-show-action-selector","should-show-checkboxes","should-show-delete-menu","should-show-polling-toggle","soft-deletes","onStartPolling","onStopPolling","toggle-select-all-matching","toggle-select-all","toggle-polling","trashed-changed","trashed-parameter","trashed","update-per-page-changed","via-many-to-many","via-resource"]),(0,o.createVNode)(y,{loading:e.loading,variant:e.resourceResponse?"overlay":"default"},{default:(0,o.withCtx)((()=>[null!=e.resourceResponseError?((0,o.openBlock)(),(0,o.createBlock)(m,{key:0,resource:e.resourceInformation,onClick:n.getResources},null,8,["resource","onClick"])):((0,o.openBlock)(),(0,o.createElementBlock)(o.Fragment,{key:1},[e.resources.length?(0,o.createCommentVNode)("",!0):((0,o.openBlock)(),(0,o.createBlock)(f,{key:0,"create-button-label":e.createButtonLabel,"singular-name":e.singularName,"resource-name":e.resourceName,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"relationship-type":e.relationshipType,"authorized-to-create":e.authorizedToCreate,"authorized-to-relate":e.authorizedToRelate},null,8,["create-button-label","singular-name","resource-name","via-resource","via-resource-id","via-relationship","relationship-type","authorized-to-create","authorized-to-relate"])),(0,o.createVNode)(v,{"authorized-to-relate":e.authorizedToRelate,"resource-name":e.resourceName,resources:e.resources,"singular-name":e.singularName,"selected-resources":e.selectedResources,"selected-resource-ids":e.selectedResourceIds,"actions-are-available":n.actionsAreAvailable,"actions-endpoint":n.lensActionEndpoint,"should-show-checkboxes":e.shouldShowCheckboxes,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"relationship-type":e.relationshipType,"update-selection-status":e.updateSelectionStatus,sortable:!0,onOrder:e.orderByField,onResetOrderBy:e.resetOrderBy,onDelete:e.deleteResources,onRestore:e.restoreResources,onActionExecuted:n.getResources,ref:"resourceTable"},null,8,["authorized-to-relate","resource-name","resources","singular-name","selected-resources","selected-resource-ids","actions-are-available","actions-endpoint","should-show-checkboxes","via-resource","via-resource-id","via-relationship","relationship-type","update-selection-status","onOrder","onResetOrderBy","onDelete","onRestore","onActionExecuted"]),(0,o.createVNode)(g,{"pagination-component":e.paginationComponent,"should-show-pagination":e.shouldShowPagination,"has-next-page":e.hasNextPage,"has-previous-page":e.hasPreviousPage,"load-more":n.loadMore,"select-page":e.selectPage,"total-pages":e.totalPages,"current-page":e.currentPage,"per-page":e.perPage,"resource-count-label":e.resourceCountLabel,"current-resource-count":e.currentResourceCount,"all-matching-resource-count":e.allMatchingResourceCount},null,8,["pagination-component","should-show-pagination","has-next-page","has-previous-page","load-more","select-page","total-pages","current-page","per-page","resource-count-label","current-resource-count","all-matching-resource-count"])],64))])),_:1},8,["loading","variant"])])),_:1})])),_:1},8,["loading","dusk"])}],["__file","Lens.vue"]]);function f(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function v(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const g=Object.assign({name:"Lens"},{__name:"Lens",props:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?f(Object(r),!0).forEach((function(t){v(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):f(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({lens:{type:String,required:!0},searchable:{type:Boolean,default:!1}},(0,i.rr)(["resourceName"])),setup:e=>(t,r)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(m),{resourceName:t.resourceName,lens:e.lens,searchable:e.searchable},null,8,["resourceName","lens","searchable"]))}),y=(0,h.A)(g,[["__file","Lens.vue"]])},6511:(e,t,r)=>{"use strict";r.d(t,{A:()=>v});var o=r(29726);const i={class:"text-2xl text-center font-normal mb-6"},l={class:"mb-6"},a={class:"block mb-2",for:"username"},n=["type","name"],s={class:"mb-6"},c={class:"block mb-2",for:"password"},d={class:"flex mb-6"},u={key:0,class:"ml-auto"},p=["href","textContent"];var h=r(3526),m=r(74640);const f={name:"LoginPage",layout:h.A,components:{Checkbox:m.Checkbox,Button:m.Button},props:{username:{type:String,default:"email"},email:{type:String,default:"email"}},data(){return{form:Nova.form({[this.username]:"",password:"",remember:!1})}},methods:{async attempt(){try{const{redirect:e,two_factor:t}=await this.form.post(Nova.url("/login"));let r={url:Nova.url("/"),remote:!0};!0===t?r={url:Nova.url("/user-security/two-factor-challenge"),remote:!1}:null!=e&&(r={url:e,remote:!0}),Nova.visit(r)}catch(e){500===e.response?.status&&Nova.error(this.__("There was a problem submitting the form."))}}},computed:{usernameLabel(){return this.username===this.email?"Email Address":"Username"},usernameInputType(){return this.username===this.email?"email":"text"},supportsPasswordReset:()=>Nova.config("withPasswordReset"),forgotPasswordPath:()=>Nova.config("forgotPasswordPath")}};const v=(0,r(66262).A)(f,[["render",function(e,t,r,h,m,f){const v=(0,o.resolveComponent)("Head"),g=(0,o.resolveComponent)("DividerLine"),y=(0,o.resolveComponent)("HelpText"),b=(0,o.resolveComponent)("Checkbox"),k=(0,o.resolveComponent)("Link"),w=(0,o.resolveComponent)("Button");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.createVNode)(v,{title:e.__("Log In")},null,8,["title"]),(0,o.createElementVNode)("form",{onSubmit:t[3]||(t[3]=(0,o.withModifiers)(((...e)=>f.attempt&&f.attempt(...e)),["prevent"])),class:"bg-white dark:bg-gray-800 shadow rounded-lg p-8 max-w-[25rem] mx-auto"},[(0,o.createElementVNode)("h2",i,(0,o.toDisplayString)(e.__("Welcome Back!")),1),(0,o.createVNode)(g),(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("label",a,(0,o.toDisplayString)(e.__(f.usernameLabel)),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{"onUpdate:modelValue":t[0]||(t[0]=e=>m.form[r.username]=e),class:(0,o.normalizeClass)(["w-full form-control form-input form-control-bordered",{"form-control-bordered-error":m.form.errors.has(r.username)}]),id:"username",type:f.usernameInputType,name:r.username,autofocus:"",autocomplete:"username",required:""},null,10,n),[[o.vModelDynamic,m.form[r.username]]]),m.form.errors.has(r.username)?((0,o.openBlock)(),(0,o.createBlock)(y,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(m.form.errors.first(r.username)),1)])),_:1})):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("div",s,[(0,o.createElementVNode)("label",c,(0,o.toDisplayString)(e.__("Password")),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{"onUpdate:modelValue":t[1]||(t[1]=e=>m.form.password=e),class:(0,o.normalizeClass)(["w-full form-control form-input form-control-bordered",{"form-control-bordered-error":m.form.errors.has("password")}]),id:"password",type:"password",name:"password",autocomplete:"current-password",required:""},null,2),[[o.vModelText,m.form.password]]),m.form.errors.has("password")?((0,o.openBlock)(),(0,o.createBlock)(y,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(m.form.errors.first("password")),1)])),_:1})):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("div",d,[(0,o.createVNode)(b,{onChange:t[2]||(t[2]=()=>m.form.remember=!m.form.remember),"model-value":m.form.remember,dusk:"remember-button",label:e.__("Remember me")},null,8,["model-value","label"]),f.supportsPasswordReset||!1!==f.forgotPasswordPath?((0,o.openBlock)(),(0,o.createElementBlock)("div",u,[!1===f.forgotPasswordPath?((0,o.openBlock)(),(0,o.createBlock)(k,{key:0,href:e.$url("/password/reset"),class:"text-gray-500 font-bold no-underline",textContent:(0,o.toDisplayString)(e.__("Forgot your password?"))},null,8,["href","textContent"])):((0,o.openBlock)(),(0,o.createElementBlock)("a",{key:1,href:f.forgotPasswordPath,class:"text-gray-500 font-bold no-underline",textContent:(0,o.toDisplayString)(e.__("Forgot your password?"))},null,8,p))])):(0,o.createCommentVNode)("",!0)]),(0,o.createVNode)(w,{class:"w-full flex justify-center",type:"submit",loading:m.form.processing},{default:(0,o.withCtx)((()=>[(0,o.createElementVNode)("span",null,(0,o.toDisplayString)(e.__("Log In")),1)])),_:1},8,["loading"])],32)])}],["__file","Login.vue"]])},73464:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});var o=r(29726),i=r(35229),l=r(3056);const a=Object.assign({name:"Replicate",extends:l.A},{__name:"Replicate",props:(0,i.rr)(["resourceName","resourceId"]),setup:e=>(e,t)=>{const r=(0,o.resolveComponent)("CreateForm");return(0,o.openBlock)(),(0,o.createBlock)(r,{mode:"form","resource-name":e.resourceName,"from-resource-id":e.resourceId,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"should-override-meta":"","form-unique-id":e.formUniqueId,onResourceCreated:e.handleResourceCreated,onCreateCancelled:e.cancelCreatingResource,onUpdateFormStatus:e.onUpdateFormStatus},null,8,["resource-name","from-resource-id","via-resource","via-resource-id","via-relationship","form-unique-id","onResourceCreated","onCreateCancelled","onUpdateFormStatus"])}});const n=(0,r(66262).A)(a,[["__file","Replicate.vue"]])},74234:(e,t,r)=>{"use strict";r.d(t,{A:()=>g});var o=r(29726),i=r(3526),l=r(74640),a=r(12215),n=r.n(a),s=r(65835);const c={class:"text-2xl text-center font-normal mb-6"},d={class:"mb-6"},u={class:"block mb-2",for:"email"},p={class:"mb-6"},h={class:"block mb-2",for:"password"},m={class:"mb-6"},f={class:"block mb-2",for:"password_confirmation"},v=Object.assign({layout:i.A},{__name:"ResetPassword",props:{email:{type:String,required:!1},token:{type:String,required:!0}},setup(e){const t=e,r=(0,o.reactive)(Nova.form({email:t.email,password:"",password_confirmation:"",token:t.token})),{__:i}=(0,s.B)();async function a(){const{message:e}=await r.post(Nova.url("/password/reset")),t={url:Nova.url("/"),remote:!0};n().set("token",Math.random().toString(36),{expires:365}),Nova.$toasted.show(e,{action:{onClick:()=>Nova.visit(t),text:i("Reload")},duration:null,type:"success"}),setTimeout((()=>Nova.visit(t)),5e3)}return(e,t)=>{const n=(0,o.resolveComponent)("Head"),s=(0,o.resolveComponent)("DividerLine"),v=(0,o.resolveComponent)("HelpText");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.createVNode)(n,{title:(0,o.unref)(i)("Reset Password")},null,8,["title"]),(0,o.createElementVNode)("form",{onSubmit:(0,o.withModifiers)(a,["prevent"]),class:"bg-white dark:bg-gray-800 shadow rounded-lg p-8 w-[25rem] mx-auto"},[(0,o.createElementVNode)("h2",c,(0,o.toDisplayString)((0,o.unref)(i)("Reset Password")),1),(0,o.createVNode)(s),(0,o.createElementVNode)("div",d,[(0,o.createElementVNode)("label",u,(0,o.toDisplayString)((0,o.unref)(i)("Email Address")),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{"onUpdate:modelValue":t[0]||(t[0]=e=>r.email=e),class:(0,o.normalizeClass)(["w-full form-control form-input form-control-bordered",{"form-control-bordered-error":r.errors.has("email")}]),id:"email",type:"email",name:"email",required:"",autofocus:""},null,2),[[o.vModelText,r.email]]),r.errors.has("email")?((0,o.openBlock)(),(0,o.createBlock)(v,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.errors.first("email")),1)])),_:1})):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("div",p,[(0,o.createElementVNode)("label",h,(0,o.toDisplayString)((0,o.unref)(i)("Password")),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{"onUpdate:modelValue":t[1]||(t[1]=e=>r.password=e),class:(0,o.normalizeClass)(["w-full form-control form-input form-control-bordered",{"form-control-bordered-error":r.errors.has("password")}]),id:"password",type:"password",name:"password",required:""},null,2),[[o.vModelText,r.password]]),r.errors.has("password")?((0,o.openBlock)(),(0,o.createBlock)(v,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.errors.first("password")),1)])),_:1})):(0,o.createCommentVNode)("",!0)]),(0,o.createElementVNode)("div",m,[(0,o.createElementVNode)("label",f,(0,o.toDisplayString)((0,o.unref)(i)("Confirm Password")),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{"onUpdate:modelValue":t[2]||(t[2]=e=>r.password_confirmation=e),class:(0,o.normalizeClass)(["w-full form-control form-input form-control-bordered",{"form-control-bordered-error":r.errors.has("password_confirmation")}]),id:"password_confirmation",type:"password",name:"password_confirmation",required:""},null,2),[[o.vModelText,r.password_confirmation]]),r.errors.has("password_confirmation")?((0,o.openBlock)(),(0,o.createBlock)(v,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(r.errors.first("password_confirmation")),1)])),_:1})):(0,o.createCommentVNode)("",!0)]),(0,o.createVNode)((0,o.unref)(l.Button),{class:"w-full flex justify-center",type:"submit",loading:r.processing},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)((0,o.unref)(i)("Reset Password")),1)])),_:1},8,["loading"])],32)])}}});const g=(0,r(66262).A)(v,[["__file","ResetPassword.vue"]])},19791:(e,t,r)=>{"use strict";r.d(t,{A:()=>v});var o=r(29726);const i={class:"text-2xl text-center font-normal mb-6"},l={class:"mb-6"},a={class:"block mb-2"},n={key:0,class:"mb-6"},s={class:"block mb-2",for:"code"},c={key:1,class:"mb-6"},d={class:"block mb-2",for:"recovery_code"},u={class:"flex mb-6"},p={class:"ml-auto"};var h=r(3526),m=r(74640);const f={layout:h.A,components:{Button:m.Button},data:()=>({form:Nova.form({code:"",recovery_code:""}),recovery:!1,completed:!1}),watch:{recovery(e){this.$nextTick((()=>{e?(this.$refs.recoveryCodeInput.focus(),this.form.code=""):(this.$refs.codeInput.focus(),this.form.recovery_code="")}))}},methods:{async attempt(){try{const{redirect:e}=await this.form.post(Nova.url("/user-security/two-factor-challenge"));this.completed=!0;let t={url:Nova.url("/"),remote:!0};null!=e&&(t={url:e,remote:!0}),Nova.visit(t)}catch(e){500===e.response?.status&&Nova.error(this.__("There was a problem submitting the form."))}},async toggleRecovery(){this.recovery^=!0}}};const v=(0,r(66262).A)(f,[["render",function(e,t,r,h,m,f){const v=(0,o.resolveComponent)("Head"),g=(0,o.resolveComponent)("DividerLine"),y=(0,o.resolveComponent)("HelpText"),b=(0,o.resolveComponent)("Button");return(0,o.openBlock)(),(0,o.createElementBlock)("div",null,[(0,o.createVNode)(v,{title:e.__("Two-factor Confirmation")},null,8,["title"]),(0,o.createElementVNode)("form",{onSubmit:t[2]||(t[2]=(0,o.withModifiers)(((...e)=>f.attempt&&f.attempt(...e)),["prevent"])),class:"bg-white dark:bg-gray-800 shadow rounded-lg p-8 w-[25rem] mx-auto"},[(0,o.createElementVNode)("h2",i,(0,o.toDisplayString)(e.__("Two-factor Confirmation")),1),(0,o.createVNode)(g),(0,o.createElementVNode)("div",l,[(0,o.createElementVNode)("p",a,(0,o.toDisplayString)(e.__(e.recovery?"Please confirm access to your account by entering one of your emergency recovery codes.":"Please confirm access to your account by entering the authentication code provided by your authenticator application.")),1)]),e.recovery?((0,o.openBlock)(),(0,o.createElementBlock)("div",c,[(0,o.createElementVNode)("label",d,(0,o.toDisplayString)(e.__("Recovery Code")),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{ref:"recoveryCodeInput","onUpdate:modelValue":t[1]||(t[1]=t=>e.form.recovery_code=t),id:"recovery_code",type:"text",name:"recovery_code",autocomplete:"one-time-code",autofocus:"",class:(0,o.normalizeClass)(["form-control form-input form-control-bordered w-full",{"form-control-bordered-error":e.form.errors.has("code")}])},null,2),[[o.vModelText,e.form.recovery_code]]),e.form.errors.has("recovery_code")?((0,o.openBlock)(),(0,o.createBlock)(y,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.form.errors.first("recovery_code")),1)])),_:1})):(0,o.createCommentVNode)("",!0)])):((0,o.openBlock)(),(0,o.createElementBlock)("div",n,[(0,o.createElementVNode)("label",s,(0,o.toDisplayString)(e.__("Code")),1),(0,o.withDirectives)((0,o.createElementVNode)("input",{ref:"codeInput","onUpdate:modelValue":t[0]||(t[0]=t=>e.form.code=t),id:"code",type:"text",name:"code",inputmode:"numeric",autocomplete:"one-time-code",autofocus:"",class:(0,o.normalizeClass)(["form-control form-input form-control-bordered w-full",{"form-control-bordered-error":e.form.errors.has("code")}])},null,2),[[o.vModelText,e.form.code]]),e.form.errors.has("code")?((0,o.openBlock)(),(0,o.createBlock)(y,{key:0,class:"mt-2 text-red-500"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.form.errors.first("code")),1)])),_:1})):(0,o.createCommentVNode)("",!0)])),(0,o.createElementVNode)("div",u,[(0,o.createElementVNode)("div",p,[(0,o.createVNode)(b,{type:"button",variant:"ghost",onClick:(0,o.withModifiers)(f.toggleRecovery,["prevent"]),class:"text-gray-500 font-bold no-underline"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__(e.recovery?"Use a recovery code":"Use an authentication code")),1)])),_:1},8,["onClick"])])]),(0,o.createVNode)(b,{loading:e.form.processing,disabled:e.completed,type:"submit",class:"w-full flex justify-center"},{default:(0,o.withCtx)((()=>[(0,o.createTextVNode)((0,o.toDisplayString)(e.__("Log In")),1)])),_:1},8,["loading","disabled"])],32)])}],["__file","TwoFactorChallenge.vue"]])},59856:(e,t,r)=>{"use strict";r.d(t,{A:()=>k});var o=r(29726);const i=["data-form-unique-id"],l={class:"mb-8 space-y-4"},a={class:"flex flex-col md:flex-row md:items-center justify-center md:justify-end space-y-2 md:space-y-0 md:space-x-3"};var n=r(74640),s=r(35229),c=r(66278),d=r(15101),u=r.n(d);function p(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function h(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?p(Object(r),!0).forEach((function(t){m(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):p(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function m(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const f={components:{Button:n.Button},mixins:[s.B5,s.qR,s.Ye,s.rd],provide(){return{removeFile:this.removeFile}},props:(0,s.rr)(["resourceName","resourceId","viaResource","viaResourceId","viaRelationship"]),data:()=>({relationResponse:null,loading:!0,submittedViaUpdateResourceAndContinueEditing:!1,submittedViaUpdateResource:!1,title:null,fields:[],panels:[],lastRetrievedAt:null}),async created(){if(Nova.missingResource(this.resourceName))return Nova.visit("/404");if(this.isRelation){const{data:e}=await Nova.request().get(`/nova-api/${this.viaResource}/field/${this.viaRelationship}`,{params:{relatable:!0}});this.relationResponse=e}this.getFields(),this.updateLastRetrievedAtTimestamp()},methods:h(h({},(0,c.i0)(["fetchPolicies"])),{},{handleFileDeleted(){},removeFile(e){const{resourceName:t,resourceId:r}=this;Nova.request().delete(`/nova-api/${t}/${r}/field/${e}`)},handleResourceLoaded(){this.loading=!1,Nova.$emit("resource-loaded",{resourceName:this.resourceName,resourceId:this.resourceId.toString(),mode:"update"})},async getFields(){this.loading=!0,this.panels=[],this.fields=[];const{data:{title:e,panels:t,fields:r}}=await Nova.request().get(`/nova-api/${this.resourceName}/${this.resourceId}/update-fields`,{params:{editing:!0,editMode:"update",viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship}}).catch((e=>{404!=e.response.status||Nova.visit("/404")}));this.title=e,this.panels=t,this.fields=r,this.handleResourceLoaded()},async submitViaUpdateResource(e){e.preventDefault(),this.submittedViaUpdateResource=!0,this.submittedViaUpdateResourceAndContinueEditing=!1,await this.updateResource()},async submitViaUpdateResourceAndContinueEditing(e){e.preventDefault(),this.submittedViaUpdateResourceAndContinueEditing=!0,this.submittedViaUpdateResource=!1,await this.updateResource()},cancelUpdatingResource(){this.handleProceedingToPreviousPage(),this.proceedToPreviousPage(this.isRelation?`/resources/${this.viaResource}/${this.viaResourceId}`:`/resources/${this.resourceName}/${this.resourceId}`)},async updateResource(){if(this.isWorking=!0,this.$refs.form.reportValidity())try{const{data:{redirect:e,id:t}}=await this.updateRequest();if(await this.fetchPolicies(),Nova.success(this.__("The :resource was updated!",{resource:this.resourceInformation.singularLabel.toLowerCase()})),Nova.$emit("resource-updated",{resourceName:this.resourceName,resourceId:t}),await this.updateLastRetrievedAtTimestamp(),!this.submittedViaUpdateResource)return void(t!=this.resourceId?Nova.visit(`/resources/${this.resourceName}/${t}/edit`):(window.scrollTo(0,0),this.disableNavigateBackUsingHistory(),this.getFields(),this.resetErrors(),this.submittedViaUpdateResource=!1,this.submittedViaUpdateResourceAndContinueEditing=!1,this.isWorking=!1));Nova.visit(e)}catch(e){window.scrollTo(0,0),this.submittedViaUpdateResource=!1,this.submittedViaUpdateResourceAndContinueEditing=!1,this.handleOnUpdateResponseError(e)}this.submittedViaUpdateResource=!1,this.submittedViaUpdateResourceAndContinueEditing=!1,this.isWorking=!1},updateRequest(){return Nova.request().post(`/nova-api/${this.resourceName}/${this.resourceId}`,this.updateResourceFormData(),{params:{viaResource:this.viaResource,viaResourceId:this.viaResourceId,viaRelationship:this.viaRelationship,editing:!0,editMode:"update"}})},updateResourceFormData(){return u()(new FormData,(e=>{Object.values(this.panels).forEach((t=>{Object.values(t.fields).forEach((t=>{t.fill(e)}))})),e.append("_method","PUT"),e.append("_retrieved_at",this.lastRetrievedAt)}))},updateLastRetrievedAtTimestamp(){this.lastRetrievedAt=Math.floor((new Date).getTime()/1e3)},onUpdateFormStatus(){}}),computed:{wasSubmittedViaUpdateResourceAndContinueEditing(){return this.isWorking&&this.submittedViaUpdateResourceAndContinueEditing},wasSubmittedViaUpdateResource(){return this.isWorking&&this.submittedViaUpdateResource},singularName(){return this.relationResponse?this.relationResponse.singularLabel:this.resourceInformation.singularLabel},updateButtonLabel(){return this.resourceInformation.updateButtonLabel},isRelation(){return Boolean(this.viaResourceId&&this.viaRelationship)}}};var v=r(66262);const g=(0,v.A)(f,[["render",function(e,t,r,n,s,c){const d=(0,o.resolveComponent)("Head"),u=(0,o.resolveComponent)("Button"),p=(0,o.resolveComponent)("LoadingView");return(0,o.openBlock)(),(0,o.createBlock)(p,{loading:e.loading},{default:(0,o.withCtx)((()=>[e.resourceInformation&&e.title?((0,o.openBlock)(),(0,o.createBlock)(d,{key:0,title:e.__("Update :resource: :title",{resource:e.resourceInformation.singularLabel,title:e.title})},null,8,["title"])):(0,o.createCommentVNode)("",!0),e.panels?((0,o.openBlock)(),(0,o.createElementBlock)("form",{key:1,onSubmit:t[0]||(t[0]=(...e)=>c.submitViaUpdateResource&&c.submitViaUpdateResource(...e)),onChange:t[1]||(t[1]=(...e)=>c.onUpdateFormStatus&&c.onUpdateFormStatus(...e)),"data-form-unique-id":e.formUniqueId,autocomplete:"off",ref:"form"},[(0,o.createElementVNode)("div",l,[((0,o.openBlock)(!0),(0,o.createElementBlock)(o.Fragment,null,(0,o.renderList)(e.panels,(t=>((0,o.openBlock)(),(0,o.createBlock)((0,o.resolveDynamicComponent)("form-"+t.component),{key:t.id,onUpdateLastRetrievedAtTimestamp:c.updateLastRetrievedAtTimestamp,onFileDeleted:c.handleFileDeleted,onFieldChanged:c.onUpdateFormStatus,onFileUploadStarted:e.handleFileUploadStarted,onFileUploadFinished:e.handleFileUploadFinished,panel:t,name:t.name,"resource-id":e.resourceId,"resource-name":e.resourceName,fields:t.fields,"form-unique-id":e.formUniqueId,mode:"form","validation-errors":e.validationErrors,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"show-help-text":!0},null,40,["onUpdateLastRetrievedAtTimestamp","onFileDeleted","onFieldChanged","onFileUploadStarted","onFileUploadFinished","panel","name","resource-id","resource-name","fields","form-unique-id","validation-errors","via-resource","via-resource-id","via-relationship"])))),128))]),(0,o.createElementVNode)("div",a,[(0,o.createVNode)(u,{dusk:"cancel-update-button",variant:"ghost",label:e.__("Cancel"),onClick:c.cancelUpdatingResource,disabled:e.isWorking},null,8,["label","onClick","disabled"]),(0,o.createVNode)(u,{dusk:"update-and-continue-editing-button",onClick:c.submitViaUpdateResourceAndContinueEditing,disabled:e.isWorking,loading:c.wasSubmittedViaUpdateResourceAndContinueEditing,label:e.__("Update & Continue Editing")},null,8,["onClick","disabled","loading","label"]),(0,o.createVNode)(u,{dusk:"update-button",type:"submit",disabled:e.isWorking,loading:c.wasSubmittedViaUpdateResource,label:c.updateButtonLabel},null,8,["disabled","loading","label"])])],40,i)):(0,o.createCommentVNode)("",!0)])),_:1},8,["loading"])}],["__file","Update.vue"]]);var y=r(25542);const b=Object.assign({name:"Update"},{__name:"Update",props:(0,s.rr)(["resourceName","resourceId","viaResource","viaResourceId","viaRelationship"]),setup(e){const t=(0,y.L)();return(e,r)=>((0,o.openBlock)(),(0,o.createBlock)((0,o.unref)(g),{"resource-name":e.resourceName,"resource-id":e.resourceId,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,"form-unique-id":(0,o.unref)(t)},null,8,["resource-name","resource-id","via-resource","via-resource-id","via-relationship","form-unique-id"]))}}),k=(0,v.A)(b,[["__file","Update.vue"]])},96731:(e,t,r)=>{"use strict";r.d(t,{A:()=>a});var o=r(29726),i=r(25542);const l=Object.assign({name:"UpdateAttached"},{__name:"UpdateAttached",props:{resourceName:{type:String,required:!0},resourceId:{required:!0},relatedResourceName:{type:String,required:!0},relatedResourceId:{required:!0},viaResource:{default:""},viaResourceId:{default:""},parentResource:{type:Object},viaRelationship:{default:""},viaPivotId:{default:null},polymorphic:{default:!1}},setup(e){const t=(0,i.L)();return(r,i)=>{const l=(0,o.resolveComponent)("UpdateAttachedResource");return(0,o.openBlock)(),(0,o.createBlock)(l,{"resource-name":e.resourceName,"resource-id":e.resourceId,"related-resource-name":e.relatedResourceName,"related-resource-id":e.relatedResourceId,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"parent-resource":e.parentResource,"via-relationship":e.viaRelationship,"via-pivot-id":e.viaPivotId,polymorphic:e.polymorphic,"form-unique-id":(0,o.unref)(t)},null,8,["resource-name","resource-id","related-resource-name","related-resource-id","via-resource","via-resource-id","parent-resource","via-relationship","via-pivot-id","polymorphic","form-unique-id"])}}});const a=(0,r(66262).A)(l,[["__file","UpdateAttached.vue"]])},99962:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});var o=r(29726);const i={class:"max-w-7xl mx-auto py-10 sm:px-6 lg:px-8"},l={class:"mb-10"},a=Object.assign({name:"UserSecurity"},{__name:"UserSecurity",props:{options:{type:Object,required:!0},user:{type:Object,required:!0}},setup(e){const t=(0,o.computed)((()=>Nova.config("fortifyFeatures")));return(r,a)=>{const n=(0,o.resolveComponent)("Head"),s=(0,o.resolveComponent)("Heading"),c=(0,o.resolveComponent)("UserSecurityUpdatePasswords"),d=(0,o.resolveComponent)("DividerLine"),u=(0,o.resolveComponent)("UserSecurityTwoFactorAuthentication");return(0,o.openBlock)(),(0,o.createElementBlock)("div",i,[(0,o.createVNode)(n,{title:r.__("User Security")},null,8,["title"]),(0,o.createElementVNode)("div",l,[(0,o.createVNode)(s,{level:1,textContent:(0,o.toDisplayString)(r.__("User Security"))},null,8,["textContent"])]),(0,o.createElementVNode)("div",null,[t.value.includes("update-passwords")?((0,o.openBlock)(),(0,o.createBlock)(c,{key:0,user:e.user},null,8,["user"])):(0,o.createCommentVNode)("",!0),t.value.includes("update-passwords")&&t.value.includes("two-factor-authentication")?((0,o.openBlock)(),(0,o.createBlock)(d,{key:1})):(0,o.createCommentVNode)("",!0),t.value.includes("two-factor-authentication")?((0,o.openBlock)(),(0,o.createBlock)(u,{key:2,options:e.options["two-factor-authentication"]??{},user:e.user},null,8,["options","user"])):(0,o.createCommentVNode)("",!0)])])}}});const n=(0,r(66262).A)(a,[["__file","UserSecurity.vue"]])},3056:(e,t,r)=>{"use strict";r.d(t,{A:()=>c});var o=r(29726);var i=r(35229),l=r(25542);function a(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,o)}return r}function n(e,t,r){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var o=r.call(e,t||"default");if("object"!=typeof o)return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}const s={emits:["refresh","create-cancelled","finished-loading"],mixins:[i.rd,i.Uf],provide(){return{removeFile:this.removeFile}},props:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?a(Object(r),!0).forEach((function(t){n(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}({mode:{type:String,default:"form",validator:e=>["modal","form"].includes(e)}},(0,i.rr)(["resourceName","viaResource","viaResourceId","viaRelationship"])),data:()=>({formUniqueId:(0,l.L)()}),methods:{handleResourceCreated({redirect:e,id:t}){return"form"!==this.mode&&this.allowLeavingModal(),Nova.$emit("resource-created",{resourceName:this.resourceName,resourceId:t}),"form"===this.mode?Nova.visit(e):this.$emit("refresh",{redirect:e,id:t})},handleResourceCreatedAndAddingAnother(){this.disableNavigateBackUsingHistory()},cancelCreatingResource(){return"form"===this.mode?(this.handleProceedingToPreviousPage(),void this.proceedToPreviousPage(this.isRelation?`/resources/${this.viaResource}/${this.viaResourceId}`:`/resources/${this.resourceName}`)):(this.allowLeavingModal(),this.$emit("create-cancelled"))},onUpdateFormStatus(){"form"!==this.mode&&this.updateModalStatus()},removeFile(e){}},computed:{isRelation(){return Boolean(this.viaResourceId&&this.viaRelationship)}}};const c=(0,r(66262).A)(s,[["render",function(e,t,r,i,l,a){const n=(0,o.resolveComponent)("CreateForm");return(0,o.openBlock)(),(0,o.createBlock)(n,{onResourceCreated:a.handleResourceCreated,onResourceCreatedAndAddingAnother:a.handleResourceCreatedAndAddingAnother,onCreateCancelled:a.cancelCreatingResource,mode:r.mode,"resource-name":e.resourceName,"via-resource":e.viaResource,"via-resource-id":e.viaResourceId,"via-relationship":e.viaRelationship,onUpdateFormStatus:a.onUpdateFormStatus,onFinishedLoading:t[0]||(t[0]=t=>e.$emit("finished-loading")),"should-override-meta":"form"===r.mode,"form-unique-id":e.formUniqueId},null,8,["onResourceCreated","onResourceCreatedAndAddingAnother","onCreateCancelled","mode","resource-name","via-resource","via-resource-id","via-relationship","onUpdateFormStatus","should-override-meta","form-unique-id"])}],["__file","Create.vue"]])},60630:(e,t,r)=>{var o={"./ActionSelector.vue":65215,"./AppLogo.vue":72172,"./Avatar.vue":39383,"./Backdrop.vue":62953,"./Badges/Badge.vue":57091,"./Badges/CircleBadge.vue":82958,"./BooleanOption.vue":95564,"./Buttons/CopyButton.vue":1780,"./Buttons/InertiaButton.vue":77518,"./Buttons/InvertedButton.vue":23105,"./Card.vue":61070,"./CardWrapper.vue":40506,"./Cards.vue":90581,"./Cards/HelpCard.vue":29433,"./Checkbox.vue":63136,"./CheckboxWithLabel.vue":35893,"./CollapseButton.vue":65764,"./ConfirmsPassword.vue":96813,"./Controls/MultiSelectControl.vue":89042,"./Controls/SelectControl.vue":99138,"./CreateForm.vue":72522,"./CreateResourceButton.vue":76037,"./DefaultField.vue":57199,"./DeleteMenu.vue":52613,"./DividerLine.vue":71786,"./DropZone/DropZone.vue":28213,"./DropZone/FilePreviewBlock.vue":84547,"./DropZone/SingleDropZone.vue":80636,"./Dropdowns/ActionDropdown.vue":46644,"./Dropdowns/DetailActionDropdown.vue":30013,"./Dropdowns/Dropdown.vue":36663,"./Dropdowns/DropdownMenu.vue":41600,"./Dropdowns/DropdownMenuHeading.vue":84787,"./Dropdowns/DropdownMenuItem.vue":73020,"./Dropdowns/InlineActionDropdown.vue":58909,"./Dropdowns/SelectAllDropdown.vue":81518,"./Dropdowns/ThemeDropdown.vue":32657,"./Excerpt.vue":30422,"./FadeTransition.vue":27284,"./FieldWrapper.vue":46854,"./FilterMenu.vue":15604,"./Filters/BooleanFilter.vue":10255,"./Filters/DateFilter.vue":2891,"./Filters/FilterContainer.vue":56138,"./Filters/SelectFilter.vue":84183,"./FormButton.vue":81433,"./FormLabel.vue":62415,"./GlobalSearch.vue":36623,"./Heading.vue":13750,"./HelpText.vue":91303,"./HelpTextTooltip.vue":6491,"./Icons/CopyIcon.vue":92407,"./Icons/Editor/IconBold.vue":74960,"./Icons/Editor/IconFullScreen.vue":76825,"./Icons/Editor/IconImage.vue":57404,"./Icons/Editor/IconItalic.vue":87446,"./Icons/Editor/IconLink.vue":48309,"./Icons/ErrorPageIcon.vue":49467,"./Icons/IconArrow.vue":21449,"./Icons/IconBoolean.vue":16018,"./Icons/IconBooleanOption.vue":18711,"./Icons/Loader.vue":47833,"./ImageLoader.vue":12617,"./IndexEmptyDialog.vue":73289,"./IndexErrorDialog.vue":96735,"./Inputs/CharacterCounter.vue":87853,"./Inputs/ComboBoxInput.vue":36706,"./Inputs/IndexSearchInput.vue":26762,"./Inputs/RoundInput.vue":40902,"./Inputs/SearchInput.vue":21760,"./Inputs/SearchInputResult.vue":76402,"./LensSelector.vue":24511,"./LicenseWarning.vue":99820,"./LoadingCard.vue":89204,"./LoadingView.vue":5983,"./Markdown/MarkdownEditor.vue":1085,"./Markdown/MarkdownEditorToolbar.vue":24143,"./Menu/Breadcrumbs.vue":25787,"./Menu/MainMenu.vue":43134,"./Menu/MenuGroup.vue":16839,"./Menu/MenuItem.vue":12899,"./Menu/MenuList.vue":21081,"./Menu/MenuSection.vue":84372,"./Metrics/Base/BasePartitionMetric.vue":29033,"./Metrics/Base/BaseProgressMetric.vue":39157,"./Metrics/Base/BaseTrendMetric.vue":28104,"./Metrics/Base/BaseValueMetric.vue":32983,"./Metrics/MetricTableRow.vue":99543,"./Metrics/PartitionMetric.vue":64903,"./Metrics/ProgressMetric.vue":98825,"./Metrics/TableMetric.vue":33796,"./Metrics/TrendMetric.vue":1740,"./Metrics/ValueMetric.vue":58937,"./MobileUserMenu.vue":61462,"./Modals/ConfirmActionModal.vue":75713,"./Modals/ConfirmUploadRemovalModal.vue":48619,"./Modals/ConfirmsPasswordModal.vue":80245,"./Modals/CreateRelationModal.vue":6347,"./Modals/DeleteResourceModal.vue":24916,"./Modals/Modal.vue":41488,"./Modals/ModalContent.vue":23772,"./Modals/ModalFooter.vue":51434,"./Modals/ModalHeader.vue":62532,"./Modals/PreviewResourceModal.vue":22308,"./Modals/RestoreResourceModal.vue":71368,"./Notifications/MessageNotification.vue":14197,"./Notifications/NotificationCenter.vue":70261,"./Notifications/NotificationList.vue":15001,"./Pagination/PaginationLinks.vue":84661,"./Pagination/PaginationLoadMore.vue":55623,"./Pagination/PaginationSimple.vue":9320,"./Pagination/ResourcePagination.vue":75268,"./PanelItem.vue":57228,"./PassthroughLogo.vue":29627,"./ProgressBar.vue":5112,"./RelationPeek.vue":84227,"./Repeater/RepeaterRow.vue":34324,"./ResourceTable.vue":55293,"./ResourceTableHeader.vue":50101,"./ResourceTableRow.vue":79344,"./ResourceTableToolbar.vue":15404,"./ScrollWrap.vue":96279,"./SortableIcon.vue":33025,"./Tags/TagGroup.vue":19078,"./Tags/TagGroupItem.vue":40229,"./Tags/TagList.vue":17039,"./Tags/TagListItem.vue":99973,"./Tooltip.vue":69793,"./TooltipContent.vue":18384,"./TrashedCheckbox.vue":25882,"./Trix.vue":46199,"./UserMenu.vue":60465,"./UserSecurity/UserSecurityTwoFactorAuthentication.vue":21073,"./UserSecurity/UserSecurityUpdatePasswords.vue":39699};function i(e){var t=l(e);return r(t)}function l(e){if(!r.o(o,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return o[e]}i.keys=function(){return Object.keys(o)},i.resolve=l,e.exports=i,i.id=60630},11079:(e,t,r)=>{var o={"./AudioField.vue":2202,"./BadgeField.vue":77421,"./BelongsToField.vue":71818,"./BelongsToManyField.vue":40605,"./BooleanField.vue":3001,"./BooleanGroupField.vue":35336,"./CodeField.vue":35480,"./ColorField.vue":12310,"./CurrencyField.vue":43175,"./DateField.vue":46960,"./DateTimeField.vue":74405,"./EmailField.vue":69556,"./FileField.vue":92048,"./HasManyField.vue":70813,"./HasManyThroughField.vue":70425,"./HasOneField.vue":7746,"./HasOneThroughField.vue":8588,"./HeadingField.vue":26949,"./HiddenField.vue":41968,"./IdField.vue":13699,"./KeyValueField.vue":16979,"./MarkdownField.vue":21199,"./MorphToActionTargetField.vue":50769,"./MorphToField.vue":18318,"./MorphToManyField.vue":59958,"./MultiSelectField.vue":89535,"./Panel.vue":73437,"./PasswordField.vue":16181,"./RelationshipPanel.vue":63726,"./RepeaterField.vue":22092,"./SelectField.vue":89032,"./SlugField.vue":79175,"./SparklineField.vue":71788,"./StackField.vue":58403,"./StatusField.vue":12136,"./TabsPanel.vue":91167,"./TagField.vue":82141,"./TextField.vue":21738,"./TextareaField.vue":29765,"./TrixField.vue":96134,"./UrlField.vue":69928,"./VaporAudioField.vue":92135,"./VaporFileField.vue":57562};function i(e){var t=l(e);return r(t)}function l(e){if(!r.o(o,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return o[e]}i.keys=function(){return Object.keys(o)},i.resolve=l,e.exports=i,i.id=11079},77978:(e,t,r)=>{var o={"./BelongsToField.vue":53941,"./BooleanField.vue":43460,"./BooleanGroupField.vue":28514,"./DateField.vue":78430,"./DateTimeField.vue":94299,"./EloquentField.vue":83240,"./EmailField.vue":34245,"./MorphToField.vue":86951,"./MultiSelectField.vue":33011,"./NumberField.vue":72482,"./SelectField.vue":71595,"./TextField.vue":85645};function i(e){var t=l(e);return r(t)}function l(e){if(!r.o(o,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return o[e]}i.keys=function(){return Object.keys(o)},i.resolve=l,e.exports=i,i.id=77978},67970:(e,t,r)=>{var o={"./AudioField.vue":77054,"./BelongsToField.vue":14056,"./BooleanField.vue":36938,"./BooleanGroupField.vue":6461,"./CodeField.vue":61907,"./ColorField.vue":3210,"./CurrencyField.vue":72366,"./DateField.vue":18166,"./DateTimeField.vue":23019,"./EmailField.vue":36078,"./FileField.vue":22988,"./HasOneField.vue":58116,"./HeadingField.vue":79899,"./HiddenField.vue":6970,"./KeyValueField.vue":18053,"./KeyValueHeader.vue":99682,"./KeyValueItem.vue":5226,"./KeyValueTable.vue":83420,"./MarkdownField.vue":19399,"./MorphToField.vue":69976,"./MultiSelectField.vue":6629,"./Panel.vue":82437,"./PasswordField.vue":13662,"./RelationshipPanel.vue":52568,"./RepeaterField.vue":7275,"./SelectField.vue":48924,"./SlugField.vue":81909,"./StatusField.vue":48080,"./TabsPanel.vue":19736,"./TagField.vue":13868,"./TextField.vue":35841,"./TextareaField.vue":75649,"./TrixField.vue":98385,"./UrlField.vue":54185,"./VaporAudioField.vue":16192,"./VaporFileField.vue":50531};function i(e){var t=l(e);return r(t)}function l(e){if(!r.o(o,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return o[e]}i.keys=function(){return Object.keys(o)},i.resolve=l,e.exports=i,i.id=67970},49020:(e,t,r)=>{var o={"./AudioField.vue":43032,"./BadgeField.vue":51086,"./BelongsToField.vue":99723,"./BooleanField.vue":95915,"./BooleanGroupField.vue":55371,"./ColorField.vue":84706,"./CurrencyField.vue":41129,"./DateField.vue":81871,"./DateTimeField.vue":9952,"./EmailField.vue":13785,"./FileField.vue":48242,"./HeadingField.vue":81173,"./HiddenField.vue":76439,"./IdField.vue":21451,"./LineField.vue":24549,"./MorphToActionTargetField.vue":25736,"./MorphToField.vue":59219,"./MultiSelectField.vue":8947,"./PasswordField.vue":46750,"./SelectField.vue":61775,"./SlugField.vue":42212,"./SparklineField.vue":46086,"./StackField.vue":95328,"./StatusField.vue":7187,"./TagField.vue":25565,"./TextField.vue":89250,"./UrlField.vue":51466,"./VaporAudioField.vue":35656,"./VaporFileField.vue":22104};function i(e){var t=l(e);return r(t)}function l(e){if(!r.o(o,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return o[e]}i.keys=function(){return Object.keys(o)},i.resolve=l,e.exports=i,i.id=49020},87092:(e,t,r)=>{var o={"./HasOneField.vue":64087};function i(e){var t=l(e);return r(t)}function l(e){if(!r.o(o,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return o[e]}i.keys=function(){return Object.keys(o)},i.resolve=l,e.exports=i,i.id=87092},74640:e=>{"use strict";e.exports=LaravelNovaUi},42634:()=>{}},e=>{var t=t=>e(e.s=t);e.O(0,[524,332],(()=>(t(12327),t(43478))));e.O()}]);