react-bootstrap 2.5.0-beta.1 → 2.6.0
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.d.ts +15 -0
- package/cjs/AbstractNavItem.d.ts +19 -0
- package/cjs/AccordionCollapse.d.ts +3 -0
- package/cjs/AccordionCollapse.js +3 -0
- package/cjs/AccordionToggle.d.ts +11 -0
- package/cjs/CardColumns.d.ts +2 -0
- package/cjs/CardContext.d.ts +6 -0
- package/cjs/CardDeck.d.ts +2 -0
- package/cjs/CardImg.d.ts +1 -1
- package/cjs/Carousel.d.ts +1 -1
- package/cjs/CloseButton.d.ts +1 -1
- package/cjs/CloseButton.js +3 -0
- package/cjs/Form.d.ts +6 -6
- package/cjs/FormFile.d.ts +23 -0
- package/cjs/FormFileInput.d.ts +10 -0
- package/cjs/FormFileLabel.d.ts +7 -0
- package/cjs/Jumbotron.d.ts +7 -0
- package/cjs/ListGroup.d.ts +1 -1
- package/cjs/ListGroupItem.js +3 -0
- package/cjs/Media.d.ts +8 -0
- package/cjs/Modal.js +1 -1
- package/cjs/Nav.d.ts +1 -1
- package/cjs/Navbar.d.ts +1 -1
- package/cjs/NavbarOffcanvas.js +2 -1
- package/cjs/Offcanvas.d.ts +1 -0
- package/cjs/Offcanvas.js +4 -2
- package/cjs/OverlayTrigger.d.ts +5 -5
- package/cjs/PageItem.js +0 -1
- package/cjs/PopoverContent.d.ts +5 -0
- package/cjs/PopoverTitle.d.ts +5 -0
- package/cjs/ResponsiveEmbed.d.ts +9 -0
- package/cjs/SafeAnchor.d.ts +17 -0
- package/cjs/SelectableContext.d.ts +5 -0
- package/cjs/Spinner.d.ts +1 -1
- package/cjs/Spinner.js +1 -1
- package/cjs/Tab.d.ts +2 -2
- package/cjs/TabContainer.d.ts +2 -2
- package/cjs/TabContext.d.ts +12 -0
- package/cjs/Tabs.d.ts +3 -3
- package/cjs/safeFindDOMNode.d.ts +1 -1
- package/cjs/types.d.ts +1 -1
- package/cjs/usePopperMarginModifiers.d.ts +4 -0
- package/dist/react-bootstrap.js +125 -275
- package/dist/react-bootstrap.min.js +1 -1
- package/esm/AbstractNav.d.ts +15 -0
- package/esm/AbstractNavItem.d.ts +19 -0
- package/esm/AccordionCollapse.d.ts +3 -0
- package/esm/AccordionCollapse.js +4 -0
- package/esm/AccordionToggle.d.ts +11 -0
- package/esm/CardColumns.d.ts +2 -0
- package/esm/CardContext.d.ts +6 -0
- package/esm/CardDeck.d.ts +2 -0
- package/esm/CardImg.d.ts +1 -1
- package/esm/Carousel.d.ts +1 -1
- package/esm/CloseButton.d.ts +1 -1
- package/esm/CloseButton.js +3 -0
- package/esm/Form.d.ts +6 -6
- package/esm/FormFile.d.ts +23 -0
- package/esm/FormFileInput.d.ts +10 -0
- package/esm/FormFileLabel.d.ts +7 -0
- package/esm/Jumbotron.d.ts +7 -0
- package/esm/ListGroup.d.ts +1 -1
- package/esm/ListGroupItem.js +2 -0
- package/esm/Media.d.ts +8 -0
- package/esm/Modal.js +1 -1
- package/esm/Nav.d.ts +1 -1
- package/esm/Navbar.d.ts +1 -1
- package/esm/NavbarOffcanvas.js +2 -1
- package/esm/Offcanvas.d.ts +1 -0
- package/esm/Offcanvas.js +4 -2
- package/esm/OverlayTrigger.d.ts +5 -5
- package/esm/PageItem.js +0 -1
- package/esm/PopoverContent.d.ts +5 -0
- package/esm/PopoverTitle.d.ts +5 -0
- package/esm/ResponsiveEmbed.d.ts +9 -0
- package/esm/SafeAnchor.d.ts +17 -0
- package/esm/SelectableContext.d.ts +5 -0
- package/esm/Spinner.d.ts +1 -1
- package/esm/Spinner.js +1 -1
- package/esm/Tab.d.ts +2 -2
- package/esm/TabContainer.d.ts +2 -2
- package/esm/TabContext.d.ts +12 -0
- package/esm/Tabs.d.ts +3 -3
- package/esm/safeFindDOMNode.d.ts +1 -1
- package/esm/types.d.ts +1 -1
- package/esm/usePopperMarginModifiers.d.ts +4 -0
- package/package.json +2 -2
package/dist/react-bootstrap.js
CHANGED
|
@@ -1101,7 +1101,7 @@ var prop_types = __webpack_require__(526);
|
|
|
1101
1101
|
var prop_types_default = /*#__PURE__*/__webpack_require__.n(prop_types);
|
|
1102
1102
|
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/extends.js
|
|
1103
1103
|
function extends_extends() {
|
|
1104
|
-
extends_extends = Object.assign
|
|
1104
|
+
extends_extends = Object.assign ? Object.assign.bind() : function (target) {
|
|
1105
1105
|
for (var i = 1; i < arguments.length; i++) {
|
|
1106
1106
|
var source = arguments[i];
|
|
1107
1107
|
|
|
@@ -1114,7 +1114,6 @@ function extends_extends() {
|
|
|
1114
1114
|
|
|
1115
1115
|
return target;
|
|
1116
1116
|
};
|
|
1117
|
-
|
|
1118
1117
|
return extends_extends.apply(this, arguments);
|
|
1119
1118
|
}
|
|
1120
1119
|
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js
|
|
@@ -1774,11 +1773,10 @@ function style(node, property) {
|
|
|
1774
1773
|
/* harmony default export */ const css = (style);
|
|
1775
1774
|
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js
|
|
1776
1775
|
function _setPrototypeOf(o, p) {
|
|
1777
|
-
_setPrototypeOf = Object.setPrototypeOf
|
|
1776
|
+
_setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
|
|
1778
1777
|
o.__proto__ = p;
|
|
1779
1778
|
return o;
|
|
1780
1779
|
};
|
|
1781
|
-
|
|
1782
1780
|
return _setPrototypeOf(o, p);
|
|
1783
1781
|
}
|
|
1784
1782
|
;// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/inheritsLoose.js
|
|
@@ -2550,7 +2548,7 @@ const TransitionWrapper = /*#__PURE__*/external_root_React_commonjs2_react_commo
|
|
|
2550
2548
|
})
|
|
2551
2549
|
}, void 0, false, {
|
|
2552
2550
|
fileName: TransitionWrapper_jsxFileName,
|
|
2553
|
-
lineNumber:
|
|
2551
|
+
lineNumber: 66,
|
|
2554
2552
|
columnNumber: 7
|
|
2555
2553
|
}, undefined);
|
|
2556
2554
|
});
|
|
@@ -2771,6 +2769,10 @@ const AccordionCollapse_propTypes = {
|
|
|
2771
2769
|
/** Children prop should only contain a single child, and is enforced as such */
|
|
2772
2770
|
children: (prop_types_default()).element.isRequired
|
|
2773
2771
|
};
|
|
2772
|
+
/**
|
|
2773
|
+
* This component accepts all of [`Collapse`'s props](/utilities/transitions/#collapse-props).
|
|
2774
|
+
*/
|
|
2775
|
+
|
|
2774
2776
|
const AccordionCollapse = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_.forwardRef(({
|
|
2775
2777
|
as: Component = 'div',
|
|
2776
2778
|
bsPrefix,
|
|
@@ -2792,12 +2794,12 @@ const AccordionCollapse = /*#__PURE__*/external_root_React_commonjs2_react_commo
|
|
|
2792
2794
|
children: external_root_React_commonjs2_react_commonjs_react_amd_react_.Children.only(children)
|
|
2793
2795
|
}, void 0, false, {
|
|
2794
2796
|
fileName: AccordionCollapse_jsxFileName,
|
|
2795
|
-
lineNumber:
|
|
2797
|
+
lineNumber: 56,
|
|
2796
2798
|
columnNumber: 9
|
|
2797
2799
|
}, undefined)
|
|
2798
2800
|
}, void 0, false, {
|
|
2799
2801
|
fileName: AccordionCollapse_jsxFileName,
|
|
2800
|
-
lineNumber:
|
|
2802
|
+
lineNumber: 50,
|
|
2801
2803
|
columnNumber: 7
|
|
2802
2804
|
}, undefined);
|
|
2803
2805
|
});
|
|
@@ -3076,6 +3078,17 @@ const Accordion_propTypes = {
|
|
|
3076
3078
|
/** The default active key that is expanded on start */
|
|
3077
3079
|
defaultActiveKey: prop_types_default().oneOfType([(prop_types_default()).string, (prop_types_default()).array]),
|
|
3078
3080
|
|
|
3081
|
+
/**
|
|
3082
|
+
* Callback fired when the active item changes.
|
|
3083
|
+
*
|
|
3084
|
+
* ```js
|
|
3085
|
+
* (eventKey: string | string[] | null, event: Object) => void
|
|
3086
|
+
* ```
|
|
3087
|
+
*
|
|
3088
|
+
* @controllable activeIndex
|
|
3089
|
+
*/
|
|
3090
|
+
onSelect: (prop_types_default()).func,
|
|
3091
|
+
|
|
3079
3092
|
/** Renders accordion edge-to-edge with its parent container */
|
|
3080
3093
|
flush: (prop_types_default()).bool,
|
|
3081
3094
|
|
|
@@ -3110,12 +3123,12 @@ const Accordion = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_reac
|
|
|
3110
3123
|
className: classnames_default()(className, prefix, flush && `${prefix}-flush`)
|
|
3111
3124
|
}, void 0, false, {
|
|
3112
3125
|
fileName: Accordion_jsxFileName,
|
|
3113
|
-
lineNumber:
|
|
3126
|
+
lineNumber: 87,
|
|
3114
3127
|
columnNumber: 9
|
|
3115
3128
|
}, undefined)
|
|
3116
3129
|
}, void 0, false, {
|
|
3117
3130
|
fileName: Accordion_jsxFileName,
|
|
3118
|
-
lineNumber:
|
|
3131
|
+
lineNumber: 86,
|
|
3119
3132
|
columnNumber: 7
|
|
3120
3133
|
}, undefined);
|
|
3121
3134
|
});
|
|
@@ -3160,7 +3173,7 @@ function useEventCallback(fn) {
|
|
|
3160
3173
|
return ref.current && ref.current.apply(ref, arguments);
|
|
3161
3174
|
}, [ref]);
|
|
3162
3175
|
}
|
|
3163
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3176
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useCallbackRef.js
|
|
3164
3177
|
|
|
3165
3178
|
/**
|
|
3166
3179
|
* A convenience hook around `useState` designed to be paired with
|
|
@@ -3190,37 +3203,7 @@ function useEventCallback(fn) {
|
|
|
3190
3203
|
function useCallbackRef() {
|
|
3191
3204
|
return (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useState)(null);
|
|
3192
3205
|
}
|
|
3193
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3194
|
-
|
|
3195
|
-
/**
|
|
3196
|
-
* Creates a `Ref` whose value is updated in an effect, ensuring the most recent
|
|
3197
|
-
* value is the one rendered with. Generally only required for Concurrent mode usage
|
|
3198
|
-
* where previous work in `render()` may be discarded before being used.
|
|
3199
|
-
*
|
|
3200
|
-
* This is safe to access in an event handler.
|
|
3201
|
-
*
|
|
3202
|
-
* @param value The `Ref` value
|
|
3203
|
-
*/
|
|
3204
|
-
|
|
3205
|
-
function esm_useCommittedRef_useCommittedRef(value) {
|
|
3206
|
-
var ref = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)(value);
|
|
3207
|
-
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect)(function () {
|
|
3208
|
-
ref.current = value;
|
|
3209
|
-
}, [value]);
|
|
3210
|
-
return ref;
|
|
3211
|
-
}
|
|
3212
|
-
|
|
3213
|
-
/* harmony default export */ const hooks_esm_useCommittedRef = (esm_useCommittedRef_useCommittedRef);
|
|
3214
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/ui/node_modules/@restart/hooks/esm/useEventCallback.js
|
|
3215
|
-
|
|
3216
|
-
|
|
3217
|
-
function useEventCallback_useEventCallback(fn) {
|
|
3218
|
-
var ref = hooks_esm_useCommittedRef(fn);
|
|
3219
|
-
return (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useCallback)(function () {
|
|
3220
|
-
return ref.current && ref.current.apply(ref, arguments);
|
|
3221
|
-
}, [ref]);
|
|
3222
|
-
}
|
|
3223
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/ui/node_modules/@restart/hooks/esm/useEventListener.js
|
|
3206
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useEventListener.js
|
|
3224
3207
|
|
|
3225
3208
|
|
|
3226
3209
|
/**
|
|
@@ -3238,7 +3221,7 @@ function useEventListener_useEventListener(eventTarget, event, listener, capture
|
|
|
3238
3221
|
capture = false;
|
|
3239
3222
|
}
|
|
3240
3223
|
|
|
3241
|
-
var handler =
|
|
3224
|
+
var handler = useEventCallback(listener);
|
|
3242
3225
|
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect)(function () {
|
|
3243
3226
|
var target = typeof eventTarget === 'function' ? eventTarget() : eventTarget;
|
|
3244
3227
|
target.addEventListener(event, handler, capture);
|
|
@@ -3247,7 +3230,7 @@ function useEventListener_useEventListener(eventTarget, event, listener, capture
|
|
|
3247
3230
|
};
|
|
3248
3231
|
}, [eventTarget]);
|
|
3249
3232
|
}
|
|
3250
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3233
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useGlobalListener.js
|
|
3251
3234
|
|
|
3252
3235
|
|
|
3253
3236
|
/**
|
|
@@ -3275,7 +3258,7 @@ function useGlobalListener(event, handler, capture) {
|
|
|
3275
3258
|
}, []);
|
|
3276
3259
|
return useEventListener(documentTarget, event, handler, capture);
|
|
3277
3260
|
}
|
|
3278
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3261
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useInterval.js
|
|
3279
3262
|
|
|
3280
3263
|
|
|
3281
3264
|
/**
|
|
@@ -3334,7 +3317,7 @@ function useInterval(fn, ms, paused, runImmediately) {
|
|
|
3334
3317
|
}
|
|
3335
3318
|
|
|
3336
3319
|
/* harmony default export */ const esm_useInterval = ((/* unused pure expression or super */ null && (useInterval)));
|
|
3337
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3320
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useRafInterval.js
|
|
3338
3321
|
|
|
3339
3322
|
|
|
3340
3323
|
|
|
@@ -3373,7 +3356,7 @@ function useRafInterval(fn, ms, paused) {
|
|
|
3373
3356
|
}
|
|
3374
3357
|
|
|
3375
3358
|
/* harmony default export */ const esm_useRafInterval = ((/* unused pure expression or super */ null && (useRafInterval)));
|
|
3376
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3359
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useMergeState.js
|
|
3377
3360
|
function useMergeState_extends() {
|
|
3378
3361
|
useMergeState_extends = Object.assign || function (target) {
|
|
3379
3362
|
for (var i = 1; i < arguments.length; i++) {
|
|
@@ -3430,7 +3413,7 @@ function useMergeState_useMergeState(initialState) {
|
|
|
3430
3413
|
}, [setState]);
|
|
3431
3414
|
return [state, updater];
|
|
3432
3415
|
}
|
|
3433
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3416
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useMergeStateFromProps.js
|
|
3434
3417
|
|
|
3435
3418
|
function useMergeStateFromProps(props, gDSFP, initialState) {
|
|
3436
3419
|
var _useMergeState = useMergeState(initialState),
|
|
@@ -3441,7 +3424,7 @@ function useMergeStateFromProps(props, gDSFP, initialState) {
|
|
|
3441
3424
|
if (nextState !== null) setState(nextState);
|
|
3442
3425
|
return [state, setState];
|
|
3443
3426
|
}
|
|
3444
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3427
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useMounted.js
|
|
3445
3428
|
|
|
3446
3429
|
/**
|
|
3447
3430
|
* Track whether a component is current mounted. Generally less preferable than
|
|
@@ -3477,7 +3460,7 @@ function useMounted() {
|
|
|
3477
3460
|
}, []);
|
|
3478
3461
|
return isMounted.current;
|
|
3479
3462
|
}
|
|
3480
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3463
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/usePrevious.js
|
|
3481
3464
|
|
|
3482
3465
|
/**
|
|
3483
3466
|
* Store the last of some value. Tracked via a `Ref` only updating it
|
|
@@ -3504,7 +3487,7 @@ function usePrevious(value) {
|
|
|
3504
3487
|
});
|
|
3505
3488
|
return ref.current;
|
|
3506
3489
|
}
|
|
3507
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3490
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useImage.js
|
|
3508
3491
|
|
|
3509
3492
|
/**
|
|
3510
3493
|
* Fetch and load an image for programatic use such as in a `<canvas>` element.
|
|
@@ -3583,7 +3566,7 @@ function useImage(imageOrUrl, crossOrigin) {
|
|
|
3583
3566
|
}, [imageOrUrl, crossOrigin]);
|
|
3584
3567
|
return state;
|
|
3585
3568
|
}
|
|
3586
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3569
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useIsomorphicEffect.js
|
|
3587
3570
|
|
|
3588
3571
|
var isReactNative = typeof __webpack_require__.g !== 'undefined' && // @ts-ignore
|
|
3589
3572
|
__webpack_require__.g.navigator && // @ts-ignore
|
|
@@ -3599,7 +3582,7 @@ var isDOM = typeof document !== 'undefined';
|
|
|
3599
3582
|
*/
|
|
3600
3583
|
|
|
3601
3584
|
/* harmony default export */ const useIsomorphicEffect = (isDOM || isReactNative ? external_root_React_commonjs2_react_commonjs_react_amd_react_.useLayoutEffect : external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect);
|
|
3602
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3585
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useResizeObserver.js
|
|
3603
3586
|
|
|
3604
3587
|
|
|
3605
3588
|
var targetMap = new WeakMap();
|
|
@@ -3652,7 +3635,7 @@ function useResizeObserver(element) {
|
|
|
3652
3635
|
}, [element]);
|
|
3653
3636
|
return rect;
|
|
3654
3637
|
}
|
|
3655
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
3638
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/index.js
|
|
3656
3639
|
|
|
3657
3640
|
|
|
3658
3641
|
|
|
@@ -3698,6 +3681,7 @@ function useButtonProps({
|
|
|
3698
3681
|
href,
|
|
3699
3682
|
target,
|
|
3700
3683
|
rel,
|
|
3684
|
+
role,
|
|
3701
3685
|
onClick,
|
|
3702
3686
|
tabIndex = 0,
|
|
3703
3687
|
type
|
|
@@ -3751,7 +3735,7 @@ function useButtonProps({
|
|
|
3751
3735
|
}
|
|
3752
3736
|
|
|
3753
3737
|
return [{
|
|
3754
|
-
role: 'button',
|
|
3738
|
+
role: role != null ? role : 'button',
|
|
3755
3739
|
// explicitly undefined so that it overrides the props disabled in a spread
|
|
3756
3740
|
// e.g. <Tag {...props} {...hookProps} />
|
|
3757
3741
|
disabled: undefined,
|
|
@@ -3826,12 +3810,12 @@ const Anchor = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_a
|
|
|
3826
3810
|
const [buttonProps] = useButtonProps(Object.assign({
|
|
3827
3811
|
tagName: 'a'
|
|
3828
3812
|
}, props));
|
|
3829
|
-
const handleKeyDown =
|
|
3813
|
+
const handleKeyDown = useEventCallback(e => {
|
|
3830
3814
|
buttonProps.onKeyDown(e);
|
|
3831
3815
|
onKeyDown == null ? void 0 : onKeyDown(e);
|
|
3832
3816
|
});
|
|
3833
3817
|
|
|
3834
|
-
if (Anchor_isTrivialHref(props.href)
|
|
3818
|
+
if (Anchor_isTrivialHref(props.href) || props.role === 'button') {
|
|
3835
3819
|
return /*#__PURE__*/(0,jsx_runtime.jsx)("a", Object.assign({
|
|
3836
3820
|
ref: ref
|
|
3837
3821
|
}, props, buttonProps, {
|
|
@@ -3975,7 +3959,10 @@ var CloseButton_jsxFileName = "/Users/kyletsang/Documents/Kyle/Code/react-bootst
|
|
|
3975
3959
|
|
|
3976
3960
|
|
|
3977
3961
|
const CloseButton_propTypes = {
|
|
3962
|
+
/** An accessible label indicating the relevant information about the Close Button. */
|
|
3978
3963
|
'aria-label': (prop_types_default()).string,
|
|
3964
|
+
|
|
3965
|
+
/** A callback fired after the Close Button is clicked. */
|
|
3979
3966
|
onClick: (prop_types_default()).func,
|
|
3980
3967
|
|
|
3981
3968
|
/**
|
|
@@ -3999,7 +3986,7 @@ const CloseButton = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_re
|
|
|
3999
3986
|
...props
|
|
4000
3987
|
}, void 0, false, {
|
|
4001
3988
|
fileName: CloseButton_jsxFileName,
|
|
4002
|
-
lineNumber:
|
|
3989
|
+
lineNumber: 33,
|
|
4003
3990
|
columnNumber: 5
|
|
4004
3991
|
}, undefined));
|
|
4005
3992
|
CloseButton.displayName = 'CloseButton';
|
|
@@ -4865,42 +4852,6 @@ function useUpdateEffect(fn, deps) {
|
|
|
4865
4852
|
}
|
|
4866
4853
|
|
|
4867
4854
|
/* harmony default export */ const esm_useUpdateEffect = (useUpdateEffect);
|
|
4868
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useMounted.js
|
|
4869
|
-
|
|
4870
|
-
/**
|
|
4871
|
-
* Track whether a component is current mounted. Generally less preferable than
|
|
4872
|
-
* properlly canceling effects so they don't run after a component is unmounted,
|
|
4873
|
-
* but helpful in cases where that isn't feasible, such as a `Promise` resolution.
|
|
4874
|
-
*
|
|
4875
|
-
* @returns a function that returns the current isMounted state of the component
|
|
4876
|
-
*
|
|
4877
|
-
* ```ts
|
|
4878
|
-
* const [data, setData] = useState(null)
|
|
4879
|
-
* const isMounted = useMounted()
|
|
4880
|
-
*
|
|
4881
|
-
* useEffect(() => {
|
|
4882
|
-
* fetchdata().then((newData) => {
|
|
4883
|
-
* if (isMounted()) {
|
|
4884
|
-
* setData(newData);
|
|
4885
|
-
* }
|
|
4886
|
-
* })
|
|
4887
|
-
* })
|
|
4888
|
-
* ```
|
|
4889
|
-
*/
|
|
4890
|
-
|
|
4891
|
-
function useMounted_useMounted() {
|
|
4892
|
-
var mounted = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)(true);
|
|
4893
|
-
var isMounted = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)(function () {
|
|
4894
|
-
return mounted.current;
|
|
4895
|
-
});
|
|
4896
|
-
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect)(function () {
|
|
4897
|
-
mounted.current = true;
|
|
4898
|
-
return function () {
|
|
4899
|
-
mounted.current = false;
|
|
4900
|
-
};
|
|
4901
|
-
}, []);
|
|
4902
|
-
return isMounted.current;
|
|
4903
|
-
}
|
|
4904
4855
|
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useUpdatedRef.js
|
|
4905
4856
|
|
|
4906
4857
|
/**
|
|
@@ -4975,7 +4926,7 @@ function setChainedTimeout(handleRef, fn, timeoutAtMs) {
|
|
|
4975
4926
|
|
|
4976
4927
|
|
|
4977
4928
|
function useTimeout() {
|
|
4978
|
-
var isMounted =
|
|
4929
|
+
var isMounted = useMounted(); // types are confused between node and web here IDK
|
|
4979
4930
|
|
|
4980
4931
|
var handleRef = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)();
|
|
4981
4932
|
useWillUnmount(function () {
|
|
@@ -5757,7 +5708,7 @@ var toArray = Function.prototype.bind.call(Function.prototype.call, [].slice);
|
|
|
5757
5708
|
function qsa(element, selector) {
|
|
5758
5709
|
return toArray(element.querySelectorAll(selector));
|
|
5759
5710
|
}
|
|
5760
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
5711
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useForceUpdate.js
|
|
5761
5712
|
|
|
5762
5713
|
/**
|
|
5763
5714
|
* Returns a function that triggers a component update. the hook equivalent to
|
|
@@ -5876,7 +5827,7 @@ function dequal(foo, bar) {
|
|
|
5876
5827
|
return foo !== foo && bar !== bar;
|
|
5877
5828
|
}
|
|
5878
5829
|
|
|
5879
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/
|
|
5830
|
+
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useSafeState.js
|
|
5880
5831
|
|
|
5881
5832
|
|
|
5882
5833
|
|
|
@@ -8031,14 +7982,14 @@ function useClickOutside(ref, onClickOutside = useClickOutside_noop, {
|
|
|
8031
7982
|
preventMouseClickOutsideRef.current = !currentTarget || isModifiedEvent(e) || !isLeftClickEvent(e) || !!contains_contains(currentTarget, e.target) || waitingForTrigger.current;
|
|
8032
7983
|
waitingForTrigger.current = false;
|
|
8033
7984
|
}, [ref]);
|
|
8034
|
-
const handleInitialMouse =
|
|
7985
|
+
const handleInitialMouse = useEventCallback(e => {
|
|
8035
7986
|
const currentTarget = getRefTarget(ref);
|
|
8036
7987
|
|
|
8037
7988
|
if (currentTarget && contains_contains(currentTarget, e.target)) {
|
|
8038
7989
|
waitingForTrigger.current = true;
|
|
8039
7990
|
}
|
|
8040
7991
|
});
|
|
8041
|
-
const handleMouse =
|
|
7992
|
+
const handleMouse = useEventCallback(e => {
|
|
8042
7993
|
if (!preventMouseClickOutsideRef.current) {
|
|
8043
7994
|
onClickOutside(e);
|
|
8044
7995
|
}
|
|
@@ -8116,7 +8067,7 @@ function mergeOptionsWithPopperConfig({
|
|
|
8116
8067
|
arrowElement,
|
|
8117
8068
|
popperConfig = {}
|
|
8118
8069
|
}) {
|
|
8119
|
-
var _modifiers$preventOve, _modifiers$preventOve2, _modifiers$offset, _modifiers$arrow;
|
|
8070
|
+
var _modifiers$eventListe, _modifiers$preventOve, _modifiers$preventOve2, _modifiers$offset, _modifiers$arrow;
|
|
8120
8071
|
|
|
8121
8072
|
const modifiers = toModifierMap(popperConfig.modifiers);
|
|
8122
8073
|
return Object.assign({}, popperConfig, {
|
|
@@ -8125,7 +8076,8 @@ function mergeOptionsWithPopperConfig({
|
|
|
8125
8076
|
strategy: fixed ? 'fixed' : popperConfig.strategy,
|
|
8126
8077
|
modifiers: toModifierArray(Object.assign({}, modifiers, {
|
|
8127
8078
|
eventListeners: {
|
|
8128
|
-
enabled: enableEvents
|
|
8079
|
+
enabled: enableEvents,
|
|
8080
|
+
options: (_modifiers$eventListe = modifiers.eventListeners) == null ? void 0 : _modifiers$eventListe.options
|
|
8129
8081
|
},
|
|
8130
8082
|
preventOverflow: Object.assign({}, modifiers.preventOverflow, {
|
|
8131
8083
|
options: containerPadding ? Object.assign({
|
|
@@ -8485,7 +8437,7 @@ function useDropdownItem({
|
|
|
8485
8437
|
} = navContext || {};
|
|
8486
8438
|
const eventKey = makeEventKey(key, href);
|
|
8487
8439
|
const isActive = active == null && key != null ? makeEventKey(activeKey) === eventKey : active;
|
|
8488
|
-
const handleClick =
|
|
8440
|
+
const handleClick = useEventCallback(event => {
|
|
8489
8441
|
if (disabled) return;
|
|
8490
8442
|
onClick == null ? void 0 : onClick(event);
|
|
8491
8443
|
|
|
@@ -8604,7 +8556,7 @@ function Dropdown({
|
|
|
8604
8556
|
source
|
|
8605
8557
|
});
|
|
8606
8558
|
}, [onToggle]);
|
|
8607
|
-
const handleSelect =
|
|
8559
|
+
const handleSelect = useEventCallback((key, event) => {
|
|
8608
8560
|
onSelect == null ? void 0 : onSelect(key, event);
|
|
8609
8561
|
toggle(false, event, 'select');
|
|
8610
8562
|
|
|
@@ -8626,12 +8578,12 @@ function Dropdown({
|
|
|
8626
8578
|
focusInDropdown.current = menuElement.contains(menuElement.ownerDocument.activeElement);
|
|
8627
8579
|
}
|
|
8628
8580
|
|
|
8629
|
-
const focusToggle =
|
|
8581
|
+
const focusToggle = useEventCallback(() => {
|
|
8630
8582
|
if (toggleElement && toggleElement.focus) {
|
|
8631
8583
|
toggleElement.focus();
|
|
8632
8584
|
}
|
|
8633
8585
|
});
|
|
8634
|
-
const maybeFocusFirst =
|
|
8586
|
+
const maybeFocusFirst = useEventCallback(() => {
|
|
8635
8587
|
const type = lastSourceEvent.current;
|
|
8636
8588
|
let focusType = focusFirstItemOnShow;
|
|
8637
8589
|
|
|
@@ -8833,22 +8785,6 @@ const DropdownItem_DropdownItem = /*#__PURE__*/external_root_React_commonjs2_rea
|
|
|
8833
8785
|
DropdownItem_DropdownItem.displayName = 'DropdownItem';
|
|
8834
8786
|
DropdownItem_DropdownItem.propTypes = DropdownItem_propTypes;
|
|
8835
8787
|
/* harmony default export */ const src_DropdownItem = (DropdownItem_DropdownItem);
|
|
8836
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useIsomorphicEffect.js
|
|
8837
|
-
|
|
8838
|
-
var useIsomorphicEffect_isReactNative = typeof __webpack_require__.g !== 'undefined' && // @ts-ignore
|
|
8839
|
-
__webpack_require__.g.navigator && // @ts-ignore
|
|
8840
|
-
__webpack_require__.g.navigator.product === 'ReactNative';
|
|
8841
|
-
var useIsomorphicEffect_isDOM = typeof document !== 'undefined';
|
|
8842
|
-
/**
|
|
8843
|
-
* Is `useLayoutEffect` in a DOM or React Native environment, otherwise resolves to useEffect
|
|
8844
|
-
* Only useful to avoid the console warning.
|
|
8845
|
-
*
|
|
8846
|
-
* PREFER `useEffect` UNLESS YOU KNOW WHAT YOU ARE DOING.
|
|
8847
|
-
*
|
|
8848
|
-
* @category effects
|
|
8849
|
-
*/
|
|
8850
|
-
|
|
8851
|
-
/* harmony default export */ const esm_useIsomorphicEffect = (useIsomorphicEffect_isDOM || useIsomorphicEffect_isReactNative ? external_root_React_commonjs2_react_commonjs_react_amd_react_.useLayoutEffect : external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect);
|
|
8852
8788
|
;// CONCATENATED MODULE: ./src/InputGroupContext.tsx
|
|
8853
8789
|
|
|
8854
8790
|
const InputGroupContext_context = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_.createContext(null);
|
|
@@ -9037,7 +8973,7 @@ const DropdownMenu_DropdownMenu = /*#__PURE__*/external_root_React_commonjs2_rea
|
|
|
9037
8973
|
placement
|
|
9038
8974
|
});
|
|
9039
8975
|
menuProps.ref = esm_useMergedRefs(useWrappedRefWithWarning(ref, 'DropdownMenu'), menuProps.ref);
|
|
9040
|
-
|
|
8976
|
+
useIsomorphicEffect(() => {
|
|
9041
8977
|
// Popper's initial position for the menu is incorrect when
|
|
9042
8978
|
// renderOnMount=true. Need to call update() to correct it.
|
|
9043
8979
|
if (show) popper == null ? void 0 : popper.update();
|
|
@@ -10677,47 +10613,6 @@ InputGroup.displayName = 'InputGroup';
|
|
|
10677
10613
|
Radio: InputGroupRadio,
|
|
10678
10614
|
Checkbox: InputGroupCheckbox
|
|
10679
10615
|
}));
|
|
10680
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/ui/node_modules/@restart/hooks/esm/useMergedRefs.js
|
|
10681
|
-
|
|
10682
|
-
|
|
10683
|
-
var useMergedRefs_toFnRef = function toFnRef(ref) {
|
|
10684
|
-
return !ref || typeof ref === 'function' ? ref : function (value) {
|
|
10685
|
-
ref.current = value;
|
|
10686
|
-
};
|
|
10687
|
-
};
|
|
10688
|
-
|
|
10689
|
-
function useMergedRefs_mergeRefs(refA, refB) {
|
|
10690
|
-
var a = useMergedRefs_toFnRef(refA);
|
|
10691
|
-
var b = useMergedRefs_toFnRef(refB);
|
|
10692
|
-
return function (value) {
|
|
10693
|
-
if (a) a(value);
|
|
10694
|
-
if (b) b(value);
|
|
10695
|
-
};
|
|
10696
|
-
}
|
|
10697
|
-
/**
|
|
10698
|
-
* Create and returns a single callback ref composed from two other Refs.
|
|
10699
|
-
*
|
|
10700
|
-
* ```tsx
|
|
10701
|
-
* const Button = React.forwardRef((props, ref) => {
|
|
10702
|
-
* const [element, attachRef] = useCallbackRef<HTMLButtonElement>();
|
|
10703
|
-
* const mergedRef = useMergedRefs(ref, attachRef);
|
|
10704
|
-
*
|
|
10705
|
-
* return <button ref={mergedRef} {...props}/>
|
|
10706
|
-
* })
|
|
10707
|
-
* ```
|
|
10708
|
-
*
|
|
10709
|
-
* @param refA A Callback or mutable Ref
|
|
10710
|
-
* @param refB A Callback or mutable Ref
|
|
10711
|
-
* @category refs
|
|
10712
|
-
*/
|
|
10713
|
-
|
|
10714
|
-
function useMergedRefs_useMergedRefs(refA, refB) {
|
|
10715
|
-
return (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useMemo)(function () {
|
|
10716
|
-
return useMergedRefs_mergeRefs(refA, refB);
|
|
10717
|
-
}, [refA, refB]);
|
|
10718
|
-
}
|
|
10719
|
-
|
|
10720
|
-
/* harmony default export */ const hooks_esm_useMergedRefs = (useMergedRefs_useMergedRefs);
|
|
10721
10616
|
;// CONCATENATED MODULE: ./node_modules/@restart/ui/esm/TabContext.js
|
|
10722
10617
|
|
|
10723
10618
|
const TabContext = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_.createContext(null);
|
|
@@ -10799,7 +10694,7 @@ function useNavItem({
|
|
|
10799
10694
|
}
|
|
10800
10695
|
}
|
|
10801
10696
|
|
|
10802
|
-
props.onClick =
|
|
10697
|
+
props.onClick = useEventCallback(e => {
|
|
10803
10698
|
if (disabled) return;
|
|
10804
10699
|
onClick == null ? void 0 : onClick(e);
|
|
10805
10700
|
|
|
@@ -10956,7 +10851,7 @@ const Nav = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_
|
|
|
10956
10851
|
|
|
10957
10852
|
needsRefocusRef.current = false;
|
|
10958
10853
|
});
|
|
10959
|
-
const mergedRef =
|
|
10854
|
+
const mergedRef = esm_useMergedRefs(ref, listNode);
|
|
10960
10855
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(esm_SelectableContext.Provider, {
|
|
10961
10856
|
value: handleSelect,
|
|
10962
10857
|
children: /*#__PURE__*/(0,jsx_runtime.jsx)(esm_NavContext.Provider, {
|
|
@@ -10989,6 +10884,7 @@ var ListGroupItem_jsxFileName = "/Users/kyletsang/Documents/Kyle/Code/react-boot
|
|
|
10989
10884
|
|
|
10990
10885
|
|
|
10991
10886
|
|
|
10887
|
+
|
|
10992
10888
|
const ListGroupItem_propTypes = {
|
|
10993
10889
|
/**
|
|
10994
10890
|
* @default 'list-group-item'
|
|
@@ -10996,7 +10892,7 @@ const ListGroupItem_propTypes = {
|
|
|
10996
10892
|
bsPrefix: (prop_types_default()).string,
|
|
10997
10893
|
|
|
10998
10894
|
/**
|
|
10999
|
-
* Sets contextual classes for list item
|
|
10895
|
+
* Sets contextual classes for list item.
|
|
11000
10896
|
* @type {('primary'|'secondary'|'success'|'danger'|'warning'|'info'|'dark'|'light')}
|
|
11001
10897
|
*/
|
|
11002
10898
|
variant: (prop_types_default()).string,
|
|
@@ -11008,21 +10904,25 @@ const ListGroupItem_propTypes = {
|
|
|
11008
10904
|
action: (prop_types_default()).bool,
|
|
11009
10905
|
|
|
11010
10906
|
/**
|
|
11011
|
-
* Sets list item as active
|
|
10907
|
+
* Sets list item as active.
|
|
11012
10908
|
*/
|
|
11013
10909
|
active: (prop_types_default()).bool,
|
|
11014
10910
|
|
|
11015
10911
|
/**
|
|
11016
|
-
* Sets list item state as disabled
|
|
10912
|
+
* Sets list item state as disabled.
|
|
11017
10913
|
*/
|
|
11018
10914
|
disabled: (prop_types_default()).bool,
|
|
11019
10915
|
eventKey: prop_types_default().oneOfType([(prop_types_default()).string, (prop_types_default()).number]),
|
|
10916
|
+
|
|
10917
|
+
/** A callback function for when this component is clicked. */
|
|
11020
10918
|
onClick: (prop_types_default()).func,
|
|
10919
|
+
|
|
10920
|
+
/** Providing a `href` and setting `action` to `true`, it will render the ListGroup.Item as an `<a>` element (unless `as` is provided). */
|
|
11021
10921
|
href: (prop_types_default()).string,
|
|
11022
10922
|
|
|
11023
10923
|
/**
|
|
11024
10924
|
* You can use a custom element type for this component. For none `action` items, items render as `li`.
|
|
11025
|
-
* For actions the default is an
|
|
10925
|
+
* For actions the default is an anchor or button element depending on whether a `href` is provided.
|
|
11026
10926
|
*
|
|
11027
10927
|
* @default {'div' | 'a' | 'button'}
|
|
11028
10928
|
*/
|
|
@@ -11062,6 +10962,7 @@ const ListGroupItem = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_
|
|
|
11062
10962
|
|
|
11063
10963
|
|
|
11064
10964
|
const Component = as || (action ? props.href ? 'a' : 'button' : 'div');
|
|
10965
|
+
false ? 0 : void 0;
|
|
11065
10966
|
return /*#__PURE__*/(0,jsx_dev_runtime.jsxDEV)(Component, {
|
|
11066
10967
|
ref: ref,
|
|
11067
10968
|
...props,
|
|
@@ -11070,7 +10971,7 @@ const ListGroupItem = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_
|
|
|
11070
10971
|
className: classnames_default()(className, bsPrefix, meta.isActive && 'active', disabled && 'disabled', variant && `${bsPrefix}-${variant}`, action && `${bsPrefix}-action`)
|
|
11071
10972
|
}, void 0, false, {
|
|
11072
10973
|
fileName: ListGroupItem_jsxFileName,
|
|
11073
|
-
lineNumber:
|
|
10974
|
+
lineNumber: 113,
|
|
11074
10975
|
columnNumber: 9
|
|
11075
10976
|
}, undefined);
|
|
11076
10977
|
});
|
|
@@ -11177,36 +11078,6 @@ function scrollbarSize(recalc) {
|
|
|
11177
11078
|
|
|
11178
11079
|
return size;
|
|
11179
11080
|
}
|
|
11180
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/hooks/esm/useCallbackRef.js
|
|
11181
|
-
|
|
11182
|
-
/**
|
|
11183
|
-
* A convenience hook around `useState` designed to be paired with
|
|
11184
|
-
* the component [callback ref](https://reactjs.org/docs/refs-and-the-dom.html#callback-refs) api.
|
|
11185
|
-
* Callback refs are useful over `useRef()` when you need to respond to the ref being set
|
|
11186
|
-
* instead of lazily accessing it in an effect.
|
|
11187
|
-
*
|
|
11188
|
-
* ```ts
|
|
11189
|
-
* const [element, attachRef] = useCallbackRef<HTMLDivElement>()
|
|
11190
|
-
*
|
|
11191
|
-
* useEffect(() => {
|
|
11192
|
-
* if (!element) return
|
|
11193
|
-
*
|
|
11194
|
-
* const calendar = new FullCalendar.Calendar(element)
|
|
11195
|
-
*
|
|
11196
|
-
* return () => {
|
|
11197
|
-
* calendar.destroy()
|
|
11198
|
-
* }
|
|
11199
|
-
* }, [element])
|
|
11200
|
-
*
|
|
11201
|
-
* return <div ref={attachRef} />
|
|
11202
|
-
* ```
|
|
11203
|
-
*
|
|
11204
|
-
* @category refs
|
|
11205
|
-
*/
|
|
11206
|
-
|
|
11207
|
-
function useCallbackRef_useCallbackRef() {
|
|
11208
|
-
return (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useState)(null);
|
|
11209
|
-
}
|
|
11210
11081
|
;// CONCATENATED MODULE: ./node_modules/dom-helpers/esm/activeElement.js
|
|
11211
11082
|
|
|
11212
11083
|
/**
|
|
@@ -11233,38 +11104,6 @@ function activeElement(doc) {
|
|
|
11233
11104
|
return doc.body;
|
|
11234
11105
|
}
|
|
11235
11106
|
}
|
|
11236
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/ui/node_modules/@restart/hooks/esm/useUpdatedRef.js
|
|
11237
|
-
|
|
11238
|
-
/**
|
|
11239
|
-
* Returns a ref that is immediately updated with the new value
|
|
11240
|
-
*
|
|
11241
|
-
* @param value The Ref value
|
|
11242
|
-
* @category refs
|
|
11243
|
-
*/
|
|
11244
|
-
|
|
11245
|
-
function useUpdatedRef_useUpdatedRef(value) {
|
|
11246
|
-
var valueRef = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)(value);
|
|
11247
|
-
valueRef.current = value;
|
|
11248
|
-
return valueRef;
|
|
11249
|
-
}
|
|
11250
|
-
;// CONCATENATED MODULE: ./node_modules/@restart/ui/node_modules/@restart/hooks/esm/useWillUnmount.js
|
|
11251
|
-
|
|
11252
|
-
|
|
11253
|
-
/**
|
|
11254
|
-
* Attach a callback that fires when a component unmounts
|
|
11255
|
-
*
|
|
11256
|
-
* @param fn Handler to run when the component unmounts
|
|
11257
|
-
* @category effects
|
|
11258
|
-
*/
|
|
11259
|
-
|
|
11260
|
-
function useWillUnmount_useWillUnmount(fn) {
|
|
11261
|
-
var onUnmount = useUpdatedRef_useUpdatedRef(fn);
|
|
11262
|
-
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useEffect)(function () {
|
|
11263
|
-
return function () {
|
|
11264
|
-
return onUnmount.current();
|
|
11265
|
-
};
|
|
11266
|
-
}, []);
|
|
11267
|
-
}
|
|
11268
11107
|
;// CONCATENATED MODULE: ./node_modules/@restart/ui/esm/getScrollbarWidth.js
|
|
11269
11108
|
/**
|
|
11270
11109
|
* Get the width of the vertical window scrollbar if it's visible
|
|
@@ -11399,13 +11238,11 @@ class ModalManager {
|
|
|
11399
11238
|
|
|
11400
11239
|
|
|
11401
11240
|
const resolveContainerRef = (ref, document) => {
|
|
11402
|
-
var _ref;
|
|
11403
|
-
|
|
11404
11241
|
if (!canUseDOM) return null;
|
|
11405
11242
|
if (ref == null) return (document || ownerDocument()).body;
|
|
11406
11243
|
if (typeof ref === 'function') ref = ref();
|
|
11407
11244
|
if (ref && 'current' in ref) ref = ref.current;
|
|
11408
|
-
if ((
|
|
11245
|
+
if (ref && ('nodeType' in ref || ref.getBoundingClientRect)) return ref;
|
|
11409
11246
|
return null;
|
|
11410
11247
|
};
|
|
11411
11248
|
function useWaitForDOMRef(ref, onResolved) {
|
|
@@ -11547,7 +11384,7 @@ const Modal = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_react
|
|
|
11547
11384
|
setExited(false);
|
|
11548
11385
|
}
|
|
11549
11386
|
|
|
11550
|
-
const handleShow =
|
|
11387
|
+
const handleShow = useEventCallback(() => {
|
|
11551
11388
|
modal.add();
|
|
11552
11389
|
removeKeydownListenerRef.current = esm_listen(document, 'keydown', handleDocumentKeyDown);
|
|
11553
11390
|
removeFocusListenerRef.current = esm_listen(document, 'focus', // the timeout is necessary b/c this will run before the new modal is mounted
|
|
@@ -11569,7 +11406,7 @@ const Modal = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_react
|
|
|
11569
11406
|
}
|
|
11570
11407
|
}
|
|
11571
11408
|
});
|
|
11572
|
-
const handleHide =
|
|
11409
|
+
const handleHide = useEventCallback(() => {
|
|
11573
11410
|
modal.remove();
|
|
11574
11411
|
removeKeydownListenerRef.current == null ? void 0 : removeKeydownListenerRef.current();
|
|
11575
11412
|
removeFocusListenerRef.current == null ? void 0 : removeFocusListenerRef.current();
|
|
@@ -11598,11 +11435,11 @@ const Modal = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_react
|
|
|
11598
11435
|
if (!exited) return;
|
|
11599
11436
|
handleHide();
|
|
11600
11437
|
}, [exited, handleHide]);
|
|
11601
|
-
|
|
11438
|
+
useWillUnmount(() => {
|
|
11602
11439
|
handleHide();
|
|
11603
11440
|
}); // --------------------------------
|
|
11604
11441
|
|
|
11605
|
-
const handleEnforceFocus =
|
|
11442
|
+
const handleEnforceFocus = useEventCallback(() => {
|
|
11606
11443
|
if (!enforceFocus || !isMounted() || !modal.isTopModal()) {
|
|
11607
11444
|
return;
|
|
11608
11445
|
}
|
|
@@ -11613,7 +11450,7 @@ const Modal = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_react
|
|
|
11613
11450
|
modal.dialog.focus();
|
|
11614
11451
|
}
|
|
11615
11452
|
});
|
|
11616
|
-
const handleBackdropClick =
|
|
11453
|
+
const handleBackdropClick = useEventCallback(e => {
|
|
11617
11454
|
if (e.target !== e.currentTarget) {
|
|
11618
11455
|
return;
|
|
11619
11456
|
}
|
|
@@ -11624,7 +11461,7 @@ const Modal = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_react
|
|
|
11624
11461
|
onHide();
|
|
11625
11462
|
}
|
|
11626
11463
|
});
|
|
11627
|
-
const handleDocumentKeyDown =
|
|
11464
|
+
const handleDocumentKeyDown = useEventCallback(e => {
|
|
11628
11465
|
if (keyboard && e.keyCode === 27 && modal.isTopModal()) {
|
|
11629
11466
|
onEscapeKeyDown == null ? void 0 : onEscapeKeyDown(e);
|
|
11630
11467
|
|
|
@@ -12307,7 +12144,7 @@ const Modal_Modal = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_re
|
|
|
12307
12144
|
const waitingForMouseUpRef = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)(false);
|
|
12308
12145
|
const ignoreBackdropClickRef = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)(false);
|
|
12309
12146
|
const removeStaticModalAnimationRef = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)(null);
|
|
12310
|
-
const [modal, setModalRef] =
|
|
12147
|
+
const [modal, setModalRef] = useCallbackRef();
|
|
12311
12148
|
const mergedRef = esm_useMergedRefs(ref, setModalRef);
|
|
12312
12149
|
const handleHide = useEventCallback(onHide);
|
|
12313
12150
|
const isRTL = useIsRTL();
|
|
@@ -12442,7 +12279,7 @@ const Modal_Modal = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_re
|
|
|
12442
12279
|
role: "dialog",
|
|
12443
12280
|
...dialogProps,
|
|
12444
12281
|
style: baseModalStyle,
|
|
12445
|
-
className: classnames_default()(className, bsPrefix, animateStaticModal && `${bsPrefix}-static
|
|
12282
|
+
className: classnames_default()(className, bsPrefix, animateStaticModal && `${bsPrefix}-static`, !animation && 'show'),
|
|
12446
12283
|
onClick: backdrop ? handleClick : undefined,
|
|
12447
12284
|
onMouseUp: handleMouseUp,
|
|
12448
12285
|
"aria-label": ariaLabel,
|
|
@@ -12455,7 +12292,7 @@ const Modal_Modal = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_re
|
|
|
12455
12292
|
children: children
|
|
12456
12293
|
}, void 0, false, {
|
|
12457
12294
|
fileName: Modal_jsxFileName,
|
|
12458
|
-
lineNumber:
|
|
12295
|
+
lineNumber: 471,
|
|
12459
12296
|
columnNumber: 11
|
|
12460
12297
|
}, undefined)
|
|
12461
12298
|
}, void 0, false, {
|
|
@@ -12493,12 +12330,12 @@ const Modal_Modal = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_re
|
|
|
12493
12330
|
renderDialog: renderDialog
|
|
12494
12331
|
}, void 0, false, {
|
|
12495
12332
|
fileName: Modal_jsxFileName,
|
|
12496
|
-
lineNumber:
|
|
12333
|
+
lineNumber: 484,
|
|
12497
12334
|
columnNumber: 11
|
|
12498
12335
|
}, undefined)
|
|
12499
12336
|
}, void 0, false, {
|
|
12500
12337
|
fileName: Modal_jsxFileName,
|
|
12501
|
-
lineNumber:
|
|
12338
|
+
lineNumber: 483,
|
|
12502
12339
|
columnNumber: 9
|
|
12503
12340
|
}, undefined);
|
|
12504
12341
|
});
|
|
@@ -12963,7 +12800,7 @@ function useMediaQuery(query, targetWindow) {
|
|
|
12963
12800
|
matches = _useState[0],
|
|
12964
12801
|
setMatches = _useState[1];
|
|
12965
12802
|
|
|
12966
|
-
|
|
12803
|
+
useIsomorphicEffect(function () {
|
|
12967
12804
|
var mql = getMatcher(query, targetWindow);
|
|
12968
12805
|
|
|
12969
12806
|
if (!mql) {
|
|
@@ -13106,7 +12943,8 @@ var useBreakpoint = createBreakpointHook({
|
|
|
13106
12943
|
sm: 576,
|
|
13107
12944
|
md: 768,
|
|
13108
12945
|
lg: 992,
|
|
13109
|
-
xl: 1200
|
|
12946
|
+
xl: 1200,
|
|
12947
|
+
xxl: 1400
|
|
13110
12948
|
});
|
|
13111
12949
|
/* harmony default export */ const esm_useBreakpoint = (useBreakpoint);
|
|
13112
12950
|
;// CONCATENATED MODULE: ./src/OffcanvasBody.tsx
|
|
@@ -13428,6 +13266,13 @@ const Offcanvas_propTypes = {
|
|
|
13428
13266
|
* @private
|
|
13429
13267
|
*/
|
|
13430
13268
|
container: (prop_types_default()).any,
|
|
13269
|
+
|
|
13270
|
+
/**
|
|
13271
|
+
* For internal use to render static node from NavbarOffcanvas.
|
|
13272
|
+
*
|
|
13273
|
+
* @private
|
|
13274
|
+
*/
|
|
13275
|
+
renderStaticNode: (prop_types_default()).bool,
|
|
13431
13276
|
'aria-labelledby': (prop_types_default()).string
|
|
13432
13277
|
};
|
|
13433
13278
|
const Offcanvas_defaultProps = {
|
|
@@ -13438,14 +13283,15 @@ const Offcanvas_defaultProps = {
|
|
|
13438
13283
|
autoFocus: true,
|
|
13439
13284
|
enforceFocus: true,
|
|
13440
13285
|
restoreFocus: true,
|
|
13441
|
-
placement: 'start'
|
|
13286
|
+
placement: 'start',
|
|
13287
|
+
renderStaticNode: false
|
|
13442
13288
|
};
|
|
13443
13289
|
|
|
13444
13290
|
function Offcanvas_DialogTransition(props) {
|
|
13445
13291
|
return /*#__PURE__*/(0,jsx_dev_runtime.jsxDEV)(src_OffcanvasToggling, { ...props
|
|
13446
13292
|
}, void 0, false, {
|
|
13447
13293
|
fileName: Offcanvas_jsxFileName,
|
|
13448
|
-
lineNumber:
|
|
13294
|
+
lineNumber: 203,
|
|
13449
13295
|
columnNumber: 10
|
|
13450
13296
|
}, this);
|
|
13451
13297
|
}
|
|
@@ -13454,7 +13300,7 @@ function Offcanvas_BackdropTransition(props) {
|
|
|
13454
13300
|
return /*#__PURE__*/(0,jsx_dev_runtime.jsxDEV)(src_Fade, { ...props
|
|
13455
13301
|
}, void 0, false, {
|
|
13456
13302
|
fileName: Offcanvas_jsxFileName,
|
|
13457
|
-
lineNumber:
|
|
13303
|
+
lineNumber: 207,
|
|
13458
13304
|
columnNumber: 10
|
|
13459
13305
|
}, this);
|
|
13460
13306
|
}
|
|
@@ -13488,6 +13334,7 @@ const Offcanvas = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_reac
|
|
|
13488
13334
|
onExited,
|
|
13489
13335
|
backdropClassName,
|
|
13490
13336
|
manager: propsManager,
|
|
13337
|
+
renderStaticNode,
|
|
13491
13338
|
...props
|
|
13492
13339
|
}, ref) => {
|
|
13493
13340
|
const modalManager = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)();
|
|
@@ -13539,7 +13386,7 @@ const Offcanvas = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_reac
|
|
|
13539
13386
|
className: classnames_default()(`${bsPrefix}-backdrop`, backdropClassName)
|
|
13540
13387
|
}, void 0, false, {
|
|
13541
13388
|
fileName: Offcanvas_jsxFileName,
|
|
13542
|
-
lineNumber:
|
|
13389
|
+
lineNumber: 303,
|
|
13543
13390
|
columnNumber: 11
|
|
13544
13391
|
}, undefined), [backdropClassName, bsPrefix]);
|
|
13545
13392
|
|
|
@@ -13550,12 +13397,12 @@ const Offcanvas = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_reac
|
|
|
13550
13397
|
children: children
|
|
13551
13398
|
}, void 0, false, {
|
|
13552
13399
|
fileName: Offcanvas_jsxFileName,
|
|
13553
|
-
lineNumber:
|
|
13400
|
+
lineNumber: 312,
|
|
13554
13401
|
columnNumber: 9
|
|
13555
13402
|
}, undefined);
|
|
13556
13403
|
|
|
13557
13404
|
return /*#__PURE__*/(0,jsx_dev_runtime.jsxDEV)(jsx_dev_runtime.Fragment, {
|
|
13558
|
-
children: [!showOffcanvas && renderDialog({}), /*#__PURE__*/(0,jsx_dev_runtime.jsxDEV)(src_ModalContext.Provider, {
|
|
13405
|
+
children: [!showOffcanvas && (responsive || renderStaticNode) && renderDialog({}), /*#__PURE__*/(0,jsx_dev_runtime.jsxDEV)(src_ModalContext.Provider, {
|
|
13559
13406
|
value: modalContext,
|
|
13560
13407
|
children: /*#__PURE__*/(0,jsx_dev_runtime.jsxDEV)(esm_Modal, {
|
|
13561
13408
|
show: showOffcanvas,
|
|
@@ -13583,12 +13430,12 @@ const Offcanvas = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_reac
|
|
|
13583
13430
|
renderDialog: renderDialog
|
|
13584
13431
|
}, void 0, false, {
|
|
13585
13432
|
fileName: Offcanvas_jsxFileName,
|
|
13586
|
-
lineNumber:
|
|
13433
|
+
lineNumber: 340,
|
|
13587
13434
|
columnNumber: 13
|
|
13588
13435
|
}, undefined)
|
|
13589
13436
|
}, void 0, false, {
|
|
13590
13437
|
fileName: Offcanvas_jsxFileName,
|
|
13591
|
-
lineNumber:
|
|
13438
|
+
lineNumber: 339,
|
|
13592
13439
|
columnNumber: 11
|
|
13593
13440
|
}, undefined)]
|
|
13594
13441
|
}, void 0, true);
|
|
@@ -13613,11 +13460,12 @@ const NavbarOffcanvas = /*#__PURE__*/external_root_React_commonjs2_react_commonj
|
|
|
13613
13460
|
return /*#__PURE__*/(0,jsx_dev_runtime.jsxDEV)(src_Offcanvas, {
|
|
13614
13461
|
ref: ref,
|
|
13615
13462
|
show: !!(context != null && context.expanded),
|
|
13616
|
-
...props
|
|
13463
|
+
...props,
|
|
13464
|
+
renderStaticNode: true
|
|
13617
13465
|
}, void 0, false, {
|
|
13618
13466
|
fileName: NavbarOffcanvas_jsxFileName,
|
|
13619
|
-
lineNumber:
|
|
13620
|
-
columnNumber:
|
|
13467
|
+
lineNumber: 13,
|
|
13468
|
+
columnNumber: 7
|
|
13621
13469
|
}, undefined);
|
|
13622
13470
|
});
|
|
13623
13471
|
NavbarOffcanvas.displayName = 'NavbarOffcanvas';
|
|
@@ -13730,7 +13578,7 @@ const Navbar_propTypes = {
|
|
|
13730
13578
|
collapseOnSelect: (prop_types_default()).bool,
|
|
13731
13579
|
|
|
13732
13580
|
/**
|
|
13733
|
-
* Controls the
|
|
13581
|
+
* Controls the visibility of the navbar body
|
|
13734
13582
|
*
|
|
13735
13583
|
* @controllable onToggle
|
|
13736
13584
|
*/
|
|
@@ -13965,7 +13813,7 @@ function useRootClose(ref, onRootClose, {
|
|
|
13965
13813
|
disabled,
|
|
13966
13814
|
clickTrigger
|
|
13967
13815
|
});
|
|
13968
|
-
const handleKeyUp =
|
|
13816
|
+
const handleKeyUp = useEventCallback(e => {
|
|
13969
13817
|
if (e.keyCode === escapeKeyCode) {
|
|
13970
13818
|
onClose(e);
|
|
13971
13819
|
}
|
|
@@ -14019,7 +13867,7 @@ const Overlay = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_
|
|
|
14019
13867
|
} = props;
|
|
14020
13868
|
const [rootElement, attachRef] = useCallbackRef();
|
|
14021
13869
|
const [arrowElement, attachArrowRef] = useCallbackRef();
|
|
14022
|
-
const mergedRef =
|
|
13870
|
+
const mergedRef = esm_useMergedRefs(attachRef, outerRef);
|
|
14023
13871
|
const container = useWaitForDOMRef(props.container);
|
|
14024
13872
|
const target = useWaitForDOMRef(props.target);
|
|
14025
13873
|
const [exited, setExited] = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useState)(!props.show);
|
|
@@ -14372,7 +14220,7 @@ const Overlay_Overlay = /*#__PURE__*/external_root_React_commonjs2_react_commonj
|
|
|
14372
14220
|
...outerProps
|
|
14373
14221
|
}, outerRef) => {
|
|
14374
14222
|
const popperRef = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useRef)({});
|
|
14375
|
-
const [firstRenderedState, setFirstRenderedState] =
|
|
14223
|
+
const [firstRenderedState, setFirstRenderedState] = useCallbackRef();
|
|
14376
14224
|
const [ref, modifiers] = useOverlayOffset(outerProps.offset);
|
|
14377
14225
|
const mergedRef = esm_useMergedRefs(outerRef, ref);
|
|
14378
14226
|
const actualTransition = transition === true ? src_Fade : transition || undefined;
|
|
@@ -14380,7 +14228,7 @@ const Overlay_Overlay = /*#__PURE__*/external_root_React_commonjs2_react_commonj
|
|
|
14380
14228
|
setFirstRenderedState(state);
|
|
14381
14229
|
popperConfig == null ? void 0 : popperConfig.onFirstUpdate == null ? void 0 : popperConfig.onFirstUpdate(state);
|
|
14382
14230
|
});
|
|
14383
|
-
|
|
14231
|
+
useIsomorphicEffect(() => {
|
|
14384
14232
|
if (firstRenderedState) {
|
|
14385
14233
|
popperRef.current.scheduleUpdate == null ? void 0 : popperRef.current.scheduleUpdate();
|
|
14386
14234
|
}
|
|
@@ -14685,10 +14533,13 @@ const PageItem_propTypes = {
|
|
|
14685
14533
|
/** Styles PageItem as active, and renders a `<span>` instead of an `<a>`. */
|
|
14686
14534
|
active: (prop_types_default()).bool,
|
|
14687
14535
|
|
|
14688
|
-
/** An accessible label indicating the active state
|
|
14536
|
+
/** An accessible label indicating the active state. */
|
|
14689
14537
|
activeLabel: (prop_types_default()).string,
|
|
14690
14538
|
|
|
14691
|
-
/**
|
|
14539
|
+
/** The HTML href attribute for the `PageItem`. */
|
|
14540
|
+
href: (prop_types_default()).string,
|
|
14541
|
+
|
|
14542
|
+
/** A callback function for when this component is clicked. */
|
|
14692
14543
|
onClick: (prop_types_default()).func
|
|
14693
14544
|
};
|
|
14694
14545
|
const PageItem_defaultProps = {
|
|
@@ -14715,24 +14566,23 @@ const PageItem = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react
|
|
|
14715
14566
|
}),
|
|
14716
14567
|
children: /*#__PURE__*/(0,jsx_dev_runtime.jsxDEV)(Component, {
|
|
14717
14568
|
className: "page-link",
|
|
14718
|
-
disabled: disabled,
|
|
14719
14569
|
...props,
|
|
14720
14570
|
children: [children, active && activeLabel && /*#__PURE__*/(0,jsx_dev_runtime.jsxDEV)("span", {
|
|
14721
14571
|
className: "visually-hidden",
|
|
14722
14572
|
children: activeLabel
|
|
14723
14573
|
}, void 0, false, {
|
|
14724
14574
|
fileName: PageItem_jsxFileName,
|
|
14725
|
-
lineNumber:
|
|
14575
|
+
lineNumber: 65,
|
|
14726
14576
|
columnNumber: 15
|
|
14727
14577
|
}, undefined)]
|
|
14728
14578
|
}, void 0, true, {
|
|
14729
14579
|
fileName: PageItem_jsxFileName,
|
|
14730
|
-
lineNumber:
|
|
14580
|
+
lineNumber: 62,
|
|
14731
14581
|
columnNumber: 11
|
|
14732
14582
|
}, undefined)
|
|
14733
14583
|
}, void 0, false, {
|
|
14734
14584
|
fileName: PageItem_jsxFileName,
|
|
14735
|
-
lineNumber:
|
|
14585
|
+
lineNumber: 57,
|
|
14736
14586
|
columnNumber: 9
|
|
14737
14587
|
}, undefined);
|
|
14738
14588
|
});
|
|
@@ -14752,19 +14602,19 @@ function createButton(name, defaultValue, label = name) {
|
|
|
14752
14602
|
children: children || defaultValue
|
|
14753
14603
|
}, void 0, false, {
|
|
14754
14604
|
fileName: PageItem_jsxFileName,
|
|
14755
|
-
lineNumber:
|
|
14605
|
+
lineNumber: 83,
|
|
14756
14606
|
columnNumber: 9
|
|
14757
14607
|
}, this), /*#__PURE__*/(0,jsx_dev_runtime.jsxDEV)("span", {
|
|
14758
14608
|
className: "visually-hidden",
|
|
14759
14609
|
children: label
|
|
14760
14610
|
}, void 0, false, {
|
|
14761
14611
|
fileName: PageItem_jsxFileName,
|
|
14762
|
-
lineNumber:
|
|
14612
|
+
lineNumber: 84,
|
|
14763
14613
|
columnNumber: 9
|
|
14764
14614
|
}, this)]
|
|
14765
14615
|
}, void 0, true, {
|
|
14766
14616
|
fileName: PageItem_jsxFileName,
|
|
14767
|
-
lineNumber:
|
|
14617
|
+
lineNumber: 82,
|
|
14768
14618
|
columnNumber: 7
|
|
14769
14619
|
}, this));
|
|
14770
14620
|
Button.displayName = name;
|
|
@@ -14791,7 +14641,7 @@ const Pagination_propTypes = {
|
|
|
14791
14641
|
bsPrefix: (prop_types_default()).string,
|
|
14792
14642
|
|
|
14793
14643
|
/**
|
|
14794
|
-
*
|
|
14644
|
+
* Sets the size of all PageItems.
|
|
14795
14645
|
*
|
|
14796
14646
|
* @type {('sm'|'lg')}
|
|
14797
14647
|
*/
|
|
@@ -15387,7 +15237,7 @@ const Spinner_propTypes = {
|
|
|
15387
15237
|
const Spinner = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_.forwardRef(({
|
|
15388
15238
|
bsPrefix,
|
|
15389
15239
|
variant,
|
|
15390
|
-
animation,
|
|
15240
|
+
animation = 'border',
|
|
15391
15241
|
size,
|
|
15392
15242
|
// Need to define the default "as" during prop destructuring to be compatible with styled-components github.com/react-bootstrap/react-bootstrap/issues/3595
|
|
15393
15243
|
as: Component = 'div',
|
|
@@ -15402,7 +15252,7 @@ const Spinner = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_
|
|
|
15402
15252
|
className: classnames_default()(className, bsSpinnerPrefix, size && `${bsSpinnerPrefix}-${size}`, variant && `text-${variant}`)
|
|
15403
15253
|
}, void 0, false, {
|
|
15404
15254
|
fileName: Spinner_jsxFileName,
|
|
15405
|
-
lineNumber:
|
|
15255
|
+
lineNumber: 79,
|
|
15406
15256
|
columnNumber: 9
|
|
15407
15257
|
}, undefined);
|
|
15408
15258
|
});
|