Compare commits
66 Commits
2025.12.0-
...
develop
| Author | SHA1 | Date |
|---|---|---|
|
|
6d00645bc7 | |
|
|
baeed4bc80 | |
|
|
dba44daf9c | |
|
|
46e6dd99d1 | |
|
|
f48af7f73b | |
|
|
834e8b4c24 | |
|
|
7ef0c96758 | |
|
|
b10074e939 | |
|
|
260dbd150b | |
|
|
79cbbcfe0f | |
|
|
c893f85864 | |
|
|
24d4ffa2ec | |
|
|
0b931daefd | |
|
|
cc05d93194 | |
|
|
90345591bb | |
|
|
730227f353 | |
|
|
4acb37ee9d | |
|
|
7025769c69 | |
|
|
1a4ef8769f | |
|
|
055cd0c250 | |
|
|
d35ddc77d2 | |
|
|
8d871a58e3 | |
|
|
99b0b436e0 | |
|
|
e3d5b95672 | |
|
|
0d52145b2b | |
|
|
467404d5bb | |
|
|
99e25784ad | |
|
|
9e1e40d35a | |
|
|
8eb6e29d2c | |
|
|
2d198a711b | |
|
|
e0b872dc09 | |
|
|
711b86ab7d | |
|
|
e8b4dae553 | |
|
|
36d404818d | |
|
|
cb03f3f013 | |
|
|
c109bec013 | |
|
|
6fa4eb8c4f | |
|
|
5fb4caa14b | |
|
|
bc1f83664f | |
|
|
78435dc8d4 | |
|
|
d74aded35f | |
|
|
d605680524 | |
|
|
1096ce8e4a | |
|
|
8e6fffee68 | |
|
|
2cffd9f0fb | |
|
|
988f5ab69f | |
|
|
3afe7c5348 | |
|
|
73cc30f50f | |
|
|
da3b3af984 | |
|
|
3273ca7512 | |
|
|
b67bfe0763 | |
|
|
63d2870755 | |
|
|
61f9c148f0 | |
|
|
8927a9e98a | |
|
|
dc77d59f87 | |
|
|
2d0dae236f | |
|
|
a1f0ca4b8f | |
|
|
2a996287e3 | |
|
|
65dd917bfb | |
|
|
b0bffd3842 | |
|
|
4ee6f90ab2 | |
|
|
50379e52db | |
|
|
6bb29ab5c3 | |
|
|
fc1e2229e5 | |
|
|
daf2a57b3c | |
|
|
6716950d7f |
|
|
@ -110,10 +110,19 @@ port: 3000
|
|||
# Changes how the server interpret the origin IP of the request.
|
||||
#
|
||||
# Any format supported by Fastify is accepted.
|
||||
# Default: do not trust any proxies (i.e. trustProxy: false)
|
||||
# Default: trust all proxies (i.e. trustProxy: true)
|
||||
# See: https://fastify.dev/docs/latest/reference/server/#trustproxy
|
||||
# To improve security, we recommend that you configure your settings appropriately.
|
||||
# Incorrect configuration can cause issues such as difficulty signing in,
|
||||
# so please configure your settings carefully.
|
||||
#
|
||||
# trustProxy: false
|
||||
#trustProxy:
|
||||
# - '10.0.0.0/8'
|
||||
# - '172.16.0.0/12'
|
||||
# - '192.168.0.0/16'
|
||||
# - '127.0.0.1/32'
|
||||
# - '::1/128'
|
||||
# - 'fc00::/7'
|
||||
|
||||
# ┌──────────────────────────┐
|
||||
#───┘ PostgreSQL configuration └────────────────────────────────
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
"workspaceFolder": "/workspace",
|
||||
"features": {
|
||||
"ghcr.io/devcontainers/features/node:1": {
|
||||
"version": "24.10.0"
|
||||
"version": "22.15.0"
|
||||
},
|
||||
"ghcr.io/devcontainers-extra/features/pnpm:2": {
|
||||
"version": "10.10.0"
|
||||
|
|
|
|||
|
|
@ -16,13 +16,13 @@ jobs:
|
|||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4.3.0
|
||||
uses: actions/checkout@v6.0.1
|
||||
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
|
|||
|
|
@ -12,9 +12,9 @@ jobs:
|
|||
|
||||
steps:
|
||||
- name: Checkout head
|
||||
uses: actions/checkout@v4.3.0
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ jobs:
|
|||
if: ${{ github.event.pull_request.mergeable == null || github.event.pull_request.mergeable == true }}
|
||||
steps:
|
||||
- name: checkout
|
||||
uses: actions/checkout@v4.3.0
|
||||
uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
submodules: true
|
||||
persist-credentials: false
|
||||
|
|
@ -29,7 +29,7 @@ jobs:
|
|||
|
||||
- name: setup node
|
||||
id: setup-node
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: pnpm
|
||||
|
|
@ -53,7 +53,7 @@ jobs:
|
|||
|
||||
# packages/misskey-js/generator/built/autogen
|
||||
- name: Upload Generated
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: generated-misskey-js
|
||||
path: packages/misskey-js/generator/built/autogen
|
||||
|
|
@ -66,14 +66,14 @@ jobs:
|
|||
if: ${{ github.event.pull_request.mergeable == null || github.event.pull_request.mergeable == true }}
|
||||
steps:
|
||||
- name: checkout
|
||||
uses: actions/checkout@v4.3.0
|
||||
uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
submodules: true
|
||||
persist-credentials: false
|
||||
ref: refs/pull/${{ github.event.pull_request.number }}/merge
|
||||
|
||||
- name: Upload From Merged
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: actual-misskey-js
|
||||
path: packages/misskey-js/src/autogen
|
||||
|
|
@ -86,13 +86,13 @@ jobs:
|
|||
pull-requests: write
|
||||
steps:
|
||||
- name: download generated-misskey-js
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v7
|
||||
with:
|
||||
name: generated-misskey-js
|
||||
path: misskey-js-generated
|
||||
|
||||
- name: download actual-misskey-js
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v7
|
||||
with:
|
||||
name: actual-misskey-js
|
||||
path: misskey-js-actual
|
||||
|
|
@ -113,9 +113,9 @@ jobs:
|
|||
|
||||
- name: send message
|
||||
if: steps.check-changes.outputs.changes == 'true'
|
||||
uses: thollander/actions-comment-pull-request@v2
|
||||
uses: thollander/actions-comment-pull-request@v3
|
||||
with:
|
||||
comment_tag: check-misskey-js-autogen
|
||||
comment-tag: check-misskey-js-autogen
|
||||
message: |-
|
||||
Thank you for sending us a great Pull Request! 👍
|
||||
Please regenerate misskey-js type definitions! 🙏
|
||||
|
|
@ -127,9 +127,9 @@ jobs:
|
|||
|
||||
- name: send message
|
||||
if: steps.check-changes.outputs.changes == 'false'
|
||||
uses: thollander/actions-comment-pull-request@v2
|
||||
uses: thollander/actions-comment-pull-request@v3
|
||||
with:
|
||||
comment_tag: check-misskey-js-autogen
|
||||
comment-tag: check-misskey-js-autogen
|
||||
mode: delete
|
||||
message: "Thank you!"
|
||||
create_if_not_exists: false
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4.3.0
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Check version
|
||||
run: |
|
||||
if [ "$(jq -r '.version' package.json)" != "$(jq -r '.version' packages/misskey-js/package.json)" ]; then
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4.3.0
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Check
|
||||
run: |
|
||||
counter=0
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ jobs:
|
|||
check_copyright_year:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
- run: |
|
||||
if [ "$(grep Copyright COPYING | sed -e 's/.*2014-\([0-9]*\) .*/\1/g')" -ne "$(date +%Y)" ]; then
|
||||
echo "Please change copyright year!"
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ jobs:
|
|||
wait_time: ${{ steps.get-wait-time.outputs.wait_time }}
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4.3.0
|
||||
uses: actions/checkout@v6.0.1
|
||||
|
||||
- name: Check allowed users
|
||||
id: check-allowed-users
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ jobs:
|
|||
platform=${{ matrix.platform }}
|
||||
echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4.3.0
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
- name: Log in to Docker Hub
|
||||
|
|
@ -53,7 +53,7 @@ jobs:
|
|||
digest="${{ steps.build.outputs.digest }}"
|
||||
touch "/tmp/digests/${digest#sha256:}"
|
||||
- name: Upload digest
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: digests-${{ env.PLATFORM_PAIR }}
|
||||
path: /tmp/digests/*
|
||||
|
|
@ -66,7 +66,7 @@ jobs:
|
|||
- build
|
||||
steps:
|
||||
- name: Download digests
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v7
|
||||
with:
|
||||
path: /tmp/digests
|
||||
pattern: digests-*
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ jobs:
|
|||
platform=${{ matrix.platform }}
|
||||
echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4.3.0
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
- name: Docker meta
|
||||
|
|
@ -64,7 +64,7 @@ jobs:
|
|||
digest="${{ steps.build.outputs.digest }}"
|
||||
touch "/tmp/digests/${digest#sha256:}"
|
||||
- name: Upload digest
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: digests-${{ env.PLATFORM_PAIR }}
|
||||
path: /tmp/digests/*
|
||||
|
|
@ -77,7 +77,7 @@ jobs:
|
|||
- build
|
||||
steps:
|
||||
- name: Download digests
|
||||
uses: actions/download-artifact@v4
|
||||
uses: actions/download-artifact@v7
|
||||
with:
|
||||
path: /tmp/digests
|
||||
pattern: digests-*
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ jobs:
|
|||
DOCKLE_VERSION: 0.4.15
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
|
||||
- name: Download and install dockle v${{ env.DOCKLE_VERSION }}
|
||||
run: |
|
||||
|
|
|
|||
|
|
@ -25,14 +25,14 @@ jobs:
|
|||
ref: refs/pull/${{ github.event.number }}/merge
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
ref: ${{ matrix.ref }}
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
@ -48,7 +48,7 @@ jobs:
|
|||
- name: Copy API.json
|
||||
run: cp packages/backend/built/api.json ${{ matrix.api-json-name }}
|
||||
- name: Upload Artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: api-artifact-${{ matrix.api-json-name }}
|
||||
path: ${{ matrix.api-json-name }}
|
||||
|
|
@ -61,7 +61,7 @@ jobs:
|
|||
PR_NUMBER: ${{ github.event.number }}
|
||||
run: |
|
||||
echo "$PR_NUMBER" > ./pr_number
|
||||
- uses: actions/upload-artifact@v4
|
||||
- uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: api-artifact-pr-number
|
||||
path: pr_number
|
||||
|
|
|
|||
|
|
@ -40,14 +40,14 @@ jobs:
|
|||
- 56312:6379
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
ref: ${{ matrix.ref }}
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
@ -67,7 +67,7 @@ jobs:
|
|||
# Start the server and measure memory usage
|
||||
node packages/backend/scripts/measure-memory.mjs > ${{ matrix.memory-json-name }}
|
||||
- name: Upload Artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: memory-artifact-${{ matrix.memory-json-name }}
|
||||
path: ${{ matrix.memory-json-name }}
|
||||
|
|
@ -81,7 +81,7 @@ jobs:
|
|||
PR_NUMBER: ${{ github.event.number }}
|
||||
run: |
|
||||
echo "$PR_NUMBER" > ./pr_number
|
||||
- uses: actions/upload-artifact@v4
|
||||
- uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: memory-artifact-pr-number
|
||||
path: pr_number
|
||||
|
|
|
|||
|
|
@ -11,6 +11,6 @@ jobs:
|
|||
pull-requests: write
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/labeler@v5
|
||||
- uses: actions/labeler@v6
|
||||
with:
|
||||
repo-token: "${{ secrets.GITHUB_TOKEN }}"
|
||||
|
|
|
|||
|
|
@ -36,13 +36,13 @@ jobs:
|
|||
pnpm_install:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- uses: actions/setup-node@v4.4.0
|
||||
- uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
@ -69,13 +69,13 @@ jobs:
|
|||
eslint-cache-version: v1
|
||||
eslint-cache-path: ${{ github.workspace }}/node_modules/.cache/eslint-${{ matrix.workspace }}
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- uses: actions/setup-node@v4.4.0
|
||||
- uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
@ -100,13 +100,13 @@ jobs:
|
|||
- sw
|
||||
- misskey-js
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- uses: actions/setup-node@v4.4.0
|
||||
- uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
|
|||
|
|
@ -16,13 +16,13 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
continue-on-error: true
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- uses: actions/setup-node@v4.4.0
|
||||
- uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: ".node-version"
|
||||
cache: "pnpm"
|
||||
|
|
|
|||
|
|
@ -16,13 +16,13 @@ jobs:
|
|||
id-token: write
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ jobs:
|
|||
edit:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v6
|
||||
# headが$GITHUB_REF_NAME, baseが$STABLE_BRANCHかつopenのPRを1つ取得
|
||||
- name: Get PR
|
||||
run: |
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ jobs:
|
|||
outputs:
|
||||
pr_number: ${{ steps.get_pr.outputs.pr_number }}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v6
|
||||
# headが$GITHUB_REF_NAME, baseが$STABLE_BRANCHかつopenのPRを1つ取得
|
||||
- name: Get PRs
|
||||
run: |
|
||||
|
|
|
|||
|
|
@ -16,7 +16,7 @@ jobs:
|
|||
# api-artifact
|
||||
steps:
|
||||
- name: Download artifact
|
||||
uses: actions/github-script@v7.1.0
|
||||
uses: actions/github-script@v8.0.0
|
||||
with:
|
||||
script: |
|
||||
const fs = require('fs');
|
||||
|
|
@ -60,7 +60,7 @@ jobs:
|
|||
- name: Echo full diff
|
||||
run: cat ./api-full.json.diff
|
||||
- name: Upload full diff to Artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: api-artifact
|
||||
path: |
|
||||
|
|
@ -89,16 +89,16 @@ jobs:
|
|||
fi
|
||||
|
||||
echo "$FOOTER" >> ./output.md
|
||||
- uses: thollander/actions-comment-pull-request@v2
|
||||
- uses: thollander/actions-comment-pull-request@v3
|
||||
with:
|
||||
pr_number: ${{ steps.load-pr-num.outputs.pr-number }}
|
||||
comment_tag: show_diff
|
||||
filePath: ./output.md
|
||||
pr-number: ${{ steps.load-pr-num.outputs.pr-number }}
|
||||
comment-tag: show_diff
|
||||
file-path: ./output.md
|
||||
- name: Tell error to PR
|
||||
uses: thollander/actions-comment-pull-request@v2
|
||||
uses: thollander/actions-comment-pull-request@v3
|
||||
if: failure() && steps.load-pr-num.outputs.pr-number
|
||||
with:
|
||||
pr_number: ${{ steps.load-pr-num.outputs.pr-number }}
|
||||
comment_tag: show_diff_error
|
||||
pr-number: ${{ steps.load-pr-num.outputs.pr-number }}
|
||||
comment-tag: show_diff_error
|
||||
message: |
|
||||
api.jsonの差分作成中にエラーが発生しました。詳細は[Workflowのログ](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }})を確認してください。
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ jobs:
|
|||
|
||||
steps:
|
||||
- name: Download artifact
|
||||
uses: actions/github-script@v7.1.0
|
||||
uses: actions/github-script@v8.0.0
|
||||
with:
|
||||
script: |
|
||||
const fs = require('fs');
|
||||
|
|
@ -107,16 +107,16 @@ jobs:
|
|||
fi
|
||||
|
||||
echo "$FOOTER" >> ./output.md
|
||||
- uses: thollander/actions-comment-pull-request@v2
|
||||
- uses: thollander/actions-comment-pull-request@v3
|
||||
with:
|
||||
pr_number: ${{ steps.load-pr-num.outputs.pr-number }}
|
||||
comment_tag: show_memory_diff
|
||||
filePath: ./output.md
|
||||
pr-number: ${{ steps.load-pr-num.outputs.pr-number }}
|
||||
comment-tag: show_memory_diff
|
||||
file-path: ./output.md
|
||||
- name: Tell error to PR
|
||||
uses: thollander/actions-comment-pull-request@v2
|
||||
uses: thollander/actions-comment-pull-request@v3
|
||||
if: failure() && steps.load-pr-num.outputs.pr-number
|
||||
with:
|
||||
pr_number: ${{ steps.load-pr-num.outputs.pr-number }}
|
||||
comment_tag: show_memory_diff_error
|
||||
pr-number: ${{ steps.load-pr-num.outputs.pr-number }}
|
||||
comment-tag: show_memory_diff_error
|
||||
message: |
|
||||
An error occurred while comparing backend memory usage. See [workflow logs](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}) for details.
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ jobs:
|
|||
pull-requests: write
|
||||
steps:
|
||||
- name: Reply
|
||||
uses: actions/github-script@v6
|
||||
uses: actions/github-script@v8
|
||||
with:
|
||||
script: |
|
||||
const body = `To dev team (@misskey-dev/dev):
|
||||
|
|
|
|||
|
|
@ -22,12 +22,12 @@ jobs:
|
|||
NODE_OPTIONS: "--max_old_space_size=7168"
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
if: github.event_name != 'pull_request_target'
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: true
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
if: github.event_name == 'pull_request_target'
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
|
@ -39,7 +39,7 @@ jobs:
|
|||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
@ -90,7 +90,7 @@ jobs:
|
|||
env:
|
||||
CHROMATIC_PROJECT_TOKEN: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
|
||||
- name: Notify that Chromatic detects changes
|
||||
uses: actions/github-script@v7.1.0
|
||||
uses: actions/github-script@v8.0.0
|
||||
if: github.event_name != 'pull_request_target' && steps.chromatic_push.outputs.success == 'false'
|
||||
with:
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
|
@ -102,7 +102,7 @@ jobs:
|
|||
body: 'Chromatic detects changes. Please [review the changes on Chromatic](https://www.chromatic.com/builds?appId=6428f7d7b962f0b79f97d6e4).'
|
||||
})
|
||||
- name: Upload Artifacts
|
||||
uses: actions/upload-artifact@v4
|
||||
uses: actions/upload-artifact@v6
|
||||
with:
|
||||
name: storybook
|
||||
path: packages/frontend/storybook-static
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ jobs:
|
|||
- 56312:6379
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
|
|
@ -86,7 +86,7 @@ jobs:
|
|||
fi
|
||||
done
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: ${{ matrix.node-version-file }}
|
||||
cache: 'pnpm'
|
||||
|
|
@ -129,13 +129,13 @@ jobs:
|
|||
- 56312:6379
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: ${{ matrix.node-version-file }}
|
||||
cache: 'pnpm'
|
||||
|
|
@ -173,7 +173,7 @@ jobs:
|
|||
POSTGRES_HOST_AUTH_METHOD: trust
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
|
|
@ -182,7 +182,7 @@ jobs:
|
|||
id: current-date
|
||||
run: echo "today=$(date +'%Y-%m-%d')" >> $GITHUB_OUTPUT
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: ${{ matrix.node-version-file }}
|
||||
cache: 'pnpm'
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ jobs:
|
|||
- .node-version
|
||||
- .github/min.node-version
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/checkout@v6
|
||||
with:
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
|
|
@ -68,7 +68,7 @@ jobs:
|
|||
fi
|
||||
done
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: ${{ matrix.node-version-file }}
|
||||
cache: 'pnpm'
|
||||
|
|
|
|||
|
|
@ -28,13 +28,13 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
@ -76,7 +76,7 @@ jobs:
|
|||
- 56312:6379
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
submodules: true
|
||||
# https://github.com/cypress-io/cypress-docker-images/issues/150
|
||||
|
|
@ -88,7 +88,7 @@ jobs:
|
|||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
@ -113,12 +113,12 @@ jobs:
|
|||
wait-on: 'http://localhost:61812'
|
||||
headed: true
|
||||
browser: ${{ matrix.browser }}
|
||||
- uses: actions/upload-artifact@v4
|
||||
- uses: actions/upload-artifact@v6
|
||||
if: failure()
|
||||
with:
|
||||
name: ${{ matrix.browser }}-cypress-screenshots
|
||||
path: cypress/screenshots
|
||||
- uses: actions/upload-artifact@v4
|
||||
- uses: actions/upload-artifact@v6
|
||||
if: always()
|
||||
with:
|
||||
name: ${{ matrix.browser }}-cypress-videos
|
||||
|
|
|
|||
|
|
@ -22,13 +22,13 @@ jobs:
|
|||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4.3.0
|
||||
uses: actions/checkout@v6.0.1
|
||||
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
|
||||
- name: Setup Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
|
|||
|
|
@ -16,13 +16,13 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
|
|||
|
|
@ -17,13 +17,13 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4.3.0
|
||||
- uses: actions/checkout@v6.0.1
|
||||
with:
|
||||
submodules: true
|
||||
- name: Setup pnpm
|
||||
uses: pnpm/action-setup@v4.2.0
|
||||
- name: Use Node.js
|
||||
uses: actions/setup-node@v4.4.0
|
||||
uses: actions/setup-node@v6.1.0
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
24.10.0
|
||||
22.15.0
|
||||
|
|
|
|||
37
CHANGELOG.md
37
CHANGELOG.md
|
|
@ -1,7 +1,38 @@
|
|||
## 2025.12.0
|
||||
## 2025.12.2
|
||||
|
||||
### Note
|
||||
v2025.12.0で行われた「configの`trustProxy`のデフォルト値を`false`に変更」について、正しく環境に応じた設定を行わないとサインインが困難になるといった状態を緩和するために、以前のデフォルト値に戻す暫定対応を行いました。
|
||||
|
||||
**セキュリティを向上させるためには適切な設定を行うことを推奨しますが、間違った設定値を入れると上述のような不具合の原因となりますので、慎重に行ってください。**
|
||||
|
||||
### General
|
||||
-
|
||||
- 依存関係の更新
|
||||
|
||||
### Client
|
||||
- Enhance: デッキのUI説明を追加
|
||||
- Fix: バージョン表記のないPlayが正しく動作しない問題を修正
|
||||
バージョン表記のないものは v0.x 系として実行されます。v1.x 系で動作させたい場合は必ずバージョン表記を含めてください。
|
||||
- Fix: デッキUIでメニュー位置を下にしているとプロファイル削除ボタンが表示されないのを修正
|
||||
|
||||
|
||||
## 2025.12.1
|
||||
|
||||
### Client
|
||||
- Fix: 特定の条件下でMisskeyが起動せず空白のページが表示されることがある問題を軽減
|
||||
- Fix: 初回読み込み時などに、言語設定で不整合が発生することがある問題を修正
|
||||
- Fix: 削除されたノートのリノートが正しく動作されない問題を修正
|
||||
- Fix: チャンネルオーナーが削除済みの時にチャンネルのヘッダーメニューが表示されない不具合を修正
|
||||
- Fix: ドライブで登録日以外でソートする場合は月でグループ化して表示しないように
|
||||
- Fix: `null` を返す note_view_intrruptor プラグインが動作しない問題を修正
|
||||
|
||||
### Server
|
||||
- Fix: ジョブキューでSentryが有効にならない問題を修正
|
||||
|
||||
|
||||
## 2025.12.0
|
||||
|
||||
### Note
|
||||
- configの`trustProxy`のデフォルト値を`false`に変更しました。アップデート前に現在のconfigをご確認の上、必要に応じて値を変更してください。
|
||||
|
||||
### Client
|
||||
- Fix: stacking router viewで連続して戻る操作を行うと何も表示されなくなる問題を修正
|
||||
|
|
@ -10,7 +41,7 @@
|
|||
- Enhance: メモリ使用量を削減しました
|
||||
- Enhance: ActivityPubアクティビティを送信する際のパフォーマンス向上
|
||||
- Enhance: 依存関係の更新
|
||||
|
||||
- Fix: セキュリティに関する修正
|
||||
|
||||
## 2025.11.1
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
# syntax = docker/dockerfile:1.4
|
||||
|
||||
ARG NODE_VERSION=24.10.0-bookworm
|
||||
ARG NODE_VERSION=22.15.0-bookworm
|
||||
|
||||
# build assets & compile TypeScript
|
||||
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ services:
|
|||
env_file:
|
||||
- .config/docker.env
|
||||
volumes:
|
||||
- ./db:/var/lib/postgresql/data
|
||||
- ./db:/var/lib/postgresql
|
||||
healthcheck:
|
||||
test: "pg_isready -U $$POSTGRES_USER -d $$POSTGRES_DB"
|
||||
interval: 5s
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ services:
|
|||
env_file:
|
||||
- .config/docker.env
|
||||
volumes:
|
||||
- ./db:/var/lib/postgresql/data
|
||||
- ./db:/var/lib/postgresql
|
||||
healthcheck:
|
||||
test: "pg_isready -U $$POSTGRES_USER -d $$POSTGRES_DB"
|
||||
interval: 5s
|
||||
|
|
|
|||
|
|
@ -83,6 +83,7 @@ files: "Dateien"
|
|||
download: "Herunterladen"
|
||||
driveFileDeleteConfirm: "Möchtest du die Datei „{name}“ wirklich löschen? Einige Inhalte, die diese Datei verwenden, werden auch verschwinden."
|
||||
unfollowConfirm: "Möchtest du {name} wirklich nicht mehr folgen?"
|
||||
rejectFollowRequestConfirm: "Möchtest du die Follow-Anfrage von {name} ablehnen?"
|
||||
exportRequested: "Du hast einen Export angefragt. Dies kann etwas Zeit in Anspruch nehmen. Sobald der Export abgeschlossen ist, wird er deiner Drive hinzugefügt."
|
||||
importRequested: "Du hast einen Import angefragt. Dies kann etwas Zeit in Anspruch nehmen."
|
||||
lists: "Listen"
|
||||
|
|
@ -1018,6 +1019,7 @@ pushNotificationAlreadySubscribed: "Push-Benachrichtigungen sind bereits aktivie
|
|||
pushNotificationNotSupported: "Entweder dein Browser oder deine Instanz unterstützt Push-Benachrichtigungen nicht"
|
||||
sendPushNotificationReadMessage: "Push-Benachrichtigungen löschen, sobald sie gelesen wurden"
|
||||
sendPushNotificationReadMessageCaption: "Dies kann gegebenenfalls den Batterieverbrauch deines Gerätes erhöhen."
|
||||
pleaseAllowPushNotification: "Bitte erlauben Sie Benachrichtigungen in Ihrem Browser."
|
||||
windowMaximize: "Maximieren"
|
||||
windowMinimize: "Minimieren"
|
||||
windowRestore: "Wiederherstellen"
|
||||
|
|
@ -1054,6 +1056,7 @@ permissionDeniedError: "Aktion verweigert"
|
|||
permissionDeniedErrorDescription: "Dieses Benutzerkonto besitzt nicht die Berechtigung, um diese Aktion auszuführen."
|
||||
preset: "Vorlage"
|
||||
selectFromPresets: "Aus Vorlagen wählen"
|
||||
custom: "Benutzerdefiniert"
|
||||
achievements: "Errungenschaften"
|
||||
gotInvalidResponseError: "Ungültige Antwort des Servers"
|
||||
gotInvalidResponseErrorDescription: "Eventuell ist der Server momentan nicht erreichbar oder untergeht Wartungsarbeiten. Bitte versuche es später noch einmal."
|
||||
|
|
@ -1243,6 +1246,7 @@ releaseToRefresh: "Zum Aktualisieren loslassen"
|
|||
refreshing: "Wird aktualisiert..."
|
||||
pullDownToRefresh: "Zum Aktualisieren ziehen"
|
||||
useGroupedNotifications: "Benachrichtigungen gruppieren"
|
||||
emailVerificationFailedError: "Es gab ein Problem bei der Überprüfung Ihrer E-Mail-Adresse. Der Link ist möglicherweise abgelaufen."
|
||||
cwNotationRequired: "Ist \"Inhaltswarnung verwenden\" aktiviert, muss eine Beschreibung gegeben werden."
|
||||
doReaction: "Reagieren"
|
||||
code: "Code"
|
||||
|
|
@ -1370,7 +1374,12 @@ defaultImageCompressionLevel: "Standard-Bildkomprimierungsstufe"
|
|||
defaultImageCompressionLevel_description: "Ein niedrigerer Wert erhält die Bildqualität, erhöht aber die Dateigröße. <br>Höhere Werte reduzieren die Dateigröße, verringern aber die Bildqualität."
|
||||
inMinutes: "Minute(n)"
|
||||
inDays: "Tag(en)"
|
||||
safeModeEnabled: "Der abgesicherte Modus ist aktiviert."
|
||||
schedule: "Planen"
|
||||
scheduled: "Geplant"
|
||||
widgets: "Widgets"
|
||||
deviceInfo: "Geräteinformation"
|
||||
youAreAdmin: "Sie sind ein Administrator"
|
||||
presets: "Vorlage"
|
||||
_imageEditing:
|
||||
_vars:
|
||||
|
|
|
|||
|
|
@ -83,6 +83,8 @@ files: "Files"
|
|||
download: "Download"
|
||||
driveFileDeleteConfirm: "Are you sure you want to delete \"{name}\"? All notes with this file attached will also be deleted."
|
||||
unfollowConfirm: "Are you sure you want to unfollow {name}?"
|
||||
cancelFollowRequestConfirm: "Are you sure that you want to cancel your follow request to {name}?"
|
||||
rejectFollowRequestConfirm: "Are you sure that you want to reject the follow request from {name}?"
|
||||
exportRequested: "You've requested an export. This may take a while. It will be added to your Drive once completed."
|
||||
importRequested: "You've requested an import. This may take a while."
|
||||
lists: "Lists"
|
||||
|
|
|
|||
|
|
@ -1252,7 +1252,7 @@ detachAll: "Quitar todo"
|
|||
angle: "Ángulo"
|
||||
flip: "Echar de un capirotazo"
|
||||
showAvatarDecorations: "Mostrar decoraciones de avatar"
|
||||
releaseToRefresh: "Soltar para recargar"
|
||||
releaseToRefresh: "Suelta para recargar"
|
||||
refreshing: "Recargando..."
|
||||
pullDownToRefresh: "Tira hacia abajo para recargar"
|
||||
useGroupedNotifications: "Mostrar notificaciones agrupadas"
|
||||
|
|
|
|||
|
|
@ -2890,6 +2890,15 @@ _deck:
|
|||
usedAsMinWidthWhenFlexible: "「幅を自動調整」が有効の場合、これが幅の最小値となります"
|
||||
flexible: "幅を自動調整"
|
||||
enableSyncBetweenDevicesForProfiles: "プロファイル情報のデバイス間同期を有効にする"
|
||||
showHowToUse: "UIの説明を見る"
|
||||
|
||||
_howToUse:
|
||||
addColumn_title: "カラム追加"
|
||||
addColumn_description: "カラムの種類を選んで追加できます。"
|
||||
settings_title: "UI設定"
|
||||
settings_description: "デッキUIの詳細設定を行えます。"
|
||||
switchProfile_title: "プロファイル切り替え"
|
||||
switchProfile_description: "UIのレイアウトをプロファイルとして保存し、いつでも切り替えられるようにできます。"
|
||||
|
||||
_columns:
|
||||
main: "メイン"
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ copyRemoteLink: "复制远程链接"
|
|||
copyLinkRenote: "复制转帖链接"
|
||||
delete: "删除"
|
||||
deleteAndEdit: "删除并编辑"
|
||||
deleteAndEditConfirm: "要删除此帖并再次编辑吗?对此帖的所有回应、转发和回复也将被删除。"
|
||||
deleteAndEditConfirm: "要删除此帖并再次编辑吗?此帖下所有的回应、转发和回复也将被删除。"
|
||||
addToList: "添加至列表"
|
||||
addToAntenna: "添加到天线"
|
||||
sendMessage: "发送消息"
|
||||
|
|
@ -136,7 +136,7 @@ emojiPicker: "表情符号选择器"
|
|||
pinnedEmojisForReactionSettingDescription: "可以设置发表回应时置顶显示的表情符号"
|
||||
pinnedEmojisSettingDescription: "可以设置输入表情符号时置顶显示的表情符号"
|
||||
emojiPickerDisplay: "选择器显示设置"
|
||||
overwriteFromPinnedEmojisForReaction: "从「置顶(回应)」设置覆盖"
|
||||
overwriteFromPinnedEmojisForReaction: "使用「置顶(回应)」设置覆盖"
|
||||
overwriteFromPinnedEmojis: "从全局设置覆盖"
|
||||
reactionSettingDescription2: "拖动重新排序,单击删除,点击 + 添加。"
|
||||
rememberNoteVisibility: "保存上次设置的可见性"
|
||||
|
|
@ -153,8 +153,8 @@ block: "拉黑"
|
|||
unblock: "取消拉黑"
|
||||
suspend: "冻结"
|
||||
unsuspend: "解除冻结"
|
||||
blockConfirm: "确定要拉黑吗?"
|
||||
unblockConfirm: "确定要取消拉黑吗?"
|
||||
blockConfirm: "确定要屏蔽吗?"
|
||||
unblockConfirm: "确定要取消屏蔽吗?"
|
||||
suspendConfirm: "要冻结吗?"
|
||||
unsuspendConfirm: "要解除冻结吗?"
|
||||
selectList: "选择列表"
|
||||
|
|
@ -174,7 +174,7 @@ emojiUrl: "emoji 地址"
|
|||
addEmoji: "添加表情符号"
|
||||
settingGuide: "推荐配置"
|
||||
cacheRemoteFiles: "缓存远程文件"
|
||||
cacheRemoteFilesDescription: "启用此设定时,将在此服务器上缓存远程文件。虽然可以加快图片显示的速度,但是相对的会消耗大量的服务器存储空间。用户角色内的网盘容量决定了这个远程用户能在服务器上保留多少缓存。当超出了这个限制时,旧的文件将从缓存中被删除,成为链接。当禁用此设定时,则是从一开始就将远程文件保留为链接。此时推荐将 default.yml 的 proxyRemoteFiles 设置为 true 以优化缩略图生成及保护用户隐私。"
|
||||
cacheRemoteFilesDescription: "启用此设定时,将在此服务器上缓存远程文件。虽然可以加快图片显示的速度,但是相对的会消耗大量的服务器存储空间。用户角色内的网盘容量决定了这个远程用户能在服务器上保留多少缓存。当超出了这个限制时,旧的文件将从缓存中被删除,成为链接。当禁用此设定时,则是从一开始就将远程文件保留为链接。此时推荐将 的 proxyRemoteFiles 设置为 true 以优化缩略图生成及保护用户隐私。"
|
||||
youCanCleanRemoteFilesCache: "可以使用文件管理的🗑️按钮来删除所有的缓存。"
|
||||
cacheRemoteSensitiveFiles: "缓存远程敏感媒体文件"
|
||||
cacheRemoteSensitiveFilesDescription: "如果禁用这项设定,远程服务器的敏感媒体将不会被缓存,而是直接链接。"
|
||||
|
|
@ -184,7 +184,7 @@ flagAsCat: "喵!!!!!!!!!!!!"
|
|||
flagAsCatDescription: "喵喵喵??"
|
||||
flagShowTimelineReplies: "在时间线上显示帖子的回复"
|
||||
flagShowTimelineRepliesDescription: "启用时,时间线除了显示用户的帖子外,还会显示其他用户对帖子的回复。"
|
||||
autoAcceptFollowed: "自动允许来自我关注的用户对我的关注请求"
|
||||
autoAcceptFollowed: "自动允许回关请求"
|
||||
addAccount: "添加账户"
|
||||
reloadAccountsList: "更新账户列表"
|
||||
loginFailed: "登录失败"
|
||||
|
|
@ -247,8 +247,8 @@ mediaSilencedInstancesDescription: "设置要隐藏媒体文件的服务器,
|
|||
federationAllowedHosts: "允许联合的服务器"
|
||||
federationAllowedHostsDescription: "设定允许联合的服务器,以换行分隔。"
|
||||
muteAndBlock: "屏蔽/拉黑"
|
||||
mutedUsers: "已屏蔽用户"
|
||||
blockedUsers: "已拉黑的用户"
|
||||
mutedUsers: "已静音的用户"
|
||||
blockedUsers: "已屏蔽的用户"
|
||||
noUsers: "无用户"
|
||||
editProfile: "编辑资料"
|
||||
noteDeleteConfirm: "确定要删除该帖子吗?"
|
||||
|
|
@ -1344,7 +1344,7 @@ skip: "跳过"
|
|||
restore: "恢复"
|
||||
syncBetweenDevices: "设备间同步"
|
||||
preferenceSyncConflictTitle: "服务器上已存在设定值"
|
||||
preferenceSyncConflictText: "服务器上已有此设置的设定值。要覆盖哪个设定值?"
|
||||
preferenceSyncConflictText: "即将保存设定值到服务器,但检测到服务器上已有此设置的设定值。要使用哪个设定值?"
|
||||
preferenceSyncConflictChoiceMerge: "合并"
|
||||
preferenceSyncConflictChoiceServer: "服务器上的设定值"
|
||||
preferenceSyncConflictChoiceDevice: "设备上的设定值"
|
||||
|
|
@ -3270,7 +3270,7 @@ _watermarkEditor:
|
|||
driveFileTypeWarn: "不支持此文件"
|
||||
driveFileTypeWarnDescription: "请选择图像文件"
|
||||
title: "编辑水印"
|
||||
cover: "覆盖全体"
|
||||
cover: "覆盖所有"
|
||||
repeat: "平铺"
|
||||
preserveBoundingRect: "调整为旋转时不超出范围"
|
||||
opacity: "不透明度"
|
||||
|
|
|
|||
22
package.json
22
package.json
|
|
@ -1,12 +1,12 @@
|
|||
{
|
||||
"name": "misskey",
|
||||
"version": "2025.12.0-alpha.2",
|
||||
"version": "2025.12.2-beta.2",
|
||||
"codename": "nasubi",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/misskey-dev/misskey.git"
|
||||
},
|
||||
"packageManager": "pnpm@10.23.0",
|
||||
"packageManager": "pnpm@10.25.0",
|
||||
"workspaces": [
|
||||
"packages/misskey-js",
|
||||
"packages/i18n",
|
||||
|
|
@ -53,15 +53,13 @@
|
|||
"cleanall": "pnpm clean-all"
|
||||
},
|
||||
"resolutions": {
|
||||
"chokidar": "4.0.3",
|
||||
"chokidar": "5.0.0",
|
||||
"lodash": "4.17.21"
|
||||
},
|
||||
"dependencies": {
|
||||
"cssnano": "7.1.2",
|
||||
"esbuild": "0.27.0",
|
||||
"execa": "9.6.0",
|
||||
"fast-glob": "3.3.3",
|
||||
"glob": "13.0.0",
|
||||
"esbuild": "0.27.1",
|
||||
"execa": "9.6.1",
|
||||
"ignore-walk": "8.0.0",
|
||||
"js-yaml": "4.1.1",
|
||||
"postcss": "8.5.6",
|
||||
|
|
@ -73,15 +71,15 @@
|
|||
"@eslint/js": "9.39.1",
|
||||
"@misskey-dev/eslint-plugin": "2.2.0",
|
||||
"@types/js-yaml": "4.0.9",
|
||||
"@types/node": "24.10.1",
|
||||
"@typescript-eslint/eslint-plugin": "8.47.0",
|
||||
"@typescript-eslint/parser": "8.47.0",
|
||||
"@types/node": "24.10.2",
|
||||
"@typescript-eslint/eslint-plugin": "8.49.0",
|
||||
"@typescript-eslint/parser": "8.49.0",
|
||||
"cross-env": "10.1.0",
|
||||
"cypress": "15.7.0",
|
||||
"cypress": "15.7.1",
|
||||
"eslint": "9.39.1",
|
||||
"globals": "16.5.0",
|
||||
"ncp": "2.0.0",
|
||||
"pnpm": "10.23.0",
|
||||
"pnpm": "10.25.0",
|
||||
"start-server-and-test": "2.1.3"
|
||||
},
|
||||
"optionalDependencies": {
|
||||
|
|
|
|||
|
|
@ -71,26 +71,25 @@
|
|||
"utf-8-validate": "6.0.5"
|
||||
},
|
||||
"dependencies": {
|
||||
"@aws-sdk/client-s3": "3.937.0",
|
||||
"@aws-sdk/lib-storage": "3.937.0",
|
||||
"@aws-sdk/client-s3": "3.948.0",
|
||||
"@aws-sdk/lib-storage": "3.948.0",
|
||||
"@discordapp/twemoji": "16.0.1",
|
||||
"@fastify/accepts": "5.0.3",
|
||||
"@fastify/cookie": "11.0.2",
|
||||
"@fastify/cors": "11.1.0",
|
||||
"@fastify/accepts": "5.0.4",
|
||||
"@fastify/cors": "11.2.0",
|
||||
"@fastify/express": "4.0.2",
|
||||
"@fastify/http-proxy": "11.3.0",
|
||||
"@fastify/http-proxy": "11.4.1",
|
||||
"@fastify/multipart": "9.3.0",
|
||||
"@fastify/static": "8.3.0",
|
||||
"@kitajs/html": "4.2.11",
|
||||
"@misskey-dev/sharp-read-bmp": "1.2.0",
|
||||
"@misskey-dev/summaly": "5.2.5",
|
||||
"@napi-rs/canvas": "0.1.82",
|
||||
"@napi-rs/canvas": "0.1.84",
|
||||
"@nestjs/common": "11.1.9",
|
||||
"@nestjs/core": "11.1.9",
|
||||
"@nestjs/testing": "11.1.9",
|
||||
"@peertube/http-signature": "1.7.0",
|
||||
"@sentry/node": "10.26.0",
|
||||
"@sentry/profiling-node": "10.26.0",
|
||||
"@sentry/node": "10.29.0",
|
||||
"@sentry/profiling-node": "10.29.0",
|
||||
"@simplewebauthn/server": "13.2.2",
|
||||
"@sinonjs/fake-timers": "15.0.0",
|
||||
"@smithy/node-http-handler": "4.4.5",
|
||||
|
|
@ -104,13 +103,12 @@
|
|||
"async-mutex": "0.5.0",
|
||||
"bcryptjs": "3.0.3",
|
||||
"blurhash": "2.0.5",
|
||||
"body-parser": "2.2.0",
|
||||
"bullmq": "5.64.1",
|
||||
"body-parser": "2.2.1",
|
||||
"bullmq": "5.65.1",
|
||||
"cacheable-lookup": "7.0.0",
|
||||
"cbor": "10.0.11",
|
||||
"chalk": "5.6.2",
|
||||
"chalk-template": "1.1.2",
|
||||
"chokidar": "4.0.3",
|
||||
"chokidar": "5.0.0",
|
||||
"color-convert": "3.1.3",
|
||||
"content-disposition": "1.0.1",
|
||||
"date-fns": "4.1.0",
|
||||
|
|
@ -121,17 +119,16 @@
|
|||
"file-type": "21.1.1",
|
||||
"fluent-ffmpeg": "2.1.3",
|
||||
"form-data": "4.0.5",
|
||||
"got": "14.6.4",
|
||||
"got": "14.6.5",
|
||||
"hpagent": "1.2.0",
|
||||
"http-link-header": "1.1.3",
|
||||
"i18n": "workspace:*",
|
||||
"ioredis": "5.8.2",
|
||||
"ip-cidr": "4.0.2",
|
||||
"ipaddr.js": "2.2.0",
|
||||
"ipaddr.js": "2.3.0",
|
||||
"is-svg": "6.1.0",
|
||||
"json5": "2.2.3",
|
||||
"jsonld": "9.0.0",
|
||||
"jsrsasign": "11.1.0",
|
||||
"juice": "11.0.3",
|
||||
"meilisearch": "0.54.0",
|
||||
"mfm-js": "0.25.0",
|
||||
|
|
@ -143,15 +140,14 @@
|
|||
"nested-property": "4.0.0",
|
||||
"node-fetch": "3.3.2",
|
||||
"node-html-parser": "7.0.1",
|
||||
"nodemailer": "7.0.10",
|
||||
"nodemailer": "7.0.11",
|
||||
"nsfwjs": "4.2.0",
|
||||
"oauth": "0.10.2",
|
||||
"oauth2orize": "1.12.0",
|
||||
"oauth2orize-pkce": "0.1.2",
|
||||
"os-utils": "0.0.14",
|
||||
"otpauth": "9.4.1",
|
||||
"pg": "8.16.3",
|
||||
"pkce-challenge": "5.0.0",
|
||||
"pkce-challenge": "5.0.1",
|
||||
"probe-image-size": "7.2.3",
|
||||
"promise-limit": "2.7.0",
|
||||
"qrcode": "1.5.4",
|
||||
|
|
@ -170,14 +166,13 @@
|
|||
"slacc": "0.0.10",
|
||||
"strict-event-emitter-types": "2.0.0",
|
||||
"stringz": "2.1.0",
|
||||
"systeminformation": "5.27.11",
|
||||
"systeminformation": "5.27.14",
|
||||
"tinycolor2": "1.6.0",
|
||||
"tmp": "0.2.5",
|
||||
"tsc-alias": "1.8.16",
|
||||
"tsconfig-paths": "4.2.0",
|
||||
"typeorm": "0.3.27",
|
||||
"typeorm": "0.3.28",
|
||||
"typescript": "5.9.3",
|
||||
"ulid": "3.0.1",
|
||||
"ulid": "3.0.2",
|
||||
"vary": "1.1.2",
|
||||
"web-push": "3.6.7",
|
||||
"ws": "8.18.3",
|
||||
|
|
@ -187,7 +182,7 @@
|
|||
"@jest/globals": "29.7.0",
|
||||
"@kitajs/ts-html-plugin": "4.1.3",
|
||||
"@nestjs/platform-express": "11.1.9",
|
||||
"@sentry/vue": "10.26.0",
|
||||
"@sentry/vue": "10.29.0",
|
||||
"@simplewebauthn/types": "12.0.0",
|
||||
"@swc/jest": "0.2.39",
|
||||
"@types/accepts": "1.3.7",
|
||||
|
|
@ -199,12 +194,10 @@
|
|||
"@types/http-link-header": "1.0.7",
|
||||
"@types/jest": "29.5.14",
|
||||
"@types/jsonld": "1.5.15",
|
||||
"@types/jsrsasign": "10.5.15",
|
||||
"@types/mime-types": "3.0.1",
|
||||
"@types/ms": "2.1.0",
|
||||
"@types/node": "24.10.1",
|
||||
"@types/node": "24.10.2",
|
||||
"@types/nodemailer": "7.0.4",
|
||||
"@types/oauth": "0.9.6",
|
||||
"@types/oauth2orize": "1.11.5",
|
||||
"@types/oauth2orize-pkce": "0.1.2",
|
||||
"@types/pg": "8.15.6",
|
||||
|
|
@ -214,7 +207,7 @@
|
|||
"@types/rename": "1.0.7",
|
||||
"@types/sanitize-html": "2.16.0",
|
||||
"@types/semver": "7.7.1",
|
||||
"@types/simple-oauth2": "5.0.7",
|
||||
"@types/simple-oauth2": "5.0.8",
|
||||
"@types/sinonjs__fake-timers": "15.0.1",
|
||||
"@types/supertest": "6.0.3",
|
||||
"@types/tinycolor2": "1.4.6",
|
||||
|
|
@ -222,21 +215,21 @@
|
|||
"@types/vary": "1.1.3",
|
||||
"@types/web-push": "3.6.4",
|
||||
"@types/ws": "8.18.1",
|
||||
"@typescript-eslint/eslint-plugin": "8.47.0",
|
||||
"@typescript-eslint/parser": "8.47.0",
|
||||
"@typescript-eslint/eslint-plugin": "8.49.0",
|
||||
"@typescript-eslint/parser": "8.49.0",
|
||||
"aws-sdk-client-mock": "4.1.0",
|
||||
"cbor": "10.0.11",
|
||||
"cross-env": "10.1.0",
|
||||
"eslint-plugin-import": "2.32.0",
|
||||
"execa": "9.6.0",
|
||||
"execa": "9.6.1",
|
||||
"fkill": "10.0.1",
|
||||
"jest": "29.7.0",
|
||||
"jest-mock": "29.7.0",
|
||||
"jest-util": "29.7.0",
|
||||
"js-yaml": "4.1.1",
|
||||
"nodemon": "3.1.11",
|
||||
"pid-port": "2.0.0",
|
||||
"simple-oauth2": "5.1.0",
|
||||
"supertest": "7.1.4",
|
||||
"vite": "7.2.4"
|
||||
"vite": "7.2.7"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@ import * as fs from 'node:fs';
|
|||
import { fileURLToPath } from 'node:url';
|
||||
import { dirname } from 'node:path';
|
||||
import { Injectable } from '@nestjs/common';
|
||||
import si from 'systeminformation';
|
||||
import { Mutex } from 'async-mutex';
|
||||
import fetch from 'node-fetch';
|
||||
import { bindThis } from '@/decorators.js';
|
||||
|
|
@ -84,6 +83,7 @@ export class AiService {
|
|||
|
||||
@bindThis
|
||||
private async getCpuFlags(): Promise<string[]> {
|
||||
const si = await import('systeminformation');
|
||||
const str = await si.cpuFlags();
|
||||
return str.split(/\s+/);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@ import type { UsersRepository, NotesRepository, FollowingsRepository, PollsRepos
|
|||
import { bindThis } from '@/decorators.js';
|
||||
import { DebounceLoader } from '@/misc/loader.js';
|
||||
import { IdService } from '@/core/IdService.js';
|
||||
import { shouldHideNoteByTime } from '@/misc/should-hide-note-by-time.js';
|
||||
import { ReactionsBufferingService } from '@/core/ReactionsBufferingService.js';
|
||||
import type { OnModuleInit } from '@nestjs/common';
|
||||
import type { CustomEmojiService } from '../CustomEmojiService.js';
|
||||
|
|
@ -116,12 +117,7 @@ export class NoteEntityService implements OnModuleInit {
|
|||
private treatVisibility(packedNote: Packed<'Note'>): Packed<'Note'>['visibility'] {
|
||||
if (packedNote.visibility === 'public' || packedNote.visibility === 'home') {
|
||||
const followersOnlyBefore = packedNote.user.makeNotesFollowersOnlyBefore;
|
||||
if ((followersOnlyBefore != null)
|
||||
&& (
|
||||
(followersOnlyBefore <= 0 && (Date.now() - new Date(packedNote.createdAt).getTime() > 0 - (followersOnlyBefore * 1000)))
|
||||
|| (followersOnlyBefore > 0 && (new Date(packedNote.createdAt).getTime() < followersOnlyBefore * 1000))
|
||||
)
|
||||
) {
|
||||
if (shouldHideNoteByTime(followersOnlyBefore, packedNote.createdAt)) {
|
||||
packedNote.visibility = 'followers';
|
||||
}
|
||||
}
|
||||
|
|
@ -141,12 +137,7 @@ export class NoteEntityService implements OnModuleInit {
|
|||
|
||||
if (!hide) {
|
||||
const hiddenBefore = packedNote.user.makeNotesHiddenBefore;
|
||||
if ((hiddenBefore != null)
|
||||
&& (
|
||||
(hiddenBefore <= 0 && (Date.now() - new Date(packedNote.createdAt).getTime() > 0 - (hiddenBefore * 1000)))
|
||||
|| (hiddenBefore > 0 && (new Date(packedNote.createdAt).getTime() < hiddenBefore * 1000))
|
||||
)
|
||||
) {
|
||||
if (shouldHideNoteByTime(hiddenBefore, packedNote.createdAt)) {
|
||||
hide = true;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,13 +4,12 @@
|
|||
*/
|
||||
|
||||
import { Inject, Injectable } from '@nestjs/common';
|
||||
import si from 'systeminformation';
|
||||
import Xev from 'xev';
|
||||
import * as osUtils from 'os-utils';
|
||||
import { bindThis } from '@/decorators.js';
|
||||
import type { OnApplicationShutdown } from '@nestjs/common';
|
||||
import { MiMeta } from '@/models/_.js';
|
||||
import { DI } from '@/di-symbols.js';
|
||||
import type { OnApplicationShutdown } from '@nestjs/common';
|
||||
|
||||
const ev = new Xev();
|
||||
|
||||
|
|
@ -97,12 +96,14 @@ function cpuUsage(): Promise<number> {
|
|||
|
||||
// MEMORY STAT
|
||||
async function mem() {
|
||||
const si = await import('systeminformation');
|
||||
const data = await si.mem();
|
||||
return data;
|
||||
}
|
||||
|
||||
// NETWORK STAT
|
||||
async function net() {
|
||||
const si = await import('systeminformation');
|
||||
const iface = await si.networkInterfaceDefault();
|
||||
const data = await si.networkStats(iface);
|
||||
return data[0];
|
||||
|
|
@ -110,5 +111,6 @@ async function net() {
|
|||
|
||||
// FS STAT
|
||||
async function fs() {
|
||||
const si = await import('systeminformation');
|
||||
return await si.disksIO().catch(() => ({ rIO_sec: 0, wIO_sec: 0 }));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,29 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: syuilo and misskey-project
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
/**
|
||||
* ノートが指定された時間条件に基づいて非表示対象かどうかを判定する
|
||||
* @param hiddenBefore 非表示条件(負の値: 作成からの経過秒数、正の値: UNIXタイムスタンプ秒、null: 判定しない)
|
||||
* @param createdAt ノートの作成日時(ISO 8601形式の文字列 または Date オブジェクト)
|
||||
* @returns 非表示にすべき場合は true
|
||||
*/
|
||||
export function shouldHideNoteByTime(hiddenBefore: number | null | undefined, createdAt: string | Date): boolean {
|
||||
if (hiddenBefore == null) {
|
||||
return false;
|
||||
}
|
||||
|
||||
const createdAtTime = typeof createdAt === 'string' ? new Date(createdAt).getTime() : createdAt.getTime();
|
||||
|
||||
if (hiddenBefore <= 0) {
|
||||
// 負の値: 作成からの経過時間(秒)で判定
|
||||
const elapsedSeconds = (Date.now() - createdAtTime) / 1000;
|
||||
const hideAfterSeconds = Math.abs(hiddenBefore);
|
||||
return elapsedSeconds >= hideAfterSeconds;
|
||||
} else {
|
||||
// 正の値: 絶対的なタイムスタンプ(秒)で判定
|
||||
const createdAtSeconds = createdAtTime / 1000;
|
||||
return createdAtSeconds <= hiddenBefore;
|
||||
}
|
||||
}
|
||||
|
|
@ -4,15 +4,11 @@
|
|||
*/
|
||||
|
||||
import * as os from 'node:os';
|
||||
import sysUtils from 'systeminformation';
|
||||
import type Logger from '@/logger.js';
|
||||
|
||||
export async function showMachineInfo(parentLogger: Logger) {
|
||||
const logger = parentLogger.createSubLogger('machine');
|
||||
logger.debug(`Hostname: ${os.hostname()}`);
|
||||
logger.debug(`Platform: ${process.platform} Arch: ${process.arch}`);
|
||||
const mem = await sysUtils.mem();
|
||||
const totalmem = (mem.total / 1024 / 1024 / 1024).toFixed(1);
|
||||
const availmem = (mem.available / 1024 / 1024 / 1024).toFixed(1);
|
||||
logger.debug(`CPU: ${os.cpus().length} core MEM: ${totalmem}GB (available: ${availmem}GB)`);
|
||||
logger.debug(`CPU: ${os.cpus().length} core MEM: ${(os.totalmem() / 1024 / 1024 / 1024).toFixed(1)}GB (available: ${(os.freemem() / 1024 / 1024 / 1024).toFixed(1)}GB)`);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -157,7 +157,7 @@ export class QueueProcessorService implements OnApplicationShutdown {
|
|||
}
|
||||
|
||||
let Sentry: typeof import('@sentry/node') | undefined;
|
||||
if (Sentry != null) {
|
||||
if (this.config.sentryForBackend) {
|
||||
import('@sentry/node').then((mod) => {
|
||||
Sentry = mod;
|
||||
});
|
||||
|
|
|
|||
|
|
@ -5,21 +5,20 @@
|
|||
|
||||
import * as fs from 'node:fs';
|
||||
import { Writable } from 'node:stream';
|
||||
import { Inject, Injectable, StreamableFile } from '@nestjs/common';
|
||||
import { MoreThan } from 'typeorm';
|
||||
import { Inject, Injectable } from '@nestjs/common';
|
||||
import { format as dateFormat } from 'date-fns';
|
||||
import { DI } from '@/di-symbols.js';
|
||||
import type { ClipNotesRepository, ClipsRepository, MiClip, MiClipNote, MiUser, NotesRepository, PollsRepository, UsersRepository } from '@/models/_.js';
|
||||
import type { ClipNotesRepository, ClipsRepository, MiClip, MiClipNote, MiUser, PollsRepository, UsersRepository } from '@/models/_.js';
|
||||
import type Logger from '@/logger.js';
|
||||
import { DriveService } from '@/core/DriveService.js';
|
||||
import { createTemp } from '@/misc/create-temp.js';
|
||||
import type { MiPoll } from '@/models/Poll.js';
|
||||
import type { MiNote } from '@/models/Note.js';
|
||||
import { bindThis } from '@/decorators.js';
|
||||
import { DriveFileEntityService } from '@/core/entities/DriveFileEntityService.js';
|
||||
import { Packed } from '@/misc/json-schema.js';
|
||||
import { IdService } from '@/core/IdService.js';
|
||||
import { NotificationService } from '@/core/NotificationService.js';
|
||||
import { QueryService } from '@/core/QueryService.js';
|
||||
import { shouldHideNoteByTime } from '@/misc/should-hide-note-by-time.js';
|
||||
import { QueueLoggerService } from '../QueueLoggerService.js';
|
||||
import type * as Bull from 'bullmq';
|
||||
import type { DbJobDataWithUser } from '../types.js';
|
||||
|
|
@ -43,6 +42,7 @@ export class ExportClipsProcessorService {
|
|||
|
||||
private driveService: DriveService,
|
||||
private queueLoggerService: QueueLoggerService,
|
||||
private queryService: QueryService,
|
||||
private idService: IdService,
|
||||
private notificationService: NotificationService,
|
||||
) {
|
||||
|
|
@ -100,16 +100,16 @@ export class ExportClipsProcessorService {
|
|||
});
|
||||
|
||||
while (true) {
|
||||
const clips = await this.clipsRepository.find({
|
||||
where: {
|
||||
userId: user.id,
|
||||
...(cursor ? { id: MoreThan(cursor) } : {}),
|
||||
},
|
||||
take: 100,
|
||||
order: {
|
||||
id: 1,
|
||||
},
|
||||
});
|
||||
const query = this.clipsRepository.createQueryBuilder('clip')
|
||||
.where('clip.userId = :userId', { userId: user.id })
|
||||
.orderBy('clip.id', 'ASC')
|
||||
.take(100);
|
||||
|
||||
if (cursor) {
|
||||
query.andWhere('clip.id > :cursor', { cursor });
|
||||
}
|
||||
|
||||
const clips = await query.getMany();
|
||||
|
||||
if (clips.length === 0) {
|
||||
job.updateProgress(100);
|
||||
|
|
@ -124,7 +124,7 @@ export class ExportClipsProcessorService {
|
|||
const isFirst = exportedClipsCount === 0;
|
||||
await writer.write(isFirst ? content : ',\n' + content);
|
||||
|
||||
await this.processClipNotes(writer, clip.id);
|
||||
await this.processClipNotes(writer, clip.id, user.id);
|
||||
|
||||
await writer.write(']}');
|
||||
exportedClipsCount++;
|
||||
|
|
@ -134,22 +134,25 @@ export class ExportClipsProcessorService {
|
|||
}
|
||||
}
|
||||
|
||||
async processClipNotes(writer: WritableStreamDefaultWriter, clipId: string): Promise<void> {
|
||||
async processClipNotes(writer: WritableStreamDefaultWriter, clipId: string, userId: string): Promise<void> {
|
||||
let exportedClipNotesCount = 0;
|
||||
let cursor: MiClipNote['id'] | null = null;
|
||||
|
||||
while (true) {
|
||||
const clipNotes = await this.clipNotesRepository.find({
|
||||
where: {
|
||||
clipId,
|
||||
...(cursor ? { id: MoreThan(cursor) } : {}),
|
||||
},
|
||||
take: 100,
|
||||
order: {
|
||||
id: 1,
|
||||
},
|
||||
relations: ['note', 'note.user'],
|
||||
}) as (MiClipNote & { note: MiNote & { user: MiUser } })[];
|
||||
const query = this.clipNotesRepository.createQueryBuilder('clipNote')
|
||||
.leftJoinAndSelect('clipNote.note', 'note')
|
||||
.leftJoinAndSelect('note.user', 'user')
|
||||
.where('clipNote.clipId = :clipId', { clipId })
|
||||
.orderBy('clipNote.id', 'ASC')
|
||||
.take(100);
|
||||
|
||||
if (cursor) {
|
||||
query.andWhere('clipNote.id > :cursor', { cursor });
|
||||
}
|
||||
|
||||
this.queryService.generateVisibilityQuery(query, { id: userId });
|
||||
|
||||
const clipNotes = await query.getMany() as (MiClipNote & { note: MiNote & { user: MiUser } })[];
|
||||
|
||||
if (clipNotes.length === 0) {
|
||||
break;
|
||||
|
|
@ -158,6 +161,11 @@ export class ExportClipsProcessorService {
|
|||
cursor = clipNotes.at(-1)?.id ?? null;
|
||||
|
||||
for (const clipNote of clipNotes) {
|
||||
const noteCreatedAt = this.idService.parse(clipNote.note.id).date;
|
||||
if (shouldHideNoteByTime(clipNote.note.user.makeNotesHiddenBefore, noteCreatedAt)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
let poll: MiPoll | undefined;
|
||||
if (clipNote.note.hasPoll) {
|
||||
poll = await this.pollsRepository.findOneByOrFail({ noteId: clipNote.note.id });
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@
|
|||
|
||||
import * as fs from 'node:fs';
|
||||
import { Inject, Injectable } from '@nestjs/common';
|
||||
import { MoreThan } from 'typeorm';
|
||||
import { format as dateFormat } from 'date-fns';
|
||||
import { DI } from '@/di-symbols.js';
|
||||
import type { MiNoteFavorite, NoteFavoritesRepository, PollsRepository, MiUser, UsersRepository } from '@/models/_.js';
|
||||
|
|
@ -17,6 +16,8 @@ import type { MiNote } from '@/models/Note.js';
|
|||
import { bindThis } from '@/decorators.js';
|
||||
import { IdService } from '@/core/IdService.js';
|
||||
import { NotificationService } from '@/core/NotificationService.js';
|
||||
import { QueryService } from '@/core/QueryService.js';
|
||||
import { shouldHideNoteByTime } from '@/misc/should-hide-note-by-time.js';
|
||||
import { QueueLoggerService } from '../QueueLoggerService.js';
|
||||
import type * as Bull from 'bullmq';
|
||||
import type { DbJobDataWithUser } from '../types.js';
|
||||
|
|
@ -37,6 +38,7 @@ export class ExportFavoritesProcessorService {
|
|||
|
||||
private driveService: DriveService,
|
||||
private queueLoggerService: QueueLoggerService,
|
||||
private queryService: QueryService,
|
||||
private idService: IdService,
|
||||
private notificationService: NotificationService,
|
||||
) {
|
||||
|
|
@ -83,17 +85,20 @@ export class ExportFavoritesProcessorService {
|
|||
});
|
||||
|
||||
while (true) {
|
||||
const favorites = await this.noteFavoritesRepository.find({
|
||||
where: {
|
||||
userId: user.id,
|
||||
...(cursor ? { id: MoreThan(cursor) } : {}),
|
||||
},
|
||||
take: 100,
|
||||
order: {
|
||||
id: 1,
|
||||
},
|
||||
relations: ['note', 'note.user'],
|
||||
}) as (MiNoteFavorite & { note: MiNote & { user: MiUser } })[];
|
||||
const query = this.noteFavoritesRepository.createQueryBuilder('favorite')
|
||||
.leftJoinAndSelect('favorite.note', 'note')
|
||||
.leftJoinAndSelect('note.user', 'user')
|
||||
.where('favorite.userId = :userId', { userId: user.id })
|
||||
.orderBy('favorite.id', 'ASC')
|
||||
.take(100);
|
||||
|
||||
if (cursor) {
|
||||
query.andWhere('favorite.id > :cursor', { cursor });
|
||||
}
|
||||
|
||||
this.queryService.generateVisibilityQuery(query, { id: user.id });
|
||||
|
||||
const favorites = await query.getMany() as (MiNoteFavorite & { note: MiNote & { user: MiUser } })[];
|
||||
|
||||
if (favorites.length === 0) {
|
||||
job.updateProgress(100);
|
||||
|
|
@ -103,6 +108,11 @@ export class ExportFavoritesProcessorService {
|
|||
cursor = favorites.at(-1)?.id ?? null;
|
||||
|
||||
for (const favorite of favorites) {
|
||||
const noteCreatedAt = this.idService.parse(favorite.note.id).date;
|
||||
if (shouldHideNoteByTime(favorite.note.user.makeNotesHiddenBefore, noteCreatedAt)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
let poll: MiPoll | undefined;
|
||||
if (favorite.note.hasPoll) {
|
||||
poll = await this.pollsRepository.findOneByOrFail({ noteId: favorite.note.id });
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ export class ServerService implements OnApplicationShutdown {
|
|||
@bindThis
|
||||
public async launch(): Promise<void> {
|
||||
const fastify = Fastify({
|
||||
trustProxy: this.config.trustProxy ?? false,
|
||||
trustProxy: this.config.trustProxy ?? true,
|
||||
logger: false,
|
||||
});
|
||||
this.#fastify = fastify;
|
||||
|
|
|
|||
|
|
@ -313,13 +313,17 @@ export class ApiCallService implements OnApplicationShutdown {
|
|||
}
|
||||
|
||||
if (ep.meta.limit) {
|
||||
// koa will automatically load the `X-Forwarded-For` header if `proxy: true` is configured in the app.
|
||||
let limitActor: string;
|
||||
let limitActor: string | null;
|
||||
if (user) {
|
||||
limitActor = user.id;
|
||||
} else {
|
||||
if (request.ip === '::1' || request.ip === '127.0.0.1') {
|
||||
console.warn('request ip is localhost, maybe caused by misconfiguration of trustProxy or reverse proxy');
|
||||
limitActor = null;
|
||||
} else {
|
||||
limitActor = getIpHash(request.ip);
|
||||
}
|
||||
}
|
||||
|
||||
const limit = Object.assign({}, ep.meta.limit);
|
||||
|
||||
|
|
@ -330,7 +334,7 @@ export class ApiCallService implements OnApplicationShutdown {
|
|||
// TODO: 毎リクエスト計算するのもあれだしキャッシュしたい
|
||||
const factor = user ? (await this.roleService.getUserPolicies(user.id)).rateLimitFactor : 1;
|
||||
|
||||
if (factor > 0) {
|
||||
if (limitActor != null && factor > 0) {
|
||||
// Rate limit
|
||||
const rateLimit = await this.rateLimiterService.limit(limit as IEndpointMeta['limit'] & { key: NonNullable<string> }, limitActor, factor);
|
||||
if (rateLimit != null) {
|
||||
|
|
|
|||
|
|
@ -89,6 +89,9 @@ export class SigninApiService {
|
|||
return { error };
|
||||
}
|
||||
|
||||
if (request.ip === '::1' || request.ip === '127.0.0.1') {
|
||||
console.warn('request ip is localhost, maybe caused by misconfiguration of trustProxy or reverse proxy');
|
||||
} else {
|
||||
// not more than 1 attempt per second and not more than 10 attempts per hour
|
||||
const rateLimit = await this.rateLimiterService.limit({ key: 'signin', duration: 60 * 60 * 1000, max: 10, minInterval: 1000 }, getIpHash(request.ip));
|
||||
if (rateLimit != null) {
|
||||
|
|
@ -101,6 +104,7 @@ export class SigninApiService {
|
|||
},
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
if (typeof username !== 'string') {
|
||||
reply.code(400);
|
||||
|
|
|
|||
|
|
@ -84,6 +84,9 @@ export class SigninWithPasskeyApiService {
|
|||
return error(status ?? 500, failure ?? { id: '4e30e80c-e338-45a0-8c8f-44455efa3b76' });
|
||||
};
|
||||
|
||||
if (request.ip === '::1' || request.ip === '127.0.0.1') {
|
||||
console.warn('request ip is localhost, maybe caused by misconfiguration of trustProxy or reverse proxy');
|
||||
} else {
|
||||
try {
|
||||
// Not more than 1 API call per 250ms and not more than 100 attempts per 30min
|
||||
// NOTE: 1 Sign-in require 2 API calls
|
||||
|
|
@ -98,6 +101,7 @@ export class SigninWithPasskeyApiService {
|
|||
},
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
// Initiate Passkey Auth challenge with context
|
||||
if (!credential) {
|
||||
|
|
|
|||
|
|
@ -4,7 +4,6 @@
|
|||
*/
|
||||
|
||||
import * as os from 'node:os';
|
||||
import si from 'systeminformation';
|
||||
import { Inject, Injectable } from '@nestjs/common';
|
||||
import { DataSource } from 'typeorm';
|
||||
import * as Redis from 'ioredis';
|
||||
|
|
@ -112,6 +111,8 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
|
||||
) {
|
||||
super(meta, paramDef, async () => {
|
||||
const si = await import('systeminformation');
|
||||
|
||||
const memStats = await si.mem();
|
||||
const fsStats = await si.fsSize();
|
||||
const netInterface = await si.networkInterfaceDefault();
|
||||
|
|
|
|||
|
|
@ -4,7 +4,6 @@
|
|||
*/
|
||||
|
||||
import * as os from 'node:os';
|
||||
import si from 'systeminformation';
|
||||
import { Inject, Injectable } from '@nestjs/common';
|
||||
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||
import { MiMeta } from '@/models/_.js';
|
||||
|
|
@ -93,6 +92,8 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
},
|
||||
};
|
||||
|
||||
const si = await import('systeminformation');
|
||||
|
||||
const memStats = await si.mem();
|
||||
const fsStats = await si.fsSize();
|
||||
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ services:
|
|||
volumes:
|
||||
- type: bind
|
||||
source: ./volumes/db.a
|
||||
target: /var/lib/postgresql/data
|
||||
target: /var/lib/postgresql
|
||||
bind:
|
||||
create_host_path: true
|
||||
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ services:
|
|||
volumes:
|
||||
- type: bind
|
||||
source: ./volumes/db.b
|
||||
target: /var/lib/postgresql/data
|
||||
target: /var/lib/postgresql
|
||||
bind:
|
||||
create_host_path: true
|
||||
|
||||
|
|
|
|||
|
|
@ -168,7 +168,36 @@ describe('export-clips', () => {
|
|||
assert.strictEqual(exported[1].clipNotes[0].note.text, 'baz2');
|
||||
});
|
||||
|
||||
test('Clipping other user\'s note', async () => {
|
||||
test('Clipping other user\'s note (followers only notes are excluded when not following)', async () => {
|
||||
const res = await api('clips/create', {
|
||||
name: 'kawaii',
|
||||
description: 'kawaii',
|
||||
}, alice);
|
||||
assert.strictEqual(res.status, 200);
|
||||
const clip = res.body;
|
||||
|
||||
const note = await post(bob, {
|
||||
text: 'baz',
|
||||
visibility: 'followers',
|
||||
});
|
||||
|
||||
const res2 = await api('clips/add-note', {
|
||||
clipId: clip.id,
|
||||
noteId: note.id,
|
||||
}, alice);
|
||||
assert.strictEqual(res2.status, 204);
|
||||
|
||||
const res3 = await api('i/export-clips', {}, alice);
|
||||
assert.strictEqual(res3.status, 204);
|
||||
|
||||
const exported = await pollFirstDriveFile();
|
||||
assert.strictEqual(exported[0].clipNotes.length, 0);
|
||||
});
|
||||
|
||||
test('Clipping other user\'s note (followers only notes are included when following)', async () => {
|
||||
// Alice follows Bob
|
||||
await api('following/create', { userId: bob.id }, alice);
|
||||
|
||||
const res = await api('clips/create', {
|
||||
name: 'kawaii',
|
||||
description: 'kawaii',
|
||||
|
|
|
|||
|
|
@ -0,0 +1,136 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: syuilo and misskey-project
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import { describe, expect, test, beforeEach, afterEach } from '@jest/globals';
|
||||
import * as lolex from '@sinonjs/fake-timers';
|
||||
import { shouldHideNoteByTime } from '@/misc/should-hide-note-by-time.js';
|
||||
|
||||
describe('misc:should-hide-note-by-time', () => {
|
||||
let clock: lolex.InstalledClock;
|
||||
const epoch = Date.UTC(2000, 0, 1, 0, 0, 0);
|
||||
|
||||
beforeEach(() => {
|
||||
clock = lolex.install({
|
||||
// https://github.com/sinonjs/sinon/issues/2620
|
||||
toFake: Object.keys(lolex.timers).filter((key) => !['nextTick', 'queueMicrotask'].includes(key)) as lolex.FakeMethod[],
|
||||
now: new Date(epoch),
|
||||
shouldClearNativeTimers: true,
|
||||
});
|
||||
});
|
||||
|
||||
afterEach(() => {
|
||||
clock.uninstall();
|
||||
});
|
||||
|
||||
describe('hiddenBefore が null または undefined の場合', () => {
|
||||
test('hiddenBefore が null のときは false を返す(非表示機能が有効でない)', () => {
|
||||
const createdAt = new Date(epoch - 86400000); // 1 day ago
|
||||
expect(shouldHideNoteByTime(null, createdAt)).toBe(false);
|
||||
});
|
||||
|
||||
test('hiddenBefore が undefined のときは false を返す(非表示機能が有効でない)', () => {
|
||||
const createdAt = new Date(epoch - 86400000); // 1 day ago
|
||||
expect(shouldHideNoteByTime(undefined, createdAt)).toBe(false);
|
||||
});
|
||||
});
|
||||
|
||||
describe('相対時間モード (hiddenBefore <= 0)', () => {
|
||||
test('閾値内に作成されたノートは false を返す(作成からの経過時間がまだ短い→表示)', () => {
|
||||
const hiddenBefore = -86400; // 1 day in seconds
|
||||
const createdAt = new Date(epoch - 3600000); // 1 hour ago
|
||||
expect(shouldHideNoteByTime(hiddenBefore, createdAt)).toBe(false);
|
||||
});
|
||||
|
||||
test('閾値を超えて作成されたノートは true を返す(指定期間以上経過している→非表示)', () => {
|
||||
const hiddenBefore = -86400; // 1 day in seconds
|
||||
const createdAt = new Date(epoch - 172800000); // 2 days ago
|
||||
expect(shouldHideNoteByTime(hiddenBefore, createdAt)).toBe(true);
|
||||
});
|
||||
|
||||
test('ちょうど閾値で作成されたノートは true を返す(閾値に達したら非表示)', () => {
|
||||
const hiddenBefore = -86400; // 1 day in seconds
|
||||
const createdAt = new Date(epoch - 86400000); // exactly 1 day ago
|
||||
expect(shouldHideNoteByTime(hiddenBefore, createdAt)).toBe(true);
|
||||
});
|
||||
|
||||
test('異なる相対時間値で判定できる(1時間設定と3時間設定の異なる結果)', () => {
|
||||
const createdAt = new Date(epoch - 7200000); // 2 hours ago
|
||||
expect(shouldHideNoteByTime(-3600, createdAt)).toBe(true); // 1時間経過→非表示
|
||||
expect(shouldHideNoteByTime(-10800, createdAt)).toBe(false); // 3時間未経過→表示
|
||||
});
|
||||
|
||||
test('ISO 8601 形式の文字列の createdAt に対応できる(文字列でも正しく判定)', () => {
|
||||
const createdAtString = new Date(epoch - 86400000).toISOString();
|
||||
const hiddenBefore = -86400; // 1 day in seconds
|
||||
expect(shouldHideNoteByTime(hiddenBefore, createdAtString)).toBe(true);
|
||||
});
|
||||
|
||||
test('hiddenBefore が 0 の場合に対応できる(0秒以上経過で非表示→ほぼ全て非表示)', () => {
|
||||
const hiddenBefore = 0;
|
||||
const createdAt = new Date(epoch - 1); // 1ms ago
|
||||
expect(shouldHideNoteByTime(hiddenBefore, createdAt)).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
describe('絶対時間モード (hiddenBefore > 0)', () => {
|
||||
test('閾値タイムスタンプより後に作成されたノートは false を返す(指定日時より後→表示)', () => {
|
||||
const thresholdSeconds = Math.floor(epoch / 1000);
|
||||
const createdAt = new Date(epoch + 3600000); // 1 hour from epoch
|
||||
expect(shouldHideNoteByTime(thresholdSeconds, createdAt)).toBe(false);
|
||||
});
|
||||
|
||||
test('閾値タイムスタンプより前に作成されたノートは true を返す(指定日時より前→非表示)', () => {
|
||||
const thresholdSeconds = Math.floor(epoch / 1000);
|
||||
const createdAt = new Date(epoch - 3600000); // 1 hour ago
|
||||
expect(shouldHideNoteByTime(thresholdSeconds, createdAt)).toBe(true);
|
||||
});
|
||||
|
||||
test('ちょうど閾値タイムスタンプで作成されたノートは true を返す(指定日時に達したら非表示)', () => {
|
||||
const thresholdSeconds = Math.floor(epoch / 1000);
|
||||
const createdAt = new Date(epoch); // exactly epoch
|
||||
expect(shouldHideNoteByTime(thresholdSeconds, createdAt)).toBe(true);
|
||||
});
|
||||
|
||||
test('ISO 8601 形式の文字列の createdAt に対応できる(文字列でも正しく判定)', () => {
|
||||
const thresholdSeconds = Math.floor(epoch / 1000);
|
||||
const createdAtString = new Date(epoch - 3600000).toISOString();
|
||||
expect(shouldHideNoteByTime(thresholdSeconds, createdAtString)).toBe(true);
|
||||
});
|
||||
|
||||
test('異なる閾値タイムスタンプで判定できる(2021年設定と現在より1時間前設定の異なる結果)', () => {
|
||||
const thresholdSeconds = Math.floor((epoch - 86400000) / 1000); // 1 day ago
|
||||
const createdAtBefore = new Date(epoch - 172800000); // 2 days ago
|
||||
const createdAtAfter = new Date(epoch - 3600000); // 1 hour ago
|
||||
expect(shouldHideNoteByTime(thresholdSeconds, createdAtBefore)).toBe(true); // 閾値より前→非表示
|
||||
expect(shouldHideNoteByTime(thresholdSeconds, createdAtAfter)).toBe(false); // 閾値より後→表示
|
||||
});
|
||||
});
|
||||
|
||||
describe('エッジケース', () => {
|
||||
test('相対時間モードで非常に古いノートに対応できる(非常に古い→閾値超→非表示)', () => {
|
||||
const hiddenBefore = -1; // hide notes older than 1 second
|
||||
const createdAt = new Date(epoch - 1000000); // very old
|
||||
expect(shouldHideNoteByTime(hiddenBefore, createdAt)).toBe(true);
|
||||
});
|
||||
|
||||
test('相対時間モードで非常に新しいノートに対応できる(非常に新しい→閾値未満→表示)', () => {
|
||||
const hiddenBefore = -86400; // 1 day
|
||||
const createdAt = new Date(epoch - 1); // 1ms ago
|
||||
expect(shouldHideNoteByTime(hiddenBefore, createdAt)).toBe(false);
|
||||
});
|
||||
|
||||
test('大きなタイムスタンプ値に対応できる(未来の日時を指定→現在のノートは全て非表示)', () => {
|
||||
const thresholdSeconds = Math.floor(epoch / 1000) + 86400; // 1 day from epoch
|
||||
const createdAt = new Date(epoch); // created epoch
|
||||
expect(shouldHideNoteByTime(thresholdSeconds, createdAt)).toBe(true);
|
||||
});
|
||||
|
||||
test('小さな相対時間値に対応できる(1秒設定で2秒前→非表示)', () => {
|
||||
const hiddenBefore = -1; // 1 second
|
||||
const createdAt = new Date(epoch - 2000); // 2 seconds ago
|
||||
expect(shouldHideNoteByTime(hiddenBefore, createdAt)).toBe(true);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
@ -11,9 +11,9 @@
|
|||
},
|
||||
"devDependencies": {
|
||||
"@types/estree": "1.0.8",
|
||||
"@types/node": "24.10.1",
|
||||
"@typescript-eslint/eslint-plugin": "8.47.0",
|
||||
"@typescript-eslint/parser": "8.47.0",
|
||||
"@types/node": "24.10.2",
|
||||
"@typescript-eslint/eslint-plugin": "8.49.0",
|
||||
"@typescript-eslint/parser": "8.49.0",
|
||||
"rollup": "4.53.3",
|
||||
"typescript": "5.9.3"
|
||||
},
|
||||
|
|
@ -21,6 +21,6 @@
|
|||
"i18n": "workspace:*",
|
||||
"estree-walker": "3.0.3",
|
||||
"magic-string": "0.30.21",
|
||||
"vite": "7.2.4"
|
||||
"vite": "7.2.7"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,8 +17,6 @@
|
|||
"@rollup/pluginutils": "5.3.0",
|
||||
"@twemoji/parser": "16.0.0",
|
||||
"@vitejs/plugin-vue": "6.0.2",
|
||||
"@vue/compiler-sfc": "3.5.24",
|
||||
"astring": "1.9.0",
|
||||
"buraha": "0.0.1",
|
||||
"estree-walker": "3.0.3",
|
||||
"frontend-shared": "workspace:*",
|
||||
|
|
@ -28,15 +26,12 @@
|
|||
"misskey-js": "workspace:*",
|
||||
"punycode.js": "2.3.1",
|
||||
"rollup": "4.53.3",
|
||||
"sass": "1.94.2",
|
||||
"shiki": "3.15.0",
|
||||
"sass": "1.95.1",
|
||||
"shiki": "3.19.0",
|
||||
"tinycolor2": "1.6.0",
|
||||
"tsc-alias": "1.8.16",
|
||||
"tsconfig-paths": "4.2.0",
|
||||
"typescript": "5.9.3",
|
||||
"uuid": "13.0.0",
|
||||
"vite": "7.2.4",
|
||||
"vue": "3.5.24"
|
||||
"vite": "7.2.7",
|
||||
"vue": "3.5.25"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@misskey-dev/summaly": "5.2.5",
|
||||
|
|
@ -44,30 +39,30 @@
|
|||
"@testing-library/vue": "8.1.0",
|
||||
"@types/estree": "1.0.8",
|
||||
"@types/micromatch": "4.0.10",
|
||||
"@types/node": "24.10.1",
|
||||
"@types/node": "24.10.2",
|
||||
"@types/punycode.js": "npm:@types/punycode@2.1.4",
|
||||
"@types/tinycolor2": "1.4.6",
|
||||
"@types/ws": "8.18.1",
|
||||
"@typescript-eslint/eslint-plugin": "8.47.0",
|
||||
"@typescript-eslint/parser": "8.47.0",
|
||||
"@vitest/coverage-v8": "4.0.13",
|
||||
"@vue/runtime-core": "3.5.24",
|
||||
"@typescript-eslint/eslint-plugin": "8.49.0",
|
||||
"@typescript-eslint/parser": "8.49.0",
|
||||
"@vitest/coverage-v8": "4.0.15",
|
||||
"@vue/runtime-core": "3.5.25",
|
||||
"acorn": "8.15.0",
|
||||
"cross-env": "10.1.0",
|
||||
"eslint-plugin-import": "2.32.0",
|
||||
"eslint-plugin-vue": "10.6.0",
|
||||
"fast-glob": "3.3.3",
|
||||
"happy-dom": "20.0.10",
|
||||
"eslint-plugin-vue": "10.6.2",
|
||||
"happy-dom": "20.0.11",
|
||||
"intersection-observer": "0.12.2",
|
||||
"micromatch": "4.0.8",
|
||||
"msw": "2.12.2",
|
||||
"msw": "2.12.4",
|
||||
"nodemon": "3.1.11",
|
||||
"prettier": "3.6.2",
|
||||
"prettier": "3.7.4",
|
||||
"start-server-and-test": "2.1.3",
|
||||
"tsx": "4.20.6",
|
||||
"tsx": "4.21.0",
|
||||
"typescript": "5.9.3",
|
||||
"vite-plugin-turbosnap": "1.0.3",
|
||||
"vue-component-type-helpers": "3.1.5",
|
||||
"vue-component-type-helpers": "3.1.8",
|
||||
"vue-eslint-parser": "10.2.0",
|
||||
"vue-tsc": "3.1.5"
|
||||
"vue-tsc": "3.1.8"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -70,6 +70,8 @@
|
|||
importAppScript();
|
||||
});
|
||||
}
|
||||
|
||||
localStorage.setItem('lang', lang);
|
||||
//#endregion
|
||||
|
||||
async function addStyle(styleText) {
|
||||
|
|
|
|||
|
|
@ -3,14 +3,13 @@ import { fileURLToPath } from 'node:url';
|
|||
import { dirname } from 'node:path';
|
||||
import * as esbuild from 'esbuild';
|
||||
import { build } from 'esbuild';
|
||||
import { globSync } from 'glob';
|
||||
import { execa } from 'execa';
|
||||
|
||||
const _filename = fileURLToPath(import.meta.url);
|
||||
const _dirname = dirname(_filename);
|
||||
const _package = JSON.parse(fs.readFileSync(_dirname + '/package.json', 'utf-8'));
|
||||
|
||||
const entryPoints = globSync('./js/**/**.{ts,tsx}');
|
||||
const entryPoints = fs.globSync('./js/**/**.{ts,tsx}');
|
||||
|
||||
/** @type {import('esbuild').BuildOptions} */
|
||||
const options = {
|
||||
|
|
|
|||
|
|
@ -21,11 +21,11 @@
|
|||
"lint": "pnpm typecheck && pnpm eslint"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/node": "24.10.1",
|
||||
"@typescript-eslint/eslint-plugin": "8.47.0",
|
||||
"@typescript-eslint/parser": "8.47.0",
|
||||
"esbuild": "0.27.0",
|
||||
"eslint-plugin-vue": "10.6.0",
|
||||
"@types/node": "24.10.2",
|
||||
"@typescript-eslint/eslint-plugin": "8.49.0",
|
||||
"@typescript-eslint/parser": "8.49.0",
|
||||
"esbuild": "0.27.1",
|
||||
"eslint-plugin-vue": "10.6.2",
|
||||
"nodemon": "3.1.11",
|
||||
"typescript": "5.9.3",
|
||||
"vue-eslint-parser": "10.2.0"
|
||||
|
|
@ -36,6 +36,6 @@
|
|||
"dependencies": {
|
||||
"i18n": "workspace:*",
|
||||
"misskey-js": "workspace:*",
|
||||
"vue": "3.5.24"
|
||||
"vue": "3.5.25"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,12 +3,11 @@
|
|||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import { existsSync, readFileSync } from 'node:fs';
|
||||
import { existsSync, readFileSync, globSync } from 'node:fs';
|
||||
import { writeFile } from 'node:fs/promises';
|
||||
import { basename, dirname } from 'node:path/posix';
|
||||
import { GENERATOR, type State, generate } from 'astring';
|
||||
import type * as estree from 'estree';
|
||||
import glob from 'fast-glob';
|
||||
import { format } from 'prettier';
|
||||
|
||||
interface SatisfiesExpression extends estree.BaseExpression {
|
||||
|
|
@ -439,38 +438,37 @@ function toStories(component: string): Promise<string> {
|
|||
|
||||
// glob('src/{components,pages,ui,widgets}/**/*.vue')
|
||||
(async () => {
|
||||
const globs = await Promise.all([
|
||||
glob('src/components/global/Mk*.vue'),
|
||||
glob('src/components/global/RouterView.vue'),
|
||||
glob('src/components/MkAbuseReportWindow.vue'),
|
||||
glob('src/components/MkAccountMoved.vue'),
|
||||
glob('src/components/MkAchievements.vue'),
|
||||
glob('src/components/MkAnalogClock.vue'),
|
||||
glob('src/components/MkAnimBg.vue'),
|
||||
glob('src/components/MkAnnouncementDialog.vue'),
|
||||
glob('src/components/MkAntennaEditor.vue'),
|
||||
glob('src/components/MkAntennaEditorDialog.vue'),
|
||||
glob('src/components/MkAsUi.vue'),
|
||||
glob('src/components/MkAutocomplete.vue'),
|
||||
glob('src/components/MkAvatars.vue'),
|
||||
glob('src/components/Mk[B-E]*.vue'),
|
||||
glob('src/components/MkFlashPreview.vue'),
|
||||
glob('src/components/MkGalleryPostPreview.vue'),
|
||||
glob('src/components/MkSignupServerRules.vue'),
|
||||
glob('src/components/MkUserSetupDialog.vue'),
|
||||
glob('src/components/MkUserSetupDialog.*.vue'),
|
||||
glob('src/components/MkImgPreviewDialog.vue'),
|
||||
glob('src/components/MkInstanceCardMini.vue'),
|
||||
glob('src/components/MkInviteCode.vue'),
|
||||
glob('src/components/MkTagItem.vue'),
|
||||
glob('src/components/MkRoleSelectDialog.vue'),
|
||||
glob('src/components/grid/MkGrid.vue'),
|
||||
glob('src/pages/admin/custom-emojis-manager2.vue'),
|
||||
glob('src/pages/admin/overview.ap-requests.vue'),
|
||||
glob('src/pages/user/home.vue'),
|
||||
glob('src/pages/search.vue'),
|
||||
]);
|
||||
const components = globs.flat();
|
||||
const components = [
|
||||
globSync('src/components/global/Mk*.vue'),
|
||||
globSync('src/components/global/RouterView.vue'),
|
||||
globSync('src/components/MkAbuseReportWindow.vue'),
|
||||
globSync('src/components/MkAccountMoved.vue'),
|
||||
globSync('src/components/MkAchievements.vue'),
|
||||
globSync('src/components/MkAnalogClock.vue'),
|
||||
globSync('src/components/MkAnimBg.vue'),
|
||||
globSync('src/components/MkAnnouncementDialog.vue'),
|
||||
globSync('src/components/MkAntennaEditor.vue'),
|
||||
globSync('src/components/MkAntennaEditorDialog.vue'),
|
||||
globSync('src/components/MkAsUi.vue'),
|
||||
globSync('src/components/MkAutocomplete.vue'),
|
||||
globSync('src/components/MkAvatars.vue'),
|
||||
globSync('src/components/Mk[B-E]*.vue'),
|
||||
globSync('src/components/MkFlashPreview.vue'),
|
||||
globSync('src/components/MkGalleryPostPreview.vue'),
|
||||
globSync('src/components/MkSignupServerRules.vue'),
|
||||
globSync('src/components/MkUserSetupDialog.vue'),
|
||||
globSync('src/components/MkUserSetupDialog.*.vue'),
|
||||
globSync('src/components/MkImgPreviewDialog.vue'),
|
||||
globSync('src/components/MkInstanceCardMini.vue'),
|
||||
globSync('src/components/MkInviteCode.vue'),
|
||||
globSync('src/components/MkTagItem.vue'),
|
||||
globSync('src/components/MkRoleSelectDialog.vue'),
|
||||
globSync('src/components/grid/MkGrid.vue'),
|
||||
globSync('src/pages/admin/custom-emojis-manager2.vue'),
|
||||
globSync('src/pages/admin/overview.ap-requests.vue'),
|
||||
globSync('src/pages/user/home.vue'),
|
||||
globSync('src/pages/search.vue'),
|
||||
].flat();
|
||||
await Promise.all(components.map(async (component) => {
|
||||
const stories = component.replace(/\.vue$/, '.stories.ts');
|
||||
await writeFile(stories, await toStories(component));
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@ import {
|
|||
type PluginOption
|
||||
} from 'vite';
|
||||
import fs from 'node:fs';
|
||||
import { glob } from 'glob';
|
||||
import JSON5 from 'json5';
|
||||
import MagicString, { SourceMap } from 'magic-string';
|
||||
import path from 'node:path'
|
||||
|
|
@ -724,7 +723,7 @@ export function pluginCreateSearchIndexVirtualModule(options: Options, asigner:
|
|||
|
||||
async load(id) {
|
||||
if (id == '\0' + allSearchIndexFile) {
|
||||
const files = await Promise.all(options.targetFilePaths.map(async (filePathPattern) => await glob(filePathPattern))).then(paths => paths.flat());
|
||||
const files = options.targetFilePaths.map((filePathPattern) => fs.globSync(filePathPattern)).flat();
|
||||
let generatedFile = '';
|
||||
let arrayElements = '';
|
||||
for (let file of files) {
|
||||
|
|
|
|||
|
|
@ -19,21 +19,19 @@
|
|||
"@analytics/google-analytics": "1.1.0",
|
||||
"@discordapp/twemoji": "16.0.1",
|
||||
"@github/webauthn-json": "2.1.1",
|
||||
"@mcaptcha/vanilla-glue": "0.1.0-alpha-3",
|
||||
"@mcaptcha/vanilla-glue": "0.1.0-rc2",
|
||||
"i18n": "workspace:*",
|
||||
"@misskey-dev/browser-image-resizer": "2024.1.0",
|
||||
"@rollup/plugin-json": "6.1.0",
|
||||
"@rollup/plugin-replace": "6.0.3",
|
||||
"@rollup/pluginutils": "5.3.0",
|
||||
"@sentry/vue": "10.26.0",
|
||||
"@sentry/vue": "10.29.0",
|
||||
"@syuilo/aiscript": "1.2.0",
|
||||
"@syuilo/aiscript-0-19-0": "npm:@syuilo/aiscript@^0.19.0",
|
||||
"@twemoji/parser": "16.0.0",
|
||||
"@vitejs/plugin-vue": "6.0.2",
|
||||
"@vue/compiler-sfc": "3.5.24",
|
||||
"aiscript-vscode": "github:aiscript-dev/aiscript-vscode#v0.1.15",
|
||||
"aiscript-vscode": "github:aiscript-dev/aiscript-vscode#v0.1.16",
|
||||
"analytics": "0.8.19",
|
||||
"astring": "1.9.0",
|
||||
"broadcast-channel": "7.2.0",
|
||||
"buraha": "0.0.1",
|
||||
"canvas-confetti": "1.9.4",
|
||||
|
|
@ -46,10 +44,9 @@
|
|||
"compare-versions": "6.1.1",
|
||||
"cropperjs": "2.1.0",
|
||||
"date-fns": "4.1.0",
|
||||
"estree-walker": "3.0.3",
|
||||
"eventemitter3": "5.0.1",
|
||||
"execa": "9.6.0",
|
||||
"exifreader": "4.32.0",
|
||||
"execa": "9.6.1",
|
||||
"exifreader": "4.33.1",
|
||||
"frontend-shared": "workspace:*",
|
||||
"icons-subsetter": "workspace:*",
|
||||
"idb-keyval": "6.2.2",
|
||||
|
|
@ -57,9 +54,8 @@
|
|||
"ios-haptics": "0.1.4",
|
||||
"is-file-animated": "1.0.2",
|
||||
"json5": "2.2.3",
|
||||
"magic-string": "0.30.21",
|
||||
"matter-js": "0.20.0",
|
||||
"mediabunny": "1.25.1",
|
||||
"mediabunny": "1.25.8",
|
||||
"mfm-js": "0.25.0",
|
||||
"misskey-bubble-game": "workspace:*",
|
||||
"misskey-js": "workspace:*",
|
||||
|
|
@ -70,19 +66,15 @@
|
|||
"qr-scanner": "1.4.2",
|
||||
"rollup": "4.53.3",
|
||||
"sanitize-html": "2.17.0",
|
||||
"sass": "1.94.2",
|
||||
"shiki": "3.15.0",
|
||||
"strict-event-emitter-types": "2.0.0",
|
||||
"sass": "1.95.1",
|
||||
"shiki": "3.19.0",
|
||||
"textarea-caret": "3.1.0",
|
||||
"three": "0.181.2",
|
||||
"throttle-debounce": "5.0.2",
|
||||
"tinycolor2": "1.6.0",
|
||||
"tsc-alias": "1.8.16",
|
||||
"tsconfig-paths": "4.2.0",
|
||||
"typescript": "5.9.3",
|
||||
"v-code-diff": "1.13.1",
|
||||
"vite": "7.2.4",
|
||||
"vue": "3.5.24",
|
||||
"vite": "7.2.7",
|
||||
"vue": "3.5.25",
|
||||
"vuedraggable": "next",
|
||||
"wanakana": "5.3.1"
|
||||
},
|
||||
|
|
@ -90,7 +82,7 @@
|
|||
"@misskey-dev/summaly": "5.2.5",
|
||||
"@storybook/addon-essentials": "8.6.14",
|
||||
"@storybook/addon-interactions": "8.6.14",
|
||||
"@storybook/addon-links": "10.0.8",
|
||||
"@storybook/addon-links": "10.1.5",
|
||||
"@storybook/addon-mdx-gfm": "8.6.14",
|
||||
"@storybook/addon-storysource": "8.6.14",
|
||||
"@storybook/blocks": "8.6.14",
|
||||
|
|
@ -98,58 +90,59 @@
|
|||
"@storybook/core-events": "8.6.14",
|
||||
"@storybook/manager-api": "8.6.14",
|
||||
"@storybook/preview-api": "8.6.14",
|
||||
"@storybook/react": "10.0.8",
|
||||
"@storybook/react-vite": "10.0.8",
|
||||
"@storybook/react": "10.1.5",
|
||||
"@storybook/react-vite": "10.1.5",
|
||||
"@storybook/test": "8.6.14",
|
||||
"@storybook/theming": "8.6.14",
|
||||
"@storybook/types": "8.6.14",
|
||||
"@storybook/vue3": "10.0.8",
|
||||
"@storybook/vue3-vite": "10.0.8",
|
||||
"@storybook/vue3": "10.1.5",
|
||||
"@storybook/vue3-vite": "10.1.5",
|
||||
"@tabler/icons-webfont": "3.35.0",
|
||||
"@testing-library/vue": "8.1.0",
|
||||
"@types/canvas-confetti": "1.9.0",
|
||||
"@types/estree": "1.0.8",
|
||||
"@types/matter-js": "0.20.2",
|
||||
"@types/micromatch": "4.0.10",
|
||||
"@types/node": "24.10.1",
|
||||
"@types/node": "24.10.2",
|
||||
"@types/punycode.js": "npm:@types/punycode@2.1.4",
|
||||
"@types/sanitize-html": "2.16.0",
|
||||
"@types/seedrandom": "3.0.8",
|
||||
"@types/throttle-debounce": "5.0.2",
|
||||
"@types/tinycolor2": "1.4.6",
|
||||
"@types/ws": "8.18.1",
|
||||
"@typescript-eslint/eslint-plugin": "8.47.0",
|
||||
"@typescript-eslint/parser": "8.47.0",
|
||||
"@vitest/coverage-v8": "4.0.13",
|
||||
"@vue/compiler-core": "3.5.24",
|
||||
"@vue/runtime-core": "3.5.24",
|
||||
"@typescript-eslint/eslint-plugin": "8.49.0",
|
||||
"@typescript-eslint/parser": "8.49.0",
|
||||
"@vitest/coverage-v8": "4.0.15",
|
||||
"@vue/compiler-core": "3.5.25",
|
||||
"acorn": "8.15.0",
|
||||
"astring": "1.9.0",
|
||||
"cross-env": "10.1.0",
|
||||
"cypress": "15.7.0",
|
||||
"cypress": "15.7.1",
|
||||
"eslint-plugin-import": "2.32.0",
|
||||
"eslint-plugin-vue": "10.6.0",
|
||||
"fast-glob": "3.3.3",
|
||||
"happy-dom": "20.0.10",
|
||||
"eslint-plugin-vue": "10.6.2",
|
||||
"estree-walker": "3.0.3",
|
||||
"happy-dom": "20.0.11",
|
||||
"intersection-observer": "0.12.2",
|
||||
"magic-string": "0.30.21",
|
||||
"micromatch": "4.0.8",
|
||||
"minimatch": "10.1.1",
|
||||
"msw": "2.12.2",
|
||||
"msw": "2.12.4",
|
||||
"msw-storybook-addon": "2.0.6",
|
||||
"nodemon": "3.1.11",
|
||||
"prettier": "3.6.2",
|
||||
"react": "19.2.0",
|
||||
"react-dom": "19.2.0",
|
||||
"prettier": "3.7.4",
|
||||
"react": "19.2.1",
|
||||
"react-dom": "19.2.1",
|
||||
"seedrandom": "3.0.5",
|
||||
"start-server-and-test": "2.1.3",
|
||||
"storybook": "10.0.8",
|
||||
"storybook": "10.1.5",
|
||||
"storybook-addon-misskey-theme": "github:misskey-dev/storybook-addon-misskey-theme",
|
||||
"tsx": "4.20.6",
|
||||
"vite-plugin-glsl": "1.5.4",
|
||||
"tsx": "4.21.0",
|
||||
"typescript": "5.9.3",
|
||||
"vite-plugin-glsl": "1.5.5",
|
||||
"vite-plugin-turbosnap": "1.0.3",
|
||||
"vitest": "4.0.13",
|
||||
"vitest": "4.0.15",
|
||||
"vitest-fetch-mock": "0.4.5",
|
||||
"vue-component-type-helpers": "3.1.5",
|
||||
"vue-component-type-helpers": "3.1.8",
|
||||
"vue-eslint-parser": "10.2.0",
|
||||
"vue-tsc": "3.1.5"
|
||||
"vue-tsc": "3.1.8"
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -42,6 +42,8 @@
|
|||
console.error('invalid lang value detected!!!', typeof lang, lang);
|
||||
lang = 'en-US';
|
||||
}
|
||||
|
||||
localStorage.setItem('lang', lang);
|
||||
//#endregion
|
||||
|
||||
//#region Script
|
||||
|
|
|
|||
|
|
@ -83,6 +83,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
</div>
|
||||
<MkButton v-if="foldersPaginator.canFetchOlder.value" primary rounded @click="foldersPaginator.fetchOlder()">{{ i18n.ts.loadMore }}</MkButton>
|
||||
|
||||
<template v-if="shouldBeGroupedByDate">
|
||||
<MkStickyContainer v-for="(item, i) in filesTimeline" :key="`${item.date.getFullYear()}/${item.date.getMonth() + 1}`">
|
||||
<template #header>
|
||||
<div :class="$style.date">
|
||||
|
|
@ -111,6 +112,29 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
/>
|
||||
</TransitionGroup>
|
||||
</MkStickyContainer>
|
||||
</template>
|
||||
<TransitionGroup
|
||||
v-else
|
||||
tag="div"
|
||||
:enterActiveClass="prefer.s.animation ? $style.transition_files_enterActive : ''"
|
||||
:leaveActiveClass="prefer.s.animation ? $style.transition_files_leaveActive : ''"
|
||||
:enterFromClass="prefer.s.animation ? $style.transition_files_enterFrom : ''"
|
||||
:leaveToClass="prefer.s.animation ? $style.transition_files_leaveTo : ''"
|
||||
:moveClass="prefer.s.animation ? $style.transition_files_move : ''"
|
||||
:class="$style.files"
|
||||
>
|
||||
<XFile
|
||||
v-for="file in filesPaginator.items.value" :key="file.id"
|
||||
:class="$style.file"
|
||||
:file="file"
|
||||
:folder="folder"
|
||||
:isSelected="selectedFiles.some(x => x.id === file.id)"
|
||||
@click="onFileClick($event, file)"
|
||||
@dragstart="onFileDragstart(file, $event)"
|
||||
@dragend="isDragSource = false"
|
||||
/>
|
||||
</TransitionGroup>
|
||||
|
||||
<MkButton v-show="filesPaginator.canFetchOlder.value" :class="$style.loadMore" primary rounded @click="filesPaginator.fetchOlder()">{{ i18n.ts.loadMore }}</MkButton>
|
||||
|
||||
<div v-if="filesPaginator.items.value.length == 0 && foldersPaginator.items.value.length == 0 && !fetching" :class="$style.empty">
|
||||
|
|
@ -217,6 +241,7 @@ const foldersPaginator = markRaw(new Paginator('drive/folders', {
|
|||
}));
|
||||
|
||||
const filesTimeline = makeDateGroupedTimelineComputedRef(filesPaginator.items, 'month');
|
||||
const shouldBeGroupedByDate = computed(() => ['+createdAt', '-createdAt'].includes(sortModeSelect.value));
|
||||
|
||||
watch(folder, () => emit('cd', folder.value));
|
||||
watch(sortModeSelect, () => {
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
</MkModalWindow>
|
||||
</template>
|
||||
<script lang="ts" setup>
|
||||
import { defineProps, ref } from 'vue';
|
||||
import { ref } from 'vue';
|
||||
import MkModalWindow from './MkModalWindow.vue';
|
||||
import type * as Misskey from 'misskey-js';
|
||||
|
||||
|
|
|
|||
|
|
@ -233,16 +233,18 @@ function showMenu(ev: MouseEvent) {
|
|||
.hide {
|
||||
display: block;
|
||||
position: absolute;
|
||||
border-radius: 6px;
|
||||
background-color: var(--MI_THEME-fg);
|
||||
color: hsl(from var(--MI_THEME-accent) h s calc(l + 10));
|
||||
background-color: rgba(0, 0, 0, 0.3);
|
||||
-webkit-backdrop-filter: var(--MI-blur, blur(15px));
|
||||
backdrop-filter: var(--MI-blur, blur(15px));
|
||||
border-radius: 0 0 0 9px;
|
||||
color: #fff;
|
||||
font-size: 12px;
|
||||
opacity: .5;
|
||||
padding: 5px 8px;
|
||||
text-align: center;
|
||||
cursor: pointer;
|
||||
top: 12px;
|
||||
right: 12px;
|
||||
top: 0;
|
||||
right: 0;
|
||||
}
|
||||
|
||||
.hiddenTextWrapper {
|
||||
|
|
@ -272,17 +274,17 @@ html[data-color-scheme=light] .visible {
|
|||
.menu {
|
||||
display: block;
|
||||
position: absolute;
|
||||
border-radius: 999px;
|
||||
background-color: rgba(0, 0, 0, 0.3);
|
||||
-webkit-backdrop-filter: var(--MI-blur, blur(15px));
|
||||
backdrop-filter: var(--MI-blur, blur(15px));
|
||||
border-radius: 9px 0 0 0;
|
||||
color: #fff;
|
||||
font-size: 0.8em;
|
||||
width: 28px;
|
||||
height: 28px;
|
||||
text-align: center;
|
||||
bottom: 10px;
|
||||
right: 10px;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
}
|
||||
|
||||
.imageContainer {
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
|
||||
<template>
|
||||
<div
|
||||
v-if="!hardMuted && muted === false"
|
||||
v-if="!hardMuted && !hideByPlugin && muted === false"
|
||||
ref="rootEl"
|
||||
v-hotkey="keymap"
|
||||
:class="[$style.root, { [$style.showActionsOnlyHover]: prefer.s.showNoteActionsOnlyHover, [$style.skipRender]: prefer.s.skipNoteRender }]"
|
||||
|
|
@ -38,7 +38,10 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<span v-if="note.channel" style="margin-left: 0.5em;" :title="note.channel.name"><i class="ti ti-device-tv"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="renoteCollapsed" :class="$style.collapsedRenoteTarget">
|
||||
<div v-if="isRenote && note.renote == null" :class="$style.deleted">
|
||||
{{ i18n.ts.deletedNote }}
|
||||
</div>
|
||||
<div v-else-if="renoteCollapsed" :class="$style.collapsedRenoteTarget">
|
||||
<MkAvatar :class="$style.collapsedRenoteTargetAvatar" :user="appearNote.user" link preview/>
|
||||
<Mfm :text="getNoteSummary(appearNote)" :plain="true" :nowrap="true" :author="appearNote.user" :nyaize="'respect'" :class="$style.collapsedRenoteTargetText" @click="renoteCollapsed = false"/>
|
||||
</div>
|
||||
|
|
@ -158,7 +161,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
</div>
|
||||
</article>
|
||||
</div>
|
||||
<div v-else-if="!hardMuted" :class="$style.muted" @click="muted = false">
|
||||
<div v-else-if="!hardMuted && !hideByPlugin" :class="$style.muted" @click="muted = false">
|
||||
<I18n v-if="muted === 'sensitiveMute'" :src="i18n.ts.userSaysSomethingSensitive" tag="small">
|
||||
<template #name>
|
||||
<MkA v-user-preview="appearNote.userId" :to="userPage(appearNote.user)">
|
||||
|
|
@ -267,6 +270,7 @@ let note = deepClone(props.note);
|
|||
|
||||
// plugin
|
||||
const noteViewInterruptors = getPluginHandlers('note_view_interruptor');
|
||||
const hideByPlugin = ref(false);
|
||||
if (noteViewInterruptors.length > 0) {
|
||||
let result: Misskey.entities.Note | null = deepClone(note);
|
||||
for (const interruptor of noteViewInterruptors) {
|
||||
|
|
@ -276,8 +280,12 @@ if (noteViewInterruptors.length > 0) {
|
|||
console.error(err);
|
||||
}
|
||||
}
|
||||
if (result == null) {
|
||||
hideByPlugin.value = true;
|
||||
} else {
|
||||
note = result as Misskey.entities.Note;
|
||||
}
|
||||
}
|
||||
|
||||
const isRenote = Misskey.note.isPureRenote(note);
|
||||
const appearNote = getAppearNote(note) ?? note;
|
||||
|
|
@ -1144,4 +1152,14 @@ function emitUpdReaction(emoji: string, delta: number) {
|
|||
opacity: .8;
|
||||
font-size: 95%;
|
||||
}
|
||||
|
||||
.deleted {
|
||||
text-align: center;
|
||||
padding: 32px;
|
||||
margin: 6px 32px 28px;
|
||||
--color: light-dark(rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.15));
|
||||
background-size: auto auto;
|
||||
background-image: repeating-linear-gradient(135deg, transparent, transparent 10px, var(--color) 4px, var(--color) 14px);
|
||||
border-radius: 8px;
|
||||
}
|
||||
</style>
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
|
||||
<template>
|
||||
<div
|
||||
v-if="!muted && !isDeleted"
|
||||
v-if="!muted && !hideByPlugin && !isDeleted"
|
||||
ref="rootEl"
|
||||
v-hotkey="keymap"
|
||||
:class="$style.root"
|
||||
|
|
@ -43,6 +43,10 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<span v-if="note.localOnly" style="margin-left: 0.5em;" :title="i18n.ts._visibility['disableFederation']"><i class="ti ti-rocket-off"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="isRenote && note.renote == null" :class="$style.deleted">
|
||||
{{ i18n.ts.deletedNote }}
|
||||
</div>
|
||||
<template v-else>
|
||||
<article :class="$style.note" @contextmenu.stop="onContextmenu">
|
||||
<header :class="$style.noteHeader">
|
||||
<MkAvatar :class="$style.noteHeaderAvatar" :user="appearNote.user" indicator link preview/>
|
||||
|
|
@ -187,7 +191,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<MkNoteSub v-for="note in replies" :key="note.id" :note="note" :class="$style.reply" :detail="true"/>
|
||||
</div>
|
||||
<div v-else-if="tab === 'renotes'" :class="$style.tab_renotes">
|
||||
<MkPagination :paginator="renotesPaginator">
|
||||
<MkPagination :paginator="renotesPaginator" :forceDisableInfiniteScroll="true">
|
||||
<template #default="{ items }">
|
||||
<div style="display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); grid-gap: 12px;">
|
||||
<MkA v-for="item in items" :key="item.id" :to="userPage(item.user)">
|
||||
|
|
@ -204,7 +208,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<span style="margin-left: 4px;">{{ $appearNote.reactions[reaction] }}</span>
|
||||
</button>
|
||||
</div>
|
||||
<MkPagination v-if="reactionTabType" :key="reactionTabType" :paginator="reactionsPaginator">
|
||||
<MkPagination v-if="reactionTabType" :key="reactionTabType" :paginator="reactionsPaginator" :forceDisableInfiniteScroll="true">
|
||||
<template #default="{ items }">
|
||||
<div style="display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); grid-gap: 12px;">
|
||||
<MkA v-for="item in items" :key="item.id" :to="userPage(item.user)">
|
||||
|
|
@ -215,6 +219,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
</MkPagination>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
</div>
|
||||
<div v-else-if="muted" class="_panel" :class="$style.muted" @click="muted = false">
|
||||
<I18n :src="i18n.ts.userSaysSomething" tag="small">
|
||||
|
|
@ -289,6 +294,7 @@ let note = deepClone(props.note);
|
|||
|
||||
// plugin
|
||||
const noteViewInterruptors = getPluginHandlers('note_view_interruptor');
|
||||
const hideByPlugin = ref(false);
|
||||
if (noteViewInterruptors.length > 0) {
|
||||
let result: Misskey.entities.Note | null = deepClone(note);
|
||||
for (const interruptor of noteViewInterruptors) {
|
||||
|
|
@ -298,8 +304,12 @@ if (noteViewInterruptors.length > 0) {
|
|||
console.error(err);
|
||||
}
|
||||
}
|
||||
if (result == null) {
|
||||
hideByPlugin.value = true;
|
||||
} else {
|
||||
note = result as Misskey.entities.Note;
|
||||
}
|
||||
}
|
||||
|
||||
const isRenote = Misskey.note.isPureRenote(note);
|
||||
const appearNote = getAppearNote(note) ?? note;
|
||||
|
|
@ -944,4 +954,14 @@ function loadConversation() {
|
|||
text-align: center;
|
||||
opacity: 0.7;
|
||||
}
|
||||
|
||||
.deleted {
|
||||
text-align: center;
|
||||
padding: 32px;
|
||||
margin: 6px 32px 32px;
|
||||
--color: light-dark(rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.15));
|
||||
background-size: auto auto;
|
||||
background-image: repeating-linear-gradient(135deg, transparent, transparent 10px, var(--color) 4px, var(--color) 14px);
|
||||
border-radius: 8px;
|
||||
}
|
||||
</style>
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
|
||||
<template>
|
||||
<div
|
||||
:class="[$style.root, { [$style.modal]: modal, _popup: modal }]"
|
||||
:class="[$style.root]"
|
||||
@dragover.stop="onDragover"
|
||||
@dragenter="onDragenter"
|
||||
@dragleave="onDragleave"
|
||||
|
|
@ -114,7 +114,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { inject, watch, nextTick, onMounted, defineAsyncComponent, provide, shallowRef, ref, computed, useTemplateRef, onUnmounted } from 'vue';
|
||||
import { watch, nextTick, onMounted, defineAsyncComponent, provide, shallowRef, ref, computed, useTemplateRef, onUnmounted } from 'vue';
|
||||
import * as mfm from 'mfm-js';
|
||||
import * as Misskey from 'misskey-js';
|
||||
import insertTextAtCursor from 'insert-text-at-cursor';
|
||||
|
|
@ -161,8 +161,6 @@ import { closeTip } from '@/tips.js';
|
|||
|
||||
const $i = ensureSignin();
|
||||
|
||||
const modal = inject(DI.inModal, false);
|
||||
|
||||
const props = withDefaults(defineProps<PostFormProps & {
|
||||
fixed?: boolean;
|
||||
autofocus?: boolean;
|
||||
|
|
@ -1447,13 +1445,6 @@ defineExpose({
|
|||
.root {
|
||||
position: relative;
|
||||
container-type: inline-size;
|
||||
|
||||
&.modal {
|
||||
width: 100%;
|
||||
max-width: 520px;
|
||||
overflow-x: clip;
|
||||
overflow-y: auto;
|
||||
}
|
||||
}
|
||||
|
||||
//#region header
|
||||
|
|
@ -1722,7 +1713,8 @@ html[data-color-scheme=light] .preview {
|
|||
min-width: 100%;
|
||||
width: 100%;
|
||||
min-height: 90px;
|
||||
height: 100%;
|
||||
max-height: 500px;
|
||||
field-sizing: content;
|
||||
}
|
||||
|
||||
.textCount {
|
||||
|
|
|
|||
|
|
@ -14,6 +14,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<MkPostForm
|
||||
ref="form"
|
||||
:class="$style.form"
|
||||
class="_popup"
|
||||
v-bind="props"
|
||||
autofocus
|
||||
freezeAfterPosted
|
||||
|
|
@ -73,7 +74,8 @@ function onModalClosed() {
|
|||
|
||||
<style lang="scss" module>
|
||||
.form {
|
||||
max-height: 100%;
|
||||
width: 100%;
|
||||
max-width: 520px;
|
||||
margin: 0 auto auto auto;
|
||||
}
|
||||
</style>
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<template v-if="showDecoration">
|
||||
<img
|
||||
v-for="decoration in decorations ?? user.avatarDecorations"
|
||||
:class="[$style.decoration, { [$style.decorationBlink]: decoration.blink }]"
|
||||
:class="[$style.decoration, { [$style.decorationBlink]: getDecorationIsBrink(decoration) }]"
|
||||
:src="getDecorationUrl(decoration)"
|
||||
:style="{
|
||||
rotate: getDecorationAngle(decoration),
|
||||
|
|
@ -56,13 +56,16 @@ import { prefer } from '@/preferences.js';
|
|||
const animation = ref(prefer.s.animation);
|
||||
const squareAvatars = ref(prefer.s.squareAvatars);
|
||||
|
||||
type Decoration = Misskey.entities.UserDetailed['avatarDecorations'][number];
|
||||
type DecorationEditorDecoration = Omit<Misskey.entities.UserDetailed['avatarDecorations'][number], 'id'> & { blink?: boolean; };
|
||||
|
||||
const props = withDefaults(defineProps<{
|
||||
user: Misskey.entities.User;
|
||||
target?: string | null;
|
||||
link?: boolean;
|
||||
preview?: boolean;
|
||||
indicator?: boolean;
|
||||
decorations?: (Omit<Misskey.entities.UserDetailed['avatarDecorations'][number], 'id'> & { blink?: boolean; })[];
|
||||
decorations?: DecorationEditorDecoration[];
|
||||
forceShowDecoration?: boolean;
|
||||
}>(), {
|
||||
target: null,
|
||||
|
|
@ -93,27 +96,31 @@ function onClick(ev: MouseEvent): void {
|
|||
emit('click', ev);
|
||||
}
|
||||
|
||||
function getDecorationUrl(decoration: Omit<Misskey.entities.UserDetailed['avatarDecorations'][number], 'id'>) {
|
||||
function getDecorationUrl(decoration: Decoration | DecorationEditorDecoration) {
|
||||
if (prefer.s.disableShowingAnimatedImages || prefer.s.dataSaver.avatar) return getStaticImageUrl(decoration.url);
|
||||
return decoration.url;
|
||||
}
|
||||
|
||||
function getDecorationAngle(decoration: Omit<Misskey.entities.UserDetailed['avatarDecorations'][number], 'id'>) {
|
||||
function getDecorationAngle(decoration: Decoration | DecorationEditorDecoration) {
|
||||
const angle = decoration.angle ?? 0;
|
||||
return angle === 0 ? undefined : `${angle * 360}deg`;
|
||||
}
|
||||
|
||||
function getDecorationScale(decoration: Omit<Misskey.entities.UserDetailed['avatarDecorations'][number], 'id'>) {
|
||||
function getDecorationScale(decoration: Decoration | DecorationEditorDecoration) {
|
||||
const scaleX = decoration.flipH ? -1 : 1;
|
||||
return scaleX === 1 ? undefined : `${scaleX} 1`;
|
||||
}
|
||||
|
||||
function getDecorationOffset(decoration: Omit<Misskey.entities.UserDetailed['avatarDecorations'][number], 'id'>) {
|
||||
function getDecorationOffset(decoration: Decoration | DecorationEditorDecoration) {
|
||||
const offsetX = decoration.offsetX ?? 0;
|
||||
const offsetY = decoration.offsetY ?? 0;
|
||||
return offsetX === 0 && offsetY === 0 ? undefined : `${offsetX * 100}% ${offsetY * 100}%`;
|
||||
}
|
||||
|
||||
function getDecorationIsBrink(decoration: Decoration | DecorationEditorDecoration) {
|
||||
return 'blink' in decoration && decoration.blink === true;
|
||||
}
|
||||
|
||||
const color = ref<string | undefined>();
|
||||
|
||||
watch(() => props.user.avatarBlurhash, () => {
|
||||
|
|
|
|||
|
|
@ -74,9 +74,8 @@ function mount() {
|
|||
}
|
||||
|
||||
function back() {
|
||||
const prev = tabs.value.at(tabs.value.length - 2);
|
||||
if (prev == null) return; // transitionの関係でprevが無い状態でbackが呼ばれることがある
|
||||
|
||||
if (tabs.value.length <= 1) return; // transitionの関係でタブが1つの状態でbackが呼ばれることがある
|
||||
const prev = tabs.value[tabs.value.length - 2];
|
||||
tabs.value = [...tabs.value.slice(0, tabs.value.length - 1)];
|
||||
router?.replaceByPath(prev.fullPath);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@ export const components = {
|
|||
SearchIcon: SearchIcon,
|
||||
};
|
||||
|
||||
declare module '@vue/runtime-core' {
|
||||
declare module 'vue' {
|
||||
export interface GlobalComponents {
|
||||
I18n: typeof I18n;
|
||||
RouterView: typeof RouterView;
|
||||
|
|
|
|||
|
|
@ -122,7 +122,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<SearchMarker>
|
||||
<MkFolder :defaultOpen="true">
|
||||
<template #icon><SearchIcon><i class="ti ti-bolt"></i></SearchIcon></template>
|
||||
<template #label><SearchLabel>Misskey® Reactions Boost Technology™ (RBT)</SearchLabel><span class="_beta">{{ i18n.ts.beta }}</span></template>
|
||||
<template #label><SearchLabel>Misskey® Reactions Boost Technology™ (RBT)</SearchLabel></template>
|
||||
<template v-if="rbtForm.savedState.enableReactionsBuffering" #suffix>Enabled</template>
|
||||
<template v-else #suffix>Disabled</template>
|
||||
<template v-if="rbtForm.modified.value" #footer>
|
||||
|
|
|
|||
|
|
@ -257,7 +257,7 @@ async function search() {
|
|||
}
|
||||
|
||||
const headerActions = computed(() => {
|
||||
if (channel.value && channel.value.userId) {
|
||||
if (channel.value) {
|
||||
const headerItems: PageHeaderItem[] = [];
|
||||
|
||||
headerItems.push({
|
||||
|
|
|
|||
|
|
@ -193,7 +193,7 @@ function start() {
|
|||
}
|
||||
|
||||
function getIsLegacy(version: string | null): boolean {
|
||||
if (version == null) return false;
|
||||
if (version == null) return true;
|
||||
try {
|
||||
return compareVersions(version, '1.0.0') < 0;
|
||||
} catch {
|
||||
|
|
@ -206,7 +206,7 @@ async function run() {
|
|||
if (!flash.value) return;
|
||||
|
||||
const version = utils.getLangVersion(flash.value.script);
|
||||
const isLegacy = version != null && getIsLegacy(version);
|
||||
const isLegacy = getIsLegacy(version);
|
||||
|
||||
const { Interpreter, Parser, values } = isLegacy ? (await import('@syuilo/aiscript-0-19-0') as any) : await import('@syuilo/aiscript');
|
||||
|
||||
|
|
|
|||
|
|
@ -90,7 +90,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
|
||||
<SearchMarker :keywords="['lockdown']">
|
||||
<FormSection>
|
||||
<template #label><SearchLabel>{{ i18n.ts.lockdown }}</SearchLabel><span class="_beta">{{ i18n.ts.beta }}</span></template>
|
||||
<template #label><SearchLabel>{{ i18n.ts.lockdown }}</SearchLabel></template>
|
||||
|
||||
<div class="_gaps_m">
|
||||
<SearchMarker :keywords="['login', 'signin']">
|
||||
|
|
@ -213,9 +213,9 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
|
||||
<script lang="ts" setup>
|
||||
import { ref, computed, watch } from 'vue';
|
||||
import type { MkSelectItem } from '@/components/MkSelect.vue';
|
||||
import MkSwitch from '@/components/MkSwitch.vue';
|
||||
import MkSelect from '@/components/MkSelect.vue';
|
||||
import type { MkSelectItem } from '@/components/MkSelect.vue';
|
||||
import FormSection from '@/components/form/section.vue';
|
||||
import { misskeyApi } from '@/utility/misskey-api.js';
|
||||
import { i18n } from '@/i18n.js';
|
||||
|
|
|
|||
|
|
@ -107,7 +107,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
|
||||
<SearchMarker :keywords="['follow', 'message']">
|
||||
<MkInput v-model="profile.followedMessage" :max="200" manualSave :mfmPreview="false">
|
||||
<template #label><SearchLabel>{{ i18n.ts._profile.followedMessage }}</SearchLabel><span class="_beta">{{ i18n.ts.beta }}</span></template>
|
||||
<template #label><SearchLabel>{{ i18n.ts._profile.followedMessage }}</SearchLabel></template>
|
||||
<template #caption>
|
||||
<div><SearchText>{{ i18n.ts._profile.followedMessageDescription }}</SearchText></div>
|
||||
<div>{{ i18n.ts._profile.followedMessageDescriptionForLockedAccount }}</div>
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<SearchMarker :keywords="['signin', 'login', 'history', 'log']">
|
||||
<FormSection>
|
||||
<template #label><SearchLabel>{{ i18n.ts.signinHistory }}</SearchLabel></template>
|
||||
<MkPagination :paginator="paginator" withControl>
|
||||
<MkPagination :paginator="paginator" withControl :forceDisableInfiniteScroll="true">
|
||||
<template #default="{items}">
|
||||
<div>
|
||||
<div v-for="item in items" :key="item.id" v-panel class="timnmucd">
|
||||
|
|
|
|||
|
|
@ -257,20 +257,23 @@ export class PreferencesManager extends EventEmitter<PreferencesManagerEvents> {
|
|||
|
||||
this.rewriteRawState(key, v);
|
||||
|
||||
const record = this.getMatchedRecordOf(key);
|
||||
|
||||
const _save = () => {
|
||||
this.save();
|
||||
this.emit('committed', {
|
||||
key,
|
||||
value: v,
|
||||
oldValue: this.s[key],
|
||||
});
|
||||
|
||||
const record = this.getMatchedRecordOf(key);
|
||||
};
|
||||
|
||||
if (parseScope(record[0]).account == null && isAccountDependentKey(key) && currentAccount != null) {
|
||||
this.profile.preferences[key].push([makeScope({
|
||||
server: host,
|
||||
account: currentAccount.id,
|
||||
}), v, {}]);
|
||||
this.save();
|
||||
_save();
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -278,12 +281,12 @@ export class PreferencesManager extends EventEmitter<PreferencesManagerEvents> {
|
|||
this.profile.preferences[key].push([makeScope({
|
||||
server: host,
|
||||
}), v, {}]);
|
||||
this.save();
|
||||
_save();
|
||||
return;
|
||||
}
|
||||
|
||||
record[1] = v;
|
||||
this.save();
|
||||
_save();
|
||||
|
||||
if (record[2].sync) {
|
||||
// awaitの必要なし
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@ export const TIPS = [
|
|||
'clips',
|
||||
'userLists',
|
||||
'postForm',
|
||||
'deck',
|
||||
'tl.home',
|
||||
'tl.local',
|
||||
'tl.social',
|
||||
|
|
|
|||
|
|
@ -14,6 +14,9 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<i v-if="store.r.realtimeMode.value" class="ti ti-bolt ti-fw"></i>
|
||||
<i v-else class="ti ti-bolt-off ti-fw"></i>
|
||||
</button>
|
||||
<button v-if="!iconOnly && showWidgetButton" v-tooltip.noDelay.right="i18n.ts.widgets" class="_button" :class="[$style.widget]" @click="() => emit('widgetButtonClick')">
|
||||
<i class="ti ti-apps ti-fw"></i>
|
||||
</button>
|
||||
</div>
|
||||
<div :class="$style.middle">
|
||||
<MkA v-tooltip.noDelay.right="i18n.ts.timeline" :class="$style.item" :activeClass="$style.active" to="/" exact>
|
||||
|
|
@ -51,7 +54,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
</MkA>
|
||||
</div>
|
||||
<div :class="$style.bottom">
|
||||
<button v-if="showWidgetButton" v-tooltip.noDelay.right="i18n.ts.widgets" class="_button" :class="[$style.widget]" @click="() => emit('widgetButtonClick')">
|
||||
<button v-if="iconOnly && showWidgetButton" v-tooltip.noDelay.right="i18n.ts.widgets" class="_button" :class="[$style.widget]" @click="() => emit('widgetButtonClick')">
|
||||
<i class="ti ti-apps ti-fw"></i>
|
||||
</button>
|
||||
<button v-if="iconOnly" v-tooltip.noDelay.right="i18n.ts.realtimeMode" class="_button" :class="[$style.realtimeMode, store.r.realtimeMode.value ? $style.on : null]" @click="toggleRealtimeMode">
|
||||
|
|
@ -436,6 +439,12 @@ function menuEdit() {
|
|||
}
|
||||
}
|
||||
|
||||
.widget {
|
||||
display: inline-block;
|
||||
width: var(--top-height);
|
||||
margin-left: auto;
|
||||
}
|
||||
|
||||
.bottom {
|
||||
position: sticky;
|
||||
bottom: 0;
|
||||
|
|
|
|||
|
|
@ -38,36 +38,39 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
@headerWheel="onWheel"
|
||||
/>
|
||||
</section>
|
||||
<div v-if="layout.length === 0" class="_panel" :class="$style.onboarding">
|
||||
<div v-if="layout.length === 0" class="_panel _gaps" :class="$style.onboarding">
|
||||
<div>{{ i18n.ts._deck.introduction }}</div>
|
||||
<div>{{ i18n.ts._deck.introduction2 }}</div>
|
||||
<MkInfo v-if="!store.r.tips.value.deck" closable @close="closeTip('deck')">
|
||||
<button class="_textButton" @click="showTour">{{ i18n.ts._deck.showHowToUse }}</button>
|
||||
</MkInfo>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div v-if="prefer.r['deck.menuPosition'].value === 'right'" :class="$style.sideMenu">
|
||||
<div :class="$style.sideMenuTop">
|
||||
<button v-tooltip.noDelay.left="`${i18n.ts._deck.profile}: ${prefer.s['deck.profile']}`" :class="$style.sideMenuButton" class="_button" @click="switchProfileMenu"><i class="ti ti-caret-down"></i></button>
|
||||
<button ref="swicthProfileButtonEl" v-tooltip.noDelay.left="`${i18n.ts._deck.profile}: ${prefer.s['deck.profile']}`" :class="$style.sideMenuButton" class="_button" @click="switchProfileMenu"><i class="ti ti-caret-down"></i></button>
|
||||
<button v-tooltip.noDelay.left="i18n.ts._deck.deleteProfile" :class="$style.sideMenuButton" class="_button" @click="deleteProfile"><i class="ti ti-trash"></i></button>
|
||||
</div>
|
||||
<div :class="$style.sideMenuMiddle">
|
||||
<button v-tooltip.noDelay.left="i18n.ts._deck.addColumn" :class="$style.sideMenuButton" class="_button" @click="addColumn"><i class="ti ti-plus"></i></button>
|
||||
<button ref="addColumnButtonEl" v-tooltip.noDelay.left="i18n.ts._deck.addColumn" :class="$style.sideMenuButton" class="_button" @click="addColumn"><i class="ti ti-plus"></i></button>
|
||||
</div>
|
||||
<div :class="$style.sideMenuBottom">
|
||||
<button v-tooltip.noDelay.left="i18n.ts.settings" :class="$style.sideMenuButton" class="_button" @click="showSettings"><i class="ti ti-settings-2"></i></button>
|
||||
<button ref="settingsButtonEl" v-tooltip.noDelay.left="i18n.ts.settings" :class="$style.sideMenuButton" class="_button" @click="showSettings"><i class="ti ti-settings-2"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div v-if="prefer.r['deck.menuPosition'].value === 'bottom'" :class="$style.bottomMenu">
|
||||
<div :class="$style.bottomMenuLeft">
|
||||
<button v-tooltip.noDelay.left="`${i18n.ts._deck.profile}: ${prefer.s['deck.profile']}`" :class="$style.bottomMenuButton" class="_button" @click="switchProfileMenu"><i class="ti ti-caret-down"></i></button>
|
||||
<button v-tooltip.noDelay.left="i18n.ts._deck.deleteProfile" :class="$style.bottomMenuButton" class="_button" @click="deleteProfile"><i class="ti ti-trash"></i></button>
|
||||
<button ref="swicthProfileButtonEl" v-tooltip.noDelay.top="`${i18n.ts._deck.profile}: ${prefer.s['deck.profile']}`" :class="$style.bottomMenuButton" class="_button" @click="switchProfileMenu"><i class="ti ti-caret-down"></i></button>
|
||||
<button v-tooltip.noDelay.top="i18n.ts._deck.deleteProfile" :class="$style.bottomMenuButton" class="_button" @click="deleteProfile"><i class="ti ti-trash"></i></button>
|
||||
</div>
|
||||
<div :class="$style.bottomMenuMiddle">
|
||||
<button v-tooltip.noDelay.left="i18n.ts._deck.addColumn" :class="$style.bottomMenuButton" class="_button" @click="addColumn"><i class="ti ti-plus"></i></button>
|
||||
<button ref="addColumnButtonEl" v-tooltip.noDelay.top="i18n.ts._deck.addColumn" :class="$style.bottomMenuButton" class="_button" @click="addColumn"><i class="ti ti-plus"></i></button>
|
||||
</div>
|
||||
<div :class="$style.bottomMenuRight">
|
||||
<button v-tooltip.noDelay.left="i18n.ts.settings" :class="$style.bottomMenuButton" class="_button" @click="showSettings"><i class="ti ti-settings-2"></i></button>
|
||||
<button ref="settingsButtonEl" v-tooltip.noDelay.top="i18n.ts.settings" :class="$style.bottomMenuButton" class="_button" @click="showSettings"><i class="ti ti-settings-2"></i></button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
@ -96,6 +99,7 @@ import { $i } from '@/i.js';
|
|||
import { i18n } from '@/i18n.js';
|
||||
import { deviceKind } from '@/utility/device-kind.js';
|
||||
import { prefer } from '@/preferences.js';
|
||||
import { store } from '@/store.js';
|
||||
import XMainColumn from '@/ui/deck/main-column.vue';
|
||||
import XTlColumn from '@/ui/deck/tl-column.vue';
|
||||
import XAntennaColumn from '@/ui/deck/antenna-column.vue';
|
||||
|
|
@ -107,10 +111,13 @@ import XMentionsColumn from '@/ui/deck/mentions-column.vue';
|
|||
import XDirectColumn from '@/ui/deck/direct-column.vue';
|
||||
import XRoleTimelineColumn from '@/ui/deck/role-timeline-column.vue';
|
||||
import XChatColumn from '@/ui/deck/chat-column.vue';
|
||||
import MkInfo from '@/components/MkInfo.vue';
|
||||
import { mainRouter } from '@/router.js';
|
||||
import { columns, layout, columnTypes, switchProfileMenu, addColumn as addColumnToStore, deleteProfile as deleteProfile_ } from '@/deck.js';
|
||||
import { shouldSuggestRestoreBackup } from '@/preferences/utility.js';
|
||||
import { shouldSuggestReload } from '@/utility/reload-suggest.js';
|
||||
import { startTour } from '@/utility/tour.js';
|
||||
import { closeTip } from '@/tips.js';
|
||||
|
||||
const XStatusBars = defineAsyncComponent(() => import('@/ui/_common_/statusbars.vue'));
|
||||
const XAnnouncements = defineAsyncComponent(() => import('@/ui/_common_/announcements.vue'));
|
||||
|
|
@ -163,6 +170,9 @@ function showSettings() {
|
|||
}
|
||||
|
||||
const columnsEl = useTemplateRef('columnsEl');
|
||||
const addColumnButtonEl = useTemplateRef('addColumnButtonEl');
|
||||
const settingsButtonEl = useTemplateRef('settingsButtonEl');
|
||||
const swicthProfileButtonEl = useTemplateRef('swicthProfileButtonEl');
|
||||
|
||||
const addColumn = async (ev) => {
|
||||
const { canceled, result: column } = await os.select({
|
||||
|
|
@ -218,6 +228,30 @@ async function deleteProfile() {
|
|||
os.success();
|
||||
}
|
||||
|
||||
function showTour() {
|
||||
if (addColumnButtonEl.value == null ||
|
||||
settingsButtonEl.value == null ||
|
||||
swicthProfileButtonEl.value == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
startTour([{
|
||||
element: addColumnButtonEl.value,
|
||||
title: i18n.ts._deck._howToUse.addColumn_title,
|
||||
description: i18n.ts._deck._howToUse.addColumn_description,
|
||||
}, {
|
||||
element: settingsButtonEl.value,
|
||||
title: i18n.ts._deck._howToUse.settings_title,
|
||||
description: i18n.ts._deck._howToUse.settings_description,
|
||||
}, {
|
||||
element: swicthProfileButtonEl.value,
|
||||
title: i18n.ts._deck._howToUse.switchProfile_title,
|
||||
description: i18n.ts._deck._howToUse.switchProfile_description,
|
||||
}]).then(() => {
|
||||
closeTip('deck');
|
||||
});
|
||||
}
|
||||
|
||||
window.document.documentElement.style.overflowY = 'hidden';
|
||||
window.document.documentElement.style.scrollBehavior = 'auto';
|
||||
</script>
|
||||
|
|
@ -345,7 +379,7 @@ window.document.documentElement.style.scrollBehavior = 'auto';
|
|||
}
|
||||
|
||||
.bottomMenuButton {
|
||||
display: block;
|
||||
display: inline-block;
|
||||
height: 100%;
|
||||
aspect-ratio: 1;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ async function setAntenna() {
|
|||
})),
|
||||
} : undefined),
|
||||
],
|
||||
default: props.column.antennaId,
|
||||
default: antennas.find(x => x.id === props.column.antennaId)?.id,
|
||||
});
|
||||
|
||||
if (canceled || antennaIdOrOperation == null) return;
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ async function setChannel() {
|
|||
items: channels.map(x => ({
|
||||
value: x.id, label: x.name,
|
||||
})),
|
||||
default: props.column.channelId,
|
||||
default: channels.find(x => x.id === props.column.channelId)?.id,
|
||||
});
|
||||
if (canceled || chosenChannelId == null) return;
|
||||
const chosenChannel = channels.find(x => x.id === chosenChannelId)!;
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@ async function setList() {
|
|||
})),
|
||||
} : undefined),
|
||||
],
|
||||
default: props.column.listId,
|
||||
default: lists.find(x => x.id === props.column.listId)?.id,
|
||||
});
|
||||
if (canceled || listIdOrOperation == null) return;
|
||||
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ async function setRole() {
|
|||
items: roles.map(x => ({
|
||||
value: x.id, label: x.name,
|
||||
})),
|
||||
default: props.column.roleId,
|
||||
default: roles.find(x => x.id === props.column.roleId)?.id,
|
||||
});
|
||||
if (canceled || roleId == null) return;
|
||||
const role = roles.find(x => x.id === roleId)!;
|
||||
|
|
|
|||
|
|
@ -104,6 +104,7 @@ async function setType() {
|
|||
}, {
|
||||
value: 'global', label: i18n.ts._timelines.global,
|
||||
}],
|
||||
default: props.column.tl,
|
||||
});
|
||||
if (canceled) {
|
||||
if (props.column.tl == null) {
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<XTitlebar v-if="prefer.r.showTitlebar.value" style="flex-shrink: 0;"/>
|
||||
|
||||
<div :class="$style.nonTitlebarArea">
|
||||
<XSidebar v-if="!isMobile" :class="$style.sidebar" :showWidgetButton="!isDesktop" @widgetButtonClick="widgetsShowing = true"/>
|
||||
<XSidebar v-if="!isMobile" :class="$style.sidebar" :showWidgetButton="!showWidgetsSide" @widgetButtonClick="widgetsShowing = true"/>
|
||||
|
||||
<div :class="[$style.contents, !isMobile && prefer.r.showTitlebar.value ? $style.withSidebarAndTitlebar : null]" @contextmenu.stop="onContextmenu">
|
||||
<div>
|
||||
|
|
@ -22,7 +22,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<XMobileFooterMenu v-if="isMobile" ref="navFooter" v-model:drawerMenuShowing="drawerMenuShowing" v-model:widgetsShowing="widgetsShowing"/>
|
||||
</div>
|
||||
|
||||
<div v-if="isDesktop && !pageMetadata?.needWideArea" :class="$style.widgets">
|
||||
<div v-if="showWidgetsSide && !pageMetadata?.needWideArea" :class="$style.widgets">
|
||||
<XWidgets/>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -64,7 +64,8 @@ const DESKTOP_THRESHOLD = 1100;
|
|||
const MOBILE_THRESHOLD = 500;
|
||||
|
||||
// デスクトップでウィンドウを狭くしたときモバイルUIが表示されて欲しいことはあるので deviceKind === 'desktop' の判定は行わない
|
||||
const isDesktop = ref(window.innerWidth >= DESKTOP_THRESHOLD);
|
||||
const showWidgetsSide = window.innerWidth >= DESKTOP_THRESHOLD;
|
||||
|
||||
const isMobile = ref(deviceKind === 'smartphone' || window.innerWidth <= MOBILE_THRESHOLD);
|
||||
window.addEventListener('resize', () => {
|
||||
isMobile.value = deviceKind === 'smartphone' || window.innerWidth <= MOBILE_THRESHOLD;
|
||||
|
|
@ -102,14 +103,6 @@ if (window.innerWidth > 1024) {
|
|||
}
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
if (!isDesktop.value) {
|
||||
window.addEventListener('resize', () => {
|
||||
if (window.innerWidth >= DESKTOP_THRESHOLD) isDesktop.value = true;
|
||||
}, { passive: true });
|
||||
}
|
||||
});
|
||||
|
||||
const onContextmenu = (ev) => {
|
||||
if (isLink(ev.target)) return;
|
||||
if (['INPUT', 'TEXTAREA', 'IMG', 'VIDEO', 'CANVAS'].includes(ev.target.tagName) || ev.target.attributes['contenteditable']) return;
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ import { watch as chokidarWatch } from 'chokidar';
|
|||
import * as esbuild from 'esbuild';
|
||||
import { build } from 'esbuild';
|
||||
import { execa } from 'execa';
|
||||
import { globSync } from 'glob';
|
||||
import { generateLocaleInterface } from './scripts/generateLocaleInterface.js';
|
||||
import type { BuildOptions, BuildResult, Plugin, PluginBuild } from 'esbuild';
|
||||
|
||||
|
|
@ -22,7 +21,7 @@ const _rootPackage = JSON.parse(fs.readFileSync(resolve(_rootPackageDir, 'packag
|
|||
const _frontendLocalesDir = resolve(_dirname, '../../built/_frontend_dist_/locales');
|
||||
const _localesDir = resolve(_rootPackageDir, 'locales');
|
||||
|
||||
const entryPoints = globSync('./src/**/**.{ts,tsx}');
|
||||
const entryPoints = fs.globSync('./src/**/**.{ts,tsx}');
|
||||
|
||||
const options: BuildOptions = {
|
||||
entryPoints,
|
||||
|
|
|
|||
|
|
@ -29,15 +29,14 @@
|
|||
],
|
||||
"devDependencies": {
|
||||
"@types/js-yaml": "4.0.9",
|
||||
"@types/node": "24.10.1",
|
||||
"@typescript-eslint/eslint-plugin": "8.47.0",
|
||||
"@typescript-eslint/parser": "8.47.0",
|
||||
"chokidar": "4.0.3",
|
||||
"esbuild": "0.27.0",
|
||||
"execa": "9.6.0",
|
||||
"glob": "11.1.0",
|
||||
"@types/node": "24.10.2",
|
||||
"@typescript-eslint/eslint-plugin": "8.49.0",
|
||||
"@typescript-eslint/parser": "8.49.0",
|
||||
"chokidar": "5.0.0",
|
||||
"esbuild": "0.27.1",
|
||||
"execa": "9.6.1",
|
||||
"nodemon": "3.1.11",
|
||||
"tsx": "4.20.6",
|
||||
"tsx": "4.21.0",
|
||||
"typescript": "5.9.3"
|
||||
},
|
||||
"dependencies": {
|
||||
|
|
|
|||
|
|
@ -10936,6 +10936,36 @@ export interface Locale extends ILocale {
|
|||
* プロファイル情報のデバイス間同期を有効にする
|
||||
*/
|
||||
"enableSyncBetweenDevicesForProfiles": string;
|
||||
/**
|
||||
* UIの説明を見る
|
||||
*/
|
||||
"showHowToUse": string;
|
||||
"_howToUse": {
|
||||
/**
|
||||
* カラム追加
|
||||
*/
|
||||
"addColumn_title": string;
|
||||
/**
|
||||
* カラムの種類を選んで追加できます。
|
||||
*/
|
||||
"addColumn_description": string;
|
||||
/**
|
||||
* UI設定
|
||||
*/
|
||||
"settings_title": string;
|
||||
/**
|
||||
* デッキUIの詳細設定を行えます。
|
||||
*/
|
||||
"settings_description": string;
|
||||
/**
|
||||
* プロファイル切り替え
|
||||
*/
|
||||
"switchProfile_title": string;
|
||||
/**
|
||||
* UIのレイアウトをプロファイルとして保存し、いつでも切り替えられるようにできます。
|
||||
*/
|
||||
"switchProfile_description": string;
|
||||
};
|
||||
"_columns": {
|
||||
/**
|
||||
* メイン
|
||||
|
|
|
|||
|
|
@ -11,16 +11,15 @@
|
|||
"lint": "pnpm typecheck && pnpm eslint"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/node": "24.10.1",
|
||||
"@types/node": "24.10.2",
|
||||
"@types/wawoff2": "1.0.2",
|
||||
"@typescript-eslint/eslint-plugin": "8.47.0",
|
||||
"@typescript-eslint/parser": "8.47.0"
|
||||
"@typescript-eslint/eslint-plugin": "8.49.0",
|
||||
"@typescript-eslint/parser": "8.49.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"@tabler/icons-webfont": "3.35.0",
|
||||
"harfbuzzjs": "0.4.13",
|
||||
"tiny-glob": "0.2.9",
|
||||
"tsx": "4.20.6",
|
||||
"tsx": "4.21.0",
|
||||
"typescript": "5.9.3",
|
||||
"wawoff2": "2.0.1"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -3,9 +3,8 @@
|
|||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import { promises as fsp, existsSync } from 'fs';
|
||||
import path from 'path';
|
||||
import glob from 'tiny-glob';
|
||||
import { promises as fsp, existsSync } from 'node:fs';
|
||||
import path from 'node:path';
|
||||
import { generateSubsettedFont } from './subsetter.js';
|
||||
|
||||
const filesToScan = {
|
||||
|
|
@ -47,8 +46,8 @@ async function main() {
|
|||
const iconsToPack = new Set<string>();
|
||||
|
||||
const cwd = path.resolve(process.cwd(), '../../');
|
||||
const files = await glob(dir, { cwd });
|
||||
for (const file of files) {
|
||||
const files = fsp.glob(dir, { cwd });
|
||||
for await (const file of files) {
|
||||
//console.log(`Scanning ${file}`);
|
||||
const content = await fsp.readFile(path.resolve(cwd, file), 'utf-8');
|
||||
const classRegex = /ti-[a-z0-9-]+/g;
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue