forked from FoundKeyGang/FoundKey
chore: remove s-age dependency
This isn't being used anymore since
4e41fa8767
.
In any case, age calculation really doesn't need to involve a 3rd party
library.
Ref: FoundKeyGang/FoundKey#90
This commit is contained in:
parent
10caf861e8
commit
41414b4576
5 changed files with 4 additions and 26 deletions
|
@ -98,7 +98,6 @@
|
||||||
"require-all": "3.0.0",
|
"require-all": "3.0.0",
|
||||||
"rndstr": "1.0.0",
|
"rndstr": "1.0.0",
|
||||||
"rss-parser": "3.12.0",
|
"rss-parser": "3.12.0",
|
||||||
"s-age": "1.1.2",
|
|
||||||
"sanitize-html": "2.7.0",
|
"sanitize-html": "2.7.0",
|
||||||
"semver": "7.3.7",
|
"semver": "7.3.7",
|
||||||
"sharp": "0.29.3",
|
"sharp": "0.29.3",
|
||||||
|
|
|
@ -58,7 +58,6 @@
|
||||||
"reflect-metadata": "0.1.13",
|
"reflect-metadata": "0.1.13",
|
||||||
"rndstr": "1.0.0",
|
"rndstr": "1.0.0",
|
||||||
"rollup": "2.75.7",
|
"rollup": "2.75.7",
|
||||||
"s-age": "1.1.2",
|
|
||||||
"sass": "1.53.0",
|
"sass": "1.53.0",
|
||||||
"seedrandom": "3.0.5",
|
"seedrandom": "3.0.5",
|
||||||
"strict-event-emitter-types": "2.0.0",
|
"strict-event-emitter-types": "2.0.0",
|
||||||
|
|
|
@ -108,21 +108,17 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { defineAsyncComponent, computed, inject, onMounted, onUnmounted, watch } from 'vue';
|
import { defineAsyncComponent, onMounted, onUnmounted } from 'vue';
|
||||||
import calcAge from 's-age';
|
|
||||||
import * as misskey from 'foundkey-js';
|
import * as misskey from 'foundkey-js';
|
||||||
import XUserTimeline from './index.timeline.vue';
|
import XUserTimeline from './index.timeline.vue';
|
||||||
import XNote from '@/components/note.vue';
|
import XNote from '@/components/note.vue';
|
||||||
import MkFollowButton from '@/components/follow-button.vue';
|
import MkFollowButton from '@/components/follow-button.vue';
|
||||||
import MkContainer from '@/components/ui/container.vue';
|
|
||||||
import MkFolder from '@/components/ui/folder.vue';
|
|
||||||
import MkRemoteCaution from '@/components/remote-caution.vue';
|
import MkRemoteCaution from '@/components/remote-caution.vue';
|
||||||
import MkTab from '@/components/tab.vue';
|
|
||||||
import MkInfo from '@/components/ui/info.vue';
|
import MkInfo from '@/components/ui/info.vue';
|
||||||
import { getScrollPosition } from '@/scripts/scroll';
|
import { getScrollPosition } from '@/scripts/scroll';
|
||||||
import { getUserMenu } from '@/scripts/get-user-menu';
|
import { getUserMenu } from '@/scripts/get-user-menu';
|
||||||
import number from '@/filters/number';
|
import number from '@/filters/number';
|
||||||
import { userPage, acct as getAcct } from '@/filters/user';
|
import { userPage } from '@/filters/user';
|
||||||
import * as os from '@/os';
|
import * as os from '@/os';
|
||||||
import { useRouter } from '@/router';
|
import { useRouter } from '@/router';
|
||||||
import { i18n } from '@/i18n';
|
import { i18n } from '@/i18n';
|
||||||
|
@ -150,10 +146,6 @@ const style = $computed(() => {
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
const age = $computed(() => {
|
|
||||||
return calcAge(props.user.birthday);
|
|
||||||
});
|
|
||||||
|
|
||||||
function menu(ev) {
|
function menu(ev) {
|
||||||
os.popupMenu(getUserMenu(props.user), ev.currentTarget ?? ev.target);
|
os.popupMenu(getUserMenu(props.user), ev.currentTarget ?? ev.target);
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,14 +18,11 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { defineAsyncComponent, computed, inject, onMounted, onUnmounted, watch } from 'vue';
|
import { defineAsyncComponent, computed, watch } from 'vue';
|
||||||
import calcAge from 's-age';
|
|
||||||
import * as Acct from 'foundkey-js/built/acct';
|
import * as Acct from 'foundkey-js/built/acct';
|
||||||
import * as misskey from 'foundkey-js';
|
import * as misskey from 'foundkey-js';
|
||||||
import { getScrollPosition } from '@/scripts/scroll';
|
|
||||||
import { getUserMenu } from '@/scripts/get-user-menu';
|
import { getUserMenu } from '@/scripts/get-user-menu';
|
||||||
import number from '@/filters/number';
|
import { acct as getAcct } from '@/filters/user';
|
||||||
import { userPage, acct as getAcct } from '@/filters/user';
|
|
||||||
import * as os from '@/os';
|
import * as os from '@/os';
|
||||||
import { useRouter } from '@/router';
|
import { useRouter } from '@/router';
|
||||||
import { definePageMetadata } from '@/scripts/page-metadata';
|
import { definePageMetadata } from '@/scripts/page-metadata';
|
||||||
|
|
|
@ -3928,7 +3928,6 @@ __metadata:
|
||||||
require-all: 3.0.0
|
require-all: 3.0.0
|
||||||
rndstr: 1.0.0
|
rndstr: 1.0.0
|
||||||
rss-parser: 3.12.0
|
rss-parser: 3.12.0
|
||||||
s-age: 1.1.2
|
|
||||||
sanitize-html: 2.7.0
|
sanitize-html: 2.7.0
|
||||||
semver: 7.3.7
|
semver: 7.3.7
|
||||||
sharp: 0.29.3
|
sharp: 0.29.3
|
||||||
|
@ -4974,7 +4973,6 @@ __metadata:
|
||||||
reflect-metadata: 0.1.13
|
reflect-metadata: 0.1.13
|
||||||
rndstr: 1.0.0
|
rndstr: 1.0.0
|
||||||
rollup: 2.75.7
|
rollup: 2.75.7
|
||||||
s-age: 1.1.2
|
|
||||||
sass: 1.53.0
|
sass: 1.53.0
|
||||||
seedrandom: 3.0.5
|
seedrandom: 3.0.5
|
||||||
start-server-and-test: 1.14.0
|
start-server-and-test: 1.14.0
|
||||||
|
@ -15051,13 +15049,6 @@ __metadata:
|
||||||
languageName: node
|
languageName: node
|
||||||
linkType: hard
|
linkType: hard
|
||||||
|
|
||||||
"s-age@npm:1.1.2":
|
|
||||||
version: 1.1.2
|
|
||||||
resolution: "s-age@npm:1.1.2"
|
|
||||||
checksum: cc073977a1ba2c0b78551bbf29f356f1b11b6e47a1786196f2a2990a46627aef424d41fdabbb65974d3bbec168c16e2be4da4f66f6c3b9fad859a14aa162bc7a
|
|
||||||
languageName: node
|
|
||||||
linkType: hard
|
|
||||||
|
|
||||||
"safari-14-idb-fix@npm:^3.0.0":
|
"safari-14-idb-fix@npm:^3.0.0":
|
||||||
version: 3.0.0
|
version: 3.0.0
|
||||||
resolution: "safari-14-idb-fix@npm:3.0.0"
|
resolution: "safari-14-idb-fix@npm:3.0.0"
|
||||||
|
|
Loading…
Reference in a new issue