UNPKG

react-med-img-viewer

Version:

React component for medical image visualization. Interacts with the med-img server

1 lines 976 kB
!function(e,t){for(var r in t)e[r]=t[r]}(exports,function(e){var t={};function r(n){if(t[n])return t[n].exports;var i=t[n]={i:n,l:!1,exports:{}};return e[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)r.d(n,i,function(t){return e[t]}.bind(null,i));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=129)}([function(e,t,r){"use strict";(function(e){r.d(t,"h",(function(){return g})),r.d(t,"i",(function(){return p})),r.d(t,"j",(function(){return h})),r.d(t,"e",(function(){return w})),r.d(t,"b",(function(){return N})),r.d(t,"f",(function(){return C})),r.d(t,"c",(function(){return x})),r.d(t,"g",(function(){return L})),r.d(t,"d",(function(){return O}));var n=r(6);function i(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function a(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if(!(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e)))return;var r=[],n=!0,i=!1,a=void 0;try{for(var o,s=e[Symbol.iterator]();!(n=(o=s.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){i=!0,a=e}finally{try{n||null==s.return||s.return()}finally{if(i)throw a}}return r}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function s(e){return function(e){if(Array.isArray(e)){for(var t=0,r=new Array(e.length);t<e.length;t++)r[t]=e[t];return r}}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}var u=0,c=Symbol("void");var l={};function f(){}["log","debug","info","warn","error","time","timeEnd","group","groupEnd"].forEach((function(e){l[e]=f})),e.console=console.hasOwnProperty("log")?console:l;var d={debug:f,error:e.console.error||f,info:e.console.info||f,log:e.console.log||f,warn:e.console.warn||f};function g(){d.debug.apply(d,arguments)}function p(){d.error.apply(d,arguments)}function h(){d.warn.apply(d,arguments)}var m={};var M={Float32Array:Float32Array,Float64Array:Float64Array,Uint8Array:Uint8Array,Int8Array:Int8Array,Uint16Array:Uint16Array,Int16Array:Int16Array,Uint32Array:Uint32Array,Int32Array:Int32Array};function A(e){return e.charAt(0).toUpperCase()+e.slice(1)}function v(e){Object.keys(e).forEach((function(t){Array.isArray(e[t])&&(e[t]=[].concat(e[t]))}))}function y(e){return e.isA?e.getState():e}function T(e){setTimeout(e,0)}function w(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};v(t);var r=[];function n(e){r[e]=null}function i(e){return Object.freeze({unsubscribe:function(){n(e)}})}return Number.isInteger(t.mtime)||(t.mtime=++u),t.classHierarchy=["vtkObject"],e.isDeleted=function(){return!!t.deleted},e.modified=function(n){t.deleted?p("instance deleted - cannot call any method"):n&&n<e.getMTime()||(t.mtime=++u,r.forEach((function(t){return t&&t(e)})))},e.onModified=function(e){if(t.deleted)return p("instance deleted - cannot call any method"),null;var n=r.length;return r.push(e),i(n)},e.getMTime=function(){return t.mtime},e.isA=function(e){for(var r=t.classHierarchy.length;r--;)if(t.classHierarchy[r]===e)return!0;return!1},e.getClassName=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return t.classHierarchy[t.classHierarchy.length-1-e]},e.set=function(){var r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],a=!1;return Object.keys(r).forEach((function(o){var u=i?null:e["set".concat(A(o))];u&&Array.isArray(r[o])&&u.length>1?a=u.apply(void 0,s(r[o]))||a:u?a=u(r[o])||a:(-1!==["mtime"].indexOf(o)||n||h("Warning: Set value to model directly ".concat(o,", ").concat(r[o])),t[o]=r[o],a=!0)})),a},e.get=function(){for(var e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];if(!r.length)return t;var i={};return r.forEach((function(e){i[e]=t[e]})),i},e.getReferenceByName=function(e){return t[e]},e.delete=function(){Object.keys(t).forEach((function(e){return delete t[e]})),r.forEach((function(e,t){return n(t)})),t.deleted=!0},e.getState=function(){var r=Object.assign({},t,{vtkClass:e.getClassName()});Object.keys(r).forEach((function(e){null===r[e]||void 0===r[e]?delete r[e]:r[e].isA?r[e]=r[e].getState():Array.isArray(r[e])&&(r[e]=r[e].map(y))}));var n={};return Object.keys(r).sort().forEach((function(e){n[e]=r[e]})),n.mtime&&delete n.mtime,n},e.shallowCopy=function(r){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(r.getClassName()!==e.getClassName())throw new Error("Cannot ShallowCopy ".concat(r.getClassName()," into ").concat(e.getClassName()));var i=r.get(),a=Object.keys(t).sort(),o=Object.keys(i).sort();o.forEach((function(e){var r=a.indexOf(e);-1===r?n&&g("add ".concat(e," in shallowCopy")):a.splice(r,1),t[e]=i[e]})),a.length&&n&&g("Untouched keys: ".concat(a.join(", "))),e.modified()},e}function N(e,t,r){r.forEach((function(r){"object"===o(r)?e["get".concat(A(r.name))]=function(){return t[r.name]}:e["get".concat(A(r))]=function(){return t[r]}}))}var D={enum:function(e,t,r){return function(n){if("string"==typeof n){if(void 0!==r.enum[n])return t[r.name]!==r.enum[n]&&(t[r.name]=r.enum[n],e.modified(),!0);throw p("Set Enum with invalid argument ".concat(r,", ").concat(n)),new RangeError("Set Enum with invalid string argument")}if("number"==typeof n){if(t[r.name]!==n){if(-1!==Object.keys(r.enum).map((function(e){return r.enum[e]})).indexOf(n))return t[r.name]=n,e.modified(),!0;throw p("Set Enum outside numeric range ".concat(r,", ").concat(n)),new RangeError("Set Enum outside numeric range")}return!1}throw p("Set Enum with invalid argument (String/Number) ".concat(r,", ").concat(n)),new TypeError("Set Enum with invalid argument (String/Number)")}}};function I(e){if("object"===o(e)){var t=D[e.type];if(t)return function(r,n){return t(r,n,e)};throw p("No setter for field ".concat(e)),new TypeError("No setter for field")}return function(t,r){return function(n){return r.deleted?(p("instance deleted - cannot call any method"),!1):r[e]!==n&&(r[e]=n,t.modified(),!0)}}}function b(e,t,r){r.forEach((function(r){"object"===o(r)?e["set".concat(A(r.name))]=I(r)(e,t):e["set".concat(A(r))]=I(r)(e,t)}))}function C(e,t,r){N(e,t,r),b(e,t,r)}function x(e,t,r){r.forEach((function(r){e["get".concat(A(r))]=function(){return[].concat(t[r])},e["get".concat(A(r),"ByReference")]=function(){return t[r]}}))}function E(e,t,r,n){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:void 0;r.forEach((function(r){e["set".concat(A(r))]=function(){if(t.deleted)return p("instance deleted - cannot call any method"),!1;for(var a=arguments.length,o=new Array(a),s=0;s<a;s++)o[s]=arguments[s];var u=o;if(1===u.length&&Array.isArray(u[0])&&(u=u[0]),u.length!==n){if(!(u.length<n&&void 0!==i))throw new RangeError("Invalid number of values for array setter (".concat(r,")"));for(u=[].concat(u);u.length<n;)u.push(i)}var c=!1;return t[r].forEach((function(e,t){if(e!==u[t]){if(c)return;c=!0}})),(c||t[r].length!==u.length)&&(t[r]=[].concat(u),e.modified()),!0},e["set".concat(A(r),"From")]=function(e){var n=t[r];e.forEach((function(e,t){n[t]=e}))}}))}function L(e,t,r,n){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:void 0;x(e,t,r),E(e,t,r,n,i)}var S=Symbol("Event abort");function O(e,t){var r=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r={},n={};return e(n,r,t),Object.freeze(n)};return t&&n.a.register(t,r),r}function j(e){return e&&e.isA&&e.isA("vtkObject")}function R(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};t.keystore=Object.assign(t.keystore||{},r),e.setKey=function(e,r){t.keystore[e]=r},e.getKey=function(e,r){return t.keystore[e]},e.getAllKeys=function(e,r){return Object.keys(t.keystore)},e.deleteKey=function(e,r){return delete t.keystore[e]},e.clearKeystore=function(){return e.getAllKeys().forEach((function(e){return delete t.keystore[e]}))}}var k=1;t.a={algo:function(e,t,r,i){function a(r){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;t.deleted?p("instance deleted - cannot call any method"):n>=t.numberOfInputs?p("algorithm ".concat(e.getClassName()," only has ").concat(t.numberOfInputs," input ports. To add more input ports, use addInputData()")):(t.inputData[n]!==r||t.inputConnection[n])&&(t.inputData[n]=r,t.inputConnection[n]=null,e.modified&&e.modified())}function o(r){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;if(t.deleted)p("instance deleted - cannot call any method");else{if(n>=t.numberOfInputs){var i="algorithm ".concat(e.getClassName()," only has ");return i+="".concat(t.numberOfInputs),void p(i+=" input ports. To add more input ports, use addInputConnection()")}t.inputData[n]=null,t.inputConnection[n]=r}}function s(){var r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return t.deleted?(p("instance deleted - cannot call any method"),null):(e.shouldUpdate()&&e.update(),t.output[r])}if(t.inputData?t.inputData=t.inputData.map(n.a):t.inputData=[],t.inputConnection?t.inputConnection=t.inputConnection.map(n.a):t.inputConnection=[],t.output?t.output=t.output.map(n.a):t.output=[],t.inputArrayToProcess?t.inputArrayToProcess=t.inputArrayToProcess.map(n.a):t.inputArrayToProcess=[],t.numberOfInputs=r,e.shouldUpdate=function(){for(var r=e.getMTime(),n=i,a=1/0;n--;){if(!t.output[n])return!0;var o=t.output[n].getMTime();if(o<r)return!0;o<a&&(a=o)}for(n=t.numberOfInputs;n--;)if(t.inputConnection[n]&&t.inputConnection[n].filter.shouldUpdate())return!0;for(n=t.numberOfInputs;n--;)if(e.getInputData(n)&&e.getInputData(n).getMTime()>a)return!0;return!1},t.numberOfInputs){for(var u=t.numberOfInputs;u--;)t.inputData.push(null),t.inputConnection.push(null);e.setInputData=a,e.setInputConnection=o,e.addInputData=function(e){t.deleted?p("instance deleted - cannot call any method"):(t.numberOfInputs++,a(e,t.numberOfInputs-1))},e.addInputConnection=function(e){t.deleted?p("instance deleted - cannot call any method"):(t.numberOfInputs++,o(e,t.numberOfInputs-1))},e.getInputData=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return t.inputConnection[e]&&(t.inputData[e]=t.inputConnection[e]()),t.inputData[e]},e.getInputConnection=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return t.inputConnection[e]}}i&&(e.getOutputData=s,e.getOutputPort=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,r=function(){return s(t)};return r.filter=e,r}),e.update=function(){var r=[];if(t.numberOfInputs)for(var n=0;n<t.numberOfInputs;)r[n]=e.getInputData(n),n++;e.shouldUpdate()&&e.requestData&&e.requestData(r,t.output)},e.getNumberOfInputPorts=function(){return t.numberOfInputs},e.getNumberOfOutputPorts=function(){return i||t.output.length},e.getInputArrayToProcess=function(e){var r=t.inputArrayToProcess[e],n=t.inputData[e];return r&&n?n["get".concat(r.fieldAssociation)]().getArray(r.arrayName):null},e.setInputArrayToProcess=function(e,r,n){for(var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"Scalars";t.inputArrayToProcess.length<e;)t.inputArrayToProcess.push(null);t.inputArrayToProcess[e]={arrayName:r,fieldAssociation:n,attributeType:i}}},capitalize:A,chain:function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return function(){for(var e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];return t.filter((function(e){return!!e})).map((function(e){return e.apply(void 0,r)}))}},debounce:function(e,t,r){var n,i=this;return function(){for(var a=arguments.length,o=new Array(a),s=0;s<a;s++)o[s]=arguments[s];var u=i,c=function(){n=null,r||e.apply(u,o)},l=r&&!n;clearTimeout(n),n=setTimeout(c,t),l&&e.apply(u,o)}},enumToString:function(e,t){return Object.keys(e).find((function(r){return e[r]===t}))},event:function(e,t,r){var n=[],i=e.delete,o=1;function s(e){for(var t=0;t<n.length;++t){if(a(n[t],1)[0]===e)return void n.splice(t,1)}}function u(e){return Object.freeze({unsubscribe:function(){s(e)}})}e["invoke".concat(A(r))]=function(){var r=arguments;if(t.deleted)p("instance deleted - cannot call any method");else{var i=n.slice(),o=function(t){var n=a(i[t],3),o=n[1],s=n[2];if(!o)return"continue";if(s<0)setTimeout((function(){return o.apply(e,r)}),1-s);else if(o.apply(e,r)===S)return"break"};e:for(var s=0;s<i.length;++s){var u=o(s);switch(u){case"continue":continue;case"break":break e}}}},e["on".concat(A(r))]=function(e){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;if(!e.apply)return console.error("Invalid callback for event ".concat(r)),null;if(t.deleted)return p("instance deleted - cannot call any method"),null;var a=o++;return n.push([a,e,i]),n.sort((function(e,t){return t[2]-e[2]})),u(a)},e.delete=function(){i(),n.forEach((function(e){return s(a(e,1)[0])}))}},EVENT_ABORT:S,formatBytesToProperUnit:function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1e3,n=["TB","GB","MB","KB"],i=Number(e),a="B";i>r;)i/=r,a=n.pop();return"".concat(i.toFixed(t)," ").concat(a)},formatNumbersWithThousandSeparator:function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:" ",r=[],n=e;n>1e3;)r.push("000".concat(n%1e3).slice(-3)),n=Math.floor(n/1e3);return n>0&&r.push(n),r.reverse(),r.join(t)},get:N,getArray:x,getCurrentGlobalMTime:function(){return u},getStateArrayMapFunc:y,isVtkObject:j,keystore:R,newInstance:O,normalizeWheel:function(e){var t=0,r=0,n=0,i=0;return"detail"in e&&(r=e.detail),"wheelDelta"in e&&(r=-e.wheelDelta/120),"wheelDeltaY"in e&&(r=-e.wheelDeltaY/120),"wheelDeltaX"in e&&(t=-e.wheelDeltaX/120),"axis"in e&&e.axis===e.HORIZONTAL_AXIS&&(t=r,r=0),n=10*t,i=10*r,"deltaY"in e&&(i=e.deltaY),"deltaX"in e&&(n=e.deltaX),(n||i)&&e.deltaMode&&(1===e.deltaMode?(n*=40,i*=40):(n*=800,i*=800)),n&&!t&&(t=n<1?-1:1),i&&!r&&(r=i<1?-1:1),{spinX:t,spinY:r,pixelX:n,pixelY:i}},obj:w,proxy:function(e,t){R(e,t);var r=e.delete;t.proxyId="".concat(k++),t.ui=JSON.parse(JSON.stringify(t.ui||[])),N(e,t,["proxyId","proxyGroup","proxyName"]),C(e,t,["proxyManager"]);var n={},a={};function o(e,t){a[t]||(a[t]=[]);for(var r=a[t],i=0;i<e.length;i++)r.push(e[i].name),n[e[i].name]=e[i],e[i].children&&e[i].children.length&&o(e[i].children,e[i].name)}function s(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"__root__";return a[e]}function u(){for(var r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"__root__",n=[],i=t.proxyId,a=s(r)||[],o=0;o<a.length;o++){var c=a[o],l=e["get".concat(A(c))],f=l?l():void 0,d={id:i,name:c,value:f},g=u(c);g.length&&(d.children=g),n.push(d)}return n}o(t.ui,"__root__"),e.updateUI=function(r){t.ui=JSON.parse(JSON.stringify(r||[])),Object.keys(n).forEach((function(e){return delete n[e]})),Object.keys(a).forEach((function(e){return delete a[e]})),o(t.ui,"__root__"),e.modified()},e.updateProxyProperty=function(e,t){var r=n[e];r?Object.assign(r,t):n[e]=Object.assign({},t)},e.activate=function(){if(t.proxyManager){var r="setActive".concat(A(e.getProxyGroup().slice(0,-1)));t.proxyManager[r]&&t.proxyManager[r](e)}},t.propertyLinkSubscribers={},e.registerPropertyLinkForGC=function(e,r){r in t.propertyLinkSubscribers||(t.propertyLinkSubscribers[r]=[]),t.propertyLinkSubscribers[r].push(e)},e.gcPropertyLinks=function(r){for(var n=t.propertyLinkSubscribers[r]||[];n.length;)n.pop().unbind(e)},t.propertyLinkMap={},e.getPropertyLink=function(e){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(t.propertyLinkMap[e])return t.propertyLinkMap[e];var n=null,a=[],o=0,s=!1;function u(r){var u=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(s)return null;var c=[],l=null;for(o=a.length;o--;){var f=a[o];f.instance===r?l=f:c.push(f)}if(!l)return null;var d=l.instance["get".concat(A(l.propertyName))]();if(d!==n||u){for(n=d,s=!0;c.length;){var g=c.pop();g.instance.set(i({},g.propertyName,n))}s=!1}return t.propertyLinkMap[e].persistent&&(t.propertyLinkMap[e].value=d),d}function c(e,t){var r=[];for(o=a.length;o--;){var n=a[o];n.instance!==e||n.propertyName!==t&&void 0!==t||(n.subscription.unsubscribe(),r.push(o))}for(;r.length;)a.splice(r.pop(),1)}function l(r,n){var o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],s=r.onModified(u),l=a[0];return a.push({instance:r,propertyName:n,subscription:s}),o&&(t.propertyLinkMap[e].persistent&&void 0!==t.propertyLinkMap[e].value?r.set(i({},n,t.propertyLinkMap[e].value)):l&&u(l.instance,!0)),{unsubscribe:function(){return c(r,n)}}}function f(){for(;a.length;)a.pop().subscription.unsubscribe()}var d={bind:l,unbind:c,unsubscribe:f,persistent:r};return t.propertyLinkMap[e]=d,d},e.listPropertyNames=function(){return u().map((function(e){return e.name}))},e.getPropertyByName=function(e){return u().find((function(t){return t.name===e}))},e.getPropertyDomainByName=function(e){return n[e].domain},e.getProxySection=function(){return{id:t.proxyId,name:t.proxyGroup,ui:t.ui,properties:u()}},e.delete=function(){for(var n=Object.keys(t.propertyLinkMap),i=n.length;i--;)t.propertyLinkMap[n[i]].unsubscribe();Object.keys(t.propertyLinkSubscribers).forEach(e.gcPropertyLinks),r()},T((function(){if(t.links)for(var r=0;r<t.links.length;r++){var n=t.links[r],i=n.link,a=n.property,o=n.persistent,s=n.updateOnBind;if("application"===n.type){var u=t.proxyManager.getPropertyLink(i,o);e.registerPropertyLinkForGC(u,"application"),u.bind(e,a,s)}}}))},proxyPropertyMapping:function(e,t,r){for(var n=e.delete,i=[],a=Object.keys(r),o=a.length;o--;){var s=a[o],u=r[s],c=u.modelKey,l=u.property,f=u.modified,d=void 0===f||f,g=A(l),p=A(s);e["get".concat(p)]=t[c]["get".concat(g)],e["set".concat(p)]=t[c]["set".concat(g)],d&&i.push(t[c].onModified(e.modified))}e.delete=function(){for(;i.length;)i.pop().unsubscribe();n()}},proxyPropertyState:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};function i(e){for(var r=Object.keys(e),n=r.length;n--;){var i=r[n];t[i].set(e[i])}}t.this=e;for(var a=Object.keys(n),o=a.length,s=function(){var s=a[o];t[s]=n[s];var u=r[s];e["set".concat(A(s))]=function(r){r!==t[s]&&(t[s]=r,i(u[r]),e.modified())}};o--;)s();a.length&&N(e,t,a)},safeArrays:v,set:b,setArray:E,setGet:C,setGetArray:L,setImmediate:T,setLoggerFunction:function(e,t){d[e]&&(d[e]=t||f)},throttle:function(e,t){var r=!1,n=null;function i(){r=!1,null!==n&&(a.apply(void 0,s(n)),n=null)}function a(){for(var a=arguments.length,o=new Array(a),s=0;s<a;s++)o[s]=arguments[s];r?n=o:(r=!0,e.apply(void 0,o),setTimeout(i,t))}return a},traverseInstanceTree:function e(t,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[];if(j(t)){if(i.indexOf(t)>=0)return n;i.push(t);var a=r(t);void 0!==a&&n.push(a);var o=t.get();Object.keys(o).forEach((function(t){var a=o[t];Array.isArray(a)?a.forEach((function(t){e(t,r,n,i)})):e(a,r,n,i)}))}return n},TYPED_ARRAYS:M,uncapitalize:function(e){return e.charAt(0).toLowerCase()+e.slice(1)},VOID:c,vtkDebugMacro:g,vtkErrorMacro:p,vtkInfoMacro:function(){d.info.apply(d,arguments)},vtkLogMacro:function(){d.log.apply(d,arguments)},vtkOnceErrorMacro:function(e){m[e]||(d.error(e),m[e]=!0)},vtkWarningMacro:h}}).call(this,r(11))},function(e,t){e.exports=require("react")},function(e,t){e.exports=require("react-bootstrap")},function(e,t,r){(function(e,r){var n;!function(){var i="object"==typeof self&&self.self===self&&self||"object"==typeof e&&e.global===e&&e||this||{},a=i._,o=Array.prototype,s=Object.prototype,u="undefined"!=typeof Symbol?Symbol.prototype:null,c=o.push,l=o.slice,f=s.toString,d=s.hasOwnProperty,g=Array.isArray,p=Object.keys,h=Object.create,m=function(){},M=function(e){return e instanceof M?e:this instanceof M?void(this._wrapped=e):new M(e)};t.nodeType?i._=M:(!r.nodeType&&r.exports&&(t=r.exports=M),t._=M),M.VERSION="1.9.2";var A,v=function(e,t,r){if(void 0===t)return e;switch(null==r?3:r){case 1:return function(r){return e.call(t,r)};case 3:return function(r,n,i){return e.call(t,r,n,i)};case 4:return function(r,n,i,a){return e.call(t,r,n,i,a)}}return function(){return e.apply(t,arguments)}},y=function(e,t,r){return M.iteratee!==A?M.iteratee(e,t):null==e?M.identity:M.isFunction(e)?v(e,t,r):M.isObject(e)&&!M.isArray(e)?M.matcher(e):M.property(e)};M.iteratee=A=function(e,t){return y(e,t,1/0)};var T=function(e,t){return t=null==t?e.length-1:+t,function(){for(var r=Math.max(arguments.length-t,0),n=Array(r),i=0;i<r;i++)n[i]=arguments[i+t];switch(t){case 0:return e.call(this,n);case 1:return e.call(this,arguments[0],n);case 2:return e.call(this,arguments[0],arguments[1],n)}var a=Array(t+1);for(i=0;i<t;i++)a[i]=arguments[i];return a[t]=n,e.apply(this,a)}},w=function(e){if(!M.isObject(e))return{};if(h)return h(e);m.prototype=e;var t=new m;return m.prototype=null,t},N=function(e){return function(t){return null==t?void 0:t[e]}},D=function(e,t){return null!=e&&d.call(e,t)},I=function(e,t){for(var r=t.length,n=0;n<r;n++){if(null==e)return;e=e[t[n]]}return r?e:void 0},b=Math.pow(2,53)-1,C=N("length"),x=function(e){var t=C(e);return"number"==typeof t&&t>=0&&t<=b};M.each=M.forEach=function(e,t,r){var n,i;if(t=v(t,r),x(e))for(n=0,i=e.length;n<i;n++)t(e[n],n,e);else{var a=M.keys(e);for(n=0,i=a.length;n<i;n++)t(e[a[n]],a[n],e)}return e},M.map=M.collect=function(e,t,r){t=y(t,r);for(var n=!x(e)&&M.keys(e),i=(n||e).length,a=Array(i),o=0;o<i;o++){var s=n?n[o]:o;a[o]=t(e[s],s,e)}return a};var E=function(e){var t=function(t,r,n,i){var a=!x(t)&&M.keys(t),o=(a||t).length,s=e>0?0:o-1;for(i||(n=t[a?a[s]:s],s+=e);s>=0&&s<o;s+=e){var u=a?a[s]:s;n=r(n,t[u],u,t)}return n};return function(e,r,n,i){var a=arguments.length>=3;return t(e,v(r,i,4),n,a)}};M.reduce=M.foldl=M.inject=E(1),M.reduceRight=M.foldr=E(-1),M.find=M.detect=function(e,t,r){var n=(x(e)?M.findIndex:M.findKey)(e,t,r);if(void 0!==n&&-1!==n)return e[n]},M.filter=M.select=function(e,t,r){var n=[];return t=y(t,r),M.each(e,(function(e,r,i){t(e,r,i)&&n.push(e)})),n},M.reject=function(e,t,r){return M.filter(e,M.negate(y(t)),r)},M.every=M.all=function(e,t,r){t=y(t,r);for(var n=!x(e)&&M.keys(e),i=(n||e).length,a=0;a<i;a++){var o=n?n[a]:a;if(!t(e[o],o,e))return!1}return!0},M.some=M.any=function(e,t,r){t=y(t,r);for(var n=!x(e)&&M.keys(e),i=(n||e).length,a=0;a<i;a++){var o=n?n[a]:a;if(t(e[o],o,e))return!0}return!1},M.contains=M.includes=M.include=function(e,t,r,n){return x(e)||(e=M.values(e)),("number"!=typeof r||n)&&(r=0),M.indexOf(e,t,r)>=0},M.invoke=T((function(e,t,r){var n,i;return M.isFunction(t)?i=t:M.isArray(t)&&(n=t.slice(0,-1),t=t[t.length-1]),M.map(e,(function(e){var a=i;if(!a){if(n&&n.length&&(e=I(e,n)),null==e)return;a=e[t]}return null==a?a:a.apply(e,r)}))})),M.pluck=function(e,t){return M.map(e,M.property(t))},M.where=function(e,t){return M.filter(e,M.matcher(t))},M.findWhere=function(e,t){return M.find(e,M.matcher(t))},M.max=function(e,t,r){var n,i,a=-1/0,o=-1/0;if(null==t||"number"==typeof t&&"object"!=typeof e[0]&&null!=e)for(var s=0,u=(e=x(e)?e:M.values(e)).length;s<u;s++)null!=(n=e[s])&&n>a&&(a=n);else t=y(t,r),M.each(e,(function(e,r,n){((i=t(e,r,n))>o||i===-1/0&&a===-1/0)&&(a=e,o=i)}));return a},M.min=function(e,t,r){var n,i,a=1/0,o=1/0;if(null==t||"number"==typeof t&&"object"!=typeof e[0]&&null!=e)for(var s=0,u=(e=x(e)?e:M.values(e)).length;s<u;s++)null!=(n=e[s])&&n<a&&(a=n);else t=y(t,r),M.each(e,(function(e,r,n){((i=t(e,r,n))<o||i===1/0&&a===1/0)&&(a=e,o=i)}));return a},M.shuffle=function(e){return M.sample(e,1/0)},M.sample=function(e,t,r){if(null==t||r)return x(e)||(e=M.values(e)),e[M.random(e.length-1)];var n=x(e)?M.clone(e):M.values(e),i=C(n);t=Math.max(Math.min(t,i),0);for(var a=i-1,o=0;o<t;o++){var s=M.random(o,a),u=n[o];n[o]=n[s],n[s]=u}return n.slice(0,t)},M.sortBy=function(e,t,r){var n=0;return t=y(t,r),M.pluck(M.map(e,(function(e,r,i){return{value:e,index:n++,criteria:t(e,r,i)}})).sort((function(e,t){var r=e.criteria,n=t.criteria;if(r!==n){if(r>n||void 0===r)return 1;if(r<n||void 0===n)return-1}return e.index-t.index})),"value")};var L=function(e,t){return function(r,n,i){var a=t?[[],[]]:{};return n=y(n,i),M.each(r,(function(t,i){var o=n(t,i,r);e(a,t,o)})),a}};M.groupBy=L((function(e,t,r){D(e,r)?e[r].push(t):e[r]=[t]})),M.indexBy=L((function(e,t,r){e[r]=t})),M.countBy=L((function(e,t,r){D(e,r)?e[r]++:e[r]=1}));var S=/[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g;M.toArray=function(e){return e?M.isArray(e)?l.call(e):M.isString(e)?e.match(S):x(e)?M.map(e,M.identity):M.values(e):[]},M.size=function(e){return null==e?0:x(e)?e.length:M.keys(e).length},M.partition=L((function(e,t,r){e[r?0:1].push(t)}),!0),M.first=M.head=M.take=function(e,t,r){return null==e||e.length<1?null==t?void 0:[]:null==t||r?e[0]:M.initial(e,e.length-t)},M.initial=function(e,t,r){return l.call(e,0,Math.max(0,e.length-(null==t||r?1:t)))},M.last=function(e,t,r){return null==e||e.length<1?null==t?void 0:[]:null==t||r?e[e.length-1]:M.rest(e,Math.max(0,e.length-t))},M.rest=M.tail=M.drop=function(e,t,r){return l.call(e,null==t||r?1:t)},M.compact=function(e){return M.filter(e,Boolean)};var O=function(e,t,r,n){for(var i=(n=n||[]).length,a=0,o=C(e);a<o;a++){var s=e[a];if(x(s)&&(M.isArray(s)||M.isArguments(s)))if(t)for(var u=0,c=s.length;u<c;)n[i++]=s[u++];else O(s,t,r,n),i=n.length;else r||(n[i++]=s)}return n};M.flatten=function(e,t){return O(e,t,!1)},M.without=T((function(e,t){return M.difference(e,t)})),M.uniq=M.unique=function(e,t,r,n){M.isBoolean(t)||(n=r,r=t,t=!1),null!=r&&(r=y(r,n));for(var i=[],a=[],o=0,s=C(e);o<s;o++){var u=e[o],c=r?r(u,o,e):u;t&&!r?(o&&a===c||i.push(u),a=c):r?M.contains(a,c)||(a.push(c),i.push(u)):M.contains(i,u)||i.push(u)}return i},M.union=T((function(e){return M.uniq(O(e,!0,!0))})),M.intersection=function(e){for(var t=[],r=arguments.length,n=0,i=C(e);n<i;n++){var a=e[n];if(!M.contains(t,a)){var o;for(o=1;o<r&&M.contains(arguments[o],a);o++);o===r&&t.push(a)}}return t},M.difference=T((function(e,t){return t=O(t,!0,!0),M.filter(e,(function(e){return!M.contains(t,e)}))})),M.unzip=function(e){for(var t=e&&M.max(e,C).length||0,r=Array(t),n=0;n<t;n++)r[n]=M.pluck(e,n);return r},M.zip=T(M.unzip),M.object=function(e,t){for(var r={},n=0,i=C(e);n<i;n++)t?r[e[n]]=t[n]:r[e[n][0]]=e[n][1];return r};var j=function(e){return function(t,r,n){r=y(r,n);for(var i=C(t),a=e>0?0:i-1;a>=0&&a<i;a+=e)if(r(t[a],a,t))return a;return-1}};M.findIndex=j(1),M.findLastIndex=j(-1),M.sortedIndex=function(e,t,r,n){for(var i=(r=y(r,n,1))(t),a=0,o=C(e);a<o;){var s=Math.floor((a+o)/2);r(e[s])<i?a=s+1:o=s}return a};var R=function(e,t,r){return function(n,i,a){var o=0,s=C(n);if("number"==typeof a)e>0?o=a>=0?a:Math.max(a+s,o):s=a>=0?Math.min(a+1,s):a+s+1;else if(r&&a&&s)return n[a=r(n,i)]===i?a:-1;if(i!=i)return(a=t(l.call(n,o,s),M.isNaN))>=0?a+o:-1;for(a=e>0?o:s-1;a>=0&&a<s;a+=e)if(n[a]===i)return a;return-1}};M.indexOf=R(1,M.findIndex,M.sortedIndex),M.lastIndexOf=R(-1,M.findLastIndex),M.range=function(e,t,r){null==t&&(t=e||0,e=0),r||(r=t<e?-1:1);for(var n=Math.max(Math.ceil((t-e)/r),0),i=Array(n),a=0;a<n;a++,e+=r)i[a]=e;return i},M.chunk=function(e,t){if(null==t||t<1)return[];for(var r=[],n=0,i=e.length;n<i;)r.push(l.call(e,n,n+=t));return r};var k=function(e,t,r,n,i){if(!(n instanceof t))return e.apply(r,i);var a=w(e.prototype),o=e.apply(a,i);return M.isObject(o)?o:a};M.bind=T((function(e,t,r){if(!M.isFunction(e))throw new TypeError("Bind must be called on a function");var n=T((function(i){return k(e,n,t,this,r.concat(i))}));return n})),M.partial=T((function(e,t){var r=M.partial.placeholder,n=function(){for(var i=0,a=t.length,o=Array(a),s=0;s<a;s++)o[s]=t[s]===r?arguments[i++]:t[s];for(;i<arguments.length;)o.push(arguments[i++]);return k(e,n,this,this,o)};return n})),M.partial.placeholder=M,M.bindAll=T((function(e,t){var r=(t=O(t,!1,!1)).length;if(r<1)throw new Error("bindAll must be passed function names");for(;r--;){var n=t[r];e[n]=M.bind(e[n],e)}})),M.memoize=function(e,t){var r=function(n){var i=r.cache,a=""+(t?t.apply(this,arguments):n);return D(i,a)||(i[a]=e.apply(this,arguments)),i[a]};return r.cache={},r},M.delay=T((function(e,t,r){return setTimeout((function(){return e.apply(null,r)}),t)})),M.defer=M.partial(M.delay,M,1),M.throttle=function(e,t,r){var n,i,a,o,s=0;r||(r={});var u=function(){s=!1===r.leading?0:M.now(),n=null,o=e.apply(i,a),n||(i=a=null)},c=function(){var c=M.now();s||!1!==r.leading||(s=c);var l=t-(c-s);return i=this,a=arguments,l<=0||l>t?(n&&(clearTimeout(n),n=null),s=c,o=e.apply(i,a),n||(i=a=null)):n||!1===r.trailing||(n=setTimeout(u,l)),o};return c.cancel=function(){clearTimeout(n),s=0,n=i=a=null},c},M.debounce=function(e,t,r){var n,i,a=function(t,r){n=null,r&&(i=e.apply(t,r))},o=T((function(o){if(n&&clearTimeout(n),r){var s=!n;n=setTimeout(a,t),s&&(i=e.apply(this,o))}else n=M.delay(a,t,this,o);return i}));return o.cancel=function(){clearTimeout(n),n=null},o},M.wrap=function(e,t){return M.partial(t,e)},M.negate=function(e){return function(){return!e.apply(this,arguments)}},M.compose=function(){var e=arguments,t=e.length-1;return function(){for(var r=t,n=e[t].apply(this,arguments);r--;)n=e[r].call(this,n);return n}},M.after=function(e,t){return function(){if(--e<1)return t.apply(this,arguments)}},M.before=function(e,t){var r;return function(){return--e>0&&(r=t.apply(this,arguments)),e<=1&&(t=null),r}},M.once=M.partial(M.before,2),M.restArguments=T;var _=!{toString:null}.propertyIsEnumerable("toString"),P=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],z=function(e,t){var r=P.length,n=e.constructor,i=M.isFunction(n)&&n.prototype||s,a="constructor";for(D(e,a)&&!M.contains(t,a)&&t.push(a);r--;)(a=P[r])in e&&e[a]!==i[a]&&!M.contains(t,a)&&t.push(a)};M.keys=function(e){if(!M.isObject(e))return[];if(p)return p(e);var t=[];for(var r in e)D(e,r)&&t.push(r);return _&&z(e,t),t},M.allKeys=function(e){if(!M.isObject(e))return[];var t=[];for(var r in e)t.push(r);return _&&z(e,t),t},M.values=function(e){for(var t=M.keys(e),r=t.length,n=Array(r),i=0;i<r;i++)n[i]=e[t[i]];return n},M.mapObject=function(e,t,r){t=y(t,r);for(var n=M.keys(e),i=n.length,a={},o=0;o<i;o++){var s=n[o];a[s]=t(e[s],s,e)}return a},M.pairs=function(e){for(var t=M.keys(e),r=t.length,n=Array(r),i=0;i<r;i++)n[i]=[t[i],e[t[i]]];return n},M.invert=function(e){for(var t={},r=M.keys(e),n=0,i=r.length;n<i;n++)t[e[r[n]]]=r[n];return t},M.functions=M.methods=function(e){var t=[];for(var r in e)M.isFunction(e[r])&&t.push(r);return t.sort()};var B=function(e,t){return function(r){var n=arguments.length;if(t&&(r=Object(r)),n<2||null==r)return r;for(var i=1;i<n;i++)for(var a=arguments[i],o=e(a),s=o.length,u=0;u<s;u++){var c=o[u];t&&void 0!==r[c]||(r[c]=a[c])}return r}};M.extend=B(M.allKeys),M.extendOwn=M.assign=B(M.keys),M.findKey=function(e,t,r){t=y(t,r);for(var n,i=M.keys(e),a=0,o=i.length;a<o;a++)if(t(e[n=i[a]],n,e))return n};var U,V,F=function(e,t,r){return t in r};M.pick=T((function(e,t){var r={},n=t[0];if(null==e)return r;M.isFunction(n)?(t.length>1&&(n=v(n,t[1])),t=M.allKeys(e)):(n=F,t=O(t,!1,!1),e=Object(e));for(var i=0,a=t.length;i<a;i++){var o=t[i],s=e[o];n(s,o,e)&&(r[o]=s)}return r})),M.omit=T((function(e,t){var r,n=t[0];return M.isFunction(n)?(n=M.negate(n),t.length>1&&(r=t[1])):(t=M.map(O(t,!1,!1),String),n=function(e,r){return!M.contains(t,r)}),M.pick(e,n,r)})),M.defaults=B(M.allKeys,!0),M.create=function(e,t){var r=w(e);return t&&M.extendOwn(r,t),r},M.clone=function(e){return M.isObject(e)?M.isArray(e)?e.slice():M.extend({},e):e},M.tap=function(e,t){return t(e),e},M.isMatch=function(e,t){var r=M.keys(t),n=r.length;if(null==e)return!n;for(var i=Object(e),a=0;a<n;a++){var o=r[a];if(t[o]!==i[o]||!(o in i))return!1}return!0},U=function(e,t,r,n){if(e===t)return 0!==e||1/e==1/t;if(null==e||null==t)return!1;if(e!=e)return t!=t;var i=typeof e;return("function"===i||"object"===i||"object"==typeof t)&&V(e,t,r,n)},V=function(e,t,r,n){e instanceof M&&(e=e._wrapped),t instanceof M&&(t=t._wrapped);var i=f.call(e);if(i!==f.call(t))return!1;switch(i){case"[object RegExp]":case"[object String]":return""+e==""+t;case"[object Number]":return+e!=+e?+t!=+t:0==+e?1/+e==1/t:+e==+t;case"[object Date]":case"[object Boolean]":return+e==+t;case"[object Symbol]":return u.valueOf.call(e)===u.valueOf.call(t)}var a="[object Array]"===i;if(!a){if("object"!=typeof e||"object"!=typeof t)return!1;var o=e.constructor,s=t.constructor;if(o!==s&&!(M.isFunction(o)&&o instanceof o&&M.isFunction(s)&&s instanceof s)&&"constructor"in e&&"constructor"in t)return!1}n=n||[];for(var c=(r=r||[]).length;c--;)if(r[c]===e)return n[c]===t;if(r.push(e),n.push(t),a){if((c=e.length)!==t.length)return!1;for(;c--;)if(!U(e[c],t[c],r,n))return!1}else{var l,d=M.keys(e);if(c=d.length,M.keys(t).length!==c)return!1;for(;c--;)if(l=d[c],!D(t,l)||!U(e[l],t[l],r,n))return!1}return r.pop(),n.pop(),!0},M.isEqual=function(e,t){return U(e,t)},M.isEmpty=function(e){return null==e||(x(e)&&(M.isArray(e)||M.isString(e)||M.isArguments(e))?0===e.length:0===M.keys(e).length)},M.isElement=function(e){return!(!e||1!==e.nodeType)},M.isArray=g||function(e){return"[object Array]"===f.call(e)},M.isObject=function(e){var t=typeof e;return"function"===t||"object"===t&&!!e},M.each(["Arguments","Function","String","Number","Date","RegExp","Error","Symbol","Map","WeakMap","Set","WeakSet"],(function(e){M["is"+e]=function(t){return f.call(t)==="[object "+e+"]"}})),M.isArguments(arguments)||(M.isArguments=function(e){return D(e,"callee")});var G=i.document&&i.document.childNodes;"object"!=typeof Int8Array&&"function"!=typeof G&&(M.isFunction=function(e){return"function"==typeof e||!1}),M.isFinite=function(e){return!M.isSymbol(e)&&isFinite(e)&&!isNaN(parseFloat(e))},M.isNaN=function(e){return M.isNumber(e)&&isNaN(e)},M.isBoolean=function(e){return!0===e||!1===e||"[object Boolean]"===f.call(e)},M.isNull=function(e){return null===e},M.isUndefined=function(e){return void 0===e},M.has=function(e,t){if(!M.isArray(t))return D(e,t);for(var r=t.length,n=0;n<r;n++){var i=t[n];if(null==e||!d.call(e,i))return!1;e=e[i]}return!!r},M.noConflict=function(){return i._=a,this},M.identity=function(e){return e},M.constant=function(e){return function(){return e}},M.noop=function(){},M.property=function(e){return M.isArray(e)?function(t){return I(t,e)}:N(e)},M.propertyOf=function(e){return null==e?function(){}:function(t){return M.isArray(t)?I(e,t):e[t]}},M.matcher=M.matches=function(e){return e=M.extendOwn({},e),function(t){return M.isMatch(t,e)}},M.times=function(e,t,r){var n=Array(Math.max(0,e));t=v(t,r,1);for(var i=0;i<e;i++)n[i]=t(i);return n},M.random=function(e,t){return null==t&&(t=e,e=0),e+Math.floor(Math.random()*(t-e+1))},M.now=Date.now||function(){return(new Date).getTime()};var Q={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","`":"&#x60;"},Y=M.invert(Q),W=function(e){var t=function(t){return e[t]},r="(?:"+M.keys(e).join("|")+")",n=RegExp(r),i=RegExp(r,"g");return function(e){return e=null==e?"":""+e,n.test(e)?e.replace(i,t):e}};M.escape=W(Q),M.unescape=W(Y),M.result=function(e,t,r){M.isArray(t)||(t=[t]);var n=t.length;if(!n)return M.isFunction(r)?r.call(e):r;for(var i=0;i<n;i++){var a=null==e?void 0:e[t[i]];void 0===a&&(a=r,i=n),e=M.isFunction(a)?a.call(e):a}return e};var H=0;M.uniqueId=function(e){var t=++H+"";return e?e+t:t},M.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var K=/(.)^/,X={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},Z=/\\|'|\r|\n|\u2028|\u2029/g,q=function(e){return"\\"+X[e]};M.template=function(e,t,r){!t&&r&&(t=r),t=M.defaults({},t,M.templateSettings);var n,i=RegExp([(t.escape||K).source,(t.interpolate||K).source,(t.evaluate||K).source].join("|")+"|$","g"),a=0,o="__p+='";e.replace(i,(function(t,r,n,i,s){return o+=e.slice(a,s).replace(Z,q),a=s+t.length,r?o+="'+\n((__t=("+r+"))==null?'':_.escape(__t))+\n'":n?o+="'+\n((__t=("+n+"))==null?'':__t)+\n'":i&&(o+="';\n"+i+"\n__p+='"),t})),o+="';\n",t.variable||(o="with(obj||{}){\n"+o+"}\n"),o="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+o+"return __p;\n";try{n=new Function(t.variable||"obj","_",o)}catch(e){throw e.source=o,e}var s=function(e){return n.call(this,e,M)},u=t.variable||"obj";return s.source="function("+u+"){\n"+o+"}",s},M.chain=function(e){var t=M(e);return t._chain=!0,t};var J=function(e,t){return e._chain?M(t).chain():t};M.mixin=function(e){return M.each(M.functions(e),(function(t){var r=M[t]=e[t];M.prototype[t]=function(){var e=[this._wrapped];return c.apply(e,arguments),J(this,r.apply(M,e))}})),M},M.mixin(M),M.each(["pop","push","reverse","shift","sort","splice","unshift"],(function(e){var t=o[e];M.prototype[e]=function(){var r=this._wrapped;return t.apply(r,arguments),"shift"!==e&&"splice"!==e||0!==r.length||delete r[0],J(this,r)}})),M.each(["concat","join","slice"],(function(e){var t=o[e];M.prototype[e]=function(){return J(this,t.apply(this._wrapped,arguments))}})),M.prototype.value=function(){return this._wrapped},M.prototype.valueOf=M.prototype.toJSON=M.prototype.value,M.prototype.toString=function(){return String(this._wrapped)},void 0===(n=function(){return M}.apply(t,[]))||(r.exports=n)}()}).call(this,r(11),r(16)(e))},function(e,t,r){"use strict";var n=r(14),i=r(51),a=r(29),o=r(107),s=r(26);function u(e){return e}function c(e,t){for(var r=0;r<e.length;++r)t[r]=255&e.charCodeAt(r);return t}t.newBlob=function(e,r){t.checkSupport("blob");try{return new Blob([e],{type:r})}catch(t){try{var n=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return n.append(e),n.getBlob(r)}catch(e){throw new Error("Bug : can't construct the Blob.")}}};var l={stringifyByChunk:function(e,t,r){var n=[],i=0,a=e.length;if(a<=r)return String.fromCharCode.apply(null,e);for(;i<a;)"array"===t||"nodebuffer"===t?n.push(String.fromCharCode.apply(null,e.slice(i,Math.min(i+r,a)))):n.push(String.fromCharCode.apply(null,e.subarray(i,Math.min(i+r,a)))),i+=r;return n.join("")},stringifyByChar:function(e){for(var t="",r=0;r<e.length;r++)t+=String.fromCharCode(e[r]);return t},applyCanBeUsed:{uint8array:function(){try{return n.uint8array&&1===String.fromCharCode.apply(null,new Uint8Array(1)).length}catch(e){return!1}}(),nodebuffer:function(){try{return n.nodebuffer&&1===String.fromCharCode.apply(null,a.allocBuffer(1)).length}catch(e){return!1}}()}};function f(e){var r=65536,n=t.getTypeOf(e),i=!0;if("uint8array"===n?i=l.applyCanBeUsed.uint8array:"nodebuffer"===n&&(i=l.applyCanBeUsed.nodebuffer),i)for(;r>1;)try{return l.stringifyByChunk(e,n,r)}catch(e){r=Math.floor(r/2)}return l.stringifyByChar(e)}function d(e,t){for(var r=0;r<e.length;r++)t[r]=e[r];return t}t.applyFromCharCode=f;var g={};g.string={string:u,array:function(e){return c(e,new Array(e.length))},arraybuffer:function(e){return g.string.uint8array(e).buffer},uint8array:function(e){return c(e,new Uint8Array(e.length))},nodebuffer:function(e){return c(e,a.allocBuffer(e.length))}},g.array={string:f,array:u,arraybuffer:function(e){return new Uint8Array(e).buffer},uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return a.newBufferFrom(e)}},g.arraybuffer={string:function(e){return f(new Uint8Array(e))},array:function(e){return d(new Uint8Array(e),new Array(e.byteLength))},arraybuffer:u,uint8array:function(e){return new Uint8Array(e)},nodebuffer:function(e){return a.newBufferFrom(new Uint8Array(e))}},g.uint8array={string:f,array:function(e){return d(e,new Array(e.length))},arraybuffer:function(e){return e.buffer},uint8array:u,nodebuffer:function(e){return a.newBufferFrom(e)}},g.nodebuffer={string:f,array:function(e){return d(e,new Array(e.length))},arraybuffer:function(e){return g.nodebuffer.uint8array(e).buffer},uint8array:function(e){return d(e,new Uint8Array(e.length))},nodebuffer:u},t.transformTo=function(e,r){if(r||(r=""),!e)return r;t.checkSupport(e);var n=t.getTypeOf(r);return g[n][e](r)},t.getTypeOf=function(e){return"string"==typeof e?"string":"[object Array]"===Object.prototype.toString.call(e)?"array":n.nodebuffer&&a.isBuffer(e)?"nodebuffer":n.uint8array&&e instanceof Uint8Array?"uint8array":n.arraybuffer&&e instanceof ArrayBuffer?"arraybuffer":void 0},t.checkSupport=function(e){if(!n[e.toLowerCase()])throw new Error(e+" is not supported by this platform")},t.MAX_VALUE_16BITS=65535,t.MAX_VALUE_32BITS=-1,t.pretty=function(e){var t,r,n="";for(r=0;r<(e||"").length;r++)n+="\\x"+((t=e.charCodeAt(r))<16?"0":"")+t.toString(16).toUpperCase();return n},t.delay=function(e,t,r){o((function(){e.apply(r||null,t||[])}))},t.inherits=function(e,t){var r=function(){};r.prototype=t.prototype,e.prototype=new r},t.extend=function(){var e,t,r={};for(e=0;e<arguments.length;e++)for(t in arguments[e])arguments[e].hasOwnProperty(t)&&void 0===r[t]&&(r[t]=arguments[e][t]);return r},t.prepareContent=function(e,r,a,o,u){return s.Promise.resolve(r).then((function(e){return n.blob&&(e instanceof Blob||-1!==["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(e)))&&"undefined"!=typeof FileReader?new s.Promise((function(t,r){var n=new FileReader;n.onload=function(e){t(e.target.result)},n.onerror=function(e){r(e.target.error)},n.readAsArrayBuffer(e)})):e})).then((function(r){var l,f=t.getTypeOf(r);return f?("arraybuffer"===f?r=t.transformTo("uint8array",r):"string"===f&&(u?r=i.decode(r):a&&!0!==o&&(r=c(l=r,n.uint8array?new Uint8Array(l.length):new Array(l.length)))),r):s.Promise.reject(new Error("Can't read the data of '"+e+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))}))}},function(e,t,r){"use strict";var n={};(0,r(13).assign)(n,r(85),r(88),r(42)),e.exports=n},function(e,t,r){"use strict";(function(e){function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}r.d(t,"a",(function(){return a}));var i={vtkObject:function(){return null}};function a(t){if(null==t)return t;if(t.isA)return t;if(!t.vtkClass)return e.console&&e.console.error&&e.console.error("Invalid VTK object"),null;var r=i[t.vtkClass];if(!r)return e.console&&e.console.error&&e.console.error("No vtk class found for Object of type ".concat(t.vtkClass)),null;var o=Object.assign({},t);Object.keys(o).forEach((function(e){o[e]&&"object"===n(o[e])&&o[e].vtkClass&&(o[e]=a(o[e]))}));var s=r(o);return s&&s.modified&&s.modified(),s}a.register=function(e,t){i[e]=t}}).call(this,r(11))},function(e,t,r){"use strict";var n=r(122),i=r(123),a=r(124);function o(e,t){return t.encode?t.strict?n(e):encodeURIComponent(e):e}function s(e){var t=e.indexOf("?");return-1===t?"":e.slice(t+1)}function u(e,t){var r=function(e){var t;switch(e.arrayFormat){case"index":return function(e,r,n){t=/\[(\d*)\]$/.exec(e),e=e.replace(/\[\d*\]$/,""),t?(void 0===n[e]&&(n[e]={}),n[e][t[1]]=r):n[e]=r};case"bracket":return function(e,r,n){t=/(\[\])$/.exec(e),e=e.replace(/\[\]$/,""),t?void 0!==n[e]?n[e]=[].concat(n[e],r):n[e]=[r]:n[e]=r};default:return function(e,t,r){void 0!==r[e]?r[e]=[].concat(r[e],t):r[e]=t}}}(t=i({arrayFormat:"none"},t)),n=Object.create(null);return"string"!=typeof e?n:(e=e.trim().replace(/^[?#&]/,""))?(e.split("&").forEach((function(e){var t=e.replace(/\+/g," ").split("="),i=t.shift(),o=t.length>0?t.join("="):void 0;o=void 0===o?null:a(o),r(a(i),o,n)})),Object.keys(n).sort().reduce((function(e,t){var r=n[t];return Boolean(r)&&"object"==typeof r&&!Array.isArray(r)?e[t]=function e(t){return Array.isArray(t)?t.sort():"object"==typeof t?e(Object.keys(t)).sort((function(e,t){return Number(e)-Number(t)})).map((function(e){return t[e]})):t}(r):e[t]=r,e}),Object.create(null))):n}t.extract=s,t.parse=u,t.stringify=function(e,t){!1===(t=i({encode:!0,strict:!0,arrayFormat:"none"},t)).sort&&(t.sort=function(){});var r=function(e){switch(e.arrayFormat){case"index":return function(t,r,n){return null===r?[o(t,e),"[",n,"]"].join(""):[o(t,e),"[",o(n,e),"]=",o(r,e)].join("")};case"bracket":return function(t,r){return null===r?o(t,e):[o(t,e),"[]=",o(r,e)].join("")};default:return function(t,r){return null===r?o(t,e):[o(t,e),"=",o(r,e)].join("")}}}(t);return e?Object.keys(e).sort(t.sort).map((function(n){var i=e[n];if(void 0===i)return"";if(null===i)return o(n,t);if(Array.isArray(i)){var a=[];return i.slice().forEach((function(e){void 0!==e&&a.push(r(n,e,a.length))})),a.join("&")}return o(n,t)+"="+o(i,t)})).filter((function(e){return e.length>0})).join("&"):""},t.parseUrl=function(e,t){return{url:e.split("?")[0]||"",query:u(s(e),t)}}},function(e,t){e.exports=function(){throw new Error("define cannot be used indirect")}},function(e,t,r){"use strict";function n(e){this.name=e||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}n.prototype={push:function(e){this.emit("data",e)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(e){this.emit("error",e)}return!0},error:function(e){return!this.isFinished&&(this.isPaused?this.generatedError=e:(this.isFinished=!0,this.emit("error",e),this.previous&&this.previous.error(e),this.cleanUp()),!0)},on:function(e,t){return this._listeners[e].push(t),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(e,t){if(this._listeners[e])for(var r=0;r<this._listeners[e].length;r++)this._listeners[e][r].call(this,t)},pipe:function(e){return e.registerPrevious(this)},registerPrevious:function(e){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=e.streamInfo,this.mergeStreamInfo(),this.previous=e;var t=this;return e.on("data",(function(e){t.processChunk(e)})),e.on("end",(function(){t.end()})),e.on("error",(function(e){t.error(e)})),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){if(!this.isPaused||this.isFinished)return!1;this.isPaused=!1;var e=!1;return this.generatedError&&(this.error(this.generatedError),e=!0),this.previous&&this.previous.resume(),!e},flush:function(){},processChunk:function(e){this.push(e)},withStreamInfo:function(e,t){return this.extraStreamInfo[e]=t,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var e in this.extraStreamInfo)this.extraStreamInfo.hasOwnProperty(e)&&(this.streamInfo[e]=this.extraStreamInfo[e])},lock:function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},toString:function(){var e="Worker "+this.name;return this.previous?this.previous+" -> "+e:e}},e.exports=n},function(e,t){e.exports=require("react-feather")},function(e,t){var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(e){"object"==typeof window&&(r=window)}e.exports=r},function(e,t){e.exports=require("react-router-dom")},function(e,t,r){"use strict";var n="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;function i(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.assign=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var r=t.shift();if(r){if("object"!=typeof r)throw new TypeError(r+"must be non-object");for(var n in r)i(r,n)&&(e[n]=r[n])}}return e},t.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)};var a={arraySet:function(e,t,r,n,i){if(t.subarray&&e.subarray)e.set(t.subarray(r,r+n),i);else for(var a=0;a<n;a++)e[i+a]=t[r+a]},flattenChunks:function(e){var t,r,n,i,a,o;for(n=0,t=0,r=e.length;t<r;t++)n+=e[t].length;for(o=new Uint8Array(n),i=0,t=0,r=e.length;t<r;t++)a=e[t],o.set(a,i),i+=a.length;return o}},o={arraySet:function(e,t,r,n,i){for(var a=0;a<n;a++)e[i+a]=t[r+a]},flattenChunks:function(e){return[].concat.apply([],e)}};t.setTyped=function(e){e?(t.Buf8=Uint8Array,t.Buf16=Uint16Array,t.Buf32=Int32Array,t.assign(t,a)):(t.Buf8=Array,t.Buf16=Array,t.Buf32=Array,t.assign(t,o))},t.setTyped(n)},function(e,t,r){"use strict";(function(e){if(t.base64=!0,t.array=!0,t.string=!0,t.arraybuffer="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array,t.nodebuffer=void 0!==e,t.uint8array="undefined"!=typeof Uint8Array,"undefined"==typeof ArrayBuffer)t.blob=!1;else{var n=new ArrayBuffer(0);try{t.blob=0===new Blob([n],{type:"application/zip"}).size}catch(e){try{var i=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);i.append(n),t.blob=0===i.getBlob("application/zip").size}catch(e){t.blob=!1}}}try{t.nodestream=!!r(44).Readable}catch(e){t.nodestream=!1}}).call(this,r(23).Buffer)},function(e,t){e.exports="//VTK::System::Dec\n\n/*=========================================================================\n\n Program: Visualization Toolkit\n Module: vtkPolyDataFS.glsl\n\n Copyright (c) Ken Marti