File tree Expand file tree Collapse file tree 2 files changed +5
-11
lines changed
src/app/components/StateRoute Expand file tree Collapse file tree 2 files changed +5
-11
lines changed Original file line number Diff line number Diff line change @@ -19,21 +19,15 @@ import LinkControls from './LinkControls';
1919import getLinkComponent from './getLinkComponent' ;
2020import { toggleExpanded , setCurrentTabInApp } from '../../../actions/actions' ;
2121import { useStoreContext } from '../../../store' ;
22+ import { LinkTypesProps , DefaultMargin , ToolTipStyles } from '../../../components/FrontendTypes'
2223
23- const defaultMargin : { } = {
24+ const defaultMargin : DefaultMargin = {
2425 top : 30 ,
2526 left : 30 ,
2627 right : 55 ,
2728 bottom : 70 ,
2829} ;
2930
30- export type LinkTypesProps = {
31- width : number ;
32- height : number ;
33- margin ?: { top : number ; right : number ; bottom : number ; left : number } ;
34- snapshots : Record < string , unknown > ;
35- currentSnapshot ?: Record < string , unknown > ;
36- } ;
3731
3832export default function ComponentMap ( {
3933 // imported props to be used to display the dendrogram
@@ -95,7 +89,7 @@ export default function ComponentMap({
9589 scroll : true ,
9690 } ) ;
9791
98- const tooltipStyles : { } = {
92+ const tooltipStyles : ToolTipStyles = {
9993 ...defaultStyles ,
10094 minWidth : 60 ,
10195 maxWidth : 300 ,
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ const StateRoute = (props: StateRouteProps) => {
2727 const { hierarchy, sliderIndex, viewIndex } = tabs [ currentTab ] ;
2828
2929 // Map
30- const renderComponentMap = ( ) : JSX . Element => {
30+ const renderComponentMap = ( ) => {
3131 if ( hierarchy ) {
3232 return (
3333 < ParentSize className = 'componentMapContainer' >
@@ -50,7 +50,7 @@ const StateRoute = (props: StateRouteProps) => {
5050 // if true, we invoke the D3 render chart with hierarchy
5151 // by invoking History component, and passing in all the props required to render D3 elements and perform timeJump from clicking of node
5252 // otherwise we send an alert to the user that no state was found.
53- const renderHistory = ( ) : JSX . Element => {
53+ const renderHistory : JSX . Element = ( ) => {
5454 if ( hierarchy ) {
5555 return (
5656 < ParentSize >
You can’t perform that action at this time.
0 commit comments