@deephaven/dashboard 1.1.2-beta.0 → 1.1.2-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 (39) hide show
  1. package/dist/BasePanel.js.map +1 -1
  2. package/dist/Dashboard.js.map +1 -1
  3. package/dist/DashboardConstants.js.map +1 -1
  4. package/dist/DashboardEvents.js.map +1 -1
  5. package/dist/DashboardLayout.js.map +1 -1
  6. package/dist/DashboardPanelWrapper.js.map +1 -1
  7. package/dist/DashboardPlugin.js.map +1 -1
  8. package/dist/DashboardUtils.js.map +1 -1
  9. package/dist/LazyDashboard.js.map +1 -1
  10. package/dist/NavigationEvent.js.map +1 -1
  11. package/dist/PanelContextMenu.js.map +1 -1
  12. package/dist/PanelErrorBoundary.js.map +1 -1
  13. package/dist/PanelEvent.js.map +1 -1
  14. package/dist/PanelManager.js.map +1 -1
  15. package/dist/PanelPlaceholder.js.map +1 -1
  16. package/dist/RenameDialog.js.map +1 -1
  17. package/dist/TabEvent.js.map +1 -1
  18. package/dist/declaration.d.js.map +1 -1
  19. package/dist/index.js.map +1 -1
  20. package/dist/layout/GLPropTypes.js.map +1 -1
  21. package/dist/layout/LayoutManagerContext.js.map +1 -1
  22. package/dist/layout/LayoutUtils.js.map +1 -1
  23. package/dist/layout/index.js.map +1 -1
  24. package/dist/layout/useDashboardPanel.js.map +1 -1
  25. package/dist/layout/useLayoutManager.js.map +1 -1
  26. package/dist/layout/useListener.js.map +1 -1
  27. package/dist/layout/usePanelRegistration.js.map +1 -1
  28. package/dist/redux/actionTypes.js.map +1 -1
  29. package/dist/redux/actions.js.map +1 -1
  30. package/dist/redux/hooks.js.map +1 -1
  31. package/dist/redux/index.js.map +1 -1
  32. package/dist/redux/reducers/dashboardData.js.map +1 -1
  33. package/dist/redux/reducers/index.js.map +1 -1
  34. package/dist/redux/selectors.js.map +1 -1
  35. package/dist/useDashboardId.js.map +1 -1
  36. package/dist/useDhId.js.map +1 -1
  37. package/dist/useFiber.js.map +1 -1
  38. package/dist/usePanelId.js.map +1 -1
  39. package/package.json +10 -10
