react-bootstrap 2.6.0 → 2.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/AbstractModalHeader.js +0 -9
- package/cjs/Accordion.js +0 -17
- package/cjs/AccordionBody.d.ts +2 -1
- package/cjs/AccordionBody.js +12 -10
- package/cjs/AccordionButton.d.ts +1 -1
- package/cjs/AccordionButton.js +1 -16
- package/cjs/AccordionCollapse.js +0 -10
- package/cjs/AccordionContext.d.ts +1 -1
- package/cjs/AccordionContext.js +0 -5
- package/cjs/AccordionHeader.js +0 -9
- package/cjs/AccordionItem.js +0 -9
- package/cjs/AccordionItemContext.js +0 -4
- package/cjs/Alert.js +0 -17
- package/cjs/Anchor.js +0 -3
- package/cjs/Badge.js +0 -8
- package/cjs/BootstrapModalManager.js +2 -18
- package/cjs/Breadcrumb.js +2 -12
- package/cjs/BreadcrumbItem.js +2 -10
- package/cjs/Button.d.ts +1 -1
- package/cjs/Button.js +2 -10
- package/cjs/ButtonGroup.js +2 -9
- package/cjs/ButtonToolbar.js +2 -9
- package/cjs/Card.js +0 -14
- package/cjs/CardGroup.js +0 -4
- package/cjs/CardHeader.js +0 -9
- package/cjs/CardHeaderContext.js +0 -4
- package/cjs/CardImg.js +2 -9
- package/cjs/Carousel.d.ts +1 -1
- package/cjs/Carousel.js +9 -58
- package/cjs/CarouselCaption.js +0 -4
- package/cjs/CarouselItem.js +0 -8
- package/cjs/CloseButton.d.ts +1 -1
- package/cjs/CloseButton.js +0 -10
- package/cjs/Col.d.ts +5 -5
- package/cjs/Col.js +6 -14
- package/cjs/Collapse.d.ts +1 -1
- package/cjs/Collapse.js +10 -22
- package/cjs/Container.js +0 -8
- package/cjs/Dropdown.js +17 -27
- package/cjs/DropdownButton.js +1 -25
- package/cjs/DropdownContext.d.ts +2 -2
- package/cjs/DropdownContext.js +0 -4
- package/cjs/DropdownItem.js +2 -11
- package/cjs/DropdownMenu.d.ts +2 -2
- package/cjs/DropdownMenu.js +12 -34
- package/cjs/DropdownToggle.d.ts +2 -2
- package/cjs/DropdownToggle.js +7 -24
- package/cjs/ElementChildren.js +2 -8
- package/cjs/Fade.js +2 -12
- package/cjs/Feedback.d.ts +1 -1
- package/cjs/Feedback.js +4 -11
- package/cjs/Figure.js +0 -7
- package/cjs/FigureCaption.js +0 -3
- package/cjs/FigureImage.js +0 -8
- package/cjs/FloatingLabel.js +0 -9
- package/cjs/Form.d.ts +1 -1
- package/cjs/Form.js +2 -22
- package/cjs/FormCheck.d.ts +1 -1
- package/cjs/FormCheck.js +2 -16
- package/cjs/FormCheckInput.d.ts +1 -1
- package/cjs/FormCheckInput.js +2 -10
- package/cjs/FormCheckLabel.js +2 -10
- package/cjs/FormContext.js +0 -4
- package/cjs/FormControl.d.ts +1 -1
- package/cjs/FormControl.js +2 -16
- package/cjs/FormFloating.js +0 -4
- package/cjs/FormGroup.js +2 -8
- package/cjs/FormLabel.d.ts +1 -1
- package/cjs/FormLabel.js +0 -11
- package/cjs/FormRange.js +2 -10
- package/cjs/FormSelect.js +2 -10
- package/cjs/FormText.js +4 -10
- package/cjs/Image.js +0 -13
- package/cjs/InputGroup.js +3 -18
- package/cjs/InputGroupContext.js +0 -4
- package/cjs/ListGroup.js +0 -16
- package/cjs/ListGroupItem.js +2 -16
- package/cjs/Modal.js +31 -72
- package/cjs/ModalBody.js +0 -4
- package/cjs/ModalContext.js +0 -5
- package/cjs/ModalDialog.js +2 -9
- package/cjs/ModalFooter.js +0 -4
- package/cjs/ModalHeader.js +0 -9
- package/cjs/ModalTitle.js +0 -6
- package/cjs/Nav.js +0 -19
- package/cjs/NavContext.js +0 -4
- package/cjs/NavDropdown.js +0 -12
- package/cjs/NavItem.js +0 -4
- package/cjs/NavLink.js +2 -12
- package/cjs/Navbar.js +3 -22
- package/cjs/NavbarBrand.js +2 -9
- package/cjs/NavbarCollapse.js +0 -9
- package/cjs/NavbarContext.js +0 -4
- package/cjs/NavbarOffcanvas.d.ts +1 -1
- package/cjs/NavbarOffcanvas.js +0 -8
- package/cjs/NavbarToggle.js +2 -13
- package/cjs/Offcanvas.d.ts +1 -1
- package/cjs/Offcanvas.js +9 -37
- package/cjs/OffcanvasBody.js +0 -4
- package/cjs/OffcanvasHeader.js +0 -9
- package/cjs/OffcanvasTitle.js +0 -6
- package/cjs/OffcanvasToggling.js +2 -12
- package/cjs/Overlay.d.ts +2 -1
- package/cjs/Overlay.js +24 -31
- package/cjs/OverlayTrigger.d.ts +4 -4
- package/cjs/OverlayTrigger.js +7 -32
- package/cjs/PageItem.js +3 -11
- package/cjs/Pagination.js +0 -11
- package/cjs/Placeholder.js +2 -11
- package/cjs/PlaceholderButton.js +2 -9
- package/cjs/Popover.d.ts +1 -0
- package/cjs/Popover.js +12 -16
- package/cjs/PopoverBody.js +0 -4
- package/cjs/PopoverHeader.js +0 -4
- package/cjs/ProgressBar.js +2 -20
- package/cjs/Ratio.d.ts +1 -1
- package/cjs/Ratio.js +3 -12
- package/cjs/Row.d.ts +2 -2
- package/cjs/Row.js +0 -10
- package/cjs/SSRProvider.js +0 -2
- package/cjs/Spinner.js +0 -8
- package/cjs/SplitButton.js +1 -27
- package/cjs/Stack.d.ts +1 -1
- package/cjs/Stack.js +4 -14
- package/cjs/Switch.d.ts +1 -1
- package/cjs/Switch.js +2 -10
- package/cjs/Tab.js +2 -20
- package/cjs/TabContainer.js +2 -10
- package/cjs/TabContent.js +0 -4
- package/cjs/TabPane.js +7 -17
- package/cjs/Table.js +2 -13
- package/cjs/Tabs.js +6 -24
- package/cjs/ThemeProvider.js +8 -17
- package/cjs/Toast.js +5 -18
- package/cjs/ToastBody.js +0 -4
- package/cjs/ToastContainer.d.ts +1 -1
- package/cjs/ToastContainer.js +0 -8
- package/cjs/ToastContext.js +0 -5
- package/cjs/ToastFade.js +2 -9
- package/cjs/ToastHeader.js +0 -11
- package/cjs/ToggleButton.d.ts +1 -1
- package/cjs/ToggleButton.js +2 -11
- package/cjs/ToggleButtonGroup.d.ts +2 -2
- package/cjs/ToggleButtonGroup.js +2 -23
- package/cjs/Tooltip.d.ts +1 -0
- package/cjs/Tooltip.js +12 -12
- package/cjs/TransitionWrapper.d.ts +1 -1
- package/cjs/TransitionWrapper.js +3 -15
- package/cjs/createChainedFunction.js +2 -5
- package/cjs/createUtilityClasses.d.ts +1 -1
- package/cjs/createUtilityClasses.js +0 -6
- package/cjs/createWithBsPrefix.js +0 -11
- package/cjs/divWithClassName.js +2 -9
- package/cjs/getInitialPopperStyles.d.ts +2 -0
- package/cjs/getInitialPopperStyles.js +14 -0
- package/cjs/getTabTransitionComponent.js +0 -6
- package/cjs/helpers.d.ts +4 -4
- package/cjs/helpers.js +2 -9
- package/cjs/index.js +0 -171
- package/cjs/safeFindDOMNode.js +0 -5
- package/cjs/transitionEndListener.js +0 -6
- package/cjs/triggerBrowserReflow.js +0 -2
- package/cjs/types.d.ts +11 -10
- package/cjs/types.js +0 -5
- package/cjs/useOverlayOffset.js +0 -8
- package/cjs/usePlaceholder.d.ts +2 -2
- package/cjs/usePlaceholder.js +2 -7
- package/cjs/useWrappedRefWithWarning.js +4 -9
- package/dist/react-bootstrap.js +740 -1967
- package/dist/react-bootstrap.min.js +1 -1
- package/esm/AccordionBody.d.ts +2 -1
- package/esm/AccordionBody.js +12 -0
- package/esm/AccordionButton.d.ts +1 -1
- package/esm/AccordionButton.js +1 -5
- package/esm/AccordionCollapse.js +0 -1
- package/esm/AccordionContext.d.ts +1 -1
- package/esm/Alert.js +0 -2
- package/esm/BootstrapModalManager.js +2 -9
- package/esm/Breadcrumb.js +2 -1
- package/esm/BreadcrumbItem.js +2 -1
- package/esm/Button.d.ts +1 -1
- package/esm/Button.js +2 -1
- package/esm/ButtonGroup.js +2 -1
- package/esm/ButtonToolbar.js +2 -1
- package/esm/CardImg.js +2 -1
- package/esm/Carousel.d.ts +1 -1
- package/esm/Carousel.js +9 -36
- package/esm/CloseButton.d.ts +1 -1
- package/esm/CloseButton.js +0 -2
- package/esm/Col.d.ts +5 -5
- package/esm/Col.js +6 -5
- package/esm/Collapse.d.ts +1 -1
- package/esm/Collapse.js +11 -8
- package/esm/Dropdown.js +17 -7
- package/esm/DropdownButton.js +1 -14
- package/esm/DropdownContext.d.ts +2 -2
- package/esm/DropdownItem.js +2 -1
- package/esm/DropdownMenu.d.ts +2 -2
- package/esm/DropdownMenu.js +12 -15
- package/esm/DropdownToggle.d.ts +2 -2
- package/esm/DropdownToggle.js +7 -10
- package/esm/ElementChildren.js +3 -6
- package/esm/Fade.js +2 -1
- package/esm/Feedback.d.ts +1 -1
- package/esm/Feedback.js +4 -3
- package/esm/Form.d.ts +1 -1
- package/esm/Form.js +2 -2
- package/esm/FormCheck.d.ts +1 -1
- package/esm/FormCheck.js +2 -3
- package/esm/FormCheckInput.d.ts +1 -1
- package/esm/FormCheckInput.js +2 -1
- package/esm/FormCheckLabel.js +2 -1
- package/esm/FormContext.js +3 -1
- package/esm/FormControl.d.ts +1 -1
- package/esm/FormControl.js +2 -3
- package/esm/FormGroup.js +2 -1
- package/esm/FormLabel.d.ts +1 -1
- package/esm/FormRange.js +2 -1
- package/esm/FormSelect.js +2 -1
- package/esm/FormText.js +4 -2
- package/esm/Image.js +0 -4
- package/esm/InputGroup.js +3 -5
- package/esm/ListGroup.js +0 -2
- package/esm/ListGroupItem.js +2 -4
- package/esm/Modal.js +31 -43
- package/esm/ModalContext.js +0 -1
- package/esm/ModalDialog.js +2 -1
- package/esm/Nav.js +0 -2
- package/esm/NavLink.js +2 -1
- package/esm/Navbar.js +3 -4
- package/esm/NavbarBrand.js +2 -1
- package/esm/NavbarContext.js +3 -1
- package/esm/NavbarOffcanvas.d.ts +1 -1
- package/esm/NavbarToggle.js +2 -3
- package/esm/Offcanvas.d.ts +1 -1
- package/esm/Offcanvas.js +9 -16
- package/esm/OffcanvasToggling.js +2 -1
- package/esm/Overlay.d.ts +2 -1
- package/esm/Overlay.js +25 -17
- package/esm/OverlayTrigger.d.ts +4 -4
- package/esm/OverlayTrigger.js +7 -20
- package/esm/PageItem.js +2 -3
- package/esm/Pagination.js +0 -1
- package/esm/Placeholder.js +2 -1
- package/esm/PlaceholderButton.js +2 -1
- package/esm/Popover.d.ts +1 -0
- package/esm/Popover.js +12 -3
- package/esm/ProgressBar.js +2 -12
- package/esm/Ratio.d.ts +1 -1
- package/esm/Ratio.js +3 -4
- package/esm/Row.d.ts +2 -2
- package/esm/Row.js +0 -2
- package/esm/SplitButton.js +1 -16
- package/esm/Stack.d.ts +1 -1
- package/esm/Stack.js +4 -5
- package/esm/Switch.d.ts +1 -1
- package/esm/Switch.js +2 -1
- package/esm/Tab.js +2 -9
- package/esm/TabContainer.js +2 -3
- package/esm/TabPane.js +7 -4
- package/esm/Table.js +2 -6
- package/esm/Tabs.js +6 -9
- package/esm/ThemeProvider.js +8 -9
- package/esm/Toast.js +5 -5
- package/esm/ToastContainer.d.ts +1 -1
- package/esm/ToastContext.js +0 -1
- package/esm/ToastFade.js +2 -1
- package/esm/ToggleButton.d.ts +1 -1
- package/esm/ToggleButton.js +2 -3
- package/esm/ToggleButtonGroup.d.ts +2 -2
- package/esm/ToggleButtonGroup.js +2 -9
- package/esm/Tooltip.d.ts +1 -0
- package/esm/Tooltip.js +12 -3
- package/esm/TransitionWrapper.d.ts +1 -1
- package/esm/TransitionWrapper.js +3 -5
- package/esm/createChainedFunction.js +2 -4
- package/esm/createUtilityClasses.d.ts +1 -1
- package/esm/createUtilityClasses.js +0 -1
- package/esm/createWithBsPrefix.js +0 -2
- package/esm/divWithClassName.js +2 -1
- package/esm/getInitialPopperStyles.d.ts +2 -0
- package/esm/getInitialPopperStyles.js +9 -0
- package/esm/getTabTransitionComponent.js +0 -1
- package/esm/helpers.d.ts +4 -4
- package/esm/helpers.js +3 -3
- package/esm/safeFindDOMNode.js +0 -1
- package/esm/transitionEndListener.js +0 -2
- package/esm/types.d.ts +11 -10
- package/esm/useOverlayOffset.js +3 -3
- package/esm/usePlaceholder.d.ts +2 -2
- package/esm/usePlaceholder.js +2 -1
- package/esm/useWrappedRefWithWarning.js +4 -3
- package/getInitialPopperStyles/package.json +7 -0
- package/package.json +1 -1
- package/cjs/AbstractNav.d.ts +0 -15
- package/cjs/AbstractNavItem.d.ts +0 -19
- package/cjs/AccordionToggle.d.ts +0 -11
- package/cjs/CardColumns.d.ts +0 -2
- package/cjs/CardContext.d.ts +0 -6
- package/cjs/CardDeck.d.ts +0 -2
- package/cjs/FormFile.d.ts +0 -23
- package/cjs/FormFileInput.d.ts +0 -10
- package/cjs/FormFileLabel.d.ts +0 -7
- package/cjs/Jumbotron.d.ts +0 -7
- package/cjs/Media.d.ts +0 -8
- package/cjs/PopoverContent.d.ts +0 -5
- package/cjs/PopoverTitle.d.ts +0 -5
- package/cjs/ResponsiveEmbed.d.ts +0 -9
- package/cjs/SafeAnchor.d.ts +0 -17
- package/cjs/SelectableContext.d.ts +0 -5
- package/cjs/TabContext.d.ts +0 -12
- package/cjs/usePopperMarginModifiers.d.ts +0 -4
- package/esm/AbstractNav.d.ts +0 -15
- package/esm/AbstractNavItem.d.ts +0 -19
- package/esm/AccordionToggle.d.ts +0 -11
- package/esm/CardColumns.d.ts +0 -2
- package/esm/CardContext.d.ts +0 -6
- package/esm/CardDeck.d.ts +0 -2
- package/esm/FormFile.d.ts +0 -23
- package/esm/FormFileInput.d.ts +0 -10
- package/esm/FormFileLabel.d.ts +0 -7
- package/esm/Jumbotron.d.ts +0 -7
- package/esm/Media.d.ts +0 -8
- package/esm/PopoverContent.d.ts +0 -5
- package/esm/PopoverTitle.d.ts +0 -5
- package/esm/ResponsiveEmbed.d.ts +0 -9
- package/esm/SafeAnchor.d.ts +0 -17
- package/esm/SelectableContext.d.ts +0 -5
- package/esm/TabContext.d.ts +0 -12
- package/esm/usePopperMarginModifiers.d.ts +0 -4
package/esm/ToastFade.js
CHANGED
|
@@ -6,7 +6,8 @@ const fadeStyles = {
|
|
|
6
6
|
[ENTERING]: 'showing',
|
|
7
7
|
[EXITING]: 'showing show'
|
|
8
8
|
};
|
|
9
|
-
const ToastFade = /*#__PURE__*/React.forwardRef((props, ref) => /*#__PURE__*/_jsx(Fade, {
|
|
9
|
+
const ToastFade = /*#__PURE__*/React.forwardRef((props, ref) => /*#__PURE__*/_jsx(Fade, {
|
|
10
|
+
...props,
|
|
10
11
|
ref: ref,
|
|
11
12
|
transitionClasses: fadeStyles
|
|
12
13
|
}));
|
package/esm/ToggleButton.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { ButtonProps } from './Button';
|
|
3
|
-
export
|
|
3
|
+
export type ToggleButtonType = 'checkbox' | 'radio';
|
|
4
4
|
export interface ToggleButtonProps extends Omit<ButtonProps, 'onChange' | 'type'> {
|
|
5
5
|
type?: ToggleButtonType;
|
|
6
6
|
name?: string;
|
package/esm/ToggleButton.js
CHANGED
|
@@ -5,9 +5,7 @@ import Button from './Button';
|
|
|
5
5
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
6
6
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
7
7
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
8
|
-
|
|
9
8
|
const noop = () => undefined;
|
|
10
|
-
|
|
11
9
|
const ToggleButton = /*#__PURE__*/React.forwardRef(({
|
|
12
10
|
bsPrefix,
|
|
13
11
|
name,
|
|
@@ -34,7 +32,8 @@ const ToggleButton = /*#__PURE__*/React.forwardRef(({
|
|
|
34
32
|
disabled: !!disabled,
|
|
35
33
|
onChange: onChange || noop,
|
|
36
34
|
id: id
|
|
37
|
-
}), /*#__PURE__*/_jsx(Button, {
|
|
35
|
+
}), /*#__PURE__*/_jsx(Button, {
|
|
36
|
+
...props,
|
|
38
37
|
ref: ref,
|
|
39
38
|
className: classNames(className, disabled && 'disabled'),
|
|
40
39
|
type: undefined,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { ButtonGroupProps } from './ButtonGroup';
|
|
3
3
|
import { BsPrefixRefForwardingComponent } from './helpers';
|
|
4
|
-
|
|
4
|
+
type BaseToggleButtonProps = Omit<ButtonGroupProps, 'toggle' | 'defaultValue' | 'onChange'>;
|
|
5
5
|
export interface ToggleButtonRadioProps<T> extends BaseToggleButtonProps {
|
|
6
6
|
type?: 'radio';
|
|
7
7
|
name: string;
|
|
@@ -16,7 +16,7 @@ export interface ToggleButtonCheckboxProps<T> extends BaseToggleButtonProps {
|
|
|
16
16
|
defaultValue?: T[];
|
|
17
17
|
onChange?: (value: T[]) => void;
|
|
18
18
|
}
|
|
19
|
-
export
|
|
19
|
+
export type ToggleButtonGroupProps<T> = ToggleButtonRadioProps<T> | ToggleButtonCheckboxProps<T>;
|
|
20
20
|
declare const _default: BsPrefixRefForwardingComponent<"a", ToggleButtonGroupProps<any>> & {
|
|
21
21
|
Button: React.ForwardRefExoticComponent<import("./ToggleButton").ToggleButtonProps & React.RefAttributes<HTMLLabelElement>>;
|
|
22
22
|
};
|
package/esm/ToggleButtonGroup.js
CHANGED
|
@@ -21,31 +21,26 @@ const ToggleButtonGroup = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
|
21
21
|
} = useUncontrolled(props, {
|
|
22
22
|
value: 'onChange'
|
|
23
23
|
});
|
|
24
|
-
|
|
25
24
|
const getValues = () => value == null ? [] : [].concat(value);
|
|
26
|
-
|
|
27
25
|
const handleToggle = (inputVal, event) => {
|
|
28
26
|
if (!onChange) {
|
|
29
27
|
return;
|
|
30
28
|
}
|
|
31
|
-
|
|
32
29
|
const values = getValues();
|
|
33
30
|
const isActive = values.indexOf(inputVal) !== -1;
|
|
34
|
-
|
|
35
31
|
if (type === 'radio') {
|
|
36
32
|
if (!isActive) onChange(inputVal, event);
|
|
37
33
|
return;
|
|
38
34
|
}
|
|
39
|
-
|
|
40
35
|
if (isActive) {
|
|
41
36
|
onChange(values.filter(n => n !== inputVal), event);
|
|
42
37
|
} else {
|
|
43
38
|
onChange([...values, inputVal], event);
|
|
44
39
|
}
|
|
45
40
|
};
|
|
46
|
-
|
|
47
41
|
!(type !== 'radio' || !!name) ? process.env.NODE_ENV !== "production" ? invariant(false, 'A `name` is required to group the toggle buttons when the `type` ' + 'is set to "radio"') : invariant(false) : void 0;
|
|
48
|
-
return /*#__PURE__*/_jsx(ButtonGroup, {
|
|
42
|
+
return /*#__PURE__*/_jsx(ButtonGroup, {
|
|
43
|
+
...controlledProps,
|
|
49
44
|
ref: ref,
|
|
50
45
|
children: map(children, child => {
|
|
51
46
|
const values = getValues();
|
|
@@ -53,9 +48,7 @@ const ToggleButtonGroup = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
|
53
48
|
value: childVal,
|
|
54
49
|
onChange: childOnChange
|
|
55
50
|
} = child.props;
|
|
56
|
-
|
|
57
51
|
const handler = e => handleToggle(childVal, e);
|
|
58
|
-
|
|
59
52
|
return /*#__PURE__*/React.cloneElement(child, {
|
|
60
53
|
type,
|
|
61
54
|
name: child.name || name,
|
package/esm/Tooltip.d.ts
CHANGED
|
@@ -7,6 +7,7 @@ export interface TooltipProps extends React.HTMLAttributes<HTMLDivElement>, BsPr
|
|
|
7
7
|
arrowProps?: Partial<OverlayArrowProps>;
|
|
8
8
|
show?: boolean;
|
|
9
9
|
popper?: PopperRef;
|
|
10
|
+
hasDoneInitialMeasure?: boolean;
|
|
10
11
|
}
|
|
11
12
|
declare const Tooltip: React.ForwardRefExoticComponent<TooltipProps & React.RefAttributes<HTMLDivElement>>;
|
|
12
13
|
export default Tooltip;
|
package/esm/Tooltip.js
CHANGED
|
@@ -2,6 +2,7 @@ import classNames from 'classnames';
|
|
|
2
2
|
import * as React from 'react';
|
|
3
3
|
import { useBootstrapPrefix, useIsRTL } from './ThemeProvider';
|
|
4
4
|
import { getOverlayDirection } from './helpers';
|
|
5
|
+
import getInitialPopperStyles from './getInitialPopperStyles';
|
|
5
6
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
6
7
|
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
7
8
|
const defaultProps = {
|
|
@@ -14,17 +15,25 @@ const Tooltip = /*#__PURE__*/React.forwardRef(({
|
|
|
14
15
|
style,
|
|
15
16
|
children,
|
|
16
17
|
arrowProps,
|
|
17
|
-
|
|
18
|
-
|
|
18
|
+
hasDoneInitialMeasure,
|
|
19
|
+
popper,
|
|
20
|
+
show: _,
|
|
19
21
|
...props
|
|
20
22
|
}, ref) => {
|
|
21
23
|
bsPrefix = useBootstrapPrefix(bsPrefix, 'tooltip');
|
|
22
24
|
const isRTL = useIsRTL();
|
|
23
25
|
const [primaryPlacement] = (placement == null ? void 0 : placement.split('-')) || [];
|
|
24
26
|
const bsDirection = getOverlayDirection(primaryPlacement, isRTL);
|
|
27
|
+
let computedStyle = style;
|
|
28
|
+
if (!hasDoneInitialMeasure) {
|
|
29
|
+
computedStyle = {
|
|
30
|
+
...style,
|
|
31
|
+
...getInitialPopperStyles(popper == null ? void 0 : popper.strategy)
|
|
32
|
+
};
|
|
33
|
+
}
|
|
25
34
|
return /*#__PURE__*/_jsxs("div", {
|
|
26
35
|
ref: ref,
|
|
27
|
-
style:
|
|
36
|
+
style: computedStyle,
|
|
28
37
|
role: "tooltip",
|
|
29
38
|
"x-placement": primaryPlacement,
|
|
30
39
|
className: classNames(className, bsPrefix, `bs-tooltip-${bsDirection}`),
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import Transition, { TransitionProps, TransitionStatus } from 'react-transition-group/Transition';
|
|
3
|
-
export
|
|
3
|
+
export type TransitionWrapperProps = TransitionProps & {
|
|
4
4
|
childRef?: React.Ref<unknown>;
|
|
5
5
|
children: React.ReactElement | ((status: TransitionStatus, props: Record<string, unknown>) => React.ReactNode);
|
|
6
6
|
};
|
package/esm/TransitionWrapper.js
CHANGED
|
@@ -18,19 +18,16 @@ const TransitionWrapper = /*#__PURE__*/React.forwardRef(({
|
|
|
18
18
|
}, ref) => {
|
|
19
19
|
const nodeRef = useRef(null);
|
|
20
20
|
const mergedRef = useMergedRefs(nodeRef, childRef);
|
|
21
|
-
|
|
22
21
|
const attachRef = r => {
|
|
23
22
|
mergedRef(safeFindDOMNode(r));
|
|
24
23
|
};
|
|
25
|
-
|
|
26
24
|
const normalize = callback => param => {
|
|
27
25
|
if (callback && nodeRef.current) {
|
|
28
26
|
callback(nodeRef.current, param);
|
|
29
27
|
}
|
|
30
28
|
};
|
|
31
|
-
/* eslint-disable react-hooks/exhaustive-deps */
|
|
32
|
-
|
|
33
29
|
|
|
30
|
+
/* eslint-disable react-hooks/exhaustive-deps */
|
|
34
31
|
const handleEnter = useCallback(normalize(onEnter), [onEnter]);
|
|
35
32
|
const handleEntering = useCallback(normalize(onEntering), [onEntering]);
|
|
36
33
|
const handleEntered = useCallback(normalize(onEntered), [onEntered]);
|
|
@@ -51,7 +48,8 @@ const TransitionWrapper = /*#__PURE__*/React.forwardRef(({
|
|
|
51
48
|
onExiting: handleExiting,
|
|
52
49
|
addEndListener: handleAddEndListener,
|
|
53
50
|
nodeRef: nodeRef,
|
|
54
|
-
children: typeof children === 'function' ? (status, innerProps) => children(status, {
|
|
51
|
+
children: typeof children === 'function' ? (status, innerProps) => children(status, {
|
|
52
|
+
...innerProps,
|
|
55
53
|
ref: attachRef
|
|
56
54
|
}) : /*#__PURE__*/React.cloneElement(children, {
|
|
57
55
|
ref: attachRef
|
|
@@ -12,15 +12,13 @@ function createChainedFunction(...funcs) {
|
|
|
12
12
|
if (typeof f !== 'function') {
|
|
13
13
|
throw new Error('Invalid Argument Type, must only provide functions, undefined, or null.');
|
|
14
14
|
}
|
|
15
|
-
|
|
16
15
|
if (acc === null) return f;
|
|
17
16
|
return function chainedFunction(...args) {
|
|
18
17
|
// @ts-ignore
|
|
19
|
-
acc.apply(this, args);
|
|
20
|
-
|
|
18
|
+
acc.apply(this, args);
|
|
19
|
+
// @ts-ignore
|
|
21
20
|
f.apply(this, args);
|
|
22
21
|
};
|
|
23
22
|
}, null);
|
|
24
23
|
}
|
|
25
|
-
|
|
26
24
|
export default createChainedFunction;
|
|
@@ -17,7 +17,6 @@ export default function createUtilityClassName(utilityValues, breakpoints = DEFA
|
|
|
17
17
|
if (typeof utilValue === 'object') {
|
|
18
18
|
breakpoints.forEach(brkPoint => {
|
|
19
19
|
const bpValue = utilValue[brkPoint];
|
|
20
|
-
|
|
21
20
|
if (bpValue != null) {
|
|
22
21
|
const infix = brkPoint !== minBreakpoint ? `-${brkPoint}` : '';
|
|
23
22
|
classes.push(`${utilName}${infix}-${bpValue}`);
|
|
@@ -3,9 +3,7 @@ import camelize from 'dom-helpers/camelize';
|
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { useBootstrapPrefix } from './ThemeProvider';
|
|
5
5
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
6
|
-
|
|
7
6
|
const pascalCase = str => str[0].toUpperCase() + camelize(str).slice(1);
|
|
8
|
-
|
|
9
7
|
// TODO: emstricten & fix the typing here! `createWithBsPrefix<TElementType>...`
|
|
10
8
|
export default function createWithBsPrefix(prefix, {
|
|
11
9
|
displayName = pascalCase(prefix),
|
package/esm/divWithClassName.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import classNames from 'classnames';
|
|
3
3
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
4
|
-
export default (className => /*#__PURE__*/React.forwardRef((p, ref) => /*#__PURE__*/_jsx("div", {
|
|
4
|
+
export default (className => /*#__PURE__*/React.forwardRef((p, ref) => /*#__PURE__*/_jsx("div", {
|
|
5
|
+
...p,
|
|
5
6
|
ref: ref,
|
|
6
7
|
className: classNames(p.className, className)
|
|
7
8
|
})));
|
package/esm/helpers.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { TransitionComponent } from '@restart/ui/types';
|
|
3
|
-
export
|
|
4
|
-
export
|
|
3
|
+
export type Omit<T, U> = Pick<T, Exclude<keyof T, keyof U>>;
|
|
4
|
+
export type ReplaceProps<Inner extends React.ElementType, P> = Omit<React.ComponentPropsWithRef<Inner>, P> & P;
|
|
5
5
|
export interface BsPrefixOnlyProps {
|
|
6
6
|
bsPrefix?: string;
|
|
7
7
|
}
|
|
@@ -19,6 +19,6 @@ export interface BsPrefixRefForwardingComponent<TInitial extends React.ElementTy
|
|
|
19
19
|
}
|
|
20
20
|
export declare class BsPrefixComponent<As extends React.ElementType, P = unknown> extends React.Component<ReplaceProps<As, BsPrefixProps<As> & P>> {
|
|
21
21
|
}
|
|
22
|
-
export
|
|
23
|
-
export
|
|
22
|
+
export type BsPrefixComponentClass<As extends React.ElementType, P = unknown> = React.ComponentClass<ReplaceProps<As, BsPrefixProps<As> & P>>;
|
|
23
|
+
export type TransitionType = boolean | TransitionComponent;
|
|
24
24
|
export declare function getOverlayDirection(placement: string, isRTL?: boolean): string;
|
package/esm/helpers.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
export class BsPrefixComponent extends React.Component {}
|
|
2
|
+
export class BsPrefixComponent extends React.Component {}
|
|
3
|
+
|
|
4
|
+
// Need to use this instead of typeof Component to get proper type checking.
|
|
3
5
|
|
|
4
6
|
export function getOverlayDirection(placement, isRTL) {
|
|
5
7
|
let bsDirection = placement;
|
|
6
|
-
|
|
7
8
|
if (placement === 'left') {
|
|
8
9
|
bsDirection = isRTL ? 'end' : 'start';
|
|
9
10
|
} else if (placement === 'right') {
|
|
10
11
|
bsDirection = isRTL ? 'start' : 'end';
|
|
11
12
|
}
|
|
12
|
-
|
|
13
13
|
return bsDirection;
|
|
14
14
|
}
|
package/esm/safeFindDOMNode.js
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
import css from 'dom-helpers/css';
|
|
2
2
|
import transitionEnd from 'dom-helpers/transitionEnd';
|
|
3
|
-
|
|
4
3
|
function parseDuration(node, property) {
|
|
5
4
|
const str = css(node, property) || '';
|
|
6
5
|
const mult = str.indexOf('ms') === -1 ? 1000 : 1;
|
|
7
6
|
return parseFloat(str) * mult;
|
|
8
7
|
}
|
|
9
|
-
|
|
10
8
|
export default function transitionEndListener(element, handler) {
|
|
11
9
|
const duration = parseDuration(element, 'transitionDuration');
|
|
12
10
|
const delay = parseDuration(element, 'transitionDelay');
|
package/esm/types.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import PropTypes from 'prop-types';
|
|
2
|
-
import { State } from '@restart/ui/usePopper';
|
|
3
|
-
export
|
|
4
|
-
export
|
|
5
|
-
export
|
|
6
|
-
export
|
|
7
|
-
export
|
|
8
|
-
export
|
|
2
|
+
import { State, UsePopperOptions } from '@restart/ui/usePopper';
|
|
3
|
+
export type Variant = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | 'dark' | 'light' | string;
|
|
4
|
+
export type ButtonVariant = Variant | 'link' | 'outline-primary' | 'outline-secondary' | 'outline-success' | 'outline-danger' | 'outline-warning' | 'outline-info' | 'outline-dark' | 'outline-light';
|
|
5
|
+
export type Color = 'primary' | 'secondary' | 'success' | 'danger' | 'warning' | 'info' | 'dark' | 'light' | 'white' | 'muted';
|
|
6
|
+
export type Placement = import('@restart/ui/usePopper').Placement;
|
|
7
|
+
export type AlignDirection = 'start' | 'end';
|
|
8
|
+
export type ResponsiveAlignProp = {
|
|
9
9
|
sm: AlignDirection;
|
|
10
10
|
} | {
|
|
11
11
|
md: AlignDirection;
|
|
@@ -16,13 +16,14 @@ export declare type ResponsiveAlignProp = {
|
|
|
16
16
|
} | {
|
|
17
17
|
xxl: AlignDirection;
|
|
18
18
|
} | Record<string, AlignDirection>;
|
|
19
|
-
export
|
|
19
|
+
export type AlignType = AlignDirection | ResponsiveAlignProp;
|
|
20
20
|
export declare const alignPropType: PropTypes.Requireable<NonNullable<object | AlignDirection | null | undefined>>;
|
|
21
|
-
export
|
|
22
|
-
export
|
|
21
|
+
export type RootCloseEvent = 'click' | 'mousedown';
|
|
22
|
+
export type GapValue = 0 | 1 | 2 | 3 | 4 | 5;
|
|
23
23
|
export interface PopperRef {
|
|
24
24
|
state: State | undefined;
|
|
25
25
|
outOfBoundaries: boolean;
|
|
26
26
|
placement: Placement | undefined;
|
|
27
27
|
scheduleUpdate?: () => void;
|
|
28
|
+
strategy: UsePopperOptions['strategy'];
|
|
28
29
|
}
|
package/esm/useOverlayOffset.js
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { useMemo, useRef } from 'react';
|
|
2
2
|
import hasClass from 'dom-helpers/hasClass';
|
|
3
3
|
import { useBootstrapPrefix } from './ThemeProvider';
|
|
4
|
-
import Popover from './Popover';
|
|
5
|
-
// This applies a custom offset to the overlay if it's a popover.
|
|
4
|
+
import Popover from './Popover';
|
|
6
5
|
|
|
6
|
+
// This is meant for internal use.
|
|
7
|
+
// This applies a custom offset to the overlay if it's a popover.
|
|
7
8
|
export default function useOverlayOffset(customOffset) {
|
|
8
9
|
const overlayRef = useRef(null);
|
|
9
10
|
const popoverClass = useBootstrapPrefix(undefined, 'popover');
|
|
@@ -14,7 +15,6 @@ export default function useOverlayOffset(customOffset) {
|
|
|
14
15
|
if (overlayRef.current && hasClass(overlayRef.current, popoverClass)) {
|
|
15
16
|
return customOffset || Popover.POPPER_OFFSET;
|
|
16
17
|
}
|
|
17
|
-
|
|
18
18
|
return customOffset || [0, 0];
|
|
19
19
|
}
|
|
20
20
|
}
|
package/esm/usePlaceholder.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ColProps } from './Col';
|
|
2
2
|
import { Variant } from './types';
|
|
3
|
-
export
|
|
4
|
-
export
|
|
3
|
+
export type PlaceholderAnimation = 'glow' | 'wave';
|
|
4
|
+
export type PlaceholderSize = 'xs' | 'sm' | 'lg';
|
|
5
5
|
export interface UsePlaceholderProps extends Omit<ColProps, 'as'> {
|
|
6
6
|
animation?: PlaceholderAnimation;
|
|
7
7
|
bg?: Variant;
|
package/esm/usePlaceholder.js
CHANGED
|
@@ -13,7 +13,8 @@ export default function usePlaceholder({
|
|
|
13
13
|
className,
|
|
14
14
|
...colProps
|
|
15
15
|
}] = useCol(props);
|
|
16
|
-
return {
|
|
16
|
+
return {
|
|
17
|
+
...colProps,
|
|
17
18
|
className: classNames(className, animation ? `${bsPrefix}-${animation}` : bsPrefix, size && `${bsPrefix}-${size}`, bg && `bg-${bg}`)
|
|
18
19
|
};
|
|
19
20
|
}
|
|
@@ -3,11 +3,12 @@ import { useCallback } from 'react';
|
|
|
3
3
|
import useMergedRefs from '@restart/hooks/useMergedRefs';
|
|
4
4
|
export default function useWrappedRefWithWarning(ref, componentName) {
|
|
5
5
|
// @ts-ignore
|
|
6
|
-
if (!(process.env.NODE_ENV !== "production")) return ref;
|
|
6
|
+
if (!(process.env.NODE_ENV !== "production")) return ref;
|
|
7
7
|
|
|
8
|
+
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
8
9
|
const warningRef = useCallback(refValue => {
|
|
9
10
|
!(refValue == null || !refValue.isReactComponent) ? process.env.NODE_ENV !== "production" ? invariant(false, `${componentName} injected a ref to a provided \`as\` component that resolved to a component instance instead of a DOM element. ` + 'Use `React.forwardRef` to provide the injected ref to the class component as a prop in order to pass it directly to a DOM element') : invariant(false) : void 0;
|
|
10
|
-
}, [componentName]);
|
|
11
|
-
|
|
11
|
+
}, [componentName]);
|
|
12
|
+
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
12
13
|
return useMergedRefs(warningRef, ref);
|
|
13
14
|
}
|
package/package.json
CHANGED
package/cjs/AbstractNav.d.ts
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
-
interface AbstractNavProps {
|
|
4
|
-
activeKey?: any;
|
|
5
|
-
as?: React.ElementType;
|
|
6
|
-
getControlledId?: any;
|
|
7
|
-
getControllerId?: any;
|
|
8
|
-
onKeyDown?: any;
|
|
9
|
-
onSelect?: any;
|
|
10
|
-
parentOnSelect?: any;
|
|
11
|
-
role?: string;
|
|
12
|
-
}
|
|
13
|
-
declare type AbstractNav = BsPrefixRefForwardingComponent<'ul', AbstractNavProps>;
|
|
14
|
-
declare const AbstractNav: AbstractNav;
|
|
15
|
-
export default AbstractNav;
|
package/cjs/AbstractNavItem.d.ts
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
-
import { EventKey } from './types';
|
|
4
|
-
interface AbstractNavItemProps {
|
|
5
|
-
active?: boolean;
|
|
6
|
-
as: React.ElementType;
|
|
7
|
-
className?: string;
|
|
8
|
-
disabled?: boolean;
|
|
9
|
-
eventKey?: EventKey;
|
|
10
|
-
href?: string;
|
|
11
|
-
role?: string;
|
|
12
|
-
id?: string;
|
|
13
|
-
tabIndex?: number;
|
|
14
|
-
onClick?: (e: any) => void;
|
|
15
|
-
onSelect?: (navKey: string, e: any) => void;
|
|
16
|
-
}
|
|
17
|
-
declare type AbstractNavItem = BsPrefixRefForwardingComponent<'div', AbstractNavItemProps>;
|
|
18
|
-
declare const AbstractNavItem: AbstractNavItem;
|
|
19
|
-
export default AbstractNavItem;
|
package/cjs/AccordionToggle.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { BsPrefixPropsWithChildren, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
-
declare type EventHandler = React.EventHandler<React.SyntheticEvent>;
|
|
4
|
-
export interface AccordionToggleProps extends BsPrefixPropsWithChildren {
|
|
5
|
-
eventKey: string;
|
|
6
|
-
onClick?: EventHandler;
|
|
7
|
-
}
|
|
8
|
-
declare type AccordionToggle = BsPrefixRefForwardingComponent<'div', AccordionToggleProps>;
|
|
9
|
-
export declare function useAccordionToggle(eventKey: string, onClick?: EventHandler): EventHandler;
|
|
10
|
-
declare const AccordionToggle: AccordionToggle;
|
|
11
|
-
export default AccordionToggle;
|
package/cjs/CardColumns.d.ts
DELETED
package/cjs/CardContext.d.ts
DELETED
package/cjs/CardDeck.d.ts
DELETED
package/cjs/FormFile.d.ts
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import FormFileInput from './FormFileInput';
|
|
3
|
-
import FormFileLabel from './FormFileLabel';
|
|
4
|
-
import { BsCustomPrefixProps, BsPrefixPropsWithChildren, BsPrefixRefForwardingComponent } from './helpers';
|
|
5
|
-
export interface FormFileProps extends BsPrefixPropsWithChildren, BsCustomPrefixProps, Pick<React.HTMLAttributes<HTMLElement>, 'style'> {
|
|
6
|
-
inputAs?: React.ElementType;
|
|
7
|
-
id?: string;
|
|
8
|
-
disabled?: boolean;
|
|
9
|
-
label?: React.ReactNode;
|
|
10
|
-
custom?: boolean;
|
|
11
|
-
isValid?: boolean;
|
|
12
|
-
isInvalid?: boolean;
|
|
13
|
-
feedback?: React.ReactNode;
|
|
14
|
-
feedbackTooltip?: boolean;
|
|
15
|
-
lang?: string;
|
|
16
|
-
'data-browse'?: any;
|
|
17
|
-
}
|
|
18
|
-
declare type FormFile = BsPrefixRefForwardingComponent<'input', FormFileProps> & {
|
|
19
|
-
Input: typeof FormFileInput;
|
|
20
|
-
Label: typeof FormFileLabel;
|
|
21
|
-
};
|
|
22
|
-
declare const FormFile: FormFile;
|
|
23
|
-
export default FormFile;
|
package/cjs/FormFileInput.d.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { BsCustomPrefixProps, BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
2
|
-
export interface FormFileInputProps extends BsPrefixProps, BsCustomPrefixProps {
|
|
3
|
-
id?: string;
|
|
4
|
-
isValid?: boolean;
|
|
5
|
-
isInvalid?: boolean;
|
|
6
|
-
lang?: string;
|
|
7
|
-
}
|
|
8
|
-
declare type FormFileInput = BsPrefixRefForwardingComponent<'input', FormFileInputProps>;
|
|
9
|
-
declare const FormFileInput: FormFileInput;
|
|
10
|
-
export default FormFileInput;
|
package/cjs/FormFileLabel.d.ts
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { BsCustomPrefixProps, BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
2
|
-
export interface FormFileLabelProps extends BsPrefixProps, BsCustomPrefixProps {
|
|
3
|
-
htmlFor?: string;
|
|
4
|
-
}
|
|
5
|
-
declare type FormFileLabel = BsPrefixRefForwardingComponent<'label', FormFileLabelProps>;
|
|
6
|
-
declare const FormFileLabel: FormFileLabel;
|
|
7
|
-
export default FormFileLabel;
|
package/cjs/Jumbotron.d.ts
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
2
|
-
export interface JumbotronProps extends BsPrefixProps {
|
|
3
|
-
fluid?: boolean;
|
|
4
|
-
}
|
|
5
|
-
declare type Jumbotron = BsPrefixRefForwardingComponent<'div', JumbotronProps>;
|
|
6
|
-
declare const Jumbotron: Jumbotron;
|
|
7
|
-
export default Jumbotron;
|
package/cjs/Media.d.ts
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
2
|
-
declare const MediaBody: BsPrefixRefForwardingComponent<"div", unknown>;
|
|
3
|
-
declare type MediaProps = BsPrefixProps;
|
|
4
|
-
declare type Media = BsPrefixRefForwardingComponent<'div', MediaProps> & {
|
|
5
|
-
Body: typeof MediaBody;
|
|
6
|
-
};
|
|
7
|
-
declare const Media: Media;
|
|
8
|
-
export default Media;
|
package/cjs/PopoverContent.d.ts
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { BsPrefixPropsWithChildren, BsPrefixRefForwardingComponent } from './helpers';
|
|
2
|
-
declare type PopoverContentProps = BsPrefixPropsWithChildren;
|
|
3
|
-
declare type PopoverContent = BsPrefixRefForwardingComponent<'div', PopoverContentProps>;
|
|
4
|
-
declare const PopoverContent: PopoverContent;
|
|
5
|
-
export default PopoverContent;
|
package/cjs/PopoverTitle.d.ts
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { BsPrefixPropsWithChildren, BsPrefixRefForwardingComponent } from './helpers';
|
|
2
|
-
declare type PopoverTitleProps = BsPrefixPropsWithChildren;
|
|
3
|
-
declare type PopoverTitle = BsPrefixRefForwardingComponent<'div', PopoverTitleProps>;
|
|
4
|
-
declare const PopoverTitle: PopoverTitle;
|
|
5
|
-
export default PopoverTitle;
|
package/cjs/ResponsiveEmbed.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { BsPrefixPropsWithChildren, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
-
export interface ResponsiveEmbedProps extends BsPrefixPropsWithChildren {
|
|
4
|
-
children: React.ReactChild;
|
|
5
|
-
aspectRatio?: '21by9' | '16by9' | '4by3' | '1by1';
|
|
6
|
-
}
|
|
7
|
-
declare type ResponsiveEmbed = BsPrefixRefForwardingComponent<'div', ResponsiveEmbedProps>;
|
|
8
|
-
declare const ResponsiveEmbed: ResponsiveEmbed;
|
|
9
|
-
export default ResponsiveEmbed;
|
package/cjs/SafeAnchor.d.ts
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
-
export interface SafeAnchorProps extends React.HTMLAttributes<HTMLElement>, BsPrefixProps {
|
|
4
|
-
href?: string;
|
|
5
|
-
disabled?: boolean;
|
|
6
|
-
tabIndex?: number;
|
|
7
|
-
}
|
|
8
|
-
declare type SafeAnchor = BsPrefixRefForwardingComponent<'a', SafeAnchorProps>;
|
|
9
|
-
/**
|
|
10
|
-
* There are situations due to browser quirks or Bootstrap CSS where
|
|
11
|
-
* an anchor tag is needed, when semantically a button tag is the
|
|
12
|
-
* better choice. SafeAnchor ensures that when an anchor is used like a
|
|
13
|
-
* button its accessible. It also emulates input `disabled` behavior for
|
|
14
|
-
* links, which is usually desirable for Buttons, NavItems, DropdownItems, etc.
|
|
15
|
-
*/
|
|
16
|
-
declare const SafeAnchor: SafeAnchor;
|
|
17
|
-
export default SafeAnchor;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
declare type SelectableContextType = (key: string | null, event: any) => void;
|
|
3
|
-
declare const SelectableContext: React.Context<SelectableContextType | null>;
|
|
4
|
-
export declare const makeEventKey: (eventKey?: string | number | null | undefined, href?: string | null) => string | null;
|
|
5
|
-
export default SelectableContext;
|