react-bootstrap 2.9.0-beta.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/Alert.d.ts +2 -2
- package/cjs/Alert.js +4 -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/Card.d.ts +7 -7
- package/cjs/Card.js +16 -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/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/CarouselCaption.d.ts +6 -2
- package/cjs/CarouselCaption.js +22 -2
- package/cjs/Dropdown.d.ts +4 -4
- package/cjs/Dropdown.js +6 -18
- 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/DropdownItemText.d.ts +6 -0
- package/cjs/DropdownItemText.js +29 -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/Form.d.ts +1 -1
- package/cjs/FormControl.js +1 -12
- package/cjs/FormFloating.d.ts +6 -2
- package/cjs/FormFloating.js +22 -2
- package/cjs/InputGroup.d.ts +4 -3
- package/cjs/InputGroup.js +4 -7
- package/cjs/InputGroupText.d.ts +6 -0
- package/cjs/InputGroupText.js +29 -0
- package/cjs/Modal.d.ts +3 -3
- package/cjs/ModalBody.d.ts +6 -2
- package/cjs/ModalBody.js +22 -2
- package/cjs/ModalFooter.d.ts +6 -2
- package/cjs/ModalFooter.js +22 -2
- package/cjs/ModalTitle.d.ts +6 -3
- package/cjs/ModalTitle.js +21 -3
- package/cjs/Nav.d.ts +1 -1
- package/cjs/NavDropdown.d.ts +4 -4
- package/cjs/NavItem.d.ts +6 -2
- package/cjs/NavItem.js +22 -2
- package/cjs/Navbar.d.ts +1 -1
- package/cjs/Navbar.js +2 -5
- package/cjs/NavbarText.d.ts +6 -0
- package/cjs/NavbarText.js +29 -0
- package/cjs/Offcanvas.d.ts +2 -2
- package/cjs/OffcanvasBody.d.ts +6 -2
- package/cjs/OffcanvasBody.js +22 -2
- package/cjs/OffcanvasTitle.d.ts +6 -3
- package/cjs/OffcanvasTitle.js +21 -3
- package/cjs/Overlay.js +3 -2
- package/cjs/Popover.d.ts +2 -2
- 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/Tab.d.ts +1 -1
- package/cjs/TabContent.d.ts +6 -2
- package/cjs/TabContent.js +22 -2
- package/cjs/Toast.d.ts +1 -1
- package/cjs/ToastBody.d.ts +6 -2
- package/cjs/ToastBody.js +22 -2
- package/cjs/ToggleButton.d.ts +1 -0
- package/cjs/index.d.ts +71 -9
- package/cjs/index.js +68 -15
- package/dist/react-bootstrap.js +1096 -469
- package/dist/react-bootstrap.min.js +1 -1
- package/esm/Alert.d.ts +2 -2
- package/esm/Alert.js +2 -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/Card.d.ts +7 -7
- package/esm/Card.js +8 -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/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/CarouselCaption.d.ts +6 -2
- package/esm/CarouselCaption.js +21 -2
- package/esm/Dropdown.d.ts +4 -4
- package/esm/Dropdown.js +3 -15
- 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/DropdownItemText.d.ts +6 -0
- package/esm/DropdownItemText.js +21 -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/Form.d.ts +1 -1
- package/esm/FormControl.js +1 -12
- package/esm/FormFloating.d.ts +6 -2
- package/esm/FormFloating.js +21 -2
- package/esm/InputGroup.d.ts +4 -3
- package/esm/InputGroup.js +1 -4
- package/esm/InputGroupText.d.ts +6 -0
- package/esm/InputGroupText.js +21 -0
- package/esm/Modal.d.ts +3 -3
- package/esm/ModalBody.d.ts +6 -2
- package/esm/ModalBody.js +21 -2
- package/esm/ModalFooter.d.ts +6 -2
- package/esm/ModalFooter.js +21 -2
- package/esm/ModalTitle.d.ts +6 -3
- package/esm/ModalTitle.js +21 -4
- package/esm/Nav.d.ts +1 -1
- package/esm/NavDropdown.d.ts +4 -4
- package/esm/NavItem.d.ts +6 -2
- package/esm/NavItem.js +21 -2
- package/esm/Navbar.d.ts +1 -1
- package/esm/Navbar.js +1 -4
- package/esm/NavbarText.d.ts +6 -0
- package/esm/NavbarText.js +21 -0
- package/esm/Offcanvas.d.ts +2 -2
- package/esm/OffcanvasBody.d.ts +6 -2
- package/esm/OffcanvasBody.js +21 -2
- package/esm/OffcanvasTitle.d.ts +6 -3
- package/esm/OffcanvasTitle.js +21 -4
- package/esm/Overlay.js +3 -2
- package/esm/Popover.d.ts +2 -2
- 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/Tab.d.ts +1 -1
- package/esm/TabContent.d.ts +6 -2
- package/esm/TabContent.js +21 -2
- package/esm/Toast.d.ts +1 -1
- package/esm/ToastBody.d.ts +6 -2
- package/esm/ToastBody.js +21 -2
- package/esm/ToggleButton.d.ts +1 -0
- package/esm/index.d.ts +71 -9
- package/esm/index.js +33 -7
- package/package.json +1 -1
package/esm/Figure.js
CHANGED
|
@@ -1,9 +1,25 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
2
5
|
import FigureImage from './FigureImage';
|
|
3
6
|
import FigureCaption from './FigureCaption';
|
|
4
|
-
|
|
5
|
-
|
|
7
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
9
|
+
const Figure = /*#__PURE__*/React.forwardRef(({
|
|
10
|
+
className,
|
|
11
|
+
bsPrefix,
|
|
12
|
+
as: Component = 'figure',
|
|
13
|
+
...props
|
|
14
|
+
}, ref) => {
|
|
15
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'figure');
|
|
16
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
17
|
+
ref: ref,
|
|
18
|
+
className: classNames(className, bsPrefix),
|
|
19
|
+
...props
|
|
20
|
+
});
|
|
6
21
|
});
|
|
22
|
+
Figure.displayName = 'Figure';
|
|
7
23
|
export default Object.assign(Figure, {
|
|
8
24
|
Image: FigureImage,
|
|
9
25
|
Caption: FigureCaption
|
package/esm/FigureCaption.d.ts
CHANGED
|
@@ -1,2 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import type { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
+
export interface FigureCaptionProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const FigureCaption: BsPrefixRefForwardingComponent<'figcaption', FigureCaptionProps>;
|
|
2
6
|
export default FigureCaption;
|
package/esm/FigureCaption.js
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
5
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
const FigureCaption = /*#__PURE__*/React.forwardRef(({
|
|
8
|
+
className,
|
|
9
|
+
bsPrefix,
|
|
10
|
+
as: Component = 'figcaption',
|
|
11
|
+
...props
|
|
12
|
+
}, ref) => {
|
|
13
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'figure-caption');
|
|
14
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
15
|
+
ref: ref,
|
|
16
|
+
className: classNames(className, bsPrefix),
|
|
17
|
+
...props
|
|
18
|
+
});
|
|
4
19
|
});
|
|
20
|
+
FigureCaption.displayName = 'FigureCaption';
|
|
5
21
|
export default FigureCaption;
|
package/esm/Form.d.ts
CHANGED
|
@@ -8,7 +8,7 @@ declare const _default: BsPrefixRefForwardingComponent<"form", FormProps> & {
|
|
|
8
8
|
Control: BsPrefixRefForwardingComponent<"input", import("./FormControl").FormControlProps> & {
|
|
9
9
|
Feedback: BsPrefixRefForwardingComponent<"div", import("./Feedback").FeedbackProps>;
|
|
10
10
|
};
|
|
11
|
-
Floating: BsPrefixRefForwardingComponent<"div",
|
|
11
|
+
Floating: BsPrefixRefForwardingComponent<"div", import("./FormFloating").FormFloatingProps>;
|
|
12
12
|
Check: BsPrefixRefForwardingComponent<"input", import("./FormCheck").FormCheckProps> & {
|
|
13
13
|
Input: BsPrefixRefForwardingComponent<"input", import("./FormCheckInput").FormCheckInputProps>;
|
|
14
14
|
Label: React.ForwardRefExoticComponent<import("./FormCheckLabel").FormCheckLabelProps & React.RefAttributes<HTMLLabelElement>>;
|
package/esm/FormControl.js
CHANGED
|
@@ -27,17 +27,6 @@ const FormControl = /*#__PURE__*/React.forwardRef(({
|
|
|
27
27
|
controlId
|
|
28
28
|
} = useContext(FormContext);
|
|
29
29
|
bsPrefix = useBootstrapPrefix(bsPrefix, 'form-control');
|
|
30
|
-
let classes;
|
|
31
|
-
if (plaintext) {
|
|
32
|
-
classes = {
|
|
33
|
-
[`${bsPrefix}-plaintext`]: true
|
|
34
|
-
};
|
|
35
|
-
} else {
|
|
36
|
-
classes = {
|
|
37
|
-
[bsPrefix]: true,
|
|
38
|
-
[`${bsPrefix}-${size}`]: size
|
|
39
|
-
};
|
|
40
|
-
}
|
|
41
30
|
process.env.NODE_ENV !== "production" ? warning(controlId == null || !id, '`controlId` is ignored on `<FormControl>` when `id` is specified.') : void 0;
|
|
42
31
|
return /*#__PURE__*/_jsx(Component, {
|
|
43
32
|
...props,
|
|
@@ -46,7 +35,7 @@ const FormControl = /*#__PURE__*/React.forwardRef(({
|
|
|
46
35
|
ref: ref,
|
|
47
36
|
readOnly: readOnly,
|
|
48
37
|
id: id || controlId,
|
|
49
|
-
className: classNames(className,
|
|
38
|
+
className: classNames(className, plaintext ? `${bsPrefix}-plaintext` : bsPrefix, size && `${bsPrefix}-${size}`, type === 'color' && `${bsPrefix}-color`, isValid && 'is-valid', isInvalid && 'is-invalid')
|
|
50
39
|
});
|
|
51
40
|
});
|
|
52
41
|
FormControl.displayName = 'FormControl';
|
package/esm/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/esm/FormFloating.js
CHANGED
|
@@ -1,2 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
5
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
const FormFloating = /*#__PURE__*/React.forwardRef(({
|
|
8
|
+
className,
|
|
9
|
+
bsPrefix,
|
|
10
|
+
as: Component = 'div',
|
|
11
|
+
...props
|
|
12
|
+
}, ref) => {
|
|
13
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'form-floating');
|
|
14
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
15
|
+
ref: ref,
|
|
16
|
+
className: classNames(className, bsPrefix),
|
|
17
|
+
...props
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
FormFloating.displayName = 'FormFloating';
|
|
21
|
+
export default FormFloating;
|
package/esm/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/esm/InputGroup.js
CHANGED
|
@@ -3,14 +3,11 @@
|
|
|
3
3
|
import classNames from 'classnames';
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import { useMemo } from 'react';
|
|
6
|
-
import createWithBsPrefix from './createWithBsPrefix';
|
|
7
6
|
import { useBootstrapPrefix } from './ThemeProvider';
|
|
8
7
|
import FormCheckInput from './FormCheckInput';
|
|
9
8
|
import InputGroupContext from './InputGroupContext';
|
|
9
|
+
import InputGroupText from './InputGroupText';
|
|
10
10
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
11
|
-
const InputGroupText = createWithBsPrefix('input-group-text', {
|
|
12
|
-
Component: 'span'
|
|
13
|
-
});
|
|
14
11
|
const InputGroupCheckbox = props => /*#__PURE__*/_jsx(InputGroupText, {
|
|
15
12
|
children: /*#__PURE__*/_jsx(FormCheckInput, {
|
|
16
13
|
type: "checkbox",
|
|
@@ -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,21 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
5
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
const InputGroupText = /*#__PURE__*/React.forwardRef(({
|
|
8
|
+
className,
|
|
9
|
+
bsPrefix,
|
|
10
|
+
as: Component = 'span',
|
|
11
|
+
...props
|
|
12
|
+
}, ref) => {
|
|
13
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'input-group-text');
|
|
14
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
15
|
+
ref: ref,
|
|
16
|
+
className: classNames(className, bsPrefix),
|
|
17
|
+
...props
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
InputGroupText.displayName = 'InputGroupText';
|
|
21
|
+
export default InputGroupText;
|
package/esm/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/esm/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/esm/ModalBody.js
CHANGED
|
@@ -1,2 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
5
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
const ModalBody = /*#__PURE__*/React.forwardRef(({
|
|
8
|
+
className,
|
|
9
|
+
bsPrefix,
|
|
10
|
+
as: Component = 'div',
|
|
11
|
+
...props
|
|
12
|
+
}, ref) => {
|
|
13
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'modal-body');
|
|
14
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
15
|
+
ref: ref,
|
|
16
|
+
className: classNames(className, bsPrefix),
|
|
17
|
+
...props
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
ModalBody.displayName = 'ModalBody';
|
|
21
|
+
export default ModalBody;
|
package/esm/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/esm/ModalFooter.js
CHANGED
|
@@ -1,2 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
5
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
const ModalFooter = /*#__PURE__*/React.forwardRef(({
|
|
8
|
+
className,
|
|
9
|
+
bsPrefix,
|
|
10
|
+
as: Component = 'div',
|
|
11
|
+
...props
|
|
12
|
+
}, ref) => {
|
|
13
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'modal-footer');
|
|
14
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
15
|
+
ref: ref,
|
|
16
|
+
className: classNames(className, bsPrefix),
|
|
17
|
+
...props
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
ModalFooter.displayName = 'ModalFooter';
|
|
21
|
+
export default ModalFooter;
|
package/esm/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/esm/ModalTitle.js
CHANGED
|
@@ -1,6 +1,23 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
2
5
|
import divWithClassName from './divWithClassName';
|
|
6
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
7
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
8
|
const DivStyledAsH4 = divWithClassName('h4');
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
9
|
+
const ModalTitle = /*#__PURE__*/React.forwardRef(({
|
|
10
|
+
className,
|
|
11
|
+
bsPrefix,
|
|
12
|
+
as: Component = DivStyledAsH4,
|
|
13
|
+
...props
|
|
14
|
+
}, ref) => {
|
|
15
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'modal-title');
|
|
16
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
17
|
+
ref: ref,
|
|
18
|
+
className: classNames(className, bsPrefix),
|
|
19
|
+
...props
|
|
20
|
+
});
|
|
21
|
+
});
|
|
22
|
+
ModalTitle.displayName = 'ModalTitle';
|
|
23
|
+
export default ModalTitle;
|
package/esm/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/esm/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/esm/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/esm/NavItem.js
CHANGED
|
@@ -1,2 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
5
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
const NavItem = /*#__PURE__*/React.forwardRef(({
|
|
8
|
+
className,
|
|
9
|
+
bsPrefix,
|
|
10
|
+
as: Component = 'div',
|
|
11
|
+
...props
|
|
12
|
+
}, ref) => {
|
|
13
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'nav-item');
|
|
14
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
15
|
+
ref: ref,
|
|
16
|
+
className: classNames(className, bsPrefix),
|
|
17
|
+
...props
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
NavItem.displayName = 'NavItem';
|
|
21
|
+
export default NavItem;
|
package/esm/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/esm/Navbar.js
CHANGED
|
@@ -5,17 +5,14 @@ import * as React from 'react';
|
|
|
5
5
|
import { useCallback, useMemo } from 'react';
|
|
6
6
|
import SelectableContext from '@restart/ui/SelectableContext';
|
|
7
7
|
import { useUncontrolled } from 'uncontrollable';
|
|
8
|
-
import createWithBsPrefix from './createWithBsPrefix';
|
|
9
8
|
import NavbarBrand from './NavbarBrand';
|
|
10
9
|
import NavbarCollapse from './NavbarCollapse';
|
|
11
10
|
import NavbarToggle from './NavbarToggle';
|
|
12
11
|
import NavbarOffcanvas from './NavbarOffcanvas';
|
|
13
12
|
import { useBootstrapPrefix } from './ThemeProvider';
|
|
14
13
|
import NavbarContext from './NavbarContext';
|
|
14
|
+
import NavbarText from './NavbarText';
|
|
15
15
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
16
|
-
const NavbarText = createWithBsPrefix('navbar-text', {
|
|
17
|
-
Component: 'span'
|
|
18
|
-
});
|
|
19
16
|
const Navbar = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
20
17
|
const {
|
|
21
18
|
bsPrefix: initialBsPrefix,
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import type { BsPrefixProps, BsPrefixRefForwardingComponent } from './helpers';
|
|
3
|
+
export interface NavbarTextProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const NavbarText: BsPrefixRefForwardingComponent<'span', NavbarTextProps>;
|
|
6
|
+
export default NavbarText;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
5
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
const NavbarText = /*#__PURE__*/React.forwardRef(({
|
|
8
|
+
className,
|
|
9
|
+
bsPrefix,
|
|
10
|
+
as: Component = 'span',
|
|
11
|
+
...props
|
|
12
|
+
}, ref) => {
|
|
13
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'navbar-text');
|
|
14
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
15
|
+
ref: ref,
|
|
16
|
+
className: classNames(className, bsPrefix),
|
|
17
|
+
...props
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
NavbarText.displayName = 'NavbarText';
|
|
21
|
+
export default NavbarText;
|
package/esm/Offcanvas.d.ts
CHANGED
|
@@ -11,8 +11,8 @@ export interface OffcanvasProps extends Omit<BaseModalProps, 'role' | 'renderBac
|
|
|
11
11
|
renderStaticNode?: boolean;
|
|
12
12
|
}
|
|
13
13
|
declare const _default: BsPrefixRefForwardingComponent<"div", OffcanvasProps> & {
|
|
14
|
-
Body: BsPrefixRefForwardingComponent<"div",
|
|
14
|
+
Body: BsPrefixRefForwardingComponent<"div", import("./OffcanvasBody").OffcanvasBodyProps>;
|
|
15
15
|
Header: React.ForwardRefExoticComponent<import("./OffcanvasHeader").OffcanvasHeaderProps & React.RefAttributes<HTMLDivElement>>;
|
|
16
|
-
Title: BsPrefixRefForwardingComponent<
|
|
16
|
+
Title: BsPrefixRefForwardingComponent<"div", import("./OffcanvasTitle").OffcanvasTitleProps>;
|
|
17
17
|
};
|
|
18
18
|
export default _default;
|
package/esm/OffcanvasBody.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 OffcanvasBodyProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const OffcanvasBody: BsPrefixRefForwardingComponent<'div', OffcanvasBodyProps>;
|
|
6
|
+
export default OffcanvasBody;
|
package/esm/OffcanvasBody.js
CHANGED
|
@@ -1,2 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
5
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
const OffcanvasBody = /*#__PURE__*/React.forwardRef(({
|
|
8
|
+
className,
|
|
9
|
+
bsPrefix,
|
|
10
|
+
as: Component = 'div',
|
|
11
|
+
...props
|
|
12
|
+
}, ref) => {
|
|
13
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'offcanvas-body');
|
|
14
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
15
|
+
ref: ref,
|
|
16
|
+
className: classNames(className, bsPrefix),
|
|
17
|
+
...props
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
OffcanvasBody.displayName = 'OffcanvasBody';
|
|
21
|
+
export default OffcanvasBody;
|
package/esm/OffcanvasTitle.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 OffcanvasTitleProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const OffcanvasTitle: BsPrefixRefForwardingComponent<'div', OffcanvasTitleProps>;
|
|
6
|
+
export default OffcanvasTitle;
|
package/esm/OffcanvasTitle.js
CHANGED
|
@@ -1,6 +1,23 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
2
5
|
import divWithClassName from './divWithClassName';
|
|
6
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
7
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
8
|
const DivStyledAsH5 = divWithClassName('h5');
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
9
|
+
const OffcanvasTitle = /*#__PURE__*/React.forwardRef(({
|
|
10
|
+
className,
|
|
11
|
+
bsPrefix,
|
|
12
|
+
as: Component = DivStyledAsH5,
|
|
13
|
+
...props
|
|
14
|
+
}, ref) => {
|
|
15
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'offcanvas-title');
|
|
16
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
17
|
+
ref: ref,
|
|
18
|
+
className: classNames(className, bsPrefix),
|
|
19
|
+
...props
|
|
20
|
+
});
|
|
21
|
+
});
|
|
22
|
+
OffcanvasTitle.displayName = 'OffcanvasTitle';
|
|
23
|
+
export default OffcanvasTitle;
|
package/esm/Overlay.js
CHANGED
|
@@ -40,10 +40,11 @@ const Overlay = /*#__PURE__*/React.forwardRef(({
|
|
|
40
40
|
popperConfig == null ? void 0 : popperConfig.onFirstUpdate == null ? void 0 : popperConfig.onFirstUpdate(state);
|
|
41
41
|
});
|
|
42
42
|
useIsomorphicEffect(() => {
|
|
43
|
-
if (firstRenderedState) {
|
|
43
|
+
if (firstRenderedState && outerProps.target) {
|
|
44
|
+
// Must wait for target element to resolve before updating popper.
|
|
44
45
|
popperRef.current.scheduleUpdate == null ? void 0 : popperRef.current.scheduleUpdate();
|
|
45
46
|
}
|
|
46
|
-
}, [firstRenderedState]);
|
|
47
|
+
}, [firstRenderedState, outerProps.target]);
|
|
47
48
|
useEffect(() => {
|
|
48
49
|
if (!outerShow) {
|
|
49
50
|
setFirstRenderedState(null);
|
package/esm/Popover.d.ts
CHANGED
|
@@ -12,8 +12,8 @@ export interface PopoverProps extends React.HTMLAttributes<HTMLDivElement>, BsPr
|
|
|
12
12
|
hasDoneInitialMeasure?: boolean;
|
|
13
13
|
}
|
|
14
14
|
declare const _default: React.ForwardRefExoticComponent<PopoverProps & React.RefAttributes<HTMLDivElement>> & {
|
|
15
|
-
Header: import("./helpers").BsPrefixRefForwardingComponent<"div",
|
|
16
|
-
Body: import("./helpers").BsPrefixRefForwardingComponent<"div",
|
|
15
|
+
Header: import("./helpers").BsPrefixRefForwardingComponent<"div", import("./PopoverHeader").PopoverHeaderProps>;
|
|
16
|
+
Body: import("./helpers").BsPrefixRefForwardingComponent<"div", import("./PopoverBody").PopoverBodyProps>;
|
|
17
17
|
POPPER_OFFSET: readonly [0, 8];
|
|
18
18
|
};
|
|
19
19
|
export default _default;
|
package/esm/PopoverBody.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 PopoverBodyProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const PopoverBody: BsPrefixRefForwardingComponent<'div', PopoverBodyProps>;
|
|
6
|
+
export default PopoverBody;
|
package/esm/PopoverBody.js
CHANGED
|
@@ -1,2 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
5
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
const PopoverBody = /*#__PURE__*/React.forwardRef(({
|
|
8
|
+
className,
|
|
9
|
+
bsPrefix,
|
|
10
|
+
as: Component = 'div',
|
|
11
|
+
...props
|
|
12
|
+
}, ref) => {
|
|
13
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'popover-body');
|
|
14
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
15
|
+
ref: ref,
|
|
16
|
+
className: classNames(className, bsPrefix),
|
|
17
|
+
...props
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
PopoverBody.displayName = 'PopoverBody';
|
|
21
|
+
export default PopoverBody;
|
package/esm/PopoverHeader.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 PopoverHeaderProps extends BsPrefixProps, React.HTMLAttributes<HTMLElement> {
|
|
4
|
+
}
|
|
5
|
+
declare const PopoverHeader: BsPrefixRefForwardingComponent<'div', PopoverHeaderProps>;
|
|
6
|
+
export default PopoverHeader;
|
package/esm/PopoverHeader.js
CHANGED
|
@@ -1,2 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import classNames from 'classnames';
|
|
5
|
+
import { useBootstrapPrefix } from './ThemeProvider';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
const PopoverHeader = /*#__PURE__*/React.forwardRef(({
|
|
8
|
+
className,
|
|
9
|
+
bsPrefix,
|
|
10
|
+
as: Component = 'div',
|
|
11
|
+
...props
|
|
12
|
+
}, ref) => {
|
|
13
|
+
bsPrefix = useBootstrapPrefix(bsPrefix, 'popover-header');
|
|
14
|
+
return /*#__PURE__*/_jsx(Component, {
|
|
15
|
+
ref: ref,
|
|
16
|
+
className: classNames(className, bsPrefix),
|
|
17
|
+
...props
|
|
18
|
+
});
|
|
19
|
+
});
|
|
20
|
+
PopoverHeader.displayName = 'PopoverHeader';
|
|
21
|
+
export default PopoverHeader;
|