- Add flush to remove the default background-color, some borders,
- and some rounded corners to render Accordions edge-to-edge with their parent container.
-
-
-
-
-
- {AccordionFlushExampleSource}
-
-
- Uncontrolled
-
-
-
-
-
- { UncontrolledAccordionExampleSource }
-
-
-
- Stay Open
-
- Add the stayOpen prop to make accordion items stay open when another item is opened.
-
- );
- }
-}
diff --git a/docs/lib/Components/AlertsPage.js b/docs/lib/Components/AlertsPage.js
deleted file mode 100644
index 805811a60..000000000
--- a/docs/lib/Components/AlertsPage.js
+++ /dev/null
@@ -1,117 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import { Alert } from 'reactstrap';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-
-import AlertExample from '../examples/Alert';
-const AlertExampleSource = require('!!raw-loader!../examples/Alert');
-
-import AlertLinkExample from '../examples/AlertLink';
-const AlertLinkExampleSource = require('!!raw-loader!../examples/AlertLink');
-
-import AlertContentExample from '../examples/AlertContent';
-const AlertContentExampleSource = require('!!raw-loader!../examples/AlertContent');
-
-import AlertDismissExample from '../examples/AlertDismiss';
-const AlertDismissExampleSource = require('!!raw-loader!../examples/AlertDismiss');
-
-import AlertUncontrolledDismissExample from '../examples/AlertUncontrolledDismiss';
-const AlertUncontrolledDismissExampleSource = require('!!raw-loader!../examples/AlertUncontrolledDismiss');
-
-import {AlertFadelessExample, UncontrolledAlertFadelessExample} from '../examples/AlertFadeless';
-const AlertFadelessExampleSource = require('!!raw-loader!../examples/AlertFadeless');
-
-export default class AlertsPage extends React.Component {
- render() {
- return (
-
-
-
-
-
-
-
- {AlertExampleSource}
-
-
-
- Properties
-
-
-{`Alert.propTypes = {
- className: PropTypes.string,
- closeClassName: PropTypes.string,
- color: PropTypes.string, // default: 'success'
- isOpen: PropTypes.bool, // default: true
- toggle: PropTypes.func,
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- fade: PropTypes.bool, // default: true
- // Controls the transition of the alert fading in and out
- // See [Fade](/components/fade/) for more details
- transition: PropTypes.shape(Fade.propTypes),
-}`}
-
-
-
- Link color
-
-
-
-
-
- {AlertLinkExampleSource}
-
-
-
- Additional content
-
-
-
-
-
- {AlertContentExampleSource}
-
-
-
- Dismissing
-
-
-
-
-
- {AlertDismissExampleSource}
-
-
-
- Uncontrolled [disable] Alerts
-
- For the most basic use-case an uncontrolled component can provide the functionality wanted without the need to manage/control the state of the component. UncontrolledAlert does not require isOpen nor toggle props to work.
-
-
-
-
-
-
- {AlertUncontrolledDismissExampleSource}
-
-
-
- Alerts without fade
-
- Fade can be disabled using fade=false.
-
-
-
-
-
-
-
- {AlertFadelessExampleSource}
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/BadgePage.js b/docs/lib/Components/BadgePage.js
deleted file mode 100644
index b0e0f11e7..000000000
--- a/docs/lib/Components/BadgePage.js
+++ /dev/null
@@ -1,77 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-
-import BadgeExample from '../examples/Badge';
-const BadgeExampleSource = require('!!raw-loader!../examples/Badge');
-
-import BadgeButtonExample from '../examples/BadgeButton';
-const BadgeButtonExampleSource = require('!!raw-loader!../examples/BadgeButton');
-
-import BadgePillsExample from '../examples/BadgePills';
-const BadgePillsExampleSource = require('!!raw-loader!../examples/BadgePills');
-
-import BadgeVariationsExample from '../examples/BadgeVariations';
-const BadgeVariationsExampleSource = require('!!raw-loader!../examples/BadgeVariations');
-
-import BadgeLinksExample from '../examples/BadgeLinks';
-const BadgeLinksExampleSource = require('!!raw-loader!../examples/BadgeLinks');
-
-export default class BadgesPage extends React.Component {
- render() {
- return (
-
-
-
-
Scale to parent
-
-
-
-
-
- {BadgeExampleSource}
-
-
-
Badges can be used as part of links or buttons to provide a counter.
-
-
-
-
-
- {BadgeButtonExampleSource}
-
-
- Contextual variations
-
-
-
-
-
- {BadgeVariationsExampleSource}
-
-
- Pills
-
-
-
-
-
- {BadgePillsExampleSource}
-
-
- Links
-
Adding the href prop (without specifying a tag prop) will default the badge to a link.
- );
- }
-}
diff --git a/docs/lib/Components/ButtonsPage.js b/docs/lib/Components/ButtonsPage.js
deleted file mode 100644
index 5032395f1..000000000
--- a/docs/lib/Components/ButtonsPage.js
+++ /dev/null
@@ -1,184 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import { Button } from 'reactstrap';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-import ButtonExample from '../examples/Button';
-const ButtonExampleSource = require('!!raw-loader!../examples/Button');
-
-import ButtonOutline from '../examples/ButtonOutline';
-const ButtonOutlineSource = require('!!raw-loader!../examples/ButtonOutline');
-
-import ButtonStateful from '../examples/ButtonStateful';
-const ButtonStatefulSource = require('!!raw-loader!../examples/ButtonStateful');
-
-import ButtonCloseIcon from '../examples/ButtonCloseIcon';
-const ButtonCloseIconSource = require('!!raw-loader!../examples/ButtonCloseIcon');
-
-import ButtonToggle from '../examples/ButtonToggle';
-const ButtonToggleSource = require('!!raw-loader!../examples/ButtonToggle');
-
-export default class ButtonsPage extends React.Component {
- render() {
- return (
-
-
-
-
-
-
-
- {ButtonExampleSource}
-
-
-
Properties
-
-
-{`Button.propTypes = {
- active: PropTypes.bool,
- 'aria-label': PropTypes.string,
- block: PropTypes.bool,
- color: PropTypes.string, // default: 'secondary'
- disabled: PropTypes.bool,
- outline: PropTypes.bool,
-
- // Pass in a Component to override default button element
- // example: react-router Link
- // default: 'button'
- tag: PropTypes.oneOfType([
- PropTypes.func,
- PropTypes.string,
- PropTypes.shape({ $$typeof: PropTypes.symbol, render: PropTypes.func }),
- PropTypes.arrayOf(PropTypes.oneOfType([
- PropTypes.func,
- PropTypes.string,
- PropTypes.shape({ $$typeof: PropTypes.symbol, render: PropTypes.func }),
- ]))
- ]),
-
- // ref will only get you a reference to the Button component, use innerRef to get a reference to the DOM element (for things like focus management).
- innerRef: PropTypes.oneOfType([PropTypes.object, PropTypes.func, PropTypes.string]),
-
- onClick: PropTypes.func,
- size: PropTypes.string,
- children: PropTypes.node,
- className: PropTypes.string,
- cssModule: PropTypes.object,
-
- // use close prop for BS4 close icon utility
- close: PropTypes.bool,
-}
-
-Button.defaultProps = {
- color: 'secondary',
- tag: 'button',
-}`}
-
-
- Outline Buttons
-
-
-
-
-
- {ButtonOutlineSource}
-
-
- Sizes
-
- {' '}
-
-
-
-
-{`{' '}
-`}
-
-
-
- {' '}
-
-
-
-
-{`{' '}
-`}
-
-
-
-
-
-
-
-
-{`
-`}
-
-
- Active State
-
- {' '}
-
-
-
-
-{`{' '}
-`}
-
-
- Disabled State
-
- {' '}
-
-
-
-
-{`{' '}
-`}
-
-
-
- Checkbox and Radio Buttons (Stateful Buttons)
-
- In order to have checkbox and radio buttons, your component needs to manage the state of which button(s) are active/select. It is not in the opinion of this library to manage state within it's components so it is left up to you. Below is a simple example showcasing how this could be done using the components which already exist in this library.
-
-
-
-
-
-
- {ButtonStatefulSource}
-
-
-
- Close icon
-
- Use a generic close icon to dismiss content. Use <Button close /> for the default icon. Otherwise, custom content for the button
- may be defined. (e.g. JSX: <Button close><span aria-hidden="true">–</span></Button>) The default aria-label is "Close".
-
-
-
-
-
-
- {ButtonCloseIconSource}
-
-
-
- Button Toggle
-
- Button toggle state
-
-
-
-
-
-
- {ButtonToggleSource}
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/CardPage.js b/docs/lib/Components/CardPage.js
deleted file mode 100644
index 220e6554b..000000000
--- a/docs/lib/Components/CardPage.js
+++ /dev/null
@@ -1,239 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-
-import CardExample from '../examples/Card';
-import CardContentExample from '../examples/CardContentTypes';
-import CardSizingExample from '../examples/CardSizing';
-import CardAlignmentExample from '../examples/CardAlignment';
-import CardHeaderFooterExample from '../examples/CardHeaderFooter';
-import CardImageCapsExample from '../examples/CardImageCaps';
-import CardImageOverlayExample from '../examples/CardImageOverlay';
-import CardBackgroundsExample from '../examples/CardBackgrounds';
-import CardOutlineExample from '../examples/CardOutline';
-import CardGroupsExample from '../examples/CardGroups';
-import CardDecksExample from '../examples/CardDecks';
-import CardColumnsExample from '../examples/CardColumns';
-
-const CardExampleSource = require('!!raw-loader!../examples/Card');
-const CardContentExampleSource = require('!!raw-loader!../examples/CardContentTypes');
-const CardSizingExampleSource = require('!!raw-loader!../examples/CardSizing');
-const CardAlignmentExampleSource = require('!!raw-loader!../examples/CardAlignment');
-const CardHeaderFooterExampleSource = require('!!raw-loader!../examples/CardHeaderFooter');
-const CardImageCapsExampleSource = require('!!raw-loader!../examples/CardImageCaps');
-const CardImageOverlayExampleSource = require('!!raw-loader!../examples/CardImageOverlay');
-const CardBackgroundsExampleSource = require('!!raw-loader!../examples/CardBackgrounds');
-const CardOutlineExampleSource = require('!!raw-loader!../examples/CardOutline');
-const CardGroupsExampleSource = require('!!raw-loader!../examples/CardGroups');
-const CardDecksExampleSource = require('!!raw-loader!../examples/CardDecks');
-const CardColumnsExampleSource = require('!!raw-loader!../examples/CardColumns');
-
-export default class CardPage extends React.Component {
- render() {
- return (
-
-
-
-
-
-
-
-
- {CardExampleSource}
-
-
-
Properties
-
-
-{`Card.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- inverse: PropTypes.bool,
- color: PropTypes.string,
- body: PropTypes.bool,
- className: PropTypes.string
-};
-
-CardBody.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string
-};
-
-CardColumns.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string
-};
-
-CardDeck.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string
-};
-
-CardFooter.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string
-};
-
-CardGroup.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string
-};
-
-CardHeader.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string
-};
-
-CardImg.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string,
- // Use top or bottom to position image via "card-img-top" or "card-img-bottom"
- top: PropTypes.bool,
- bottom: PropTypes.bool
-};
-
-CardImgOverlay.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string
-};
-
-CardLink.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string,
- // ref will only get you a reference to the CardLink component, use innerRef to get a reference to the DOM element (for things like focus management).
- innerRef: PropTypes.oneOfType([PropTypes.func, PropTypes.string])
-};
-
-CardSubtitle.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string
-};
-
-CardText.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string
-};
-
-CardTitle.propTypes = {
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- className: PropTypes.string
-};`}
-
-
- Content Types
-
-
-
-
-
- {CardContentExampleSource}
-
-
- Sizing
-
-
-
-
-
- {CardSizingExampleSource}
-
-
- Text alignment
-
-
-
-
-
- {CardAlignmentExampleSource}
-
-
- Header and Footer
-
-
-
-
-
- {CardHeaderFooterExampleSource}
-
-
- Image caps
-
-
-
-
-
- {CardImageCapsExampleSource}
-
-
- Image overlays
-
-
-
-
-
- {CardImageOverlayExampleSource}
-
-
- Background variants
-
-
-
-
-
- {CardBackgroundsExampleSource}
-
-
- Outline variants
-
-
-
-
-
- {CardOutlineExampleSource}
-
-
- Groups
-
-
-
-
-
- {CardGroupsExampleSource}
-
-
- Decks
-
-
-
-
-
- {CardDecksExampleSource}
-
-
- Columns
-
-
-
-
-
- {CardColumnsExampleSource}
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/CarouselPage.js b/docs/lib/Components/CarouselPage.js
deleted file mode 100644
index 2c972a1ca..000000000
--- a/docs/lib/Components/CarouselPage.js
+++ /dev/null
@@ -1,158 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-import CarouselExample from '../examples/Carousel';
-const CarouselExampleSource = require('!!raw-loader!../examples/Carousel');
-import CarouselUncontrolledExample from '../examples/CarouselUncontrolled';
-const CarouselUncontrolledExampleSource = require('!!raw-loader!../examples/CarouselUncontrolled');
-import CarouselCustomTagExample from '../examples/CarouselCustomTag';
-const CarouselCustomTagExampleSource = require('!!raw-loader!../examples/CarouselCustomTag');
-
-export default class CarouselPage extends React.Component {
- render() {
- return (
-
-
-
-
-
-
-
- {CarouselExampleSource}
-
-
-
- Carousel Properties
-
-
-{`Carousel.propTypes = {
- // the current active slide of the carousel
- activeIndex: PropTypes.number,
- // a function which should advance the carousel to the next slide (via activeIndex)
- next: PropTypes.func.isRequired,
- // a function which should advance the carousel to the previous slide (via activeIndex)
- previous: PropTypes.func.isRequired,
- // controls if the left and right arrow keys should control the carousel
- keyboard: PropTypes.bool,
- /* If set to "hover", pauses the cycling of the carousel on mouseenter and resumes the cycling of the carousel on
- * mouseleave. If set to false, hovering over the carousel won't pause it. (default: "hover")
- */
- pause: PropTypes.oneOf(['hover', false]),
- // Autoplays the carousel after the user manually cycles the first item. If "carousel", autoplays the carousel on load.
- // This is how bootstrap defines it... I would prefer a bool named autoplay or something...
- ride: PropTypes.oneOf(['carousel']),
- // the interval at which the carousel automatically cycles (default: 5000)
- // If set to false, carousel will not Autoplay (i.e. will not automatically cycle).
- interval: PropTypes.oneOfType([
- PropTypes.number,
- PropTypes.string,
- PropTypes.bool,
- ]),
- children: PropTypes.array,
- // called when the mouse enters the Carousel
- mouseEnter: PropTypes.func,
- // called when the mouse exits the Carousel
- mouseLeave: PropTypes.func,
- // controls whether the slide animation on the Carousel works or not
- slide: PropTypes.bool,
- // make the controls, indicators and captions dark on the Carousel
- dark: PropTypes.bool,
- cssModule: PropTypes.object,
- // controls whether the touch gestures on the Carousel works or not (default: true)
- enableTouch: PropTypes.bool,
-};`}
-
-
- For the most basic use-case an uncontrolled component can provide the functionality wanted without the need to manage/control the state of the component. UncontrolledCarousel does not require previous, next nor activeIndex props to work.
- Anything provided to a normal Carousel can also be provided to UncontrolledCarousel, overriding the control UncontrolledCarousel provides. Additionally, you can hide the controls by passing false to the controls prop
- and you can disable the indicators by passing false to the indicators prop; both are visible by default. Autoplay (ride="carousel") is enabled by default, you can disable it by passing false to the autoPlay prop.
-
-
-
-
-
-
- {CarouselUncontrolledExampleSource}
-
-
-
- Uncontrolled Carousel Properties
-
Same as Carousel (except children) can be overridden plus the following
- Collapse is wrapped in a Transition component
- from react-transition-group/transition. Transition props are passed through to
- this wrapper. Refer to the Transition documentation for details:
- http://reactcommunity.org/react-transition-group/transition/.
-
-
- Horizontal
-
-
-
-
- {CollapseHorizontalExampleSource}
-
-
- Events
-
- Use the onEnter, onEntering, onEntered, onExiting and onExited props for
- callbacks when the Collapse has finished opening (entering) or closing (exiting).
-
-
-
-
-
- {CollapseEventsExampleSource}
-
- Uncontrolled Collapse
-
- For the most basic use-case, an uncontrolled component can provide the functionality
- wanted without the need to manage/control the state of the component.{' '}
- UncontrolledCollapse does not require an isOpen prop. Instead
- pass a toggler prop. The toggler prop is a string which will run
- querySelectorAll to find dom elements which will trigger toggle. The defaultOpen
- prop controls the initial state.
-
- The Dropdown component is used to pass the isOpen & toggle props via context to the following components: DropdownToggle, DropdownMenu. The DropdownToggle uses the Button component internally, meaning it also accepts all the props the Button component accepts.
-
-
-
-
-
-
- {DropdownExampleSource}
-
-
-
Properties
-
-
-{`Dropdown.propTypes = {
- a11y: PropTypes.bool, // defaults to true. Set to false to enable more bootstrap like tabbing behavior
- className: PropTypes.string,
- disabled: PropTypes.bool,
- direction: PropTypes.oneOf(['up', 'down', 'start', 'end']),
- group: PropTypes.bool,
- isOpen: PropTypes.bool,
- // For Dropdown usage inside a Nav
- nav: PropTypes.bool,
- active: PropTypes.bool,
- // For Dropdown usage inside a Navbar (disables popper)
- inNavbar: PropTypes.bool,
- tag: PropTypes.string, // default: 'div' unless nav=true, then 'li'
- toggle: PropTypes.func,
- setActiveFromChild: PropTypes.bool
-};
-
-DropdownToggle.propTypes = {
- caret: PropTypes.bool,
- color: PropTypes.string,
- className: PropTypes.string,
- disabled: PropTypes.bool,
- onClick: PropTypes.func,
- 'data-toggle': PropTypes.string,
- 'aria-haspopup': PropTypes.bool,
- // For DropdownToggle usage inside a Nav
- nav: PropTypes.bool,
- // Defaults to Button component
- tag: PropTypes.any
-};
-
-DropdownMenu.propTypes = {
- tag: PropTypes.string,
- children: PropTypes.node.isRequired,
- dark: PropTypes.bool,
- end: PropTypes.bool,
- flip: PropTypes.bool, // default: true,
- className: PropTypes.string,
- cssModule: PropTypes.object,
- // Custom modifiers that are passed to Popper.js, see https://popper.js.org/docs/v2/modifiers/
- modifiers: PropTypes.array,
- persist: PropTypes.bool, // presist the popper, even when closed. See #779 for reasoning
- // passed to popper, see https://popper.js.org/docs/v2/constructors/#strategy
- strategy: PropTypes.string,
- // Element to place the menu in. Used to show the menu as a child of 'body'
- // or other elements in the DOM instead of where it naturally is. This can be
- // used to make the Dropdown escape a container with overflow: hidden
- container: PropTypes.oneOfType([PropTypes.string, PropTypes.func, DOMElement]),
-};
-
-DropdownItem.propTypes = {
- children: PropTypes.node,
- active: PropTypes.bool,
- disabled: PropTypes.bool,
- divider: PropTypes.bool,
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- header: PropTypes.bool,
- onClick: PropTypes.func,
- className: PropTypes.string,
- cssModule: PropTypes.object,
- toggle: PropTypes.bool, // default: true
- text: PropTypes.bool
-};`}
-
-
- Alignment
-
To align the DropdownMenu to the right, add a right prop to Dropdown.
-
-
-
-
- Dropdown's menu is right-aligned
-
-
- Header
- Action
- Another Action
-
- Another Really Really Long Action (Really!)
-
-
-
-
-
-
-{`
-
- Dropdown's menu is right-aligned
-
-
- Header
- Action
- Another Action
-
- Another Really Really Long Action (Really!)
-
-`}
-
-
- Dark dropdowns
-
To opt into darker DropdownMenu to match a dark Navbar, add a dark prop to DropdownMenu.
-
-
-
-
- Dropdown's menu is dark
-
-
- Header
- Active Action
- Another Action
-
-
-
-
-
-
-{`
-
- Dropdown's menu is dark
-
-
- Header
- Active Action
- Another Action
-
-`}
-
-
- For the most basic use-case an uncontrolled component can provide the functionality wanted without the need to manage/control the state of the component. UncontrolledDropdown does not require isOpen nor toggle props to work. For the ButtonDropdown flavor, an uncontrolled component have been made as well; UncontrolledButtonDropdown.
-
-
-{`
-
- Dropup
-
-
- Another Action
- Another Action
-
-
-
- { this.setState({ btnDropleft: !this.state.btnDropleft }); }}>
-
- Dropleft
-
-
- Another Action
- Another Action
-
-
-
- { this.setState({ btnDropright: !this.state.btnDropright }); }}>
-
- Dropright
-
-
- Another Action
- Another Action
-
-`}
-
-
-
- Modifiers
-
-
-
- { this.setState({ ddModifiers: !this.state.ddModifiers }); }}
- >
-
- Dropdown
-
- {
- return {
- ...data,
- styles: {
- ...data.styles,
- overflow: 'auto',
- maxHeight: '100px',
- },
- };
- },
- },
- }}
- >
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
-
-
-
-
-
-
-
-{`
-
- Dropdown
-
- {
- return {
- ...data,
- styles: {
- ...data.styles,
- overflow: 'auto',
- maxHeight: '100px',
- },
- };
- },
- },
- }}
- >
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
- Another Action
-
-`}
-
-
-
- setActiveFromChild
-
- Use setActiveFromChild prop to automatically set the dropdown to active when any of the dropdown menu items are active. Note: this prop will not work in conjunction with react-router Link and activeClassName.
-
-
-
-
-
-
- {DropdownSetActiveFromChildSource}
-
-
-
- container
-
- Use the container prop to allow the dropdown menu to be placed inside an alternate container through a React Portal. This can be used to allow the dropdown menu to escape a container with the style overflow: hidden.
-
-
-
-
-
-
- {DropdownContainerSource}
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/FadePage.js b/docs/lib/Components/FadePage.js
deleted file mode 100644
index 15cd5c4e4..000000000
--- a/docs/lib/Components/FadePage.js
+++ /dev/null
@@ -1,76 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import { Alert } from 'reactstrap';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-
-import FadeExample from '../examples/Fade';
-const FadeExampleSource = require('!!raw-loader!../examples/Fade');
-
-export default class FadePage extends React.Component {
- render() {
- return (
-
-
-
-
-
-
-
- {FadeExampleSource}
-
-
-
- Properties
-
-
-{`Fade.propTypes = {
- // Controls if the fade is currently showing or not (default: true)
- in: PropTypes.bool,
-
- // All of these match [react-transition-group/Transition](https://reactcommunity.org/react-transition-group/#Transition) props
- mountOnEnter: PropTypes.bool,
- unmountOnExit: PropTypes.bool,
- appear: PropTypes.bool, // (default: true)
- enter: PropTypes.bool, // (default: true)
- exit: PropTypes.bool, // (default: true)
- timeout: PropTypes.oneOfType([ // (default: 150)
- PropTypes.number,
- PropTypes.shape({
- enter: PropTypes.number,
- exit: PropTypes.number,
- }).isRequired,
- ]),
- addEndListener: PropTypes.func,
- onEnter: PropTypes.func,
- onEntering: PropTypes.func,
- onEntered: PropTypes.func,
- onExit: PropTypes.func,
- onExiting: PropTypes.func,
- onExited: PropTypes.func,
-
- // The component(s) that should be faded
- children: PropTypes.oneOfType([
- PropTypes.arrayOf(PropTypes.node),
- PropTypes.node
- ]),
- // Pass in a component or primitive component name to override the default element
- // (default: 'div')
- tag: PropTypes.oneOfType([PropTypes.string, PropTypes.func]),
- // Class always applied to the Fade element (default: 'fade')
- baseClass: PropTypes.string,
- // Class applied to transition the Fade element in (default: 'show')
- baseClassActive: PropTypes.string,
- // Other classes that should always be applied
- className: PropTypes.string,
- cssModule: PropTypes.object,
-
- // Any other props provided will be applied to the element created (specified by tag)
-}`}
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/FormPage.js b/docs/lib/Components/FormPage.js
deleted file mode 100644
index 24ad36686..000000000
--- a/docs/lib/Components/FormPage.js
+++ /dev/null
@@ -1,213 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-
-import FormExample from '../examples/Form';
-const FormExampleSource = require('!!raw-loader!../examples/Form');
-
-import FormGridExample from '../examples/FormGrid';
-const FormGridExampleSource = require('!!raw-loader!../examples/FormGrid');
-
-import FormGridFormRowExample from '../examples/FormGridFormRow';
-const FormGridFormRowExampleSource = require('!!raw-loader!../examples/FormGridFormRow');
-
-import FormInlineExample from '../examples/FormInline';
-const FormInlineExampleSource = require('!!raw-loader!../examples/FormInline');
-
-import FormFeedbackExample from '../examples/FormFeedback';
-const FormFeedbackExampleSource = require('!!raw-loader!../examples/FormFeedback');
-
-import InputTypeExample from '../examples/InputType';
-const InputTypeExampleSource = require('!!raw-loader!../examples/InputType');
-
-import InlineCheckboxesExample from '../examples/InlineCheckboxes';
-const InlineCheckboxesExampleSource = require('!!raw-loader!../examples/InlineCheckboxes');
-
-import InputSizingExample from '../examples/InputSizing';
-const InputSizingExampleSource = require('!!raw-loader!../examples/InputSizing');
-
-import InputGridSizingExample from '../examples/InputGridSizing';
-const InputGridSizingExampleSource = require('!!raw-loader!../examples/InputGridSizing');
-
-import LabelHiddenExample from '../examples/LabelHidden';
-const LabelHiddenExampleSource = require('!!raw-loader!../examples/LabelHidden');
-
-export default class FormPage extends React.Component {
- render() {
- return (
-
-
-
-
-
-
-
- {FormExampleSource}
-
-
-
- Properties
-
-
-{`Input.propTypes = {
- children: PropTypes.node,
- // type can be things like text, password, (typical input types) as well as select and textarea, providing children as you normally would to those.
- type: PropTypes.string,
- size: PropTypes.string,
- bsSize: PropTypes.string,
- state: deprecated(PropTypes.string, 'Please use the prop "valid"'),
- valid: PropTypes.bool, // applied the is-valid class when true, does nothing when false
- invalid: PropTypes.bool, // applied the is-invalid class when true, does nothing when false
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- // ref will only get you a reference to the Input component, use innerRef to get a reference to the DOM input (for things like focus management).
- innerRef: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- static: deprecated(PropTypes.bool, 'Please use the prop "plaintext"'),
- plaintext: PropTypes.bool,
- addon: PropTypes.bool,
- className: PropTypes.string,
- cssModule: PropTypes.object,
-};
-
-Form.propTypes = {
- children: PropTypes.node,
- inline: PropTypes.bool,
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]), // default: 'form'
- innerRef: PropTypes.oneOfType([PropTypes.object, PropTypes.func, PropTypes.string]),
- className: PropTypes.string,
- cssModule: PropTypes.object,
-};
-
-FormFeedback.propTypes = {
- children: PropTypes.node,
- // Pass in a Component to override default element
- tag: PropTypes.string, // default: 'div'
- className: PropTypes.string,
- cssModule: PropTypes.object,
- valid: PropTypes.bool, // default: undefined
- // The parent element must contain the 'position: relative' style to work
- tooltip: PropTypes.bool
-};
-
-FormGroup.propTypes = {
- children: PropTypes.node,
- // Applied the row class when true, does nothing when false
- row: PropTypes.bool,
- // Applied the form-check class when true, mb-3 when false
- check: PropTypes.bool,
- inline: PropTypes.bool,
- // Applied the disabled class when the check and disabled props are true, does nothing when false
- disabled: PropTypes.bool,
- // Pass in a Component to override default element
- tag: PropTypes.string, // default: 'div'
- className: PropTypes.string,
- cssModule: PropTypes.object,
-};
-
-FormText.propTypes = {
- children: PropTypes.node,
- inline: PropTypes.bool,
- // Pass in a Component to override default element
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]), // default: 'small'
- color: PropTypes.string, // default: 'muted'
- className: PropTypes.string,
- cssModule: PropTypes.object,
-};`}
-
-
-
-{`InputGroup.propTypes = {
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- size: PropTypes.string,
- className: PropTypes.string
-};
-
-InputGroupButton.propTypes = {
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- addonType: PropTypes.oneOf(['prepend', 'append']).isRequired,
- children: PropTypes.node,
- groupClassName: PropTypes.string, // only used in shorthand
- groupAttributes: PropTypes.object, // only used in shorthand
- className: PropTypes.string
-};`}
-
-
- Addons
-
-
-
-
-
-
-
- {AddonExampleSource}
-
-
-
- Input Group Sizing
-
-
-
-
-
-
-
- {AddonSizingExampleSource}
-
-
-
- Buttons / Dropdowns
-
-
-
-
-
-
-
- {ButtonExampleSource}
-
-
-
- Button Shorthand (DEPRECATED)
-
- Button shorthand is deprecated. Below are the updated examples of how to use InputGroupAddon to
- accomplish the same output.
-
-
- Button shorthand is a convenience method for adding just a button. It is triggered when only a single string
- is the child. A Button will be created and all of the props will be passed to it with the exception of
- groupClassName and groupAttributes, which are used to added classes and attributes
- to the wrapping container. This means you can add your onClick and other handlers directly to
- InputGroupButton. If you want your string to not be wrapped in a button, then you really want to
- use InputGroupAddon (see Addons above for that).
-
-
-
-
-
-
-
-
- {ButtonShorthandExampleSource}
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/LayoutPage.js b/docs/lib/Components/LayoutPage.js
deleted file mode 100644
index 402bc9b4f..000000000
--- a/docs/lib/Components/LayoutPage.js
+++ /dev/null
@@ -1,105 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-import LayoutExample from '../examples/Layout';
-import LayoutRowColsExample from '../examples/LayoutRowCols';
-import ContainerResponsiveExample from '../examples/ContainerResponsive';
-
-const LayoutExampleSource = require('!!raw-loader!../examples/Layout');
-const LayoutRowColsExampleSource = require('!!raw-loader!../examples/LayoutRowCols');
-const ContainerResponsiveExampleSource = require('!!raw-loader!../examples/ContainerResponsive');
-
-export default class LayoutsPage extends React.Component {
- render() {
- return (
-
-
-
-
-
-
-
- {LayoutExampleSource}
-
-
-
Container Properties
-
-
-{`Container.propTypes = {
- fluid: PropTypes.oneOfType([PropTypes.bool, PropTypes.string])
- // applies .container-fluid class if bool or .container-{breakpoint} if string
-}`}
-
-
-
-{`const stringOrNumberProp = PropTypes.oneOfType([PropTypes.number, PropTypes.string]);
-const columnProps = PropTypes.oneOfType([
- PropTypes.string,
- PropTypes.number,
- PropTypes.bool,
- PropTypes.shape({
- size: PropTypes.oneOfType([PropTypes.bool, PropTypes.number, PropTypes.string]),
- // example size values:
- // 12 || "12" => col-12 or col-\`width\`-12
- // auto => col-auto or col-\`width\`-auto
- // true => col or col-\`width\`
- order: stringOrNumberProp,
- offset: stringOrNumberProp
- })
-]);
-
-Col.propTypes = {
- xs: columnProps,
- sm: columnProps,
- md: columnProps,
- lg: columnProps,
- xl: columnProps,
- xxl: columnProps,
- // override the predefined width (the ones above) with your own custom widths.
- // see https://github.com/reactstrap/reactstrap/issues/297#issuecomment-273556116
- widths: PropTypes.array,
-}`}
-
-
-
Container
-
-
-
-
-
- {ContainerResponsiveExampleSource}
-
-
-
Row Columns
-
-
-
-
-
- {LayoutRowColsExampleSource}
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/ListGroupPage.js b/docs/lib/Components/ListGroupPage.js
deleted file mode 100644
index bdd21b9ed..000000000
--- a/docs/lib/Components/ListGroupPage.js
+++ /dev/null
@@ -1,139 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-import ListGroupExample from '../examples/ListGroup';
-import ListGroupBadgeExample from '../examples/ListGroupBadge';
-import ListGroupDisabledItemsExample from '../examples/ListGroupDisabledItems';
-import ListGroupAnchorsAndButtonsExample from '../examples/ListGroupAnchorsAndButtons';
-import ListGroupContextualClassesExample from '../examples/ListGroupContextualClasses';
-import ListGroupCustomContentExample from '../examples/ListGroupCustomContent';
-import ListGroupFlushExample from '../examples/ListGroupFlush';
-import ListGroupHorizontalExample from '../examples/ListGroupHorizontal';
-import ListGroupNumberedExample from '../examples/ListGroupNumbered';
-
-const ListGroupBadgeExampleSource = require('!!raw-loader!../examples/ListGroupBadge');
-const ListGroupExampleSource = require('!!raw-loader!../examples/ListGroup');
-const ListGroupDisabledItemsExampleSource = require('!!raw-loader!../examples/ListGroupDisabledItems');
-const ListGroupAnchorsAndButtonsExampleSource = require('!!raw-loader!../examples/ListGroupAnchorsAndButtons');
-const ListGroupContextualClassesExampleSource = require('!!raw-loader!../examples/ListGroupContextualClasses');
-const ListGroupCustomContentExampleSource = require('!!raw-loader!../examples/ListGroupCustomContent');
-const ListGroupFlushExampleSource = require('!!raw-loader!../examples/ListGroupFlush')
-const ListGroupHorizontalExampleSource = require("!!raw-loader!../examples/ListGroupHorizontal");
-const ListGroupNumberedExampleSource = require("!!raw-loader!../examples/ListGroupNumbered");
-
-export default class ListGroupPage extends React.Component {
- render() {
- return (
-
-
-
-
-
-
-
- {ListGroupExampleSource}
-
-
-
Properties
-
-
-{
- `ListGroup.propTypes = {
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- // boolean to render list group items edge-to-edge in a parent container
- flush: PropTypes.bool,
- // boolean to render list group items horizontal. string for specific breakpoint, or true to be always horizontal
- horizontal: PropTypes.oneOfType([PropTypes.bool, PropTypes.string]),
- className: PropTypes.string,
- cssModule: PropTypes.object,
- }`
- }
-
-
-
-
-
-
-
-
-
- {ListGroupBadgeExampleSource}
-
-
-
-
-
-
-
-
-
- {ListGroupDisabledItemsExampleSource}
-
-
-
-
-
-
Note: you need add action props to make these buttons fit the list.
-
-
-
-
- {ListGroupAnchorsAndButtonsExampleSource}
-
-
-
-
-
-
-
-
-
- {ListGroupContextualClassesExampleSource}
-
-
-
-
-
-
-
-
-
- {ListGroupCustomContentExampleSource}
-
-
-
-
-
-
-
-
-
- {ListGroupFlushExampleSource}
-
-
-
-
-
-
-
-
-
- {ListGroupHorizontalExampleSource}
-
-
-
-
-
-
-
-
-
- {ListGroupNumberedExampleSource}
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/ListPage.js b/docs/lib/Components/ListPage.js
deleted file mode 100644
index b8f391fb4..000000000
--- a/docs/lib/Components/ListPage.js
+++ /dev/null
@@ -1,62 +0,0 @@
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import PageTitle from '../UI/PageTitle';
-import ListInlineExample from '../examples/ListInline';
-import ListUnstyledExample from '../examples/ListUnstyled';
-
-const ListInlineExampleSource = require('!!raw-loader!../examples/ListInline');
-const ListUnstyledExampleSource = require('!!raw-loader!../examples/ListUnstyled');
-
-export default class ListPage extends React.Component {
- render() {
- return (
-
- );
- }
-}
diff --git a/docs/lib/Components/ModalsPage.js b/docs/lib/Components/ModalsPage.js
deleted file mode 100644
index 4d6d63e77..000000000
--- a/docs/lib/Components/ModalsPage.js
+++ /dev/null
@@ -1,280 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-
-import PageTitle from '../UI/PageTitle';
-import ModalExample from '../examples/Modal';
-import ModalBackdropExample from '../examples/ModalBackdrop';
-import ModalNestedExample from '../examples/ModalNested';
-import ModalCustomTimeoutExample from '../examples/ModalCustomTimeout';
-import ModalFadelessExample from '../examples/ModalFadeless';
-import ModalFullscreenExample from '../examples/ModalFullscreen';
-import ModalExternalExample from '../examples/ModalExternal';
-import ModalCustomCloseIconExample from '../examples/ModalCustomCloseIcon';
-import ModalCustomCloseButtonExample from '../examples/ModalCustomCloseButton';
-import ModalDestructuringExample from '../examples/ModalDestructuring';
-import ModalFocusAfterClose from '../examples/ModalFocusAfterClose';
-
-const ModalBackdropExampleSource = require('!!raw-loader!../examples/ModalBackdrop');
-const ModalCustomCloseButtonExampleSource = require('!!raw-loader!../examples/ModalCustomCloseButton');
-const ModalCustomCloseIconExampleSource = require('!!raw-loader!../examples/ModalCustomCloseIcon');
-const ModalCustomTimeoutExampleSource = require('!!raw-loader!../examples/ModalCustomTimeout');
-const ModalExampleSource = require('!!raw-loader!../examples/Modal');
-const ModalExternalExampleSource = require('!!raw-loader!../examples/ModalExternal');
-const ModalFadelessExampleSource = require('!!raw-loader!../examples/ModalFadeless');
-const ModalFullscreenExampleSource = require('!!raw-loader!../examples/ModalFullscreen');
-
-const ModalNestedExampleSource = require('!!raw-loader!../examples/ModalNested');
-const ModalDestructuringExampleSource = require('!!raw-loader!../examples/ModalDestructuring');
-const ModalFocusOnDestroyExampleSource = require('!!raw-loader!../examples/ModalFocusAfterClose');
-
-const ModalsPage = () => {
- return (
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {ModalExampleSource}
-
-
-
Properties
-
-
- {`Modal.propTypes = {
- // boolean to control the state of the popover
- isOpen: PropTypes.bool,
- autoFocus: PropTypes.bool,
- // if modal should be centered vertically in viewport
- centered: PropTypes.bool,
- // if modal should be fullscreen
- fullscreen: PropTypes.oneOfType([
- PropTypes.bool, // always fullscreen
- PropTypes.oneOf(['sm', 'md', 'lg', 'xl']), // fullscreen below breakpoints
- ]),
- // corresponds to bootstrap's modal sizes, ie. 'lg' or 'sm'
- size: PropTypes.string,
- // callback for toggling isOpen in the controlling component
- toggle: PropTypes.func,
- role: PropTypes.string, // defaults to "dialog"
- // used to reference the ID of the title element in the modal
- labelledBy: PropTypes.string,
- keyboard: PropTypes.bool,
- // control backdrop, see http://v4-alpha.getbootstrap.com/components/modal/#options
- backdrop: PropTypes.oneOfType([
- PropTypes.bool,
- PropTypes.oneOf(['static'])
- ]),
- // if body of modal should be scrollable when content is long
- scrollable: PropTypes.bool,
- // allows for a node/component to exist next to the modal (outside of it). Useful for external close buttons
- external: PropTypes.node,
- // called on componentDidMount
- onEnter: PropTypes.func,
- // called on componentWillUnmount
- onExit: PropTypes.func,
- // called when done transitioning in
- onOpened: PropTypes.func,
- // called when done transitioning out
- onClosed: PropTypes.func,
- className: PropTypes.string,
- wrapClassName: PropTypes.string,
- modalClassName: PropTypes.string,
- backdropClassName: PropTypes.string,
- contentClassName: PropTypes.string,
- // boolean to control whether the fade transition occurs (default: true)
- fade: PropTypes.bool,
- cssModule: PropTypes.object,
- // zIndex defaults to 1000.
- zIndex: PropTypes.oneOfType([
- PropTypes.number,
- PropTypes.string,
- ]),
- // backdropTransition - controls backdrop transition
- // timeout is 150ms by default to match bootstrap
- // see [Fade](/components/fade/) for more details
- backdropTransition: PropTypes.shape(Fade.propTypes),
- // modalTransition - controls modal transition
- // timeout is 300ms by default to match bootstrap
- // see [Fade](/components/fade/) for more details
- modalTransition: PropTypes.shape(Fade.propTypes),
- innerRef: PropTypes.object,
- // if modal should be destructed/removed from DOM after closing
- unmountOnClose: PropTypes.bool, // defaults to true
- // if the element which triggered the modal to open should focused after the modal closes (see example somewhere below)
- returnFocusAfterClose: PropTypes.bool, // defaults to true
- // container to append the modal to
- container: PropTypes.oneOfType([PropTypes.string, PropTypes.func, DOMElement]),
- trapFocus: PropTypes.bool // Traps focus within modal
-}`}
-
-
-
-
Fullscreen Modals
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- {ModalFullscreenExampleSource}
-
-
-
-
Backdrop
-
-
-
-
-
-
-
-
-
- {ModalBackdropExampleSource}
-
-
-
-
Nested Modals
-
-
-
-
-
-
-
-
-
- {ModalNestedExampleSource}
-
-
-
-
Modals with Custom Transition Timeouts
-
-
-
-
-
-
-
-
-
- {ModalCustomTimeoutExampleSource}
-
-
-
-
Modals without Fade Effect
-
-
-
-
-
-
-
-
-
- {ModalFadelessExampleSource}
-
-
-
-
Modals with external button
-
-
-
-
-
-
-
-
-
- {ModalExternalExampleSource}
-
-
-
-
Modals with custom close icon
-
-
-
-
-
-
-
-
-
- {ModalCustomCloseIconExampleSource}
-
-
-
Modals with custom close button
-
-
-
-
-
-
-
-
-
- {ModalCustomCloseButtonExampleSource}
-
-
-
-
Destructuring
-
-
-
-
-
-
-
-
-
- {ModalDestructuringExampleSource}
-
-
-
-
Focus after close
-
-
-
-
-
-
-
-
-
- {ModalFocusOnDestroyExampleSource}
-
-
-
- );
-};
-
-export default ModalsPage;
diff --git a/docs/lib/Components/NavbarPage.js b/docs/lib/Components/NavbarPage.js
deleted file mode 100644
index 83ea9a6b2..000000000
--- a/docs/lib/Components/NavbarPage.js
+++ /dev/null
@@ -1,85 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { Link } from 'react-router';
-import { PrismCode } from 'react-prism';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-import NavbarExample from '../examples/Navbar';
-const NavbarExampleSource = require('!!raw-loader!../examples/Navbar');
-import NavbarTogglerExample from '../examples/NavbarToggler';
-const NavbarTogglerExampleSource = require('!!raw-loader!../examples/NavbarToggler');
-
-export default class NavsPage extends React.Component {
- render() {
- return (
-
-
-
-
-
-
-
- {NavbarExampleSource}
-
-
-
Navbar Properties
-
See also Navs for additional components and PropTypes.
-
-
-{`Navbar.propTypes = {
- light: PropTypes.bool,
- dark: PropTypes.bool,
- fixed: PropTypes.string,
- color: PropTypes.string,
- role: PropTypes.string,
- expand: PropTypes.oneOfType([PropTypes.bool, PropTypes.string]),
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string])
- // pass in custom element to use
-}`}
-
-
-
NavbarBrand Properties
-
-
-{`NavbarBrand.propTypes = {
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string])
- // pass in custom element to use
-}`}
-
-
-
NavbarText Properties
-
-
-{`NavbarText.propTypes = {
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string])
- // pass in custom element to use
-}`}
-
-
- NavbarToggler
-
- Place the NavbarTogglerafterNavbarBrand to have it appear on the right (typical setup).
- Reverse the order to have it appear on the left
-
-
-
-
-
-
- {NavbarTogglerExampleSource}
-
-
-
NavbarToggler Properties
-
-
-{`NavbarToggler.propTypes = {
- type: PropTypes.string,
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string])
- // pass in custom element to use
-}`}
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/NavsPage.js b/docs/lib/Components/NavsPage.js
deleted file mode 100644
index b5e07a453..000000000
--- a/docs/lib/Components/NavsPage.js
+++ /dev/null
@@ -1,98 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-import NavsExample from '../examples/Navs';
-const NavsExampleSource = require('!!raw-loader!../examples/Navs');
-import NavVerticalExample from '../examples/NavVertical';
-const NavVerticalExampleSource = require('!!raw-loader!../examples/NavVertical');
-import NavTabsExample from '../examples/NavTabs';
-const NavTabsExampleSource = require('!!raw-loader!../examples/NavTabs');
-import NavPillsExample from '../examples/NavPills';
-const NavPillsExampleSource = require('!!raw-loader!../examples/NavPills');
-
-export default class NavssPage extends React.Component {
- render() {
- return (
-
-
-{`NavItem.propTypes = {
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- active: PropTypes.bool,
- // pass in custom element to use
-}`}
-
-
-
NavLink Properties
-
-
-{`NavLink.propTypes = {
- disabled: PropTypes.bool,
- active: PropTypes.bool,
- // pass in custom element to use
- tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
- // ref will only get you a reference to the NavLink component, use innerRef to get a reference to the DOM element (for things like focus management).
- innerRef: PropTypes.oneOfType([PropTypes.func, PropTypes.string])
-}`}
-
-
-
-{`Popover.propTypes = {
- children: PropTypes.oneOfType([PropTypes.node, PropTypes.func]),
- // space separated list of triggers (e.g. "click hover focus")
- trigger: PropTypes.string,
- // boolean to control the state of the popover
- isOpen: PropTypes.bool,
- // callback for toggling isOpen in the controlling component
- toggle: PropTypes.func,
- // boundaries for popper, can be scrollParent, window, viewport, or any DOM element
- boundariesElement: PropTypes.oneOfType([PropTypes.string, DOMElement]),
- target: PropTypes.oneOfType([
- PropTypes.string,
- PropTypes.func,
- DOMElement, // instanceof Element (https://developer.mozilla.org/en-US/docs/Web/API/Element)
- ]).isRequired,
- // Where to inject the popper DOM node, default to body
- container: PropTypes.oneOfType([PropTypes.string, PropTypes.func, DOMElement]),
- className: PropTypes.string,
- // Apply class to the popper component
- popperClassName: PropTypes.string,
- // Apply class to the inner-popover
- innerClassName: PropTypes.string,
- disabled: PropTypes.bool,
- hideArrow: PropTypes.bool,
- placementPrefix: PropTypes.string,
- delay: PropTypes.oneOfType([
- PropTypes.shape({ show: PropTypes.number, hide: PropTypes.number }),
- PropTypes.number,
- ]),
- placement: PropTypes.oneOf([
- 'auto',
- 'auto-start',
- 'auto-end',
- 'top',
- 'top-start',
- 'top-end',
- 'right',
- 'right-start',
- 'right-end',
- 'bottom',
- 'bottom-start',
- 'bottom-end',
- 'left',
- 'left-start',
- 'left-end',
- ]),
- // Custom modifiers that are passed to Popper.js, see https://popper.js.org/docs/v2/modifiers/
- modifiers: PropTypes.array,
- // https://popper.js.org/docs/v2/constructors/#strategy
- strategy: PropTypes.string,
- offset: PropTypes.arrayOf(PropTypes.number),
-
- // Whether to show/hide the popover with a fade effect
- // (default: true)
- fade: PropTypes.bool,
-
- // Whether to flip the direction of the popover if too close to
- // the container edge
- // (default: true)
- flip: PropTypes.bool,
-}`}
-
-
- Popovers Trigger
-
Trigger each popover to see information about the trigger
-
-
-
-
-
- {PopoverFocusExampleSource}
-
-
- Popovers Placements
-
-
-
-
-
- {PopoverExampleMultiSource}
-
-
- UncontrolledPopovers
-
-
-
-
-
- {UncontrolledPopoverExampleSource}
-
-
- Repositioning Popovers
-
- If you need to reposition a popover due to content changes or target placement changes, use
- the update function to manually reposition it. This function is exposed
- as a render prop for children.
-
-
-
-
-
-
- {PopoverUpdateExampleSource}
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/ProgressPage.js b/docs/lib/Components/ProgressPage.js
deleted file mode 100644
index 44f27a15e..000000000
--- a/docs/lib/Components/ProgressPage.js
+++ /dev/null
@@ -1,150 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import PageTitle from '../UI/PageTitle';
-import { Card, CardText } from 'reactstrap';
-import SectionTitle from '../UI/SectionTitle';
-import ProgressExample from '../examples/Progress';
-const ProgressExampleSource = require('!!raw-loader!../examples/Progress');
-import ProgressColorExample from '../examples/ProgressColor';
-const ProgressColorExampleSource = require('!!raw-loader!../examples/ProgressColor');
-import ProgressLabelsExample from '../examples/ProgressLabels';
-const ProgressLabelsExampleSource = require('!!raw-loader!../examples/ProgressLabels');
-import ProgressAnimatedExample from '../examples/ProgressAnimated';
-const ProgressAnimatedExampleSource = require('!!raw-loader!../examples/ProgressAnimated');
-import ProgressStripedExample from '../examples/ProgressStriped';
-const ProgressStripedExampleSource = require('!!raw-loader!../examples/ProgressStriped');
-import ProgressMultiExample from '../examples/ProgressMulti';
-const ProgressMultiExampleSource = require('!!raw-loader!../examples/ProgressMulti');
-import ProgressMaxExample from '../examples/ProgressMax';
-const ProgressMaxExampleSource = require('!!raw-loader!../examples/ProgressMax');
-
-export default class ProgressPage extends React.Component {
- render() {
- return (
-
-
-
-
-
-
-
- {ProgressExampleSource}
-
-
-
Properties
-
-
-{`Progress.propTypes = {
- multi: PropTypes.bool,
- bar: PropTypes.bool, // used in combination with multi
- tag: PropTypes.string,
- value: PropTypes.oneOfType([
- PropTypes.string,
- PropTypes.number,
- ]),
- min: PropTypes.oneOfType([
- PropTypes.string,
- PropTypes.number,
- ]),
- max: PropTypes.oneOf([
- PropTypes.string,
- PropTypes.number,
- ]),
- animated: PropTypes.bool,
- striped: PropTypes.bool,
- color: PropTypes.string,
- className: PropTypes.string,
- barStyle: PropTypes.object, // used to add style to the inner progress-bar element
- barClassName: PropTypes.string, // used to add class to the inner progress-bar element
- barAriaValueText: PropTypes.string,
- barAriaLabelledBy: PropTypes.string,
-};
-
-Progress.defaultProps = {
- tag: 'progress',
- value: 0,
- max: 100,
-};`}
-
-
-
- Color Variants
-
-
-
-
-
-
-
- {ProgressColorExampleSource}
-
-
-
- Labels
-
-
-
-
-
-
-
- {ProgressLabelsExampleSource}
-
-
-
- Striped
-
-
-
-
-
-
-
- {ProgressStripedExampleSource}
-
-
-
- Animated
-
- The animated prop also adds the striped prop; there is no need to pass both.
-
-
-
-
-
-
-
-
- {ProgressAnimatedExampleSource}
-
-
-
- Multiple bars / Stacked
-
-
-
-
-
-
-
- {ProgressMultiExampleSource}
-
-
-
- Max value
-
-
-
-
-
-
-
- {ProgressMaxExampleSource}
-
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/SpinnersPage.js b/docs/lib/Components/SpinnersPage.js
deleted file mode 100644
index 2eed19ec2..000000000
--- a/docs/lib/Components/SpinnersPage.js
+++ /dev/null
@@ -1,70 +0,0 @@
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import { Spinner } from 'reactstrap';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-
-import SpinnerExample from '../examples/Spinner';
-
-import SpinnerGrowerExample from '../examples/SpinnerGrower';
-const SpinnerExampleSource = require('!!raw-loader!../examples/Spinner');
-const SpinnerGrowerExampleSource = require('!!raw-loader!../examples/SpinnerGrower');
-export default class SpinnersPage extends React.Component {
- render() {
- return (
-
- );
- }
-}
diff --git a/docs/lib/Components/TablesPage.js b/docs/lib/Components/TablesPage.js
deleted file mode 100644
index 04f172439..000000000
--- a/docs/lib/Components/TablesPage.js
+++ /dev/null
@@ -1,127 +0,0 @@
-/* eslint react/no-multi-comp: 0, react/prop-types: 0 */
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import PageTitle from '../UI/PageTitle';
-import SectionTitle from '../UI/SectionTitle';
-
-import TableExample from '../examples/Table';
-import TableBorderedExample from '../examples/TableBordered';
-import TableBorderlessExample from '../examples/TableBorderless';
-import TableHoverExample from '../examples/TableHover';
-import TableDarkExample from '../examples/TableDark';
-import TableResponsiveExample from '../examples/TableResponsive';
-import TableSizingExample from '../examples/TableSizing';
-import TableStripedExample from '../examples/TableStriped';
-
-const TableExampleSource = require('!!raw-loader!../examples/Table');
-const TableBorderedExampleSource = require('!!raw-loader!../examples/TableBordered');
-const TableBorderlessExampleSource = require('!!raw-loader!../examples/TableBorderless');
-const TableHoverExampleSource = require('!!raw-loader!../examples/TableHover');
-const TableDarkExampleSource = require('!!raw-loader!../examples/TableDark');
-const TableResponsiveExampleSource = require('!!raw-loader!../examples/TableResponsive');
-const TableSizingExampleSource = require('!!raw-loader!../examples/TableSizing');
-const TableStripedExampleSource = require('!!raw-loader!../examples/TableStriped');
-
-export default class TablesPage extends React.Component {
- render() {
- return (
-
-
-
-
-
-
-
-
- {TableExampleSource}
-
-
-
Properties
-
-
-{`Table.propTypes = {
-// Pass in a Component to override default element
-tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]),
-size: PropTypes.string,
-bordered: PropTypes.bool,
-borderless: PropTypes.bool,
-striped: PropTypes.bool,
-dark: PropTypes.bool,
-hover: PropTypes.bool,
-responsive: PropTypes.bool,
-// Custom ref handler that will be assigned to the "ref" of the inner
element
-innerRef: PropTypes.oneOfType([
- PropTypes.func,
- PropTypes.string,
- PropTypes.object
-])
-};`}
-
-
- Dark table
-
-
-{`Tooltip.propTypes = {
- children: PropTypes.oneOfType([PropTypes.node, PropTypes.func]),
- // space separated list of triggers (e.g. "click hover focus")
- trigger: PropTypes.string,
- // boundaries for popper, can be scrollParent, window, viewport, or any DOM element
- boundariesElement: PropTypes.oneOfType([PropTypes.string, DOMElement]),
- // boolean to control the state of the tooltip
- isOpen: PropTypes.bool,
- hideArrow: PropTypes.bool,
- // callback for toggling isOpen in the controlling component. It will receive an object with info about the event that triggered it
- toggle: PropTypes.func,
- // target element or element ID, popover is attached to this element
- target: PropTypes.oneOfType([
- PropTypes.string,
- PropTypes.func,
- DOMElement, // instanceof Element (https://developer.mozilla.org/en-US/docs/Web/API/Element)
- ]).isRequired,
- // Where to inject the popper DOM node, default to body
- container: PropTypes.oneOfType([PropTypes.string, PropTypes.func, DOMElement]),
- // optionally override show/hide delays - default { show: 0, hide: 50 }
- delay: PropTypes.oneOfType([
- PropTypes.shape({ show: PropTypes.number, hide: PropTypes.number }),
- PropTypes.number
- ]),
- className: PropTypes.string,
- // Apply class to the popper component
- popperClassName: PropTypes.string,
- // Apply class to the inner-tooltip
- innerClassName: PropTypes.string,
- // Apply class to the arrow-tooltip ('arrow' by default)
- arrowClassName: PropTypes.string,
- // optionally hide tooltip when hovering over tooltip content - default true
- autohide: PropTypes.bool,
- // convenience attachments for popover
- placement: PropTypes.oneOf([
- 'auto',
- 'auto-start',
- 'auto-end',
- 'top',
- 'top-start',
- 'top-end',
- 'right',
- 'right-start',
- 'right-end',
- 'bottom',
- 'bottom-start',
- 'bottom-end',
- 'left',
- 'left-start',
- 'left-end',
- ]),
- // Custom modifiers that are passed to Popper.js, see https://popper.js.org/docs/v2/modifiers/
- modifiers: PropTypes.array,
- // Whether the element the tooltip is pointing to has "position: fixed" styling. This is passed to Popper.js and
- // will make the tooltip itself have "position: fixed" as well
- positionFixed: PropTypes.bool,
- offset: PropTypes.arrayOf(PropTypes.number),
- // Custom ref handler that will be assigned to the "ref" of the
wrapping the tooltip elements
- innerRef: PropTypes.oneOfType([
- PropTypes.func,
- PropTypes.string,
- PropTypes.object
- ]),
-
- // Whether to show/hide the popover with a fade effect
- // (default: true)
- fade: PropTypes.bool,
-
- // Whether to flip the direction of the popover if too close to
- // the container edge
- // (default: true)
- flip: PropTypes.bool,
-}`}
-
-
- Tooltip Disable Autohide
-
-
-
-
-
- {TooltipExampleAutoHideSource}
-
-
- Tooltips List
-
-
-
-
-
- {TooltipExampleMultiSource}
-
-
- Uncontrolled Tooltip
-
- For the most basic use-case an uncontrolled component can provide the functionality wanted without the need to manage/control the state of the component. UncontrolledTooltip does not require isOpen nor toggle props to work.
-
-
-
-
-
-
- {TooltipExampleUncontrolledSource}
-
-
- Repositioning Tooltips
-
- If you need to reposition a tooltip due to content changes or target placement changes, use
- the update function to manually reposition it. This function is exposed
- as a render prop for children.
-
-
-
-
-
-
- {TooltipUpdateExampleSource}
-
-
-
- );
- }
-}
diff --git a/docs/lib/Components/index.js b/docs/lib/Components/index.js
deleted file mode 100644
index 4421613ad..000000000
--- a/docs/lib/Components/index.js
+++ /dev/null
@@ -1,135 +0,0 @@
-import React from 'react';
-import Content from '../UI/Content';
-
-const items = [
- {
- name: 'Accordion',
- to: '/components/accordion/'
- },
- {
- name: 'Alerts',
- to: '/components/alerts/'
- },
- {
- name: 'Badge',
- to: '/components/badge/'
- },
- {
- name: 'Breadcrumbs',
- to: '/components/breadcrumbs/'
- },
- {
- name: 'Buttons',
- to: '/components/buttons/'
- },
- {
- name: 'Button Dropdown',
- to: '/components/button-dropdown/'
- },
- {
- name: 'Button Group',
- to: '/components/button-group/'
- },
- {
- name: 'Card',
- to: '/components/card/'
- },
- {
- name: 'Carousel',
- to: '/components/carousel/'
- },
- {
- name: 'Collapse',
- to: '/components/collapse/'
- },
- {
- name: 'Dropdowns',
- to: '/components/dropdowns/'
- },
- {
- name: 'Fade',
- to: '/components/fade/'
- },
- {
- name: 'Form',
- to: '/components/form/'
- },
- {
- name: 'Input Group',
- to: '/components/input-group/'
- },
- {
- name: 'Layout',
- to: '/components/layout/'
- },
- {
- name: 'List',
- to: '/components/list/'
- },
- {
- name: 'List Group',
- to: '/components/listgroup/'
- },
- {
- name: 'Media',
- to: '/components/media/'
- },
- {
- name: 'Modals',
- to: '/components/modals/'
- },
- {
- name: 'Navbar',
- to: '/components/navbar/'
- },
- {
- name: 'Navs',
- to: '/components/navs/'
- },
- {
- name: 'Offcanvas',
- to: '/components/offcanvas/'
- },
- {
- name: 'Placeholder',
- to: '/components/placeholder/'
- },
- {
- name: 'Spinners',
- to: '/components/spinners/'
- },
- {
- name: 'Toasts',
- to: '/components/toasts/'
- },
- {
- name: 'Pagination',
- to: '/components/pagination/'
- },
- {
- name: 'Popovers',
- to: '/components/popovers/'
- },
- {
- name: 'Progress',
- to: '/components/progress/'
- },
- {
- name: 'Tables',
- to: '/components/tables/'
- },
- {
- name: 'Tabs',
- to: '/components/tabs/'
- },
- {
- name: 'Tooltips',
- to: '/components/tooltips/'
- }
-];
-
-function Components(props) {
- return ;
-}
-
-export default Components;
diff --git a/docs/lib/Home/index.js b/docs/lib/Home/index.js
deleted file mode 100644
index 1e9502e29..000000000
--- a/docs/lib/Home/index.js
+++ /dev/null
@@ -1,262 +0,0 @@
-import React from 'react';
-import { PrismCode } from 'react-prism';
-import { Button, Container, Row, Col } from 'reactstrap';
-import { Link } from 'react-router';
-import Example from '../examples/import-basic';
-
-const importBasic = require('!!raw-loader!../examples/import-basic');
-
-export default () => {
- return (
-
- Then open{' '}
-
- http://localhost:3000/
- {' '}
- to see your app. The initial structure of your app is setup. Next,
- let's add reactstrap and bootstrap.
-
-
Adding Bootstrap
-
- Install reactstrap and Bootstrap from NPM. Reactstrap does not
- include Bootstrap CSS so this needs to be installed as well:
-
- Import required reactstrap components within{' '}
- src/App.js file or your custom component files:
-
-
-
- {`import { Button } from 'reactstrap';`}
-
-
-
- Now you are ready to use the imported reactstrap components within
- your component hierarchy defined in the render method. Here is an
- example{' '}
-
- App.js
- {' '}
- redone using reactstrap.
-
-
CDN
-
- Reactstrap can be included directly in your application's bundle
- or excluded during compilation and linked directly to a CDN.
-
- This library contains React Bootstrap 4 components that favor
- composition and control. The library does not depend on jQuery or
- Bootstrap javascript. However,{' '}
- https://popper.js.org/ via{' '}
-
- https://github.com/popperjs/react-popper
- {' '}
- is relied upon for advanced positioning of content like Tooltips,
- Popovers, and auto-flipping Dropdowns.
-
-
- There are a few core concepts to understand in order to make the
- most out of this library.
-
-
- 1) Your content is expected to be composed via props.children
- rather than using named props to pass in Components.
-
-
-
- {`// Content passed in via props
-const Example = (props) => {
- return (
-
This is a tooltip example!
- );
-}
-
-// Content passed in as children (Preferred)
-const PreferredExample = (props) => {
- return (
-
- 2) Attributes in this library are used to pass in state,
- conveniently apply modifier classes, enable advanced functionality
- (like popperjs), or automatically include non-content based
- elements.
-
-
Examples:
-
-
- isOpen - current state for items like dropdown,
- popover, tooltip
-
-
- toggle - callback for toggling isOpen in the
- controlling component
-
-
- color - applies color classes, ex:{' '}
- {''}
-
- Easily clear floats by adding
- {' '}.clearfix{' '}
- to the parent element.
- Utilizes
- the micro clearfix as popularized by Nicolas Gallagher.
- Can also be used as a mixin.
-
- Convey meaning through color with a handful of emphasis utility
- classes. These may also be applied to links and will darken on hover
- just like our default link styles.
-