import * as React from 'react' ; import Sticky from 'react-stickynode' ; import { IFormSection } from '@client/forms' ; import styled from '@client/styledComponents' ; import { FormTabs } from '@client/components/form' ; import { injectIntl , WrappedComponentProps as IntlShapeProps } from 'react-intl' ; const StickyFormTabsContainer = styled . div `
  div.sticky-inner-wrapper {
    ${ ( { theme } ) => theme . gradients . gradientNightshade };
  }
` ; interface IStickyFormTabProps { sections : IFormSection [ ] ; activeTabId : string ; onTabClick : ( tabId : string ) => void ; } function StickyFormTabsComponent ( { sections , activeTabId , onTabClick } ) { return ( < StickyFormTabsContainer id = "form_tabs_container" > < Sticky enabled = { true } innerZ = { 2 } > < FormTabs sections = { sections } activeTabId = { activeTabId } onTabClick = { onTabClick } / > < /Sticky> < /StickyFormTabsContainer>); } export const StickyFormTabs = injectIntl ( StickyFormTabsComponent ) ;