{"version":3,"sources":["webpack:///./Avensia.Common/Features/Shared/Blocks/AccordionBlock/AccordionBlock.tsx"],"names":["AccordionContent","div","margin","x","y","state","isOpen","toggleAccordion","setState","render","header","html","Div","className","hasLinks","onToggle","this","Component"],"mappings":"2FAAA,0EAkBMA,EAAmB,IAAOC,IAAI,CAClCC,OAAQ,CAAEC,EAAG,EAAGC,EAAG,UAGrB,yE,OACE,EAAAC,MAAQ,CACNC,QAAQ,GAGV,EAAAC,gBAAkB,WAChB,EAAKC,SAAS,CACZF,QAAS,EAAKD,MAAMC,U,EAsB1B,OA7B4C,iBAW1C,YAAAG,OAAA,WACQ,iBAAEC,EAAA,EAAAA,OAAQC,EAAA,EAAAA,KAChB,OACE,kBAAC,IAAQ,KACP,kBAAC,IAAOC,IAAG,CAACC,UAAU,QACpB,kBAAC,IAAOD,IAAG,CAACC,UAAW,YAAkB,GAAI,EAAG,YAA2B,KACzE,kBAAC,IAAS,CAACH,OAAQA,EAAQI,UAAU,EAAOC,SAAUC,KAAKT,gBAAiBD,OAAQU,KAAKX,MAAMC,QAC7F,kBAACN,EAAgB,CAACa,UAAU,kBAC1B,kBAAC,IAAOD,IAAG,CAACC,UAAW,YAAkB,GAAI,IAC1CF,GAAQ,kBAAC,UAAI,CAACA,KAAMA,EAAKA,cAS5C,EA7BA,CAA4C,IAAMM,W","file":"assets/50.chunk.058b239c0d8d13ccc526.js","sourcesContent":["/**\r\n * @ComponentFor AccordionBlockViewModel\r\n */\r\n\r\nimport React from 'react';\r\nimport { styled } from '@glitz/react';\r\nimport Accordion from 'Shared/Accordion';\r\nimport Html from 'Shared/Partials/PropertyTypes/Html';\r\nimport AccordionBlockViewModel from './AccordionBlockViewModel.type';\r\nimport { createGridClasses, createOffsetGridClassLarge } from 'Shared/grid';\r\nimport { GridWrap } from 'Shared/PageLayout';\r\n\r\ntype PropType = AccordionBlockViewModel;\r\n\r\ntype StateType = {\r\n  isOpen: boolean;\r\n};\r\n\r\nconst AccordionContent = styled.div({\r\n  margin: { x: 0, y: '32px' },\r\n});\r\n\r\nexport default class AccordionBlock extends React.Component<PropType, StateType> {\r\n  state = {\r\n    isOpen: false,\r\n  };\r\n\r\n  toggleAccordion = () => {\r\n    this.setState({\r\n      isOpen: !this.state.isOpen,\r\n    });\r\n  };\r\n\r\n  render() {\r\n    const { header, html } = this.props;\r\n    return (\r\n      <GridWrap>\r\n        <styled.Div className=\"grid\">\r\n          <styled.Div className={createGridClasses(12, 7, createOffsetGridClassLarge(2))}>\r\n            <Accordion header={header} hasLinks={false} onToggle={this.toggleAccordion} isOpen={this.state.isOpen}>\r\n              <AccordionContent className=\"grid subgrid-7\">\r\n                <styled.Div className={createGridClasses(12, 5)}>\r\n                  {html && <Html html={html.html} />}\r\n                </styled.Div>\r\n              </AccordionContent>\r\n            </Accordion>\r\n          </styled.Div>\r\n        </styled.Div>\r\n      </GridWrap>\r\n    );\r\n  }\r\n}\r\n"],"sourceRoot":""}