@deephaven/embed-chart 0.68.1-beta.0 → 0.68.1-beta.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (20) hide show
  1. package/build/assets/{App-7213d07f.js → App-3ddf79a4.js} +2 -2
  2. package/build/assets/{App-7213d07f.js.map → App-3ddf79a4.js.map} +1 -1
  3. package/build/assets/{Chart-e62f6b61.js → Chart-1b4a62ea.js} +2 -2
  4. package/build/assets/{Chart-e62f6b61.js.map → Chart-1b4a62ea.js.map} +1 -1
  5. package/build/assets/{IrisGrid-bad6e1f6.js → IrisGrid-bb108771.js} +3 -3
  6. package/build/assets/{IrisGrid-bad6e1f6.js.map → IrisGrid-bb108771.js.map} +1 -1
  7. package/build/assets/{MarkdownEditor-36ed3bec.js → MarkdownEditor-5ab006cc.js} +2 -2
  8. package/build/assets/{MarkdownEditor-36ed3bec.js.map → MarkdownEditor-5ab006cc.js.map} +1 -1
  9. package/build/assets/{MarkdownNotebook-78a8c01f.js → MarkdownNotebook-9e909c63.js} +2 -2
  10. package/build/assets/{MarkdownNotebook-78a8c01f.js.map → MarkdownNotebook-9e909c63.js.map} +1 -1
  11. package/build/assets/{index-9da8119c.js → index-05061411.js} +2 -2
  12. package/build/assets/{index-9da8119c.js.map → index-05061411.js.map} +1 -1
  13. package/build/assets/{index-67025ed6.js → index-7d1c05fa.js} +16 -16
  14. package/build/assets/{index-67025ed6.js.map → index-7d1c05fa.js.map} +1 -1
  15. package/build/assets/{useChartTheme-d7378f1f.js → useChartTheme-09340a80.js} +2 -2
  16. package/build/assets/{useChartTheme-d7378f1f.js.map → useChartTheme-09340a80.js.map} +1 -1
  17. package/build/assets/{useConnection-e6eca64b.js → useConnection-7b456a8e.js} +2 -2
  18. package/build/assets/{useConnection-e6eca64b.js.map → useConnection-7b456a8e.js.map} +1 -1
  19. package/build/index.html +1 -1
  20. package/package.json +13 -13
