Use native date formatting from Keycloak
This commit is contained in:
parent
0a562763e6
commit
f2bc66c3ea
|
@ -45,7 +45,6 @@
|
|||
"webpack-cli": "^4.9.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"moment": "^2.29.4",
|
||||
"rfc4648": "^1.5.2",
|
||||
"vue": "^3.2.26",
|
||||
"vue-i18n": "9"
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
<div class="w-full ml-5 flex flex-col">
|
||||
<p>{{ authenticator.label }}</p>
|
||||
<p class="text-sm">
|
||||
{{ $t("webauthn.registered", {date: moment(authenticator.createdAt)}) }}
|
||||
{{ $t("webauthn.registered", { date: authenticator.createdAt }) }}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -77,7 +77,6 @@ import ErrorBox from "~/components/ErrorBox.vue";
|
|||
import type { KcContextBase } from "~/types/context";
|
||||
import { base64url } from "rfc4648";
|
||||
import { formPost } from "~/functions/utils";
|
||||
import moment from "moment";
|
||||
|
||||
export default defineComponent({
|
||||
name: "WebAuthnAuthenticate",
|
||||
|
@ -98,9 +97,6 @@ export default defineComponent({
|
|||
}
|
||||
},
|
||||
methods: {
|
||||
moment(date: string) : string {
|
||||
return moment(date).toDate().toLocaleString();
|
||||
},
|
||||
tryAnotherWay(e: Event) {
|
||||
e.preventDefault();
|
||||
formPost(this.context.url.loginAction, {
|
||||
|
|
Loading…
Reference in a new issue