@ainias42/react-bootstrap-mobile 0.2.7 → 0.2.9
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/bootstrapReactMobile.ts +1 -0
- package/dist/bootstrapReactMobile.d.ts +1 -0
- package/dist/bootstrapReactMobile.js +32 -7
- package/dist/bootstrapReactMobile.js.map +1 -1
- package/dist/src/Components/Clickable/Clickable.d.ts +1 -0
- package/dist/src/Components/Hooks/useRerender.d.ts +1 -0
- package/package.json +1 -1
- package/src/Components/Clickable/Clickable.tsx +4 -1
- package/src/Components/Hooks/useRerender.ts +21 -0
package/bootstrapReactMobile.ts
CHANGED
|
@@ -57,6 +57,7 @@ export * from './src/Components/Hooks/useListener';
|
|
|
57
57
|
export * from './src/Components/Hooks/useMousePosition';
|
|
58
58
|
export * from './src/Components/Hooks/useOnMount';
|
|
59
59
|
export * from './src/Components/Hooks/useOnce';
|
|
60
|
+
export * from './src/Components/Hooks/useRerender';
|
|
60
61
|
export * from './src/Components/Hooks/useWindowDimensions';
|
|
61
62
|
export * from './src/Components/Icon/DoubleIcon';
|
|
62
63
|
export * from './src/Components/Icon/Icon';
|
|
@@ -57,6 +57,7 @@ export * from './src/Components/Hooks/useListener';
|
|
|
57
57
|
export * from './src/Components/Hooks/useMousePosition';
|
|
58
58
|
export * from './src/Components/Hooks/useOnMount';
|
|
59
59
|
export * from './src/Components/Hooks/useOnce';
|
|
60
|
+
export * from './src/Components/Hooks/useRerender';
|
|
60
61
|
export * from './src/Components/Hooks/useWindowDimensions';
|
|
61
62
|
export * from './src/Components/Icon/DoubleIcon';
|
|
62
63
|
export * from './src/Components/Icon/Icon';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
*
|
|
3
|
-
* @ainias42/react-bootstrap-mobile v0.2.
|
|
3
|
+
* @ainias42/react-bootstrap-mobile v0.2.8
|
|
4
4
|
* git+https://github.com/Ainias/Bootstrap-React-Mobile.git
|
|
5
5
|
* Copyright (c) Silas Günther and project contributors.
|
|
6
6
|
* This source code is licensed under the MIT license found in the
|
|
@@ -4803,7 +4803,7 @@ module.exports = baseForOwn;
|
|
|
4803
4803
|
/***/ 7422:
|
|
4804
4804
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
4805
4805
|
|
|
4806
|
-
var castPath = __webpack_require__(
|
|
4806
|
+
var castPath = __webpack_require__(1769),
|
|
4807
4807
|
toKey = __webpack_require__(7797);
|
|
4808
4808
|
|
|
4809
4809
|
/**
|
|
@@ -5693,7 +5693,7 @@ module.exports = castFunction;
|
|
|
5693
5693
|
|
|
5694
5694
|
/***/ }),
|
|
5695
5695
|
|
|
5696
|
-
/***/
|
|
5696
|
+
/***/ 1769:
|
|
5697
5697
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
5698
5698
|
|
|
5699
5699
|
var isArray = __webpack_require__(6449),
|
|
@@ -6772,7 +6772,7 @@ module.exports = getValue;
|
|
|
6772
6772
|
/***/ 9326:
|
|
6773
6773
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
6774
6774
|
|
|
6775
|
-
var castPath = __webpack_require__(
|
|
6775
|
+
var castPath = __webpack_require__(1769),
|
|
6776
6776
|
isArguments = __webpack_require__(2428),
|
|
6777
6777
|
isArray = __webpack_require__(6449),
|
|
6778
6778
|
isIndex = __webpack_require__(361),
|
|
@@ -10150,6 +10150,7 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
10150
10150
|
useOnChangeDone: () => (/* reexport */ useOnChangeDone),
|
|
10151
10151
|
useOnMount: () => (/* reexport */ useOnMount),
|
|
10152
10152
|
useOnce: () => (/* reexport */ useOnce),
|
|
10153
|
+
useRerender: () => (/* reexport */ useRerender),
|
|
10153
10154
|
useSendFormContext: () => (/* reexport */ useSendFormContext),
|
|
10154
10155
|
useSharedSelectedColor: () => (/* reexport */ useSharedSelectedColor),
|
|
10155
10156
|
useSpoilerGroup: () => (/* reexport */ useSpoilerGroup),
|
|
@@ -10354,9 +10355,10 @@ function Clickable(_a, ref) {
|
|
|
10354
10355
|
stopPropagation = true,
|
|
10355
10356
|
useReactOnMouseLeave = false,
|
|
10356
10357
|
tabIndex,
|
|
10357
|
-
draggable
|
|
10358
|
+
draggable,
|
|
10359
|
+
title
|
|
10358
10360
|
} = _a,
|
|
10359
|
-
clickData = Clickable_rest(_a, ["className", "children", "style", "href", "target", "id", "interactable", "preventDefault", "stopPropagation", "useReactOnMouseLeave", "tabIndex", "draggable"]);
|
|
10361
|
+
clickData = Clickable_rest(_a, ["className", "children", "style", "href", "target", "id", "interactable", "preventDefault", "stopPropagation", "useReactOnMouseLeave", "tabIndex", "draggable", "title"]);
|
|
10360
10362
|
// States
|
|
10361
10363
|
// Refs
|
|
10362
10364
|
const clickableRef = (0,external_react_.useRef)(null);
|
|
@@ -10526,7 +10528,8 @@ function Clickable(_a, ref) {
|
|
|
10526
10528
|
onDoubleClick: realOnDoubleClick,
|
|
10527
10529
|
tabIndex: interactable ? 0 : tabIndex,
|
|
10528
10530
|
draggable,
|
|
10529
|
-
onDragStart: realOnDragStartListener
|
|
10531
|
+
onDragStart: realOnDragStartListener,
|
|
10532
|
+
title
|
|
10530
10533
|
};
|
|
10531
10534
|
if (typeof href === 'string') {
|
|
10532
10535
|
return /*#__PURE__*/external_react_.createElement("a", _extends({}, props, {
|
|
@@ -24910,6 +24913,26 @@ function useOnce(cb, condition) {
|
|
|
24910
24913
|
}
|
|
24911
24914
|
});
|
|
24912
24915
|
}
|
|
24916
|
+
;// CONCATENATED MODULE: ./src/Components/Hooks/useRerender.ts
|
|
24917
|
+
|
|
24918
|
+
function useRerender(defaultDelay = 0) {
|
|
24919
|
+
const timeoutRef = (0,external_react_.useRef)();
|
|
24920
|
+
const [renderCounter, updateRenderCounter] = (0,external_react_.useState)(0);
|
|
24921
|
+
const update = (0,external_react_.useCallback)((delay = defaultDelay) => {
|
|
24922
|
+
if (delay === 0) {
|
|
24923
|
+
clearTimeout(timeoutRef.current);
|
|
24924
|
+
timeoutRef.current = undefined;
|
|
24925
|
+
updateRenderCounter(old => old + 1);
|
|
24926
|
+
} else if (!timeoutRef.current) {
|
|
24927
|
+
timeoutRef.current = setTimeout(() => {
|
|
24928
|
+
clearTimeout(timeoutRef.current);
|
|
24929
|
+
timeoutRef.current = undefined;
|
|
24930
|
+
updateRenderCounter(old => old + 1);
|
|
24931
|
+
}, delay);
|
|
24932
|
+
}
|
|
24933
|
+
}, []);
|
|
24934
|
+
return [update, renderCounter];
|
|
24935
|
+
}
|
|
24913
24936
|
;// CONCATENATED MODULE: ./src/Components/Hooks/useWindowDimensions.ts
|
|
24914
24937
|
|
|
24915
24938
|
|
|
@@ -29279,6 +29302,7 @@ function nonEmptyString(str, other = Characters.NBSP) {
|
|
|
29279
29302
|
|
|
29280
29303
|
|
|
29281
29304
|
|
|
29305
|
+
|
|
29282
29306
|
|
|
29283
29307
|
|
|
29284
29308
|
})();
|
|
@@ -29400,6 +29424,7 @@ exports.useMousePosition = __webpack_exports__.useMousePosition;
|
|
|
29400
29424
|
exports.useOnChangeDone = __webpack_exports__.useOnChangeDone;
|
|
29401
29425
|
exports.useOnMount = __webpack_exports__.useOnMount;
|
|
29402
29426
|
exports.useOnce = __webpack_exports__.useOnce;
|
|
29427
|
+
exports.useRerender = __webpack_exports__.useRerender;
|
|
29403
29428
|
exports.useSendFormContext = __webpack_exports__.useSendFormContext;
|
|
29404
29429
|
exports.useSharedSelectedColor = __webpack_exports__.useSharedSelectedColor;
|
|
29405
29430
|
exports.useSpoilerGroup = __webpack_exports__.useSpoilerGroup;
|