@@ -1,3 +1,3 @@
1
- import{a$ as Se,r as h,M as Te,D as u,b0 as be,H as F,b1 as we,E as Ee,F as N,R as Pe,W as l,G as Oe}from"./vendor-927f4ce2.js";import{T as Me,L as P,aX as Fe,aS as Ce,G as _e,J as Ne,D as De,F as xe,K as je,z as Re,R as Le,u as $e,r as Ie,H as Ae,a7 as He}from"./index-9da8119c.js";import{c as ae,g as y}from"./useConnection-e6eca64b.js";function z(r,e,t,n,o,i,a){try{var s=r[i](a),c=s.value}catch(f){t(f);return}s.done?e(c):Promise.resolve(c).then(n,o)}function Ue(r){return function(){var e=this,t=arguments;return new Promise(function(n,o){var i=r.apply(e,t);function a(c){z(i,n,o,a,s,"next",c)}function s(c){z(i,n,o,a,s,"throw",c)}a(void 0)})}}function Ke(r){return I.apply(this,arguments)}function I(){return I=Ue(function*(r){var{clipboard:e}=navigator;if(e!==void 0)try{return navigator.clipboard.writeText(r)}catch{return G(r)}G(r)}),I.apply(this,arguments)}function G(r){var e=document.activeElement,t=document.createElement("textarea");t.value=r,document.body.appendChild(t),t.focus(),t.select();var n=document.execCommand("copy");if(document.body.removeChild(t),e instanceof HTMLElement&&e.focus(),!n)throw new Error("Unable to execute copy command")}const ke={"dh-spectrum-palette":"_dh-spectrum-palette_llwuf_1"},We={"dh-spectrum-alias":"_dh-spectrum-alias_1906d_1"};function V(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable})),t.push.apply(t,n)}return t}function B(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?V(Object(t),!0).forEach(function(n){Ze(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):V(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function Ze(r,e,t){return e=Ye(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function Ye(r){var e=ze(r,"string");return typeof e=="symbol"?e:String(e)}function ze(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var X=B(B({},ke),We);function q(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable})),t.push.apply(t,n)}return t}function x(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?q(Object(t),!0).forEach(function(n){Ge(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):q(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function Ge(r,e,t){return e=Ve(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function Ve(r){var e=Be(r,"string");return typeof e=="symbol"?e:String(e)}function Be(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var{global:Xe,light:qe,dark:Je,medium:Qe,large:et}=Se,tt={global:Xe,light:x(x({},qe),X),dark:x(x({},Je),X),medium:Qe,large:et};function se(r){var{children:e,isPortal:t=!1,theme:n=tt,colorScheme:o}=r,[i]=h.useState(t?Te():null);return u.jsx(be,{UNSAFE_className:"spectrum-theme-provider",theme:n,colorScheme:o,"data-unique-id":i,children:e})}function J(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable})),t.push.apply(t,n)}return t}function rt(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?J(Object(t),!0).forEach(function(n){M(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):J(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function M(r,e,t){return e=nt(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function nt(r){var e=ot(r,"string");return typeof e=="symbol"?e:String(e)}function ot(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var Q="popper";class A extends h.Component{constructor(e){super(e),M(this,"element",void 0),M(this,"container",void 0),M(this,"rAF",void 0),this.handleEnter=this.handleEnter.bind(this),this.handleExit=this.handleExit.bind(this),this.handleBlur=this.handleBlur.bind(this),this.element=document.createElement("div"),this.element.className="popper-container",this.container=F.createRef(),this.rAF=0;var{isShown:t}=this.props;this.state={show:t,popper:null}}componentDidUpdate(e){var{isShown:t}=this.props;e.isShown!==t&&(t?(cancelAnimationFrame(this.rAF),this.rAF=window.requestAnimationFrame(()=>{this.show()})):this.hide())}componentWillUnmount(){this.destroyPopper(!1)}getVisibleElement(e){return e==null||e.clientHeight>0||e.clientWidth>0?e:this.getVisibleElement(e.parentElement)}initPopper(){var{popper:e}=this.state,{closeOnBlur:t,referenceObject:n}=this.props;if(!e&&this.container.current!==null){var{options:o}=this.props;o=rt({placement:"auto",modifiers:{preventOverflow:{boundariesElement:"viewport"}}},o),document.body.appendChild(this.element);var i=this.getVisibleElement(this.container.current);i==null&&(i=this.container.current),e=new we(n||i,this.element,o),e.scheduleUpdate(),cancelAnimationFrame(this.rAF),this.rAF=window.requestAnimationFrame(()=>{if(t){var a=this.element.querySelector(".".concat(Q));a instanceof HTMLElement&&!a.contains(document.activeElement)&&a.focus()}}),this.setState({popper:e})}}destroyPopper(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;cancelAnimationFrame(this.rAF);var{popper:t}=this.state;t&&(t.destroy(),document.body.contains(this.element)&&document.body.removeChild(this.element),e&&this.setState({popper:null}))}show(){this.initPopper(),this.setState({show:!0})}hide(){this.setState({show:!1})}scheduleUpdate(){var{popper:e}=this.state;e&&e.scheduleUpdate()}handleBlur(e){e.relatedTarget instanceof HTMLElement&&(this.element.contains(e.relatedTarget)||this.hide())}handleEnter(){var{onEntered:e}=this.props;e()}handleExit(){var{onExited:e}=this.props,{show:t}=this.state;t||this.destroyPopper(),e()}renderContent(){var{className:e,children:t,timeout:n,interactive:o,closeOnBlur:i}=this.props,{show:a}=this.state;return u.jsx(se,{isPortal:!0,children:u.jsx(Ee,{in:a,timeout:n,classNames:"popper-transition",onEntered:this.handleEnter,onExited:this.handleExit,children:u.jsx("div",{onClick:s=>{s.stopPropagation()},onKeyDown:s=>{s.key==="Escape"&&this.hide()},className:N(Q,{interactive:o},e),onBlur:i?this.handleBlur:void 0,tabIndex:i?-1:void 0,role:"presentation",children:u.jsxs("div",{className:"popper-content",children:[t,u.jsx("div",{className:"popper-arrow","x-arrow":""})]})})})})}render(){var{popper:e}=this.state,{"data-testid":t}=this.props;return u.jsx("div",{className:"popper-parent-container",ref:this.container,style:{display:"none"},"data-testid":t,children:e&&Pe.createPortal(this.renderContent(),this.element)})}}M(A,"propTypes",{children:l.node.isRequired,options:l.shape({}),className:l.string,timeout:l.number,onEntered:l.func,onExited:l.func,isShown:l.bool,closeOnBlur:l.bool,interactive:l.bool,referenceObject:l.shape({}),"data-testid":l.string});M(A,"defaultProps",{options:{},className:"",timeout:Me.transitionMs,onEntered(){},onExited(){},isShown:!1,interactive:!1,closeOnBlur:!1,referenceObject:null,"data-testid":void 0});const it=A;function ee(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable})),t.push.apply(t,n)}return t}function at(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?ee(Object(t),!0).forEach(function(n){v(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):ee(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function v(r,e,t){return e=st(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function st(r){var e=lt(r,"string");return typeof e=="symbol"?e:String(e)}function lt(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var ut=P.module("Tooltip");class m extends h.Component{static handleHidden(){m.shownTooltipCount-=1,m.shownTooltipCount===0&&(m.lastHiddenTime=Date.now())}static handleShown(){m.shownTooltipCount+=1}constructor(e){super(e),v(this,"container",void 0),v(this,"popper",void 0),v(this,"parent",void 0),v(this,"timer",void 0),this.handleMouseMove=this.handleMouseMove.bind(this),this.handleMouseLeave=this.handleMouseLeave.bind(this),this.handleWindowMouseMove=this.handleWindowMouseMove.bind(this),this.handleWheel=this.handleWheel.bind(this),this.handleTimeout=this.handleTimeout.bind(this),this.handleExited=this.handleExited.bind(this),this.stopShowingTooltip=this.stopShowingTooltip.bind(this),this.container=F.createRef(),this.popper=F.createRef(),this.parent=null,this.timer=null,this.state={isShown:!1}}componentDidMount(){this.startListening();var{timeout:e}=this.props;e===0&&this.show()}componentDidUpdate(e,t){var{isShown:n}=t,{isShown:o}=this.state;o!==n&&(o?m.handleShown():m.handleHidden())}componentWillUnmount(){this.stopListening(),this.stopListeningWindow(),this.stopTimer();var{isShown:e}=this.state;e&&m.handleHidden()}startListening(){if(!this.container.current||!this.container.current.parentElement){ut.error("Tooltip doesn't have a container or a parent set!");return}this.parent=this.container.current.parentElement,this.parent.addEventListener("mousemove",this.handleMouseMove),this.parent.addEventListener("mouseleave",this.handleMouseLeave),this.parent.addEventListener("mousedown",this.stopShowingTooltip)}stopListening(){this.parent&&(this.parent.removeEventListener("mousemove",this.handleMouseMove),this.parent.removeEventListener("mouseleave",this.handleMouseLeave),this.parent.removeEventListener("mousedown",this.stopShowingTooltip))}startListeningWindow(){window.addEventListener("mousemove",this.handleWindowMouseMove,!0),window.addEventListener("contextmenu",this.stopShowingTooltip,!0),window.addEventListener("wheel",this.handleWheel)}stopListeningWindow(){window.removeEventListener("mousemove",this.handleWindowMouseMove,!0),window.removeEventListener("contextmenu",this.stopShowingTooltip,!0),window.removeEventListener("wheel",this.handleWheel)}handleMouseMove(){this.startTimer()}handleWheel(){var{isShown:e}=this.state;this.popper.current&&this.parent&&e&&!this.popper.current.element.matches(":hover")&&!this.parent.matches(":hover")&&(this.stopTimer(),this.hide())}handleMouseLeave(){var{isShown:e}=this.state;this.stopTimer();var{interactive:t}=this.props;!t&&e&&this.hide()}handleTimeout(){this.show()}handleWindowMouseMove(e){var t=e.clientX,n=e.clientY,{isShown:o}=this.state;if(!(!this.popper.current||!this.parent)){var i=this.popper.current.element.getBoundingClientRect(),a=this.parent.getBoundingClientRect();t>=i.left&&t<=i.left+i.width&&n>=i.top&&n<=i.top+i.height?this.handleMouseMove():t>=a.left&&t<=a.left+a.width&&n>=a.top&&n<=a.top+a.height?this.handleMouseMove():o&&(this.stopTimer(),this.hide())}}startTimer(){this.stopTimer();var{timeout:e,reshowTimeout:t}=this.props,n=e;(m.shownTooltipCount>0||Date.now()-m.lastHiddenTime<m.triggerReshowThreshold)&&(n=t),this.timer=window.setTimeout(this.handleTimeout,n)}stopTimer(){this.timer!=null&&(clearTimeout(this.timer),this.timer=null)}show(){var{isShown:e}=this.state;if(this.stopTimer(),!e){var t;(t=this.popper.current)===null||t===void 0||t.show(),this.setState({isShown:!0});var{interactive:n}=this.props;n&&this.startListeningWindow()}}hide(){var e;(e=this.popper.current)===null||e===void 0||e.hide(),this.stopListeningWindow()}update(){var e;(e=this.popper.current)===null||e===void 0||e.scheduleUpdate()}handleExited(){this.setState({isShown:!1});var{onExited:e}=this.props;e()}stopShowingTooltip(){var{isShown:e}=this.state;this.stopTimer(),e&&this.hide()}render(){var{interactive:e,children:t,referenceObject:n,popperClassName:o,"data-testid":i,onEntered:a}=this.props,{isShown:s}=this.state,{options:c}=this.props;return c=at({placement:"bottom"},c),u.jsx("div",{ref:this.container,style:{display:"none"},"data-testid":i,children:u.jsx(it,{className:N(o,"popper-tooltip"),options:c,ref:this.popper,onEntered:a,onExited:this.handleExited,interactive:e,referenceObject:n,children:u.jsxs("div",{className:"tooltip-content",children:[" ",s&&t]})})})}}v(m,"defaultTimeout",500);v(m,"defaultReshowTimeout",100);v(m,"triggerReshowThreshold",300);v(m,"shownTooltipCount",0);v(m,"lastHiddenTime",Date.now());v(m,"defaultProps",{interactive:!1,options:{},popperClassName:"",reshowTimeout:m.defaultReshowTimeout,timeout:m.defaultTimeout,onEntered:()=>{},onExited:()=>{},"data-testid":void 0});const mt=m;var dt=3500,ct=P.module("useCopyToClipboard");function ht(){var[r,e]=h.useState(!1),t=h.useRef(null),n=h.useCallback(o=>{Ke(o).then(()=>{e(!0)}).catch(i=>ct.error("Unable to copy ".concat(o),`
1
+ import{a$ as Se,r as h,M as Te,D as u,b0 as be,H as F,b1 as we,E as Ee,F as N,R as Pe,W as l,G as Oe}from"./vendor-927f4ce2.js";import{T as Me,L as P,aX as Fe,aS as Ce,G as _e,J as Ne,D as De,F as xe,K as je,z as Re,R as Le,u as $e,r as Ie,H as Ae,a7 as He}from"./index-05061411.js";import{c as ae,g as y}from"./useConnection-7b456a8e.js";function z(r,e,t,n,o,i,a){try{var s=r[i](a),c=s.value}catch(f){t(f);return}s.done?e(c):Promise.resolve(c).then(n,o)}function Ue(r){return function(){var e=this,t=arguments;return new Promise(function(n,o){var i=r.apply(e,t);function a(c){z(i,n,o,a,s,"next",c)}function s(c){z(i,n,o,a,s,"throw",c)}a(void 0)})}}function Ke(r){return I.apply(this,arguments)}function I(){return I=Ue(function*(r){var{clipboard:e}=navigator;if(e!==void 0)try{return navigator.clipboard.writeText(r)}catch{return G(r)}G(r)}),I.apply(this,arguments)}function G(r){var e=document.activeElement,t=document.createElement("textarea");t.value=r,document.body.appendChild(t),t.focus(),t.select();var n=document.execCommand("copy");if(document.body.removeChild(t),e instanceof HTMLElement&&e.focus(),!n)throw new Error("Unable to execute copy command")}const ke={"dh-spectrum-palette":"_dh-spectrum-palette_llwuf_1"},We={"dh-spectrum-alias":"_dh-spectrum-alias_1906d_1"};function V(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable})),t.push.apply(t,n)}return t}function B(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?V(Object(t),!0).forEach(function(n){Ze(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):V(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function Ze(r,e,t){return e=Ye(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function Ye(r){var e=ze(r,"string");return typeof e=="symbol"?e:String(e)}function ze(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var X=B(B({},ke),We);function q(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable})),t.push.apply(t,n)}return t}function x(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?q(Object(t),!0).forEach(function(n){Ge(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):q(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function Ge(r,e,t){return e=Ve(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function Ve(r){var e=Be(r,"string");return typeof e=="symbol"?e:String(e)}function Be(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var{global:Xe,light:qe,dark:Je,medium:Qe,large:et}=Se,tt={global:Xe,light:x(x({},qe),X),dark:x(x({},Je),X),medium:Qe,large:et};function se(r){var{children:e,isPortal:t=!1,theme:n=tt,colorScheme:o}=r,[i]=h.useState(t?Te():null);return u.jsx(be,{UNSAFE_className:"spectrum-theme-provider",theme:n,colorScheme:o,"data-unique-id":i,children:e})}function J(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable})),t.push.apply(t,n)}return t}function rt(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?J(Object(t),!0).forEach(function(n){M(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):J(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function M(r,e,t){return e=nt(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function nt(r){var e=ot(r,"string");return typeof e=="symbol"?e:String(e)}function ot(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var Q="popper";class A extends h.Component{constructor(e){super(e),M(this,"element",void 0),M(this,"container",void 0),M(this,"rAF",void 0),this.handleEnter=this.handleEnter.bind(this),this.handleExit=this.handleExit.bind(this),this.handleBlur=this.handleBlur.bind(this),this.element=document.createElement("div"),this.element.className="popper-container",this.container=F.createRef(),this.rAF=0;var{isShown:t}=this.props;this.state={show:t,popper:null}}componentDidUpdate(e){var{isShown:t}=this.props;e.isShown!==t&&(t?(cancelAnimationFrame(this.rAF),this.rAF=window.requestAnimationFrame(()=>{this.show()})):this.hide())}componentWillUnmount(){this.destroyPopper(!1)}getVisibleElement(e){return e==null||e.clientHeight>0||e.clientWidth>0?e:this.getVisibleElement(e.parentElement)}initPopper(){var{popper:e}=this.state,{closeOnBlur:t,referenceObject:n}=this.props;if(!e&&this.container.current!==null){var{options:o}=this.props;o=rt({placement:"auto",modifiers:{preventOverflow:{boundariesElement:"viewport"}}},o),document.body.appendChild(this.element);var i=this.getVisibleElement(this.container.current);i==null&&(i=this.container.current),e=new we(n||i,this.element,o),e.scheduleUpdate(),cancelAnimationFrame(this.rAF),this.rAF=window.requestAnimationFrame(()=>{if(t){var a=this.element.querySelector(".".concat(Q));a instanceof HTMLElement&&!a.contains(document.activeElement)&&a.focus()}}),this.setState({popper:e})}}destroyPopper(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;cancelAnimationFrame(this.rAF);var{popper:t}=this.state;t&&(t.destroy(),document.body.contains(this.element)&&document.body.removeChild(this.element),e&&this.setState({popper:null}))}show(){this.initPopper(),this.setState({show:!0})}hide(){this.setState({show:!1})}scheduleUpdate(){var{popper:e}=this.state;e&&e.scheduleUpdate()}handleBlur(e){e.relatedTarget instanceof HTMLElement&&(this.element.contains(e.relatedTarget)||this.hide())}handleEnter(){var{onEntered:e}=this.props;e()}handleExit(){var{onExited:e}=this.props,{show:t}=this.state;t||this.destroyPopper(),e()}renderContent(){var{className:e,children:t,timeout:n,interactive:o,closeOnBlur:i}=this.props,{show:a}=this.state;return u.jsx(se,{isPortal:!0,children:u.jsx(Ee,{in:a,timeout:n,classNames:"popper-transition",onEntered:this.handleEnter,onExited:this.handleExit,children:u.jsx("div",{onClick:s=>{s.stopPropagation()},onKeyDown:s=>{s.key==="Escape"&&this.hide()},className:N(Q,{interactive:o},e),onBlur:i?this.handleBlur:void 0,tabIndex:i?-1:void 0,role:"presentation",children:u.jsxs("div",{className:"popper-content",children:[t,u.jsx("div",{className:"popper-arrow","x-arrow":""})]})})})})}render(){var{popper:e}=this.state,{"data-testid":t}=this.props;return u.jsx("div",{className:"popper-parent-container",ref:this.container,style:{display:"none"},"data-testid":t,children:e&&Pe.createPortal(this.renderContent(),this.element)})}}M(A,"propTypes",{children:l.node.isRequired,options:l.shape({}),className:l.string,timeout:l.number,onEntered:l.func,onExited:l.func,isShown:l.bool,closeOnBlur:l.bool,interactive:l.bool,referenceObject:l.shape({}),"data-testid":l.string});M(A,"defaultProps",{options:{},className:"",timeout:Me.transitionMs,onEntered(){},onExited(){},isShown:!1,interactive:!1,closeOnBlur:!1,referenceObject:null,"data-testid":void 0});const it=A;function ee(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable})),t.push.apply(t,n)}return t}function at(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?ee(Object(t),!0).forEach(function(n){v(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):ee(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function v(r,e,t){return e=st(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function st(r){var e=lt(r,"string");return typeof e=="symbol"?e:String(e)}function lt(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var ut=P.module("Tooltip");class m extends h.Component{static handleHidden(){m.shownTooltipCount-=1,m.shownTooltipCount===0&&(m.lastHiddenTime=Date.now())}static handleShown(){m.shownTooltipCount+=1}constructor(e){super(e),v(this,"container",void 0),v(this,"popper",void 0),v(this,"parent",void 0),v(this,"timer",void 0),this.handleMouseMove=this.handleMouseMove.bind(this),this.handleMouseLeave=this.handleMouseLeave.bind(this),this.handleWindowMouseMove=this.handleWindowMouseMove.bind(this),this.handleWheel=this.handleWheel.bind(this),this.handleTimeout=this.handleTimeout.bind(this),this.handleExited=this.handleExited.bind(this),this.stopShowingTooltip=this.stopShowingTooltip.bind(this),this.container=F.createRef(),this.popper=F.createRef(),this.parent=null,this.timer=null,this.state={isShown:!1}}componentDidMount(){this.startListening();var{timeout:e}=this.props;e===0&&this.show()}componentDidUpdate(e,t){var{isShown:n}=t,{isShown:o}=this.state;o!==n&&(o?m.handleShown():m.handleHidden())}componentWillUnmount(){this.stopListening(),this.stopListeningWindow(),this.stopTimer();var{isShown:e}=this.state;e&&m.handleHidden()}startListening(){if(!this.container.current||!this.container.current.parentElement){ut.error("Tooltip doesn't have a container or a parent set!");return}this.parent=this.container.current.parentElement,this.parent.addEventListener("mousemove",this.handleMouseMove),this.parent.addEventListener("mouseleave",this.handleMouseLeave),this.parent.addEventListener("mousedown",this.stopShowingTooltip)}stopListening(){this.parent&&(this.parent.removeEventListener("mousemove",this.handleMouseMove),this.parent.removeEventListener("mouseleave",this.handleMouseLeave),this.parent.removeEventListener("mousedown",this.stopShowingTooltip))}startListeningWindow(){window.addEventListener("mousemove",this.handleWindowMouseMove,!0),window.addEventListener("contextmenu",this.stopShowingTooltip,!0),window.addEventListener("wheel",this.handleWheel)}stopListeningWindow(){window.removeEventListener("mousemove",this.handleWindowMouseMove,!0),window.removeEventListener("contextmenu",this.stopShowingTooltip,!0),window.removeEventListener("wheel",this.handleWheel)}handleMouseMove(){this.startTimer()}handleWheel(){var{isShown:e}=this.state;this.popper.current&&this.parent&&e&&!this.popper.current.element.matches(":hover")&&!this.parent.matches(":hover")&&(this.stopTimer(),this.hide())}handleMouseLeave(){var{isShown:e}=this.state;this.stopTimer();var{interactive:t}=this.props;!t&&e&&this.hide()}handleTimeout(){this.show()}handleWindowMouseMove(e){var t=e.clientX,n=e.clientY,{isShown:o}=this.state;if(!(!this.popper.current||!this.parent)){var i=this.popper.current.element.getBoundingClientRect(),a=this.parent.getBoundingClientRect();t>=i.left&&t<=i.left+i.width&&n>=i.top&&n<=i.top+i.height?this.handleMouseMove():t>=a.left&&t<=a.left+a.width&&n>=a.top&&n<=a.top+a.height?this.handleMouseMove():o&&(this.stopTimer(),this.hide())}}startTimer(){this.stopTimer();var{timeout:e,reshowTimeout:t}=this.props,n=e;(m.shownTooltipCount>0||Date.now()-m.lastHiddenTime<m.triggerReshowThreshold)&&(n=t),this.timer=window.setTimeout(this.handleTimeout,n)}stopTimer(){this.timer!=null&&(clearTimeout(this.timer),this.timer=null)}show(){var{isShown:e}=this.state;if(this.stopTimer(),!e){var t;(t=this.popper.current)===null||t===void 0||t.show(),this.setState({isShown:!0});var{interactive:n}=this.props;n&&this.startListeningWindow()}}hide(){var e;(e=this.popper.current)===null||e===void 0||e.hide(),this.stopListeningWindow()}update(){var e;(e=this.popper.current)===null||e===void 0||e.scheduleUpdate()}handleExited(){this.setState({isShown:!1});var{onExited:e}=this.props;e()}stopShowingTooltip(){var{isShown:e}=this.state;this.stopTimer(),e&&this.hide()}render(){var{interactive:e,children:t,referenceObject:n,popperClassName:o,"data-testid":i,onEntered:a}=this.props,{isShown:s}=this.state,{options:c}=this.props;return c=at({placement:"bottom"},c),u.jsx("div",{ref:this.container,style:{display:"none"},"data-testid":i,children:u.jsx(it,{className:N(o,"popper-tooltip"),options:c,ref:this.popper,onEntered:a,onExited:this.handleExited,interactive:e,referenceObject:n,children:u.jsxs("div",{className:"tooltip-content",children:[" ",s&&t]})})})}}v(m,"defaultTimeout",500);v(m,"defaultReshowTimeout",100);v(m,"triggerReshowThreshold",300);v(m,"shownTooltipCount",0);v(m,"lastHiddenTime",Date.now());v(m,"defaultProps",{interactive:!1,options:{},popperClassName:"",reshowTimeout:m.defaultReshowTimeout,timeout:m.defaultTimeout,onEntered:()=>{},onExited:()=>{},"data-testid":void 0});const mt=m;var dt=3500,ct=P.module("useCopyToClipboard");function ht(){var[r,e]=h.useState(!1),t=h.useRef(null),n=h.useCallback(o=>{Ke(o).then(()=>{e(!0)}).catch(i=>ct.error("Unable to copy ".concat(o),`
2
2
  `,i))},[]);return h.useEffect(()=>(t.current&&clearTimeout(t.current),r&&(t.current=setTimeout(()=>{e(!1)},dt)),()=>{t.current&&clearTimeout(t.current)}),[r]),[r,n]}var pt=["kind","variant","type","tooltip","icon","disabled","active","onClick","onContextMenu","onMouseDown","onMouseUp","onMouseEnter","onMouseLeave","onKeyDown","className","style","children","tabIndex","data-testid","aria-label"];function te(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable})),t.push.apply(t,n)}return t}function re(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?te(Object(t),!0).forEach(function(n){ft(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):te(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function ft(r,e,t){return e=vt(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function vt(r){var e=gt(r,"string");return typeof e=="symbol"?e:String(e)}function gt(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}function yt(r,e){if(r==null)return{};var t=St(r,e),n,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(r);for(o=0;o<i.length;o++)n=i[o],!(e.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(r,n)&&(t[n]=r[n])}return t}function St(r,e){if(r==null)return{};var t={},n=Object.keys(r),o,i;for(i=0;i<n.length;i++)o=n[i],!(e.indexOf(o)>=0)&&(t[o]=r[o]);return t}var Tt=["primary","secondary","tertiary","success","danger","inline","ghost"],bt=["group-end"];function wt(r,e){switch(r){case"primary":return"btn-primary";case"secondary":return"btn-outline-primary";case"tertiary":return"btn-secondary";case"success":return"btn-success";case"danger":return"btn-danger";case"inline":return"btn-inline";case"ghost":return N("btn-link",{"btn-link-icon":e,"btn-link-icon-only":e})}}function Et(r){switch(r){case"group-end":return N("pl-2","pr-3")}}var j=F.forwardRef((r,e)=>{var{kind:t,variant:n,type:o,tooltip:i,icon:a,disabled:s=!1,active:c,onClick:f,onContextMenu:D,onMouseDown:g,onMouseUp:w,onMouseEnter:C,onMouseLeave:de,onKeyDown:ce,className:he,style:pe,children:U,tabIndex:fe,"data-testid":ve,"aria-label":K}=r,ge=yt(r,pt),k;n&&(k=Et(n));var L;a&&(L=F.isValidElement(a)?a:u.jsx(Oe,{icon:a}));var W=L!=null&&U==null,ye=wt(t,W),$;i!==void 0&&($=typeof i=="string"?u.jsx(mt,{children:i}):i);var Z=K;K===void 0&&W&&i!=null&&typeof i=="string"&&(Z=i);var Y=u.jsxs("button",re(re({"data-testid":ve,ref:e,type:o,className:N("btn",ye,k,{active:c},he),onClick:f,onContextMenu:D,onMouseUp:w,onMouseDown:g,onMouseEnter:C,onMouseLeave:de,onKeyDown:ce,style:pe,disabled:s,tabIndex:fe,"aria-label":Z},ge),{},{children:[a&&L,U,i!=null&&!s&&$]}));return s&&i!=null?u.jsxs("span",{className:"btn-disabled-wrapper",children:[Y,$]}):Y});j.displayName="Button";j.propTypes={kind:l.oneOf(Tt).isRequired,variant:l.oneOf(bt),type:l.oneOf(["submit","reset","button"]),tooltip(r){var{tooltip:e,icon:t,children:n}=r;return e===void 0&&t!=null&&n==null?new Error("Tooltip is required for icon only buttons"):null},icon(r){var{children:e,icon:t}=r;return t==null&&e==null?new Error("Icon is required if no children are provided"):e==null&&!F.isValidElement(t)&&(t==null||t.iconName===""||t.iconName==null)?new Error("Icon must be react element or fontawesome IconDefinition"):null},disabled:l.bool,active:l.bool,onClick(r){var{onClick:e,type:t}=r;return t==="button"&&typeof e!="function"?new Error("type button requires an onClick function"):e!==void 0&&typeof e!="function"?new Error("onClick must be a function"):null},onContextMenu:l.func,onMouseUp:l.func,onMouseDown:l.func,onMouseEnter:l.func,onMouseLeave:l.func,onKeyDown:l.func,tabIndex:l.number,children:l.node,className:l.string,style:l.object,"data-testid":l.string};j.defaultProps={type:"button",onClick:void 0,onContextMenu:void 0,onMouseUp:void 0,onMouseDown:void 0,onMouseEnter:void 0,onMouseLeave:void 0,onKeyDown:void 0,variant:void 0,tooltip:void 0,icon:void 0,disabled:!1,active:void 0,tabIndex:void 0,children:void 0,className:void 0,style:{},"data-testid":void 0};const Pt=j;function ar(r){var{copy:e,kind:t="ghost",tooltip:n="Copy",className:o,style:i,"data-testid":a,children:s}=r,[c,f]=ht();return u.jsx(Pt,{kind:t,className:o,style:i,"data-testid":a,icon:c?Fe:Ce,tooltip:c?"Copied":n,onClick:()=>{f(typeof e=="function"?e():e)},children:s})}var Ot=P.module("ThemeProvider"),le=h.createContext(null);function sr(r){var{themes:e,defaultPreloadValues:t=$e,children:n}=r,o=h.useMemo(()=>_e(),[]),[i,a]=h.useState(null),[s,c]=h.useState(()=>{var g,w;return(g=(w=Ne())===null||w===void 0?void 0:w.themeKey)!==null&&g!==void 0?g:De}),f=h.useMemo(()=>e==null?null:xe(s,{base:o,custom:e??[]}),[o,s,e]),D=h.useMemo(()=>[...o,...e??[]],[o,e]);return h.useEffect(function(){if(!(f==null||e==null)){je(t);var w=Re(t);Ot.debug2("updateThemePreloadData:",{active:f.map(C=>C.themeKey),custom:e.map(C=>C.themeKey),preloadStyleContent:w,selectedThemeKey:s}),Le({themeKey:s,preloadStyleContent:w})}},[f,s,e,t]),h.useEffect(()=>{a({activeThemes:f,selectedThemeKey:s,themes:D,setSelectedThemeKey:c})},[f,s,D]),u.jsxs(u.Fragment,{children:[f==null?null:u.jsx(u.Fragment,{children:f.map(g=>u.jsx("style",{"data-theme-key":g.themeKey,children:g.styleContent},g.themeKey))}),i==null?null:u.jsx(le.Provider,{value:i,children:u.jsx(se,{children:n})})]})}function Mt(){return ae(le,"No ThemeContext value found. Component must be wrapped in a ThemeContext.Provider")}function H(r,e,t){return e=Ft(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function Ft(r){var e=Ct(r,"string");return typeof e=="symbol"?e:String(e)}function Ct(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}class R{static isValid(e,t){return!0}static isSameFormat(e,t){throw new Error("isSameFormat not implemented")}static makeFormat(e,t,n){return{label:e,formatString:t,type:n}}format(e,t){return""}}H(R,"TYPE_GLOBAL","type-global");H(R,"TYPE_CONTEXT_PRESET","type-context-preset");H(R,"TYPE_CONTEXT_CUSTOM","type-context-custom");const p=R;class _t extends p{format(e){switch(e){case 1:case!0:return"true";case 0:case!1:return"false";default:return""}}}const Nt=_t;class Dt extends p{format(e){return String.fromCharCode(e)}}const xt=Dt;function E(r,e,t){return e=jt(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function jt(r){var e=Rt(r,"string");return typeof e=="symbol"?e:String(e)}function Rt(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var ne=P.module("DateTimeColumnFormatter");class S extends p{static isValid(e,t){if(t.formatString==null)return!1;try{return e.i18n.DateTimeFormat.format(t.formatString,new Date),!0}catch{return!1}}static makeFormat(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:p.TYPE_CONTEXT_PRESET;return{label:e,formatString:t,type:n}}static isSameFormat(e,t){return e===t||e!==null&&t!==null&&e.type===t.type&&e.formatString===t.formatString}static makeGlobalFormatStringMap(e,t){var n=t?"'T'":" ",o=e?" z":"";return new Map([["yyyy-MM-dd HH:mm:ss","yyyy-MM-dd".concat(n,"HH:mm:ss").concat(o)],["yyyy-MM-dd HH:mm:ss.SSS","yyyy-MM-dd".concat(n,"HH:mm:ss.SSS").concat(o)],["yyyy-MM-dd HH:mm:ss.SSSSSSSSS","yyyy-MM-dd".concat(n,"HH:mm:ss.SSSSSSSSS").concat(o)]])}static getGlobalFormats(e,t){var n=S.makeGlobalFormatStringMap(e,t);return[...n.keys()]}static makeFormatStringMap(e,t){var n=t!==void 0&&t?"'T'":" ",o=e!==void 0&&e?" z":"";return new Map([["yyyy-MM-dd","yyyy-MM-dd".concat(o)],["MM-dd-yyyy","MM-dd-yyyy".concat(o)],["HH:mm:ss","HH:mm:ss".concat(o)],["HH:mm:ss.SSS","HH:mm:ss.SSS".concat(o)],["HH:mm:ss.SSSSSSSSS","HH:mm:ss.SSSSSSSSS".concat(o)],["yyyy-MM-dd HH:mm:ss","yyyy-MM-dd".concat(n,"HH:mm:ss").concat(o)],["yyyy-MM-dd HH:mm:ss.SSS","yyyy-MM-dd".concat(n,"HH:mm:ss.SSS").concat(o)],["yyyy-MM-dd HH:mm:ss.SSSSSSSSS","yyyy-MM-dd".concat(n,"HH:mm:ss.SSSSSSSSS").concat(o)]])}static getFormats(e,t){var n=S.makeFormatStringMap(e,t);return[...n.keys()]}constructor(e){var{timeZone:t="",showTimeZone:n=!0,showTSeparator:o=!1,defaultDateTimeFormatString:i=S.DEFAULT_DATETIME_FORMAT_STRING}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};super(),E(this,"dh",void 0),E(this,"dhTimeZone",void 0),E(this,"defaultDateTimeFormatString",void 0),E(this,"showTimeZone",void 0),E(this,"showTSeparator",void 0),E(this,"formatStringMap",void 0);var a=t||S.DEFAULT_TIME_ZONE_ID;try{this.dhTimeZone=e.i18n.TimeZone.getTimeZone(a)}catch{ne.error("Unsupported time zone id",a),this.dhTimeZone=e.i18n.TimeZone.getTimeZone(S.DEFAULT_TIME_ZONE_ID)}this.dh=e,this.defaultDateTimeFormatString=i,this.showTimeZone=n,this.showTSeparator=o,this.formatStringMap=S.makeFormatStringMap(n,o)}getEffectiveFormatString(e){var t;return(t=this.formatStringMap.get(e))!==null&&t!==void 0?t:e}format(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.formatString!=null&&t.formatString!==""?t.formatString:this.defaultDateTimeFormatString,o=this.getEffectiveFormatString(n);try{return this.dh.i18n.DateTimeFormat.format(o,e,this.dhTimeZone)}catch{ne.error("Invalid format arguments")}return""}}E(S,"DEFAULT_DATETIME_FORMAT_STRING","yyyy-MM-dd HH:mm:ss.SSS");E(S,"DEFAULT_TIME_ZONE_ID","America/New_York");function b(r,e,t){return e=Lt(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function Lt(r){var e=$t(r,"string");return typeof e=="symbol"?e:String(e)}function $t(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var It=P.module("DecimalColumnFormatter");class d extends p{static isValid(e,t){if(t.formatString==null)return!1;try{return e.i18n.NumberFormat.format(t.formatString,0),!0}catch{return!1}}static makeFormat(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:p.TYPE_CONTEXT_PRESET,o=arguments.length>3?arguments[3]:void 0;return{label:e,type:n,formatString:t,multiplier:o}}static makePresetFormat(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",n=arguments.length>2?arguments[2]:void 0;return d.makeFormat(e,t,p.TYPE_CONTEXT_PRESET,n)}static makeCustomFormat(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0;return d.makeFormat("Custom Format",e,p.TYPE_CONTEXT_CUSTOM,t)}static isSameFormat(e,t){return e===t||e!=null&&t!=null&&e.type===t.type&&e.formatString===t.formatString&&e.multiplier===t.multiplier}constructor(e){var{defaultFormatString:t=d.DEFAULT_FORMAT_STRING}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};super(),b(this,"defaultFormatString",void 0),b(this,"dh",void 0),this.dh=e,this.defaultFormatString=t}format(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.formatString!=null&&t.formatString!==""?t.formatString:this.defaultFormatString,o=t.multiplier!=null&&t.multiplier!==0?e*t.multiplier:e;try{return this.dh.i18n.NumberFormat.format(n,o)}catch{It.error("Invalid format arguments")}return""}}b(d,"DEFAULT_FORMAT_STRING","###,##0.0000");b(d,"FORMAT_PERCENT",d.makePresetFormat("Percent","##0.00%"));b(d,"FORMAT_BASIS_POINTS",d.makePresetFormat("Basis Points","###,##0 bp",1e4));b(d,"FORMAT_MILLIONS",d.makePresetFormat("Millions","###,##0.000 mm",1e-6));b(d,"FORMAT_SCIENTIFIC_NOTATION",d.makePresetFormat("Scientific Notation","0.0000E0"));b(d,"FORMAT_ROUND",d.makePresetFormat("Round","###,##0"));b(d,"FORMAT_ROUND_TWO_DECIMALS",d.makePresetFormat("0.00","###,##0.00"));b(d,"FORMAT_ROUND_FOUR_DECIMALS",d.makePresetFormat("0.0000","###,##0.0000"));class At extends p{format(e){return"".concat(e)}}const Ht=At;function _(r,e,t){return e=Ut(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function Ut(r){var e=Kt(r,"string");return typeof e=="symbol"?e:String(e)}function Kt(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var kt=P.module("IntegerColumnFormatter");class T extends p{static isValid(e,t){if(t.formatString==null)return!1;try{return e.i18n.NumberFormat.format(t.formatString,0),!0}catch{return!1}}static makeFormat(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:p.TYPE_CONTEXT_PRESET,o=arguments.length>3?arguments[3]:void 0;return{label:e,type:n,formatString:t,multiplier:o}}static makePresetFormat(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",n=arguments.length>2?arguments[2]:void 0;return T.makeFormat(e,t,p.TYPE_CONTEXT_PRESET,n)}static makeCustomFormat(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0;return T.makeFormat("Custom Format",e,p.TYPE_CONTEXT_CUSTOM,t)}static isSameFormat(e,t){return e===t||e!=null&&t!=null&&e.type===t.type&&e.formatString===t.formatString&&e.multiplier===t.multiplier}constructor(e){var{defaultFormatString:t=T.DEFAULT_FORMAT_STRING}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};super(),_(this,"dh",void 0),_(this,"defaultFormatString",void 0),this.dh=e,this.defaultFormatString=t}format(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.formatString!=null&&t.formatString!==""?t.formatString:this.defaultFormatString,o=t.multiplier!=null&&t.multiplier!==0?e*t.multiplier:e;try{return this.dh.i18n.NumberFormat.format(n,o)}catch{kt.error("Invalid format arguments")}return""}}_(T,"DEFAULT_FORMAT_STRING","###,##0");_(T,"FORMAT_MILLIONS",T.makePresetFormat("Millions","###,##0.000 mm",1e-6));_(T,"FORMAT_SCIENTIFIC_NOTATION",T.makePresetFormat("Scientific Notation","0.0000E0"));class Wt extends p{format(e){return e}}function O(r,e,t){return e=Zt(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function Zt(r){var e=Yt(r,"string");return typeof e=="symbol"?e:String(e)}function Yt(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}class ue{static makeColumnFormatMap(e){return e==null?new Map:e.reduce((t,n)=>{var o=y.getNormalizedType(n.columnType);if(o===null)return t;t.has(o)||t.set(o,new Map);var i=t.get(o);return i==null||i.set(n.columnName,n.format),t},new Map)}static makeColumnFormattingRule(e,t,n){return{columnType:e,columnName:t,format:n}}constructor(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,i=arguments.length>4?arguments[4]:void 0,a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:!1,s=arguments.length>6&&arguments[6]!==void 0?arguments[6]:!0,c=arguments.length>7&&arguments[7]!==void 0?arguments[7]:!0;O(this,"defaultColumnFormatter",void 0),O(this,"typeFormatterMap",void 0),O(this,"columnFormatMap",void 0),O(this,"truncateNumbersWithPound",void 0),O(this,"showEmptyStrings",void 0),O(this,"showNullStrings",void 0),this.defaultColumnFormatter=new Ht,this.typeFormatterMap=new Map([[y.dataType.BOOLEAN,new Nt],[y.dataType.CHAR,new xt],[y.dataType.DATETIME,new S(e,n)],[y.dataType.DECIMAL,new d(e,o)],[y.dataType.INT,new T(e,i)],[y.dataType.STRING,new Wt]]),this.columnFormatMap=ue.makeColumnFormatMap(t),this.truncateNumbersWithPound=a,this.showEmptyStrings=s,this.showNullStrings=c}getColumnFormatMapForType(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=y.getNormalizedType(e);if(n!==null)return t&&!this.columnFormatMap.has(n)&&this.columnFormatMap.set(n,new Map),this.columnFormatMap.get(n)}getColumnFormat(e,t){var n,o=this.getColumnFormatMapForType(e);return(n=o==null?void 0:o.get(t))!==null&&n!==void 0?n:null}getColumnTypeFormatter(e){var t=y.getNormalizedType(e),n=this.defaultColumnFormatter;if(t){var o;n=(o=this.typeFormatterMap.get(t))!==null&&o!==void 0?o:n}return n}getFormattedString(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"",o=arguments.length>3?arguments[3]:void 0;if(e==null)return"";var i=this.getColumnTypeFormatter(t),a=o||this.getColumnFormat(t,n);return i.format(e,a??void 0)}get timeZone(){var e,t=this.typeFormatterMap.get(y.dataType.DATETIME);return t==null||(e=t.dhTimeZone)===null||e===void 0?void 0:e.id}}function zt(r){if(r&&r.formatter){var{formatter:e}=r;return e}}function Gt(r){return{timeZone:r==null?void 0:r.timeZone,defaultDateTimeFormatString:r==null?void 0:r.defaultDateTimeFormat,showTimeZone:r==null?void 0:r.showTimeZone,showTSeparator:r==null?void 0:r.showTSeparator}}function Vt(r,e,t){var n=r.getColumnFormat(t,e);return n!=null&&(n.type===p.TYPE_CONTEXT_PRESET||n.type===p.TYPE_CONTEXT_CUSTOM)}const lr={getColumnFormats:zt,getDateTimeFormatterOptions:Gt,isCustomColumnFormatDefined:Vt};function Bt(r,e,t){return e=Xt(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function Xt(r){var e=qt(r,"string");return typeof e=="symbol"?e:String(e)}function qt(r,e){if(typeof r!="object"||r===null)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}class ur extends Error{constructor(){super(...arguments),Bt(this,"isDownsamplingError",!0)}}const Jt="var(--dh-color-chart-colorway)",Qt="var(--dh-color-chart-grid)",er="var(--dh-color-chart-axis-line)",tr="var(--dh-color-chart-axis-line-zero)",oe={"paper-bgcolor":"var(--dh-color-chart-bg)","plot-bgcolor":"var(--dh-color-chart-plot-bg)","title-color":"var(--dh-color-chart-title)","legend-color":"var(--dh-color-chart-legend-fg)",colorway:Jt,gridcolor:Qt,linecolor:er,zerolinecolor:tr,"error-band-line-color":"var(--dh-color-chart-error-band-line)","ohlc-increasing":"var(--dh-color-chart-ohlc-increase)","ohlc-decreasing":"var(--dh-color-chart-ohlc-decrease)","coastline-color":"var(--dh-color-chart-geo-coastline)","land-color":"var(--dh-color-chart-geo-land)","ocean-color":"var(--dh-color-chart-geo-ocean)","lake-color":"var(--dh-color-chart-geo-lake)","river-color":"var(--dh-color-chart-geo-river)"};var ie=P.module("ChartTheme");function rr(){var r,e=Ie(oe);return e.colorway=Ae((r=e.colorway)!==null&&r!==void 0?r:"").map(t=>{var[n,o]=t;return He.normalizeCssColor(e.colorway.substring(n,o+1))}).join(" "),ie.debug2("Chart theme:",oe),ie.debug2("Chart theme derived:",e),Object.freeze({paper_bgcolor:e["paper-bgcolor"],plot_bgcolor:e["plot-bgcolor"],title_color:e["title-color"],legend_color:e["legend-color"],colorway:e.colorway,gridcolor:e.gridcolor,linecolor:e.linecolor,zerolinecolor:e.zerolinecolor,error_band_line_color:e["error-band-line-color"],ohlc_increasing:e["ohlc-increasing"],ohlc_decreasing:e["ohlc-decreasing"],coastline_color:e["coastline-color"],land_color:e["land-color"],ocean_color:e["ocean-color"],lake_color:e["lake-color"],river_color:e["river-color"]})}var me=h.createContext(null);function mr(r){var{children:e}=r,{activeThemes:t}=Mt(),n=h.useMemo(rr,[t]);return u.jsx(me.Provider,{value:n,children:e})}function dr(){return ae(me,"No ChartThemeContext value found.")}export{Pt as B,ar as C,S as D,ue as F,T as I,it as P,Wt as S,mt as T,Mt as a,le as b,sr as c,Nt as d,xt as e,d as f,Ht as g,lr as h,p as i,zt as j,Gt as k,Vt as l,rr as m,me as n,mr as o,ur as p,dr as q,Ke as r,tt as t,ht as u};
3
- //# sourceMappingURL=useChartTheme-d7378f1f.js.map
3
+ //# sourceMappingURL=useChartTheme-09340a80.js.map