@diasro/ucsd-its-frontend 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -12562,12 +12562,15 @@ const ag = ["start", "end", "left", "right", "top", "bottom"], lg = O({
12562
12562
  n.setDockVisible(!1);
12563
12563
  return;
12564
12564
  }
12565
- if (n.setCurrentSubHdr(u.label), n.execAction(u, l.eventMap), n.setActiveMenuVal(u.key), u.link) {
12566
- if (u.link.includes("http")) {
12567
- window.open(u.link, "_blank");
12568
- return;
12565
+ if (n.setCurrentSubHdr(u.label), n.execAction(u, l.eventMap), !u.children) {
12566
+ if (n.setActiveMenuVal(u.key), u.link) {
12567
+ if (u.link.includes("http")) {
12568
+ window.open(u.link, "_blank");
12569
+ return;
12570
+ }
12571
+ a.push(u.link);
12569
12572
  }
12570
- a.push(u.link);
12573
+ return;
12571
12574
  }
12572
12575
  n.setActiveMenu(u);
12573
12576
  };
@@ -341,5 +341,5 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
341
341
  }
342
342
  `)},Of={root:"p-tooltip p-component",arrow:"p-tooltip-arrow",text:"p-tooltip-text"},Ef=he.extend({name:"tooltip-directive",theme:Pf,classes:Of}),Bf=Y.extend({style:Ef});function Df(e,t){return Ff(e)||Mf(e,t)||Lf(e,t)||jf()}function jf(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
343
343
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Lf(e,t){if(e){if(typeof e=="string")return yl(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?yl(e,t):void 0}}function yl(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,a=Array(t);n<t;n++)a[n]=e[n];return a}function Mf(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var a,r,i,l,s=[],c=!0,d=!1;try{if(i=(n=n.call(e)).next,t!==0)for(;!(c=(a=i.call(n)).done)&&(s.push(a.value),s.length!==t);c=!0);}catch(u){d=!0,r=u}finally{try{if(!c&&n.return!=null&&(l=n.return(),Object(l)!==l))return}finally{if(d)throw r}}return s}}function Ff(e){if(Array.isArray(e))return e}function pl(e,t,n){return(t=Hf(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Hf(e){var t=Zf(e,"string");return dt(t)=="symbol"?t:t+""}function Zf(e,t){if(dt(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var a=n.call(e,t||"default");if(dt(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function dt(e){"@babel/helpers - typeof";return dt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},dt(e)}var Wf=Bf.extend("tooltip",{beforeMount:function(t,n){var a,r=this.getTarget(t);if(r.$_ptooltipModifiers=this.getModifiers(n),n.value){if(typeof n.value=="string")r.$_ptooltipValue=n.value,r.$_ptooltipDisabled=!1,r.$_ptooltipEscape=!0,r.$_ptooltipClass=null,r.$_ptooltipFitContent=!0,r.$_ptooltipIdAttr=jt()+"_tooltip",r.$_ptooltipShowDelay=0,r.$_ptooltipHideDelay=0,r.$_ptooltipAutoHide=!0;else if(dt(n.value)==="object"&&n.value){if(Et(n.value.value)||n.value.value.trim()==="")return;r.$_ptooltipValue=n.value.value,r.$_ptooltipDisabled=!!n.value.disabled===n.value.disabled?n.value.disabled:!1,r.$_ptooltipEscape=!!n.value.escape===n.value.escape?n.value.escape:!0,r.$_ptooltipClass=n.value.class||"",r.$_ptooltipFitContent=!!n.value.fitContent===n.value.fitContent?n.value.fitContent:!0,r.$_ptooltipIdAttr=n.value.id||jt()+"_tooltip",r.$_ptooltipShowDelay=n.value.showDelay||0,r.$_ptooltipHideDelay=n.value.hideDelay||0,r.$_ptooltipAutoHide=!!n.value.autoHide===n.value.autoHide?n.value.autoHide:!0}}else return;r.$_ptooltipZIndex=(a=n.instance.$primevue)===null||a===void 0||(a=a.config)===null||a===void 0||(a=a.zIndex)===null||a===void 0?void 0:a.tooltip,this.bindEvents(r,n),t.setAttribute("data-pd-tooltip",!0)},updated:function(t,n){var a=this.getTarget(t);if(a.$_ptooltipModifiers=this.getModifiers(n),this.unbindEvents(a),!!n.value){if(typeof n.value=="string")a.$_ptooltipValue=n.value,a.$_ptooltipDisabled=!1,a.$_ptooltipEscape=!0,a.$_ptooltipClass=null,a.$_ptooltipIdAttr=a.$_ptooltipIdAttr||jt()+"_tooltip",a.$_ptooltipShowDelay=0,a.$_ptooltipHideDelay=0,a.$_ptooltipAutoHide=!0,this.bindEvents(a,n);else if(dt(n.value)==="object"&&n.value)if(Et(n.value.value)||n.value.value.trim()===""){this.unbindEvents(a,n);return}else a.$_ptooltipValue=n.value.value,a.$_ptooltipDisabled=!!n.value.disabled===n.value.disabled?n.value.disabled:!1,a.$_ptooltipEscape=!!n.value.escape===n.value.escape?n.value.escape:!0,a.$_ptooltipClass=n.value.class||"",a.$_ptooltipFitContent=!!n.value.fitContent===n.value.fitContent?n.value.fitContent:!0,a.$_ptooltipIdAttr=n.value.id||a.$_ptooltipIdAttr||jt()+"_tooltip",a.$_ptooltipShowDelay=n.value.showDelay||0,a.$_ptooltipHideDelay=n.value.hideDelay||0,a.$_ptooltipAutoHide=!!n.value.autoHide===n.value.autoHide?n.value.autoHide:!0,this.bindEvents(a,n)}},unmounted:function(t,n){var a=this.getTarget(t);this.remove(a),this.unbindEvents(a,n),a.$_ptooltipScrollHandler&&(a.$_ptooltipScrollHandler.destroy(),a.$_ptooltipScrollHandler=null)},timer:void 0,methods:{bindEvents:function(t,n){var a=this,r=t.$_ptooltipModifiers;r.focus?(t.$_focusevent=function(i){return a.onFocus(i,n)},t.addEventListener("focus",t.$_focusevent),t.addEventListener("blur",this.onBlur.bind(this))):(t.$_mouseenterevent=function(i){return a.onMouseEnter(i,n)},t.addEventListener("mouseenter",t.$_mouseenterevent),t.addEventListener("mouseleave",this.onMouseLeave.bind(this)),t.addEventListener("click",this.onClick.bind(this))),t.addEventListener("keydown",this.onKeydown.bind(this))},unbindEvents:function(t){var n=t.$_ptooltipModifiers;n.focus?(t.removeEventListener("focus",t.$_focusevent),t.$_focusevent=null,t.removeEventListener("blur",this.onBlur.bind(this))):(t.removeEventListener("mouseenter",t.$_mouseenterevent),t.$_mouseenterevent=null,t.removeEventListener("mouseleave",this.onMouseLeave.bind(this)),t.removeEventListener("click",this.onClick.bind(this))),t.removeEventListener("keydown",this.onKeydown.bind(this))},bindScrollListener:function(t){var n=this;t.$_ptooltipScrollHandler||(t.$_ptooltipScrollHandler=new ff(t,function(){n.hide(t)})),t.$_ptooltipScrollHandler.bindScrollListener()},unbindScrollListener:function(t){t.$_ptooltipScrollHandler&&t.$_ptooltipScrollHandler.unbindScrollListener()},onMouseEnter:function(t,n){var a=t.currentTarget,r=a.$_ptooltipShowDelay;this.show(a,n,r)},onMouseLeave:function(t){var n=t.currentTarget,a=n.$_ptooltipHideDelay,r=n.$_ptooltipAutoHide;if(r)this.hide(n,a);else{var i=bt(t.target,"data-pc-name")==="tooltip"||bt(t.target,"data-pc-section")==="arrow"||bt(t.target,"data-pc-section")==="text"||bt(t.relatedTarget,"data-pc-name")==="tooltip"||bt(t.relatedTarget,"data-pc-section")==="arrow"||bt(t.relatedTarget,"data-pc-section")==="text";!i&&this.hide(n,a)}},onFocus:function(t,n){var a=t.currentTarget,r=a.$_ptooltipShowDelay;this.show(a,n,r)},onBlur:function(t){var n=t.currentTarget,a=n.$_ptooltipHideDelay;this.hide(n,a)},onClick:function(t){var n=t.currentTarget,a=n.$_ptooltipHideDelay;this.hide(n,a)},onKeydown:function(t){var n=t.currentTarget,a=n.$_ptooltipHideDelay;t.code==="Escape"&&this.hide(t.currentTarget,a)},tooltipActions:function(t,n){if(!(t.$_ptooltipDisabled||!Ki(t))){var a=this.create(t,n);this.align(t),!this.isUnstyled()&&Tu(a,250);var r=this;window.addEventListener("resize",function i(){Ou()||r.hide(t),window.removeEventListener("resize",i)}),a.addEventListener("mouseleave",function i(){r.hide(t),a.removeEventListener("mouseleave",i),t.removeEventListener("mouseenter",t.$_mouseenterevent),setTimeout(function(){return t.addEventListener("mouseenter",t.$_mouseenterevent)},50)}),this.bindScrollListener(t),ul.set("tooltip",a,t.$_ptooltipZIndex)}},show:function(t,n,a){var r=this;a!==void 0?this.timer=setTimeout(function(){return r.tooltipActions(t,n)},a):this.tooltipActions(t,n)},tooltipRemoval:function(t){this.remove(t),this.unbindScrollListener(t)},hide:function(t,n){var a=this;clearTimeout(this.timer),n!==void 0?setTimeout(function(){return a.tooltipRemoval(t)},n):this.tooltipRemoval(t)},getTooltipElement:function(t){return document.getElementById(t.$_ptooltipId)},create:function(t){var n=t.$_ptooltipModifiers,a=Kn("div",{class:!this.isUnstyled()&&this.cx("arrow"),"p-bind":this.ptm("arrow",{context:n})}),r=Kn("div",{class:!this.isUnstyled()&&this.cx("text"),"p-bind":this.ptm("text",{context:n})});t.$_ptooltipEscape?(r.innerHTML="",r.appendChild(document.createTextNode(t.$_ptooltipValue))):r.innerHTML=t.$_ptooltipValue;var i=Kn("div",pl(pl({id:t.$_ptooltipIdAttr,role:"tooltip",style:{display:"inline-block",width:t.$_ptooltipFitContent?"fit-content":void 0,pointerEvents:!this.isUnstyled()&&t.$_ptooltipAutoHide&&"none"},class:[!this.isUnstyled()&&this.cx("root"),t.$_ptooltipClass]},this.$attrSelector,""),"p-bind",this.ptm("root",{context:n})),a,r);return document.body.appendChild(i),t.$_ptooltipId=i.id,this.$el=i,i},remove:function(t){if(t){var n=this.getTooltipElement(t);n&&n.parentElement&&(ul.clear(n),document.body.removeChild(n)),t.$_ptooltipId=null}},align:function(t){var n=t.$_ptooltipModifiers;n.top?(this.alignTop(t),this.isOutOfBounds(t)&&(this.alignBottom(t),this.isOutOfBounds(t)&&this.alignTop(t))):n.left?(this.alignLeft(t),this.isOutOfBounds(t)&&(this.alignRight(t),this.isOutOfBounds(t)&&(this.alignTop(t),this.isOutOfBounds(t)&&(this.alignBottom(t),this.isOutOfBounds(t)&&this.alignLeft(t))))):n.bottom?(this.alignBottom(t),this.isOutOfBounds(t)&&(this.alignTop(t),this.isOutOfBounds(t)&&this.alignBottom(t))):(this.alignRight(t),this.isOutOfBounds(t)&&(this.alignLeft(t),this.isOutOfBounds(t)&&(this.alignTop(t),this.isOutOfBounds(t)&&(this.alignBottom(t),this.isOutOfBounds(t)&&this.alignRight(t)))))},getHostOffset:function(t){var n=t.getBoundingClientRect(),a=n.left+Nu(),r=n.top+xu();return{left:a,top:r}},alignRight:function(t){this.preAlign(t,"right");var n=this.getTooltipElement(t),a=this.getHostOffset(t),r=a.left+lt(t),i=a.top+(st(t)-st(n))/2;n.style.left=r+"px",n.style.top=i+"px"},alignLeft:function(t){this.preAlign(t,"left");var n=this.getTooltipElement(t),a=this.getHostOffset(t),r=a.left-lt(n),i=a.top+(st(t)-st(n))/2;n.style.left=r+"px",n.style.top=i+"px"},alignTop:function(t){this.preAlign(t,"top");var n=this.getTooltipElement(t),a=this.getHostOffset(t),r=a.left+(lt(t)-lt(n))/2,i=a.top-st(n);n.style.left=r+"px",n.style.top=i+"px"},alignBottom:function(t){this.preAlign(t,"bottom");var n=this.getTooltipElement(t),a=this.getHostOffset(t),r=a.left+(lt(t)-lt(n))/2,i=a.top+st(t);n.style.left=r+"px",n.style.top=i+"px"},preAlign:function(t,n){var a=this.getTooltipElement(t);a.style.left="-999px",a.style.top="-999px",Jn(a,"p-tooltip-".concat(a.$_ptooltipPosition)),!this.isUnstyled()&&Ui(a,"p-tooltip-".concat(n)),a.$_ptooltipPosition=n,a.setAttribute("data-p-position",n);var r=Dt(a,'[data-pc-section="arrow"]');r.style.top=n==="bottom"?"0":n==="right"||n==="left"||n!=="right"&&n!=="left"&&n!=="top"&&n!=="bottom"?"50%":null,r.style.bottom=n==="top"?"0":null,r.style.left=n==="right"||n!=="right"&&n!=="left"&&n!=="top"&&n!=="bottom"?"0":n==="top"||n==="bottom"?"50%":null,r.style.right=n==="left"?"0":null},isOutOfBounds:function(t){var n=this.getTooltipElement(t),a=n.getBoundingClientRect(),r=a.top,i=a.left,l=lt(n),s=st(n),c=Iu();return i+l>c.width||i<0||r<0||r+s>c.height},getTarget:function(t){var n;return Gi(t,"p-inputwrapper")&&(n=Dt(t,"input"))!==null&&n!==void 0?n:t},getModifiers:function(t){return t.modifiers&&Object.keys(t.modifiers).length?t.modifiers:t.arg&&dt(t.arg)==="object"?Object.entries(t.arg).reduce(function(n,a){var r=Df(a,2),i=r[0],l=r[1];return(i==="event"||i==="position")&&(n[l]=!0),n},{}):{}}}}),Yf={name:"BaseDock",extends:dl,props:{position:{type:String,default:"bottom"},model:null,class:null,style:null,tooltipOptions:null,menuId:{type:String,default:null},tabindex:{type:Number,default:0},breakpoint:{type:String,default:"960px"},ariaLabel:{type:String,default:null},ariaLabelledby:{type:String,default:null}},style:af,provide:function(){return{$pcDock:this,$parentInstance:this}}};function bl(e){return Xf(e)||Uf(e)||Gf(e)||zf()}function zf(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
344
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Gf(e,t){if(e){if(typeof e=="string")return ia(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ia(e,t):void 0}}function Uf(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Xf(e){if(Array.isArray(e))return ia(e)}function ia(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,a=Array(t);n<t;n++)a[n]=e[n];return a}var Cl={name:"DockSub",hostName:"Dock",extends:dl,emits:["focus","blur"],props:{position:{type:String,default:"bottom"},model:{type:Array,default:null},templates:{type:null,default:null},tooltipOptions:null,menuId:{type:String,default:null},tabindex:{type:Number,default:0},ariaLabel:{type:String,default:null},ariaLabelledby:{type:String,default:null}},data:function(){return{id:this.menuId,currentIndex:-3,focused:!1,focusedOptionIndex:-1}},watch:{menuId:function(t){this.id=t||jt()}},mounted:function(){this.id=this.id||jt()},methods:{getItemId:function(t){return"".concat(this.id,"_").concat(t)},getItemProp:function(t,n){return t&&t.item?Ne(t.item[n]):void 0},getPTOptions:function(t,n,a){return this.ptm(t,{context:{index:a,item:n,active:this.isItemActive(this.getItemId(a))}})},isSameMenuItem:function(t){return t.currentTarget&&(t.currentTarget.isSameNode(t.target)||t.currentTarget.isSameNode(t.target.closest('[data-pc-section="item"]')))},isItemActive:function(t){return t===this.focusedOptionIndex},onListMouseLeave:function(){this.currentIndex=-3},onItemMouseEnter:function(t){this.currentIndex=t},onItemClick:function(t,n){if(this.isSameMenuItem(t)){var a=this.getItemProp(n,"command");a&&a({originalEvent:t,item:n.item})}},onListFocus:function(t){this.focused=!0,this.changeFocusedOptionIndex(0),this.$emit("focus",t)},onListBlur:function(t){this.focused=!1,this.focusedOptionIndex=-1,this.$emit("blur",t)},onListKeyDown:function(t){switch(t.code){case"ArrowDown":{(this.position==="left"||this.position==="right")&&this.onArrowDownKey(),t.preventDefault();break}case"ArrowUp":{(this.position==="left"||this.position==="right")&&this.onArrowUpKey(),t.preventDefault();break}case"ArrowRight":{(this.position==="top"||this.position==="bottom")&&this.onArrowDownKey(),t.preventDefault();break}case"ArrowLeft":{(this.position==="top"||this.position==="bottom")&&this.onArrowUpKey(),t.preventDefault();break}case"Home":{this.onHomeKey(),t.preventDefault();break}case"End":{this.onEndKey(),t.preventDefault();break}case"Enter":case"NumpadEnter":case"Space":{this.onSpaceKey(t),t.preventDefault();break}}},onArrowDownKey:function(){var t=this.findNextOptionIndex(this.focusedOptionIndex);this.changeFocusedOptionIndex(t)},onArrowUpKey:function(){var t=this.findPrevOptionIndex(this.focusedOptionIndex);this.changeFocusedOptionIndex(t)},onHomeKey:function(){this.changeFocusedOptionIndex(0)},onEndKey:function(){this.changeFocusedOptionIndex(_n(this.$refs.list,'li[data-pc-section="item"][data-p-disabled="false"]').length-1)},onSpaceKey:function(){var t=Dt(this.$refs.list,'li[id="'.concat("".concat(this.focusedOptionIndex),'"]')),n=t&&Dt(t,'[data-pc-section="itemlink"]');n?n.click():t&&t.click()},findNextOptionIndex:function(t){var n=_n(this.$refs.list,'li[data-pc-section="item"][data-p-disabled="false"]'),a=bl(n).findIndex(function(r){return r.id===t});return a>-1?a+1:0},findPrevOptionIndex:function(t){var n=_n(this.$refs.list,'li[data-pc-section="item"][data-p-disabled="false"]'),a=bl(n).findIndex(function(r){return r.id===t});return a>-1?a-1:0},changeFocusedOptionIndex:function(t){var n=_n(this.$refs.list,'li[data-pc-section="item"][data-p-disabled="false"]'),a=t>=n.length?n.length-1:t<0?0:t;this.focusedOptionIndex=n[a].getAttribute("id")},disabled:function(t){return typeof t.disabled=="function"?t.disabled():t.disabled},getMenuItemProps:function(t,n){return{action:o.mergeProps({tabindex:-1,class:this.cx("itemLink")},this.getPTOptions("itemLink",t,n)),icon:o.mergeProps({class:[this.cx("itemIcon"),t.icon]},this.getPTOptions("itemIcon",t,n))}}},computed:{focusedOptionId:function(){return this.focusedOptionIndex!==-1?this.focusedOptionIndex:null}},directives:{ripple:Rf,tooltip:Wf}},Jf=["id","aria-orientation","aria-activedescendant","tabindex","aria-label","aria-labelledby"],Qf=["id","aria-label","aria-disabled","onClick","onMouseenter","data-p-focused","data-p-disabled"],Kf=["href","target"];function _f(e,t,n,a,r,i){var l=o.resolveDirective("ripple"),s=o.resolveDirective("tooltip");return o.openBlock(),o.createElementBlock("div",o.mergeProps({class:e.cx("listContainer")},e.ptm("listContainer")),[o.createElementVNode("ul",o.mergeProps({ref:"list",id:r.id,class:e.cx("list"),role:"menu","aria-orientation":n.position==="bottom"||n.position==="top"?"horizontal":"vertical","aria-activedescendant":r.focused?i.focusedOptionId:void 0,tabindex:n.tabindex,"aria-label":n.ariaLabel,"aria-labelledby":n.ariaLabelledby,onFocus:t[0]||(t[0]=function(){return i.onListFocus&&i.onListFocus.apply(i,arguments)}),onBlur:t[1]||(t[1]=function(){return i.onListBlur&&i.onListBlur.apply(i,arguments)}),onKeydown:t[2]||(t[2]=function(){return i.onListKeyDown&&i.onListKeyDown.apply(i,arguments)}),onMouseleave:t[3]||(t[3]=function(){return i.onListMouseLeave&&i.onListMouseLeave.apply(i,arguments)})},e.ptm("list")),[(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(n.model,function(c,d){return o.openBlock(),o.createElementBlock("li",o.mergeProps({key:d,id:i.getItemId(d),class:e.cx("item",{processedItem:c,id:i.getItemId(d)}),role:"menuitem","aria-label":c.label,"aria-disabled":i.disabled(c),onClick:function(f){return i.onItemClick(f,c)},onMouseenter:function(f){return i.onItemMouseEnter(d)},ref_for:!0},i.getPTOptions("item",c,d),{"data-p-focused":i.isItemActive(i.getItemId(d)),"data-p-disabled":i.disabled(c)||!1}),[o.createElementVNode("div",o.mergeProps({class:e.cx("itemContent"),ref_for:!0},i.getPTOptions("itemContent",c,d)),[n.templates.item?(o.openBlock(),o.createBlock(o.resolveDynamicComponent(n.templates.item),{key:1,item:c,index:d,label:c.label,props:i.getMenuItemProps(c,d)},null,8,["item","index","label","props"])):o.withDirectives((o.openBlock(),o.createElementBlock("a",o.mergeProps({key:0,href:c.url,class:e.cx("itemLink"),target:c.target,tabindex:"-1","aria-hidden":"true",ref_for:!0},i.getPTOptions("itemLink",c,d)),[!n.templates.icon&&!n.templates.itemicon?o.withDirectives((o.openBlock(),o.createElementBlock("span",o.mergeProps({key:0,class:[e.cx("itemIcon"),c.icon],ref_for:!0},i.getPTOptions("itemIcon",c,d)),null,16)),[[l]]):(o.openBlock(),o.createBlock(o.resolveDynamicComponent(n.templates.icon||n.templates.itemicon),{key:1,item:c,class:o.normalizeClass(e.cx("itemIcon"))},null,8,["item","class"]))],16,Kf)),[[s,{value:c.label,disabled:!n.tooltipOptions},n.tooltipOptions]])],16)],16,Qf)}),128))],16,Jf)],16)}Cl.render=_f;var la={name:"Dock",extends:Yf,inheritAttrs:!1,matchMediaListener:null,data:function(){return{query:null,queryMatches:!1}},mounted:function(){this.bindMatchMediaListener()},beforeUnmount:function(){this.unbindMatchMediaListener()},methods:{bindMatchMediaListener:function(){var t=this;if(!this.matchMediaListener){var n=matchMedia("(max-width: ".concat(this.breakpoint,")"));this.query=n,this.queryMatches=n.matches,this.matchMediaListener=function(){t.queryMatches=n.matches,t.mobileActive=!1},this.query.addEventListener("change",this.matchMediaListener)}},unbindMatchMediaListener:function(){this.matchMediaListener&&(this.query.removeEventListener("change",this.matchMediaListener),this.matchMediaListener=null)}},computed:{containerClass:function(){return[this.class,this.cx("root")]}},components:{DockSub:Cl}};function qf(e,t,n,a,r,i){var l=o.resolveComponent("DockSub");return o.openBlock(),o.createElementBlock("div",o.mergeProps({class:i.containerClass,style:e.style},e.ptmi("root")),[o.createVNode(l,{model:e.model,templates:e.$slots,tooltipOptions:e.tooltipOptions,position:e.position,menuId:e.menuId,"aria-label":e.ariaLabel,"aria-labelledby":e.ariaLabelledby,tabindex:e.tabindex,pt:e.pt,unstyled:e.unstyled},null,8,["model","templates","tooltipOptions","position","menuId","aria-label","aria-labelledby","tabindex","pt","unstyled"])],16)}la.render=qf;function $f(e){let{rootEl:t,isSticky:n,layoutItemStyles:a}=e;const r=o.shallowRef(!1),i=o.shallowRef(0),l=o.computed(()=>{const d=typeof r.value=="boolean"?"top":r.value;return[n.value?{top:"auto",bottom:"auto",height:void 0}:void 0,r.value?{[d]:F(i.value)}:{top:a.value.top}]});o.onMounted(()=>{o.watch(n,d=>{d?window.addEventListener("scroll",c,{passive:!0}):window.removeEventListener("scroll",c)},{immediate:!0})}),o.onBeforeUnmount(()=>{window.removeEventListener("scroll",c)});let s=0;function c(){const d=s>window.scrollY?"up":"down",u=t.value.getBoundingClientRect(),f=parseFloat(a.value.top??0),g=window.scrollY-Math.max(0,i.value-f),h=u.height+Math.max(i.value,f)-window.scrollY-window.innerHeight,m=parseFloat(getComputedStyle(t.value).getPropertyValue("--v-body-scroll-y"))||0;u.height<window.innerHeight-f?(r.value="top",i.value=f):d==="up"&&r.value==="bottom"||d==="down"&&r.value==="top"?(i.value=window.scrollY+u.top-m,r.value=!0):d==="down"&&h<=0?(i.value=0,r.value="bottom"):d==="up"&&g<=0&&(m?r.value!=="top"&&(i.value=-g+m+f,r.value="top"):(i.value=u.top+g,r.value="top")),s=window.scrollY}return{isStuck:r,stickyStyles:l}}const eg=100,tg=20;function Al(e){return(e<0?-1:1)*Math.sqrt(Math.abs(e))*1.41421356237}function wl(e){if(e.length<2)return 0;if(e.length===2)return e[1].t===e[0].t?0:(e[1].d-e[0].d)/(e[1].t-e[0].t);let t=0;for(let n=e.length-1;n>0;n--){if(e[n].t===e[n-1].t)continue;const a=Al(t),r=(e[n].d-e[n-1].d)/(e[n].t-e[n-1].t);t+=(r-a)*Math.abs(r),n===e.length-1&&(t*=.5)}return Al(t)*1e3}function ng(){const e={};function t(r){Array.from(r.changedTouches).forEach(i=>{(e[i.identifier]??(e[i.identifier]=new Zl(tg))).push([r.timeStamp,i])})}function n(r){Array.from(r.changedTouches).forEach(i=>{delete e[i.identifier]})}function a(r){const i=e[r]?.values().reverse();if(!i)throw new Error(`No samples for touch id ${r}`);const l=i[0],s=[],c=[];for(const d of i){if(l[0]-d[0]>eg)break;s.push({t:d[0],d:d[1].clientX}),c.push({t:d[0],d:d[1].clientY})}return{x:wl(s),y:wl(c),get direction(){const{x:d,y:u}=this,[f,g]=[Math.abs(d),Math.abs(u)];return f>g&&d>=0?"right":f>g&&d<=0?"left":g>f&&u>=0?"down":g>f&&u<=0?"up":og()}}}return{addMovement:t,endTouch:n,getVelocity:a}}function og(){throw new Error}function ag(e){let{el:t,isActive:n,isTemporary:a,width:r,touchless:i,position:l}=e;o.onMounted(()=>{window.addEventListener("touchstart",b,{passive:!0}),window.addEventListener("touchmove",p,{passive:!1}),window.addEventListener("touchend",A,{passive:!0})}),o.onBeforeUnmount(()=>{window.removeEventListener("touchstart",b),window.removeEventListener("touchmove",p),window.removeEventListener("touchend",A)});const s=o.computed(()=>["left","right"].includes(l.value)),{addMovement:c,endTouch:d,getVelocity:u}=ng();let f=!1;const g=o.shallowRef(!1),h=o.shallowRef(0),m=o.shallowRef(0);let v;function y(V,k){return(l.value==="left"?V:l.value==="right"?document.documentElement.clientWidth-V:l.value==="top"?V:l.value==="bottom"?document.documentElement.clientHeight-V:Lt())-(k?r.value:0)}function C(V){let k=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;const w=l.value==="left"?(V-m.value)/r.value:l.value==="right"?(document.documentElement.clientWidth-V-m.value)/r.value:l.value==="top"?(V-m.value)/r.value:l.value==="bottom"?(document.documentElement.clientHeight-V-m.value)/r.value:Lt();return k?Math.max(0,Math.min(1,w)):w}function b(V){if(i.value)return;const k=V.changedTouches[0].clientX,w=V.changedTouches[0].clientY,O=25,L=l.value==="left"?k<O:l.value==="right"?k>document.documentElement.clientWidth-O:l.value==="top"?w<O:l.value==="bottom"?w>document.documentElement.clientHeight-O:Lt(),T=n.value&&(l.value==="left"?k<r.value:l.value==="right"?k>document.documentElement.clientWidth-r.value:l.value==="top"?w<r.value:l.value==="bottom"?w>document.documentElement.clientHeight-r.value:Lt());(L||T||n.value&&a.value)&&(v=[k,w],m.value=y(s.value?k:w,n.value),h.value=C(s.value?k:w),f=m.value>-20&&m.value<80,d(V),c(V))}function p(V){const k=V.changedTouches[0].clientX,w=V.changedTouches[0].clientY;if(f){if(!V.cancelable){f=!1;return}const L=Math.abs(k-v[0]),T=Math.abs(w-v[1]);(s.value?L>T&&L>3:T>L&&T>3)?(g.value=!0,f=!1):(s.value?T:L)>3&&(f=!1)}if(!g.value)return;V.preventDefault(),c(V);const O=C(s.value?k:w,!1);h.value=Math.max(0,Math.min(1,O)),O>1?m.value=y(s.value?k:w,!0):O<0&&(m.value=y(s.value?k:w,!1))}function A(V){if(f=!1,!g.value)return;c(V),g.value=!1;const k=u(V.changedTouches[0].identifier),w=Math.abs(k.x),O=Math.abs(k.y);(s.value?w>O&&w>400:O>w&&O>3)?n.value=k.direction===({left:"right",right:"left",top:"down",bottom:"up"}[l.value]||Lt()):n.value=h.value>.5}const S=o.computed(()=>g.value?{transform:l.value==="left"?`translateX(calc(-100% + ${h.value*r.value}px))`:l.value==="right"?`translateX(calc(100% - ${h.value*r.value}px))`:l.value==="top"?`translateY(calc(-100% + ${h.value*r.value}px))`:l.value==="bottom"?`translateY(calc(100% - ${h.value*r.value}px))`:Lt(),transition:"none"}:void 0);return We(g,()=>{const V=t.value?.style.transform??null,k=t.value?.style.transition??null;o.watchEffect(()=>{t.value?.style.setProperty("transform",S.value?.transform||"none"),t.value?.style.setProperty("transition",S.value?.transition||null)}),o.onScopeDispose(()=>{t.value?.style.setProperty("transform",V),t.value?.style.setProperty("transition",k)})}),{isDragging:g,dragProgress:h,dragStyles:S}}function Lt(){throw new Error}const rg=["start","end","left","right","top","bottom"],ig=N({color:String,disableResizeWatcher:Boolean,disableRouteWatcher:Boolean,expandOnHover:Boolean,floating:Boolean,modelValue:{type:Boolean,default:null},permanent:Boolean,rail:{type:Boolean,default:null},railWidth:{type:[Number,String],default:56},scrim:{type:[Boolean,String],default:!0},image:String,temporary:Boolean,persistent:Boolean,touchless:Boolean,width:{type:[Number,String],default:256},location:{type:String,default:"start",validator:e=>rg.includes(e)},sticky:Boolean,...Xe(),...X(),...Lo(),...cr({mobile:null}),...Re(),...Uo(),...pe(),..._({tag:"nav"}),...de()},"VNavigationDrawer"),Sl=j()({name:"VNavigationDrawer",props:ig(),emits:{"update:modelValue":e=>!0,"update:rail":e=>!0},setup(e,t){let{attrs:n,emit:a,slots:r}=t;const{isRtl:i}=Pe(),{themeClasses:l}=ge(e),{borderClasses:s}=Je(e),{backgroundColorClasses:c,backgroundColorStyles:d}=Ae(o.toRef(e,"color")),{elevationClasses:u}=Ze(e),{displayClasses:f,mobile:g}=To(e),{roundedClasses:h}=we(e),m=qa(),v=be(e,"modelValue",null,R=>!!R),{ssrBootStyles:y}=ln(),{scopeId:C}=Tt(),b=o.ref(),p=o.shallowRef(!1),{runOpenDelay:A,runCloseDelay:S}=Mo(e,R=>{p.value=R}),V=o.computed(()=>e.rail&&e.expandOnHover&&p.value?Number(e.width):Number(e.rail?e.railWidth:e.width)),k=o.computed(()=>co(e.location,i.value)),w=o.computed(()=>e.persistent),O=o.computed(()=>!e.permanent&&(g.value||e.temporary)),L=o.computed(()=>e.sticky&&!O.value&&k.value!=="bottom");We(()=>e.expandOnHover&&e.rail!=null,()=>{o.watch(p,R=>a("update:rail",!R))}),We(()=>!e.disableResizeWatcher,()=>{o.watch(O,R=>!e.permanent&&o.nextTick(()=>v.value=!R))}),We(()=>!e.disableRouteWatcher&&!!m,()=>{o.watch(m.currentRoute,()=>O.value&&(v.value=!1))}),o.watch(()=>e.permanent,R=>{R&&(v.value=!0)}),e.modelValue==null&&!O.value&&(v.value=e.permanent||!g.value);const{isDragging:T,dragProgress:x}=ag({el:b,isActive:v,isTemporary:O,width:V,touchless:o.toRef(e,"touchless"),position:k}),I=o.computed(()=>{const R=O.value?0:e.rail&&e.expandOnHover?Number(e.railWidth):V.value;return T.value?R*x.value:R}),B=o.computed(()=>["top","bottom"].includes(e.location)?0:V.value),{layoutItemStyles:D,layoutItemScrimStyles:M}=Xo({id:e.name,order:o.computed(()=>parseInt(e.order,10)),position:k,layoutSize:I,elementSize:B,active:o.computed(()=>v.value||T.value),disableTransitions:o.computed(()=>T.value),absolute:o.computed(()=>e.absolute||L.value&&typeof z.value!="string")}),{isStuck:z,stickyStyles:W}=$f({rootEl:b,isSticky:L,layoutItemStyles:D}),K=Ae(o.computed(()=>typeof e.scrim=="string"?e.scrim:null)),E=o.computed(()=>({...T.value?{opacity:x.value*.2,transition:"none"}:void 0,...M.value}));return tt({VList:{bgColor:"transparent"}}),Z(()=>{const R=r.image||e.image;return o.createVNode(o.Fragment,null,[o.createVNode(e.tag,o.mergeProps({ref:b,onMouseenter:A,onMouseleave:S,class:["v-navigation-drawer",`v-navigation-drawer--${k.value}`,{"v-navigation-drawer--expand-on-hover":e.expandOnHover,"v-navigation-drawer--floating":e.floating,"v-navigation-drawer--is-hovering":p.value,"v-navigation-drawer--rail":e.rail,"v-navigation-drawer--temporary":O.value,"v-navigation-drawer--persistent":w.value,"v-navigation-drawer--active":v.value,"v-navigation-drawer--sticky":L.value},l.value,c.value,s.value,f.value,u.value,h.value,e.class],style:[d.value,D.value,y.value,W.value,e.style,["top","bottom"].includes(k.value)?{height:"auto"}:{}]},C,n),{default:()=>[R&&o.createVNode("div",{key:"image",class:"v-navigation-drawer__img"},[r.image?o.createVNode(se,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{alt:"",cover:!0,height:"inherit",src:e.image}}},r.image):o.createVNode(vt,{key:"image-img",alt:"",cover:!0,height:"inherit",src:e.image},null)]),r.prepend&&o.createVNode("div",{class:"v-navigation-drawer__prepend"},[r.prepend?.()]),o.createVNode("div",{class:"v-navigation-drawer__content"},[r.default?.()]),r.append&&o.createVNode("div",{class:"v-navigation-drawer__append"},[r.append?.()])]}),o.createVNode(o.Transition,{name:"fade-transition"},{default:()=>[O.value&&(T.value||v.value)&&!!e.scrim&&o.createVNode("div",o.mergeProps({class:["v-navigation-drawer__scrim",K.backgroundColorClasses.value],style:[E.value,K.backgroundColorStyles.value],onClick:()=>{w.value||(v.value=!1)}},C),null)]})])}),{isStuck:z}}}),lg={class:"text-center"},sg={key:0},cg={key:1,style:{position:"fixed",bottom:"0",left:"0"}},Vl=o.defineComponent({__name:"FloatMenu",setup(e){const{mobile:t}=ie.useDisplay(),n=fe(),a=ie.useTheme(),r=ft.useRouter(),i=Cn(),l=ve(),s=d=>{if(n.setCurrentSubHdr(d.label),n.execAction(d,i.eventMap),!d.children){n.setActiveMenuVal(d.key),r.push(d.link),n.setFloatMenu(!1);return}n.setActiveMenu(d),d.link&&r.push(d.link)},c=d=>{if(d.key==="c-0"){n.setFloatMenu(!0);return}if(d.key==="c-1"){n.setDockVisible(!1);return}if(n.setCurrentSubHdr(d.label),n.execAction(d,i.eventMap),n.setActiveMenuVal(d.key),d.link){if(d.link.includes("http")){window.open(d.link,"_blank");return}r.push(d.link)}n.setActiveMenu(d)};return(d,u)=>(o.openBlock(),o.createElementBlock(o.Fragment,null,[o.createVNode(hi,{modelValue:o.unref(n).floatMenu,"onUpdate:modelValue":u[1]||(u[1]=f=>o.unref(n).floatMenu=f),id:"floatContainer",fullscreen:o.unref(t),width:"100%","location-strategy":"static",height:"60vh",transition:"dialog-bottom-transition"},{default:o.withCtx(()=>[o.createVNode(Ye,{class:o.normalizeClass(["mx-auto dock-window",[o.unref(a).current.value.dark?"dark":"light",o.unref(t)?"":"rounded-xl"]])},{default:o.withCtx(()=>[o.createVNode(ee,null,{append:o.withCtx(()=>[o.unref(l).isAuthenticated()?(o.openBlock(),o.createBlock(Pt,{key:0})):(o.openBlock(),o.createBlock(ne,{key:1,to:"/login",color:"info","prepend-icon":"mdi-login"},{default:o.withCtx(()=>u[4]||(u[4]=[o.createTextVNode("Sign In")])),_:1})),o.createVNode(ne,{icon:"mdi-close",onClick:u[0]||(u[0]=o.withModifiers(f=>o.unref(n).setFloatMenu(!1),["stop"])),title:"Close"})]),_:1}),o.createVNode(Le,{class:"mx-auto"},{default:o.withCtx(()=>[o.createVNode(vt,{src:o.unref(a).current.value.dark?o.unref(vi):o.unref(yi),height:"50px",width:"350px",class:o.normalizeClass(o.unref(a).current.value.dark?"":"image-remove-bg")},null,8,["src","class"])]),_:1}),o.createVNode(Wa,{class:"mx-auto"},{default:o.withCtx(()=>[o.createVNode(Oe,null,{default:o.withCtx(()=>[o.createVNode(Te,null,{default:o.withCtx(()=>[o.createElementVNode("div",lg,[o.createElementVNode("div",{class:o.normalizeClass(["title text-h5",`text-black-${o.unref(a).current.value.dark?"darken":"lighten"}-2`])},o.toDisplayString(o.unref(n).currentPageHeader)+" - "+o.toDisplayString(o.unref(n).currentSubHdr),3)])]),_:1})]),_:1})]),_:1}),o.createVNode(at,null,{default:o.withCtx(()=>[o.createVNode(xo,{fluid:"",class:o.normalizeClass(o.unref(t)?"ms-10":"")},{default:o.withCtx(()=>[o.createVNode(Oe,{class:"justify-end align-end","no-gutters":""},{default:o.withCtx(()=>[(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(o.unref(n).activeMenu,f=>(o.openBlock(),o.createBlock(Te,{key:f.key},{default:o.withCtx(()=>[o.createVNode(zn,{link:f.link||"",disabled:f.disabled,"badge-color":f.badgeColor,"badge-content":o.unref(n).getBadgeContent(f),label:f.label,icon:o.unref(n).renderIcon(f),active:f.active,onLinkClicked:g=>s(f),"sub-menu":f.childDropdown?f.children:[]},null,8,["link","disabled","badge-color","badge-content","label","icon","active","onLinkClicked","sub-menu"])]),_:2},1024))),128))]),_:1})]),_:1},8,["class"])]),_:1})]),_:1},8,["class"])]),_:1},8,["modelValue","fullscreen"]),o.unref(t)?(o.openBlock(),o.createElementBlock("div",cg,[o.withDirectives(o.createVNode(ne,{variant:"elevated",class:"square-button ma-1",icon:"mdi-dots-grid",color:`amber-${o.unref(a).current.value.dark?"darken":"lighten"}-2`,onClick:u[3]||(u[3]=o.withModifiers(f=>o.unref(n).setFloatMenu(!0),["stop"])),"active-color":`amber-${o.unref(a).current.value.dark?"darken":"lighten"}-2`},null,8,["color","active-color"]),[[Ke,"Show Navigation Bar",void 0,{top:!0}]])])):(o.openBlock(),o.createElementBlock("div",sg,[o.unref(n).dockPosition!=="bottom"?(o.openBlock(),o.createBlock(Sl,{key:0,class:"bg-transparent",modelValue:o.unref(n).dockVisible,"onUpdate:modelValue":u[2]||(u[2]=f=>o.unref(n).dockVisible=f),rail:!0,"rail-width":"70",floating:"",location:o.unref(n).dockPosition},{default:o.withCtx(()=>[o.unref(n).dockVisible?(o.openBlock(),o.createBlock(o.unref(la),{key:0,model:[o.unref(i).launcher,...o.unref(n).activeMenu,o.unref(i).toggleDock],position:o.unref(n).dockPosition,class:o.normalizeClass(o.unref(n).dockPosition==="bottom"?"bottom":"")},{itemicon:o.withCtx(({item:f})=>[o.withDirectives(o.createVNode(ne,{class:"square-button",icon:o.unref(n).renderIcon(f),color:`${f.buttonColor}-${o.unref(a).current.value.dark?"darken":"lighten"}-2`,onClick:o.withModifiers(g=>c(f),["stop"]),"active-color":`amber-${o.unref(a).current.value.dark?"darken":"lighten"}-2`,active:f.active},null,8,["icon","color","onClick","active-color","active"]),[[Ke,f.label,void 0,{top:!0}]])]),_:1},8,["model","position","class"])):o.createCommentVNode("",!0)]),_:1},8,["modelValue","location"])):o.createCommentVNode("",!0),o.unref(n).dockVisible&&o.unref(n).dockPosition==="bottom"?(o.openBlock(),o.createBlock(o.unref(la),{key:1,style:{position:"fixed",height:"56px",width:"100%",margin:"0",left:"0",bottom:"0"},model:[o.unref(i).launcher,...o.unref(n).activeMenu,o.unref(i).toggleDock],position:o.unref(n).dockPosition,class:o.normalizeClass(o.unref(n).dockPosition==="bottom"?"bottom":"")},{itemicon:o.withCtx(({item:f})=>[o.withDirectives(o.createVNode(ne,{class:"square-button",icon:o.unref(n).renderIcon(f),color:`${f.buttonColor}-${o.unref(a).current.value.dark?"darken":"lighten"}-2`,onClick:o.withModifiers(g=>c(f),["stop"]),"active-color":`amber-${o.unref(a).current.value.dark?"darken":"lighten"}-2`,active:f.active},null,8,["icon","color","onClick","active-color","active"]),[[Ke,f.label,void 0,{top:!0}]])]),_:1},8,["model","position","class"])):o.createCommentVNode("",!0)]))],64))}}),kl=o.defineComponent({__name:"FloatingLayout",setup(e){const{mobile:t}=ie.useDisplay(),n=fe(),a=ie.useTheme();return o.onMounted(()=>{a.current.value.dark&&n.currentTheme==="light"&&(a.global.name.value="light")}),(r,i)=>(o.openBlock(),o.createElementBlock(o.Fragment,null,[o.createVNode(Vl),o.createVNode(_o,null,{default:o.withCtx(()=>[o.renderSlot(r.$slots,"default")]),_:3}),o.unref(t)?o.createCommentVNode("",!0):(o.openBlock(),o.createBlock(Ot,{key:0}))],64))}}),dg=Object.freeze(Object.defineProperty({__proto__:null,default:kl},Symbol.toStringTag,{value:"Module"})),Cn=()=>({eventMap:{toggleTheme:()=>{fe().toggleTheme()}},launcher:{label:"Launcher",key:"c-0",icon:"mdi-dots-grid",disabled:!1,buttonColor:"purple",link:"/",active:!0,children:[]},toggleDock:{label:"Hide/Show Dock",key:"c-1",icon:"mdi-eye-off",disabled:!1,buttonColor:"purple",link:"/",active:!0,children:[]},registerLayouts:r=>{const i=Object.assign({"../layouts/AppLayout.vue":Jd,"../layouts/DefaultLayout.vue":gu,"../layouts/FixedLayout.vue":Pl,"../layouts/FloatingLayout.vue":dg,"../layouts/UcsdFooter.vue":Xd,"../layouts/UcsdHeader.vue":zd,"../layouts/UserPanel.vue":kd});for(const l in i){const s=i[l],c=l.split("/").pop()?.replace(".vue","");c&&c.endsWith("Layout")&&(console.log(l),r.component(c,s.default))}fe().init()}}),ug={key:0},sa=o.defineComponent({__name:"RailMenu",props:{layout:{type:String,required:!1},toggleNav:{type:Boolean,required:!1}},emits:["linkClicked"],setup(e,{emit:t}){const{mobile:n}=ie.useDisplay(),a=ft.useRouter(),r=fe(),i=ie.useTheme(),l=Cn(),s=ve(),c=t,d=f=>r.layoutRail?"":f.split("-").length===3?"ms-5":f.split("-").length>3?"ms-10":"",u=f=>{if(r.execAction(f,l.eventMap),!f.children){if(r.setActiveMenuVal(f.key),r.setLayoutRail(!0),f.link){if(f.link.includes("http")){window.open(f.link,"_blank");return}a.push(f.link)}return}r.setActiveMenu(f),c("linkClicked")};return(f,g)=>(o.openBlock(),o.createBlock(Sl,{floating:"",width:"300",temporary:o.unref(n),modelValue:o.unref(r).navDrawer,"onUpdate:modelValue":g[2]||(g[2]=h=>o.unref(r).navDrawer=h),"rail-width":"60",class:o.normalizeClass(`bg-grey-${o.unref(i).current.value.dark?"darken":"lighten"}-4`),rail:o.unref(r).layoutRail,onClick:g[3]||(g[3]=h=>o.unref(r).setLayoutRail(!1))},o.createSlots({default:o.withCtx(()=>[o.createVNode(pt,{class:"pa-2 ma-0",activatable:!0},{default:o.withCtx(()=>[o.createVNode(ee,{nav:""},{prepend:o.withCtx(()=>[o.withDirectives(o.createVNode(ne,{class:"square-button",size:"small",icon:o.unref(r).layoutRail?"mdi-chevron-right":"mdi-chevron-left",color:`amber-${o.unref(i).current.value.dark?"darken":"lighten"}-2`,onClick:g[0]||(g[0]=o.withModifiers(h=>o.unref(r).setLayoutRail(!o.unref(r).layoutRail),["stop"]))},null,8,["icon","color"]),[[Ke,"Expand/Collapse",void 0,{top:!0}]])]),_:1}),o.createVNode(ee,{nav:""},{prepend:o.withCtx(()=>[o.withDirectives(o.createVNode(ne,{class:"square-button",icon:"mdi-eye-off",color:`amber-${o.unref(i).current.value.dark?"darken":"lighten"}-2`,onClick:g[1]||(g[1]=o.withModifiers(h=>o.unref(r).setNavDrawer(!1),["stop"]))},null,8,["color"]),[[Ke,"Hide Navigation Bar",void 0,{top:!0}]])]),_:1}),o.createVNode(Wn),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(o.unref(r).activeMenu,h=>(o.openBlock(),o.createBlock(ee,{nav:"",key:h.key,active:o.unref(r).activeMenuVal===h.key},o.createSlots({prepend:o.withCtx(()=>[o.withDirectives(o.createVNode(ne,{class:o.normalizeClass(["square-button",d(h.key)]),icon:o.unref(r).renderIcon(h),color:`${h.buttonColor}-${o.unref(i).current.value.dark?"darken":"lighten"}-2`,onClick:o.withModifiers(m=>u(h),["stop"]),"active-color":`amber-${o.unref(i).current.value.dark?"darken":"lighten"}-2`,active:h.active},null,8,["class","icon","color","onClick","active-color","active"]),[[Ke,h.label,void 0,{top:!0}]])]),_:2},[h.badgeContent&&!o.unref(r).layoutRail?{name:"append",fn:o.withCtx(()=>[o.createVNode(an,{color:h.badgeColor,content:h.badgeContent(),inline:""},null,8,["color","content"])]),key:"0"}:void 0,o.unref(r).layoutRail?void 0:{name:"default",fn:o.withCtx(()=>[o.createVNode(ee,{class:"text-body-2 ms-5",onClick:o.withModifiers(m=>u(h),["stop"])},{default:o.withCtx(()=>[o.createTextVNode(o.toDisplayString(h.label),1)]),_:2},1032,["onClick"])]),key:"1"}]),1032,["active"]))),128))]),_:1}),o.unref(n)?(o.openBlock(),o.createElementBlock("span",ug,[o.unref(s).isAuthenticated()?(o.openBlock(),o.createBlock(Pt,{key:0})):o.withDirectives((o.openBlock(),o.createBlock(ne,{key:1,class:"square-button",size:"small",icon:"mdi-login",color:`amber-${o.unref(i).current.value.dark?"darken":"lighten"}-2`,to:"/login"},null,8,["color"])),[[Ke,"Sign In",void 0,{top:!0}]])])):o.createCommentVNode("",!0)]),_:2},[o.unref(n)&&!o.unref(r).layoutRail?{name:"append",fn:o.withCtx(()=>[o.createVNode(Ot)]),key:"0"}:void 0]),1032,["temporary","modelValue","class","rail"]))}}),Il=o.defineComponent({__name:"FixedLayout",props:{pageHeader:{type:String,required:!1},pageSubHeader:{type:String,required:!1}},setup(e){const t=fe(),{mobile:n}=ie.useDisplay(),a=ie.useTheme();return o.onMounted(()=>{a.current.value.dark&&t.currentTheme==="light"&&(a.global.name.value="light")}),(r,i)=>(o.openBlock(),o.createElementBlock(o.Fragment,null,[o.createVNode(Gn,{"header-sub-title":e.pageSubHeader,"header-title":e.pageHeader},null,8,["header-sub-title","header-title"]),o.createVNode(sa,{layout:"Fixed","toggle-nav":!0}),o.createVNode(_o,null,{default:o.withCtx(()=>[o.renderSlot(r.$slots,"default")]),_:3}),o.unref(n)?o.createCommentVNode("",!0):(o.openBlock(),o.createBlock(Ot,{key:0}))],64))}}),fg=Cn(),gg={install(e,t){e.provide("ucsdAppConfig",t.ucsdAppConfig),fg.registerLayouts(e),typeof t.ucsdAppConfig.initCallback=="function"&&t.ucsdAppConfig.initCallback(),console.log("UCSD Plugin initialized with config:",t.ucsdAppConfig)}},mg=[{path:"/login",name:"Login",component:Sr},{path:"/login-success",name:"LoginSuccess",component:Vr},{path:"/logout",name:"Logout",component:Mr},{path:"/unauthorized",name:"Unauthorized",component:Jr}],hg=e=>{e.beforeEach(async(t,n,a)=>{const r=ve();if(t.matched.some(s=>s.meta.requiresAuth)&&!r.isAuthenticated())return r.preAuthRoute=t.path,console.log("User not authenticated. Redirecting to login..."),a({name:"Login"});const i=t.meta?.roles,l=r.getRoleAssignedToUser();if(i&&!i.some(s=>l.includes(s)))return a({path:"/unauthorized"});a()})},Nl=eo.defineStore("its-audit",()=>{const e=o.ref({audits:new Array}),t=()=>{e.value.audits.splice(0,e.value.audits.length)},n=l=>{const s=[];let c=0;const d=u=>{let f=[];for(let g=0;g<u.length;g++){if(g%5){const h={op:l.op,path:l.path,oldKeyValues:f};s.push({detailKey:"ad-"+c++,detailValue:JSON.stringify(h)}),f=[]}f.push({key:u[g].key,value:u[g].value})}if(f.length>0){const g={op:l.op,path:l.path,oldKeyValues:f};s.push({detailKey:"ad-"+c++,detailValue:JSON.stringify(g)})}};return typeof l.oldKeyValues<"u"&&d(l.oldKeyValues),typeof l.newKeyValues<"u"&&d(l.newKeyValues),s};return{auditQueue:e,addToAuditQueue:(l,s,c)=>{l.details=[{detailKey:"userInfo",detailValue:JSON.stringify(ve().userInfo())}].concat(s),c.length>0&&c.forEach((d,u)=>{const f=JSON.stringify(d);if(f.length>1e3){const g=n(d);l.details?.push(...g)}else l.details?.push({detailKey:"ad-"+u,detailValue:f})}),e.value.audits.push(l)},postAudit:async()=>{let l=0;for(const s of e.value.audits)s.dateCreated=At().getTimeStamp(),s.auditId=Date.now()+l++},getAuditQueue:(l,s)=>{const c=[];return e.value.audits.forEach(d=>{d.details?.forEach(u=>{l&&u.detailKey===l&&c.push(d),s&&u.detailKey==="userInfo"&&u.detailValue.includes(s)&&c.push(d)})}),c},resetAuditQueue:t}},{persist:[{storage:sessionStorage,pick:["auditQueue"]}]}),vg=()=>{const e=At(),t=Nl();let n={};const a=s=>{Object.entries(s).forEach(([c,d])=>{console.log(`Key: ${c}, Value: ${d}`)})};return{trackChanges:(s,c)=>{if(c){n={};return}n=e.deepClone(s)},commitChanges:(s,c,d,u,f)=>{c.event=c.event+"-"+u,console.log("Old Value:"),a(n),console.log("New Value:"),a(s),console.log("Differences");let g=[];u==="update"&&(g=e.compareObjects(n,s));const h=[];if(g.forEach(m=>{u==="update"&&h.push({op:u,path:m.path,oldValue:m.value1,newValue:m.value2}),console.log(`Difference at "${m.path}": Old = ${m.value1}, New = ${m.value2}`)}),n=e.deepClone(s),u==="new"||u==="delete"){const m=[];for(const y in s)if(Object.prototype.hasOwnProperty.call(s,y)){if(u==="new"&&f.length>0&&!f.includes(y))continue;m.push({key:y,value:s[y]})}const v={op:u,path:"/"};u==="delete"?v.oldKeyValues=m:v.newKeyValues=m,h.push(v)}if(h.length>0){let m={};c.eventIcon!==""&&(m.icon=c.eventIcon),c.eventColor!==""&&(m.color=c.eventColor),s.hasOwnProperty("id")&&(m.id=s.id),Object.keys(m).length===0&&(m.id=d);const v=JSON.stringify(m),y=[{detailKey:d,detailValue:v}];t.addToAuditQueue(c,y,h),t.postAudit().then(C=>{console.log(C)})}console.log(JSON.stringify(c))},mapAuditToTimeLine:s=>{const c=(f,g)=>{let h="",m=g==="old"?"old-data":"";if(f.hasOwnProperty(g+"KeyValues")){h+="<div>"+e.getLastPath(f.path)+`</div>
344
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Gf(e,t){if(e){if(typeof e=="string")return ia(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?ia(e,t):void 0}}function Uf(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Xf(e){if(Array.isArray(e))return ia(e)}function ia(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,a=Array(t);n<t;n++)a[n]=e[n];return a}var Cl={name:"DockSub",hostName:"Dock",extends:dl,emits:["focus","blur"],props:{position:{type:String,default:"bottom"},model:{type:Array,default:null},templates:{type:null,default:null},tooltipOptions:null,menuId:{type:String,default:null},tabindex:{type:Number,default:0},ariaLabel:{type:String,default:null},ariaLabelledby:{type:String,default:null}},data:function(){return{id:this.menuId,currentIndex:-3,focused:!1,focusedOptionIndex:-1}},watch:{menuId:function(t){this.id=t||jt()}},mounted:function(){this.id=this.id||jt()},methods:{getItemId:function(t){return"".concat(this.id,"_").concat(t)},getItemProp:function(t,n){return t&&t.item?Ne(t.item[n]):void 0},getPTOptions:function(t,n,a){return this.ptm(t,{context:{index:a,item:n,active:this.isItemActive(this.getItemId(a))}})},isSameMenuItem:function(t){return t.currentTarget&&(t.currentTarget.isSameNode(t.target)||t.currentTarget.isSameNode(t.target.closest('[data-pc-section="item"]')))},isItemActive:function(t){return t===this.focusedOptionIndex},onListMouseLeave:function(){this.currentIndex=-3},onItemMouseEnter:function(t){this.currentIndex=t},onItemClick:function(t,n){if(this.isSameMenuItem(t)){var a=this.getItemProp(n,"command");a&&a({originalEvent:t,item:n.item})}},onListFocus:function(t){this.focused=!0,this.changeFocusedOptionIndex(0),this.$emit("focus",t)},onListBlur:function(t){this.focused=!1,this.focusedOptionIndex=-1,this.$emit("blur",t)},onListKeyDown:function(t){switch(t.code){case"ArrowDown":{(this.position==="left"||this.position==="right")&&this.onArrowDownKey(),t.preventDefault();break}case"ArrowUp":{(this.position==="left"||this.position==="right")&&this.onArrowUpKey(),t.preventDefault();break}case"ArrowRight":{(this.position==="top"||this.position==="bottom")&&this.onArrowDownKey(),t.preventDefault();break}case"ArrowLeft":{(this.position==="top"||this.position==="bottom")&&this.onArrowUpKey(),t.preventDefault();break}case"Home":{this.onHomeKey(),t.preventDefault();break}case"End":{this.onEndKey(),t.preventDefault();break}case"Enter":case"NumpadEnter":case"Space":{this.onSpaceKey(t),t.preventDefault();break}}},onArrowDownKey:function(){var t=this.findNextOptionIndex(this.focusedOptionIndex);this.changeFocusedOptionIndex(t)},onArrowUpKey:function(){var t=this.findPrevOptionIndex(this.focusedOptionIndex);this.changeFocusedOptionIndex(t)},onHomeKey:function(){this.changeFocusedOptionIndex(0)},onEndKey:function(){this.changeFocusedOptionIndex(_n(this.$refs.list,'li[data-pc-section="item"][data-p-disabled="false"]').length-1)},onSpaceKey:function(){var t=Dt(this.$refs.list,'li[id="'.concat("".concat(this.focusedOptionIndex),'"]')),n=t&&Dt(t,'[data-pc-section="itemlink"]');n?n.click():t&&t.click()},findNextOptionIndex:function(t){var n=_n(this.$refs.list,'li[data-pc-section="item"][data-p-disabled="false"]'),a=bl(n).findIndex(function(r){return r.id===t});return a>-1?a+1:0},findPrevOptionIndex:function(t){var n=_n(this.$refs.list,'li[data-pc-section="item"][data-p-disabled="false"]'),a=bl(n).findIndex(function(r){return r.id===t});return a>-1?a-1:0},changeFocusedOptionIndex:function(t){var n=_n(this.$refs.list,'li[data-pc-section="item"][data-p-disabled="false"]'),a=t>=n.length?n.length-1:t<0?0:t;this.focusedOptionIndex=n[a].getAttribute("id")},disabled:function(t){return typeof t.disabled=="function"?t.disabled():t.disabled},getMenuItemProps:function(t,n){return{action:o.mergeProps({tabindex:-1,class:this.cx("itemLink")},this.getPTOptions("itemLink",t,n)),icon:o.mergeProps({class:[this.cx("itemIcon"),t.icon]},this.getPTOptions("itemIcon",t,n))}}},computed:{focusedOptionId:function(){return this.focusedOptionIndex!==-1?this.focusedOptionIndex:null}},directives:{ripple:Rf,tooltip:Wf}},Jf=["id","aria-orientation","aria-activedescendant","tabindex","aria-label","aria-labelledby"],Qf=["id","aria-label","aria-disabled","onClick","onMouseenter","data-p-focused","data-p-disabled"],Kf=["href","target"];function _f(e,t,n,a,r,i){var l=o.resolveDirective("ripple"),s=o.resolveDirective("tooltip");return o.openBlock(),o.createElementBlock("div",o.mergeProps({class:e.cx("listContainer")},e.ptm("listContainer")),[o.createElementVNode("ul",o.mergeProps({ref:"list",id:r.id,class:e.cx("list"),role:"menu","aria-orientation":n.position==="bottom"||n.position==="top"?"horizontal":"vertical","aria-activedescendant":r.focused?i.focusedOptionId:void 0,tabindex:n.tabindex,"aria-label":n.ariaLabel,"aria-labelledby":n.ariaLabelledby,onFocus:t[0]||(t[0]=function(){return i.onListFocus&&i.onListFocus.apply(i,arguments)}),onBlur:t[1]||(t[1]=function(){return i.onListBlur&&i.onListBlur.apply(i,arguments)}),onKeydown:t[2]||(t[2]=function(){return i.onListKeyDown&&i.onListKeyDown.apply(i,arguments)}),onMouseleave:t[3]||(t[3]=function(){return i.onListMouseLeave&&i.onListMouseLeave.apply(i,arguments)})},e.ptm("list")),[(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(n.model,function(c,d){return o.openBlock(),o.createElementBlock("li",o.mergeProps({key:d,id:i.getItemId(d),class:e.cx("item",{processedItem:c,id:i.getItemId(d)}),role:"menuitem","aria-label":c.label,"aria-disabled":i.disabled(c),onClick:function(f){return i.onItemClick(f,c)},onMouseenter:function(f){return i.onItemMouseEnter(d)},ref_for:!0},i.getPTOptions("item",c,d),{"data-p-focused":i.isItemActive(i.getItemId(d)),"data-p-disabled":i.disabled(c)||!1}),[o.createElementVNode("div",o.mergeProps({class:e.cx("itemContent"),ref_for:!0},i.getPTOptions("itemContent",c,d)),[n.templates.item?(o.openBlock(),o.createBlock(o.resolveDynamicComponent(n.templates.item),{key:1,item:c,index:d,label:c.label,props:i.getMenuItemProps(c,d)},null,8,["item","index","label","props"])):o.withDirectives((o.openBlock(),o.createElementBlock("a",o.mergeProps({key:0,href:c.url,class:e.cx("itemLink"),target:c.target,tabindex:"-1","aria-hidden":"true",ref_for:!0},i.getPTOptions("itemLink",c,d)),[!n.templates.icon&&!n.templates.itemicon?o.withDirectives((o.openBlock(),o.createElementBlock("span",o.mergeProps({key:0,class:[e.cx("itemIcon"),c.icon],ref_for:!0},i.getPTOptions("itemIcon",c,d)),null,16)),[[l]]):(o.openBlock(),o.createBlock(o.resolveDynamicComponent(n.templates.icon||n.templates.itemicon),{key:1,item:c,class:o.normalizeClass(e.cx("itemIcon"))},null,8,["item","class"]))],16,Kf)),[[s,{value:c.label,disabled:!n.tooltipOptions},n.tooltipOptions]])],16)],16,Qf)}),128))],16,Jf)],16)}Cl.render=_f;var la={name:"Dock",extends:Yf,inheritAttrs:!1,matchMediaListener:null,data:function(){return{query:null,queryMatches:!1}},mounted:function(){this.bindMatchMediaListener()},beforeUnmount:function(){this.unbindMatchMediaListener()},methods:{bindMatchMediaListener:function(){var t=this;if(!this.matchMediaListener){var n=matchMedia("(max-width: ".concat(this.breakpoint,")"));this.query=n,this.queryMatches=n.matches,this.matchMediaListener=function(){t.queryMatches=n.matches,t.mobileActive=!1},this.query.addEventListener("change",this.matchMediaListener)}},unbindMatchMediaListener:function(){this.matchMediaListener&&(this.query.removeEventListener("change",this.matchMediaListener),this.matchMediaListener=null)}},computed:{containerClass:function(){return[this.class,this.cx("root")]}},components:{DockSub:Cl}};function qf(e,t,n,a,r,i){var l=o.resolveComponent("DockSub");return o.openBlock(),o.createElementBlock("div",o.mergeProps({class:i.containerClass,style:e.style},e.ptmi("root")),[o.createVNode(l,{model:e.model,templates:e.$slots,tooltipOptions:e.tooltipOptions,position:e.position,menuId:e.menuId,"aria-label":e.ariaLabel,"aria-labelledby":e.ariaLabelledby,tabindex:e.tabindex,pt:e.pt,unstyled:e.unstyled},null,8,["model","templates","tooltipOptions","position","menuId","aria-label","aria-labelledby","tabindex","pt","unstyled"])],16)}la.render=qf;function $f(e){let{rootEl:t,isSticky:n,layoutItemStyles:a}=e;const r=o.shallowRef(!1),i=o.shallowRef(0),l=o.computed(()=>{const d=typeof r.value=="boolean"?"top":r.value;return[n.value?{top:"auto",bottom:"auto",height:void 0}:void 0,r.value?{[d]:F(i.value)}:{top:a.value.top}]});o.onMounted(()=>{o.watch(n,d=>{d?window.addEventListener("scroll",c,{passive:!0}):window.removeEventListener("scroll",c)},{immediate:!0})}),o.onBeforeUnmount(()=>{window.removeEventListener("scroll",c)});let s=0;function c(){const d=s>window.scrollY?"up":"down",u=t.value.getBoundingClientRect(),f=parseFloat(a.value.top??0),g=window.scrollY-Math.max(0,i.value-f),h=u.height+Math.max(i.value,f)-window.scrollY-window.innerHeight,m=parseFloat(getComputedStyle(t.value).getPropertyValue("--v-body-scroll-y"))||0;u.height<window.innerHeight-f?(r.value="top",i.value=f):d==="up"&&r.value==="bottom"||d==="down"&&r.value==="top"?(i.value=window.scrollY+u.top-m,r.value=!0):d==="down"&&h<=0?(i.value=0,r.value="bottom"):d==="up"&&g<=0&&(m?r.value!=="top"&&(i.value=-g+m+f,r.value="top"):(i.value=u.top+g,r.value="top")),s=window.scrollY}return{isStuck:r,stickyStyles:l}}const eg=100,tg=20;function Al(e){return(e<0?-1:1)*Math.sqrt(Math.abs(e))*1.41421356237}function wl(e){if(e.length<2)return 0;if(e.length===2)return e[1].t===e[0].t?0:(e[1].d-e[0].d)/(e[1].t-e[0].t);let t=0;for(let n=e.length-1;n>0;n--){if(e[n].t===e[n-1].t)continue;const a=Al(t),r=(e[n].d-e[n-1].d)/(e[n].t-e[n-1].t);t+=(r-a)*Math.abs(r),n===e.length-1&&(t*=.5)}return Al(t)*1e3}function ng(){const e={};function t(r){Array.from(r.changedTouches).forEach(i=>{(e[i.identifier]??(e[i.identifier]=new Zl(tg))).push([r.timeStamp,i])})}function n(r){Array.from(r.changedTouches).forEach(i=>{delete e[i.identifier]})}function a(r){const i=e[r]?.values().reverse();if(!i)throw new Error(`No samples for touch id ${r}`);const l=i[0],s=[],c=[];for(const d of i){if(l[0]-d[0]>eg)break;s.push({t:d[0],d:d[1].clientX}),c.push({t:d[0],d:d[1].clientY})}return{x:wl(s),y:wl(c),get direction(){const{x:d,y:u}=this,[f,g]=[Math.abs(d),Math.abs(u)];return f>g&&d>=0?"right":f>g&&d<=0?"left":g>f&&u>=0?"down":g>f&&u<=0?"up":og()}}}return{addMovement:t,endTouch:n,getVelocity:a}}function og(){throw new Error}function ag(e){let{el:t,isActive:n,isTemporary:a,width:r,touchless:i,position:l}=e;o.onMounted(()=>{window.addEventListener("touchstart",b,{passive:!0}),window.addEventListener("touchmove",p,{passive:!1}),window.addEventListener("touchend",A,{passive:!0})}),o.onBeforeUnmount(()=>{window.removeEventListener("touchstart",b),window.removeEventListener("touchmove",p),window.removeEventListener("touchend",A)});const s=o.computed(()=>["left","right"].includes(l.value)),{addMovement:c,endTouch:d,getVelocity:u}=ng();let f=!1;const g=o.shallowRef(!1),h=o.shallowRef(0),m=o.shallowRef(0);let v;function y(V,k){return(l.value==="left"?V:l.value==="right"?document.documentElement.clientWidth-V:l.value==="top"?V:l.value==="bottom"?document.documentElement.clientHeight-V:Lt())-(k?r.value:0)}function C(V){let k=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;const w=l.value==="left"?(V-m.value)/r.value:l.value==="right"?(document.documentElement.clientWidth-V-m.value)/r.value:l.value==="top"?(V-m.value)/r.value:l.value==="bottom"?(document.documentElement.clientHeight-V-m.value)/r.value:Lt();return k?Math.max(0,Math.min(1,w)):w}function b(V){if(i.value)return;const k=V.changedTouches[0].clientX,w=V.changedTouches[0].clientY,O=25,L=l.value==="left"?k<O:l.value==="right"?k>document.documentElement.clientWidth-O:l.value==="top"?w<O:l.value==="bottom"?w>document.documentElement.clientHeight-O:Lt(),T=n.value&&(l.value==="left"?k<r.value:l.value==="right"?k>document.documentElement.clientWidth-r.value:l.value==="top"?w<r.value:l.value==="bottom"?w>document.documentElement.clientHeight-r.value:Lt());(L||T||n.value&&a.value)&&(v=[k,w],m.value=y(s.value?k:w,n.value),h.value=C(s.value?k:w),f=m.value>-20&&m.value<80,d(V),c(V))}function p(V){const k=V.changedTouches[0].clientX,w=V.changedTouches[0].clientY;if(f){if(!V.cancelable){f=!1;return}const L=Math.abs(k-v[0]),T=Math.abs(w-v[1]);(s.value?L>T&&L>3:T>L&&T>3)?(g.value=!0,f=!1):(s.value?T:L)>3&&(f=!1)}if(!g.value)return;V.preventDefault(),c(V);const O=C(s.value?k:w,!1);h.value=Math.max(0,Math.min(1,O)),O>1?m.value=y(s.value?k:w,!0):O<0&&(m.value=y(s.value?k:w,!1))}function A(V){if(f=!1,!g.value)return;c(V),g.value=!1;const k=u(V.changedTouches[0].identifier),w=Math.abs(k.x),O=Math.abs(k.y);(s.value?w>O&&w>400:O>w&&O>3)?n.value=k.direction===({left:"right",right:"left",top:"down",bottom:"up"}[l.value]||Lt()):n.value=h.value>.5}const S=o.computed(()=>g.value?{transform:l.value==="left"?`translateX(calc(-100% + ${h.value*r.value}px))`:l.value==="right"?`translateX(calc(100% - ${h.value*r.value}px))`:l.value==="top"?`translateY(calc(-100% + ${h.value*r.value}px))`:l.value==="bottom"?`translateY(calc(100% - ${h.value*r.value}px))`:Lt(),transition:"none"}:void 0);return We(g,()=>{const V=t.value?.style.transform??null,k=t.value?.style.transition??null;o.watchEffect(()=>{t.value?.style.setProperty("transform",S.value?.transform||"none"),t.value?.style.setProperty("transition",S.value?.transition||null)}),o.onScopeDispose(()=>{t.value?.style.setProperty("transform",V),t.value?.style.setProperty("transition",k)})}),{isDragging:g,dragProgress:h,dragStyles:S}}function Lt(){throw new Error}const rg=["start","end","left","right","top","bottom"],ig=N({color:String,disableResizeWatcher:Boolean,disableRouteWatcher:Boolean,expandOnHover:Boolean,floating:Boolean,modelValue:{type:Boolean,default:null},permanent:Boolean,rail:{type:Boolean,default:null},railWidth:{type:[Number,String],default:56},scrim:{type:[Boolean,String],default:!0},image:String,temporary:Boolean,persistent:Boolean,touchless:Boolean,width:{type:[Number,String],default:256},location:{type:String,default:"start",validator:e=>rg.includes(e)},sticky:Boolean,...Xe(),...X(),...Lo(),...cr({mobile:null}),...Re(),...Uo(),...pe(),..._({tag:"nav"}),...de()},"VNavigationDrawer"),Sl=j()({name:"VNavigationDrawer",props:ig(),emits:{"update:modelValue":e=>!0,"update:rail":e=>!0},setup(e,t){let{attrs:n,emit:a,slots:r}=t;const{isRtl:i}=Pe(),{themeClasses:l}=ge(e),{borderClasses:s}=Je(e),{backgroundColorClasses:c,backgroundColorStyles:d}=Ae(o.toRef(e,"color")),{elevationClasses:u}=Ze(e),{displayClasses:f,mobile:g}=To(e),{roundedClasses:h}=we(e),m=qa(),v=be(e,"modelValue",null,R=>!!R),{ssrBootStyles:y}=ln(),{scopeId:C}=Tt(),b=o.ref(),p=o.shallowRef(!1),{runOpenDelay:A,runCloseDelay:S}=Mo(e,R=>{p.value=R}),V=o.computed(()=>e.rail&&e.expandOnHover&&p.value?Number(e.width):Number(e.rail?e.railWidth:e.width)),k=o.computed(()=>co(e.location,i.value)),w=o.computed(()=>e.persistent),O=o.computed(()=>!e.permanent&&(g.value||e.temporary)),L=o.computed(()=>e.sticky&&!O.value&&k.value!=="bottom");We(()=>e.expandOnHover&&e.rail!=null,()=>{o.watch(p,R=>a("update:rail",!R))}),We(()=>!e.disableResizeWatcher,()=>{o.watch(O,R=>!e.permanent&&o.nextTick(()=>v.value=!R))}),We(()=>!e.disableRouteWatcher&&!!m,()=>{o.watch(m.currentRoute,()=>O.value&&(v.value=!1))}),o.watch(()=>e.permanent,R=>{R&&(v.value=!0)}),e.modelValue==null&&!O.value&&(v.value=e.permanent||!g.value);const{isDragging:T,dragProgress:x}=ag({el:b,isActive:v,isTemporary:O,width:V,touchless:o.toRef(e,"touchless"),position:k}),I=o.computed(()=>{const R=O.value?0:e.rail&&e.expandOnHover?Number(e.railWidth):V.value;return T.value?R*x.value:R}),B=o.computed(()=>["top","bottom"].includes(e.location)?0:V.value),{layoutItemStyles:D,layoutItemScrimStyles:M}=Xo({id:e.name,order:o.computed(()=>parseInt(e.order,10)),position:k,layoutSize:I,elementSize:B,active:o.computed(()=>v.value||T.value),disableTransitions:o.computed(()=>T.value),absolute:o.computed(()=>e.absolute||L.value&&typeof z.value!="string")}),{isStuck:z,stickyStyles:W}=$f({rootEl:b,isSticky:L,layoutItemStyles:D}),K=Ae(o.computed(()=>typeof e.scrim=="string"?e.scrim:null)),E=o.computed(()=>({...T.value?{opacity:x.value*.2,transition:"none"}:void 0,...M.value}));return tt({VList:{bgColor:"transparent"}}),Z(()=>{const R=r.image||e.image;return o.createVNode(o.Fragment,null,[o.createVNode(e.tag,o.mergeProps({ref:b,onMouseenter:A,onMouseleave:S,class:["v-navigation-drawer",`v-navigation-drawer--${k.value}`,{"v-navigation-drawer--expand-on-hover":e.expandOnHover,"v-navigation-drawer--floating":e.floating,"v-navigation-drawer--is-hovering":p.value,"v-navigation-drawer--rail":e.rail,"v-navigation-drawer--temporary":O.value,"v-navigation-drawer--persistent":w.value,"v-navigation-drawer--active":v.value,"v-navigation-drawer--sticky":L.value},l.value,c.value,s.value,f.value,u.value,h.value,e.class],style:[d.value,D.value,y.value,W.value,e.style,["top","bottom"].includes(k.value)?{height:"auto"}:{}]},C,n),{default:()=>[R&&o.createVNode("div",{key:"image",class:"v-navigation-drawer__img"},[r.image?o.createVNode(se,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{alt:"",cover:!0,height:"inherit",src:e.image}}},r.image):o.createVNode(vt,{key:"image-img",alt:"",cover:!0,height:"inherit",src:e.image},null)]),r.prepend&&o.createVNode("div",{class:"v-navigation-drawer__prepend"},[r.prepend?.()]),o.createVNode("div",{class:"v-navigation-drawer__content"},[r.default?.()]),r.append&&o.createVNode("div",{class:"v-navigation-drawer__append"},[r.append?.()])]}),o.createVNode(o.Transition,{name:"fade-transition"},{default:()=>[O.value&&(T.value||v.value)&&!!e.scrim&&o.createVNode("div",o.mergeProps({class:["v-navigation-drawer__scrim",K.backgroundColorClasses.value],style:[E.value,K.backgroundColorStyles.value],onClick:()=>{w.value||(v.value=!1)}},C),null)]})])}),{isStuck:z}}}),lg={class:"text-center"},sg={key:0},cg={key:1,style:{position:"fixed",bottom:"0",left:"0"}},Vl=o.defineComponent({__name:"FloatMenu",setup(e){const{mobile:t}=ie.useDisplay(),n=fe(),a=ie.useTheme(),r=ft.useRouter(),i=Cn(),l=ve(),s=d=>{if(n.setCurrentSubHdr(d.label),n.execAction(d,i.eventMap),!d.children){n.setActiveMenuVal(d.key),r.push(d.link),n.setFloatMenu(!1);return}n.setActiveMenu(d),d.link&&r.push(d.link)},c=d=>{if(d.key==="c-0"){n.setFloatMenu(!0);return}if(d.key==="c-1"){n.setDockVisible(!1);return}if(n.setCurrentSubHdr(d.label),n.execAction(d,i.eventMap),!d.children){if(n.setActiveMenuVal(d.key),d.link){if(d.link.includes("http")){window.open(d.link,"_blank");return}r.push(d.link)}return}n.setActiveMenu(d)};return(d,u)=>(o.openBlock(),o.createElementBlock(o.Fragment,null,[o.createVNode(hi,{modelValue:o.unref(n).floatMenu,"onUpdate:modelValue":u[1]||(u[1]=f=>o.unref(n).floatMenu=f),id:"floatContainer",fullscreen:o.unref(t),width:"100%","location-strategy":"static",height:"60vh",transition:"dialog-bottom-transition"},{default:o.withCtx(()=>[o.createVNode(Ye,{class:o.normalizeClass(["mx-auto dock-window",[o.unref(a).current.value.dark?"dark":"light",o.unref(t)?"":"rounded-xl"]])},{default:o.withCtx(()=>[o.createVNode(ee,null,{append:o.withCtx(()=>[o.unref(l).isAuthenticated()?(o.openBlock(),o.createBlock(Pt,{key:0})):(o.openBlock(),o.createBlock(ne,{key:1,to:"/login",color:"info","prepend-icon":"mdi-login"},{default:o.withCtx(()=>u[4]||(u[4]=[o.createTextVNode("Sign In")])),_:1})),o.createVNode(ne,{icon:"mdi-close",onClick:u[0]||(u[0]=o.withModifiers(f=>o.unref(n).setFloatMenu(!1),["stop"])),title:"Close"})]),_:1}),o.createVNode(Le,{class:"mx-auto"},{default:o.withCtx(()=>[o.createVNode(vt,{src:o.unref(a).current.value.dark?o.unref(vi):o.unref(yi),height:"50px",width:"350px",class:o.normalizeClass(o.unref(a).current.value.dark?"":"image-remove-bg")},null,8,["src","class"])]),_:1}),o.createVNode(Wa,{class:"mx-auto"},{default:o.withCtx(()=>[o.createVNode(Oe,null,{default:o.withCtx(()=>[o.createVNode(Te,null,{default:o.withCtx(()=>[o.createElementVNode("div",lg,[o.createElementVNode("div",{class:o.normalizeClass(["title text-h5",`text-black-${o.unref(a).current.value.dark?"darken":"lighten"}-2`])},o.toDisplayString(o.unref(n).currentPageHeader)+" - "+o.toDisplayString(o.unref(n).currentSubHdr),3)])]),_:1})]),_:1})]),_:1}),o.createVNode(at,null,{default:o.withCtx(()=>[o.createVNode(xo,{fluid:"",class:o.normalizeClass(o.unref(t)?"ms-10":"")},{default:o.withCtx(()=>[o.createVNode(Oe,{class:"justify-end align-end","no-gutters":""},{default:o.withCtx(()=>[(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(o.unref(n).activeMenu,f=>(o.openBlock(),o.createBlock(Te,{key:f.key},{default:o.withCtx(()=>[o.createVNode(zn,{link:f.link||"",disabled:f.disabled,"badge-color":f.badgeColor,"badge-content":o.unref(n).getBadgeContent(f),label:f.label,icon:o.unref(n).renderIcon(f),active:f.active,onLinkClicked:g=>s(f),"sub-menu":f.childDropdown?f.children:[]},null,8,["link","disabled","badge-color","badge-content","label","icon","active","onLinkClicked","sub-menu"])]),_:2},1024))),128))]),_:1})]),_:1},8,["class"])]),_:1})]),_:1},8,["class"])]),_:1},8,["modelValue","fullscreen"]),o.unref(t)?(o.openBlock(),o.createElementBlock("div",cg,[o.withDirectives(o.createVNode(ne,{variant:"elevated",class:"square-button ma-1",icon:"mdi-dots-grid",color:`amber-${o.unref(a).current.value.dark?"darken":"lighten"}-2`,onClick:u[3]||(u[3]=o.withModifiers(f=>o.unref(n).setFloatMenu(!0),["stop"])),"active-color":`amber-${o.unref(a).current.value.dark?"darken":"lighten"}-2`},null,8,["color","active-color"]),[[Ke,"Show Navigation Bar",void 0,{top:!0}]])])):(o.openBlock(),o.createElementBlock("div",sg,[o.unref(n).dockPosition!=="bottom"?(o.openBlock(),o.createBlock(Sl,{key:0,class:"bg-transparent",modelValue:o.unref(n).dockVisible,"onUpdate:modelValue":u[2]||(u[2]=f=>o.unref(n).dockVisible=f),rail:!0,"rail-width":"70",floating:"",location:o.unref(n).dockPosition},{default:o.withCtx(()=>[o.unref(n).dockVisible?(o.openBlock(),o.createBlock(o.unref(la),{key:0,model:[o.unref(i).launcher,...o.unref(n).activeMenu,o.unref(i).toggleDock],position:o.unref(n).dockPosition,class:o.normalizeClass(o.unref(n).dockPosition==="bottom"?"bottom":"")},{itemicon:o.withCtx(({item:f})=>[o.withDirectives(o.createVNode(ne,{class:"square-button",icon:o.unref(n).renderIcon(f),color:`${f.buttonColor}-${o.unref(a).current.value.dark?"darken":"lighten"}-2`,onClick:o.withModifiers(g=>c(f),["stop"]),"active-color":`amber-${o.unref(a).current.value.dark?"darken":"lighten"}-2`,active:f.active},null,8,["icon","color","onClick","active-color","active"]),[[Ke,f.label,void 0,{top:!0}]])]),_:1},8,["model","position","class"])):o.createCommentVNode("",!0)]),_:1},8,["modelValue","location"])):o.createCommentVNode("",!0),o.unref(n).dockVisible&&o.unref(n).dockPosition==="bottom"?(o.openBlock(),o.createBlock(o.unref(la),{key:1,style:{position:"fixed",height:"56px",width:"100%",margin:"0",left:"0",bottom:"0"},model:[o.unref(i).launcher,...o.unref(n).activeMenu,o.unref(i).toggleDock],position:o.unref(n).dockPosition,class:o.normalizeClass(o.unref(n).dockPosition==="bottom"?"bottom":"")},{itemicon:o.withCtx(({item:f})=>[o.withDirectives(o.createVNode(ne,{class:"square-button",icon:o.unref(n).renderIcon(f),color:`${f.buttonColor}-${o.unref(a).current.value.dark?"darken":"lighten"}-2`,onClick:o.withModifiers(g=>c(f),["stop"]),"active-color":`amber-${o.unref(a).current.value.dark?"darken":"lighten"}-2`,active:f.active},null,8,["icon","color","onClick","active-color","active"]),[[Ke,f.label,void 0,{top:!0}]])]),_:1},8,["model","position","class"])):o.createCommentVNode("",!0)]))],64))}}),kl=o.defineComponent({__name:"FloatingLayout",setup(e){const{mobile:t}=ie.useDisplay(),n=fe(),a=ie.useTheme();return o.onMounted(()=>{a.current.value.dark&&n.currentTheme==="light"&&(a.global.name.value="light")}),(r,i)=>(o.openBlock(),o.createElementBlock(o.Fragment,null,[o.createVNode(Vl),o.createVNode(_o,null,{default:o.withCtx(()=>[o.renderSlot(r.$slots,"default")]),_:3}),o.unref(t)?o.createCommentVNode("",!0):(o.openBlock(),o.createBlock(Ot,{key:0}))],64))}}),dg=Object.freeze(Object.defineProperty({__proto__:null,default:kl},Symbol.toStringTag,{value:"Module"})),Cn=()=>({eventMap:{toggleTheme:()=>{fe().toggleTheme()}},launcher:{label:"Launcher",key:"c-0",icon:"mdi-dots-grid",disabled:!1,buttonColor:"purple",link:"/",active:!0,children:[]},toggleDock:{label:"Hide/Show Dock",key:"c-1",icon:"mdi-eye-off",disabled:!1,buttonColor:"purple",link:"/",active:!0,children:[]},registerLayouts:r=>{const i=Object.assign({"../layouts/AppLayout.vue":Jd,"../layouts/DefaultLayout.vue":gu,"../layouts/FixedLayout.vue":Pl,"../layouts/FloatingLayout.vue":dg,"../layouts/UcsdFooter.vue":Xd,"../layouts/UcsdHeader.vue":zd,"../layouts/UserPanel.vue":kd});for(const l in i){const s=i[l],c=l.split("/").pop()?.replace(".vue","");c&&c.endsWith("Layout")&&(console.log(l),r.component(c,s.default))}fe().init()}}),ug={key:0},sa=o.defineComponent({__name:"RailMenu",props:{layout:{type:String,required:!1},toggleNav:{type:Boolean,required:!1}},emits:["linkClicked"],setup(e,{emit:t}){const{mobile:n}=ie.useDisplay(),a=ft.useRouter(),r=fe(),i=ie.useTheme(),l=Cn(),s=ve(),c=t,d=f=>r.layoutRail?"":f.split("-").length===3?"ms-5":f.split("-").length>3?"ms-10":"",u=f=>{if(r.execAction(f,l.eventMap),!f.children){if(r.setActiveMenuVal(f.key),r.setLayoutRail(!0),f.link){if(f.link.includes("http")){window.open(f.link,"_blank");return}a.push(f.link)}return}r.setActiveMenu(f),c("linkClicked")};return(f,g)=>(o.openBlock(),o.createBlock(Sl,{floating:"",width:"300",temporary:o.unref(n),modelValue:o.unref(r).navDrawer,"onUpdate:modelValue":g[2]||(g[2]=h=>o.unref(r).navDrawer=h),"rail-width":"60",class:o.normalizeClass(`bg-grey-${o.unref(i).current.value.dark?"darken":"lighten"}-4`),rail:o.unref(r).layoutRail,onClick:g[3]||(g[3]=h=>o.unref(r).setLayoutRail(!1))},o.createSlots({default:o.withCtx(()=>[o.createVNode(pt,{class:"pa-2 ma-0",activatable:!0},{default:o.withCtx(()=>[o.createVNode(ee,{nav:""},{prepend:o.withCtx(()=>[o.withDirectives(o.createVNode(ne,{class:"square-button",size:"small",icon:o.unref(r).layoutRail?"mdi-chevron-right":"mdi-chevron-left",color:`amber-${o.unref(i).current.value.dark?"darken":"lighten"}-2`,onClick:g[0]||(g[0]=o.withModifiers(h=>o.unref(r).setLayoutRail(!o.unref(r).layoutRail),["stop"]))},null,8,["icon","color"]),[[Ke,"Expand/Collapse",void 0,{top:!0}]])]),_:1}),o.createVNode(ee,{nav:""},{prepend:o.withCtx(()=>[o.withDirectives(o.createVNode(ne,{class:"square-button",icon:"mdi-eye-off",color:`amber-${o.unref(i).current.value.dark?"darken":"lighten"}-2`,onClick:g[1]||(g[1]=o.withModifiers(h=>o.unref(r).setNavDrawer(!1),["stop"]))},null,8,["color"]),[[Ke,"Hide Navigation Bar",void 0,{top:!0}]])]),_:1}),o.createVNode(Wn),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(o.unref(r).activeMenu,h=>(o.openBlock(),o.createBlock(ee,{nav:"",key:h.key,active:o.unref(r).activeMenuVal===h.key},o.createSlots({prepend:o.withCtx(()=>[o.withDirectives(o.createVNode(ne,{class:o.normalizeClass(["square-button",d(h.key)]),icon:o.unref(r).renderIcon(h),color:`${h.buttonColor}-${o.unref(i).current.value.dark?"darken":"lighten"}-2`,onClick:o.withModifiers(m=>u(h),["stop"]),"active-color":`amber-${o.unref(i).current.value.dark?"darken":"lighten"}-2`,active:h.active},null,8,["class","icon","color","onClick","active-color","active"]),[[Ke,h.label,void 0,{top:!0}]])]),_:2},[h.badgeContent&&!o.unref(r).layoutRail?{name:"append",fn:o.withCtx(()=>[o.createVNode(an,{color:h.badgeColor,content:h.badgeContent(),inline:""},null,8,["color","content"])]),key:"0"}:void 0,o.unref(r).layoutRail?void 0:{name:"default",fn:o.withCtx(()=>[o.createVNode(ee,{class:"text-body-2 ms-5",onClick:o.withModifiers(m=>u(h),["stop"])},{default:o.withCtx(()=>[o.createTextVNode(o.toDisplayString(h.label),1)]),_:2},1032,["onClick"])]),key:"1"}]),1032,["active"]))),128))]),_:1}),o.unref(n)?(o.openBlock(),o.createElementBlock("span",ug,[o.unref(s).isAuthenticated()?(o.openBlock(),o.createBlock(Pt,{key:0})):o.withDirectives((o.openBlock(),o.createBlock(ne,{key:1,class:"square-button",size:"small",icon:"mdi-login",color:`amber-${o.unref(i).current.value.dark?"darken":"lighten"}-2`,to:"/login"},null,8,["color"])),[[Ke,"Sign In",void 0,{top:!0}]])])):o.createCommentVNode("",!0)]),_:2},[o.unref(n)&&!o.unref(r).layoutRail?{name:"append",fn:o.withCtx(()=>[o.createVNode(Ot)]),key:"0"}:void 0]),1032,["temporary","modelValue","class","rail"]))}}),Il=o.defineComponent({__name:"FixedLayout",props:{pageHeader:{type:String,required:!1},pageSubHeader:{type:String,required:!1}},setup(e){const t=fe(),{mobile:n}=ie.useDisplay(),a=ie.useTheme();return o.onMounted(()=>{a.current.value.dark&&t.currentTheme==="light"&&(a.global.name.value="light")}),(r,i)=>(o.openBlock(),o.createElementBlock(o.Fragment,null,[o.createVNode(Gn,{"header-sub-title":e.pageSubHeader,"header-title":e.pageHeader},null,8,["header-sub-title","header-title"]),o.createVNode(sa,{layout:"Fixed","toggle-nav":!0}),o.createVNode(_o,null,{default:o.withCtx(()=>[o.renderSlot(r.$slots,"default")]),_:3}),o.unref(n)?o.createCommentVNode("",!0):(o.openBlock(),o.createBlock(Ot,{key:0}))],64))}}),fg=Cn(),gg={install(e,t){e.provide("ucsdAppConfig",t.ucsdAppConfig),fg.registerLayouts(e),typeof t.ucsdAppConfig.initCallback=="function"&&t.ucsdAppConfig.initCallback(),console.log("UCSD Plugin initialized with config:",t.ucsdAppConfig)}},mg=[{path:"/login",name:"Login",component:Sr},{path:"/login-success",name:"LoginSuccess",component:Vr},{path:"/logout",name:"Logout",component:Mr},{path:"/unauthorized",name:"Unauthorized",component:Jr}],hg=e=>{e.beforeEach(async(t,n,a)=>{const r=ve();if(t.matched.some(s=>s.meta.requiresAuth)&&!r.isAuthenticated())return r.preAuthRoute=t.path,console.log("User not authenticated. Redirecting to login..."),a({name:"Login"});const i=t.meta?.roles,l=r.getRoleAssignedToUser();if(i&&!i.some(s=>l.includes(s)))return a({path:"/unauthorized"});a()})},Nl=eo.defineStore("its-audit",()=>{const e=o.ref({audits:new Array}),t=()=>{e.value.audits.splice(0,e.value.audits.length)},n=l=>{const s=[];let c=0;const d=u=>{let f=[];for(let g=0;g<u.length;g++){if(g%5){const h={op:l.op,path:l.path,oldKeyValues:f};s.push({detailKey:"ad-"+c++,detailValue:JSON.stringify(h)}),f=[]}f.push({key:u[g].key,value:u[g].value})}if(f.length>0){const g={op:l.op,path:l.path,oldKeyValues:f};s.push({detailKey:"ad-"+c++,detailValue:JSON.stringify(g)})}};return typeof l.oldKeyValues<"u"&&d(l.oldKeyValues),typeof l.newKeyValues<"u"&&d(l.newKeyValues),s};return{auditQueue:e,addToAuditQueue:(l,s,c)=>{l.details=[{detailKey:"userInfo",detailValue:JSON.stringify(ve().userInfo())}].concat(s),c.length>0&&c.forEach((d,u)=>{const f=JSON.stringify(d);if(f.length>1e3){const g=n(d);l.details?.push(...g)}else l.details?.push({detailKey:"ad-"+u,detailValue:f})}),e.value.audits.push(l)},postAudit:async()=>{let l=0;for(const s of e.value.audits)s.dateCreated=At().getTimeStamp(),s.auditId=Date.now()+l++},getAuditQueue:(l,s)=>{const c=[];return e.value.audits.forEach(d=>{d.details?.forEach(u=>{l&&u.detailKey===l&&c.push(d),s&&u.detailKey==="userInfo"&&u.detailValue.includes(s)&&c.push(d)})}),c},resetAuditQueue:t}},{persist:[{storage:sessionStorage,pick:["auditQueue"]}]}),vg=()=>{const e=At(),t=Nl();let n={};const a=s=>{Object.entries(s).forEach(([c,d])=>{console.log(`Key: ${c}, Value: ${d}`)})};return{trackChanges:(s,c)=>{if(c){n={};return}n=e.deepClone(s)},commitChanges:(s,c,d,u,f)=>{c.event=c.event+"-"+u,console.log("Old Value:"),a(n),console.log("New Value:"),a(s),console.log("Differences");let g=[];u==="update"&&(g=e.compareObjects(n,s));const h=[];if(g.forEach(m=>{u==="update"&&h.push({op:u,path:m.path,oldValue:m.value1,newValue:m.value2}),console.log(`Difference at "${m.path}": Old = ${m.value1}, New = ${m.value2}`)}),n=e.deepClone(s),u==="new"||u==="delete"){const m=[];for(const y in s)if(Object.prototype.hasOwnProperty.call(s,y)){if(u==="new"&&f.length>0&&!f.includes(y))continue;m.push({key:y,value:s[y]})}const v={op:u,path:"/"};u==="delete"?v.oldKeyValues=m:v.newKeyValues=m,h.push(v)}if(h.length>0){let m={};c.eventIcon!==""&&(m.icon=c.eventIcon),c.eventColor!==""&&(m.color=c.eventColor),s.hasOwnProperty("id")&&(m.id=s.id),Object.keys(m).length===0&&(m.id=d);const v=JSON.stringify(m),y=[{detailKey:d,detailValue:v}];t.addToAuditQueue(c,y,h),t.postAudit().then(C=>{console.log(C)})}console.log(JSON.stringify(c))},mapAuditToTimeLine:s=>{const c=(f,g)=>{let h="",m=g==="old"?"old-data":"";if(f.hasOwnProperty(g+"KeyValues")){h+="<div>"+e.getLastPath(f.path)+`</div>
345
345
  `;for(let v=0;v<f[g+"KeyValues"].length;v++)h+='<div class="v-row v-row--no-gutters '+m+'"><div class="v-col">'+e.getLastPath(f[g+"KeyValues"][v].key)+'</div><div class="v-col">'+f[g+"KeyValues"][v].value+"</div></div>"}return f.hasOwnProperty(g+"Value")&&(h+='<div class="v-row v-row--no-gutters '+m+'"><div class="v-col">'+e.getLastPath(f.path)+'</div><div class="v-col">'+f[g+"Value"]+"</div></div>"),f.hasOwnProperty(g+"Values")&&(h+='<div class="v-row v-row--no-gutters '+m+'"><div class="v-col">'+e.getLastPath(f.path)+'</div><div class="v-col">'+f[g+"Values"].join(",")+"</div></div>"),h},d=f=>{let g="";const h=[],m=[];return f.forEach(v=>{v.op==="added"||v.op==="info"?h.push(v):m.push(v)}),m.length>0&&(g+='<div class="v-container ma-0 pa-0 text-body-2">',m.forEach(v=>g+=c(v,"old")),g+='</div><hr class="v-divider mt-3 mb-3"/>',g+='<div class="v-container ma-0 pa-0">',m.forEach(v=>g+=c(v,"new")),g+="</div>"),h.length>0&&(g+='<div class="v-container ma-0 pa-0">',h.forEach(v=>g+=c(v,"new")),g+="</div>"),g},u=[];s.sort((f,g)=>e.ensure(g.auditId)-e.ensure(f.auditId));for(let f=0;f<s.length;f++){const g=e.parseDateAndSplit(e.ensure(s[f].dateCreated)),h=s[f].details??[];let m="unknown",v="unknown",y="info",C="mdi-information-variant",b="No information";const p=[];for(let A=0;A<h.length;A++){if(h[A].detailKey==="userInfo"){const S=JSON.parse(h[A].detailValue);m=S.name,v=S.email}if(h[A].detailKey.startsWith("ad-"))try{p.push(JSON.parse(h[A].detailValue))}catch(S){console.log(S)}else{const S=JSON.parse(h[A].detailValue);S.hasOwnProperty("color")&&(y=S.color),S.hasOwnProperty("icon")&&(C=S.icon)}}p.length>0&&(b=d(p)),u.push({auditId:e.ensure(s[f].auditId),color:y,icon:C,fullDate:e.ensure(s[f].dateCreated),date:g.date,time:g.time,name:m,email:v,event:s[f].event,details:b})}return u}}};G.AppLayout=Ci,G.ChangeHistory=Cd,G.CommonRoutes=mg,G.DefaultLayout=Di,G.FixedLayout=Il,G.FloatMenu=Vl,G.FloatingLayout=kl,G.Login=Sr,G.LoginSuccess=Vr,G.Logout=Mr,G.ProgressDialog=wd,G.RailMenu=sa,G.TileButton=zn,G.TopMenu=Bi,G.UcsdFooter=Ot,G.UcsdHeader=Gn,G.UcsdPlugin=gg,G.Unauthorized=Jr,G.UserPanel=Pt,G.registerGlobalGuards=hg,G.useAuditLog=vg,G.useItsAppStore=fe,G.useItsAuditStore=Nl,G.useItsAuthStore=ve,G.useUcsdAppUtils=At,G.useUcsdLayout=Cn,Object.defineProperty(G,Symbol.toStringTag,{value:"Module"})});
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@diasro/ucsd-its-frontend",
3
3
  "private": false,
4
- "version": "0.0.2",
4
+ "version": "0.0.3",
5
5
  "type": "module",
6
6
  "author": "Robert Dias <rdias@ucsd.edu>",
7
7
  "description": "A UCSD shared component library for Vue 3. For UCSD use only",