@@ -1 +1 @@
1
- {"version":3,"file":"useListener.js","names":["useEffect","useListener","eventEmitter","eventName","callback","initEventEmitter","on","off"],"sources":["../../src/layout/useListener.ts"],"sourcesContent":["import { useEffect } from 'react';\nimport type { EventEmitter } from '@deephaven/golden-layout';\n\n/**\n * Listen for a specific event on an EventEmitter\n * @param eventEmitter EventEmitter to listen to\n * @param eventName Name of the event to listen to\n * @param callback Callback to call when the event is triggered\n */\nexport function useListener(\n eventEmitter: EventEmitter,\n eventName: string,\n // eslint-disable-next-line @typescript-eslint/ban-types\n callback: Function\n): void {\n useEffect(\n function initEventEmitter() {\n eventEmitter.on(eventName, callback);\n\n return () => {\n eventEmitter.off(eventName, callback);\n };\n },\n [eventEmitter, eventName, callback]\n );\n}\n\nexport default useListener;\n"],"mappings":"AAAA,SAASA,SAAS,QAAQ,OAAO;AAGjC;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,WAAWA,CACzBC,YAA0B,EAC1BC,SAAiB;AACjB;AACAC,QAAkB,EACZ;EACNJ,SAAS,CACP,SAASK,gBAAgBA,CAAA,EAAG;IAC1BH,YAAY,CAACI,EAAE,CAACH,SAAS,EAAEC,QAAQ,CAAC;IAEpC,OAAO,MAAM;MACXF,YAAY,CAACK,GAAG,CAACJ,SAAS,EAAEC,QAAQ,CAAC;IACvC,CAAC;EACH,CAAC,EACD,CAACF,YAAY,EAAEC,SAAS,EAAEC,QAAQ,CACpC,CAAC;AACH;AAEA,eAAeH,WAAW"}
1
+ {"version":3,"file":"useListener.js","names":["useEffect","useListener","eventEmitter","eventName","callback","initEventEmitter","on","off"],"sources":["../../src/layout/useListener.ts"],"sourcesContent":["import { useEffect } from 'react';\nimport type { EventEmitter } from '@deephaven/golden-layout';\n\n/**\n * Listen for a specific event on an EventEmitter\n * @param eventEmitter EventEmitter to listen to\n * @param eventName Name of the event to listen to\n * @param callback Callback to call when the event is triggered\n */\nexport function useListener(\n eventEmitter: EventEmitter,\n eventName: string,\n // eslint-disable-next-line @typescript-eslint/ban-types\n callback: Function\n): void {\n useEffect(\n function initEventEmitter() {\n eventEmitter.on(eventName, callback);\n\n return () => {\n eventEmitter.off(eventName, callback);\n };\n },\n [eventEmitter, eventName, callback]\n );\n}\n\nexport default useListener;\n"],"mappings":"AAAA,SAASA,SAAS,QAAQ,OAAO;AAGjC;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,WAAWA,CACzBC,YAA0B,EAC1BC,SAAiB;AACjB;AACAC,QAAkB,EACZ;EACNJ,SAAS,CACP,SAASK,gBAAgBA,CAAA,EAAG;IAC1BH,YAAY,CAACI,EAAE,CAACH,SAAS,EAAEC,QAAQ,CAAC;IAEpC,OAAO,MAAM;MACXF,YAAY,CAACK,GAAG,CAACJ,SAAS,EAAEC,QAAQ,CAAC;IACvC,CAAC;EACH,CAAC,EACD,CAACF,YAAY,EAAEC,SAAS,EAAEC,QAAQ,CACpC,CAAC;AACH;AAEA,eAAeH,WAAW","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"usePanelRegistration.js","names":["React","usePanelRegistration","registerComponent","ComponentType","hydrate","dehydrate","_ComponentType$COMPON","name","COMPONENT","displayName","Error","useEffect","deregister"],"sources":["../../src/layout/usePanelRegistration.ts"],"sourcesContent":["import React from 'react';\nimport {\n type DashboardPanelProps,\n type DashboardPluginComponentProps,\n type PanelComponentType,\n type PanelDehydrateFunction,\n type PanelHydrateFunction,\n} from '../DashboardPlugin';\n\n/**\n * Registers a given panel component. Also runs a `useEffect` that will\n * automatically de-register then panel on unmount.\n * @param registerComponent\n * @param ComponentType\n * @param hydrate\n * @param dehydrate\n */\nexport default function usePanelRegistration<\n P extends DashboardPanelProps,\n C extends React.ComponentType<P>,\n>(\n registerComponent: DashboardPluginComponentProps['registerComponent'],\n ComponentType: PanelComponentType<P, C>,\n hydrate?: PanelHydrateFunction,\n dehydrate?: PanelDehydrateFunction\n): void {\n const name = ComponentType.COMPONENT ?? ComponentType.displayName;\n\n if (name == null) {\n throw new Error(\n 'ComponentType must have a `COMPONENT` or `displayName` attribute.'\n );\n }\n\n React.useEffect(() => {\n const deregister = registerComponent(\n name,\n ComponentType,\n hydrate,\n dehydrate\n );\n\n return () => {\n deregister();\n };\n }, [ComponentType, dehydrate, hydrate, name, registerComponent]);\n}\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AASzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,SAASC,oBAAoBA,CAI1CC,iBAAqE,EACrEC,aAAuC,EACvCC,OAA8B,EAC9BC,SAAkC,EAC5B;EAAA,IAAAC,qBAAA;EACN,IAAMC,IAAI,IAAAD,qBAAA,GAAGH,aAAa,CAACK,SAAS,cAAAF,qBAAA,cAAAA,qBAAA,GAAIH,aAAa,CAACM,WAAW;EAEjE,IAAIF,IAAI,IAAI,IAAI,EAAE;IAChB,MAAM,IAAIG,KAAK,CACb,mEACF,CAAC;EACH;EAEAV,KAAK,CAACW,SAAS,CAAC,MAAM;IACpB,IAAMC,UAAU,GAAGV,iBAAiB,CAClCK,IAAI,EACJJ,aAAa,EACbC,OAAO,EACPC,SACF,CAAC;IAED,OAAO,MAAM;MACXO,UAAU,CAAC,CAAC;IACd,CAAC;EACH,CAAC,EAAE,CAACT,aAAa,EAAEE,SAAS,EAAED,OAAO,EAAEG,IAAI,EAAEL,iBAAiB,CAAC,CAAC;AAClE"}
1
+ {"version":3,"file":"usePanelRegistration.js","names":["React","usePanelRegistration","registerComponent","ComponentType","hydrate","dehydrate","_ComponentType$COMPON","name","COMPONENT","displayName","Error","useEffect","deregister"],"sources":["../../src/layout/usePanelRegistration.ts"],"sourcesContent":["import React from 'react';\nimport {\n type DashboardPanelProps,\n type DashboardPluginComponentProps,\n type PanelComponentType,\n type PanelDehydrateFunction,\n type PanelHydrateFunction,\n} from '../DashboardPlugin';\n\n/**\n * Registers a given panel component. Also runs a `useEffect` that will\n * automatically de-register then panel on unmount.\n * @param registerComponent\n * @param ComponentType\n * @param hydrate\n * @param dehydrate\n */\nexport default function usePanelRegistration<\n P extends DashboardPanelProps,\n C extends React.ComponentType<P>,\n>(\n registerComponent: DashboardPluginComponentProps['registerComponent'],\n ComponentType: PanelComponentType<P, C>,\n hydrate?: PanelHydrateFunction,\n dehydrate?: PanelDehydrateFunction\n): void {\n const name = ComponentType.COMPONENT ?? ComponentType.displayName;\n\n if (name == null) {\n throw new Error(\n 'ComponentType must have a `COMPONENT` or `displayName` attribute.'\n );\n }\n\n React.useEffect(() => {\n const deregister = registerComponent(\n name,\n ComponentType,\n hydrate,\n dehydrate\n );\n\n return () => {\n deregister();\n };\n }, [ComponentType, dehydrate, hydrate, name, registerComponent]);\n}\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AASzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,SAASC,oBAAoBA,CAI1CC,iBAAqE,EACrEC,aAAuC,EACvCC,OAA8B,EAC9BC,SAAkC,EAC5B;EAAA,IAAAC,qBAAA;EACN,IAAMC,IAAI,IAAAD,qBAAA,GAAGH,aAAa,CAACK,SAAS,cAAAF,qBAAA,cAAAA,qBAAA,GAAIH,aAAa,CAACM,WAAW;EAEjE,IAAIF,IAAI,IAAI,IAAI,EAAE;IAChB,MAAM,IAAIG,KAAK,CACb,mEACF,CAAC;EACH;EAEAV,KAAK,CAACW,SAAS,CAAC,MAAM;IACpB,IAAMC,UAAU,GAAGV,iBAAiB,CAClCK,IAAI,EACJJ,aAAa,EACbC,OAAO,EACPC,SACF,CAAC;IAED,OAAO,MAAM;MACXO,UAAU,CAAC,CAAC;IACd,CAAC;EACH,CAAC,EAAE,CAACT,aAAa,EAAEE,SAAS,EAAED,OAAO,EAAEG,IAAI,EAAEL,iBAAiB,CAAC,CAAC;AAClE","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"actionTypes.js","names":["SET_DASHBOARD_DATA"],"sources":["../../src/redux/actionTypes.ts"],"sourcesContent":["// eslint-disable-next-line import/prefer-default-export\nexport const SET_DASHBOARD_DATA = 'SET_DASHBOARD_DATA';\n"],"mappings":"AAAA;AACA,OAAO,IAAMA,kBAAkB,GAAG,oBAAoB"}
1
+ {"version":3,"file":"actionTypes.js","names":["SET_DASHBOARD_DATA"],"sources":["../../src/redux/actionTypes.ts"],"sourcesContent":["// eslint-disable-next-line import/prefer-default-export\nexport const SET_DASHBOARD_DATA = 'SET_DASHBOARD_DATA';\n"],"mappings":"AAAA;AACA,OAAO,IAAMA,kBAAkB,GAAG,oBAAoB","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"actions.js","names":["SET_DASHBOARD_DATA","getDashboardData","getPluginDataMapForDashboard","setDashboardData","id","data","type","payload","updateDashboardData","dispatch","getState","_objectSpread","setDashboardPluginData","pluginId","pluginDataMap"],"sources":["../../src/redux/actions.ts"],"sourcesContent":["import {\n type DashboardData,\n type PluginData,\n type RootState,\n} from '@deephaven/redux';\nimport type { Action } from 'redux';\nimport type { ThunkAction } from 'redux-thunk';\nimport { SET_DASHBOARD_DATA } from './actionTypes';\nimport { getDashboardData, getPluginDataMapForDashboard } from './selectors';\n\n/**\n * Action to replace the dashboard data for a dashboard\n * @param id The ID of the dashboard to set the data on\n * @param data Data for the dashboard\n * @returns The action to get dispatched\n */\nexport const setDashboardData = (\n id: string,\n data: DashboardData\n): {\n type: string;\n id: string;\n payload: DashboardData;\n} => ({\n type: SET_DASHBOARD_DATA,\n id,\n payload: data,\n});\n\n/**\n * Action to update the dashboard data. Will combine the update with any existing dashboard data.\n * @param id The id of the dashboard to update the data on\n * @param updateData The data to combine with the existing dashboard data\n * @returns\n */\nexport const updateDashboardData =\n (\n id: string,\n data: DashboardData\n ): ThunkAction<unknown, RootState, undefined, Action<unknown>> =>\n (dispatch, getState) =>\n dispatch(\n setDashboardData(id, {\n ...getDashboardData(getState(), id),\n ...data,\n })\n );\n\n/**\n * Action to set the dashboard plugin data.\n * Will replace any existing plugin data for the plugin in the dashboard with the data provided.\n * @param id The id of the dashboard to set the data on\n * @param pluginId The id of the plugin to set the data on\n * @param data The data to replace the existing plugin data with\n * @returns Thunk action to dispatch\n */\nexport const setDashboardPluginData =\n (\n id: string,\n pluginId: string,\n data: PluginData\n ): ThunkAction<unknown, RootState, undefined, Action<unknown>> =>\n (dispatch, getState) =>\n dispatch(\n setDashboardData(id, {\n ...getDashboardData(getState(), id),\n pluginDataMap: {\n ...getPluginDataMapForDashboard(getState(), id),\n [pluginId]: data,\n },\n })\n );\n"],"mappings":";;;;;SAOSA,kBAAkB;AAAA,SAClBC,gBAAgB,EAAEC,4BAA4B;AAEvD;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMC,gBAAgB,GAAGA,CAC9BC,EAAU,EACVC,IAAmB,MAKf;EACJC,IAAI,EAAEN,kBAAkB;EACxBI,EAAE;EACFG,OAAO,EAAEF;AACX,CAAC,CAAC;;AAEF;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMG,mBAAmB,GAC9BA,CACEJ,EAAU,EACVC,IAAmB,KAErB,CAACI,QAAQ,EAAEC,QAAQ,KACjBD,QAAQ,CACNN,gBAAgB,CAACC,EAAE,EAAAO,aAAA,CAAAA,aAAA,KACdV,gBAAgB,CAACS,QAAQ,CAAC,CAAC,EAAEN,EAAE,CAAC,GAChCC,IAAI,CACR,CACH,CAAC;;AAEL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMO,sBAAsB,GACjCA,CACER,EAAU,EACVS,QAAgB,EAChBR,IAAgB,KAElB,CAACI,QAAQ,EAAEC,QAAQ,KACjBD,QAAQ,CACNN,gBAAgB,CAACC,EAAE,EAAAO,aAAA,CAAAA,aAAA,KACdV,gBAAgB,CAACS,QAAQ,CAAC,CAAC,EAAEN,EAAE,CAAC;EACnCU,aAAa,EAAAH,aAAA,CAAAA,aAAA,KACRT,4BAA4B,CAACQ,QAAQ,CAAC,CAAC,EAAEN,EAAE,CAAC;IAC/C,CAACS,QAAQ,GAAGR;EAAI;AACjB,EACF,CACH,CAAC"}
1
+ {"version":3,"file":"actions.js","names":["SET_DASHBOARD_DATA","getDashboardData","getPluginDataMapForDashboard","setDashboardData","id","data","type","payload","updateDashboardData","dispatch","getState","_objectSpread","setDashboardPluginData","pluginId","pluginDataMap"],"sources":["../../src/redux/actions.ts"],"sourcesContent":["import {\n type DashboardData,\n type PluginData,\n type RootState,\n} from '@deephaven/redux';\nimport type { Action } from 'redux';\nimport type { ThunkAction } from 'redux-thunk';\nimport { SET_DASHBOARD_DATA } from './actionTypes';\nimport { getDashboardData, getPluginDataMapForDashboard } from './selectors';\n\n/**\n * Action to replace the dashboard data for a dashboard\n * @param id The ID of the dashboard to set the data on\n * @param data Data for the dashboard\n * @returns The action to get dispatched\n */\nexport const setDashboardData = (\n id: string,\n data: DashboardData\n): {\n type: string;\n id: string;\n payload: DashboardData;\n} => ({\n type: SET_DASHBOARD_DATA,\n id,\n payload: data,\n});\n\n/**\n * Action to update the dashboard data. Will combine the update with any existing dashboard data.\n * @param id The id of the dashboard to update the data on\n * @param updateData The data to combine with the existing dashboard data\n * @returns\n */\nexport const updateDashboardData =\n (\n id: string,\n data: DashboardData\n ): ThunkAction<unknown, RootState, undefined, Action<unknown>> =>\n (dispatch, getState) =>\n dispatch(\n setDashboardData(id, {\n ...getDashboardData(getState(), id),\n ...data,\n })\n );\n\n/**\n * Action to set the dashboard plugin data.\n * Will replace any existing plugin data for the plugin in the dashboard with the data provided.\n * @param id The id of the dashboard to set the data on\n * @param pluginId The id of the plugin to set the data on\n * @param data The data to replace the existing plugin data with\n * @returns Thunk action to dispatch\n */\nexport const setDashboardPluginData =\n (\n id: string,\n pluginId: string,\n data: PluginData\n ): ThunkAction<unknown, RootState, undefined, Action<unknown>> =>\n (dispatch, getState) =>\n dispatch(\n setDashboardData(id, {\n ...getDashboardData(getState(), id),\n pluginDataMap: {\n ...getPluginDataMapForDashboard(getState(), id),\n [pluginId]: data,\n },\n })\n );\n"],"mappings":";;;;;SAOSA,kBAAkB;AAAA,SAClBC,gBAAgB,EAAEC,4BAA4B;AAEvD;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMC,gBAAgB,GAAGA,CAC9BC,EAAU,EACVC,IAAmB,MAKf;EACJC,IAAI,EAAEN,kBAAkB;EACxBI,EAAE;EACFG,OAAO,EAAEF;AACX,CAAC,CAAC;;AAEF;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMG,mBAAmB,GAC9BA,CACEJ,EAAU,EACVC,IAAmB,KAErB,CAACI,QAAQ,EAAEC,QAAQ,KACjBD,QAAQ,CACNN,gBAAgB,CAACC,EAAE,EAAAO,aAAA,CAAAA,aAAA,KACdV,gBAAgB,CAACS,QAAQ,CAAC,CAAC,EAAEN,EAAE,CAAC,GAChCC,IAAI,CACR,CACH,CAAC;;AAEL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMO,sBAAsB,GACjCA,CACER,EAAU,EACVS,QAAgB,EAChBR,IAAgB,KAElB,CAACI,QAAQ,EAAEC,QAAQ,KACjBD,QAAQ,CACNN,gBAAgB,CAACC,EAAE,EAAAO,aAAA,CAAAA,aAAA,KACdV,gBAAgB,CAACS,QAAQ,CAAC,CAAC,EAAEN,EAAE,CAAC;EACnCU,aAAa,EAAAH,aAAA,CAAAA,aAAA,KACRT,4BAA4B,CAACQ,QAAQ,CAAC,CAAC,EAAEN,EAAE,CAAC;IAC/C,CAACS,QAAQ,GAAGR;EAAI;AACjB,EACF,CACH,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"hooks.js","names":["useCallback","useDispatch","useSelector","getPluginDataForDashboard","setDashboardPluginData","useDashboardPluginData","dashboardId","pluginId","dispatch","data","store","setData","newData"],"sources":["../../src/redux/hooks.ts"],"sourcesContent":["import { useCallback } from 'react';\nimport { useDispatch, useSelector } from 'react-redux';\nimport { type PluginData, type RootState } from '@deephaven/redux';\nimport { getPluginDataForDashboard } from './selectors';\nimport { setDashboardPluginData } from './actions';\n\n/**\n * Custom hook that provides access to plugin data for a specific dashboard and plugin.\n * @param dashboardId - The ID of the dashboard.\n * @param pluginId - The ID of the plugin.\n * @returns A tuple containing the plugin data and a function to update the plugin data.\n */\nexport function useDashboardPluginData<T = PluginData>(\n dashboardId: string,\n pluginId: string\n): [T, (data: T) => void] {\n const dispatch = useDispatch();\n const data = useSelector((store: RootState) =>\n getPluginDataForDashboard<T>(store, dashboardId, pluginId)\n );\n const setData = useCallback(\n (newData: T) =>\n dispatch(setDashboardPluginData(dashboardId, pluginId, newData)),\n [dashboardId, pluginId, dispatch]\n );\n return [data, setData];\n}\n\nexport default { useDashboardPluginData };\n"],"mappings":"AAAA,SAASA,WAAW,QAAQ,OAAO;AACnC,SAASC,WAAW,EAAEC,WAAW,QAAQ,aAAa;AAAC,SAE9CC,yBAAyB;AAAA,SACzBC,sBAAsB;AAE/B;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,sBAAsBA,CACpCC,WAAmB,EACnBC,QAAgB,EACQ;EACxB,IAAMC,QAAQ,GAAGP,WAAW,CAAC,CAAC;EAC9B,IAAMQ,IAAI,GAAGP,WAAW,CAAEQ,KAAgB,IACxCP,yBAAyB,CAAIO,KAAK,EAAEJ,WAAW,EAAEC,QAAQ,CAC3D,CAAC;EACD,IAAMI,OAAO,GAAGX,WAAW,CACxBY,OAAU,IACTJ,QAAQ,CAACJ,sBAAsB,CAACE,WAAW,EAAEC,QAAQ,EAAEK,OAAO,CAAC,CAAC,EAClE,CAACN,WAAW,EAAEC,QAAQ,EAAEC,QAAQ,CAClC,CAAC;EACD,OAAO,CAACC,IAAI,EAAEE,OAAO,CAAC;AACxB;AAEA,eAAe;EAAEN;AAAuB,CAAC"}
1
+ {"version":3,"file":"hooks.js","names":["useCallback","useDispatch","useSelector","getPluginDataForDashboard","setDashboardPluginData","useDashboardPluginData","dashboardId","pluginId","dispatch","data","store","setData","newData"],"sources":["../../src/redux/hooks.ts"],"sourcesContent":["import { useCallback } from 'react';\nimport { useDispatch, useSelector } from 'react-redux';\nimport { type PluginData, type RootState } from '@deephaven/redux';\nimport { getPluginDataForDashboard } from './selectors';\nimport { setDashboardPluginData } from './actions';\n\n/**\n * Custom hook that provides access to plugin data for a specific dashboard and plugin.\n * @param dashboardId - The ID of the dashboard.\n * @param pluginId - The ID of the plugin.\n * @returns A tuple containing the plugin data and a function to update the plugin data.\n */\nexport function useDashboardPluginData<T = PluginData>(\n dashboardId: string,\n pluginId: string\n): [T, (data: T) => void] {\n const dispatch = useDispatch();\n const data = useSelector((store: RootState) =>\n getPluginDataForDashboard<T>(store, dashboardId, pluginId)\n );\n const setData = useCallback(\n (newData: T) =>\n dispatch(setDashboardPluginData(dashboardId, pluginId, newData)),\n [dashboardId, pluginId, dispatch]\n );\n return [data, setData];\n}\n\nexport default { useDashboardPluginData };\n"],"mappings":"AAAA,SAASA,WAAW,QAAQ,OAAO;AACnC,SAASC,WAAW,EAAEC,WAAW,QAAQ,aAAa;AAAC,SAE9CC,yBAAyB;AAAA,SACzBC,sBAAsB;AAE/B;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,sBAAsBA,CACpCC,WAAmB,EACnBC,QAAgB,EACQ;EACxB,IAAMC,QAAQ,GAAGP,WAAW,CAAC,CAAC;EAC9B,IAAMQ,IAAI,GAAGP,WAAW,CAAEQ,KAAgB,IACxCP,yBAAyB,CAAIO,KAAK,EAAEJ,WAAW,EAAEC,QAAQ,CAC3D,CAAC;EACD,IAAMI,OAAO,GAAGX,WAAW,CACxBY,OAAU,IACTJ,QAAQ,CAACJ,sBAAsB,CAACE,WAAW,EAAEC,QAAQ,EAAEK,OAAO,CAAC,CAAC,EAClE,CAACN,WAAW,EAAEC,QAAQ,EAAEC,QAAQ,CAClC,CAAC;EACD,OAAO,CAACC,IAAI,EAAEE,OAAO,CAAC;AACxB;AAEA,eAAe;EAAEN;AAAuB,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["reducerRegistry","reducers","Object","entries","map","_ref","name","reducer","register"],"sources":["../../src/redux/index.ts"],"sourcesContent":["import { reducerRegistry } from '@deephaven/redux';\nimport reducers from './reducers';\n\nObject.entries(reducers).map(([name, reducer]) =>\n reducerRegistry.register(name, reducer)\n);\n\nexport { reducers };\nexport * from './actions';\nexport * from './actionTypes';\nexport * from './hooks';\nexport * from './selectors';\n"],"mappings":"AAAA,SAASA,eAAe,QAAQ,kBAAkB;AAAC,OAC5CC,QAAQ;AAEfC,MAAM,CAACC,OAAO,CAACF,QAAQ,CAAC,CAACG,GAAG,CAACC,IAAA;EAAA,IAAC,CAACC,IAAI,EAAEC,OAAO,CAAC,GAAAF,IAAA;EAAA,OAC3CL,eAAe,CAACQ,QAAQ,CAACF,IAAI,EAAEC,OAAO,CAAC;AAAA,CACzC,CAAC;AAED,SAASN,QAAQ;AAAG;AAAA;AAAA;AAAA"}
1
+ {"version":3,"file":"index.js","names":["reducerRegistry","reducers","Object","entries","map","_ref","name","reducer","register"],"sources":["../../src/redux/index.ts"],"sourcesContent":["import { reducerRegistry } from '@deephaven/redux';\nimport reducers from './reducers';\n\nObject.entries(reducers).map(([name, reducer]) =>\n reducerRegistry.register(name, reducer)\n);\n\nexport { reducers };\nexport * from './actions';\nexport * from './actionTypes';\nexport * from './hooks';\nexport * from './selectors';\n"],"mappings":"AAAA,SAASA,eAAe,QAAQ,kBAAkB;AAAC,OAC5CC,QAAQ;AAEfC,MAAM,CAACC,OAAO,CAACF,QAAQ,CAAC,CAACG,GAAG,CAACC,IAAA;EAAA,IAAC,CAACC,IAAI,EAAEC,OAAO,CAAC,GAAAF,IAAA;EAAA,OAC3CL,eAAe,CAACQ,QAAQ,CAACF,IAAI,EAAEC,OAAO,CAAC;AAAA,CACzC,CAAC;AAED,SAASN,QAAQ;AAAG;AAAA;AAAA;AAAA","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"dashboardData.js","names":["replaceByIdReducer","SET_DASHBOARD_DATA"],"sources":["../../../src/redux/reducers/dashboardData.ts"],"sourcesContent":["/**\n * Store information about input filters set in a dashboard\n */\nimport { replaceByIdReducer } from '@deephaven/redux';\nimport { SET_DASHBOARD_DATA } from '../actionTypes';\n\nexport default replaceByIdReducer(SET_DASHBOARD_DATA, {}, false);\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,kBAAkB,QAAQ,kBAAkB;AAAC,SAC7CC,kBAAkB;AAE3B,eAAeD,kBAAkB,CAACC,kBAAkB,EAAE,CAAC,CAAC,EAAE,KAAK,CAAC"}
1
+ {"version":3,"file":"dashboardData.js","names":["replaceByIdReducer","SET_DASHBOARD_DATA"],"sources":["../../../src/redux/reducers/dashboardData.ts"],"sourcesContent":["/**\n * Store information about input filters set in a dashboard\n */\nimport { replaceByIdReducer } from '@deephaven/redux';\nimport { SET_DASHBOARD_DATA } from '../actionTypes';\n\nexport default replaceByIdReducer(SET_DASHBOARD_DATA, {}, false);\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,kBAAkB,QAAQ,kBAAkB;AAAC,SAC7CC,kBAAkB;AAE3B,eAAeD,kBAAkB,CAACC,kBAAkB,EAAE,CAAC,CAAC,EAAE,KAAK,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["dashboardData"],"sources":["../../../src/redux/reducers/index.ts"],"sourcesContent":["import dashboardData from './dashboardData';\n\nexport default { dashboardData };\n"],"mappings":"OAAOA,aAAa;AAEpB,eAAe;EAAEA;AAAc,CAAC"}
1
+ {"version":3,"file":"index.js","names":["dashboardData"],"sources":["../../../src/redux/reducers/index.ts"],"sourcesContent":["import dashboardData from './dashboardData';\n\nexport default { dashboardData };\n"],"mappings":"OAAOA,aAAa;AAEpB,eAAe;EAAEA;AAAc,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"selectors.js","names":["useDispatch","useSelector","useStore","EMPTY_MAP","Map","EMPTY_OBJECT","Object","freeze","EMPTY_ARRAY","useAppDispatch","useAppSelector","useAppStore","getAllDashboardsData","store","dashboardData","getDashboardData","dashboardId","_getAllDashboardsData","getClosedPanelsForDashboard","_getDashboardData$clo","closed","getOpenedPanelMapForDashboard","_getDashboardData$ope","openedMap","getPluginDataMapForDashboard","_getDashboardData$plu","pluginDataMap","getPluginDataForDashboard","pluginId"],"sources":["../../src/redux/selectors.ts"],"sourcesContent":["import {\n type AppStore,\n type DashboardData,\n type PluginData,\n type PluginDataMap,\n type RootDispatch,\n type RootState,\n} from '@deephaven/redux';\nimport {\n type TypedUseSelectorHook,\n useDispatch,\n useSelector,\n useStore,\n} from 'react-redux';\nimport { type ClosedPanels, type OpenedPanelMap } from '../PanelManager';\n\nconst EMPTY_MAP = new Map();\n\nconst EMPTY_OBJECT = Object.freeze({});\n\nconst EMPTY_ARRAY = Object.freeze([]);\n\ntype Selector<R> = (state: RootState) => R;\n\n// https://react-redux.js.org/using-react-redux/usage-with-typescript#define-typed-hooks\n// Defined in @deephaven/dashboard, as that's the most common package with React and @deephaven/redux as dependencies\n// We could have another package specifically for this, but it's not really necessary.\nexport const useAppDispatch: () => RootDispatch = useDispatch;\nexport const useAppSelector: TypedUseSelectorHook<RootState> = useSelector;\nexport const useAppStore: () => AppStore = useStore;\n\n/**\n * Retrieve the data for all dashboards\n * @param store The redux store\n * @returns Property mapping dashboard ID to data for that dashboard\n */\nexport const getAllDashboardsData: Selector<\n Record<string, DashboardData>\n> = store => store.dashboardData;\n\n/**\n * @param store The redux store\n * @param dashboardId The dashboard ID to get data for\n * @returns The data object for the dashboard with the specified ID\n */\nexport const getDashboardData = (\n store: RootState,\n dashboardId: string\n): DashboardData => getAllDashboardsData(store)[dashboardId] ?? EMPTY_OBJECT;\n\n/**\n * @param store The redux store\n * @param dashboardId The dashboard ID to get data for\n * @returns The ClosedPanel array of panels that were previously closed/dehydrated\n */\nexport const getClosedPanelsForDashboard = (\n store: RootState,\n dashboardId: string\n): ClosedPanels =>\n (getDashboardData(store, dashboardId).closed ?? EMPTY_ARRAY) as ClosedPanels;\n\n/**\n * @param store The redux store\n * @param dashboardId The dashboard ID to get data for\n * @returns The map of panel IDs to components of all currently open components\n */\nexport const getOpenedPanelMapForDashboard = (\n store: RootState,\n dashboardId: string\n): OpenedPanelMap =>\n (getDashboardData(store, dashboardId).openedMap ??\n EMPTY_MAP) as OpenedPanelMap;\n\n/**\n * @param store The redux store\n * @param dashboardId The dashboard ID to get data for\n * @returns The map of plugin IDs to data for all plugins on the dashboard\n */\nexport const getPluginDataMapForDashboard = <T = PluginData>(\n store: RootState,\n dashboardId: string\n): PluginDataMap<T> =>\n getDashboardData(store, dashboardId).pluginDataMap ?? EMPTY_OBJECT;\n\n/**\n * @param store The redux store\n * @param dashboardId The dashboard ID to get data for\n * @param pluginId The plugin ID to get data for\n * @returns The plugin data\n */\nexport const getPluginDataForDashboard = <T = PluginData>(\n store: RootState,\n dashboardId: string,\n pluginId: string\n): T => getPluginDataMapForDashboard<T>(store, dashboardId)[pluginId];\n"],"mappings":"AAQA,SAEEA,WAAW,EACXC,WAAW,EACXC,QAAQ,QACH,aAAa;AAGpB,IAAMC,SAAS,GAAG,IAAIC,GAAG,CAAC,CAAC;AAE3B,IAAMC,YAAY,GAAGC,MAAM,CAACC,MAAM,CAAC,CAAC,CAAC,CAAC;AAEtC,IAAMC,WAAW,GAAGF,MAAM,CAACC,MAAM,CAAC,EAAE,CAAC;AAIrC;AACA;AACA;AACA,OAAO,IAAME,cAAkC,GAAGT,WAAW;AAC7D,OAAO,IAAMU,cAA+C,GAAGT,WAAW;AAC1E,OAAO,IAAMU,WAA2B,GAAGT,QAAQ;;AAEnD;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMU,oBAEZ,GAAGC,KAAK,IAAIA,KAAK,CAACC,aAAa;;AAEhC;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMC,gBAAgB,GAAGA,CAC9BF,KAAgB,EAChBG,WAAmB;EAAA,IAAAC,qBAAA;EAAA,QAAAA,qBAAA,GACDL,oBAAoB,CAACC,KAAK,CAAC,CAACG,WAAW,CAAC,cAAAC,qBAAA,cAAAA,qBAAA,GAAIZ,YAAY;AAAA;;AAE5E;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMa,2BAA2B,GAAGA,CACzCL,KAAgB,EAChBG,WAAmB;EAAA,IAAAG,qBAAA;EAAA,QAAAA,qBAAA,GAElBJ,gBAAgB,CAACF,KAAK,EAAEG,WAAW,CAAC,CAACI,MAAM,cAAAD,qBAAA,cAAAA,qBAAA,GAAIX,WAAW;AAAA,CAAiB;;AAE9E;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMa,6BAA6B,GAAGA,CAC3CR,KAAgB,EAChBG,WAAmB;EAAA,IAAAM,qBAAA;EAAA,QAAAA,qBAAA,GAElBP,gBAAgB,CAACF,KAAK,EAAEG,WAAW,CAAC,CAACO,SAAS,cAAAD,qBAAA,cAAAA,qBAAA,GAC7CnB,SAAS;AAAA,CAAmB;;AAEhC;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMqB,4BAA4B,GAAGA,CAC1CX,KAAgB,EAChBG,WAAmB;EAAA,IAAAS,qBAAA;EAAA,QAAAA,qBAAA,GAEnBV,gBAAgB,CAACF,KAAK,EAAEG,WAAW,CAAC,CAACU,aAAa,cAAAD,qBAAA,cAAAA,qBAAA,GAAIpB,YAAY;AAAA;;AAEpE;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMsB,yBAAyB,GAAGA,CACvCd,KAAgB,EAChBG,WAAmB,EACnBY,QAAgB,KACVJ,4BAA4B,CAAIX,KAAK,EAAEG,WAAW,CAAC,CAACY,QAAQ,CAAC"}
1
+ {"version":3,"file":"selectors.js","names":["useDispatch","useSelector","useStore","EMPTY_MAP","Map","EMPTY_OBJECT","Object","freeze","EMPTY_ARRAY","useAppDispatch","useAppSelector","useAppStore","getAllDashboardsData","store","dashboardData","getDashboardData","dashboardId","_getAllDashboardsData","getClosedPanelsForDashboard","_getDashboardData$clo","closed","getOpenedPanelMapForDashboard","_getDashboardData$ope","openedMap","getPluginDataMapForDashboard","_getDashboardData$plu","pluginDataMap","getPluginDataForDashboard","pluginId"],"sources":["../../src/redux/selectors.ts"],"sourcesContent":["import {\n type AppStore,\n type DashboardData,\n type PluginData,\n type PluginDataMap,\n type RootDispatch,\n type RootState,\n} from '@deephaven/redux';\nimport {\n type TypedUseSelectorHook,\n useDispatch,\n useSelector,\n useStore,\n} from 'react-redux';\nimport { type ClosedPanels, type OpenedPanelMap } from '../PanelManager';\n\nconst EMPTY_MAP = new Map();\n\nconst EMPTY_OBJECT = Object.freeze({});\n\nconst EMPTY_ARRAY = Object.freeze([]);\n\ntype Selector<R> = (state: RootState) => R;\n\n// https://react-redux.js.org/using-react-redux/usage-with-typescript#define-typed-hooks\n// Defined in @deephaven/dashboard, as that's the most common package with React and @deephaven/redux as dependencies\n// We could have another package specifically for this, but it's not really necessary.\nexport const useAppDispatch: () => RootDispatch = useDispatch;\nexport const useAppSelector: TypedUseSelectorHook<RootState> = useSelector;\nexport const useAppStore: () => AppStore = useStore;\n\n/**\n * Retrieve the data for all dashboards\n * @param store The redux store\n * @returns Property mapping dashboard ID to data for that dashboard\n */\nexport const getAllDashboardsData: Selector<\n Record<string, DashboardData>\n> = store => store.dashboardData;\n\n/**\n * @param store The redux store\n * @param dashboardId The dashboard ID to get data for\n * @returns The data object for the dashboard with the specified ID\n */\nexport const getDashboardData = (\n store: RootState,\n dashboardId: string\n): DashboardData => getAllDashboardsData(store)[dashboardId] ?? EMPTY_OBJECT;\n\n/**\n * @param store The redux store\n * @param dashboardId The dashboard ID to get data for\n * @returns The ClosedPanel array of panels that were previously closed/dehydrated\n */\nexport const getClosedPanelsForDashboard = (\n store: RootState,\n dashboardId: string\n): ClosedPanels =>\n (getDashboardData(store, dashboardId).closed ?? EMPTY_ARRAY) as ClosedPanels;\n\n/**\n * @param store The redux store\n * @param dashboardId The dashboard ID to get data for\n * @returns The map of panel IDs to components of all currently open components\n */\nexport const getOpenedPanelMapForDashboard = (\n store: RootState,\n dashboardId: string\n): OpenedPanelMap =>\n (getDashboardData(store, dashboardId).openedMap ??\n EMPTY_MAP) as OpenedPanelMap;\n\n/**\n * @param store The redux store\n * @param dashboardId The dashboard ID to get data for\n * @returns The map of plugin IDs to data for all plugins on the dashboard\n */\nexport const getPluginDataMapForDashboard = <T = PluginData>(\n store: RootState,\n dashboardId: string\n): PluginDataMap<T> =>\n getDashboardData(store, dashboardId).pluginDataMap ?? EMPTY_OBJECT;\n\n/**\n * @param store The redux store\n * @param dashboardId The dashboard ID to get data for\n * @param pluginId The plugin ID to get data for\n * @returns The plugin data\n */\nexport const getPluginDataForDashboard = <T = PluginData>(\n store: RootState,\n dashboardId: string,\n pluginId: string\n): T => getPluginDataMapForDashboard<T>(store, dashboardId)[pluginId];\n"],"mappings":"AAQA,SAEEA,WAAW,EACXC,WAAW,EACXC,QAAQ,QACH,aAAa;AAGpB,IAAMC,SAAS,GAAG,IAAIC,GAAG,CAAC,CAAC;AAE3B,IAAMC,YAAY,GAAGC,MAAM,CAACC,MAAM,CAAC,CAAC,CAAC,CAAC;AAEtC,IAAMC,WAAW,GAAGF,MAAM,CAACC,MAAM,CAAC,EAAE,CAAC;AAIrC;AACA;AACA;AACA,OAAO,IAAME,cAAkC,GAAGT,WAAW;AAC7D,OAAO,IAAMU,cAA+C,GAAGT,WAAW;AAC1E,OAAO,IAAMU,WAA2B,GAAGT,QAAQ;;AAEnD;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMU,oBAEZ,GAAGC,KAAK,IAAIA,KAAK,CAACC,aAAa;;AAEhC;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMC,gBAAgB,GAAGA,CAC9BF,KAAgB,EAChBG,WAAmB;EAAA,IAAAC,qBAAA;EAAA,QAAAA,qBAAA,GACDL,oBAAoB,CAACC,KAAK,CAAC,CAACG,WAAW,CAAC,cAAAC,qBAAA,cAAAA,qBAAA,GAAIZ,YAAY;AAAA;;AAE5E;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMa,2BAA2B,GAAGA,CACzCL,KAAgB,EAChBG,WAAmB;EAAA,IAAAG,qBAAA;EAAA,QAAAA,qBAAA,GAElBJ,gBAAgB,CAACF,KAAK,EAAEG,WAAW,CAAC,CAACI,MAAM,cAAAD,qBAAA,cAAAA,qBAAA,GAAIX,WAAW;AAAA,CAAiB;;AAE9E;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMa,6BAA6B,GAAGA,CAC3CR,KAAgB,EAChBG,WAAmB;EAAA,IAAAM,qBAAA;EAAA,QAAAA,qBAAA,GAElBP,gBAAgB,CAACF,KAAK,EAAEG,WAAW,CAAC,CAACO,SAAS,cAAAD,qBAAA,cAAAA,qBAAA,GAC7CnB,SAAS;AAAA,CAAmB;;AAEhC;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMqB,4BAA4B,GAAGA,CAC1CX,KAAgB,EAChBG,WAAmB;EAAA,IAAAS,qBAAA;EAAA,QAAAA,qBAAA,GAEnBV,gBAAgB,CAACF,KAAK,EAAEG,WAAW,CAAC,CAACU,aAAa,cAAAD,qBAAA,cAAAA,qBAAA,GAAIpB,YAAY;AAAA;;AAEpE;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,IAAMsB,yBAAyB,GAAGA,CACvCd,KAAgB,EAChBG,WAAmB,EACnBY,QAAgB,KACVJ,4BAA4B,CAAIX,KAAK,EAAEG,WAAW,CAAC,CAACY,QAAQ,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"useDashboardId.js","names":["createContext","useContext","DashboardIdContext","useDashboardId","dashboardId","Error"],"sources":["../src/useDashboardId.ts"],"sourcesContent":["import { createContext, useContext } from 'react';\n\nexport const DashboardIdContext = createContext<string | null>(null);\n\nexport function useDashboardId(): string {\n const dashboardId = useContext(DashboardIdContext);\n if (dashboardId == null) {\n throw new Error(\n 'useDashboardId must be used within a DashboardIdContext provider'\n );\n }\n return dashboardId;\n}\n"],"mappings":"AAAA,SAASA,aAAa,EAAEC,UAAU,QAAQ,OAAO;AAEjD,OAAO,IAAMC,kBAAkB,gBAAGF,aAAa,CAAgB,IAAI,CAAC;AAEpE,OAAO,SAASG,cAAcA,CAAA,EAAW;EACvC,IAAMC,WAAW,GAAGH,UAAU,CAACC,kBAAkB,CAAC;EAClD,IAAIE,WAAW,IAAI,IAAI,EAAE;IACvB,MAAM,IAAIC,KAAK,CACb,kEACF,CAAC;EACH;EACA,OAAOD,WAAW;AACpB"}
1
+ {"version":3,"file":"useDashboardId.js","names":["createContext","useContext","DashboardIdContext","useDashboardId","dashboardId","Error"],"sources":["../src/useDashboardId.ts"],"sourcesContent":["import { createContext, useContext } from 'react';\n\nexport const DashboardIdContext = createContext<string | null>(null);\n\nexport function useDashboardId(): string {\n const dashboardId = useContext(DashboardIdContext);\n if (dashboardId == null) {\n throw new Error(\n 'useDashboardId must be used within a DashboardIdContext provider'\n );\n }\n return dashboardId;\n}\n"],"mappings":"AAAA,SAASA,aAAa,EAAEC,UAAU,QAAQ,OAAO;AAEjD,OAAO,IAAMC,kBAAkB,gBAAGF,aAAa,CAAgB,IAAI,CAAC;AAEpE,OAAO,SAASG,cAAcA,CAAA,EAAW;EACvC,IAAMC,WAAW,GAAGH,UAAU,CAACC,kBAAkB,CAAC;EAClD,IAAIE,WAAW,IAAI,IAAI,EAAE;IACvB,MAAM,IAAIC,KAAK,CACb,kEACF,CAAC;EACH;EACA,OAAOD,WAAW;AACpB","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"useDhId.js","names":["Log","useFiber","usePanelId","log","module","DH_ID_PROP","useDhId","_ref","_useFiber","props","pendingProps","dhIdProp","panelId","Error","concat","warn"],"sources":["../src/useDhId.ts"],"sourcesContent":["import Log from '@deephaven/log';\nimport { useFiber } from './useFiber';\nimport { usePanelId } from './usePanelId';\n\nconst log = Log.module('useDhId');\n\nexport const DH_ID_PROP = '__dhId';\n\n/**\n * Gets the Deephaven ID of a component.\n * This is used to identify the component within a dashboard.\n * Usually this is just a panel ID, but in some contexts such as dh.ui,\n * it may be an ID for a component within a panel.\n *\n * Looks for a __dhId prop on the component, and if not found, looks in the PanelIdContext.\n * @param props The props of the component using this hook\n * @returns The Deephaven ID of the component or null if not found.\n */\nexport function useDhId(): string | null {\n // pendingProps are the props passed to the fiber node\n const props =\n (useFiber()?.pendingProps as Record<string, unknown> | undefined) ?? {};\n const dhIdProp = props[DH_ID_PROP];\n const panelId = usePanelId();\n\n if (dhIdProp != null) {\n if (typeof dhIdProp !== 'string') {\n throw new Error(\n `useDhId expected prop ${DH_ID_PROP} to be a string, but got ${typeof dhIdProp}`\n );\n }\n return dhIdProp;\n }\n\n if (panelId == null) {\n log.warn(\n `useDhId must be used within a PanelIdContext provider if there is no ${DH_ID_PROP} prop. Defaulting to null.`\n );\n return null;\n }\n\n return panelId;\n}\n"],"mappings":"AAAA,OAAOA,GAAG,MAAM,gBAAgB;AAAC,SACxBC,QAAQ;AAAA,SACRC,UAAU;AAEnB,IAAMC,GAAG,GAAGH,GAAG,CAACI,MAAM,CAAC,SAAS,CAAC;AAEjC,OAAO,IAAMC,UAAU,GAAG,QAAQ;;AAElC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,OAAOA,CAAA,EAAkB;EAAA,IAAAC,IAAA,EAAAC,SAAA;EACvC;EACA,IAAMC,KAAK,IAAAF,IAAA,IAAAC,SAAA,GACRP,QAAQ,CAAC,CAAC,cAAAO,SAAA,uBAAVA,SAAA,CAAYE,YAAY,cAAAH,IAAA,cAAAA,IAAA,GAA4C,CAAC,CAAC;EACzE,IAAMI,QAAQ,GAAGF,KAAK,CAACJ,UAAU,CAAC;EAClC,IAAMO,OAAO,GAAGV,UAAU,CAAC,CAAC;EAE5B,IAAIS,QAAQ,IAAI,IAAI,EAAE;IACpB,IAAI,OAAOA,QAAQ,KAAK,QAAQ,EAAE;MAChC,MAAM,IAAIE,KAAK,0BAAAC,MAAA,CACYT,UAAU,+BAAAS,MAAA,CAA4B,OAAOH,QAAQ,CAChF,CAAC;IACH;IACA,OAAOA,QAAQ;EACjB;EAEA,IAAIC,OAAO,IAAI,IAAI,EAAE;IACnBT,GAAG,CAACY,IAAI,yEAAAD,MAAA,CACkET,UAAU,+BACpF,CAAC;IACD,OAAO,IAAI;EACb;EAEA,OAAOO,OAAO;AAChB"}
1
+ {"version":3,"file":"useDhId.js","names":["Log","useFiber","usePanelId","log","module","DH_ID_PROP","useDhId","_ref","_useFiber","props","pendingProps","dhIdProp","panelId","Error","concat","warn"],"sources":["../src/useDhId.ts"],"sourcesContent":["import Log from '@deephaven/log';\nimport { useFiber } from './useFiber';\nimport { usePanelId } from './usePanelId';\n\nconst log = Log.module('useDhId');\n\nexport const DH_ID_PROP = '__dhId';\n\n/**\n * Gets the Deephaven ID of a component.\n * This is used to identify the component within a dashboard.\n * Usually this is just a panel ID, but in some contexts such as dh.ui,\n * it may be an ID for a component within a panel.\n *\n * Looks for a __dhId prop on the component, and if not found, looks in the PanelIdContext.\n * @param props The props of the component using this hook\n * @returns The Deephaven ID of the component or null if not found.\n */\nexport function useDhId(): string | null {\n // pendingProps are the props passed to the fiber node\n const props =\n (useFiber()?.pendingProps as Record<string, unknown> | undefined) ?? {};\n const dhIdProp = props[DH_ID_PROP];\n const panelId = usePanelId();\n\n if (dhIdProp != null) {\n if (typeof dhIdProp !== 'string') {\n throw new Error(\n `useDhId expected prop ${DH_ID_PROP} to be a string, but got ${typeof dhIdProp}`\n );\n }\n return dhIdProp;\n }\n\n if (panelId == null) {\n log.warn(\n `useDhId must be used within a PanelIdContext provider if there is no ${DH_ID_PROP} prop. Defaulting to null.`\n );\n return null;\n }\n\n return panelId;\n}\n"],"mappings":"AAAA,OAAOA,GAAG,MAAM,gBAAgB;AAAC,SACxBC,QAAQ;AAAA,SACRC,UAAU;AAEnB,IAAMC,GAAG,GAAGH,GAAG,CAACI,MAAM,CAAC,SAAS,CAAC;AAEjC,OAAO,IAAMC,UAAU,GAAG,QAAQ;;AAElC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,OAAOA,CAAA,EAAkB;EAAA,IAAAC,IAAA,EAAAC,SAAA;EACvC;EACA,IAAMC,KAAK,IAAAF,IAAA,IAAAC,SAAA,GACRP,QAAQ,CAAC,CAAC,cAAAO,SAAA,uBAAVA,SAAA,CAAYE,YAAY,cAAAH,IAAA,cAAAA,IAAA,GAA4C,CAAC,CAAC;EACzE,IAAMI,QAAQ,GAAGF,KAAK,CAACJ,UAAU,CAAC;EAClC,IAAMO,OAAO,GAAGV,UAAU,CAAC,CAAC;EAE5B,IAAIS,QAAQ,IAAI,IAAI,EAAE;IACpB,IAAI,OAAOA,QAAQ,KAAK,QAAQ,EAAE;MAChC,MAAM,IAAIE,KAAK,0BAAAC,MAAA,CACYT,UAAU,+BAAAS,MAAA,CAA4B,OAAOH,QAAQ,CAChF,CAAC;IACH;IACA,OAAOA,QAAQ;EACjB;EAEA,IAAIC,OAAO,IAAI,IAAI,EAAE;IACnBT,GAAG,CAACY,IAAI,yEAAAD,MAAA,CACkET,UAAU,+BACpF,CAAC;IACD,OAAO,IAAI;EACb;EAEA,OAAOO,OAAO;AAChB","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"useFiber.js","names":["nanoid","React","jsx","_jsx","traverseFiber","fiber","ascending","selector","child","return","match","sibling","wrapContext","context","Object","defineProperties","_currentRenderer","get","set","_currentRenderer2","_","FiberContext","createContext","FiberProvider","Component","constructor","arguments","_defineProperty","render","children","props","Provider","value","_reactInternals","useFiber","root","useContext","Error","id","useState","actualFiber","useMemo","maybeFiber","alternate","filter","r","node","state","memoizedState","next"],"sources":["../src/useFiber.tsx"],"sourcesContent":["/**\n * Adapted from https://www.npmjs.com/package/its-fine to support React 17.\n * The main change is using `nanoid` instead of `useId` which doesn't exist in React 17.\n * Also tweaked a bit of the code to match our style and removed the parts we don't use.\n */\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport { nanoid } from 'nanoid';\nimport * as React from 'react';\nimport type ReactReconciler from 'react-reconciler';\n\n/**\n * Represents a react-internal Fiber node.\n */\ntype Fiber<T = any> = Omit<ReactReconciler.Fiber, 'stateNode'> & {\n stateNode: T;\n};\n\n/**\n * Represents a {@link Fiber} node selector for traversal.\n */\ntype FiberSelector<T = any> = (\n /** The current {@link Fiber} node. */\n node: Fiber<T | null>\n) => boolean | void;\n\n/**\n * Traverses up or down a {@link Fiber}, return `true` to stop and select a node.\n */\nfunction traverseFiber<T = any>(\n /** Input {@link Fiber} to traverse. */\n fiber: Fiber | undefined,\n /** Whether to ascend and walk up the tree. Will walk down if `false`. */\n ascending: boolean,\n /** A {@link Fiber} node selector, returns the first match when `true` is passed. */\n selector: FiberSelector<T>\n): Fiber<T> | undefined {\n if (!fiber) {\n return;\n }\n if (selector(fiber) === true) {\n return fiber;\n }\n\n let child = ascending ? fiber.return : fiber.child;\n while (child) {\n const match = traverseFiber(child, ascending, selector);\n if (match) {\n return match;\n }\n\n child = ascending ? null : child.sibling;\n }\n}\n\n// In development, React will warn about using contexts between renderers.\n// Hide the warning because its-fine fixes this issue\n// https://github.com/facebook/react/pull/12779\nfunction wrapContext<T>(context: React.Context<T>): React.Context<T> {\n try {\n return Object.defineProperties(context, {\n _currentRenderer: {\n get() {\n return null;\n },\n set() {\n /* no-op */\n },\n },\n _currentRenderer2: {\n get() {\n return null;\n },\n set() {\n /* no-op */\n },\n },\n });\n } catch (_) {\n return context;\n }\n}\n\n// eslint-disable-next-line react-refresh/only-export-components\nconst FiberContext = /* @__PURE__ */ wrapContext(\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n /* @__PURE__ */ React.createContext<Fiber>(null!)\n);\n\n/**\n * A react-internal {@link Fiber} provider. This component binds React children to the React Fiber tree. Call its-fine hooks within this.\n */\nexport class FiberProvider extends React.Component<{\n children?: React.ReactNode;\n}> {\n private _reactInternals!: Fiber;\n\n render(): JSX.Element {\n const { children } = this.props;\n return (\n // eslint-disable-next-line no-underscore-dangle\n <FiberContext.Provider value={this._reactInternals}>\n {children}\n </FiberContext.Provider>\n );\n }\n}\n\n/**\n * Returns the current react-internal {@link Fiber}. This is an implementation detail of [react-reconciler](https://github.com/facebook/react/tree/main/packages/react-reconciler).\n */\nexport function useFiber(): Fiber<null> | undefined {\n const root = React.useContext(FiberContext);\n if (root === null) {\n throw new Error('useFiber must be called within a <FiberProvider />!');\n }\n\n const [id] = React.useState(() => nanoid());\n const actualFiber = React.useMemo(() => {\n // eslint-disable-next-line no-restricted-syntax\n for (const maybeFiber of [root, root?.alternate].filter(r => r != null)) {\n const fiber = traverseFiber<null>(maybeFiber, false, node => {\n let state = node.memoizedState;\n while (state != null) {\n if (state.memoizedState === id) {\n return true;\n }\n state = state.next;\n }\n });\n\n if (fiber) {\n return fiber;\n }\n }\n }, [root, id]);\n\n return actualFiber;\n}\n"],"mappings":"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"}
1
+ {"version":3,"file":"useFiber.js","names":["nanoid","React","jsx","_jsx","traverseFiber","fiber","ascending","selector","child","return","match","sibling","wrapContext","context","Object","defineProperties","_currentRenderer","get","set","_currentRenderer2","_","FiberContext","createContext","FiberProvider","Component","constructor","arguments","_defineProperty","render","children","props","Provider","value","_reactInternals","useFiber","root","useContext","Error","id","useState","actualFiber","useMemo","maybeFiber","alternate","filter","r","node","state","memoizedState","next"],"sources":["../src/useFiber.tsx"],"sourcesContent":["/**\n * Adapted from https://www.npmjs.com/package/its-fine to support React 17.\n * The main change is using `nanoid` instead of `useId` which doesn't exist in React 17.\n * Also tweaked a bit of the code to match our style and removed the parts we don't use.\n */\n/* eslint-disable @typescript-eslint/no-explicit-any */\nimport { nanoid } from 'nanoid';\nimport * as React from 'react';\nimport type ReactReconciler from 'react-reconciler';\n\n/**\n * Represents a react-internal Fiber node.\n */\ntype Fiber<T = any> = Omit<ReactReconciler.Fiber, 'stateNode'> & {\n stateNode: T;\n};\n\n/**\n * Represents a {@link Fiber} node selector for traversal.\n */\ntype FiberSelector<T = any> = (\n /** The current {@link Fiber} node. */\n node: Fiber<T | null>\n) => boolean | void;\n\n/**\n * Traverses up or down a {@link Fiber}, return `true` to stop and select a node.\n */\nfunction traverseFiber<T = any>(\n /** Input {@link Fiber} to traverse. */\n fiber: Fiber | undefined,\n /** Whether to ascend and walk up the tree. Will walk down if `false`. */\n ascending: boolean,\n /** A {@link Fiber} node selector, returns the first match when `true` is passed. */\n selector: FiberSelector<T>\n): Fiber<T> | undefined {\n if (!fiber) {\n return;\n }\n if (selector(fiber) === true) {\n return fiber;\n }\n\n let child = ascending ? fiber.return : fiber.child;\n while (child) {\n const match = traverseFiber(child, ascending, selector);\n if (match) {\n return match;\n }\n\n child = ascending ? null : child.sibling;\n }\n}\n\n// In development, React will warn about using contexts between renderers.\n// Hide the warning because its-fine fixes this issue\n// https://github.com/facebook/react/pull/12779\nfunction wrapContext<T>(context: React.Context<T>): React.Context<T> {\n try {\n return Object.defineProperties(context, {\n _currentRenderer: {\n get() {\n return null;\n },\n set() {\n /* no-op */\n },\n },\n _currentRenderer2: {\n get() {\n return null;\n },\n set() {\n /* no-op */\n },\n },\n });\n } catch (_) {\n return context;\n }\n}\n\n// eslint-disable-next-line react-refresh/only-export-components\nconst FiberContext = /* @__PURE__ */ wrapContext(\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n /* @__PURE__ */ React.createContext<Fiber>(null!)\n);\n\n/**\n * A react-internal {@link Fiber} provider. This component binds React children to the React Fiber tree. Call its-fine hooks within this.\n */\nexport class FiberProvider extends React.Component<{\n children?: React.ReactNode;\n}> {\n private _reactInternals!: Fiber;\n\n render(): JSX.Element {\n const { children } = this.props;\n return (\n // eslint-disable-next-line no-underscore-dangle\n <FiberContext.Provider value={this._reactInternals}>\n {children}\n </FiberContext.Provider>\n );\n }\n}\n\n/**\n * Returns the current react-internal {@link Fiber}. This is an implementation detail of [react-reconciler](https://github.com/facebook/react/tree/main/packages/react-reconciler).\n */\nexport function useFiber(): Fiber<null> | undefined {\n const root = React.useContext(FiberContext);\n if (root === null) {\n throw new Error('useFiber must be called within a <FiberProvider />!');\n }\n\n const [id] = React.useState(() => nanoid());\n const actualFiber = React.useMemo(() => {\n // eslint-disable-next-line no-restricted-syntax\n for (const maybeFiber of [root, root?.alternate].filter(r => r != null)) {\n const fiber = traverseFiber<null>(maybeFiber, false, node => {\n let state = node.memoizedState;\n while (state != null) {\n if (state.memoizedState === id) {\n return true;\n }\n state = state.next;\n }\n });\n\n if (fiber) {\n return fiber;\n }\n }\n }, [root, id]);\n\n return actualFiber;\n}\n"],"mappings":"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","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"usePanelId.js","names":["createContext","useContext","PanelIdContext","usePanelId"],"sources":["../src/usePanelId.ts"],"sourcesContent":["import { createContext, useContext } from 'react';\n\n/**\n * Context to provide the golden layout panel ID.\n */\nexport const PanelIdContext = createContext<string | null>(null);\n\n/**\n * Gets the current panel ID from the nearest context.\n * @returns The current panel ID from the context, or null if not set or there is no context.\n */\nexport function usePanelId(): string | null {\n return useContext(PanelIdContext);\n}\n"],"mappings":"AAAA,SAASA,aAAa,EAAEC,UAAU,QAAQ,OAAO;;AAEjD;AACA;AACA;AACA,OAAO,IAAMC,cAAc,gBAAGF,aAAa,CAAgB,IAAI,CAAC;;AAEhE;AACA;AACA;AACA;AACA,OAAO,SAASG,UAAUA,CAAA,EAAkB;EAC1C,OAAOF,UAAU,CAACC,cAAc,CAAC;AACnC"}
1
+ {"version":3,"file":"usePanelId.js","names":["createContext","useContext","PanelIdContext","usePanelId"],"sources":["../src/usePanelId.ts"],"sourcesContent":["import { createContext, useContext } from 'react';\n\n/**\n * Context to provide the golden layout panel ID.\n */\nexport const PanelIdContext = createContext<string | null>(null);\n\n/**\n * Gets the current panel ID from the nearest context.\n * @returns The current panel ID from the context, or null if not set or there is no context.\n */\nexport function usePanelId(): string | null {\n return useContext(PanelIdContext);\n}\n"],"mappings":"AAAA,SAASA,aAAa,EAAEC,UAAU,QAAQ,OAAO;;AAEjD;AACA;AACA;AACA,OAAO,IAAMC,cAAc,gBAAGF,aAAa,CAAgB,IAAI,CAAC;;AAEhE;AACA;AACA;AACA;AACA,OAAO,SAASG,UAAUA,CAAA,EAAkB;EAC1C,OAAOF,UAAU,CAACC,cAAc,CAAC;AACnC","ignoreList":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deephaven/dashboard",
3
- "version": "1.1.2-beta.0+0de18610",
3
+ "version": "1.1.2-beta.3+bc16dbd9",
4
4
  "description": "Deephaven Dashboard",
5
5
  "author": "Deephaven Data Labs LLC",
6
6
  "license": "Apache-2.0",
@@ -22,12 +22,12 @@
22
22
  "build:sass": "sass --embed-sources --load-path=../../node_modules ./src:./dist"
23
23
  },
24
24
  "dependencies": {
25
- "@deephaven/components": "^1.1.2-beta.0+0de18610",
26
- "@deephaven/golden-layout": "^1.1.2-beta.0+0de18610",
27
- "@deephaven/log": "^1.1.2-beta.0+0de18610",
28
- "@deephaven/react-hooks": "^1.1.2-beta.0+0de18610",
29
- "@deephaven/redux": "^1.1.2-beta.0+0de18610",
30
- "@deephaven/utils": "^1.1.2-beta.0+0de18610",
25
+ "@deephaven/components": "^1.1.2-beta.3+bc16dbd9",
26
+ "@deephaven/golden-layout": "^1.1.2-beta.3+bc16dbd9",
27
+ "@deephaven/log": "^1.1.2-beta.3+bc16dbd9",
28
+ "@deephaven/react-hooks": "^1.1.2-beta.3+bc16dbd9",
29
+ "@deephaven/redux": "^1.1.2-beta.3+bc16dbd9",
30
+ "@deephaven/utils": "^1.1.2-beta.3+bc16dbd9",
31
31
  "classnames": "^2.3.1",
32
32
  "fast-deep-equal": "^3.1.3",
33
33
  "lodash.ismatch": "^4.1.1",
@@ -42,8 +42,8 @@
42
42
  "react-redux": "^7.2.4"
43
43
  },
44
44
  "devDependencies": {
45
- "@deephaven/mocks": "^1.1.2-beta.0+0de18610",
46
- "@deephaven/test-utils": "^1.1.2-beta.0+0de18610",
45
+ "@deephaven/mocks": "^1.1.2-beta.3+bc16dbd9",
46
+ "@deephaven/test-utils": "^1.1.2-beta.3+bc16dbd9",
47
47
  "@types/lodash.ismatch": "^4.4.0",
48
48
  "@types/react-reconciler": "^0.32.0"
49
49
  },
@@ -53,5 +53,5 @@
53
53
  "publishConfig": {
54
54
  "access": "public"
55
55
  },
56
- "gitHead": "0de18610304cf9b6e013a89b4a4a43a7b7911534"
56
+ "gitHead": "bc16dbd92d3699185768571eaea38bec973d53f6"
57
57
  }