/** * WordPress dependencies */ import { SocialNetworkName } from '@nelio-content/types'; import { Toolbar, ToolbarButton } from '@safe-wordpress/components'; import { _x } from '@safe-wordpress/i18n'; export type Tab = 'publication' | 'reshare'; export type TabSelectorProps = { readonly className?: string; readonly network: SocialNetworkName; readonly tab: Tab; readonly setTab: ( tab: Tab ) => void; }; export const TabSelector = ( { className, network, tab, setTab, }: TabSelectorProps ): JSX.Element => ( setTab( 'publication' ) } /> { network !== 'webhook' && ( setTab( 'reshare' ) } /> ) } );