react-bootstrap 2.8.0 → 2.9.0-beta.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/AlertHeading/package.json +7 -0
- package/AlertLink/package.json +7 -0
- package/CardBody/package.json +7 -0
- package/CardFooter/package.json +7 -0
- package/CardImgOverlay/package.json +7 -0
- package/CardLink/package.json +7 -0
- package/CardSubtitle/package.json +7 -0
- package/CardText/package.json +7 -0
- package/CardTitle/package.json +7 -0
- package/DropdownDivider/package.json +7 -0
- package/DropdownHeader/package.json +7 -0
- package/DropdownItemText/package.json +7 -0
- package/InputGroupText/package.json +7 -0
- package/NavbarText/package.json +7 -0
- package/cjs/AbstractModalHeader.js +1 -0
- package/cjs/Accordion.js +1 -0
- package/cjs/AccordionBody.js +1 -0
- package/cjs/AccordionButton.js +1 -0
- package/cjs/AccordionCollapse.js +1 -0
- package/cjs/AccordionContext.js +1 -0
- package/cjs/AccordionHeader.js +1 -0
- package/cjs/AccordionItem.js +1 -0
- package/cjs/AccordionItemContext.js +1 -0
- package/cjs/Alert.d.ts +2 -2
- package/cjs/Alert.js +5 -13
- package/cjs/AlertHeading.d.ts +6 -0
- package/cjs/AlertHeading.js +32 -0
- package/cjs/AlertLink.d.ts +6 -0
- package/cjs/AlertLink.js +30 -0
- package/cjs/Badge.js +1 -0
- package/cjs/Breadcrumb.js +1 -0
- package/cjs/BreadcrumbItem.js +1 -0
- package/cjs/Button.js +1 -0
- package/cjs/ButtonGroup.js +1 -0
- package/cjs/ButtonToolbar.js +1 -0
- package/cjs/Card.d.ts +7 -7
- package/cjs/Card.js +17 -28
- package/cjs/CardBody.d.ts +6 -0
- package/cjs/CardBody.js +29 -0
- package/cjs/CardFooter.d.ts +6 -0
- package/cjs/CardFooter.js +29 -0
- package/cjs/CardGroup.d.ts +6 -2
- package/cjs/CardGroup.js +22 -2
- package/cjs/CardHeader.js +1 -0
- package/cjs/CardHeaderContext.js +1 -0
- package/cjs/CardImg.js +1 -0
- package/cjs/CardImgOverlay.d.ts +6 -0
- package/cjs/CardImgOverlay.js +29 -0
- package/cjs/CardLink.d.ts +6 -0
- package/cjs/CardLink.js +29 -0
- package/cjs/CardSubtitle.d.ts +6 -0
- package/cjs/CardSubtitle.js +31 -0
- package/cjs/CardText.d.ts +6 -0
- package/cjs/CardText.js +29 -0
- package/cjs/CardTitle.d.ts +6 -0
- package/cjs/CardTitle.js +31 -0
- package/cjs/Carousel.d.ts +1 -1
- package/cjs/Carousel.js +1 -0
- package/cjs/CarouselCaption.d.ts +6 -2
- package/cjs/CarouselCaption.js +22 -2
- package/cjs/CarouselItem.js +1 -0
- package/cjs/Col.js +1 -0
- package/cjs/Container.js +1 -0
- package/cjs/Dropdown.d.ts +4 -4
- package/cjs/Dropdown.js +7 -18
- package/cjs/DropdownContext.js +1 -0
- package/cjs/DropdownDivider.d.ts +6 -0
- package/cjs/DropdownDivider.js +31 -0
- package/cjs/DropdownHeader.d.ts +6 -0
- package/cjs/DropdownHeader.js +31 -0
- package/cjs/DropdownItem.d.ts +2 -2
- package/cjs/DropdownItem.js +1 -0
- package/cjs/DropdownItemText.d.ts +6 -0
- package/cjs/DropdownItemText.js +29 -0
- package/cjs/DropdownMenu.js +1 -0
- package/cjs/DropdownToggle.js +1 -0
- package/cjs/Figure.d.ts +7 -4
- package/cjs/Figure.js +20 -3
- package/cjs/FigureCaption.d.ts +5 -1
- package/cjs/FigureCaption.js +20 -3
- package/cjs/FloatingLabel.js +1 -0
- package/cjs/Form.d.ts +1 -1
- package/cjs/FormCheck.js +1 -0
- package/cjs/FormCheckInput.js +1 -0
- package/cjs/FormCheckLabel.js +1 -0
- package/cjs/FormContext.js +1 -0
- package/cjs/FormControl.js +2 -12
- package/cjs/FormFloating.d.ts +6 -2
- package/cjs/FormFloating.js +22 -2
- package/cjs/FormLabel.js +1 -0
- package/cjs/FormRange.js +1 -0
- package/cjs/FormSelect.js +1 -0
- package/cjs/FormText.js +1 -0
- package/cjs/Image.js +1 -0
- package/cjs/InputGroup.d.ts +4 -3
- package/cjs/InputGroup.js +5 -7
- package/cjs/InputGroupContext.js +1 -0
- package/cjs/InputGroupText.d.ts +6 -0
- package/cjs/InputGroupText.js +29 -0
- package/cjs/ListGroup.js +1 -0
- package/cjs/ListGroupItem.js +1 -0
- package/cjs/Modal.d.ts +3 -3
- package/cjs/Modal.js +1 -0
- package/cjs/ModalBody.d.ts +6 -2
- package/cjs/ModalBody.js +22 -2
- package/cjs/ModalContext.js +1 -0
- package/cjs/ModalDialog.js +1 -0
- package/cjs/ModalFooter.d.ts +6 -2
- package/cjs/ModalFooter.js +22 -2
- package/cjs/ModalHeader.js +1 -0
- package/cjs/ModalTitle.d.ts +6 -3
- package/cjs/ModalTitle.js +21 -3
- package/cjs/Nav.d.ts +1 -1
- package/cjs/Nav.js +1 -0
- package/cjs/NavContext.js +1 -0
- package/cjs/NavDropdown.d.ts +4 -4
- package/cjs/NavDropdown.js +1 -0
- package/cjs/NavItem.d.ts +6 -2
- package/cjs/NavItem.js +22 -2
- package/cjs/NavLink.js +1 -0
- package/cjs/Navbar.d.ts +1 -1
- package/cjs/Navbar.js +3 -5
- package/cjs/NavbarBrand.js +1 -0
- package/cjs/NavbarCollapse.js +1 -0
- package/cjs/NavbarContext.js +1 -0
- package/cjs/NavbarOffcanvas.js +1 -0
- package/cjs/NavbarText.d.ts +6 -0
- package/cjs/NavbarText.js +29 -0
- package/cjs/NavbarToggle.js +1 -0
- package/cjs/Offcanvas.d.ts +2 -2
- package/cjs/Offcanvas.js +1 -0
- package/cjs/OffcanvasBody.d.ts +6 -2
- package/cjs/OffcanvasBody.js +22 -2
- package/cjs/OffcanvasHeader.js +1 -0
- package/cjs/OffcanvasTitle.d.ts +6 -3
- package/cjs/OffcanvasTitle.js +21 -3
- package/cjs/OffcanvasToggling.js +1 -0
- package/cjs/Overlay.js +4 -2
- package/cjs/OverlayTrigger.js +1 -0
- package/cjs/Pagination.js +1 -0
- package/cjs/Popover.d.ts +2 -2
- package/cjs/Popover.js +1 -0
- package/cjs/PopoverBody.d.ts +6 -2
- package/cjs/PopoverBody.js +22 -2
- package/cjs/PopoverHeader.d.ts +6 -2
- package/cjs/PopoverHeader.js +22 -2
- package/cjs/ProgressBar.js +1 -0
- package/cjs/Ratio.js +1 -0
- package/cjs/Row.js +1 -0
- package/cjs/Spinner.js +1 -0
- package/cjs/Stack.js +1 -0
- package/cjs/Tab.d.ts +1 -1
- package/cjs/Tab.js +0 -6
- package/cjs/TabContent.d.ts +6 -2
- package/cjs/TabContent.js +22 -2
- package/cjs/TabPane.js +1 -0
- package/cjs/Table.js +1 -0
- package/cjs/ThemeProvider.js +1 -0
- package/cjs/Toast.d.ts +1 -1
- package/cjs/Toast.js +1 -0
- package/cjs/ToastBody.d.ts +6 -2
- package/cjs/ToastBody.js +22 -2
- package/cjs/ToastContainer.js +1 -0
- package/cjs/ToastContext.js +1 -0
- package/cjs/ToastHeader.js +1 -0
- package/cjs/ToggleButton.d.ts +1 -0
- package/cjs/ToggleButton.js +1 -0
- package/cjs/Tooltip.js +1 -0
- package/cjs/TransitionWrapper.js +1 -0
- package/cjs/createWithBsPrefix.js +1 -0
- package/cjs/index.d.ts +71 -9
- package/cjs/index.js +68 -15
- package/cjs/useOverlayOffset.js +1 -0
- package/cjs/usePlaceholder.js +1 -0
- package/dist/react-bootstrap.js +1199 -490
- package/dist/react-bootstrap.min.js +1 -1
- package/esm/AbstractModalHeader.js +2 -0
- package/esm/Accordion.js +2 -0
- package/esm/AccordionBody.js +2 -0
- package/esm/AccordionButton.js +2 -0
- package/esm/AccordionCollapse.js +2 -0
- package/esm/AccordionContext.js +2 -0
- package/esm/AccordionHeader.js +2 -0
- package/esm/AccordionItem.js +2 -0
- package/esm/AccordionItemContext.js +2 -0
- package/esm/Alert.d.ts +2 -2
- package/esm/Alert.js +4 -11
- package/esm/AlertHeading.d.ts +6 -0
- package/esm/AlertHeading.js +24 -0
- package/esm/AlertLink.d.ts +6 -0
- package/esm/AlertLink.js +22 -0
- package/esm/Badge.js +2 -0
- package/esm/Breadcrumb.js +2 -0
- package/esm/BreadcrumbItem.js +2 -0
- package/esm/Button.js +2 -0
- package/esm/ButtonGroup.js +2 -0
- package/esm/ButtonToolbar.js +2 -0
- package/esm/Card.d.ts +7 -7
- package/esm/Card.js +10 -20
- package/esm/CardBody.d.ts +6 -0
- package/esm/CardBody.js +21 -0
- package/esm/CardFooter.d.ts +6 -0
- package/esm/CardFooter.js +21 -0
- package/esm/CardGroup.d.ts +6 -2
- package/esm/CardGroup.js +21 -2
- package/esm/CardHeader.js +2 -0
- package/esm/CardHeaderContext.js +2 -0
- package/esm/CardImg.js +2 -0
- package/esm/CardImgOverlay.d.ts +6 -0
- package/esm/CardImgOverlay.js +21 -0
- package/esm/CardLink.d.ts +6 -0
- package/esm/CardLink.js +21 -0
- package/esm/CardSubtitle.d.ts +6 -0
- package/esm/CardSubtitle.js +23 -0
- package/esm/CardText.d.ts +6 -0
- package/esm/CardText.js +21 -0
- package/esm/CardTitle.d.ts +6 -0
- package/esm/CardTitle.js +23 -0
- package/esm/Carousel.d.ts +1 -1
- package/esm/Carousel.js +2 -0
- package/esm/CarouselCaption.d.ts +6 -2
- package/esm/CarouselCaption.js +21 -2
- package/esm/CarouselItem.js +2 -0
- package/esm/Col.js +2 -0
- package/esm/Container.js +2 -0
- package/esm/Dropdown.d.ts +4 -4
- package/esm/Dropdown.js +5 -15
- package/esm/DropdownContext.js +2 -0
- package/esm/DropdownDivider.d.ts +6 -0
- package/esm/DropdownDivider.js +23 -0
- package/esm/DropdownHeader.d.ts +6 -0
- package/esm/DropdownHeader.js +23 -0
- package/esm/DropdownItem.d.ts +2 -2
- package/esm/DropdownItem.js +2 -0
- package/esm/DropdownItemText.d.ts +6 -0
- package/esm/DropdownItemText.js +21 -0
- package/esm/DropdownMenu.js +2 -0
- package/esm/DropdownToggle.js +2 -0
- package/esm/Figure.d.ts +7 -4
- package/esm/Figure.js +19 -3
- package/esm/FigureCaption.d.ts +5 -1
- package/esm/FigureCaption.js +19 -3
- package/esm/FloatingLabel.js +2 -0
- package/esm/Form.d.ts +1 -1
- package/esm/FormCheck.js +2 -0
- package/esm/FormCheckInput.js +2 -0
- package/esm/FormCheckLabel.js +2 -0
- package/esm/FormContext.js +2 -0
- package/esm/FormControl.js +3 -12
- package/esm/FormFloating.d.ts +6 -2
- package/esm/FormFloating.js +21 -2
- package/esm/FormLabel.js +2 -0
- package/esm/FormRange.js +2 -0
- package/esm/FormSelect.js +2 -0
- package/esm/FormText.js +2 -0
- package/esm/Image.js +2 -0
- package/esm/InputGroup.d.ts +4 -3
- package/esm/InputGroup.js +3 -4
- package/esm/InputGroupContext.js +2 -0
- package/esm/InputGroupText.d.ts +6 -0
- package/esm/InputGroupText.js +21 -0
- package/esm/ListGroup.js +2 -0
- package/esm/ListGroupItem.js +2 -0
- package/esm/Modal.d.ts +3 -3
- package/esm/Modal.js +2 -0
- package/esm/ModalBody.d.ts +6 -2
- package/esm/ModalBody.js +21 -2
- package/esm/ModalContext.js +2 -0
- package/esm/ModalDialog.js +2 -0
- package/esm/ModalFooter.d.ts +6 -2
- package/esm/ModalFooter.js +21 -2
- package/esm/ModalHeader.js +2 -0
- package/esm/ModalTitle.d.ts +6 -3
- package/esm/ModalTitle.js +21 -4
- package/esm/Nav.d.ts +1 -1
- package/esm/Nav.js +2 -0
- package/esm/NavContext.js +2 -0
- package/esm/NavDropdown.d.ts +4 -4
- package/esm/NavDropdown.js +2 -0
- package/esm/NavItem.d.ts +6 -2
- package/esm/NavItem.js +21 -2
- package/esm/NavLink.js +2 -0
- package/esm/Navbar.d.ts +1 -1
- package/esm/Navbar.js +3 -4
- package/esm/NavbarBrand.js +2 -0
- package/esm/NavbarCollapse.js +2 -0
- package/esm/NavbarContext.js +2 -0
- package/esm/NavbarOffcanvas.js +2 -0
- package/esm/NavbarText.d.ts +6 -0
- package/esm/NavbarText.js +21 -0
- package/esm/NavbarToggle.js +2 -0
- package/esm/Offcanvas.d.ts +2 -2
- package/esm/Offcanvas.js +2 -0
- package/esm/OffcanvasBody.d.ts +6 -2
- package/esm/OffcanvasBody.js +21 -2
- package/esm/OffcanvasHeader.js +2 -0
- package/esm/OffcanvasTitle.d.ts +6 -3
- package/esm/OffcanvasTitle.js +21 -4
- package/esm/OffcanvasToggling.js +2 -0
- package/esm/Overlay.js +5 -2
- package/esm/OverlayTrigger.js +2 -0
- package/esm/Pagination.js +2 -0
- package/esm/Popover.d.ts +2 -2
- package/esm/Popover.js +2 -0
- package/esm/PopoverBody.d.ts +6 -2
- package/esm/PopoverBody.js +21 -2
- package/esm/PopoverHeader.d.ts +6 -2
- package/esm/PopoverHeader.js +21 -2
- package/esm/ProgressBar.js +2 -0
- package/esm/Ratio.js +2 -0
- package/esm/Row.js +2 -0
- package/esm/Spinner.js +2 -0
- package/esm/Stack.js +2 -0
- package/esm/Tab.d.ts +1 -1
- package/esm/Tab.js +0 -5
- package/esm/TabContent.d.ts +6 -2
- package/esm/TabContent.js +21 -2
- package/esm/TabPane.js +2 -0
- package/esm/Table.js +2 -0
- package/esm/ThemeProvider.js +2 -0
- package/esm/Toast.d.ts +1 -1
- package/esm/Toast.js +2 -0
- package/esm/ToastBody.d.ts +6 -2
- package/esm/ToastBody.js +21 -2
- package/esm/ToastContainer.js +2 -0
- package/esm/ToastContext.js +2 -0
- package/esm/ToastHeader.js +2 -0
- package/esm/ToggleButton.d.ts +1 -0
- package/esm/ToggleButton.js +2 -0
- package/esm/Tooltip.js +2 -0
- package/esm/TransitionWrapper.js +2 -0
- package/esm/createWithBsPrefix.js +2 -0
- package/esm/index.d.ts +71 -9
- package/esm/index.js +33 -7
- package/esm/useOverlayOffset.js +2 -0
- package/esm/usePlaceholder.js +2 -0
- package/package.json +4 -4
package/cjs/FormCheck.js
CHANGED
package/cjs/FormCheckInput.js
CHANGED
package/cjs/FormCheckLabel.js
CHANGED
package/cjs/FormContext.js
CHANGED
package/cjs/FormControl.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
"use client";
|
|
2
3
|
|
|
3
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
5
|
exports.__esModule = true;
|
|
@@ -31,17 +32,6 @@ const FormControl = /*#__PURE__*/React.forwardRef(({
|
|
|
31
32
|
controlId
|
|
32
33
|
} = (0, React.useContext)(_FormContext.default);
|
|
33
34
|
bsPrefix = (0, _ThemeProvider.useBootstrapPrefix)(bsPrefix, 'form-control');
|
|
34
|
-
let classes;
|
|
35
|
-
if (plaintext) {
|
|
36
|
-
classes = {
|
|
37
|
-
[`${bsPrefix}-plaintext`]: true
|
|
38
|
-
};
|
|
39
|
-
} else {
|
|
40
|
-
classes = {
|
|
41
|
-
[bsPrefix]: true,
|
|
42
|
-
[`${bsPrefix}-${size}`]: size
|
|
43
|
-
};
|
|
44
|
-
}
|
|
45
35
|
process.env.NODE_ENV !== "production" ? (0, _warning.default)(controlId == null || !id, '`controlId` is ignored on `<FormControl>` when `id` is specified.') : void 0;
|
|
46
36
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(Component, {
|
|
47
37
|
...props,
|
|
@@ -50,7 +40,7 @@ const FormControl = /*#__PURE__*/React.forwardRef(({
|
|
|
50
40
|
ref: ref,
|
|
51
41
|
readOnly: readOnly,
|
|
52
42
|
id: id || controlId,
|
|
53
|
-
className: (0, _classnames.default)(className,
|
|
43
|
+
className: (0, _classnames.default)(className, plaintext ? `${bsPrefix}-plaintext` : bsPrefix, size && `${bsPrefix}-${size}`, type === 'color' && `${bsPrefix}-color`, isValid && 'is-valid', isInvalid && 'is-invalid')
|
|
54
44
|
});
|
|
55
45
|
});
|
|
56
46
|
FormControl.displayName = 'FormControl';
|
package/cjs/FormFloating.d.ts
CHANGED
|
@@ -1,2 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import type { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
+
export interface FormFloatingProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const FormFloating: BsPrefixRefForwardingComponent<'div', FormFloatingProps>;
|
|
6
|
+
export default FormFloating;
|
package/cjs/FormFloating.js
CHANGED
|
@@ -1,9 +1,29 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
"use client";
|
|
2
3
|
|
|
3
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
5
|
exports.__esModule = true;
|
|
5
6
|
exports.default = void 0;
|
|
6
|
-
var
|
|
7
|
-
var
|
|
7
|
+
var React = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
9
|
+
var _ThemeProvider = require("./ThemeProvider");
|
|
10
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
11
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
12
|
+
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; }
|
|
13
|
+
const FormFloating = /*#__PURE__*/React.forwardRef(({
|
|
14
|
+
className,
|
|
15
|
+
bsPrefix,
|
|
16
|
+
as: Component = 'div',
|
|
17
|
+
...props
|
|
18
|
+
}, ref) => {
|
|
19
|
+
bsPrefix = (0, _ThemeProvider.useBootstrapPrefix)(bsPrefix, 'form-floating');
|
|
20
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(Component, {
|
|
21
|
+
ref: ref,
|
|
22
|
+
className: (0, _classnames.default)(className, bsPrefix),
|
|
23
|
+
...props
|
|
24
|
+
});
|
|
25
|
+
});
|
|
26
|
+
FormFloating.displayName = 'FormFloating';
|
|
27
|
+
var _default = FormFloating;
|
|
8
28
|
exports.default = _default;
|
|
9
29
|
module.exports = exports.default;
|
package/cjs/FormLabel.js
CHANGED
package/cjs/FormRange.js
CHANGED
package/cjs/FormSelect.js
CHANGED
package/cjs/FormText.js
CHANGED
package/cjs/Image.js
CHANGED
package/cjs/InputGroup.d.ts
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
import { type FormCheckInputProps } from './FormCheckInput';
|
|
2
3
|
import { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
4
|
export interface InputGroupProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
5
|
size?: 'sm' | 'lg';
|
|
5
6
|
hasValidation?: boolean;
|
|
6
7
|
}
|
|
7
8
|
declare const _default: BsPrefixRefForwardingComponent<"div", InputGroupProps> & {
|
|
8
|
-
Text: BsPrefixRefForwardingComponent<"span",
|
|
9
|
-
Radio: (props:
|
|
10
|
-
Checkbox: (props:
|
|
9
|
+
Text: BsPrefixRefForwardingComponent<"span", import("./InputGroupText").InputGroupTextProps>;
|
|
10
|
+
Radio: (props: FormCheckInputProps) => JSX.Element;
|
|
11
|
+
Checkbox: (props: FormCheckInputProps) => JSX.Element;
|
|
11
12
|
};
|
|
12
13
|
export default _default;
|
package/cjs/InputGroup.js
CHANGED
|
@@ -1,27 +1,25 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
"use client";
|
|
2
3
|
|
|
3
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
5
|
exports.__esModule = true;
|
|
5
6
|
exports.default = void 0;
|
|
6
7
|
var _classnames = _interopRequireDefault(require("classnames"));
|
|
7
8
|
var React = _interopRequireWildcard(require("react"));
|
|
8
|
-
var _createWithBsPrefix = _interopRequireDefault(require("./createWithBsPrefix"));
|
|
9
9
|
var _ThemeProvider = require("./ThemeProvider");
|
|
10
10
|
var _FormCheckInput = _interopRequireDefault(require("./FormCheckInput"));
|
|
11
11
|
var _InputGroupContext = _interopRequireDefault(require("./InputGroupContext"));
|
|
12
|
+
var _InputGroupText = _interopRequireDefault(require("./InputGroupText"));
|
|
12
13
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
13
14
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
14
15
|
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; }
|
|
15
|
-
const
|
|
16
|
-
Component: 'span'
|
|
17
|
-
});
|
|
18
|
-
const InputGroupCheckbox = props => /*#__PURE__*/(0, _jsxRuntime.jsx)(InputGroupText, {
|
|
16
|
+
const InputGroupCheckbox = props => /*#__PURE__*/(0, _jsxRuntime.jsx)(_InputGroupText.default, {
|
|
19
17
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_FormCheckInput.default, {
|
|
20
18
|
type: "checkbox",
|
|
21
19
|
...props
|
|
22
20
|
})
|
|
23
21
|
});
|
|
24
|
-
const InputGroupRadio = props => /*#__PURE__*/(0, _jsxRuntime.jsx)(
|
|
22
|
+
const InputGroupRadio = props => /*#__PURE__*/(0, _jsxRuntime.jsx)(_InputGroupText.default, {
|
|
25
23
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_FormCheckInput.default, {
|
|
26
24
|
type: "radio",
|
|
27
25
|
...props
|
|
@@ -52,7 +50,7 @@ const InputGroup = /*#__PURE__*/React.forwardRef(({
|
|
|
52
50
|
});
|
|
53
51
|
InputGroup.displayName = 'InputGroup';
|
|
54
52
|
var _default = Object.assign(InputGroup, {
|
|
55
|
-
Text:
|
|
53
|
+
Text: _InputGroupText.default,
|
|
56
54
|
Radio: InputGroupRadio,
|
|
57
55
|
Checkbox: InputGroupCheckbox
|
|
58
56
|
});
|
package/cjs/InputGroupContext.js
CHANGED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import type { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
+
export interface InputGroupTextProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const InputGroupText: BsPrefixRefForwardingComponent<'span', InputGroupTextProps>;
|
|
6
|
+
export default InputGroupText;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
|
|
4
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
5
|
+
exports.__esModule = true;
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var React = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
9
|
+
var _ThemeProvider = require("./ThemeProvider");
|
|
10
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
11
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
12
|
+
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; }
|
|
13
|
+
const InputGroupText = /*#__PURE__*/React.forwardRef(({
|
|
14
|
+
className,
|
|
15
|
+
bsPrefix,
|
|
16
|
+
as: Component = 'span',
|
|
17
|
+
...props
|
|
18
|
+
}, ref) => {
|
|
19
|
+
bsPrefix = (0, _ThemeProvider.useBootstrapPrefix)(bsPrefix, 'input-group-text');
|
|
20
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(Component, {
|
|
21
|
+
ref: ref,
|
|
22
|
+
className: (0, _classnames.default)(className, bsPrefix),
|
|
23
|
+
...props
|
|
24
|
+
});
|
|
25
|
+
});
|
|
26
|
+
InputGroupText.displayName = 'InputGroupText';
|
|
27
|
+
var _default = InputGroupText;
|
|
28
|
+
exports.default = _default;
|
|
29
|
+
module.exports = exports.default;
|
package/cjs/ListGroup.js
CHANGED
package/cjs/ListGroupItem.js
CHANGED
package/cjs/Modal.d.ts
CHANGED
|
@@ -15,10 +15,10 @@ export interface ModalProps extends Omit<BaseModalProps, 'role' | 'renderBackdro
|
|
|
15
15
|
[other: string]: any;
|
|
16
16
|
}
|
|
17
17
|
declare const _default: BsPrefixRefForwardingComponent<"div", ModalProps> & {
|
|
18
|
-
Body: BsPrefixRefForwardingComponent<"div",
|
|
18
|
+
Body: BsPrefixRefForwardingComponent<"div", import("./ModalBody").ModalBodyProps>;
|
|
19
19
|
Header: React.ForwardRefExoticComponent<import("./ModalHeader").ModalHeaderProps & React.RefAttributes<HTMLDivElement>>;
|
|
20
|
-
Title: BsPrefixRefForwardingComponent<
|
|
21
|
-
Footer: BsPrefixRefForwardingComponent<"div",
|
|
20
|
+
Title: BsPrefixRefForwardingComponent<"span", import("./ModalTitle").ModalTitleProps>;
|
|
21
|
+
Footer: BsPrefixRefForwardingComponent<"div", import("./ModalFooter").ModalFooterProps>;
|
|
22
22
|
Dialog: React.ForwardRefExoticComponent<import("./ModalDialog").ModalDialogProps & React.RefAttributes<HTMLDivElement>>;
|
|
23
23
|
TRANSITION_DURATION: number;
|
|
24
24
|
BACKDROP_TRANSITION_DURATION: number;
|
package/cjs/Modal.js
CHANGED
package/cjs/ModalBody.d.ts
CHANGED
|
@@ -1,2 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import type { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
+
export interface ModalBodyProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const ModalBody: BsPrefixRefForwardingComponent<'div', ModalBodyProps>;
|
|
6
|
+
export default ModalBody;
|
package/cjs/ModalBody.js
CHANGED
|
@@ -1,9 +1,29 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
"use client";
|
|
2
3
|
|
|
3
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
5
|
exports.__esModule = true;
|
|
5
6
|
exports.default = void 0;
|
|
6
|
-
var
|
|
7
|
-
var
|
|
7
|
+
var React = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
9
|
+
var _ThemeProvider = require("./ThemeProvider");
|
|
10
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
11
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
12
|
+
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; }
|
|
13
|
+
const ModalBody = /*#__PURE__*/React.forwardRef(({
|
|
14
|
+
className,
|
|
15
|
+
bsPrefix,
|
|
16
|
+
as: Component = 'div',
|
|
17
|
+
...props
|
|
18
|
+
}, ref) => {
|
|
19
|
+
bsPrefix = (0, _ThemeProvider.useBootstrapPrefix)(bsPrefix, 'modal-body');
|
|
20
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(Component, {
|
|
21
|
+
ref: ref,
|
|
22
|
+
className: (0, _classnames.default)(className, bsPrefix),
|
|
23
|
+
...props
|
|
24
|
+
});
|
|
25
|
+
});
|
|
26
|
+
ModalBody.displayName = 'ModalBody';
|
|
27
|
+
var _default = ModalBody;
|
|
8
28
|
exports.default = _default;
|
|
9
29
|
module.exports = exports.default;
|
package/cjs/ModalContext.js
CHANGED
package/cjs/ModalDialog.js
CHANGED
package/cjs/ModalFooter.d.ts
CHANGED
|
@@ -1,2 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import type { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
+
export interface ModalFooterProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const ModalFooter: BsPrefixRefForwardingComponent<'div', ModalFooterProps>;
|
|
6
|
+
export default ModalFooter;
|
package/cjs/ModalFooter.js
CHANGED
|
@@ -1,9 +1,29 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
"use client";
|
|
2
3
|
|
|
3
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
5
|
exports.__esModule = true;
|
|
5
6
|
exports.default = void 0;
|
|
6
|
-
var
|
|
7
|
-
var
|
|
7
|
+
var React = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
9
|
+
var _ThemeProvider = require("./ThemeProvider");
|
|
10
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
11
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
12
|
+
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; }
|
|
13
|
+
const ModalFooter = /*#__PURE__*/React.forwardRef(({
|
|
14
|
+
className,
|
|
15
|
+
bsPrefix,
|
|
16
|
+
as: Component = 'div',
|
|
17
|
+
...props
|
|
18
|
+
}, ref) => {
|
|
19
|
+
bsPrefix = (0, _ThemeProvider.useBootstrapPrefix)(bsPrefix, 'modal-footer');
|
|
20
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(Component, {
|
|
21
|
+
ref: ref,
|
|
22
|
+
className: (0, _classnames.default)(className, bsPrefix),
|
|
23
|
+
...props
|
|
24
|
+
});
|
|
25
|
+
});
|
|
26
|
+
ModalFooter.displayName = 'ModalFooter';
|
|
27
|
+
var _default = ModalFooter;
|
|
8
28
|
exports.default = _default;
|
|
9
29
|
module.exports = exports.default;
|
package/cjs/ModalHeader.js
CHANGED
package/cjs/ModalTitle.d.ts
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import type { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
+
export interface ModalTitleProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const ModalTitle: BsPrefixRefForwardingComponent<'span', ModalTitleProps>;
|
|
6
|
+
export default ModalTitle;
|
package/cjs/ModalTitle.js
CHANGED
|
@@ -1,13 +1,31 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
"use client";
|
|
2
3
|
|
|
3
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
5
|
exports.__esModule = true;
|
|
5
6
|
exports.default = void 0;
|
|
6
|
-
var
|
|
7
|
+
var React = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
7
9
|
var _divWithClassName = _interopRequireDefault(require("./divWithClassName"));
|
|
10
|
+
var _ThemeProvider = require("./ThemeProvider");
|
|
11
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
12
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
|
+
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; }
|
|
8
14
|
const DivStyledAsH4 = (0, _divWithClassName.default)('h4');
|
|
9
|
-
|
|
10
|
-
|
|
15
|
+
const ModalTitle = /*#__PURE__*/React.forwardRef(({
|
|
16
|
+
className,
|
|
17
|
+
bsPrefix,
|
|
18
|
+
as: Component = DivStyledAsH4,
|
|
19
|
+
...props
|
|
20
|
+
}, ref) => {
|
|
21
|
+
bsPrefix = (0, _ThemeProvider.useBootstrapPrefix)(bsPrefix, 'modal-title');
|
|
22
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(Component, {
|
|
23
|
+
ref: ref,
|
|
24
|
+
className: (0, _classnames.default)(className, bsPrefix),
|
|
25
|
+
...props
|
|
26
|
+
});
|
|
11
27
|
});
|
|
28
|
+
ModalTitle.displayName = 'ModalTitle';
|
|
29
|
+
var _default = ModalTitle;
|
|
12
30
|
exports.default = _default;
|
|
13
31
|
module.exports = exports.default;
|
package/cjs/Nav.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ export interface NavProps extends BsPrefixProps, BaseNavProps {
|
|
|
12
12
|
navbarScroll?: boolean;
|
|
13
13
|
}
|
|
14
14
|
declare const _default: BsPrefixRefForwardingComponent<"div", NavProps> & {
|
|
15
|
-
Item: BsPrefixRefForwardingComponent<"div",
|
|
15
|
+
Item: BsPrefixRefForwardingComponent<"div", import("./NavItem").NavItemProps>;
|
|
16
16
|
Link: BsPrefixRefForwardingComponent<"a", import("./NavLink").NavLinkProps>;
|
|
17
17
|
};
|
|
18
18
|
export default _default;
|
package/cjs/Nav.js
CHANGED
package/cjs/NavContext.js
CHANGED
package/cjs/NavDropdown.d.ts
CHANGED
|
@@ -12,9 +12,9 @@ export interface NavDropdownProps extends Omit<DropdownProps, 'title'> {
|
|
|
12
12
|
menuVariant?: DropdownMenuVariant;
|
|
13
13
|
}
|
|
14
14
|
declare const _default: BsPrefixRefForwardingComponent<"div", NavDropdownProps> & {
|
|
15
|
-
Item: BsPrefixRefForwardingComponent<
|
|
16
|
-
ItemText: BsPrefixRefForwardingComponent<"span",
|
|
17
|
-
Divider: BsPrefixRefForwardingComponent<"hr",
|
|
18
|
-
Header: BsPrefixRefForwardingComponent<"div",
|
|
15
|
+
Item: BsPrefixRefForwardingComponent<"a", import("./DropdownItem").DropdownItemProps>;
|
|
16
|
+
ItemText: BsPrefixRefForwardingComponent<"span", import("./DropdownItemText").DropdownItemTextProps>;
|
|
17
|
+
Divider: BsPrefixRefForwardingComponent<"hr", import("./DropdownDivider").DropdownDividerProps>;
|
|
18
|
+
Header: BsPrefixRefForwardingComponent<"div", import("./DropdownHeader").DropdownHeaderProps>;
|
|
19
19
|
};
|
|
20
20
|
export default _default;
|
package/cjs/NavDropdown.js
CHANGED
package/cjs/NavItem.d.ts
CHANGED
|
@@ -1,2 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import type { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
+
export interface NavItemProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const NavItem: BsPrefixRefForwardingComponent<'div', NavItemProps>;
|
|
6
|
+
export default NavItem;
|
package/cjs/NavItem.js
CHANGED
|
@@ -1,9 +1,29 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
"use client";
|
|
2
3
|
|
|
3
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
5
|
exports.__esModule = true;
|
|
5
6
|
exports.default = void 0;
|
|
6
|
-
var
|
|
7
|
-
var
|
|
7
|
+
var React = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _classnames = _interopRequireDefault(require("classnames"));
|
|
9
|
+
var _ThemeProvider = require("./ThemeProvider");
|
|
10
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
11
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
12
|
+
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; }
|
|
13
|
+
const NavItem = /*#__PURE__*/React.forwardRef(({
|
|
14
|
+
className,
|
|
15
|
+
bsPrefix,
|
|
16
|
+
as: Component = 'div',
|
|
17
|
+
...props
|
|
18
|
+
}, ref) => {
|
|
19
|
+
bsPrefix = (0, _ThemeProvider.useBootstrapPrefix)(bsPrefix, 'nav-item');
|
|
20
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(Component, {
|
|
21
|
+
ref: ref,
|
|
22
|
+
className: (0, _classnames.default)(className, bsPrefix),
|
|
23
|
+
...props
|
|
24
|
+
});
|
|
25
|
+
});
|
|
26
|
+
NavItem.displayName = 'NavItem';
|
|
27
|
+
var _default = NavItem;
|
|
8
28
|
exports.default = _default;
|
|
9
29
|
module.exports = exports.default;
|
package/cjs/NavLink.js
CHANGED
package/cjs/Navbar.d.ts
CHANGED
|
@@ -16,7 +16,7 @@ declare const _default: BsPrefixRefForwardingComponent<"nav", NavbarProps> & {
|
|
|
16
16
|
Brand: BsPrefixRefForwardingComponent<"a", import("./NavbarBrand").NavbarBrandProps>;
|
|
17
17
|
Collapse: React.ForwardRefExoticComponent<import("./NavbarCollapse").NavbarCollapseProps & React.RefAttributes<HTMLDivElement>>;
|
|
18
18
|
Offcanvas: React.ForwardRefExoticComponent<Omit<import("./NavbarOffcanvas").NavbarOffcanvasProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
19
|
-
Text: BsPrefixRefForwardingComponent<"span",
|
|
19
|
+
Text: BsPrefixRefForwardingComponent<"span", import("./NavbarText").NavbarTextProps>;
|
|
20
20
|
Toggle: BsPrefixRefForwardingComponent<"button", import("./NavbarToggle").NavbarToggleProps>;
|
|
21
21
|
};
|
|
22
22
|
export default _default;
|
package/cjs/Navbar.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
"use client";
|
|
2
3
|
|
|
3
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
5
|
exports.__esModule = true;
|
|
@@ -7,19 +8,16 @@ var _classnames = _interopRequireDefault(require("classnames"));
|
|
|
7
8
|
var React = _interopRequireWildcard(require("react"));
|
|
8
9
|
var _SelectableContext = _interopRequireDefault(require("@restart/ui/SelectableContext"));
|
|
9
10
|
var _uncontrollable = require("uncontrollable");
|
|
10
|
-
var _createWithBsPrefix = _interopRequireDefault(require("./createWithBsPrefix"));
|
|
11
11
|
var _NavbarBrand = _interopRequireDefault(require("./NavbarBrand"));
|
|
12
12
|
var _NavbarCollapse = _interopRequireDefault(require("./NavbarCollapse"));
|
|
13
13
|
var _NavbarToggle = _interopRequireDefault(require("./NavbarToggle"));
|
|
14
14
|
var _NavbarOffcanvas = _interopRequireDefault(require("./NavbarOffcanvas"));
|
|
15
15
|
var _ThemeProvider = require("./ThemeProvider");
|
|
16
16
|
var _NavbarContext = _interopRequireDefault(require("./NavbarContext"));
|
|
17
|
+
var _NavbarText = _interopRequireDefault(require("./NavbarText"));
|
|
17
18
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
18
19
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
19
20
|
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; }
|
|
20
|
-
const NavbarText = (0, _createWithBsPrefix.default)('navbar-text', {
|
|
21
|
-
Component: 'span'
|
|
22
|
-
});
|
|
23
21
|
const Navbar = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
24
22
|
const {
|
|
25
23
|
bsPrefix: initialBsPrefix,
|
|
@@ -78,7 +76,7 @@ var _default = Object.assign(Navbar, {
|
|
|
78
76
|
Brand: _NavbarBrand.default,
|
|
79
77
|
Collapse: _NavbarCollapse.default,
|
|
80
78
|
Offcanvas: _NavbarOffcanvas.default,
|
|
81
|
-
Text:
|
|
79
|
+
Text: _NavbarText.default,
|
|
82
80
|
Toggle: _NavbarToggle.default
|
|
83
81
|
});
|
|
84
82
|
exports.default = _default;
|
package/cjs/NavbarBrand.js
CHANGED
package/cjs/NavbarCollapse.js
CHANGED
package/cjs/NavbarContext.js
CHANGED