import { Meta , Story } from '@storybook/react' ; import { DataSection } from './DataSection' ; import { IDataProps } from './DataRow' ; import React from 'react' ; interface IProps { id ? : string ; title : string ; items : IDataProps [ ] ; responsiveContents ? : React . ReactNode ; } export default { title : 'Components/Interface/ViewData/DataSection' , component : DataSection } as Meta ; const Template = ( args ) => < DataSection { ... args } / > ; export const DataSectionView = Template . bind ( { } ) ; DataSectionView . args = { title : 'Section Title' , items : [ { label : 'Name' , value : 'Atiq Zaman' , action : { label : 'Change' , disabled : true } } , { label : 'Phone Number' , value : '+880xxxxxx' , action : { label : 'Change' , handler : ( ) => alert ( 'Change your phone number' ) } } ] } ;