mirror of
https://github.com/morpheus65535/bazarr.git
synced 2025-01-07 15:27:38 +08:00
no log: Remove moment.js from frontend since we don't use it anymore
This commit is contained in:
parent
26dc35556e
commit
677cf75deb
3 changed files with 0 additions and 32 deletions
14
frontend/package-lock.json
generated
14
frontend/package-lock.json
generated
|
@ -32,7 +32,6 @@
|
|||
"axios": "^0.21.0",
|
||||
"bootstrap": "^4.0.0",
|
||||
"lodash": "^4.0.0",
|
||||
"moment": "^2.29.1",
|
||||
"rc-slider": "^9.7.1",
|
||||
"react": "^16.0.0",
|
||||
"react-bootstrap": "^1.0.0",
|
||||
|
@ -12761,14 +12760,6 @@
|
|||
"mkdirp": "bin/cmd.js"
|
||||
}
|
||||
},
|
||||
"node_modules/moment": {
|
||||
"version": "2.29.1",
|
||||
"resolved": "https://registry.npmjs.org/moment/-/moment-2.29.1.tgz",
|
||||
"integrity": "sha512-kHmoybcPV8Sqy59DwNDY3Jefr64lK/by/da0ViFcuA4DH0vQg5Q6Ze5VimxkfQNSC+Mls/Kx53s7TjP1RhFEDQ==",
|
||||
"engines": {
|
||||
"node": "*"
|
||||
}
|
||||
},
|
||||
"node_modules/move-concurrently": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/move-concurrently/-/move-concurrently-1.0.1.tgz",
|
||||
|
@ -32045,11 +32036,6 @@
|
|||
"minimist": "^1.2.5"
|
||||
}
|
||||
},
|
||||
"moment": {
|
||||
"version": "2.29.1",
|
||||
"resolved": "https://registry.npmjs.org/moment/-/moment-2.29.1.tgz",
|
||||
"integrity": "sha512-kHmoybcPV8Sqy59DwNDY3Jefr64lK/by/da0ViFcuA4DH0vQg5Q6Ze5VimxkfQNSC+Mls/Kx53s7TjP1RhFEDQ=="
|
||||
},
|
||||
"move-concurrently": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/move-concurrently/-/move-concurrently-1.0.1.tgz",
|
||||
|
|
|
@ -37,7 +37,6 @@
|
|||
"axios": "^0.21.0",
|
||||
"bootstrap": "^4.0.0",
|
||||
"lodash": "^4.0.0",
|
||||
"moment": "^2.29.1",
|
||||
"rc-slider": "^9.7.1",
|
||||
"react": "^16.0.0",
|
||||
"react-bootstrap": "^1.0.0",
|
||||
|
|
|
@ -11,7 +11,6 @@ import {
|
|||
FontAwesomeIconProps,
|
||||
} from "@fortawesome/react-fontawesome";
|
||||
import { isNull, isUndefined } from "lodash";
|
||||
import moment from "moment";
|
||||
import React, { FunctionComponent, useMemo } from "react";
|
||||
import {
|
||||
OverlayTrigger,
|
||||
|
@ -98,22 +97,6 @@ export const LoadingIndicator: FunctionComponent<{
|
|||
);
|
||||
};
|
||||
|
||||
interface FormatterProps {
|
||||
format?: string;
|
||||
children: string | Date;
|
||||
}
|
||||
|
||||
export const DateFormatter: FunctionComponent<FormatterProps> = ({
|
||||
children,
|
||||
format,
|
||||
}) => {
|
||||
const result = useMemo(
|
||||
() => moment(children, format ?? "DD/MM/YYYY h:mm:ss").fromNow(),
|
||||
[children, format]
|
||||
);
|
||||
return <span>{result}</span>;
|
||||
};
|
||||
|
||||
interface LanguageTextProps {
|
||||
text: Language;
|
||||
className?: string;
|
||||
|
|
Loading…
Reference in a new issue