????
Current Path : C:/inetpub/vhost/qlhncn.gdtsolutions.vn/www/assets/ |
Current File : C:/inetpub/vhost/qlhncn.gdtsolutions.vn/www/assets/MenuItem-fe4b2e1b.js |
import{r,v as re,W as C,P as n}from"./index-63f91612.js";import{a as Q,c as _e}from"./useTheme-88c8fc58.js";import{c as ee,a as Ne,r as we}from"./withStyles-8b7f6946.js";import{w as ie}from"./capitalize-7bd4806a.js";import{o as te,h as je,M as ke,i as Ae,P as Se,e as M,j as Ue,d as ze,f as He,s as Ke}from"./DialogCustomize-5c5d912b.js";import{d as We}from"./debounce-b2775af4.js";import{r as Ge,e as qe}from"./refType-b95f6af7.js";import{H as oe}from"./HTMLElementType-ee7a24b5.js";import{G as Be}from"./Grow-bfd0cac8.js";import{a as Ve,b as Ye}from"./SelectPanelMulti-840dd9be.js";function Ee(o,e){var t=0;return typeof e=="number"?t=e:e==="center"?t=o.height/2:e==="bottom"&&(t=o.height),t}function ye(o,e){var t=0;return typeof e=="number"?t=e:e==="center"?t=o.width/2:e==="right"&&(t=o.width),t}function Pe(o){return[o.horizontal,o.vertical].map(function(e){return typeof e=="number"?"".concat(e,"px"):e}).join(" ")}function Xe(o,e){for(var t=e,v=0;t&&t!==o;)t=t.parentElement,v+=t.scrollTop;return v}function Z(o){return typeof o=="function"?o():o}var Je={root:{},paper:{position:"absolute",overflowY:"auto",overflowX:"hidden",minWidth:16,minHeight:16,maxWidth:"calc(100% - 32px)",maxHeight:"calc(100% - 32px)",outline:0}},Ce=r.forwardRef(function(e,t){var v=e.action,p=e.anchorEl,y=e.anchorOrigin,h=y===void 0?{vertical:"top",horizontal:"left"}:y,s=e.anchorPosition,I=e.anchorReference,w=I===void 0?"anchorEl":I,F=e.children,P=e.classes,D=e.className,x=e.container,L=e.elevation,$=L===void 0?8:L,j=e.getContentAnchorEl,A=e.marginThreshold,d=A===void 0?16:A,_=e.onEnter,z=e.onEntered,H=e.onEntering,K=e.onExit,N=e.onExited,V=e.onExiting,a=e.open,u=e.PaperProps,c=u===void 0?{}:u,T=e.transformOrigin,g=T===void 0?{vertical:"top",horizontal:"left"}:T,l=e.TransitionComponent,S=l===void 0?Be:l,R=e.transitionDuration,W=R===void 0?"auto":R,O=e.TransitionProps,b=O===void 0?{}:O,Y=Q(e,["action","anchorEl","anchorOrigin","anchorPosition","anchorReference","children","classes","className","container","elevation","getContentAnchorEl","marginThreshold","onEnter","onEntered","onEntering","onExit","onExited","onExiting","open","PaperProps","transformOrigin","TransitionComponent","transitionDuration","TransitionProps"]),G=r.useRef(),ae=r.useCallback(function(i){if(w==="anchorPosition")return s||console.error('Material-UI: You need to provide a `anchorPosition` prop when using <Popover anchorReference="anchorPosition" />.'),s;var f=Z(p),m=f&&f.nodeType===1?f:te(G.current).body,E=m.getBoundingClientRect();{var U=m.getBoundingClientRect();U.top===0&&U.left===0&&U.right===0&&U.bottom===0&&console.warn(["Material-UI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` `))}var k=i===0?h.vertical:"center";return{top:E.top+Ee(E,k),left:E.left+ye(E,h.horizontal)}},[p,h.horizontal,h.vertical,s,w]),se=r.useCallback(function(i){var f=0;if(j&&w==="anchorEl"){var m=j(i);if(m&&i.contains(m)){var E=Xe(i,m);f=m.offsetTop+m.clientHeight/2-E||0}h.vertical!=="top"&&console.error(["Material-UI: You can not change the default `anchorOrigin.vertical` value ","when also providing the `getContentAnchorEl` prop to the popover component.","Only use one of the two props.","Set `getContentAnchorEl` to `null | undefined` or leave `anchorOrigin.vertical` unchanged."].join(` `))}return f},[h.vertical,w,j]),le=r.useCallback(function(i){var f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return{vertical:Ee(i,g.vertical)+f,horizontal:ye(i,g.horizontal)}},[g.horizontal,g.vertical]),ue=r.useCallback(function(i){var f=se(i),m={width:i.offsetWidth,height:i.offsetHeight},E=le(m,f);if(w==="none")return{top:null,left:null,transformOrigin:Pe(E)};var U=ae(f),k=U.top-E.vertical,B=U.left-E.horizontal,fe=k+m.height,de=B+m.width,pe=je(Z(p)),X=pe.innerHeight-d,he=pe.innerWidth-d;if(k<d){var me=k-d;k-=me,E.vertical+=me}else if(fe>X){var ve=fe-X;k-=ve,E.vertical+=ve}if(m.height>X&&m.height&&X&&console.error(["Material-UI: The popover component is too tall.","Some part of it can not be seen on the screen (".concat(m.height-X,"px)."),"Please consider adding a `max-height` to improve the user-experience."].join(` `)),B<d){var ge=B-d;B-=ge,E.horizontal+=ge}else if(de>he){var be=de-he;B-=be,E.horizontal+=be}return{top:"".concat(Math.round(k),"px"),left:"".concat(Math.round(B),"px"),transformOrigin:Pe(E)}},[p,w,ae,se,le,d]),q=r.useCallback(function(){var i=G.current;if(i){var f=ue(i);f.top!==null&&(i.style.top=f.top),f.left!==null&&(i.style.left=f.left),i.style.transformOrigin=f.transformOrigin}},[ue]),De=function(f,m){H&&H(f,m),q()},Le=r.useCallback(function(i){G.current=re.findDOMNode(i)},[]);r.useEffect(function(){a&&q()}),r.useImperativeHandle(v,function(){return a?{updatePosition:function(){q()}}:null},[a,q]),r.useEffect(function(){if(a){var i=We(function(){q()});return window.addEventListener("resize",i),function(){i.clear(),window.removeEventListener("resize",i)}}},[a,q]);var ce=W;W==="auto"&&!S.muiSupportAuto&&(ce=void 0);var $e=x||(p?te(Z(p)).body:void 0);return r.createElement(ke,C({container:$e,open:a,ref:t,BackdropProps:{invisible:!0},className:ee(P.root,D)},Y),r.createElement(S,C({appear:!0,in:a,onEnter:_,onEntered:z,onExit:K,onExited:N,onExiting:V,timeout:ce},b,{onEntering:Ae(De,b.onEntering)}),r.createElement(Se,C({elevation:$,ref:Le},c,{className:ee(P.paper,c.className)}),F)))});Ce.propTypes={action:Ge,anchorEl:Ne(n.oneOfType([oe,n.func]),function(o){if(o.open&&(!o.anchorReference||o.anchorReference==="anchorEl")){var e=Z(o.anchorEl);if(e&&e.nodeType===1){var t=e.getBoundingClientRect();if(t.top===0&&t.left===0&&t.right===0&&t.bottom===0)return new Error(["Material-UI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(` `))}else return new Error(["Material-UI: The `anchorEl` prop provided to the component is invalid.","It should be an Element instance but it's `".concat(e,"` instead.")].join(` `))}return null}),anchorOrigin:n.shape({horizontal:n.oneOfType([n.oneOf(["center","left","right"]),n.number]).isRequired,vertical:n.oneOfType([n.oneOf(["bottom","center","top"]),n.number]).isRequired}),anchorPosition:n.shape({left:n.number.isRequired,top:n.number.isRequired}),anchorReference:n.oneOf(["anchorEl","anchorPosition","none"]),children:n.node,classes:n.object,className:n.string,container:n.oneOfType([oe,n.instanceOf(r.Component),n.func]),elevation:n.number,getContentAnchorEl:n.func,marginThreshold:n.number,onClose:n.func,onEnter:M(n.func,"Use the `TransitionProps` prop instead."),onEntered:M(n.func,"Use the `TransitionProps` prop instead."),onEntering:M(n.func,"Use the `TransitionProps` prop instead."),onExit:M(n.func,"Use the `TransitionProps` prop instead."),onExited:M(n.func,"Use the `TransitionProps` prop instead."),onExiting:M(n.func,"Use the `TransitionProps` prop instead."),open:n.bool.isRequired,PaperProps:n.shape({component:qe}),transformOrigin:n.shape({horizontal:n.oneOfType([n.oneOf(["center","left","right"]),n.number]).isRequired,vertical:n.oneOfType([n.oneOf(["bottom","center","top"]),n.number]).isRequired}),TransitionComponent:n.elementType,transitionDuration:n.oneOfType([n.oneOf(["auto"]),n.number,n.shape({appear:n.number,enter:n.number,exit:n.number})]),TransitionProps:n.object};const Qe=ie(Je,{name:"MuiPopover"})(Ce);function ne(o,e,t){return o===e?o.firstChild:e&&e.nextElementSibling?e.nextElementSibling:t?null:o.firstChild}function Te(o,e,t){return o===e?t?o.firstChild:o.lastChild:e&&e.previousElementSibling?e.previousElementSibling:t?null:o.lastChild}function xe(o,e){if(e===void 0)return!0;var t=o.innerText;return t===void 0&&(t=o.textContent),t=t.trim().toLowerCase(),t.length===0?!1:e.repeating?t[0]===e.keys[0]:t.indexOf(e.keys.join(""))===0}function J(o,e,t,v,p,y){for(var h=!1,s=p(o,e,e?t:!1);s;){if(s===o.firstChild){if(h)return;h=!0}var I=v?!1:s.disabled||s.getAttribute("aria-disabled")==="true";if(!s.hasAttribute("tabindex")||!xe(s,y)||I)s=p(o,s,t);else{s.focus();return}}}var Ze=typeof window>"u"?r.useEffect:r.useLayoutEffect,Me=r.forwardRef(function(e,t){var v=e.actions,p=e.autoFocus,y=p===void 0?!1:p,h=e.autoFocusItem,s=h===void 0?!1:h,I=e.children,w=e.className,F=e.disabledItemsFocusable,P=F===void 0?!1:F,D=e.disableListWrap,x=D===void 0?!1:D,L=e.onKeyDown,$=e.variant,j=$===void 0?"selectedMenu":$,A=Q(e,["actions","autoFocus","autoFocusItem","children","className","disabledItemsFocusable","disableListWrap","onKeyDown","variant"]),d=r.useRef(null),_=r.useRef({keys:[],repeating:!0,previousKeyMatched:!0,lastTime:null});Ze(function(){y&&d.current.focus()},[y]),r.useImperativeHandle(v,function(){return{adjustStyleForScrollbar:function(u,c){var T=!d.current.style.width;if(u.clientHeight<d.current.clientHeight&&T){var g="".concat(Ue(),"px");d.current.style[c.direction==="rtl"?"paddingLeft":"paddingRight"]=g,d.current.style.width="calc(100% + ".concat(g,")")}return d.current}}},[]);var z=function(u){var c=d.current,T=u.key,g=te(c).activeElement;if(T==="ArrowDown")u.preventDefault(),J(c,g,x,P,ne);else if(T==="ArrowUp")u.preventDefault(),J(c,g,x,P,Te);else if(T==="Home")u.preventDefault(),J(c,null,x,P,ne);else if(T==="End")u.preventDefault(),J(c,null,x,P,Te);else if(T.length===1){var l=_.current,S=T.toLowerCase(),R=performance.now();l.keys.length>0&&(R-l.lastTime>500?(l.keys=[],l.repeating=!0,l.previousKeyMatched=!0):l.repeating&&S!==l.keys[0]&&(l.repeating=!1)),l.lastTime=R,l.keys.push(S);var W=g&&!l.repeating&&xe(g,l);l.previousKeyMatched&&(W||J(c,g,!1,P,ne,l))?u.preventDefault():l.previousKeyMatched=!1}L&&L(u)},H=r.useCallback(function(a){d.current=re.findDOMNode(a)},[]),K=ze(H,t),N=-1;r.Children.forEach(I,function(a,u){r.isValidElement(a)&&(we.isFragment(a)&&console.error(["Material-UI: The Menu component doesn't accept a Fragment as a child.","Consider providing an array instead."].join(` `)),a.props.disabled||(j==="selectedMenu"&&a.props.selected||N===-1)&&(N=u))});var V=r.Children.map(I,function(a,u){if(u===N){var c={};return s&&(c.autoFocus=!0),a.props.tabIndex===void 0&&j==="selectedMenu"&&(c.tabIndex=0),r.cloneElement(a,c)}return a});return r.createElement(Ve,C({role:"menu",ref:K,className:w,onKeyDown:z,tabIndex:y?0:-1},A),V)});Me.propTypes={autoFocus:n.bool,autoFocusItem:n.bool,children:n.node,className:n.string,disabledItemsFocusable:n.bool,disableListWrap:n.bool,onKeyDown:n.func,variant:n.oneOf(["menu","selectedMenu"])};const en=Me;var Oe={vertical:"top",horizontal:"right"},Ie={vertical:"top",horizontal:"left"},nn={paper:{maxHeight:"calc(100% - 96px)",WebkitOverflowScrolling:"touch"},list:{outline:0}},Re=r.forwardRef(function(e,t){var v=e.autoFocus,p=v===void 0?!0:v,y=e.children,h=e.classes,s=e.disableAutoFocusItem,I=s===void 0?!1:s,w=e.MenuListProps,F=w===void 0?{}:w,P=e.onClose,D=e.onEntering,x=e.open,L=e.PaperProps,$=L===void 0?{}:L,j=e.PopoverClasses,A=e.transitionDuration,d=A===void 0?"auto":A,_=e.TransitionProps;_=_===void 0?{}:_;var z=_.onEntering,H=Q(_,["onEntering"]),K=e.variant,N=K===void 0?"selectedMenu":K,V=Q(e,["autoFocus","children","classes","disableAutoFocusItem","MenuListProps","onClose","onEntering","open","PaperProps","PopoverClasses","transitionDuration","TransitionProps","variant"]),a=He(),u=p&&!I&&x,c=r.useRef(null),T=r.useRef(null),g=function(){return T.current},l=function(b,Y){c.current&&c.current.adjustStyleForScrollbar(b,a),D&&D(b,Y),z&&z(b,Y)},S=function(b){b.key==="Tab"&&(b.preventDefault(),P&&P(b,"tabKeyDown"))},R=-1;r.Children.map(y,function(O,b){r.isValidElement(O)&&(we.isFragment(O)&&console.error(["Material-UI: The Menu component doesn't accept a Fragment as a child.","Consider providing an array instead."].join(` `)),O.props.disabled||(N!=="menu"&&O.props.selected||R===-1)&&(R=b))});var W=r.Children.map(y,function(O,b){return b===R?r.cloneElement(O,{ref:function(G){T.current=re.findDOMNode(G),Ke(O.ref,G)}}):O});return r.createElement(Qe,C({getContentAnchorEl:g,classes:j,onClose:P,TransitionProps:C({onEntering:l},H),anchorOrigin:a.direction==="rtl"?Oe:Ie,transformOrigin:a.direction==="rtl"?Oe:Ie,PaperProps:C({},$,{classes:C({},$.classes,{root:h.paper})}),open:x,ref:t,transitionDuration:d},V),r.createElement(en,C({onKeyDown:S,actions:c,autoFocus:p&&(R===-1||I),autoFocusItem:u,variant:N},F,{className:ee(h.list,F.className)}),W))});Re.propTypes={anchorEl:n.oneOfType([oe,n.func]),autoFocus:n.bool,children:n.node,classes:n.object,disableAutoFocusItem:n.bool,MenuListProps:n.object,onClose:n.func,onEnter:M(n.func,"Use the `TransitionProps` prop instead."),onEntered:M(n.func,"Use the `TransitionProps` prop instead."),onEntering:M(n.func,"Use the `TransitionProps` prop instead."),onExit:M(n.func,"Use the `TransitionProps` prop instead."),onExited:M(n.func,"Use the `TransitionProps` prop instead."),onExiting:M(n.func,"Use the `TransitionProps` prop instead."),open:n.bool.isRequired,PaperProps:n.object,PopoverClasses:n.object,transitionDuration:n.oneOfType([n.oneOf(["auto"]),n.number,n.shape({appear:n.number,enter:n.number,exit:n.number})]),TransitionProps:n.object,variant:n.oneOf(["menu","selectedMenu"])};const hn=ie(nn,{name:"MuiMenu"})(Re);var tn=function(e){return{root:C({},e.typography.body1,_e({minHeight:48,paddingTop:6,paddingBottom:6,boxSizing:"border-box",width:"auto",overflow:"hidden",whiteSpace:"nowrap"},e.breakpoints.up("sm"),{minHeight:"auto"})),gutters:{},selected:{},dense:C({},e.typography.body2,{minHeight:"auto"})}},Fe=r.forwardRef(function(e,t){var v=e.classes,p=e.className,y=e.component,h=y===void 0?"li":y,s=e.disableGutters,I=s===void 0?!1:s,w=e.ListItemClasses,F=e.role,P=F===void 0?"menuitem":F,D=e.selected,x=e.tabIndex,L=Q(e,["classes","className","component","disableGutters","ListItemClasses","role","selected","tabIndex"]),$;return e.disabled||($=x!==void 0?x:-1),r.createElement(Ye,C({button:!0,role:P,tabIndex:$,component:h,selected:D,disableGutters:I,classes:C({dense:v.dense},w),className:ee(v.root,p,D&&v.selected,!I&&v.gutters),ref:t},L))});Fe.propTypes={children:n.node,classes:n.object.isRequired,className:n.string,component:n.elementType,dense:n.bool,disabled:n.bool,disableGutters:n.bool,ListItemClasses:n.object,role:n.string,selected:n.bool,tabIndex:n.number};const mn=ie(tn,{name:"MuiMenuItem"})(Fe);export{hn as M,mn as a};