Skip to content

Commit

Permalink
fix(types): type exports not being removed from compiled out
Browse files Browse the repository at this point in the history
fixes #5267
  • Loading branch information
jquense committed Jul 7, 2020
1 parent f4ddfea commit 7b4c639
Show file tree
Hide file tree
Showing 2 changed files with 185 additions and 81 deletions.
2 changes: 1 addition & 1 deletion src/PageItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ PageItem.displayName = 'PageItem';
export default PageItem;

function createButton(name: string, defaultValue: ReactNode, label = name) {
function Button({ children, ...props }) {
function Button({ children, ...props }: PageItemProps) {
return (
<PageItem {...props}>
<span aria-hidden="true">{children || defaultValue}</span>
Expand Down
264 changes: 184 additions & 80 deletions src/index.tsx
Original file line number Diff line number Diff line change
@@ -1,103 +1,207 @@
export { default as Accordion, AccordionProps } from './Accordion';
export { default as Accordion } from './Accordion';
export type { AccordionProps } from './Accordion';

export { default as AccordionContext } from './AccordionContext';
export {
default as AccordionCollapse,
AccordionCollapseProps,
} from './AccordionCollapse';
export { default as AccordionCollapse } from './AccordionCollapse';
export type { AccordionCollapseProps } from './AccordionCollapse';

export {
default as AccordionToggle,
AccordionToggleProps,
useAccordionToggle,
} from './AccordionToggle';
export { default as Alert, AlertProps } from './Alert';
export { default as Badge, BadgeProps } from './Badge';
export { default as Breadcrumb, BreadcrumbProps } from './Breadcrumb';
export {
default as BreadcrumbItem,
BreadcrumbItemProps,
} from './BreadcrumbItem';
export { default as Button, ButtonProps } from './Button';
export { default as ButtonGroup, ButtonGroupProps } from './ButtonGroup';
export { default as ButtonToolbar, ButtonToolbarProps } from './ButtonToolbar';
export { default as Card, CardProps } from './Card';
export type { AccordionToggleProps } from './AccordionToggle';

export { default as Alert } from './Alert';
export type { AlertProps } from './Alert';

export { default as Badge } from './Badge';
export type { BadgeProps } from './Badge';

export { default as Breadcrumb } from './Breadcrumb';
export type { BreadcrumbProps } from './Breadcrumb';

export { default as BreadcrumbItem } from './BreadcrumbItem';
export type { BreadcrumbItemProps } from './BreadcrumbItem';

export { default as Button } from './Button';
export type { ButtonProps } from './Button';

export { default as ButtonGroup } from './ButtonGroup';
export type { ButtonGroupProps } from './ButtonGroup';

export { default as ButtonToolbar } from './ButtonToolbar';
export type { ButtonToolbarProps } from './ButtonToolbar';

export { default as Card } from './Card';
export type { CardProps } from './Card';

export { default as CardColumns } from './CardColumns';
export { default as CardDeck } from './CardDeck';
export { default as CardImg, CardImgProps } from './CardImg';

export { default as CardImg } from './CardImg';
export type { CardImgProps } from './CardImg';

export { default as CardGroup } from './CardGroup';
export { default as Carousel, CarouselProps } from './Carousel';
export { default as Carousel } from './Carousel';
export type { CarouselProps } from './Carousel';

export { default as CarouselItem } from './CarouselItem';
export { default as CloseButton, CloseButtonProps } from './CloseButton';
export { default as Col, ColProps } from './Col';
export { default as Collapse, CollapseProps } from './Collapse';
export { default as Dropdown, DropdownProps } from './Dropdown';
export {
default as DropdownButton,
DropdownButtonProps,
} from './DropdownButton';
export { default as Fade, FadeProps } from './Fade';

export { default as Form, FormProps } from './Form';
export { default as FormControl, FormControlProps } from './FormControl';
export { default as FormCheck, FormCheckProps } from './FormCheck';
export { default as FormFile, FormFileProps } from './FormFile';
export { default as FormGroup, FormGroupProps } from './FormGroup';
export { default as FormLabel, FormLabelProps } from './FormLabel';
export { default as FormText, FormTextProps } from './FormText';

export { default as Container, ContainerProps } from './Container';
export { default as Image, ImageProps } from './Image';
export { default as CloseButton } from './CloseButton';
export type { CloseButtonProps } from './CloseButton';

export { default as Col } from './Col';
export type { ColProps } from './Col';

export { default as Collapse } from './Collapse';
export type { CollapseProps } from './Collapse';

export { default as Dropdown } from './Dropdown';
export type { DropdownProps } from './Dropdown';

export { default as DropdownButton } from './DropdownButton';
export type { DropdownButtonProps } from './DropdownButton';

export { default as Fade } from './Fade';
export type { FadeProps } from './Fade';

export { default as Form } from './Form';
export type { FormProps } from './Form';

export { default as FormControl } from './FormControl';
export type { FormControlProps } from './FormControl';

export { default as FormCheck } from './FormCheck';
export type { FormCheckProps } from './FormCheck';

export { default as FormFile } from './FormFile';
export type { FormFileProps } from './FormFile';

export { default as FormGroup } from './FormGroup';
export type { FormGroupProps } from './FormGroup';

export { default as FormLabel } from './FormLabel';
export type { FormLabelProps } from './FormLabel';

export { default as FormText } from './FormText';
export type { FormTextProps } from './FormText';

export { default as Container } from './Container';
export type { ContainerProps } from './Container';

export { default as Image } from './Image';
export type { ImageProps } from './Image';

export { default as Figure } from './Figure';
export { default as InputGroup, InputGroupProps } from './InputGroup';
export { default as Jumbotron, JumbotronProps } from './Jumbotron';
export { default as ListGroup, ListGroupProps } from './ListGroup';
export { default as ListGroupItem, ListGroupItemProps } from './ListGroupItem';
export { default as InputGroup } from './InputGroup';
export type { InputGroupProps } from './InputGroup';

export { default as Jumbotron } from './Jumbotron';
export type { JumbotronProps } from './Jumbotron';

export { default as ListGroup } from './ListGroup';
export type { ListGroupProps } from './ListGroup';

export { default as ListGroupItem } from './ListGroupItem';
export type { ListGroupItemProps } from './ListGroupItem';

export { default as Media } from './Media';
export { default as Modal, ModalProps } from './Modal';
export { default as Modal } from './Modal';
export type { ModalProps } from './Modal';

export { default as ModalBody } from './ModalBody';
export { default as ModalDialog, ModalDialogProps } from './ModalDialog';
export { default as ModalDialog } from './ModalDialog';
export type { ModalDialogProps } from './ModalDialog';

export { default as ModalFooter } from './ModalFooter';
export { default as ModalTitle } from './ModalTitle';
export { default as Nav, NavProps } from './Nav';
export { default as Navbar, NavbarProps } from './Navbar';
export { default as NavbarBrand, NavbarBrandProps } from './NavbarBrand';
export { default as NavDropdown, NavDropdownProps } from './NavDropdown';
export { default as NavItem, NavItemProps } from './NavItem';
export { default as NavLink, NavLinkProps } from './NavLink';
export { default as Overlay, OverlayProps } from './Overlay';
export {
default as OverlayTrigger,
OverlayTriggerProps,
} from './OverlayTrigger';
export { default as PageItem, PageItemProps } from './PageItem';
export { default as Pagination, PaginationProps } from './Pagination';
export { default as Nav } from './Nav';
export type { NavProps } from './Nav';

export { default as Navbar } from './Navbar';
export type { NavbarProps } from './Navbar';

export { default as NavbarBrand } from './NavbarBrand';
export type { NavbarBrandProps } from './NavbarBrand';

export { default as NavDropdown } from './NavDropdown';
export type { NavDropdownProps } from './NavDropdown';

export { default as NavItem } from './NavItem';
export type { NavItemProps } from './NavItem';

export { default as NavLink } from './NavLink';
export type { NavLinkProps } from './NavLink';

export { default as Overlay } from './Overlay';
export type { OverlayProps } from './Overlay';

export { default as OverlayTrigger } from './OverlayTrigger';
export type { OverlayTriggerProps } from './OverlayTrigger';

export { default as PageItem } from './PageItem';
export type { PageItemProps } from './PageItem';

export { default as Pagination } from './Pagination';
export type { PaginationProps } from './Pagination';

export { default as Popover } from './Popover';
export type { PopoverProps } from './Popover';

export { default as Popover, PopoverProps } from './Popover';
export { default as PopoverTitle } from './PopoverTitle';
export { default as PopoverContent } from './PopoverContent';
export { default as ProgressBar, ProgressBarProps } from './ProgressBar';
export {
default as ResponsiveEmbed,
ResponsiveEmbedProps,
} from './ResponsiveEmbed';
export { default as Row, RowProps } from './Row';
export { default as SafeAnchor, SafeAnchorProps } from './SafeAnchor';
export { default as Spinner, SpinnerProps } from './Spinner';
export { default as SplitButton, SplitButtonProps } from './SplitButton';
export { default as Tab, TabProps } from './Tab';
export { default as TabContainer, TabContainerProps } from './TabContainer';
export { default as ProgressBar } from './ProgressBar';
export type { ProgressBarProps } from './ProgressBar';

export { default as ResponsiveEmbed } from './ResponsiveEmbed';
export type { ResponsiveEmbedProps } from './ResponsiveEmbed';

export { default as Row } from './Row';
export type { RowProps } from './Row';

export { default as SafeAnchor } from './SafeAnchor';
export type { SafeAnchorProps } from './SafeAnchor';

export { default as Spinner } from './Spinner';
export type { SpinnerProps } from './Spinner';

export { default as SplitButton } from './SplitButton';
export type { SplitButtonProps } from './SplitButton';

export { default as Tab } from './Tab';
export type { TabProps } from './Tab';

export { default as TabContainer } from './TabContainer';
export type { TabContainerProps } from './TabContainer';

export { default as TabContent } from './TabContent';
export { default as Table, TableProps } from './Table';
export { default as TabPane, TabPaneProps } from './TabPane';
export { default as Tabs, TabsProps } from './Tabs';
export { default as ThemeProvider, ThemeProviderProps } from './ThemeProvider';
export { default as Toast, ToastProps } from './Toast';
export { default as Table } from './Table';
export type { TableProps } from './Table';

export { default as TabPane } from './TabPane';
export type { TabPaneProps } from './TabPane';

export { default as Tabs } from './Tabs';
export type { TabsProps } from './Tabs';

export { default as ThemeProvider } from './ThemeProvider';
export type { ThemeProviderProps } from './ThemeProvider';

export { default as Toast } from './Toast';
export type { ToastProps } from './Toast';

export { default as ToastBody } from './ToastBody';
export { default as ToastHeader, ToastHeaderProps } from './ToastHeader';
export { default as ToggleButton, ToggleButtonProps } from './ToggleButton';
export {
default as ToggleButtonGroup,
export { default as ToastHeader } from './ToastHeader';
export type { ToastHeaderProps } from './ToastHeader';

export { default as ToggleButton } from './ToggleButton';
export type { ToggleButtonProps } from './ToggleButton';

export { default as ToggleButtonGroup } from './ToggleButtonGroup';
export type {
ToggleButtonCheckboxProps,
ToggleButtonGroupProps,
ToggleButtonRadioProps,
} from './ToggleButtonGroup';
export { default as Tooltip, TooltipProps } from './Tooltip';

export { default as Tooltip } from './Tooltip';
export type { TooltipProps } from './Tooltip';

0 comments on commit 7b4c639

Please sign in to comment.