Sha256: ce312cd21367fc783afe9f6981519fcfdd34dcff23940cff7138e2ba6171e7a6

Contents?: true

Size: 772 Bytes

Versions: 6

Compression:

Stored size: 772 Bytes

Contents

/* @flow */

import React from 'react'
import classNames from 'classnames'

import styles from './flyout_panel.scss'

type FlyoutPanelProps = {|
  className: ?string,
  position: "left" | "right",
  show: ?boolean,
  children: string,
|}

const FlyoutPanel = ({ position, show, children, className }: FlyoutPanelProps) => {
  const positionClass = position == "right" ? styles.right : styles.left
  const classes = classNames(
    styles['flyout-panel'],
    positionClass,
    className,
    "col-md-5",
    show ? styles.open : null
  )
  const scrollClasses = classNames(styles['scroll-inner-box'], 'p-5', 'pt-2')
  return (
    <div className={classes}>
      <div className={scrollClasses}>
        {children}
      </div>
    </div>
  )
}

export default FlyoutPanel

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
playbook_ui-2.7.2 components/FlyoutPanel/FlyoutPanel.jsx
playbook_ui-2.7.1 components/FlyoutPanel/FlyoutPanel.jsx
playbook_ui-2.7.0 components/FlyoutPanel/FlyoutPanel.jsx
playbook_ui-2.6.0 components/FlyoutPanel/FlyoutPanel.jsx
playbook_ui-2.5.0 components/FlyoutPanel/FlyoutPanel.jsx
nitro_sg-3.0.2 components/FlyoutPanel/FlyoutPanel.jsx