import React from 'react'; import { DISPLAY_MODE, PeriodicElement } from '../../periodic-element/periodic-element.component'; import { TABLE_DICO_V2 } from '../../periodic-table-data/table-v2'; import { useDetailedElement } from '../../periodic-table-state/table-store'; // Ultimately, we'll allow people to pass a specific component by using render props // the goal is to allow people to insert whatever you want there interface Props { plugin?: JSX.Element; disabled?: boolean; } export const PeriodicTableSpacer: React.FC = (props) => { const detailedElement = useDetailedElement(); let pluginComponent = props.plugin; if (props.disabled || !props.plugin) { pluginComponent = ( <>
); } return ( {/*
{showSwitcher &&
}
{!disabled && (selectorWidget)}
*/} {pluginComponent}
{detailedElement && (
); };