@cripty2001/utils 0.0.131 → 0.0.132
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/dist/react-whispr.js +2 -2
- package/package.json +1 -1
package/dist/react-whispr.js
CHANGED
|
@@ -166,8 +166,8 @@ function useAsync(f, data, debouce = 200) {
|
|
|
166
166
|
function useRelTime(refresh = 1000) {
|
|
167
167
|
const currTs = useCurrentTimestamp(refresh);
|
|
168
168
|
const rtf = (0, react_1.useRef)(new Intl.RelativeTimeFormat(navigator.language, { numeric: "auto" })).current;
|
|
169
|
-
const getFormat = (
|
|
170
|
-
|
|
169
|
+
const getFormat = (_seconds) => {
|
|
170
|
+
const seconds = Math.abs(_seconds);
|
|
171
171
|
if (seconds < 60)
|
|
172
172
|
return "second";
|
|
173
173
|
if (seconds < 3600)
|
package/package.json
CHANGED