react-bootstrap 1.6.0 → 1.6.4
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/AbstractNav.js +3 -1
- package/cjs/AbstractNavItem.js +3 -1
- package/cjs/Accordion.js +3 -1
- package/cjs/AccordionCollapse.js +3 -1
- package/cjs/AccordionToggle.js +3 -1
- package/cjs/Alert.js +2 -1
- package/cjs/Anchor.d.ts +3 -0
- package/cjs/Badge.js +2 -1
- package/cjs/Breadcrumb.js +2 -1
- package/cjs/BreadcrumbItem.js +2 -1
- package/cjs/Button.js +2 -1
- package/cjs/ButtonGroup.js +2 -1
- package/cjs/ButtonToolbar.js +2 -1
- package/cjs/Card.js +3 -1
- package/cjs/CardImg.js +2 -1
- package/cjs/Carousel.js +3 -1
- package/cjs/CarouselItem.js +3 -1
- package/cjs/CloseButton.js +2 -1
- package/cjs/Col.js +2 -1
- package/cjs/Collapse.d.ts +1 -2
- package/cjs/Collapse.js +3 -1
- package/cjs/Container.js +2 -1
- package/cjs/Dropdown.js +3 -1
- package/cjs/DropdownButton.js +3 -1
- package/cjs/DropdownContext.d.ts +10 -0
- package/cjs/DropdownItem.js +3 -1
- package/cjs/DropdownMenu.js +3 -1
- package/cjs/DropdownToggle.js +3 -1
- package/cjs/Fade.js +3 -1
- package/cjs/Feedback.js +2 -1
- package/cjs/FigureImage.js +3 -1
- package/cjs/FloatingLabel.d.ts +9 -0
- package/cjs/Form.js +2 -1
- package/cjs/FormCheck.js +3 -1
- package/cjs/FormCheckInput.js +3 -1
- package/cjs/FormCheckLabel.js +3 -1
- package/cjs/FormControl.js +3 -1
- package/cjs/FormFile.js +3 -1
- package/cjs/FormFileInput.js +3 -1
- package/cjs/FormFileLabel.js +3 -1
- package/cjs/FormFloating.d.ts +2 -0
- package/cjs/FormGroup.js +3 -1
- package/cjs/FormLabel.js +4 -1
- package/cjs/FormText.js +3 -1
- package/cjs/Image.js +2 -1
- package/cjs/InputGroup.d.ts +5 -7
- package/cjs/InputGroup.js +8 -9
- package/cjs/InputGroupContext.d.ts +3 -0
- package/cjs/Jumbotron.js +2 -1
- package/cjs/ListGroup.js +2 -1
- package/cjs/ListGroupItem.js +3 -1
- package/cjs/Media.js +2 -1
- package/cjs/Modal.d.ts +3 -2
- package/cjs/Modal.js +19 -32
- package/cjs/ModalDialog.js +3 -1
- package/cjs/ModalHeader.js +3 -1
- package/cjs/Nav.js +3 -1
- package/cjs/NavDropdown.js +3 -1
- package/cjs/NavItem.js +3 -1
- package/cjs/NavLink.js +2 -1
- package/cjs/Navbar.js +3 -1
- package/cjs/NavbarBrand.js +3 -1
- package/cjs/NavbarCollapse.js +3 -1
- package/cjs/NavbarToggle.js +3 -1
- package/cjs/Offcanvas.d.ts +2 -2
- package/cjs/OffcanvasToggling.d.ts +2 -1
- package/cjs/Overlay.js +5 -2
- package/cjs/OverlayTrigger.js +3 -1
- package/cjs/PageItem.js +4 -3
- package/cjs/Pagination.js +3 -1
- package/cjs/Placeholder.d.ts +8 -0
- package/cjs/PlaceholderButton.d.ts +8 -0
- package/cjs/Popover.js +2 -1
- package/cjs/PopoverContent.js +3 -1
- package/cjs/PopoverTitle.js +3 -1
- package/cjs/ProgressBar.js +7 -3
- package/cjs/Ratio.d.ts +9 -0
- package/cjs/ResponsiveEmbed.js +2 -1
- package/cjs/Row.js +2 -1
- package/cjs/SSRProvider.d.ts +4 -0
- package/cjs/SafeAnchor.d.ts +0 -1
- package/cjs/SafeAnchor.js +3 -1
- package/cjs/Spinner.d.ts +0 -1
- package/cjs/Spinner.js +3 -1
- package/cjs/SplitButton.js +2 -1
- package/cjs/Stack.d.ts +11 -0
- package/cjs/TabContent.js +3 -1
- package/cjs/TabPane.js +5 -2
- package/cjs/Table.js +3 -1
- package/cjs/Tabs.js +2 -1
- package/cjs/Toast.js +3 -1
- package/cjs/ToastFade.d.ts +5 -0
- package/cjs/ToastHeader.js +3 -1
- package/cjs/ToggleButton.js +3 -1
- package/cjs/ToggleButtonGroup.js +2 -1
- package/cjs/Tooltip.js +2 -1
- package/cjs/createUtilityClasses.d.ts +12 -0
- package/cjs/createWithBsPrefix.js +3 -1
- package/cjs/getTabTransitionComponent.d.ts +3 -0
- package/cjs/safeFindDOMNode.d.ts +2 -0
- package/cjs/types.js +3 -1
- package/cjs/useOverlayOffset.d.ts +1 -1
- package/cjs/usePlaceholder.d.ts +10 -0
- package/cjs/usePopperMarginModifiers.js +3 -0
- package/dist/react-bootstrap.js +642 -461
- package/dist/react-bootstrap.min.js +1 -1
- package/dist/react-bootstrap.min.js.LICENSE.txt +1 -1
- package/esm/AbstractNav.js +2 -1
- package/esm/AbstractNavItem.js +2 -1
- package/esm/Accordion.js +2 -1
- package/esm/AccordionCollapse.js +2 -1
- package/esm/AccordionToggle.js +2 -1
- package/esm/Alert.js +2 -1
- package/esm/Anchor.d.ts +3 -0
- package/esm/Badge.js +2 -1
- package/esm/Breadcrumb.js +2 -1
- package/esm/BreadcrumbItem.js +2 -1
- package/esm/Button.js +2 -1
- package/esm/ButtonGroup.js +2 -1
- package/esm/ButtonToolbar.js +2 -1
- package/esm/Card.js +2 -1
- package/esm/CardImg.js +2 -1
- package/esm/Carousel.js +2 -1
- package/esm/CarouselItem.js +2 -1
- package/esm/CloseButton.js +2 -1
- package/esm/Col.js +2 -1
- package/esm/Collapse.d.ts +1 -2
- package/esm/Collapse.js +2 -1
- package/esm/Container.js +2 -1
- package/esm/Dropdown.js +2 -1
- package/esm/DropdownButton.js +2 -1
- package/esm/DropdownContext.d.ts +10 -0
- package/esm/DropdownItem.js +2 -1
- package/esm/DropdownMenu.js +2 -1
- package/esm/DropdownToggle.js +2 -1
- package/esm/Fade.js +2 -1
- package/esm/Feedback.js +2 -1
- package/esm/FigureImage.js +2 -1
- package/esm/FloatingLabel.d.ts +9 -0
- package/esm/Form.js +2 -1
- package/esm/FormCheck.js +2 -1
- package/esm/FormCheckInput.js +2 -1
- package/esm/FormCheckLabel.js +2 -1
- package/esm/FormControl.js +2 -1
- package/esm/FormFile.js +2 -1
- package/esm/FormFileInput.js +2 -1
- package/esm/FormFileLabel.js +2 -1
- package/esm/FormFloating.d.ts +2 -0
- package/esm/FormGroup.js +2 -1
- package/esm/FormLabel.js +3 -1
- package/esm/FormText.js +2 -1
- package/esm/Image.js +2 -1
- package/esm/InputGroup.d.ts +5 -7
- package/esm/InputGroup.js +8 -11
- package/esm/InputGroupContext.d.ts +3 -0
- package/esm/Jumbotron.js +2 -1
- package/esm/ListGroup.js +2 -1
- package/esm/ListGroupItem.js +2 -1
- package/esm/Media.js +2 -1
- package/esm/Modal.d.ts +3 -2
- package/esm/Modal.js +17 -31
- package/esm/ModalDialog.js +2 -1
- package/esm/ModalHeader.js +2 -1
- package/esm/Nav.js +2 -1
- package/esm/NavDropdown.js +2 -1
- package/esm/NavItem.js +2 -1
- package/esm/NavLink.js +2 -1
- package/esm/Navbar.js +2 -1
- package/esm/NavbarBrand.js +2 -1
- package/esm/NavbarCollapse.js +2 -1
- package/esm/NavbarToggle.js +2 -1
- package/esm/Offcanvas.d.ts +2 -2
- package/esm/OffcanvasToggling.d.ts +2 -1
- package/esm/Overlay.js +4 -2
- package/esm/OverlayTrigger.js +2 -1
- package/esm/PageItem.js +4 -2
- package/esm/Pagination.js +2 -1
- package/esm/Placeholder.d.ts +8 -0
- package/esm/PlaceholderButton.d.ts +8 -0
- package/esm/Popover.js +2 -1
- package/esm/PopoverContent.js +2 -1
- package/esm/PopoverTitle.js +2 -1
- package/esm/ProgressBar.js +6 -3
- package/esm/Ratio.d.ts +9 -0
- package/esm/ResponsiveEmbed.js +2 -1
- package/esm/Row.js +2 -1
- package/esm/SSRProvider.d.ts +4 -0
- package/esm/SafeAnchor.d.ts +0 -1
- package/esm/SafeAnchor.js +2 -1
- package/esm/Spinner.d.ts +0 -1
- package/esm/Spinner.js +2 -1
- package/esm/SplitButton.js +2 -1
- package/esm/Stack.d.ts +11 -0
- package/esm/TabContent.js +2 -1
- package/esm/TabPane.js +4 -2
- package/esm/Table.js +2 -1
- package/esm/Tabs.js +2 -1
- package/esm/Toast.js +2 -1
- package/esm/ToastFade.d.ts +5 -0
- package/esm/ToastHeader.js +2 -1
- package/esm/ToggleButton.js +2 -1
- package/esm/ToggleButtonGroup.js +2 -1
- package/esm/Tooltip.js +2 -1
- package/esm/createUtilityClasses.d.ts +12 -0
- package/esm/createWithBsPrefix.js +2 -1
- package/esm/getTabTransitionComponent.d.ts +3 -0
- package/esm/safeFindDOMNode.d.ts +2 -0
- package/esm/types.js +1 -0
- package/esm/useOverlayOffset.d.ts +1 -1
- package/esm/usePlaceholder.d.ts +10 -0
- package/esm/usePopperMarginModifiers.js +3 -0
- package/package.json +6 -7
package/cjs/ToggleButton.js
CHANGED
|
@@ -15,6 +15,8 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
15
15
|
|
|
16
16
|
var _Button = _interopRequireDefault(require("./Button"));
|
|
17
17
|
|
|
18
|
+
var _excluded = ["children", "name", "className", "checked", "type", "onChange", "value", "disabled", "inputRef"];
|
|
19
|
+
|
|
18
20
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
19
21
|
|
|
20
22
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
@@ -33,7 +35,7 @@ var ToggleButton = /*#__PURE__*/_react.default.forwardRef(function (_ref, ref) {
|
|
|
33
35
|
value = _ref.value,
|
|
34
36
|
disabled = _ref.disabled,
|
|
35
37
|
inputRef = _ref.inputRef,
|
|
36
|
-
props = (0, _objectWithoutPropertiesLoose2.default)(_ref,
|
|
38
|
+
props = (0, _objectWithoutPropertiesLoose2.default)(_ref, _excluded);
|
|
37
39
|
|
|
38
40
|
var _useState = (0, _react.useState)(false),
|
|
39
41
|
focused = _useState[0],
|
package/cjs/ToggleButtonGroup.js
CHANGED
|
@@ -23,6 +23,7 @@ var _ButtonGroup = _interopRequireDefault(require("./ButtonGroup"));
|
|
|
23
23
|
|
|
24
24
|
var _ToggleButton = _interopRequireDefault(require("./ToggleButton"));
|
|
25
25
|
|
|
26
|
+
var _excluded = ["children", "type", "name", "value", "onChange"];
|
|
26
27
|
var defaultProps = {
|
|
27
28
|
type: 'radio',
|
|
28
29
|
vertical: false
|
|
@@ -37,7 +38,7 @@ var ToggleButtonGroup = /*#__PURE__*/_react.default.forwardRef(function (props,
|
|
|
37
38
|
name = _useUncontrolled.name,
|
|
38
39
|
value = _useUncontrolled.value,
|
|
39
40
|
onChange = _useUncontrolled.onChange,
|
|
40
|
-
controlledProps = (0, _objectWithoutPropertiesLoose2.default)(_useUncontrolled,
|
|
41
|
+
controlledProps = (0, _objectWithoutPropertiesLoose2.default)(_useUncontrolled, _excluded);
|
|
41
42
|
|
|
42
43
|
var getValues = function getValues() {
|
|
43
44
|
return value == null ? [] : [].concat(value);
|
package/cjs/Tooltip.js
CHANGED
|
@@ -17,6 +17,7 @@ var _isRequiredForA11y = _interopRequireDefault(require("prop-types-extra/lib/is
|
|
|
17
17
|
|
|
18
18
|
var _ThemeProvider = require("./ThemeProvider");
|
|
19
19
|
|
|
20
|
+
var _excluded = ["bsPrefix", "placement", "className", "style", "children", "arrowProps", "popper", "show"];
|
|
20
21
|
var defaultProps = {
|
|
21
22
|
placement: 'right'
|
|
22
23
|
};
|
|
@@ -30,7 +31,7 @@ var Tooltip = /*#__PURE__*/_react.default.forwardRef(function (_ref, ref) {
|
|
|
30
31
|
arrowProps = _ref.arrowProps,
|
|
31
32
|
_ = _ref.popper,
|
|
32
33
|
_2 = _ref.show,
|
|
33
|
-
props = (0, _objectWithoutPropertiesLoose2.default)(_ref,
|
|
34
|
+
props = (0, _objectWithoutPropertiesLoose2.default)(_ref, _excluded);
|
|
34
35
|
bsPrefix = (0, _ThemeProvider.useBootstrapPrefix)(bsPrefix, 'tooltip');
|
|
35
36
|
|
|
36
37
|
var _ref2 = (placement == null ? void 0 : placement.split('-')) || [],
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import PropTypes from 'prop-types';
|
|
2
|
+
export declare type ResponsiveUtilityValue<T> = T | {
|
|
3
|
+
xs?: T;
|
|
4
|
+
sm?: T;
|
|
5
|
+
md?: T;
|
|
6
|
+
lg?: T;
|
|
7
|
+
xl?: T;
|
|
8
|
+
xxl?: T;
|
|
9
|
+
};
|
|
10
|
+
export declare function responsivePropType(propType: any): PropTypes.Requireable<any>;
|
|
11
|
+
export declare const DEVICE_SIZES: readonly ["xxl", "xl", "lg", "md", "sm", "xs"];
|
|
12
|
+
export default function createUtilityClassName(utilityValues: Record<string, ResponsiveUtilityValue<unknown>>): string[];
|
|
@@ -17,6 +17,8 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
17
17
|
|
|
18
18
|
var _ThemeProvider = require("./ThemeProvider");
|
|
19
19
|
|
|
20
|
+
var _excluded = ["className", "bsPrefix", "as"];
|
|
21
|
+
|
|
20
22
|
var pascalCase = function pascalCase(str) {
|
|
21
23
|
return str[0].toUpperCase() + (0, _camelize.default)(str).slice(1);
|
|
22
24
|
};
|
|
@@ -34,7 +36,7 @@ function createWithBsPrefix(prefix, _temp) {
|
|
|
34
36
|
bsPrefix = _ref2.bsPrefix,
|
|
35
37
|
_ref2$as = _ref2.as,
|
|
36
38
|
Tag = _ref2$as === void 0 ? Component || 'div' : _ref2$as,
|
|
37
|
-
props = (0, _objectWithoutPropertiesLoose2.default)(_ref2,
|
|
39
|
+
props = (0, _objectWithoutPropertiesLoose2.default)(_ref2, _excluded);
|
|
38
40
|
var resolvedPrefix = (0, _ThemeProvider.useBootstrapPrefix)(bsPrefix, prefix);
|
|
39
41
|
return /*#__PURE__*/_react.default.createElement(Tag, (0, _extends2.default)({
|
|
40
42
|
ref: ref,
|
package/cjs/types.js
CHANGED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ColProps } from './Col';
|
|
2
|
+
import { Variant } from './types';
|
|
3
|
+
export declare type PlaceholderAnimation = 'glow' | 'wave';
|
|
4
|
+
export declare type PlaceholderSize = 'xs' | 'sm' | 'lg';
|
|
5
|
+
export interface UsePlaceholderProps extends Omit<ColProps, 'as'> {
|
|
6
|
+
animation?: PlaceholderAnimation;
|
|
7
|
+
bg?: Variant;
|
|
8
|
+
size?: PlaceholderSize;
|
|
9
|
+
}
|
|
10
|
+
export default function usePlaceholder({ animation, bg, bsPrefix, size, ...props }: UsePlaceholderProps): any;
|
|
@@ -101,6 +101,9 @@ function usePopperMarginModifiers() {
|
|
|
101
101
|
name: 'popoverArrowMargins',
|
|
102
102
|
enabled: true,
|
|
103
103
|
phase: 'main',
|
|
104
|
+
fn: function fn() {
|
|
105
|
+
return undefined;
|
|
106
|
+
},
|
|
104
107
|
requiresIfExists: ['arrow'],
|
|
105
108
|
effect: function effect(_ref2) {
|
|
106
109
|
var state = _ref2.state;
|