From e2ff5311727c49a4f697d3ff0d335606d1af1535 Mon Sep 17 00:00:00 2001 From: ThatOneCalculator Date: Wed, 5 Jul 2023 18:28:27 -0700 Subject: [PATCH] chore: :arrow_up: up prettier, pnpm --- package.json | 2 +- .../backend/src/queue/processors/inbox.ts | 2 +- packages/client/package.json | 2 +- .../src/components/MkAbuseReportWindow.vue | 2 +- .../client/src/components/MkAnalogClock.vue | 12 ++-- .../client/src/components/MkAutocomplete.vue | 12 ++-- packages/client/src/components/MkButton.vue | 2 +- packages/client/src/components/MkCaptcha.vue | 6 +- .../src/components/MkChannelFollowButton.vue | 2 +- .../client/src/components/MkChannelList.vue | 2 +- packages/client/src/components/MkChart.vue | 58 +++++++++---------- .../client/src/components/MkChatPreview.vue | 2 +- .../client/src/components/MkCode.core.vue | 6 +- packages/client/src/components/MkCode.vue | 2 +- .../client/src/components/MkContainer.vue | 6 +- .../client/src/components/MkContextMenu.vue | 3 +- .../client/src/components/MkCropperDialog.vue | 2 +- packages/client/src/components/MkCwButton.vue | 4 +- .../src/components/MkDateSeparatedList.vue | 9 +-- packages/client/src/components/MkDialog.vue | 20 +++++-- .../client/src/components/MkDigitalClock.vue | 6 +- .../client/src/components/MkDrive.file.vue | 10 ++-- .../client/src/components/MkDrive.folder.vue | 10 ++-- .../src/components/MkDrive.navFolder.vue | 2 +- packages/client/src/components/MkDrive.vue | 26 ++++----- .../src/components/MkDriveSelectDialog.vue | 2 +- .../src/components/MkEmojiPicker.section.vue | 4 +- .../client/src/components/MkEmojiPicker.vue | 20 +++---- .../src/components/MkEmojiPickerDialog.vue | 2 +- .../src/components/MkFileListForAdmin.vue | 2 +- packages/client/src/components/MkFolder.vue | 12 ++-- .../client/src/components/MkFollowButton.vue | 6 +- .../client/src/components/MkFormDialog.vue | 2 +- packages/client/src/components/MkFormula.vue | 2 +- packages/client/src/components/MkGoogle.vue | 2 +- packages/client/src/components/MkHeatmap.vue | 2 +- .../client/src/components/MkImageViewer.vue | 2 +- .../src/components/MkImgWithBlurhash.vue | 2 +- .../src/components/MkInstanceSelectDialog.vue | 2 +- .../client/src/components/MkInstanceStats.vue | 8 +-- .../src/components/MkInstanceTicker.vue | 9 ++- packages/client/src/components/MkKeyValue.vue | 2 +- .../client/src/components/MkLaunchPad.vue | 2 +- packages/client/src/components/MkLink.vue | 6 +- packages/client/src/components/MkMarquee.vue | 6 +- packages/client/src/components/MkMedia.vue | 5 +- .../client/src/components/MkMediaBanner.vue | 2 +- .../client/src/components/MkMediaCaption.vue | 4 +- .../client/src/components/MkMediaList.vue | 4 +- packages/client/src/components/MkMenu.vue | 4 +- .../client/src/components/MkMiniChart.vue | 2 +- packages/client/src/components/MkModal.vue | 24 ++++---- .../client/src/components/MkModalWindow.vue | 2 +- packages/client/src/components/MkNote.vue | 27 +++++---- .../client/src/components/MkNoteDetailed.vue | 12 ++-- .../client/src/components/MkNoteHeader.vue | 4 +- packages/client/src/components/MkNoteSub.vue | 16 ++--- .../client/src/components/MkNotification.vue | 6 +- .../MkNotificationSettingWindow.vue | 4 +- .../src/components/MkNotificationToast.vue | 4 +- .../client/src/components/MkNotifications.vue | 2 +- packages/client/src/components/MkNumber.vue | 2 +- .../client/src/components/MkPageWindow.vue | 2 +- .../client/src/components/MkPagination.vue | 25 ++++---- packages/client/src/components/MkPoll.vue | 10 ++-- .../client/src/components/MkPollEditor.vue | 6 +- packages/client/src/components/MkPostForm.vue | 46 +++++++-------- .../src/components/MkPostFormAttaches.vue | 8 +-- .../MkPushNotificationAllowButton.vue | 8 +-- .../client/src/components/MkQuoteButton.vue | 2 +- .../components/MkReactionsViewer.reaction.vue | 4 +- .../client/src/components/MkRenoteButton.vue | 6 +- packages/client/src/components/MkRipple.vue | 2 +- packages/client/src/components/MkSample.vue | 2 +- packages/client/src/components/MkSignin.vue | 6 +- .../client/src/components/MkSigninDialog.vue | 2 +- packages/client/src/components/MkSignup.vue | 2 +- .../client/src/components/MkSignupDialog.vue | 2 +- packages/client/src/components/MkSparkle.vue | 11 ++-- .../src/components/MkStarButtonNoEmoji.vue | 2 +- packages/client/src/components/MkTab.vue | 10 ++-- packages/client/src/components/MkTagCloud.vue | 8 +-- packages/client/src/components/MkTimeline.vue | 5 +- packages/client/src/components/MkToast.vue | 4 +- .../src/components/MkTokenGenerateWindow.vue | 2 +- packages/client/src/components/MkTooltip.vue | 5 +- .../src/components/MkTutorialDialog.vue | 8 +-- .../client/src/components/MkUrlPreview.vue | 9 ++- .../client/src/components/MkUserCardMini.vue | 2 +- .../client/src/components/MkUserPreview.vue | 4 +- .../client/src/components/MkVisibility.vue | 2 +- .../src/components/MkVisibilityPicker.vue | 4 +- .../client/src/components/MkWaitingDialog.vue | 2 +- packages/client/src/components/MkWidgets.vue | 4 +- packages/client/src/components/MkWindow.vue | 6 +- packages/client/src/components/form/input.vue | 2 +- .../client/src/components/form/radios.vue | 12 ++-- packages/client/src/components/form/range.vue | 4 +- .../client/src/components/form/select.vue | 2 +- packages/client/src/components/form/split.vue | 2 +- .../client/src/components/form/suspense.vue | 2 +- packages/client/src/components/global/MkA.vue | 4 +- .../client/src/components/global/MkAd.vue | 2 +- .../client/src/components/global/MkAvatar.vue | 6 +- .../client/src/components/global/MkEmoji.vue | 8 +-- .../src/components/global/MkLoading.vue | 2 +- .../global/MkMisskeyFlavoredMarkdown.vue | 2 +- .../src/components/global/MkPageHeader.vue | 14 +++-- .../client/src/components/global/MkSpacer.vue | 2 +- .../components/global/MkStickyContainer.vue | 2 +- .../client/src/components/global/MkTime.vue | 2 +- .../client/src/components/global/MkUrl.vue | 4 +- .../src/components/global/MkUserName.vue | 2 +- .../src/components/global/RouterView.vue | 2 +- .../src/components/page/page.counter.vue | 2 +- .../client/src/components/page/page.image.vue | 2 +- .../client/src/components/page/page.note.vue | 2 +- .../client/src/components/page/page.post.vue | 2 +- .../client/src/components/page/page.text.vue | 2 +- .../src/components/page/page.textarea.vue | 2 +- packages/client/src/pages/_error_.vue | 4 +- packages/client/src/pages/about.emojis.vue | 8 +-- .../client/src/pages/about.federation.vue | 2 +- packages/client/src/pages/about.vue | 4 +- packages/client/src/pages/admin-file.vue | 2 +- packages/client/src/pages/admin/_header_.vue | 6 +- .../client/src/pages/admin/bot-protection.vue | 2 +- packages/client/src/pages/admin/database.vue | 2 +- packages/client/src/pages/admin/emojis.vue | 24 ++++---- .../client/src/pages/admin/federation.vue | 2 +- packages/client/src/pages/admin/files.vue | 2 +- packages/client/src/pages/admin/index.vue | 4 +- .../client/src/pages/admin/overview.pie.vue | 4 +- .../src/pages/admin/overview.queue-chart.vue | 8 +-- .../client/src/pages/admin/promotions.vue | 2 +- .../src/pages/admin/queue.chart.chart.vue | 4 +- .../client/src/pages/admin/queue.chart.vue | 2 +- packages/client/src/pages/admin/users.vue | 4 +- .../client/src/pages/antenna-timeline.vue | 8 +-- packages/client/src/pages/api-console.vue | 6 +- packages/client/src/pages/auth.vue | 2 +- packages/client/src/pages/channel-editor.vue | 6 +- packages/client/src/pages/channel.vue | 6 +- packages/client/src/pages/channels.vue | 2 +- packages/client/src/pages/clip.vue | 10 ++-- packages/client/src/pages/drive.vue | 2 +- packages/client/src/pages/emojis.emoji.vue | 4 +- packages/client/src/pages/explore.users.vue | 2 +- packages/client/src/pages/explore.vue | 2 +- packages/client/src/pages/follow-requests.vue | 2 +- packages/client/src/pages/gallery/edit.vue | 6 +- packages/client/src/pages/gallery/index.vue | 2 +- packages/client/src/pages/gallery/post.vue | 4 +- packages/client/src/pages/instance-info.vue | 4 +- packages/client/src/pages/messaging/index.vue | 12 ++-- .../pages/messaging/messaging-room.form.vue | 12 ++-- .../messaging/messaging-room.message.vue | 2 +- .../src/pages/messaging/messaging-room.vue | 4 +- packages/client/src/pages/mfm-cheat-sheet.vue | 40 ++++++------- packages/client/src/pages/miauth.vue | 4 +- .../client/src/pages/my-antennas/edit.vue | 2 +- .../client/src/pages/my-antennas/editor.vue | 6 +- packages/client/src/pages/my-groups/group.vue | 4 +- packages/client/src/pages/my-groups/index.vue | 2 +- packages/client/src/pages/my-lists/list.vue | 4 +- packages/client/src/pages/note.vue | 8 +-- packages/client/src/pages/notifications.vue | 6 +- .../page-editor/els/page-editor.el.button.vue | 4 +- .../page-editor/els/page-editor.el.canvas.vue | 2 +- .../els/page-editor.el.counter.vue | 2 +- .../page-editor/els/page-editor.el.if.vue | 2 +- .../page-editor/els/page-editor.el.image.vue | 2 +- .../page-editor/els/page-editor.el.note.vue | 4 +- .../els/page-editor.el.number-input.vue | 2 +- .../page-editor/els/page-editor.el.post.vue | 2 +- .../els/page-editor.el.radio-button.vue | 4 +- .../els/page-editor.el.section.vue | 2 +- .../page-editor/els/page-editor.el.switch.vue | 2 +- .../els/page-editor.el.text-input.vue | 2 +- .../page-editor/els/page-editor.el.text.vue | 2 +- .../els/page-editor.el.textarea-input.vue | 2 +- .../els/page-editor.el.textarea.vue | 2 +- .../pages/page-editor/page-editor.blocks.vue | 2 +- .../page-editor/page-editor.script-block.vue | 18 +++--- .../src/pages/page-editor/page-editor.vue | 10 ++-- packages/client/src/pages/page.vue | 4 +- packages/client/src/pages/pages.vue | 2 +- packages/client/src/pages/preview.vue | 2 +- packages/client/src/pages/reset-password.vue | 4 +- packages/client/src/pages/scratchpad.vue | 2 +- packages/client/src/pages/search.vue | 2 +- packages/client/src/pages/settings/2fa.vue | 6 +- .../client/src/pages/settings/accounts.vue | 8 +-- packages/client/src/pages/settings/api.vue | 4 +- .../src/pages/settings/custom-katex-macro.vue | 6 +- packages/client/src/pages/settings/deck.vue | 2 +- packages/client/src/pages/settings/drive.vue | 2 +- packages/client/src/pages/settings/email.vue | 14 ++--- .../client/src/pages/settings/general.vue | 46 +++++++-------- packages/client/src/pages/settings/index.vue | 2 +- .../client/src/pages/settings/integration.vue | 2 +- packages/client/src/pages/settings/navbar.vue | 4 +- .../src/pages/settings/notifications.vue | 12 ++-- .../src/pages/settings/plugin.install.vue | 10 ++-- packages/client/src/pages/settings/plugin.vue | 2 +- .../pages/settings/preferences-backups.vue | 18 +++--- .../client/src/pages/settings/privacy.vue | 6 +- .../client/src/pages/settings/profile.vue | 12 ++-- .../client/src/pages/settings/reaction.vue | 22 +++---- .../client/src/pages/settings/security.vue | 2 +- packages/client/src/pages/settings/sounds.vue | 2 +- .../pages/settings/statusbar.statusbar.vue | 8 +-- .../src/pages/settings/theme.manage.vue | 2 +- packages/client/src/pages/settings/theme.vue | 20 +++---- .../client/src/pages/settings/webhook.vue | 2 +- packages/client/src/pages/share.vue | 20 +++---- packages/client/src/pages/tag.vue | 2 +- packages/client/src/pages/theme-editor.vue | 6 +- packages/client/src/pages/timeline.vue | 10 ++-- packages/client/src/pages/user-info.vue | 6 +- .../client/src/pages/user-list-timeline.vue | 8 +-- .../client/src/pages/user/follow-list.vue | 2 +- packages/client/src/pages/user/followers.vue | 6 +- packages/client/src/pages/user/following.vue | 6 +- packages/client/src/pages/user/gallery.vue | 2 +- packages/client/src/pages/user/home.vue | 14 ++--- .../client/src/pages/user/index.activity.vue | 4 +- packages/client/src/pages/user/index.vue | 8 +-- .../client/src/pages/welcome.entrance.a.vue | 6 +- .../client/src/pages/welcome.entrance.b.vue | 8 +-- .../client/src/pages/welcome.entrance.c.vue | 6 +- packages/client/src/pages/welcome.vue | 2 +- packages/client/src/style.scss | 29 ++++++++-- packages/client/src/ui/_common_/common.vue | 6 +- .../src/ui/_common_/navbar-for-mobile.vue | 4 +- packages/client/src/ui/_common_/navbar.vue | 4 +- .../client/src/ui/_common_/statusbars.vue | 4 +- packages/client/src/ui/_common_/upload.vue | 6 +- packages/client/src/ui/deck.vue | 24 +++++--- packages/client/src/ui/deck/column.vue | 4 +- packages/client/src/ui/deck/main-column.vue | 4 +- .../src/ui/deck/notifications-column.vue | 4 +- packages/client/src/ui/universal.vue | 20 ++++--- packages/client/src/ui/universal.widgets.vue | 6 +- packages/client/src/ui/visitor/a.vue | 2 +- packages/client/src/ui/visitor/b.vue | 9 +-- packages/client/src/ui/visitor/header.vue | 4 +- packages/client/src/ui/visitor/kanban.vue | 4 +- .../client/src/widgets/activity.chart.vue | 10 ++-- packages/client/src/widgets/activity.vue | 2 +- packages/client/src/widgets/aiscript.vue | 4 +- packages/client/src/widgets/button.vue | 4 +- packages/client/src/widgets/calendar.vue | 2 +- packages/client/src/widgets/clock.vue | 12 ++-- packages/client/src/widgets/digital-clock.vue | 12 ++-- packages/client/src/widgets/federation.vue | 6 +- .../client/src/widgets/instance-cloud.vue | 4 +- packages/client/src/widgets/job-queue.vue | 2 +- packages/client/src/widgets/memo.vue | 4 +- packages/client/src/widgets/notifications.vue | 6 +- packages/client/src/widgets/online-users.vue | 2 +- packages/client/src/widgets/photos.vue | 2 +- packages/client/src/widgets/post-form.vue | 2 +- packages/client/src/widgets/rss-ticker.vue | 2 +- packages/client/src/widgets/rss.vue | 2 +- packages/client/src/widgets/server-info.vue | 9 ++- .../src/widgets/server-metric/index.vue | 2 +- .../client/src/widgets/server-metric/net.vue | 2 +- .../client/src/widgets/server-metric/pie.vue | 4 +- packages/client/src/widgets/slideshow.vue | 2 +- packages/client/src/widgets/timeline.vue | 4 +- packages/client/src/widgets/trends.vue | 2 +- packages/client/src/widgets/unix-clock.vue | 4 +- packages/client/src/widgets/user-list.vue | 2 +- pnpm-lock.yaml | 16 +++-- 275 files changed, 888 insertions(+), 781 deletions(-) diff --git a/package.json b/package.json index 3408ce50f9..db96ae1ca5 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "type": "git", "url": "https://codeberg.org/calckey/calckey.git" }, - "packageManager": "pnpm@8.6.3", + "packageManager": "pnpm@8.6.6", "private": true, "scripts": { "rebuild": "pnpm run clean && pnpm node ./scripts/build-greet.js && pnpm -r run build && pnpm run gulp", diff --git a/packages/backend/src/queue/processors/inbox.ts b/packages/backend/src/queue/processors/inbox.ts index 09a69b25cb..0e500b89ed 100644 --- a/packages/backend/src/queue/processors/inbox.ts +++ b/packages/backend/src/queue/processors/inbox.ts @@ -37,7 +37,7 @@ export default async (job: Bull.Job): Promise => { if (!signature?.keyId) { const err = `Invalid signature: ${signature}`; - job.moveToFailed({message: err}); + job.moveToFailed({ message: err }); return err; } //#endregion diff --git a/packages/client/package.json b/packages/client/package.json index 2ec569381d..e34773ffe8 100644 --- a/packages/client/package.json +++ b/packages/client/package.json @@ -57,7 +57,7 @@ "matter-js": "0.18.0", "mfm-js": "0.23.3", "photoswipe": "5.3.7", - "prettier": "2.8.8", + "prettier": "3.0.0", "prettier-plugin-vue": "1.1.6", "prismjs": "1.29.0", "punycode": "2.1.1", diff --git a/packages/client/src/components/MkAbuseReportWindow.vue b/packages/client/src/components/MkAbuseReportWindow.vue index 19b8ba5264..6fdf3b9e0b 100644 --- a/packages/client/src/components/MkAbuseReportWindow.vue +++ b/packages/client/src/components/MkAbuseReportWindow.vue @@ -67,7 +67,7 @@ function send() { userId: props.user.id, comment: comment.value, }, - undefined + undefined, ).then((res) => { os.alert({ type: "success", diff --git a/packages/client/src/components/MkAnalogClock.vue b/packages/client/src/components/MkAnalogClock.vue index 43d81f2a96..2c67d2dcda 100644 --- a/packages/client/src/components/MkAnalogClock.vue +++ b/packages/client/src/components/MkAnalogClock.vue @@ -19,7 +19,7 @@ 0, 1 - angleDiff(hAngle, angle) / Math.PI - - numbersOpacityFactor + numbersOpacityFactor, ) " /> @@ -48,7 +48,7 @@ 0, 1 - angleDiff(hAngle, angle) / Math.PI - - numbersOpacityFactor + numbersOpacityFactor, ) " > @@ -151,7 +151,7 @@ const props = withDefaults( graduations: "dots", fadeGraduations: true, sAnimation: "elastic", - } + }, ); const graduationsMajor = computed(() => { @@ -192,7 +192,7 @@ let sOneRound = false; function tick() { const now = new Date(); now.setMinutes( - now.getMinutes() + (new Date().getTimezoneOffset() + props.offset) + now.getMinutes() + (new Date().getTimezoneOffset() + props.offset), ); s = now.getSeconds(); m = now.getMinutes(); @@ -225,7 +225,7 @@ function calcColors() { const computedStyle = getComputedStyle(document.documentElement); const dark = tinycolor(computedStyle.getPropertyValue("--bg")).isDark(); const accent = tinycolor( - computedStyle.getPropertyValue("--accent") + computedStyle.getPropertyValue("--accent"), ).toHexString(); majorGraduationColor = dark ? "rgba(255, 255, 255, 0.3)" @@ -233,7 +233,7 @@ function calcColors() { //minorGraduationColor = dark ? 'rgba(255, 255, 255, 0.2)' : 'rgba(0, 0, 0, 0.2)'; sHandColor = dark ? "rgba(255, 255, 255, 0.5)" : "rgba(0, 0, 0, 0.3)"; mHandColor = tinycolor( - computedStyle.getPropertyValue("--fg") + computedStyle.getPropertyValue("--fg"), ).toHexString(); hHandColor = accent; nowColor = accent; diff --git a/packages/client/src/components/MkAutocomplete.vue b/packages/client/src/components/MkAutocomplete.vue index 37207a14f7..e1a61f11f8 100644 --- a/packages/client/src/components/MkAutocomplete.vue +++ b/packages/client/src/components/MkAutocomplete.vue @@ -268,7 +268,7 @@ function exec() { } else if (props.type === "hashtag") { if (!props.q || props.q === "") { hashtags.value = JSON.parse( - localStorage.getItem("hashtags") || "[]" + localStorage.getItem("hashtags") || "[]", ); fetching.value = false; } else { @@ -288,7 +288,7 @@ function exec() { // キャッシュ sessionStorage.setItem( cacheKey, - JSON.stringify(searchedHashtags) + JSON.stringify(searchedHashtags), ); }); } @@ -298,7 +298,7 @@ function exec() { // 最近使った絵文字をサジェスト emojis.value = defaultStore.state.recentlyUsedEmojis .map((emoji) => - emojiDb.find((dbEmoji) => dbEmoji.emoji === emoji) + emojiDb.find((dbEmoji) => dbEmoji.emoji === emoji), ) .filter((x) => x) as EmojiDef[]; return; @@ -450,7 +450,7 @@ onMounted(() => { nextTick(() => { exec(); }); - } + }, ); }); }); @@ -470,7 +470,9 @@ onBeforeUnmount(() => { max-width: 100%; margin-top: calc(1em + 8px); overflow: hidden; - transition: top 0.1s ease, left 0.1s ease; + transition: + top 0.1s ease, + left 0.1s ease; > ol { display: block; diff --git a/packages/client/src/components/MkButton.vue b/packages/client/src/components/MkButton.vue index aa0adb54bd..ab02819086 100644 --- a/packages/client/src/components/MkButton.vue +++ b/packages/client/src/components/MkButton.vue @@ -90,7 +90,7 @@ function onMousedown(evt: MouseEvent): void { target.clientWidth, target.clientHeight, circleCenterX, - circleCenterY + circleCenterY, ); window.setTimeout(() => { diff --git a/packages/client/src/components/MkCaptcha.vue b/packages/client/src/components/MkCaptcha.vue index 554d4ac3a7..71d8c29964 100644 --- a/packages/client/src/components/MkCaptcha.vue +++ b/packages/client/src/components/MkCaptcha.vue @@ -25,7 +25,7 @@ type Captcha = { | "expired-callback" | "error-callback" | "endpoint"]?: unknown; - } + }, ): string; remove(id: string): void; execute(id: string): void; @@ -78,7 +78,7 @@ const src = computed(() => { }); const captcha = computed( - () => window[variable.value] || ({} as unknown as Captcha) + () => window[variable.value] || ({} as unknown as Captcha), ); if (loaded) { @@ -91,7 +91,7 @@ if (loaded) { async: true, id: props.provider, src: src.value, - }) + }), ) ).addEventListener("load", () => (available.value = true)); } diff --git a/packages/client/src/components/MkChannelFollowButton.vue b/packages/client/src/components/MkChannelFollowButton.vue index b4cb1a87f7..77b5f5f495 100644 --- a/packages/client/src/components/MkChannelFollowButton.vue +++ b/packages/client/src/components/MkChannelFollowButton.vue @@ -34,7 +34,7 @@ const props = withDefaults( }>(), { full: false, - } + }, ); const isFollowing = ref(props.channel.isFollowing); diff --git a/packages/client/src/components/MkChannelList.vue b/packages/client/src/components/MkChannelList.vue index c284736f28..c5452cd124 100644 --- a/packages/client/src/components/MkChannelList.vue +++ b/packages/client/src/components/MkChannelList.vue @@ -35,7 +35,7 @@ const props = withDefaults( }>(), { extractor: (item) => item, - } + }, ); diff --git a/packages/client/src/components/MkChart.vue b/packages/client/src/components/MkChart.vue index 310d980b49..fab89e0b0c 100644 --- a/packages/client/src/components/MkChart.vue +++ b/packages/client/src/components/MkChart.vue @@ -91,7 +91,7 @@ Chart.register( Tooltip, SubTitle, Filler, - zoomPlugin + zoomPlugin, //gradient, ); @@ -179,11 +179,11 @@ const render = () => { // フォントカラー Chart.defaults.color = getComputedStyle( - document.documentElement + document.documentElement, ).getPropertyValue("--fg"); const maxes = chartData.series.map((x, i) => - Math.max(...x.data.map((d) => d.y)) + Math.max(...x.data.map((d) => d.y)), ); chartInstance = new Chart(chartEl.value, { @@ -471,9 +471,9 @@ const fetchNotesChart = async (type: string): Promise => { raw.local.inc, negate(raw.local.dec), raw.remote.inc, - negate(raw.remote.dec) + negate(raw.remote.dec), ) - : sum(raw[type].inc, negate(raw[type].dec)) + : sum(raw[type].inc, negate(raw[type].dec)), ), color: "#888888", }, @@ -483,7 +483,7 @@ const fetchNotesChart = async (type: string): Promise => { data: format( type === "combined" ? sum(raw.local.diffs.renote, raw.remote.diffs.renote) - : raw[type].diffs.renote + : raw[type].diffs.renote, ), color: colors.green, }, @@ -493,7 +493,7 @@ const fetchNotesChart = async (type: string): Promise => { data: format( type === "combined" ? sum(raw.local.diffs.reply, raw.remote.diffs.reply) - : raw[type].diffs.reply + : raw[type].diffs.reply, ), color: colors.yellow, }, @@ -503,7 +503,7 @@ const fetchNotesChart = async (type: string): Promise => { data: format( type === "combined" ? sum(raw.local.diffs.normal, raw.remote.diffs.normal) - : raw[type].diffs.normal + : raw[type].diffs.normal, ), color: colors.blue, }, @@ -514,9 +514,9 @@ const fetchNotesChart = async (type: string): Promise => { type === "combined" ? sum( raw.local.diffs.withFile, - raw.remote.diffs.withFile + raw.remote.diffs.withFile, ) - : raw[type].diffs.withFile + : raw[type].diffs.withFile, ), color: colors.purple, }, @@ -567,8 +567,8 @@ const fetchUsersChart = async (total: boolean): Promise => { raw.local.inc, negate(raw.local.dec), raw.remote.inc, - negate(raw.remote.dec) - ) + negate(raw.remote.dec), + ), ), }, { @@ -577,7 +577,7 @@ const fetchUsersChart = async (total: boolean): Promise => { data: format( total ? raw.local.total - : sum(raw.local.inc, negate(raw.local.dec)) + : sum(raw.local.inc, negate(raw.local.dec)), ), }, { @@ -586,7 +586,7 @@ const fetchUsersChart = async (total: boolean): Promise => { data: format( total ? raw.remote.total - : sum(raw.remote.inc, negate(raw.remote.dec)) + : sum(raw.remote.inc, negate(raw.remote.dec)), ), }, ], @@ -675,8 +675,8 @@ const fetchDriveChart = async (): Promise => { raw.local.incSize, negate(raw.local.decSize), raw.remote.incSize, - negate(raw.remote.decSize) - ) + negate(raw.remote.decSize), + ), ), }, { @@ -719,8 +719,8 @@ const fetchDriveFilesChart = async (): Promise => { raw.local.incCount, negate(raw.local.decCount), raw.remote.incCount, - negate(raw.remote.decCount) - ) + negate(raw.remote.decCount), + ), ), }, { @@ -778,7 +778,7 @@ const fetchInstanceRequestsChart = async (): Promise => { }; const fetchInstanceUsersChart = async ( - total: boolean + total: boolean, ): Promise => { const raw = await os.apiGet("charts/instance", { host: props.args.host, @@ -794,7 +794,7 @@ const fetchInstanceUsersChart = async ( data: format( total ? raw.users.total - : sum(raw.users.inc, negate(raw.users.dec)) + : sum(raw.users.inc, negate(raw.users.dec)), ), }, ], @@ -802,7 +802,7 @@ const fetchInstanceUsersChart = async ( }; const fetchInstanceNotesChart = async ( - total: boolean + total: boolean, ): Promise => { const raw = await os.apiGet("charts/instance", { host: props.args.host, @@ -818,7 +818,7 @@ const fetchInstanceNotesChart = async ( data: format( total ? raw.notes.total - : sum(raw.notes.inc, negate(raw.notes.dec)) + : sum(raw.notes.inc, negate(raw.notes.dec)), ), }, ], @@ -826,7 +826,7 @@ const fetchInstanceNotesChart = async ( }; const fetchInstanceFfChart = async ( - total: boolean + total: boolean, ): Promise => { const raw = await os.apiGet("charts/instance", { host: props.args.host, @@ -842,7 +842,7 @@ const fetchInstanceFfChart = async ( data: format( total ? raw.following.total - : sum(raw.following.inc, negate(raw.following.dec)) + : sum(raw.following.inc, negate(raw.following.dec)), ), }, { @@ -852,7 +852,7 @@ const fetchInstanceFfChart = async ( data: format( total ? raw.followers.total - : sum(raw.followers.inc, negate(raw.followers.dec)) + : sum(raw.followers.inc, negate(raw.followers.dec)), ), }, ], @@ -860,7 +860,7 @@ const fetchInstanceFfChart = async ( }; const fetchInstanceDriveUsageChart = async ( - total: boolean + total: boolean, ): Promise => { const raw = await os.apiGet("charts/instance", { host: props.args.host, @@ -877,7 +877,7 @@ const fetchInstanceDriveUsageChart = async ( data: format( total ? raw.drive.totalUsage - : sum(raw.drive.incUsage, negate(raw.drive.decUsage)) + : sum(raw.drive.incUsage, negate(raw.drive.decUsage)), ), }, ], @@ -885,7 +885,7 @@ const fetchInstanceDriveUsageChart = async ( }; const fetchInstanceDriveFilesChart = async ( - total: boolean + total: boolean, ): Promise => { const raw = await os.apiGet("charts/instance", { host: props.args.host, @@ -901,7 +901,7 @@ const fetchInstanceDriveFilesChart = async ( data: format( total ? raw.drive.totalFiles - : sum(raw.drive.incFiles, negate(raw.drive.decFiles)) + : sum(raw.drive.incFiles, negate(raw.drive.decFiles)), ), }, ], diff --git a/packages/client/src/components/MkChatPreview.vue b/packages/client/src/components/MkChatPreview.vue index c2f9d9db5b..2d7e1296d0 100644 --- a/packages/client/src/components/MkChatPreview.vue +++ b/packages/client/src/components/MkChatPreview.vue @@ -11,7 +11,7 @@ message.groupId ? `/my/messaging/group/${message.groupId}` : `/my/messaging/${getAcct( - isMe(message) ? message.recipient : message.user + isMe(message) ? message.recipient : message.user, )}` " > diff --git a/packages/client/src/components/MkCode.core.vue b/packages/client/src/components/MkCode.core.vue index c397a950c1..579c6cf1ec 100644 --- a/packages/client/src/components/MkCode.core.vue +++ b/packages/client/src/components/MkCode.core.vue @@ -18,13 +18,13 @@ const props = defineProps<{ }>(); const prismLang = computed(() => - Prism.languages[props.lang] ? props.lang : "js" + Prism.languages[props.lang] ? props.lang : "js", ); const html = computed(() => Prism.highlight( props.code, Prism.languages[prismLang.value], - prismLang.value - ) + prismLang.value, + ), ); diff --git a/packages/client/src/components/MkCode.vue b/packages/client/src/components/MkCode.vue index f012b5312e..2e3fb3f0e3 100644 --- a/packages/client/src/components/MkCode.vue +++ b/packages/client/src/components/MkCode.vue @@ -12,6 +12,6 @@ defineProps<{ }>(); const XCode = defineAsyncComponent( - () => import("@/components/MkCode.core.vue") + () => import("@/components/MkCode.core.vue"), ); diff --git a/packages/client/src/components/MkContainer.vue b/packages/client/src/components/MkContainer.vue index 4c4e91160c..468982129a 100644 --- a/packages/client/src/components/MkContainer.vue +++ b/packages/client/src/components/MkContainer.vue @@ -125,7 +125,7 @@ export default defineComponent({ }, { immediate: true, - } + }, ); this.$el.style.setProperty("--maxHeight", this.maxHeight + "px"); @@ -174,7 +174,9 @@ export default defineComponent({ .container-toggle-enter-active, .container-toggle-leave-active { overflow-y: hidden; - transition: opacity 0.5s, height 0.5s !important; + transition: + opacity 0.5s, + height 0.5s !important; } .container-toggle-enter-from { opacity: 0; diff --git a/packages/client/src/components/MkContextMenu.vue b/packages/client/src/components/MkContextMenu.vue index 3e94dd59d0..d615b63521 100644 --- a/packages/client/src/components/MkContextMenu.vue +++ b/packages/client/src/components/MkContextMenu.vue @@ -80,7 +80,8 @@ function onMousedown(evt: Event) { .fade-enter-active, .fade-leave-active { - transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), + transition: + opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), transform 0.5s cubic-bezier(0.16, 1, 0.3, 1); transform-origin: left top; } diff --git a/packages/client/src/components/MkCropperDialog.vue b/packages/client/src/components/MkCropperDialog.vue index cce948572d..b7d25bd35d 100644 --- a/packages/client/src/components/MkCropperDialog.vue +++ b/packages/client/src/components/MkCropperDialog.vue @@ -118,7 +118,7 @@ onMounted(() => { const selection = cropper.getCropperSelection()!; selection.themeColor = tinycolor( - computedStyle.getPropertyValue("--accent") + computedStyle.getPropertyValue("--accent"), ).toHexString(); selection.aspectRatio = props.aspectRatio; selection.initialAspectRatio = props.aspectRatio; diff --git a/packages/client/src/components/MkCwButton.vue b/packages/client/src/components/MkCwButton.vue index f7fcb1d012..4db39f1ac9 100644 --- a/packages/client/src/components/MkCwButton.vue +++ b/packages/client/src/components/MkCwButton.vue @@ -63,7 +63,9 @@ defineExpose({ > span { background: var(--cwBg) !important; color: var(--cwFg); - transition: background 0.2s, color 0.2s; + transition: + background 0.2s, + color 0.2s; > span { font-weight: 500; &::before { diff --git a/packages/client/src/components/MkDateSeparatedList.vue b/packages/client/src/components/MkDateSeparatedList.vue index 7ecc91808a..ebb66ea1f4 100644 --- a/packages/client/src/components/MkDateSeparatedList.vue +++ b/packages/client/src/components/MkDateSeparatedList.vue @@ -84,8 +84,8 @@ export default defineComponent({ class: "ph-caret-down ph-bold ph-lg icon", }), ]), - ] - ) + ], + ), ); return [el, separator]; @@ -119,7 +119,7 @@ export default defineComponent({ : { class: "sqadhkmv" + (props.noGap ? " noGap" : ""), }, - { default: renderChildren } + { default: renderChildren }, ); }, }); @@ -140,7 +140,8 @@ export default defineComponent({ } > .list-enter-active { - transition: transform 0.7s cubic-bezier(0.23, 1, 0.32, 1), + transition: + transform 0.7s cubic-bezier(0.23, 1, 0.32, 1), opacity 0.7s cubic-bezier(0.23, 1, 0.32, 1); } diff --git a/packages/client/src/components/MkDialog.vue b/packages/client/src/components/MkDialog.vue index f870005eff..5a106a5b2a 100644 --- a/packages/client/src/components/MkDialog.vue +++ b/packages/client/src/components/MkDialog.vue @@ -78,14 +78,24 @@ okButtonDisabled && disabledReason === 'charactersExceeded' " - v-text="i18n.t('_dialog.charactersExceeded', { current: (inputValue as string).length, max: input.maxLength ?? 'NaN' })" + v-text=" + i18n.t('_dialog.charactersExceeded', { + current: (inputValue as string).length, + max: input.maxLength ?? 'NaN', + }) + " />