HEX
Server: Apache/2.4.46 (Win64) OpenSSL/1.1.1j PHP/8.4.25
System: Windows NT DESKTOP-4TAV2RJ 10.0 build 19045 (Windows 10) AMD64
User: fred (0)
PHP: 8.4.25
Disabled: NONE
Upload Files
File: C:/Users/fred/anaconda3/share/jupyter/nbextensions/jupyter-js-widgets/extension.js.map
{"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///../node_modules/@lumino/algorithm/dist/index.es6.js","webpack:///../node_modules/@lumino/messaging/dist/index.es6.js","webpack:///../node_modules/underscore/underscore.js","webpack:///../packages/base/lib/utils.js","webpack:///../packages/base/lib/version.js","webpack:///../packages/base/lib/manager-base.js","webpack:///../packages/base/lib/backbone-patch.js","webpack:///../packages/base/lib/nativeview.js","webpack:///../packages/base/lib/widget.js","webpack:///../packages/base/lib/services-shim.js","webpack:///../packages/base/lib/widget_layout.js","webpack:///../packages/base/lib/widget_style.js","webpack:///../packages/base/lib/viewlist.js","webpack:///../packages/base/lib/registry.js","webpack:///../node_modules/@lumino/domutils/dist/index.es6.js","webpack:///../node_modules/@lumino/signaling/dist/index.es6.js","webpack:///../node_modules/@lumino/properties/dist/index.es6.js","webpack:///../node_modules/@lumino/disposable/dist/index.es6.js","webpack:///../node_modules/@lumino/keyboard/dist/index.es6.js","webpack:///../node_modules/@lumino/commands/dist/index.es6.js","webpack:///../node_modules/@lumino/virtualdom/dist/index.es6.js","webpack:///../node_modules/@lumino/dragdrop/dist/index.es6.js","webpack:///../node_modules/@lumino/widgets/dist/index.es6.js","webpack:///../node_modules/@lumino/coreutils/dist/index.es6.js","webpack:///../node_modules/jquery/dist/jquery.js","webpack:///../node_modules/css-loader/dist/runtime/api.js","webpack:///../node_modules/lodash/_root.js","webpack:///../node_modules/lodash/_getNative.js","webpack:///../node_modules/webpack/buildin/global.js","webpack:///../node_modules/lodash/_baseGetTag.js","webpack:///../node_modules/lodash/isObjectLike.js","webpack:///../node_modules/jquery-ui/ui/version.js","webpack:///../node_modules/lodash/_ListCache.js","webpack:///../node_modules/lodash/_assocIndexOf.js","webpack:///../node_modules/lodash/_nativeCreate.js","webpack:///../node_modules/lodash/_getMapData.js","webpack:///../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js","webpack:///../node_modules/backbone/backbone.js","webpack:///../node_modules/webpack/buildin/module.js","webpack:///../node_modules/lodash/_Map.js","webpack:///../node_modules/lodash/_Symbol.js","webpack:///../node_modules/lodash/isArray.js","webpack:///../node_modules/timers-browserify/main.js","webpack:///../packages/controls/lib/utils.js","webpack:///../packages/controls/lib/version.js","webpack:///../packages/controls/lib/widget_description.js","webpack:///../packages/controls/lib/widget_core.js","webpack:///../packages/controls/lib/widget_link.js","webpack:///../packages/controls/lib/widget_bool.js","webpack:///../packages/controls/lib/widget_button.js","webpack:///../packages/controls/lib/widget_box.js","webpack:///../packages/controls/lib/widget_image.js","webpack:///../packages/controls/lib/widget_video.js","webpack:///../packages/controls/lib/widget_audio.js","webpack:///../packages/controls/lib/widget_color.js","webpack:///../packages/controls/lib/widget_date.js","webpack:///../node_modules/d3-format/src/formatDecimal.js","webpack:///../node_modules/d3-format/src/formatSpecifier.js","webpack:///../node_modules/d3-format/src/formatTrim.js","webpack:///../node_modules/d3-format/src/formatPrefixAuto.js","webpack:///../node_modules/d3-format/src/defaultLocale.js","webpack:///../node_modules/d3-format/src/formatRounded.js","webpack:///../node_modules/d3-format/src/formatTypes.js","webpack:///../node_modules/d3-format/src/identity.js","webpack:///../node_modules/d3-format/src/locale.js","webpack:///../node_modules/d3-format/src/formatGroup.js","webpack:///../node_modules/d3-format/src/formatNumerals.js","webpack:///../node_modules/d3-format/src/exponent.js","webpack:///../packages/controls/lib/widget_int.js","webpack:///../packages/controls/lib/widget_float.js","webpack:///../packages/controls/lib/widget_controller.js","webpack:///../packages/controls/lib/widget_selection.js","webpack:///../packages/controls/lib/phosphor/tabpanel.js","webpack:///../packages/controls/lib/phosphor/currentselection.js","webpack:///../packages/controls/lib/phosphor/accordion.js","webpack:///../packages/controls/lib/widget_selectioncontainer.js","webpack:///../packages/controls/lib/widget_string.js","webpack:///../packages/controls/lib/widget_upload.js","webpack:///../packages/controls/lib/index.js","webpack:///../node_modules/base64-js/index.js","webpack:///../node_modules/lodash/eq.js","webpack:///../node_modules/lodash/isFunction.js","webpack:///../node_modules/lodash/_freeGlobal.js","webpack:///../node_modules/lodash/isObject.js","webpack:///../node_modules/lodash/_toSource.js","webpack:///../node_modules/lodash/_MapCache.js","webpack:///../node_modules/lodash/_equalArrays.js","webpack:///../node_modules/lodash/isBuffer.js","webpack:///../node_modules/lodash/isTypedArray.js","webpack:///../node_modules/lodash/isLength.js","webpack:///../node_modules/lodash/_overArg.js","webpack:///../node_modules/jquery-ui/ui/widget.js","webpack:///./src/widget_output.js","webpack:///./src/save_state.js","webpack:///./src/embed_widgets.js","webpack:///../node_modules/lodash/isEqual.js","webpack:///../node_modules/lodash/isPlainObject.js","webpack:///../node_modules/@lumino/collections/dist/index.es6.js","webpack:///./src/extension.js","webpack:///./src/manager.js","webpack:///../node_modules/lodash/_baseIsEqual.js","webpack:///../node_modules/lodash/_baseIsEqualDeep.js","webpack:///../node_modules/lodash/_Stack.js","webpack:///../node_modules/lodash/_listCacheClear.js","webpack:///../node_modules/lodash/_listCacheDelete.js","webpack:///../node_modules/lodash/_listCacheGet.js","webpack:///../node_modules/lodash/_listCacheHas.js","webpack:///../node_modules/lodash/_listCacheSet.js","webpack:///../node_modules/lodash/_stackClear.js","webpack:///../node_modules/lodash/_stackDelete.js","webpack:///../node_modules/lodash/_stackGet.js","webpack:///../node_modules/lodash/_stackHas.js","webpack:///../node_modules/lodash/_stackSet.js","webpack:///../node_modules/lodash/_baseIsNative.js","webpack:///../node_modules/lodash/_getRawTag.js","webpack:///../node_modules/lodash/_objectToString.js","webpack:///../node_modules/lodash/_isMasked.js","webpack:///../node_modules/lodash/_coreJsData.js","webpack:///../node_modules/lodash/_getValue.js","webpack:///../node_modules/lodash/_mapCacheClear.js","webpack:///../node_modules/lodash/_Hash.js","webpack:///../node_modules/lodash/_hashClear.js","webpack:///../node_modules/lodash/_hashDelete.js","webpack:///../node_modules/lodash/_hashGet.js","webpack:///../node_modules/lodash/_hashHas.js","webpack:///../node_modules/lodash/_hashSet.js","webpack:///../node_modules/lodash/_mapCacheDelete.js","webpack:///../node_modules/lodash/_isKeyable.js","webpack:///../node_modules/lodash/_mapCacheGet.js","webpack:///../node_modules/lodash/_mapCacheHas.js","webpack:///../node_modules/lodash/_mapCacheSet.js","webpack:///../node_modules/lodash/_SetCache.js","webpack:///../node_modules/lodash/_setCacheAdd.js","webpack:///../node_modules/lodash/_setCacheHas.js","webpack:///../node_modules/lodash/_arraySome.js","webpack:///../node_modules/lodash/_cacheHas.js","webpack:///../node_modules/lodash/_equalByTag.js","webpack:///../node_modules/lodash/_Uint8Array.js","webpack:///../node_modules/lodash/_mapToArray.js","webpack:///../node_modules/lodash/_setToArray.js","webpack:///../node_modules/lodash/_equalObjects.js","webpack:///../node_modules/lodash/_getAllKeys.js","webpack:///../node_modules/lodash/_baseGetAllKeys.js","webpack:///../node_modules/lodash/_arrayPush.js","webpack:///../node_modules/lodash/_getSymbols.js","webpack:///../node_modules/lodash/_arrayFilter.js","webpack:///../node_modules/lodash/stubArray.js","webpack:///../node_modules/lodash/keys.js","webpack:///../node_modules/lodash/_arrayLikeKeys.js","webpack:///../node_modules/lodash/_baseTimes.js","webpack:///../node_modules/lodash/isArguments.js","webpack:///../node_modules/lodash/_baseIsArguments.js","webpack:///../node_modules/lodash/stubFalse.js","webpack:///../node_modules/lodash/_isIndex.js","webpack:///../node_modules/lodash/_baseIsTypedArray.js","webpack:///../node_modules/lodash/_baseUnary.js","webpack:///../node_modules/lodash/_nodeUtil.js","webpack:///../node_modules/lodash/_baseKeys.js","webpack:///../node_modules/lodash/_isPrototype.js","webpack:///../node_modules/lodash/_nativeKeys.js","webpack:///../node_modules/lodash/isArrayLike.js","webpack:///../node_modules/lodash/_getTag.js","webpack:///../node_modules/lodash/_DataView.js","webpack:///../node_modules/lodash/_Promise.js","webpack:///../node_modules/lodash/_Set.js","webpack:///../node_modules/lodash/_WeakMap.js","webpack:///../node_modules/lodash/_getPrototype.js","webpack:///../node_modules/setimmediate/setImmediate.js","webpack:///../node_modules/process/browser.js","webpack:///../node_modules/jquery-ui/ui/widgets/slider.js","webpack:///../node_modules/jquery-ui/ui/widgets/mouse.js","webpack:///../node_modules/jquery-ui/ui/ie.js","webpack:///../node_modules/jquery-ui/ui/keycode.js","webpack:///./src/widget_output.css?9021","webpack:///./src/widget_output.css","webpack:///../node_modules/@lumino/widgets/style/index.css?22b3","webpack:///../node_modules/@lumino/widgets/style/index.css","webpack:///../node_modules/@lumino/widgets/style/widget.css","webpack:///../node_modules/@lumino/widgets/style/commandpalette.css","webpack:///../node_modules/@lumino/widgets/style/dockpanel.css","webpack:///../node_modules/@lumino/widgets/style/menu.css","webpack:///../node_modules/@lumino/widgets/style/menubar.css","webpack:///../node_modules/@lumino/widgets/style/scrollbar.css","webpack:///../node_modules/@lumino/widgets/style/splitpanel.css","webpack:///../node_modules/@lumino/widgets/style/tabbar.css","webpack:///../node_modules/@lumino/widgets/style/tabpanel.css","webpack:///../packages/base/css/index.css?0d0d","webpack:///../packages/base/css/index.css","webpack:///../packages/controls/css/widgets.css?60b4","webpack:///../packages/controls/css/widgets.css","webpack:///../packages/controls/css/labvariables.css","webpack:///../packages/controls/css/materialcolors.css","webpack:///../packages/controls/css/widgets-base.css","webpack:///../packages/controls/css/phosphor.css","webpack:///../packages/output/lib/output.js"],"names":["installedModules","__webpack_require__","moduleId","exports","module","i","l","modules","call","m","c","d","name","getter","o","Object","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","prototype","hasOwnProperty","p","s","ArrayExt","iter","ArrayIterator","each","fn","index","it","undefined","next","every","some","toArray","result","firstIndexOf","array","start","stop","span","length","Math","max","min","j","lastIndexOf","findFirstIndex","findLastIndex","reverse","a","b","removeAt","findFirstValue","findLastValue","lowerBound","begin","half","middle","upperBound","shallowEqual","slice","options","step","Error","floor","move","fromIndex","toIndex","rotate","delta","pivot","fill","insert","removeFirstOf","removeLastOf","removeAllOf","count","removeFirstWhere","removeLastWhere","removeAllWhere","source","this","_index","_source","clone","KeyIterator","keys","_keys","ValueIterator","ItemIterator","FnIterator","_fn","chain","objects","_i","arguments","ChainIterator","map","_cloned","_active","active","empty","EmptyIterator","EnumerateIterator","filter","FilterIterator","find","MapIterator","Private","RangeIterator","_start","_stop","_step","_length","rangeLength","reduce","initial","first","TypeError","accumulator","second","once","RepeatIterator","Infinity","ceil","_value","_count","retro","RetroArrayIterator","StringExt","StrideIterator","findIndices","query","indices","Array","indexOf","matchSumOfSquares","score","matchSumOfDeltas","last","highlight","k","push","cmp","TakeIterator","ZipIterator","extendStatics","setPrototypeOf","__proto__","MessageLoop","Message","type","configurable","conflate","other","ConflatableMessage","_super","apply","__","constructor","__extends","sendMessage","handler","msg","hooks","messageHooks","hook","messageHook","err","exceptionHandler","invokeHook","invokeHandler","postMessage","isConflatable","messageQueue","posted","enqueueMessage","installMessageHook","set","removeMessageHook","scheduleCleanup","clearData","flush","flushGuard","loopTaskID","unschedule","runMessageLoop","getExceptionHandler","setExceptionHandler","old","WeakMap","dirtySet","Set","console","error","schedule","requestAnimationFrame","setImmediate","cancelAnimationFrame","clearImmediate","processMessage","addLast","isEmpty","sentinel","removeFirst","size","cleanupDirtySet","add","forEach","cleanupHooks","clear","isNull","root","self","global","previousUnderscore","_","ArrayProto","ObjProto","SymbolProto","toString","nativeIsArray","isArray","nativeKeys","nativeCreate","Ctor","obj","_wrapped","nodeType","VERSION","builtinIteratee","optimizeCb","func","context","argCount","collection","cb","iteratee","identity","isFunction","isObject","matcher","restArguments","startIndex","rest","args","baseCreate","shallowProperty","has","path","deepGet","MAX_ARRAY_INDEX","pow","getLength","isArrayLike","collect","results","currentKey","createReduce","dir","reducer","memo","foldl","inject","reduceRight","foldr","detect","predicate","findIndex","findKey","select","list","reject","negate","all","any","contains","includes","include","item","guard","values","invoke","contextPath","method","pluck","where","attrs","findWhere","computed","lastComputed","v","shuffle","sample","random","rand","temp","sortBy","criteria","sort","left","right","group","behavior","partition","groupBy","indexBy","countBy","reStrSymbol","isString","match","pass","head","take","tail","drop","compact","Boolean","flatten","input","shallow","strict","output","idx","isArguments","len","without","otherArrays","difference","uniq","unique","isSorted","isBoolean","seen","union","arrays","intersection","argsLength","unzip","zip","createPredicateIndexFinder","sortedIndex","low","high","mid","createIndexFinder","predicateFind","isNaN","range","chunk","executeBound","sourceFunc","boundFunc","callingContext","bound","callArgs","concat","partial","boundArgs","placeholder","position","bindAll","memoize","hasher","cache","address","delay","wait","setTimeout","defer","throttle","timeout","previous","later","leading","now","throttled","remaining","clearTimeout","trailing","cancel","debounce","immediate","debounced","callNow","wrap","wrapper","compose","after","times","before","hasEnumBug","propertyIsEnumerable","nonEnumerableProps","collectNonEnumProps","nonEnumIdx","proto","prop","allKeys","mapObject","pairs","invert","functions","methods","names","createAssigner","keysFunc","defaults","extend","extendOwn","assign","eq","deepEq","keyInObj","pick","omit","String","props","tap","interceptor","isMatch","aStack","bStack","className","valueOf","areArrays","aCtor","bCtor","pop","isEqual","isElement","nodelist","document","childNodes","Int8Array","isFinite","isSymbol","parseFloat","isNumber","isUndefined","noConflict","constant","noop","propertyOf","matches","accum","Date","getTime","escapeMap","unescapeMap","createEscaper","escaper","join","testRegexp","RegExp","replaceRegexp","string","test","replace","escape","unescape","fallback","idCounter","uniqueId","prefix","id","templateSettings","evaluate","interpolate","noMatch","escapes","escapeRegExp","escapeChar","template","text","settings","oldSettings","render","offset","variable","Function","e","data","argument","instance","_chain","chainResult","mixin","toJSON","__assign","uuid","uuid4","WrappedError","message","_this","warn","error_stack","resolvePromisesDict","Promise","then","log","put_buffers","state","buffer_paths","buffers","buffer_path","remove_buffers","remove","is_cloned","ArrayBuffer","isView","buffer","new_value","hexTable","bufferToHex","x","Uint8Array","hexToBuffer","hex","parseInt","bufferToBase64","base64ToBuffer","base64","JUPYTER_WIDGETS_VERSION","PROTOCOL_VERSION","__awaiter","thisArg","_arguments","P","generator","resolve","fulfilled","rejected","done","__generator","body","f","y","g","label","sent","trys","ops","verb","iterator","op","PROTOCOL_MAJOR_VERSION","split","CONTROL_COMM_TARGET","CONTROL_COMM_PROTOCOL_VERSION","CONTROL_COMM_TIMEOUT","ManagerBase","comm_target_name","_models","display_model","model","create_view","view","display_view","catch","setViewOptions","viewPromise","state_change","loadClass","ViewType","listenTo","model_id","views","callbacks","get_model","has_model","handle_comm_open","comm","protocolVersion","metadata","version","content","DataView","new_model","model_name","model_module","model_module_version","new_widget","serialized_state","commPromise","view_name","view_module","view_module_version","_create_comm","_model_module","_model_module_version","_model_name","_view_module","_view_module_version","_view_name","options_clone","sync","register_model","modelPromise","_a","comm_id","_make_model","model_promise","ModelType","error_1","attributes","modelOptions","widget_model","_deserialize_state","widget_manager","_loadFromKernel","initComm_1","error_2","states","bufferPaths","bufferGroups","widget_id","widget_comms","_b","on_msg","on_close","send","close","_loadFromKernelModels","deserializedState","error_3","set_state","comm_ids","widgets_info","_get_comm_info","msg_id","info","parent_header","header","msg_type","promise","widget_info","clear_state","models","get_state","modelPromises","serialize_state","version_major","live_comms","decode","modelState","encoding","modelCreate","disconnect","comm_live","resolveUrl","url","filterExistingModelState","res","serialize","drop_defaults","version_minor","val","_validate","unset","silent","changes","changing","_changing","_previousAttributes","changed","current","prev","attr","idAttribute","_pending","trigger","ElementProto","Element","matchesSelector","selector","ownerDocument","querySelectorAll","NativeView","_removeElement","undelegateEvents","el","parentNode","removeChild","_setElement","element","_setAttributes","setAttribute","delegate","eventName","listener","_domEvents","node","target","srcElement","delegateTarget","handleEvent","addEventListener","undelegate","handlers","removeEventListener","splice","unpack_models","manager","unpacked_1","sub_value","unpacked_2","pack_models","widget","model_ids","value_1","packed_1","shims","WidgetModel","_view_count","isNew","initialize","_expectedEchoMsgIds","_attrsToUpdate","_closed","_state_lock","_msg_buffer","_msg_buffer_callbacks","_pending_msgs","_buffered_state_diff","_handle_comm_closed","_handle_comm_msg","_comm_live","comm_closed","stopListening","_c","msgId_1","attrName","fullState","defaults_1","state_1","_handle_status","execution_state","msgId","send_sync_message","rememberLastUpdateFor","return_value","changedAttributes","key_1","msgState","serializers","JSON","parse","stringify","statuscb_1","shell","iopub","status","save_changes","patch","save","on_some_change","callback","scope","on","hasChanged","deserialized","deserialize","DOMWidgetModel","_dom_classes","layout","style","WidgetView","parameters","update","displayed","create_child_view","child_model","parent","touch","JupyterPhosphorWidget","_view","dispose","isDisposed","processPhosphorMessage","JupyterPhosphorPanelWidget","DOMWidgetView","new_classes","old_classes","update_classes","layoutPromise","setLayout","stylePromise","setStyle","_comm_live_update","oldLayout","oldLayoutView","unlayout","pWidget","ResizeMessage","UnknownSize","oldStyle","oldStyleView","unstyle","classList","getAttribute","update_mapped_classes","class_map","trait_name","set_mapped_classes","$el","removeClass","addClass","css_properties","align_content","align_items","align_self","border","bottom","display","flex","flex_flow","height","justify_content","justify_items","margin","max_height","max_width","min_height","min_width","overflow","overflow_x","overflow_y","order","padding","top","visibility","width","object_fit","object_position","grid_auto_columns","grid_auto_flow","grid_auto_rows","grid_gap","grid_template_rows","grid_template_columns","grid_template_areas","grid_row","grid_column","grid_area","LayoutModel","LayoutView","_traitNames","registerTrait","trait","handleOverflowChange","handleChange","css_name","removeProperty","StyleModel","Derived","styleProperties","default","StyleView","attribute","elements","services","CommManager","jsServicesKernel","targets","comms","kernel","init_kernel","new_comm","target_name","createComm","Comm","register_comm","open","register_target","handle","registerCommTarget","jsServicesComm","unregister_target","commId","targetName","future","_hookupCallbacks","onMsg","onClose","onReply","reply","onStdin","onIOPub","clear_output","ViewList","remove_view","_handler_context","_create_view","_remove_view","new_models","first_removed","removed","IJupyterWidgetRegistry","ClipboardExt","ElementExt","Platform","Selector","copyText","event","preventDefault","stopPropagation","clipboardData","setData","execCommand","boxSizing","window","getComputedStyle","bt","borderTopWidth","bl","borderLeftWidth","br","borderRightWidth","bb","borderBottomWidth","pt","paddingTop","pl","paddingLeft","pr","paddingRight","pb","paddingBottom","borderTop","borderLeft","borderRight","borderBottom","horizontalSum","verticalSum","sizeLimits","minWidth","minHeight","maxWidth","maxHeight","hitTest","clientX","clientY","rect","getBoundingClientRect","scrollIntoViewIfNeeded","area","ar","er","scrollTop","IS_MAC","navigator","platform","IS_WIN","IS_IE","userAgent","IS_EDGE","accelKey","metaKey","ctrlKey","calculateSpecificity","specificityCache","calculateSingle","isValid","validityCache","testElem","querySelector","protoMatchFunc","createElement","mozMatchesSelector","msMatchesSelector","oMatchesSelector","webkitMatchesSelector","re","NEGATION_RE","ID_RE","CLASS_RE","ATTR_RE","PSEUDO_ELEM_RE","PSEDUO_CLASS_RE","TYPE_RE","IGNORE_RE","Signal","sender","connect","slot","emit","disconnectBetween","receiver","disconnectSender","disconnectReceiver","disconnectAll","receivers","receiversForSender","connection","signal","sendersForReceiver","senders","findConnection","invokeSlot","connections","cleanupConnections","isDeadConnection","AttachedProperty","_pid","nextPID","_create","_coerce","coerce","_compare","compare","_changed","owner","ensureMap","_createValue","oldValue","newValue","_coerceValue","_maybeNotify","_compareValue","ownerData","delete","DisposableSet","DisposableDelegate","ObservableDisposableDelegate","_disposed","_isDisposed","_items","from","items","ObservableDisposableSet","getKeyboardLayout","keyboardLayout","KeycodeLayout","codes","_codes","extractKeys","isValidKey","keyForKeydownEvent","keyCode","EN_US","8","9","13","19","27","32","33","34","35","36","37","38","39","40","45","46","48","49","50","51","52","53","54","55","56","57","59","61","65","66","67","68","69","70","71","72","73","74","75","76","77","78","79","80","81","82","83","84","85","86","87","88","89","90","93","96","97","98","99","100","101","102","103","104","105","106","107","109","110","111","112","113","114","115","116","117","118","119","120","121","122","123","173","186","187","188","189","190","191","192","219","220","221","222","CommandRegistry","_timerID","_replaying","_keystrokes","_keydownEvents","_keyBindings","_exactKeyMatch","_commands","_commandChanged","_commandExecuted","_keyBindingChanged","listCommands","hasCommand","addCommand","createCommand","notifyCommandChanged","emptyObject","cmd","mnemonic","icon","iconClass","iconLabel","caption","usage","dataset","isEnabled","isToggled","isToggleable","isVisible","execute","addKeyBinding","binding","createKeyBinding","processKeydownEvent","keystroke","keystrokeForKeydownEvent","_replayKeydownEvents","_clearPendingState","matchKeyBinding","exact","_executeKeyBinding","_startTimer","_clearTimer","_onPendingTimeout","CHORD_TIMEOUT","replayKeyEvent","command","word","msg1","msg2","parseKeystroke","alt","ctrl","shift","token","normalizeKeystroke","mods","parts","normalizeKeys","winKeys","macKeys","linuxKeys","formatKeystroke","altKey","shiftKey","asFunc","emptyStringFunc","undefinedFunc","negativeOneFunc","emptyDatasetFunc","trueFunc","falseFunc","validateSelector","bindings","distance","specificity","sqm","matchSequence","td","targetDistance","sp","dispatchEvent","createEvent","bubbles","cancelable","initEvent","which","cloneKeyboardEvent","dfault","bindKeys","userKeys","targ","curr","currentTarget","dist","parentElement","hasAttribute","h","VirtualDOM","VirtualText","VirtualElement","tag","children","renderer","VirtualElementPass","arg","values_1","child","abbr","article","aside","audio","bdi","bdo","blockquote","button","canvas","cite","code","col","colgroup","datalist","dd","del","dfn","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","hr","iframe","img","ins","kbd","legend","li","main","mark","meter","nav","noscript","ol","optgroup","option","param","pre","progress","q","rp","rt","ruby","samp","section","small","strong","sub","summary","sup","table","tbody","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var_","video","wbr","realize","createDOMNode","host","oldContent","hostMap","newContent","asContentArray","updateContent","insertBefore","createTextNode","addAttrs","oldKeyed","firstChild","keyMap","content_1","vNode","nextSibling","collectKeys","oldCopy","currElem","newCount","oldVNode","newVNode","newKey","pair","oldKey","updateAttrs","textContent","removeContent","_sentinel","oldNode","lastChild","unrender","specialAttrs","name_1","substr","htmlFor","name_2","addDataset","elemStyle","addStyle","oldAttrs","newAttrs","removeAttribute","oldDataset","newDataset","name_3","name_4","updateDataset","newStyle","updateStyle","Drag","_onScrollFrame","_scrollTarget","edge","SCROLL_EDGE_SIZE","round","scrollLeft","_dropAction","_override","_currentTarget","_currentElement","_promise","_resolve","mimeData","dragImage","proposedAction","supportedActions","event_1","createMouseEvent","dispatchDragLeave","_finalize","_addListeners","_attachDragImage","_evtMouseMove","_evtMouseUp","_evtKeyDown","moveDragImage","_updateCurrentTarget","_updateDragScroll","action","dispatchDrop","_removeListeners","findScrollTarget","prevTarget","currTarget","prevElem","elementFromPoint","dispatchDragExit","dispatchDragEnter","dispatchDragOver","_setDropAction","pointerEvents","appendChild","_detachDragImage","validateAction","overrideCursor","cursor","overrideCursorID","supported","actionTable","supportedTable","initMouseEvent","scrollable","offsetX","offsetY","pageXOffset","pageYOffset","top_1","dr","db","dsw","scrollWidth","clientWidth","dsh","scrollHeight","clientHeight","shouldScroll","drag","dragEvent","createDragEvent","canceled","dropAction","related","screenX","screenY","BoxEngine","BoxSizer","sizeHint","minSize","maxSize","stretch","calc","sizers","space","totalMin","totalMax","totalSize","totalStretch","stretchCount","sizer","hint","notDoneCount","freeSpace","distSpace","distStretch","amt","adjust","growLimit","shrinkLimit","grow","limit","shrink","growSizer","shrinkSizer","Title","_label","_caption","_mnemonic","_iconClass","_iconLabel","_className","_closable","_icon","iconRenderer","closable","_dataset","Widget","_flags","_layout","_parent","createNode","setFlag","Flag","IsDisposed","isAttached","detach","testFlag","IsAttached","IsHidden","IsVisible","titleProperty","ChildMessage","Msg","ParentChanged","DisallowLayout","hasClass","toggleClass","force","toggle","UpdateRequest","fit","FitRequest","activate","ActivateRequest","CloseRequest","show","BeforeShow","clearFlag","AfterShow","hide","BeforeHide","AfterHide","setHidden","hidden","flag","notifyLayout","onResize","onUpdateRequest","onFitRequest","onBeforeShow","onAfterShow","onBeforeHide","onAfterHide","onBeforeAttach","isHidden","onAfterAttach","onBeforeDetach","onAfterDetach","onActivateRequest","onCloseRequest","onChildAdded","onChildRemoved","processParentMessage","BeforeAttach","AfterAttach","BeforeDetach","AfterDetach","attach","ref","Layout","_fitPolicy","fitPolicy","init","onChildShown","onChildHidden","removeWidget","getHorizontalAlignment","Private$1","horizontalAlignmentProperty","setHorizontalAlignment","getVerticalAlignment","verticalAlignmentProperty","setVerticalAlignment","LayoutItem","_top","NaN","_left","_width","_height","_minWidth","_minHeight","_maxWidth","_maxHeight","limits","clampW","clampH","resized","onAlignmentChanged","BoxLayout","Private$2","PanelLayout","_widgets","addWidget","insertWidget","attachWidget","moveWidget","removeWidgetAt","detachWidget","_fixed","_spacing","_dirty","_sizers","_box","_alignment","_direction","direction","alignment","spacing","clampSpacing","_update","_fit","nVisible","horz","isHorizontal","minW","minH","getSizeBasis","getStretch","box","offsetWidth","offsetHeight","extra","stretchProperty","setStretch","sizeBasisProperty","setSizeBasis","onChildSizingChanged","Private$3","Panel","createLayout","widgets","Private$4","BoxPanel","CommandPalette","Renderer","Private$5","_activeIndex","_results","commands","defaultRenderer","commandChanged","_onGenericChange","keyBindingChanged","getElementsByClassName","addItem","createItem","refresh","addItems","newItems","removeItem","removeItemAt","clearItems","inputNode","_evtClick","_toggleFocused","focus","contentNode","search","canActivate","renderEmptyMessage","activeIndex","category","renderHeader","renderItem","_execute","_activatePreviousItem","_activateNextItem","ai","part","toLowerCase","focused","activeElement","formatHeader","createItemClass","createItemDataset","renderItemIcon","renderItemContent","renderItemShortcut","formatEmptyMessage","createIconClass","renderItemLabel","renderItemCaption","formatItemLabel","formatItemCaption","formatItemShortcut","kb","keyBinding","fuzzySearch","rgx","rgxMatch","exec","categoryIndices","labelIndices","matchType","scoreCmp","m1","d1","i1","i2","d2","localeCompare","r1","rank","r2","spellcheck","CommandItem","scores","matchItems","visited","item_1","createResults","trim","keyBindings","deepEqual","Private$6","Menu","_childIndex","_openTimerID","_closeTimerID","_childMenu","_parentMenu","_aboutToClose","_menuRequested","menu","activateNextItem","activatePreviousItem","triggerActiveItem","activeItem","_cancelOpenTimer","_cancelCloseTimer","rootMenu","_openChildMenu","insertItem","forceX","forceY","openRootMenu","_evtMouseEnter","_evtMouseLeave","_evtMouseDown","collapsedFlags","computeCollapsed","collapsed","childMenu","parentMenu","kc","findMnemonic","multiple","auto","_startCloseTimer","submenu","_startOpenTimer","hitTestMenus","activateFirst","_closeChildMenu","itemNode","openSubmenu","TIMER_DELAY","aria","createItemARIA","renderIcon","renderLabel","renderShortcut","renderSubmenu","formatLabel","formatShortcut","role","suffix","char","SUBMENU_OVERLAP","tabIndex","MenuItem","k1","k2","px","py","cw","documentElement","ch","itemRect","upperKey","toUpperCase","mn","command_1","args_1","Private$7","ContextMenu","_idTick","itemCmp","s1","s2","availableItems","Private$8","DockLayout","_root","Map","iterAllWidgets","iterUserWidgets","selectedWidgets","iterSelectedWidgets","tabBars","iterTabBars","handles","iterHandles","moveHandle","findSplitNode","orientation","offsetLeft","offsetTop","holdSizes","saveLayout","holdAllSizes","createConfig","restoreLayout","config","mainConfig","widgetSet","normalizeAreaConfig","oldWidgets","oldTabBars","oldHandles","tabBar","realizeAreaConfig","createTabBar","_createTabBar","createHandle","_createHandle","refNode","findTabNode","_insertTab","_insertSplit","_removeWidget","hitTestTabAreas","tabNode","hitTestTabNodes","borderWidth","borderHeight","titles","removeTab","splitNode","syncHandles","maybeParent","childNode","childHandle","TabLayoutNode","splitHandle","i_1","gChild","gHandle","gSizer","addTab","findFirstTabNode","currentIndex","insertTab","_splitRoot","i_2","normalizeSizes","createSizer","GOLDEN_RATIO","i_3","j_1","SplitLayoutNode","normalized","oldRoot","newRoot","normalizeTabAreaConfig","sizes","abs","normalizeSplitAreaConfig","realizeTabAreaConfig","realizeSplitAreaConfig","tabSizer","widgetSizer","currentTitle","tabBarItem","widgetItem","tabBarSizer","createNormalizedSizes","sum","horizontal","fixed","handleStyle","Private$9","TabBar","_currentIndex","_titles","_titlesEditable","_previousTitle","_dragData","_tabMoved","_currentChanged","_tabCloseRequested","_tabDetachRequested","_tabActivateRequested","tabsMovable","titlesEditable","allowDeselect","insertBehavior","removeBehavior","_orientation","_releaseMouse","pi","ci","ct","previousIndex","previousTitle","asTitle","_onTitleChanged","_adjustCurrentForInsert","_adjustCurrentForMove","removeTabAt","_adjustCurrentForRemove","clearTabs","releaseMouse","_evtDblClick","zIndex","renderTab","tabs","tab","oldValue_1","innerHTML","input_1","onblur_1","pressX","pressY","tabPos","tabSize","tabPressPos","targetIndex","tabLayout","contentRect","override","dragActive","dragAborted","detachRequested","closeIconSelector","dragExceeded","tabRect","snapTabLayout","detachExceeded","layoutTabs","finalizeTabPosition","duration","parseTransitionDuration","resetTabPositions","bh","_tabID","_tabKeys","createTabKey","createTabStyle","createTabClass","createTabDataset","renderCloseIcon","DRAG_THRESHOLD","DETACH_THRESHOLD","transitionDuration","pos","marginLeft","marginTop","dx","dy","pressPos","localPos","clientPos","clientSize","targetPos","targetEnd","pxPos","threshold","ideal","tgt","final","Private$a","DockPanel","_drag","_tabsMovable","_tabsConstrained","_pressData","_layoutModified","_mode","_renderer","_edges","edges","DEFAULT_EDGES","tabsConstrained","overlay","Overlay","createSingleDocumentConfig","LayoutModified","tabbar","selectWidget","bar","activateWidget","_evtDragEnter","_evtDragLeave","_evtDragOver","_evtDrop","isGeneratedTabBarProperty","hasData","_showOverlay","findDropTarget","zone","factory","getData","getDropRef","deltaX","deltaY","xPos","yPos","tabHeight","tabMoved","_onTabMoved","currentChanged","_onCurrentChanged","tabCloseRequested","_onTabCloseRequested","tabDetachRequested","_onTabDetachRequested","tabActivateRequested","_onTabActivateRequested","cloneNode","_timer","_hidden","geo","panel","selected","panelRect","al","at","ab","rx","ry","GridLayout","Private$b","FocusTracker","_counter","_activeWidget","_currentWidget","_numbers","_nodes","_activeChanged","w","focusNumber","disposed","_onWidgetDisposed","_setWidgets","valid","_evtFocus","_evtBlur","oldCurrent","oldActive","focusTarget","relatedTarget","_rowSpacing","_columnSpacing","_rowStarts","_columnStarts","_rowSizers","_columnSizers","rowCount","reallocSizers","columnCount","rowSpacing","clampValue","columnSpacing","rowStretch","setRowStretch","columnStretch","setColumnStretch","maxRow","maxCol","rowSpanCmp","getCellConfig","row","rowSpan","distributeMin","columnSpanCmp","c1","column","c2","columnSpan","fixedRowSpace","fixedColSpace","cellConfigProperty","setCellConfig","normalizeConfig","portion","Private$c","MenuBar","_menus","openActiveMenu","addMenu","insertMenu","aboutToClose","_onMenuAboutToClose","menuRequested","_onMenuMenuRequested","removeMenu","removeMenuAt","clearMenus","menus","blur","stopImmediatePropagation","newMenu","activeMenu","oldMenu","Private$d","ScrollBar","_onRepeat","_repeatTimer","mouseX","mouseY","trackNode","thumbNode","thumbRect","_pageRequested","incrementNode","_stepRequested","decrementNode","_page","_maximum","_thumbMoved","maximum","page","thumbStyle","transform","_moveThumb","findPart","trackPos","trackSpan","trackRect","decrement","increment","thumb","scrollBar","SplitLayout","Private$e","SingletonLayout","_widget","_hasNormedSizes","_handles","relativeSizes","normalize","setRelativeSizes","normed","average","averageSize","lastHandleIndex","Private$f","SplitPanel","Private$g","StackedLayout","StackedPanel","_widgetRemoved","Private$h","TabPanel","stackedPanel","widgetRemoved","_onWidgetRemoved","_tabPlacement","tabPlacement","directionFromPlacement","orientationFromPlacement","currentWidget","previousWidget","plc","placementToOrientationMap","placementToDirectionMap","JSONExt","isPrimitive","a1","a2","deepArrayEqual","firstValue","secondValue","deepObjectEqual","deepCopy","deepArrayCopy","subvalue","deepObjectCopy","freeze","emptyArray","Random","MimeData","_types","_values","types","mime","PromiseDelegate","_reject","reason","crypto","getRandomValues","msCrypto","randomFillSync","randomBytes","bytes","UUID","Token","_tokenStructuralPropertyT","lut","noGlobal","arr","getProto","getPrototypeOf","class2type","hasOwn","fnToString","ObjectFunctionString","support","isWindow","preservedScriptAttributes","src","nonce","noModule","DOMEval","doc","script","toType","jQuery","rtrim","jquery","num","pushStack","elems","ret","merge","prevObject","elem","end","copy","copyIsArray","deep","isPlainObject","expando","isReady","isEmptyObject","globalEval","makeArray","inArray","grep","callbackExpect","guid","Sizzle","Expr","getText","isXML","tokenize","compile","outermostContext","sortInput","hasDuplicate","setDocument","docElem","documentIsHTML","rbuggyQSA","rbuggyMatches","preferredDoc","dirruns","classCache","createCache","tokenCache","compilerCache","nonnativeSelectorCache","sortOrder","push_native","booleans","whitespace","identifier","pseudos","rwhitespace","rcomma","rcombinators","rdescend","rpseudo","ridentifier","matchExpr","rhtml","rinputs","rheader","rnative","rquickExpr","rsibling","runescape","funescape","escaped","escapedWhitespace","fromCharCode","rcssescape","fcssescape","asCodePoint","charCodeAt","unloadHandler","inDisabledFieldset","addCombinator","disabled","nodeName","els","seed","nid","groups","newSelector","newContext","getElementById","getElementsByTagName","qsa","toSelector","testContext","qsaError","cacheLength","markFunction","assert","addHandle","attrHandle","siblingCheck","cur","diff","sourceIndex","createInputPseudo","createButtonPseudo","createDisabledPseudo","isDisabled","createPositionalPseudo","matchIndexes","namespace","namespaceURI","hasCompare","subWindow","defaultView","attachEvent","createComment","getById","getElementsByName","attrId","getAttributeNode","tmp","disconnectedMatch","compareDocumentPosition","adown","bup","sortDetached","aup","ap","bp","unshift","expr","specified","sel","uniqueSort","duplicates","detectDuplicates","sortStable","nodeValue","selectors","createPseudo","relative","preFilter","excess","unquoted","nodeNameSelector","pattern","operator","check","what","simple","forward","ofType","xml","uniqueCache","outerCache","nodeIndex","useCache","uniqueID","pseudo","setFilters","matched","unmatched","lang","elemLang","hash","location","hasFocus","href","checked","selectedIndex","radio","checkbox","file","password","image","submit","reset","tokens","combinator","base","skip","checkNonElements","doneName","oldCache","newCache","elementMatcher","matchers","condense","newUnmatched","mapped","setMatcher","postFilter","postFinder","postSelector","preMap","postMap","preexisting","contexts","multipleContexts","matcherIn","matcherOut","matcherFromTokens","checkContext","leadingRelative","implicitRelative","matchContext","matchAnyContext","filters","parseOnly","soFar","preFilters","cached","setMatchers","elementMatchers","bySet","byElement","superMatcher","outermost","matchedCount","setMatched","contextBackup","dirrunsUnique","matcherFromGroupMatchers","compiled","defaultValue","isXMLDoc","escapeSelector","until","truncate","is","siblings","rneedsContext","needsContext","rsingleTag","winnow","qualifier","not","rootjQuery","parseHTML","ready","rparentsprev","guaranteedUnique","contents","sibling","closest","prevAll","addBack","parents","parentsUntil","nextAll","nextUntil","prevUntil","contentDocument","rnothtmlwhite","Identity","Thrower","ex","adoptValue","noValue","fail","Callbacks","createOptions","firing","memory","fired","locked","queue","firingIndex","fire","stopOnFalse","disable","lock","fireWith","Deferred","tuples","always","deferred","pipe","fns","newDefer","tuple","returned","notify","onFulfilled","onRejected","onProgress","maxDepth","depth","special","that","mightThrow","notifyWith","resolveWith","process","exceptionHook","stackTrace","rejectWith","getStackHook","stateString","when","singleValue","resolveContexts","resolveValues","master","updateFunc","rerrorNames","stack","readyException","readyList","completed","readyWait","readyState","doScroll","access","chainable","emptyGet","raw","bulk","rmsPrefix","rdashAlpha","fcamelCase","letter","camelCase","acceptData","Data","uid","dataPriv","dataUser","rbrace","rmultiDash","dataAttr","removeData","_data","_removeData","dequeue","startLength","_queueHooks","setter","clearQueue","pnum","rcssNum","cssExpand","composed","getRootNode","isHiddenWithinTree","css","swap","adjustCSS","valueParts","tween","adjusted","scale","maxIterations","currentValue","unit","cssNumber","initialInUnit","defaultDisplayMap","getDefaultDisplay","showHide","rcheckableType","rtagName","rscriptType","wrapMap","_default","getAll","setGlobalEval","refElements","buildFragment","scripts","selection","ignored","attached","fragment","createDocumentFragment","nodes","htmlPrefilter","checkClone","noCloneChecked","rkeyEvent","rmouseEvent","rtypenamespace","returnTrue","returnFalse","expectSync","safeActiveElement","one","origFn","off","leverageNative","notAsync","saved","isTrigger","delegateType","Event","handleObjIn","eventHandle","events","handleObj","namespaces","origType","elemData","triggered","dispatch","bindType","delegateCount","setup","mappedTypes","origCount","teardown","removeEvent","nativeEvent","handlerQueue","fix","preDispatch","isPropagationStopped","isImmediatePropagationStopped","rnamespace","postDispatch","matchedHandlers","matchedSelectors","addProp","originalEvent","writable","load","noBubble","click","beforeunload","returnValue","isDefaultPrevented","defaultPrevented","timeStamp","isSimulated","changedTouches","detail","eventPhase","pageX","pageY","charCode","buttons","pointerId","pointerType","targetTouches","toElement","touches","mouseenter","mouseleave","pointerenter","pointerleave","orig","rxhtmlTag","rnoInnerhtml","rchecked","rcleanScript","manipulationTarget","disableScript","restoreScript","cloneCopyEvent","dest","pdataOld","pdataCur","udataOld","udataCur","fixInput","domManip","hasScripts","iNoClone","valueIsFunction","html","_evalUrl","keepData","cleanData","dataAndEvents","deepDataAndEvents","srcElements","destElements","inPage","append","prepend","replaceWith","replaceChild","appendTo","prependTo","insertAfter","replaceAll","original","rnumnonpx","getStyles","opener","rboxStyle","curCSS","getPropertyValue","pixelBoxStyles","addGetHookIf","conditionFn","hookFn","computeStyleTests","container","cssText","divStyle","pixelPositionVal","reliableMarginLeftVal","roundPixelMeasures","pixelBoxStylesVal","boxSizingReliableVal","scrollboxSizeVal","measure","backgroundClip","clearCloneStyle","boxSizingReliable","pixelPosition","reliableMarginLeft","scrollboxSize","cssPrefixes","emptyStyle","vendorProps","finalPropName","cssProps","capName","vendorPropName","rdisplayswap","rcustomProp","cssShow","cssNormalTransform","letterSpacing","fontWeight","setPositiveNumber","subtract","boxModelAdjustment","dimension","isBorderBox","styles","computedVal","getWidthOrHeight","valueIsBorderBox","offsetProp","getClientRects","Tween","easing","cssHooks","opacity","origName","isCustomProp","setProperty","scrollboxSizeBuggy","expand","expanded","propHooks","run","percent","eased","fx","linear","swing","cos","PI","fxNow","inProgress","rfxtypes","rrun","interval","tick","createFxNow","genFx","includeWidth","createTween","animation","Animation","tweeners","properties","stopped","prefilters","currentTime","startTime","tweens","opts","specialEasing","originalProperties","originalOptions","gotoEnd","propFilter","complete","timer","anim","tweener","oldfire","propTween","restoreDisplay","isBox","dataShow","unqueued","overflowX","overflowY","prefilter","speed","opt","speeds","fadeTo","to","animate","optall","doAnimation","finish","stopQueue","timers","cssFn","slideDown","slideUp","slideToggle","fadeIn","fadeOut","fadeToggle","slow","fast","checkOn","optSelected","radioValue","boolHook","removeAttr","nType","attrHooks","bool","attrNames","lowercaseName","rfocusable","rclickable","stripAndCollapse","getClass","classesToArray","removeProp","propFix","tabindex","classes","curValue","clazz","finalValue","stateVal","isValidValue","classNames","rreturn","valHooks","optionSet","focusin","rfocusMorph","stopPropagationCallback","onlyHandlers","bubbleType","ontype","lastElement","eventPath","parentWindow","simulate","triggerHandler","attaches","rquery","parseXML","DOMParser","parseFromString","rbracket","rCRLF","rsubmitterTypes","rsubmittable","buildParams","traditional","valueOrFunction","encodeURIComponent","serializeArray","r20","rhash","rantiCache","rheaders","rnoContent","rprotocol","transports","allTypes","originAnchor","addToPrefiltersOrTransports","structure","dataTypeExpression","dataType","dataTypes","inspectPrefiltersOrTransports","jqXHR","inspected","seekingTransport","inspect","prefilterOrFactory","dataTypeOrTransport","ajaxExtend","flatOptions","ajaxSettings","lastModified","etag","isLocal","protocol","processData","async","contentType","accepts","json","responseFields","converters","ajaxSetup","ajaxPrefilter","ajaxTransport","ajax","transport","cacheURL","responseHeadersString","responseHeaders","timeoutTimer","urlAnchor","fireGlobals","uncached","callbackContext","globalEventContext","completeDeferred","statusCode","requestHeaders","requestHeadersNames","strAbort","getResponseHeader","getAllResponseHeaders","setRequestHeader","overrideMimeType","mimeType","abort","statusText","finalText","crossDomain","hasContent","ifModified","headers","beforeSend","success","nativeStatusText","responses","isSuccess","response","modified","finalDataType","firstDataType","ajaxHandleResponses","conv2","conv","dataFilter","throws","ajaxConvert","getJSON","getScript","wrapAll","firstElementChild","wrapInner","htmlIsFunction","unwrap","visible","xhr","XMLHttpRequest","xhrSuccessStatus","0","1223","xhrSupported","cors","errorCallback","username","xhrFields","onload","onerror","onabort","ontimeout","onreadystatechange","responseType","responseText","binary","scriptAttrs","charset","scriptCharset","evt","oldCallbacks","rjsonp","jsonp","jsonpCallback","originalSettings","callbackName","overwritten","responseContainer","jsonProp","createHTMLDocument","implementation","keepScripts","parsed","params","animated","setOffset","curPosition","curLeft","curCSSTop","curTop","curOffset","curCSSLeft","curElem","using","win","offsetParent","parentOffset","scrollTo","Height","Width","defaultExtra","funcName","hover","fnOver","fnOut","unbind","proxy","holdReady","hold","parseJSON","isNumeric","_jQuery","_$","$","useSourceMap","cssMapping","btoa","sourceMapping","sourceMap","sourceURLs","sources","sourceRoot","cssWithMappingToString","mediaQuery","freeGlobal","freeSelf","baseIsNative","getValue","getRawTag","objectToString","symToStringTag","ui","listCacheClear","listCacheDelete","listCacheGet","listCacheHas","listCacheSet","ListCache","entries","entry","getNative","isKeyable","__data__","isOldIE","atob","getTarget","styleTarget","HTMLIFrameElement","stylesInDom","modulesToDom","media","insertStyleElement","textStore","replaceText","replacement","applyToSingletonTag","styleSheet","cssNode","applyToTag","singleton","singletonCounter","styleIndex","removeStyleElement","newObj","newList","Backbone","previousBackbone","emulateHTTP","emulateJSON","addUnderscoreMethods","Class","defaultVal","addMethod","_isModel","modelMatcher","Events","eventSplitter","eventsApi","internalOn","listening","_events","onApi","ctx","_listeners","_listenId","listeningTo","_listeningTo","thisId","objId","offApi","listeners","ids","_callback","onceMap","listenToOnce","offer","triggerApi","objEvents","allEvents","triggerEvents","ev","a3","Model","cid","cidPrefix","validationError","previousAttributes","fetch","resp","serverAttrs","wrapError","validate","destroy","urlError","Collection","comparator","_reset","setOptions","addOptions","singular","_removeModels","toAdd","toRemove","modelMap","sortable","sortAttr","existing","_prepareModel","_addReference","orderChanged","_removeReference","previousModels","modelId","_byId","callbackOpts","_onModelEvent","prevId","View","viewOptions","_ensureElement","delegateEventSplitter","tagName","setElement","delegateEvents","_createElement","methodMap","_method","textStatus","errorThrown","Router","routes","_bindRoutes","optionalParam","namedParam","splatParam","route","isRegExp","_routeToRegExp","router","history","_extractParameters","navigate","optional","decodeURIComponent","History","checkUrl","routeStripper","rootStripper","pathStripper","started","atRoot","pathname","getSearch","matchRoot","decodeFragment","decodeURI","getHash","getPath","charAt","getFragment","_usePushState","_wantsHashChange","hashChange","_hasHashChange","documentMode","_useHashChange","_wantsPushState","pushState","_hasPushState","iWindow","contentWindow","_checkUrlInterval","setInterval","loadUrl","detachEvent","clearInterval","_updateHash","protoProps","staticProps","Surrogate","__super__","webpackPolyfill","deprecate","paths","Timeout","clearFn","_id","_clearFn","unref","enroll","msecs","_idleTimeoutId","_idleTimeout","unenroll","_unrefActive","_onTimeout","wrapped_error","typeset","MathJax","Hub","Queue","escape_html","esc","JUPYTER_CONTROLS_VERSION","DescriptionStyleModel","description_width","DescriptionModel","description","description_tooltip","DescriptionView","updateDescription","LabeledDOMWidgetModel","LabeledDOMWidgetView","CoreWidgetModel","CoreDOMWidgetModel","CoreDescriptionModel","DirectionalLinkModel","updateBindings","updateValue","sourceModel","sourceAttr","targetModel","targetAttr","_updating","cleanup","LinkModel","BoolModel","CheckboxModel","indent","CheckboxView","checkboxLabel","descriptionSpan","updateIndent","_handle_click","updated_view","ToggleButtonModel","tooltip","button_style","ToggleButtonView","update_button_style","set_button_style","primary","warning","danger","ValidModel","readout","ValidView","ButtonStyleModel","button_color","font_weight","ButtonModel","ButtonView","BoxModel","box_style","HBoxModel","VBoxModel","BoxView","children_views","add_child_model","update_children","update_box_style","set_box_style","dummy","HBoxView","VBoxView","GridBoxView","GridBoxModel","ImageModel","format","ImageView","blob","Blob","URL","createObjectURL","TextDecoder","oldurl","revokeObjectURL","VideoModel","autoplay","loop","controls","VideoView","AudioModel","AudioView","ColorPickerModel","concise","ColorPickerView","_color_container","_textbox","_colorpicker","_update_value","_update_concise","_picker_change","_text_change","color","rgb","named_colors","_validate_color","aliceblue","antiquewhite","aqua","aquamarine","azure","beige","bisque","black","blanchedalmond","blue","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgrey","darkgreen","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkslategrey","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dimgrey","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","grey","green","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgreen","lightgray","lightgrey","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightslategrey","lightsteelblue","lightyellow","lime","limegreen","linen","magenta","maroon","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","navy","oldlace","olive","olivedrab","orange","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","purple","red","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","silver","skyblue","slateblue","slategray","slategrey","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen","serialize_date","year","getUTCFullYear","month","getUTCMonth","date","getUTCDate","deserialize_date","setUTCFullYear","setUTCHours","DatePickerModel","DatePickerView","_datepicker","_picker_focusout","valueAsDate","validity","badInput","toExponential","coefficient","formatSpecifier","specifier","FormatSpecifier","align","sign","symbol","zero","comma","precision","prefixExponent","formatDecimal","exponent","toFixed","toPrecision","formatRounded","prefixes","locale","grouping","thousands","Number","substring","currencyPrefix","currency","currencySuffix","decimal","numerals","formatNumerals","minus","nan","newFormat","formatTypes","formatType","maybeSuffix","valuePrefix","valueSuffix","valueNegative","out","i0","formatTrim","formatPrefix","IntModel","BoundedIntModel","SliderStyleModel","handle_color","IntSliderModel","readout_format","continuous_update","update_readout_format","readout_formatter","IntRangeSliderModel","BaseIntSliderView","_parse_value","$slider","slider","slide","handleSliderChange","handleSliderChanged","slider_container","contentEditable","that_1","model_value","orientation_1","readout_overflow","handleKeyDown","handleTextChange","_validate_slide_value","IntRangeSliderView","_range_regex","valueToString","stringToValue","vmin","vmax","actual_value","IntSliderView","IntTextModel","BoundedIntTextModel","IntTextView","_default_step","textbox","required","handleKeypress","handleKeyUp","handleChanging","trimmed","handleChanged","numericalValue","boundedValue","ProgressStyleModel","bar_color","IntProgressModel","bar_style","ProgressView","update_bar_style","set_bar_style","PlayModel","_playing","_repeat","show_repeat","next_value","schedule_next","pause","play","repeat","PlayView","playButton","pauseButton","stopButton","repeatButton","playIcon","pauseIcon","stopIcon","repeatIcon","onclick","update_playing","update_repeat","playing","FloatModel","BoundedFloatModel","FloatSliderModel","_range","slider_color","FloatLogSliderModel","FloatRangeSliderModel","FloatSliderView","FloatLogSliderView","log_value","FloatRangeSliderView","FloatTextModel","BoundedFloatTextModel","FloatTextView","FloatProgressModel","ControllerButtonModel","pressed","ControllerButtonView","background","textAlign","ControllerAxisModel","ControllerAxisView","bullet","ControllerModel","mapping","connected","timestamp","axes","getGamepads","update_loop","wait_loop","pad","btn","_create_button_model","axis","_create_axis_model","reset_gamepad","ControllerView","button_views","add_button","axis_views","add_axis","update_label","axis_box","button_box","SelectionModel","_options_labels","DropdownModel","DropdownView","_updateOptions","listbox","_handle_change","SelectModel","rows","SelectView","updateSelection","RadioButtonsModel","tooltips","icons","RadioButtonsView","radios","stale","item_query","radio_el","adjustPadding","elStyles","margins","marginBottom","lineHeight","cStyles","containerMargin","extraMargin","ToggleButtonsStyleModel","button_width","ToggleButtonsModel","ToggleButtonsView","_css_state","buttongroup","previous_icons","previous_bstyle","classMap","item_html","update_style_traits","SelectionSliderModel","SelectionSliderView","updateReadout","MultipleSelectionModel","SelectMultipleModel","SelectMultipleView","listboxOptions","selectedOptions","SelectionRangeSliderModel","SelectionRangeSliderView","labels","minValue","maxValue","EventedPanel","tabContents","Selection","sequence","_array","_previousValue","_selectionChanged","_insertBehavior","_removeBehavior","adjustSelectionForSet","pv","_updateSelectedValue","cv","previousValue","adjustSelectionForInsert","adjustSelectionForMove","clearSelection","adjustSelectionForRemove","Collapse","_collapseChanged","_header","_content","oldWidget","_onChildDisposed","_collapsed","_collapse","_uncollapse","Accordion","_selection","selectionChanged","_onSelectionChanged","collapseWidgets","collapse","_wrapWidget","collapseChanged","_onCollapseChange","change","SelectionContainerModel","selected_index","AccordionModel","JupyterPhosphorAccordionWidget","AccordionView","add_child_view","remove_child_view","updateChildren","update_selected_index","update_titles","accordion","updatingChildren","TabModel","JupyterPhosphorTabPanelWidget","TabView","updatingTabs","childrenViews","addChildView","updateTabs","updateTitles","_onTabChanged","updateSelectedIndex","StringModel","HTMLModel","HTMLView","HTMLMathModel","HTMLMathView","LabelModel","LabelView","TextareaModel","TextareaView","update_placeholder","TextModel","TextView","inputType","update_title","PasswordModel","PasswordView","ComboboxModel","ensure_options","ComboboxView","isInitialRender","highlightValidState","optLines","__spreadArrays","il","jl","FileUploadModel","accept","FileUploadView","fileInput","promisesFile","files","fileReader","FileReader","readAsArrayBuffer","li_buffer","counter","byteLength","b64","lens","getLens","validLen","placeHoldersLen","toByteArray","Arr","_byteLength","curByte","revLookup","fromByteArray","uint8","extraBytes","len2","encodeChunk","lookup","baseGetTag","funcToString","mapCacheClear","mapCacheDelete","mapCacheGet","mapCacheHas","mapCacheSet","MapCache","SetCache","arraySome","cacheHas","bitmask","customizer","equalFunc","isPartial","arrLength","othLength","stacked","arrValue","othValue","compared","othIndex","stubFalse","freeExports","freeModule","Buffer","isBuffer","baseIsTypedArray","baseUnary","nodeUtil","nodeIsTypedArray","isTypedArray","widgetUuid","widgetSlice","existingConstructor","basePrototype","proxiedPrototype","fullName","_createWidget","_proto","_childConstructors","_superApply","__super","__superApply","widgetEventPrefix","widgetName","widgetFullName","childPrototype","bridge","inputIndex","inputLength","isMethodCall","methodValue","_init","defaultElement","eventNamespace","hoverable","focusable","classesElementLookup","_on","_getCreateOptions","_setOptionDisabled","_trigger","_getCreateEventData","_destroy","_removeClass","curOption","_setOptions","_setOption","_setOptionClasses","classKey","currentElements","_classes","_toggleClass","enable","full","processClassString","checkOption","_untrackClassesElement","_addClass","suppressDisabledCheck","delegateElement","handlerProxy","_off","_delay","_hoverable","_focusable","focusout","defaultEffect","hasOptions","effect","effectName","effects","outputBase","outputArea","requirejs","OutputModel","outputs","reset_msg_id","set_callbacks_for_msg","output_area","OutputArea","prompt_area","notebook","keyboard_manager","handle_output","newMessage","handle_clear_output","setOutputs","iopubCallbacks","prev_msg_id","previous_callback","output_callback_overrides_pop","output_callback_overrides_push","fromJSON","OutputView","help","help_index","Jupyter","wm","WidgetManager","_managers","download","actions","register","VIEW_MIME_TYPE","escapeScript","dialog","get_cells","cell","modal","class","baseIsEqual","getPrototype","isObjectLike","funcProto","objectProto","objectCtorString","BPlusTree","LeafNode","firstLeaf","lastLeaf","iterItems","retroItems","sliceItems","retroSlice","retroSliceItems","itemAt","hasItem","getItem","maybeSplitRoot","deleteItem","maybeExtractRoot","tree","BranchNode","leaf","ForwardIterator","RetroIterator","findPivotIndexByIndex","findPivotIndexByKey","findKeyIndex","existing_1","i_4","prevSize","currSize","MAX_NODE_WIDTH","updateSizes","i_5","MIN_NODE_WIDTH","joinChild","_node","next_1","v1_1","v2_1","v1","v2","_d","_e","_f","hasNext","isLeaf","hasExtra","LinkedList","_first","_last","_size","ForwardValueIterator","RetroValueIterator","ForwardNodeIterator","retroNodes","RetroNodeIterator","removeLast","addFirst","LinkedListNode","_ref","removeNode","MIME_TYPE","mngr","PhosphorWidget","NOTEBOOK_VERSION_INFO","NOTEBOOK_MAJOR","NOTEBOOK_MINOR","NOTEBOOK_PATCH","RENDER_SHOULD_THROW","handle_kernel","comm_manager","register_events","outputarea","removeView","viewids","_jupyterWidgetViews","register_mime_type","md","toinsert","create_output_subarea","safe","load_ipython_extension","outputWidgets","saveState","embedWidgets","polyfill_new_comm_buffers","send_shell_message","super","widget_md","render_cell_output","_init_actions","_init_menu","moduleName","moduleVersion","require","mod","notification_area","saveWidgetsAction","menubar","clearWidgetsAction","widgetsMenu","helpMenu","widgetsMenuLink","innerText","widgetsSubmenu","divider","_createMenuItem","itemLink","_get_connected_kernel","need_polyfill","comm_info","is_connected","iopub_callbacks","baseIsEqualDeep","Stack","equalArrays","equalByTag","equalObjects","getTag","objectTag","objIsArr","othIsArr","objTag","othTag","objIsObj","othIsObj","isSameTag","objIsWrapped","othIsWrapped","objUnwrapped","othUnwrapped","stackClear","stackDelete","stackGet","stackHas","stackSet","assocIndexOf","LARGE_ARRAY_SIZE","isMasked","toSource","reIsHostCtor","reIsNative","nativeObjectToString","isOwn","unmasked","coreJsData","maskSrcKey","IE_PROTO","Hash","hashClear","hashDelete","hashGet","hashHas","hashSet","getMapData","setCacheAdd","setCacheHas","mapToArray","setToArray","symbolProto","symbolValueOf","byteOffset","convert","getAllKeys","objProps","objLength","skipCtor","objValue","objCtor","othCtor","baseGetAllKeys","getSymbols","arrayPush","symbolsFunc","arrayFilter","stubArray","nativeGetSymbols","getOwnPropertySymbols","resIndex","arrayLikeKeys","baseKeys","baseTimes","isIndex","inherited","isArr","isArg","isBuff","isType","skipIndexes","baseIsArguments","reIsUint","isLength","typedArrayTags","freeProcess","isPrototype","overArg","dataViewCtorString","mapCtorString","promiseCtorString","setCtorString","weakMapCtorString","ctorString","registerImmediate","channel","messagePrefix","onGlobalMessage","nextHandle","tasksByHandle","currentlyRunningATask","attachTo","nextTick","runIfPresent","importScripts","postMessageIsAsynchronous","oldOnMessage","onmessage","canUsePostMessage","MessageChannel","port1","port2","task","cachedSetTimeout","cachedClearTimeout","defaultSetTimout","defaultClearTimeout","runTimeout","fun","currentQueue","draining","queueIndex","cleanUpNextTick","drainQueue","marker","runClearTimeout","Item","browser","env","argv","versions","addListener","removeListener","removeAllListeners","prependListener","prependOnceListener","cwd","chdir","umask","mouse","numPages","_keySliding","_mouseSliding","_animateOff","_handleIndex","_detectOrientation","_mouseInit","_calculateNewMax","_refresh","_createRange","_createHandles","_setupEvents","_refreshValue","handleCount","existingHandles","_valueMin","_handleEvents","_mouseDestroy","_mouseCapture","normValue","closestHandle","mouseOverHandle","elementSize","outerWidth","outerHeight","elementOffset","_normValueFromMouse","_valueMax","thisDistance","_lastChangedValue","_clickOffset","_slide","_mouseStart","_mouseDrag","_mouseStop","_change","pixelTotal","pixelMouse","percentMouse","valueTotal","valueMouse","_trimAlignValue","_uiHash","uiHash","handleIndex","_hasMultipleValues","newVal","otherVal","newValues","vals","valsLength","_refreshRange","valModStep","alignValue","_precision","_precisionOf","str","lastValPercent","valPercent","valueMin","valueMax","oRange","_set","keydown","curVal","HOME","END","PAGE_UP","PAGE_DOWN","UP","RIGHT","DOWN","LEFT","keyup","mouseHandled","_mouseDown","_mouseMoveDelegate","_mouseUpDelegate","_mouseMoved","_mouseStarted","_mouseUp","_mouseDownEvent","btnIsLeft","elIsCancel","mouseDelayMet","_mouseDelayTimer","_mouseDistanceMet","_mouseDelayMet","_mouseMove","ie","ignoreMissingWhich","BACKSPACE","COMMA","DELETE","ENTER","ESCAPE","PERIOD","SPACE","TAB","api","exported","locals","___CSS_LOADER_API_IMPORT___","___CSS_LOADER_AT_RULE_IMPORT_0___","___CSS_LOADER_AT_RULE_IMPORT_1___","___CSS_LOADER_AT_RULE_IMPORT_2___","___CSS_LOADER_AT_RULE_IMPORT_3___","___CSS_LOADER_AT_RULE_IMPORT_4___","___CSS_LOADER_AT_RULE_IMPORT_5___","___CSS_LOADER_AT_RULE_IMPORT_6___","___CSS_LOADER_AT_RULE_IMPORT_7___","___CSS_LOADER_AT_RULE_IMPORT_8___","OUTPUT_WIDGET_VERSION"],"mappings":"sCACE,IAAIA,EAAmB,GAGvB,SAASC,EAAoBC,GAG5B,GAAGF,EAAiBE,GACnB,OAAOF,EAAiBE,GAAUC,QAGnC,IAAIC,EAASJ,EAAiBE,GAAY,CACzCG,EAAGH,EACHI,GAAG,EACHH,QAAS,IAUV,OANAI,EAAQL,GAAUM,KAAKJ,EAAOD,QAASC,EAAQA,EAAOD,QAASF,GAG/DG,EAAOE,GAAI,EAGJF,EAAOD,QA0Df,OArDAF,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAIV,EAGxBC,EAAoBU,EAAI,SAASR,EAASS,EAAMC,GAC3CZ,EAAoBa,EA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,GACjC,IAAK,IAAIa,EAAG/B,EAAI,EAAGyB,EAAIgF,UAAUvD,OAAQlD,EAAIyB,EAAGzB,IAE5C,IAAK,IAAI8B,KADTC,EAAI0E,UAAUzG,GACOU,OAAOkB,UAAUC,eAAe1B,KAAK4B,EAAGD,KACzDZ,EAAEY,GAAKC,EAAED,IAEjB,OAAOZ,IAEKqJ,MAAM5E,KAAMc,YAGrB6nI,EAAwB,QAC/B/Y,EAA6B,SAAUjrH,GAEvC,SAASirH,IACL,OAAkB,OAAXjrH,GAAmBA,EAAOC,MAAM5E,KAAMc,YAAcd,KAK/D,OAPA+E,EAAU6qH,EAAajrH,GAIvBirH,EAAY3zH,UAAUqY,SAAW,WAC7B,OAAOkF,EAASA,EAAS,GAAI7U,EAAO1I,UAAUqY,SAAS9Z,KAAKwF,OAAQ,CAAE8f,YAAa,cAAeG,WAAY,aAAcL,cAAe,0BAA2BG,aAAc,0BAA2BF,sBAAuB8oH,EAAuB3oH,qBAAsB2oH,KAEhR/Y,EARqB,CAS9B,kBAEEmB,EAA4B,SAAUpsH,GAEtC,SAASosH,IACL,OAAkB,OAAXpsH,GAAmBA,EAAOC,MAAM5E,KAAMc,YAAcd,KAE/D,OAJA+E,EAAUgsH,EAAYpsH,GAIfosH,EALoB,CAM7B","file":"extension.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 48);\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * The namespace for array-specific algorithms.\n */\nvar ArrayExt;\n(function (ArrayExt) {\n    /**\n     * Find the index of the first occurrence of a value in an array.\n     *\n     * @param array - The array-like object to search.\n     *\n     * @param value - The value to locate in the array. Values are\n     *   compared using strict `===` equality.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The index of the first occurrence of the value, or `-1`\n     *   if the value is not found.\n     *\n     * #### Notes\n     * If `stop < start` the search will wrap at the end of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * A `start` or `stop` which is non-integral.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let data = ['one', 'two', 'three', 'four', 'one'];\n     * ArrayExt.firstIndexOf(data, 'red');        // -1\n     * ArrayExt.firstIndexOf(data, 'one');        // 0\n     * ArrayExt.firstIndexOf(data, 'one', 1);     // 4\n     * ArrayExt.firstIndexOf(data, 'two', 2);     // -1\n     * ArrayExt.firstIndexOf(data, 'two', 2, 1);  // 1\n     * ```\n     */\n    function firstIndexOf(array, value, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var n = array.length;\n        if (n === 0) {\n            return -1;\n        }\n        if (start < 0) {\n            start = Math.max(0, start + n);\n        }\n        else {\n            start = Math.min(start, n - 1);\n        }\n        if (stop < 0) {\n            stop = Math.max(0, stop + n);\n        }\n        else {\n            stop = Math.min(stop, n - 1);\n        }\n        var span;\n        if (stop < start) {\n            span = (stop + 1) + (n - start);\n        }\n        else {\n            span = stop - start + 1;\n        }\n        for (var i = 0; i < span; ++i) {\n            var j = (start + i) % n;\n            if (array[j] === value) {\n                return j;\n            }\n        }\n        return -1;\n    }\n    ArrayExt.firstIndexOf = firstIndexOf;\n    /**\n     * Find the index of the last occurrence of a value in an array.\n     *\n     * @param array - The array-like object to search.\n     *\n     * @param value - The value to locate in the array. Values are\n     *   compared using strict `===` equality.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The index of the last occurrence of the value, or `-1`\n     *   if the value is not found.\n     *\n     * #### Notes\n     * If `start < stop` the search will wrap at the front of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * A `start` or `stop` which is non-integral.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let data = ['one', 'two', 'three', 'four', 'one'];\n     * ArrayExt.lastIndexOf(data, 'red');        // -1\n     * ArrayExt.lastIndexOf(data, 'one');        // 4\n     * ArrayExt.lastIndexOf(data, 'one', 1);     // 0\n     * ArrayExt.lastIndexOf(data, 'two', 0);     // -1\n     * ArrayExt.lastIndexOf(data, 'two', 0, 1);  // 1\n     * ```\n     */\n    function lastIndexOf(array, value, start, stop) {\n        if (start === void 0) { start = -1; }\n        if (stop === void 0) { stop = 0; }\n        var n = array.length;\n        if (n === 0) {\n            return -1;\n        }\n        if (start < 0) {\n            start = Math.max(0, start + n);\n        }\n        else {\n            start = Math.min(start, n - 1);\n        }\n        if (stop < 0) {\n            stop = Math.max(0, stop + n);\n        }\n        else {\n            stop = Math.min(stop, n - 1);\n        }\n        var span;\n        if (start < stop) {\n            span = (start + 1) + (n - stop);\n        }\n        else {\n            span = start - stop + 1;\n        }\n        for (var i = 0; i < span; ++i) {\n            var j = (start - i + n) % n;\n            if (array[j] === value) {\n                return j;\n            }\n        }\n        return -1;\n    }\n    ArrayExt.lastIndexOf = lastIndexOf;\n    /**\n     * Find the index of the first value which matches a predicate.\n     *\n     * @param array - The array-like object to search.\n     *\n     * @param fn - The predicate function to apply to the values.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The index of the first matching value, or `-1` if no\n     *   matching value is found.\n     *\n     * #### Notes\n     * If `stop < start` the search will wrap at the end of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * A `start` or `stop` which is non-integral.\n     *\n     * Modifying the length of the array while searching.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * function isEven(value: number): boolean {\n     *   return value % 2 === 0;\n     * }\n     *\n     * let data = [1, 2, 3, 4, 3, 2, 1];\n     * ArrayExt.findFirstIndex(data, isEven);       // 1\n     * ArrayExt.findFirstIndex(data, isEven, 4);    // 5\n     * ArrayExt.findFirstIndex(data, isEven, 6);    // -1\n     * ArrayExt.findFirstIndex(data, isEven, 6, 5); // 1\n     * ```\n     */\n    function findFirstIndex(array, fn, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var n = array.length;\n        if (n === 0) {\n            return -1;\n        }\n        if (start < 0) {\n            start = Math.max(0, start + n);\n        }\n        else {\n            start = Math.min(start, n - 1);\n        }\n        if (stop < 0) {\n            stop = Math.max(0, stop + n);\n        }\n        else {\n            stop = Math.min(stop, n - 1);\n        }\n        var span;\n        if (stop < start) {\n            span = (stop + 1) + (n - start);\n        }\n        else {\n            span = stop - start + 1;\n        }\n        for (var i = 0; i < span; ++i) {\n            var j = (start + i) % n;\n            if (fn(array[j], j)) {\n                return j;\n            }\n        }\n        return -1;\n    }\n    ArrayExt.findFirstIndex = findFirstIndex;\n    /**\n     * Find the index of the last value which matches a predicate.\n     *\n     * @param object - The array-like object to search.\n     *\n     * @param fn - The predicate function to apply to the values.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The index of the last matching value, or `-1` if no\n     *   matching value is found.\n     *\n     * #### Notes\n     * If `start < stop` the search will wrap at the front of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * A `start` or `stop` which is non-integral.\n     *\n     * Modifying the length of the array while searching.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * function isEven(value: number): boolean {\n     *   return value % 2 === 0;\n     * }\n     *\n     * let data = [1, 2, 3, 4, 3, 2, 1];\n     * ArrayExt.findLastIndex(data, isEven);        // 5\n     * ArrayExt.findLastIndex(data, isEven, 4);     // 3\n     * ArrayExt.findLastIndex(data, isEven, 0);     // -1\n     * ArrayExt.findLastIndex(data, isEven, 0, 1);  // 5\n     * ```\n     */\n    function findLastIndex(array, fn, start, stop) {\n        if (start === void 0) { start = -1; }\n        if (stop === void 0) { stop = 0; }\n        var n = array.length;\n        if (n === 0) {\n            return -1;\n        }\n        if (start < 0) {\n            start = Math.max(0, start + n);\n        }\n        else {\n            start = Math.min(start, n - 1);\n        }\n        if (stop < 0) {\n            stop = Math.max(0, stop + n);\n        }\n        else {\n            stop = Math.min(stop, n - 1);\n        }\n        var d;\n        if (start < stop) {\n            d = (start + 1) + (n - stop);\n        }\n        else {\n            d = start - stop + 1;\n        }\n        for (var i = 0; i < d; ++i) {\n            var j = (start - i + n) % n;\n            if (fn(array[j], j)) {\n                return j;\n            }\n        }\n        return -1;\n    }\n    ArrayExt.findLastIndex = findLastIndex;\n    /**\n     * Find the first value which matches a predicate.\n     *\n     * @param array - The array-like object to search.\n     *\n     * @param fn - The predicate function to apply to the values.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The first matching value, or `undefined` if no matching\n     *   value is found.\n     *\n     * #### Notes\n     * If `stop < start` the search will wrap at the end of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * A `start` or `stop` which is non-integral.\n     *\n     * Modifying the length of the array while searching.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * function isEven(value: number): boolean {\n     *   return value % 2 === 0;\n     * }\n     *\n     * let data = [1, 2, 3, 4, 3, 2, 1];\n     * ArrayExt.findFirstValue(data, isEven);       // 2\n     * ArrayExt.findFirstValue(data, isEven, 2);    // 4\n     * ArrayExt.findFirstValue(data, isEven, 6);    // undefined\n     * ArrayExt.findFirstValue(data, isEven, 6, 5); // 2\n     * ```\n     */\n    function findFirstValue(array, fn, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var index = findFirstIndex(array, fn, start, stop);\n        return index !== -1 ? array[index] : undefined;\n    }\n    ArrayExt.findFirstValue = findFirstValue;\n    /**\n     * Find the last value which matches a predicate.\n     *\n     * @param object - The array-like object to search.\n     *\n     * @param fn - The predicate function to apply to the values.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The last matching value, or `undefined` if no matching\n     *   value is found.\n     *\n     * #### Notes\n     * If `start < stop` the search will wrap at the front of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * A `start` or `stop` which is non-integral.\n     *\n     * Modifying the length of the array while searching.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * function isEven(value: number): boolean {\n     *   return value % 2 === 0;\n     * }\n     *\n     * let data = [1, 2, 3, 4, 3, 2, 1];\n     * ArrayExt.findLastValue(data, isEven);        // 2\n     * ArrayExt.findLastValue(data, isEven, 4);     // 4\n     * ArrayExt.findLastValue(data, isEven, 0);     // undefined\n     * ArrayExt.findLastValue(data, isEven, 0, 1);  // 2\n     * ```\n     */\n    function findLastValue(array, fn, start, stop) {\n        if (start === void 0) { start = -1; }\n        if (stop === void 0) { stop = 0; }\n        var index = findLastIndex(array, fn, start, stop);\n        return index !== -1 ? array[index] : undefined;\n    }\n    ArrayExt.findLastValue = findLastValue;\n    /**\n     * Find the index of the first element which compares `>=` to a value.\n     *\n     * @param array - The sorted array-like object to search.\n     *\n     * @param value - The value to locate in the array.\n     *\n     * @param fn - The 3-way comparison function to apply to the values.\n     *   It should return `< 0` if an element is less than a value, `0` if\n     *   an element is equal to a value, or `> 0` if an element is greater\n     *   than a value.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The index of the first element which compares `>=` to the\n     *   value, or `length` if there is no such element. If the computed\n     *   index for `stop` is less than `start`, then the computed index\n     *   for `start` is returned.\n     *\n     * #### Notes\n     * The array must already be sorted in ascending order according to\n     * the comparison function.\n     *\n     * #### Complexity\n     * Logarithmic.\n     *\n     * #### Undefined Behavior\n     * Searching a range which is not sorted in ascending order.\n     *\n     * A `start` or `stop` which is non-integral.\n     *\n     * Modifying the length of the array while searching.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * function numberCmp(a: number, b: number): number {\n     *   return a - b;\n     * }\n     *\n     * let data = [0, 3, 4, 7, 7, 9];\n     * ArrayExt.lowerBound(data, 0, numberCmp);   // 0\n     * ArrayExt.lowerBound(data, 6, numberCmp);   // 3\n     * ArrayExt.lowerBound(data, 7, numberCmp);   // 3\n     * ArrayExt.lowerBound(data, -1, numberCmp);  // 0\n     * ArrayExt.lowerBound(data, 10, numberCmp);  // 6\n     * ```\n     */\n    function lowerBound(array, value, fn, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var n = array.length;\n        if (n === 0) {\n            return 0;\n        }\n        if (start < 0) {\n            start = Math.max(0, start + n);\n        }\n        else {\n            start = Math.min(start, n - 1);\n        }\n        if (stop < 0) {\n            stop = Math.max(0, stop + n);\n        }\n        else {\n            stop = Math.min(stop, n - 1);\n        }\n        var begin = start;\n        var span = stop - start + 1;\n        while (span > 0) {\n            var half = span >> 1;\n            var middle = begin + half;\n            if (fn(array[middle], value) < 0) {\n                begin = middle + 1;\n                span -= half + 1;\n            }\n            else {\n                span = half;\n            }\n        }\n        return begin;\n    }\n    ArrayExt.lowerBound = lowerBound;\n    /**\n     * Find the index of the first element which compares `>` than a value.\n     *\n     * @param array - The sorted array-like object to search.\n     *\n     * @param value - The value to locate in the array.\n     *\n     * @param fn - The 3-way comparison function to apply to the values.\n     *   It should return `< 0` if an element is less than a value, `0` if\n     *   an element is equal to a value, or `> 0` if an element is greater\n     *   than a value.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The index of the first element which compares `>` than the\n     *   value, or `length` if there is no such element. If the computed\n     *   index for `stop` is less than `start`, then the computed index\n     *   for `start` is returned.\n     *\n     * #### Notes\n     * The array must already be sorted in ascending order according to\n     * the comparison function.\n     *\n     * #### Complexity\n     * Logarithmic.\n     *\n     * #### Undefined Behavior\n     * Searching a range which is not sorted in ascending order.\n     *\n     * A `start` or `stop` which is non-integral.\n     *\n     * Modifying the length of the array while searching.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * function numberCmp(a: number, b: number): number {\n     *   return a - b;\n     * }\n     *\n     * let data = [0, 3, 4, 7, 7, 9];\n     * ArrayExt.upperBound(data, 0, numberCmp);   // 1\n     * ArrayExt.upperBound(data, 6, numberCmp);   // 3\n     * ArrayExt.upperBound(data, 7, numberCmp);   // 5\n     * ArrayExt.upperBound(data, -1, numberCmp);  // 0\n     * ArrayExt.upperBound(data, 10, numberCmp);  // 6\n     * ```\n     */\n    function upperBound(array, value, fn, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var n = array.length;\n        if (n === 0) {\n            return 0;\n        }\n        if (start < 0) {\n            start = Math.max(0, start + n);\n        }\n        else {\n            start = Math.min(start, n - 1);\n        }\n        if (stop < 0) {\n            stop = Math.max(0, stop + n);\n        }\n        else {\n            stop = Math.min(stop, n - 1);\n        }\n        var begin = start;\n        var span = stop - start + 1;\n        while (span > 0) {\n            var half = span >> 1;\n            var middle = begin + half;\n            if (fn(array[middle], value) > 0) {\n                span = half;\n            }\n            else {\n                begin = middle + 1;\n                span -= half + 1;\n            }\n        }\n        return begin;\n    }\n    ArrayExt.upperBound = upperBound;\n    /**\n     * Test whether two arrays are shallowly equal.\n     *\n     * @param a - The first array-like object to compare.\n     *\n     * @param b - The second array-like object to compare.\n     *\n     * @param fn - The comparison function to apply to the elements. It\n     *   should return `true` if the elements are \"equal\". The default\n     *   compares elements using strict `===` equality.\n     *\n     * @returns Whether the two arrays are shallowly equal.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * Modifying the length of the arrays while comparing.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let d1 = [0, 3, 4, 7, 7, 9];\n     * let d2 = [0, 3, 4, 7, 7, 9];\n     * let d3 = [42];\n     * ArrayExt.shallowEqual(d1, d2);  // true\n     * ArrayExt.shallowEqual(d2, d3);  // false\n     * ```\n     */\n    function shallowEqual(a, b, fn) {\n        // Check for object identity first.\n        if (a === b) {\n            return true;\n        }\n        // Bail early if the lengths are different.\n        if (a.length !== b.length) {\n            return false;\n        }\n        // Compare each element for equality.\n        for (var i = 0, n = a.length; i < n; ++i) {\n            if (fn ? !fn(a[i], b[i]) : a[i] !== b[i]) {\n                return false;\n            }\n        }\n        // The array are shallowly equal.\n        return true;\n    }\n    ArrayExt.shallowEqual = shallowEqual;\n    /**\n     * Create a slice of an array subject to an optional step.\n     *\n     * @param array - The array-like object of interest.\n     *\n     * @param options - The options for configuring the slice.\n     *\n     * @returns A new array with the specified values.\n     *\n     * @throws An exception if the slice `step` is `0`.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * A `start`, `stop`, or `step` which is non-integral.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let data = [0, 3, 4, 7, 7, 9];\n     * ArrayExt.slice(data);                         // [0, 3, 4, 7, 7, 9]\n     * ArrayExt.slice(data, { start: 2 });           // [4, 7, 7, 9]\n     * ArrayExt.slice(data, { start: 0, stop: 4 });  // [0, 3, 4, 7]\n     * ArrayExt.slice(data, { step: 2 });            // [0, 4, 7]\n     * ArrayExt.slice(data, { step: -1 });           // [9, 7, 7, 4, 3, 0]\n     * ```\n     */\n    function slice(array, options) {\n        if (options === void 0) { options = {}; }\n        // Extract the options.\n        var start = options.start, stop = options.stop, step = options.step;\n        // Set up the `step` value.\n        if (step === undefined) {\n            step = 1;\n        }\n        // Validate the step size.\n        if (step === 0) {\n            throw new Error('Slice `step` cannot be zero.');\n        }\n        // Look up the length of the array.\n        var n = array.length;\n        // Set up the `start` value.\n        if (start === undefined) {\n            start = step < 0 ? n - 1 : 0;\n        }\n        else if (start < 0) {\n            start = Math.max(start + n, step < 0 ? -1 : 0);\n        }\n        else if (start >= n) {\n            start = step < 0 ? n - 1 : n;\n        }\n        // Set up the `stop` value.\n        if (stop === undefined) {\n            stop = step < 0 ? -1 : n;\n        }\n        else if (stop < 0) {\n            stop = Math.max(stop + n, step < 0 ? -1 : 0);\n        }\n        else if (stop >= n) {\n            stop = step < 0 ? n - 1 : n;\n        }\n        // Compute the slice length.\n        var length;\n        if ((step < 0 && stop >= start) || (step > 0 && start >= stop)) {\n            length = 0;\n        }\n        else if (step < 0) {\n            length = Math.floor((stop - start + 1) / step + 1);\n        }\n        else {\n            length = Math.floor((stop - start - 1) / step + 1);\n        }\n        // Compute the sliced result.\n        var result = [];\n        for (var i = 0; i < length; ++i) {\n            result[i] = array[start + i * step];\n        }\n        // Return the result.\n        return result;\n    }\n    ArrayExt.slice = slice;\n    /**\n     * Move an element in an array from one index to another.\n     *\n     * @param array - The mutable array-like object of interest.\n     *\n     * @param fromIndex - The index of the element to move. Negative\n     *   values are taken as an offset from the end of the array.\n     *\n     * @param toIndex - The target index of the element. Negative\n     *   values are taken as an offset from the end of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * A `fromIndex` or `toIndex` which is non-integral.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from from '@lumino/algorithm';\n     *\n     * let data = [0, 1, 2, 3, 4];\n     * ArrayExt.move(data, 1, 2);  // [0, 2, 1, 3, 4]\n     * ArrayExt.move(data, 4, 2);  // [0, 2, 4, 1, 3]\n     * ```\n     */\n    function move(array, fromIndex, toIndex) {\n        var n = array.length;\n        if (n <= 1) {\n            return;\n        }\n        if (fromIndex < 0) {\n            fromIndex = Math.max(0, fromIndex + n);\n        }\n        else {\n            fromIndex = Math.min(fromIndex, n - 1);\n        }\n        if (toIndex < 0) {\n            toIndex = Math.max(0, toIndex + n);\n        }\n        else {\n            toIndex = Math.min(toIndex, n - 1);\n        }\n        if (fromIndex === toIndex) {\n            return;\n        }\n        var value = array[fromIndex];\n        var d = fromIndex < toIndex ? 1 : -1;\n        for (var i = fromIndex; i !== toIndex; i += d) {\n            array[i] = array[i + d];\n        }\n        array[toIndex] = value;\n    }\n    ArrayExt.move = move;\n    /**\n     * Reverse an array in-place.\n     *\n     * @param array - The mutable array-like object of interest.\n     *\n     * @param start - The index of the first element in the range to be\n     *   reversed, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   reversed, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * A `start` or  `stop` index which is non-integral.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let data = [0, 1, 2, 3, 4];\n     * ArrayExt.reverse(data, 1, 3);  // [0, 3, 2, 1, 4]\n     * ArrayExt.reverse(data, 3);     // [0, 3, 2, 4, 1]\n     * ArrayExt.reverse(data);        // [1, 4, 2, 3, 0]\n     * ```\n     */\n    function reverse(array, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var n = array.length;\n        if (n <= 1) {\n            return;\n        }\n        if (start < 0) {\n            start = Math.max(0, start + n);\n        }\n        else {\n            start = Math.min(start, n - 1);\n        }\n        if (stop < 0) {\n            stop = Math.max(0, stop + n);\n        }\n        else {\n            stop = Math.min(stop, n - 1);\n        }\n        while (start < stop) {\n            var a = array[start];\n            var b = array[stop];\n            array[start++] = b;\n            array[stop--] = a;\n        }\n    }\n    ArrayExt.reverse = reverse;\n    /**\n     * Rotate the elements of an array in-place.\n     *\n     * @param array - The mutable array-like object of interest.\n     *\n     * @param delta - The amount of rotation to apply to the elements. A\n     *   positive value will rotate the elements to the left. A negative\n     *   value will rotate the elements to the right.\n     *\n     * @param start - The index of the first element in the range to be\n     *   rotated, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   rotated, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * A `delta`, `start`, or `stop` which is non-integral.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let data = [0, 1, 2, 3, 4];\n     * ArrayExt.rotate(data, 2);        // [2, 3, 4, 0, 1]\n     * ArrayExt.rotate(data, -2);       // [0, 1, 2, 3, 4]\n     * ArrayExt.rotate(data, 10);       // [0, 1, 2, 3, 4]\n     * ArrayExt.rotate(data, 9);        // [4, 0, 1, 2, 3]\n     * ArrayExt.rotate(data, 2, 1, 3);  // [4, 2, 0, 1, 3]\n     * ```\n     */\n    function rotate(array, delta, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var n = array.length;\n        if (n <= 1) {\n            return;\n        }\n        if (start < 0) {\n            start = Math.max(0, start + n);\n        }\n        else {\n            start = Math.min(start, n - 1);\n        }\n        if (stop < 0) {\n            stop = Math.max(0, stop + n);\n        }\n        else {\n            stop = Math.min(stop, n - 1);\n        }\n        if (start >= stop) {\n            return;\n        }\n        var length = stop - start + 1;\n        if (delta > 0) {\n            delta = delta % length;\n        }\n        else if (delta < 0) {\n            delta = ((delta % length) + length) % length;\n        }\n        if (delta === 0) {\n            return;\n        }\n        var pivot = start + delta;\n        reverse(array, start, pivot - 1);\n        reverse(array, pivot, stop);\n        reverse(array, start, stop);\n    }\n    ArrayExt.rotate = rotate;\n    /**\n     * Fill an array with a static value.\n     *\n     * @param array - The mutable array-like object to fill.\n     *\n     * @param value - The static value to use to fill the array.\n     *\n     * @param start - The index of the first element in the range to be\n     *   filled, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   filled, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * #### Notes\n     * If `stop < start` the fill will wrap at the end of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * A `start` or `stop` which is non-integral.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let data = ['one', 'two', 'three', 'four'];\n     * ArrayExt.fill(data, 'r');        // ['r', 'r', 'r', 'r']\n     * ArrayExt.fill(data, 'g', 1);     // ['r', 'g', 'g', 'g']\n     * ArrayExt.fill(data, 'b', 2, 3);  // ['r', 'g', 'b', 'b']\n     * ArrayExt.fill(data, 'z', 3, 1);  // ['z', 'z', 'b', 'z']\n     * ```\n     */\n    function fill(array, value, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var n = array.length;\n        if (n === 0) {\n            return;\n        }\n        if (start < 0) {\n            start = Math.max(0, start + n);\n        }\n        else {\n            start = Math.min(start, n - 1);\n        }\n        if (stop < 0) {\n            stop = Math.max(0, stop + n);\n        }\n        else {\n            stop = Math.min(stop, n - 1);\n        }\n        var span;\n        if (stop < start) {\n            span = (stop + 1) + (n - start);\n        }\n        else {\n            span = stop - start + 1;\n        }\n        for (var i = 0; i < span; ++i) {\n            array[(start + i) % n] = value;\n        }\n    }\n    ArrayExt.fill = fill;\n    /**\n     * Insert a value into an array at a specific index.\n     *\n     * @param array - The array of interest.\n     *\n     * @param index - The index at which to insert the value. Negative\n     *   values are taken as an offset from the end of the array.\n     *\n     * @param value - The value to set at the specified index.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * An `index` which is non-integral.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let data = [0, 1, 2];\n     * ArrayExt.insert(data, 0, -1);  // [-1, 0, 1, 2]\n     * ArrayExt.insert(data, 2, 12);  // [-1, 0, 12, 1, 2]\n     * ArrayExt.insert(data, -1, 7);  // [-1, 0, 12, 1, 7, 2]\n     * ArrayExt.insert(data, 6, 19);  // [-1, 0, 12, 1, 7, 2, 19]\n     * ```\n     */\n    function insert(array, index, value) {\n        var n = array.length;\n        if (index < 0) {\n            index = Math.max(0, index + n);\n        }\n        else {\n            index = Math.min(index, n);\n        }\n        for (var i = n; i > index; --i) {\n            array[i] = array[i - 1];\n        }\n        array[index] = value;\n    }\n    ArrayExt.insert = insert;\n    /**\n     * Remove and return a value at a specific index in an array.\n     *\n     * @param array - The array of interest.\n     *\n     * @param index - The index of the value to remove. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The value at the specified index, or `undefined` if the\n     *   index is out of range.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Undefined Behavior\n     * An `index` which is non-integral.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let data = [0, 12, 23, 39, 14, 12, 75];\n     * ArrayExt.removeAt(data, 2);   // 23\n     * ArrayExt.removeAt(data, -2);  // 12\n     * ArrayExt.removeAt(data, 10);  // undefined;\n     * ```\n     */\n    function removeAt(array, index) {\n        var n = array.length;\n        if (index < 0) {\n            index += n;\n        }\n        if (index < 0 || index >= n) {\n            return undefined;\n        }\n        var value = array[index];\n        for (var i = index + 1; i < n; ++i) {\n            array[i - 1] = array[i];\n        }\n        array.length = n - 1;\n        return value;\n    }\n    ArrayExt.removeAt = removeAt;\n    /**\n     * Remove the first occurrence of a value from an array.\n     *\n     * @param array - The array of interest.\n     *\n     * @param value - The value to remove from the array. Values are\n     *   compared using strict `===` equality.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The index of the removed value, or `-1` if the value\n     *   is not contained in the array.\n     *\n     * #### Notes\n     * If `stop < start` the search will wrap at the end of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let data = [0, 12, 23, 39, 14, 12, 75];\n     * ArrayExt.removeFirstOf(data, 12);        // 1\n     * ArrayExt.removeFirstOf(data, 17);        // -1\n     * ArrayExt.removeFirstOf(data, 39, 3);     // -1\n     * ArrayExt.removeFirstOf(data, 39, 3, 2);  // 2\n     * ```\n     */\n    function removeFirstOf(array, value, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var index = firstIndexOf(array, value, start, stop);\n        if (index !== -1) {\n            removeAt(array, index);\n        }\n        return index;\n    }\n    ArrayExt.removeFirstOf = removeFirstOf;\n    /**\n     * Remove the last occurrence of a value from an array.\n     *\n     * @param array - The array of interest.\n     *\n     * @param value - The value to remove from the array. Values are\n     *   compared using strict `===` equality.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The index of the removed value, or `-1` if the value\n     *   is not contained in the array.\n     *\n     * #### Notes\n     * If `start < stop` the search will wrap at the end of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let data = [0, 12, 23, 39, 14, 12, 75];\n     * ArrayExt.removeLastOf(data, 12);        // 5\n     * ArrayExt.removeLastOf(data, 17);        // -1\n     * ArrayExt.removeLastOf(data, 39, 2);     // -1\n     * ArrayExt.removeLastOf(data, 39, 2, 3);  // 3\n     * ```\n     */\n    function removeLastOf(array, value, start, stop) {\n        if (start === void 0) { start = -1; }\n        if (stop === void 0) { stop = 0; }\n        var index = lastIndexOf(array, value, start, stop);\n        if (index !== -1) {\n            removeAt(array, index);\n        }\n        return index;\n    }\n    ArrayExt.removeLastOf = removeLastOf;\n    /**\n     * Remove all occurrences of a value from an array.\n     *\n     * @param array - The array of interest.\n     *\n     * @param value - The value to remove from the array. Values are\n     *   compared using strict `===` equality.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The number of elements removed from the array.\n     *\n     * #### Notes\n     * If `stop < start` the search will conceptually wrap at the end of\n     * the array, however the array will be traversed front-to-back.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * let data = [14, 12, 23, 39, 14, 12, 19, 14];\n     * ArrayExt.removeAllOf(data, 12);        // 2\n     * ArrayExt.removeAllOf(data, 17);        // 0\n     * ArrayExt.removeAllOf(data, 14, 1, 4);  // 1\n     * ```\n     */\n    function removeAllOf(array, value, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var n = array.length;\n        if (n === 0) {\n            return 0;\n        }\n        if (start < 0) {\n            start = Math.max(0, start + n);\n        }\n        else {\n            start = Math.min(start, n - 1);\n        }\n        if (stop < 0) {\n            stop = Math.max(0, stop + n);\n        }\n        else {\n            stop = Math.min(stop, n - 1);\n        }\n        var count = 0;\n        for (var i = 0; i < n; ++i) {\n            if (start <= stop && (i >= start && i <= stop) && array[i] === value) {\n                count++;\n            }\n            else if (stop < start && (i <= stop || i >= start) && array[i] === value) {\n                count++;\n            }\n            else if (count > 0) {\n                array[i - count] = array[i];\n            }\n        }\n        if (count > 0) {\n            array.length = n - count;\n        }\n        return count;\n    }\n    ArrayExt.removeAllOf = removeAllOf;\n    /**\n     * Remove the first occurrence of a value which matches a predicate.\n     *\n     * @param array - The array of interest.\n     *\n     * @param fn - The predicate function to apply to the values.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The removed `{ index, value }`, which will be `-1` and\n     *   `undefined` if the value is not contained in the array.\n     *\n     * #### Notes\n     * If `stop < start` the search will wrap at the end of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * function isEven(value: number): boolean {\n     *   return value % 2 === 0;\n     * }\n     *\n     * let data = [0, 12, 23, 39, 14, 12, 75];\n     * ArrayExt.removeFirstWhere(data, isEven);     // { index: 0, value: 0 }\n     * ArrayExt.removeFirstWhere(data, isEven, 2);  // { index: 3, value: 14 }\n     * ArrayExt.removeFirstWhere(data, isEven, 4);  // { index: -1, value: undefined }\n     * ```\n     */\n    function removeFirstWhere(array, fn, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var value;\n        var index = findFirstIndex(array, fn, start, stop);\n        if (index !== -1) {\n            value = removeAt(array, index);\n        }\n        return { index: index, value: value };\n    }\n    ArrayExt.removeFirstWhere = removeFirstWhere;\n    /**\n     * Remove the last occurrence of a value which matches a predicate.\n     *\n     * @param array - The array of interest.\n     *\n     * @param fn - The predicate function to apply to the values.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The removed `{ index, value }`, which will be `-1` and\n     *   `undefined` if the value is not contained in the array.\n     *\n     * #### Notes\n     * If `start < stop` the search will wrap at the end of the array.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * function isEven(value: number): boolean {\n     *   return value % 2 === 0;\n     * }\n     *\n     * let data = [0, 12, 23, 39, 14, 12, 75];\n     * ArrayExt.removeLastWhere(data, isEven);        // { index: 5, value: 12 }\n     * ArrayExt.removeLastWhere(data, isEven, 2);     // { index: 1, value: 12 }\n     * ArrayExt.removeLastWhere(data, isEven, 2, 1);  // { index: -1, value: undefined }\n     * ```\n     */\n    function removeLastWhere(array, fn, start, stop) {\n        if (start === void 0) { start = -1; }\n        if (stop === void 0) { stop = 0; }\n        var value;\n        var index = findLastIndex(array, fn, start, stop);\n        if (index !== -1) {\n            value = removeAt(array, index);\n        }\n        return { index: index, value: value };\n    }\n    ArrayExt.removeLastWhere = removeLastWhere;\n    /**\n     * Remove all occurrences of values which match a predicate.\n     *\n     * @param array - The array of interest.\n     *\n     * @param fn - The predicate function to apply to the values.\n     *\n     * @param start - The index of the first element in the range to be\n     *   searched, inclusive. The default value is `0`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @param stop - The index of the last element in the range to be\n     *   searched, inclusive. The default value is `-1`. Negative values\n     *   are taken as an offset from the end of the array.\n     *\n     * @returns The number of elements removed from the array.\n     *\n     * #### Notes\n     * If `stop < start` the search will conceptually wrap at the end of\n     * the array, however the array will be traversed front-to-back.\n     *\n     * #### Complexity\n     * Linear.\n     *\n     * #### Example\n     * ```typescript\n     * import { ArrayExt } from '@lumino/algorithm';\n     *\n     * function isEven(value: number): boolean {\n     *   return value % 2 === 0;\n     * }\n     *\n     * function isNegative(value: number): boolean {\n     *   return value < 0;\n     * }\n     *\n     * let data = [0, 12, -13, -9, 23, 39, 14, -15, 12, 75];\n     * ArrayExt.removeAllWhere(data, isEven);            // 4\n     * ArrayExt.removeAllWhere(data, isNegative, 0, 3);  // 2\n     * ```\n     */\n    function removeAllWhere(array, fn, start, stop) {\n        if (start === void 0) { start = 0; }\n        if (stop === void 0) { stop = -1; }\n        var n = array.length;\n        if (n === 0) {\n            return 0;\n        }\n        if (start < 0) {\n            start = Math.max(0, start + n);\n        }\n        else {\n            start = Math.min(start, n - 1);\n        }\n        if (stop < 0) {\n            stop = Math.max(0, stop + n);\n        }\n        else {\n            stop = Math.min(stop, n - 1);\n        }\n        var count = 0;\n        for (var i = 0; i < n; ++i) {\n            if (start <= stop && (i >= start && i <= stop) && fn(array[i], i)) {\n                count++;\n            }\n            else if (stop < start && (i <= stop || i >= start) && fn(array[i], i)) {\n                count++;\n            }\n            else if (count > 0) {\n                array[i - count] = array[i];\n            }\n        }\n        if (count > 0) {\n            array.length = n - count;\n        }\n        return count;\n    }\n    ArrayExt.removeAllWhere = removeAllWhere;\n})(ArrayExt || (ArrayExt = {}));\n\n// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * Create an iterator for an iterable object.\n *\n * @param object - The iterable or array-like object of interest.\n *\n * @returns A new iterator for the given object.\n *\n * #### Notes\n * This function allows iteration algorithms to operate on user-defined\n * iterable types and builtin array-like objects in a uniform fashion.\n */\nfunction iter(object) {\n    var it;\n    if (typeof object.iter === 'function') {\n        it = object.iter();\n    }\n    else {\n        it = new ArrayIterator(object);\n    }\n    return it;\n}\n/**\n * Create an iterator for the keys in an object.\n *\n * @param object - The object of interest.\n *\n * @returns A new iterator for the keys in the given object.\n *\n * #### Complexity\n * Linear.\n *\n * #### Example\n * ```typescript\n * import { each, keys } from '@lumino/algorithm';\n *\n * let data = { one: 1, two: 2, three: 3 };\n *\n * each(keys(data), key => { console.log(key); }); // 'one', 'two', 'three'\n * ```\n */\nfunction iterKeys(object) {\n    return new KeyIterator(object);\n}\n/**\n * Create an iterator for the values in an object.\n *\n * @param object - The object of interest.\n *\n * @returns A new iterator for the values in the given object.\n *\n * #### Complexity\n * Linear.\n *\n * #### Example\n * ```typescript\n * import { each, values } from '@lumino/algorithm';\n *\n * let data = { one: 1, two: 2, three: 3 };\n *\n * each(values(data), value => { console.log(value); }); // 1, 2, 3\n * ```\n */\nfunction iterValues(object) {\n    return new ValueIterator(object);\n}\n/**\n * Create an iterator for the items in an object.\n *\n * @param object - The object of interest.\n *\n * @returns A new iterator for the items in the given object.\n *\n * #### Complexity\n * Linear.\n *\n * #### Example\n * ```typescript\n * import { each, items } from '@lumino/algorithm';\n *\n * let data = { one: 1, two: 2, three: 3 };\n *\n * each(items(data), value => { console.log(value); }); // ['one', 1], ['two', 2], ['three', 3]\n * ```\n */\nfunction iterItems(object) {\n    return new ItemIterator(object);\n}\n/**\n * Create an iterator for an iterator-like function.\n *\n * @param fn - A function which behaves like an iterator `next` method.\n *\n * @returns A new iterator for the given function.\n *\n * #### Notes\n * The returned iterator **cannot** be cloned.\n *\n * #### Example\n * ```typescript\n * import { each, iterFn } from '@lumino/algorithm';\n *\n * let it = iterFn((() => {\n *   let i = 0;\n *   return () => i > 3 ? undefined : i++;\n * })());\n *\n * each(it, v => { console.log(v); }); // 0, 1, 2, 3\n * ```\n */\nfunction iterFn(fn) {\n    return new FnIterator(fn);\n}\n/**\n * Invoke a function for each value in an iterable.\n *\n * @param object - The iterable or array-like object of interest.\n *\n * @param fn - The callback function to invoke for each value.\n *\n * #### Notes\n * Iteration can be terminated early by returning `false` from the\n * callback function.\n *\n * #### Complexity\n * Linear.\n *\n * #### Example\n * ```typescript\n * import { each } from '@lumino/algorithm';\n *\n * let data = [5, 7, 0, -2, 9];\n *\n * each(data, value => { console.log(value); });\n * ```\n */\nfunction each(object, fn) {\n    var index = 0;\n    var it = iter(object);\n    var value;\n    while ((value = it.next()) !== undefined) {\n        if (fn(value, index++) === false) {\n            return;\n        }\n    }\n}\n/**\n * Test whether all values in an iterable satisfy a predicate.\n *\n * @param object - The iterable or array-like object of interest.\n *\n * @param fn - The predicate function to invoke for each value.\n *\n * @returns `true` if all values pass the test, `false` otherwise.\n *\n * #### Notes\n * Iteration terminates on the first `false` predicate result.\n *\n * #### Complexity\n * Linear.\n *\n * #### Example\n * ```typescript\n * import { every } from '@lumino/algorithm';\n *\n * let data = [5, 7, 1];\n *\n * every(data, value => value % 2 === 0);  // false\n * every(data, value => value % 2 === 1);  // true\n * ```\n */\nfunction every(object, fn) {\n    var index = 0;\n    var it = iter(object);\n    var value;\n    while ((value = it.next()) !== undefined) {\n        if (!fn(value, index++)) {\n            return false;\n        }\n    }\n    return true;\n}\n/**\n * Test whether any value in an iterable satisfies a predicate.\n *\n * @param object - The iterable or array-like object of interest.\n *\n * @param fn - The predicate function to invoke for each value.\n *\n * @returns `true` if any value passes the test, `false` otherwise.\n *\n * #### Notes\n * Iteration terminates on the first `true` predicate result.\n *\n * #### Complexity\n * Linear.\n *\n * #### Example\n * ```typescript\n * import { some } from '@lumino/algorithm';\n *\n * let data = [5, 7, 1];\n *\n * some(data, value => value === 7);  // true\n * some(data, value => value === 3);  // false\n * ```\n */\nfunction some(object, fn) {\n    var index = 0;\n    var it = iter(object);\n    var value;\n    while ((value = it.next()) !== undefined) {\n        if (fn(value, index++)) {\n            return true;\n        }\n    }\n    return false;\n}\n/**\n * Create an array from an iterable of values.\n *\n * @param object - The iterable or array-like object of interest.\n *\n * @returns A new array of values from the given object.\n *\n * #### Example\n * ```typescript\n * import { iter, toArray } from '@lumino/algorithm';\n *\n * let data = [1, 2, 3, 4, 5, 6];\n *\n * let stream = iter(data);\n *\n * toArray(stream);  // [1, 2, 3, 4, 5, 6];\n * ```\n */\nfunction toArray(object) {\n    var index = 0;\n    var result = [];\n    var it = iter(object);\n    var value;\n    while ((value = it.next()) !== undefined) {\n        result[index++] = value;\n    }\n    return result;\n}\n/**\n * Create an object from an iterable of key/value pairs.\n *\n * @param object - The iterable or array-like object of interest.\n *\n * @returns A new object mapping keys to values.\n *\n * #### Example\n * ```typescript\n * import { toObject } from '@lumino/algorithm';\n *\n * let data = [['one', 1], ['two', 2], ['three', 3]];\n *\n * toObject(data);  // { one: 1, two: 2, three: 3 }\n * ```\n */\nfunction toObject(object) {\n    var it = iter(object);\n    var pair;\n    var result = {};\n    while ((pair = it.next()) !== undefined) {\n        result[pair[0]] = pair[1];\n    }\n    return result;\n}\n/**\n * An iterator for an array-like object.\n *\n * #### Notes\n * This iterator can be used for any builtin JS array-like object.\n */\nvar ArrayIterator = /** @class */ (function () {\n    /**\n     * Construct a new array iterator.\n     *\n     * @param source - The array-like object of interest.\n     */\n    function ArrayIterator(source) {\n        this._index = 0;\n        this._source = source;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    ArrayIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    ArrayIterator.prototype.clone = function () {\n        var result = new ArrayIterator(this._source);\n        result._index = this._index;\n        return result;\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    ArrayIterator.prototype.next = function () {\n        if (this._index >= this._source.length) {\n            return undefined;\n        }\n        return this._source[this._index++];\n    };\n    return ArrayIterator;\n}());\n/**\n * An iterator for the keys in an object.\n *\n * #### Notes\n * This iterator can be used for any JS object.\n */\nvar KeyIterator = /** @class */ (function () {\n    /**\n     * Construct a new key iterator.\n     *\n     * @param source - The object of interest.\n     *\n     * @param keys - The keys to iterate, if known.\n     */\n    function KeyIterator(source, keys) {\n        if (keys === void 0) { keys = Object.keys(source); }\n        this._index = 0;\n        this._source = source;\n        this._keys = keys;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    KeyIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    KeyIterator.prototype.clone = function () {\n        var result = new KeyIterator(this._source, this._keys);\n        result._index = this._index;\n        return result;\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    KeyIterator.prototype.next = function () {\n        if (this._index >= this._keys.length) {\n            return undefined;\n        }\n        var key = this._keys[this._index++];\n        if (key in this._source) {\n            return key;\n        }\n        return this.next();\n    };\n    return KeyIterator;\n}());\n/**\n * An iterator for the values in an object.\n *\n * #### Notes\n * This iterator can be used for any JS object.\n */\nvar ValueIterator = /** @class */ (function () {\n    /**\n     * Construct a new value iterator.\n     *\n     * @param source - The object of interest.\n     *\n     * @param keys - The keys to iterate, if known.\n     */\n    function ValueIterator(source, keys) {\n        if (keys === void 0) { keys = Object.keys(source); }\n        this._index = 0;\n        this._source = source;\n        this._keys = keys;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    ValueIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    ValueIterator.prototype.clone = function () {\n        var result = new ValueIterator(this._source, this._keys);\n        result._index = this._index;\n        return result;\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    ValueIterator.prototype.next = function () {\n        if (this._index >= this._keys.length) {\n            return undefined;\n        }\n        var key = this._keys[this._index++];\n        if (key in this._source) {\n            return this._source[key];\n        }\n        return this.next();\n    };\n    return ValueIterator;\n}());\n/**\n * An iterator for the items in an object.\n *\n * #### Notes\n * This iterator can be used for any JS object.\n */\nvar ItemIterator = /** @class */ (function () {\n    /**\n     * Construct a new item iterator.\n     *\n     * @param source - The object of interest.\n     *\n     * @param keys - The keys to iterate, if known.\n     */\n    function ItemIterator(source, keys) {\n        if (keys === void 0) { keys = Object.keys(source); }\n        this._index = 0;\n        this._source = source;\n        this._keys = keys;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    ItemIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    ItemIterator.prototype.clone = function () {\n        var result = new ItemIterator(this._source, this._keys);\n        result._index = this._index;\n        return result;\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    ItemIterator.prototype.next = function () {\n        if (this._index >= this._keys.length) {\n            return undefined;\n        }\n        var key = this._keys[this._index++];\n        if (key in this._source) {\n            return [key, this._source[key]];\n        }\n        return this.next();\n    };\n    return ItemIterator;\n}());\n/**\n * An iterator for an iterator-like function.\n */\nvar FnIterator = /** @class */ (function () {\n    /**\n     * Construct a new function iterator.\n     *\n     * @param fn - The iterator-like function of interest.\n     */\n    function FnIterator(fn) {\n        this._fn = fn;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    FnIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    FnIterator.prototype.clone = function () {\n        throw new Error('An `FnIterator` cannot be cloned.');\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    FnIterator.prototype.next = function () {\n        return this._fn.call(undefined);\n    };\n    return FnIterator;\n}());\n\n// Copyright (c) Jupyter Development Team.\n/**\n * Chain together several iterables.\n *\n * @param objects - The iterable or array-like objects of interest.\n *\n * @returns An iterator which yields the values of the iterables\n *   in the order in which they are supplied.\n *\n * #### Example\n * ```typescript\n * import { chain, toArray } from '@lumino/algorithm';\n *\n * let data1 = [1, 2, 3];\n * let data2 = [4, 5, 6];\n *\n * let stream = chain(data1, data2);\n *\n * toArray(stream);  // [1, 2, 3, 4, 5, 6]\n * ```\n */\nfunction chain() {\n    var objects = [];\n    for (var _i = 0; _i < arguments.length; _i++) {\n        objects[_i] = arguments[_i];\n    }\n    return new ChainIterator(iter(objects.map(iter)));\n}\n/**\n * An iterator which chains together several iterators.\n */\nvar ChainIterator = /** @class */ (function () {\n    /**\n     * Construct a new chain iterator.\n     *\n     * @param source - The iterator of iterators of interest.\n     */\n    function ChainIterator(source) {\n        this._cloned = false;\n        this._source = source;\n        this._active = undefined;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    ChainIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    ChainIterator.prototype.clone = function () {\n        var result = new ChainIterator(this._source.clone());\n        result._active = this._active && this._active.clone();\n        result._cloned = true;\n        this._cloned = true;\n        return result;\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    ChainIterator.prototype.next = function () {\n        if (this._active === undefined) {\n            var active = this._source.next();\n            if (active === undefined) {\n                return undefined;\n            }\n            this._active = this._cloned ? active.clone() : active;\n        }\n        var value = this._active.next();\n        if (value !== undefined) {\n            return value;\n        }\n        this._active = undefined;\n        return this.next();\n    };\n    return ChainIterator;\n}());\n\n/**\n * Create an empty iterator.\n *\n * @returns A new iterator which yields nothing.\n *\n * #### Example\n * ```typescript\n * import { empty, toArray } from '@lumino/algorithm';\n *\n * let stream = empty<number>();\n *\n * toArray(stream);  // []\n * ```\n */\nfunction empty() {\n    return new EmptyIterator();\n}\n/**\n * An iterator which is always empty.\n */\nvar EmptyIterator = /** @class */ (function () {\n    /**\n     * Construct a new empty iterator.\n     */\n    function EmptyIterator() {\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    EmptyIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    EmptyIterator.prototype.clone = function () {\n        return new EmptyIterator();\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    EmptyIterator.prototype.next = function () {\n        return undefined;\n    };\n    return EmptyIterator;\n}());\n\n// Copyright (c) Jupyter Development Team.\n/**\n * Enumerate an iterable object.\n *\n * @param object - The iterable or array-like object of interest.\n *\n * @param start - The starting enum value. The default is `0`.\n *\n * @returns An iterator which yields the enumerated values.\n *\n * #### Example\n * ```typescript\n * import { enumerate, toArray } from '@lumino/algorithm';\n *\n * let data = ['foo', 'bar', 'baz'];\n *\n * let stream = enumerate(data, 1);\n *\n * toArray(stream);  // [[1, 'foo'], [2, 'bar'], [3, 'baz']]\n * ```\n */\nfunction enumerate(object, start) {\n    if (start === void 0) { start = 0; }\n    return new EnumerateIterator(iter(object), start);\n}\n/**\n * An iterator which enumerates the source values.\n */\nvar EnumerateIterator = /** @class */ (function () {\n    /**\n     * Construct a new enumerate iterator.\n     *\n     * @param source - The iterator of values of interest.\n     *\n     * @param start - The starting enum value.\n     */\n    function EnumerateIterator(source, start) {\n        this._source = source;\n        this._index = start;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    EnumerateIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    EnumerateIterator.prototype.clone = function () {\n        return new EnumerateIterator(this._source.clone(), this._index);\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    EnumerateIterator.prototype.next = function () {\n        var value = this._source.next();\n        if (value === undefined) {\n            return undefined;\n        }\n        return [this._index++, value];\n    };\n    return EnumerateIterator;\n}());\n\n// Copyright (c) Jupyter Development Team.\n/**\n * Filter an iterable for values which pass a test.\n *\n * @param object - The iterable or array-like object of interest.\n *\n * @param fn - The predicate function to invoke for each value.\n *\n * @returns An iterator which yields the values which pass the test.\n *\n * #### Example\n * ```typescript\n * import { filter, toArray } from '@lumino/algorithm';\n *\n * let data = [1, 2, 3, 4, 5, 6];\n *\n * let stream = filter(data, value => value % 2 === 0);\n *\n * toArray(stream);  // [2, 4, 6]\n * ```\n */\nfunction filter(object, fn) {\n    return new FilterIterator(iter(object), fn);\n}\n/**\n * An iterator which yields values which pass a test.\n */\nvar FilterIterator = /** @class */ (function () {\n    /**\n     * Construct a new filter iterator.\n     *\n     * @param source - The iterator of values of interest.\n     *\n     * @param fn - The predicate function to invoke for each value.\n     */\n    function FilterIterator(source, fn) {\n        this._index = 0;\n        this._source = source;\n        this._fn = fn;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    FilterIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    FilterIterator.prototype.clone = function () {\n        var result = new FilterIterator(this._source.clone(), this._fn);\n        result._index = this._index;\n        return result;\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    FilterIterator.prototype.next = function () {\n        var fn = this._fn;\n        var it = this._source;\n        var value;\n        while ((value = it.next()) !== undefined) {\n            if (fn(value, this._index++)) {\n                return value;\n            }\n        }\n        return undefined;\n    };\n    return FilterIterator;\n}());\n\n// Copyright (c) Jupyter Development Team.\n/**\n * Find the first value in an iterable which matches a predicate.\n *\n * @param object - The iterable or array-like object to search.\n *\n * @param fn - The predicate function to apply to the values.\n *\n * @returns The first matching value, or `undefined` if no matching\n *   value is found.\n *\n * #### Complexity\n * Linear.\n *\n * #### Example\n * ```typescript\n * import { find } from '@lumino/algorithm';\n *\n * interface IAnimal { species: string, name: string };\n *\n * function isCat(value: IAnimal): boolean {\n *   return value.species === 'cat';\n * }\n *\n * let data: IAnimal[] = [\n *   { species: 'dog', name: 'spot' },\n *   { species: 'cat', name: 'fluffy' },\n *   { species: 'alligator', name: 'pocho' }\n * ];\n *\n * find(data, isCat).name;  // 'fluffy'\n * ```\n */\nfunction find(object, fn) {\n    var index = 0;\n    var it = iter(object);\n    var value;\n    while ((value = it.next()) !== undefined) {\n        if (fn(value, index++)) {\n            return value;\n        }\n    }\n    return undefined;\n}\n/**\n * Find the index of the first value which matches a predicate.\n *\n * @param object - The iterable or array-like object to search.\n *\n * @param fn - The predicate function to apply to the values.\n *\n * @returns The index of the first matching value, or `-1` if no\n *   matching value is found.\n *\n * #### Complexity\n * Linear.\n *\n * #### Example\n * ```typescript\n * import { findIndex } from '@lumino/algorithm';\n *\n * interface IAnimal { species: string, name: string };\n *\n * function isCat(value: IAnimal): boolean {\n *   return value.species === 'cat';\n * }\n *\n * let data: IAnimal[] = [\n *   { species: 'dog', name: 'spot' },\n *   { species: 'cat', name: 'fluffy' },\n *   { species: 'alligator', name: 'pocho' }\n * ];\n *\n * findIndex(data, isCat);  // 1\n * ```\n */\nfunction findIndex(object, fn) {\n    var index = 0;\n    var it = iter(object);\n    var value;\n    while ((value = it.next()) !== undefined) {\n        if (fn(value, index++)) {\n            return index - 1;\n        }\n    }\n    return -1;\n}\n/**\n * Find the minimum value in an iterable.\n *\n * @param object - The iterable or array-like object to search.\n *\n * @param fn - The 3-way comparison function to apply to the values.\n *   It should return `< 0` if the first value is less than the second.\n *   `0` if the values are equivalent, or `> 0` if the first value is\n *   greater than the second.\n *\n * @returns The minimum value in the iterable. If multiple values are\n *   equivalent to the minimum, the left-most value is returned. If\n *   the iterable is empty, this returns `undefined`.\n *\n * #### Complexity\n * Linear.\n *\n * #### Example\n * ```typescript\n * import { min } from '@lumino/algorithm';\n *\n * function numberCmp(a: number, b: number): number {\n *   return a - b;\n * }\n *\n * min([7, 4, 0, 3, 9, 4], numberCmp);  // 0\n * ```\n */\nfunction min(object, fn) {\n    var it = iter(object);\n    var value = it.next();\n    if (value === undefined) {\n        return undefined;\n    }\n    var result = value;\n    while ((value = it.next()) !== undefined) {\n        if (fn(value, result) < 0) {\n            result = value;\n        }\n    }\n    return result;\n}\n/**\n * Find the maximum value in an iterable.\n *\n * @param object - The iterable or array-like object to search.\n *\n * @param fn - The 3-way comparison function to apply to the values.\n *   It should return `< 0` if the first value is less than the second.\n *   `0` if the values are equivalent, or `> 0` if the first value is\n *   greater than the second.\n *\n * @returns The maximum value in the iterable. If multiple values are\n *   equivalent to the maximum, the left-most value is returned. If\n *   the iterable is empty, this returns `undefined`.\n *\n * #### Complexity\n * Linear.\n *\n * #### Example\n * ```typescript\n * import { max } from '@lumino/algorithm';\n *\n * function numberCmp(a: number, b: number): number {\n *   return a - b;\n * }\n *\n * max([7, 4, 0, 3, 9, 4], numberCmp);  // 9\n * ```\n */\nfunction max(object, fn) {\n    var it = iter(object);\n    var value = it.next();\n    if (value === undefined) {\n        return undefined;\n    }\n    var result = value;\n    while ((value = it.next()) !== undefined) {\n        if (fn(value, result) > 0) {\n            result = value;\n        }\n    }\n    return result;\n}\n/**\n * Find the minimum and maximum values in an iterable.\n *\n * @param object - The iterable or array-like object to search.\n *\n * @param fn - The 3-way comparison function to apply to the values.\n *   It should return `< 0` if the first value is less than the second.\n *   `0` if the values are equivalent, or `> 0` if the first value is\n *   greater than the second.\n *\n * @returns A 2-tuple of the `[min, max]` values in the iterable. If\n *   multiple values are equivalent, the left-most values are returned.\n *   If the iterable is empty, this returns `undefined`.\n *\n * #### Complexity\n * Linear.\n *\n * #### Example\n * ```typescript\n * import { minmax } from '@lumino/algorithm';\n *\n * function numberCmp(a: number, b: number): number {\n *   return a - b;\n * }\n *\n * minmax([7, 4, 0, 3, 9, 4], numberCmp);  // [0, 9]\n * ```\n */\nfunction minmax(object, fn) {\n    var it = iter(object);\n    var value = it.next();\n    if (value === undefined) {\n        return undefined;\n    }\n    var vmin = value;\n    var vmax = value;\n    while ((value = it.next()) !== undefined) {\n        if (fn(value, vmin) < 0) {\n            vmin = value;\n        }\n        else if (fn(value, vmax) > 0) {\n            vmax = value;\n        }\n    }\n    return [vmin, vmax];\n}\n\n// Copyright (c) Jupyter Development Team.\n/**\n * Transform the values of an iterable with a mapping function.\n *\n * @param object - The iterable or array-like object of interest.\n *\n * @param fn - The mapping function to invoke for each value.\n *\n * @returns An iterator which yields the transformed values.\n *\n * #### Example\n * ```typescript\n * import { map, toArray } from '@lumino/algorithm';\n *\n * let data = [1, 2, 3];\n *\n * let stream = map(data, value => value * 2);\n *\n * toArray(stream);  // [2, 4, 6]\n * ```\n */\nfunction map(object, fn) {\n    return new MapIterator(iter(object), fn);\n}\n/**\n * An iterator which transforms values using a mapping function.\n */\nvar MapIterator = /** @class */ (function () {\n    /**\n     * Construct a new map iterator.\n     *\n     * @param source - The iterator of values of interest.\n     *\n     * @param fn - The mapping function to invoke for each value.\n     */\n    function MapIterator(source, fn) {\n        this._index = 0;\n        this._source = source;\n        this._fn = fn;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    MapIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    MapIterator.prototype.clone = function () {\n        var result = new MapIterator(this._source.clone(), this._fn);\n        result._index = this._index;\n        return result;\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    MapIterator.prototype.next = function () {\n        var value = this._source.next();\n        if (value === undefined) {\n            return undefined;\n        }\n        return this._fn.call(undefined, value, this._index++);\n    };\n    return MapIterator;\n}());\n\n/**\n * Create an iterator of evenly spaced values.\n *\n * @param start - The starting value for the range, inclusive.\n *\n * @param stop - The stopping value for the range, exclusive.\n *\n * @param step - The distance between each value.\n *\n * @returns An iterator which produces evenly spaced values.\n *\n * #### Notes\n * In the single argument form of `range(stop)`, `start` defaults to\n * `0` and `step` defaults to `1`.\n *\n * In the two argument form of `range(start, stop)`, `step` defaults\n * to `1`.\n */\nfunction range(start, stop, step) {\n    if (stop === undefined) {\n        return new RangeIterator(0, start, 1);\n    }\n    if (step === undefined) {\n        return new RangeIterator(start, stop, 1);\n    }\n    return new RangeIterator(start, stop, step);\n}\n/**\n * An iterator which produces a range of evenly spaced values.\n */\nvar RangeIterator = /** @class */ (function () {\n    /**\n     * Construct a new range iterator.\n     *\n     * @param start - The starting value for the range, inclusive.\n     *\n     * @param stop - The stopping value for the range, exclusive.\n     *\n     * @param step - The distance between each value.\n     */\n    function RangeIterator(start, stop, step) {\n        this._index = 0;\n        this._start = start;\n        this._stop = stop;\n        this._step = step;\n        this._length = Private.rangeLength(start, stop, step);\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    RangeIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    RangeIterator.prototype.clone = function () {\n        var result = new RangeIterator(this._start, this._stop, this._step);\n        result._index = this._index;\n        return result;\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    RangeIterator.prototype.next = function () {\n        if (this._index >= this._length) {\n            return undefined;\n        }\n        return this._start + this._step * this._index++;\n    };\n    return RangeIterator;\n}());\n/**\n * The namespace for the module implementation details.\n */\nvar Private;\n(function (Private) {\n    /**\n     * Compute the effective length of a range.\n     *\n     * @param start - The starting value for the range, inclusive.\n     *\n     * @param stop - The stopping value for the range, exclusive.\n     *\n     * @param step - The distance between each value.\n     *\n     * @returns The number of steps need to traverse the range.\n     */\n    function rangeLength(start, stop, step) {\n        if (step === 0) {\n            return Infinity;\n        }\n        if (start > stop && step > 0) {\n            return 0;\n        }\n        if (start < stop && step < 0) {\n            return 0;\n        }\n        return Math.ceil((stop - start) / step);\n    }\n    Private.rangeLength = rangeLength;\n})(Private || (Private = {}));\n\n// Copyright (c) Jupyter Development Team.\nfunction reduce(object, fn, initial) {\n    // Setup the iterator and fetch the first value.\n    var index = 0;\n    var it = iter(object);\n    var first = it.next();\n    // An empty iterator and no initial value is an error.\n    if (first === undefined && initial === undefined) {\n        throw new TypeError('Reduce of empty iterable with no initial value.');\n    }\n    // If the iterator is empty, return the initial value.\n    if (first === undefined) {\n        return initial;\n    }\n    // If the iterator has a single item and no initial value, the\n    // reducer is not invoked and the first item is the return value.\n    var second = it.next();\n    if (second === undefined && initial === undefined) {\n        return first;\n    }\n    // If iterator has a single item and an initial value is provided,\n    // the reducer is invoked and that result is the return value.\n    if (second === undefined) {\n        return fn(initial, first, index++);\n    }\n    // Setup the initial accumlated value.\n    var accumulator;\n    if (initial === undefined) {\n        accumulator = fn(first, second, index++);\n    }\n    else {\n        accumulator = fn(fn(initial, first, index++), second, index++);\n    }\n    // Iterate the rest of the values, updating the accumulator.\n    var next;\n    while ((next = it.next()) !== undefined) {\n        accumulator = fn(accumulator, next, index++);\n    }\n    // Return the final accumulated value.\n    return accumulator;\n}\n\n/**\n * Create an iterator which repeats a value a number of times.\n *\n * @param value - The value to repeat.\n *\n * @param count - The number of times to repeat the value.\n *\n * @returns A new iterator which repeats the specified value.\n *\n * #### Example\n * ```typescript\n * import { repeat, toArray } from '@lumino/algorithm';\n *\n * let stream = repeat(7, 3);\n *\n * toArray(stream);  // [7, 7, 7]\n * ```\n */\nfunction repeat(value, count) {\n    return new RepeatIterator(value, count);\n}\n/**\n * Create an iterator which yields a value a single time.\n *\n * @param value - The value to wrap in an iterator.\n *\n * @returns A new iterator which yields the value a single time.\n *\n * #### Example\n * ```typescript\n * import { once, toArray } from '@lumino/algorithm';\n *\n * let stream = once(7);\n *\n * toArray(stream);  // [7]\n * ```\n */\nfunction once(value) {\n    return new RepeatIterator(value, 1);\n}\n/**\n * An iterator which repeats a value a specified number of times.\n */\nvar RepeatIterator = /** @class */ (function () {\n    /**\n     * Construct a new repeat iterator.\n     *\n     * @param value - The value to repeat.\n     *\n     * @param count - The number of times to repeat the value.\n     */\n    function RepeatIterator(value, count) {\n        this._value = value;\n        this._count = count;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    RepeatIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    RepeatIterator.prototype.clone = function () {\n        return new RepeatIterator(this._value, this._count);\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    RepeatIterator.prototype.next = function () {\n        if (this._count <= 0) {\n            return undefined;\n        }\n        this._count--;\n        return this._value;\n    };\n    return RepeatIterator;\n}());\n\n/**\n * Create an iterator for a retroable object.\n *\n * @param object - The retroable or array-like object of interest.\n *\n * @returns An iterator which traverses the object's values in reverse.\n *\n * #### Example\n * ```typescript\n * import { retro, toArray } from '@lumino/algorithm';\n *\n * let data = [1, 2, 3, 4, 5, 6];\n *\n * let stream = retro(data);\n *\n * toArray(stream);  // [6, 5, 4, 3, 2, 1]\n * ```\n */\nfunction retro(object) {\n    var it;\n    if (typeof object.retro === 'function') {\n        it = object.retro();\n    }\n    else {\n        it = new RetroArrayIterator(object);\n    }\n    return it;\n}\n/**\n * An iterator which traverses an array-like object in reverse.\n *\n * #### Notes\n * This iterator can be used for any builtin JS array-like object.\n */\nvar RetroArrayIterator = /** @class */ (function () {\n    /**\n     * Construct a new retro iterator.\n     *\n     * @param source - The array-like object of interest.\n     */\n    function RetroArrayIterator(source) {\n        this._source = source;\n        this._index = source.length - 1;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    RetroArrayIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    RetroArrayIterator.prototype.clone = function () {\n        var result = new RetroArrayIterator(this._source);\n        result._index = this._index;\n        return result;\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    RetroArrayIterator.prototype.next = function () {\n        if (this._index < 0 || this._index >= this._source.length) {\n            return undefined;\n        }\n        return this._source[this._index--];\n    };\n    return RetroArrayIterator;\n}());\n\n// Copyright (c) Jupyter Development Team.\n/**\n * Topologically sort an iterable of edges.\n *\n * @param edges - The iterable or array-like object of edges to sort.\n *   An edge is represented as a 2-tuple of `[fromNode, toNode]`.\n *\n * @returns The topologically sorted array of nodes.\n *\n * #### Notes\n * If a cycle is present in the graph, the cycle will be ignored and\n * the return value will be only approximately sorted.\n *\n * #### Example\n * ```typescript\n * import { topologicSort } from '@lumino/algorithm';\n *\n * let data = [\n *   ['d', 'e'],\n *   ['c', 'd'],\n *   ['a', 'b'],\n *   ['b', 'c']\n * ];\n *\n * topologicSort(data);  // ['a', 'b', 'c', 'd', 'e']\n * ```\n */\nfunction topologicSort(edges) {\n    // Setup the shared sorting state.\n    var sorted = [];\n    var visited = new Set();\n    var graph = new Map();\n    // Add the edges to the graph.\n    each(edges, addEdge);\n    // Visit each node in the graph.\n    graph.forEach(function (v, k) { visit(k); });\n    // Return the sorted results.\n    return sorted;\n    // Add an edge to the graph.\n    function addEdge(edge) {\n        var fromNode = edge[0], toNode = edge[1];\n        var children = graph.get(toNode);\n        if (children) {\n            children.push(fromNode);\n        }\n        else {\n            graph.set(toNode, [fromNode]);\n        }\n    }\n    // Recursively visit the node.\n    function visit(node) {\n        if (visited.has(node)) {\n            return;\n        }\n        visited.add(node);\n        var children = graph.get(node);\n        if (children) {\n            children.forEach(visit);\n        }\n        sorted.push(node);\n    }\n}\n\n// Copyright (c) Jupyter Development Team.\n/**\n * Iterate over an iterable using a stepped increment.\n *\n * @param object - The iterable or array-like object of interest.\n *\n * @param step - The distance to step on each iteration. A value\n *   of less than `1` will behave the same as a value of `1`.\n *\n * @returns An iterator which traverses the iterable step-wise.\n *\n * #### Example\n * ```typescript\n * import { stride, toArray } from '@lumino/algorithm';\n *\n * let data = [1, 2, 3, 4, 5, 6];\n *\n * let stream = stride(data, 2);\n *\n * toArray(stream);  // [1, 3, 5];\n * ```\n */\nfunction stride(object, step) {\n    return new StrideIterator(iter(object), step);\n}\n/**\n * An iterator which traverses a source iterator step-wise.\n */\nvar StrideIterator = /** @class */ (function () {\n    /**\n     * Construct a new stride iterator.\n     *\n     * @param source - The iterator of values of interest.\n     *\n     * @param step - The distance to step on each iteration. A value\n     *   of less than `1` will behave the same as a value of `1`.\n     */\n    function StrideIterator(source, step) {\n        this._source = source;\n        this._step = step;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    StrideIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    StrideIterator.prototype.clone = function () {\n        return new StrideIterator(this._source.clone(), this._step);\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    StrideIterator.prototype.next = function () {\n        var value = this._source.next();\n        for (var n = this._step - 1; n > 0; --n) {\n            this._source.next();\n        }\n        return value;\n    };\n    return StrideIterator;\n}());\n\n// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * The namespace for string-specific algorithms.\n */\nvar StringExt;\n(function (StringExt) {\n    /**\n     * Find the indices of characters in a source text.\n     *\n     * @param source - The source text which should be searched.\n     *\n     * @param query - The characters to locate in the source text.\n     *\n     * @param start - The index to start the search.\n     *\n     * @returns The matched indices, or `null` if there is no match.\n     *\n     * #### Complexity\n     * Linear on `sourceText`.\n     *\n     * #### Notes\n     * In order for there to be a match, all of the characters in `query`\n     * **must** appear in `source` in the order given by `query`.\n     *\n     * Characters are matched using strict `===` equality.\n     */\n    function findIndices(source, query, start) {\n        if (start === void 0) { start = 0; }\n        var indices = new Array(query.length);\n        for (var i = 0, j = start, n = query.length; i < n; ++i, ++j) {\n            j = source.indexOf(query[i], j);\n            if (j === -1) {\n                return null;\n            }\n            indices[i] = j;\n        }\n        return indices;\n    }\n    StringExt.findIndices = findIndices;\n    /**\n     * A string matcher which uses a sum-of-squares algorithm.\n     *\n     * @param source - The source text which should be searched.\n     *\n     * @param query - The characters to locate in the source text.\n     *\n     * @param start - The index to start the search.\n     *\n     * @returns The match result, or `null` if there is no match.\n     *   A lower `score` represents a stronger match.\n     *\n     * #### Complexity\n     * Linear on `sourceText`.\n     *\n     * #### Notes\n     * This scoring algorithm uses a sum-of-squares approach to determine\n     * the score. In order for there to be a match, all of the characters\n     * in `query` **must** appear in `source` in order. The index of each\n     * matching character is squared and added to the score. This means\n     * that early and consecutive character matches are preferred, while\n     * late matches are heavily penalized.\n     */\n    function matchSumOfSquares(source, query, start) {\n        if (start === void 0) { start = 0; }\n        var indices = findIndices(source, query, start);\n        if (!indices) {\n            return null;\n        }\n        var score = 0;\n        for (var i = 0, n = indices.length; i < n; ++i) {\n            var j = indices[i] - start;\n            score += j * j;\n        }\n        return { score: score, indices: indices };\n    }\n    StringExt.matchSumOfSquares = matchSumOfSquares;\n    /**\n     * A string matcher which uses a sum-of-deltas algorithm.\n     *\n     * @param source - The source text which should be searched.\n     *\n     * @param query - The characters to locate in the source text.\n     *\n     * @param start - The index to start the search.\n     *\n     * @returns The match result, or `null` if there is no match.\n     *   A lower `score` represents a stronger match.\n     *\n     * #### Complexity\n     * Linear on `sourceText`.\n     *\n     * #### Notes\n     * This scoring algorithm uses a sum-of-deltas approach to determine\n     * the score. In order for there to be a match, all of the characters\n     * in `query` **must** appear in `source` in order. The delta between\n     * the indices are summed to create the score. This means that groups\n     * of matched characters are preferred, while fragmented matches are\n     * penalized.\n     */\n    function matchSumOfDeltas(source, query, start) {\n        if (start === void 0) { start = 0; }\n        var indices = findIndices(source, query, start);\n        if (!indices) {\n            return null;\n        }\n        var score = 0;\n        var last = start - 1;\n        for (var i = 0, n = indices.length; i < n; ++i) {\n            var j = indices[i];\n            score += j - last - 1;\n            last = j;\n        }\n        return { score: score, indices: indices };\n    }\n    StringExt.matchSumOfDeltas = matchSumOfDeltas;\n    /**\n     * Highlight the matched characters of a source text.\n     *\n     * @param source - The text which should be highlighted.\n     *\n     * @param indices - The indices of the matched characters. They must\n     *   appear in increasing order and must be in bounds of the source.\n     *\n     * @param fn - The function to apply to the matched chunks.\n     *\n     * @returns An array of unmatched and highlighted chunks.\n     */\n    function highlight(source, indices, fn) {\n        // Set up the result array.\n        var result = [];\n        // Set up the counter variables.\n        var k = 0;\n        var last = 0;\n        var n = indices.length;\n        // Iterator over each index.\n        while (k < n) {\n            // Set up the chunk indices.\n            var i = indices[k];\n            var j = indices[k];\n            // Advance the right chunk index until it's non-contiguous.\n            while (++k < n && indices[k] === j + 1) {\n                j++;\n            }\n            // Extract the unmatched text.\n            if (last < i) {\n                result.push(source.slice(last, i));\n            }\n            // Extract and highlight the matched text.\n            if (i < j + 1) {\n                result.push(fn(source.slice(i, j + 1)));\n            }\n            // Update the last visited index.\n            last = j + 1;\n        }\n        // Extract any remaining unmatched text.\n        if (last < source.length) {\n            result.push(source.slice(last));\n        }\n        // Return the highlighted result.\n        return result;\n    }\n    StringExt.highlight = highlight;\n    /**\n     * A 3-way string comparison function.\n     *\n     * @param a - The first string of interest.\n     *\n     * @param b - The second string of interest.\n     *\n     * @returns `-1` if `a < b`, else `1` if `a > b`, else `0`.\n     */\n    function cmp(a, b) {\n        return a < b ? -1 : a > b ? 1 : 0;\n    }\n    StringExt.cmp = cmp;\n})(StringExt || (StringExt = {}));\n\n// Copyright (c) Jupyter Development Team.\n/**\n * Take a fixed number of items from an iterable.\n *\n * @param object - The iterable or array-like object of interest.\n *\n * @param count - The number of items to take from the iterable.\n *\n * @returns An iterator which yields the specified number of items\n *   from the source iterable.\n *\n * #### Notes\n * The returned iterator will exhaust early if the source iterable\n * contains an insufficient number of items.\n */\nfunction take(object, count) {\n    return new TakeIterator(iter(object), count);\n}\n/**\n * An iterator which takes a fixed number of items from a source.\n */\nvar TakeIterator = /** @class */ (function () {\n    /**\n     * Construct a new take iterator.\n     *\n     * @param source - The iterator of interest.\n     *\n     * @param count - The number of items to take from the source.\n     */\n    function TakeIterator(source, count) {\n        this._source = source;\n        this._count = count;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    TakeIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    TakeIterator.prototype.clone = function () {\n        return new TakeIterator(this._source.clone(), this._count);\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    TakeIterator.prototype.next = function () {\n        if (this._count <= 0) {\n            return undefined;\n        }\n        var value = this._source.next();\n        if (value === undefined) {\n            return undefined;\n        }\n        this._count--;\n        return value;\n    };\n    return TakeIterator;\n}());\n\n// Copyright (c) Jupyter Development Team.\n/**\n * Iterate several iterables in lockstep.\n *\n * @param objects - The iterable or array-like objects of interest.\n *\n * @returns An iterator which yields successive tuples of values where\n *   each value is taken in turn from the provided iterables. It will\n *   be as long as the shortest provided iterable.\n *\n * #### Example\n * ```typescript\n * import { zip, toArray } from '@lumino/algorithm';\n *\n * let data1 = [1, 2, 3];\n * let data2 = [4, 5, 6];\n *\n * let stream = zip(data1, data2);\n *\n * toArray(stream);  // [[1, 4], [2, 5], [3, 6]]\n * ```\n */\nfunction zip() {\n    var objects = [];\n    for (var _i = 0; _i < arguments.length; _i++) {\n        objects[_i] = arguments[_i];\n    }\n    return new ZipIterator(objects.map(iter));\n}\n/**\n * An iterator which iterates several sources in lockstep.\n */\nvar ZipIterator = /** @class */ (function () {\n    /**\n     * Construct a new zip iterator.\n     *\n     * @param source - The iterators of interest.\n     */\n    function ZipIterator(source) {\n        this._source = source;\n    }\n    /**\n     * Get an iterator over the object's values.\n     *\n     * @returns An iterator which yields the object's values.\n     */\n    ZipIterator.prototype.iter = function () {\n        return this;\n    };\n    /**\n     * Create an independent clone of the iterator.\n     *\n     * @returns A new independent clone of the iterator.\n     */\n    ZipIterator.prototype.clone = function () {\n        return new ZipIterator(this._source.map(function (it) { return it.clone(); }));\n    };\n    /**\n     * Get the next value from the iterator.\n     *\n     * @returns The next value from the iterator, or `undefined`.\n     */\n    ZipIterator.prototype.next = function () {\n        var result = new Array(this._source.length);\n        for (var i = 0, n = this._source.length; i < n; ++i) {\n            var value = this._source[i].next();\n            if (value === undefined) {\n                return undefined;\n            }\n            result[i] = value;\n        }\n        return result;\n    };\n    return ZipIterator;\n}());\n\nexport { ArrayExt, ArrayIterator, ChainIterator, EmptyIterator, EnumerateIterator, FilterIterator, FnIterator, ItemIterator, KeyIterator, MapIterator, RangeIterator, RepeatIterator, RetroArrayIterator, StrideIterator, StringExt, TakeIterator, ValueIterator, ZipIterator, chain, each, empty, enumerate, every, filter, find, findIndex, iter, iterFn, iterItems, iterKeys, iterValues, map, max, min, minmax, once, range, reduce, repeat, retro, some, stride, take, toArray, toObject, topologicSort, zip };\n//# sourceMappingURL=index.es6.js.map\n","import { every, retro, some, ArrayExt, each } from '@lumino/algorithm';\nimport { LinkedList } from '@lumino/collections';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n    extendStatics = Object.setPrototypeOf ||\r\n        ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n        function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\r\n    return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n    extendStatics(d, b);\r\n    function __() { this.constructor = d; }\r\n    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * A message which can be delivered to a message handler.\n *\n * #### Notes\n * This class may be subclassed to create complex message types.\n */\nvar Message = /** @class */ (function () {\n    /**\n     * Construct a new message.\n     *\n     * @param type - The type of the message.\n     */\n    function Message(type) {\n        this.type = type;\n    }\n    Object.defineProperty(Message.prototype, \"isConflatable\", {\n        /**\n         * Test whether the message is conflatable.\n         *\n         * #### Notes\n         * Message conflation is an advanced topic. Most message types will\n         * not make use of this feature.\n         *\n         * If a conflatable message is posted to a handler while another\n         * conflatable message of the same `type` has already been posted\n         * to the handler, the `conflate()` method of the existing message\n         * will be invoked. If that method returns `true`, the new message\n         * will not be enqueued. This allows messages to be compressed, so\n         * that only a single instance of the message type is processed per\n         * cycle, no matter how many times messages of that type are posted.\n         *\n         * Custom message types may reimplement this property.\n         *\n         * The default implementation is always `false`.\n         */\n        get: function () {\n            return false;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Conflate this message with another message of the same `type`.\n     *\n     * @param other - A conflatable message of the same `type`.\n     *\n     * @returns `true` if the message was successfully conflated, or\n     *   `false` otherwise.\n     *\n     * #### Notes\n     * Message conflation is an advanced topic. Most message types will\n     * not make use of this feature.\n     *\n     * This method is called automatically by the message loop when the\n     * given message is posted to the handler paired with this message.\n     * This message will already be enqueued and conflatable, and the\n     * given message will have the same `type` and also be conflatable.\n     *\n     * This method should merge the state of the other message into this\n     * message as needed so that when this message is finally delivered\n     * to the handler, it receives the most up-to-date information.\n     *\n     * If this method returns `true`, it signals that the other message\n     * was successfully conflated and that message will not be enqueued.\n     *\n     * If this method returns `false`, the other message will be enqueued\n     * for normal delivery.\n     *\n     * Custom message types may reimplement this method.\n     *\n     * The default implementation always returns `false`.\n     */\n    Message.prototype.conflate = function (other) {\n        return false;\n    };\n    return Message;\n}());\n/**\n * A convenience message class which conflates automatically.\n *\n * #### Notes\n * Message conflation is an advanced topic. Most user code will not\n * make use of this class.\n *\n * This message class is useful for creating message instances which\n * should be conflated, but which have no state other than `type`.\n *\n * If conflation of stateful messages is required, a custom `Message`\n * subclass should be created.\n */\nvar ConflatableMessage = /** @class */ (function (_super) {\n    __extends(ConflatableMessage, _super);\n    function ConflatableMessage() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    Object.defineProperty(ConflatableMessage.prototype, \"isConflatable\", {\n        /**\n         * Test whether the message is conflatable.\n         *\n         * #### Notes\n         * This property is always `true`.\n         */\n        get: function () {\n            return true;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Conflate this message with another message of the same `type`.\n     *\n     * #### Notes\n     * This method always returns `true`.\n     */\n    ConflatableMessage.prototype.conflate = function (other) {\n        return true;\n    };\n    return ConflatableMessage;\n}(Message));\n/**\n * The namespace for the global singleton message loop.\n */\nvar MessageLoop;\n(function (MessageLoop) {\n    /**\n     * Send a message to a message handler to process immediately.\n     *\n     * @param handler - The handler which should process the message.\n     *\n     * @param msg - The message to deliver to the handler.\n     *\n     * #### Notes\n     * The message will first be sent through any installed message hooks\n     * for the handler. If the message passes all hooks, it will then be\n     * delivered to the `processMessage` method of the handler.\n     *\n     * The message will not be conflated with pending posted messages.\n     *\n     * Exceptions in hooks and handlers will be caught and logged.\n     */\n    function sendMessage(handler, msg) {\n        // Lookup the message hooks for the handler.\n        var hooks = messageHooks.get(handler);\n        // Handle the common case of no installed hooks.\n        if (!hooks || hooks.length === 0) {\n            invokeHandler(handler, msg);\n            return;\n        }\n        // Invoke the message hooks starting with the newest first.\n        var passed = every(retro(hooks), function (hook) {\n            return hook ? invokeHook(hook, handler, msg) : true;\n        });\n        // Invoke the handler if the message passes all hooks.\n        if (passed) {\n            invokeHandler(handler, msg);\n        }\n    }\n    MessageLoop.sendMessage = sendMessage;\n    /**\n     * Post a message to a message handler to process in the future.\n     *\n     * @param handler - The handler which should process the message.\n     *\n     * @param msg - The message to post to the handler.\n     *\n     * #### Notes\n     * The message will be conflated with the pending posted messages for\n     * the handler, if possible. If the message is not conflated, it will\n     * be queued for normal delivery on the next cycle of the event loop.\n     *\n     * Exceptions in hooks and handlers will be caught and logged.\n     */\n    function postMessage(handler, msg) {\n        // Handle the common case of a non-conflatable message.\n        if (!msg.isConflatable) {\n            enqueueMessage(handler, msg);\n            return;\n        }\n        // Conflate the message with an existing message if possible.\n        var conflated = some(messageQueue, function (posted) {\n            if (posted.handler !== handler) {\n                return false;\n            }\n            if (!posted.msg) {\n                return false;\n            }\n            if (posted.msg.type !== msg.type) {\n                return false;\n            }\n            if (!posted.msg.isConflatable) {\n                return false;\n            }\n            return posted.msg.conflate(msg);\n        });\n        // Enqueue the message if it was not conflated.\n        if (!conflated) {\n            enqueueMessage(handler, msg);\n        }\n    }\n    MessageLoop.postMessage = postMessage;\n    /**\n     * Install a message hook for a message handler.\n     *\n     * @param handler - The message handler of interest.\n     *\n     * @param hook - The message hook to install.\n     *\n     * #### Notes\n     * A message hook is invoked before a message is delivered to the\n     * handler. If the hook returns `false`, no other hooks will be\n     * invoked and the message will not be delivered to the handler.\n     *\n     * The most recently installed message hook is executed first.\n     *\n     * If the hook is already installed, this is a no-op.\n     */\n    function installMessageHook(handler, hook) {\n        // Lookup the hooks for the handler.\n        var hooks = messageHooks.get(handler);\n        // Bail early if the hook is already installed.\n        if (hooks && hooks.indexOf(hook) !== -1) {\n            return;\n        }\n        // Add the hook to the end, so it will be the first to execute.\n        if (!hooks) {\n            messageHooks.set(handler, [hook]);\n        }\n        else {\n            hooks.push(hook);\n        }\n    }\n    MessageLoop.installMessageHook = installMessageHook;\n    /**\n     * Remove an installed message hook for a message handler.\n     *\n     * @param handler - The message handler of interest.\n     *\n     * @param hook - The message hook to remove.\n     *\n     * #### Notes\n     * It is safe to call this function while the hook is executing.\n     *\n     * If the hook is not installed, this is a no-op.\n     */\n    function removeMessageHook(handler, hook) {\n        // Lookup the hooks for the handler.\n        var hooks = messageHooks.get(handler);\n        // Bail early if the hooks do not exist.\n        if (!hooks) {\n            return;\n        }\n        // Lookup the index of the hook and bail if not found.\n        var i = hooks.indexOf(hook);\n        if (i === -1) {\n            return;\n        }\n        // Clear the hook and schedule a cleanup of the array.\n        hooks[i] = null;\n        scheduleCleanup(hooks);\n    }\n    MessageLoop.removeMessageHook = removeMessageHook;\n    /**\n     * Clear all message data associated with a message handler.\n     *\n     * @param handler - The message handler of interest.\n     *\n     * #### Notes\n     * This will clear all posted messages and hooks for the handler.\n     */\n    function clearData(handler) {\n        // Lookup the hooks for the handler.\n        var hooks = messageHooks.get(handler);\n        // Clear all messsage hooks for the handler.\n        if (hooks && hooks.length > 0) {\n            ArrayExt.fill(hooks, null);\n            scheduleCleanup(hooks);\n        }\n        // Clear all posted messages for the handler.\n        each(messageQueue, function (posted) {\n            if (posted.handler === handler) {\n                posted.handler = null;\n                posted.msg = null;\n            }\n        });\n    }\n    MessageLoop.clearData = clearData;\n    /**\n     * Process the pending posted messages in the queue immediately.\n     *\n     * #### Notes\n     * This function is useful when posted messages must be processed\n     * immediately, instead of on the next animation frame.\n     *\n     * This function should normally not be needed, but it may be\n     * required to work around certain browser idiosyncrasies.\n     *\n     * Recursing into this function is a no-op.\n     */\n    function flush() {\n        // Bail if recursion is detected or if there is no pending task.\n        if (flushGuard || loopTaskID === 0) {\n            return;\n        }\n        // Unschedule the pending loop task.\n        unschedule(loopTaskID);\n        // Run the message loop within the recursion guard.\n        flushGuard = true;\n        runMessageLoop();\n        flushGuard = false;\n    }\n    MessageLoop.flush = flush;\n    /**\n     * Get the message loop exception handler.\n     *\n     * @returns The current exception handler.\n     *\n     * #### Notes\n     * The default exception handler is `console.error`.\n     */\n    function getExceptionHandler() {\n        return exceptionHandler;\n    }\n    MessageLoop.getExceptionHandler = getExceptionHandler;\n    /**\n     * Set the message loop exception handler.\n     *\n     * @param handler - The function to use as the exception handler.\n     *\n     * @returns The old exception handler.\n     *\n     * #### Notes\n     * The exception handler is invoked when a message handler or a\n     * message hook throws an exception.\n     */\n    function setExceptionHandler(handler) {\n        var old = exceptionHandler;\n        exceptionHandler = handler;\n        return old;\n    }\n    MessageLoop.setExceptionHandler = setExceptionHandler;\n    /**\n     * The queue of posted message pairs.\n     */\n    var messageQueue = new LinkedList();\n    /**\n     * A mapping of handler to array of installed message hooks.\n     */\n    var messageHooks = new WeakMap();\n    /**\n     * A set of message hook arrays which are pending cleanup.\n     */\n    var dirtySet = new Set();\n    /**\n     * The message loop exception handler.\n     */\n    var exceptionHandler = function (err) {\n        console.error(err);\n    };\n    /**\n     * The id of the pending loop task animation frame.\n     */\n    var loopTaskID = 0;\n    /**\n     * A guard flag to prevent flush recursion.\n     */\n    var flushGuard = false;\n    /**\n     * A function to schedule an event loop callback.\n     */\n    var schedule = (function () {\n        var ok = typeof requestAnimationFrame === 'function';\n        return ok ? requestAnimationFrame : setImmediate;\n    })();\n    /**\n     * A function to unschedule an event loop callback.\n     */\n    var unschedule = (function () {\n        var ok = typeof cancelAnimationFrame === 'function';\n        return ok ? cancelAnimationFrame : clearImmediate;\n    })();\n    /**\n     * Invoke a message hook with the specified handler and message.\n     *\n     * Returns the result of the hook, or `true` if the hook throws.\n     *\n     * Exceptions in the hook will be caught and logged.\n     */\n    function invokeHook(hook, handler, msg) {\n        var result = true;\n        try {\n            if (typeof hook === 'function') {\n                result = hook(handler, msg);\n            }\n            else {\n                result = hook.messageHook(handler, msg);\n            }\n        }\n        catch (err) {\n            exceptionHandler(err);\n        }\n        return result;\n    }\n    /**\n     * Invoke a message handler with the specified message.\n     *\n     * Exceptions in the handler will be caught and logged.\n     */\n    function invokeHandler(handler, msg) {\n        try {\n            handler.processMessage(msg);\n        }\n        catch (err) {\n            exceptionHandler(err);\n        }\n    }\n    /**\n     * Add a message to the end of the message queue.\n     *\n     * This will automatically schedule a run of the message loop.\n     */\n    function enqueueMessage(handler, msg) {\n        // Add the posted message to the queue.\n        messageQueue.addLast({ handler: handler, msg: msg });\n        // Bail if a loop task is already pending.\n        if (loopTaskID !== 0) {\n            return;\n        }\n        // Schedule a run of the message loop.\n        loopTaskID = schedule(runMessageLoop);\n    }\n    /**\n     * Run an iteration of the message loop.\n     *\n     * This will process all pending messages in the queue. If a message\n     * is added to the queue while the message loop is running, it will\n     * be processed on the next cycle of the loop.\n     */\n    function runMessageLoop() {\n        // Clear the task ID so the next loop can be scheduled.\n        loopTaskID = 0;\n        // If the message queue is empty, there is nothing else to do.\n        if (messageQueue.isEmpty) {\n            return;\n        }\n        // Add a sentinel value to the end of the queue. The queue will\n        // only be processed up to the sentinel. Messages posted during\n        // this cycle will execute on the next cycle.\n        var sentinel = { handler: null, msg: null };\n        messageQueue.addLast(sentinel);\n        // Enter the message loop.\n        while (true) {\n            // Remove the first posted message in the queue.\n            var posted = messageQueue.removeFirst();\n            // If the value is the sentinel, exit the loop.\n            if (posted === sentinel) {\n                return;\n            }\n            // Dispatch the message if it has not been cleared.\n            if (posted.handler && posted.msg) {\n                sendMessage(posted.handler, posted.msg);\n            }\n        }\n    }\n    /**\n     * Schedule a cleanup of a message hooks array.\n     *\n     * This will add the array to the dirty set and schedule a deferred\n     * cleanup of the array contents. On cleanup, any `null` hook will\n     * be removed from the array.\n     */\n    function scheduleCleanup(hooks) {\n        if (dirtySet.size === 0) {\n            schedule(cleanupDirtySet);\n        }\n        dirtySet.add(hooks);\n    }\n    /**\n     * Cleanup the message hook arrays in the dirty set.\n     *\n     * This function should only be invoked asynchronously, when the\n     * stack frame is guaranteed to not be on the path of user code.\n     */\n    function cleanupDirtySet() {\n        dirtySet.forEach(cleanupHooks);\n        dirtySet.clear();\n    }\n    /**\n     * Cleanup the dirty hooks in a message hooks array.\n     *\n     * This will remove any `null` hook from the array.\n     *\n     * This function should only be invoked asynchronously, when the\n     * stack frame is guaranteed to not be on the path of user code.\n     */\n    function cleanupHooks(hooks) {\n        ArrayExt.removeAllWhere(hooks, isNull);\n    }\n    /**\n     * Test whether a value is `null`.\n     */\n    function isNull(value) {\n        return value === null;\n    }\n})(MessageLoop || (MessageLoop = {}));\n\nexport { ConflatableMessage, Message, MessageLoop };\n//# sourceMappingURL=index.es6.js.map\n","//     Underscore.js 1.9.1\n//     http://underscorejs.org\n//     (c) 2009-2018 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n//     Underscore may be freely distributed under the MIT license.\n\n(function() {\n\n  // Baseline setup\n  // --------------\n\n  // Establish the root object, `window` (`self`) in the browser, `global`\n  // on the server, or `this` in some virtual machines. We use `self`\n  // instead of `window` for `WebWorker` support.\n  var root = typeof self == 'object' && self.self === self && self ||\n            typeof global == 'object' && global.global === global && global ||\n            this ||\n            {};\n\n  // Save the previous value of the `_` variable.\n  var previousUnderscore = root._;\n\n  // Save bytes in the minified (but not gzipped) version:\n  var ArrayProto = Array.prototype, ObjProto = Object.prototype;\n  var SymbolProto = typeof Symbol !== 'undefined' ? Symbol.prototype : null;\n\n  // Create quick reference variables for speed access to core prototypes.\n  var push = ArrayProto.push,\n      slice = ArrayProto.slice,\n      toString = ObjProto.toString,\n      hasOwnProperty = ObjProto.hasOwnProperty;\n\n  // All **ECMAScript 5** native function implementations that we hope to use\n  // are declared here.\n  var nativeIsArray = Array.isArray,\n      nativeKeys = Object.keys,\n      nativeCreate = Object.create;\n\n  // Naked function reference for surrogate-prototype-swapping.\n  var Ctor = function(){};\n\n  // Create a safe reference to the Underscore object for use below.\n  var _ = function(obj) {\n    if (obj instanceof _) return obj;\n    if (!(this instanceof _)) return new _(obj);\n    this._wrapped = obj;\n  };\n\n  // Export the Underscore object for **Node.js**, with\n  // backwards-compatibility for their old module API. If we're in\n  // the browser, add `_` as a global object.\n  // (`nodeType` is checked to ensure that `module`\n  // and `exports` are not HTML elements.)\n  if (typeof exports != 'undefined' && !exports.nodeType) {\n    if (typeof module != 'undefined' && !module.nodeType && module.exports) {\n      exports = module.exports = _;\n    }\n    exports._ = _;\n  } else {\n    root._ = _;\n  }\n\n  // Current version.\n  _.VERSION = '1.9.1';\n\n  // Internal function that returns an efficient (for current engines) version\n  // of the passed-in callback, to be repeatedly applied in other Underscore\n  // functions.\n  var optimizeCb = function(func, context, argCount) {\n    if (context === void 0) return func;\n    switch (argCount == null ? 3 : argCount) {\n      case 1: return function(value) {\n        return func.call(context, value);\n      };\n      // The 2-argument case is omitted because we’re not using it.\n      case 3: return function(value, index, collection) {\n        return func.call(context, value, index, collection);\n      };\n      case 4: return function(accumulator, value, index, collection) {\n        return func.call(context, accumulator, value, index, collection);\n      };\n    }\n    return function() {\n      return func.apply(context, arguments);\n    };\n  };\n\n  var builtinIteratee;\n\n  // An internal function to generate callbacks that can be applied to each\n  // element in a collection, returning the desired result — either `identity`,\n  // an arbitrary callback, a property matcher, or a property accessor.\n  var cb = function(value, context, argCount) {\n    if (_.iteratee !== builtinIteratee) return _.iteratee(value, context);\n    if (value == null) return _.identity;\n    if (_.isFunction(value)) return optimizeCb(value, context, argCount);\n    if (_.isObject(value) && !_.isArray(value)) return _.matcher(value);\n    return _.property(value);\n  };\n\n  // External wrapper for our callback generator. Users may customize\n  // `_.iteratee` if they want additional predicate/iteratee shorthand styles.\n  // This abstraction hides the internal-only argCount argument.\n  _.iteratee = builtinIteratee = function(value, context) {\n    return cb(value, context, Infinity);\n  };\n\n  // Some functions take a variable number of arguments, or a few expected\n  // arguments at the beginning and then a variable number of values to operate\n  // on. This helper accumulates all remaining arguments past the function’s\n  // argument length (or an explicit `startIndex`), into an array that becomes\n  // the last argument. Similar to ES6’s \"rest parameter\".\n  var restArguments = function(func, startIndex) {\n    startIndex = startIndex == null ? func.length - 1 : +startIndex;\n    return function() {\n      var length = Math.max(arguments.length - startIndex, 0),\n          rest = Array(length),\n          index = 0;\n      for (; index < length; index++) {\n        rest[index] = arguments[index + startIndex];\n      }\n      switch (startIndex) {\n        case 0: return func.call(this, rest);\n        case 1: return func.call(this, arguments[0], rest);\n        case 2: return func.call(this, arguments[0], arguments[1], rest);\n      }\n      var args = Array(startIndex + 1);\n      for (index = 0; index < startIndex; index++) {\n        args[index] = arguments[index];\n      }\n      args[startIndex] = rest;\n      return func.apply(this, args);\n    };\n  };\n\n  // An internal function for creating a new object that inherits from another.\n  var baseCreate = function(prototype) {\n    if (!_.isObject(prototype)) return {};\n    if (nativeCreate) return nativeCreate(prototype);\n    Ctor.prototype = prototype;\n    var result = new Ctor;\n    Ctor.prototype = null;\n    return result;\n  };\n\n  var shallowProperty = function(key) {\n    return function(obj) {\n      return obj == null ? void 0 : obj[key];\n    };\n  };\n\n  var has = function(obj, path) {\n    return obj != null && hasOwnProperty.call(obj, path);\n  }\n\n  var deepGet = function(obj, path) {\n    var length = path.length;\n    for (var i = 0; i < length; i++) {\n      if (obj == null) return void 0;\n      obj = obj[path[i]];\n    }\n    return length ? obj : void 0;\n  };\n\n  // Helper for collection methods to determine whether a collection\n  // should be iterated as an array or as an object.\n  // Related: http://people.mozilla.org/~jorendorff/es6-draft.html#sec-tolength\n  // Avoids a very nasty iOS 8 JIT bug on ARM-64. #2094\n  var MAX_ARRAY_INDEX = Math.pow(2, 53) - 1;\n  var getLength = shallowProperty('length');\n  var isArrayLike = function(collection) {\n    var length = getLength(collection);\n    return typeof length == 'number' && length >= 0 && length <= MAX_ARRAY_INDEX;\n  };\n\n  // Collection Functions\n  // --------------------\n\n  // The cornerstone, an `each` implementation, aka `forEach`.\n  // Handles raw objects in addition to array-likes. Treats all\n  // sparse array-likes as if they were dense.\n  _.each = _.forEach = function(obj, iteratee, context) {\n    iteratee = optimizeCb(iteratee, context);\n    var i, length;\n    if (isArrayLike(obj)) {\n      for (i = 0, length = obj.length; i < length; i++) {\n        iteratee(obj[i], i, obj);\n      }\n    } else {\n      var keys = _.keys(obj);\n      for (i = 0, length = keys.length; i < length; i++) {\n        iteratee(obj[keys[i]], keys[i], obj);\n      }\n    }\n    return obj;\n  };\n\n  // Return the results of applying the iteratee to each element.\n  _.map = _.collect = function(obj, iteratee, context) {\n    iteratee = cb(iteratee, context);\n    var keys = !isArrayLike(obj) && _.keys(obj),\n        length = (keys || obj).length,\n        results = Array(length);\n    for (var index = 0; index < length; index++) {\n      var currentKey = keys ? keys[index] : index;\n      results[index] = iteratee(obj[currentKey], currentKey, obj);\n    }\n    return results;\n  };\n\n  // Create a reducing function iterating left or right.\n  var createReduce = function(dir) {\n    // Wrap code that reassigns argument variables in a separate function than\n    // the one that accesses `arguments.length` to avoid a perf hit. (#1991)\n    var reducer = function(obj, iteratee, memo, initial) {\n      var keys = !isArrayLike(obj) && _.keys(obj),\n          length = (keys || obj).length,\n          index = dir > 0 ? 0 : length - 1;\n      if (!initial) {\n        memo = obj[keys ? keys[index] : index];\n        index += dir;\n      }\n      for (; index >= 0 && index < length; index += dir) {\n        var currentKey = keys ? keys[index] : index;\n        memo = iteratee(memo, obj[currentKey], currentKey, obj);\n      }\n      return memo;\n    };\n\n    return function(obj, iteratee, memo, context) {\n      var initial = arguments.length >= 3;\n      return reducer(obj, optimizeCb(iteratee, context, 4), memo, initial);\n    };\n  };\n\n  // **Reduce** builds up a single result from a list of values, aka `inject`,\n  // or `foldl`.\n  _.reduce = _.foldl = _.inject = createReduce(1);\n\n  // The right-associative version of reduce, also known as `foldr`.\n  _.reduceRight = _.foldr = createReduce(-1);\n\n  // Return the first value which passes a truth test. Aliased as `detect`.\n  _.find = _.detect = function(obj, predicate, context) {\n    var keyFinder = isArrayLike(obj) ? _.findIndex : _.findKey;\n    var key = keyFinder(obj, predicate, context);\n    if (key !== void 0 && key !== -1) return obj[key];\n  };\n\n  // Return all the elements that pass a truth test.\n  // Aliased as `select`.\n  _.filter = _.select = function(obj, predicate, context) {\n    var results = [];\n    predicate = cb(predicate, context);\n    _.each(obj, function(value, index, list) {\n      if (predicate(value, index, list)) results.push(value);\n    });\n    return results;\n  };\n\n  // Return all the elements for which a truth test fails.\n  _.reject = function(obj, predicate, context) {\n    return _.filter(obj, _.negate(cb(predicate)), context);\n  };\n\n  // Determine whether all of the elements match a truth test.\n  // Aliased as `all`.\n  _.every = _.all = function(obj, predicate, context) {\n    predicate = cb(predicate, context);\n    var keys = !isArrayLike(obj) && _.keys(obj),\n        length = (keys || obj).length;\n    for (var index = 0; index < length; index++) {\n      var currentKey = keys ? keys[index] : index;\n      if (!predicate(obj[currentKey], currentKey, obj)) return false;\n    }\n    return true;\n  };\n\n  // Determine if at least one element in the object matches a truth test.\n  // Aliased as `any`.\n  _.some = _.any = function(obj, predicate, context) {\n    predicate = cb(predicate, context);\n    var keys = !isArrayLike(obj) && _.keys(obj),\n        length = (keys || obj).length;\n    for (var index = 0; index < length; index++) {\n      var currentKey = keys ? keys[index] : index;\n      if (predicate(obj[currentKey], currentKey, obj)) return true;\n    }\n    return false;\n  };\n\n  // Determine if the array or object contains a given item (using `===`).\n  // Aliased as `includes` and `include`.\n  _.contains = _.includes = _.include = function(obj, item, fromIndex, guard) {\n    if (!isArrayLike(obj)) obj = _.values(obj);\n    if (typeof fromIndex != 'number' || guard) fromIndex = 0;\n    return _.indexOf(obj, item, fromIndex) >= 0;\n  };\n\n  // Invoke a method (with arguments) on every item in a collection.\n  _.invoke = restArguments(function(obj, path, args) {\n    var contextPath, func;\n    if (_.isFunction(path)) {\n      func = path;\n    } else if (_.isArray(path)) {\n      contextPath = path.slice(0, -1);\n      path = path[path.length - 1];\n    }\n    return _.map(obj, function(context) {\n      var method = func;\n      if (!method) {\n        if (contextPath && contextPath.length) {\n          context = deepGet(context, contextPath);\n        }\n        if (context == null) return void 0;\n        method = context[path];\n      }\n      return method == null ? method : method.apply(context, args);\n    });\n  });\n\n  // Convenience version of a common use case of `map`: fetching a property.\n  _.pluck = function(obj, key) {\n    return _.map(obj, _.property(key));\n  };\n\n  // Convenience version of a common use case of `filter`: selecting only objects\n  // containing specific `key:value` pairs.\n  _.where = function(obj, attrs) {\n    return _.filter(obj, _.matcher(attrs));\n  };\n\n  // Convenience version of a common use case of `find`: getting the first object\n  // containing specific `key:value` pairs.\n  _.findWhere = function(obj, attrs) {\n    return _.find(obj, _.matcher(attrs));\n  };\n\n  // Return the maximum element (or element-based computation).\n  _.max = function(obj, iteratee, context) {\n    var result = -Infinity, lastComputed = -Infinity,\n        value, computed;\n    if (iteratee == null || typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null) {\n      obj = isArrayLike(obj) ? obj : _.values(obj);\n      for (var i = 0, length = obj.length; i < length; i++) {\n        value = obj[i];\n        if (value != null && value > result) {\n          result = value;\n        }\n      }\n    } else {\n      iteratee = cb(iteratee, context);\n      _.each(obj, function(v, index, list) {\n        computed = iteratee(v, index, list);\n        if (computed > lastComputed || computed === -Infinity && result === -Infinity) {\n          result = v;\n          lastComputed = computed;\n        }\n      });\n    }\n    return result;\n  };\n\n  // Return the minimum element (or element-based computation).\n  _.min = function(obj, iteratee, context) {\n    var result = Infinity, lastComputed = Infinity,\n        value, computed;\n    if (iteratee == null || typeof iteratee == 'number' && typeof obj[0] != 'object' && obj != null) {\n      obj = isArrayLike(obj) ? obj : _.values(obj);\n      for (var i = 0, length = obj.length; i < length; i++) {\n        value = obj[i];\n        if (value != null && value < result) {\n          result = value;\n        }\n      }\n    } else {\n      iteratee = cb(iteratee, context);\n      _.each(obj, function(v, index, list) {\n        computed = iteratee(v, index, list);\n        if (computed < lastComputed || computed === Infinity && result === Infinity) {\n          result = v;\n          lastComputed = computed;\n        }\n      });\n    }\n    return result;\n  };\n\n  // Shuffle a collection.\n  _.shuffle = function(obj) {\n    return _.sample(obj, Infinity);\n  };\n\n  // Sample **n** random values from a collection using the modern version of the\n  // [Fisher-Yates shuffle](http://en.wikipedia.org/wiki/Fisher–Yates_shuffle).\n  // If **n** is not specified, returns a single random element.\n  // The internal `guard` argument allows it to work with `map`.\n  _.sample = function(obj, n, guard) {\n    if (n == null || guard) {\n      if (!isArrayLike(obj)) obj = _.values(obj);\n      return obj[_.random(obj.length - 1)];\n    }\n    var sample = isArrayLike(obj) ? _.clone(obj) : _.values(obj);\n    var length = getLength(sample);\n    n = Math.max(Math.min(n, length), 0);\n    var last = length - 1;\n    for (var index = 0; index < n; index++) {\n      var rand = _.random(index, last);\n      var temp = sample[index];\n      sample[index] = sample[rand];\n      sample[rand] = temp;\n    }\n    return sample.slice(0, n);\n  };\n\n  // Sort the object's values by a criterion produced by an iteratee.\n  _.sortBy = function(obj, iteratee, context) {\n    var index = 0;\n    iteratee = cb(iteratee, context);\n    return _.pluck(_.map(obj, function(value, key, list) {\n      return {\n        value: value,\n        index: index++,\n        criteria: iteratee(value, key, list)\n      };\n    }).sort(function(left, right) {\n      var a = left.criteria;\n      var b = right.criteria;\n      if (a !== b) {\n        if (a > b || a === void 0) return 1;\n        if (a < b || b === void 0) return -1;\n      }\n      return left.index - right.index;\n    }), 'value');\n  };\n\n  // An internal function used for aggregate \"group by\" operations.\n  var group = function(behavior, partition) {\n    return function(obj, iteratee, context) {\n      var result = partition ? [[], []] : {};\n      iteratee = cb(iteratee, context);\n      _.each(obj, function(value, index) {\n        var key = iteratee(value, index, obj);\n        behavior(result, value, key);\n      });\n      return result;\n    };\n  };\n\n  // Groups the object's values by a criterion. Pass either a string attribute\n  // to group by, or a function that returns the criterion.\n  _.groupBy = group(function(result, value, key) {\n    if (has(result, key)) result[key].push(value); else result[key] = [value];\n  });\n\n  // Indexes the object's values by a criterion, similar to `groupBy`, but for\n  // when you know that your index values will be unique.\n  _.indexBy = group(function(result, value, key) {\n    result[key] = value;\n  });\n\n  // Counts instances of an object that group by a certain criterion. Pass\n  // either a string attribute to count by, or a function that returns the\n  // criterion.\n  _.countBy = group(function(result, value, key) {\n    if (has(result, key)) result[key]++; else result[key] = 1;\n  });\n\n  var reStrSymbol = /[^\\ud800-\\udfff]|[\\ud800-\\udbff][\\udc00-\\udfff]|[\\ud800-\\udfff]/g;\n  // Safely create a real, live array from anything iterable.\n  _.toArray = function(obj) {\n    if (!obj) return [];\n    if (_.isArray(obj)) return slice.call(obj);\n    if (_.isString(obj)) {\n      // Keep surrogate pair characters together\n      return obj.match(reStrSymbol);\n    }\n    if (isArrayLike(obj)) return _.map(obj, _.identity);\n    return _.values(obj);\n  };\n\n  // Return the number of elements in an object.\n  _.size = function(obj) {\n    if (obj == null) return 0;\n    return isArrayLike(obj) ? obj.length : _.keys(obj).length;\n  };\n\n  // Split a collection into two arrays: one whose elements all satisfy the given\n  // predicate, and one whose elements all do not satisfy the predicate.\n  _.partition = group(function(result, value, pass) {\n    result[pass ? 0 : 1].push(value);\n  }, true);\n\n  // Array Functions\n  // ---------------\n\n  // Get the first element of an array. Passing **n** will return the first N\n  // values in the array. Aliased as `head` and `take`. The **guard** check\n  // allows it to work with `_.map`.\n  _.first = _.head = _.take = function(array, n, guard) {\n    if (array == null || array.length < 1) return n == null ? void 0 : [];\n    if (n == null || guard) return array[0];\n    return _.initial(array, array.length - n);\n  };\n\n  // Returns everything but the last entry of the array. Especially useful on\n  // the arguments object. Passing **n** will return all the values in\n  // the array, excluding the last N.\n  _.initial = function(array, n, guard) {\n    return slice.call(array, 0, Math.max(0, array.length - (n == null || guard ? 1 : n)));\n  };\n\n  // Get the last element of an array. Passing **n** will return the last N\n  // values in the array.\n  _.last = function(array, n, guard) {\n    if (array == null || array.length < 1) return n == null ? void 0 : [];\n    if (n == null || guard) return array[array.length - 1];\n    return _.rest(array, Math.max(0, array.length - n));\n  };\n\n  // Returns everything but the first entry of the array. Aliased as `tail` and `drop`.\n  // Especially useful on the arguments object. Passing an **n** will return\n  // the rest N values in the array.\n  _.rest = _.tail = _.drop = function(array, n, guard) {\n    return slice.call(array, n == null || guard ? 1 : n);\n  };\n\n  // Trim out all falsy values from an array.\n  _.compact = function(array) {\n    return _.filter(array, Boolean);\n  };\n\n  // Internal implementation of a recursive `flatten` function.\n  var flatten = function(input, shallow, strict, output) {\n    output = output || [];\n    var idx = output.length;\n    for (var i = 0, length = getLength(input); i < length; i++) {\n      var value = input[i];\n      if (isArrayLike(value) && (_.isArray(value) || _.isArguments(value))) {\n        // Flatten current level of array or arguments object.\n        if (shallow) {\n          var j = 0, len = value.length;\n          while (j < len) output[idx++] = value[j++];\n        } else {\n          flatten(value, shallow, strict, output);\n          idx = output.length;\n        }\n      } else if (!strict) {\n        output[idx++] = value;\n      }\n    }\n    return output;\n  };\n\n  // Flatten out an array, either recursively (by default), or just one level.\n  _.flatten = function(array, shallow) {\n    return flatten(array, shallow, false);\n  };\n\n  // Return a version of the array that does not contain the specified value(s).\n  _.without = restArguments(function(array, otherArrays) {\n    return _.difference(array, otherArrays);\n  });\n\n  // Produce a duplicate-free version of the array. If the array has already\n  // been sorted, you have the option of using a faster algorithm.\n  // The faster algorithm will not work with an iteratee if the iteratee\n  // is not a one-to-one function, so providing an iteratee will disable\n  // the faster algorithm.\n  // Aliased as `unique`.\n  _.uniq = _.unique = function(array, isSorted, iteratee, context) {\n    if (!_.isBoolean(isSorted)) {\n      context = iteratee;\n      iteratee = isSorted;\n      isSorted = false;\n    }\n    if (iteratee != null) iteratee = cb(iteratee, context);\n    var result = [];\n    var seen = [];\n    for (var i = 0, length = getLength(array); i < length; i++) {\n      var value = array[i],\n          computed = iteratee ? iteratee(value, i, array) : value;\n      if (isSorted && !iteratee) {\n        if (!i || seen !== computed) result.push(value);\n        seen = computed;\n      } else if (iteratee) {\n        if (!_.contains(seen, computed)) {\n          seen.push(computed);\n          result.push(value);\n        }\n      } else if (!_.contains(result, value)) {\n        result.push(value);\n      }\n    }\n    return result;\n  };\n\n  // Produce an array that contains the union: each distinct element from all of\n  // the passed-in arrays.\n  _.union = restArguments(function(arrays) {\n    return _.uniq(flatten(arrays, true, true));\n  });\n\n  // Produce an array that contains every item shared between all the\n  // passed-in arrays.\n  _.intersection = function(array) {\n    var result = [];\n    var argsLength = arguments.length;\n    for (var i = 0, length = getLength(array); i < length; i++) {\n      var item = array[i];\n      if (_.contains(result, item)) continue;\n      var j;\n      for (j = 1; j < argsLength; j++) {\n        if (!_.contains(arguments[j], item)) break;\n      }\n      if (j === argsLength) result.push(item);\n    }\n    return result;\n  };\n\n  // Take the difference between one array and a number of other arrays.\n  // Only the elements present in just the first array will remain.\n  _.difference = restArguments(function(array, rest) {\n    rest = flatten(rest, true, true);\n    return _.filter(array, function(value){\n      return !_.contains(rest, value);\n    });\n  });\n\n  // Complement of _.zip. Unzip accepts an array of arrays and groups\n  // each array's elements on shared indices.\n  _.unzip = function(array) {\n    var length = array && _.max(array, getLength).length || 0;\n    var result = Array(length);\n\n    for (var index = 0; index < length; index++) {\n      result[index] = _.pluck(array, index);\n    }\n    return result;\n  };\n\n  // Zip together multiple lists into a single array -- elements that share\n  // an index go together.\n  _.zip = restArguments(_.unzip);\n\n  // Converts lists into objects. Pass either a single array of `[key, value]`\n  // pairs, or two parallel arrays of the same length -- one of keys, and one of\n  // the corresponding values. Passing by pairs is the reverse of _.pairs.\n  _.object = function(list, values) {\n    var result = {};\n    for (var i = 0, length = getLength(list); i < length; i++) {\n      if (values) {\n        result[list[i]] = values[i];\n      } else {\n        result[list[i][0]] = list[i][1];\n      }\n    }\n    return result;\n  };\n\n  // Generator function to create the findIndex and findLastIndex functions.\n  var createPredicateIndexFinder = function(dir) {\n    return function(array, predicate, context) {\n      predicate = cb(predicate, context);\n      var length = getLength(array);\n      var index = dir > 0 ? 0 : length - 1;\n      for (; index >= 0 && index < length; index += dir) {\n        if (predicate(array[index], index, array)) return index;\n      }\n      return -1;\n    };\n  };\n\n  // Returns the first index on an array-like that passes a predicate test.\n  _.findIndex = createPredicateIndexFinder(1);\n  _.findLastIndex = createPredicateIndexFinder(-1);\n\n  // Use a comparator function to figure out the smallest index at which\n  // an object should be inserted so as to maintain order. Uses binary search.\n  _.sortedIndex = function(array, obj, iteratee, context) {\n    iteratee = cb(iteratee, context, 1);\n    var value = iteratee(obj);\n    var low = 0, high = getLength(array);\n    while (low < high) {\n      var mid = Math.floor((low + high) / 2);\n      if (iteratee(array[mid]) < value) low = mid + 1; else high = mid;\n    }\n    return low;\n  };\n\n  // Generator function to create the indexOf and lastIndexOf functions.\n  var createIndexFinder = function(dir, predicateFind, sortedIndex) {\n    return function(array, item, idx) {\n      var i = 0, length = getLength(array);\n      if (typeof idx == 'number') {\n        if (dir > 0) {\n          i = idx >= 0 ? idx : Math.max(idx + length, i);\n        } else {\n          length = idx >= 0 ? Math.min(idx + 1, length) : idx + length + 1;\n        }\n      } else if (sortedIndex && idx && length) {\n        idx = sortedIndex(array, item);\n        return array[idx] === item ? idx : -1;\n      }\n      if (item !== item) {\n        idx = predicateFind(slice.call(array, i, length), _.isNaN);\n        return idx >= 0 ? idx + i : -1;\n      }\n      for (idx = dir > 0 ? i : length - 1; idx >= 0 && idx < length; idx += dir) {\n        if (array[idx] === item) return idx;\n      }\n      return -1;\n    };\n  };\n\n  // Return the position of the first occurrence of an item in an array,\n  // or -1 if the item is not included in the array.\n  // If the array is large and already in sort order, pass `true`\n  // for **isSorted** to use binary search.\n  _.indexOf = createIndexFinder(1, _.findIndex, _.sortedIndex);\n  _.lastIndexOf = createIndexFinder(-1, _.findLastIndex);\n\n  // Generate an integer Array containing an arithmetic progression. A port of\n  // the native Python `range()` function. See\n  // [the Python documentation](http://docs.python.org/library/functions.html#range).\n  _.range = function(start, stop, step) {\n    if (stop == null) {\n      stop = start || 0;\n      start = 0;\n    }\n    if (!step) {\n      step = stop < start ? -1 : 1;\n    }\n\n    var length = Math.max(Math.ceil((stop - start) / step), 0);\n    var range = Array(length);\n\n    for (var idx = 0; idx < length; idx++, start += step) {\n      range[idx] = start;\n    }\n\n    return range;\n  };\n\n  // Chunk a single array into multiple arrays, each containing `count` or fewer\n  // items.\n  _.chunk = function(array, count) {\n    if (count == null || count < 1) return [];\n    var result = [];\n    var i = 0, length = array.length;\n    while (i < length) {\n      result.push(slice.call(array, i, i += count));\n    }\n    return result;\n  };\n\n  // Function (ahem) Functions\n  // ------------------\n\n  // Determines whether to execute a function as a constructor\n  // or a normal function with the provided arguments.\n  var executeBound = function(sourceFunc, boundFunc, context, callingContext, args) {\n    if (!(callingContext instanceof boundFunc)) return sourceFunc.apply(context, args);\n    var self = baseCreate(sourceFunc.prototype);\n    var result = sourceFunc.apply(self, args);\n    if (_.isObject(result)) return result;\n    return self;\n  };\n\n  // Create a function bound to a given object (assigning `this`, and arguments,\n  // optionally). Delegates to **ECMAScript 5**'s native `Function.bind` if\n  // available.\n  _.bind = restArguments(function(func, context, args) {\n    if (!_.isFunction(func)) throw new TypeError('Bind must be called on a function');\n    var bound = restArguments(function(callArgs) {\n      return executeBound(func, bound, context, this, args.concat(callArgs));\n    });\n    return bound;\n  });\n\n  // Partially apply a function by creating a version that has had some of its\n  // arguments pre-filled, without changing its dynamic `this` context. _ acts\n  // as a placeholder by default, allowing any combination of arguments to be\n  // pre-filled. Set `_.partial.placeholder` for a custom placeholder argument.\n  _.partial = restArguments(function(func, boundArgs) {\n    var placeholder = _.partial.placeholder;\n    var bound = function() {\n      var position = 0, length = boundArgs.length;\n      var args = Array(length);\n      for (var i = 0; i < length; i++) {\n        args[i] = boundArgs[i] === placeholder ? arguments[position++] : boundArgs[i];\n      }\n      while (position < arguments.length) args.push(arguments[position++]);\n      return executeBound(func, bound, this, this, args);\n    };\n    return bound;\n  });\n\n  _.partial.placeholder = _;\n\n  // Bind a number of an object's methods to that object. Remaining arguments\n  // are the method names to be bound. Useful for ensuring that all callbacks\n  // defined on an object belong to it.\n  _.bindAll = restArguments(function(obj, keys) {\n    keys = flatten(keys, false, false);\n    var index = keys.length;\n    if (index < 1) throw new Error('bindAll must be passed function names');\n    while (index--) {\n      var key = keys[index];\n      obj[key] = _.bind(obj[key], obj);\n    }\n  });\n\n  // Memoize an expensive function by storing its results.\n  _.memoize = function(func, hasher) {\n    var memoize = function(key) {\n      var cache = memoize.cache;\n      var address = '' + (hasher ? hasher.apply(this, arguments) : key);\n      if (!has(cache, address)) cache[address] = func.apply(this, arguments);\n      return cache[address];\n    };\n    memoize.cache = {};\n    return memoize;\n  };\n\n  // Delays a function for the given number of milliseconds, and then calls\n  // it with the arguments supplied.\n  _.delay = restArguments(function(func, wait, args) {\n    return setTimeout(function() {\n      return func.apply(null, args);\n    }, wait);\n  });\n\n  // Defers a function, scheduling it to run after the current call stack has\n  // cleared.\n  _.defer = _.partial(_.delay, _, 1);\n\n  // Returns a function, that, when invoked, will only be triggered at most once\n  // during a given window of time. Normally, the throttled function will run\n  // as much as it can, without ever going more than once per `wait` duration;\n  // but if you'd like to disable the execution on the leading edge, pass\n  // `{leading: false}`. To disable execution on the trailing edge, ditto.\n  _.throttle = function(func, wait, options) {\n    var timeout, context, args, result;\n    var previous = 0;\n    if (!options) options = {};\n\n    var later = function() {\n      previous = options.leading === false ? 0 : _.now();\n      timeout = null;\n      result = func.apply(context, args);\n      if (!timeout) context = args = null;\n    };\n\n    var throttled = function() {\n      var now = _.now();\n      if (!previous && options.leading === false) previous = now;\n      var remaining = wait - (now - previous);\n      context = this;\n      args = arguments;\n      if (remaining <= 0 || remaining > wait) {\n        if (timeout) {\n          clearTimeout(timeout);\n          timeout = null;\n        }\n        previous = now;\n        result = func.apply(context, args);\n        if (!timeout) context = args = null;\n      } else if (!timeout && options.trailing !== false) {\n        timeout = setTimeout(later, remaining);\n      }\n      return result;\n    };\n\n    throttled.cancel = function() {\n      clearTimeout(timeout);\n      previous = 0;\n      timeout = context = args = null;\n    };\n\n    return throttled;\n  };\n\n  // Returns a function, that, as long as it continues to be invoked, will not\n  // be triggered. The function will be called after it stops being called for\n  // N milliseconds. If `immediate` is passed, trigger the function on the\n  // leading edge, instead of the trailing.\n  _.debounce = function(func, wait, immediate) {\n    var timeout, result;\n\n    var later = function(context, args) {\n      timeout = null;\n      if (args) result = func.apply(context, args);\n    };\n\n    var debounced = restArguments(function(args) {\n      if (timeout) clearTimeout(timeout);\n      if (immediate) {\n        var callNow = !timeout;\n        timeout = setTimeout(later, wait);\n        if (callNow) result = func.apply(this, args);\n      } else {\n        timeout = _.delay(later, wait, this, args);\n      }\n\n      return result;\n    });\n\n    debounced.cancel = function() {\n      clearTimeout(timeout);\n      timeout = null;\n    };\n\n    return debounced;\n  };\n\n  // Returns the first function passed as an argument to the second,\n  // allowing you to adjust arguments, run code before and after, and\n  // conditionally execute the original function.\n  _.wrap = function(func, wrapper) {\n    return _.partial(wrapper, func);\n  };\n\n  // Returns a negated version of the passed-in predicate.\n  _.negate = function(predicate) {\n    return function() {\n      return !predicate.apply(this, arguments);\n    };\n  };\n\n  // Returns a function that is the composition of a list of functions, each\n  // consuming the return value of the function that follows.\n  _.compose = function() {\n    var args = arguments;\n    var start = args.length - 1;\n    return function() {\n      var i = start;\n      var result = args[start].apply(this, arguments);\n      while (i--) result = args[i].call(this, result);\n      return result;\n    };\n  };\n\n  // Returns a function that will only be executed on and after the Nth call.\n  _.after = function(times, func) {\n    return function() {\n      if (--times < 1) {\n        return func.apply(this, arguments);\n      }\n    };\n  };\n\n  // Returns a function that will only be executed up to (but not including) the Nth call.\n  _.before = function(times, func) {\n    var memo;\n    return function() {\n      if (--times > 0) {\n        memo = func.apply(this, arguments);\n      }\n      if (times <= 1) func = null;\n      return memo;\n    };\n  };\n\n  // Returns a function that will be executed at most one time, no matter how\n  // often you call it. Useful for lazy initialization.\n  _.once = _.partial(_.before, 2);\n\n  _.restArguments = restArguments;\n\n  // Object Functions\n  // ----------------\n\n  // Keys in IE < 9 that won't be iterated by `for key in ...` and thus missed.\n  var hasEnumBug = !{toString: null}.propertyIsEnumerable('toString');\n  var nonEnumerableProps = ['valueOf', 'isPrototypeOf', 'toString',\n    'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString'];\n\n  var collectNonEnumProps = function(obj, keys) {\n    var nonEnumIdx = nonEnumerableProps.length;\n    var constructor = obj.constructor;\n    var proto = _.isFunction(constructor) && constructor.prototype || ObjProto;\n\n    // Constructor is a special case.\n    var prop = 'constructor';\n    if (has(obj, prop) && !_.contains(keys, prop)) keys.push(prop);\n\n    while (nonEnumIdx--) {\n      prop = nonEnumerableProps[nonEnumIdx];\n      if (prop in obj && obj[prop] !== proto[prop] && !_.contains(keys, prop)) {\n        keys.push(prop);\n      }\n    }\n  };\n\n  // Retrieve the names of an object's own properties.\n  // Delegates to **ECMAScript 5**'s native `Object.keys`.\n  _.keys = function(obj) {\n    if (!_.isObject(obj)) return [];\n    if (nativeKeys) return nativeKeys(obj);\n    var keys = [];\n    for (var key in obj) if (has(obj, key)) keys.push(key);\n    // Ahem, IE < 9.\n    if (hasEnumBug) collectNonEnumProps(obj, keys);\n    return keys;\n  };\n\n  // Retrieve all the property names of an object.\n  _.allKeys = function(obj) {\n    if (!_.isObject(obj)) return [];\n    var keys = [];\n    for (var key in obj) keys.push(key);\n    // Ahem, IE < 9.\n    if (hasEnumBug) collectNonEnumProps(obj, keys);\n    return keys;\n  };\n\n  // Retrieve the values of an object's properties.\n  _.values = function(obj) {\n    var keys = _.keys(obj);\n    var length = keys.length;\n    var values = Array(length);\n    for (var i = 0; i < length; i++) {\n      values[i] = obj[keys[i]];\n    }\n    return values;\n  };\n\n  // Returns the results of applying the iteratee to each element of the object.\n  // In contrast to _.map it returns an object.\n  _.mapObject = function(obj, iteratee, context) {\n    iteratee = cb(iteratee, context);\n    var keys = _.keys(obj),\n        length = keys.length,\n        results = {};\n    for (var index = 0; index < length; index++) {\n      var currentKey = keys[index];\n      results[currentKey] = iteratee(obj[currentKey], currentKey, obj);\n    }\n    return results;\n  };\n\n  // Convert an object into a list of `[key, value]` pairs.\n  // The opposite of _.object.\n  _.pairs = function(obj) {\n    var keys = _.keys(obj);\n    var length = keys.length;\n    var pairs = Array(length);\n    for (var i = 0; i < length; i++) {\n      pairs[i] = [keys[i], obj[keys[i]]];\n    }\n    return pairs;\n  };\n\n  // Invert the keys and values of an object. The values must be serializable.\n  _.invert = function(obj) {\n    var result = {};\n    var keys = _.keys(obj);\n    for (var i = 0, length = keys.length; i < length; i++) {\n      result[obj[keys[i]]] = keys[i];\n    }\n    return result;\n  };\n\n  // Return a sorted list of the function names available on the object.\n  // Aliased as `methods`.\n  _.functions = _.methods = function(obj) {\n    var names = [];\n    for (var key in obj) {\n      if (_.isFunction(obj[key])) names.push(key);\n    }\n    return names.sort();\n  };\n\n  // An internal function for creating assigner functions.\n  var createAssigner = function(keysFunc, defaults) {\n    return function(obj) {\n      var length = arguments.length;\n      if (defaults) obj = Object(obj);\n      if (length < 2 || obj == null) return obj;\n      for (var index = 1; index < length; index++) {\n        var source = arguments[index],\n            keys = keysFunc(source),\n            l = keys.length;\n        for (var i = 0; i < l; i++) {\n          var key = keys[i];\n          if (!defaults || obj[key] === void 0) obj[key] = source[key];\n        }\n      }\n      return obj;\n    };\n  };\n\n  // Extend a given object with all the properties in passed-in object(s).\n  _.extend = createAssigner(_.allKeys);\n\n  // Assigns a given object with all the own properties in the passed-in object(s).\n  // (https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object/assign)\n  _.extendOwn = _.assign = createAssigner(_.keys);\n\n  // Returns the first key on an object that passes a predicate test.\n  _.findKey = function(obj, predicate, context) {\n    predicate = cb(predicate, context);\n    var keys = _.keys(obj), key;\n    for (var i = 0, length = keys.length; i < length; i++) {\n      key = keys[i];\n      if (predicate(obj[key], key, obj)) return key;\n    }\n  };\n\n  // Internal pick helper function to determine if `obj` has key `key`.\n  var keyInObj = function(value, key, obj) {\n    return key in obj;\n  };\n\n  // Return a copy of the object only containing the whitelisted properties.\n  _.pick = restArguments(function(obj, keys) {\n    var result = {}, iteratee = keys[0];\n    if (obj == null) return result;\n    if (_.isFunction(iteratee)) {\n      if (keys.length > 1) iteratee = optimizeCb(iteratee, keys[1]);\n      keys = _.allKeys(obj);\n    } else {\n      iteratee = keyInObj;\n      keys = flatten(keys, false, false);\n      obj = Object(obj);\n    }\n    for (var i = 0, length = keys.length; i < length; i++) {\n      var key = keys[i];\n      var value = obj[key];\n      if (iteratee(value, key, obj)) result[key] = value;\n    }\n    return result;\n  });\n\n  // Return a copy of the object without the blacklisted properties.\n  _.omit = restArguments(function(obj, keys) {\n    var iteratee = keys[0], context;\n    if (_.isFunction(iteratee)) {\n      iteratee = _.negate(iteratee);\n      if (keys.length > 1) context = keys[1];\n    } else {\n      keys = _.map(flatten(keys, false, false), String);\n      iteratee = function(value, key) {\n        return !_.contains(keys, key);\n      };\n    }\n    return _.pick(obj, iteratee, context);\n  });\n\n  // Fill in a given object with default properties.\n  _.defaults = createAssigner(_.allKeys, true);\n\n  // Creates an object that inherits from the given prototype object.\n  // If additional properties are provided then they will be added to the\n  // created object.\n  _.create = function(prototype, props) {\n    var result = baseCreate(prototype);\n    if (props) _.extendOwn(result, props);\n    return result;\n  };\n\n  // Create a (shallow-cloned) duplicate of an object.\n  _.clone = function(obj) {\n    if (!_.isObject(obj)) return obj;\n    return _.isArray(obj) ? obj.slice() : _.extend({}, obj);\n  };\n\n  // Invokes interceptor with the obj, and then returns obj.\n  // The primary purpose of this method is to \"tap into\" a method chain, in\n  // order to perform operations on intermediate results within the chain.\n  _.tap = function(obj, interceptor) {\n    interceptor(obj);\n    return obj;\n  };\n\n  // Returns whether an object has a given set of `key:value` pairs.\n  _.isMatch = function(object, attrs) {\n    var keys = _.keys(attrs), length = keys.length;\n    if (object == null) return !length;\n    var obj = Object(object);\n    for (var i = 0; i < length; i++) {\n      var key = keys[i];\n      if (attrs[key] !== obj[key] || !(key in obj)) return false;\n    }\n    return true;\n  };\n\n\n  // Internal recursive comparison function for `isEqual`.\n  var eq, deepEq;\n  eq = function(a, b, aStack, bStack) {\n    // Identical objects are equal. `0 === -0`, but they aren't identical.\n    // See the [Harmony `egal` proposal](http://wiki.ecmascript.org/doku.php?id=harmony:egal).\n    if (a === b) return a !== 0 || 1 / a === 1 / b;\n    // `null` or `undefined` only equal to itself (strict comparison).\n    if (a == null || b == null) return false;\n    // `NaN`s are equivalent, but non-reflexive.\n    if (a !== a) return b !== b;\n    // Exhaust primitive checks\n    var type = typeof a;\n    if (type !== 'function' && type !== 'object' && typeof b != 'object') return false;\n    return deepEq(a, b, aStack, bStack);\n  };\n\n  // Internal recursive comparison function for `isEqual`.\n  deepEq = function(a, b, aStack, bStack) {\n    // Unwrap any wrapped objects.\n    if (a instanceof _) a = a._wrapped;\n    if (b instanceof _) b = b._wrapped;\n    // Compare `[[Class]]` names.\n    var className = toString.call(a);\n    if (className !== toString.call(b)) return false;\n    switch (className) {\n      // Strings, numbers, regular expressions, dates, and booleans are compared by value.\n      case '[object RegExp]':\n      // RegExps are coerced to strings for comparison (Note: '' + /a/i === '/a/i')\n      case '[object String]':\n        // Primitives and their corresponding object wrappers are equivalent; thus, `\"5\"` is\n        // equivalent to `new String(\"5\")`.\n        return '' + a === '' + b;\n      case '[object Number]':\n        // `NaN`s are equivalent, but non-reflexive.\n        // Object(NaN) is equivalent to NaN.\n        if (+a !== +a) return +b !== +b;\n        // An `egal` comparison is performed for other numeric values.\n        return +a === 0 ? 1 / +a === 1 / b : +a === +b;\n      case '[object Date]':\n      case '[object Boolean]':\n        // Coerce dates and booleans to numeric primitive values. Dates are compared by their\n        // millisecond representations. Note that invalid dates with millisecond representations\n        // of `NaN` are not equivalent.\n        return +a === +b;\n      case '[object Symbol]':\n        return SymbolProto.valueOf.call(a) === SymbolProto.valueOf.call(b);\n    }\n\n    var areArrays = className === '[object Array]';\n    if (!areArrays) {\n      if (typeof a != 'object' || typeof b != 'object') return false;\n\n      // Objects with different constructors are not equivalent, but `Object`s or `Array`s\n      // from different frames are.\n      var aCtor = a.constructor, bCtor = b.constructor;\n      if (aCtor !== bCtor && !(_.isFunction(aCtor) && aCtor instanceof aCtor &&\n                               _.isFunction(bCtor) && bCtor instanceof bCtor)\n                          && ('constructor' in a && 'constructor' in b)) {\n        return false;\n      }\n    }\n    // Assume equality for cyclic structures. The algorithm for detecting cyclic\n    // structures is adapted from ES 5.1 section 15.12.3, abstract operation `JO`.\n\n    // Initializing stack of traversed objects.\n    // It's done here since we only need them for objects and arrays comparison.\n    aStack = aStack || [];\n    bStack = bStack || [];\n    var length = aStack.length;\n    while (length--) {\n      // Linear search. Performance is inversely proportional to the number of\n      // unique nested structures.\n      if (aStack[length] === a) return bStack[length] === b;\n    }\n\n    // Add the first object to the stack of traversed objects.\n    aStack.push(a);\n    bStack.push(b);\n\n    // Recursively compare objects and arrays.\n    if (areArrays) {\n      // Compare array lengths to determine if a deep comparison is necessary.\n      length = a.length;\n      if (length !== b.length) return false;\n      // Deep compare the contents, ignoring non-numeric properties.\n      while (length--) {\n        if (!eq(a[length], b[length], aStack, bStack)) return false;\n      }\n    } else {\n      // Deep compare objects.\n      var keys = _.keys(a), key;\n      length = keys.length;\n      // Ensure that both objects contain the same number of properties before comparing deep equality.\n      if (_.keys(b).length !== length) return false;\n      while (length--) {\n        // Deep compare each member\n        key = keys[length];\n        if (!(has(b, key) && eq(a[key], b[key], aStack, bStack))) return false;\n      }\n    }\n    // Remove the first object from the stack of traversed objects.\n    aStack.pop();\n    bStack.pop();\n    return true;\n  };\n\n  // Perform a deep comparison to check if two objects are equal.\n  _.isEqual = function(a, b) {\n    return eq(a, b);\n  };\n\n  // Is a given array, string, or object empty?\n  // An \"empty\" object has no enumerable own-properties.\n  _.isEmpty = function(obj) {\n    if (obj == null) return true;\n    if (isArrayLike(obj) && (_.isArray(obj) || _.isString(obj) || _.isArguments(obj))) return obj.length === 0;\n    return _.keys(obj).length === 0;\n  };\n\n  // Is a given value a DOM element?\n  _.isElement = function(obj) {\n    return !!(obj && obj.nodeType === 1);\n  };\n\n  // Is a given value an array?\n  // Delegates to ECMA5's native Array.isArray\n  _.isArray = nativeIsArray || function(obj) {\n    return toString.call(obj) === '[object Array]';\n  };\n\n  // Is a given variable an object?\n  _.isObject = function(obj) {\n    var type = typeof obj;\n    return type === 'function' || type === 'object' && !!obj;\n  };\n\n  // Add some isType methods: isArguments, isFunction, isString, isNumber, isDate, isRegExp, isError, isMap, isWeakMap, isSet, isWeakSet.\n  _.each(['Arguments', 'Function', 'String', 'Number', 'Date', 'RegExp', 'Error', 'Symbol', 'Map', 'WeakMap', 'Set', 'WeakSet'], function(name) {\n    _['is' + name] = function(obj) {\n      return toString.call(obj) === '[object ' + name + ']';\n    };\n  });\n\n  // Define a fallback version of the method in browsers (ahem, IE < 9), where\n  // there isn't any inspectable \"Arguments\" type.\n  if (!_.isArguments(arguments)) {\n    _.isArguments = function(obj) {\n      return has(obj, 'callee');\n    };\n  }\n\n  // Optimize `isFunction` if appropriate. Work around some typeof bugs in old v8,\n  // IE 11 (#1621), Safari 8 (#1929), and PhantomJS (#2236).\n  var nodelist = root.document && root.document.childNodes;\n  if (typeof /./ != 'function' && typeof Int8Array != 'object' && typeof nodelist != 'function') {\n    _.isFunction = function(obj) {\n      return typeof obj == 'function' || false;\n    };\n  }\n\n  // Is a given object a finite number?\n  _.isFinite = function(obj) {\n    return !_.isSymbol(obj) && isFinite(obj) && !isNaN(parseFloat(obj));\n  };\n\n  // Is the given value `NaN`?\n  _.isNaN = function(obj) {\n    return _.isNumber(obj) && isNaN(obj);\n  };\n\n  // Is a given value a boolean?\n  _.isBoolean = function(obj) {\n    return obj === true || obj === false || toString.call(obj) === '[object Boolean]';\n  };\n\n  // Is a given value equal to null?\n  _.isNull = function(obj) {\n    return obj === null;\n  };\n\n  // Is a given variable undefined?\n  _.isUndefined = function(obj) {\n    return obj === void 0;\n  };\n\n  // Shortcut function for checking if an object has a given property directly\n  // on itself (in other words, not on a prototype).\n  _.has = function(obj, path) {\n    if (!_.isArray(path)) {\n      return has(obj, path);\n    }\n    var length = path.length;\n    for (var i = 0; i < length; i++) {\n      var key = path[i];\n      if (obj == null || !hasOwnProperty.call(obj, key)) {\n        return false;\n      }\n      obj = obj[key];\n    }\n    return !!length;\n  };\n\n  // Utility Functions\n  // -----------------\n\n  // Run Underscore.js in *noConflict* mode, returning the `_` variable to its\n  // previous owner. Returns a reference to the Underscore object.\n  _.noConflict = function() {\n    root._ = previousUnderscore;\n    return this;\n  };\n\n  // Keep the identity function around for default iteratees.\n  _.identity = function(value) {\n    return value;\n  };\n\n  // Predicate-generating functions. Often useful outside of Underscore.\n  _.constant = function(value) {\n    return function() {\n      return value;\n    };\n  };\n\n  _.noop = function(){};\n\n  // Creates a function that, when passed an object, will traverse that object’s\n  // properties down the given `path`, specified as an array of keys or indexes.\n  _.property = function(path) {\n    if (!_.isArray(path)) {\n      return shallowProperty(path);\n    }\n    return function(obj) {\n      return deepGet(obj, path);\n    };\n  };\n\n  // Generates a function for a given object that returns a given property.\n  _.propertyOf = function(obj) {\n    if (obj == null) {\n      return function(){};\n    }\n    return function(path) {\n      return !_.isArray(path) ? obj[path] : deepGet(obj, path);\n    };\n  };\n\n  // Returns a predicate for checking whether an object has a given set of\n  // `key:value` pairs.\n  _.matcher = _.matches = function(attrs) {\n    attrs = _.extendOwn({}, attrs);\n    return function(obj) {\n      return _.isMatch(obj, attrs);\n    };\n  };\n\n  // Run a function **n** times.\n  _.times = function(n, iteratee, context) {\n    var accum = Array(Math.max(0, n));\n    iteratee = optimizeCb(iteratee, context, 1);\n    for (var i = 0; i < n; i++) accum[i] = iteratee(i);\n    return accum;\n  };\n\n  // Return a random integer between min and max (inclusive).\n  _.random = function(min, max) {\n    if (max == null) {\n      max = min;\n      min = 0;\n    }\n    return min + Math.floor(Math.random() * (max - min + 1));\n  };\n\n  // A (possibly faster) way to get the current timestamp as an integer.\n  _.now = Date.now || function() {\n    return new Date().getTime();\n  };\n\n  // List of HTML entities for escaping.\n  var escapeMap = {\n    '&': '&amp;',\n    '<': '&lt;',\n    '>': '&gt;',\n    '\"': '&quot;',\n    \"'\": '&#x27;',\n    '`': '&#x60;'\n  };\n  var unescapeMap = _.invert(escapeMap);\n\n  // Functions for escaping and unescaping strings to/from HTML interpolation.\n  var createEscaper = function(map) {\n    var escaper = function(match) {\n      return map[match];\n    };\n    // Regexes for identifying a key that needs to be escaped.\n    var source = '(?:' + _.keys(map).join('|') + ')';\n    var testRegexp = RegExp(source);\n    var replaceRegexp = RegExp(source, 'g');\n    return function(string) {\n      string = string == null ? '' : '' + string;\n      return testRegexp.test(string) ? string.replace(replaceRegexp, escaper) : string;\n    };\n  };\n  _.escape = createEscaper(escapeMap);\n  _.unescape = createEscaper(unescapeMap);\n\n  // Traverses the children of `obj` along `path`. If a child is a function, it\n  // is invoked with its parent as context. Returns the value of the final\n  // child, or `fallback` if any child is undefined.\n  _.result = function(obj, path, fallback) {\n    if (!_.isArray(path)) path = [path];\n    var length = path.length;\n    if (!length) {\n      return _.isFunction(fallback) ? fallback.call(obj) : fallback;\n    }\n    for (var i = 0; i < length; i++) {\n      var prop = obj == null ? void 0 : obj[path[i]];\n      if (prop === void 0) {\n        prop = fallback;\n        i = length; // Ensure we don't continue iterating.\n      }\n      obj = _.isFunction(prop) ? prop.call(obj) : prop;\n    }\n    return obj;\n  };\n\n  // Generate a unique integer id (unique within the entire client session).\n  // Useful for temporary DOM ids.\n  var idCounter = 0;\n  _.uniqueId = function(prefix) {\n    var id = ++idCounter + '';\n    return prefix ? prefix + id : id;\n  };\n\n  // By default, Underscore uses ERB-style template delimiters, change the\n  // following template settings to use alternative delimiters.\n  _.templateSettings = {\n    evaluate: /<%([\\s\\S]+?)%>/g,\n    interpolate: /<%=([\\s\\S]+?)%>/g,\n    escape: /<%-([\\s\\S]+?)%>/g\n  };\n\n  // When customizing `templateSettings`, if you don't want to define an\n  // interpolation, evaluation or escaping regex, we need one that is\n  // guaranteed not to match.\n  var noMatch = /(.)^/;\n\n  // Certain characters need to be escaped so that they can be put into a\n  // string literal.\n  var escapes = {\n    \"'\": \"'\",\n    '\\\\': '\\\\',\n    '\\r': 'r',\n    '\\n': 'n',\n    '\\u2028': 'u2028',\n    '\\u2029': 'u2029'\n  };\n\n  var escapeRegExp = /\\\\|'|\\r|\\n|\\u2028|\\u2029/g;\n\n  var escapeChar = function(match) {\n    return '\\\\' + escapes[match];\n  };\n\n  // JavaScript micro-templating, similar to John Resig's implementation.\n  // Underscore templating handles arbitrary delimiters, preserves whitespace,\n  // and correctly escapes quotes within interpolated code.\n  // NB: `oldSettings` only exists for backwards compatibility.\n  _.template = function(text, settings, oldSettings) {\n    if (!settings && oldSettings) settings = oldSettings;\n    settings = _.defaults({}, settings, _.templateSettings);\n\n    // Combine delimiters into one regular expression via alternation.\n    var matcher = RegExp([\n      (settings.escape || noMatch).source,\n      (settings.interpolate || noMatch).source,\n      (settings.evaluate || noMatch).source\n    ].join('|') + '|$', 'g');\n\n    // Compile the template source, escaping string literals appropriately.\n    var index = 0;\n    var source = \"__p+='\";\n    text.replace(matcher, function(match, escape, interpolate, evaluate, offset) {\n      source += text.slice(index, offset).replace(escapeRegExp, escapeChar);\n      index = offset + match.length;\n\n      if (escape) {\n        source += \"'+\\n((__t=(\" + escape + \"))==null?'':_.escape(__t))+\\n'\";\n      } else if (interpolate) {\n        source += \"'+\\n((__t=(\" + interpolate + \"))==null?'':__t)+\\n'\";\n      } else if (evaluate) {\n        source += \"';\\n\" + evaluate + \"\\n__p+='\";\n      }\n\n      // Adobe VMs need the match returned to produce the correct offset.\n      return match;\n    });\n    source += \"';\\n\";\n\n    // If a variable is not specified, place data values in local scope.\n    if (!settings.variable) source = 'with(obj||{}){\\n' + source + '}\\n';\n\n    source = \"var __t,__p='',__j=Array.prototype.join,\" +\n      \"print=function(){__p+=__j.call(arguments,'');};\\n\" +\n      source + 'return __p;\\n';\n\n    var render;\n    try {\n      render = new Function(settings.variable || 'obj', '_', source);\n    } catch (e) {\n      e.source = source;\n      throw e;\n    }\n\n    var template = function(data) {\n      return render.call(this, data, _);\n    };\n\n    // Provide the compiled source as a convenience for precompilation.\n    var argument = settings.variable || 'obj';\n    template.source = 'function(' + argument + '){\\n' + source + '}';\n\n    return template;\n  };\n\n  // Add a \"chain\" function. Start chaining a wrapped Underscore object.\n  _.chain = function(obj) {\n    var instance = _(obj);\n    instance._chain = true;\n    return instance;\n  };\n\n  // OOP\n  // ---------------\n  // If Underscore is called as a function, it returns a wrapped object that\n  // can be used OO-style. This wrapper holds altered versions of all the\n  // underscore functions. Wrapped objects may be chained.\n\n  // Helper function to continue chaining intermediate results.\n  var chainResult = function(instance, obj) {\n    return instance._chain ? _(obj).chain() : obj;\n  };\n\n  // Add your own custom functions to the Underscore object.\n  _.mixin = function(obj) {\n    _.each(_.functions(obj), function(name) {\n      var func = _[name] = obj[name];\n      _.prototype[name] = function() {\n        var args = [this._wrapped];\n        push.apply(args, arguments);\n        return chainResult(this, func.apply(_, args));\n      };\n    });\n    return _;\n  };\n\n  // Add all of the Underscore functions to the wrapper object.\n  _.mixin(_);\n\n  // Add all mutator Array functions to the wrapper.\n  _.each(['pop', 'push', 'reverse', 'shift', 'sort', 'splice', 'unshift'], function(name) {\n    var method = ArrayProto[name];\n    _.prototype[name] = function() {\n      var obj = this._wrapped;\n      method.apply(obj, arguments);\n      if ((name === 'shift' || name === 'splice') && obj.length === 0) delete obj[0];\n      return chainResult(this, obj);\n    };\n  });\n\n  // Add all accessor Array functions to the wrapper.\n  _.each(['concat', 'join', 'slice'], function(name) {\n    var method = ArrayProto[name];\n    _.prototype[name] = function() {\n      return chainResult(this, method.apply(this._wrapped, arguments));\n    };\n  });\n\n  // Extracts the result from a wrapped and chained object.\n  _.prototype.value = function() {\n    return this._wrapped;\n  };\n\n  // Provide unwrapping proxy for some methods used in engine operations\n  // such as arithmetic and JSON stringification.\n  _.prototype.valueOf = _.prototype.toJSON = _.prototype.value;\n\n  _.prototype.toString = function() {\n    return String(this._wrapped);\n  };\n\n  // AMD registration happens at the end for compatibility with AMD loaders\n  // that may not enforce next-turn semantics on modules. Even though general\n  // practice for AMD registration is to be anonymous, underscore registers\n  // as a named module because, like jQuery, it is a base library that is\n  // popular enough to be bundled in a third party lib, but not be part of\n  // an AMD load request. Those cases could generate an error when an\n  // anonymous define() is called outside of a loader request.\n  if (typeof define == 'function' && define.amd) {\n    define('underscore', [], function() {\n      return _;\n    });\n  }\n}());\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { toByteArray, fromByteArray } from 'base64-js';\nimport { UUID } from '@lumino/coreutils';\nimport _isEqual from 'lodash/isEqual';\nimport isPlainObject from 'lodash/isPlainObject';\n/**\n * Find all strings in the first argument that are not in the second.\n */\nexport function difference(a, b) {\n    return a.filter(function (v) { return b.indexOf(v) === -1; });\n}\n/**\n * Compare two objects deeply to see if they are equal.\n */\nexport function isEqual(a, b) {\n    return _isEqual(a, b);\n}\n/**\n * A polyfill for Object.assign\n *\n * This is from code that Typescript 2.4 generates for a polyfill.\n */\nexport var assign = Object.assign || function (t) {\n    for (var i = 1; i < arguments.length; i++) {\n        var s = arguments[i];\n        for (var p in s) {\n            if (Object.prototype.hasOwnProperty.call(s, p)) {\n                t[p] = s[p];\n            }\n        }\n    }\n    return t;\n};\n/**\n * Generate a UUID\n *\n * http://www.ietf.org/rfc/rfc4122.txt\n */\nexport function uuid() {\n    return UUID.uuid4();\n}\n/**\n * Wrappable Error class\n *\n * The Error class doesn't actually act on `this`.  Instead it always\n * returns a new instance of Error.  Here we capture that instance so we\n * can apply it's properties to `this`.\n */\nvar WrappedError = /** @class */ (function (_super) {\n    __extends(WrappedError, _super);\n    function WrappedError(message, error) {\n        var _this = _super.call(this, message) || this;\n        console.warn('WrappedError has been deprecated!');\n        // Keep a stack of the original error messages.\n        if (error instanceof WrappedError) {\n            _this.error_stack = error.error_stack;\n        }\n        else {\n            _this.error_stack = [error];\n        }\n        _this.error_stack.push(_this);\n        return _this;\n    }\n    return WrappedError;\n}(Error));\nexport { WrappedError };\n/**\n * Resolve a promiseful dictionary.\n * Returns a single Promise.\n */\nexport function resolvePromisesDict(d) {\n    var keys = Object.keys(d);\n    var values = [];\n    keys.forEach(function (key) {\n        values.push(d[key]);\n    });\n    return Promise.all(values).then(function (v) {\n        var d = {};\n        for (var i = 0; i < keys.length; i++) {\n            d[keys[i]] = v[i];\n        }\n        return d;\n    });\n}\n/**\n * Creates a wrappable Promise rejection function.\n *\n * Creates a function that logs an error message before rethrowing\n * the original error that caused the promise to reject.\n */\nexport function reject(message, log) {\n    return function promiseRejection(error) {\n        if (log) {\n            console.error(new Error(message));\n        }\n        throw error;\n    };\n}\n/**\n * Takes an object 'state' and fills in buffer[i] at 'path' buffer_paths[i]\n * where buffer_paths[i] is a list indicating where in the object buffer[i] should\n * be placed\n * Example: state = {a: 1, b: {}, c: [0, null]}\n * buffers = [array1, array2]\n * buffer_paths = [['b', 'data'], ['c', 1]]\n * Will lead to {a: 1, b: {data: array1}, c: [0, array2]}\n */\nexport function put_buffers(state, buffer_paths, buffers) {\n    for (var i = 0; i < buffer_paths.length; i++) {\n        var buffer_path = buffer_paths[i];\n        // say we want to set state[x][y][z] = buffers[i]\n        var obj = state;\n        // we first get obj = state[x][y]\n        for (var j = 0; j < buffer_path.length - 1; j++) {\n            obj = obj[buffer_path[j]];\n        }\n        // and then set: obj[z] = buffers[i]\n        obj[buffer_path[buffer_path.length - 1]] = buffers[i];\n    }\n}\n/**\n * The inverse of put_buffers, return an objects with the new state where all buffers(ArrayBuffer)\n * are removed. If a buffer is a member of an object, that object is cloned, and the key removed. If a buffer\n * is an element of an array, that array is cloned, and the element is set to null.\n * See put_buffers for the meaning of buffer_paths\n * Returns an object with the new state (.state) an array with paths to the buffers (.buffer_paths),\n * and the buffers associated to those paths (.buffers).\n */\nexport function remove_buffers(state) {\n    var buffers = [];\n    var buffer_paths = [];\n    // if we need to remove an object from a list, we need to clone that list, otherwise we may modify\n    // the internal state of the widget model\n    // however, we do not want to clone everything, for performance\n    function remove(obj, path) {\n        if (obj.toJSON) {\n            // We need to get the JSON form of the object before recursing.\n            // See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/stringify#toJSON()_behavior\n            obj = obj.toJSON();\n        }\n        if (Array.isArray(obj)) {\n            var is_cloned = false;\n            for (var i = 0; i < obj.length; i++) {\n                var value = obj[i];\n                if (value) {\n                    if (value instanceof ArrayBuffer || ArrayBuffer.isView(value)) {\n                        if (!is_cloned) {\n                            obj = obj.slice();\n                            is_cloned = true;\n                        }\n                        buffers.push(ArrayBuffer.isView(value) ? value.buffer : value);\n                        buffer_paths.push(path.concat([i]));\n                        // easier to just keep the array, but clear the entry, otherwise we have to think\n                        // about array length, much easier this way\n                        obj[i] = null;\n                    }\n                    else {\n                        var new_value = remove(value, path.concat([i]));\n                        // only assigned when the value changes, we may serialize objects that don't support assignment\n                        if (new_value !== value) {\n                            if (!is_cloned) {\n                                obj = obj.slice();\n                                is_cloned = true;\n                            }\n                            obj[i] = new_value;\n                        }\n                    }\n                }\n            }\n        }\n        else if (isPlainObject(obj)) {\n            for (var key in obj) {\n                var is_cloned = false;\n                if (obj.hasOwnProperty(key)) {\n                    var value = obj[key];\n                    if (value) {\n                        if (value instanceof ArrayBuffer || ArrayBuffer.isView(value)) {\n                            if (!is_cloned) {\n                                obj = __assign({}, obj);\n                                is_cloned = true;\n                            }\n                            buffers.push(ArrayBuffer.isView(value) ? value.buffer : value);\n                            buffer_paths.push(path.concat([key]));\n                            delete obj[key]; // for objects/dicts we just delete them\n                        }\n                        else {\n                            var new_value = remove(value, path.concat([key]));\n                            // only assigned when the value changes, we may serialize objects that don't support assignment\n                            if (new_value !== value) {\n                                if (!is_cloned) {\n                                    obj = __assign({}, obj);\n                                    is_cloned = true;\n                                }\n                                obj[key] = new_value;\n                            }\n                        }\n                    }\n                }\n            }\n        }\n        return obj;\n    }\n    var new_state = remove(state, []);\n    return { state: new_state, buffers: buffers, buffer_paths: buffer_paths };\n}\nvar hexTable = [\n    '00', '01', '02', '03', '04', '05', '06', '07', '08', '09', '0A', '0B', '0C', '0D', '0E', '0F',\n    '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '1A', '1B', '1C', '1D', '1E', '1F',\n    '20', '21', '22', '23', '24', '25', '26', '27', '28', '29', '2A', '2B', '2C', '2D', '2E', '2F',\n    '30', '31', '32', '33', '34', '35', '36', '37', '38', '39', '3A', '3B', '3C', '3D', '3E', '3F',\n    '40', '41', '42', '43', '44', '45', '46', '47', '48', '49', '4A', '4B', '4C', '4D', '4E', '4F',\n    '50', '51', '52', '53', '54', '55', '56', '57', '58', '59', '5A', '5B', '5C', '5D', '5E', '5F',\n    '60', '61', '62', '63', '64', '65', '66', '67', '68', '69', '6A', '6B', '6C', '6D', '6E', '6F',\n    '70', '71', '72', '73', '74', '75', '76', '77', '78', '79', '7A', '7B', '7C', '7D', '7E', '7F',\n    '80', '81', '82', '83', '84', '85', '86', '87', '88', '89', '8A', '8B', '8C', '8D', '8E', '8F',\n    '90', '91', '92', '93', '94', '95', '96', '97', '98', '99', '9A', '9B', '9C', '9D', '9E', '9F',\n    'A0', 'A1', 'A2', 'A3', 'A4', 'A5', 'A6', 'A7', 'A8', 'A9', 'AA', 'AB', 'AC', 'AD', 'AE', 'AF',\n    'B0', 'B1', 'B2', 'B3', 'B4', 'B5', 'B6', 'B7', 'B8', 'B9', 'BA', 'BB', 'BC', 'BD', 'BE', 'BF',\n    'C0', 'C1', 'C2', 'C3', 'C4', 'C5', 'C6', 'C7', 'C8', 'C9', 'CA', 'CB', 'CC', 'CD', 'CE', 'CF',\n    'D0', 'D1', 'D2', 'D3', 'D4', 'D5', 'D6', 'D7', 'D8', 'D9', 'DA', 'DB', 'DC', 'DD', 'DE', 'DF',\n    'E0', 'E1', 'E2', 'E3', 'E4', 'E5', 'E6', 'E7', 'E8', 'E9', 'EA', 'EB', 'EC', 'ED', 'EE', 'EF',\n    'F0', 'F1', 'F2', 'F3', 'F4', 'F5', 'F6', 'F7', 'F8', 'F9', 'FA', 'FB', 'FC', 'FD', 'FE', 'FF'\n];\n/**\n * Convert an ArrayBuffer to a hex string.\n */\nexport function bufferToHex(buffer) {\n    var x = new Uint8Array(buffer);\n    var s = [];\n    for (var i = 0; i < x.length; i++) {\n        s.push(hexTable[x[i]]);\n    }\n    return s.join('');\n}\n/**\n * Convert a hex string to an ArrayBuffer.\n */\nexport function hexToBuffer(hex) {\n    var x = new Uint8Array(hex.length / 2);\n    for (var i = 0; i < hex.length; i += 2) {\n        x[i / 2] = parseInt(hex.slice(i, i + 2), 16);\n    }\n    return x.buffer;\n}\n/**\n * Convert an ArrayBuffer to a base64 string.\n */\nexport function bufferToBase64(buffer) {\n    return fromByteArray(new Uint8Array(buffer));\n}\n/**\n * Convert a base64 string to an ArrayBuffer.\n */\nexport function base64ToBuffer(base64) {\n    return toByteArray(base64).buffer;\n}\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nexport var JUPYTER_WIDGETS_VERSION = '1.2.0';\nexport var PROTOCOL_VERSION = '2.1.0';\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n    function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n    return new (P || (P = Promise))(function (resolve, reject) {\n        function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n        function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n        function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n        step((generator = generator.apply(thisArg, _arguments || [])).next());\n    });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n    var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n    return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n    function verb(n) { return function (v) { return step([n, v]); }; }\n    function step(op) {\n        if (f) throw new TypeError(\"Generator is already executing.\");\n        while (_) try {\n            if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n            if (y = 0, t) op = [op[0] & 2, t.value];\n            switch (op[0]) {\n                case 0: case 1: t = op; break;\n                case 4: _.label++; return { value: op[1], done: false };\n                case 5: _.label++; y = op[1]; op = [0]; continue;\n                case 7: op = _.ops.pop(); _.trys.pop(); continue;\n                default:\n                    if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n                    if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n                    if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n                    if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n                    if (t[2]) _.ops.pop();\n                    _.trys.pop(); continue;\n            }\n            op = body.call(thisArg, _);\n        } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n        if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n    }\n};\nimport * as utils from './utils';\nimport { PromiseDelegate, } from '@lumino/coreutils';\nimport { PROTOCOL_VERSION } from './version';\nvar PROTOCOL_MAJOR_VERSION = PROTOCOL_VERSION.split('.', 1)[0];\n/**\n * The control comm target name.\n */\nexport var CONTROL_COMM_TARGET = 'jupyter.widget.control';\n/**\n * The supported version for the control comm channel.\n */\nexport var CONTROL_COMM_PROTOCOL_VERSION = '1.0.0';\n/**\n * Time (in ms) after which we consider the control comm target not responding.\n */\nexport var CONTROL_COMM_TIMEOUT = 4000;\n/**\n * Manager abstract base class\n */\nvar ManagerBase = /** @class */ (function () {\n    function ManagerBase() {\n        /**\n         * The comm target name to register\n         */\n        this.comm_target_name = 'jupyter.widget';\n        /**\n         * Dictionary of model ids and model instance promises\n         */\n        this._models = Object.create(null);\n    }\n    /**\n     * Display a DOMWidgetView for a particular model.\n     */\n    ManagerBase.prototype.display_model = function (msg, model, options) {\n        var _this = this;\n        if (options === void 0) { options = {}; }\n        return this.create_view(model, options).then(function (view) { return _this.display_view(msg, view, options); }).catch(utils.reject('Could not create view', true));\n    };\n    /**\n     * Modifies view options. Generally overloaded in custom widget manager\n     * implementations.\n     */\n    ManagerBase.prototype.setViewOptions = function (options) {\n        if (options === void 0) { options = {}; }\n        return options;\n    };\n    ManagerBase.prototype.create_view = function (model, options) {\n        var _this = this;\n        if (options === void 0) { options = {}; }\n        var viewPromise = model.state_change = model.state_change.then(function () {\n            return _this.loadClass(model.get('_view_name'), model.get('_view_module'), model.get('_view_module_version')).then(function (ViewType) {\n                var view = new ViewType({\n                    model: model,\n                    options: _this.setViewOptions(options)\n                });\n                view.listenTo(model, 'destroy', view.remove);\n                return Promise.resolve(view.render()).then(function () { return view; });\n            }).catch(utils.reject('Could not create a view for model id ' + model.model_id, true));\n        });\n        var id = utils.uuid();\n        model.views[id] = viewPromise;\n        viewPromise.then(function (view) {\n            view.once('remove', function () { delete view.model.views[id]; }, _this);\n        });\n        return model.state_change;\n    };\n    /**\n     * callback handlers specific to a view\n     */\n    ManagerBase.prototype.callbacks = function (view) {\n        return {};\n    };\n    /**\n     * Get a promise for a model by model id.\n     *\n     * #### Notes\n     * If a model is not found, undefined is returned (NOT a promise). However,\n     * the calling code should also deal with the case where a rejected promise\n     * is returned, and should treat that also as a model not found.\n     */\n    ManagerBase.prototype.get_model = function (model_id) {\n        // TODO: Perhaps we should return a Promise.reject if the model is not\n        // found. Right now this isn't a true async function because it doesn't\n        // always return a promise.\n        return this._models[model_id];\n    };\n    /**\n     * Returns true if the given model is registered, otherwise false.\n     *\n     * #### Notes\n     * This is a synchronous way to check if a model is registered.\n     */\n    ManagerBase.prototype.has_model = function (model_id) {\n        return this._models[model_id] !== undefined;\n    };\n    /**\n     * Handle when a comm is opened.\n     */\n    ManagerBase.prototype.handle_comm_open = function (comm, msg) {\n        var protocolVersion = (msg.metadata || {}).version || '';\n        if (protocolVersion.split('.', 1)[0] !== PROTOCOL_MAJOR_VERSION) {\n            var error = \"Wrong widget protocol version: received protocol version '\" + protocolVersion + \"', but was expecting major version '\" + PROTOCOL_MAJOR_VERSION + \"'\";\n            console.error(error);\n            return Promise.reject(error);\n        }\n        var data = msg.content.data;\n        var buffer_paths = data.buffer_paths || [];\n        // Make sure the buffers are DataViews\n        var buffers = (msg.buffers || []).map(function (b) {\n            if (b instanceof DataView) {\n                return b;\n            }\n            else {\n                return new DataView(b instanceof ArrayBuffer ? b : b.buffer);\n            }\n        });\n        utils.put_buffers(data.state, buffer_paths, buffers);\n        return this.new_model({\n            model_name: data.state['_model_name'],\n            model_module: data.state['_model_module'],\n            model_module_version: data.state['_model_module_version'],\n            comm: comm\n        }, data.state).catch(utils.reject('Could not create a model.', true));\n    };\n    /**\n     * Create a comm and new widget model.\n     * @param  options - same options as new_model but comm is not\n     *                          required and additional options are available.\n     * @param  serialized_state - serialized model attributes.\n     */\n    ManagerBase.prototype.new_widget = function (options, serialized_state) {\n        var _this = this;\n        if (serialized_state === void 0) { serialized_state = {}; }\n        var commPromise;\n        // we check to make sure the view information is provided, to help catch\n        // backwards incompatibility errors.\n        if (options.view_name === undefined\n            || options.view_module === undefined\n            || options.view_module_version === undefined) {\n            return Promise.reject('new_widget(...) must be given view information in the options.');\n        }\n        // If no comm is provided, a new comm is opened for the jupyter.widget\n        // target.\n        if (options.comm) {\n            commPromise = Promise.resolve(options.comm);\n        }\n        else {\n            commPromise = this._create_comm(this.comm_target_name, options.model_id, {\n                state: {\n                    _model_module: options.model_module,\n                    _model_module_version: options.model_module_version,\n                    _model_name: options.model_name,\n                    _view_module: options.view_module,\n                    _view_module_version: options.view_module_version,\n                    _view_name: options.view_name\n                },\n            }, { version: PROTOCOL_VERSION });\n        }\n        // The options dictionary is copied since data will be added to it.\n        var options_clone = __assign({}, options);\n        // Create the model. In the case where the comm promise is rejected a\n        // comm-less model is still created with the required model id.\n        return commPromise.then(function (comm) {\n            // Comm Promise Resolved.\n            options_clone.comm = comm;\n            var widget_model = _this.new_model(options_clone, serialized_state);\n            return widget_model.then(function (model) {\n                model.sync('create', model);\n                return model;\n            });\n        }, function () {\n            // Comm Promise Rejected.\n            if (!options_clone.model_id) {\n                options_clone.model_id = utils.uuid();\n            }\n            return _this.new_model(options_clone, serialized_state);\n        });\n    };\n    ManagerBase.prototype.register_model = function (model_id, modelPromise) {\n        var _this = this;\n        this._models[model_id] = modelPromise;\n        modelPromise.then(function (model) {\n            model.once('comm:close', function () {\n                delete _this._models[model_id];\n            });\n        });\n    };\n    /**\n     * Create and return a promise for a new widget model\n     *\n     * @param options - the options for creating the model.\n     * @param serialized_state - attribute values for the model.\n     *\n     * @example\n     * widget_manager.new_model({\n     *      model_name: 'IntSlider',\n     *      model_module: '@jupyter-widgets/controls',\n     *      model_module_version: '1.0.0',\n     *      model_id: 'u-u-i-d'\n     * }).then((model) => { console.log('Create success!', model); },\n     *  (err) => {console.error(err)});\n     *\n     */\n    ManagerBase.prototype.new_model = function (options, serialized_state) {\n        if (serialized_state === void 0) { serialized_state = {}; }\n        return __awaiter(this, void 0, void 0, function () {\n            var model_id, modelPromise;\n            return __generator(this, function (_a) {\n                switch (_a.label) {\n                    case 0:\n                        if (options.model_id) {\n                            model_id = options.model_id;\n                        }\n                        else if (options.comm) {\n                            model_id = options.model_id = options.comm.comm_id;\n                        }\n                        else {\n                            throw new Error('Neither comm nor model_id provided in options object. At least one must exist.');\n                        }\n                        modelPromise = this._make_model(options, serialized_state);\n                        // this call needs to happen before the first `await`, see note in `set_state`:\n                        this.register_model(model_id, modelPromise);\n                        return [4 /*yield*/, modelPromise];\n                    case 1: return [2 /*return*/, _a.sent()];\n                }\n            });\n        });\n    };\n    ManagerBase.prototype._make_model = function (options, serialized_state) {\n        if (serialized_state === void 0) { serialized_state = {}; }\n        return __awaiter(this, void 0, void 0, function () {\n            var model_id, model_promise, ModelType, error_1, attributes, modelOptions, widget_model;\n            return __generator(this, function (_a) {\n                switch (_a.label) {\n                    case 0:\n                        model_id = options.model_id;\n                        model_promise = this.loadClass(options.model_name, options.model_module, options.model_module_version);\n                        _a.label = 1;\n                    case 1:\n                        _a.trys.push([1, 3, , 4]);\n                        return [4 /*yield*/, model_promise];\n                    case 2:\n                        ModelType = _a.sent();\n                        return [3 /*break*/, 4];\n                    case 3:\n                        error_1 = _a.sent();\n                        console.error('Could not instantiate widget');\n                        throw error_1;\n                    case 4:\n                        if (!ModelType) {\n                            throw new Error(\"Cannot find model module \" + options.model_module + \"@\" + options.model_module_version + \", \" + options.model_name);\n                        }\n                        return [4 /*yield*/, ModelType._deserialize_state(serialized_state, this)];\n                    case 5:\n                        attributes = _a.sent();\n                        modelOptions = {\n                            widget_manager: this,\n                            model_id: model_id,\n                            comm: options.comm,\n                        };\n                        widget_model = new ModelType(attributes, modelOptions);\n                        widget_model.name = options.model_name;\n                        widget_model.module = options.model_module;\n                        return [2 /*return*/, widget_model];\n                }\n            });\n        });\n    };\n    /**\n     * Fetch all widgets states from the kernel using the control comm channel\n     * If this fails (control comm handler not implemented kernel side),\n     * it will fall back to `_loadFromKernelModels`.\n     *\n     * This is a utility function that can be used in subclasses.\n     */\n    ManagerBase.prototype._loadFromKernel = function () {\n        return __awaiter(this, void 0, void 0, function () {\n            var data, buffers, initComm_1, error_2, states, bufferPaths, bufferGroups, i, _a, widget_id, path, b, widget_comms;\n            var _this = this;\n            return __generator(this, function (_b) {\n                switch (_b.label) {\n                    case 0:\n                        _b.trys.push([0, 3, , 4]);\n                        return [4 /*yield*/, this._create_comm(CONTROL_COMM_TARGET, utils.uuid(), {}, { version: CONTROL_COMM_PROTOCOL_VERSION })];\n                    case 1:\n                        initComm_1 = _b.sent();\n                        return [4 /*yield*/, new Promise(function (resolve, reject) {\n                                initComm_1.on_msg(function (msg) {\n                                    data = msg['content']['data'];\n                                    if (data.method !== 'update_states') {\n                                        console.warn(\"\\n                        Unknown \" + data.method + \" message on the Control channel\\n                        \");\n                                        return;\n                                    }\n                                    buffers = (msg.buffers || []).map(function (b) {\n                                        if (b instanceof DataView) {\n                                            return b;\n                                        }\n                                        else {\n                                            return new DataView(b instanceof ArrayBuffer ? b : b.buffer);\n                                        }\n                                    });\n                                    resolve(null);\n                                });\n                                initComm_1.on_close(function () { return reject('Control comm was closed too early'); });\n                                // Send a states request msg\n                                initComm_1.send({ method: 'request_states' }, {});\n                                // Reject if we didn't get a response in time\n                                setTimeout(function () { return reject('Control comm did not respond in time'); }, CONTROL_COMM_TIMEOUT);\n                            })];\n                    case 2:\n                        _b.sent();\n                        initComm_1.close();\n                        return [3 /*break*/, 4];\n                    case 3:\n                        error_2 = _b.sent();\n                        console.warn('Failed to fetch ipywidgets through the \"jupyter.widget.control\" comm channel, fallback to fetching individual model state. Reason:', error_2);\n                        // Fall back to the old implementation for old ipywidgets backend versions (ipywidgets<=7.6)\n                        return [2 /*return*/, this._loadFromKernelModels()];\n                    case 4:\n                        states = data.states;\n                        bufferPaths = {};\n                        bufferGroups = {};\n                        // Group buffers and buffer paths by widget id\n                        for (i = 0; i < data.buffer_paths.length; i++) {\n                            _a = data.buffer_paths[i], widget_id = _a[0], path = _a.slice(1);\n                            b = buffers[i];\n                            if (!bufferPaths[widget_id]) {\n                                bufferPaths[widget_id] = [];\n                                bufferGroups[widget_id] = [];\n                            }\n                            bufferPaths[widget_id].push(path);\n                            bufferGroups[widget_id].push(b);\n                        }\n                        return [4 /*yield*/, Promise.all(Object.keys(states).map(function (widget_id) { return __awaiter(_this, void 0, void 0, function () {\n                                var comm, _a;\n                                return __generator(this, function (_b) {\n                                    switch (_b.label) {\n                                        case 0:\n                                            if (!this.has_model(widget_id)) return [3 /*break*/, 1];\n                                            _a = undefined;\n                                            return [3 /*break*/, 3];\n                                        case 1: return [4 /*yield*/, this._create_comm('jupyter.widget', widget_id)];\n                                        case 2:\n                                            _a = _b.sent();\n                                            _b.label = 3;\n                                        case 3:\n                                            comm = _a;\n                                            return [2 /*return*/, { widget_id: widget_id, comm: comm }];\n                                    }\n                                });\n                            }); }))];\n                    case 5:\n                        widget_comms = _b.sent();\n                        return [4 /*yield*/, Promise.all(widget_comms.map(function (_a) {\n                                var widget_id = _a.widget_id, comm = _a.comm;\n                                return __awaiter(_this, void 0, void 0, function () {\n                                    var state, model, deserializedState, error_3;\n                                    return __generator(this, function (_b) {\n                                        switch (_b.label) {\n                                            case 0:\n                                                state = states[widget_id];\n                                                // Put binary buffers\n                                                if (widget_id in bufferPaths) {\n                                                    utils.put_buffers(state, bufferPaths[widget_id], bufferGroups[widget_id]);\n                                                }\n                                                _b.label = 1;\n                                            case 1:\n                                                _b.trys.push([1, 7, , 8]);\n                                                if (!comm) return [3 /*break*/, 3];\n                                                // This must be the first await in the code path that\n                                                // reaches here so that registering the model promise in\n                                                // new_model can register the widget promise before it may\n                                                // be required by other widgets.\n                                                return [4 /*yield*/, this.new_model({\n                                                        model_name: state.model_name,\n                                                        model_module: state.model_module,\n                                                        model_module_version: state.model_module_version,\n                                                        model_id: widget_id,\n                                                        comm: comm,\n                                                    }, state.state)];\n                                            case 2:\n                                                // This must be the first await in the code path that\n                                                // reaches here so that registering the model promise in\n                                                // new_model can register the widget promise before it may\n                                                // be required by other widgets.\n                                                _b.sent();\n                                                return [3 /*break*/, 6];\n                                            case 3: return [4 /*yield*/, this.get_model(widget_id)];\n                                            case 4:\n                                                model = _b.sent();\n                                                return [4 /*yield*/, model.constructor._deserialize_state(state.state, this)];\n                                            case 5:\n                                                deserializedState = _b.sent();\n                                                model.set_state(deserializedState);\n                                                _b.label = 6;\n                                            case 6: return [3 /*break*/, 8];\n                                            case 7:\n                                                error_3 = _b.sent();\n                                                // Failed to create a widget model, we continue creating other models so that\n                                                // other widgets can render\n                                                console.error(error_3);\n                                                return [3 /*break*/, 8];\n                                            case 8: return [2 /*return*/];\n                                        }\n                                    });\n                                });\n                            }))];\n                    case 6:\n                        _b.sent();\n                        return [2 /*return*/];\n                }\n            });\n        });\n    };\n    /**\n     * Old implementation of fetching widget models one by one using\n     * the request_state message on each comm.\n     *\n     * This is a utility function that can be used in subclasses.\n     */\n    ManagerBase.prototype._loadFromKernelModels = function () {\n        return __awaiter(this, void 0, void 0, function () {\n            var comm_ids, widgets_info;\n            var _this = this;\n            return __generator(this, function (_a) {\n                switch (_a.label) {\n                    case 0: return [4 /*yield*/, this._get_comm_info()];\n                    case 1:\n                        comm_ids = _a.sent();\n                        return [4 /*yield*/, Promise.all(Object.keys(comm_ids).map(function (comm_id) { return __awaiter(_this, void 0, void 0, function () {\n                                var comm, msg_id, info;\n                                return __generator(this, function (_a) {\n                                    switch (_a.label) {\n                                        case 0:\n                                            if (this.has_model(comm_id)) {\n                                                return [2 /*return*/];\n                                            }\n                                            return [4 /*yield*/, this._create_comm(this.comm_target_name, comm_id)];\n                                        case 1:\n                                            comm = _a.sent();\n                                            msg_id = '';\n                                            info = new PromiseDelegate();\n                                            comm.on_msg(function (msg) {\n                                                if (msg.parent_header.msg_id === msg_id &&\n                                                    msg.header.msg_type === 'comm_msg' &&\n                                                    msg.content.data.method === 'update') {\n                                                    var data = msg.content.data;\n                                                    var buffer_paths = data.buffer_paths || [];\n                                                    var buffers = msg.buffers || [];\n                                                    utils.put_buffers(data.state, buffer_paths, buffers);\n                                                    info.resolve({ comm: comm, msg: msg });\n                                                }\n                                            });\n                                            msg_id = comm.send({\n                                                method: 'request_state',\n                                            }, this.callbacks(undefined));\n                                            return [2 /*return*/, info.promise];\n                                    }\n                                });\n                            }); }))];\n                    case 2:\n                        widgets_info = _a.sent();\n                        // We put in a synchronization barrier here so that we don't have to\n                        // topologically sort the restored widgets. `new_model` synchronously\n                        // registers the widget ids before reconstructing their state\n                        // asynchronously, so promises to every widget reference should be available\n                        // by the time they are used.\n                        return [4 /*yield*/, Promise.all(widgets_info.map(function (widget_info) { return __awaiter(_this, void 0, void 0, function () {\n                                var content;\n                                return __generator(this, function (_a) {\n                                    switch (_a.label) {\n                                        case 0:\n                                            if (!widget_info) {\n                                                return [2 /*return*/];\n                                            }\n                                            content = widget_info.msg.content;\n                                            return [4 /*yield*/, this.new_model({\n                                                    model_name: content.data.state._model_name,\n                                                    model_module: content.data.state._model_module,\n                                                    model_module_version: content.data.state._model_module_version,\n                                                    comm: widget_info.comm,\n                                                }, content.data.state)];\n                                        case 1:\n                                            _a.sent();\n                                            return [2 /*return*/];\n                                    }\n                                });\n                            }); }))];\n                    case 3:\n                        // We put in a synchronization barrier here so that we don't have to\n                        // topologically sort the restored widgets. `new_model` synchronously\n                        // registers the widget ids before reconstructing their state\n                        // asynchronously, so promises to every widget reference should be available\n                        // by the time they are used.\n                        _a.sent();\n                        return [2 /*return*/];\n                }\n            });\n        });\n    };\n    /**\n     * Close all widgets and empty the widget state.\n     * @return Promise that resolves when the widget state is cleared.\n     */\n    ManagerBase.prototype.clear_state = function () {\n        var _this = this;\n        return utils.resolvePromisesDict(this._models).then(function (models) {\n            Object.keys(models).forEach(function (id) { return models[id].close(); });\n            _this._models = Object.create(null);\n        });\n    };\n    /**\n     * Asynchronously get the state of the widget manager.\n     *\n     * This includes all of the widget models, and follows the format given in\n     * the @jupyter-widgets/schema package.\n     *\n     * @param options - The options for what state to return.\n     * @returns Promise for a state dictionary\n     */\n    ManagerBase.prototype.get_state = function (options) {\n        var _this = this;\n        if (options === void 0) { options = {}; }\n        var modelPromises = Object.keys(this._models).map(function (id) { return _this._models[id]; });\n        return Promise.all(modelPromises).then(function (models) {\n            return serialize_state(models, options);\n        });\n    };\n    /**\n     * Set the widget manager state.\n     *\n     * @param state - a Javascript object conforming to the application/vnd.jupyter.widget-state+json spec.\n     *\n     * Reconstructs all of the widget models in the state, merges that with the\n     * current manager state, and then attempts to redisplay the widgets in the\n     * state.\n     */\n    ManagerBase.prototype.set_state = function (state) {\n        var _this = this;\n        // Check to make sure that it's the same version we are parsing.\n        if (!(state.version_major && state.version_major <= 2)) {\n            throw 'Unsupported widget state format';\n        }\n        var models = state.state;\n        // Recreate all the widget models for the given widget manager state.\n        var all_models = this._get_comm_info().then(function (live_comms) {\n            /* Note: It is currently safe to just loop over the models in any order,\n               given that the following holds (does at the time of writing):\n               1: any call to `new_model` with state registers the model promise (e.g. with `register_model`)\n                  synchronously (before it's first `await` statement).\n               2: any calls to a model constructor or the `set_state` method on a model,\n                  happens asynchronously (in a `then` clause, or after an `await` statement).\n\n              Without these assumptions, one risks trying to set model state with a reference\n              to another model that doesn't exist yet!\n            */\n            return Promise.all(Object.keys(models).map(function (model_id) {\n                // First put back the binary buffers\n                var decode = { 'base64': utils.base64ToBuffer, 'hex': utils.hexToBuffer };\n                var model = models[model_id];\n                var modelState = model.state;\n                if (model.buffers) {\n                    var bufferPaths = model.buffers.map(function (b) { return b.path; });\n                    // put_buffers expects buffers to be DataViews\n                    var buffers = model.buffers.map(function (b) { return new DataView(decode[b.encoding](b.data)); });\n                    utils.put_buffers(model.state, bufferPaths, buffers);\n                }\n                // If the model has already been created, set its state and then\n                // return it.\n                if (_this.has_model(model_id)) {\n                    return _this.get_model(model_id).then(function (model) {\n                        // deserialize state\n                        return model.constructor._deserialize_state(modelState || {}, _this).then(function (attributes) {\n                            model.set_state(attributes); // case 2\n                            return model;\n                        });\n                    });\n                }\n                var modelCreate = {\n                    model_id: model_id,\n                    model_name: model.model_name,\n                    model_module: model.model_module,\n                    model_module_version: model.model_module_version\n                };\n                if (live_comms.hasOwnProperty(model_id)) { // live comm\n                    // This connects to an existing comm if it exists, and\n                    // should *not* send a comm open message.\n                    return _this._create_comm(_this.comm_target_name, model_id).then(function (comm) {\n                        modelCreate.comm = comm;\n                        return _this.new_model(modelCreate); // No state, so safe wrt. case 1\n                    });\n                }\n                else {\n                    return _this.new_model(modelCreate, modelState); // case 1\n                }\n            }));\n        });\n        return all_models;\n    };\n    /**\n     * Disconnect the widget manager from the kernel, setting each model's comm\n     * as dead.\n     */\n    ManagerBase.prototype.disconnect = function () {\n        var _this = this;\n        Object.keys(this._models).forEach(function (i) {\n            _this._models[i].then(function (model) { model.comm_live = false; });\n        });\n    };\n    /**\n     * Resolve a URL relative to the current notebook location.\n     *\n     * The default implementation just returns the original url.\n     */\n    ManagerBase.prototype.resolveUrl = function (url) {\n        return Promise.resolve(url);\n    };\n    /**\n     * Filter serialized widget state to remove any ID's already present in manager.\n     *\n     * @param {*} state Serialized state to filter\n     *\n     * @returns {*} A copy of the state, with its 'state' attribute filtered\n     */\n    ManagerBase.prototype.filterExistingModelState = function (serialized_state) {\n        var _this = this;\n        var models = serialized_state.state;\n        models = Object.keys(models)\n            .filter(function (model_id) { return !_this.has_model(model_id); })\n            .reduce(function (res, model_id) {\n            res[model_id] = models[model_id];\n            return res;\n        }, {});\n        return __assign(__assign({}, serialized_state), { state: models });\n    };\n    return ManagerBase;\n}());\nexport { ManagerBase };\n/**\n * Serialize an array of widget models\n *\n * #### Notes\n * The return value follows the format given in the\n * @jupyter-widgets/schema package.\n */\nexport function serialize_state(models, options) {\n    if (options === void 0) { options = {}; }\n    var state = {};\n    models.forEach(function (model) {\n        var model_id = model.model_id;\n        var split = utils.remove_buffers(model.serialize(model.get_state(options.drop_defaults)));\n        var buffers = split.buffers.map(function (buffer, index) {\n            return {\n                data: utils.bufferToBase64(buffer),\n                path: split.buffer_paths[index],\n                encoding: 'base64'\n            };\n        });\n        state[model_id] = {\n            model_name: model.name,\n            model_module: model.module,\n            model_module_version: model.get('_model_module_version'),\n            state: split.state\n        };\n        // To save space, only include the buffers key if we have buffers\n        if (buffers.length > 0) {\n            state[model_id].buffers = buffers;\n        }\n    });\n    return { version_major: 2, version_minor: 0, state: state };\n}\n","// This file contains a modified version of the set function from the Backbone\n// (see\n// https://github.com/jashkenas/backbone/blob/05fde9e201f7e2137796663081105cd6dad12a98/backbone.js#L460,\n// with changes below marked with an EDIT comment). This file in Backbone has the following license.\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\n//     (c) 2010-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n//     Backbone may be freely distributed under the MIT license.\n//     For all details and documentation:\n//     http://backbonejs.org\n// Backbone's full license is below (from https://github.com/jashkenas/backbone/blob/05fde9e201f7e2137796663081105cd6dad12a98/LICENSE)\n/*\nCopyright (c) 2010-2015 Jeremy Ashkenas, DocumentCloud\n\nPermission is hereby granted, free of charge, to any person\nobtaining a copy of this software and associated documentation\nfiles (the \"Software\"), to deal in the Software without\nrestriction, including without limitation the rights to use,\ncopy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the\nSoftware is furnished to do so, subject to the following\nconditions:\n\nThe above copyright notice and this permission notice shall be\nincluded in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\nEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES\nOF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\nNONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT\nHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,\nWHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\nFROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR\nOTHER DEALINGS IN THE SOFTWARE.\n*/\nimport * as utils from './utils';\n// Set a hash of model attributes on the object, firing `\"change\"`. This is\n// the core primitive operation of a model, updating the data and notifying\n// anyone who needs to know about the change in state. The heart of the beast.\n// This *MUST* be called with the model as the `this` context.\nexport function set(key, val, options) {\n    /* tslint:disable:no-invalid-this */\n    if (key == null) {\n        return this;\n    }\n    // Handle both `\"key\", value` and `{key: value}` -style arguments.\n    var attrs;\n    if (typeof key === 'object') {\n        attrs = key;\n        options = val;\n    }\n    else {\n        (attrs = {})[key] = val;\n    }\n    options || (options = {});\n    // Run validation.\n    if (!this._validate(attrs, options)) {\n        return false;\n    }\n    // Extract attributes and options.\n    var unset = options.unset;\n    var silent = options.silent;\n    var changes = [];\n    var changing = this._changing;\n    this._changing = true;\n    try {\n        if (!changing) {\n            // EDIT: changed to use object spread instead of _.clone\n            this._previousAttributes = __assign({}, this.attributes);\n            this.changed = {};\n        }\n        var current = this.attributes;\n        var changed = this.changed;\n        var prev = this._previousAttributes;\n        // For each `set` attribute, update or delete the current value.\n        for (var attr in attrs) {\n            val = attrs[attr];\n            // EDIT: the following two lines use our isEqual instead of _.isEqual\n            if (!utils.isEqual(current[attr], val)) {\n                changes.push(attr);\n            }\n            if (!utils.isEqual(prev[attr], val)) {\n                changed[attr] = val;\n            }\n            else {\n                delete changed[attr];\n            }\n            unset ? delete current[attr] : current[attr] = val;\n        }\n        // Update the `id`.\n        this.id = this.get(this.idAttribute);\n        // Trigger all relevant attribute changes.\n        if (!silent) {\n            if (changes.length) {\n                this._pending = options;\n            }\n            for (var i = 0; i < changes.length; i++) {\n                this.trigger('change:' + changes[i], this, current[changes[i]], options);\n            }\n        }\n        // You might be wondering why there's a `while` loop here. Changes can\n        // be recursively nested within `\"change\"` events.\n        if (changing) {\n            return this;\n        }\n        if (!silent) {\n            while (this._pending) {\n                options = this._pending;\n                this._pending = false;\n                this.trigger('change', this, options);\n            }\n        }\n    }\n    finally {\n        this._pending = false;\n        this._changing = false;\n    }\n    return this;\n    /* tslint:enable:no-invalid-this */\n}\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\n/*\n This file contains substantial portions of https://github.com/akre54/Backbone.NativeView/blob/521188d9554b53d95d70ed34f878d8ac9fc10df2/backbone.nativeview.js, which has the following license:\n\n(c) 2015 Adam Krebs, Jimmy Yuen Ho Wong\nBackbone.NativeView may be freely distributed under the MIT license.\n\nCopyright (c) 2014 Adam Krebs\n\nPermission is hereby granted, free of charge, to any person\nobtaining a copy of this software and associated documentation\nfiles (the \"Software\"), to deal in the Software without\nrestriction, including without limitation the rights to use,\ncopy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the\nSoftware is furnished to do so, subject to the following\nconditions:\n\nThe above copyright notice and this permission notice shall be\nincluded in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\nEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES\nOF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\nNONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT\nHOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,\nWHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING\nFROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR\nOTHER DEALINGS IN THE SOFTWARE.\n\n*/\nimport * as Backbone from 'backbone';\n// Caches a local reference to `Element.prototype` for faster access.\nvar ElementProto = Element.prototype; // : typeof Element = (typeof Element !== 'undefined' && Element.prototype) || {};\n// Find the right `Element#matches` for IE>=9 and modern browsers.\nvar matchesSelector = ElementProto.matches ||\n    ElementProto['webkitMatchesSelector'] ||\n    ElementProto['mozMatchesSelector'] ||\n    ElementProto['msMatchesSelector'] ||\n    ElementProto['oMatchesSelector'] ||\n    function matches(selector) {\n        /* tslint:disable:no-invalid-this */\n        var matches = (this.document || this.ownerDocument).querySelectorAll(selector);\n        var i = matches.length;\n        while (--i >= 0 && matches.item(i) !== this) {\n            continue;\n        }\n        return i > -1;\n        /* tslint:enable:no-invalid-this */\n    };\nvar NativeView = /** @class */ (function (_super) {\n    __extends(NativeView, _super);\n    function NativeView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    NativeView.prototype._removeElement = function () {\n        this.undelegateEvents();\n        if (this.el.parentNode) {\n            this.el.parentNode.removeChild(this.el);\n        }\n    };\n    // Apply the `element` to the view.\n    NativeView.prototype._setElement = function (element) {\n        this.el = element;\n    };\n    // Set a hash of attributes to the view's `el`. We use the \"prop\" version\n    // if available, falling back to `setAttribute` for the catch-all.\n    NativeView.prototype._setAttributes = function (attrs) {\n        for (var attr in attrs) {\n            attr in this.el ? this.el[attr] = attrs[attr] : this.el.setAttribute(attr, attrs[attr]);\n        }\n    };\n    /**\n     * Make an event delegation handler for the given `eventName` and `selector`\n     * and attach it to `this.el`.\n     * If selector is empty, the listener will be bound to `this.el`. If not, a\n     * new handler that will recursively traverse up the event target's DOM\n     * hierarchy looking for a node that matches the selector. If one is found,\n     * the event's `delegateTarget` property is set to it and the return the\n     * result of calling bound `listener` with the parameters given to the\n     * handler.\n     *\n     * This does not properly handle selectors for things like focus and blur (see\n     * https://github.com/jquery/jquery/blob/7d21f02b9ec9f655583e898350badf89165ed4d5/src/event.js#L442\n     * for some similar exceptional cases).\n     */\n    NativeView.prototype.delegate = function (eventName, selector, listener) {\n        if (typeof selector !== 'string') {\n            listener = selector;\n            selector = null;\n        }\n        // We have to initialize this here, instead of in the constructor, because the\n        // super constructor eventually calls this method before we get a chance to initialize\n        // this._domEvents to an empty list.\n        if (this._domEvents === void 0) {\n            this._domEvents = [];\n        }\n        var root = this.el;\n        var handler = selector ? function (e) {\n            var node = e.target || e.srcElement;\n            for (; node && node !== root; node = node.parentNode) {\n                if (matchesSelector.call(node, selector)) {\n                    e.delegateTarget = node;\n                    if (listener.handleEvent) {\n                        return listener.handleEvent(e);\n                    }\n                    else {\n                        return listener(e);\n                    }\n                }\n            }\n        } : listener;\n        this.el.addEventListener(eventName, handler, false);\n        this._domEvents.push({ eventName: eventName, handler: handler, listener: listener, selector: selector });\n        return handler;\n    };\n    // Remove a single delegated event. Either `eventName` or `selector` must\n    // be included, `selector` and `listener` are optional.\n    NativeView.prototype.undelegate = function (eventName, selector, listener) {\n        if (typeof selector === 'function') {\n            listener = selector;\n            selector = null;\n        }\n        if (this.el && this._domEvents) {\n            var handlers = this._domEvents.slice();\n            var i = handlers.length;\n            while (i--) {\n                var item = handlers[i];\n                var match = item.eventName === eventName &&\n                    (listener ? item.listener === listener : true) &&\n                    (selector ? item.selector === selector : true);\n                if (!match) {\n                    continue;\n                }\n                this.el.removeEventListener(item.eventName, item.handler, false);\n                this._domEvents.splice(i, 1);\n            }\n        }\n        return this;\n    };\n    // Remove all events created with `delegate` from `el`\n    NativeView.prototype.undelegateEvents = function () {\n        if (this.el && this._domEvents) {\n            var len = this._domEvents.length;\n            for (var i = 0; i < len; i++) {\n                var item = this._domEvents[i];\n                this.el.removeEventListener(item.eventName, item.handler, false);\n            }\n            this._domEvents.length = 0;\n        }\n        return this;\n    };\n    return NativeView;\n}(Backbone.View));\nexport { NativeView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport * as backbonePatch from './backbone-patch';\nimport * as utils from './utils';\nimport * as Backbone from 'backbone';\nimport $ from 'jquery';\nimport { NativeView } from './nativeview';\nimport { Panel, Widget } from '@lumino/widgets';\nimport { MessageLoop } from '@lumino/messaging';\nimport { JUPYTER_WIDGETS_VERSION } from './version';\n/**\n * The magic key used in the widget graph serialization.\n */\nvar IPY_MODEL_ = 'IPY_MODEL_';\n/**\n * Replace model ids with models recursively.\n */\nexport function unpack_models(value, manager) {\n    if (Array.isArray(value)) {\n        var unpacked_1 = [];\n        value.forEach(function (sub_value, key) {\n            unpacked_1.push(unpack_models(sub_value, manager));\n        });\n        return Promise.all(unpacked_1);\n    }\n    else if (value instanceof Object) {\n        var unpacked_2 = {};\n        Object.keys(value).forEach(function (key) {\n            unpacked_2[key] = unpack_models(value[key], manager);\n        });\n        return utils.resolvePromisesDict(unpacked_2);\n    }\n    else if (typeof value === 'string' && value.slice(0, 10) === 'IPY_MODEL_') {\n        // get_model returns a promise already\n        return manager.get_model(value.slice(10, value.length));\n    }\n    else {\n        return Promise.resolve(value);\n    }\n}\n/** Replace models with ids recursively.\n *\n * If the commonly-used `unpack_models` is given as the `deseralize` method,\n * pack_models would be the appropriate `serialize`.\n * However, the default serialize method will have the same effect, when\n * `unpack_models` is used as the deserialize method.\n * This is to ensure backwards compatibility, see:\n *   https://github.com/jupyter-widgets/ipywidgets/pull/3738/commits/f9e27328bb631eb5247a7a6563595d3e655492c7#diff-efb19099381ae8911dd7f69b015a0138d08da7164512c1ee112aa75100bc9be2\n */\nexport function pack_models(value, widget) {\n    if (Array.isArray(value)) {\n        var model_ids = [];\n        for (var _i = 0, value_1 = value; _i < value_1.length; _i++) {\n            var model = value_1[_i];\n            model_ids.push(pack_models(model, widget));\n        }\n        return model_ids;\n    }\n    else if (value instanceof WidgetModel) {\n        return \"\" + IPY_MODEL_ + value.model_id;\n    }\n    else if (value instanceof Object && typeof value !== 'string') {\n        var packed_1 = {};\n        Object.keys(value).forEach(function (key) {\n            packed_1[key] = pack_models(value[key], widget);\n        });\n    }\n    else {\n        return value;\n    }\n}\nvar WidgetModel = /** @class */ (function (_super) {\n    __extends(WidgetModel, _super);\n    function WidgetModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * The default attributes.\n     */\n    WidgetModel.prototype.defaults = function () {\n        return {\n            _model_module: '@jupyter-widgets/base',\n            _model_name: 'WidgetModel',\n            _model_module_version: JUPYTER_WIDGETS_VERSION,\n            _view_module: '@jupyter-widgets/base',\n            _view_name: null,\n            _view_module_version: JUPYTER_WIDGETS_VERSION,\n            _view_count: null,\n        };\n    };\n    /**\n     * Test to see if the model has been synced with the server.\n     *\n     * #### Notes\n     * As of backbone 1.1, backbone ignores `patch` if it thinks the\n     * model has never been pushed.\n     */\n    WidgetModel.prototype.isNew = function () {\n        return false;\n    };\n    /**\n     * Constructor\n     *\n     * Initializes a WidgetModel instance. Called by the Backbone constructor.\n     *\n     * Parameters\n     * ----------\n     * widget_manager : WidgetManager instance\n     * model_id : string\n     *      An ID unique to this model.\n     * comm : Comm instance (optional)\n     */\n    WidgetModel.prototype.initialize = function (attributes, options) {\n        this._expectedEchoMsgIds = {};\n        this._attrsToUpdate = {};\n        _super.prototype.initialize.call(this, attributes, options);\n        // Attributes should be initialized here, since user initialization may depend on it\n        this.widget_manager = options.widget_manager;\n        this.model_id = options.model_id;\n        var comm = options.comm;\n        this.views = Object.create(null);\n        this.state_change = Promise.resolve();\n        this._closed = false;\n        this._state_lock = null;\n        this._msg_buffer = null;\n        this._msg_buffer_callbacks = null;\n        this._pending_msgs = 0;\n        // _buffered_state_diff must be created *after* the super.initialize\n        // call above. See the note in the set() method below.\n        this._buffered_state_diff = {};\n        if (comm) {\n            // Remember comm associated with the model.\n            this.comm = comm;\n            // Hook comm messages up to model.\n            comm.on_close(this._handle_comm_closed.bind(this));\n            comm.on_msg(this._handle_comm_msg.bind(this));\n            this.comm_live = true;\n        }\n        else {\n            this.comm_live = false;\n        }\n    };\n    Object.defineProperty(WidgetModel.prototype, \"comm_live\", {\n        get: function () {\n            return this._comm_live;\n        },\n        set: function (x) {\n            this._comm_live = x;\n            this.trigger('comm_live_update');\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Send a custom msg over the comm.\n     */\n    WidgetModel.prototype.send = function (content, callbacks, buffers) {\n        if (this.comm !== undefined) {\n            var data = { method: 'custom', content: content };\n            this.comm.send(data, callbacks, {}, buffers);\n        }\n    };\n    /**\n     * Close model\n     *\n     * @param comm_closed - true if the comm is already being closed. If false, the comm will be closed.\n     *\n     * @returns - a promise that is fulfilled when all the associated views have been removed.\n     */\n    WidgetModel.prototype.close = function (comm_closed) {\n        var _this = this;\n        if (comm_closed === void 0) { comm_closed = false; }\n        // can only be closed once.\n        if (this._closed) {\n            return;\n        }\n        this._closed = true;\n        if (this.comm && !comm_closed) {\n            this.comm.close();\n        }\n        this.stopListening();\n        this.trigger('destroy', this);\n        if (this.comm) {\n            delete this.comm;\n        }\n        // Delete all views of this model\n        var views = Object.keys(this.views).map(function (id) {\n            return _this.views[id].then(function (view) { return view.remove(); });\n        });\n        delete this.views;\n        return Promise.all(views).then(function () { return; });\n    };\n    /**\n     * Handle when a widget comm is closed.\n     */\n    WidgetModel.prototype._handle_comm_closed = function (msg) {\n        this.trigger('comm:close');\n        this.close(true);\n    };\n    /**\n     * Handle incoming comm msg.\n     */\n    WidgetModel.prototype._handle_comm_msg = function (msg) {\n        var _this = this;\n        var data = msg.content.data;\n        var method = data.method;\n        // tslint:disable-next-line:switch-default\n        switch (method) {\n            case 'update':\n            case 'echo_update':\n                this.state_change = this.state_change\n                    .then(function () {\n                    var _a, _b, _c;\n                    var state = data.state;\n                    var buffer_paths = (_a = data.buffer_paths, (_a !== null && _a !== void 0 ? _a : []));\n                    // Make sure the buffers are DataViews\n                    var buffers = (_c = (_b = msg.buffers) === null || _b === void 0 ? void 0 : _b.slice(0, buffer_paths.length), (_c !== null && _c !== void 0 ? _c : [])).map(function (b) {\n                        if (b instanceof DataView) {\n                            return b;\n                        }\n                        else {\n                            return new DataView(b instanceof ArrayBuffer ? b : b.buffer);\n                        }\n                    });\n                    utils.put_buffers(state, buffer_paths, buffers);\n                    if (msg.parent_header && method === 'echo_update') {\n                        var msgId_1 = msg.parent_header.msg_id;\n                        // we may have echos coming from other clients, we only care about\n                        // dropping echos for which we expected a reply\n                        var expectedEcho = Object.keys(state).filter(function (attrName) {\n                            return _this._expectedEchoMsgIds.hasOwnProperty(attrName);\n                        });\n                        expectedEcho.forEach(function (attrName) {\n                            // Skip echo messages until we get the reply we are expecting.\n                            var isOldMessage = _this._expectedEchoMsgIds[attrName] !== msgId_1;\n                            if (isOldMessage) {\n                                // Ignore an echo update that comes before our echo.\n                                delete state[attrName];\n                            }\n                            else {\n                                // we got our echo confirmation, so stop looking for it\n                                delete _this._expectedEchoMsgIds[attrName];\n                                // Start accepting echo updates unless we plan to send out a new state soon\n                                if (_this._msg_buffer !== null &&\n                                    Object.prototype.hasOwnProperty.call(_this._msg_buffer, attrName)) {\n                                    delete state[attrName];\n                                }\n                            }\n                        });\n                    }\n                    return _this.constructor._deserialize_state(state, _this.widget_manager);\n                }).then(function (state) {\n                    _this.set_state(state);\n                }).catch(utils.reject(\"Could not process update msg for model id: \" + this.model_id, true));\n                return this.state_change;\n            case 'custom':\n                this.trigger('msg:custom', data.content, msg.buffers);\n                return Promise.resolve();\n        }\n    };\n    /**\n     * Handle when a widget is updated from the backend.\n     *\n     * This function is meant for internal use only. Values set here will not be propagated on a sync.\n     */\n    WidgetModel.prototype.set_state = function (state) {\n        this._state_lock = state;\n        try {\n            this.set(state);\n        }\n        catch (e) {\n            console.error(\"Error setting state: \" + e.message);\n        }\n        finally {\n            this._state_lock = null;\n        }\n    };\n    /**\n     * Get the serializable state of the model.\n     *\n     * If drop_default is truthy, attributes that are equal to their default\n     * values are dropped.\n     */\n    WidgetModel.prototype.get_state = function (drop_defaults) {\n        var fullState = this.attributes;\n        if (drop_defaults) {\n            // if defaults is a function, call it\n            var d = this.defaults;\n            var defaults_1 = (typeof d === 'function') ? d.call(this) : d;\n            var state_1 = {};\n            Object.keys(fullState).forEach(function (key) {\n                if (!(utils.isEqual(fullState[key], defaults_1[key]))) {\n                    state_1[key] = fullState[key];\n                }\n            });\n            return state_1;\n        }\n        else {\n            return __assign({}, fullState);\n        }\n    };\n    /**\n     * Handle status msgs.\n     *\n     * execution_state : ('busy', 'idle', 'starting')\n     */\n    WidgetModel.prototype._handle_status = function (msg) {\n        if (this.comm !== void 0) {\n            if (msg.content.execution_state === 'idle') {\n                this._pending_msgs--;\n                // Sanity check for logic errors that may push this below zero.\n                if (this._pending_msgs < 0) {\n                    console.error(\"Jupyter Widgets message throttle: Pending messages < 0 (=\" + this._pending_msgs + \"), which is unexpected. Resetting to 0 to continue.\");\n                    this._pending_msgs = 0; // do not break message throttling in case of unexpected errors\n                }\n                // Send buffer if one is waiting and we are below the throttle.\n                if (this._msg_buffer !== null\n                    && this._pending_msgs < 1) {\n                    var msgId = this.send_sync_message(this._msg_buffer, this._msg_buffer_callbacks);\n                    this.rememberLastUpdateFor(msgId);\n                    this._msg_buffer = null;\n                    this._msg_buffer_callbacks = null;\n                }\n            }\n        }\n    };\n    /**\n     * Create msg callbacks for a comm msg.\n     */\n    WidgetModel.prototype.callbacks = function (view) {\n        return this.widget_manager.callbacks(view);\n    };\n    /**\n     * Set one or more values.\n     *\n     * We just call the super method, in which val and options are optional.\n     * Handles both \"key\", value and {key: value} -style arguments.\n     */\n    WidgetModel.prototype.set = function (key, val, options) {\n        // Call our patched backbone set. See #1642 and #1643.\n        var return_value = backbonePatch.set.call(this, key, val, options);\n        // Backbone only remembers the diff of the most recent set()\n        // operation.  Calling set multiple times in a row results in a\n        // loss of change information.  Here we keep our own running diff.\n        //\n        // We don't buffer the state set in the constructor (including\n        // defaults), so we first check to see if we've initialized _buffered_state_diff.\n        // which happens after the constructor sets attributes at creation.\n        if (this._buffered_state_diff !== void 0) {\n            var attrs = this.changedAttributes() || {};\n            // The state_lock lists attributes that are currently being changed\n            // right now from a kernel message. We don't want to send these\n            // non-changes back to the kernel, so we delete them out of attrs if\n            // they haven't changed from their state_lock value.\n            // The state lock could be null or undefined (if set is being called from\n            // the initializer).\n            if (this._state_lock) {\n                for (var _i = 0, _a = Object.keys(this._state_lock); _i < _a.length; _i++) {\n                    var key_1 = _a[_i];\n                    if (attrs[key_1] === this._state_lock[key_1]) {\n                        delete attrs[key_1];\n                    }\n                }\n            }\n            this._buffered_state_diff = utils.assign(this._buffered_state_diff, attrs);\n        }\n        return return_value;\n    };\n    /**\n     * Handle sync to the back-end.  Called when a model.save() is called.\n     *\n     * Make sure a comm exists.\n     *\n     * Parameters\n     * ----------\n     * method : create, update, patch, delete, read\n     *   create/update always send the full attribute set\n     *   patch - only send attributes listed in options.attrs, and if we\n     *   are queuing up messages, combine with previous messages that have\n     *   not been sent yet\n     * model : the model we are syncing\n     *   will normally be the same as `this`\n     * options : dict\n     *   the `attrs` key, if it exists, gives an {attr: value} dict that\n     *   should be synced, otherwise, sync all attributes.\n     *\n     */\n    WidgetModel.prototype.sync = function (method, model, options) {\n        var _this = this;\n        if (options === void 0) { options = {}; }\n        // the typing is to return `any` since the super.sync method returns a JqXHR, but we just return false if there is an error.\n        if (this.comm === undefined) {\n            throw 'Syncing error: no comm channel defined';\n        }\n        var attrs = (method === 'patch') ? options.attrs : model.get_state(options.drop_defaults);\n        // The state_lock lists attributes that are currently being changed\n        // right now from a kernel message. We don't want to send these\n        // non-changes back to the kernel, so we delete them out of attrs if\n        // they haven't changed from their state_lock value.\n        // The state lock could be null or undefined (if this is triggered\n        // from the initializer).\n        if (this._state_lock) {\n            for (var _i = 0, _a = Object.keys(this._state_lock); _i < _a.length; _i++) {\n                var key = _a[_i];\n                if (attrs[key] === this._state_lock[key]) {\n                    delete attrs[key];\n                }\n            }\n        }\n        Object.keys(attrs).forEach(function (attrName) {\n            _this._attrsToUpdate[attrName] = true;\n        });\n        var msgState = this.serialize(attrs);\n        if (Object.keys(msgState).length > 0) {\n            // If this message was sent via backbone itself, it will not\n            // have any callbacks.  It's important that we create callbacks\n            // so we can listen for status messages, etc...\n            var callbacks = options.callbacks || this.callbacks();\n            // Check throttle.\n            if (this._pending_msgs >= 1) {\n                // The throttle has been exceeded, buffer the current msg so\n                // it can be sent once the kernel has finished processing\n                // some of the existing messages.\n                // Combine updates if it is a 'patch' sync, otherwise replace updates\n                switch (method) {\n                    case 'patch':\n                        this._msg_buffer = utils.assign(this._msg_buffer || {}, msgState);\n                        break;\n                    case 'update':\n                    case 'create':\n                        this._msg_buffer = msgState;\n                        break;\n                    default:\n                        throw 'unrecognized syncing method';\n                }\n                this._msg_buffer_callbacks = callbacks;\n            }\n            else {\n                // We haven't exceeded the throttle, send the message like\n                // normal.\n                var msgId = this.send_sync_message(attrs, callbacks);\n                this.rememberLastUpdateFor(msgId);\n                // Since the comm is a one-way communication, assume the message\n                // arrived and was processed successfully.\n                // Don't call options.success since we don't have a model back from\n                // the server. Note that this means we don't have the Backbone\n                // 'sync' event.\n            }\n        }\n    };\n    WidgetModel.prototype.rememberLastUpdateFor = function (msgId) {\n        var _this = this;\n        Object.keys(this._attrsToUpdate).forEach(function (attrName) {\n            _this._expectedEchoMsgIds[attrName] = msgId;\n        });\n        this._attrsToUpdate = {};\n    };\n    /**\n     * Serialize widget state.\n     *\n     * A serializer is a function which takes in a state attribute and a widget,\n     * and synchronously returns a JSONable object. The returned object will\n     * have toJSON called if possible, and the final result should be a\n     * primitive object that is a snapshot of the widget state that may have\n     * binary array buffers.\n     */\n    WidgetModel.prototype.serialize = function (state) {\n        var serializers = this.constructor.serializers || {};\n        for (var _i = 0, _a = Object.keys(state); _i < _a.length; _i++) {\n            var k = _a[_i];\n            try {\n                if (serializers[k] && serializers[k].serialize) {\n                    state[k] = serializers[k].serialize(state[k], this);\n                }\n                else {\n                    // the default serializer just deep-copies the object\n                    state[k] = JSON.parse(JSON.stringify(state[k]));\n                }\n                if (state[k] && state[k].toJSON) {\n                    state[k] = state[k].toJSON();\n                }\n            }\n            catch (e) {\n                console.error('Error serializing widget state attribute: ', k);\n                throw e;\n            }\n        }\n        return state;\n    };\n    /**\n     * Send a sync message to the kernel.\n     */\n    WidgetModel.prototype.send_sync_message = function (state, callbacks) {\n        var _this = this;\n        if (callbacks === void 0) { callbacks = {}; }\n        if (!this.comm) {\n            return '';\n        }\n        try {\n            // Make a 2-deep copy so we don't modify the caller's callbacks object.\n            callbacks = {\n                shell: __assign({}, callbacks.shell),\n                iopub: __assign({}, callbacks.iopub),\n                input: callbacks.input,\n            };\n            // Save the caller's status callback so we can call it after we handle the message.\n            var statuscb_1 = callbacks.iopub.status;\n            callbacks.iopub.status = function (msg) {\n                _this._handle_status(msg);\n                if (statuscb_1) {\n                    statuscb_1(msg);\n                }\n            };\n            // split out the binary buffers\n            var split = utils.remove_buffers(state);\n            var msgId = this.comm.send({\n                method: 'update',\n                state: split.state,\n                buffer_paths: split.buffer_paths\n            }, callbacks, {}, split.buffers);\n            this._pending_msgs++;\n            return msgId;\n        }\n        catch (e) {\n            console.error('Could not send widget sync message', e);\n        }\n        return '';\n    };\n    /**\n     * Push this model's state to the back-end\n     *\n     * This invokes a Backbone.Sync.\n     */\n    WidgetModel.prototype.save_changes = function (callbacks) {\n        if (this.comm_live) {\n            var options = { patch: true };\n            if (callbacks) {\n                options.callbacks = callbacks;\n            }\n            this.save(this._buffered_state_diff, options);\n            this._buffered_state_diff = {};\n        }\n    };\n    /**\n     * on_some_change(['key1', 'key2'], foo, context) differs from\n     * on('change:key1 change:key2', foo, context).\n     * If the widget attributes key1 and key2 are both modified,\n     * the second form will result in foo being called twice\n     * while the first will call foo only once.\n     */\n    WidgetModel.prototype.on_some_change = function (keys, callback, context) {\n        var scope = this;\n        this.on('change', function () {\n            if (keys.some(scope.hasChanged, scope)) {\n                callback.apply(context, arguments);\n            }\n        }, this);\n    };\n    /**\n     * Serialize the model.  See the deserialization function at the top of this file\n     * and the kernel-side serializer/deserializer.\n     */\n    WidgetModel.prototype.toJSON = function (options) {\n        return \"IPY_MODEL_\" + this.model_id;\n    };\n    /**\n     * Returns a promise for the deserialized state. The second argument\n     * is an instance of widget manager, which is required for the\n     * deserialization of widget models.\n     */\n    WidgetModel._deserialize_state = function (state, manager) {\n        var serializers = this.serializers;\n        var deserialized;\n        if (serializers) {\n            deserialized = {};\n            for (var k in state) {\n                if (serializers[k] && serializers[k].deserialize) {\n                    deserialized[k] = (serializers[k].deserialize)(state[k], manager);\n                }\n                else {\n                    deserialized[k] = state[k];\n                }\n            }\n        }\n        else {\n            deserialized = state;\n        }\n        return utils.resolvePromisesDict(deserialized);\n    };\n    return WidgetModel;\n}(Backbone.Model));\nexport { WidgetModel };\nvar DOMWidgetModel = /** @class */ (function (_super) {\n    __extends(DOMWidgetModel, _super);\n    function DOMWidgetModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    DOMWidgetModel.prototype.defaults = function () {\n        return utils.assign(_super.prototype.defaults.call(this), {\n            _dom_classes: []\n            // We do not declare defaults for the layout and style attributes.\n            // Those defaults are constructed on the kernel side and synced here\n            // as needed, and our code here copes with those attributes being\n            // undefined. See\n            // https://github.com/jupyter-widgets/ipywidgets/issues/1620 and\n            // https://github.com/jupyter-widgets/ipywidgets/pull/1621\n        });\n    };\n    DOMWidgetModel.serializers = __assign(__assign({}, WidgetModel.serializers), { layout: { deserialize: unpack_models }, style: { deserialize: unpack_models } });\n    return DOMWidgetModel;\n}(WidgetModel));\nexport { DOMWidgetModel };\nvar WidgetView = /** @class */ (function (_super) {\n    __extends(WidgetView, _super);\n    /**\n     * Public constructor.\n     */\n    function WidgetView(options) {\n        return _super.call(this, options) || this;\n    }\n    /**\n     * Initializer, called at the end of the constructor.\n     */\n    WidgetView.prototype.initialize = function (parameters) {\n        var _this = this;\n        this.listenTo(this.model, 'change', function () {\n            var changed = Object.keys(_this.model.changedAttributes() || {});\n            if (changed[0] === '_view_count' && changed.length === 1) {\n                // Just the view count was updated\n                return;\n            }\n            _this.update();\n        });\n        this.options = parameters.options;\n        this.once('remove', function () {\n            if (typeof (_this.model.get('_view_count')) === 'number') {\n                _this.model.set('_view_count', _this.model.get('_view_count') - 1);\n                _this.model.save_changes();\n            }\n        });\n        this.once('displayed', function () {\n            if (typeof (_this.model.get('_view_count')) === 'number') {\n                _this.model.set('_view_count', _this.model.get('_view_count') + 1);\n                _this.model.save_changes();\n            }\n        });\n        this.displayed = new Promise(function (resolve, reject) {\n            _this.once('displayed', resolve);\n        });\n    };\n    /**\n     * Triggered on model change.\n     *\n     * Update view to be consistent with this.model\n     */\n    WidgetView.prototype.update = function (options) {\n        return;\n    };\n    /**\n     * Render a view\n     *\n     * @returns the view or a promise to the view.\n     */\n    WidgetView.prototype.render = function () {\n        return;\n    };\n    /**\n     * Create and promise that resolves to a child view of a given model\n     */\n    WidgetView.prototype.create_child_view = function (child_model, options) {\n        if (options === void 0) { options = {}; }\n        options = __assign({ parent: this }, options);\n        return this.model.widget_manager.create_view(child_model, options)\n            .catch(utils.reject('Could not create child view', true));\n    };\n    /**\n     * Create msg callbacks for a comm msg.\n     */\n    WidgetView.prototype.callbacks = function () {\n        return this.model.callbacks(this);\n    };\n    /**\n     * Send a custom msg associated with this view.\n     */\n    WidgetView.prototype.send = function (content, buffers) {\n        this.model.send(content, this.callbacks(), buffers);\n    };\n    WidgetView.prototype.touch = function () {\n        this.model.save_changes(this.callbacks());\n    };\n    WidgetView.prototype.remove = function () {\n        // Raise a remove event when the view is removed.\n        _super.prototype.remove.call(this);\n        this.trigger('remove');\n        return this;\n    };\n    return WidgetView;\n}(NativeView));\nexport { WidgetView };\nvar JupyterPhosphorWidget = /** @class */ (function (_super) {\n    __extends(JupyterPhosphorWidget, _super);\n    function JupyterPhosphorWidget(options) {\n        var _this = this;\n        var view = options.view;\n        delete options.view;\n        _this = _super.call(this, options) || this;\n        _this._view = view;\n        return _this;\n    }\n    /**\n     * Dispose the widget.\n     *\n     * This causes the view to be destroyed as well with 'remove'\n     */\n    JupyterPhosphorWidget.prototype.dispose = function () {\n        if (this.isDisposed) {\n            return;\n        }\n        _super.prototype.dispose.call(this);\n        if (this._view) {\n            this._view.remove();\n        }\n        this._view = null;\n    };\n    /**\n     * Process the phosphor message.\n     *\n     * Any custom phosphor widget used inside a Jupyter widget should override\n     * the processMessage function like this.\n     */\n    JupyterPhosphorWidget.prototype.processMessage = function (msg) {\n        _super.prototype.processMessage.call(this, msg);\n        this._view.processPhosphorMessage(msg);\n    };\n    return JupyterPhosphorWidget;\n}(Widget));\nexport { JupyterPhosphorWidget };\nvar JupyterPhosphorPanelWidget = /** @class */ (function (_super) {\n    __extends(JupyterPhosphorPanelWidget, _super);\n    function JupyterPhosphorPanelWidget(options) {\n        var _this = this;\n        var view = options.view;\n        delete options.view;\n        _this = _super.call(this, options) || this;\n        _this._view = view;\n        return _this;\n    }\n    /**\n     * Process the phosphor message.\n     *\n     * Any custom phosphor widget used inside a Jupyter widget should override\n     * the processMessage function like this.\n     */\n    JupyterPhosphorPanelWidget.prototype.processMessage = function (msg) {\n        _super.prototype.processMessage.call(this, msg);\n        this._view.processPhosphorMessage(msg);\n    };\n    /**\n     * Dispose the widget.\n     *\n     * This causes the view to be destroyed as well with 'remove'\n     */\n    JupyterPhosphorPanelWidget.prototype.dispose = function () {\n        if (this.isDisposed) {\n            return;\n        }\n        _super.prototype.dispose.call(this);\n        if (this._view) {\n            this._view.remove();\n        }\n        this._view = null;\n    };\n    return JupyterPhosphorPanelWidget;\n}(Panel));\nexport { JupyterPhosphorPanelWidget };\nvar DOMWidgetView = /** @class */ (function (_super) {\n    __extends(DOMWidgetView, _super);\n    function DOMWidgetView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Public constructor\n     */\n    DOMWidgetView.prototype.initialize = function (parameters) {\n        var _this = this;\n        _super.prototype.initialize.call(this, parameters);\n        this.listenTo(this.model, 'change:_dom_classes', function (model, new_classes) {\n            var old_classes = model.previous('_dom_classes');\n            _this.update_classes(old_classes, new_classes);\n        });\n        this.layoutPromise = Promise.resolve();\n        this.listenTo(this.model, 'change:layout', function (model, value) {\n            _this.setLayout(value, model.previous('layout'));\n        });\n        this.stylePromise = Promise.resolve();\n        this.listenTo(this.model, 'change:style', function (model, value) {\n            _this.setStyle(value, model.previous('style'));\n        });\n        this.displayed.then(function () {\n            _this.update_classes([], _this.model.get('_dom_classes'));\n            _this.setLayout(_this.model.get('layout'));\n            _this.setStyle(_this.model.get('style'));\n        });\n        this._comm_live_update();\n        this.listenTo(this.model, 'comm_live_update', function () {\n            _this._comm_live_update();\n        });\n    };\n    DOMWidgetView.prototype.setLayout = function (layout, oldLayout) {\n        var _this = this;\n        if (layout) {\n            this.layoutPromise = this.layoutPromise.then(function (oldLayoutView) {\n                if (oldLayoutView) {\n                    oldLayoutView.unlayout();\n                    _this.stopListening(oldLayoutView.model);\n                    oldLayoutView.remove();\n                }\n                return _this.create_child_view(layout).then(function (view) {\n                    // Trigger the displayed event of the child view.\n                    return _this.displayed.then(function () {\n                        view.trigger('displayed');\n                        _this.listenTo(view.model, 'change', function () {\n                            // Post (asynchronous) so layout changes can take\n                            // effect first.\n                            MessageLoop.postMessage(_this.pWidget, Widget.ResizeMessage.UnknownSize);\n                        });\n                        MessageLoop.postMessage(_this.pWidget, Widget.ResizeMessage.UnknownSize);\n                        return view;\n                    });\n                }).catch(utils.reject('Could not add LayoutView to DOMWidgetView', true));\n            });\n        }\n    };\n    DOMWidgetView.prototype.setStyle = function (style, oldStyle) {\n        var _this = this;\n        if (style) {\n            this.stylePromise = this.stylePromise.then(function (oldStyleView) {\n                if (oldStyleView) {\n                    oldStyleView.unstyle();\n                    _this.stopListening(oldStyleView.model);\n                    oldStyleView.remove();\n                }\n                return _this.create_child_view(style).then(function (view) {\n                    // Trigger the displayed event of the child view.\n                    return _this.displayed.then(function () {\n                        view.trigger('displayed');\n                        // Unlike for the layout attribute, style changes don't\n                        // trigger phosphor resize messages.\n                        return view;\n                    });\n                }).catch(utils.reject('Could not add styleView to DOMWidgetView', true));\n            });\n        }\n    };\n    /**\n     * Update the DOM classes applied to an element, default to this.el.\n     */\n    DOMWidgetView.prototype.update_classes = function (old_classes, new_classes, el) {\n        if (el === undefined) {\n            el = this.el;\n        }\n        utils.difference(old_classes, new_classes).map(function (c) {\n            if (el.classList) { // classList is not supported by IE for svg elements\n                el.classList.remove(c);\n            }\n            else {\n                el.setAttribute('class', el.getAttribute('class').replace(c, ''));\n            }\n        });\n        utils.difference(new_classes, old_classes).map(function (c) {\n            if (el.classList) { // classList is not supported by IE for svg elements\n                el.classList.add(c);\n            }\n            else {\n                el.setAttribute('class', el.getAttribute('class').concat(' ', c));\n            }\n        });\n    };\n    /**\n     * Update the DOM classes applied to the widget based on a single\n     * trait's value.\n     *\n     * Given a trait value classes map, this function automatically\n     * handles applying the appropriate classes to the widget element\n     * and removing classes that are no longer valid.\n     *\n     * Parameters\n     * ----------\n     * class_map: dictionary\n     *  Dictionary of trait values to class lists.\n     *  Example:\n     *      {\n     *          success: ['alert', 'alert-success'],\n     *          info: ['alert', 'alert-info'],\n     *          warning: ['alert', 'alert-warning'],\n     *          danger: ['alert', 'alert-danger']\n     *      };\n     * trait_name: string\n     *  Name of the trait to check the value of.\n     * el: optional DOM element handle, defaults to this.el\n     *  Element that the classes are applied to.\n     */\n    DOMWidgetView.prototype.update_mapped_classes = function (class_map, trait_name, el) {\n        var key = this.model.previous(trait_name);\n        var old_classes = class_map[key] ? class_map[key] : [];\n        key = this.model.get(trait_name);\n        var new_classes = class_map[key] ? class_map[key] : [];\n        this.update_classes(old_classes, new_classes, el || this.el);\n    };\n    DOMWidgetView.prototype.set_mapped_classes = function (class_map, trait_name, el) {\n        var key = this.model.get(trait_name);\n        var new_classes = class_map[key] ? class_map[key] : [];\n        this.update_classes([], new_classes, el || this.el);\n    };\n    DOMWidgetView.prototype._setElement = function (el) {\n        if (this.pWidget) {\n            this.pWidget.dispose();\n        }\n        this.$el = el instanceof $ ? el : $(el);\n        this.el = this.$el[0];\n        this.pWidget = new JupyterPhosphorWidget({\n            node: el,\n            view: this\n        });\n    };\n    DOMWidgetView.prototype.remove = function () {\n        if (this.pWidget) {\n            this.pWidget.dispose();\n        }\n        return _super.prototype.remove.call(this);\n    };\n    DOMWidgetView.prototype.processPhosphorMessage = function (msg) {\n        // tslint:disable-next-line:switch-default\n        switch (msg.type) {\n            case 'after-attach':\n                this.trigger('displayed');\n                break;\n        }\n    };\n    DOMWidgetView.prototype._comm_live_update = function () {\n        if (this.model.comm_live) {\n            this.pWidget.removeClass('jupyter-widgets-disconnected');\n        }\n        else {\n            this.pWidget.addClass('jupyter-widgets-disconnected');\n        }\n    };\n    return DOMWidgetView;\n}(WidgetView));\nexport { DOMWidgetView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {\n    function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\n    return new (P || (P = Promise))(function (resolve, reject) {\n        function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\n        function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\n        function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\n        step((generator = generator.apply(thisArg, _arguments || [])).next());\n    });\n};\nvar __generator = (this && this.__generator) || function (thisArg, body) {\n    var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\n    return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\n    function verb(n) { return function (v) { return step([n, v]); }; }\n    function step(op) {\n        if (f) throw new TypeError(\"Generator is already executing.\");\n        while (_) try {\n            if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\n            if (y = 0, t) op = [op[0] & 2, t.value];\n            switch (op[0]) {\n                case 0: case 1: t = op; break;\n                case 4: _.label++; return { value: op[1], done: false };\n                case 5: _.label++; y = op[1]; op = [0]; continue;\n                case 7: op = _.ops.pop(); _.trys.pop(); continue;\n                default:\n                    if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\n                    if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\n                    if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\n                    if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\n                    if (t[2]) _.ops.pop();\n                    _.trys.pop(); continue;\n            }\n            op = body.call(thisArg, _);\n        } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\n        if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\n    }\n};\nexport var shims;\n(function (shims) {\n    var services;\n    (function (services) {\n        /**\n         * Public constructor\n         * @param jsServicesKernel - @jupyterlab/services Kernel.IKernel instance\n         */\n        var CommManager = /** @class */ (function () {\n            function CommManager(jsServicesKernel) {\n                this.targets = Object.create(null);\n                this.comms = Object.create(null);\n                this.kernel = null;\n                this.jsServicesKernel = null;\n                this.init_kernel(jsServicesKernel);\n            }\n            /**\n             * Hookup kernel events.\n             * @param  {Kernel.IKernel} jsServicesKernel - @jupyterlab/services Kernel.IKernel instance\n             */\n            CommManager.prototype.init_kernel = function (jsServicesKernel) {\n                this.kernel = jsServicesKernel; // These aren't really the same.\n                this.jsServicesKernel = jsServicesKernel;\n            };\n            /**\n             * Creates a new connected comm\n             */\n            CommManager.prototype.new_comm = function (target_name, data, callbacks, metadata, comm_id, buffers) {\n                return __awaiter(this, void 0, void 0, function () {\n                    var c, comm;\n                    return __generator(this, function (_a) {\n                        c = this.jsServicesKernel.createComm(target_name, comm_id);\n                        comm = new Comm(c);\n                        this.register_comm(comm);\n                        comm.open(data, callbacks, metadata, buffers);\n                        return [2 /*return*/, comm];\n                    });\n                });\n            };\n            /**\n             * Register a comm target\n             * @param  {string} target_name\n             * @param  {(Comm, object) => void} f - callback that is called when the\n             *                         comm is made.  Signature of f(comm, msg).\n             */\n            CommManager.prototype.register_target = function (target_name, f) {\n                var _this = this;\n                var handle = this.jsServicesKernel.registerCommTarget(target_name, function (jsServicesComm, msg) {\n                    // Create the comm.\n                    var comm = new Comm(jsServicesComm);\n                    _this.register_comm(comm);\n                    // Call the callback for the comm.\n                    try {\n                        return f(comm, msg);\n                    }\n                    catch (e) {\n                        comm.close();\n                        console.error(e);\n                        console.error(new Error('Exception opening new comm'));\n                    }\n                });\n                this.targets[target_name] = handle;\n            };\n            /**\n             * Unregisters a comm target\n             * @param  {string} target_name\n             */\n            CommManager.prototype.unregister_target = function (target_name, f) {\n                var handle = this.targets[target_name];\n                handle.dispose();\n                delete this.targets[target_name];\n            };\n            /**\n             * Register a comm in the mapping\n             */\n            CommManager.prototype.register_comm = function (comm) {\n                this.comms[comm.comm_id] = Promise.resolve(comm);\n                comm.kernel = this.kernel;\n                return comm.comm_id;\n            };\n            return CommManager;\n        }());\n        services.CommManager = CommManager;\n        /**\n         * Public constructor\n         * @param  {IComm} jsServicesComm - @jupyterlab/services IComm instance\n         */\n        var Comm = /** @class */ (function () {\n            function Comm(jsServicesComm) {\n                this.jsServicesComm = null;\n                this.kernel = null;\n                this.jsServicesComm = jsServicesComm;\n            }\n            Object.defineProperty(Comm.prototype, \"comm_id\", {\n                /**\n                 * Comm id\n                 * @return {string}\n                 */\n                get: function () {\n                    return this.jsServicesComm.commId;\n                },\n                enumerable: true,\n                configurable: true\n            });\n            Object.defineProperty(Comm.prototype, \"target_name\", {\n                /**\n                 * Target name\n                 * @return {string}\n                 */\n                get: function () {\n                    return this.jsServicesComm.targetName;\n                },\n                enumerable: true,\n                configurable: true\n            });\n            /**\n             * Opens a sibling comm in the backend\n             * @param  data\n             * @param  callbacks\n             * @param  metadata\n             * @return msg id\n             */\n            Comm.prototype.open = function (data, callbacks, metadata, buffers) {\n                var future = this.jsServicesComm.open(data, metadata, buffers);\n                this._hookupCallbacks(future, callbacks);\n                return future.msg.header.msg_id;\n            };\n            /**\n             * Sends a message to the sibling comm in the backend\n             * @param  data\n             * @param  callbacks\n             * @param  metadata\n             * @param  buffers\n             * @return message id\n             */\n            Comm.prototype.send = function (data, callbacks, metadata, buffers) {\n                var future = this.jsServicesComm.send(data, metadata, buffers);\n                this._hookupCallbacks(future, callbacks);\n                return future.msg.header.msg_id;\n            };\n            /**\n             * Closes the sibling comm in the backend\n             * @param  data\n             * @param  callbacks\n             * @param  metadata\n             * @return msg id\n             */\n            Comm.prototype.close = function (data, callbacks, metadata, buffers) {\n                var future = this.jsServicesComm.close(data, metadata, buffers);\n                this._hookupCallbacks(future, callbacks);\n                return future.msg.header.msg_id;\n            };\n            /**\n             * Register a message handler\n             * @param  callback, which is given a message\n             */\n            Comm.prototype.on_msg = function (callback) {\n                this.jsServicesComm.onMsg = callback.bind(this);\n            };\n            /**\n             * Register a handler for when the comm is closed by the backend\n             * @param  callback, which is given a message\n             */\n            Comm.prototype.on_close = function (callback) {\n                this.jsServicesComm.onClose = callback.bind(this);\n            };\n            /**\n             * Hooks callback object up with @jupyterlab/services IKernelFuture\n             * @param  @jupyterlab/services IKernelFuture instance\n             * @param  callbacks\n             */\n            Comm.prototype._hookupCallbacks = function (future, callbacks) {\n                if (callbacks) {\n                    future.onReply = function (msg) {\n                        if (callbacks.shell && callbacks.shell.reply) {\n                            callbacks.shell.reply(msg);\n                        }\n                        // TODO: Handle payloads.  See https://github.com/jupyter/notebook/blob/master/notebook/static/services/kernels/kernel.js#L923-L947\n                    };\n                    future.onStdin = function (msg) {\n                        if (callbacks.input) {\n                            callbacks.input(msg);\n                        }\n                    };\n                    future.onIOPub = function (msg) {\n                        if (callbacks.iopub) {\n                            if (callbacks.iopub.status && msg.header.msg_type === 'status') {\n                                callbacks.iopub.status(msg);\n                            }\n                            else if (callbacks.iopub.clear_output && msg.header.msg_type === 'clear_output') {\n                                callbacks.iopub.clear_output(msg);\n                            }\n                            else if (callbacks.iopub.output) {\n                                switch (msg.header.msg_type) {\n                                    case 'display_data':\n                                    case 'execute_result':\n                                    case 'stream':\n                                    case 'error':\n                                        callbacks.iopub.output(msg);\n                                        break;\n                                    default: break;\n                                }\n                            }\n                        }\n                    };\n                }\n            };\n            return Comm;\n        }());\n        services.Comm = Comm;\n    })(services = shims.services || (shims.services = {}));\n})(shims || (shims = {}));\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nimport { assign } from './utils';\nimport { WidgetModel, WidgetView } from './widget';\n/**\n * css properties exposed by the layout widget with their default values.\n */\nvar css_properties = {\n    align_content: null,\n    align_items: null,\n    align_self: null,\n    border: null,\n    bottom: null,\n    display: null,\n    flex: null,\n    flex_flow: null,\n    height: null,\n    justify_content: null,\n    justify_items: null,\n    left: null,\n    margin: null,\n    max_height: null,\n    max_width: null,\n    min_height: null,\n    min_width: null,\n    overflow: null,\n    overflow_x: null,\n    overflow_y: null,\n    order: null,\n    padding: null,\n    right: null,\n    top: null,\n    visibility: null,\n    width: null,\n    // image-specific\n    object_fit: null,\n    object_position: null,\n    // container\n    grid_auto_columns: null,\n    grid_auto_flow: null,\n    grid_auto_rows: null,\n    grid_gap: null,\n    grid_template_rows: null,\n    grid_template_columns: null,\n    grid_template_areas: null,\n    // items\n    grid_row: null,\n    grid_column: null,\n    grid_area: null\n};\nvar LayoutModel = /** @class */ (function (_super) {\n    __extends(LayoutModel, _super);\n    function LayoutModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    LayoutModel.prototype.defaults = function () {\n        return assign(_super.prototype.defaults.call(this), {\n            _model_name: 'LayoutModel',\n            _view_name: 'LayoutView'\n        }, css_properties);\n    };\n    return LayoutModel;\n}(WidgetModel));\nexport { LayoutModel };\nvar LayoutView = /** @class */ (function (_super) {\n    __extends(LayoutView, _super);\n    function LayoutView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Public constructor\n     */\n    LayoutView.prototype.initialize = function (parameters) {\n        this._traitNames = [];\n        _super.prototype.initialize.call(this, parameters);\n        // Register the traits that live on the Python side\n        for (var _i = 0, _a = Object.keys(css_properties); _i < _a.length; _i++) {\n            var key = _a[_i];\n            this.registerTrait(key);\n        }\n    };\n    /**\n     * Register a CSS trait that is known by the model\n     * @param trait\n     */\n    LayoutView.prototype.registerTrait = function (trait) {\n        var _this = this;\n        this._traitNames.push(trait);\n        // Treat overflow_x and overflow_y as a special case since they are deprecated\n        // and interact in special ways with the overflow attribute.\n        if (trait === 'overflow_x' || trait === 'overflow_y') {\n            // Listen to changes, and set the value on change.\n            this.listenTo(this.model, 'change:' + trait, function (model, value) {\n                _this.handleOverflowChange(trait, value);\n            });\n            // Set the initial value on display.\n            this.handleOverflowChange(trait, this.model.get(trait));\n            return;\n        }\n        // Listen to changes, and set the value on change.\n        this.listenTo(this.model, 'change:' + trait, function (model, value) {\n            _this.handleChange(trait, value);\n        });\n        // Set the initial value on display.\n        this.handleChange(trait, this.model.get(trait));\n    };\n    /**\n     * Get the the name of the css property from the trait name\n     * @param  model attribute name\n     * @return css property name\n     */\n    LayoutView.prototype.css_name = function (trait) {\n        return trait.replace(/_/g, '-');\n    };\n    /**\n     * Handles when a trait value changes\n     */\n    LayoutView.prototype.handleChange = function (trait, value) {\n        // should be synchronous so that we can measure later.\n        var parent = this.options.parent;\n        if (parent) {\n            if (value === null) {\n                parent.el.style.removeProperty(this.css_name(trait));\n            }\n            else {\n                parent.el.style[this.css_name(trait)] = value;\n            }\n        }\n        else {\n            console.warn('Style not applied because a parent view does not exist');\n        }\n    };\n    /**\n     * Handles when the value of overflow_x or overflow_y changes\n     */\n    LayoutView.prototype.handleOverflowChange = function (trait, value) {\n        // This differs from the default handleChange method\n        // in that setting `overflow_x` or `overflow_y` to null\n        // when `overflow` is null removes the attribute.\n        var parent = this.options.parent;\n        if (parent) {\n            if (value === null) {\n                if (this.model.get('overflow') === null) {\n                    parent.el.style.removeProperty(this.css_name(trait));\n                }\n            }\n            else {\n                parent.el.style[this.css_name(trait)] = value;\n            }\n        }\n        else {\n            console.warn('Style not applied because a parent view does not exist');\n        }\n    };\n    /**\n     * Remove the styling from the parent view.\n     */\n    LayoutView.prototype.unlayout = function () {\n        var _this = this;\n        var parent = this.options.parent;\n        this._traitNames.forEach(function (trait) {\n            if (parent) {\n                parent.el.style.removeProperty(_this.css_name(trait));\n            }\n            else {\n                console.warn('Style not removed because a parent view does not exist');\n            }\n        }, this);\n    };\n    return LayoutView;\n}(WidgetView));\nexport { LayoutView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nimport { assign } from './utils';\nimport { WidgetModel, WidgetView } from './widget';\nvar StyleModel = /** @class */ (function (_super) {\n    __extends(StyleModel, _super);\n    function StyleModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    StyleModel.prototype.defaults = function () {\n        var Derived = this.constructor;\n        return assign(_super.prototype.defaults.call(this), {\n            _model_name: 'StyleModel',\n            _view_name: 'StyleView',\n        }, Object.keys(Derived.styleProperties).reduce(function (obj, key) {\n            obj[key] = Derived.styleProperties[key].default;\n            return obj;\n        }, {}));\n    };\n    StyleModel.styleProperties = {};\n    return StyleModel;\n}(WidgetModel));\nexport { StyleModel };\nvar StyleView = /** @class */ (function (_super) {\n    __extends(StyleView, _super);\n    function StyleView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Public constructor\n     */\n    StyleView.prototype.initialize = function (parameters) {\n        this._traitNames = [];\n        _super.prototype.initialize.call(this, parameters);\n        // Register the traits that live on the Python side\n        var ModelType = this.model.constructor;\n        for (var _i = 0, _a = Object.keys(ModelType.styleProperties); _i < _a.length; _i++) {\n            var key = _a[_i];\n            this.registerTrait(key);\n        }\n        // Set the initial styles\n        this.style();\n    };\n    /**\n     * Register a CSS trait that is known by the model\n     * @param trait\n     */\n    StyleView.prototype.registerTrait = function (trait) {\n        var _this = this;\n        this._traitNames.push(trait);\n        // Listen to changes, and set the value on change.\n        this.listenTo(this.model, 'change:' + trait, function (model, value) {\n            _this.handleChange(trait, value);\n        });\n    };\n    /**\n     * Handles when a trait value changes\n     */\n    StyleView.prototype.handleChange = function (trait, value) {\n        // should be synchronous so that we can measure later.\n        var parent = this.options.parent;\n        if (parent) {\n            var ModelType = this.model.constructor;\n            var styleProperties = ModelType.styleProperties;\n            var attribute = styleProperties[trait].attribute;\n            var selector = styleProperties[trait].selector;\n            var elements = selector ? parent.el.querySelectorAll(selector) : [parent.el];\n            if (value === null) {\n                for (var i = 0; i !== elements.length; ++i) {\n                    elements[i].style.removeProperty(attribute);\n                }\n            }\n            else {\n                for (var i = 0; i !== elements.length; ++i) {\n                    elements[i].style[attribute] = value;\n                }\n            }\n        }\n        else {\n            console.warn('Style not applied because a parent view does not exist');\n        }\n    };\n    /**\n     * Apply styles for all registered traits\n     */\n    StyleView.prototype.style = function () {\n        for (var _i = 0, _a = this._traitNames; _i < _a.length; _i++) {\n            var trait = _a[_i];\n            this.handleChange(trait, this.model.get(trait));\n        }\n    };\n    /**\n     * Remove the styling from the parent view.\n     */\n    StyleView.prototype.unstyle = function () {\n        var parent = this.options.parent;\n        var ModelType = this.model.constructor;\n        var styleProperties = ModelType.styleProperties;\n        this._traitNames.forEach(function (trait) {\n            if (parent) {\n                var attribute = styleProperties[trait].attribute;\n                var selector = styleProperties[trait].selector;\n                var elements = selector ? parent.el.querySelectorAll(selector) : [parent.el];\n                for (var i = 0; i !== elements.length; ++i) {\n                    elements[i].style.removeProperty(attribute);\n                }\n            }\n            else {\n                console.warn('Style not removed because a parent view does not exist');\n            }\n        }, this);\n    };\n    return StyleView;\n}(WidgetView));\nexport { StyleView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/**\n * - create_view and remove_view are default functions called when adding or removing views\n * - create_view takes a model and an index and returns a view or a promise for a view for that model\n * - remove_view takes a view and destroys it (including calling `view.remove()`)\n * - each time the update() function is called with a new list, the create and remove\n *   callbacks will be called in an order so that if you append the views created in the\n *   create callback and remove the views in the remove callback, you will duplicate\n *   the order of the list.\n * - the remove callback defaults to just removing the view (e.g., pass in null for the second parameter)\n * - the context defaults to the created ViewList.  If you pass another context, the create and remove\n *   will be called in that context.\n */\nvar ViewList = /** @class */ (function () {\n    function ViewList(create_view, remove_view, context) {\n        this.initialize(create_view, remove_view, context);\n    }\n    ViewList.prototype.initialize = function (create_view, remove_view, context) {\n        this._handler_context = context || this;\n        this._models = [];\n        this.views = []; // list of promises for views\n        this._create_view = create_view;\n        this._remove_view = remove_view || function (view) { view.remove(); };\n    };\n    /**\n     * the create_view, remove_view, and context arguments override the defaults\n     * specified when the list is created.\n     * after this function, the .views attribute is a list of promises for views\n     * if you want to perform some action on the list of views, do something like\n     * `Promise.all(myviewlist.views).then(function(views) {...});`\n     */\n    ViewList.prototype.update = function (new_models, create_view, remove_view, context) {\n        var remove = remove_view || this._remove_view;\n        var create = create_view || this._create_view;\n        context = context || this._handler_context;\n        var i = 0;\n        // first, skip past the beginning of the lists if they are identical\n        for (; i < new_models.length; i++) {\n            if (i >= this._models.length || new_models[i] !== this._models[i]) {\n                break;\n            }\n        }\n        var first_removed = i;\n        // Remove the non-matching items from the old list.\n        var removed = this.views.splice(first_removed, this.views.length - first_removed);\n        for (var j = 0; j < removed.length; j++) {\n            removed[j].then(function (view) {\n                remove.call(context, view);\n            });\n        }\n        // Add the rest of the new list items.\n        for (; i < new_models.length; i++) {\n            this.views.push(Promise.resolve(create.call(context, new_models[i], i)));\n        }\n        // make a copy of the input array\n        this._models = new_models.slice();\n        // return a promise that resolves to all of the resolved views\n        return Promise.all(this.views);\n    };\n    /**\n     * removes every view in the list; convenience function for `.update([])`\n     * that should be faster\n     * returns a promise that resolves after this removal is done\n     */\n    ViewList.prototype.remove = function () {\n        var _this = this;\n        return Promise.all(this.views).then(function (views) {\n            views.forEach(function (value) { return _this._remove_view.call(_this._handler_context, value); });\n            _this.views = [];\n            _this._models = [];\n        });\n    };\n    /**\n     * Dispose this viewlist.\n     *\n     * A synchronous function which just deletes references to child views. This\n     * function does not call .remove() on child views because that is\n     * asynchronous. Use this in cases where child views will be removed in\n     * another way.\n     */\n    ViewList.prototype.dispose = function () {\n        this.views = null;\n        this._models = null;\n    };\n    return ViewList;\n}());\nexport { ViewList };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nimport { Token } from '@lumino/coreutils';\n/**\n * A runtime interface token for a widget registry.\n */\nexport var IJupyterWidgetRegistry = new Token('jupyter.extensions.jupyterWidgetRegistry');\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2019, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * The namespace for clipboard related functionality.\n */\nvar ClipboardExt;\n(function (ClipboardExt) {\n    /**\n     * Copy text to the system clipboard.\n     *\n     * @param text - The text to copy to the clipboard.\n     */\n    function copyText(text) {\n        // Fetch the document body.\n        var body = document.body;\n        // Set up the clipboard event listener.\n        var handler = function (event) {\n            // Stop the event propagation.\n            event.preventDefault();\n            event.stopPropagation();\n            // Set the clipboard data.\n            event.clipboardData.setData('text', text);\n            // Remove the event listener.\n            body.removeEventListener('copy', handler, true);\n        };\n        // Add the event listener.\n        body.addEventListener('copy', handler, true);\n        // Trigger the event.\n        document.execCommand('copy');\n    }\n    ClipboardExt.copyText = copyText;\n})(ClipboardExt || (ClipboardExt = {}));\n\n// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * The namespace for element related utilities.\n */\nvar ElementExt;\n(function (ElementExt) {\n    /**\n     * Compute the box sizing for an element.\n     *\n     * @param element - The element of interest.\n     *\n     * @returns The box sizing data for the specified element.\n     */\n    function boxSizing(element) {\n        var style = window.getComputedStyle(element);\n        var bt = parseFloat(style.borderTopWidth) || 0;\n        var bl = parseFloat(style.borderLeftWidth) || 0;\n        var br = parseFloat(style.borderRightWidth) || 0;\n        var bb = parseFloat(style.borderBottomWidth) || 0;\n        var pt = parseFloat(style.paddingTop) || 0;\n        var pl = parseFloat(style.paddingLeft) || 0;\n        var pr = parseFloat(style.paddingRight) || 0;\n        var pb = parseFloat(style.paddingBottom) || 0;\n        var hs = bl + pl + pr + br;\n        var vs = bt + pt + pb + bb;\n        return {\n            borderTop: bt,\n            borderLeft: bl,\n            borderRight: br,\n            borderBottom: bb,\n            paddingTop: pt,\n            paddingLeft: pl,\n            paddingRight: pr,\n            paddingBottom: pb,\n            horizontalSum: hs,\n            verticalSum: vs\n        };\n    }\n    ElementExt.boxSizing = boxSizing;\n    /**\n     * Compute the size limits for an element.\n     *\n     * @param element - The element of interest.\n     *\n     * @returns The size limit data for the specified element.\n     */\n    function sizeLimits(element) {\n        var style = window.getComputedStyle(element);\n        var minWidth = parseFloat(style.minWidth) || 0;\n        var minHeight = parseFloat(style.minHeight) || 0;\n        var maxWidth = parseFloat(style.maxWidth) || Infinity;\n        var maxHeight = parseFloat(style.maxHeight) || Infinity;\n        maxWidth = Math.max(minWidth, maxWidth);\n        maxHeight = Math.max(minHeight, maxHeight);\n        return { minWidth: minWidth, minHeight: minHeight, maxWidth: maxWidth, maxHeight: maxHeight };\n    }\n    ElementExt.sizeLimits = sizeLimits;\n    /**\n     * Test whether a client position lies within an element.\n     *\n     * @param element - The DOM element of interest.\n     *\n     * @param clientX - The client X coordinate of interest.\n     *\n     * @param clientY - The client Y coordinate of interest.\n     *\n     * @returns Whether the point is within the given element.\n     */\n    function hitTest(element, clientX, clientY) {\n        var rect = element.getBoundingClientRect();\n        return (clientX >= rect.left &&\n            clientX < rect.right &&\n            clientY >= rect.top &&\n            clientY < rect.bottom);\n    }\n    ElementExt.hitTest = hitTest;\n    /**\n     * Vertically scroll an element into view if needed.\n     *\n     * @param area - The scroll area element.\n     *\n     * @param element - The element of interest.\n     *\n     * #### Notes\n     * This follows the \"nearest\" behavior of the native `scrollIntoView`\n     * method, which is not supported by all browsers.\n     * https://drafts.csswg.org/cssom-view/#element-scrolling-members\n     *\n     * If the element fully covers the visible area or is fully contained\n     * within the visible area, no scrolling will take place. Otherwise,\n     * the nearest edges of the area and element are aligned.\n     */\n    function scrollIntoViewIfNeeded(area, element) {\n        var ar = area.getBoundingClientRect();\n        var er = element.getBoundingClientRect();\n        if (er.top <= ar.top && er.bottom >= ar.bottom) {\n            return;\n        }\n        if (er.top < ar.top && er.height <= ar.height) {\n            area.scrollTop -= ar.top - er.top;\n            return;\n        }\n        if (er.bottom > ar.bottom && er.height >= ar.height) {\n            area.scrollTop -= ar.top - er.top;\n            return;\n        }\n        if (er.top < ar.top && er.height > ar.height) {\n            area.scrollTop -= ar.bottom - er.bottom;\n            return;\n        }\n        if (er.bottom > ar.bottom && er.height < ar.height) {\n            area.scrollTop -= ar.bottom - er.bottom;\n            return;\n        }\n    }\n    ElementExt.scrollIntoViewIfNeeded = scrollIntoViewIfNeeded;\n})(ElementExt || (ElementExt = {}));\n\n// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * The namespace for platform related utilities.\n */\nvar Platform;\n(function (Platform) {\n    /**\n     * A flag indicating whether the platform is Mac.\n     */\n    Platform.IS_MAC = !!navigator.platform.match(/Mac/i);\n    /**\n     * A flag indicating whether the platform is Windows.\n     */\n    Platform.IS_WIN = !!navigator.platform.match(/Win/i);\n    /**\n     * A flag indicating whether the browser is IE.\n     */\n    Platform.IS_IE = /Trident/.test(navigator.userAgent);\n    /**\n     * A flag indicating whether the browser is Edge.\n     */\n    Platform.IS_EDGE = /Edge/.test(navigator.userAgent);\n    /**\n     * Test whether the `accel` key is pressed.\n     *\n     * @param event - The keyboard or mouse event of interest.\n     *\n     * @returns Whether the `accel` key is pressed.\n     *\n     * #### Notes\n     * On Mac the `accel` key is the command key. On all other\n     * platforms the `accel` key is the control key.\n     */\n    function accelKey(event) {\n        return Platform.IS_MAC ? event.metaKey : event.ctrlKey;\n    }\n    Platform.accelKey = accelKey;\n})(Platform || (Platform = {}));\n\n// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * The namespace for selector related utilities.\n */\nvar Selector;\n(function (Selector) {\n    /**\n     * Calculate the specificity of a single CSS selector.\n     *\n     * @param selector - The CSS selector of interest.\n     *\n     * @returns The specificity of the selector.\n     *\n     * #### Undefined Behavior\n     * The selector is invalid.\n     *\n     * #### Notes\n     * This is based on https://www.w3.org/TR/css3-selectors/#specificity\n     *\n     * A larger number represents a more specific selector.\n     *\n     * The smallest possible specificity is `0`.\n     *\n     * The result is represented as a hex number `0x<aa><bb><cc>` where\n     * each component is the count of the respective selector clause.\n     *\n     * If the selector contains commas, only the first clause is used.\n     *\n     * The computed result is cached, so subsequent calculations for the\n     * same selector are extremely fast.\n     */\n    function calculateSpecificity(selector) {\n        if (selector in Private.specificityCache) {\n            return Private.specificityCache[selector];\n        }\n        var result = Private.calculateSingle(selector);\n        return Private.specificityCache[selector] = result;\n    }\n    Selector.calculateSpecificity = calculateSpecificity;\n    /**\n     * Test whether a selector is a valid CSS selector.\n     *\n     * @param selector - The CSS selector of interest.\n     *\n     * @returns `true` if the selector is valid, `false` otherwise.\n     *\n     * #### Notes\n     * The computed result is cached, so subsequent tests for the same\n     * selector are extremely fast.\n     */\n    function isValid(selector) {\n        if (selector in Private.validityCache) {\n            return Private.validityCache[selector];\n        }\n        var result = true;\n        try {\n            Private.testElem.querySelector(selector);\n        }\n        catch (err) {\n            result = false;\n        }\n        return Private.validityCache[selector] = result;\n    }\n    Selector.isValid = isValid;\n    /**\n     * Test whether an element matches a CSS selector.\n     *\n     * @param element - The element of interest.\n     *\n     * @param selector - The valid CSS selector of interest.\n     *\n     * @returns `true` if the element is a match, `false` otherwise.\n     *\n     * #### Notes\n     * This function uses the builtin browser capabilities when possible,\n     * falling back onto a document query otherwise.\n     */\n    function matches(element, selector) {\n        return Private.protoMatchFunc.call(element, selector);\n    }\n    Selector.matches = matches;\n})(Selector || (Selector = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private;\n(function (Private) {\n    /**\n     * A cache of computed selector specificity values.\n     */\n    Private.specificityCache = Object.create(null);\n    /**\n     * A cache of computed selector validity.\n     */\n    Private.validityCache = Object.create(null);\n    /**\n     * An empty element for testing selector validity.\n     */\n    Private.testElem = document.createElement('div');\n    /**\n     * A cross-browser CSS selector matching prototype function.\n     */\n    Private.protoMatchFunc = (function () {\n        var proto = Element.prototype;\n        return (proto.matches ||\n            proto.matchesSelector ||\n            proto.mozMatchesSelector ||\n            proto.msMatchesSelector ||\n            proto.oMatchesSelector ||\n            proto.webkitMatchesSelector ||\n            (function (selector) {\n                var elem = this;\n                var matches = elem.ownerDocument ? elem.ownerDocument.querySelectorAll(selector) : [];\n                return Array.prototype.indexOf.call(matches, elem) !== -1;\n            }));\n    })();\n    /**\n     * Calculate the specificity of a single selector.\n     *\n     * The behavior is undefined if the selector is invalid.\n     */\n    function calculateSingle(selector) {\n        // Ignore anything after the first comma.\n        selector = selector.split(',', 1)[0];\n        // Setup the aggregate counters.\n        var a = 0;\n        var b = 0;\n        var c = 0;\n        // Apply a regex to the front of the selector. If it succeeds, that\n        // portion of the selector is removed. Returns a success/fail flag.\n        function match(re) {\n            var match = selector.match(re);\n            if (match === null) {\n                return false;\n            }\n            selector = selector.slice(match[0].length);\n            return true;\n        }\n        // Replace the negation pseudo-class (which is ignored),\n        // but keep its inner content (which is not ignored).\n        selector = selector.replace(NEGATION_RE, ' $1 ');\n        // Continue matching until the selector is consumed.\n        while (selector.length > 0) {\n            // Match an ID selector.\n            if (match(ID_RE)) {\n                a++;\n                continue;\n            }\n            // Match a class selector.\n            if (match(CLASS_RE)) {\n                b++;\n                continue;\n            }\n            // Match an attribute selector.\n            if (match(ATTR_RE)) {\n                b++;\n                continue;\n            }\n            // Match a pseudo-element selector. This is done before matching\n            // a pseudo-class since this regex overlaps with that regex.\n            if (match(PSEUDO_ELEM_RE)) {\n                c++;\n                continue;\n            }\n            // Match a pseudo-class selector.\n            if (match(PSEDUO_CLASS_RE)) {\n                b++;\n                continue;\n            }\n            // Match a plain type selector.\n            if (match(TYPE_RE)) {\n                c++;\n                continue;\n            }\n            // Finally, match any ignored characters.\n            if (match(IGNORE_RE)) {\n                continue;\n            }\n            // At this point, the selector is assumed to be invalid.\n            return 0;\n        }\n        // Clamp each component to a reasonable base.\n        a = Math.min(a, 0xFF);\n        b = Math.min(b, 0xFF);\n        c = Math.min(c, 0xFF);\n        // Combine the components into a single result.\n        return (a << 16) | (b << 8) | c;\n    }\n    Private.calculateSingle = calculateSingle;\n    /**\n     * A regex which matches an ID selector at string start.\n     */\n    var ID_RE = /^#[^\\s\\+>~#\\.\\[:]+/;\n    /**\n     * A regex which matches a class selector at string start.\n     */\n    var CLASS_RE = /^\\.[^\\s\\+>~#\\.\\[:]+/;\n    /**\n     * A regex which matches an attribute selector at string start.\n     */\n    var ATTR_RE = /^\\[[^\\]]+\\]/;\n    /**\n     * A regex which matches a type selector at string start.\n     */\n    var TYPE_RE = /^[^\\s\\+>~#\\.\\[:]+/;\n    /**\n     * A regex which matches a pseudo-element selector at string start.\n     */\n    var PSEUDO_ELEM_RE = /^(::[^\\s\\+>~#\\.\\[:]+|:first-line|:first-letter|:before|:after)/;\n    /**\n     * A regex which matches a pseudo-class selector at string start.\n     */\n    var PSEDUO_CLASS_RE = /^:[^\\s\\+>~#\\.\\[:]+/;\n    /**\n     * A regex which matches ignored characters at string start.\n     */\n    var IGNORE_RE = /^[\\s\\+>~\\*]+/;\n    /**\n     * A regex which matches the negation pseudo-class globally.\n     */\n    var NEGATION_RE = /:not\\(([^\\)]+)\\)/g;\n})(Private || (Private = {}));\n\nexport { ClipboardExt, ElementExt, Platform, Selector };\n//# sourceMappingURL=index.es6.js.map\n","import { find, each, ArrayExt } from '@lumino/algorithm';\n\n// Copyright (c) Jupyter Development Team.\n/**\n * A concrete implementation of `ISignal`.\n *\n * #### Example\n * ```typescript\n * import { ISignal, Signal } from '@lumino/signaling';\n *\n * class SomeClass {\n *\n *   constructor(name: string) {\n *     this.name = name;\n *   }\n *\n *   readonly name: string;\n *\n *   get valueChanged: ISignal<this, number> {\n *     return this._valueChanged;\n *   }\n *\n *   get value(): number {\n *     return this._value;\n *   }\n *\n *   set value(value: number) {\n *     if (value === this._value) {\n *       return;\n *     }\n *     this._value = value;\n *     this._valueChanged.emit(value);\n *   }\n *\n *   private _value = 0;\n *   private _valueChanged = new Signal<this, number>(this);\n * }\n *\n * function logger(sender: SomeClass, value: number): void {\n *   console.log(sender.name, value);\n * }\n *\n * let m1 = new SomeClass('foo');\n * let m2 = new SomeClass('bar');\n *\n * m1.valueChanged.connect(logger);\n * m2.valueChanged.connect(logger);\n *\n * m1.value = 42;  // logs: foo 42\n * m2.value = 17;  // logs: bar 17\n * ```\n */\nvar Signal = /** @class */ (function () {\n    /**\n     * Construct a new signal.\n     *\n     * @param sender - The sender which owns the signal.\n     */\n    function Signal(sender) {\n        this.sender = sender;\n    }\n    /**\n     * Connect a slot to the signal.\n     *\n     * @param slot - The slot to invoke when the signal is emitted.\n     *\n     * @param thisArg - The `this` context for the slot. If provided,\n     *   this must be a non-primitive object.\n     *\n     * @returns `true` if the connection succeeds, `false` otherwise.\n     */\n    Signal.prototype.connect = function (slot, thisArg) {\n        return Private.connect(this, slot, thisArg);\n    };\n    /**\n     * Disconnect a slot from the signal.\n     *\n     * @param slot - The slot to disconnect from the signal.\n     *\n     * @param thisArg - The `this` context for the slot. If provided,\n     *   this must be a non-primitive object.\n     *\n     * @returns `true` if the connection is removed, `false` otherwise.\n     */\n    Signal.prototype.disconnect = function (slot, thisArg) {\n        return Private.disconnect(this, slot, thisArg);\n    };\n    /**\n     * Emit the signal and invoke the connected slots.\n     *\n     * @param args - The args to pass to the connected slots.\n     *\n     * #### Notes\n     * Slots are invoked synchronously in connection order.\n     *\n     * Exceptions thrown by connected slots will be caught and logged.\n     */\n    Signal.prototype.emit = function (args) {\n        Private.emit(this, args);\n    };\n    return Signal;\n}());\n/**\n * The namespace for the `Signal` class statics.\n */\n(function (Signal) {\n    /**\n     * Remove all connections between a sender and receiver.\n     *\n     * @param sender - The sender object of interest.\n     *\n     * @param receiver - The receiver object of interest.\n     *\n     * #### Notes\n     * If a `thisArg` is provided when connecting a signal, that object\n     * is considered the receiver. Otherwise, the `slot` is considered\n     * the receiver.\n     */\n    function disconnectBetween(sender, receiver) {\n        Private.disconnectBetween(sender, receiver);\n    }\n    Signal.disconnectBetween = disconnectBetween;\n    /**\n     * Remove all connections where the given object is the sender.\n     *\n     * @param sender - The sender object of interest.\n     */\n    function disconnectSender(sender) {\n        Private.disconnectSender(sender);\n    }\n    Signal.disconnectSender = disconnectSender;\n    /**\n     * Remove all connections where the given object is the receiver.\n     *\n     * @param receiver - The receiver object of interest.\n     *\n     * #### Notes\n     * If a `thisArg` is provided when connecting a signal, that object\n     * is considered the receiver. Otherwise, the `slot` is considered\n     * the receiver.\n     */\n    function disconnectReceiver(receiver) {\n        Private.disconnectReceiver(receiver);\n    }\n    Signal.disconnectReceiver = disconnectReceiver;\n    /**\n     * Remove all connections where an object is the sender or receiver.\n     *\n     * @param object - The object of interest.\n     *\n     * #### Notes\n     * If a `thisArg` is provided when connecting a signal, that object\n     * is considered the receiver. Otherwise, the `slot` is considered\n     * the receiver.\n     */\n    function disconnectAll(object) {\n        Private.disconnectAll(object);\n    }\n    Signal.disconnectAll = disconnectAll;\n    /**\n     * Clear all signal data associated with the given object.\n     *\n     * @param object - The object for which the data should be cleared.\n     *\n     * #### Notes\n     * This removes all signal connections and any other signal data\n     * associated with the object.\n     */\n    function clearData(object) {\n        Private.disconnectAll(object);\n    }\n    Signal.clearData = clearData;\n    /**\n     * Get the signal exception handler.\n     *\n     * @returns The current exception handler.\n     *\n     * #### Notes\n     * The default exception handler is `console.error`.\n     */\n    function getExceptionHandler() {\n        return Private.exceptionHandler;\n    }\n    Signal.getExceptionHandler = getExceptionHandler;\n    /**\n     * Set the signal exception handler.\n     *\n     * @param handler - The function to use as the exception handler.\n     *\n     * @returns The old exception handler.\n     *\n     * #### Notes\n     * The exception handler is invoked when a slot throws an exception.\n     */\n    function setExceptionHandler(handler) {\n        var old = Private.exceptionHandler;\n        Private.exceptionHandler = handler;\n        return old;\n    }\n    Signal.setExceptionHandler = setExceptionHandler;\n})(Signal || (Signal = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private;\n(function (Private) {\n    /**\n     * The signal exception handler function.\n     */\n    Private.exceptionHandler = function (err) {\n        console.error(err);\n    };\n    /**\n     * Connect a slot to a signal.\n     *\n     * @param signal - The signal of interest.\n     *\n     * @param slot - The slot to invoke when the signal is emitted.\n     *\n     * @param thisArg - The `this` context for the slot. If provided,\n     *   this must be a non-primitive object.\n     *\n     * @returns `true` if the connection succeeds, `false` otherwise.\n     */\n    function connect(signal, slot, thisArg) {\n        // Coerce a `null` `thisArg` to `undefined`.\n        thisArg = thisArg || undefined;\n        // Ensure the sender's array of receivers is created.\n        var receivers = receiversForSender.get(signal.sender);\n        if (!receivers) {\n            receivers = [];\n            receiversForSender.set(signal.sender, receivers);\n        }\n        // Bail if a matching connection already exists.\n        if (findConnection(receivers, signal, slot, thisArg)) {\n            return false;\n        }\n        // Choose the best object for the receiver.\n        var receiver = thisArg || slot;\n        // Ensure the receiver's array of senders is created.\n        var senders = sendersForReceiver.get(receiver);\n        if (!senders) {\n            senders = [];\n            sendersForReceiver.set(receiver, senders);\n        }\n        // Create a new connection and add it to the end of each array.\n        var connection = { signal: signal, slot: slot, thisArg: thisArg };\n        receivers.push(connection);\n        senders.push(connection);\n        // Indicate a successful connection.\n        return true;\n    }\n    Private.connect = connect;\n    /**\n     * Disconnect a slot from a signal.\n     *\n     * @param signal - The signal of interest.\n     *\n     * @param slot - The slot to disconnect from the signal.\n     *\n     * @param thisArg - The `this` context for the slot. If provided,\n     *   this must be a non-primitive object.\n     *\n     * @returns `true` if the connection is removed, `false` otherwise.\n     */\n    function disconnect(signal, slot, thisArg) {\n        // Coerce a `null` `thisArg` to `undefined`.\n        thisArg = thisArg || undefined;\n        // Lookup the list of receivers, and bail if none exist.\n        var receivers = receiversForSender.get(signal.sender);\n        if (!receivers || receivers.length === 0) {\n            return false;\n        }\n        // Bail if no matching connection exits.\n        var connection = findConnection(receivers, signal, slot, thisArg);\n        if (!connection) {\n            return false;\n        }\n        // Choose the best object for the receiver.\n        var receiver = thisArg || slot;\n        // Lookup the array of senders, which is now known to exist.\n        var senders = sendersForReceiver.get(receiver);\n        // Clear the connection and schedule cleanup of the arrays.\n        connection.signal = null;\n        scheduleCleanup(receivers);\n        scheduleCleanup(senders);\n        // Indicate a successful disconnection.\n        return true;\n    }\n    Private.disconnect = disconnect;\n    /**\n     * Remove all connections between a sender and receiver.\n     *\n     * @param sender - The sender object of interest.\n     *\n     * @param receiver - The receiver object of interest.\n     */\n    function disconnectBetween(sender, receiver) {\n        // If there are no receivers, there is nothing to do.\n        var receivers = receiversForSender.get(sender);\n        if (!receivers || receivers.length === 0) {\n            return;\n        }\n        // If there are no senders, there is nothing to do.\n        var senders = sendersForReceiver.get(receiver);\n        if (!senders || senders.length === 0) {\n            return;\n        }\n        // Clear each connection between the sender and receiver.\n        each(senders, function (connection) {\n            // Skip connections which have already been cleared.\n            if (!connection.signal) {\n                return;\n            }\n            // Clear the connection if it matches the sender.\n            if (connection.signal.sender === sender) {\n                connection.signal = null;\n            }\n        });\n        // Schedule a cleanup of the senders and receivers.\n        scheduleCleanup(receivers);\n        scheduleCleanup(senders);\n    }\n    Private.disconnectBetween = disconnectBetween;\n    /**\n     * Remove all connections where the given object is the sender.\n     *\n     * @param sender - The sender object of interest.\n     */\n    function disconnectSender(sender) {\n        // If there are no receivers, there is nothing to do.\n        var receivers = receiversForSender.get(sender);\n        if (!receivers || receivers.length === 0) {\n            return;\n        }\n        // Clear each receiver connection.\n        each(receivers, function (connection) {\n            // Skip connections which have already been cleared.\n            if (!connection.signal) {\n                return;\n            }\n            // Choose the best object for the receiver.\n            var receiver = connection.thisArg || connection.slot;\n            // Clear the connection.\n            connection.signal = null;\n            // Cleanup the array of senders, which is now known to exist.\n            scheduleCleanup(sendersForReceiver.get(receiver));\n        });\n        // Schedule a cleanup of the receivers.\n        scheduleCleanup(receivers);\n    }\n    Private.disconnectSender = disconnectSender;\n    /**\n     * Remove all connections where the given object is the receiver.\n     *\n     * @param receiver - The receiver object of interest.\n     */\n    function disconnectReceiver(receiver) {\n        // If there are no senders, there is nothing to do.\n        var senders = sendersForReceiver.get(receiver);\n        if (!senders || senders.length === 0) {\n            return;\n        }\n        // Clear each sender connection.\n        each(senders, function (connection) {\n            // Skip connections which have already been cleared.\n            if (!connection.signal) {\n                return;\n            }\n            // Lookup the sender for the connection.\n            var sender = connection.signal.sender;\n            // Clear the connection.\n            connection.signal = null;\n            // Cleanup the array of receivers, which is now known to exist.\n            scheduleCleanup(receiversForSender.get(sender));\n        });\n        // Schedule a cleanup of the list of senders.\n        scheduleCleanup(senders);\n    }\n    Private.disconnectReceiver = disconnectReceiver;\n    /**\n     * Remove all connections where an object is the sender or receiver.\n     *\n     * @param object - The object of interest.\n     */\n    function disconnectAll(object) {\n        // Remove all connections where the given object is the sender.\n        disconnectSender(object);\n        // Remove all connections where the given object is the receiver.\n        disconnectReceiver(object);\n    }\n    Private.disconnectAll = disconnectAll;\n    /**\n     * Emit a signal and invoke its connected slots.\n     *\n     * @param signal - The signal of interest.\n     *\n     * @param args - The args to pass to the connected slots.\n     *\n     * #### Notes\n     * Slots are invoked synchronously in connection order.\n     *\n     * Exceptions thrown by connected slots will be caught and logged.\n     */\n    function emit(signal, args) {\n        // If there are no receivers, there is nothing to do.\n        var receivers = receiversForSender.get(signal.sender);\n        if (!receivers || receivers.length === 0) {\n            return;\n        }\n        // Invoke the slots for connections with a matching signal.\n        // Any connections added during emission are not invoked.\n        for (var i = 0, n = receivers.length; i < n; ++i) {\n            var connection = receivers[i];\n            if (connection.signal === signal) {\n                invokeSlot(connection, args);\n            }\n        }\n    }\n    Private.emit = emit;\n    /**\n     * A weak mapping of sender to array of receiver connections.\n     */\n    var receiversForSender = new WeakMap();\n    /**\n     * A weak mapping of receiver to array of sender connections.\n     */\n    var sendersForReceiver = new WeakMap();\n    /**\n     * A set of connection arrays which are pending cleanup.\n     */\n    var dirtySet = new Set();\n    /**\n     * A function to schedule an event loop callback.\n     */\n    var schedule = (function () {\n        var ok = typeof requestAnimationFrame === 'function';\n        // @ts-ignore\n        return ok ? requestAnimationFrame : setImmediate;\n    })();\n    /**\n     * Find a connection which matches the given parameters.\n     */\n    function findConnection(connections, signal, slot, thisArg) {\n        return find(connections, function (connection) { return (connection.signal === signal &&\n            connection.slot === slot &&\n            connection.thisArg === thisArg); });\n    }\n    /**\n     * Invoke a slot with the given parameters.\n     *\n     * The connection is assumed to be valid.\n     *\n     * Exceptions in the slot will be caught and logged.\n     */\n    function invokeSlot(connection, args) {\n        var signal = connection.signal, slot = connection.slot, thisArg = connection.thisArg;\n        try {\n            slot.call(thisArg, signal.sender, args);\n        }\n        catch (err) {\n            Private.exceptionHandler(err);\n        }\n    }\n    /**\n     * Schedule a cleanup of a connection array.\n     *\n     * This will add the array to the dirty set and schedule a deferred\n     * cleanup of the array contents. On cleanup, any connection with a\n     * `null` signal will be removed from the array.\n     */\n    function scheduleCleanup(array) {\n        if (dirtySet.size === 0) {\n            schedule(cleanupDirtySet);\n        }\n        dirtySet.add(array);\n    }\n    /**\n     * Cleanup the connection lists in the dirty set.\n     *\n     * This function should only be invoked asynchronously, when the\n     * stack frame is guaranteed to not be on the path of user code.\n     */\n    function cleanupDirtySet() {\n        dirtySet.forEach(cleanupConnections);\n        dirtySet.clear();\n    }\n    /**\n     * Cleanup the dirty connections in a connections array.\n     *\n     * This will remove any connection with a `null` signal.\n     *\n     * This function should only be invoked asynchronously, when the\n     * stack frame is guaranteed to not be on the path of user code.\n     */\n    function cleanupConnections(connections) {\n        ArrayExt.removeAllWhere(connections, isDeadConnection);\n    }\n    /**\n     * Test whether a connection is dead.\n     *\n     * A dead connection has a `null` signal.\n     */\n    function isDeadConnection(connection) {\n        return connection.signal === null;\n    }\n})(Private || (Private = {}));\n\nexport { Signal };\n//# sourceMappingURL=index.es6.js.map\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * A class which attaches a value to an external object.\n *\n * #### Notes\n * Attached properties are used to extend the state of an object with\n * semantic data from an unrelated class. They also encapsulate value\n * creation, coercion, and notification.\n *\n * Because attached property values are stored in a hash table, which\n * in turn is stored in a WeakMap keyed on the owner object, there is\n * non-trivial storage overhead involved in their use. The pattern is\n * therefore best used for the storage of rare data.\n */\nvar AttachedProperty = /** @class */ (function () {\n    /**\n     * Construct a new attached property.\n     *\n     * @param options - The options for initializing the property.\n     */\n    function AttachedProperty(options) {\n        this._pid = Private.nextPID();\n        this.name = options.name;\n        this._create = options.create;\n        this._coerce = options.coerce || null;\n        this._compare = options.compare || null;\n        this._changed = options.changed || null;\n    }\n    /**\n     * Get the current value of the property for a given owner.\n     *\n     * @param owner - The property owner of interest.\n     *\n     * @returns The current value of the property.\n     *\n     * #### Notes\n     * If the value has not yet been set, the default value will be\n     * computed and assigned as the current value of the property.\n     */\n    AttachedProperty.prototype.get = function (owner) {\n        var value;\n        var map = Private.ensureMap(owner);\n        if (this._pid in map) {\n            value = map[this._pid];\n        }\n        else {\n            value = map[this._pid] = this._createValue(owner);\n        }\n        return value;\n    };\n    /**\n     * Set the current value of the property for a given owner.\n     *\n     * @param owner - The property owner of interest.\n     *\n     * @param value - The value for the property.\n     *\n     * #### Notes\n     * If the value has not yet been set, the default value will be\n     * computed and used as the previous value for the comparison.\n     */\n    AttachedProperty.prototype.set = function (owner, value) {\n        var oldValue;\n        var map = Private.ensureMap(owner);\n        if (this._pid in map) {\n            oldValue = map[this._pid];\n        }\n        else {\n            oldValue = map[this._pid] = this._createValue(owner);\n        }\n        var newValue = this._coerceValue(owner, value);\n        this._maybeNotify(owner, oldValue, map[this._pid] = newValue);\n    };\n    /**\n     * Explicitly coerce the current property value for a given owner.\n     *\n     * @param owner - The property owner of interest.\n     *\n     * #### Notes\n     * If the value has not yet been set, the default value will be\n     * computed and used as the previous value for the comparison.\n     */\n    AttachedProperty.prototype.coerce = function (owner) {\n        var oldValue;\n        var map = Private.ensureMap(owner);\n        if (this._pid in map) {\n            oldValue = map[this._pid];\n        }\n        else {\n            oldValue = map[this._pid] = this._createValue(owner);\n        }\n        var newValue = this._coerceValue(owner, oldValue);\n        this._maybeNotify(owner, oldValue, map[this._pid] = newValue);\n    };\n    /**\n     * Get or create the default value for the given owner.\n     */\n    AttachedProperty.prototype._createValue = function (owner) {\n        var create = this._create;\n        return create(owner);\n    };\n    /**\n     * Coerce the value for the given owner.\n     */\n    AttachedProperty.prototype._coerceValue = function (owner, value) {\n        var coerce = this._coerce;\n        return coerce ? coerce(owner, value) : value;\n    };\n    /**\n     * Compare the old value and new value for equality.\n     */\n    AttachedProperty.prototype._compareValue = function (oldValue, newValue) {\n        var compare = this._compare;\n        return compare ? compare(oldValue, newValue) : oldValue === newValue;\n    };\n    /**\n     * Run the change notification if the given values are different.\n     */\n    AttachedProperty.prototype._maybeNotify = function (owner, oldValue, newValue) {\n        var changed = this._changed;\n        if (changed && !this._compareValue(oldValue, newValue)) {\n            changed(owner, oldValue, newValue);\n        }\n    };\n    return AttachedProperty;\n}());\n/**\n * The namespace for the `AttachedProperty` class statics.\n */\n(function (AttachedProperty) {\n    /**\n     * Clear the stored property data for the given owner.\n     *\n     * @param owner - The property owner of interest.\n     *\n     * #### Notes\n     * This will clear all property values for the owner, but it will\n     * **not** run the change notification for any of the properties.\n     */\n    function clearData(owner) {\n        Private.ownerData.delete(owner);\n    }\n    AttachedProperty.clearData = clearData;\n})(AttachedProperty || (AttachedProperty = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private;\n(function (Private) {\n    /**\n     * A weak mapping of property owner to property map.\n     */\n    Private.ownerData = new WeakMap();\n    /**\n     * A function which computes successive unique property ids.\n     */\n    Private.nextPID = (function () {\n        var id = 0;\n        return function () {\n            var rand = Math.random();\n            var stem = (\"\" + rand).slice(2);\n            return \"pid-\" + stem + \"-\" + id++;\n        };\n    })();\n    /**\n     * Lookup the data map for the property owner.\n     *\n     * This will create the map if one does not already exist.\n     */\n    function ensureMap(owner) {\n        var map = Private.ownerData.get(owner);\n        if (map) {\n            return map;\n        }\n        map = Object.create(null);\n        Private.ownerData.set(owner, map);\n        return map;\n    }\n    Private.ensureMap = ensureMap;\n})(Private || (Private = {}));\n\nexport { AttachedProperty };\n//# sourceMappingURL=index.es6.js.map\n","import { each } from '@lumino/algorithm';\nimport { Signal } from '@lumino/signaling';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n    extendStatics = Object.setPrototypeOf ||\r\n        ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n        function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\r\n    return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n    extendStatics(d, b);\r\n    function __() { this.constructor = d; }\r\n    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * A disposable object which delegates to a callback function.\n */\nvar DisposableDelegate = /** @class */ (function () {\n    /**\n     * Construct a new disposable delegate.\n     *\n     * @param fn - The callback function to invoke on dispose.\n     */\n    function DisposableDelegate(fn) {\n        this._fn = fn;\n    }\n    Object.defineProperty(DisposableDelegate.prototype, \"isDisposed\", {\n        /**\n         * Test whether the delegate has been disposed.\n         */\n        get: function () {\n            return !this._fn;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Dispose of the delegate and invoke the callback function.\n     */\n    DisposableDelegate.prototype.dispose = function () {\n        if (!this._fn) {\n            return;\n        }\n        var fn = this._fn;\n        this._fn = null;\n        fn();\n    };\n    return DisposableDelegate;\n}());\n/**\n * An observable disposable object which delegates to a callback function.\n */\nvar ObservableDisposableDelegate = /** @class */ (function (_super) {\n    __extends(ObservableDisposableDelegate, _super);\n    function ObservableDisposableDelegate() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._disposed = new Signal(_this);\n        return _this;\n    }\n    Object.defineProperty(ObservableDisposableDelegate.prototype, \"disposed\", {\n        /**\n         * A signal emitted when the delegate is disposed.\n         */\n        get: function () {\n            return this._disposed;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Dispose of the delegate and invoke the callback function.\n     */\n    ObservableDisposableDelegate.prototype.dispose = function () {\n        if (this.isDisposed) {\n            return;\n        }\n        _super.prototype.dispose.call(this);\n        this._disposed.emit(undefined);\n        Signal.clearData(this);\n    };\n    return ObservableDisposableDelegate;\n}(DisposableDelegate));\n/**\n * An object which manages a collection of disposable items.\n */\nvar DisposableSet = /** @class */ (function () {\n    /**\n     * Construct a new disposable set.\n     */\n    function DisposableSet() {\n        this._isDisposed = false;\n        this._items = new Set();\n    }\n    Object.defineProperty(DisposableSet.prototype, \"isDisposed\", {\n        /**\n         * Test whether the set has been disposed.\n         */\n        get: function () {\n            return this._isDisposed;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Dispose of the set and the items it contains.\n     *\n     * #### Notes\n     * Items are disposed in the order they are added to the set.\n     */\n    DisposableSet.prototype.dispose = function () {\n        if (this._isDisposed) {\n            return;\n        }\n        this._isDisposed = true;\n        this._items.forEach(function (item) { item.dispose(); });\n        this._items.clear();\n    };\n    /**\n     * Test whether the set contains a specific item.\n     *\n     * @param item - The item of interest.\n     *\n     * @returns `true` if the set contains the item, `false` otherwise.\n     */\n    DisposableSet.prototype.contains = function (item) {\n        return this._items.has(item);\n    };\n    /**\n     * Add a disposable item to the set.\n     *\n     * @param item - The item to add to the set.\n     *\n     * #### Notes\n     * If the item is already contained in the set, this is a no-op.\n     */\n    DisposableSet.prototype.add = function (item) {\n        this._items.add(item);\n    };\n    /**\n     * Remove a disposable item from the set.\n     *\n     * @param item - The item to remove from the set.\n     *\n     * #### Notes\n     * If the item is not contained in the set, this is a no-op.\n     */\n    DisposableSet.prototype.remove = function (item) {\n        this._items.delete(item);\n    };\n    /**\n     * Remove all items from the set.\n     */\n    DisposableSet.prototype.clear = function () {\n        this._items.clear();\n    };\n    return DisposableSet;\n}());\n/**\n * The namespace for the `DisposableSet` class statics.\n */\n(function (DisposableSet) {\n    /**\n     * Create a disposable set from an iterable of items.\n     *\n     * @param items - The iterable or array-like object of interest.\n     *\n     * @returns A new disposable initialized with the given items.\n     */\n    function from(items) {\n        var set = new DisposableSet();\n        each(items, function (item) { set.add(item); });\n        return set;\n    }\n    DisposableSet.from = from;\n})(DisposableSet || (DisposableSet = {}));\n/**\n * An observable object which manages a collection of disposable items.\n */\nvar ObservableDisposableSet = /** @class */ (function (_super) {\n    __extends(ObservableDisposableSet, _super);\n    function ObservableDisposableSet() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._disposed = new Signal(_this);\n        return _this;\n    }\n    Object.defineProperty(ObservableDisposableSet.prototype, \"disposed\", {\n        /**\n         * A signal emitted when the set is disposed.\n         */\n        get: function () {\n            return this._disposed;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Dispose of the set and the items it contains.\n     *\n     * #### Notes\n     * Items are disposed in the order they are added to the set.\n     */\n    ObservableDisposableSet.prototype.dispose = function () {\n        if (this.isDisposed) {\n            return;\n        }\n        _super.prototype.dispose.call(this);\n        this._disposed.emit(undefined);\n        Signal.clearData(this);\n    };\n    return ObservableDisposableSet;\n}(DisposableSet));\n/**\n * The namespace for the `ObservableDisposableSet` class statics.\n */\n(function (ObservableDisposableSet) {\n    /**\n     * Create an observable disposable set from an iterable of items.\n     *\n     * @param items - The iterable or array-like object of interest.\n     *\n     * @returns A new disposable initialized with the given items.\n     */\n    function from(items) {\n        var set = new ObservableDisposableSet();\n        each(items, function (item) { set.add(item); });\n        return set;\n    }\n    ObservableDisposableSet.from = from;\n})(ObservableDisposableSet || (ObservableDisposableSet = {}));\n\nexport { DisposableDelegate, DisposableSet, ObservableDisposableDelegate, ObservableDisposableSet };\n//# sourceMappingURL=index.es6.js.map\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * Get the global application keyboard layout instance.\n *\n * @returns The keyboard layout for use by the application.\n *\n * #### Notes\n * The default keyboard layout is US-English.\n */\nfunction getKeyboardLayout() {\n    return Private.keyboardLayout;\n}\n/**\n * Set the global application keyboard layout instance.\n *\n * @param - The keyboard layout for use by the application.\n *\n * #### Notes\n * The keyboard layout should typically be set on application startup\n * to a layout which is appropriate for the user's system.\n */\nfunction setKeyboardLayout(layout) {\n    Private.keyboardLayout = layout;\n}\n/**\n * A concrete implementation of [[IKeyboardLayout]] based on keycodes.\n *\n * The `keyCode` property of a `'keydown'` event is a browser and OS\n * specific representation of the physical key (not character) which\n * was pressed on a keyboard. While not the most convenient API, it\n * is currently the only one which works reliably on all browsers.\n *\n * This class accepts a user-defined mapping of keycode to key, which\n * allows for reliable shortcuts tailored to the user's system.\n */\nvar KeycodeLayout = /** @class */ (function () {\n    /**\n     * Construct a new keycode layout.\n     *\n     * @param name - The human readable name for the layout.\n     *\n     * @param codes - A mapping of keycode to key value.\n     */\n    function KeycodeLayout(name, codes) {\n        this.name = name;\n        this._codes = codes;\n        this._keys = KeycodeLayout.extractKeys(codes);\n    }\n    /**\n     * Get an array of the key values supported by the layout.\n     *\n     * @returns A new array of the supported key values.\n     */\n    KeycodeLayout.prototype.keys = function () {\n        return Object.keys(this._keys);\n    };\n    /**\n     * Test whether the given key is a valid value for the layout.\n     *\n     * @param key - The user provided key to test for validity.\n     *\n     * @returns `true` if the key is valid, `false` otherwise.\n     */\n    KeycodeLayout.prototype.isValidKey = function (key) {\n        return key in this._keys;\n    };\n    /**\n     * Get the key for a `'keydown'` event.\n     *\n     * @param event - The event object for a `'keydown'` event.\n     *\n     * @returns The associated key value, or an empty string if\n     *   the event does not represent a valid primary key.\n     */\n    KeycodeLayout.prototype.keyForKeydownEvent = function (event) {\n        return this._codes[event.keyCode] || '';\n    };\n    return KeycodeLayout;\n}());\n/**\n * The namespace for the `KeycodeLayout` class statics.\n */\n(function (KeycodeLayout) {\n    /**\n     * Extract the set of keys from a code map.\n     *\n     * @param code - The code map of interest.\n     *\n     * @returns A set of the keys in the code map.\n     */\n    function extractKeys(codes) {\n        var keys = Object.create(null);\n        for (var c in codes) {\n            keys[codes[c]] = true;\n        }\n        return keys;\n    }\n    KeycodeLayout.extractKeys = extractKeys;\n})(KeycodeLayout || (KeycodeLayout = {}));\n/**\n * A keycode-based keyboard layout for US English keyboards.\n *\n * This layout is valid for the following OS/Browser combinations.\n *\n * - Windows\n *   - Chrome\n *   - Firefox\n *   - IE\n *\n * - OSX\n *   - Chrome\n *   - Firefox\n *   - Safari\n *\n * - Linux\n *   - Chrome\n *   - Firefox\n *\n * Other combinations may also work, but are untested.\n */\nvar EN_US = new KeycodeLayout('en-us', {\n    8: 'Backspace',\n    9: 'Tab',\n    13: 'Enter',\n    19: 'Pause',\n    27: 'Escape',\n    32: 'Space',\n    33: 'PageUp',\n    34: 'PageDown',\n    35: 'End',\n    36: 'Home',\n    37: 'ArrowLeft',\n    38: 'ArrowUp',\n    39: 'ArrowRight',\n    40: 'ArrowDown',\n    45: 'Insert',\n    46: 'Delete',\n    48: '0',\n    49: '1',\n    50: '2',\n    51: '3',\n    52: '4',\n    53: '5',\n    54: '6',\n    55: '7',\n    56: '8',\n    57: '9',\n    59: ';',\n    61: '=',\n    65: 'A',\n    66: 'B',\n    67: 'C',\n    68: 'D',\n    69: 'E',\n    70: 'F',\n    71: 'G',\n    72: 'H',\n    73: 'I',\n    74: 'J',\n    75: 'K',\n    76: 'L',\n    77: 'M',\n    78: 'N',\n    79: 'O',\n    80: 'P',\n    81: 'Q',\n    82: 'R',\n    83: 'S',\n    84: 'T',\n    85: 'U',\n    86: 'V',\n    87: 'W',\n    88: 'X',\n    89: 'Y',\n    90: 'Z',\n    93: 'ContextMenu',\n    96: '0',\n    97: '1',\n    98: '2',\n    99: '3',\n    100: '4',\n    101: '5',\n    102: '6',\n    103: '7',\n    104: '8',\n    105: '9',\n    106: '*',\n    107: '+',\n    109: '-',\n    110: '.',\n    111: '/',\n    112: 'F1',\n    113: 'F2',\n    114: 'F3',\n    115: 'F4',\n    116: 'F5',\n    117: 'F6',\n    118: 'F7',\n    119: 'F8',\n    120: 'F9',\n    121: 'F10',\n    122: 'F11',\n    123: 'F12',\n    173: '-',\n    186: ';',\n    187: '=',\n    188: ',',\n    189: '-',\n    190: '.',\n    191: '/',\n    192: '`',\n    219: '[',\n    220: '\\\\',\n    221: ']',\n    222: '\\''\n});\n/**\n * The namespace for the module implementation details.\n */\nvar Private;\n(function (Private) {\n    /**\n     * The global keyboard layout instance.\n     */\n    Private.keyboardLayout = EN_US;\n})(Private || (Private = {}));\n\nexport { EN_US, KeycodeLayout, getKeyboardLayout, setKeyboardLayout };\n//# sourceMappingURL=index.es6.js.map\n","import { ArrayExt } from '@lumino/algorithm';\nimport { JSONExt } from '@lumino/coreutils';\nimport { DisposableDelegate } from '@lumino/disposable';\nimport { Platform, Selector } from '@lumino/domutils';\nimport { getKeyboardLayout } from '@lumino/keyboard';\nimport { Signal } from '@lumino/signaling';\n\n// Copyright (c) Jupyter Development Team.\n/**\n * An object which manages a collection of commands.\n *\n * #### Notes\n * A command registry can be used to populate a variety of action-based\n * widgets, such as command palettes, menus, and toolbars.\n */\nvar CommandRegistry = /** @class */ (function () {\n    /**\n     * Construct a new command registry.\n     */\n    function CommandRegistry() {\n        this._timerID = 0;\n        this._replaying = false;\n        this._keystrokes = [];\n        this._keydownEvents = [];\n        this._keyBindings = [];\n        this._exactKeyMatch = null;\n        this._commands = Object.create(null);\n        this._commandChanged = new Signal(this);\n        this._commandExecuted = new Signal(this);\n        this._keyBindingChanged = new Signal(this);\n    }\n    Object.defineProperty(CommandRegistry.prototype, \"commandChanged\", {\n        /**\n         * A signal emitted when a command has changed.\n         *\n         * #### Notes\n         * This signal is useful for visual representations of commands which\n         * need to refresh when the state of a relevant command has changed.\n         */\n        get: function () {\n            return this._commandChanged;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(CommandRegistry.prototype, \"commandExecuted\", {\n        /**\n         * A signal emitted when a command has executed.\n         *\n         * #### Notes\n         * Care should be taken when consuming this signal. The command system is used\n         * by many components for many user actions. Handlers registered with this\n         * signal must return quickly to ensure the overall application remains responsive.\n         */\n        get: function () {\n            return this._commandExecuted;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(CommandRegistry.prototype, \"keyBindingChanged\", {\n        /**\n         * A signal emitted when a key binding is changed.\n         */\n        get: function () {\n            return this._keyBindingChanged;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(CommandRegistry.prototype, \"keyBindings\", {\n        /**\n         * A read-only array of the key bindings in the registry.\n         */\n        get: function () {\n            return this._keyBindings;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * List the ids of the registered commands.\n     *\n     * @returns A new array of the registered command ids.\n     */\n    CommandRegistry.prototype.listCommands = function () {\n        return Object.keys(this._commands);\n    };\n    /**\n     * Test whether a specific command is registered.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @returns `true` if the command is registered, `false` otherwise.\n     */\n    CommandRegistry.prototype.hasCommand = function (id) {\n        return id in this._commands;\n    };\n    /**\n     * Add a command to the registry.\n     *\n     * @param id - The unique id of the command.\n     *\n     * @param options - The options for the command.\n     *\n     * @returns A disposable which will remove the command.\n     *\n     * @throws An error if the given `id` is already registered.\n     */\n    CommandRegistry.prototype.addCommand = function (id, options) {\n        var _this = this;\n        // Throw an error if the id is already registered.\n        if (id in this._commands) {\n            throw new Error(\"Command '\" + id + \"' already registered.\");\n        }\n        // Add the command to the registry.\n        this._commands[id] = Private.createCommand(options);\n        // Emit the `commandChanged` signal.\n        this._commandChanged.emit({ id: id, type: 'added' });\n        // Return a disposable which will remove the command.\n        return new DisposableDelegate(function () {\n            // Remove the command from the registry.\n            delete _this._commands[id];\n            // Emit the `commandChanged` signal.\n            _this._commandChanged.emit({ id: id, type: 'removed' });\n        });\n    };\n    /**\n     * Notify listeners that the state of a command has changed.\n     *\n     * @param id - The id of the command which has changed. If more than\n     *   one command has changed, this argument should be omitted.\n     *\n     * @throws An error if the given `id` is not registered.\n     *\n     * #### Notes\n     * This method should be called by the command author whenever the\n     * application state changes such that the results of the command\n     * metadata functions may have changed.\n     *\n     * This will cause the `commandChanged` signal to be emitted.\n     */\n    CommandRegistry.prototype.notifyCommandChanged = function (id) {\n        if (id !== undefined && !(id in this._commands)) {\n            throw new Error(\"Command '\" + id + \"' is not registered.\");\n        }\n        this._commandChanged.emit({ id: id, type: id ? 'changed' : 'many-changed' });\n    };\n    /**\n     * Get the display label for a specific command.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns The display label for the command, or an empty string\n     *   if the command is not registered.\n     */\n    CommandRegistry.prototype.label = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.label.call(undefined, args) : '';\n    };\n    /**\n     * Get the mnemonic index for a specific command.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns The mnemonic index for the command, or `-1` if the\n     *   command is not registered.\n     */\n    CommandRegistry.prototype.mnemonic = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.mnemonic.call(undefined, args) : -1;\n    };\n    /**\n     * Get the icon renderer for a specific command.\n     *\n     * DEPRECATED: if set to a string value, the .icon field will\n     * function as an alias for the .iconClass field, for backwards\n     * compatibility. In the future when this is removed, the default\n     * return type will become undefined.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns The icon renderer for the command, or\n     *   an empty string if the command is not registered.\n     */\n    CommandRegistry.prototype.icon = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.icon.call(undefined, args) : /* <DEPRECATED> */ '' /* </DEPRECATED> */ /* <FUTURE> undefined </FUTURE> */;\n    };\n    /**\n     * Get the icon class for a specific command.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns The icon class for the command, or an empty string if\n     *   the command is not registered.\n     */\n    CommandRegistry.prototype.iconClass = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.iconClass.call(undefined, args) : '';\n    };\n    /**\n     * Get the icon label for a specific command.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns The icon label for the command, or an empty string if\n     *   the command is not registered.\n     */\n    CommandRegistry.prototype.iconLabel = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.iconLabel.call(undefined, args) : '';\n    };\n    /**\n     * Get the short form caption for a specific command.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns The caption for the command, or an empty string if the\n     *   command is not registered.\n     */\n    CommandRegistry.prototype.caption = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.caption.call(undefined, args) : '';\n    };\n    /**\n     * Get the usage help text for a specific command.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns The usage text for the command, or an empty string if\n     *   the command is not registered.\n     */\n    CommandRegistry.prototype.usage = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.usage.call(undefined, args) : '';\n    };\n    /**\n     * Get the extra class name for a specific command.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns The class name for the command, or an empty string if\n     *   the command is not registered.\n     */\n    CommandRegistry.prototype.className = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.className.call(undefined, args) : '';\n    };\n    /**\n     * Get the dataset for a specific command.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns The dataset for the command, or an empty dataset if\n     *   the command is not registered.\n     */\n    CommandRegistry.prototype.dataset = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.dataset.call(undefined, args) : {};\n    };\n    /**\n     * Test whether a specific command is enabled.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns A boolean indicating whether the command is enabled,\n     *   or `false` if the command is not registered.\n     */\n    CommandRegistry.prototype.isEnabled = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.isEnabled.call(undefined, args) : false;\n    };\n    /**\n     * Test whether a specific command is toggled.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns A boolean indicating whether the command is toggled,\n     *   or `false` if the command is not registered.\n     */\n    CommandRegistry.prototype.isToggled = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.isToggled.call(undefined, args) : false;\n    };\n    /**\n     * Test whether a specific command is toggleable.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns A boolean indicating whether the command is toggleable,\n     *   or `false` if the command is not registered.\n     */\n    CommandRegistry.prototype.isToggleable = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.isToggleable : false;\n    };\n    /**\n     * Test whether a specific command is visible.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns A boolean indicating whether the command is visible,\n     *   or `false` if the command is not registered.\n     */\n    CommandRegistry.prototype.isVisible = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        var cmd = this._commands[id];\n        return cmd ? cmd.isVisible.call(undefined, args) : false;\n    };\n    /**\n     * Execute a specific command.\n     *\n     * @param id - The id of the command of interest.\n     *\n     * @param args - The arguments for the command.\n     *\n     * @returns A promise which resolves with the result of the command.\n     *\n     * #### Notes\n     * The promise will reject if the command throws an exception,\n     * or if the command is not registered.\n     */\n    CommandRegistry.prototype.execute = function (id, args) {\n        if (args === void 0) { args = JSONExt.emptyObject; }\n        // Reject if the command is not registered.\n        var cmd = this._commands[id];\n        if (!cmd) {\n            return Promise.reject(new Error(\"Command '\" + id + \"' not registered.\"));\n        }\n        // Execute the command and reject if an exception is thrown.\n        var value;\n        try {\n            value = cmd.execute.call(undefined, args);\n        }\n        catch (err) {\n            value = Promise.reject(err);\n        }\n        // Create the return promise which resolves the result.\n        var result = Promise.resolve(value);\n        // Emit the command executed signal.\n        this._commandExecuted.emit({ id: id, args: args, result: result });\n        // Return the result promise to the caller.\n        return result;\n    };\n    /**\n     * Add a key binding to the registry.\n     *\n     * @param options - The options for creating the key binding.\n     *\n     * @returns A disposable which removes the added key binding.\n     *\n     * #### Notes\n     * If multiple key bindings are registered for the same sequence, the\n     * binding with the highest selector specificity is executed first. A\n     * tie is broken by using the most recently added key binding.\n     *\n     * Ambiguous key bindings are resolved with a timeout. As an example,\n     * suppose two key bindings are registered: one with the key sequence\n     * `['Ctrl D']`, and another with `['Ctrl D', 'Ctrl W']`. If the user\n     * presses `Ctrl D`, the first binding cannot be immediately executed\n     * since the user may intend to complete the chord with `Ctrl W`. For\n     * such cases, a timer is used to allow the chord to be completed. If\n     * the chord is not completed before the timeout, the first binding\n     * is executed.\n     */\n    CommandRegistry.prototype.addKeyBinding = function (options) {\n        var _this = this;\n        // Create the binding for the given options.\n        var binding = Private.createKeyBinding(options);\n        // Add the key binding to the bindings array.\n        this._keyBindings.push(binding);\n        // Emit the `bindingChanged` signal.\n        this._keyBindingChanged.emit({ binding: binding, type: 'added' });\n        // Return a disposable which will remove the binding.\n        return new DisposableDelegate(function () {\n            // Remove the binding from the array.\n            ArrayExt.removeFirstOf(_this._keyBindings, binding);\n            // Emit the `bindingChanged` signal.\n            _this._keyBindingChanged.emit({ binding: binding, type: 'removed' });\n        });\n    };\n    /**\n     * Process a `'keydown'` event and invoke a matching key binding.\n     *\n     * @param event - The event object for a `'keydown'` event.\n     *\n     * #### Notes\n     * This should be called in response to a `'keydown'` event in order\n     * to invoke the command for the best matching key binding.\n     *\n     * The registry **does not** install its own listener for `'keydown'`\n     * events. This allows the application full control over the nodes\n     * and phase for which the registry processes `'keydown'` events.\n     *\n     * When the keydown event is processed, if the event target or any of its\n     * ancestor nodes has a `data-lm-suppress-shortcuts` attribute, its keydown\n     * events will not invoke commands.\n     */\n    CommandRegistry.prototype.processKeydownEvent = function (event) {\n        // Bail immediately if playing back keystrokes.\n        if (this._replaying) {\n            return;\n        }\n        // Get the normalized keystroke for the event.\n        var keystroke = CommandRegistry.keystrokeForKeydownEvent(event);\n        // If the keystroke is not valid for the keyboard layout, replay\n        // any suppressed events and clear the pending state.\n        if (!keystroke) {\n            this._replayKeydownEvents();\n            this._clearPendingState();\n            return;\n        }\n        // Add the keystroke to the current key sequence.\n        this._keystrokes.push(keystroke);\n        // Find the exact and partial matches for the key sequence.\n        var _a = Private.matchKeyBinding(this._keyBindings, this._keystrokes, event), exact = _a.exact, partial = _a.partial;\n        // If there is no exact match and no partial match, replay\n        // any suppressed events and clear the pending state.\n        if (!exact && !partial) {\n            this._replayKeydownEvents();\n            this._clearPendingState();\n            return;\n        }\n        // Stop propagation of the event. If there is only a partial match,\n        // the event will be replayed if a final exact match never occurs.\n        event.preventDefault();\n        event.stopPropagation();\n        // If there is an exact match but no partial match, the exact match\n        // can be dispatched immediately. The pending state is cleared so\n        // the next key press starts from the default state.\n        if (exact && !partial) {\n            this._executeKeyBinding(exact);\n            this._clearPendingState();\n            return;\n        }\n        // If there is both an exact match and a partial match, the exact\n        // match is stored for future dispatch in case the timer expires\n        // before a more specific match is triggered.\n        if (exact) {\n            this._exactKeyMatch = exact;\n        }\n        // Store the event for possible playback in the future.\n        this._keydownEvents.push(event);\n        // (Re)start the timer to dispatch the most recent exact match\n        // in case the partial match fails to result in an exact match.\n        this._startTimer();\n    };\n    /**\n     * Start or restart the pending timeout.\n     */\n    CommandRegistry.prototype._startTimer = function () {\n        var _this = this;\n        this._clearTimer();\n        this._timerID = window.setTimeout(function () {\n            _this._onPendingTimeout();\n        }, Private.CHORD_TIMEOUT);\n    };\n    /**\n     * Clear the pending timeout.\n     */\n    CommandRegistry.prototype._clearTimer = function () {\n        if (this._timerID !== 0) {\n            clearTimeout(this._timerID);\n            this._timerID = 0;\n        }\n    };\n    /**\n     * Replay the keydown events which were suppressed.\n     */\n    CommandRegistry.prototype._replayKeydownEvents = function () {\n        if (this._keydownEvents.length === 0) {\n            return;\n        }\n        this._replaying = true;\n        this._keydownEvents.forEach(Private.replayKeyEvent);\n        this._replaying = false;\n    };\n    /**\n     * Execute the command for the given key binding.\n     *\n     * If the command is missing or disabled, a warning will be logged.\n     */\n    CommandRegistry.prototype._executeKeyBinding = function (binding) {\n        var command = binding.command, args = binding.args;\n        if (!this.hasCommand(command) || !this.isEnabled(command, args)) {\n            var word = this.hasCommand(command) ? 'enabled' : 'registered';\n            var keys = binding.keys.join(', ');\n            var msg1 = \"Cannot execute key binding '\" + keys + \"':\";\n            var msg2 = \"command '\" + command + \"' is not \" + word + \".\";\n            console.warn(msg1 + \" \" + msg2);\n            return;\n        }\n        this.execute(command, args);\n    };\n    /**\n     * Clear the internal pending state.\n     */\n    CommandRegistry.prototype._clearPendingState = function () {\n        this._clearTimer();\n        this._exactKeyMatch = null;\n        this._keystrokes.length = 0;\n        this._keydownEvents.length = 0;\n    };\n    /**\n     * Handle the partial match timeout.\n     */\n    CommandRegistry.prototype._onPendingTimeout = function () {\n        this._timerID = 0;\n        if (this._exactKeyMatch) {\n            this._executeKeyBinding(this._exactKeyMatch);\n        }\n        else {\n            this._replayKeydownEvents();\n        }\n        this._clearPendingState();\n    };\n    return CommandRegistry;\n}());\n/**\n * The namespace for the `CommandRegistry` class statics.\n */\n(function (CommandRegistry) {\n    /**\n     * Parse a keystroke into its constituent components.\n     *\n     * @param keystroke - The keystroke of interest.\n     *\n     * @returns The parsed components of the keystroke.\n     *\n     * #### Notes\n     * The keystroke should be of the form:\n     *   `[<modifier 1> [<modifier 2> [<modifier N> ]]]<primary key>`\n     *\n     * The supported modifiers are: `Accel`, `Alt`, `Cmd`, `Ctrl`, and\n     * `Shift`. The `Accel` modifier is translated to `Cmd` on Mac and\n     * `Ctrl` on all other platforms.\n     *\n     * The parsing is tolerant and will not throw exceptions. Notably:\n     *   - Duplicate modifiers are ignored.\n     *   - Extra primary keys are ignored.\n     *   - The order of modifiers and primary key is irrelevant.\n     *   - The keystroke parts should be separated by whitespace.\n     *   - The keystroke is case sensitive.\n     */\n    function parseKeystroke(keystroke) {\n        var key = '';\n        var alt = false;\n        var cmd = false;\n        var ctrl = false;\n        var shift = false;\n        for (var _i = 0, _a = keystroke.split(/\\s+/); _i < _a.length; _i++) {\n            var token = _a[_i];\n            if (token === 'Accel') {\n                if (Platform.IS_MAC) {\n                    cmd = true;\n                }\n                else {\n                    ctrl = true;\n                }\n            }\n            else if (token === 'Alt') {\n                alt = true;\n            }\n            else if (token === 'Cmd') {\n                cmd = true;\n            }\n            else if (token === 'Ctrl') {\n                ctrl = true;\n            }\n            else if (token === 'Shift') {\n                shift = true;\n            }\n            else if (token.length > 0) {\n                key = token;\n            }\n        }\n        return { cmd: cmd, ctrl: ctrl, alt: alt, shift: shift, key: key };\n    }\n    CommandRegistry.parseKeystroke = parseKeystroke;\n    /**\n     * Normalize a keystroke into a canonical representation.\n     *\n     * @param keystroke - The keystroke of interest.\n     *\n     * @returns The normalized representation of the keystroke.\n     *\n     * #### Notes\n     * This normalizes the keystroke by removing duplicate modifiers and\n     * extra primary keys, and assembling the parts in a canonical order.\n     *\n     * The `Cmd` modifier is ignored on non-Mac platforms.\n     */\n    function normalizeKeystroke(keystroke) {\n        var mods = '';\n        var parts = parseKeystroke(keystroke);\n        if (parts.ctrl) {\n            mods += 'Ctrl ';\n        }\n        if (parts.alt) {\n            mods += 'Alt ';\n        }\n        if (parts.shift) {\n            mods += 'Shift ';\n        }\n        if (parts.cmd && Platform.IS_MAC) {\n            mods += 'Cmd ';\n        }\n        return mods + parts.key;\n    }\n    CommandRegistry.normalizeKeystroke = normalizeKeystroke;\n    /**\n     * Get the platform-specific normalized keys for an options object.\n     *\n     * @param options - The options for the key binding.\n     *\n     * @returns Array of combined, normalized keys.\n     */\n    function normalizeKeys(options) {\n        var keys;\n        if (Platform.IS_WIN) {\n            keys = options.winKeys || options.keys;\n        }\n        else if (Platform.IS_MAC) {\n            keys = options.macKeys || options.keys;\n        }\n        else {\n            keys = options.linuxKeys || options.keys;\n        }\n        return keys.map(normalizeKeystroke);\n    }\n    CommandRegistry.normalizeKeys = normalizeKeys;\n    /**\n     * Format a keystroke for display on the local system.\n     */\n    function formatKeystroke(keystroke) {\n        var mods = '';\n        var parts = parseKeystroke(keystroke);\n        if (Platform.IS_MAC) {\n            if (parts.ctrl) {\n                mods += '\\u2303 ';\n            }\n            if (parts.alt) {\n                mods += '\\u2325 ';\n            }\n            if (parts.shift) {\n                mods += '\\u21E7 ';\n            }\n            if (parts.cmd) {\n                mods += '\\u2318 ';\n            }\n        }\n        else {\n            if (parts.ctrl) {\n                mods += 'Ctrl+';\n            }\n            if (parts.alt) {\n                mods += 'Alt+';\n            }\n            if (parts.shift) {\n                mods += 'Shift+';\n            }\n        }\n        return mods + parts.key;\n    }\n    CommandRegistry.formatKeystroke = formatKeystroke;\n    /**\n     * Create a normalized keystroke for a `'keydown'` event.\n     *\n     * @param event - The event object for a `'keydown'` event.\n     *\n     * @returns A normalized keystroke, or an empty string if the event\n     *   does not represent a valid keystroke for the given layout.\n     */\n    function keystrokeForKeydownEvent(event) {\n        var key = getKeyboardLayout().keyForKeydownEvent(event);\n        if (!key) {\n            return '';\n        }\n        var mods = '';\n        if (event.ctrlKey) {\n            mods += 'Ctrl ';\n        }\n        if (event.altKey) {\n            mods += 'Alt ';\n        }\n        if (event.shiftKey) {\n            mods += 'Shift ';\n        }\n        if (event.metaKey && Platform.IS_MAC) {\n            mods += 'Cmd ';\n        }\n        return mods + key;\n    }\n    CommandRegistry.keystrokeForKeydownEvent = keystrokeForKeydownEvent;\n})(CommandRegistry || (CommandRegistry = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private;\n(function (Private) {\n    /**\n     * The timeout in ms for triggering a key binding chord.\n     */\n    Private.CHORD_TIMEOUT = 1000;\n    /**\n     * Create a normalized command from an options object.\n     */\n    function createCommand(options) {\n        var icon;\n        var iconClass;\n        /* <DEPRECATED> */\n        if (!(options.icon) || typeof options.icon === 'string') {\n            // alias icon to iconClass\n            iconClass = asFunc(options.iconClass || options.icon, emptyStringFunc);\n            icon = iconClass;\n        }\n        else {\n            /* /<DEPRECATED> */\n            iconClass = asFunc(options.iconClass, emptyStringFunc);\n            icon = asFunc(options.icon, undefinedFunc);\n            /* <DEPRECATED> */\n        }\n        /* </DEPRECATED> */\n        return {\n            execute: options.execute,\n            label: asFunc(options.label, emptyStringFunc),\n            mnemonic: asFunc(options.mnemonic, negativeOneFunc),\n            icon: icon,\n            iconClass: iconClass,\n            iconLabel: asFunc(options.iconLabel, emptyStringFunc),\n            caption: asFunc(options.caption, emptyStringFunc),\n            usage: asFunc(options.usage, emptyStringFunc),\n            className: asFunc(options.className, emptyStringFunc),\n            dataset: asFunc(options.dataset, emptyDatasetFunc),\n            isEnabled: options.isEnabled || trueFunc,\n            isToggled: options.isToggled || falseFunc,\n            isToggleable: options.isToggleable || !!options.isToggled,\n            isVisible: options.isVisible || trueFunc\n        };\n    }\n    Private.createCommand = createCommand;\n    /**\n     * Create a key binding object from key binding options.\n     */\n    function createKeyBinding(options) {\n        return {\n            keys: CommandRegistry.normalizeKeys(options),\n            selector: validateSelector(options),\n            command: options.command,\n            args: options.args || JSONExt.emptyObject\n        };\n    }\n    Private.createKeyBinding = createKeyBinding;\n    /**\n     * Find the key bindings which match a key sequence.\n     *\n     * This returns a match result which contains the best exact matching\n     * binding, and a flag which indicates if there are partial matches.\n     */\n    function matchKeyBinding(bindings, keys, event) {\n        // The current best exact match.\n        var exact = null;\n        // Whether a partial match has been found.\n        var partial = false;\n        // The match distance for the exact match.\n        var distance = Infinity;\n        // The specificity for the exact match.\n        var specificity = 0;\n        // Iterate over the bindings and search for the best match.\n        for (var i = 0, n = bindings.length; i < n; ++i) {\n            // Lookup the current binding.\n            var binding = bindings[i];\n            // Check whether the key binding sequence is a match.\n            var sqm = matchSequence(binding.keys, keys);\n            // If there is no match, the binding is ignored.\n            if (sqm === 0 /* None */) {\n                continue;\n            }\n            // If it is a partial match and no other partial match has been\n            // found, ensure the selector matches and set the partial flag.\n            if (sqm === 2 /* Partial */) {\n                if (!partial && targetDistance(binding.selector, event) !== -1) {\n                    partial = true;\n                }\n                continue;\n            }\n            // Ignore the match if the selector doesn't match, or if the\n            // matched node is farther away than the current best match.\n            var td = targetDistance(binding.selector, event);\n            if (td === -1 || td > distance) {\n                continue;\n            }\n            // Get the specificity for the selector.\n            var sp = Selector.calculateSpecificity(binding.selector);\n            // Update the best match if this match is stronger.\n            if (!exact || td < distance || sp >= specificity) {\n                exact = binding;\n                distance = td;\n                specificity = sp;\n            }\n        }\n        // Return the match result.\n        return { exact: exact, partial: partial };\n    }\n    Private.matchKeyBinding = matchKeyBinding;\n    /**\n     * Replay a keyboard event.\n     *\n     * This synthetically dispatches a clone of the keyboard event.\n     */\n    function replayKeyEvent(event) {\n        event.target.dispatchEvent(cloneKeyboardEvent(event));\n    }\n    Private.replayKeyEvent = replayKeyEvent;\n    /**\n     * A singleton empty string function.\n     */\n    var emptyStringFunc = function () { return ''; };\n    /**\n     * A singleton `-1` number function\n     */\n    var negativeOneFunc = function () { return -1; };\n    /**\n     * A singleton true boolean function.\n     */\n    var trueFunc = function () { return true; };\n    /**\n     * A singleton false boolean function.\n     */\n    var falseFunc = function () { return false; };\n    /**\n     * A singleton empty dataset function.\n     */\n    var emptyDatasetFunc = function () { return ({}); };\n    /**\n     * A singleton undefined function\n     */\n    var undefinedFunc = function () { return undefined; };\n    /**\n     * Cast a value or command func to a command func.\n     */\n    function asFunc(value, dfault) {\n        if (value === undefined) {\n            return dfault;\n        }\n        if (typeof value === 'function') {\n            return value;\n        }\n        return function () { return value; };\n    }\n    /**\n     * Validate the selector for an options object.\n     *\n     * This returns the validated selector, or throws if the selector is\n     * invalid or contains commas.\n     */\n    function validateSelector(options) {\n        if (options.selector.indexOf(',') !== -1) {\n            throw new Error(\"Selector cannot contain commas: \" + options.selector);\n        }\n        if (!Selector.isValid(options.selector)) {\n            throw new Error(\"Invalid selector: \" + options.selector);\n        }\n        return options.selector;\n    }\n    /**\n     * Test whether a key binding sequence matches a key sequence.\n     *\n     * Returns a `SequenceMatch` value indicating the type of match.\n     */\n    function matchSequence(bindKeys, userKeys) {\n        if (bindKeys.length < userKeys.length) {\n            return 0 /* None */;\n        }\n        for (var i = 0, n = userKeys.length; i < n; ++i) {\n            if (bindKeys[i] !== userKeys[i]) {\n                return 0 /* None */;\n            }\n        }\n        if (bindKeys.length > userKeys.length) {\n            return 2 /* Partial */;\n        }\n        return 1 /* Exact */;\n    }\n    /**\n     * Find the distance from the target node to the first matching node.\n     *\n     * This traverses the event path from `target` to `currentTarget` and\n     * computes the distance from `target` to the first node which matches\n     * the CSS selector. If no match is found, `-1` is returned.\n     */\n    function targetDistance(selector, event) {\n        var targ = event.target;\n        var curr = event.currentTarget;\n        for (var dist = 0; targ !== null; targ = targ.parentElement, ++dist) {\n            if (targ.hasAttribute('data-lm-suppress-shortcuts')) {\n                return -1;\n            }\n            /* <DEPRECATED> */\n            if (targ.hasAttribute('data-p-suppress-shortcuts')) {\n                return -1;\n            }\n            /* </DEPRECATED> */\n            if (Selector.matches(targ, selector)) {\n                return dist;\n            }\n            if (targ === curr) {\n                return -1;\n            }\n        }\n        return -1;\n    }\n    /**\n     * Clone a keyboard event.\n     */\n    function cloneKeyboardEvent(event) {\n        // A custom event is required because Chrome nulls out the\n        // `keyCode` field in user-generated `KeyboardEvent` types.\n        var clone = document.createEvent('Event');\n        var bubbles = event.bubbles || true;\n        var cancelable = event.cancelable || true;\n        clone.initEvent(event.type || 'keydown', bubbles, cancelable);\n        clone.key = event.key || '';\n        clone.keyCode = event.keyCode || 0;\n        clone.which = event.keyCode || 0;\n        clone.ctrlKey = event.ctrlKey || false;\n        clone.altKey = event.altKey || false;\n        clone.shiftKey = event.shiftKey || false;\n        clone.metaKey = event.metaKey || false;\n        clone.view = event.view || window;\n        return clone;\n    }\n})(Private || (Private = {}));\n\nexport { CommandRegistry };\n//# sourceMappingURL=index.es6.js.map\n","import { ArrayExt } from '@lumino/algorithm';\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n    extendStatics = Object.setPrototypeOf ||\r\n        ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n        function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\r\n    return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n    extendStatics(d, b);\r\n    function __() { this.constructor = d; }\r\n    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\n\n/**\n * A virtual node which represents plain text content.\n *\n * #### Notes\n * User code will not typically create a `VirtualText` node directly.\n * Instead, the `h()` function will be used to create an element tree.\n */\nvar VirtualText = /** @class */ (function () {\n    /**\n     * Construct a new virtual text node.\n     *\n     * @param content - The text content for the node.\n     */\n    function VirtualText(content) {\n        /**\n         * The type of the node.\n         *\n         * This value can be used as a type guard for discriminating the\n         * `VirtualNode` union type.\n         */\n        this.type = 'text';\n        this.content = content;\n    }\n    return VirtualText;\n}());\n/**\n * A virtual node which represents an HTML element.\n *\n * #### Notes\n * User code will not typically create a `VirtualElement` node directly.\n * Instead, the `h()` function will be used to create an element tree.\n */\nvar VirtualElement = /** @class */ (function () {\n    /**\n     * Construct a new virtual element node.\n     *\n     * @param tag - The element tag name.\n     *\n     * @param attrs - The element attributes.\n     *\n     * @param children - The element children.\n     *\n     * @param renderer - An optional custom renderer for the element.\n     */\n    function VirtualElement(tag, attrs, children, renderer) {\n        /**\n         * The type of the node.\n         *\n         * This value can be used as a type guard for discriminating the\n         * `VirtualNode` union type.\n         */\n        this.type = 'element';\n        this.tag = tag;\n        this.attrs = attrs;\n        this.children = children;\n        this.renderer = renderer;\n    }\n    return VirtualElement;\n}());\n/**\n * DEPRECATED - use VirtualElement with a defined renderer param instead.\n * This class is provided as a backwards compatibility shim\n *\n * A \"pass thru\" virtual node whose children are managed by a render and an\n * unrender callback. The intent of this flavor of virtual node is to make\n * it easy to blend other kinds of virtualdom (eg React) into Phosphor's\n * virtualdom.\n *\n * #### Notes\n * User code will not typically create a `VirtualElementPass` node directly.\n * Instead, the `hpass()` function will be used to create an element tree.\n */\nvar VirtualElementPass = /** @class */ (function (_super) {\n    __extends(VirtualElementPass, _super);\n    /**\n     * DEPRECATED - use VirtualElement with a defined renderer param instead\n     *\n     * Construct a new virtual element pass thru node.\n     *\n     * @param tag - the tag of the parent element of this node. Once the parent\n     * element is rendered, it will be passed as an argument to\n     * renderer.render\n     *\n     * @param attrs - attributes that will assigned to the\n     * parent element\n     *\n     * @param renderer - an object with render and unrender\n     * functions, each of which should take a single argument of type\n     * HTMLElement and return nothing. If null, the parent element\n     * will be rendered barren without any children.\n     */\n    function VirtualElementPass(tag, attrs, renderer) {\n        return _super.call(this, tag, attrs, [], renderer || undefined) || this;\n    }\n    return VirtualElementPass;\n}(VirtualElement));\nfunction h(tag) {\n    var attrs = {};\n    var renderer;\n    var children = [];\n    for (var i = 1, n = arguments.length; i < n; ++i) {\n        var arg = arguments[i];\n        if (typeof arg === 'string') {\n            children.push(new VirtualText(arg));\n        }\n        else if (arg instanceof VirtualText) {\n            children.push(arg);\n        }\n        else if (arg instanceof VirtualElement) {\n            children.push(arg);\n        }\n        else if (arg instanceof Array) {\n            extend(children, arg);\n        }\n        else if ((i === 1 || i === 2) && arg && typeof arg === 'object') {\n            if (\"render\" in arg) {\n                renderer = arg;\n            }\n            else {\n                attrs = arg;\n            }\n        }\n    }\n    return new VirtualElement(tag, attrs, children, renderer);\n    function extend(array, values) {\n        for (var _i = 0, values_1 = values; _i < values_1.length; _i++) {\n            var child = values_1[_i];\n            if (typeof child === 'string') {\n                array.push(new VirtualText(child));\n            }\n            else if (child instanceof VirtualText) {\n                array.push(child);\n            }\n            else if (child instanceof VirtualElement) {\n                array.push(child);\n            }\n        }\n    }\n}\n/**\n * The namespace for the `h` function statics.\n */\n(function (h) {\n    h.a = h.bind(undefined, 'a');\n    h.abbr = h.bind(undefined, 'abbr');\n    h.address = h.bind(undefined, 'address');\n    h.area = h.bind(undefined, 'area');\n    h.article = h.bind(undefined, 'article');\n    h.aside = h.bind(undefined, 'aside');\n    h.audio = h.bind(undefined, 'audio');\n    h.b = h.bind(undefined, 'b');\n    h.bdi = h.bind(undefined, 'bdi');\n    h.bdo = h.bind(undefined, 'bdo');\n    h.blockquote = h.bind(undefined, 'blockquote');\n    h.br = h.bind(undefined, 'br');\n    h.button = h.bind(undefined, 'button');\n    h.canvas = h.bind(undefined, 'canvas');\n    h.caption = h.bind(undefined, 'caption');\n    h.cite = h.bind(undefined, 'cite');\n    h.code = h.bind(undefined, 'code');\n    h.col = h.bind(undefined, 'col');\n    h.colgroup = h.bind(undefined, 'colgroup');\n    h.data = h.bind(undefined, 'data');\n    h.datalist = h.bind(undefined, 'datalist');\n    h.dd = h.bind(undefined, 'dd');\n    h.del = h.bind(undefined, 'del');\n    h.dfn = h.bind(undefined, 'dfn');\n    h.div = h.bind(undefined, 'div');\n    h.dl = h.bind(undefined, 'dl');\n    h.dt = h.bind(undefined, 'dt');\n    h.em = h.bind(undefined, 'em');\n    h.embed = h.bind(undefined, 'embed');\n    h.fieldset = h.bind(undefined, 'fieldset');\n    h.figcaption = h.bind(undefined, 'figcaption');\n    h.figure = h.bind(undefined, 'figure');\n    h.footer = h.bind(undefined, 'footer');\n    h.form = h.bind(undefined, 'form');\n    h.h1 = h.bind(undefined, 'h1');\n    h.h2 = h.bind(undefined, 'h2');\n    h.h3 = h.bind(undefined, 'h3');\n    h.h4 = h.bind(undefined, 'h4');\n    h.h5 = h.bind(undefined, 'h5');\n    h.h6 = h.bind(undefined, 'h6');\n    h.header = h.bind(undefined, 'header');\n    h.hr = h.bind(undefined, 'hr');\n    h.i = h.bind(undefined, 'i');\n    h.iframe = h.bind(undefined, 'iframe');\n    h.img = h.bind(undefined, 'img');\n    h.input = h.bind(undefined, 'input');\n    h.ins = h.bind(undefined, 'ins');\n    h.kbd = h.bind(undefined, 'kbd');\n    h.label = h.bind(undefined, 'label');\n    h.legend = h.bind(undefined, 'legend');\n    h.li = h.bind(undefined, 'li');\n    h.main = h.bind(undefined, 'main');\n    h.map = h.bind(undefined, 'map');\n    h.mark = h.bind(undefined, 'mark');\n    h.meter = h.bind(undefined, 'meter');\n    h.nav = h.bind(undefined, 'nav');\n    h.noscript = h.bind(undefined, 'noscript');\n    h.object = h.bind(undefined, 'object');\n    h.ol = h.bind(undefined, 'ol');\n    h.optgroup = h.bind(undefined, 'optgroup');\n    h.option = h.bind(undefined, 'option');\n    h.output = h.bind(undefined, 'output');\n    h.p = h.bind(undefined, 'p');\n    h.param = h.bind(undefined, 'param');\n    h.pre = h.bind(undefined, 'pre');\n    h.progress = h.bind(undefined, 'progress');\n    h.q = h.bind(undefined, 'q');\n    h.rp = h.bind(undefined, 'rp');\n    h.rt = h.bind(undefined, 'rt');\n    h.ruby = h.bind(undefined, 'ruby');\n    h.s = h.bind(undefined, 's');\n    h.samp = h.bind(undefined, 'samp');\n    h.section = h.bind(undefined, 'section');\n    h.select = h.bind(undefined, 'select');\n    h.small = h.bind(undefined, 'small');\n    h.source = h.bind(undefined, 'source');\n    h.span = h.bind(undefined, 'span');\n    h.strong = h.bind(undefined, 'strong');\n    h.sub = h.bind(undefined, 'sub');\n    h.summary = h.bind(undefined, 'summary');\n    h.sup = h.bind(undefined, 'sup');\n    h.table = h.bind(undefined, 'table');\n    h.tbody = h.bind(undefined, 'tbody');\n    h.td = h.bind(undefined, 'td');\n    h.textarea = h.bind(undefined, 'textarea');\n    h.tfoot = h.bind(undefined, 'tfoot');\n    h.th = h.bind(undefined, 'th');\n    h.thead = h.bind(undefined, 'thead');\n    h.time = h.bind(undefined, 'time');\n    h.title = h.bind(undefined, 'title');\n    h.tr = h.bind(undefined, 'tr');\n    h.track = h.bind(undefined, 'track');\n    h.u = h.bind(undefined, 'u');\n    h.ul = h.bind(undefined, 'ul');\n    h.var_ = h.bind(undefined, 'var');\n    h.video = h.bind(undefined, 'video');\n    h.wbr = h.bind(undefined, 'wbr');\n})(h || (h = {}));\nfunction hpass(tag) {\n    var attrs = {};\n    var renderer = null;\n    if (arguments.length === 2) {\n        var arg = arguments[1];\n        if (\"render\" in arg) {\n            renderer = arg;\n        }\n        else {\n            attrs = arg;\n        }\n    }\n    else if (arguments.length === 3) {\n        attrs = arguments[1];\n        renderer = arguments[2];\n    }\n    else if (arguments.length > 3) {\n        throw new Error(\"hpass() should be called with 1, 2, or 3 arguments\");\n    }\n    return new VirtualElementPass(tag, attrs, renderer);\n}\n/**\n * The namespace for the virtual DOM rendering functions.\n */\nvar VirtualDOM;\n(function (VirtualDOM) {\n    function realize(node) {\n        return Private.createDOMNode(node);\n    }\n    VirtualDOM.realize = realize;\n    /**\n     * Render virtual DOM content into a host element.\n     *\n     * @param content - The virtual DOM content to render.\n     *\n     * @param host - The host element for the rendered content.\n     *\n     * #### Notes\n     * This renders the delta from the previous rendering. It assumes that\n     * the content of the host element is not manipulated by external code.\n     *\n     * Providing `null` content will clear the rendering.\n     *\n     * Externally modifying the provided content or the host element will\n     * result in undefined rendering behavior.\n     */\n    function render(content, host) {\n        var oldContent = Private.hostMap.get(host) || [];\n        var newContent = Private.asContentArray(content);\n        Private.hostMap.set(host, newContent);\n        Private.updateContent(host, oldContent, newContent);\n    }\n    VirtualDOM.render = render;\n})(VirtualDOM || (VirtualDOM = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private;\n(function (Private) {\n    /**\n     * A weak mapping of host element to virtual DOM content.\n     */\n    Private.hostMap = new WeakMap();\n    /**\n     * Cast a content value to a content array.\n     */\n    function asContentArray(value) {\n        if (!value) {\n            return [];\n        }\n        if (value instanceof Array) {\n            return value;\n        }\n        return [value];\n    }\n    Private.asContentArray = asContentArray;\n    function createDOMNode(node) {\n        var host = arguments[1] || null;\n        var before = arguments[2] || null;\n        if (host) {\n            host.insertBefore(createDOMNode(node), before);\n        }\n        else {\n            // Create a text node for a virtual text node.\n            if (node.type === 'text') {\n                return document.createTextNode(node.content);\n            }\n            // Create the HTML element with the specified tag.\n            host = document.createElement(node.tag);\n            // Add the attributes for the new element.\n            addAttrs(host, node.attrs);\n            if (node.renderer) {\n                node.renderer.render(host, { attrs: node.attrs, children: node.children });\n                return host;\n            }\n            // Recursively populate the element with child content.\n            for (var i = 0, n = node.children.length; i < n; ++i) {\n                createDOMNode(node.children[i], host);\n            }\n        }\n        return host;\n    }\n    Private.createDOMNode = createDOMNode;\n    /**\n     * Update a host element with the delta of the virtual content.\n     *\n     * This is the core \"diff\" algorithm. There is no explicit \"patch\"\n     * phase. The host is patched at each step as the diff progresses.\n     */\n    function updateContent(host, oldContent, newContent) {\n        // Bail early if the content is identical.\n        if (oldContent === newContent) {\n            return;\n        }\n        // Collect the old keyed elems into a mapping.\n        var oldKeyed = collectKeys(host, oldContent);\n        // Create a copy of the old content which can be modified in-place.\n        var oldCopy = oldContent.slice();\n        // Update the host with the new content. The diff always proceeds\n        // forward and never modifies a previously visited index. The old\n        // copy array is modified in-place to reflect the changes made to\n        // the host children. This causes the stale nodes to be pushed to\n        // the end of the host node and removed at the end of the loop.\n        var currElem = host.firstChild;\n        var newCount = newContent.length;\n        for (var i = 0; i < newCount; ++i) {\n            // If the old content is exhausted, create a new node.\n            if (i >= oldCopy.length) {\n                createDOMNode(newContent[i], host);\n                continue;\n            }\n            // Lookup the old and new virtual nodes.\n            var oldVNode = oldCopy[i];\n            var newVNode = newContent[i];\n            // If both elements are identical, there is nothing to do.\n            if (oldVNode === newVNode) {\n                currElem = currElem.nextSibling;\n                continue;\n            }\n            // Handle the simplest case of in-place text update first.\n            if (oldVNode.type === 'text' && newVNode.type === 'text') {\n                currElem.textContent = newVNode.content;\n                currElem = currElem.nextSibling;\n                continue;\n            }\n            // If the old or new node is a text node, the other node is now\n            // known to be an element node, so create and insert a new node.\n            if (oldVNode.type === 'text' || newVNode.type === 'text') {\n                ArrayExt.insert(oldCopy, i, newVNode);\n                createDOMNode(newVNode, host, currElem);\n                continue;\n            }\n            // If the old XOR new node has a custom renderer,\n            // create and insert a new node.\n            if (!(oldVNode.renderer) != !(newVNode.renderer)) {\n                ArrayExt.insert(oldCopy, i, newVNode);\n                createDOMNode(newVNode, host, currElem);\n                continue;\n            }\n            // At this point, both nodes are known to be element nodes.\n            // If the new elem is keyed, move an old keyed elem to the proper\n            // location before proceeding with the diff. The search can start\n            // at the current index, since the unmatched old keyed elems are\n            // pushed forward in the old copy array.\n            var newKey = newVNode.attrs.key;\n            if (newKey && newKey in oldKeyed) {\n                var pair = oldKeyed[newKey];\n                if (pair.vNode !== oldVNode) {\n                    ArrayExt.move(oldCopy, oldCopy.indexOf(pair.vNode, i + 1), i);\n                    host.insertBefore(pair.element, currElem);\n                    oldVNode = pair.vNode;\n                    currElem = pair.element;\n                }\n            }\n            // If both elements are identical, there is nothing to do.\n            if (oldVNode === newVNode) {\n                currElem = currElem.nextSibling;\n                continue;\n            }\n            // If the old elem is keyed and does not match the new elem key,\n            // create a new node. This is necessary since the old keyed elem\n            // may be matched at a later point in the diff.\n            var oldKey = oldVNode.attrs.key;\n            if (oldKey && oldKey !== newKey) {\n                ArrayExt.insert(oldCopy, i, newVNode);\n                createDOMNode(newVNode, host, currElem);\n                continue;\n            }\n            // If the tags are different, create a new node.\n            if (oldVNode.tag !== newVNode.tag) {\n                ArrayExt.insert(oldCopy, i, newVNode);\n                createDOMNode(newVNode, host, currElem);\n                continue;\n            }\n            // At this point, the element can be updated in-place.\n            // Update the element attributes.\n            updateAttrs(currElem, oldVNode.attrs, newVNode.attrs);\n            // Update the element content.\n            if (newVNode.renderer) {\n                newVNode.renderer.render(currElem, { attrs: newVNode.attrs, children: newVNode.children });\n            }\n            else {\n                updateContent(currElem, oldVNode.children, newVNode.children);\n            }\n            // Step to the next sibling element.\n            currElem = currElem.nextSibling;\n        }\n        // Cleanup stale DOM\n        removeContent(host, oldCopy, newCount, true);\n    }\n    Private.updateContent = updateContent;\n    /**\n     * Handle cleanup of stale vdom and its associated DOM. The host node is\n     * traversed recursively (in depth-first order), and any explicit cleanup\n     * required by a child node is carried out when it is visited (eg if a node\n     * has a custom renderer, the renderer.unrender function will be called).\n     * Once the subtree beneath each child of host has been completely visited,\n     * that child will be removed via a call to host.removeChild.\n     */\n    function removeContent(host, oldContent, newCount, _sentinel) {\n        // Dispose of the old nodes pushed to the end of the host.\n        for (var i = oldContent.length - 1; i >= newCount; --i) {\n            var oldNode = oldContent[i];\n            var child = (_sentinel ? host.lastChild : host.childNodes[i]);\n            // recursively clean up host children\n            if (oldNode.type === 'text') ;\n            else if (oldNode.renderer && oldNode.renderer.unrender) {\n                oldNode.renderer.unrender(child, { attrs: oldNode.attrs, children: oldNode.children });\n            }\n            else {\n                removeContent(child, oldNode.children, 0, false);\n            }\n            if (_sentinel) {\n                host.removeChild(child);\n            }\n        }\n    }\n    /**\n     * A set of special-cased attribute names.\n     */\n    var specialAttrs = {\n        'key': true,\n        'className': true,\n        'htmlFor': true,\n        'dataset': true,\n        'style': true,\n    };\n    /**\n     * Add element attributes to a newly created HTML element.\n     */\n    function addAttrs(element, attrs) {\n        // Add the inline event listeners and node attributes.\n        for (var name_1 in attrs) {\n            if (name_1 in specialAttrs) {\n                continue;\n            }\n            if (name_1.substr(0, 2) === 'on') {\n                element[name_1] = attrs[name_1];\n            }\n            else {\n                element.setAttribute(name_1, attrs[name_1]);\n            }\n        }\n        // Add the element `class` attribute.\n        if (attrs.className !== undefined) {\n            element.setAttribute('class', attrs.className);\n        }\n        // Add the element `for` attribute.\n        if (attrs.htmlFor !== undefined) {\n            element.setAttribute('for', attrs.htmlFor);\n        }\n        // Add the dataset values.\n        if (attrs.dataset) {\n            addDataset(element, attrs.dataset);\n        }\n        // Add the inline styles.\n        if (attrs.style) {\n            addStyle(element, attrs.style);\n        }\n    }\n    /**\n     * Update the element attributes of an HTML element.\n     */\n    function updateAttrs(element, oldAttrs, newAttrs) {\n        // Do nothing if the attrs are the same object.\n        if (oldAttrs === newAttrs) {\n            return;\n        }\n        // Setup the strongly typed loop variable.\n        var name;\n        // Remove attributes and listeners which no longer exist.\n        for (name in oldAttrs) {\n            if (name in specialAttrs || name in newAttrs) {\n                continue;\n            }\n            if (name.substr(0, 2) === 'on') {\n                element[name] = null;\n            }\n            else {\n                element.removeAttribute(name);\n            }\n        }\n        // Add and update new and existing attributes and listeners.\n        for (name in newAttrs) {\n            if (name in specialAttrs || oldAttrs[name] === newAttrs[name]) {\n                continue;\n            }\n            if (name.substr(0, 2) === 'on') {\n                element[name] = newAttrs[name];\n            }\n            else {\n                element.setAttribute(name, newAttrs[name]);\n            }\n        }\n        // Update the element `class` attribute.\n        if (oldAttrs.className !== newAttrs.className) {\n            if (newAttrs.className !== undefined) {\n                element.setAttribute('class', newAttrs.className);\n            }\n            else {\n                element.removeAttribute('class');\n            }\n        }\n        // Add the element `for` attribute.\n        if (oldAttrs.htmlFor !== newAttrs.htmlFor) {\n            if (newAttrs.htmlFor !== undefined) {\n                element.setAttribute('for', newAttrs.htmlFor);\n            }\n            else {\n                element.removeAttribute('for');\n            }\n        }\n        // Update the dataset values.\n        if (oldAttrs.dataset !== newAttrs.dataset) {\n            updateDataset(element, oldAttrs.dataset || {}, newAttrs.dataset || {});\n        }\n        // Update the inline styles.\n        if (oldAttrs.style !== newAttrs.style) {\n            updateStyle(element, oldAttrs.style || {}, newAttrs.style || {});\n        }\n    }\n    /**\n     * Add dataset values to a newly created HTML element.\n     */\n    function addDataset(element, dataset) {\n        for (var name_2 in dataset) {\n            element.setAttribute(\"data-\" + name_2, dataset[name_2]);\n        }\n    }\n    /**\n     * Update the dataset values of an HTML element.\n     */\n    function updateDataset(element, oldDataset, newDataset) {\n        for (var name_3 in oldDataset) {\n            if (!(name_3 in newDataset)) {\n                element.removeAttribute(\"data-\" + name_3);\n            }\n        }\n        for (var name_4 in newDataset) {\n            if (oldDataset[name_4] !== newDataset[name_4]) {\n                element.setAttribute(\"data-\" + name_4, newDataset[name_4]);\n            }\n        }\n    }\n    /**\n     * Add inline style values to a newly created HTML element.\n     */\n    function addStyle(element, style) {\n        var elemStyle = element.style;\n        var name;\n        for (name in style) {\n            elemStyle[name] = style[name];\n        }\n    }\n    /**\n     * Update the inline style values of an HTML element.\n     */\n    function updateStyle(element, oldStyle, newStyle) {\n        var elemStyle = element.style;\n        var name;\n        for (name in oldStyle) {\n            if (!(name in newStyle)) {\n                elemStyle[name] = '';\n            }\n        }\n        for (name in newStyle) {\n            if (oldStyle[name] !== newStyle[name]) {\n                elemStyle[name] = newStyle[name];\n            }\n        }\n    }\n    /**\n     * Collect a mapping of keyed elements for the host content.\n     */\n    function collectKeys(host, content) {\n        var node = host.firstChild;\n        var keyMap = Object.create(null);\n        for (var _i = 0, content_1 = content; _i < content_1.length; _i++) {\n            var vNode = content_1[_i];\n            if (vNode.type === 'element' && vNode.attrs.key) {\n                keyMap[vNode.attrs.key] = { vNode: vNode, element: node };\n            }\n            node = node.nextSibling;\n        }\n        return keyMap;\n    }\n})(Private || (Private = {}));\n\nexport { VirtualDOM, VirtualElement, VirtualElementPass, VirtualText, h, hpass };\n//# sourceMappingURL=index.es6.js.map\n","import { DisposableDelegate } from '@lumino/disposable';\n\n/**\n * An object which manages a drag-drop operation.\n *\n * A drag object dispatches four different events to drop targets:\n *\n * - `'lm-dragenter'` - Dispatched when the mouse enters the target\n *   element. This event must be canceled in order to receive any\n *   of the other events.\n *\n * - `'lm-dragover'` - Dispatched when the mouse moves over the drop\n *   target. It must cancel the event and set the `dropAction` to one\n *   of the supported actions in order to receive drop events.\n *\n * - `'lm-dragleave'` - Dispatched when the mouse leaves the target\n *   element. This includes moving the mouse into child elements.\n *\n * - `'lm-drop'`- Dispatched when the mouse is released over the target\n *   element when the target indicates an appropriate drop action. If\n *   the event is canceled, the indicated drop action is returned to\n *   the initiator through the resolved promise.\n *\n * A drag operation can be terminated at any time by pressing `Escape`\n * or by disposing the drag object.\n *\n * A drag object has the ability to automatically scroll a scrollable\n * element when the mouse is hovered near one of its edges. To enable\n * this, add the `data-lm-dragscroll` attribute to any element which\n * the drag object should consider for scrolling.\n *\n * #### Notes\n * This class is designed to be used when dragging and dropping custom\n * data *within* a single application. It is *not* a replacement for\n * the native drag-drop API. Instead, it provides an API which allows\n * drag operations to be initiated programmatically and enables the\n * transfer of arbitrary non-string objects; features which are not\n * possible with the native drag-drop API.\n */\nvar Drag = /** @class */ (function () {\n    /**\n     * Construct a new drag object.\n     *\n     * @param options - The options for initializing the drag.\n     */\n    function Drag(options) {\n        var _this = this;\n        /**\n         * The scroll loop handler function.\n         */\n        this._onScrollFrame = function () {\n            // Bail early if there is no scroll target.\n            if (!_this._scrollTarget) {\n                return;\n            }\n            // Unpack the scroll target.\n            var _a = _this._scrollTarget, element = _a.element, edge = _a.edge, distance = _a.distance;\n            // Calculate the scroll delta using nonlinear acceleration.\n            var d = Private.SCROLL_EDGE_SIZE - distance;\n            var f = Math.pow(d / Private.SCROLL_EDGE_SIZE, 2);\n            var s = Math.max(1, Math.round(f * Private.SCROLL_EDGE_SIZE));\n            // Scroll the element in the specified direction.\n            switch (edge) {\n                case 'top':\n                    element.scrollTop -= s;\n                    break;\n                case 'left':\n                    element.scrollLeft -= s;\n                    break;\n                case 'right':\n                    element.scrollLeft += s;\n                    break;\n                case 'bottom':\n                    element.scrollTop += s;\n                    break;\n            }\n            // Request the next cycle of the scroll loop.\n            requestAnimationFrame(_this._onScrollFrame);\n        };\n        this._disposed = false;\n        this._dropAction = 'none';\n        this._override = null;\n        this._currentTarget = null;\n        this._currentElement = null;\n        this._promise = null;\n        this._scrollTarget = null;\n        this._resolve = null;\n        this.mimeData = options.mimeData;\n        this.dragImage = options.dragImage || null;\n        this.proposedAction = options.proposedAction || 'copy';\n        this.supportedActions = options.supportedActions || 'all';\n        this.source = options.source || null;\n    }\n    /**\n     * Dispose of the resources held by the drag object.\n     *\n     * #### Notes\n     * This will cancel the drag operation if it is active.\n     */\n    Drag.prototype.dispose = function () {\n        // Do nothing if the drag object is already disposed.\n        if (this._disposed) {\n            return;\n        }\n        this._disposed = true;\n        // If there is a current target, dispatch a drag leave event.\n        if (this._currentTarget) {\n            var event_1 = Private.createMouseEvent('mouseup', -1, -1);\n            Private.dispatchDragLeave(this, this._currentTarget, null, event_1);\n        }\n        // Finalize the drag object with `'none'`.\n        this._finalize('none');\n    };\n    Object.defineProperty(Drag.prototype, \"isDisposed\", {\n        /**\n         * Test whether the drag object is disposed.\n         */\n        get: function () {\n            return this._disposed;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Start the drag operation at the specified client position.\n     *\n     * @param clientX - The client X position for the drag start.\n     *\n     * @param clientY - The client Y position for the drag start.\n     *\n     * @returns A promise which resolves to the result of the drag.\n     *\n     * #### Notes\n     * If the drag has already been started, the promise created by the\n     * first call to `start` is returned.\n     *\n     * If the drag operation has ended, or if the drag object has been\n     * disposed, the returned promise will resolve to `'none'`.\n     *\n     * The drag object will be automatically disposed when drag operation\n     * completes. This means `Drag` objects are for single-use only.\n     *\n     * This method assumes the left mouse button is already held down.\n     */\n    Drag.prototype.start = function (clientX, clientY) {\n        var _this = this;\n        // If the drag object is already disposed, resolve to `None`.\n        if (this._disposed) {\n            return Promise.resolve('none');\n        }\n        // If the drag has already been started, return the promise.\n        if (this._promise) {\n            return this._promise;\n        }\n        // Install the document listeners for the drag object.\n        this._addListeners();\n        // Attach the drag image at the specified client position.\n        this._attachDragImage(clientX, clientY);\n        // Create the promise which will be resolved on completion.\n        this._promise = new Promise(function (resolve, reject) {\n            _this._resolve = resolve;\n        });\n        // Trigger a fake move event to kick off the drag operation.\n        var event = Private.createMouseEvent('mousemove', clientX, clientY);\n        document.dispatchEvent(event);\n        // Return the pending promise for the drag operation.\n        return this._promise;\n    };\n    /**\n     * Handle the DOM events for the drag operation.\n     *\n     * @param event - The DOM event sent to the drag object.\n     *\n     * #### Notes\n     * This method implements the DOM `EventListener` interface and is\n     * called in response to events on the document. It should not be\n     * called directly by user code.\n     */\n    Drag.prototype.handleEvent = function (event) {\n        switch (event.type) {\n            case 'mousemove':\n                this._evtMouseMove(event);\n                break;\n            case 'mouseup':\n                this._evtMouseUp(event);\n                break;\n            case 'keydown':\n                this._evtKeyDown(event);\n                break;\n            default:\n                // Stop all other events during drag-drop.\n                event.preventDefault();\n                event.stopPropagation();\n                break;\n        }\n    };\n    /**\n     * Move the drag image element to the specified location.\n     *\n     * This is a no-op if there is no drag image element.\n     */\n    Drag.prototype.moveDragImage = function (clientX, clientY) {\n        if (!this.dragImage) {\n            return;\n        }\n        var style = this.dragImage.style;\n        style.top = clientY + \"px\";\n        style.left = clientX + \"px\";\n    };\n    /**\n     * Handle the `'mousemove'` event for the drag object.\n     */\n    Drag.prototype._evtMouseMove = function (event) {\n        // Stop all input events during drag-drop.\n        event.preventDefault();\n        event.stopPropagation();\n        // Update the current target node and dispatch enter/leave events.\n        this._updateCurrentTarget(event);\n        // Update the drag scroll element.\n        this._updateDragScroll(event);\n        // Move the drag image to the specified client position. This is\n        // performed *after* dispatching to prevent unnecessary reflows.\n        this.moveDragImage(event.clientX, event.clientY);\n    };\n    /**\n     * Handle the `'mouseup'` event for the drag object.\n     */\n    Drag.prototype._evtMouseUp = function (event) {\n        // Stop all input events during drag-drop.\n        event.preventDefault();\n        event.stopPropagation();\n        // Do nothing if the left button is not released.\n        if (event.button !== 0) {\n            return;\n        }\n        // Update the current target node and dispatch enter/leave events.\n        // This prevents a subtle issue where the DOM mutates under the\n        // cursor after the last move event but before the drop event.\n        this._updateCurrentTarget(event);\n        // If there is no current target, finalize with `'none'`.\n        if (!this._currentTarget) {\n            this._finalize('none');\n            return;\n        }\n        // If the last drop action was `'none'`, dispatch a leave event\n        // to the current target and finalize the drag with `'none'`.\n        if (this._dropAction === 'none') {\n            Private.dispatchDragLeave(this, this._currentTarget, null, event);\n            this._finalize('none');\n            return;\n        }\n        // Dispatch the drop event at the current target and finalize\n        // with the resulting drop action.\n        var action = Private.dispatchDrop(this, this._currentTarget, event);\n        this._finalize(action);\n    };\n    /**\n     * Handle the `'keydown'` event for the drag object.\n     */\n    Drag.prototype._evtKeyDown = function (event) {\n        // Stop all input events during drag-drop.\n        event.preventDefault();\n        event.stopPropagation();\n        // Cancel the drag if `Escape` is pressed.\n        if (event.keyCode === 27) {\n            this.dispose();\n        }\n    };\n    /**\n     * Add the document event listeners for the drag object.\n     */\n    Drag.prototype._addListeners = function () {\n        document.addEventListener('mousedown', this, true);\n        document.addEventListener('mousemove', this, true);\n        document.addEventListener('mouseup', this, true);\n        document.addEventListener('mouseenter', this, true);\n        document.addEventListener('mouseleave', this, true);\n        document.addEventListener('mouseover', this, true);\n        document.addEventListener('mouseout', this, true);\n        document.addEventListener('keydown', this, true);\n        document.addEventListener('keyup', this, true);\n        document.addEventListener('keypress', this, true);\n        document.addEventListener('contextmenu', this, true);\n    };\n    /**\n     * Remove the document event listeners for the drag object.\n     */\n    Drag.prototype._removeListeners = function () {\n        document.removeEventListener('mousedown', this, true);\n        document.removeEventListener('mousemove', this, true);\n        document.removeEventListener('mouseup', this, true);\n        document.removeEventListener('mouseenter', this, true);\n        document.removeEventListener('mouseleave', this, true);\n        document.removeEventListener('mouseover', this, true);\n        document.removeEventListener('mouseout', this, true);\n        document.removeEventListener('keydown', this, true);\n        document.removeEventListener('keyup', this, true);\n        document.removeEventListener('keypress', this, true);\n        document.removeEventListener('contextmenu', this, true);\n    };\n    /**\n     * Update the drag scroll element under the mouse.\n     */\n    Drag.prototype._updateDragScroll = function (event) {\n        // Find the scroll target under the mouse.\n        var target = Private.findScrollTarget(event);\n        // Bail if there is nothing to scroll.\n        if (!this._scrollTarget && !target) {\n            return;\n        }\n        // Start the scroll loop if needed.\n        if (!this._scrollTarget) {\n            setTimeout(this._onScrollFrame, 500);\n        }\n        // Update the scroll target.\n        this._scrollTarget = target;\n    };\n    /**\n     * Update the current target node using the given mouse event.\n     */\n    Drag.prototype._updateCurrentTarget = function (event) {\n        // Fetch common local state.\n        var prevTarget = this._currentTarget;\n        var currTarget = this._currentTarget;\n        var prevElem = this._currentElement;\n        // Find the current indicated element at the given position.\n        var currElem = document.elementFromPoint(event.clientX, event.clientY);\n        // Update the current element reference.\n        this._currentElement = currElem;\n        // If the indicated element changes from the previous iteration,\n        // and is different from the current target, dispatch the exit\n        // event to the target.\n        if (currElem !== prevElem && currElem !== currTarget) {\n            Private.dispatchDragExit(this, currTarget, currElem, event);\n        }\n        // If the indicated element changes from the previous iteration,\n        // and is different from the current target, dispatch the enter\n        // event and compute the new target element.\n        if (currElem !== prevElem && currElem !== currTarget) {\n            currTarget = Private.dispatchDragEnter(this, currElem, currTarget, event);\n        }\n        // If the current target element has changed, update the current\n        // target reference and dispatch the leave event to the old target.\n        if (currTarget !== prevTarget) {\n            this._currentTarget = currTarget;\n            Private.dispatchDragLeave(this, prevTarget, currTarget, event);\n        }\n        // Dispatch the drag over event and update the drop action.\n        var action = Private.dispatchDragOver(this, currTarget, event);\n        this._setDropAction(action);\n    };\n    /**\n     * Attach the drag image element at the specified location.\n     *\n     * This is a no-op if there is no drag image element.\n     */\n    Drag.prototype._attachDragImage = function (clientX, clientY) {\n        if (!this.dragImage) {\n            return;\n        }\n        this.dragImage.classList.add('lm-mod-drag-image');\n        /* <DEPRECATED> */\n        this.dragImage.classList.add('p-mod-drag-image');\n        /* </DEPRECATED> */\n        var style = this.dragImage.style;\n        style.pointerEvents = 'none';\n        style.position = 'fixed';\n        style.top = clientY + \"px\";\n        style.left = clientX + \"px\";\n        document.body.appendChild(this.dragImage);\n    };\n    /**\n     * Detach the drag image element from the DOM.\n     *\n     * This is a no-op if there is no drag image element.\n     */\n    Drag.prototype._detachDragImage = function () {\n        if (!this.dragImage) {\n            return;\n        }\n        var parent = this.dragImage.parentNode;\n        if (!parent) {\n            return;\n        }\n        parent.removeChild(this.dragImage);\n    };\n    /**\n     * Set the internal drop action state and update the drag cursor.\n     */\n    Drag.prototype._setDropAction = function (action) {\n        action = Private.validateAction(action, this.supportedActions);\n        if (this._override && this._dropAction === action) {\n            return;\n        }\n        switch (action) {\n            case 'none':\n                this._dropAction = action;\n                this._override = Drag.overrideCursor('no-drop');\n                break;\n            case 'copy':\n                this._dropAction = action;\n                this._override = Drag.overrideCursor('copy');\n                break;\n            case 'link':\n                this._dropAction = action;\n                this._override = Drag.overrideCursor('alias');\n                break;\n            case 'move':\n                this._dropAction = action;\n                this._override = Drag.overrideCursor('move');\n                break;\n        }\n    };\n    /**\n     * Finalize the drag operation and resolve the drag promise.\n     */\n    Drag.prototype._finalize = function (action) {\n        // Store the resolve function as a temp variable.\n        var resolve = this._resolve;\n        // Remove the document event listeners.\n        this._removeListeners();\n        // Detach the drag image.\n        this._detachDragImage();\n        // Dispose of the cursor override.\n        if (this._override) {\n            this._override.dispose();\n            this._override = null;\n        }\n        // Clear the mime data.\n        this.mimeData.clear();\n        // Clear the rest of the internal drag state.\n        this._disposed = true;\n        this._dropAction = 'none';\n        this._currentTarget = null;\n        this._currentElement = null;\n        this._scrollTarget = null;\n        this._promise = null;\n        this._resolve = null;\n        // Finally, resolve the promise to the given drop action.\n        if (resolve) {\n            resolve(action);\n        }\n    };\n    return Drag;\n}());\n/**\n * The namespace for the `Drag` class statics.\n */\n(function (Drag) {\n    /**\n     * Override the cursor icon for the entire document.\n     *\n     * @param cursor - The string representing the cursor style.\n     *\n     * @returns A disposable which will clear the override when disposed.\n     *\n     * #### Notes\n     * The most recent call to `overrideCursor` takes precedence.\n     * Disposing an old override has no effect on the current override.\n     *\n     * This utility function is used by the `Drag` class to override the\n     * mouse cursor during a drag-drop operation, but it can also be used\n     * by other classes to fix the cursor icon during normal mouse drags.\n     *\n     * #### Example\n     * ```typescript\n     * import { Drag } from '@lumino/dragdrop';\n     *\n     * // Force the cursor to be 'wait' for the entire document.\n     * let override = Drag.overrideCursor('wait');\n     *\n     * // Clear the override by disposing the return value.\n     * override.dispose();\n     * ```\n     */\n    function overrideCursor(cursor) {\n        var id = ++overrideCursorID;\n        document.body.style.cursor = cursor;\n        document.body.classList.add('lm-mod-override-cursor');\n        /* <DEPRECATED> */\n        document.body.classList.add('p-mod-override-cursor');\n        /* </DEPRECATED> */\n        return new DisposableDelegate(function () {\n            if (id === overrideCursorID) {\n                document.body.style.cursor = '';\n                document.body.classList.remove('lm-mod-override-cursor');\n                /* <DEPRECATED> */\n                document.body.classList.remove('p-mod-override-cursor');\n                /* </DEPRECATED> */\n            }\n        });\n    }\n    Drag.overrideCursor = overrideCursor;\n    /**\n     * The internal id for the active cursor override.\n     */\n    var overrideCursorID = 0;\n})(Drag || (Drag = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private;\n(function (Private) {\n    /**\n     * The size of a drag scroll edge, in pixels.\n     */\n    Private.SCROLL_EDGE_SIZE = 20;\n    /**\n     * Validate the given action is one of the supported actions.\n     *\n     * Returns the given action or `'none'` if the action is unsupported.\n     */\n    function validateAction(action, supported) {\n        return (actionTable[action] & supportedTable[supported]) ? action : 'none';\n    }\n    Private.validateAction = validateAction;\n    /**\n     * Create a left mouse event at the given position.\n     *\n     * @param type - The event type for the mouse event.\n     *\n     * @param clientX - The client X position.\n     *\n     * @param clientY - The client Y position.\n     *\n     * @returns A newly created and initialized mouse event.\n     */\n    function createMouseEvent(type, clientX, clientY) {\n        var event = document.createEvent('MouseEvent');\n        event.initMouseEvent(type, true, true, window, 0, 0, 0, clientX, clientY, false, false, false, false, 0, null);\n        return event;\n    }\n    Private.createMouseEvent = createMouseEvent;\n    /**\n     * Find the drag scroll target under the mouse, if any.\n     */\n    function findScrollTarget(event) {\n        // Look up the client mouse position.\n        var x = event.clientX;\n        var y = event.clientY;\n        // Get the element under the mouse.\n        var element = document.elementFromPoint(x, y);\n        // Search for a scrollable target based on the mouse position.\n        // The null assert in third clause of for-loop is required due to:\n        // https://github.com/Microsoft/TypeScript/issues/14143\n        for (; element; element = element.parentElement) {\n            // Ignore elements which are not marked as scrollable.\n            var scrollable = element.hasAttribute('data-lm-dragscroll');\n            /* <DEPRECATED> */\n            scrollable = scrollable || element.hasAttribute('data-p-dragscroll');\n            /* </DEPRECATED> */\n            if (!scrollable) {\n                continue;\n            }\n            // Set up the coordinate offsets for the element.\n            var offsetX = 0;\n            var offsetY = 0;\n            if (element === document.body) {\n                offsetX = window.pageXOffset;\n                offsetY = window.pageYOffset;\n            }\n            // Get the element bounds in viewport coordinates.\n            var r = element.getBoundingClientRect();\n            var top_1 = r.top + offsetY;\n            var left = r.left + offsetX;\n            var right = left + r.width;\n            var bottom = top_1 + r.height;\n            // Skip the element if it's not under the mouse.\n            if (x < left || x >= right || y < top_1 || y >= bottom) {\n                continue;\n            }\n            // Compute the distance to each edge.\n            var dl = x - left + 1;\n            var dt = y - top_1 + 1;\n            var dr = right - x;\n            var db = bottom - y;\n            // Find the smallest of the edge distances.\n            var distance = Math.min(dl, dt, dr, db);\n            // Skip the element if the mouse is not within a scroll edge.\n            if (distance > Private.SCROLL_EDGE_SIZE) {\n                continue;\n            }\n            // Set up the edge result variable.\n            var edge = void 0;\n            // Find the edge for the computed distance.\n            switch (distance) {\n                case db:\n                    edge = 'bottom';\n                    break;\n                case dt:\n                    edge = 'top';\n                    break;\n                case dr:\n                    edge = 'right';\n                    break;\n                case dl:\n                    edge = 'left';\n                    break;\n                default:\n                    throw 'unreachable';\n            }\n            // Compute how much the element can scroll in width and height.\n            var dsw = element.scrollWidth - element.clientWidth;\n            var dsh = element.scrollHeight - element.clientHeight;\n            // Determine if the element should be scrolled for the edge.\n            var shouldScroll = void 0;\n            switch (edge) {\n                case 'top':\n                    shouldScroll = dsh > 0 && element.scrollTop > 0;\n                    break;\n                case 'left':\n                    shouldScroll = dsw > 0 && element.scrollLeft > 0;\n                    break;\n                case 'right':\n                    shouldScroll = dsw > 0 && element.scrollLeft < dsw;\n                    break;\n                case 'bottom':\n                    shouldScroll = dsh > 0 && element.scrollTop < dsh;\n                    break;\n                default:\n                    throw 'unreachable';\n            }\n            // Skip the element if it should not be scrolled.\n            if (!shouldScroll) {\n                continue;\n            }\n            // Return the drag scroll target.\n            return { element: element, edge: edge, distance: distance };\n        }\n        // No drag scroll target was found.\n        return null;\n    }\n    Private.findScrollTarget = findScrollTarget;\n    /**\n     * Dispatch a drag enter event to the indicated element.\n     *\n     * @param drag - The drag object associated with the action.\n     *\n     * @param currElem - The currently indicated element, or `null`. This\n     *   is the \"immediate user selection\" from the whatwg spec.\n     *\n     * @param currTarget - The current drag target element, or `null`. This\n     *   is the \"current target element\" from the whatwg spec.\n     *\n     * @param event - The mouse event related to the action.\n     *\n     * @returns The element to use as the current drag target. This is the\n     *   \"current target element\" from the whatwg spec, and may be `null`.\n     *\n     * #### Notes\n     * This largely implements the drag enter portion of the whatwg spec:\n     * https://html.spec.whatwg.org/multipage/interaction.html#drag-and-drop-processing-model\n     */\n    function dispatchDragEnter(drag, currElem, currTarget, event) {\n        // If the current element is null, return null as the new target.\n        if (!currElem) {\n            return null;\n        }\n        // Dispatch a drag enter event to the current element.\n        var dragEvent = createDragEvent('lm-dragenter', drag, event, currTarget);\n        var canceled = !currElem.dispatchEvent(dragEvent);\n        // If the event was canceled, use the current element as the new target.\n        if (canceled) {\n            return currElem;\n        }\n        /* <DEPRECATED> */\n        dragEvent = createDragEvent('p-dragenter', drag, event, currTarget);\n        canceled = !currElem.dispatchEvent(dragEvent);\n        if (canceled) {\n            return currElem;\n        }\n        /* </DEPRECATED> */\n        // If the current element is the document body, keep the original target.\n        if (currElem === document.body) {\n            return currTarget;\n        }\n        // Dispatch a drag enter event on the document body.\n        dragEvent = createDragEvent('lm-dragenter', drag, event, currTarget);\n        document.body.dispatchEvent(dragEvent);\n        /* <DEPRECATED> */\n        dragEvent = createDragEvent('p-dragenter', drag, event, currTarget);\n        document.body.dispatchEvent(dragEvent);\n        /* </DEPRECATED> */\n        // Ignore the event cancellation, and use the body as the new target.\n        return document.body;\n    }\n    Private.dispatchDragEnter = dispatchDragEnter;\n    /**\n     * Dispatch a drag exit event to the indicated element.\n     *\n     * @param drag - The drag object associated with the action.\n     *\n     * @param prevTarget - The previous target element, or `null`. This\n     *   is the previous \"current target element\" from the whatwg spec.\n     *\n     * @param currTarget - The current drag target element, or `null`. This\n     *   is the \"current target element\" from the whatwg spec.\n     *\n     * @param event - The mouse event related to the action.\n     *\n     * #### Notes\n     * This largely implements the drag exit portion of the whatwg spec:\n     * https://html.spec.whatwg.org/multipage/interaction.html#drag-and-drop-processing-model\n     */\n    function dispatchDragExit(drag, prevTarget, currTarget, event) {\n        // If the previous target is null, do nothing.\n        if (!prevTarget) {\n            return;\n        }\n        // Dispatch the drag exit event to the previous target.\n        var dragEvent = createDragEvent('lm-dragexit', drag, event, currTarget);\n        prevTarget.dispatchEvent(dragEvent);\n        /* <DEPRECATED> */\n        dragEvent = createDragEvent('p-dragexit', drag, event, currTarget);\n        prevTarget.dispatchEvent(dragEvent);\n        /* </DEPRECATED> */\n    }\n    Private.dispatchDragExit = dispatchDragExit;\n    /**\n     * Dispatch a drag leave event to the indicated element.\n     *\n     * @param drag - The drag object associated with the action.\n     *\n     * @param prevTarget - The previous target element, or `null`. This\n     *   is the previous \"current target element\" from the whatwg spec.\n     *\n     * @param currTarget - The current drag target element, or `null`. This\n     *   is the \"current target element\" from the whatwg spec.\n     *\n     * @param event - The mouse event related to the action.\n     *\n     * #### Notes\n     * This largely implements the drag leave portion of the whatwg spec:\n     * https://html.spec.whatwg.org/multipage/interaction.html#drag-and-drop-processing-model\n     */\n    function dispatchDragLeave(drag, prevTarget, currTarget, event) {\n        // If the previous target is null, do nothing.\n        if (!prevTarget) {\n            return;\n        }\n        // Dispatch the drag leave event to the previous target.\n        var dragEvent = createDragEvent('lm-dragleave', drag, event, currTarget);\n        prevTarget.dispatchEvent(dragEvent);\n        /* <DEPRECATED> */\n        dragEvent = createDragEvent('p-dragleave', drag, event, currTarget);\n        prevTarget.dispatchEvent(dragEvent);\n        /* </DEPRECATED> */\n    }\n    Private.dispatchDragLeave = dispatchDragLeave;\n    /**\n     * Dispatch a drag over event to the indicated element.\n     *\n     * @param drag - The drag object associated with the action.\n     *\n     * @param currTarget - The current drag target element, or `null`. This\n     *   is the \"current target element\" from the whatwg spec.\n     *\n     * @param event - The mouse event related to the action.\n     *\n     * @returns The `DropAction` result of the drag over event.\n     *\n     * #### Notes\n     * This largely implements the drag over portion of the whatwg spec:\n     * https://html.spec.whatwg.org/multipage/interaction.html#drag-and-drop-processing-model\n     */\n    function dispatchDragOver(drag, currTarget, event) {\n        // If there is no current target, the drop action is none.\n        if (!currTarget) {\n            return 'none';\n        }\n        // Dispatch the drag over event to the current target.\n        var dragEvent = createDragEvent('lm-dragover', drag, event, null);\n        var canceled = !currTarget.dispatchEvent(dragEvent);\n        // If the event was canceled, return the drop action result.\n        if (canceled) {\n            return dragEvent.dropAction;\n        }\n        /* <DEPRECATED> */\n        dragEvent = createDragEvent('p-dragover', drag, event, null);\n        canceled = !currTarget.dispatchEvent(dragEvent);\n        if (canceled) {\n            return dragEvent.dropAction;\n        }\n        /* </DEPRECATED> */\n        // Otherwise, the effective drop action is none.\n        return 'none';\n    }\n    Private.dispatchDragOver = dispatchDragOver;\n    /**\n     * Dispatch a drop event to the indicated element.\n     *\n     * @param drag - The drag object associated with the action.\n     *\n     * @param currTarget - The current drag target element, or `null`. This\n     *   is the \"current target element\" from the whatwg spec.\n     *\n     * @param event - The mouse event related to the action.\n     *\n     * @returns The `DropAction` result of the drop event.\n     *\n     * #### Notes\n     * This largely implements the drag over portion of the whatwg spec:\n     * https://html.spec.whatwg.org/multipage/interaction.html#drag-and-drop-processing-model\n     */\n    function dispatchDrop(drag, currTarget, event) {\n        // If there is no current target, the drop action is none.\n        if (!currTarget) {\n            return 'none';\n        }\n        // Dispatch the drop event to the current target.\n        var dragEvent = createDragEvent('lm-drop', drag, event, null);\n        var canceled = !currTarget.dispatchEvent(dragEvent);\n        // If the event was canceled, return the drop action result.\n        if (canceled) {\n            return dragEvent.dropAction;\n        }\n        /* <DEPRECATED> */\n        dragEvent = createDragEvent('p-drop', drag, event, null);\n        canceled = !currTarget.dispatchEvent(dragEvent);\n        if (canceled) {\n            return dragEvent.dropAction;\n        }\n        /* </DEPRECATED> */\n        // Otherwise, the effective drop action is none.\n        return 'none';\n    }\n    Private.dispatchDrop = dispatchDrop;\n    /**\n     * A lookup table from drop action to bit value.\n     */\n    var actionTable = {\n        'none': 0x0,\n        'copy': 0x1,\n        'link': 0x2,\n        'move': 0x4\n    };\n    /**\n     * A lookup table from supported action to drop action bit mask.\n     */\n    var supportedTable = {\n        'none': actionTable['none'],\n        'copy': actionTable['copy'],\n        'link': actionTable['link'],\n        'move': actionTable['move'],\n        'copy-link': actionTable['copy'] | actionTable['link'],\n        'copy-move': actionTable['copy'] | actionTable['move'],\n        'link-move': actionTable['link'] | actionTable['move'],\n        'all': actionTable['copy'] | actionTable['link'] | actionTable['move']\n    };\n    /**\n     * Create a new initialized `IDragEvent` from the given data.\n     *\n     * @param type - The event type for the drag event.\n     *\n     * @param drag - The drag object to use for seeding the drag data.\n     *\n     * @param event - The mouse event to use for seeding the mouse data.\n     *\n     * @param related - The related target for the event, or `null`.\n     *\n     * @returns A new object which implements `IDragEvent`.\n     */\n    function createDragEvent(type, drag, event, related) {\n        // Create a new mouse event to use as the drag event. Currently,\n        // JS engines do now allow user-defined Event subclasses.\n        var dragEvent = document.createEvent('MouseEvent');\n        // Initialize the mouse event data.\n        dragEvent.initMouseEvent(type, true, true, window, 0, event.screenX, event.screenY, event.clientX, event.clientY, event.ctrlKey, event.altKey, event.shiftKey, event.metaKey, event.button, related);\n        // Forcefully add the custom drag event properties.\n        dragEvent.dropAction = 'none';\n        dragEvent.mimeData = drag.mimeData;\n        dragEvent.proposedAction = drag.proposedAction;\n        dragEvent.supportedActions = drag.supportedActions;\n        dragEvent.source = drag.source;\n        // Return the fully initialized drag event.\n        return dragEvent;\n    }\n})(Private || (Private = {}));\n\nexport { Drag };\n//# sourceMappingURL=index.es6.js.map\n","import { empty, each, iter, ArrayExt, StringExt, chain, once, map, ChainIterator, reduce, find, toArray, filter, max } from '@lumino/algorithm';\nimport { ElementExt, Selector, Platform } from '@lumino/domutils';\nimport { MessageLoop, Message, ConflatableMessage } from '@lumino/messaging';\nimport { AttachedProperty } from '@lumino/properties';\nimport { Signal } from '@lumino/signaling';\nimport { JSONExt, MimeData } from '@lumino/coreutils';\nimport { CommandRegistry } from '@lumino/commands';\nimport { VirtualDOM, h } from '@lumino/virtualdom';\nimport { DisposableDelegate } from '@lumino/disposable';\nimport { getKeyboardLayout } from '@lumino/keyboard';\nimport { Drag } from '@lumino/dragdrop';\n\n// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * A sizer object for use with the box engine layout functions.\n *\n * #### Notes\n * A box sizer holds the geometry information for an object along an\n * arbitrary layout orientation.\n *\n * For best performance, this class should be treated as a raw data\n * struct. It should not typically be subclassed.\n */\nvar BoxSizer = /** @class */ (function () {\n    function BoxSizer() {\n        /**\n         * The preferred size for the sizer.\n         *\n         * #### Notes\n         * The sizer will be given this initial size subject to its size\n         * bounds. The sizer will not deviate from this size unless such\n         * deviation is required to fit into the available layout space.\n         *\n         * There is no limit to this value, but it will be clamped to the\n         * bounds defined by [[minSize]] and [[maxSize]].\n         *\n         * The default value is `0`.\n         */\n        this.sizeHint = 0;\n        /**\n         * The minimum size of the sizer.\n         *\n         * #### Notes\n         * The sizer will never be sized less than this value, even if\n         * it means the sizer will overflow the available layout space.\n         *\n         * It is assumed that this value lies in the range `[0, Infinity)`\n         * and that it is `<=` to [[maxSize]]. Failure to adhere to this\n         * constraint will yield undefined results.\n         *\n         * The default value is `0`.\n         */\n        this.minSize = 0;\n        /**\n         * The maximum size of the sizer.\n         *\n         * #### Notes\n         * The sizer will never be sized greater than this value, even if\n         * it means the sizer will underflow the available layout space.\n         *\n         * It is assumed that this value lies in the range `[0, Infinity]`\n         * and that it is `>=` to [[minSize]]. Failure to adhere to this\n         * constraint will yield undefined results.\n         *\n         * The default value is `Infinity`.\n         */\n        this.maxSize = Infinity;\n        /**\n         * The stretch factor for the sizer.\n         *\n         * #### Notes\n         * This controls how much the sizer stretches relative to its sibling\n         * sizers when layout space is distributed. A stretch factor of zero\n         * is special and will cause the sizer to only be resized after all\n         * other sizers with a stretch factor greater than zero have been\n         * resized to their limits.\n         *\n         * It is assumed that this value is an integer that lies in the range\n         * `[0, Infinity)`. Failure to adhere to this constraint will yield\n         * undefined results.\n         *\n         * The default value is `1`.\n         */\n        this.stretch = 1;\n        /**\n         * The computed size of the sizer.\n         *\n         * #### Notes\n         * This value is the output of a call to [[boxCalc]]. It represents\n         * the computed size for the object along the layout orientation,\n         * and will always lie in the range `[minSize, maxSize]`.\n         *\n         * This value is output only.\n         *\n         * Changing this value will have no effect.\n         */\n        this.size = 0;\n        /**\n         * An internal storage property for the layout algorithm.\n         *\n         * #### Notes\n         * This value is used as temporary storage by the layout algorithm.\n         *\n         * Changing this value will have no effect.\n         */\n        this.done = false;\n    }\n    return BoxSizer;\n}());\n/**\n * The namespace for the box engine layout functions.\n */\nvar BoxEngine;\n(function (BoxEngine) {\n    /**\n     * Calculate the optimal layout sizes for a sequence of box sizers.\n     *\n     * This distributes the available layout space among the box sizers\n     * according to the following algorithm:\n     *\n     * 1. Initialize the sizers's size to its size hint and compute the\n     *    sums for each of size hint, min size, and max size.\n     *\n     * 2. If the total size hint equals the available space, return.\n     *\n     * 3. If the available space is less than the total min size, set all\n     *    sizers to their min size and return.\n     *\n     * 4. If the available space is greater than the total max size, set\n     *    all sizers to their max size and return.\n     *\n     * 5. If the layout space is less than the total size hint, distribute\n     *    the negative delta as follows:\n     *\n     *    a. Shrink each sizer with a stretch factor greater than zero by\n     *       an amount proportional to the negative space and the sum of\n     *       stretch factors. If the sizer reaches its min size, remove\n     *       it and its stretch factor from the computation.\n     *\n     *    b. If after adjusting all stretch sizers there remains negative\n     *       space, distribute the space equally among the sizers with a\n     *       stretch factor of zero. If a sizer reaches its min size,\n     *       remove it from the computation.\n     *\n     * 6. If the layout space is greater than the total size hint,\n     *    distribute the positive delta as follows:\n     *\n     *    a. Expand each sizer with a stretch factor greater than zero by\n     *       an amount proportional to the postive space and the sum of\n     *       stretch factors. If the sizer reaches its max size, remove\n     *       it and its stretch factor from the computation.\n     *\n     *    b. If after adjusting all stretch sizers there remains positive\n     *       space, distribute the space equally among the sizers with a\n     *       stretch factor of zero. If a sizer reaches its max size,\n     *       remove it from the computation.\n     *\n     * 7. return\n     *\n     * @param sizers - The sizers for a particular layout line.\n     *\n     * @param space - The available layout space for the sizers.\n     *\n     * @returns The delta between the provided available space and the\n     *   actual consumed space. This value will be zero if the sizers\n     *   can be adjusted to fit, negative if the available space is too\n     *   small, and positive if the available space is too large.\n     *\n     * #### Notes\n     * The [[size]] of each sizer is updated with the computed size.\n     *\n     * This function can be called at any time to recompute the layout for\n     * an existing sequence of sizers. The previously computed results will\n     * have no effect on the new output. It is therefore not necessary to\n     * create new sizer objects on each resize event.\n     */\n    function calc(sizers, space) {\n        // Bail early if there is nothing to do.\n        var count = sizers.length;\n        if (count === 0) {\n            return space;\n        }\n        // Setup the size and stretch counters.\n        var totalMin = 0;\n        var totalMax = 0;\n        var totalSize = 0;\n        var totalStretch = 0;\n        var stretchCount = 0;\n        // Setup the sizers and compute the totals.\n        for (var i = 0; i < count; ++i) {\n            var sizer = sizers[i];\n            var min = sizer.minSize;\n            var max = sizer.maxSize;\n            var hint = sizer.sizeHint;\n            sizer.done = false;\n            sizer.size = Math.max(min, Math.min(hint, max));\n            totalSize += sizer.size;\n            totalMin += min;\n            totalMax += max;\n            if (sizer.stretch > 0) {\n                totalStretch += sizer.stretch;\n                stretchCount++;\n            }\n        }\n        // If the space is equal to the total size, return early.\n        if (space === totalSize) {\n            return 0;\n        }\n        // If the space is less than the total min, minimize each sizer.\n        if (space <= totalMin) {\n            for (var i = 0; i < count; ++i) {\n                var sizer = sizers[i];\n                sizer.size = sizer.minSize;\n            }\n            return space - totalMin;\n        }\n        // If the space is greater than the total max, maximize each sizer.\n        if (space >= totalMax) {\n            for (var i = 0; i < count; ++i) {\n                var sizer = sizers[i];\n                sizer.size = sizer.maxSize;\n            }\n            return space - totalMax;\n        }\n        // The loops below perform sub-pixel precision sizing. A near zero\n        // value is used for compares instead of zero to ensure that the\n        // loop terminates when the subdivided space is reasonably small.\n        var nearZero = 0.01;\n        // A counter which is decremented each time a sizer is resized to\n        // its limit. This ensures the loops terminate even if there is\n        // space remaining to distribute.\n        var notDoneCount = count;\n        // Distribute negative delta space.\n        if (space < totalSize) {\n            // Shrink each stretchable sizer by an amount proportional to its\n            // stretch factor. If a sizer reaches its min size it's marked as\n            // done. The loop progresses in phases where each sizer is given\n            // a chance to consume its fair share for the pass, regardless of\n            // whether a sizer before it reached its limit. This continues\n            // until the stretchable sizers or the free space is exhausted.\n            var freeSpace = totalSize - space;\n            while (stretchCount > 0 && freeSpace > nearZero) {\n                var distSpace = freeSpace;\n                var distStretch = totalStretch;\n                for (var i = 0; i < count; ++i) {\n                    var sizer = sizers[i];\n                    if (sizer.done || sizer.stretch === 0) {\n                        continue;\n                    }\n                    var amt = sizer.stretch * distSpace / distStretch;\n                    if (sizer.size - amt <= sizer.minSize) {\n                        freeSpace -= sizer.size - sizer.minSize;\n                        totalStretch -= sizer.stretch;\n                        sizer.size = sizer.minSize;\n                        sizer.done = true;\n                        notDoneCount--;\n                        stretchCount--;\n                    }\n                    else {\n                        freeSpace -= amt;\n                        sizer.size -= amt;\n                    }\n                }\n            }\n            // Distribute any remaining space evenly among the non-stretchable\n            // sizers. This progresses in phases in the same manner as above.\n            while (notDoneCount > 0 && freeSpace > nearZero) {\n                var amt = freeSpace / notDoneCount;\n                for (var i = 0; i < count; ++i) {\n                    var sizer = sizers[i];\n                    if (sizer.done) {\n                        continue;\n                    }\n                    if (sizer.size - amt <= sizer.minSize) {\n                        freeSpace -= sizer.size - sizer.minSize;\n                        sizer.size = sizer.minSize;\n                        sizer.done = true;\n                        notDoneCount--;\n                    }\n                    else {\n                        freeSpace -= amt;\n                        sizer.size -= amt;\n                    }\n                }\n            }\n        }\n        // Distribute positive delta space.\n        else {\n            // Expand each stretchable sizer by an amount proportional to its\n            // stretch factor. If a sizer reaches its max size it's marked as\n            // done. The loop progresses in phases where each sizer is given\n            // a chance to consume its fair share for the pass, regardless of\n            // whether a sizer before it reached its limit. This continues\n            // until the stretchable sizers or the free space is exhausted.\n            var freeSpace = space - totalSize;\n            while (stretchCount > 0 && freeSpace > nearZero) {\n                var distSpace = freeSpace;\n                var distStretch = totalStretch;\n                for (var i = 0; i < count; ++i) {\n                    var sizer = sizers[i];\n                    if (sizer.done || sizer.stretch === 0) {\n                        continue;\n                    }\n                    var amt = sizer.stretch * distSpace / distStretch;\n                    if (sizer.size + amt >= sizer.maxSize) {\n                        freeSpace -= sizer.maxSize - sizer.size;\n                        totalStretch -= sizer.stretch;\n                        sizer.size = sizer.maxSize;\n                        sizer.done = true;\n                        notDoneCount--;\n                        stretchCount--;\n                    }\n                    else {\n                        freeSpace -= amt;\n                        sizer.size += amt;\n                    }\n                }\n            }\n            // Distribute any remaining space evenly among the non-stretchable\n            // sizers. This progresses in phases in the same manner as above.\n            while (notDoneCount > 0 && freeSpace > nearZero) {\n                var amt = freeSpace / notDoneCount;\n                for (var i = 0; i < count; ++i) {\n                    var sizer = sizers[i];\n                    if (sizer.done) {\n                        continue;\n                    }\n                    if (sizer.size + amt >= sizer.maxSize) {\n                        freeSpace -= sizer.maxSize - sizer.size;\n                        sizer.size = sizer.maxSize;\n                        sizer.done = true;\n                        notDoneCount--;\n                    }\n                    else {\n                        freeSpace -= amt;\n                        sizer.size += amt;\n                    }\n                }\n            }\n        }\n        // Indicate that the consumed space equals the available space.\n        return 0;\n    }\n    BoxEngine.calc = calc;\n    /**\n     * Adjust a sizer by a delta and update its neighbors accordingly.\n     *\n     * @param sizers - The sizers which should be adjusted.\n     *\n     * @param index - The index of the sizer to grow.\n     *\n     * @param delta - The amount to adjust the sizer, positive or negative.\n     *\n     * #### Notes\n     * This will adjust the indicated sizer by the specified amount, along\n     * with the sizes of the appropriate neighbors, subject to the limits\n     * specified by each of the sizers.\n     *\n     * This is useful when implementing box layouts where the boundaries\n     * between the sizers are interactively adjustable by the user.\n     */\n    function adjust(sizers, index, delta) {\n        // Bail early when there is nothing to do.\n        if (sizers.length === 0 || delta === 0) {\n            return;\n        }\n        // Dispatch to the proper implementation.\n        if (delta > 0) {\n            growSizer(sizers, index, delta);\n        }\n        else {\n            shrinkSizer(sizers, index, -delta);\n        }\n    }\n    BoxEngine.adjust = adjust;\n    /**\n     * Grow a sizer by a positive delta and adjust neighbors.\n     */\n    function growSizer(sizers, index, delta) {\n        // Compute how much the items to the left can expand.\n        var growLimit = 0;\n        for (var i = 0; i <= index; ++i) {\n            var sizer = sizers[i];\n            growLimit += sizer.maxSize - sizer.size;\n        }\n        // Compute how much the items to the right can shrink.\n        var shrinkLimit = 0;\n        for (var i = index + 1, n = sizers.length; i < n; ++i) {\n            var sizer = sizers[i];\n            shrinkLimit += sizer.size - sizer.minSize;\n        }\n        // Clamp the delta adjustment to the limits.\n        delta = Math.min(delta, growLimit, shrinkLimit);\n        // Grow the sizers to the left by the delta.\n        var grow = delta;\n        for (var i = index; i >= 0 && grow > 0; --i) {\n            var sizer = sizers[i];\n            var limit = sizer.maxSize - sizer.size;\n            if (limit >= grow) {\n                sizer.sizeHint = sizer.size + grow;\n                grow = 0;\n            }\n            else {\n                sizer.sizeHint = sizer.size + limit;\n                grow -= limit;\n            }\n        }\n        // Shrink the sizers to the right by the delta.\n        var shrink = delta;\n        for (var i = index + 1, n = sizers.length; i < n && shrink > 0; ++i) {\n            var sizer = sizers[i];\n            var limit = sizer.size - sizer.minSize;\n            if (limit >= shrink) {\n                sizer.sizeHint = sizer.size - shrink;\n                shrink = 0;\n            }\n            else {\n                sizer.sizeHint = sizer.size - limit;\n                shrink -= limit;\n            }\n        }\n    }\n    /**\n     * Shrink a sizer by a positive delta and adjust neighbors.\n     */\n    function shrinkSizer(sizers, index, delta) {\n        // Compute how much the items to the right can expand.\n        var growLimit = 0;\n        for (var i = index + 1, n = sizers.length; i < n; ++i) {\n            var sizer = sizers[i];\n            growLimit += sizer.maxSize - sizer.size;\n        }\n        // Compute how much the items to the left can shrink.\n        var shrinkLimit = 0;\n        for (var i = 0; i <= index; ++i) {\n            var sizer = sizers[i];\n            shrinkLimit += sizer.size - sizer.minSize;\n        }\n        // Clamp the delta adjustment to the limits.\n        delta = Math.min(delta, growLimit, shrinkLimit);\n        // Grow the sizers to the right by the delta.\n        var grow = delta;\n        for (var i = index + 1, n = sizers.length; i < n && grow > 0; ++i) {\n            var sizer = sizers[i];\n            var limit = sizer.maxSize - sizer.size;\n            if (limit >= grow) {\n                sizer.sizeHint = sizer.size + grow;\n                grow = 0;\n            }\n            else {\n                sizer.sizeHint = sizer.size + limit;\n                grow -= limit;\n            }\n        }\n        // Shrink the sizers to the left by the delta.\n        var shrink = delta;\n        for (var i = index; i >= 0 && shrink > 0; --i) {\n            var sizer = sizers[i];\n            var limit = sizer.size - sizer.minSize;\n            if (limit >= shrink) {\n                sizer.sizeHint = sizer.size - shrink;\n                shrink = 0;\n            }\n            else {\n                sizer.sizeHint = sizer.size - limit;\n                shrink -= limit;\n            }\n        }\n    }\n})(BoxEngine || (BoxEngine = {}));\n\n/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\r\nthis file except in compliance with the License. You may obtain a copy of the\r\nLicense at http://www.apache.org/licenses/LICENSE-2.0\r\n\r\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\r\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\r\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\r\nMERCHANTABLITY OR NON-INFRINGEMENT.\r\n\r\nSee the Apache Version 2.0 License for specific language governing permissions\r\nand limitations under the License.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n    extendStatics = Object.setPrototypeOf ||\r\n        ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n        function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\r\n    return extendStatics(d, b);\r\n};\r\n\r\nfunction __extends(d, b) {\r\n    extendStatics(d, b);\r\n    function __() { this.constructor = d; }\r\n    d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nvar __assign = function() {\r\n    __assign = Object.assign || function __assign(t) {\r\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n            s = arguments[i];\r\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n        }\r\n        return t;\r\n    };\r\n    return __assign.apply(this, arguments);\r\n};\n\n// Copyright (c) Jupyter Development Team.\n/**\n * An object which holds data related to an object's title.\n *\n * #### Notes\n * A title object is intended to hold the data necessary to display a\n * header for a particular object. A common example is the `TabPanel`,\n * which uses the widget title to populate the tab for a child widget.\n */\nvar Title = /** @class */ (function () {\n    /**\n     * Construct a new title.\n     *\n     * @param options - The options for initializing the title.\n     */\n    function Title(options) {\n        this._label = '';\n        this._caption = '';\n        this._mnemonic = -1;\n        this._iconClass = '';\n        this._iconLabel = '';\n        this._className = '';\n        this._closable = false;\n        this._changed = new Signal(this);\n        this.owner = options.owner;\n        if (options.label !== undefined) {\n            this._label = options.label;\n        }\n        if (options.mnemonic !== undefined) {\n            this._mnemonic = options.mnemonic;\n        }\n        if (options.icon !== undefined) {\n            /* <DEPRECATED> */\n            if (typeof options.icon === \"string\") {\n                // when ._icon is null, the .icon getter will alias .iconClass\n                this._icon = null;\n                this._iconClass = options.icon;\n            }\n            else {\n                /* </DEPRECATED> */\n                this._icon = options.icon;\n                /* <DEPRECATED> */\n            }\n            /* </DEPRECATED> */\n        }\n        /* <DEPRECATED> */\n        else {\n            // if unset, default to aliasing .iconClass\n            this._icon = null;\n        }\n        /* </DEPRECATED> */\n        if (options.iconClass !== undefined) {\n            this._iconClass = options.iconClass;\n        }\n        if (options.iconLabel !== undefined) {\n            this._iconLabel = options.iconLabel;\n        }\n        if (options.iconRenderer !== undefined) {\n            this._icon = options.iconRenderer;\n        }\n        if (options.caption !== undefined) {\n            this._caption = options.caption;\n        }\n        if (options.className !== undefined) {\n            this._className = options.className;\n        }\n        if (options.closable !== undefined) {\n            this._closable = options.closable;\n        }\n        this._dataset = options.dataset || {};\n    }\n    Object.defineProperty(Title.prototype, \"changed\", {\n        /**\n         * A signal emitted when the state of the title changes.\n         */\n        get: function () {\n            return this._changed;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Title.prototype, \"label\", {\n        /**\n         * Get the label for the title.\n         *\n         * #### Notes\n         * The default value is an empty string.\n         */\n        get: function () {\n            return this._label;\n        },\n        /**\n         * Set the label for the title.\n         */\n        set: function (value) {\n            if (this._label === value) {\n                return;\n            }\n            this._label = value;\n            this._changed.emit(undefined);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Title.prototype, \"mnemonic\", {\n        /**\n         * Get the mnemonic index for the title.\n         *\n         * #### Notes\n         * The default value is `-1`.\n         */\n        get: function () {\n            return this._mnemonic;\n        },\n        /**\n         * Set the mnemonic index for the title.\n         */\n        set: function (value) {\n            if (this._mnemonic === value) {\n                return;\n            }\n            this._mnemonic = value;\n            this._changed.emit(undefined);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Title.prototype, \"icon\", {\n        /**\n         * Get the icon renderer for the title.\n         *\n         * #### Notes\n         * The default value is undefined.\n         *\n         * DEPRECATED: if set to a string value, the .icon field will function as\n         * an alias for the .iconClass field, for backwards compatibility\n         */\n        get: function () {\n            /* <DEPRECATED> */\n            if (this._icon === null) {\n                // only alias .iconClass if ._icon has been explicitly nulled\n                return this.iconClass;\n            }\n            /* </DEPRECATED> */\n            return this._icon;\n        },\n        /**\n         * Set the icon renderer for the title.\n         *\n         * #### Notes\n         * A renderer is an object that supplies a render and unrender function.\n         *\n         * DEPRECATED: if set to a string value, the .icon field will function as\n         * an alias for the .iconClass field, for backwards compatibility\n         */\n        set: function (value /* </DEPRECATED> */) {\n            /* <DEPRECATED> */\n            if (typeof value === \"string\") {\n                // when ._icon is null, the .icon getter will alias .iconClass\n                this._icon = null;\n                this.iconClass = value;\n            }\n            else {\n                /* </DEPRECATED> */\n                if (this._icon === value) {\n                    return;\n                }\n                this._icon = value;\n                this._changed.emit(undefined);\n                /* <DEPRECATED> */\n            }\n            /* </DEPRECATED> */\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Title.prototype, \"iconClass\", {\n        /**\n         * Get the icon class name for the title.\n         *\n         * #### Notes\n         * The default value is an empty string.\n         */\n        get: function () {\n            return this._iconClass;\n        },\n        /**\n         * Set the icon class name for the title.\n         *\n         * #### Notes\n         * Multiple class names can be separated with whitespace.\n         */\n        set: function (value) {\n            if (this._iconClass === value) {\n                return;\n            }\n            this._iconClass = value;\n            this._changed.emit(undefined);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Title.prototype, \"iconLabel\", {\n        /**\n         * Get the icon label for the title.\n         *\n         * #### Notes\n         * The default value is an empty string.\n         */\n        get: function () {\n            return this._iconLabel;\n        },\n        /**\n         * Set the icon label for the title.\n         *\n         * #### Notes\n         * Multiple class names can be separated with whitespace.\n         */\n        set: function (value) {\n            if (this._iconLabel === value) {\n                return;\n            }\n            this._iconLabel = value;\n            this._changed.emit(undefined);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Title.prototype, \"iconRenderer\", {\n        /**\n         * @deprecated Use `icon` instead.\n         */\n        get: function () {\n            return this._icon || undefined;\n        },\n        /**\n         * @deprecated Use `icon` instead.\n         */\n        set: function (value) {\n            this.icon = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Title.prototype, \"caption\", {\n        /**\n         * Get the caption for the title.\n         *\n         * #### Notes\n         * The default value is an empty string.\n         */\n        get: function () {\n            return this._caption;\n        },\n        /**\n         * Set the caption for the title.\n         */\n        set: function (value) {\n            if (this._caption === value) {\n                return;\n            }\n            this._caption = value;\n            this._changed.emit(undefined);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Title.prototype, \"className\", {\n        /**\n         * Get the extra class name for the title.\n         *\n         * #### Notes\n         * The default value is an empty string.\n         */\n        get: function () {\n            return this._className;\n        },\n        /**\n         * Set the extra class name for the title.\n         *\n         * #### Notes\n         * Multiple class names can be separated with whitespace.\n         */\n        set: function (value) {\n            if (this._className === value) {\n                return;\n            }\n            this._className = value;\n            this._changed.emit(undefined);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Title.prototype, \"closable\", {\n        /**\n         * Get the closable state for the title.\n         *\n         * #### Notes\n         * The default value is `false`.\n         */\n        get: function () {\n            return this._closable;\n        },\n        /**\n         * Set the closable state for the title.\n         *\n         * #### Notes\n         * This controls the presence of a close icon when applicable.\n         */\n        set: function (value) {\n            if (this._closable === value) {\n                return;\n            }\n            this._closable = value;\n            this._changed.emit(undefined);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Title.prototype, \"dataset\", {\n        /**\n         * Get the dataset for the title.\n         *\n         * #### Notes\n         * The default value is an empty dataset.\n         */\n        get: function () {\n            return this._dataset;\n        },\n        /**\n         * Set the dataset for the title.\n         *\n         * #### Notes\n         * This controls the data attributes when applicable.\n         */\n        set: function (value) {\n            if (this._dataset === value) {\n                return;\n            }\n            this._dataset = value;\n            this._changed.emit(undefined);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    return Title;\n}());\n\n/**\n * The base class of the lumino widget hierarchy.\n *\n * #### Notes\n * This class will typically be subclassed in order to create a useful\n * widget. However, it can be used directly to host externally created\n * content.\n */\nvar Widget = /** @class */ (function () {\n    /**\n     * Construct a new widget.\n     *\n     * @param options - The options for initializing the widget.\n     */\n    function Widget(options) {\n        if (options === void 0) { options = {}; }\n        this._flags = 0;\n        this._layout = null;\n        this._parent = null;\n        this._disposed = new Signal(this);\n        this.node = Private.createNode(options);\n        this.addClass('lm-Widget');\n        /* <DEPRECATED> */\n        this.addClass('p-Widget');\n        /* </DEPRECATED> */\n    }\n    /**\n     * Dispose of the widget and its descendant widgets.\n     *\n     * #### Notes\n     * It is unsafe to use the widget after it has been disposed.\n     *\n     * All calls made to this method after the first are a no-op.\n     */\n    Widget.prototype.dispose = function () {\n        // Do nothing if the widget is already disposed.\n        if (this.isDisposed) {\n            return;\n        }\n        // Set the disposed flag and emit the disposed signal.\n        this.setFlag(Widget.Flag.IsDisposed);\n        this._disposed.emit(undefined);\n        // Remove or detach the widget if necessary.\n        if (this.parent) {\n            this.parent = null;\n        }\n        else if (this.isAttached) {\n            Widget.detach(this);\n        }\n        // Dispose of the widget layout.\n        if (this._layout) {\n            this._layout.dispose();\n            this._layout = null;\n        }\n        // Clear the extra data associated with the widget.\n        Signal.clearData(this);\n        MessageLoop.clearData(this);\n        AttachedProperty.clearData(this);\n    };\n    Object.defineProperty(Widget.prototype, \"disposed\", {\n        /**\n         * A signal emitted when the widget is disposed.\n         */\n        get: function () {\n            return this._disposed;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Widget.prototype, \"isDisposed\", {\n        /**\n         * Test whether the widget has been disposed.\n         */\n        get: function () {\n            return this.testFlag(Widget.Flag.IsDisposed);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Widget.prototype, \"isAttached\", {\n        /**\n         * Test whether the widget's node is attached to the DOM.\n         */\n        get: function () {\n            return this.testFlag(Widget.Flag.IsAttached);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Widget.prototype, \"isHidden\", {\n        /**\n         * Test whether the widget is explicitly hidden.\n         */\n        get: function () {\n            return this.testFlag(Widget.Flag.IsHidden);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Widget.prototype, \"isVisible\", {\n        /**\n         * Test whether the widget is visible.\n         *\n         * #### Notes\n         * A widget is visible when it is attached to the DOM, is not\n         * explicitly hidden, and has no explicitly hidden ancestors.\n         */\n        get: function () {\n            return this.testFlag(Widget.Flag.IsVisible);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Widget.prototype, \"title\", {\n        /**\n         * The title object for the widget.\n         *\n         * #### Notes\n         * The title object is used by some container widgets when displaying\n         * the widget alongside some title, such as a tab panel or side bar.\n         *\n         * Since not all widgets will use the title, it is created on demand.\n         *\n         * The `owner` property of the title is set to this widget.\n         */\n        get: function () {\n            return Private.titleProperty.get(this);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Widget.prototype, \"id\", {\n        /**\n         * Get the id of the widget's DOM node.\n         */\n        get: function () {\n            return this.node.id;\n        },\n        /**\n         * Set the id of the widget's DOM node.\n         */\n        set: function (value) {\n            this.node.id = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Widget.prototype, \"dataset\", {\n        /**\n         * The dataset for the widget's DOM node.\n         */\n        get: function () {\n            return this.node.dataset;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Widget.prototype, \"parent\", {\n        /**\n         * Get the parent of the widget.\n         */\n        get: function () {\n            return this._parent;\n        },\n        /**\n         * Set the parent of the widget.\n         *\n         * #### Notes\n         * Children are typically added to a widget by using a layout, which\n         * means user code will not normally set the parent widget directly.\n         *\n         * The widget will be automatically removed from its old parent.\n         *\n         * This is a no-op if there is no effective parent change.\n         */\n        set: function (value) {\n            if (this._parent === value) {\n                return;\n            }\n            if (value && this.contains(value)) {\n                throw new Error('Invalid parent widget.');\n            }\n            if (this._parent && !this._parent.isDisposed) {\n                var msg = new Widget.ChildMessage('child-removed', this);\n                MessageLoop.sendMessage(this._parent, msg);\n            }\n            this._parent = value;\n            if (this._parent && !this._parent.isDisposed) {\n                var msg = new Widget.ChildMessage('child-added', this);\n                MessageLoop.sendMessage(this._parent, msg);\n            }\n            if (!this.isDisposed) {\n                MessageLoop.sendMessage(this, Widget.Msg.ParentChanged);\n            }\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Widget.prototype, \"layout\", {\n        /**\n         * Get the layout for the widget.\n         */\n        get: function () {\n            return this._layout;\n        },\n        /**\n         * Set the layout for the widget.\n         *\n         * #### Notes\n         * The layout is single-use only. It cannot be changed after the\n         * first assignment.\n         *\n         * The layout is disposed automatically when the widget is disposed.\n         */\n        set: function (value) {\n            if (this._layout === value) {\n                return;\n            }\n            if (this.testFlag(Widget.Flag.DisallowLayout)) {\n                throw new Error('Cannot set widget layout.');\n            }\n            if (this._layout) {\n                throw new Error('Cannot change widget layout.');\n            }\n            if (value.parent) {\n                throw new Error('Cannot change layout parent.');\n            }\n            this._layout = value;\n            value.parent = this;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Create an iterator over the widget's children.\n     *\n     * @returns A new iterator over the children of the widget.\n     *\n     * #### Notes\n     * The widget must have a populated layout in order to have children.\n     *\n     * If a layout is not installed, the returned iterator will be empty.\n     */\n    Widget.prototype.children = function () {\n        return this._layout ? this._layout.iter() : empty();\n    };\n    /**\n     * Test whether a widget is a descendant of this widget.\n     *\n     * @param widget - The descendant widget of interest.\n     *\n     * @returns `true` if the widget is a descendant, `false` otherwise.\n     */\n    Widget.prototype.contains = function (widget) {\n        for (var value = widget; value; value = value._parent) {\n            if (value === this) {\n                return true;\n            }\n        }\n        return false;\n    };\n    /**\n     * Test whether the widget's DOM node has the given class name.\n     *\n     * @param name - The class name of interest.\n     *\n     * @returns `true` if the node has the class, `false` otherwise.\n     */\n    Widget.prototype.hasClass = function (name) {\n        return this.node.classList.contains(name);\n    };\n    /**\n     * Add a class name to the widget's DOM node.\n     *\n     * @param name - The class name to add to the node.\n     *\n     * #### Notes\n     * If the class name is already added to the node, this is a no-op.\n     *\n     * The class name must not contain whitespace.\n     */\n    Widget.prototype.addClass = function (name) {\n        this.node.classList.add(name);\n    };\n    /**\n     * Remove a class name from the widget's DOM node.\n     *\n     * @param name - The class name to remove from the node.\n     *\n     * #### Notes\n     * If the class name is not yet added to the node, this is a no-op.\n     *\n     * The class name must not contain whitespace.\n     */\n    Widget.prototype.removeClass = function (name) {\n        this.node.classList.remove(name);\n    };\n    /**\n     * Toggle a class name on the widget's DOM node.\n     *\n     * @param name - The class name to toggle on the node.\n     *\n     * @param force - Whether to force add the class (`true`) or force\n     *   remove the class (`false`). If not provided, the presence of\n     *   the class will be toggled from its current state.\n     *\n     * @returns `true` if the class is now present, `false` otherwise.\n     *\n     * #### Notes\n     * The class name must not contain whitespace.\n     */\n    Widget.prototype.toggleClass = function (name, force) {\n        if (force === true) {\n            this.node.classList.add(name);\n            return true;\n        }\n        if (force === false) {\n            this.node.classList.remove(name);\n            return false;\n        }\n        return this.node.classList.toggle(name);\n    };\n    /**\n     * Post an `'update-request'` message to the widget.\n     *\n     * #### Notes\n     * This is a simple convenience method for posting the message.\n     */\n    Widget.prototype.update = function () {\n        MessageLoop.postMessage(this, Widget.Msg.UpdateRequest);\n    };\n    /**\n     * Post a `'fit-request'` message to the widget.\n     *\n     * #### Notes\n     * This is a simple convenience method for posting the message.\n     */\n    Widget.prototype.fit = function () {\n        MessageLoop.postMessage(this, Widget.Msg.FitRequest);\n    };\n    /**\n     * Post an `'activate-request'` message to the widget.\n     *\n     * #### Notes\n     * This is a simple convenience method for posting the message.\n     */\n    Widget.prototype.activate = function () {\n        MessageLoop.postMessage(this, Widget.Msg.ActivateRequest);\n    };\n    /**\n     * Send a `'close-request'` message to the widget.\n     *\n     * #### Notes\n     * This is a simple convenience method for sending the message.\n     */\n    Widget.prototype.close = function () {\n        MessageLoop.sendMessage(this, Widget.Msg.CloseRequest);\n    };\n    /**\n     * Show the widget and make it visible to its parent widget.\n     *\n     * #### Notes\n     * This causes the [[isHidden]] property to be `false`.\n     *\n     * If the widget is not explicitly hidden, this is a no-op.\n     */\n    Widget.prototype.show = function () {\n        if (!this.testFlag(Widget.Flag.IsHidden)) {\n            return;\n        }\n        if (this.isAttached && (!this.parent || this.parent.isVisible)) {\n            MessageLoop.sendMessage(this, Widget.Msg.BeforeShow);\n        }\n        this.clearFlag(Widget.Flag.IsHidden);\n        this.removeClass('lm-mod-hidden');\n        /* <DEPRECATED> */\n        this.removeClass('p-mod-hidden');\n        /* </DEPRECATED> */\n        if (this.isAttached && (!this.parent || this.parent.isVisible)) {\n            MessageLoop.sendMessage(this, Widget.Msg.AfterShow);\n        }\n        if (this.parent) {\n            var msg = new Widget.ChildMessage('child-shown', this);\n            MessageLoop.sendMessage(this.parent, msg);\n        }\n    };\n    /**\n     * Hide the widget and make it hidden to its parent widget.\n     *\n     * #### Notes\n     * This causes the [[isHidden]] property to be `true`.\n     *\n     * If the widget is explicitly hidden, this is a no-op.\n     */\n    Widget.prototype.hide = function () {\n        if (this.testFlag(Widget.Flag.IsHidden)) {\n            return;\n        }\n        if (this.isAttached && (!this.parent || this.parent.isVisible)) {\n            MessageLoop.sendMessage(this, Widget.Msg.BeforeHide);\n        }\n        this.setFlag(Widget.Flag.IsHidden);\n        this.addClass('lm-mod-hidden');\n        /* <DEPRECATED> */\n        this.addClass('p-mod-hidden');\n        /* </DEPRECATED> */\n        if (this.isAttached && (!this.parent || this.parent.isVisible)) {\n            MessageLoop.sendMessage(this, Widget.Msg.AfterHide);\n        }\n        if (this.parent) {\n            var msg = new Widget.ChildMessage('child-hidden', this);\n            MessageLoop.sendMessage(this.parent, msg);\n        }\n    };\n    /**\n     * Show or hide the widget according to a boolean value.\n     *\n     * @param hidden - `true` to hide the widget, or `false` to show it.\n     *\n     * #### Notes\n     * This is a convenience method for `hide()` and `show()`.\n     */\n    Widget.prototype.setHidden = function (hidden) {\n        if (hidden) {\n            this.hide();\n        }\n        else {\n            this.show();\n        }\n    };\n    /**\n     * Test whether the given widget flag is set.\n     *\n     * #### Notes\n     * This will not typically be called directly by user code.\n     */\n    Widget.prototype.testFlag = function (flag) {\n        return (this._flags & flag) !== 0;\n    };\n    /**\n     * Set the given widget flag.\n     *\n     * #### Notes\n     * This will not typically be called directly by user code.\n     */\n    Widget.prototype.setFlag = function (flag) {\n        this._flags |= flag;\n    };\n    /**\n     * Clear the given widget flag.\n     *\n     * #### Notes\n     * This will not typically be called directly by user code.\n     */\n    Widget.prototype.clearFlag = function (flag) {\n        this._flags &= ~flag;\n    };\n    /**\n     * Process a message sent to the widget.\n     *\n     * @param msg - The message sent to the widget.\n     *\n     * #### Notes\n     * Subclasses may reimplement this method as needed.\n     */\n    Widget.prototype.processMessage = function (msg) {\n        switch (msg.type) {\n            case 'resize':\n                this.notifyLayout(msg);\n                this.onResize(msg);\n                break;\n            case 'update-request':\n                this.notifyLayout(msg);\n                this.onUpdateRequest(msg);\n                break;\n            case 'fit-request':\n                this.notifyLayout(msg);\n                this.onFitRequest(msg);\n                break;\n            case 'before-show':\n                this.notifyLayout(msg);\n                this.onBeforeShow(msg);\n                break;\n            case 'after-show':\n                this.setFlag(Widget.Flag.IsVisible);\n                this.notifyLayout(msg);\n                this.onAfterShow(msg);\n                break;\n            case 'before-hide':\n                this.notifyLayout(msg);\n                this.onBeforeHide(msg);\n                break;\n            case 'after-hide':\n                this.clearFlag(Widget.Flag.IsVisible);\n                this.notifyLayout(msg);\n                this.onAfterHide(msg);\n                break;\n            case 'before-attach':\n                this.notifyLayout(msg);\n                this.onBeforeAttach(msg);\n                break;\n            case 'after-attach':\n                if (!this.isHidden && (!this.parent || this.parent.isVisible)) {\n                    this.setFlag(Widget.Flag.IsVisible);\n                }\n                this.setFlag(Widget.Flag.IsAttached);\n                this.notifyLayout(msg);\n                this.onAfterAttach(msg);\n                break;\n            case 'before-detach':\n                this.notifyLayout(msg);\n                this.onBeforeDetach(msg);\n                break;\n            case 'after-detach':\n                this.clearFlag(Widget.Flag.IsVisible);\n                this.clearFlag(Widget.Flag.IsAttached);\n                this.notifyLayout(msg);\n                this.onAfterDetach(msg);\n                break;\n            case 'activate-request':\n                this.notifyLayout(msg);\n                this.onActivateRequest(msg);\n                break;\n            case 'close-request':\n                this.notifyLayout(msg);\n                this.onCloseRequest(msg);\n                break;\n            case 'child-added':\n                this.notifyLayout(msg);\n                this.onChildAdded(msg);\n                break;\n            case 'child-removed':\n                this.notifyLayout(msg);\n                this.onChildRemoved(msg);\n                break;\n            default:\n                this.notifyLayout(msg);\n                break;\n        }\n    };\n    /**\n     * Invoke the message processing routine of the widget's layout.\n     *\n     * @param msg - The message to dispatch to the layout.\n     *\n     * #### Notes\n     * This is a no-op if the widget does not have a layout.\n     *\n     * This will not typically be called directly by user code.\n     */\n    Widget.prototype.notifyLayout = function (msg) {\n        if (this._layout) {\n            this._layout.processParentMessage(msg);\n        }\n    };\n    /**\n     * A message handler invoked on a `'close-request'` message.\n     *\n     * #### Notes\n     * The default implementation unparents or detaches the widget.\n     */\n    Widget.prototype.onCloseRequest = function (msg) {\n        if (this.parent) {\n            this.parent = null;\n        }\n        else if (this.isAttached) {\n            Widget.detach(this);\n        }\n    };\n    /**\n     * A message handler invoked on a `'resize'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onResize = function (msg) { };\n    /**\n     * A message handler invoked on an `'update-request'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onUpdateRequest = function (msg) { };\n    /**\n     * A message handler invoked on a `'fit-request'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onFitRequest = function (msg) { };\n    /**\n     * A message handler invoked on an `'activate-request'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onActivateRequest = function (msg) { };\n    /**\n     * A message handler invoked on a `'before-show'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onBeforeShow = function (msg) { };\n    /**\n     * A message handler invoked on an `'after-show'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onAfterShow = function (msg) { };\n    /**\n     * A message handler invoked on a `'before-hide'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onBeforeHide = function (msg) { };\n    /**\n     * A message handler invoked on an `'after-hide'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onAfterHide = function (msg) { };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onBeforeAttach = function (msg) { };\n    /**\n     * A message handler invoked on an `'after-attach'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onAfterAttach = function (msg) { };\n    /**\n     * A message handler invoked on a `'before-detach'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onBeforeDetach = function (msg) { };\n    /**\n     * A message handler invoked on an `'after-detach'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onAfterDetach = function (msg) { };\n    /**\n     * A message handler invoked on a `'child-added'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onChildAdded = function (msg) { };\n    /**\n     * A message handler invoked on a `'child-removed'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Widget.prototype.onChildRemoved = function (msg) { };\n    return Widget;\n}());\n/**\n * The namespace for the `Widget` class statics.\n */\n(function (Widget) {\n    /**\n     * An enum of widget bit flags.\n     */\n    var Flag;\n    (function (Flag) {\n        /**\n         * The widget has been disposed.\n         */\n        Flag[Flag[\"IsDisposed\"] = 1] = \"IsDisposed\";\n        /**\n         * The widget is attached to the DOM.\n         */\n        Flag[Flag[\"IsAttached\"] = 2] = \"IsAttached\";\n        /**\n         * The widget is hidden.\n         */\n        Flag[Flag[\"IsHidden\"] = 4] = \"IsHidden\";\n        /**\n         * The widget is visible.\n         */\n        Flag[Flag[\"IsVisible\"] = 8] = \"IsVisible\";\n        /**\n         * A layout cannot be set on the widget.\n         */\n        Flag[Flag[\"DisallowLayout\"] = 16] = \"DisallowLayout\";\n    })(Flag = Widget.Flag || (Widget.Flag = {}));\n    /**\n     * A collection of stateless messages related to widgets.\n     */\n    var Msg;\n    (function (Msg) {\n        /**\n         * A singleton `'before-show'` message.\n         *\n         * #### Notes\n         * This message is sent to a widget before it becomes visible.\n         *\n         * This message is **not** sent when the widget is being attached.\n         */\n        Msg.BeforeShow = new Message('before-show');\n        /**\n         * A singleton `'after-show'` message.\n         *\n         * #### Notes\n         * This message is sent to a widget after it becomes visible.\n         *\n         * This message is **not** sent when the widget is being attached.\n         */\n        Msg.AfterShow = new Message('after-show');\n        /**\n         * A singleton `'before-hide'` message.\n         *\n         * #### Notes\n         * This message is sent to a widget before it becomes not-visible.\n         *\n         * This message is **not** sent when the widget is being detached.\n         */\n        Msg.BeforeHide = new Message('before-hide');\n        /**\n         * A singleton `'after-hide'` message.\n         *\n         * #### Notes\n         * This message is sent to a widget after it becomes not-visible.\n         *\n         * This message is **not** sent when the widget is being detached.\n         */\n        Msg.AfterHide = new Message('after-hide');\n        /**\n         * A singleton `'before-attach'` message.\n         *\n         * #### Notes\n         * This message is sent to a widget before it is attached.\n         */\n        Msg.BeforeAttach = new Message('before-attach');\n        /**\n         * A singleton `'after-attach'` message.\n         *\n         * #### Notes\n         * This message is sent to a widget after it is attached.\n         */\n        Msg.AfterAttach = new Message('after-attach');\n        /**\n         * A singleton `'before-detach'` message.\n         *\n         * #### Notes\n         * This message is sent to a widget before it is detached.\n         */\n        Msg.BeforeDetach = new Message('before-detach');\n        /**\n         * A singleton `'after-detach'` message.\n         *\n         * #### Notes\n         * This message is sent to a widget after it is detached.\n         */\n        Msg.AfterDetach = new Message('after-detach');\n        /**\n         * A singleton `'parent-changed'` message.\n         *\n         * #### Notes\n         * This message is sent to a widget when its parent has changed.\n         */\n        Msg.ParentChanged = new Message('parent-changed');\n        /**\n         * A singleton conflatable `'update-request'` message.\n         *\n         * #### Notes\n         * This message can be dispatched to supporting widgets in order to\n         * update their content based on the current widget state. Not all\n         * widgets will respond to messages of this type.\n         *\n         * For widgets with a layout, this message will inform the layout to\n         * update the position and size of its child widgets.\n         */\n        Msg.UpdateRequest = new ConflatableMessage('update-request');\n        /**\n         * A singleton conflatable `'fit-request'` message.\n         *\n         * #### Notes\n         * For widgets with a layout, this message will inform the layout to\n         * recalculate its size constraints to fit the space requirements of\n         * its child widgets, and to update their position and size. Not all\n         * layouts will respond to messages of this type.\n         */\n        Msg.FitRequest = new ConflatableMessage('fit-request');\n        /**\n         * A singleton conflatable `'activate-request'` message.\n         *\n         * #### Notes\n         * This message should be dispatched to a widget when it should\n         * perform the actions necessary to activate the widget, which\n         * may include focusing its node or descendant node.\n         */\n        Msg.ActivateRequest = new ConflatableMessage('activate-request');\n        /**\n         * A singleton conflatable `'close-request'` message.\n         *\n         * #### Notes\n         * This message should be dispatched to a widget when it should close\n         * and remove itself from the widget hierarchy.\n         */\n        Msg.CloseRequest = new ConflatableMessage('close-request');\n    })(Msg = Widget.Msg || (Widget.Msg = {}));\n    /**\n     * A message class for child related messages.\n     */\n    var ChildMessage = /** @class */ (function (_super) {\n        __extends(ChildMessage, _super);\n        /**\n         * Construct a new child message.\n         *\n         * @param type - The message type.\n         *\n         * @param child - The child widget for the message.\n         */\n        function ChildMessage(type, child) {\n            var _this = _super.call(this, type) || this;\n            _this.child = child;\n            return _this;\n        }\n        return ChildMessage;\n    }(Message));\n    Widget.ChildMessage = ChildMessage;\n    /**\n     * A message class for `'resize'` messages.\n     */\n    var ResizeMessage = /** @class */ (function (_super) {\n        __extends(ResizeMessage, _super);\n        /**\n         * Construct a new resize message.\n         *\n         * @param width - The **offset width** of the widget, or `-1` if\n         *   the width is not known.\n         *\n         * @param height - The **offset height** of the widget, or `-1` if\n         *   the height is not known.\n         */\n        function ResizeMessage(width, height) {\n            var _this = _super.call(this, 'resize') || this;\n            _this.width = width;\n            _this.height = height;\n            return _this;\n        }\n        return ResizeMessage;\n    }(Message));\n    Widget.ResizeMessage = ResizeMessage;\n    /**\n     * The namespace for the `ResizeMessage` class statics.\n     */\n    (function (ResizeMessage) {\n        /**\n         * A singleton `'resize'` message with an unknown size.\n         */\n        ResizeMessage.UnknownSize = new ResizeMessage(-1, -1);\n    })(ResizeMessage = Widget.ResizeMessage || (Widget.ResizeMessage = {}));\n    /**\n     * Attach a widget to a host DOM node.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @param host - The DOM node to use as the widget's host.\n     *\n     * @param ref - The child of `host` to use as the reference element.\n     *   If this is provided, the widget will be inserted before this\n     *   node in the host. The default is `null`, which will cause the\n     *   widget to be added as the last child of the host.\n     *\n     * #### Notes\n     * This will throw an error if the widget is not a root widget, if\n     * the widget is already attached, or if the host is not attached\n     * to the DOM.\n     */\n    function attach(widget, host, ref) {\n        if (ref === void 0) { ref = null; }\n        if (widget.parent) {\n            throw new Error('Cannot attach a child widget.');\n        }\n        if (widget.isAttached || document.body.contains(widget.node)) {\n            throw new Error('Widget is already attached.');\n        }\n        if (!document.body.contains(host)) {\n            throw new Error('Host is not attached.');\n        }\n        MessageLoop.sendMessage(widget, Widget.Msg.BeforeAttach);\n        host.insertBefore(widget.node, ref);\n        MessageLoop.sendMessage(widget, Widget.Msg.AfterAttach);\n    }\n    Widget.attach = attach;\n    /**\n     * Detach the widget from its host DOM node.\n     *\n     * @param widget - The widget of interest.\n     *\n     * #### Notes\n     * This will throw an error if the widget is not a root widget,\n     * or if the widget is not attached to the DOM.\n     */\n    function detach(widget) {\n        if (widget.parent) {\n            throw new Error('Cannot detach a child widget.');\n        }\n        if (!widget.isAttached || !document.body.contains(widget.node)) {\n            throw new Error('Widget is not attached.');\n        }\n        MessageLoop.sendMessage(widget, Widget.Msg.BeforeDetach);\n        widget.node.parentNode.removeChild(widget.node);\n        MessageLoop.sendMessage(widget, Widget.Msg.AfterDetach);\n    }\n    Widget.detach = detach;\n})(Widget || (Widget = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private;\n(function (Private) {\n    /**\n     * An attached property for the widget title object.\n     */\n    Private.titleProperty = new AttachedProperty({\n        name: 'title',\n        create: function (owner) { return new Title({ owner: owner }); },\n    });\n    /**\n     * Create a DOM node for the given widget options.\n     */\n    function createNode(options) {\n        return options.node || document.createElement('div');\n    }\n    Private.createNode = createNode;\n})(Private || (Private = {}));\n\n// Copyright (c) Jupyter Development Team.\n/**\n * An abstract base class for creating lumino layouts.\n *\n * #### Notes\n * A layout is used to add widgets to a parent and to arrange those\n * widgets within the parent's DOM node.\n *\n * This class implements the base functionality which is required of\n * nearly all layouts. It must be subclassed in order to be useful.\n *\n * Notably, this class does not define a uniform interface for adding\n * widgets to the layout. A subclass should define that API in a way\n * which is meaningful for its intended use.\n */\nvar Layout = /** @class */ (function () {\n    /**\n     * Construct a new layout.\n     *\n     * @param options - The options for initializing the layout.\n     */\n    function Layout(options) {\n        if (options === void 0) { options = {}; }\n        this._disposed = false;\n        this._parent = null;\n        this._fitPolicy = options.fitPolicy || 'set-min-size';\n    }\n    /**\n     * Dispose of the resources held by the layout.\n     *\n     * #### Notes\n     * This should be reimplemented to clear and dispose of the widgets.\n     *\n     * All reimplementations should call the superclass method.\n     *\n     * This method is called automatically when the parent is disposed.\n     */\n    Layout.prototype.dispose = function () {\n        this._parent = null;\n        this._disposed = true;\n        Signal.clearData(this);\n        AttachedProperty.clearData(this);\n    };\n    Object.defineProperty(Layout.prototype, \"isDisposed\", {\n        /**\n         * Test whether the layout is disposed.\n         */\n        get: function () {\n            return this._disposed;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Layout.prototype, \"parent\", {\n        /**\n         * Get the parent widget of the layout.\n         */\n        get: function () {\n            return this._parent;\n        },\n        /**\n         * Set the parent widget of the layout.\n         *\n         * #### Notes\n         * This is set automatically when installing the layout on the parent\n         * widget. The parent widget should not be set directly by user code.\n         */\n        set: function (value) {\n            if (this._parent === value) {\n                return;\n            }\n            if (this._parent) {\n                throw new Error('Cannot change parent widget.');\n            }\n            if (value.layout !== this) {\n                throw new Error('Invalid parent widget.');\n            }\n            this._parent = value;\n            this.init();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Layout.prototype, \"fitPolicy\", {\n        /**\n         * Get the fit policy for the layout.\n         *\n         * #### Notes\n         * The fit policy controls the computed size constraints which are\n         * applied to the parent widget by the layout.\n         *\n         * Some layout implementations may ignore the fit policy.\n         */\n        get: function () {\n            return this._fitPolicy;\n        },\n        /**\n         * Set the fit policy for the layout.\n         *\n         * #### Notes\n         * The fit policy controls the computed size constraints which are\n         * applied to the parent widget by the layout.\n         *\n         * Some layout implementations may ignore the fit policy.\n         *\n         * Changing the fit policy will clear the current size constraint\n         * for the parent widget and then re-fit the parent.\n         */\n        set: function (value) {\n            // Bail if the policy does not change\n            if (this._fitPolicy === value) {\n                return;\n            }\n            // Update the internal policy.\n            this._fitPolicy = value;\n            // Clear the size constraints and schedule a fit of the parent.\n            if (this._parent) {\n                var style = this._parent.node.style;\n                style.minWidth = '';\n                style.minHeight = '';\n                style.maxWidth = '';\n                style.maxHeight = '';\n                this._parent.fit();\n            }\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Process a message sent to the parent widget.\n     *\n     * @param msg - The message sent to the parent widget.\n     *\n     * #### Notes\n     * This method is called by the parent widget to process a message.\n     *\n     * Subclasses may reimplement this method as needed.\n     */\n    Layout.prototype.processParentMessage = function (msg) {\n        switch (msg.type) {\n            case 'resize':\n                this.onResize(msg);\n                break;\n            case 'update-request':\n                this.onUpdateRequest(msg);\n                break;\n            case 'fit-request':\n                this.onFitRequest(msg);\n                break;\n            case 'before-show':\n                this.onBeforeShow(msg);\n                break;\n            case 'after-show':\n                this.onAfterShow(msg);\n                break;\n            case 'before-hide':\n                this.onBeforeHide(msg);\n                break;\n            case 'after-hide':\n                this.onAfterHide(msg);\n                break;\n            case 'before-attach':\n                this.onBeforeAttach(msg);\n                break;\n            case 'after-attach':\n                this.onAfterAttach(msg);\n                break;\n            case 'before-detach':\n                this.onBeforeDetach(msg);\n                break;\n            case 'after-detach':\n                this.onAfterDetach(msg);\n                break;\n            case 'child-removed':\n                this.onChildRemoved(msg);\n                break;\n            case 'child-shown':\n                this.onChildShown(msg);\n                break;\n            case 'child-hidden':\n                this.onChildHidden(msg);\n                break;\n        }\n    };\n    /**\n     * Perform layout initialization which requires the parent widget.\n     *\n     * #### Notes\n     * This method is invoked immediately after the layout is installed\n     * on the parent widget.\n     *\n     * The default implementation reparents all of the widgets to the\n     * layout parent widget.\n     *\n     * Subclasses should reimplement this method and attach the child\n     * widget nodes to the parent widget's node.\n     */\n    Layout.prototype.init = function () {\n        var _this = this;\n        each(this, function (widget) {\n            widget.parent = _this.parent;\n        });\n    };\n    /**\n     * A message handler invoked on a `'resize'` message.\n     *\n     * #### Notes\n     * The layout should ensure that its widgets are resized according\n     * to the specified layout space, and that they are sent a `'resize'`\n     * message if appropriate.\n     *\n     * The default implementation of this method sends an `UnknownSize`\n     * resize message to all widgets.\n     *\n     * This may be reimplemented by subclasses as needed.\n     */\n    Layout.prototype.onResize = function (msg) {\n        each(this, function (widget) {\n            MessageLoop.sendMessage(widget, Widget.ResizeMessage.UnknownSize);\n        });\n    };\n    /**\n     * A message handler invoked on an `'update-request'` message.\n     *\n     * #### Notes\n     * The layout should ensure that its widgets are resized according\n     * to the available layout space, and that they are sent a `'resize'`\n     * message if appropriate.\n     *\n     * The default implementation of this method sends an `UnknownSize`\n     * resize message to all widgets.\n     *\n     * This may be reimplemented by subclasses as needed.\n     */\n    Layout.prototype.onUpdateRequest = function (msg) {\n        each(this, function (widget) {\n            MessageLoop.sendMessage(widget, Widget.ResizeMessage.UnknownSize);\n        });\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     *\n     * #### Notes\n     * The default implementation of this method forwards the message\n     * to all widgets. It assumes all widget nodes are attached to the\n     * parent widget node.\n     *\n     * This may be reimplemented by subclasses as needed.\n     */\n    Layout.prototype.onBeforeAttach = function (msg) {\n        each(this, function (widget) {\n            MessageLoop.sendMessage(widget, msg);\n        });\n    };\n    /**\n     * A message handler invoked on an `'after-attach'` message.\n     *\n     * #### Notes\n     * The default implementation of this method forwards the message\n     * to all widgets. It assumes all widget nodes are attached to the\n     * parent widget node.\n     *\n     * This may be reimplemented by subclasses as needed.\n     */\n    Layout.prototype.onAfterAttach = function (msg) {\n        each(this, function (widget) {\n            MessageLoop.sendMessage(widget, msg);\n        });\n    };\n    /**\n     * A message handler invoked on a `'before-detach'` message.\n     *\n     * #### Notes\n     * The default implementation of this method forwards the message\n     * to all widgets. It assumes all widget nodes are attached to the\n     * parent widget node.\n     *\n     * This may be reimplemented by subclasses as needed.\n     */\n    Layout.prototype.onBeforeDetach = function (msg) {\n        each(this, function (widget) {\n            MessageLoop.sendMessage(widget, msg);\n        });\n    };\n    /**\n     * A message handler invoked on an `'after-detach'` message.\n     *\n     * #### Notes\n     * The default implementation of this method forwards the message\n     * to all widgets. It assumes all widget nodes are attached to the\n     * parent widget node.\n     *\n     * This may be reimplemented by subclasses as needed.\n     */\n    Layout.prototype.onAfterDetach = function (msg) {\n        each(this, function (widget) {\n            MessageLoop.sendMessage(widget, msg);\n        });\n    };\n    /**\n     * A message handler invoked on a `'before-show'` message.\n     *\n     * #### Notes\n     * The default implementation of this method forwards the message to\n     * all non-hidden widgets. It assumes all widget nodes are attached\n     * to the parent widget node.\n     *\n     * This may be reimplemented by subclasses as needed.\n     */\n    Layout.prototype.onBeforeShow = function (msg) {\n        each(this, function (widget) {\n            if (!widget.isHidden) {\n                MessageLoop.sendMessage(widget, msg);\n            }\n        });\n    };\n    /**\n     * A message handler invoked on an `'after-show'` message.\n     *\n     * #### Notes\n     * The default implementation of this method forwards the message to\n     * all non-hidden widgets. It assumes all widget nodes are attached\n     * to the parent widget node.\n     *\n     * This may be reimplemented by subclasses as needed.\n     */\n    Layout.prototype.onAfterShow = function (msg) {\n        each(this, function (widget) {\n            if (!widget.isHidden) {\n                MessageLoop.sendMessage(widget, msg);\n            }\n        });\n    };\n    /**\n     * A message handler invoked on a `'before-hide'` message.\n     *\n     * #### Notes\n     * The default implementation of this method forwards the message to\n     * all non-hidden widgets. It assumes all widget nodes are attached\n     * to the parent widget node.\n     *\n     * This may be reimplemented by subclasses as needed.\n     */\n    Layout.prototype.onBeforeHide = function (msg) {\n        each(this, function (widget) {\n            if (!widget.isHidden) {\n                MessageLoop.sendMessage(widget, msg);\n            }\n        });\n    };\n    /**\n     * A message handler invoked on an `'after-hide'` message.\n     *\n     * #### Notes\n     * The default implementation of this method forwards the message to\n     * all non-hidden widgets. It assumes all widget nodes are attached\n     * to the parent widget node.\n     *\n     * This may be reimplemented by subclasses as needed.\n     */\n    Layout.prototype.onAfterHide = function (msg) {\n        each(this, function (widget) {\n            if (!widget.isHidden) {\n                MessageLoop.sendMessage(widget, msg);\n            }\n        });\n    };\n    /**\n     * A message handler invoked on a `'child-removed'` message.\n     *\n     * #### Notes\n     * This will remove the child widget from the layout.\n     *\n     * Subclasses should **not** typically reimplement this method.\n     */\n    Layout.prototype.onChildRemoved = function (msg) {\n        this.removeWidget(msg.child);\n    };\n    /**\n     * A message handler invoked on a `'fit-request'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Layout.prototype.onFitRequest = function (msg) { };\n    /**\n     * A message handler invoked on a `'child-shown'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Layout.prototype.onChildShown = function (msg) { };\n    /**\n     * A message handler invoked on a `'child-hidden'` message.\n     *\n     * #### Notes\n     * The default implementation of this handler is a no-op.\n     */\n    Layout.prototype.onChildHidden = function (msg) { };\n    return Layout;\n}());\n/**\n * The namespace for the `Layout` class statics.\n */\n(function (Layout) {\n    /**\n     * Get the horizontal alignment for a widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @returns The horizontal alignment for the widget.\n     *\n     * #### Notes\n     * If the layout width allocated to a widget is larger than its max\n     * width, the horizontal alignment controls how the widget is placed\n     * within the extra horizontal space.\n     *\n     * If the allocated width is less than the widget's max width, the\n     * horizontal alignment has no effect.\n     *\n     * Some layout implementations may ignore horizontal alignment.\n     */\n    function getHorizontalAlignment(widget) {\n        return Private$1.horizontalAlignmentProperty.get(widget);\n    }\n    Layout.getHorizontalAlignment = getHorizontalAlignment;\n    /**\n     * Set the horizontal alignment for a widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @param value - The value for the horizontal alignment.\n     *\n     * #### Notes\n     * If the layout width allocated to a widget is larger than its max\n     * width, the horizontal alignment controls how the widget is placed\n     * within the extra horizontal space.\n     *\n     * If the allocated width is less than the widget's max width, the\n     * horizontal alignment has no effect.\n     *\n     * Some layout implementations may ignore horizontal alignment.\n     *\n     * Changing the horizontal alignment will post an `update-request`\n     * message to widget's parent, provided the parent has a layout\n     * installed.\n     */\n    function setHorizontalAlignment(widget, value) {\n        Private$1.horizontalAlignmentProperty.set(widget, value);\n    }\n    Layout.setHorizontalAlignment = setHorizontalAlignment;\n    /**\n     * Get the vertical alignment for a widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @returns The vertical alignment for the widget.\n     *\n     * #### Notes\n     * If the layout height allocated to a widget is larger than its max\n     * height, the vertical alignment controls how the widget is placed\n     * within the extra vertical space.\n     *\n     * If the allocated height is less than the widget's max height, the\n     * vertical alignment has no effect.\n     *\n     * Some layout implementations may ignore vertical alignment.\n     */\n    function getVerticalAlignment(widget) {\n        return Private$1.verticalAlignmentProperty.get(widget);\n    }\n    Layout.getVerticalAlignment = getVerticalAlignment;\n    /**\n     * Set the vertical alignment for a widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @param value - The value for the vertical alignment.\n     *\n     * #### Notes\n     * If the layout height allocated to a widget is larger than its max\n     * height, the vertical alignment controls how the widget is placed\n     * within the extra vertical space.\n     *\n     * If the allocated height is less than the widget's max height, the\n     * vertical alignment has no effect.\n     *\n     * Some layout implementations may ignore vertical alignment.\n     *\n     * Changing the horizontal alignment will post an `update-request`\n     * message to widget's parent, provided the parent has a layout\n     * installed.\n     */\n    function setVerticalAlignment(widget, value) {\n        Private$1.verticalAlignmentProperty.set(widget, value);\n    }\n    Layout.setVerticalAlignment = setVerticalAlignment;\n})(Layout || (Layout = {}));\n/**\n * An object which assists in the absolute layout of widgets.\n *\n * #### Notes\n * This class is useful when implementing a layout which arranges its\n * widgets using absolute positioning.\n *\n * This class is used by nearly all of the built-in lumino layouts.\n */\nvar LayoutItem = /** @class */ (function () {\n    /**\n     * Construct a new layout item.\n     *\n     * @param widget - The widget to be managed by the item.\n     *\n     * #### Notes\n     * The widget will be set to absolute positioning.\n     */\n    function LayoutItem(widget) {\n        this._top = NaN;\n        this._left = NaN;\n        this._width = NaN;\n        this._height = NaN;\n        this._minWidth = 0;\n        this._minHeight = 0;\n        this._maxWidth = Infinity;\n        this._maxHeight = Infinity;\n        this._disposed = false;\n        this.widget = widget;\n        this.widget.node.style.position = 'absolute';\n    }\n    /**\n     * Dispose of the the layout item.\n     *\n     * #### Notes\n     * This will reset the positioning of the widget.\n     */\n    LayoutItem.prototype.dispose = function () {\n        // Do nothing if the item is already disposed.\n        if (this._disposed) {\n            return;\n        }\n        // Mark the item as disposed.\n        this._disposed = true;\n        // Reset the widget style.\n        var style = this.widget.node.style;\n        style.position = '';\n        style.top = '';\n        style.left = '';\n        style.width = '';\n        style.height = '';\n    };\n    Object.defineProperty(LayoutItem.prototype, \"minWidth\", {\n        /**\n         * The computed minimum width of the widget.\n         *\n         * #### Notes\n         * This value can be updated by calling the `fit` method.\n         */\n        get: function () {\n            return this._minWidth;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LayoutItem.prototype, \"minHeight\", {\n        /**\n         * The computed minimum height of the widget.\n         *\n         * #### Notes\n         * This value can be updated by calling the `fit` method.\n         */\n        get: function () {\n            return this._minHeight;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LayoutItem.prototype, \"maxWidth\", {\n        /**\n         * The computed maximum width of the widget.\n         *\n         * #### Notes\n         * This value can be updated by calling the `fit` method.\n         */\n        get: function () {\n            return this._maxWidth;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LayoutItem.prototype, \"maxHeight\", {\n        /**\n         * The computed maximum height of the widget.\n         *\n         * #### Notes\n         * This value can be updated by calling the `fit` method.\n         */\n        get: function () {\n            return this._maxHeight;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LayoutItem.prototype, \"isDisposed\", {\n        /**\n         * Whether the layout item is disposed.\n         */\n        get: function () {\n            return this._disposed;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LayoutItem.prototype, \"isHidden\", {\n        /**\n         * Whether the managed widget is hidden.\n         */\n        get: function () {\n            return this.widget.isHidden;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LayoutItem.prototype, \"isVisible\", {\n        /**\n         * Whether the managed widget is visible.\n         */\n        get: function () {\n            return this.widget.isVisible;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LayoutItem.prototype, \"isAttached\", {\n        /**\n         * Whether the managed widget is attached.\n         */\n        get: function () {\n            return this.widget.isAttached;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Update the computed size limits of the managed widget.\n     */\n    LayoutItem.prototype.fit = function () {\n        var limits = ElementExt.sizeLimits(this.widget.node);\n        this._minWidth = limits.minWidth;\n        this._minHeight = limits.minHeight;\n        this._maxWidth = limits.maxWidth;\n        this._maxHeight = limits.maxHeight;\n    };\n    /**\n     * Update the position and size of the managed widget.\n     *\n     * @param left - The left edge position of the layout box.\n     *\n     * @param top - The top edge position of the layout box.\n     *\n     * @param width - The width of the layout box.\n     *\n     * @param height - The height of the layout box.\n     */\n    LayoutItem.prototype.update = function (left, top, width, height) {\n        // Clamp the size to the computed size limits.\n        var clampW = Math.max(this._minWidth, Math.min(width, this._maxWidth));\n        var clampH = Math.max(this._minHeight, Math.min(height, this._maxHeight));\n        // Adjust the left edge for the horizontal alignment, if needed.\n        if (clampW < width) {\n            switch (Layout.getHorizontalAlignment(this.widget)) {\n                case 'left':\n                    break;\n                case 'center':\n                    left += (width - clampW) / 2;\n                    break;\n                case 'right':\n                    left += width - clampW;\n                    break;\n                default:\n                    throw 'unreachable';\n            }\n        }\n        // Adjust the top edge for the vertical alignment, if needed.\n        if (clampH < height) {\n            switch (Layout.getVerticalAlignment(this.widget)) {\n                case 'top':\n                    break;\n                case 'center':\n                    top += (height - clampH) / 2;\n                    break;\n                case 'bottom':\n                    top += height - clampH;\n                    break;\n                default:\n                    throw 'unreachable';\n            }\n        }\n        // Set up the resize variables.\n        var resized = false;\n        var style = this.widget.node.style;\n        // Update the top edge of the widget if needed.\n        if (this._top !== top) {\n            this._top = top;\n            style.top = top + \"px\";\n        }\n        // Update the left edge of the widget if needed.\n        if (this._left !== left) {\n            this._left = left;\n            style.left = left + \"px\";\n        }\n        // Update the width of the widget if needed.\n        if (this._width !== clampW) {\n            resized = true;\n            this._width = clampW;\n            style.width = clampW + \"px\";\n        }\n        // Update the height of the widget if needed.\n        if (this._height !== clampH) {\n            resized = true;\n            this._height = clampH;\n            style.height = clampH + \"px\";\n        }\n        // Send a resize message to the widget if needed.\n        if (resized) {\n            var msg = new Widget.ResizeMessage(clampW, clampH);\n            MessageLoop.sendMessage(this.widget, msg);\n        }\n    };\n    return LayoutItem;\n}());\n/**\n * The namespace for the module implementation details.\n */\nvar Private$1;\n(function (Private) {\n    /**\n     * The attached property for a widget horizontal alignment.\n     */\n    Private.horizontalAlignmentProperty = new AttachedProperty({\n        name: 'horizontalAlignment',\n        create: function () { return 'center'; },\n        changed: onAlignmentChanged\n    });\n    /**\n     * The attached property for a widget vertical alignment.\n     */\n    Private.verticalAlignmentProperty = new AttachedProperty({\n        name: 'verticalAlignment',\n        create: function () { return 'top'; },\n        changed: onAlignmentChanged\n    });\n    /**\n     * The change handler for the attached alignment properties.\n     */\n    function onAlignmentChanged(child) {\n        if (child.parent && child.parent.layout) {\n            child.parent.update();\n        }\n    }\n})(Private$1 || (Private$1 = {}));\n\n/**\n * A concrete layout implementation suitable for many use cases.\n *\n * #### Notes\n * This class is suitable as a base class for implementing a variety of\n * layouts, but can also be used directly with standard CSS to layout a\n * collection of widgets.\n */\nvar PanelLayout = /** @class */ (function (_super) {\n    __extends(PanelLayout, _super);\n    function PanelLayout() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._widgets = [];\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the layout.\n     *\n     * #### Notes\n     * This will clear and dispose all widgets in the layout.\n     *\n     * All reimplementations should call the superclass method.\n     *\n     * This method is called automatically when the parent is disposed.\n     */\n    PanelLayout.prototype.dispose = function () {\n        while (this._widgets.length > 0) {\n            this._widgets.pop().dispose();\n        }\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(PanelLayout.prototype, \"widgets\", {\n        /**\n         * A read-only array of the widgets in the layout.\n         */\n        get: function () {\n            return this._widgets;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Create an iterator over the widgets in the layout.\n     *\n     * @returns A new iterator over the widgets in the layout.\n     */\n    PanelLayout.prototype.iter = function () {\n        return iter(this._widgets);\n    };\n    /**\n     * Add a widget to the end of the layout.\n     *\n     * @param widget - The widget to add to the layout.\n     *\n     * #### Notes\n     * If the widget is already contained in the layout, it will be moved.\n     */\n    PanelLayout.prototype.addWidget = function (widget) {\n        this.insertWidget(this._widgets.length, widget);\n    };\n    /**\n     * Insert a widget into the layout at the specified index.\n     *\n     * @param index - The index at which to insert the widget.\n     *\n     * @param widget - The widget to insert into the layout.\n     *\n     * #### Notes\n     * The index will be clamped to the bounds of the widgets.\n     *\n     * If the widget is already added to the layout, it will be moved.\n     *\n     * #### Undefined Behavior\n     * An `index` which is non-integral.\n     */\n    PanelLayout.prototype.insertWidget = function (index, widget) {\n        // Remove the widget from its current parent. This is a no-op\n        // if the widget's parent is already the layout parent widget.\n        widget.parent = this.parent;\n        // Look up the current index of the widget.\n        var i = this._widgets.indexOf(widget);\n        // Clamp the insert index to the array bounds.\n        var j = Math.max(0, Math.min(index, this._widgets.length));\n        // If the widget is not in the array, insert it.\n        if (i === -1) {\n            // Insert the widget into the array.\n            ArrayExt.insert(this._widgets, j, widget);\n            // If the layout is parented, attach the widget to the DOM.\n            if (this.parent) {\n                this.attachWidget(j, widget);\n            }\n            // There is nothing more to do.\n            return;\n        }\n        // Otherwise, the widget exists in the array and should be moved.\n        // Adjust the index if the location is at the end of the array.\n        if (j === this._widgets.length) {\n            j--;\n        }\n        // Bail if there is no effective move.\n        if (i === j) {\n            return;\n        }\n        // Move the widget to the new location.\n        ArrayExt.move(this._widgets, i, j);\n        // If the layout is parented, move the widget in the DOM.\n        if (this.parent) {\n            this.moveWidget(i, j, widget);\n        }\n    };\n    /**\n     * Remove a widget from the layout.\n     *\n     * @param widget - The widget to remove from the layout.\n     *\n     * #### Notes\n     * A widget is automatically removed from the layout when its `parent`\n     * is set to `null`. This method should only be invoked directly when\n     * removing a widget from a layout which has yet to be installed on a\n     * parent widget.\n     *\n     * This method does *not* modify the widget's `parent`.\n     */\n    PanelLayout.prototype.removeWidget = function (widget) {\n        this.removeWidgetAt(this._widgets.indexOf(widget));\n    };\n    /**\n     * Remove the widget at a given index from the layout.\n     *\n     * @param index - The index of the widget to remove.\n     *\n     * #### Notes\n     * A widget is automatically removed from the layout when its `parent`\n     * is set to `null`. This method should only be invoked directly when\n     * removing a widget from a layout which has yet to be installed on a\n     * parent widget.\n     *\n     * This method does *not* modify the widget's `parent`.\n     *\n     * #### Undefined Behavior\n     * An `index` which is non-integral.\n     */\n    PanelLayout.prototype.removeWidgetAt = function (index) {\n        // Remove the widget from the array.\n        var widget = ArrayExt.removeAt(this._widgets, index);\n        // If the layout is parented, detach the widget from the DOM.\n        if (widget && this.parent) {\n            this.detachWidget(index, widget);\n        }\n    };\n    /**\n     * Perform layout initialization which requires the parent widget.\n     */\n    PanelLayout.prototype.init = function () {\n        var _this = this;\n        _super.prototype.init.call(this);\n        each(this, function (widget, index) {\n            _this.attachWidget(index, widget);\n        });\n    };\n    /**\n     * Attach a widget to the parent's DOM node.\n     *\n     * @param index - The current index of the widget in the layout.\n     *\n     * @param widget - The widget to attach to the parent.\n     *\n     * #### Notes\n     * This method is called automatically by the panel layout at the\n     * appropriate time. It should not be called directly by user code.\n     *\n     * The default implementation adds the widgets's node to the parent's\n     * node at the proper location, and sends the appropriate attach\n     * messages to the widget if the parent is attached to the DOM.\n     *\n     * Subclasses may reimplement this method to control how the widget's\n     * node is added to the parent's node.\n     */\n    PanelLayout.prototype.attachWidget = function (index, widget) {\n        // Look up the next sibling reference node.\n        var ref = this.parent.node.children[index];\n        // Send a `'before-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeAttach);\n        }\n        // Insert the widget's node before the sibling.\n        this.parent.node.insertBefore(widget.node, ref);\n        // Send an `'after-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterAttach);\n        }\n    };\n    /**\n     * Move a widget in the parent's DOM node.\n     *\n     * @param fromIndex - The previous index of the widget in the layout.\n     *\n     * @param toIndex - The current index of the widget in the layout.\n     *\n     * @param widget - The widget to move in the parent.\n     *\n     * #### Notes\n     * This method is called automatically by the panel layout at the\n     * appropriate time. It should not be called directly by user code.\n     *\n     * The default implementation moves the widget's node to the proper\n     * location in the parent's node and sends the appropriate attach and\n     * detach messages to the widget if the parent is attached to the DOM.\n     *\n     * Subclasses may reimplement this method to control how the widget's\n     * node is moved in the parent's node.\n     */\n    PanelLayout.prototype.moveWidget = function (fromIndex, toIndex, widget) {\n        // Send a `'before-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeDetach);\n        }\n        // Remove the widget's node from the parent.\n        this.parent.node.removeChild(widget.node);\n        // Send an `'after-detach'` and  message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterDetach);\n        }\n        // Look up the next sibling reference node.\n        var ref = this.parent.node.children[toIndex];\n        // Send a `'before-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeAttach);\n        }\n        // Insert the widget's node before the sibling.\n        this.parent.node.insertBefore(widget.node, ref);\n        // Send an `'after-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterAttach);\n        }\n    };\n    /**\n     * Detach a widget from the parent's DOM node.\n     *\n     * @param index - The previous index of the widget in the layout.\n     *\n     * @param widget - The widget to detach from the parent.\n     *\n     * #### Notes\n     * This method is called automatically by the panel layout at the\n     * appropriate time. It should not be called directly by user code.\n     *\n     * The default implementation removes the widget's node from the\n     * parent's node, and sends the appropriate detach messages to the\n     * widget if the parent is attached to the DOM.\n     *\n     * Subclasses may reimplement this method to control how the widget's\n     * node is removed from the parent's node.\n     */\n    PanelLayout.prototype.detachWidget = function (index, widget) {\n        // Send a `'before-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeDetach);\n        }\n        // Remove the widget's node from the parent.\n        this.parent.node.removeChild(widget.node);\n        // Send an `'after-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterDetach);\n        }\n    };\n    return PanelLayout;\n}(Layout));\n\n/**\n * A layout which arranges its widgets in a single row or column.\n */\nvar BoxLayout = /** @class */ (function (_super) {\n    __extends(BoxLayout, _super);\n    /**\n     * Construct a new box layout.\n     *\n     * @param options - The options for initializing the layout.\n     */\n    function BoxLayout(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this) || this;\n        _this._fixed = 0;\n        _this._spacing = 4;\n        _this._dirty = false;\n        _this._sizers = [];\n        _this._items = [];\n        _this._box = null;\n        _this._alignment = 'start';\n        _this._direction = 'top-to-bottom';\n        if (options.direction !== undefined) {\n            _this._direction = options.direction;\n        }\n        if (options.alignment !== undefined) {\n            _this._alignment = options.alignment;\n        }\n        if (options.spacing !== undefined) {\n            _this._spacing = Private$2.clampSpacing(options.spacing);\n        }\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the layout.\n     */\n    BoxLayout.prototype.dispose = function () {\n        // Dispose of the layout items.\n        each(this._items, function (item) { item.dispose(); });\n        // Clear the layout state.\n        this._box = null;\n        this._items.length = 0;\n        this._sizers.length = 0;\n        // Dispose of the rest of the layout.\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(BoxLayout.prototype, \"direction\", {\n        /**\n         * Get the layout direction for the box layout.\n         */\n        get: function () {\n            return this._direction;\n        },\n        /**\n         * Set the layout direction for the box layout.\n         */\n        set: function (value) {\n            if (this._direction === value) {\n                return;\n            }\n            this._direction = value;\n            if (!this.parent) {\n                return;\n            }\n            this.parent.dataset['direction'] = value;\n            this.parent.fit();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(BoxLayout.prototype, \"alignment\", {\n        /**\n         * Get the content alignment for the box layout.\n         *\n         * #### Notes\n         * This is the alignment of the widgets in the layout direction.\n         *\n         * The alignment has no effect if the widgets can expand to fill the\n         * entire box layout.\n         */\n        get: function () {\n            return this._alignment;\n        },\n        /**\n         * Set the content alignment for the box layout.\n         *\n         * #### Notes\n         * This is the alignment of the widgets in the layout direction.\n         *\n         * The alignment has no effect if the widgets can expand to fill the\n         * entire box layout.\n         */\n        set: function (value) {\n            if (this._alignment === value) {\n                return;\n            }\n            this._alignment = value;\n            if (!this.parent) {\n                return;\n            }\n            this.parent.dataset['alignment'] = value;\n            this.parent.update();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(BoxLayout.prototype, \"spacing\", {\n        /**\n         * Get the inter-element spacing for the box layout.\n         */\n        get: function () {\n            return this._spacing;\n        },\n        /**\n         * Set the inter-element spacing for the box layout.\n         */\n        set: function (value) {\n            value = Private$2.clampSpacing(value);\n            if (this._spacing === value) {\n                return;\n            }\n            this._spacing = value;\n            if (!this.parent) {\n                return;\n            }\n            this.parent.fit();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Perform layout initialization which requires the parent widget.\n     */\n    BoxLayout.prototype.init = function () {\n        this.parent.dataset['direction'] = this.direction;\n        this.parent.dataset['alignment'] = this.alignment;\n        _super.prototype.init.call(this);\n    };\n    /**\n     * Attach a widget to the parent's DOM node.\n     *\n     * @param index - The current index of the widget in the layout.\n     *\n     * @param widget - The widget to attach to the parent.\n     *\n     * #### Notes\n     * This is a reimplementation of the superclass method.\n     */\n    BoxLayout.prototype.attachWidget = function (index, widget) {\n        // Create and add a new layout item for the widget.\n        ArrayExt.insert(this._items, index, new LayoutItem(widget));\n        // Create and add a new sizer for the widget.\n        ArrayExt.insert(this._sizers, index, new BoxSizer());\n        // Send a `'before-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeAttach);\n        }\n        // Add the widget's node to the parent.\n        this.parent.node.appendChild(widget.node);\n        // Send an `'after-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterAttach);\n        }\n        // Post a fit request for the parent widget.\n        this.parent.fit();\n    };\n    /**\n     * Move a widget in the parent's DOM node.\n     *\n     * @param fromIndex - The previous index of the widget in the layout.\n     *\n     * @param toIndex - The current index of the widget in the layout.\n     *\n     * @param widget - The widget to move in the parent.\n     *\n     * #### Notes\n     * This is a reimplementation of the superclass method.\n     */\n    BoxLayout.prototype.moveWidget = function (fromIndex, toIndex, widget) {\n        // Move the layout item for the widget.\n        ArrayExt.move(this._items, fromIndex, toIndex);\n        // Move the sizer for the widget.\n        ArrayExt.move(this._sizers, fromIndex, toIndex);\n        // Post an update request for the parent widget.\n        this.parent.update();\n    };\n    /**\n     * Detach a widget from the parent's DOM node.\n     *\n     * @param index - The previous index of the widget in the layout.\n     *\n     * @param widget - The widget to detach from the parent.\n     *\n     * #### Notes\n     * This is a reimplementation of the superclass method.\n     */\n    BoxLayout.prototype.detachWidget = function (index, widget) {\n        // Remove the layout item for the widget.\n        var item = ArrayExt.removeAt(this._items, index);\n        // Remove the sizer for the widget.\n        ArrayExt.removeAt(this._sizers, index);\n        // Send a `'before-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeDetach);\n        }\n        // Remove the widget's node from the parent.\n        this.parent.node.removeChild(widget.node);\n        // Send an `'after-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterDetach);\n        }\n        // Dispose of the layout item.\n        item.dispose();\n        // Post a fit request for the parent widget.\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'before-show'` message.\n     */\n    BoxLayout.prototype.onBeforeShow = function (msg) {\n        _super.prototype.onBeforeShow.call(this, msg);\n        this.parent.update();\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     */\n    BoxLayout.prototype.onBeforeAttach = function (msg) {\n        _super.prototype.onBeforeAttach.call(this, msg);\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'child-shown'` message.\n     */\n    BoxLayout.prototype.onChildShown = function (msg) {\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'child-hidden'` message.\n     */\n    BoxLayout.prototype.onChildHidden = function (msg) {\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'resize'` message.\n     */\n    BoxLayout.prototype.onResize = function (msg) {\n        if (this.parent.isVisible) {\n            this._update(msg.width, msg.height);\n        }\n    };\n    /**\n     * A message handler invoked on an `'update-request'` message.\n     */\n    BoxLayout.prototype.onUpdateRequest = function (msg) {\n        if (this.parent.isVisible) {\n            this._update(-1, -1);\n        }\n    };\n    /**\n     * A message handler invoked on a `'fit-request'` message.\n     */\n    BoxLayout.prototype.onFitRequest = function (msg) {\n        if (this.parent.isAttached) {\n            this._fit();\n        }\n    };\n    /**\n     * Fit the layout to the total size required by the widgets.\n     */\n    BoxLayout.prototype._fit = function () {\n        // Compute the visible item count.\n        var nVisible = 0;\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            nVisible += +!this._items[i].isHidden;\n        }\n        // Update the fixed space for the visible items.\n        this._fixed = this._spacing * Math.max(0, nVisible - 1);\n        // Setup the computed minimum size.\n        var horz = Private$2.isHorizontal(this._direction);\n        var minW = horz ? this._fixed : 0;\n        var minH = horz ? 0 : this._fixed;\n        // Update the sizers and computed minimum size.\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            // Fetch the item and corresponding box sizer.\n            var item = this._items[i];\n            var sizer = this._sizers[i];\n            // If the item is hidden, it should consume zero size.\n            if (item.isHidden) {\n                sizer.minSize = 0;\n                sizer.maxSize = 0;\n                continue;\n            }\n            // Update the size limits for the item.\n            item.fit();\n            // Update the size basis and stretch factor.\n            sizer.sizeHint = BoxLayout.getSizeBasis(item.widget);\n            sizer.stretch = BoxLayout.getStretch(item.widget);\n            // Update the sizer limits and computed min size.\n            if (horz) {\n                sizer.minSize = item.minWidth;\n                sizer.maxSize = item.maxWidth;\n                minW += item.minWidth;\n                minH = Math.max(minH, item.minHeight);\n            }\n            else {\n                sizer.minSize = item.minHeight;\n                sizer.maxSize = item.maxHeight;\n                minH += item.minHeight;\n                minW = Math.max(minW, item.minWidth);\n            }\n        }\n        // Update the box sizing and add it to the computed min size.\n        var box = this._box = ElementExt.boxSizing(this.parent.node);\n        minW += box.horizontalSum;\n        minH += box.verticalSum;\n        // Update the parent's min size constraints.\n        var style = this.parent.node.style;\n        style.minWidth = minW + \"px\";\n        style.minHeight = minH + \"px\";\n        // Set the dirty flag to ensure only a single update occurs.\n        this._dirty = true;\n        // Notify the ancestor that it should fit immediately. This may\n        // cause a resize of the parent, fulfilling the required update.\n        if (this.parent.parent) {\n            MessageLoop.sendMessage(this.parent.parent, Widget.Msg.FitRequest);\n        }\n        // If the dirty flag is still set, the parent was not resized.\n        // Trigger the required update on the parent widget immediately.\n        if (this._dirty) {\n            MessageLoop.sendMessage(this.parent, Widget.Msg.UpdateRequest);\n        }\n    };\n    /**\n     * Update the layout position and size of the widgets.\n     *\n     * The parent offset dimensions should be `-1` if unknown.\n     */\n    BoxLayout.prototype._update = function (offsetWidth, offsetHeight) {\n        // Clear the dirty flag to indicate the update occurred.\n        this._dirty = false;\n        // Compute the visible item count.\n        var nVisible = 0;\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            nVisible += +!this._items[i].isHidden;\n        }\n        // Bail early if there are no visible items to layout.\n        if (nVisible === 0) {\n            return;\n        }\n        // Measure the parent if the offset dimensions are unknown.\n        if (offsetWidth < 0) {\n            offsetWidth = this.parent.node.offsetWidth;\n        }\n        if (offsetHeight < 0) {\n            offsetHeight = this.parent.node.offsetHeight;\n        }\n        // Ensure the parent box sizing data is computed.\n        if (!this._box) {\n            this._box = ElementExt.boxSizing(this.parent.node);\n        }\n        // Compute the layout area adjusted for border and padding.\n        var top = this._box.paddingTop;\n        var left = this._box.paddingLeft;\n        var width = offsetWidth - this._box.horizontalSum;\n        var height = offsetHeight - this._box.verticalSum;\n        // Distribute the layout space and adjust the start position.\n        var delta;\n        switch (this._direction) {\n            case 'left-to-right':\n                delta = BoxEngine.calc(this._sizers, Math.max(0, width - this._fixed));\n                break;\n            case 'top-to-bottom':\n                delta = BoxEngine.calc(this._sizers, Math.max(0, height - this._fixed));\n                break;\n            case 'right-to-left':\n                delta = BoxEngine.calc(this._sizers, Math.max(0, width - this._fixed));\n                left += width;\n                break;\n            case 'bottom-to-top':\n                delta = BoxEngine.calc(this._sizers, Math.max(0, height - this._fixed));\n                top += height;\n                break;\n            default:\n                throw 'unreachable';\n        }\n        // Setup the variables for justification and alignment offset.\n        var extra = 0;\n        var offset = 0;\n        // Account for alignment if there is extra layout space.\n        if (delta > 0) {\n            switch (this._alignment) {\n                case 'start':\n                    break;\n                case 'center':\n                    extra = 0;\n                    offset = delta / 2;\n                    break;\n                case 'end':\n                    extra = 0;\n                    offset = delta;\n                    break;\n                case 'justify':\n                    extra = delta / nVisible;\n                    offset = 0;\n                    break;\n                default:\n                    throw 'unreachable';\n            }\n        }\n        // Layout the items using the computed box sizes.\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            // Fetch the item.\n            var item = this._items[i];\n            // Ignore hidden items.\n            if (item.isHidden) {\n                continue;\n            }\n            // Fetch the computed size for the widget.\n            var size = this._sizers[i].size;\n            // Update the widget geometry and advance the relevant edge.\n            switch (this._direction) {\n                case 'left-to-right':\n                    item.update(left + offset, top, size + extra, height);\n                    left += size + extra + this._spacing;\n                    break;\n                case 'top-to-bottom':\n                    item.update(left, top + offset, width, size + extra);\n                    top += size + extra + this._spacing;\n                    break;\n                case 'right-to-left':\n                    item.update(left - offset - size - extra, top, size + extra, height);\n                    left -= size + extra + this._spacing;\n                    break;\n                case 'bottom-to-top':\n                    item.update(left, top - offset - size - extra, width, size + extra);\n                    top -= size + extra + this._spacing;\n                    break;\n                default:\n                    throw 'unreachable';\n            }\n        }\n    };\n    return BoxLayout;\n}(PanelLayout));\n/**\n * The namespace for the `BoxLayout` class statics.\n */\n(function (BoxLayout) {\n    /**\n     * Get the box layout stretch factor for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @returns The box layout stretch factor for the widget.\n     */\n    function getStretch(widget) {\n        return Private$2.stretchProperty.get(widget);\n    }\n    BoxLayout.getStretch = getStretch;\n    /**\n     * Set the box layout stretch factor for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @param value - The value for the stretch factor.\n     */\n    function setStretch(widget, value) {\n        Private$2.stretchProperty.set(widget, value);\n    }\n    BoxLayout.setStretch = setStretch;\n    /**\n     * Get the box layout size basis for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @returns The box layout size basis for the widget.\n     */\n    function getSizeBasis(widget) {\n        return Private$2.sizeBasisProperty.get(widget);\n    }\n    BoxLayout.getSizeBasis = getSizeBasis;\n    /**\n     * Set the box layout size basis for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @param value - The value for the size basis.\n     */\n    function setSizeBasis(widget, value) {\n        Private$2.sizeBasisProperty.set(widget, value);\n    }\n    BoxLayout.setSizeBasis = setSizeBasis;\n})(BoxLayout || (BoxLayout = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$2;\n(function (Private) {\n    /**\n     * The property descriptor for a widget stretch factor.\n     */\n    Private.stretchProperty = new AttachedProperty({\n        name: 'stretch',\n        create: function () { return 0; },\n        coerce: function (owner, value) { return Math.max(0, Math.floor(value)); },\n        changed: onChildSizingChanged\n    });\n    /**\n     * The property descriptor for a widget size basis.\n     */\n    Private.sizeBasisProperty = new AttachedProperty({\n        name: 'sizeBasis',\n        create: function () { return 0; },\n        coerce: function (owner, value) { return Math.max(0, Math.floor(value)); },\n        changed: onChildSizingChanged\n    });\n    /**\n     * Test whether a direction has horizontal orientation.\n     */\n    function isHorizontal(dir) {\n        return dir === 'left-to-right' || dir === 'right-to-left';\n    }\n    Private.isHorizontal = isHorizontal;\n    /**\n     * Clamp a spacing value to an integer >= 0.\n     */\n    function clampSpacing(value) {\n        return Math.max(0, Math.floor(value));\n    }\n    Private.clampSpacing = clampSpacing;\n    /**\n     * The change handler for the attached sizing properties.\n     */\n    function onChildSizingChanged(child) {\n        if (child.parent && child.parent.layout instanceof BoxLayout) {\n            child.parent.fit();\n        }\n    }\n})(Private$2 || (Private$2 = {}));\n\n/**\n * A simple and convenient panel widget class.\n *\n * #### Notes\n * This class is suitable as a base class for implementing a variety of\n * convenience panel widgets, but can also be used directly with CSS to\n * arrange a collection of widgets.\n *\n * This class provides a convenience wrapper around a [[PanelLayout]].\n */\nvar Panel = /** @class */ (function (_super) {\n    __extends(Panel, _super);\n    /**\n     * Construct a new panel.\n     *\n     * @param options - The options for initializing the panel.\n     */\n    function Panel(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this) || this;\n        _this.addClass('lm-Panel');\n        /* <DEPRECATED> */\n        _this.addClass('p-Panel');\n        /* </DEPRECATED> */\n        _this.layout = Private$3.createLayout(options);\n        return _this;\n    }\n    Object.defineProperty(Panel.prototype, \"widgets\", {\n        /**\n         * A read-only array of the widgets in the panel.\n         */\n        get: function () {\n            return this.layout.widgets;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Add a widget to the end of the panel.\n     *\n     * @param widget - The widget to add to the panel.\n     *\n     * #### Notes\n     * If the widget is already contained in the panel, it will be moved.\n     */\n    Panel.prototype.addWidget = function (widget) {\n        this.layout.addWidget(widget);\n    };\n    /**\n     * Insert a widget at the specified index.\n     *\n     * @param index - The index at which to insert the widget.\n     *\n     * @param widget - The widget to insert into to the panel.\n     *\n     * #### Notes\n     * If the widget is already contained in the panel, it will be moved.\n     */\n    Panel.prototype.insertWidget = function (index, widget) {\n        this.layout.insertWidget(index, widget);\n    };\n    return Panel;\n}(Widget));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$3;\n(function (Private) {\n    /**\n     * Create a panel layout for the given panel options.\n     */\n    function createLayout(options) {\n        return options.layout || new PanelLayout();\n    }\n    Private.createLayout = createLayout;\n})(Private$3 || (Private$3 = {}));\n\n/**\n * A panel which arranges its widgets in a single row or column.\n *\n * #### Notes\n * This class provides a convenience wrapper around a [[BoxLayout]].\n */\nvar BoxPanel = /** @class */ (function (_super) {\n    __extends(BoxPanel, _super);\n    /**\n     * Construct a new box panel.\n     *\n     * @param options - The options for initializing the box panel.\n     */\n    function BoxPanel(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this, { layout: Private$4.createLayout(options) }) || this;\n        _this.addClass('lm-BoxPanel');\n        /* <DEPRECATED> */\n        _this.addClass('p-BoxPanel');\n        return _this;\n        /* </DEPRECATED> */\n    }\n    Object.defineProperty(BoxPanel.prototype, \"direction\", {\n        /**\n         * Get the layout direction for the box panel.\n         */\n        get: function () {\n            return this.layout.direction;\n        },\n        /**\n         * Set the layout direction for the box panel.\n         */\n        set: function (value) {\n            this.layout.direction = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(BoxPanel.prototype, \"alignment\", {\n        /**\n         * Get the content alignment for the box panel.\n         *\n         * #### Notes\n         * This is the alignment of the widgets in the layout direction.\n         *\n         * The alignment has no effect if the widgets can expand to fill the\n         * entire box layout.\n         */\n        get: function () {\n            return this.layout.alignment;\n        },\n        /**\n         * Set the content alignment for the box panel.\n         *\n         * #### Notes\n         * This is the alignment of the widgets in the layout direction.\n         *\n         * The alignment has no effect if the widgets can expand to fill the\n         * entire box layout.\n         */\n        set: function (value) {\n            this.layout.alignment = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(BoxPanel.prototype, \"spacing\", {\n        /**\n         * Get the inter-element spacing for the box panel.\n         */\n        get: function () {\n            return this.layout.spacing;\n        },\n        /**\n         * Set the inter-element spacing for the box panel.\n         */\n        set: function (value) {\n            this.layout.spacing = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * A message handler invoked on a `'child-added'` message.\n     */\n    BoxPanel.prototype.onChildAdded = function (msg) {\n        msg.child.addClass('lm-BoxPanel-child');\n        /* <DEPRECATED> */\n        msg.child.addClass('p-BoxPanel-child');\n        /* </DEPRECATED> */\n    };\n    /**\n     * A message handler invoked on a `'child-removed'` message.\n     */\n    BoxPanel.prototype.onChildRemoved = function (msg) {\n        msg.child.removeClass('lm-BoxPanel-child');\n        /* <DEPRECATED> */\n        msg.child.removeClass('p-BoxPanel-child');\n        /* </DEPRECATED> */\n    };\n    return BoxPanel;\n}(Panel));\n/**\n * The namespace for the `BoxPanel` class statics.\n */\n(function (BoxPanel) {\n    /**\n     * Get the box panel stretch factor for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @returns The box panel stretch factor for the widget.\n     */\n    function getStretch(widget) {\n        return BoxLayout.getStretch(widget);\n    }\n    BoxPanel.getStretch = getStretch;\n    /**\n     * Set the box panel stretch factor for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @param value - The value for the stretch factor.\n     */\n    function setStretch(widget, value) {\n        BoxLayout.setStretch(widget, value);\n    }\n    BoxPanel.setStretch = setStretch;\n    /**\n     * Get the box panel size basis for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @returns The box panel size basis for the widget.\n     */\n    function getSizeBasis(widget) {\n        return BoxLayout.getSizeBasis(widget);\n    }\n    BoxPanel.getSizeBasis = getSizeBasis;\n    /**\n     * Set the box panel size basis for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @param value - The value for the size basis.\n     */\n    function setSizeBasis(widget, value) {\n        BoxLayout.setSizeBasis(widget, value);\n    }\n    BoxPanel.setSizeBasis = setSizeBasis;\n})(BoxPanel || (BoxPanel = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$4;\n(function (Private) {\n    /**\n     * Create a box layout for the given panel options.\n     */\n    function createLayout(options) {\n        return options.layout || new BoxLayout(options);\n    }\n    Private.createLayout = createLayout;\n})(Private$4 || (Private$4 = {}));\n\n/**\n * A widget which displays command items as a searchable palette.\n */\nvar CommandPalette = /** @class */ (function (_super) {\n    __extends(CommandPalette, _super);\n    /**\n     * Construct a new command palette.\n     *\n     * @param options - The options for initializing the palette.\n     */\n    function CommandPalette(options) {\n        var _this = _super.call(this, { node: Private$5.createNode() }) || this;\n        _this._activeIndex = -1;\n        _this._items = [];\n        _this._results = null;\n        _this.addClass('lm-CommandPalette');\n        /* <DEPRECATED> */\n        _this.addClass('p-CommandPalette');\n        /* </DEPRECATED> */\n        _this.setFlag(Widget.Flag.DisallowLayout);\n        _this.commands = options.commands;\n        _this.renderer = options.renderer || CommandPalette.defaultRenderer;\n        _this.commands.commandChanged.connect(_this._onGenericChange, _this);\n        _this.commands.keyBindingChanged.connect(_this._onGenericChange, _this);\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the widget.\n     */\n    CommandPalette.prototype.dispose = function () {\n        this._items.length = 0;\n        this._results = null;\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(CommandPalette.prototype, \"searchNode\", {\n        /**\n         * The command palette search node.\n         *\n         * #### Notes\n         * This is the node which contains the search-related elements.\n         */\n        get: function () {\n            return this.node.getElementsByClassName('lm-CommandPalette-search')[0];\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(CommandPalette.prototype, \"inputNode\", {\n        /**\n         * The command palette input node.\n         *\n         * #### Notes\n         * This is the actual input node for the search area.\n         */\n        get: function () {\n            return this.node.getElementsByClassName('lm-CommandPalette-input')[0];\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(CommandPalette.prototype, \"contentNode\", {\n        /**\n         * The command palette content node.\n         *\n         * #### Notes\n         * This is the node which holds the command item nodes.\n         *\n         * Modifying this node directly can lead to undefined behavior.\n         */\n        get: function () {\n            return this.node.getElementsByClassName('lm-CommandPalette-content')[0];\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(CommandPalette.prototype, \"items\", {\n        /**\n         * A read-only array of the command items in the palette.\n         */\n        get: function () {\n            return this._items;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Add a command item to the command palette.\n     *\n     * @param options - The options for creating the command item.\n     *\n     * @returns The command item added to the palette.\n     */\n    CommandPalette.prototype.addItem = function (options) {\n        // Create a new command item for the options.\n        var item = Private$5.createItem(this.commands, options);\n        // Add the item to the array.\n        this._items.push(item);\n        // Refresh the search results.\n        this.refresh();\n        // Return the item added to the palette.\n        return item;\n    };\n    /**\n     * Adds command items to the command palette.\n     *\n     * @param items - An array of options for creating each command item.\n     *\n     * @returns The command items added to the palette.\n     */\n    CommandPalette.prototype.addItems = function (items) {\n        var _this = this;\n        var newItems = items.map(function (item) { return Private$5.createItem(_this.commands, item); });\n        newItems.forEach(function (item) { return _this._items.push(item); });\n        this.refresh();\n        return newItems;\n    };\n    /**\n     * Remove an item from the command palette.\n     *\n     * @param item - The item to remove from the palette.\n     *\n     * #### Notes\n     * This is a no-op if the item is not in the palette.\n     */\n    CommandPalette.prototype.removeItem = function (item) {\n        this.removeItemAt(this._items.indexOf(item));\n    };\n    /**\n     * Remove the item at a given index from the command palette.\n     *\n     * @param index - The index of the item to remove.\n     *\n     * #### Notes\n     * This is a no-op if the index is out of range.\n     */\n    CommandPalette.prototype.removeItemAt = function (index) {\n        // Remove the item from the array.\n        var item = ArrayExt.removeAt(this._items, index);\n        // Bail if the index is out of range.\n        if (!item) {\n            return;\n        }\n        // Refresh the search results.\n        this.refresh();\n    };\n    /**\n     * Remove all items from the command palette.\n     */\n    CommandPalette.prototype.clearItems = function () {\n        // Bail if there is nothing to remove.\n        if (this._items.length === 0) {\n            return;\n        }\n        // Clear the array of items.\n        this._items.length = 0;\n        // Refresh the search results.\n        this.refresh();\n    };\n    /**\n     * Clear the search results and schedule an update.\n     *\n     * #### Notes\n     * This should be called whenever the search results of the palette\n     * should be updated.\n     *\n     * This is typically called automatically by the palette as needed,\n     * but can be called manually if the input text is programatically\n     * changed.\n     *\n     * The rendered results are updated asynchronously.\n     */\n    CommandPalette.prototype.refresh = function () {\n        this._results = null;\n        if (this.inputNode.value !== '') {\n            var clear = this.node.getElementsByClassName('lm-close-icon')[0];\n            clear.style.display = 'inherit';\n        }\n        else {\n            var clear = this.node.getElementsByClassName('lm-close-icon')[0];\n            clear.style.display = 'none';\n        }\n        this.update();\n    };\n    /**\n     * Handle the DOM events for the command palette.\n     *\n     * @param event - The DOM event sent to the command palette.\n     *\n     * #### Notes\n     * This method implements the DOM `EventListener` interface and is\n     * called in response to events on the command palette's DOM node.\n     * It should not be called directly by user code.\n     */\n    CommandPalette.prototype.handleEvent = function (event) {\n        switch (event.type) {\n            case 'click':\n                this._evtClick(event);\n                break;\n            case 'keydown':\n                this._evtKeyDown(event);\n                break;\n            case 'input':\n                this.refresh();\n                break;\n            case 'focus':\n            case 'blur':\n                this._toggleFocused();\n                break;\n        }\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     */\n    CommandPalette.prototype.onBeforeAttach = function (msg) {\n        this.node.addEventListener('click', this);\n        this.node.addEventListener('keydown', this);\n        this.node.addEventListener('input', this);\n        this.node.addEventListener('focus', this, true);\n        this.node.addEventListener('blur', this, true);\n    };\n    /**\n     * A message handler invoked on an `'after-detach'` message.\n     */\n    CommandPalette.prototype.onAfterDetach = function (msg) {\n        this.node.removeEventListener('click', this);\n        this.node.removeEventListener('keydown', this);\n        this.node.removeEventListener('input', this);\n        this.node.removeEventListener('focus', this, true);\n        this.node.removeEventListener('blur', this, true);\n    };\n    /**\n     * A message handler invoked on an `'activate-request'` message.\n     */\n    CommandPalette.prototype.onActivateRequest = function (msg) {\n        if (this.isAttached) {\n            var input = this.inputNode;\n            input.focus();\n            input.select();\n        }\n    };\n    /**\n     * A message handler invoked on an `'update-request'` message.\n     */\n    CommandPalette.prototype.onUpdateRequest = function (msg) {\n        // Fetch the current query text and content node.\n        var query = this.inputNode.value;\n        var contentNode = this.contentNode;\n        // Ensure the search results are generated.\n        var results = this._results;\n        if (!results) {\n            // Generate and store the new search results.\n            results = this._results = Private$5.search(this._items, query);\n            // Reset the active index.\n            this._activeIndex = (query ? ArrayExt.findFirstIndex(results, Private$5.canActivate) : -1);\n        }\n        // If there is no query and no results, clear the content.\n        if (!query && results.length === 0) {\n            VirtualDOM.render(null, contentNode);\n            return;\n        }\n        // If the is a query but no results, render the empty message.\n        if (query && results.length === 0) {\n            var content_1 = this.renderer.renderEmptyMessage({ query: query });\n            VirtualDOM.render(content_1, contentNode);\n            return;\n        }\n        // Create the render content for the search results.\n        var renderer = this.renderer;\n        var activeIndex = this._activeIndex;\n        var content = new Array(results.length);\n        for (var i = 0, n = results.length; i < n; ++i) {\n            var result = results[i];\n            if (result.type === 'header') {\n                var indices = result.indices;\n                var category = result.category;\n                content[i] = renderer.renderHeader({ category: category, indices: indices });\n            }\n            else {\n                var item = result.item;\n                var indices = result.indices;\n                var active = i === activeIndex;\n                content[i] = renderer.renderItem({ item: item, indices: indices, active: active });\n            }\n        }\n        // Render the search result content.\n        VirtualDOM.render(content, contentNode);\n        // Adjust the scroll position as needed.\n        if (activeIndex < 0 || activeIndex >= results.length) {\n            contentNode.scrollTop = 0;\n        }\n        else {\n            var element = contentNode.children[activeIndex];\n            ElementExt.scrollIntoViewIfNeeded(contentNode, element);\n        }\n    };\n    /**\n     * Handle the `'click'` event for the command palette.\n     */\n    CommandPalette.prototype._evtClick = function (event) {\n        // Bail if the click is not the left button.\n        if (event.button !== 0) {\n            return;\n        }\n        // Clear input if the target is clear button\n        if (event.target.classList.contains(\"lm-close-icon\")) {\n            this.inputNode.value = '';\n            this.refresh();\n            return;\n        }\n        // Find the index of the item which was clicked.\n        var index = ArrayExt.findFirstIndex(this.contentNode.children, function (node) {\n            return node.contains(event.target);\n        });\n        // Bail if the click was not on an item.\n        if (index === -1) {\n            return;\n        }\n        // Kill the event when a content item is clicked.\n        event.preventDefault();\n        event.stopPropagation();\n        // Execute the item if possible.\n        this._execute(index);\n    };\n    /**\n     * Handle the `'keydown'` event for the command palette.\n     */\n    CommandPalette.prototype._evtKeyDown = function (event) {\n        if (event.altKey || event.ctrlKey || event.metaKey || event.shiftKey) {\n            return;\n        }\n        switch (event.keyCode) {\n            case 13: // Enter\n                event.preventDefault();\n                event.stopPropagation();\n                this._execute(this._activeIndex);\n                break;\n            case 38: // Up Arrow\n                event.preventDefault();\n                event.stopPropagation();\n                this._activatePreviousItem();\n                break;\n            case 40: // Down Arrow\n                event.preventDefault();\n                event.stopPropagation();\n                this._activateNextItem();\n                break;\n        }\n    };\n    /**\n     * Activate the next enabled command item.\n     */\n    CommandPalette.prototype._activateNextItem = function () {\n        // Bail if there are no search results.\n        if (!this._results || this._results.length === 0) {\n            return;\n        }\n        // Find the next enabled item index.\n        var ai = this._activeIndex;\n        var n = this._results.length;\n        var start = ai < n - 1 ? ai + 1 : 0;\n        var stop = start === 0 ? n - 1 : start - 1;\n        this._activeIndex = ArrayExt.findFirstIndex(this._results, Private$5.canActivate, start, stop);\n        // Schedule an update of the items.\n        this.update();\n    };\n    /**\n     * Activate the previous enabled command item.\n     */\n    CommandPalette.prototype._activatePreviousItem = function () {\n        // Bail if there are no search results.\n        if (!this._results || this._results.length === 0) {\n            return;\n        }\n        // Find the previous enabled item index.\n        var ai = this._activeIndex;\n        var n = this._results.length;\n        var start = ai <= 0 ? n - 1 : ai - 1;\n        var stop = start === n - 1 ? 0 : start + 1;\n        this._activeIndex = ArrayExt.findLastIndex(this._results, Private$5.canActivate, start, stop);\n        // Schedule an update of the items.\n        this.update();\n    };\n    /**\n     * Execute the command item at the given index, if possible.\n     */\n    CommandPalette.prototype._execute = function (index) {\n        // Bail if there are no search results.\n        if (!this._results) {\n            return;\n        }\n        // Bail if the index is out of range.\n        var part = this._results[index];\n        if (!part) {\n            return;\n        }\n        // Update the search text if the item is a header.\n        if (part.type === 'header') {\n            var input = this.inputNode;\n            input.value = part.category.toLowerCase() + \" \";\n            input.focus();\n            this.refresh();\n            return;\n        }\n        // Bail if item is not enabled.\n        if (!part.item.isEnabled) {\n            return;\n        }\n        // Execute the item.\n        this.commands.execute(part.item.command, part.item.args);\n        // Clear the query text.\n        this.inputNode.value = '';\n        // Refresh the search results.\n        this.refresh();\n    };\n    /**\n     * Toggle the focused modifier based on the input node focus state.\n     */\n    CommandPalette.prototype._toggleFocused = function () {\n        var focused = document.activeElement === this.inputNode;\n        this.toggleClass('lm-mod-focused', focused);\n        /* <DEPRECATED> */\n        this.toggleClass('p-mod-focused', focused);\n        /* </DEPRECATED> */\n    };\n    /**\n     * A signal handler for generic command changes.\n     */\n    CommandPalette.prototype._onGenericChange = function () {\n        this.refresh();\n    };\n    return CommandPalette;\n}(Widget));\n/**\n * The namespace for the `CommandPalette` class statics.\n */\n(function (CommandPalette) {\n    /**\n     * The default implementation of `IRenderer`.\n     */\n    var Renderer = /** @class */ (function () {\n        function Renderer() {\n        }\n        /**\n         * Render the virtual element for a command palette header.\n         *\n         * @param data - The data to use for rendering the header.\n         *\n         * @returns A virtual element representing the header.\n         */\n        Renderer.prototype.renderHeader = function (data) {\n            var content = this.formatHeader(data);\n            return h.li({ className: 'lm-CommandPalette-header'\n                    /* <DEPRECATED> */\n                    + ' p-CommandPalette-header'\n                /* </DEPRECATED> */\n            }, content);\n        };\n        /**\n         * Render the virtual element for a command palette item.\n         *\n         * @param data - The data to use for rendering the item.\n         *\n         * @returns A virtual element representing the item.\n         */\n        Renderer.prototype.renderItem = function (data) {\n            var className = this.createItemClass(data);\n            var dataset = this.createItemDataset(data);\n            return (h.li({ className: className, dataset: dataset }, this.renderItemIcon(data), this.renderItemContent(data), this.renderItemShortcut(data)));\n        };\n        /**\n         * Render the empty results message for a command palette.\n         *\n         * @param data - The data to use for rendering the message.\n         *\n         * @returns A virtual element representing the message.\n         */\n        Renderer.prototype.renderEmptyMessage = function (data) {\n            var content = this.formatEmptyMessage(data);\n            return h.li({\n                className: 'lm-CommandPalette-emptyMessage'\n                    /* <DEPRECATED> */\n                    + ' p-CommandPalette-emptyMessage'\n                /* </DEPRECATED> */\n            }, content);\n        };\n        /**\n         * Render the icon for a command palette item.\n         *\n         * @param data - The data to use for rendering the icon.\n         *\n         * @returns A virtual element representing the icon.\n         */\n        Renderer.prototype.renderItemIcon = function (data) {\n            var className = this.createIconClass(data);\n            /* <DEPRECATED> */\n            if (typeof data.item.icon === 'string') {\n                return h.div({ className: className }, data.item.iconLabel);\n            }\n            /* </DEPRECATED> */\n            // if data.item.icon is undefined, it will be ignored\n            return h.div({ className: className }, data.item.icon, data.item.iconLabel);\n        };\n        /**\n         * Render the content for a command palette item.\n         *\n         * @param data - The data to use for rendering the content.\n         *\n         * @returns A virtual element representing the content.\n         */\n        Renderer.prototype.renderItemContent = function (data) {\n            return (h.div({\n                className: 'lm-CommandPalette-itemContent'\n                    /* <DEPRECATED> */\n                    + ' p-CommandPalette-itemContent'\n                /* </DEPRECATED> */\n            }, this.renderItemLabel(data), this.renderItemCaption(data)));\n        };\n        /**\n         * Render the label for a command palette item.\n         *\n         * @param data - The data to use for rendering the label.\n         *\n         * @returns A virtual element representing the label.\n         */\n        Renderer.prototype.renderItemLabel = function (data) {\n            var content = this.formatItemLabel(data);\n            return h.div({\n                className: 'lm-CommandPalette-itemLabel'\n                    /* <DEPRECATED> */\n                    + ' p-CommandPalette-itemLabel'\n                /* </DEPRECATED> */\n            }, content);\n        };\n        /**\n         * Render the caption for a command palette item.\n         *\n         * @param data - The data to use for rendering the caption.\n         *\n         * @returns A virtual element representing the caption.\n         */\n        Renderer.prototype.renderItemCaption = function (data) {\n            var content = this.formatItemCaption(data);\n            return h.div({\n                className: 'lm-CommandPalette-itemCaption'\n                    /* <DEPRECATED> */\n                    + ' p-CommandPalette-itemCaption'\n                /* </DEPRECATED> */\n            }, content);\n        };\n        /**\n         * Render the shortcut for a command palette item.\n         *\n         * @param data - The data to use for rendering the shortcut.\n         *\n         * @returns A virtual element representing the shortcut.\n         */\n        Renderer.prototype.renderItemShortcut = function (data) {\n            var content = this.formatItemShortcut(data);\n            return h.div({\n                className: 'lm-CommandPalette-itemShortcut'\n                    /* <DEPRECATED> */\n                    + ' p-CommandPalette-itemShortcut'\n                /* </DEPRECATED> */\n            }, content);\n        };\n        /**\n         * Create the class name for the command palette item.\n         *\n         * @param data - The data to use for the class name.\n         *\n         * @returns The full class name for the command palette item.\n         */\n        Renderer.prototype.createItemClass = function (data) {\n            // Set up the initial class name.\n            var name = 'lm-CommandPalette-item';\n            /* <DEPRECATED> */\n            name += ' p-CommandPalette-item';\n            /* </DEPRECATED> */\n            // Add the boolean state classes.\n            if (!data.item.isEnabled) {\n                name += ' lm-mod-disabled';\n                /* <DEPRECATED> */\n                name += ' p-mod-disabled';\n                /* </DEPRECATED> */\n            }\n            if (data.item.isToggled) {\n                name += ' lm-mod-toggled';\n                /* <DEPRECATED> */\n                name += ' p-mod-toggled';\n                /* </DEPRECATED> */\n            }\n            if (data.active) {\n                name += ' lm-mod-active';\n                /* <DEPRECATED> */\n                name += ' p-mod-active';\n                /* </DEPRECATED> */\n            }\n            // Add the extra class.\n            var extra = data.item.className;\n            if (extra) {\n                name += \" \" + extra;\n            }\n            // Return the complete class name.\n            return name;\n        };\n        /**\n         * Create the dataset for the command palette item.\n         *\n         * @param data - The data to use for creating the dataset.\n         *\n         * @returns The dataset for the command palette item.\n         */\n        Renderer.prototype.createItemDataset = function (data) {\n            return __assign(__assign({}, data.item.dataset), { command: data.item.command });\n        };\n        /**\n         * Create the class name for the command item icon.\n         *\n         * @param data - The data to use for the class name.\n         *\n         * @returns The full class name for the item icon.\n         */\n        Renderer.prototype.createIconClass = function (data) {\n            var name = 'lm-CommandPalette-itemIcon';\n            /* <DEPRECATED> */\n            name += ' p-CommandPalette-itemIcon';\n            /* </DEPRECATED> */\n            var extra = data.item.iconClass;\n            return extra ? name + \" \" + extra : name;\n        };\n        /**\n         * Create the render content for the header node.\n         *\n         * @param data - The data to use for the header content.\n         *\n         * @returns The content to add to the header node.\n         */\n        Renderer.prototype.formatHeader = function (data) {\n            if (!data.indices || data.indices.length === 0) {\n                return data.category;\n            }\n            return StringExt.highlight(data.category, data.indices, h.mark);\n        };\n        /**\n         * Create the render content for the empty message node.\n         *\n         * @param data - The data to use for the empty message content.\n         *\n         * @returns The content to add to the empty message node.\n         */\n        Renderer.prototype.formatEmptyMessage = function (data) {\n            return \"No commands found that match '\" + data.query + \"'\";\n        };\n        /**\n         * Create the render content for the item shortcut node.\n         *\n         * @param data - The data to use for the shortcut content.\n         *\n         * @returns The content to add to the shortcut node.\n         */\n        Renderer.prototype.formatItemShortcut = function (data) {\n            var kb = data.item.keyBinding;\n            return kb ? kb.keys.map(CommandRegistry.formatKeystroke).join(', ') : null;\n        };\n        /**\n         * Create the render content for the item label node.\n         *\n         * @param data - The data to use for the label content.\n         *\n         * @returns The content to add to the label node.\n         */\n        Renderer.prototype.formatItemLabel = function (data) {\n            if (!data.indices || data.indices.length === 0) {\n                return data.item.label;\n            }\n            return StringExt.highlight(data.item.label, data.indices, h.mark);\n        };\n        /**\n         * Create the render content for the item caption node.\n         *\n         * @param data - The data to use for the caption content.\n         *\n         * @returns The content to add to the caption node.\n         */\n        Renderer.prototype.formatItemCaption = function (data) {\n            return data.item.caption;\n        };\n        return Renderer;\n    }());\n    CommandPalette.Renderer = Renderer;\n    /**\n     * The default `Renderer` instance.\n     */\n    CommandPalette.defaultRenderer = new Renderer();\n})(CommandPalette || (CommandPalette = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$5;\n(function (Private) {\n    /**\n     * Create the DOM node for a command palette.\n     */\n    function createNode() {\n        var node = document.createElement('div');\n        var search = document.createElement('div');\n        var wrapper = document.createElement('div');\n        var input = document.createElement('input');\n        var content = document.createElement('ul');\n        var clear = document.createElement('button');\n        search.className = 'lm-CommandPalette-search';\n        wrapper.className = 'lm-CommandPalette-wrapper';\n        input.className = 'lm-CommandPalette-input';\n        clear.className = 'lm-close-icon';\n        content.className = 'lm-CommandPalette-content';\n        /* <DEPRECATED> */\n        search.classList.add('p-CommandPalette-search');\n        wrapper.classList.add('p-CommandPalette-wrapper');\n        input.classList.add('p-CommandPalette-input');\n        content.classList.add('p-CommandPalette-content');\n        /* </DEPRECATED> */\n        input.spellcheck = false;\n        wrapper.appendChild(input);\n        wrapper.appendChild(clear);\n        search.appendChild(wrapper);\n        node.appendChild(search);\n        node.appendChild(content);\n        return node;\n    }\n    Private.createNode = createNode;\n    /**\n     * Create a new command item from a command registry and options.\n     */\n    function createItem(commands, options) {\n        return new CommandItem(commands, options);\n    }\n    Private.createItem = createItem;\n    /**\n     * Search an array of command items for fuzzy matches.\n     */\n    function search(items, query) {\n        // Fuzzy match the items for the query.\n        var scores = matchItems(items, query);\n        // Sort the items based on their score.\n        scores.sort(scoreCmp);\n        // Create the results for the search.\n        return createResults(scores);\n    }\n    Private.search = search;\n    /**\n     * Test whether a result item can be activated.\n     */\n    function canActivate(result) {\n        return result.type === 'item' && result.item.isEnabled;\n    }\n    Private.canActivate = canActivate;\n    /**\n     * Normalize a category for a command item.\n     */\n    function normalizeCategory(category) {\n        return category.trim().replace(/\\s+/g, ' ');\n    }\n    /**\n     * Normalize the query text for a fuzzy search.\n     */\n    function normalizeQuery(text) {\n        return text.replace(/\\s+/g, '').toLowerCase();\n    }\n    /**\n     * Perform a fuzzy match on an array of command items.\n     */\n    function matchItems(items, query) {\n        // Normalize the query text to lower case with no whitespace.\n        query = normalizeQuery(query);\n        // Create the array to hold the scores.\n        var scores = [];\n        // Iterate over the items and match against the query.\n        for (var i = 0, n = items.length; i < n; ++i) {\n            // Ignore items which are not visible.\n            var item = items[i];\n            if (!item.isVisible) {\n                continue;\n            }\n            // If the query is empty, all items are matched by default.\n            if (!query) {\n                scores.push({\n                    matchType: 3 /* Default */,\n                    categoryIndices: null,\n                    labelIndices: null,\n                    score: 0, item: item\n                });\n                continue;\n            }\n            // Run the fuzzy search for the item and query.\n            var score = fuzzySearch(item, query);\n            // Ignore the item if it is not a match.\n            if (!score) {\n                continue;\n            }\n            // Penalize disabled items.\n            // TODO - push disabled items all the way down in sort cmp?\n            if (!item.isEnabled) {\n                score.score += 1000;\n            }\n            // Add the score to the results.\n            scores.push(score);\n        }\n        // Return the final array of scores.\n        return scores;\n    }\n    /**\n     * Perform a fuzzy search on a single command item.\n     */\n    function fuzzySearch(item, query) {\n        // Create the source text to be searched.\n        var category = item.category.toLowerCase();\n        var label = item.label.toLowerCase();\n        var source = category + \" \" + label;\n        // Set up the match score and indices array.\n        var score = Infinity;\n        var indices = null;\n        // The regex for search word boundaries\n        var rgx = /\\b\\w/g;\n        // Search the source by word boundary.\n        while (true) {\n            // Find the next word boundary in the source.\n            var rgxMatch = rgx.exec(source);\n            // Break if there is no more source context.\n            if (!rgxMatch) {\n                break;\n            }\n            // Run the string match on the relevant substring.\n            var match = StringExt.matchSumOfDeltas(source, query, rgxMatch.index);\n            // Break if there is no match.\n            if (!match) {\n                break;\n            }\n            // Update the match if the score is better.\n            if (match && match.score <= score) {\n                score = match.score;\n                indices = match.indices;\n            }\n        }\n        // Bail if there was no match.\n        if (!indices || score === Infinity) {\n            return null;\n        }\n        // Compute the pivot index between category and label text.\n        var pivot = category.length + 1;\n        // Find the slice index to separate matched indices.\n        var j = ArrayExt.lowerBound(indices, pivot, function (a, b) { return a - b; });\n        // Extract the matched category and label indices.\n        var categoryIndices = indices.slice(0, j);\n        var labelIndices = indices.slice(j);\n        // Adjust the label indices for the pivot offset.\n        for (var i = 0, n = labelIndices.length; i < n; ++i) {\n            labelIndices[i] -= pivot;\n        }\n        // Handle a pure label match.\n        if (categoryIndices.length === 0) {\n            return {\n                matchType: 0 /* Label */,\n                categoryIndices: null,\n                labelIndices: labelIndices,\n                score: score, item: item\n            };\n        }\n        // Handle a pure category match.\n        if (labelIndices.length === 0) {\n            return {\n                matchType: 1 /* Category */,\n                categoryIndices: categoryIndices,\n                labelIndices: null,\n                score: score, item: item\n            };\n        }\n        // Handle a split match.\n        return {\n            matchType: 2 /* Split */,\n            categoryIndices: categoryIndices,\n            labelIndices: labelIndices,\n            score: score, item: item\n        };\n    }\n    /**\n     * A sort comparison function for a match score.\n     */\n    function scoreCmp(a, b) {\n        // First compare based on the match type\n        var m1 = a.matchType - b.matchType;\n        if (m1 !== 0) {\n            return m1;\n        }\n        // Otherwise, compare based on the match score.\n        var d1 = a.score - b.score;\n        if (d1 !== 0) {\n            return d1;\n        }\n        // Find the match index based on the match type.\n        var i1 = 0;\n        var i2 = 0;\n        switch (a.matchType) {\n            case 0 /* Label */:\n                i1 = a.labelIndices[0];\n                i2 = b.labelIndices[0];\n                break;\n            case 1 /* Category */:\n            case 2 /* Split */:\n                i1 = a.categoryIndices[0];\n                i2 = b.categoryIndices[0];\n                break;\n        }\n        // Compare based on the match index.\n        if (i1 !== i2) {\n            return i1 - i2;\n        }\n        // Otherwise, compare by category.\n        var d2 = a.item.category.localeCompare(b.item.category);\n        if (d2 !== 0) {\n            return d2;\n        }\n        // Otherwise, compare by rank.\n        var r1 = a.item.rank;\n        var r2 = b.item.rank;\n        if (r1 !== r2) {\n            return r1 < r2 ? -1 : 1; // Infinity safe\n        }\n        // Finally, compare by label.\n        return a.item.label.localeCompare(b.item.label);\n    }\n    /**\n     * Create the results from an array of sorted scores.\n     */\n    function createResults(scores) {\n        // Set up an array to track which scores have been visited.\n        var visited = new Array(scores.length);\n        ArrayExt.fill(visited, false);\n        // Set up the search results array.\n        var results = [];\n        // Iterate over each score in the array.\n        for (var i = 0, n = scores.length; i < n; ++i) {\n            // Ignore a score which has already been processed.\n            if (visited[i]) {\n                continue;\n            }\n            // Extract the current item and indices.\n            var _a = scores[i], item = _a.item, categoryIndices = _a.categoryIndices;\n            // Extract the category for the current item.\n            var category = item.category;\n            // Add the header result for the category.\n            results.push({ type: 'header', category: category, indices: categoryIndices });\n            // Find the rest of the scores with the same category.\n            for (var j = i; j < n; ++j) {\n                // Ignore a score which has already been processed.\n                if (visited[j]) {\n                    continue;\n                }\n                // Extract the data for the current score.\n                var _b = scores[j], item_1 = _b.item, labelIndices = _b.labelIndices;\n                // Ignore an item with a different category.\n                if (item_1.category !== category) {\n                    continue;\n                }\n                // Create the item result for the score.\n                results.push({ type: 'item', item: item_1, indices: labelIndices });\n                // Mark the score as processed.\n                visited[j] = true;\n            }\n        }\n        // Return the final results.\n        return results;\n    }\n    /**\n     * A concrete implementation of `CommandPalette.IItem`.\n     */\n    var CommandItem = /** @class */ (function () {\n        /**\n         * Construct a new command item.\n         */\n        function CommandItem(commands, options) {\n            this._commands = commands;\n            this.category = normalizeCategory(options.category);\n            this.command = options.command;\n            this.args = options.args || JSONExt.emptyObject;\n            this.rank = options.rank !== undefined ? options.rank : Infinity;\n        }\n        Object.defineProperty(CommandItem.prototype, \"label\", {\n            /**\n             * The display label for the command item.\n             */\n            get: function () {\n                return this._commands.label(this.command, this.args);\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(CommandItem.prototype, \"icon\", {\n            /**\n             * The icon renderer for the command item.\n             */\n            get: function () {\n                return this._commands.icon(this.command, this.args);\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(CommandItem.prototype, \"iconClass\", {\n            /**\n             * The icon class for the command item.\n             */\n            get: function () {\n                return this._commands.iconClass(this.command, this.args);\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(CommandItem.prototype, \"iconLabel\", {\n            /**\n             * The icon label for the command item.\n             */\n            get: function () {\n                return this._commands.iconLabel(this.command, this.args);\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(CommandItem.prototype, \"caption\", {\n            /**\n             * The display caption for the command item.\n             */\n            get: function () {\n                return this._commands.caption(this.command, this.args);\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(CommandItem.prototype, \"className\", {\n            /**\n             * The extra class name for the command item.\n             */\n            get: function () {\n                return this._commands.className(this.command, this.args);\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(CommandItem.prototype, \"dataset\", {\n            /**\n             * The dataset for the command item.\n             */\n            get: function () {\n                return this._commands.dataset(this.command, this.args);\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(CommandItem.prototype, \"isEnabled\", {\n            /**\n             * Whether the command item is enabled.\n             */\n            get: function () {\n                return this._commands.isEnabled(this.command, this.args);\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(CommandItem.prototype, \"isToggled\", {\n            /**\n             * Whether the command item is toggled.\n             */\n            get: function () {\n                return this._commands.isToggled(this.command, this.args);\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(CommandItem.prototype, \"isVisible\", {\n            /**\n             * Whether the command item is visible.\n             */\n            get: function () {\n                return this._commands.isVisible(this.command, this.args);\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(CommandItem.prototype, \"keyBinding\", {\n            /**\n             * The key binding for the command item.\n             */\n            get: function () {\n                var _a = this, command = _a.command, args = _a.args;\n                return ArrayExt.findLastValue(this._commands.keyBindings, function (kb) {\n                    return kb.command === command && JSONExt.deepEqual(kb.args, args);\n                }) || null;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        return CommandItem;\n    }());\n})(Private$5 || (Private$5 = {}));\n\n/**\n * A widget which displays items as a canonical menu.\n */\nvar Menu = /** @class */ (function (_super) {\n    __extends(Menu, _super);\n    /**\n     * Construct a new menu.\n     *\n     * @param options - The options for initializing the menu.\n     */\n    function Menu(options) {\n        var _this = _super.call(this, { node: Private$6.createNode() }) || this;\n        _this._childIndex = -1;\n        _this._activeIndex = -1;\n        _this._openTimerID = 0;\n        _this._closeTimerID = 0;\n        _this._items = [];\n        _this._childMenu = null;\n        _this._parentMenu = null;\n        _this._aboutToClose = new Signal(_this);\n        _this._menuRequested = new Signal(_this);\n        _this.addClass('lm-Menu');\n        /* <DEPRECATED> */\n        _this.addClass('p-Menu');\n        /* </DEPRECATED> */\n        _this.setFlag(Widget.Flag.DisallowLayout);\n        _this.commands = options.commands;\n        _this.renderer = options.renderer || Menu.defaultRenderer;\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the menu.\n     */\n    Menu.prototype.dispose = function () {\n        this.close();\n        this._items.length = 0;\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(Menu.prototype, \"aboutToClose\", {\n        /**\n         * A signal emitted just before the menu is closed.\n         *\n         * #### Notes\n         * This signal is emitted when the menu receives a `'close-request'`\n         * message, just before it removes itself from the DOM.\n         *\n         * This signal is not emitted if the menu is already detached from\n         * the DOM when it receives the `'close-request'` message.\n         */\n        get: function () {\n            return this._aboutToClose;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Menu.prototype, \"menuRequested\", {\n        /**\n         * A signal emitted when a new menu is requested by the user.\n         *\n         * #### Notes\n         * This signal is emitted whenever the user presses the right or left\n         * arrow keys, and a submenu cannot be opened or closed in response.\n         *\n         * This signal is useful when implementing menu bars in order to open\n         * the next or previous menu in response to a user key press.\n         *\n         * This signal is only emitted for the root menu in a hierarchy.\n         */\n        get: function () {\n            return this._menuRequested;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Menu.prototype, \"parentMenu\", {\n        /**\n         * The parent menu of the menu.\n         *\n         * #### Notes\n         * This is `null` unless the menu is an open submenu.\n         */\n        get: function () {\n            return this._parentMenu;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Menu.prototype, \"childMenu\", {\n        /**\n         * The child menu of the menu.\n         *\n         * #### Notes\n         * This is `null` unless the menu has an open submenu.\n         */\n        get: function () {\n            return this._childMenu;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Menu.prototype, \"rootMenu\", {\n        /**\n         * The root menu of the menu hierarchy.\n         */\n        get: function () {\n            var menu = this;\n            while (menu._parentMenu) {\n                menu = menu._parentMenu;\n            }\n            return menu;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Menu.prototype, \"leafMenu\", {\n        /**\n         * The leaf menu of the menu hierarchy.\n         */\n        get: function () {\n            var menu = this;\n            while (menu._childMenu) {\n                menu = menu._childMenu;\n            }\n            return menu;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Menu.prototype, \"contentNode\", {\n        /**\n         * The menu content node.\n         *\n         * #### Notes\n         * This is the node which holds the menu item nodes.\n         *\n         * Modifying this node directly can lead to undefined behavior.\n         */\n        get: function () {\n            return this.node.getElementsByClassName('lm-Menu-content')[0];\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Menu.prototype, \"activeItem\", {\n        /**\n         * Get the currently active menu item.\n         */\n        get: function () {\n            return this._items[this._activeIndex] || null;\n        },\n        /**\n         * Set the currently active menu item.\n         *\n         * #### Notes\n         * If the item cannot be activated, the item will be set to `null`.\n         */\n        set: function (value) {\n            this.activeIndex = value ? this._items.indexOf(value) : -1;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Menu.prototype, \"activeIndex\", {\n        /**\n         * Get the index of the currently active menu item.\n         *\n         * #### Notes\n         * This will be `-1` if no menu item is active.\n         */\n        get: function () {\n            return this._activeIndex;\n        },\n        /**\n         * Set the index of the currently active menu item.\n         *\n         * #### Notes\n         * If the item cannot be activated, the index will be set to `-1`.\n         */\n        set: function (value) {\n            // Adjust the value for an out of range index.\n            if (value < 0 || value >= this._items.length) {\n                value = -1;\n            }\n            // Ensure the item can be activated.\n            if (value !== -1 && !Private$6.canActivate(this._items[value])) {\n                value = -1;\n            }\n            // Bail if the index will not change.\n            if (this._activeIndex === value) {\n                return;\n            }\n            // Update the active index.\n            this._activeIndex = value;\n            // schedule an update of the items.\n            this.update();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Menu.prototype, \"items\", {\n        /**\n         * A read-only array of the menu items in the menu.\n         */\n        get: function () {\n            return this._items;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Activate the next selectable item in the menu.\n     *\n     * #### Notes\n     * If no item is selectable, the index will be set to `-1`.\n     */\n    Menu.prototype.activateNextItem = function () {\n        var n = this._items.length;\n        var ai = this._activeIndex;\n        var start = ai < n - 1 ? ai + 1 : 0;\n        var stop = start === 0 ? n - 1 : start - 1;\n        this.activeIndex = ArrayExt.findFirstIndex(this._items, Private$6.canActivate, start, stop);\n    };\n    /**\n     * Activate the previous selectable item in the menu.\n     *\n     * #### Notes\n     * If no item is selectable, the index will be set to `-1`.\n     */\n    Menu.prototype.activatePreviousItem = function () {\n        var n = this._items.length;\n        var ai = this._activeIndex;\n        var start = ai <= 0 ? n - 1 : ai - 1;\n        var stop = start === n - 1 ? 0 : start + 1;\n        this.activeIndex = ArrayExt.findLastIndex(this._items, Private$6.canActivate, start, stop);\n    };\n    /**\n     * Trigger the active menu item.\n     *\n     * #### Notes\n     * If the active item is a submenu, it will be opened and the first\n     * item will be activated.\n     *\n     * If the active item is a command, the command will be executed.\n     *\n     * If the menu is not attached, this is a no-op.\n     *\n     * If there is no active item, this is a no-op.\n     */\n    Menu.prototype.triggerActiveItem = function () {\n        // Bail if the menu is not attached.\n        if (!this.isAttached) {\n            return;\n        }\n        // Bail if there is no active item.\n        var item = this.activeItem;\n        if (!item) {\n            return;\n        }\n        // Cancel the pending timers.\n        this._cancelOpenTimer();\n        this._cancelCloseTimer();\n        // If the item is a submenu, open it.\n        if (item.type === 'submenu') {\n            this._openChildMenu(true);\n            return;\n        }\n        // Close the root menu before executing the command.\n        this.rootMenu.close();\n        // Execute the command for the item.\n        var command = item.command, args = item.args;\n        if (this.commands.isEnabled(command, args)) {\n            this.commands.execute(command, args);\n        }\n        else {\n            console.log(\"Command '\" + command + \"' is disabled.\");\n        }\n    };\n    /**\n     * Add a menu item to the end of the menu.\n     *\n     * @param options - The options for creating the menu item.\n     *\n     * @returns The menu item added to the menu.\n     */\n    Menu.prototype.addItem = function (options) {\n        return this.insertItem(this._items.length, options);\n    };\n    /**\n     * Insert a menu item into the menu at the specified index.\n     *\n     * @param index - The index at which to insert the item.\n     *\n     * @param options - The options for creating the menu item.\n     *\n     * @returns The menu item added to the menu.\n     *\n     * #### Notes\n     * The index will be clamped to the bounds of the items.\n     */\n    Menu.prototype.insertItem = function (index, options) {\n        // Close the menu if it's attached.\n        if (this.isAttached) {\n            this.close();\n        }\n        // Reset the active index.\n        this.activeIndex = -1;\n        // Clamp the insert index to the array bounds.\n        var i = Math.max(0, Math.min(index, this._items.length));\n        // Create the item for the options.\n        var item = Private$6.createItem(this, options);\n        // Insert the item into the array.\n        ArrayExt.insert(this._items, i, item);\n        // Schedule an update of the items.\n        this.update();\n        // Return the item added to the menu.\n        return item;\n    };\n    /**\n     * Remove an item from the menu.\n     *\n     * @param item - The item to remove from the menu.\n     *\n     * #### Notes\n     * This is a no-op if the item is not in the menu.\n     */\n    Menu.prototype.removeItem = function (item) {\n        this.removeItemAt(this._items.indexOf(item));\n    };\n    /**\n     * Remove the item at a given index from the menu.\n     *\n     * @param index - The index of the item to remove.\n     *\n     * #### Notes\n     * This is a no-op if the index is out of range.\n     */\n    Menu.prototype.removeItemAt = function (index) {\n        // Close the menu if it's attached.\n        if (this.isAttached) {\n            this.close();\n        }\n        // Reset the active index.\n        this.activeIndex = -1;\n        // Remove the item from the array.\n        var item = ArrayExt.removeAt(this._items, index);\n        // Bail if the index is out of range.\n        if (!item) {\n            return;\n        }\n        // Schedule an update of the items.\n        this.update();\n    };\n    /**\n     * Remove all menu items from the menu.\n     */\n    Menu.prototype.clearItems = function () {\n        // Close the menu if it's attached.\n        if (this.isAttached) {\n            this.close();\n        }\n        // Reset the active index.\n        this.activeIndex = -1;\n        // Bail if there is nothing to remove.\n        if (this._items.length === 0) {\n            return;\n        }\n        // Clear the items.\n        this._items.length = 0;\n        // Schedule an update of the items.\n        this.update();\n    };\n    /**\n     * Open the menu at the specified location.\n     *\n     * @param x - The client X coordinate of the menu location.\n     *\n     * @param y - The client Y coordinate of the menu location.\n     *\n     * @param options - The additional options for opening the menu.\n     *\n     * #### Notes\n     * The menu will be opened at the given location unless it will not\n     * fully fit on the screen. If it will not fit, it will be adjusted\n     * to fit naturally on the screen.\n     *\n     * This is a no-op if the menu is already attached to the DOM.\n     */\n    Menu.prototype.open = function (x, y, options) {\n        if (options === void 0) { options = {}; }\n        // Bail early if the menu is already attached.\n        if (this.isAttached) {\n            return;\n        }\n        // Extract the position options.\n        var forceX = options.forceX || false;\n        var forceY = options.forceY || false;\n        // Open the menu as a root menu.\n        Private$6.openRootMenu(this, x, y, forceX, forceY);\n        // Activate the menu to accept keyboard input.\n        this.activate();\n    };\n    /**\n     * Handle the DOM events for the menu.\n     *\n     * @param event - The DOM event sent to the menu.\n     *\n     * #### Notes\n     * This method implements the DOM `EventListener` interface and is\n     * called in response to events on the menu's DOM nodes. It should\n     * not be called directly by user code.\n     */\n    Menu.prototype.handleEvent = function (event) {\n        switch (event.type) {\n            case 'keydown':\n                this._evtKeyDown(event);\n                break;\n            case 'mouseup':\n                this._evtMouseUp(event);\n                break;\n            case 'mousemove':\n                this._evtMouseMove(event);\n                break;\n            case 'mouseenter':\n                this._evtMouseEnter(event);\n                break;\n            case 'mouseleave':\n                this._evtMouseLeave(event);\n                break;\n            case 'mousedown':\n                this._evtMouseDown(event);\n                break;\n            case 'contextmenu':\n                event.preventDefault();\n                event.stopPropagation();\n                break;\n        }\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     */\n    Menu.prototype.onBeforeAttach = function (msg) {\n        this.node.addEventListener('keydown', this);\n        this.node.addEventListener('mouseup', this);\n        this.node.addEventListener('mousemove', this);\n        this.node.addEventListener('mouseenter', this);\n        this.node.addEventListener('mouseleave', this);\n        this.node.addEventListener('contextmenu', this);\n        document.addEventListener('mousedown', this, true);\n    };\n    /**\n     * A message handler invoked on an `'after-detach'` message.\n     */\n    Menu.prototype.onAfterDetach = function (msg) {\n        this.node.removeEventListener('keydown', this);\n        this.node.removeEventListener('mouseup', this);\n        this.node.removeEventListener('mousemove', this);\n        this.node.removeEventListener('mouseenter', this);\n        this.node.removeEventListener('mouseleave', this);\n        this.node.removeEventListener('contextmenu', this);\n        document.removeEventListener('mousedown', this, true);\n    };\n    /**\n     * A message handler invoked on an `'activate-request'` message.\n     */\n    Menu.prototype.onActivateRequest = function (msg) {\n        if (this.isAttached) {\n            this.node.focus();\n        }\n    };\n    /**\n     * A message handler invoked on an `'update-request'` message.\n     */\n    Menu.prototype.onUpdateRequest = function (msg) {\n        var items = this._items;\n        var renderer = this.renderer;\n        var activeIndex = this._activeIndex;\n        var collapsedFlags = Private$6.computeCollapsed(items);\n        var content = new Array(items.length);\n        for (var i = 0, n = items.length; i < n; ++i) {\n            var item = items[i];\n            var active = i === activeIndex;\n            var collapsed = collapsedFlags[i];\n            content[i] = renderer.renderItem({ item: item, active: active, collapsed: collapsed });\n        }\n        VirtualDOM.render(content, this.contentNode);\n    };\n    /**\n     * A message handler invoked on a `'close-request'` message.\n     */\n    Menu.prototype.onCloseRequest = function (msg) {\n        // Cancel the pending timers.\n        this._cancelOpenTimer();\n        this._cancelCloseTimer();\n        // Reset the active index.\n        this.activeIndex = -1;\n        // Close any open child menu.\n        var childMenu = this._childMenu;\n        if (childMenu) {\n            this._childIndex = -1;\n            this._childMenu = null;\n            childMenu._parentMenu = null;\n            childMenu.close();\n        }\n        // Remove this menu from its parent and activate the parent.\n        var parentMenu = this._parentMenu;\n        if (parentMenu) {\n            this._parentMenu = null;\n            parentMenu._childIndex = -1;\n            parentMenu._childMenu = null;\n            parentMenu.activate();\n        }\n        // Emit the `aboutToClose` signal if the menu is attached.\n        if (this.isAttached) {\n            this._aboutToClose.emit(undefined);\n        }\n        // Finish closing the menu.\n        _super.prototype.onCloseRequest.call(this, msg);\n    };\n    /**\n     * Handle the `'keydown'` event for the menu.\n     *\n     * #### Notes\n     * This listener is attached to the menu node.\n     */\n    Menu.prototype._evtKeyDown = function (event) {\n        // A menu handles all keydown events.\n        event.preventDefault();\n        event.stopPropagation();\n        // Fetch the key code for the event.\n        var kc = event.keyCode;\n        // Enter\n        if (kc === 13) {\n            this.triggerActiveItem();\n            return;\n        }\n        // Escape\n        if (kc === 27) {\n            this.close();\n            return;\n        }\n        // Left Arrow\n        if (kc === 37) {\n            if (this._parentMenu) {\n                this.close();\n            }\n            else {\n                this._menuRequested.emit('previous');\n            }\n            return;\n        }\n        // Up Arrow\n        if (kc === 38) {\n            this.activatePreviousItem();\n            return;\n        }\n        // Right Arrow\n        if (kc === 39) {\n            var item = this.activeItem;\n            if (item && item.type === 'submenu') {\n                this.triggerActiveItem();\n            }\n            else {\n                this.rootMenu._menuRequested.emit('next');\n            }\n            return;\n        }\n        // Down Arrow\n        if (kc === 40) {\n            this.activateNextItem();\n            return;\n        }\n        // Get the pressed key character.\n        var key = getKeyboardLayout().keyForKeydownEvent(event);\n        // Bail if the key is not valid.\n        if (!key) {\n            return;\n        }\n        // Search for the next best matching mnemonic item.\n        var start = this._activeIndex + 1;\n        var result = Private$6.findMnemonic(this._items, key, start);\n        // Handle the requested mnemonic based on the search results.\n        // If exactly one mnemonic is matched, that item is triggered.\n        // Otherwise, the next mnemonic is activated if available,\n        // followed by the auto mnemonic if available.\n        if (result.index !== -1 && !result.multiple) {\n            this.activeIndex = result.index;\n            this.triggerActiveItem();\n        }\n        else if (result.index !== -1) {\n            this.activeIndex = result.index;\n        }\n        else if (result.auto !== -1) {\n            this.activeIndex = result.auto;\n        }\n    };\n    /**\n     * Handle the `'mouseup'` event for the menu.\n     *\n     * #### Notes\n     * This listener is attached to the menu node.\n     */\n    Menu.prototype._evtMouseUp = function (event) {\n        if (event.button !== 0) {\n            return;\n        }\n        event.preventDefault();\n        event.stopPropagation();\n        this.triggerActiveItem();\n    };\n    /**\n     * Handle the `'mousemove'` event for the menu.\n     *\n     * #### Notes\n     * This listener is attached to the menu node.\n     */\n    Menu.prototype._evtMouseMove = function (event) {\n        // Hit test the item nodes for the item under the mouse.\n        var index = ArrayExt.findFirstIndex(this.contentNode.children, function (node) {\n            return ElementExt.hitTest(node, event.clientX, event.clientY);\n        });\n        // Bail early if the mouse is already over the active index.\n        if (index === this._activeIndex) {\n            return;\n        }\n        // Update and coerce the active index.\n        this.activeIndex = index;\n        index = this.activeIndex;\n        // If the index is the current child index, cancel the timers.\n        if (index === this._childIndex) {\n            this._cancelOpenTimer();\n            this._cancelCloseTimer();\n            return;\n        }\n        // If a child menu is currently open, start the close timer.\n        if (this._childIndex !== -1) {\n            this._startCloseTimer();\n        }\n        // Cancel the open timer to give a full delay for opening.\n        this._cancelOpenTimer();\n        // Bail if the active item is not a valid submenu item.\n        var item = this.activeItem;\n        if (!item || item.type !== 'submenu' || !item.submenu) {\n            return;\n        }\n        // Start the open timer to open the active item submenu.\n        this._startOpenTimer();\n    };\n    /**\n     * Handle the `'mouseenter'` event for the menu.\n     *\n     * #### Notes\n     * This listener is attached to the menu node.\n     */\n    Menu.prototype._evtMouseEnter = function (event) {\n        // Synchronize the active ancestor items.\n        for (var menu = this._parentMenu; menu; menu = menu._parentMenu) {\n            menu._cancelOpenTimer();\n            menu._cancelCloseTimer();\n            menu.activeIndex = menu._childIndex;\n        }\n    };\n    /**\n     * Handle the `'mouseleave'` event for the menu.\n     *\n     * #### Notes\n     * This listener is attached to the menu node.\n     */\n    Menu.prototype._evtMouseLeave = function (event) {\n        // Cancel any pending submenu opening.\n        this._cancelOpenTimer();\n        // If there is no open child menu, just reset the active index.\n        if (!this._childMenu) {\n            this.activeIndex = -1;\n            return;\n        }\n        // If the mouse is over the child menu, cancel the close timer.\n        var clientX = event.clientX, clientY = event.clientY;\n        if (ElementExt.hitTest(this._childMenu.node, clientX, clientY)) {\n            this._cancelCloseTimer();\n            return;\n        }\n        // Otherwise, reset the active index and start the close timer.\n        this.activeIndex = -1;\n        this._startCloseTimer();\n    };\n    /**\n     * Handle the `'mousedown'` event for the menu.\n     *\n     * #### Notes\n     * This listener is attached to the document node.\n     */\n    Menu.prototype._evtMouseDown = function (event) {\n        // Bail if the menu is not a root menu.\n        if (this._parentMenu) {\n            return;\n        }\n        // The mouse button which is pressed is irrelevant. If the press\n        // is not on a menu, the entire hierarchy is closed and the event\n        // is allowed to propagate. This allows other code to act on the\n        // event, such as focusing the clicked element.\n        if (Private$6.hitTestMenus(this, event.clientX, event.clientY)) {\n            event.preventDefault();\n            event.stopPropagation();\n        }\n        else {\n            this.close();\n        }\n    };\n    /**\n     * Open the child menu at the active index immediately.\n     *\n     * If a different child menu is already open, it will be closed,\n     * even if the active item is not a valid submenu.\n     */\n    Menu.prototype._openChildMenu = function (activateFirst) {\n        if (activateFirst === void 0) { activateFirst = false; }\n        // If the item is not a valid submenu, close the child menu.\n        var item = this.activeItem;\n        if (!item || item.type !== 'submenu' || !item.submenu) {\n            this._closeChildMenu();\n            return;\n        }\n        // Do nothing if the child menu will not change.\n        var submenu = item.submenu;\n        if (submenu === this._childMenu) {\n            return;\n        }\n        // Ensure the current child menu is closed.\n        this._closeChildMenu();\n        // Update the private child state.\n        this._childMenu = submenu;\n        this._childIndex = this._activeIndex;\n        // Set the parent menu reference for the child.\n        submenu._parentMenu = this;\n        // Ensure the menu is updated and lookup the item node.\n        MessageLoop.sendMessage(this, Widget.Msg.UpdateRequest);\n        var itemNode = this.contentNode.children[this._activeIndex];\n        // Open the submenu at the active node.\n        Private$6.openSubmenu(submenu, itemNode);\n        // Activate the first item if desired.\n        if (activateFirst) {\n            submenu.activeIndex = -1;\n            submenu.activateNextItem();\n        }\n        // Activate the child menu.\n        submenu.activate();\n    };\n    /**\n     * Close the child menu immediately.\n     *\n     * This is a no-op if a child menu is not open.\n     */\n    Menu.prototype._closeChildMenu = function () {\n        if (this._childMenu) {\n            this._childMenu.close();\n        }\n    };\n    /**\n     * Start the open timer, unless it is already pending.\n     */\n    Menu.prototype._startOpenTimer = function () {\n        var _this = this;\n        if (this._openTimerID === 0) {\n            this._openTimerID = window.setTimeout(function () {\n                _this._openTimerID = 0;\n                _this._openChildMenu();\n            }, Private$6.TIMER_DELAY);\n        }\n    };\n    /**\n     * Start the close timer, unless it is already pending.\n     */\n    Menu.prototype._startCloseTimer = function () {\n        var _this = this;\n        if (this._closeTimerID === 0) {\n            this._closeTimerID = window.setTimeout(function () {\n                _this._closeTimerID = 0;\n                _this._closeChildMenu();\n            }, Private$6.TIMER_DELAY);\n        }\n    };\n    /**\n     * Cancel the open timer, if the timer is pending.\n     */\n    Menu.prototype._cancelOpenTimer = function () {\n        if (this._openTimerID !== 0) {\n            clearTimeout(this._openTimerID);\n            this._openTimerID = 0;\n        }\n    };\n    /**\n     * Cancel the close timer, if the timer is pending.\n     */\n    Menu.prototype._cancelCloseTimer = function () {\n        if (this._closeTimerID !== 0) {\n            clearTimeout(this._closeTimerID);\n            this._closeTimerID = 0;\n        }\n    };\n    return Menu;\n}(Widget));\n/**\n * The namespace for the `Menu` class statics.\n */\n(function (Menu) {\n    /**\n     * The default implementation of `IRenderer`.\n     *\n     * #### Notes\n     * Subclasses are free to reimplement rendering methods as needed.\n     */\n    var Renderer = /** @class */ (function () {\n        /**\n         * Construct a new renderer.\n         */\n        function Renderer() {\n        }\n        /**\n         * Render the virtual element for a menu item.\n         *\n         * @param data - The data to use for rendering the item.\n         *\n         * @returns A virtual element representing the item.\n         */\n        Renderer.prototype.renderItem = function (data) {\n            var className = this.createItemClass(data);\n            var dataset = this.createItemDataset(data);\n            var aria = this.createItemARIA(data);\n            return (h.li(__assign({ className: className, dataset: dataset }, aria), this.renderIcon(data), this.renderLabel(data), this.renderShortcut(data), this.renderSubmenu(data)));\n        };\n        /**\n         * Render the icon element for a menu item.\n         *\n         * @param data - The data to use for rendering the icon.\n         *\n         * @returns A virtual element representing the item icon.\n         */\n        Renderer.prototype.renderIcon = function (data) {\n            var className = this.createIconClass(data);\n            /* <DEPRECATED> */\n            if (typeof data.item.icon === 'string') {\n                return h.div({ className: className }, data.item.iconLabel);\n            }\n            /* </DEPRECATED> */\n            // if data.item.icon is undefined, it will be ignored\n            return h.div({ className: className }, data.item.icon, data.item.iconLabel);\n        };\n        /**\n         * Render the label element for a menu item.\n         *\n         * @param data - The data to use for rendering the label.\n         *\n         * @returns A virtual element representing the item label.\n         */\n        Renderer.prototype.renderLabel = function (data) {\n            var content = this.formatLabel(data);\n            return h.div({\n                className: 'lm-Menu-itemLabel'\n                    /* <DEPRECATED> */\n                    + ' p-Menu-itemLabel'\n                /* </DEPRECATED> */\n            }, content);\n        };\n        /**\n         * Render the shortcut element for a menu item.\n         *\n         * @param data - The data to use for rendering the shortcut.\n         *\n         * @returns A virtual element representing the item shortcut.\n         */\n        Renderer.prototype.renderShortcut = function (data) {\n            var content = this.formatShortcut(data);\n            return h.div({\n                className: 'lm-Menu-itemShortcut'\n                    /* <DEPRECATED> */\n                    + ' p-Menu-itemShortcut'\n                /* </DEPRECATED> */\n            }, content);\n        };\n        /**\n         * Render the submenu icon element for a menu item.\n         *\n         * @param data - The data to use for rendering the submenu icon.\n         *\n         * @returns A virtual element representing the submenu icon.\n         */\n        Renderer.prototype.renderSubmenu = function (data) {\n            return h.div({\n                className: 'lm-Menu-itemSubmenuIcon'\n                    /* <DEPRECATED> */\n                    + ' p-Menu-itemSubmenuIcon'\n                /* </DEPRECATED> */\n            });\n        };\n        /**\n         * Create the class name for the menu item.\n         *\n         * @param data - The data to use for the class name.\n         *\n         * @returns The full class name for the menu item.\n         */\n        Renderer.prototype.createItemClass = function (data) {\n            // Setup the initial class name.\n            var name = 'lm-Menu-item';\n            /* <DEPRECATED> */\n            name += ' p-Menu-item';\n            /* </DEPRECATED> */\n            // Add the boolean state classes.\n            if (!data.item.isEnabled) {\n                name += ' lm-mod-disabled';\n                /* <DEPRECATED> */\n                name += ' p-mod-disabled';\n                /* </DEPRECATED> */\n            }\n            if (data.item.isToggled) {\n                name += ' lm-mod-toggled';\n                /* <DEPRECATED> */\n                name += ' p-mod-toggled';\n                /* </DEPRECATED> */\n            }\n            if (!data.item.isVisible) {\n                name += ' lm-mod-hidden';\n                /* <DEPRECATED> */\n                name += ' p-mod-hidden';\n                /* </DEPRECATED> */\n            }\n            if (data.active) {\n                name += ' lm-mod-active';\n                /* <DEPRECATED> */\n                name += ' p-mod-active';\n                /* </DEPRECATED> */\n            }\n            if (data.collapsed) {\n                name += ' lm-mod-collapsed';\n                /* <DEPRECATED> */\n                name += ' p-mod-collapsed';\n                /* </DEPRECATED> */\n            }\n            // Add the extra class.\n            var extra = data.item.className;\n            if (extra) {\n                name += \" \" + extra;\n            }\n            // Return the complete class name.\n            return name;\n        };\n        /**\n         * Create the dataset for the menu item.\n         *\n         * @param data - The data to use for creating the dataset.\n         *\n         * @returns The dataset for the menu item.\n         */\n        Renderer.prototype.createItemDataset = function (data) {\n            var result;\n            var _a = data.item, type = _a.type, command = _a.command, dataset = _a.dataset;\n            if (type === 'command') {\n                result = __assign(__assign({}, dataset), { type: type, command: command });\n            }\n            else {\n                result = __assign(__assign({}, dataset), { type: type });\n            }\n            return result;\n        };\n        /**\n         * Create the class name for the menu item icon.\n         *\n         * @param data - The data to use for the class name.\n         *\n         * @returns The full class name for the item icon.\n         */\n        Renderer.prototype.createIconClass = function (data) {\n            var name = 'lm-Menu-itemIcon';\n            /* <DEPRECATED> */\n            name += ' p-Menu-itemIcon';\n            /* </DEPRECATED> */\n            var extra = data.item.iconClass;\n            return extra ? name + \" \" + extra : name;\n        };\n        /**\n         * Create the aria attributes for menu item.\n         *\n         * @param data - The data to use for the aria attributes.\n         *\n         * @returns The aria attributes object for the item.\n         */\n        Renderer.prototype.createItemARIA = function (data) {\n            var aria = {};\n            switch (data.item.type) {\n                case 'separator':\n                    aria.role = 'presentation';\n                    break;\n                case 'submenu':\n                    aria['aria-haspopup'] = 'true';\n                    break;\n                default:\n                    aria.role = 'menuitem';\n            }\n            return aria;\n        };\n        /**\n         * Create the render content for the label node.\n         *\n         * @param data - The data to use for the label content.\n         *\n         * @returns The content to add to the label node.\n         */\n        Renderer.prototype.formatLabel = function (data) {\n            // Fetch the label text and mnemonic index.\n            var _a = data.item, label = _a.label, mnemonic = _a.mnemonic;\n            // If the index is out of range, do not modify the label.\n            if (mnemonic < 0 || mnemonic >= label.length) {\n                return label;\n            }\n            // Split the label into parts.\n            var prefix = label.slice(0, mnemonic);\n            var suffix = label.slice(mnemonic + 1);\n            var char = label[mnemonic];\n            // Wrap the mnemonic character in a span.\n            var span = h.span({\n                className: 'lm-Menu-itemMnemonic'\n                    /* <DEPRECATED> */\n                    + ' p-Menu-itemMnemonic'\n                /* </DEPRECATED> */\n            }, char);\n            // Return the content parts.\n            return [prefix, span, suffix];\n        };\n        /**\n         * Create the render content for the shortcut node.\n         *\n         * @param data - The data to use for the shortcut content.\n         *\n         * @returns The content to add to the shortcut node.\n         */\n        Renderer.prototype.formatShortcut = function (data) {\n            var kb = data.item.keyBinding;\n            return kb ? kb.keys.map(CommandRegistry.formatKeystroke).join(', ') : null;\n        };\n        return Renderer;\n    }());\n    Menu.Renderer = Renderer;\n    /**\n     * The default `Renderer` instance.\n     */\n    Menu.defaultRenderer = new Renderer();\n})(Menu || (Menu = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$6;\n(function (Private) {\n    /**\n     * The ms delay for opening and closing a submenu.\n     */\n    Private.TIMER_DELAY = 300;\n    /**\n     * The horizontal pixel overlap for an open submenu.\n     */\n    Private.SUBMENU_OVERLAP = 3;\n    /**\n     * Create the DOM node for a menu.\n     */\n    function createNode() {\n        var node = document.createElement('div');\n        var content = document.createElement('ul');\n        content.className = 'lm-Menu-content';\n        /* <DEPRECATED> */\n        content.classList.add('p-Menu-content');\n        /* </DEPRECATED> */\n        node.appendChild(content);\n        content.setAttribute('role', 'menu');\n        node.tabIndex = -1;\n        return node;\n    }\n    Private.createNode = createNode;\n    /**\n     * Test whether a menu item can be activated.\n     */\n    function canActivate(item) {\n        return item.type !== 'separator' && item.isEnabled && item.isVisible;\n    }\n    Private.canActivate = canActivate;\n    /**\n     * Create a new menu item for an owner menu.\n     */\n    function createItem(owner, options) {\n        return new MenuItem(owner.commands, options);\n    }\n    Private.createItem = createItem;\n    /**\n     * Hit test a menu hierarchy starting at the given root.\n     */\n    function hitTestMenus(menu, x, y) {\n        for (var temp = menu; temp; temp = temp.childMenu) {\n            if (ElementExt.hitTest(temp.node, x, y)) {\n                return true;\n            }\n        }\n        return false;\n    }\n    Private.hitTestMenus = hitTestMenus;\n    /**\n     * Compute which extra separator items should be collapsed.\n     */\n    function computeCollapsed(items) {\n        // Allocate the return array and fill it with `false`.\n        var result = new Array(items.length);\n        ArrayExt.fill(result, false);\n        // Collapse the leading separators.\n        var k1 = 0;\n        var n = items.length;\n        for (; k1 < n; ++k1) {\n            var item = items[k1];\n            if (!item.isVisible) {\n                continue;\n            }\n            if (item.type !== 'separator') {\n                break;\n            }\n            result[k1] = true;\n        }\n        // Hide the trailing separators.\n        var k2 = n - 1;\n        for (; k2 >= 0; --k2) {\n            var item = items[k2];\n            if (!item.isVisible) {\n                continue;\n            }\n            if (item.type !== 'separator') {\n                break;\n            }\n            result[k2] = true;\n        }\n        // Hide the remaining consecutive separators.\n        var hide = false;\n        while (++k1 < k2) {\n            var item = items[k1];\n            if (!item.isVisible) {\n                continue;\n            }\n            if (item.type !== 'separator') {\n                hide = false;\n            }\n            else if (hide) {\n                result[k1] = true;\n            }\n            else {\n                hide = true;\n            }\n        }\n        // Return the resulting flags.\n        return result;\n    }\n    Private.computeCollapsed = computeCollapsed;\n    /**\n     * Open a menu as a root menu at the target location.\n     */\n    function openRootMenu(menu, x, y, forceX, forceY) {\n        // Ensure the menu is updated before attaching and measuring.\n        MessageLoop.sendMessage(menu, Widget.Msg.UpdateRequest);\n        // Get the current position and size of the main viewport.\n        var px = window.pageXOffset;\n        var py = window.pageYOffset;\n        var cw = document.documentElement.clientWidth;\n        var ch = document.documentElement.clientHeight;\n        // Compute the maximum allowed height for the menu.\n        var maxHeight = ch - (forceY ? y : 0);\n        // Fetch common variables.\n        var node = menu.node;\n        var style = node.style;\n        // Clear the menu geometry and prepare it for measuring.\n        style.top = '';\n        style.left = '';\n        style.width = '';\n        style.height = '';\n        style.visibility = 'hidden';\n        style.maxHeight = maxHeight + \"px\";\n        // Attach the menu to the document.\n        Widget.attach(menu, document.body);\n        // Measure the size of the menu.\n        var _a = node.getBoundingClientRect(), width = _a.width, height = _a.height;\n        // Adjust the X position of the menu to fit on-screen.\n        if (!forceX && (x + width > px + cw)) {\n            x = px + cw - width;\n        }\n        // Adjust the Y position of the menu to fit on-screen.\n        if (!forceY && (y + height > py + ch)) {\n            if (y > py + ch) {\n                y = py + ch - height;\n            }\n            else {\n                y = y - height;\n            }\n        }\n        // Update the position of the menu to the computed position.\n        style.top = Math.max(0, y) + \"px\";\n        style.left = Math.max(0, x) + \"px\";\n        // Finally, make the menu visible on the screen.\n        style.visibility = '';\n    }\n    Private.openRootMenu = openRootMenu;\n    /**\n     * Open a menu as a submenu using an item node for positioning.\n     */\n    function openSubmenu(submenu, itemNode) {\n        // Ensure the menu is updated before opening.\n        MessageLoop.sendMessage(submenu, Widget.Msg.UpdateRequest);\n        // Get the current position and size of the main viewport.\n        var px = window.pageXOffset;\n        var py = window.pageYOffset;\n        var cw = document.documentElement.clientWidth;\n        var ch = document.documentElement.clientHeight;\n        // Compute the maximum allowed height for the menu.\n        var maxHeight = ch;\n        // Fetch common variables.\n        var node = submenu.node;\n        var style = node.style;\n        // Clear the menu geometry and prepare it for measuring.\n        style.top = '';\n        style.left = '';\n        style.width = '';\n        style.height = '';\n        style.visibility = 'hidden';\n        style.maxHeight = maxHeight + \"px\";\n        // Attach the menu to the document.\n        Widget.attach(submenu, document.body);\n        // Measure the size of the menu.\n        var _a = node.getBoundingClientRect(), width = _a.width, height = _a.height;\n        // Compute the box sizing for the menu.\n        var box = ElementExt.boxSizing(submenu.node);\n        // Get the bounding rect for the target item node.\n        var itemRect = itemNode.getBoundingClientRect();\n        // Compute the target X position.\n        var x = itemRect.right - Private.SUBMENU_OVERLAP;\n        // Adjust the X position to fit on the screen.\n        if (x + width > px + cw) {\n            x = itemRect.left + Private.SUBMENU_OVERLAP - width;\n        }\n        // Compute the target Y position.\n        var y = itemRect.top - box.borderTop - box.paddingTop;\n        // Adjust the Y position to fit on the screen.\n        if (y + height > py + ch) {\n            y = itemRect.bottom + box.borderBottom + box.paddingBottom - height;\n        }\n        // Update the position of the menu to the computed position.\n        style.top = Math.max(0, y) + \"px\";\n        style.left = Math.max(0, x) + \"px\";\n        // Finally, make the menu visible on the screen.\n        style.visibility = '';\n    }\n    Private.openSubmenu = openSubmenu;\n    /**\n     * Find the best matching mnemonic item.\n     *\n     * The search starts at the given index and wraps around.\n     */\n    function findMnemonic(items, key, start) {\n        // Setup the result variables.\n        var index = -1;\n        var auto = -1;\n        var multiple = false;\n        // Normalize the key to upper case.\n        var upperKey = key.toUpperCase();\n        // Search the items from the given start index.\n        for (var i = 0, n = items.length; i < n; ++i) {\n            // Compute the wrapped index.\n            var k = (i + start) % n;\n            // Lookup the item\n            var item = items[k];\n            // Ignore items which cannot be activated.\n            if (!canActivate(item)) {\n                continue;\n            }\n            // Ignore items with an empty label.\n            var label = item.label;\n            if (label.length === 0) {\n                continue;\n            }\n            // Lookup the mnemonic index for the label.\n            var mn = item.mnemonic;\n            // Handle a valid mnemonic index.\n            if (mn >= 0 && mn < label.length) {\n                if (label[mn].toUpperCase() === upperKey) {\n                    if (index === -1) {\n                        index = k;\n                    }\n                    else {\n                        multiple = true;\n                    }\n                }\n                continue;\n            }\n            // Finally, handle the auto index if possible.\n            if (auto === -1 && label[0].toUpperCase() === upperKey) {\n                auto = k;\n            }\n        }\n        // Return the search results.\n        return { index: index, multiple: multiple, auto: auto };\n    }\n    Private.findMnemonic = findMnemonic;\n    /**\n     * A concrete implementation of `Menu.IItem`.\n     */\n    var MenuItem = /** @class */ (function () {\n        /**\n         * Construct a new menu item.\n         */\n        function MenuItem(commands, options) {\n            this._commands = commands;\n            this.type = options.type || 'command';\n            this.command = options.command || '';\n            this.args = options.args || JSONExt.emptyObject;\n            this.submenu = options.submenu || null;\n        }\n        Object.defineProperty(MenuItem.prototype, \"label\", {\n            /**\n             * The display label for the menu item.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    return this._commands.label(this.command, this.args);\n                }\n                if (this.type === 'submenu' && this.submenu) {\n                    return this.submenu.title.label;\n                }\n                return '';\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(MenuItem.prototype, \"mnemonic\", {\n            /**\n             * The mnemonic index for the menu item.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    return this._commands.mnemonic(this.command, this.args);\n                }\n                if (this.type === 'submenu' && this.submenu) {\n                    return this.submenu.title.mnemonic;\n                }\n                return -1;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(MenuItem.prototype, \"icon\", {\n            /**\n             * The icon renderer for the menu item.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    return this._commands.icon(this.command, this.args);\n                }\n                if (this.type === 'submenu' && this.submenu) {\n                    return this.submenu.title.icon;\n                }\n                /* <DEPRECATED> */\n                // alias to icon class if not otherwise defined\n                return this.iconClass;\n                /* </DEPRECATED> */\n                /* <FUTURE>\n                return undefined;\n                </FUTURE> */\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(MenuItem.prototype, \"iconClass\", {\n            /**\n             * The icon class for the menu item.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    return this._commands.iconClass(this.command, this.args);\n                }\n                if (this.type === 'submenu' && this.submenu) {\n                    return this.submenu.title.iconClass;\n                }\n                return '';\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(MenuItem.prototype, \"iconLabel\", {\n            /**\n             * The icon label for the menu item.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    return this._commands.iconLabel(this.command, this.args);\n                }\n                if (this.type === 'submenu' && this.submenu) {\n                    return this.submenu.title.iconLabel;\n                }\n                return '';\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(MenuItem.prototype, \"caption\", {\n            /**\n             * The display caption for the menu item.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    return this._commands.caption(this.command, this.args);\n                }\n                if (this.type === 'submenu' && this.submenu) {\n                    return this.submenu.title.caption;\n                }\n                return '';\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(MenuItem.prototype, \"className\", {\n            /**\n             * The extra class name for the menu item.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    return this._commands.className(this.command, this.args);\n                }\n                if (this.type === 'submenu' && this.submenu) {\n                    return this.submenu.title.className;\n                }\n                return '';\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(MenuItem.prototype, \"dataset\", {\n            /**\n             * The dataset for the menu item.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    return this._commands.dataset(this.command, this.args);\n                }\n                if (this.type === 'submenu' && this.submenu) {\n                    return this.submenu.title.dataset;\n                }\n                return {};\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(MenuItem.prototype, \"isEnabled\", {\n            /**\n             * Whether the menu item is enabled.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    return this._commands.isEnabled(this.command, this.args);\n                }\n                if (this.type === 'submenu') {\n                    return this.submenu !== null;\n                }\n                return true;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(MenuItem.prototype, \"isToggled\", {\n            /**\n             * Whether the menu item is toggled.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    return this._commands.isToggled(this.command, this.args);\n                }\n                return false;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(MenuItem.prototype, \"isVisible\", {\n            /**\n             * Whether the menu item is visible.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    return this._commands.isVisible(this.command, this.args);\n                }\n                if (this.type === 'submenu') {\n                    return this.submenu !== null;\n                }\n                return true;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(MenuItem.prototype, \"keyBinding\", {\n            /**\n             * The key binding for the menu item.\n             */\n            get: function () {\n                if (this.type === 'command') {\n                    var _a = this, command_1 = _a.command, args_1 = _a.args;\n                    return ArrayExt.findLastValue(this._commands.keyBindings, function (kb) {\n                        return kb.command === command_1 && JSONExt.deepEqual(kb.args, args_1);\n                    }) || null;\n                }\n                return null;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        return MenuItem;\n    }());\n})(Private$6 || (Private$6 = {}));\n\n/**\n * An object which implements a universal context menu.\n *\n * #### Notes\n * The items shown in the context menu are determined by CSS selector\n * matching against the DOM hierarchy at the site of the mouse click.\n * This is similar in concept to how keyboard shortcuts are matched\n * in the command registry.\n */\nvar ContextMenu = /** @class */ (function () {\n    /**\n     * Construct a new context menu.\n     *\n     * @param options - The options for initializing the menu.\n     */\n    function ContextMenu(options) {\n        this._idTick = 0;\n        this._items = [];\n        this.menu = new Menu(options);\n    }\n    /**\n     * Add an item to the context menu.\n     *\n     * @param options - The options for creating the item.\n     *\n     * @returns A disposable which will remove the item from the menu.\n     */\n    ContextMenu.prototype.addItem = function (options) {\n        var _this = this;\n        // Create an item from the given options.\n        var item = Private$7.createItem(options, this._idTick++);\n        // Add the item to the internal array.\n        this._items.push(item);\n        // Return a disposable which will remove the item.\n        return new DisposableDelegate(function () {\n            ArrayExt.removeFirstOf(_this._items, item);\n        });\n    };\n    /**\n     * Open the context menu in response to a `'contextmenu'` event.\n     *\n     * @param event - The `'contextmenu'` event of interest.\n     *\n     * @returns `true` if the menu was opened, or `false` if no items\n     *   matched the event and the menu was not opened.\n     *\n     * #### Notes\n     * This method will populate the context menu with items which match\n     * the propagation path of the event, then open the menu at the mouse\n     * position indicated by the event.\n     */\n    ContextMenu.prototype.open = function (event) {\n        var _this = this;\n        // Clear the current contents of the context menu.\n        this.menu.clearItems();\n        // Bail early if there are no items to match.\n        if (this._items.length === 0) {\n            return false;\n        }\n        // Find the matching items for the event.\n        var items = Private$7.matchItems(this._items, event);\n        // Bail if there are no matching items.\n        if (!items || items.length === 0) {\n            return false;\n        }\n        // Add the filtered items to the menu.\n        each(items, function (item) { _this.menu.addItem(item); });\n        // Open the context menu at the current mouse position.\n        this.menu.open(event.clientX, event.clientY);\n        // Indicate success.\n        return true;\n    };\n    return ContextMenu;\n}());\n/**\n * The namespace for the module implementation details.\n */\nvar Private$7;\n(function (Private) {\n    /**\n     * Create a normalized context menu item from an options object.\n     */\n    function createItem(options, id) {\n        var selector = validateSelector(options.selector);\n        var rank = options.rank !== undefined ? options.rank : Infinity;\n        return __assign(__assign({}, options), { selector: selector, rank: rank, id: id });\n    }\n    Private.createItem = createItem;\n    /**\n     * Find the items which match a context menu event.\n     *\n     * The results are sorted by DOM level, specificity, and rank.\n     */\n    function matchItems(items, event) {\n        // Look up the target of the event.\n        var target = event.target;\n        // Bail if there is no target.\n        if (!target) {\n            return null;\n        }\n        // Look up the current target of the event.\n        var currentTarget = event.currentTarget;\n        // Bail if there is no current target.\n        if (!currentTarget) {\n            return null;\n        }\n        // There are some third party libraries that cause the `target` to\n        // be detached from the DOM before lumino can process the event.\n        // If that happens, search for a new target node by point. If that\n        // node is still dangling, bail.\n        if (!currentTarget.contains(target)) {\n            target = document.elementFromPoint(event.clientX, event.clientY);\n            if (!target || !currentTarget.contains(target)) {\n                return null;\n            }\n        }\n        // Set up the result array.\n        var result = [];\n        // Copy the items array to allow in-place modification.\n        var availableItems = items.slice();\n        // Walk up the DOM hierarchy searching for matches.\n        while (target !== null) {\n            // Set up the match array for this DOM level.\n            var matches = [];\n            // Search the remaining items for matches.\n            for (var i = 0, n = availableItems.length; i < n; ++i) {\n                // Fetch the item.\n                var item = availableItems[i];\n                // Skip items which are already consumed.\n                if (!item) {\n                    continue;\n                }\n                // Skip items which do not match the element.\n                if (!Selector.matches(target, item.selector)) {\n                    continue;\n                }\n                // Add the matched item to the result for this DOM level.\n                matches.push(item);\n                // Mark the item as consumed.\n                availableItems[i] = null;\n            }\n            // Sort the matches for this level and add them to the results.\n            if (matches.length !== 0) {\n                matches.sort(itemCmp);\n                result.push.apply(result, matches);\n            }\n            // Stop searching at the limits of the DOM range.\n            if (target === currentTarget) {\n                break;\n            }\n            // Step to the parent DOM level.\n            target = target.parentElement;\n        }\n        // Return the matched and sorted results.\n        return result;\n    }\n    Private.matchItems = matchItems;\n    /**\n     * Validate the selector for a menu item.\n     *\n     * This returns the validated selector, or throws if the selector is\n     * invalid or contains commas.\n     */\n    function validateSelector(selector) {\n        if (selector.indexOf(',') !== -1) {\n            throw new Error(\"Selector cannot contain commas: \" + selector);\n        }\n        if (!Selector.isValid(selector)) {\n            throw new Error(\"Invalid selector: \" + selector);\n        }\n        return selector;\n    }\n    /**\n     * A sort comparison function for a context menu item.\n     */\n    function itemCmp(a, b) {\n        // Sort first based on selector specificity.\n        var s1 = Selector.calculateSpecificity(a.selector);\n        var s2 = Selector.calculateSpecificity(b.selector);\n        if (s1 !== s2) {\n            return s2 - s1;\n        }\n        // If specificities are equal, sort based on rank.\n        var r1 = a.rank;\n        var r2 = b.rank;\n        if (r1 !== r2) {\n            return r1 < r2 ? -1 : 1; // Infinity-safe\n        }\n        // When all else fails, sort by item id.\n        return a.id - b.id;\n    }\n})(Private$7 || (Private$7 = {}));\n\n/**\n * A layout which provides a flexible docking arrangement.\n *\n * #### Notes\n * The consumer of this layout is responsible for handling all signals\n * from the generated tab bars and managing the visibility of widgets\n * and tab bars as needed.\n */\nvar DockLayout = /** @class */ (function (_super) {\n    __extends(DockLayout, _super);\n    /**\n     * Construct a new dock layout.\n     *\n     * @param options - The options for initializing the layout.\n     */\n    function DockLayout(options) {\n        var _this = _super.call(this) || this;\n        _this._spacing = 4;\n        _this._dirty = false;\n        _this._root = null;\n        _this._box = null;\n        _this._items = new Map();\n        _this.renderer = options.renderer;\n        if (options.spacing !== undefined) {\n            _this._spacing = Private$8.clampSpacing(options.spacing);\n        }\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the layout.\n     *\n     * #### Notes\n     * This will clear and dispose all widgets in the layout.\n     */\n    DockLayout.prototype.dispose = function () {\n        // Get an iterator over the widgets in the layout.\n        var widgets = this.iter();\n        // Dispose of the layout items.\n        this._items.forEach(function (item) { item.dispose(); });\n        // Clear the layout state before disposing the widgets.\n        this._box = null;\n        this._root = null;\n        this._items.clear();\n        // Dispose of the widgets contained in the old layout root.\n        each(widgets, function (widget) { widget.dispose(); });\n        // Dispose of the base class.\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(DockLayout.prototype, \"spacing\", {\n        /**\n         * Get the inter-element spacing for the dock layout.\n         */\n        get: function () {\n            return this._spacing;\n        },\n        /**\n         * Set the inter-element spacing for the dock layout.\n         */\n        set: function (value) {\n            value = Private$8.clampSpacing(value);\n            if (this._spacing === value) {\n                return;\n            }\n            this._spacing = value;\n            if (!this.parent) {\n                return;\n            }\n            this.parent.fit();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(DockLayout.prototype, \"isEmpty\", {\n        /**\n         * Whether the dock layout is empty.\n         */\n        get: function () {\n            return this._root === null;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Create an iterator over all widgets in the layout.\n     *\n     * @returns A new iterator over the widgets in the layout.\n     *\n     * #### Notes\n     * This iterator includes the generated tab bars.\n     */\n    DockLayout.prototype.iter = function () {\n        return this._root ? this._root.iterAllWidgets() : empty();\n    };\n    /**\n     * Create an iterator over the user widgets in the layout.\n     *\n     * @returns A new iterator over the user widgets in the layout.\n     *\n     * #### Notes\n     * This iterator does not include the generated tab bars.\n     */\n    DockLayout.prototype.widgets = function () {\n        return this._root ? this._root.iterUserWidgets() : empty();\n    };\n    /**\n     * Create an iterator over the selected widgets in the layout.\n     *\n     * @returns A new iterator over the selected user widgets.\n     *\n     * #### Notes\n     * This iterator yields the widgets corresponding to the current tab\n     * of each tab bar in the layout.\n     */\n    DockLayout.prototype.selectedWidgets = function () {\n        return this._root ? this._root.iterSelectedWidgets() : empty();\n    };\n    /**\n     * Create an iterator over the tab bars in the layout.\n     *\n     * @returns A new iterator over the tab bars in the layout.\n     *\n     * #### Notes\n     * This iterator does not include the user widgets.\n     */\n    DockLayout.prototype.tabBars = function () {\n        return this._root ? this._root.iterTabBars() : empty();\n    };\n    /**\n     * Create an iterator over the handles in the layout.\n     *\n     * @returns A new iterator over the handles in the layout.\n     */\n    DockLayout.prototype.handles = function () {\n        return this._root ? this._root.iterHandles() : empty();\n    };\n    /**\n     * Move a handle to the given offset position.\n     *\n     * @param handle - The handle to move.\n     *\n     * @param offsetX - The desired offset X position of the handle.\n     *\n     * @param offsetY - The desired offset Y position of the handle.\n     *\n     * #### Notes\n     * If the given handle is not contained in the layout, this is no-op.\n     *\n     * The handle will be moved as close as possible to the desired\n     * position without violating any of the layout constraints.\n     *\n     * Only one of the coordinates is used depending on the orientation\n     * of the handle. This method accepts both coordinates to make it\n     * easy to invoke from a mouse move event without needing to know\n     * the handle orientation.\n     */\n    DockLayout.prototype.moveHandle = function (handle, offsetX, offsetY) {\n        // Bail early if there is no root or if the handle is hidden.\n        var hidden = handle.classList.contains('lm-mod-hidden');\n        /* <DEPRECATED> */\n        hidden = hidden || handle.classList.contains('p-mod-hidden');\n        /* </DEPRECATED> */\n        if (!this._root || hidden) {\n            return;\n        }\n        // Lookup the split node for the handle.\n        var data = this._root.findSplitNode(handle);\n        if (!data) {\n            return;\n        }\n        // Compute the desired delta movement for the handle.\n        var delta;\n        if (data.node.orientation === 'horizontal') {\n            delta = offsetX - handle.offsetLeft;\n        }\n        else {\n            delta = offsetY - handle.offsetTop;\n        }\n        // Bail if there is no handle movement.\n        if (delta === 0) {\n            return;\n        }\n        // Prevent sibling resizing unless needed.\n        data.node.holdSizes();\n        // Adjust the sizers to reflect the handle movement.\n        BoxEngine.adjust(data.node.sizers, data.index, delta);\n        // Update the layout of the widgets.\n        if (this.parent) {\n            this.parent.update();\n        }\n    };\n    /**\n     * Save the current configuration of the dock layout.\n     *\n     * @returns A new config object for the current layout state.\n     *\n     * #### Notes\n     * The return value can be provided to the `restoreLayout` method\n     * in order to restore the layout to its current configuration.\n     */\n    DockLayout.prototype.saveLayout = function () {\n        // Bail early if there is no root.\n        if (!this._root) {\n            return { main: null };\n        }\n        // Hold the current sizes in the layout tree.\n        this._root.holdAllSizes();\n        // Return the layout config.\n        return { main: this._root.createConfig() };\n    };\n    /**\n     * Restore the layout to a previously saved configuration.\n     *\n     * @param config - The layout configuration to restore.\n     *\n     * #### Notes\n     * Widgets which currently belong to the layout but which are not\n     * contained in the config will be unparented.\n     */\n    DockLayout.prototype.restoreLayout = function (config) {\n        var _this = this;\n        // Create the widget set for validating the config.\n        var widgetSet = new Set();\n        // Normalize the main area config and collect the widgets.\n        var mainConfig;\n        if (config.main) {\n            mainConfig = Private$8.normalizeAreaConfig(config.main, widgetSet);\n        }\n        else {\n            mainConfig = null;\n        }\n        // Create iterators over the old content.\n        var oldWidgets = this.widgets();\n        var oldTabBars = this.tabBars();\n        var oldHandles = this.handles();\n        // Clear the root before removing the old content.\n        this._root = null;\n        // Unparent the old widgets which are not in the new config.\n        each(oldWidgets, function (widget) {\n            if (!widgetSet.has(widget)) {\n                widget.parent = null;\n            }\n        });\n        // Dispose of the old tab bars.\n        each(oldTabBars, function (tabBar) {\n            tabBar.dispose();\n        });\n        // Remove the old handles.\n        each(oldHandles, function (handle) {\n            if (handle.parentNode) {\n                handle.parentNode.removeChild(handle);\n            }\n        });\n        // Reparent the new widgets to the current parent.\n        widgetSet.forEach(function (widget) {\n            widget.parent = _this.parent;\n        });\n        // Create the root node for the new config.\n        if (mainConfig) {\n            this._root = Private$8.realizeAreaConfig(mainConfig, {\n                createTabBar: function () { return _this._createTabBar(); },\n                createHandle: function () { return _this._createHandle(); }\n            });\n        }\n        else {\n            this._root = null;\n        }\n        // If there is no parent, there is nothing more to do.\n        if (!this.parent) {\n            return;\n        }\n        // Attach the new widgets to the parent.\n        widgetSet.forEach(function (widget) {\n            _this.attachWidget(widget);\n        });\n        // Post a fit request to the parent.\n        this.parent.fit();\n    };\n    /**\n     * Add a widget to the dock layout.\n     *\n     * @param widget - The widget to add to the dock layout.\n     *\n     * @param options - The additional options for adding the widget.\n     *\n     * #### Notes\n     * The widget will be moved if it is already contained in the layout.\n     *\n     * An error will be thrown if the reference widget is invalid.\n     */\n    DockLayout.prototype.addWidget = function (widget, options) {\n        if (options === void 0) { options = {}; }\n        // Parse the options.\n        var ref = options.ref || null;\n        var mode = options.mode || 'tab-after';\n        // Find the tab node which holds the reference widget.\n        var refNode = null;\n        if (this._root && ref) {\n            refNode = this._root.findTabNode(ref);\n        }\n        // Throw an error if the reference widget is invalid.\n        if (ref && !refNode) {\n            throw new Error('Reference widget is not in the layout.');\n        }\n        // Reparent the widget to the current layout parent.\n        widget.parent = this.parent;\n        // Insert the widget according to the insert mode.\n        switch (mode) {\n            case 'tab-after':\n                this._insertTab(widget, ref, refNode, true);\n                break;\n            case 'tab-before':\n                this._insertTab(widget, ref, refNode, false);\n                break;\n            case 'split-top':\n                this._insertSplit(widget, ref, refNode, 'vertical', false);\n                break;\n            case 'split-left':\n                this._insertSplit(widget, ref, refNode, 'horizontal', false);\n                break;\n            case 'split-right':\n                this._insertSplit(widget, ref, refNode, 'horizontal', true);\n                break;\n            case 'split-bottom':\n                this._insertSplit(widget, ref, refNode, 'vertical', true);\n                break;\n        }\n        // Do nothing else if there is no parent widget.\n        if (!this.parent) {\n            return;\n        }\n        // Ensure the widget is attached to the parent widget.\n        this.attachWidget(widget);\n        // Post a fit request for the parent widget.\n        this.parent.fit();\n    };\n    /**\n     * Remove a widget from the layout.\n     *\n     * @param widget - The widget to remove from the layout.\n     *\n     * #### Notes\n     * A widget is automatically removed from the layout when its `parent`\n     * is set to `null`. This method should only be invoked directly when\n     * removing a widget from a layout which has yet to be installed on a\n     * parent widget.\n     *\n     * This method does *not* modify the widget's `parent`.\n     */\n    DockLayout.prototype.removeWidget = function (widget) {\n        // Remove the widget from its current layout location.\n        this._removeWidget(widget);\n        // Do nothing else if there is no parent widget.\n        if (!this.parent) {\n            return;\n        }\n        // Detach the widget from the parent widget.\n        this.detachWidget(widget);\n        // Post a fit request for the parent widget.\n        this.parent.fit();\n    };\n    /**\n     * Find the tab area which contains the given client position.\n     *\n     * @param clientX - The client X position of interest.\n     *\n     * @param clientY - The client Y position of interest.\n     *\n     * @returns The geometry of the tab area at the given position, or\n     *   `null` if there is no tab area at the given position.\n     */\n    DockLayout.prototype.hitTestTabAreas = function (clientX, clientY) {\n        // Bail early if hit testing cannot produce valid results.\n        if (!this._root || !this.parent || !this.parent.isVisible) {\n            return null;\n        }\n        // Ensure the parent box sizing data is computed.\n        if (!this._box) {\n            this._box = ElementExt.boxSizing(this.parent.node);\n        }\n        // Convert from client to local coordinates.\n        var rect = this.parent.node.getBoundingClientRect();\n        var x = clientX - rect.left - this._box.borderLeft;\n        var y = clientY - rect.top - this._box.borderTop;\n        // Find the tab layout node at the local position.\n        var tabNode = this._root.hitTestTabNodes(x, y);\n        // Bail if a tab layout node was not found.\n        if (!tabNode) {\n            return null;\n        }\n        // Extract the data from the tab node.\n        var tabBar = tabNode.tabBar, top = tabNode.top, left = tabNode.left, width = tabNode.width, height = tabNode.height;\n        // Compute the right and bottom edges of the tab area.\n        var borderWidth = this._box.borderLeft + this._box.borderRight;\n        var borderHeight = this._box.borderTop + this._box.borderBottom;\n        var right = rect.width - borderWidth - (left + width);\n        var bottom = rect.height - borderHeight - (top + height);\n        // Return the hit test results.\n        return { tabBar: tabBar, x: x, y: y, top: top, left: left, right: right, bottom: bottom, width: width, height: height };\n    };\n    /**\n     * Perform layout initialization which requires the parent widget.\n     */\n    DockLayout.prototype.init = function () {\n        var _this = this;\n        // Perform superclass initialization.\n        _super.prototype.init.call(this);\n        // Attach each widget to the parent.\n        each(this, function (widget) { _this.attachWidget(widget); });\n        // Attach each handle to the parent.\n        each(this.handles(), function (handle) { _this.parent.node.appendChild(handle); });\n        // Post a fit request for the parent widget.\n        this.parent.fit();\n    };\n    /**\n     * Attach the widget to the layout parent widget.\n     *\n     * @param widget - The widget to attach to the parent.\n     *\n     * #### Notes\n     * This is a no-op if the widget is already attached.\n     */\n    DockLayout.prototype.attachWidget = function (widget) {\n        // Do nothing if the widget is already attached.\n        if (this.parent.node === widget.node.parentNode) {\n            return;\n        }\n        // Create the layout item for the widget.\n        this._items.set(widget, new LayoutItem(widget));\n        // Send a `'before-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeAttach);\n        }\n        // Add the widget's node to the parent.\n        this.parent.node.appendChild(widget.node);\n        // Send an `'after-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterAttach);\n        }\n    };\n    /**\n     * Detach the widget from the layout parent widget.\n     *\n     * @param widget - The widget to detach from the parent.\n     *\n     * #### Notes\n     * This is a no-op if the widget is not attached.\n     */\n    DockLayout.prototype.detachWidget = function (widget) {\n        // Do nothing if the widget is not attached.\n        if (this.parent.node !== widget.node.parentNode) {\n            return;\n        }\n        // Send a `'before-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeDetach);\n        }\n        // Remove the widget's node from the parent.\n        this.parent.node.removeChild(widget.node);\n        // Send an `'after-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterDetach);\n        }\n        // Delete the layout item for the widget.\n        var item = this._items.get(widget);\n        if (item) {\n            this._items.delete(widget);\n            item.dispose();\n        }\n    };\n    /**\n     * A message handler invoked on a `'before-show'` message.\n     */\n    DockLayout.prototype.onBeforeShow = function (msg) {\n        _super.prototype.onBeforeShow.call(this, msg);\n        this.parent.update();\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     */\n    DockLayout.prototype.onBeforeAttach = function (msg) {\n        _super.prototype.onBeforeAttach.call(this, msg);\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'child-shown'` message.\n     */\n    DockLayout.prototype.onChildShown = function (msg) {\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'child-hidden'` message.\n     */\n    DockLayout.prototype.onChildHidden = function (msg) {\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'resize'` message.\n     */\n    DockLayout.prototype.onResize = function (msg) {\n        if (this.parent.isVisible) {\n            this._update(msg.width, msg.height);\n        }\n    };\n    /**\n     * A message handler invoked on an `'update-request'` message.\n     */\n    DockLayout.prototype.onUpdateRequest = function (msg) {\n        if (this.parent.isVisible) {\n            this._update(-1, -1);\n        }\n    };\n    /**\n     * A message handler invoked on a `'fit-request'` message.\n     */\n    DockLayout.prototype.onFitRequest = function (msg) {\n        if (this.parent.isAttached) {\n            this._fit();\n        }\n    };\n    /**\n     * Remove the specified widget from the layout structure.\n     *\n     * #### Notes\n     * This is a no-op if the widget is not in the layout tree.\n     *\n     * This does not detach the widget from the parent node.\n     */\n    DockLayout.prototype._removeWidget = function (widget) {\n        // Bail early if there is no layout root.\n        if (!this._root) {\n            return;\n        }\n        // Find the tab node which contains the given widget.\n        var tabNode = this._root.findTabNode(widget);\n        // Bail early if the tab node is not found.\n        if (!tabNode) {\n            return;\n        }\n        // If there are multiple tabs, just remove the widget's tab.\n        if (tabNode.tabBar.titles.length > 1) {\n            tabNode.tabBar.removeTab(widget.title);\n            return;\n        }\n        // Otherwise, the tab node needs to be removed...\n        // Dispose the tab bar.\n        tabNode.tabBar.dispose();\n        // Handle the case where the tab node is the root.\n        if (this._root === tabNode) {\n            this._root = null;\n            return;\n        }\n        // Otherwise, remove the tab node from its parent...\n        // Prevent widget resizing unless needed.\n        this._root.holdAllSizes();\n        // Clear the parent reference on the tab node.\n        var splitNode = tabNode.parent;\n        tabNode.parent = null;\n        // Remove the tab node from its parent split node.\n        var i = ArrayExt.removeFirstOf(splitNode.children, tabNode);\n        var handle = ArrayExt.removeAt(splitNode.handles, i);\n        ArrayExt.removeAt(splitNode.sizers, i);\n        // Remove the handle from its parent DOM node.\n        if (handle.parentNode) {\n            handle.parentNode.removeChild(handle);\n        }\n        // If there are multiple children, just update the handles.\n        if (splitNode.children.length > 1) {\n            splitNode.syncHandles();\n            return;\n        }\n        // Otherwise, the split node also needs to be removed...\n        // Clear the parent reference on the split node.\n        var maybeParent = splitNode.parent;\n        splitNode.parent = null;\n        // Lookup the remaining child node and handle.\n        var childNode = splitNode.children[0];\n        var childHandle = splitNode.handles[0];\n        // Clear the split node data.\n        splitNode.children.length = 0;\n        splitNode.handles.length = 0;\n        splitNode.sizers.length = 0;\n        // Remove the child handle from its parent node.\n        if (childHandle.parentNode) {\n            childHandle.parentNode.removeChild(childHandle);\n        }\n        // Handle the case where the split node is the root.\n        if (this._root === splitNode) {\n            childNode.parent = null;\n            this._root = childNode;\n            return;\n        }\n        // Otherwise, move the child node to the parent node...\n        var parentNode = maybeParent;\n        // Lookup the index of the split node.\n        var j = parentNode.children.indexOf(splitNode);\n        // Handle the case where the child node is a tab node.\n        if (childNode instanceof Private$8.TabLayoutNode) {\n            childNode.parent = parentNode;\n            parentNode.children[j] = childNode;\n            return;\n        }\n        // Remove the split data from the parent.\n        var splitHandle = ArrayExt.removeAt(parentNode.handles, j);\n        ArrayExt.removeAt(parentNode.children, j);\n        ArrayExt.removeAt(parentNode.sizers, j);\n        // Remove the handle from its parent node.\n        if (splitHandle.parentNode) {\n            splitHandle.parentNode.removeChild(splitHandle);\n        }\n        // The child node and the split parent node will have the same\n        // orientation. Merge the grand-children with the parent node.\n        for (var i_1 = 0, n = childNode.children.length; i_1 < n; ++i_1) {\n            var gChild = childNode.children[i_1];\n            var gHandle = childNode.handles[i_1];\n            var gSizer = childNode.sizers[i_1];\n            ArrayExt.insert(parentNode.children, j + i_1, gChild);\n            ArrayExt.insert(parentNode.handles, j + i_1, gHandle);\n            ArrayExt.insert(parentNode.sizers, j + i_1, gSizer);\n            gChild.parent = parentNode;\n        }\n        // Clear the child node.\n        childNode.children.length = 0;\n        childNode.handles.length = 0;\n        childNode.sizers.length = 0;\n        childNode.parent = null;\n        // Sync the handles on the parent node.\n        parentNode.syncHandles();\n    };\n    /**\n     * Insert a widget next to an existing tab.\n     *\n     * #### Notes\n     * This does not attach the widget to the parent widget.\n     */\n    DockLayout.prototype._insertTab = function (widget, ref, refNode, after) {\n        // Do nothing if the tab is inserted next to itself.\n        if (widget === ref) {\n            return;\n        }\n        // Create the root if it does not exist.\n        if (!this._root) {\n            var tabNode = new Private$8.TabLayoutNode(this._createTabBar());\n            tabNode.tabBar.addTab(widget.title);\n            this._root = tabNode;\n            return;\n        }\n        // Use the first tab node as the ref node if needed.\n        if (!refNode) {\n            refNode = this._root.findFirstTabNode();\n        }\n        // If the widget is not contained in the ref node, ensure it is\n        // removed from the layout and hidden before being added again.\n        if (refNode.tabBar.titles.indexOf(widget.title) === -1) {\n            this._removeWidget(widget);\n            widget.hide();\n        }\n        // Lookup the target index for inserting the tab.\n        var index;\n        if (ref) {\n            index = refNode.tabBar.titles.indexOf(ref.title);\n        }\n        else {\n            index = refNode.tabBar.currentIndex;\n        }\n        // Insert the widget's tab relative to the target index.\n        refNode.tabBar.insertTab(index + (after ? 1 : 0), widget.title);\n    };\n    /**\n     * Insert a widget as a new split area.\n     *\n     * #### Notes\n     * This does not attach the widget to the parent widget.\n     */\n    DockLayout.prototype._insertSplit = function (widget, ref, refNode, orientation, after) {\n        // Do nothing if there is no effective split.\n        if (widget === ref && refNode && refNode.tabBar.titles.length === 1) {\n            return;\n        }\n        // Ensure the widget is removed from the current layout.\n        this._removeWidget(widget);\n        // Create the tab layout node to hold the widget.\n        var tabNode = new Private$8.TabLayoutNode(this._createTabBar());\n        tabNode.tabBar.addTab(widget.title);\n        // Set the root if it does not exist.\n        if (!this._root) {\n            this._root = tabNode;\n            return;\n        }\n        // If the ref node parent is null, split the root.\n        if (!refNode || !refNode.parent) {\n            // Ensure the root is split with the correct orientation.\n            var root = this._splitRoot(orientation);\n            // Determine the insert index for the new tab node.\n            var i_2 = after ? root.children.length : 0;\n            // Normalize the split node.\n            root.normalizeSizes();\n            // Create the sizer for new tab node.\n            var sizer = Private$8.createSizer(refNode ? 1 : Private$8.GOLDEN_RATIO);\n            // Insert the tab node sized to the golden ratio.\n            ArrayExt.insert(root.children, i_2, tabNode);\n            ArrayExt.insert(root.sizers, i_2, sizer);\n            ArrayExt.insert(root.handles, i_2, this._createHandle());\n            tabNode.parent = root;\n            // Re-normalize the split node to maintain the ratios.\n            root.normalizeSizes();\n            // Finally, synchronize the visibility of the handles.\n            root.syncHandles();\n            return;\n        }\n        // Lookup the split node for the ref widget.\n        var splitNode = refNode.parent;\n        // If the split node already had the correct orientation,\n        // the widget can be inserted into the split node directly.\n        if (splitNode.orientation === orientation) {\n            // Find the index of the ref node.\n            var i_3 = splitNode.children.indexOf(refNode);\n            // Normalize the split node.\n            splitNode.normalizeSizes();\n            // Consume half the space for the insert location.\n            var s = splitNode.sizers[i_3].sizeHint /= 2;\n            // Insert the tab node sized to the other half.\n            var j_1 = i_3 + (after ? 1 : 0);\n            ArrayExt.insert(splitNode.children, j_1, tabNode);\n            ArrayExt.insert(splitNode.sizers, j_1, Private$8.createSizer(s));\n            ArrayExt.insert(splitNode.handles, j_1, this._createHandle());\n            tabNode.parent = splitNode;\n            // Finally, synchronize the visibility of the handles.\n            splitNode.syncHandles();\n            return;\n        }\n        // Remove the ref node from the split node.\n        var i = ArrayExt.removeFirstOf(splitNode.children, refNode);\n        // Create a new normalized split node for the children.\n        var childNode = new Private$8.SplitLayoutNode(orientation);\n        childNode.normalized = true;\n        // Add the ref node sized to half the space.\n        childNode.children.push(refNode);\n        childNode.sizers.push(Private$8.createSizer(0.5));\n        childNode.handles.push(this._createHandle());\n        refNode.parent = childNode;\n        // Add the tab node sized to the other half.\n        var j = after ? 1 : 0;\n        ArrayExt.insert(childNode.children, j, tabNode);\n        ArrayExt.insert(childNode.sizers, j, Private$8.createSizer(0.5));\n        ArrayExt.insert(childNode.handles, j, this._createHandle());\n        tabNode.parent = childNode;\n        // Synchronize the visibility of the handles.\n        childNode.syncHandles();\n        // Finally, add the new child node to the original split node.\n        ArrayExt.insert(splitNode.children, i, childNode);\n        childNode.parent = splitNode;\n    };\n    /**\n     * Ensure the root is a split node with the given orientation.\n     */\n    DockLayout.prototype._splitRoot = function (orientation) {\n        // Bail early if the root already meets the requirements.\n        var oldRoot = this._root;\n        if (oldRoot instanceof Private$8.SplitLayoutNode) {\n            if (oldRoot.orientation === orientation) {\n                return oldRoot;\n            }\n        }\n        // Create a new root node with the specified orientation.\n        var newRoot = this._root = new Private$8.SplitLayoutNode(orientation);\n        // Add the old root to the new root.\n        if (oldRoot) {\n            newRoot.children.push(oldRoot);\n            newRoot.sizers.push(Private$8.createSizer(0));\n            newRoot.handles.push(this._createHandle());\n            oldRoot.parent = newRoot;\n        }\n        // Return the new root as a convenience.\n        return newRoot;\n    };\n    /**\n     * Fit the layout to the total size required by the widgets.\n     */\n    DockLayout.prototype._fit = function () {\n        // Set up the computed minimum size.\n        var minW = 0;\n        var minH = 0;\n        // Update the size limits for the layout tree.\n        if (this._root) {\n            var limits = this._root.fit(this._spacing, this._items);\n            minW = limits.minWidth;\n            minH = limits.minHeight;\n        }\n        // Update the box sizing and add it to the computed min size.\n        var box = this._box = ElementExt.boxSizing(this.parent.node);\n        minW += box.horizontalSum;\n        minH += box.verticalSum;\n        // Update the parent's min size constraints.\n        var style = this.parent.node.style;\n        style.minWidth = minW + \"px\";\n        style.minHeight = minH + \"px\";\n        // Set the dirty flag to ensure only a single update occurs.\n        this._dirty = true;\n        // Notify the ancestor that it should fit immediately. This may\n        // cause a resize of the parent, fulfilling the required update.\n        if (this.parent.parent) {\n            MessageLoop.sendMessage(this.parent.parent, Widget.Msg.FitRequest);\n        }\n        // If the dirty flag is still set, the parent was not resized.\n        // Trigger the required update on the parent widget immediately.\n        if (this._dirty) {\n            MessageLoop.sendMessage(this.parent, Widget.Msg.UpdateRequest);\n        }\n    };\n    /**\n     * Update the layout position and size of the widgets.\n     *\n     * The parent offset dimensions should be `-1` if unknown.\n     */\n    DockLayout.prototype._update = function (offsetWidth, offsetHeight) {\n        // Clear the dirty flag to indicate the update occurred.\n        this._dirty = false;\n        // Bail early if there is no root layout node.\n        if (!this._root) {\n            return;\n        }\n        // Measure the parent if the offset dimensions are unknown.\n        if (offsetWidth < 0) {\n            offsetWidth = this.parent.node.offsetWidth;\n        }\n        if (offsetHeight < 0) {\n            offsetHeight = this.parent.node.offsetHeight;\n        }\n        // Ensure the parent box sizing data is computed.\n        if (!this._box) {\n            this._box = ElementExt.boxSizing(this.parent.node);\n        }\n        // Compute the actual layout bounds adjusted for border and padding.\n        var x = this._box.paddingTop;\n        var y = this._box.paddingLeft;\n        var width = offsetWidth - this._box.horizontalSum;\n        var height = offsetHeight - this._box.verticalSum;\n        // Update the geometry of the layout tree.\n        this._root.update(x, y, width, height, this._spacing, this._items);\n    };\n    /**\n     * Create a new tab bar for use by the dock layout.\n     *\n     * #### Notes\n     * The tab bar will be attached to the parent if it exists.\n     */\n    DockLayout.prototype._createTabBar = function () {\n        // Create the tab bar using the renderer.\n        var tabBar = this.renderer.createTabBar();\n        // Enforce necessary tab bar behavior.\n        tabBar.orientation = 'horizontal';\n        // Reparent and attach the tab bar to the parent if possible.\n        if (this.parent) {\n            tabBar.parent = this.parent;\n            this.attachWidget(tabBar);\n        }\n        // Return the initialized tab bar.\n        return tabBar;\n    };\n    /**\n     * Create a new handle for the dock layout.\n     *\n     * #### Notes\n     * The handle will be attached to the parent if it exists.\n     */\n    DockLayout.prototype._createHandle = function () {\n        // Create the handle using the renderer.\n        var handle = this.renderer.createHandle();\n        // Initialize the handle layout behavior.\n        var style = handle.style;\n        style.position = 'absolute';\n        style.top = '0';\n        style.left = '0';\n        style.width = '0';\n        style.height = '0';\n        // Attach the handle to the parent if it exists.\n        if (this.parent) {\n            this.parent.node.appendChild(handle);\n        }\n        // Return the initialized handle.\n        return handle;\n    };\n    return DockLayout;\n}(Layout));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$8;\n(function (Private) {\n    /**\n     * A fraction used for sizing root panels; ~= `1 / golden_ratio`.\n     */\n    Private.GOLDEN_RATIO = 0.618;\n    /**\n     * Clamp a spacing value to an integer >= 0.\n     */\n    function clampSpacing(value) {\n        return Math.max(0, Math.floor(value));\n    }\n    Private.clampSpacing = clampSpacing;\n    /**\n     * Create a box sizer with an initial size hint.\n     */\n    function createSizer(hint) {\n        var sizer = new BoxSizer();\n        sizer.sizeHint = hint;\n        sizer.size = hint;\n        return sizer;\n    }\n    Private.createSizer = createSizer;\n    /**\n     * Normalize an area config object and collect the visited widgets.\n     */\n    function normalizeAreaConfig(config, widgetSet) {\n        var result;\n        if (config.type === 'tab-area') {\n            result = normalizeTabAreaConfig(config, widgetSet);\n        }\n        else {\n            result = normalizeSplitAreaConfig(config, widgetSet);\n        }\n        return result;\n    }\n    Private.normalizeAreaConfig = normalizeAreaConfig;\n    /**\n     * Convert a normalized area config into a layout tree.\n     */\n    function realizeAreaConfig(config, renderer) {\n        var node;\n        if (config.type === 'tab-area') {\n            node = realizeTabAreaConfig(config, renderer);\n        }\n        else {\n            node = realizeSplitAreaConfig(config, renderer);\n        }\n        return node;\n    }\n    Private.realizeAreaConfig = realizeAreaConfig;\n    /**\n     * A layout node which holds the data for a tabbed area.\n     */\n    var TabLayoutNode = /** @class */ (function () {\n        /**\n         * Construct a new tab layout node.\n         *\n         * @param tabBar - The tab bar to use for the layout node.\n         */\n        function TabLayoutNode(tabBar) {\n            /**\n             * The parent of the layout node.\n             */\n            this.parent = null;\n            this._top = 0;\n            this._left = 0;\n            this._width = 0;\n            this._height = 0;\n            var tabSizer = new BoxSizer();\n            var widgetSizer = new BoxSizer();\n            tabSizer.stretch = 0;\n            widgetSizer.stretch = 1;\n            this.tabBar = tabBar;\n            this.sizers = [tabSizer, widgetSizer];\n        }\n        Object.defineProperty(TabLayoutNode.prototype, \"top\", {\n            /**\n             * The most recent value for the `top` edge of the layout box.\n             */\n            get: function () {\n                return this._top;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(TabLayoutNode.prototype, \"left\", {\n            /**\n             * The most recent value for the `left` edge of the layout box.\n             */\n            get: function () {\n                return this._left;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(TabLayoutNode.prototype, \"width\", {\n            /**\n             * The most recent value for the `width` of the layout box.\n             */\n            get: function () {\n                return this._width;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(TabLayoutNode.prototype, \"height\", {\n            /**\n             * The most recent value for the `height` of the layout box.\n             */\n            get: function () {\n                return this._height;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        /**\n         * Create an iterator for all widgets in the layout tree.\n         */\n        TabLayoutNode.prototype.iterAllWidgets = function () {\n            return chain(once(this.tabBar), this.iterUserWidgets());\n        };\n        /**\n         * Create an iterator for the user widgets in the layout tree.\n         */\n        TabLayoutNode.prototype.iterUserWidgets = function () {\n            return map(this.tabBar.titles, function (title) { return title.owner; });\n        };\n        /**\n         * Create an iterator for the selected widgets in the layout tree.\n         */\n        TabLayoutNode.prototype.iterSelectedWidgets = function () {\n            var title = this.tabBar.currentTitle;\n            return title ? once(title.owner) : empty();\n        };\n        /**\n         * Create an iterator for the tab bars in the layout tree.\n         */\n        TabLayoutNode.prototype.iterTabBars = function () {\n            return once(this.tabBar);\n        };\n        /**\n         * Create an iterator for the handles in the layout tree.\n         */\n        TabLayoutNode.prototype.iterHandles = function () {\n            return empty();\n        };\n        /**\n         * Find the tab layout node which contains the given widget.\n         */\n        TabLayoutNode.prototype.findTabNode = function (widget) {\n            return this.tabBar.titles.indexOf(widget.title) !== -1 ? this : null;\n        };\n        /**\n         * Find the split layout node which contains the given handle.\n         */\n        TabLayoutNode.prototype.findSplitNode = function (handle) {\n            return null;\n        };\n        /**\n         * Find the first tab layout node in a layout tree.\n         */\n        TabLayoutNode.prototype.findFirstTabNode = function () {\n            return this;\n        };\n        /**\n         * Find the tab layout node which contains the local point.\n         */\n        TabLayoutNode.prototype.hitTestTabNodes = function (x, y) {\n            if (x < this._left || x >= this._left + this._width) {\n                return null;\n            }\n            if (y < this._top || y >= this._top + this._height) {\n                return null;\n            }\n            return this;\n        };\n        /**\n         * Create a configuration object for the layout tree.\n         */\n        TabLayoutNode.prototype.createConfig = function () {\n            var widgets = this.tabBar.titles.map(function (title) { return title.owner; });\n            var currentIndex = this.tabBar.currentIndex;\n            return { type: 'tab-area', widgets: widgets, currentIndex: currentIndex };\n        };\n        /**\n         * Recursively hold all of the sizes in the layout tree.\n         *\n         * This ignores the sizers of tab layout nodes.\n         */\n        TabLayoutNode.prototype.holdAllSizes = function () {\n            return;\n        };\n        /**\n         * Fit the layout tree.\n         */\n        TabLayoutNode.prototype.fit = function (spacing, items) {\n            // Set up the limit variables.\n            var minWidth = 0;\n            var minHeight = 0;\n            var maxWidth = Infinity;\n            var maxHeight = Infinity;\n            // Lookup the tab bar layout item.\n            var tabBarItem = items.get(this.tabBar);\n            // Lookup the widget layout item.\n            var current = this.tabBar.currentTitle;\n            var widgetItem = current ? items.get(current.owner) : undefined;\n            // Lookup the tab bar and widget sizers.\n            var _a = this.sizers, tabBarSizer = _a[0], widgetSizer = _a[1];\n            // Update the tab bar limits.\n            if (tabBarItem) {\n                tabBarItem.fit();\n            }\n            // Update the widget limits.\n            if (widgetItem) {\n                widgetItem.fit();\n            }\n            // Update the results and sizer for the tab bar.\n            if (tabBarItem && !tabBarItem.isHidden) {\n                minWidth = Math.max(minWidth, tabBarItem.minWidth);\n                minHeight += tabBarItem.minHeight;\n                tabBarSizer.minSize = tabBarItem.minHeight;\n                tabBarSizer.maxSize = tabBarItem.maxHeight;\n            }\n            else {\n                tabBarSizer.minSize = 0;\n                tabBarSizer.maxSize = 0;\n            }\n            // Update the results and sizer for the current widget.\n            if (widgetItem && !widgetItem.isHidden) {\n                minWidth = Math.max(minWidth, widgetItem.minWidth);\n                minHeight += widgetItem.minHeight;\n                widgetSizer.minSize = widgetItem.minHeight;\n                widgetSizer.maxSize = Infinity;\n            }\n            else {\n                widgetSizer.minSize = 0;\n                widgetSizer.maxSize = Infinity;\n            }\n            // Return the computed size limits for the layout node.\n            return { minWidth: minWidth, minHeight: minHeight, maxWidth: maxWidth, maxHeight: maxHeight };\n        };\n        /**\n         * Update the layout tree.\n         */\n        TabLayoutNode.prototype.update = function (left, top, width, height, spacing, items) {\n            // Update the layout box values.\n            this._top = top;\n            this._left = left;\n            this._width = width;\n            this._height = height;\n            // Lookup the tab bar layout item.\n            var tabBarItem = items.get(this.tabBar);\n            // Lookup the widget layout item.\n            var current = this.tabBar.currentTitle;\n            var widgetItem = current ? items.get(current.owner) : undefined;\n            // Distribute the layout space to the sizers.\n            BoxEngine.calc(this.sizers, height);\n            // Update the tab bar item using the computed size.\n            if (tabBarItem && !tabBarItem.isHidden) {\n                var size = this.sizers[0].size;\n                tabBarItem.update(left, top, width, size);\n                top += size;\n            }\n            // Layout the widget using the computed size.\n            if (widgetItem && !widgetItem.isHidden) {\n                var size = this.sizers[1].size;\n                widgetItem.update(left, top, width, size);\n            }\n        };\n        return TabLayoutNode;\n    }());\n    Private.TabLayoutNode = TabLayoutNode;\n    /**\n     * A layout node which holds the data for a split area.\n     */\n    var SplitLayoutNode = /** @class */ (function () {\n        /**\n         * Construct a new split layout node.\n         *\n         * @param orientation - The orientation of the node.\n         */\n        function SplitLayoutNode(orientation) {\n            /**\n             * The parent of the layout node.\n             */\n            this.parent = null;\n            /**\n             * Whether the sizers have been normalized.\n             */\n            this.normalized = false;\n            /**\n             * The child nodes for the split node.\n             */\n            this.children = [];\n            /**\n             * The box sizers for the layout children.\n             */\n            this.sizers = [];\n            /**\n             * The handles for the layout children.\n             */\n            this.handles = [];\n            this.orientation = orientation;\n        }\n        /**\n         * Create an iterator for all widgets in the layout tree.\n         */\n        SplitLayoutNode.prototype.iterAllWidgets = function () {\n            var children = map(this.children, function (child) { return child.iterAllWidgets(); });\n            return new ChainIterator(children);\n        };\n        /**\n         * Create an iterator for the user widgets in the layout tree.\n         */\n        SplitLayoutNode.prototype.iterUserWidgets = function () {\n            var children = map(this.children, function (child) { return child.iterUserWidgets(); });\n            return new ChainIterator(children);\n        };\n        /**\n         * Create an iterator for the selected widgets in the layout tree.\n         */\n        SplitLayoutNode.prototype.iterSelectedWidgets = function () {\n            var children = map(this.children, function (child) { return child.iterSelectedWidgets(); });\n            return new ChainIterator(children);\n        };\n        /**\n         * Create an iterator for the tab bars in the layout tree.\n         */\n        SplitLayoutNode.prototype.iterTabBars = function () {\n            var children = map(this.children, function (child) { return child.iterTabBars(); });\n            return new ChainIterator(children);\n        };\n        /**\n         * Create an iterator for the handles in the layout tree.\n         */\n        SplitLayoutNode.prototype.iterHandles = function () {\n            var children = map(this.children, function (child) { return child.iterHandles(); });\n            return chain(this.handles, new ChainIterator(children));\n        };\n        /**\n         * Find the tab layout node which contains the given widget.\n         */\n        SplitLayoutNode.prototype.findTabNode = function (widget) {\n            for (var i = 0, n = this.children.length; i < n; ++i) {\n                var result = this.children[i].findTabNode(widget);\n                if (result) {\n                    return result;\n                }\n            }\n            return null;\n        };\n        /**\n         * Find the split layout node which contains the given handle.\n         */\n        SplitLayoutNode.prototype.findSplitNode = function (handle) {\n            var index = this.handles.indexOf(handle);\n            if (index !== -1) {\n                return { index: index, node: this };\n            }\n            for (var i = 0, n = this.children.length; i < n; ++i) {\n                var result = this.children[i].findSplitNode(handle);\n                if (result) {\n                    return result;\n                }\n            }\n            return null;\n        };\n        /**\n         * Find the first tab layout node in a layout tree.\n         */\n        SplitLayoutNode.prototype.findFirstTabNode = function () {\n            if (this.children.length === 0) {\n                return null;\n            }\n            return this.children[0].findFirstTabNode();\n        };\n        /**\n         * Find the tab layout node which contains the local point.\n         */\n        SplitLayoutNode.prototype.hitTestTabNodes = function (x, y) {\n            for (var i = 0, n = this.children.length; i < n; ++i) {\n                var result = this.children[i].hitTestTabNodes(x, y);\n                if (result) {\n                    return result;\n                }\n            }\n            return null;\n        };\n        /**\n         * Create a configuration object for the layout tree.\n         */\n        SplitLayoutNode.prototype.createConfig = function () {\n            var orientation = this.orientation;\n            var sizes = this.createNormalizedSizes();\n            var children = this.children.map(function (child) { return child.createConfig(); });\n            return { type: 'split-area', orientation: orientation, children: children, sizes: sizes };\n        };\n        /**\n         * Sync the visibility and orientation of the handles.\n         */\n        SplitLayoutNode.prototype.syncHandles = function () {\n            var _this = this;\n            each(this.handles, function (handle, i) {\n                handle.setAttribute('data-orientation', _this.orientation);\n                if (i === _this.handles.length - 1) {\n                    handle.classList.add('lm-mod-hidden');\n                    /* <DEPRECATED> */\n                    handle.classList.add('p-mod-hidden');\n                    /* </DEPRECATED> */\n                }\n                else {\n                    handle.classList.remove('lm-mod-hidden');\n                    /* <DEPRECATED> */\n                    handle.classList.remove('p-mod-hidden');\n                    /* </DEPRECATED> */\n                }\n            });\n        };\n        /**\n         * Hold the current sizes of the box sizers.\n         *\n         * This sets the size hint of each sizer to its current size.\n         */\n        SplitLayoutNode.prototype.holdSizes = function () {\n            each(this.sizers, function (sizer) { sizer.sizeHint = sizer.size; });\n        };\n        /**\n         * Recursively hold all of the sizes in the layout tree.\n         *\n         * This ignores the sizers of tab layout nodes.\n         */\n        SplitLayoutNode.prototype.holdAllSizes = function () {\n            each(this.children, function (child) { return child.holdAllSizes(); });\n            this.holdSizes();\n        };\n        /**\n         * Normalize the sizes of the split layout node.\n         */\n        SplitLayoutNode.prototype.normalizeSizes = function () {\n            // Bail early if the sizers are empty.\n            var n = this.sizers.length;\n            if (n === 0) {\n                return;\n            }\n            // Hold the current sizes of the sizers.\n            this.holdSizes();\n            // Compute the sum of the sizes.\n            var sum = reduce(this.sizers, function (v, sizer) { return v + sizer.sizeHint; }, 0);\n            // Normalize the sizes based on the sum.\n            if (sum === 0) {\n                each(this.sizers, function (sizer) {\n                    sizer.size = sizer.sizeHint = 1 / n;\n                });\n            }\n            else {\n                each(this.sizers, function (sizer) {\n                    sizer.size = sizer.sizeHint /= sum;\n                });\n            }\n            // Mark the sizes as normalized.\n            this.normalized = true;\n        };\n        /**\n         * Snap the normalized sizes of the split layout node.\n         */\n        SplitLayoutNode.prototype.createNormalizedSizes = function () {\n            // Bail early if the sizers are empty.\n            var n = this.sizers.length;\n            if (n === 0) {\n                return [];\n            }\n            // Grab the current sizes of the sizers.\n            var sizes = this.sizers.map(function (sizer) { return sizer.size; });\n            // Compute the sum of the sizes.\n            var sum = reduce(sizes, function (v, size) { return v + size; }, 0);\n            // Normalize the sizes based on the sum.\n            if (sum === 0) {\n                each(sizes, function (size, i) { sizes[i] = 1 / n; });\n            }\n            else {\n                each(sizes, function (size, i) { sizes[i] = size / sum; });\n            }\n            // Return the normalized sizes.\n            return sizes;\n        };\n        /**\n         * Fit the layout tree.\n         */\n        SplitLayoutNode.prototype.fit = function (spacing, items) {\n            // Compute the required fixed space.\n            var horizontal = this.orientation === 'horizontal';\n            var fixed = Math.max(0, this.children.length - 1) * spacing;\n            // Set up the limit variables.\n            var minWidth = horizontal ? fixed : 0;\n            var minHeight = horizontal ? 0 : fixed;\n            var maxWidth = Infinity;\n            var maxHeight = Infinity;\n            // Fit the children and update the limits.\n            for (var i = 0, n = this.children.length; i < n; ++i) {\n                var limits = this.children[i].fit(spacing, items);\n                if (horizontal) {\n                    minHeight = Math.max(minHeight, limits.minHeight);\n                    minWidth += limits.minWidth;\n                    this.sizers[i].minSize = limits.minWidth;\n                }\n                else {\n                    minWidth = Math.max(minWidth, limits.minWidth);\n                    minHeight += limits.minHeight;\n                    this.sizers[i].minSize = limits.minHeight;\n                }\n            }\n            // Return the computed limits for the layout node.\n            return { minWidth: minWidth, minHeight: minHeight, maxWidth: maxWidth, maxHeight: maxHeight };\n        };\n        /**\n         * Update the layout tree.\n         */\n        SplitLayoutNode.prototype.update = function (left, top, width, height, spacing, items) {\n            // Compute the available layout space.\n            var horizontal = this.orientation === 'horizontal';\n            var fixed = Math.max(0, this.children.length - 1) * spacing;\n            var space = Math.max(0, (horizontal ? width : height) - fixed);\n            // De-normalize the sizes if needed.\n            if (this.normalized) {\n                each(this.sizers, function (sizer) { sizer.sizeHint *= space; });\n                this.normalized = false;\n            }\n            // Distribute the layout space to the sizers.\n            BoxEngine.calc(this.sizers, space);\n            // Update the geometry of the child nodes and handles.\n            for (var i = 0, n = this.children.length; i < n; ++i) {\n                var child = this.children[i];\n                var size = this.sizers[i].size;\n                var handleStyle = this.handles[i].style;\n                if (horizontal) {\n                    child.update(left, top, size, height, spacing, items);\n                    left += size;\n                    handleStyle.top = top + \"px\";\n                    handleStyle.left = left + \"px\";\n                    handleStyle.width = spacing + \"px\";\n                    handleStyle.height = height + \"px\";\n                    left += spacing;\n                }\n                else {\n                    child.update(left, top, width, size, spacing, items);\n                    top += size;\n                    handleStyle.top = top + \"px\";\n                    handleStyle.left = left + \"px\";\n                    handleStyle.width = width + \"px\";\n                    handleStyle.height = spacing + \"px\";\n                    top += spacing;\n                }\n            }\n        };\n        return SplitLayoutNode;\n    }());\n    Private.SplitLayoutNode = SplitLayoutNode;\n    /**\n     * Normalize a tab area config and collect the visited widgets.\n     */\n    function normalizeTabAreaConfig(config, widgetSet) {\n        // Bail early if there is no content.\n        if (config.widgets.length === 0) {\n            return null;\n        }\n        // Setup the filtered widgets array.\n        var widgets = [];\n        // Filter the config for unique widgets.\n        each(config.widgets, function (widget) {\n            if (!widgetSet.has(widget)) {\n                widgetSet.add(widget);\n                widgets.push(widget);\n            }\n        });\n        // Bail if there are no effective widgets.\n        if (widgets.length === 0) {\n            return null;\n        }\n        // Normalize the current index.\n        var index = config.currentIndex;\n        if (index !== -1 && (index < 0 || index >= widgets.length)) {\n            index = 0;\n        }\n        // Return a normalized config object.\n        return { type: 'tab-area', widgets: widgets, currentIndex: index };\n    }\n    /**\n     * Normalize a split area config and collect the visited widgets.\n     */\n    function normalizeSplitAreaConfig(config, widgetSet) {\n        // Set up the result variables.\n        var orientation = config.orientation;\n        var children = [];\n        var sizes = [];\n        // Normalize the config children.\n        for (var i = 0, n = config.children.length; i < n; ++i) {\n            // Normalize the child config.\n            var child = normalizeAreaConfig(config.children[i], widgetSet);\n            // Ignore an empty child.\n            if (!child) {\n                continue;\n            }\n            // Add the child or hoist its content as appropriate.\n            if (child.type === 'tab-area' || child.orientation !== orientation) {\n                children.push(child);\n                sizes.push(Math.abs(config.sizes[i] || 0));\n            }\n            else {\n                children.push.apply(children, child.children);\n                sizes.push.apply(sizes, child.sizes);\n            }\n        }\n        // Bail if there are no effective children.\n        if (children.length === 0) {\n            return null;\n        }\n        // If there is only one effective child, return that child.\n        if (children.length === 1) {\n            return children[0];\n        }\n        // Return a normalized config object.\n        return { type: 'split-area', orientation: orientation, children: children, sizes: sizes };\n    }\n    /**\n     * Convert a normalized tab area config into a layout tree.\n     */\n    function realizeTabAreaConfig(config, renderer) {\n        // Create the tab bar for the layout node.\n        var tabBar = renderer.createTabBar();\n        // Hide each widget and add it to the tab bar.\n        each(config.widgets, function (widget) {\n            widget.hide();\n            tabBar.addTab(widget.title);\n        });\n        // Set the current index of the tab bar.\n        tabBar.currentIndex = config.currentIndex;\n        // Return the new tab layout node.\n        return new TabLayoutNode(tabBar);\n    }\n    /**\n     * Convert a normalized split area config into a layout tree.\n     */\n    function realizeSplitAreaConfig(config, renderer) {\n        // Create the split layout node.\n        var node = new SplitLayoutNode(config.orientation);\n        // Add each child to the layout node.\n        each(config.children, function (child, i) {\n            // Create the child data for the layout node.\n            var childNode = realizeAreaConfig(child, renderer);\n            var sizer = createSizer(config.sizes[i]);\n            var handle = renderer.createHandle();\n            // Add the child data to the layout node.\n            node.children.push(childNode);\n            node.handles.push(handle);\n            node.sizers.push(sizer);\n            // Update the parent for the child node.\n            childNode.parent = node;\n        });\n        // Synchronize the handle state for the layout node.\n        node.syncHandles();\n        // Normalize the sizes for the layout node.\n        node.normalizeSizes();\n        // Return the new layout node.\n        return node;\n    }\n})(Private$8 || (Private$8 = {}));\n\n/**\n * A widget which displays titles as a single row or column of tabs.\n *\n * #### Notes\n * If CSS transforms are used to rotate nodes for vertically oriented\n * text, then tab dragging will not work correctly. The `tabsMovable`\n * property should be set to `false` when rotating nodes from CSS.\n */\nvar TabBar = /** @class */ (function (_super) {\n    __extends(TabBar, _super);\n    /**\n     * Construct a new tab bar.\n     *\n     * @param options - The options for initializing the tab bar.\n     */\n    function TabBar(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this, { node: Private$9.createNode() }) || this;\n        _this._currentIndex = -1;\n        _this._titles = [];\n        _this._titlesEditable = false;\n        _this._previousTitle = null;\n        _this._dragData = null;\n        _this._tabMoved = new Signal(_this);\n        _this._currentChanged = new Signal(_this);\n        _this._tabCloseRequested = new Signal(_this);\n        _this._tabDetachRequested = new Signal(_this);\n        _this._tabActivateRequested = new Signal(_this);\n        _this.addClass('lm-TabBar');\n        /* <DEPRECATED> */\n        _this.addClass('p-TabBar');\n        /* </DEPRECATED> */\n        _this.setFlag(Widget.Flag.DisallowLayout);\n        _this.tabsMovable = options.tabsMovable || false;\n        _this.titlesEditable = options.titlesEditable || false;\n        _this.allowDeselect = options.allowDeselect || false;\n        _this.insertBehavior = options.insertBehavior || 'select-tab-if-needed';\n        _this.removeBehavior = options.removeBehavior || 'select-tab-after';\n        _this.renderer = options.renderer || TabBar.defaultRenderer;\n        _this._orientation = options.orientation || 'horizontal';\n        _this.dataset['orientation'] = _this._orientation;\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the widget.\n     */\n    TabBar.prototype.dispose = function () {\n        this._releaseMouse();\n        this._titles.length = 0;\n        this._previousTitle = null;\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(TabBar.prototype, \"currentChanged\", {\n        /**\n         * A signal emitted when the current tab is changed.\n         *\n         * #### Notes\n         * This signal is emitted when the currently selected tab is changed\n         * either through user or programmatic interaction.\n         *\n         * Notably, this signal is not emitted when the index of the current\n         * tab changes due to tabs being inserted, removed, or moved. It is\n         * only emitted when the actual current tab node is changed.\n         */\n        get: function () {\n            return this._currentChanged;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabBar.prototype, \"tabMoved\", {\n        /**\n         * A signal emitted when a tab is moved by the user.\n         *\n         * #### Notes\n         * This signal is emitted when a tab is moved by user interaction.\n         *\n         * This signal is not emitted when a tab is moved programmatically.\n         */\n        get: function () {\n            return this._tabMoved;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabBar.prototype, \"tabActivateRequested\", {\n        /**\n         * A signal emitted when a tab is clicked by the user.\n         *\n         * #### Notes\n         * If the clicked tab is not the current tab, the clicked tab will be\n         * made current and the `currentChanged` signal will be emitted first.\n         *\n         * This signal is emitted even if the clicked tab is the current tab.\n         */\n        get: function () {\n            return this._tabActivateRequested;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabBar.prototype, \"tabCloseRequested\", {\n        /**\n         * A signal emitted when a tab close icon is clicked.\n         *\n         * #### Notes\n         * This signal is not emitted unless the tab title is `closable`.\n         */\n        get: function () {\n            return this._tabCloseRequested;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabBar.prototype, \"tabDetachRequested\", {\n        /**\n         * A signal emitted when a tab is dragged beyond the detach threshold.\n         *\n         * #### Notes\n         * This signal is emitted when the user drags a tab with the mouse,\n         * and mouse is dragged beyond the detach threshold.\n         *\n         * The consumer of the signal should call `releaseMouse` and remove\n         * the tab in order to complete the detach.\n         *\n         * This signal is only emitted once per drag cycle.\n         */\n        get: function () {\n            return this._tabDetachRequested;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabBar.prototype, \"titlesEditable\", {\n        /**\n         * Whether the titles can be user-edited.\n         *\n         */\n        get: function () {\n            return this._titlesEditable;\n        },\n        /**\n         * Set whether titles can be user edited.\n         *\n         */\n        set: function (value) {\n            this._titlesEditable = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabBar.prototype, \"currentTitle\", {\n        /**\n         * Get the currently selected title.\n         *\n         * #### Notes\n         * This will be `null` if no tab is selected.\n         */\n        get: function () {\n            return this._titles[this._currentIndex] || null;\n        },\n        /**\n         * Set the currently selected title.\n         *\n         * #### Notes\n         * If the title does not exist, the title will be set to `null`.\n         */\n        set: function (value) {\n            this.currentIndex = value ? this._titles.indexOf(value) : -1;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabBar.prototype, \"currentIndex\", {\n        /**\n         * Get the index of the currently selected tab.\n         *\n         * #### Notes\n         * This will be `-1` if no tab is selected.\n         */\n        get: function () {\n            return this._currentIndex;\n        },\n        /**\n         * Set the index of the currently selected tab.\n         *\n         * #### Notes\n         * If the value is out of range, the index will be set to `-1`.\n         */\n        set: function (value) {\n            // Adjust for an out of range index.\n            if (value < 0 || value >= this._titles.length) {\n                value = -1;\n            }\n            // Bail early if the index will not change.\n            if (this._currentIndex === value) {\n                return;\n            }\n            // Look up the previous index and title.\n            var pi = this._currentIndex;\n            var pt = this._titles[pi] || null;\n            // Look up the current index and title.\n            var ci = value;\n            var ct = this._titles[ci] || null;\n            // Update the current index and previous title.\n            this._currentIndex = ci;\n            this._previousTitle = pt;\n            // Schedule an update of the tabs.\n            this.update();\n            // Emit the current changed signal.\n            this._currentChanged.emit({\n                previousIndex: pi, previousTitle: pt,\n                currentIndex: ci, currentTitle: ct\n            });\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabBar.prototype, \"orientation\", {\n        /**\n         * Get the orientation of the tab bar.\n         *\n         * #### Notes\n         * This controls whether the tabs are arranged in a row or column.\n         */\n        get: function () {\n            return this._orientation;\n        },\n        /**\n         * Set the orientation of the tab bar.\n         *\n         * #### Notes\n         * This controls whether the tabs are arranged in a row or column.\n         */\n        set: function (value) {\n            // Do nothing if the orientation does not change.\n            if (this._orientation === value) {\n                return;\n            }\n            // Release the mouse before making any changes.\n            this._releaseMouse();\n            // Toggle the orientation values.\n            this._orientation = value;\n            this.dataset['orientation'] = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabBar.prototype, \"titles\", {\n        /**\n         * A read-only array of the titles in the tab bar.\n         */\n        get: function () {\n            return this._titles;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabBar.prototype, \"contentNode\", {\n        /**\n         * The tab bar content node.\n         *\n         * #### Notes\n         * This is the node which holds the tab nodes.\n         *\n         * Modifying this node directly can lead to undefined behavior.\n         */\n        get: function () {\n            return this.node.getElementsByClassName('lm-TabBar-content')[0];\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Add a tab to the end of the tab bar.\n     *\n     * @param value - The title which holds the data for the tab,\n     *   or an options object to convert to a title.\n     *\n     * @returns The title object added to the tab bar.\n     *\n     * #### Notes\n     * If the title is already added to the tab bar, it will be moved.\n     */\n    TabBar.prototype.addTab = function (value) {\n        return this.insertTab(this._titles.length, value);\n    };\n    /**\n     * Insert a tab into the tab bar at the specified index.\n     *\n     * @param index - The index at which to insert the tab.\n     *\n     * @param value - The title which holds the data for the tab,\n     *   or an options object to convert to a title.\n     *\n     * @returns The title object added to the tab bar.\n     *\n     * #### Notes\n     * The index will be clamped to the bounds of the tabs.\n     *\n     * If the title is already added to the tab bar, it will be moved.\n     */\n    TabBar.prototype.insertTab = function (index, value) {\n        // Release the mouse before making any changes.\n        this._releaseMouse();\n        // Coerce the value to a title.\n        var title = Private$9.asTitle(value);\n        // Look up the index of the title.\n        var i = this._titles.indexOf(title);\n        // Clamp the insert index to the array bounds.\n        var j = Math.max(0, Math.min(index, this._titles.length));\n        // If the title is not in the array, insert it.\n        if (i === -1) {\n            // Insert the title into the array.\n            ArrayExt.insert(this._titles, j, title);\n            // Connect to the title changed signal.\n            title.changed.connect(this._onTitleChanged, this);\n            // Schedule an update of the tabs.\n            this.update();\n            // Adjust the current index for the insert.\n            this._adjustCurrentForInsert(j, title);\n            // Return the title added to the tab bar.\n            return title;\n        }\n        // Otherwise, the title exists in the array and should be moved.\n        // Adjust the index if the location is at the end of the array.\n        if (j === this._titles.length) {\n            j--;\n        }\n        // Bail if there is no effective move.\n        if (i === j) {\n            return title;\n        }\n        // Move the title to the new location.\n        ArrayExt.move(this._titles, i, j);\n        // Schedule an update of the tabs.\n        this.update();\n        // Adjust the current index for the move.\n        this._adjustCurrentForMove(i, j);\n        // Return the title added to the tab bar.\n        return title;\n    };\n    /**\n     * Remove a tab from the tab bar.\n     *\n     * @param title - The title for the tab to remove.\n     *\n     * #### Notes\n     * This is a no-op if the title is not in the tab bar.\n     */\n    TabBar.prototype.removeTab = function (title) {\n        this.removeTabAt(this._titles.indexOf(title));\n    };\n    /**\n     * Remove the tab at a given index from the tab bar.\n     *\n     * @param index - The index of the tab to remove.\n     *\n     * #### Notes\n     * This is a no-op if the index is out of range.\n     */\n    TabBar.prototype.removeTabAt = function (index) {\n        // Release the mouse before making any changes.\n        this._releaseMouse();\n        // Remove the title from the array.\n        var title = ArrayExt.removeAt(this._titles, index);\n        // Bail if the index is out of range.\n        if (!title) {\n            return;\n        }\n        // Disconnect from the title changed signal.\n        title.changed.disconnect(this._onTitleChanged, this);\n        // Clear the previous title if it's being removed.\n        if (title === this._previousTitle) {\n            this._previousTitle = null;\n        }\n        // Schedule an update of the tabs.\n        this.update();\n        // Adjust the current index for the remove.\n        this._adjustCurrentForRemove(index, title);\n    };\n    /**\n     * Remove all tabs from the tab bar.\n     */\n    TabBar.prototype.clearTabs = function () {\n        // Bail if there is nothing to remove.\n        if (this._titles.length === 0) {\n            return;\n        }\n        // Release the mouse before making any changes.\n        this._releaseMouse();\n        // Disconnect from the title changed signals.\n        for (var _i = 0, _a = this._titles; _i < _a.length; _i++) {\n            var title = _a[_i];\n            title.changed.disconnect(this._onTitleChanged, this);\n        }\n        // Get the current index and title.\n        var pi = this.currentIndex;\n        var pt = this.currentTitle;\n        // Reset the current index and previous title.\n        this._currentIndex = -1;\n        this._previousTitle = null;\n        // Clear the title array.\n        this._titles.length = 0;\n        // Schedule an update of the tabs.\n        this.update();\n        // If no tab was selected, there's nothing else to do.\n        if (pi === -1) {\n            return;\n        }\n        // Emit the current changed signal.\n        this._currentChanged.emit({\n            previousIndex: pi, previousTitle: pt,\n            currentIndex: -1, currentTitle: null\n        });\n    };\n    /**\n     * Release the mouse and restore the non-dragged tab positions.\n     *\n     * #### Notes\n     * This will cause the tab bar to stop handling mouse events and to\n     * restore the tabs to their non-dragged positions.\n     */\n    TabBar.prototype.releaseMouse = function () {\n        this._releaseMouse();\n    };\n    /**\n     * Handle the DOM events for the tab bar.\n     *\n     * @param event - The DOM event sent to the tab bar.\n     *\n     * #### Notes\n     * This method implements the DOM `EventListener` interface and is\n     * called in response to events on the tab bar's DOM node.\n     *\n     * This should not be called directly by user code.\n     */\n    TabBar.prototype.handleEvent = function (event) {\n        switch (event.type) {\n            case 'mousedown':\n                this._evtMouseDown(event);\n                break;\n            case 'mousemove':\n                this._evtMouseMove(event);\n                break;\n            case 'mouseup':\n                this._evtMouseUp(event);\n                break;\n            case 'dblclick':\n                this._evtDblClick(event);\n                break;\n            case 'keydown':\n                this._evtKeyDown(event);\n                break;\n            case 'contextmenu':\n                event.preventDefault();\n                event.stopPropagation();\n                break;\n        }\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     */\n    TabBar.prototype.onBeforeAttach = function (msg) {\n        this.node.addEventListener('mousedown', this);\n        this.node.addEventListener('dblclick', this);\n    };\n    /**\n     * A message handler invoked on an `'after-detach'` message.\n     */\n    TabBar.prototype.onAfterDetach = function (msg) {\n        this.node.removeEventListener('mousedown', this);\n        this.node.removeEventListener('dblclick', this);\n        this._releaseMouse();\n    };\n    /**\n     * A message handler invoked on an `'update-request'` message.\n     */\n    TabBar.prototype.onUpdateRequest = function (msg) {\n        var titles = this._titles;\n        var renderer = this.renderer;\n        var currentTitle = this.currentTitle;\n        var content = new Array(titles.length);\n        for (var i = 0, n = titles.length; i < n; ++i) {\n            var title = titles[i];\n            var current = title === currentTitle;\n            var zIndex = current ? n : n - i - 1;\n            content[i] = renderer.renderTab({ title: title, current: current, zIndex: zIndex });\n        }\n        VirtualDOM.render(content, this.contentNode);\n    };\n    /**\n     * Handle the `'dblclick'` event for the tab bar.\n     */\n    TabBar.prototype._evtDblClick = function (event) {\n        // Do nothing if titles are not editable\n        if (!this.titlesEditable) {\n            return;\n        }\n        var tabs = this.contentNode.children;\n        // Find the index of the released tab.\n        var index = ArrayExt.findFirstIndex(tabs, function (tab) {\n            return ElementExt.hitTest(tab, event.clientX, event.clientY);\n        });\n        // Do nothing if the press is not on a tab.\n        if (index === -1) {\n            return;\n        }\n        var title = this.titles[index];\n        var label = tabs[index].querySelector('.lm-TabBar-tabLabel');\n        if (label && label.contains(event.target)) {\n            var value = title.label || '';\n            // Clear the label element\n            var oldValue_1 = label.innerHTML;\n            label.innerHTML = \"\";\n            var input_1 = document.createElement('input');\n            input_1.classList.add('lm-TabBar-tabInput');\n            input_1.value = value;\n            label.appendChild(input_1);\n            var onblur_1 = function () {\n                input_1.removeEventListener('blur', onblur_1);\n                label.innerHTML = oldValue_1;\n            };\n            input_1.addEventListener('dblclick', function (event) { return event.stopPropagation(); });\n            input_1.addEventListener('blur', onblur_1);\n            input_1.addEventListener('keydown', function (event) {\n                if (event.key === 'Enter') {\n                    if (input_1.value !== '') {\n                        title.label = title.caption = input_1.value;\n                    }\n                    onblur_1();\n                }\n                else if (event.key === 'Escape') {\n                    onblur_1();\n                }\n            });\n            input_1.select();\n            input_1.focus();\n            if (label.children.length > 0) {\n                label.children[0].focus();\n            }\n        }\n    };\n    /**\n     * Handle the `'keydown'` event for the tab bar.\n     */\n    TabBar.prototype._evtKeyDown = function (event) {\n        // Stop all input events during drag.\n        event.preventDefault();\n        event.stopPropagation();\n        // Release the mouse if `Escape` is pressed.\n        if (event.keyCode === 27) {\n            this._releaseMouse();\n        }\n    };\n    /**\n     * Handle the `'mousedown'` event for the tab bar.\n     */\n    TabBar.prototype._evtMouseDown = function (event) {\n        // Do nothing if it's not a left or middle mouse press.\n        if (event.button !== 0 && event.button !== 1) {\n            return;\n        }\n        // Do nothing if a drag is in progress.\n        if (this._dragData) {\n            return;\n        }\n        // Lookup the tab nodes.\n        var tabs = this.contentNode.children;\n        // Find the index of the pressed tab.\n        var index = ArrayExt.findFirstIndex(tabs, function (tab) {\n            return ElementExt.hitTest(tab, event.clientX, event.clientY);\n        });\n        // Do nothing if the press is not on a tab.\n        if (index === -1) {\n            return;\n        }\n        // Pressing on a tab stops the event propagation.\n        event.preventDefault();\n        event.stopPropagation();\n        // Initialize the non-measured parts of the drag data.\n        this._dragData = {\n            tab: tabs[index],\n            index: index,\n            pressX: event.clientX,\n            pressY: event.clientY,\n            tabPos: -1,\n            tabSize: -1,\n            tabPressPos: -1,\n            targetIndex: -1,\n            tabLayout: null,\n            contentRect: null,\n            override: null,\n            dragActive: false,\n            dragAborted: false,\n            detachRequested: false\n        };\n        // Add the document mouse up listener.\n        document.addEventListener('mouseup', this, true);\n        // Do nothing else if the middle button is clicked.\n        if (event.button === 1) {\n            return;\n        }\n        // Do nothing else if the close icon is clicked.\n        var icon = tabs[index].querySelector(this.renderer.closeIconSelector);\n        if (icon && icon.contains(event.target)) {\n            return;\n        }\n        // Add the extra listeners if the tabs are movable.\n        if (this.tabsMovable) {\n            document.addEventListener('mousemove', this, true);\n            document.addEventListener('keydown', this, true);\n            document.addEventListener('contextmenu', this, true);\n        }\n        // Update the current index as appropriate.\n        if (this.allowDeselect && this.currentIndex === index) {\n            this.currentIndex = -1;\n        }\n        else {\n            this.currentIndex = index;\n        }\n        // Do nothing else if there is no current tab.\n        if (this.currentIndex === -1) {\n            return;\n        }\n        // Emit the tab activate request signal.\n        this._tabActivateRequested.emit({\n            index: this.currentIndex, title: this.currentTitle\n        });\n    };\n    /**\n     * Handle the `'mousemove'` event for the tab bar.\n     */\n    TabBar.prototype._evtMouseMove = function (event) {\n        // Do nothing if no drag is in progress.\n        var data = this._dragData;\n        if (!data) {\n            return;\n        }\n        // Suppress the event during a drag.\n        event.preventDefault();\n        event.stopPropagation();\n        // Lookup the tab nodes.\n        var tabs = this.contentNode.children;\n        // Bail early if the drag threshold has not been met.\n        if (!data.dragActive && !Private$9.dragExceeded(data, event)) {\n            return;\n        }\n        // Activate the drag if necessary.\n        if (!data.dragActive) {\n            // Fill in the rest of the drag data measurements.\n            var tabRect = data.tab.getBoundingClientRect();\n            if (this._orientation === 'horizontal') {\n                data.tabPos = data.tab.offsetLeft;\n                data.tabSize = tabRect.width;\n                data.tabPressPos = data.pressX - tabRect.left;\n            }\n            else {\n                data.tabPos = data.tab.offsetTop;\n                data.tabSize = tabRect.height;\n                data.tabPressPos = data.pressY - tabRect.top;\n            }\n            data.tabLayout = Private$9.snapTabLayout(tabs, this._orientation);\n            data.contentRect = this.contentNode.getBoundingClientRect();\n            data.override = Drag.overrideCursor('default');\n            // Add the dragging style classes.\n            data.tab.classList.add('lm-mod-dragging');\n            this.addClass('lm-mod-dragging');\n            /* <DEPRECATED> */\n            data.tab.classList.add('p-mod-dragging');\n            this.addClass('p-mod-dragging');\n            /* </DEPRECATED> */\n            // Mark the drag as active.\n            data.dragActive = true;\n        }\n        // Emit the detach requested signal if the threshold is exceeded.\n        if (!data.detachRequested && Private$9.detachExceeded(data, event)) {\n            // Only emit the signal once per drag cycle.\n            data.detachRequested = true;\n            // Setup the arguments for the signal.\n            var index = data.index;\n            var clientX = event.clientX;\n            var clientY = event.clientY;\n            var tab = tabs[index];\n            var title = this._titles[index];\n            // Emit the tab detach requested signal.\n            this._tabDetachRequested.emit({ index: index, title: title, tab: tab, clientX: clientX, clientY: clientY });\n            // Bail if the signal handler aborted the drag.\n            if (data.dragAborted) {\n                return;\n            }\n        }\n        // Update the positions of the tabs.\n        Private$9.layoutTabs(tabs, data, event, this._orientation);\n    };\n    /**\n     * Handle the `'mouseup'` event for the document.\n     */\n    TabBar.prototype._evtMouseUp = function (event) {\n        var _this = this;\n        // Do nothing if it's not a left or middle mouse release.\n        if (event.button !== 0 && event.button !== 1) {\n            return;\n        }\n        // Do nothing if no drag is in progress.\n        var data = this._dragData;\n        if (!data) {\n            return;\n        }\n        // Stop the event propagation.\n        event.preventDefault();\n        event.stopPropagation();\n        // Remove the extra mouse event listeners.\n        document.removeEventListener('mousemove', this, true);\n        document.removeEventListener('mouseup', this, true);\n        document.removeEventListener('keydown', this, true);\n        document.removeEventListener('contextmenu', this, true);\n        // Handle a release when the drag is not active.\n        if (!data.dragActive) {\n            // Clear the drag data.\n            this._dragData = null;\n            // Lookup the tab nodes.\n            var tabs = this.contentNode.children;\n            // Find the index of the released tab.\n            var index = ArrayExt.findFirstIndex(tabs, function (tab) {\n                return ElementExt.hitTest(tab, event.clientX, event.clientY);\n            });\n            // Do nothing if the release is not on the original pressed tab.\n            if (index !== data.index) {\n                return;\n            }\n            // Ignore the release if the title is not closable.\n            var title = this._titles[index];\n            if (!title.closable) {\n                return;\n            }\n            // Emit the close requested signal if the middle button is released.\n            if (event.button === 1) {\n                this._tabCloseRequested.emit({ index: index, title: title });\n                return;\n            }\n            // Emit the close requested signal if the close icon was released.\n            var icon = tabs[index].querySelector(this.renderer.closeIconSelector);\n            if (icon && icon.contains(event.target)) {\n                this._tabCloseRequested.emit({ index: index, title: title });\n                return;\n            }\n            // Otherwise, there is nothing left to do.\n            return;\n        }\n        // Do nothing if the left button is not released.\n        if (event.button !== 0) {\n            return;\n        }\n        // Position the tab at its final resting position.\n        Private$9.finalizeTabPosition(data, this._orientation);\n        // Remove the dragging class from the tab so it can be transitioned.\n        data.tab.classList.remove('lm-mod-dragging');\n        /* <DEPRECATED> */\n        data.tab.classList.remove('p-mod-dragging');\n        /* </DEPRECATED> */\n        // Parse the transition duration for releasing the tab.\n        var duration = Private$9.parseTransitionDuration(data.tab);\n        // Complete the release on a timer to allow the tab to transition.\n        setTimeout(function () {\n            // Do nothing if the drag has been aborted.\n            if (data.dragAborted) {\n                return;\n            }\n            // Clear the drag data reference.\n            _this._dragData = null;\n            // Reset the positions of the tabs.\n            Private$9.resetTabPositions(_this.contentNode.children, _this._orientation);\n            // Clear the cursor grab.\n            data.override.dispose();\n            // Remove the remaining dragging style.\n            _this.removeClass('lm-mod-dragging');\n            /* <DEPRECATED> */\n            _this.removeClass('p-mod-dragging');\n            /* </DEPRECATED> */\n            // If the tab was not moved, there is nothing else to do.\n            var i = data.index;\n            var j = data.targetIndex;\n            if (j === -1 || i === j) {\n                return;\n            }\n            // Move the title to the new locations.\n            ArrayExt.move(_this._titles, i, j);\n            // Adjust the current index for the move.\n            _this._adjustCurrentForMove(i, j);\n            // Emit the tab moved signal.\n            _this._tabMoved.emit({\n                fromIndex: i, toIndex: j, title: _this._titles[j]\n            });\n            // Update the tabs immediately to prevent flicker.\n            MessageLoop.sendMessage(_this, Widget.Msg.UpdateRequest);\n        }, duration);\n    };\n    /**\n     * Release the mouse and restore the non-dragged tab positions.\n     */\n    TabBar.prototype._releaseMouse = function () {\n        // Do nothing if no drag is in progress.\n        var data = this._dragData;\n        if (!data) {\n            return;\n        }\n        // Clear the drag data reference.\n        this._dragData = null;\n        // Remove the extra mouse listeners.\n        document.removeEventListener('mousemove', this, true);\n        document.removeEventListener('mouseup', this, true);\n        document.removeEventListener('keydown', this, true);\n        document.removeEventListener('contextmenu', this, true);\n        // Indicate the drag has been aborted. This allows the mouse\n        // event handlers to return early when the drag is canceled.\n        data.dragAborted = true;\n        // If the drag is not active, there's nothing more to do.\n        if (!data.dragActive) {\n            return;\n        }\n        // Reset the tabs to their non-dragged positions.\n        Private$9.resetTabPositions(this.contentNode.children, this._orientation);\n        // Clear the cursor override.\n        data.override.dispose();\n        // Clear the dragging style classes.\n        data.tab.classList.remove('lm-mod-dragging');\n        this.removeClass('lm-mod-dragging');\n        /* <DEPRECATED> */\n        data.tab.classList.remove('p-mod-dragging');\n        this.removeClass('p-mod-dragging');\n        /* </DEPRECATED> */\n    };\n    /**\n     * Adjust the current index for a tab insert operation.\n     *\n     * This method accounts for the tab bar's insertion behavior when\n     * adjusting the current index and emitting the changed signal.\n     */\n    TabBar.prototype._adjustCurrentForInsert = function (i, title) {\n        // Lookup commonly used variables.\n        var ct = this.currentTitle;\n        var ci = this._currentIndex;\n        var bh = this.insertBehavior;\n        // Handle the behavior where the new tab is always selected,\n        // or the behavior where the new tab is selected if needed.\n        if (bh === 'select-tab' || (bh === 'select-tab-if-needed' && ci === -1)) {\n            this._currentIndex = i;\n            this._previousTitle = ct;\n            this._currentChanged.emit({\n                previousIndex: ci, previousTitle: ct,\n                currentIndex: i, currentTitle: title\n            });\n            return;\n        }\n        // Otherwise, silently adjust the current index if needed.\n        if (ci >= i) {\n            this._currentIndex++;\n        }\n    };\n    /**\n     * Adjust the current index for a tab move operation.\n     *\n     * This method will not cause the actual current tab to change.\n     * It silently adjusts the index to account for the given move.\n     */\n    TabBar.prototype._adjustCurrentForMove = function (i, j) {\n        if (this._currentIndex === i) {\n            this._currentIndex = j;\n        }\n        else if (this._currentIndex < i && this._currentIndex >= j) {\n            this._currentIndex++;\n        }\n        else if (this._currentIndex > i && this._currentIndex <= j) {\n            this._currentIndex--;\n        }\n    };\n    /**\n     * Adjust the current index for a tab remove operation.\n     *\n     * This method accounts for the tab bar's remove behavior when\n     * adjusting the current index and emitting the changed signal.\n     */\n    TabBar.prototype._adjustCurrentForRemove = function (i, title) {\n        // Lookup commonly used variables.\n        var ci = this._currentIndex;\n        var bh = this.removeBehavior;\n        // Silently adjust the index if the current tab is not removed.\n        if (ci !== i) {\n            if (ci > i) {\n                this._currentIndex--;\n            }\n            return;\n        }\n        // No tab gets selected if the tab bar is empty.\n        if (this._titles.length === 0) {\n            this._currentIndex = -1;\n            this._currentChanged.emit({\n                previousIndex: i, previousTitle: title,\n                currentIndex: -1, currentTitle: null\n            });\n            return;\n        }\n        // Handle behavior where the next sibling tab is selected.\n        if (bh === 'select-tab-after') {\n            this._currentIndex = Math.min(i, this._titles.length - 1);\n            this._currentChanged.emit({\n                previousIndex: i, previousTitle: title,\n                currentIndex: this._currentIndex, currentTitle: this.currentTitle\n            });\n            return;\n        }\n        // Handle behavior where the previous sibling tab is selected.\n        if (bh === 'select-tab-before') {\n            this._currentIndex = Math.max(0, i - 1);\n            this._currentChanged.emit({\n                previousIndex: i, previousTitle: title,\n                currentIndex: this._currentIndex, currentTitle: this.currentTitle\n            });\n            return;\n        }\n        // Handle behavior where the previous history tab is selected.\n        if (bh === 'select-previous-tab') {\n            if (this._previousTitle) {\n                this._currentIndex = this._titles.indexOf(this._previousTitle);\n                this._previousTitle = null;\n            }\n            else {\n                this._currentIndex = Math.min(i, this._titles.length - 1);\n            }\n            this._currentChanged.emit({\n                previousIndex: i, previousTitle: title,\n                currentIndex: this._currentIndex, currentTitle: this.currentTitle\n            });\n            return;\n        }\n        // Otherwise, no tab gets selected.\n        this._currentIndex = -1;\n        this._currentChanged.emit({\n            previousIndex: i, previousTitle: title,\n            currentIndex: -1, currentTitle: null\n        });\n    };\n    /**\n     * Handle the `changed` signal of a title object.\n     */\n    TabBar.prototype._onTitleChanged = function (sender) {\n        this.update();\n    };\n    return TabBar;\n}(Widget));\n/**\n * The namespace for the `TabBar` class statics.\n */\n(function (TabBar) {\n    /**\n     * The default implementation of `IRenderer`.\n     *\n     * #### Notes\n     * Subclasses are free to reimplement rendering methods as needed.\n     */\n    var Renderer = /** @class */ (function () {\n        /**\n         * Construct a new renderer.\n         */\n        function Renderer() {\n            /**\n             * A selector which matches the close icon node in a tab.\n             */\n            this.closeIconSelector = '.lm-TabBar-tabCloseIcon';\n            this._tabID = 0;\n            this._tabKeys = new WeakMap();\n        }\n        /**\n         * Render the virtual element for a tab.\n         *\n         * @param data - The data to use for rendering the tab.\n         *\n         * @returns A virtual element representing the tab.\n         */\n        Renderer.prototype.renderTab = function (data) {\n            var title = data.title.caption;\n            var key = this.createTabKey(data);\n            var style = this.createTabStyle(data);\n            var className = this.createTabClass(data);\n            var dataset = this.createTabDataset(data);\n            return (h.li({ key: key, className: className, title: title, style: style, dataset: dataset }, this.renderIcon(data), this.renderLabel(data), this.renderCloseIcon(data)));\n        };\n        /**\n         * Render the icon element for a tab.\n         *\n         * @param data - The data to use for rendering the tab.\n         *\n         * @returns A virtual element representing the tab icon.\n         */\n        Renderer.prototype.renderIcon = function (data) {\n            var title = data.title;\n            var className = this.createIconClass(data);\n            /* <DEPRECATED> */\n            if (typeof title.icon === 'string') {\n                return h.div({ className: className }, title.iconLabel);\n            }\n            /* </DEPRECATED> */\n            // if title.icon is undefined, it will be ignored\n            return h.div({ className: className }, title.icon, title.iconLabel);\n        };\n        /**\n         * Render the label element for a tab.\n         *\n         * @param data - The data to use for rendering the tab.\n         *\n         * @returns A virtual element representing the tab label.\n         */\n        Renderer.prototype.renderLabel = function (data) {\n            return h.div({\n                className: 'lm-TabBar-tabLabel'\n                    /* <DEPRECATED> */\n                    + ' p-TabBar-tabLabel'\n                /* </DEPRECATED> */\n            }, data.title.label);\n        };\n        /**\n         * Render the close icon element for a tab.\n         *\n         * @param data - The data to use for rendering the tab.\n         *\n         * @returns A virtual element representing the tab close icon.\n         */\n        Renderer.prototype.renderCloseIcon = function (data) {\n            return h.div({\n                className: 'lm-TabBar-tabCloseIcon'\n                    /* <DEPRECATED> */\n                    + ' p-TabBar-tabCloseIcon'\n                /* </DEPRECATED> */\n            });\n        };\n        /**\n         * Create a unique render key for the tab.\n         *\n         * @param data - The data to use for the tab.\n         *\n         * @returns The unique render key for the tab.\n         *\n         * #### Notes\n         * This method caches the key against the tab title the first time\n         * the key is generated. This enables efficient rendering of moved\n         * tabs and avoids subtle hover style artifacts.\n         */\n        Renderer.prototype.createTabKey = function (data) {\n            var key = this._tabKeys.get(data.title);\n            if (key === undefined) {\n                key = \"tab-key-\" + this._tabID++;\n                this._tabKeys.set(data.title, key);\n            }\n            return key;\n        };\n        /**\n         * Create the inline style object for a tab.\n         *\n         * @param data - The data to use for the tab.\n         *\n         * @returns The inline style data for the tab.\n         */\n        Renderer.prototype.createTabStyle = function (data) {\n            return { zIndex: \"\" + data.zIndex };\n        };\n        /**\n         * Create the class name for the tab.\n         *\n         * @param data - The data to use for the tab.\n         *\n         * @returns The full class name for the tab.\n         */\n        Renderer.prototype.createTabClass = function (data) {\n            var name = 'lm-TabBar-tab';\n            /* <DEPRECATED> */\n            name += ' p-TabBar-tab';\n            /* </DEPRECATED> */\n            if (data.title.className) {\n                name += \" \" + data.title.className;\n            }\n            if (data.title.closable) {\n                name += ' lm-mod-closable';\n                /* <DEPRECATED> */\n                name += ' p-mod-closable';\n                /* </DEPRECATED> */\n            }\n            if (data.current) {\n                name += ' lm-mod-current';\n                /* <DEPRECATED> */\n                name += ' p-mod-current';\n                /* </DEPRECATED> */\n            }\n            return name;\n        };\n        /**\n         * Create the dataset for a tab.\n         *\n         * @param data - The data to use for the tab.\n         *\n         * @returns The dataset for the tab.\n         */\n        Renderer.prototype.createTabDataset = function (data) {\n            return data.title.dataset;\n        };\n        /**\n         * Create the class name for the tab icon.\n         *\n         * @param data - The data to use for the tab.\n         *\n         * @returns The full class name for the tab icon.\n         */\n        Renderer.prototype.createIconClass = function (data) {\n            var name = 'lm-TabBar-tabIcon';\n            /* <DEPRECATED> */\n            name += ' p-TabBar-tabIcon';\n            /* </DEPRECATED> */\n            var extra = data.title.iconClass;\n            return extra ? name + \" \" + extra : name;\n        };\n        return Renderer;\n    }());\n    TabBar.Renderer = Renderer;\n    /**\n     * The default `Renderer` instance.\n     */\n    TabBar.defaultRenderer = new Renderer();\n})(TabBar || (TabBar = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$9;\n(function (Private) {\n    /**\n     * The start drag distance threshold.\n     */\n    Private.DRAG_THRESHOLD = 5;\n    /**\n     * The detach distance threshold.\n     */\n    Private.DETACH_THRESHOLD = 20;\n    /**\n     * Create the DOM node for a tab bar.\n     */\n    function createNode() {\n        var node = document.createElement('div');\n        var content = document.createElement('ul');\n        content.className = 'lm-TabBar-content';\n        /* <DEPRECATED> */\n        content.classList.add('p-TabBar-content');\n        /* </DEPRECATED> */\n        node.appendChild(content);\n        return node;\n    }\n    Private.createNode = createNode;\n    /**\n     * Coerce a title or options into a real title.\n     */\n    function asTitle(value) {\n        return value instanceof Title ? value : new Title(value);\n    }\n    Private.asTitle = asTitle;\n    /**\n     * Parse the transition duration for a tab node.\n     */\n    function parseTransitionDuration(tab) {\n        var style = window.getComputedStyle(tab);\n        return 1000 * (parseFloat(style.transitionDuration) || 0);\n    }\n    Private.parseTransitionDuration = parseTransitionDuration;\n    /**\n     * Get a snapshot of the current tab layout values.\n     */\n    function snapTabLayout(tabs, orientation) {\n        var layout = new Array(tabs.length);\n        for (var i = 0, n = tabs.length; i < n; ++i) {\n            var node = tabs[i];\n            var style = window.getComputedStyle(node);\n            if (orientation === 'horizontal') {\n                layout[i] = {\n                    pos: node.offsetLeft,\n                    size: node.offsetWidth,\n                    margin: parseFloat(style.marginLeft) || 0\n                };\n            }\n            else {\n                layout[i] = {\n                    pos: node.offsetTop,\n                    size: node.offsetHeight,\n                    margin: parseFloat(style.marginTop) || 0\n                };\n            }\n        }\n        return layout;\n    }\n    Private.snapTabLayout = snapTabLayout;\n    /**\n     * Test if the event exceeds the drag threshold.\n     */\n    function dragExceeded(data, event) {\n        var dx = Math.abs(event.clientX - data.pressX);\n        var dy = Math.abs(event.clientY - data.pressY);\n        return dx >= Private.DRAG_THRESHOLD || dy >= Private.DRAG_THRESHOLD;\n    }\n    Private.dragExceeded = dragExceeded;\n    /**\n     * Test if the event exceeds the drag detach threshold.\n     */\n    function detachExceeded(data, event) {\n        var rect = data.contentRect;\n        return ((event.clientX < rect.left - Private.DETACH_THRESHOLD) ||\n            (event.clientX >= rect.right + Private.DETACH_THRESHOLD) ||\n            (event.clientY < rect.top - Private.DETACH_THRESHOLD) ||\n            (event.clientY >= rect.bottom + Private.DETACH_THRESHOLD));\n    }\n    Private.detachExceeded = detachExceeded;\n    /**\n     * Update the relative tab positions and computed target index.\n     */\n    function layoutTabs(tabs, data, event, orientation) {\n        // Compute the orientation-sensitive values.\n        var pressPos;\n        var localPos;\n        var clientPos;\n        var clientSize;\n        if (orientation === 'horizontal') {\n            pressPos = data.pressX;\n            localPos = event.clientX - data.contentRect.left;\n            clientPos = event.clientX;\n            clientSize = data.contentRect.width;\n        }\n        else {\n            pressPos = data.pressY;\n            localPos = event.clientY - data.contentRect.top;\n            clientPos = event.clientY;\n            clientSize = data.contentRect.height;\n        }\n        // Compute the target data.\n        var targetIndex = data.index;\n        var targetPos = localPos - data.tabPressPos;\n        var targetEnd = targetPos + data.tabSize;\n        // Update the relative tab positions.\n        for (var i = 0, n = tabs.length; i < n; ++i) {\n            var pxPos = void 0;\n            var layout = data.tabLayout[i];\n            var threshold = layout.pos + (layout.size >> 1);\n            if (i < data.index && targetPos < threshold) {\n                pxPos = data.tabSize + data.tabLayout[i + 1].margin + \"px\";\n                targetIndex = Math.min(targetIndex, i);\n            }\n            else if (i > data.index && targetEnd > threshold) {\n                pxPos = -data.tabSize - layout.margin + \"px\";\n                targetIndex = Math.max(targetIndex, i);\n            }\n            else if (i === data.index) {\n                var ideal = clientPos - pressPos;\n                var limit = clientSize - (data.tabPos + data.tabSize);\n                pxPos = Math.max(-data.tabPos, Math.min(ideal, limit)) + \"px\";\n            }\n            else {\n                pxPos = '';\n            }\n            if (orientation === 'horizontal') {\n                tabs[i].style.left = pxPos;\n            }\n            else {\n                tabs[i].style.top = pxPos;\n            }\n        }\n        // Update the computed target index.\n        data.targetIndex = targetIndex;\n    }\n    Private.layoutTabs = layoutTabs;\n    /**\n     * Position the drag tab at its final resting relative position.\n     */\n    function finalizeTabPosition(data, orientation) {\n        // Compute the orientation-sensitive client size.\n        var clientSize;\n        if (orientation === 'horizontal') {\n            clientSize = data.contentRect.width;\n        }\n        else {\n            clientSize = data.contentRect.height;\n        }\n        // Compute the ideal final tab position.\n        var ideal;\n        if (data.targetIndex === data.index) {\n            ideal = 0;\n        }\n        else if (data.targetIndex > data.index) {\n            var tgt = data.tabLayout[data.targetIndex];\n            ideal = tgt.pos + tgt.size - data.tabSize - data.tabPos;\n        }\n        else {\n            var tgt = data.tabLayout[data.targetIndex];\n            ideal = tgt.pos - data.tabPos;\n        }\n        // Compute the tab position limit.\n        var limit = clientSize - (data.tabPos + data.tabSize);\n        var final = Math.max(-data.tabPos, Math.min(ideal, limit));\n        // Set the final orientation-sensitive position.\n        if (orientation === 'horizontal') {\n            data.tab.style.left = final + \"px\";\n        }\n        else {\n            data.tab.style.top = final + \"px\";\n        }\n    }\n    Private.finalizeTabPosition = finalizeTabPosition;\n    /**\n     * Reset the relative positions of the given tabs.\n     */\n    function resetTabPositions(tabs, orientation) {\n        each(tabs, function (tab) {\n            if (orientation === 'horizontal') {\n                tab.style.left = '';\n            }\n            else {\n                tab.style.top = '';\n            }\n        });\n    }\n    Private.resetTabPositions = resetTabPositions;\n})(Private$9 || (Private$9 = {}));\n\n/**\n * A widget which provides a flexible docking area for widgets.\n */\nvar DockPanel = /** @class */ (function (_super) {\n    __extends(DockPanel, _super);\n    /**\n     * Construct a new dock panel.\n     *\n     * @param options - The options for initializing the panel.\n     */\n    function DockPanel(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this) || this;\n        _this._drag = null;\n        _this._tabsMovable = true;\n        _this._tabsConstrained = false;\n        _this._pressData = null;\n        _this._layoutModified = new Signal(_this);\n        _this.addClass('lm-DockPanel');\n        /* <DEPRECATED> */\n        _this.addClass('p-DockPanel');\n        /* </DEPRECATED> */\n        _this._mode = options.mode || 'multiple-document';\n        _this._renderer = options.renderer || DockPanel.defaultRenderer;\n        _this._edges = options.edges || Private$a.DEFAULT_EDGES;\n        if (options.tabsMovable !== undefined) {\n            _this._tabsMovable = options.tabsMovable;\n        }\n        if (options.tabsConstrained !== undefined) {\n            _this._tabsConstrained = options.tabsConstrained;\n        }\n        // Toggle the CSS mode attribute.\n        _this.dataset['mode'] = _this._mode;\n        // Create the delegate renderer for the layout.\n        var renderer = {\n            createTabBar: function () { return _this._createTabBar(); },\n            createHandle: function () { return _this._createHandle(); }\n        };\n        // Set up the dock layout for the panel.\n        _this.layout = new DockLayout({ renderer: renderer, spacing: options.spacing });\n        // Set up the overlay drop indicator.\n        _this.overlay = options.overlay || new DockPanel.Overlay();\n        _this.node.appendChild(_this.overlay.node);\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the panel.\n     */\n    DockPanel.prototype.dispose = function () {\n        // Ensure the mouse is released.\n        this._releaseMouse();\n        // Hide the overlay.\n        this.overlay.hide(0);\n        // Cancel a drag if one is in progress.\n        if (this._drag) {\n            this._drag.dispose();\n        }\n        // Dispose of the base class.\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(DockPanel.prototype, \"layoutModified\", {\n        /**\n         * A signal emitted when the layout configuration is modified.\n         *\n         * #### Notes\n         * This signal is emitted whenever the current layout configuration\n         * may have changed.\n         *\n         * This signal is emitted asynchronously in a collapsed fashion, so\n         * that multiple synchronous modifications results in only a single\n         * emit of the signal.\n         */\n        get: function () {\n            return this._layoutModified;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(DockPanel.prototype, \"renderer\", {\n        /**\n         * The renderer used by the dock panel.\n         */\n        get: function () {\n            return this.layout.renderer;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(DockPanel.prototype, \"spacing\", {\n        /**\n         * Get the spacing between the widgets.\n         */\n        get: function () {\n            return this.layout.spacing;\n        },\n        /**\n         * Set the spacing between the widgets.\n         */\n        set: function (value) {\n            this.layout.spacing = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(DockPanel.prototype, \"mode\", {\n        /**\n         * Get the mode for the dock panel.\n         */\n        get: function () {\n            return this._mode;\n        },\n        /**\n         * Set the mode for the dock panel.\n         *\n         * #### Notes\n         * Changing the mode is a destructive operation with respect to the\n         * panel's layout configuration. If layout state must be preserved,\n         * save the current layout config before changing the mode.\n         */\n        set: function (value) {\n            // Bail early if the mode does not change.\n            if (this._mode === value) {\n                return;\n            }\n            // Update the internal mode.\n            this._mode = value;\n            // Toggle the CSS mode attribute.\n            this.dataset['mode'] = value;\n            // Get the layout for the panel.\n            var layout = this.layout;\n            // Configure the layout for the specified mode.\n            switch (value) {\n                case 'multiple-document':\n                    each(layout.tabBars(), function (tabBar) { tabBar.show(); });\n                    break;\n                case 'single-document':\n                    layout.restoreLayout(Private$a.createSingleDocumentConfig(this));\n                    break;\n                default:\n                    throw 'unreachable';\n            }\n            // Schedule an emit of the layout modified signal.\n            MessageLoop.postMessage(this, Private$a.LayoutModified);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(DockPanel.prototype, \"tabsMovable\", {\n        /**\n         * Whether the tabs can be dragged / moved at runtime.\n         */\n        get: function () {\n            return this._tabsMovable;\n        },\n        /**\n         * Enable / Disable draggable / movable tabs.\n         */\n        set: function (value) {\n            this._tabsMovable = value;\n            each(this.tabBars(), function (tabbar) { tabbar.tabsMovable = value; });\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(DockPanel.prototype, \"tabsConstrained\", {\n        /**\n         * Whether the tabs are constrained to their source dock panel\n         */\n        get: function () {\n            return this._tabsConstrained;\n        },\n        /**\n         * Constrain/Allow tabs to be dragged outside of this dock panel\n         */\n        set: function (value) {\n            this._tabsConstrained = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(DockPanel.prototype, \"isEmpty\", {\n        /**\n         * Whether the dock panel is empty.\n         */\n        get: function () {\n            return this.layout.isEmpty;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Create an iterator over the user widgets in the panel.\n     *\n     * @returns A new iterator over the user widgets in the panel.\n     *\n     * #### Notes\n     * This iterator does not include the generated tab bars.\n     */\n    DockPanel.prototype.widgets = function () {\n        return this.layout.widgets();\n    };\n    /**\n     * Create an iterator over the selected widgets in the panel.\n     *\n     * @returns A new iterator over the selected user widgets.\n     *\n     * #### Notes\n     * This iterator yields the widgets corresponding to the current tab\n     * of each tab bar in the panel.\n     */\n    DockPanel.prototype.selectedWidgets = function () {\n        return this.layout.selectedWidgets();\n    };\n    /**\n     * Create an iterator over the tab bars in the panel.\n     *\n     * @returns A new iterator over the tab bars in the panel.\n     *\n     * #### Notes\n     * This iterator does not include the user widgets.\n     */\n    DockPanel.prototype.tabBars = function () {\n        return this.layout.tabBars();\n    };\n    /**\n     * Create an iterator over the handles in the panel.\n     *\n     * @returns A new iterator over the handles in the panel.\n     */\n    DockPanel.prototype.handles = function () {\n        return this.layout.handles();\n    };\n    /**\n     * Select a specific widget in the dock panel.\n     *\n     * @param widget - The widget of interest.\n     *\n     * #### Notes\n     * This will make the widget the current widget in its tab area.\n     */\n    DockPanel.prototype.selectWidget = function (widget) {\n        // Find the tab bar which contains the widget.\n        var tabBar = find(this.tabBars(), function (bar) {\n            return bar.titles.indexOf(widget.title) !== -1;\n        });\n        // Throw an error if no tab bar is found.\n        if (!tabBar) {\n            throw new Error('Widget is not contained in the dock panel.');\n        }\n        // Ensure the widget is the current widget.\n        tabBar.currentTitle = widget.title;\n    };\n    /**\n     * Activate a specified widget in the dock panel.\n     *\n     * @param widget - The widget of interest.\n     *\n     * #### Notes\n     * This will select and activate the given widget.\n     */\n    DockPanel.prototype.activateWidget = function (widget) {\n        this.selectWidget(widget);\n        widget.activate();\n    };\n    /**\n     * Save the current layout configuration of the dock panel.\n     *\n     * @returns A new config object for the current layout state.\n     *\n     * #### Notes\n     * The return value can be provided to the `restoreLayout` method\n     * in order to restore the layout to its current configuration.\n     */\n    DockPanel.prototype.saveLayout = function () {\n        return this.layout.saveLayout();\n    };\n    /**\n     * Restore the layout to a previously saved configuration.\n     *\n     * @param config - The layout configuration to restore.\n     *\n     * #### Notes\n     * Widgets which currently belong to the layout but which are not\n     * contained in the config will be unparented.\n     *\n     * The dock panel automatically reverts to `'multiple-document'`\n     * mode when a layout config is restored.\n     */\n    DockPanel.prototype.restoreLayout = function (config) {\n        // Reset the mode.\n        this._mode = 'multiple-document';\n        // Restore the layout.\n        this.layout.restoreLayout(config);\n        // Flush the message loop on IE and Edge to prevent flicker.\n        if (Platform.IS_EDGE || Platform.IS_IE) {\n            MessageLoop.flush();\n        }\n        // Schedule an emit of the layout modified signal.\n        MessageLoop.postMessage(this, Private$a.LayoutModified);\n    };\n    /**\n     * Add a widget to the dock panel.\n     *\n     * @param widget - The widget to add to the dock panel.\n     *\n     * @param options - The additional options for adding the widget.\n     *\n     * #### Notes\n     * If the panel is in single document mode, the options are ignored\n     * and the widget is always added as tab in the hidden tab bar.\n     */\n    DockPanel.prototype.addWidget = function (widget, options) {\n        if (options === void 0) { options = {}; }\n        // Add the widget to the layout.\n        if (this._mode === 'single-document') {\n            this.layout.addWidget(widget);\n        }\n        else {\n            this.layout.addWidget(widget, options);\n        }\n        // Schedule an emit of the layout modified signal.\n        MessageLoop.postMessage(this, Private$a.LayoutModified);\n    };\n    /**\n     * Process a message sent to the widget.\n     *\n     * @param msg - The message sent to the widget.\n     */\n    DockPanel.prototype.processMessage = function (msg) {\n        if (msg.type === 'layout-modified') {\n            this._layoutModified.emit(undefined);\n        }\n        else {\n            _super.prototype.processMessage.call(this, msg);\n        }\n    };\n    /**\n     * Handle the DOM events for the dock panel.\n     *\n     * @param event - The DOM event sent to the panel.\n     *\n     * #### Notes\n     * This method implements the DOM `EventListener` interface and is\n     * called in response to events on the panel's DOM node. It should\n     * not be called directly by user code.\n     */\n    DockPanel.prototype.handleEvent = function (event) {\n        switch (event.type) {\n            case 'lm-dragenter':\n                this._evtDragEnter(event);\n                break;\n            case 'lm-dragleave':\n                this._evtDragLeave(event);\n                break;\n            case 'lm-dragover':\n                this._evtDragOver(event);\n                break;\n            case 'lm-drop':\n                this._evtDrop(event);\n                break;\n            case 'mousedown':\n                this._evtMouseDown(event);\n                break;\n            case 'mousemove':\n                this._evtMouseMove(event);\n                break;\n            case 'mouseup':\n                this._evtMouseUp(event);\n                break;\n            case 'keydown':\n                this._evtKeyDown(event);\n                break;\n            case 'contextmenu':\n                event.preventDefault();\n                event.stopPropagation();\n                break;\n        }\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     */\n    DockPanel.prototype.onBeforeAttach = function (msg) {\n        this.node.addEventListener('lm-dragenter', this);\n        this.node.addEventListener('lm-dragleave', this);\n        this.node.addEventListener('lm-dragover', this);\n        this.node.addEventListener('lm-drop', this);\n        this.node.addEventListener('mousedown', this);\n    };\n    /**\n     * A message handler invoked on an `'after-detach'` message.\n     */\n    DockPanel.prototype.onAfterDetach = function (msg) {\n        this.node.removeEventListener('lm-dragenter', this);\n        this.node.removeEventListener('lm-dragleave', this);\n        this.node.removeEventListener('lm-dragover', this);\n        this.node.removeEventListener('lm-drop', this);\n        this.node.removeEventListener('mousedown', this);\n        this._releaseMouse();\n    };\n    /**\n     * A message handler invoked on a `'child-added'` message.\n     */\n    DockPanel.prototype.onChildAdded = function (msg) {\n        // Ignore the generated tab bars.\n        if (Private$a.isGeneratedTabBarProperty.get(msg.child)) {\n            return;\n        }\n        // Add the widget class to the child.\n        msg.child.addClass('lm-DockPanel-widget');\n        /* <DEPRECATED> */\n        msg.child.addClass('p-DockPanel-widget');\n        /* </DEPRECATED> */\n    };\n    /**\n     * A message handler invoked on a `'child-removed'` message.\n     */\n    DockPanel.prototype.onChildRemoved = function (msg) {\n        // Ignore the generated tab bars.\n        if (Private$a.isGeneratedTabBarProperty.get(msg.child)) {\n            return;\n        }\n        // Remove the widget class from the child.\n        msg.child.removeClass('lm-DockPanel-widget');\n        /* <DEPRECATED> */\n        msg.child.removeClass('p-DockPanel-widget');\n        /* </DEPRECATED> */\n        // Schedule an emit of the layout modified signal.\n        MessageLoop.postMessage(this, Private$a.LayoutModified);\n    };\n    /**\n     * Handle the `'lm-dragenter'` event for the dock panel.\n     */\n    DockPanel.prototype._evtDragEnter = function (event) {\n        // If the factory mime type is present, mark the event as\n        // handled in order to get the rest of the drag events.\n        if (event.mimeData.hasData('application/vnd.lumino.widget-factory')) {\n            event.preventDefault();\n            event.stopPropagation();\n        }\n    };\n    /**\n     * Handle the `'lm-dragleave'` event for the dock panel.\n     */\n    DockPanel.prototype._evtDragLeave = function (event) {\n        // Mark the event as handled.\n        event.preventDefault();\n        event.stopPropagation();\n        // The new target might be a descendant, so we might still handle the drop.\n        // Hide asynchronously so that if a lm-dragover event bubbles up to us, the\n        // hide is cancelled by the lm-dragover handler's show overlay logic.\n        this.overlay.hide(1);\n    };\n    /**\n     * Handle the `'lm-dragover'` event for the dock panel.\n     */\n    DockPanel.prototype._evtDragOver = function (event) {\n        // Mark the event as handled.\n        event.preventDefault();\n        event.stopPropagation();\n        // Show the drop indicator overlay and update the drop\n        // action based on the drop target zone under the mouse.\n        if ((this._tabsConstrained && event.source !== this) || this._showOverlay(event.clientX, event.clientY) === 'invalid') {\n            event.dropAction = 'none';\n        }\n        else {\n            event.dropAction = event.proposedAction;\n        }\n    };\n    /**\n     * Handle the `'lm-drop'` event for the dock panel.\n     */\n    DockPanel.prototype._evtDrop = function (event) {\n        // Mark the event as handled.\n        event.preventDefault();\n        event.stopPropagation();\n        // Hide the drop indicator overlay.\n        this.overlay.hide(0);\n        // Bail if the proposed action is to do nothing.\n        if (event.proposedAction === 'none') {\n            event.dropAction = 'none';\n            return;\n        }\n        // Find the drop target under the mouse.\n        var clientX = event.clientX, clientY = event.clientY;\n        var _a = Private$a.findDropTarget(this, clientX, clientY, this._edges), zone = _a.zone, target = _a.target;\n        // Bail if the drop zone is invalid.\n        if (zone === 'invalid') {\n            event.dropAction = 'none';\n            return;\n        }\n        // Bail if the factory mime type has invalid data.\n        var mimeData = event.mimeData;\n        var factory = mimeData.getData('application/vnd.lumino.widget-factory');\n        if (typeof factory !== 'function') {\n            event.dropAction = 'none';\n            return;\n        }\n        // Bail if the factory does not produce a widget.\n        var widget = factory();\n        if (!(widget instanceof Widget)) {\n            event.dropAction = 'none';\n            return;\n        }\n        // Bail if the widget is an ancestor of the dock panel.\n        if (widget.contains(this)) {\n            event.dropAction = 'none';\n            return;\n        }\n        // Find the reference widget for the drop target.\n        var ref = target ? Private$a.getDropRef(target.tabBar) : null;\n        // Add the widget according to the indicated drop zone.\n        switch (zone) {\n            case 'root-all':\n                this.addWidget(widget);\n                break;\n            case 'root-top':\n                this.addWidget(widget, { mode: 'split-top' });\n                break;\n            case 'root-left':\n                this.addWidget(widget, { mode: 'split-left' });\n                break;\n            case 'root-right':\n                this.addWidget(widget, { mode: 'split-right' });\n                break;\n            case 'root-bottom':\n                this.addWidget(widget, { mode: 'split-bottom' });\n                break;\n            case 'widget-all':\n                this.addWidget(widget, { mode: 'tab-after', ref: ref });\n                break;\n            case 'widget-top':\n                this.addWidget(widget, { mode: 'split-top', ref: ref });\n                break;\n            case 'widget-left':\n                this.addWidget(widget, { mode: 'split-left', ref: ref });\n                break;\n            case 'widget-right':\n                this.addWidget(widget, { mode: 'split-right', ref: ref });\n                break;\n            case 'widget-bottom':\n                this.addWidget(widget, { mode: 'split-bottom', ref: ref });\n                break;\n            case 'widget-tab':\n                this.addWidget(widget, { mode: 'tab-after', ref: ref });\n                break;\n            default:\n                throw 'unreachable';\n        }\n        // Accept the proposed drop action.\n        event.dropAction = event.proposedAction;\n        // Activate the dropped widget.\n        this.activateWidget(widget);\n    };\n    /**\n     * Handle the `'keydown'` event for the dock panel.\n     */\n    DockPanel.prototype._evtKeyDown = function (event) {\n        // Stop input events during drag.\n        event.preventDefault();\n        event.stopPropagation();\n        // Release the mouse if `Escape` is pressed.\n        if (event.keyCode === 27) {\n            // Finalize the mouse release.\n            this._releaseMouse();\n            // Schedule an emit of the layout modified signal.\n            MessageLoop.postMessage(this, Private$a.LayoutModified);\n        }\n    };\n    /**\n     * Handle the `'mousedown'` event for the dock panel.\n     */\n    DockPanel.prototype._evtMouseDown = function (event) {\n        // Do nothing if the left mouse button is not pressed.\n        if (event.button !== 0) {\n            return;\n        }\n        // Find the handle which contains the mouse target, if any.\n        var layout = this.layout;\n        var target = event.target;\n        var handle = find(layout.handles(), function (handle) { return handle.contains(target); });\n        if (!handle) {\n            return;\n        }\n        // Stop the event when a handle is pressed.\n        event.preventDefault();\n        event.stopPropagation();\n        // Add the extra document listeners.\n        document.addEventListener('keydown', this, true);\n        document.addEventListener('mouseup', this, true);\n        document.addEventListener('mousemove', this, true);\n        document.addEventListener('contextmenu', this, true);\n        // Compute the offset deltas for the handle press.\n        var rect = handle.getBoundingClientRect();\n        var deltaX = event.clientX - rect.left;\n        var deltaY = event.clientY - rect.top;\n        // Override the cursor and store the press data.\n        var style = window.getComputedStyle(handle);\n        var override = Drag.overrideCursor(style.cursor);\n        this._pressData = { handle: handle, deltaX: deltaX, deltaY: deltaY, override: override };\n    };\n    /**\n     * Handle the `'mousemove'` event for the dock panel.\n     */\n    DockPanel.prototype._evtMouseMove = function (event) {\n        // Bail early if no drag is in progress.\n        if (!this._pressData) {\n            return;\n        }\n        // Stop the event when dragging a handle.\n        event.preventDefault();\n        event.stopPropagation();\n        // Compute the desired offset position for the handle.\n        var rect = this.node.getBoundingClientRect();\n        var xPos = event.clientX - rect.left - this._pressData.deltaX;\n        var yPos = event.clientY - rect.top - this._pressData.deltaY;\n        // Set the handle as close to the desired position as possible.\n        var layout = this.layout;\n        layout.moveHandle(this._pressData.handle, xPos, yPos);\n    };\n    /**\n     * Handle the `'mouseup'` event for the dock panel.\n     */\n    DockPanel.prototype._evtMouseUp = function (event) {\n        // Do nothing if the left mouse button is not released.\n        if (event.button !== 0) {\n            return;\n        }\n        // Stop the event when releasing a handle.\n        event.preventDefault();\n        event.stopPropagation();\n        // Finalize the mouse release.\n        this._releaseMouse();\n        // Schedule an emit of the layout modified signal.\n        MessageLoop.postMessage(this, Private$a.LayoutModified);\n    };\n    /**\n     * Release the mouse grab for the dock panel.\n     */\n    DockPanel.prototype._releaseMouse = function () {\n        // Bail early if no drag is in progress.\n        if (!this._pressData) {\n            return;\n        }\n        // Clear the override cursor.\n        this._pressData.override.dispose();\n        this._pressData = null;\n        // Remove the extra document listeners.\n        document.removeEventListener('keydown', this, true);\n        document.removeEventListener('mouseup', this, true);\n        document.removeEventListener('mousemove', this, true);\n        document.removeEventListener('contextmenu', this, true);\n    };\n    /**\n     * Show the overlay indicator at the given client position.\n     *\n     * Returns the drop zone at the specified client position.\n     *\n     * #### Notes\n     * If the position is not over a valid zone, the overlay is hidden.\n     */\n    DockPanel.prototype._showOverlay = function (clientX, clientY) {\n        // Find the dock target for the given client position.\n        var _a = Private$a.findDropTarget(this, clientX, clientY, this._edges), zone = _a.zone, target = _a.target;\n        // If the drop zone is invalid, hide the overlay and bail.\n        if (zone === 'invalid') {\n            this.overlay.hide(100);\n            return zone;\n        }\n        // Setup the variables needed to compute the overlay geometry.\n        var top;\n        var left;\n        var right;\n        var bottom;\n        var box = ElementExt.boxSizing(this.node); // TODO cache this?\n        var rect = this.node.getBoundingClientRect();\n        // Compute the overlay geometry based on the dock zone.\n        switch (zone) {\n            case 'root-all':\n                top = box.paddingTop;\n                left = box.paddingLeft;\n                right = box.paddingRight;\n                bottom = box.paddingBottom;\n                break;\n            case 'root-top':\n                top = box.paddingTop;\n                left = box.paddingLeft;\n                right = box.paddingRight;\n                bottom = rect.height * Private$a.GOLDEN_RATIO;\n                break;\n            case 'root-left':\n                top = box.paddingTop;\n                left = box.paddingLeft;\n                right = rect.width * Private$a.GOLDEN_RATIO;\n                bottom = box.paddingBottom;\n                break;\n            case 'root-right':\n                top = box.paddingTop;\n                left = rect.width * Private$a.GOLDEN_RATIO;\n                right = box.paddingRight;\n                bottom = box.paddingBottom;\n                break;\n            case 'root-bottom':\n                top = rect.height * Private$a.GOLDEN_RATIO;\n                left = box.paddingLeft;\n                right = box.paddingRight;\n                bottom = box.paddingBottom;\n                break;\n            case 'widget-all':\n                top = target.top;\n                left = target.left;\n                right = target.right;\n                bottom = target.bottom;\n                break;\n            case 'widget-top':\n                top = target.top;\n                left = target.left;\n                right = target.right;\n                bottom = target.bottom + target.height / 2;\n                break;\n            case 'widget-left':\n                top = target.top;\n                left = target.left;\n                right = target.right + target.width / 2;\n                bottom = target.bottom;\n                break;\n            case 'widget-right':\n                top = target.top;\n                left = target.left + target.width / 2;\n                right = target.right;\n                bottom = target.bottom;\n                break;\n            case 'widget-bottom':\n                top = target.top + target.height / 2;\n                left = target.left;\n                right = target.right;\n                bottom = target.bottom;\n                break;\n            case 'widget-tab':\n                var tabHeight = target.tabBar.node.getBoundingClientRect().height;\n                top = target.top;\n                left = target.left;\n                right = target.right;\n                bottom = target.bottom + target.height - tabHeight;\n                break;\n            default:\n                throw 'unreachable';\n        }\n        // Show the overlay with the computed geometry.\n        this.overlay.show({ top: top, left: left, right: right, bottom: bottom });\n        // Finally, return the computed drop zone.\n        return zone;\n    };\n    /**\n     * Create a new tab bar for use by the panel.\n     */\n    DockPanel.prototype._createTabBar = function () {\n        // Create the tab bar.\n        var tabBar = this._renderer.createTabBar();\n        // Set the generated tab bar property for the tab bar.\n        Private$a.isGeneratedTabBarProperty.set(tabBar, true);\n        // Hide the tab bar when in single document mode.\n        if (this._mode === 'single-document') {\n            tabBar.hide();\n        }\n        // Enforce necessary tab bar behavior.\n        // TODO do we really want to enforce *all* of these?\n        tabBar.tabsMovable = this._tabsMovable;\n        tabBar.allowDeselect = false;\n        tabBar.removeBehavior = 'select-previous-tab';\n        tabBar.insertBehavior = 'select-tab-if-needed';\n        // Connect the signal handlers for the tab bar.\n        tabBar.tabMoved.connect(this._onTabMoved, this);\n        tabBar.currentChanged.connect(this._onCurrentChanged, this);\n        tabBar.tabCloseRequested.connect(this._onTabCloseRequested, this);\n        tabBar.tabDetachRequested.connect(this._onTabDetachRequested, this);\n        tabBar.tabActivateRequested.connect(this._onTabActivateRequested, this);\n        // Return the initialized tab bar.\n        return tabBar;\n    };\n    /**\n     * Create a new handle for use by the panel.\n     */\n    DockPanel.prototype._createHandle = function () {\n        return this._renderer.createHandle();\n    };\n    /**\n     * Handle the `tabMoved` signal from a tab bar.\n     */\n    DockPanel.prototype._onTabMoved = function () {\n        MessageLoop.postMessage(this, Private$a.LayoutModified);\n    };\n    /**\n     * Handle the `currentChanged` signal from a tab bar.\n     */\n    DockPanel.prototype._onCurrentChanged = function (sender, args) {\n        // Extract the previous and current title from the args.\n        var previousTitle = args.previousTitle, currentTitle = args.currentTitle;\n        // Hide the previous widget.\n        if (previousTitle) {\n            previousTitle.owner.hide();\n        }\n        // Show the current widget.\n        if (currentTitle) {\n            currentTitle.owner.show();\n        }\n        // Flush the message loop on IE and Edge to prevent flicker.\n        if (Platform.IS_EDGE || Platform.IS_IE) {\n            MessageLoop.flush();\n        }\n        // Schedule an emit of the layout modified signal.\n        MessageLoop.postMessage(this, Private$a.LayoutModified);\n    };\n    /**\n     * Handle the `tabActivateRequested` signal from a tab bar.\n     */\n    DockPanel.prototype._onTabActivateRequested = function (sender, args) {\n        args.title.owner.activate();\n    };\n    /**\n     * Handle the `tabCloseRequested` signal from a tab bar.\n     */\n    DockPanel.prototype._onTabCloseRequested = function (sender, args) {\n        args.title.owner.close();\n    };\n    /**\n     * Handle the `tabDetachRequested` signal from a tab bar.\n     */\n    DockPanel.prototype._onTabDetachRequested = function (sender, args) {\n        var _this = this;\n        // Do nothing if a drag is already in progress.\n        if (this._drag) {\n            return;\n        }\n        // Release the tab bar's hold on the mouse.\n        sender.releaseMouse();\n        // Extract the data from the args.\n        var title = args.title, tab = args.tab, clientX = args.clientX, clientY = args.clientY;\n        // Setup the mime data for the drag operation.\n        var mimeData = new MimeData();\n        var factory = function () { return title.owner; };\n        mimeData.setData('application/vnd.lumino.widget-factory', factory);\n        // Create the drag image for the drag operation.\n        var dragImage = tab.cloneNode(true);\n        // Create the drag object to manage the drag-drop operation.\n        this._drag = new Drag({\n            mimeData: mimeData, dragImage: dragImage,\n            proposedAction: 'move',\n            supportedActions: 'move',\n            source: this\n        });\n        // Hide the tab node in the original tab.\n        tab.classList.add('lm-mod-hidden');\n        /* <DEPRECATED> */\n        tab.classList.add('p-mod-hidden');\n        // Create the cleanup callback.\n        var cleanup = (function () {\n            _this._drag = null;\n            tab.classList.remove('lm-mod-hidden');\n            /* <DEPRECATED> */\n            tab.classList.remove('p-mod-hidden');\n        });\n        // Start the drag operation and cleanup when done.\n        this._drag.start(clientX, clientY).then(cleanup);\n    };\n    return DockPanel;\n}(Widget));\n/**\n * The namespace for the `DockPanel` class statics.\n */\n(function (DockPanel) {\n    /**\n     * A concrete implementation of `IOverlay`.\n     *\n     * This is the default overlay implementation for a dock panel.\n     */\n    var Overlay = /** @class */ (function () {\n        /**\n         * Construct a new overlay.\n         */\n        function Overlay() {\n            this._timer = -1;\n            this._hidden = true;\n            this.node = document.createElement('div');\n            this.node.classList.add('lm-DockPanel-overlay');\n            this.node.classList.add('lm-mod-hidden');\n            /* <DEPRECATED> */\n            this.node.classList.add('p-DockPanel-overlay');\n            this.node.classList.add('p-mod-hidden');\n            this.node.style.position = 'absolute';\n        }\n        /**\n         * Show the overlay using the given overlay geometry.\n         *\n         * @param geo - The desired geometry for the overlay.\n         */\n        Overlay.prototype.show = function (geo) {\n            // Update the position of the overlay.\n            var style = this.node.style;\n            style.top = geo.top + \"px\";\n            style.left = geo.left + \"px\";\n            style.right = geo.right + \"px\";\n            style.bottom = geo.bottom + \"px\";\n            // Clear any pending hide timer.\n            clearTimeout(this._timer);\n            this._timer = -1;\n            // If the overlay is already visible, we're done.\n            if (!this._hidden) {\n                return;\n            }\n            // Clear the hidden flag.\n            this._hidden = false;\n            // Finally, show the overlay.\n            this.node.classList.remove('lm-mod-hidden');\n            /* <DEPRECATED> */\n            this.node.classList.remove('p-mod-hidden');\n        };\n        /**\n         * Hide the overlay node.\n         *\n         * @param delay - The delay (in ms) before hiding the overlay.\n         *   A delay value <= 0 will hide the overlay immediately.\n         */\n        Overlay.prototype.hide = function (delay) {\n            var _this = this;\n            // Do nothing if the overlay is already hidden.\n            if (this._hidden) {\n                return;\n            }\n            // Hide immediately if the delay is <= 0.\n            if (delay <= 0) {\n                clearTimeout(this._timer);\n                this._timer = -1;\n                this._hidden = true;\n                this.node.classList.add('lm-mod-hidden');\n                /* <DEPRECATED> */\n                this.node.classList.add('p-mod-hidden');\n                return;\n            }\n            // Do nothing if a hide is already pending.\n            if (this._timer !== -1) {\n                return;\n            }\n            // Otherwise setup the hide timer.\n            this._timer = window.setTimeout(function () {\n                _this._timer = -1;\n                _this._hidden = true;\n                _this.node.classList.add('lm-mod-hidden');\n                /* <DEPRECATED> */\n                _this.node.classList.add('p-mod-hidden');\n            }, delay);\n        };\n        return Overlay;\n    }());\n    DockPanel.Overlay = Overlay;\n    /**\n     * The default implementation of `IRenderer`.\n     */\n    var Renderer = /** @class */ (function () {\n        function Renderer() {\n        }\n        /**\n         * Create a new tab bar for use with a dock panel.\n         *\n         * @returns A new tab bar for a dock panel.\n         */\n        Renderer.prototype.createTabBar = function () {\n            var bar = new TabBar();\n            bar.addClass('lm-DockPanel-tabBar');\n            /* <DEPRECATED> */\n            bar.addClass('p-DockPanel-tabBar');\n            /* </DEPRECATED> */\n            return bar;\n        };\n        /**\n         * Create a new handle node for use with a dock panel.\n         *\n         * @returns A new handle node for a dock panel.\n         */\n        Renderer.prototype.createHandle = function () {\n            var handle = document.createElement('div');\n            handle.className = 'lm-DockPanel-handle';\n            /* <DEPRECATED> */\n            handle.classList.add('p-DockPanel-handle');\n            return handle;\n        };\n        return Renderer;\n    }());\n    DockPanel.Renderer = Renderer;\n    /**\n     * The default `Renderer` instance.\n     */\n    DockPanel.defaultRenderer = new Renderer();\n})(DockPanel || (DockPanel = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$a;\n(function (Private) {\n    /**\n     * A fraction used for sizing root panels; ~= `1 / golden_ratio`.\n     */\n    Private.GOLDEN_RATIO = 0.618;\n    /**\n     * The default sizes for the edge drop zones, in pixels.\n     */\n    Private.DEFAULT_EDGES = {\n        /**\n         * The size of the top edge dock zone for the root panel, in pixels.\n         * This is different from the others to distinguish between the top\n         * tab bar and the top root zone.\n         */\n        top: 12,\n        /**\n         * The size of the edge dock zone for the root panel, in pixels.\n         */\n        right: 40,\n        /**\n         * The size of the edge dock zone for the root panel, in pixels.\n         */\n        bottom: 40,\n        /**\n         * The size of the edge dock zone for the root panel, in pixels.\n         */\n        left: 40\n    };\n    /**\n     * A singleton `'layout-modified'` conflatable message.\n     */\n    Private.LayoutModified = new ConflatableMessage('layout-modified');\n    /**\n     * An attached property used to track generated tab bars.\n     */\n    Private.isGeneratedTabBarProperty = new AttachedProperty({\n        name: 'isGeneratedTabBar',\n        create: function () { return false; }\n    });\n    /**\n     * Create a single document config for the widgets in a dock panel.\n     */\n    function createSingleDocumentConfig(panel) {\n        // Return an empty config if the panel is empty.\n        if (panel.isEmpty) {\n            return { main: null };\n        }\n        // Get a flat array of the widgets in the panel.\n        var widgets = toArray(panel.widgets());\n        // Get the first selected widget in the panel.\n        var selected = panel.selectedWidgets().next();\n        // Compute the current index for the new config.\n        var currentIndex = selected ? widgets.indexOf(selected) : -1;\n        // Return the single document config.\n        return { main: { type: 'tab-area', widgets: widgets, currentIndex: currentIndex } };\n    }\n    Private.createSingleDocumentConfig = createSingleDocumentConfig;\n    /**\n     * Find the drop target at the given client position.\n     */\n    function findDropTarget(panel, clientX, clientY, edges) {\n        // Bail if the mouse is not over the dock panel.\n        if (!ElementExt.hitTest(panel.node, clientX, clientY)) {\n            return { zone: 'invalid', target: null };\n        }\n        // Look up the layout for the panel.\n        var layout = panel.layout;\n        // If the layout is empty, indicate the entire root drop zone.\n        if (layout.isEmpty) {\n            return { zone: 'root-all', target: null };\n        }\n        // Test the edge zones when in multiple document mode.\n        if (panel.mode === 'multiple-document') {\n            // Get the client rect for the dock panel.\n            var panelRect = panel.node.getBoundingClientRect();\n            // Compute the distance to each edge of the panel.\n            var pl = clientX - panelRect.left + 1;\n            var pt = clientY - panelRect.top + 1;\n            var pr = panelRect.right - clientX;\n            var pb = panelRect.bottom - clientY;\n            // Find the minimum distance to an edge.\n            var pd = Math.min(pt, pr, pb, pl);\n            // Return a root zone if the mouse is within an edge.\n            switch (pd) {\n                case pt:\n                    if (pt < edges.top) {\n                        return { zone: 'root-top', target: null };\n                    }\n                    break;\n                case pr:\n                    if (pr < edges.right) {\n                        return { zone: 'root-right', target: null };\n                    }\n                    break;\n                case pb:\n                    if (pb < edges.bottom) {\n                        return { zone: 'root-bottom', target: null };\n                    }\n                    break;\n                case pl:\n                    if (pl < edges.left) {\n                        return { zone: 'root-left', target: null };\n                    }\n                    break;\n                default:\n                    throw 'unreachable';\n            }\n        }\n        // Hit test the dock layout at the given client position.\n        var target = layout.hitTestTabAreas(clientX, clientY);\n        // Bail if no target area was found.\n        if (!target) {\n            return { zone: 'invalid', target: null };\n        }\n        // Return the whole tab area when in single document mode.\n        if (panel.mode === 'single-document') {\n            return { zone: 'widget-all', target: target };\n        }\n        // Compute the distance to each edge of the tab area.\n        var al = target.x - target.left + 1;\n        var at = target.y - target.top + 1;\n        var ar = target.left + target.width - target.x;\n        var ab = target.top + target.height - target.y;\n        var tabHeight = target.tabBar.node.getBoundingClientRect().height;\n        if (at < tabHeight) {\n            return { zone: 'widget-tab', target: target };\n        }\n        // Get the X and Y edge sizes for the area.\n        var rx = Math.round(target.width / 3);\n        var ry = Math.round(target.height / 3);\n        // If the mouse is not within an edge, indicate the entire area.\n        if (al > rx && ar > rx && at > ry && ab > ry) {\n            return { zone: 'widget-all', target: target };\n        }\n        // Scale the distances by the slenderness ratio.\n        al /= rx;\n        at /= ry;\n        ar /= rx;\n        ab /= ry;\n        // Find the minimum distance to the area edge.\n        var ad = Math.min(al, at, ar, ab);\n        // Find the widget zone for the area edge.\n        var zone;\n        switch (ad) {\n            case al:\n                zone = 'widget-left';\n                break;\n            case at:\n                zone = 'widget-top';\n                break;\n            case ar:\n                zone = 'widget-right';\n                break;\n            case ab:\n                zone = 'widget-bottom';\n                break;\n            default:\n                throw 'unreachable';\n        }\n        // Return the final drop target.\n        return { zone: zone, target: target };\n    }\n    Private.findDropTarget = findDropTarget;\n    /**\n     * Get the drop reference widget for a tab bar.\n     */\n    function getDropRef(tabBar) {\n        if (tabBar.titles.length === 0) {\n            return null;\n        }\n        if (tabBar.currentTitle) {\n            return tabBar.currentTitle.owner;\n        }\n        return tabBar.titles[tabBar.titles.length - 1].owner;\n    }\n    Private.getDropRef = getDropRef;\n})(Private$a || (Private$a = {}));\n\n// Copyright (c) Jupyter Development Team.\n/**\n * A class which tracks focus among a set of widgets.\n *\n * This class is useful when code needs to keep track of the most\n * recently focused widget(s) among a set of related widgets.\n */\nvar FocusTracker = /** @class */ (function () {\n    /**\n     * Construct a new focus tracker.\n     */\n    function FocusTracker() {\n        this._counter = 0;\n        this._widgets = [];\n        this._activeWidget = null;\n        this._currentWidget = null;\n        this._numbers = new Map();\n        this._nodes = new Map();\n        this._activeChanged = new Signal(this);\n        this._currentChanged = new Signal(this);\n    }\n    /**\n     * Dispose of the resources held by the tracker.\n     */\n    FocusTracker.prototype.dispose = function () {\n        var _this = this;\n        // Do nothing if the tracker is already disposed.\n        if (this._counter < 0) {\n            return;\n        }\n        // Mark the tracker as disposed.\n        this._counter = -1;\n        // Clear the connections for the tracker.\n        Signal.clearData(this);\n        // Remove all event listeners.\n        each(this._widgets, function (w) {\n            w.node.removeEventListener('focus', _this, true);\n            w.node.removeEventListener('blur', _this, true);\n        });\n        // Clear the internal data structures.\n        this._activeWidget = null;\n        this._currentWidget = null;\n        this._nodes.clear();\n        this._numbers.clear();\n        this._widgets.length = 0;\n    };\n    Object.defineProperty(FocusTracker.prototype, \"currentChanged\", {\n        /**\n         * A signal emitted when the current widget has changed.\n         */\n        get: function () {\n            return this._currentChanged;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(FocusTracker.prototype, \"activeChanged\", {\n        /**\n         * A signal emitted when the active widget has changed.\n         */\n        get: function () {\n            return this._activeChanged;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(FocusTracker.prototype, \"isDisposed\", {\n        /**\n         * A flag indicating whether the tracker is disposed.\n         */\n        get: function () {\n            return this._counter < 0;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(FocusTracker.prototype, \"currentWidget\", {\n        /**\n         * The current widget in the tracker.\n         *\n         * #### Notes\n         * The current widget is the widget among the tracked widgets which\n         * has the *descendant node* which has most recently been focused.\n         *\n         * The current widget will not be updated if the node loses focus. It\n         * will only be updated when a different tracked widget gains focus.\n         *\n         * If the current widget is removed from the tracker, the previous\n         * current widget will be restored.\n         *\n         * This behavior is intended to follow a user's conceptual model of\n         * a semantically \"current\" widget, where the \"last thing of type X\"\n         * to be interacted with is the \"current instance of X\", regardless\n         * of whether that instance still has focus.\n         */\n        get: function () {\n            return this._currentWidget;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(FocusTracker.prototype, \"activeWidget\", {\n        /**\n         * The active widget in the tracker.\n         *\n         * #### Notes\n         * The active widget is the widget among the tracked widgets which\n         * has the *descendant node* which is currently focused.\n         */\n        get: function () {\n            return this._activeWidget;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(FocusTracker.prototype, \"widgets\", {\n        /**\n         * A read only array of the widgets being tracked.\n         */\n        get: function () {\n            return this._widgets;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Get the focus number for a particular widget in the tracker.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @returns The focus number for the given widget, or `-1` if the\n     *   widget has not had focus since being added to the tracker, or\n     *   is not contained by the tracker.\n     *\n     * #### Notes\n     * The focus number indicates the relative order in which the widgets\n     * have gained focus. A widget with a larger number has gained focus\n     * more recently than a widget with a smaller number.\n     *\n     * The `currentWidget` will always have the largest focus number.\n     *\n     * All widgets start with a focus number of `-1`, which indicates that\n     * the widget has not been focused since being added to the tracker.\n     */\n    FocusTracker.prototype.focusNumber = function (widget) {\n        var n = this._numbers.get(widget);\n        return n === undefined ? -1 : n;\n    };\n    /**\n     * Test whether the focus tracker contains a given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @returns `true` if the widget is tracked, `false` otherwise.\n     */\n    FocusTracker.prototype.has = function (widget) {\n        return this._numbers.has(widget);\n    };\n    /**\n     * Add a widget to the focus tracker.\n     *\n     * @param widget - The widget of interest.\n     *\n     * #### Notes\n     * A widget will be automatically removed from the tracker if it\n     * is disposed after being added.\n     *\n     * If the widget is already tracked, this is a no-op.\n     */\n    FocusTracker.prototype.add = function (widget) {\n        // Do nothing if the widget is already tracked.\n        if (this._numbers.has(widget)) {\n            return;\n        }\n        // Test whether the widget has focus.\n        var focused = widget.node.contains(document.activeElement);\n        // Set up the initial focus number.\n        var n = focused ? this._counter++ : -1;\n        // Add the widget to the internal data structures.\n        this._widgets.push(widget);\n        this._numbers.set(widget, n);\n        this._nodes.set(widget.node, widget);\n        // Set up the event listeners. The capturing phase must be used\n        // since the 'focus' and 'blur' events don't bubble and Firefox\n        // doesn't support the 'focusin' or 'focusout' events.\n        widget.node.addEventListener('focus', this, true);\n        widget.node.addEventListener('blur', this, true);\n        // Connect the disposed signal handler.\n        widget.disposed.connect(this._onWidgetDisposed, this);\n        // Set the current and active widgets if needed.\n        if (focused) {\n            this._setWidgets(widget, widget);\n        }\n    };\n    /**\n     * Remove a widget from the focus tracker.\n     *\n     * #### Notes\n     * If the widget is the `currentWidget`, the previous current widget\n     * will become the new `currentWidget`.\n     *\n     * A widget will be automatically removed from the tracker if it\n     * is disposed after being added.\n     *\n     * If the widget is not tracked, this is a no-op.\n     */\n    FocusTracker.prototype.remove = function (widget) {\n        var _this = this;\n        // Bail early if the widget is not tracked.\n        if (!this._numbers.has(widget)) {\n            return;\n        }\n        // Disconnect the disposed signal handler.\n        widget.disposed.disconnect(this._onWidgetDisposed, this);\n        // Remove the event listeners.\n        widget.node.removeEventListener('focus', this, true);\n        widget.node.removeEventListener('blur', this, true);\n        // Remove the widget from the internal data structures.\n        ArrayExt.removeFirstOf(this._widgets, widget);\n        this._nodes.delete(widget.node);\n        this._numbers.delete(widget);\n        // Bail early if the widget is not the current widget.\n        if (this._currentWidget !== widget) {\n            return;\n        }\n        // Filter the widgets for those which have had focus.\n        var valid = filter(this._widgets, function (w) { return _this._numbers.get(w) !== -1; });\n        // Get the valid widget with the max focus number.\n        var previous = max(valid, function (first, second) {\n            var a = _this._numbers.get(first);\n            var b = _this._numbers.get(second);\n            return a - b;\n        }) || null;\n        // Set the current and active widgets.\n        this._setWidgets(previous, null);\n    };\n    /**\n     * Handle the DOM events for the focus tracker.\n     *\n     * @param event - The DOM event sent to the panel.\n     *\n     * #### Notes\n     * This method implements the DOM `EventListener` interface and is\n     * called in response to events on the tracked nodes. It should\n     * not be called directly by user code.\n     */\n    FocusTracker.prototype.handleEvent = function (event) {\n        switch (event.type) {\n            case 'focus':\n                this._evtFocus(event);\n                break;\n            case 'blur':\n                this._evtBlur(event);\n                break;\n        }\n    };\n    /**\n     * Set the current and active widgets for the tracker.\n     */\n    FocusTracker.prototype._setWidgets = function (current, active) {\n        // Swap the current widget.\n        var oldCurrent = this._currentWidget;\n        this._currentWidget = current;\n        // Swap the active widget.\n        var oldActive = this._activeWidget;\n        this._activeWidget = active;\n        // Emit the `currentChanged` signal if needed.\n        if (oldCurrent !== current) {\n            this._currentChanged.emit({ oldValue: oldCurrent, newValue: current });\n        }\n        // Emit the `activeChanged` signal if needed.\n        if (oldActive !== active) {\n            this._activeChanged.emit({ oldValue: oldActive, newValue: active });\n        }\n    };\n    /**\n     * Handle the `'focus'` event for a tracked widget.\n     */\n    FocusTracker.prototype._evtFocus = function (event) {\n        // Find the widget which gained focus, which is known to exist.\n        var widget = this._nodes.get(event.currentTarget);\n        // Update the focus number if necessary.\n        if (widget !== this._currentWidget) {\n            this._numbers.set(widget, this._counter++);\n        }\n        // Set the current and active widgets.\n        this._setWidgets(widget, widget);\n    };\n    /**\n     * Handle the `'blur'` event for a tracked widget.\n     */\n    FocusTracker.prototype._evtBlur = function (event) {\n        // Find the widget which lost focus, which is known to exist.\n        var widget = this._nodes.get(event.currentTarget);\n        // Get the node which being focused after this blur.\n        var focusTarget = event.relatedTarget;\n        // If no other node is being focused, clear the active widget.\n        if (!focusTarget) {\n            this._setWidgets(this._currentWidget, null);\n            return;\n        }\n        // Bail if the focus widget is not changing.\n        if (widget.node.contains(focusTarget)) {\n            return;\n        }\n        // If no tracked widget is being focused, clear the active widget.\n        if (!find(this._widgets, function (w) { return w.node.contains(focusTarget); })) {\n            this._setWidgets(this._currentWidget, null);\n            return;\n        }\n    };\n    /**\n     * Handle the `disposed` signal for a tracked widget.\n     */\n    FocusTracker.prototype._onWidgetDisposed = function (sender) {\n        this.remove(sender);\n    };\n    return FocusTracker;\n}());\n\n/**\n * A layout which arranges its widgets in a grid.\n */\nvar GridLayout = /** @class */ (function (_super) {\n    __extends(GridLayout, _super);\n    /**\n     * Construct a new grid layout.\n     *\n     * @param options - The options for initializing the layout.\n     */\n    function GridLayout(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this, options) || this;\n        _this._dirty = false;\n        _this._rowSpacing = 4;\n        _this._columnSpacing = 4;\n        _this._items = [];\n        _this._rowStarts = [];\n        _this._columnStarts = [];\n        _this._rowSizers = [new BoxSizer()];\n        _this._columnSizers = [new BoxSizer()];\n        _this._box = null;\n        if (options.rowCount !== undefined) {\n            Private$b.reallocSizers(_this._rowSizers, options.rowCount);\n        }\n        if (options.columnCount !== undefined) {\n            Private$b.reallocSizers(_this._columnSizers, options.columnCount);\n        }\n        if (options.rowSpacing !== undefined) {\n            _this._rowSpacing = Private$b.clampValue(options.rowSpacing);\n        }\n        if (options.columnSpacing !== undefined) {\n            _this._columnSpacing = Private$b.clampValue(options.columnSpacing);\n        }\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the layout.\n     */\n    GridLayout.prototype.dispose = function () {\n        // Dispose of the widgets and layout items.\n        each(this._items, function (item) {\n            var widget = item.widget;\n            item.dispose();\n            widget.dispose();\n        });\n        // Clear the layout state.\n        this._box = null;\n        this._items.length = 0;\n        this._rowStarts.length = 0;\n        this._rowSizers.length = 0;\n        this._columnStarts.length = 0;\n        this._columnSizers.length = 0;\n        // Dispose of the rest of the layout.\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(GridLayout.prototype, \"rowCount\", {\n        /**\n         * Get the number of rows in the layout.\n         */\n        get: function () {\n            return this._rowSizers.length;\n        },\n        /**\n         * Set the number of rows in the layout.\n         *\n         * #### Notes\n         * The minimum row count is `1`.\n         */\n        set: function (value) {\n            // Do nothing if the row count does not change.\n            if (value === this.rowCount) {\n                return;\n            }\n            // Reallocate the row sizers.\n            Private$b.reallocSizers(this._rowSizers, value);\n            // Schedule a fit of the parent.\n            if (this.parent) {\n                this.parent.fit();\n            }\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(GridLayout.prototype, \"columnCount\", {\n        /**\n         * Get the number of columns in the layout.\n         */\n        get: function () {\n            return this._columnSizers.length;\n        },\n        /**\n         * Set the number of columns in the layout.\n         *\n         * #### Notes\n         * The minimum column count is `1`.\n         */\n        set: function (value) {\n            // Do nothing if the column count does not change.\n            if (value === this.columnCount) {\n                return;\n            }\n            // Reallocate the column sizers.\n            Private$b.reallocSizers(this._columnSizers, value);\n            // Schedule a fit of the parent.\n            if (this.parent) {\n                this.parent.fit();\n            }\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(GridLayout.prototype, \"rowSpacing\", {\n        /**\n         * Get the row spacing for the layout.\n         */\n        get: function () {\n            return this._rowSpacing;\n        },\n        /**\n         * Set the row spacing for the layout.\n         */\n        set: function (value) {\n            // Clamp the spacing to the allowed range.\n            value = Private$b.clampValue(value);\n            // Bail if the spacing does not change\n            if (this._rowSpacing === value) {\n                return;\n            }\n            // Update the internal spacing.\n            this._rowSpacing = value;\n            // Schedule a fit of the parent.\n            if (this.parent) {\n                this.parent.fit();\n            }\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(GridLayout.prototype, \"columnSpacing\", {\n        /**\n         * Get the column spacing for the layout.\n         */\n        get: function () {\n            return this._columnSpacing;\n        },\n        /**\n         * Set the col spacing for the layout.\n         */\n        set: function (value) {\n            // Clamp the spacing to the allowed range.\n            value = Private$b.clampValue(value);\n            // Bail if the spacing does not change\n            if (this._columnSpacing === value) {\n                return;\n            }\n            // Update the internal spacing.\n            this._columnSpacing = value;\n            // Schedule a fit of the parent.\n            if (this.parent) {\n                this.parent.fit();\n            }\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Get the stretch factor for a specific row.\n     *\n     * @param index - The row index of interest.\n     *\n     * @returns The stretch factor for the row.\n     *\n     * #### Notes\n     * This returns `-1` if the index is out of range.\n     */\n    GridLayout.prototype.rowStretch = function (index) {\n        var sizer = this._rowSizers[index];\n        return sizer ? sizer.stretch : -1;\n    };\n    /**\n     * Set the stretch factor for a specific row.\n     *\n     * @param index - The row index of interest.\n     *\n     * @param value - The stretch factor for the row.\n     *\n     * #### Notes\n     * This is a no-op if the index is out of range.\n     */\n    GridLayout.prototype.setRowStretch = function (index, value) {\n        // Look up the row sizer.\n        var sizer = this._rowSizers[index];\n        // Bail if the index is out of range.\n        if (!sizer) {\n            return;\n        }\n        // Clamp the value to the allowed range.\n        value = Private$b.clampValue(value);\n        // Bail if the stretch does not change.\n        if (sizer.stretch === value) {\n            return;\n        }\n        // Update the sizer stretch.\n        sizer.stretch = value;\n        // Schedule an update of the parent.\n        if (this.parent) {\n            this.parent.update();\n        }\n    };\n    /**\n     * Get the stretch factor for a specific column.\n     *\n     * @param index - The column index of interest.\n     *\n     * @returns The stretch factor for the column.\n     *\n     * #### Notes\n     * This returns `-1` if the index is out of range.\n     */\n    GridLayout.prototype.columnStretch = function (index) {\n        var sizer = this._columnSizers[index];\n        return sizer ? sizer.stretch : -1;\n    };\n    /**\n     * Set the stretch factor for a specific column.\n     *\n     * @param index - The column index of interest.\n     *\n     * @param value - The stretch factor for the column.\n     *\n     * #### Notes\n     * This is a no-op if the index is out of range.\n     */\n    GridLayout.prototype.setColumnStretch = function (index, value) {\n        // Look up the column sizer.\n        var sizer = this._columnSizers[index];\n        // Bail if the index is out of range.\n        if (!sizer) {\n            return;\n        }\n        // Clamp the value to the allowed range.\n        value = Private$b.clampValue(value);\n        // Bail if the stretch does not change.\n        if (sizer.stretch === value) {\n            return;\n        }\n        // Update the sizer stretch.\n        sizer.stretch = value;\n        // Schedule an update of the parent.\n        if (this.parent) {\n            this.parent.update();\n        }\n    };\n    /**\n     * Create an iterator over the widgets in the layout.\n     *\n     * @returns A new iterator over the widgets in the layout.\n     */\n    GridLayout.prototype.iter = function () {\n        return map(this._items, function (item) { return item.widget; });\n    };\n    /**\n     * Add a widget to the grid layout.\n     *\n     * @param widget - The widget to add to the layout.\n     *\n     * #### Notes\n     * If the widget is already contained in the layout, this is no-op.\n     */\n    GridLayout.prototype.addWidget = function (widget) {\n        // Look up the index for the widget.\n        var i = ArrayExt.findFirstIndex(this._items, function (it) { return it.widget === widget; });\n        // Bail if the widget is already in the layout.\n        if (i !== -1) {\n            return;\n        }\n        // Add the widget to the layout.\n        this._items.push(new LayoutItem(widget));\n        // Attach the widget to the parent.\n        if (this.parent) {\n            this.attachWidget(widget);\n        }\n    };\n    /**\n     * Remove a widget from the grid layout.\n     *\n     * @param widget - The widget to remove from the layout.\n     *\n     * #### Notes\n     * A widget is automatically removed from the layout when its `parent`\n     * is set to `null`. This method should only be invoked directly when\n     * removing a widget from a layout which has yet to be installed on a\n     * parent widget.\n     *\n     * This method does *not* modify the widget's `parent`.\n     */\n    GridLayout.prototype.removeWidget = function (widget) {\n        // Look up the index for the widget.\n        var i = ArrayExt.findFirstIndex(this._items, function (it) { return it.widget === widget; });\n        // Bail if the widget is not in the layout.\n        if (i === -1) {\n            return;\n        }\n        // Remove the widget from the layout.\n        var item = ArrayExt.removeAt(this._items, i);\n        // Detach the widget from the parent.\n        if (this.parent) {\n            this.detachWidget(widget);\n        }\n        // Dispose the layout item.\n        item.dispose();\n    };\n    /**\n     * Perform layout initialization which requires the parent widget.\n     */\n    GridLayout.prototype.init = function () {\n        var _this = this;\n        _super.prototype.init.call(this);\n        each(this, function (widget) { _this.attachWidget(widget); });\n    };\n    /**\n     * Attach a widget to the parent's DOM node.\n     *\n     * @param widget - The widget to attach to the parent.\n     */\n    GridLayout.prototype.attachWidget = function (widget) {\n        // Send a `'before-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeAttach);\n        }\n        // Add the widget's node to the parent.\n        this.parent.node.appendChild(widget.node);\n        // Send an `'after-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterAttach);\n        }\n        // Post a fit request for the parent widget.\n        this.parent.fit();\n    };\n    /**\n     * Detach a widget from the parent's DOM node.\n     *\n     * @param widget - The widget to detach from the parent.\n     */\n    GridLayout.prototype.detachWidget = function (widget) {\n        // Send a `'before-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeDetach);\n        }\n        // Remove the widget's node from the parent.\n        this.parent.node.removeChild(widget.node);\n        // Send an `'after-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterDetach);\n        }\n        // Post a fit request for the parent widget.\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'before-show'` message.\n     */\n    GridLayout.prototype.onBeforeShow = function (msg) {\n        _super.prototype.onBeforeShow.call(this, msg);\n        this.parent.update();\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     */\n    GridLayout.prototype.onBeforeAttach = function (msg) {\n        _super.prototype.onBeforeAttach.call(this, msg);\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'child-shown'` message.\n     */\n    GridLayout.prototype.onChildShown = function (msg) {\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'child-hidden'` message.\n     */\n    GridLayout.prototype.onChildHidden = function (msg) {\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'resize'` message.\n     */\n    GridLayout.prototype.onResize = function (msg) {\n        if (this.parent.isVisible) {\n            this._update(msg.width, msg.height);\n        }\n    };\n    /**\n     * A message handler invoked on an `'update-request'` message.\n     */\n    GridLayout.prototype.onUpdateRequest = function (msg) {\n        if (this.parent.isVisible) {\n            this._update(-1, -1);\n        }\n    };\n    /**\n     * A message handler invoked on a `'fit-request'` message.\n     */\n    GridLayout.prototype.onFitRequest = function (msg) {\n        if (this.parent.isAttached) {\n            this._fit();\n        }\n    };\n    /**\n     * Fit the layout to the total size required by the widgets.\n     */\n    GridLayout.prototype._fit = function () {\n        // Reset the min sizes of the sizers.\n        for (var i = 0, n = this.rowCount; i < n; ++i) {\n            this._rowSizers[i].minSize = 0;\n        }\n        for (var i = 0, n = this.columnCount; i < n; ++i) {\n            this._columnSizers[i].minSize = 0;\n        }\n        // Filter for the visible layout items.\n        var items = this._items.filter(function (it) { return !it.isHidden; });\n        // Fit the layout items.\n        for (var i = 0, n = items.length; i < n; ++i) {\n            items[i].fit();\n        }\n        // Get the max row and column index.\n        var maxRow = this.rowCount - 1;\n        var maxCol = this.columnCount - 1;\n        // Sort the items by row span.\n        items.sort(Private$b.rowSpanCmp);\n        // Update the min sizes of the row sizers.\n        for (var i = 0, n = items.length; i < n; ++i) {\n            // Fetch the item.\n            var item = items[i];\n            // Get the row bounds for the item.\n            var config = GridLayout.getCellConfig(item.widget);\n            var r1 = Math.min(config.row, maxRow);\n            var r2 = Math.min(config.row + config.rowSpan - 1, maxRow);\n            // Distribute the minimum height to the sizers as needed.\n            Private$b.distributeMin(this._rowSizers, r1, r2, item.minHeight);\n        }\n        // Sort the items by column span.\n        items.sort(Private$b.columnSpanCmp);\n        // Update the min sizes of the column sizers.\n        for (var i = 0, n = items.length; i < n; ++i) {\n            // Fetch the item.\n            var item = items[i];\n            // Get the column bounds for the item.\n            var config = GridLayout.getCellConfig(item.widget);\n            var c1 = Math.min(config.column, maxCol);\n            var c2 = Math.min(config.column + config.columnSpan - 1, maxCol);\n            // Distribute the minimum width to the sizers as needed.\n            Private$b.distributeMin(this._columnSizers, c1, c2, item.minWidth);\n        }\n        // If no size constraint is needed, just update the parent.\n        if (this.fitPolicy === 'set-no-constraint') {\n            MessageLoop.sendMessage(this.parent, Widget.Msg.UpdateRequest);\n            return;\n        }\n        // Set up the computed min size.\n        var minH = maxRow * this._rowSpacing;\n        var minW = maxCol * this._columnSpacing;\n        // Add the sizer minimums to the computed min size.\n        for (var i = 0, n = this.rowCount; i < n; ++i) {\n            minH += this._rowSizers[i].minSize;\n        }\n        for (var i = 0, n = this.columnCount; i < n; ++i) {\n            minW += this._columnSizers[i].minSize;\n        }\n        // Update the box sizing and add it to the computed min size.\n        var box = this._box = ElementExt.boxSizing(this.parent.node);\n        minW += box.horizontalSum;\n        minH += box.verticalSum;\n        // Update the parent's min size constraints.\n        var style = this.parent.node.style;\n        style.minWidth = minW + \"px\";\n        style.minHeight = minH + \"px\";\n        // Set the dirty flag to ensure only a single update occurs.\n        this._dirty = true;\n        // Notify the ancestor that it should fit immediately. This may\n        // cause a resize of the parent, fulfilling the required update.\n        if (this.parent.parent) {\n            MessageLoop.sendMessage(this.parent.parent, Widget.Msg.FitRequest);\n        }\n        // If the dirty flag is still set, the parent was not resized.\n        // Trigger the required update on the parent widget immediately.\n        if (this._dirty) {\n            MessageLoop.sendMessage(this.parent, Widget.Msg.UpdateRequest);\n        }\n    };\n    /**\n     * Update the layout position and size of the widgets.\n     *\n     * The parent offset dimensions should be `-1` if unknown.\n     */\n    GridLayout.prototype._update = function (offsetWidth, offsetHeight) {\n        // Clear the dirty flag to indicate the update occurred.\n        this._dirty = false;\n        // Measure the parent if the offset dimensions are unknown.\n        if (offsetWidth < 0) {\n            offsetWidth = this.parent.node.offsetWidth;\n        }\n        if (offsetHeight < 0) {\n            offsetHeight = this.parent.node.offsetHeight;\n        }\n        // Ensure the parent box sizing data is computed.\n        if (!this._box) {\n            this._box = ElementExt.boxSizing(this.parent.node);\n        }\n        // Compute the layout area adjusted for border and padding.\n        var top = this._box.paddingTop;\n        var left = this._box.paddingLeft;\n        var width = offsetWidth - this._box.horizontalSum;\n        var height = offsetHeight - this._box.verticalSum;\n        // Get the max row and column index.\n        var maxRow = this.rowCount - 1;\n        var maxCol = this.columnCount - 1;\n        // Compute the total fixed row and column space.\n        var fixedRowSpace = maxRow * this._rowSpacing;\n        var fixedColSpace = maxCol * this._columnSpacing;\n        // Distribute the available space to the box sizers.\n        BoxEngine.calc(this._rowSizers, Math.max(0, height - fixedRowSpace));\n        BoxEngine.calc(this._columnSizers, Math.max(0, width - fixedColSpace));\n        // Update the row start positions.\n        for (var i = 0, pos = top, n = this.rowCount; i < n; ++i) {\n            this._rowStarts[i] = pos;\n            pos += this._rowSizers[i].size + this._rowSpacing;\n        }\n        // Update the column start positions.\n        for (var i = 0, pos = left, n = this.columnCount; i < n; ++i) {\n            this._columnStarts[i] = pos;\n            pos += this._columnSizers[i].size + this._columnSpacing;\n        }\n        // Update the geometry of the layout items.\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            // Fetch the item.\n            var item = this._items[i];\n            // Ignore hidden items.\n            if (item.isHidden) {\n                continue;\n            }\n            // Fetch the cell bounds for the widget.\n            var config = GridLayout.getCellConfig(item.widget);\n            var r1 = Math.min(config.row, maxRow);\n            var c1 = Math.min(config.column, maxCol);\n            var r2 = Math.min(config.row + config.rowSpan - 1, maxRow);\n            var c2 = Math.min(config.column + config.columnSpan - 1, maxCol);\n            // Compute the cell geometry.\n            var x = this._columnStarts[c1];\n            var y = this._rowStarts[r1];\n            var w = this._columnStarts[c2] + this._columnSizers[c2].size - x;\n            var h = this._rowStarts[r2] + this._rowSizers[r2].size - y;\n            // Update the geometry of the layout item.\n            item.update(x, y, w, h);\n        }\n    };\n    return GridLayout;\n}(Layout));\n/**\n * The namespace for the `GridLayout` class statics.\n */\n(function (GridLayout) {\n    /**\n     * Get the cell config for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @returns The cell config for the widget.\n     */\n    function getCellConfig(widget) {\n        return Private$b.cellConfigProperty.get(widget);\n    }\n    GridLayout.getCellConfig = getCellConfig;\n    /**\n     * Set the cell config for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @param value - The value for the cell config.\n     */\n    function setCellConfig(widget, value) {\n        Private$b.cellConfigProperty.set(widget, Private$b.normalizeConfig(value));\n    }\n    GridLayout.setCellConfig = setCellConfig;\n})(GridLayout || (GridLayout = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$b;\n(function (Private) {\n    /**\n     * The property descriptor for the widget cell config.\n     */\n    Private.cellConfigProperty = new AttachedProperty({\n        name: 'cellConfig',\n        create: function () { return ({ row: 0, column: 0, rowSpan: 1, columnSpan: 1 }); },\n        changed: onChildCellConfigChanged\n    });\n    /**\n     * Normalize a partial cell config object.\n     */\n    function normalizeConfig(config) {\n        var row = Math.max(0, Math.floor(config.row || 0));\n        var column = Math.max(0, Math.floor(config.column || 0));\n        var rowSpan = Math.max(1, Math.floor(config.rowSpan || 0));\n        var columnSpan = Math.max(1, Math.floor(config.columnSpan || 0));\n        return { row: row, column: column, rowSpan: rowSpan, columnSpan: columnSpan };\n    }\n    Private.normalizeConfig = normalizeConfig;\n    /**\n     * Clamp a value to an integer >= 0.\n     */\n    function clampValue(value) {\n        return Math.max(0, Math.floor(value));\n    }\n    Private.clampValue = clampValue;\n    /**\n     * A sort comparison function for row spans.\n     */\n    function rowSpanCmp(a, b) {\n        var c1 = Private.cellConfigProperty.get(a.widget);\n        var c2 = Private.cellConfigProperty.get(b.widget);\n        return c1.rowSpan - c2.rowSpan;\n    }\n    Private.rowSpanCmp = rowSpanCmp;\n    /**\n     * A sort comparison function for column spans.\n     */\n    function columnSpanCmp(a, b) {\n        var c1 = Private.cellConfigProperty.get(a.widget);\n        var c2 = Private.cellConfigProperty.get(b.widget);\n        return c1.columnSpan - c2.columnSpan;\n    }\n    Private.columnSpanCmp = columnSpanCmp;\n    /**\n     * Reallocate the box sizers for the given grid dimensions.\n     */\n    function reallocSizers(sizers, count) {\n        // Coerce the count to the valid range.\n        count = Math.max(1, Math.floor(count));\n        // Add the missing sizers.\n        while (sizers.length < count) {\n            sizers.push(new BoxSizer());\n        }\n        // Remove the extra sizers.\n        if (sizers.length > count) {\n            sizers.length = count;\n        }\n    }\n    Private.reallocSizers = reallocSizers;\n    /**\n     * Distribute a min size constraint across a range of sizers.\n     */\n    function distributeMin(sizers, i1, i2, minSize) {\n        // Sanity check the indices.\n        if (i2 < i1) {\n            return;\n        }\n        // Handle the simple case of no cell span.\n        if (i1 === i2) {\n            var sizer = sizers[i1];\n            sizer.minSize = Math.max(sizer.minSize, minSize);\n            return;\n        }\n        // Compute the total current min size of the span.\n        var totalMin = 0;\n        for (var i = i1; i <= i2; ++i) {\n            totalMin += sizers[i].minSize;\n        }\n        // Do nothing if the total is greater than the required.\n        if (totalMin >= minSize) {\n            return;\n        }\n        // Compute the portion of the space to allocate to each sizer.\n        var portion = (minSize - totalMin) / (i2 - i1 + 1);\n        // Add the portion to each sizer.\n        for (var i = i1; i <= i2; ++i) {\n            sizers[i].minSize += portion;\n        }\n    }\n    Private.distributeMin = distributeMin;\n    /**\n     * The change handler for the child cell config property.\n     */\n    function onChildCellConfigChanged(child) {\n        if (child.parent && child.parent.layout instanceof GridLayout) {\n            child.parent.fit();\n        }\n    }\n})(Private$b || (Private$b = {}));\n\n/**\n * A widget which displays menus as a canonical menu bar.\n */\nvar MenuBar = /** @class */ (function (_super) {\n    __extends(MenuBar, _super);\n    /**\n     * Construct a new menu bar.\n     *\n     * @param options - The options for initializing the menu bar.\n     */\n    function MenuBar(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this, { node: Private$c.createNode() }) || this;\n        _this._activeIndex = -1;\n        _this._menus = [];\n        _this._childMenu = null;\n        _this.addClass('lm-MenuBar');\n        /* <DEPRECATED> */\n        _this.addClass('p-MenuBar');\n        /* </DEPRECATED> */\n        _this.setFlag(Widget.Flag.DisallowLayout);\n        _this.renderer = options.renderer || MenuBar.defaultRenderer;\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the widget.\n     */\n    MenuBar.prototype.dispose = function () {\n        this._closeChildMenu();\n        this._menus.length = 0;\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(MenuBar.prototype, \"childMenu\", {\n        /**\n         * The child menu of the menu bar.\n         *\n         * #### Notes\n         * This will be `null` if the menu bar does not have an open menu.\n         */\n        get: function () {\n            return this._childMenu;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(MenuBar.prototype, \"contentNode\", {\n        /**\n         * Get the menu bar content node.\n         *\n         * #### Notes\n         * This is the node which holds the menu title nodes.\n         *\n         * Modifying this node directly can lead to undefined behavior.\n         */\n        get: function () {\n            return this.node.getElementsByClassName('lm-MenuBar-content')[0];\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(MenuBar.prototype, \"activeMenu\", {\n        /**\n         * Get the currently active menu.\n         */\n        get: function () {\n            return this._menus[this._activeIndex] || null;\n        },\n        /**\n         * Set the currently active menu.\n         *\n         * #### Notes\n         * If the menu does not exist, the menu will be set to `null`.\n         */\n        set: function (value) {\n            this.activeIndex = value ? this._menus.indexOf(value) : -1;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(MenuBar.prototype, \"activeIndex\", {\n        /**\n         * Get the index of the currently active menu.\n         *\n         * #### Notes\n         * This will be `-1` if no menu is active.\n         */\n        get: function () {\n            return this._activeIndex;\n        },\n        /**\n         * Set the index of the currently active menu.\n         *\n         * #### Notes\n         * If the menu cannot be activated, the index will be set to `-1`.\n         */\n        set: function (value) {\n            // Adjust the value for an out of range index.\n            if (value < 0 || value >= this._menus.length) {\n                value = -1;\n            }\n            // Bail early if the index will not change.\n            if (this._activeIndex === value) {\n                return;\n            }\n            // Update the active index.\n            this._activeIndex = value;\n            // Schedule an update of the items.\n            this.update();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(MenuBar.prototype, \"menus\", {\n        /**\n         * A read-only array of the menus in the menu bar.\n         */\n        get: function () {\n            return this._menus;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Open the active menu and activate its first menu item.\n     *\n     * #### Notes\n     * If there is no active menu, this is a no-op.\n     */\n    MenuBar.prototype.openActiveMenu = function () {\n        // Bail early if there is no active item.\n        if (this._activeIndex === -1) {\n            return;\n        }\n        // Open the child menu.\n        this._openChildMenu();\n        // Activate the first item in the child menu.\n        if (this._childMenu) {\n            this._childMenu.activeIndex = -1;\n            this._childMenu.activateNextItem();\n        }\n    };\n    /**\n     * Add a menu to the end of the menu bar.\n     *\n     * @param menu - The menu to add to the menu bar.\n     *\n     * #### Notes\n     * If the menu is already added to the menu bar, it will be moved.\n     */\n    MenuBar.prototype.addMenu = function (menu) {\n        this.insertMenu(this._menus.length, menu);\n    };\n    /**\n     * Insert a menu into the menu bar at the specified index.\n     *\n     * @param index - The index at which to insert the menu.\n     *\n     * @param menu - The menu to insert into the menu bar.\n     *\n     * #### Notes\n     * The index will be clamped to the bounds of the menus.\n     *\n     * If the menu is already added to the menu bar, it will be moved.\n     */\n    MenuBar.prototype.insertMenu = function (index, menu) {\n        // Close the child menu before making changes.\n        this._closeChildMenu();\n        // Look up the index of the menu.\n        var i = this._menus.indexOf(menu);\n        // Clamp the insert index to the array bounds.\n        var j = Math.max(0, Math.min(index, this._menus.length));\n        // If the menu is not in the array, insert it.\n        if (i === -1) {\n            // Insert the menu into the array.\n            ArrayExt.insert(this._menus, j, menu);\n            // Add the styling class to the menu.\n            menu.addClass('lm-MenuBar-menu');\n            /* <DEPRECATED> */\n            menu.addClass('p-MenuBar-menu');\n            /* </DEPRECATED> */\n            // Connect to the menu signals.\n            menu.aboutToClose.connect(this._onMenuAboutToClose, this);\n            menu.menuRequested.connect(this._onMenuMenuRequested, this);\n            menu.title.changed.connect(this._onTitleChanged, this);\n            // Schedule an update of the items.\n            this.update();\n            // There is nothing more to do.\n            return;\n        }\n        // Otherwise, the menu exists in the array and should be moved.\n        // Adjust the index if the location is at the end of the array.\n        if (j === this._menus.length) {\n            j--;\n        }\n        // Bail if there is no effective move.\n        if (i === j) {\n            return;\n        }\n        // Move the menu to the new locations.\n        ArrayExt.move(this._menus, i, j);\n        // Schedule an update of the items.\n        this.update();\n    };\n    /**\n     * Remove a menu from the menu bar.\n     *\n     * @param menu - The menu to remove from the menu bar.\n     *\n     * #### Notes\n     * This is a no-op if the menu is not in the menu bar.\n     */\n    MenuBar.prototype.removeMenu = function (menu) {\n        this.removeMenuAt(this._menus.indexOf(menu));\n    };\n    /**\n     * Remove the menu at a given index from the menu bar.\n     *\n     * @param index - The index of the menu to remove.\n     *\n     * #### Notes\n     * This is a no-op if the index is out of range.\n     */\n    MenuBar.prototype.removeMenuAt = function (index) {\n        // Close the child menu before making changes.\n        this._closeChildMenu();\n        // Remove the menu from the array.\n        var menu = ArrayExt.removeAt(this._menus, index);\n        // Bail if the index is out of range.\n        if (!menu) {\n            return;\n        }\n        // Disconnect from the menu signals.\n        menu.aboutToClose.disconnect(this._onMenuAboutToClose, this);\n        menu.menuRequested.disconnect(this._onMenuMenuRequested, this);\n        menu.title.changed.disconnect(this._onTitleChanged, this);\n        // Remove the styling class from the menu.\n        menu.removeClass('lm-MenuBar-menu');\n        /* <DEPRECATED> */\n        menu.removeClass('p-MenuBar-menu');\n        /* </DEPRECATED> */\n        // Schedule an update of the items.\n        this.update();\n    };\n    /**\n     * Remove all menus from the menu bar.\n     */\n    MenuBar.prototype.clearMenus = function () {\n        // Bail if there is nothing to remove.\n        if (this._menus.length === 0) {\n            return;\n        }\n        // Close the child menu before making changes.\n        this._closeChildMenu();\n        // Disconnect from the menu signals and remove the styling class.\n        for (var _i = 0, _a = this._menus; _i < _a.length; _i++) {\n            var menu = _a[_i];\n            menu.aboutToClose.disconnect(this._onMenuAboutToClose, this);\n            menu.menuRequested.disconnect(this._onMenuMenuRequested, this);\n            menu.title.changed.disconnect(this._onTitleChanged, this);\n            menu.removeClass('lm-MenuBar-menu');\n            /* <DEPRECATED> */\n            menu.removeClass('p-MenuBar-menu');\n            /* </DEPRECATED> */\n        }\n        // Clear the menus array.\n        this._menus.length = 0;\n        // Schedule an update of the items.\n        this.update();\n    };\n    /**\n     * Handle the DOM events for the menu bar.\n     *\n     * @param event - The DOM event sent to the menu bar.\n     *\n     * #### Notes\n     * This method implements the DOM `EventListener` interface and is\n     * called in response to events on the menu bar's DOM nodes. It\n     * should not be called directly by user code.\n     */\n    MenuBar.prototype.handleEvent = function (event) {\n        switch (event.type) {\n            case 'keydown':\n                this._evtKeyDown(event);\n                break;\n            case 'mousedown':\n                this._evtMouseDown(event);\n                break;\n            case 'mousemove':\n                this._evtMouseMove(event);\n                break;\n            case 'mouseleave':\n                this._evtMouseLeave(event);\n                break;\n            case 'contextmenu':\n                event.preventDefault();\n                event.stopPropagation();\n                break;\n        }\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     */\n    MenuBar.prototype.onBeforeAttach = function (msg) {\n        this.node.addEventListener('keydown', this);\n        this.node.addEventListener('mousedown', this);\n        this.node.addEventListener('mousemove', this);\n        this.node.addEventListener('mouseleave', this);\n        this.node.addEventListener('contextmenu', this);\n    };\n    /**\n     * A message handler invoked on an `'after-detach'` message.\n     */\n    MenuBar.prototype.onAfterDetach = function (msg) {\n        this.node.removeEventListener('keydown', this);\n        this.node.removeEventListener('mousedown', this);\n        this.node.removeEventListener('mousemove', this);\n        this.node.removeEventListener('mouseleave', this);\n        this.node.removeEventListener('contextmenu', this);\n        this._closeChildMenu();\n    };\n    /**\n     * A message handler invoked on an `'activate-request'` message.\n     */\n    MenuBar.prototype.onActivateRequest = function (msg) {\n        if (this.isAttached) {\n            this.node.focus();\n        }\n    };\n    /**\n     * A message handler invoked on an `'update-request'` message.\n     */\n    MenuBar.prototype.onUpdateRequest = function (msg) {\n        var menus = this._menus;\n        var renderer = this.renderer;\n        var activeIndex = this._activeIndex;\n        var content = new Array(menus.length);\n        for (var i = 0, n = menus.length; i < n; ++i) {\n            var title = menus[i].title;\n            var active = i === activeIndex;\n            content[i] = renderer.renderItem({ title: title, active: active });\n        }\n        VirtualDOM.render(content, this.contentNode);\n    };\n    /**\n     * Handle the `'keydown'` event for the menu bar.\n     */\n    MenuBar.prototype._evtKeyDown = function (event) {\n        // A menu bar handles all keydown events.\n        event.preventDefault();\n        event.stopPropagation();\n        // Fetch the key code for the event.\n        var kc = event.keyCode;\n        // Enter, Up Arrow, Down Arrow\n        if (kc === 13 || kc === 38 || kc === 40) {\n            this.openActiveMenu();\n            return;\n        }\n        // Escape\n        if (kc === 27) {\n            this._closeChildMenu();\n            this.activeIndex = -1;\n            this.node.blur();\n            return;\n        }\n        // Left Arrow\n        if (kc === 37) {\n            var i = this._activeIndex;\n            var n = this._menus.length;\n            this.activeIndex = i === 0 ? n - 1 : i - 1;\n            return;\n        }\n        // Right Arrow\n        if (kc === 39) {\n            var i = this._activeIndex;\n            var n = this._menus.length;\n            this.activeIndex = i === n - 1 ? 0 : i + 1;\n            return;\n        }\n        // Get the pressed key character.\n        var key = getKeyboardLayout().keyForKeydownEvent(event);\n        // Bail if the key is not valid.\n        if (!key) {\n            return;\n        }\n        // Search for the next best matching mnemonic item.\n        var start = this._activeIndex + 1;\n        var result = Private$c.findMnemonic(this._menus, key, start);\n        // Handle the requested mnemonic based on the search results.\n        // If exactly one mnemonic is matched, that menu is opened.\n        // Otherwise, the next mnemonic is activated if available,\n        // followed by the auto mnemonic if available.\n        if (result.index !== -1 && !result.multiple) {\n            this.activeIndex = result.index;\n            this.openActiveMenu();\n        }\n        else if (result.index !== -1) {\n            this.activeIndex = result.index;\n        }\n        else if (result.auto !== -1) {\n            this.activeIndex = result.auto;\n        }\n    };\n    /**\n     * Handle the `'mousedown'` event for the menu bar.\n     */\n    MenuBar.prototype._evtMouseDown = function (event) {\n        // Bail if the mouse press was not on the menu bar. This can occur\n        // when the document listener is installed for an active menu bar.\n        if (!ElementExt.hitTest(this.node, event.clientX, event.clientY)) {\n            return;\n        }\n        // Stop the propagation of the event. Immediate propagation is\n        // also stopped so that an open menu does not handle the event.\n        event.preventDefault();\n        event.stopPropagation();\n        event.stopImmediatePropagation();\n        // Check if the mouse is over one of the menu items.\n        var index = ArrayExt.findFirstIndex(this.contentNode.children, function (node) {\n            return ElementExt.hitTest(node, event.clientX, event.clientY);\n        });\n        // If the press was not on an item, close the child menu.\n        if (index === -1) {\n            this._closeChildMenu();\n            return;\n        }\n        // If the press was not the left mouse button, do nothing further.\n        if (event.button !== 0) {\n            return;\n        }\n        // Otherwise, toggle the open state of the child menu.\n        if (this._childMenu) {\n            this._closeChildMenu();\n            this.activeIndex = index;\n        }\n        else {\n            this.activeIndex = index;\n            this._openChildMenu();\n        }\n    };\n    /**\n     * Handle the `'mousemove'` event for the menu bar.\n     */\n    MenuBar.prototype._evtMouseMove = function (event) {\n        // Check if the mouse is over one of the menu items.\n        var index = ArrayExt.findFirstIndex(this.contentNode.children, function (node) {\n            return ElementExt.hitTest(node, event.clientX, event.clientY);\n        });\n        // Bail early if the active index will not change.\n        if (index === this._activeIndex) {\n            return;\n        }\n        // Bail early if a child menu is open and the mouse is not over\n        // an item. This allows the child menu to be kept open when the\n        // mouse is over the empty part of the menu bar.\n        if (index === -1 && this._childMenu) {\n            return;\n        }\n        // Update the active index to the hovered item.\n        this.activeIndex = index;\n        // Open the new menu if a menu is already open.\n        if (this._childMenu) {\n            this._openChildMenu();\n        }\n    };\n    /**\n     * Handle the `'mouseleave'` event for the menu bar.\n     */\n    MenuBar.prototype._evtMouseLeave = function (event) {\n        // Reset the active index if there is no open menu.\n        if (!this._childMenu) {\n            this.activeIndex = -1;\n        }\n    };\n    /**\n     * Open the child menu at the active index immediately.\n     *\n     * If a different child menu is already open, it will be closed,\n     * even if there is no active menu.\n     */\n    MenuBar.prototype._openChildMenu = function () {\n        // If there is no active menu, close the current menu.\n        var newMenu = this.activeMenu;\n        if (!newMenu) {\n            this._closeChildMenu();\n            return;\n        }\n        // Bail if there is no effective menu change.\n        var oldMenu = this._childMenu;\n        if (oldMenu === newMenu) {\n            return;\n        }\n        // Swap the internal menu reference.\n        this._childMenu = newMenu;\n        // Close the current menu, or setup for the new menu.\n        if (oldMenu) {\n            oldMenu.close();\n        }\n        else {\n            this.addClass('lm-mod-active');\n            /* <DEPRECATED> */\n            this.addClass('p-mod-active');\n            /* </DEPRECATED> */\n            document.addEventListener('mousedown', this, true);\n        }\n        // Ensure the menu bar is updated and look up the item node.\n        MessageLoop.sendMessage(this, Widget.Msg.UpdateRequest);\n        var itemNode = this.contentNode.children[this._activeIndex];\n        // Get the positioning data for the new menu.\n        var _a = itemNode.getBoundingClientRect(), left = _a.left, bottom = _a.bottom;\n        // Open the new menu at the computed location.\n        newMenu.open(left, bottom, { forceX: true, forceY: true });\n    };\n    /**\n     * Close the child menu immediately.\n     *\n     * This is a no-op if a child menu is not open.\n     */\n    MenuBar.prototype._closeChildMenu = function () {\n        // Bail if no child menu is open.\n        if (!this._childMenu) {\n            return;\n        }\n        // Remove the active class from the menu bar.\n        this.removeClass('lm-mod-active');\n        /* <DEPRECATED> */\n        this.removeClass('p-mod-active');\n        /* </DEPRECATED> */\n        // Remove the document listeners.\n        document.removeEventListener('mousedown', this, true);\n        // Clear the internal menu reference.\n        var menu = this._childMenu;\n        this._childMenu = null;\n        // Close the menu.\n        menu.close();\n        // Reset the active index.\n        this.activeIndex = -1;\n    };\n    /**\n     * Handle the `aboutToClose` signal of a menu.\n     */\n    MenuBar.prototype._onMenuAboutToClose = function (sender) {\n        // Bail if the sender is not the child menu.\n        if (sender !== this._childMenu) {\n            return;\n        }\n        // Remove the active class from the menu bar.\n        this.removeClass('lm-mod-active');\n        /* <DEPRECATED> */\n        this.removeClass('p-mod-active');\n        /* </DEPRECATED> */\n        // Remove the document listeners.\n        document.removeEventListener('mousedown', this, true);\n        // Clear the internal menu reference.\n        this._childMenu = null;\n        // Reset the active index.\n        this.activeIndex = -1;\n    };\n    /**\n     * Handle the `menuRequested` signal of a child menu.\n     */\n    MenuBar.prototype._onMenuMenuRequested = function (sender, args) {\n        // Bail if the sender is not the child menu.\n        if (sender !== this._childMenu) {\n            return;\n        }\n        // Look up the active index and menu count.\n        var i = this._activeIndex;\n        var n = this._menus.length;\n        // Active the next requested index.\n        switch (args) {\n            case 'next':\n                this.activeIndex = i === n - 1 ? 0 : i + 1;\n                break;\n            case 'previous':\n                this.activeIndex = i === 0 ? n - 1 : i - 1;\n                break;\n        }\n        // Open the active menu.\n        this.openActiveMenu();\n    };\n    /**\n     * Handle the `changed` signal of a title object.\n     */\n    MenuBar.prototype._onTitleChanged = function () {\n        this.update();\n    };\n    return MenuBar;\n}(Widget));\n/**\n * The namespace for the `MenuBar` class statics.\n */\n(function (MenuBar) {\n    /**\n     * The default implementation of `IRenderer`.\n     *\n     * #### Notes\n     * Subclasses are free to reimplement rendering methods as needed.\n     */\n    var Renderer = /** @class */ (function () {\n        /**\n         * Construct a new renderer.\n         */\n        function Renderer() {\n        }\n        /**\n         * Render the virtual element for a menu bar item.\n         *\n         * @param data - The data to use for rendering the item.\n         *\n         * @returns A virtual element representing the item.\n         */\n        Renderer.prototype.renderItem = function (data) {\n            var className = this.createItemClass(data);\n            var dataset = this.createItemDataset(data);\n            var aria = this.createItemARIA(data);\n            return (h.li(__assign({ className: className, dataset: dataset }, aria), this.renderIcon(data), this.renderLabel(data)));\n        };\n        /**\n         * Render the icon element for a menu bar item.\n         *\n         * @param data - The data to use for rendering the icon.\n         *\n         * @returns A virtual element representing the item icon.\n         */\n        Renderer.prototype.renderIcon = function (data) {\n            var className = this.createIconClass(data);\n            /* <DEPRECATED> */\n            if (typeof data.title.icon === 'string') {\n                return h.div({ className: className }, data.title.iconLabel);\n            }\n            /* </DEPRECATED> */\n            // if data.title.icon is undefined, it will be ignored\n            return h.div({ className: className }, data.title.icon, data.title.iconLabel);\n        };\n        /**\n         * Render the label element for a menu item.\n         *\n         * @param data - The data to use for rendering the label.\n         *\n         * @returns A virtual element representing the item label.\n         */\n        Renderer.prototype.renderLabel = function (data) {\n            var content = this.formatLabel(data);\n            return h.div({ className: 'lm-MenuBar-itemLabel'\n                    /* <DEPRECATED> */\n                    + ' p-MenuBar-itemLabel'\n                /* </DEPRECATED> */\n            }, content);\n        };\n        /**\n         * Create the class name for the menu bar item.\n         *\n         * @param data - The data to use for the class name.\n         *\n         * @returns The full class name for the menu item.\n         */\n        Renderer.prototype.createItemClass = function (data) {\n            var name = 'lm-MenuBar-item';\n            /* <DEPRECATED> */\n            name += ' p-MenuBar-item';\n            /* </DEPRECATED> */\n            if (data.title.className) {\n                name += \" \" + data.title.className;\n            }\n            if (data.active) {\n                name += ' lm-mod-active';\n                /* <DEPRECATED> */\n                name += ' p-mod-active';\n                /* </DEPRECATED> */\n            }\n            return name;\n        };\n        /**\n         * Create the dataset for a menu bar item.\n         *\n         * @param data - The data to use for the item.\n         *\n         * @returns The dataset for the menu bar item.\n         */\n        Renderer.prototype.createItemDataset = function (data) {\n            return data.title.dataset;\n        };\n        /**\n         * Create the aria attributes for menu bar item.\n         *\n         * @param data - The data to use for the aria attributes.\n         *\n         * @returns The aria attributes object for the item.\n         */\n        Renderer.prototype.createItemARIA = function (data) {\n            return { role: 'menuitem', 'aria-haspopup': 'true' };\n        };\n        /**\n         * Create the class name for the menu bar item icon.\n         *\n         * @param data - The data to use for the class name.\n         *\n         * @returns The full class name for the item icon.\n         */\n        Renderer.prototype.createIconClass = function (data) {\n            var name = 'lm-MenuBar-itemIcon';\n            /* <DEPRECATED> */\n            name += ' p-MenuBar-itemIcon';\n            /* </DEPRECATED> */\n            var extra = data.title.iconClass;\n            return extra ? name + \" \" + extra : name;\n        };\n        /**\n         * Create the render content for the label node.\n         *\n         * @param data - The data to use for the label content.\n         *\n         * @returns The content to add to the label node.\n         */\n        Renderer.prototype.formatLabel = function (data) {\n            // Fetch the label text and mnemonic index.\n            var _a = data.title, label = _a.label, mnemonic = _a.mnemonic;\n            // If the index is out of range, do not modify the label.\n            if (mnemonic < 0 || mnemonic >= label.length) {\n                return label;\n            }\n            // Split the label into parts.\n            var prefix = label.slice(0, mnemonic);\n            var suffix = label.slice(mnemonic + 1);\n            var char = label[mnemonic];\n            // Wrap the mnemonic character in a span.\n            var span = h.span({\n                className: 'lm-MenuBar-itemMnemonic'\n                    /* <DEPRECATED> */\n                    + ' p-MenuBar-itemMnemonic'\n                /* </DEPRECATED> */\n            }, char);\n            // Return the content parts.\n            return [prefix, span, suffix];\n        };\n        return Renderer;\n    }());\n    MenuBar.Renderer = Renderer;\n    /**\n     * The default `Renderer` instance.\n     */\n    MenuBar.defaultRenderer = new Renderer();\n})(MenuBar || (MenuBar = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$c;\n(function (Private) {\n    /**\n     * Create the DOM node for a menu bar.\n     */\n    function createNode() {\n        var node = document.createElement('div');\n        var content = document.createElement('ul');\n        content.className = 'lm-MenuBar-content';\n        /* <DEPRECATED> */\n        content.classList.add('p-MenuBar-content');\n        /* </DEPRECATED> */\n        node.appendChild(content);\n        content.setAttribute('role', 'menubar');\n        node.tabIndex = -1;\n        return node;\n    }\n    Private.createNode = createNode;\n    /**\n     * Find the best matching mnemonic item.\n     *\n     * The search starts at the given index and wraps around.\n     */\n    function findMnemonic(menus, key, start) {\n        // Setup the result variables.\n        var index = -1;\n        var auto = -1;\n        var multiple = false;\n        // Normalize the key to upper case.\n        var upperKey = key.toUpperCase();\n        // Search the items from the given start index.\n        for (var i = 0, n = menus.length; i < n; ++i) {\n            // Compute the wrapped index.\n            var k = (i + start) % n;\n            // Look up the menu title.\n            var title = menus[k].title;\n            // Ignore titles with an empty label.\n            if (title.label.length === 0) {\n                continue;\n            }\n            // Look up the mnemonic index for the label.\n            var mn = title.mnemonic;\n            // Handle a valid mnemonic index.\n            if (mn >= 0 && mn < title.label.length) {\n                if (title.label[mn].toUpperCase() === upperKey) {\n                    if (index === -1) {\n                        index = k;\n                    }\n                    else {\n                        multiple = true;\n                    }\n                }\n                continue;\n            }\n            // Finally, handle the auto index if possible.\n            if (auto === -1 && title.label[0].toUpperCase() === upperKey) {\n                auto = k;\n            }\n        }\n        // Return the search results.\n        return { index: index, multiple: multiple, auto: auto };\n    }\n    Private.findMnemonic = findMnemonic;\n})(Private$c || (Private$c = {}));\n\n/**\n * A widget which implements a canonical scroll bar.\n */\nvar ScrollBar = /** @class */ (function (_super) {\n    __extends(ScrollBar, _super);\n    /**\n     * Construct a new scroll bar.\n     *\n     * @param options - The options for initializing the scroll bar.\n     */\n    function ScrollBar(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this, { node: Private$d.createNode() }) || this;\n        /**\n         * A timeout callback for repeating the mouse press.\n         */\n        _this._onRepeat = function () {\n            // Clear the repeat timer id.\n            _this._repeatTimer = -1;\n            // Bail if the mouse has been released.\n            if (!_this._pressData) {\n                return;\n            }\n            // Look up the part that was pressed.\n            var part = _this._pressData.part;\n            // Bail if the thumb was pressed.\n            if (part === 'thumb') {\n                return;\n            }\n            // Schedule the timer for another repeat.\n            _this._repeatTimer = window.setTimeout(_this._onRepeat, 20);\n            // Get the current mouse position.\n            var mouseX = _this._pressData.mouseX;\n            var mouseY = _this._pressData.mouseY;\n            // Handle a decrement button repeat.\n            if (part === 'decrement') {\n                // Bail if the mouse is not over the button.\n                if (!ElementExt.hitTest(_this.decrementNode, mouseX, mouseY)) {\n                    return;\n                }\n                // Emit the step requested signal.\n                _this._stepRequested.emit('decrement');\n                // Finished.\n                return;\n            }\n            // Handle an increment button repeat.\n            if (part === 'increment') {\n                // Bail if the mouse is not over the button.\n                if (!ElementExt.hitTest(_this.incrementNode, mouseX, mouseY)) {\n                    return;\n                }\n                // Emit the step requested signal.\n                _this._stepRequested.emit('increment');\n                // Finished.\n                return;\n            }\n            // Handle a track repeat.\n            if (part === 'track') {\n                // Bail if the mouse is not over the track.\n                if (!ElementExt.hitTest(_this.trackNode, mouseX, mouseY)) {\n                    return;\n                }\n                // Fetch the thumb node.\n                var thumbNode = _this.thumbNode;\n                // Bail if the mouse is over the thumb.\n                if (ElementExt.hitTest(thumbNode, mouseX, mouseY)) {\n                    return;\n                }\n                // Fetch the client rect for the thumb.\n                var thumbRect = thumbNode.getBoundingClientRect();\n                // Determine the direction for the page request.\n                var dir = void 0;\n                if (_this._orientation === 'horizontal') {\n                    dir = mouseX < thumbRect.left ? 'decrement' : 'increment';\n                }\n                else {\n                    dir = mouseY < thumbRect.top ? 'decrement' : 'increment';\n                }\n                // Emit the page requested signal.\n                _this._pageRequested.emit(dir);\n                // Finished.\n                return;\n            }\n        };\n        _this._value = 0;\n        _this._page = 10;\n        _this._maximum = 100;\n        _this._repeatTimer = -1;\n        _this._pressData = null;\n        _this._thumbMoved = new Signal(_this);\n        _this._stepRequested = new Signal(_this);\n        _this._pageRequested = new Signal(_this);\n        _this.addClass('lm-ScrollBar');\n        /* <DEPRECATED> */\n        _this.addClass('p-ScrollBar');\n        /* </DEPRECATED> */\n        _this.setFlag(Widget.Flag.DisallowLayout);\n        // Set the orientation.\n        _this._orientation = options.orientation || 'vertical';\n        _this.dataset['orientation'] = _this._orientation;\n        // Parse the rest of the options.\n        if (options.maximum !== undefined) {\n            _this._maximum = Math.max(0, options.maximum);\n        }\n        if (options.page !== undefined) {\n            _this._page = Math.max(0, options.page);\n        }\n        if (options.value !== undefined) {\n            _this._value = Math.max(0, Math.min(options.value, _this._maximum));\n        }\n        return _this;\n    }\n    Object.defineProperty(ScrollBar.prototype, \"thumbMoved\", {\n        /**\n         * A signal emitted when the user moves the scroll thumb.\n         *\n         * #### Notes\n         * The payload is the current value of the scroll bar.\n         */\n        get: function () {\n            return this._thumbMoved;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(ScrollBar.prototype, \"stepRequested\", {\n        /**\n         * A signal emitted when the user clicks a step button.\n         *\n         * #### Notes\n         * The payload is whether a decrease or increase is requested.\n         */\n        get: function () {\n            return this._stepRequested;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(ScrollBar.prototype, \"pageRequested\", {\n        /**\n         * A signal emitted when the user clicks the scroll track.\n         *\n         * #### Notes\n         * The payload is whether a decrease or increase is requested.\n         */\n        get: function () {\n            return this._pageRequested;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(ScrollBar.prototype, \"orientation\", {\n        /**\n         * Get the orientation of the scroll bar.\n         */\n        get: function () {\n            return this._orientation;\n        },\n        /**\n         * Set the orientation of the scroll bar.\n         */\n        set: function (value) {\n            // Do nothing if the orientation does not change.\n            if (this._orientation === value) {\n                return;\n            }\n            // Release the mouse before making changes.\n            this._releaseMouse();\n            // Update the internal orientation.\n            this._orientation = value;\n            this.dataset['orientation'] = value;\n            // Schedule an update the scroll bar.\n            this.update();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(ScrollBar.prototype, \"value\", {\n        /**\n         * Get the current value of the scroll bar.\n         */\n        get: function () {\n            return this._value;\n        },\n        /**\n         * Set the current value of the scroll bar.\n         *\n         * #### Notes\n         * The value will be clamped to the range `[0, maximum]`.\n         */\n        set: function (value) {\n            // Clamp the value to the allowable range.\n            value = Math.max(0, Math.min(value, this._maximum));\n            // Do nothing if the value does not change.\n            if (this._value === value) {\n                return;\n            }\n            // Update the internal value.\n            this._value = value;\n            // Schedule an update the scroll bar.\n            this.update();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(ScrollBar.prototype, \"page\", {\n        /**\n         * Get the page size of the scroll bar.\n         *\n         * #### Notes\n         * The page size is the amount of visible content in the scrolled\n         * region, expressed in data units. It determines the size of the\n         * scroll bar thumb.\n         */\n        get: function () {\n            return this._page;\n        },\n        /**\n         * Set the page size of the scroll bar.\n         *\n         * #### Notes\n         * The page size will be clamped to the range `[0, Infinity]`.\n         */\n        set: function (value) {\n            // Clamp the page size to the allowable range.\n            value = Math.max(0, value);\n            // Do nothing if the value does not change.\n            if (this._page === value) {\n                return;\n            }\n            // Update the internal page size.\n            this._page = value;\n            // Schedule an update the scroll bar.\n            this.update();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(ScrollBar.prototype, \"maximum\", {\n        /**\n         * Get the maximum value of the scroll bar.\n         */\n        get: function () {\n            return this._maximum;\n        },\n        /**\n         * Set the maximum value of the scroll bar.\n         *\n         * #### Notes\n         * The max size will be clamped to the range `[0, Infinity]`.\n         */\n        set: function (value) {\n            // Clamp the value to the allowable range.\n            value = Math.max(0, value);\n            // Do nothing if the value does not change.\n            if (this._maximum === value) {\n                return;\n            }\n            // Update the internal values.\n            this._maximum = value;\n            // Clamp the current value to the new range.\n            this._value = Math.min(this._value, value);\n            // Schedule an update the scroll bar.\n            this.update();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(ScrollBar.prototype, \"decrementNode\", {\n        /**\n         * The scroll bar decrement button node.\n         *\n         * #### Notes\n         * Modifying this node directly can lead to undefined behavior.\n         */\n        get: function () {\n            return this.node.getElementsByClassName('lm-ScrollBar-button')[0];\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(ScrollBar.prototype, \"incrementNode\", {\n        /**\n         * The scroll bar increment button node.\n         *\n         * #### Notes\n         * Modifying this node directly can lead to undefined behavior.\n         */\n        get: function () {\n            return this.node.getElementsByClassName('lm-ScrollBar-button')[1];\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(ScrollBar.prototype, \"trackNode\", {\n        /**\n         * The scroll bar track node.\n         *\n         * #### Notes\n         * Modifying this node directly can lead to undefined behavior.\n         */\n        get: function () {\n            return this.node.getElementsByClassName('lm-ScrollBar-track')[0];\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(ScrollBar.prototype, \"thumbNode\", {\n        /**\n         * The scroll bar thumb node.\n         *\n         * #### Notes\n         * Modifying this node directly can lead to undefined behavior.\n         */\n        get: function () {\n            return this.node.getElementsByClassName('lm-ScrollBar-thumb')[0];\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Handle the DOM events for the scroll bar.\n     *\n     * @param event - The DOM event sent to the scroll bar.\n     *\n     * #### Notes\n     * This method implements the DOM `EventListener` interface and is\n     * called in response to events on the scroll bar's DOM node.\n     *\n     * This should not be called directly by user code.\n     */\n    ScrollBar.prototype.handleEvent = function (event) {\n        switch (event.type) {\n            case 'mousedown':\n                this._evtMouseDown(event);\n                break;\n            case 'mousemove':\n                this._evtMouseMove(event);\n                break;\n            case 'mouseup':\n                this._evtMouseUp(event);\n                break;\n            case 'keydown':\n                this._evtKeyDown(event);\n                break;\n            case 'contextmenu':\n                event.preventDefault();\n                event.stopPropagation();\n                break;\n        }\n    };\n    /**\n     * A method invoked on a 'before-attach' message.\n     */\n    ScrollBar.prototype.onBeforeAttach = function (msg) {\n        this.node.addEventListener('mousedown', this);\n        this.update();\n    };\n    /**\n     * A method invoked on an 'after-detach' message.\n     */\n    ScrollBar.prototype.onAfterDetach = function (msg) {\n        this.node.removeEventListener('mousedown', this);\n        this._releaseMouse();\n    };\n    /**\n     * A method invoked on an 'update-request' message.\n     */\n    ScrollBar.prototype.onUpdateRequest = function (msg) {\n        // Convert the value and page into percentages.\n        var value = this._value * 100 / this._maximum;\n        var page = this._page * 100 / (this._page + this._maximum);\n        // Clamp the value and page to the relevant range.\n        value = Math.max(0, Math.min(value, 100));\n        page = Math.max(0, Math.min(page, 100));\n        // Fetch the thumb style.\n        var thumbStyle = this.thumbNode.style;\n        // Update the thumb style for the current orientation.\n        if (this._orientation === 'horizontal') {\n            thumbStyle.top = '';\n            thumbStyle.height = '';\n            thumbStyle.left = value + \"%\";\n            thumbStyle.width = page + \"%\";\n            thumbStyle.transform = \"translate(\" + -value + \"%, 0%)\";\n        }\n        else {\n            thumbStyle.left = '';\n            thumbStyle.width = '';\n            thumbStyle.top = value + \"%\";\n            thumbStyle.height = page + \"%\";\n            thumbStyle.transform = \"translate(0%, \" + -value + \"%)\";\n        }\n    };\n    /**\n     * Handle the `'keydown'` event for the scroll bar.\n     */\n    ScrollBar.prototype._evtKeyDown = function (event) {\n        // Stop all input events during drag.\n        event.preventDefault();\n        event.stopPropagation();\n        // Ignore anything except the `Escape` key.\n        if (event.keyCode !== 27) {\n            return;\n        }\n        // Fetch the previous scroll value.\n        var value = this._pressData ? this._pressData.value : -1;\n        // Release the mouse.\n        this._releaseMouse();\n        // Restore the old scroll value if possible.\n        if (value !== -1) {\n            this._moveThumb(value);\n        }\n    };\n    /**\n     * Handle the `'mousedown'` event for the scroll bar.\n     */\n    ScrollBar.prototype._evtMouseDown = function (event) {\n        // Do nothing if it's not a left mouse press.\n        if (event.button !== 0) {\n            return;\n        }\n        // Send an activate request to the scroll bar. This can be\n        // used by message hooks to activate something relevant.\n        this.activate();\n        // Do nothing if the mouse is already captured.\n        if (this._pressData) {\n            return;\n        }\n        // Find the pressed scroll bar part.\n        var part = Private$d.findPart(this, event.target);\n        // Do nothing if the part is not of interest.\n        if (!part) {\n            return;\n        }\n        // Stop the event propagation.\n        event.preventDefault();\n        event.stopPropagation();\n        // Override the mouse cursor.\n        var override = Drag.overrideCursor('default');\n        // Set up the press data.\n        this._pressData = {\n            part: part, override: override,\n            delta: -1, value: -1,\n            mouseX: event.clientX,\n            mouseY: event.clientY\n        };\n        // Add the extra event listeners.\n        document.addEventListener('mousemove', this, true);\n        document.addEventListener('mouseup', this, true);\n        document.addEventListener('keydown', this, true);\n        document.addEventListener('contextmenu', this, true);\n        // Handle a thumb press.\n        if (part === 'thumb') {\n            // Fetch the thumb node.\n            var thumbNode = this.thumbNode;\n            // Fetch the client rect for the thumb.\n            var thumbRect = thumbNode.getBoundingClientRect();\n            // Update the press data delta for the current orientation.\n            if (this._orientation === 'horizontal') {\n                this._pressData.delta = event.clientX - thumbRect.left;\n            }\n            else {\n                this._pressData.delta = event.clientY - thumbRect.top;\n            }\n            // Add the active class to the thumb node.\n            thumbNode.classList.add('lm-mod-active');\n            /* <DEPRECATED> */\n            thumbNode.classList.add('p-mod-active');\n            /* </DEPRECATED> */\n            // Store the current value in the press data.\n            this._pressData.value = this._value;\n            // Finished.\n            return;\n        }\n        // Handle a track press.\n        if (part === 'track') {\n            // Fetch the client rect for the thumb.\n            var thumbRect = this.thumbNode.getBoundingClientRect();\n            // Determine the direction for the page request.\n            var dir = void 0;\n            if (this._orientation === 'horizontal') {\n                dir = event.clientX < thumbRect.left ? 'decrement' : 'increment';\n            }\n            else {\n                dir = event.clientY < thumbRect.top ? 'decrement' : 'increment';\n            }\n            // Start the repeat timer.\n            this._repeatTimer = window.setTimeout(this._onRepeat, 350);\n            // Emit the page requested signal.\n            this._pageRequested.emit(dir);\n            // Finished.\n            return;\n        }\n        // Handle a decrement button press.\n        if (part === 'decrement') {\n            // Add the active class to the decrement node.\n            this.decrementNode.classList.add('lm-mod-active');\n            /* <DEPRECATED> */\n            this.decrementNode.classList.add('p-mod-active');\n            /* </DEPRECATED> */\n            // Start the repeat timer.\n            this._repeatTimer = window.setTimeout(this._onRepeat, 350);\n            // Emit the step requested signal.\n            this._stepRequested.emit('decrement');\n            // Finished.\n            return;\n        }\n        // Handle an increment button press.\n        if (part === 'increment') {\n            // Add the active class to the increment node.\n            this.incrementNode.classList.add('lm-mod-active');\n            /* <DEPRECATED> */\n            this.incrementNode.classList.add('p-mod-active');\n            /* </DEPRECATED> */\n            // Start the repeat timer.\n            this._repeatTimer = window.setTimeout(this._onRepeat, 350);\n            // Emit the step requested signal.\n            this._stepRequested.emit('increment');\n            // Finished.\n            return;\n        }\n    };\n    /**\n     * Handle the `'mousemove'` event for the scroll bar.\n     */\n    ScrollBar.prototype._evtMouseMove = function (event) {\n        // Do nothing if no drag is in progress.\n        if (!this._pressData) {\n            return;\n        }\n        // Stop the event propagation.\n        event.preventDefault();\n        event.stopPropagation();\n        // Update the mouse position.\n        this._pressData.mouseX = event.clientX;\n        this._pressData.mouseY = event.clientY;\n        // Bail if the thumb is not being dragged.\n        if (this._pressData.part !== 'thumb') {\n            return;\n        }\n        // Get the client rect for the thumb and track.\n        var thumbRect = this.thumbNode.getBoundingClientRect();\n        var trackRect = this.trackNode.getBoundingClientRect();\n        // Fetch the scroll geometry based on the orientation.\n        var trackPos;\n        var trackSpan;\n        if (this._orientation === 'horizontal') {\n            trackPos = event.clientX - trackRect.left - this._pressData.delta;\n            trackSpan = trackRect.width - thumbRect.width;\n        }\n        else {\n            trackPos = event.clientY - trackRect.top - this._pressData.delta;\n            trackSpan = trackRect.height - thumbRect.height;\n        }\n        // Compute the desired value from the scroll geometry.\n        var value = trackSpan === 0 ? 0 : trackPos * this._maximum / trackSpan;\n        // Move the thumb to the computed value.\n        this._moveThumb(value);\n    };\n    /**\n     * Handle the `'mouseup'` event for the scroll bar.\n     */\n    ScrollBar.prototype._evtMouseUp = function (event) {\n        // Do nothing if it's not a left mouse release.\n        if (event.button !== 0) {\n            return;\n        }\n        // Stop the event propagation.\n        event.preventDefault();\n        event.stopPropagation();\n        // Release the mouse.\n        this._releaseMouse();\n    };\n    /**\n     * Release the mouse and restore the node states.\n     */\n    ScrollBar.prototype._releaseMouse = function () {\n        // Bail if there is no press data.\n        if (!this._pressData) {\n            return;\n        }\n        // Clear the repeat timer.\n        clearTimeout(this._repeatTimer);\n        this._repeatTimer = -1;\n        // Clear the press data.\n        this._pressData.override.dispose();\n        this._pressData = null;\n        // Remove the extra event listeners.\n        document.removeEventListener('mousemove', this, true);\n        document.removeEventListener('mouseup', this, true);\n        document.removeEventListener('keydown', this, true);\n        document.removeEventListener('contextmenu', this, true);\n        // Remove the active classes from the nodes.\n        this.thumbNode.classList.remove('lm-mod-active');\n        this.decrementNode.classList.remove('lm-mod-active');\n        this.incrementNode.classList.remove('lm-mod-active');\n        /* <DEPRECATED> */\n        this.thumbNode.classList.remove('p-mod-active');\n        this.decrementNode.classList.remove('p-mod-active');\n        this.incrementNode.classList.remove('p-mod-active');\n        /* </DEPRECATED> */\n    };\n    /**\n     * Move the thumb to the specified position.\n     */\n    ScrollBar.prototype._moveThumb = function (value) {\n        // Clamp the value to the allowed range.\n        value = Math.max(0, Math.min(value, this._maximum));\n        // Bail if the value does not change.\n        if (this._value === value) {\n            return;\n        }\n        // Update the internal value.\n        this._value = value;\n        // Schedule an update of the scroll bar.\n        this.update();\n        // Emit the thumb moved signal.\n        this._thumbMoved.emit(value);\n    };\n    return ScrollBar;\n}(Widget));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$d;\n(function (Private) {\n    /**\n     * Create the DOM node for a scroll bar.\n     */\n    function createNode() {\n        var node = document.createElement('div');\n        var decrement = document.createElement('div');\n        var increment = document.createElement('div');\n        var track = document.createElement('div');\n        var thumb = document.createElement('div');\n        decrement.className = 'lm-ScrollBar-button';\n        increment.className = 'lm-ScrollBar-button';\n        decrement.dataset['action'] = 'decrement';\n        increment.dataset['action'] = 'increment';\n        track.className = 'lm-ScrollBar-track';\n        thumb.className = 'lm-ScrollBar-thumb';\n        /* <DEPRECATED> */\n        decrement.classList.add('p-ScrollBar-button');\n        increment.classList.add('p-ScrollBar-button');\n        track.classList.add('p-ScrollBar-track');\n        thumb.classList.add('p-ScrollBar-thumb');\n        /* </DEPRECATED> */\n        track.appendChild(thumb);\n        node.appendChild(decrement);\n        node.appendChild(track);\n        node.appendChild(increment);\n        return node;\n    }\n    Private.createNode = createNode;\n    /**\n     * Find the scroll bar part which contains the given target.\n     */\n    function findPart(scrollBar, target) {\n        // Test the thumb.\n        if (scrollBar.thumbNode.contains(target)) {\n            return 'thumb';\n        }\n        // Test the track.\n        if (scrollBar.trackNode.contains(target)) {\n            return 'track';\n        }\n        // Test the decrement button.\n        if (scrollBar.decrementNode.contains(target)) {\n            return 'decrement';\n        }\n        // Test the increment button.\n        if (scrollBar.incrementNode.contains(target)) {\n            return 'increment';\n        }\n        // Indicate no match.\n        return null;\n    }\n    Private.findPart = findPart;\n})(Private$d || (Private$d = {}));\n\n/**\n * A concrete layout implementation which holds a single widget.\n *\n * #### Notes\n * This class is useful for creating simple container widgets which\n * hold a single child. The child should be positioned with CSS.\n */\nvar SingletonLayout = /** @class */ (function (_super) {\n    __extends(SingletonLayout, _super);\n    function SingletonLayout() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._widget = null;\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the layout.\n     */\n    SingletonLayout.prototype.dispose = function () {\n        if (this._widget) {\n            var widget = this._widget;\n            this._widget = null;\n            widget.dispose();\n        }\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(SingletonLayout.prototype, \"widget\", {\n        /**\n         * Get the child widget for the layout.\n         */\n        get: function () {\n            return this._widget;\n        },\n        /**\n         * Set the child widget for the layout.\n         *\n         * #### Notes\n         * Setting the child widget will cause the old child widget to be\n         * automatically disposed. If that is not desired, set the parent\n         * of the old child to `null` before assigning a new child.\n         */\n        set: function (widget) {\n            // Remove the widget from its current parent. This is a no-op\n            // if the widget's parent is already the layout parent widget.\n            if (widget) {\n                widget.parent = this.parent;\n            }\n            // Bail early if the widget does not change.\n            if (this._widget === widget) {\n                return;\n            }\n            // Dispose of the old child widget.\n            if (this._widget) {\n                this._widget.dispose();\n            }\n            // Update the internal widget.\n            this._widget = widget;\n            // Attach the new child widget if needed.\n            if (this.parent && widget) {\n                this.attachWidget(widget);\n            }\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Create an iterator over the widgets in the layout.\n     *\n     * @returns A new iterator over the widgets in the layout.\n     */\n    SingletonLayout.prototype.iter = function () {\n        return this._widget ? once(this._widget) : empty();\n    };\n    /**\n     * Remove a widget from the layout.\n     *\n     * @param widget - The widget to remove from the layout.\n     *\n     * #### Notes\n     * A widget is automatically removed from the layout when its `parent`\n     * is set to `null`. This method should only be invoked directly when\n     * removing a widget from a layout which has yet to be installed on a\n     * parent widget.\n     *\n     * This method does *not* modify the widget's `parent`.\n     */\n    SingletonLayout.prototype.removeWidget = function (widget) {\n        // Bail early if the widget does not exist in the layout.\n        if (this._widget !== widget) {\n            return;\n        }\n        // Clear the internal widget.\n        this._widget = null;\n        // If the layout is parented, detach the widget from the DOM.\n        if (this.parent) {\n            this.detachWidget(widget);\n        }\n    };\n    /**\n     * Perform layout initialization which requires the parent widget.\n     */\n    SingletonLayout.prototype.init = function () {\n        var _this = this;\n        _super.prototype.init.call(this);\n        each(this, function (widget) { _this.attachWidget(widget); });\n    };\n    /**\n     * Attach a widget to the parent's DOM node.\n     *\n     * @param index - The current index of the widget in the layout.\n     *\n     * @param widget - The widget to attach to the parent.\n     *\n     * #### Notes\n     * This method is called automatically by the single layout at the\n     * appropriate time. It should not be called directly by user code.\n     *\n     * The default implementation adds the widgets's node to the parent's\n     * node at the proper location, and sends the appropriate attach\n     * messages to the widget if the parent is attached to the DOM.\n     *\n     * Subclasses may reimplement this method to control how the widget's\n     * node is added to the parent's node.\n     */\n    SingletonLayout.prototype.attachWidget = function (widget) {\n        // Send a `'before-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeAttach);\n        }\n        // Add the widget's node to the parent.\n        this.parent.node.appendChild(widget.node);\n        // Send an `'after-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterAttach);\n        }\n    };\n    /**\n     * Detach a widget from the parent's DOM node.\n     *\n     * @param widget - The widget to detach from the parent.\n     *\n     * #### Notes\n     * This method is called automatically by the single layout at the\n     * appropriate time. It should not be called directly by user code.\n     *\n     * The default implementation removes the widget's node from the\n     * parent's node, and sends the appropriate detach messages to the\n     * widget if the parent is attached to the DOM.\n     *\n     * Subclasses may reimplement this method to control how the widget's\n     * node is removed from the parent's node.\n     */\n    SingletonLayout.prototype.detachWidget = function (widget) {\n        // Send a `'before-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeDetach);\n        }\n        // Remove the widget's node from the parent.\n        this.parent.node.removeChild(widget.node);\n        // Send an `'after-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterDetach);\n        }\n    };\n    return SingletonLayout;\n}(Layout));\n\n/**\n * A layout which arranges its widgets into resizable sections.\n */\nvar SplitLayout = /** @class */ (function (_super) {\n    __extends(SplitLayout, _super);\n    /**\n     * Construct a new split layout.\n     *\n     * @param options - The options for initializing the layout.\n     */\n    function SplitLayout(options) {\n        var _this = _super.call(this) || this;\n        _this._fixed = 0;\n        _this._spacing = 4;\n        _this._dirty = false;\n        _this._hasNormedSizes = false;\n        _this._sizers = [];\n        _this._items = [];\n        _this._handles = [];\n        _this._box = null;\n        _this._alignment = 'start';\n        _this._orientation = 'horizontal';\n        _this.renderer = options.renderer;\n        if (options.orientation !== undefined) {\n            _this._orientation = options.orientation;\n        }\n        if (options.alignment !== undefined) {\n            _this._alignment = options.alignment;\n        }\n        if (options.spacing !== undefined) {\n            _this._spacing = Private$e.clampSpacing(options.spacing);\n        }\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the layout.\n     */\n    SplitLayout.prototype.dispose = function () {\n        // Dispose of the layout items.\n        each(this._items, function (item) { item.dispose(); });\n        // Clear the layout state.\n        this._box = null;\n        this._items.length = 0;\n        this._sizers.length = 0;\n        this._handles.length = 0;\n        // Dispose of the rest of the layout.\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(SplitLayout.prototype, \"orientation\", {\n        /**\n         * Get the layout orientation for the split layout.\n         */\n        get: function () {\n            return this._orientation;\n        },\n        /**\n         * Set the layout orientation for the split layout.\n         */\n        set: function (value) {\n            if (this._orientation === value) {\n                return;\n            }\n            this._orientation = value;\n            if (!this.parent) {\n                return;\n            }\n            this.parent.dataset['orientation'] = value;\n            this.parent.fit();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(SplitLayout.prototype, \"alignment\", {\n        /**\n         * Get the content alignment for the split layout.\n         *\n         * #### Notes\n         * This is the alignment of the widgets in the layout direction.\n         *\n         * The alignment has no effect if the widgets can expand  to fill the\n         * entire split layout.\n         */\n        get: function () {\n            return this._alignment;\n        },\n        /**\n         * Set the content alignment for the split layout.\n         *\n         * #### Notes\n         * This is the alignment of the widgets in the layout direction.\n         *\n         * The alignment has no effect if the widgets can expand  to fill the\n         * entire split layout.\n         */\n        set: function (value) {\n            if (this._alignment === value) {\n                return;\n            }\n            this._alignment = value;\n            if (!this.parent) {\n                return;\n            }\n            this.parent.dataset['alignment'] = value;\n            this.parent.update();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(SplitLayout.prototype, \"spacing\", {\n        /**\n         * Get the inter-element spacing for the split layout.\n         */\n        get: function () {\n            return this._spacing;\n        },\n        /**\n         * Set the inter-element spacing for the split layout.\n         */\n        set: function (value) {\n            value = Private$e.clampSpacing(value);\n            if (this._spacing === value) {\n                return;\n            }\n            this._spacing = value;\n            if (!this.parent) {\n                return;\n            }\n            this.parent.fit();\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(SplitLayout.prototype, \"handles\", {\n        /**\n         * A read-only array of the split handles in the layout.\n         */\n        get: function () {\n            return this._handles;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Get the relative sizes of the widgets in the layout.\n     *\n     * @returns A new array of the relative sizes of the widgets.\n     *\n     * #### Notes\n     * The returned sizes reflect the sizes of the widgets normalized\n     * relative to their siblings.\n     *\n     * This method **does not** measure the DOM nodes.\n     */\n    SplitLayout.prototype.relativeSizes = function () {\n        return Private$e.normalize(this._sizers.map(function (sizer) { return sizer.size; }));\n    };\n    /**\n     * Set the relative sizes for the widgets in the layout.\n     *\n     * @param sizes - The relative sizes for the widgets in the panel.\n     *\n     * #### Notes\n     * Extra values are ignored, too few will yield an undefined layout.\n     *\n     * The actual geometry of the DOM nodes is updated asynchronously.\n     */\n    SplitLayout.prototype.setRelativeSizes = function (sizes) {\n        // Copy the sizes and pad with zeros as needed.\n        var n = this._sizers.length;\n        var temp = sizes.slice(0, n);\n        while (temp.length < n) {\n            temp.push(0);\n        }\n        // Normalize the padded sizes.\n        var normed = Private$e.normalize(temp);\n        // Apply the normalized sizes to the sizers.\n        for (var i = 0; i < n; ++i) {\n            var sizer = this._sizers[i];\n            sizer.sizeHint = normed[i];\n            sizer.size = normed[i];\n        }\n        // Set the flag indicating the sizes are normalized.\n        this._hasNormedSizes = true;\n        // Trigger an update of the parent widget.\n        if (this.parent) {\n            this.parent.update();\n        }\n    };\n    /**\n     * Move the offset position of a split handle.\n     *\n     * @param index - The index of the handle of the interest.\n     *\n     * @param position - The desired offset position of the handle.\n     *\n     * #### Notes\n     * The position is relative to the offset parent.\n     *\n     * This will move the handle as close as possible to the desired\n     * position. The sibling widgets will be adjusted as necessary.\n     */\n    SplitLayout.prototype.moveHandle = function (index, position) {\n        // Bail if the index is invalid or the handle is hidden.\n        var handle = this._handles[index];\n        if (!handle || handle.classList.contains('lm-mod-hidden')) {\n            return;\n        }\n        // Compute the desired delta movement for the handle.\n        var delta;\n        if (this._orientation === 'horizontal') {\n            delta = position - handle.offsetLeft;\n        }\n        else {\n            delta = position - handle.offsetTop;\n        }\n        // Bail if there is no handle movement.\n        if (delta === 0) {\n            return;\n        }\n        // Prevent widget resizing unless needed.\n        for (var _i = 0, _a = this._sizers; _i < _a.length; _i++) {\n            var sizer = _a[_i];\n            if (sizer.size > 0) {\n                sizer.sizeHint = sizer.size;\n            }\n        }\n        // Adjust the sizers to reflect the handle movement.\n        BoxEngine.adjust(this._sizers, index, delta);\n        // Update the layout of the widgets.\n        if (this.parent) {\n            this.parent.update();\n        }\n    };\n    /**\n     * Perform layout initialization which requires the parent widget.\n     */\n    SplitLayout.prototype.init = function () {\n        this.parent.dataset['orientation'] = this.orientation;\n        this.parent.dataset['alignment'] = this.alignment;\n        _super.prototype.init.call(this);\n    };\n    /**\n     * Attach a widget to the parent's DOM node.\n     *\n     * @param index - The current index of the widget in the layout.\n     *\n     * @param widget - The widget to attach to the parent.\n     *\n     * #### Notes\n     * This is a reimplementation of the superclass method.\n     */\n    SplitLayout.prototype.attachWidget = function (index, widget) {\n        // Create the item, handle, and sizer for the new widget.\n        var item = new LayoutItem(widget);\n        var handle = Private$e.createHandle(this.renderer);\n        var average = Private$e.averageSize(this._sizers);\n        var sizer = Private$e.createSizer(average);\n        // Insert the item, handle, and sizer into the internal arrays.\n        ArrayExt.insert(this._items, index, item);\n        ArrayExt.insert(this._sizers, index, sizer);\n        ArrayExt.insert(this._handles, index, handle);\n        // Send a `'before-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeAttach);\n        }\n        // Add the widget and handle nodes to the parent.\n        this.parent.node.appendChild(widget.node);\n        this.parent.node.appendChild(handle);\n        // Send an `'after-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterAttach);\n        }\n        // Post a fit request for the parent widget.\n        this.parent.fit();\n    };\n    /**\n     * Move a widget in the parent's DOM node.\n     *\n     * @param fromIndex - The previous index of the widget in the layout.\n     *\n     * @param toIndex - The current index of the widget in the layout.\n     *\n     * @param widget - The widget to move in the parent.\n     *\n     * #### Notes\n     * This is a reimplementation of the superclass method.\n     */\n    SplitLayout.prototype.moveWidget = function (fromIndex, toIndex, widget) {\n        // Move the item, sizer, and handle for the widget.\n        ArrayExt.move(this._items, fromIndex, toIndex);\n        ArrayExt.move(this._sizers, fromIndex, toIndex);\n        ArrayExt.move(this._handles, fromIndex, toIndex);\n        // Post a fit request to the parent to show/hide last handle.\n        this.parent.fit();\n    };\n    /**\n     * Detach a widget from the parent's DOM node.\n     *\n     * @param index - The previous index of the widget in the layout.\n     *\n     * @param widget - The widget to detach from the parent.\n     *\n     * #### Notes\n     * This is a reimplementation of the superclass method.\n     */\n    SplitLayout.prototype.detachWidget = function (index, widget) {\n        // Remove the item, handle, and sizer for the widget.\n        var item = ArrayExt.removeAt(this._items, index);\n        var handle = ArrayExt.removeAt(this._handles, index);\n        ArrayExt.removeAt(this._sizers, index);\n        // Send a `'before-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeDetach);\n        }\n        // Remove the widget and handle nodes from the parent.\n        this.parent.node.removeChild(widget.node);\n        this.parent.node.removeChild(handle);\n        // Send an `'after-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterDetach);\n        }\n        // Dispose of the layout item.\n        item.dispose();\n        // Post a fit request for the parent widget.\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'before-show'` message.\n     */\n    SplitLayout.prototype.onBeforeShow = function (msg) {\n        _super.prototype.onBeforeShow.call(this, msg);\n        this.parent.update();\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     */\n    SplitLayout.prototype.onBeforeAttach = function (msg) {\n        _super.prototype.onBeforeAttach.call(this, msg);\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'child-shown'` message.\n     */\n    SplitLayout.prototype.onChildShown = function (msg) {\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'child-hidden'` message.\n     */\n    SplitLayout.prototype.onChildHidden = function (msg) {\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'resize'` message.\n     */\n    SplitLayout.prototype.onResize = function (msg) {\n        if (this.parent.isVisible) {\n            this._update(msg.width, msg.height);\n        }\n    };\n    /**\n     * A message handler invoked on an `'update-request'` message.\n     */\n    SplitLayout.prototype.onUpdateRequest = function (msg) {\n        if (this.parent.isVisible) {\n            this._update(-1, -1);\n        }\n    };\n    /**\n     * A message handler invoked on a `'fit-request'` message.\n     */\n    SplitLayout.prototype.onFitRequest = function (msg) {\n        if (this.parent.isAttached) {\n            this._fit();\n        }\n    };\n    /**\n     * Fit the layout to the total size required by the widgets.\n     */\n    SplitLayout.prototype._fit = function () {\n        // Update the handles and track the visible widget count.\n        var nVisible = 0;\n        var lastHandleIndex = -1;\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            if (this._items[i].isHidden) {\n                this._handles[i].classList.add('lm-mod-hidden');\n                /* <DEPRECATED> */\n                this._handles[i].classList.add('p-mod-hidden');\n                /* </DEPRECATED> */\n            }\n            else {\n                this._handles[i].classList.remove('lm-mod-hidden');\n                /* <DEPRECATED> */\n                this._handles[i].classList.remove('p-mod-hidden');\n                /* </DEPRECATED> */\n                lastHandleIndex = i;\n                nVisible++;\n            }\n        }\n        // Hide the handle for the last visible widget.\n        if (lastHandleIndex !== -1) {\n            this._handles[lastHandleIndex].classList.add('lm-mod-hidden');\n            /* <DEPRECATED> */\n            this._handles[lastHandleIndex].classList.add('p-mod-hidden');\n            /* </DEPRECATED> */\n        }\n        // Update the fixed space for the visible items.\n        this._fixed = this._spacing * Math.max(0, nVisible - 1);\n        // Setup the computed minimum size.\n        var horz = this._orientation === 'horizontal';\n        var minW = horz ? this._fixed : 0;\n        var minH = horz ? 0 : this._fixed;\n        // Update the sizers and computed size limits.\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            // Fetch the item and corresponding box sizer.\n            var item = this._items[i];\n            var sizer = this._sizers[i];\n            // Prevent resizing unless necessary.\n            if (sizer.size > 0) {\n                sizer.sizeHint = sizer.size;\n            }\n            // If the item is hidden, it should consume zero size.\n            if (item.isHidden) {\n                sizer.minSize = 0;\n                sizer.maxSize = 0;\n                continue;\n            }\n            // Update the size limits for the item.\n            item.fit();\n            // Update the stretch factor.\n            sizer.stretch = SplitLayout.getStretch(item.widget);\n            // Update the sizer limits and computed min size.\n            if (horz) {\n                sizer.minSize = item.minWidth;\n                sizer.maxSize = item.maxWidth;\n                minW += item.minWidth;\n                minH = Math.max(minH, item.minHeight);\n            }\n            else {\n                sizer.minSize = item.minHeight;\n                sizer.maxSize = item.maxHeight;\n                minH += item.minHeight;\n                minW = Math.max(minW, item.minWidth);\n            }\n        }\n        // Update the box sizing and add it to the computed min size.\n        var box = this._box = ElementExt.boxSizing(this.parent.node);\n        minW += box.horizontalSum;\n        minH += box.verticalSum;\n        // Update the parent's min size constraints.\n        var style = this.parent.node.style;\n        style.minWidth = minW + \"px\";\n        style.minHeight = minH + \"px\";\n        // Set the dirty flag to ensure only a single update occurs.\n        this._dirty = true;\n        // Notify the ancestor that it should fit immediately. This may\n        // cause a resize of the parent, fulfilling the required update.\n        if (this.parent.parent) {\n            MessageLoop.sendMessage(this.parent.parent, Widget.Msg.FitRequest);\n        }\n        // If the dirty flag is still set, the parent was not resized.\n        // Trigger the required update on the parent widget immediately.\n        if (this._dirty) {\n            MessageLoop.sendMessage(this.parent, Widget.Msg.UpdateRequest);\n        }\n    };\n    /**\n     * Update the layout position and size of the widgets.\n     *\n     * The parent offset dimensions should be `-1` if unknown.\n     */\n    SplitLayout.prototype._update = function (offsetWidth, offsetHeight) {\n        // Clear the dirty flag to indicate the update occurred.\n        this._dirty = false;\n        // Compute the visible item count.\n        var nVisible = 0;\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            nVisible += +!this._items[i].isHidden;\n        }\n        // Bail early if there are no visible items to layout.\n        if (nVisible === 0) {\n            return;\n        }\n        // Measure the parent if the offset dimensions are unknown.\n        if (offsetWidth < 0) {\n            offsetWidth = this.parent.node.offsetWidth;\n        }\n        if (offsetHeight < 0) {\n            offsetHeight = this.parent.node.offsetHeight;\n        }\n        // Ensure the parent box sizing data is computed.\n        if (!this._box) {\n            this._box = ElementExt.boxSizing(this.parent.node);\n        }\n        // Compute the actual layout bounds adjusted for border and padding.\n        var top = this._box.paddingTop;\n        var left = this._box.paddingLeft;\n        var width = offsetWidth - this._box.horizontalSum;\n        var height = offsetHeight - this._box.verticalSum;\n        // Compute the adjusted layout space.\n        var space;\n        var horz = this._orientation === 'horizontal';\n        if (horz) {\n            space = Math.max(0, width - this._fixed);\n        }\n        else {\n            space = Math.max(0, height - this._fixed);\n        }\n        // Scale the size hints if they are normalized.\n        if (this._hasNormedSizes) {\n            for (var _i = 0, _a = this._sizers; _i < _a.length; _i++) {\n                var sizer = _a[_i];\n                sizer.sizeHint *= space;\n            }\n            this._hasNormedSizes = false;\n        }\n        // Distribute the layout space to the box sizers.\n        var delta = BoxEngine.calc(this._sizers, space);\n        // Set up the variables for justification and alignment offset.\n        var extra = 0;\n        var offset = 0;\n        // Account for alignment if there is extra layout space.\n        if (delta > 0) {\n            switch (this._alignment) {\n                case 'start':\n                    break;\n                case 'center':\n                    extra = 0;\n                    offset = delta / 2;\n                    break;\n                case 'end':\n                    extra = 0;\n                    offset = delta;\n                    break;\n                case 'justify':\n                    extra = delta / nVisible;\n                    offset = 0;\n                    break;\n                default:\n                    throw 'unreachable';\n            }\n        }\n        // Layout the items using the computed box sizes.\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            // Fetch the item.\n            var item = this._items[i];\n            // Ignore hidden items.\n            if (item.isHidden) {\n                continue;\n            }\n            // Fetch the computed size for the widget.\n            var size = this._sizers[i].size;\n            // Fetch the style for the handle.\n            var handleStyle = this._handles[i].style;\n            // Update the widget and handle, and advance the relevant edge.\n            if (horz) {\n                item.update(left + offset, top, size + extra, height);\n                left += size + extra;\n                handleStyle.top = top + \"px\";\n                handleStyle.left = left + offset + \"px\";\n                handleStyle.width = this._spacing + \"px\";\n                handleStyle.height = height + \"px\";\n                left += this._spacing;\n            }\n            else {\n                item.update(left, top + offset, width, size + extra);\n                top += size + extra;\n                handleStyle.top = top + offset + \"px\";\n                handleStyle.left = left + \"px\";\n                handleStyle.width = width + \"px\";\n                handleStyle.height = this._spacing + \"px\";\n                top += this._spacing;\n            }\n        }\n    };\n    return SplitLayout;\n}(PanelLayout));\n/**\n * The namespace for the `SplitLayout` class statics.\n */\n(function (SplitLayout) {\n    /**\n     * Get the split layout stretch factor for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @returns The split layout stretch factor for the widget.\n     */\n    function getStretch(widget) {\n        return Private$e.stretchProperty.get(widget);\n    }\n    SplitLayout.getStretch = getStretch;\n    /**\n     * Set the split layout stretch factor for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @param value - The value for the stretch factor.\n     */\n    function setStretch(widget, value) {\n        Private$e.stretchProperty.set(widget, value);\n    }\n    SplitLayout.setStretch = setStretch;\n})(SplitLayout || (SplitLayout = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$e;\n(function (Private) {\n    /**\n     * The property descriptor for a widget stretch factor.\n     */\n    Private.stretchProperty = new AttachedProperty({\n        name: 'stretch',\n        create: function () { return 0; },\n        coerce: function (owner, value) { return Math.max(0, Math.floor(value)); },\n        changed: onChildSizingChanged\n    });\n    /**\n     * Create a new box sizer with the given size hint.\n     */\n    function createSizer(size) {\n        var sizer = new BoxSizer();\n        sizer.sizeHint = Math.floor(size);\n        return sizer;\n    }\n    Private.createSizer = createSizer;\n    /**\n     * Create a new split handle node using the given renderer.\n     */\n    function createHandle(renderer) {\n        var handle = renderer.createHandle();\n        handle.style.position = 'absolute';\n        return handle;\n    }\n    Private.createHandle = createHandle;\n    /**\n     * Clamp a spacing value to an integer >= 0.\n     */\n    function clampSpacing(value) {\n        return Math.max(0, Math.floor(value));\n    }\n    Private.clampSpacing = clampSpacing;\n    /**\n     * Compute the average size of an array of box sizers.\n     */\n    function averageSize(sizers) {\n        return sizers.reduce(function (v, s) { return v + s.size; }, 0) / sizers.length || 0;\n    }\n    Private.averageSize = averageSize;\n    /**\n     * Normalize an array of values.\n     */\n    function normalize(values) {\n        var n = values.length;\n        if (n === 0) {\n            return [];\n        }\n        var sum = values.reduce(function (a, b) { return a + Math.abs(b); }, 0);\n        return sum === 0 ? values.map(function (v) { return 1 / n; }) : values.map(function (v) { return v / sum; });\n    }\n    Private.normalize = normalize;\n    /**\n     * The change handler for the attached sizing properties.\n     */\n    function onChildSizingChanged(child) {\n        if (child.parent && child.parent.layout instanceof SplitLayout) {\n            child.parent.fit();\n        }\n    }\n})(Private$e || (Private$e = {}));\n\n/**\n * A panel which arranges its widgets into resizable sections.\n *\n * #### Notes\n * This class provides a convenience wrapper around a [[SplitLayout]].\n */\nvar SplitPanel = /** @class */ (function (_super) {\n    __extends(SplitPanel, _super);\n    /**\n     * Construct a new split panel.\n     *\n     * @param options - The options for initializing the split panel.\n     */\n    function SplitPanel(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this, { layout: Private$f.createLayout(options) }) || this;\n        _this._pressData = null;\n        _this.addClass('lm-SplitPanel');\n        /* <DEPRECATED> */\n        _this.addClass('p-SplitPanel');\n        return _this;\n        /* </DEPRECATED> */\n    }\n    /**\n     * Dispose of the resources held by the panel.\n     */\n    SplitPanel.prototype.dispose = function () {\n        this._releaseMouse();\n        _super.prototype.dispose.call(this);\n    };\n    Object.defineProperty(SplitPanel.prototype, \"orientation\", {\n        /**\n         * Get the layout orientation for the split panel.\n         */\n        get: function () {\n            return this.layout.orientation;\n        },\n        /**\n         * Set the layout orientation for the split panel.\n         */\n        set: function (value) {\n            this.layout.orientation = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(SplitPanel.prototype, \"alignment\", {\n        /**\n         * Get the content alignment for the split panel.\n         *\n         * #### Notes\n         * This is the alignment of the widgets in the layout direction.\n         *\n         * The alignment has no effect if the widgets can expand to fill the\n         * entire split panel.\n         */\n        get: function () {\n            return this.layout.alignment;\n        },\n        /**\n         * Set the content alignment for the split panel.\n         *\n         * #### Notes\n         * This is the alignment of the widgets in the layout direction.\n         *\n         * The alignment has no effect if the widgets can expand to fill the\n         * entire split panel.\n         */\n        set: function (value) {\n            this.layout.alignment = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(SplitPanel.prototype, \"spacing\", {\n        /**\n         * Get the inter-element spacing for the split panel.\n         */\n        get: function () {\n            return this.layout.spacing;\n        },\n        /**\n         * Set the inter-element spacing for the split panel.\n         */\n        set: function (value) {\n            this.layout.spacing = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(SplitPanel.prototype, \"renderer\", {\n        /**\n         * The renderer used by the split panel.\n         */\n        get: function () {\n            return this.layout.renderer;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(SplitPanel.prototype, \"handles\", {\n        /**\n         * A read-only array of the split handles in the panel.\n         */\n        get: function () {\n            return this.layout.handles;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Get the relative sizes of the widgets in the panel.\n     *\n     * @returns A new array of the relative sizes of the widgets.\n     *\n     * #### Notes\n     * The returned sizes reflect the sizes of the widgets normalized\n     * relative to their siblings.\n     *\n     * This method **does not** measure the DOM nodes.\n     */\n    SplitPanel.prototype.relativeSizes = function () {\n        return this.layout.relativeSizes();\n    };\n    /**\n     * Set the relative sizes for the widgets in the panel.\n     *\n     * @param sizes - The relative sizes for the widgets in the panel.\n     *\n     * #### Notes\n     * Extra values are ignored, too few will yield an undefined layout.\n     *\n     * The actual geometry of the DOM nodes is updated asynchronously.\n     */\n    SplitPanel.prototype.setRelativeSizes = function (sizes) {\n        this.layout.setRelativeSizes(sizes);\n    };\n    /**\n     * Handle the DOM events for the split panel.\n     *\n     * @param event - The DOM event sent to the panel.\n     *\n     * #### Notes\n     * This method implements the DOM `EventListener` interface and is\n     * called in response to events on the panel's DOM node. It should\n     * not be called directly by user code.\n     */\n    SplitPanel.prototype.handleEvent = function (event) {\n        switch (event.type) {\n            case 'mousedown':\n                this._evtMouseDown(event);\n                break;\n            case 'mousemove':\n                this._evtMouseMove(event);\n                break;\n            case 'mouseup':\n                this._evtMouseUp(event);\n                break;\n            case 'keydown':\n                this._evtKeyDown(event);\n                break;\n            case 'contextmenu':\n                event.preventDefault();\n                event.stopPropagation();\n                break;\n        }\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     */\n    SplitPanel.prototype.onBeforeAttach = function (msg) {\n        this.node.addEventListener('mousedown', this);\n    };\n    /**\n     * A message handler invoked on an `'after-detach'` message.\n     */\n    SplitPanel.prototype.onAfterDetach = function (msg) {\n        this.node.removeEventListener('mousedown', this);\n        this._releaseMouse();\n    };\n    /**\n     * A message handler invoked on a `'child-added'` message.\n     */\n    SplitPanel.prototype.onChildAdded = function (msg) {\n        msg.child.addClass('lm-SplitPanel-child');\n        /* <DEPRECATED> */\n        msg.child.addClass('p-SplitPanel-child');\n        /* </DEPRECATED> */\n        this._releaseMouse();\n    };\n    /**\n     * A message handler invoked on a `'child-removed'` message.\n     */\n    SplitPanel.prototype.onChildRemoved = function (msg) {\n        msg.child.removeClass('lm-SplitPanel-child');\n        /* <DEPRECATED> */\n        msg.child.removeClass('p-SplitPanel-child');\n        /* </DEPRECATED> */\n        this._releaseMouse();\n    };\n    /**\n     * Handle the `'keydown'` event for the split panel.\n     */\n    SplitPanel.prototype._evtKeyDown = function (event) {\n        // Stop input events during drag.\n        event.preventDefault();\n        event.stopPropagation();\n        // Release the mouse if `Escape` is pressed.\n        if (event.keyCode === 27) {\n            this._releaseMouse();\n        }\n    };\n    /**\n     * Handle the `'mousedown'` event for the split panel.\n     */\n    SplitPanel.prototype._evtMouseDown = function (event) {\n        // Do nothing if the left mouse button is not pressed.\n        if (event.button !== 0) {\n            return;\n        }\n        // Find the handle which contains the mouse target, if any.\n        var layout = this.layout;\n        var index = ArrayExt.findFirstIndex(layout.handles, function (handle) {\n            return handle.contains(event.target);\n        });\n        // Bail early if the mouse press was not on a handle.\n        if (index === -1) {\n            return;\n        }\n        // Stop the event when a split handle is pressed.\n        event.preventDefault();\n        event.stopPropagation();\n        // Add the extra document listeners.\n        document.addEventListener('mouseup', this, true);\n        document.addEventListener('mousemove', this, true);\n        document.addEventListener('keydown', this, true);\n        document.addEventListener('contextmenu', this, true);\n        // Compute the offset delta for the handle press.\n        var delta;\n        var handle = layout.handles[index];\n        var rect = handle.getBoundingClientRect();\n        if (layout.orientation === 'horizontal') {\n            delta = event.clientX - rect.left;\n        }\n        else {\n            delta = event.clientY - rect.top;\n        }\n        // Override the cursor and store the press data.\n        var style = window.getComputedStyle(handle);\n        var override = Drag.overrideCursor(style.cursor);\n        this._pressData = { index: index, delta: delta, override: override };\n    };\n    /**\n     * Handle the `'mousemove'` event for the split panel.\n     */\n    SplitPanel.prototype._evtMouseMove = function (event) {\n        // Stop the event when dragging a split handle.\n        event.preventDefault();\n        event.stopPropagation();\n        // Compute the desired offset position for the handle.\n        var pos;\n        var layout = this.layout;\n        var rect = this.node.getBoundingClientRect();\n        if (layout.orientation === 'horizontal') {\n            pos = event.clientX - rect.left - this._pressData.delta;\n        }\n        else {\n            pos = event.clientY - rect.top - this._pressData.delta;\n        }\n        // Move the handle as close to the desired position as possible.\n        layout.moveHandle(this._pressData.index, pos);\n    };\n    /**\n     * Handle the `'mouseup'` event for the split panel.\n     */\n    SplitPanel.prototype._evtMouseUp = function (event) {\n        // Do nothing if the left mouse button is not released.\n        if (event.button !== 0) {\n            return;\n        }\n        // Stop the event when releasing a handle.\n        event.preventDefault();\n        event.stopPropagation();\n        // Finalize the mouse release.\n        this._releaseMouse();\n    };\n    /**\n     * Release the mouse grab for the split panel.\n     */\n    SplitPanel.prototype._releaseMouse = function () {\n        // Bail early if no drag is in progress.\n        if (!this._pressData) {\n            return;\n        }\n        // Clear the override cursor.\n        this._pressData.override.dispose();\n        this._pressData = null;\n        // Remove the extra document listeners.\n        document.removeEventListener('mouseup', this, true);\n        document.removeEventListener('mousemove', this, true);\n        document.removeEventListener('keydown', this, true);\n        document.removeEventListener('contextmenu', this, true);\n    };\n    return SplitPanel;\n}(Panel));\n/**\n * The namespace for the `SplitPanel` class statics.\n */\n(function (SplitPanel) {\n    /**\n     * The default implementation of `IRenderer`.\n     */\n    var Renderer = /** @class */ (function () {\n        function Renderer() {\n        }\n        /**\n         * Create a new handle for use with a split panel.\n         *\n         * @returns A new handle element for a split panel.\n         */\n        Renderer.prototype.createHandle = function () {\n            var handle = document.createElement('div');\n            handle.className = 'lm-SplitPanel-handle';\n            /* <DEPRECATED> */\n            handle.classList.add('p-SplitPanel-handle');\n            /* </DEPRECATED> */\n            return handle;\n        };\n        return Renderer;\n    }());\n    SplitPanel.Renderer = Renderer;\n    /**\n     * The default `Renderer` instance.\n     */\n    SplitPanel.defaultRenderer = new Renderer();\n    /**\n     * Get the split panel stretch factor for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @returns The split panel stretch factor for the widget.\n     */\n    function getStretch(widget) {\n        return SplitLayout.getStretch(widget);\n    }\n    SplitPanel.getStretch = getStretch;\n    /**\n     * Set the split panel stretch factor for the given widget.\n     *\n     * @param widget - The widget of interest.\n     *\n     * @param value - The value for the stretch factor.\n     */\n    function setStretch(widget, value) {\n        SplitLayout.setStretch(widget, value);\n    }\n    SplitPanel.setStretch = setStretch;\n})(SplitPanel || (SplitPanel = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$f;\n(function (Private) {\n    /**\n     * Create a split layout for the given panel options.\n     */\n    function createLayout(options) {\n        return options.layout || new SplitLayout({\n            renderer: options.renderer || SplitPanel.defaultRenderer,\n            orientation: options.orientation,\n            alignment: options.alignment,\n            spacing: options.spacing\n        });\n    }\n    Private.createLayout = createLayout;\n})(Private$f || (Private$f = {}));\n\n/**\n * A layout where visible widgets are stacked atop one another.\n *\n * #### Notes\n * The Z-order of the visible widgets follows their layout order.\n */\nvar StackedLayout = /** @class */ (function (_super) {\n    __extends(StackedLayout, _super);\n    function StackedLayout() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._dirty = false;\n        _this._items = [];\n        _this._box = null;\n        return _this;\n    }\n    /**\n     * Dispose of the resources held by the layout.\n     */\n    StackedLayout.prototype.dispose = function () {\n        // Dispose of the layout items.\n        each(this._items, function (item) { item.dispose(); });\n        // Clear the layout state.\n        this._box = null;\n        this._items.length = 0;\n        // Dispose of the rest of the layout.\n        _super.prototype.dispose.call(this);\n    };\n    /**\n     * Attach a widget to the parent's DOM node.\n     *\n     * @param index - The current index of the widget in the layout.\n     *\n     * @param widget - The widget to attach to the parent.\n     *\n     * #### Notes\n     * This is a reimplementation of the superclass method.\n     */\n    StackedLayout.prototype.attachWidget = function (index, widget) {\n        // Create and add a new layout item for the widget.\n        ArrayExt.insert(this._items, index, new LayoutItem(widget));\n        // Send a `'before-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeAttach);\n        }\n        // Add the widget's node to the parent.\n        this.parent.node.appendChild(widget.node);\n        // Send an `'after-attach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterAttach);\n        }\n        // Post a fit request for the parent widget.\n        this.parent.fit();\n    };\n    /**\n     * Move a widget in the parent's DOM node.\n     *\n     * @param fromIndex - The previous index of the widget in the layout.\n     *\n     * @param toIndex - The current index of the widget in the layout.\n     *\n     * @param widget - The widget to move in the parent.\n     *\n     * #### Notes\n     * This is a reimplementation of the superclass method.\n     */\n    StackedLayout.prototype.moveWidget = function (fromIndex, toIndex, widget) {\n        // Move the layout item for the widget.\n        ArrayExt.move(this._items, fromIndex, toIndex);\n        // Post an update request for the parent widget.\n        this.parent.update();\n    };\n    /**\n     * Detach a widget from the parent's DOM node.\n     *\n     * @param index - The previous index of the widget in the layout.\n     *\n     * @param widget - The widget to detach from the parent.\n     *\n     * #### Notes\n     * This is a reimplementation of the superclass method.\n     */\n    StackedLayout.prototype.detachWidget = function (index, widget) {\n        // Remove the layout item for the widget.\n        var item = ArrayExt.removeAt(this._items, index);\n        // Send a `'before-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.BeforeDetach);\n        }\n        // Remove the widget's node from the parent.\n        this.parent.node.removeChild(widget.node);\n        // Send an `'after-detach'` message if the parent is attached.\n        if (this.parent.isAttached) {\n            MessageLoop.sendMessage(widget, Widget.Msg.AfterDetach);\n        }\n        // Reset the z-index for the widget.\n        item.widget.node.style.zIndex = '';\n        // Dispose of the layout item.\n        item.dispose();\n        // Post a fit request for the parent widget.\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'before-show'` message.\n     */\n    StackedLayout.prototype.onBeforeShow = function (msg) {\n        _super.prototype.onBeforeShow.call(this, msg);\n        this.parent.update();\n    };\n    /**\n     * A message handler invoked on a `'before-attach'` message.\n     */\n    StackedLayout.prototype.onBeforeAttach = function (msg) {\n        _super.prototype.onBeforeAttach.call(this, msg);\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'child-shown'` message.\n     */\n    StackedLayout.prototype.onChildShown = function (msg) {\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'child-hidden'` message.\n     */\n    StackedLayout.prototype.onChildHidden = function (msg) {\n        this.parent.fit();\n    };\n    /**\n     * A message handler invoked on a `'resize'` message.\n     */\n    StackedLayout.prototype.onResize = function (msg) {\n        if (this.parent.isVisible) {\n            this._update(msg.width, msg.height);\n        }\n    };\n    /**\n     * A message handler invoked on an `'update-request'` message.\n     */\n    StackedLayout.prototype.onUpdateRequest = function (msg) {\n        if (this.parent.isVisible) {\n            this._update(-1, -1);\n        }\n    };\n    /**\n     * A message handler invoked on a `'fit-request'` message.\n     */\n    StackedLayout.prototype.onFitRequest = function (msg) {\n        if (this.parent.isAttached) {\n            this._fit();\n        }\n    };\n    /**\n     * Fit the layout to the total size required by the widgets.\n     */\n    StackedLayout.prototype._fit = function () {\n        // Set up the computed minimum size.\n        var minW = 0;\n        var minH = 0;\n        // Update the computed minimum size.\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            // Fetch the item.\n            var item = this._items[i];\n            // Ignore hidden items.\n            if (item.isHidden) {\n                continue;\n            }\n            // Update the size limits for the item.\n            item.fit();\n            // Update the computed minimum size.\n            minW = Math.max(minW, item.minWidth);\n            minH = Math.max(minH, item.minHeight);\n        }\n        // Update the box sizing and add it to the computed min size.\n        var box = this._box = ElementExt.boxSizing(this.parent.node);\n        minW += box.horizontalSum;\n        minH += box.verticalSum;\n        // Update the parent's min size constraints.\n        var style = this.parent.node.style;\n        style.minWidth = minW + \"px\";\n        style.minHeight = minH + \"px\";\n        // Set the dirty flag to ensure only a single update occurs.\n        this._dirty = true;\n        // Notify the ancestor that it should fit immediately. This may\n        // cause a resize of the parent, fulfilling the required update.\n        if (this.parent.parent) {\n            MessageLoop.sendMessage(this.parent.parent, Widget.Msg.FitRequest);\n        }\n        // If the dirty flag is still set, the parent was not resized.\n        // Trigger the required update on the parent widget immediately.\n        if (this._dirty) {\n            MessageLoop.sendMessage(this.parent, Widget.Msg.UpdateRequest);\n        }\n    };\n    /**\n     * Update the layout position and size of the widgets.\n     *\n     * The parent offset dimensions should be `-1` if unknown.\n     */\n    StackedLayout.prototype._update = function (offsetWidth, offsetHeight) {\n        // Clear the dirty flag to indicate the update occurred.\n        this._dirty = false;\n        // Compute the visible item count.\n        var nVisible = 0;\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            nVisible += +!this._items[i].isHidden;\n        }\n        // Bail early if there are no visible items to layout.\n        if (nVisible === 0) {\n            return;\n        }\n        // Measure the parent if the offset dimensions are unknown.\n        if (offsetWidth < 0) {\n            offsetWidth = this.parent.node.offsetWidth;\n        }\n        if (offsetHeight < 0) {\n            offsetHeight = this.parent.node.offsetHeight;\n        }\n        // Ensure the parent box sizing data is computed.\n        if (!this._box) {\n            this._box = ElementExt.boxSizing(this.parent.node);\n        }\n        // Compute the actual layout bounds adjusted for border and padding.\n        var top = this._box.paddingTop;\n        var left = this._box.paddingLeft;\n        var width = offsetWidth - this._box.horizontalSum;\n        var height = offsetHeight - this._box.verticalSum;\n        // Update the widget stacking order and layout geometry.\n        for (var i = 0, n = this._items.length; i < n; ++i) {\n            // Fetch the item.\n            var item = this._items[i];\n            // Ignore hidden items.\n            if (item.isHidden) {\n                continue;\n            }\n            // Set the z-index for the widget.\n            item.widget.node.style.zIndex = \"\" + i;\n            // Update the item geometry.\n            item.update(left, top, width, height);\n        }\n    };\n    return StackedLayout;\n}(PanelLayout));\n\n/**\n * A panel where visible widgets are stacked atop one another.\n *\n * #### Notes\n * This class provides a convenience wrapper around a [[StackedLayout]].\n */\nvar StackedPanel = /** @class */ (function (_super) {\n    __extends(StackedPanel, _super);\n    /**\n     * Construct a new stacked panel.\n     *\n     * @param options - The options for initializing the panel.\n     */\n    function StackedPanel(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this, { layout: Private$g.createLayout(options) }) || this;\n        _this._widgetRemoved = new Signal(_this);\n        _this.addClass('lm-StackedPanel');\n        /* <DEPRECATED> */\n        _this.addClass('p-StackedPanel');\n        return _this;\n        /* </DEPRECATED> */\n    }\n    Object.defineProperty(StackedPanel.prototype, \"widgetRemoved\", {\n        /**\n         * A signal emitted when a widget is removed from a stacked panel.\n         */\n        get: function () {\n            return this._widgetRemoved;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * A message handler invoked on a `'child-added'` message.\n     */\n    StackedPanel.prototype.onChildAdded = function (msg) {\n        msg.child.addClass('lm-StackedPanel-child');\n        /* <DEPRECATED> */\n        msg.child.addClass('p-StackedPanel-child');\n        /* </DEPRECATED> */\n    };\n    /**\n     * A message handler invoked on a `'child-removed'` message.\n     */\n    StackedPanel.prototype.onChildRemoved = function (msg) {\n        msg.child.removeClass('lm-StackedPanel-child');\n        /* <DEPRECATED> */\n        msg.child.removeClass('p-StackedPanel-child');\n        /* </DEPRECATED> */\n        this._widgetRemoved.emit(msg.child);\n    };\n    return StackedPanel;\n}(Panel));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$g;\n(function (Private) {\n    /**\n     * Create a stacked layout for the given panel options.\n     */\n    function createLayout(options) {\n        return options.layout || new StackedLayout();\n    }\n    Private.createLayout = createLayout;\n})(Private$g || (Private$g = {}));\n\n/**\n * A widget which combines a `TabBar` and a `StackedPanel`.\n *\n * #### Notes\n * This is a simple panel which handles the common case of a tab bar\n * placed next to a content area. The selected tab controls the widget\n * which is shown in the content area.\n *\n * For use cases which require more control than is provided by this\n * panel, the `TabBar` widget may be used independently.\n */\nvar TabPanel = /** @class */ (function (_super) {\n    __extends(TabPanel, _super);\n    /**\n     * Construct a new tab panel.\n     *\n     * @param options - The options for initializing the tab panel.\n     */\n    function TabPanel(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this) || this;\n        _this._currentChanged = new Signal(_this);\n        _this.addClass('lm-TabPanel');\n        /* <DEPRECATED> */\n        _this.addClass('p-TabPanel');\n        /* </DEPRECATED> */\n        // Create the tab bar and stacked panel.\n        _this.tabBar = new TabBar(options);\n        _this.tabBar.addClass('lm-TabPanel-tabBar');\n        _this.stackedPanel = new StackedPanel();\n        _this.stackedPanel.addClass('lm-TabPanel-stackedPanel');\n        /* <DEPRECATED> */\n        _this.tabBar.addClass('p-TabPanel-tabBar');\n        _this.stackedPanel.addClass('p-TabPanel-stackedPanel');\n        /* </DEPRECATED> */\n        // Connect the tab bar signal handlers.\n        _this.tabBar.tabMoved.connect(_this._onTabMoved, _this);\n        _this.tabBar.currentChanged.connect(_this._onCurrentChanged, _this);\n        _this.tabBar.tabCloseRequested.connect(_this._onTabCloseRequested, _this);\n        _this.tabBar.tabActivateRequested.connect(_this._onTabActivateRequested, _this);\n        // Connect the stacked panel signal handlers.\n        _this.stackedPanel.widgetRemoved.connect(_this._onWidgetRemoved, _this);\n        // Get the data related to the placement.\n        _this._tabPlacement = options.tabPlacement || 'top';\n        var direction = Private$h.directionFromPlacement(_this._tabPlacement);\n        var orientation = Private$h.orientationFromPlacement(_this._tabPlacement);\n        // Configure the tab bar for the placement.\n        _this.tabBar.orientation = orientation;\n        _this.tabBar.dataset['placement'] = _this._tabPlacement;\n        // Create the box layout.\n        var layout = new BoxLayout({ direction: direction, spacing: 0 });\n        // Set the stretch factors for the child widgets.\n        BoxLayout.setStretch(_this.tabBar, 0);\n        BoxLayout.setStretch(_this.stackedPanel, 1);\n        // Add the child widgets to the layout.\n        layout.addWidget(_this.tabBar);\n        layout.addWidget(_this.stackedPanel);\n        // Install the layout on the tab panel.\n        _this.layout = layout;\n        return _this;\n    }\n    Object.defineProperty(TabPanel.prototype, \"currentChanged\", {\n        /**\n         * A signal emitted when the current tab is changed.\n         *\n         * #### Notes\n         * This signal is emitted when the currently selected tab is changed\n         * either through user or programmatic interaction.\n         *\n         * Notably, this signal is not emitted when the index of the current\n         * tab changes due to tabs being inserted, removed, or moved. It is\n         * only emitted when the actual current tab node is changed.\n         */\n        get: function () {\n            return this._currentChanged;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabPanel.prototype, \"currentIndex\", {\n        /**\n         * Get the index of the currently selected tab.\n         *\n         * #### Notes\n         * This will be `-1` if no tab is selected.\n         */\n        get: function () {\n            return this.tabBar.currentIndex;\n        },\n        /**\n         * Set the index of the currently selected tab.\n         *\n         * #### Notes\n         * If the index is out of range, it will be set to `-1`.\n         */\n        set: function (value) {\n            this.tabBar.currentIndex = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabPanel.prototype, \"currentWidget\", {\n        /**\n         * Get the currently selected widget.\n         *\n         * #### Notes\n         * This will be `null` if there is no selected tab.\n         */\n        get: function () {\n            var title = this.tabBar.currentTitle;\n            return title ? title.owner : null;\n        },\n        /**\n         * Set the currently selected widget.\n         *\n         * #### Notes\n         * If the widget is not in the panel, it will be set to `null`.\n         */\n        set: function (value) {\n            this.tabBar.currentTitle = value ? value.title : null;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabPanel.prototype, \"tabsMovable\", {\n        /**\n         * Get the whether the tabs are movable by the user.\n         *\n         * #### Notes\n         * Tabs can always be moved programmatically.\n         */\n        get: function () {\n            return this.tabBar.tabsMovable;\n        },\n        /**\n         * Set the whether the tabs are movable by the user.\n         *\n         * #### Notes\n         * Tabs can always be moved programmatically.\n         */\n        set: function (value) {\n            this.tabBar.tabsMovable = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabPanel.prototype, \"tabPlacement\", {\n        /**\n         * Get the tab placement for the tab panel.\n         *\n         * #### Notes\n         * This controls the position of the tab bar relative to the content.\n         */\n        get: function () {\n            return this._tabPlacement;\n        },\n        /**\n         * Set the tab placement for the tab panel.\n         *\n         * #### Notes\n         * This controls the position of the tab bar relative to the content.\n         */\n        set: function (value) {\n            // Bail if the placement does not change.\n            if (this._tabPlacement === value) {\n                return;\n            }\n            // Update the internal value.\n            this._tabPlacement = value;\n            // Get the values related to the placement.\n            var direction = Private$h.directionFromPlacement(value);\n            var orientation = Private$h.orientationFromPlacement(value);\n            // Configure the tab bar for the placement.\n            this.tabBar.orientation = orientation;\n            this.tabBar.dataset['placement'] = value;\n            // Update the layout direction.\n            this.layout.direction = direction;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabPanel.prototype, \"widgets\", {\n        /**\n         * A read-only array of the widgets in the panel.\n         */\n        get: function () {\n            return this.stackedPanel.widgets;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Add a widget to the end of the tab panel.\n     *\n     * @param widget - The widget to add to the tab panel.\n     *\n     * #### Notes\n     * If the widget is already contained in the panel, it will be moved.\n     *\n     * The widget's `title` is used to populate the tab.\n     */\n    TabPanel.prototype.addWidget = function (widget) {\n        this.insertWidget(this.widgets.length, widget);\n    };\n    /**\n     * Insert a widget into the tab panel at a specified index.\n     *\n     * @param index - The index at which to insert the widget.\n     *\n     * @param widget - The widget to insert into to the tab panel.\n     *\n     * #### Notes\n     * If the widget is already contained in the panel, it will be moved.\n     *\n     * The widget's `title` is used to populate the tab.\n     */\n    TabPanel.prototype.insertWidget = function (index, widget) {\n        if (widget !== this.currentWidget) {\n            widget.hide();\n        }\n        this.stackedPanel.insertWidget(index, widget);\n        this.tabBar.insertTab(index, widget.title);\n    };\n    /**\n     * Handle the `currentChanged` signal from the tab bar.\n     */\n    TabPanel.prototype._onCurrentChanged = function (sender, args) {\n        // Extract the previous and current title from the args.\n        var previousIndex = args.previousIndex, previousTitle = args.previousTitle, currentIndex = args.currentIndex, currentTitle = args.currentTitle;\n        // Extract the widgets from the titles.\n        var previousWidget = previousTitle ? previousTitle.owner : null;\n        var currentWidget = currentTitle ? currentTitle.owner : null;\n        // Hide the previous widget.\n        if (previousWidget) {\n            previousWidget.hide();\n        }\n        // Show the current widget.\n        if (currentWidget) {\n            currentWidget.show();\n        }\n        // Emit the `currentChanged` signal for the tab panel.\n        this._currentChanged.emit({\n            previousIndex: previousIndex, previousWidget: previousWidget, currentIndex: currentIndex, currentWidget: currentWidget\n        });\n        // Flush the message loop on IE and Edge to prevent flicker.\n        if (Platform.IS_EDGE || Platform.IS_IE) {\n            MessageLoop.flush();\n        }\n    };\n    /**\n     * Handle the `tabActivateRequested` signal from the tab bar.\n     */\n    TabPanel.prototype._onTabActivateRequested = function (sender, args) {\n        args.title.owner.activate();\n    };\n    /**\n     * Handle the `tabCloseRequested` signal from the tab bar.\n     */\n    TabPanel.prototype._onTabCloseRequested = function (sender, args) {\n        args.title.owner.close();\n    };\n    /**\n     * Handle the `tabMoved` signal from the tab bar.\n     */\n    TabPanel.prototype._onTabMoved = function (sender, args) {\n        this.stackedPanel.insertWidget(args.toIndex, args.title.owner);\n    };\n    /**\n     * Handle the `widgetRemoved` signal from the stacked panel.\n     */\n    TabPanel.prototype._onWidgetRemoved = function (sender, widget) {\n        this.tabBar.removeTab(widget.title);\n    };\n    return TabPanel;\n}(Widget));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$h;\n(function (Private) {\n    /**\n     * Convert a tab placement to tab bar orientation.\n     */\n    function orientationFromPlacement(plc) {\n        return placementToOrientationMap[plc];\n    }\n    Private.orientationFromPlacement = orientationFromPlacement;\n    /**\n     * Convert a tab placement to a box layout direction.\n     */\n    function directionFromPlacement(plc) {\n        return placementToDirectionMap[plc];\n    }\n    Private.directionFromPlacement = directionFromPlacement;\n    /**\n     * A mapping of tab placement to tab bar orientation.\n     */\n    var placementToOrientationMap = {\n        'top': 'horizontal',\n        'left': 'vertical',\n        'right': 'vertical',\n        'bottom': 'horizontal'\n    };\n    /**\n     * A mapping of tab placement to box layout direction.\n     */\n    var placementToDirectionMap = {\n        'top': 'top-to-bottom',\n        'left': 'left-to-right',\n        'right': 'right-to-left',\n        'bottom': 'bottom-to-top'\n    };\n})(Private$h || (Private$h = {}));\n\nexport { BoxEngine, BoxLayout, BoxPanel, BoxSizer, CommandPalette, ContextMenu, DockLayout, DockPanel, FocusTracker, GridLayout, Layout, LayoutItem, Menu, MenuBar, Panel, PanelLayout, ScrollBar, SingletonLayout, SplitLayout, SplitPanel, StackedLayout, StackedPanel, TabBar, TabPanel, Title, Widget };\n//# sourceMappingURL=index.es6.js.map\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * The namespace for JSON-specific functions.\n */\nvar JSONExt;\n(function (JSONExt) {\n    /**\n     * A shared frozen empty JSONObject\n     */\n    JSONExt.emptyObject = Object.freeze({});\n    /**\n     * A shared frozen empty JSONArray\n     */\n    JSONExt.emptyArray = Object.freeze([]);\n    /**\n     * Test whether a JSON value is a primitive.\n     *\n     * @param value - The JSON value of interest.\n     *\n     * @returns `true` if the value is a primitive,`false` otherwise.\n     */\n    function isPrimitive(value) {\n        return (value === null ||\n            typeof value === 'boolean' ||\n            typeof value === 'number' ||\n            typeof value === 'string');\n    }\n    JSONExt.isPrimitive = isPrimitive;\n    function isArray(value) {\n        return Array.isArray(value);\n    }\n    JSONExt.isArray = isArray;\n    function isObject(value) {\n        return !isPrimitive(value) && !isArray(value);\n    }\n    JSONExt.isObject = isObject;\n    /**\n     * Compare two JSON values for deep equality.\n     *\n     * @param first - The first JSON value of interest.\n     *\n     * @param second - The second JSON value of interest.\n     *\n     * @returns `true` if the values are equivalent, `false` otherwise.\n     */\n    function deepEqual(first, second) {\n        // Check referential and primitive equality first.\n        if (first === second) {\n            return true;\n        }\n        // If one is a primitive, the `===` check ruled out the other.\n        if (isPrimitive(first) || isPrimitive(second)) {\n            return false;\n        }\n        // Test whether they are arrays.\n        var a1 = isArray(first);\n        var a2 = isArray(second);\n        // Bail if the types are different.\n        if (a1 !== a2) {\n            return false;\n        }\n        // If they are both arrays, compare them.\n        if (a1 && a2) {\n            return deepArrayEqual(first, second);\n        }\n        // At this point, they must both be objects.\n        return deepObjectEqual(first, second);\n    }\n    JSONExt.deepEqual = deepEqual;\n    /**\n     * Create a deep copy of a JSON value.\n     *\n     * @param value - The JSON value to copy.\n     *\n     * @returns A deep copy of the given JSON value.\n     */\n    function deepCopy(value) {\n        // Do nothing for primitive values.\n        if (isPrimitive(value)) {\n            return value;\n        }\n        // Deep copy an array.\n        if (isArray(value)) {\n            return deepArrayCopy(value);\n        }\n        // Deep copy an object.\n        return deepObjectCopy(value);\n    }\n    JSONExt.deepCopy = deepCopy;\n    /**\n     * Compare two JSON arrays for deep equality.\n     */\n    function deepArrayEqual(first, second) {\n        // Check referential equality first.\n        if (first === second) {\n            return true;\n        }\n        // Test the arrays for equal length.\n        if (first.length !== second.length) {\n            return false;\n        }\n        // Compare the values for equality.\n        for (var i = 0, n = first.length; i < n; ++i) {\n            if (!deepEqual(first[i], second[i])) {\n                return false;\n            }\n        }\n        // At this point, the arrays are equal.\n        return true;\n    }\n    /**\n     * Compare two JSON objects for deep equality.\n     */\n    function deepObjectEqual(first, second) {\n        // Check referential equality first.\n        if (first === second) {\n            return true;\n        }\n        // Check for the first object's keys in the second object.\n        for (var key in first) {\n            if (first[key] !== undefined && !(key in second)) {\n                return false;\n            }\n        }\n        // Check for the second object's keys in the first object.\n        for (var key in second) {\n            if (second[key] !== undefined && !(key in first)) {\n                return false;\n            }\n        }\n        // Compare the values for equality.\n        for (var key in first) {\n            // Get the values.\n            var firstValue = first[key];\n            var secondValue = second[key];\n            // If both are undefined, ignore the key.\n            if (firstValue === undefined && secondValue === undefined) {\n                continue;\n            }\n            // If only one value is undefined, the objects are not equal.\n            if (firstValue === undefined || secondValue === undefined) {\n                return false;\n            }\n            // Compare the values.\n            if (!deepEqual(firstValue, secondValue)) {\n                return false;\n            }\n        }\n        // At this point, the objects are equal.\n        return true;\n    }\n    /**\n     * Create a deep copy of a JSON array.\n     */\n    function deepArrayCopy(value) {\n        var result = new Array(value.length);\n        for (var i = 0, n = value.length; i < n; ++i) {\n            result[i] = deepCopy(value[i]);\n        }\n        return result;\n    }\n    /**\n     * Create a deep copy of a JSON object.\n     */\n    function deepObjectCopy(value) {\n        var result = {};\n        for (var key in value) {\n            // Ignore undefined values.\n            var subvalue = value[key];\n            if (subvalue === undefined) {\n                continue;\n            }\n            result[key] = deepCopy(subvalue);\n        }\n        return result;\n    }\n})(JSONExt || (JSONExt = {}));\n\n// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * An object which stores MIME data for general application use.\n *\n * #### Notes\n * This class does not attempt to enforce \"correctness\" of MIME types\n * and their associated data. Since this class is designed to transfer\n * arbitrary data and objects within the same application, it assumes\n * that the user provides correct and accurate data.\n */\nvar MimeData = /** @class */ (function () {\n    function MimeData() {\n        this._types = [];\n        this._values = [];\n    }\n    /**\n     * Get an array of the MIME types contained within the dataset.\n     *\n     * @returns A new array of the MIME types, in order of insertion.\n     */\n    MimeData.prototype.types = function () {\n        return this._types.slice();\n    };\n    /**\n     * Test whether the dataset has an entry for the given type.\n     *\n     * @param mime - The MIME type of interest.\n     *\n     * @returns `true` if the dataset contains a value for the given\n     *   MIME type, `false` otherwise.\n     */\n    MimeData.prototype.hasData = function (mime) {\n        return this._types.indexOf(mime) !== -1;\n    };\n    /**\n     * Get the data value for the given MIME type.\n     *\n     * @param mime - The MIME type of interest.\n     *\n     * @returns The value for the given MIME type, or `undefined` if\n     *   the dataset does not contain a value for the type.\n     */\n    MimeData.prototype.getData = function (mime) {\n        var i = this._types.indexOf(mime);\n        return i !== -1 ? this._values[i] : undefined;\n    };\n    /**\n     * Set the data value for the given MIME type.\n     *\n     * @param mime - The MIME type of interest.\n     *\n     * @param data - The data value for the given MIME type.\n     *\n     * #### Notes\n     * This will overwrite any previous entry for the MIME type.\n     */\n    MimeData.prototype.setData = function (mime, data) {\n        this.clearData(mime);\n        this._types.push(mime);\n        this._values.push(data);\n    };\n    /**\n     * Remove the data entry for the given MIME type.\n     *\n     * @param mime - The MIME type of interest.\n     *\n     * #### Notes\n     * This is a no-op if there is no entry for the given MIME type.\n     */\n    MimeData.prototype.clearData = function (mime) {\n        var i = this._types.indexOf(mime);\n        if (i !== -1) {\n            this._types.splice(i, 1);\n            this._values.splice(i, 1);\n        }\n    };\n    /**\n     * Remove all data entries from the dataset.\n     */\n    MimeData.prototype.clear = function () {\n        this._types.length = 0;\n        this._values.length = 0;\n    };\n    return MimeData;\n}());\n\n// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * A class which wraps a promise into a delegate object.\n *\n * #### Notes\n * This class is useful when the logic to resolve or reject a promise\n * cannot be defined at the point where the promise is created.\n */\nvar PromiseDelegate = /** @class */ (function () {\n    /**\n     * Construct a new promise delegate.\n     */\n    function PromiseDelegate() {\n        var _this = this;\n        this.promise = new Promise(function (resolve, reject) {\n            _this._resolve = resolve;\n            _this._reject = reject;\n        });\n    }\n    /**\n     * Resolve the wrapped promise with the given value.\n     *\n     * @param value - The value to use for resolving the promise.\n     */\n    PromiseDelegate.prototype.resolve = function (value) {\n        var resolve = this._resolve;\n        resolve(value);\n    };\n    /**\n     * Reject the wrapped promise with the given value.\n     *\n     * @reason - The reason for rejecting the promise.\n     */\n    PromiseDelegate.prototype.reject = function (reason) {\n        var reject = this._reject;\n        reject(reason);\n    };\n    return PromiseDelegate;\n}());\n\n// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * The namespace for random number related functionality.\n */\nvar Random;\n(function (Random) {\n    /**\n     * A function which generates random bytes.\n     *\n     * @param buffer - The `Uint8Array` to fill with random bytes.\n     *\n     * #### Notes\n     * A cryptographically strong random number generator will be used if\n     * available. Otherwise, `Math.random` will be used as a fallback for\n     * randomness.\n     *\n     * The following RNGs are supported, listed in order of precedence:\n     *   - `window.crypto.getRandomValues`\n     *   - `window.msCrypto.getRandomValues`\n     *   - `require('crypto').randomFillSync\n     *   - `require('crypto').randomBytes\n     *   - `Math.random`\n     */\n    Random.getRandomValues = (function () {\n        // Look up the crypto module if available.\n        var crypto = ((typeof window !== 'undefined' && (window.crypto || window.msCrypto)) ||\n            (typeof require !== 'undefined' && require('crypto')) || null);\n        // Modern browsers and IE 11\n        if (crypto && typeof crypto.getRandomValues === 'function') {\n            return function getRandomValues(buffer) {\n                return crypto.getRandomValues(buffer);\n            };\n        }\n        // Node 7+\n        if (crypto && typeof crypto.randomFillSync === 'function') {\n            return function getRandomValues(buffer) {\n                return crypto.randomFillSync(buffer);\n            };\n        }\n        // Node 0.10+\n        if (crypto && typeof crypto.randomBytes === 'function') {\n            return function getRandomValues(buffer) {\n                var bytes = crypto.randomBytes(buffer.length);\n                for (var i = 0, n = bytes.length; i < n; ++i) {\n                    buffer[i] = bytes[i];\n                }\n            };\n        }\n        // Fallback\n        return function getRandomValues(buffer) {\n            var value = 0;\n            for (var i = 0, n = buffer.length; i < n; ++i) {\n                if (i % 4 === 0) {\n                    value = Math.random() * 0xFFFFFFFF >>> 0;\n                }\n                buffer[i] = value & 0xFF;\n                value >>>= 8;\n            }\n        };\n    })();\n})(Random || (Random = {}));\n\n// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/*-----------------------------------------------------------------------------\n| Copyright (c) 2014-2017, PhosphorJS Contributors\n|\n| Distributed under the terms of the BSD 3-Clause License.\n|\n| The full license is in the file LICENSE, distributed with this software.\n|----------------------------------------------------------------------------*/\n/**\n * A runtime object which captures compile-time type information.\n *\n * #### Notes\n * A token captures the compile-time type of an interface or class in\n * an object which can be used at runtime in a type-safe fashion.\n */\nvar Token = /** @class */ (function () {\n    /**\n     * Construct a new token.\n     *\n     * @param name - A human readable name for the token.\n     */\n    function Token(name) {\n        this.name = name;\n        this._tokenStructuralPropertyT = null;\n    }\n    return Token;\n}());\n\n// Copyright (c) Jupyter Development Team.\n/**\n * The namespace for UUID related functionality.\n */\nvar UUID;\n(function (UUID) {\n    /**\n     * A function which generates UUID v4 identifiers.\n     *\n     * @returns A new UUID v4 string.\n     *\n     * #### Notes\n     * This implementation complies with RFC 4122.\n     *\n     * This uses `Random.getRandomValues()` for random bytes, which in\n     * turn will use the underlying `crypto` module of the platform if\n     * it is available. The fallback for randomness is `Math.random`.\n     */\n    UUID.uuid4 = (function () {\n        // Create a 16 byte array to hold the random values.\n        var bytes = new Uint8Array(16);\n        // Create a look up table from bytes to hex strings.\n        var lut = new Array(256);\n        // Pad the single character hex digits with a leading zero.\n        for (var i = 0; i < 16; ++i) {\n            lut[i] = '0' + i.toString(16);\n        }\n        // Populate the rest of the hex digits.\n        for (var i = 16; i < 256; ++i) {\n            lut[i] = i.toString(16);\n        }\n        // Return a function which generates the UUID.\n        return function uuid4() {\n            // Get a new batch of random values.\n            Random.getRandomValues(bytes);\n            // Set the UUID version number to 4.\n            bytes[6] = 0x40 | (bytes[6] & 0x0F);\n            // Set the clock sequence bit to the RFC spec.\n            bytes[8] = 0x80 | (bytes[8] & 0x3F);\n            // Assemble the UUID string.\n            return (lut[bytes[0]] +\n                lut[bytes[1]] +\n                lut[bytes[2]] +\n                lut[bytes[3]] +\n                '-' +\n                lut[bytes[4]] +\n                lut[bytes[5]] +\n                '-' +\n                lut[bytes[6]] +\n                lut[bytes[7]] +\n                '-' +\n                lut[bytes[8]] +\n                lut[bytes[9]] +\n                '-' +\n                lut[bytes[10]] +\n                lut[bytes[11]] +\n                lut[bytes[12]] +\n                lut[bytes[13]] +\n                lut[bytes[14]] +\n                lut[bytes[15]]);\n        };\n    })();\n})(UUID || (UUID = {}));\n\nexport { JSONExt, MimeData, PromiseDelegate, Random, Token, UUID };\n//# sourceMappingURL=index.es6.js.map\n","/*!\n * jQuery JavaScript Library v3.4.1\n * https://jquery.com/\n *\n * Includes Sizzle.js\n * https://sizzlejs.com/\n *\n * Copyright JS Foundation and other contributors\n * Released under the MIT license\n * https://jquery.org/license\n *\n * Date: 2019-05-01T21:04Z\n */\n( function( global, factory ) {\n\n\t\"use strict\";\n\n\tif ( typeof module === \"object\" && typeof module.exports === \"object\" ) {\n\n\t\t// For CommonJS and CommonJS-like environments where a proper `window`\n\t\t// is present, execute the factory and get jQuery.\n\t\t// For environments that do not have a `window` with a `document`\n\t\t// (such as Node.js), expose a factory as module.exports.\n\t\t// This accentuates the need for the creation of a real `window`.\n\t\t// e.g. var jQuery = require(\"jquery\")(window);\n\t\t// See ticket #14549 for more info.\n\t\tmodule.exports = global.document ?\n\t\t\tfactory( global, true ) :\n\t\t\tfunction( w ) {\n\t\t\t\tif ( !w.document ) {\n\t\t\t\t\tthrow new Error( \"jQuery requires a window with a document\" );\n\t\t\t\t}\n\t\t\t\treturn factory( w );\n\t\t\t};\n\t} else {\n\t\tfactory( global );\n\t}\n\n// Pass this if window is not defined yet\n} )( typeof window !== \"undefined\" ? window : this, function( window, noGlobal ) {\n\n// Edge <= 12 - 13+, Firefox <=18 - 45+, IE 10 - 11, Safari 5.1 - 9+, iOS 6 - 9.1\n// throw exceptions when non-strict code (e.g., ASP.NET 4.5) accesses strict mode\n// arguments.callee.caller (trac-13335). But as of jQuery 3.0 (2016), strict mode should be common\n// enough that all such attempts are guarded in a try block.\n\"use strict\";\n\nvar arr = [];\n\nvar document = window.document;\n\nvar getProto = Object.getPrototypeOf;\n\nvar slice = arr.slice;\n\nvar concat = arr.concat;\n\nvar push = arr.push;\n\nvar indexOf = arr.indexOf;\n\nvar class2type = {};\n\nvar toString = class2type.toString;\n\nvar hasOwn = class2type.hasOwnProperty;\n\nvar fnToString = hasOwn.toString;\n\nvar ObjectFunctionString = fnToString.call( Object );\n\nvar support = {};\n\nvar isFunction = function isFunction( obj ) {\n\n      // Support: Chrome <=57, Firefox <=52\n      // In some browsers, typeof returns \"function\" for HTML <object> elements\n      // (i.e., `typeof document.createElement( \"object\" ) === \"function\"`).\n      // We don't want to classify *any* DOM node as a function.\n      return typeof obj === \"function\" && typeof obj.nodeType !== \"number\";\n  };\n\n\nvar isWindow = function isWindow( obj ) {\n\t\treturn obj != null && obj === obj.window;\n\t};\n\n\n\n\n\tvar preservedScriptAttributes = {\n\t\ttype: true,\n\t\tsrc: true,\n\t\tnonce: true,\n\t\tnoModule: true\n\t};\n\n\tfunction DOMEval( code, node, doc ) {\n\t\tdoc = doc || document;\n\n\t\tvar i, val,\n\t\t\tscript = doc.createElement( \"script\" );\n\n\t\tscript.text = code;\n\t\tif ( node ) {\n\t\t\tfor ( i in preservedScriptAttributes ) {\n\n\t\t\t\t// Support: Firefox 64+, Edge 18+\n\t\t\t\t// Some browsers don't support the \"nonce\" property on scripts.\n\t\t\t\t// On the other hand, just using `getAttribute` is not enough as\n\t\t\t\t// the `nonce` attribute is reset to an empty string whenever it\n\t\t\t\t// becomes browsing-context connected.\n\t\t\t\t// See https://github.com/whatwg/html/issues/2369\n\t\t\t\t// See https://html.spec.whatwg.org/#nonce-attributes\n\t\t\t\t// The `node.getAttribute` check was added for the sake of\n\t\t\t\t// `jQuery.globalEval` so that it can fake a nonce-containing node\n\t\t\t\t// via an object.\n\t\t\t\tval = node[ i ] || node.getAttribute && node.getAttribute( i );\n\t\t\t\tif ( val ) {\n\t\t\t\t\tscript.setAttribute( i, val );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tdoc.head.appendChild( script ).parentNode.removeChild( script );\n\t}\n\n\nfunction toType( obj ) {\n\tif ( obj == null ) {\n\t\treturn obj + \"\";\n\t}\n\n\t// Support: Android <=2.3 only (functionish RegExp)\n\treturn typeof obj === \"object\" || typeof obj === \"function\" ?\n\t\tclass2type[ toString.call( obj ) ] || \"object\" :\n\t\ttypeof obj;\n}\n/* global Symbol */\n// Defining this global in .eslintrc.json would create a danger of using the global\n// unguarded in another place, it seems safer to define global only for this module\n\n\n\nvar\n\tversion = \"3.4.1\",\n\n\t// Define a local copy of jQuery\n\tjQuery = function( selector, context ) {\n\n\t\t// The jQuery object is actually just the init constructor 'enhanced'\n\t\t// Need init if jQuery is called (just allow error to be thrown if not included)\n\t\treturn new jQuery.fn.init( selector, context );\n\t},\n\n\t// Support: Android <=4.0 only\n\t// Make sure we trim BOM and NBSP\n\trtrim = /^[\\s\\uFEFF\\xA0]+|[\\s\\uFEFF\\xA0]+$/g;\n\njQuery.fn = jQuery.prototype = {\n\n\t// The current version of jQuery being used\n\tjquery: version,\n\n\tconstructor: jQuery,\n\n\t// The default length of a jQuery object is 0\n\tlength: 0,\n\n\ttoArray: function() {\n\t\treturn slice.call( this );\n\t},\n\n\t// Get the Nth element in the matched element set OR\n\t// Get the whole matched element set as a clean array\n\tget: function( num ) {\n\n\t\t// Return all the elements in a clean array\n\t\tif ( num == null ) {\n\t\t\treturn slice.call( this );\n\t\t}\n\n\t\t// Return just the one element from the set\n\t\treturn num < 0 ? this[ num + this.length ] : this[ num ];\n\t},\n\n\t// Take an array of elements and push it onto the stack\n\t// (returning the new matched element set)\n\tpushStack: function( elems ) {\n\n\t\t// Build a new jQuery matched element set\n\t\tvar ret = jQuery.merge( this.constructor(), elems );\n\n\t\t// Add the old object onto the stack (as a reference)\n\t\tret.prevObject = this;\n\n\t\t// Return the newly-formed element set\n\t\treturn ret;\n\t},\n\n\t// Execute a callback for every element in the matched set.\n\teach: function( callback ) {\n\t\treturn jQuery.each( this, callback );\n\t},\n\n\tmap: function( callback ) {\n\t\treturn this.pushStack( jQuery.map( this, function( elem, i ) {\n\t\t\treturn callback.call( elem, i, elem );\n\t\t} ) );\n\t},\n\n\tslice: function() {\n\t\treturn this.pushStack( slice.apply( this, arguments ) );\n\t},\n\n\tfirst: function() {\n\t\treturn this.eq( 0 );\n\t},\n\n\tlast: function() {\n\t\treturn this.eq( -1 );\n\t},\n\n\teq: function( i ) {\n\t\tvar len = this.length,\n\t\t\tj = +i + ( i < 0 ? len : 0 );\n\t\treturn this.pushStack( j >= 0 && j < len ? [ this[ j ] ] : [] );\n\t},\n\n\tend: function() {\n\t\treturn this.prevObject || this.constructor();\n\t},\n\n\t// For internal use only.\n\t// Behaves like an Array's method, not like a jQuery method.\n\tpush: push,\n\tsort: arr.sort,\n\tsplice: arr.splice\n};\n\njQuery.extend = jQuery.fn.extend = function() {\n\tvar options, name, src, copy, copyIsArray, clone,\n\t\ttarget = arguments[ 0 ] || {},\n\t\ti = 1,\n\t\tlength = arguments.length,\n\t\tdeep = false;\n\n\t// Handle a deep copy situation\n\tif ( typeof target === \"boolean\" ) {\n\t\tdeep = target;\n\n\t\t// Skip the boolean and the target\n\t\ttarget = arguments[ i ] || {};\n\t\ti++;\n\t}\n\n\t// Handle case when target is a string or something (possible in deep copy)\n\tif ( typeof target !== \"object\" && !isFunction( target ) ) {\n\t\ttarget = {};\n\t}\n\n\t// Extend jQuery itself if only one argument is passed\n\tif ( i === length ) {\n\t\ttarget = this;\n\t\ti--;\n\t}\n\n\tfor ( ; i < length; i++ ) {\n\n\t\t// Only deal with non-null/undefined values\n\t\tif ( ( options = arguments[ i ] ) != null ) {\n\n\t\t\t// Extend the base object\n\t\t\tfor ( name in options ) {\n\t\t\t\tcopy = options[ name ];\n\n\t\t\t\t// Prevent Object.prototype pollution\n\t\t\t\t// Prevent never-ending loop\n\t\t\t\tif ( name === \"__proto__\" || target === copy ) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\t// Recurse if we're merging plain objects or arrays\n\t\t\t\tif ( deep && copy && ( jQuery.isPlainObject( copy ) ||\n\t\t\t\t\t( copyIsArray = Array.isArray( copy ) ) ) ) {\n\t\t\t\t\tsrc = target[ name ];\n\n\t\t\t\t\t// Ensure proper type for the source value\n\t\t\t\t\tif ( copyIsArray && !Array.isArray( src ) ) {\n\t\t\t\t\t\tclone = [];\n\t\t\t\t\t} else if ( !copyIsArray && !jQuery.isPlainObject( src ) ) {\n\t\t\t\t\t\tclone = {};\n\t\t\t\t\t} else {\n\t\t\t\t\t\tclone = src;\n\t\t\t\t\t}\n\t\t\t\t\tcopyIsArray = false;\n\n\t\t\t\t\t// Never move original objects, clone them\n\t\t\t\t\ttarget[ name ] = jQuery.extend( deep, clone, copy );\n\n\t\t\t\t// Don't bring in undefined values\n\t\t\t\t} else if ( copy !== undefined ) {\n\t\t\t\t\ttarget[ name ] = copy;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t// Return the modified object\n\treturn target;\n};\n\njQuery.extend( {\n\n\t// Unique for each copy of jQuery on the page\n\texpando: \"jQuery\" + ( version + Math.random() ).replace( /\\D/g, \"\" ),\n\n\t// Assume jQuery is ready without the ready module\n\tisReady: true,\n\n\terror: function( msg ) {\n\t\tthrow new Error( msg );\n\t},\n\n\tnoop: function() {},\n\n\tisPlainObject: function( obj ) {\n\t\tvar proto, Ctor;\n\n\t\t// Detect obvious negatives\n\t\t// Use toString instead of jQuery.type to catch host objects\n\t\tif ( !obj || toString.call( obj ) !== \"[object Object]\" ) {\n\t\t\treturn false;\n\t\t}\n\n\t\tproto = getProto( obj );\n\n\t\t// Objects with no prototype (e.g., `Object.create( null )`) are plain\n\t\tif ( !proto ) {\n\t\t\treturn true;\n\t\t}\n\n\t\t// Objects with prototype are plain iff they were constructed by a global Object function\n\t\tCtor = hasOwn.call( proto, \"constructor\" ) && proto.constructor;\n\t\treturn typeof Ctor === \"function\" && fnToString.call( Ctor ) === ObjectFunctionString;\n\t},\n\n\tisEmptyObject: function( obj ) {\n\t\tvar name;\n\n\t\tfor ( name in obj ) {\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t},\n\n\t// Evaluates a script in a global context\n\tglobalEval: function( code, options ) {\n\t\tDOMEval( code, { nonce: options && options.nonce } );\n\t},\n\n\teach: function( obj, callback ) {\n\t\tvar length, i = 0;\n\n\t\tif ( isArrayLike( obj ) ) {\n\t\t\tlength = obj.length;\n\t\t\tfor ( ; i < length; i++ ) {\n\t\t\t\tif ( callback.call( obj[ i ], i, obj[ i ] ) === false ) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\tfor ( i in obj ) {\n\t\t\t\tif ( callback.call( obj[ i ], i, obj[ i ] ) === false ) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn obj;\n\t},\n\n\t// Support: Android <=4.0 only\n\ttrim: function( text ) {\n\t\treturn text == null ?\n\t\t\t\"\" :\n\t\t\t( text + \"\" ).replace( rtrim, \"\" );\n\t},\n\n\t// results is for internal usage only\n\tmakeArray: function( arr, results ) {\n\t\tvar ret = results || [];\n\n\t\tif ( arr != null ) {\n\t\t\tif ( isArrayLike( Object( arr ) ) ) {\n\t\t\t\tjQuery.merge( ret,\n\t\t\t\t\ttypeof arr === \"string\" ?\n\t\t\t\t\t[ arr ] : arr\n\t\t\t\t);\n\t\t\t} else {\n\t\t\t\tpush.call( ret, arr );\n\t\t\t}\n\t\t}\n\n\t\treturn ret;\n\t},\n\n\tinArray: function( elem, arr, i ) {\n\t\treturn arr == null ? -1 : indexOf.call( arr, elem, i );\n\t},\n\n\t// Support: Android <=4.0 only, PhantomJS 1 only\n\t// push.apply(_, arraylike) throws on ancient WebKit\n\tmerge: function( first, second ) {\n\t\tvar len = +second.length,\n\t\t\tj = 0,\n\t\t\ti = first.length;\n\n\t\tfor ( ; j < len; j++ ) {\n\t\t\tfirst[ i++ ] = second[ j ];\n\t\t}\n\n\t\tfirst.length = i;\n\n\t\treturn first;\n\t},\n\n\tgrep: function( elems, callback, invert ) {\n\t\tvar callbackInverse,\n\t\t\tmatches = [],\n\t\t\ti = 0,\n\t\t\tlength = elems.length,\n\t\t\tcallbackExpect = !invert;\n\n\t\t// Go through the array, only saving the items\n\t\t// that pass the validator function\n\t\tfor ( ; i < length; i++ ) {\n\t\t\tcallbackInverse = !callback( elems[ i ], i );\n\t\t\tif ( callbackInverse !== callbackExpect ) {\n\t\t\t\tmatches.push( elems[ i ] );\n\t\t\t}\n\t\t}\n\n\t\treturn matches;\n\t},\n\n\t// arg is for internal usage only\n\tmap: function( elems, callback, arg ) {\n\t\tvar length, value,\n\t\t\ti = 0,\n\t\t\tret = [];\n\n\t\t// Go through the array, translating each of the items to their new values\n\t\tif ( isArrayLike( elems ) ) {\n\t\t\tlength = elems.length;\n\t\t\tfor ( ; i < length; i++ ) {\n\t\t\t\tvalue = callback( elems[ i ], i, arg );\n\n\t\t\t\tif ( value != null ) {\n\t\t\t\t\tret.push( value );\n\t\t\t\t}\n\t\t\t}\n\n\t\t// Go through every key on the object,\n\t\t} else {\n\t\t\tfor ( i in elems ) {\n\t\t\t\tvalue = callback( elems[ i ], i, arg );\n\n\t\t\t\tif ( value != null ) {\n\t\t\t\t\tret.push( value );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Flatten any nested arrays\n\t\treturn concat.apply( [], ret );\n\t},\n\n\t// A global GUID counter for objects\n\tguid: 1,\n\n\t// jQuery.support is not used in Core but other projects attach their\n\t// properties to it so it needs to exist.\n\tsupport: support\n} );\n\nif ( typeof Symbol === \"function\" ) {\n\tjQuery.fn[ Symbol.iterator ] = arr[ Symbol.iterator ];\n}\n\n// Populate the class2type map\njQuery.each( \"Boolean Number String Function Array Date RegExp Object Error Symbol\".split( \" \" ),\nfunction( i, name ) {\n\tclass2type[ \"[object \" + name + \"]\" ] = name.toLowerCase();\n} );\n\nfunction isArrayLike( obj ) {\n\n\t// Support: real iOS 8.2 only (not reproducible in simulator)\n\t// `in` check used to prevent JIT error (gh-2145)\n\t// hasOwn isn't used here due to false negatives\n\t// regarding Nodelist length in IE\n\tvar length = !!obj && \"length\" in obj && obj.length,\n\t\ttype = toType( obj );\n\n\tif ( isFunction( obj ) || isWindow( obj ) ) {\n\t\treturn false;\n\t}\n\n\treturn type === \"array\" || length === 0 ||\n\t\ttypeof length === \"number\" && length > 0 && ( length - 1 ) in obj;\n}\nvar Sizzle =\n/*!\n * Sizzle CSS Selector Engine v2.3.4\n * https://sizzlejs.com/\n *\n * Copyright JS Foundation and other contributors\n * Released under the MIT license\n * https://js.foundation/\n *\n * Date: 2019-04-08\n */\n(function( window ) {\n\nvar i,\n\tsupport,\n\tExpr,\n\tgetText,\n\tisXML,\n\ttokenize,\n\tcompile,\n\tselect,\n\toutermostContext,\n\tsortInput,\n\thasDuplicate,\n\n\t// Local document vars\n\tsetDocument,\n\tdocument,\n\tdocElem,\n\tdocumentIsHTML,\n\trbuggyQSA,\n\trbuggyMatches,\n\tmatches,\n\tcontains,\n\n\t// Instance-specific data\n\texpando = \"sizzle\" + 1 * new Date(),\n\tpreferredDoc = window.document,\n\tdirruns = 0,\n\tdone = 0,\n\tclassCache = createCache(),\n\ttokenCache = createCache(),\n\tcompilerCache = createCache(),\n\tnonnativeSelectorCache = createCache(),\n\tsortOrder = function( a, b ) {\n\t\tif ( a === b ) {\n\t\t\thasDuplicate = true;\n\t\t}\n\t\treturn 0;\n\t},\n\n\t// Instance methods\n\thasOwn = ({}).hasOwnProperty,\n\tarr = [],\n\tpop = arr.pop,\n\tpush_native = arr.push,\n\tpush = arr.push,\n\tslice = arr.slice,\n\t// Use a stripped-down indexOf as it's faster than native\n\t// https://jsperf.com/thor-indexof-vs-for/5\n\tindexOf = function( list, elem ) {\n\t\tvar i = 0,\n\t\t\tlen = list.length;\n\t\tfor ( ; i < len; i++ ) {\n\t\t\tif ( list[i] === elem ) {\n\t\t\t\treturn i;\n\t\t\t}\n\t\t}\n\t\treturn -1;\n\t},\n\n\tbooleans = \"checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped\",\n\n\t// Regular expressions\n\n\t// http://www.w3.org/TR/css3-selectors/#whitespace\n\twhitespace = \"[\\\\x20\\\\t\\\\r\\\\n\\\\f]\",\n\n\t// http://www.w3.org/TR/CSS21/syndata.html#value-def-identifier\n\tidentifier = \"(?:\\\\\\\\.|[\\\\w-]|[^\\0-\\\\xa0])+\",\n\n\t// Attribute selectors: http://www.w3.org/TR/selectors/#attribute-selectors\n\tattributes = \"\\\\[\" + whitespace + \"*(\" + identifier + \")(?:\" + whitespace +\n\t\t// Operator (capture 2)\n\t\t\"*([*^$|!~]?=)\" + whitespace +\n\t\t// \"Attribute values must be CSS identifiers [capture 5] or strings [capture 3 or capture 4]\"\n\t\t\"*(?:'((?:\\\\\\\\.|[^\\\\\\\\'])*)'|\\\"((?:\\\\\\\\.|[^\\\\\\\\\\\"])*)\\\"|(\" + identifier + \"))|)\" + whitespace +\n\t\t\"*\\\\]\",\n\n\tpseudos = \":(\" + identifier + \")(?:\\\\((\" +\n\t\t// To reduce the number of selectors needing tokenize in the preFilter, prefer arguments:\n\t\t// 1. quoted (capture 3; capture 4 or capture 5)\n\t\t\"('((?:\\\\\\\\.|[^\\\\\\\\'])*)'|\\\"((?:\\\\\\\\.|[^\\\\\\\\\\\"])*)\\\")|\" +\n\t\t// 2. simple (capture 6)\n\t\t\"((?:\\\\\\\\.|[^\\\\\\\\()[\\\\]]|\" + attributes + \")*)|\" +\n\t\t// 3. anything else (capture 2)\n\t\t\".*\" +\n\t\t\")\\\\)|)\",\n\n\t// Leading and non-escaped trailing whitespace, capturing some non-whitespace characters preceding the latter\n\trwhitespace = new RegExp( whitespace + \"+\", \"g\" ),\n\trtrim = new RegExp( \"^\" + whitespace + \"+|((?:^|[^\\\\\\\\])(?:\\\\\\\\.)*)\" + whitespace + \"+$\", \"g\" ),\n\n\trcomma = new RegExp( \"^\" + whitespace + \"*,\" + whitespace + \"*\" ),\n\trcombinators = new RegExp( \"^\" + whitespace + \"*([>+~]|\" + whitespace + \")\" + whitespace + \"*\" ),\n\trdescend = new RegExp( whitespace + \"|>\" ),\n\n\trpseudo = new RegExp( pseudos ),\n\tridentifier = new RegExp( \"^\" + identifier + \"$\" ),\n\n\tmatchExpr = {\n\t\t\"ID\": new RegExp( \"^#(\" + identifier + \")\" ),\n\t\t\"CLASS\": new RegExp( \"^\\\\.(\" + identifier + \")\" ),\n\t\t\"TAG\": new RegExp( \"^(\" + identifier + \"|[*])\" ),\n\t\t\"ATTR\": new RegExp( \"^\" + attributes ),\n\t\t\"PSEUDO\": new RegExp( \"^\" + pseudos ),\n\t\t\"CHILD\": new RegExp( \"^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\\\(\" + whitespace +\n\t\t\t\"*(even|odd|(([+-]|)(\\\\d*)n|)\" + whitespace + \"*(?:([+-]|)\" + whitespace +\n\t\t\t\"*(\\\\d+)|))\" + whitespace + \"*\\\\)|)\", \"i\" ),\n\t\t\"bool\": new RegExp( \"^(?:\" + booleans + \")$\", \"i\" ),\n\t\t// For use in libraries implementing .is()\n\t\t// We use this for POS matching in `select`\n\t\t\"needsContext\": new RegExp( \"^\" + whitespace + \"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\\\(\" +\n\t\t\twhitespace + \"*((?:-\\\\d)?\\\\d*)\" + whitespace + \"*\\\\)|)(?=[^-]|$)\", \"i\" )\n\t},\n\n\trhtml = /HTML$/i,\n\trinputs = /^(?:input|select|textarea|button)$/i,\n\trheader = /^h\\d$/i,\n\n\trnative = /^[^{]+\\{\\s*\\[native \\w/,\n\n\t// Easily-parseable/retrievable ID or TAG or CLASS selectors\n\trquickExpr = /^(?:#([\\w-]+)|(\\w+)|\\.([\\w-]+))$/,\n\n\trsibling = /[+~]/,\n\n\t// CSS escapes\n\t// http://www.w3.org/TR/CSS21/syndata.html#escaped-characters\n\trunescape = new RegExp( \"\\\\\\\\([\\\\da-f]{1,6}\" + whitespace + \"?|(\" + whitespace + \")|.)\", \"ig\" ),\n\tfunescape = function( _, escaped, escapedWhitespace ) {\n\t\tvar high = \"0x\" + escaped - 0x10000;\n\t\t// NaN means non-codepoint\n\t\t// Support: Firefox<24\n\t\t// Workaround erroneous numeric interpretation of +\"0x\"\n\t\treturn high !== high || escapedWhitespace ?\n\t\t\tescaped :\n\t\t\thigh < 0 ?\n\t\t\t\t// BMP codepoint\n\t\t\t\tString.fromCharCode( high + 0x10000 ) :\n\t\t\t\t// Supplemental Plane codepoint (surrogate pair)\n\t\t\t\tString.fromCharCode( high >> 10 | 0xD800, high & 0x3FF | 0xDC00 );\n\t},\n\n\t// CSS string/identifier serialization\n\t// https://drafts.csswg.org/cssom/#common-serializing-idioms\n\trcssescape = /([\\0-\\x1f\\x7f]|^-?\\d)|^-$|[^\\0-\\x1f\\x7f-\\uFFFF\\w-]/g,\n\tfcssescape = function( ch, asCodePoint ) {\n\t\tif ( asCodePoint ) {\n\n\t\t\t// U+0000 NULL becomes U+FFFD REPLACEMENT CHARACTER\n\t\t\tif ( ch === \"\\0\" ) {\n\t\t\t\treturn \"\\uFFFD\";\n\t\t\t}\n\n\t\t\t// Control characters and (dependent upon position) numbers get escaped as code points\n\t\t\treturn ch.slice( 0, -1 ) + \"\\\\\" + ch.charCodeAt( ch.length - 1 ).toString( 16 ) + \" \";\n\t\t}\n\n\t\t// Other potentially-special ASCII characters get backslash-escaped\n\t\treturn \"\\\\\" + ch;\n\t},\n\n\t// Used for iframes\n\t// See setDocument()\n\t// Removing the function wrapper causes a \"Permission Denied\"\n\t// error in IE\n\tunloadHandler = function() {\n\t\tsetDocument();\n\t},\n\n\tinDisabledFieldset = addCombinator(\n\t\tfunction( elem ) {\n\t\t\treturn elem.disabled === true && elem.nodeName.toLowerCase() === \"fieldset\";\n\t\t},\n\t\t{ dir: \"parentNode\", next: \"legend\" }\n\t);\n\n// Optimize for push.apply( _, NodeList )\ntry {\n\tpush.apply(\n\t\t(arr = slice.call( preferredDoc.childNodes )),\n\t\tpreferredDoc.childNodes\n\t);\n\t// Support: Android<4.0\n\t// Detect silently failing push.apply\n\tarr[ preferredDoc.childNodes.length ].nodeType;\n} catch ( e ) {\n\tpush = { apply: arr.length ?\n\n\t\t// Leverage slice if possible\n\t\tfunction( target, els ) {\n\t\t\tpush_native.apply( target, slice.call(els) );\n\t\t} :\n\n\t\t// Support: IE<9\n\t\t// Otherwise append directly\n\t\tfunction( target, els ) {\n\t\t\tvar j = target.length,\n\t\t\t\ti = 0;\n\t\t\t// Can't trust NodeList.length\n\t\t\twhile ( (target[j++] = els[i++]) ) {}\n\t\t\ttarget.length = j - 1;\n\t\t}\n\t};\n}\n\nfunction Sizzle( selector, context, results, seed ) {\n\tvar m, i, elem, nid, match, groups, newSelector,\n\t\tnewContext = context && context.ownerDocument,\n\n\t\t// nodeType defaults to 9, since context defaults to document\n\t\tnodeType = context ? context.nodeType : 9;\n\n\tresults = results || [];\n\n\t// Return early from calls with invalid selector or context\n\tif ( typeof selector !== \"string\" || !selector ||\n\t\tnodeType !== 1 && nodeType !== 9 && nodeType !== 11 ) {\n\n\t\treturn results;\n\t}\n\n\t// Try to shortcut find operations (as opposed to filters) in HTML documents\n\tif ( !seed ) {\n\n\t\tif ( ( context ? context.ownerDocument || context : preferredDoc ) !== document ) {\n\t\t\tsetDocument( context );\n\t\t}\n\t\tcontext = context || document;\n\n\t\tif ( documentIsHTML ) {\n\n\t\t\t// If the selector is sufficiently simple, try using a \"get*By*\" DOM method\n\t\t\t// (excepting DocumentFragment context, where the methods don't exist)\n\t\t\tif ( nodeType !== 11 && (match = rquickExpr.exec( selector )) ) {\n\n\t\t\t\t// ID selector\n\t\t\t\tif ( (m = match[1]) ) {\n\n\t\t\t\t\t// Document context\n\t\t\t\t\tif ( nodeType === 9 ) {\n\t\t\t\t\t\tif ( (elem = context.getElementById( m )) ) {\n\n\t\t\t\t\t\t\t// Support: IE, Opera, Webkit\n\t\t\t\t\t\t\t// TODO: identify versions\n\t\t\t\t\t\t\t// getElementById can match elements by name instead of ID\n\t\t\t\t\t\t\tif ( elem.id === m ) {\n\t\t\t\t\t\t\t\tresults.push( elem );\n\t\t\t\t\t\t\t\treturn results;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\treturn results;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t// Element context\n\t\t\t\t\t} else {\n\n\t\t\t\t\t\t// Support: IE, Opera, Webkit\n\t\t\t\t\t\t// TODO: identify versions\n\t\t\t\t\t\t// getElementById can match elements by name instead of ID\n\t\t\t\t\t\tif ( newContext && (elem = newContext.getElementById( m )) &&\n\t\t\t\t\t\t\tcontains( context, elem ) &&\n\t\t\t\t\t\t\telem.id === m ) {\n\n\t\t\t\t\t\t\tresults.push( elem );\n\t\t\t\t\t\t\treturn results;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t// Type selector\n\t\t\t\t} else if ( match[2] ) {\n\t\t\t\t\tpush.apply( results, context.getElementsByTagName( selector ) );\n\t\t\t\t\treturn results;\n\n\t\t\t\t// Class selector\n\t\t\t\t} else if ( (m = match[3]) && support.getElementsByClassName &&\n\t\t\t\t\tcontext.getElementsByClassName ) {\n\n\t\t\t\t\tpush.apply( results, context.getElementsByClassName( m ) );\n\t\t\t\t\treturn results;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Take advantage of querySelectorAll\n\t\t\tif ( support.qsa &&\n\t\t\t\t!nonnativeSelectorCache[ selector + \" \" ] &&\n\t\t\t\t(!rbuggyQSA || !rbuggyQSA.test( selector )) &&\n\n\t\t\t\t// Support: IE 8 only\n\t\t\t\t// Exclude object elements\n\t\t\t\t(nodeType !== 1 || context.nodeName.toLowerCase() !== \"object\") ) {\n\n\t\t\t\tnewSelector = selector;\n\t\t\t\tnewContext = context;\n\n\t\t\t\t// qSA considers elements outside a scoping root when evaluating child or\n\t\t\t\t// descendant combinators, which is not what we want.\n\t\t\t\t// In such cases, we work around the behavior by prefixing every selector in the\n\t\t\t\t// list with an ID selector referencing the scope context.\n\t\t\t\t// Thanks to Andrew Dupont for this technique.\n\t\t\t\tif ( nodeType === 1 && rdescend.test( selector ) ) {\n\n\t\t\t\t\t// Capture the context ID, setting it first if necessary\n\t\t\t\t\tif ( (nid = context.getAttribute( \"id\" )) ) {\n\t\t\t\t\t\tnid = nid.replace( rcssescape, fcssescape );\n\t\t\t\t\t} else {\n\t\t\t\t\t\tcontext.setAttribute( \"id\", (nid = expando) );\n\t\t\t\t\t}\n\n\t\t\t\t\t// Prefix every selector in the list\n\t\t\t\t\tgroups = tokenize( selector );\n\t\t\t\t\ti = groups.length;\n\t\t\t\t\twhile ( i-- ) {\n\t\t\t\t\t\tgroups[i] = \"#\" + nid + \" \" + toSelector( groups[i] );\n\t\t\t\t\t}\n\t\t\t\t\tnewSelector = groups.join( \",\" );\n\n\t\t\t\t\t// Expand context for sibling selectors\n\t\t\t\t\tnewContext = rsibling.test( selector ) && testContext( context.parentNode ) ||\n\t\t\t\t\t\tcontext;\n\t\t\t\t}\n\n\t\t\t\ttry {\n\t\t\t\t\tpush.apply( results,\n\t\t\t\t\t\tnewContext.querySelectorAll( newSelector )\n\t\t\t\t\t);\n\t\t\t\t\treturn results;\n\t\t\t\t} catch ( qsaError ) {\n\t\t\t\t\tnonnativeSelectorCache( selector, true );\n\t\t\t\t} finally {\n\t\t\t\t\tif ( nid === expando ) {\n\t\t\t\t\t\tcontext.removeAttribute( \"id\" );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t// All others\n\treturn select( selector.replace( rtrim, \"$1\" ), context, results, seed );\n}\n\n/**\n * Create key-value caches of limited size\n * @returns {function(string, object)} Returns the Object data after storing it on itself with\n *\tproperty name the (space-suffixed) string and (if the cache is larger than Expr.cacheLength)\n *\tdeleting the oldest entry\n */\nfunction createCache() {\n\tvar keys = [];\n\n\tfunction cache( key, value ) {\n\t\t// Use (key + \" \") to avoid collision with native prototype properties (see Issue #157)\n\t\tif ( keys.push( key + \" \" ) > Expr.cacheLength ) {\n\t\t\t// Only keep the most recent entries\n\t\t\tdelete cache[ keys.shift() ];\n\t\t}\n\t\treturn (cache[ key + \" \" ] = value);\n\t}\n\treturn cache;\n}\n\n/**\n * Mark a function for special use by Sizzle\n * @param {Function} fn The function to mark\n */\nfunction markFunction( fn ) {\n\tfn[ expando ] = true;\n\treturn fn;\n}\n\n/**\n * Support testing using an element\n * @param {Function} fn Passed the created element and returns a boolean result\n */\nfunction assert( fn ) {\n\tvar el = document.createElement(\"fieldset\");\n\n\ttry {\n\t\treturn !!fn( el );\n\t} catch (e) {\n\t\treturn false;\n\t} finally {\n\t\t// Remove from its parent by default\n\t\tif ( el.parentNode ) {\n\t\t\tel.parentNode.removeChild( el );\n\t\t}\n\t\t// release memory in IE\n\t\tel = null;\n\t}\n}\n\n/**\n * Adds the same handler for all of the specified attrs\n * @param {String} attrs Pipe-separated list of attributes\n * @param {Function} handler The method that will be applied\n */\nfunction addHandle( attrs, handler ) {\n\tvar arr = attrs.split(\"|\"),\n\t\ti = arr.length;\n\n\twhile ( i-- ) {\n\t\tExpr.attrHandle[ arr[i] ] = handler;\n\t}\n}\n\n/**\n * Checks document order of two siblings\n * @param {Element} a\n * @param {Element} b\n * @returns {Number} Returns less than 0 if a precedes b, greater than 0 if a follows b\n */\nfunction siblingCheck( a, b ) {\n\tvar cur = b && a,\n\t\tdiff = cur && a.nodeType === 1 && b.nodeType === 1 &&\n\t\t\ta.sourceIndex - b.sourceIndex;\n\n\t// Use IE sourceIndex if available on both nodes\n\tif ( diff ) {\n\t\treturn diff;\n\t}\n\n\t// Check if b follows a\n\tif ( cur ) {\n\t\twhile ( (cur = cur.nextSibling) ) {\n\t\t\tif ( cur === b ) {\n\t\t\t\treturn -1;\n\t\t\t}\n\t\t}\n\t}\n\n\treturn a ? 1 : -1;\n}\n\n/**\n * Returns a function to use in pseudos for input types\n * @param {String} type\n */\nfunction createInputPseudo( type ) {\n\treturn function( elem ) {\n\t\tvar name = elem.nodeName.toLowerCase();\n\t\treturn name === \"input\" && elem.type === type;\n\t};\n}\n\n/**\n * Returns a function to use in pseudos for buttons\n * @param {String} type\n */\nfunction createButtonPseudo( type ) {\n\treturn function( elem ) {\n\t\tvar name = elem.nodeName.toLowerCase();\n\t\treturn (name === \"input\" || name === \"button\") && elem.type === type;\n\t};\n}\n\n/**\n * Returns a function to use in pseudos for :enabled/:disabled\n * @param {Boolean} disabled true for :disabled; false for :enabled\n */\nfunction createDisabledPseudo( disabled ) {\n\n\t// Known :disabled false positives: fieldset[disabled] > legend:nth-of-type(n+2) :can-disable\n\treturn function( elem ) {\n\n\t\t// Only certain elements can match :enabled or :disabled\n\t\t// https://html.spec.whatwg.org/multipage/scripting.html#selector-enabled\n\t\t// https://html.spec.whatwg.org/multipage/scripting.html#selector-disabled\n\t\tif ( \"form\" in elem ) {\n\n\t\t\t// Check for inherited disabledness on relevant non-disabled elements:\n\t\t\t// * listed form-associated elements in a disabled fieldset\n\t\t\t//   https://html.spec.whatwg.org/multipage/forms.html#category-listed\n\t\t\t//   https://html.spec.whatwg.org/multipage/forms.html#concept-fe-disabled\n\t\t\t// * option elements in a disabled optgroup\n\t\t\t//   https://html.spec.whatwg.org/multipage/forms.html#concept-option-disabled\n\t\t\t// All such elements have a \"form\" property.\n\t\t\tif ( elem.parentNode && elem.disabled === false ) {\n\n\t\t\t\t// Option elements defer to a parent optgroup if present\n\t\t\t\tif ( \"label\" in elem ) {\n\t\t\t\t\tif ( \"label\" in elem.parentNode ) {\n\t\t\t\t\t\treturn elem.parentNode.disabled === disabled;\n\t\t\t\t\t} else {\n\t\t\t\t\t\treturn elem.disabled === disabled;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Support: IE 6 - 11\n\t\t\t\t// Use the isDisabled shortcut property to check for disabled fieldset ancestors\n\t\t\t\treturn elem.isDisabled === disabled ||\n\n\t\t\t\t\t// Where there is no isDisabled, check manually\n\t\t\t\t\t/* jshint -W018 */\n\t\t\t\t\telem.isDisabled !== !disabled &&\n\t\t\t\t\t\tinDisabledFieldset( elem ) === disabled;\n\t\t\t}\n\n\t\t\treturn elem.disabled === disabled;\n\n\t\t// Try to winnow out elements that can't be disabled before trusting the disabled property.\n\t\t// Some victims get caught in our net (label, legend, menu, track), but it shouldn't\n\t\t// even exist on them, let alone have a boolean value.\n\t\t} else if ( \"label\" in elem ) {\n\t\t\treturn elem.disabled === disabled;\n\t\t}\n\n\t\t// Remaining elements are neither :enabled nor :disabled\n\t\treturn false;\n\t};\n}\n\n/**\n * Returns a function to use in pseudos for positionals\n * @param {Function} fn\n */\nfunction createPositionalPseudo( fn ) {\n\treturn markFunction(function( argument ) {\n\t\targument = +argument;\n\t\treturn markFunction(function( seed, matches ) {\n\t\t\tvar j,\n\t\t\t\tmatchIndexes = fn( [], seed.length, argument ),\n\t\t\t\ti = matchIndexes.length;\n\n\t\t\t// Match elements found at the specified indexes\n\t\t\twhile ( i-- ) {\n\t\t\t\tif ( seed[ (j = matchIndexes[i]) ] ) {\n\t\t\t\t\tseed[j] = !(matches[j] = seed[j]);\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t});\n}\n\n/**\n * Checks a node for validity as a Sizzle context\n * @param {Element|Object=} context\n * @returns {Element|Object|Boolean} The input node if acceptable, otherwise a falsy value\n */\nfunction testContext( context ) {\n\treturn context && typeof context.getElementsByTagName !== \"undefined\" && context;\n}\n\n// Expose support vars for convenience\nsupport = Sizzle.support = {};\n\n/**\n * Detects XML nodes\n * @param {Element|Object} elem An element or a document\n * @returns {Boolean} True iff elem is a non-HTML XML node\n */\nisXML = Sizzle.isXML = function( elem ) {\n\tvar namespace = elem.namespaceURI,\n\t\tdocElem = (elem.ownerDocument || elem).documentElement;\n\n\t// Support: IE <=8\n\t// Assume HTML when documentElement doesn't yet exist, such as inside loading iframes\n\t// https://bugs.jquery.com/ticket/4833\n\treturn !rhtml.test( namespace || docElem && docElem.nodeName || \"HTML\" );\n};\n\n/**\n * Sets document-related variables once based on the current document\n * @param {Element|Object} [doc] An element or document object to use to set the document\n * @returns {Object} Returns the current document\n */\nsetDocument = Sizzle.setDocument = function( node ) {\n\tvar hasCompare, subWindow,\n\t\tdoc = node ? node.ownerDocument || node : preferredDoc;\n\n\t// Return early if doc is invalid or already selected\n\tif ( doc === document || doc.nodeType !== 9 || !doc.documentElement ) {\n\t\treturn document;\n\t}\n\n\t// Update global variables\n\tdocument = doc;\n\tdocElem = document.documentElement;\n\tdocumentIsHTML = !isXML( document );\n\n\t// Support: IE 9-11, Edge\n\t// Accessing iframe documents after unload throws \"permission denied\" errors (jQuery #13936)\n\tif ( preferredDoc !== document &&\n\t\t(subWindow = document.defaultView) && subWindow.top !== subWindow ) {\n\n\t\t// Support: IE 11, Edge\n\t\tif ( subWindow.addEventListener ) {\n\t\t\tsubWindow.addEventListener( \"unload\", unloadHandler, false );\n\n\t\t// Support: IE 9 - 10 only\n\t\t} else if ( subWindow.attachEvent ) {\n\t\t\tsubWindow.attachEvent( \"onunload\", unloadHandler );\n\t\t}\n\t}\n\n\t/* Attributes\n\t---------------------------------------------------------------------- */\n\n\t// Support: IE<8\n\t// Verify that getAttribute really returns attributes and not properties\n\t// (excepting IE8 booleans)\n\tsupport.attributes = assert(function( el ) {\n\t\tel.className = \"i\";\n\t\treturn !el.getAttribute(\"className\");\n\t});\n\n\t/* getElement(s)By*\n\t---------------------------------------------------------------------- */\n\n\t// Check if getElementsByTagName(\"*\") returns only elements\n\tsupport.getElementsByTagName = assert(function( el ) {\n\t\tel.appendChild( document.createComment(\"\") );\n\t\treturn !el.getElementsByTagName(\"*\").length;\n\t});\n\n\t// Support: IE<9\n\tsupport.getElementsByClassName = rnative.test( document.getElementsByClassName );\n\n\t// Support: IE<10\n\t// Check if getElementById returns elements by name\n\t// The broken getElementById methods don't pick up programmatically-set names,\n\t// so use a roundabout getElementsByName test\n\tsupport.getById = assert(function( el ) {\n\t\tdocElem.appendChild( el ).id = expando;\n\t\treturn !document.getElementsByName || !document.getElementsByName( expando ).length;\n\t});\n\n\t// ID filter and find\n\tif ( support.getById ) {\n\t\tExpr.filter[\"ID\"] = function( id ) {\n\t\t\tvar attrId = id.replace( runescape, funescape );\n\t\t\treturn function( elem ) {\n\t\t\t\treturn elem.getAttribute(\"id\") === attrId;\n\t\t\t};\n\t\t};\n\t\tExpr.find[\"ID\"] = function( id, context ) {\n\t\t\tif ( typeof context.getElementById !== \"undefined\" && documentIsHTML ) {\n\t\t\t\tvar elem = context.getElementById( id );\n\t\t\t\treturn elem ? [ elem ] : [];\n\t\t\t}\n\t\t};\n\t} else {\n\t\tExpr.filter[\"ID\"] =  function( id ) {\n\t\t\tvar attrId = id.replace( runescape, funescape );\n\t\t\treturn function( elem ) {\n\t\t\t\tvar node = typeof elem.getAttributeNode !== \"undefined\" &&\n\t\t\t\t\telem.getAttributeNode(\"id\");\n\t\t\t\treturn node && node.value === attrId;\n\t\t\t};\n\t\t};\n\n\t\t// Support: IE 6 - 7 only\n\t\t// getElementById is not reliable as a find shortcut\n\t\tExpr.find[\"ID\"] = function( id, context ) {\n\t\t\tif ( typeof context.getElementById !== \"undefined\" && documentIsHTML ) {\n\t\t\t\tvar node, i, elems,\n\t\t\t\t\telem = context.getElementById( id );\n\n\t\t\t\tif ( elem ) {\n\n\t\t\t\t\t// Verify the id attribute\n\t\t\t\t\tnode = elem.getAttributeNode(\"id\");\n\t\t\t\t\tif ( node && node.value === id ) {\n\t\t\t\t\t\treturn [ elem ];\n\t\t\t\t\t}\n\n\t\t\t\t\t// Fall back on getElementsByName\n\t\t\t\t\telems = context.getElementsByName( id );\n\t\t\t\t\ti = 0;\n\t\t\t\t\twhile ( (elem = elems[i++]) ) {\n\t\t\t\t\t\tnode = elem.getAttributeNode(\"id\");\n\t\t\t\t\t\tif ( node && node.value === id ) {\n\t\t\t\t\t\t\treturn [ elem ];\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn [];\n\t\t\t}\n\t\t};\n\t}\n\n\t// Tag\n\tExpr.find[\"TAG\"] = support.getElementsByTagName ?\n\t\tfunction( tag, context ) {\n\t\t\tif ( typeof context.getElementsByTagName !== \"undefined\" ) {\n\t\t\t\treturn context.getElementsByTagName( tag );\n\n\t\t\t// DocumentFragment nodes don't have gEBTN\n\t\t\t} else if ( support.qsa ) {\n\t\t\t\treturn context.querySelectorAll( tag );\n\t\t\t}\n\t\t} :\n\n\t\tfunction( tag, context ) {\n\t\t\tvar elem,\n\t\t\t\ttmp = [],\n\t\t\t\ti = 0,\n\t\t\t\t// By happy coincidence, a (broken) gEBTN appears on DocumentFragment nodes too\n\t\t\t\tresults = context.getElementsByTagName( tag );\n\n\t\t\t// Filter out possible comments\n\t\t\tif ( tag === \"*\" ) {\n\t\t\t\twhile ( (elem = results[i++]) ) {\n\t\t\t\t\tif ( elem.nodeType === 1 ) {\n\t\t\t\t\t\ttmp.push( elem );\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn tmp;\n\t\t\t}\n\t\t\treturn results;\n\t\t};\n\n\t// Class\n\tExpr.find[\"CLASS\"] = support.getElementsByClassName && function( className, context ) {\n\t\tif ( typeof context.getElementsByClassName !== \"undefined\" && documentIsHTML ) {\n\t\t\treturn context.getElementsByClassName( className );\n\t\t}\n\t};\n\n\t/* QSA/matchesSelector\n\t---------------------------------------------------------------------- */\n\n\t// QSA and matchesSelector support\n\n\t// matchesSelector(:active) reports false when true (IE9/Opera 11.5)\n\trbuggyMatches = [];\n\n\t// qSa(:focus) reports false when true (Chrome 21)\n\t// We allow this because of a bug in IE8/9 that throws an error\n\t// whenever `document.activeElement` is accessed on an iframe\n\t// So, we allow :focus to pass through QSA all the time to avoid the IE error\n\t// See https://bugs.jquery.com/ticket/13378\n\trbuggyQSA = [];\n\n\tif ( (support.qsa = rnative.test( document.querySelectorAll )) ) {\n\t\t// Build QSA regex\n\t\t// Regex strategy adopted from Diego Perini\n\t\tassert(function( el ) {\n\t\t\t// Select is set to empty string on purpose\n\t\t\t// This is to test IE's treatment of not explicitly\n\t\t\t// setting a boolean content attribute,\n\t\t\t// since its presence should be enough\n\t\t\t// https://bugs.jquery.com/ticket/12359\n\t\t\tdocElem.appendChild( el ).innerHTML = \"<a id='\" + expando + \"'></a>\" +\n\t\t\t\t\"<select id='\" + expando + \"-\\r\\\\' msallowcapture=''>\" +\n\t\t\t\t\"<option selected=''></option></select>\";\n\n\t\t\t// Support: IE8, Opera 11-12.16\n\t\t\t// Nothing should be selected when empty strings follow ^= or $= or *=\n\t\t\t// The test attribute must be unknown in Opera but \"safe\" for WinRT\n\t\t\t// https://msdn.microsoft.com/en-us/library/ie/hh465388.aspx#attribute_section\n\t\t\tif ( el.querySelectorAll(\"[msallowcapture^='']\").length ) {\n\t\t\t\trbuggyQSA.push( \"[*^$]=\" + whitespace + \"*(?:''|\\\"\\\")\" );\n\t\t\t}\n\n\t\t\t// Support: IE8\n\t\t\t// Boolean attributes and \"value\" are not treated correctly\n\t\t\tif ( !el.querySelectorAll(\"[selected]\").length ) {\n\t\t\t\trbuggyQSA.push( \"\\\\[\" + whitespace + \"*(?:value|\" + booleans + \")\" );\n\t\t\t}\n\n\t\t\t// Support: Chrome<29, Android<4.4, Safari<7.0+, iOS<7.0+, PhantomJS<1.9.8+\n\t\t\tif ( !el.querySelectorAll( \"[id~=\" + expando + \"-]\" ).length ) {\n\t\t\t\trbuggyQSA.push(\"~=\");\n\t\t\t}\n\n\t\t\t// Webkit/Opera - :checked should return selected option elements\n\t\t\t// http://www.w3.org/TR/2011/REC-css3-selectors-20110929/#checked\n\t\t\t// IE8 throws error here and will not see later tests\n\t\t\tif ( !el.querySelectorAll(\":checked\").length ) {\n\t\t\t\trbuggyQSA.push(\":checked\");\n\t\t\t}\n\n\t\t\t// Support: Safari 8+, iOS 8+\n\t\t\t// https://bugs.webkit.org/show_bug.cgi?id=136851\n\t\t\t// In-page `selector#id sibling-combinator selector` fails\n\t\t\tif ( !el.querySelectorAll( \"a#\" + expando + \"+*\" ).length ) {\n\t\t\t\trbuggyQSA.push(\".#.+[+~]\");\n\t\t\t}\n\t\t});\n\n\t\tassert(function( el ) {\n\t\t\tel.innerHTML = \"<a href='' disabled='disabled'></a>\" +\n\t\t\t\t\"<select disabled='disabled'><option/></select>\";\n\n\t\t\t// Support: Windows 8 Native Apps\n\t\t\t// The type and name attributes are restricted during .innerHTML assignment\n\t\t\tvar input = document.createElement(\"input\");\n\t\t\tinput.setAttribute( \"type\", \"hidden\" );\n\t\t\tel.appendChild( input ).setAttribute( \"name\", \"D\" );\n\n\t\t\t// Support: IE8\n\t\t\t// Enforce case-sensitivity of name attribute\n\t\t\tif ( el.querySelectorAll(\"[name=d]\").length ) {\n\t\t\t\trbuggyQSA.push( \"name\" + whitespace + \"*[*^$|!~]?=\" );\n\t\t\t}\n\n\t\t\t// FF 3.5 - :enabled/:disabled and hidden elements (hidden elements are still enabled)\n\t\t\t// IE8 throws error here and will not see later tests\n\t\t\tif ( el.querySelectorAll(\":enabled\").length !== 2 ) {\n\t\t\t\trbuggyQSA.push( \":enabled\", \":disabled\" );\n\t\t\t}\n\n\t\t\t// Support: IE9-11+\n\t\t\t// IE's :disabled selector does not pick up the children of disabled fieldsets\n\t\t\tdocElem.appendChild( el ).disabled = true;\n\t\t\tif ( el.querySelectorAll(\":disabled\").length !== 2 ) {\n\t\t\t\trbuggyQSA.push( \":enabled\", \":disabled\" );\n\t\t\t}\n\n\t\t\t// Opera 10-11 does not throw on post-comma invalid pseudos\n\t\t\tel.querySelectorAll(\"*,:x\");\n\t\t\trbuggyQSA.push(\",.*:\");\n\t\t});\n\t}\n\n\tif ( (support.matchesSelector = rnative.test( (matches = docElem.matches ||\n\t\tdocElem.webkitMatchesSelector ||\n\t\tdocElem.mozMatchesSelector ||\n\t\tdocElem.oMatchesSelector ||\n\t\tdocElem.msMatchesSelector) )) ) {\n\n\t\tassert(function( el ) {\n\t\t\t// Check to see if it's possible to do matchesSelector\n\t\t\t// on a disconnected node (IE 9)\n\t\t\tsupport.disconnectedMatch = matches.call( el, \"*\" );\n\n\t\t\t// This should fail with an exception\n\t\t\t// Gecko does not error, returns false instead\n\t\t\tmatches.call( el, \"[s!='']:x\" );\n\t\t\trbuggyMatches.push( \"!=\", pseudos );\n\t\t});\n\t}\n\n\trbuggyQSA = rbuggyQSA.length && new RegExp( rbuggyQSA.join(\"|\") );\n\trbuggyMatches = rbuggyMatches.length && new RegExp( rbuggyMatches.join(\"|\") );\n\n\t/* Contains\n\t---------------------------------------------------------------------- */\n\thasCompare = rnative.test( docElem.compareDocumentPosition );\n\n\t// Element contains another\n\t// Purposefully self-exclusive\n\t// As in, an element does not contain itself\n\tcontains = hasCompare || rnative.test( docElem.contains ) ?\n\t\tfunction( a, b ) {\n\t\t\tvar adown = a.nodeType === 9 ? a.documentElement : a,\n\t\t\t\tbup = b && b.parentNode;\n\t\t\treturn a === bup || !!( bup && bup.nodeType === 1 && (\n\t\t\t\tadown.contains ?\n\t\t\t\t\tadown.contains( bup ) :\n\t\t\t\t\ta.compareDocumentPosition && a.compareDocumentPosition( bup ) & 16\n\t\t\t));\n\t\t} :\n\t\tfunction( a, b ) {\n\t\t\tif ( b ) {\n\t\t\t\twhile ( (b = b.parentNode) ) {\n\t\t\t\t\tif ( b === a ) {\n\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn false;\n\t\t};\n\n\t/* Sorting\n\t---------------------------------------------------------------------- */\n\n\t// Document order sorting\n\tsortOrder = hasCompare ?\n\tfunction( a, b ) {\n\n\t\t// Flag for duplicate removal\n\t\tif ( a === b ) {\n\t\t\thasDuplicate = true;\n\t\t\treturn 0;\n\t\t}\n\n\t\t// Sort on method existence if only one input has compareDocumentPosition\n\t\tvar compare = !a.compareDocumentPosition - !b.compareDocumentPosition;\n\t\tif ( compare ) {\n\t\t\treturn compare;\n\t\t}\n\n\t\t// Calculate position if both inputs belong to the same document\n\t\tcompare = ( a.ownerDocument || a ) === ( b.ownerDocument || b ) ?\n\t\t\ta.compareDocumentPosition( b ) :\n\n\t\t\t// Otherwise we know they are disconnected\n\t\t\t1;\n\n\t\t// Disconnected nodes\n\t\tif ( compare & 1 ||\n\t\t\t(!support.sortDetached && b.compareDocumentPosition( a ) === compare) ) {\n\n\t\t\t// Choose the first element that is related to our preferred document\n\t\t\tif ( a === document || a.ownerDocument === preferredDoc && contains(preferredDoc, a) ) {\n\t\t\t\treturn -1;\n\t\t\t}\n\t\t\tif ( b === document || b.ownerDocument === preferredDoc && contains(preferredDoc, b) ) {\n\t\t\t\treturn 1;\n\t\t\t}\n\n\t\t\t// Maintain original order\n\t\t\treturn sortInput ?\n\t\t\t\t( indexOf( sortInput, a ) - indexOf( sortInput, b ) ) :\n\t\t\t\t0;\n\t\t}\n\n\t\treturn compare & 4 ? -1 : 1;\n\t} :\n\tfunction( a, b ) {\n\t\t// Exit early if the nodes are identical\n\t\tif ( a === b ) {\n\t\t\thasDuplicate = true;\n\t\t\treturn 0;\n\t\t}\n\n\t\tvar cur,\n\t\t\ti = 0,\n\t\t\taup = a.parentNode,\n\t\t\tbup = b.parentNode,\n\t\t\tap = [ a ],\n\t\t\tbp = [ b ];\n\n\t\t// Parentless nodes are either documents or disconnected\n\t\tif ( !aup || !bup ) {\n\t\t\treturn a === document ? -1 :\n\t\t\t\tb === document ? 1 :\n\t\t\t\taup ? -1 :\n\t\t\t\tbup ? 1 :\n\t\t\t\tsortInput ?\n\t\t\t\t( indexOf( sortInput, a ) - indexOf( sortInput, b ) ) :\n\t\t\t\t0;\n\n\t\t// If the nodes are siblings, we can do a quick check\n\t\t} else if ( aup === bup ) {\n\t\t\treturn siblingCheck( a, b );\n\t\t}\n\n\t\t// Otherwise we need full lists of their ancestors for comparison\n\t\tcur = a;\n\t\twhile ( (cur = cur.parentNode) ) {\n\t\t\tap.unshift( cur );\n\t\t}\n\t\tcur = b;\n\t\twhile ( (cur = cur.parentNode) ) {\n\t\t\tbp.unshift( cur );\n\t\t}\n\n\t\t// Walk down the tree looking for a discrepancy\n\t\twhile ( ap[i] === bp[i] ) {\n\t\t\ti++;\n\t\t}\n\n\t\treturn i ?\n\t\t\t// Do a sibling check if the nodes have a common ancestor\n\t\t\tsiblingCheck( ap[i], bp[i] ) :\n\n\t\t\t// Otherwise nodes in our document sort first\n\t\t\tap[i] === preferredDoc ? -1 :\n\t\t\tbp[i] === preferredDoc ? 1 :\n\t\t\t0;\n\t};\n\n\treturn document;\n};\n\nSizzle.matches = function( expr, elements ) {\n\treturn Sizzle( expr, null, null, elements );\n};\n\nSizzle.matchesSelector = function( elem, expr ) {\n\t// Set document vars if needed\n\tif ( ( elem.ownerDocument || elem ) !== document ) {\n\t\tsetDocument( elem );\n\t}\n\n\tif ( support.matchesSelector && documentIsHTML &&\n\t\t!nonnativeSelectorCache[ expr + \" \" ] &&\n\t\t( !rbuggyMatches || !rbuggyMatches.test( expr ) ) &&\n\t\t( !rbuggyQSA     || !rbuggyQSA.test( expr ) ) ) {\n\n\t\ttry {\n\t\t\tvar ret = matches.call( elem, expr );\n\n\t\t\t// IE 9's matchesSelector returns false on disconnected nodes\n\t\t\tif ( ret || support.disconnectedMatch ||\n\t\t\t\t\t// As well, disconnected nodes are said to be in a document\n\t\t\t\t\t// fragment in IE 9\n\t\t\t\t\telem.document && elem.document.nodeType !== 11 ) {\n\t\t\t\treturn ret;\n\t\t\t}\n\t\t} catch (e) {\n\t\t\tnonnativeSelectorCache( expr, true );\n\t\t}\n\t}\n\n\treturn Sizzle( expr, document, null, [ elem ] ).length > 0;\n};\n\nSizzle.contains = function( context, elem ) {\n\t// Set document vars if needed\n\tif ( ( context.ownerDocument || context ) !== document ) {\n\t\tsetDocument( context );\n\t}\n\treturn contains( context, elem );\n};\n\nSizzle.attr = function( elem, name ) {\n\t// Set document vars if needed\n\tif ( ( elem.ownerDocument || elem ) !== document ) {\n\t\tsetDocument( elem );\n\t}\n\n\tvar fn = Expr.attrHandle[ name.toLowerCase() ],\n\t\t// Don't get fooled by Object.prototype properties (jQuery #13807)\n\t\tval = fn && hasOwn.call( Expr.attrHandle, name.toLowerCase() ) ?\n\t\t\tfn( elem, name, !documentIsHTML ) :\n\t\t\tundefined;\n\n\treturn val !== undefined ?\n\t\tval :\n\t\tsupport.attributes || !documentIsHTML ?\n\t\t\telem.getAttribute( name ) :\n\t\t\t(val = elem.getAttributeNode(name)) && val.specified ?\n\t\t\t\tval.value :\n\t\t\t\tnull;\n};\n\nSizzle.escape = function( sel ) {\n\treturn (sel + \"\").replace( rcssescape, fcssescape );\n};\n\nSizzle.error = function( msg ) {\n\tthrow new Error( \"Syntax error, unrecognized expression: \" + msg );\n};\n\n/**\n * Document sorting and removing duplicates\n * @param {ArrayLike} results\n */\nSizzle.uniqueSort = function( results ) {\n\tvar elem,\n\t\tduplicates = [],\n\t\tj = 0,\n\t\ti = 0;\n\n\t// Unless we *know* we can detect duplicates, assume their presence\n\thasDuplicate = !support.detectDuplicates;\n\tsortInput = !support.sortStable && results.slice( 0 );\n\tresults.sort( sortOrder );\n\n\tif ( hasDuplicate ) {\n\t\twhile ( (elem = results[i++]) ) {\n\t\t\tif ( elem === results[ i ] ) {\n\t\t\t\tj = duplicates.push( i );\n\t\t\t}\n\t\t}\n\t\twhile ( j-- ) {\n\t\t\tresults.splice( duplicates[ j ], 1 );\n\t\t}\n\t}\n\n\t// Clear input after sorting to release objects\n\t// See https://github.com/jquery/sizzle/pull/225\n\tsortInput = null;\n\n\treturn results;\n};\n\n/**\n * Utility function for retrieving the text value of an array of DOM nodes\n * @param {Array|Element} elem\n */\ngetText = Sizzle.getText = function( elem ) {\n\tvar node,\n\t\tret = \"\",\n\t\ti = 0,\n\t\tnodeType = elem.nodeType;\n\n\tif ( !nodeType ) {\n\t\t// If no nodeType, this is expected to be an array\n\t\twhile ( (node = elem[i++]) ) {\n\t\t\t// Do not traverse comment nodes\n\t\t\tret += getText( node );\n\t\t}\n\t} else if ( nodeType === 1 || nodeType === 9 || nodeType === 11 ) {\n\t\t// Use textContent for elements\n\t\t// innerText usage removed for consistency of new lines (jQuery #11153)\n\t\tif ( typeof elem.textContent === \"string\" ) {\n\t\t\treturn elem.textContent;\n\t\t} else {\n\t\t\t// Traverse its children\n\t\t\tfor ( elem = elem.firstChild; elem; elem = elem.nextSibling ) {\n\t\t\t\tret += getText( elem );\n\t\t\t}\n\t\t}\n\t} else if ( nodeType === 3 || nodeType === 4 ) {\n\t\treturn elem.nodeValue;\n\t}\n\t// Do not include comment or processing instruction nodes\n\n\treturn ret;\n};\n\nExpr = Sizzle.selectors = {\n\n\t// Can be adjusted by the user\n\tcacheLength: 50,\n\n\tcreatePseudo: markFunction,\n\n\tmatch: matchExpr,\n\n\tattrHandle: {},\n\n\tfind: {},\n\n\trelative: {\n\t\t\">\": { dir: \"parentNode\", first: true },\n\t\t\" \": { dir: \"parentNode\" },\n\t\t\"+\": { dir: \"previousSibling\", first: true },\n\t\t\"~\": { dir: \"previousSibling\" }\n\t},\n\n\tpreFilter: {\n\t\t\"ATTR\": function( match ) {\n\t\t\tmatch[1] = match[1].replace( runescape, funescape );\n\n\t\t\t// Move the given value to match[3] whether quoted or unquoted\n\t\t\tmatch[3] = ( match[3] || match[4] || match[5] || \"\" ).replace( runescape, funescape );\n\n\t\t\tif ( match[2] === \"~=\" ) {\n\t\t\t\tmatch[3] = \" \" + match[3] + \" \";\n\t\t\t}\n\n\t\t\treturn match.slice( 0, 4 );\n\t\t},\n\n\t\t\"CHILD\": function( match ) {\n\t\t\t/* matches from matchExpr[\"CHILD\"]\n\t\t\t\t1 type (only|nth|...)\n\t\t\t\t2 what (child|of-type)\n\t\t\t\t3 argument (even|odd|\\d*|\\d*n([+-]\\d+)?|...)\n\t\t\t\t4 xn-component of xn+y argument ([+-]?\\d*n|)\n\t\t\t\t5 sign of xn-component\n\t\t\t\t6 x of xn-component\n\t\t\t\t7 sign of y-component\n\t\t\t\t8 y of y-component\n\t\t\t*/\n\t\t\tmatch[1] = match[1].toLowerCase();\n\n\t\t\tif ( match[1].slice( 0, 3 ) === \"nth\" ) {\n\t\t\t\t// nth-* requires argument\n\t\t\t\tif ( !match[3] ) {\n\t\t\t\t\tSizzle.error( match[0] );\n\t\t\t\t}\n\n\t\t\t\t// numeric x and y parameters for Expr.filter.CHILD\n\t\t\t\t// remember that false/true cast respectively to 0/1\n\t\t\t\tmatch[4] = +( match[4] ? match[5] + (match[6] || 1) : 2 * ( match[3] === \"even\" || match[3] === \"odd\" ) );\n\t\t\t\tmatch[5] = +( ( match[7] + match[8] ) || match[3] === \"odd\" );\n\n\t\t\t// other types prohibit arguments\n\t\t\t} else if ( match[3] ) {\n\t\t\t\tSizzle.error( match[0] );\n\t\t\t}\n\n\t\t\treturn match;\n\t\t},\n\n\t\t\"PSEUDO\": function( match ) {\n\t\t\tvar excess,\n\t\t\t\tunquoted = !match[6] && match[2];\n\n\t\t\tif ( matchExpr[\"CHILD\"].test( match[0] ) ) {\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\t// Accept quoted arguments as-is\n\t\t\tif ( match[3] ) {\n\t\t\t\tmatch[2] = match[4] || match[5] || \"\";\n\n\t\t\t// Strip excess characters from unquoted arguments\n\t\t\t} else if ( unquoted && rpseudo.test( unquoted ) &&\n\t\t\t\t// Get excess from tokenize (recursively)\n\t\t\t\t(excess = tokenize( unquoted, true )) &&\n\t\t\t\t// advance to the next closing parenthesis\n\t\t\t\t(excess = unquoted.indexOf( \")\", unquoted.length - excess ) - unquoted.length) ) {\n\n\t\t\t\t// excess is a negative index\n\t\t\t\tmatch[0] = match[0].slice( 0, excess );\n\t\t\t\tmatch[2] = unquoted.slice( 0, excess );\n\t\t\t}\n\n\t\t\t// Return only captures needed by the pseudo filter method (type and argument)\n\t\t\treturn match.slice( 0, 3 );\n\t\t}\n\t},\n\n\tfilter: {\n\n\t\t\"TAG\": function( nodeNameSelector ) {\n\t\t\tvar nodeName = nodeNameSelector.replace( runescape, funescape ).toLowerCase();\n\t\t\treturn nodeNameSelector === \"*\" ?\n\t\t\t\tfunction() { return true; } :\n\t\t\t\tfunction( elem ) {\n\t\t\t\t\treturn elem.nodeName && elem.nodeName.toLowerCase() === nodeName;\n\t\t\t\t};\n\t\t},\n\n\t\t\"CLASS\": function( className ) {\n\t\t\tvar pattern = classCache[ className + \" \" ];\n\n\t\t\treturn pattern ||\n\t\t\t\t(pattern = new RegExp( \"(^|\" + whitespace + \")\" + className + \"(\" + whitespace + \"|$)\" )) &&\n\t\t\t\tclassCache( className, function( elem ) {\n\t\t\t\t\treturn pattern.test( typeof elem.className === \"string\" && elem.className || typeof elem.getAttribute !== \"undefined\" && elem.getAttribute(\"class\") || \"\" );\n\t\t\t\t});\n\t\t},\n\n\t\t\"ATTR\": function( name, operator, check ) {\n\t\t\treturn function( elem ) {\n\t\t\t\tvar result = Sizzle.attr( elem, name );\n\n\t\t\t\tif ( result == null ) {\n\t\t\t\t\treturn operator === \"!=\";\n\t\t\t\t}\n\t\t\t\tif ( !operator ) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\n\t\t\t\tresult += \"\";\n\n\t\t\t\treturn operator === \"=\" ? result === check :\n\t\t\t\t\toperator === \"!=\" ? result !== check :\n\t\t\t\t\toperator === \"^=\" ? check && result.indexOf( check ) === 0 :\n\t\t\t\t\toperator === \"*=\" ? check && result.indexOf( check ) > -1 :\n\t\t\t\t\toperator === \"$=\" ? check && result.slice( -check.length ) === check :\n\t\t\t\t\toperator === \"~=\" ? ( \" \" + result.replace( rwhitespace, \" \" ) + \" \" ).indexOf( check ) > -1 :\n\t\t\t\t\toperator === \"|=\" ? result === check || result.slice( 0, check.length + 1 ) === check + \"-\" :\n\t\t\t\t\tfalse;\n\t\t\t};\n\t\t},\n\n\t\t\"CHILD\": function( type, what, argument, first, last ) {\n\t\t\tvar simple = type.slice( 0, 3 ) !== \"nth\",\n\t\t\t\tforward = type.slice( -4 ) !== \"last\",\n\t\t\t\tofType = what === \"of-type\";\n\n\t\t\treturn first === 1 && last === 0 ?\n\n\t\t\t\t// Shortcut for :nth-*(n)\n\t\t\t\tfunction( elem ) {\n\t\t\t\t\treturn !!elem.parentNode;\n\t\t\t\t} :\n\n\t\t\t\tfunction( elem, context, xml ) {\n\t\t\t\t\tvar cache, uniqueCache, outerCache, node, nodeIndex, start,\n\t\t\t\t\t\tdir = simple !== forward ? \"nextSibling\" : \"previousSibling\",\n\t\t\t\t\t\tparent = elem.parentNode,\n\t\t\t\t\t\tname = ofType && elem.nodeName.toLowerCase(),\n\t\t\t\t\t\tuseCache = !xml && !ofType,\n\t\t\t\t\t\tdiff = false;\n\n\t\t\t\t\tif ( parent ) {\n\n\t\t\t\t\t\t// :(first|last|only)-(child|of-type)\n\t\t\t\t\t\tif ( simple ) {\n\t\t\t\t\t\t\twhile ( dir ) {\n\t\t\t\t\t\t\t\tnode = elem;\n\t\t\t\t\t\t\t\twhile ( (node = node[ dir ]) ) {\n\t\t\t\t\t\t\t\t\tif ( ofType ?\n\t\t\t\t\t\t\t\t\t\tnode.nodeName.toLowerCase() === name :\n\t\t\t\t\t\t\t\t\t\tnode.nodeType === 1 ) {\n\n\t\t\t\t\t\t\t\t\t\treturn false;\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t// Reverse direction for :only-* (if we haven't yet done so)\n\t\t\t\t\t\t\t\tstart = dir = type === \"only\" && !start && \"nextSibling\";\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\treturn true;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tstart = [ forward ? parent.firstChild : parent.lastChild ];\n\n\t\t\t\t\t\t// non-xml :nth-child(...) stores cache data on `parent`\n\t\t\t\t\t\tif ( forward && useCache ) {\n\n\t\t\t\t\t\t\t// Seek `elem` from a previously-cached index\n\n\t\t\t\t\t\t\t// ...in a gzip-friendly way\n\t\t\t\t\t\t\tnode = parent;\n\t\t\t\t\t\t\touterCache = node[ expando ] || (node[ expando ] = {});\n\n\t\t\t\t\t\t\t// Support: IE <9 only\n\t\t\t\t\t\t\t// Defend against cloned attroperties (jQuery gh-1709)\n\t\t\t\t\t\t\tuniqueCache = outerCache[ node.uniqueID ] ||\n\t\t\t\t\t\t\t\t(outerCache[ node.uniqueID ] = {});\n\n\t\t\t\t\t\t\tcache = uniqueCache[ type ] || [];\n\t\t\t\t\t\t\tnodeIndex = cache[ 0 ] === dirruns && cache[ 1 ];\n\t\t\t\t\t\t\tdiff = nodeIndex && cache[ 2 ];\n\t\t\t\t\t\t\tnode = nodeIndex && parent.childNodes[ nodeIndex ];\n\n\t\t\t\t\t\t\twhile ( (node = ++nodeIndex && node && node[ dir ] ||\n\n\t\t\t\t\t\t\t\t// Fallback to seeking `elem` from the start\n\t\t\t\t\t\t\t\t(diff = nodeIndex = 0) || start.pop()) ) {\n\n\t\t\t\t\t\t\t\t// When found, cache indexes on `parent` and break\n\t\t\t\t\t\t\t\tif ( node.nodeType === 1 && ++diff && node === elem ) {\n\t\t\t\t\t\t\t\t\tuniqueCache[ type ] = [ dirruns, nodeIndex, diff ];\n\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// Use previously-cached element index if available\n\t\t\t\t\t\t\tif ( useCache ) {\n\t\t\t\t\t\t\t\t// ...in a gzip-friendly way\n\t\t\t\t\t\t\t\tnode = elem;\n\t\t\t\t\t\t\t\touterCache = node[ expando ] || (node[ expando ] = {});\n\n\t\t\t\t\t\t\t\t// Support: IE <9 only\n\t\t\t\t\t\t\t\t// Defend against cloned attroperties (jQuery gh-1709)\n\t\t\t\t\t\t\t\tuniqueCache = outerCache[ node.uniqueID ] ||\n\t\t\t\t\t\t\t\t\t(outerCache[ node.uniqueID ] = {});\n\n\t\t\t\t\t\t\t\tcache = uniqueCache[ type ] || [];\n\t\t\t\t\t\t\t\tnodeIndex = cache[ 0 ] === dirruns && cache[ 1 ];\n\t\t\t\t\t\t\t\tdiff = nodeIndex;\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// xml :nth-child(...)\n\t\t\t\t\t\t\t// or :nth-last-child(...) or :nth(-last)?-of-type(...)\n\t\t\t\t\t\t\tif ( diff === false ) {\n\t\t\t\t\t\t\t\t// Use the same loop as above to seek `elem` from the start\n\t\t\t\t\t\t\t\twhile ( (node = ++nodeIndex && node && node[ dir ] ||\n\t\t\t\t\t\t\t\t\t(diff = nodeIndex = 0) || start.pop()) ) {\n\n\t\t\t\t\t\t\t\t\tif ( ( ofType ?\n\t\t\t\t\t\t\t\t\t\tnode.nodeName.toLowerCase() === name :\n\t\t\t\t\t\t\t\t\t\tnode.nodeType === 1 ) &&\n\t\t\t\t\t\t\t\t\t\t++diff ) {\n\n\t\t\t\t\t\t\t\t\t\t// Cache the index of each encountered element\n\t\t\t\t\t\t\t\t\t\tif ( useCache ) {\n\t\t\t\t\t\t\t\t\t\t\touterCache = node[ expando ] || (node[ expando ] = {});\n\n\t\t\t\t\t\t\t\t\t\t\t// Support: IE <9 only\n\t\t\t\t\t\t\t\t\t\t\t// Defend against cloned attroperties (jQuery gh-1709)\n\t\t\t\t\t\t\t\t\t\t\tuniqueCache = outerCache[ node.uniqueID ] ||\n\t\t\t\t\t\t\t\t\t\t\t\t(outerCache[ node.uniqueID ] = {});\n\n\t\t\t\t\t\t\t\t\t\t\tuniqueCache[ type ] = [ dirruns, diff ];\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\tif ( node === elem ) {\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// Incorporate the offset, then check against cycle size\n\t\t\t\t\t\tdiff -= last;\n\t\t\t\t\t\treturn diff === first || ( diff % first === 0 && diff / first >= 0 );\n\t\t\t\t\t}\n\t\t\t\t};\n\t\t},\n\n\t\t\"PSEUDO\": function( pseudo, argument ) {\n\t\t\t// pseudo-class names are case-insensitive\n\t\t\t// http://www.w3.org/TR/selectors/#pseudo-classes\n\t\t\t// Prioritize by case sensitivity in case custom pseudos are added with uppercase letters\n\t\t\t// Remember that setFilters inherits from pseudos\n\t\t\tvar args,\n\t\t\t\tfn = Expr.pseudos[ pseudo ] || Expr.setFilters[ pseudo.toLowerCase() ] ||\n\t\t\t\t\tSizzle.error( \"unsupported pseudo: \" + pseudo );\n\n\t\t\t// The user may use createPseudo to indicate that\n\t\t\t// arguments are needed to create the filter function\n\t\t\t// just as Sizzle does\n\t\t\tif ( fn[ expando ] ) {\n\t\t\t\treturn fn( argument );\n\t\t\t}\n\n\t\t\t// But maintain support for old signatures\n\t\t\tif ( fn.length > 1 ) {\n\t\t\t\targs = [ pseudo, pseudo, \"\", argument ];\n\t\t\t\treturn Expr.setFilters.hasOwnProperty( pseudo.toLowerCase() ) ?\n\t\t\t\t\tmarkFunction(function( seed, matches ) {\n\t\t\t\t\t\tvar idx,\n\t\t\t\t\t\t\tmatched = fn( seed, argument ),\n\t\t\t\t\t\t\ti = matched.length;\n\t\t\t\t\t\twhile ( i-- ) {\n\t\t\t\t\t\t\tidx = indexOf( seed, matched[i] );\n\t\t\t\t\t\t\tseed[ idx ] = !( matches[ idx ] = matched[i] );\n\t\t\t\t\t\t}\n\t\t\t\t\t}) :\n\t\t\t\t\tfunction( elem ) {\n\t\t\t\t\t\treturn fn( elem, 0, args );\n\t\t\t\t\t};\n\t\t\t}\n\n\t\t\treturn fn;\n\t\t}\n\t},\n\n\tpseudos: {\n\t\t// Potentially complex pseudos\n\t\t\"not\": markFunction(function( selector ) {\n\t\t\t// Trim the selector passed to compile\n\t\t\t// to avoid treating leading and trailing\n\t\t\t// spaces as combinators\n\t\t\tvar input = [],\n\t\t\t\tresults = [],\n\t\t\t\tmatcher = compile( selector.replace( rtrim, \"$1\" ) );\n\n\t\t\treturn matcher[ expando ] ?\n\t\t\t\tmarkFunction(function( seed, matches, context, xml ) {\n\t\t\t\t\tvar elem,\n\t\t\t\t\t\tunmatched = matcher( seed, null, xml, [] ),\n\t\t\t\t\t\ti = seed.length;\n\n\t\t\t\t\t// Match elements unmatched by `matcher`\n\t\t\t\t\twhile ( i-- ) {\n\t\t\t\t\t\tif ( (elem = unmatched[i]) ) {\n\t\t\t\t\t\t\tseed[i] = !(matches[i] = elem);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}) :\n\t\t\t\tfunction( elem, context, xml ) {\n\t\t\t\t\tinput[0] = elem;\n\t\t\t\t\tmatcher( input, null, xml, results );\n\t\t\t\t\t// Don't keep the element (issue #299)\n\t\t\t\t\tinput[0] = null;\n\t\t\t\t\treturn !results.pop();\n\t\t\t\t};\n\t\t}),\n\n\t\t\"has\": markFunction(function( selector ) {\n\t\t\treturn function( elem ) {\n\t\t\t\treturn Sizzle( selector, elem ).length > 0;\n\t\t\t};\n\t\t}),\n\n\t\t\"contains\": markFunction(function( text ) {\n\t\t\ttext = text.replace( runescape, funescape );\n\t\t\treturn function( elem ) {\n\t\t\t\treturn ( elem.textContent || getText( elem ) ).indexOf( text ) > -1;\n\t\t\t};\n\t\t}),\n\n\t\t// \"Whether an element is represented by a :lang() selector\n\t\t// is based solely on the element's language value\n\t\t// being equal to the identifier C,\n\t\t// or beginning with the identifier C immediately followed by \"-\".\n\t\t// The matching of C against the element's language value is performed case-insensitively.\n\t\t// The identifier C does not have to be a valid language name.\"\n\t\t// http://www.w3.org/TR/selectors/#lang-pseudo\n\t\t\"lang\": markFunction( function( lang ) {\n\t\t\t// lang value must be a valid identifier\n\t\t\tif ( !ridentifier.test(lang || \"\") ) {\n\t\t\t\tSizzle.error( \"unsupported lang: \" + lang );\n\t\t\t}\n\t\t\tlang = lang.replace( runescape, funescape ).toLowerCase();\n\t\t\treturn function( elem ) {\n\t\t\t\tvar elemLang;\n\t\t\t\tdo {\n\t\t\t\t\tif ( (elemLang = documentIsHTML ?\n\t\t\t\t\t\telem.lang :\n\t\t\t\t\t\telem.getAttribute(\"xml:lang\") || elem.getAttribute(\"lang\")) ) {\n\n\t\t\t\t\t\telemLang = elemLang.toLowerCase();\n\t\t\t\t\t\treturn elemLang === lang || elemLang.indexOf( lang + \"-\" ) === 0;\n\t\t\t\t\t}\n\t\t\t\t} while ( (elem = elem.parentNode) && elem.nodeType === 1 );\n\t\t\t\treturn false;\n\t\t\t};\n\t\t}),\n\n\t\t// Miscellaneous\n\t\t\"target\": function( elem ) {\n\t\t\tvar hash = window.location && window.location.hash;\n\t\t\treturn hash && hash.slice( 1 ) === elem.id;\n\t\t},\n\n\t\t\"root\": function( elem ) {\n\t\t\treturn elem === docElem;\n\t\t},\n\n\t\t\"focus\": function( elem ) {\n\t\t\treturn elem === document.activeElement && (!document.hasFocus || document.hasFocus()) && !!(elem.type || elem.href || ~elem.tabIndex);\n\t\t},\n\n\t\t// Boolean properties\n\t\t\"enabled\": createDisabledPseudo( false ),\n\t\t\"disabled\": createDisabledPseudo( true ),\n\n\t\t\"checked\": function( elem ) {\n\t\t\t// In CSS3, :checked should return both checked and selected elements\n\t\t\t// http://www.w3.org/TR/2011/REC-css3-selectors-20110929/#checked\n\t\t\tvar nodeName = elem.nodeName.toLowerCase();\n\t\t\treturn (nodeName === \"input\" && !!elem.checked) || (nodeName === \"option\" && !!elem.selected);\n\t\t},\n\n\t\t\"selected\": function( elem ) {\n\t\t\t// Accessing this property makes selected-by-default\n\t\t\t// options in Safari work properly\n\t\t\tif ( elem.parentNode ) {\n\t\t\t\telem.parentNode.selectedIndex;\n\t\t\t}\n\n\t\t\treturn elem.selected === true;\n\t\t},\n\n\t\t// Contents\n\t\t\"empty\": function( elem ) {\n\t\t\t// http://www.w3.org/TR/selectors/#empty-pseudo\n\t\t\t// :empty is negated by element (1) or content nodes (text: 3; cdata: 4; entity ref: 5),\n\t\t\t//   but not by others (comment: 8; processing instruction: 7; etc.)\n\t\t\t// nodeType < 6 works because attributes (2) do not appear as children\n\t\t\tfor ( elem = elem.firstChild; elem; elem = elem.nextSibling ) {\n\t\t\t\tif ( elem.nodeType < 6 ) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn true;\n\t\t},\n\n\t\t\"parent\": function( elem ) {\n\t\t\treturn !Expr.pseudos[\"empty\"]( elem );\n\t\t},\n\n\t\t// Element/input types\n\t\t\"header\": function( elem ) {\n\t\t\treturn rheader.test( elem.nodeName );\n\t\t},\n\n\t\t\"input\": function( elem ) {\n\t\t\treturn rinputs.test( elem.nodeName );\n\t\t},\n\n\t\t\"button\": function( elem ) {\n\t\t\tvar name = elem.nodeName.toLowerCase();\n\t\t\treturn name === \"input\" && elem.type === \"button\" || name === \"button\";\n\t\t},\n\n\t\t\"text\": function( elem ) {\n\t\t\tvar attr;\n\t\t\treturn elem.nodeName.toLowerCase() === \"input\" &&\n\t\t\t\telem.type === \"text\" &&\n\n\t\t\t\t// Support: IE<8\n\t\t\t\t// New HTML5 attribute values (e.g., \"search\") appear with elem.type === \"text\"\n\t\t\t\t( (attr = elem.getAttribute(\"type\")) == null || attr.toLowerCase() === \"text\" );\n\t\t},\n\n\t\t// Position-in-collection\n\t\t\"first\": createPositionalPseudo(function() {\n\t\t\treturn [ 0 ];\n\t\t}),\n\n\t\t\"last\": createPositionalPseudo(function( matchIndexes, length ) {\n\t\t\treturn [ length - 1 ];\n\t\t}),\n\n\t\t\"eq\": createPositionalPseudo(function( matchIndexes, length, argument ) {\n\t\t\treturn [ argument < 0 ? argument + length : argument ];\n\t\t}),\n\n\t\t\"even\": createPositionalPseudo(function( matchIndexes, length ) {\n\t\t\tvar i = 0;\n\t\t\tfor ( ; i < length; i += 2 ) {\n\t\t\t\tmatchIndexes.push( i );\n\t\t\t}\n\t\t\treturn matchIndexes;\n\t\t}),\n\n\t\t\"odd\": createPositionalPseudo(function( matchIndexes, length ) {\n\t\t\tvar i = 1;\n\t\t\tfor ( ; i < length; i += 2 ) {\n\t\t\t\tmatchIndexes.push( i );\n\t\t\t}\n\t\t\treturn matchIndexes;\n\t\t}),\n\n\t\t\"lt\": createPositionalPseudo(function( matchIndexes, length, argument ) {\n\t\t\tvar i = argument < 0 ?\n\t\t\t\targument + length :\n\t\t\t\targument > length ?\n\t\t\t\t\tlength :\n\t\t\t\t\targument;\n\t\t\tfor ( ; --i >= 0; ) {\n\t\t\t\tmatchIndexes.push( i );\n\t\t\t}\n\t\t\treturn matchIndexes;\n\t\t}),\n\n\t\t\"gt\": createPositionalPseudo(function( matchIndexes, length, argument ) {\n\t\t\tvar i = argument < 0 ? argument + length : argument;\n\t\t\tfor ( ; ++i < length; ) {\n\t\t\t\tmatchIndexes.push( i );\n\t\t\t}\n\t\t\treturn matchIndexes;\n\t\t})\n\t}\n};\n\nExpr.pseudos[\"nth\"] = Expr.pseudos[\"eq\"];\n\n// Add button/input type pseudos\nfor ( i in { radio: true, checkbox: true, file: true, password: true, image: true } ) {\n\tExpr.pseudos[ i ] = createInputPseudo( i );\n}\nfor ( i in { submit: true, reset: true } ) {\n\tExpr.pseudos[ i ] = createButtonPseudo( i );\n}\n\n// Easy API for creating new setFilters\nfunction setFilters() {}\nsetFilters.prototype = Expr.filters = Expr.pseudos;\nExpr.setFilters = new setFilters();\n\ntokenize = Sizzle.tokenize = function( selector, parseOnly ) {\n\tvar matched, match, tokens, type,\n\t\tsoFar, groups, preFilters,\n\t\tcached = tokenCache[ selector + \" \" ];\n\n\tif ( cached ) {\n\t\treturn parseOnly ? 0 : cached.slice( 0 );\n\t}\n\n\tsoFar = selector;\n\tgroups = [];\n\tpreFilters = Expr.preFilter;\n\n\twhile ( soFar ) {\n\n\t\t// Comma and first run\n\t\tif ( !matched || (match = rcomma.exec( soFar )) ) {\n\t\t\tif ( match ) {\n\t\t\t\t// Don't consume trailing commas as valid\n\t\t\t\tsoFar = soFar.slice( match[0].length ) || soFar;\n\t\t\t}\n\t\t\tgroups.push( (tokens = []) );\n\t\t}\n\n\t\tmatched = false;\n\n\t\t// Combinators\n\t\tif ( (match = rcombinators.exec( soFar )) ) {\n\t\t\tmatched = match.shift();\n\t\t\ttokens.push({\n\t\t\t\tvalue: matched,\n\t\t\t\t// Cast descendant combinators to space\n\t\t\t\ttype: match[0].replace( rtrim, \" \" )\n\t\t\t});\n\t\t\tsoFar = soFar.slice( matched.length );\n\t\t}\n\n\t\t// Filters\n\t\tfor ( type in Expr.filter ) {\n\t\t\tif ( (match = matchExpr[ type ].exec( soFar )) && (!preFilters[ type ] ||\n\t\t\t\t(match = preFilters[ type ]( match ))) ) {\n\t\t\t\tmatched = match.shift();\n\t\t\t\ttokens.push({\n\t\t\t\t\tvalue: matched,\n\t\t\t\t\ttype: type,\n\t\t\t\t\tmatches: match\n\t\t\t\t});\n\t\t\t\tsoFar = soFar.slice( matched.length );\n\t\t\t}\n\t\t}\n\n\t\tif ( !matched ) {\n\t\t\tbreak;\n\t\t}\n\t}\n\n\t// Return the length of the invalid excess\n\t// if we're just parsing\n\t// Otherwise, throw an error or return tokens\n\treturn parseOnly ?\n\t\tsoFar.length :\n\t\tsoFar ?\n\t\t\tSizzle.error( selector ) :\n\t\t\t// Cache the tokens\n\t\t\ttokenCache( selector, groups ).slice( 0 );\n};\n\nfunction toSelector( tokens ) {\n\tvar i = 0,\n\t\tlen = tokens.length,\n\t\tselector = \"\";\n\tfor ( ; i < len; i++ ) {\n\t\tselector += tokens[i].value;\n\t}\n\treturn selector;\n}\n\nfunction addCombinator( matcher, combinator, base ) {\n\tvar dir = combinator.dir,\n\t\tskip = combinator.next,\n\t\tkey = skip || dir,\n\t\tcheckNonElements = base && key === \"parentNode\",\n\t\tdoneName = done++;\n\n\treturn combinator.first ?\n\t\t// Check against closest ancestor/preceding element\n\t\tfunction( elem, context, xml ) {\n\t\t\twhile ( (elem = elem[ dir ]) ) {\n\t\t\t\tif ( elem.nodeType === 1 || checkNonElements ) {\n\t\t\t\t\treturn matcher( elem, context, xml );\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn false;\n\t\t} :\n\n\t\t// Check against all ancestor/preceding elements\n\t\tfunction( elem, context, xml ) {\n\t\t\tvar oldCache, uniqueCache, outerCache,\n\t\t\t\tnewCache = [ dirruns, doneName ];\n\n\t\t\t// We can't set arbitrary data on XML nodes, so they don't benefit from combinator caching\n\t\t\tif ( xml ) {\n\t\t\t\twhile ( (elem = elem[ dir ]) ) {\n\t\t\t\t\tif ( elem.nodeType === 1 || checkNonElements ) {\n\t\t\t\t\t\tif ( matcher( elem, context, xml ) ) {\n\t\t\t\t\t\t\treturn true;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\twhile ( (elem = elem[ dir ]) ) {\n\t\t\t\t\tif ( elem.nodeType === 1 || checkNonElements ) {\n\t\t\t\t\t\touterCache = elem[ expando ] || (elem[ expando ] = {});\n\n\t\t\t\t\t\t// Support: IE <9 only\n\t\t\t\t\t\t// Defend against cloned attroperties (jQuery gh-1709)\n\t\t\t\t\t\tuniqueCache = outerCache[ elem.uniqueID ] || (outerCache[ elem.uniqueID ] = {});\n\n\t\t\t\t\t\tif ( skip && skip === elem.nodeName.toLowerCase() ) {\n\t\t\t\t\t\t\telem = elem[ dir ] || elem;\n\t\t\t\t\t\t} else if ( (oldCache = uniqueCache[ key ]) &&\n\t\t\t\t\t\t\toldCache[ 0 ] === dirruns && oldCache[ 1 ] === doneName ) {\n\n\t\t\t\t\t\t\t// Assign to newCache so results back-propagate to previous elements\n\t\t\t\t\t\t\treturn (newCache[ 2 ] = oldCache[ 2 ]);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// Reuse newcache so results back-propagate to previous elements\n\t\t\t\t\t\t\tuniqueCache[ key ] = newCache;\n\n\t\t\t\t\t\t\t// A match means we're done; a fail means we have to keep checking\n\t\t\t\t\t\t\tif ( (newCache[ 2 ] = matcher( elem, context, xml )) ) {\n\t\t\t\t\t\t\t\treturn true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn false;\n\t\t};\n}\n\nfunction elementMatcher( matchers ) {\n\treturn matchers.length > 1 ?\n\t\tfunction( elem, context, xml ) {\n\t\t\tvar i = matchers.length;\n\t\t\twhile ( i-- ) {\n\t\t\t\tif ( !matchers[i]( elem, context, xml ) ) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn true;\n\t\t} :\n\t\tmatchers[0];\n}\n\nfunction multipleContexts( selector, contexts, results ) {\n\tvar i = 0,\n\t\tlen = contexts.length;\n\tfor ( ; i < len; i++ ) {\n\t\tSizzle( selector, contexts[i], results );\n\t}\n\treturn results;\n}\n\nfunction condense( unmatched, map, filter, context, xml ) {\n\tvar elem,\n\t\tnewUnmatched = [],\n\t\ti = 0,\n\t\tlen = unmatched.length,\n\t\tmapped = map != null;\n\n\tfor ( ; i < len; i++ ) {\n\t\tif ( (elem = unmatched[i]) ) {\n\t\t\tif ( !filter || filter( elem, context, xml ) ) {\n\t\t\t\tnewUnmatched.push( elem );\n\t\t\t\tif ( mapped ) {\n\t\t\t\t\tmap.push( i );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn newUnmatched;\n}\n\nfunction setMatcher( preFilter, selector, matcher, postFilter, postFinder, postSelector ) {\n\tif ( postFilter && !postFilter[ expando ] ) {\n\t\tpostFilter = setMatcher( postFilter );\n\t}\n\tif ( postFinder && !postFinder[ expando ] ) {\n\t\tpostFinder = setMatcher( postFinder, postSelector );\n\t}\n\treturn markFunction(function( seed, results, context, xml ) {\n\t\tvar temp, i, elem,\n\t\t\tpreMap = [],\n\t\t\tpostMap = [],\n\t\t\tpreexisting = results.length,\n\n\t\t\t// Get initial elements from seed or context\n\t\t\telems = seed || multipleContexts( selector || \"*\", context.nodeType ? [ context ] : context, [] ),\n\n\t\t\t// Prefilter to get matcher input, preserving a map for seed-results synchronization\n\t\t\tmatcherIn = preFilter && ( seed || !selector ) ?\n\t\t\t\tcondense( elems, preMap, preFilter, context, xml ) :\n\t\t\t\telems,\n\n\t\t\tmatcherOut = matcher ?\n\t\t\t\t// If we have a postFinder, or filtered seed, or non-seed postFilter or preexisting results,\n\t\t\t\tpostFinder || ( seed ? preFilter : preexisting || postFilter ) ?\n\n\t\t\t\t\t// ...intermediate processing is necessary\n\t\t\t\t\t[] :\n\n\t\t\t\t\t// ...otherwise use results directly\n\t\t\t\t\tresults :\n\t\t\t\tmatcherIn;\n\n\t\t// Find primary matches\n\t\tif ( matcher ) {\n\t\t\tmatcher( matcherIn, matcherOut, context, xml );\n\t\t}\n\n\t\t// Apply postFilter\n\t\tif ( postFilter ) {\n\t\t\ttemp = condense( matcherOut, postMap );\n\t\t\tpostFilter( temp, [], context, xml );\n\n\t\t\t// Un-match failing elements by moving them back to matcherIn\n\t\t\ti = temp.length;\n\t\t\twhile ( i-- ) {\n\t\t\t\tif ( (elem = temp[i]) ) {\n\t\t\t\t\tmatcherOut[ postMap[i] ] = !(matcherIn[ postMap[i] ] = elem);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif ( seed ) {\n\t\t\tif ( postFinder || preFilter ) {\n\t\t\t\tif ( postFinder ) {\n\t\t\t\t\t// Get the final matcherOut by condensing this intermediate into postFinder contexts\n\t\t\t\t\ttemp = [];\n\t\t\t\t\ti = matcherOut.length;\n\t\t\t\t\twhile ( i-- ) {\n\t\t\t\t\t\tif ( (elem = matcherOut[i]) ) {\n\t\t\t\t\t\t\t// Restore matcherIn since elem is not yet a final match\n\t\t\t\t\t\t\ttemp.push( (matcherIn[i] = elem) );\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tpostFinder( null, (matcherOut = []), temp, xml );\n\t\t\t\t}\n\n\t\t\t\t// Move matched elements from seed to results to keep them synchronized\n\t\t\t\ti = matcherOut.length;\n\t\t\t\twhile ( i-- ) {\n\t\t\t\t\tif ( (elem = matcherOut[i]) &&\n\t\t\t\t\t\t(temp = postFinder ? indexOf( seed, elem ) : preMap[i]) > -1 ) {\n\n\t\t\t\t\t\tseed[temp] = !(results[temp] = elem);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t// Add elements to results, through postFinder if defined\n\t\t} else {\n\t\t\tmatcherOut = condense(\n\t\t\t\tmatcherOut === results ?\n\t\t\t\t\tmatcherOut.splice( preexisting, matcherOut.length ) :\n\t\t\t\t\tmatcherOut\n\t\t\t);\n\t\t\tif ( postFinder ) {\n\t\t\t\tpostFinder( null, results, matcherOut, xml );\n\t\t\t} else {\n\t\t\t\tpush.apply( results, matcherOut );\n\t\t\t}\n\t\t}\n\t});\n}\n\nfunction matcherFromTokens( tokens ) {\n\tvar checkContext, matcher, j,\n\t\tlen = tokens.length,\n\t\tleadingRelative = Expr.relative[ tokens[0].type ],\n\t\timplicitRelative = leadingRelative || Expr.relative[\" \"],\n\t\ti = leadingRelative ? 1 : 0,\n\n\t\t// The foundational matcher ensures that elements are reachable from top-level context(s)\n\t\tmatchContext = addCombinator( function( elem ) {\n\t\t\treturn elem === checkContext;\n\t\t}, implicitRelative, true ),\n\t\tmatchAnyContext = addCombinator( function( elem ) {\n\t\t\treturn indexOf( checkContext, elem ) > -1;\n\t\t}, implicitRelative, true ),\n\t\tmatchers = [ function( elem, context, xml ) {\n\t\t\tvar ret = ( !leadingRelative && ( xml || context !== outermostContext ) ) || (\n\t\t\t\t(checkContext = context).nodeType ?\n\t\t\t\t\tmatchContext( elem, context, xml ) :\n\t\t\t\t\tmatchAnyContext( elem, context, xml ) );\n\t\t\t// Avoid hanging onto element (issue #299)\n\t\t\tcheckContext = null;\n\t\t\treturn ret;\n\t\t} ];\n\n\tfor ( ; i < len; i++ ) {\n\t\tif ( (matcher = Expr.relative[ tokens[i].type ]) ) {\n\t\t\tmatchers = [ addCombinator(elementMatcher( matchers ), matcher) ];\n\t\t} else {\n\t\t\tmatcher = Expr.filter[ tokens[i].type ].apply( null, tokens[i].matches );\n\n\t\t\t// Return special upon seeing a positional matcher\n\t\t\tif ( matcher[ expando ] ) {\n\t\t\t\t// Find the next relative operator (if any) for proper handling\n\t\t\t\tj = ++i;\n\t\t\t\tfor ( ; j < len; j++ ) {\n\t\t\t\t\tif ( Expr.relative[ tokens[j].type ] ) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn setMatcher(\n\t\t\t\t\ti > 1 && elementMatcher( matchers ),\n\t\t\t\t\ti > 1 && toSelector(\n\t\t\t\t\t\t// If the preceding token was a descendant combinator, insert an implicit any-element `*`\n\t\t\t\t\t\ttokens.slice( 0, i - 1 ).concat({ value: tokens[ i - 2 ].type === \" \" ? \"*\" : \"\" })\n\t\t\t\t\t).replace( rtrim, \"$1\" ),\n\t\t\t\t\tmatcher,\n\t\t\t\t\ti < j && matcherFromTokens( tokens.slice( i, j ) ),\n\t\t\t\t\tj < len && matcherFromTokens( (tokens = tokens.slice( j )) ),\n\t\t\t\t\tj < len && toSelector( tokens )\n\t\t\t\t);\n\t\t\t}\n\t\t\tmatchers.push( matcher );\n\t\t}\n\t}\n\n\treturn elementMatcher( matchers );\n}\n\nfunction matcherFromGroupMatchers( elementMatchers, setMatchers ) {\n\tvar bySet = setMatchers.length > 0,\n\t\tbyElement = elementMatchers.length > 0,\n\t\tsuperMatcher = function( seed, context, xml, results, outermost ) {\n\t\t\tvar elem, j, matcher,\n\t\t\t\tmatchedCount = 0,\n\t\t\t\ti = \"0\",\n\t\t\t\tunmatched = seed && [],\n\t\t\t\tsetMatched = [],\n\t\t\t\tcontextBackup = outermostContext,\n\t\t\t\t// We must always have either seed elements or outermost context\n\t\t\t\telems = seed || byElement && Expr.find[\"TAG\"]( \"*\", outermost ),\n\t\t\t\t// Use integer dirruns iff this is the outermost matcher\n\t\t\t\tdirrunsUnique = (dirruns += contextBackup == null ? 1 : Math.random() || 0.1),\n\t\t\t\tlen = elems.length;\n\n\t\t\tif ( outermost ) {\n\t\t\t\toutermostContext = context === document || context || outermost;\n\t\t\t}\n\n\t\t\t// Add elements passing elementMatchers directly to results\n\t\t\t// Support: IE<9, Safari\n\t\t\t// Tolerate NodeList properties (IE: \"length\"; Safari: <number>) matching elements by id\n\t\t\tfor ( ; i !== len && (elem = elems[i]) != null; i++ ) {\n\t\t\t\tif ( byElement && elem ) {\n\t\t\t\t\tj = 0;\n\t\t\t\t\tif ( !context && elem.ownerDocument !== document ) {\n\t\t\t\t\t\tsetDocument( elem );\n\t\t\t\t\t\txml = !documentIsHTML;\n\t\t\t\t\t}\n\t\t\t\t\twhile ( (matcher = elementMatchers[j++]) ) {\n\t\t\t\t\t\tif ( matcher( elem, context || document, xml) ) {\n\t\t\t\t\t\t\tresults.push( elem );\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif ( outermost ) {\n\t\t\t\t\t\tdirruns = dirrunsUnique;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Track unmatched elements for set filters\n\t\t\t\tif ( bySet ) {\n\t\t\t\t\t// They will have gone through all possible matchers\n\t\t\t\t\tif ( (elem = !matcher && elem) ) {\n\t\t\t\t\t\tmatchedCount--;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Lengthen the array for every element, matched or not\n\t\t\t\t\tif ( seed ) {\n\t\t\t\t\t\tunmatched.push( elem );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// `i` is now the count of elements visited above, and adding it to `matchedCount`\n\t\t\t// makes the latter nonnegative.\n\t\t\tmatchedCount += i;\n\n\t\t\t// Apply set filters to unmatched elements\n\t\t\t// NOTE: This can be skipped if there are no unmatched elements (i.e., `matchedCount`\n\t\t\t// equals `i`), unless we didn't visit _any_ elements in the above loop because we have\n\t\t\t// no element matchers and no seed.\n\t\t\t// Incrementing an initially-string \"0\" `i` allows `i` to remain a string only in that\n\t\t\t// case, which will result in a \"00\" `matchedCount` that differs from `i` but is also\n\t\t\t// numerically zero.\n\t\t\tif ( bySet && i !== matchedCount ) {\n\t\t\t\tj = 0;\n\t\t\t\twhile ( (matcher = setMatchers[j++]) ) {\n\t\t\t\t\tmatcher( unmatched, setMatched, context, xml );\n\t\t\t\t}\n\n\t\t\t\tif ( seed ) {\n\t\t\t\t\t// Reintegrate element matches to eliminate the need for sorting\n\t\t\t\t\tif ( matchedCount > 0 ) {\n\t\t\t\t\t\twhile ( i-- ) {\n\t\t\t\t\t\t\tif ( !(unmatched[i] || setMatched[i]) ) {\n\t\t\t\t\t\t\t\tsetMatched[i] = pop.call( results );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t// Discard index placeholder values to get only actual matches\n\t\t\t\t\tsetMatched = condense( setMatched );\n\t\t\t\t}\n\n\t\t\t\t// Add matches to results\n\t\t\t\tpush.apply( results, setMatched );\n\n\t\t\t\t// Seedless set matches succeeding multiple successful matchers stipulate sorting\n\t\t\t\tif ( outermost && !seed && setMatched.length > 0 &&\n\t\t\t\t\t( matchedCount + setMatchers.length ) > 1 ) {\n\n\t\t\t\t\tSizzle.uniqueSort( results );\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Override manipulation of globals by nested matchers\n\t\t\tif ( outermost ) {\n\t\t\t\tdirruns = dirrunsUnique;\n\t\t\t\toutermostContext = contextBackup;\n\t\t\t}\n\n\t\t\treturn unmatched;\n\t\t};\n\n\treturn bySet ?\n\t\tmarkFunction( superMatcher ) :\n\t\tsuperMatcher;\n}\n\ncompile = Sizzle.compile = function( selector, match /* Internal Use Only */ ) {\n\tvar i,\n\t\tsetMatchers = [],\n\t\telementMatchers = [],\n\t\tcached = compilerCache[ selector + \" \" ];\n\n\tif ( !cached ) {\n\t\t// Generate a function of recursive functions that can be used to check each element\n\t\tif ( !match ) {\n\t\t\tmatch = tokenize( selector );\n\t\t}\n\t\ti = match.length;\n\t\twhile ( i-- ) {\n\t\t\tcached = matcherFromTokens( match[i] );\n\t\t\tif ( cached[ expando ] ) {\n\t\t\t\tsetMatchers.push( cached );\n\t\t\t} else {\n\t\t\t\telementMatchers.push( cached );\n\t\t\t}\n\t\t}\n\n\t\t// Cache the compiled function\n\t\tcached = compilerCache( selector, matcherFromGroupMatchers( elementMatchers, setMatchers ) );\n\n\t\t// Save selector and tokenization\n\t\tcached.selector = selector;\n\t}\n\treturn cached;\n};\n\n/**\n * A low-level selection function that works with Sizzle's compiled\n *  selector functions\n * @param {String|Function} selector A selector or a pre-compiled\n *  selector function built with Sizzle.compile\n * @param {Element} context\n * @param {Array} [results]\n * @param {Array} [seed] A set of elements to match against\n */\nselect = Sizzle.select = function( selector, context, results, seed ) {\n\tvar i, tokens, token, type, find,\n\t\tcompiled = typeof selector === \"function\" && selector,\n\t\tmatch = !seed && tokenize( (selector = compiled.selector || selector) );\n\n\tresults = results || [];\n\n\t// Try to minimize operations if there is only one selector in the list and no seed\n\t// (the latter of which guarantees us context)\n\tif ( match.length === 1 ) {\n\n\t\t// Reduce context if the leading compound selector is an ID\n\t\ttokens = match[0] = match[0].slice( 0 );\n\t\tif ( tokens.length > 2 && (token = tokens[0]).type === \"ID\" &&\n\t\t\t\tcontext.nodeType === 9 && documentIsHTML && Expr.relative[ tokens[1].type ] ) {\n\n\t\t\tcontext = ( Expr.find[\"ID\"]( token.matches[0].replace(runescape, funescape), context ) || [] )[0];\n\t\t\tif ( !context ) {\n\t\t\t\treturn results;\n\n\t\t\t// Precompiled matchers will still verify ancestry, so step up a level\n\t\t\t} else if ( compiled ) {\n\t\t\t\tcontext = context.parentNode;\n\t\t\t}\n\n\t\t\tselector = selector.slice( tokens.shift().value.length );\n\t\t}\n\n\t\t// Fetch a seed set for right-to-left matching\n\t\ti = matchExpr[\"needsContext\"].test( selector ) ? 0 : tokens.length;\n\t\twhile ( i-- ) {\n\t\t\ttoken = tokens[i];\n\n\t\t\t// Abort if we hit a combinator\n\t\t\tif ( Expr.relative[ (type = token.type) ] ) {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif ( (find = Expr.find[ type ]) ) {\n\t\t\t\t// Search, expanding context for leading sibling combinators\n\t\t\t\tif ( (seed = find(\n\t\t\t\t\ttoken.matches[0].replace( runescape, funescape ),\n\t\t\t\t\trsibling.test( tokens[0].type ) && testContext( context.parentNode ) || context\n\t\t\t\t)) ) {\n\n\t\t\t\t\t// If seed is empty or no tokens remain, we can return early\n\t\t\t\t\ttokens.splice( i, 1 );\n\t\t\t\t\tselector = seed.length && toSelector( tokens );\n\t\t\t\t\tif ( !selector ) {\n\t\t\t\t\t\tpush.apply( results, seed );\n\t\t\t\t\t\treturn results;\n\t\t\t\t\t}\n\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t// Compile and execute a filtering function if one is not provided\n\t// Provide `match` to avoid retokenization if we modified the selector above\n\t( compiled || compile( selector, match ) )(\n\t\tseed,\n\t\tcontext,\n\t\t!documentIsHTML,\n\t\tresults,\n\t\t!context || rsibling.test( selector ) && testContext( context.parentNode ) || context\n\t);\n\treturn results;\n};\n\n// One-time assignments\n\n// Sort stability\nsupport.sortStable = expando.split(\"\").sort( sortOrder ).join(\"\") === expando;\n\n// Support: Chrome 14-35+\n// Always assume duplicates if they aren't passed to the comparison function\nsupport.detectDuplicates = !!hasDuplicate;\n\n// Initialize against the default document\nsetDocument();\n\n// Support: Webkit<537.32 - Safari 6.0.3/Chrome 25 (fixed in Chrome 27)\n// Detached nodes confoundingly follow *each other*\nsupport.sortDetached = assert(function( el ) {\n\t// Should return 1, but returns 4 (following)\n\treturn el.compareDocumentPosition( document.createElement(\"fieldset\") ) & 1;\n});\n\n// Support: IE<8\n// Prevent attribute/property \"interpolation\"\n// https://msdn.microsoft.com/en-us/library/ms536429%28VS.85%29.aspx\nif ( !assert(function( el ) {\n\tel.innerHTML = \"<a href='#'></a>\";\n\treturn el.firstChild.getAttribute(\"href\") === \"#\" ;\n}) ) {\n\taddHandle( \"type|href|height|width\", function( elem, name, isXML ) {\n\t\tif ( !isXML ) {\n\t\t\treturn elem.getAttribute( name, name.toLowerCase() === \"type\" ? 1 : 2 );\n\t\t}\n\t});\n}\n\n// Support: IE<9\n// Use defaultValue in place of getAttribute(\"value\")\nif ( !support.attributes || !assert(function( el ) {\n\tel.innerHTML = \"<input/>\";\n\tel.firstChild.setAttribute( \"value\", \"\" );\n\treturn el.firstChild.getAttribute( \"value\" ) === \"\";\n}) ) {\n\taddHandle( \"value\", function( elem, name, isXML ) {\n\t\tif ( !isXML && elem.nodeName.toLowerCase() === \"input\" ) {\n\t\t\treturn elem.defaultValue;\n\t\t}\n\t});\n}\n\n// Support: IE<9\n// Use getAttributeNode to fetch booleans when getAttribute lies\nif ( !assert(function( el ) {\n\treturn el.getAttribute(\"disabled\") == null;\n}) ) {\n\taddHandle( booleans, function( elem, name, isXML ) {\n\t\tvar val;\n\t\tif ( !isXML ) {\n\t\t\treturn elem[ name ] === true ? name.toLowerCase() :\n\t\t\t\t\t(val = elem.getAttributeNode( name )) && val.specified ?\n\t\t\t\t\tval.value :\n\t\t\t\tnull;\n\t\t}\n\t});\n}\n\nreturn Sizzle;\n\n})( window );\n\n\n\njQuery.find = Sizzle;\njQuery.expr = Sizzle.selectors;\n\n// Deprecated\njQuery.expr[ \":\" ] = jQuery.expr.pseudos;\njQuery.uniqueSort = jQuery.unique = Sizzle.uniqueSort;\njQuery.text = Sizzle.getText;\njQuery.isXMLDoc = Sizzle.isXML;\njQuery.contains = Sizzle.contains;\njQuery.escapeSelector = Sizzle.escape;\n\n\n\n\nvar dir = function( elem, dir, until ) {\n\tvar matched = [],\n\t\ttruncate = until !== undefined;\n\n\twhile ( ( elem = elem[ dir ] ) && elem.nodeType !== 9 ) {\n\t\tif ( elem.nodeType === 1 ) {\n\t\t\tif ( truncate && jQuery( elem ).is( until ) ) {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tmatched.push( elem );\n\t\t}\n\t}\n\treturn matched;\n};\n\n\nvar siblings = function( n, elem ) {\n\tvar matched = [];\n\n\tfor ( ; n; n = n.nextSibling ) {\n\t\tif ( n.nodeType === 1 && n !== elem ) {\n\t\t\tmatched.push( n );\n\t\t}\n\t}\n\n\treturn matched;\n};\n\n\nvar rneedsContext = jQuery.expr.match.needsContext;\n\n\n\nfunction nodeName( elem, name ) {\n\n  return elem.nodeName && elem.nodeName.toLowerCase() === name.toLowerCase();\n\n};\nvar rsingleTag = ( /^<([a-z][^\\/\\0>:\\x20\\t\\r\\n\\f]*)[\\x20\\t\\r\\n\\f]*\\/?>(?:<\\/\\1>|)$/i );\n\n\n\n// Implement the identical functionality for filter and not\nfunction winnow( elements, qualifier, not ) {\n\tif ( isFunction( qualifier ) ) {\n\t\treturn jQuery.grep( elements, function( elem, i ) {\n\t\t\treturn !!qualifier.call( elem, i, elem ) !== not;\n\t\t} );\n\t}\n\n\t// Single element\n\tif ( qualifier.nodeType ) {\n\t\treturn jQuery.grep( elements, function( elem ) {\n\t\t\treturn ( elem === qualifier ) !== not;\n\t\t} );\n\t}\n\n\t// Arraylike of elements (jQuery, arguments, Array)\n\tif ( typeof qualifier !== \"string\" ) {\n\t\treturn jQuery.grep( elements, function( elem ) {\n\t\t\treturn ( indexOf.call( qualifier, elem ) > -1 ) !== not;\n\t\t} );\n\t}\n\n\t// Filtered directly for both simple and complex selectors\n\treturn jQuery.filter( qualifier, elements, not );\n}\n\njQuery.filter = function( expr, elems, not ) {\n\tvar elem = elems[ 0 ];\n\n\tif ( not ) {\n\t\texpr = \":not(\" + expr + \")\";\n\t}\n\n\tif ( elems.length === 1 && elem.nodeType === 1 ) {\n\t\treturn jQuery.find.matchesSelector( elem, expr ) ? [ elem ] : [];\n\t}\n\n\treturn jQuery.find.matches( expr, jQuery.grep( elems, function( elem ) {\n\t\treturn elem.nodeType === 1;\n\t} ) );\n};\n\njQuery.fn.extend( {\n\tfind: function( selector ) {\n\t\tvar i, ret,\n\t\t\tlen = this.length,\n\t\t\tself = this;\n\n\t\tif ( typeof selector !== \"string\" ) {\n\t\t\treturn this.pushStack( jQuery( selector ).filter( function() {\n\t\t\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\t\t\tif ( jQuery.contains( self[ i ], this ) ) {\n\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} ) );\n\t\t}\n\n\t\tret = this.pushStack( [] );\n\n\t\tfor ( i = 0; i < len; i++ ) {\n\t\t\tjQuery.find( selector, self[ i ], ret );\n\t\t}\n\n\t\treturn len > 1 ? jQuery.uniqueSort( ret ) : ret;\n\t},\n\tfilter: function( selector ) {\n\t\treturn this.pushStack( winnow( this, selector || [], false ) );\n\t},\n\tnot: function( selector ) {\n\t\treturn this.pushStack( winnow( this, selector || [], true ) );\n\t},\n\tis: function( selector ) {\n\t\treturn !!winnow(\n\t\t\tthis,\n\n\t\t\t// If this is a positional/relative selector, check membership in the returned set\n\t\t\t// so $(\"p:first\").is(\"p:last\") won't return true for a doc with two \"p\".\n\t\t\ttypeof selector === \"string\" && rneedsContext.test( selector ) ?\n\t\t\t\tjQuery( selector ) :\n\t\t\t\tselector || [],\n\t\t\tfalse\n\t\t).length;\n\t}\n} );\n\n\n// Initialize a jQuery object\n\n\n// A central reference to the root jQuery(document)\nvar rootjQuery,\n\n\t// A simple way to check for HTML strings\n\t// Prioritize #id over <tag> to avoid XSS via location.hash (#9521)\n\t// Strict HTML recognition (#11290: must start with <)\n\t// Shortcut simple #id case for speed\n\trquickExpr = /^(?:\\s*(<[\\w\\W]+>)[^>]*|#([\\w-]+))$/,\n\n\tinit = jQuery.fn.init = function( selector, context, root ) {\n\t\tvar match, elem;\n\n\t\t// HANDLE: $(\"\"), $(null), $(undefined), $(false)\n\t\tif ( !selector ) {\n\t\t\treturn this;\n\t\t}\n\n\t\t// Method init() accepts an alternate rootjQuery\n\t\t// so migrate can support jQuery.sub (gh-2101)\n\t\troot = root || rootjQuery;\n\n\t\t// Handle HTML strings\n\t\tif ( typeof selector === \"string\" ) {\n\t\t\tif ( selector[ 0 ] === \"<\" &&\n\t\t\t\tselector[ selector.length - 1 ] === \">\" &&\n\t\t\t\tselector.length >= 3 ) {\n\n\t\t\t\t// Assume that strings that start and end with <> are HTML and skip the regex check\n\t\t\t\tmatch = [ null, selector, null ];\n\n\t\t\t} else {\n\t\t\t\tmatch = rquickExpr.exec( selector );\n\t\t\t}\n\n\t\t\t// Match html or make sure no context is specified for #id\n\t\t\tif ( match && ( match[ 1 ] || !context ) ) {\n\n\t\t\t\t// HANDLE: $(html) -> $(array)\n\t\t\t\tif ( match[ 1 ] ) {\n\t\t\t\t\tcontext = context instanceof jQuery ? context[ 0 ] : context;\n\n\t\t\t\t\t// Option to run scripts is true for back-compat\n\t\t\t\t\t// Intentionally let the error be thrown if parseHTML is not present\n\t\t\t\t\tjQuery.merge( this, jQuery.parseHTML(\n\t\t\t\t\t\tmatch[ 1 ],\n\t\t\t\t\t\tcontext && context.nodeType ? context.ownerDocument || context : document,\n\t\t\t\t\t\ttrue\n\t\t\t\t\t) );\n\n\t\t\t\t\t// HANDLE: $(html, props)\n\t\t\t\t\tif ( rsingleTag.test( match[ 1 ] ) && jQuery.isPlainObject( context ) ) {\n\t\t\t\t\t\tfor ( match in context ) {\n\n\t\t\t\t\t\t\t// Properties of context are called as methods if possible\n\t\t\t\t\t\t\tif ( isFunction( this[ match ] ) ) {\n\t\t\t\t\t\t\t\tthis[ match ]( context[ match ] );\n\n\t\t\t\t\t\t\t// ...and otherwise set as attributes\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tthis.attr( match, context[ match ] );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\treturn this;\n\n\t\t\t\t// HANDLE: $(#id)\n\t\t\t\t} else {\n\t\t\t\t\telem = document.getElementById( match[ 2 ] );\n\n\t\t\t\t\tif ( elem ) {\n\n\t\t\t\t\t\t// Inject the element directly into the jQuery object\n\t\t\t\t\t\tthis[ 0 ] = elem;\n\t\t\t\t\t\tthis.length = 1;\n\t\t\t\t\t}\n\t\t\t\t\treturn this;\n\t\t\t\t}\n\n\t\t\t// HANDLE: $(expr, $(...))\n\t\t\t} else if ( !context || context.jquery ) {\n\t\t\t\treturn ( context || root ).find( selector );\n\n\t\t\t// HANDLE: $(expr, context)\n\t\t\t// (which is just equivalent to: $(context).find(expr)\n\t\t\t} else {\n\t\t\t\treturn this.constructor( context ).find( selector );\n\t\t\t}\n\n\t\t// HANDLE: $(DOMElement)\n\t\t} else if ( selector.nodeType ) {\n\t\t\tthis[ 0 ] = selector;\n\t\t\tthis.length = 1;\n\t\t\treturn this;\n\n\t\t// HANDLE: $(function)\n\t\t// Shortcut for document ready\n\t\t} else if ( isFunction( selector ) ) {\n\t\t\treturn root.ready !== undefined ?\n\t\t\t\troot.ready( selector ) :\n\n\t\t\t\t// Execute immediately if ready is not present\n\t\t\t\tselector( jQuery );\n\t\t}\n\n\t\treturn jQuery.makeArray( selector, this );\n\t};\n\n// Give the init function the jQuery prototype for later instantiation\ninit.prototype = jQuery.fn;\n\n// Initialize central reference\nrootjQuery = jQuery( document );\n\n\nvar rparentsprev = /^(?:parents|prev(?:Until|All))/,\n\n\t// Methods guaranteed to produce a unique set when starting from a unique set\n\tguaranteedUnique = {\n\t\tchildren: true,\n\t\tcontents: true,\n\t\tnext: true,\n\t\tprev: true\n\t};\n\njQuery.fn.extend( {\n\thas: function( target ) {\n\t\tvar targets = jQuery( target, this ),\n\t\t\tl = targets.length;\n\n\t\treturn this.filter( function() {\n\t\t\tvar i = 0;\n\t\t\tfor ( ; i < l; i++ ) {\n\t\t\t\tif ( jQuery.contains( this, targets[ i ] ) ) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t}\n\t\t} );\n\t},\n\n\tclosest: function( selectors, context ) {\n\t\tvar cur,\n\t\t\ti = 0,\n\t\t\tl = this.length,\n\t\t\tmatched = [],\n\t\t\ttargets = typeof selectors !== \"string\" && jQuery( selectors );\n\n\t\t// Positional selectors never match, since there's no _selection_ context\n\t\tif ( !rneedsContext.test( selectors ) ) {\n\t\t\tfor ( ; i < l; i++ ) {\n\t\t\t\tfor ( cur = this[ i ]; cur && cur !== context; cur = cur.parentNode ) {\n\n\t\t\t\t\t// Always skip document fragments\n\t\t\t\t\tif ( cur.nodeType < 11 && ( targets ?\n\t\t\t\t\t\ttargets.index( cur ) > -1 :\n\n\t\t\t\t\t\t// Don't pass non-elements to Sizzle\n\t\t\t\t\t\tcur.nodeType === 1 &&\n\t\t\t\t\t\t\tjQuery.find.matchesSelector( cur, selectors ) ) ) {\n\n\t\t\t\t\t\tmatched.push( cur );\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn this.pushStack( matched.length > 1 ? jQuery.uniqueSort( matched ) : matched );\n\t},\n\n\t// Determine the position of an element within the set\n\tindex: function( elem ) {\n\n\t\t// No argument, return index in parent\n\t\tif ( !elem ) {\n\t\t\treturn ( this[ 0 ] && this[ 0 ].parentNode ) ? this.first().prevAll().length : -1;\n\t\t}\n\n\t\t// Index in selector\n\t\tif ( typeof elem === \"string\" ) {\n\t\t\treturn indexOf.call( jQuery( elem ), this[ 0 ] );\n\t\t}\n\n\t\t// Locate the position of the desired element\n\t\treturn indexOf.call( this,\n\n\t\t\t// If it receives a jQuery object, the first element is used\n\t\t\telem.jquery ? elem[ 0 ] : elem\n\t\t);\n\t},\n\n\tadd: function( selector, context ) {\n\t\treturn this.pushStack(\n\t\t\tjQuery.uniqueSort(\n\t\t\t\tjQuery.merge( this.get(), jQuery( selector, context ) )\n\t\t\t)\n\t\t);\n\t},\n\n\taddBack: function( selector ) {\n\t\treturn this.add( selector == null ?\n\t\t\tthis.prevObject : this.prevObject.filter( selector )\n\t\t);\n\t}\n} );\n\nfunction sibling( cur, dir ) {\n\twhile ( ( cur = cur[ dir ] ) && cur.nodeType !== 1 ) {}\n\treturn cur;\n}\n\njQuery.each( {\n\tparent: function( elem ) {\n\t\tvar parent = elem.parentNode;\n\t\treturn parent && parent.nodeType !== 11 ? parent : null;\n\t},\n\tparents: function( elem ) {\n\t\treturn dir( elem, \"parentNode\" );\n\t},\n\tparentsUntil: function( elem, i, until ) {\n\t\treturn dir( elem, \"parentNode\", until );\n\t},\n\tnext: function( elem ) {\n\t\treturn sibling( elem, \"nextSibling\" );\n\t},\n\tprev: function( elem ) {\n\t\treturn sibling( elem, \"previousSibling\" );\n\t},\n\tnextAll: function( elem ) {\n\t\treturn dir( elem, \"nextSibling\" );\n\t},\n\tprevAll: function( elem ) {\n\t\treturn dir( elem, \"previousSibling\" );\n\t},\n\tnextUntil: function( elem, i, until ) {\n\t\treturn dir( elem, \"nextSibling\", until );\n\t},\n\tprevUntil: function( elem, i, until ) {\n\t\treturn dir( elem, \"previousSibling\", until );\n\t},\n\tsiblings: function( elem ) {\n\t\treturn siblings( ( elem.parentNode || {} ).firstChild, elem );\n\t},\n\tchildren: function( elem ) {\n\t\treturn siblings( elem.firstChild );\n\t},\n\tcontents: function( elem ) {\n\t\tif ( typeof elem.contentDocument !== \"undefined\" ) {\n\t\t\treturn elem.contentDocument;\n\t\t}\n\n\t\t// Support: IE 9 - 11 only, iOS 7 only, Android Browser <=4.3 only\n\t\t// Treat the template element as a regular one in browsers that\n\t\t// don't support it.\n\t\tif ( nodeName( elem, \"template\" ) ) {\n\t\t\telem = elem.content || elem;\n\t\t}\n\n\t\treturn jQuery.merge( [], elem.childNodes );\n\t}\n}, function( name, fn ) {\n\tjQuery.fn[ name ] = function( until, selector ) {\n\t\tvar matched = jQuery.map( this, fn, until );\n\n\t\tif ( name.slice( -5 ) !== \"Until\" ) {\n\t\t\tselector = until;\n\t\t}\n\n\t\tif ( selector && typeof selector === \"string\" ) {\n\t\t\tmatched = jQuery.filter( selector, matched );\n\t\t}\n\n\t\tif ( this.length > 1 ) {\n\n\t\t\t// Remove duplicates\n\t\t\tif ( !guaranteedUnique[ name ] ) {\n\t\t\t\tjQuery.uniqueSort( matched );\n\t\t\t}\n\n\t\t\t// Reverse order for parents* and prev-derivatives\n\t\t\tif ( rparentsprev.test( name ) ) {\n\t\t\t\tmatched.reverse();\n\t\t\t}\n\t\t}\n\n\t\treturn this.pushStack( matched );\n\t};\n} );\nvar rnothtmlwhite = ( /[^\\x20\\t\\r\\n\\f]+/g );\n\n\n\n// Convert String-formatted options into Object-formatted ones\nfunction createOptions( options ) {\n\tvar object = {};\n\tjQuery.each( options.match( rnothtmlwhite ) || [], function( _, flag ) {\n\t\tobject[ flag ] = true;\n\t} );\n\treturn object;\n}\n\n/*\n * Create a callback list using the following parameters:\n *\n *\toptions: an optional list of space-separated options that will change how\n *\t\t\tthe callback list behaves or a more traditional option object\n *\n * By default a callback list will act like an event callback list and can be\n * \"fired\" multiple times.\n *\n * Possible options:\n *\n *\tonce:\t\t\twill ensure the callback list can only be fired once (like a Deferred)\n *\n *\tmemory:\t\t\twill keep track of previous values and will call any callback added\n *\t\t\t\t\tafter the list has been fired right away with the latest \"memorized\"\n *\t\t\t\t\tvalues (like a Deferred)\n *\n *\tunique:\t\t\twill ensure a callback can only be added once (no duplicate in the list)\n *\n *\tstopOnFalse:\tinterrupt callings when a callback returns false\n *\n */\njQuery.Callbacks = function( options ) {\n\n\t// Convert options from String-formatted to Object-formatted if needed\n\t// (we check in cache first)\n\toptions = typeof options === \"string\" ?\n\t\tcreateOptions( options ) :\n\t\tjQuery.extend( {}, options );\n\n\tvar // Flag to know if list is currently firing\n\t\tfiring,\n\n\t\t// Last fire value for non-forgettable lists\n\t\tmemory,\n\n\t\t// Flag to know if list was already fired\n\t\tfired,\n\n\t\t// Flag to prevent firing\n\t\tlocked,\n\n\t\t// Actual callback list\n\t\tlist = [],\n\n\t\t// Queue of execution data for repeatable lists\n\t\tqueue = [],\n\n\t\t// Index of currently firing callback (modified by add/remove as needed)\n\t\tfiringIndex = -1,\n\n\t\t// Fire callbacks\n\t\tfire = function() {\n\n\t\t\t// Enforce single-firing\n\t\t\tlocked = locked || options.once;\n\n\t\t\t// Execute callbacks for all pending executions,\n\t\t\t// respecting firingIndex overrides and runtime changes\n\t\t\tfired = firing = true;\n\t\t\tfor ( ; queue.length; firingIndex = -1 ) {\n\t\t\t\tmemory = queue.shift();\n\t\t\t\twhile ( ++firingIndex < list.length ) {\n\n\t\t\t\t\t// Run callback and check for early termination\n\t\t\t\t\tif ( list[ firingIndex ].apply( memory[ 0 ], memory[ 1 ] ) === false &&\n\t\t\t\t\t\toptions.stopOnFalse ) {\n\n\t\t\t\t\t\t// Jump to end and forget the data so .add doesn't re-fire\n\t\t\t\t\t\tfiringIndex = list.length;\n\t\t\t\t\t\tmemory = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Forget the data if we're done with it\n\t\t\tif ( !options.memory ) {\n\t\t\t\tmemory = false;\n\t\t\t}\n\n\t\t\tfiring = false;\n\n\t\t\t// Clean up if we're done firing for good\n\t\t\tif ( locked ) {\n\n\t\t\t\t// Keep an empty list if we have data for future add calls\n\t\t\t\tif ( memory ) {\n\t\t\t\t\tlist = [];\n\n\t\t\t\t// Otherwise, this object is spent\n\t\t\t\t} else {\n\t\t\t\t\tlist = \"\";\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\n\t\t// Actual Callbacks object\n\t\tself = {\n\n\t\t\t// Add a callback or a collection of callbacks to the list\n\t\t\tadd: function() {\n\t\t\t\tif ( list ) {\n\n\t\t\t\t\t// If we have memory from a past run, we should fire after adding\n\t\t\t\t\tif ( memory && !firing ) {\n\t\t\t\t\t\tfiringIndex = list.length - 1;\n\t\t\t\t\t\tqueue.push( memory );\n\t\t\t\t\t}\n\n\t\t\t\t\t( function add( args ) {\n\t\t\t\t\t\tjQuery.each( args, function( _, arg ) {\n\t\t\t\t\t\t\tif ( isFunction( arg ) ) {\n\t\t\t\t\t\t\t\tif ( !options.unique || !self.has( arg ) ) {\n\t\t\t\t\t\t\t\t\tlist.push( arg );\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} else if ( arg && arg.length && toType( arg ) !== \"string\" ) {\n\n\t\t\t\t\t\t\t\t// Inspect recursively\n\t\t\t\t\t\t\t\tadd( arg );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} );\n\t\t\t\t\t} )( arguments );\n\n\t\t\t\t\tif ( memory && !firing ) {\n\t\t\t\t\t\tfire();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn this;\n\t\t\t},\n\n\t\t\t// Remove a callback from the list\n\t\t\tremove: function() {\n\t\t\t\tjQuery.each( arguments, function( _, arg ) {\n\t\t\t\t\tvar index;\n\t\t\t\t\twhile ( ( index = jQuery.inArray( arg, list, index ) ) > -1 ) {\n\t\t\t\t\t\tlist.splice( index, 1 );\n\n\t\t\t\t\t\t// Handle firing indexes\n\t\t\t\t\t\tif ( index <= firingIndex ) {\n\t\t\t\t\t\t\tfiringIndex--;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} );\n\t\t\t\treturn this;\n\t\t\t},\n\n\t\t\t// Check if a given callback is in the list.\n\t\t\t// If no argument is given, return whether or not list has callbacks attached.\n\t\t\thas: function( fn ) {\n\t\t\t\treturn fn ?\n\t\t\t\t\tjQuery.inArray( fn, list ) > -1 :\n\t\t\t\t\tlist.length > 0;\n\t\t\t},\n\n\t\t\t// Remove all callbacks from the list\n\t\t\tempty: function() {\n\t\t\t\tif ( list ) {\n\t\t\t\t\tlist = [];\n\t\t\t\t}\n\t\t\t\treturn this;\n\t\t\t},\n\n\t\t\t// Disable .fire and .add\n\t\t\t// Abort any current/pending executions\n\t\t\t// Clear all callbacks and values\n\t\t\tdisable: function() {\n\t\t\t\tlocked = queue = [];\n\t\t\t\tlist = memory = \"\";\n\t\t\t\treturn this;\n\t\t\t},\n\t\t\tdisabled: function() {\n\t\t\t\treturn !list;\n\t\t\t},\n\n\t\t\t// Disable .fire\n\t\t\t// Also disable .add unless we have memory (since it would have no effect)\n\t\t\t// Abort any pending executions\n\t\t\tlock: function() {\n\t\t\t\tlocked = queue = [];\n\t\t\t\tif ( !memory && !firing ) {\n\t\t\t\t\tlist = memory = \"\";\n\t\t\t\t}\n\t\t\t\treturn this;\n\t\t\t},\n\t\t\tlocked: function() {\n\t\t\t\treturn !!locked;\n\t\t\t},\n\n\t\t\t// Call all callbacks with the given context and arguments\n\t\t\tfireWith: function( context, args ) {\n\t\t\t\tif ( !locked ) {\n\t\t\t\t\targs = args || [];\n\t\t\t\t\targs = [ context, args.slice ? args.slice() : args ];\n\t\t\t\t\tqueue.push( args );\n\t\t\t\t\tif ( !firing ) {\n\t\t\t\t\t\tfire();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn this;\n\t\t\t},\n\n\t\t\t// Call all the callbacks with the given arguments\n\t\t\tfire: function() {\n\t\t\t\tself.fireWith( this, arguments );\n\t\t\t\treturn this;\n\t\t\t},\n\n\t\t\t// To know if the callbacks have already been called at least once\n\t\t\tfired: function() {\n\t\t\t\treturn !!fired;\n\t\t\t}\n\t\t};\n\n\treturn self;\n};\n\n\nfunction Identity( v ) {\n\treturn v;\n}\nfunction Thrower( ex ) {\n\tthrow ex;\n}\n\nfunction adoptValue( value, resolve, reject, noValue ) {\n\tvar method;\n\n\ttry {\n\n\t\t// Check for promise aspect first to privilege synchronous behavior\n\t\tif ( value && isFunction( ( method = value.promise ) ) ) {\n\t\t\tmethod.call( value ).done( resolve ).fail( reject );\n\n\t\t// Other thenables\n\t\t} else if ( value && isFunction( ( method = value.then ) ) ) {\n\t\t\tmethod.call( value, resolve, reject );\n\n\t\t// Other non-thenables\n\t\t} else {\n\n\t\t\t// Control `resolve` arguments by letting Array#slice cast boolean `noValue` to integer:\n\t\t\t// * false: [ value ].slice( 0 ) => resolve( value )\n\t\t\t// * true: [ value ].slice( 1 ) => resolve()\n\t\t\tresolve.apply( undefined, [ value ].slice( noValue ) );\n\t\t}\n\n\t// For Promises/A+, convert exceptions into rejections\n\t// Since jQuery.when doesn't unwrap thenables, we can skip the extra checks appearing in\n\t// Deferred#then to conditionally suppress rejection.\n\t} catch ( value ) {\n\n\t\t// Support: Android 4.0 only\n\t\t// Strict mode functions invoked without .call/.apply get global-object context\n\t\treject.apply( undefined, [ value ] );\n\t}\n}\n\njQuery.extend( {\n\n\tDeferred: function( func ) {\n\t\tvar tuples = [\n\n\t\t\t\t// action, add listener, callbacks,\n\t\t\t\t// ... .then handlers, argument index, [final state]\n\t\t\t\t[ \"notify\", \"progress\", jQuery.Callbacks( \"memory\" ),\n\t\t\t\t\tjQuery.Callbacks( \"memory\" ), 2 ],\n\t\t\t\t[ \"resolve\", \"done\", jQuery.Callbacks( \"once memory\" ),\n\t\t\t\t\tjQuery.Callbacks( \"once memory\" ), 0, \"resolved\" ],\n\t\t\t\t[ \"reject\", \"fail\", jQuery.Callbacks( \"once memory\" ),\n\t\t\t\t\tjQuery.Callbacks( \"once memory\" ), 1, \"rejected\" ]\n\t\t\t],\n\t\t\tstate = \"pending\",\n\t\t\tpromise = {\n\t\t\t\tstate: function() {\n\t\t\t\t\treturn state;\n\t\t\t\t},\n\t\t\t\talways: function() {\n\t\t\t\t\tdeferred.done( arguments ).fail( arguments );\n\t\t\t\t\treturn this;\n\t\t\t\t},\n\t\t\t\t\"catch\": function( fn ) {\n\t\t\t\t\treturn promise.then( null, fn );\n\t\t\t\t},\n\n\t\t\t\t// Keep pipe for back-compat\n\t\t\t\tpipe: function( /* fnDone, fnFail, fnProgress */ ) {\n\t\t\t\t\tvar fns = arguments;\n\n\t\t\t\t\treturn jQuery.Deferred( function( newDefer ) {\n\t\t\t\t\t\tjQuery.each( tuples, function( i, tuple ) {\n\n\t\t\t\t\t\t\t// Map tuples (progress, done, fail) to arguments (done, fail, progress)\n\t\t\t\t\t\t\tvar fn = isFunction( fns[ tuple[ 4 ] ] ) && fns[ tuple[ 4 ] ];\n\n\t\t\t\t\t\t\t// deferred.progress(function() { bind to newDefer or newDefer.notify })\n\t\t\t\t\t\t\t// deferred.done(function() { bind to newDefer or newDefer.resolve })\n\t\t\t\t\t\t\t// deferred.fail(function() { bind to newDefer or newDefer.reject })\n\t\t\t\t\t\t\tdeferred[ tuple[ 1 ] ]( function() {\n\t\t\t\t\t\t\t\tvar returned = fn && fn.apply( this, arguments );\n\t\t\t\t\t\t\t\tif ( returned && isFunction( returned.promise ) ) {\n\t\t\t\t\t\t\t\t\treturned.promise()\n\t\t\t\t\t\t\t\t\t\t.progress( newDefer.notify )\n\t\t\t\t\t\t\t\t\t\t.done( newDefer.resolve )\n\t\t\t\t\t\t\t\t\t\t.fail( newDefer.reject );\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tnewDefer[ tuple[ 0 ] + \"With\" ](\n\t\t\t\t\t\t\t\t\t\tthis,\n\t\t\t\t\t\t\t\t\t\tfn ? [ returned ] : arguments\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} );\n\t\t\t\t\t\t} );\n\t\t\t\t\t\tfns = null;\n\t\t\t\t\t} ).promise();\n\t\t\t\t},\n\t\t\t\tthen: function( onFulfilled, onRejected, onProgress ) {\n\t\t\t\t\tvar maxDepth = 0;\n\t\t\t\t\tfunction resolve( depth, deferred, handler, special ) {\n\t\t\t\t\t\treturn function() {\n\t\t\t\t\t\t\tvar that = this,\n\t\t\t\t\t\t\t\targs = arguments,\n\t\t\t\t\t\t\t\tmightThrow = function() {\n\t\t\t\t\t\t\t\t\tvar returned, then;\n\n\t\t\t\t\t\t\t\t\t// Support: Promises/A+ section 2.3.3.3.3\n\t\t\t\t\t\t\t\t\t// https://promisesaplus.com/#point-59\n\t\t\t\t\t\t\t\t\t// Ignore double-resolution attempts\n\t\t\t\t\t\t\t\t\tif ( depth < maxDepth ) {\n\t\t\t\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\treturned = handler.apply( that, args );\n\n\t\t\t\t\t\t\t\t\t// Support: Promises/A+ section 2.3.1\n\t\t\t\t\t\t\t\t\t// https://promisesaplus.com/#point-48\n\t\t\t\t\t\t\t\t\tif ( returned === deferred.promise() ) {\n\t\t\t\t\t\t\t\t\t\tthrow new TypeError( \"Thenable self-resolution\" );\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t// Support: Promises/A+ sections 2.3.3.1, 3.5\n\t\t\t\t\t\t\t\t\t// https://promisesaplus.com/#point-54\n\t\t\t\t\t\t\t\t\t// https://promisesaplus.com/#point-75\n\t\t\t\t\t\t\t\t\t// Retrieve `then` only once\n\t\t\t\t\t\t\t\t\tthen = returned &&\n\n\t\t\t\t\t\t\t\t\t\t// Support: Promises/A+ section 2.3.4\n\t\t\t\t\t\t\t\t\t\t// https://promisesaplus.com/#point-64\n\t\t\t\t\t\t\t\t\t\t// Only check objects and functions for thenability\n\t\t\t\t\t\t\t\t\t\t( typeof returned === \"object\" ||\n\t\t\t\t\t\t\t\t\t\t\ttypeof returned === \"function\" ) &&\n\t\t\t\t\t\t\t\t\t\treturned.then;\n\n\t\t\t\t\t\t\t\t\t// Handle a returned thenable\n\t\t\t\t\t\t\t\t\tif ( isFunction( then ) ) {\n\n\t\t\t\t\t\t\t\t\t\t// Special processors (notify) just wait for resolution\n\t\t\t\t\t\t\t\t\t\tif ( special ) {\n\t\t\t\t\t\t\t\t\t\t\tthen.call(\n\t\t\t\t\t\t\t\t\t\t\t\treturned,\n\t\t\t\t\t\t\t\t\t\t\t\tresolve( maxDepth, deferred, Identity, special ),\n\t\t\t\t\t\t\t\t\t\t\t\tresolve( maxDepth, deferred, Thrower, special )\n\t\t\t\t\t\t\t\t\t\t\t);\n\n\t\t\t\t\t\t\t\t\t\t// Normal processors (resolve) also hook into progress\n\t\t\t\t\t\t\t\t\t\t} else {\n\n\t\t\t\t\t\t\t\t\t\t\t// ...and disregard older resolution values\n\t\t\t\t\t\t\t\t\t\t\tmaxDepth++;\n\n\t\t\t\t\t\t\t\t\t\t\tthen.call(\n\t\t\t\t\t\t\t\t\t\t\t\treturned,\n\t\t\t\t\t\t\t\t\t\t\t\tresolve( maxDepth, deferred, Identity, special ),\n\t\t\t\t\t\t\t\t\t\t\t\tresolve( maxDepth, deferred, Thrower, special ),\n\t\t\t\t\t\t\t\t\t\t\t\tresolve( maxDepth, deferred, Identity,\n\t\t\t\t\t\t\t\t\t\t\t\t\tdeferred.notifyWith )\n\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t// Handle all other returned values\n\t\t\t\t\t\t\t\t\t} else {\n\n\t\t\t\t\t\t\t\t\t\t// Only substitute handlers pass on context\n\t\t\t\t\t\t\t\t\t\t// and multiple values (non-spec behavior)\n\t\t\t\t\t\t\t\t\t\tif ( handler !== Identity ) {\n\t\t\t\t\t\t\t\t\t\t\tthat = undefined;\n\t\t\t\t\t\t\t\t\t\t\targs = [ returned ];\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t// Process the value(s)\n\t\t\t\t\t\t\t\t\t\t// Default process is resolve\n\t\t\t\t\t\t\t\t\t\t( special || deferred.resolveWith )( that, args );\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t},\n\n\t\t\t\t\t\t\t\t// Only normal processors (resolve) catch and reject exceptions\n\t\t\t\t\t\t\t\tprocess = special ?\n\t\t\t\t\t\t\t\t\tmightThrow :\n\t\t\t\t\t\t\t\t\tfunction() {\n\t\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\t\tmightThrow();\n\t\t\t\t\t\t\t\t\t\t} catch ( e ) {\n\n\t\t\t\t\t\t\t\t\t\t\tif ( jQuery.Deferred.exceptionHook ) {\n\t\t\t\t\t\t\t\t\t\t\t\tjQuery.Deferred.exceptionHook( e,\n\t\t\t\t\t\t\t\t\t\t\t\t\tprocess.stackTrace );\n\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t// Support: Promises/A+ section 2.3.3.3.4.1\n\t\t\t\t\t\t\t\t\t\t\t// https://promisesaplus.com/#point-61\n\t\t\t\t\t\t\t\t\t\t\t// Ignore post-resolution exceptions\n\t\t\t\t\t\t\t\t\t\t\tif ( depth + 1 >= maxDepth ) {\n\n\t\t\t\t\t\t\t\t\t\t\t\t// Only substitute handlers pass on context\n\t\t\t\t\t\t\t\t\t\t\t\t// and multiple values (non-spec behavior)\n\t\t\t\t\t\t\t\t\t\t\t\tif ( handler !== Thrower ) {\n\t\t\t\t\t\t\t\t\t\t\t\t\tthat = undefined;\n\t\t\t\t\t\t\t\t\t\t\t\t\targs = [ e ];\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t\t\tdeferred.rejectWith( that, args );\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t};\n\n\t\t\t\t\t\t\t// Support: Promises/A+ section 2.3.3.3.1\n\t\t\t\t\t\t\t// https://promisesaplus.com/#point-57\n\t\t\t\t\t\t\t// Re-resolve promises immediately to dodge false rejection from\n\t\t\t\t\t\t\t// subsequent errors\n\t\t\t\t\t\t\tif ( depth ) {\n\t\t\t\t\t\t\t\tprocess();\n\t\t\t\t\t\t\t} else {\n\n\t\t\t\t\t\t\t\t// Call an optional hook to record the stack, in case of exception\n\t\t\t\t\t\t\t\t// since it's otherwise lost when execution goes async\n\t\t\t\t\t\t\t\tif ( jQuery.Deferred.getStackHook ) {\n\t\t\t\t\t\t\t\t\tprocess.stackTrace = jQuery.Deferred.getStackHook();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\twindow.setTimeout( process );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t};\n\t\t\t\t\t}\n\n\t\t\t\t\treturn jQuery.Deferred( function( newDefer ) {\n\n\t\t\t\t\t\t// progress_handlers.add( ... )\n\t\t\t\t\t\ttuples[ 0 ][ 3 ].add(\n\t\t\t\t\t\t\tresolve(\n\t\t\t\t\t\t\t\t0,\n\t\t\t\t\t\t\t\tnewDefer,\n\t\t\t\t\t\t\t\tisFunction( onProgress ) ?\n\t\t\t\t\t\t\t\t\tonProgress :\n\t\t\t\t\t\t\t\t\tIdentity,\n\t\t\t\t\t\t\t\tnewDefer.notifyWith\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t);\n\n\t\t\t\t\t\t// fulfilled_handlers.add( ... )\n\t\t\t\t\t\ttuples[ 1 ][ 3 ].add(\n\t\t\t\t\t\t\tresolve(\n\t\t\t\t\t\t\t\t0,\n\t\t\t\t\t\t\t\tnewDefer,\n\t\t\t\t\t\t\t\tisFunction( onFulfilled ) ?\n\t\t\t\t\t\t\t\t\tonFulfilled :\n\t\t\t\t\t\t\t\t\tIdentity\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t);\n\n\t\t\t\t\t\t// rejected_handlers.add( ... )\n\t\t\t\t\t\ttuples[ 2 ][ 3 ].add(\n\t\t\t\t\t\t\tresolve(\n\t\t\t\t\t\t\t\t0,\n\t\t\t\t\t\t\t\tnewDefer,\n\t\t\t\t\t\t\t\tisFunction( onRejected ) ?\n\t\t\t\t\t\t\t\t\tonRejected :\n\t\t\t\t\t\t\t\t\tThrower\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t);\n\t\t\t\t\t} ).promise();\n\t\t\t\t},\n\n\t\t\t\t// Get a promise for this deferred\n\t\t\t\t// If obj is provided, the promise aspect is added to the object\n\t\t\t\tpromise: function( obj ) {\n\t\t\t\t\treturn obj != null ? jQuery.extend( obj, promise ) : promise;\n\t\t\t\t}\n\t\t\t},\n\t\t\tdeferred = {};\n\n\t\t// Add list-specific methods\n\t\tjQuery.each( tuples, function( i, tuple ) {\n\t\t\tvar list = tuple[ 2 ],\n\t\t\t\tstateString = tuple[ 5 ];\n\n\t\t\t// promise.progress = list.add\n\t\t\t// promise.done = list.add\n\t\t\t// promise.fail = list.add\n\t\t\tpromise[ tuple[ 1 ] ] = list.add;\n\n\t\t\t// Handle state\n\t\t\tif ( stateString ) {\n\t\t\t\tlist.add(\n\t\t\t\t\tfunction() {\n\n\t\t\t\t\t\t// state = \"resolved\" (i.e., fulfilled)\n\t\t\t\t\t\t// state = \"rejected\"\n\t\t\t\t\t\tstate = stateString;\n\t\t\t\t\t},\n\n\t\t\t\t\t// rejected_callbacks.disable\n\t\t\t\t\t// fulfilled_callbacks.disable\n\t\t\t\t\ttuples[ 3 - i ][ 2 ].disable,\n\n\t\t\t\t\t// rejected_handlers.disable\n\t\t\t\t\t// fulfilled_handlers.disable\n\t\t\t\t\ttuples[ 3 - i ][ 3 ].disable,\n\n\t\t\t\t\t// progress_callbacks.lock\n\t\t\t\t\ttuples[ 0 ][ 2 ].lock,\n\n\t\t\t\t\t// progress_handlers.lock\n\t\t\t\t\ttuples[ 0 ][ 3 ].lock\n\t\t\t\t);\n\t\t\t}\n\n\t\t\t// progress_handlers.fire\n\t\t\t// fulfilled_handlers.fire\n\t\t\t// rejected_handlers.fire\n\t\t\tlist.add( tuple[ 3 ].fire );\n\n\t\t\t// deferred.notify = function() { deferred.notifyWith(...) }\n\t\t\t// deferred.resolve = function() { deferred.resolveWith(...) }\n\t\t\t// deferred.reject = function() { deferred.rejectWith(...) }\n\t\t\tdeferred[ tuple[ 0 ] ] = function() {\n\t\t\t\tdeferred[ tuple[ 0 ] + \"With\" ]( this === deferred ? undefined : this, arguments );\n\t\t\t\treturn this;\n\t\t\t};\n\n\t\t\t// deferred.notifyWith = list.fireWith\n\t\t\t// deferred.resolveWith = list.fireWith\n\t\t\t// deferred.rejectWith = list.fireWith\n\t\t\tdeferred[ tuple[ 0 ] + \"With\" ] = list.fireWith;\n\t\t} );\n\n\t\t// Make the deferred a promise\n\t\tpromise.promise( deferred );\n\n\t\t// Call given func if any\n\t\tif ( func ) {\n\t\t\tfunc.call( deferred, deferred );\n\t\t}\n\n\t\t// All done!\n\t\treturn deferred;\n\t},\n\n\t// Deferred helper\n\twhen: function( singleValue ) {\n\t\tvar\n\n\t\t\t// count of uncompleted subordinates\n\t\t\tremaining = arguments.length,\n\n\t\t\t// count of unprocessed arguments\n\t\t\ti = remaining,\n\n\t\t\t// subordinate fulfillment data\n\t\t\tresolveContexts = Array( i ),\n\t\t\tresolveValues = slice.call( arguments ),\n\n\t\t\t// the master Deferred\n\t\t\tmaster = jQuery.Deferred(),\n\n\t\t\t// subordinate callback factory\n\t\t\tupdateFunc = function( i ) {\n\t\t\t\treturn function( value ) {\n\t\t\t\t\tresolveContexts[ i ] = this;\n\t\t\t\t\tresolveValues[ i ] = arguments.length > 1 ? slice.call( arguments ) : value;\n\t\t\t\t\tif ( !( --remaining ) ) {\n\t\t\t\t\t\tmaster.resolveWith( resolveContexts, resolveValues );\n\t\t\t\t\t}\n\t\t\t\t};\n\t\t\t};\n\n\t\t// Single- and empty arguments are adopted like Promise.resolve\n\t\tif ( remaining <= 1 ) {\n\t\t\tadoptValue( singleValue, master.done( updateFunc( i ) ).resolve, master.reject,\n\t\t\t\t!remaining );\n\n\t\t\t// Use .then() to unwrap secondary thenables (cf. gh-3000)\n\t\t\tif ( master.state() === \"pending\" ||\n\t\t\t\tisFunction( resolveValues[ i ] && resolveValues[ i ].then ) ) {\n\n\t\t\t\treturn master.then();\n\t\t\t}\n\t\t}\n\n\t\t// Multiple arguments are aggregated like Promise.all array elements\n\t\twhile ( i-- ) {\n\t\t\tadoptValue( resolveValues[ i ], updateFunc( i ), master.reject );\n\t\t}\n\n\t\treturn master.promise();\n\t}\n} );\n\n\n// These usually indicate a programmer mistake during development,\n// warn about them ASAP rather than swallowing them by default.\nvar rerrorNames = /^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;\n\njQuery.Deferred.exceptionHook = function( error, stack ) {\n\n\t// Support: IE 8 - 9 only\n\t// Console exists when dev tools are open, which can happen at any time\n\tif ( window.console && window.console.warn && error && rerrorNames.test( error.name ) ) {\n\t\twindow.console.warn( \"jQuery.Deferred exception: \" + error.message, error.stack, stack );\n\t}\n};\n\n\n\n\njQuery.readyException = function( error ) {\n\twindow.setTimeout( function() {\n\t\tthrow error;\n\t} );\n};\n\n\n\n\n// The deferred used on DOM ready\nvar readyList = jQuery.Deferred();\n\njQuery.fn.ready = function( fn ) {\n\n\treadyList\n\t\t.then( fn )\n\n\t\t// Wrap jQuery.readyException in a function so that the lookup\n\t\t// happens at the time of error handling instead of callback\n\t\t// registration.\n\t\t.catch( function( error ) {\n\t\t\tjQuery.readyException( error );\n\t\t} );\n\n\treturn this;\n};\n\njQuery.extend( {\n\n\t// Is the DOM ready to be used? Set to true once it occurs.\n\tisReady: false,\n\n\t// A counter to track how many items to wait for before\n\t// the ready event fires. See #6781\n\treadyWait: 1,\n\n\t// Handle when the DOM is ready\n\tready: function( wait ) {\n\n\t\t// Abort if there are pending holds or we're already ready\n\t\tif ( wait === true ? --jQuery.readyWait : jQuery.isReady ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Remember that the DOM is ready\n\t\tjQuery.isReady = true;\n\n\t\t// If a normal DOM Ready event fired, decrement, and wait if need be\n\t\tif ( wait !== true && --jQuery.readyWait > 0 ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// If there are functions bound, to execute\n\t\treadyList.resolveWith( document, [ jQuery ] );\n\t}\n} );\n\njQuery.ready.then = readyList.then;\n\n// The ready event handler and self cleanup method\nfunction completed() {\n\tdocument.removeEventListener( \"DOMContentLoaded\", completed );\n\twindow.removeEventListener( \"load\", completed );\n\tjQuery.ready();\n}\n\n// Catch cases where $(document).ready() is called\n// after the browser event has already occurred.\n// Support: IE <=9 - 10 only\n// Older IE sometimes signals \"interactive\" too soon\nif ( document.readyState === \"complete\" ||\n\t( document.readyState !== \"loading\" && !document.documentElement.doScroll ) ) {\n\n\t// Handle it asynchronously to allow scripts the opportunity to delay ready\n\twindow.setTimeout( jQuery.ready );\n\n} else {\n\n\t// Use the handy event callback\n\tdocument.addEventListener( \"DOMContentLoaded\", completed );\n\n\t// A fallback to window.onload, that will always work\n\twindow.addEventListener( \"load\", completed );\n}\n\n\n\n\n// Multifunctional method to get and set values of a collection\n// The value/s can optionally be executed if it's a function\nvar access = function( elems, fn, key, value, chainable, emptyGet, raw ) {\n\tvar i = 0,\n\t\tlen = elems.length,\n\t\tbulk = key == null;\n\n\t// Sets many values\n\tif ( toType( key ) === \"object\" ) {\n\t\tchainable = true;\n\t\tfor ( i in key ) {\n\t\t\taccess( elems, fn, i, key[ i ], true, emptyGet, raw );\n\t\t}\n\n\t// Sets one value\n\t} else if ( value !== undefined ) {\n\t\tchainable = true;\n\n\t\tif ( !isFunction( value ) ) {\n\t\t\traw = true;\n\t\t}\n\n\t\tif ( bulk ) {\n\n\t\t\t// Bulk operations run against the entire set\n\t\t\tif ( raw ) {\n\t\t\t\tfn.call( elems, value );\n\t\t\t\tfn = null;\n\n\t\t\t// ...except when executing function values\n\t\t\t} else {\n\t\t\t\tbulk = fn;\n\t\t\t\tfn = function( elem, key, value ) {\n\t\t\t\t\treturn bulk.call( jQuery( elem ), value );\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\n\t\tif ( fn ) {\n\t\t\tfor ( ; i < len; i++ ) {\n\t\t\t\tfn(\n\t\t\t\t\telems[ i ], key, raw ?\n\t\t\t\t\tvalue :\n\t\t\t\t\tvalue.call( elems[ i ], i, fn( elems[ i ], key ) )\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t}\n\n\tif ( chainable ) {\n\t\treturn elems;\n\t}\n\n\t// Gets\n\tif ( bulk ) {\n\t\treturn fn.call( elems );\n\t}\n\n\treturn len ? fn( elems[ 0 ], key ) : emptyGet;\n};\n\n\n// Matches dashed string for camelizing\nvar rmsPrefix = /^-ms-/,\n\trdashAlpha = /-([a-z])/g;\n\n// Used by camelCase as callback to replace()\nfunction fcamelCase( all, letter ) {\n\treturn letter.toUpperCase();\n}\n\n// Convert dashed to camelCase; used by the css and data modules\n// Support: IE <=9 - 11, Edge 12 - 15\n// Microsoft forgot to hump their vendor prefix (#9572)\nfunction camelCase( string ) {\n\treturn string.replace( rmsPrefix, \"ms-\" ).replace( rdashAlpha, fcamelCase );\n}\nvar acceptData = function( owner ) {\n\n\t// Accepts only:\n\t//  - Node\n\t//    - Node.ELEMENT_NODE\n\t//    - Node.DOCUMENT_NODE\n\t//  - Object\n\t//    - Any\n\treturn owner.nodeType === 1 || owner.nodeType === 9 || !( +owner.nodeType );\n};\n\n\n\n\nfunction Data() {\n\tthis.expando = jQuery.expando + Data.uid++;\n}\n\nData.uid = 1;\n\nData.prototype = {\n\n\tcache: function( owner ) {\n\n\t\t// Check if the owner object already has a cache\n\t\tvar value = owner[ this.expando ];\n\n\t\t// If not, create one\n\t\tif ( !value ) {\n\t\t\tvalue = {};\n\n\t\t\t// We can accept data for non-element nodes in modern browsers,\n\t\t\t// but we should not, see #8335.\n\t\t\t// Always return an empty object.\n\t\t\tif ( acceptData( owner ) ) {\n\n\t\t\t\t// If it is a node unlikely to be stringify-ed or looped over\n\t\t\t\t// use plain assignment\n\t\t\t\tif ( owner.nodeType ) {\n\t\t\t\t\towner[ this.expando ] = value;\n\n\t\t\t\t// Otherwise secure it in a non-enumerable property\n\t\t\t\t// configurable must be true to allow the property to be\n\t\t\t\t// deleted when data is removed\n\t\t\t\t} else {\n\t\t\t\t\tObject.defineProperty( owner, this.expando, {\n\t\t\t\t\t\tvalue: value,\n\t\t\t\t\t\tconfigurable: true\n\t\t\t\t\t} );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn value;\n\t},\n\tset: function( owner, data, value ) {\n\t\tvar prop,\n\t\t\tcache = this.cache( owner );\n\n\t\t// Handle: [ owner, key, value ] args\n\t\t// Always use camelCase key (gh-2257)\n\t\tif ( typeof data === \"string\" ) {\n\t\t\tcache[ camelCase( data ) ] = value;\n\n\t\t// Handle: [ owner, { properties } ] args\n\t\t} else {\n\n\t\t\t// Copy the properties one-by-one to the cache object\n\t\t\tfor ( prop in data ) {\n\t\t\t\tcache[ camelCase( prop ) ] = data[ prop ];\n\t\t\t}\n\t\t}\n\t\treturn cache;\n\t},\n\tget: function( owner, key ) {\n\t\treturn key === undefined ?\n\t\t\tthis.cache( owner ) :\n\n\t\t\t// Always use camelCase key (gh-2257)\n\t\t\towner[ this.expando ] && owner[ this.expando ][ camelCase( key ) ];\n\t},\n\taccess: function( owner, key, value ) {\n\n\t\t// In cases where either:\n\t\t//\n\t\t//   1. No key was specified\n\t\t//   2. A string key was specified, but no value provided\n\t\t//\n\t\t// Take the \"read\" path and allow the get method to determine\n\t\t// which value to return, respectively either:\n\t\t//\n\t\t//   1. The entire cache object\n\t\t//   2. The data stored at the key\n\t\t//\n\t\tif ( key === undefined ||\n\t\t\t\t( ( key && typeof key === \"string\" ) && value === undefined ) ) {\n\n\t\t\treturn this.get( owner, key );\n\t\t}\n\n\t\t// When the key is not a string, or both a key and value\n\t\t// are specified, set or extend (existing objects) with either:\n\t\t//\n\t\t//   1. An object of properties\n\t\t//   2. A key and value\n\t\t//\n\t\tthis.set( owner, key, value );\n\n\t\t// Since the \"set\" path can have two possible entry points\n\t\t// return the expected data based on which path was taken[*]\n\t\treturn value !== undefined ? value : key;\n\t},\n\tremove: function( owner, key ) {\n\t\tvar i,\n\t\t\tcache = owner[ this.expando ];\n\n\t\tif ( cache === undefined ) {\n\t\t\treturn;\n\t\t}\n\n\t\tif ( key !== undefined ) {\n\n\t\t\t// Support array or space separated string of keys\n\t\t\tif ( Array.isArray( key ) ) {\n\n\t\t\t\t// If key is an array of keys...\n\t\t\t\t// We always set camelCase keys, so remove that.\n\t\t\t\tkey = key.map( camelCase );\n\t\t\t} else {\n\t\t\t\tkey = camelCase( key );\n\n\t\t\t\t// If a key with the spaces exists, use it.\n\t\t\t\t// Otherwise, create an array by matching non-whitespace\n\t\t\t\tkey = key in cache ?\n\t\t\t\t\t[ key ] :\n\t\t\t\t\t( key.match( rnothtmlwhite ) || [] );\n\t\t\t}\n\n\t\t\ti = key.length;\n\n\t\t\twhile ( i-- ) {\n\t\t\t\tdelete cache[ key[ i ] ];\n\t\t\t}\n\t\t}\n\n\t\t// Remove the expando if there's no more data\n\t\tif ( key === undefined || jQuery.isEmptyObject( cache ) ) {\n\n\t\t\t// Support: Chrome <=35 - 45\n\t\t\t// Webkit & Blink performance suffers when deleting properties\n\t\t\t// from DOM nodes, so set to undefined instead\n\t\t\t// https://bugs.chromium.org/p/chromium/issues/detail?id=378607 (bug restricted)\n\t\t\tif ( owner.nodeType ) {\n\t\t\t\towner[ this.expando ] = undefined;\n\t\t\t} else {\n\t\t\t\tdelete owner[ this.expando ];\n\t\t\t}\n\t\t}\n\t},\n\thasData: function( owner ) {\n\t\tvar cache = owner[ this.expando ];\n\t\treturn cache !== undefined && !jQuery.isEmptyObject( cache );\n\t}\n};\nvar dataPriv = new Data();\n\nvar dataUser = new Data();\n\n\n\n//\tImplementation Summary\n//\n//\t1. Enforce API surface and semantic compatibility with 1.9.x branch\n//\t2. Improve the module's maintainability by reducing the storage\n//\t\tpaths to a single mechanism.\n//\t3. Use the same single mechanism to support \"private\" and \"user\" data.\n//\t4. _Never_ expose \"private\" data to user code (TODO: Drop _data, _removeData)\n//\t5. Avoid exposing implementation details on user objects (eg. expando properties)\n//\t6. Provide a clear path for implementation upgrade to WeakMap in 2014\n\nvar rbrace = /^(?:\\{[\\w\\W]*\\}|\\[[\\w\\W]*\\])$/,\n\trmultiDash = /[A-Z]/g;\n\nfunction getData( data ) {\n\tif ( data === \"true\" ) {\n\t\treturn true;\n\t}\n\n\tif ( data === \"false\" ) {\n\t\treturn false;\n\t}\n\n\tif ( data === \"null\" ) {\n\t\treturn null;\n\t}\n\n\t// Only convert to a number if it doesn't change the string\n\tif ( data === +data + \"\" ) {\n\t\treturn +data;\n\t}\n\n\tif ( rbrace.test( data ) ) {\n\t\treturn JSON.parse( data );\n\t}\n\n\treturn data;\n}\n\nfunction dataAttr( elem, key, data ) {\n\tvar name;\n\n\t// If nothing was found internally, try to fetch any\n\t// data from the HTML5 data-* attribute\n\tif ( data === undefined && elem.nodeType === 1 ) {\n\t\tname = \"data-\" + key.replace( rmultiDash, \"-$&\" ).toLowerCase();\n\t\tdata = elem.getAttribute( name );\n\n\t\tif ( typeof data === \"string\" ) {\n\t\t\ttry {\n\t\t\t\tdata = getData( data );\n\t\t\t} catch ( e ) {}\n\n\t\t\t// Make sure we set the data so it isn't changed later\n\t\t\tdataUser.set( elem, key, data );\n\t\t} else {\n\t\t\tdata = undefined;\n\t\t}\n\t}\n\treturn data;\n}\n\njQuery.extend( {\n\thasData: function( elem ) {\n\t\treturn dataUser.hasData( elem ) || dataPriv.hasData( elem );\n\t},\n\n\tdata: function( elem, name, data ) {\n\t\treturn dataUser.access( elem, name, data );\n\t},\n\n\tremoveData: function( elem, name ) {\n\t\tdataUser.remove( elem, name );\n\t},\n\n\t// TODO: Now that all calls to _data and _removeData have been replaced\n\t// with direct calls to dataPriv methods, these can be deprecated.\n\t_data: function( elem, name, data ) {\n\t\treturn dataPriv.access( elem, name, data );\n\t},\n\n\t_removeData: function( elem, name ) {\n\t\tdataPriv.remove( elem, name );\n\t}\n} );\n\njQuery.fn.extend( {\n\tdata: function( key, value ) {\n\t\tvar i, name, data,\n\t\t\telem = this[ 0 ],\n\t\t\tattrs = elem && elem.attributes;\n\n\t\t// Gets all values\n\t\tif ( key === undefined ) {\n\t\t\tif ( this.length ) {\n\t\t\t\tdata = dataUser.get( elem );\n\n\t\t\t\tif ( elem.nodeType === 1 && !dataPriv.get( elem, \"hasDataAttrs\" ) ) {\n\t\t\t\t\ti = attrs.length;\n\t\t\t\t\twhile ( i-- ) {\n\n\t\t\t\t\t\t// Support: IE 11 only\n\t\t\t\t\t\t// The attrs elements can be null (#14894)\n\t\t\t\t\t\tif ( attrs[ i ] ) {\n\t\t\t\t\t\t\tname = attrs[ i ].name;\n\t\t\t\t\t\t\tif ( name.indexOf( \"data-\" ) === 0 ) {\n\t\t\t\t\t\t\t\tname = camelCase( name.slice( 5 ) );\n\t\t\t\t\t\t\t\tdataAttr( elem, name, data[ name ] );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tdataPriv.set( elem, \"hasDataAttrs\", true );\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn data;\n\t\t}\n\n\t\t// Sets multiple values\n\t\tif ( typeof key === \"object\" ) {\n\t\t\treturn this.each( function() {\n\t\t\t\tdataUser.set( this, key );\n\t\t\t} );\n\t\t}\n\n\t\treturn access( this, function( value ) {\n\t\t\tvar data;\n\n\t\t\t// The calling jQuery object (element matches) is not empty\n\t\t\t// (and therefore has an element appears at this[ 0 ]) and the\n\t\t\t// `value` parameter was not undefined. An empty jQuery object\n\t\t\t// will result in `undefined` for elem = this[ 0 ] which will\n\t\t\t// throw an exception if an attempt to read a data cache is made.\n\t\t\tif ( elem && value === undefined ) {\n\n\t\t\t\t// Attempt to get data from the cache\n\t\t\t\t// The key will always be camelCased in Data\n\t\t\t\tdata = dataUser.get( elem, key );\n\t\t\t\tif ( data !== undefined ) {\n\t\t\t\t\treturn data;\n\t\t\t\t}\n\n\t\t\t\t// Attempt to \"discover\" the data in\n\t\t\t\t// HTML5 custom data-* attrs\n\t\t\t\tdata = dataAttr( elem, key );\n\t\t\t\tif ( data !== undefined ) {\n\t\t\t\t\treturn data;\n\t\t\t\t}\n\n\t\t\t\t// We tried really hard, but the data doesn't exist.\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// Set the data...\n\t\t\tthis.each( function() {\n\n\t\t\t\t// We always store the camelCased key\n\t\t\t\tdataUser.set( this, key, value );\n\t\t\t} );\n\t\t}, null, value, arguments.length > 1, null, true );\n\t},\n\n\tremoveData: function( key ) {\n\t\treturn this.each( function() {\n\t\t\tdataUser.remove( this, key );\n\t\t} );\n\t}\n} );\n\n\njQuery.extend( {\n\tqueue: function( elem, type, data ) {\n\t\tvar queue;\n\n\t\tif ( elem ) {\n\t\t\ttype = ( type || \"fx\" ) + \"queue\";\n\t\t\tqueue = dataPriv.get( elem, type );\n\n\t\t\t// Speed up dequeue by getting out quickly if this is just a lookup\n\t\t\tif ( data ) {\n\t\t\t\tif ( !queue || Array.isArray( data ) ) {\n\t\t\t\t\tqueue = dataPriv.access( elem, type, jQuery.makeArray( data ) );\n\t\t\t\t} else {\n\t\t\t\t\tqueue.push( data );\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn queue || [];\n\t\t}\n\t},\n\n\tdequeue: function( elem, type ) {\n\t\ttype = type || \"fx\";\n\n\t\tvar queue = jQuery.queue( elem, type ),\n\t\t\tstartLength = queue.length,\n\t\t\tfn = queue.shift(),\n\t\t\thooks = jQuery._queueHooks( elem, type ),\n\t\t\tnext = function() {\n\t\t\t\tjQuery.dequeue( elem, type );\n\t\t\t};\n\n\t\t// If the fx queue is dequeued, always remove the progress sentinel\n\t\tif ( fn === \"inprogress\" ) {\n\t\t\tfn = queue.shift();\n\t\t\tstartLength--;\n\t\t}\n\n\t\tif ( fn ) {\n\n\t\t\t// Add a progress sentinel to prevent the fx queue from being\n\t\t\t// automatically dequeued\n\t\t\tif ( type === \"fx\" ) {\n\t\t\t\tqueue.unshift( \"inprogress\" );\n\t\t\t}\n\n\t\t\t// Clear up the last queue stop function\n\t\t\tdelete hooks.stop;\n\t\t\tfn.call( elem, next, hooks );\n\t\t}\n\n\t\tif ( !startLength && hooks ) {\n\t\t\thooks.empty.fire();\n\t\t}\n\t},\n\n\t// Not public - generate a queueHooks object, or return the current one\n\t_queueHooks: function( elem, type ) {\n\t\tvar key = type + \"queueHooks\";\n\t\treturn dataPriv.get( elem, key ) || dataPriv.access( elem, key, {\n\t\t\tempty: jQuery.Callbacks( \"once memory\" ).add( function() {\n\t\t\t\tdataPriv.remove( elem, [ type + \"queue\", key ] );\n\t\t\t} )\n\t\t} );\n\t}\n} );\n\njQuery.fn.extend( {\n\tqueue: function( type, data ) {\n\t\tvar setter = 2;\n\n\t\tif ( typeof type !== \"string\" ) {\n\t\t\tdata = type;\n\t\t\ttype = \"fx\";\n\t\t\tsetter--;\n\t\t}\n\n\t\tif ( arguments.length < setter ) {\n\t\t\treturn jQuery.queue( this[ 0 ], type );\n\t\t}\n\n\t\treturn data === undefined ?\n\t\t\tthis :\n\t\t\tthis.each( function() {\n\t\t\t\tvar queue = jQuery.queue( this, type, data );\n\n\t\t\t\t// Ensure a hooks for this queue\n\t\t\t\tjQuery._queueHooks( this, type );\n\n\t\t\t\tif ( type === \"fx\" && queue[ 0 ] !== \"inprogress\" ) {\n\t\t\t\t\tjQuery.dequeue( this, type );\n\t\t\t\t}\n\t\t\t} );\n\t},\n\tdequeue: function( type ) {\n\t\treturn this.each( function() {\n\t\t\tjQuery.dequeue( this, type );\n\t\t} );\n\t},\n\tclearQueue: function( type ) {\n\t\treturn this.queue( type || \"fx\", [] );\n\t},\n\n\t// Get a promise resolved when queues of a certain type\n\t// are emptied (fx is the type by default)\n\tpromise: function( type, obj ) {\n\t\tvar tmp,\n\t\t\tcount = 1,\n\t\t\tdefer = jQuery.Deferred(),\n\t\t\telements = this,\n\t\t\ti = this.length,\n\t\t\tresolve = function() {\n\t\t\t\tif ( !( --count ) ) {\n\t\t\t\t\tdefer.resolveWith( elements, [ elements ] );\n\t\t\t\t}\n\t\t\t};\n\n\t\tif ( typeof type !== \"string\" ) {\n\t\t\tobj = type;\n\t\t\ttype = undefined;\n\t\t}\n\t\ttype = type || \"fx\";\n\n\t\twhile ( i-- ) {\n\t\t\ttmp = dataPriv.get( elements[ i ], type + \"queueHooks\" );\n\t\t\tif ( tmp && tmp.empty ) {\n\t\t\t\tcount++;\n\t\t\t\ttmp.empty.add( resolve );\n\t\t\t}\n\t\t}\n\t\tresolve();\n\t\treturn defer.promise( obj );\n\t}\n} );\nvar pnum = ( /[+-]?(?:\\d*\\.|)\\d+(?:[eE][+-]?\\d+|)/ ).source;\n\nvar rcssNum = new RegExp( \"^(?:([+-])=|)(\" + pnum + \")([a-z%]*)$\", \"i\" );\n\n\nvar cssExpand = [ \"Top\", \"Right\", \"Bottom\", \"Left\" ];\n\nvar documentElement = document.documentElement;\n\n\n\n\tvar isAttached = function( elem ) {\n\t\t\treturn jQuery.contains( elem.ownerDocument, elem );\n\t\t},\n\t\tcomposed = { composed: true };\n\n\t// Support: IE 9 - 11+, Edge 12 - 18+, iOS 10.0 - 10.2 only\n\t// Check attachment across shadow DOM boundaries when possible (gh-3504)\n\t// Support: iOS 10.0-10.2 only\n\t// Early iOS 10 versions support `attachShadow` but not `getRootNode`,\n\t// leading to errors. We need to check for `getRootNode`.\n\tif ( documentElement.getRootNode ) {\n\t\tisAttached = function( elem ) {\n\t\t\treturn jQuery.contains( elem.ownerDocument, elem ) ||\n\t\t\t\telem.getRootNode( composed ) === elem.ownerDocument;\n\t\t};\n\t}\nvar isHiddenWithinTree = function( elem, el ) {\n\n\t\t// isHiddenWithinTree might be called from jQuery#filter function;\n\t\t// in that case, element will be second argument\n\t\telem = el || elem;\n\n\t\t// Inline style trumps all\n\t\treturn elem.style.display === \"none\" ||\n\t\t\telem.style.display === \"\" &&\n\n\t\t\t// Otherwise, check computed style\n\t\t\t// Support: Firefox <=43 - 45\n\t\t\t// Disconnected elements can have computed display: none, so first confirm that elem is\n\t\t\t// in the document.\n\t\t\tisAttached( elem ) &&\n\n\t\t\tjQuery.css( elem, \"display\" ) === \"none\";\n\t};\n\nvar swap = function( elem, options, callback, args ) {\n\tvar ret, name,\n\t\told = {};\n\n\t// Remember the old values, and insert the new ones\n\tfor ( name in options ) {\n\t\told[ name ] = elem.style[ name ];\n\t\telem.style[ name ] = options[ name ];\n\t}\n\n\tret = callback.apply( elem, args || [] );\n\n\t// Revert the old values\n\tfor ( name in options ) {\n\t\telem.style[ name ] = old[ name ];\n\t}\n\n\treturn ret;\n};\n\n\n\n\nfunction adjustCSS( elem, prop, valueParts, tween ) {\n\tvar adjusted, scale,\n\t\tmaxIterations = 20,\n\t\tcurrentValue = tween ?\n\t\t\tfunction() {\n\t\t\t\treturn tween.cur();\n\t\t\t} :\n\t\t\tfunction() {\n\t\t\t\treturn jQuery.css( elem, prop, \"\" );\n\t\t\t},\n\t\tinitial = currentValue(),\n\t\tunit = valueParts && valueParts[ 3 ] || ( jQuery.cssNumber[ prop ] ? \"\" : \"px\" ),\n\n\t\t// Starting value computation is required for potential unit mismatches\n\t\tinitialInUnit = elem.nodeType &&\n\t\t\t( jQuery.cssNumber[ prop ] || unit !== \"px\" && +initial ) &&\n\t\t\trcssNum.exec( jQuery.css( elem, prop ) );\n\n\tif ( initialInUnit && initialInUnit[ 3 ] !== unit ) {\n\n\t\t// Support: Firefox <=54\n\t\t// Halve the iteration target value to prevent interference from CSS upper bounds (gh-2144)\n\t\tinitial = initial / 2;\n\n\t\t// Trust units reported by jQuery.css\n\t\tunit = unit || initialInUnit[ 3 ];\n\n\t\t// Iteratively approximate from a nonzero starting point\n\t\tinitialInUnit = +initial || 1;\n\n\t\twhile ( maxIterations-- ) {\n\n\t\t\t// Evaluate and update our best guess (doubling guesses that zero out).\n\t\t\t// Finish if the scale equals or crosses 1 (making the old*new product non-positive).\n\t\t\tjQuery.style( elem, prop, initialInUnit + unit );\n\t\t\tif ( ( 1 - scale ) * ( 1 - ( scale = currentValue() / initial || 0.5 ) ) <= 0 ) {\n\t\t\t\tmaxIterations = 0;\n\t\t\t}\n\t\t\tinitialInUnit = initialInUnit / scale;\n\n\t\t}\n\n\t\tinitialInUnit = initialInUnit * 2;\n\t\tjQuery.style( elem, prop, initialInUnit + unit );\n\n\t\t// Make sure we update the tween properties later on\n\t\tvalueParts = valueParts || [];\n\t}\n\n\tif ( valueParts ) {\n\t\tinitialInUnit = +initialInUnit || +initial || 0;\n\n\t\t// Apply relative offset (+=/-=) if specified\n\t\tadjusted = valueParts[ 1 ] ?\n\t\t\tinitialInUnit + ( valueParts[ 1 ] + 1 ) * valueParts[ 2 ] :\n\t\t\t+valueParts[ 2 ];\n\t\tif ( tween ) {\n\t\t\ttween.unit = unit;\n\t\t\ttween.start = initialInUnit;\n\t\t\ttween.end = adjusted;\n\t\t}\n\t}\n\treturn adjusted;\n}\n\n\nvar defaultDisplayMap = {};\n\nfunction getDefaultDisplay( elem ) {\n\tvar temp,\n\t\tdoc = elem.ownerDocument,\n\t\tnodeName = elem.nodeName,\n\t\tdisplay = defaultDisplayMap[ nodeName ];\n\n\tif ( display ) {\n\t\treturn display;\n\t}\n\n\ttemp = doc.body.appendChild( doc.createElement( nodeName ) );\n\tdisplay = jQuery.css( temp, \"display\" );\n\n\ttemp.parentNode.removeChild( temp );\n\n\tif ( display === \"none\" ) {\n\t\tdisplay = \"block\";\n\t}\n\tdefaultDisplayMap[ nodeName ] = display;\n\n\treturn display;\n}\n\nfunction showHide( elements, show ) {\n\tvar display, elem,\n\t\tvalues = [],\n\t\tindex = 0,\n\t\tlength = elements.length;\n\n\t// Determine new display value for elements that need to change\n\tfor ( ; index < length; index++ ) {\n\t\telem = elements[ index ];\n\t\tif ( !elem.style ) {\n\t\t\tcontinue;\n\t\t}\n\n\t\tdisplay = elem.style.display;\n\t\tif ( show ) {\n\n\t\t\t// Since we force visibility upon cascade-hidden elements, an immediate (and slow)\n\t\t\t// check is required in this first loop unless we have a nonempty display value (either\n\t\t\t// inline or about-to-be-restored)\n\t\t\tif ( display === \"none\" ) {\n\t\t\t\tvalues[ index ] = dataPriv.get( elem, \"display\" ) || null;\n\t\t\t\tif ( !values[ index ] ) {\n\t\t\t\t\telem.style.display = \"\";\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( elem.style.display === \"\" && isHiddenWithinTree( elem ) ) {\n\t\t\t\tvalues[ index ] = getDefaultDisplay( elem );\n\t\t\t}\n\t\t} else {\n\t\t\tif ( display !== \"none\" ) {\n\t\t\t\tvalues[ index ] = \"none\";\n\n\t\t\t\t// Remember what we're overwriting\n\t\t\t\tdataPriv.set( elem, \"display\", display );\n\t\t\t}\n\t\t}\n\t}\n\n\t// Set the display of the elements in a second loop to avoid constant reflow\n\tfor ( index = 0; index < length; index++ ) {\n\t\tif ( values[ index ] != null ) {\n\t\t\telements[ index ].style.display = values[ index ];\n\t\t}\n\t}\n\n\treturn elements;\n}\n\njQuery.fn.extend( {\n\tshow: function() {\n\t\treturn showHide( this, true );\n\t},\n\thide: function() {\n\t\treturn showHide( this );\n\t},\n\ttoggle: function( state ) {\n\t\tif ( typeof state === \"boolean\" ) {\n\t\t\treturn state ? this.show() : this.hide();\n\t\t}\n\n\t\treturn this.each( function() {\n\t\t\tif ( isHiddenWithinTree( this ) ) {\n\t\t\t\tjQuery( this ).show();\n\t\t\t} else {\n\t\t\t\tjQuery( this ).hide();\n\t\t\t}\n\t\t} );\n\t}\n} );\nvar rcheckableType = ( /^(?:checkbox|radio)$/i );\n\nvar rtagName = ( /<([a-z][^\\/\\0>\\x20\\t\\r\\n\\f]*)/i );\n\nvar rscriptType = ( /^$|^module$|\\/(?:java|ecma)script/i );\n\n\n\n// We have to close these tags to support XHTML (#13200)\nvar wrapMap = {\n\n\t// Support: IE <=9 only\n\toption: [ 1, \"<select multiple='multiple'>\", \"</select>\" ],\n\n\t// XHTML parsers do not magically insert elements in the\n\t// same way that tag soup parsers do. So we cannot shorten\n\t// this by omitting <tbody> or other required elements.\n\tthead: [ 1, \"<table>\", \"</table>\" ],\n\tcol: [ 2, \"<table><colgroup>\", \"</colgroup></table>\" ],\n\ttr: [ 2, \"<table><tbody>\", \"</tbody></table>\" ],\n\ttd: [ 3, \"<table><tbody><tr>\", \"</tr></tbody></table>\" ],\n\n\t_default: [ 0, \"\", \"\" ]\n};\n\n// Support: IE <=9 only\nwrapMap.optgroup = wrapMap.option;\n\nwrapMap.tbody = wrapMap.tfoot = wrapMap.colgroup = wrapMap.caption = wrapMap.thead;\nwrapMap.th = wrapMap.td;\n\n\nfunction getAll( context, tag ) {\n\n\t// Support: IE <=9 - 11 only\n\t// Use typeof to avoid zero-argument method invocation on host objects (#15151)\n\tvar ret;\n\n\tif ( typeof context.getElementsByTagName !== \"undefined\" ) {\n\t\tret = context.getElementsByTagName( tag || \"*\" );\n\n\t} else if ( typeof context.querySelectorAll !== \"undefined\" ) {\n\t\tret = context.querySelectorAll( tag || \"*\" );\n\n\t} else {\n\t\tret = [];\n\t}\n\n\tif ( tag === undefined || tag && nodeName( context, tag ) ) {\n\t\treturn jQuery.merge( [ context ], ret );\n\t}\n\n\treturn ret;\n}\n\n\n// Mark scripts as having already been evaluated\nfunction setGlobalEval( elems, refElements ) {\n\tvar i = 0,\n\t\tl = elems.length;\n\n\tfor ( ; i < l; i++ ) {\n\t\tdataPriv.set(\n\t\t\telems[ i ],\n\t\t\t\"globalEval\",\n\t\t\t!refElements || dataPriv.get( refElements[ i ], \"globalEval\" )\n\t\t);\n\t}\n}\n\n\nvar rhtml = /<|&#?\\w+;/;\n\nfunction buildFragment( elems, context, scripts, selection, ignored ) {\n\tvar elem, tmp, tag, wrap, attached, j,\n\t\tfragment = context.createDocumentFragment(),\n\t\tnodes = [],\n\t\ti = 0,\n\t\tl = elems.length;\n\n\tfor ( ; i < l; i++ ) {\n\t\telem = elems[ i ];\n\n\t\tif ( elem || elem === 0 ) {\n\n\t\t\t// Add nodes directly\n\t\t\tif ( toType( elem ) === \"object\" ) {\n\n\t\t\t\t// Support: Android <=4.0 only, PhantomJS 1 only\n\t\t\t\t// push.apply(_, arraylike) throws on ancient WebKit\n\t\t\t\tjQuery.merge( nodes, elem.nodeType ? [ elem ] : elem );\n\n\t\t\t// Convert non-html into a text node\n\t\t\t} else if ( !rhtml.test( elem ) ) {\n\t\t\t\tnodes.push( context.createTextNode( elem ) );\n\n\t\t\t// Convert html into DOM nodes\n\t\t\t} else {\n\t\t\t\ttmp = tmp || fragment.appendChild( context.createElement( \"div\" ) );\n\n\t\t\t\t// Deserialize a standard representation\n\t\t\t\ttag = ( rtagName.exec( elem ) || [ \"\", \"\" ] )[ 1 ].toLowerCase();\n\t\t\t\twrap = wrapMap[ tag ] || wrapMap._default;\n\t\t\t\ttmp.innerHTML = wrap[ 1 ] + jQuery.htmlPrefilter( elem ) + wrap[ 2 ];\n\n\t\t\t\t// Descend through wrappers to the right content\n\t\t\t\tj = wrap[ 0 ];\n\t\t\t\twhile ( j-- ) {\n\t\t\t\t\ttmp = tmp.lastChild;\n\t\t\t\t}\n\n\t\t\t\t// Support: Android <=4.0 only, PhantomJS 1 only\n\t\t\t\t// push.apply(_, arraylike) throws on ancient WebKit\n\t\t\t\tjQuery.merge( nodes, tmp.childNodes );\n\n\t\t\t\t// Remember the top-level container\n\t\t\t\ttmp = fragment.firstChild;\n\n\t\t\t\t// Ensure the created nodes are orphaned (#12392)\n\t\t\t\ttmp.textContent = \"\";\n\t\t\t}\n\t\t}\n\t}\n\n\t// Remove wrapper from fragment\n\tfragment.textContent = \"\";\n\n\ti = 0;\n\twhile ( ( elem = nodes[ i++ ] ) ) {\n\n\t\t// Skip elements already in the context collection (trac-4087)\n\t\tif ( selection && jQuery.inArray( elem, selection ) > -1 ) {\n\t\t\tif ( ignored ) {\n\t\t\t\tignored.push( elem );\n\t\t\t}\n\t\t\tcontinue;\n\t\t}\n\n\t\tattached = isAttached( elem );\n\n\t\t// Append to fragment\n\t\ttmp = getAll( fragment.appendChild( elem ), \"script\" );\n\n\t\t// Preserve script evaluation history\n\t\tif ( attached ) {\n\t\t\tsetGlobalEval( tmp );\n\t\t}\n\n\t\t// Capture executables\n\t\tif ( scripts ) {\n\t\t\tj = 0;\n\t\t\twhile ( ( elem = tmp[ j++ ] ) ) {\n\t\t\t\tif ( rscriptType.test( elem.type || \"\" ) ) {\n\t\t\t\t\tscripts.push( elem );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn fragment;\n}\n\n\n( function() {\n\tvar fragment = document.createDocumentFragment(),\n\t\tdiv = fragment.appendChild( document.createElement( \"div\" ) ),\n\t\tinput = document.createElement( \"input\" );\n\n\t// Support: Android 4.0 - 4.3 only\n\t// Check state lost if the name is set (#11217)\n\t// Support: Windows Web Apps (WWA)\n\t// `name` and `type` must use .setAttribute for WWA (#14901)\n\tinput.setAttribute( \"type\", \"radio\" );\n\tinput.setAttribute( \"checked\", \"checked\" );\n\tinput.setAttribute( \"name\", \"t\" );\n\n\tdiv.appendChild( input );\n\n\t// Support: Android <=4.1 only\n\t// Older WebKit doesn't clone checked state correctly in fragments\n\tsupport.checkClone = div.cloneNode( true ).cloneNode( true ).lastChild.checked;\n\n\t// Support: IE <=11 only\n\t// Make sure textarea (and checkbox) defaultValue is properly cloned\n\tdiv.innerHTML = \"<textarea>x</textarea>\";\n\tsupport.noCloneChecked = !!div.cloneNode( true ).lastChild.defaultValue;\n} )();\n\n\nvar\n\trkeyEvent = /^key/,\n\trmouseEvent = /^(?:mouse|pointer|contextmenu|drag|drop)|click/,\n\trtypenamespace = /^([^.]*)(?:\\.(.+)|)/;\n\nfunction returnTrue() {\n\treturn true;\n}\n\nfunction returnFalse() {\n\treturn false;\n}\n\n// Support: IE <=9 - 11+\n// focus() and blur() are asynchronous, except when they are no-op.\n// So expect focus to be synchronous when the element is already active,\n// and blur to be synchronous when the element is not already active.\n// (focus and blur are always synchronous in other supported browsers,\n// this just defines when we can count on it).\nfunction expectSync( elem, type ) {\n\treturn ( elem === safeActiveElement() ) === ( type === \"focus\" );\n}\n\n// Support: IE <=9 only\n// Accessing document.activeElement can throw unexpectedly\n// https://bugs.jquery.com/ticket/13393\nfunction safeActiveElement() {\n\ttry {\n\t\treturn document.activeElement;\n\t} catch ( err ) { }\n}\n\nfunction on( elem, types, selector, data, fn, one ) {\n\tvar origFn, type;\n\n\t// Types can be a map of types/handlers\n\tif ( typeof types === \"object\" ) {\n\n\t\t// ( types-Object, selector, data )\n\t\tif ( typeof selector !== \"string\" ) {\n\n\t\t\t// ( types-Object, data )\n\t\t\tdata = data || selector;\n\t\t\tselector = undefined;\n\t\t}\n\t\tfor ( type in types ) {\n\t\t\ton( elem, type, selector, data, types[ type ], one );\n\t\t}\n\t\treturn elem;\n\t}\n\n\tif ( data == null && fn == null ) {\n\n\t\t// ( types, fn )\n\t\tfn = selector;\n\t\tdata = selector = undefined;\n\t} else if ( fn == null ) {\n\t\tif ( typeof selector === \"string\" ) {\n\n\t\t\t// ( types, selector, fn )\n\t\t\tfn = data;\n\t\t\tdata = undefined;\n\t\t} else {\n\n\t\t\t// ( types, data, fn )\n\t\t\tfn = data;\n\t\t\tdata = selector;\n\t\t\tselector = undefined;\n\t\t}\n\t}\n\tif ( fn === false ) {\n\t\tfn = returnFalse;\n\t} else if ( !fn ) {\n\t\treturn elem;\n\t}\n\n\tif ( one === 1 ) {\n\t\torigFn = fn;\n\t\tfn = function( event ) {\n\n\t\t\t// Can use an empty set, since event contains the info\n\t\t\tjQuery().off( event );\n\t\t\treturn origFn.apply( this, arguments );\n\t\t};\n\n\t\t// Use same guid so caller can remove using origFn\n\t\tfn.guid = origFn.guid || ( origFn.guid = jQuery.guid++ );\n\t}\n\treturn elem.each( function() {\n\t\tjQuery.event.add( this, types, fn, data, selector );\n\t} );\n}\n\n/*\n * Helper functions for managing events -- not part of the public interface.\n * Props to Dean Edwards' addEvent library for many of the ideas.\n */\njQuery.event = {\n\n\tglobal: {},\n\n\tadd: function( elem, types, handler, data, selector ) {\n\n\t\tvar handleObjIn, eventHandle, tmp,\n\t\t\tevents, t, handleObj,\n\t\t\tspecial, handlers, type, namespaces, origType,\n\t\t\telemData = dataPriv.get( elem );\n\n\t\t// Don't attach events to noData or text/comment nodes (but allow plain objects)\n\t\tif ( !elemData ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Caller can pass in an object of custom data in lieu of the handler\n\t\tif ( handler.handler ) {\n\t\t\thandleObjIn = handler;\n\t\t\thandler = handleObjIn.handler;\n\t\t\tselector = handleObjIn.selector;\n\t\t}\n\n\t\t// Ensure that invalid selectors throw exceptions at attach time\n\t\t// Evaluate against documentElement in case elem is a non-element node (e.g., document)\n\t\tif ( selector ) {\n\t\t\tjQuery.find.matchesSelector( documentElement, selector );\n\t\t}\n\n\t\t// Make sure that the handler has a unique ID, used to find/remove it later\n\t\tif ( !handler.guid ) {\n\t\t\thandler.guid = jQuery.guid++;\n\t\t}\n\n\t\t// Init the element's event structure and main handler, if this is the first\n\t\tif ( !( events = elemData.events ) ) {\n\t\t\tevents = elemData.events = {};\n\t\t}\n\t\tif ( !( eventHandle = elemData.handle ) ) {\n\t\t\teventHandle = elemData.handle = function( e ) {\n\n\t\t\t\t// Discard the second event of a jQuery.event.trigger() and\n\t\t\t\t// when an event is called after a page has unloaded\n\t\t\t\treturn typeof jQuery !== \"undefined\" && jQuery.event.triggered !== e.type ?\n\t\t\t\t\tjQuery.event.dispatch.apply( elem, arguments ) : undefined;\n\t\t\t};\n\t\t}\n\n\t\t// Handle multiple events separated by a space\n\t\ttypes = ( types || \"\" ).match( rnothtmlwhite ) || [ \"\" ];\n\t\tt = types.length;\n\t\twhile ( t-- ) {\n\t\t\ttmp = rtypenamespace.exec( types[ t ] ) || [];\n\t\t\ttype = origType = tmp[ 1 ];\n\t\t\tnamespaces = ( tmp[ 2 ] || \"\" ).split( \".\" ).sort();\n\n\t\t\t// There *must* be a type, no attaching namespace-only handlers\n\t\t\tif ( !type ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t// If event changes its type, use the special event handlers for the changed type\n\t\t\tspecial = jQuery.event.special[ type ] || {};\n\n\t\t\t// If selector defined, determine special event api type, otherwise given type\n\t\t\ttype = ( selector ? special.delegateType : special.bindType ) || type;\n\n\t\t\t// Update special based on newly reset type\n\t\t\tspecial = jQuery.event.special[ type ] || {};\n\n\t\t\t// handleObj is passed to all event handlers\n\t\t\thandleObj = jQuery.extend( {\n\t\t\t\ttype: type,\n\t\t\t\torigType: origType,\n\t\t\t\tdata: data,\n\t\t\t\thandler: handler,\n\t\t\t\tguid: handler.guid,\n\t\t\t\tselector: selector,\n\t\t\t\tneedsContext: selector && jQuery.expr.match.needsContext.test( selector ),\n\t\t\t\tnamespace: namespaces.join( \".\" )\n\t\t\t}, handleObjIn );\n\n\t\t\t// Init the event handler queue if we're the first\n\t\t\tif ( !( handlers = events[ type ] ) ) {\n\t\t\t\thandlers = events[ type ] = [];\n\t\t\t\thandlers.delegateCount = 0;\n\n\t\t\t\t// Only use addEventListener if the special events handler returns false\n\t\t\t\tif ( !special.setup ||\n\t\t\t\t\tspecial.setup.call( elem, data, namespaces, eventHandle ) === false ) {\n\n\t\t\t\t\tif ( elem.addEventListener ) {\n\t\t\t\t\t\telem.addEventListener( type, eventHandle );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif ( special.add ) {\n\t\t\t\tspecial.add.call( elem, handleObj );\n\n\t\t\t\tif ( !handleObj.handler.guid ) {\n\t\t\t\t\thandleObj.handler.guid = handler.guid;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Add to the element's handler list, delegates in front\n\t\t\tif ( selector ) {\n\t\t\t\thandlers.splice( handlers.delegateCount++, 0, handleObj );\n\t\t\t} else {\n\t\t\t\thandlers.push( handleObj );\n\t\t\t}\n\n\t\t\t// Keep track of which events have ever been used, for event optimization\n\t\t\tjQuery.event.global[ type ] = true;\n\t\t}\n\n\t},\n\n\t// Detach an event or set of events from an element\n\tremove: function( elem, types, handler, selector, mappedTypes ) {\n\n\t\tvar j, origCount, tmp,\n\t\t\tevents, t, handleObj,\n\t\t\tspecial, handlers, type, namespaces, origType,\n\t\t\telemData = dataPriv.hasData( elem ) && dataPriv.get( elem );\n\n\t\tif ( !elemData || !( events = elemData.events ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Once for each type.namespace in types; type may be omitted\n\t\ttypes = ( types || \"\" ).match( rnothtmlwhite ) || [ \"\" ];\n\t\tt = types.length;\n\t\twhile ( t-- ) {\n\t\t\ttmp = rtypenamespace.exec( types[ t ] ) || [];\n\t\t\ttype = origType = tmp[ 1 ];\n\t\t\tnamespaces = ( tmp[ 2 ] || \"\" ).split( \".\" ).sort();\n\n\t\t\t// Unbind all events (on this namespace, if provided) for the element\n\t\t\tif ( !type ) {\n\t\t\t\tfor ( type in events ) {\n\t\t\t\t\tjQuery.event.remove( elem, type + types[ t ], handler, selector, true );\n\t\t\t\t}\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tspecial = jQuery.event.special[ type ] || {};\n\t\t\ttype = ( selector ? special.delegateType : special.bindType ) || type;\n\t\t\thandlers = events[ type ] || [];\n\t\t\ttmp = tmp[ 2 ] &&\n\t\t\t\tnew RegExp( \"(^|\\\\.)\" + namespaces.join( \"\\\\.(?:.*\\\\.|)\" ) + \"(\\\\.|$)\" );\n\n\t\t\t// Remove matching events\n\t\t\torigCount = j = handlers.length;\n\t\t\twhile ( j-- ) {\n\t\t\t\thandleObj = handlers[ j ];\n\n\t\t\t\tif ( ( mappedTypes || origType === handleObj.origType ) &&\n\t\t\t\t\t( !handler || handler.guid === handleObj.guid ) &&\n\t\t\t\t\t( !tmp || tmp.test( handleObj.namespace ) ) &&\n\t\t\t\t\t( !selector || selector === handleObj.selector ||\n\t\t\t\t\t\tselector === \"**\" && handleObj.selector ) ) {\n\t\t\t\t\thandlers.splice( j, 1 );\n\n\t\t\t\t\tif ( handleObj.selector ) {\n\t\t\t\t\t\thandlers.delegateCount--;\n\t\t\t\t\t}\n\t\t\t\t\tif ( special.remove ) {\n\t\t\t\t\t\tspecial.remove.call( elem, handleObj );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Remove generic event handler if we removed something and no more handlers exist\n\t\t\t// (avoids potential for endless recursion during removal of special event handlers)\n\t\t\tif ( origCount && !handlers.length ) {\n\t\t\t\tif ( !special.teardown ||\n\t\t\t\t\tspecial.teardown.call( elem, namespaces, elemData.handle ) === false ) {\n\n\t\t\t\t\tjQuery.removeEvent( elem, type, elemData.handle );\n\t\t\t\t}\n\n\t\t\t\tdelete events[ type ];\n\t\t\t}\n\t\t}\n\n\t\t// Remove data and the expando if it's no longer used\n\t\tif ( jQuery.isEmptyObject( events ) ) {\n\t\t\tdataPriv.remove( elem, \"handle events\" );\n\t\t}\n\t},\n\n\tdispatch: function( nativeEvent ) {\n\n\t\t// Make a writable jQuery.Event from the native event object\n\t\tvar event = jQuery.event.fix( nativeEvent );\n\n\t\tvar i, j, ret, matched, handleObj, handlerQueue,\n\t\t\targs = new Array( arguments.length ),\n\t\t\thandlers = ( dataPriv.get( this, \"events\" ) || {} )[ event.type ] || [],\n\t\t\tspecial = jQuery.event.special[ event.type ] || {};\n\n\t\t// Use the fix-ed jQuery.Event rather than the (read-only) native event\n\t\targs[ 0 ] = event;\n\n\t\tfor ( i = 1; i < arguments.length; i++ ) {\n\t\t\targs[ i ] = arguments[ i ];\n\t\t}\n\n\t\tevent.delegateTarget = this;\n\n\t\t// Call the preDispatch hook for the mapped type, and let it bail if desired\n\t\tif ( special.preDispatch && special.preDispatch.call( this, event ) === false ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Determine handlers\n\t\thandlerQueue = jQuery.event.handlers.call( this, event, handlers );\n\n\t\t// Run delegates first; they may want to stop propagation beneath us\n\t\ti = 0;\n\t\twhile ( ( matched = handlerQueue[ i++ ] ) && !event.isPropagationStopped() ) {\n\t\t\tevent.currentTarget = matched.elem;\n\n\t\t\tj = 0;\n\t\t\twhile ( ( handleObj = matched.handlers[ j++ ] ) &&\n\t\t\t\t!event.isImmediatePropagationStopped() ) {\n\n\t\t\t\t// If the event is namespaced, then each handler is only invoked if it is\n\t\t\t\t// specially universal or its namespaces are a superset of the event's.\n\t\t\t\tif ( !event.rnamespace || handleObj.namespace === false ||\n\t\t\t\t\tevent.rnamespace.test( handleObj.namespace ) ) {\n\n\t\t\t\t\tevent.handleObj = handleObj;\n\t\t\t\t\tevent.data = handleObj.data;\n\n\t\t\t\t\tret = ( ( jQuery.event.special[ handleObj.origType ] || {} ).handle ||\n\t\t\t\t\t\thandleObj.handler ).apply( matched.elem, args );\n\n\t\t\t\t\tif ( ret !== undefined ) {\n\t\t\t\t\t\tif ( ( event.result = ret ) === false ) {\n\t\t\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Call the postDispatch hook for the mapped type\n\t\tif ( special.postDispatch ) {\n\t\t\tspecial.postDispatch.call( this, event );\n\t\t}\n\n\t\treturn event.result;\n\t},\n\n\thandlers: function( event, handlers ) {\n\t\tvar i, handleObj, sel, matchedHandlers, matchedSelectors,\n\t\t\thandlerQueue = [],\n\t\t\tdelegateCount = handlers.delegateCount,\n\t\t\tcur = event.target;\n\n\t\t// Find delegate handlers\n\t\tif ( delegateCount &&\n\n\t\t\t// Support: IE <=9\n\t\t\t// Black-hole SVG <use> instance trees (trac-13180)\n\t\t\tcur.nodeType &&\n\n\t\t\t// Support: Firefox <=42\n\t\t\t// Suppress spec-violating clicks indicating a non-primary pointer button (trac-3861)\n\t\t\t// https://www.w3.org/TR/DOM-Level-3-Events/#event-type-click\n\t\t\t// Support: IE 11 only\n\t\t\t// ...but not arrow key \"clicks\" of radio inputs, which can have `button` -1 (gh-2343)\n\t\t\t!( event.type === \"click\" && event.button >= 1 ) ) {\n\n\t\t\tfor ( ; cur !== this; cur = cur.parentNode || this ) {\n\n\t\t\t\t// Don't check non-elements (#13208)\n\t\t\t\t// Don't process clicks on disabled elements (#6911, #8165, #11382, #11764)\n\t\t\t\tif ( cur.nodeType === 1 && !( event.type === \"click\" && cur.disabled === true ) ) {\n\t\t\t\t\tmatchedHandlers = [];\n\t\t\t\t\tmatchedSelectors = {};\n\t\t\t\t\tfor ( i = 0; i < delegateCount; i++ ) {\n\t\t\t\t\t\thandleObj = handlers[ i ];\n\n\t\t\t\t\t\t// Don't conflict with Object.prototype properties (#13203)\n\t\t\t\t\t\tsel = handleObj.selector + \" \";\n\n\t\t\t\t\t\tif ( matchedSelectors[ sel ] === undefined ) {\n\t\t\t\t\t\t\tmatchedSelectors[ sel ] = handleObj.needsContext ?\n\t\t\t\t\t\t\t\tjQuery( sel, this ).index( cur ) > -1 :\n\t\t\t\t\t\t\t\tjQuery.find( sel, this, null, [ cur ] ).length;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ( matchedSelectors[ sel ] ) {\n\t\t\t\t\t\t\tmatchedHandlers.push( handleObj );\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif ( matchedHandlers.length ) {\n\t\t\t\t\t\thandlerQueue.push( { elem: cur, handlers: matchedHandlers } );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// Add the remaining (directly-bound) handlers\n\t\tcur = this;\n\t\tif ( delegateCount < handlers.length ) {\n\t\t\thandlerQueue.push( { elem: cur, handlers: handlers.slice( delegateCount ) } );\n\t\t}\n\n\t\treturn handlerQueue;\n\t},\n\n\taddProp: function( name, hook ) {\n\t\tObject.defineProperty( jQuery.Event.prototype, name, {\n\t\t\tenumerable: true,\n\t\t\tconfigurable: true,\n\n\t\t\tget: isFunction( hook ) ?\n\t\t\t\tfunction() {\n\t\t\t\t\tif ( this.originalEvent ) {\n\t\t\t\t\t\t\treturn hook( this.originalEvent );\n\t\t\t\t\t}\n\t\t\t\t} :\n\t\t\t\tfunction() {\n\t\t\t\t\tif ( this.originalEvent ) {\n\t\t\t\t\t\t\treturn this.originalEvent[ name ];\n\t\t\t\t\t}\n\t\t\t\t},\n\n\t\t\tset: function( value ) {\n\t\t\t\tObject.defineProperty( this, name, {\n\t\t\t\t\tenumerable: true,\n\t\t\t\t\tconfigurable: true,\n\t\t\t\t\twritable: true,\n\t\t\t\t\tvalue: value\n\t\t\t\t} );\n\t\t\t}\n\t\t} );\n\t},\n\n\tfix: function( originalEvent ) {\n\t\treturn originalEvent[ jQuery.expando ] ?\n\t\t\toriginalEvent :\n\t\t\tnew jQuery.Event( originalEvent );\n\t},\n\n\tspecial: {\n\t\tload: {\n\n\t\t\t// Prevent triggered image.load events from bubbling to window.load\n\t\t\tnoBubble: true\n\t\t},\n\t\tclick: {\n\n\t\t\t// Utilize native event to ensure correct state for checkable inputs\n\t\t\tsetup: function( data ) {\n\n\t\t\t\t// For mutual compressibility with _default, replace `this` access with a local var.\n\t\t\t\t// `|| data` is dead code meant only to preserve the variable through minification.\n\t\t\t\tvar el = this || data;\n\n\t\t\t\t// Claim the first handler\n\t\t\t\tif ( rcheckableType.test( el.type ) &&\n\t\t\t\t\tel.click && nodeName( el, \"input\" ) ) {\n\n\t\t\t\t\t// dataPriv.set( el, \"click\", ... )\n\t\t\t\t\tleverageNative( el, \"click\", returnTrue );\n\t\t\t\t}\n\n\t\t\t\t// Return false to allow normal processing in the caller\n\t\t\t\treturn false;\n\t\t\t},\n\t\t\ttrigger: function( data ) {\n\n\t\t\t\t// For mutual compressibility with _default, replace `this` access with a local var.\n\t\t\t\t// `|| data` is dead code meant only to preserve the variable through minification.\n\t\t\t\tvar el = this || data;\n\n\t\t\t\t// Force setup before triggering a click\n\t\t\t\tif ( rcheckableType.test( el.type ) &&\n\t\t\t\t\tel.click && nodeName( el, \"input\" ) ) {\n\n\t\t\t\t\tleverageNative( el, \"click\" );\n\t\t\t\t}\n\n\t\t\t\t// Return non-false to allow normal event-path propagation\n\t\t\t\treturn true;\n\t\t\t},\n\n\t\t\t// For cross-browser consistency, suppress native .click() on links\n\t\t\t// Also prevent it if we're currently inside a leveraged native-event stack\n\t\t\t_default: function( event ) {\n\t\t\t\tvar target = event.target;\n\t\t\t\treturn rcheckableType.test( target.type ) &&\n\t\t\t\t\ttarget.click && nodeName( target, \"input\" ) &&\n\t\t\t\t\tdataPriv.get( target, \"click\" ) ||\n\t\t\t\t\tnodeName( target, \"a\" );\n\t\t\t}\n\t\t},\n\n\t\tbeforeunload: {\n\t\t\tpostDispatch: function( event ) {\n\n\t\t\t\t// Support: Firefox 20+\n\t\t\t\t// Firefox doesn't alert if the returnValue field is not set.\n\t\t\t\tif ( event.result !== undefined && event.originalEvent ) {\n\t\t\t\t\tevent.originalEvent.returnValue = event.result;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n};\n\n// Ensure the presence of an event listener that handles manually-triggered\n// synthetic events by interrupting progress until reinvoked in response to\n// *native* events that it fires directly, ensuring that state changes have\n// already occurred before other listeners are invoked.\nfunction leverageNative( el, type, expectSync ) {\n\n\t// Missing expectSync indicates a trigger call, which must force setup through jQuery.event.add\n\tif ( !expectSync ) {\n\t\tif ( dataPriv.get( el, type ) === undefined ) {\n\t\t\tjQuery.event.add( el, type, returnTrue );\n\t\t}\n\t\treturn;\n\t}\n\n\t// Register the controller as a special universal handler for all event namespaces\n\tdataPriv.set( el, type, false );\n\tjQuery.event.add( el, type, {\n\t\tnamespace: false,\n\t\thandler: function( event ) {\n\t\t\tvar notAsync, result,\n\t\t\t\tsaved = dataPriv.get( this, type );\n\n\t\t\tif ( ( event.isTrigger & 1 ) && this[ type ] ) {\n\n\t\t\t\t// Interrupt processing of the outer synthetic .trigger()ed event\n\t\t\t\t// Saved data should be false in such cases, but might be a leftover capture object\n\t\t\t\t// from an async native handler (gh-4350)\n\t\t\t\tif ( !saved.length ) {\n\n\t\t\t\t\t// Store arguments for use when handling the inner native event\n\t\t\t\t\t// There will always be at least one argument (an event object), so this array\n\t\t\t\t\t// will not be confused with a leftover capture object.\n\t\t\t\t\tsaved = slice.call( arguments );\n\t\t\t\t\tdataPriv.set( this, type, saved );\n\n\t\t\t\t\t// Trigger the native event and capture its result\n\t\t\t\t\t// Support: IE <=9 - 11+\n\t\t\t\t\t// focus() and blur() are asynchronous\n\t\t\t\t\tnotAsync = expectSync( this, type );\n\t\t\t\t\tthis[ type ]();\n\t\t\t\t\tresult = dataPriv.get( this, type );\n\t\t\t\t\tif ( saved !== result || notAsync ) {\n\t\t\t\t\t\tdataPriv.set( this, type, false );\n\t\t\t\t\t} else {\n\t\t\t\t\t\tresult = {};\n\t\t\t\t\t}\n\t\t\t\t\tif ( saved !== result ) {\n\n\t\t\t\t\t\t// Cancel the outer synthetic event\n\t\t\t\t\t\tevent.stopImmediatePropagation();\n\t\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\t\treturn result.value;\n\t\t\t\t\t}\n\n\t\t\t\t// If this is an inner synthetic event for an event with a bubbling surrogate\n\t\t\t\t// (focus or blur), assume that the surrogate already propagated from triggering the\n\t\t\t\t// native event and prevent that from happening again here.\n\t\t\t\t// This technically gets the ordering wrong w.r.t. to `.trigger()` (in which the\n\t\t\t\t// bubbling surrogate propagates *after* the non-bubbling base), but that seems\n\t\t\t\t// less bad than duplication.\n\t\t\t\t} else if ( ( jQuery.event.special[ type ] || {} ).delegateType ) {\n\t\t\t\t\tevent.stopPropagation();\n\t\t\t\t}\n\n\t\t\t// If this is a native event triggered above, everything is now in order\n\t\t\t// Fire an inner synthetic event with the original arguments\n\t\t\t} else if ( saved.length ) {\n\n\t\t\t\t// ...and capture the result\n\t\t\t\tdataPriv.set( this, type, {\n\t\t\t\t\tvalue: jQuery.event.trigger(\n\n\t\t\t\t\t\t// Support: IE <=9 - 11+\n\t\t\t\t\t\t// Extend with the prototype to reset the above stopImmediatePropagation()\n\t\t\t\t\t\tjQuery.extend( saved[ 0 ], jQuery.Event.prototype ),\n\t\t\t\t\t\tsaved.slice( 1 ),\n\t\t\t\t\t\tthis\n\t\t\t\t\t)\n\t\t\t\t} );\n\n\t\t\t\t// Abort handling of the native event\n\t\t\t\tevent.stopImmediatePropagation();\n\t\t\t}\n\t\t}\n\t} );\n}\n\njQuery.removeEvent = function( elem, type, handle ) {\n\n\t// This \"if\" is needed for plain objects\n\tif ( elem.removeEventListener ) {\n\t\telem.removeEventListener( type, handle );\n\t}\n};\n\njQuery.Event = function( src, props ) {\n\n\t// Allow instantiation without the 'new' keyword\n\tif ( !( this instanceof jQuery.Event ) ) {\n\t\treturn new jQuery.Event( src, props );\n\t}\n\n\t// Event object\n\tif ( src && src.type ) {\n\t\tthis.originalEvent = src;\n\t\tthis.type = src.type;\n\n\t\t// Events bubbling up the document may have been marked as prevented\n\t\t// by a handler lower down the tree; reflect the correct value.\n\t\tthis.isDefaultPrevented = src.defaultPrevented ||\n\t\t\t\tsrc.defaultPrevented === undefined &&\n\n\t\t\t\t// Support: Android <=2.3 only\n\t\t\t\tsrc.returnValue === false ?\n\t\t\treturnTrue :\n\t\t\treturnFalse;\n\n\t\t// Create target properties\n\t\t// Support: Safari <=6 - 7 only\n\t\t// Target should not be a text node (#504, #13143)\n\t\tthis.target = ( src.target && src.target.nodeType === 3 ) ?\n\t\t\tsrc.target.parentNode :\n\t\t\tsrc.target;\n\n\t\tthis.currentTarget = src.currentTarget;\n\t\tthis.relatedTarget = src.relatedTarget;\n\n\t// Event type\n\t} else {\n\t\tthis.type = src;\n\t}\n\n\t// Put explicitly provided properties onto the event object\n\tif ( props ) {\n\t\tjQuery.extend( this, props );\n\t}\n\n\t// Create a timestamp if incoming event doesn't have one\n\tthis.timeStamp = src && src.timeStamp || Date.now();\n\n\t// Mark it as fixed\n\tthis[ jQuery.expando ] = true;\n};\n\n// jQuery.Event is based on DOM3 Events as specified by the ECMAScript Language Binding\n// https://www.w3.org/TR/2003/WD-DOM-Level-3-Events-20030331/ecma-script-binding.html\njQuery.Event.prototype = {\n\tconstructor: jQuery.Event,\n\tisDefaultPrevented: returnFalse,\n\tisPropagationStopped: returnFalse,\n\tisImmediatePropagationStopped: returnFalse,\n\tisSimulated: false,\n\n\tpreventDefault: function() {\n\t\tvar e = this.originalEvent;\n\n\t\tthis.isDefaultPrevented = returnTrue;\n\n\t\tif ( e && !this.isSimulated ) {\n\t\t\te.preventDefault();\n\t\t}\n\t},\n\tstopPropagation: function() {\n\t\tvar e = this.originalEvent;\n\n\t\tthis.isPropagationStopped = returnTrue;\n\n\t\tif ( e && !this.isSimulated ) {\n\t\t\te.stopPropagation();\n\t\t}\n\t},\n\tstopImmediatePropagation: function() {\n\t\tvar e = this.originalEvent;\n\n\t\tthis.isImmediatePropagationStopped = returnTrue;\n\n\t\tif ( e && !this.isSimulated ) {\n\t\t\te.stopImmediatePropagation();\n\t\t}\n\n\t\tthis.stopPropagation();\n\t}\n};\n\n// Includes all common event props including KeyEvent and MouseEvent specific props\njQuery.each( {\n\taltKey: true,\n\tbubbles: true,\n\tcancelable: true,\n\tchangedTouches: true,\n\tctrlKey: true,\n\tdetail: true,\n\teventPhase: true,\n\tmetaKey: true,\n\tpageX: true,\n\tpageY: true,\n\tshiftKey: true,\n\tview: true,\n\t\"char\": true,\n\tcode: true,\n\tcharCode: true,\n\tkey: true,\n\tkeyCode: true,\n\tbutton: true,\n\tbuttons: true,\n\tclientX: true,\n\tclientY: true,\n\toffsetX: true,\n\toffsetY: true,\n\tpointerId: true,\n\tpointerType: true,\n\tscreenX: true,\n\tscreenY: true,\n\ttargetTouches: true,\n\ttoElement: true,\n\ttouches: true,\n\n\twhich: function( event ) {\n\t\tvar button = event.button;\n\n\t\t// Add which for key events\n\t\tif ( event.which == null && rkeyEvent.test( event.type ) ) {\n\t\t\treturn event.charCode != null ? event.charCode : event.keyCode;\n\t\t}\n\n\t\t// Add which for click: 1 === left; 2 === middle; 3 === right\n\t\tif ( !event.which && button !== undefined && rmouseEvent.test( event.type ) ) {\n\t\t\tif ( button & 1 ) {\n\t\t\t\treturn 1;\n\t\t\t}\n\n\t\t\tif ( button & 2 ) {\n\t\t\t\treturn 3;\n\t\t\t}\n\n\t\t\tif ( button & 4 ) {\n\t\t\t\treturn 2;\n\t\t\t}\n\n\t\t\treturn 0;\n\t\t}\n\n\t\treturn event.which;\n\t}\n}, jQuery.event.addProp );\n\njQuery.each( { focus: \"focusin\", blur: \"focusout\" }, function( type, delegateType ) {\n\tjQuery.event.special[ type ] = {\n\n\t\t// Utilize native event if possible so blur/focus sequence is correct\n\t\tsetup: function() {\n\n\t\t\t// Claim the first handler\n\t\t\t// dataPriv.set( this, \"focus\", ... )\n\t\t\t// dataPriv.set( this, \"blur\", ... )\n\t\t\tleverageNative( this, type, expectSync );\n\n\t\t\t// Return false to allow normal processing in the caller\n\t\t\treturn false;\n\t\t},\n\t\ttrigger: function() {\n\n\t\t\t// Force setup before trigger\n\t\t\tleverageNative( this, type );\n\n\t\t\t// Return non-false to allow normal event-path propagation\n\t\t\treturn true;\n\t\t},\n\n\t\tdelegateType: delegateType\n\t};\n} );\n\n// Create mouseenter/leave events using mouseover/out and event-time checks\n// so that event delegation works in jQuery.\n// Do the same for pointerenter/pointerleave and pointerover/pointerout\n//\n// Support: Safari 7 only\n// Safari sends mouseenter too often; see:\n// https://bugs.chromium.org/p/chromium/issues/detail?id=470258\n// for the description of the bug (it existed in older Chrome versions as well).\njQuery.each( {\n\tmouseenter: \"mouseover\",\n\tmouseleave: \"mouseout\",\n\tpointerenter: \"pointerover\",\n\tpointerleave: \"pointerout\"\n}, function( orig, fix ) {\n\tjQuery.event.special[ orig ] = {\n\t\tdelegateType: fix,\n\t\tbindType: fix,\n\n\t\thandle: function( event ) {\n\t\t\tvar ret,\n\t\t\t\ttarget = this,\n\t\t\t\trelated = event.relatedTarget,\n\t\t\t\thandleObj = event.handleObj;\n\n\t\t\t// For mouseenter/leave call the handler if related is outside the target.\n\t\t\t// NB: No relatedTarget if the mouse left/entered the browser window\n\t\t\tif ( !related || ( related !== target && !jQuery.contains( target, related ) ) ) {\n\t\t\t\tevent.type = handleObj.origType;\n\t\t\t\tret = handleObj.handler.apply( this, arguments );\n\t\t\t\tevent.type = fix;\n\t\t\t}\n\t\t\treturn ret;\n\t\t}\n\t};\n} );\n\njQuery.fn.extend( {\n\n\ton: function( types, selector, data, fn ) {\n\t\treturn on( this, types, selector, data, fn );\n\t},\n\tone: function( types, selector, data, fn ) {\n\t\treturn on( this, types, selector, data, fn, 1 );\n\t},\n\toff: function( types, selector, fn ) {\n\t\tvar handleObj, type;\n\t\tif ( types && types.preventDefault && types.handleObj ) {\n\n\t\t\t// ( event )  dispatched jQuery.Event\n\t\t\thandleObj = types.handleObj;\n\t\t\tjQuery( types.delegateTarget ).off(\n\t\t\t\thandleObj.namespace ?\n\t\t\t\t\thandleObj.origType + \".\" + handleObj.namespace :\n\t\t\t\t\thandleObj.origType,\n\t\t\t\thandleObj.selector,\n\t\t\t\thandleObj.handler\n\t\t\t);\n\t\t\treturn this;\n\t\t}\n\t\tif ( typeof types === \"object\" ) {\n\n\t\t\t// ( types-object [, selector] )\n\t\t\tfor ( type in types ) {\n\t\t\t\tthis.off( type, selector, types[ type ] );\n\t\t\t}\n\t\t\treturn this;\n\t\t}\n\t\tif ( selector === false || typeof selector === \"function\" ) {\n\n\t\t\t// ( types [, fn] )\n\t\t\tfn = selector;\n\t\t\tselector = undefined;\n\t\t}\n\t\tif ( fn === false ) {\n\t\t\tfn = returnFalse;\n\t\t}\n\t\treturn this.each( function() {\n\t\t\tjQuery.event.remove( this, types, fn, selector );\n\t\t} );\n\t}\n} );\n\n\nvar\n\n\t/* eslint-disable max-len */\n\n\t// See https://github.com/eslint/eslint/issues/3229\n\trxhtmlTag = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\\/\\0>\\x20\\t\\r\\n\\f]*)[^>]*)\\/>/gi,\n\n\t/* eslint-enable */\n\n\t// Support: IE <=10 - 11, Edge 12 - 13 only\n\t// In IE/Edge using regex groups here causes severe slowdowns.\n\t// See https://connect.microsoft.com/IE/feedback/details/1736512/\n\trnoInnerhtml = /<script|<style|<link/i,\n\n\t// checked=\"checked\" or checked\n\trchecked = /checked\\s*(?:[^=]|=\\s*.checked.)/i,\n\trcleanScript = /^\\s*<!(?:\\[CDATA\\[|--)|(?:\\]\\]|--)>\\s*$/g;\n\n// Prefer a tbody over its parent table for containing new rows\nfunction manipulationTarget( elem, content ) {\n\tif ( nodeName( elem, \"table\" ) &&\n\t\tnodeName( content.nodeType !== 11 ? content : content.firstChild, \"tr\" ) ) {\n\n\t\treturn jQuery( elem ).children( \"tbody\" )[ 0 ] || elem;\n\t}\n\n\treturn elem;\n}\n\n// Replace/restore the type attribute of script elements for safe DOM manipulation\nfunction disableScript( elem ) {\n\telem.type = ( elem.getAttribute( \"type\" ) !== null ) + \"/\" + elem.type;\n\treturn elem;\n}\nfunction restoreScript( elem ) {\n\tif ( ( elem.type || \"\" ).slice( 0, 5 ) === \"true/\" ) {\n\t\telem.type = elem.type.slice( 5 );\n\t} else {\n\t\telem.removeAttribute( \"type\" );\n\t}\n\n\treturn elem;\n}\n\nfunction cloneCopyEvent( src, dest ) {\n\tvar i, l, type, pdataOld, pdataCur, udataOld, udataCur, events;\n\n\tif ( dest.nodeType !== 1 ) {\n\t\treturn;\n\t}\n\n\t// 1. Copy private data: events, handlers, etc.\n\tif ( dataPriv.hasData( src ) ) {\n\t\tpdataOld = dataPriv.access( src );\n\t\tpdataCur = dataPriv.set( dest, pdataOld );\n\t\tevents = pdataOld.events;\n\n\t\tif ( events ) {\n\t\t\tdelete pdataCur.handle;\n\t\t\tpdataCur.events = {};\n\n\t\t\tfor ( type in events ) {\n\t\t\t\tfor ( i = 0, l = events[ type ].length; i < l; i++ ) {\n\t\t\t\t\tjQuery.event.add( dest, type, events[ type ][ i ] );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t// 2. Copy user data\n\tif ( dataUser.hasData( src ) ) {\n\t\tudataOld = dataUser.access( src );\n\t\tudataCur = jQuery.extend( {}, udataOld );\n\n\t\tdataUser.set( dest, udataCur );\n\t}\n}\n\n// Fix IE bugs, see support tests\nfunction fixInput( src, dest ) {\n\tvar nodeName = dest.nodeName.toLowerCase();\n\n\t// Fails to persist the checked state of a cloned checkbox or radio button.\n\tif ( nodeName === \"input\" && rcheckableType.test( src.type ) ) {\n\t\tdest.checked = src.checked;\n\n\t// Fails to return the selected option to the default selected state when cloning options\n\t} else if ( nodeName === \"input\" || nodeName === \"textarea\" ) {\n\t\tdest.defaultValue = src.defaultValue;\n\t}\n}\n\nfunction domManip( collection, args, callback, ignored ) {\n\n\t// Flatten any nested arrays\n\targs = concat.apply( [], args );\n\n\tvar fragment, first, scripts, hasScripts, node, doc,\n\t\ti = 0,\n\t\tl = collection.length,\n\t\tiNoClone = l - 1,\n\t\tvalue = args[ 0 ],\n\t\tvalueIsFunction = isFunction( value );\n\n\t// We can't cloneNode fragments that contain checked, in WebKit\n\tif ( valueIsFunction ||\n\t\t\t( l > 1 && typeof value === \"string\" &&\n\t\t\t\t!support.checkClone && rchecked.test( value ) ) ) {\n\t\treturn collection.each( function( index ) {\n\t\t\tvar self = collection.eq( index );\n\t\t\tif ( valueIsFunction ) {\n\t\t\t\targs[ 0 ] = value.call( this, index, self.html() );\n\t\t\t}\n\t\t\tdomManip( self, args, callback, ignored );\n\t\t} );\n\t}\n\n\tif ( l ) {\n\t\tfragment = buildFragment( args, collection[ 0 ].ownerDocument, false, collection, ignored );\n\t\tfirst = fragment.firstChild;\n\n\t\tif ( fragment.childNodes.length === 1 ) {\n\t\t\tfragment = first;\n\t\t}\n\n\t\t// Require either new content or an interest in ignored elements to invoke the callback\n\t\tif ( first || ignored ) {\n\t\t\tscripts = jQuery.map( getAll( fragment, \"script\" ), disableScript );\n\t\t\thasScripts = scripts.length;\n\n\t\t\t// Use the original fragment for the last item\n\t\t\t// instead of the first because it can end up\n\t\t\t// being emptied incorrectly in certain situations (#8070).\n\t\t\tfor ( ; i < l; i++ ) {\n\t\t\t\tnode = fragment;\n\n\t\t\t\tif ( i !== iNoClone ) {\n\t\t\t\t\tnode = jQuery.clone( node, true, true );\n\n\t\t\t\t\t// Keep references to cloned scripts for later restoration\n\t\t\t\t\tif ( hasScripts ) {\n\n\t\t\t\t\t\t// Support: Android <=4.0 only, PhantomJS 1 only\n\t\t\t\t\t\t// push.apply(_, arraylike) throws on ancient WebKit\n\t\t\t\t\t\tjQuery.merge( scripts, getAll( node, \"script\" ) );\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tcallback.call( collection[ i ], node, i );\n\t\t\t}\n\n\t\t\tif ( hasScripts ) {\n\t\t\t\tdoc = scripts[ scripts.length - 1 ].ownerDocument;\n\n\t\t\t\t// Reenable scripts\n\t\t\t\tjQuery.map( scripts, restoreScript );\n\n\t\t\t\t// Evaluate executable scripts on first document insertion\n\t\t\t\tfor ( i = 0; i < hasScripts; i++ ) {\n\t\t\t\t\tnode = scripts[ i ];\n\t\t\t\t\tif ( rscriptType.test( node.type || \"\" ) &&\n\t\t\t\t\t\t!dataPriv.access( node, \"globalEval\" ) &&\n\t\t\t\t\t\tjQuery.contains( doc, node ) ) {\n\n\t\t\t\t\t\tif ( node.src && ( node.type || \"\" ).toLowerCase()  !== \"module\" ) {\n\n\t\t\t\t\t\t\t// Optional AJAX dependency, but won't run scripts if not present\n\t\t\t\t\t\t\tif ( jQuery._evalUrl && !node.noModule ) {\n\t\t\t\t\t\t\t\tjQuery._evalUrl( node.src, {\n\t\t\t\t\t\t\t\t\tnonce: node.nonce || node.getAttribute( \"nonce\" )\n\t\t\t\t\t\t\t\t} );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tDOMEval( node.textContent.replace( rcleanScript, \"\" ), node, doc );\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn collection;\n}\n\nfunction remove( elem, selector, keepData ) {\n\tvar node,\n\t\tnodes = selector ? jQuery.filter( selector, elem ) : elem,\n\t\ti = 0;\n\n\tfor ( ; ( node = nodes[ i ] ) != null; i++ ) {\n\t\tif ( !keepData && node.nodeType === 1 ) {\n\t\t\tjQuery.cleanData( getAll( node ) );\n\t\t}\n\n\t\tif ( node.parentNode ) {\n\t\t\tif ( keepData && isAttached( node ) ) {\n\t\t\t\tsetGlobalEval( getAll( node, \"script\" ) );\n\t\t\t}\n\t\t\tnode.parentNode.removeChild( node );\n\t\t}\n\t}\n\n\treturn elem;\n}\n\njQuery.extend( {\n\thtmlPrefilter: function( html ) {\n\t\treturn html.replace( rxhtmlTag, \"<$1></$2>\" );\n\t},\n\n\tclone: function( elem, dataAndEvents, deepDataAndEvents ) {\n\t\tvar i, l, srcElements, destElements,\n\t\t\tclone = elem.cloneNode( true ),\n\t\t\tinPage = isAttached( elem );\n\n\t\t// Fix IE cloning issues\n\t\tif ( !support.noCloneChecked && ( elem.nodeType === 1 || elem.nodeType === 11 ) &&\n\t\t\t\t!jQuery.isXMLDoc( elem ) ) {\n\n\t\t\t// We eschew Sizzle here for performance reasons: https://jsperf.com/getall-vs-sizzle/2\n\t\t\tdestElements = getAll( clone );\n\t\t\tsrcElements = getAll( elem );\n\n\t\t\tfor ( i = 0, l = srcElements.length; i < l; i++ ) {\n\t\t\t\tfixInput( srcElements[ i ], destElements[ i ] );\n\t\t\t}\n\t\t}\n\n\t\t// Copy the events from the original to the clone\n\t\tif ( dataAndEvents ) {\n\t\t\tif ( deepDataAndEvents ) {\n\t\t\t\tsrcElements = srcElements || getAll( elem );\n\t\t\t\tdestElements = destElements || getAll( clone );\n\n\t\t\t\tfor ( i = 0, l = srcElements.length; i < l; i++ ) {\n\t\t\t\t\tcloneCopyEvent( srcElements[ i ], destElements[ i ] );\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tcloneCopyEvent( elem, clone );\n\t\t\t}\n\t\t}\n\n\t\t// Preserve script evaluation history\n\t\tdestElements = getAll( clone, \"script\" );\n\t\tif ( destElements.length > 0 ) {\n\t\t\tsetGlobalEval( destElements, !inPage && getAll( elem, \"script\" ) );\n\t\t}\n\n\t\t// Return the cloned set\n\t\treturn clone;\n\t},\n\n\tcleanData: function( elems ) {\n\t\tvar data, elem, type,\n\t\t\tspecial = jQuery.event.special,\n\t\t\ti = 0;\n\n\t\tfor ( ; ( elem = elems[ i ] ) !== undefined; i++ ) {\n\t\t\tif ( acceptData( elem ) ) {\n\t\t\t\tif ( ( data = elem[ dataPriv.expando ] ) ) {\n\t\t\t\t\tif ( data.events ) {\n\t\t\t\t\t\tfor ( type in data.events ) {\n\t\t\t\t\t\t\tif ( special[ type ] ) {\n\t\t\t\t\t\t\t\tjQuery.event.remove( elem, type );\n\n\t\t\t\t\t\t\t// This is a shortcut to avoid jQuery.event.remove's overhead\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tjQuery.removeEvent( elem, type, data.handle );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t// Support: Chrome <=35 - 45+\n\t\t\t\t\t// Assign undefined instead of using delete, see Data#remove\n\t\t\t\t\telem[ dataPriv.expando ] = undefined;\n\t\t\t\t}\n\t\t\t\tif ( elem[ dataUser.expando ] ) {\n\n\t\t\t\t\t// Support: Chrome <=35 - 45+\n\t\t\t\t\t// Assign undefined instead of using delete, see Data#remove\n\t\t\t\t\telem[ dataUser.expando ] = undefined;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n} );\n\njQuery.fn.extend( {\n\tdetach: function( selector ) {\n\t\treturn remove( this, selector, true );\n\t},\n\n\tremove: function( selector ) {\n\t\treturn remove( this, selector );\n\t},\n\n\ttext: function( value ) {\n\t\treturn access( this, function( value ) {\n\t\t\treturn value === undefined ?\n\t\t\t\tjQuery.text( this ) :\n\t\t\t\tthis.empty().each( function() {\n\t\t\t\t\tif ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {\n\t\t\t\t\t\tthis.textContent = value;\n\t\t\t\t\t}\n\t\t\t\t} );\n\t\t}, null, value, arguments.length );\n\t},\n\n\tappend: function() {\n\t\treturn domManip( this, arguments, function( elem ) {\n\t\t\tif ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {\n\t\t\t\tvar target = manipulationTarget( this, elem );\n\t\t\t\ttarget.appendChild( elem );\n\t\t\t}\n\t\t} );\n\t},\n\n\tprepend: function() {\n\t\treturn domManip( this, arguments, function( elem ) {\n\t\t\tif ( this.nodeType === 1 || this.nodeType === 11 || this.nodeType === 9 ) {\n\t\t\t\tvar target = manipulationTarget( this, elem );\n\t\t\t\ttarget.insertBefore( elem, target.firstChild );\n\t\t\t}\n\t\t} );\n\t},\n\n\tbefore: function() {\n\t\treturn domManip( this, arguments, function( elem ) {\n\t\t\tif ( this.parentNode ) {\n\t\t\t\tthis.parentNode.insertBefore( elem, this );\n\t\t\t}\n\t\t} );\n\t},\n\n\tafter: function() {\n\t\treturn domManip( this, arguments, function( elem ) {\n\t\t\tif ( this.parentNode ) {\n\t\t\t\tthis.parentNode.insertBefore( elem, this.nextSibling );\n\t\t\t}\n\t\t} );\n\t},\n\n\tempty: function() {\n\t\tvar elem,\n\t\t\ti = 0;\n\n\t\tfor ( ; ( elem = this[ i ] ) != null; i++ ) {\n\t\t\tif ( elem.nodeType === 1 ) {\n\n\t\t\t\t// Prevent memory leaks\n\t\t\t\tjQuery.cleanData( getAll( elem, false ) );\n\n\t\t\t\t// Remove any remaining nodes\n\t\t\t\telem.textContent = \"\";\n\t\t\t}\n\t\t}\n\n\t\treturn this;\n\t},\n\n\tclone: function( dataAndEvents, deepDataAndEvents ) {\n\t\tdataAndEvents = dataAndEvents == null ? false : dataAndEvents;\n\t\tdeepDataAndEvents = deepDataAndEvents == null ? dataAndEvents : deepDataAndEvents;\n\n\t\treturn this.map( function() {\n\t\t\treturn jQuery.clone( this, dataAndEvents, deepDataAndEvents );\n\t\t} );\n\t},\n\n\thtml: function( value ) {\n\t\treturn access( this, function( value ) {\n\t\t\tvar elem = this[ 0 ] || {},\n\t\t\t\ti = 0,\n\t\t\t\tl = this.length;\n\n\t\t\tif ( value === undefined && elem.nodeType === 1 ) {\n\t\t\t\treturn elem.innerHTML;\n\t\t\t}\n\n\t\t\t// See if we can take a shortcut and just use innerHTML\n\t\t\tif ( typeof value === \"string\" && !rnoInnerhtml.test( value ) &&\n\t\t\t\t!wrapMap[ ( rtagName.exec( value ) || [ \"\", \"\" ] )[ 1 ].toLowerCase() ] ) {\n\n\t\t\t\tvalue = jQuery.htmlPrefilter( value );\n\n\t\t\t\ttry {\n\t\t\t\t\tfor ( ; i < l; i++ ) {\n\t\t\t\t\t\telem = this[ i ] || {};\n\n\t\t\t\t\t\t// Remove element nodes and prevent memory leaks\n\t\t\t\t\t\tif ( elem.nodeType === 1 ) {\n\t\t\t\t\t\t\tjQuery.cleanData( getAll( elem, false ) );\n\t\t\t\t\t\t\telem.innerHTML = value;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\telem = 0;\n\n\t\t\t\t// If using innerHTML throws an exception, use the fallback method\n\t\t\t\t} catch ( e ) {}\n\t\t\t}\n\n\t\t\tif ( elem ) {\n\t\t\t\tthis.empty().append( value );\n\t\t\t}\n\t\t}, null, value, arguments.length );\n\t},\n\n\treplaceWith: function() {\n\t\tvar ignored = [];\n\n\t\t// Make the changes, replacing each non-ignored context element with the new content\n\t\treturn domManip( this, arguments, function( elem ) {\n\t\t\tvar parent = this.parentNode;\n\n\t\t\tif ( jQuery.inArray( this, ignored ) < 0 ) {\n\t\t\t\tjQuery.cleanData( getAll( this ) );\n\t\t\t\tif ( parent ) {\n\t\t\t\t\tparent.replaceChild( elem, this );\n\t\t\t\t}\n\t\t\t}\n\n\t\t// Force callback invocation\n\t\t}, ignored );\n\t}\n} );\n\njQuery.each( {\n\tappendTo: \"append\",\n\tprependTo: \"prepend\",\n\tinsertBefore: \"before\",\n\tinsertAfter: \"after\",\n\treplaceAll: \"replaceWith\"\n}, function( name, original ) {\n\tjQuery.fn[ name ] = function( selector ) {\n\t\tvar elems,\n\t\t\tret = [],\n\t\t\tinsert = jQuery( selector ),\n\t\t\tlast = insert.length - 1,\n\t\t\ti = 0;\n\n\t\tfor ( ; i <= last; i++ ) {\n\t\t\telems = i === last ? this : this.clone( true );\n\t\t\tjQuery( insert[ i ] )[ original ]( elems );\n\n\t\t\t// Support: Android <=4.0 only, PhantomJS 1 only\n\t\t\t// .get() because push.apply(_, arraylike) throws on ancient WebKit\n\t\t\tpush.apply( ret, elems.get() );\n\t\t}\n\n\t\treturn this.pushStack( ret );\n\t};\n} );\nvar rnumnonpx = new RegExp( \"^(\" + pnum + \")(?!px)[a-z%]+$\", \"i\" );\n\nvar getStyles = function( elem ) {\n\n\t\t// Support: IE <=11 only, Firefox <=30 (#15098, #14150)\n\t\t// IE throws on elements created in popups\n\t\t// FF meanwhile throws on frame elements through \"defaultView.getComputedStyle\"\n\t\tvar view = elem.ownerDocument.defaultView;\n\n\t\tif ( !view || !view.opener ) {\n\t\t\tview = window;\n\t\t}\n\n\t\treturn view.getComputedStyle( elem );\n\t};\n\nvar rboxStyle = new RegExp( cssExpand.join( \"|\" ), \"i\" );\n\n\n\n( function() {\n\n\t// Executing both pixelPosition & boxSizingReliable tests require only one layout\n\t// so they're executed at the same time to save the second computation.\n\tfunction computeStyleTests() {\n\n\t\t// This is a singleton, we need to execute it only once\n\t\tif ( !div ) {\n\t\t\treturn;\n\t\t}\n\n\t\tcontainer.style.cssText = \"position:absolute;left:-11111px;width:60px;\" +\n\t\t\t\"margin-top:1px;padding:0;border:0\";\n\t\tdiv.style.cssText =\n\t\t\t\"position:relative;display:block;box-sizing:border-box;overflow:scroll;\" +\n\t\t\t\"margin:auto;border:1px;padding:1px;\" +\n\t\t\t\"width:60%;top:1%\";\n\t\tdocumentElement.appendChild( container ).appendChild( div );\n\n\t\tvar divStyle = window.getComputedStyle( div );\n\t\tpixelPositionVal = divStyle.top !== \"1%\";\n\n\t\t// Support: Android 4.0 - 4.3 only, Firefox <=3 - 44\n\t\treliableMarginLeftVal = roundPixelMeasures( divStyle.marginLeft ) === 12;\n\n\t\t// Support: Android 4.0 - 4.3 only, Safari <=9.1 - 10.1, iOS <=7.0 - 9.3\n\t\t// Some styles come back with percentage values, even though they shouldn't\n\t\tdiv.style.right = \"60%\";\n\t\tpixelBoxStylesVal = roundPixelMeasures( divStyle.right ) === 36;\n\n\t\t// Support: IE 9 - 11 only\n\t\t// Detect misreporting of content dimensions for box-sizing:border-box elements\n\t\tboxSizingReliableVal = roundPixelMeasures( divStyle.width ) === 36;\n\n\t\t// Support: IE 9 only\n\t\t// Detect overflow:scroll screwiness (gh-3699)\n\t\t// Support: Chrome <=64\n\t\t// Don't get tricked when zoom affects offsetWidth (gh-4029)\n\t\tdiv.style.position = \"absolute\";\n\t\tscrollboxSizeVal = roundPixelMeasures( div.offsetWidth / 3 ) === 12;\n\n\t\tdocumentElement.removeChild( container );\n\n\t\t// Nullify the div so it wouldn't be stored in the memory and\n\t\t// it will also be a sign that checks already performed\n\t\tdiv = null;\n\t}\n\n\tfunction roundPixelMeasures( measure ) {\n\t\treturn Math.round( parseFloat( measure ) );\n\t}\n\n\tvar pixelPositionVal, boxSizingReliableVal, scrollboxSizeVal, pixelBoxStylesVal,\n\t\treliableMarginLeftVal,\n\t\tcontainer = document.createElement( \"div\" ),\n\t\tdiv = document.createElement( \"div\" );\n\n\t// Finish early in limited (non-browser) environments\n\tif ( !div.style ) {\n\t\treturn;\n\t}\n\n\t// Support: IE <=9 - 11 only\n\t// Style of cloned element affects source element cloned (#8908)\n\tdiv.style.backgroundClip = \"content-box\";\n\tdiv.cloneNode( true ).style.backgroundClip = \"\";\n\tsupport.clearCloneStyle = div.style.backgroundClip === \"content-box\";\n\n\tjQuery.extend( support, {\n\t\tboxSizingReliable: function() {\n\t\t\tcomputeStyleTests();\n\t\t\treturn boxSizingReliableVal;\n\t\t},\n\t\tpixelBoxStyles: function() {\n\t\t\tcomputeStyleTests();\n\t\t\treturn pixelBoxStylesVal;\n\t\t},\n\t\tpixelPosition: function() {\n\t\t\tcomputeStyleTests();\n\t\t\treturn pixelPositionVal;\n\t\t},\n\t\treliableMarginLeft: function() {\n\t\t\tcomputeStyleTests();\n\t\t\treturn reliableMarginLeftVal;\n\t\t},\n\t\tscrollboxSize: function() {\n\t\t\tcomputeStyleTests();\n\t\t\treturn scrollboxSizeVal;\n\t\t}\n\t} );\n} )();\n\n\nfunction curCSS( elem, name, computed ) {\n\tvar width, minWidth, maxWidth, ret,\n\n\t\t// Support: Firefox 51+\n\t\t// Retrieving style before computed somehow\n\t\t// fixes an issue with getting wrong values\n\t\t// on detached elements\n\t\tstyle = elem.style;\n\n\tcomputed = computed || getStyles( elem );\n\n\t// getPropertyValue is needed for:\n\t//   .css('filter') (IE 9 only, #12537)\n\t//   .css('--customProperty) (#3144)\n\tif ( computed ) {\n\t\tret = computed.getPropertyValue( name ) || computed[ name ];\n\n\t\tif ( ret === \"\" && !isAttached( elem ) ) {\n\t\t\tret = jQuery.style( elem, name );\n\t\t}\n\n\t\t// A tribute to the \"awesome hack by Dean Edwards\"\n\t\t// Android Browser returns percentage for some values,\n\t\t// but width seems to be reliably pixels.\n\t\t// This is against the CSSOM draft spec:\n\t\t// https://drafts.csswg.org/cssom/#resolved-values\n\t\tif ( !support.pixelBoxStyles() && rnumnonpx.test( ret ) && rboxStyle.test( name ) ) {\n\n\t\t\t// Remember the original values\n\t\t\twidth = style.width;\n\t\t\tminWidth = style.minWidth;\n\t\t\tmaxWidth = style.maxWidth;\n\n\t\t\t// Put in the new values to get a computed value out\n\t\t\tstyle.minWidth = style.maxWidth = style.width = ret;\n\t\t\tret = computed.width;\n\n\t\t\t// Revert the changed values\n\t\t\tstyle.width = width;\n\t\t\tstyle.minWidth = minWidth;\n\t\t\tstyle.maxWidth = maxWidth;\n\t\t}\n\t}\n\n\treturn ret !== undefined ?\n\n\t\t// Support: IE <=9 - 11 only\n\t\t// IE returns zIndex value as an integer.\n\t\tret + \"\" :\n\t\tret;\n}\n\n\nfunction addGetHookIf( conditionFn, hookFn ) {\n\n\t// Define the hook, we'll check on the first run if it's really needed.\n\treturn {\n\t\tget: function() {\n\t\t\tif ( conditionFn() ) {\n\n\t\t\t\t// Hook not needed (or it's not possible to use it due\n\t\t\t\t// to missing dependency), remove it.\n\t\t\t\tdelete this.get;\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// Hook needed; redefine it so that the support test is not executed again.\n\t\t\treturn ( this.get = hookFn ).apply( this, arguments );\n\t\t}\n\t};\n}\n\n\nvar cssPrefixes = [ \"Webkit\", \"Moz\", \"ms\" ],\n\temptyStyle = document.createElement( \"div\" ).style,\n\tvendorProps = {};\n\n// Return a vendor-prefixed property or undefined\nfunction vendorPropName( name ) {\n\n\t// Check for vendor prefixed names\n\tvar capName = name[ 0 ].toUpperCase() + name.slice( 1 ),\n\t\ti = cssPrefixes.length;\n\n\twhile ( i-- ) {\n\t\tname = cssPrefixes[ i ] + capName;\n\t\tif ( name in emptyStyle ) {\n\t\t\treturn name;\n\t\t}\n\t}\n}\n\n// Return a potentially-mapped jQuery.cssProps or vendor prefixed property\nfunction finalPropName( name ) {\n\tvar final = jQuery.cssProps[ name ] || vendorProps[ name ];\n\n\tif ( final ) {\n\t\treturn final;\n\t}\n\tif ( name in emptyStyle ) {\n\t\treturn name;\n\t}\n\treturn vendorProps[ name ] = vendorPropName( name ) || name;\n}\n\n\nvar\n\n\t// Swappable if display is none or starts with table\n\t// except \"table\", \"table-cell\", or \"table-caption\"\n\t// See here for display values: https://developer.mozilla.org/en-US/docs/CSS/display\n\trdisplayswap = /^(none|table(?!-c[ea]).+)/,\n\trcustomProp = /^--/,\n\tcssShow = { position: \"absolute\", visibility: \"hidden\", display: \"block\" },\n\tcssNormalTransform = {\n\t\tletterSpacing: \"0\",\n\t\tfontWeight: \"400\"\n\t};\n\nfunction setPositiveNumber( elem, value, subtract ) {\n\n\t// Any relative (+/-) values have already been\n\t// normalized at this point\n\tvar matches = rcssNum.exec( value );\n\treturn matches ?\n\n\t\t// Guard against undefined \"subtract\", e.g., when used as in cssHooks\n\t\tMath.max( 0, matches[ 2 ] - ( subtract || 0 ) ) + ( matches[ 3 ] || \"px\" ) :\n\t\tvalue;\n}\n\nfunction boxModelAdjustment( elem, dimension, box, isBorderBox, styles, computedVal ) {\n\tvar i = dimension === \"width\" ? 1 : 0,\n\t\textra = 0,\n\t\tdelta = 0;\n\n\t// Adjustment may not be necessary\n\tif ( box === ( isBorderBox ? \"border\" : \"content\" ) ) {\n\t\treturn 0;\n\t}\n\n\tfor ( ; i < 4; i += 2 ) {\n\n\t\t// Both box models exclude margin\n\t\tif ( box === \"margin\" ) {\n\t\t\tdelta += jQuery.css( elem, box + cssExpand[ i ], true, styles );\n\t\t}\n\n\t\t// If we get here with a content-box, we're seeking \"padding\" or \"border\" or \"margin\"\n\t\tif ( !isBorderBox ) {\n\n\t\t\t// Add padding\n\t\t\tdelta += jQuery.css( elem, \"padding\" + cssExpand[ i ], true, styles );\n\n\t\t\t// For \"border\" or \"margin\", add border\n\t\t\tif ( box !== \"padding\" ) {\n\t\t\t\tdelta += jQuery.css( elem, \"border\" + cssExpand[ i ] + \"Width\", true, styles );\n\n\t\t\t// But still keep track of it otherwise\n\t\t\t} else {\n\t\t\t\textra += jQuery.css( elem, \"border\" + cssExpand[ i ] + \"Width\", true, styles );\n\t\t\t}\n\n\t\t// If we get here with a border-box (content + padding + border), we're seeking \"content\" or\n\t\t// \"padding\" or \"margin\"\n\t\t} else {\n\n\t\t\t// For \"content\", subtract padding\n\t\t\tif ( box === \"content\" ) {\n\t\t\t\tdelta -= jQuery.css( elem, \"padding\" + cssExpand[ i ], true, styles );\n\t\t\t}\n\n\t\t\t// For \"content\" or \"padding\", subtract border\n\t\t\tif ( box !== \"margin\" ) {\n\t\t\t\tdelta -= jQuery.css( elem, \"border\" + cssExpand[ i ] + \"Width\", true, styles );\n\t\t\t}\n\t\t}\n\t}\n\n\t// Account for positive content-box scroll gutter when requested by providing computedVal\n\tif ( !isBorderBox && computedVal >= 0 ) {\n\n\t\t// offsetWidth/offsetHeight is a rounded sum of content, padding, scroll gutter, and border\n\t\t// Assuming integer scroll gutter, subtract the rest and round down\n\t\tdelta += Math.max( 0, Math.ceil(\n\t\t\telem[ \"offset\" + dimension[ 0 ].toUpperCase() + dimension.slice( 1 ) ] -\n\t\t\tcomputedVal -\n\t\t\tdelta -\n\t\t\textra -\n\t\t\t0.5\n\n\t\t// If offsetWidth/offsetHeight is unknown, then we can't determine content-box scroll gutter\n\t\t// Use an explicit zero to avoid NaN (gh-3964)\n\t\t) ) || 0;\n\t}\n\n\treturn delta;\n}\n\nfunction getWidthOrHeight( elem, dimension, extra ) {\n\n\t// Start with computed style\n\tvar styles = getStyles( elem ),\n\n\t\t// To avoid forcing a reflow, only fetch boxSizing if we need it (gh-4322).\n\t\t// Fake content-box until we know it's needed to know the true value.\n\t\tboxSizingNeeded = !support.boxSizingReliable() || extra,\n\t\tisBorderBox = boxSizingNeeded &&\n\t\t\tjQuery.css( elem, \"boxSizing\", false, styles ) === \"border-box\",\n\t\tvalueIsBorderBox = isBorderBox,\n\n\t\tval = curCSS( elem, dimension, styles ),\n\t\toffsetProp = \"offset\" + dimension[ 0 ].toUpperCase() + dimension.slice( 1 );\n\n\t// Support: Firefox <=54\n\t// Return a confounding non-pixel value or feign ignorance, as appropriate.\n\tif ( rnumnonpx.test( val ) ) {\n\t\tif ( !extra ) {\n\t\t\treturn val;\n\t\t}\n\t\tval = \"auto\";\n\t}\n\n\n\t// Fall back to offsetWidth/offsetHeight when value is \"auto\"\n\t// This happens for inline elements with no explicit setting (gh-3571)\n\t// Support: Android <=4.1 - 4.3 only\n\t// Also use offsetWidth/offsetHeight for misreported inline dimensions (gh-3602)\n\t// Support: IE 9-11 only\n\t// Also use offsetWidth/offsetHeight for when box sizing is unreliable\n\t// We use getClientRects() to check for hidden/disconnected.\n\t// In those cases, the computed value can be trusted to be border-box\n\tif ( ( !support.boxSizingReliable() && isBorderBox ||\n\t\tval === \"auto\" ||\n\t\t!parseFloat( val ) && jQuery.css( elem, \"display\", false, styles ) === \"inline\" ) &&\n\t\telem.getClientRects().length ) {\n\n\t\tisBorderBox = jQuery.css( elem, \"boxSizing\", false, styles ) === \"border-box\";\n\n\t\t// Where available, offsetWidth/offsetHeight approximate border box dimensions.\n\t\t// Where not available (e.g., SVG), assume unreliable box-sizing and interpret the\n\t\t// retrieved value as a content box dimension.\n\t\tvalueIsBorderBox = offsetProp in elem;\n\t\tif ( valueIsBorderBox ) {\n\t\t\tval = elem[ offsetProp ];\n\t\t}\n\t}\n\n\t// Normalize \"\" and auto\n\tval = parseFloat( val ) || 0;\n\n\t// Adjust for the element's box model\n\treturn ( val +\n\t\tboxModelAdjustment(\n\t\t\telem,\n\t\t\tdimension,\n\t\t\textra || ( isBorderBox ? \"border\" : \"content\" ),\n\t\t\tvalueIsBorderBox,\n\t\t\tstyles,\n\n\t\t\t// Provide the current computed size to request scroll gutter calculation (gh-3589)\n\t\t\tval\n\t\t)\n\t) + \"px\";\n}\n\njQuery.extend( {\n\n\t// Add in style property hooks for overriding the default\n\t// behavior of getting and setting a style property\n\tcssHooks: {\n\t\topacity: {\n\t\t\tget: function( elem, computed ) {\n\t\t\t\tif ( computed ) {\n\n\t\t\t\t\t// We should always get a number back from opacity\n\t\t\t\t\tvar ret = curCSS( elem, \"opacity\" );\n\t\t\t\t\treturn ret === \"\" ? \"1\" : ret;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t},\n\n\t// Don't automatically add \"px\" to these possibly-unitless properties\n\tcssNumber: {\n\t\t\"animationIterationCount\": true,\n\t\t\"columnCount\": true,\n\t\t\"fillOpacity\": true,\n\t\t\"flexGrow\": true,\n\t\t\"flexShrink\": true,\n\t\t\"fontWeight\": true,\n\t\t\"gridArea\": true,\n\t\t\"gridColumn\": true,\n\t\t\"gridColumnEnd\": true,\n\t\t\"gridColumnStart\": true,\n\t\t\"gridRow\": true,\n\t\t\"gridRowEnd\": true,\n\t\t\"gridRowStart\": true,\n\t\t\"lineHeight\": true,\n\t\t\"opacity\": true,\n\t\t\"order\": true,\n\t\t\"orphans\": true,\n\t\t\"widows\": true,\n\t\t\"zIndex\": true,\n\t\t\"zoom\": true\n\t},\n\n\t// Add in properties whose names you wish to fix before\n\t// setting or getting the value\n\tcssProps: {},\n\n\t// Get and set the style property on a DOM Node\n\tstyle: function( elem, name, value, extra ) {\n\n\t\t// Don't set styles on text and comment nodes\n\t\tif ( !elem || elem.nodeType === 3 || elem.nodeType === 8 || !elem.style ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Make sure that we're working with the right name\n\t\tvar ret, type, hooks,\n\t\t\torigName = camelCase( name ),\n\t\t\tisCustomProp = rcustomProp.test( name ),\n\t\t\tstyle = elem.style;\n\n\t\t// Make sure that we're working with the right name. We don't\n\t\t// want to query the value if it is a CSS custom property\n\t\t// since they are user-defined.\n\t\tif ( !isCustomProp ) {\n\t\t\tname = finalPropName( origName );\n\t\t}\n\n\t\t// Gets hook for the prefixed version, then unprefixed version\n\t\thooks = jQuery.cssHooks[ name ] || jQuery.cssHooks[ origName ];\n\n\t\t// Check if we're setting a value\n\t\tif ( value !== undefined ) {\n\t\t\ttype = typeof value;\n\n\t\t\t// Convert \"+=\" or \"-=\" to relative numbers (#7345)\n\t\t\tif ( type === \"string\" && ( ret = rcssNum.exec( value ) ) && ret[ 1 ] ) {\n\t\t\t\tvalue = adjustCSS( elem, name, ret );\n\n\t\t\t\t// Fixes bug #9237\n\t\t\t\ttype = \"number\";\n\t\t\t}\n\n\t\t\t// Make sure that null and NaN values aren't set (#7116)\n\t\t\tif ( value == null || value !== value ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// If a number was passed in, add the unit (except for certain CSS properties)\n\t\t\t// The isCustomProp check can be removed in jQuery 4.0 when we only auto-append\n\t\t\t// \"px\" to a few hardcoded values.\n\t\t\tif ( type === \"number\" && !isCustomProp ) {\n\t\t\t\tvalue += ret && ret[ 3 ] || ( jQuery.cssNumber[ origName ] ? \"\" : \"px\" );\n\t\t\t}\n\n\t\t\t// background-* props affect original clone's values\n\t\t\tif ( !support.clearCloneStyle && value === \"\" && name.indexOf( \"background\" ) === 0 ) {\n\t\t\t\tstyle[ name ] = \"inherit\";\n\t\t\t}\n\n\t\t\t// If a hook was provided, use that value, otherwise just set the specified value\n\t\t\tif ( !hooks || !( \"set\" in hooks ) ||\n\t\t\t\t( value = hooks.set( elem, value, extra ) ) !== undefined ) {\n\n\t\t\t\tif ( isCustomProp ) {\n\t\t\t\t\tstyle.setProperty( name, value );\n\t\t\t\t} else {\n\t\t\t\t\tstyle[ name ] = value;\n\t\t\t\t}\n\t\t\t}\n\n\t\t} else {\n\n\t\t\t// If a hook was provided get the non-computed value from there\n\t\t\tif ( hooks && \"get\" in hooks &&\n\t\t\t\t( ret = hooks.get( elem, false, extra ) ) !== undefined ) {\n\n\t\t\t\treturn ret;\n\t\t\t}\n\n\t\t\t// Otherwise just get the value from the style object\n\t\t\treturn style[ name ];\n\t\t}\n\t},\n\n\tcss: function( elem, name, extra, styles ) {\n\t\tvar val, num, hooks,\n\t\t\torigName = camelCase( name ),\n\t\t\tisCustomProp = rcustomProp.test( name );\n\n\t\t// Make sure that we're working with the right name. We don't\n\t\t// want to modify the value if it is a CSS custom property\n\t\t// since they are user-defined.\n\t\tif ( !isCustomProp ) {\n\t\t\tname = finalPropName( origName );\n\t\t}\n\n\t\t// Try prefixed name followed by the unprefixed name\n\t\thooks = jQuery.cssHooks[ name ] || jQuery.cssHooks[ origName ];\n\n\t\t// If a hook was provided get the computed value from there\n\t\tif ( hooks && \"get\" in hooks ) {\n\t\t\tval = hooks.get( elem, true, extra );\n\t\t}\n\n\t\t// Otherwise, if a way to get the computed value exists, use that\n\t\tif ( val === undefined ) {\n\t\t\tval = curCSS( elem, name, styles );\n\t\t}\n\n\t\t// Convert \"normal\" to computed value\n\t\tif ( val === \"normal\" && name in cssNormalTransform ) {\n\t\t\tval = cssNormalTransform[ name ];\n\t\t}\n\n\t\t// Make numeric if forced or a qualifier was provided and val looks numeric\n\t\tif ( extra === \"\" || extra ) {\n\t\t\tnum = parseFloat( val );\n\t\t\treturn extra === true || isFinite( num ) ? num || 0 : val;\n\t\t}\n\n\t\treturn val;\n\t}\n} );\n\njQuery.each( [ \"height\", \"width\" ], function( i, dimension ) {\n\tjQuery.cssHooks[ dimension ] = {\n\t\tget: function( elem, computed, extra ) {\n\t\t\tif ( computed ) {\n\n\t\t\t\t// Certain elements can have dimension info if we invisibly show them\n\t\t\t\t// but it must have a current display style that would benefit\n\t\t\t\treturn rdisplayswap.test( jQuery.css( elem, \"display\" ) ) &&\n\n\t\t\t\t\t// Support: Safari 8+\n\t\t\t\t\t// Table columns in Safari have non-zero offsetWidth & zero\n\t\t\t\t\t// getBoundingClientRect().width unless display is changed.\n\t\t\t\t\t// Support: IE <=11 only\n\t\t\t\t\t// Running getBoundingClientRect on a disconnected node\n\t\t\t\t\t// in IE throws an error.\n\t\t\t\t\t( !elem.getClientRects().length || !elem.getBoundingClientRect().width ) ?\n\t\t\t\t\t\tswap( elem, cssShow, function() {\n\t\t\t\t\t\t\treturn getWidthOrHeight( elem, dimension, extra );\n\t\t\t\t\t\t} ) :\n\t\t\t\t\t\tgetWidthOrHeight( elem, dimension, extra );\n\t\t\t}\n\t\t},\n\n\t\tset: function( elem, value, extra ) {\n\t\t\tvar matches,\n\t\t\t\tstyles = getStyles( elem ),\n\n\t\t\t\t// Only read styles.position if the test has a chance to fail\n\t\t\t\t// to avoid forcing a reflow.\n\t\t\t\tscrollboxSizeBuggy = !support.scrollboxSize() &&\n\t\t\t\t\tstyles.position === \"absolute\",\n\n\t\t\t\t// To avoid forcing a reflow, only fetch boxSizing if we need it (gh-3991)\n\t\t\t\tboxSizingNeeded = scrollboxSizeBuggy || extra,\n\t\t\t\tisBorderBox = boxSizingNeeded &&\n\t\t\t\t\tjQuery.css( elem, \"boxSizing\", false, styles ) === \"border-box\",\n\t\t\t\tsubtract = extra ?\n\t\t\t\t\tboxModelAdjustment(\n\t\t\t\t\t\telem,\n\t\t\t\t\t\tdimension,\n\t\t\t\t\t\textra,\n\t\t\t\t\t\tisBorderBox,\n\t\t\t\t\t\tstyles\n\t\t\t\t\t) :\n\t\t\t\t\t0;\n\n\t\t\t// Account for unreliable border-box dimensions by comparing offset* to computed and\n\t\t\t// faking a content-box to get border and padding (gh-3699)\n\t\t\tif ( isBorderBox && scrollboxSizeBuggy ) {\n\t\t\t\tsubtract -= Math.ceil(\n\t\t\t\t\telem[ \"offset\" + dimension[ 0 ].toUpperCase() + dimension.slice( 1 ) ] -\n\t\t\t\t\tparseFloat( styles[ dimension ] ) -\n\t\t\t\t\tboxModelAdjustment( elem, dimension, \"border\", false, styles ) -\n\t\t\t\t\t0.5\n\t\t\t\t);\n\t\t\t}\n\n\t\t\t// Convert to pixels if value adjustment is needed\n\t\t\tif ( subtract && ( matches = rcssNum.exec( value ) ) &&\n\t\t\t\t( matches[ 3 ] || \"px\" ) !== \"px\" ) {\n\n\t\t\t\telem.style[ dimension ] = value;\n\t\t\t\tvalue = jQuery.css( elem, dimension );\n\t\t\t}\n\n\t\t\treturn setPositiveNumber( elem, value, subtract );\n\t\t}\n\t};\n} );\n\njQuery.cssHooks.marginLeft = addGetHookIf( support.reliableMarginLeft,\n\tfunction( elem, computed ) {\n\t\tif ( computed ) {\n\t\t\treturn ( parseFloat( curCSS( elem, \"marginLeft\" ) ) ||\n\t\t\t\telem.getBoundingClientRect().left -\n\t\t\t\t\tswap( elem, { marginLeft: 0 }, function() {\n\t\t\t\t\t\treturn elem.getBoundingClientRect().left;\n\t\t\t\t\t} )\n\t\t\t\t) + \"px\";\n\t\t}\n\t}\n);\n\n// These hooks are used by animate to expand properties\njQuery.each( {\n\tmargin: \"\",\n\tpadding: \"\",\n\tborder: \"Width\"\n}, function( prefix, suffix ) {\n\tjQuery.cssHooks[ prefix + suffix ] = {\n\t\texpand: function( value ) {\n\t\t\tvar i = 0,\n\t\t\t\texpanded = {},\n\n\t\t\t\t// Assumes a single number if not a string\n\t\t\t\tparts = typeof value === \"string\" ? value.split( \" \" ) : [ value ];\n\n\t\t\tfor ( ; i < 4; i++ ) {\n\t\t\t\texpanded[ prefix + cssExpand[ i ] + suffix ] =\n\t\t\t\t\tparts[ i ] || parts[ i - 2 ] || parts[ 0 ];\n\t\t\t}\n\n\t\t\treturn expanded;\n\t\t}\n\t};\n\n\tif ( prefix !== \"margin\" ) {\n\t\tjQuery.cssHooks[ prefix + suffix ].set = setPositiveNumber;\n\t}\n} );\n\njQuery.fn.extend( {\n\tcss: function( name, value ) {\n\t\treturn access( this, function( elem, name, value ) {\n\t\t\tvar styles, len,\n\t\t\t\tmap = {},\n\t\t\t\ti = 0;\n\n\t\t\tif ( Array.isArray( name ) ) {\n\t\t\t\tstyles = getStyles( elem );\n\t\t\t\tlen = name.length;\n\n\t\t\t\tfor ( ; i < len; i++ ) {\n\t\t\t\t\tmap[ name[ i ] ] = jQuery.css( elem, name[ i ], false, styles );\n\t\t\t\t}\n\n\t\t\t\treturn map;\n\t\t\t}\n\n\t\t\treturn value !== undefined ?\n\t\t\t\tjQuery.style( elem, name, value ) :\n\t\t\t\tjQuery.css( elem, name );\n\t\t}, name, value, arguments.length > 1 );\n\t}\n} );\n\n\nfunction Tween( elem, options, prop, end, easing ) {\n\treturn new Tween.prototype.init( elem, options, prop, end, easing );\n}\njQuery.Tween = Tween;\n\nTween.prototype = {\n\tconstructor: Tween,\n\tinit: function( elem, options, prop, end, easing, unit ) {\n\t\tthis.elem = elem;\n\t\tthis.prop = prop;\n\t\tthis.easing = easing || jQuery.easing._default;\n\t\tthis.options = options;\n\t\tthis.start = this.now = this.cur();\n\t\tthis.end = end;\n\t\tthis.unit = unit || ( jQuery.cssNumber[ prop ] ? \"\" : \"px\" );\n\t},\n\tcur: function() {\n\t\tvar hooks = Tween.propHooks[ this.prop ];\n\n\t\treturn hooks && hooks.get ?\n\t\t\thooks.get( this ) :\n\t\t\tTween.propHooks._default.get( this );\n\t},\n\trun: function( percent ) {\n\t\tvar eased,\n\t\t\thooks = Tween.propHooks[ this.prop ];\n\n\t\tif ( this.options.duration ) {\n\t\t\tthis.pos = eased = jQuery.easing[ this.easing ](\n\t\t\t\tpercent, this.options.duration * percent, 0, 1, this.options.duration\n\t\t\t);\n\t\t} else {\n\t\t\tthis.pos = eased = percent;\n\t\t}\n\t\tthis.now = ( this.end - this.start ) * eased + this.start;\n\n\t\tif ( this.options.step ) {\n\t\t\tthis.options.step.call( this.elem, this.now, this );\n\t\t}\n\n\t\tif ( hooks && hooks.set ) {\n\t\t\thooks.set( this );\n\t\t} else {\n\t\t\tTween.propHooks._default.set( this );\n\t\t}\n\t\treturn this;\n\t}\n};\n\nTween.prototype.init.prototype = Tween.prototype;\n\nTween.propHooks = {\n\t_default: {\n\t\tget: function( tween ) {\n\t\t\tvar result;\n\n\t\t\t// Use a property on the element directly when it is not a DOM element,\n\t\t\t// or when there is no matching style property that exists.\n\t\t\tif ( tween.elem.nodeType !== 1 ||\n\t\t\t\ttween.elem[ tween.prop ] != null && tween.elem.style[ tween.prop ] == null ) {\n\t\t\t\treturn tween.elem[ tween.prop ];\n\t\t\t}\n\n\t\t\t// Passing an empty string as a 3rd parameter to .css will automatically\n\t\t\t// attempt a parseFloat and fallback to a string if the parse fails.\n\t\t\t// Simple values such as \"10px\" are parsed to Float;\n\t\t\t// complex values such as \"rotate(1rad)\" are returned as-is.\n\t\t\tresult = jQuery.css( tween.elem, tween.prop, \"\" );\n\n\t\t\t// Empty strings, null, undefined and \"auto\" are converted to 0.\n\t\t\treturn !result || result === \"auto\" ? 0 : result;\n\t\t},\n\t\tset: function( tween ) {\n\n\t\t\t// Use step hook for back compat.\n\t\t\t// Use cssHook if its there.\n\t\t\t// Use .style if available and use plain properties where available.\n\t\t\tif ( jQuery.fx.step[ tween.prop ] ) {\n\t\t\t\tjQuery.fx.step[ tween.prop ]( tween );\n\t\t\t} else if ( tween.elem.nodeType === 1 && (\n\t\t\t\t\tjQuery.cssHooks[ tween.prop ] ||\n\t\t\t\t\ttween.elem.style[ finalPropName( tween.prop ) ] != null ) ) {\n\t\t\t\tjQuery.style( tween.elem, tween.prop, tween.now + tween.unit );\n\t\t\t} else {\n\t\t\t\ttween.elem[ tween.prop ] = tween.now;\n\t\t\t}\n\t\t}\n\t}\n};\n\n// Support: IE <=9 only\n// Panic based approach to setting things on disconnected nodes\nTween.propHooks.scrollTop = Tween.propHooks.scrollLeft = {\n\tset: function( tween ) {\n\t\tif ( tween.elem.nodeType && tween.elem.parentNode ) {\n\t\t\ttween.elem[ tween.prop ] = tween.now;\n\t\t}\n\t}\n};\n\njQuery.easing = {\n\tlinear: function( p ) {\n\t\treturn p;\n\t},\n\tswing: function( p ) {\n\t\treturn 0.5 - Math.cos( p * Math.PI ) / 2;\n\t},\n\t_default: \"swing\"\n};\n\njQuery.fx = Tween.prototype.init;\n\n// Back compat <1.8 extension point\njQuery.fx.step = {};\n\n\n\n\nvar\n\tfxNow, inProgress,\n\trfxtypes = /^(?:toggle|show|hide)$/,\n\trrun = /queueHooks$/;\n\nfunction schedule() {\n\tif ( inProgress ) {\n\t\tif ( document.hidden === false && window.requestAnimationFrame ) {\n\t\t\twindow.requestAnimationFrame( schedule );\n\t\t} else {\n\t\t\twindow.setTimeout( schedule, jQuery.fx.interval );\n\t\t}\n\n\t\tjQuery.fx.tick();\n\t}\n}\n\n// Animations created synchronously will run synchronously\nfunction createFxNow() {\n\twindow.setTimeout( function() {\n\t\tfxNow = undefined;\n\t} );\n\treturn ( fxNow = Date.now() );\n}\n\n// Generate parameters to create a standard animation\nfunction genFx( type, includeWidth ) {\n\tvar which,\n\t\ti = 0,\n\t\tattrs = { height: type };\n\n\t// If we include width, step value is 1 to do all cssExpand values,\n\t// otherwise step value is 2 to skip over Left and Right\n\tincludeWidth = includeWidth ? 1 : 0;\n\tfor ( ; i < 4; i += 2 - includeWidth ) {\n\t\twhich = cssExpand[ i ];\n\t\tattrs[ \"margin\" + which ] = attrs[ \"padding\" + which ] = type;\n\t}\n\n\tif ( includeWidth ) {\n\t\tattrs.opacity = attrs.width = type;\n\t}\n\n\treturn attrs;\n}\n\nfunction createTween( value, prop, animation ) {\n\tvar tween,\n\t\tcollection = ( Animation.tweeners[ prop ] || [] ).concat( Animation.tweeners[ \"*\" ] ),\n\t\tindex = 0,\n\t\tlength = collection.length;\n\tfor ( ; index < length; index++ ) {\n\t\tif ( ( tween = collection[ index ].call( animation, prop, value ) ) ) {\n\n\t\t\t// We're done with this property\n\t\t\treturn tween;\n\t\t}\n\t}\n}\n\nfunction defaultPrefilter( elem, props, opts ) {\n\tvar prop, value, toggle, hooks, oldfire, propTween, restoreDisplay, display,\n\t\tisBox = \"width\" in props || \"height\" in props,\n\t\tanim = this,\n\t\torig = {},\n\t\tstyle = elem.style,\n\t\thidden = elem.nodeType && isHiddenWithinTree( elem ),\n\t\tdataShow = dataPriv.get( elem, \"fxshow\" );\n\n\t// Queue-skipping animations hijack the fx hooks\n\tif ( !opts.queue ) {\n\t\thooks = jQuery._queueHooks( elem, \"fx\" );\n\t\tif ( hooks.unqueued == null ) {\n\t\t\thooks.unqueued = 0;\n\t\t\toldfire = hooks.empty.fire;\n\t\t\thooks.empty.fire = function() {\n\t\t\t\tif ( !hooks.unqueued ) {\n\t\t\t\t\toldfire();\n\t\t\t\t}\n\t\t\t};\n\t\t}\n\t\thooks.unqueued++;\n\n\t\tanim.always( function() {\n\n\t\t\t// Ensure the complete handler is called before this completes\n\t\t\tanim.always( function() {\n\t\t\t\thooks.unqueued--;\n\t\t\t\tif ( !jQuery.queue( elem, \"fx\" ).length ) {\n\t\t\t\t\thooks.empty.fire();\n\t\t\t\t}\n\t\t\t} );\n\t\t} );\n\t}\n\n\t// Detect show/hide animations\n\tfor ( prop in props ) {\n\t\tvalue = props[ prop ];\n\t\tif ( rfxtypes.test( value ) ) {\n\t\t\tdelete props[ prop ];\n\t\t\ttoggle = toggle || value === \"toggle\";\n\t\t\tif ( value === ( hidden ? \"hide\" : \"show\" ) ) {\n\n\t\t\t\t// Pretend to be hidden if this is a \"show\" and\n\t\t\t\t// there is still data from a stopped show/hide\n\t\t\t\tif ( value === \"show\" && dataShow && dataShow[ prop ] !== undefined ) {\n\t\t\t\t\thidden = true;\n\n\t\t\t\t// Ignore all other no-op show/hide data\n\t\t\t\t} else {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\t\t\torig[ prop ] = dataShow && dataShow[ prop ] || jQuery.style( elem, prop );\n\t\t}\n\t}\n\n\t// Bail out if this is a no-op like .hide().hide()\n\tpropTween = !jQuery.isEmptyObject( props );\n\tif ( !propTween && jQuery.isEmptyObject( orig ) ) {\n\t\treturn;\n\t}\n\n\t// Restrict \"overflow\" and \"display\" styles during box animations\n\tif ( isBox && elem.nodeType === 1 ) {\n\n\t\t// Support: IE <=9 - 11, Edge 12 - 15\n\t\t// Record all 3 overflow attributes because IE does not infer the shorthand\n\t\t// from identically-valued overflowX and overflowY and Edge just mirrors\n\t\t// the overflowX value there.\n\t\topts.overflow = [ style.overflow, style.overflowX, style.overflowY ];\n\n\t\t// Identify a display type, preferring old show/hide data over the CSS cascade\n\t\trestoreDisplay = dataShow && dataShow.display;\n\t\tif ( restoreDisplay == null ) {\n\t\t\trestoreDisplay = dataPriv.get( elem, \"display\" );\n\t\t}\n\t\tdisplay = jQuery.css( elem, \"display\" );\n\t\tif ( display === \"none\" ) {\n\t\t\tif ( restoreDisplay ) {\n\t\t\t\tdisplay = restoreDisplay;\n\t\t\t} else {\n\n\t\t\t\t// Get nonempty value(s) by temporarily forcing visibility\n\t\t\t\tshowHide( [ elem ], true );\n\t\t\t\trestoreDisplay = elem.style.display || restoreDisplay;\n\t\t\t\tdisplay = jQuery.css( elem, \"display\" );\n\t\t\t\tshowHide( [ elem ] );\n\t\t\t}\n\t\t}\n\n\t\t// Animate inline elements as inline-block\n\t\tif ( display === \"inline\" || display === \"inline-block\" && restoreDisplay != null ) {\n\t\t\tif ( jQuery.css( elem, \"float\" ) === \"none\" ) {\n\n\t\t\t\t// Restore the original display value at the end of pure show/hide animations\n\t\t\t\tif ( !propTween ) {\n\t\t\t\t\tanim.done( function() {\n\t\t\t\t\t\tstyle.display = restoreDisplay;\n\t\t\t\t\t} );\n\t\t\t\t\tif ( restoreDisplay == null ) {\n\t\t\t\t\t\tdisplay = style.display;\n\t\t\t\t\t\trestoreDisplay = display === \"none\" ? \"\" : display;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tstyle.display = \"inline-block\";\n\t\t\t}\n\t\t}\n\t}\n\n\tif ( opts.overflow ) {\n\t\tstyle.overflow = \"hidden\";\n\t\tanim.always( function() {\n\t\t\tstyle.overflow = opts.overflow[ 0 ];\n\t\t\tstyle.overflowX = opts.overflow[ 1 ];\n\t\t\tstyle.overflowY = opts.overflow[ 2 ];\n\t\t} );\n\t}\n\n\t// Implement show/hide animations\n\tpropTween = false;\n\tfor ( prop in orig ) {\n\n\t\t// General show/hide setup for this element animation\n\t\tif ( !propTween ) {\n\t\t\tif ( dataShow ) {\n\t\t\t\tif ( \"hidden\" in dataShow ) {\n\t\t\t\t\thidden = dataShow.hidden;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tdataShow = dataPriv.access( elem, \"fxshow\", { display: restoreDisplay } );\n\t\t\t}\n\n\t\t\t// Store hidden/visible for toggle so `.stop().toggle()` \"reverses\"\n\t\t\tif ( toggle ) {\n\t\t\t\tdataShow.hidden = !hidden;\n\t\t\t}\n\n\t\t\t// Show elements before animating them\n\t\t\tif ( hidden ) {\n\t\t\t\tshowHide( [ elem ], true );\n\t\t\t}\n\n\t\t\t/* eslint-disable no-loop-func */\n\n\t\t\tanim.done( function() {\n\n\t\t\t/* eslint-enable no-loop-func */\n\n\t\t\t\t// The final step of a \"hide\" animation is actually hiding the element\n\t\t\t\tif ( !hidden ) {\n\t\t\t\t\tshowHide( [ elem ] );\n\t\t\t\t}\n\t\t\t\tdataPriv.remove( elem, \"fxshow\" );\n\t\t\t\tfor ( prop in orig ) {\n\t\t\t\t\tjQuery.style( elem, prop, orig[ prop ] );\n\t\t\t\t}\n\t\t\t} );\n\t\t}\n\n\t\t// Per-property setup\n\t\tpropTween = createTween( hidden ? dataShow[ prop ] : 0, prop, anim );\n\t\tif ( !( prop in dataShow ) ) {\n\t\t\tdataShow[ prop ] = propTween.start;\n\t\t\tif ( hidden ) {\n\t\t\t\tpropTween.end = propTween.start;\n\t\t\t\tpropTween.start = 0;\n\t\t\t}\n\t\t}\n\t}\n}\n\nfunction propFilter( props, specialEasing ) {\n\tvar index, name, easing, value, hooks;\n\n\t// camelCase, specialEasing and expand cssHook pass\n\tfor ( index in props ) {\n\t\tname = camelCase( index );\n\t\teasing = specialEasing[ name ];\n\t\tvalue = props[ index ];\n\t\tif ( Array.isArray( value ) ) {\n\t\t\teasing = value[ 1 ];\n\t\t\tvalue = props[ index ] = value[ 0 ];\n\t\t}\n\n\t\tif ( index !== name ) {\n\t\t\tprops[ name ] = value;\n\t\t\tdelete props[ index ];\n\t\t}\n\n\t\thooks = jQuery.cssHooks[ name ];\n\t\tif ( hooks && \"expand\" in hooks ) {\n\t\t\tvalue = hooks.expand( value );\n\t\t\tdelete props[ name ];\n\n\t\t\t// Not quite $.extend, this won't overwrite existing keys.\n\t\t\t// Reusing 'index' because we have the correct \"name\"\n\t\t\tfor ( index in value ) {\n\t\t\t\tif ( !( index in props ) ) {\n\t\t\t\t\tprops[ index ] = value[ index ];\n\t\t\t\t\tspecialEasing[ index ] = easing;\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\tspecialEasing[ name ] = easing;\n\t\t}\n\t}\n}\n\nfunction Animation( elem, properties, options ) {\n\tvar result,\n\t\tstopped,\n\t\tindex = 0,\n\t\tlength = Animation.prefilters.length,\n\t\tdeferred = jQuery.Deferred().always( function() {\n\n\t\t\t// Don't match elem in the :animated selector\n\t\t\tdelete tick.elem;\n\t\t} ),\n\t\ttick = function() {\n\t\t\tif ( stopped ) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\tvar currentTime = fxNow || createFxNow(),\n\t\t\t\tremaining = Math.max( 0, animation.startTime + animation.duration - currentTime ),\n\n\t\t\t\t// Support: Android 2.3 only\n\t\t\t\t// Archaic crash bug won't allow us to use `1 - ( 0.5 || 0 )` (#12497)\n\t\t\t\ttemp = remaining / animation.duration || 0,\n\t\t\t\tpercent = 1 - temp,\n\t\t\t\tindex = 0,\n\t\t\t\tlength = animation.tweens.length;\n\n\t\t\tfor ( ; index < length; index++ ) {\n\t\t\t\tanimation.tweens[ index ].run( percent );\n\t\t\t}\n\n\t\t\tdeferred.notifyWith( elem, [ animation, percent, remaining ] );\n\n\t\t\t// If there's more to do, yield\n\t\t\tif ( percent < 1 && length ) {\n\t\t\t\treturn remaining;\n\t\t\t}\n\n\t\t\t// If this was an empty animation, synthesize a final progress notification\n\t\t\tif ( !length ) {\n\t\t\t\tdeferred.notifyWith( elem, [ animation, 1, 0 ] );\n\t\t\t}\n\n\t\t\t// Resolve the animation and report its conclusion\n\t\t\tdeferred.resolveWith( elem, [ animation ] );\n\t\t\treturn false;\n\t\t},\n\t\tanimation = deferred.promise( {\n\t\t\telem: elem,\n\t\t\tprops: jQuery.extend( {}, properties ),\n\t\t\topts: jQuery.extend( true, {\n\t\t\t\tspecialEasing: {},\n\t\t\t\teasing: jQuery.easing._default\n\t\t\t}, options ),\n\t\t\toriginalProperties: properties,\n\t\t\toriginalOptions: options,\n\t\t\tstartTime: fxNow || createFxNow(),\n\t\t\tduration: options.duration,\n\t\t\ttweens: [],\n\t\t\tcreateTween: function( prop, end ) {\n\t\t\t\tvar tween = jQuery.Tween( elem, animation.opts, prop, end,\n\t\t\t\t\t\tanimation.opts.specialEasing[ prop ] || animation.opts.easing );\n\t\t\t\tanimation.tweens.push( tween );\n\t\t\t\treturn tween;\n\t\t\t},\n\t\t\tstop: function( gotoEnd ) {\n\t\t\t\tvar index = 0,\n\n\t\t\t\t\t// If we are going to the end, we want to run all the tweens\n\t\t\t\t\t// otherwise we skip this part\n\t\t\t\t\tlength = gotoEnd ? animation.tweens.length : 0;\n\t\t\t\tif ( stopped ) {\n\t\t\t\t\treturn this;\n\t\t\t\t}\n\t\t\t\tstopped = true;\n\t\t\t\tfor ( ; index < length; index++ ) {\n\t\t\t\t\tanimation.tweens[ index ].run( 1 );\n\t\t\t\t}\n\n\t\t\t\t// Resolve when we played the last frame; otherwise, reject\n\t\t\t\tif ( gotoEnd ) {\n\t\t\t\t\tdeferred.notifyWith( elem, [ animation, 1, 0 ] );\n\t\t\t\t\tdeferred.resolveWith( elem, [ animation, gotoEnd ] );\n\t\t\t\t} else {\n\t\t\t\t\tdeferred.rejectWith( elem, [ animation, gotoEnd ] );\n\t\t\t\t}\n\t\t\t\treturn this;\n\t\t\t}\n\t\t} ),\n\t\tprops = animation.props;\n\n\tpropFilter( props, animation.opts.specialEasing );\n\n\tfor ( ; index < length; index++ ) {\n\t\tresult = Animation.prefilters[ index ].call( animation, elem, props, animation.opts );\n\t\tif ( result ) {\n\t\t\tif ( isFunction( result.stop ) ) {\n\t\t\t\tjQuery._queueHooks( animation.elem, animation.opts.queue ).stop =\n\t\t\t\t\tresult.stop.bind( result );\n\t\t\t}\n\t\t\treturn result;\n\t\t}\n\t}\n\n\tjQuery.map( props, createTween, animation );\n\n\tif ( isFunction( animation.opts.start ) ) {\n\t\tanimation.opts.start.call( elem, animation );\n\t}\n\n\t// Attach callbacks from options\n\tanimation\n\t\t.progress( animation.opts.progress )\n\t\t.done( animation.opts.done, animation.opts.complete )\n\t\t.fail( animation.opts.fail )\n\t\t.always( animation.opts.always );\n\n\tjQuery.fx.timer(\n\t\tjQuery.extend( tick, {\n\t\t\telem: elem,\n\t\t\tanim: animation,\n\t\t\tqueue: animation.opts.queue\n\t\t} )\n\t);\n\n\treturn animation;\n}\n\njQuery.Animation = jQuery.extend( Animation, {\n\n\ttweeners: {\n\t\t\"*\": [ function( prop, value ) {\n\t\t\tvar tween = this.createTween( prop, value );\n\t\t\tadjustCSS( tween.elem, prop, rcssNum.exec( value ), tween );\n\t\t\treturn tween;\n\t\t} ]\n\t},\n\n\ttweener: function( props, callback ) {\n\t\tif ( isFunction( props ) ) {\n\t\t\tcallback = props;\n\t\t\tprops = [ \"*\" ];\n\t\t} else {\n\t\t\tprops = props.match( rnothtmlwhite );\n\t\t}\n\n\t\tvar prop,\n\t\t\tindex = 0,\n\t\t\tlength = props.length;\n\n\t\tfor ( ; index < length; index++ ) {\n\t\t\tprop = props[ index ];\n\t\t\tAnimation.tweeners[ prop ] = Animation.tweeners[ prop ] || [];\n\t\t\tAnimation.tweeners[ prop ].unshift( callback );\n\t\t}\n\t},\n\n\tprefilters: [ defaultPrefilter ],\n\n\tprefilter: function( callback, prepend ) {\n\t\tif ( prepend ) {\n\t\t\tAnimation.prefilters.unshift( callback );\n\t\t} else {\n\t\t\tAnimation.prefilters.push( callback );\n\t\t}\n\t}\n} );\n\njQuery.speed = function( speed, easing, fn ) {\n\tvar opt = speed && typeof speed === \"object\" ? jQuery.extend( {}, speed ) : {\n\t\tcomplete: fn || !fn && easing ||\n\t\t\tisFunction( speed ) && speed,\n\t\tduration: speed,\n\t\teasing: fn && easing || easing && !isFunction( easing ) && easing\n\t};\n\n\t// Go to the end state if fx are off\n\tif ( jQuery.fx.off ) {\n\t\topt.duration = 0;\n\n\t} else {\n\t\tif ( typeof opt.duration !== \"number\" ) {\n\t\t\tif ( opt.duration in jQuery.fx.speeds ) {\n\t\t\t\topt.duration = jQuery.fx.speeds[ opt.duration ];\n\n\t\t\t} else {\n\t\t\t\topt.duration = jQuery.fx.speeds._default;\n\t\t\t}\n\t\t}\n\t}\n\n\t// Normalize opt.queue - true/undefined/null -> \"fx\"\n\tif ( opt.queue == null || opt.queue === true ) {\n\t\topt.queue = \"fx\";\n\t}\n\n\t// Queueing\n\topt.old = opt.complete;\n\n\topt.complete = function() {\n\t\tif ( isFunction( opt.old ) ) {\n\t\t\topt.old.call( this );\n\t\t}\n\n\t\tif ( opt.queue ) {\n\t\t\tjQuery.dequeue( this, opt.queue );\n\t\t}\n\t};\n\n\treturn opt;\n};\n\njQuery.fn.extend( {\n\tfadeTo: function( speed, to, easing, callback ) {\n\n\t\t// Show any hidden elements after setting opacity to 0\n\t\treturn this.filter( isHiddenWithinTree ).css( \"opacity\", 0 ).show()\n\n\t\t\t// Animate to the value specified\n\t\t\t.end().animate( { opacity: to }, speed, easing, callback );\n\t},\n\tanimate: function( prop, speed, easing, callback ) {\n\t\tvar empty = jQuery.isEmptyObject( prop ),\n\t\t\toptall = jQuery.speed( speed, easing, callback ),\n\t\t\tdoAnimation = function() {\n\n\t\t\t\t// Operate on a copy of prop so per-property easing won't be lost\n\t\t\t\tvar anim = Animation( this, jQuery.extend( {}, prop ), optall );\n\n\t\t\t\t// Empty animations, or finishing resolves immediately\n\t\t\t\tif ( empty || dataPriv.get( this, \"finish\" ) ) {\n\t\t\t\t\tanim.stop( true );\n\t\t\t\t}\n\t\t\t};\n\t\t\tdoAnimation.finish = doAnimation;\n\n\t\treturn empty || optall.queue === false ?\n\t\t\tthis.each( doAnimation ) :\n\t\t\tthis.queue( optall.queue, doAnimation );\n\t},\n\tstop: function( type, clearQueue, gotoEnd ) {\n\t\tvar stopQueue = function( hooks ) {\n\t\t\tvar stop = hooks.stop;\n\t\t\tdelete hooks.stop;\n\t\t\tstop( gotoEnd );\n\t\t};\n\n\t\tif ( typeof type !== \"string\" ) {\n\t\t\tgotoEnd = clearQueue;\n\t\t\tclearQueue = type;\n\t\t\ttype = undefined;\n\t\t}\n\t\tif ( clearQueue && type !== false ) {\n\t\t\tthis.queue( type || \"fx\", [] );\n\t\t}\n\n\t\treturn this.each( function() {\n\t\t\tvar dequeue = true,\n\t\t\t\tindex = type != null && type + \"queueHooks\",\n\t\t\t\ttimers = jQuery.timers,\n\t\t\t\tdata = dataPriv.get( this );\n\n\t\t\tif ( index ) {\n\t\t\t\tif ( data[ index ] && data[ index ].stop ) {\n\t\t\t\t\tstopQueue( data[ index ] );\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tfor ( index in data ) {\n\t\t\t\t\tif ( data[ index ] && data[ index ].stop && rrun.test( index ) ) {\n\t\t\t\t\t\tstopQueue( data[ index ] );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tfor ( index = timers.length; index--; ) {\n\t\t\t\tif ( timers[ index ].elem === this &&\n\t\t\t\t\t( type == null || timers[ index ].queue === type ) ) {\n\n\t\t\t\t\ttimers[ index ].anim.stop( gotoEnd );\n\t\t\t\t\tdequeue = false;\n\t\t\t\t\ttimers.splice( index, 1 );\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Start the next in the queue if the last step wasn't forced.\n\t\t\t// Timers currently will call their complete callbacks, which\n\t\t\t// will dequeue but only if they were gotoEnd.\n\t\t\tif ( dequeue || !gotoEnd ) {\n\t\t\t\tjQuery.dequeue( this, type );\n\t\t\t}\n\t\t} );\n\t},\n\tfinish: function( type ) {\n\t\tif ( type !== false ) {\n\t\t\ttype = type || \"fx\";\n\t\t}\n\t\treturn this.each( function() {\n\t\t\tvar index,\n\t\t\t\tdata = dataPriv.get( this ),\n\t\t\t\tqueue = data[ type + \"queue\" ],\n\t\t\t\thooks = data[ type + \"queueHooks\" ],\n\t\t\t\ttimers = jQuery.timers,\n\t\t\t\tlength = queue ? queue.length : 0;\n\n\t\t\t// Enable finishing flag on private data\n\t\t\tdata.finish = true;\n\n\t\t\t// Empty the queue first\n\t\t\tjQuery.queue( this, type, [] );\n\n\t\t\tif ( hooks && hooks.stop ) {\n\t\t\t\thooks.stop.call( this, true );\n\t\t\t}\n\n\t\t\t// Look for any active animations, and finish them\n\t\t\tfor ( index = timers.length; index--; ) {\n\t\t\t\tif ( timers[ index ].elem === this && timers[ index ].queue === type ) {\n\t\t\t\t\ttimers[ index ].anim.stop( true );\n\t\t\t\t\ttimers.splice( index, 1 );\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Look for any animations in the old queue and finish them\n\t\t\tfor ( index = 0; index < length; index++ ) {\n\t\t\t\tif ( queue[ index ] && queue[ index ].finish ) {\n\t\t\t\t\tqueue[ index ].finish.call( this );\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Turn off finishing flag\n\t\t\tdelete data.finish;\n\t\t} );\n\t}\n} );\n\njQuery.each( [ \"toggle\", \"show\", \"hide\" ], function( i, name ) {\n\tvar cssFn = jQuery.fn[ name ];\n\tjQuery.fn[ name ] = function( speed, easing, callback ) {\n\t\treturn speed == null || typeof speed === \"boolean\" ?\n\t\t\tcssFn.apply( this, arguments ) :\n\t\t\tthis.animate( genFx( name, true ), speed, easing, callback );\n\t};\n} );\n\n// Generate shortcuts for custom animations\njQuery.each( {\n\tslideDown: genFx( \"show\" ),\n\tslideUp: genFx( \"hide\" ),\n\tslideToggle: genFx( \"toggle\" ),\n\tfadeIn: { opacity: \"show\" },\n\tfadeOut: { opacity: \"hide\" },\n\tfadeToggle: { opacity: \"toggle\" }\n}, function( name, props ) {\n\tjQuery.fn[ name ] = function( speed, easing, callback ) {\n\t\treturn this.animate( props, speed, easing, callback );\n\t};\n} );\n\njQuery.timers = [];\njQuery.fx.tick = function() {\n\tvar timer,\n\t\ti = 0,\n\t\ttimers = jQuery.timers;\n\n\tfxNow = Date.now();\n\n\tfor ( ; i < timers.length; i++ ) {\n\t\ttimer = timers[ i ];\n\n\t\t// Run the timer and safely remove it when done (allowing for external removal)\n\t\tif ( !timer() && timers[ i ] === timer ) {\n\t\t\ttimers.splice( i--, 1 );\n\t\t}\n\t}\n\n\tif ( !timers.length ) {\n\t\tjQuery.fx.stop();\n\t}\n\tfxNow = undefined;\n};\n\njQuery.fx.timer = function( timer ) {\n\tjQuery.timers.push( timer );\n\tjQuery.fx.start();\n};\n\njQuery.fx.interval = 13;\njQuery.fx.start = function() {\n\tif ( inProgress ) {\n\t\treturn;\n\t}\n\n\tinProgress = true;\n\tschedule();\n};\n\njQuery.fx.stop = function() {\n\tinProgress = null;\n};\n\njQuery.fx.speeds = {\n\tslow: 600,\n\tfast: 200,\n\n\t// Default speed\n\t_default: 400\n};\n\n\n// Based off of the plugin by Clint Helfers, with permission.\n// https://web.archive.org/web/20100324014747/http://blindsignals.com/index.php/2009/07/jquery-delay/\njQuery.fn.delay = function( time, type ) {\n\ttime = jQuery.fx ? jQuery.fx.speeds[ time ] || time : time;\n\ttype = type || \"fx\";\n\n\treturn this.queue( type, function( next, hooks ) {\n\t\tvar timeout = window.setTimeout( next, time );\n\t\thooks.stop = function() {\n\t\t\twindow.clearTimeout( timeout );\n\t\t};\n\t} );\n};\n\n\n( function() {\n\tvar input = document.createElement( \"input\" ),\n\t\tselect = document.createElement( \"select\" ),\n\t\topt = select.appendChild( document.createElement( \"option\" ) );\n\n\tinput.type = \"checkbox\";\n\n\t// Support: Android <=4.3 only\n\t// Default value for a checkbox should be \"on\"\n\tsupport.checkOn = input.value !== \"\";\n\n\t// Support: IE <=11 only\n\t// Must access selectedIndex to make default options select\n\tsupport.optSelected = opt.selected;\n\n\t// Support: IE <=11 only\n\t// An input loses its value after becoming a radio\n\tinput = document.createElement( \"input\" );\n\tinput.value = \"t\";\n\tinput.type = \"radio\";\n\tsupport.radioValue = input.value === \"t\";\n} )();\n\n\nvar boolHook,\n\tattrHandle = jQuery.expr.attrHandle;\n\njQuery.fn.extend( {\n\tattr: function( name, value ) {\n\t\treturn access( this, jQuery.attr, name, value, arguments.length > 1 );\n\t},\n\n\tremoveAttr: function( name ) {\n\t\treturn this.each( function() {\n\t\t\tjQuery.removeAttr( this, name );\n\t\t} );\n\t}\n} );\n\njQuery.extend( {\n\tattr: function( elem, name, value ) {\n\t\tvar ret, hooks,\n\t\t\tnType = elem.nodeType;\n\n\t\t// Don't get/set attributes on text, comment and attribute nodes\n\t\tif ( nType === 3 || nType === 8 || nType === 2 ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Fallback to prop when attributes are not supported\n\t\tif ( typeof elem.getAttribute === \"undefined\" ) {\n\t\t\treturn jQuery.prop( elem, name, value );\n\t\t}\n\n\t\t// Attribute hooks are determined by the lowercase version\n\t\t// Grab necessary hook if one is defined\n\t\tif ( nType !== 1 || !jQuery.isXMLDoc( elem ) ) {\n\t\t\thooks = jQuery.attrHooks[ name.toLowerCase() ] ||\n\t\t\t\t( jQuery.expr.match.bool.test( name ) ? boolHook : undefined );\n\t\t}\n\n\t\tif ( value !== undefined ) {\n\t\t\tif ( value === null ) {\n\t\t\t\tjQuery.removeAttr( elem, name );\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif ( hooks && \"set\" in hooks &&\n\t\t\t\t( ret = hooks.set( elem, value, name ) ) !== undefined ) {\n\t\t\t\treturn ret;\n\t\t\t}\n\n\t\t\telem.setAttribute( name, value + \"\" );\n\t\t\treturn value;\n\t\t}\n\n\t\tif ( hooks && \"get\" in hooks && ( ret = hooks.get( elem, name ) ) !== null ) {\n\t\t\treturn ret;\n\t\t}\n\n\t\tret = jQuery.find.attr( elem, name );\n\n\t\t// Non-existent attributes return null, we normalize to undefined\n\t\treturn ret == null ? undefined : ret;\n\t},\n\n\tattrHooks: {\n\t\ttype: {\n\t\t\tset: function( elem, value ) {\n\t\t\t\tif ( !support.radioValue && value === \"radio\" &&\n\t\t\t\t\tnodeName( elem, \"input\" ) ) {\n\t\t\t\t\tvar val = elem.value;\n\t\t\t\t\telem.setAttribute( \"type\", value );\n\t\t\t\t\tif ( val ) {\n\t\t\t\t\t\telem.value = val;\n\t\t\t\t\t}\n\t\t\t\t\treturn value;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t},\n\n\tremoveAttr: function( elem, value ) {\n\t\tvar name,\n\t\t\ti = 0,\n\n\t\t\t// Attribute names can contain non-HTML whitespace characters\n\t\t\t// https://html.spec.whatwg.org/multipage/syntax.html#attributes-2\n\t\t\tattrNames = value && value.match( rnothtmlwhite );\n\n\t\tif ( attrNames && elem.nodeType === 1 ) {\n\t\t\twhile ( ( name = attrNames[ i++ ] ) ) {\n\t\t\t\telem.removeAttribute( name );\n\t\t\t}\n\t\t}\n\t}\n} );\n\n// Hooks for boolean attributes\nboolHook = {\n\tset: function( elem, value, name ) {\n\t\tif ( value === false ) {\n\n\t\t\t// Remove boolean attributes when set to false\n\t\t\tjQuery.removeAttr( elem, name );\n\t\t} else {\n\t\t\telem.setAttribute( name, name );\n\t\t}\n\t\treturn name;\n\t}\n};\n\njQuery.each( jQuery.expr.match.bool.source.match( /\\w+/g ), function( i, name ) {\n\tvar getter = attrHandle[ name ] || jQuery.find.attr;\n\n\tattrHandle[ name ] = function( elem, name, isXML ) {\n\t\tvar ret, handle,\n\t\t\tlowercaseName = name.toLowerCase();\n\n\t\tif ( !isXML ) {\n\n\t\t\t// Avoid an infinite loop by temporarily removing this function from the getter\n\t\t\thandle = attrHandle[ lowercaseName ];\n\t\t\tattrHandle[ lowercaseName ] = ret;\n\t\t\tret = getter( elem, name, isXML ) != null ?\n\t\t\t\tlowercaseName :\n\t\t\t\tnull;\n\t\t\tattrHandle[ lowercaseName ] = handle;\n\t\t}\n\t\treturn ret;\n\t};\n} );\n\n\n\n\nvar rfocusable = /^(?:input|select|textarea|button)$/i,\n\trclickable = /^(?:a|area)$/i;\n\njQuery.fn.extend( {\n\tprop: function( name, value ) {\n\t\treturn access( this, jQuery.prop, name, value, arguments.length > 1 );\n\t},\n\n\tremoveProp: function( name ) {\n\t\treturn this.each( function() {\n\t\t\tdelete this[ jQuery.propFix[ name ] || name ];\n\t\t} );\n\t}\n} );\n\njQuery.extend( {\n\tprop: function( elem, name, value ) {\n\t\tvar ret, hooks,\n\t\t\tnType = elem.nodeType;\n\n\t\t// Don't get/set properties on text, comment and attribute nodes\n\t\tif ( nType === 3 || nType === 8 || nType === 2 ) {\n\t\t\treturn;\n\t\t}\n\n\t\tif ( nType !== 1 || !jQuery.isXMLDoc( elem ) ) {\n\n\t\t\t// Fix name and attach hooks\n\t\t\tname = jQuery.propFix[ name ] || name;\n\t\t\thooks = jQuery.propHooks[ name ];\n\t\t}\n\n\t\tif ( value !== undefined ) {\n\t\t\tif ( hooks && \"set\" in hooks &&\n\t\t\t\t( ret = hooks.set( elem, value, name ) ) !== undefined ) {\n\t\t\t\treturn ret;\n\t\t\t}\n\n\t\t\treturn ( elem[ name ] = value );\n\t\t}\n\n\t\tif ( hooks && \"get\" in hooks && ( ret = hooks.get( elem, name ) ) !== null ) {\n\t\t\treturn ret;\n\t\t}\n\n\t\treturn elem[ name ];\n\t},\n\n\tpropHooks: {\n\t\ttabIndex: {\n\t\t\tget: function( elem ) {\n\n\t\t\t\t// Support: IE <=9 - 11 only\n\t\t\t\t// elem.tabIndex doesn't always return the\n\t\t\t\t// correct value when it hasn't been explicitly set\n\t\t\t\t// https://web.archive.org/web/20141116233347/http://fluidproject.org/blog/2008/01/09/getting-setting-and-removing-tabindex-values-with-javascript/\n\t\t\t\t// Use proper attribute retrieval(#12072)\n\t\t\t\tvar tabindex = jQuery.find.attr( elem, \"tabindex\" );\n\n\t\t\t\tif ( tabindex ) {\n\t\t\t\t\treturn parseInt( tabindex, 10 );\n\t\t\t\t}\n\n\t\t\t\tif (\n\t\t\t\t\trfocusable.test( elem.nodeName ) ||\n\t\t\t\t\trclickable.test( elem.nodeName ) &&\n\t\t\t\t\telem.href\n\t\t\t\t) {\n\t\t\t\t\treturn 0;\n\t\t\t\t}\n\n\t\t\t\treturn -1;\n\t\t\t}\n\t\t}\n\t},\n\n\tpropFix: {\n\t\t\"for\": \"htmlFor\",\n\t\t\"class\": \"className\"\n\t}\n} );\n\n// Support: IE <=11 only\n// Accessing the selectedIndex property\n// forces the browser to respect setting selected\n// on the option\n// The getter ensures a default option is selected\n// when in an optgroup\n// eslint rule \"no-unused-expressions\" is disabled for this code\n// since it considers such accessions noop\nif ( !support.optSelected ) {\n\tjQuery.propHooks.selected = {\n\t\tget: function( elem ) {\n\n\t\t\t/* eslint no-unused-expressions: \"off\" */\n\n\t\t\tvar parent = elem.parentNode;\n\t\t\tif ( parent && parent.parentNode ) {\n\t\t\t\tparent.parentNode.selectedIndex;\n\t\t\t}\n\t\t\treturn null;\n\t\t},\n\t\tset: function( elem ) {\n\n\t\t\t/* eslint no-unused-expressions: \"off\" */\n\n\t\t\tvar parent = elem.parentNode;\n\t\t\tif ( parent ) {\n\t\t\t\tparent.selectedIndex;\n\n\t\t\t\tif ( parent.parentNode ) {\n\t\t\t\t\tparent.parentNode.selectedIndex;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t};\n}\n\njQuery.each( [\n\t\"tabIndex\",\n\t\"readOnly\",\n\t\"maxLength\",\n\t\"cellSpacing\",\n\t\"cellPadding\",\n\t\"rowSpan\",\n\t\"colSpan\",\n\t\"useMap\",\n\t\"frameBorder\",\n\t\"contentEditable\"\n], function() {\n\tjQuery.propFix[ this.toLowerCase() ] = this;\n} );\n\n\n\n\n\t// Strip and collapse whitespace according to HTML spec\n\t// https://infra.spec.whatwg.org/#strip-and-collapse-ascii-whitespace\n\tfunction stripAndCollapse( value ) {\n\t\tvar tokens = value.match( rnothtmlwhite ) || [];\n\t\treturn tokens.join( \" \" );\n\t}\n\n\nfunction getClass( elem ) {\n\treturn elem.getAttribute && elem.getAttribute( \"class\" ) || \"\";\n}\n\nfunction classesToArray( value ) {\n\tif ( Array.isArray( value ) ) {\n\t\treturn value;\n\t}\n\tif ( typeof value === \"string\" ) {\n\t\treturn value.match( rnothtmlwhite ) || [];\n\t}\n\treturn [];\n}\n\njQuery.fn.extend( {\n\taddClass: function( value ) {\n\t\tvar classes, elem, cur, curValue, clazz, j, finalValue,\n\t\t\ti = 0;\n\n\t\tif ( isFunction( value ) ) {\n\t\t\treturn this.each( function( j ) {\n\t\t\t\tjQuery( this ).addClass( value.call( this, j, getClass( this ) ) );\n\t\t\t} );\n\t\t}\n\n\t\tclasses = classesToArray( value );\n\n\t\tif ( classes.length ) {\n\t\t\twhile ( ( elem = this[ i++ ] ) ) {\n\t\t\t\tcurValue = getClass( elem );\n\t\t\t\tcur = elem.nodeType === 1 && ( \" \" + stripAndCollapse( curValue ) + \" \" );\n\n\t\t\t\tif ( cur ) {\n\t\t\t\t\tj = 0;\n\t\t\t\t\twhile ( ( clazz = classes[ j++ ] ) ) {\n\t\t\t\t\t\tif ( cur.indexOf( \" \" + clazz + \" \" ) < 0 ) {\n\t\t\t\t\t\t\tcur += clazz + \" \";\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t// Only assign if different to avoid unneeded rendering.\n\t\t\t\t\tfinalValue = stripAndCollapse( cur );\n\t\t\t\t\tif ( curValue !== finalValue ) {\n\t\t\t\t\t\telem.setAttribute( \"class\", finalValue );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn this;\n\t},\n\n\tremoveClass: function( value ) {\n\t\tvar classes, elem, cur, curValue, clazz, j, finalValue,\n\t\t\ti = 0;\n\n\t\tif ( isFunction( value ) ) {\n\t\t\treturn this.each( function( j ) {\n\t\t\t\tjQuery( this ).removeClass( value.call( this, j, getClass( this ) ) );\n\t\t\t} );\n\t\t}\n\n\t\tif ( !arguments.length ) {\n\t\t\treturn this.attr( \"class\", \"\" );\n\t\t}\n\n\t\tclasses = classesToArray( value );\n\n\t\tif ( classes.length ) {\n\t\t\twhile ( ( elem = this[ i++ ] ) ) {\n\t\t\t\tcurValue = getClass( elem );\n\n\t\t\t\t// This expression is here for better compressibility (see addClass)\n\t\t\t\tcur = elem.nodeType === 1 && ( \" \" + stripAndCollapse( curValue ) + \" \" );\n\n\t\t\t\tif ( cur ) {\n\t\t\t\t\tj = 0;\n\t\t\t\t\twhile ( ( clazz = classes[ j++ ] ) ) {\n\n\t\t\t\t\t\t// Remove *all* instances\n\t\t\t\t\t\twhile ( cur.indexOf( \" \" + clazz + \" \" ) > -1 ) {\n\t\t\t\t\t\t\tcur = cur.replace( \" \" + clazz + \" \", \" \" );\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t// Only assign if different to avoid unneeded rendering.\n\t\t\t\t\tfinalValue = stripAndCollapse( cur );\n\t\t\t\t\tif ( curValue !== finalValue ) {\n\t\t\t\t\t\telem.setAttribute( \"class\", finalValue );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn this;\n\t},\n\n\ttoggleClass: function( value, stateVal ) {\n\t\tvar type = typeof value,\n\t\t\tisValidValue = type === \"string\" || Array.isArray( value );\n\n\t\tif ( typeof stateVal === \"boolean\" && isValidValue ) {\n\t\t\treturn stateVal ? this.addClass( value ) : this.removeClass( value );\n\t\t}\n\n\t\tif ( isFunction( value ) ) {\n\t\t\treturn this.each( function( i ) {\n\t\t\t\tjQuery( this ).toggleClass(\n\t\t\t\t\tvalue.call( this, i, getClass( this ), stateVal ),\n\t\t\t\t\tstateVal\n\t\t\t\t);\n\t\t\t} );\n\t\t}\n\n\t\treturn this.each( function() {\n\t\t\tvar className, i, self, classNames;\n\n\t\t\tif ( isValidValue ) {\n\n\t\t\t\t// Toggle individual class names\n\t\t\t\ti = 0;\n\t\t\t\tself = jQuery( this );\n\t\t\t\tclassNames = classesToArray( value );\n\n\t\t\t\twhile ( ( className = classNames[ i++ ] ) ) {\n\n\t\t\t\t\t// Check each className given, space separated list\n\t\t\t\t\tif ( self.hasClass( className ) ) {\n\t\t\t\t\t\tself.removeClass( className );\n\t\t\t\t\t} else {\n\t\t\t\t\t\tself.addClass( className );\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t// Toggle whole class name\n\t\t\t} else if ( value === undefined || type === \"boolean\" ) {\n\t\t\t\tclassName = getClass( this );\n\t\t\t\tif ( className ) {\n\n\t\t\t\t\t// Store className if set\n\t\t\t\t\tdataPriv.set( this, \"__className__\", className );\n\t\t\t\t}\n\n\t\t\t\t// If the element has a class name or if we're passed `false`,\n\t\t\t\t// then remove the whole classname (if there was one, the above saved it).\n\t\t\t\t// Otherwise bring back whatever was previously saved (if anything),\n\t\t\t\t// falling back to the empty string if nothing was stored.\n\t\t\t\tif ( this.setAttribute ) {\n\t\t\t\t\tthis.setAttribute( \"class\",\n\t\t\t\t\t\tclassName || value === false ?\n\t\t\t\t\t\t\"\" :\n\t\t\t\t\t\tdataPriv.get( this, \"__className__\" ) || \"\"\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\t\t} );\n\t},\n\n\thasClass: function( selector ) {\n\t\tvar className, elem,\n\t\t\ti = 0;\n\n\t\tclassName = \" \" + selector + \" \";\n\t\twhile ( ( elem = this[ i++ ] ) ) {\n\t\t\tif ( elem.nodeType === 1 &&\n\t\t\t\t( \" \" + stripAndCollapse( getClass( elem ) ) + \" \" ).indexOf( className ) > -1 ) {\n\t\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\treturn false;\n\t}\n} );\n\n\n\n\nvar rreturn = /\\r/g;\n\njQuery.fn.extend( {\n\tval: function( value ) {\n\t\tvar hooks, ret, valueIsFunction,\n\t\t\telem = this[ 0 ];\n\n\t\tif ( !arguments.length ) {\n\t\t\tif ( elem ) {\n\t\t\t\thooks = jQuery.valHooks[ elem.type ] ||\n\t\t\t\t\tjQuery.valHooks[ elem.nodeName.toLowerCase() ];\n\n\t\t\t\tif ( hooks &&\n\t\t\t\t\t\"get\" in hooks &&\n\t\t\t\t\t( ret = hooks.get( elem, \"value\" ) ) !== undefined\n\t\t\t\t) {\n\t\t\t\t\treturn ret;\n\t\t\t\t}\n\n\t\t\t\tret = elem.value;\n\n\t\t\t\t// Handle most common string cases\n\t\t\t\tif ( typeof ret === \"string\" ) {\n\t\t\t\t\treturn ret.replace( rreturn, \"\" );\n\t\t\t\t}\n\n\t\t\t\t// Handle cases where value is null/undef or number\n\t\t\t\treturn ret == null ? \"\" : ret;\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\tvalueIsFunction = isFunction( value );\n\n\t\treturn this.each( function( i ) {\n\t\t\tvar val;\n\n\t\t\tif ( this.nodeType !== 1 ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif ( valueIsFunction ) {\n\t\t\t\tval = value.call( this, i, jQuery( this ).val() );\n\t\t\t} else {\n\t\t\t\tval = value;\n\t\t\t}\n\n\t\t\t// Treat null/undefined as \"\"; convert numbers to string\n\t\t\tif ( val == null ) {\n\t\t\t\tval = \"\";\n\n\t\t\t} else if ( typeof val === \"number\" ) {\n\t\t\t\tval += \"\";\n\n\t\t\t} else if ( Array.isArray( val ) ) {\n\t\t\t\tval = jQuery.map( val, function( value ) {\n\t\t\t\t\treturn value == null ? \"\" : value + \"\";\n\t\t\t\t} );\n\t\t\t}\n\n\t\t\thooks = jQuery.valHooks[ this.type ] || jQuery.valHooks[ this.nodeName.toLowerCase() ];\n\n\t\t\t// If set returns undefined, fall back to normal setting\n\t\t\tif ( !hooks || !( \"set\" in hooks ) || hooks.set( this, val, \"value\" ) === undefined ) {\n\t\t\t\tthis.value = val;\n\t\t\t}\n\t\t} );\n\t}\n} );\n\njQuery.extend( {\n\tvalHooks: {\n\t\toption: {\n\t\t\tget: function( elem ) {\n\n\t\t\t\tvar val = jQuery.find.attr( elem, \"value\" );\n\t\t\t\treturn val != null ?\n\t\t\t\t\tval :\n\n\t\t\t\t\t// Support: IE <=10 - 11 only\n\t\t\t\t\t// option.text throws exceptions (#14686, #14858)\n\t\t\t\t\t// Strip and collapse whitespace\n\t\t\t\t\t// https://html.spec.whatwg.org/#strip-and-collapse-whitespace\n\t\t\t\t\tstripAndCollapse( jQuery.text( elem ) );\n\t\t\t}\n\t\t},\n\t\tselect: {\n\t\t\tget: function( elem ) {\n\t\t\t\tvar value, option, i,\n\t\t\t\t\toptions = elem.options,\n\t\t\t\t\tindex = elem.selectedIndex,\n\t\t\t\t\tone = elem.type === \"select-one\",\n\t\t\t\t\tvalues = one ? null : [],\n\t\t\t\t\tmax = one ? index + 1 : options.length;\n\n\t\t\t\tif ( index < 0 ) {\n\t\t\t\t\ti = max;\n\n\t\t\t\t} else {\n\t\t\t\t\ti = one ? index : 0;\n\t\t\t\t}\n\n\t\t\t\t// Loop through all the selected options\n\t\t\t\tfor ( ; i < max; i++ ) {\n\t\t\t\t\toption = options[ i ];\n\n\t\t\t\t\t// Support: IE <=9 only\n\t\t\t\t\t// IE8-9 doesn't update selected after form reset (#2551)\n\t\t\t\t\tif ( ( option.selected || i === index ) &&\n\n\t\t\t\t\t\t\t// Don't return options that are disabled or in a disabled optgroup\n\t\t\t\t\t\t\t!option.disabled &&\n\t\t\t\t\t\t\t( !option.parentNode.disabled ||\n\t\t\t\t\t\t\t\t!nodeName( option.parentNode, \"optgroup\" ) ) ) {\n\n\t\t\t\t\t\t// Get the specific value for the option\n\t\t\t\t\t\tvalue = jQuery( option ).val();\n\n\t\t\t\t\t\t// We don't need an array for one selects\n\t\t\t\t\t\tif ( one ) {\n\t\t\t\t\t\t\treturn value;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// Multi-Selects return an array\n\t\t\t\t\t\tvalues.push( value );\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn values;\n\t\t\t},\n\n\t\t\tset: function( elem, value ) {\n\t\t\t\tvar optionSet, option,\n\t\t\t\t\toptions = elem.options,\n\t\t\t\t\tvalues = jQuery.makeArray( value ),\n\t\t\t\t\ti = options.length;\n\n\t\t\t\twhile ( i-- ) {\n\t\t\t\t\toption = options[ i ];\n\n\t\t\t\t\t/* eslint-disable no-cond-assign */\n\n\t\t\t\t\tif ( option.selected =\n\t\t\t\t\t\tjQuery.inArray( jQuery.valHooks.option.get( option ), values ) > -1\n\t\t\t\t\t) {\n\t\t\t\t\t\toptionSet = true;\n\t\t\t\t\t}\n\n\t\t\t\t\t/* eslint-enable no-cond-assign */\n\t\t\t\t}\n\n\t\t\t\t// Force browsers to behave consistently when non-matching value is set\n\t\t\t\tif ( !optionSet ) {\n\t\t\t\t\telem.selectedIndex = -1;\n\t\t\t\t}\n\t\t\t\treturn values;\n\t\t\t}\n\t\t}\n\t}\n} );\n\n// Radios and checkboxes getter/setter\njQuery.each( [ \"radio\", \"checkbox\" ], function() {\n\tjQuery.valHooks[ this ] = {\n\t\tset: function( elem, value ) {\n\t\t\tif ( Array.isArray( value ) ) {\n\t\t\t\treturn ( elem.checked = jQuery.inArray( jQuery( elem ).val(), value ) > -1 );\n\t\t\t}\n\t\t}\n\t};\n\tif ( !support.checkOn ) {\n\t\tjQuery.valHooks[ this ].get = function( elem ) {\n\t\t\treturn elem.getAttribute( \"value\" ) === null ? \"on\" : elem.value;\n\t\t};\n\t}\n} );\n\n\n\n\n// Return jQuery for attributes-only inclusion\n\n\nsupport.focusin = \"onfocusin\" in window;\n\n\nvar rfocusMorph = /^(?:focusinfocus|focusoutblur)$/,\n\tstopPropagationCallback = function( e ) {\n\t\te.stopPropagation();\n\t};\n\njQuery.extend( jQuery.event, {\n\n\ttrigger: function( event, data, elem, onlyHandlers ) {\n\n\t\tvar i, cur, tmp, bubbleType, ontype, handle, special, lastElement,\n\t\t\teventPath = [ elem || document ],\n\t\t\ttype = hasOwn.call( event, \"type\" ) ? event.type : event,\n\t\t\tnamespaces = hasOwn.call( event, \"namespace\" ) ? event.namespace.split( \".\" ) : [];\n\n\t\tcur = lastElement = tmp = elem = elem || document;\n\n\t\t// Don't do events on text and comment nodes\n\t\tif ( elem.nodeType === 3 || elem.nodeType === 8 ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// focus/blur morphs to focusin/out; ensure we're not firing them right now\n\t\tif ( rfocusMorph.test( type + jQuery.event.triggered ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\tif ( type.indexOf( \".\" ) > -1 ) {\n\n\t\t\t// Namespaced trigger; create a regexp to match event type in handle()\n\t\t\tnamespaces = type.split( \".\" );\n\t\t\ttype = namespaces.shift();\n\t\t\tnamespaces.sort();\n\t\t}\n\t\tontype = type.indexOf( \":\" ) < 0 && \"on\" + type;\n\n\t\t// Caller can pass in a jQuery.Event object, Object, or just an event type string\n\t\tevent = event[ jQuery.expando ] ?\n\t\t\tevent :\n\t\t\tnew jQuery.Event( type, typeof event === \"object\" && event );\n\n\t\t// Trigger bitmask: & 1 for native handlers; & 2 for jQuery (always true)\n\t\tevent.isTrigger = onlyHandlers ? 2 : 3;\n\t\tevent.namespace = namespaces.join( \".\" );\n\t\tevent.rnamespace = event.namespace ?\n\t\t\tnew RegExp( \"(^|\\\\.)\" + namespaces.join( \"\\\\.(?:.*\\\\.|)\" ) + \"(\\\\.|$)\" ) :\n\t\t\tnull;\n\n\t\t// Clean up the event in case it is being reused\n\t\tevent.result = undefined;\n\t\tif ( !event.target ) {\n\t\t\tevent.target = elem;\n\t\t}\n\n\t\t// Clone any incoming data and prepend the event, creating the handler arg list\n\t\tdata = data == null ?\n\t\t\t[ event ] :\n\t\t\tjQuery.makeArray( data, [ event ] );\n\n\t\t// Allow special events to draw outside the lines\n\t\tspecial = jQuery.event.special[ type ] || {};\n\t\tif ( !onlyHandlers && special.trigger && special.trigger.apply( elem, data ) === false ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Determine event propagation path in advance, per W3C events spec (#9951)\n\t\t// Bubble up to document, then to window; watch for a global ownerDocument var (#9724)\n\t\tif ( !onlyHandlers && !special.noBubble && !isWindow( elem ) ) {\n\n\t\t\tbubbleType = special.delegateType || type;\n\t\t\tif ( !rfocusMorph.test( bubbleType + type ) ) {\n\t\t\t\tcur = cur.parentNode;\n\t\t\t}\n\t\t\tfor ( ; cur; cur = cur.parentNode ) {\n\t\t\t\teventPath.push( cur );\n\t\t\t\ttmp = cur;\n\t\t\t}\n\n\t\t\t// Only add window if we got to document (e.g., not plain obj or detached DOM)\n\t\t\tif ( tmp === ( elem.ownerDocument || document ) ) {\n\t\t\t\teventPath.push( tmp.defaultView || tmp.parentWindow || window );\n\t\t\t}\n\t\t}\n\n\t\t// Fire handlers on the event path\n\t\ti = 0;\n\t\twhile ( ( cur = eventPath[ i++ ] ) && !event.isPropagationStopped() ) {\n\t\t\tlastElement = cur;\n\t\t\tevent.type = i > 1 ?\n\t\t\t\tbubbleType :\n\t\t\t\tspecial.bindType || type;\n\n\t\t\t// jQuery handler\n\t\t\thandle = ( dataPriv.get( cur, \"events\" ) || {} )[ event.type ] &&\n\t\t\t\tdataPriv.get( cur, \"handle\" );\n\t\t\tif ( handle ) {\n\t\t\t\thandle.apply( cur, data );\n\t\t\t}\n\n\t\t\t// Native handler\n\t\t\thandle = ontype && cur[ ontype ];\n\t\t\tif ( handle && handle.apply && acceptData( cur ) ) {\n\t\t\t\tevent.result = handle.apply( cur, data );\n\t\t\t\tif ( event.result === false ) {\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tevent.type = type;\n\n\t\t// If nobody prevented the default action, do it now\n\t\tif ( !onlyHandlers && !event.isDefaultPrevented() ) {\n\n\t\t\tif ( ( !special._default ||\n\t\t\t\tspecial._default.apply( eventPath.pop(), data ) === false ) &&\n\t\t\t\tacceptData( elem ) ) {\n\n\t\t\t\t// Call a native DOM method on the target with the same name as the event.\n\t\t\t\t// Don't do default actions on window, that's where global variables be (#6170)\n\t\t\t\tif ( ontype && isFunction( elem[ type ] ) && !isWindow( elem ) ) {\n\n\t\t\t\t\t// Don't re-trigger an onFOO event when we call its FOO() method\n\t\t\t\t\ttmp = elem[ ontype ];\n\n\t\t\t\t\tif ( tmp ) {\n\t\t\t\t\t\telem[ ontype ] = null;\n\t\t\t\t\t}\n\n\t\t\t\t\t// Prevent re-triggering of the same event, since we already bubbled it above\n\t\t\t\t\tjQuery.event.triggered = type;\n\n\t\t\t\t\tif ( event.isPropagationStopped() ) {\n\t\t\t\t\t\tlastElement.addEventListener( type, stopPropagationCallback );\n\t\t\t\t\t}\n\n\t\t\t\t\telem[ type ]();\n\n\t\t\t\t\tif ( event.isPropagationStopped() ) {\n\t\t\t\t\t\tlastElement.removeEventListener( type, stopPropagationCallback );\n\t\t\t\t\t}\n\n\t\t\t\t\tjQuery.event.triggered = undefined;\n\n\t\t\t\t\tif ( tmp ) {\n\t\t\t\t\t\telem[ ontype ] = tmp;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn event.result;\n\t},\n\n\t// Piggyback on a donor event to simulate a different one\n\t// Used only for `focus(in | out)` events\n\tsimulate: function( type, elem, event ) {\n\t\tvar e = jQuery.extend(\n\t\t\tnew jQuery.Event(),\n\t\t\tevent,\n\t\t\t{\n\t\t\t\ttype: type,\n\t\t\t\tisSimulated: true\n\t\t\t}\n\t\t);\n\n\t\tjQuery.event.trigger( e, null, elem );\n\t}\n\n} );\n\njQuery.fn.extend( {\n\n\ttrigger: function( type, data ) {\n\t\treturn this.each( function() {\n\t\t\tjQuery.event.trigger( type, data, this );\n\t\t} );\n\t},\n\ttriggerHandler: function( type, data ) {\n\t\tvar elem = this[ 0 ];\n\t\tif ( elem ) {\n\t\t\treturn jQuery.event.trigger( type, data, elem, true );\n\t\t}\n\t}\n} );\n\n\n// Support: Firefox <=44\n// Firefox doesn't have focus(in | out) events\n// Related ticket - https://bugzilla.mozilla.org/show_bug.cgi?id=687787\n//\n// Support: Chrome <=48 - 49, Safari <=9.0 - 9.1\n// focus(in | out) events fire after focus & blur events,\n// which is spec violation - http://www.w3.org/TR/DOM-Level-3-Events/#events-focusevent-event-order\n// Related ticket - https://bugs.chromium.org/p/chromium/issues/detail?id=449857\nif ( !support.focusin ) {\n\tjQuery.each( { focus: \"focusin\", blur: \"focusout\" }, function( orig, fix ) {\n\n\t\t// Attach a single capturing handler on the document while someone wants focusin/focusout\n\t\tvar handler = function( event ) {\n\t\t\tjQuery.event.simulate( fix, event.target, jQuery.event.fix( event ) );\n\t\t};\n\n\t\tjQuery.event.special[ fix ] = {\n\t\t\tsetup: function() {\n\t\t\t\tvar doc = this.ownerDocument || this,\n\t\t\t\t\tattaches = dataPriv.access( doc, fix );\n\n\t\t\t\tif ( !attaches ) {\n\t\t\t\t\tdoc.addEventListener( orig, handler, true );\n\t\t\t\t}\n\t\t\t\tdataPriv.access( doc, fix, ( attaches || 0 ) + 1 );\n\t\t\t},\n\t\t\tteardown: function() {\n\t\t\t\tvar doc = this.ownerDocument || this,\n\t\t\t\t\tattaches = dataPriv.access( doc, fix ) - 1;\n\n\t\t\t\tif ( !attaches ) {\n\t\t\t\t\tdoc.removeEventListener( orig, handler, true );\n\t\t\t\t\tdataPriv.remove( doc, fix );\n\n\t\t\t\t} else {\n\t\t\t\t\tdataPriv.access( doc, fix, attaches );\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t} );\n}\nvar location = window.location;\n\nvar nonce = Date.now();\n\nvar rquery = ( /\\?/ );\n\n\n\n// Cross-browser xml parsing\njQuery.parseXML = function( data ) {\n\tvar xml;\n\tif ( !data || typeof data !== \"string\" ) {\n\t\treturn null;\n\t}\n\n\t// Support: IE 9 - 11 only\n\t// IE throws on parseFromString with invalid input.\n\ttry {\n\t\txml = ( new window.DOMParser() ).parseFromString( data, \"text/xml\" );\n\t} catch ( e ) {\n\t\txml = undefined;\n\t}\n\n\tif ( !xml || xml.getElementsByTagName( \"parsererror\" ).length ) {\n\t\tjQuery.error( \"Invalid XML: \" + data );\n\t}\n\treturn xml;\n};\n\n\nvar\n\trbracket = /\\[\\]$/,\n\trCRLF = /\\r?\\n/g,\n\trsubmitterTypes = /^(?:submit|button|image|reset|file)$/i,\n\trsubmittable = /^(?:input|select|textarea|keygen)/i;\n\nfunction buildParams( prefix, obj, traditional, add ) {\n\tvar name;\n\n\tif ( Array.isArray( obj ) ) {\n\n\t\t// Serialize array item.\n\t\tjQuery.each( obj, function( i, v ) {\n\t\t\tif ( traditional || rbracket.test( prefix ) ) {\n\n\t\t\t\t// Treat each array item as a scalar.\n\t\t\t\tadd( prefix, v );\n\n\t\t\t} else {\n\n\t\t\t\t// Item is non-scalar (array or object), encode its numeric index.\n\t\t\t\tbuildParams(\n\t\t\t\t\tprefix + \"[\" + ( typeof v === \"object\" && v != null ? i : \"\" ) + \"]\",\n\t\t\t\t\tv,\n\t\t\t\t\ttraditional,\n\t\t\t\t\tadd\n\t\t\t\t);\n\t\t\t}\n\t\t} );\n\n\t} else if ( !traditional && toType( obj ) === \"object\" ) {\n\n\t\t// Serialize object item.\n\t\tfor ( name in obj ) {\n\t\t\tbuildParams( prefix + \"[\" + name + \"]\", obj[ name ], traditional, add );\n\t\t}\n\n\t} else {\n\n\t\t// Serialize scalar item.\n\t\tadd( prefix, obj );\n\t}\n}\n\n// Serialize an array of form elements or a set of\n// key/values into a query string\njQuery.param = function( a, traditional ) {\n\tvar prefix,\n\t\ts = [],\n\t\tadd = function( key, valueOrFunction ) {\n\n\t\t\t// If value is a function, invoke it and use its return value\n\t\t\tvar value = isFunction( valueOrFunction ) ?\n\t\t\t\tvalueOrFunction() :\n\t\t\t\tvalueOrFunction;\n\n\t\t\ts[ s.length ] = encodeURIComponent( key ) + \"=\" +\n\t\t\t\tencodeURIComponent( value == null ? \"\" : value );\n\t\t};\n\n\tif ( a == null ) {\n\t\treturn \"\";\n\t}\n\n\t// If an array was passed in, assume that it is an array of form elements.\n\tif ( Array.isArray( a ) || ( a.jquery && !jQuery.isPlainObject( a ) ) ) {\n\n\t\t// Serialize the form elements\n\t\tjQuery.each( a, function() {\n\t\t\tadd( this.name, this.value );\n\t\t} );\n\n\t} else {\n\n\t\t// If traditional, encode the \"old\" way (the way 1.3.2 or older\n\t\t// did it), otherwise encode params recursively.\n\t\tfor ( prefix in a ) {\n\t\t\tbuildParams( prefix, a[ prefix ], traditional, add );\n\t\t}\n\t}\n\n\t// Return the resulting serialization\n\treturn s.join( \"&\" );\n};\n\njQuery.fn.extend( {\n\tserialize: function() {\n\t\treturn jQuery.param( this.serializeArray() );\n\t},\n\tserializeArray: function() {\n\t\treturn this.map( function() {\n\n\t\t\t// Can add propHook for \"elements\" to filter or add form elements\n\t\t\tvar elements = jQuery.prop( this, \"elements\" );\n\t\t\treturn elements ? jQuery.makeArray( elements ) : this;\n\t\t} )\n\t\t.filter( function() {\n\t\t\tvar type = this.type;\n\n\t\t\t// Use .is( \":disabled\" ) so that fieldset[disabled] works\n\t\t\treturn this.name && !jQuery( this ).is( \":disabled\" ) &&\n\t\t\t\trsubmittable.test( this.nodeName ) && !rsubmitterTypes.test( type ) &&\n\t\t\t\t( this.checked || !rcheckableType.test( type ) );\n\t\t} )\n\t\t.map( function( i, elem ) {\n\t\t\tvar val = jQuery( this ).val();\n\n\t\t\tif ( val == null ) {\n\t\t\t\treturn null;\n\t\t\t}\n\n\t\t\tif ( Array.isArray( val ) ) {\n\t\t\t\treturn jQuery.map( val, function( val ) {\n\t\t\t\t\treturn { name: elem.name, value: val.replace( rCRLF, \"\\r\\n\" ) };\n\t\t\t\t} );\n\t\t\t}\n\n\t\t\treturn { name: elem.name, value: val.replace( rCRLF, \"\\r\\n\" ) };\n\t\t} ).get();\n\t}\n} );\n\n\nvar\n\tr20 = /%20/g,\n\trhash = /#.*$/,\n\trantiCache = /([?&])_=[^&]*/,\n\trheaders = /^(.*?):[ \\t]*([^\\r\\n]*)$/mg,\n\n\t// #7653, #8125, #8152: local protocol detection\n\trlocalProtocol = /^(?:about|app|app-storage|.+-extension|file|res|widget):$/,\n\trnoContent = /^(?:GET|HEAD)$/,\n\trprotocol = /^\\/\\//,\n\n\t/* Prefilters\n\t * 1) They are useful to introduce custom dataTypes (see ajax/jsonp.js for an example)\n\t * 2) These are called:\n\t *    - BEFORE asking for a transport\n\t *    - AFTER param serialization (s.data is a string if s.processData is true)\n\t * 3) key is the dataType\n\t * 4) the catchall symbol \"*\" can be used\n\t * 5) execution will start with transport dataType and THEN continue down to \"*\" if needed\n\t */\n\tprefilters = {},\n\n\t/* Transports bindings\n\t * 1) key is the dataType\n\t * 2) the catchall symbol \"*\" can be used\n\t * 3) selection will start with transport dataType and THEN go to \"*\" if needed\n\t */\n\ttransports = {},\n\n\t// Avoid comment-prolog char sequence (#10098); must appease lint and evade compression\n\tallTypes = \"*/\".concat( \"*\" ),\n\n\t// Anchor tag for parsing the document origin\n\toriginAnchor = document.createElement( \"a\" );\n\toriginAnchor.href = location.href;\n\n// Base \"constructor\" for jQuery.ajaxPrefilter and jQuery.ajaxTransport\nfunction addToPrefiltersOrTransports( structure ) {\n\n\t// dataTypeExpression is optional and defaults to \"*\"\n\treturn function( dataTypeExpression, func ) {\n\n\t\tif ( typeof dataTypeExpression !== \"string\" ) {\n\t\t\tfunc = dataTypeExpression;\n\t\t\tdataTypeExpression = \"*\";\n\t\t}\n\n\t\tvar dataType,\n\t\t\ti = 0,\n\t\t\tdataTypes = dataTypeExpression.toLowerCase().match( rnothtmlwhite ) || [];\n\n\t\tif ( isFunction( func ) ) {\n\n\t\t\t// For each dataType in the dataTypeExpression\n\t\t\twhile ( ( dataType = dataTypes[ i++ ] ) ) {\n\n\t\t\t\t// Prepend if requested\n\t\t\t\tif ( dataType[ 0 ] === \"+\" ) {\n\t\t\t\t\tdataType = dataType.slice( 1 ) || \"*\";\n\t\t\t\t\t( structure[ dataType ] = structure[ dataType ] || [] ).unshift( func );\n\n\t\t\t\t// Otherwise append\n\t\t\t\t} else {\n\t\t\t\t\t( structure[ dataType ] = structure[ dataType ] || [] ).push( func );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t};\n}\n\n// Base inspection function for prefilters and transports\nfunction inspectPrefiltersOrTransports( structure, options, originalOptions, jqXHR ) {\n\n\tvar inspected = {},\n\t\tseekingTransport = ( structure === transports );\n\n\tfunction inspect( dataType ) {\n\t\tvar selected;\n\t\tinspected[ dataType ] = true;\n\t\tjQuery.each( structure[ dataType ] || [], function( _, prefilterOrFactory ) {\n\t\t\tvar dataTypeOrTransport = prefilterOrFactory( options, originalOptions, jqXHR );\n\t\t\tif ( typeof dataTypeOrTransport === \"string\" &&\n\t\t\t\t!seekingTransport && !inspected[ dataTypeOrTransport ] ) {\n\n\t\t\t\toptions.dataTypes.unshift( dataTypeOrTransport );\n\t\t\t\tinspect( dataTypeOrTransport );\n\t\t\t\treturn false;\n\t\t\t} else if ( seekingTransport ) {\n\t\t\t\treturn !( selected = dataTypeOrTransport );\n\t\t\t}\n\t\t} );\n\t\treturn selected;\n\t}\n\n\treturn inspect( options.dataTypes[ 0 ] ) || !inspected[ \"*\" ] && inspect( \"*\" );\n}\n\n// A special extend for ajax options\n// that takes \"flat\" options (not to be deep extended)\n// Fixes #9887\nfunction ajaxExtend( target, src ) {\n\tvar key, deep,\n\t\tflatOptions = jQuery.ajaxSettings.flatOptions || {};\n\n\tfor ( key in src ) {\n\t\tif ( src[ key ] !== undefined ) {\n\t\t\t( flatOptions[ key ] ? target : ( deep || ( deep = {} ) ) )[ key ] = src[ key ];\n\t\t}\n\t}\n\tif ( deep ) {\n\t\tjQuery.extend( true, target, deep );\n\t}\n\n\treturn target;\n}\n\n/* Handles responses to an ajax request:\n * - finds the right dataType (mediates between content-type and expected dataType)\n * - returns the corresponding response\n */\nfunction ajaxHandleResponses( s, jqXHR, responses ) {\n\n\tvar ct, type, finalDataType, firstDataType,\n\t\tcontents = s.contents,\n\t\tdataTypes = s.dataTypes;\n\n\t// Remove auto dataType and get content-type in the process\n\twhile ( dataTypes[ 0 ] === \"*\" ) {\n\t\tdataTypes.shift();\n\t\tif ( ct === undefined ) {\n\t\t\tct = s.mimeType || jqXHR.getResponseHeader( \"Content-Type\" );\n\t\t}\n\t}\n\n\t// Check if we're dealing with a known content-type\n\tif ( ct ) {\n\t\tfor ( type in contents ) {\n\t\t\tif ( contents[ type ] && contents[ type ].test( ct ) ) {\n\t\t\t\tdataTypes.unshift( type );\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t}\n\n\t// Check to see if we have a response for the expected dataType\n\tif ( dataTypes[ 0 ] in responses ) {\n\t\tfinalDataType = dataTypes[ 0 ];\n\t} else {\n\n\t\t// Try convertible dataTypes\n\t\tfor ( type in responses ) {\n\t\t\tif ( !dataTypes[ 0 ] || s.converters[ type + \" \" + dataTypes[ 0 ] ] ) {\n\t\t\t\tfinalDataType = type;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\tif ( !firstDataType ) {\n\t\t\t\tfirstDataType = type;\n\t\t\t}\n\t\t}\n\n\t\t// Or just use first one\n\t\tfinalDataType = finalDataType || firstDataType;\n\t}\n\n\t// If we found a dataType\n\t// We add the dataType to the list if needed\n\t// and return the corresponding response\n\tif ( finalDataType ) {\n\t\tif ( finalDataType !== dataTypes[ 0 ] ) {\n\t\t\tdataTypes.unshift( finalDataType );\n\t\t}\n\t\treturn responses[ finalDataType ];\n\t}\n}\n\n/* Chain conversions given the request and the original response\n * Also sets the responseXXX fields on the jqXHR instance\n */\nfunction ajaxConvert( s, response, jqXHR, isSuccess ) {\n\tvar conv2, current, conv, tmp, prev,\n\t\tconverters = {},\n\n\t\t// Work with a copy of dataTypes in case we need to modify it for conversion\n\t\tdataTypes = s.dataTypes.slice();\n\n\t// Create converters map with lowercased keys\n\tif ( dataTypes[ 1 ] ) {\n\t\tfor ( conv in s.converters ) {\n\t\t\tconverters[ conv.toLowerCase() ] = s.converters[ conv ];\n\t\t}\n\t}\n\n\tcurrent = dataTypes.shift();\n\n\t// Convert to each sequential dataType\n\twhile ( current ) {\n\n\t\tif ( s.responseFields[ current ] ) {\n\t\t\tjqXHR[ s.responseFields[ current ] ] = response;\n\t\t}\n\n\t\t// Apply the dataFilter if provided\n\t\tif ( !prev && isSuccess && s.dataFilter ) {\n\t\t\tresponse = s.dataFilter( response, s.dataType );\n\t\t}\n\n\t\tprev = current;\n\t\tcurrent = dataTypes.shift();\n\n\t\tif ( current ) {\n\n\t\t\t// There's only work to do if current dataType is non-auto\n\t\t\tif ( current === \"*\" ) {\n\n\t\t\t\tcurrent = prev;\n\n\t\t\t// Convert response if prev dataType is non-auto and differs from current\n\t\t\t} else if ( prev !== \"*\" && prev !== current ) {\n\n\t\t\t\t// Seek a direct converter\n\t\t\t\tconv = converters[ prev + \" \" + current ] || converters[ \"* \" + current ];\n\n\t\t\t\t// If none found, seek a pair\n\t\t\t\tif ( !conv ) {\n\t\t\t\t\tfor ( conv2 in converters ) {\n\n\t\t\t\t\t\t// If conv2 outputs current\n\t\t\t\t\t\ttmp = conv2.split( \" \" );\n\t\t\t\t\t\tif ( tmp[ 1 ] === current ) {\n\n\t\t\t\t\t\t\t// If prev can be converted to accepted input\n\t\t\t\t\t\t\tconv = converters[ prev + \" \" + tmp[ 0 ] ] ||\n\t\t\t\t\t\t\t\tconverters[ \"* \" + tmp[ 0 ] ];\n\t\t\t\t\t\t\tif ( conv ) {\n\n\t\t\t\t\t\t\t\t// Condense equivalence converters\n\t\t\t\t\t\t\t\tif ( conv === true ) {\n\t\t\t\t\t\t\t\t\tconv = converters[ conv2 ];\n\n\t\t\t\t\t\t\t\t// Otherwise, insert the intermediate dataType\n\t\t\t\t\t\t\t\t} else if ( converters[ conv2 ] !== true ) {\n\t\t\t\t\t\t\t\t\tcurrent = tmp[ 0 ];\n\t\t\t\t\t\t\t\t\tdataTypes.unshift( tmp[ 1 ] );\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Apply converter (if not an equivalence)\n\t\t\t\tif ( conv !== true ) {\n\n\t\t\t\t\t// Unless errors are allowed to bubble, catch and return them\n\t\t\t\t\tif ( conv && s.throws ) {\n\t\t\t\t\t\tresponse = conv( response );\n\t\t\t\t\t} else {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tresponse = conv( response );\n\t\t\t\t\t\t} catch ( e ) {\n\t\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\t\tstate: \"parsererror\",\n\t\t\t\t\t\t\t\terror: conv ? e : \"No conversion from \" + prev + \" to \" + current\n\t\t\t\t\t\t\t};\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn { state: \"success\", data: response };\n}\n\njQuery.extend( {\n\n\t// Counter for holding the number of active queries\n\tactive: 0,\n\n\t// Last-Modified header cache for next request\n\tlastModified: {},\n\tetag: {},\n\n\tajaxSettings: {\n\t\turl: location.href,\n\t\ttype: \"GET\",\n\t\tisLocal: rlocalProtocol.test( location.protocol ),\n\t\tglobal: true,\n\t\tprocessData: true,\n\t\tasync: true,\n\t\tcontentType: \"application/x-www-form-urlencoded; charset=UTF-8\",\n\n\t\t/*\n\t\ttimeout: 0,\n\t\tdata: null,\n\t\tdataType: null,\n\t\tusername: null,\n\t\tpassword: null,\n\t\tcache: null,\n\t\tthrows: false,\n\t\ttraditional: false,\n\t\theaders: {},\n\t\t*/\n\n\t\taccepts: {\n\t\t\t\"*\": allTypes,\n\t\t\ttext: \"text/plain\",\n\t\t\thtml: \"text/html\",\n\t\t\txml: \"application/xml, text/xml\",\n\t\t\tjson: \"application/json, text/javascript\"\n\t\t},\n\n\t\tcontents: {\n\t\t\txml: /\\bxml\\b/,\n\t\t\thtml: /\\bhtml/,\n\t\t\tjson: /\\bjson\\b/\n\t\t},\n\n\t\tresponseFields: {\n\t\t\txml: \"responseXML\",\n\t\t\ttext: \"responseText\",\n\t\t\tjson: \"responseJSON\"\n\t\t},\n\n\t\t// Data converters\n\t\t// Keys separate source (or catchall \"*\") and destination types with a single space\n\t\tconverters: {\n\n\t\t\t// Convert anything to text\n\t\t\t\"* text\": String,\n\n\t\t\t// Text to html (true = no transformation)\n\t\t\t\"text html\": true,\n\n\t\t\t// Evaluate text as a json expression\n\t\t\t\"text json\": JSON.parse,\n\n\t\t\t// Parse text as xml\n\t\t\t\"text xml\": jQuery.parseXML\n\t\t},\n\n\t\t// For options that shouldn't be deep extended:\n\t\t// you can add your own custom options here if\n\t\t// and when you create one that shouldn't be\n\t\t// deep extended (see ajaxExtend)\n\t\tflatOptions: {\n\t\t\turl: true,\n\t\t\tcontext: true\n\t\t}\n\t},\n\n\t// Creates a full fledged settings object into target\n\t// with both ajaxSettings and settings fields.\n\t// If target is omitted, writes into ajaxSettings.\n\tajaxSetup: function( target, settings ) {\n\t\treturn settings ?\n\n\t\t\t// Building a settings object\n\t\t\tajaxExtend( ajaxExtend( target, jQuery.ajaxSettings ), settings ) :\n\n\t\t\t// Extending ajaxSettings\n\t\t\tajaxExtend( jQuery.ajaxSettings, target );\n\t},\n\n\tajaxPrefilter: addToPrefiltersOrTransports( prefilters ),\n\tajaxTransport: addToPrefiltersOrTransports( transports ),\n\n\t// Main method\n\tajax: function( url, options ) {\n\n\t\t// If url is an object, simulate pre-1.5 signature\n\t\tif ( typeof url === \"object\" ) {\n\t\t\toptions = url;\n\t\t\turl = undefined;\n\t\t}\n\n\t\t// Force options to be an object\n\t\toptions = options || {};\n\n\t\tvar transport,\n\n\t\t\t// URL without anti-cache param\n\t\t\tcacheURL,\n\n\t\t\t// Response headers\n\t\t\tresponseHeadersString,\n\t\t\tresponseHeaders,\n\n\t\t\t// timeout handle\n\t\t\ttimeoutTimer,\n\n\t\t\t// Url cleanup var\n\t\t\turlAnchor,\n\n\t\t\t// Request state (becomes false upon send and true upon completion)\n\t\t\tcompleted,\n\n\t\t\t// To know if global events are to be dispatched\n\t\t\tfireGlobals,\n\n\t\t\t// Loop variable\n\t\t\ti,\n\n\t\t\t// uncached part of the url\n\t\t\tuncached,\n\n\t\t\t// Create the final options object\n\t\t\ts = jQuery.ajaxSetup( {}, options ),\n\n\t\t\t// Callbacks context\n\t\t\tcallbackContext = s.context || s,\n\n\t\t\t// Context for global events is callbackContext if it is a DOM node or jQuery collection\n\t\t\tglobalEventContext = s.context &&\n\t\t\t\t( callbackContext.nodeType || callbackContext.jquery ) ?\n\t\t\t\t\tjQuery( callbackContext ) :\n\t\t\t\t\tjQuery.event,\n\n\t\t\t// Deferreds\n\t\t\tdeferred = jQuery.Deferred(),\n\t\t\tcompleteDeferred = jQuery.Callbacks( \"once memory\" ),\n\n\t\t\t// Status-dependent callbacks\n\t\t\tstatusCode = s.statusCode || {},\n\n\t\t\t// Headers (they are sent all at once)\n\t\t\trequestHeaders = {},\n\t\t\trequestHeadersNames = {},\n\n\t\t\t// Default abort message\n\t\t\tstrAbort = \"canceled\",\n\n\t\t\t// Fake xhr\n\t\t\tjqXHR = {\n\t\t\t\treadyState: 0,\n\n\t\t\t\t// Builds headers hashtable if needed\n\t\t\t\tgetResponseHeader: function( key ) {\n\t\t\t\t\tvar match;\n\t\t\t\t\tif ( completed ) {\n\t\t\t\t\t\tif ( !responseHeaders ) {\n\t\t\t\t\t\t\tresponseHeaders = {};\n\t\t\t\t\t\t\twhile ( ( match = rheaders.exec( responseHeadersString ) ) ) {\n\t\t\t\t\t\t\t\tresponseHeaders[ match[ 1 ].toLowerCase() + \" \" ] =\n\t\t\t\t\t\t\t\t\t( responseHeaders[ match[ 1 ].toLowerCase() + \" \" ] || [] )\n\t\t\t\t\t\t\t\t\t\t.concat( match[ 2 ] );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tmatch = responseHeaders[ key.toLowerCase() + \" \" ];\n\t\t\t\t\t}\n\t\t\t\t\treturn match == null ? null : match.join( \", \" );\n\t\t\t\t},\n\n\t\t\t\t// Raw string\n\t\t\t\tgetAllResponseHeaders: function() {\n\t\t\t\t\treturn completed ? responseHeadersString : null;\n\t\t\t\t},\n\n\t\t\t\t// Caches the header\n\t\t\t\tsetRequestHeader: function( name, value ) {\n\t\t\t\t\tif ( completed == null ) {\n\t\t\t\t\t\tname = requestHeadersNames[ name.toLowerCase() ] =\n\t\t\t\t\t\t\trequestHeadersNames[ name.toLowerCase() ] || name;\n\t\t\t\t\t\trequestHeaders[ name ] = value;\n\t\t\t\t\t}\n\t\t\t\t\treturn this;\n\t\t\t\t},\n\n\t\t\t\t// Overrides response content-type header\n\t\t\t\toverrideMimeType: function( type ) {\n\t\t\t\t\tif ( completed == null ) {\n\t\t\t\t\t\ts.mimeType = type;\n\t\t\t\t\t}\n\t\t\t\t\treturn this;\n\t\t\t\t},\n\n\t\t\t\t// Status-dependent callbacks\n\t\t\t\tstatusCode: function( map ) {\n\t\t\t\t\tvar code;\n\t\t\t\t\tif ( map ) {\n\t\t\t\t\t\tif ( completed ) {\n\n\t\t\t\t\t\t\t// Execute the appropriate callbacks\n\t\t\t\t\t\t\tjqXHR.always( map[ jqXHR.status ] );\n\t\t\t\t\t\t} else {\n\n\t\t\t\t\t\t\t// Lazy-add the new callbacks in a way that preserves old ones\n\t\t\t\t\t\t\tfor ( code in map ) {\n\t\t\t\t\t\t\t\tstatusCode[ code ] = [ statusCode[ code ], map[ code ] ];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\treturn this;\n\t\t\t\t},\n\n\t\t\t\t// Cancel the request\n\t\t\t\tabort: function( statusText ) {\n\t\t\t\t\tvar finalText = statusText || strAbort;\n\t\t\t\t\tif ( transport ) {\n\t\t\t\t\t\ttransport.abort( finalText );\n\t\t\t\t\t}\n\t\t\t\t\tdone( 0, finalText );\n\t\t\t\t\treturn this;\n\t\t\t\t}\n\t\t\t};\n\n\t\t// Attach deferreds\n\t\tdeferred.promise( jqXHR );\n\n\t\t// Add protocol if not provided (prefilters might expect it)\n\t\t// Handle falsy url in the settings object (#10093: consistency with old signature)\n\t\t// We also use the url parameter if available\n\t\ts.url = ( ( url || s.url || location.href ) + \"\" )\n\t\t\t.replace( rprotocol, location.protocol + \"//\" );\n\n\t\t// Alias method option to type as per ticket #12004\n\t\ts.type = options.method || options.type || s.method || s.type;\n\n\t\t// Extract dataTypes list\n\t\ts.dataTypes = ( s.dataType || \"*\" ).toLowerCase().match( rnothtmlwhite ) || [ \"\" ];\n\n\t\t// A cross-domain request is in order when the origin doesn't match the current origin.\n\t\tif ( s.crossDomain == null ) {\n\t\t\turlAnchor = document.createElement( \"a\" );\n\n\t\t\t// Support: IE <=8 - 11, Edge 12 - 15\n\t\t\t// IE throws exception on accessing the href property if url is malformed,\n\t\t\t// e.g. http://example.com:80x/\n\t\t\ttry {\n\t\t\t\turlAnchor.href = s.url;\n\n\t\t\t\t// Support: IE <=8 - 11 only\n\t\t\t\t// Anchor's host property isn't correctly set when s.url is relative\n\t\t\t\turlAnchor.href = urlAnchor.href;\n\t\t\t\ts.crossDomain = originAnchor.protocol + \"//\" + originAnchor.host !==\n\t\t\t\t\turlAnchor.protocol + \"//\" + urlAnchor.host;\n\t\t\t} catch ( e ) {\n\n\t\t\t\t// If there is an error parsing the URL, assume it is crossDomain,\n\t\t\t\t// it can be rejected by the transport if it is invalid\n\t\t\t\ts.crossDomain = true;\n\t\t\t}\n\t\t}\n\n\t\t// Convert data if not already a string\n\t\tif ( s.data && s.processData && typeof s.data !== \"string\" ) {\n\t\t\ts.data = jQuery.param( s.data, s.traditional );\n\t\t}\n\n\t\t// Apply prefilters\n\t\tinspectPrefiltersOrTransports( prefilters, s, options, jqXHR );\n\n\t\t// If request was aborted inside a prefilter, stop there\n\t\tif ( completed ) {\n\t\t\treturn jqXHR;\n\t\t}\n\n\t\t// We can fire global events as of now if asked to\n\t\t// Don't fire events if jQuery.event is undefined in an AMD-usage scenario (#15118)\n\t\tfireGlobals = jQuery.event && s.global;\n\n\t\t// Watch for a new set of requests\n\t\tif ( fireGlobals && jQuery.active++ === 0 ) {\n\t\t\tjQuery.event.trigger( \"ajaxStart\" );\n\t\t}\n\n\t\t// Uppercase the type\n\t\ts.type = s.type.toUpperCase();\n\n\t\t// Determine if request has content\n\t\ts.hasContent = !rnoContent.test( s.type );\n\n\t\t// Save the URL in case we're toying with the If-Modified-Since\n\t\t// and/or If-None-Match header later on\n\t\t// Remove hash to simplify url manipulation\n\t\tcacheURL = s.url.replace( rhash, \"\" );\n\n\t\t// More options handling for requests with no content\n\t\tif ( !s.hasContent ) {\n\n\t\t\t// Remember the hash so we can put it back\n\t\t\tuncached = s.url.slice( cacheURL.length );\n\n\t\t\t// If data is available and should be processed, append data to url\n\t\t\tif ( s.data && ( s.processData || typeof s.data === \"string\" ) ) {\n\t\t\t\tcacheURL += ( rquery.test( cacheURL ) ? \"&\" : \"?\" ) + s.data;\n\n\t\t\t\t// #9682: remove data so that it's not used in an eventual retry\n\t\t\t\tdelete s.data;\n\t\t\t}\n\n\t\t\t// Add or update anti-cache param if needed\n\t\t\tif ( s.cache === false ) {\n\t\t\t\tcacheURL = cacheURL.replace( rantiCache, \"$1\" );\n\t\t\t\tuncached = ( rquery.test( cacheURL ) ? \"&\" : \"?\" ) + \"_=\" + ( nonce++ ) + uncached;\n\t\t\t}\n\n\t\t\t// Put hash and anti-cache on the URL that will be requested (gh-1732)\n\t\t\ts.url = cacheURL + uncached;\n\n\t\t// Change '%20' to '+' if this is encoded form body content (gh-2658)\n\t\t} else if ( s.data && s.processData &&\n\t\t\t( s.contentType || \"\" ).indexOf( \"application/x-www-form-urlencoded\" ) === 0 ) {\n\t\t\ts.data = s.data.replace( r20, \"+\" );\n\t\t}\n\n\t\t// Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.\n\t\tif ( s.ifModified ) {\n\t\t\tif ( jQuery.lastModified[ cacheURL ] ) {\n\t\t\t\tjqXHR.setRequestHeader( \"If-Modified-Since\", jQuery.lastModified[ cacheURL ] );\n\t\t\t}\n\t\t\tif ( jQuery.etag[ cacheURL ] ) {\n\t\t\t\tjqXHR.setRequestHeader( \"If-None-Match\", jQuery.etag[ cacheURL ] );\n\t\t\t}\n\t\t}\n\n\t\t// Set the correct header, if data is being sent\n\t\tif ( s.data && s.hasContent && s.contentType !== false || options.contentType ) {\n\t\t\tjqXHR.setRequestHeader( \"Content-Type\", s.contentType );\n\t\t}\n\n\t\t// Set the Accepts header for the server, depending on the dataType\n\t\tjqXHR.setRequestHeader(\n\t\t\t\"Accept\",\n\t\t\ts.dataTypes[ 0 ] && s.accepts[ s.dataTypes[ 0 ] ] ?\n\t\t\t\ts.accepts[ s.dataTypes[ 0 ] ] +\n\t\t\t\t\t( s.dataTypes[ 0 ] !== \"*\" ? \", \" + allTypes + \"; q=0.01\" : \"\" ) :\n\t\t\t\ts.accepts[ \"*\" ]\n\t\t);\n\n\t\t// Check for headers option\n\t\tfor ( i in s.headers ) {\n\t\t\tjqXHR.setRequestHeader( i, s.headers[ i ] );\n\t\t}\n\n\t\t// Allow custom headers/mimetypes and early abort\n\t\tif ( s.beforeSend &&\n\t\t\t( s.beforeSend.call( callbackContext, jqXHR, s ) === false || completed ) ) {\n\n\t\t\t// Abort if not done already and return\n\t\t\treturn jqXHR.abort();\n\t\t}\n\n\t\t// Aborting is no longer a cancellation\n\t\tstrAbort = \"abort\";\n\n\t\t// Install callbacks on deferreds\n\t\tcompleteDeferred.add( s.complete );\n\t\tjqXHR.done( s.success );\n\t\tjqXHR.fail( s.error );\n\n\t\t// Get transport\n\t\ttransport = inspectPrefiltersOrTransports( transports, s, options, jqXHR );\n\n\t\t// If no transport, we auto-abort\n\t\tif ( !transport ) {\n\t\t\tdone( -1, \"No Transport\" );\n\t\t} else {\n\t\t\tjqXHR.readyState = 1;\n\n\t\t\t// Send global event\n\t\t\tif ( fireGlobals ) {\n\t\t\t\tglobalEventContext.trigger( \"ajaxSend\", [ jqXHR, s ] );\n\t\t\t}\n\n\t\t\t// If request was aborted inside ajaxSend, stop there\n\t\t\tif ( completed ) {\n\t\t\t\treturn jqXHR;\n\t\t\t}\n\n\t\t\t// Timeout\n\t\t\tif ( s.async && s.timeout > 0 ) {\n\t\t\t\ttimeoutTimer = window.setTimeout( function() {\n\t\t\t\t\tjqXHR.abort( \"timeout\" );\n\t\t\t\t}, s.timeout );\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\tcompleted = false;\n\t\t\t\ttransport.send( requestHeaders, done );\n\t\t\t} catch ( e ) {\n\n\t\t\t\t// Rethrow post-completion exceptions\n\t\t\t\tif ( completed ) {\n\t\t\t\t\tthrow e;\n\t\t\t\t}\n\n\t\t\t\t// Propagate others as results\n\t\t\t\tdone( -1, e );\n\t\t\t}\n\t\t}\n\n\t\t// Callback for when everything is done\n\t\tfunction done( status, nativeStatusText, responses, headers ) {\n\t\t\tvar isSuccess, success, error, response, modified,\n\t\t\t\tstatusText = nativeStatusText;\n\n\t\t\t// Ignore repeat invocations\n\t\t\tif ( completed ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tcompleted = true;\n\n\t\t\t// Clear timeout if it exists\n\t\t\tif ( timeoutTimer ) {\n\t\t\t\twindow.clearTimeout( timeoutTimer );\n\t\t\t}\n\n\t\t\t// Dereference transport for early garbage collection\n\t\t\t// (no matter how long the jqXHR object will be used)\n\t\t\ttransport = undefined;\n\n\t\t\t// Cache response headers\n\t\t\tresponseHeadersString = headers || \"\";\n\n\t\t\t// Set readyState\n\t\t\tjqXHR.readyState = status > 0 ? 4 : 0;\n\n\t\t\t// Determine if successful\n\t\t\tisSuccess = status >= 200 && status < 300 || status === 304;\n\n\t\t\t// Get response data\n\t\t\tif ( responses ) {\n\t\t\t\tresponse = ajaxHandleResponses( s, jqXHR, responses );\n\t\t\t}\n\n\t\t\t// Convert no matter what (that way responseXXX fields are always set)\n\t\t\tresponse = ajaxConvert( s, response, jqXHR, isSuccess );\n\n\t\t\t// If successful, handle type chaining\n\t\t\tif ( isSuccess ) {\n\n\t\t\t\t// Set the If-Modified-Since and/or If-None-Match header, if in ifModified mode.\n\t\t\t\tif ( s.ifModified ) {\n\t\t\t\t\tmodified = jqXHR.getResponseHeader( \"Last-Modified\" );\n\t\t\t\t\tif ( modified ) {\n\t\t\t\t\t\tjQuery.lastModified[ cacheURL ] = modified;\n\t\t\t\t\t}\n\t\t\t\t\tmodified = jqXHR.getResponseHeader( \"etag\" );\n\t\t\t\t\tif ( modified ) {\n\t\t\t\t\t\tjQuery.etag[ cacheURL ] = modified;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// if no content\n\t\t\t\tif ( status === 204 || s.type === \"HEAD\" ) {\n\t\t\t\t\tstatusText = \"nocontent\";\n\n\t\t\t\t// if not modified\n\t\t\t\t} else if ( status === 304 ) {\n\t\t\t\t\tstatusText = \"notmodified\";\n\n\t\t\t\t// If we have data, let's convert it\n\t\t\t\t} else {\n\t\t\t\t\tstatusText = response.state;\n\t\t\t\t\tsuccess = response.data;\n\t\t\t\t\terror = response.error;\n\t\t\t\t\tisSuccess = !error;\n\t\t\t\t}\n\t\t\t} else {\n\n\t\t\t\t// Extract error from statusText and normalize for non-aborts\n\t\t\t\terror = statusText;\n\t\t\t\tif ( status || !statusText ) {\n\t\t\t\t\tstatusText = \"error\";\n\t\t\t\t\tif ( status < 0 ) {\n\t\t\t\t\t\tstatus = 0;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// Set data for the fake xhr object\n\t\t\tjqXHR.status = status;\n\t\t\tjqXHR.statusText = ( nativeStatusText || statusText ) + \"\";\n\n\t\t\t// Success/Error\n\t\t\tif ( isSuccess ) {\n\t\t\t\tdeferred.resolveWith( callbackContext, [ success, statusText, jqXHR ] );\n\t\t\t} else {\n\t\t\t\tdeferred.rejectWith( callbackContext, [ jqXHR, statusText, error ] );\n\t\t\t}\n\n\t\t\t// Status-dependent callbacks\n\t\t\tjqXHR.statusCode( statusCode );\n\t\t\tstatusCode = undefined;\n\n\t\t\tif ( fireGlobals ) {\n\t\t\t\tglobalEventContext.trigger( isSuccess ? \"ajaxSuccess\" : \"ajaxError\",\n\t\t\t\t\t[ jqXHR, s, isSuccess ? success : error ] );\n\t\t\t}\n\n\t\t\t// Complete\n\t\t\tcompleteDeferred.fireWith( callbackContext, [ jqXHR, statusText ] );\n\n\t\t\tif ( fireGlobals ) {\n\t\t\t\tglobalEventContext.trigger( \"ajaxComplete\", [ jqXHR, s ] );\n\n\t\t\t\t// Handle the global AJAX counter\n\t\t\t\tif ( !( --jQuery.active ) ) {\n\t\t\t\t\tjQuery.event.trigger( \"ajaxStop\" );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn jqXHR;\n\t},\n\n\tgetJSON: function( url, data, callback ) {\n\t\treturn jQuery.get( url, data, callback, \"json\" );\n\t},\n\n\tgetScript: function( url, callback ) {\n\t\treturn jQuery.get( url, undefined, callback, \"script\" );\n\t}\n} );\n\njQuery.each( [ \"get\", \"post\" ], function( i, method ) {\n\tjQuery[ method ] = function( url, data, callback, type ) {\n\n\t\t// Shift arguments if data argument was omitted\n\t\tif ( isFunction( data ) ) {\n\t\t\ttype = type || callback;\n\t\t\tcallback = data;\n\t\t\tdata = undefined;\n\t\t}\n\n\t\t// The url can be an options object (which then must have .url)\n\t\treturn jQuery.ajax( jQuery.extend( {\n\t\t\turl: url,\n\t\t\ttype: method,\n\t\t\tdataType: type,\n\t\t\tdata: data,\n\t\t\tsuccess: callback\n\t\t}, jQuery.isPlainObject( url ) && url ) );\n\t};\n} );\n\n\njQuery._evalUrl = function( url, options ) {\n\treturn jQuery.ajax( {\n\t\turl: url,\n\n\t\t// Make this explicit, since user can override this through ajaxSetup (#11264)\n\t\ttype: \"GET\",\n\t\tdataType: \"script\",\n\t\tcache: true,\n\t\tasync: false,\n\t\tglobal: false,\n\n\t\t// Only evaluate the response if it is successful (gh-4126)\n\t\t// dataFilter is not invoked for failure responses, so using it instead\n\t\t// of the default converter is kludgy but it works.\n\t\tconverters: {\n\t\t\t\"text script\": function() {}\n\t\t},\n\t\tdataFilter: function( response ) {\n\t\t\tjQuery.globalEval( response, options );\n\t\t}\n\t} );\n};\n\n\njQuery.fn.extend( {\n\twrapAll: function( html ) {\n\t\tvar wrap;\n\n\t\tif ( this[ 0 ] ) {\n\t\t\tif ( isFunction( html ) ) {\n\t\t\t\thtml = html.call( this[ 0 ] );\n\t\t\t}\n\n\t\t\t// The elements to wrap the target around\n\t\t\twrap = jQuery( html, this[ 0 ].ownerDocument ).eq( 0 ).clone( true );\n\n\t\t\tif ( this[ 0 ].parentNode ) {\n\t\t\t\twrap.insertBefore( this[ 0 ] );\n\t\t\t}\n\n\t\t\twrap.map( function() {\n\t\t\t\tvar elem = this;\n\n\t\t\t\twhile ( elem.firstElementChild ) {\n\t\t\t\t\telem = elem.firstElementChild;\n\t\t\t\t}\n\n\t\t\t\treturn elem;\n\t\t\t} ).append( this );\n\t\t}\n\n\t\treturn this;\n\t},\n\n\twrapInner: function( html ) {\n\t\tif ( isFunction( html ) ) {\n\t\t\treturn this.each( function( i ) {\n\t\t\t\tjQuery( this ).wrapInner( html.call( this, i ) );\n\t\t\t} );\n\t\t}\n\n\t\treturn this.each( function() {\n\t\t\tvar self = jQuery( this ),\n\t\t\t\tcontents = self.contents();\n\n\t\t\tif ( contents.length ) {\n\t\t\t\tcontents.wrapAll( html );\n\n\t\t\t} else {\n\t\t\t\tself.append( html );\n\t\t\t}\n\t\t} );\n\t},\n\n\twrap: function( html ) {\n\t\tvar htmlIsFunction = isFunction( html );\n\n\t\treturn this.each( function( i ) {\n\t\t\tjQuery( this ).wrapAll( htmlIsFunction ? html.call( this, i ) : html );\n\t\t} );\n\t},\n\n\tunwrap: function( selector ) {\n\t\tthis.parent( selector ).not( \"body\" ).each( function() {\n\t\t\tjQuery( this ).replaceWith( this.childNodes );\n\t\t} );\n\t\treturn this;\n\t}\n} );\n\n\njQuery.expr.pseudos.hidden = function( elem ) {\n\treturn !jQuery.expr.pseudos.visible( elem );\n};\njQuery.expr.pseudos.visible = function( elem ) {\n\treturn !!( elem.offsetWidth || elem.offsetHeight || elem.getClientRects().length );\n};\n\n\n\n\njQuery.ajaxSettings.xhr = function() {\n\ttry {\n\t\treturn new window.XMLHttpRequest();\n\t} catch ( e ) {}\n};\n\nvar xhrSuccessStatus = {\n\n\t\t// File protocol always yields status code 0, assume 200\n\t\t0: 200,\n\n\t\t// Support: IE <=9 only\n\t\t// #1450: sometimes IE returns 1223 when it should be 204\n\t\t1223: 204\n\t},\n\txhrSupported = jQuery.ajaxSettings.xhr();\n\nsupport.cors = !!xhrSupported && ( \"withCredentials\" in xhrSupported );\nsupport.ajax = xhrSupported = !!xhrSupported;\n\njQuery.ajaxTransport( function( options ) {\n\tvar callback, errorCallback;\n\n\t// Cross domain only allowed if supported through XMLHttpRequest\n\tif ( support.cors || xhrSupported && !options.crossDomain ) {\n\t\treturn {\n\t\t\tsend: function( headers, complete ) {\n\t\t\t\tvar i,\n\t\t\t\t\txhr = options.xhr();\n\n\t\t\t\txhr.open(\n\t\t\t\t\toptions.type,\n\t\t\t\t\toptions.url,\n\t\t\t\t\toptions.async,\n\t\t\t\t\toptions.username,\n\t\t\t\t\toptions.password\n\t\t\t\t);\n\n\t\t\t\t// Apply custom fields if provided\n\t\t\t\tif ( options.xhrFields ) {\n\t\t\t\t\tfor ( i in options.xhrFields ) {\n\t\t\t\t\t\txhr[ i ] = options.xhrFields[ i ];\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Override mime type if needed\n\t\t\t\tif ( options.mimeType && xhr.overrideMimeType ) {\n\t\t\t\t\txhr.overrideMimeType( options.mimeType );\n\t\t\t\t}\n\n\t\t\t\t// X-Requested-With header\n\t\t\t\t// For cross-domain requests, seeing as conditions for a preflight are\n\t\t\t\t// akin to a jigsaw puzzle, we simply never set it to be sure.\n\t\t\t\t// (it can always be set on a per-request basis or even using ajaxSetup)\n\t\t\t\t// For same-domain requests, won't change header if already provided.\n\t\t\t\tif ( !options.crossDomain && !headers[ \"X-Requested-With\" ] ) {\n\t\t\t\t\theaders[ \"X-Requested-With\" ] = \"XMLHttpRequest\";\n\t\t\t\t}\n\n\t\t\t\t// Set headers\n\t\t\t\tfor ( i in headers ) {\n\t\t\t\t\txhr.setRequestHeader( i, headers[ i ] );\n\t\t\t\t}\n\n\t\t\t\t// Callback\n\t\t\t\tcallback = function( type ) {\n\t\t\t\t\treturn function() {\n\t\t\t\t\t\tif ( callback ) {\n\t\t\t\t\t\t\tcallback = errorCallback = xhr.onload =\n\t\t\t\t\t\t\t\txhr.onerror = xhr.onabort = xhr.ontimeout =\n\t\t\t\t\t\t\t\t\txhr.onreadystatechange = null;\n\n\t\t\t\t\t\t\tif ( type === \"abort\" ) {\n\t\t\t\t\t\t\t\txhr.abort();\n\t\t\t\t\t\t\t} else if ( type === \"error\" ) {\n\n\t\t\t\t\t\t\t\t// Support: IE <=9 only\n\t\t\t\t\t\t\t\t// On a manual native abort, IE9 throws\n\t\t\t\t\t\t\t\t// errors on any property access that is not readyState\n\t\t\t\t\t\t\t\tif ( typeof xhr.status !== \"number\" ) {\n\t\t\t\t\t\t\t\t\tcomplete( 0, \"error\" );\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tcomplete(\n\n\t\t\t\t\t\t\t\t\t\t// File: protocol always yields status 0; see #8605, #14207\n\t\t\t\t\t\t\t\t\t\txhr.status,\n\t\t\t\t\t\t\t\t\t\txhr.statusText\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tcomplete(\n\t\t\t\t\t\t\t\t\txhrSuccessStatus[ xhr.status ] || xhr.status,\n\t\t\t\t\t\t\t\t\txhr.statusText,\n\n\t\t\t\t\t\t\t\t\t// Support: IE <=9 only\n\t\t\t\t\t\t\t\t\t// IE9 has no XHR2 but throws on binary (trac-11426)\n\t\t\t\t\t\t\t\t\t// For XHR2 non-text, let the caller handle it (gh-2498)\n\t\t\t\t\t\t\t\t\t( xhr.responseType || \"text\" ) !== \"text\"  ||\n\t\t\t\t\t\t\t\t\ttypeof xhr.responseText !== \"string\" ?\n\t\t\t\t\t\t\t\t\t\t{ binary: xhr.response } :\n\t\t\t\t\t\t\t\t\t\t{ text: xhr.responseText },\n\t\t\t\t\t\t\t\t\txhr.getAllResponseHeaders()\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t};\n\n\t\t\t\t// Listen to events\n\t\t\t\txhr.onload = callback();\n\t\t\t\terrorCallback = xhr.onerror = xhr.ontimeout = callback( \"error\" );\n\n\t\t\t\t// Support: IE 9 only\n\t\t\t\t// Use onreadystatechange to replace onabort\n\t\t\t\t// to handle uncaught aborts\n\t\t\t\tif ( xhr.onabort !== undefined ) {\n\t\t\t\t\txhr.onabort = errorCallback;\n\t\t\t\t} else {\n\t\t\t\t\txhr.onreadystatechange = function() {\n\n\t\t\t\t\t\t// Check readyState before timeout as it changes\n\t\t\t\t\t\tif ( xhr.readyState === 4 ) {\n\n\t\t\t\t\t\t\t// Allow onerror to be called first,\n\t\t\t\t\t\t\t// but that will not handle a native abort\n\t\t\t\t\t\t\t// Also, save errorCallback to a variable\n\t\t\t\t\t\t\t// as xhr.onerror cannot be accessed\n\t\t\t\t\t\t\twindow.setTimeout( function() {\n\t\t\t\t\t\t\t\tif ( callback ) {\n\t\t\t\t\t\t\t\t\terrorCallback();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} );\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\t\t\t\t}\n\n\t\t\t\t// Create the abort callback\n\t\t\t\tcallback = callback( \"abort\" );\n\n\t\t\t\ttry {\n\n\t\t\t\t\t// Do send the request (this may raise an exception)\n\t\t\t\t\txhr.send( options.hasContent && options.data || null );\n\t\t\t\t} catch ( e ) {\n\n\t\t\t\t\t// #14683: Only rethrow if this hasn't been notified as an error yet\n\t\t\t\t\tif ( callback ) {\n\t\t\t\t\t\tthrow e;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t},\n\n\t\t\tabort: function() {\n\t\t\t\tif ( callback ) {\n\t\t\t\t\tcallback();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t}\n} );\n\n\n\n\n// Prevent auto-execution of scripts when no explicit dataType was provided (See gh-2432)\njQuery.ajaxPrefilter( function( s ) {\n\tif ( s.crossDomain ) {\n\t\ts.contents.script = false;\n\t}\n} );\n\n// Install script dataType\njQuery.ajaxSetup( {\n\taccepts: {\n\t\tscript: \"text/javascript, application/javascript, \" +\n\t\t\t\"application/ecmascript, application/x-ecmascript\"\n\t},\n\tcontents: {\n\t\tscript: /\\b(?:java|ecma)script\\b/\n\t},\n\tconverters: {\n\t\t\"text script\": function( text ) {\n\t\t\tjQuery.globalEval( text );\n\t\t\treturn text;\n\t\t}\n\t}\n} );\n\n// Handle cache's special case and crossDomain\njQuery.ajaxPrefilter( \"script\", function( s ) {\n\tif ( s.cache === undefined ) {\n\t\ts.cache = false;\n\t}\n\tif ( s.crossDomain ) {\n\t\ts.type = \"GET\";\n\t}\n} );\n\n// Bind script tag hack transport\njQuery.ajaxTransport( \"script\", function( s ) {\n\n\t// This transport only deals with cross domain or forced-by-attrs requests\n\tif ( s.crossDomain || s.scriptAttrs ) {\n\t\tvar script, callback;\n\t\treturn {\n\t\t\tsend: function( _, complete ) {\n\t\t\t\tscript = jQuery( \"<script>\" )\n\t\t\t\t\t.attr( s.scriptAttrs || {} )\n\t\t\t\t\t.prop( { charset: s.scriptCharset, src: s.url } )\n\t\t\t\t\t.on( \"load error\", callback = function( evt ) {\n\t\t\t\t\t\tscript.remove();\n\t\t\t\t\t\tcallback = null;\n\t\t\t\t\t\tif ( evt ) {\n\t\t\t\t\t\t\tcomplete( evt.type === \"error\" ? 404 : 200, evt.type );\n\t\t\t\t\t\t}\n\t\t\t\t\t} );\n\n\t\t\t\t// Use native DOM manipulation to avoid our domManip AJAX trickery\n\t\t\t\tdocument.head.appendChild( script[ 0 ] );\n\t\t\t},\n\t\t\tabort: function() {\n\t\t\t\tif ( callback ) {\n\t\t\t\t\tcallback();\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t}\n} );\n\n\n\n\nvar oldCallbacks = [],\n\trjsonp = /(=)\\?(?=&|$)|\\?\\?/;\n\n// Default jsonp settings\njQuery.ajaxSetup( {\n\tjsonp: \"callback\",\n\tjsonpCallback: function() {\n\t\tvar callback = oldCallbacks.pop() || ( jQuery.expando + \"_\" + ( nonce++ ) );\n\t\tthis[ callback ] = true;\n\t\treturn callback;\n\t}\n} );\n\n// Detect, normalize options and install callbacks for jsonp requests\njQuery.ajaxPrefilter( \"json jsonp\", function( s, originalSettings, jqXHR ) {\n\n\tvar callbackName, overwritten, responseContainer,\n\t\tjsonProp = s.jsonp !== false && ( rjsonp.test( s.url ) ?\n\t\t\t\"url\" :\n\t\t\ttypeof s.data === \"string\" &&\n\t\t\t\t( s.contentType || \"\" )\n\t\t\t\t\t.indexOf( \"application/x-www-form-urlencoded\" ) === 0 &&\n\t\t\t\trjsonp.test( s.data ) && \"data\"\n\t\t);\n\n\t// Handle iff the expected data type is \"jsonp\" or we have a parameter to set\n\tif ( jsonProp || s.dataTypes[ 0 ] === \"jsonp\" ) {\n\n\t\t// Get callback name, remembering preexisting value associated with it\n\t\tcallbackName = s.jsonpCallback = isFunction( s.jsonpCallback ) ?\n\t\t\ts.jsonpCallback() :\n\t\t\ts.jsonpCallback;\n\n\t\t// Insert callback into url or form data\n\t\tif ( jsonProp ) {\n\t\t\ts[ jsonProp ] = s[ jsonProp ].replace( rjsonp, \"$1\" + callbackName );\n\t\t} else if ( s.jsonp !== false ) {\n\t\t\ts.url += ( rquery.test( s.url ) ? \"&\" : \"?\" ) + s.jsonp + \"=\" + callbackName;\n\t\t}\n\n\t\t// Use data converter to retrieve json after script execution\n\t\ts.converters[ \"script json\" ] = function() {\n\t\t\tif ( !responseContainer ) {\n\t\t\t\tjQuery.error( callbackName + \" was not called\" );\n\t\t\t}\n\t\t\treturn responseContainer[ 0 ];\n\t\t};\n\n\t\t// Force json dataType\n\t\ts.dataTypes[ 0 ] = \"json\";\n\n\t\t// Install callback\n\t\toverwritten = window[ callbackName ];\n\t\twindow[ callbackName ] = function() {\n\t\t\tresponseContainer = arguments;\n\t\t};\n\n\t\t// Clean-up function (fires after converters)\n\t\tjqXHR.always( function() {\n\n\t\t\t// If previous value didn't exist - remove it\n\t\t\tif ( overwritten === undefined ) {\n\t\t\t\tjQuery( window ).removeProp( callbackName );\n\n\t\t\t// Otherwise restore preexisting value\n\t\t\t} else {\n\t\t\t\twindow[ callbackName ] = overwritten;\n\t\t\t}\n\n\t\t\t// Save back as free\n\t\t\tif ( s[ callbackName ] ) {\n\n\t\t\t\t// Make sure that re-using the options doesn't screw things around\n\t\t\t\ts.jsonpCallback = originalSettings.jsonpCallback;\n\n\t\t\t\t// Save the callback name for future use\n\t\t\t\toldCallbacks.push( callbackName );\n\t\t\t}\n\n\t\t\t// Call if it was a function and we have a response\n\t\t\tif ( responseContainer && isFunction( overwritten ) ) {\n\t\t\t\toverwritten( responseContainer[ 0 ] );\n\t\t\t}\n\n\t\t\tresponseContainer = overwritten = undefined;\n\t\t} );\n\n\t\t// Delegate to script\n\t\treturn \"script\";\n\t}\n} );\n\n\n\n\n// Support: Safari 8 only\n// In Safari 8 documents created via document.implementation.createHTMLDocument\n// collapse sibling forms: the second one becomes a child of the first one.\n// Because of that, this security measure has to be disabled in Safari 8.\n// https://bugs.webkit.org/show_bug.cgi?id=137337\nsupport.createHTMLDocument = ( function() {\n\tvar body = document.implementation.createHTMLDocument( \"\" ).body;\n\tbody.innerHTML = \"<form></form><form></form>\";\n\treturn body.childNodes.length === 2;\n} )();\n\n\n// Argument \"data\" should be string of html\n// context (optional): If specified, the fragment will be created in this context,\n// defaults to document\n// keepScripts (optional): If true, will include scripts passed in the html string\njQuery.parseHTML = function( data, context, keepScripts ) {\n\tif ( typeof data !== \"string\" ) {\n\t\treturn [];\n\t}\n\tif ( typeof context === \"boolean\" ) {\n\t\tkeepScripts = context;\n\t\tcontext = false;\n\t}\n\n\tvar base, parsed, scripts;\n\n\tif ( !context ) {\n\n\t\t// Stop scripts or inline event handlers from being executed immediately\n\t\t// by using document.implementation\n\t\tif ( support.createHTMLDocument ) {\n\t\t\tcontext = document.implementation.createHTMLDocument( \"\" );\n\n\t\t\t// Set the base href for the created document\n\t\t\t// so any parsed elements with URLs\n\t\t\t// are based on the document's URL (gh-2965)\n\t\t\tbase = context.createElement( \"base\" );\n\t\t\tbase.href = document.location.href;\n\t\t\tcontext.head.appendChild( base );\n\t\t} else {\n\t\t\tcontext = document;\n\t\t}\n\t}\n\n\tparsed = rsingleTag.exec( data );\n\tscripts = !keepScripts && [];\n\n\t// Single tag\n\tif ( parsed ) {\n\t\treturn [ context.createElement( parsed[ 1 ] ) ];\n\t}\n\n\tparsed = buildFragment( [ data ], context, scripts );\n\n\tif ( scripts && scripts.length ) {\n\t\tjQuery( scripts ).remove();\n\t}\n\n\treturn jQuery.merge( [], parsed.childNodes );\n};\n\n\n/**\n * Load a url into a page\n */\njQuery.fn.load = function( url, params, callback ) {\n\tvar selector, type, response,\n\t\tself = this,\n\t\toff = url.indexOf( \" \" );\n\n\tif ( off > -1 ) {\n\t\tselector = stripAndCollapse( url.slice( off ) );\n\t\turl = url.slice( 0, off );\n\t}\n\n\t// If it's a function\n\tif ( isFunction( params ) ) {\n\n\t\t// We assume that it's the callback\n\t\tcallback = params;\n\t\tparams = undefined;\n\n\t// Otherwise, build a param string\n\t} else if ( params && typeof params === \"object\" ) {\n\t\ttype = \"POST\";\n\t}\n\n\t// If we have elements to modify, make the request\n\tif ( self.length > 0 ) {\n\t\tjQuery.ajax( {\n\t\t\turl: url,\n\n\t\t\t// If \"type\" variable is undefined, then \"GET\" method will be used.\n\t\t\t// Make value of this field explicit since\n\t\t\t// user can override it through ajaxSetup method\n\t\t\ttype: type || \"GET\",\n\t\t\tdataType: \"html\",\n\t\t\tdata: params\n\t\t} ).done( function( responseText ) {\n\n\t\t\t// Save response for use in complete callback\n\t\t\tresponse = arguments;\n\n\t\t\tself.html( selector ?\n\n\t\t\t\t// If a selector was specified, locate the right elements in a dummy div\n\t\t\t\t// Exclude scripts to avoid IE 'Permission Denied' errors\n\t\t\t\tjQuery( \"<div>\" ).append( jQuery.parseHTML( responseText ) ).find( selector ) :\n\n\t\t\t\t// Otherwise use the full result\n\t\t\t\tresponseText );\n\n\t\t// If the request succeeds, this function gets \"data\", \"status\", \"jqXHR\"\n\t\t// but they are ignored because response was set above.\n\t\t// If it fails, this function gets \"jqXHR\", \"status\", \"error\"\n\t\t} ).always( callback && function( jqXHR, status ) {\n\t\t\tself.each( function() {\n\t\t\t\tcallback.apply( this, response || [ jqXHR.responseText, status, jqXHR ] );\n\t\t\t} );\n\t\t} );\n\t}\n\n\treturn this;\n};\n\n\n\n\n// Attach a bunch of functions for handling common AJAX events\njQuery.each( [\n\t\"ajaxStart\",\n\t\"ajaxStop\",\n\t\"ajaxComplete\",\n\t\"ajaxError\",\n\t\"ajaxSuccess\",\n\t\"ajaxSend\"\n], function( i, type ) {\n\tjQuery.fn[ type ] = function( fn ) {\n\t\treturn this.on( type, fn );\n\t};\n} );\n\n\n\n\njQuery.expr.pseudos.animated = function( elem ) {\n\treturn jQuery.grep( jQuery.timers, function( fn ) {\n\t\treturn elem === fn.elem;\n\t} ).length;\n};\n\n\n\n\njQuery.offset = {\n\tsetOffset: function( elem, options, i ) {\n\t\tvar curPosition, curLeft, curCSSTop, curTop, curOffset, curCSSLeft, calculatePosition,\n\t\t\tposition = jQuery.css( elem, \"position\" ),\n\t\t\tcurElem = jQuery( elem ),\n\t\t\tprops = {};\n\n\t\t// Set position first, in-case top/left are set even on static elem\n\t\tif ( position === \"static\" ) {\n\t\t\telem.style.position = \"relative\";\n\t\t}\n\n\t\tcurOffset = curElem.offset();\n\t\tcurCSSTop = jQuery.css( elem, \"top\" );\n\t\tcurCSSLeft = jQuery.css( elem, \"left\" );\n\t\tcalculatePosition = ( position === \"absolute\" || position === \"fixed\" ) &&\n\t\t\t( curCSSTop + curCSSLeft ).indexOf( \"auto\" ) > -1;\n\n\t\t// Need to be able to calculate position if either\n\t\t// top or left is auto and position is either absolute or fixed\n\t\tif ( calculatePosition ) {\n\t\t\tcurPosition = curElem.position();\n\t\t\tcurTop = curPosition.top;\n\t\t\tcurLeft = curPosition.left;\n\n\t\t} else {\n\t\t\tcurTop = parseFloat( curCSSTop ) || 0;\n\t\t\tcurLeft = parseFloat( curCSSLeft ) || 0;\n\t\t}\n\n\t\tif ( isFunction( options ) ) {\n\n\t\t\t// Use jQuery.extend here to allow modification of coordinates argument (gh-1848)\n\t\t\toptions = options.call( elem, i, jQuery.extend( {}, curOffset ) );\n\t\t}\n\n\t\tif ( options.top != null ) {\n\t\t\tprops.top = ( options.top - curOffset.top ) + curTop;\n\t\t}\n\t\tif ( options.left != null ) {\n\t\t\tprops.left = ( options.left - curOffset.left ) + curLeft;\n\t\t}\n\n\t\tif ( \"using\" in options ) {\n\t\t\toptions.using.call( elem, props );\n\n\t\t} else {\n\t\t\tcurElem.css( props );\n\t\t}\n\t}\n};\n\njQuery.fn.extend( {\n\n\t// offset() relates an element's border box to the document origin\n\toffset: function( options ) {\n\n\t\t// Preserve chaining for setter\n\t\tif ( arguments.length ) {\n\t\t\treturn options === undefined ?\n\t\t\t\tthis :\n\t\t\t\tthis.each( function( i ) {\n\t\t\t\t\tjQuery.offset.setOffset( this, options, i );\n\t\t\t\t} );\n\t\t}\n\n\t\tvar rect, win,\n\t\t\telem = this[ 0 ];\n\n\t\tif ( !elem ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Return zeros for disconnected and hidden (display: none) elements (gh-2310)\n\t\t// Support: IE <=11 only\n\t\t// Running getBoundingClientRect on a\n\t\t// disconnected node in IE throws an error\n\t\tif ( !elem.getClientRects().length ) {\n\t\t\treturn { top: 0, left: 0 };\n\t\t}\n\n\t\t// Get document-relative position by adding viewport scroll to viewport-relative gBCR\n\t\trect = elem.getBoundingClientRect();\n\t\twin = elem.ownerDocument.defaultView;\n\t\treturn {\n\t\t\ttop: rect.top + win.pageYOffset,\n\t\t\tleft: rect.left + win.pageXOffset\n\t\t};\n\t},\n\n\t// position() relates an element's margin box to its offset parent's padding box\n\t// This corresponds to the behavior of CSS absolute positioning\n\tposition: function() {\n\t\tif ( !this[ 0 ] ) {\n\t\t\treturn;\n\t\t}\n\n\t\tvar offsetParent, offset, doc,\n\t\t\telem = this[ 0 ],\n\t\t\tparentOffset = { top: 0, left: 0 };\n\n\t\t// position:fixed elements are offset from the viewport, which itself always has zero offset\n\t\tif ( jQuery.css( elem, \"position\" ) === \"fixed\" ) {\n\n\t\t\t// Assume position:fixed implies availability of getBoundingClientRect\n\t\t\toffset = elem.getBoundingClientRect();\n\n\t\t} else {\n\t\t\toffset = this.offset();\n\n\t\t\t// Account for the *real* offset parent, which can be the document or its root element\n\t\t\t// when a statically positioned element is identified\n\t\t\tdoc = elem.ownerDocument;\n\t\t\toffsetParent = elem.offsetParent || doc.documentElement;\n\t\t\twhile ( offsetParent &&\n\t\t\t\t( offsetParent === doc.body || offsetParent === doc.documentElement ) &&\n\t\t\t\tjQuery.css( offsetParent, \"position\" ) === \"static\" ) {\n\n\t\t\t\toffsetParent = offsetParent.parentNode;\n\t\t\t}\n\t\t\tif ( offsetParent && offsetParent !== elem && offsetParent.nodeType === 1 ) {\n\n\t\t\t\t// Incorporate borders into its offset, since they are outside its content origin\n\t\t\t\tparentOffset = jQuery( offsetParent ).offset();\n\t\t\t\tparentOffset.top += jQuery.css( offsetParent, \"borderTopWidth\", true );\n\t\t\t\tparentOffset.left += jQuery.css( offsetParent, \"borderLeftWidth\", true );\n\t\t\t}\n\t\t}\n\n\t\t// Subtract parent offsets and element margins\n\t\treturn {\n\t\t\ttop: offset.top - parentOffset.top - jQuery.css( elem, \"marginTop\", true ),\n\t\t\tleft: offset.left - parentOffset.left - jQuery.css( elem, \"marginLeft\", true )\n\t\t};\n\t},\n\n\t// This method will return documentElement in the following cases:\n\t// 1) For the element inside the iframe without offsetParent, this method will return\n\t//    documentElement of the parent window\n\t// 2) For the hidden or detached element\n\t// 3) For body or html element, i.e. in case of the html node - it will return itself\n\t//\n\t// but those exceptions were never presented as a real life use-cases\n\t// and might be considered as more preferable results.\n\t//\n\t// This logic, however, is not guaranteed and can change at any point in the future\n\toffsetParent: function() {\n\t\treturn this.map( function() {\n\t\t\tvar offsetParent = this.offsetParent;\n\n\t\t\twhile ( offsetParent && jQuery.css( offsetParent, \"position\" ) === \"static\" ) {\n\t\t\t\toffsetParent = offsetParent.offsetParent;\n\t\t\t}\n\n\t\t\treturn offsetParent || documentElement;\n\t\t} );\n\t}\n} );\n\n// Create scrollLeft and scrollTop methods\njQuery.each( { scrollLeft: \"pageXOffset\", scrollTop: \"pageYOffset\" }, function( method, prop ) {\n\tvar top = \"pageYOffset\" === prop;\n\n\tjQuery.fn[ method ] = function( val ) {\n\t\treturn access( this, function( elem, method, val ) {\n\n\t\t\t// Coalesce documents and windows\n\t\t\tvar win;\n\t\t\tif ( isWindow( elem ) ) {\n\t\t\t\twin = elem;\n\t\t\t} else if ( elem.nodeType === 9 ) {\n\t\t\t\twin = elem.defaultView;\n\t\t\t}\n\n\t\t\tif ( val === undefined ) {\n\t\t\t\treturn win ? win[ prop ] : elem[ method ];\n\t\t\t}\n\n\t\t\tif ( win ) {\n\t\t\t\twin.scrollTo(\n\t\t\t\t\t!top ? val : win.pageXOffset,\n\t\t\t\t\ttop ? val : win.pageYOffset\n\t\t\t\t);\n\n\t\t\t} else {\n\t\t\t\telem[ method ] = val;\n\t\t\t}\n\t\t}, method, val, arguments.length );\n\t};\n} );\n\n// Support: Safari <=7 - 9.1, Chrome <=37 - 49\n// Add the top/left cssHooks using jQuery.fn.position\n// Webkit bug: https://bugs.webkit.org/show_bug.cgi?id=29084\n// Blink bug: https://bugs.chromium.org/p/chromium/issues/detail?id=589347\n// getComputedStyle returns percent when specified for top/left/bottom/right;\n// rather than make the css module depend on the offset module, just check for it here\njQuery.each( [ \"top\", \"left\" ], function( i, prop ) {\n\tjQuery.cssHooks[ prop ] = addGetHookIf( support.pixelPosition,\n\t\tfunction( elem, computed ) {\n\t\t\tif ( computed ) {\n\t\t\t\tcomputed = curCSS( elem, prop );\n\n\t\t\t\t// If curCSS returns percentage, fallback to offset\n\t\t\t\treturn rnumnonpx.test( computed ) ?\n\t\t\t\t\tjQuery( elem ).position()[ prop ] + \"px\" :\n\t\t\t\t\tcomputed;\n\t\t\t}\n\t\t}\n\t);\n} );\n\n\n// Create innerHeight, innerWidth, height, width, outerHeight and outerWidth methods\njQuery.each( { Height: \"height\", Width: \"width\" }, function( name, type ) {\n\tjQuery.each( { padding: \"inner\" + name, content: type, \"\": \"outer\" + name },\n\t\tfunction( defaultExtra, funcName ) {\n\n\t\t// Margin is only for outerHeight, outerWidth\n\t\tjQuery.fn[ funcName ] = function( margin, value ) {\n\t\t\tvar chainable = arguments.length && ( defaultExtra || typeof margin !== \"boolean\" ),\n\t\t\t\textra = defaultExtra || ( margin === true || value === true ? \"margin\" : \"border\" );\n\n\t\t\treturn access( this, function( elem, type, value ) {\n\t\t\t\tvar doc;\n\n\t\t\t\tif ( isWindow( elem ) ) {\n\n\t\t\t\t\t// $( window ).outerWidth/Height return w/h including scrollbars (gh-1729)\n\t\t\t\t\treturn funcName.indexOf( \"outer\" ) === 0 ?\n\t\t\t\t\t\telem[ \"inner\" + name ] :\n\t\t\t\t\t\telem.document.documentElement[ \"client\" + name ];\n\t\t\t\t}\n\n\t\t\t\t// Get document width or height\n\t\t\t\tif ( elem.nodeType === 9 ) {\n\t\t\t\t\tdoc = elem.documentElement;\n\n\t\t\t\t\t// Either scroll[Width/Height] or offset[Width/Height] or client[Width/Height],\n\t\t\t\t\t// whichever is greatest\n\t\t\t\t\treturn Math.max(\n\t\t\t\t\t\telem.body[ \"scroll\" + name ], doc[ \"scroll\" + name ],\n\t\t\t\t\t\telem.body[ \"offset\" + name ], doc[ \"offset\" + name ],\n\t\t\t\t\t\tdoc[ \"client\" + name ]\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\treturn value === undefined ?\n\n\t\t\t\t\t// Get width or height on the element, requesting but not forcing parseFloat\n\t\t\t\t\tjQuery.css( elem, type, extra ) :\n\n\t\t\t\t\t// Set width or height on the element\n\t\t\t\t\tjQuery.style( elem, type, value, extra );\n\t\t\t}, type, chainable ? margin : undefined, chainable );\n\t\t};\n\t} );\n} );\n\n\njQuery.each( ( \"blur focus focusin focusout resize scroll click dblclick \" +\n\t\"mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave \" +\n\t\"change select submit keydown keypress keyup contextmenu\" ).split( \" \" ),\n\tfunction( i, name ) {\n\n\t// Handle event binding\n\tjQuery.fn[ name ] = function( data, fn ) {\n\t\treturn arguments.length > 0 ?\n\t\t\tthis.on( name, null, data, fn ) :\n\t\t\tthis.trigger( name );\n\t};\n} );\n\njQuery.fn.extend( {\n\thover: function( fnOver, fnOut ) {\n\t\treturn this.mouseenter( fnOver ).mouseleave( fnOut || fnOver );\n\t}\n} );\n\n\n\n\njQuery.fn.extend( {\n\n\tbind: function( types, data, fn ) {\n\t\treturn this.on( types, null, data, fn );\n\t},\n\tunbind: function( types, fn ) {\n\t\treturn this.off( types, null, fn );\n\t},\n\n\tdelegate: function( selector, types, data, fn ) {\n\t\treturn this.on( types, selector, data, fn );\n\t},\n\tundelegate: function( selector, types, fn ) {\n\n\t\t// ( namespace ) or ( selector, types [, fn] )\n\t\treturn arguments.length === 1 ?\n\t\t\tthis.off( selector, \"**\" ) :\n\t\t\tthis.off( types, selector || \"**\", fn );\n\t}\n} );\n\n// Bind a function to a context, optionally partially applying any\n// arguments.\n// jQuery.proxy is deprecated to promote standards (specifically Function#bind)\n// However, it is not slated for removal any time soon\njQuery.proxy = function( fn, context ) {\n\tvar tmp, args, proxy;\n\n\tif ( typeof context === \"string\" ) {\n\t\ttmp = fn[ context ];\n\t\tcontext = fn;\n\t\tfn = tmp;\n\t}\n\n\t// Quick check to determine if target is callable, in the spec\n\t// this throws a TypeError, but we will just return undefined.\n\tif ( !isFunction( fn ) ) {\n\t\treturn undefined;\n\t}\n\n\t// Simulated bind\n\targs = slice.call( arguments, 2 );\n\tproxy = function() {\n\t\treturn fn.apply( context || this, args.concat( slice.call( arguments ) ) );\n\t};\n\n\t// Set the guid of unique handler to the same of original handler, so it can be removed\n\tproxy.guid = fn.guid = fn.guid || jQuery.guid++;\n\n\treturn proxy;\n};\n\njQuery.holdReady = function( hold ) {\n\tif ( hold ) {\n\t\tjQuery.readyWait++;\n\t} else {\n\t\tjQuery.ready( true );\n\t}\n};\njQuery.isArray = Array.isArray;\njQuery.parseJSON = JSON.parse;\njQuery.nodeName = nodeName;\njQuery.isFunction = isFunction;\njQuery.isWindow = isWindow;\njQuery.camelCase = camelCase;\njQuery.type = toType;\n\njQuery.now = Date.now;\n\njQuery.isNumeric = function( obj ) {\n\n\t// As of jQuery 3.0, isNumeric is limited to\n\t// strings and numbers (primitives or objects)\n\t// that can be coerced to finite numbers (gh-2662)\n\tvar type = jQuery.type( obj );\n\treturn ( type === \"number\" || type === \"string\" ) &&\n\n\t\t// parseFloat NaNs numeric-cast false positives (\"\")\n\t\t// ...but misinterprets leading-number strings, particularly hex literals (\"0x...\")\n\t\t// subtraction forces infinities to NaN\n\t\t!isNaN( obj - parseFloat( obj ) );\n};\n\n\n\n\n// Register as a named AMD module, since jQuery can be concatenated with other\n// files that may use define, but not via a proper concatenation script that\n// understands anonymous AMD modules. A named AMD is safest and most robust\n// way to register. Lowercase jquery is used because AMD module names are\n// derived from file names, and jQuery is normally delivered in a lowercase\n// file name. Do this after creating the global so that if an AMD module wants\n// to call noConflict to hide this version of jQuery, it will work.\n\n// Note that for maximum portability, libraries that are not jQuery should\n// declare themselves as anonymous modules, and avoid setting a global if an\n// AMD loader is present. jQuery is a special case. For more information, see\n// https://github.com/jrburke/requirejs/wiki/Updating-existing-libraries#wiki-anon\n\nif ( typeof define === \"function\" && define.amd ) {\n\tdefine( \"jquery\", [], function() {\n\t\treturn jQuery;\n\t} );\n}\n\n\n\n\nvar\n\n\t// Map over jQuery in case of overwrite\n\t_jQuery = window.jQuery,\n\n\t// Map over the $ in case of overwrite\n\t_$ = window.$;\n\njQuery.noConflict = function( deep ) {\n\tif ( window.$ === jQuery ) {\n\t\twindow.$ = _$;\n\t}\n\n\tif ( deep && window.jQuery === jQuery ) {\n\t\twindow.jQuery = _jQuery;\n\t}\n\n\treturn jQuery;\n};\n\n// Expose jQuery and $ identifiers, even in AMD\n// (#7102#comment:10, https://github.com/jquery/jquery/pull/557)\n// and CommonJS for browser emulators (#13566)\nif ( !noGlobal ) {\n\twindow.jQuery = window.$ = jQuery;\n}\n\n\n\n\nreturn jQuery;\n} );\n","\"use strict\";\n\n/*\n  MIT License http://www.opensource.org/licenses/mit-license.php\n  Author Tobias Koppers @sokra\n*/\n// css base code, injected by the css-loader\n// eslint-disable-next-line func-names\nmodule.exports = function (useSourceMap) {\n  var list = []; // return the list of modules as css string\n\n  list.toString = function toString() {\n    return this.map(function (item) {\n      var content = cssWithMappingToString(item, useSourceMap);\n\n      if (item[2]) {\n        return \"@media \".concat(item[2], \" {\").concat(content, \"}\");\n      }\n\n      return content;\n    }).join('');\n  }; // import a list of modules into the list\n  // eslint-disable-next-line func-names\n\n\n  list.i = function (modules, mediaQuery) {\n    if (typeof modules === 'string') {\n      // eslint-disable-next-line no-param-reassign\n      modules = [[null, modules, '']];\n    }\n\n    for (var i = 0; i < modules.length; i++) {\n      var item = [].concat(modules[i]);\n\n      if (mediaQuery) {\n        if (!item[2]) {\n          item[2] = mediaQuery;\n        } else {\n          item[2] = \"\".concat(mediaQuery, \" and \").concat(item[2]);\n        }\n      }\n\n      list.push(item);\n    }\n  };\n\n  return list;\n};\n\nfunction cssWithMappingToString(item, useSourceMap) {\n  var content = item[1] || ''; // eslint-disable-next-line prefer-destructuring\n\n  var cssMapping = item[3];\n\n  if (!cssMapping) {\n    return content;\n  }\n\n  if (useSourceMap && typeof btoa === 'function') {\n    var sourceMapping = toComment(cssMapping);\n    var sourceURLs = cssMapping.sources.map(function (source) {\n      return \"/*# sourceURL=\".concat(cssMapping.sourceRoot).concat(source, \" */\");\n    });\n    return [content].concat(sourceURLs).concat([sourceMapping]).join('\\n');\n  }\n\n  return [content].join('\\n');\n} // Adapted from convert-source-map (MIT)\n\n\nfunction toComment(sourceMap) {\n  // eslint-disable-next-line no-undef\n  var base64 = btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap))));\n  var data = \"sourceMappingURL=data:application/json;charset=utf-8;base64,\".concat(base64);\n  return \"/*# \".concat(data, \" */\");\n}","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nmodule.exports = root;\n","var baseIsNative = require('./_baseIsNative'),\n    getValue = require('./_getValue');\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n  var value = getValue(object, key);\n  return baseIsNative(value) ? value : undefined;\n}\n\nmodule.exports = getNative;\n","var g;\n\n// This works in non-strict mode\ng = (function() {\n\treturn this;\n})();\n\ntry {\n\t// This works if eval is allowed (see CSP)\n\tg = g || new Function(\"return this\")();\n} catch (e) {\n\t// This works if the window reference is available\n\tif (typeof window === \"object\") g = window;\n}\n\n// g can still be undefined, but nothing to do about it...\n// We return undefined, instead of nothing here, so it's\n// easier to handle this case. if(!global) { ...}\n\nmodule.exports = g;\n","var Symbol = require('./_Symbol'),\n    getRawTag = require('./_getRawTag'),\n    objectToString = require('./_objectToString');\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n    undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n  if (value == null) {\n    return value === undefined ? undefinedTag : nullTag;\n  }\n  return (symToStringTag && symToStringTag in Object(value))\n    ? getRawTag(value)\n    : objectToString(value);\n}\n\nmodule.exports = baseGetTag;\n","/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n  return value != null && typeof value == 'object';\n}\n\nmodule.exports = isObjectLike;\n","( function( factory ) {\n\tif ( typeof define === \"function\" && define.amd ) {\n\n\t\t// AMD. Register as an anonymous module.\n\t\tdefine( [ \"jquery\" ], factory );\n\t} else {\n\n\t\t// Browser globals\n\t\tfactory( jQuery );\n\t}\n} ( function( $ ) {\n\n$.ui = $.ui || {};\n\nreturn $.ui.version = \"1.12.1\";\n\n} ) );\n","var listCacheClear = require('./_listCacheClear'),\n    listCacheDelete = require('./_listCacheDelete'),\n    listCacheGet = require('./_listCacheGet'),\n    listCacheHas = require('./_listCacheHas'),\n    listCacheSet = require('./_listCacheSet');\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n  var index = -1,\n      length = entries == null ? 0 : entries.length;\n\n  this.clear();\n  while (++index < length) {\n    var entry = entries[index];\n    this.set(entry[0], entry[1]);\n  }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nmodule.exports = ListCache;\n","var eq = require('./eq');\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n  var length = array.length;\n  while (length--) {\n    if (eq(array[length][0], key)) {\n      return length;\n    }\n  }\n  return -1;\n}\n\nmodule.exports = assocIndexOf;\n","var getNative = require('./_getNative');\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nmodule.exports = nativeCreate;\n","var isKeyable = require('./_isKeyable');\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n  var data = map.__data__;\n  return isKeyable(key)\n    ? data[typeof key == 'string' ? 'string' : 'hash']\n    : data.map;\n}\n\nmodule.exports = getMapData;\n","\"use strict\";\n\nvar isOldIE = function isOldIE() {\n  var memo;\n  return function memorize() {\n    if (typeof memo === 'undefined') {\n      // Test for IE <= 9 as proposed by Browserhacks\n      // @see http://browserhacks.com/#hack-e71d8692f65334173fee715c222cb805\n      // Tests for existence of standard globals is to allow style-loader\n      // to operate correctly into non-standard environments\n      // @see https://github.com/webpack-contrib/style-loader/issues/177\n      memo = Boolean(window && document && document.all && !window.atob);\n    }\n\n    return memo;\n  };\n}();\n\nvar getTarget = function getTarget() {\n  var memo = {};\n  return function memorize(target) {\n    if (typeof memo[target] === 'undefined') {\n      var styleTarget = document.querySelector(target); // Special case to return head of iframe instead of iframe itself\n\n      if (window.HTMLIFrameElement && styleTarget instanceof window.HTMLIFrameElement) {\n        try {\n          // This will throw an exception if access to iframe is blocked\n          // due to cross-origin restrictions\n          styleTarget = styleTarget.contentDocument.head;\n        } catch (e) {\n          // istanbul ignore next\n          styleTarget = null;\n        }\n      }\n\n      memo[target] = styleTarget;\n    }\n\n    return memo[target];\n  };\n}();\n\nvar stylesInDom = {};\n\nfunction modulesToDom(moduleId, list, options) {\n  for (var i = 0; i < list.length; i++) {\n    var part = {\n      css: list[i][1],\n      media: list[i][2],\n      sourceMap: list[i][3]\n    };\n\n    if (stylesInDom[moduleId][i]) {\n      stylesInDom[moduleId][i](part);\n    } else {\n      stylesInDom[moduleId].push(addStyle(part, options));\n    }\n  }\n}\n\nfunction insertStyleElement(options) {\n  var style = document.createElement('style');\n  var attributes = options.attributes || {};\n\n  if (typeof attributes.nonce === 'undefined') {\n    var nonce = typeof __webpack_nonce__ !== 'undefined' ? __webpack_nonce__ : null;\n\n    if (nonce) {\n      attributes.nonce = nonce;\n    }\n  }\n\n  Object.keys(attributes).forEach(function (key) {\n    style.setAttribute(key, attributes[key]);\n  });\n\n  if (typeof options.insert === 'function') {\n    options.insert(style);\n  } else {\n    var target = getTarget(options.insert || 'head');\n\n    if (!target) {\n      throw new Error(\"Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.\");\n    }\n\n    target.appendChild(style);\n  }\n\n  return style;\n}\n\nfunction removeStyleElement(style) {\n  // istanbul ignore if\n  if (style.parentNode === null) {\n    return false;\n  }\n\n  style.parentNode.removeChild(style);\n}\n/* istanbul ignore next  */\n\n\nvar replaceText = function replaceText() {\n  var textStore = [];\n  return function replace(index, replacement) {\n    textStore[index] = replacement;\n    return textStore.filter(Boolean).join('\\n');\n  };\n}();\n\nfunction applyToSingletonTag(style, index, remove, obj) {\n  var css = remove ? '' : obj.css; // For old IE\n\n  /* istanbul ignore if  */\n\n  if (style.styleSheet) {\n    style.styleSheet.cssText = replaceText(index, css);\n  } else {\n    var cssNode = document.createTextNode(css);\n    var childNodes = style.childNodes;\n\n    if (childNodes[index]) {\n      style.removeChild(childNodes[index]);\n    }\n\n    if (childNodes.length) {\n      style.insertBefore(cssNode, childNodes[index]);\n    } else {\n      style.appendChild(cssNode);\n    }\n  }\n}\n\nfunction applyToTag(style, options, obj) {\n  var css = obj.css;\n  var media = obj.media;\n  var sourceMap = obj.sourceMap;\n\n  if (media) {\n    style.setAttribute('media', media);\n  } else {\n    style.removeAttribute('media');\n  }\n\n  if (sourceMap && btoa) {\n    css += \"\\n/*# sourceMappingURL=data:application/json;base64,\".concat(btoa(unescape(encodeURIComponent(JSON.stringify(sourceMap)))), \" */\");\n  } // For old IE\n\n  /* istanbul ignore if  */\n\n\n  if (style.styleSheet) {\n    style.styleSheet.cssText = css;\n  } else {\n    while (style.firstChild) {\n      style.removeChild(style.firstChild);\n    }\n\n    style.appendChild(document.createTextNode(css));\n  }\n}\n\nvar singleton = null;\nvar singletonCounter = 0;\n\nfunction addStyle(obj, options) {\n  var style;\n  var update;\n  var remove;\n\n  if (options.singleton) {\n    var styleIndex = singletonCounter++;\n    style = singleton || (singleton = insertStyleElement(options));\n    update = applyToSingletonTag.bind(null, style, styleIndex, false);\n    remove = applyToSingletonTag.bind(null, style, styleIndex, true);\n  } else {\n    style = insertStyleElement(options);\n    update = applyToTag.bind(null, style, options);\n\n    remove = function remove() {\n      removeStyleElement(style);\n    };\n  }\n\n  update(obj);\n  return function updateStyle(newObj) {\n    if (newObj) {\n      if (newObj.css === obj.css && newObj.media === obj.media && newObj.sourceMap === obj.sourceMap) {\n        return;\n      }\n\n      update(obj = newObj);\n    } else {\n      remove();\n    }\n  };\n}\n\nmodule.exports = function (moduleId, list, options) {\n  options = options || {}; // Force single-tag solution on IE6-9, which has a hard limit on the # of <style>\n  // tags it will allow on a page\n\n  if (!options.singleton && typeof options.singleton !== 'boolean') {\n    options.singleton = isOldIE();\n  }\n\n  moduleId = options.base ? moduleId + options.base : moduleId;\n  list = list || [];\n\n  if (!stylesInDom[moduleId]) {\n    stylesInDom[moduleId] = [];\n  }\n\n  modulesToDom(moduleId, list, options);\n  return function update(newList) {\n    newList = newList || [];\n\n    if (Object.prototype.toString.call(newList) !== '[object Array]') {\n      return;\n    }\n\n    if (!stylesInDom[moduleId]) {\n      stylesInDom[moduleId] = [];\n    }\n\n    modulesToDom(moduleId, newList, options);\n\n    for (var j = newList.length; j < stylesInDom[moduleId].length; j++) {\n      stylesInDom[moduleId][j]();\n    }\n\n    stylesInDom[moduleId].length = newList.length;\n\n    if (stylesInDom[moduleId].length === 0) {\n      delete stylesInDom[moduleId];\n    }\n  };\n};","//     Backbone.js 1.2.3\n\n//     (c) 2010-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n//     Backbone may be freely distributed under the MIT license.\n//     For all details and documentation:\n//     http://backbonejs.org\n\n(function(factory) {\n\n  // Establish the root object, `window` (`self`) in the browser, or `global` on the server.\n  // We use `self` instead of `window` for `WebWorker` support.\n  var root = (typeof self == 'object' && self.self == self && self) ||\n            (typeof global == 'object' && global.global == global && global);\n\n  // Set up Backbone appropriately for the environment. Start with AMD.\n  if (typeof define === 'function' && define.amd) {\n    define(['underscore', 'jquery', 'exports'], function(_, $, exports) {\n      // Export global even in AMD case in case this script is loaded with\n      // others that may still expect a global Backbone.\n      root.Backbone = factory(root, exports, _, $);\n    });\n\n  // Next for Node.js or CommonJS. jQuery may not be needed as a module.\n  } else if (typeof exports !== 'undefined') {\n    var _ = require('underscore'), $;\n    try { $ = require('jquery'); } catch(e) {}\n    factory(root, exports, _, $);\n\n  // Finally, as a browser global.\n  } else {\n    root.Backbone = factory(root, {}, root._, (root.jQuery || root.Zepto || root.ender || root.$));\n  }\n\n}(function(root, Backbone, _, $) {\n\n  // Initial Setup\n  // -------------\n\n  // Save the previous value of the `Backbone` variable, so that it can be\n  // restored later on, if `noConflict` is used.\n  var previousBackbone = root.Backbone;\n\n  // Create a local reference to a common array method we'll want to use later.\n  var slice = Array.prototype.slice;\n\n  // Current version of the library. Keep in sync with `package.json`.\n  Backbone.VERSION = '1.2.3';\n\n  // For Backbone's purposes, jQuery, Zepto, Ender, or My Library (kidding) owns\n  // the `$` variable.\n  Backbone.$ = $;\n\n  // Runs Backbone.js in *noConflict* mode, returning the `Backbone` variable\n  // to its previous owner. Returns a reference to this Backbone object.\n  Backbone.noConflict = function() {\n    root.Backbone = previousBackbone;\n    return this;\n  };\n\n  // Turn on `emulateHTTP` to support legacy HTTP servers. Setting this option\n  // will fake `\"PATCH\"`, `\"PUT\"` and `\"DELETE\"` requests via the `_method` parameter and\n  // set a `X-Http-Method-Override` header.\n  Backbone.emulateHTTP = false;\n\n  // Turn on `emulateJSON` to support legacy servers that can't deal with direct\n  // `application/json` requests ... this will encode the body as\n  // `application/x-www-form-urlencoded` instead and will send the model in a\n  // form param named `model`.\n  Backbone.emulateJSON = false;\n\n  // Proxy Backbone class methods to Underscore functions, wrapping the model's\n  // `attributes` object or collection's `models` array behind the scenes.\n  //\n  // collection.filter(function(model) { return model.get('age') > 10 });\n  // collection.each(this.addView);\n  //\n  // `Function#apply` can be slow so we use the method's arg count, if we know it.\n  var addMethod = function(length, method, attribute) {\n    switch (length) {\n      case 1: return function() {\n        return _[method](this[attribute]);\n      };\n      case 2: return function(value) {\n        return _[method](this[attribute], value);\n      };\n      case 3: return function(iteratee, context) {\n        return _[method](this[attribute], cb(iteratee, this), context);\n      };\n      case 4: return function(iteratee, defaultVal, context) {\n        return _[method](this[attribute], cb(iteratee, this), defaultVal, context);\n      };\n      default: return function() {\n        var args = slice.call(arguments);\n        args.unshift(this[attribute]);\n        return _[method].apply(_, args);\n      };\n    }\n  };\n  var addUnderscoreMethods = function(Class, methods, attribute) {\n    _.each(methods, function(length, method) {\n      if (_[method]) Class.prototype[method] = addMethod(length, method, attribute);\n    });\n  };\n\n  // Support `collection.sortBy('attr')` and `collection.findWhere({id: 1})`.\n  var cb = function(iteratee, instance) {\n    if (_.isFunction(iteratee)) return iteratee;\n    if (_.isObject(iteratee) && !instance._isModel(iteratee)) return modelMatcher(iteratee);\n    if (_.isString(iteratee)) return function(model) { return model.get(iteratee); };\n    return iteratee;\n  };\n  var modelMatcher = function(attrs) {\n    var matcher = _.matches(attrs);\n    return function(model) {\n      return matcher(model.attributes);\n    };\n  };\n\n  // Backbone.Events\n  // ---------------\n\n  // A module that can be mixed in to *any object* in order to provide it with\n  // a custom event channel. You may bind a callback to an event with `on` or\n  // remove with `off`; `trigger`-ing an event fires all callbacks in\n  // succession.\n  //\n  //     var object = {};\n  //     _.extend(object, Backbone.Events);\n  //     object.on('expand', function(){ alert('expanded'); });\n  //     object.trigger('expand');\n  //\n  var Events = Backbone.Events = {};\n\n  // Regular expression used to split event strings.\n  var eventSplitter = /\\s+/;\n\n  // Iterates over the standard `event, callback` (as well as the fancy multiple\n  // space-separated events `\"change blur\", callback` and jQuery-style event\n  // maps `{event: callback}`).\n  var eventsApi = function(iteratee, events, name, callback, opts) {\n    var i = 0, names;\n    if (name && typeof name === 'object') {\n      // Handle event maps.\n      if (callback !== void 0 && 'context' in opts && opts.context === void 0) opts.context = callback;\n      for (names = _.keys(name); i < names.length ; i++) {\n        events = eventsApi(iteratee, events, names[i], name[names[i]], opts);\n      }\n    } else if (name && eventSplitter.test(name)) {\n      // Handle space separated event names by delegating them individually.\n      for (names = name.split(eventSplitter); i < names.length; i++) {\n        events = iteratee(events, names[i], callback, opts);\n      }\n    } else {\n      // Finally, standard events.\n      events = iteratee(events, name, callback, opts);\n    }\n    return events;\n  };\n\n  // Bind an event to a `callback` function. Passing `\"all\"` will bind\n  // the callback to all events fired.\n  Events.on = function(name, callback, context) {\n    return internalOn(this, name, callback, context);\n  };\n\n  // Guard the `listening` argument from the public API.\n  var internalOn = function(obj, name, callback, context, listening) {\n    obj._events = eventsApi(onApi, obj._events || {}, name, callback, {\n        context: context,\n        ctx: obj,\n        listening: listening\n    });\n\n    if (listening) {\n      var listeners = obj._listeners || (obj._listeners = {});\n      listeners[listening.id] = listening;\n    }\n\n    return obj;\n  };\n\n  // Inversion-of-control versions of `on`. Tell *this* object to listen to\n  // an event in another object... keeping track of what it's listening to\n  // for easier unbinding later.\n  Events.listenTo =  function(obj, name, callback) {\n    if (!obj) return this;\n    var id = obj._listenId || (obj._listenId = _.uniqueId('l'));\n    var listeningTo = this._listeningTo || (this._listeningTo = {});\n    var listening = listeningTo[id];\n\n    // This object is not listening to any other events on `obj` yet.\n    // Setup the necessary references to track the listening callbacks.\n    if (!listening) {\n      var thisId = this._listenId || (this._listenId = _.uniqueId('l'));\n      listening = listeningTo[id] = {obj: obj, objId: id, id: thisId, listeningTo: listeningTo, count: 0};\n    }\n\n    // Bind callbacks on obj, and keep track of them on listening.\n    internalOn(obj, name, callback, this, listening);\n    return this;\n  };\n\n  // The reducing API that adds a callback to the `events` object.\n  var onApi = function(events, name, callback, options) {\n    if (callback) {\n      var handlers = events[name] || (events[name] = []);\n      var context = options.context, ctx = options.ctx, listening = options.listening;\n      if (listening) listening.count++;\n\n      handlers.push({ callback: callback, context: context, ctx: context || ctx, listening: listening });\n    }\n    return events;\n  };\n\n  // Remove one or many callbacks. If `context` is null, removes all\n  // callbacks with that function. If `callback` is null, removes all\n  // callbacks for the event. If `name` is null, removes all bound\n  // callbacks for all events.\n  Events.off =  function(name, callback, context) {\n    if (!this._events) return this;\n    this._events = eventsApi(offApi, this._events, name, callback, {\n        context: context,\n        listeners: this._listeners\n    });\n    return this;\n  };\n\n  // Tell this object to stop listening to either specific events ... or\n  // to every object it's currently listening to.\n  Events.stopListening =  function(obj, name, callback) {\n    var listeningTo = this._listeningTo;\n    if (!listeningTo) return this;\n\n    var ids = obj ? [obj._listenId] : _.keys(listeningTo);\n\n    for (var i = 0; i < ids.length; i++) {\n      var listening = listeningTo[ids[i]];\n\n      // If listening doesn't exist, this object is not currently\n      // listening to obj. Break out early.\n      if (!listening) break;\n\n      listening.obj.off(name, callback, this);\n    }\n    if (_.isEmpty(listeningTo)) this._listeningTo = void 0;\n\n    return this;\n  };\n\n  // The reducing API that removes a callback from the `events` object.\n  var offApi = function(events, name, callback, options) {\n    if (!events) return;\n\n    var i = 0, listening;\n    var context = options.context, listeners = options.listeners;\n\n    // Delete all events listeners and \"drop\" events.\n    if (!name && !callback && !context) {\n      var ids = _.keys(listeners);\n      for (; i < ids.length; i++) {\n        listening = listeners[ids[i]];\n        delete listeners[listening.id];\n        delete listening.listeningTo[listening.objId];\n      }\n      return;\n    }\n\n    var names = name ? [name] : _.keys(events);\n    for (; i < names.length; i++) {\n      name = names[i];\n      var handlers = events[name];\n\n      // Bail out if there are no events stored.\n      if (!handlers) break;\n\n      // Replace events if there are any remaining.  Otherwise, clean up.\n      var remaining = [];\n      for (var j = 0; j < handlers.length; j++) {\n        var handler = handlers[j];\n        if (\n          callback && callback !== handler.callback &&\n            callback !== handler.callback._callback ||\n              context && context !== handler.context\n        ) {\n          remaining.push(handler);\n        } else {\n          listening = handler.listening;\n          if (listening && --listening.count === 0) {\n            delete listeners[listening.id];\n            delete listening.listeningTo[listening.objId];\n          }\n        }\n      }\n\n      // Update tail event if the list has any events.  Otherwise, clean up.\n      if (remaining.length) {\n        events[name] = remaining;\n      } else {\n        delete events[name];\n      }\n    }\n    if (_.size(events)) return events;\n  };\n\n  // Bind an event to only be triggered a single time. After the first time\n  // the callback is invoked, its listener will be removed. If multiple events\n  // are passed in using the space-separated syntax, the handler will fire\n  // once for each event, not once for a combination of all events.\n  Events.once =  function(name, callback, context) {\n    // Map the event into a `{event: once}` object.\n    var events = eventsApi(onceMap, {}, name, callback, _.bind(this.off, this));\n    return this.on(events, void 0, context);\n  };\n\n  // Inversion-of-control versions of `once`.\n  Events.listenToOnce =  function(obj, name, callback) {\n    // Map the event into a `{event: once}` object.\n    var events = eventsApi(onceMap, {}, name, callback, _.bind(this.stopListening, this, obj));\n    return this.listenTo(obj, events);\n  };\n\n  // Reduces the event callbacks into a map of `{event: onceWrapper}`.\n  // `offer` unbinds the `onceWrapper` after it has been called.\n  var onceMap = function(map, name, callback, offer) {\n    if (callback) {\n      var once = map[name] = _.once(function() {\n        offer(name, once);\n        callback.apply(this, arguments);\n      });\n      once._callback = callback;\n    }\n    return map;\n  };\n\n  // Trigger one or many events, firing all bound callbacks. Callbacks are\n  // passed the same arguments as `trigger` is, apart from the event name\n  // (unless you're listening on `\"all\"`, which will cause your callback to\n  // receive the true name of the event as the first argument).\n  Events.trigger =  function(name) {\n    if (!this._events) return this;\n\n    var length = Math.max(0, arguments.length - 1);\n    var args = Array(length);\n    for (var i = 0; i < length; i++) args[i] = arguments[i + 1];\n\n    eventsApi(triggerApi, this._events, name, void 0, args);\n    return this;\n  };\n\n  // Handles triggering the appropriate event callbacks.\n  var triggerApi = function(objEvents, name, cb, args) {\n    if (objEvents) {\n      var events = objEvents[name];\n      var allEvents = objEvents.all;\n      if (events && allEvents) allEvents = allEvents.slice();\n      if (events) triggerEvents(events, args);\n      if (allEvents) triggerEvents(allEvents, [name].concat(args));\n    }\n    return objEvents;\n  };\n\n  // A difficult-to-believe, but optimized internal dispatch function for\n  // triggering events. Tries to keep the usual cases speedy (most internal\n  // Backbone events have 3 arguments).\n  var triggerEvents = function(events, args) {\n    var ev, i = -1, l = events.length, a1 = args[0], a2 = args[1], a3 = args[2];\n    switch (args.length) {\n      case 0: while (++i < l) (ev = events[i]).callback.call(ev.ctx); return;\n      case 1: while (++i < l) (ev = events[i]).callback.call(ev.ctx, a1); return;\n      case 2: while (++i < l) (ev = events[i]).callback.call(ev.ctx, a1, a2); return;\n      case 3: while (++i < l) (ev = events[i]).callback.call(ev.ctx, a1, a2, a3); return;\n      default: while (++i < l) (ev = events[i]).callback.apply(ev.ctx, args); return;\n    }\n  };\n\n  // Aliases for backwards compatibility.\n  Events.bind   = Events.on;\n  Events.unbind = Events.off;\n\n  // Allow the `Backbone` object to serve as a global event bus, for folks who\n  // want global \"pubsub\" in a convenient place.\n  _.extend(Backbone, Events);\n\n  // Backbone.Model\n  // --------------\n\n  // Backbone **Models** are the basic data object in the framework --\n  // frequently representing a row in a table in a database on your server.\n  // A discrete chunk of data and a bunch of useful, related methods for\n  // performing computations and transformations on that data.\n\n  // Create a new model with the specified attributes. A client id (`cid`)\n  // is automatically generated and assigned for you.\n  var Model = Backbone.Model = function(attributes, options) {\n    var attrs = attributes || {};\n    options || (options = {});\n    this.cid = _.uniqueId(this.cidPrefix);\n    this.attributes = {};\n    if (options.collection) this.collection = options.collection;\n    if (options.parse) attrs = this.parse(attrs, options) || {};\n    attrs = _.defaults({}, attrs, _.result(this, 'defaults'));\n    this.set(attrs, options);\n    this.changed = {};\n    this.initialize.apply(this, arguments);\n  };\n\n  // Attach all inheritable methods to the Model prototype.\n  _.extend(Model.prototype, Events, {\n\n    // A hash of attributes whose current and previous value differ.\n    changed: null,\n\n    // The value returned during the last failed validation.\n    validationError: null,\n\n    // The default name for the JSON `id` attribute is `\"id\"`. MongoDB and\n    // CouchDB users may want to set this to `\"_id\"`.\n    idAttribute: 'id',\n\n    // The prefix is used to create the client id which is used to identify models locally.\n    // You may want to override this if you're experiencing name clashes with model ids.\n    cidPrefix: 'c',\n\n    // Initialize is an empty function by default. Override it with your own\n    // initialization logic.\n    initialize: function(){},\n\n    // Return a copy of the model's `attributes` object.\n    toJSON: function(options) {\n      return _.clone(this.attributes);\n    },\n\n    // Proxy `Backbone.sync` by default -- but override this if you need\n    // custom syncing semantics for *this* particular model.\n    sync: function() {\n      return Backbone.sync.apply(this, arguments);\n    },\n\n    // Get the value of an attribute.\n    get: function(attr) {\n      return this.attributes[attr];\n    },\n\n    // Get the HTML-escaped value of an attribute.\n    escape: function(attr) {\n      return _.escape(this.get(attr));\n    },\n\n    // Returns `true` if the attribute contains a value that is not null\n    // or undefined.\n    has: function(attr) {\n      return this.get(attr) != null;\n    },\n\n    // Special-cased proxy to underscore's `_.matches` method.\n    matches: function(attrs) {\n      return !!_.iteratee(attrs, this)(this.attributes);\n    },\n\n    // Set a hash of model attributes on the object, firing `\"change\"`. This is\n    // the core primitive operation of a model, updating the data and notifying\n    // anyone who needs to know about the change in state. The heart of the beast.\n    set: function(key, val, options) {\n      if (key == null) return this;\n\n      // Handle both `\"key\", value` and `{key: value}` -style arguments.\n      var attrs;\n      if (typeof key === 'object') {\n        attrs = key;\n        options = val;\n      } else {\n        (attrs = {})[key] = val;\n      }\n\n      options || (options = {});\n\n      // Run validation.\n      if (!this._validate(attrs, options)) return false;\n\n      // Extract attributes and options.\n      var unset      = options.unset;\n      var silent     = options.silent;\n      var changes    = [];\n      var changing   = this._changing;\n      this._changing = true;\n\n      if (!changing) {\n        this._previousAttributes = _.clone(this.attributes);\n        this.changed = {};\n      }\n\n      var current = this.attributes;\n      var changed = this.changed;\n      var prev    = this._previousAttributes;\n\n      // For each `set` attribute, update or delete the current value.\n      for (var attr in attrs) {\n        val = attrs[attr];\n        if (!_.isEqual(current[attr], val)) changes.push(attr);\n        if (!_.isEqual(prev[attr], val)) {\n          changed[attr] = val;\n        } else {\n          delete changed[attr];\n        }\n        unset ? delete current[attr] : current[attr] = val;\n      }\n\n      // Update the `id`.\n      this.id = this.get(this.idAttribute);\n\n      // Trigger all relevant attribute changes.\n      if (!silent) {\n        if (changes.length) this._pending = options;\n        for (var i = 0; i < changes.length; i++) {\n          this.trigger('change:' + changes[i], this, current[changes[i]], options);\n        }\n      }\n\n      // You might be wondering why there's a `while` loop here. Changes can\n      // be recursively nested within `\"change\"` events.\n      if (changing) return this;\n      if (!silent) {\n        while (this._pending) {\n          options = this._pending;\n          this._pending = false;\n          this.trigger('change', this, options);\n        }\n      }\n      this._pending = false;\n      this._changing = false;\n      return this;\n    },\n\n    // Remove an attribute from the model, firing `\"change\"`. `unset` is a noop\n    // if the attribute doesn't exist.\n    unset: function(attr, options) {\n      return this.set(attr, void 0, _.extend({}, options, {unset: true}));\n    },\n\n    // Clear all attributes on the model, firing `\"change\"`.\n    clear: function(options) {\n      var attrs = {};\n      for (var key in this.attributes) attrs[key] = void 0;\n      return this.set(attrs, _.extend({}, options, {unset: true}));\n    },\n\n    // Determine if the model has changed since the last `\"change\"` event.\n    // If you specify an attribute name, determine if that attribute has changed.\n    hasChanged: function(attr) {\n      if (attr == null) return !_.isEmpty(this.changed);\n      return _.has(this.changed, attr);\n    },\n\n    // Return an object containing all the attributes that have changed, or\n    // false if there are no changed attributes. Useful for determining what\n    // parts of a view need to be updated and/or what attributes need to be\n    // persisted to the server. Unset attributes will be set to undefined.\n    // You can also pass an attributes object to diff against the model,\n    // determining if there *would be* a change.\n    changedAttributes: function(diff) {\n      if (!diff) return this.hasChanged() ? _.clone(this.changed) : false;\n      var old = this._changing ? this._previousAttributes : this.attributes;\n      var changed = {};\n      for (var attr in diff) {\n        var val = diff[attr];\n        if (_.isEqual(old[attr], val)) continue;\n        changed[attr] = val;\n      }\n      return _.size(changed) ? changed : false;\n    },\n\n    // Get the previous value of an attribute, recorded at the time the last\n    // `\"change\"` event was fired.\n    previous: function(attr) {\n      if (attr == null || !this._previousAttributes) return null;\n      return this._previousAttributes[attr];\n    },\n\n    // Get all of the attributes of the model at the time of the previous\n    // `\"change\"` event.\n    previousAttributes: function() {\n      return _.clone(this._previousAttributes);\n    },\n\n    // Fetch the model from the server, merging the response with the model's\n    // local attributes. Any changed attributes will trigger a \"change\" event.\n    fetch: function(options) {\n      options = _.extend({parse: true}, options);\n      var model = this;\n      var success = options.success;\n      options.success = function(resp) {\n        var serverAttrs = options.parse ? model.parse(resp, options) : resp;\n        if (!model.set(serverAttrs, options)) return false;\n        if (success) success.call(options.context, model, resp, options);\n        model.trigger('sync', model, resp, options);\n      };\n      wrapError(this, options);\n      return this.sync('read', this, options);\n    },\n\n    // Set a hash of model attributes, and sync the model to the server.\n    // If the server returns an attributes hash that differs, the model's\n    // state will be `set` again.\n    save: function(key, val, options) {\n      // Handle both `\"key\", value` and `{key: value}` -style arguments.\n      var attrs;\n      if (key == null || typeof key === 'object') {\n        attrs = key;\n        options = val;\n      } else {\n        (attrs = {})[key] = val;\n      }\n\n      options = _.extend({validate: true, parse: true}, options);\n      var wait = options.wait;\n\n      // If we're not waiting and attributes exist, save acts as\n      // `set(attr).save(null, opts)` with validation. Otherwise, check if\n      // the model will be valid when the attributes, if any, are set.\n      if (attrs && !wait) {\n        if (!this.set(attrs, options)) return false;\n      } else {\n        if (!this._validate(attrs, options)) return false;\n      }\n\n      // After a successful server-side save, the client is (optionally)\n      // updated with the server-side state.\n      var model = this;\n      var success = options.success;\n      var attributes = this.attributes;\n      options.success = function(resp) {\n        // Ensure attributes are restored during synchronous saves.\n        model.attributes = attributes;\n        var serverAttrs = options.parse ? model.parse(resp, options) : resp;\n        if (wait) serverAttrs = _.extend({}, attrs, serverAttrs);\n        if (serverAttrs && !model.set(serverAttrs, options)) return false;\n        if (success) success.call(options.context, model, resp, options);\n        model.trigger('sync', model, resp, options);\n      };\n      wrapError(this, options);\n\n      // Set temporary attributes if `{wait: true}` to properly find new ids.\n      if (attrs && wait) this.attributes = _.extend({}, attributes, attrs);\n\n      var method = this.isNew() ? 'create' : (options.patch ? 'patch' : 'update');\n      if (method === 'patch' && !options.attrs) options.attrs = attrs;\n      var xhr = this.sync(method, this, options);\n\n      // Restore attributes.\n      this.attributes = attributes;\n\n      return xhr;\n    },\n\n    // Destroy this model on the server if it was already persisted.\n    // Optimistically removes the model from its collection, if it has one.\n    // If `wait: true` is passed, waits for the server to respond before removal.\n    destroy: function(options) {\n      options = options ? _.clone(options) : {};\n      var model = this;\n      var success = options.success;\n      var wait = options.wait;\n\n      var destroy = function() {\n        model.stopListening();\n        model.trigger('destroy', model, model.collection, options);\n      };\n\n      options.success = function(resp) {\n        if (wait) destroy();\n        if (success) success.call(options.context, model, resp, options);\n        if (!model.isNew()) model.trigger('sync', model, resp, options);\n      };\n\n      var xhr = false;\n      if (this.isNew()) {\n        _.defer(options.success);\n      } else {\n        wrapError(this, options);\n        xhr = this.sync('delete', this, options);\n      }\n      if (!wait) destroy();\n      return xhr;\n    },\n\n    // Default URL for the model's representation on the server -- if you're\n    // using Backbone's restful methods, override this to change the endpoint\n    // that will be called.\n    url: function() {\n      var base =\n        _.result(this, 'urlRoot') ||\n        _.result(this.collection, 'url') ||\n        urlError();\n      if (this.isNew()) return base;\n      var id = this.get(this.idAttribute);\n      return base.replace(/[^\\/]$/, '$&/') + encodeURIComponent(id);\n    },\n\n    // **parse** converts a response into the hash of attributes to be `set` on\n    // the model. The default implementation is just to pass the response along.\n    parse: function(resp, options) {\n      return resp;\n    },\n\n    // Create a new model with identical attributes to this one.\n    clone: function() {\n      return new this.constructor(this.attributes);\n    },\n\n    // A model is new if it has never been saved to the server, and lacks an id.\n    isNew: function() {\n      return !this.has(this.idAttribute);\n    },\n\n    // Check if the model is currently in a valid state.\n    isValid: function(options) {\n      return this._validate({}, _.defaults({validate: true}, options));\n    },\n\n    // Run validation against the next complete set of model attributes,\n    // returning `true` if all is well. Otherwise, fire an `\"invalid\"` event.\n    _validate: function(attrs, options) {\n      if (!options.validate || !this.validate) return true;\n      attrs = _.extend({}, this.attributes, attrs);\n      var error = this.validationError = this.validate(attrs, options) || null;\n      if (!error) return true;\n      this.trigger('invalid', this, error, _.extend(options, {validationError: error}));\n      return false;\n    }\n\n  });\n\n  // Underscore methods that we want to implement on the Model, mapped to the\n  // number of arguments they take.\n  var modelMethods = { keys: 1, values: 1, pairs: 1, invert: 1, pick: 0,\n      omit: 0, chain: 1, isEmpty: 1 };\n\n  // Mix in each Underscore method as a proxy to `Model#attributes`.\n  addUnderscoreMethods(Model, modelMethods, 'attributes');\n\n  // Backbone.Collection\n  // -------------------\n\n  // If models tend to represent a single row of data, a Backbone Collection is\n  // more analogous to a table full of data ... or a small slice or page of that\n  // table, or a collection of rows that belong together for a particular reason\n  // -- all of the messages in this particular folder, all of the documents\n  // belonging to this particular author, and so on. Collections maintain\n  // indexes of their models, both in order, and for lookup by `id`.\n\n  // Create a new **Collection**, perhaps to contain a specific type of `model`.\n  // If a `comparator` is specified, the Collection will maintain\n  // its models in sort order, as they're added and removed.\n  var Collection = Backbone.Collection = function(models, options) {\n    options || (options = {});\n    if (options.model) this.model = options.model;\n    if (options.comparator !== void 0) this.comparator = options.comparator;\n    this._reset();\n    this.initialize.apply(this, arguments);\n    if (models) this.reset(models, _.extend({silent: true}, options));\n  };\n\n  // Default options for `Collection#set`.\n  var setOptions = {add: true, remove: true, merge: true};\n  var addOptions = {add: true, remove: false};\n\n  // Splices `insert` into `array` at index `at`.\n  var splice = function(array, insert, at) {\n    at = Math.min(Math.max(at, 0), array.length);\n    var tail = Array(array.length - at);\n    var length = insert.length;\n    for (var i = 0; i < tail.length; i++) tail[i] = array[i + at];\n    for (i = 0; i < length; i++) array[i + at] = insert[i];\n    for (i = 0; i < tail.length; i++) array[i + length + at] = tail[i];\n  };\n\n  // Define the Collection's inheritable methods.\n  _.extend(Collection.prototype, Events, {\n\n    // The default model for a collection is just a **Backbone.Model**.\n    // This should be overridden in most cases.\n    model: Model,\n\n    // Initialize is an empty function by default. Override it with your own\n    // initialization logic.\n    initialize: function(){},\n\n    // The JSON representation of a Collection is an array of the\n    // models' attributes.\n    toJSON: function(options) {\n      return this.map(function(model) { return model.toJSON(options); });\n    },\n\n    // Proxy `Backbone.sync` by default.\n    sync: function() {\n      return Backbone.sync.apply(this, arguments);\n    },\n\n    // Add a model, or list of models to the set. `models` may be Backbone\n    // Models or raw JavaScript objects to be converted to Models, or any\n    // combination of the two.\n    add: function(models, options) {\n      return this.set(models, _.extend({merge: false}, options, addOptions));\n    },\n\n    // Remove a model, or a list of models from the set.\n    remove: function(models, options) {\n      options = _.extend({}, options);\n      var singular = !_.isArray(models);\n      models = singular ? [models] : _.clone(models);\n      var removed = this._removeModels(models, options);\n      if (!options.silent && removed) this.trigger('update', this, options);\n      return singular ? removed[0] : removed;\n    },\n\n    // Update a collection by `set`-ing a new list of models, adding new ones,\n    // removing models that are no longer present, and merging models that\n    // already exist in the collection, as necessary. Similar to **Model#set**,\n    // the core operation for updating the data contained by the collection.\n    set: function(models, options) {\n      if (models == null) return;\n\n      options = _.defaults({}, options, setOptions);\n      if (options.parse && !this._isModel(models)) models = this.parse(models, options);\n\n      var singular = !_.isArray(models);\n      models = singular ? [models] : models.slice();\n\n      var at = options.at;\n      if (at != null) at = +at;\n      if (at < 0) at += this.length + 1;\n\n      var set = [];\n      var toAdd = [];\n      var toRemove = [];\n      var modelMap = {};\n\n      var add = options.add;\n      var merge = options.merge;\n      var remove = options.remove;\n\n      var sort = false;\n      var sortable = this.comparator && (at == null) && options.sort !== false;\n      var sortAttr = _.isString(this.comparator) ? this.comparator : null;\n\n      // Turn bare objects into model references, and prevent invalid models\n      // from being added.\n      var model;\n      for (var i = 0; i < models.length; i++) {\n        model = models[i];\n\n        // If a duplicate is found, prevent it from being added and\n        // optionally merge it into the existing model.\n        var existing = this.get(model);\n        if (existing) {\n          if (merge && model !== existing) {\n            var attrs = this._isModel(model) ? model.attributes : model;\n            if (options.parse) attrs = existing.parse(attrs, options);\n            existing.set(attrs, options);\n            if (sortable && !sort) sort = existing.hasChanged(sortAttr);\n          }\n          if (!modelMap[existing.cid]) {\n            modelMap[existing.cid] = true;\n            set.push(existing);\n          }\n          models[i] = existing;\n\n        // If this is a new, valid model, push it to the `toAdd` list.\n        } else if (add) {\n          model = models[i] = this._prepareModel(model, options);\n          if (model) {\n            toAdd.push(model);\n            this._addReference(model, options);\n            modelMap[model.cid] = true;\n            set.push(model);\n          }\n        }\n      }\n\n      // Remove stale models.\n      if (remove) {\n        for (i = 0; i < this.length; i++) {\n          model = this.models[i];\n          if (!modelMap[model.cid]) toRemove.push(model);\n        }\n        if (toRemove.length) this._removeModels(toRemove, options);\n      }\n\n      // See if sorting is needed, update `length` and splice in new models.\n      var orderChanged = false;\n      var replace = !sortable && add && remove;\n      if (set.length && replace) {\n        orderChanged = this.length != set.length || _.some(this.models, function(model, index) {\n          return model !== set[index];\n        });\n        this.models.length = 0;\n        splice(this.models, set, 0);\n        this.length = this.models.length;\n      } else if (toAdd.length) {\n        if (sortable) sort = true;\n        splice(this.models, toAdd, at == null ? this.length : at);\n        this.length = this.models.length;\n      }\n\n      // Silently sort the collection if appropriate.\n      if (sort) this.sort({silent: true});\n\n      // Unless silenced, it's time to fire all appropriate add/sort events.\n      if (!options.silent) {\n        for (i = 0; i < toAdd.length; i++) {\n          if (at != null) options.index = at + i;\n          model = toAdd[i];\n          model.trigger('add', model, this, options);\n        }\n        if (sort || orderChanged) this.trigger('sort', this, options);\n        if (toAdd.length || toRemove.length) this.trigger('update', this, options);\n      }\n\n      // Return the added (or merged) model (or models).\n      return singular ? models[0] : models;\n    },\n\n    // When you have more items than you want to add or remove individually,\n    // you can reset the entire set with a new list of models, without firing\n    // any granular `add` or `remove` events. Fires `reset` when finished.\n    // Useful for bulk operations and optimizations.\n    reset: function(models, options) {\n      options = options ? _.clone(options) : {};\n      for (var i = 0; i < this.models.length; i++) {\n        this._removeReference(this.models[i], options);\n      }\n      options.previousModels = this.models;\n      this._reset();\n      models = this.add(models, _.extend({silent: true}, options));\n      if (!options.silent) this.trigger('reset', this, options);\n      return models;\n    },\n\n    // Add a model to the end of the collection.\n    push: function(model, options) {\n      return this.add(model, _.extend({at: this.length}, options));\n    },\n\n    // Remove a model from the end of the collection.\n    pop: function(options) {\n      var model = this.at(this.length - 1);\n      return this.remove(model, options);\n    },\n\n    // Add a model to the beginning of the collection.\n    unshift: function(model, options) {\n      return this.add(model, _.extend({at: 0}, options));\n    },\n\n    // Remove a model from the beginning of the collection.\n    shift: function(options) {\n      var model = this.at(0);\n      return this.remove(model, options);\n    },\n\n    // Slice out a sub-array of models from the collection.\n    slice: function() {\n      return slice.apply(this.models, arguments);\n    },\n\n    // Get a model from the set by id.\n    get: function(obj) {\n      if (obj == null) return void 0;\n      var id = this.modelId(this._isModel(obj) ? obj.attributes : obj);\n      return this._byId[obj] || this._byId[id] || this._byId[obj.cid];\n    },\n\n    // Get the model at the given index.\n    at: function(index) {\n      if (index < 0) index += this.length;\n      return this.models[index];\n    },\n\n    // Return models with matching attributes. Useful for simple cases of\n    // `filter`.\n    where: function(attrs, first) {\n      return this[first ? 'find' : 'filter'](attrs);\n    },\n\n    // Return the first model with matching attributes. Useful for simple cases\n    // of `find`.\n    findWhere: function(attrs) {\n      return this.where(attrs, true);\n    },\n\n    // Force the collection to re-sort itself. You don't need to call this under\n    // normal circumstances, as the set will maintain sort order as each item\n    // is added.\n    sort: function(options) {\n      var comparator = this.comparator;\n      if (!comparator) throw new Error('Cannot sort a set without a comparator');\n      options || (options = {});\n\n      var length = comparator.length;\n      if (_.isFunction(comparator)) comparator = _.bind(comparator, this);\n\n      // Run sort based on type of `comparator`.\n      if (length === 1 || _.isString(comparator)) {\n        this.models = this.sortBy(comparator);\n      } else {\n        this.models.sort(comparator);\n      }\n      if (!options.silent) this.trigger('sort', this, options);\n      return this;\n    },\n\n    // Pluck an attribute from each model in the collection.\n    pluck: function(attr) {\n      return _.invoke(this.models, 'get', attr);\n    },\n\n    // Fetch the default set of models for this collection, resetting the\n    // collection when they arrive. If `reset: true` is passed, the response\n    // data will be passed through the `reset` method instead of `set`.\n    fetch: function(options) {\n      options = _.extend({parse: true}, options);\n      var success = options.success;\n      var collection = this;\n      options.success = function(resp) {\n        var method = options.reset ? 'reset' : 'set';\n        collection[method](resp, options);\n        if (success) success.call(options.context, collection, resp, options);\n        collection.trigger('sync', collection, resp, options);\n      };\n      wrapError(this, options);\n      return this.sync('read', this, options);\n    },\n\n    // Create a new instance of a model in this collection. Add the model to the\n    // collection immediately, unless `wait: true` is passed, in which case we\n    // wait for the server to agree.\n    create: function(model, options) {\n      options = options ? _.clone(options) : {};\n      var wait = options.wait;\n      model = this._prepareModel(model, options);\n      if (!model) return false;\n      if (!wait) this.add(model, options);\n      var collection = this;\n      var success = options.success;\n      options.success = function(model, resp, callbackOpts) {\n        if (wait) collection.add(model, callbackOpts);\n        if (success) success.call(callbackOpts.context, model, resp, callbackOpts);\n      };\n      model.save(null, options);\n      return model;\n    },\n\n    // **parse** converts a response into a list of models to be added to the\n    // collection. The default implementation is just to pass it through.\n    parse: function(resp, options) {\n      return resp;\n    },\n\n    // Create a new collection with an identical list of models as this one.\n    clone: function() {\n      return new this.constructor(this.models, {\n        model: this.model,\n        comparator: this.comparator\n      });\n    },\n\n    // Define how to uniquely identify models in the collection.\n    modelId: function (attrs) {\n      return attrs[this.model.prototype.idAttribute || 'id'];\n    },\n\n    // Private method to reset all internal state. Called when the collection\n    // is first initialized or reset.\n    _reset: function() {\n      this.length = 0;\n      this.models = [];\n      this._byId  = {};\n    },\n\n    // Prepare a hash of attributes (or other model) to be added to this\n    // collection.\n    _prepareModel: function(attrs, options) {\n      if (this._isModel(attrs)) {\n        if (!attrs.collection) attrs.collection = this;\n        return attrs;\n      }\n      options = options ? _.clone(options) : {};\n      options.collection = this;\n      var model = new this.model(attrs, options);\n      if (!model.validationError) return model;\n      this.trigger('invalid', this, model.validationError, options);\n      return false;\n    },\n\n    // Internal method called by both remove and set.\n    _removeModels: function(models, options) {\n      var removed = [];\n      for (var i = 0; i < models.length; i++) {\n        var model = this.get(models[i]);\n        if (!model) continue;\n\n        var index = this.indexOf(model);\n        this.models.splice(index, 1);\n        this.length--;\n\n        if (!options.silent) {\n          options.index = index;\n          model.trigger('remove', model, this, options);\n        }\n\n        removed.push(model);\n        this._removeReference(model, options);\n      }\n      return removed.length ? removed : false;\n    },\n\n    // Method for checking whether an object should be considered a model for\n    // the purposes of adding to the collection.\n    _isModel: function (model) {\n      return model instanceof Model;\n    },\n\n    // Internal method to create a model's ties to a collection.\n    _addReference: function(model, options) {\n      this._byId[model.cid] = model;\n      var id = this.modelId(model.attributes);\n      if (id != null) this._byId[id] = model;\n      model.on('all', this._onModelEvent, this);\n    },\n\n    // Internal method to sever a model's ties to a collection.\n    _removeReference: function(model, options) {\n      delete this._byId[model.cid];\n      var id = this.modelId(model.attributes);\n      if (id != null) delete this._byId[id];\n      if (this === model.collection) delete model.collection;\n      model.off('all', this._onModelEvent, this);\n    },\n\n    // Internal method called every time a model in the set fires an event.\n    // Sets need to update their indexes when models change ids. All other\n    // events simply proxy through. \"add\" and \"remove\" events that originate\n    // in other collections are ignored.\n    _onModelEvent: function(event, model, collection, options) {\n      if ((event === 'add' || event === 'remove') && collection !== this) return;\n      if (event === 'destroy') this.remove(model, options);\n      if (event === 'change') {\n        var prevId = this.modelId(model.previousAttributes());\n        var id = this.modelId(model.attributes);\n        if (prevId !== id) {\n          if (prevId != null) delete this._byId[prevId];\n          if (id != null) this._byId[id] = model;\n        }\n      }\n      this.trigger.apply(this, arguments);\n    }\n\n  });\n\n  // Underscore methods that we want to implement on the Collection.\n  // 90% of the core usefulness of Backbone Collections is actually implemented\n  // right here:\n  var collectionMethods = { forEach: 3, each: 3, map: 3, collect: 3, reduce: 4,\n      foldl: 4, inject: 4, reduceRight: 4, foldr: 4, find: 3, detect: 3, filter: 3,\n      select: 3, reject: 3, every: 3, all: 3, some: 3, any: 3, include: 3, includes: 3,\n      contains: 3, invoke: 0, max: 3, min: 3, toArray: 1, size: 1, first: 3,\n      head: 3, take: 3, initial: 3, rest: 3, tail: 3, drop: 3, last: 3,\n      without: 0, difference: 0, indexOf: 3, shuffle: 1, lastIndexOf: 3,\n      isEmpty: 1, chain: 1, sample: 3, partition: 3, groupBy: 3, countBy: 3,\n      sortBy: 3, indexBy: 3};\n\n  // Mix in each Underscore method as a proxy to `Collection#models`.\n  addUnderscoreMethods(Collection, collectionMethods, 'models');\n\n  // Backbone.View\n  // -------------\n\n  // Backbone Views are almost more convention than they are actual code. A View\n  // is simply a JavaScript object that represents a logical chunk of UI in the\n  // DOM. This might be a single item, an entire list, a sidebar or panel, or\n  // even the surrounding frame which wraps your whole app. Defining a chunk of\n  // UI as a **View** allows you to define your DOM events declaratively, without\n  // having to worry about render order ... and makes it easy for the view to\n  // react to specific changes in the state of your models.\n\n  // Creating a Backbone.View creates its initial element outside of the DOM,\n  // if an existing element is not provided...\n  var View = Backbone.View = function(options) {\n    this.cid = _.uniqueId('view');\n    _.extend(this, _.pick(options, viewOptions));\n    this._ensureElement();\n    this.initialize.apply(this, arguments);\n  };\n\n  // Cached regex to split keys for `delegate`.\n  var delegateEventSplitter = /^(\\S+)\\s*(.*)$/;\n\n  // List of view options to be set as properties.\n  var viewOptions = ['model', 'collection', 'el', 'id', 'attributes', 'className', 'tagName', 'events'];\n\n  // Set up all inheritable **Backbone.View** properties and methods.\n  _.extend(View.prototype, Events, {\n\n    // The default `tagName` of a View's element is `\"div\"`.\n    tagName: 'div',\n\n    // jQuery delegate for element lookup, scoped to DOM elements within the\n    // current view. This should be preferred to global lookups where possible.\n    $: function(selector) {\n      return this.$el.find(selector);\n    },\n\n    // Initialize is an empty function by default. Override it with your own\n    // initialization logic.\n    initialize: function(){},\n\n    // **render** is the core function that your view should override, in order\n    // to populate its element (`this.el`), with the appropriate HTML. The\n    // convention is for **render** to always return `this`.\n    render: function() {\n      return this;\n    },\n\n    // Remove this view by taking the element out of the DOM, and removing any\n    // applicable Backbone.Events listeners.\n    remove: function() {\n      this._removeElement();\n      this.stopListening();\n      return this;\n    },\n\n    // Remove this view's element from the document and all event listeners\n    // attached to it. Exposed for subclasses using an alternative DOM\n    // manipulation API.\n    _removeElement: function() {\n      this.$el.remove();\n    },\n\n    // Change the view's element (`this.el` property) and re-delegate the\n    // view's events on the new element.\n    setElement: function(element) {\n      this.undelegateEvents();\n      this._setElement(element);\n      this.delegateEvents();\n      return this;\n    },\n\n    // Creates the `this.el` and `this.$el` references for this view using the\n    // given `el`. `el` can be a CSS selector or an HTML string, a jQuery\n    // context or an element. Subclasses can override this to utilize an\n    // alternative DOM manipulation API and are only required to set the\n    // `this.el` property.\n    _setElement: function(el) {\n      this.$el = el instanceof Backbone.$ ? el : Backbone.$(el);\n      this.el = this.$el[0];\n    },\n\n    // Set callbacks, where `this.events` is a hash of\n    //\n    // *{\"event selector\": \"callback\"}*\n    //\n    //     {\n    //       'mousedown .title':  'edit',\n    //       'click .button':     'save',\n    //       'click .open':       function(e) { ... }\n    //     }\n    //\n    // pairs. Callbacks will be bound to the view, with `this` set properly.\n    // Uses event delegation for efficiency.\n    // Omitting the selector binds the event to `this.el`.\n    delegateEvents: function(events) {\n      events || (events = _.result(this, 'events'));\n      if (!events) return this;\n      this.undelegateEvents();\n      for (var key in events) {\n        var method = events[key];\n        if (!_.isFunction(method)) method = this[method];\n        if (!method) continue;\n        var match = key.match(delegateEventSplitter);\n        this.delegate(match[1], match[2], _.bind(method, this));\n      }\n      return this;\n    },\n\n    // Add a single event listener to the view's element (or a child element\n    // using `selector`). This only works for delegate-able events: not `focus`,\n    // `blur`, and not `change`, `submit`, and `reset` in Internet Explorer.\n    delegate: function(eventName, selector, listener) {\n      this.$el.on(eventName + '.delegateEvents' + this.cid, selector, listener);\n      return this;\n    },\n\n    // Clears all callbacks previously bound to the view by `delegateEvents`.\n    // You usually don't need to use this, but may wish to if you have multiple\n    // Backbone views attached to the same DOM element.\n    undelegateEvents: function() {\n      if (this.$el) this.$el.off('.delegateEvents' + this.cid);\n      return this;\n    },\n\n    // A finer-grained `undelegateEvents` for removing a single delegated event.\n    // `selector` and `listener` are both optional.\n    undelegate: function(eventName, selector, listener) {\n      this.$el.off(eventName + '.delegateEvents' + this.cid, selector, listener);\n      return this;\n    },\n\n    // Produces a DOM element to be assigned to your view. Exposed for\n    // subclasses using an alternative DOM manipulation API.\n    _createElement: function(tagName) {\n      return document.createElement(tagName);\n    },\n\n    // Ensure that the View has a DOM element to render into.\n    // If `this.el` is a string, pass it through `$()`, take the first\n    // matching element, and re-assign it to `el`. Otherwise, create\n    // an element from the `id`, `className` and `tagName` properties.\n    _ensureElement: function() {\n      if (!this.el) {\n        var attrs = _.extend({}, _.result(this, 'attributes'));\n        if (this.id) attrs.id = _.result(this, 'id');\n        if (this.className) attrs['class'] = _.result(this, 'className');\n        this.setElement(this._createElement(_.result(this, 'tagName')));\n        this._setAttributes(attrs);\n      } else {\n        this.setElement(_.result(this, 'el'));\n      }\n    },\n\n    // Set attributes from a hash on this view's element.  Exposed for\n    // subclasses using an alternative DOM manipulation API.\n    _setAttributes: function(attributes) {\n      this.$el.attr(attributes);\n    }\n\n  });\n\n  // Backbone.sync\n  // -------------\n\n  // Override this function to change the manner in which Backbone persists\n  // models to the server. You will be passed the type of request, and the\n  // model in question. By default, makes a RESTful Ajax request\n  // to the model's `url()`. Some possible customizations could be:\n  //\n  // * Use `setTimeout` to batch rapid-fire updates into a single request.\n  // * Send up the models as XML instead of JSON.\n  // * Persist models via WebSockets instead of Ajax.\n  //\n  // Turn on `Backbone.emulateHTTP` in order to send `PUT` and `DELETE` requests\n  // as `POST`, with a `_method` parameter containing the true HTTP method,\n  // as well as all requests with the body as `application/x-www-form-urlencoded`\n  // instead of `application/json` with the model in a param named `model`.\n  // Useful when interfacing with server-side languages like **PHP** that make\n  // it difficult to read the body of `PUT` requests.\n  Backbone.sync = function(method, model, options) {\n    var type = methodMap[method];\n\n    // Default options, unless specified.\n    _.defaults(options || (options = {}), {\n      emulateHTTP: Backbone.emulateHTTP,\n      emulateJSON: Backbone.emulateJSON\n    });\n\n    // Default JSON-request options.\n    var params = {type: type, dataType: 'json'};\n\n    // Ensure that we have a URL.\n    if (!options.url) {\n      params.url = _.result(model, 'url') || urlError();\n    }\n\n    // Ensure that we have the appropriate request data.\n    if (options.data == null && model && (method === 'create' || method === 'update' || method === 'patch')) {\n      params.contentType = 'application/json';\n      params.data = JSON.stringify(options.attrs || model.toJSON(options));\n    }\n\n    // For older servers, emulate JSON by encoding the request into an HTML-form.\n    if (options.emulateJSON) {\n      params.contentType = 'application/x-www-form-urlencoded';\n      params.data = params.data ? {model: params.data} : {};\n    }\n\n    // For older servers, emulate HTTP by mimicking the HTTP method with `_method`\n    // And an `X-HTTP-Method-Override` header.\n    if (options.emulateHTTP && (type === 'PUT' || type === 'DELETE' || type === 'PATCH')) {\n      params.type = 'POST';\n      if (options.emulateJSON) params.data._method = type;\n      var beforeSend = options.beforeSend;\n      options.beforeSend = function(xhr) {\n        xhr.setRequestHeader('X-HTTP-Method-Override', type);\n        if (beforeSend) return beforeSend.apply(this, arguments);\n      };\n    }\n\n    // Don't process data on a non-GET request.\n    if (params.type !== 'GET' && !options.emulateJSON) {\n      params.processData = false;\n    }\n\n    // Pass along `textStatus` and `errorThrown` from jQuery.\n    var error = options.error;\n    options.error = function(xhr, textStatus, errorThrown) {\n      options.textStatus = textStatus;\n      options.errorThrown = errorThrown;\n      if (error) error.call(options.context, xhr, textStatus, errorThrown);\n    };\n\n    // Make the request, allowing the user to override any Ajax options.\n    var xhr = options.xhr = Backbone.ajax(_.extend(params, options));\n    model.trigger('request', model, xhr, options);\n    return xhr;\n  };\n\n  // Map from CRUD to HTTP for our default `Backbone.sync` implementation.\n  var methodMap = {\n    'create': 'POST',\n    'update': 'PUT',\n    'patch':  'PATCH',\n    'delete': 'DELETE',\n    'read':   'GET'\n  };\n\n  // Set the default implementation of `Backbone.ajax` to proxy through to `$`.\n  // Override this if you'd like to use a different library.\n  Backbone.ajax = function() {\n    return Backbone.$.ajax.apply(Backbone.$, arguments);\n  };\n\n  // Backbone.Router\n  // ---------------\n\n  // Routers map faux-URLs to actions, and fire events when routes are\n  // matched. Creating a new one sets its `routes` hash, if not set statically.\n  var Router = Backbone.Router = function(options) {\n    options || (options = {});\n    if (options.routes) this.routes = options.routes;\n    this._bindRoutes();\n    this.initialize.apply(this, arguments);\n  };\n\n  // Cached regular expressions for matching named param parts and splatted\n  // parts of route strings.\n  var optionalParam = /\\((.*?)\\)/g;\n  var namedParam    = /(\\(\\?)?:\\w+/g;\n  var splatParam    = /\\*\\w+/g;\n  var escapeRegExp  = /[\\-{}\\[\\]+?.,\\\\\\^$|#\\s]/g;\n\n  // Set up all inheritable **Backbone.Router** properties and methods.\n  _.extend(Router.prototype, Events, {\n\n    // Initialize is an empty function by default. Override it with your own\n    // initialization logic.\n    initialize: function(){},\n\n    // Manually bind a single named route to a callback. For example:\n    //\n    //     this.route('search/:query/p:num', 'search', function(query, num) {\n    //       ...\n    //     });\n    //\n    route: function(route, name, callback) {\n      if (!_.isRegExp(route)) route = this._routeToRegExp(route);\n      if (_.isFunction(name)) {\n        callback = name;\n        name = '';\n      }\n      if (!callback) callback = this[name];\n      var router = this;\n      Backbone.history.route(route, function(fragment) {\n        var args = router._extractParameters(route, fragment);\n        if (router.execute(callback, args, name) !== false) {\n          router.trigger.apply(router, ['route:' + name].concat(args));\n          router.trigger('route', name, args);\n          Backbone.history.trigger('route', router, name, args);\n        }\n      });\n      return this;\n    },\n\n    // Execute a route handler with the provided parameters.  This is an\n    // excellent place to do pre-route setup or post-route cleanup.\n    execute: function(callback, args, name) {\n      if (callback) callback.apply(this, args);\n    },\n\n    // Simple proxy to `Backbone.history` to save a fragment into the history.\n    navigate: function(fragment, options) {\n      Backbone.history.navigate(fragment, options);\n      return this;\n    },\n\n    // Bind all defined routes to `Backbone.history`. We have to reverse the\n    // order of the routes here to support behavior where the most general\n    // routes can be defined at the bottom of the route map.\n    _bindRoutes: function() {\n      if (!this.routes) return;\n      this.routes = _.result(this, 'routes');\n      var route, routes = _.keys(this.routes);\n      while ((route = routes.pop()) != null) {\n        this.route(route, this.routes[route]);\n      }\n    },\n\n    // Convert a route string into a regular expression, suitable for matching\n    // against the current location hash.\n    _routeToRegExp: function(route) {\n      route = route.replace(escapeRegExp, '\\\\$&')\n                   .replace(optionalParam, '(?:$1)?')\n                   .replace(namedParam, function(match, optional) {\n                     return optional ? match : '([^/?]+)';\n                   })\n                   .replace(splatParam, '([^?]*?)');\n      return new RegExp('^' + route + '(?:\\\\?([\\\\s\\\\S]*))?$');\n    },\n\n    // Given a route, and a URL fragment that it matches, return the array of\n    // extracted decoded parameters. Empty or unmatched parameters will be\n    // treated as `null` to normalize cross-browser behavior.\n    _extractParameters: function(route, fragment) {\n      var params = route.exec(fragment).slice(1);\n      return _.map(params, function(param, i) {\n        // Don't decode the search params.\n        if (i === params.length - 1) return param || null;\n        return param ? decodeURIComponent(param) : null;\n      });\n    }\n\n  });\n\n  // Backbone.History\n  // ----------------\n\n  // Handles cross-browser history management, based on either\n  // [pushState](http://diveintohtml5.info/history.html) and real URLs, or\n  // [onhashchange](https://developer.mozilla.org/en-US/docs/DOM/window.onhashchange)\n  // and URL fragments. If the browser supports neither (old IE, natch),\n  // falls back to polling.\n  var History = Backbone.History = function() {\n    this.handlers = [];\n    this.checkUrl = _.bind(this.checkUrl, this);\n\n    // Ensure that `History` can be used outside of the browser.\n    if (typeof window !== 'undefined') {\n      this.location = window.location;\n      this.history = window.history;\n    }\n  };\n\n  // Cached regex for stripping a leading hash/slash and trailing space.\n  var routeStripper = /^[#\\/]|\\s+$/g;\n\n  // Cached regex for stripping leading and trailing slashes.\n  var rootStripper = /^\\/+|\\/+$/g;\n\n  // Cached regex for stripping urls of hash.\n  var pathStripper = /#.*$/;\n\n  // Has the history handling already been started?\n  History.started = false;\n\n  // Set up all inheritable **Backbone.History** properties and methods.\n  _.extend(History.prototype, Events, {\n\n    // The default interval to poll for hash changes, if necessary, is\n    // twenty times a second.\n    interval: 50,\n\n    // Are we at the app root?\n    atRoot: function() {\n      var path = this.location.pathname.replace(/[^\\/]$/, '$&/');\n      return path === this.root && !this.getSearch();\n    },\n\n    // Does the pathname match the root?\n    matchRoot: function() {\n      var path = this.decodeFragment(this.location.pathname);\n      var root = path.slice(0, this.root.length - 1) + '/';\n      return root === this.root;\n    },\n\n    // Unicode characters in `location.pathname` are percent encoded so they're\n    // decoded for comparison. `%25` should not be decoded since it may be part\n    // of an encoded parameter.\n    decodeFragment: function(fragment) {\n      return decodeURI(fragment.replace(/%25/g, '%2525'));\n    },\n\n    // In IE6, the hash fragment and search params are incorrect if the\n    // fragment contains `?`.\n    getSearch: function() {\n      var match = this.location.href.replace(/#.*/, '').match(/\\?.+/);\n      return match ? match[0] : '';\n    },\n\n    // Gets the true hash value. Cannot use location.hash directly due to bug\n    // in Firefox where location.hash will always be decoded.\n    getHash: function(window) {\n      var match = (window || this).location.href.match(/#(.*)$/);\n      return match ? match[1] : '';\n    },\n\n    // Get the pathname and search params, without the root.\n    getPath: function() {\n      var path = this.decodeFragment(\n        this.location.pathname + this.getSearch()\n      ).slice(this.root.length - 1);\n      return path.charAt(0) === '/' ? path.slice(1) : path;\n    },\n\n    // Get the cross-browser normalized URL fragment from the path or hash.\n    getFragment: function(fragment) {\n      if (fragment == null) {\n        if (this._usePushState || !this._wantsHashChange) {\n          fragment = this.getPath();\n        } else {\n          fragment = this.getHash();\n        }\n      }\n      return fragment.replace(routeStripper, '');\n    },\n\n    // Start the hash change handling, returning `true` if the current URL matches\n    // an existing route, and `false` otherwise.\n    start: function(options) {\n      if (History.started) throw new Error('Backbone.history has already been started');\n      History.started = true;\n\n      // Figure out the initial configuration. Do we need an iframe?\n      // Is pushState desired ... is it available?\n      this.options          = _.extend({root: '/'}, this.options, options);\n      this.root             = this.options.root;\n      this._wantsHashChange = this.options.hashChange !== false;\n      this._hasHashChange   = 'onhashchange' in window && (document.documentMode === void 0 || document.documentMode > 7);\n      this._useHashChange   = this._wantsHashChange && this._hasHashChange;\n      this._wantsPushState  = !!this.options.pushState;\n      this._hasPushState    = !!(this.history && this.history.pushState);\n      this._usePushState    = this._wantsPushState && this._hasPushState;\n      this.fragment         = this.getFragment();\n\n      // Normalize root to always include a leading and trailing slash.\n      this.root = ('/' + this.root + '/').replace(rootStripper, '/');\n\n      // Transition from hashChange to pushState or vice versa if both are\n      // requested.\n      if (this._wantsHashChange && this._wantsPushState) {\n\n        // If we've started off with a route from a `pushState`-enabled\n        // browser, but we're currently in a browser that doesn't support it...\n        if (!this._hasPushState && !this.atRoot()) {\n          var root = this.root.slice(0, -1) || '/';\n          this.location.replace(root + '#' + this.getPath());\n          // Return immediately as browser will do redirect to new url\n          return true;\n\n        // Or if we've started out with a hash-based route, but we're currently\n        // in a browser where it could be `pushState`-based instead...\n        } else if (this._hasPushState && this.atRoot()) {\n          this.navigate(this.getHash(), {replace: true});\n        }\n\n      }\n\n      // Proxy an iframe to handle location events if the browser doesn't\n      // support the `hashchange` event, HTML5 history, or the user wants\n      // `hashChange` but not `pushState`.\n      if (!this._hasHashChange && this._wantsHashChange && !this._usePushState) {\n        this.iframe = document.createElement('iframe');\n        this.iframe.src = 'javascript:0';\n        this.iframe.style.display = 'none';\n        this.iframe.tabIndex = -1;\n        var body = document.body;\n        // Using `appendChild` will throw on IE < 9 if the document is not ready.\n        var iWindow = body.insertBefore(this.iframe, body.firstChild).contentWindow;\n        iWindow.document.open();\n        iWindow.document.close();\n        iWindow.location.hash = '#' + this.fragment;\n      }\n\n      // Add a cross-platform `addEventListener` shim for older browsers.\n      var addEventListener = window.addEventListener || function (eventName, listener) {\n        return attachEvent('on' + eventName, listener);\n      };\n\n      // Depending on whether we're using pushState or hashes, and whether\n      // 'onhashchange' is supported, determine how we check the URL state.\n      if (this._usePushState) {\n        addEventListener('popstate', this.checkUrl, false);\n      } else if (this._useHashChange && !this.iframe) {\n        addEventListener('hashchange', this.checkUrl, false);\n      } else if (this._wantsHashChange) {\n        this._checkUrlInterval = setInterval(this.checkUrl, this.interval);\n      }\n\n      if (!this.options.silent) return this.loadUrl();\n    },\n\n    // Disable Backbone.history, perhaps temporarily. Not useful in a real app,\n    // but possibly useful for unit testing Routers.\n    stop: function() {\n      // Add a cross-platform `removeEventListener` shim for older browsers.\n      var removeEventListener = window.removeEventListener || function (eventName, listener) {\n        return detachEvent('on' + eventName, listener);\n      };\n\n      // Remove window listeners.\n      if (this._usePushState) {\n        removeEventListener('popstate', this.checkUrl, false);\n      } else if (this._useHashChange && !this.iframe) {\n        removeEventListener('hashchange', this.checkUrl, false);\n      }\n\n      // Clean up the iframe if necessary.\n      if (this.iframe) {\n        document.body.removeChild(this.iframe);\n        this.iframe = null;\n      }\n\n      // Some environments will throw when clearing an undefined interval.\n      if (this._checkUrlInterval) clearInterval(this._checkUrlInterval);\n      History.started = false;\n    },\n\n    // Add a route to be tested when the fragment changes. Routes added later\n    // may override previous routes.\n    route: function(route, callback) {\n      this.handlers.unshift({route: route, callback: callback});\n    },\n\n    // Checks the current URL to see if it has changed, and if it has,\n    // calls `loadUrl`, normalizing across the hidden iframe.\n    checkUrl: function(e) {\n      var current = this.getFragment();\n\n      // If the user pressed the back button, the iframe's hash will have\n      // changed and we should use that for comparison.\n      if (current === this.fragment && this.iframe) {\n        current = this.getHash(this.iframe.contentWindow);\n      }\n\n      if (current === this.fragment) return false;\n      if (this.iframe) this.navigate(current);\n      this.loadUrl();\n    },\n\n    // Attempt to load the current URL fragment. If a route succeeds with a\n    // match, returns `true`. If no defined routes matches the fragment,\n    // returns `false`.\n    loadUrl: function(fragment) {\n      // If the root doesn't match, no routes can match either.\n      if (!this.matchRoot()) return false;\n      fragment = this.fragment = this.getFragment(fragment);\n      return _.some(this.handlers, function(handler) {\n        if (handler.route.test(fragment)) {\n          handler.callback(fragment);\n          return true;\n        }\n      });\n    },\n\n    // Save a fragment into the hash history, or replace the URL state if the\n    // 'replace' option is passed. You are responsible for properly URL-encoding\n    // the fragment in advance.\n    //\n    // The options object can contain `trigger: true` if you wish to have the\n    // route callback be fired (not usually desirable), or `replace: true`, if\n    // you wish to modify the current URL without adding an entry to the history.\n    navigate: function(fragment, options) {\n      if (!History.started) return false;\n      if (!options || options === true) options = {trigger: !!options};\n\n      // Normalize the fragment.\n      fragment = this.getFragment(fragment || '');\n\n      // Don't include a trailing slash on the root.\n      var root = this.root;\n      if (fragment === '' || fragment.charAt(0) === '?') {\n        root = root.slice(0, -1) || '/';\n      }\n      var url = root + fragment;\n\n      // Strip the hash and decode for matching.\n      fragment = this.decodeFragment(fragment.replace(pathStripper, ''));\n\n      if (this.fragment === fragment) return;\n      this.fragment = fragment;\n\n      // If pushState is available, we use it to set the fragment as a real URL.\n      if (this._usePushState) {\n        this.history[options.replace ? 'replaceState' : 'pushState']({}, document.title, url);\n\n      // If hash changes haven't been explicitly disabled, update the hash\n      // fragment to store history.\n      } else if (this._wantsHashChange) {\n        this._updateHash(this.location, fragment, options.replace);\n        if (this.iframe && (fragment !== this.getHash(this.iframe.contentWindow))) {\n          var iWindow = this.iframe.contentWindow;\n\n          // Opening and closing the iframe tricks IE7 and earlier to push a\n          // history entry on hash-tag change.  When replace is true, we don't\n          // want this.\n          if (!options.replace) {\n            iWindow.document.open();\n            iWindow.document.close();\n          }\n\n          this._updateHash(iWindow.location, fragment, options.replace);\n        }\n\n      // If you've told us that you explicitly don't want fallback hashchange-\n      // based history, then `navigate` becomes a page refresh.\n      } else {\n        return this.location.assign(url);\n      }\n      if (options.trigger) return this.loadUrl(fragment);\n    },\n\n    // Update the hash location, either replacing the current entry, or adding\n    // a new one to the browser history.\n    _updateHash: function(location, fragment, replace) {\n      if (replace) {\n        var href = location.href.replace(/(javascript:|#).*$/, '');\n        location.replace(href + '#' + fragment);\n      } else {\n        // Some browsers require that `hash` contains a leading #.\n        location.hash = '#' + fragment;\n      }\n    }\n\n  });\n\n  // Create the default Backbone.history.\n  Backbone.history = new History;\n\n  // Helpers\n  // -------\n\n  // Helper function to correctly set up the prototype chain for subclasses.\n  // Similar to `goog.inherits`, but uses a hash of prototype properties and\n  // class properties to be extended.\n  var extend = function(protoProps, staticProps) {\n    var parent = this;\n    var child;\n\n    // The constructor function for the new subclass is either defined by you\n    // (the \"constructor\" property in your `extend` definition), or defaulted\n    // by us to simply call the parent constructor.\n    if (protoProps && _.has(protoProps, 'constructor')) {\n      child = protoProps.constructor;\n    } else {\n      child = function(){ return parent.apply(this, arguments); };\n    }\n\n    // Add static properties to the constructor function, if supplied.\n    _.extend(child, parent, staticProps);\n\n    // Set the prototype chain to inherit from `parent`, without calling\n    // `parent` constructor function.\n    var Surrogate = function(){ this.constructor = child; };\n    Surrogate.prototype = parent.prototype;\n    child.prototype = new Surrogate;\n\n    // Add prototype properties (instance properties) to the subclass,\n    // if supplied.\n    if (protoProps) _.extend(child.prototype, protoProps);\n\n    // Set a convenience property in case the parent's prototype is needed\n    // later.\n    child.__super__ = parent.prototype;\n\n    return child;\n  };\n\n  // Set up inheritance for the model, collection, router, view and history.\n  Model.extend = Collection.extend = Router.extend = View.extend = History.extend = extend;\n\n  // Throw an error when a URL is needed, and none is supplied.\n  var urlError = function() {\n    throw new Error('A \"url\" property or function must be specified');\n  };\n\n  // Wrap an optional error callback with a fallback error event.\n  var wrapError = function(model, options) {\n    var error = options.error;\n    options.error = function(resp) {\n      if (error) error.call(options.context, model, resp, options);\n      model.trigger('error', model, resp, options);\n    };\n  };\n\n  return Backbone;\n\n}));\n","module.exports = function(module) {\n\tif (!module.webpackPolyfill) {\n\t\tmodule.deprecate = function() {};\n\t\tmodule.paths = [];\n\t\t// module.parent = undefined by default\n\t\tif (!module.children) module.children = [];\n\t\tObject.defineProperty(module, \"loaded\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.l;\n\t\t\t}\n\t\t});\n\t\tObject.defineProperty(module, \"id\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.i;\n\t\t\t}\n\t\t});\n\t\tmodule.webpackPolyfill = 1;\n\t}\n\treturn module;\n};\n","var getNative = require('./_getNative'),\n    root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nmodule.exports = Map;\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nmodule.exports = Symbol;\n","/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nmodule.exports = isArray;\n","var scope = (typeof global !== \"undefined\" && global) ||\n            (typeof self !== \"undefined\" && self) ||\n            window;\nvar apply = Function.prototype.apply;\n\n// DOM APIs, for completeness\n\nexports.setTimeout = function() {\n  return new Timeout(apply.call(setTimeout, scope, arguments), clearTimeout);\n};\nexports.setInterval = function() {\n  return new Timeout(apply.call(setInterval, scope, arguments), clearInterval);\n};\nexports.clearTimeout =\nexports.clearInterval = function(timeout) {\n  if (timeout) {\n    timeout.close();\n  }\n};\n\nfunction Timeout(id, clearFn) {\n  this._id = id;\n  this._clearFn = clearFn;\n}\nTimeout.prototype.unref = Timeout.prototype.ref = function() {};\nTimeout.prototype.close = function() {\n  this._clearFn.call(scope, this._id);\n};\n\n// Does not start the time, just sets up the members needed.\nexports.enroll = function(item, msecs) {\n  clearTimeout(item._idleTimeoutId);\n  item._idleTimeout = msecs;\n};\n\nexports.unenroll = function(item) {\n  clearTimeout(item._idleTimeoutId);\n  item._idleTimeout = -1;\n};\n\nexports._unrefActive = exports.active = function(item) {\n  clearTimeout(item._idleTimeoutId);\n\n  var msecs = item._idleTimeout;\n  if (msecs >= 0) {\n    item._idleTimeoutId = setTimeout(function onTimeout() {\n      if (item._onTimeout)\n        item._onTimeout();\n    }, msecs);\n  }\n};\n\n// setimmediate attaches itself to the global object\nrequire(\"setimmediate\");\n// On some exotic environments, it's not clear which object `setimmediate` was\n// able to install onto.  Search each possibility in the same order as the\n// `setimmediate` library.\nexports.setImmediate = (typeof self !== \"undefined\" && self.setImmediate) ||\n                       (typeof global !== \"undefined\" && global.setImmediate) ||\n                       (this && this.setImmediate);\nexports.clearImmediate = (typeof self !== \"undefined\" && self.clearImmediate) ||\n                         (typeof global !== \"undefined\" && global.clearImmediate) ||\n                         (this && this.clearImmediate);\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nexport { uuid, WrappedError, resolvePromisesDict } from '@jupyter-widgets/base';\nimport { WrappedError } from '@jupyter-widgets/base';\n/**\n * Creates a wrappable Promise rejection function.\n *\n * Creates a function that returns a Promise.reject with a new WrappedError\n * that has the provided message and wraps the original error that\n * caused the promise to reject.\n */\nexport function reject(message, log) {\n    return function promiseRejection(error) {\n        var wrapped_error = new WrappedError(message, error);\n        if (log) {\n            console.error(wrapped_error);\n        }\n        return Promise.reject(wrapped_error);\n    };\n}\n/**\n * Apply MathJax rendering to an element, and optionally set its text.\n *\n * If MathJax is not available, make no changes.\n *\n * Parameters\n * ----------\n * element: Node\n * text: optional string\n */\nexport function typeset(element, text) {\n    if (text !== void 0) {\n        element.textContent = text;\n    }\n    if (window.MathJax !== void 0) {\n        MathJax.Hub.Queue(['Typeset', MathJax.Hub, element]);\n    }\n}\n/**\n * escape text to HTML\n */\nexport function escape_html(text) {\n    var esc = document.createElement('div');\n    esc.textContent = text;\n    return esc.innerHTML;\n}\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/**\n * The version of the Jupyter controls widget attribute spec that this package\n * implements.\n */\nexport var JUPYTER_CONTROLS_VERSION = '1.5.0';\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { DOMWidgetModel, DOMWidgetView, StyleModel } from '@jupyter-widgets/base';\nimport { typeset } from './utils';\nimport { JUPYTER_CONTROLS_VERSION } from './version';\nvar DescriptionStyleModel = /** @class */ (function (_super) {\n    __extends(DescriptionStyleModel, _super);\n    function DescriptionStyleModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    DescriptionStyleModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'DescriptionStyleModel', _model_module: '@jupyter-widgets/controls', _model_module_version: JUPYTER_CONTROLS_VERSION });\n    };\n    DescriptionStyleModel.styleProperties = {\n        description_width: {\n            selector: '.widget-label',\n            attribute: 'width',\n            default: null\n        },\n    };\n    return DescriptionStyleModel;\n}(StyleModel));\nexport { DescriptionStyleModel };\nvar DescriptionModel = /** @class */ (function (_super) {\n    __extends(DescriptionModel, _super);\n    function DescriptionModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    DescriptionModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'DescriptionModel', _view_name: 'DescriptionView', _view_module: '@jupyter-widgets/controls', _model_module: '@jupyter-widgets/controls', _view_module_version: JUPYTER_CONTROLS_VERSION, _model_module_version: JUPYTER_CONTROLS_VERSION, description: '', description_tooltip: null });\n    };\n    return DescriptionModel;\n}(DOMWidgetModel));\nexport { DescriptionModel };\nvar DescriptionView = /** @class */ (function (_super) {\n    __extends(DescriptionView, _super);\n    function DescriptionView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    DescriptionView.prototype.render = function () {\n        this.label = document.createElement('label');\n        this.el.appendChild(this.label);\n        this.label.className = 'widget-label';\n        this.label.style.display = 'none';\n        this.listenTo(this.model, 'change:description', this.updateDescription);\n        this.listenTo(this.model, 'change:description_tooltip', this.updateDescription);\n        this.updateDescription();\n    };\n    DescriptionView.prototype.typeset = function (element, text) {\n        this.displayed.then(function () { return typeset(element, text); });\n    };\n    DescriptionView.prototype.updateDescription = function () {\n        var description = this.model.get('description');\n        var description_tooltip = this.model.get('description_tooltip');\n        if (description_tooltip === null) {\n            description_tooltip = description;\n        }\n        if (description.length === 0) {\n            this.label.style.display = 'none';\n        }\n        else {\n            this.label.innerHTML = description;\n            this.typeset(this.label);\n            this.label.style.display = '';\n        }\n        this.label.title = description_tooltip;\n    };\n    return DescriptionView;\n}(DOMWidgetView));\nexport { DescriptionView };\n/**\n * For backwards compatibility with jupyter-js-widgets 2.x.\n *\n * Use DescriptionModel instead.\n */\nvar LabeledDOMWidgetModel = /** @class */ (function (_super) {\n    __extends(LabeledDOMWidgetModel, _super);\n    function LabeledDOMWidgetModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    return LabeledDOMWidgetModel;\n}(DescriptionModel));\nexport { LabeledDOMWidgetModel };\n/**\n * For backwards compatibility with jupyter-js-widgets 2.x.\n *\n * Use DescriptionView instead.\n */\nvar LabeledDOMWidgetView = /** @class */ (function (_super) {\n    __extends(LabeledDOMWidgetView, _super);\n    function LabeledDOMWidgetView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    return LabeledDOMWidgetView;\n}(DescriptionView));\nexport { LabeledDOMWidgetView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\n// widget_core implements some common patterns for the core widget collection\n// that are not to be used directly by third-party widget authors.\nimport { DOMWidgetModel, WidgetModel } from '@jupyter-widgets/base';\nimport { DescriptionModel } from './widget_description';\nimport { JUPYTER_CONTROLS_VERSION } from './version';\nimport * as _ from 'underscore';\nvar CoreWidgetModel = /** @class */ (function (_super) {\n    __extends(CoreWidgetModel, _super);\n    function CoreWidgetModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    CoreWidgetModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'CoreWidgetModel',\n            _view_module: '@jupyter-widgets/controls',\n            _model_module: '@jupyter-widgets/controls',\n            _view_module_version: JUPYTER_CONTROLS_VERSION,\n            _model_module_version: JUPYTER_CONTROLS_VERSION,\n        });\n    };\n    return CoreWidgetModel;\n}(WidgetModel));\nexport { CoreWidgetModel };\nvar CoreDOMWidgetModel = /** @class */ (function (_super) {\n    __extends(CoreDOMWidgetModel, _super);\n    function CoreDOMWidgetModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    CoreDOMWidgetModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'CoreDOMWidgetModel',\n            _view_module: '@jupyter-widgets/controls',\n            _model_module: '@jupyter-widgets/controls',\n            _view_module_version: JUPYTER_CONTROLS_VERSION,\n            _model_module_version: JUPYTER_CONTROLS_VERSION,\n        });\n    };\n    return CoreDOMWidgetModel;\n}(DOMWidgetModel));\nexport { CoreDOMWidgetModel };\nvar CoreDescriptionModel = /** @class */ (function (_super) {\n    __extends(CoreDescriptionModel, _super);\n    function CoreDescriptionModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    CoreDescriptionModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'CoreDescriptionModel',\n            _view_module: '@jupyter-widgets/controls',\n            _model_module: '@jupyter-widgets/controls',\n            _view_module_version: JUPYTER_CONTROLS_VERSION,\n            _model_module_version: JUPYTER_CONTROLS_VERSION,\n        });\n    };\n    return CoreDescriptionModel;\n}(DescriptionModel));\nexport { CoreDescriptionModel };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { unpack_models } from '@jupyter-widgets/base';\nimport { CoreWidgetModel } from './widget_core';\nimport * as _ from 'underscore';\nvar DirectionalLinkModel = /** @class */ (function (_super) {\n    __extends(DirectionalLinkModel, _super);\n    function DirectionalLinkModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    DirectionalLinkModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            target: undefined,\n            source: undefined,\n            _model_name: 'DirectionalLinkModel'\n        });\n    };\n    DirectionalLinkModel.prototype.initialize = function (attributes, options) {\n        _super.prototype.initialize.call(this, attributes, options);\n        this.on('change', this.updateBindings, this);\n        this.updateBindings();\n    };\n    DirectionalLinkModel.prototype.updateValue = function (sourceModel, sourceAttr, targetModel, targetAttr) {\n        if (this._updating) {\n            return;\n        }\n        this._updating = true;\n        try {\n            if (targetModel) {\n                targetModel.set(targetAttr, sourceModel.get(sourceAttr));\n                targetModel.save_changes();\n            }\n        }\n        finally {\n            this._updating = false;\n        }\n    };\n    DirectionalLinkModel.prototype.updateBindings = function () {\n        var _a, _b;\n        var _this = this;\n        this.cleanup();\n        _a = this.get('source') || [null, null], this.sourceModel = _a[0], this.sourceAttr = _a[1];\n        _b = this.get('target') || [null, null], this.targetModel = _b[0], this.targetAttr = _b[1];\n        if (this.sourceModel) {\n            this.listenTo(this.sourceModel, 'change:' + this.sourceAttr, function () {\n                _this.updateValue(_this.sourceModel, _this.sourceAttr, _this.targetModel, _this.targetAttr);\n            });\n            this.updateValue(this.sourceModel, this.sourceAttr, this.targetModel, this.targetAttr);\n            this.listenToOnce(this.sourceModel, 'destroy', this.cleanup);\n        }\n        if (this.targetModel) {\n            this.listenToOnce(this.targetModel, 'destroy', this.cleanup);\n        }\n    };\n    DirectionalLinkModel.prototype.cleanup = function () {\n        // Stop listening to 'change' and 'destroy' events of the source and target\n        if (this.sourceModel) {\n            this.stopListening(this.sourceModel, 'change:' + this.sourceAttr, null);\n            this.stopListening(this.sourceModel, 'destroy', null);\n        }\n        if (this.targetModel) {\n            this.stopListening(this.targetModel, 'destroy', null);\n        }\n    };\n    DirectionalLinkModel.serializers = __assign(__assign({}, CoreWidgetModel.serializers), { target: { deserialize: unpack_models }, source: { deserialize: unpack_models } });\n    return DirectionalLinkModel;\n}(CoreWidgetModel));\nexport { DirectionalLinkModel };\nvar LinkModel = /** @class */ (function (_super) {\n    __extends(LinkModel, _super);\n    function LinkModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    LinkModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'LinkModel'\n        });\n    };\n    LinkModel.prototype.updateBindings = function () {\n        var _this = this;\n        _super.prototype.updateBindings.call(this);\n        if (this.targetModel) {\n            this.listenTo(this.targetModel, 'change:' + this.targetAttr, function () {\n                _this.updateValue(_this.targetModel, _this.targetAttr, _this.sourceModel, _this.sourceAttr);\n            });\n        }\n    };\n    LinkModel.prototype.cleanup = function () {\n        _super.prototype.cleanup.call(this);\n        if (this.targetModel) {\n            this.stopListening(this.targetModel, 'change:' + this.targetAttr, null);\n        }\n    };\n    return LinkModel;\n}(DirectionalLinkModel));\nexport { LinkModel };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nimport { CoreDescriptionModel } from './widget_core';\nimport { DescriptionView } from './widget_description';\nimport { DOMWidgetView } from '@jupyter-widgets/base';\nimport * as _ from 'underscore';\nvar BoolModel = /** @class */ (function (_super) {\n    __extends(BoolModel, _super);\n    function BoolModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    BoolModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            value: false,\n            disabled: false,\n            _model_name: 'BoolModel'\n        });\n    };\n    return BoolModel;\n}(CoreDescriptionModel));\nexport { BoolModel };\nvar CheckboxModel = /** @class */ (function (_super) {\n    __extends(CheckboxModel, _super);\n    function CheckboxModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    CheckboxModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            indent: true,\n            _view_name: 'CheckboxView',\n            _model_name: 'CheckboxModel'\n        });\n    };\n    return CheckboxModel;\n}(CoreDescriptionModel));\nexport { CheckboxModel };\nvar CheckboxView = /** @class */ (function (_super) {\n    __extends(CheckboxView, _super);\n    function CheckboxView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    CheckboxView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-checkbox');\n        // adding a zero-width space to the label to help\n        // the browser set the baseline correctly\n        this.label.innerHTML = '&#8203;';\n        // label containing the checkbox and description span\n        this.checkboxLabel = document.createElement('label');\n        this.checkboxLabel.classList.add('widget-label-basic');\n        this.el.appendChild(this.checkboxLabel);\n        // checkbox\n        this.checkbox = document.createElement('input');\n        this.checkbox.setAttribute('type', 'checkbox');\n        this.checkboxLabel.appendChild(this.checkbox);\n        // span to the right of the checkbox that will render the description\n        this.descriptionSpan = document.createElement('span');\n        this.checkboxLabel.appendChild(this.descriptionSpan);\n        this.listenTo(this.model, 'change:indent', this.updateIndent);\n        this.update(); // Set defaults.\n        this.updateDescription();\n        this.updateIndent();\n    };\n    /**\n     * Overriden from super class\n     *\n     * Update the description span (rather than the label) since\n     * we want the description to the right of the checkbox.\n     */\n    CheckboxView.prototype.updateDescription = function () {\n        // can be called before the view is fully initialized\n        if (this.checkboxLabel == null) {\n            return;\n        }\n        var description = this.model.get('description');\n        this.descriptionSpan.innerHTML = description;\n        this.typeset(this.descriptionSpan);\n        this.descriptionSpan.title = description;\n        this.checkbox.title = description;\n    };\n    /**\n     * Update the visibility of the label in the super class\n     * to provide the optional indent.\n     */\n    CheckboxView.prototype.updateIndent = function () {\n        var indent = this.model.get('indent');\n        this.label.style.display = indent ? '' : 'none';\n    };\n    CheckboxView.prototype.events = function () {\n        return {\n            'click input[type=\"checkbox\"]': '_handle_click'\n        };\n    };\n    /**\n     * Handles when the checkbox is clicked.\n     *\n     * Calling model.set will trigger all of the other views of the\n     * model to update.\n     */\n    CheckboxView.prototype._handle_click = function () {\n        var value = this.model.get('value');\n        this.model.set('value', !value, { updated_view: this });\n        this.touch();\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed. The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    CheckboxView.prototype.update = function (options) {\n        this.checkbox.checked = this.model.get('value');\n        if (options === undefined || options.updated_view != this) {\n            this.checkbox.disabled = this.model.get('disabled');\n        }\n        return _super.prototype.update.call(this);\n    };\n    return CheckboxView;\n}(DescriptionView));\nexport { CheckboxView };\nvar ToggleButtonModel = /** @class */ (function (_super) {\n    __extends(ToggleButtonModel, _super);\n    function ToggleButtonModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ToggleButtonModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _view_name: 'ToggleButtonView',\n            _model_name: 'ToggleButtonModel',\n            tooltip: '',\n            icon: '',\n            button_style: ''\n        });\n    };\n    return ToggleButtonModel;\n}(BoolModel));\nexport { ToggleButtonModel };\nvar ToggleButtonView = /** @class */ (function (_super) {\n    __extends(ToggleButtonView, _super);\n    function ToggleButtonView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    ToggleButtonView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('jupyter-button');\n        this.el.classList.add('widget-toggle-button');\n        this.listenTo(this.model, 'change:button_style', this.update_button_style);\n        this.set_button_style();\n        this.update(); // Set defaults.\n    };\n    ToggleButtonView.prototype.update_button_style = function () {\n        this.update_mapped_classes(ToggleButtonView.class_map, 'button_style');\n    };\n    ToggleButtonView.prototype.set_button_style = function () {\n        this.set_mapped_classes(ToggleButtonView.class_map, 'button_style');\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed. The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    ToggleButtonView.prototype.update = function (options) {\n        if (this.model.get('value')) {\n            this.el.classList.add('mod-active');\n        }\n        else {\n            this.el.classList.remove('mod-active');\n        }\n        if (options === undefined || options.updated_view !== this) {\n            this.el.disabled = this.model.get('disabled');\n            this.el.setAttribute('title', this.model.get('tooltip'));\n            var description = this.model.get('description');\n            var icon = this.model.get('icon');\n            if (description.trim().length === 0 && icon.trim().length === 0) {\n                this.el.innerHTML = '&nbsp;'; // Preserve button height\n            }\n            else {\n                this.el.textContent = '';\n                if (icon.trim().length) {\n                    var i = document.createElement('i');\n                    this.el.appendChild(i);\n                    i.classList.add('fa');\n                    i.classList.add('fa-' + icon);\n                }\n                this.el.appendChild(document.createTextNode(description));\n            }\n        }\n        return _super.prototype.update.call(this);\n    };\n    ToggleButtonView.prototype.events = function () {\n        return {\n            // Dictionary of events and their handlers.\n            'click': '_handle_click'\n        };\n    };\n    /**\n     * Handles and validates user input.\n     *\n     * Calling model.set will trigger all of the other views of the\n     * model to update.\n     */\n    ToggleButtonView.prototype._handle_click = function (event) {\n        event.preventDefault();\n        var value = this.model.get('value');\n        this.model.set('value', !value, { updated_view: this });\n        this.touch();\n    };\n    Object.defineProperty(ToggleButtonView.prototype, \"tagName\", {\n        /**\n         * The default tag name.\n         *\n         * #### Notes\n         * This is a read-only attribute.\n         */\n        get: function () {\n            // We can't make this an attribute with a default value\n            // since it would be set after it is needed in the\n            // constructor.\n            return 'button';\n        },\n        enumerable: true,\n        configurable: true\n    });\n    ToggleButtonView.class_map = {\n        primary: ['mod-primary'],\n        success: ['mod-success'],\n        info: ['mod-info'],\n        warning: ['mod-warning'],\n        danger: ['mod-danger']\n    };\n    return ToggleButtonView;\n}(DOMWidgetView));\nexport { ToggleButtonView };\nvar ValidModel = /** @class */ (function (_super) {\n    __extends(ValidModel, _super);\n    function ValidModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ValidModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            readout: 'Invalid',\n            _view_name: 'ValidView',\n            _model_name: 'ValidModel'\n        });\n    };\n    return ValidModel;\n}(BoolModel));\nexport { ValidModel };\nvar ValidView = /** @class */ (function (_super) {\n    __extends(ValidView, _super);\n    function ValidView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    ValidView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-valid');\n        this.el.classList.add('widget-inline-hbox');\n        this.icon = document.createElement('i');\n        this.icon.classList.add('fa', 'fa-fw');\n        this.el.appendChild(this.icon);\n        this.readout = document.createElement('span');\n        this.readout.classList.add('widget-valid-readout');\n        this.readout.classList.add('widget-readout');\n        this.el.appendChild(this.readout);\n        this.update();\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed.  The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    ValidView.prototype.update = function () {\n        this.el.classList.remove('mod-valid');\n        this.el.classList.remove('mod-invalid');\n        this.icon.classList.remove('fa-check');\n        this.icon.classList.remove('fa-times');\n        this.readout.textContent = this.model.get('readout');\n        if (this.model.get('value')) {\n            this.el.classList.add('mod-valid');\n            this.icon.classList.add('fa-check');\n        }\n        else {\n            this.el.classList.add('mod-invalid');\n            this.icon.classList.add('fa-times');\n        }\n    };\n    return ValidView;\n}(DescriptionView));\nexport { ValidView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nimport { DOMWidgetView, StyleModel } from '@jupyter-widgets/base';\nimport { CoreDOMWidgetModel } from './widget_core';\nimport { JUPYTER_CONTROLS_VERSION } from './version';\nimport * as _ from 'underscore';\nvar ButtonStyleModel = /** @class */ (function (_super) {\n    __extends(ButtonStyleModel, _super);\n    function ButtonStyleModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ButtonStyleModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'ButtonStyleModel',\n            _model_module: '@jupyter-widgets/controls',\n            _model_module_version: JUPYTER_CONTROLS_VERSION,\n        });\n    };\n    ButtonStyleModel.styleProperties = {\n        button_color: {\n            selector: '',\n            attribute: 'background-color',\n            default: null\n        },\n        font_weight: {\n            selector: '',\n            attribute: 'font-weight',\n            default: ''\n        }\n    };\n    return ButtonStyleModel;\n}(StyleModel));\nexport { ButtonStyleModel };\nvar ButtonModel = /** @class */ (function (_super) {\n    __extends(ButtonModel, _super);\n    function ButtonModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ButtonModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            description: '',\n            tooltip: '',\n            disabled: false,\n            icon: '',\n            button_style: '',\n            _view_name: 'ButtonView',\n            _model_name: 'ButtonModel',\n            style: null\n        });\n    };\n    return ButtonModel;\n}(CoreDOMWidgetModel));\nexport { ButtonModel };\nvar ButtonView = /** @class */ (function (_super) {\n    __extends(ButtonView, _super);\n    function ButtonView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    ButtonView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('jupyter-button');\n        this.el.classList.add('widget-button');\n        this.listenTo(this.model, 'change:button_style', this.update_button_style);\n        this.set_button_style();\n        this.update(); // Set defaults.\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed. The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    ButtonView.prototype.update = function () {\n        this.el.disabled = this.model.get('disabled');\n        this.el.setAttribute('title', this.model.get('tooltip'));\n        var description = this.model.get('description');\n        var icon = this.model.get('icon');\n        if (description.length || icon.length) {\n            this.el.textContent = '';\n            if (icon.length) {\n                var i = document.createElement('i');\n                i.classList.add('fa');\n                i.classList.add('fa-' + icon);\n                if (description.length === 0) {\n                    i.classList.add('center');\n                }\n                this.el.appendChild(i);\n            }\n            this.el.appendChild(document.createTextNode(description));\n        }\n        return _super.prototype.update.call(this);\n    };\n    ButtonView.prototype.update_button_style = function () {\n        this.update_mapped_classes(ButtonView.class_map, 'button_style');\n    };\n    ButtonView.prototype.set_button_style = function () {\n        this.set_mapped_classes(ButtonView.class_map, 'button_style');\n    };\n    /**\n     * Dictionary of events and handlers\n     */\n    ButtonView.prototype.events = function () {\n        // TODO: return typing not needed in Typescript later than 1.8.x\n        // See http://stackoverflow.com/questions/22077023/why-cant-i-indirectly-return-an-object-literal-to-satisfy-an-index-signature-re and https://github.com/Microsoft/TypeScript/pull/7029\n        return { 'click': '_handle_click' };\n    };\n    /**\n     * Handles when the button is clicked.\n     */\n    ButtonView.prototype._handle_click = function (event) {\n        event.preventDefault();\n        this.send({ event: 'click' });\n    };\n    Object.defineProperty(ButtonView.prototype, \"tagName\", {\n        /**\n         * The default tag name.\n         *\n         * #### Notes\n         * This is a read-only attribute.\n         */\n        get: function () {\n            // We can't make this an attribute with a default value\n            // since it would be set after it is needed in the\n            // constructor.\n            return 'button';\n        },\n        enumerable: true,\n        configurable: true\n    });\n    ButtonView.class_map = {\n        primary: ['mod-primary'],\n        success: ['mod-success'],\n        info: ['mod-info'],\n        warning: ['mod-warning'],\n        danger: ['mod-danger']\n    };\n    return ButtonView;\n}(DOMWidgetView));\nexport { ButtonView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { DOMWidgetView, unpack_models, ViewList, JupyterPhosphorPanelWidget } from '@jupyter-widgets/base';\nimport { CoreDOMWidgetModel } from './widget_core';\nimport { reject } from './utils';\nimport { ArrayExt } from '@lumino/algorithm';\nimport { MessageLoop } from '@lumino/messaging';\nimport { Widget } from '@lumino/widgets';\nimport * as _ from 'underscore';\nimport $ from 'jquery';\nvar BoxModel = /** @class */ (function (_super) {\n    __extends(BoxModel, _super);\n    function BoxModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    BoxModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _view_name: 'BoxView',\n            _model_name: 'BoxModel',\n            children: [],\n            box_style: ''\n        });\n    };\n    BoxModel.serializers = __assign(__assign({}, CoreDOMWidgetModel.serializers), { children: { deserialize: unpack_models } });\n    return BoxModel;\n}(CoreDOMWidgetModel));\nexport { BoxModel };\nvar HBoxModel = /** @class */ (function (_super) {\n    __extends(HBoxModel, _super);\n    function HBoxModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    HBoxModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _view_name: 'HBoxView',\n            _model_name: 'HBoxModel',\n        });\n    };\n    return HBoxModel;\n}(BoxModel));\nexport { HBoxModel };\nvar VBoxModel = /** @class */ (function (_super) {\n    __extends(VBoxModel, _super);\n    function VBoxModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    VBoxModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _view_name: 'VBoxView',\n            _model_name: 'VBoxModel',\n        });\n    };\n    return VBoxModel;\n}(BoxModel));\nexport { VBoxModel };\nvar BoxView = /** @class */ (function (_super) {\n    __extends(BoxView, _super);\n    function BoxView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    BoxView.prototype._createElement = function (tagName) {\n        this.pWidget = new JupyterPhosphorPanelWidget({ view: this });\n        return this.pWidget.node;\n    };\n    BoxView.prototype._setElement = function (el) {\n        if (this.el || el !== this.pWidget.node) {\n            // Boxes don't allow setting the element beyond the initial creation.\n            throw new Error('Cannot reset the DOM element.');\n        }\n        this.el = this.pWidget.node;\n        this.$el = $(this.pWidget.node);\n    };\n    BoxView.prototype.initialize = function (parameters) {\n        _super.prototype.initialize.call(this, parameters);\n        this.children_views = new ViewList(this.add_child_model, null, this);\n        this.listenTo(this.model, 'change:children', this.update_children);\n        this.listenTo(this.model, 'change:box_style', this.update_box_style);\n        this.pWidget.addClass('jupyter-widgets');\n        this.pWidget.addClass('widget-container');\n        this.pWidget.addClass('widget-box');\n    };\n    BoxView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.update_children();\n        this.set_box_style();\n    };\n    BoxView.prototype.update_children = function () {\n        this.children_views.update(this.model.get('children')).then(function (views) {\n            // Notify all children that their sizes may have changed.\n            views.forEach(function (view) {\n                MessageLoop.postMessage(view.pWidget, Widget.ResizeMessage.UnknownSize);\n            });\n        });\n    };\n    BoxView.prototype.update_box_style = function () {\n        this.update_mapped_classes(BoxView.class_map, 'box_style');\n    };\n    BoxView.prototype.set_box_style = function () {\n        this.set_mapped_classes(BoxView.class_map, 'box_style');\n    };\n    BoxView.prototype.add_child_model = function (model) {\n        var _this = this;\n        // we insert a dummy element so the order is preserved when we add\n        // the rendered content later.\n        var dummy = new Widget();\n        this.pWidget.addWidget(dummy);\n        return this.create_child_view(model).then(function (view) {\n            // replace the dummy widget with the new one.\n            var i = ArrayExt.firstIndexOf(_this.pWidget.widgets, dummy);\n            _this.pWidget.insertWidget(i, view.pWidget);\n            dummy.dispose();\n            return view;\n        }).catch(reject('Could not add child view to box', true));\n    };\n    BoxView.prototype.remove = function () {\n        this.children_views = null;\n        _super.prototype.remove.call(this);\n    };\n    BoxView.class_map = {\n        success: ['alert', 'alert-success'],\n        info: ['alert', 'alert-info'],\n        warning: ['alert', 'alert-warning'],\n        danger: ['alert', 'alert-danger']\n    };\n    return BoxView;\n}(DOMWidgetView));\nexport { BoxView };\nvar HBoxView = /** @class */ (function (_super) {\n    __extends(HBoxView, _super);\n    function HBoxView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Public constructor\n     */\n    HBoxView.prototype.initialize = function (parameters) {\n        _super.prototype.initialize.call(this, parameters);\n        this.pWidget.addClass('widget-hbox');\n    };\n    return HBoxView;\n}(BoxView));\nexport { HBoxView };\nvar VBoxView = /** @class */ (function (_super) {\n    __extends(VBoxView, _super);\n    function VBoxView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Public constructor\n     */\n    VBoxView.prototype.initialize = function (parameters) {\n        _super.prototype.initialize.call(this, parameters);\n        this.pWidget.addClass('widget-vbox');\n    };\n    return VBoxView;\n}(BoxView));\nexport { VBoxView };\nvar GridBoxView = /** @class */ (function (_super) {\n    __extends(GridBoxView, _super);\n    function GridBoxView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Public constructor\n     */\n    GridBoxView.prototype.initialize = function (parameters) {\n        _super.prototype.initialize.call(this, parameters);\n        this.pWidget.addClass('widget-gridbox');\n        // display needn't be set to flex and grid \n        this.pWidget.removeClass('widget-box');\n    };\n    return GridBoxView;\n}(BoxView));\nexport { GridBoxView };\nvar GridBoxModel = /** @class */ (function (_super) {\n    __extends(GridBoxModel, _super);\n    function GridBoxModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    GridBoxModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _view_name: 'GridBoxView',\n            _model_name: 'GridBoxModel',\n        });\n    };\n    return GridBoxModel;\n}(BoxModel));\nexport { GridBoxModel };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { DOMWidgetView } from '@jupyter-widgets/base';\nimport { CoreDOMWidgetModel } from './widget_core';\nimport * as _ from 'underscore';\nvar ImageModel = /** @class */ (function (_super) {\n    __extends(ImageModel, _super);\n    function ImageModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ImageModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'ImageModel',\n            _view_name: 'ImageView',\n            format: 'png',\n            width: '',\n            height: '',\n            value: new DataView(new ArrayBuffer(0))\n        });\n    };\n    ImageModel.serializers = __assign(__assign({}, CoreDOMWidgetModel.serializers), { value: { serialize: function (value) {\n                return new DataView(value.buffer.slice(0));\n            } } });\n    return ImageModel;\n}(CoreDOMWidgetModel));\nexport { ImageModel };\nvar ImageView = /** @class */ (function (_super) {\n    __extends(ImageView, _super);\n    function ImageView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ImageView.prototype.render = function () {\n        /**\n         * Called when view is rendered.\n         */\n        _super.prototype.render.call(this);\n        this.pWidget.addClass('jupyter-widgets');\n        this.pWidget.addClass('widget-image');\n        this.update(); // Set defaults.\n    };\n    ImageView.prototype.update = function () {\n        /**\n         * Update the contents of this view\n         *\n         * Called when the model is changed.  The model may have been\n         * changed by another view or by a state update from the back-end.\n         */\n        var url;\n        var format = this.model.get('format');\n        var value = this.model.get('value');\n        if (format !== 'url') {\n            var blob = new Blob([value], { type: \"image/\" + this.model.get('format') });\n            url = URL.createObjectURL(blob);\n        }\n        else {\n            url = (new TextDecoder('utf-8')).decode(value.buffer);\n        }\n        // Clean up the old objectURL\n        var oldurl = this.el.src;\n        this.el.src = url;\n        if (oldurl && typeof oldurl !== 'string') {\n            URL.revokeObjectURL(oldurl);\n        }\n        var width = this.model.get('width');\n        if (width !== undefined && width.length > 0) {\n            this.el.setAttribute('width', width);\n        }\n        else {\n            this.el.removeAttribute('width');\n        }\n        var height = this.model.get('height');\n        if (height !== undefined && height.length > 0) {\n            this.el.setAttribute('height', height);\n        }\n        else {\n            this.el.removeAttribute('height');\n        }\n        return _super.prototype.update.call(this);\n    };\n    ImageView.prototype.remove = function () {\n        if (this.el.src) {\n            URL.revokeObjectURL(this.el.src);\n        }\n        _super.prototype.remove.call(this);\n    };\n    Object.defineProperty(ImageView.prototype, \"tagName\", {\n        /**\n         * The default tag name.\n         *\n         * #### Notes\n         * This is a read-only attribute.\n         */\n        get: function () {\n            // We can't make this an attribute with a default value\n            // since it would be set after it is needed in the\n            // constructor.\n            return 'img';\n        },\n        enumerable: true,\n        configurable: true\n    });\n    return ImageView;\n}(DOMWidgetView));\nexport { ImageView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { DOMWidgetView } from '@jupyter-widgets/base';\nimport { CoreDOMWidgetModel } from './widget_core';\nimport * as _ from 'underscore';\nvar VideoModel = /** @class */ (function (_super) {\n    __extends(VideoModel, _super);\n    function VideoModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    VideoModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'VideoModel',\n            _view_name: 'VideoView',\n            format: 'mp4',\n            width: '',\n            height: '',\n            autoplay: true,\n            loop: true,\n            controls: true,\n            value: new DataView(new ArrayBuffer(0))\n        });\n    };\n    VideoModel.serializers = __assign(__assign({}, CoreDOMWidgetModel.serializers), { value: { serialize: function (value) {\n                return new DataView(value.buffer.slice(0));\n            } } });\n    return VideoModel;\n}(CoreDOMWidgetModel));\nexport { VideoModel };\nvar VideoView = /** @class */ (function (_super) {\n    __extends(VideoView, _super);\n    function VideoView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    VideoView.prototype.render = function () {\n        /**\n         * Called when view is rendered.\n         */\n        _super.prototype.render.call(this);\n        this.pWidget.addClass('jupyter-widgets');\n        this.pWidget.addClass('widget-image');\n        this.update(); // Set defaults.\n    };\n    VideoView.prototype.update = function () {\n        /**\n         * Update the contents of this view\n         *\n         * Called when the model is changed.  The model may have been\n         * changed by another view or by a state update from the back-end.\n         */\n        var url;\n        var format = this.model.get('format');\n        var value = this.model.get('value');\n        if (format !== 'url') {\n            var blob = new Blob([value], { type: \"video/\" + this.model.get('format') });\n            url = URL.createObjectURL(blob);\n        }\n        else {\n            url = (new TextDecoder('utf-8')).decode(value.buffer);\n        }\n        // Clean up the old objectURL\n        var oldurl = this.el.src;\n        this.el.src = url;\n        if (oldurl && typeof oldurl !== 'string') {\n            URL.revokeObjectURL(oldurl);\n        }\n        // Height and width\n        var width = this.model.get('width');\n        if (width !== undefined && width.length > 0) {\n            this.el.setAttribute('width', width);\n        }\n        else {\n            this.el.removeAttribute('width');\n        }\n        var height = this.model.get('height');\n        if (height !== undefined && height.length > 0) {\n            this.el.setAttribute('height', height);\n        }\n        else {\n            this.el.removeAttribute('height');\n        }\n        // Video attributes\n        this.el.loop = this.model.get('loop');\n        this.el.autoplay = this.model.get('autoplay');\n        this.el.controls = this.model.get('controls');\n        return _super.prototype.update.call(this);\n    };\n    VideoView.prototype.remove = function () {\n        if (this.el.src) {\n            URL.revokeObjectURL(this.el.src);\n        }\n        _super.prototype.remove.call(this);\n    };\n    Object.defineProperty(VideoView.prototype, \"tagName\", {\n        /**\n         * The default tag name.\n         *\n         * #### Notes\n         * This is a read-only attribute.\n         */\n        get: function () {\n            // We can't make this an attribute with a default value\n            // since it would be set after it is needed in the\n            // constructor.\n            return 'video';\n        },\n        enumerable: true,\n        configurable: true\n    });\n    return VideoView;\n}(DOMWidgetView));\nexport { VideoView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { DOMWidgetView } from '@jupyter-widgets/base';\nimport { CoreDOMWidgetModel } from './widget_core';\nimport * as _ from 'underscore';\nvar AudioModel = /** @class */ (function (_super) {\n    __extends(AudioModel, _super);\n    function AudioModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    AudioModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'AudioModel',\n            _view_name: 'AudioView',\n            format: 'mp3',\n            autoplay: true,\n            loop: true,\n            controls: true,\n            value: new DataView(new ArrayBuffer(0))\n        });\n    };\n    AudioModel.serializers = __assign(__assign({}, CoreDOMWidgetModel.serializers), { value: { serialize: function (value) {\n                return new DataView(value.buffer.slice(0));\n            } } });\n    return AudioModel;\n}(CoreDOMWidgetModel));\nexport { AudioModel };\nvar AudioView = /** @class */ (function (_super) {\n    __extends(AudioView, _super);\n    function AudioView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    AudioView.prototype.render = function () {\n        /**\n         * Called when view is rendered.\n         */\n        _super.prototype.render.call(this);\n        this.pWidget.addClass('jupyter-widgets');\n        this.update(); // Set defaults.\n    };\n    AudioView.prototype.update = function () {\n        /**\n         * Update the contents of this view\n         *\n         * Called when the model is changed.  The model may have been\n         * changed by another view or by a state update from the back-end.\n         */\n        var url;\n        var format = this.model.get('format');\n        var value = this.model.get('value');\n        if (format !== 'url') {\n            var blob = new Blob([value], { type: \"audio/\" + this.model.get('format') });\n            url = URL.createObjectURL(blob);\n        }\n        else {\n            url = (new TextDecoder('utf-8')).decode(value.buffer);\n        }\n        // Clean up the old objectURL\n        var oldurl = this.el.src;\n        this.el.src = url;\n        if (oldurl && typeof oldurl !== 'string') {\n            URL.revokeObjectURL(oldurl);\n        }\n        // Audio attributes\n        this.el.loop = this.model.get('loop');\n        this.el.autoplay = this.model.get('autoplay');\n        this.el.controls = this.model.get('controls');\n        return _super.prototype.update.call(this);\n    };\n    AudioView.prototype.remove = function () {\n        if (this.el.src) {\n            URL.revokeObjectURL(this.el.src);\n        }\n        _super.prototype.remove.call(this);\n    };\n    Object.defineProperty(AudioView.prototype, \"tagName\", {\n        /**\n         * The default tag name.\n         *\n         * #### Notes\n         * This is a read-only attribute.\n         */\n        get: function () {\n            // We can't make this an attribute with a default value\n            // since it would be set after it is needed in the\n            // constructor.\n            return 'audio';\n        },\n        enumerable: true,\n        configurable: true\n    });\n    return AudioView;\n}(DOMWidgetView));\nexport { AudioView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nimport { CoreDescriptionModel } from './widget_core';\nimport { DescriptionView } from './widget_description';\nimport { uuid } from './utils';\nimport * as _ from 'underscore';\nvar ColorPickerModel = /** @class */ (function (_super) {\n    __extends(ColorPickerModel, _super);\n    function ColorPickerModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ColorPickerModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            value: 'black',\n            concise: false,\n            _model_name: 'ColorPickerModel',\n            _view_name: 'ColorPickerView'\n        });\n    };\n    return ColorPickerModel;\n}(CoreDescriptionModel));\nexport { ColorPickerModel };\nvar ColorPickerView = /** @class */ (function (_super) {\n    __extends(ColorPickerView, _super);\n    function ColorPickerView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ColorPickerView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-colorpicker');\n        this._color_container = document.createElement('div');\n        this._color_container.className = 'widget-inline-hbox widget-colorpicker-input';\n        this.el.appendChild(this._color_container);\n        this._textbox = document.createElement('input');\n        this._textbox.setAttribute('type', 'text');\n        this._textbox.id = this.label.htmlFor = uuid();\n        this._color_container.appendChild(this._textbox);\n        this._textbox.value = this.model.get('value');\n        this._colorpicker = document.createElement('input');\n        this._colorpicker.setAttribute('type', 'color');\n        this._color_container.appendChild(this._colorpicker);\n        this.listenTo(this.model, 'change:value', this._update_value);\n        this.listenTo(this.model, 'change:concise', this._update_concise);\n        this._update_concise();\n        this._update_value();\n        this.update();\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed. The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    ColorPickerView.prototype.update = function (options) {\n        if (options === undefined || options.updated_view != this) {\n            var disabled = this.model.get('disabled');\n            this._textbox.disabled = disabled;\n            this._colorpicker.disabled = disabled;\n        }\n        return _super.prototype.update.call(this);\n    };\n    ColorPickerView.prototype.events = function () {\n        // Typescript doesn't understand that these functions are called, so we\n        // specifically use them here so it knows they are being used.\n        void this._picker_change;\n        void this._text_change;\n        return {\n            'change [type=\"color\"]': '_picker_change',\n            'change [type=\"text\"]': '_text_change'\n        };\n    };\n    ColorPickerView.prototype._update_value = function () {\n        var value = this.model.get('value');\n        this._colorpicker.value = color2hex(value);\n        this._textbox.value = value;\n    };\n    ColorPickerView.prototype._update_concise = function () {\n        var concise = this.model.get('concise');\n        if (concise) {\n            this.el.classList.add('concise');\n            this._textbox.style.display = 'none';\n        }\n        else {\n            this.el.classList.remove('concise');\n            this._textbox.style.display = '';\n        }\n    };\n    ColorPickerView.prototype._picker_change = function () {\n        this.model.set('value', this._colorpicker.value);\n        this.touch();\n    };\n    ColorPickerView.prototype._text_change = function () {\n        var value = this._validate_color(this._textbox.value, this.model.get('value'));\n        this.model.set('value', value);\n        this.touch();\n    };\n    ColorPickerView.prototype._validate_color = function (color, fallback) {\n        return color.match(/#[a-fA-F0-9]{3}(?:[a-fA-F0-9]{3})?$/) ||\n            named_colors[color.toLowerCase()] ? color : fallback;\n    };\n    return ColorPickerView;\n}(DescriptionView));\nexport { ColorPickerView };\nvar named_colors = { aliceblue: '#f0f8ff', antiquewhite: '#faebd7', aqua: '#00ffff', aquamarine: '#7fffd4', azure: '#f0ffff', beige: '#f5f5dc', bisque: '#ffe4c4', black: '#000000', blanchedalmond: '#ffebcd', blue: '#0000ff', blueviolet: '#8a2be2', brown: '#a52a2a', burlywood: '#deb887', cadetblue: '#5f9ea0', chartreuse: '#7fff00', chocolate: '#d2691e', coral: '#ff7f50', cornflowerblue: '#6495ed', cornsilk: '#fff8dc', crimson: '#dc143c', cyan: '#00ffff', darkblue: '#00008b', darkcyan: '#008b8b', darkgoldenrod: '#b8860b', darkgray: '#a9a9a9', darkgrey: '#a9a9a9', darkgreen: '#006400', darkkhaki: '#bdb76b', darkmagenta: '#8b008b', darkolivegreen: '#556b2f', darkorange: '#ff8c00', darkorchid: '#9932cc', darkred: '#8b0000', darksalmon: '#e9967a', darkseagreen: '#8fbc8f', darkslateblue: '#483d8b', darkslategray: '#2f4f4f', darkslategrey: '#2f4f4f', darkturquoise: '#00ced1', darkviolet: '#9400d3', deeppink: '#ff1493', deepskyblue: '#00bfff', dimgray: '#696969', dimgrey: '#696969', dodgerblue: '#1e90ff', firebrick: '#b22222', floralwhite: '#fffaf0', forestgreen: '#228b22', fuchsia: '#ff00ff', gainsboro: '#dcdcdc', ghostwhite: '#f8f8ff', gold: '#ffd700', goldenrod: '#daa520', gray: '#808080', grey: '#808080', green: '#008000', greenyellow: '#adff2f', honeydew: '#f0fff0', hotpink: '#ff69b4', indianred: '#cd5c5c', indigo: '#4b0082', ivory: '#fffff0', khaki: '#f0e68c', lavender: '#e6e6fa', lavenderblush: '#fff0f5', lawngreen: '#7cfc00', lemonchiffon: '#fffacd', lightblue: '#add8e6', lightcoral: '#f08080', lightcyan: '#e0ffff', lightgoldenrodyellow: '#fafad2', lightgreen: '#90ee90', lightgray: '#d3d3d3', lightgrey: '#d3d3d3', lightpink: '#ffb6c1', lightsalmon: '#ffa07a', lightseagreen: '#20b2aa', lightskyblue: '#87cefa', lightslategray: '#778899', lightslategrey: '#778899', lightsteelblue: '#b0c4de', lightyellow: '#ffffe0', lime: '#00ff00', limegreen: '#32cd32', linen: '#faf0e6', magenta: '#ff00ff', maroon: '#800000', mediumaquamarine: '#66cdaa', mediumblue: '#0000cd', mediumorchid: '#ba55d3', mediumpurple: '#9370db', mediumseagreen: '#3cb371', mediumslateblue: '#7b68ee', mediumspringgreen: '#00fa9a', mediumturquoise: '#48d1cc', mediumvioletred: '#c71585', midnightblue: '#191970', mintcream: '#f5fffa', mistyrose: '#ffe4e1', moccasin: '#ffe4b5', navajowhite: '#ffdead', navy: '#000080', oldlace: '#fdf5e6', olive: '#808000', olivedrab: '#6b8e23', orange: '#ffa500', orangered: '#ff4500', orchid: '#da70d6', palegoldenrod: '#eee8aa', palegreen: '#98fb98', paleturquoise: '#afeeee', palevioletred: '#db7093', papayawhip: '#ffefd5', peachpuff: '#ffdab9', peru: '#cd853f', pink: '#ffc0cb', plum: '#dda0dd', powderblue: '#b0e0e6', purple: '#800080', red: '#ff0000', rosybrown: '#bc8f8f', royalblue: '#4169e1', saddlebrown: '#8b4513', salmon: '#fa8072', sandybrown: '#f4a460', seagreen: '#2e8b57', seashell: '#fff5ee', sienna: '#a0522d', silver: '#c0c0c0', skyblue: '#87ceeb', slateblue: '#6a5acd', slategray: '#708090', slategrey: '#708090', snow: '#fffafa', springgreen: '#00ff7f', steelblue: '#4682b4', tan: '#d2b48c', teal: '#008080', thistle: '#d8bfd8', tomato: '#ff6347', turquoise: '#40e0d0', violet: '#ee82ee', wheat: '#f5deb3', white: '#ffffff', whitesmoke: '#f5f5f5', yellow: '#ffff00', yellowgreen: '#9acd32', };\n/*\n * From a valid html color (named color, 6-digits or 3-digits hex format)\n * return a 6-digits hexadecimal color #rrggbb.\n */\nfunction color2hex(color) {\n    return named_colors[color.toLowerCase()] || rgb3_to_rgb6(color);\n}\nfunction rgb3_to_rgb6(rgb) {\n    if (rgb.length === 7) {\n        return rgb;\n    }\n    else {\n        return '#' + rgb.charAt(1) + rgb.charAt(1) +\n            rgb.charAt(2) + rgb.charAt(2) +\n            rgb.charAt(3) + rgb.charAt(3);\n    }\n}\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { DescriptionView } from './widget_description';\nimport { CoreDescriptionModel } from './widget_core';\nimport { uuid } from './utils';\nimport * as _ from 'underscore';\nexport function serialize_date(value) {\n    if (value === null) {\n        return null;\n    }\n    else {\n        return {\n            year: value.getUTCFullYear(),\n            month: value.getUTCMonth(),\n            date: value.getUTCDate()\n        };\n    }\n}\nexport function deserialize_date(value) {\n    if (value === null) {\n        return null;\n    }\n    else {\n        var date = new Date();\n        date.setUTCFullYear(value.year, value.month, value.date);\n        date.setUTCHours(0, 0, 0, 0);\n        return date;\n    }\n}\nvar DatePickerModel = /** @class */ (function (_super) {\n    __extends(DatePickerModel, _super);\n    function DatePickerModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    DatePickerModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            value: null,\n            _model_name: 'DatePickerModel',\n            _view_name: 'DatePickerView'\n        });\n    };\n    DatePickerModel.serializers = __assign(__assign({}, CoreDescriptionModel.serializers), { value: {\n            serialize: serialize_date,\n            deserialize: deserialize_date\n        } });\n    return DatePickerModel;\n}(CoreDescriptionModel));\nexport { DatePickerModel };\nvar DatePickerView = /** @class */ (function (_super) {\n    __extends(DatePickerView, _super);\n    function DatePickerView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    DatePickerView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-datepicker');\n        this._datepicker = document.createElement('input');\n        this._datepicker.setAttribute('type', 'date');\n        this._datepicker.id = this.label.htmlFor = uuid();\n        this.el.appendChild(this._datepicker);\n        this.listenTo(this.model, 'change:value', this._update_value);\n        this._update_value();\n        this.update();\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed. The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    DatePickerView.prototype.update = function (options) {\n        if (options === undefined || options.updated_view !== this) {\n            this._datepicker.disabled = this.model.get('disabled');\n        }\n        return _super.prototype.update.call(this);\n    };\n    DatePickerView.prototype.events = function () {\n        // Typescript doesn't understand that these functions are called, so we\n        // specifically use them here so it knows they are being used.\n        void this._picker_change;\n        void this._picker_focusout;\n        return {\n            'change [type=\"date\"]': '_picker_change',\n            'focusout [type=\"date\"]': '_picker_focusout'\n        };\n    };\n    DatePickerView.prototype._update_value = function () {\n        var value = this.model.get('value');\n        this._datepicker.valueAsDate = value;\n    };\n    DatePickerView.prototype._picker_change = function () {\n        if (!this._datepicker.validity.badInput) {\n            this.model.set('value', this._datepicker.valueAsDate);\n            this.touch();\n        }\n    };\n    DatePickerView.prototype._picker_focusout = function () {\n        if (this._datepicker.validity.badInput) {\n            this.model.set('value', null);\n            this.touch();\n        }\n    };\n    return DatePickerView;\n}(DescriptionView));\nexport { DatePickerView };\n","// Computes the decimal coefficient and exponent of the specified number x with\n// significant digits p, where x is positive and p is in [1, 21] or undefined.\n// For example, formatDecimal(1.23) returns [\"123\", 0].\nexport default function(x, p) {\n  if ((i = (x = p ? x.toExponential(p - 1) : x.toExponential()).indexOf(\"e\")) < 0) return null; // NaN, ±Infinity\n  var i, coefficient = x.slice(0, i);\n\n  // The string returned by toExponential either has the form \\d\\.\\d+e[-+]\\d+\n  // (e.g., 1.2e+3) or the form \\de[-+]\\d+ (e.g., 1e+3).\n  return [\n    coefficient.length > 1 ? coefficient[0] + coefficient.slice(2) : coefficient,\n    +x.slice(i + 1)\n  ];\n}\n","// [[fill]align][sign][symbol][0][width][,][.precision][~][type]\nvar re = /^(?:(.)?([<>=^]))?([+\\-( ])?([$#])?(0)?(\\d+)?(,)?(\\.\\d+)?(~)?([a-z%])?$/i;\n\nexport default function formatSpecifier(specifier) {\n  if (!(match = re.exec(specifier))) throw new Error(\"invalid format: \" + specifier);\n  var match;\n  return new FormatSpecifier({\n    fill: match[1],\n    align: match[2],\n    sign: match[3],\n    symbol: match[4],\n    zero: match[5],\n    width: match[6],\n    comma: match[7],\n    precision: match[8] && match[8].slice(1),\n    trim: match[9],\n    type: match[10]\n  });\n}\n\nformatSpecifier.prototype = FormatSpecifier.prototype; // instanceof\n\nexport function FormatSpecifier(specifier) {\n  this.fill = specifier.fill === undefined ? \" \" : specifier.fill + \"\";\n  this.align = specifier.align === undefined ? \">\" : specifier.align + \"\";\n  this.sign = specifier.sign === undefined ? \"-\" : specifier.sign + \"\";\n  this.symbol = specifier.symbol === undefined ? \"\" : specifier.symbol + \"\";\n  this.zero = !!specifier.zero;\n  this.width = specifier.width === undefined ? undefined : +specifier.width;\n  this.comma = !!specifier.comma;\n  this.precision = specifier.precision === undefined ? undefined : +specifier.precision;\n  this.trim = !!specifier.trim;\n  this.type = specifier.type === undefined ? \"\" : specifier.type + \"\";\n}\n\nFormatSpecifier.prototype.toString = function() {\n  return this.fill\n      + this.align\n      + this.sign\n      + this.symbol\n      + (this.zero ? \"0\" : \"\")\n      + (this.width === undefined ? \"\" : Math.max(1, this.width | 0))\n      + (this.comma ? \",\" : \"\")\n      + (this.precision === undefined ? \"\" : \".\" + Math.max(0, this.precision | 0))\n      + (this.trim ? \"~\" : \"\")\n      + this.type;\n};\n","// Trims insignificant zeros, e.g., replaces 1.2000k with 1.2k.\nexport default function(s) {\n  out: for (var n = s.length, i = 1, i0 = -1, i1; i < n; ++i) {\n    switch (s[i]) {\n      case \".\": i0 = i1 = i; break;\n      case \"0\": if (i0 === 0) i0 = i; i1 = i; break;\n      default: if (!+s[i]) break out; if (i0 > 0) i0 = 0; break;\n    }\n  }\n  return i0 > 0 ? s.slice(0, i0) + s.slice(i1 + 1) : s;\n}\n","import formatDecimal from \"./formatDecimal.js\";\n\nexport var prefixExponent;\n\nexport default function(x, p) {\n  var d = formatDecimal(x, p);\n  if (!d) return x + \"\";\n  var coefficient = d[0],\n      exponent = d[1],\n      i = exponent - (prefixExponent = Math.max(-8, Math.min(8, Math.floor(exponent / 3))) * 3) + 1,\n      n = coefficient.length;\n  return i === n ? coefficient\n      : i > n ? coefficient + new Array(i - n + 1).join(\"0\")\n      : i > 0 ? coefficient.slice(0, i) + \".\" + coefficient.slice(i)\n      : \"0.\" + new Array(1 - i).join(\"0\") + formatDecimal(x, Math.max(0, p + i - 1))[0]; // less than 1y!\n}\n","import formatLocale from \"./locale.js\";\n\nvar locale;\nexport var format;\nexport var formatPrefix;\n\ndefaultLocale({\n  decimal: \".\",\n  thousands: \",\",\n  grouping: [3],\n  currency: [\"$\", \"\"],\n  minus: \"-\"\n});\n\nexport default function defaultLocale(definition) {\n  locale = formatLocale(definition);\n  format = locale.format;\n  formatPrefix = locale.formatPrefix;\n  return locale;\n}\n","import formatDecimal from \"./formatDecimal.js\";\n\nexport default function(x, p) {\n  var d = formatDecimal(x, p);\n  if (!d) return x + \"\";\n  var coefficient = d[0],\n      exponent = d[1];\n  return exponent < 0 ? \"0.\" + new Array(-exponent).join(\"0\") + coefficient\n      : coefficient.length > exponent + 1 ? coefficient.slice(0, exponent + 1) + \".\" + coefficient.slice(exponent + 1)\n      : coefficient + new Array(exponent - coefficient.length + 2).join(\"0\");\n}\n","import formatPrefixAuto from \"./formatPrefixAuto.js\";\nimport formatRounded from \"./formatRounded.js\";\n\nexport default {\n  \"%\": function(x, p) { return (x * 100).toFixed(p); },\n  \"b\": function(x) { return Math.round(x).toString(2); },\n  \"c\": function(x) { return x + \"\"; },\n  \"d\": function(x) { return Math.round(x).toString(10); },\n  \"e\": function(x, p) { return x.toExponential(p); },\n  \"f\": function(x, p) { return x.toFixed(p); },\n  \"g\": function(x, p) { return x.toPrecision(p); },\n  \"o\": function(x) { return Math.round(x).toString(8); },\n  \"p\": function(x, p) { return formatRounded(x * 100, p); },\n  \"r\": formatRounded,\n  \"s\": formatPrefixAuto,\n  \"X\": function(x) { return Math.round(x).toString(16).toUpperCase(); },\n  \"x\": function(x) { return Math.round(x).toString(16); }\n};\n","export default function(x) {\n  return x;\n}\n","import exponent from \"./exponent.js\";\nimport formatGroup from \"./formatGroup.js\";\nimport formatNumerals from \"./formatNumerals.js\";\nimport formatSpecifier from \"./formatSpecifier.js\";\nimport formatTrim from \"./formatTrim.js\";\nimport formatTypes from \"./formatTypes.js\";\nimport {prefixExponent} from \"./formatPrefixAuto.js\";\nimport identity from \"./identity.js\";\n\nvar map = Array.prototype.map,\n    prefixes = [\"y\",\"z\",\"a\",\"f\",\"p\",\"n\",\"µ\",\"m\",\"\",\"k\",\"M\",\"G\",\"T\",\"P\",\"E\",\"Z\",\"Y\"];\n\nexport default function(locale) {\n  var group = locale.grouping === undefined || locale.thousands === undefined ? identity : formatGroup(map.call(locale.grouping, Number), locale.thousands + \"\"),\n      currencyPrefix = locale.currency === undefined ? \"\" : locale.currency[0] + \"\",\n      currencySuffix = locale.currency === undefined ? \"\" : locale.currency[1] + \"\",\n      decimal = locale.decimal === undefined ? \".\" : locale.decimal + \"\",\n      numerals = locale.numerals === undefined ? identity : formatNumerals(map.call(locale.numerals, String)),\n      percent = locale.percent === undefined ? \"%\" : locale.percent + \"\",\n      minus = locale.minus === undefined ? \"-\" : locale.minus + \"\",\n      nan = locale.nan === undefined ? \"NaN\" : locale.nan + \"\";\n\n  function newFormat(specifier) {\n    specifier = formatSpecifier(specifier);\n\n    var fill = specifier.fill,\n        align = specifier.align,\n        sign = specifier.sign,\n        symbol = specifier.symbol,\n        zero = specifier.zero,\n        width = specifier.width,\n        comma = specifier.comma,\n        precision = specifier.precision,\n        trim = specifier.trim,\n        type = specifier.type;\n\n    // The \"n\" type is an alias for \",g\".\n    if (type === \"n\") comma = true, type = \"g\";\n\n    // The \"\" type, and any invalid type, is an alias for \".12~g\".\n    else if (!formatTypes[type]) precision === undefined && (precision = 12), trim = true, type = \"g\";\n\n    // If zero fill is specified, padding goes after sign and before digits.\n    if (zero || (fill === \"0\" && align === \"=\")) zero = true, fill = \"0\", align = \"=\";\n\n    // Compute the prefix and suffix.\n    // For SI-prefix, the suffix is lazily computed.\n    var prefix = symbol === \"$\" ? currencyPrefix : symbol === \"#\" && /[boxX]/.test(type) ? \"0\" + type.toLowerCase() : \"\",\n        suffix = symbol === \"$\" ? currencySuffix : /[%p]/.test(type) ? percent : \"\";\n\n    // What format function should we use?\n    // Is this an integer type?\n    // Can this type generate exponential notation?\n    var formatType = formatTypes[type],\n        maybeSuffix = /[defgprs%]/.test(type);\n\n    // Set the default precision if not specified,\n    // or clamp the specified precision to the supported range.\n    // For significant precision, it must be in [1, 21].\n    // For fixed precision, it must be in [0, 20].\n    precision = precision === undefined ? 6\n        : /[gprs]/.test(type) ? Math.max(1, Math.min(21, precision))\n        : Math.max(0, Math.min(20, precision));\n\n    function format(value) {\n      var valuePrefix = prefix,\n          valueSuffix = suffix,\n          i, n, c;\n\n      if (type === \"c\") {\n        valueSuffix = formatType(value) + valueSuffix;\n        value = \"\";\n      } else {\n        value = +value;\n\n        // Perform the initial formatting.\n        var valueNegative = value < 0;\n        value = isNaN(value) ? nan : formatType(Math.abs(value), precision);\n\n        // Trim insignificant zeros.\n        if (trim) value = formatTrim(value);\n\n        // If a negative value rounds to zero during formatting, treat as positive.\n        if (valueNegative && +value === 0) valueNegative = false;\n\n        // Compute the prefix and suffix.\n        valuePrefix = (valueNegative ? (sign === \"(\" ? sign : minus) : sign === \"-\" || sign === \"(\" ? \"\" : sign) + valuePrefix;\n\n        valueSuffix = (type === \"s\" ? prefixes[8 + prefixExponent / 3] : \"\") + valueSuffix + (valueNegative && sign === \"(\" ? \")\" : \"\");\n\n        // Break the formatted value into the integer “value” part that can be\n        // grouped, and fractional or exponential “suffix” part that is not.\n        if (maybeSuffix) {\n          i = -1, n = value.length;\n          while (++i < n) {\n            if (c = value.charCodeAt(i), 48 > c || c > 57) {\n              valueSuffix = (c === 46 ? decimal + value.slice(i + 1) : value.slice(i)) + valueSuffix;\n              value = value.slice(0, i);\n              break;\n            }\n          }\n        }\n      }\n\n      // If the fill character is not \"0\", grouping is applied before padding.\n      if (comma && !zero) value = group(value, Infinity);\n\n      // Compute the padding.\n      var length = valuePrefix.length + value.length + valueSuffix.length,\n          padding = length < width ? new Array(width - length + 1).join(fill) : \"\";\n\n      // If the fill character is \"0\", grouping is applied after padding.\n      if (comma && zero) value = group(padding + value, padding.length ? width - valueSuffix.length : Infinity), padding = \"\";\n\n      // Reconstruct the final output based on the desired alignment.\n      switch (align) {\n        case \"<\": value = valuePrefix + value + valueSuffix + padding; break;\n        case \"=\": value = valuePrefix + padding + value + valueSuffix; break;\n        case \"^\": value = padding.slice(0, length = padding.length >> 1) + valuePrefix + value + valueSuffix + padding.slice(length); break;\n        default: value = padding + valuePrefix + value + valueSuffix; break;\n      }\n\n      return numerals(value);\n    }\n\n    format.toString = function() {\n      return specifier + \"\";\n    };\n\n    return format;\n  }\n\n  function formatPrefix(specifier, value) {\n    var f = newFormat((specifier = formatSpecifier(specifier), specifier.type = \"f\", specifier)),\n        e = Math.max(-8, Math.min(8, Math.floor(exponent(value) / 3))) * 3,\n        k = Math.pow(10, -e),\n        prefix = prefixes[8 + e / 3];\n    return function(value) {\n      return f(k * value) + prefix;\n    };\n  }\n\n  return {\n    format: newFormat,\n    formatPrefix: formatPrefix\n  };\n}\n","export default function(grouping, thousands) {\n  return function(value, width) {\n    var i = value.length,\n        t = [],\n        j = 0,\n        g = grouping[0],\n        length = 0;\n\n    while (i > 0 && g > 0) {\n      if (length + g + 1 > width) g = Math.max(1, width - length);\n      t.push(value.substring(i -= g, i + g));\n      if ((length += g + 1) > width) break;\n      g = grouping[j = (j + 1) % grouping.length];\n    }\n\n    return t.reverse().join(thousands);\n  };\n}\n","export default function(numerals) {\n  return function(value) {\n    return value.replace(/[0-9]/g, function(i) {\n      return numerals[+i];\n    });\n  };\n}\n","import formatDecimal from \"./formatDecimal.js\";\n\nexport default function(x) {\n  return x = formatDecimal(Math.abs(x)), x ? x[1] : NaN;\n}\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { CoreDescriptionModel } from './widget_core';\nimport { DescriptionView, DescriptionStyleModel } from './widget_description';\nimport { DOMWidgetView } from '@jupyter-widgets/base';\nimport { uuid } from './utils';\nimport { format } from 'd3-format';\nimport * as _ from 'underscore';\nimport $ from 'jquery';\nimport 'jquery-ui/ui/widgets/slider';\nvar IntModel = /** @class */ (function (_super) {\n    __extends(IntModel, _super);\n    function IntModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    IntModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'IntModel',\n            value: 0,\n        });\n    };\n    return IntModel;\n}(CoreDescriptionModel));\nexport { IntModel };\nvar BoundedIntModel = /** @class */ (function (_super) {\n    __extends(BoundedIntModel, _super);\n    function BoundedIntModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    BoundedIntModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'BoundedIntModel',\n            max: 100,\n            min: 0\n        });\n    };\n    return BoundedIntModel;\n}(IntModel));\nexport { BoundedIntModel };\nvar SliderStyleModel = /** @class */ (function (_super) {\n    __extends(SliderStyleModel, _super);\n    function SliderStyleModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    SliderStyleModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'SliderStyleModel' });\n    };\n    SliderStyleModel.styleProperties = __assign(__assign({}, DescriptionStyleModel.styleProperties), { handle_color: {\n            selector: '.ui-slider-handle',\n            attribute: 'background-color',\n            default: null\n        } });\n    return SliderStyleModel;\n}(DescriptionStyleModel));\nexport { SliderStyleModel };\nvar IntSliderModel = /** @class */ (function (_super) {\n    __extends(IntSliderModel, _super);\n    function IntSliderModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    IntSliderModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'IntSliderModel',\n            _view_name: 'IntSliderView',\n            step: 1,\n            orientation: 'horizontal',\n            readout: true,\n            readout_format: 'd',\n            continuous_update: true,\n            style: null,\n            disabled: false,\n        });\n    };\n    IntSliderModel.prototype.initialize = function (attributes, options) {\n        _super.prototype.initialize.call(this, attributes, options);\n        this.on('change:readout_format', this.update_readout_format, this);\n        this.update_readout_format();\n    };\n    IntSliderModel.prototype.update_readout_format = function () {\n        this.readout_formatter = format(this.get('readout_format'));\n    };\n    return IntSliderModel;\n}(BoundedIntModel));\nexport { IntSliderModel };\nvar IntRangeSliderModel = /** @class */ (function (_super) {\n    __extends(IntRangeSliderModel, _super);\n    function IntRangeSliderModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    return IntRangeSliderModel;\n}(IntSliderModel));\nexport { IntRangeSliderModel };\nvar BaseIntSliderView = /** @class */ (function (_super) {\n    __extends(BaseIntSliderView, _super);\n    function BaseIntSliderView() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._parse_value = parseInt;\n        return _this;\n    }\n    BaseIntSliderView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-slider');\n        this.el.classList.add('widget-hslider');\n        (this.$slider = $('<div />'))\n            .slider({\n            slide: this.handleSliderChange.bind(this),\n            stop: this.handleSliderChanged.bind(this)\n        })\n            .addClass('slider');\n        // Put the slider in a container\n        this.slider_container = document.createElement('div');\n        this.slider_container.classList.add('slider-container');\n        this.slider_container.appendChild(this.$slider[0]);\n        this.el.appendChild(this.slider_container);\n        this.readout = document.createElement('div');\n        this.el.appendChild(this.readout);\n        this.readout.classList.add('widget-readout');\n        this.readout.contentEditable = 'true';\n        this.readout.style.display = 'none';\n        // Set defaults.\n        this.update();\n    };\n    BaseIntSliderView.prototype.update = function (options) {\n        /**\n         * Update the contents of this view\n         *\n         * Called when the model is changed.  The model may have been\n         * changed by another view or by a state update from the back-end.\n         */\n        if (options === undefined || options.updated_view !== this) {\n            // JQuery slider option keys.  These keys happen to have a\n            // one-to-one mapping with the corresponding keys of the model.\n            var jquery_slider_keys = ['step', 'disabled'];\n            var that_1 = this;\n            that_1.$slider.slider({});\n            jquery_slider_keys.forEach(function (key) {\n                var model_value = that_1.model.get(key);\n                if (model_value !== undefined) {\n                    that_1.$slider.slider('option', key, model_value);\n                }\n            });\n            if (this.model.get('disabled')) {\n                this.readout.contentEditable = 'false';\n            }\n            else {\n                this.readout.contentEditable = 'true';\n            }\n            var max = this.model.get('max');\n            var min = this.model.get('min');\n            if (min <= max) {\n                if (max !== undefined) {\n                    this.$slider.slider('option', 'max', max);\n                }\n                if (min !== undefined) {\n                    this.$slider.slider('option', 'min', min);\n                }\n            }\n            // WORKAROUND FOR JQUERY SLIDER BUG.\n            // The horizontal position of the slider handle\n            // depends on the value of the slider at the time\n            // of orientation change.  Before applying the new\n            // workaround, we set the value to the minimum to\n            // make sure that the horizontal placement of the\n            // handle in the vertical slider is always\n            // consistent.\n            var orientation_1 = this.model.get('orientation');\n            this.$slider.slider('option', 'orientation', orientation_1);\n            // Use the right CSS classes for vertical & horizontal sliders\n            if (orientation_1 === 'vertical') {\n                this.el.classList.remove('widget-hslider');\n                this.el.classList.add('widget-vslider');\n                this.el.classList.remove('widget-inline-hbox');\n                this.el.classList.add('widget-inline-vbox');\n            }\n            else {\n                this.el.classList.remove('widget-vslider');\n                this.el.classList.add('widget-hslider');\n                this.el.classList.remove('widget-inline-vbox');\n                this.el.classList.add('widget-inline-hbox');\n            }\n            var readout = this.model.get('readout');\n            if (readout) {\n                this.readout.style.display = '';\n                this.displayed.then(function () {\n                    if (that_1.readout_overflow()) {\n                        that_1.readout.classList.add('overflow');\n                    }\n                    else {\n                        that_1.readout.classList.remove('overflow');\n                    }\n                });\n            }\n            else {\n                this.readout.style.display = 'none';\n            }\n        }\n        return _super.prototype.update.call(this);\n    };\n    /**\n     * Returns true if the readout box content overflows.\n     */\n    BaseIntSliderView.prototype.readout_overflow = function () {\n        return this.readout.scrollWidth > this.readout.clientWidth;\n    };\n    BaseIntSliderView.prototype.events = function () {\n        return {\n            // Dictionary of events and their handlers.\n            'slide': 'handleSliderChange',\n            'slidestop': 'handleSliderChanged',\n            'blur [contentEditable=true]': 'handleTextChange',\n            'keydown [contentEditable=true]': 'handleKeyDown'\n        };\n    };\n    BaseIntSliderView.prototype.handleKeyDown = function (e) {\n        if (e.keyCode === 13) { /* keyboard keycodes `enter` */\n            e.preventDefault();\n            this.handleTextChange();\n        }\n    };\n    /**\n     * Validate the value of the slider before sending it to the back-end\n     * and applying it to the other views on the page.\n     */\n    BaseIntSliderView.prototype._validate_slide_value = function (x) {\n        return Math.floor(x);\n    };\n    return BaseIntSliderView;\n}(DescriptionView));\nexport { BaseIntSliderView };\nvar IntRangeSliderView = /** @class */ (function (_super) {\n    __extends(IntRangeSliderView, _super);\n    function IntRangeSliderView() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        // range numbers can be separated by a hyphen, colon, or an en-dash\n        _this._range_regex = /^\\s*([+-]?\\d+)\\s*[-:–]\\s*([+-]?\\d+)/;\n        return _this;\n    }\n    IntRangeSliderView.prototype.update = function (options) {\n        _super.prototype.update.call(this, options);\n        this.$slider.slider('option', 'range', true);\n        // values for the range case are validated python-side in\n        // _Bounded{Int,Float}RangeWidget._validate\n        var value = this.model.get('value');\n        this.$slider.slider('option', 'values', value.slice());\n        this.readout.textContent = this.valueToString(value);\n        if (this.model.get('value') !== value) {\n            this.model.set('value', value, { updated_view: this });\n            this.touch();\n        }\n    };\n    /**\n     * Write value to a string\n     */\n    IntRangeSliderView.prototype.valueToString = function (value) {\n        var format = this.model.readout_formatter;\n        return value.map(function (v) {\n            return format(v);\n        }).join(' – ');\n    };\n    /**\n     * Parse value from a string\n     */\n    IntRangeSliderView.prototype.stringToValue = function (text) {\n        // ranges can be expressed either 'val-val' or 'val:val' (+spaces)\n        var match = this._range_regex.exec(text);\n        if (match) {\n            return [this._parse_value(match[1]), this._parse_value(match[2])];\n        }\n        else {\n            return null;\n        }\n    };\n    /**\n     * this handles the entry of text into the contentEditable label first, the\n     * value is checked if it contains a parseable value then it is clamped\n     * within the min-max range of the slider finally, the model is updated if\n     * the value is to be changed\n     *\n     * if any of these conditions are not met, the text is reset\n     */\n    IntRangeSliderView.prototype.handleTextChange = function () {\n        var value = this.stringToValue(this.readout.textContent);\n        var vmin = this.model.get('min');\n        var vmax = this.model.get('max');\n        // reject input where NaN or lower > upper\n        if (value === null ||\n            isNaN(value[0]) ||\n            isNaN(value[1]) ||\n            (value[0] > value[1])) {\n            this.readout.textContent = this.valueToString(this.model.get('value'));\n        }\n        else {\n            // clamp to range\n            value = [Math.max(Math.min(value[0], vmax), vmin),\n                Math.max(Math.min(value[1], vmax), vmin)];\n            if ((value[0] !== this.model.get('value')[0]) ||\n                (value[1] !== this.model.get('value')[1])) {\n                this.readout.textContent = this.valueToString(value);\n                this.model.set('value', value, { updated_view: this });\n                this.touch();\n            }\n            else {\n                this.readout.textContent = this.valueToString(this.model.get('value'));\n            }\n        }\n    };\n    /**\n     * Called when the slider value is changing.\n     */\n    IntRangeSliderView.prototype.handleSliderChange = function (e, ui) {\n        var actual_value = ui.values.map(this._validate_slide_value);\n        this.readout.textContent = this.valueToString(actual_value);\n        // Only persist the value while sliding if the continuous_update\n        // trait is set to true.\n        if (this.model.get('continuous_update')) {\n            this.handleSliderChanged(e, ui);\n        }\n    };\n    /**\n     * Called when the slider value has changed.\n     *\n     * Calling model.set will trigger all of the other views of the\n     * model to update.\n     */\n    IntRangeSliderView.prototype.handleSliderChanged = function (e, ui) {\n        var actual_value = ui.values.map(this._validate_slide_value);\n        this.model.set('value', actual_value, { updated_view: this });\n        this.touch();\n    };\n    return IntRangeSliderView;\n}(BaseIntSliderView));\nexport { IntRangeSliderView };\nvar IntSliderView = /** @class */ (function (_super) {\n    __extends(IntSliderView, _super);\n    function IntSliderView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    IntSliderView.prototype.update = function (options) {\n        _super.prototype.update.call(this, options);\n        var min = this.model.get('min');\n        var max = this.model.get('max');\n        var value = this.model.get('value');\n        if (value > max) {\n            value = max;\n        }\n        else if (value < min) {\n            value = min;\n        }\n        this.$slider.slider('option', 'value', value);\n        this.readout.textContent = this.valueToString(value);\n        if (this.model.get('value') !== value) {\n            this.model.set('value', value, { updated_view: this });\n            this.touch();\n        }\n    };\n    /**\n     * Write value to a string\n     */\n    IntSliderView.prototype.valueToString = function (value) {\n        var format = this.model.readout_formatter;\n        return format(value);\n    };\n    /**\n     * Parse value from a string\n     */\n    IntSliderView.prototype.stringToValue = function (text) {\n        return this._parse_value(text);\n    };\n    /**\n     * this handles the entry of text into the contentEditable label first, the\n     * value is checked if it contains a parseable value then it is clamped\n     * within the min-max range of the slider finally, the model is updated if\n     * the value is to be changed\n     *\n     * if any of these conditions are not met, the text is reset\n     */\n    IntSliderView.prototype.handleTextChange = function () {\n        var value = this.stringToValue(this.readout.textContent);\n        var vmin = this.model.get('min');\n        var vmax = this.model.get('max');\n        if (isNaN(value)) {\n            this.readout.textContent = this.valueToString(this.model.get('value'));\n        }\n        else {\n            value = Math.max(Math.min(value, vmax), vmin);\n            if (value !== this.model.get('value')) {\n                this.readout.textContent = this.valueToString(value);\n                this.model.set('value', value, { updated_view: this });\n                this.touch();\n            }\n            else {\n                this.readout.textContent = this.valueToString(this.model.get('value'));\n            }\n        }\n    };\n    /**\n     * Called when the slider value is changing.\n     */\n    IntSliderView.prototype.handleSliderChange = function (e, ui) {\n        var actual_value = this._validate_slide_value(ui.value);\n        this.readout.textContent = this.valueToString(actual_value);\n        // Only persist the value while sliding if the continuous_update\n        // trait is set to true.\n        if (this.model.get('continuous_update')) {\n            this.handleSliderChanged(e, ui);\n        }\n    };\n    /**\n     * Called when the slider value has changed.\n     *\n     * Calling model.set will trigger all of the other views of the\n     * model to update.\n     */\n    IntSliderView.prototype.handleSliderChanged = function (e, ui) {\n        var actual_value = this._validate_slide_value(ui.value);\n        this.model.set('value', actual_value, { updated_view: this });\n        this.touch();\n    };\n    return IntSliderView;\n}(BaseIntSliderView));\nexport { IntSliderView };\nvar IntTextModel = /** @class */ (function (_super) {\n    __extends(IntTextModel, _super);\n    function IntTextModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    IntTextModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'IntTextModel',\n            _view_name: 'IntTextView',\n            disabled: false,\n            continuous_update: false,\n        });\n    };\n    return IntTextModel;\n}(IntModel));\nexport { IntTextModel };\nvar BoundedIntTextModel = /** @class */ (function (_super) {\n    __extends(BoundedIntTextModel, _super);\n    function BoundedIntTextModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    BoundedIntTextModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'BoundedIntTextModel',\n            _view_name: 'IntTextView',\n            disabled: false,\n            continuous_update: false,\n            step: 1,\n        });\n    };\n    return BoundedIntTextModel;\n}(BoundedIntModel));\nexport { BoundedIntTextModel };\nvar IntTextView = /** @class */ (function (_super) {\n    __extends(IntTextView, _super);\n    function IntTextView() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._parse_value = parseInt;\n        _this._default_step = '1';\n        return _this;\n    }\n    IntTextView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-text');\n        this.textbox = document.createElement('input');\n        this.textbox.type = 'number';\n        this.textbox.required = true;\n        this.textbox.id = this.label.htmlFor = uuid();\n        this.el.appendChild(this.textbox);\n        this.update(); // Set defaults.\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed.  The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    IntTextView.prototype.update = function (options) {\n        if (options === undefined || options.updated_view !== this) {\n            var value = this.model.get('value');\n            if (this._parse_value(this.textbox.value) !== value) {\n                this.textbox.value = value.toString();\n            }\n            if (this.model.get('min') !== undefined) {\n                this.textbox.min = this.model.get('min');\n            }\n            if (this.model.get('max') !== undefined) {\n                this.textbox.max = this.model.get('max');\n            }\n            if (this.model.get('step') !== undefined\n                && this.model.get('step') !== null) {\n                this.textbox.step = this.model.get('step');\n            }\n            else {\n                this.textbox.step = this._default_step;\n            }\n            this.textbox.disabled = this.model.get('disabled');\n        }\n        return _super.prototype.update.call(this);\n    };\n    IntTextView.prototype.events = function () {\n        return {\n            'keydown input': 'handleKeyDown',\n            'keypress input': 'handleKeypress',\n            'keyup input': 'handleKeyUp',\n            'input input': 'handleChanging',\n            'change input': 'handleChanged'\n        };\n    };\n    /**\n     * Handle key down\n     *\n     * Stop propagation so the event isn't sent to the application.\n     */\n    IntTextView.prototype.handleKeyDown = function (e) {\n        e.stopPropagation();\n    };\n    /**\n     * Handles key press\n     */\n    IntTextView.prototype.handleKeypress = function (e) {\n        if (/[e,. ]/.test(String.fromCharCode(e.keyCode))) {\n            e.preventDefault();\n        }\n    };\n    /**\n     * Handle key up\n     */\n    IntTextView.prototype.handleKeyUp = function (e) {\n        if (e.altKey || e.ctrlKey) {\n            return;\n        }\n        var target = e.target;\n        /* remove invalid characters */\n        var value = target.value;\n        value = value.replace(/[e,.\\s]/g, \"\");\n        if (value.length >= 1) {\n            var subvalue = value.substr(1);\n            value = value[0] + subvalue.replace(/[+-]/g, \"\");\n        }\n        if (target.value != value) {\n            e.preventDefault();\n            target.value = value;\n        }\n    };\n    /**\n     * Call the submit handler if continuous update is true and we are not\n     * obviously incomplete.\n     */\n    IntTextView.prototype.handleChanging = function (e) {\n        var target = e.target;\n        var trimmed = target.value.trim();\n        if (trimmed === '' || (['-', '-.', '.', '+.', '+'].indexOf(trimmed) >= 0)) {\n            // incomplete number\n            return;\n        }\n        if (this.model.get('continuous_update')) {\n            this.handleChanged(e);\n        }\n    };\n    /**\n     * Applies validated input.\n     */\n    IntTextView.prototype.handleChanged = function (e) {\n        var target = e.target;\n        var numericalValue = this._parse_value(target.value);\n        // If parse failed, reset value to value stored in model.\n        if (isNaN(numericalValue)) {\n            target.value = this.model.get('value');\n        }\n        else {\n            // Handle both the unbounded and bounded case by\n            // checking to see if the max/min properties are defined\n            var boundedValue = numericalValue;\n            if (this.model.get('max') !== undefined) {\n                boundedValue = Math.min(this.model.get('max'), boundedValue);\n            }\n            if (this.model.get('min') !== undefined) {\n                boundedValue = Math.max(this.model.get('min'), boundedValue);\n            }\n            if (boundedValue !== numericalValue) {\n                target.value = boundedValue;\n                numericalValue = boundedValue;\n            }\n            // Apply the value if it has changed.\n            if (numericalValue !== this.model.get('value')) {\n                this.model.set('value', numericalValue, { updated_view: this });\n                this.touch();\n            }\n        }\n    };\n    return IntTextView;\n}(DescriptionView));\nexport { IntTextView };\nvar ProgressStyleModel = /** @class */ (function (_super) {\n    __extends(ProgressStyleModel, _super);\n    function ProgressStyleModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ProgressStyleModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'ProgressStyleModel' });\n    };\n    ProgressStyleModel.styleProperties = __assign(__assign({}, DescriptionStyleModel.styleProperties), { bar_color: {\n            selector: '.progress-bar',\n            attribute: 'background-color',\n            default: null\n        } });\n    return ProgressStyleModel;\n}(DescriptionStyleModel));\nexport { ProgressStyleModel };\nvar IntProgressModel = /** @class */ (function (_super) {\n    __extends(IntProgressModel, _super);\n    function IntProgressModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    IntProgressModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'IntProgressModel',\n            _view_name: 'ProgressView',\n            orientation: 'horizontal',\n            bar_style: '',\n            style: null\n        });\n    };\n    return IntProgressModel;\n}(BoundedIntModel));\nexport { IntProgressModel };\nvar ProgressView = /** @class */ (function (_super) {\n    __extends(ProgressView, _super);\n    function ProgressView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ProgressView.prototype.initialize = function (parameters) {\n        _super.prototype.initialize.call(this, parameters);\n        this.listenTo(this.model, 'change:bar_style', this.update_bar_style);\n        this.pWidget.addClass('jupyter-widgets');\n    };\n    ProgressView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        var orientation = this.model.get('orientation');\n        var className = orientation === 'horizontal' ?\n            'widget-hprogress' : 'widget-vprogress';\n        this.el.classList.add(className);\n        this.progress = document.createElement('div');\n        this.progress.classList.add('progress');\n        this.progress.style.position = 'relative';\n        this.el.appendChild(this.progress);\n        this.bar = document.createElement('div');\n        this.bar.classList.add('progress-bar');\n        this.bar.style.position = 'absolute';\n        this.bar.style.bottom = '0px';\n        this.bar.style.left = '0px';\n        this.progress.appendChild(this.bar);\n        // Set defaults.\n        this.update();\n        this.set_bar_style();\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed.  The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    ProgressView.prototype.update = function () {\n        var value = this.model.get('value');\n        var max = this.model.get('max');\n        var min = this.model.get('min');\n        var orientation = this.model.get('orientation');\n        var percent = 100.0 * (value - min) / (max - min);\n        if (orientation === 'horizontal') {\n            this.el.classList.remove('widget-inline-vbox');\n            this.el.classList.remove('widget-vprogress');\n            this.el.classList.add('widget-inline-hbox');\n            this.el.classList.add('widget-hprogress');\n            this.bar.style.width = percent + '%';\n            this.bar.style.height = '100%';\n        }\n        else {\n            this.el.classList.remove('widget-inline-hbox');\n            this.el.classList.remove('widget-hprogress');\n            this.el.classList.add('widget-inline-vbox');\n            this.el.classList.add('widget-vprogress');\n            this.bar.style.width = '100%';\n            this.bar.style.height = percent + '%';\n        }\n        return _super.prototype.update.call(this);\n    };\n    ProgressView.prototype.update_bar_style = function () {\n        this.update_mapped_classes(ProgressView.class_map, 'bar_style', this.bar);\n    };\n    ProgressView.prototype.set_bar_style = function () {\n        this.set_mapped_classes(ProgressView.class_map, 'bar_style', this.bar);\n    };\n    ProgressView.class_map = {\n        success: ['progress-bar-success'],\n        info: ['progress-bar-info'],\n        warning: ['progress-bar-warning'],\n        danger: ['progress-bar-danger']\n    };\n    return ProgressView;\n}(DescriptionView));\nexport { ProgressView };\nvar PlayModel = /** @class */ (function (_super) {\n    __extends(PlayModel, _super);\n    function PlayModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    PlayModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'PlayModel',\n            _view_name: 'PlayView',\n            _playing: false,\n            _repeat: false,\n            show_repeat: true,\n            interval: 100,\n            step: 1,\n            disabled: false,\n        });\n    };\n    PlayModel.prototype.initialize = function (attributes, options) {\n        _super.prototype.initialize.call(this, attributes, options);\n    };\n    PlayModel.prototype.loop = function () {\n        if (this.get('_playing')) {\n            var next_value = this.get('value') + this.get('step');\n            if (next_value <= this.get('max')) {\n                this.set('value', next_value);\n                this.schedule_next();\n            }\n            else {\n                if (this.get('_repeat')) {\n                    this.set('value', this.get('min'));\n                    this.schedule_next();\n                }\n                else {\n                    this.set('_playing', false);\n                }\n            }\n            this.save_changes();\n        }\n    };\n    PlayModel.prototype.schedule_next = function () {\n        window.setTimeout(this.loop.bind(this), this.get('interval'));\n    };\n    PlayModel.prototype.stop = function () {\n        this.set('_playing', false);\n        this.set('value', this.get('min'));\n        this.save_changes();\n    };\n    PlayModel.prototype.pause = function () {\n        this.set('_playing', false);\n        this.save_changes();\n    };\n    PlayModel.prototype.play = function () {\n        this.set('_playing', true);\n        if (this.get('value') == this.get('max')) {\n            // if the value is at the end, reset if first, and then schedule the next\n            this.set('value', this.get('min'));\n            this.schedule_next();\n            this.save_changes();\n        }\n        else {\n            // otherwise directly start with the next value\n            // loop will call save_changes in this case\n            this.loop();\n        }\n    };\n    PlayModel.prototype.repeat = function () {\n        this.set('_repeat', !this.get('_repeat'));\n        this.save_changes();\n    };\n    return PlayModel;\n}(BoundedIntModel));\nexport { PlayModel };\nvar PlayView = /** @class */ (function (_super) {\n    __extends(PlayView, _super);\n    function PlayView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    PlayView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-play');\n        this.playButton = document.createElement('button');\n        this.pauseButton = document.createElement('button');\n        this.stopButton = document.createElement('button');\n        this.repeatButton = document.createElement('button');\n        this.playButton.className = 'jupyter-button';\n        this.pauseButton.className = 'jupyter-button';\n        this.stopButton.className = 'jupyter-button';\n        this.repeatButton.className = 'jupyter-button';\n        this.el.appendChild(this.playButton); // Toggle button with playing\n        this.el.appendChild(this.pauseButton); // Disable if not playing\n        this.el.appendChild(this.stopButton); // Disable if not playing\n        this.el.appendChild(this.repeatButton); // Always enabled, but may be hidden\n        var playIcon = document.createElement('i');\n        playIcon.className = 'fa fa-play';\n        this.playButton.appendChild(playIcon);\n        var pauseIcon = document.createElement('i');\n        pauseIcon.className = 'fa fa-pause';\n        this.pauseButton.appendChild(pauseIcon);\n        var stopIcon = document.createElement('i');\n        stopIcon.className = 'fa fa-stop';\n        this.stopButton.appendChild(stopIcon);\n        var repeatIcon = document.createElement('i');\n        repeatIcon.className = 'fa fa-retweet';\n        this.repeatButton.appendChild(repeatIcon);\n        this.playButton.onclick = this.model.play.bind(this.model);\n        this.pauseButton.onclick = this.model.pause.bind(this.model);\n        this.stopButton.onclick = this.model.stop.bind(this.model);\n        this.repeatButton.onclick = this.model.repeat.bind(this.model);\n        this.listenTo(this.model, 'change:_playing', this.update_playing);\n        this.listenTo(this.model, 'change:_repeat', this.update_repeat);\n        this.listenTo(this.model, 'change:show_repeat', this.update_repeat);\n        this.update_playing();\n        this.update_repeat();\n        this.update();\n    };\n    PlayView.prototype.update = function () {\n        var disabled = this.model.get('disabled');\n        this.playButton.disabled = disabled;\n        this.pauseButton.disabled = disabled;\n        this.stopButton.disabled = disabled;\n        this.repeatButton.disabled = disabled;\n        this.update_playing();\n    };\n    PlayView.prototype.update_playing = function () {\n        var playing = this.model.get('_playing');\n        var disabled = this.model.get('disabled');\n        if (playing) {\n            if (!disabled) {\n                this.pauseButton.disabled = false;\n            }\n            this.playButton.classList.add('mod-active');\n        }\n        else {\n            if (!disabled) {\n                this.pauseButton.disabled = true;\n            }\n            this.playButton.classList.remove('mod-active');\n        }\n    };\n    PlayView.prototype.update_repeat = function () {\n        var repeat = this.model.get('_repeat');\n        this.repeatButton.style.display = this.model.get('show_repeat') ? this.playButton.style.display : 'none';\n        if (repeat) {\n            this.repeatButton.classList.add('mod-active');\n        }\n        else {\n            this.repeatButton.classList.remove('mod-active');\n        }\n    };\n    return PlayView;\n}(DOMWidgetView));\nexport { PlayView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nimport { CoreDescriptionModel } from './widget_core';\nimport * as _ from 'underscore';\nimport { IntSliderView, IntRangeSliderView, IntTextView, BaseIntSliderView } from './widget_int';\nimport { format } from 'd3-format';\nvar FloatModel = /** @class */ (function (_super) {\n    __extends(FloatModel, _super);\n    function FloatModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    FloatModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'FloatModel',\n            value: 0,\n        });\n    };\n    return FloatModel;\n}(CoreDescriptionModel));\nexport { FloatModel };\nvar BoundedFloatModel = /** @class */ (function (_super) {\n    __extends(BoundedFloatModel, _super);\n    function BoundedFloatModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    BoundedFloatModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'BoundedFloatModel',\n            max: 100.0,\n            min: 0.0\n        });\n    };\n    return BoundedFloatModel;\n}(FloatModel));\nexport { BoundedFloatModel };\nvar FloatSliderModel = /** @class */ (function (_super) {\n    __extends(FloatSliderModel, _super);\n    function FloatSliderModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    FloatSliderModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'FloatSliderModel',\n            _view_name: 'FloatSliderView',\n            step: 1.0,\n            orientation: 'horizontal',\n            _range: false,\n            readout: true,\n            readout_format: '.2f',\n            slider_color: null,\n            continuous_update: true,\n            disabled: false,\n        });\n    };\n    FloatSliderModel.prototype.initialize = function (attributes, options) {\n        _super.prototype.initialize.call(this, attributes, options);\n        this.on('change:readout_format', this.update_readout_format, this);\n        this.update_readout_format();\n    };\n    FloatSliderModel.prototype.update_readout_format = function () {\n        this.readout_formatter = format(this.get('readout_format'));\n    };\n    return FloatSliderModel;\n}(BoundedFloatModel));\nexport { FloatSliderModel };\nvar FloatLogSliderModel = /** @class */ (function (_super) {\n    __extends(FloatLogSliderModel, _super);\n    function FloatLogSliderModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    FloatLogSliderModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'FloatLogSliderModel',\n            _view_name: 'FloatLogSliderView',\n            step: 0.1,\n            orientation: 'horizontal',\n            _range: false,\n            readout: true,\n            readout_format: '.3g',\n            slider_color: null,\n            continuous_update: true,\n            disabled: false,\n            base: 10.,\n            value: 1.0,\n            min: 0,\n            max: 4\n        });\n    };\n    FloatLogSliderModel.prototype.initialize = function (attributes, options) {\n        _super.prototype.initialize.call(this, attributes, options);\n        this.on('change:readout_format', this.update_readout_format, this);\n        this.update_readout_format();\n    };\n    FloatLogSliderModel.prototype.update_readout_format = function () {\n        this.readout_formatter = format(this.get('readout_format'));\n    };\n    return FloatLogSliderModel;\n}(BoundedFloatModel));\nexport { FloatLogSliderModel };\nvar FloatRangeSliderModel = /** @class */ (function (_super) {\n    __extends(FloatRangeSliderModel, _super);\n    function FloatRangeSliderModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    return FloatRangeSliderModel;\n}(FloatSliderModel));\nexport { FloatRangeSliderModel };\nvar FloatSliderView = /** @class */ (function (_super) {\n    __extends(FloatSliderView, _super);\n    function FloatSliderView() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._parse_value = parseFloat;\n        return _this;\n    }\n    /**\n     * Validate the value of the slider before sending it to the back-end\n     * and applying it to the other views on the page.\n     */\n    FloatSliderView.prototype._validate_slide_value = function (x) {\n        return x;\n    };\n    return FloatSliderView;\n}(IntSliderView));\nexport { FloatSliderView };\nvar FloatLogSliderView = /** @class */ (function (_super) {\n    __extends(FloatLogSliderView, _super);\n    function FloatLogSliderView() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._parse_value = parseFloat;\n        return _this;\n    }\n    FloatLogSliderView.prototype.update = function (options) {\n        _super.prototype.update.call(this, options);\n        var min = this.model.get('min');\n        var max = this.model.get('max');\n        var value = this.model.get('value');\n        var base = this.model.get('base');\n        var log_value = Math.log(value) / Math.log(base);\n        if (log_value > max) {\n            log_value = max;\n        }\n        else if (log_value < min) {\n            log_value = min;\n        }\n        this.$slider.slider('option', 'value', log_value);\n        this.readout.textContent = this.valueToString(value);\n        if (this.model.get('value') !== value) {\n            this.model.set('value', value, { updated_view: this });\n            this.touch();\n        }\n    };\n    /**\n     * Write value to a string\n     */\n    FloatLogSliderView.prototype.valueToString = function (value) {\n        var format = this.model.readout_formatter;\n        return format(value);\n    };\n    /**\n     * Parse value from a string\n     */\n    FloatLogSliderView.prototype.stringToValue = function (text) {\n        return this._parse_value(text);\n    };\n    /**\n     * this handles the entry of text into the contentEditable label first, the\n     * value is checked if it contains a parseable value then it is clamped\n     * within the min-max range of the slider finally, the model is updated if\n     * the value is to be changed\n     *\n     * if any of these conditions are not met, the text is reset\n     */\n    FloatLogSliderView.prototype.handleTextChange = function () {\n        var value = this.stringToValue(this.readout.textContent);\n        var vmin = this.model.get('min');\n        var vmax = this.model.get('max');\n        var base = this.model.get('base');\n        if (isNaN(value)) {\n            this.readout.textContent = this.valueToString(this.model.get('value'));\n        }\n        else {\n            value = Math.max(Math.min(value, Math.pow(base, vmax)), Math.pow(base, vmin));\n            if (value !== this.model.get('value')) {\n                this.readout.textContent = this.valueToString(value);\n                this.model.set('value', value, { updated_view: this });\n                this.touch();\n            }\n            else {\n                this.readout.textContent = this.valueToString(this.model.get('value'));\n            }\n        }\n    };\n    /**\n     * Called when the slider value is changing.\n     */\n    FloatLogSliderView.prototype.handleSliderChange = function (e, ui) {\n        var base = this.model.get('base');\n        var actual_value = Math.pow(base, this._validate_slide_value(ui.value));\n        this.readout.textContent = this.valueToString(actual_value);\n        // Only persist the value while sliding if the continuous_update\n        // trait is set to true.\n        if (this.model.get('continuous_update')) {\n            this.handleSliderChanged(e, ui);\n        }\n    };\n    /**\n     * Called when the slider value has changed.\n     *\n     * Calling model.set will trigger all of the other views of the\n     * model to update.\n     */\n    FloatLogSliderView.prototype.handleSliderChanged = function (e, ui) {\n        var base = this.model.get('base');\n        var actual_value = Math.pow(base, this._validate_slide_value(ui.value));\n        this.model.set('value', actual_value, { updated_view: this });\n        this.touch();\n    };\n    FloatLogSliderView.prototype._validate_slide_value = function (x) {\n        return x;\n    };\n    return FloatLogSliderView;\n}(BaseIntSliderView));\nexport { FloatLogSliderView };\nvar FloatRangeSliderView = /** @class */ (function (_super) {\n    __extends(FloatRangeSliderView, _super);\n    function FloatRangeSliderView() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._parse_value = parseFloat;\n        // matches: whitespace?, float, whitespace?, (hyphen, colon, or en-dash), whitespace?, float\n        _this._range_regex = /^\\s*([+-]?(?:\\d*\\.?\\d+|\\d+\\.)(?:[eE][-:]?\\d+)?)\\s*[-:–]\\s*([+-]?(?:\\d*\\.?\\d+|\\d+\\.)(?:[eE][+-]?\\d+)?)/;\n        return _this;\n    }\n    /**\n     * Validate the value of the slider before sending it to the back-end\n     * and applying it to the other views on the page.\n     */\n    FloatRangeSliderView.prototype._validate_slide_value = function (x) {\n        return x;\n    };\n    return FloatRangeSliderView;\n}(IntRangeSliderView));\nexport { FloatRangeSliderView };\nvar FloatTextModel = /** @class */ (function (_super) {\n    __extends(FloatTextModel, _super);\n    function FloatTextModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    FloatTextModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'FloatTextModel',\n            _view_name: 'FloatTextView',\n            disabled: false,\n            continuous_update: false,\n        });\n    };\n    return FloatTextModel;\n}(FloatModel));\nexport { FloatTextModel };\nvar BoundedFloatTextModel = /** @class */ (function (_super) {\n    __extends(BoundedFloatTextModel, _super);\n    function BoundedFloatTextModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    BoundedFloatTextModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'BoundedFloatTextModel',\n            _view_name: 'FloatTextView',\n            disabled: false,\n            continuous_update: false,\n            step: 0.1\n        });\n    };\n    return BoundedFloatTextModel;\n}(BoundedFloatModel));\nexport { BoundedFloatTextModel };\nvar FloatTextView = /** @class */ (function (_super) {\n    __extends(FloatTextView, _super);\n    function FloatTextView() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._parse_value = parseFloat;\n        _this._default_step = 'any';\n        return _this;\n    }\n    /**\n     * Handle key press\n     */\n    FloatTextView.prototype.handleKeypress = function (e) {\n        // Overwrite IntTextView's handleKeypress\n        // which prevents decimal points.\n        e.stopPropagation();\n    };\n    /**\n     * Handle key up\n     */\n    FloatTextView.prototype.handleKeyUp = function (e) {\n        // Overwrite IntTextView's handleKeyUp\n        // which prevents decimal points.\n    };\n    return FloatTextView;\n}(IntTextView));\nexport { FloatTextView };\nvar FloatProgressModel = /** @class */ (function (_super) {\n    __extends(FloatProgressModel, _super);\n    function FloatProgressModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    FloatProgressModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'FloatProgressModel',\n            _view_name: 'ProgressView',\n            orientation: 'horizontal',\n            bar_style: '',\n            style: null\n        });\n    };\n    return FloatProgressModel;\n}(BoundedFloatModel));\nexport { FloatProgressModel };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { CoreDOMWidgetModel } from './widget_core';\nimport { DOMWidgetView, unpack_models, ViewList, JupyterPhosphorPanelWidget } from '@jupyter-widgets/base';\nimport { Widget, Panel } from '@lumino/widgets';\nimport { ArrayExt } from '@lumino/algorithm';\nimport * as _ from 'underscore';\nimport * as utils from './utils';\nimport $ from 'jquery';\nvar ControllerButtonModel = /** @class */ (function (_super) {\n    __extends(ControllerButtonModel, _super);\n    function ControllerButtonModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ControllerButtonModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'ControllerButtonModel',\n            _view_name: 'ControllerButtonView',\n            value: 0.0,\n            pressed: false\n        });\n    };\n    return ControllerButtonModel;\n}(CoreDOMWidgetModel));\nexport { ControllerButtonModel };\n/**\n * Very simple view for a gamepad button.\n */\nvar ControllerButtonView = /** @class */ (function (_super) {\n    __extends(ControllerButtonView, _super);\n    function ControllerButtonView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ControllerButtonView.prototype.render = function () {\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-controller-button');\n        this.el.style.width = 'fit-content';\n        this.support = document.createElement('div');\n        this.support.style.position = 'relative';\n        this.support.style.margin = '1px';\n        this.support.style.width = '16px';\n        this.support.style.height = '16px';\n        this.support.style.border = '1px solid black';\n        this.support.style.background = 'lightgray';\n        this.el.appendChild(this.support);\n        this.bar = document.createElement('div');\n        this.bar.style.position = 'absolute';\n        this.bar.style.width = '100%';\n        this.bar.style.bottom = '0px';\n        this.bar.style.background = 'gray';\n        this.support.appendChild(this.bar);\n        this.update();\n        this.label = document.createElement('div');\n        this.label.textContent = this.model.get('description');\n        this.label.style.textAlign = 'center';\n        this.el.appendChild(this.label);\n    };\n    ControllerButtonView.prototype.update = function () {\n        this.bar.style.height = (100 * this.model.get('value')) + '%';\n    };\n    return ControllerButtonView;\n}(DOMWidgetView));\nexport { ControllerButtonView };\nvar ControllerAxisModel = /** @class */ (function (_super) {\n    __extends(ControllerAxisModel, _super);\n    function ControllerAxisModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ControllerAxisModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'ControllerAxisModel',\n            _view_name: 'ControllerAxisView',\n            value: 0.0\n        });\n    };\n    return ControllerAxisModel;\n}(CoreDOMWidgetModel));\nexport { ControllerAxisModel };\n/**\n * Very simple view for a gamepad axis.\n */\nvar ControllerAxisView = /** @class */ (function (_super) {\n    __extends(ControllerAxisView, _super);\n    function ControllerAxisView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ControllerAxisView.prototype.render = function () {\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-controller-axis');\n        this.el.style.width = '16px';\n        this.el.style.padding = '4px';\n        this.support = document.createElement('div');\n        this.support.style.position = 'relative';\n        this.support.style.margin = '1px';\n        this.support.style.width = '4px';\n        this.support.style.height = '64px';\n        this.support.style.border = '1px solid black';\n        this.support.style.background = 'lightgray';\n        this.bullet = document.createElement('div');\n        this.bullet.style.position = 'absolute';\n        this.bullet.style.margin = '-3px';\n        this.bullet.style.boxSizing = 'unset';\n        this.bullet.style.width = '10px';\n        this.bullet.style.height = '10px';\n        this.bullet.style.background = 'gray';\n        this.label = document.createElement('div');\n        this.label.textContent = this.model.get('description');\n        this.label.style.textAlign = 'center';\n        this.support.appendChild(this.bullet);\n        this.el.appendChild(this.support);\n        this.el.appendChild(this.label);\n        this.update();\n    };\n    ControllerAxisView.prototype.update = function () {\n        this.bullet.style.top = (50 * (this.model.get('value') + 1)) + '%';\n    };\n    return ControllerAxisView;\n}(DOMWidgetView));\nexport { ControllerAxisView };\nvar ControllerModel = /** @class */ (function (_super) {\n    __extends(ControllerModel, _super);\n    function ControllerModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ControllerModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'ControllerModel',\n            _view_name: 'ControllerView',\n            index: 0,\n            name: '',\n            mapping: '',\n            connected: false,\n            timestamp: 0,\n            buttons: [],\n            axes: []\n        });\n    };\n    ControllerModel.prototype.initialize = function (attributes, options) {\n        _super.prototype.initialize.call(this, attributes, options);\n        if (navigator.getGamepads === void 0) {\n            // Checks if the browser supports the gamepad API\n            this.readout = 'This browser does not support gamepads.';\n            console.error(this.readout);\n        }\n        else {\n            // Start the wait loop, and listen to updates of the only\n            // user-provided attribute, the gamepad index.\n            this.readout = 'Connect gamepad and press any button.';\n            if (this.get('connected')) {\n                // No need to re-create Button and Axis widgets, re-use\n                // the models provided by the backend which may already\n                // be wired to other things.\n                this.update_loop();\n            }\n            else {\n                // Wait for a gamepad to be connected.\n                this.wait_loop();\n            }\n        }\n    };\n    /**\n     * Waits for a gamepad to be connected at the provided index.\n     * Once one is connected, it will start the update loop, which\n     * populates the update of axes and button values.\n     */\n    ControllerModel.prototype.wait_loop = function () {\n        var index = this.get('index');\n        var pad = navigator.getGamepads()[index];\n        if (pad) {\n            var that_1 = this;\n            this.setup(pad).then(function (controls) {\n                that_1.set(controls);\n                that_1.save_changes();\n                window.requestAnimationFrame(that_1.update_loop.bind(that_1));\n            });\n        }\n        else {\n            window.requestAnimationFrame(this.wait_loop.bind(this));\n        }\n    };\n    /**\n     * Given a native gamepad object, returns a promise for a dictionary of\n     * controls, of the form\n     * {\n     *     buttons: list of Button models,\n     *     axes: list of Axis models,\n     * }\n     */\n    ControllerModel.prototype.setup = function (pad) {\n        // Set up the main gamepad attributes\n        this.set({\n            name: pad.id,\n            mapping: pad.mapping,\n            connected: pad.connected,\n            timestamp: pad.timestamp\n        });\n        // Create buttons and axes. When done, start the update loop\n        var that = this;\n        return utils.resolvePromisesDict({\n            buttons: Promise.all(pad.buttons.map(function (btn, index) {\n                return that._create_button_model(index);\n            })),\n            axes: Promise.all(pad.axes.map(function (axis, index) {\n                return that._create_axis_model(index);\n            })),\n        });\n    };\n    /**\n     * Update axes and buttons values, until the gamepad is disconnected.\n     * When the gamepad is disconnected, this.reset_gamepad is called.\n     */\n    ControllerModel.prototype.update_loop = function () {\n        var index = this.get('index');\n        var id = this.get('name');\n        var pad = navigator.getGamepads()[index];\n        if (pad && index === pad.index && id === pad.id) {\n            this.set({\n                timestamp: pad.timestamp,\n                connected: pad.connected\n            });\n            this.save_changes();\n            this.get('buttons').forEach(function (model, index) {\n                model.set({\n                    value: pad.buttons[index].value,\n                    pressed: pad.buttons[index].pressed\n                });\n                model.save_changes();\n            });\n            this.get('axes').forEach(function (model, index) {\n                model.set('value', pad.axes[index]);\n                model.save_changes();\n            });\n            window.requestAnimationFrame(this.update_loop.bind(this));\n        }\n        else {\n            this.reset_gamepad();\n        }\n    };\n    /**\n     * Resets the gamepad attributes, and start the wait_loop.\n     */\n    ControllerModel.prototype.reset_gamepad = function () {\n        this.get('buttons').forEach(function (button) {\n            button.close();\n        });\n        this.get('axes').forEach(function (axis) {\n            axis.close();\n        });\n        this.set({\n            name: '',\n            mapping: '',\n            connected: false,\n            timestamp: 0.0,\n            buttons: [],\n            axes: []\n        });\n        this.save_changes();\n        window.requestAnimationFrame(this.wait_loop.bind(this));\n    };\n    /**\n     * Creates a gamepad button widget.\n     */\n    ControllerModel.prototype._create_button_model = function (index) {\n        return this.widget_manager.new_widget({\n            model_name: 'ControllerButtonModel',\n            model_module: '@jupyter-widgets/controls',\n            model_module_version: this.get('_model_module_version'),\n            view_name: 'ControllerButtonView',\n            view_module: '@jupyter-widgets/controls',\n            view_module_version: this.get('_view_module_version'),\n        }).then(function (model) {\n            model.set('description', index);\n            return model;\n        });\n    };\n    /**\n     * Creates a gamepad axis widget.\n     */\n    ControllerModel.prototype._create_axis_model = function (index) {\n        return this.widget_manager.new_widget({\n            model_name: 'ControllerAxisModel',\n            model_module: '@jupyter-widgets/controls',\n            model_module_version: this.get('_model_module_version'),\n            view_name: 'ControllerAxisView',\n            view_module: '@jupyter-widgets/controls',\n            view_module_version: this.get('_view_module_version'),\n        }).then(function (model) {\n            model.set('description', index);\n            return model;\n        });\n    };\n    ControllerModel.serializers = __assign(__assign({}, CoreDOMWidgetModel.serializers), { buttons: { deserialize: unpack_models }, axes: { deserialize: unpack_models } });\n    return ControllerModel;\n}(CoreDOMWidgetModel));\nexport { ControllerModel };\n/**\n * A simple view for a gamepad.\n */\nvar ControllerView = /** @class */ (function (_super) {\n    __extends(ControllerView, _super);\n    function ControllerView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ControllerView.prototype._createElement = function (tagName) {\n        this.pWidget = new JupyterPhosphorPanelWidget({ view: this });\n        return this.pWidget.node;\n    };\n    ControllerView.prototype._setElement = function (el) {\n        if (this.el || el !== this.pWidget.node) {\n            // Boxes don't allow setting the element beyond the initial creation.\n            throw new Error('Cannot reset the DOM element.');\n        }\n        this.el = this.pWidget.node;\n        this.$el = $(this.pWidget.node);\n    };\n    ControllerView.prototype.initialize = function (parameters) {\n        _super.prototype.initialize.call(this, parameters);\n        this.button_views = new ViewList(this.add_button, null, this);\n        this.listenTo(this.model, 'change:buttons', function (model, value) {\n            this.button_views.update(value);\n        });\n        this.axis_views = new ViewList(this.add_axis, null, this);\n        this.listenTo(this.model, 'change:axes', function (model, value) {\n            this.axis_views.update(value);\n        });\n        this.listenTo(this.model, 'change:name', this.update_label);\n    };\n    ControllerView.prototype.render = function () {\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-controller');\n        this.label = document.createElement('div');\n        this.el.appendChild(this.label);\n        this.axis_box = new Panel();\n        this.axis_box.node.style.display = 'flex';\n        this.pWidget.addWidget(this.axis_box);\n        this.button_box = new Panel();\n        this.button_box.node.style.display = 'flex';\n        this.pWidget.addWidget(this.button_box);\n        this.button_views.update(this.model.get('buttons'));\n        this.axis_views.update(this.model.get('axes'));\n        this.update_label();\n    };\n    ControllerView.prototype.update_label = function () {\n        this.label.textContent = this.model.get('name') || this.model.readout;\n    };\n    ControllerView.prototype.add_button = function (model) {\n        var _this = this;\n        // we insert a dummy element so the order is preserved when we add\n        // the rendered content later.\n        var dummy = new Widget();\n        this.button_box.addWidget(dummy);\n        return this.create_child_view(model).then(function (view) {\n            // replace the dummy widget with the new one.\n            var i = ArrayExt.firstIndexOf(_this.button_box.widgets, dummy);\n            _this.button_box.insertWidget(i, view.pWidget);\n            dummy.dispose();\n            return view;\n        }).catch(utils.reject('Could not add child button view to controller', true));\n    };\n    ControllerView.prototype.add_axis = function (model) {\n        var _this = this;\n        // we insert a dummy element so the order is preserved when we add\n        // the rendered content later.\n        var dummy = new Widget();\n        this.axis_box.addWidget(dummy);\n        return this.create_child_view(model).then(function (view) {\n            // replace the dummy widget with the new one.\n            var i = ArrayExt.firstIndexOf(_this.axis_box.widgets, dummy);\n            _this.axis_box.insertWidget(i, view.pWidget);\n            dummy.dispose();\n            return view;\n        }).catch(utils.reject('Could not add child axis view to controller', true));\n    };\n    ControllerView.prototype.remove = function () {\n        _super.prototype.remove.call(this);\n        this.button_views.remove();\n        this.axis_views.remove();\n    };\n    return ControllerView;\n}(DOMWidgetView));\nexport { ControllerView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { CoreDescriptionModel, } from './widget_core';\nimport { DescriptionView, DescriptionStyleModel } from './widget_description';\nimport { uuid } from './utils';\nimport * as _ from 'underscore';\nimport * as utils from './utils';\nimport $ from 'jquery';\nvar SelectionModel = /** @class */ (function (_super) {\n    __extends(SelectionModel, _super);\n    function SelectionModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    SelectionModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'SelectionModel', index: '', _options_labels: [], disabled: false });\n    };\n    return SelectionModel;\n}(CoreDescriptionModel));\nexport { SelectionModel };\nvar DropdownModel = /** @class */ (function (_super) {\n    __extends(DropdownModel, _super);\n    function DropdownModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    DropdownModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'DropdownModel', _view_name: 'DropdownView', button_style: '' });\n    };\n    return DropdownModel;\n}(SelectionModel));\nexport { DropdownModel };\n// TODO: Make a phosphor dropdown control, wrapped in DropdownView. Also, fix\n// bugs in keyboard handling. See\n// https://github.com/jupyter-widgets/ipywidgets/issues/1055 and\n// https://github.com/jupyter-widgets/ipywidgets/issues/1049\n// For now, we subclass SelectView to provide DropdownView\n// For the old code, see commit f68bfbc566f3a78a8f3350b438db8ed523ce3642\nvar DropdownView = /** @class */ (function (_super) {\n    __extends(DropdownView, _super);\n    function DropdownView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Public constructor.\n     */\n    DropdownView.prototype.initialize = function (parameters) {\n        var _this = this;\n        _super.prototype.initialize.call(this, parameters);\n        this.listenTo(this.model, 'change:_options_labels', function () { return _this._updateOptions(); });\n    };\n    /**\n     * Called when view is rendered.\n     */\n    DropdownView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-dropdown');\n        this.listbox = document.createElement('select');\n        this.listbox.id = this.label.htmlFor = uuid();\n        this.el.appendChild(this.listbox);\n        this._updateOptions();\n        this.update();\n    };\n    /**\n     * Update the contents of this view\n     */\n    DropdownView.prototype.update = function () {\n        // Disable listbox if needed\n        this.listbox.disabled = this.model.get('disabled');\n        // Select the correct element\n        var index = this.model.get('index');\n        this.listbox.selectedIndex = index === null ? -1 : index;\n        return _super.prototype.update.call(this);\n    };\n    DropdownView.prototype._updateOptions = function () {\n        this.listbox.textContent = '';\n        var items = this.model.get('_options_labels');\n        for (var i = 0; i < items.length; i++) {\n            var item = items[i];\n            var option = document.createElement('option');\n            option.textContent = item.replace(/ /g, '\\xa0'); // space -> &nbsp;\n            option.setAttribute('data-value', encodeURIComponent(item));\n            option.value = item;\n            this.listbox.appendChild(option);\n        }\n    };\n    DropdownView.prototype.events = function () {\n        return {\n            'change select': '_handle_change'\n        };\n    };\n    /**\n     * Handle when a new value is selected.\n     */\n    DropdownView.prototype._handle_change = function () {\n        this.model.set('index', this.listbox.selectedIndex === -1 ? null : this.listbox.selectedIndex);\n        this.touch();\n    };\n    return DropdownView;\n}(DescriptionView));\nexport { DropdownView };\nvar SelectModel = /** @class */ (function (_super) {\n    __extends(SelectModel, _super);\n    function SelectModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    SelectModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'SelectModel', _view_name: 'SelectView', rows: 5 });\n    };\n    return SelectModel;\n}(SelectionModel));\nexport { SelectModel };\nvar SelectView = /** @class */ (function (_super) {\n    __extends(SelectView, _super);\n    function SelectView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Public constructor.\n     */\n    SelectView.prototype.initialize = function (parameters) {\n        var _this = this;\n        _super.prototype.initialize.call(this, parameters);\n        this.listenTo(this.model, 'change:_options_labels', function () { return _this._updateOptions(); });\n        this.listenTo(this.model, 'change:index', function (model, value, options) { return _this.updateSelection(options); });\n        // Create listbox here so that subclasses can modify it before it is populated in render()\n        this.listbox = document.createElement('select');\n    };\n    /**\n     * Called when view is rendered.\n     */\n    SelectView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-select');\n        this.listbox.id = this.label.htmlFor = uuid();\n        this.el.appendChild(this.listbox);\n        this._updateOptions();\n        this.update();\n        this.updateSelection();\n    };\n    /**\n     * Update the contents of this view\n     */\n    SelectView.prototype.update = function () {\n        _super.prototype.update.call(this);\n        this.listbox.disabled = this.model.get('disabled');\n        var rows = this.model.get('rows');\n        if (rows === null) {\n            rows = '';\n        }\n        this.listbox.setAttribute('size', rows);\n    };\n    SelectView.prototype.updateSelection = function (options) {\n        if (options === void 0) { options = {}; }\n        if (options.updated_view === this) {\n            return;\n        }\n        var index = this.model.get('index');\n        this.listbox.selectedIndex = index === null ? -1 : index;\n    };\n    SelectView.prototype._updateOptions = function () {\n        this.listbox.textContent = '';\n        var items = this.model.get('_options_labels');\n        for (var i = 0; i < items.length; i++) {\n            var item = items[i];\n            var option = document.createElement('option');\n            option.textContent = item.replace(/ /g, '\\xa0'); // space -> &nbsp;\n            option.setAttribute('data-value', encodeURIComponent(item));\n            option.value = item;\n            this.listbox.appendChild(option);\n        }\n    };\n    SelectView.prototype.events = function () {\n        return {\n            'change select': '_handle_change'\n        };\n    };\n    /**\n     * Handle when a new value is selected.\n     */\n    SelectView.prototype._handle_change = function () {\n        this.model.set('index', this.listbox.selectedIndex, { updated_view: this });\n        this.touch();\n    };\n    return SelectView;\n}(DescriptionView));\nexport { SelectView };\nvar RadioButtonsModel = /** @class */ (function (_super) {\n    __extends(RadioButtonsModel, _super);\n    function RadioButtonsModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    RadioButtonsModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'RadioButtonsModel', _view_name: 'RadioButtonsView', tooltips: [], icons: [], button_style: '' });\n    };\n    return RadioButtonsModel;\n}(SelectionModel));\nexport { RadioButtonsModel };\nvar RadioButtonsView = /** @class */ (function (_super) {\n    __extends(RadioButtonsView, _super);\n    function RadioButtonsView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    RadioButtonsView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-radio');\n        this.container = document.createElement('div');\n        this.el.appendChild(this.container);\n        this.container.classList.add('widget-radio-box');\n        this.update();\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed.  The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    RadioButtonsView.prototype.update = function (options) {\n        var view = this;\n        var items = this.model.get('_options_labels');\n        var radios = _.pluck(this.container.querySelectorAll('input[type=\"radio\"]'), 'value');\n        var stale = items.length != radios.length;\n        if (!stale) {\n            for (var i = 0, len = items.length; i < len; ++i) {\n                if (radios[i] !== items[i]) {\n                    stale = true;\n                    break;\n                }\n            }\n        }\n        if (stale && (options === undefined || options.updated_view !== this)) {\n            // Add items to the DOM.\n            this.container.textContent = '';\n            items.forEach(function (item, index) {\n                var label = document.createElement('label');\n                label.textContent = item;\n                view.container.appendChild(label);\n                var radio = document.createElement('input');\n                radio.setAttribute('type', 'radio');\n                radio.value = index.toString();\n                radio.setAttribute('data-value', encodeURIComponent(item));\n                label.appendChild(radio);\n            });\n        }\n        items.forEach(function (item, index) {\n            var item_query = 'input[data-value=\"' +\n                encodeURIComponent(item) + '\"]';\n            var radio = view.container.querySelectorAll(item_query);\n            if (radio.length > 0) {\n                var radio_el = radio[0];\n                radio_el.checked = view.model.get('index') === index;\n                radio_el.disabled = view.model.get('disabled');\n            }\n        });\n        // Schedule adjustPadding asynchronously to\n        // allow dom elements to be created properly\n        setTimeout(this.adjustPadding, 0, this);\n        return _super.prototype.update.call(this, options);\n    };\n    /**\n     * Adjust Padding to Multiple of Line Height\n     *\n     * Adjust margins so that the overall height\n     * is a multiple of a single line height.\n     *\n     * This widget needs it because radio options\n     * are spaced tighter than individual widgets\n     * yet we would like the full widget line up properly\n     * when displayed side-by-side with other widgets.\n     */\n    RadioButtonsView.prototype.adjustPadding = function (e) {\n        // Vertical margins on a widget\n        var elStyles = window.getComputedStyle(e.el);\n        var margins = parseInt(elStyles.marginTop, 10) + parseInt(elStyles.marginBottom, 10);\n        // Total spaces taken by a single-line widget\n        var lineHeight = e.label.offsetHeight + margins;\n        // Current adjustment value on this widget\n        var cStyles = window.getComputedStyle(e.container);\n        var containerMargin = parseInt(cStyles.marginBottom);\n        // How far we are off from a multiple of single windget lines\n        var diff = (e.el.offsetHeight + margins - containerMargin) % lineHeight;\n        // Apply the new adjustment\n        var extraMargin = diff == 0 ? 0 : (lineHeight - diff);\n        e.container.style.marginBottom = extraMargin + 'px';\n    };\n    RadioButtonsView.prototype.events = function () {\n        return {\n            'click input[type=\"radio\"]': '_handle_click'\n        };\n    };\n    /**\n     * Handle when a value is clicked.\n     *\n     * Calling model.set will trigger all of the other views of the\n     * model to update.\n     */\n    RadioButtonsView.prototype._handle_click = function (event) {\n        var target = event.target;\n        this.model.set('index', parseInt(target.value), { updated_view: this });\n        this.touch();\n    };\n    return RadioButtonsView;\n}(DescriptionView));\nexport { RadioButtonsView };\nvar ToggleButtonsStyleModel = /** @class */ (function (_super) {\n    __extends(ToggleButtonsStyleModel, _super);\n    function ToggleButtonsStyleModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ToggleButtonsStyleModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'ToggleButtonsStyleModel',\n        });\n    };\n    ToggleButtonsStyleModel.styleProperties = __assign(__assign({}, DescriptionStyleModel.styleProperties), { button_width: {\n            selector: '.widget-toggle-button',\n            attribute: 'width',\n            default: null\n        }, font_weight: {\n            selector: '.widget-toggle-button',\n            attribute: 'font-weight',\n            default: ''\n        } });\n    return ToggleButtonsStyleModel;\n}(DescriptionStyleModel));\nexport { ToggleButtonsStyleModel };\nvar ToggleButtonsModel = /** @class */ (function (_super) {\n    __extends(ToggleButtonsModel, _super);\n    function ToggleButtonsModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ToggleButtonsModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'ToggleButtonsModel', _view_name: 'ToggleButtonsView' });\n    };\n    return ToggleButtonsModel;\n}(SelectionModel));\nexport { ToggleButtonsModel };\nvar ToggleButtonsView = /** @class */ (function (_super) {\n    __extends(ToggleButtonsView, _super);\n    function ToggleButtonsView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ToggleButtonsView.prototype.initialize = function (options) {\n        this._css_state = {};\n        _super.prototype.initialize.call(this, options);\n        this.listenTo(this.model, 'change:button_style', this.update_button_style);\n    };\n    /**\n     * Called when view is rendered.\n     */\n    ToggleButtonsView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-toggle-buttons');\n        this.buttongroup = document.createElement('div');\n        this.el.appendChild(this.buttongroup);\n        this.update();\n        this.set_button_style();\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed.  The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    ToggleButtonsView.prototype.update = function (options) {\n        var view = this;\n        var items = this.model.get('_options_labels');\n        var icons = this.model.get('icons') || [];\n        var previous_icons = this.model.previous('icons') || [];\n        var previous_bstyle = ToggleButtonsView.classMap[this.model.previous('button_style')] || '';\n        var tooltips = view.model.get('tooltips') || [];\n        var disabled = this.model.get('disabled');\n        var buttons = this.buttongroup.querySelectorAll('button');\n        var values = _.pluck(buttons, 'value');\n        var stale = false;\n        for (var i = 0, len = items.length; i < len; ++i) {\n            if (values[i] !== items[i] || icons[i] !== previous_icons[i]) {\n                stale = true;\n                break;\n            }\n        }\n        if (stale && (options === undefined || options.updated_view !== this)) {\n            // Add items to the DOM.\n            this.buttongroup.textContent = '';\n            items.forEach(function (item, index) {\n                var item_html;\n                var empty = item.trim().length === 0 &&\n                    (!icons[index] || icons[index].trim().length === 0);\n                if (empty) {\n                    item_html = '&nbsp;';\n                }\n                else {\n                    item_html = utils.escape_html(item);\n                }\n                var icon = document.createElement('i');\n                var button = document.createElement('button');\n                if (icons[index]) {\n                    icon.className = 'fa fa-' + icons[index];\n                }\n                button.setAttribute('type', 'button');\n                button.className = 'widget-toggle-button jupyter-button';\n                if (previous_bstyle) {\n                    button.classList.add(previous_bstyle);\n                }\n                button.innerHTML = item_html;\n                button.setAttribute('data-value', encodeURIComponent(item));\n                button.setAttribute('value', index.toString());\n                button.appendChild(icon);\n                button.disabled = disabled;\n                if (tooltips[index]) {\n                    button.setAttribute('title', tooltips[index]);\n                }\n                view.update_style_traits(button);\n                view.buttongroup.appendChild(button);\n            });\n        }\n        // Select active button.\n        items.forEach(function (item, index) {\n            var item_query = '[data-value=\"' + encodeURIComponent(item) + '\"]';\n            var button = view.buttongroup.querySelector(item_query);\n            if (view.model.get('index') === index) {\n                button.classList.add('mod-active');\n            }\n            else {\n                button.classList.remove('mod-active');\n            }\n        });\n        this.stylePromise.then(function (style) {\n            if (style) {\n                style.style();\n            }\n        });\n        return _super.prototype.update.call(this, options);\n    };\n    ToggleButtonsView.prototype.update_style_traits = function (button) {\n        for (var name_1 in this._css_state) {\n            if (this._css_state.hasOwnProperty(name_1)) {\n                if (name_1 === 'margin') {\n                    this.buttongroup.style[name_1] = this._css_state[name_1];\n                }\n                else if (name_1 !== 'width') {\n                    if (button) {\n                        button.style[name_1] = this._css_state[name_1];\n                    }\n                    else {\n                        var buttons = this.buttongroup\n                            .querySelectorAll('button');\n                        if (buttons.length) {\n                            (buttons[0]).style[name_1] = this._css_state[name_1];\n                        }\n                    }\n                }\n            }\n        }\n    };\n    ToggleButtonsView.prototype.update_button_style = function () {\n        var buttons = this.buttongroup.querySelectorAll('button');\n        for (var i = 0; i < buttons.length; i++) {\n            this.update_mapped_classes(ToggleButtonsView.classMap, 'button_style', buttons[i]);\n        }\n    };\n    ToggleButtonsView.prototype.set_button_style = function () {\n        var buttons = this.buttongroup.querySelectorAll('button');\n        for (var i = 0; i < buttons.length; i++) {\n            this.set_mapped_classes(ToggleButtonsView.classMap, 'button_style', buttons[i]);\n        }\n    };\n    ToggleButtonsView.prototype.events = function () {\n        return {\n            'click button': '_handle_click'\n        };\n    };\n    /**\n     * Handle when a value is clicked.\n     *\n     * Calling model.set will trigger all of the other views of the\n     * model to update.\n     */\n    ToggleButtonsView.prototype._handle_click = function (event) {\n        var target = event.target;\n        this.model.set('index', parseInt(target.value, 10), { updated_view: this });\n        this.touch();\n        // We also send a clicked event, since the value is only set if it changed.\n        // See https://github.com/jupyter-widgets/ipywidgets/issues/763\n        this.send({ event: 'click' });\n    };\n    return ToggleButtonsView;\n}(DescriptionView));\nexport { ToggleButtonsView };\n(function (ToggleButtonsView) {\n    ToggleButtonsView.classMap = {\n        primary: ['mod-primary'],\n        success: ['mod-success'],\n        info: ['mod-info'],\n        warning: ['mod-warning'],\n        danger: ['mod-danger']\n    };\n})(ToggleButtonsView || (ToggleButtonsView = {}));\nvar SelectionSliderModel = /** @class */ (function (_super) {\n    __extends(SelectionSliderModel, _super);\n    function SelectionSliderModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    SelectionSliderModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'SelectionSliderModel', _view_name: 'SelectionSliderView', orientation: 'horizontal', readout: true, continuous_update: true });\n    };\n    return SelectionSliderModel;\n}(SelectionModel));\nexport { SelectionSliderModel };\nvar SelectionSliderView = /** @class */ (function (_super) {\n    __extends(SelectionSliderView, _super);\n    function SelectionSliderView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    SelectionSliderView.prototype.render = function () {\n        var _this = this;\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-hslider');\n        this.el.classList.add('widget-slider');\n        (this.$slider = $('<div />'))\n            .slider({\n            slide: this.handleSliderChange.bind(this),\n            stop: this.handleSliderChanged.bind(this)\n        })\n            .addClass('slider');\n        // Put the slider in a container\n        this.slider_container = document.createElement('div');\n        this.slider_container.classList.add('slider-container');\n        this.slider_container.appendChild(this.$slider[0]);\n        this.el.appendChild(this.slider_container);\n        this.readout = document.createElement('div');\n        this.el.appendChild(this.readout);\n        this.readout.classList.add('widget-readout');\n        this.readout.style.display = 'none';\n        this.listenTo(this.model, 'change:slider_color', function (sender, value) {\n            _this.$slider.find('a').css('background', value);\n        });\n        this.$slider.find('a').css('background', this.model.get('slider_color'));\n        // Set defaults.\n        this.update();\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed.  The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    SelectionSliderView.prototype.update = function (options) {\n        if (options === undefined || options.updated_view !== this) {\n            var labels = this.model.get('_options_labels');\n            var max = labels.length - 1;\n            var min = 0;\n            this.$slider.slider('option', 'step', 1);\n            this.$slider.slider('option', 'max', max);\n            this.$slider.slider('option', 'min', min);\n            // WORKAROUND FOR JQUERY SLIDER BUG.\n            // The horizontal position of the slider handle\n            // depends on the value of the slider at the time\n            // of orientation change.  Before applying the new\n            // workaround, we set the value to the minimum to\n            // make sure that the horizontal placement of the\n            // handle in the vertical slider is always\n            // consistent.\n            var orientation_1 = this.model.get('orientation');\n            this.$slider.slider('option', 'value', min);\n            this.$slider.slider('option', 'orientation', orientation_1);\n            var disabled = this.model.get('disabled');\n            this.$slider.slider('option', 'disabled', disabled);\n            if (disabled) {\n                this.readout.contentEditable = 'false';\n            }\n            else {\n                this.readout.contentEditable = 'true';\n            }\n            // Use the right CSS classes for vertical & horizontal sliders\n            if (orientation_1 === 'vertical') {\n                this.el.classList.remove('widget-hslider');\n                this.el.classList.remove('widget-inline-hbox');\n                this.el.classList.add('widget-vslider');\n                this.el.classList.add('widget-inline-vbox');\n            }\n            else {\n                this.el.classList.remove('widget-vslider');\n                this.el.classList.remove('widget-inline-vbox');\n                this.el.classList.add('widget-hslider');\n                this.el.classList.add('widget-inline-hbox');\n            }\n            var readout = this.model.get('readout');\n            if (readout) {\n                // this.$readout.show();\n                this.readout.style.display = '';\n            }\n            else {\n                // this.$readout.hide();\n                this.readout.style.display = 'none';\n            }\n            this.updateSelection();\n        }\n        return _super.prototype.update.call(this, options);\n    };\n    SelectionSliderView.prototype.events = function () {\n        return {\n            'slide': 'handleSliderChange',\n            'slidestop': 'handleSliderChanged'\n        };\n    };\n    SelectionSliderView.prototype.updateSelection = function () {\n        var index = this.model.get('index');\n        this.$slider.slider('option', 'value', index);\n        this.updateReadout(index);\n    };\n    SelectionSliderView.prototype.updateReadout = function (index) {\n        var value = this.model.get('_options_labels')[index];\n        this.readout.textContent = value;\n    };\n    /**\n     * Called when the slider value is changing.\n     */\n    SelectionSliderView.prototype.handleSliderChange = function (e, ui) {\n        this.updateReadout(ui.value);\n        // Only persist the value while sliding if the continuous_update\n        // trait is set to true.\n        if (this.model.get('continuous_update')) {\n            this.handleSliderChanged(e, ui);\n        }\n    };\n    /**\n     * Called when the slider value has changed.\n     *\n     * Calling model.set will trigger all of the other views of the\n     * model to update.\n     */\n    SelectionSliderView.prototype.handleSliderChanged = function (e, ui) {\n        this.updateReadout(ui.value);\n        this.model.set('index', ui.value, { updated_view: this });\n        this.touch();\n    };\n    return SelectionSliderView;\n}(DescriptionView));\nexport { SelectionSliderView };\nvar MultipleSelectionModel = /** @class */ (function (_super) {\n    __extends(MultipleSelectionModel, _super);\n    function MultipleSelectionModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    MultipleSelectionModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'MultipleSelectionModel' });\n    };\n    return MultipleSelectionModel;\n}(SelectionModel));\nexport { MultipleSelectionModel };\nvar SelectMultipleModel = /** @class */ (function (_super) {\n    __extends(SelectMultipleModel, _super);\n    function SelectMultipleModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    SelectMultipleModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'SelectMultipleModel', _view_name: 'SelectMultipleView', rows: null });\n    };\n    return SelectMultipleModel;\n}(MultipleSelectionModel));\nexport { SelectMultipleModel };\nvar SelectMultipleView = /** @class */ (function (_super) {\n    __extends(SelectMultipleView, _super);\n    function SelectMultipleView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Public constructor.\n     */\n    SelectMultipleView.prototype.initialize = function (parameters) {\n        _super.prototype.initialize.call(this, parameters);\n        this.listbox.multiple = true;\n    };\n    /**\n     * Called when view is rendered.\n     */\n    SelectMultipleView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('widget-select-multiple');\n    };\n    SelectMultipleView.prototype.updateSelection = function (options) {\n        if (options === void 0) { options = {}; }\n        if (options.updated_view === this) {\n            return;\n        }\n        var selected = this.model.get('index') || [];\n        var listboxOptions = this.listbox.options;\n        // Clear the selection\n        this.listbox.selectedIndex = -1;\n        // Select the appropriate options\n        selected.forEach(function (i) {\n            listboxOptions[i].selected = true;\n        });\n    };\n    /**\n     * Handle when a new value is selected.\n     */\n    SelectMultipleView.prototype._handle_change = function () {\n        var index = Array.prototype.map\n            .call(this.listbox.selectedOptions || [], function (option) {\n            return option.index;\n        });\n        this.model.set('index', index, { updated_view: this });\n        this.touch();\n    };\n    return SelectMultipleView;\n}(SelectView));\nexport { SelectMultipleView };\nvar SelectionRangeSliderModel = /** @class */ (function (_super) {\n    __extends(SelectionRangeSliderModel, _super);\n    function SelectionRangeSliderModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    SelectionRangeSliderModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'SelectionSliderModel', _view_name: 'SelectionSliderView', orientation: 'horizontal', readout: true, continuous_update: true });\n    };\n    return SelectionRangeSliderModel;\n}(MultipleSelectionModel));\nexport { SelectionRangeSliderModel };\nvar SelectionRangeSliderView = /** @class */ (function (_super) {\n    __extends(SelectionRangeSliderView, _super);\n    function SelectionRangeSliderView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    SelectionRangeSliderView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.$slider.slider('option', 'range', true);\n    };\n    SelectionRangeSliderView.prototype.updateSelection = function () {\n        var index = this.model.get('index');\n        this.$slider.slider('option', 'values', index.slice());\n        this.updateReadout(index);\n    };\n    SelectionRangeSliderView.prototype.updateReadout = function (index) {\n        var labels = this.model.get('_options_labels');\n        var minValue = labels[index[0]];\n        var maxValue = labels[index[1]];\n        this.readout.textContent = minValue + \"-\" + maxValue;\n    };\n    /**\n     * Called when the slider value is changing.\n     */\n    SelectionRangeSliderView.prototype.handleSliderChange = function (e, ui) {\n        this.updateReadout(ui.values);\n        // Only persist the value while sliding if the continuous_update\n        // trait is set to true.\n        if (this.model.get('continuous_update')) {\n            this.handleSliderChanged(e, ui);\n        }\n    };\n    /**\n     * Called when the slider value has changed.\n     *\n     * Calling model.set will trigger all of the other views of the\n     * model to update.\n     */\n    SelectionRangeSliderView.prototype.handleSliderChanged = function (e, ui) {\n        // The jqueryui documentation indicates ui.values doesn't exist on the slidestop event,\n        // but it appears that it actually does: https://github.com/jquery/jquery-ui/blob/ae31f2b3b478975f70526bdf3299464b9afa8bb1/ui/widgets/slider.js#L313\n        this.updateReadout(ui.values);\n        this.model.set('index', ui.values.slice(), { updated_view: this });\n        this.touch();\n    };\n    return SelectionRangeSliderView;\n}(SelectionSliderView));\nexport { SelectionRangeSliderView };\n","/* This file has code derived from PhosphorJS. The license for this PhosphorJS code is:\n\nCopyright (c) 2014-2017, PhosphorJS Contributors\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions are met:\n\n* Redistributions of source code must retain the above copyright notice, this\n  list of conditions and the following disclaimer.\n\n* Redistributions in binary form must reproduce the above copyright notice,\n  this list of conditions and the following disclaimer in the documentation\n  and/or other materials provided with the distribution.\n\n* Neither the name of the copyright holder nor the names of its\n  contributors may be used to endorse or promote products derived from\n  this software without specific prior written permission.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\nAND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\nIMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\nDISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\nFOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\nDAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\nSERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\nCAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\nOR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\nOF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n\n*/\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nimport { MessageLoop } from '@lumino/messaging';\nimport { Signal } from '@lumino/signaling';\nimport { Platform } from '@lumino/domutils';\nimport { Panel, PanelLayout, TabBar, Widget } from '@lumino/widgets';\n/**\n * A panel where visible widgets are stacked atop one another.\n *\n * #### Notes\n * This class provides a convenience wrapper around a [[PanelLayout]].\n */\nvar EventedPanel = /** @class */ (function (_super) {\n    __extends(EventedPanel, _super);\n    function EventedPanel() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this._widgetRemoved = new Signal(_this);\n        return _this;\n    }\n    Object.defineProperty(EventedPanel.prototype, \"widgetRemoved\", {\n        /**\n         * A signal emitted when a widget is removed from the panel.\n         */\n        get: function () {\n            return this._widgetRemoved;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * A message handler invoked on a `'child-removed'` message.\n     */\n    EventedPanel.prototype.onChildRemoved = function (msg) {\n        this._widgetRemoved.emit(msg.child);\n    };\n    return EventedPanel;\n}(Panel));\nexport { EventedPanel };\n/**\n * A widget which combines a `TabBar` and a `EventedPanel`.\n *\n * #### Notes\n * This is a simple panel which handles the common case of a tab bar\n * placed next to a content area. The selected tab controls the widget\n * which is shown in the content area.\n *\n * For use cases which require more control than is provided by this\n * panel, the `TabBar` widget may be used independently.\n *\n * TODO: Support setting the direction??\n */\nvar TabPanel = /** @class */ (function (_super) {\n    __extends(TabPanel, _super);\n    /**\n     * Construct a new tab panel.\n     *\n     * @param options - The options for initializing the tab panel.\n     */\n    function TabPanel(options) {\n        if (options === void 0) { options = {}; }\n        var _this = _super.call(this) || this;\n        _this._currentChanged = new Signal(_this);\n        _this.addClass('p-TabPanel');\n        // Create the tab bar and contents panel.\n        _this.tabBar = new TabBar(options);\n        _this.tabBar.addClass('p-TabPanel-tabBar');\n        _this.tabContents = new EventedPanel();\n        _this.tabContents.addClass('p-TabPanel-tabContents');\n        // Connect the tab bar signal handlers.\n        _this.tabBar.tabMoved.connect(_this._onTabMoved, _this);\n        _this.tabBar.currentChanged.connect(_this._onCurrentChanged, _this);\n        _this.tabBar.tabCloseRequested.connect(_this._onTabCloseRequested, _this);\n        _this.tabBar.tabActivateRequested.connect(_this._onTabActivateRequested, _this);\n        // Connect the evented panel signal handlers.\n        _this.tabContents.widgetRemoved.connect(_this._onWidgetRemoved, _this);\n        // Create the layout.\n        var layout = new PanelLayout();\n        // Add the child widgets to the layout.\n        layout.addWidget(_this.tabBar);\n        layout.addWidget(_this.tabContents);\n        // Install the layout on the tab panel.\n        _this.layout = layout;\n        return _this;\n    }\n    Object.defineProperty(TabPanel.prototype, \"currentChanged\", {\n        /**\n         * A signal emitted when the current tab is changed.\n         *\n         * #### Notes\n         * This signal is emitted when the currently selected tab is changed\n         * either through user or programmatic interaction.\n         *\n         * Notably, this signal is not emitted when the index of the current\n         * tab changes due to tabs being inserted, removed, or moved. It is\n         * only emitted when the actual current tab node is changed.\n         */\n        get: function () {\n            return this._currentChanged;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabPanel.prototype, \"currentIndex\", {\n        /**\n         * Get the index of the currently selected tab.\n         *\n         * #### Notes\n         * This will be `null` if no tab is selected.\n         */\n        get: function () {\n            var currentIndex = this.tabBar.currentIndex;\n            // Phosphor tab bars have an index of -1 if no tab is selected\n            return (currentIndex === -1 ? null : currentIndex);\n        },\n        /**\n         * Set the index of the currently selected tab.\n         *\n         * #### Notes\n         * If the index is out of range, it will be set to `null`.\n         */\n        set: function (value) {\n            this.tabBar.currentIndex = (value === null ? -1 : value);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabPanel.prototype, \"currentWidget\", {\n        /**\n         * Get the currently selected widget.\n         *\n         * #### Notes\n         * This will be `null` if there is no selected tab.\n         */\n        get: function () {\n            var title = this.tabBar.currentTitle;\n            return title ? title.owner : null;\n        },\n        /**\n         * Set the currently selected widget.\n         *\n         * #### Notes\n         * If the widget is not in the panel, it will be set to `null`.\n         */\n        set: function (value) {\n            this.tabBar.currentTitle = value ? value.title : null;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabPanel.prototype, \"tabsMovable\", {\n        /**\n         * Get the whether the tabs are movable by the user.\n         *\n         * #### Notes\n         * Tabs can always be moved programmatically.\n         */\n        get: function () {\n            return this.tabBar.tabsMovable;\n        },\n        /**\n         * Set the whether the tabs are movable by the user.\n         *\n         * #### Notes\n         * Tabs can always be moved programmatically.\n         */\n        set: function (value) {\n            this.tabBar.tabsMovable = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(TabPanel.prototype, \"widgets\", {\n        /**\n         * A read-only array of the widgets in the panel.\n         */\n        get: function () {\n            return this.tabContents.widgets;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Add a widget to the end of the tab panel.\n     *\n     * @param widget - The widget to add to the tab panel.\n     *\n     * #### Notes\n     * If the widget is already contained in the panel, it will be moved.\n     *\n     * The widget's `title` is used to populate the tab.\n     */\n    TabPanel.prototype.addWidget = function (widget) {\n        this.insertWidget(this.widgets.length, widget);\n    };\n    /**\n     * Insert a widget into the tab panel at a specified index.\n     *\n     * @param index - The index at which to insert the widget.\n     *\n     * @param widget - The widget to insert into to the tab panel.\n     *\n     * #### Notes\n     * If the widget is already contained in the panel, it will be moved.\n     *\n     * The widget's `title` is used to populate the tab.\n     */\n    TabPanel.prototype.insertWidget = function (index, widget) {\n        if (widget !== this.currentWidget) {\n            widget.hide();\n        }\n        this.tabContents.insertWidget(index, widget);\n        this.tabBar.insertTab(index, widget.title);\n    };\n    /**\n     * Handle the `currentChanged` signal from the tab bar.\n     */\n    TabPanel.prototype._onCurrentChanged = function (sender, args) {\n        // Extract the previous and current title from the args.\n        var previousIndex = args.previousIndex, previousTitle = args.previousTitle, currentIndex = args.currentIndex, currentTitle = args.currentTitle;\n        // Extract the widgets from the titles.\n        var previousWidget = previousTitle ? previousTitle.owner : null;\n        var currentWidget = currentTitle ? currentTitle.owner : null;\n        // Hide the previous widget.\n        if (previousWidget) {\n            previousWidget.hide();\n        }\n        // Show the current widget.\n        if (currentWidget) {\n            currentWidget.show();\n        }\n        // Emit the `currentChanged` signal for the tab panel.\n        this._currentChanged.emit({\n            previousIndex: previousIndex, previousWidget: previousWidget, currentIndex: currentIndex, currentWidget: currentWidget\n        });\n        // Flush the message loop on IE and Edge to prevent flicker.\n        if (Platform.IS_EDGE || Platform.IS_IE) {\n            MessageLoop.flush();\n        }\n    };\n    /**\n     * Handle the `tabActivateRequested` signal from the tab bar.\n     */\n    TabPanel.prototype._onTabActivateRequested = function (sender, args) {\n        args.title.owner.activate();\n    };\n    /**\n     * Handle the `tabCloseRequested` signal from the tab bar.\n     */\n    TabPanel.prototype._onTabCloseRequested = function (sender, args) {\n        args.title.owner.close();\n    };\n    /**\n     * Handle the `tabMoved` signal from the tab bar.\n     */\n    TabPanel.prototype._onTabMoved = function (sender, args) {\n        this.tabContents.insertWidget(args.toIndex, args.title.owner);\n    };\n    /**\n     * Handle the `widgetRemoved` signal from the stacked panel.\n     */\n    TabPanel.prototype._onWidgetRemoved = function (sender, widget) {\n        this.tabBar.removeTab(widget.title);\n    };\n    return TabPanel;\n}(Widget));\nexport { TabPanel };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n/**\n * A variety of convenience methods for maintaining a current selection\n */\nimport { ArrayExt } from '@lumino/algorithm';\nimport { Signal } from '@lumino/signaling';\nvar Selection = /** @class */ (function () {\n    function Selection(sequence, options) {\n        if (options === void 0) { options = {}; }\n        this._array = null;\n        this._value = null;\n        this._previousValue = null;\n        this._selectionChanged = new Signal(this);\n        this._array = sequence;\n        this._insertBehavior = options.insertBehavior || 'select-item-if-needed';\n        this._removeBehavior = options.removeBehavior || 'select-item-after';\n    }\n    Object.defineProperty(Selection.prototype, \"selectionChanged\", {\n        /**\n         * A signal emitted when the current item is changed.\n         *\n         * #### Notes\n         * This signal is emitted when the currently selected item is changed either\n         * through user or programmatic interaction.\n         *\n         * Notably, this signal is not emitted when the index of the current item\n         * changes due to other items being inserted, removed, or moved, but the\n         * current item remains the same. It is only emitted when the actual current\n         * item is changed.\n         */\n        get: function () {\n            return this._selectionChanged;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Adjust for setting an item.\n     *\n     * This should be called *after* the set.\n     *\n     * @param index - The index set.\n     * @param oldValue - The old value at the index.\n     */\n    Selection.prototype.adjustSelectionForSet = function (index) {\n        // We just need to send a signal if the currentValue changed.\n        // Get the current index and value.\n        var pi = this.index;\n        var pv = this.value;\n        // Exit early if this doesn't affect the selection\n        if (index !== pi) {\n            return;\n        }\n        this._updateSelectedValue();\n        var cv = this.value;\n        // The previous item is now null, since it is no longer in the array.\n        this._previousValue = null;\n        // Send signal if there was a change\n        if (pv !== cv) {\n            // Emit the current changed signal.\n            this._selectionChanged.emit({\n                previousIndex: pi, previousValue: pv,\n                currentIndex: pi, currentValue: cv\n            });\n        }\n    };\n    Object.defineProperty(Selection.prototype, \"value\", {\n        /**\n         * Get the currently selected item.\n         *\n         * #### Notes\n         * This will be `null` if no item is selected.\n         */\n        get: function () {\n            return this._value;\n        },\n        /**\n         * Set the currently selected item.\n         *\n         * #### Notes\n         * If the item does not exist in the vector, the currentValue will be set to\n         * `null`. This selects the first entry equal to the desired item.\n         */\n        set: function (value) {\n            if (value === null) {\n                this.index = null;\n            }\n            else {\n                this.index = ArrayExt.firstIndexOf(this._array, value);\n            }\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Selection.prototype, \"index\", {\n        /**\n         * Get the index of the currently selected item.\n         *\n         * #### Notes\n         * This will be `null` if no item is selected.\n         */\n        get: function () {\n            return this._index;\n        },\n        /**\n         * Set the index of the currently selected tab.\n         *\n         * @param index - The index to select.\n         *\n         * #### Notes\n         * If the value is out of range, the index will be set to `null`, which\n         * indicates no item is selected.\n         */\n        set: function (index) {\n            // Coerce the value to an index.\n            var i;\n            if (index !== null) {\n                i = Math.floor(index);\n                if (i < 0 || i >= this._array.length) {\n                    i = null;\n                }\n            }\n            else {\n                i = null;\n            }\n            // Bail early if the index will not change.\n            if (this._index === i) {\n                return;\n            }\n            // Look up the previous index and item.\n            var pi = this._index;\n            var pv = this._value;\n            // Update the state\n            this._index = i;\n            this._updateSelectedValue();\n            this._previousValue = pv;\n            // Emit the current changed signal.\n            this._selectionChanged.emit({\n                previousIndex: pi, previousValue: pv,\n                currentIndex: i, currentValue: this._value\n            });\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Selection.prototype, \"insertBehavior\", {\n        /**\n         * Get the selection behavior when inserting a tab.\n         */\n        get: function () {\n            return this._insertBehavior;\n        },\n        /**\n         * Set the selection behavior when inserting a tab.\n         */\n        set: function (value) {\n            this._insertBehavior = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Selection.prototype, \"removeBehavior\", {\n        /**\n         * Get the selection behavior when removing a tab.\n         */\n        get: function () {\n            return this._removeBehavior;\n        },\n        /**\n         * Set the selection behavior when removing a tab.\n         */\n        set: function (value) {\n            this._removeBehavior = value;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Adjust the current index for a tab insert operation.\n     *\n     * @param i - The new index of the inserted item.\n     * @param j - The inserted item.\n     *\n     * #### Notes\n     * This method accounts for the tab bar's insertion behavior when adjusting\n     * the current index and emitting the changed signal. This should be called\n     * after the insertion.\n     */\n    Selection.prototype.adjustSelectionForInsert = function (i, item) {\n        // Lookup commonly used variables.\n        var cv = this._value;\n        var ci = this._index;\n        var bh = this._insertBehavior;\n        // Handle the behavior where the new item is always selected,\n        // or the behavior where the new item is selected if needed.\n        if (bh === 'select-item' || (bh === 'select-item-if-needed' && ci === null)) {\n            this._index = i;\n            this._value = item;\n            this._previousValue = cv;\n            this._selectionChanged.emit({\n                previousIndex: ci, previousValue: cv,\n                currentIndex: i, currentValue: item\n            });\n            return;\n        }\n        // Otherwise, silently adjust the current index if needed.\n        if (ci >= i) {\n            this._index++;\n        }\n    };\n    /**\n     * Adjust the current index for move operation.\n     *\n     * @param i - The previous index of the item.\n     * @param j - The new index of the item.\n     *\n     * #### Notes\n     * This method will not cause the actual current item to change. It silently\n     * adjusts the current index to account for the given move.\n     */\n    Selection.prototype.adjustSelectionForMove = function (i, j) {\n        if (this._index === i) {\n            this._index = j;\n        }\n        else if (this._index < i && this._index >= j) {\n            this._index++;\n        }\n        else if (this._index > i && this._index <= j) {\n            this._index--;\n        }\n    };\n    /**\n     * Clear the selection and history.\n     */\n    Selection.prototype.clearSelection = function () {\n        // Get the current index and item.\n        var pi = this._index;\n        var pv = this._value;\n        // Reset the current index and previous item.\n        this._index = null;\n        this._value = null;\n        this._previousValue = null;\n        // If no item was selected, there's nothing else to do.\n        if (pi === null) {\n            return;\n        }\n        // Emit the current changed signal.\n        this._selectionChanged.emit({\n            previousIndex: pi, previousValue: pv,\n            currentIndex: this._index, currentValue: this._value\n        });\n    };\n    /**\n     * Adjust the current index for an item remove operation.\n     *\n     * @param i - The former index of the removed item.\n     * @param item - The removed item.\n     *\n     * #### Notes\n     * This method accounts for the remove behavior when adjusting the current\n     * index and emitting the changed signal. It should be called after the item\n     * is removed.\n     */\n    Selection.prototype.adjustSelectionForRemove = function (i, item) {\n        // Lookup commonly used variables.\n        var ci = this._index;\n        var bh = this._removeBehavior;\n        // Silently adjust the index if the current item is not removed.\n        if (ci !== i) {\n            if (ci > i) {\n                this._index--;\n            }\n            return;\n        }\n        // No item gets selected if the vector is empty.\n        if (this._array.length === 0) {\n            // Reset the current index and previous item.\n            this._index = null;\n            this._value = null;\n            this._previousValue = null;\n            this._selectionChanged.emit({\n                previousIndex: i, previousValue: item,\n                currentIndex: this._index, currentValue: this._value\n            });\n            return;\n        }\n        // Handle behavior where the next sibling item is selected.\n        if (bh === 'select-item-after') {\n            this._index = Math.min(i, this._array.length - 1);\n            this._updateSelectedValue();\n            this._previousValue = null;\n            this._selectionChanged.emit({\n                previousIndex: i, previousValue: item,\n                currentIndex: this._index, currentValue: this._value\n            });\n            return;\n        }\n        // Handle behavior where the previous sibling item is selected.\n        if (bh === 'select-item-before') {\n            this._index = Math.max(0, i - 1);\n            this._updateSelectedValue();\n            this._previousValue = null;\n            this._selectionChanged.emit({\n                previousIndex: i, previousValue: item,\n                currentIndex: this._index, currentValue: this._value\n            });\n            return;\n        }\n        // Handle behavior where the previous history item is selected.\n        if (bh === 'select-previous-item') {\n            if (this._previousValue) {\n                this.value = this._previousValue;\n            }\n            else {\n                this._index = Math.min(i, this._array.length - 1);\n                this._updateSelectedValue();\n            }\n            this._previousValue = null;\n            this._selectionChanged.emit({\n                previousIndex: i, previousValue: item,\n                currentIndex: this._index, currentValue: this.value\n            });\n            return;\n        }\n        // Otherwise, no item gets selected.\n        this._index = null;\n        this._value = null;\n        this._previousValue = null;\n        this._selectionChanged.emit({\n            previousIndex: i, previousValue: item,\n            currentIndex: this._index, currentValue: this._value\n        });\n    };\n    /**\n     * Set the current value based on the current index.\n     */\n    Selection.prototype._updateSelectedValue = function () {\n        var i = this._index;\n        this._value = i !== null ? this._array[i] : null;\n    };\n    return Selection;\n}());\nexport { Selection };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nimport { ArrayExt } from '@lumino/algorithm';\nimport { Signal } from '@lumino/signaling';\nimport { Panel, PanelLayout, Widget } from '@lumino/widgets';\nimport { Selection } from './currentselection';\n/**\n * The class name added to Collapse instances.\n */\nvar COLLAPSE_CLASS = 'p-Collapse';\n/**\n * The class name added to a Collapse's header.\n */\nvar COLLAPSE_HEADER_CLASS = 'p-Collapse-header';\n/**\n * The class name added to a Collapse's contents.\n */\nvar COLLAPSE_CONTENTS_CLASS = 'p-Collapse-contents';\n/**\n * The class name added to a Collapse when it is opened\n */\nvar COLLAPSE_CLASS_OPEN = 'p-Collapse-open';\n/**\n * A panel that supports a collapsible header, made from the widget's title.\n * Clicking on the title expands or contracts the widget.\n */\nvar Collapse = /** @class */ (function (_super) {\n    __extends(Collapse, _super);\n    function Collapse(options) {\n        var _this = _super.call(this, options) || this;\n        _this._collapseChanged = new Signal(_this);\n        _this.addClass(COLLAPSE_CLASS);\n        _this._header = new Widget();\n        _this._header.addClass(COLLAPSE_HEADER_CLASS);\n        _this._header.node.addEventListener('click', _this);\n        // Fontawesome icon for caret\n        var icon = document.createElement('i');\n        icon.classList.add('fa', 'fa-fw', 'fa-caret-right');\n        _this._header.node.appendChild(icon);\n        // Label content\n        _this._header.node.appendChild(document.createElement('span'));\n        _this._content = new Panel();\n        _this._content.addClass(COLLAPSE_CONTENTS_CLASS);\n        var layout = new PanelLayout();\n        _this.layout = layout;\n        layout.addWidget(_this._header);\n        layout.addWidget(_this._content);\n        if (options.widget) {\n            _this.widget = options.widget;\n        }\n        _this.collapsed = false;\n        return _this;\n    }\n    Collapse.prototype.dispose = function () {\n        if (this.isDisposed) {\n            return;\n        }\n        _super.prototype.dispose.call(this);\n        this._header = null;\n        this._widget = null;\n        this._content = null;\n    };\n    Object.defineProperty(Collapse.prototype, \"widget\", {\n        get: function () {\n            return this._widget;\n        },\n        set: function (widget) {\n            var oldWidget = this._widget;\n            if (oldWidget) {\n                oldWidget.disposed.disconnect(this._onChildDisposed, this);\n                oldWidget.title.changed.disconnect(this._onTitleChanged, this);\n                oldWidget.parent = null;\n            }\n            this._widget = widget;\n            widget.disposed.connect(this._onChildDisposed, this);\n            widget.title.changed.connect(this._onTitleChanged, this);\n            this._onTitleChanged(widget.title);\n            this._content.addWidget(widget);\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Collapse.prototype, \"collapsed\", {\n        get: function () {\n            return this._collapsed;\n        },\n        set: function (value) {\n            // TODO: should we have this check here?\n            if (value === this._collapsed) {\n                return;\n            }\n            if (value) {\n                this._collapse();\n            }\n            else {\n                this._uncollapse();\n            }\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Collapse.prototype.toggle = function () {\n        this.collapsed = !this.collapsed;\n    };\n    Object.defineProperty(Collapse.prototype, \"collapseChanged\", {\n        get: function () {\n            return this._collapseChanged;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Collapse.prototype._collapse = function () {\n        this._collapsed = true;\n        if (this._content) {\n            this._content.hide();\n        }\n        this.removeClass(COLLAPSE_CLASS_OPEN);\n        this._header.node.children[0].classList.add('fa-caret-right');\n        this._header.node.children[0].classList.remove('fa-caret-down');\n        this._collapseChanged.emit(void 0);\n    };\n    Collapse.prototype._uncollapse = function () {\n        this._collapsed = false;\n        if (this._content) {\n            this._content.show();\n        }\n        this.addClass(COLLAPSE_CLASS_OPEN);\n        this._header.node.children[0].classList.add('fa-caret-down');\n        this._header.node.children[0].classList.remove('fa-caret-right');\n        this._collapseChanged.emit(void 0);\n    };\n    /**\n     * Handle the DOM events for the Collapse widget.\n     *\n     * @param event - The DOM event sent to the panel.\n     *\n     * #### Notes\n     * This method implements the DOM `EventListener` interface and is\n     * called in response to events on the panel's DOM node. It should\n     * not be called directly by user code.\n     */\n    Collapse.prototype.handleEvent = function (event) {\n        switch (event.type) {\n            case 'click':\n                this._evtClick(event);\n                break;\n            default:\n                break;\n        }\n    };\n    Collapse.prototype._evtClick = function (event) {\n        this.toggle();\n    };\n    /**\n     * Handle the `changed` signal of a title object.\n     */\n    Collapse.prototype._onTitleChanged = function (sender) {\n        this._header.node.children[1].textContent = this._widget.title.label;\n    };\n    Collapse.prototype._onChildDisposed = function (sender) {\n        this.dispose();\n    };\n    return Collapse;\n}(Widget));\nexport { Collapse };\n/**\n * The class name added to Accordion instances.\n */\nvar ACCORDION_CLASS = 'p-Accordion';\n/**\n * The class name added to an Accordion child.\n */\nvar ACCORDION_CHILD_CLASS = 'p-Accordion-child';\nvar ACCORDION_CHILD_ACTIVE_CLASS = 'p-Accordion-child-active';\n/**\n * A panel that supports a collapsible header, made from the widget's title.\n * Clicking on the title expands or contracts the widget.\n */\nvar Accordion = /** @class */ (function (_super) {\n    __extends(Accordion, _super);\n    function Accordion(options) {\n        var _this = _super.call(this, options) || this;\n        _this._selection = new Selection(_this.widgets);\n        _this._selection.selectionChanged.connect(_this._onSelectionChanged, _this);\n        _this.addClass(ACCORDION_CLASS);\n        return _this;\n    }\n    Object.defineProperty(Accordion.prototype, \"collapseWidgets\", {\n        /**\n         * A read-only sequence of the widgets in the panel.\n         *\n         * #### Notes\n         * This is a read-only property.\n         */\n        /*  get widgets(): ISequence<Widget> {\n            return new ArraySequence(toArray(map((this.layout as PanelLayout).widgets, (w: Collapse) => w.widget)));\n          }\n        */\n        get: function () {\n            return this.layout.widgets;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(Accordion.prototype, \"selection\", {\n        get: function () {\n            return this._selection;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Accordion.prototype.indexOf = function (widget) {\n        return ArrayExt.findFirstIndex(this.collapseWidgets, function (w) { return w.widget === widget; });\n    };\n    /**\n     * Add a widget to the end of the accordion.\n     *\n     * @param widget - The widget to add to the accordion.\n     *\n     * @returns The Collapse widget wrapping the added widget.\n     *\n     * #### Notes\n     * The widget will be wrapped in a CollapsedWidget.\n     */\n    Accordion.prototype.addWidget = function (widget) {\n        var collapse = this._wrapWidget(widget);\n        collapse.collapsed = true;\n        _super.prototype.addWidget.call(this, collapse);\n        this._selection.adjustSelectionForInsert(this.widgets.length - 1, collapse);\n        return collapse;\n    };\n    /**\n     * Insert a widget at the specified index.\n     *\n     * @param index - The index at which to insert the widget.\n     *\n     * @param widget - The widget to insert into to the accordion.\n     *\n     * #### Notes\n     * If the widget is already contained in the panel, it will be moved.\n     */\n    Accordion.prototype.insertWidget = function (index, widget) {\n        var collapse = this._wrapWidget(widget);\n        collapse.collapsed = true;\n        _super.prototype.insertWidget.call(this, index, collapse);\n        this._selection.adjustSelectionForInsert(index, collapse);\n    };\n    Accordion.prototype.removeWidget = function (widget) {\n        var index = this.indexOf(widget);\n        if (index >= 0) {\n            var collapse = this.collapseWidgets[index];\n            widget.parent = null;\n            collapse.dispose();\n            this._selection.adjustSelectionForRemove(index, null);\n        }\n    };\n    Accordion.prototype._wrapWidget = function (widget) {\n        var collapse = new Collapse({ widget: widget });\n        collapse.addClass(ACCORDION_CHILD_CLASS);\n        collapse.collapseChanged.connect(this._onCollapseChange, this);\n        return collapse;\n    };\n    Accordion.prototype._onCollapseChange = function (sender) {\n        if (!sender.collapsed) {\n            this._selection.value = sender;\n        }\n        else if (this._selection.value === sender && sender.collapsed) {\n            this._selection.value = null;\n        }\n    };\n    Accordion.prototype._onSelectionChanged = function (sender, change) {\n        // Collapse previous widget, open current widget\n        var pv = change.previousValue;\n        var cv = change.currentValue;\n        if (pv) {\n            pv.collapsed = true;\n            pv.removeClass(ACCORDION_CHILD_ACTIVE_CLASS);\n        }\n        if (cv) {\n            cv.collapsed = false;\n            cv.addClass(ACCORDION_CHILD_ACTIVE_CLASS);\n        }\n    };\n    return Accordion;\n}(Panel));\nexport { Accordion };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nimport { DOMWidgetView, ViewList } from '@jupyter-widgets/base';\nimport { BoxModel } from './widget_box';\nimport { TabPanel } from './phosphor/tabpanel';\nimport { Accordion } from './phosphor/accordion';\nimport { Widget } from '@lumino/widgets';\nimport { each, ArrayExt } from '@lumino/algorithm';\nimport { MessageLoop } from '@lumino/messaging';\nimport * as _ from 'underscore';\nimport * as utils from './utils';\nimport $ from 'jquery';\nvar SelectionContainerModel = /** @class */ (function (_super) {\n    __extends(SelectionContainerModel, _super);\n    function SelectionContainerModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    SelectionContainerModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'SelectionContainerModel',\n            selected_index: 0,\n            _titles: {}\n        });\n    };\n    return SelectionContainerModel;\n}(BoxModel));\nexport { SelectionContainerModel };\nvar AccordionModel = /** @class */ (function (_super) {\n    __extends(AccordionModel, _super);\n    function AccordionModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    AccordionModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'AccordionModel',\n            _view_name: 'AccordionView'\n        });\n    };\n    return AccordionModel;\n}(SelectionContainerModel));\nexport { AccordionModel };\n// We implement our own tab widget since Phoshpor's TabPanel uses an absolute\n// positioning BoxLayout, but we want a more an html/css-based Panel layout.\nvar JupyterPhosphorAccordionWidget = /** @class */ (function (_super) {\n    __extends(JupyterPhosphorAccordionWidget, _super);\n    function JupyterPhosphorAccordionWidget(options) {\n        var _this = this;\n        var view = options.view;\n        delete options.view;\n        _this = _super.call(this, options) || this;\n        _this._view = view;\n        return _this;\n    }\n    /**\n     * Process the phosphor message.\n     *\n     * Any custom phosphor widget used inside a Jupyter widget should override\n     * the processMessage function like this.\n     */\n    JupyterPhosphorAccordionWidget.prototype.processMessage = function (msg) {\n        _super.prototype.processMessage.call(this, msg);\n        this._view.processPhosphorMessage(msg);\n    };\n    /**\n     * Dispose the widget.\n     *\n     * This causes the view to be destroyed as well with 'remove'\n     */\n    JupyterPhosphorAccordionWidget.prototype.dispose = function () {\n        if (this.isDisposed) {\n            return;\n        }\n        _super.prototype.dispose.call(this);\n        if (this._view) {\n            this._view.remove();\n        }\n        this._view = null;\n    };\n    return JupyterPhosphorAccordionWidget;\n}(Accordion));\nexport { JupyterPhosphorAccordionWidget };\nvar AccordionView = /** @class */ (function (_super) {\n    __extends(AccordionView, _super);\n    function AccordionView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    AccordionView.prototype._createElement = function (tagName) {\n        this.pWidget = new JupyterPhosphorAccordionWidget({ view: this });\n        return this.pWidget.node;\n    };\n    AccordionView.prototype._setElement = function (el) {\n        if (this.el || el !== this.pWidget.node) {\n            // Accordions don't allow setting the element beyond the initial creation.\n            throw new Error('Cannot reset the DOM element.');\n        }\n        this.el = this.pWidget.node;\n        this.$el = $(this.pWidget.node);\n    };\n    AccordionView.prototype.initialize = function (parameters) {\n        var _this = this;\n        _super.prototype.initialize.call(this, parameters);\n        this.children_views = new ViewList(this.add_child_view, this.remove_child_view, this);\n        this.listenTo(this.model, 'change:children', function () { return _this.updateChildren(); });\n        this.listenTo(this.model, 'change:selected_index', function () { return _this.update_selected_index(); });\n        this.listenTo(this.model, 'change:_titles', function () { return _this.update_titles(); });\n    };\n    /**\n     * Called when view is rendered.\n     */\n    AccordionView.prototype.render = function () {\n        var _this = this;\n        _super.prototype.render.call(this);\n        var accordion = this.pWidget;\n        accordion.addClass('jupyter-widgets');\n        accordion.addClass('widget-accordion');\n        accordion.addClass('widget-container');\n        accordion.selection.selectionChanged.connect(function (sender) {\n            if (!_this.updatingChildren) {\n                _this.model.set('selected_index', accordion.selection.index);\n                _this.touch();\n            }\n        });\n        this.children_views.update(this.model.get('children'));\n        this.update_titles();\n        this.update_selected_index();\n    };\n    /**\n     * Update children\n     */\n    AccordionView.prototype.updateChildren = function () {\n        // While we are updating, the index may not be valid, so deselect the\n        // tabs before updating so we don't get spurious changes in the index,\n        // which would then set off another sync cycle.\n        this.updatingChildren = true;\n        this.pWidget.selection.index = null;\n        this.children_views.update(this.model.get('children'));\n        this.update_selected_index();\n        this.updatingChildren = false;\n    };\n    /**\n     * Set header titles\n     */\n    AccordionView.prototype.update_titles = function () {\n        var collapsed = this.pWidget.collapseWidgets;\n        var titles = this.model.get('_titles');\n        for (var i = 0; i < collapsed.length; i++) {\n            if (titles[i] !== void 0) {\n                collapsed[i].widget.title.label = titles[i];\n            }\n        }\n    };\n    /**\n     * Make the rendering and selected index consistent.\n     */\n    AccordionView.prototype.update_selected_index = function () {\n        this.pWidget.selection.index = this.model.get('selected_index');\n    };\n    /**\n     * Called when a child is removed from children list.\n     */\n    AccordionView.prototype.remove_child_view = function (view) {\n        this.pWidget.removeWidget(view.pWidget);\n        view.remove();\n    };\n    /**\n     * Called when a child is added to children list.\n     */\n    AccordionView.prototype.add_child_view = function (model, index) {\n        // Placeholder widget to keep our position in the tab panel while we create the view.\n        var accordion = this.pWidget;\n        var placeholder = new Widget();\n        placeholder.title.label = this.model.get('_titles')[index] || '';\n        accordion.addWidget(placeholder);\n        return this.create_child_view(model).then(function (view) {\n            var widget = view.pWidget;\n            widget.title.label = placeholder.title.label;\n            var collapse = accordion.collapseWidgets[accordion.indexOf(placeholder)];\n            collapse.widget = widget;\n            placeholder.dispose();\n            return view;\n        }).catch(utils.reject('Could not add child view to box', true));\n    };\n    AccordionView.prototype.remove = function () {\n        this.children_views = null;\n        _super.prototype.remove.call(this);\n    };\n    return AccordionView;\n}(DOMWidgetView));\nexport { AccordionView };\nvar TabModel = /** @class */ (function (_super) {\n    __extends(TabModel, _super);\n    function TabModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    TabModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'TabModel',\n            _view_name: 'TabView'\n        });\n    };\n    return TabModel;\n}(SelectionContainerModel));\nexport { TabModel };\n// We implement our own tab widget since Phoshpor's TabPanel uses an absolute\n// positioning BoxLayout, but we want a more an html/css-based Panel layout.\nvar JupyterPhosphorTabPanelWidget = /** @class */ (function (_super) {\n    __extends(JupyterPhosphorTabPanelWidget, _super);\n    function JupyterPhosphorTabPanelWidget(options) {\n        var _this = this;\n        var view = options.view;\n        delete options.view;\n        _this = _super.call(this, options) || this;\n        _this._view = view;\n        // We want the view's messages to be the messages the tabContents panel\n        // gets.\n        MessageLoop.installMessageHook(_this.tabContents, function (handler, msg) {\n            // There may be times when we want the view's handler to be called\n            // *after* the message has been processed by the widget, in which\n            // case we'll need to revisit using a message hook.\n            _this._view.processPhosphorMessage(msg);\n            return true;\n        });\n        return _this;\n    }\n    /**\n     * Dispose the widget.\n     *\n     * This causes the view to be destroyed as well with 'remove'\n     */\n    JupyterPhosphorTabPanelWidget.prototype.dispose = function () {\n        if (this.isDisposed) {\n            return;\n        }\n        _super.prototype.dispose.call(this);\n        if (this._view) {\n            this._view.remove();\n        }\n        this._view = null;\n    };\n    return JupyterPhosphorTabPanelWidget;\n}(TabPanel));\nexport { JupyterPhosphorTabPanelWidget };\nvar TabView = /** @class */ (function (_super) {\n    __extends(TabView, _super);\n    function TabView() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this.updatingTabs = false;\n        return _this;\n    }\n    TabView.prototype._createElement = function (tagName) {\n        this.pWidget = new JupyterPhosphorTabPanelWidget({\n            view: this,\n        });\n        return this.pWidget.node;\n    };\n    TabView.prototype._setElement = function (el) {\n        if (this.el || el !== this.pWidget.node) {\n            // TabViews don't allow setting the element beyond the initial creation.\n            throw new Error('Cannot reset the DOM element.');\n        }\n        this.el = this.pWidget.node;\n        this.$el = $(this.pWidget.node);\n    };\n    /**\n     * Public constructor.\n     */\n    TabView.prototype.initialize = function (parameters) {\n        var _this = this;\n        _super.prototype.initialize.call(this, parameters);\n        this.childrenViews = new ViewList(this.addChildView, function (view) { view.remove(); }, this);\n        this.listenTo(this.model, 'change:children', function () { return _this.updateTabs(); });\n        this.listenTo(this.model, 'change:_titles', function () { return _this.updateTitles(); });\n    };\n    /**\n     * Called when view is rendered.\n     */\n    TabView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        var tabs = this.pWidget;\n        tabs.addClass('jupyter-widgets');\n        tabs.addClass('widget-container');\n        tabs.addClass('widget-tab');\n        tabs.tabsMovable = true;\n        tabs.tabBar.insertBehavior = 'none'; // needed for insert behavior, see below.\n        tabs.tabBar.currentChanged.connect(this._onTabChanged, this);\n        tabs.tabBar.tabMoved.connect(this._onTabMoved, this);\n        tabs.tabBar.addClass('widget-tab-bar');\n        tabs.tabContents.addClass('widget-tab-contents');\n        // TODO: expose this option in python\n        tabs.tabBar.tabsMovable = false;\n        this.updateTabs();\n        this.update();\n    };\n    /**\n     * Render tab views based on the current model's children.\n     */\n    TabView.prototype.updateTabs = function () {\n        // While we are updating, the index may not be valid, so deselect the\n        // tabs before updating so we don't get spurious changes in the index,\n        // which would then set off another sync cycle.\n        this.updatingTabs = true;\n        this.pWidget.currentIndex = null;\n        this.childrenViews.update(this.model.get('children'));\n        this.pWidget.currentIndex = this.model.get('selected_index');\n        this.updatingTabs = false;\n    };\n    /**\n     * Called when a child is added to children list.\n     */\n    TabView.prototype.addChildView = function (model, index) {\n        // Placeholder widget to keep our position in the tab panel while we create the view.\n        var label = this.model.get('_titles')[index] || '';\n        var tabs = this.pWidget;\n        var placeholder = new Widget();\n        placeholder.title.label = label;\n        tabs.addWidget(placeholder);\n        return this.create_child_view(model).then(function (view) {\n            var widget = view.pWidget;\n            widget.title.label = placeholder.title.label;\n            widget.title.closable = false;\n            var i = ArrayExt.firstIndexOf(tabs.widgets, placeholder);\n            // insert after placeholder so that if placholder is selected, the\n            // real widget will be selected now (this depends on the tab bar\n            // insert behavior)\n            tabs.insertWidget(i + 1, widget);\n            placeholder.dispose();\n            return view;\n        }).catch(utils.reject('Could not add child view to box', true));\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed.  The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    TabView.prototype.update = function () {\n        // Update the selected index in the overall update method because it\n        // should be run after the tabs have been updated. Otherwise the\n        // selected index may not be a valid tab in the tab bar.\n        this.updateSelectedIndex();\n        return _super.prototype.update.call(this);\n    };\n    /**\n     * Updates the tab page titles.\n     */\n    TabView.prototype.updateTitles = function () {\n        var titles = this.model.get('_titles') || {};\n        each(this.pWidget.widgets, function (widget, i) {\n            widget.title.label = titles[i] || '';\n        });\n    };\n    /**\n     * Updates the selected index.\n     */\n    TabView.prototype.updateSelectedIndex = function () {\n        this.pWidget.currentIndex = this.model.get('selected_index');\n    };\n    TabView.prototype.remove = function () {\n        this.childrenViews = null;\n        _super.prototype.remove.call(this);\n    };\n    TabView.prototype._onTabChanged = function (sender, args) {\n        if (!this.updatingTabs) {\n            var i = args.currentIndex;\n            this.model.set('selected_index', i === -1 ? null : i);\n            this.touch();\n        }\n    };\n    /**\n     * Handle the `tabMoved` signal from the tab bar.\n     */\n    TabView.prototype._onTabMoved = function (sender, args) {\n        var children = this.model.get('children').slice();\n        ArrayExt.move(children, args.fromIndex, args.toIndex);\n        this.model.set('children', children);\n        this.touch();\n    };\n    return TabView;\n}(DOMWidgetView));\nexport { TabView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { CoreDescriptionModel } from './widget_core';\nimport { DescriptionView } from './widget_description';\nimport { uuid } from './utils';\nimport * as _ from 'underscore';\n/**\n * Class name for a combobox with an invlid value.\n */\nvar INVALID_VALUE_CLASS = 'jpwidgets-invalidComboValue';\nvar StringModel = /** @class */ (function (_super) {\n    __extends(StringModel, _super);\n    function StringModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    StringModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            value: '',\n            disabled: false,\n            placeholder: '\\u200b',\n            _model_name: 'StringModel'\n        });\n    };\n    return StringModel;\n}(CoreDescriptionModel));\nexport { StringModel };\nvar HTMLModel = /** @class */ (function (_super) {\n    __extends(HTMLModel, _super);\n    function HTMLModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    HTMLModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _view_name: 'HTMLView',\n            _model_name: 'HTMLModel'\n        });\n    };\n    return HTMLModel;\n}(StringModel));\nexport { HTMLModel };\nvar HTMLView = /** @class */ (function (_super) {\n    __extends(HTMLView, _super);\n    function HTMLView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    HTMLView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-html');\n        this.content = document.createElement('div');\n        this.content.classList.add('widget-html-content');\n        this.el.appendChild(this.content);\n        this.update(); // Set defaults.\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed.  The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    HTMLView.prototype.update = function () {\n        this.content.innerHTML = this.model.get('value');\n        return _super.prototype.update.call(this);\n    };\n    return HTMLView;\n}(DescriptionView));\nexport { HTMLView };\nvar HTMLMathModel = /** @class */ (function (_super) {\n    __extends(HTMLMathModel, _super);\n    function HTMLMathModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    HTMLMathModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _view_name: 'HTMLMathView',\n            _model_name: 'HTMLMathModel'\n        });\n    };\n    return HTMLMathModel;\n}(StringModel));\nexport { HTMLMathModel };\nvar HTMLMathView = /** @class */ (function (_super) {\n    __extends(HTMLMathView, _super);\n    function HTMLMathView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    HTMLMathView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-htmlmath');\n        this.content = document.createElement('div');\n        this.content.classList.add('widget-htmlmath-content');\n        this.el.appendChild(this.content);\n        this.update(); // Set defaults.\n    };\n    /**\n     * Update the contents of this view\n     */\n    HTMLMathView.prototype.update = function () {\n        this.content.innerHTML = this.model.get('value');\n        this.typeset(this.content);\n        return _super.prototype.update.call(this);\n    };\n    return HTMLMathView;\n}(DescriptionView));\nexport { HTMLMathView };\nvar LabelModel = /** @class */ (function (_super) {\n    __extends(LabelModel, _super);\n    function LabelModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    LabelModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _view_name: 'LabelView',\n            _model_name: 'LabelModel'\n        });\n    };\n    return LabelModel;\n}(StringModel));\nexport { LabelModel };\nvar LabelView = /** @class */ (function (_super) {\n    __extends(LabelView, _super);\n    function LabelView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    LabelView.prototype.render = function () {\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-label');\n        this.update(); // Set defaults.\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed.  The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    LabelView.prototype.update = function () {\n        this.typeset(this.el, this.model.get('value'));\n        return _super.prototype.update.call(this);\n    };\n    return LabelView;\n}(DescriptionView));\nexport { LabelView };\nvar TextareaModel = /** @class */ (function (_super) {\n    __extends(TextareaModel, _super);\n    function TextareaModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    TextareaModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _view_name: 'TextareaView',\n            _model_name: 'TextareaModel',\n            rows: null,\n            continuous_update: true,\n        });\n    };\n    return TextareaModel;\n}(StringModel));\nexport { TextareaModel };\nvar TextareaView = /** @class */ (function (_super) {\n    __extends(TextareaView, _super);\n    function TextareaView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    TextareaView.prototype.render = function () {\n        var _this = this;\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-textarea');\n        this.textbox = document.createElement('textarea');\n        this.textbox.setAttribute('rows', '5');\n        this.textbox.id = this.label.htmlFor = uuid();\n        this.el.appendChild(this.textbox);\n        this.update(); // Set defaults.\n        this.listenTo(this.model, 'change:placeholder', function (model, value, options) {\n            _this.update_placeholder(value);\n        });\n        this.update_placeholder();\n    };\n    TextareaView.prototype.update_placeholder = function (value) {\n        value = value || this.model.get('placeholder');\n        this.textbox.setAttribute('placeholder', value.toString());\n    };\n    /**\n     * Update the contents of this view\n     *\n     * Called when the model is changed.  The model may have been\n     * changed by another view or by a state update from the back-end.\n     */\n    TextareaView.prototype.update = function (options) {\n        if (options === undefined || options.updated_view != this) {\n            this.textbox.value = this.model.get('value');\n            var rows = this.model.get('rows');\n            if (rows === null) {\n                rows = '';\n            }\n            this.textbox.setAttribute('rows', rows);\n            this.textbox.disabled = this.model.get('disabled');\n        }\n        return _super.prototype.update.call(this);\n    };\n    TextareaView.prototype.events = function () {\n        return {\n            'keydown input': 'handleKeyDown',\n            'keypress input': 'handleKeypress',\n            'input textarea': 'handleChanging',\n            'change textarea': 'handleChanged'\n        };\n    };\n    /**\n     * Handle key down\n     *\n     * Stop propagation so the event isn't sent to the application.\n     */\n    TextareaView.prototype.handleKeyDown = function (e) {\n        e.stopPropagation();\n    };\n    /**\n     * Handles key press\n     *\n     * Stop propagation so the keypress isn't sent to the application.\n     */\n    TextareaView.prototype.handleKeypress = function (e) {\n        e.stopPropagation();\n    };\n    /**\n     * Triggered on input change\n     */\n    TextareaView.prototype.handleChanging = function (e) {\n        if (this.model.get('continuous_update')) {\n            this.handleChanged(e);\n        }\n    };\n    /**\n     * Sync the value with the kernel.\n     *\n     * @param e Event\n     */\n    TextareaView.prototype.handleChanged = function (e) {\n        var target = e.target;\n        this.model.set('value', target.value, { updated_view: this });\n        this.touch();\n    };\n    return TextareaView;\n}(DescriptionView));\nexport { TextareaView };\nvar TextModel = /** @class */ (function (_super) {\n    __extends(TextModel, _super);\n    function TextModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    TextModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _view_name: 'TextView',\n            _model_name: 'TextModel',\n            continuous_update: true,\n        });\n    };\n    return TextModel;\n}(StringModel));\nexport { TextModel };\nvar TextView = /** @class */ (function (_super) {\n    __extends(TextView, _super);\n    function TextView() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this.inputType = 'text';\n        return _this;\n    }\n    /**\n     * Called when view is rendered.\n     */\n    TextView.prototype.render = function () {\n        var _this = this;\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-inline-hbox');\n        this.el.classList.add('widget-text');\n        this.textbox = document.createElement('input');\n        this.textbox.setAttribute('type', this.inputType);\n        this.textbox.id = this.label.htmlFor = uuid();\n        this.el.appendChild(this.textbox);\n        this.update(); // Set defaults.\n        this.listenTo(this.model, 'change:placeholder', function (model, value, options) {\n            _this.update_placeholder(value);\n        });\n        this.listenTo(this.model, 'change:description_tooltip', this.update_title);\n        this.listenTo(this.model, 'change:description', this.update_title);\n        this.update_placeholder();\n        this.update_title();\n    };\n    TextView.prototype.update_placeholder = function (value) {\n        this.textbox.setAttribute('placeholder', value || this.model.get('placeholder'));\n    };\n    TextView.prototype.update_title = function () {\n        var title = this.model.get('description_tooltip');\n        if (!title) {\n            this.textbox.removeAttribute('title');\n        }\n        else if (this.model.get('description').length === 0) {\n            this.textbox.setAttribute('title', title);\n        }\n    };\n    TextView.prototype.update = function (options) {\n        /**\n         * Update the contents of this view\n         *\n         * Called when the model is changed.  The model may have been\n         * changed by another view or by a state update from the back-end.\n         */\n        if (options === undefined || options.updated_view !== this) {\n            if (this.textbox.value !== this.model.get('value')) {\n                this.textbox.value = this.model.get('value');\n            }\n            this.textbox.disabled = this.model.get('disabled');\n        }\n        return _super.prototype.update.call(this);\n    };\n    TextView.prototype.events = function () {\n        return {\n            'keydown input': 'handleKeyDown',\n            'keypress input': 'handleKeypress',\n            'input input': 'handleChanging',\n            'change input': 'handleChanged'\n        };\n    };\n    /**\n     * Handle key down\n     *\n     * Stop propagation so the keypress isn't sent to the application.\n     */\n    TextView.prototype.handleKeyDown = function (e) {\n        e.stopPropagation();\n    };\n    /**\n     * Handles text submission\n     */\n    TextView.prototype.handleKeypress = function (e) {\n        e.stopPropagation();\n        // The submit message is deprecated in widgets 7\n        if (e.keyCode === 13) { // Return key\n            this.send({ event: 'submit' });\n        }\n    };\n    /**\n     * Handles user input.\n     *\n     * Calling model.set will trigger all of the other views of the\n     * model to update.\n     */\n    TextView.prototype.handleChanging = function (e) {\n        if (this.model.get('continuous_update')) {\n            this.handleChanged(e);\n        }\n    };\n    /**\n     * Handles user input.\n     *\n     * Calling model.set will trigger all of the other views of the\n     * model to update.\n     */\n    TextView.prototype.handleChanged = function (e) {\n        var target = e.target;\n        this.model.set('value', target.value, { updated_view: this });\n        this.touch();\n    };\n    return TextView;\n}(DescriptionView));\nexport { TextView };\nvar PasswordModel = /** @class */ (function (_super) {\n    __extends(PasswordModel, _super);\n    function PasswordModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    PasswordModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _view_name: 'PasswordView',\n            _model_name: 'PasswordModel'\n        });\n    };\n    return PasswordModel;\n}(TextModel));\nexport { PasswordModel };\nvar PasswordView = /** @class */ (function (_super) {\n    __extends(PasswordView, _super);\n    function PasswordView() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this.inputType = 'password';\n        return _this;\n    }\n    return PasswordView;\n}(TextView));\nexport { PasswordView };\n/**\n * Combobox widget model class.\n */\nvar ComboboxModel = /** @class */ (function (_super) {\n    __extends(ComboboxModel, _super);\n    function ComboboxModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    ComboboxModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'ComboboxModel', _view_name: 'ComboboxView', options: [], ensure_options: false });\n    };\n    return ComboboxModel;\n}(TextModel));\nexport { ComboboxModel };\n/**\n * Combobox widget view class.\n */\nvar ComboboxView = /** @class */ (function (_super) {\n    __extends(ComboboxView, _super);\n    function ComboboxView() {\n        var _this = _super !== null && _super.apply(this, arguments) || this;\n        _this.isInitialRender = true;\n        return _this;\n    }\n    ComboboxView.prototype.render = function () {\n        this.datalist = document.createElement('datalist');\n        this.datalist.id = uuid();\n        _super.prototype.render.call(this);\n        this.textbox.setAttribute('list', this.datalist.id);\n        this.el.appendChild(this.datalist);\n    };\n    ComboboxView.prototype.update = function (options) {\n        _super.prototype.update.call(this, options);\n        if (!this.datalist) {\n            return;\n        }\n        var valid = this.isValid(this.model.get('value'));\n        this.highlightValidState(valid);\n        // Check if we need to update options\n        if ((options !== undefined && options.updated_view) || (!this.model.hasChanged('options') &&\n            !this.isInitialRender)) {\n            // Value update only, keep current options\n            return;\n        }\n        this.isInitialRender = false;\n        var opts = this.model.get('options');\n        var optLines = opts.map(function (o) {\n            return \"<option value=\\\"\" + o + \"\\\"></option>\";\n        });\n        this.datalist.innerHTML = optLines.join('\\n');\n    };\n    ComboboxView.prototype.isValid = function (value) {\n        if (true === this.model.get('ensure_option')) {\n            var options = this.model.get('options');\n            if (options.indexOf(value) === -1) {\n                return false;\n            }\n        }\n        return true;\n    };\n    ComboboxView.prototype.handleChanging = function (e) {\n        // Override to validate value\n        var target = e.target;\n        var valid = this.isValid(target.value);\n        this.highlightValidState(valid);\n        if (valid) {\n            _super.prototype.handleChanging.call(this, e);\n        }\n    };\n    ComboboxView.prototype.handleChanged = function (e) {\n        // Override to validate value\n        var target = e.target;\n        var valid = this.isValid(target.value);\n        this.highlightValidState(valid);\n        if (valid) {\n            _super.prototype.handleChanged.call(this, e);\n        }\n    };\n    ComboboxView.prototype.highlightValidState = function (valid) {\n        this.textbox.classList.toggle(INVALID_VALUE_CLASS, !valid);\n    };\n    return ComboboxView;\n}(TextView));\nexport { ComboboxView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nvar __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nvar __spreadArrays = (this && this.__spreadArrays) || function () {\n    for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\n    for (var r = Array(s), k = 0, i = 0; i < il; i++)\n        for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\n            r[k] = a[j];\n    return r;\n};\nimport { CoreDOMWidgetModel } from './widget_core';\nimport { DOMWidgetView } from '@jupyter-widgets/base';\nimport * as _ from 'underscore';\nvar FileUploadModel = /** @class */ (function (_super) {\n    __extends(FileUploadModel, _super);\n    function FileUploadModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    FileUploadModel.prototype.defaults = function () {\n        return _.extend(_super.prototype.defaults.call(this), {\n            _model_name: 'FileUploadModel',\n            _view_name: 'FileUploadView',\n            _counter: 0,\n            accept: '',\n            description: 'Upload',\n            tooltip: '',\n            disabled: false,\n            icon: 'upload',\n            button_style: '',\n            multiple: false,\n            metadata: [],\n            data: [],\n            error: '',\n            style: null\n        });\n    };\n    FileUploadModel.serializers = __assign(__assign({}, CoreDOMWidgetModel.serializers), { data: { serialize: function (buffers) { return __spreadArrays(buffers); } } });\n    return FileUploadModel;\n}(CoreDOMWidgetModel));\nexport { FileUploadModel };\nvar FileUploadView = /** @class */ (function (_super) {\n    __extends(FileUploadView, _super);\n    function FileUploadView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    Object.defineProperty(FileUploadView.prototype, \"tagName\", {\n        get: function () {\n            return 'button';\n        },\n        enumerable: true,\n        configurable: true\n    });\n    FileUploadView.prototype.render = function () {\n        var _this = this;\n        _super.prototype.render.call(this);\n        this.el.classList.add('jupyter-widgets');\n        this.el.classList.add('widget-upload');\n        this.el.classList.add('jupyter-button');\n        this.fileInput = document.createElement('input');\n        this.fileInput.type = 'file';\n        this.fileInput.style.display = 'none';\n        this.el.appendChild(this.fileInput);\n        this.el.addEventListener('click', function () {\n            _this.fileInput.click();\n        });\n        this.fileInput.addEventListener('click', function () {\n            _this.fileInput.value = '';\n        });\n        this.fileInput.addEventListener('change', function () {\n            var promisesFile = [];\n            Array.from(_this.fileInput.files).forEach(function (file) {\n                promisesFile.push(new Promise(function (resolve, reject) {\n                    var metadata = {\n                        name: file.name,\n                        type: file.type,\n                        size: file.size,\n                        lastModified: file.lastModified,\n                    };\n                    _this.fileReader = new FileReader();\n                    _this.fileReader.onload = function (event) {\n                        var buffer = event.target.result;\n                        resolve({\n                            buffer: buffer,\n                            metadata: metadata,\n                            error: '',\n                        });\n                    };\n                    _this.fileReader.onerror = function () {\n                        reject();\n                    };\n                    _this.fileReader.onabort = _this.fileReader.onerror;\n                    _this.fileReader.readAsArrayBuffer(file);\n                }));\n            });\n            Promise.all(promisesFile)\n                .then(function (contents) {\n                var metadata = [];\n                var li_buffer = [];\n                contents.forEach(function (c) {\n                    metadata.push(c.metadata);\n                    li_buffer.push(c.buffer);\n                });\n                var counter = _this.model.get('_counter');\n                _this.model.set({\n                    _counter: counter + contents.length,\n                    metadata: metadata,\n                    data: li_buffer,\n                    error: '',\n                });\n                _this.touch();\n            })\n                .catch(function (err) {\n                console.error('error in file upload: %o', err);\n                _this.model.set({\n                    error: err,\n                });\n                _this.touch();\n            });\n        });\n        this.listenTo(this.model, 'change:button_style', this.update_button_style);\n        this.set_button_style();\n        this.update(); // Set defaults.\n    };\n    FileUploadView.prototype.update = function () {\n        this.el.disabled = this.model.get('disabled');\n        this.el.setAttribute('title', this.model.get('tooltip'));\n        var description = this.model.get('description') + \" (\" + this.model.get('_counter') + \")\";\n        var icon = this.model.get('icon');\n        if (description.length || icon.length) {\n            this.el.textContent = '';\n            if (icon.length) {\n                var i = document.createElement('i');\n                i.classList.add('fa');\n                i.classList.add('fa-' + icon);\n                if (description.length === 0) {\n                    i.classList.add('center');\n                }\n                this.el.appendChild(i);\n            }\n            this.el.appendChild(document.createTextNode(description));\n        }\n        this.fileInput.accept = this.model.get('accept');\n        this.fileInput.multiple = this.model.get('multiple');\n        return _super.prototype.update.call(this);\n    };\n    FileUploadView.prototype.update_button_style = function () {\n        this.update_mapped_classes(FileUploadView.class_map, 'button_style', this.el);\n    };\n    FileUploadView.prototype.set_button_style = function () {\n        this.set_mapped_classes(FileUploadView.class_map, 'button_style', this.el);\n    };\n    FileUploadView.class_map = {\n        primary: ['mod-primary'],\n        success: ['mod-success'],\n        info: ['mod-info'],\n        warning: ['mod-warning'],\n        danger: ['mod-danger']\n    };\n    return FileUploadView;\n}(DOMWidgetView));\nexport { FileUploadView };\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\nexport * from './utils';\nexport * from './version';\nexport * from './widget_link';\nexport * from './widget_bool';\nexport * from './widget_button';\nexport * from './widget_box';\nexport * from './widget_image';\nexport * from './widget_video';\nexport * from './widget_audio';\nexport * from './widget_color';\nexport * from './widget_date';\nexport * from './widget_int';\nexport * from './widget_float';\nexport * from './widget_controller';\nexport * from './widget_selection';\nexport * from './widget_selectioncontainer';\nexport * from './widget_string';\nexport * from './widget_description';\nexport * from './widget_upload';\nexport var version = require('../package.json').version;\n","'use strict'\n\nexports.byteLength = byteLength\nexports.toByteArray = toByteArray\nexports.fromByteArray = fromByteArray\n\nvar lookup = []\nvar revLookup = []\nvar Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array\n\nvar code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'\nfor (var i = 0, len = code.length; i < len; ++i) {\n  lookup[i] = code[i]\n  revLookup[code.charCodeAt(i)] = i\n}\n\n// Support decoding URL-safe base64 strings, as Node.js does.\n// See: https://en.wikipedia.org/wiki/Base64#URL_applications\nrevLookup['-'.charCodeAt(0)] = 62\nrevLookup['_'.charCodeAt(0)] = 63\n\nfunction getLens (b64) {\n  var len = b64.length\n\n  if (len % 4 > 0) {\n    throw new Error('Invalid string. Length must be a multiple of 4')\n  }\n\n  // Trim off extra bytes after placeholder bytes are found\n  // See: https://github.com/beatgammit/base64-js/issues/42\n  var validLen = b64.indexOf('=')\n  if (validLen === -1) validLen = len\n\n  var placeHoldersLen = validLen === len\n    ? 0\n    : 4 - (validLen % 4)\n\n  return [validLen, placeHoldersLen]\n}\n\n// base64 is 4/3 + up to two characters of the original data\nfunction byteLength (b64) {\n  var lens = getLens(b64)\n  var validLen = lens[0]\n  var placeHoldersLen = lens[1]\n  return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen\n}\n\nfunction _byteLength (b64, validLen, placeHoldersLen) {\n  return ((validLen + placeHoldersLen) * 3 / 4) - placeHoldersLen\n}\n\nfunction toByteArray (b64) {\n  var tmp\n  var lens = getLens(b64)\n  var validLen = lens[0]\n  var placeHoldersLen = lens[1]\n\n  var arr = new Arr(_byteLength(b64, validLen, placeHoldersLen))\n\n  var curByte = 0\n\n  // if there are placeholders, only get up to the last complete 4 chars\n  var len = placeHoldersLen > 0\n    ? validLen - 4\n    : validLen\n\n  var i\n  for (i = 0; i < len; i += 4) {\n    tmp =\n      (revLookup[b64.charCodeAt(i)] << 18) |\n      (revLookup[b64.charCodeAt(i + 1)] << 12) |\n      (revLookup[b64.charCodeAt(i + 2)] << 6) |\n      revLookup[b64.charCodeAt(i + 3)]\n    arr[curByte++] = (tmp >> 16) & 0xFF\n    arr[curByte++] = (tmp >> 8) & 0xFF\n    arr[curByte++] = tmp & 0xFF\n  }\n\n  if (placeHoldersLen === 2) {\n    tmp =\n      (revLookup[b64.charCodeAt(i)] << 2) |\n      (revLookup[b64.charCodeAt(i + 1)] >> 4)\n    arr[curByte++] = tmp & 0xFF\n  }\n\n  if (placeHoldersLen === 1) {\n    tmp =\n      (revLookup[b64.charCodeAt(i)] << 10) |\n      (revLookup[b64.charCodeAt(i + 1)] << 4) |\n      (revLookup[b64.charCodeAt(i + 2)] >> 2)\n    arr[curByte++] = (tmp >> 8) & 0xFF\n    arr[curByte++] = tmp & 0xFF\n  }\n\n  return arr\n}\n\nfunction tripletToBase64 (num) {\n  return lookup[num >> 18 & 0x3F] +\n    lookup[num >> 12 & 0x3F] +\n    lookup[num >> 6 & 0x3F] +\n    lookup[num & 0x3F]\n}\n\nfunction encodeChunk (uint8, start, end) {\n  var tmp\n  var output = []\n  for (var i = start; i < end; i += 3) {\n    tmp =\n      ((uint8[i] << 16) & 0xFF0000) +\n      ((uint8[i + 1] << 8) & 0xFF00) +\n      (uint8[i + 2] & 0xFF)\n    output.push(tripletToBase64(tmp))\n  }\n  return output.join('')\n}\n\nfunction fromByteArray (uint8) {\n  var tmp\n  var len = uint8.length\n  var extraBytes = len % 3 // if we have 1 byte left, pad 2 bytes\n  var parts = []\n  var maxChunkLength = 16383 // must be multiple of 3\n\n  // go through the array every three bytes, we'll deal with trailing stuff later\n  for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) {\n    parts.push(encodeChunk(\n      uint8, i, (i + maxChunkLength) > len2 ? len2 : (i + maxChunkLength)\n    ))\n  }\n\n  // pad the end with zeros, but make sure to not forget the extra bytes\n  if (extraBytes === 1) {\n    tmp = uint8[len - 1]\n    parts.push(\n      lookup[tmp >> 2] +\n      lookup[(tmp << 4) & 0x3F] +\n      '=='\n    )\n  } else if (extraBytes === 2) {\n    tmp = (uint8[len - 2] << 8) + uint8[len - 1]\n    parts.push(\n      lookup[tmp >> 10] +\n      lookup[(tmp >> 4) & 0x3F] +\n      lookup[(tmp << 2) & 0x3F] +\n      '='\n    )\n  }\n\n  return parts.join('')\n}\n","/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n  return value === other || (value !== value && other !== other);\n}\n\nmodule.exports = eq;\n","var baseGetTag = require('./_baseGetTag'),\n    isObject = require('./isObject');\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n    funcTag = '[object Function]',\n    genTag = '[object GeneratorFunction]',\n    proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n  if (!isObject(value)) {\n    return false;\n  }\n  // The use of `Object#toString` avoids issues with the `typeof` operator\n  // in Safari 9 which returns 'object' for typed arrays and other constructors.\n  var tag = baseGetTag(value);\n  return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nmodule.exports = isFunction;\n","/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nmodule.exports = freeGlobal;\n","/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n  var type = typeof value;\n  return value != null && (type == 'object' || type == 'function');\n}\n\nmodule.exports = isObject;\n","/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n  if (func != null) {\n    try {\n      return funcToString.call(func);\n    } catch (e) {}\n    try {\n      return (func + '');\n    } catch (e) {}\n  }\n  return '';\n}\n\nmodule.exports = toSource;\n","var mapCacheClear = require('./_mapCacheClear'),\n    mapCacheDelete = require('./_mapCacheDelete'),\n    mapCacheGet = require('./_mapCacheGet'),\n    mapCacheHas = require('./_mapCacheHas'),\n    mapCacheSet = require('./_mapCacheSet');\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n  var index = -1,\n      length = entries == null ? 0 : entries.length;\n\n  this.clear();\n  while (++index < length) {\n    var entry = entries[index];\n    this.set(entry[0], entry[1]);\n  }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nmodule.exports = MapCache;\n","var SetCache = require('./_SetCache'),\n    arraySome = require('./_arraySome'),\n    cacheHas = require('./_cacheHas');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n    COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n  var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n      arrLength = array.length,\n      othLength = other.length;\n\n  if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n    return false;\n  }\n  // Assume cyclic values are equal.\n  var stacked = stack.get(array);\n  if (stacked && stack.get(other)) {\n    return stacked == other;\n  }\n  var index = -1,\n      result = true,\n      seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n  stack.set(array, other);\n  stack.set(other, array);\n\n  // Ignore non-index properties.\n  while (++index < arrLength) {\n    var arrValue = array[index],\n        othValue = other[index];\n\n    if (customizer) {\n      var compared = isPartial\n        ? customizer(othValue, arrValue, index, other, array, stack)\n        : customizer(arrValue, othValue, index, array, other, stack);\n    }\n    if (compared !== undefined) {\n      if (compared) {\n        continue;\n      }\n      result = false;\n      break;\n    }\n    // Recursively compare arrays (susceptible to call stack limits).\n    if (seen) {\n      if (!arraySome(other, function(othValue, othIndex) {\n            if (!cacheHas(seen, othIndex) &&\n                (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n              return seen.push(othIndex);\n            }\n          })) {\n        result = false;\n        break;\n      }\n    } else if (!(\n          arrValue === othValue ||\n            equalFunc(arrValue, othValue, bitmask, customizer, stack)\n        )) {\n      result = false;\n      break;\n    }\n  }\n  stack['delete'](array);\n  stack['delete'](other);\n  return result;\n}\n\nmodule.exports = equalArrays;\n","var root = require('./_root'),\n    stubFalse = require('./stubFalse');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nmodule.exports = isBuffer;\n","var baseIsTypedArray = require('./_baseIsTypedArray'),\n    baseUnary = require('./_baseUnary'),\n    nodeUtil = require('./_nodeUtil');\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nmodule.exports = isTypedArray;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n  return typeof value == 'number' &&\n    value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nmodule.exports = isLength;\n","/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n  return function(arg) {\n    return func(transform(arg));\n  };\n}\n\nmodule.exports = overArg;\n","/*!\n * jQuery UI Widget 1.12.1\n * http://jqueryui.com\n *\n * Copyright jQuery Foundation and other contributors\n * Released under the MIT license.\n * http://jquery.org/license\n */\n\n//>>label: Widget\n//>>group: Core\n//>>description: Provides a factory for creating stateful widgets with a common API.\n//>>docs: http://api.jqueryui.com/jQuery.widget/\n//>>demos: http://jqueryui.com/widget/\n\n( function( factory ) {\n\tif ( typeof define === \"function\" && define.amd ) {\n\n\t\t// AMD. Register as an anonymous module.\n\t\tdefine( [ \"jquery\", \"./version\" ], factory );\n\t} else {\n\n\t\t// Browser globals\n\t\tfactory( jQuery );\n\t}\n}( function( $ ) {\n\nvar widgetUuid = 0;\nvar widgetSlice = Array.prototype.slice;\n\n$.cleanData = ( function( orig ) {\n\treturn function( elems ) {\n\t\tvar events, elem, i;\n\t\tfor ( i = 0; ( elem = elems[ i ] ) != null; i++ ) {\n\t\t\ttry {\n\n\t\t\t\t// Only trigger remove when necessary to save time\n\t\t\t\tevents = $._data( elem, \"events\" );\n\t\t\t\tif ( events && events.remove ) {\n\t\t\t\t\t$( elem ).triggerHandler( \"remove\" );\n\t\t\t\t}\n\n\t\t\t// Http://bugs.jquery.com/ticket/8235\n\t\t\t} catch ( e ) {}\n\t\t}\n\t\torig( elems );\n\t};\n} )( $.cleanData );\n\n$.widget = function( name, base, prototype ) {\n\tvar existingConstructor, constructor, basePrototype;\n\n\t// ProxiedPrototype allows the provided prototype to remain unmodified\n\t// so that it can be used as a mixin for multiple widgets (#8876)\n\tvar proxiedPrototype = {};\n\n\tvar namespace = name.split( \".\" )[ 0 ];\n\tname = name.split( \".\" )[ 1 ];\n\tvar fullName = namespace + \"-\" + name;\n\n\tif ( !prototype ) {\n\t\tprototype = base;\n\t\tbase = $.Widget;\n\t}\n\n\tif ( $.isArray( prototype ) ) {\n\t\tprototype = $.extend.apply( null, [ {} ].concat( prototype ) );\n\t}\n\n\t// Create selector for plugin\n\t$.expr[ \":\" ][ fullName.toLowerCase() ] = function( elem ) {\n\t\treturn !!$.data( elem, fullName );\n\t};\n\n\t$[ namespace ] = $[ namespace ] || {};\n\texistingConstructor = $[ namespace ][ name ];\n\tconstructor = $[ namespace ][ name ] = function( options, element ) {\n\n\t\t// Allow instantiation without \"new\" keyword\n\t\tif ( !this._createWidget ) {\n\t\t\treturn new constructor( options, element );\n\t\t}\n\n\t\t// Allow instantiation without initializing for simple inheritance\n\t\t// must use \"new\" keyword (the code above always passes args)\n\t\tif ( arguments.length ) {\n\t\t\tthis._createWidget( options, element );\n\t\t}\n\t};\n\n\t// Extend with the existing constructor to carry over any static properties\n\t$.extend( constructor, existingConstructor, {\n\t\tversion: prototype.version,\n\n\t\t// Copy the object used to create the prototype in case we need to\n\t\t// redefine the widget later\n\t\t_proto: $.extend( {}, prototype ),\n\n\t\t// Track widgets that inherit from this widget in case this widget is\n\t\t// redefined after a widget inherits from it\n\t\t_childConstructors: []\n\t} );\n\n\tbasePrototype = new base();\n\n\t// We need to make the options hash a property directly on the new instance\n\t// otherwise we'll modify the options hash on the prototype that we're\n\t// inheriting from\n\tbasePrototype.options = $.widget.extend( {}, basePrototype.options );\n\t$.each( prototype, function( prop, value ) {\n\t\tif ( !$.isFunction( value ) ) {\n\t\t\tproxiedPrototype[ prop ] = value;\n\t\t\treturn;\n\t\t}\n\t\tproxiedPrototype[ prop ] = ( function() {\n\t\t\tfunction _super() {\n\t\t\t\treturn base.prototype[ prop ].apply( this, arguments );\n\t\t\t}\n\n\t\t\tfunction _superApply( args ) {\n\t\t\t\treturn base.prototype[ prop ].apply( this, args );\n\t\t\t}\n\n\t\t\treturn function() {\n\t\t\t\tvar __super = this._super;\n\t\t\t\tvar __superApply = this._superApply;\n\t\t\t\tvar returnValue;\n\n\t\t\t\tthis._super = _super;\n\t\t\t\tthis._superApply = _superApply;\n\n\t\t\t\treturnValue = value.apply( this, arguments );\n\n\t\t\t\tthis._super = __super;\n\t\t\t\tthis._superApply = __superApply;\n\n\t\t\t\treturn returnValue;\n\t\t\t};\n\t\t} )();\n\t} );\n\tconstructor.prototype = $.widget.extend( basePrototype, {\n\n\t\t// TODO: remove support for widgetEventPrefix\n\t\t// always use the name + a colon as the prefix, e.g., draggable:start\n\t\t// don't prefix for widgets that aren't DOM-based\n\t\twidgetEventPrefix: existingConstructor ? ( basePrototype.widgetEventPrefix || name ) : name\n\t}, proxiedPrototype, {\n\t\tconstructor: constructor,\n\t\tnamespace: namespace,\n\t\twidgetName: name,\n\t\twidgetFullName: fullName\n\t} );\n\n\t// If this widget is being redefined then we need to find all widgets that\n\t// are inheriting from it and redefine all of them so that they inherit from\n\t// the new version of this widget. We're essentially trying to replace one\n\t// level in the prototype chain.\n\tif ( existingConstructor ) {\n\t\t$.each( existingConstructor._childConstructors, function( i, child ) {\n\t\t\tvar childPrototype = child.prototype;\n\n\t\t\t// Redefine the child widget using the same prototype that was\n\t\t\t// originally used, but inherit from the new version of the base\n\t\t\t$.widget( childPrototype.namespace + \".\" + childPrototype.widgetName, constructor,\n\t\t\t\tchild._proto );\n\t\t} );\n\n\t\t// Remove the list of existing child constructors from the old constructor\n\t\t// so the old child constructors can be garbage collected\n\t\tdelete existingConstructor._childConstructors;\n\t} else {\n\t\tbase._childConstructors.push( constructor );\n\t}\n\n\t$.widget.bridge( name, constructor );\n\n\treturn constructor;\n};\n\n$.widget.extend = function( target ) {\n\tvar input = widgetSlice.call( arguments, 1 );\n\tvar inputIndex = 0;\n\tvar inputLength = input.length;\n\tvar key;\n\tvar value;\n\n\tfor ( ; inputIndex < inputLength; inputIndex++ ) {\n\t\tfor ( key in input[ inputIndex ] ) {\n\t\t\tvalue = input[ inputIndex ][ key ];\n\t\t\tif ( input[ inputIndex ].hasOwnProperty( key ) && value !== undefined ) {\n\n\t\t\t\t// Clone objects\n\t\t\t\tif ( $.isPlainObject( value ) ) {\n\t\t\t\t\ttarget[ key ] = $.isPlainObject( target[ key ] ) ?\n\t\t\t\t\t\t$.widget.extend( {}, target[ key ], value ) :\n\n\t\t\t\t\t\t// Don't extend strings, arrays, etc. with objects\n\t\t\t\t\t\t$.widget.extend( {}, value );\n\n\t\t\t\t// Copy everything else by reference\n\t\t\t\t} else {\n\t\t\t\t\ttarget[ key ] = value;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\treturn target;\n};\n\n$.widget.bridge = function( name, object ) {\n\tvar fullName = object.prototype.widgetFullName || name;\n\t$.fn[ name ] = function( options ) {\n\t\tvar isMethodCall = typeof options === \"string\";\n\t\tvar args = widgetSlice.call( arguments, 1 );\n\t\tvar returnValue = this;\n\n\t\tif ( isMethodCall ) {\n\n\t\t\t// If this is an empty collection, we need to have the instance method\n\t\t\t// return undefined instead of the jQuery instance\n\t\t\tif ( !this.length && options === \"instance\" ) {\n\t\t\t\treturnValue = undefined;\n\t\t\t} else {\n\t\t\t\tthis.each( function() {\n\t\t\t\t\tvar methodValue;\n\t\t\t\t\tvar instance = $.data( this, fullName );\n\n\t\t\t\t\tif ( options === \"instance\" ) {\n\t\t\t\t\t\treturnValue = instance;\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\n\t\t\t\t\tif ( !instance ) {\n\t\t\t\t\t\treturn $.error( \"cannot call methods on \" + name +\n\t\t\t\t\t\t\t\" prior to initialization; \" +\n\t\t\t\t\t\t\t\"attempted to call method '\" + options + \"'\" );\n\t\t\t\t\t}\n\n\t\t\t\t\tif ( !$.isFunction( instance[ options ] ) || options.charAt( 0 ) === \"_\" ) {\n\t\t\t\t\t\treturn $.error( \"no such method '\" + options + \"' for \" + name +\n\t\t\t\t\t\t\t\" widget instance\" );\n\t\t\t\t\t}\n\n\t\t\t\t\tmethodValue = instance[ options ].apply( instance, args );\n\n\t\t\t\t\tif ( methodValue !== instance && methodValue !== undefined ) {\n\t\t\t\t\t\treturnValue = methodValue && methodValue.jquery ?\n\t\t\t\t\t\t\treturnValue.pushStack( methodValue.get() ) :\n\t\t\t\t\t\t\tmethodValue;\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t} );\n\t\t\t}\n\t\t} else {\n\n\t\t\t// Allow multiple hashes to be passed on init\n\t\t\tif ( args.length ) {\n\t\t\t\toptions = $.widget.extend.apply( null, [ options ].concat( args ) );\n\t\t\t}\n\n\t\t\tthis.each( function() {\n\t\t\t\tvar instance = $.data( this, fullName );\n\t\t\t\tif ( instance ) {\n\t\t\t\t\tinstance.option( options || {} );\n\t\t\t\t\tif ( instance._init ) {\n\t\t\t\t\t\tinstance._init();\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t$.data( this, fullName, new object( options, this ) );\n\t\t\t\t}\n\t\t\t} );\n\t\t}\n\n\t\treturn returnValue;\n\t};\n};\n\n$.Widget = function( /* options, element */ ) {};\n$.Widget._childConstructors = [];\n\n$.Widget.prototype = {\n\twidgetName: \"widget\",\n\twidgetEventPrefix: \"\",\n\tdefaultElement: \"<div>\",\n\n\toptions: {\n\t\tclasses: {},\n\t\tdisabled: false,\n\n\t\t// Callbacks\n\t\tcreate: null\n\t},\n\n\t_createWidget: function( options, element ) {\n\t\telement = $( element || this.defaultElement || this )[ 0 ];\n\t\tthis.element = $( element );\n\t\tthis.uuid = widgetUuid++;\n\t\tthis.eventNamespace = \".\" + this.widgetName + this.uuid;\n\n\t\tthis.bindings = $();\n\t\tthis.hoverable = $();\n\t\tthis.focusable = $();\n\t\tthis.classesElementLookup = {};\n\n\t\tif ( element !== this ) {\n\t\t\t$.data( element, this.widgetFullName, this );\n\t\t\tthis._on( true, this.element, {\n\t\t\t\tremove: function( event ) {\n\t\t\t\t\tif ( event.target === element ) {\n\t\t\t\t\t\tthis.destroy();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} );\n\t\t\tthis.document = $( element.style ?\n\n\t\t\t\t// Element within the document\n\t\t\t\telement.ownerDocument :\n\n\t\t\t\t// Element is window or document\n\t\t\t\telement.document || element );\n\t\t\tthis.window = $( this.document[ 0 ].defaultView || this.document[ 0 ].parentWindow );\n\t\t}\n\n\t\tthis.options = $.widget.extend( {},\n\t\t\tthis.options,\n\t\t\tthis._getCreateOptions(),\n\t\t\toptions );\n\n\t\tthis._create();\n\n\t\tif ( this.options.disabled ) {\n\t\t\tthis._setOptionDisabled( this.options.disabled );\n\t\t}\n\n\t\tthis._trigger( \"create\", null, this._getCreateEventData() );\n\t\tthis._init();\n\t},\n\n\t_getCreateOptions: function() {\n\t\treturn {};\n\t},\n\n\t_getCreateEventData: $.noop,\n\n\t_create: $.noop,\n\n\t_init: $.noop,\n\n\tdestroy: function() {\n\t\tvar that = this;\n\n\t\tthis._destroy();\n\t\t$.each( this.classesElementLookup, function( key, value ) {\n\t\t\tthat._removeClass( value, key );\n\t\t} );\n\n\t\t// We can probably remove the unbind calls in 2.0\n\t\t// all event bindings should go through this._on()\n\t\tthis.element\n\t\t\t.off( this.eventNamespace )\n\t\t\t.removeData( this.widgetFullName );\n\t\tthis.widget()\n\t\t\t.off( this.eventNamespace )\n\t\t\t.removeAttr( \"aria-disabled\" );\n\n\t\t// Clean up events and states\n\t\tthis.bindings.off( this.eventNamespace );\n\t},\n\n\t_destroy: $.noop,\n\n\twidget: function() {\n\t\treturn this.element;\n\t},\n\n\toption: function( key, value ) {\n\t\tvar options = key;\n\t\tvar parts;\n\t\tvar curOption;\n\t\tvar i;\n\n\t\tif ( arguments.length === 0 ) {\n\n\t\t\t// Don't return a reference to the internal hash\n\t\t\treturn $.widget.extend( {}, this.options );\n\t\t}\n\n\t\tif ( typeof key === \"string\" ) {\n\n\t\t\t// Handle nested keys, e.g., \"foo.bar\" => { foo: { bar: ___ } }\n\t\t\toptions = {};\n\t\t\tparts = key.split( \".\" );\n\t\t\tkey = parts.shift();\n\t\t\tif ( parts.length ) {\n\t\t\t\tcurOption = options[ key ] = $.widget.extend( {}, this.options[ key ] );\n\t\t\t\tfor ( i = 0; i < parts.length - 1; i++ ) {\n\t\t\t\t\tcurOption[ parts[ i ] ] = curOption[ parts[ i ] ] || {};\n\t\t\t\t\tcurOption = curOption[ parts[ i ] ];\n\t\t\t\t}\n\t\t\t\tkey = parts.pop();\n\t\t\t\tif ( arguments.length === 1 ) {\n\t\t\t\t\treturn curOption[ key ] === undefined ? null : curOption[ key ];\n\t\t\t\t}\n\t\t\t\tcurOption[ key ] = value;\n\t\t\t} else {\n\t\t\t\tif ( arguments.length === 1 ) {\n\t\t\t\t\treturn this.options[ key ] === undefined ? null : this.options[ key ];\n\t\t\t\t}\n\t\t\t\toptions[ key ] = value;\n\t\t\t}\n\t\t}\n\n\t\tthis._setOptions( options );\n\n\t\treturn this;\n\t},\n\n\t_setOptions: function( options ) {\n\t\tvar key;\n\n\t\tfor ( key in options ) {\n\t\t\tthis._setOption( key, options[ key ] );\n\t\t}\n\n\t\treturn this;\n\t},\n\n\t_setOption: function( key, value ) {\n\t\tif ( key === \"classes\" ) {\n\t\t\tthis._setOptionClasses( value );\n\t\t}\n\n\t\tthis.options[ key ] = value;\n\n\t\tif ( key === \"disabled\" ) {\n\t\t\tthis._setOptionDisabled( value );\n\t\t}\n\n\t\treturn this;\n\t},\n\n\t_setOptionClasses: function( value ) {\n\t\tvar classKey, elements, currentElements;\n\n\t\tfor ( classKey in value ) {\n\t\t\tcurrentElements = this.classesElementLookup[ classKey ];\n\t\t\tif ( value[ classKey ] === this.options.classes[ classKey ] ||\n\t\t\t\t\t!currentElements ||\n\t\t\t\t\t!currentElements.length ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t// We are doing this to create a new jQuery object because the _removeClass() call\n\t\t\t// on the next line is going to destroy the reference to the current elements being\n\t\t\t// tracked. We need to save a copy of this collection so that we can add the new classes\n\t\t\t// below.\n\t\t\telements = $( currentElements.get() );\n\t\t\tthis._removeClass( currentElements, classKey );\n\n\t\t\t// We don't use _addClass() here, because that uses this.options.classes\n\t\t\t// for generating the string of classes. We want to use the value passed in from\n\t\t\t// _setOption(), this is the new value of the classes option which was passed to\n\t\t\t// _setOption(). We pass this value directly to _classes().\n\t\t\telements.addClass( this._classes( {\n\t\t\t\telement: elements,\n\t\t\t\tkeys: classKey,\n\t\t\t\tclasses: value,\n\t\t\t\tadd: true\n\t\t\t} ) );\n\t\t}\n\t},\n\n\t_setOptionDisabled: function( value ) {\n\t\tthis._toggleClass( this.widget(), this.widgetFullName + \"-disabled\", null, !!value );\n\n\t\t// If the widget is becoming disabled, then nothing is interactive\n\t\tif ( value ) {\n\t\t\tthis._removeClass( this.hoverable, null, \"ui-state-hover\" );\n\t\t\tthis._removeClass( this.focusable, null, \"ui-state-focus\" );\n\t\t}\n\t},\n\n\tenable: function() {\n\t\treturn this._setOptions( { disabled: false } );\n\t},\n\n\tdisable: function() {\n\t\treturn this._setOptions( { disabled: true } );\n\t},\n\n\t_classes: function( options ) {\n\t\tvar full = [];\n\t\tvar that = this;\n\n\t\toptions = $.extend( {\n\t\t\telement: this.element,\n\t\t\tclasses: this.options.classes || {}\n\t\t}, options );\n\n\t\tfunction processClassString( classes, checkOption ) {\n\t\t\tvar current, i;\n\t\t\tfor ( i = 0; i < classes.length; i++ ) {\n\t\t\t\tcurrent = that.classesElementLookup[ classes[ i ] ] || $();\n\t\t\t\tif ( options.add ) {\n\t\t\t\t\tcurrent = $( $.unique( current.get().concat( options.element.get() ) ) );\n\t\t\t\t} else {\n\t\t\t\t\tcurrent = $( current.not( options.element ).get() );\n\t\t\t\t}\n\t\t\t\tthat.classesElementLookup[ classes[ i ] ] = current;\n\t\t\t\tfull.push( classes[ i ] );\n\t\t\t\tif ( checkOption && options.classes[ classes[ i ] ] ) {\n\t\t\t\t\tfull.push( options.classes[ classes[ i ] ] );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tthis._on( options.element, {\n\t\t\t\"remove\": \"_untrackClassesElement\"\n\t\t} );\n\n\t\tif ( options.keys ) {\n\t\t\tprocessClassString( options.keys.match( /\\S+/g ) || [], true );\n\t\t}\n\t\tif ( options.extra ) {\n\t\t\tprocessClassString( options.extra.match( /\\S+/g ) || [] );\n\t\t}\n\n\t\treturn full.join( \" \" );\n\t},\n\n\t_untrackClassesElement: function( event ) {\n\t\tvar that = this;\n\t\t$.each( that.classesElementLookup, function( key, value ) {\n\t\t\tif ( $.inArray( event.target, value ) !== -1 ) {\n\t\t\t\tthat.classesElementLookup[ key ] = $( value.not( event.target ).get() );\n\t\t\t}\n\t\t} );\n\t},\n\n\t_removeClass: function( element, keys, extra ) {\n\t\treturn this._toggleClass( element, keys, extra, false );\n\t},\n\n\t_addClass: function( element, keys, extra ) {\n\t\treturn this._toggleClass( element, keys, extra, true );\n\t},\n\n\t_toggleClass: function( element, keys, extra, add ) {\n\t\tadd = ( typeof add === \"boolean\" ) ? add : extra;\n\t\tvar shift = ( typeof element === \"string\" || element === null ),\n\t\t\toptions = {\n\t\t\t\textra: shift ? keys : extra,\n\t\t\t\tkeys: shift ? element : keys,\n\t\t\t\telement: shift ? this.element : element,\n\t\t\t\tadd: add\n\t\t\t};\n\t\toptions.element.toggleClass( this._classes( options ), add );\n\t\treturn this;\n\t},\n\n\t_on: function( suppressDisabledCheck, element, handlers ) {\n\t\tvar delegateElement;\n\t\tvar instance = this;\n\n\t\t// No suppressDisabledCheck flag, shuffle arguments\n\t\tif ( typeof suppressDisabledCheck !== \"boolean\" ) {\n\t\t\thandlers = element;\n\t\t\telement = suppressDisabledCheck;\n\t\t\tsuppressDisabledCheck = false;\n\t\t}\n\n\t\t// No element argument, shuffle and use this.element\n\t\tif ( !handlers ) {\n\t\t\thandlers = element;\n\t\t\telement = this.element;\n\t\t\tdelegateElement = this.widget();\n\t\t} else {\n\t\t\telement = delegateElement = $( element );\n\t\t\tthis.bindings = this.bindings.add( element );\n\t\t}\n\n\t\t$.each( handlers, function( event, handler ) {\n\t\t\tfunction handlerProxy() {\n\n\t\t\t\t// Allow widgets to customize the disabled handling\n\t\t\t\t// - disabled as an array instead of boolean\n\t\t\t\t// - disabled class as method for disabling individual parts\n\t\t\t\tif ( !suppressDisabledCheck &&\n\t\t\t\t\t\t( instance.options.disabled === true ||\n\t\t\t\t\t\t$( this ).hasClass( \"ui-state-disabled\" ) ) ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\treturn ( typeof handler === \"string\" ? instance[ handler ] : handler )\n\t\t\t\t\t.apply( instance, arguments );\n\t\t\t}\n\n\t\t\t// Copy the guid so direct unbinding works\n\t\t\tif ( typeof handler !== \"string\" ) {\n\t\t\t\thandlerProxy.guid = handler.guid =\n\t\t\t\t\thandler.guid || handlerProxy.guid || $.guid++;\n\t\t\t}\n\n\t\t\tvar match = event.match( /^([\\w:-]*)\\s*(.*)$/ );\n\t\t\tvar eventName = match[ 1 ] + instance.eventNamespace;\n\t\t\tvar selector = match[ 2 ];\n\n\t\t\tif ( selector ) {\n\t\t\t\tdelegateElement.on( eventName, selector, handlerProxy );\n\t\t\t} else {\n\t\t\t\telement.on( eventName, handlerProxy );\n\t\t\t}\n\t\t} );\n\t},\n\n\t_off: function( element, eventName ) {\n\t\teventName = ( eventName || \"\" ).split( \" \" ).join( this.eventNamespace + \" \" ) +\n\t\t\tthis.eventNamespace;\n\t\telement.off( eventName ).off( eventName );\n\n\t\t// Clear the stack to avoid memory leaks (#10056)\n\t\tthis.bindings = $( this.bindings.not( element ).get() );\n\t\tthis.focusable = $( this.focusable.not( element ).get() );\n\t\tthis.hoverable = $( this.hoverable.not( element ).get() );\n\t},\n\n\t_delay: function( handler, delay ) {\n\t\tfunction handlerProxy() {\n\t\t\treturn ( typeof handler === \"string\" ? instance[ handler ] : handler )\n\t\t\t\t.apply( instance, arguments );\n\t\t}\n\t\tvar instance = this;\n\t\treturn setTimeout( handlerProxy, delay || 0 );\n\t},\n\n\t_hoverable: function( element ) {\n\t\tthis.hoverable = this.hoverable.add( element );\n\t\tthis._on( element, {\n\t\t\tmouseenter: function( event ) {\n\t\t\t\tthis._addClass( $( event.currentTarget ), null, \"ui-state-hover\" );\n\t\t\t},\n\t\t\tmouseleave: function( event ) {\n\t\t\t\tthis._removeClass( $( event.currentTarget ), null, \"ui-state-hover\" );\n\t\t\t}\n\t\t} );\n\t},\n\n\t_focusable: function( element ) {\n\t\tthis.focusable = this.focusable.add( element );\n\t\tthis._on( element, {\n\t\t\tfocusin: function( event ) {\n\t\t\t\tthis._addClass( $( event.currentTarget ), null, \"ui-state-focus\" );\n\t\t\t},\n\t\t\tfocusout: function( event ) {\n\t\t\t\tthis._removeClass( $( event.currentTarget ), null, \"ui-state-focus\" );\n\t\t\t}\n\t\t} );\n\t},\n\n\t_trigger: function( type, event, data ) {\n\t\tvar prop, orig;\n\t\tvar callback = this.options[ type ];\n\n\t\tdata = data || {};\n\t\tevent = $.Event( event );\n\t\tevent.type = ( type === this.widgetEventPrefix ?\n\t\t\ttype :\n\t\t\tthis.widgetEventPrefix + type ).toLowerCase();\n\n\t\t// The original event may come from any element\n\t\t// so we need to reset the target on the new event\n\t\tevent.target = this.element[ 0 ];\n\n\t\t// Copy original event properties over to the new event\n\t\torig = event.originalEvent;\n\t\tif ( orig ) {\n\t\t\tfor ( prop in orig ) {\n\t\t\t\tif ( !( prop in event ) ) {\n\t\t\t\t\tevent[ prop ] = orig[ prop ];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tthis.element.trigger( event, data );\n\t\treturn !( $.isFunction( callback ) &&\n\t\t\tcallback.apply( this.element[ 0 ], [ event ].concat( data ) ) === false ||\n\t\t\tevent.isDefaultPrevented() );\n\t}\n};\n\n$.each( { show: \"fadeIn\", hide: \"fadeOut\" }, function( method, defaultEffect ) {\n\t$.Widget.prototype[ \"_\" + method ] = function( element, options, callback ) {\n\t\tif ( typeof options === \"string\" ) {\n\t\t\toptions = { effect: options };\n\t\t}\n\n\t\tvar hasOptions;\n\t\tvar effectName = !options ?\n\t\t\tmethod :\n\t\t\toptions === true || typeof options === \"number\" ?\n\t\t\t\tdefaultEffect :\n\t\t\t\toptions.effect || defaultEffect;\n\n\t\toptions = options || {};\n\t\tif ( typeof options === \"number\" ) {\n\t\t\toptions = { duration: options };\n\t\t}\n\n\t\thasOptions = !$.isEmptyObject( options );\n\t\toptions.complete = callback;\n\n\t\tif ( options.delay ) {\n\t\t\telement.delay( options.delay );\n\t\t}\n\n\t\tif ( hasOptions && $.effects && $.effects.effect[ effectName ] ) {\n\t\t\telement[ method ]( options );\n\t\t} else if ( effectName !== method && element[ effectName ] ) {\n\t\t\telement[ effectName ]( options.duration, options.easing, callback );\n\t\t} else {\n\t\t\telement.queue( function( next ) {\n\t\t\t\t$( this )[ method ]();\n\t\t\t\tif ( callback ) {\n\t\t\t\t\tcallback.call( element[ 0 ] );\n\t\t\t\t}\n\t\t\t\tnext();\n\t\t\t} );\n\t\t}\n\t};\n} );\n\nreturn $.widget;\n\n} ) );\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n\"use strict\";\n\n// This widget is strongly coupled to the notebook because of the outputarea\n// dependency.\nvar widgets = require(\"@jupyter-widgets/controls\");\nvar outputBase = require(\"@jupyter-widgets/output\");\nvar _ = require(\"underscore\");\nrequire('./widget_output.css');\n\nvar outputArea = new Promise(function(resolve, reject) {\n        requirejs([\"notebook/js/outputarea\"], resolve, reject)\n});\n\nvar OutputModel = outputBase.OutputModel.extend({\n    defaults: _.extend({}, outputBase.OutputModel.prototype.defaults(), {\n        msg_id: \"\",\n        outputs: []\n    }),\n\n    initialize: function(attributes, options) {\n        OutputModel.__super__.initialize.apply(this, arguments);\n        this.listenTo(this, 'change:msg_id', this.reset_msg_id);\n\n        if (this.comm && this.comm.kernel) {\n            this.kernel = this.comm.kernel;\n            this.kernel.set_callbacks_for_msg(this.model_id, this.callbacks(), false);\n        }\n\n        var that = this;\n        // Create an output area to handle the data model part\n        outputArea.then(function(outputArea) {\n            that.output_area = new outputArea.OutputArea({\n                selector: document.createElement('div'),\n                config: {data: {OutputArea: {}}},\n                prompt_area: false,\n                events: that.widget_manager.notebook.events,\n                keyboard_manager: that.widget_manager.keyboard_manager });\n            that.listenTo(that, 'new_message', function(msg) {\n                that.output_area.handle_output(msg);\n                that.set('outputs', that.output_area.toJSON(), {newMessage: true});\n                that.save_changes();\n            }, that);\n            that.listenTo(that, 'clear_output', function(msg) {\n                that.output_area.handle_clear_output(msg);\n                that.set('outputs', that.output_area.toJSON(), {newMessage: true});\n                that.save_changes();\n            })\n            that.listenTo(that, 'change:outputs', that.setOutputs);\n            that.setOutputs();\n        });\n    },\n\n    // make callbacks\n    callbacks: function() {\n        // Merge our callbacks with the base class callbacks.\n        var cb = OutputModel.__super__.callbacks.apply(this, arguments);\n        var iopub = cb.iopub || {};\n        var iopubCallbacks = _.extend({}, iopub, {\n            output: function(msg) {\n                this.trigger('new_message', msg);\n                if (iopub.output) {\n                    iopub.output.apply(this, arguments);\n                }\n            }.bind(this),\n            clear_output: function(msg) {\n                this.trigger('clear_output', msg);\n                if (iopub.clear_output) {\n                    iopub.clear_output.apply(this, arguments);\n                }\n            }.bind(this)\n        });\n        return _.extend({}, cb, {iopub: iopubCallbacks});\n    },\n\n    reset_msg_id: function() {\n        var kernel = this.kernel;\n        // Pop previous message id\n        var prev_msg_id = this.previous('msg_id');\n        if (prev_msg_id && kernel) {\n            var previous_callback = kernel.output_callback_overrides_pop(prev_msg_id);\n            if (previous_callback !== this.model_id) {\n                console.error('Popped wrong message ('+previous_callback+' instead of '+this.model_id+') - likely the stack was not maintained in kernel.');\n            }\n        }\n        var msg_id = this.get('msg_id');\n        if (msg_id && kernel) {\n            kernel.output_callback_overrides_push(msg_id, this.model_id);\n        }\n    },\n\n    setOutputs: function(model, value, options) {\n        if (!(options && options.newMessage)) {\n            // fromJSON does not clear the existing output\n            this.output_area.clear_output();\n            // fromJSON does not copy the message, so we make a deep copy\n            this.output_area.fromJSON(JSON.parse(JSON.stringify(this.get('outputs'))));\n        }\n    },\n\n});\n\nvar OutputView = outputBase.OutputView.extend({\n    render: function(){\n        var that = this;\n        this.el.classList.add('jupyter-widgets-output-area');\n        outputArea.then(function(outputArea) {\n            that.output_area = new outputArea.OutputArea({\n                selector: that.el,\n                // use default values for the output area config\n                config: {data: {OutputArea: {}}},\n                prompt_area: false,\n                events: that.model.widget_manager.notebook.events,\n                keyboard_manager: that.model.widget_manager.keyboard_manager });\n            that.listenTo(that.model, 'new_message', function(msg) {\n                that.output_area.handle_output(msg);\n            }, that);\n            that.listenTo(that.model, 'clear_output', function(msg) {\n                that.output_area.handle_clear_output(msg);\n                // fake the event on the output area element. This can be\n                // deleted when we can rely on\n                // https://github.com/jupyter/notebook/pull/2411 being\n                // available.\n                that.output_area.element.trigger('clearing', {output_area: this});\n            })\n            // Render initial contents from the current model\n            that.listenTo(that.model, 'change:outputs', that.setOutputs);\n            that.setOutputs();\n        });\n        OutputView.__super__.render.apply(this, arguments);\n    },\n\n    setOutputs: function(model, value, options) {\n        if (!(options && options.newMessage)) {\n            // fromJSON does not clear the existing output\n            this.output_area.clear_output();\n            // fromJSON does not copy the message, so we make a deep copy\n            this.output_area.fromJSON(JSON.parse(JSON.stringify(this.model.get('outputs'))));\n        }\n    }\n});\n\nmodule.exports = {\n    OutputView: OutputView,\n    OutputModel: OutputModel,\n};\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n\n\"use strict\";\n\nvar save_state = function() {\n    return new Promise(function(resolve, reject) {\n        requirejs([\"base/js/namespace\"], function(Jupyter) {\n            var wm = Jupyter.WidgetManager._managers[0];\n            if (!wm) {reject('No widget manager');}\n            return wm.get_state({\n                'drop_defaults': true\n            }).then(function(state) {\n                var data = \"text/json;charset=utf-8,\" + encodeURIComponent(JSON.stringify(state, null, \"    \"));\n                var a = document.createElement(\"a\");\n                a.download = \"widget_state.json\";\n                a.href = \"data:\" + data;\n                a.click();\n                resolve();\n            });\n        });\n    });\n};\n\nvar action = {\n    help: 'Download the widget state as a JSON file',\n    icon: 'fa-sliders',\n    help_index : 'zz',\n    handler : save_state\n};\n\nvar action_name = 'save-widget-state';\nvar prefix = 'widgets';\nrequirejs([\"base/js/namespace\"], function(Jupyter) {\n    Jupyter.notebook.keyboard_manager.actions.register(action, action_name, prefix);\n});\n\nmodule.exports = {action: action};\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n\n\"use strict\";\n\nvar VIEW_MIME_TYPE = \"application/vnd.jupyter.widget-view+json\"\n\nvar htmlManagerVersion = require(\"@jupyter-widgets/html-manager/package.json\").version;\n\nvar embed_widgets = function() {\n\n    /**\n     * Escape a string that will be the content of an HTML script tag.\n     *\n     * We replace the opening bracket of <script, </script, and <!-- with the\n     * unicode equivalent. This is inspired by the documentation for the script\n     * tag at\n     * https://html.spec.whatwg.org/multipage/scripting.html#restrictions-for-contents-of-script-elements\n     *\n     * We only replace these three cases so that most html or other content\n     * involving `<` is readable.\n     */\n    function escapeScript(s) {\n        return s.replace(/<(script|\\/script|!--)/gi, '\\\\u003c$1');\n    }\n\n    return new Promise(function(resolve, reject) {\n        requirejs(['base/js/namespace', 'base/js/dialog', '@jupyter-widgets/controls'], function(Jupyter, dialog, widgets) {\n            var wm = Jupyter.WidgetManager._managers[0];\n            if (!wm) {\n                reject('No widget manager');\n            }\n            wm.get_state({\n                'drop_defaults': true\n            }).then(function(state) {\n                var data = escapeScript(JSON.stringify(state, null, '    '));\n                var value = [\n'<html><head>',\n'',\n'',\n'<!-- Load require.js. Delete this if your page already loads require.js -->',\n'<script src=\"https://cdnjs.cloudflare.com/ajax/libs/require.js/2.3.4/require.min.js\" integrity=\"sha256-Ae2Vz/4ePdIu6ZyI/5ZGsYnb+m0JlOmKPjt6XZ9JJkA=\" crossorigin=\"anonymous\"></script>',\n'<script src=\"https://unpkg.com/@jupyter-widgets/html-manager@*/dist/embed-amd.js\" crossorigin=\"anonymous\"></script>',\n'<script type=\"application/vnd.jupyter.widget-state+json\">',\ndata,\n'</script>',\n'</head>',\n'<body>',\n''].join('\\n');\n                var views = [];\n                var cells = Jupyter.notebook.get_cells();\n                Jupyter.notebook.get_cells().forEach(function(cell) {\n                    if (cell.output_area) {\n                        cell.output_area.outputs.forEach(function (output) {\n                            if (output.data\n                                && output.data[VIEW_MIME_TYPE]\n                                && state.state[output.data[VIEW_MIME_TYPE].model_id]) {\n                                views.push(('\\n<script type=\"'+VIEW_MIME_TYPE+'\">\\n'\n                                    + escapeScript(JSON.stringify(output.data[VIEW_MIME_TYPE], null, '    '))\n                                    + '\\n</script>'));\n                            }\n                        });\n                    }\n                })\n                value += views.join('\\n');\n                value += '\\n\\n</body>\\n</html>\\n';\n                var content = document.createElement('textarea');\n                content.setAttribute('readonly', 'true');\n                content.style.width = '100%';\n                content.style.minHeight = '250px';\n                content.value = value;\n\n                var mod = dialog.modal({\n                    show: true,\n                    title: 'Embed widgets',\n                    body: content,\n                    keyboard_manager: Jupyter.notebook.keyboard_manager,\n                    notebook: Jupyter.notebook,\n                    buttons: {\n                        'Copy to Clipboard': {\n                            class: 'btn-primary',\n                            click: function(event) {\n                                content.select();\n                                return document.execCommand('copy');\n                            }\n                        }\n                    }\n                });\n            });\n        });\n    });\n};\n\nvar action = {\n    help: 'Embed interactive widgets',\n    icon: 'fa-sliders',\n    help_index : 'zz',\n    handler : embed_widgets\n};\n\nvar action_name = 'embed-interactive-widgets';\nvar prefix = 'widgets';\nrequirejs([\"base/js/namespace\"], function(Jupyter) {\n    Jupyter.notebook.keyboard_manager.actions.register(action, action_name, prefix);\n});\n\nmodule.exports = {\n    action: action\n};\n","var baseIsEqual = require('./_baseIsEqual');\n\n/**\n * Performs a deep comparison between two values to determine if they are\n * equivalent.\n *\n * **Note:** This method supports comparing arrays, array buffers, booleans,\n * date objects, error objects, maps, numbers, `Object` objects, regexes,\n * sets, strings, symbols, and typed arrays. `Object` objects are compared\n * by their own, not inherited, enumerable properties. Functions and DOM\n * nodes are compared by strict equality, i.e. `===`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.isEqual(object, other);\n * // => true\n *\n * object === other;\n * // => false\n */\nfunction isEqual(value, other) {\n  return baseIsEqual(value, other);\n}\n\nmodule.exports = isEqual;\n","var baseGetTag = require('./_baseGetTag'),\n    getPrototype = require('./_getPrototype'),\n    isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n    objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to infer the `Object` constructor. */\nvar objectCtorString = funcToString.call(Object);\n\n/**\n * Checks if `value` is a plain object, that is, an object created by the\n * `Object` constructor or one with a `[[Prototype]]` of `null`.\n *\n * @static\n * @memberOf _\n * @since 0.8.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a plain object, else `false`.\n * @example\n *\n * function Foo() {\n *   this.a = 1;\n * }\n *\n * _.isPlainObject(new Foo);\n * // => false\n *\n * _.isPlainObject([1, 2, 3]);\n * // => false\n *\n * _.isPlainObject({ 'x': 0, 'y': 0 });\n * // => true\n *\n * _.isPlainObject(Object.create(null));\n * // => true\n */\nfunction isPlainObject(value) {\n  if (!isObjectLike(value) || baseGetTag(value) != objectTag) {\n    return false;\n  }\n  var proto = getPrototype(value);\n  if (proto === null) {\n    return true;\n  }\n  var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor;\n  return typeof Ctor == 'function' && Ctor instanceof Ctor &&\n    funcToString.call(Ctor) == objectCtorString;\n}\n\nmodule.exports = isPlainObject;\n","import { each, empty, ArrayExt } from '@lumino/algorithm';\n\n// Copyright (c) Jupyter Development Team.\n/**\n * A generic B+ tree.\n *\n * #### Notes\n * Most operations have `O(log32 n)` or better complexity.\n */\nvar BPlusTree = /** @class */ (function () {\n    /**\n     * Construct a new B+ tree.\n     *\n     * @param cmp - The item comparison function for the tree.\n     */\n    function BPlusTree(cmp) {\n        this._root = new Private.LeafNode();\n        this.cmp = cmp;\n    }\n    Object.defineProperty(BPlusTree.prototype, \"isEmpty\", {\n        /**\n         * Whether the tree is empty.\n         *\n         * #### Complexity\n         * `O(1)`\n         */\n        get: function () {\n            return this._root.size === 0;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(BPlusTree.prototype, \"size\", {\n        /**\n         * The size of the tree.\n         *\n         * #### Complexity\n         * `O(1)`\n         */\n        get: function () {\n            return this._root.size;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(BPlusTree.prototype, \"first\", {\n        /**\n         * The first item in the tree.\n         *\n         * This is `undefined` if the tree is empty.\n         *\n         * #### Complexity\n         * `O(log32 n)`\n         */\n        get: function () {\n            var node = Private.firstLeaf(this._root);\n            return node.size > 0 ? node.items[0] : undefined;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(BPlusTree.prototype, \"last\", {\n        /**\n         * The last item in the tree.\n         *\n         * This is `undefined` if the tree is empty.\n         *\n         * #### Complexity\n         * `O(log32 n)`\n         */\n        get: function () {\n            var node = Private.lastLeaf(this._root);\n            return node.size > 0 ? node.items[node.size - 1] : undefined;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Create an iterator over the items in the tree.\n     *\n     * @returns A new iterator starting with the first item.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    BPlusTree.prototype.iter = function () {\n        return Private.iterItems(this._root);\n    };\n    /**\n     * Create a reverse iterator over the items in the tree.\n     *\n     * @returns A new iterator starting with the last item.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    BPlusTree.prototype.retro = function () {\n        return Private.retroItems(this._root);\n    };\n    /**\n     * Create an iterator for a slice of items in the tree.\n     *\n     * @param start - The index of the first item, inclusive. This\n     *   should be `< stop`. Negative values are taken as an offset\n     *   from the end of the tree. The default is `0`.\n     *\n     * @param stop - The index of the last item, exclusive. This\n     *   should be `> start`. Negative values are taken as an offset\n     *   from the end of the tree. The default is `size`.\n     *\n     * @returns A new iterator starting with the specified item.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    BPlusTree.prototype.slice = function (start, stop) {\n        return Private.sliceItems(this._root, start, stop);\n    };\n    /**\n     * Create a reverse iterator for a slice of items in the tree.\n     *\n     * @param start - The index of the first item, inclusive. This\n     *   should be `> stop`. Negative values are taken as an offset\n     *   from the end of the tree. The default is `size - 1`.\n     *\n     * @param stop - The index of the last item, exclusive. This\n     *   should be `< start`. Negative values are taken as an offset\n     *   from the end of the tree. The default is `-size - 1`.\n     *\n     * @returns A new reverse iterator starting with the specified item.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    BPlusTree.prototype.retroSlice = function (start, stop) {\n        return Private.retroSliceItems(this._root, start, stop);\n    };\n    /**\n     * Get the item at a particular index.\n     *\n     * @param index - The index of the item of interest. Negative\n     *   values are taken as an offset from the end of the tree.\n     *\n     * @returns The item at the specified index, or `undefined` if\n     *   the index is out of range.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    BPlusTree.prototype.at = function (index) {\n        return Private.itemAt(this._root, index);\n    };\n    /**\n     * Test whether the tree has an item which matches a key.\n     *\n     * @param key - The key of interest.\n     *\n     * @param cmp - A function which compares an item against the key.\n     *\n     * @returns `true` if the tree has an item which matches the given\n     *   key, `false` otherwise.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    BPlusTree.prototype.has = function (key, cmp) {\n        return Private.hasItem(this._root, key, cmp);\n    };\n    /**\n     * Get the index of an item which matches a key.\n     *\n     * @param key - The key of interest.\n     *\n     * @param cmp - A function which compares an item against the key.\n     *\n     * @returns The index of the item which matches the given key. A\n     *   negative value means that a matching item does not exist in\n     *   the tree, but if one did it would reside at `-index - 1`.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    BPlusTree.prototype.indexOf = function (key, cmp) {\n        return Private.indexOf(this._root, key, cmp);\n    };\n    /**\n     * Get the item which matches a key.\n     *\n     * @param item - The key of interest.\n     *\n     * @param cmp - A function which compares an item against the key.\n     *\n     * @returns The item which matches the given key, or `undefined` if\n     *   the tree does not have a matching item.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    BPlusTree.prototype.get = function (key, cmp) {\n        return Private.getItem(this._root, key, cmp);\n    };\n    /**\n     * Assign new items to the tree, replacing all current items.\n     *\n     * @param items - The items to assign to the tree.\n     *\n     * #### Complexity\n     * `O(n log32 n)`\n     */\n    BPlusTree.prototype.assign = function (items) {\n        this.clear();\n        this.update(items);\n    };\n    /**\n     * Insert an item into the tree.\n     *\n     * @param item - The item of interest.\n     *\n     * @returns If the given item matches an existing item in the tree,\n     *   the given item will replace it, and the existing item will be\n     *   returned. Otherwise, this method returns `undefined`.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    BPlusTree.prototype.insert = function (item) {\n        var existing = Private.insertItem(this._root, item, this.cmp);\n        this._root = Private.maybeSplitRoot(this._root);\n        return existing;\n    };\n    /**\n     * Update the tree with multiple items.\n     *\n     * @param items - The items to insert into the tree.\n     *\n     * #### Complexity\n     * `O(k log32 n)`\n     */\n    BPlusTree.prototype.update = function (items) {\n        var _this = this;\n        each(items, function (item) { _this.insert(item); });\n    };\n    /**\n     * Delete an item which matches a particular key.\n     *\n     * @param key - The key of interest.\n     *\n     * @param cmp - A function which compares an item against the key.\n     *\n     * @returns The item removed from the tree, or `undefined` if no\n     *   item matched the given key.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    BPlusTree.prototype.delete = function (key, cmp) {\n        var item = Private.deleteItem(this._root, key, cmp);\n        this._root = Private.maybeExtractRoot(this._root);\n        return item;\n    };\n    /**\n     * Remove an item at a particular index.\n     *\n     * @param index - The index of the item to remove. Negative\n     *   values are taken as an offset from the end of the tree.\n     *\n     * @returns The item removed from the tree, or `undefined` if\n     *   the given index is out of range.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    BPlusTree.prototype.remove = function (index) {\n        var item = Private.removeItem(this._root, index);\n        this._root = Private.maybeExtractRoot(this._root);\n        return item;\n    };\n    /**\n     * Clear the contents of the tree.\n     *\n     * #### Complexity\n     * `O(n)`\n     */\n    BPlusTree.prototype.clear = function () {\n        Private.clear(this._root);\n        this._root = new Private.LeafNode();\n    };\n    return BPlusTree;\n}());\n/**\n * The namespace for the `BPlusTree` class statics.\n */\n(function (BPlusTree) {\n    /**\n     * Create a new B+ tree populated with the given items.\n     *\n     * @param items - The items to add to the tree.\n     *\n     * @param cmp - The item comparison function for the tree.\n     *\n     * @returns A new B+ tree populated with the given items.\n     *\n     * #### Complexity\n     * `O(n log32 n)`\n     */\n    function from(items, cmp) {\n        var tree = new BPlusTree(cmp);\n        tree.assign(items);\n        return tree;\n    }\n    BPlusTree.from = from;\n})(BPlusTree || (BPlusTree = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private;\n(function (Private) {\n    /**\n     * A branch node in a B+ tree.\n     */\n    var BranchNode = /** @class */ (function () {\n        function BranchNode() {\n            /**\n             * The left-most item of each child subtree.\n             */\n            this.items = [];\n            /**\n             * The cumulative sizes of each child subtree.\n             */\n            this.sizes = [];\n            /**\n             * The child nodes of this branch node.\n             */\n            this.children = [];\n        }\n        Object.defineProperty(BranchNode.prototype, \"type\", {\n            /**\n             * The discriminated type of the node.\n             */\n            get: function () {\n                return 0 /* Branch */;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(BranchNode.prototype, \"size\", {\n            /**\n             * The total number of items in the subtree.\n             */\n            get: function () {\n                return this.sizes[this.sizes.length - 1];\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(BranchNode.prototype, \"width\", {\n            /**\n             * The tree width of the node.\n             */\n            get: function () {\n                return this.children.length;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        return BranchNode;\n    }());\n    Private.BranchNode = BranchNode;\n    /**\n     * A leaf node in a B+ tree.\n     */\n    var LeafNode = /** @class */ (function () {\n        function LeafNode() {\n            /**\n             * The next sibling leaf node of this leaf node.\n             */\n            this.next = null;\n            /**\n             * The previous sibling leaf node of this leaf node.\n             */\n            this.prev = null;\n            /**\n             * The items of the leaf.\n             */\n            this.items = [];\n        }\n        Object.defineProperty(LeafNode.prototype, \"type\", {\n            /**\n             * The discriminated type of the node.\n             */\n            get: function () {\n                return 1 /* Leaf */;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(LeafNode.prototype, \"size\", {\n            /**\n             * The total number of items in the leaf.\n             */\n            get: function () {\n                return this.items.length;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        Object.defineProperty(LeafNode.prototype, \"width\", {\n            /**\n             * The tree width of the node.\n             */\n            get: function () {\n                return this.items.length;\n            },\n            enumerable: true,\n            configurable: true\n        });\n        return LeafNode;\n    }());\n    Private.LeafNode = LeafNode;\n    /**\n     * Get the first leaf node in the tree.\n     *\n     * @param node - The root node of interest.\n     *\n     * @returns The first leaf node in the tree.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    function firstLeaf(node) {\n        while (node.type === 0 /* Branch */) {\n            node = node.children[0];\n        }\n        return node;\n    }\n    Private.firstLeaf = firstLeaf;\n    /**\n     * Get the last leaf node in the tree.\n     *\n     * @param node - The root node of interest.\n     *\n     * @returns The last leaf node in the tree.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    function lastLeaf(node) {\n        while (node.type === 0 /* Branch */) {\n            node = node.children[node.children.length - 1];\n        }\n        return node;\n    }\n    Private.lastLeaf = lastLeaf;\n    /**\n     * Create a forward iterator for the items in the tree.\n     *\n     * @param node - The root node of interest.\n     *\n     * @returns A new forward iterator starting with the first item.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    function iterItems(node) {\n        var leaf = firstLeaf(node);\n        return new ForwardIterator(leaf, 0, -1);\n    }\n    Private.iterItems = iterItems;\n    /**\n     * Create a reverse iterator for the items in the tree.\n     *\n     * @param node - The root node of interest.\n     *\n     * @returns A new reverse iterator starting with the last item.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    function retroItems(node) {\n        var leaf = lastLeaf(node);\n        return new RetroIterator(leaf, leaf.size - 1, -1);\n    }\n    Private.retroItems = retroItems;\n    /**\n     * Create an iterator for a slice of items in the tree.\n     *\n     * @param node - The root node of interest.\n     *\n     * @param start - The index of the first item, inclusive. This\n     *   should be `< stop`. Negative values are taken as an offset\n     *   from the end of the tree. The default is `0`.\n     *\n     * @param stop - The index of the last item, exclusive. This\n     *   should be `> start`. Negative values are taken as an offset\n     *   from the end of the tree. The default is `size`.\n     *\n     * @returns A new iterator starting with the specified item.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    function sliceItems(node, start, stop) {\n        // Normalize the start index.\n        if (start === undefined) {\n            start = 0;\n        }\n        else if (start < 0) {\n            start = Math.max(0, start + node.size);\n        }\n        else {\n            start = Math.min(start, node.size);\n        }\n        // Normalize the stop index.\n        if (stop === undefined) {\n            stop = node.size;\n        }\n        else if (stop < 0) {\n            stop = Math.max(0, stop + node.size);\n        }\n        else {\n            stop = Math.min(stop, node.size);\n        }\n        // Compute effective count.\n        var count = Math.max(0, stop - start);\n        // Bail early if there is nothing to iterate.\n        if (count === 0) {\n            return empty();\n        }\n        // Find the starting leaf node and local index.\n        while (node.type === 0 /* Branch */) {\n            var i = findPivotIndexByIndex(node.sizes, start);\n            if (i > 0)\n                start -= node.sizes[i - 1];\n            node = node.children[i];\n        }\n        // Return the forward iterator for the range.\n        return new ForwardIterator(node, start, count);\n    }\n    Private.sliceItems = sliceItems;\n    /**\n     * Create a reverse iterator for a slice of items in the tree.\n     *\n     * @param node - The root node of interest.\n     *\n     * @param start - The index of the first item, inclusive. This\n     *   should be `> stop`. Negative values are taken as an offset\n     *   from the end of the tree. The default is `size - 1`.\n     *\n     * @param stop - The index of the last item, exclusive. This\n     *   should be `< start`. Negative values are taken as an offset\n     *   from the end of the tree. The default is `-size - 1`.\n     *\n     * @returns A new reverse iterator starting with the specified item.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    function retroSliceItems(node, start, stop) {\n        // Normalize the start index.\n        if (start === undefined) {\n            start = node.size - 1;\n        }\n        else if (start < 0) {\n            start = Math.max(-1, start + node.size);\n        }\n        else {\n            start = Math.min(start, node.size - 1);\n        }\n        // Normalize the stop index.\n        if (stop === undefined) {\n            stop = -1;\n        }\n        else if (stop < 0) {\n            stop = Math.max(-1, stop + node.size);\n        }\n        else {\n            stop = Math.min(stop, node.size - 1);\n        }\n        // Compute the effective count.\n        var count = Math.max(0, start - stop);\n        // Bail early if there is nothing to iterate.\n        if (count === 0) {\n            return empty();\n        }\n        // Find the starting leaf node and local index.\n        while (node.type === 0 /* Branch */) {\n            var i = findPivotIndexByIndex(node.sizes, start);\n            if (i > 0)\n                start -= node.sizes[i - 1];\n            node = node.children[i];\n        }\n        // Return the retro iterator for the range.\n        return new RetroIterator(node, start, count);\n    }\n    Private.retroSliceItems = retroSliceItems;\n    /**\n     * Get the item at the specified index.\n     *\n     * @param node - The root node of interest.\n     *\n     * @param index - The index of the item of interest. Negative\n     *   values are taken as an offset from the end of the tree.\n     *\n     * @returns The item at the specified index, or `undefined` if\n     *   the index is out of range.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    function itemAt(node, index) {\n        // Wrap negative indices.\n        if (index < 0) {\n            index += node.size;\n        }\n        // Bail early if the index is out of range.\n        if (index < 0 || index >= node.size) {\n            return undefined;\n        }\n        // Find the containing leaf node and local index.\n        while (node.type === 0 /* Branch */) {\n            var i = findPivotIndexByIndex(node.sizes, index);\n            if (i > 0)\n                index -= node.sizes[i - 1];\n            node = node.children[i];\n        }\n        // Return the item at the specified index.\n        return node.items[index];\n    }\n    Private.itemAt = itemAt;\n    /**\n     * Test whether the tree contains an item which matches a key.\n     *\n     * @param node - The root node of interest.\n     *\n     * @param key - The key of interest.\n     *\n     * @param cmp - The key comparison function.\n     *\n     * @returns Whether the tree contains a matching item.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    function hasItem(node, key, cmp) {\n        // Find the containing leaf node.\n        while (node.type === 0 /* Branch */) {\n            var i_1 = findPivotIndexByKey(node.items, key, cmp);\n            node = node.children[i_1];\n        }\n        // Find the key index.\n        var i = findKeyIndex(node.items, key, cmp);\n        // Return whether or not the node contains a matching item.\n        return i >= 0;\n    }\n    Private.hasItem = hasItem;\n    /**\n     * Get the index of the item which matches a key.\n     *\n     * @param node - The node of interest.\n     *\n     * @param key - The key of interest.\n     *\n     * @param cmp - The key comparison function.\n     *\n     * @returns The index of the item which matches the given key. A\n     *   negative value means that a matching item does not exist in\n     *   the tree, but if one did it would reside at `-index - 1`.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    function indexOf(node, key, cmp) {\n        // Set up the global index.\n        var index = 0;\n        // Find the containing leaf node and global index.\n        while (node.type === 0 /* Branch */) {\n            var i_2 = findPivotIndexByKey(node.items, key, cmp);\n            if (i_2 > 0)\n                index += node.sizes[i_2 - 1];\n            node = node.children[i_2];\n        }\n        // Find the key index.\n        var i = findKeyIndex(node.items, key, cmp);\n        // Return the final computed index.\n        return i >= 0 ? index + i : -index + i;\n    }\n    Private.indexOf = indexOf;\n    /**\n     * Get the item for a particular key.\n     *\n     * @param node - The node of interest.\n     *\n     * @param key - The key of interest.\n     *\n     * @param cmp - The key comparison function.\n     *\n     * @returns The item for the specified key, or `undefined` if\n     *   the tree does not have a matching item for the key.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     */\n    function getItem(node, key, cmp) {\n        // Find the containing leaf node.\n        while (node.type === 0 /* Branch */) {\n            var i_3 = findPivotIndexByKey(node.items, key, cmp);\n            node = node.children[i_3];\n        }\n        // Find the key index.\n        var i = findKeyIndex(node.items, key, cmp);\n        // Return the item for the given key.\n        return i >= 0 ? node.items[i] : undefined;\n    }\n    Private.getItem = getItem;\n    /**\n     * Insert an item into the tree.\n     *\n     * @param node - The root node of interest.\n     *\n     * @param item - The item of interest.\n     *\n     * @param cmp - The item comparison function.\n     *\n     * @returns If the given item matches an existing item in the tree,\n     *   the given item will replace it, and the existing item will be\n     *   returned. Otherwise, this function returns `undefined`.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     *\n     * #### Notes\n     * The root may be overfull after calling this function.\n     */\n    function insertItem(node, item, cmp) {\n        // Handle leaf nodes first.\n        if (node.type === 1 /* Leaf */) {\n            // Find the index for the given item.\n            var i_4 = findKeyIndex(node.items, item, cmp);\n            // Fetch the existing item and insert the new item.\n            var existing_1;\n            if (i_4 >= 0) {\n                existing_1 = node.items[i_4];\n                node.items[i_4] = item;\n            }\n            else {\n                existing_1 = undefined;\n                ArrayExt.insert(node.items, -i_4 - 1, item);\n            }\n            // Return the existing item.\n            return existing_1;\n        }\n        // Find the pivot index for the insert.\n        var i = findPivotIndexByKey(node.items, item, cmp);\n        // Fetch the pivot child.\n        var child = node.children[i];\n        // Fetch the current size of the child.\n        var prevSize = child.size;\n        // Recursively insert the item into the child.\n        var existing = insertItem(child, item, cmp);\n        // Fetch the updated size of the child.\n        var currSize = child.size;\n        // Update the item state of the branch.\n        node.items[i] = child.items[0];\n        // Bail early if the child size did not change.\n        if (prevSize === currSize) {\n            return existing;\n        }\n        // Split the child if it's overfull.\n        if (child.width > MAX_NODE_WIDTH) {\n            var next = splitNode(child);\n            ArrayExt.insert(node.children, i + 1, next);\n            ArrayExt.insert(node.items, i + 1, next.items[0]);\n        }\n        // Update the dirty sizes of the branch.\n        updateSizes(node, i);\n        // Return the existing item.\n        return existing;\n    }\n    Private.insertItem = insertItem;\n    /**\n     * Delete an item in the tree.\n     *\n     * @param node - The node of interest.\n     *\n     * @param key - The key of interest.\n     *\n     * @param cmp - The key comparison function.\n     *\n     * @returns The deleted item or `undefined`.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     *\n     * #### Notes\n     * The root may be underfull after calling this function.\n     */\n    function deleteItem(node, key, cmp) {\n        // Handle leaf nodes first.\n        if (node.type === 1 /* Leaf */) {\n            // Find the index for the given key.\n            var i_5 = findKeyIndex(node.items, key, cmp);\n            // Bail early if the item does not exist.\n            if (i_5 < 0) {\n                return undefined;\n            }\n            // Remove the item at the computed index.\n            return ArrayExt.removeAt(node.items, i_5);\n        }\n        // Find the pivot index for the delete.\n        var i = findPivotIndexByKey(node.items, key, cmp);\n        // Fetch the pivot child.\n        var child = node.children[i];\n        // Fetch the current size of the child.\n        var prevSize = child.size;\n        // Recursively remove the item from the child.\n        var item = deleteItem(child, key, cmp);\n        // Fetch the updated size of the child.\n        var currSize = child.size;\n        // Bail early if the child size did not change.\n        if (prevSize === currSize) {\n            return item;\n        }\n        // Update the item state of the branch.\n        node.items[i] = child.items[0];\n        // Join the child if it's underfull.\n        if (child.width < MIN_NODE_WIDTH) {\n            i = joinChild(node, i);\n        }\n        // Update the dirty sizes of the branch.\n        updateSizes(node, i);\n        // Return the deleted item.\n        return item;\n    }\n    Private.deleteItem = deleteItem;\n    /**\n     * Remove an item from the tree.\n     *\n     * @param node - The node of interest.\n     *\n     * @param index - The index of interest.\n     *\n     * @returns The removed item or `undefined`.\n     *\n     * #### Complexity\n     * `O(log32 n)`\n     *\n     * #### Notes\n     * The root may be underfull after calling this function.\n     */\n    function removeItem(node, index) {\n        // Wrap negative indices.\n        if (index < 0) {\n            index += node.size;\n        }\n        // Bail early if the index is out of range.\n        if (index < 0 || index >= node.size) {\n            return undefined;\n        }\n        // Handle leaf nodes first.\n        if (node.type === 1 /* Leaf */) {\n            return ArrayExt.removeAt(node.items, index);\n        }\n        // Find the pivot index for the remove.\n        var i = findPivotIndexByIndex(node.sizes, index);\n        if (i > 0)\n            index -= node.sizes[i];\n        // Fetch the pivot child.\n        var child = node.children[i];\n        // Recursively remove the item from the child.\n        var item = removeItem(child, index);\n        // Update the item state of the branch.\n        node.items[i] = child.items[0];\n        // Join the child if it's underfull.\n        if (child.width < MIN_NODE_WIDTH) {\n            i = joinChild(node, i);\n        }\n        // Update the dirty sizes of the branch.\n        updateSizes(node, i);\n        // Return the removed item.\n        return item;\n    }\n    Private.removeItem = removeItem;\n    /**\n     * Recursively clear the contents of a node.\n     *\n     * @param node - The node of interest.\n     *\n     * #### Complexity\n     * `O(n)`\n     */\n    function clear(node) {\n        if (node.type === 0 /* Branch */) {\n            each(node.children, clear);\n            node.children.length = 0;\n            node.sizes.length = 0;\n            node.items.length = 0;\n        }\n        else {\n            node.items.length = 0;\n            node.next = null;\n            node.prev = null;\n        }\n    }\n    Private.clear = clear;\n    /**\n     * Split a root node and create a new root, if needed.\n     *\n     * @param node - The root node of interest.\n     *\n     * @returns The new root node.\n     */\n    function maybeSplitRoot(node) {\n        // Bail early if the current root is not overfull.\n        if (node.width <= MAX_NODE_WIDTH) {\n            return node;\n        }\n        // Create a new root branch node.\n        var root = new BranchNode();\n        // Split the node to the right and create a new sibling.\n        var next = splitNode(node);\n        // Add the sizes to the root.\n        root.sizes[0] = node.size;\n        root.sizes[1] = node.size + next.size;\n        // Add the children to the root.\n        root.children[0] = node;\n        root.children[1] = next;\n        // Add the items to the root.\n        root.items[0] = node.items[0];\n        root.items[1] = next.items[0];\n        // Return the new root node.\n        return root;\n    }\n    Private.maybeSplitRoot = maybeSplitRoot;\n    /**\n     * Extract a single node child as a new root, if needed.\n     *\n     * @param node - The root node of interest.\n     *\n     * @returns The new root node.\n     */\n    function maybeExtractRoot(node) {\n        // Bail early if the node it already a leaf.\n        if (node.type === 1 /* Leaf */) {\n            return node;\n        }\n        // Bail early if the branch has more than one child.\n        if (node.children.length > 1) {\n            return node;\n        }\n        // Extract the sole remaining child as the new root.\n        var root = node.children.pop();\n        // Clear the rest of the node state.\n        clear(node);\n        // Return the new root.\n        return root;\n    }\n    Private.maybeExtractRoot = maybeExtractRoot;\n    /**\n     * The maximum width for a node in the tree.\n     */\n    var MAX_NODE_WIDTH = 32;\n    /**\n     * The minimum width for a node in the tree.\n     */\n    var MIN_NODE_WIDTH = MAX_NODE_WIDTH >> 1;\n    /**\n     * A forward iterator for a B+ tree.\n     */\n    var ForwardIterator = /** @class */ (function () {\n        /**\n         * Construct a new forward iterator.\n         *\n         * @param node - The first leaf node in the chain.\n         *\n         * @param index - The local index of the first item.\n         *\n         * @param count - The number of items to iterate. A value `< 0`\n         *   will iterate all available items.\n         */\n        function ForwardIterator(node, index, count) {\n            this._node = node;\n            this._index = index;\n            this._count = count;\n        }\n        /**\n         * Get an iterator over the object's values.\n         *\n         * @returns An iterator which yields the object's values.\n         */\n        ForwardIterator.prototype.iter = function () {\n            return this;\n        };\n        /**\n         * Create an independent clone of the iterator.\n         *\n         * @returns A new independent clone of the iterator.\n         */\n        ForwardIterator.prototype.clone = function () {\n            return new ForwardIterator(this._node, this._index, this._count);\n        };\n        /**\n         * Get the next value from the iterator.\n         *\n         * @returns The next value from the iterator, or `undefined`.\n         */\n        ForwardIterator.prototype.next = function () {\n            if (this._node === null || this._count === 0) {\n                return undefined;\n            }\n            if (this._index >= this._node.size) {\n                this._node = this._node.next;\n                this._index = 0;\n                return this.next();\n            }\n            if (this._count > 0) {\n                this._count--;\n            }\n            return this._node.items[this._index++];\n        };\n        return ForwardIterator;\n    }());\n    /**\n     * A reverse iterator for a B+ tree.\n     */\n    var RetroIterator = /** @class */ (function () {\n        /**\n         * Construct a new retro iterator.\n         *\n         * @param node - The last leaf node in the chain.\n         *\n         * @param index - The local index of the last item.\n         *\n         * @param count - The number of items to iterate. A value `< 0`\n         *   will iterate all available items.\n         */\n        function RetroIterator(node, index, count) {\n            this._node = node;\n            this._index = index;\n            this._count = count;\n        }\n        /**\n         * Get an iterator over the object's values.\n         *\n         * @returns An iterator which yields the object's values.\n         */\n        RetroIterator.prototype.iter = function () {\n            return this;\n        };\n        /**\n         * Create an independent clone of the iterator.\n         *\n         * @returns A new independent clone of the iterator.\n         */\n        RetroIterator.prototype.clone = function () {\n            return new RetroIterator(this._node, this._index, this._count);\n        };\n        /**\n         * Get the next value from the iterator.\n         *\n         * @returns The next value from the iterator, or `undefined`.\n         */\n        RetroIterator.prototype.next = function () {\n            if (this._node === null || this._count === 0) {\n                return undefined;\n            }\n            if (this._index >= this._node.size) {\n                this._index = this._node.size - 1;\n            }\n            if (this._index < 0) {\n                this._node = this._node.prev;\n                this._index = this._node ? this._node.size - 1 : -1;\n                return this.next();\n            }\n            if (this._count > 0) {\n                this._count--;\n            }\n            return this._node.items[this._index--];\n        };\n        return RetroIterator;\n    }());\n    /**\n     * Find the pivot index for a particular local index.\n     */\n    function findPivotIndexByIndex(sizes, index) {\n        var n = sizes.length;\n        for (var i = 0; i < n; ++i) {\n            if (sizes[i] > index) {\n                return i;\n            }\n        }\n        return n - 1;\n    }\n    /**\n     * Find the pivot index for a particular key.\n     */\n    function findPivotIndexByKey(items, key, cmp) {\n        var n = items.length;\n        for (var i = 1; i < n; ++i) {\n            if (cmp(items[i], key) > 0) {\n                return i - 1;\n            }\n        }\n        return n - 1;\n    }\n    /**\n     * Find the key index for a particular key.\n     */\n    function findKeyIndex(items, key, cmp) {\n        var n = items.length;\n        for (var i = 0; i < n; ++i) {\n            var c = cmp(items[i], key);\n            if (c === 0) {\n                return i;\n            }\n            if (c > 0) {\n                return -i - 1;\n            }\n        }\n        return -n - 1;\n    }\n    /**\n     * Update the sizes of a branch node starting at the given index.\n     */\n    function updateSizes(node, i) {\n        var sizes = node.sizes, children = node.children;\n        var last = i > 0 ? sizes[i - 1] : 0;\n        for (var n = children.length; i < n; ++i) {\n            last = sizes[i] = last + children[i].size;\n        }\n        sizes.length = children.length;\n    }\n    /**\n     * Split a node and return its new next sibling.\n     *\n     * @param node - The node of interest.\n     *\n     * @returns The new next sibling node.\n     */\n    function splitNode(node) {\n        // Handle leaf nodes first.\n        if (node.type === 1 /* Leaf */) {\n            // Create the new sibling leaf node.\n            var next_1 = new LeafNode();\n            // Move the items to the new sibling.\n            var v1_1 = node.items;\n            var v2_1 = next_1.items;\n            for (var i = MIN_NODE_WIDTH, n = v1_1.length; i < n; ++i) {\n                v2_1.push(v1_1[i]);\n            }\n            v1_1.length = MIN_NODE_WIDTH;\n            // Patch up the sibling links.\n            if (node.next)\n                node.next.prev = next_1;\n            next_1.next = node.next;\n            next_1.prev = node;\n            node.next = next_1;\n            // Return the new next sibling.\n            return next_1;\n        }\n        // Create the new sibling branch node.\n        var next = new BranchNode();\n        // Move the children to the new sibling.\n        var c1 = node.children;\n        var c2 = next.children;\n        for (var i = MIN_NODE_WIDTH, n = c1.length; i < n; ++i) {\n            c2.push(c1[i]);\n        }\n        c1.length = MIN_NODE_WIDTH;\n        // Move the items to the new sibling.\n        var v1 = node.items;\n        var v2 = next.items;\n        for (var i = MIN_NODE_WIDTH, n = v1.length; i < n; ++i) {\n            v2.push(v1[i]);\n        }\n        v1.length = MIN_NODE_WIDTH;\n        // Update the dirty sizes of the nodes.\n        updateSizes(node, MIN_NODE_WIDTH);\n        updateSizes(next, 0);\n        // Return the new next sibling.\n        return next;\n    }\n    /**\n     * Join a child node of a branch with one of its siblings.\n     *\n     * @param node - The branch node of interest.\n     *\n     * @param i - The index of the child node of interest.\n     *\n     * @returns The first modified index.\n     *\n     * #### Notes\n     * This may cause the branch to become underfull.\n     */\n    function joinChild(node, i) {\n        var _a, _b, _c, _d, _e, _f;\n        // Fetch the child to be joined.\n        var child = node.children[i];\n        // Fetch the relevant sibling.\n        var sibling = i === 0 ? node.children[i + 1] : node.children[i - 1];\n        // Compute the flags which control the join behavior.\n        var hasNext = i === 0;\n        var isLeaf = child.type === 1 /* Leaf */;\n        var hasExtra = sibling.width > MIN_NODE_WIDTH;\n        // Join case #1: steal from next sibling leaf\n        if (isLeaf && hasExtra && hasNext) {\n            // Cast the children as leaves.\n            var c = child;\n            var s = sibling;\n            // Steal an item.\n            c.items.push(s.items.shift());\n            // Update the branch items.\n            node.items[i + 1] = s.items[0];\n            // Return the first modified index.\n            return i;\n        }\n        // Join case #2: steal from previous sibling leaf\n        if (isLeaf && hasExtra && !hasNext) {\n            // Cast the children as leaves.\n            var c = child;\n            var s = sibling;\n            // Steal an item.\n            c.items.unshift(s.items.pop());\n            // Update the branch items.\n            node.items[i] = c.items[0];\n            // Return the first modified index.\n            return i - 1;\n        }\n        // Join case #3: merge with next sibling leaf\n        if (isLeaf && !hasExtra && hasNext) {\n            // Cast the children as leaves.\n            var c = child;\n            var s = sibling;\n            // Merge items.\n            (_a = s.items).unshift.apply(_a, c.items);\n            // Remove the old branch child.\n            ArrayExt.removeAt(node.children, i);\n            // Remove the stale branch item.\n            ArrayExt.removeAt(node.items, i + 1);\n            // Patch up the sibling links.\n            if (c.prev)\n                c.prev.next = s;\n            s.prev = c.prev;\n            // Clear the original child.\n            clear(c);\n            // Return the first modified index.\n            return i;\n        }\n        // Join case #4: merge with previous sibling leaf\n        if (isLeaf && !hasExtra && !hasNext) {\n            // Cast the children as leaves.\n            var c = child;\n            var s = sibling;\n            // Merge items.\n            (_b = s.items).push.apply(_b, c.items);\n            // Remove the old branch child.\n            ArrayExt.removeAt(node.children, i);\n            // Remove the stale branch item.\n            ArrayExt.removeAt(node.items, i);\n            // Patch up the sibling links.\n            if (c.next)\n                c.next.prev = s;\n            s.next = c.next;\n            // Clear the original child.\n            clear(c);\n            // Return the first modified index.\n            return i - 1;\n        }\n        // Join case #5: steal from next sibling branch\n        if (!isLeaf && hasExtra && hasNext) {\n            // Cast the children to branches.\n            var c = child;\n            var s = sibling;\n            // Steal a child from the next sibling.\n            c.children.push(s.children.shift());\n            // Steal an item from the next sibling.\n            c.items.push(s.items.shift());\n            // Update the branch items.\n            node.items[i + 1] = s.items[0];\n            // Update the sibling sizes.\n            updateSizes(c, c.width - 1);\n            updateSizes(s, 0);\n            // Return the first modified index.\n            return i;\n        }\n        // Join case #6: steal from previous sibling branch\n        if (!isLeaf && hasExtra && !hasNext) {\n            // Cast the children to branches.\n            var c = child;\n            var s = sibling;\n            // Steal a child from the previous sibling.\n            c.children.unshift(s.children.pop());\n            // Steal an item from the previous sibling.\n            c.items.unshift(s.items.pop());\n            // Update the branch items.\n            node.items[i] = c.items[0];\n            // Update the sibling sizes.\n            updateSizes(c, 0);\n            updateSizes(s, s.width - 1);\n            // Return the first modified index.\n            return i - 1;\n        }\n        // Join case #7: merge with next sibling branch\n        if (!isLeaf && !hasExtra && hasNext) {\n            // Cast the children to branches.\n            var c = child;\n            var s = sibling;\n            // Merge the children with the next sibling.\n            (_c = s.children).unshift.apply(_c, c.children);\n            // Merge the items with the next sibling.\n            (_d = s.items).unshift.apply(_d, c.items);\n            // Remove the old branch child.\n            ArrayExt.removeAt(node.children, i);\n            // Remove the stale branch item.\n            ArrayExt.removeAt(node.items, i + 1);\n            // Update the sibling sizes.\n            updateSizes(s, 0);\n            // Clear the original child but, not its children.\n            c.children.length = 0;\n            clear(c);\n            // Return the first modified index.\n            return i;\n        }\n        // Join case #8: merge with previous sibling branch\n        if (!isLeaf && !hasExtra && !hasNext) {\n            // Cast the children to branches.\n            var c = child;\n            var s = sibling;\n            // Merge the children with the previous sibling.\n            (_e = s.children).push.apply(_e, c.children);\n            // Merge the items with the previous sibling.\n            (_f = s.items).push.apply(_f, c.items);\n            // Remove the old branch child.\n            ArrayExt.removeAt(node.children, i);\n            // Remove the stale branch item.\n            ArrayExt.removeAt(node.items, i);\n            // Update the sibling sizes.\n            updateSizes(s, 0);\n            // Clear the original child, but not its children.\n            c.children.length = 0;\n            clear(c);\n            // Return the first modified index.\n            return i - 1;\n        }\n        // One of the above cases must match.\n        throw 'unreachable';\n    }\n})(Private || (Private = {}));\n\n// Copyright (c) Jupyter Development Team.\n/**\n * A generic doubly-linked list.\n */\nvar LinkedList = /** @class */ (function () {\n    /**\n     * Construct a new linked list.\n     */\n    function LinkedList() {\n        this._first = null;\n        this._last = null;\n        this._size = 0;\n    }\n    Object.defineProperty(LinkedList.prototype, \"isEmpty\", {\n        /**\n         * Whether the list is empty.\n         *\n         * #### Complexity\n         * Constant.\n         */\n        get: function () {\n            return this._size === 0;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LinkedList.prototype, \"size\", {\n        /**\n         * The size of the list.\n         *\n         * #### Complexity\n         * `O(1)`\n         *\n         * #### Notes\n         * This is equivalent to `length`.\n         */\n        get: function () {\n            return this._size;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LinkedList.prototype, \"length\", {\n        /**\n         * The length of the list.\n         *\n         * #### Complexity\n         * Constant.\n         *\n         * #### Notes\n         * This is equivalent to `size`.\n         *\n         * This property is deprecated.\n         */\n        get: function () {\n            return this._size;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LinkedList.prototype, \"first\", {\n        /**\n         * The first value in the list.\n         *\n         * This is `undefined` if the list is empty.\n         *\n         * #### Complexity\n         * Constant.\n         */\n        get: function () {\n            return this._first ? this._first.value : undefined;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LinkedList.prototype, \"last\", {\n        /**\n         * The last value in the list.\n         *\n         * This is `undefined` if the list is empty.\n         *\n         * #### Complexity\n         * Constant.\n         */\n        get: function () {\n            return this._last ? this._last.value : undefined;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LinkedList.prototype, \"firstNode\", {\n        /**\n         * The first node in the list.\n         *\n         * This is `null` if the list is empty.\n         *\n         * #### Complexity\n         * Constant.\n         */\n        get: function () {\n            return this._first;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    Object.defineProperty(LinkedList.prototype, \"lastNode\", {\n        /**\n         * The last node in the list.\n         *\n         * This is `null` if the list is empty.\n         *\n         * #### Complexity\n         * Constant.\n         */\n        get: function () {\n            return this._last;\n        },\n        enumerable: true,\n        configurable: true\n    });\n    /**\n     * Create an iterator over the values in the list.\n     *\n     * @returns A new iterator starting with the first value.\n     *\n     * #### Complexity\n     * Constant.\n     */\n    LinkedList.prototype.iter = function () {\n        return new LinkedList.ForwardValueIterator(this._first);\n    };\n    /**\n     * Create a reverse iterator over the values in the list.\n     *\n     * @returns A new iterator starting with the last value.\n     *\n     * #### Complexity\n     * Constant.\n     */\n    LinkedList.prototype.retro = function () {\n        return new LinkedList.RetroValueIterator(this._last);\n    };\n    /**\n     * Create an iterator over the nodes in the list.\n     *\n     * @returns A new iterator starting with the first node.\n     *\n     * #### Complexity\n     * Constant.\n     */\n    LinkedList.prototype.nodes = function () {\n        return new LinkedList.ForwardNodeIterator(this._first);\n    };\n    /**\n     * Create a reverse iterator over the nodes in the list.\n     *\n     * @returns A new iterator starting with the last node.\n     *\n     * #### Complexity\n     * Constant.\n     */\n    LinkedList.prototype.retroNodes = function () {\n        return new LinkedList.RetroNodeIterator(this._last);\n    };\n    /**\n     * Assign new values to the list, replacing all current values.\n     *\n     * @param values - The values to assign to the list.\n     *\n     * #### Complexity\n     * Linear.\n     */\n    LinkedList.prototype.assign = function (values) {\n        var _this = this;\n        this.clear();\n        each(values, function (value) { _this.addLast(value); });\n    };\n    /**\n     * Add a value to the end of the list.\n     *\n     * @param value - The value to add to the end of the list.\n     *\n     * #### Complexity\n     * Constant.\n     *\n     * #### Notes\n     * This is equivalent to `addLast`.\n     */\n    LinkedList.prototype.push = function (value) {\n        this.addLast(value);\n    };\n    /**\n     * Remove and return the value at the end of the list.\n     *\n     * @returns The removed value, or `undefined` if the list is empty.\n     *\n     * #### Complexity\n     * Constant.\n     *\n     * #### Notes\n     * This is equivalent to `removeLast`.\n     */\n    LinkedList.prototype.pop = function () {\n        return this.removeLast();\n    };\n    /**\n     * Add a value to the beginning of the list.\n     *\n     * @param value - The value to add to the beginning of the list.\n     *\n     * #### Complexity\n     * Constant.\n     *\n     * #### Notes\n     * This is equivalent to `addFirst`.\n     */\n    LinkedList.prototype.shift = function (value) {\n        this.addFirst(value);\n    };\n    /**\n     * Remove and return the value at the beginning of the list.\n     *\n     * @returns The removed value, or `undefined` if the list is empty.\n     *\n     * #### Complexity\n     * Constant.\n     *\n     * #### Notes\n     * This is equivalent to `removeFirst`.\n     */\n    LinkedList.prototype.unshift = function () {\n        return this.removeFirst();\n    };\n    /**\n     * Add a value to the beginning of the list.\n     *\n     * @param value - The value to add to the beginning of the list.\n     *\n     * @returns The list node which holds the value.\n     *\n     * #### Complexity\n     * Constant.\n     */\n    LinkedList.prototype.addFirst = function (value) {\n        var node = new Private$1.LinkedListNode(this, value);\n        if (!this._first) {\n            this._first = node;\n            this._last = node;\n        }\n        else {\n            node.next = this._first;\n            this._first.prev = node;\n            this._first = node;\n        }\n        this._size++;\n        return node;\n    };\n    /**\n     * Add a value to the end of the list.\n     *\n     * @param value - The value to add to the end of the list.\n     *\n     * @returns The list node which holds the value.\n     *\n     * #### Complexity\n     * Constant.\n     */\n    LinkedList.prototype.addLast = function (value) {\n        var node = new Private$1.LinkedListNode(this, value);\n        if (!this._last) {\n            this._first = node;\n            this._last = node;\n        }\n        else {\n            node.prev = this._last;\n            this._last.next = node;\n            this._last = node;\n        }\n        this._size++;\n        return node;\n    };\n    /**\n     * Insert a value before a specific node in the list.\n     *\n     * @param value - The value to insert before the reference node.\n     *\n     * @param ref - The reference node of interest. If this is `null`,\n     *   the value will be added to the beginning of the list.\n     *\n     * @returns The list node which holds the value.\n     *\n     * #### Notes\n     * The reference node must be owned by the list.\n     *\n     * #### Complexity\n     * Constant.\n     */\n    LinkedList.prototype.insertBefore = function (value, ref) {\n        if (!ref || ref === this._first) {\n            return this.addFirst(value);\n        }\n        if (!(ref instanceof Private$1.LinkedListNode) || ref.list !== this) {\n            throw new Error('Reference node is not owned by the list.');\n        }\n        var node = new Private$1.LinkedListNode(this, value);\n        var _ref = ref;\n        var prev = _ref.prev;\n        node.next = _ref;\n        node.prev = prev;\n        _ref.prev = node;\n        prev.next = node;\n        this._size++;\n        return node;\n    };\n    /**\n     * Insert a value after a specific node in the list.\n     *\n     * @param value - The value to insert after the reference node.\n     *\n     * @param ref - The reference node of interest. If this is `null`,\n     *   the value will be added to the end of the list.\n     *\n     * @returns The list node which holds the value.\n     *\n     * #### Notes\n     * The reference node must be owned by the list.\n     *\n     * #### Complexity\n     * Constant.\n     */\n    LinkedList.prototype.insertAfter = function (value, ref) {\n        if (!ref || ref === this._last) {\n            return this.addLast(value);\n        }\n        if (!(ref instanceof Private$1.LinkedListNode) || ref.list !== this) {\n            throw new Error('Reference node is not owned by the list.');\n        }\n        var node = new Private$1.LinkedListNode(this, value);\n        var _ref = ref;\n        var next = _ref.next;\n        node.next = next;\n        node.prev = _ref;\n        _ref.next = node;\n        next.prev = node;\n        this._size++;\n        return node;\n    };\n    /**\n     * Remove and return the value at the beginning of the list.\n     *\n     * @returns The removed value, or `undefined` if the list is empty.\n     *\n     * #### Complexity\n     * Constant.\n     */\n    LinkedList.prototype.removeFirst = function () {\n        var node = this._first;\n        if (!node) {\n            return undefined;\n        }\n        if (node === this._last) {\n            this._first = null;\n            this._last = null;\n        }\n        else {\n            this._first = node.next;\n            this._first.prev = null;\n        }\n        node.list = null;\n        node.next = null;\n        node.prev = null;\n        this._size--;\n        return node.value;\n    };\n    /**\n     * Remove and return the value at the end of the list.\n     *\n     * @returns The removed value, or `undefined` if the list is empty.\n     *\n     * #### Complexity\n     * Constant.\n     */\n    LinkedList.prototype.removeLast = function () {\n        var node = this._last;\n        if (!node) {\n            return undefined;\n        }\n        if (node === this._first) {\n            this._first = null;\n            this._last = null;\n        }\n        else {\n            this._last = node.prev;\n            this._last.next = null;\n        }\n        node.list = null;\n        node.next = null;\n        node.prev = null;\n        this._size--;\n        return node.value;\n    };\n    /**\n     * Remove a specific node from the list.\n     *\n     * @param node - The node to remove from the list.\n     *\n     * #### Complexity\n     * Constant.\n     *\n     * #### Notes\n     * The node must be owned by the list.\n     */\n    LinkedList.prototype.removeNode = function (node) {\n        if (!(node instanceof Private$1.LinkedListNode) || node.list !== this) {\n            throw new Error('Node is not owned by the list.');\n        }\n        var _node = node;\n        if (_node === this._first && _node === this._last) {\n            this._first = null;\n            this._last = null;\n        }\n        else if (_node === this._first) {\n            this._first = _node.next;\n            this._first.prev = null;\n        }\n        else if (_node === this._last) {\n            this._last = _node.prev;\n            this._last.next = null;\n        }\n        else {\n            _node.next.prev = _node.prev;\n            _node.prev.next = _node.next;\n        }\n        _node.list = null;\n        _node.next = null;\n        _node.prev = null;\n        this._size--;\n    };\n    /**\n     * Remove all values from the list.\n     *\n     * #### Complexity\n     * Linear.\n     */\n    LinkedList.prototype.clear = function () {\n        var node = this._first;\n        while (node) {\n            var next = node.next;\n            node.list = null;\n            node.prev = null;\n            node.next = null;\n            node = next;\n        }\n        this._first = null;\n        this._last = null;\n        this._size = 0;\n    };\n    return LinkedList;\n}());\n/**\n * The namespace for the `LinkedList` class statics.\n */\n(function (LinkedList) {\n    /**\n     * Create a linked list from an iterable of values.\n     *\n     * @param values - The iterable or array-like object of interest.\n     *\n     * @returns A new linked list initialized with the given values.\n     *\n     * #### Complexity\n     * Linear.\n     */\n    function from(values) {\n        var list = new LinkedList();\n        list.assign(values);\n        return list;\n    }\n    LinkedList.from = from;\n    /**\n     * A forward iterator for values in a linked list.\n     */\n    var ForwardValueIterator = /** @class */ (function () {\n        /**\n         * Construct a forward value iterator.\n         *\n         * @param node - The first node in the list.\n         */\n        function ForwardValueIterator(node) {\n            this._node = node;\n        }\n        /**\n         * Get an iterator over the object's values.\n         *\n         * @returns An iterator which yields the object's values.\n         */\n        ForwardValueIterator.prototype.iter = function () {\n            return this;\n        };\n        /**\n         * Create an independent clone of the iterator.\n         *\n         * @returns A new independent clone of the iterator.\n         */\n        ForwardValueIterator.prototype.clone = function () {\n            return new ForwardValueIterator(this._node);\n        };\n        /**\n         * Get the next value from the iterator.\n         *\n         * @returns The next value from the iterator, or `undefined`.\n         */\n        ForwardValueIterator.prototype.next = function () {\n            if (!this._node) {\n                return undefined;\n            }\n            var node = this._node;\n            this._node = node.next;\n            return node.value;\n        };\n        return ForwardValueIterator;\n    }());\n    LinkedList.ForwardValueIterator = ForwardValueIterator;\n    /**\n     * A reverse iterator for values in a linked list.\n     */\n    var RetroValueIterator = /** @class */ (function () {\n        /**\n         * Construct a retro value iterator.\n         *\n         * @param node - The last node in the list.\n         */\n        function RetroValueIterator(node) {\n            this._node = node;\n        }\n        /**\n         * Get an iterator over the object's values.\n         *\n         * @returns An iterator which yields the object's values.\n         */\n        RetroValueIterator.prototype.iter = function () {\n            return this;\n        };\n        /**\n         * Create an independent clone of the iterator.\n         *\n         * @returns A new independent clone of the iterator.\n         */\n        RetroValueIterator.prototype.clone = function () {\n            return new RetroValueIterator(this._node);\n        };\n        /**\n         * Get the next value from the iterator.\n         *\n         * @returns The next value from the iterator, or `undefined`.\n         */\n        RetroValueIterator.prototype.next = function () {\n            if (!this._node) {\n                return undefined;\n            }\n            var node = this._node;\n            this._node = node.prev;\n            return node.value;\n        };\n        return RetroValueIterator;\n    }());\n    LinkedList.RetroValueIterator = RetroValueIterator;\n    /**\n     * A forward iterator for nodes in a linked list.\n     */\n    var ForwardNodeIterator = /** @class */ (function () {\n        /**\n         * Construct a forward node iterator.\n         *\n         * @param node - The first node in the list.\n         */\n        function ForwardNodeIterator(node) {\n            this._node = node;\n        }\n        /**\n         * Get an iterator over the object's values.\n         *\n         * @returns An iterator which yields the object's values.\n         */\n        ForwardNodeIterator.prototype.iter = function () {\n            return this;\n        };\n        /**\n         * Create an independent clone of the iterator.\n         *\n         * @returns A new independent clone of the iterator.\n         */\n        ForwardNodeIterator.prototype.clone = function () {\n            return new ForwardNodeIterator(this._node);\n        };\n        /**\n         * Get the next value from the iterator.\n         *\n         * @returns The next value from the iterator, or `undefined`.\n         */\n        ForwardNodeIterator.prototype.next = function () {\n            if (!this._node) {\n                return undefined;\n            }\n            var node = this._node;\n            this._node = node.next;\n            return node;\n        };\n        return ForwardNodeIterator;\n    }());\n    LinkedList.ForwardNodeIterator = ForwardNodeIterator;\n    /**\n     * A reverse iterator for nodes in a linked list.\n     */\n    var RetroNodeIterator = /** @class */ (function () {\n        /**\n         * Construct a retro node iterator.\n         *\n         * @param node - The last node in the list.\n         */\n        function RetroNodeIterator(node) {\n            this._node = node;\n        }\n        /**\n         * Get an iterator over the object's values.\n         *\n         * @returns An iterator which yields the object's values.\n         */\n        RetroNodeIterator.prototype.iter = function () {\n            return this;\n        };\n        /**\n         * Create an independent clone of the iterator.\n         *\n         * @returns A new independent clone of the iterator.\n         */\n        RetroNodeIterator.prototype.clone = function () {\n            return new RetroNodeIterator(this._node);\n        };\n        /**\n         * Get the next value from the iterator.\n         *\n         * @returns The next value from the iterator, or `undefined`.\n         */\n        RetroNodeIterator.prototype.next = function () {\n            if (!this._node) {\n                return undefined;\n            }\n            var node = this._node;\n            this._node = node.prev;\n            return node;\n        };\n        return RetroNodeIterator;\n    }());\n    LinkedList.RetroNodeIterator = RetroNodeIterator;\n})(LinkedList || (LinkedList = {}));\n/**\n * The namespace for the module implementation details.\n */\nvar Private$1;\n(function (Private) {\n    /**\n     * The internal linked list node implementation.\n     */\n    var LinkedListNode = /** @class */ (function () {\n        /**\n         * Construct a new linked list node.\n         *\n         * @param list - The list which owns the node.\n         *\n         * @param value - The value for the link.\n         */\n        function LinkedListNode(list, value) {\n            /**\n             * The linked list which created and owns the node.\n             */\n            this.list = null;\n            /**\n             * The next node in the list.\n             */\n            this.next = null;\n            /**\n             * The previous node in the list.\n             */\n            this.prev = null;\n            this.list = list;\n            this.value = value;\n        }\n        return LinkedListNode;\n    }());\n    Private.LinkedListNode = LinkedListNode;\n})(Private$1 || (Private$1 = {}));\n\nexport { BPlusTree, LinkedList };\n//# sourceMappingURL=index.es6.js.map\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n'use strict';\n\nwindow['requirejs'].config({\n    map: {\n        '*': {\n            '@jupyter-widgets/controls': 'nbextensions/jupyter-js-widgets/extension',\n            '@jupyter-widgets/base': 'nbextensions/jupyter-js-widgets/extension',\n            '@jupyter-widgets/output': 'nbextensions/jupyter-js-widgets/extension',\n        },\n    }\n});\n\nvar MIME_TYPE = 'application/vnd.jupyter.widget-view+json';\nvar CLASS_NAME = 'jupyter-widgets-view';\n\nvar mngr = require(\"./manager\");\nrequire(\"./save_state\");\nrequire(\"./embed_widgets\");\nvar PhosphorWidget = require(\"@lumino/widgets\");\n\nvar NOTEBOOK_VERSION_INFO = Jupyter.version.split('.');\nvar NOTEBOOK_MAJOR = parseInt(NOTEBOOK_VERSION_INFO[0]);\nvar NOTEBOOK_MINOR = parseInt(NOTEBOOK_VERSION_INFO[1]);\nvar NOTEBOOK_PATCH = parseInt(NOTEBOOK_VERSION_INFO[2]);\n\nvar RENDER_SHOULD_THROW =\n  NOTEBOOK_MAJOR > 6 ||\n  (NOTEBOOK_MAJOR == 6 && NOTEBOOK_MINOR > 4) ||\n  (NOTEBOOK_MAJOR == 6 && NOTEBOOK_MINOR == 4 && NOTEBOOK_PATCH > 4);\n\n/**\n * Create a widget manager for a kernel instance.\n */\nvar handle_kernel = function(Jupyter, kernel) {\n    if (kernel.comm_manager && kernel.widget_manager === undefined) {\n\n        // Clear any old widget manager\n        if (Jupyter.WidgetManager) {\n            Jupyter.WidgetManager._managers[0].clear_state();\n        }\n\n        // Create a new widget manager instance. Use the global\n        // Jupyter.notebook handle.\n        var manager = new mngr.WidgetManager(kernel.comm_manager, Jupyter.notebook);\n\n        // For backwards compatibility and interactive use.\n        Jupyter.WidgetManager = mngr.WidgetManager;\n\n        // Store a handle to the manager so we know not to\n        // another for this kernel. This also is a convenience\n        // for the user.\n        kernel.widget_manager = manager;\n    }\n};\n\nfunction register_events(Jupyter, events, outputarea) {\n    // If a kernel already exists, create a widget manager.\n    if (Jupyter.notebook && Jupyter.notebook.kernel) {\n        handle_kernel(Jupyter, Jupyter.notebook.kernel);\n    }\n    // When the kernel is created, create a widget manager.\n    events.on('kernel_created.Kernel kernel_created.Session', function(event, data) {\n        handle_kernel(Jupyter, data.kernel);\n    });\n\n    // When a kernel dies, disconnect the widgets.\n    events.on('kernel_killed.Session kernel_killed.Kernel kernel_restarting.Kernel', function(event, data) {\n        var kernel = data.kernel;\n        if (kernel && kernel.widget_manager) {\n            kernel.widget_manager.disconnect();\n        }\n    });\n\n    /**\n     * The views on this page. We keep this list so that we can call the view.remove()\n     * method when a view is removed from the page.\n     */\n    var views = {};\n    var removeView = function(event, data) {\n        var output = data.cell ? data.cell.output_area : data.output_area;\n        var viewids = output ? output._jupyterWidgetViews : void 0;\n        if (viewids) {\n            viewids.forEach(function(id) {\n                // this may be called after the widget is pulled off the page\n                // so we temporarily put it back on the page as a kludge\n                // so that phosphor can trigger the appropriate detach signals\n                var view = views[id];\n                view.el.style.display=\"none\";\n                document.body.appendChild(view.el);\n                view.remove();\n                delete views[id];\n            });\n            output._jupyterWidgetViews = [];\n        }\n    }\n\n    // Deleting a cell does *not* clear the outputs first.\n    events.on('delete.Cell', removeView);\n    // add an event to the notebook element for *any* outputs that are cleared.\n    Jupyter.notebook.container.on('clearing', '.output', removeView);\n\n    // For before https://github.com/jupyter/notebook/pull/2411 is merged and\n    // released. This does not handle the case where an empty cell is executed\n    // to clear input.\n    events.on('execute.CodeCell', removeView);\n    events.on('clear_output.CodeCell', removeView);\n\n    /**\n     * Render data to the output area.\n     */\n    function render(output, data, node) {\n        // data is a model id\n        var manager = Jupyter.notebook && Jupyter.notebook.kernel && Jupyter.notebook.kernel.widget_manager;\n        if (!manager) {\n            var msg = 'Error rendering Jupyter widget: missing widget manager';\n            if (RENDER_SHOULD_THROW) {\n                throw new Error(msg);\n            }\n            node.textContent = msg;\n            return;\n        }\n\n        // Missing model id means the view was removed. Hide this element.\n        if (data.model_id === '') {\n            if (RENDER_SHOULD_THROW) {\n                throw new Error('Jupyter Widgets model not found');\n            }\n            node.style.display = 'none';\n            return;\n        }\n\n        var model = manager.get_model(data.model_id);\n        if (model) {\n            model.then(function(model) {\n                return manager.display_model(void 0, model, {output: output});\n            }).then(function(view) {\n                var id = view.cid;\n                output._jupyterWidgetViews = output._jupyterWidgetViews || [];\n                output._jupyterWidgetViews.push(id);\n                views[id] = view;\n                PhosphorWidget.Widget.attach(view.pWidget, node);\n\n                // Make the node completely disappear if the view is removed.\n                view.once('remove', () => {\n                    // Since we have a mutable reference to the data, delete the\n                    // model id to indicate the view is removed.\n                    data.model_id = '';\n                    node.style.display = 'none';\n                })\n            });\n        } else {\n          var msg =\n              'A Jupyter widget could not be displayed because the widget state could not be found. This could happen if the kernel storing the widget is no longer available, or if the widget state was not saved in the notebook. You may be able to create the widget by running the appropriate cells.';\n          if (RENDER_SHOULD_THROW) {\n              throw new Error(msg);\n          }\n          node.textContent = msg;\n          return;\n        }\n    }\n\n    // `this` is the output area we are appending to\n    var append_mime = function(json, md, element) {\n        var toinsert = this.create_output_subarea(md, CLASS_NAME, MIME_TYPE);\n        this.keyboard_manager.register_events(toinsert);\n        render(this, json, toinsert[0]);\n        element.append(toinsert);\n        return toinsert;\n    };\n\n    // Register mime type with the output area\n    outputarea.OutputArea.prototype.register_mime_type(MIME_TYPE, append_mime, {\n        // An output widget could contain arbitrary user javascript\n        safe: false,\n        // Index of renderer in `output_area.display_order`\n        index: 0\n    });\n}\n\nfunction load_ipython_extension () {\n    return new Promise(function(resolve) {\n        requirejs([\n            \"base/js/namespace\",\n            \"base/js/events\",\n            \"notebook/js/outputarea\"\n        ], function(Jupyter, events, outputarea) {\n            require(\"@lumino/widgets/style/index.css\");\n            require(\"@jupyter-widgets/base/css/index.css\");\n            require('@jupyter-widgets/controls/css/widgets.css');\n            register_events(Jupyter, events, outputarea);\n            resolve();\n        });\n    });\n}\n\nvar _ = require('underscore');\nmodule.exports = _.extend({\n  load_ipython_extension: load_ipython_extension,\n}, require('@jupyter-widgets/controls'), require('@jupyter-widgets/base'), require('./widget_output'));\n","// Copyright (c) Jupyter Development Team.\n// Distributed under the terms of the Modified BSD License.\n\"use strict\";\n\nvar _ = require(\"underscore\");\nvar base = require(\"@jupyter-widgets/base\");\nvar widgets = require(\"@jupyter-widgets/controls\");\nvar outputWidgets = require(\"./widget_output\");\nvar saveState = require(\"./save_state\");\nvar embedWidgets = require(\"./embed_widgets\");\n\nvar MIME_TYPE = 'application/vnd.jupyter.widget-view+json';\n\n\nfunction polyfill_new_comm_buffers(manager, target_name, data, callbacks, metadata, comm_id, buffers) {\n    /**\n     * This polyfills services/kernel/comm/CommManager.new_comm to\n     * accept the buffers argument.\n     *\n     * argument comm_id is optional\n     */\n    return new Promise(function(resolve) {\n        requirejs([\"services/kernels/comm\"], function(comm) {\n            var comm = new comm.Comm(target_name, comm_id);\n            manager.register_comm(comm);\n            // inline Comm.open(), but with buffers\n            var content = {\n                comm_id : comm_id,\n                target_name : target_name,\n                data : data || {},\n            };\n            comm.kernel.send_shell_message(\"comm_open\", content, callbacks, metadata, buffers);\n            resolve(comm);\n        });\n    });\n}\n\nfunction new_comm(manager, target_name, data, callbacks, metadata, comm_id, buffers) {\n    // Checks whether new_comm needs a polyfill, and calls the correct version\n    // Polyfill needed for notebook <5.1, in which the new_comm method does not support a buffers argument.\n    // See https://github.com/jupyter-widgets/ipywidgets/pull/1817\n    var need_polyfill = manager.new_comm.length < 6;\n    if (need_polyfill) {\n        return polyfill_new_comm_buffers.apply(null, arguments);\n    }\n    return manager.new_comm.apply(manager, Array.prototype.slice.call(arguments, 1));\n}\n\n//--------------------------------------------------------------------\n// WidgetManager class\n//--------------------------------------------------------------------\n\n\nexport class WidgetManager extends base.ManagerBase {\n    constructor(comm_manager, notebook) {\n        super();\n        // Managers are stored in *reverse* order, so that _managers[0] is the most recent.\n        WidgetManager._managers.unshift(this);\n\n        // Attach a comm manager\n        this.notebook = notebook;\n        this.keyboard_manager = notebook.keyboard_manager;\n        this.comm_manager = comm_manager;\n\n        var widget_md = notebook.metadata.widgets\n\n        // Steps that needs to be done:\n        // 1. Register comm target\n        // 2. Get any widget state from the kernel and open comms with existing state\n        // 3. Check saved state for widgets, and restore any that would not overwrite\n        //    any live widgets.\n\n        // Register with the comm manager. (1)\n        this.comm_manager.register_target(this.comm_target_name, _.bind(this.handle_comm_open,this));\n\n        // Attempt to reconstruct any live comms by requesting them from the back-end (2).\n        var that = this;\n        this._loadFromKernel().then(function() {\n            // Now that we have mirrored any widgets from the kernel...\n            // Restore any widgets from saved state that are not live (3)\n            if (widget_md && widget_md['application/vnd.jupyter.widget-state+json']) {\n                var state = notebook.metadata.widgets['application/vnd.jupyter.widget-state+json'];\n                state = that.filterExistingModelState(state);\n                return that.set_state(state);\n            }\n        }).then(function() {\n            // Rerender cells that have widget data\n            that.notebook.get_cells().forEach(function(cell) {\n                var rerender = cell.output_area && cell.output_area.outputs.find(function(output) {\n                    return output.data && output.data[MIME_TYPE];\n                });\n                if (rerender) {\n                    that.notebook.render_cell_output(cell);\n                }\n            });\n        });\n\n        // Create the actions and menu\n        this._init_actions();\n        this._init_menu();\n    }\n\n    loadClass(className, moduleName, moduleVersion) {\n        if (moduleName === \"@jupyter-widgets/controls\") {\n            return Promise.resolve(widgets[className]);\n        } else if (moduleName === \"@jupyter-widgets/base\") {\n            return Promise.resolve(base[className]);\n        } else if (moduleName == \"@jupyter-widgets/output\") {\n            return Promise.resolve(outputWidgets[className]);\n        } else {\n            return new Promise(function(resolve, reject) {\n                window.require([moduleName], resolve, reject);\n            }).then(function(mod) {\n                if (mod[className]) {\n                    return mod[className];\n                } else {\n                    return Promise.reject('Class ' + className + ' not found in module ' + moduleName);\n                }\n            });\n        }\n    }\n\n    /**\n     * Registers manager level actions with the notebook actions list\n     */\n    _init_actions() {\n        var notifier = Jupyter.notification_area.widget('widgets');\n        this.saveWidgetsAction = {\n            handler: (function() {\n                this.get_state({\n                    drop_defaults: true\n                }).then(function(state) {\n                    Jupyter.notebook.metadata.widgets = {\n                        'application/vnd.jupyter.widget-state+json' : state\n                    };\n                    Jupyter.menubar.actions.get('jupyter-notebook:save-notebook').handler({\n                        notebook: Jupyter.notebook\n                    });\n                });\n            }).bind(this),\n            icon: 'fa-truck',\n            help: 'Save the notebook with the widget state information for static rendering'\n        };\n        Jupyter.menubar.actions.register(this.saveWidgetsAction, 'save-with-widgets', 'widgets');\n\n        this.clearWidgetsAction = {\n            handler: (function() {\n                delete Jupyter.notebook.metadata.widgets;\n                Jupyter.menubar.actions.get('jupyter-notebook:save-notebook').handler({\n                    notebook: Jupyter.notebook\n                });\n            }),\n            help: 'Clear the widget state information from the notebook'\n        };\n        Jupyter.menubar.actions.register(this.saveWidgetsAction, 'save-clear-widgets', 'widgets');\n    };\n\n    /**\n     * Initialize the widget menu\n     */\n    _init_menu() {\n\n        // Add a widgets menubar item, before help.\n        var widgetsMenu = document.createElement('li');\n        widgetsMenu.classList.add('dropdown');\n        var helpMenu = document.querySelector('#help_menu').parentElement;\n        helpMenu.parentElement.insertBefore(widgetsMenu, helpMenu);\n\n        var widgetsMenuLink = document.createElement('a');\n        widgetsMenuLink.setAttribute('href', '#');\n        widgetsMenuLink.setAttribute('data-toggle', 'dropdown');\n        widgetsMenuLink.classList.add('dropdown-toggle');\n        widgetsMenuLink.innerText = 'Widgets';\n        widgetsMenu.appendChild(widgetsMenuLink);\n\n        var widgetsSubmenu = document.createElement('ul');\n        widgetsSubmenu.setAttribute('id', 'widget-submenu');\n        widgetsSubmenu.classList.add('dropdown-menu');\n        widgetsMenu.appendChild(widgetsSubmenu);\n\n        var divider = document.createElement('ul');\n        divider.classList.add('divider');\n\n        widgetsSubmenu.appendChild(this._createMenuItem('Save Notebook Widget State', this.saveWidgetsAction));\n        widgetsSubmenu.appendChild(this._createMenuItem('Clear Notebook Widget State', this.clearWidgetsAction));\n        widgetsSubmenu.appendChild(divider);\n        widgetsSubmenu.appendChild(this._createMenuItem('Download Widget State', saveState.action));\n        widgetsSubmenu.appendChild(this._createMenuItem('Embed Widgets', embedWidgets.action));\n    };\n\n    /**\n     * Creates a menu item for an action.\n     * @param  {string} title - display string for the menu item\n     * @param  {Action} action\n     * @return {HTMLElement} menu item\n     */\n    _createMenuItem(title, action) {\n        var item = document.createElement('li');\n        item.setAttribute('title', action.help);\n\n        var itemLink = document.createElement('a');\n        itemLink.setAttribute('href', '#');\n        itemLink.innerText = title;\n        item.appendChild(itemLink);\n\n        item.onclick = action.handler;\n        return item;\n    };\n\n\n\n    display_view(msg, view, options) {\n        return Promise.resolve(view);\n    }\n\n\n    _create_comm(comm_target_name, comm_id, data, metadata, buffers) {\n        var that = this;\n        return this._get_connected_kernel().then(function(kernel) {\n            if (data || metadata) {\n                return new_comm(kernel.comm_manager, comm_target_name, data,\n                                that.callbacks(), metadata, comm_id, buffers);\n            } else {\n                // Construct a comm that already is open on the kernel side. We\n                // don't want to send an open message, which would supersede the\n                // kernel comm object, so we instead do by hand the necessary parts\n                // of the new_comm call above.\n                return new Promise(function(resolve) {\n                    requirejs([\"services/kernels/comm\"], function(comm) {\n                        var new_comm = new comm.Comm(comm_target_name, comm_id);\n                        kernel.comm_manager.register_comm(new_comm);\n                        resolve(new_comm);\n                    });\n                });\n            }\n        });\n    };\n\n    _get_comm_info() {\n        /**\n         * Gets a promise for the valid widget models.\n         */\n        var that = this;\n        return this._get_connected_kernel().then(function(kernel) {\n            return new Promise(function(resolve, reject) {\n                kernel.comm_info('jupyter.widget', function(msg) {\n                    resolve(msg['content']['comms']);\n                });\n            });\n        });\n    };\n\n    _get_connected_kernel() {\n        /**\n         * Gets a promise for a connected kernel\n         */\n        var that = this;\n        return new Promise(function(resolve, reject) {\n            if (that.comm_manager &&\n                that.comm_manager.kernel &&\n                that.comm_manager.kernel.is_connected()) {\n\n                resolve(that.comm_manager.kernel);\n            } else {\n                that.notebook.events.on('kernel_connected.Kernel', function(event, data) {\n                    resolve(data.kernel);\n                });\n            }\n        });\n    };\n\n    setViewOptions(options) {\n        var options = options || {};\n        if (!options.output && options.parent) {\n            // use the parent output if we don't have one\n            options.output = options.parent.options.output;\n        }\n        if (options.output) {\n            options.iopub_callbacks = {\n                output: options.output.handle_output.bind(options.output),\n                clear_output: options.output.handle_clear_output.bind(options.output)\n            }\n        }\n        return options;\n    };\n\n    /**\n     * Callback handlers for a specific view\n     */\n    callbacks(view) {\n        var callbacks = base.ManagerBase.prototype.callbacks.call(this, view);\n        if (view && view.options.iopub_callbacks) {\n            callbacks.iopub = view.options.iopub_callbacks\n        }\n        return callbacks;\n    };\n}\n\n/**\n * List of widget managers in *reverse* order\n * (_managers[0] is the most recent)\n */\nWidgetManager._managers = [];\n","var baseIsEqualDeep = require('./_baseIsEqualDeep'),\n    isObjectLike = require('./isObjectLike');\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n *  1 - Unordered comparison\n *  2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n  if (value === other) {\n    return true;\n  }\n  if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n    return value !== value && other !== other;\n  }\n  return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\nmodule.exports = baseIsEqual;\n","var Stack = require('./_Stack'),\n    equalArrays = require('./_equalArrays'),\n    equalByTag = require('./_equalByTag'),\n    equalObjects = require('./_equalObjects'),\n    getTag = require('./_getTag'),\n    isArray = require('./isArray'),\n    isBuffer = require('./isBuffer'),\n    isTypedArray = require('./isTypedArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n    arrayTag = '[object Array]',\n    objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n  var objIsArr = isArray(object),\n      othIsArr = isArray(other),\n      objTag = objIsArr ? arrayTag : getTag(object),\n      othTag = othIsArr ? arrayTag : getTag(other);\n\n  objTag = objTag == argsTag ? objectTag : objTag;\n  othTag = othTag == argsTag ? objectTag : othTag;\n\n  var objIsObj = objTag == objectTag,\n      othIsObj = othTag == objectTag,\n      isSameTag = objTag == othTag;\n\n  if (isSameTag && isBuffer(object)) {\n    if (!isBuffer(other)) {\n      return false;\n    }\n    objIsArr = true;\n    objIsObj = false;\n  }\n  if (isSameTag && !objIsObj) {\n    stack || (stack = new Stack);\n    return (objIsArr || isTypedArray(object))\n      ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n      : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n  }\n  if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n    var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n        othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n    if (objIsWrapped || othIsWrapped) {\n      var objUnwrapped = objIsWrapped ? object.value() : object,\n          othUnwrapped = othIsWrapped ? other.value() : other;\n\n      stack || (stack = new Stack);\n      return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n    }\n  }\n  if (!isSameTag) {\n    return false;\n  }\n  stack || (stack = new Stack);\n  return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\nmodule.exports = baseIsEqualDeep;\n","var ListCache = require('./_ListCache'),\n    stackClear = require('./_stackClear'),\n    stackDelete = require('./_stackDelete'),\n    stackGet = require('./_stackGet'),\n    stackHas = require('./_stackHas'),\n    stackSet = require('./_stackSet');\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n  var data = this.__data__ = new ListCache(entries);\n  this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nmodule.exports = Stack;\n","/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n  this.__data__ = [];\n  this.size = 0;\n}\n\nmodule.exports = listCacheClear;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n  var data = this.__data__,\n      index = assocIndexOf(data, key);\n\n  if (index < 0) {\n    return false;\n  }\n  var lastIndex = data.length - 1;\n  if (index == lastIndex) {\n    data.pop();\n  } else {\n    splice.call(data, index, 1);\n  }\n  --this.size;\n  return true;\n}\n\nmodule.exports = listCacheDelete;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n  var data = this.__data__,\n      index = assocIndexOf(data, key);\n\n  return index < 0 ? undefined : data[index][1];\n}\n\nmodule.exports = listCacheGet;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n  return assocIndexOf(this.__data__, key) > -1;\n}\n\nmodule.exports = listCacheHas;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n  var data = this.__data__,\n      index = assocIndexOf(data, key);\n\n  if (index < 0) {\n    ++this.size;\n    data.push([key, value]);\n  } else {\n    data[index][1] = value;\n  }\n  return this;\n}\n\nmodule.exports = listCacheSet;\n","var ListCache = require('./_ListCache');\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n  this.__data__ = new ListCache;\n  this.size = 0;\n}\n\nmodule.exports = stackClear;\n","/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n  var data = this.__data__,\n      result = data['delete'](key);\n\n  this.size = data.size;\n  return result;\n}\n\nmodule.exports = stackDelete;\n","/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n  return this.__data__.get(key);\n}\n\nmodule.exports = stackGet;\n","/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n  return this.__data__.has(key);\n}\n\nmodule.exports = stackHas;\n","var ListCache = require('./_ListCache'),\n    Map = require('./_Map'),\n    MapCache = require('./_MapCache');\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n  var data = this.__data__;\n  if (data instanceof ListCache) {\n    var pairs = data.__data__;\n    if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n      pairs.push([key, value]);\n      this.size = ++data.size;\n      return this;\n    }\n    data = this.__data__ = new MapCache(pairs);\n  }\n  data.set(key, value);\n  this.size = data.size;\n  return this;\n}\n\nmodule.exports = stackSet;\n","var isFunction = require('./isFunction'),\n    isMasked = require('./_isMasked'),\n    isObject = require('./isObject'),\n    toSource = require('./_toSource');\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n    objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n  funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n  .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n *  else `false`.\n */\nfunction baseIsNative(value) {\n  if (!isObject(value) || isMasked(value)) {\n    return false;\n  }\n  var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n  return pattern.test(toSource(value));\n}\n\nmodule.exports = baseIsNative;\n","var Symbol = require('./_Symbol');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n  var isOwn = hasOwnProperty.call(value, symToStringTag),\n      tag = value[symToStringTag];\n\n  try {\n    value[symToStringTag] = undefined;\n    var unmasked = true;\n  } catch (e) {}\n\n  var result = nativeObjectToString.call(value);\n  if (unmasked) {\n    if (isOwn) {\n      value[symToStringTag] = tag;\n    } else {\n      delete value[symToStringTag];\n    }\n  }\n  return result;\n}\n\nmodule.exports = getRawTag;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n  return nativeObjectToString.call(value);\n}\n\nmodule.exports = objectToString;\n","var coreJsData = require('./_coreJsData');\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n  var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n  return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n  return !!maskSrcKey && (maskSrcKey in func);\n}\n\nmodule.exports = isMasked;\n","var root = require('./_root');\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nmodule.exports = coreJsData;\n","/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n  return object == null ? undefined : object[key];\n}\n\nmodule.exports = getValue;\n","var Hash = require('./_Hash'),\n    ListCache = require('./_ListCache'),\n    Map = require('./_Map');\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n  this.size = 0;\n  this.__data__ = {\n    'hash': new Hash,\n    'map': new (Map || ListCache),\n    'string': new Hash\n  };\n}\n\nmodule.exports = mapCacheClear;\n","var hashClear = require('./_hashClear'),\n    hashDelete = require('./_hashDelete'),\n    hashGet = require('./_hashGet'),\n    hashHas = require('./_hashHas'),\n    hashSet = require('./_hashSet');\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n  var index = -1,\n      length = entries == null ? 0 : entries.length;\n\n  this.clear();\n  while (++index < length) {\n    var entry = entries[index];\n    this.set(entry[0], entry[1]);\n  }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nmodule.exports = Hash;\n","var nativeCreate = require('./_nativeCreate');\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n  this.__data__ = nativeCreate ? nativeCreate(null) : {};\n  this.size = 0;\n}\n\nmodule.exports = hashClear;\n","/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n  var result = this.has(key) && delete this.__data__[key];\n  this.size -= result ? 1 : 0;\n  return result;\n}\n\nmodule.exports = hashDelete;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n  var data = this.__data__;\n  if (nativeCreate) {\n    var result = data[key];\n    return result === HASH_UNDEFINED ? undefined : result;\n  }\n  return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nmodule.exports = hashGet;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n  var data = this.__data__;\n  return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nmodule.exports = hashHas;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n  var data = this.__data__;\n  this.size += this.has(key) ? 0 : 1;\n  data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n  return this;\n}\n\nmodule.exports = hashSet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n  var result = getMapData(this, key)['delete'](key);\n  this.size -= result ? 1 : 0;\n  return result;\n}\n\nmodule.exports = mapCacheDelete;\n","/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n  var type = typeof value;\n  return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n    ? (value !== '__proto__')\n    : (value === null);\n}\n\nmodule.exports = isKeyable;\n","var getMapData = require('./_getMapData');\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n  return getMapData(this, key).get(key);\n}\n\nmodule.exports = mapCacheGet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n  return getMapData(this, key).has(key);\n}\n\nmodule.exports = mapCacheHas;\n","var getMapData = require('./_getMapData');\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n  var data = getMapData(this, key),\n      size = data.size;\n\n  data.set(key, value);\n  this.size += data.size == size ? 0 : 1;\n  return this;\n}\n\nmodule.exports = mapCacheSet;\n","var MapCache = require('./_MapCache'),\n    setCacheAdd = require('./_setCacheAdd'),\n    setCacheHas = require('./_setCacheHas');\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n  var index = -1,\n      length = values == null ? 0 : values.length;\n\n  this.__data__ = new MapCache;\n  while (++index < length) {\n    this.add(values[index]);\n  }\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\nmodule.exports = SetCache;\n","/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n  this.__data__.set(value, HASH_UNDEFINED);\n  return this;\n}\n\nmodule.exports = setCacheAdd;\n","/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n  return this.__data__.has(value);\n}\n\nmodule.exports = setCacheHas;\n","/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n *  else `false`.\n */\nfunction arraySome(array, predicate) {\n  var index = -1,\n      length = array == null ? 0 : array.length;\n\n  while (++index < length) {\n    if (predicate(array[index], index, array)) {\n      return true;\n    }\n  }\n  return false;\n}\n\nmodule.exports = arraySome;\n","/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n  return cache.has(key);\n}\n\nmodule.exports = cacheHas;\n","var Symbol = require('./_Symbol'),\n    Uint8Array = require('./_Uint8Array'),\n    eq = require('./eq'),\n    equalArrays = require('./_equalArrays'),\n    mapToArray = require('./_mapToArray'),\n    setToArray = require('./_setToArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n    COMPARE_UNORDERED_FLAG = 2;\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n    dateTag = '[object Date]',\n    errorTag = '[object Error]',\n    mapTag = '[object Map]',\n    numberTag = '[object Number]',\n    regexpTag = '[object RegExp]',\n    setTag = '[object Set]',\n    stringTag = '[object String]',\n    symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n    dataViewTag = '[object DataView]';\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n    symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n  switch (tag) {\n    case dataViewTag:\n      if ((object.byteLength != other.byteLength) ||\n          (object.byteOffset != other.byteOffset)) {\n        return false;\n      }\n      object = object.buffer;\n      other = other.buffer;\n\n    case arrayBufferTag:\n      if ((object.byteLength != other.byteLength) ||\n          !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n        return false;\n      }\n      return true;\n\n    case boolTag:\n    case dateTag:\n    case numberTag:\n      // Coerce booleans to `1` or `0` and dates to milliseconds.\n      // Invalid dates are coerced to `NaN`.\n      return eq(+object, +other);\n\n    case errorTag:\n      return object.name == other.name && object.message == other.message;\n\n    case regexpTag:\n    case stringTag:\n      // Coerce regexes to strings and treat strings, primitives and objects,\n      // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n      // for more details.\n      return object == (other + '');\n\n    case mapTag:\n      var convert = mapToArray;\n\n    case setTag:\n      var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n      convert || (convert = setToArray);\n\n      if (object.size != other.size && !isPartial) {\n        return false;\n      }\n      // Assume cyclic values are equal.\n      var stacked = stack.get(object);\n      if (stacked) {\n        return stacked == other;\n      }\n      bitmask |= COMPARE_UNORDERED_FLAG;\n\n      // Recursively compare objects (susceptible to call stack limits).\n      stack.set(object, other);\n      var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n      stack['delete'](object);\n      return result;\n\n    case symbolTag:\n      if (symbolValueOf) {\n        return symbolValueOf.call(object) == symbolValueOf.call(other);\n      }\n  }\n  return false;\n}\n\nmodule.exports = equalByTag;\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nmodule.exports = Uint8Array;\n","/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n  var index = -1,\n      result = Array(map.size);\n\n  map.forEach(function(value, key) {\n    result[++index] = [key, value];\n  });\n  return result;\n}\n\nmodule.exports = mapToArray;\n","/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n  var index = -1,\n      result = Array(set.size);\n\n  set.forEach(function(value) {\n    result[++index] = value;\n  });\n  return result;\n}\n\nmodule.exports = setToArray;\n","var getAllKeys = require('./_getAllKeys');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n  var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n      objProps = getAllKeys(object),\n      objLength = objProps.length,\n      othProps = getAllKeys(other),\n      othLength = othProps.length;\n\n  if (objLength != othLength && !isPartial) {\n    return false;\n  }\n  var index = objLength;\n  while (index--) {\n    var key = objProps[index];\n    if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n      return false;\n    }\n  }\n  // Assume cyclic values are equal.\n  var stacked = stack.get(object);\n  if (stacked && stack.get(other)) {\n    return stacked == other;\n  }\n  var result = true;\n  stack.set(object, other);\n  stack.set(other, object);\n\n  var skipCtor = isPartial;\n  while (++index < objLength) {\n    key = objProps[index];\n    var objValue = object[key],\n        othValue = other[key];\n\n    if (customizer) {\n      var compared = isPartial\n        ? customizer(othValue, objValue, key, other, object, stack)\n        : customizer(objValue, othValue, key, object, other, stack);\n    }\n    // Recursively compare objects (susceptible to call stack limits).\n    if (!(compared === undefined\n          ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n          : compared\n        )) {\n      result = false;\n      break;\n    }\n    skipCtor || (skipCtor = key == 'constructor');\n  }\n  if (result && !skipCtor) {\n    var objCtor = object.constructor,\n        othCtor = other.constructor;\n\n    // Non `Object` object instances with different constructors are not equal.\n    if (objCtor != othCtor &&\n        ('constructor' in object && 'constructor' in other) &&\n        !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n          typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n      result = false;\n    }\n  }\n  stack['delete'](object);\n  stack['delete'](other);\n  return result;\n}\n\nmodule.exports = equalObjects;\n","var baseGetAllKeys = require('./_baseGetAllKeys'),\n    getSymbols = require('./_getSymbols'),\n    keys = require('./keys');\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n  return baseGetAllKeys(object, keys, getSymbols);\n}\n\nmodule.exports = getAllKeys;\n","var arrayPush = require('./_arrayPush'),\n    isArray = require('./isArray');\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n  var result = keysFunc(object);\n  return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nmodule.exports = baseGetAllKeys;\n","/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n  var index = -1,\n      length = values.length,\n      offset = array.length;\n\n  while (++index < length) {\n    array[offset + index] = values[index];\n  }\n  return array;\n}\n\nmodule.exports = arrayPush;\n","var arrayFilter = require('./_arrayFilter'),\n    stubArray = require('./stubArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n  if (object == null) {\n    return [];\n  }\n  object = Object(object);\n  return arrayFilter(nativeGetSymbols(object), function(symbol) {\n    return propertyIsEnumerable.call(object, symbol);\n  });\n};\n\nmodule.exports = getSymbols;\n","/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n  var index = -1,\n      length = array == null ? 0 : array.length,\n      resIndex = 0,\n      result = [];\n\n  while (++index < length) {\n    var value = array[index];\n    if (predicate(value, index, array)) {\n      result[resIndex++] = value;\n    }\n  }\n  return result;\n}\n\nmodule.exports = arrayFilter;\n","/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n  return [];\n}\n\nmodule.exports = stubArray;\n","var arrayLikeKeys = require('./_arrayLikeKeys'),\n    baseKeys = require('./_baseKeys'),\n    isArrayLike = require('./isArrayLike');\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n *   this.a = 1;\n *   this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n  return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\nmodule.exports = keys;\n","var baseTimes = require('./_baseTimes'),\n    isArguments = require('./isArguments'),\n    isArray = require('./isArray'),\n    isBuffer = require('./isBuffer'),\n    isIndex = require('./_isIndex'),\n    isTypedArray = require('./isTypedArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n  var isArr = isArray(value),\n      isArg = !isArr && isArguments(value),\n      isBuff = !isArr && !isArg && isBuffer(value),\n      isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n      skipIndexes = isArr || isArg || isBuff || isType,\n      result = skipIndexes ? baseTimes(value.length, String) : [],\n      length = result.length;\n\n  for (var key in value) {\n    if ((inherited || hasOwnProperty.call(value, key)) &&\n        !(skipIndexes && (\n           // Safari 9 has enumerable `arguments.length` in strict mode.\n           key == 'length' ||\n           // Node.js 0.10 has enumerable non-index properties on buffers.\n           (isBuff && (key == 'offset' || key == 'parent')) ||\n           // PhantomJS 2 has enumerable non-index properties on typed arrays.\n           (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n           // Skip index properties.\n           isIndex(key, length)\n        ))) {\n      result.push(key);\n    }\n  }\n  return result;\n}\n\nmodule.exports = arrayLikeKeys;\n","/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n  var index = -1,\n      result = Array(n);\n\n  while (++index < n) {\n    result[index] = iteratee(index);\n  }\n  return result;\n}\n\nmodule.exports = baseTimes;\n","var baseIsArguments = require('./_baseIsArguments'),\n    isObjectLike = require('./isObjectLike');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n *  else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n  return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n    !propertyIsEnumerable.call(value, 'callee');\n};\n\nmodule.exports = isArguments;\n","var baseGetTag = require('./_baseGetTag'),\n    isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n  return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nmodule.exports = baseIsArguments;\n","/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n  return false;\n}\n\nmodule.exports = stubFalse;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n  var type = typeof value;\n  length = length == null ? MAX_SAFE_INTEGER : length;\n\n  return !!length &&\n    (type == 'number' ||\n      (type != 'symbol' && reIsUint.test(value))) &&\n        (value > -1 && value % 1 == 0 && value < length);\n}\n\nmodule.exports = isIndex;\n","var baseGetTag = require('./_baseGetTag'),\n    isLength = require('./isLength'),\n    isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n    arrayTag = '[object Array]',\n    boolTag = '[object Boolean]',\n    dateTag = '[object Date]',\n    errorTag = '[object Error]',\n    funcTag = '[object Function]',\n    mapTag = '[object Map]',\n    numberTag = '[object Number]',\n    objectTag = '[object Object]',\n    regexpTag = '[object RegExp]',\n    setTag = '[object Set]',\n    stringTag = '[object String]',\n    weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n    dataViewTag = '[object DataView]',\n    float32Tag = '[object Float32Array]',\n    float64Tag = '[object Float64Array]',\n    int8Tag = '[object Int8Array]',\n    int16Tag = '[object Int16Array]',\n    int32Tag = '[object Int32Array]',\n    uint8Tag = '[object Uint8Array]',\n    uint8ClampedTag = '[object Uint8ClampedArray]',\n    uint16Tag = '[object Uint16Array]',\n    uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n  return isObjectLike(value) &&\n    isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nmodule.exports = baseIsTypedArray;\n","/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n  return function(value) {\n    return func(value);\n  };\n}\n\nmodule.exports = baseUnary;\n","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n  try {\n    // Use `util.types` for Node.js 10+.\n    var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n    if (types) {\n      return types;\n    }\n\n    // Legacy `process.binding('util')` for Node.js < 10.\n    return freeProcess && freeProcess.binding && freeProcess.binding('util');\n  } catch (e) {}\n}());\n\nmodule.exports = nodeUtil;\n","var isPrototype = require('./_isPrototype'),\n    nativeKeys = require('./_nativeKeys');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n  if (!isPrototype(object)) {\n    return nativeKeys(object);\n  }\n  var result = [];\n  for (var key in Object(object)) {\n    if (hasOwnProperty.call(object, key) && key != 'constructor') {\n      result.push(key);\n    }\n  }\n  return result;\n}\n\nmodule.exports = baseKeys;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n  var Ctor = value && value.constructor,\n      proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n  return value === proto;\n}\n\nmodule.exports = isPrototype;\n","var overArg = require('./_overArg');\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nmodule.exports = nativeKeys;\n","var isFunction = require('./isFunction'),\n    isLength = require('./isLength');\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n  return value != null && isLength(value.length) && !isFunction(value);\n}\n\nmodule.exports = isArrayLike;\n","var DataView = require('./_DataView'),\n    Map = require('./_Map'),\n    Promise = require('./_Promise'),\n    Set = require('./_Set'),\n    WeakMap = require('./_WeakMap'),\n    baseGetTag = require('./_baseGetTag'),\n    toSource = require('./_toSource');\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n    objectTag = '[object Object]',\n    promiseTag = '[object Promise]',\n    setTag = '[object Set]',\n    weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n    mapCtorString = toSource(Map),\n    promiseCtorString = toSource(Promise),\n    setCtorString = toSource(Set),\n    weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n    (Map && getTag(new Map) != mapTag) ||\n    (Promise && getTag(Promise.resolve()) != promiseTag) ||\n    (Set && getTag(new Set) != setTag) ||\n    (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n  getTag = function(value) {\n    var result = baseGetTag(value),\n        Ctor = result == objectTag ? value.constructor : undefined,\n        ctorString = Ctor ? toSource(Ctor) : '';\n\n    if (ctorString) {\n      switch (ctorString) {\n        case dataViewCtorString: return dataViewTag;\n        case mapCtorString: return mapTag;\n        case promiseCtorString: return promiseTag;\n        case setCtorString: return setTag;\n        case weakMapCtorString: return weakMapTag;\n      }\n    }\n    return result;\n  };\n}\n\nmodule.exports = getTag;\n","var getNative = require('./_getNative'),\n    root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nmodule.exports = DataView;\n","var getNative = require('./_getNative'),\n    root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nmodule.exports = Promise;\n","var getNative = require('./_getNative'),\n    root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nmodule.exports = Set;\n","var getNative = require('./_getNative'),\n    root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nmodule.exports = WeakMap;\n","var overArg = require('./_overArg');\n\n/** Built-in value references. */\nvar getPrototype = overArg(Object.getPrototypeOf, Object);\n\nmodule.exports = getPrototype;\n","(function (global, undefined) {\n    \"use strict\";\n\n    if (global.setImmediate) {\n        return;\n    }\n\n    var nextHandle = 1; // Spec says greater than zero\n    var tasksByHandle = {};\n    var currentlyRunningATask = false;\n    var doc = global.document;\n    var registerImmediate;\n\n    function setImmediate(callback) {\n      // Callback can either be a function or a string\n      if (typeof callback !== \"function\") {\n        callback = new Function(\"\" + callback);\n      }\n      // Copy function arguments\n      var args = new Array(arguments.length - 1);\n      for (var i = 0; i < args.length; i++) {\n          args[i] = arguments[i + 1];\n      }\n      // Store and register the task\n      var task = { callback: callback, args: args };\n      tasksByHandle[nextHandle] = task;\n      registerImmediate(nextHandle);\n      return nextHandle++;\n    }\n\n    function clearImmediate(handle) {\n        delete tasksByHandle[handle];\n    }\n\n    function run(task) {\n        var callback = task.callback;\n        var args = task.args;\n        switch (args.length) {\n        case 0:\n            callback();\n            break;\n        case 1:\n            callback(args[0]);\n            break;\n        case 2:\n            callback(args[0], args[1]);\n            break;\n        case 3:\n            callback(args[0], args[1], args[2]);\n            break;\n        default:\n            callback.apply(undefined, args);\n            break;\n        }\n    }\n\n    function runIfPresent(handle) {\n        // From the spec: \"Wait until any invocations of this algorithm started before this one have completed.\"\n        // So if we're currently running a task, we'll need to delay this invocation.\n        if (currentlyRunningATask) {\n            // Delay by doing a setTimeout. setImmediate was tried instead, but in Firefox 7 it generated a\n            // \"too much recursion\" error.\n            setTimeout(runIfPresent, 0, handle);\n        } else {\n            var task = tasksByHandle[handle];\n            if (task) {\n                currentlyRunningATask = true;\n                try {\n                    run(task);\n                } finally {\n                    clearImmediate(handle);\n                    currentlyRunningATask = false;\n                }\n            }\n        }\n    }\n\n    function installNextTickImplementation() {\n        registerImmediate = function(handle) {\n            process.nextTick(function () { runIfPresent(handle); });\n        };\n    }\n\n    function canUsePostMessage() {\n        // The test against `importScripts` prevents this implementation from being installed inside a web worker,\n        // where `global.postMessage` means something completely different and can't be used for this purpose.\n        if (global.postMessage && !global.importScripts) {\n            var postMessageIsAsynchronous = true;\n            var oldOnMessage = global.onmessage;\n            global.onmessage = function() {\n                postMessageIsAsynchronous = false;\n            };\n            global.postMessage(\"\", \"*\");\n            global.onmessage = oldOnMessage;\n            return postMessageIsAsynchronous;\n        }\n    }\n\n    function installPostMessageImplementation() {\n        // Installs an event handler on `global` for the `message` event: see\n        // * https://developer.mozilla.org/en/DOM/window.postMessage\n        // * http://www.whatwg.org/specs/web-apps/current-work/multipage/comms.html#crossDocumentMessages\n\n        var messagePrefix = \"setImmediate$\" + Math.random() + \"$\";\n        var onGlobalMessage = function(event) {\n            if (event.source === global &&\n                typeof event.data === \"string\" &&\n                event.data.indexOf(messagePrefix) === 0) {\n                runIfPresent(+event.data.slice(messagePrefix.length));\n            }\n        };\n\n        if (global.addEventListener) {\n            global.addEventListener(\"message\", onGlobalMessage, false);\n        } else {\n            global.attachEvent(\"onmessage\", onGlobalMessage);\n        }\n\n        registerImmediate = function(handle) {\n            global.postMessage(messagePrefix + handle, \"*\");\n        };\n    }\n\n    function installMessageChannelImplementation() {\n        var channel = new MessageChannel();\n        channel.port1.onmessage = function(event) {\n            var handle = event.data;\n            runIfPresent(handle);\n        };\n\n        registerImmediate = function(handle) {\n            channel.port2.postMessage(handle);\n        };\n    }\n\n    function installReadyStateChangeImplementation() {\n        var html = doc.documentElement;\n        registerImmediate = function(handle) {\n            // Create a <script> element; its readystatechange event will be fired asynchronously once it is inserted\n            // into the document. Do so, thus queuing up the task. Remember to clean up once it's been called.\n            var script = doc.createElement(\"script\");\n            script.onreadystatechange = function () {\n                runIfPresent(handle);\n                script.onreadystatechange = null;\n                html.removeChild(script);\n                script = null;\n            };\n            html.appendChild(script);\n        };\n    }\n\n    function installSetTimeoutImplementation() {\n        registerImmediate = function(handle) {\n            setTimeout(runIfPresent, 0, handle);\n        };\n    }\n\n    // If supported, we should attach to the prototype of global, since that is where setTimeout et al. live.\n    var attachTo = Object.getPrototypeOf && Object.getPrototypeOf(global);\n    attachTo = attachTo && attachTo.setTimeout ? attachTo : global;\n\n    // Don't get fooled by e.g. browserify environments.\n    if ({}.toString.call(global.process) === \"[object process]\") {\n        // For Node.js before 0.9\n        installNextTickImplementation();\n\n    } else if (canUsePostMessage()) {\n        // For non-IE10 modern browsers\n        installPostMessageImplementation();\n\n    } else if (global.MessageChannel) {\n        // For web workers, where supported\n        installMessageChannelImplementation();\n\n    } else if (doc && \"onreadystatechange\" in doc.createElement(\"script\")) {\n        // For IE 6–8\n        installReadyStateChangeImplementation();\n\n    } else {\n        // For older browsers\n        installSetTimeoutImplementation();\n    }\n\n    attachTo.setImmediate = setImmediate;\n    attachTo.clearImmediate = clearImmediate;\n}(typeof self === \"undefined\" ? typeof global === \"undefined\" ? this : global : self));\n","// shim for using process in browser\nvar process = module.exports = {};\n\n// cached from whatever global is present so that test runners that stub it\n// don't break things.  But we need to wrap it in a try catch in case it is\n// wrapped in strict mode code which doesn't define any globals.  It's inside a\n// function because try/catches deoptimize in certain engines.\n\nvar cachedSetTimeout;\nvar cachedClearTimeout;\n\nfunction defaultSetTimout() {\n    throw new Error('setTimeout has not been defined');\n}\nfunction defaultClearTimeout () {\n    throw new Error('clearTimeout has not been defined');\n}\n(function () {\n    try {\n        if (typeof setTimeout === 'function') {\n            cachedSetTimeout = setTimeout;\n        } else {\n            cachedSetTimeout = defaultSetTimout;\n        }\n    } catch (e) {\n        cachedSetTimeout = defaultSetTimout;\n    }\n    try {\n        if (typeof clearTimeout === 'function') {\n            cachedClearTimeout = clearTimeout;\n        } else {\n            cachedClearTimeout = defaultClearTimeout;\n        }\n    } catch (e) {\n        cachedClearTimeout = defaultClearTimeout;\n    }\n} ())\nfunction runTimeout(fun) {\n    if (cachedSetTimeout === setTimeout) {\n        //normal enviroments in sane situations\n        return setTimeout(fun, 0);\n    }\n    // if setTimeout wasn't available but was latter defined\n    if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {\n        cachedSetTimeout = setTimeout;\n        return setTimeout(fun, 0);\n    }\n    try {\n        // when when somebody has screwed with setTimeout but no I.E. maddness\n        return cachedSetTimeout(fun, 0);\n    } catch(e){\n        try {\n            // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally\n            return cachedSetTimeout.call(null, fun, 0);\n        } catch(e){\n            // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error\n            return cachedSetTimeout.call(this, fun, 0);\n        }\n    }\n\n\n}\nfunction runClearTimeout(marker) {\n    if (cachedClearTimeout === clearTimeout) {\n        //normal enviroments in sane situations\n        return clearTimeout(marker);\n    }\n    // if clearTimeout wasn't available but was latter defined\n    if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {\n        cachedClearTimeout = clearTimeout;\n        return clearTimeout(marker);\n    }\n    try {\n        // when when somebody has screwed with setTimeout but no I.E. maddness\n        return cachedClearTimeout(marker);\n    } catch (e){\n        try {\n            // When we are in I.E. but the script has been evaled so I.E. doesn't  trust the global object when called normally\n            return cachedClearTimeout.call(null, marker);\n        } catch (e){\n            // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.\n            // Some versions of I.E. have different rules for clearTimeout vs setTimeout\n            return cachedClearTimeout.call(this, marker);\n        }\n    }\n\n\n\n}\nvar queue = [];\nvar draining = false;\nvar currentQueue;\nvar queueIndex = -1;\n\nfunction cleanUpNextTick() {\n    if (!draining || !currentQueue) {\n        return;\n    }\n    draining = false;\n    if (currentQueue.length) {\n        queue = currentQueue.concat(queue);\n    } else {\n        queueIndex = -1;\n    }\n    if (queue.length) {\n        drainQueue();\n    }\n}\n\nfunction drainQueue() {\n    if (draining) {\n        return;\n    }\n    var timeout = runTimeout(cleanUpNextTick);\n    draining = true;\n\n    var len = queue.length;\n    while(len) {\n        currentQueue = queue;\n        queue = [];\n        while (++queueIndex < len) {\n            if (currentQueue) {\n                currentQueue[queueIndex].run();\n            }\n        }\n        queueIndex = -1;\n        len = queue.length;\n    }\n    currentQueue = null;\n    draining = false;\n    runClearTimeout(timeout);\n}\n\nprocess.nextTick = function (fun) {\n    var args = new Array(arguments.length - 1);\n    if (arguments.length > 1) {\n        for (var i = 1; i < arguments.length; i++) {\n            args[i - 1] = arguments[i];\n        }\n    }\n    queue.push(new Item(fun, args));\n    if (queue.length === 1 && !draining) {\n        runTimeout(drainQueue);\n    }\n};\n\n// v8 likes predictible objects\nfunction Item(fun, array) {\n    this.fun = fun;\n    this.array = array;\n}\nItem.prototype.run = function () {\n    this.fun.apply(null, this.array);\n};\nprocess.title = 'browser';\nprocess.browser = true;\nprocess.env = {};\nprocess.argv = [];\nprocess.version = ''; // empty string to avoid regexp issues\nprocess.versions = {};\n\nfunction noop() {}\n\nprocess.on = noop;\nprocess.addListener = noop;\nprocess.once = noop;\nprocess.off = noop;\nprocess.removeListener = noop;\nprocess.removeAllListeners = noop;\nprocess.emit = noop;\nprocess.prependListener = noop;\nprocess.prependOnceListener = noop;\n\nprocess.listeners = function (name) { return [] }\n\nprocess.binding = function (name) {\n    throw new Error('process.binding is not supported');\n};\n\nprocess.cwd = function () { return '/' };\nprocess.chdir = function (dir) {\n    throw new Error('process.chdir is not supported');\n};\nprocess.umask = function() { return 0; };\n","/*!\n * jQuery UI Slider 1.12.1\n * http://jqueryui.com\n *\n * Copyright jQuery Foundation and other contributors\n * Released under the MIT license.\n * http://jquery.org/license\n */\n\n//>>label: Slider\n//>>group: Widgets\n//>>description: Displays a flexible slider with ranges and accessibility via keyboard.\n//>>docs: http://api.jqueryui.com/slider/\n//>>demos: http://jqueryui.com/slider/\n//>>css.structure: ../../themes/base/core.css\n//>>css.structure: ../../themes/base/slider.css\n//>>css.theme: ../../themes/base/theme.css\n\n( function( factory ) {\n\tif ( typeof define === \"function\" && define.amd ) {\n\n\t\t// AMD. Register as an anonymous module.\n\t\tdefine( [\n\t\t\t\"jquery\",\n\t\t\t\"./mouse\",\n\t\t\t\"../keycode\",\n\t\t\t\"../version\",\n\t\t\t\"../widget\"\n\t\t], factory );\n\t} else {\n\n\t\t// Browser globals\n\t\tfactory( jQuery );\n\t}\n}( function( $ ) {\n\nreturn $.widget( \"ui.slider\", $.ui.mouse, {\n\tversion: \"1.12.1\",\n\twidgetEventPrefix: \"slide\",\n\n\toptions: {\n\t\tanimate: false,\n\t\tclasses: {\n\t\t\t\"ui-slider\": \"ui-corner-all\",\n\t\t\t\"ui-slider-handle\": \"ui-corner-all\",\n\n\t\t\t// Note: ui-widget-header isn't the most fittingly semantic framework class for this\n\t\t\t// element, but worked best visually with a variety of themes\n\t\t\t\"ui-slider-range\": \"ui-corner-all ui-widget-header\"\n\t\t},\n\t\tdistance: 0,\n\t\tmax: 100,\n\t\tmin: 0,\n\t\torientation: \"horizontal\",\n\t\trange: false,\n\t\tstep: 1,\n\t\tvalue: 0,\n\t\tvalues: null,\n\n\t\t// Callbacks\n\t\tchange: null,\n\t\tslide: null,\n\t\tstart: null,\n\t\tstop: null\n\t},\n\n\t// Number of pages in a slider\n\t// (how many times can you page up/down to go through the whole range)\n\tnumPages: 5,\n\n\t_create: function() {\n\t\tthis._keySliding = false;\n\t\tthis._mouseSliding = false;\n\t\tthis._animateOff = true;\n\t\tthis._handleIndex = null;\n\t\tthis._detectOrientation();\n\t\tthis._mouseInit();\n\t\tthis._calculateNewMax();\n\n\t\tthis._addClass( \"ui-slider ui-slider-\" + this.orientation,\n\t\t\t\"ui-widget ui-widget-content\" );\n\n\t\tthis._refresh();\n\n\t\tthis._animateOff = false;\n\t},\n\n\t_refresh: function() {\n\t\tthis._createRange();\n\t\tthis._createHandles();\n\t\tthis._setupEvents();\n\t\tthis._refreshValue();\n\t},\n\n\t_createHandles: function() {\n\t\tvar i, handleCount,\n\t\t\toptions = this.options,\n\t\t\texistingHandles = this.element.find( \".ui-slider-handle\" ),\n\t\t\thandle = \"<span tabindex='0'></span>\",\n\t\t\thandles = [];\n\n\t\thandleCount = ( options.values && options.values.length ) || 1;\n\n\t\tif ( existingHandles.length > handleCount ) {\n\t\t\texistingHandles.slice( handleCount ).remove();\n\t\t\texistingHandles = existingHandles.slice( 0, handleCount );\n\t\t}\n\n\t\tfor ( i = existingHandles.length; i < handleCount; i++ ) {\n\t\t\thandles.push( handle );\n\t\t}\n\n\t\tthis.handles = existingHandles.add( $( handles.join( \"\" ) ).appendTo( this.element ) );\n\n\t\tthis._addClass( this.handles, \"ui-slider-handle\", \"ui-state-default\" );\n\n\t\tthis.handle = this.handles.eq( 0 );\n\n\t\tthis.handles.each( function( i ) {\n\t\t\t$( this )\n\t\t\t\t.data( \"ui-slider-handle-index\", i )\n\t\t\t\t.attr( \"tabIndex\", 0 );\n\t\t} );\n\t},\n\n\t_createRange: function() {\n\t\tvar options = this.options;\n\n\t\tif ( options.range ) {\n\t\t\tif ( options.range === true ) {\n\t\t\t\tif ( !options.values ) {\n\t\t\t\t\toptions.values = [ this._valueMin(), this._valueMin() ];\n\t\t\t\t} else if ( options.values.length && options.values.length !== 2 ) {\n\t\t\t\t\toptions.values = [ options.values[ 0 ], options.values[ 0 ] ];\n\t\t\t\t} else if ( $.isArray( options.values ) ) {\n\t\t\t\t\toptions.values = options.values.slice( 0 );\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif ( !this.range || !this.range.length ) {\n\t\t\t\tthis.range = $( \"<div>\" )\n\t\t\t\t\t.appendTo( this.element );\n\n\t\t\t\tthis._addClass( this.range, \"ui-slider-range\" );\n\t\t\t} else {\n\t\t\t\tthis._removeClass( this.range, \"ui-slider-range-min ui-slider-range-max\" );\n\n\t\t\t\t// Handle range switching from true to min/max\n\t\t\t\tthis.range.css( {\n\t\t\t\t\t\"left\": \"\",\n\t\t\t\t\t\"bottom\": \"\"\n\t\t\t\t} );\n\t\t\t}\n\t\t\tif ( options.range === \"min\" || options.range === \"max\" ) {\n\t\t\t\tthis._addClass( this.range, \"ui-slider-range-\" + options.range );\n\t\t\t}\n\t\t} else {\n\t\t\tif ( this.range ) {\n\t\t\t\tthis.range.remove();\n\t\t\t}\n\t\t\tthis.range = null;\n\t\t}\n\t},\n\n\t_setupEvents: function() {\n\t\tthis._off( this.handles );\n\t\tthis._on( this.handles, this._handleEvents );\n\t\tthis._hoverable( this.handles );\n\t\tthis._focusable( this.handles );\n\t},\n\n\t_destroy: function() {\n\t\tthis.handles.remove();\n\t\tif ( this.range ) {\n\t\t\tthis.range.remove();\n\t\t}\n\n\t\tthis._mouseDestroy();\n\t},\n\n\t_mouseCapture: function( event ) {\n\t\tvar position, normValue, distance, closestHandle, index, allowed, offset, mouseOverHandle,\n\t\t\tthat = this,\n\t\t\to = this.options;\n\n\t\tif ( o.disabled ) {\n\t\t\treturn false;\n\t\t}\n\n\t\tthis.elementSize = {\n\t\t\twidth: this.element.outerWidth(),\n\t\t\theight: this.element.outerHeight()\n\t\t};\n\t\tthis.elementOffset = this.element.offset();\n\n\t\tposition = { x: event.pageX, y: event.pageY };\n\t\tnormValue = this._normValueFromMouse( position );\n\t\tdistance = this._valueMax() - this._valueMin() + 1;\n\t\tthis.handles.each( function( i ) {\n\t\t\tvar thisDistance = Math.abs( normValue - that.values( i ) );\n\t\t\tif ( ( distance > thisDistance ) ||\n\t\t\t\t( distance === thisDistance &&\n\t\t\t\t\t( i === that._lastChangedValue || that.values( i ) === o.min ) ) ) {\n\t\t\t\tdistance = thisDistance;\n\t\t\t\tclosestHandle = $( this );\n\t\t\t\tindex = i;\n\t\t\t}\n\t\t} );\n\n\t\tallowed = this._start( event, index );\n\t\tif ( allowed === false ) {\n\t\t\treturn false;\n\t\t}\n\t\tthis._mouseSliding = true;\n\n\t\tthis._handleIndex = index;\n\n\t\tthis._addClass( closestHandle, null, \"ui-state-active\" );\n\t\tclosestHandle.trigger( \"focus\" );\n\n\t\toffset = closestHandle.offset();\n\t\tmouseOverHandle = !$( event.target ).parents().addBack().is( \".ui-slider-handle\" );\n\t\tthis._clickOffset = mouseOverHandle ? { left: 0, top: 0 } : {\n\t\t\tleft: event.pageX - offset.left - ( closestHandle.width() / 2 ),\n\t\t\ttop: event.pageY - offset.top -\n\t\t\t\t( closestHandle.height() / 2 ) -\n\t\t\t\t( parseInt( closestHandle.css( \"borderTopWidth\" ), 10 ) || 0 ) -\n\t\t\t\t( parseInt( closestHandle.css( \"borderBottomWidth\" ), 10 ) || 0 ) +\n\t\t\t\t( parseInt( closestHandle.css( \"marginTop\" ), 10 ) || 0 )\n\t\t};\n\n\t\tif ( !this.handles.hasClass( \"ui-state-hover\" ) ) {\n\t\t\tthis._slide( event, index, normValue );\n\t\t}\n\t\tthis._animateOff = true;\n\t\treturn true;\n\t},\n\n\t_mouseStart: function() {\n\t\treturn true;\n\t},\n\n\t_mouseDrag: function( event ) {\n\t\tvar position = { x: event.pageX, y: event.pageY },\n\t\t\tnormValue = this._normValueFromMouse( position );\n\n\t\tthis._slide( event, this._handleIndex, normValue );\n\n\t\treturn false;\n\t},\n\n\t_mouseStop: function( event ) {\n\t\tthis._removeClass( this.handles, null, \"ui-state-active\" );\n\t\tthis._mouseSliding = false;\n\n\t\tthis._stop( event, this._handleIndex );\n\t\tthis._change( event, this._handleIndex );\n\n\t\tthis._handleIndex = null;\n\t\tthis._clickOffset = null;\n\t\tthis._animateOff = false;\n\n\t\treturn false;\n\t},\n\n\t_detectOrientation: function() {\n\t\tthis.orientation = ( this.options.orientation === \"vertical\" ) ? \"vertical\" : \"horizontal\";\n\t},\n\n\t_normValueFromMouse: function( position ) {\n\t\tvar pixelTotal,\n\t\t\tpixelMouse,\n\t\t\tpercentMouse,\n\t\t\tvalueTotal,\n\t\t\tvalueMouse;\n\n\t\tif ( this.orientation === \"horizontal\" ) {\n\t\t\tpixelTotal = this.elementSize.width;\n\t\t\tpixelMouse = position.x - this.elementOffset.left -\n\t\t\t\t( this._clickOffset ? this._clickOffset.left : 0 );\n\t\t} else {\n\t\t\tpixelTotal = this.elementSize.height;\n\t\t\tpixelMouse = position.y - this.elementOffset.top -\n\t\t\t\t( this._clickOffset ? this._clickOffset.top : 0 );\n\t\t}\n\n\t\tpercentMouse = ( pixelMouse / pixelTotal );\n\t\tif ( percentMouse > 1 ) {\n\t\t\tpercentMouse = 1;\n\t\t}\n\t\tif ( percentMouse < 0 ) {\n\t\t\tpercentMouse = 0;\n\t\t}\n\t\tif ( this.orientation === \"vertical\" ) {\n\t\t\tpercentMouse = 1 - percentMouse;\n\t\t}\n\n\t\tvalueTotal = this._valueMax() - this._valueMin();\n\t\tvalueMouse = this._valueMin() + percentMouse * valueTotal;\n\n\t\treturn this._trimAlignValue( valueMouse );\n\t},\n\n\t_uiHash: function( index, value, values ) {\n\t\tvar uiHash = {\n\t\t\thandle: this.handles[ index ],\n\t\t\thandleIndex: index,\n\t\t\tvalue: value !== undefined ? value : this.value()\n\t\t};\n\n\t\tif ( this._hasMultipleValues() ) {\n\t\t\tuiHash.value = value !== undefined ? value : this.values( index );\n\t\t\tuiHash.values = values || this.values();\n\t\t}\n\n\t\treturn uiHash;\n\t},\n\n\t_hasMultipleValues: function() {\n\t\treturn this.options.values && this.options.values.length;\n\t},\n\n\t_start: function( event, index ) {\n\t\treturn this._trigger( \"start\", event, this._uiHash( index ) );\n\t},\n\n\t_slide: function( event, index, newVal ) {\n\t\tvar allowed, otherVal,\n\t\t\tcurrentValue = this.value(),\n\t\t\tnewValues = this.values();\n\n\t\tif ( this._hasMultipleValues() ) {\n\t\t\totherVal = this.values( index ? 0 : 1 );\n\t\t\tcurrentValue = this.values( index );\n\n\t\t\tif ( this.options.values.length === 2 && this.options.range === true ) {\n\t\t\t\tnewVal =  index === 0 ? Math.min( otherVal, newVal ) : Math.max( otherVal, newVal );\n\t\t\t}\n\n\t\t\tnewValues[ index ] = newVal;\n\t\t}\n\n\t\tif ( newVal === currentValue ) {\n\t\t\treturn;\n\t\t}\n\n\t\tallowed = this._trigger( \"slide\", event, this._uiHash( index, newVal, newValues ) );\n\n\t\t// A slide can be canceled by returning false from the slide callback\n\t\tif ( allowed === false ) {\n\t\t\treturn;\n\t\t}\n\n\t\tif ( this._hasMultipleValues() ) {\n\t\t\tthis.values( index, newVal );\n\t\t} else {\n\t\t\tthis.value( newVal );\n\t\t}\n\t},\n\n\t_stop: function( event, index ) {\n\t\tthis._trigger( \"stop\", event, this._uiHash( index ) );\n\t},\n\n\t_change: function( event, index ) {\n\t\tif ( !this._keySliding && !this._mouseSliding ) {\n\n\t\t\t//store the last changed value index for reference when handles overlap\n\t\t\tthis._lastChangedValue = index;\n\t\t\tthis._trigger( \"change\", event, this._uiHash( index ) );\n\t\t}\n\t},\n\n\tvalue: function( newValue ) {\n\t\tif ( arguments.length ) {\n\t\t\tthis.options.value = this._trimAlignValue( newValue );\n\t\t\tthis._refreshValue();\n\t\t\tthis._change( null, 0 );\n\t\t\treturn;\n\t\t}\n\n\t\treturn this._value();\n\t},\n\n\tvalues: function( index, newValue ) {\n\t\tvar vals,\n\t\t\tnewValues,\n\t\t\ti;\n\n\t\tif ( arguments.length > 1 ) {\n\t\t\tthis.options.values[ index ] = this._trimAlignValue( newValue );\n\t\t\tthis._refreshValue();\n\t\t\tthis._change( null, index );\n\t\t\treturn;\n\t\t}\n\n\t\tif ( arguments.length ) {\n\t\t\tif ( $.isArray( arguments[ 0 ] ) ) {\n\t\t\t\tvals = this.options.values;\n\t\t\t\tnewValues = arguments[ 0 ];\n\t\t\t\tfor ( i = 0; i < vals.length; i += 1 ) {\n\t\t\t\t\tvals[ i ] = this._trimAlignValue( newValues[ i ] );\n\t\t\t\t\tthis._change( null, i );\n\t\t\t\t}\n\t\t\t\tthis._refreshValue();\n\t\t\t} else {\n\t\t\t\tif ( this._hasMultipleValues() ) {\n\t\t\t\t\treturn this._values( index );\n\t\t\t\t} else {\n\t\t\t\t\treturn this.value();\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\treturn this._values();\n\t\t}\n\t},\n\n\t_setOption: function( key, value ) {\n\t\tvar i,\n\t\t\tvalsLength = 0;\n\n\t\tif ( key === \"range\" && this.options.range === true ) {\n\t\t\tif ( value === \"min\" ) {\n\t\t\t\tthis.options.value = this._values( 0 );\n\t\t\t\tthis.options.values = null;\n\t\t\t} else if ( value === \"max\" ) {\n\t\t\t\tthis.options.value = this._values( this.options.values.length - 1 );\n\t\t\t\tthis.options.values = null;\n\t\t\t}\n\t\t}\n\n\t\tif ( $.isArray( this.options.values ) ) {\n\t\t\tvalsLength = this.options.values.length;\n\t\t}\n\n\t\tthis._super( key, value );\n\n\t\tswitch ( key ) {\n\t\t\tcase \"orientation\":\n\t\t\t\tthis._detectOrientation();\n\t\t\t\tthis._removeClass( \"ui-slider-horizontal ui-slider-vertical\" )\n\t\t\t\t\t._addClass( \"ui-slider-\" + this.orientation );\n\t\t\t\tthis._refreshValue();\n\t\t\t\tif ( this.options.range ) {\n\t\t\t\t\tthis._refreshRange( value );\n\t\t\t\t}\n\n\t\t\t\t// Reset positioning from previous orientation\n\t\t\t\tthis.handles.css( value === \"horizontal\" ? \"bottom\" : \"left\", \"\" );\n\t\t\t\tbreak;\n\t\t\tcase \"value\":\n\t\t\t\tthis._animateOff = true;\n\t\t\t\tthis._refreshValue();\n\t\t\t\tthis._change( null, 0 );\n\t\t\t\tthis._animateOff = false;\n\t\t\t\tbreak;\n\t\t\tcase \"values\":\n\t\t\t\tthis._animateOff = true;\n\t\t\t\tthis._refreshValue();\n\n\t\t\t\t// Start from the last handle to prevent unreachable handles (#9046)\n\t\t\t\tfor ( i = valsLength - 1; i >= 0; i-- ) {\n\t\t\t\t\tthis._change( null, i );\n\t\t\t\t}\n\t\t\t\tthis._animateOff = false;\n\t\t\t\tbreak;\n\t\t\tcase \"step\":\n\t\t\tcase \"min\":\n\t\t\tcase \"max\":\n\t\t\t\tthis._animateOff = true;\n\t\t\t\tthis._calculateNewMax();\n\t\t\t\tthis._refreshValue();\n\t\t\t\tthis._animateOff = false;\n\t\t\t\tbreak;\n\t\t\tcase \"range\":\n\t\t\t\tthis._animateOff = true;\n\t\t\t\tthis._refresh();\n\t\t\t\tthis._animateOff = false;\n\t\t\t\tbreak;\n\t\t}\n\t},\n\n\t_setOptionDisabled: function( value ) {\n\t\tthis._super( value );\n\n\t\tthis._toggleClass( null, \"ui-state-disabled\", !!value );\n\t},\n\n\t//internal value getter\n\t// _value() returns value trimmed by min and max, aligned by step\n\t_value: function() {\n\t\tvar val = this.options.value;\n\t\tval = this._trimAlignValue( val );\n\n\t\treturn val;\n\t},\n\n\t//internal values getter\n\t// _values() returns array of values trimmed by min and max, aligned by step\n\t// _values( index ) returns single value trimmed by min and max, aligned by step\n\t_values: function( index ) {\n\t\tvar val,\n\t\t\tvals,\n\t\t\ti;\n\n\t\tif ( arguments.length ) {\n\t\t\tval = this.options.values[ index ];\n\t\t\tval = this._trimAlignValue( val );\n\n\t\t\treturn val;\n\t\t} else if ( this._hasMultipleValues() ) {\n\n\t\t\t// .slice() creates a copy of the array\n\t\t\t// this copy gets trimmed by min and max and then returned\n\t\t\tvals = this.options.values.slice();\n\t\t\tfor ( i = 0; i < vals.length; i += 1 ) {\n\t\t\t\tvals[ i ] = this._trimAlignValue( vals[ i ] );\n\t\t\t}\n\n\t\t\treturn vals;\n\t\t} else {\n\t\t\treturn [];\n\t\t}\n\t},\n\n\t// Returns the step-aligned value that val is closest to, between (inclusive) min and max\n\t_trimAlignValue: function( val ) {\n\t\tif ( val <= this._valueMin() ) {\n\t\t\treturn this._valueMin();\n\t\t}\n\t\tif ( val >= this._valueMax() ) {\n\t\t\treturn this._valueMax();\n\t\t}\n\t\tvar step = ( this.options.step > 0 ) ? this.options.step : 1,\n\t\t\tvalModStep = ( val - this._valueMin() ) % step,\n\t\t\talignValue = val - valModStep;\n\n\t\tif ( Math.abs( valModStep ) * 2 >= step ) {\n\t\t\talignValue += ( valModStep > 0 ) ? step : ( -step );\n\t\t}\n\n\t\t// Since JavaScript has problems with large floats, round\n\t\t// the final value to 5 digits after the decimal point (see #4124)\n\t\treturn parseFloat( alignValue.toFixed( 5 ) );\n\t},\n\n\t_calculateNewMax: function() {\n\t\tvar max = this.options.max,\n\t\t\tmin = this._valueMin(),\n\t\t\tstep = this.options.step,\n\t\t\taboveMin = Math.round( ( max - min ) / step ) * step;\n\t\tmax = aboveMin + min;\n\t\tif ( max > this.options.max ) {\n\n\t\t\t//If max is not divisible by step, rounding off may increase its value\n\t\t\tmax -= step;\n\t\t}\n\t\tthis.max = parseFloat( max.toFixed( this._precision() ) );\n\t},\n\n\t_precision: function() {\n\t\tvar precision = this._precisionOf( this.options.step );\n\t\tif ( this.options.min !== null ) {\n\t\t\tprecision = Math.max( precision, this._precisionOf( this.options.min ) );\n\t\t}\n\t\treturn precision;\n\t},\n\n\t_precisionOf: function( num ) {\n\t\tvar str = num.toString(),\n\t\t\tdecimal = str.indexOf( \".\" );\n\t\treturn decimal === -1 ? 0 : str.length - decimal - 1;\n\t},\n\n\t_valueMin: function() {\n\t\treturn this.options.min;\n\t},\n\n\t_valueMax: function() {\n\t\treturn this.max;\n\t},\n\n\t_refreshRange: function( orientation ) {\n\t\tif ( orientation === \"vertical\" ) {\n\t\t\tthis.range.css( { \"width\": \"\", \"left\": \"\" } );\n\t\t}\n\t\tif ( orientation === \"horizontal\" ) {\n\t\t\tthis.range.css( { \"height\": \"\", \"bottom\": \"\" } );\n\t\t}\n\t},\n\n\t_refreshValue: function() {\n\t\tvar lastValPercent, valPercent, value, valueMin, valueMax,\n\t\t\toRange = this.options.range,\n\t\t\to = this.options,\n\t\t\tthat = this,\n\t\t\tanimate = ( !this._animateOff ) ? o.animate : false,\n\t\t\t_set = {};\n\n\t\tif ( this._hasMultipleValues() ) {\n\t\t\tthis.handles.each( function( i ) {\n\t\t\t\tvalPercent = ( that.values( i ) - that._valueMin() ) / ( that._valueMax() -\n\t\t\t\t\tthat._valueMin() ) * 100;\n\t\t\t\t_set[ that.orientation === \"horizontal\" ? \"left\" : \"bottom\" ] = valPercent + \"%\";\n\t\t\t\t$( this ).stop( 1, 1 )[ animate ? \"animate\" : \"css\" ]( _set, o.animate );\n\t\t\t\tif ( that.options.range === true ) {\n\t\t\t\t\tif ( that.orientation === \"horizontal\" ) {\n\t\t\t\t\t\tif ( i === 0 ) {\n\t\t\t\t\t\t\tthat.range.stop( 1, 1 )[ animate ? \"animate\" : \"css\" ]( {\n\t\t\t\t\t\t\t\tleft: valPercent + \"%\"\n\t\t\t\t\t\t\t}, o.animate );\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ( i === 1 ) {\n\t\t\t\t\t\t\tthat.range[ animate ? \"animate\" : \"css\" ]( {\n\t\t\t\t\t\t\t\twidth: ( valPercent - lastValPercent ) + \"%\"\n\t\t\t\t\t\t\t}, {\n\t\t\t\t\t\t\t\tqueue: false,\n\t\t\t\t\t\t\t\tduration: o.animate\n\t\t\t\t\t\t\t} );\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif ( i === 0 ) {\n\t\t\t\t\t\t\tthat.range.stop( 1, 1 )[ animate ? \"animate\" : \"css\" ]( {\n\t\t\t\t\t\t\t\tbottom: ( valPercent ) + \"%\"\n\t\t\t\t\t\t\t}, o.animate );\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ( i === 1 ) {\n\t\t\t\t\t\t\tthat.range[ animate ? \"animate\" : \"css\" ]( {\n\t\t\t\t\t\t\t\theight: ( valPercent - lastValPercent ) + \"%\"\n\t\t\t\t\t\t\t}, {\n\t\t\t\t\t\t\t\tqueue: false,\n\t\t\t\t\t\t\t\tduration: o.animate\n\t\t\t\t\t\t\t} );\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tlastValPercent = valPercent;\n\t\t\t} );\n\t\t} else {\n\t\t\tvalue = this.value();\n\t\t\tvalueMin = this._valueMin();\n\t\t\tvalueMax = this._valueMax();\n\t\t\tvalPercent = ( valueMax !== valueMin ) ?\n\t\t\t\t\t( value - valueMin ) / ( valueMax - valueMin ) * 100 :\n\t\t\t\t\t0;\n\t\t\t_set[ this.orientation === \"horizontal\" ? \"left\" : \"bottom\" ] = valPercent + \"%\";\n\t\t\tthis.handle.stop( 1, 1 )[ animate ? \"animate\" : \"css\" ]( _set, o.animate );\n\n\t\t\tif ( oRange === \"min\" && this.orientation === \"horizontal\" ) {\n\t\t\t\tthis.range.stop( 1, 1 )[ animate ? \"animate\" : \"css\" ]( {\n\t\t\t\t\twidth: valPercent + \"%\"\n\t\t\t\t}, o.animate );\n\t\t\t}\n\t\t\tif ( oRange === \"max\" && this.orientation === \"horizontal\" ) {\n\t\t\t\tthis.range.stop( 1, 1 )[ animate ? \"animate\" : \"css\" ]( {\n\t\t\t\t\twidth: ( 100 - valPercent ) + \"%\"\n\t\t\t\t}, o.animate );\n\t\t\t}\n\t\t\tif ( oRange === \"min\" && this.orientation === \"vertical\" ) {\n\t\t\t\tthis.range.stop( 1, 1 )[ animate ? \"animate\" : \"css\" ]( {\n\t\t\t\t\theight: valPercent + \"%\"\n\t\t\t\t}, o.animate );\n\t\t\t}\n\t\t\tif ( oRange === \"max\" && this.orientation === \"vertical\" ) {\n\t\t\t\tthis.range.stop( 1, 1 )[ animate ? \"animate\" : \"css\" ]( {\n\t\t\t\t\theight: ( 100 - valPercent ) + \"%\"\n\t\t\t\t}, o.animate );\n\t\t\t}\n\t\t}\n\t},\n\n\t_handleEvents: {\n\t\tkeydown: function( event ) {\n\t\t\tvar allowed, curVal, newVal, step,\n\t\t\t\tindex = $( event.target ).data( \"ui-slider-handle-index\" );\n\n\t\t\tswitch ( event.keyCode ) {\n\t\t\t\tcase $.ui.keyCode.HOME:\n\t\t\t\tcase $.ui.keyCode.END:\n\t\t\t\tcase $.ui.keyCode.PAGE_UP:\n\t\t\t\tcase $.ui.keyCode.PAGE_DOWN:\n\t\t\t\tcase $.ui.keyCode.UP:\n\t\t\t\tcase $.ui.keyCode.RIGHT:\n\t\t\t\tcase $.ui.keyCode.DOWN:\n\t\t\t\tcase $.ui.keyCode.LEFT:\n\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\tif ( !this._keySliding ) {\n\t\t\t\t\t\tthis._keySliding = true;\n\t\t\t\t\t\tthis._addClass( $( event.target ), null, \"ui-state-active\" );\n\t\t\t\t\t\tallowed = this._start( event, index );\n\t\t\t\t\t\tif ( allowed === false ) {\n\t\t\t\t\t\t\treturn;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tstep = this.options.step;\n\t\t\tif ( this._hasMultipleValues() ) {\n\t\t\t\tcurVal = newVal = this.values( index );\n\t\t\t} else {\n\t\t\t\tcurVal = newVal = this.value();\n\t\t\t}\n\n\t\t\tswitch ( event.keyCode ) {\n\t\t\t\tcase $.ui.keyCode.HOME:\n\t\t\t\t\tnewVal = this._valueMin();\n\t\t\t\t\tbreak;\n\t\t\t\tcase $.ui.keyCode.END:\n\t\t\t\t\tnewVal = this._valueMax();\n\t\t\t\t\tbreak;\n\t\t\t\tcase $.ui.keyCode.PAGE_UP:\n\t\t\t\t\tnewVal = this._trimAlignValue(\n\t\t\t\t\t\tcurVal + ( ( this._valueMax() - this._valueMin() ) / this.numPages )\n\t\t\t\t\t);\n\t\t\t\t\tbreak;\n\t\t\t\tcase $.ui.keyCode.PAGE_DOWN:\n\t\t\t\t\tnewVal = this._trimAlignValue(\n\t\t\t\t\t\tcurVal - ( ( this._valueMax() - this._valueMin() ) / this.numPages ) );\n\t\t\t\t\tbreak;\n\t\t\t\tcase $.ui.keyCode.UP:\n\t\t\t\tcase $.ui.keyCode.RIGHT:\n\t\t\t\t\tif ( curVal === this._valueMax() ) {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\tnewVal = this._trimAlignValue( curVal + step );\n\t\t\t\t\tbreak;\n\t\t\t\tcase $.ui.keyCode.DOWN:\n\t\t\t\tcase $.ui.keyCode.LEFT:\n\t\t\t\t\tif ( curVal === this._valueMin() ) {\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\tnewVal = this._trimAlignValue( curVal - step );\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tthis._slide( event, index, newVal );\n\t\t},\n\t\tkeyup: function( event ) {\n\t\t\tvar index = $( event.target ).data( \"ui-slider-handle-index\" );\n\n\t\t\tif ( this._keySliding ) {\n\t\t\t\tthis._keySliding = false;\n\t\t\t\tthis._stop( event, index );\n\t\t\t\tthis._change( event, index );\n\t\t\t\tthis._removeClass( $( event.target ), null, \"ui-state-active\" );\n\t\t\t}\n\t\t}\n\t}\n} );\n\n} ) );\n","/*!\n * jQuery UI Mouse 1.12.1\n * http://jqueryui.com\n *\n * Copyright jQuery Foundation and other contributors\n * Released under the MIT license.\n * http://jquery.org/license\n */\n\n//>>label: Mouse\n//>>group: Widgets\n//>>description: Abstracts mouse-based interactions to assist in creating certain widgets.\n//>>docs: http://api.jqueryui.com/mouse/\n\n( function( factory ) {\n\tif ( typeof define === \"function\" && define.amd ) {\n\n\t\t// AMD. Register as an anonymous module.\n\t\tdefine( [\n\t\t\t\"jquery\",\n\t\t\t\"../ie\",\n\t\t\t\"../version\",\n\t\t\t\"../widget\"\n\t\t], factory );\n\t} else {\n\n\t\t// Browser globals\n\t\tfactory( jQuery );\n\t}\n}( function( $ ) {\n\nvar mouseHandled = false;\n$( document ).on( \"mouseup\", function() {\n\tmouseHandled = false;\n} );\n\nreturn $.widget( \"ui.mouse\", {\n\tversion: \"1.12.1\",\n\toptions: {\n\t\tcancel: \"input, textarea, button, select, option\",\n\t\tdistance: 1,\n\t\tdelay: 0\n\t},\n\t_mouseInit: function() {\n\t\tvar that = this;\n\n\t\tthis.element\n\t\t\t.on( \"mousedown.\" + this.widgetName, function( event ) {\n\t\t\t\treturn that._mouseDown( event );\n\t\t\t} )\n\t\t\t.on( \"click.\" + this.widgetName, function( event ) {\n\t\t\t\tif ( true === $.data( event.target, that.widgetName + \".preventClickEvent\" ) ) {\n\t\t\t\t\t$.removeData( event.target, that.widgetName + \".preventClickEvent\" );\n\t\t\t\t\tevent.stopImmediatePropagation();\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t} );\n\n\t\tthis.started = false;\n\t},\n\n\t// TODO: make sure destroying one instance of mouse doesn't mess with\n\t// other instances of mouse\n\t_mouseDestroy: function() {\n\t\tthis.element.off( \".\" + this.widgetName );\n\t\tif ( this._mouseMoveDelegate ) {\n\t\t\tthis.document\n\t\t\t\t.off( \"mousemove.\" + this.widgetName, this._mouseMoveDelegate )\n\t\t\t\t.off( \"mouseup.\" + this.widgetName, this._mouseUpDelegate );\n\t\t}\n\t},\n\n\t_mouseDown: function( event ) {\n\n\t\t// don't let more than one widget handle mouseStart\n\t\tif ( mouseHandled ) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis._mouseMoved = false;\n\n\t\t// We may have missed mouseup (out of window)\n\t\t( this._mouseStarted && this._mouseUp( event ) );\n\n\t\tthis._mouseDownEvent = event;\n\n\t\tvar that = this,\n\t\t\tbtnIsLeft = ( event.which === 1 ),\n\n\t\t\t// event.target.nodeName works around a bug in IE 8 with\n\t\t\t// disabled inputs (#7620)\n\t\t\telIsCancel = ( typeof this.options.cancel === \"string\" && event.target.nodeName ?\n\t\t\t\t$( event.target ).closest( this.options.cancel ).length : false );\n\t\tif ( !btnIsLeft || elIsCancel || !this._mouseCapture( event ) ) {\n\t\t\treturn true;\n\t\t}\n\n\t\tthis.mouseDelayMet = !this.options.delay;\n\t\tif ( !this.mouseDelayMet ) {\n\t\t\tthis._mouseDelayTimer = setTimeout( function() {\n\t\t\t\tthat.mouseDelayMet = true;\n\t\t\t}, this.options.delay );\n\t\t}\n\n\t\tif ( this._mouseDistanceMet( event ) && this._mouseDelayMet( event ) ) {\n\t\t\tthis._mouseStarted = ( this._mouseStart( event ) !== false );\n\t\t\tif ( !this._mouseStarted ) {\n\t\t\t\tevent.preventDefault();\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\t// Click event may never have fired (Gecko & Opera)\n\t\tif ( true === $.data( event.target, this.widgetName + \".preventClickEvent\" ) ) {\n\t\t\t$.removeData( event.target, this.widgetName + \".preventClickEvent\" );\n\t\t}\n\n\t\t// These delegates are required to keep context\n\t\tthis._mouseMoveDelegate = function( event ) {\n\t\t\treturn that._mouseMove( event );\n\t\t};\n\t\tthis._mouseUpDelegate = function( event ) {\n\t\t\treturn that._mouseUp( event );\n\t\t};\n\n\t\tthis.document\n\t\t\t.on( \"mousemove.\" + this.widgetName, this._mouseMoveDelegate )\n\t\t\t.on( \"mouseup.\" + this.widgetName, this._mouseUpDelegate );\n\n\t\tevent.preventDefault();\n\n\t\tmouseHandled = true;\n\t\treturn true;\n\t},\n\n\t_mouseMove: function( event ) {\n\n\t\t// Only check for mouseups outside the document if you've moved inside the document\n\t\t// at least once. This prevents the firing of mouseup in the case of IE<9, which will\n\t\t// fire a mousemove event if content is placed under the cursor. See #7778\n\t\t// Support: IE <9\n\t\tif ( this._mouseMoved ) {\n\n\t\t\t// IE mouseup check - mouseup happened when mouse was out of window\n\t\t\tif ( $.ui.ie && ( !document.documentMode || document.documentMode < 9 ) &&\n\t\t\t\t\t!event.button ) {\n\t\t\t\treturn this._mouseUp( event );\n\n\t\t\t// Iframe mouseup check - mouseup occurred in another document\n\t\t\t} else if ( !event.which ) {\n\n\t\t\t\t// Support: Safari <=8 - 9\n\t\t\t\t// Safari sets which to 0 if you press any of the following keys\n\t\t\t\t// during a drag (#14461)\n\t\t\t\tif ( event.originalEvent.altKey || event.originalEvent.ctrlKey ||\n\t\t\t\t\t\tevent.originalEvent.metaKey || event.originalEvent.shiftKey ) {\n\t\t\t\t\tthis.ignoreMissingWhich = true;\n\t\t\t\t} else if ( !this.ignoreMissingWhich ) {\n\t\t\t\t\treturn this._mouseUp( event );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif ( event.which || event.button ) {\n\t\t\tthis._mouseMoved = true;\n\t\t}\n\n\t\tif ( this._mouseStarted ) {\n\t\t\tthis._mouseDrag( event );\n\t\t\treturn event.preventDefault();\n\t\t}\n\n\t\tif ( this._mouseDistanceMet( event ) && this._mouseDelayMet( event ) ) {\n\t\t\tthis._mouseStarted =\n\t\t\t\t( this._mouseStart( this._mouseDownEvent, event ) !== false );\n\t\t\t( this._mouseStarted ? this._mouseDrag( event ) : this._mouseUp( event ) );\n\t\t}\n\n\t\treturn !this._mouseStarted;\n\t},\n\n\t_mouseUp: function( event ) {\n\t\tthis.document\n\t\t\t.off( \"mousemove.\" + this.widgetName, this._mouseMoveDelegate )\n\t\t\t.off( \"mouseup.\" + this.widgetName, this._mouseUpDelegate );\n\n\t\tif ( this._mouseStarted ) {\n\t\t\tthis._mouseStarted = false;\n\n\t\t\tif ( event.target === this._mouseDownEvent.target ) {\n\t\t\t\t$.data( event.target, this.widgetName + \".preventClickEvent\", true );\n\t\t\t}\n\n\t\t\tthis._mouseStop( event );\n\t\t}\n\n\t\tif ( this._mouseDelayTimer ) {\n\t\t\tclearTimeout( this._mouseDelayTimer );\n\t\t\tdelete this._mouseDelayTimer;\n\t\t}\n\n\t\tthis.ignoreMissingWhich = false;\n\t\tmouseHandled = false;\n\t\tevent.preventDefault();\n\t},\n\n\t_mouseDistanceMet: function( event ) {\n\t\treturn ( Math.max(\n\t\t\t\tMath.abs( this._mouseDownEvent.pageX - event.pageX ),\n\t\t\t\tMath.abs( this._mouseDownEvent.pageY - event.pageY )\n\t\t\t) >= this.options.distance\n\t\t);\n\t},\n\n\t_mouseDelayMet: function( /* event */ ) {\n\t\treturn this.mouseDelayMet;\n\t},\n\n\t// These are placeholder methods, to be overriden by extending plugin\n\t_mouseStart: function( /* event */ ) {},\n\t_mouseDrag: function( /* event */ ) {},\n\t_mouseStop: function( /* event */ ) {},\n\t_mouseCapture: function( /* event */ ) { return true; }\n} );\n\n} ) );\n","( function( factory ) {\n\tif ( typeof define === \"function\" && define.amd ) {\n\n\t\t// AMD. Register as an anonymous module.\n\t\tdefine( [ \"jquery\", \"./version\" ], factory );\n\t} else {\n\n\t\t// Browser globals\n\t\tfactory( jQuery );\n\t}\n} ( function( $ ) {\n\n// This file is deprecated\nreturn $.ui.ie = !!/msie [\\w.]+/.exec( navigator.userAgent.toLowerCase() );\n} ) );\n","/*!\n * jQuery UI Keycode 1.12.1\n * http://jqueryui.com\n *\n * Copyright jQuery Foundation and other contributors\n * Released under the MIT license.\n * http://jquery.org/license\n */\n\n//>>label: Keycode\n//>>group: Core\n//>>description: Provide keycodes as keynames\n//>>docs: http://api.jqueryui.com/jQuery.ui.keyCode/\n\n( function( factory ) {\n\tif ( typeof define === \"function\" && define.amd ) {\n\n\t\t// AMD. Register as an anonymous module.\n\t\tdefine( [ \"jquery\", \"./version\" ], factory );\n\t} else {\n\n\t\t// Browser globals\n\t\tfactory( jQuery );\n\t}\n} ( function( $ ) {\nreturn $.ui.keyCode = {\n\tBACKSPACE: 8,\n\tCOMMA: 188,\n\tDELETE: 46,\n\tDOWN: 40,\n\tEND: 35,\n\tENTER: 13,\n\tESCAPE: 27,\n\tHOME: 36,\n\tLEFT: 37,\n\tPAGE_DOWN: 34,\n\tPAGE_UP: 33,\n\tPERIOD: 190,\n\tRIGHT: 39,\n\tSPACE: 32,\n\tTAB: 9,\n\tUP: 38\n};\n\n} ) );\n","var api = require(\"!../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\");\n            var content = require(\"!!../../node_modules/css-loader/dist/cjs.js!./widget_output.css\");\n\n            content = content.__esModule ? content.default : content;\n\n            if (typeof content === 'string') {\n              content = [[module.id, content, '']];\n            }\n\nvar options = {};\n\noptions.insert = \"head\";\noptions.singleton = false;\n\nvar update = api(module.id, content, options);\n\nvar exported = content.locals ? content.locals : {};\n\n\n\nmodule.exports = exported;","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/*\\n * Copyright (c) Jupyter Development Team.\\n * Distributed under the terms of the Modified BSD License.\\n */\\n\\n/* Override the correction for the prompt area in https://github.com/jupyter/notebook/blob/dd41d9fd5c4f698bd7468612d877828a7eeb0e7a/IPython/html/static/notebook/less/outputarea.less#L110 */\\n.jupyter-widgets-output-area div.output_subarea {\\n    max-width: 100%;\\n}\\n\\n/* Work-around for the bug fixed in https://github.com/jupyter/notebook/pull/2961 */\\n.jupyter-widgets-output-area > .out_prompt_overlay {\\n    display: none;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","var api = require(\"!../../../style-loader/dist/runtime/injectStylesIntoStyleTag.js\");\n            var content = require(\"!!../../../css-loader/dist/cjs.js!./index.css\");\n\n            content = content.__esModule ? content.default : content;\n\n            if (typeof content === 'string') {\n              content = [[module.id, content, '']];\n            }\n\nvar options = {};\n\noptions.insert = \"head\";\noptions.singleton = false;\n\nvar update = api(module.id, content, options);\n\nvar exported = content.locals ? content.locals : {};\n\n\n\nmodule.exports = exported;","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../css-loader/dist/runtime/api.js\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_0___ = require(\"-!../../../css-loader/dist/cjs.js!./widget.css\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_1___ = require(\"-!../../../css-loader/dist/cjs.js!./commandpalette.css\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_2___ = require(\"-!../../../css-loader/dist/cjs.js!./dockpanel.css\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_3___ = require(\"-!../../../css-loader/dist/cjs.js!./menu.css\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_4___ = require(\"-!../../../css-loader/dist/cjs.js!./menubar.css\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_5___ = require(\"-!../../../css-loader/dist/cjs.js!./scrollbar.css\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_6___ = require(\"-!../../../css-loader/dist/cjs.js!./splitpanel.css\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_7___ = require(\"-!../../../css-loader/dist/cjs.js!./tabbar.css\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_8___ = require(\"-!../../../css-loader/dist/cjs.js!./tabpanel.css\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_0___);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_1___);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_2___);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_3___);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_4___);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_5___);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_6___);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_7___);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_8___);\n// Module\nexports.push([module.id, \"/*-----------------------------------------------------------------------------\\n| Copyright (c) Jupyter Development Team.\\n| Copyright (c) 2014-2017, PhosphorJS Contributors\\n|\\n| Distributed under the terms of the BSD 3-Clause License.\\n|\\n| The full license is in the file LICENSE, distributed with this software.\\n|----------------------------------------------------------------------------*/\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/*-----------------------------------------------------------------------------\\n| Copyright (c) Jupyter Development Team.\\n| Copyright (c) 2014-2017, PhosphorJS Contributors\\n|\\n| Distributed under the terms of the BSD 3-Clause License.\\n|\\n| The full license is in the file LICENSE, distributed with this software.\\n|----------------------------------------------------------------------------*/\\n\\n\\n/* <DEPRECATED> */ .p-Widget, /* </DEPRECATED> */\\n.lm-Widget {\\n  box-sizing: border-box;\\n  position: relative;\\n  overflow: hidden;\\n  cursor: default;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-Widget.p-mod-hidden, /* </DEPRECATED> */\\n.lm-Widget.lm-mod-hidden {\\n  display: none !important;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/*-----------------------------------------------------------------------------\\n| Copyright (c) Jupyter Development Team.\\n| Copyright (c) 2014-2017, PhosphorJS Contributors\\n|\\n| Distributed under the terms of the BSD 3-Clause License.\\n|\\n| The full license is in the file LICENSE, distributed with this software.\\n|----------------------------------------------------------------------------*/\\n\\n\\n/* <DEPRECATED> */ .p-CommandPalette, /* </DEPRECATED> */\\n.lm-CommandPalette {\\n  display: flex;\\n  flex-direction: column;\\n  -webkit-user-select: none;\\n  -moz-user-select: none;\\n  -ms-user-select: none;\\n  user-select: none;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-CommandPalette-search, /* </DEPRECATED> */\\n.lm-CommandPalette-search {\\n  flex: 0 0 auto;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-CommandPalette-content, /* </DEPRECATED> */\\n.lm-CommandPalette-content {\\n  flex: 1 1 auto;\\n  margin: 0;\\n  padding: 0;\\n  min-height: 0;\\n  overflow: auto;\\n  list-style-type: none;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-CommandPalette-header, /* </DEPRECATED> */\\n.lm-CommandPalette-header {\\n  overflow: hidden;\\n  white-space: nowrap;\\n  text-overflow: ellipsis;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-CommandPalette-item, /* </DEPRECATED> */\\n.lm-CommandPalette-item {\\n  display: flex;\\n  flex-direction: row;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-CommandPalette-itemIcon, /* </DEPRECATED> */\\n.lm-CommandPalette-itemIcon {\\n  flex: 0 0 auto;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-CommandPalette-itemContent, /* </DEPRECATED> */\\n.lm-CommandPalette-itemContent {\\n  flex: 1 1 auto;\\n  overflow: hidden;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-CommandPalette-itemShortcut, /* </DEPRECATED> */\\n.lm-CommandPalette-itemShortcut {\\n  flex: 0 0 auto;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-CommandPalette-itemLabel, /* </DEPRECATED> */\\n.lm-CommandPalette-itemLabel {\\n  overflow: hidden;\\n  white-space: nowrap;\\n  text-overflow: ellipsis;\\n}\\n\\n.lm-close-icon {\\n\\tborder:1px solid transparent;\\n  background-color: transparent;\\n  position: absolute;\\n\\tz-index:1;\\n\\tright:3%;\\n\\ttop: 0;\\n\\tbottom: 0;\\n\\tmargin: auto;\\n\\tpadding: 7px 0;\\n\\tdisplay: none;\\n\\tvertical-align: middle;\\n  outline: 0;\\n  cursor: pointer;\\n}\\n.lm-close-icon:after {\\n\\tcontent: \\\"X\\\";\\n\\tdisplay: block;\\n\\twidth: 15px;\\n\\theight: 15px;\\n\\ttext-align: center;\\n\\tcolor:#000;\\n\\tfont-weight: normal;\\n\\tfont-size: 12px;\\n\\tcursor: pointer;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/*-----------------------------------------------------------------------------\\n| Copyright (c) Jupyter Development Team.\\n| Copyright (c) 2014-2017, PhosphorJS Contributors\\n|\\n| Distributed under the terms of the BSD 3-Clause License.\\n|\\n| The full license is in the file LICENSE, distributed with this software.\\n|----------------------------------------------------------------------------*/\\n\\n\\n/* <DEPRECATED> */ .p-DockPanel, /* </DEPRECATED> */\\n.lm-DockPanel {\\n  z-index: 0;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-DockPanel-widget, /* </DEPRECATED> */\\n.lm-DockPanel-widget {\\n  z-index: 0;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-DockPanel-tabBar, /* </DEPRECATED> */\\n.lm-DockPanel-tabBar {\\n  z-index: 1;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-DockPanel-handle, /* </DEPRECATED> */\\n.lm-DockPanel-handle {\\n  z-index: 2;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-DockPanel-handle.p-mod-hidden, /* </DEPRECATED> */\\n.lm-DockPanel-handle.lm-mod-hidden {\\n  display: none !important;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-DockPanel-handle:after, /* </DEPRECATED> */\\n.lm-DockPanel-handle:after {\\n  position: absolute;\\n  top: 0;\\n  left: 0;\\n  width: 100%;\\n  height: 100%;\\n  content: '';\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-DockPanel-handle[data-orientation='horizontal'],\\n/* </DEPRECATED> */\\n.lm-DockPanel-handle[data-orientation='horizontal'] {\\n  cursor: ew-resize;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-DockPanel-handle[data-orientation='vertical'],\\n/* </DEPRECATED> */\\n.lm-DockPanel-handle[data-orientation='vertical'] {\\n  cursor: ns-resize;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-DockPanel-handle[data-orientation='horizontal']:after,\\n/* </DEPRECATED> */\\n.lm-DockPanel-handle[data-orientation='horizontal']:after {\\n  left: 50%;\\n  min-width: 8px;\\n  transform: translateX(-50%);\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-DockPanel-handle[data-orientation='vertical']:after,\\n/* </DEPRECATED> */\\n.lm-DockPanel-handle[data-orientation='vertical']:after {\\n  top: 50%;\\n  min-height: 8px;\\n  transform: translateY(-50%);\\n}\\n\\n\\n/* <DEPRECATED> */ .p-DockPanel-overlay, /* </DEPRECATED> */\\n.lm-DockPanel-overlay {\\n  z-index: 3;\\n  box-sizing: border-box;\\n  pointer-events: none;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-DockPanel-overlay.p-mod-hidden, /* </DEPRECATED> */\\n.lm-DockPanel-overlay.lm-mod-hidden {\\n  display: none !important;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/*-----------------------------------------------------------------------------\\n| Copyright (c) Jupyter Development Team.\\n| Copyright (c) 2014-2017, PhosphorJS Contributors\\n|\\n| Distributed under the terms of the BSD 3-Clause License.\\n|\\n| The full license is in the file LICENSE, distributed with this software.\\n|----------------------------------------------------------------------------*/\\n\\n\\n/* <DEPRECATED> */ .p-Menu, /* </DEPRECATED> */\\n.lm-Menu {\\n  z-index: 10000;\\n  position: absolute;\\n  white-space: nowrap;\\n  overflow-x: hidden;\\n  overflow-y: auto;\\n  outline: none;\\n  -webkit-user-select: none;\\n  -moz-user-select: none;\\n  -ms-user-select: none;\\n  user-select: none;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-Menu-content, /* </DEPRECATED> */\\n.lm-Menu-content {\\n  margin: 0;\\n  padding: 0;\\n  display: table;\\n  list-style-type: none;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-Menu-item, /* </DEPRECATED> */\\n.lm-Menu-item {\\n  display: table-row;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-Menu-item.p-mod-hidden,\\n.p-Menu-item.p-mod-collapsed,\\n/* </DEPRECATED> */\\n.lm-Menu-item.lm-mod-hidden,\\n.lm-Menu-item.lm-mod-collapsed {\\n  display: none !important;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-Menu-itemIcon,\\n.p-Menu-itemSubmenuIcon,\\n/* </DEPRECATED> */\\n.lm-Menu-itemIcon,\\n.lm-Menu-itemSubmenuIcon {\\n  display: table-cell;\\n  text-align: center;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-Menu-itemLabel, /* </DEPRECATED> */\\n.lm-Menu-itemLabel {\\n  display: table-cell;\\n  text-align: left;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-Menu-itemShortcut, /* </DEPRECATED> */\\n.lm-Menu-itemShortcut {\\n  display: table-cell;\\n  text-align: right;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/*-----------------------------------------------------------------------------\\n| Copyright (c) Jupyter Development Team.\\n| Copyright (c) 2014-2017, PhosphorJS Contributors\\n|\\n| Distributed under the terms of the BSD 3-Clause License.\\n|\\n| The full license is in the file LICENSE, distributed with this software.\\n|----------------------------------------------------------------------------*/\\n\\n\\n/* <DEPRECATED> */ .p-MenuBar, /* </DEPRECATED> */\\n.lm-MenuBar {\\n  outline: none;\\n  -webkit-user-select: none;\\n  -moz-user-select: none;\\n  -ms-user-select: none;\\n  user-select: none;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-MenuBar-content, /* </DEPRECATED> */\\n.lm-MenuBar-content {\\n  margin: 0;\\n  padding: 0;\\n  display: flex;\\n  flex-direction: row;\\n  list-style-type: none;\\n}\\n\\n\\n/* <DEPRECATED> */ .p--MenuBar-item, /* </DEPRECATED> */\\n.lm-MenuBar-item {\\n  box-sizing: border-box;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-MenuBar-itemIcon,\\n.p-MenuBar-itemLabel,\\n/* </DEPRECATED> */\\n.lm-MenuBar-itemIcon,\\n.lm-MenuBar-itemLabel {\\n  display: inline-block;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/*-----------------------------------------------------------------------------\\n| Copyright (c) Jupyter Development Team.\\n| Copyright (c) 2014-2017, PhosphorJS Contributors\\n|\\n| Distributed under the terms of the BSD 3-Clause License.\\n|\\n| The full license is in the file LICENSE, distributed with this software.\\n|----------------------------------------------------------------------------*/\\n\\n\\n/* <DEPRECATED> */ .p-ScrollBar, /* </DEPRECATED> */\\n.lm-ScrollBar {\\n  display: flex;\\n  -webkit-user-select: none;\\n  -moz-user-select: none;\\n  -ms-user-select: none;\\n  user-select: none;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-ScrollBar[data-orientation='horizontal'],\\n/* </DEPRECATED> */\\n.lm-ScrollBar[data-orientation='horizontal'] {\\n  flex-direction: row;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-ScrollBar[data-orientation='vertical'],\\n/* </DEPRECATED> */\\n.lm-ScrollBar[data-orientation='vertical'] {\\n  flex-direction: column;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-ScrollBar-button, /* </DEPRECATED> */\\n.lm-ScrollBar-button {\\n  box-sizing: border-box;\\n  flex: 0 0 auto;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-ScrollBar-track, /* </DEPRECATED> */\\n.lm-ScrollBar-track {\\n  box-sizing: border-box;\\n  position: relative;\\n  overflow: hidden;\\n  flex: 1 1 auto;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-ScrollBar-thumb, /* </DEPRECATED> */\\n.lm-ScrollBar-thumb {\\n  box-sizing: border-box;\\n  position: absolute;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/*-----------------------------------------------------------------------------\\n| Copyright (c) Jupyter Development Team.\\n| Copyright (c) 2014-2017, PhosphorJS Contributors\\n|\\n| Distributed under the terms of the BSD 3-Clause License.\\n|\\n| The full license is in the file LICENSE, distributed with this software.\\n|----------------------------------------------------------------------------*/\\n\\n\\n/* <DEPRECATED> */ .p-SplitPanel-child, /* </DEPRECATED> */\\n.lm-SplitPanel-child {\\n  z-index: 0;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-SplitPanel-handle, /* </DEPRECATED> */\\n.lm-SplitPanel-handle {\\n  z-index: 1;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-SplitPanel-handle.p-mod-hidden, /* </DEPRECATED> */\\n.lm-SplitPanel-handle.lm-mod-hidden {\\n  display: none !important;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-SplitPanel-handle:after, /* </DEPRECATED> */\\n.lm-SplitPanel-handle:after {\\n  position: absolute;\\n  top: 0;\\n  left: 0;\\n  width: 100%;\\n  height: 100%;\\n  content: '';\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-SplitPanel[data-orientation='horizontal'] > .p-SplitPanel-handle,\\n/* </DEPRECATED> */\\n.lm-SplitPanel[data-orientation='horizontal'] > .lm-SplitPanel-handle {\\n  cursor: ew-resize;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-SplitPanel[data-orientation='vertical'] > .p-SplitPanel-handle,\\n/* </DEPRECATED> */\\n.lm-SplitPanel[data-orientation='vertical'] > .lm-SplitPanel-handle {\\n  cursor: ns-resize;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-SplitPanel[data-orientation='horizontal'] > .p-SplitPanel-handle:after,\\n/* </DEPRECATED> */\\n.lm-SplitPanel[data-orientation='horizontal'] > .lm-SplitPanel-handle:after {\\n  left: 50%;\\n  min-width: 8px;\\n  transform: translateX(-50%);\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-SplitPanel[data-orientation='vertical'] > .p-SplitPanel-handle:after,\\n/* </DEPRECATED> */\\n.lm-SplitPanel[data-orientation='vertical'] > .lm-SplitPanel-handle:after {\\n  top: 50%;\\n  min-height: 8px;\\n  transform: translateY(-50%);\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/*-----------------------------------------------------------------------------\\n| Copyright (c) Jupyter Development Team.\\n| Copyright (c) 2014-2017, PhosphorJS Contributors\\n|\\n| Distributed under the terms of the BSD 3-Clause License.\\n|\\n| The full license is in the file LICENSE, distributed with this software.\\n|----------------------------------------------------------------------------*/\\n\\n\\n/* <DEPRECATED> */ .p-TabBar, /* </DEPRECATED> */\\n.lm-TabBar {\\n  display: flex;\\n  -webkit-user-select: none;\\n  -moz-user-select: none;\\n  -ms-user-select: none;\\n  user-select: none;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-TabBar[data-orientation='horizontal'], /* </DEPRECATED> */\\n.lm-TabBar[data-orientation='horizontal'] {\\n  flex-direction: row;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-TabBar[data-orientation='vertical'], /* </DEPRECATED> */\\n.lm-TabBar[data-orientation='vertical'] {\\n  flex-direction: column;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-TabBar-content, /* </DEPRECATED> */\\n.lm-TabBar-content {\\n  margin: 0;\\n  padding: 0;\\n  display: flex;\\n  flex: 1 1 auto;\\n  list-style-type: none;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-TabBar[data-orientation='horizontal'] > .p-TabBar-content,\\n/* </DEPRECATED> */\\n.lm-TabBar[data-orientation='horizontal'] > .lm-TabBar-content {\\n  flex-direction: row;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-TabBar[data-orientation='vertical'] > .p-TabBar-content,\\n/* </DEPRECATED> */\\n.lm-TabBar[data-orientation='vertical'] > .lm-TabBar-content {\\n  flex-direction: column;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-TabBar-tab, /* </DEPRECATED> */\\n.lm-TabBar-tab {\\n  display: flex;\\n  flex-direction: row;\\n  box-sizing: border-box;\\n  overflow: hidden;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-TabBar-tabIcon,\\n.p-TabBar-tabCloseIcon,\\n/* </DEPRECATED> */\\n.lm-TabBar-tabIcon,\\n.lm-TabBar-tabCloseIcon {\\n  flex: 0 0 auto;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-TabBar-tabLabel, /* </DEPRECATED> */\\n.lm-TabBar-tabLabel {\\n  flex: 1 1 auto;\\n  overflow: hidden;\\n  white-space: nowrap;\\n}\\n\\n\\n.lm-TabBar-tabInput {\\n  user-select: all;\\n  width: 100%;\\n  box-sizing : border-box;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-TabBar-tab.p-mod-hidden, /* </DEPRECATED> */\\n.lm-TabBar-tab.lm-mod-hidden {\\n  display: none !important;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-TabBar.p-mod-dragging .p-TabBar-tab, /* </DEPRECATED> */\\n.lm-TabBar.lm-mod-dragging .lm-TabBar-tab {\\n  position: relative;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-TabBar.p-mod-dragging[data-orientation='horizontal'] .p-TabBar-tab,\\n/* </DEPRECATED> */\\n.lm-TabBar.lm-mod-dragging[data-orientation='horizontal'] .lm-TabBar-tab {\\n  left: 0;\\n  transition: left 150ms ease;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-TabBar.p-mod-dragging[data-orientation='vertical'] .p-TabBar-tab,\\n/* </DEPRECATED> */\\n.lm-TabBar.lm-mod-dragging[data-orientation='vertical'] .lm-TabBar-tab {\\n  top: 0;\\n  transition: top 150ms ease;\\n}\\n\\n\\n/* <DEPRECATED> */\\n.p-TabBar.p-mod-dragging .p-TabBar-tab.p-mod-dragging,\\n/* </DEPRECATED> */\\n.lm-TabBar.lm-mod-dragging .lm-TabBar-tab.lm-mod-dragging {\\n  transition: none;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/*-----------------------------------------------------------------------------\\n| Copyright (c) Jupyter Development Team.\\n| Copyright (c) 2014-2017, PhosphorJS Contributors\\n|\\n| Distributed under the terms of the BSD 3-Clause License.\\n|\\n| The full license is in the file LICENSE, distributed with this software.\\n|----------------------------------------------------------------------------*/\\n\\n\\n/* <DEPRECATED> */ .p-TabPanel-tabBar, /* </DEPRECATED> */\\n.lm-TabPanel-tabBar {\\n  z-index: 1;\\n}\\n\\n\\n/* <DEPRECATED> */ .p-TabPanel-stackedPanel, /* </DEPRECATED> */\\n.lm-TabPanel-stackedPanel {\\n  z-index: 0;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","var api = require(\"!../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\");\n            var content = require(\"!!../../../node_modules/css-loader/dist/cjs.js!./index.css\");\n\n            content = content.__esModule ? content.default : content;\n\n            if (typeof content === 'string') {\n              content = [[module.id, content, '']];\n            }\n\nvar options = {};\n\noptions.insert = \"head\";\noptions.singleton = false;\n\nvar update = api(module.id, content, options);\n\nvar exported = content.locals ? content.locals : {};\n\n\n\nmodule.exports = exported;","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/* Copyright (c) Jupyter Development Team.\\n * Distributed under the terms of the Modified BSD License.\\n */\\n\\n .jupyter-widgets-disconnected::before {\\n    content: \\\"\\\\f127\\\"; /* chain-broken */\\n    display: inline-block;\\n    font: normal normal 900 14px/1 'Font Awesome 5 Free', 'FontAwesome';\\n    font-size: inherit;\\n    text-rendering: auto;\\n    -webkit-font-smoothing: antialiased;\\n    -moz-osx-font-smoothing: grayscale;\\n    color: #d9534f;\\n    padding: 3px;\\n    align-self: flex-start;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","var api = require(\"!../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\");\n            var content = require(\"!!../../../node_modules/css-loader/dist/cjs.js!./widgets.css\");\n\n            content = content.__esModule ? content.default : content;\n\n            if (typeof content === 'string') {\n              content = [[module.id, content, '']];\n            }\n\nvar options = {};\n\noptions.insert = \"head\";\noptions.singleton = false;\n\nvar update = api(module.id, content, options);\n\nvar exported = content.locals ? content.locals : {};\n\n\n\nmodule.exports = exported;","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../node_modules/css-loader/dist/runtime/api.js\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_0___ = require(\"-!../../../node_modules/css-loader/dist/cjs.js!./labvariables.css\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_1___ = require(\"-!../../../node_modules/css-loader/dist/cjs.js!./widgets-base.css\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_0___);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_1___);\n// Module\nexports.push([module.id, \"/* Copyright (c) Jupyter Development Team.\\n * Distributed under the terms of the Modified BSD License.\\n */\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../node_modules/css-loader/dist/runtime/api.js\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_0___ = require(\"-!../../../node_modules/css-loader/dist/cjs.js!./materialcolors.css\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_0___);\n// Module\nexports.push([module.id, \"/*-----------------------------------------------------------------------------\\n| Copyright (c) Jupyter Development Team.\\n| Distributed under the terms of the Modified BSD License.\\n|----------------------------------------------------------------------------*/\\n\\n/*\\nThis file is copied from the JupyterLab project to define default styling for\\nwhen the widget styling is compiled down to eliminate CSS variables. We make one\\nchange - we comment out the font import below.\\n*/\\n\\n/*\\nThe following CSS variables define the main, public API for styling JupyterLab.\\nThese variables should be used by all plugins wherever possible. In other\\nwords, plugins should not define custom colors, sizes, etc unless absolutely\\nnecessary. This enables users to change the visual theme of JupyterLab\\nby changing these variables.\\n\\nMany variables appear in an ordered sequence (0,1,2,3). These sequences\\nare designed to work well together, so for example, `--jp-border-color1` should\\nbe used with `--jp-layout-color1`. The numbers have the following meanings:\\n\\n* 0: super-primary, reserved for special emphasis\\n* 1: primary, most important under normal situations\\n* 2: secondary, next most important under normal situations\\n* 3: tertiary, next most important under normal situations\\n\\nThroughout JupyterLab, we are mostly following principles from Google's\\nMaterial Design when selecting colors. We are not, however, following\\nall of MD as it is not optimized for dense, information rich UIs.\\n*/\\n\\n\\n/*\\n * Optional monospace font for input/output prompt.\\n */\\n /* Commented out in ipywidgets since we don't need it. */\\n/* @import url('https://fonts.googleapis.com/css?family=Roboto+Mono'); */\\n\\n/*\\n * Added for compabitility with output area\\n */\\n:root {\\n  --jp-icon-search: none;\\n  --jp-ui-select-caret: none;\\n}\\n\\n\\n:root {\\n\\n  /* Borders\\n\\n  The following variables, specify the visual styling of borders in JupyterLab.\\n   */\\n\\n  --jp-border-width: 1px;\\n  --jp-border-color0: var(--md-grey-700);\\n  --jp-border-color1: var(--md-grey-500);\\n  --jp-border-color2: var(--md-grey-300);\\n  --jp-border-color3: var(--md-grey-100);\\n\\n  /* UI Fonts\\n\\n  The UI font CSS variables are used for the typography all of the JupyterLab\\n  user interface elements that are not directly user generated content.\\n  */\\n\\n  --jp-ui-font-scale-factor: 1.2;\\n  --jp-ui-font-size0: calc(var(--jp-ui-font-size1)/var(--jp-ui-font-scale-factor));\\n  --jp-ui-font-size1: 13px; /* Base font size */\\n  --jp-ui-font-size2: calc(var(--jp-ui-font-size1)*var(--jp-ui-font-scale-factor));\\n  --jp-ui-font-size3: calc(var(--jp-ui-font-size2)*var(--jp-ui-font-scale-factor));\\n  --jp-ui-icon-font-size: 14px; /* Ensures px perfect FontAwesome icons */\\n  --jp-ui-font-family: \\\"Helvetica Neue\\\", Helvetica, Arial, sans-serif;\\n\\n  /* Use these font colors against the corresponding main layout colors.\\n     In a light theme, these go from dark to light.\\n  */\\n\\n  --jp-ui-font-color0: rgba(0,0,0,1.0);\\n  --jp-ui-font-color1: rgba(0,0,0,0.8);\\n  --jp-ui-font-color2: rgba(0,0,0,0.5);\\n  --jp-ui-font-color3: rgba(0,0,0,0.3);\\n\\n  /* Use these against the brand/accent/warn/error colors.\\n     These will typically go from light to darker, in both a dark and light theme\\n   */\\n\\n  --jp-ui-inverse-font-color0: rgba(255, 255, 255, 1);\\n  --jp-ui-inverse-font-color1: rgba(255, 255, 255, 1);\\n  --jp-ui-inverse-font-color2: rgba(255, 255, 255, 0.7);\\n  --jp-ui-inverse-font-color3: rgba(255, 255, 255, 0.5);\\n\\n  /* For backwards compatibility, we still define these below until ipywidgets 8.0.\\n  See https://github.com/jupyter-widgets/ipywidgets/pull/2801 */\\n  --jp-inverse-ui-font-color0: rgba(255,255,255,1);\\n  --jp-inverse-ui-font-color1: rgba(255,255,255,1.0);\\n  --jp-inverse-ui-font-color2: rgba(255,255,255,0.7);\\n  --jp-inverse-ui-font-color3: rgba(255,255,255,0.5);\\n\\n  /* Content Fonts\\n\\n  Content font variables are used for typography of user generated content.\\n  */\\n\\n  --jp-content-font-size: 13px;\\n  --jp-content-line-height: 1.5;\\n  --jp-content-font-color0: black;\\n  --jp-content-font-color1: black;\\n  --jp-content-font-color2: var(--md-grey-700);\\n  --jp-content-font-color3: var(--md-grey-500);\\n\\n  --jp-ui-font-scale-factor: 1.2;\\n  --jp-ui-font-size0: calc(var(--jp-ui-font-size1)/var(--jp-ui-font-scale-factor));\\n  --jp-ui-font-size1: 13px; /* Base font size */\\n  --jp-ui-font-size2: calc(var(--jp-ui-font-size1)*var(--jp-ui-font-scale-factor));\\n  --jp-ui-font-size3: calc(var(--jp-ui-font-size2)*var(--jp-ui-font-scale-factor));\\n\\n  --jp-code-font-size: 13px;\\n  --jp-code-line-height: 1.307;\\n  --jp-code-padding: 5px;\\n  --jp-code-font-family: monospace;\\n\\n\\n  /* Layout\\n\\n  The following are the main layout colors use in JupyterLab. In a light\\n  theme these would go from light to dark.\\n  */\\n\\n  --jp-layout-color0: white;\\n  --jp-layout-color1: white;\\n  --jp-layout-color2: var(--md-grey-200);\\n  --jp-layout-color3: var(--md-grey-400);\\n\\n  /* Brand/accent */\\n\\n  --jp-brand-color0: var(--md-blue-700);\\n  --jp-brand-color1: var(--md-blue-500);\\n  --jp-brand-color2: var(--md-blue-300);\\n  --jp-brand-color3: var(--md-blue-100);\\n\\n  --jp-accent-color0: var(--md-green-700);\\n  --jp-accent-color1: var(--md-green-500);\\n  --jp-accent-color2: var(--md-green-300);\\n  --jp-accent-color3: var(--md-green-100);\\n\\n  /* State colors (warn, error, success, info) */\\n\\n  --jp-warn-color0: var(--md-orange-700);\\n  --jp-warn-color1: var(--md-orange-500);\\n  --jp-warn-color2: var(--md-orange-300);\\n  --jp-warn-color3: var(--md-orange-100);\\n\\n  --jp-error-color0: var(--md-red-700);\\n  --jp-error-color1: var(--md-red-500);\\n  --jp-error-color2: var(--md-red-300);\\n  --jp-error-color3: var(--md-red-100);\\n\\n  --jp-success-color0: var(--md-green-700);\\n  --jp-success-color1: var(--md-green-500);\\n  --jp-success-color2: var(--md-green-300);\\n  --jp-success-color3: var(--md-green-100);\\n\\n  --jp-info-color0: var(--md-cyan-700);\\n  --jp-info-color1: var(--md-cyan-500);\\n  --jp-info-color2: var(--md-cyan-300);\\n  --jp-info-color3: var(--md-cyan-100);\\n\\n  /* Cell specific styles */\\n\\n  --jp-cell-padding: 5px;\\n  --jp-cell-editor-background: #f7f7f7;\\n  --jp-cell-editor-border-color: #cfcfcf;\\n  --jp-cell-editor-background-edit: var(--jp-ui-layout-color1);\\n  --jp-cell-editor-border-color-edit: var(--jp-brand-color1);\\n  --jp-cell-prompt-width: 100px;\\n  --jp-cell-prompt-font-family: 'Roboto Mono', monospace;\\n  --jp-cell-prompt-letter-spacing: 0px;\\n  --jp-cell-prompt-opacity: 1.0;\\n  --jp-cell-prompt-opacity-not-active: 0.4;\\n  --jp-cell-prompt-font-color-not-active: var(--md-grey-700);\\n  /* A custom blend of MD grey and blue 600\\n   * See https://meyerweb.com/eric/tools/color-blend/#546E7A:1E88E5:5:hex */\\n  --jp-cell-inprompt-font-color: #307FC1;\\n  /* A custom blend of MD grey and orange 600\\n   * https://meyerweb.com/eric/tools/color-blend/#546E7A:F4511E:5:hex */\\n  --jp-cell-outprompt-font-color: #BF5B3D;\\n\\n  /* Notebook specific styles */\\n\\n  --jp-notebook-padding: 10px;\\n  --jp-notebook-scroll-padding: 100px;\\n\\n  /* Console specific styles */\\n\\n  --jp-console-background: var(--md-grey-100);\\n\\n  /* Toolbar specific styles */\\n\\n  --jp-toolbar-border-color: var(--md-grey-400);\\n  --jp-toolbar-micro-height: 8px;\\n  --jp-toolbar-background: var(--jp-layout-color0);\\n  --jp-toolbar-box-shadow: 0px 0px 2px 0px rgba(0,0,0,0.24);\\n  --jp-toolbar-header-margin: 4px 4px 0px 4px;\\n  --jp-toolbar-active-background: var(--md-grey-300);\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/**\\n * The material design colors are adapted from google-material-color v1.2.6\\n * https://github.com/danlevan/google-material-color\\n * https://github.com/danlevan/google-material-color/blob/f67ca5f4028b2f1b34862f64b0ca67323f91b088/dist/palette.var.css\\n *\\n * The license for the material design color CSS variables is as follows (see\\n * https://github.com/danlevan/google-material-color/blob/f67ca5f4028b2f1b34862f64b0ca67323f91b088/LICENSE)\\n *\\n * The MIT License (MIT)\\n *\\n * Copyright (c) 2014 Dan Le Van\\n *\\n * Permission is hereby granted, free of charge, to any person obtaining a copy\\n * of this software and associated documentation files (the \\\"Software\\\"), to deal\\n * in the Software without restriction, including without limitation the rights\\n * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\\n * copies of the Software, and to permit persons to whom the Software is\\n * furnished to do so, subject to the following conditions:\\n *\\n * The above copyright notice and this permission notice shall be included in\\n * all copies or substantial portions of the Software.\\n *\\n * THE SOFTWARE IS PROVIDED \\\"AS IS\\\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\\n * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\\n * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\\n * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\\n * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\\n * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\\n * SOFTWARE.\\n */\\n:root {\\n  --md-red-50: #FFEBEE;\\n  --md-red-100: #FFCDD2;\\n  --md-red-200: #EF9A9A;\\n  --md-red-300: #E57373;\\n  --md-red-400: #EF5350;\\n  --md-red-500: #F44336;\\n  --md-red-600: #E53935;\\n  --md-red-700: #D32F2F;\\n  --md-red-800: #C62828;\\n  --md-red-900: #B71C1C;\\n  --md-red-A100: #FF8A80;\\n  --md-red-A200: #FF5252;\\n  --md-red-A400: #FF1744;\\n  --md-red-A700: #D50000;\\n\\n  --md-pink-50: #FCE4EC;\\n  --md-pink-100: #F8BBD0;\\n  --md-pink-200: #F48FB1;\\n  --md-pink-300: #F06292;\\n  --md-pink-400: #EC407A;\\n  --md-pink-500: #E91E63;\\n  --md-pink-600: #D81B60;\\n  --md-pink-700: #C2185B;\\n  --md-pink-800: #AD1457;\\n  --md-pink-900: #880E4F;\\n  --md-pink-A100: #FF80AB;\\n  --md-pink-A200: #FF4081;\\n  --md-pink-A400: #F50057;\\n  --md-pink-A700: #C51162;\\n\\n  --md-purple-50: #F3E5F5;\\n  --md-purple-100: #E1BEE7;\\n  --md-purple-200: #CE93D8;\\n  --md-purple-300: #BA68C8;\\n  --md-purple-400: #AB47BC;\\n  --md-purple-500: #9C27B0;\\n  --md-purple-600: #8E24AA;\\n  --md-purple-700: #7B1FA2;\\n  --md-purple-800: #6A1B9A;\\n  --md-purple-900: #4A148C;\\n  --md-purple-A100: #EA80FC;\\n  --md-purple-A200: #E040FB;\\n  --md-purple-A400: #D500F9;\\n  --md-purple-A700: #AA00FF;\\n\\n  --md-deep-purple-50: #EDE7F6;\\n  --md-deep-purple-100: #D1C4E9;\\n  --md-deep-purple-200: #B39DDB;\\n  --md-deep-purple-300: #9575CD;\\n  --md-deep-purple-400: #7E57C2;\\n  --md-deep-purple-500: #673AB7;\\n  --md-deep-purple-600: #5E35B1;\\n  --md-deep-purple-700: #512DA8;\\n  --md-deep-purple-800: #4527A0;\\n  --md-deep-purple-900: #311B92;\\n  --md-deep-purple-A100: #B388FF;\\n  --md-deep-purple-A200: #7C4DFF;\\n  --md-deep-purple-A400: #651FFF;\\n  --md-deep-purple-A700: #6200EA;\\n\\n  --md-indigo-50: #E8EAF6;\\n  --md-indigo-100: #C5CAE9;\\n  --md-indigo-200: #9FA8DA;\\n  --md-indigo-300: #7986CB;\\n  --md-indigo-400: #5C6BC0;\\n  --md-indigo-500: #3F51B5;\\n  --md-indigo-600: #3949AB;\\n  --md-indigo-700: #303F9F;\\n  --md-indigo-800: #283593;\\n  --md-indigo-900: #1A237E;\\n  --md-indigo-A100: #8C9EFF;\\n  --md-indigo-A200: #536DFE;\\n  --md-indigo-A400: #3D5AFE;\\n  --md-indigo-A700: #304FFE;\\n\\n  --md-blue-50: #E3F2FD;\\n  --md-blue-100: #BBDEFB;\\n  --md-blue-200: #90CAF9;\\n  --md-blue-300: #64B5F6;\\n  --md-blue-400: #42A5F5;\\n  --md-blue-500: #2196F3;\\n  --md-blue-600: #1E88E5;\\n  --md-blue-700: #1976D2;\\n  --md-blue-800: #1565C0;\\n  --md-blue-900: #0D47A1;\\n  --md-blue-A100: #82B1FF;\\n  --md-blue-A200: #448AFF;\\n  --md-blue-A400: #2979FF;\\n  --md-blue-A700: #2962FF;\\n\\n  --md-light-blue-50: #E1F5FE;\\n  --md-light-blue-100: #B3E5FC;\\n  --md-light-blue-200: #81D4FA;\\n  --md-light-blue-300: #4FC3F7;\\n  --md-light-blue-400: #29B6F6;\\n  --md-light-blue-500: #03A9F4;\\n  --md-light-blue-600: #039BE5;\\n  --md-light-blue-700: #0288D1;\\n  --md-light-blue-800: #0277BD;\\n  --md-light-blue-900: #01579B;\\n  --md-light-blue-A100: #80D8FF;\\n  --md-light-blue-A200: #40C4FF;\\n  --md-light-blue-A400: #00B0FF;\\n  --md-light-blue-A700: #0091EA;\\n\\n  --md-cyan-50: #E0F7FA;\\n  --md-cyan-100: #B2EBF2;\\n  --md-cyan-200: #80DEEA;\\n  --md-cyan-300: #4DD0E1;\\n  --md-cyan-400: #26C6DA;\\n  --md-cyan-500: #00BCD4;\\n  --md-cyan-600: #00ACC1;\\n  --md-cyan-700: #0097A7;\\n  --md-cyan-800: #00838F;\\n  --md-cyan-900: #006064;\\n  --md-cyan-A100: #84FFFF;\\n  --md-cyan-A200: #18FFFF;\\n  --md-cyan-A400: #00E5FF;\\n  --md-cyan-A700: #00B8D4;\\n\\n  --md-teal-50: #E0F2F1;\\n  --md-teal-100: #B2DFDB;\\n  --md-teal-200: #80CBC4;\\n  --md-teal-300: #4DB6AC;\\n  --md-teal-400: #26A69A;\\n  --md-teal-500: #009688;\\n  --md-teal-600: #00897B;\\n  --md-teal-700: #00796B;\\n  --md-teal-800: #00695C;\\n  --md-teal-900: #004D40;\\n  --md-teal-A100: #A7FFEB;\\n  --md-teal-A200: #64FFDA;\\n  --md-teal-A400: #1DE9B6;\\n  --md-teal-A700: #00BFA5;\\n\\n  --md-green-50: #E8F5E9;\\n  --md-green-100: #C8E6C9;\\n  --md-green-200: #A5D6A7;\\n  --md-green-300: #81C784;\\n  --md-green-400: #66BB6A;\\n  --md-green-500: #4CAF50;\\n  --md-green-600: #43A047;\\n  --md-green-700: #388E3C;\\n  --md-green-800: #2E7D32;\\n  --md-green-900: #1B5E20;\\n  --md-green-A100: #B9F6CA;\\n  --md-green-A200: #69F0AE;\\n  --md-green-A400: #00E676;\\n  --md-green-A700: #00C853;\\n\\n  --md-light-green-50: #F1F8E9;\\n  --md-light-green-100: #DCEDC8;\\n  --md-light-green-200: #C5E1A5;\\n  --md-light-green-300: #AED581;\\n  --md-light-green-400: #9CCC65;\\n  --md-light-green-500: #8BC34A;\\n  --md-light-green-600: #7CB342;\\n  --md-light-green-700: #689F38;\\n  --md-light-green-800: #558B2F;\\n  --md-light-green-900: #33691E;\\n  --md-light-green-A100: #CCFF90;\\n  --md-light-green-A200: #B2FF59;\\n  --md-light-green-A400: #76FF03;\\n  --md-light-green-A700: #64DD17;\\n\\n  --md-lime-50: #F9FBE7;\\n  --md-lime-100: #F0F4C3;\\n  --md-lime-200: #E6EE9C;\\n  --md-lime-300: #DCE775;\\n  --md-lime-400: #D4E157;\\n  --md-lime-500: #CDDC39;\\n  --md-lime-600: #C0CA33;\\n  --md-lime-700: #AFB42B;\\n  --md-lime-800: #9E9D24;\\n  --md-lime-900: #827717;\\n  --md-lime-A100: #F4FF81;\\n  --md-lime-A200: #EEFF41;\\n  --md-lime-A400: #C6FF00;\\n  --md-lime-A700: #AEEA00;\\n\\n  --md-yellow-50: #FFFDE7;\\n  --md-yellow-100: #FFF9C4;\\n  --md-yellow-200: #FFF59D;\\n  --md-yellow-300: #FFF176;\\n  --md-yellow-400: #FFEE58;\\n  --md-yellow-500: #FFEB3B;\\n  --md-yellow-600: #FDD835;\\n  --md-yellow-700: #FBC02D;\\n  --md-yellow-800: #F9A825;\\n  --md-yellow-900: #F57F17;\\n  --md-yellow-A100: #FFFF8D;\\n  --md-yellow-A200: #FFFF00;\\n  --md-yellow-A400: #FFEA00;\\n  --md-yellow-A700: #FFD600;\\n\\n  --md-amber-50: #FFF8E1;\\n  --md-amber-100: #FFECB3;\\n  --md-amber-200: #FFE082;\\n  --md-amber-300: #FFD54F;\\n  --md-amber-400: #FFCA28;\\n  --md-amber-500: #FFC107;\\n  --md-amber-600: #FFB300;\\n  --md-amber-700: #FFA000;\\n  --md-amber-800: #FF8F00;\\n  --md-amber-900: #FF6F00;\\n  --md-amber-A100: #FFE57F;\\n  --md-amber-A200: #FFD740;\\n  --md-amber-A400: #FFC400;\\n  --md-amber-A700: #FFAB00;\\n\\n  --md-orange-50: #FFF3E0;\\n  --md-orange-100: #FFE0B2;\\n  --md-orange-200: #FFCC80;\\n  --md-orange-300: #FFB74D;\\n  --md-orange-400: #FFA726;\\n  --md-orange-500: #FF9800;\\n  --md-orange-600: #FB8C00;\\n  --md-orange-700: #F57C00;\\n  --md-orange-800: #EF6C00;\\n  --md-orange-900: #E65100;\\n  --md-orange-A100: #FFD180;\\n  --md-orange-A200: #FFAB40;\\n  --md-orange-A400: #FF9100;\\n  --md-orange-A700: #FF6D00;\\n\\n  --md-deep-orange-50: #FBE9E7;\\n  --md-deep-orange-100: #FFCCBC;\\n  --md-deep-orange-200: #FFAB91;\\n  --md-deep-orange-300: #FF8A65;\\n  --md-deep-orange-400: #FF7043;\\n  --md-deep-orange-500: #FF5722;\\n  --md-deep-orange-600: #F4511E;\\n  --md-deep-orange-700: #E64A19;\\n  --md-deep-orange-800: #D84315;\\n  --md-deep-orange-900: #BF360C;\\n  --md-deep-orange-A100: #FF9E80;\\n  --md-deep-orange-A200: #FF6E40;\\n  --md-deep-orange-A400: #FF3D00;\\n  --md-deep-orange-A700: #DD2C00;\\n\\n  --md-brown-50: #EFEBE9;\\n  --md-brown-100: #D7CCC8;\\n  --md-brown-200: #BCAAA4;\\n  --md-brown-300: #A1887F;\\n  --md-brown-400: #8D6E63;\\n  --md-brown-500: #795548;\\n  --md-brown-600: #6D4C41;\\n  --md-brown-700: #5D4037;\\n  --md-brown-800: #4E342E;\\n  --md-brown-900: #3E2723;\\n\\n  --md-grey-50: #FAFAFA;\\n  --md-grey-100: #F5F5F5;\\n  --md-grey-200: #EEEEEE;\\n  --md-grey-300: #E0E0E0;\\n  --md-grey-400: #BDBDBD;\\n  --md-grey-500: #9E9E9E;\\n  --md-grey-600: #757575;\\n  --md-grey-700: #616161;\\n  --md-grey-800: #424242;\\n  --md-grey-900: #212121;\\n\\n  --md-blue-grey-50: #ECEFF1;\\n  --md-blue-grey-100: #CFD8DC;\\n  --md-blue-grey-200: #B0BEC5;\\n  --md-blue-grey-300: #90A4AE;\\n  --md-blue-grey-400: #78909C;\\n  --md-blue-grey-500: #607D8B;\\n  --md-blue-grey-600: #546E7A;\\n  --md-blue-grey-700: #455A64;\\n  --md-blue-grey-800: #37474F;\\n  --md-blue-grey-900: #263238;\\n}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../node_modules/css-loader/dist/runtime/api.js\");\nvar ___CSS_LOADER_AT_RULE_IMPORT_0___ = require(\"-!../../../node_modules/css-loader/dist/cjs.js!./phosphor.css\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\nexports.i(___CSS_LOADER_AT_RULE_IMPORT_0___);\n// Module\nexports.push([module.id, \"/* Copyright (c) Jupyter Development Team.\\n * Distributed under the terms of the Modified BSD License.\\n */\\n\\n/*\\n * We assume that the CSS variables in\\n * https://github.com/jupyterlab/jupyterlab/blob/master/src/default-theme/variables.css\\n * have been defined.\\n */\\n\\n:root {\\n    --jp-widgets-color: var(--jp-content-font-color1);\\n    --jp-widgets-label-color: var(--jp-widgets-color);\\n    --jp-widgets-readout-color: var(--jp-widgets-color);\\n    --jp-widgets-font-size: var(--jp-ui-font-size1);\\n    --jp-widgets-margin: 2px;\\n    --jp-widgets-inline-height: 28px;\\n    --jp-widgets-inline-width: 300px;\\n    --jp-widgets-inline-width-short: calc(var(--jp-widgets-inline-width) / 2 - var(--jp-widgets-margin));\\n    --jp-widgets-inline-width-tiny: calc(var(--jp-widgets-inline-width-short) / 2 - var(--jp-widgets-margin));\\n    --jp-widgets-inline-margin: 4px; /* margin between inline elements */\\n    --jp-widgets-inline-label-width: 80px;\\n    --jp-widgets-border-width: var(--jp-border-width);\\n    --jp-widgets-vertical-height: 200px;\\n    --jp-widgets-horizontal-tab-height: 24px;\\n    --jp-widgets-horizontal-tab-width: 144px;\\n    --jp-widgets-horizontal-tab-top-border: 2px;\\n    --jp-widgets-progress-thickness: 20px;\\n    --jp-widgets-container-padding: 15px;\\n    --jp-widgets-input-padding: 4px;\\n    --jp-widgets-radio-item-height-adjustment: 8px;\\n    --jp-widgets-radio-item-height: calc(var(--jp-widgets-inline-height) - var(--jp-widgets-radio-item-height-adjustment));\\n    --jp-widgets-slider-track-thickness: 4px;\\n    --jp-widgets-slider-border-width: var(--jp-widgets-border-width);\\n    --jp-widgets-slider-handle-size: 16px;\\n    --jp-widgets-slider-handle-border-color: var(--jp-border-color1);\\n    --jp-widgets-slider-handle-background-color: var(--jp-layout-color1);\\n    --jp-widgets-slider-active-handle-color: var(--jp-brand-color1);\\n    --jp-widgets-menu-item-height: 24px;\\n    --jp-widgets-dropdown-arrow: url(\\\"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPCEtLSBHZW5lcmF0b3I6IEFkb2JlIElsbHVzdHJhdG9yIDE5LjIuMSwgU1ZHIEV4cG9ydCBQbHVnLUluIC4gU1ZHIFZlcnNpb246IDYuMDAgQnVpbGQgMCkgIC0tPgo8c3ZnIHZlcnNpb249IjEuMSIgaWQ9IkxheWVyXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4IgoJIHZpZXdCb3g9IjAgMCAxOCAxOCIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgMTggMTg7IiB4bWw6c3BhY2U9InByZXNlcnZlIj4KPHN0eWxlIHR5cGU9InRleHQvY3NzIj4KCS5zdDB7ZmlsbDpub25lO30KPC9zdHlsZT4KPHBhdGggZD0iTTUuMiw1LjlMOSw5LjdsMy44LTMuOGwxLjIsMS4ybC00LjksNWwtNC45LTVMNS4yLDUuOXoiLz4KPHBhdGggY2xhc3M9InN0MCIgZD0iTTAtMC42aDE4djE4SDBWLTAuNnoiLz4KPC9zdmc+Cg\\\");\\n    --jp-widgets-input-color: var(--jp-ui-font-color1);\\n    --jp-widgets-input-background-color: var(--jp-layout-color1);\\n    --jp-widgets-input-border-color: var(--jp-border-color1);\\n    --jp-widgets-input-focus-border-color: var(--jp-brand-color2);\\n    --jp-widgets-input-border-width: var(--jp-widgets-border-width);\\n    --jp-widgets-disabled-opacity: 0.6;\\n\\n    /* From Material Design Lite */\\n    --md-shadow-key-umbra-opacity: 0.2;\\n    --md-shadow-key-penumbra-opacity: 0.14;\\n    --md-shadow-ambient-shadow-opacity: 0.12;\\n}\\n\\n.jupyter-widgets {\\n    margin: var(--jp-widgets-margin);\\n    box-sizing: border-box;\\n    color: var(--jp-widgets-color);\\n    overflow: visible;\\n}\\n\\n.jp-Output-result > .jupyter-widgets {\\n    margin-left: 0;\\n    margin-right: 0;\\n}\\n\\n/* vbox and hbox */\\n\\n.widget-inline-hbox {\\n    /* Horizontal widgets */\\n    box-sizing: border-box;\\n    display: flex;\\n    flex-direction: row;\\n    align-items: baseline;\\n}\\n\\n.widget-inline-vbox {\\n    /* Vertical Widgets */\\n    box-sizing: border-box;\\n    display: flex;\\n    flex-direction: column;\\n    align-items: center;\\n}\\n\\n.widget-box {\\n    box-sizing: border-box;\\n    display: flex;\\n    margin: 0;\\n    overflow: auto;\\n}\\n\\n.widget-gridbox {\\n    box-sizing: border-box;\\n    display: grid;\\n    margin: 0;\\n    overflow: auto;\\n}\\n\\n.widget-hbox {\\n    flex-direction: row;\\n}\\n\\n.widget-vbox {\\n    flex-direction: column;\\n}\\n\\n/* General Button Styling */\\n\\n.jupyter-button {\\n    padding-left: 10px;\\n    padding-right: 10px;\\n    padding-top: 0px;\\n    padding-bottom: 0px;\\n    display: inline-block;\\n    white-space: nowrap;\\n    overflow: hidden;\\n    text-overflow: ellipsis;\\n    text-align: center;\\n    font-size: var(--jp-widgets-font-size);\\n    cursor: pointer;\\n\\n    height: var(--jp-widgets-inline-height);\\n    border: 0px solid;\\n    line-height: var(--jp-widgets-inline-height);\\n    box-shadow: none;\\n\\n    color: var(--jp-ui-font-color1);\\n    background-color: var(--jp-layout-color2);\\n    border-color: var(--jp-border-color2);\\n    border: none;\\n    user-select: none;\\n}\\n\\n.jupyter-button i.fa {\\n    margin-right: var(--jp-widgets-inline-margin);\\n    pointer-events: none;\\n}\\n\\n.jupyter-button:empty:before {\\n    content: \\\"\\\\200b\\\"; /* zero-width space */\\n}\\n\\n.jupyter-widgets.jupyter-button:disabled {\\n    opacity: var(--jp-widgets-disabled-opacity);\\n}\\n\\n.jupyter-button i.fa.center {\\n    margin-right: 0;\\n}\\n\\n.jupyter-button:hover:enabled, .jupyter-button:focus:enabled {\\n    /* MD Lite 2dp shadow */\\n    box-shadow: 0 2px 2px 0 rgba(0, 0, 0, var(--md-shadow-key-penumbra-opacity)),\\n                0 3px 1px -2px rgba(0, 0, 0, var(--md-shadow-key-umbra-opacity)),\\n                0 1px 5px 0 rgba(0, 0, 0, var(--md-shadow-ambient-shadow-opacity));\\n}\\n\\n.jupyter-button:active, .jupyter-button.mod-active {\\n    /* MD Lite 4dp shadow */\\n    box-shadow: 0 4px 5px 0 rgba(0, 0, 0, var(--md-shadow-key-penumbra-opacity)),\\n                0 1px 10px 0 rgba(0, 0, 0, var(--md-shadow-ambient-shadow-opacity)),\\n                0 2px 4px -1px rgba(0, 0, 0, var(--md-shadow-key-umbra-opacity));\\n    color: var(--jp-ui-font-color1);\\n    background-color: var(--jp-layout-color3);\\n}\\n\\n.jupyter-button:focus:enabled {\\n    outline: 1px solid var(--jp-widgets-input-focus-border-color);\\n}\\n\\n/* Button \\\"Primary\\\" Styling */\\n\\n.jupyter-button.mod-primary {\\n    color: var(--jp-ui-inverse-font-color1, var(--jp-inverse-ui-font-color1));\\n    background-color: var(--jp-brand-color1);\\n}\\n\\n.jupyter-button.mod-primary.mod-active {\\n    color: var(--jp-ui-inverse-font-color0, var(--jp-inverse-ui-font-color0));\\n    background-color: var(--jp-brand-color0);\\n}\\n\\n.jupyter-button.mod-primary:active {\\n    color: var(--jp-ui-inverse-font-color0, var(--jp-inverse-ui-font-color0));\\n    background-color: var(--jp-brand-color0);\\n}\\n\\n/* Button \\\"Success\\\" Styling */\\n\\n.jupyter-button.mod-success {\\n    color: var(--jp-ui-inverse-font-color1, var(--jp-inverse-ui-font-color1));\\n    background-color: var(--jp-success-color1);\\n}\\n\\n.jupyter-button.mod-success.mod-active {\\n    color: var(--jp-ui-inverse-font-color0, var(--jp-inverse-ui-font-color0));\\n    background-color: var(--jp-success-color0);\\n}\\n\\n.jupyter-button.mod-success:active {\\n    color: var(--jp-ui-inverse-font-color0, var(--jp-inverse-ui-font-color0));\\n    background-color: var(--jp-success-color0);\\n}\\n\\n /* Button \\\"Info\\\" Styling */\\n\\n.jupyter-button.mod-info {\\n    color: var(--jp-ui-inverse-font-color1, var(--jp-inverse-ui-font-color1));\\n    background-color: var(--jp-info-color1);\\n}\\n\\n.jupyter-button.mod-info.mod-active {\\n    color: var(--jp-ui-inverse-font-color0, var(--jp-inverse-ui-font-color0));\\n    background-color: var(--jp-info-color0);\\n}\\n\\n.jupyter-button.mod-info:active {\\n    color: var(--jp-ui-inverse-font-color0, var(--jp-inverse-ui-font-color0));\\n    background-color: var(--jp-info-color0);\\n}\\n\\n/* Button \\\"Warning\\\" Styling */\\n\\n.jupyter-button.mod-warning {\\n    color: var(--jp-ui-inverse-font-color1, var(--jp-inverse-ui-font-color1));\\n    background-color: var(--jp-warn-color1);\\n}\\n\\n.jupyter-button.mod-warning.mod-active {\\n    color: var(--jp-ui-inverse-font-color0, var(--jp-inverse-ui-font-color0));\\n    background-color: var(--jp-warn-color0);\\n}\\n\\n.jupyter-button.mod-warning:active {\\n    color: var(--jp-ui-inverse-font-color0, var(--jp-inverse-ui-font-color0));\\n    background-color: var(--jp-warn-color0);\\n}\\n\\n/* Button \\\"Danger\\\" Styling */\\n\\n.jupyter-button.mod-danger {\\n    color: var(--jp-ui-inverse-font-color1, var(--jp-inverse-ui-font-color1));\\n    background-color: var(--jp-error-color1);\\n}\\n\\n.jupyter-button.mod-danger.mod-active {\\n    color: var(--jp-ui-inverse-font-color0, var(--jp-inverse-ui-font-color0));\\n    background-color: var(--jp-error-color0);\\n}\\n\\n.jupyter-button.mod-danger:active {\\n    color: var(--jp-ui-inverse-font-color0, var(--jp-inverse-ui-font-color0));\\n    background-color: var(--jp-error-color0);\\n}\\n\\n/* Widget Button, Widget Toggle Button, Widget Upload */\\n\\n.widget-button, .widget-toggle-button, .widget-upload {\\n    width: var(--jp-widgets-inline-width-short);\\n}\\n\\n/* Widget Label Styling */\\n\\n/* Override Bootstrap label css */\\n.jupyter-widgets label {\\n    margin-bottom: initial;\\n}\\n\\n.widget-label-basic {\\n    /* Basic Label */\\n    color: var(--jp-widgets-label-color);\\n    font-size: var(--jp-widgets-font-size);\\n    overflow: hidden;\\n    text-overflow: ellipsis;\\n    white-space: nowrap;\\n    line-height: var(--jp-widgets-inline-height);\\n}\\n\\n.widget-label {\\n    /* Label */\\n    color: var(--jp-widgets-label-color);\\n    font-size: var(--jp-widgets-font-size);\\n    overflow: hidden;\\n    text-overflow: ellipsis;\\n    white-space: nowrap;\\n    line-height: var(--jp-widgets-inline-height);\\n}\\n\\n.widget-inline-hbox .widget-label {\\n    /* Horizontal Widget Label */\\n    color: var(--jp-widgets-label-color);\\n    text-align: right;\\n    margin-right: calc( var(--jp-widgets-inline-margin) * 2 );\\n    width: var(--jp-widgets-inline-label-width);\\n    flex-shrink: 0;\\n}\\n\\n.widget-inline-vbox .widget-label {\\n    /* Vertical Widget Label */\\n    color: var(--jp-widgets-label-color);\\n    text-align: center;\\n    line-height: var(--jp-widgets-inline-height);\\n}\\n\\n/* Widget Readout Styling */\\n\\n.widget-readout {\\n    color: var(--jp-widgets-readout-color);\\n    font-size: var(--jp-widgets-font-size);\\n    height: var(--jp-widgets-inline-height);\\n    line-height: var(--jp-widgets-inline-height);\\n    overflow: hidden;\\n    white-space: nowrap;\\n    text-align: center;\\n}\\n\\n.widget-readout.overflow {\\n    /* Overflowing Readout */\\n\\n    /* From Material Design Lite\\n        shadow-key-umbra-opacity: 0.2;\\n        shadow-key-penumbra-opacity: 0.14;\\n        shadow-ambient-shadow-opacity: 0.12;\\n     */\\n    -webkit-box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.2),\\n                        0 3px 1px -2px rgba(0, 0, 0, 0.14),\\n                        0 1px 5px 0 rgba(0, 0, 0, 0.12);\\n\\n    -moz-box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.2),\\n                     0 3px 1px -2px rgba(0, 0, 0, 0.14),\\n                     0 1px 5px 0 rgba(0, 0, 0, 0.12);\\n\\n    box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.2),\\n                0 3px 1px -2px rgba(0, 0, 0, 0.14),\\n                0 1px 5px 0 rgba(0, 0, 0, 0.12);\\n}\\n\\n.widget-inline-hbox .widget-readout {\\n    /* Horizontal Readout */\\n    text-align: center;\\n    max-width: var(--jp-widgets-inline-width-short);\\n    min-width: var(--jp-widgets-inline-width-tiny);\\n    margin-left: var(--jp-widgets-inline-margin);\\n}\\n\\n.widget-inline-vbox .widget-readout {\\n    /* Vertical Readout */\\n    margin-top: var(--jp-widgets-inline-margin);\\n    /* as wide as the widget */\\n    width: inherit;\\n}\\n\\n/* Widget Checkbox Styling */\\n\\n.widget-checkbox {\\n    width: var(--jp-widgets-inline-width);\\n    height: var(--jp-widgets-inline-height);\\n    line-height: var(--jp-widgets-inline-height);\\n}\\n\\n.widget-checkbox input[type=\\\"checkbox\\\"] {\\n    margin: 0px calc( var(--jp-widgets-inline-margin) * 2 ) 0px 0px;\\n    line-height: var(--jp-widgets-inline-height);\\n    font-size: large;\\n    flex-grow: 1;\\n    flex-shrink: 0;\\n    align-self: center;\\n}\\n\\n/* Widget Valid Styling */\\n\\n.widget-valid {\\n    height: var(--jp-widgets-inline-height);\\n    line-height: var(--jp-widgets-inline-height);\\n    width: var(--jp-widgets-inline-width-short);\\n    font-size: var(--jp-widgets-font-size);\\n}\\n\\n.widget-valid i:before {\\n    line-height: var(--jp-widgets-inline-height);\\n    margin-right: var(--jp-widgets-inline-margin);\\n    margin-left: var(--jp-widgets-inline-margin);\\n}\\n\\n.widget-valid.mod-valid i:before {\\n    color: green;\\n}\\n\\n.widget-valid.mod-invalid i:before {\\n    color: red;\\n}\\n\\n.widget-valid.mod-valid .widget-valid-readout {\\n    display: none;\\n}\\n\\n/* Widget Text and TextArea Stying */\\n\\n.widget-textarea, .widget-text {\\n    width: var(--jp-widgets-inline-width);\\n}\\n\\n.widget-text input[type=\\\"text\\\"], .widget-text input[type=\\\"number\\\"], .widget-text input[type=\\\"password\\\"] {\\n    height: var(--jp-widgets-inline-height);\\n}\\n\\n.widget-text input[type=\\\"text\\\"]:disabled, .widget-text input[type=\\\"number\\\"]:disabled, .widget-text input[type=\\\"password\\\"]:disabled, .widget-textarea textarea:disabled {\\n    opacity: var(--jp-widgets-disabled-opacity);\\n}\\n\\n.widget-text input[type=\\\"text\\\"], .widget-text input[type=\\\"number\\\"], .widget-text input[type=\\\"password\\\"], .widget-textarea textarea {\\n    box-sizing: border-box;\\n    border: var(--jp-widgets-input-border-width) solid var(--jp-widgets-input-border-color);\\n    background-color: var(--jp-widgets-input-background-color);\\n    color: var(--jp-widgets-input-color);\\n    font-size: var(--jp-widgets-font-size);\\n    flex-grow: 1;\\n    min-width: 0; /* This makes it possible for the flexbox to shrink this input */\\n    flex-shrink: 1;\\n    outline: none !important;\\n}\\n    \\n.widget-text input[type=\\\"text\\\"], .widget-text input[type=\\\"password\\\"], .widget-textarea textarea {\\n    padding: var(--jp-widgets-input-padding) calc( var(--jp-widgets-input-padding) *  2);\\n}\\n\\n.widget-text input[type=\\\"number\\\"] {\\n    padding: var(--jp-widgets-input-padding) 0 var(--jp-widgets-input-padding) calc(var(--jp-widgets-input-padding) *  2);\\n}\\n\\n.widget-textarea textarea {\\n    height: inherit;\\n    width: inherit;\\n}\\n\\n.widget-text input:focus, .widget-textarea textarea:focus {\\n    border-color: var(--jp-widgets-input-focus-border-color);\\n}\\n\\n/* Widget Slider */\\n\\n.widget-slider .ui-slider {\\n    /* Slider Track */\\n    border: var(--jp-widgets-slider-border-width) solid var(--jp-layout-color3);\\n    background: var(--jp-layout-color3);\\n    box-sizing: border-box;\\n    position: relative;\\n    border-radius: 0px;\\n}\\n\\n.widget-slider .ui-slider .ui-slider-handle {\\n    /* Slider Handle */\\n    outline: none !important; /* focused slider handles are colored - see below */\\n    position: absolute;\\n    background-color: var(--jp-widgets-slider-handle-background-color);\\n    border: var(--jp-widgets-slider-border-width) solid var(--jp-widgets-slider-handle-border-color);\\n    box-sizing: border-box;\\n    z-index: 1;\\n    background-image: none; /* Override jquery-ui */\\n}\\n\\n/* Override jquery-ui */\\n.widget-slider .ui-slider .ui-slider-handle:hover, .widget-slider .ui-slider .ui-slider-handle:focus {\\n    background-color: var(--jp-widgets-slider-active-handle-color);\\n    border: var(--jp-widgets-slider-border-width) solid var(--jp-widgets-slider-active-handle-color);\\n}\\n\\n.widget-slider .ui-slider .ui-slider-handle:active {\\n    background-color: var(--jp-widgets-slider-active-handle-color);\\n    border-color: var(--jp-widgets-slider-active-handle-color);\\n    z-index: 2;\\n    transform: scale(1.2);\\n}\\n\\n.widget-slider  .ui-slider .ui-slider-range {\\n    /* Interval between the two specified value of a double slider */\\n    position: absolute;\\n    background: var(--jp-widgets-slider-active-handle-color);\\n    z-index: 0;\\n}\\n\\n/* Shapes of Slider Handles */\\n\\n.widget-hslider .ui-slider .ui-slider-handle {\\n    width: var(--jp-widgets-slider-handle-size);\\n    height: var(--jp-widgets-slider-handle-size);\\n    margin-top: calc((var(--jp-widgets-slider-track-thickness) - var(--jp-widgets-slider-handle-size)) / 2 - var(--jp-widgets-slider-border-width));\\n    margin-left: calc(var(--jp-widgets-slider-handle-size) / -2 + var(--jp-widgets-slider-border-width));\\n    border-radius: 50%;\\n    top: 0;\\n}\\n\\n.widget-vslider .ui-slider .ui-slider-handle {\\n    width: var(--jp-widgets-slider-handle-size);\\n    height: var(--jp-widgets-slider-handle-size);\\n    margin-bottom: calc(var(--jp-widgets-slider-handle-size) / -2 + var(--jp-widgets-slider-border-width));\\n    margin-left: calc((var(--jp-widgets-slider-track-thickness) - var(--jp-widgets-slider-handle-size)) / 2 - var(--jp-widgets-slider-border-width));\\n    border-radius: 50%;\\n    left: 0;\\n}\\n\\n.widget-hslider .ui-slider .ui-slider-range {\\n    height: calc( var(--jp-widgets-slider-track-thickness) * 2 );\\n    margin-top: calc((var(--jp-widgets-slider-track-thickness) - var(--jp-widgets-slider-track-thickness) * 2 ) / 2 - var(--jp-widgets-slider-border-width));\\n}\\n\\n.widget-vslider .ui-slider .ui-slider-range {\\n    width: calc( var(--jp-widgets-slider-track-thickness) * 2 );\\n    margin-left: calc((var(--jp-widgets-slider-track-thickness) - var(--jp-widgets-slider-track-thickness) * 2 ) / 2 - var(--jp-widgets-slider-border-width));\\n}\\n\\n/* Horizontal Slider */\\n\\n.widget-hslider {\\n    width: var(--jp-widgets-inline-width);\\n    height: var(--jp-widgets-inline-height);\\n    line-height: var(--jp-widgets-inline-height);\\n\\n    /* Override the align-items baseline. This way, the description and readout\\n    still seem to align their baseline properly, and we don't have to have\\n    align-self: stretch in the .slider-container. */\\n    align-items: center;\\n}\\n\\n.widgets-slider .slider-container {\\n    overflow: visible;\\n}\\n\\n.widget-hslider .slider-container {\\n    height: var(--jp-widgets-inline-height);\\n    margin-left: calc(var(--jp-widgets-slider-handle-size) / 2 - 2 * var(--jp-widgets-slider-border-width));\\n    margin-right: calc(var(--jp-widgets-slider-handle-size) / 2 - 2 * var(--jp-widgets-slider-border-width));\\n    flex: 1 1 var(--jp-widgets-inline-width-short);\\n}\\n\\n.widget-hslider .ui-slider {\\n    /* Inner, invisible slide div */\\n    height: var(--jp-widgets-slider-track-thickness);\\n    margin-top: calc((var(--jp-widgets-inline-height) - var(--jp-widgets-slider-track-thickness)) / 2);\\n    width: 100%;\\n}\\n\\n/* Vertical Slider */\\n\\n.widget-vbox .widget-label {\\n    height: var(--jp-widgets-inline-height);\\n    line-height: var(--jp-widgets-inline-height);\\n}\\n\\n.widget-vslider {\\n    /* Vertical Slider */\\n    height: var(--jp-widgets-vertical-height);\\n    width: var(--jp-widgets-inline-width-tiny);\\n}\\n\\n.widget-vslider .slider-container {\\n    flex: 1 1 var(--jp-widgets-inline-width-short);\\n    margin-left: auto;\\n    margin-right: auto;\\n    margin-bottom: calc(var(--jp-widgets-slider-handle-size) / 2 - 2 * var(--jp-widgets-slider-border-width));\\n    margin-top: calc(var(--jp-widgets-slider-handle-size) / 2 - 2 * var(--jp-widgets-slider-border-width));\\n    display: flex;\\n    flex-direction: column;\\n}\\n\\n.widget-vslider .ui-slider-vertical {\\n    /* Inner, invisible slide div */\\n    width: var(--jp-widgets-slider-track-thickness);\\n    flex-grow: 1;\\n    margin-left: auto;\\n    margin-right: auto;\\n}\\n\\n/* Widget Progress Styling */\\n\\n.progress-bar {\\n    -webkit-transition: none;\\n    -moz-transition: none;\\n    -ms-transition: none;\\n    -o-transition: none;\\n    transition: none;\\n}\\n\\n.progress-bar {\\n    height: var(--jp-widgets-inline-height);\\n}\\n\\n.progress-bar {\\n    background-color: var(--jp-brand-color1);\\n}\\n\\n.progress-bar-success {\\n    background-color: var(--jp-success-color1);\\n}\\n\\n.progress-bar-info {\\n    background-color: var(--jp-info-color1);\\n}\\n\\n.progress-bar-warning {\\n    background-color: var(--jp-warn-color1);\\n}\\n\\n.progress-bar-danger {\\n    background-color: var(--jp-error-color1);\\n}\\n\\n.progress {\\n    background-color: var(--jp-layout-color2);\\n    border: none;\\n    box-shadow: none;\\n}\\n\\n/* Horisontal Progress */\\n\\n.widget-hprogress {\\n    /* Progress Bar */\\n    height: var(--jp-widgets-inline-height);\\n    line-height: var(--jp-widgets-inline-height);\\n    width: var(--jp-widgets-inline-width);\\n    align-items: center;\\n\\n}\\n\\n.widget-hprogress .progress {\\n    flex-grow: 1;\\n    margin-top: var(--jp-widgets-input-padding);\\n    margin-bottom: var(--jp-widgets-input-padding);\\n    align-self: stretch;\\n    /* Override bootstrap style */\\n    height: initial;\\n}\\n\\n/* Vertical Progress */\\n\\n.widget-vprogress {\\n    height: var(--jp-widgets-vertical-height);\\n    width: var(--jp-widgets-inline-width-tiny);\\n}\\n\\n.widget-vprogress .progress {\\n    flex-grow: 1;\\n    width: var(--jp-widgets-progress-thickness);\\n    margin-left: auto;\\n    margin-right: auto;\\n    margin-bottom: 0;\\n}\\n\\n/* Select Widget Styling */\\n\\n.widget-dropdown {\\n    height: var(--jp-widgets-inline-height);\\n    width: var(--jp-widgets-inline-width);\\n    line-height: var(--jp-widgets-inline-height);\\n}\\n\\n.widget-dropdown > select {\\n    padding-right: 20px;\\n    border: var(--jp-widgets-input-border-width) solid var(--jp-widgets-input-border-color);\\n    border-radius: 0;\\n    height: inherit;\\n    flex: 1 1 var(--jp-widgets-inline-width-short);\\n    min-width: 0; /* This makes it possible for the flexbox to shrink this input */\\n    box-sizing: border-box;\\n    outline: none !important;\\n    box-shadow: none;\\n    background-color: var(--jp-widgets-input-background-color);\\n    color: var(--jp-widgets-input-color);\\n    font-size: var(--jp-widgets-font-size);\\n    vertical-align: top;\\n    padding-left: calc( var(--jp-widgets-input-padding) * 2);\\n\\tappearance: none;\\n\\t-webkit-appearance: none;\\n\\t-moz-appearance: none;\\n    background-repeat: no-repeat;\\n\\tbackground-size: 20px;\\n\\tbackground-position: right center;\\n    background-image: var(--jp-widgets-dropdown-arrow);\\n}\\n.widget-dropdown > select:focus {\\n    border-color: var(--jp-widgets-input-focus-border-color);\\n}\\n\\n.widget-dropdown > select:disabled {\\n    opacity: var(--jp-widgets-disabled-opacity);\\n}\\n\\n/* To disable the dotted border in Firefox around select controls.\\n   See http://stackoverflow.com/a/18853002 */\\n.widget-dropdown > select:-moz-focusring {\\n    color: transparent;\\n    text-shadow: 0 0 0 #000;\\n}\\n\\n/* Select and SelectMultiple */\\n\\n.widget-select {\\n    width: var(--jp-widgets-inline-width);\\n    line-height: var(--jp-widgets-inline-height);\\n\\n    /* Because Firefox defines the baseline of a select as the bottom of the\\n    control, we align the entire control to the top and add padding to the\\n    select to get an approximate first line baseline alignment. */\\n    align-items: flex-start;\\n}\\n\\n.widget-select > select {\\n    border: var(--jp-widgets-input-border-width) solid var(--jp-widgets-input-border-color);\\n    background-color: var(--jp-widgets-input-background-color);\\n    color: var(--jp-widgets-input-color);\\n    font-size: var(--jp-widgets-font-size);\\n    flex: 1 1 var(--jp-widgets-inline-width-short);\\n    outline: none !important;\\n    overflow: auto;\\n    height: inherit;\\n\\n    /* Because Firefox defines the baseline of a select as the bottom of the\\n    control, we align the entire control to the top and add padding to the\\n    select to get an approximate first line baseline alignment. */\\n    padding-top: 5px;\\n}\\n\\n.widget-select > select:focus {\\n    border-color: var(--jp-widgets-input-focus-border-color);\\n}\\n\\n.wiget-select > select > option {\\n    padding-left: var(--jp-widgets-input-padding);\\n    line-height: var(--jp-widgets-inline-height);\\n    /* line-height doesn't work on some browsers for select options */\\n    padding-top: calc(var(--jp-widgets-inline-height)-var(--jp-widgets-font-size)/2);\\n    padding-bottom: calc(var(--jp-widgets-inline-height)-var(--jp-widgets-font-size)/2);\\n}\\n\\n\\n\\n/* Toggle Buttons Styling */\\n\\n.widget-toggle-buttons {\\n    line-height: var(--jp-widgets-inline-height);\\n}\\n\\n.widget-toggle-buttons .widget-toggle-button {\\n    margin-left: var(--jp-widgets-margin);\\n    margin-right: var(--jp-widgets-margin);\\n}\\n\\n.widget-toggle-buttons .jupyter-button:disabled {\\n    opacity: var(--jp-widgets-disabled-opacity);\\n}\\n\\n/* Radio Buttons Styling */\\n\\n.widget-radio {\\n    width: var(--jp-widgets-inline-width);\\n    line-height: var(--jp-widgets-inline-height);\\n}\\n\\n.widget-radio-box {\\n    display: flex;\\n    flex-direction: column;\\n    align-items: stretch;\\n    box-sizing: border-box;\\n    flex-grow: 1;\\n    margin-bottom: var(--jp-widgets-radio-item-height-adjustment);\\n}\\n\\n.widget-radio-box label {\\n    height: var(--jp-widgets-radio-item-height);\\n    line-height: var(--jp-widgets-radio-item-height);\\n    font-size: var(--jp-widgets-font-size);\\n}\\n\\n.widget-radio-box input {\\n    height: var(--jp-widgets-radio-item-height);\\n    line-height: var(--jp-widgets-radio-item-height);\\n    margin: 0 calc( var(--jp-widgets-input-padding) * 2 ) 0 1px;\\n    float: left;\\n}\\n\\n/* Color Picker Styling */\\n\\n.widget-colorpicker {\\n    width: var(--jp-widgets-inline-width);\\n    height: var(--jp-widgets-inline-height);\\n    line-height: var(--jp-widgets-inline-height);\\n}\\n\\n.widget-colorpicker > .widget-colorpicker-input {\\n    flex-grow: 1;\\n    flex-shrink: 1;\\n    min-width: var(--jp-widgets-inline-width-tiny);\\n}\\n\\n.widget-colorpicker input[type=\\\"color\\\"] {\\n    width: var(--jp-widgets-inline-height);\\n    height: var(--jp-widgets-inline-height);\\n    padding: 0 2px; /* make the color square actually square on Chrome on OS X */\\n    background: var(--jp-widgets-input-background-color);\\n    color: var(--jp-widgets-input-color);\\n    border: var(--jp-widgets-input-border-width) solid var(--jp-widgets-input-border-color);\\n    border-left: none;\\n    flex-grow: 0;\\n    flex-shrink: 0;\\n    box-sizing: border-box;\\n    align-self: stretch;\\n    outline: none !important;\\n}\\n\\n.widget-colorpicker.concise input[type=\\\"color\\\"] {\\n    border-left: var(--jp-widgets-input-border-width) solid var(--jp-widgets-input-border-color);\\n}\\n\\n.widget-colorpicker input[type=\\\"color\\\"]:focus, .widget-colorpicker input[type=\\\"text\\\"]:focus {\\n    border-color: var(--jp-widgets-input-focus-border-color);\\n}\\n\\n.widget-colorpicker input[type=\\\"text\\\"] {\\n    flex-grow: 1;\\n    outline: none !important;\\n    height: var(--jp-widgets-inline-height);\\n    line-height: var(--jp-widgets-inline-height);\\n    background: var(--jp-widgets-input-background-color);\\n    color: var(--jp-widgets-input-color);\\n    border: var(--jp-widgets-input-border-width) solid var(--jp-widgets-input-border-color);\\n    font-size: var(--jp-widgets-font-size);\\n    padding: var(--jp-widgets-input-padding) calc( var(--jp-widgets-input-padding) *  2 );\\n    min-width: 0; /* This makes it possible for the flexbox to shrink this input */\\n    flex-shrink: 1;\\n    box-sizing: border-box;\\n}\\n\\n.widget-colorpicker input[type=\\\"text\\\"]:disabled {\\n    opacity: var(--jp-widgets-disabled-opacity);\\n}\\n\\n/* Date Picker Styling */\\n\\n.widget-datepicker {\\n    width: var(--jp-widgets-inline-width);\\n    height: var(--jp-widgets-inline-height);\\n    line-height: var(--jp-widgets-inline-height);\\n}\\n\\n.widget-datepicker input[type=\\\"date\\\"] {\\n    flex-grow: 1;\\n    flex-shrink: 1;\\n    min-width: 0; /* This makes it possible for the flexbox to shrink this input */\\n    outline: none !important;\\n    height: var(--jp-widgets-inline-height);\\n    border: var(--jp-widgets-input-border-width) solid var(--jp-widgets-input-border-color);\\n    background-color: var(--jp-widgets-input-background-color);\\n    color: var(--jp-widgets-input-color);\\n    font-size: var(--jp-widgets-font-size);\\n    padding: var(--jp-widgets-input-padding) calc( var(--jp-widgets-input-padding) *  2 );\\n    box-sizing: border-box;\\n}\\n\\n.widget-datepicker input[type=\\\"date\\\"]:focus {\\n    border-color: var(--jp-widgets-input-focus-border-color);\\n}\\n\\n.widget-datepicker input[type=\\\"date\\\"]:invalid {\\n    border-color: var(--jp-warn-color1);\\n}\\n\\n.widget-datepicker input[type=\\\"date\\\"]:disabled {\\n    opacity: var(--jp-widgets-disabled-opacity);\\n}\\n\\n/* Play Widget */\\n\\n.widget-play {\\n    width: var(--jp-widgets-inline-width-short);\\n    display: flex;\\n    align-items: stretch;\\n}\\n\\n.widget-play .jupyter-button {\\n    flex-grow: 1;\\n    height: auto;\\n}\\n\\n.widget-play .jupyter-button:disabled {\\n    opacity: var(--jp-widgets-disabled-opacity);\\n}\\n\\n/* Tab Widget */\\n\\n.jupyter-widgets.widget-tab {\\n    display: flex;\\n    flex-direction: column;\\n}\\n\\n.jupyter-widgets.widget-tab > .p-TabBar {\\n    /* Necessary so that a tab can be shifted down to overlay the border of the box below. */\\n    overflow-x: visible;\\n    overflow-y: visible;\\n}\\n\\n.jupyter-widgets.widget-tab > .p-TabBar > .p-TabBar-content {\\n    /* Make sure that the tab grows from bottom up */\\n    align-items: flex-end;\\n    min-width: 0;\\n    min-height: 0;\\n}\\n\\n.jupyter-widgets.widget-tab > .widget-tab-contents {\\n    width: 100%;\\n    box-sizing: border-box;\\n    margin: 0;\\n    background: var(--jp-layout-color1);\\n    color: var(--jp-ui-font-color1);\\n    border: var(--jp-border-width) solid var(--jp-border-color1);\\n    padding: var(--jp-widgets-container-padding);\\n    flex-grow: 1;\\n    overflow: auto;\\n}\\n\\n.jupyter-widgets.widget-tab > .p-TabBar {\\n    font: var(--jp-widgets-font-size) Helvetica, Arial, sans-serif;\\n    min-height: calc(var(--jp-widgets-horizontal-tab-height) + var(--jp-border-width));\\n}\\n\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tab {\\n    flex: 0 1 var(--jp-widgets-horizontal-tab-width);\\n    min-width: 35px;\\n    min-height: calc(var(--jp-widgets-horizontal-tab-height) + var(--jp-border-width));\\n    line-height: var(--jp-widgets-horizontal-tab-height);\\n    margin-left: calc(-1 * var(--jp-border-width));\\n    padding: 0px 10px;\\n    background: var(--jp-layout-color2);\\n    color: var(--jp-ui-font-color2);\\n    border: var(--jp-border-width) solid var(--jp-border-color1);\\n    border-bottom: none;\\n    position: relative;\\n}\\n\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tab.p-mod-current {\\n    color: var(--jp-ui-font-color0);\\n    /* We want the background to match the tab content background */\\n    background: var(--jp-layout-color1);\\n    min-height: calc(var(--jp-widgets-horizontal-tab-height) + 2 * var(--jp-border-width));\\n    transform: translateY(var(--jp-border-width));\\n    overflow: visible;\\n}\\n\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tab.p-mod-current:before {\\n    position: absolute;\\n    top: calc(-1 * var(--jp-border-width));\\n    left: calc(-1 * var(--jp-border-width));\\n    content: '';\\n    height: var(--jp-widgets-horizontal-tab-top-border);\\n    width: calc(100% + 2 * var(--jp-border-width));\\n    background: var(--jp-brand-color1);\\n}\\n\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tab:first-child {\\n    margin-left: 0;\\n}\\n\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tab:hover:not(.p-mod-current) {\\n    background: var(--jp-layout-color1);\\n    color: var(--jp-ui-font-color1);\\n}\\n\\n.jupyter-widgets.widget-tab > .p-TabBar .p-mod-closable > .p-TabBar-tabCloseIcon {\\n    margin-left: 4px;\\n}\\n\\n/* This font-awesome strategy may not work across FA4 and FA5, but we don't\\nactually support closable tabs, so it really doesn't matter */\\n.jupyter-widgets.widget-tab > .p-TabBar .p-mod-closable > .p-TabBar-tabCloseIcon:before {\\n    font-family: FontAwesome;\\n    content: '\\\\f00d'; /* close */\\n}\\n\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tabIcon,\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tabLabel,\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tabCloseIcon {\\n    line-height: var(--jp-widgets-horizontal-tab-height);\\n}\\n\\n/* Accordion Widget */\\n\\n.p-Collapse {\\n    display: flex;\\n    flex-direction: column;\\n    align-items: stretch;\\n}\\n\\n.p-Collapse-header {\\n    padding: var(--jp-widgets-input-padding);\\n    cursor: pointer;\\n    color: var(--jp-ui-font-color2);\\n    background-color: var(--jp-layout-color2);\\n    border: var(--jp-widgets-border-width) solid var(--jp-border-color1);\\n    padding: calc(var(--jp-widgets-container-padding) * 2 / 3) var(--jp-widgets-container-padding);\\n    font-weight: bold;\\n}\\n\\n.p-Collapse-header:hover {\\n    background-color: var(--jp-layout-color1);\\n    color: var(--jp-ui-font-color1);\\n}\\n\\n.p-Collapse-open > .p-Collapse-header {\\n    background-color: var(--jp-layout-color1);\\n    color: var(--jp-ui-font-color0);\\n    cursor: default;\\n    border-bottom: none;\\n}\\n\\n.p-Collapse-contents {\\n    padding: var(--jp-widgets-container-padding);\\n    background-color: var(--jp-layout-color1);\\n    color: var(--jp-ui-font-color1);\\n    border-left: var(--jp-widgets-border-width) solid var(--jp-border-color1);\\n    border-right: var(--jp-widgets-border-width) solid var(--jp-border-color1);\\n    border-bottom: var(--jp-widgets-border-width) solid var(--jp-border-color1);\\n    overflow: auto;\\n}\\n\\n.p-Accordion {\\n    display: flex;\\n    flex-direction: column;\\n    align-items: stretch;\\n}\\n\\n.p-Accordion .p-Collapse {\\n    margin-bottom: 0;\\n}\\n\\n.p-Accordion .p-Collapse + .p-Collapse {\\n    margin-top: 4px;\\n}\\n\\n\\n\\n/* HTML widget */\\n\\n.widget-html, .widget-htmlmath {\\n    font-size: var(--jp-widgets-font-size);\\n}\\n\\n.widget-html > .widget-html-content, .widget-htmlmath > .widget-html-content {\\n    /* Fill out the area in the HTML widget */\\n    align-self: stretch;\\n    flex-grow: 1;\\n    flex-shrink: 1;\\n    /* Makes sure the baseline is still aligned with other elements */\\n    line-height: var(--jp-widgets-inline-height);\\n    /* Make it possible to have absolutely-positioned elements in the html */\\n    position: relative;\\n}\\n\\n\\n/* Image widget  */\\n\\n.widget-image {\\n    max-width: 100%;\\n    height: auto;\\n}\\n\\n/* cursor fix: https://github.com/jupyter-widgets/ipywidgets/pull/3687\\n   Phosphor/Lumino sets the cursor, which we don't want. Otherwise\\n   a widget does not have the proper cursor when it is a child of an\\n   anchor tag. The two classes give it higher specificity than the\\n   phosphor/lumino classes.\\n*/\\n\\n.jupyter-widgets.lm-Widget, .jupyter-widgets.p-Widget {\\n    cursor: unset;\\n}\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \"/* This file has code derived from PhosphorJS CSS files, as noted below. The license for this PhosphorJS code is:\\n\\nCopyright (c) 2014-2017, PhosphorJS Contributors\\nAll rights reserved.\\n\\nRedistribution and use in source and binary forms, with or without\\nmodification, are permitted provided that the following conditions are met:\\n\\n* Redistributions of source code must retain the above copyright notice, this\\n  list of conditions and the following disclaimer.\\n\\n* Redistributions in binary form must reproduce the above copyright notice,\\n  this list of conditions and the following disclaimer in the documentation\\n  and/or other materials provided with the distribution.\\n\\n* Neither the name of the copyright holder nor the names of its\\n  contributors may be used to endorse or promote products derived from\\n  this software without specific prior written permission.\\n\\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \\\"AS IS\\\"\\nAND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\\nIMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\\nDISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\\nFOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\\nDAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\\nSERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\\nCAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\\nOR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\\nOF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\\n\\n*/\\n\\n/*\\n * The following section is derived from https://github.com/phosphorjs/phosphor/blob/23b9d075ebc5b73ab148b6ebfc20af97f85714c4/packages/widgets/style/tabbar.css \\n * We've scoped the rules so that they are consistent with exactly our code.\\n */\\n\\n.jupyter-widgets.widget-tab > .p-TabBar {\\n  display: flex;\\n  -webkit-user-select: none;\\n  -moz-user-select: none;\\n  -ms-user-select: none;\\n  user-select: none;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar[data-orientation='horizontal'] {\\n  flex-direction: row;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar[data-orientation='vertical'] {\\n  flex-direction: column;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar > .p-TabBar-content {\\n  margin: 0;\\n  padding: 0;\\n  display: flex;\\n  flex: 1 1 auto;\\n  list-style-type: none;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar[data-orientation='horizontal'] > .p-TabBar-content {\\n  flex-direction: row;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar[data-orientation='vertical'] > .p-TabBar-content {\\n  flex-direction: column;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tab {\\n  display: flex;\\n  flex-direction: row;\\n  box-sizing: border-box;\\n  overflow: hidden;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tabIcon,\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tabCloseIcon {\\n  flex: 0 0 auto;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tabLabel {\\n  flex: 1 1 auto;\\n  overflow: hidden;\\n  white-space: nowrap;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar .p-TabBar-tab.p-mod-hidden {\\n  display: none !important;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar.p-mod-dragging .p-TabBar-tab {\\n  position: relative;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar.p-mod-dragging[data-orientation='horizontal'] .p-TabBar-tab {\\n  left: 0;\\n  transition: left 150ms ease;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar.p-mod-dragging[data-orientation='vertical'] .p-TabBar-tab {\\n  top: 0;\\n  transition: top 150ms ease;\\n}\\n\\n\\n.jupyter-widgets.widget-tab > .p-TabBar.p-mod-dragging .p-TabBar-tab.p-mod-dragging {\\n  transition: none;\\n}\\n\\n/* End tabbar.css */\\n\", \"\"]);\n// Exports\nmodule.exports = exports;\n","var __extends = (this && this.__extends) || (function () {\n    var extendStatics = function (d, b) {\n        extendStatics = Object.setPrototypeOf ||\n            ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\n            function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\n        return extendStatics(d, b);\n    };\n    return function (d, b) {\n        extendStatics(d, b);\n        function __() { this.constructor = d; }\n        d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\n    };\n})();\nvar __assign = (this && this.__assign) || function () {\n    __assign = Object.assign || function(t) {\n        for (var s, i = 1, n = arguments.length; i < n; i++) {\n            s = arguments[i];\n            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\n                t[p] = s[p];\n        }\n        return t;\n    };\n    return __assign.apply(this, arguments);\n};\nimport { DOMWidgetModel, DOMWidgetView } from '@jupyter-widgets/base';\nexport var OUTPUT_WIDGET_VERSION = '1.0.0';\nvar OutputModel = /** @class */ (function (_super) {\n    __extends(OutputModel, _super);\n    function OutputModel() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    OutputModel.prototype.defaults = function () {\n        return __assign(__assign({}, _super.prototype.defaults.call(this)), { _model_name: 'OutputModel', _view_name: 'OutputView', _model_module: '@jupyter-widgets/output', _view_module: '@jupyter-widgets/output', _model_module_version: OUTPUT_WIDGET_VERSION, _view_module_version: OUTPUT_WIDGET_VERSION });\n    };\n    return OutputModel;\n}(DOMWidgetModel));\nexport { OutputModel };\nvar OutputView = /** @class */ (function (_super) {\n    __extends(OutputView, _super);\n    function OutputView() {\n        return _super !== null && _super.apply(this, arguments) || this;\n    }\n    return OutputView;\n}(DOMWidgetView));\nexport { OutputView };\n"],"sourceRoot":""}