{"version":3,"sources":["../node_modules/@material-ui/lab/esm/TreeView/TreeView.js","../node_modules/@material-ui/lab/esm/TabList/TabList.js","../node_modules/@material-ui/lab/esm/TabContext/TabContext.js","../node_modules/@material-ui/lab/esm/TreeView/TreeViewContext.js","../node_modules/@material-ui/lab/esm/internal/svg-icons/Close.js","../node_modules/@material-ui/lab/esm/internal/svg-icons/ArrowDropDown.js","../node_modules/@material-ui/lab/esm/useAutocomplete/useAutocomplete.js","../node_modules/@material-ui/lab/esm/internal/svg-icons/Add.js","../node_modules/@material-ui/lab/esm/TreeItem/TreeItem.js","../node_modules/@material-ui/lab/esm/TabPanel/TabPanel.js","../node_modules/@material-ui/lab/node_modules/react-is/index.js","../node_modules/@material-ui/lab/node_modules/react-is/cjs/react-is.production.min.js"],"names":["findNextFirstChar","firstChars","startIndex","char","i","length","defaultExpandedDefault","defaultSelectedDefault","TreeView","React","props","ref","children","classes","className","defaultCollapseIcon","defaultEndIcon","_props$defaultExpande","defaultExpanded","defaultExpandIcon","defaultParentIcon","_props$defaultSelecte","defaultSelected","_props$disableSelecti","disableSelection","_props$multiSelect","multiSelect","expandedProp","expanded","onNodeSelect","onNodeToggle","selectedProp","selected","other","_objectWithoutProperties","_React$useState","tabbable","setTabbable","_React$useState2","focusedNodeId","setFocusedNodeId","nodeMap","firstCharMap","visibleNodes","_useControlled","useControlled","controlled","default","name","state","_useControlled2","_slicedToArray","setExpandedState","_useControlled3","_useControlled4","setSelectedState","isExpanded","id","Array","isArray","indexOf","isSelected","getNextNode","nodeIndex","current","getPreviousNode","getLastNode","getFirstNode","focus","lastSelectedNode","lastSelectionWasRange","currentRangeSelection","handleRangeArrowSelect","event","nodes","base","start","next","filter","push","handleRangeSelect","end","range","a","b","aIndex","bIndex","Math","min","max","slice","getNodesInRange","newSelected","concat","handleMultipleSelect","value","handleSingleSelect","selectRange","stacked","arguments","undefined","_nodes$start","getNodesToRemove","map","forEach","node","cleanUpFirstCharMap","newMap","_extends","removeNodeFromNodeMap","parent","parentMap","parentChildren","c","oldFocusedNodeId","prevChildIds","_React$useState3","childrenCalculated","setChildrenCalculated","childIds","child","nodeId","arr1","arr2","arrayDiff","index","buildVisible","list","item","childs","noopSelection","TreeViewContext","Provider","icons","focusFirstNode","focusLastNode","focusNextNode","focusPreviousNode","focusByFirstCharacter","lowercaseChar","toLowerCase","firstCharIds","Object","keys","firstChar","expandAllSiblings","diff","newExpanded","toggleExpansion","oldTabbable","isFocused","selectNode","multiple","selectNextNode","selectPreviousNode","rangeSelectToFirst","rangeSelectToLast","selectAllNodes","isTabbable","getParent","mapFirstChar","addNodeToNodeMap","childrenIds","currentMap","childId","currentChildMap","role","clsx","root","withStyles","padding","margin","listStyle","TabList","childrenProp","context","useTabContext","TypeError","getPanelId","getTabId","Tabs","Context","TabContext","idPrefix","setId","round","random","useUniquePrefix","createSvgIcon","d","stripDiacritics","string","normalize","replace","findIndex","array","comp","defaultFilterOptions","config","_config$ignoreAccents","ignoreAccents","_config$ignoreCase","ignoreCase","limit","_config$matchFrom","matchFrom","stringify","_config$trim","trim","options","_ref","inputValue","getOptionLabel","input","filteredOptions","option","candidate","createFilterOptions","useAutocomplete","_props$autoComplete","autoComplete","_props$autoHighlight","autoHighlight","_props$autoSelect","autoSelect","_props$blurOnSelect","blurOnSelect","_props$clearOnBlur","clearOnBlur","freeSolo","_props$clearOnEscape","clearOnEscape","_props$componentName","componentName","_props$debug","debug","_props$defaultValue","defaultValue","_props$disableClearab","disableClearable","_props$disableCloseOn","disableCloseOnSelect","_props$disabledItemsF","disabledItemsFocusable","_props$disableListWra","disableListWrap","_props$filterOptions","filterOptions","_props$filterSelected","filterSelectedOptions","_props$freeSolo","getOptionDisabled","_props$getOptionLabel","getOptionLabelProp","_props$getOptionSelec","getOptionSelected","groupBy","_props$handleHomeEndK","handleHomeEndKeys","idProp","_props$includeInputIn","includeInputInList","inputValueProp","_props$multiple","onChange","onClose","onHighlightChange","onInputChange","onOpen","openProp","open","_props$openOnFocus","openOnFocus","_props$selectOnFocus","selectOnFocus","valueProp","useId","ignoreFocus","firstFocus","inputRef","listboxRef","anchorEl","setAnchorEl","focusedTag","setFocusedTag","defaultHighlighted","highlightedIndexRef","setValue","setInputValue","focused","setFocused","resetInputValue","useEventCallback","newValue","newInputValue","optionLabel","_useControlled5","_useControlled6","setOpenState","inputValueIsSelectedValue","popupOpen","some","value2","focusTag","tagToFocus","querySelector","setHighlightedIndex","_ref2","_ref2$reason","reason","removeAttribute","setAttribute","prev","listboxNode","parentElement","scrollHeight","clientHeight","element","scrollBottom","scrollTop","elementBottom","offsetTop","offsetHeight","changeHighlightedIndex","_ref3","_ref3$direction","direction","_ref3$reason","nextIndex","nextFocus","nextFocusDisabled","disabled","getAttribute","hasAttribute","validOptionIndex","maxIndex","newIndex","abs","getNextIndex","setSelectionRange","syncHighlightedIndex","valueItem","currentOption","val","itemIndex","optionItem","handleListboxRef","setRef","handleOpen","handleClose","handleValue","details","isTouch","selectNewValue","reasonProp","origin","splice","blur","handleFocusTag","nextTag","validTagIndex","handleClear","handleKeyDown","key","preventDefault","which","stopPropagation","onKeyDown","handleFocus","handleBlur","document","activeElement","handleInputChange","target","handleOptionMouseOver","Number","currentTarget","handleOptionTouchStart","handleOptionClick","handleTagDelete","handlePopupIndicator","handleMouseDown","handleClick","selectionEnd","selectionStart","select","handleInputMouseDown","dirty","groupedOptions","Map","reduce","acc","group","getRootProps","onMouseDown","onClick","getInputLabelProps","htmlFor","getInputProps","onBlur","onFocus","autoCapitalize","spellCheck","getClearProps","tabIndex","getPopupIndicatorProps","getTagProps","_ref4","onDelete","getListboxProps","getOptionProps","_ref5","onMouseOver","onTouchStart","TreeItem","collapseIcon","endIcon","expandIcon","iconProp","icon","label","onLabelClick","onIconClick","_props$TransitionComp","TransitionComponent","Collapse","TransitionProps","_React$useContext","contextIcons","nodeRef","contentRef","handleRef","useForkRef","expandable","Boolean","theme","useTheme","ariaSelected","handleNextArrow","handlePreviousArrow","textContent","substring","flag","altKey","str","ctrlPressed","ctrlKey","metaKey","shiftKey","match","content","defaultPrevented","iconContainer","Typography","component","unmountOnExit","in","outline","WebkitTapHighlightColor","backgroundColor","palette","action","hover","fade","primary","main","selectedOpacity","hoverOpacity","marginLeft","width","display","alignItems","cursor","marginRight","flexShrink","justifyContent","fontSize","paddingLeft","position","TabPanel","tabId","hidden","spacing","module","exports","require","e","f","g","h","k","l","m","n","p","q","r","u","v","w","Symbol","for","x","y","t","$$typeof","type","z","A","B","C","D","E","F","G","H","I","ContextConsumer","ContextProvider","Element","ForwardRef","Fragment","Lazy","Memo","Portal","Profiler","StrictMode","Suspense","isAsyncMode","isConcurrentMode","isContextConsumer","isContextProvider","isElement","isForwardRef","isFragment","isLazy","isMemo","isPortal","isProfiler","isStrictMode","isSuspense","isValidElementType","typeOf"],"mappings":";sHAAA,iEA4BA,IAAIA,EAAoB,SAA2BC,EAAYC,EAAYC,GACzE,IAAK,IAAIC,EAAIF,EAAYE,EAAIH,EAAWI,OAAQD,GAAK,EACnD,GAAID,IAASF,EAAWG,GACtB,OAAOA,EAIX,OAAQ,CACV,EAEIE,EAAyB,GACzBC,EAAyB,GACzBC,EAAwBC,cAAiB,SAAkBC,EAAOC,GACpE,IAAIC,EAAWF,EAAME,SACjBC,EAAUH,EAAMG,QAChBC,EAAYJ,EAAMI,UAClBC,EAAsBL,EAAMK,oBAC5BC,EAAiBN,EAAMM,eACvBC,EAAwBP,EAAMQ,gBAC9BA,OAA4C,IAA1BD,EAAmCX,EAAyBW,EAC9EE,EAAoBT,EAAMS,kBAC1BC,EAAoBV,EAAMU,kBAC1BC,EAAwBX,EAAMY,gBAC9BA,OAA4C,IAA1BD,EAAmCd,EAAyBc,EAC9EE,EAAwBb,EAAMc,iBAC9BA,OAA6C,IAA1BD,GAA2CA,EAC9DE,EAAqBf,EAAMgB,YAC3BA,OAAqC,IAAvBD,GAAwCA,EACtDE,EAAejB,EAAMkB,SACrBC,EAAenB,EAAMmB,aACrBC,EAAepB,EAAMoB,aACrBC,EAAerB,E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,EAAEsa,WAAWjB,GAAGrZ,EAAEsa,WAAWhB,GAAGtZ,EAAEsa,WAAWf,GAAGvZ,EAAEsa,WAAWR,GAAG9Z,EAAEsa,WAAWV,GAAG5Z,EAAE,KAAK6Z,EAAQ,EACzeZ,EAAQ0D,OAAOvC,C","file":"static/js/main~94adf935.bede0685.chunk.js","sourcesContent":["import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport PropTypes from 'prop-types';\nimport { withStyles } from '@material-ui/core/styles';\nimport { useControlled } from '@material-ui/core/utils';\nimport TreeViewContext from './TreeViewContext';\nexport var styles = {\n /* Styles applied to the root element. */\n root: {\n padding: 0,\n margin: 0,\n listStyle: 'none'\n }\n};\n\nfunction arrayDiff(arr1, arr2) {\n if (arr1.length !== arr2.length) return true;\n\n for (var i = 0; i < arr1.length; i += 1) {\n if (arr1[i] !== arr2[i]) return true;\n }\n\n return false;\n}\n\nvar findNextFirstChar = function findNextFirstChar(firstChars, startIndex, char) {\n for (var i = startIndex; i < firstChars.length; i += 1) {\n if (char === firstChars[i]) {\n return i;\n }\n }\n\n return -1;\n};\n\nvar defaultExpandedDefault = [];\nvar defaultSelectedDefault = [];\nvar TreeView = /*#__PURE__*/React.forwardRef(function TreeView(props, ref) {\n var children = props.children,\n classes = props.classes,\n className = props.className,\n defaultCollapseIcon = props.defaultCollapseIcon,\n defaultEndIcon = props.defaultEndIcon,\n _props$defaultExpande = props.defaultExpanded,\n defaultExpanded = _props$defaultExpande === void 0 ? defaultExpandedDefault : _props$defaultExpande,\n defaultExpandIcon = props.defaultExpandIcon,\n defaultParentIcon = props.defaultParentIcon,\n _props$defaultSelecte = props.defaultSelected,\n defaultSelected = _props$defaultSelecte === void 0 ? defaultSelectedDefault : _props$defaultSelecte,\n _props$disableSelecti = props.disableSelection,\n disableSelection = _props$disableSelecti === void 0 ? false : _props$disableSelecti,\n _props$multiSelect = props.multiSelect,\n multiSelect = _props$multiSelect === void 0 ? false : _props$multiSelect,\n expandedProp = props.expanded,\n onNodeSelect = props.onNodeSelect,\n onNodeToggle = props.onNodeToggle,\n selectedProp = props.selected,\n other = _objectWithoutProperties(props, [\"children\", \"classes\", \"className\", \"defaultCollapseIcon\", \"defaultEndIcon\", \"defaultExpanded\", \"defaultExpandIcon\", \"defaultParentIcon\", \"defaultSelected\", \"disableSelection\", \"multiSelect\", \"expanded\", \"onNodeSelect\", \"onNodeToggle\", \"selected\"]);\n\n var _React$useState = React.useState(null),\n tabbable = _React$useState[0],\n setTabbable = _React$useState[1];\n\n var _React$useState2 = React.useState(null),\n focusedNodeId = _React$useState2[0],\n setFocusedNodeId = _React$useState2[1];\n\n var nodeMap = React.useRef({});\n var firstCharMap = React.useRef({});\n var visibleNodes = React.useRef([]);\n\n var _useControlled = useControlled({\n controlled: expandedProp,\n default: defaultExpanded,\n name: 'TreeView',\n state: 'expanded'\n }),\n _useControlled2 = _slicedToArray(_useControlled, 2),\n expanded = _useControlled2[0],\n setExpandedState = _useControlled2[1];\n\n var _useControlled3 = useControlled({\n controlled: selectedProp,\n default: defaultSelected,\n name: 'TreeView',\n state: 'selected'\n }),\n _useControlled4 = _slicedToArray(_useControlled3, 2),\n selected = _useControlled4[0],\n setSelectedState = _useControlled4[1];\n /*\n * Status Helpers\n */\n\n\n var isExpanded = React.useCallback(function (id) {\n return Array.isArray(expanded) ? expanded.indexOf(id) !== -1 : false;\n }, [expanded]);\n var isSelected = React.useCallback(function (id) {\n return Array.isArray(selected) ? selected.indexOf(id) !== -1 : selected === id;\n }, [selected]);\n\n var isTabbable = function isTabbable(id) {\n return tabbable === id;\n };\n\n var isFocused = function isFocused(id) {\n return focusedNodeId === id;\n };\n /*\n * Node Helpers\n */\n\n\n var getNextNode = function getNextNode(id) {\n var nodeIndex = visibleNodes.current.indexOf(id);\n\n if (nodeIndex !== -1 && nodeIndex + 1 < visibleNodes.current.length) {\n return visibleNodes.current[nodeIndex + 1];\n }\n\n return null;\n };\n\n var getPreviousNode = function getPreviousNode(id) {\n var nodeIndex = visibleNodes.current.indexOf(id);\n\n if (nodeIndex !== -1 && nodeIndex - 1 >= 0) {\n return visibleNodes.current[nodeIndex - 1];\n }\n\n return null;\n };\n\n var getLastNode = function getLastNode() {\n return visibleNodes.current[visibleNodes.current.length - 1];\n };\n\n var getFirstNode = function getFirstNode() {\n return visibleNodes.current[0];\n };\n\n var getParent = function getParent(id) {\n return nodeMap.current[id].parent;\n };\n\n var getNodesInRange = function getNodesInRange(a, b) {\n var aIndex = visibleNodes.current.indexOf(a);\n var bIndex = visibleNodes.current.indexOf(b);\n var start = Math.min(aIndex, bIndex);\n var end = Math.max(aIndex, bIndex);\n return visibleNodes.current.slice(start, end + 1);\n };\n /*\n * Focus Helpers\n */\n\n\n var focus = function focus(id) {\n if (id) {\n setTabbable(id);\n setFocusedNodeId(id);\n }\n };\n\n var focusNextNode = function focusNextNode(id) {\n return focus(getNextNode(id));\n };\n\n var focusPreviousNode = function focusPreviousNode(id) {\n return focus(getPreviousNode(id));\n };\n\n var focusFirstNode = function focusFirstNode() {\n return focus(getFirstNode());\n };\n\n var focusLastNode = function focusLastNode() {\n return focus(getLastNode());\n };\n\n var focusByFirstCharacter = function focusByFirstCharacter(id, char) {\n var start;\n var index;\n var lowercaseChar = char.toLowerCase();\n var firstCharIds = [];\n var firstChars = []; // This really only works since the ids are strings\n\n Object.keys(firstCharMap.current).forEach(function (nodeId) {\n var firstChar = firstCharMap.current[nodeId];\n var map = nodeMap.current[nodeId];\n var visible = map.parent ? isExpanded(map.parent) : true;\n\n if (visible) {\n firstCharIds.push(nodeId);\n firstChars.push(firstChar);\n }\n }); // Get start index for search based on position of currentItem\n\n start = firstCharIds.indexOf(id) + 1;\n\n if (start === nodeMap.current.length) {\n start = 0;\n } // Check remaining slots in the menu\n\n\n index = findNextFirstChar(firstChars, start, lowercaseChar); // If not found in remaining slots, check from beginning\n\n if (index === -1) {\n index = findNextFirstChar(firstChars, 0, lowercaseChar);\n } // If match was found...\n\n\n if (index > -1) {\n focus(firstCharIds[index]);\n }\n };\n /*\n * Expansion Helpers\n */\n\n\n var toggleExpansion = function toggleExpansion(event) {\n var value = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : focusedNodeId;\n var newExpanded;\n\n if (expanded.indexOf(value) !== -1) {\n newExpanded = expanded.filter(function (id) {\n return id !== value;\n });\n setTabbable(function (oldTabbable) {\n var map = nodeMap.current[oldTabbable];\n\n if (oldTabbable && (map && map.parent ? map.parent.id : null) === value) {\n return value;\n }\n\n return oldTabbable;\n });\n } else {\n newExpanded = [value].concat(expanded);\n }\n\n if (onNodeToggle) {\n onNodeToggle(event, newExpanded);\n }\n\n setExpandedState(newExpanded);\n };\n\n var expandAllSiblings = function expandAllSiblings(event, id) {\n var map = nodeMap.current[id];\n var parent = nodeMap.current[map.parent];\n var diff;\n\n if (parent) {\n diff = parent.children.filter(function (child) {\n return !isExpanded(child);\n });\n } else {\n var topLevelNodes = nodeMap.current[-1].children;\n diff = topLevelNodes.filter(function (node) {\n return !isExpanded(node);\n });\n }\n\n var newExpanded = expanded.concat(diff);\n\n if (diff.length > 0) {\n setExpandedState(newExpanded);\n\n if (onNodeToggle) {\n onNodeToggle(event, newExpanded);\n }\n }\n };\n /*\n * Selection Helpers\n */\n\n\n var lastSelectedNode = React.useRef(null);\n var lastSelectionWasRange = React.useRef(false);\n var currentRangeSelection = React.useRef([]);\n\n var handleRangeArrowSelect = function handleRangeArrowSelect(event, nodes) {\n var base = selected;\n var start = nodes.start,\n next = nodes.next,\n current = nodes.current;\n\n if (!next || !current) {\n return;\n }\n\n if (currentRangeSelection.current.indexOf(current) === -1) {\n currentRangeSelection.current = [];\n }\n\n if (lastSelectionWasRange.current) {\n if (currentRangeSelection.current.indexOf(next) !== -1) {\n base = base.filter(function (id) {\n return id === start || id !== current;\n });\n currentRangeSelection.current = currentRangeSelection.current.filter(function (id) {\n return id === start || id !== current;\n });\n } else {\n base.push(next);\n currentRangeSelection.current.push(next);\n }\n } else {\n base.push(next);\n currentRangeSelection.current.push(current, next);\n }\n\n if (onNodeSelect) {\n onNodeSelect(event, base);\n }\n\n setSelectedState(base);\n };\n\n var handleRangeSelect = function handleRangeSelect(event, nodes) {\n var base = selected;\n var start = nodes.start,\n end = nodes.end; // If last selection was a range selection ignore nodes that were selected.\n\n if (lastSelectionWasRange.current) {\n base = selected.filter(function (id) {\n return currentRangeSelection.current.indexOf(id) === -1;\n });\n }\n\n var range = getNodesInRange(start, end);\n currentRangeSelection.current = range;\n var newSelected = base.concat(range);\n newSelected = newSelected.filter(function (id, i) {\n return newSelected.indexOf(id) === i;\n });\n\n if (onNodeSelect) {\n onNodeSelect(event, newSelected);\n }\n\n setSelectedState(newSelected);\n };\n\n var handleMultipleSelect = function handleMultipleSelect(event, value) {\n var newSelected = [];\n\n if (selected.indexOf(value) !== -1) {\n newSelected = selected.filter(function (id) {\n return id !== value;\n });\n } else {\n newSelected = [value].concat(selected);\n }\n\n if (onNodeSelect) {\n onNodeSelect(event, newSelected);\n }\n\n setSelectedState(newSelected);\n };\n\n var handleSingleSelect = function handleSingleSelect(event, value) {\n var newSelected = multiSelect ? [value] : value;\n\n if (onNodeSelect) {\n onNodeSelect(event, newSelected);\n }\n\n setSelectedState(newSelected);\n };\n\n var selectNode = function selectNode(event, id) {\n var multiple = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n\n if (id) {\n if (multiple) {\n handleMultipleSelect(event, id);\n } else {\n handleSingleSelect(event, id);\n }\n\n lastSelectedNode.current = id;\n lastSelectionWasRange.current = false;\n currentRangeSelection.current = [];\n return true;\n }\n\n return false;\n };\n\n var selectRange = function selectRange(event, nodes) {\n var stacked = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;\n var _nodes$start = nodes.start,\n start = _nodes$start === void 0 ? lastSelectedNode.current : _nodes$start,\n end = nodes.end,\n current = nodes.current;\n\n if (stacked) {\n handleRangeArrowSelect(event, {\n start: start,\n next: end,\n current: current\n });\n } else {\n handleRangeSelect(event, {\n start: start,\n end: end\n });\n }\n\n lastSelectionWasRange.current = true;\n return true;\n };\n\n var rangeSelectToFirst = function rangeSelectToFirst(event, id) {\n if (!lastSelectedNode.current) {\n lastSelectedNode.current = id;\n }\n\n var start = lastSelectionWasRange.current ? lastSelectedNode.current : id;\n return selectRange(event, {\n start: start,\n end: getFirstNode()\n });\n };\n\n var rangeSelectToLast = function rangeSelectToLast(event, id) {\n if (!lastSelectedNode.current) {\n lastSelectedNode.current = id;\n }\n\n var start = lastSelectionWasRange.current ? lastSelectedNode.current : id;\n return selectRange(event, {\n start: start,\n end: getLastNode()\n });\n };\n\n var selectNextNode = function selectNextNode(event, id) {\n return selectRange(event, {\n end: getNextNode(id),\n current: id\n }, true);\n };\n\n var selectPreviousNode = function selectPreviousNode(event, id) {\n return selectRange(event, {\n end: getPreviousNode(id),\n current: id\n }, true);\n };\n\n var selectAllNodes = function selectAllNodes(event) {\n return selectRange(event, {\n start: getFirstNode(),\n end: getLastNode()\n });\n };\n /*\n * Mapping Helpers\n */\n\n\n var addNodeToNodeMap = function addNodeToNodeMap(id, childrenIds) {\n var currentMap = nodeMap.current[id];\n nodeMap.current[id] = _extends({}, currentMap, {\n children: childrenIds,\n id: id\n });\n childrenIds.forEach(function (childId) {\n var currentChildMap = nodeMap.current[childId];\n nodeMap.current[childId] = _extends({}, currentChildMap, {\n parent: id,\n id: childId\n });\n });\n };\n\n var getNodesToRemove = React.useCallback(function (id) {\n var map = nodeMap.current[id];\n var nodes = [];\n\n if (map) {\n nodes.push(id);\n\n if (map.children) {\n nodes.concat(map.children);\n map.children.forEach(function (node) {\n nodes.concat(getNodesToRemove(node));\n });\n }\n }\n\n return nodes;\n }, []);\n var cleanUpFirstCharMap = React.useCallback(function (nodes) {\n var newMap = _extends({}, firstCharMap.current);\n\n nodes.forEach(function (node) {\n if (newMap[node]) {\n delete newMap[node];\n }\n });\n firstCharMap.current = newMap;\n }, []);\n var removeNodeFromNodeMap = React.useCallback(function (id) {\n var nodes = getNodesToRemove(id);\n cleanUpFirstCharMap(nodes);\n\n var newMap = _extends({}, nodeMap.current);\n\n nodes.forEach(function (node) {\n var map = newMap[node];\n\n if (map) {\n if (map.parent) {\n var parentMap = newMap[map.parent];\n\n if (parentMap && parentMap.children) {\n var parentChildren = parentMap.children.filter(function (c) {\n return c !== node;\n });\n newMap[map.parent] = _extends({}, parentMap, {\n children: parentChildren\n });\n }\n }\n\n delete newMap[node];\n }\n });\n nodeMap.current = newMap;\n setFocusedNodeId(function (oldFocusedNodeId) {\n if (oldFocusedNodeId === id) {\n return null;\n }\n\n return oldFocusedNodeId;\n });\n }, [getNodesToRemove, cleanUpFirstCharMap]);\n\n var mapFirstChar = function mapFirstChar(id, firstChar) {\n firstCharMap.current[id] = firstChar;\n };\n\n var prevChildIds = React.useRef([]);\n\n var _React$useState3 = React.useState(false),\n childrenCalculated = _React$useState3[0],\n setChildrenCalculated = _React$useState3[1];\n\n React.useEffect(function () {\n var childIds = [];\n React.Children.forEach(children, function (child) {\n if ( /*#__PURE__*/React.isValidElement(child) && child.props.nodeId) {\n childIds.push(child.props.nodeId);\n }\n });\n\n if (arrayDiff(prevChildIds.current, childIds)) {\n nodeMap.current[-1] = {\n parent: null,\n children: childIds\n };\n childIds.forEach(function (id, index) {\n if (index === 0) {\n setTabbable(id);\n }\n });\n visibleNodes.current = nodeMap.current[-1].children;\n prevChildIds.current = childIds;\n setChildrenCalculated(true);\n }\n }, [children]);\n React.useEffect(function () {\n var buildVisible = function buildVisible(nodes) {\n var list = [];\n\n for (var i = 0; i < nodes.length; i += 1) {\n var item = nodes[i];\n list.push(item);\n var childs = nodeMap.current[item].children;\n\n if (isExpanded(item) && childs) {\n list = list.concat(buildVisible(childs));\n }\n }\n\n return list;\n };\n\n if (childrenCalculated) {\n visibleNodes.current = buildVisible(nodeMap.current[-1].children);\n }\n }, [expanded, childrenCalculated, isExpanded, children]);\n\n var noopSelection = function noopSelection() {\n return false;\n };\n\n return /*#__PURE__*/React.createElement(TreeViewContext.Provider, {\n value: {\n icons: {\n defaultCollapseIcon: defaultCollapseIcon,\n defaultExpandIcon: defaultExpandIcon,\n defaultParentIcon: defaultParentIcon,\n defaultEndIcon: defaultEndIcon\n },\n focus: focus,\n focusFirstNode: focusFirstNode,\n focusLastNode: focusLastNode,\n focusNextNode: focusNextNode,\n focusPreviousNode: focusPreviousNode,\n focusByFirstCharacter: focusByFirstCharacter,\n expandAllSiblings: expandAllSiblings,\n toggleExpansion: toggleExpansion,\n isExpanded: isExpanded,\n isFocused: isFocused,\n isSelected: isSelected,\n selectNode: disableSelection ? noopSelection : selectNode,\n selectRange: disableSelection ? noopSelection : selectRange,\n selectNextNode: disableSelection ? noopSelection : selectNextNode,\n selectPreviousNode: disableSelection ? noopSelection : selectPreviousNode,\n rangeSelectToFirst: disableSelection ? noopSelection : rangeSelectToFirst,\n rangeSelectToLast: disableSelection ? noopSelection : rangeSelectToLast,\n selectAllNodes: disableSelection ? noopSelection : selectAllNodes,\n isTabbable: isTabbable,\n multiSelect: multiSelect,\n getParent: getParent,\n mapFirstChar: mapFirstChar,\n addNodeToNodeMap: addNodeToNodeMap,\n removeNodeFromNodeMap: removeNodeFromNodeMap\n }\n }, /*#__PURE__*/React.createElement(\"ul\", _extends({\n role: \"tree\",\n \"aria-multiselectable\": multiSelect,\n className: clsx(classes.root, className),\n ref: ref\n }, other), children));\n});\nprocess.env.NODE_ENV !== \"production\" ? TreeView.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the d.ts file and run \"yarn proptypes\" |\n // ----------------------------------------------------------------------\n\n /**\n * The content of the component.\n */\n children: PropTypes.node,\n\n /**\n * Override or extend the styles applied to the component.\n * See [CSS API](#css) below for more details.\n */\n classes: PropTypes.object,\n\n /**\n * @ignore\n */\n className: PropTypes.string,\n\n /**\n * The default icon used to collapse the node.\n */\n defaultCollapseIcon: PropTypes.node,\n\n /**\n * The default icon displayed next to a end node. This is applied to all\n * tree nodes and can be overridden by the TreeItem `icon` prop.\n */\n defaultEndIcon: PropTypes.node,\n\n /**\n * Expanded node ids. (Uncontrolled)\n */\n defaultExpanded: PropTypes.arrayOf(PropTypes.string),\n\n /**\n * The default icon used to expand the node.\n */\n defaultExpandIcon: PropTypes.node,\n\n /**\n * The default icon displayed next to a parent node. This is applied to all\n * parent nodes and can be overridden by the TreeItem `icon` prop.\n */\n defaultParentIcon: PropTypes.node,\n\n /**\n * Selected node ids. (Uncontrolled)\n * When `multiSelect` is true this takes an array of strings; when false (default) a string.\n */\n defaultSelected: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string), PropTypes.string]),\n\n /**\n * If `true` selection is disabled.\n */\n disableSelection: PropTypes.bool,\n\n /**\n * Expanded node ids. (Controlled)\n */\n expanded: PropTypes.arrayOf(PropTypes.string),\n\n /**\n * If true `ctrl` and `shift` will trigger multiselect.\n */\n multiSelect: PropTypes.bool,\n\n /**\n * Callback fired when tree items are selected/unselected.\n *\n * @param {object} event The event source of the callback\n * @param {(array|string)} value of the selected nodes. When `multiSelect` is true\n * this is an array of strings; when false (default) a string.\n */\n onNodeSelect: PropTypes.func,\n\n /**\n * Callback fired when tree items are expanded/collapsed.\n *\n * @param {object} event The event source of the callback.\n * @param {array} nodeIds The ids of the expanded nodes.\n */\n onNodeToggle: PropTypes.func,\n\n /**\n * Selected node ids. (Controlled)\n * When `multiSelect` is true this takes an array of strings; when false (default) a string.\n */\n selected: PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.string), PropTypes.string])\n} : void 0;\nexport default withStyles(styles, {\n name: 'MuiTreeView'\n})(TreeView);","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport * as React from 'react';\nimport * as PropTypes from 'prop-types';\nimport Tabs from '@material-ui/core/Tabs';\nimport { useTabContext, getTabId, getPanelId } from '../TabContext';\nvar TabList = /*#__PURE__*/React.forwardRef(function TabList(props, ref) {\n var childrenProp = props.children,\n other = _objectWithoutProperties(props, [\"children\"]);\n\n var context = useTabContext();\n\n if (context === null) {\n throw new TypeError('No TabContext provided');\n }\n\n var children = React.Children.map(childrenProp, function (child) {\n return /*#__PURE__*/React.cloneElement(child, {\n // SOMEDAY: `Tabs` will set those themselves\n 'aria-controls': getPanelId(context, child.props.value),\n id: getTabId(context, child.props.value)\n });\n });\n return /*#__PURE__*/React.createElement(Tabs, _extends({}, other, {\n ref: ref,\n value: context.value\n }), children);\n});\nprocess.env.NODE_ENV !== \"production\" ? TabList.propTypes = {\n children: PropTypes.arrayOf(PropTypes.element)\n} : void 0;\nexport default TabList;","import * as React from 'react';\nimport * as PropTypes from 'prop-types';\n/**\n * @type {React.Context<{ idPrefix: string; value: string } | null>}\n */\n\nvar Context = React.createContext(null);\n\nif (process.env.NODE_ENV !== 'production') {\n Context.displayName = 'TabContext';\n}\n\nfunction useUniquePrefix() {\n var _React$useState = React.useState(null),\n id = _React$useState[0],\n setId = _React$useState[1];\n\n React.useEffect(function () {\n setId(\"mui-p-\".concat(Math.round(Math.random() * 1e5)));\n }, []);\n return id;\n}\n\nexport default function TabContext(props) {\n var children = props.children,\n value = props.value;\n var idPrefix = useUniquePrefix();\n var context = React.useMemo(function () {\n return {\n idPrefix: idPrefix,\n value: value\n };\n }, [idPrefix, value]);\n return /*#__PURE__*/React.createElement(Context.Provider, {\n value: context\n }, children);\n}\nprocess.env.NODE_ENV !== \"production\" ? TabContext.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the d.ts file and run \"yarn proptypes\" |\n // ----------------------------------------------------------------------\n\n /**\n * The content of the component.\n */\n children: PropTypes.node,\n\n /**\n * The value of the currently selected `Tab`.\n */\n value: PropTypes.string.isRequired\n} : void 0;\n/**\n * @returns {unknown}\n */\n\nexport function useTabContext() {\n return React.useContext(Context);\n}\nexport function getPanelId(context, value) {\n var idPrefix = context.idPrefix;\n\n if (idPrefix === null) {\n return null;\n }\n\n return \"\".concat(context.idPrefix, \"-P-\").concat(value);\n}\nexport function getTabId(context, value) {\n var idPrefix = context.idPrefix;\n\n if (idPrefix === null) {\n return null;\n }\n\n return \"\".concat(context.idPrefix, \"-T-\").concat(value);\n}","import * as React from 'react';\n/**\n * @ignore - internal component.\n */\n\nvar TreeViewContext = React.createContext({});\n\nif (process.env.NODE_ENV !== 'production') {\n TreeViewContext.displayName = 'TreeViewContext';\n}\n\nexport default TreeViewContext;","import * as React from 'react';\nimport { createSvgIcon } from '@material-ui/core/utils';\n/**\n * @ignore - internal component.\n */\n\nexport default createSvgIcon( /*#__PURE__*/React.createElement(\"path\", {\n d: \"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z\"\n}), 'Close');","import * as React from 'react';\nimport { createSvgIcon } from '@material-ui/core/utils';\n/**\n * @ignore - internal component.\n */\n\nexport default createSvgIcon( /*#__PURE__*/React.createElement(\"path\", {\n d: \"M7 10l5 5 5-5z\"\n}), 'ArrowDropDown');","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport _typeof from \"@babel/runtime/helpers/esm/typeof\";\n\n/* eslint-disable no-constant-condition */\nimport * as React from 'react';\nimport { setRef, useEventCallback, useControlled, unstable_useId as useId } from '@material-ui/core/utils'; // https://stackoverflow.com/questions/990904/remove-accents-diacritics-in-a-string-in-javascript\n// Give up on IE 11 support for this feature\n\nfunction stripDiacritics(string) {\n return typeof string.normalize !== 'undefined' ? string.normalize('NFD').replace(/[\\u0300-\\u036f]/g, '') : string;\n}\n\nexport function createFilterOptions() {\n var config = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n var _config$ignoreAccents = config.ignoreAccents,\n ignoreAccents = _config$ignoreAccents === void 0 ? true : _config$ignoreAccents,\n _config$ignoreCase = config.ignoreCase,\n ignoreCase = _config$ignoreCase === void 0 ? true : _config$ignoreCase,\n limit = config.limit,\n _config$matchFrom = config.matchFrom,\n matchFrom = _config$matchFrom === void 0 ? 'any' : _config$matchFrom,\n stringify = config.stringify,\n _config$trim = config.trim,\n trim = _config$trim === void 0 ? false : _config$trim;\n return function (options, _ref) {\n var inputValue = _ref.inputValue,\n getOptionLabel = _ref.getOptionLabel;\n var input = trim ? inputValue.trim() : inputValue;\n\n if (ignoreCase) {\n input = input.toLowerCase();\n }\n\n if (ignoreAccents) {\n input = stripDiacritics(input);\n }\n\n var filteredOptions = options.filter(function (option) {\n var candidate = (stringify || getOptionLabel)(option);\n\n if (ignoreCase) {\n candidate = candidate.toLowerCase();\n }\n\n if (ignoreAccents) {\n candidate = stripDiacritics(candidate);\n }\n\n return matchFrom === 'start' ? candidate.indexOf(input) === 0 : candidate.indexOf(input) > -1;\n });\n return typeof limit === 'number' ? filteredOptions.slice(0, limit) : filteredOptions;\n };\n} // To replace with .findIndex() once we stop IE 11 support.\n\nfunction findIndex(array, comp) {\n for (var i = 0; i < array.length; i += 1) {\n if (comp(array[i])) {\n return i;\n }\n }\n\n return -1;\n}\n\nvar defaultFilterOptions = createFilterOptions(); // Number of options to jump in list box when pageup and pagedown keys are used.\n\nvar pageSize = 5;\nexport default function useAutocomplete(props) {\n var _props$autoComplete = props.autoComplete,\n autoComplete = _props$autoComplete === void 0 ? false : _props$autoComplete,\n _props$autoHighlight = props.autoHighlight,\n autoHighlight = _props$autoHighlight === void 0 ? false : _props$autoHighlight,\n _props$autoSelect = props.autoSelect,\n autoSelect = _props$autoSelect === void 0 ? false : _props$autoSelect,\n _props$blurOnSelect = props.blurOnSelect,\n blurOnSelect = _props$blurOnSelect === void 0 ? false : _props$blurOnSelect,\n _props$clearOnBlur = props.clearOnBlur,\n clearOnBlur = _props$clearOnBlur === void 0 ? !props.freeSolo : _props$clearOnBlur,\n _props$clearOnEscape = props.clearOnEscape,\n clearOnEscape = _props$clearOnEscape === void 0 ? false : _props$clearOnEscape,\n _props$componentName = props.componentName,\n componentName = _props$componentName === void 0 ? 'useAutocomplete' : _props$componentName,\n _props$debug = props.debug,\n debug = _props$debug === void 0 ? false : _props$debug,\n _props$defaultValue = props.defaultValue,\n defaultValue = _props$defaultValue === void 0 ? props.multiple ? [] : null : _props$defaultValue,\n _props$disableClearab = props.disableClearable,\n disableClearable = _props$disableClearab === void 0 ? false : _props$disableClearab,\n _props$disableCloseOn = props.disableCloseOnSelect,\n disableCloseOnSelect = _props$disableCloseOn === void 0 ? false : _props$disableCloseOn,\n _props$disabledItemsF = props.disabledItemsFocusable,\n disabledItemsFocusable = _props$disabledItemsF === void 0 ? false : _props$disabledItemsF,\n _props$disableListWra = props.disableListWrap,\n disableListWrap = _props$disableListWra === void 0 ? false : _props$disableListWra,\n _props$filterOptions = props.filterOptions,\n filterOptions = _props$filterOptions === void 0 ? defaultFilterOptions : _props$filterOptions,\n _props$filterSelected = props.filterSelectedOptions,\n filterSelectedOptions = _props$filterSelected === void 0 ? false : _props$filterSelected,\n _props$freeSolo = props.freeSolo,\n freeSolo = _props$freeSolo === void 0 ? false : _props$freeSolo,\n getOptionDisabled = props.getOptionDisabled,\n _props$getOptionLabel = props.getOptionLabel,\n getOptionLabelProp = _props$getOptionLabel === void 0 ? function (option) {\n return option;\n } : _props$getOptionLabel,\n _props$getOptionSelec = props.getOptionSelected,\n getOptionSelected = _props$getOptionSelec === void 0 ? function (option, value) {\n return option === value;\n } : _props$getOptionSelec,\n groupBy = props.groupBy,\n _props$handleHomeEndK = props.handleHomeEndKeys,\n handleHomeEndKeys = _props$handleHomeEndK === void 0 ? !props.freeSolo : _props$handleHomeEndK,\n idProp = props.id,\n _props$includeInputIn = props.includeInputInList,\n includeInputInList = _props$includeInputIn === void 0 ? false : _props$includeInputIn,\n inputValueProp = props.inputValue,\n _props$multiple = props.multiple,\n multiple = _props$multiple === void 0 ? false : _props$multiple,\n onChange = props.onChange,\n onClose = props.onClose,\n onHighlightChange = props.onHighlightChange,\n onInputChange = props.onInputChange,\n onOpen = props.onOpen,\n openProp = props.open,\n _props$openOnFocus = props.openOnFocus,\n openOnFocus = _props$openOnFocus === void 0 ? false : _props$openOnFocus,\n options = props.options,\n _props$selectOnFocus = props.selectOnFocus,\n selectOnFocus = _props$selectOnFocus === void 0 ? !props.freeSolo : _props$selectOnFocus,\n valueProp = props.value;\n var id = useId(idProp);\n var getOptionLabel = getOptionLabelProp;\n\n if (process.env.NODE_ENV !== 'production') {\n getOptionLabel = function getOptionLabel(option) {\n var optionLabel = getOptionLabelProp(option);\n\n if (typeof optionLabel !== 'string') {\n var erroneousReturn = optionLabel === undefined ? 'undefined' : \"\".concat(_typeof(optionLabel), \" (\").concat(optionLabel, \")\");\n console.error(\"Material-UI: The `getOptionLabel` method of \".concat(componentName, \" returned \").concat(erroneousReturn, \" instead of a string for \").concat(JSON.stringify(option), \".\"));\n }\n\n return optionLabel;\n };\n }\n\n var ignoreFocus = React.useRef(false);\n var firstFocus = React.useRef(true);\n var inputRef = React.useRef(null);\n var listboxRef = React.useRef(null);\n\n var _React$useState = React.useState(null),\n anchorEl = _React$useState[0],\n setAnchorEl = _React$useState[1];\n\n var _React$useState2 = React.useState(-1),\n focusedTag = _React$useState2[0],\n setFocusedTag = _React$useState2[1];\n\n var defaultHighlighted = autoHighlight ? 0 : -1;\n var highlightedIndexRef = React.useRef(defaultHighlighted);\n\n var _useControlled = useControlled({\n controlled: valueProp,\n default: defaultValue,\n name: componentName\n }),\n _useControlled2 = _slicedToArray(_useControlled, 2),\n value = _useControlled2[0],\n setValue = _useControlled2[1];\n\n var _useControlled3 = useControlled({\n controlled: inputValueProp,\n default: '',\n name: componentName,\n state: 'inputValue'\n }),\n _useControlled4 = _slicedToArray(_useControlled3, 2),\n inputValue = _useControlled4[0],\n setInputValue = _useControlled4[1];\n\n var _React$useState3 = React.useState(false),\n focused = _React$useState3[0],\n setFocused = _React$useState3[1];\n\n var resetInputValue = useEventCallback(function (event, newValue) {\n var newInputValue;\n\n if (multiple) {\n newInputValue = '';\n } else if (newValue == null) {\n newInputValue = '';\n } else {\n var optionLabel = getOptionLabel(newValue);\n newInputValue = typeof optionLabel === 'string' ? optionLabel : '';\n }\n\n if (inputValue === newInputValue) {\n return;\n }\n\n setInputValue(newInputValue);\n\n if (onInputChange) {\n onInputChange(event, newInputValue, 'reset');\n }\n });\n React.useEffect(function () {\n resetInputValue(null, value);\n }, [value, resetInputValue]);\n\n var _useControlled5 = useControlled({\n controlled: openProp,\n default: false,\n name: componentName,\n state: 'open'\n }),\n _useControlled6 = _slicedToArray(_useControlled5, 2),\n open = _useControlled6[0],\n setOpenState = _useControlled6[1];\n\n var inputValueIsSelectedValue = !multiple && value != null && inputValue === getOptionLabel(value);\n var popupOpen = open;\n var filteredOptions = popupOpen ? filterOptions(options.filter(function (option) {\n if (filterSelectedOptions && (multiple ? value : [value]).some(function (value2) {\n return value2 !== null && getOptionSelected(option, value2);\n })) {\n return false;\n }\n\n return true;\n }), // we use the empty string to manipulate `filterOptions` to not filter any options\n // i.e. the filter predicate always returns true\n {\n inputValue: inputValueIsSelectedValue ? '' : inputValue,\n getOptionLabel: getOptionLabel\n }) : [];\n\n if (process.env.NODE_ENV !== 'production') {\n if (value !== null && !freeSolo && options.length > 0) {\n var missingValue = (multiple ? value : [value]).filter(function (value2) {\n return !options.some(function (option) {\n return getOptionSelected(option, value2);\n });\n });\n\n if (missingValue.length > 0) {\n console.warn([\"Material-UI: The value provided to \".concat(componentName, \" is invalid.\"), \"None of the options match with `\".concat(missingValue.length > 1 ? JSON.stringify(missingValue) : JSON.stringify(missingValue[0]), \"`.\"), 'You can use the `getOptionSelected` prop to customize the equality test.'].join('\\n'));\n }\n }\n }\n\n var focusTag = useEventCallback(function (tagToFocus) {\n if (tagToFocus === -1) {\n inputRef.current.focus();\n } else {\n anchorEl.querySelector(\"[data-tag-index=\\\"\".concat(tagToFocus, \"\\\"]\")).focus();\n }\n }); // Ensure the focusedTag is never inconsistent\n\n React.useEffect(function () {\n if (multiple && focusedTag > value.length - 1) {\n setFocusedTag(-1);\n focusTag(-1);\n }\n }, [value, multiple, focusedTag, focusTag]);\n\n function validOptionIndex(index, direction) {\n if (!listboxRef.current || index === -1) {\n return -1;\n }\n\n var nextFocus = index;\n\n while (true) {\n // Out of range\n if (direction === 'next' && nextFocus === filteredOptions.length || direction === 'previous' && nextFocus === -1) {\n return -1;\n }\n\n var option = listboxRef.current.querySelector(\"[data-option-index=\\\"\".concat(nextFocus, \"\\\"]\")); // Same logic as MenuList.js\n\n var nextFocusDisabled = disabledItemsFocusable ? false : option && (option.disabled || option.getAttribute('aria-disabled') === 'true');\n\n if (option && !option.hasAttribute('tabindex') || nextFocusDisabled) {\n // Move to the next element.\n nextFocus += direction === 'next' ? 1 : -1;\n } else {\n return nextFocus;\n }\n }\n }\n\n var setHighlightedIndex = useEventCallback(function (_ref2) {\n var event = _ref2.event,\n index = _ref2.index,\n _ref2$reason = _ref2.reason,\n reason = _ref2$reason === void 0 ? 'auto' : _ref2$reason;\n highlightedIndexRef.current = index; // does the index exist?\n\n if (index === -1) {\n inputRef.current.removeAttribute('aria-activedescendant');\n } else {\n inputRef.current.setAttribute('aria-activedescendant', \"\".concat(id, \"-option-\").concat(index));\n }\n\n if (onHighlightChange) {\n onHighlightChange(event, index === -1 ? null : filteredOptions[index], reason);\n }\n\n if (!listboxRef.current) {\n return;\n }\n\n var prev = listboxRef.current.querySelector('[data-focus]');\n\n if (prev) {\n prev.removeAttribute('data-focus');\n }\n\n var listboxNode = listboxRef.current.parentElement.querySelector('[role=\"listbox\"]'); // \"No results\"\n\n if (!listboxNode) {\n return;\n }\n\n if (index === -1) {\n listboxNode.scrollTop = 0;\n return;\n }\n\n var option = listboxRef.current.querySelector(\"[data-option-index=\\\"\".concat(index, \"\\\"]\"));\n\n if (!option) {\n return;\n }\n\n option.setAttribute('data-focus', 'true'); // Scroll active descendant into view.\n // Logic copied from https://www.w3.org/TR/wai-aria-practices/examples/listbox/js/listbox.js\n //\n // Consider this API instead once it has a better browser support:\n // .scrollIntoView({ scrollMode: 'if-needed', block: 'nearest' });\n\n if (listboxNode.scrollHeight > listboxNode.clientHeight && reason !== 'mouse') {\n var element = option;\n var scrollBottom = listboxNode.clientHeight + listboxNode.scrollTop;\n var elementBottom = element.offsetTop + element.offsetHeight;\n\n if (elementBottom > scrollBottom) {\n listboxNode.scrollTop = elementBottom - listboxNode.clientHeight;\n } else if (element.offsetTop - element.offsetHeight * (groupBy ? 1.3 : 0) < listboxNode.scrollTop) {\n listboxNode.scrollTop = element.offsetTop - element.offsetHeight * (groupBy ? 1.3 : 0);\n }\n }\n });\n var changeHighlightedIndex = useEventCallback(function (_ref3) {\n var event = _ref3.event,\n diff = _ref3.diff,\n _ref3$direction = _ref3.direction,\n direction = _ref3$direction === void 0 ? 'next' : _ref3$direction,\n _ref3$reason = _ref3.reason,\n reason = _ref3$reason === void 0 ? 'auto' : _ref3$reason;\n\n if (!popupOpen) {\n return;\n }\n\n var getNextIndex = function getNextIndex() {\n var maxIndex = filteredOptions.length - 1;\n\n if (diff === 'reset') {\n return defaultHighlighted;\n }\n\n if (diff === 'start') {\n return 0;\n }\n\n if (diff === 'end') {\n return maxIndex;\n }\n\n var newIndex = highlightedIndexRef.current + diff;\n\n if (newIndex < 0) {\n if (newIndex === -1 && includeInputInList) {\n return -1;\n }\n\n if (disableListWrap && highlightedIndexRef.current !== -1 || Math.abs(diff) > 1) {\n return 0;\n }\n\n return maxIndex;\n }\n\n if (newIndex > maxIndex) {\n if (newIndex === maxIndex + 1 && includeInputInList) {\n return -1;\n }\n\n if (disableListWrap || Math.abs(diff) > 1) {\n return maxIndex;\n }\n\n return 0;\n }\n\n return newIndex;\n };\n\n var nextIndex = validOptionIndex(getNextIndex(), direction);\n setHighlightedIndex({\n index: nextIndex,\n reason: reason,\n event: event\n }); // Sync the content of the input with the highlighted option.\n\n if (autoComplete && diff !== 'reset') {\n if (nextIndex === -1) {\n inputRef.current.value = inputValue;\n } else {\n var option = getOptionLabel(filteredOptions[nextIndex]);\n inputRef.current.value = option; // The portion of the selected suggestion that has not been typed by the user,\n // a completion string, appears inline after the input cursor in the textbox.\n\n var index = option.toLowerCase().indexOf(inputValue.toLowerCase());\n\n if (index === 0 && inputValue.length > 0) {\n inputRef.current.setSelectionRange(inputValue.length, option.length);\n }\n }\n }\n });\n var syncHighlightedIndex = React.useCallback(function () {\n if (!popupOpen) {\n return;\n }\n\n var valueItem = multiple ? value[0] : value; // The popup is empty, reset\n\n if (filteredOptions.length === 0 || valueItem == null) {\n changeHighlightedIndex({\n diff: 'reset'\n });\n return;\n }\n\n if (!listboxRef.current) {\n return;\n } // Synchronize the value with the highlighted index\n\n\n if (!filterSelectedOptions && valueItem != null) {\n var currentOption = filteredOptions[highlightedIndexRef.current]; // Keep the current highlighted index if possible\n\n if (multiple && currentOption && findIndex(value, function (val) {\n return getOptionSelected(currentOption, val);\n }) !== -1) {\n return;\n }\n\n var itemIndex = findIndex(filteredOptions, function (optionItem) {\n return getOptionSelected(optionItem, valueItem);\n });\n\n if (itemIndex === -1) {\n changeHighlightedIndex({\n diff: 'reset'\n });\n } else {\n setHighlightedIndex({\n index: itemIndex\n });\n }\n\n return;\n } // Prevent the highlighted index to leak outside the boundaries.\n\n\n if (highlightedIndexRef.current >= filteredOptions.length - 1) {\n setHighlightedIndex({\n index: filteredOptions.length - 1\n });\n return;\n } // Restore the focus to the previous index.\n\n\n setHighlightedIndex({\n index: highlightedIndexRef.current\n }); // Ignore filteredOptions (and options, getOptionSelected, getOptionLabel) not to break the scroll position\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [// Only sync the highlighted index when the option switch between empty and not\n // eslint-disable-next-line react-hooks/exhaustive-deps\n filteredOptions.length === 0, // Don't sync the highlighted index with the value when multiple\n // eslint-disable-next-line react-hooks/exhaustive-deps\n multiple ? false : value, filterSelectedOptions, changeHighlightedIndex, setHighlightedIndex, popupOpen, inputValue, multiple]);\n var handleListboxRef = useEventCallback(function (node) {\n setRef(listboxRef, node);\n\n if (!node) {\n return;\n }\n\n syncHighlightedIndex();\n });\n React.useEffect(function () {\n syncHighlightedIndex();\n }, [syncHighlightedIndex]);\n\n var handleOpen = function handleOpen(event) {\n if (open) {\n return;\n }\n\n setOpenState(true);\n\n if (onOpen) {\n onOpen(event);\n }\n };\n\n var handleClose = function handleClose(event, reason) {\n if (!open) {\n return;\n }\n\n setOpenState(false);\n\n if (onClose) {\n onClose(event, reason);\n }\n };\n\n var handleValue = function handleValue(event, newValue, reason, details) {\n if (value === newValue) {\n return;\n }\n\n if (onChange) {\n onChange(event, newValue, reason, details);\n }\n\n setValue(newValue);\n };\n\n var isTouch = React.useRef(false);\n\n var selectNewValue = function selectNewValue(event, option) {\n var reasonProp = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'select-option';\n var origin = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 'options';\n var reason = reasonProp;\n var newValue = option;\n\n if (multiple) {\n newValue = Array.isArray(value) ? value.slice() : [];\n\n if (process.env.NODE_ENV !== 'production') {\n var matches = newValue.filter(function (val) {\n return getOptionSelected(option, val);\n });\n\n if (matches.length > 1) {\n console.error([\"Material-UI: The `getOptionSelected` method of \".concat(componentName, \" do not handle the arguments correctly.\"), \"The component expects a single value to match a given option but found \".concat(matches.length, \" matches.\")].join('\\n'));\n }\n }\n\n var itemIndex = findIndex(newValue, function (valueItem) {\n return getOptionSelected(option, valueItem);\n });\n\n if (itemIndex === -1) {\n newValue.push(option);\n } else if (origin !== 'freeSolo') {\n newValue.splice(itemIndex, 1);\n reason = 'remove-option';\n }\n }\n\n resetInputValue(event, newValue);\n handleValue(event, newValue, reason, {\n option: option\n });\n\n if (!disableCloseOnSelect) {\n handleClose(event, reason);\n }\n\n if (blurOnSelect === true || blurOnSelect === 'touch' && isTouch.current || blurOnSelect === 'mouse' && !isTouch.current) {\n inputRef.current.blur();\n }\n };\n\n function validTagIndex(index, direction) {\n if (index === -1) {\n return -1;\n }\n\n var nextFocus = index;\n\n while (true) {\n // Out of range\n if (direction === 'next' && nextFocus === value.length || direction === 'previous' && nextFocus === -1) {\n return -1;\n }\n\n var option = anchorEl.querySelector(\"[data-tag-index=\\\"\".concat(nextFocus, \"\\\"]\")); // Same logic as MenuList.js\n\n if (option && (!option.hasAttribute('tabindex') || option.disabled || option.getAttribute('aria-disabled') === 'true')) {\n nextFocus += direction === 'next' ? 1 : -1;\n } else {\n return nextFocus;\n }\n }\n }\n\n var handleFocusTag = function handleFocusTag(event, direction) {\n if (!multiple) {\n return;\n }\n\n handleClose(event, 'toggleInput');\n var nextTag = focusedTag;\n\n if (focusedTag === -1) {\n if (inputValue === '' && direction === 'previous') {\n nextTag = value.length - 1;\n }\n } else {\n nextTag += direction === 'next' ? 1 : -1;\n\n if (nextTag < 0) {\n nextTag = 0;\n }\n\n if (nextTag === value.length) {\n nextTag = -1;\n }\n }\n\n nextTag = validTagIndex(nextTag, direction);\n setFocusedTag(nextTag);\n focusTag(nextTag);\n };\n\n var handleClear = function handleClear(event) {\n ignoreFocus.current = true;\n setInputValue('');\n\n if (onInputChange) {\n onInputChange(event, '', 'clear');\n }\n\n handleValue(event, multiple ? [] : null, 'clear');\n };\n\n var handleKeyDown = function handleKeyDown(other) {\n return function (event) {\n if (focusedTag !== -1 && ['ArrowLeft', 'ArrowRight'].indexOf(event.key) === -1) {\n setFocusedTag(-1);\n focusTag(-1);\n }\n\n switch (event.key) {\n case 'Home':\n if (popupOpen && handleHomeEndKeys) {\n // Prevent scroll of the page\n event.preventDefault();\n changeHighlightedIndex({\n diff: 'start',\n direction: 'next',\n reason: 'keyboard',\n event: event\n });\n }\n\n break;\n\n case 'End':\n if (popupOpen && handleHomeEndKeys) {\n // Prevent scroll of the page\n event.preventDefault();\n changeHighlightedIndex({\n diff: 'end',\n direction: 'previous',\n reason: 'keyboard',\n event: event\n });\n }\n\n break;\n\n case 'PageUp':\n // Prevent scroll of the page\n event.preventDefault();\n changeHighlightedIndex({\n diff: -pageSize,\n direction: 'previous',\n reason: 'keyboard',\n event: event\n });\n handleOpen(event);\n break;\n\n case 'PageDown':\n // Prevent scroll of the page\n event.preventDefault();\n changeHighlightedIndex({\n diff: pageSize,\n direction: 'next',\n reason: 'keyboard',\n event: event\n });\n handleOpen(event);\n break;\n\n case 'ArrowDown':\n // Prevent cursor move\n event.preventDefault();\n changeHighlightedIndex({\n diff: 1,\n direction: 'next',\n reason: 'keyboard',\n event: event\n });\n handleOpen(event);\n break;\n\n case 'ArrowUp':\n // Prevent cursor move\n event.preventDefault();\n changeHighlightedIndex({\n diff: -1,\n direction: 'previous',\n reason: 'keyboard',\n event: event\n });\n handleOpen(event);\n break;\n\n case 'ArrowLeft':\n handleFocusTag(event, 'previous');\n break;\n\n case 'ArrowRight':\n handleFocusTag(event, 'next');\n break;\n\n case 'Enter':\n // Wait until IME is settled.\n if (event.which === 229) {\n break;\n }\n\n if (highlightedIndexRef.current !== -1 && popupOpen) {\n var option = filteredOptions[highlightedIndexRef.current];\n var disabled = getOptionDisabled ? getOptionDisabled(option) : false; // We don't want to validate the form.\n\n event.preventDefault();\n\n if (disabled) {\n return;\n }\n\n selectNewValue(event, option, 'select-option'); // Move the selection to the end.\n\n if (autoComplete) {\n inputRef.current.setSelectionRange(inputRef.current.value.length, inputRef.current.value.length);\n }\n } else if (freeSolo && inputValue !== '' && inputValueIsSelectedValue === false) {\n if (multiple) {\n // Allow people to add new values before they submit the form.\n event.preventDefault();\n }\n\n selectNewValue(event, inputValue, 'create-option', 'freeSolo');\n }\n\n break;\n\n case 'Escape':\n if (popupOpen) {\n // Avoid Opera to exit fullscreen mode.\n event.preventDefault(); // Avoid the Modal to handle the event.\n\n event.stopPropagation();\n handleClose(event, 'escape');\n } else if (clearOnEscape && (inputValue !== '' || multiple && value.length > 0)) {\n // Avoid Opera to exit fullscreen mode.\n event.preventDefault(); // Avoid the Modal to handle the event.\n\n event.stopPropagation();\n handleClear(event);\n }\n\n break;\n\n case 'Backspace':\n if (multiple && inputValue === '' && value.length > 0) {\n var index = focusedTag === -1 ? value.length - 1 : focusedTag;\n var newValue = value.slice();\n newValue.splice(index, 1);\n handleValue(event, newValue, 'remove-option', {\n option: value[index]\n });\n }\n\n break;\n\n default:\n }\n\n if (other.onKeyDown) {\n other.onKeyDown(event);\n }\n };\n };\n\n var handleFocus = function handleFocus(event) {\n setFocused(true);\n\n if (openOnFocus && !ignoreFocus.current) {\n handleOpen(event);\n }\n };\n\n var handleBlur = function handleBlur(event) {\n // Ignore the event when using the scrollbar with IE 11\n if (listboxRef.current !== null && document.activeElement === listboxRef.current.parentElement) {\n inputRef.current.focus();\n return;\n }\n\n setFocused(false);\n firstFocus.current = true;\n ignoreFocus.current = false;\n\n if (debug && inputValue !== '') {\n return;\n }\n\n if (autoSelect && highlightedIndexRef.current !== -1 && popupOpen) {\n selectNewValue(event, filteredOptions[highlightedIndexRef.current], 'blur');\n } else if (autoSelect && freeSolo && inputValue !== '') {\n selectNewValue(event, inputValue, 'blur', 'freeSolo');\n } else if (clearOnBlur) {\n resetInputValue(event, value);\n }\n\n handleClose(event, 'blur');\n };\n\n var handleInputChange = function handleInputChange(event) {\n var newValue = event.target.value;\n\n if (inputValue !== newValue) {\n setInputValue(newValue);\n\n if (onInputChange) {\n onInputChange(event, newValue, 'input');\n }\n }\n\n if (newValue === '') {\n if (!disableClearable && !multiple) {\n handleValue(event, null, 'clear');\n }\n } else {\n handleOpen(event);\n }\n };\n\n var handleOptionMouseOver = function handleOptionMouseOver(event) {\n setHighlightedIndex({\n event: event,\n index: Number(event.currentTarget.getAttribute('data-option-index')),\n reason: 'mouse'\n });\n };\n\n var handleOptionTouchStart = function handleOptionTouchStart() {\n isTouch.current = true;\n };\n\n var handleOptionClick = function handleOptionClick(event) {\n var index = Number(event.currentTarget.getAttribute('data-option-index'));\n selectNewValue(event, filteredOptions[index], 'select-option');\n isTouch.current = false;\n };\n\n var handleTagDelete = function handleTagDelete(index) {\n return function (event) {\n var newValue = value.slice();\n newValue.splice(index, 1);\n handleValue(event, newValue, 'remove-option', {\n option: value[index]\n });\n };\n };\n\n var handlePopupIndicator = function handlePopupIndicator(event) {\n if (open) {\n handleClose(event, 'toggleInput');\n } else {\n handleOpen(event);\n }\n }; // Prevent input blur when interacting with the combobox\n\n\n var handleMouseDown = function handleMouseDown(event) {\n if (event.target.getAttribute('id') !== id) {\n event.preventDefault();\n }\n }; // Focus the input when interacting with the combobox\n\n\n var handleClick = function handleClick() {\n inputRef.current.focus();\n\n if (selectOnFocus && firstFocus.current && inputRef.current.selectionEnd - inputRef.current.selectionStart === 0) {\n inputRef.current.select();\n }\n\n firstFocus.current = false;\n };\n\n var handleInputMouseDown = function handleInputMouseDown(event) {\n if (inputValue === '' || !open) {\n handlePopupIndicator(event);\n }\n };\n\n var dirty = freeSolo && inputValue.length > 0;\n dirty = dirty || (multiple ? value.length > 0 : value !== null);\n var groupedOptions = filteredOptions;\n\n if (groupBy) {\n // used to keep track of key and indexes in the result array\n var indexBy = new Map();\n var warn = false;\n groupedOptions = filteredOptions.reduce(function (acc, option, index) {\n var group = groupBy(option);\n\n if (acc.length > 0 && acc[acc.length - 1].group === group) {\n acc[acc.length - 1].options.push(option);\n } else {\n if (process.env.NODE_ENV !== 'production') {\n if (indexBy.get(group) && !warn) {\n console.warn(\"Material-UI: The options provided combined with the `groupBy` method of \".concat(componentName, \" returns duplicated headers.\"), 'You can solve the issue by sorting the options with the output of `groupBy`.');\n warn = true;\n }\n\n indexBy.set(group, true);\n }\n\n acc.push({\n key: index,\n index: index,\n group: group,\n options: [option]\n });\n }\n\n return acc;\n }, []);\n }\n\n return {\n getRootProps: function getRootProps() {\n var other = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n return _extends({\n 'aria-owns': popupOpen ? \"\".concat(id, \"-popup\") : null,\n role: 'combobox',\n 'aria-expanded': popupOpen\n }, other, {\n onKeyDown: handleKeyDown(other),\n onMouseDown: handleMouseDown,\n onClick: handleClick\n });\n },\n getInputLabelProps: function getInputLabelProps() {\n return {\n id: \"\".concat(id, \"-label\"),\n htmlFor: id\n };\n },\n getInputProps: function getInputProps() {\n return {\n id: id,\n value: inputValue,\n onBlur: handleBlur,\n onFocus: handleFocus,\n onChange: handleInputChange,\n onMouseDown: handleInputMouseDown,\n // if open then this is handled imperativeley so don't let react override\n // only have an opinion about this when closed\n 'aria-activedescendant': popupOpen ? '' : null,\n 'aria-autocomplete': autoComplete ? 'both' : 'list',\n 'aria-controls': popupOpen ? \"\".concat(id, \"-popup\") : null,\n // Disable browser's suggestion that might overlap with the popup.\n // Handle autocomplete but not autofill.\n autoComplete: 'off',\n ref: inputRef,\n autoCapitalize: 'none',\n spellCheck: 'false'\n };\n },\n getClearProps: function getClearProps() {\n return {\n tabIndex: -1,\n onClick: handleClear\n };\n },\n getPopupIndicatorProps: function getPopupIndicatorProps() {\n return {\n tabIndex: -1,\n onClick: handlePopupIndicator\n };\n },\n getTagProps: function getTagProps(_ref4) {\n var index = _ref4.index;\n return {\n key: index,\n 'data-tag-index': index,\n tabIndex: -1,\n onDelete: handleTagDelete(index)\n };\n },\n getListboxProps: function getListboxProps() {\n return {\n role: 'listbox',\n id: \"\".concat(id, \"-popup\"),\n 'aria-labelledby': \"\".concat(id, \"-label\"),\n ref: handleListboxRef,\n onMouseDown: function onMouseDown(event) {\n // Prevent blur\n event.preventDefault();\n }\n };\n },\n getOptionProps: function getOptionProps(_ref5) {\n var index = _ref5.index,\n option = _ref5.option;\n var selected = (multiple ? value : [value]).some(function (value2) {\n return value2 != null && getOptionSelected(option, value2);\n });\n var disabled = getOptionDisabled ? getOptionDisabled(option) : false;\n return {\n key: index,\n tabIndex: -1,\n role: 'option',\n id: \"\".concat(id, \"-option-\").concat(index),\n onMouseOver: handleOptionMouseOver,\n onClick: handleOptionClick,\n onTouchStart: handleOptionTouchStart,\n 'data-option-index': index,\n 'aria-disabled': disabled,\n 'aria-selected': selected\n };\n },\n id: id,\n inputValue: inputValue,\n value: value,\n dirty: dirty,\n popupOpen: popupOpen,\n focused: focused || focusedTag !== -1,\n anchorEl: anchorEl,\n setAnchorEl: setAnchorEl,\n focusedTag: focusedTag,\n groupedOptions: groupedOptions\n };\n}","import * as React from 'react';\nimport { createSvgIcon } from '@material-ui/core/utils';\n/**\n * @ignore - internal component.\n */\n\nexport default createSvgIcon( /*#__PURE__*/React.createElement(\"path\", {\n d: \"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z\"\n}), 'Add');","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\n\n/* eslint-disable jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions */\nimport * as React from 'react';\nimport clsx from 'clsx';\nimport PropTypes from 'prop-types';\nimport Typography from '@material-ui/core/Typography';\nimport Collapse from '@material-ui/core/Collapse';\nimport { fade, withStyles, useTheme } from '@material-ui/core/styles';\nimport { useForkRef } from '@material-ui/core/utils';\nimport TreeViewContext from '../TreeView/TreeViewContext';\nexport var styles = function styles(theme) {\n return {\n /* Styles applied to the root element. */\n root: {\n listStyle: 'none',\n margin: 0,\n padding: 0,\n outline: 0,\n WebkitTapHighlightColor: 'transparent',\n '&:focus > $content $label': {\n backgroundColor: theme.palette.action.hover\n },\n '&$selected > $content $label': {\n backgroundColor: fade(theme.palette.primary.main, theme.palette.action.selectedOpacity)\n },\n '&$selected > $content $label:hover, &$selected:focus > $content $label': {\n backgroundColor: fade(theme.palette.primary.main, theme.palette.action.selectedOpacity + theme.palette.action.hoverOpacity),\n // Reset on touch devices, it doesn't add specificity\n '@media (hover: none)': {\n backgroundColor: 'transparent'\n }\n }\n },\n\n /* Pseudo-class applied to the root element when expanded. */\n expanded: {},\n\n /* Pseudo-class applied to the root element when selected. */\n selected: {},\n\n /* Styles applied to the `role=\"group\"` element. */\n group: {\n margin: 0,\n padding: 0,\n marginLeft: 17\n },\n\n /* Styles applied to the tree node content. */\n content: {\n width: '100%',\n display: 'flex',\n alignItems: 'center',\n cursor: 'pointer'\n },\n\n /* Styles applied to the tree node icon and collapse/expand icon. */\n iconContainer: {\n marginRight: 4,\n width: 15,\n display: 'flex',\n flexShrink: 0,\n justifyContent: 'center',\n '& svg': {\n fontSize: 18\n }\n },\n\n /* Styles applied to the label element. */\n label: {\n width: '100%',\n paddingLeft: 4,\n position: 'relative',\n '&:hover': {\n backgroundColor: theme.palette.action.hover,\n // Reset on touch devices, it doesn't add specificity\n '@media (hover: none)': {\n backgroundColor: 'transparent'\n }\n }\n }\n };\n};\n\nvar isPrintableCharacter = function isPrintableCharacter(str) {\n return str && str.length === 1 && str.match(/\\S/);\n};\n\nvar TreeItem = /*#__PURE__*/React.forwardRef(function TreeItem(props, ref) {\n var children = props.children,\n classes = props.classes,\n className = props.className,\n collapseIcon = props.collapseIcon,\n endIcon = props.endIcon,\n expandIcon = props.expandIcon,\n iconProp = props.icon,\n label = props.label,\n nodeId = props.nodeId,\n onClick = props.onClick,\n onLabelClick = props.onLabelClick,\n onIconClick = props.onIconClick,\n onFocus = props.onFocus,\n onKeyDown = props.onKeyDown,\n onMouseDown = props.onMouseDown,\n _props$TransitionComp = props.TransitionComponent,\n TransitionComponent = _props$TransitionComp === void 0 ? Collapse : _props$TransitionComp,\n TransitionProps = props.TransitionProps,\n other = _objectWithoutProperties(props, [\"children\", \"classes\", \"className\", \"collapseIcon\", \"endIcon\", \"expandIcon\", \"icon\", \"label\", \"nodeId\", \"onClick\", \"onLabelClick\", \"onIconClick\", \"onFocus\", \"onKeyDown\", \"onMouseDown\", \"TransitionComponent\", \"TransitionProps\"]);\n\n var _React$useContext = React.useContext(TreeViewContext),\n contextIcons = _React$useContext.icons,\n focus = _React$useContext.focus,\n focusFirstNode = _React$useContext.focusFirstNode,\n focusLastNode = _React$useContext.focusLastNode,\n focusNextNode = _React$useContext.focusNextNode,\n focusPreviousNode = _React$useContext.focusPreviousNode,\n focusByFirstCharacter = _React$useContext.focusByFirstCharacter,\n selectNode = _React$useContext.selectNode,\n selectRange = _React$useContext.selectRange,\n selectNextNode = _React$useContext.selectNextNode,\n selectPreviousNode = _React$useContext.selectPreviousNode,\n rangeSelectToFirst = _React$useContext.rangeSelectToFirst,\n rangeSelectToLast = _React$useContext.rangeSelectToLast,\n selectAllNodes = _React$useContext.selectAllNodes,\n expandAllSiblings = _React$useContext.expandAllSiblings,\n toggleExpansion = _React$useContext.toggleExpansion,\n isExpanded = _React$useContext.isExpanded,\n isFocused = _React$useContext.isFocused,\n isSelected = _React$useContext.isSelected,\n isTabbable = _React$useContext.isTabbable,\n multiSelect = _React$useContext.multiSelect,\n getParent = _React$useContext.getParent,\n mapFirstChar = _React$useContext.mapFirstChar,\n addNodeToNodeMap = _React$useContext.addNodeToNodeMap,\n removeNodeFromNodeMap = _React$useContext.removeNodeFromNodeMap;\n\n var nodeRef = React.useRef(null);\n var contentRef = React.useRef(null);\n var handleRef = useForkRef(nodeRef, ref);\n var icon = iconProp;\n var expandable = Boolean(Array.isArray(children) ? children.length : children);\n var expanded = isExpanded ? isExpanded(nodeId) : false;\n var focused = isFocused ? isFocused(nodeId) : false;\n var tabbable = isTabbable ? isTabbable(nodeId) : false;\n var selected = isSelected ? isSelected(nodeId) : false;\n var icons = contextIcons || {};\n var theme = useTheme();\n\n if (!icon) {\n if (expandable) {\n if (!expanded) {\n icon = expandIcon || icons.defaultExpandIcon;\n } else {\n icon = collapseIcon || icons.defaultCollapseIcon;\n }\n\n if (!icon) {\n icon = icons.defaultParentIcon;\n }\n } else {\n icon = endIcon || icons.defaultEndIcon;\n }\n }\n\n var handleClick = function handleClick(event) {\n if (!focused) {\n focus(nodeId);\n }\n\n var multiple = multiSelect && (event.shiftKey || event.ctrlKey || event.metaKey); // If already expanded and trying to toggle selection don't close\n\n if (expandable && !event.defaultPrevented && !(multiple && isExpanded(nodeId))) {\n toggleExpansion(event, nodeId);\n }\n\n if (multiple) {\n if (event.shiftKey) {\n selectRange(event, {\n end: nodeId\n });\n } else {\n selectNode(event, nodeId, true);\n }\n } else {\n selectNode(event, nodeId);\n }\n\n if (onClick) {\n onClick(event);\n }\n };\n\n var handleMouseDown = function handleMouseDown(event) {\n if (event.shiftKey || event.ctrlKey || event.metaKey) {\n event.preventDefault();\n }\n\n if (onMouseDown) {\n onMouseDown(event);\n }\n };\n\n var handleNextArrow = function handleNextArrow(event) {\n if (expandable) {\n if (expanded) {\n focusNextNode(nodeId);\n } else {\n toggleExpansion(event);\n }\n }\n\n return true;\n };\n\n var handlePreviousArrow = function handlePreviousArrow(event) {\n if (expanded) {\n toggleExpansion(event, nodeId);\n return true;\n }\n\n var parent = getParent(nodeId);\n\n if (parent) {\n focus(parent);\n return true;\n }\n\n return false;\n };\n\n var handleKeyDown = function handleKeyDown(event) {\n var flag = false;\n var key = event.key;\n\n if (event.altKey || event.currentTarget !== event.target) {\n return;\n }\n\n var ctrlPressed = event.ctrlKey || event.metaKey;\n\n switch (key) {\n case ' ':\n if (nodeRef.current === event.currentTarget) {\n if (multiSelect && event.shiftKey) {\n flag = selectRange(event, {\n end: nodeId\n });\n } else if (multiSelect) {\n flag = selectNode(event, nodeId, true);\n } else {\n flag = selectNode(event, nodeId);\n }\n }\n\n event.stopPropagation();\n break;\n\n case 'Enter':\n if (nodeRef.current === event.currentTarget && expandable) {\n toggleExpansion(event);\n flag = true;\n }\n\n event.stopPropagation();\n break;\n\n case 'ArrowDown':\n if (multiSelect && event.shiftKey) {\n selectNextNode(event, nodeId);\n }\n\n focusNextNode(nodeId);\n flag = true;\n break;\n\n case 'ArrowUp':\n if (multiSelect && event.shiftKey) {\n selectPreviousNode(event, nodeId);\n }\n\n focusPreviousNode(nodeId);\n flag = true;\n break;\n\n case 'ArrowRight':\n if (theme.direction === 'rtl') {\n flag = handlePreviousArrow(event);\n } else {\n flag = handleNextArrow(event);\n }\n\n break;\n\n case 'ArrowLeft':\n if (theme.direction === 'rtl') {\n flag = handleNextArrow(event);\n } else {\n flag = handlePreviousArrow(event);\n }\n\n break;\n\n case 'Home':\n if (multiSelect && ctrlPressed && event.shiftKey) {\n rangeSelectToFirst(event, nodeId);\n }\n\n focusFirstNode();\n flag = true;\n break;\n\n case 'End':\n if (multiSelect && ctrlPressed && event.shiftKey) {\n rangeSelectToLast(event, nodeId);\n }\n\n focusLastNode();\n flag = true;\n break;\n\n default:\n if (key === '*') {\n expandAllSiblings(event, nodeId);\n flag = true;\n } else if (multiSelect && ctrlPressed && key.toLowerCase() === 'a') {\n flag = selectAllNodes(event);\n } else if (!ctrlPressed && !event.shiftKey && isPrintableCharacter(key)) {\n focusByFirstCharacter(nodeId, key);\n flag = true;\n }\n\n }\n\n if (flag) {\n event.preventDefault();\n event.stopPropagation();\n }\n\n if (onKeyDown) {\n onKeyDown(event);\n }\n };\n\n var handleFocus = function handleFocus(event) {\n if (!focused && event.currentTarget === event.target) {\n focus(nodeId);\n }\n\n if (onFocus) {\n onFocus(event);\n }\n };\n\n React.useEffect(function () {\n if (addNodeToNodeMap) {\n var childIds = [];\n React.Children.forEach(children, function (child) {\n if ( /*#__PURE__*/React.isValidElement(child) && child.props.nodeId) {\n childIds.push(child.props.nodeId);\n }\n });\n addNodeToNodeMap(nodeId, childIds);\n }\n }, [children, nodeId, addNodeToNodeMap]);\n React.useEffect(function () {\n if (removeNodeFromNodeMap) {\n return function () {\n removeNodeFromNodeMap(nodeId);\n };\n }\n\n return undefined;\n }, [nodeId, removeNodeFromNodeMap]);\n React.useEffect(function () {\n if (mapFirstChar && label) {\n mapFirstChar(nodeId, contentRef.current.textContent.substring(0, 1).toLowerCase());\n }\n }, [mapFirstChar, nodeId, label]);\n React.useEffect(function () {\n if (focused) {\n nodeRef.current.focus();\n }\n }, [focused]);\n var ariaSelected;\n\n if (multiSelect) {\n ariaSelected = selected;\n } else if (selected) {\n // single-selection trees unset aria-selected\n ariaSelected = true;\n }\n\n return /*#__PURE__*/React.createElement(\"li\", _extends({\n className: clsx(classes.root, className, expanded && classes.expanded, selected && classes.selected),\n role: \"treeitem\",\n onKeyDown: handleKeyDown,\n onFocus: handleFocus,\n \"aria-expanded\": expandable ? expanded : null,\n \"aria-selected\": ariaSelected,\n ref: handleRef,\n tabIndex: tabbable ? 0 : -1\n }, other), /*#__PURE__*/React.createElement(\"div\", {\n className: classes.content,\n onClick: handleClick,\n onMouseDown: handleMouseDown,\n ref: contentRef\n }, /*#__PURE__*/React.createElement(\"div\", {\n onClick: onIconClick,\n className: classes.iconContainer\n }, icon), /*#__PURE__*/React.createElement(Typography, {\n onClick: onLabelClick,\n component: \"div\",\n className: classes.label\n }, label)), children && /*#__PURE__*/React.createElement(TransitionComponent, _extends({\n unmountOnExit: true,\n className: classes.group,\n in: expanded,\n component: \"ul\",\n role: \"group\"\n }, TransitionProps), children));\n});\nprocess.env.NODE_ENV !== \"production\" ? TreeItem.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the d.ts file and run \"yarn proptypes\" |\n // ----------------------------------------------------------------------\n\n /**\n * The content of the component.\n */\n children: PropTypes.node,\n\n /**\n * Override or extend the styles applied to the component.\n * See [CSS API](#css) below for more details.\n */\n classes: PropTypes.object,\n\n /**\n * @ignore\n */\n className: PropTypes.string,\n\n /**\n * The icon used to collapse the node.\n */\n collapseIcon: PropTypes.node,\n\n /**\n * The icon displayed next to a end node.\n */\n endIcon: PropTypes.node,\n\n /**\n * The icon used to expand the node.\n */\n expandIcon: PropTypes.node,\n\n /**\n * The icon to display next to the tree node's label.\n */\n icon: PropTypes.node,\n\n /**\n * The tree node label.\n */\n label: PropTypes.node,\n\n /**\n * The id of the node.\n */\n nodeId: PropTypes.string.isRequired,\n\n /**\n * @ignore\n */\n onClick: PropTypes.func,\n\n /**\n * @ignore\n */\n onFocus: PropTypes.func,\n\n /**\n * `onClick` handler for the icon container. Call `event.preventDefault()` to prevent `onNodeToggle` from being called.\n */\n onIconClick: PropTypes.func,\n\n /**\n * @ignore\n */\n onKeyDown: PropTypes.func,\n\n /**\n * `onClick` handler for the label container. Call `event.preventDefault()` to prevent `onNodeToggle` from being called.\n */\n onLabelClick: PropTypes.func,\n\n /**\n * @ignore\n */\n onMouseDown: PropTypes.func,\n\n /**\n * The component used for the transition.\n * [Follow this guide](/components/transitions/#transitioncomponent-prop) to learn more about the requirements for this component.\n */\n TransitionComponent: PropTypes.elementType,\n\n /**\n * Props applied to the [`Transition`](http://reactcommunity.org/react-transition-group/transition#Transition-props) element.\n */\n TransitionProps: PropTypes.object\n} : void 0;\nexport default withStyles(styles, {\n name: 'MuiTreeItem'\n})(TreeItem);","import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutProperties from \"@babel/runtime/helpers/esm/objectWithoutProperties\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport { withStyles } from '@material-ui/core/styles';\nimport { getPanelId, getTabId, useTabContext } from '../TabContext';\nexport var styles = function styles(theme) {\n return {\n /* Styles applied to the root element. */\n root: {\n padding: theme.spacing(3)\n }\n };\n};\nvar TabPanel = /*#__PURE__*/React.forwardRef(function TabPanel(props, ref) {\n var children = props.children,\n className = props.className,\n classes = props.classes,\n value = props.value,\n other = _objectWithoutProperties(props, [\"children\", \"className\", \"classes\", \"value\"]);\n\n var context = useTabContext();\n\n if (context === null) {\n throw new TypeError('No TabContext provided');\n }\n\n var id = getPanelId(context, value);\n var tabId = getTabId(context, value);\n return /*#__PURE__*/React.createElement(\"div\", _extends({\n \"aria-labelledby\": tabId,\n className: clsx(classes.root, className),\n hidden: value !== context.value,\n id: id,\n ref: ref,\n role: \"tabpanel\"\n }, other), value === context.value && children);\n});\nprocess.env.NODE_ENV !== \"production\" ? TabPanel.propTypes = {\n // ----------------------------- Warning --------------------------------\n // | These PropTypes are generated from the TypeScript type definitions |\n // | To update them edit the d.ts file and run \"yarn proptypes\" |\n // ----------------------------------------------------------------------\n\n /**\n * The content of the component.\n */\n children: PropTypes.node,\n\n /**\n * Override or extend the styles applied to the component.\n * See [CSS API](#css) below for more details.\n */\n classes: PropTypes.object,\n\n /**\n * @ignore\n */\n className: PropTypes.string,\n\n /**\n * The `value` of the corresponding `Tab`. Must use the index of the `Tab` when\n * no `value` was passed to `Tab`.\n */\n value: PropTypes.string.isRequired\n} : void 0;\nexport default withStyles(styles, {\n name: 'MuiTabPanel'\n})(TabPanel);","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-is.production.min.js');\n} else {\n module.exports = require('./cjs/react-is.development.js');\n}\n","/** @license React v17.0.2\n * react-is.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';var b=60103,c=60106,d=60107,e=60108,f=60114,g=60109,h=60110,k=60112,l=60113,m=60120,n=60115,p=60116,q=60121,r=60122,u=60117,v=60129,w=60131;\nif(\"function\"===typeof Symbol&&Symbol.for){var x=Symbol.for;b=x(\"react.element\");c=x(\"react.portal\");d=x(\"react.fragment\");e=x(\"react.strict_mode\");f=x(\"react.profiler\");g=x(\"react.provider\");h=x(\"react.context\");k=x(\"react.forward_ref\");l=x(\"react.suspense\");m=x(\"react.suspense_list\");n=x(\"react.memo\");p=x(\"react.lazy\");q=x(\"react.block\");r=x(\"react.server.block\");u=x(\"react.fundamental\");v=x(\"react.debug_trace_mode\");w=x(\"react.legacy_hidden\")}\nfunction y(a){if(\"object\"===typeof a&&null!==a){var t=a.$$typeof;switch(t){case b:switch(a=a.type,a){case d:case f:case e:case l:case m:return a;default:switch(a=a&&a.$$typeof,a){case h:case k:case p:case n:case g:return a;default:return t}}case c:return t}}}var z=g,A=b,B=k,C=d,D=p,E=n,F=c,G=f,H=e,I=l;exports.ContextConsumer=h;exports.ContextProvider=z;exports.Element=A;exports.ForwardRef=B;exports.Fragment=C;exports.Lazy=D;exports.Memo=E;exports.Portal=F;exports.Profiler=G;exports.StrictMode=H;\nexports.Suspense=I;exports.isAsyncMode=function(){return!1};exports.isConcurrentMode=function(){return!1};exports.isContextConsumer=function(a){return y(a)===h};exports.isContextProvider=function(a){return y(a)===g};exports.isElement=function(a){return\"object\"===typeof a&&null!==a&&a.$$typeof===b};exports.isForwardRef=function(a){return y(a)===k};exports.isFragment=function(a){return y(a)===d};exports.isLazy=function(a){return y(a)===p};exports.isMemo=function(a){return y(a)===n};\nexports.isPortal=function(a){return y(a)===c};exports.isProfiler=function(a){return y(a)===f};exports.isStrictMode=function(a){return y(a)===e};exports.isSuspense=function(a){return y(a)===l};exports.isValidElementType=function(a){return\"string\"===typeof a||\"function\"===typeof a||a===d||a===f||a===v||a===e||a===l||a===m||a===w||\"object\"===typeof a&&null!==a&&(a.$$typeof===p||a.$$typeof===n||a.$$typeof===g||a.$$typeof===h||a.$$typeof===k||a.$$typeof===u||a.$$typeof===q||a[0]===r)?!0:!1};\nexports.typeOf=y;\n"],"sourceRoot":""}