diff --git a/.yarnrc b/.yarnrc new file mode 100644 index 0000000000..788570fcd5 --- /dev/null +++ b/.yarnrc @@ -0,0 +1 @@ +network-timeout 600000 diff --git a/Dockerfile b/Dockerfile index c1745fc215..067b772a42 100644 --- a/Dockerfile +++ b/Dockerfile @@ -22,7 +22,7 @@ RUN apk add --no-cache \ vips-dev \ vips -COPY package.json yarn.lock ./ +COPY package.json yarn.lock .yarnrc ./ RUN yarn install COPY . ./ RUN yarn build diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index 741a5a6191..989edcda2d 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -719,6 +719,15 @@ quitFullView: "フルビュー解除" addDescription: "説明を追加" userPagePinTip: "個々のノートのメニューから「ピン留め」を選択することで、ここにノートを表示しておくことができます。" notSpecifiedMentionWarning: "宛先に含まれていないメンションがあります" +info: "情報" +userInfo: "ユーザー情報" +unknown: "不明" +onlineStatus: "オンライン状態" +hideOnlineStatus: "オンライン状態を隠す" +hideOnlineStatusDescription: "オンライン状態を隠すと、検索などの一部機能において利便性が低下することがあります。" +online: "オンライン" +active: "アクティブ" +offline: "オフライン" _email: _follow: diff --git a/migration/1618637372000-user-last-active-date.ts b/migration/1618637372000-user-last-active-date.ts new file mode 100644 index 0000000000..a66c433a3a --- /dev/null +++ b/migration/1618637372000-user-last-active-date.ts @@ -0,0 +1,16 @@ +import {MigrationInterface, QueryRunner} from "typeorm"; + +export class userLastActiveDate1618637372000 implements MigrationInterface { + name = 'userLastActiveDate1618637372000' + + public async up(queryRunner: QueryRunner): Promise { + await queryRunner.query(`ALTER TABLE "user" ADD "lastActiveDate" TIMESTAMP WITH TIME ZONE DEFAULT NULL`); + await queryRunner.query(`CREATE INDEX "IDX_seoignmeoprigmkpodgrjmkpormg" ON "user" ("lastActiveDate") `); + } + + public async down(queryRunner: QueryRunner): Promise { + await queryRunner.query(`DROP INDEX "IDX_seoignmeoprigmkpodgrjmkpormg"`); + await queryRunner.query(`ALTER TABLE "user" DROP COLUMN "lastActiveDate"`); + } + +} diff --git a/migration/1618639857000-user-hide-online-status.ts b/migration/1618639857000-user-hide-online-status.ts new file mode 100644 index 0000000000..d5d77f9837 --- /dev/null +++ b/migration/1618639857000-user-hide-online-status.ts @@ -0,0 +1,14 @@ +import {MigrationInterface, QueryRunner} from "typeorm"; + +export class userHideOnlineStatus1618639857000 implements MigrationInterface { + name = 'userHideOnlineStatus1618639857000' + + public async up(queryRunner: QueryRunner): Promise { + await queryRunner.query(`ALTER TABLE "user" ADD "hideOnlineStatus" boolean NOT NULL DEFAULT false`); + } + + public async down(queryRunner: QueryRunner): Promise { + await queryRunner.query(`ALTER TABLE "user" DROP COLUMN "hideOnlineStatus"`); + } + +} diff --git a/package.json b/package.json index 825341d040..cd73d0e36c 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "misskey", "author": "syuilo ", - "version": "12.76.1", + "version": "12.77.0", "codename": "indigo", "repository": { "type": "git", @@ -37,7 +37,7 @@ "lodash": "^4.17.20" }, "dependencies": { - "@babel/plugin-transform-runtime": "7.13.10", + "@babel/plugin-transform-runtime": "7.13.15", "@elastic/elasticsearch": "7.11.0", "@fortawesome/fontawesome-svg-core": "1.2.35", "@fortawesome/free-brands-svg-icons": "5.15.3", @@ -49,7 +49,7 @@ "@koa/router": "9.0.1", "@sentry/browser": "5.29.2", "@sentry/tracing": "5.29.2", - "@sinonjs/fake-timers": "7.0.2", + "@sinonjs/fake-timers": "7.0.5", "@syuilo/aiscript": "0.11.1", "@types/bcryptjs": "2.4.2", "@types/bull": "3.15.0", @@ -62,7 +62,7 @@ "@types/gulp-replace": "0.0.31", "@types/is-url": "1.2.28", "@types/js-yaml": "4.0.0", - "@types/jsdom": "16.2.7", + "@types/jsdom": "16.2.10", "@types/jsonld": "1.5.5", "@types/katex": "0.11.0", "@types/koa": "2.13.1", @@ -77,10 +77,10 @@ "@types/koa__multer": "2.0.2", "@types/koa__router": "8.0.4", "@types/markdown-it": "12.0.1", - "@types/matter-js": "0.14.10", - "@types/mocha": "8.2.1", - "@types/node": "14.14.35", - "@types/node-fetch": "2.5.8", + "@types/matter-js": "0.14.11", + "@types/mocha": "8.2.2", + "@types/node": "14.14.41", + "@types/node-fetch": "2.5.10", "@types/nodemailer": "6.4.1", "@types/nprogress": "0.2.0", "@types/oauth": "0.9.1", @@ -97,7 +97,7 @@ "@types/request-stats": "3.0.0", "@types/rimraf": "3.0.0", "@types/seedrandom": "2.4.28", - "@types/sharp": "0.27.1", + "@types/sharp": "0.28.0", "@types/sinonjs__fake-timers": "6.0.2", "@types/speakeasy": "2.0.5", "@types/throttle-debounce": "2.1.0", @@ -105,39 +105,39 @@ "@types/tmp": "0.2.0", "@types/uuid": "8.3.0", "@types/web-push": "3.3.0", - "@types/webpack": "4.41.26", - "@types/webpack-stream": "3.2.11", + "@types/webpack": "5.28.0", + "@types/webpack-stream": "3.2.12", "@types/websocket": "1.0.2", - "@types/ws": "7.4.0", - "@typescript-eslint/parser": "4.18.0", - "@vue/compiler-sfc": "3.0.8", + "@types/ws": "7.4.1", + "@typescript-eslint/parser": "4.22.0", + "@vue/compiler-sfc": "3.0.11", "abort-controller": "3.0.0", "apexcharts": "3.26.0", "autobind-decorator": "2.4.0", "autosize": "4.0.2", "autwh": "0.1.0", - "aws-sdk": "2.867.0", + "aws-sdk": "2.887.0", "bcryptjs": "2.4.3", "blurhash": "1.1.3", "broadcast-channel": "3.5.3", - "bull": "3.21.1", + "bull": "3.22.0", "cafy": "15.2.1", - "cbor": "7.0.4", + "cbor": "7.0.5", "chalk": "4.1.0", "chart.js": "2.9.4", - "cli-highlight": "2.1.10", - "commander": "4.1.1", - "concurrently": "6.0.0", + "cli-highlight": "2.1.11", + "commander": "7.2.0", + "concurrently": "6.0.2", "content-disposition": "0.5.3", - "core-js": "3.9.1", + "core-js": "3.10.1", "crc-32": "1.2.0", - "css-loader": "5.1.3", - "cssnano": "4.1.10", + "css-loader": "5.2.1", + "cssnano": "5.0.1", "dateformat": "4.5.1", "diskusage": "1.1.3", "escape-regexp": "0.0.1", - "eslint": "7.22.0", - "eslint-plugin-vue": "7.7.0", + "eslint": "7.24.0", + "eslint-plugin-vue": "7.9.0", "eventemitter3": "4.0.7", "feed": "4.2.2", "fibers": "5.0.0", @@ -156,17 +156,17 @@ "http-proxy-agent": "4.0.1", "http-signature": "1.3.5", "https-proxy-agent": "5.0.0", - "idb-keyval": "5.0.4", + "idb-keyval": "5.0.5", "insert-text-at-cursor": "0.3.0", "is-root": "2.1.0", "is-svg": "4.3.1", - "js-yaml": "4.0.0", - "jsdom": "16.5.1", + "js-yaml": "4.1.0", + "jsdom": "16.5.3", "json5": "2.2.0", "json5-loader": "4.0.1", "jsonld": "4.0.1", "jsrsasign": "8.0.20", - "katex": "0.13.0", + "katex": "0.13.2", "koa": "2.13.1", "koa-bodyparser": "4.3.0", "koa-favicon": "2.1.0", @@ -178,9 +178,9 @@ "koa-views": "7.0.1", "langmap": "0.0.16", "lookup-dns-cache": "2.1.0", - "markdown-it": "12.0.4", + "markdown-it": "12.0.5", "markdown-it-anchor": "7.1.0", - "matter-js": "0.16.1", + "matter-js": "0.17.1", "mfm-js": "0.15.0", "mocha": "8.3.2", "moji": "0.5.1", @@ -192,23 +192,23 @@ "object-assign-deep": "0.4.0", "os-utils": "0.0.14", "parse5": "6.0.1", - "pg": "8.5.1", + "pg": "8.6.0", "portscanner": "2.2.0", - "postcss": "8.2.8", + "postcss": "8.2.10", "postcss-loader": "5.2.0", "prismjs": "1.23.0", - "probe-image-size": "7.0.1", + "probe-image-size": "7.1.0", "promise-limit": "2.7.0", "promise-sequential": "1.1.1", "pug": "3.0.2", "punycode": "2.1.1", - "pureimage": "0.2.7", + "pureimage": "0.3.2", "qrcode": "1.4.4", "random-seed": "0.3.0", "ratelimiter": "3.4.1", "re2": "1.15.9", "reconnecting-websocket": "4.4.0", - "redis": "3.0.2", + "redis": "3.1.1", "redis-lock": "0.1.4", "reflect-metadata": "0.1.13", "regenerator-runtime": "0.13.7", @@ -221,32 +221,32 @@ "sass": "1.32.8", "sass-loader": "11.0.1", "seedrandom": "3.0.5", - "sharp": "0.27.2", + "sharp": "0.28.1", "speakeasy": "2.0.0", "stringz": "2.1.0", "style-loader": "2.0.0", "summaly": "2.4.0", "syslog-pro": "1.0.0", - "systeminformation": "5.6.7", + "systeminformation": "5.6.12", "syuilo-password-strength": "0.0.1", "textarea-caret": "3.1.0", "three": "0.117.1", "throttle-debounce": "3.0.1", "tinycolor2": "1.4.2", "tmp": "0.2.1", - "ts-loader": "8.0.18", + "ts-loader": "8.1.0", "ts-node": "9.1.1", - "tsc-alias": "1.2.8", + "tsc-alias": "1.2.9", "tsconfig-paths": "3.9.0", "tslint": "6.1.3", "tslint-sonarts": "1.9.0", - "typeorm": "0.2.31", - "typescript": "4.2.3", + "typeorm": "0.2.32", + "typescript": "4.2.4", "ulid": "2.3.0", "uuid": "8.3.2", "v-debounce": "0.1.2", "vanilla-tilt": "1.7.0", - "vue": "3.0.8", + "vue": "3.0.11", "vue-color": "2.8.1", "vue-json-pretty": "1.7.1", "vue-loader": "16.1.2", @@ -256,9 +256,9 @@ "vue-svg-loader": "0.17.0-beta.2", "vuedraggable": "4.0.1", "web-push": "3.4.4", - "webpack": "5.27.2", - "webpack-cli": "4.5.0", - "websocket": "1.0.33", + "webpack": "5.33.2", + "webpack-cli": "4.6.0", + "websocket": "1.0.34", "ws": "7.4.4", "xev": "2.0.1" }, diff --git a/src/argv.ts b/src/argv.ts index 9c69a450db..ae6396129c 100644 --- a/src/argv.ts +++ b/src/argv.ts @@ -1,6 +1,8 @@ -import * as program from 'commander'; +import { Command } from 'commander'; import config from '@/config'; +const program = new Command(); + program .version(config.version) .option('--no-daemons', 'Disable daemon processes (for debbuging)') diff --git a/src/client/components/avatars.vue b/src/client/components/avatars.vue index cac95e6d40..da862967dd 100644 --- a/src/client/components/avatars.vue +++ b/src/client/components/avatars.vue @@ -1,7 +1,7 @@ diff --git a/src/client/components/date-separated-list.vue b/src/client/components/date-separated-list.vue index 833cdfc898..012ed42385 100644 --- a/src/client/components/date-separated-list.vue +++ b/src/client/components/date-separated-list.vue @@ -18,7 +18,12 @@ export default defineComponent({ type: Boolean, required: false, default: false - } + }, + noGap: { + type: Boolean, + required: false, + default: false + }, }, methods: { @@ -37,18 +42,16 @@ export default defineComponent({ }, render() { - const noGap = [...document.querySelectorAll('._noGap_')].some(el => el.contains(this.$parent.$el)); - if (this.items.length === 0) return; return h(this.$store.state.animation ? TransitionGroup : 'div', this.$store.state.animation ? { - class: 'sqadhkmv' + (noGap ? ' _block' : ''), + class: 'sqadhkmv' + (this.noGap ? ' noGap _block' : ''), name: 'list', tag: 'div', 'data-direction': this.direction, 'data-reversed': this.reversed ? 'true' : 'false', } : { - class: 'sqadhkmv', + class: 'sqadhkmv' + (this.noGap ? ' noGap _block' : ''), }, this.items.map((item, i) => { const el = this.$slots.default({ item: item @@ -154,17 +157,17 @@ export default defineComponent({ } } } -} -._noGap_ .sqadhkmv { - > * { - margin: 0 !important; - border: none; - border-radius: 0; - box-shadow: none; + &.noGap { + > * { + margin: 0 !important; + border: none; + border-radius: 0; + box-shadow: none; - &:not(:last-child) { - border-bottom: solid 0.5px var(--divider); + &:not(:last-child) { + border-bottom: solid 0.5px var(--divider); + } } } } diff --git a/src/client/components/drive-file-thumbnail.vue b/src/client/components/drive-file-thumbnail.vue index 91f57d1f49..aadf22ed77 100644 --- a/src/client/components/drive-file-thumbnail.vue +++ b/src/client/components/drive-file-thumbnail.vue @@ -26,7 +26,7 @@ import { faFileArchive, faFilm } from '@fortawesome/free-solid-svg-icons'; -import ImgWithBlurhash from './img-with-blurhash.vue'; +import ImgWithBlurhash from '@client/components/img-with-blurhash.vue'; import { ColdDeviceStorage } from '@client/store'; export default defineComponent({ diff --git a/src/client/components/form/base.vue b/src/client/components/form/base.vue index 84438a5b32..34deb39465 100644 --- a/src/client/components/form/base.vue +++ b/src/client/components/form/base.vue @@ -24,9 +24,12 @@ export default defineComponent({ --formXPadding: 32px; --formYPadding: 32px; + font-size: 95%; line-height: 1.3em; background: var(--bg); padding: var(--formYPadding) var(--formXPadding); + max-width: 750px; + margin: 0 auto; &:not(.wide).max-width_400px { --formXPadding: 0px; @@ -40,16 +43,16 @@ export default defineComponent({ } ._form_group { - > * { - &:not(:first-child) { + > *:not(._formNoConcat) { + &:not(:last-child):not(._formNoConcatPrev) { &._formPanel, ._formPanel { - border-top: none; + border-bottom: solid 0.5px var(--divider); } } - &:not(:last-child) { + &:not(:first-child):not(._formNoConcatNext) { &._formPanel, ._formPanel { - border-bottom: solid 0.5px var(--divider); + border-top: none; } } } diff --git a/src/client/components/form/group.vue b/src/client/components/form/group.vue index d07852155a..34ccaeff07 100644 --- a/src/client/components/form/group.vue +++ b/src/client/components/form/group.vue @@ -1,7 +1,7 @@ diff --git a/src/client/components/form/object-view.vue b/src/client/components/form/object-view.vue new file mode 100644 index 0000000000..cbd4186e56 --- /dev/null +++ b/src/client/components/form/object-view.vue @@ -0,0 +1,102 @@ + + + + + diff --git a/src/client/components/form/suspense.vue b/src/client/components/form/suspense.vue new file mode 100644 index 0000000000..6a8282733f --- /dev/null +++ b/src/client/components/form/suspense.vue @@ -0,0 +1,92 @@ + + + + + diff --git a/src/client/components/global/avatar.vue b/src/client/components/global/avatar.vue index 83675a155c..64fb2116b6 100644 --- a/src/client/components/global/avatar.vue +++ b/src/client/components/global/avatar.vue @@ -1,9 +1,11 @@ @@ -12,8 +14,12 @@ import { defineComponent } from 'vue'; import { getStaticImageUrl } from '@client/scripts/get-static-image-url'; import { extractAvgColorFromBlurhash } from '@client/scripts/extract-avg-color-from-blurhash'; import { acct, userPage } from '@client/filters/user'; +import MkUserOnlineIndicator from '@client/components/user-online-indicator.vue'; export default defineComponent({ + components: { + MkUserOnlineIndicator + }, props: { user: { type: Object, @@ -30,6 +36,10 @@ export default defineComponent({ disablePreview: { required: false, default: false + }, + showIndicator: { + required: false, + default: false } }, emits: ['click'], @@ -93,7 +103,7 @@ export default defineComponent({ } } - .inner { + > .inner { position: absolute; bottom: 0; left: 0; @@ -106,5 +116,14 @@ export default defineComponent({ width: 100%; height: 100%; } + + > .indicator { + position: absolute; + z-index: 1; + bottom: 0; + left: 0; + width: 20%; + height: 20%; + } } diff --git a/src/client/components/global/loading.vue b/src/client/components/global/loading.vue index 5d0c10c086..9b810f0a16 100644 --- a/src/client/components/global/loading.vue +++ b/src/client/components/global/loading.vue @@ -1,12 +1,11 @@ + + diff --git a/src/client/components/notifications.vue b/src/client/components/notifications.vue index 0891108d8b..1b789093ef 100644 --- a/src/client/components/notifications.vue +++ b/src/client/components/notifications.vue @@ -1,19 +1,23 @@ diff --git a/src/client/components/timeline.vue b/src/client/components/timeline.vue index faa3984638..753eba2ba1 100644 --- a/src/client/components/timeline.vue +++ b/src/client/components/timeline.vue @@ -1,5 +1,5 @@ + + diff --git a/src/client/components/user-preview.vue b/src/client/components/user-preview.vue index b2b3358374..2ec81a5220 100644 --- a/src/client/components/user-preview.vue +++ b/src/client/components/user-preview.vue @@ -3,7 +3,7 @@
- +

diff --git a/src/client/components/user-select-dialog.vue b/src/client/components/user-select-dialog.vue index 05a43402a8..a243e182e8 100644 --- a/src/client/components/user-select-dialog.vue +++ b/src/client/components/user-select-dialog.vue @@ -17,7 +17,7 @@
- +
@@ -31,7 +31,7 @@
- +
diff --git a/src/client/components/users-dialog.vue b/src/client/components/users-dialog.vue index 381aa60911..ebf867f702 100644 --- a/src/client/components/users-dialog.vue +++ b/src/client/components/users-dialog.vue @@ -7,7 +7,7 @@
- +
diff --git a/src/client/pages/channel.vue b/src/client/pages/channel.vue index 0d0184a517..f98bb41a38 100644 --- a/src/client/pages/channel.vue +++ b/src/client/pages/channel.vue @@ -22,7 +22,7 @@ - +
diff --git a/src/client/pages/clip.vue b/src/client/pages/clip.vue index 493a34e7f0..ca3e051d51 100644 --- a/src/client/pages/clip.vue +++ b/src/client/pages/clip.vue @@ -5,7 +5,7 @@
- +
diff --git a/src/client/pages/explore.vue b/src/client/pages/explore.vue index 7e0acaddf7..dc0803237b 100644 --- a/src/client/pages/explore.vue +++ b/src/client/pages/explore.vue @@ -36,7 +36,7 @@
{{ $ts.exploreFediverse }}
- +
diff --git a/src/client/pages/follow-requests.vue b/src/client/pages/follow-requests.vue index 309c5b4fdf..31c00d63cd 100644 --- a/src/client/pages/follow-requests.vue +++ b/src/client/pages/follow-requests.vue @@ -9,7 +9,7 @@