Compare commits
112 Commits
2023.10.2
...
notificati
Author | SHA1 | Date | |
---|---|---|---|
![]() |
5ec1d96048 | ||
![]() |
441c0ca465 | ||
![]() |
29b06994a2 | ||
![]() |
314fb4bfd9 | ||
![]() |
ce5ff70cb3 | ||
![]() |
6a73f7c108 | ||
![]() |
c54baf873b | ||
![]() |
e88dbad3cf | ||
![]() |
5772de2a62 | ||
![]() |
821633f878 | ||
![]() |
9b073e5fe6 | ||
![]() |
77db652bff | ||
![]() |
e632a84431 | ||
![]() |
7ed2a5fc1b | ||
![]() |
5fb6847419 | ||
![]() |
e85b8217c0 | ||
![]() |
d6fe897923 | ||
![]() |
bf01c1ee64 | ||
![]() |
7d3721dded | ||
![]() |
735f22c1c5 | ||
![]() |
cf026e4c72 | ||
![]() |
e2f34e3db6 | ||
![]() |
7c692283ad | ||
![]() |
e6e5bf1da4 | ||
![]() |
a35fe29ef4 | ||
![]() |
56c5da97e6 | ||
![]() |
af779ebff9 | ||
![]() |
4eab3c07fd | ||
![]() |
359f3d5ef5 | ||
![]() |
d45b2dd3a7 | ||
![]() |
b4dd61a016 | ||
![]() |
4f180ad45c | ||
![]() |
52dbab56a4 | ||
![]() |
7015cc937b | ||
![]() |
50b16e36c7 | ||
![]() |
e512f8c56d | ||
![]() |
183e5cef8b | ||
![]() |
38c163d67c | ||
![]() |
20f70f1c39 | ||
![]() |
c239058624 | ||
![]() |
117db08880 | ||
![]() |
2de4d3329d | ||
![]() |
8f01757a7f | ||
![]() |
d9cfea8b10 | ||
![]() |
cb1449be09 | ||
![]() |
9ad48dae04 | ||
![]() |
59cc101752 | ||
![]() |
aefc941df3 | ||
![]() |
2da55f70a7 | ||
![]() |
0fc36d11d7 | ||
![]() |
7436e0da18 | ||
![]() |
a161a9c1e7 | ||
![]() |
1a8243f1ca | ||
![]() |
feedad7d8b | ||
![]() |
b627978d00 | ||
![]() |
2a61a0c026 | ||
![]() |
5887c5da6c | ||
![]() |
9ec667a87c | ||
![]() |
a91d2ba625 | ||
![]() |
e73e21851e | ||
![]() |
481db8aba4 | ||
![]() |
a8dc6d08b1 | ||
![]() |
12ab905440 | ||
![]() |
abe78a277a | ||
![]() |
aa31b6c65b | ||
![]() |
c37616de72 | ||
![]() |
e5ff8d8445 | ||
![]() |
8a2309ba7d | ||
![]() |
a8ee67cace | ||
![]() |
5e76675a0c | ||
![]() |
1d9b5ae1ba | ||
![]() |
dc0582739f | ||
![]() |
024546206d | ||
![]() |
4dd4a11cef | ||
![]() |
afb37f0b03 | ||
![]() |
0c730968a3 | ||
![]() |
7e15f71916 | ||
![]() |
b22066b9a2 | ||
![]() |
9caae8a10a | ||
![]() |
9d0648ed35 | ||
![]() |
9c79f0b45a | ||
![]() |
c59973d9c0 | ||
![]() |
4a832e87c0 | ||
![]() |
9dcccbc8e1 | ||
![]() |
e6c54de814 | ||
![]() |
5a39c1a8eb | ||
![]() |
c9ae5d0e51 | ||
![]() |
805a2c027e | ||
![]() |
fdeee5dd05 | ||
![]() |
796265fc50 | ||
![]() |
9221cbf42b | ||
![]() |
230b4318bd | ||
![]() |
5dc0463323 | ||
![]() |
8091e8b900 | ||
![]() |
1aeae6217e | ||
![]() |
5cd98804a2 | ||
![]() |
7e80b3d4d4 | ||
![]() |
18fb7a2080 | ||
![]() |
983b1e63df | ||
![]() |
ce09a35b03 | ||
![]() |
4eaa02d25f | ||
![]() |
4b295088fd | ||
![]() |
69795e74bf | ||
![]() |
72327716ca | ||
![]() |
fd8d253e1e | ||
![]() |
845713bdbf | ||
![]() |
2697826007 | ||
![]() |
f51bca41c5 | ||
![]() |
722584bf72 | ||
![]() |
12fe09c6e7 | ||
![]() |
2c0a139da6 | ||
![]() |
101e5d622d |
60
.github/ISSUE_TEMPLATE/01_bug-report.md
vendored
60
.github/ISSUE_TEMPLATE/01_bug-report.md
vendored
@@ -1,60 +0,0 @@
|
|||||||
---
|
|
||||||
name: 🐛 Bug Report
|
|
||||||
about: Create a report to help us improve
|
|
||||||
title: ''
|
|
||||||
labels: ⚠️bug?
|
|
||||||
assignees: ''
|
|
||||||
|
|
||||||
---
|
|
||||||
|
|
||||||
<!--
|
|
||||||
Thanks for reporting!
|
|
||||||
First, in order to avoid duplicate Issues, please search to see if the problem you found has already been reported.
|
|
||||||
Also, If you are NOT owner/admin of server, PLEASE DONT REPORT SERVER SPECIFIC ISSUES TO HERE! (e.g. feature XXX is not working in misskey.example) Please try with another misskey servers, and if your issue is only reproducible with specific server, contact your server's owner/admin first.
|
|
||||||
-->
|
|
||||||
|
|
||||||
## 💡 Summary
|
|
||||||
|
|
||||||
<!-- Tell us what the bug is -->
|
|
||||||
|
|
||||||
## 🥰 Expected Behavior
|
|
||||||
|
|
||||||
<!--- Tell us what should happen -->
|
|
||||||
|
|
||||||
## 🤬 Actual Behavior
|
|
||||||
|
|
||||||
<!--
|
|
||||||
Tell us what happens instead of the expected behavior.
|
|
||||||
Please include errors from the developer console and/or server log files if you have access to them.
|
|
||||||
-->
|
|
||||||
|
|
||||||
## 📝 Steps to Reproduce
|
|
||||||
|
|
||||||
1.
|
|
||||||
2.
|
|
||||||
3.
|
|
||||||
|
|
||||||
## 📌 Environment
|
|
||||||
|
|
||||||
<!-- Tell us where on the platform it happens -->
|
|
||||||
<!-- DO NOT WRITE "latest". Please provide the specific version. -->
|
|
||||||
|
|
||||||
### 💻 Frontend
|
|
||||||
* Model and OS of the device(s):
|
|
||||||
<!-- Example: MacBook Pro (14inch, 2021), macOS Ventura 13.4 -->
|
|
||||||
* Browser:
|
|
||||||
<!-- Example: Chrome 113.0.5672.126 -->
|
|
||||||
* Server URL:
|
|
||||||
<!-- Example: misskey.io -->
|
|
||||||
* Misskey:
|
|
||||||
13.x.x
|
|
||||||
|
|
||||||
### 🛰 Backend (for server admin)
|
|
||||||
<!-- If you are using a managed service, put that after the version. -->
|
|
||||||
|
|
||||||
* Installation Method or Hosting Service: <!-- Example: docker compose, k8s/docker, systemd, "Misskey install shell script", development environment -->
|
|
||||||
* Misskey: 13.x.x
|
|
||||||
* Node: 20.x.x
|
|
||||||
* PostgreSQL: 15.x.x
|
|
||||||
* Redis: 7.x.x
|
|
||||||
* OS and Architecture: <!-- Example: Ubuntu 22.04.2 LTS aarch64 -->
|
|
91
.github/ISSUE_TEMPLATE/01_bug-report.yml
vendored
Normal file
91
.github/ISSUE_TEMPLATE/01_bug-report.yml
vendored
Normal file
@@ -0,0 +1,91 @@
|
|||||||
|
name: 🐛 Bug Report
|
||||||
|
description: Create a report to help us improve
|
||||||
|
labels: ["⚠️bug?"]
|
||||||
|
|
||||||
|
body:
|
||||||
|
- type: markdown
|
||||||
|
attributes:
|
||||||
|
value: |
|
||||||
|
Thanks for reporting!
|
||||||
|
First, in order to avoid duplicate Issues, please search to see if the problem you found has already been reported.
|
||||||
|
Also, If you are NOT owner/admin of server, PLEASE DONT REPORT SERVER SPECIFIC ISSUES TO HERE! (e.g. feature XXX is not working in misskey.example) Please try with another misskey servers, and if your issue is only reproducible with specific server, contact your server's owner/admin first.
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: 💡 Summary
|
||||||
|
description: Tell us what the bug is
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: 🥰 Expected Behavior
|
||||||
|
description: Tell us what should happen
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: 🤬 Actual Behavior
|
||||||
|
description: |
|
||||||
|
Tell us what happens instead of the expected behavior.
|
||||||
|
Please include errors from the developer console and/or server log files if you have access to them.
|
||||||
|
validations:
|
||||||
|
required: true
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: 📝 Steps to Reproduce
|
||||||
|
placeholder: |
|
||||||
|
1.
|
||||||
|
2.
|
||||||
|
3.
|
||||||
|
validations:
|
||||||
|
required: false
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: 💻 Frontend Environment
|
||||||
|
description: |
|
||||||
|
Tell us where on the platform it happens
|
||||||
|
DO NOT WRITE "latest". Please provide the specific version.
|
||||||
|
|
||||||
|
Examples:
|
||||||
|
* Model and OS of the device(s): MacBook Pro (14inch, 2021), macOS Ventura 13.4
|
||||||
|
* Browser: Chrome 113.0.5672.126
|
||||||
|
* Server URL: misskey.io
|
||||||
|
* Misskey: 13.x.x
|
||||||
|
value: |
|
||||||
|
* Model and OS of the device(s):
|
||||||
|
* Browser:
|
||||||
|
* Server URL:
|
||||||
|
* Misskey:
|
||||||
|
render: markdown
|
||||||
|
validations:
|
||||||
|
required: false
|
||||||
|
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: 🛰 Backend Environment (for server admin)
|
||||||
|
description: |
|
||||||
|
Tell us where on the platform it happens
|
||||||
|
DO NOT WRITE "latest". Please provide the specific version.
|
||||||
|
If you are using a managed service, put that after the version.
|
||||||
|
|
||||||
|
Examples:
|
||||||
|
* Installation Method or Hosting Service: docker compose, k8s/docker, systemd, "Misskey install shell script", development environment
|
||||||
|
* Misskey: 13.x.x
|
||||||
|
* Node: 20.x.x
|
||||||
|
* PostgreSQL: 15.x.x
|
||||||
|
* Redis: 7.x.x
|
||||||
|
* OS and Architecture: Ubuntu 22.04.2 LTS aarch64
|
||||||
|
value: |
|
||||||
|
* Installation Method or Hosting Service:
|
||||||
|
* Misskey:
|
||||||
|
* Node:
|
||||||
|
* PostgreSQL:
|
||||||
|
* Redis:
|
||||||
|
* OS and Architecture:
|
||||||
|
render: markdown
|
||||||
|
validations:
|
||||||
|
required: false
|
12
.github/ISSUE_TEMPLATE/02_feature-request.md
vendored
12
.github/ISSUE_TEMPLATE/02_feature-request.md
vendored
@@ -1,12 +0,0 @@
|
|||||||
---
|
|
||||||
name: ✨ Feature Request
|
|
||||||
about: Suggest an idea for this project
|
|
||||||
title: ''
|
|
||||||
labels: ✨Feature
|
|
||||||
assignees: ''
|
|
||||||
|
|
||||||
---
|
|
||||||
|
|
||||||
## Summary
|
|
||||||
|
|
||||||
<!-- Tell us what the suggestion is -->
|
|
11
.github/ISSUE_TEMPLATE/02_feature-request.yml
vendored
Normal file
11
.github/ISSUE_TEMPLATE/02_feature-request.yml
vendored
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
name: ✨ Feature Request
|
||||||
|
description: Suggest an idea for this project
|
||||||
|
labels: ["✨Feature"]
|
||||||
|
|
||||||
|
body:
|
||||||
|
- type: textarea
|
||||||
|
attributes:
|
||||||
|
label: Summary
|
||||||
|
description: Tell us what the suggestion is
|
||||||
|
validations:
|
||||||
|
required: true
|
2
.github/workflows/api-misskey-js.yml
vendored
2
.github/workflows/api-misskey-js.yml
vendored
@@ -14,7 +14,7 @@ jobs:
|
|||||||
- run: corepack enable
|
- run: corepack enable
|
||||||
|
|
||||||
- name: Setup Node.js
|
- name: Setup Node.js
|
||||||
uses: actions/setup-node@v3.8.1
|
uses: actions/setup-node@v4.0.0
|
||||||
with:
|
with:
|
||||||
node-version-file: '.node-version'
|
node-version-file: '.node-version'
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
|
63
.github/workflows/get-api-diff.yml
vendored
63
.github/workflows/get-api-diff.yml
vendored
@@ -1,4 +1,5 @@
|
|||||||
name: Report API Diff
|
# this name is used in report-api-diff.yml so be careful when change name
|
||||||
|
name: Get api.json from Misskey
|
||||||
|
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
@@ -43,7 +44,7 @@ jobs:
|
|||||||
version: 8
|
version: 8
|
||||||
run_install: false
|
run_install: false
|
||||||
- name: Use Node.js ${{ matrix.node-version }}
|
- name: Use Node.js ${{ matrix.node-version }}
|
||||||
uses: actions/setup-node@v3.8.1
|
uses: actions/setup-node@v4.0.0
|
||||||
with:
|
with:
|
||||||
node-version: ${{ matrix.node-version }}
|
node-version: ${{ matrix.node-version }}
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
@@ -125,7 +126,7 @@ jobs:
|
|||||||
version: 8
|
version: 8
|
||||||
run_install: false
|
run_install: false
|
||||||
- name: Use Node.js ${{ matrix.node-version }}
|
- name: Use Node.js ${{ matrix.node-version }}
|
||||||
uses: actions/setup-node@v3.8.1
|
uses: actions/setup-node@v4.0.0
|
||||||
with:
|
with:
|
||||||
node-version: ${{ matrix.node-version }}
|
node-version: ${{ matrix.node-version }}
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
@@ -171,55 +172,15 @@ jobs:
|
|||||||
- name: Kill Misskey Job
|
- name: Kill Misskey Job
|
||||||
run: screen -S misskey -X quit
|
run: screen -S misskey -X quit
|
||||||
|
|
||||||
compare-diff:
|
save-pr-number:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: success()
|
|
||||||
needs: [get-base, get-head]
|
|
||||||
permissions:
|
|
||||||
pull-requests: write
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Download Artifact
|
- name: Save PR number
|
||||||
uses: actions/download-artifact@v3
|
env:
|
||||||
|
PR_NUMBER: ${{ github.event.number }}
|
||||||
|
run: |
|
||||||
|
echo "$PR_NUMBER" > ./pr_number
|
||||||
|
- uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: api-artifact
|
name: api-artifact
|
||||||
path: ./artifacts
|
path: pr_number
|
||||||
- name: Output base
|
|
||||||
run: cat ./artifacts/api-base.json
|
|
||||||
- name: Output head
|
|
||||||
run: cat ./artifacts/api-head.json
|
|
||||||
- name: Arrange json files
|
|
||||||
run: |
|
|
||||||
jq '.' ./artifacts/api-base.json > ./api-base.json
|
|
||||||
jq '.' ./artifacts/api-head.json > ./api-head.json
|
|
||||||
- name: Get diff of 2 files
|
|
||||||
run: diff -u --label=base --label=head ./api-base.json ./api-head.json | cat > api.json.diff
|
|
||||||
- name: Get full diff
|
|
||||||
run: diff --label=base --label=head --new-line-format='+%L' --old-line-format='-%L' --unchanged-line-format=' %L' ./api-base.json ./api-head.json | cat > api-full.json.diff
|
|
||||||
- name: Echo full diff
|
|
||||||
run: cat ./api-full.json.diff
|
|
||||||
- name: Upload full diff to Artifact
|
|
||||||
uses: actions/upload-artifact@v3
|
|
||||||
with:
|
|
||||||
name: api-artifact
|
|
||||||
path: api-full.json.diff
|
|
||||||
- id: out-diff
|
|
||||||
name: Build diff Comment
|
|
||||||
run: |
|
|
||||||
cat <<- EOF > ./output.md
|
|
||||||
このPRによるapi.jsonの差分
|
|
||||||
<details>
|
|
||||||
<summary>差分はこちら</summary>
|
|
||||||
|
|
||||||
\`\`\`diff
|
|
||||||
$(cat ./api.json.diff)
|
|
||||||
\`\`\`
|
|
||||||
</details>
|
|
||||||
|
|
||||||
[Get diff files from Workflow Page](https://github.com/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})
|
|
||||||
EOF
|
|
||||||
- name: Write diff comment
|
|
||||||
uses: thollander/actions-comment-pull-request@v2
|
|
||||||
with:
|
|
||||||
comment_tag: show_diff
|
|
||||||
filePath: ./output.md
|
|
||||||
|
6
.github/workflows/lint.yml
vendored
6
.github/workflows/lint.yml
vendored
@@ -19,7 +19,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
version: 8
|
version: 8
|
||||||
run_install: false
|
run_install: false
|
||||||
- uses: actions/setup-node@v3.8.1
|
- uses: actions/setup-node@v4.0.0
|
||||||
with:
|
with:
|
||||||
node-version-file: '.node-version'
|
node-version-file: '.node-version'
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
@@ -46,7 +46,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
version: 7
|
version: 7
|
||||||
run_install: false
|
run_install: false
|
||||||
- uses: actions/setup-node@v3.8.1
|
- uses: actions/setup-node@v4.0.0
|
||||||
with:
|
with:
|
||||||
node-version-file: '.node-version'
|
node-version-file: '.node-version'
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
@@ -72,7 +72,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
version: 7
|
version: 7
|
||||||
run_install: false
|
run_install: false
|
||||||
- uses: actions/setup-node@v3.8.1
|
- uses: actions/setup-node@v4.0.0
|
||||||
with:
|
with:
|
||||||
node-version-file: '.node-version'
|
node-version-file: '.node-version'
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
|
85
.github/workflows/report-api-diff.yml
vendored
Normal file
85
.github/workflows/report-api-diff.yml
vendored
Normal file
@@ -0,0 +1,85 @@
|
|||||||
|
name: Report API Diff
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_run:
|
||||||
|
types: [completed]
|
||||||
|
workflows:
|
||||||
|
- Get api.json from Misskey # get-api-diff.yml
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
compare-diff:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
if: ${{ github.event.workflow_run.conclusion == 'success' }}
|
||||||
|
permissions:
|
||||||
|
pull-requests: write
|
||||||
|
|
||||||
|
# api-artifact
|
||||||
|
steps:
|
||||||
|
- name: Download artifact
|
||||||
|
uses: actions/github-script@v6
|
||||||
|
with:
|
||||||
|
script: |
|
||||||
|
let allArtifacts = await github.rest.actions.listWorkflowRunArtifacts({
|
||||||
|
owner: context.repo.owner,
|
||||||
|
repo: context.repo.repo,
|
||||||
|
run_id: context.payload.workflow_run.id,
|
||||||
|
});
|
||||||
|
let matchArtifact = allArtifacts.data.artifacts.filter((artifact) => {
|
||||||
|
return artifact.name == "api-artifact"
|
||||||
|
})[0];
|
||||||
|
let download = await github.rest.actions.downloadArtifact({
|
||||||
|
owner: context.repo.owner,
|
||||||
|
repo: context.repo.repo,
|
||||||
|
artifact_id: matchArtifact.id,
|
||||||
|
archive_format: 'zip',
|
||||||
|
});
|
||||||
|
let fs = require('fs');
|
||||||
|
fs.writeFileSync(`${process.env.GITHUB_WORKSPACE}/api-artifact.zip`, Buffer.from(download.data));
|
||||||
|
- name: Extract artifact
|
||||||
|
run: unzip api-artifact.zip -d artifacts
|
||||||
|
- name: Load PR Number
|
||||||
|
id: load-pr-num
|
||||||
|
run: echo "pr-number=$(cat artifacts/pr_number)" >> "$GITHUB_OUTPUT"
|
||||||
|
|
||||||
|
- name: Output base
|
||||||
|
run: cat ./artifacts/api-base.json
|
||||||
|
- name: Output head
|
||||||
|
run: cat ./artifacts/api-head.json
|
||||||
|
- name: Arrange json files
|
||||||
|
run: |
|
||||||
|
jq '.' ./artifacts/api-base.json > ./api-base.json
|
||||||
|
jq '.' ./artifacts/api-head.json > ./api-head.json
|
||||||
|
- name: Get diff of 2 files
|
||||||
|
run: diff -u --label=base --label=head ./api-base.json ./api-head.json | cat > api.json.diff
|
||||||
|
- name: Get full diff
|
||||||
|
run: diff --label=base --label=head --new-line-format='+%L' --old-line-format='-%L' --unchanged-line-format=' %L' ./api-base.json ./api-head.json | cat > api-full.json.diff
|
||||||
|
- name: Echo full diff
|
||||||
|
run: cat ./api-full.json.diff
|
||||||
|
- name: Upload full diff to Artifact
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: api-artifact
|
||||||
|
path: |
|
||||||
|
api-full.json.diff
|
||||||
|
api-base.json
|
||||||
|
api-head.json
|
||||||
|
- id: out-diff
|
||||||
|
name: Build diff Comment
|
||||||
|
run: |
|
||||||
|
cat <<- EOF > ./output.md
|
||||||
|
このPRによるapi.jsonの差分
|
||||||
|
<details>
|
||||||
|
<summary>差分はこちら</summary>
|
||||||
|
|
||||||
|
\`\`\`diff
|
||||||
|
$(cat ./api.json.diff)
|
||||||
|
\`\`\`
|
||||||
|
</details>
|
||||||
|
|
||||||
|
[Get diff files from Workflow Page](https://github.com/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})
|
||||||
|
EOF
|
||||||
|
- uses: thollander/actions-comment-pull-request@v2
|
||||||
|
with:
|
||||||
|
pr_number: ${{ steps.load-pr-num.outputs.pr-number }}
|
||||||
|
comment_tag: show_diff
|
||||||
|
filePath: ./output.md
|
2
.github/workflows/test-backend.yml
vendored
2
.github/workflows/test-backend.yml
vendored
@@ -38,7 +38,7 @@ jobs:
|
|||||||
version: 8
|
version: 8
|
||||||
run_install: false
|
run_install: false
|
||||||
- name: Use Node.js ${{ matrix.node-version }}
|
- name: Use Node.js ${{ matrix.node-version }}
|
||||||
uses: actions/setup-node@v3.8.1
|
uses: actions/setup-node@v4.0.0
|
||||||
with:
|
with:
|
||||||
node-version: ${{ matrix.node-version }}
|
node-version: ${{ matrix.node-version }}
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
|
4
.github/workflows/test-frontend.yml
vendored
4
.github/workflows/test-frontend.yml
vendored
@@ -25,7 +25,7 @@ jobs:
|
|||||||
version: 8
|
version: 8
|
||||||
run_install: false
|
run_install: false
|
||||||
- name: Use Node.js ${{ matrix.node-version }}
|
- name: Use Node.js ${{ matrix.node-version }}
|
||||||
uses: actions/setup-node@v3.8.1
|
uses: actions/setup-node@v4.0.0
|
||||||
with:
|
with:
|
||||||
node-version: ${{ matrix.node-version }}
|
node-version: ${{ matrix.node-version }}
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
@@ -83,7 +83,7 @@ jobs:
|
|||||||
version: 7
|
version: 7
|
||||||
run_install: false
|
run_install: false
|
||||||
- name: Use Node.js ${{ matrix.node-version }}
|
- name: Use Node.js ${{ matrix.node-version }}
|
||||||
uses: actions/setup-node@v3.8.1
|
uses: actions/setup-node@v4.0.0
|
||||||
with:
|
with:
|
||||||
node-version: ${{ matrix.node-version }}
|
node-version: ${{ matrix.node-version }}
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
|
2
.github/workflows/test-misskey-js.yml
vendored
2
.github/workflows/test-misskey-js.yml
vendored
@@ -26,7 +26,7 @@ jobs:
|
|||||||
- run: corepack enable
|
- run: corepack enable
|
||||||
|
|
||||||
- name: Setup Node.js ${{ matrix.node-version }}
|
- name: Setup Node.js ${{ matrix.node-version }}
|
||||||
uses: actions/setup-node@v3.8.1
|
uses: actions/setup-node@v4.0.0
|
||||||
with:
|
with:
|
||||||
node-version: ${{ matrix.node-version }}
|
node-version: ${{ matrix.node-version }}
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
|
2
.github/workflows/test-production.yml
vendored
2
.github/workflows/test-production.yml
vendored
@@ -28,7 +28,7 @@ jobs:
|
|||||||
version: 8
|
version: 8
|
||||||
run_install: false
|
run_install: false
|
||||||
- name: Use Node.js ${{ matrix.node-version }}
|
- name: Use Node.js ${{ matrix.node-version }}
|
||||||
uses: actions/setup-node@v3.8.1
|
uses: actions/setup-node@v4.0.0
|
||||||
with:
|
with:
|
||||||
node-version: ${{ matrix.node-version }}
|
node-version: ${{ matrix.node-version }}
|
||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
|
58
CHANGELOG.md
58
CHANGELOG.md
@@ -12,7 +12,63 @@
|
|||||||
|
|
||||||
-->
|
-->
|
||||||
|
|
||||||
## 2023.x.x (unreleased)
|
## 2023.11.0 (unreleased)
|
||||||
|
|
||||||
|
### General
|
||||||
|
- Feat: アイコンデコレーション機能
|
||||||
|
- サーバーで用意された画像をアイコンに重ねることができます
|
||||||
|
- 画像のテンプレートはこちらです: https://misskey-hub.net/avatar-decoration-template.png
|
||||||
|
- 最大でも黄色いエリア内にデコレーションを収めることを推奨します。
|
||||||
|
- 画像は512x512pxを推奨します。
|
||||||
|
- Enhance: すでにフォローしたすべての人の返信をTLに追加できるように
|
||||||
|
- Enhance: 未読の通知数を表示できるように
|
||||||
|
- Enhance: ローカリゼーションの更新
|
||||||
|
- Enhance: 依存関係の更新
|
||||||
|
|
||||||
|
### Client
|
||||||
|
- Feat: プラグイン・テーマを外部サイトから直接インストールできるようになりました
|
||||||
|
- 外部サイトでの実装が必要です。詳細は Misskey Hub をご覧ください
|
||||||
|
https://misskey-hub.net/docs/advanced/publish-on-your-website.html
|
||||||
|
- Enhance: スワイプしてタイムラインを再読込できるように
|
||||||
|
- PCの場合は右上のボタンからでも再読込できます
|
||||||
|
- Enhance: タイムラインの自動更新を無効にできるように
|
||||||
|
- Enhance: 通知をグルーピングして表示するオプション(オプトアウト)
|
||||||
|
- Enhance: コードのシンタックスハイライトエンジンをShikiに変更
|
||||||
|
- AiScriptのシンタックスハイライトに対応
|
||||||
|
- MFMでAiScriptをハイライトする場合、コードブロックの開始部分を ` ```is ` もしくは ` ```aiscript ` としてください
|
||||||
|
- Enhance: データセーバー有効時はアニメーション付きのアバター画像が停止するように
|
||||||
|
- Enhance: プラグインを削除した際には、使用されていたアクセストークンも同時に削除されるようになりました
|
||||||
|
- Enhance: プラグインで`Plugin:register_note_view_interruptor`を用いてnoteの代わりにnullを返却することでノートを非表示にできるようになりました
|
||||||
|
- Enhance: AiScript関数`Mk:nyaize()`が追加されました
|
||||||
|
- Enhance: 情報→ツール はナビゲーションバーにツールとして独立した項目になりました
|
||||||
|
- Enhance: その他細かなブラッシュアップ
|
||||||
|
- Fix: 投稿フォームでのユーザー変更がプレビューに反映されない問題を修正
|
||||||
|
- Fix: ユーザーページの ノート > ファイル付き タブにリプライが表示されてしまう
|
||||||
|
- Fix: 「検索」MFMにおいて一部の検索キーワードが正しく認識されない問題を修正
|
||||||
|
- Fix: 一部の言語でMisskey Webがクラッシュする問題を修正
|
||||||
|
- Fix: チャンネルの作成・更新時に失敗した場合何も表示されない問題を修正 #11983
|
||||||
|
- Fix: 個人カードのemojiがバッテリーになっている問題を修正
|
||||||
|
- Fix: 標準テーマと同じIDを使用してインストールできてしまう問題を修正
|
||||||
|
|
||||||
|
### Server
|
||||||
|
- Enhance: RedisへのTLのキャッシュ(FTT)をオフにできるように
|
||||||
|
- Enhance: フォローしているチャンネルをフォロー解除した時(またはその逆)、タイムラインに反映される間隔を改善
|
||||||
|
- Enhance: プロフィールの自己紹介欄のMFMが連合するようになりました
|
||||||
|
- 相手がMisskey v2023.11.0以降である必要があります
|
||||||
|
- Enhance: チャンネル取得時のパフォーマンスを向上
|
||||||
|
- Fix: リストTLに自分のフォロワー限定投稿が含まれない問題を修正
|
||||||
|
- Fix: ローカルタイムラインに投稿者自身の投稿への返信が含まれない問題を修正
|
||||||
|
- Fix: 自分のフォローしているユーザーの自分のフォローしていないユーザーの visibility: followers な投稿への返信がストリーミングで流れてくる問題を修正
|
||||||
|
- Fix: RedisへのTLキャッシュが有効の場合にHTL/LTL/STLが空になることがある問題を修正
|
||||||
|
- Fix: STLでフォローしていないチャンネルが取得される問題を修正
|
||||||
|
- Fix: `hashtags/trend`にてRedisからトレンドの情報が取得できない際にInternal Server Errorになる問題を修正
|
||||||
|
- Fix: HTLをリロードまたは遡行したとき、フォローしているチャンネルのノートが含まれない問題を修正 #11765 #12181
|
||||||
|
- Fix: リノートをリノートできるのを修正
|
||||||
|
- Fix: アクセストークンを削除すると、通知が取得できなくなる場合がある問題を修正
|
||||||
|
- Fix: 自身の宛先なしダイレクト投稿がストリーミングで流れてこない問題を修正
|
||||||
|
- Fix: サーバーサイドからのテスト通知を正しく行えるように修正
|
||||||
|
|
||||||
|
## 2023.10.2
|
||||||
|
|
||||||
### General
|
### General
|
||||||
- Feat: アンテナでローカルの投稿のみ収集できるようになりました
|
- Feat: アンテナでローカルの投稿のみ収集できるようになりました
|
||||||
|
@@ -999,6 +999,7 @@ expired: "منتهية صلاحيته"
|
|||||||
icon: "الصورة الرمزية"
|
icon: "الصورة الرمزية"
|
||||||
replies: "رد"
|
replies: "رد"
|
||||||
renotes: "أعد النشر"
|
renotes: "أعد النشر"
|
||||||
|
flip: "اقلب"
|
||||||
_initialAccountSetting:
|
_initialAccountSetting:
|
||||||
accountCreated: "نجح إنشاء حسابك!"
|
accountCreated: "نجح إنشاء حسابك!"
|
||||||
letsStartAccountSetup: "إذا كنت جديدًا لنعدّ حسابك الشخصي."
|
letsStartAccountSetup: "إذا كنت جديدًا لنعدّ حسابك الشخصي."
|
||||||
|
@@ -840,6 +840,7 @@ youFollowing: "অনুসরণ করা হচ্ছে"
|
|||||||
icon: "প্রোফাইল ছবি"
|
icon: "প্রোফাইল ছবি"
|
||||||
replies: "জবাব"
|
replies: "জবাব"
|
||||||
renotes: "রিনোট"
|
renotes: "রিনোট"
|
||||||
|
flip: "উল্টান"
|
||||||
_role:
|
_role:
|
||||||
priority: "অগ্রাধিকার"
|
priority: "অগ্রাধিকার"
|
||||||
_priority:
|
_priority:
|
||||||
|
@@ -1096,6 +1096,7 @@ iHaveReadXCarefullyAndAgree: "Přečetl jsem si text \"{x}\" a souhlasím s ním
|
|||||||
icon: "Avatar"
|
icon: "Avatar"
|
||||||
replies: "Odpovědět"
|
replies: "Odpovědět"
|
||||||
renotes: "Přeposlat"
|
renotes: "Přeposlat"
|
||||||
|
flip: "Otočit"
|
||||||
_initialAccountSetting:
|
_initialAccountSetting:
|
||||||
accountCreated: "Váš účet byl úspěšně vytvořen!"
|
accountCreated: "Váš účet byl úspěšně vytvořen!"
|
||||||
letsStartAccountSetup: "Pro začátek si nastavte svůj profil."
|
letsStartAccountSetup: "Pro začátek si nastavte svůj profil."
|
||||||
|
@@ -1132,6 +1132,10 @@ mutualFollow: "Gegenseitig gefolgt"
|
|||||||
fileAttachedOnly: "Nur Notizen mit Dateien"
|
fileAttachedOnly: "Nur Notizen mit Dateien"
|
||||||
showRepliesToOthersInTimeline: "Antworten in Chronik anzeigen"
|
showRepliesToOthersInTimeline: "Antworten in Chronik anzeigen"
|
||||||
hideRepliesToOthersInTimeline: "Antworten nicht in Chronik anzeigen"
|
hideRepliesToOthersInTimeline: "Antworten nicht in Chronik anzeigen"
|
||||||
|
showRepliesToOthersInTimelineAll: "Antworten von allen momentan gefolgten Benutzern in Chronik anzeigen"
|
||||||
|
hideRepliesToOthersInTimelineAll: "Antworten von allen momentan gefolgten Benutzern nicht in Chronik anzeigen"
|
||||||
|
confirmShowRepliesAll: "Dies ist eine unwiderrufliche Aktion. Wirklich Antworten von allen momentan gefolgten Benutzern in der Chronik anzeigen?"
|
||||||
|
confirmHideRepliesAll: "Dies ist eine unwiderrufliche Aktion. Wirklich Antworten von allen momentan gefolgten Benutzern nicht in der Chronik anzeigen?"
|
||||||
externalServices: "Externe Dienste"
|
externalServices: "Externe Dienste"
|
||||||
impressum: "Impressum"
|
impressum: "Impressum"
|
||||||
impressumUrl: "Impressums-URL"
|
impressumUrl: "Impressums-URL"
|
||||||
@@ -1139,6 +1143,12 @@ impressumDescription: "In manchen Ländern, wie Deutschland und dessen Umgebung,
|
|||||||
privacyPolicy: "Datenschutzerklärung"
|
privacyPolicy: "Datenschutzerklärung"
|
||||||
privacyPolicyUrl: "Datenschutzerklärungs-URL"
|
privacyPolicyUrl: "Datenschutzerklärungs-URL"
|
||||||
tosAndPrivacyPolicy: "Nutzungsbedingungen und Datenschutzerklärung"
|
tosAndPrivacyPolicy: "Nutzungsbedingungen und Datenschutzerklärung"
|
||||||
|
avatarDecorations: "Profilbilddekoration"
|
||||||
|
attach: "Anbringen"
|
||||||
|
detach: "Entfernen"
|
||||||
|
angle: "Winkel"
|
||||||
|
flip: "Umdrehen"
|
||||||
|
showAvatarDecorations: "Profilbilddekoration anzeigen"
|
||||||
_announcement:
|
_announcement:
|
||||||
forExistingUsers: "Nur für existierende Nutzer"
|
forExistingUsers: "Nur für existierende Nutzer"
|
||||||
forExistingUsersDescription: "Ist diese Option aktiviert, wird diese Ankündigung nur Nutzern angezeigt, die zum Zeitpunkt der Ankündigung bereits registriert sind. Ist sie deaktiviert, wird sie auch Nutzern, die sich nach dessen Veröffentlichung registrieren, angezeigt."
|
forExistingUsersDescription: "Ist diese Option aktiviert, wird diese Ankündigung nur Nutzern angezeigt, die zum Zeitpunkt der Ankündigung bereits registriert sind. Ist sie deaktiviert, wird sie auch Nutzern, die sich nach dessen Veröffentlichung registrieren, angezeigt."
|
||||||
@@ -1174,6 +1184,7 @@ _serverSettings:
|
|||||||
manifestJsonOverride: "Überschreiben von manifest.json"
|
manifestJsonOverride: "Überschreiben von manifest.json"
|
||||||
shortName: "Abkürzung"
|
shortName: "Abkürzung"
|
||||||
shortNameDescription: "Ein Kürzel für den Namen der Instanz, der angezeigt werden kann, falls der volle Instanzname lang ist."
|
shortNameDescription: "Ein Kürzel für den Namen der Instanz, der angezeigt werden kann, falls der volle Instanzname lang ist."
|
||||||
|
fanoutTimelineDescription: "Ist diese Option aktiviert, kann eine erhebliche Verbesserung im Abrufen von Chroniken und eine Reduzierung der Datenbankbelastung erzielt werden, im Gegenzug zu einer Steigerung in der Speichernutzung von Redis. Bei geringem Serverspeicher oder Serverinstabilität kann diese Option deaktiviert werden."
|
||||||
_accountMigration:
|
_accountMigration:
|
||||||
moveFrom: "Von einem anderen Konto zu diesem migrieren"
|
moveFrom: "Von einem anderen Konto zu diesem migrieren"
|
||||||
moveFromSub: "Alias für ein anderes Konto erstellen"
|
moveFromSub: "Alias für ein anderes Konto erstellen"
|
||||||
@@ -2146,6 +2157,9 @@ _moderationLogTypes:
|
|||||||
createAd: "Werbung erstellt"
|
createAd: "Werbung erstellt"
|
||||||
deleteAd: "Werbung gelöscht"
|
deleteAd: "Werbung gelöscht"
|
||||||
updateAd: "Werbung aktualisiert"
|
updateAd: "Werbung aktualisiert"
|
||||||
|
createAvatarDecoration: "Profilbilddekoration erstellt"
|
||||||
|
updateAvatarDecoration: "Profilbilddekoration aktualisiert"
|
||||||
|
deleteAvatarDecoration: "Profilbilddekoration gelöscht"
|
||||||
_fileViewer:
|
_fileViewer:
|
||||||
title: "Dateiinformationen"
|
title: "Dateiinformationen"
|
||||||
type: "Dateityp"
|
type: "Dateityp"
|
||||||
@@ -2154,3 +2168,44 @@ _fileViewer:
|
|||||||
uploadedAt: "Hochgeladen am"
|
uploadedAt: "Hochgeladen am"
|
||||||
attachedNotes: "Zugehörige Notizen"
|
attachedNotes: "Zugehörige Notizen"
|
||||||
thisPageCanBeSeenFromTheAuthor: "Nur der Benutzer, der diese Datei hochgeladen hat, kann diese Seite sehen."
|
thisPageCanBeSeenFromTheAuthor: "Nur der Benutzer, der diese Datei hochgeladen hat, kann diese Seite sehen."
|
||||||
|
_externalResourceInstaller:
|
||||||
|
title: "Von externer Seite installieren"
|
||||||
|
checkVendorBeforeInstall: "Überprüfe vor Installation die Vertrauenswürdigkeit des Vertreibers."
|
||||||
|
_plugin:
|
||||||
|
title: "Möchtest du dieses Plugin installieren?"
|
||||||
|
metaTitle: "Plugininformation"
|
||||||
|
_theme:
|
||||||
|
title: "Möchten du dieses Farbschema installieren?"
|
||||||
|
metaTitle: "Farbschemainfo"
|
||||||
|
_meta:
|
||||||
|
base: "Farbschemavorlage"
|
||||||
|
_vendorInfo:
|
||||||
|
title: "Vertreiber"
|
||||||
|
endpoint: "Referenzierter Endpunkt"
|
||||||
|
hashVerify: "Hash-Verifikation"
|
||||||
|
_errors:
|
||||||
|
_invalidParams:
|
||||||
|
title: "Ungültige Parameter"
|
||||||
|
description: "Es fehlen Informationen zum Laden der externen Ressource. Überprüfe die übergebene URL."
|
||||||
|
_resourceTypeNotSupported:
|
||||||
|
title: "Diese Ressource wird nicht unterstützt"
|
||||||
|
description: "Dieser Ressourcentyp wird nicht unterstützt. Bitte kontaktiere den Seitenbesitzer."
|
||||||
|
_failedToFetch:
|
||||||
|
title: "Fehler beim Abrufen der Daten"
|
||||||
|
fetchErrorDescription: "Während der Kommunikation mit der externen Seite ist ein Fehler aufgetreten. Kontaktiere den Seitenbesitzer, falls ein erneutes Probieren dieses Problem nicht löst."
|
||||||
|
parseErrorDescription: "Während dem Auslesen der externen Daten ist ein Fehler aufgetreten. Kontaktiere den Seitenbesitzer."
|
||||||
|
_hashUnmatched:
|
||||||
|
title: "Datenverifizierung fehlgeschlagen"
|
||||||
|
description: "Die Integritätsprüfung der geladenen Daten ist fehlgeschlagen. Aus Sicherheitsgründen kann die Installation nicht fortgesetzt werden. Kontaktiere den Seitenbesitzer."
|
||||||
|
_pluginParseFailed:
|
||||||
|
title: "AiScript-Fehler"
|
||||||
|
description: "Die angeforderten Daten wurden erfolgreich abgerufen, jedoch trat während des AiScript-Parsings ein Fehler auf. Kontaktiere den Autor des Plugins. Detaillierte Fehlerinformationen können über die Javascript-Konsole abgerufen werden."
|
||||||
|
_pluginInstallFailed:
|
||||||
|
title: "Das Plugin konnte nicht installiert werden"
|
||||||
|
description: "Während der Installation des Plugin ist ein Problem aufgetreten. Bitte versuche es erneut. Detaillierte Fehlerinformationen können über die Javascript-Konsole abgerufen werden."
|
||||||
|
_themeParseFailed:
|
||||||
|
title: "Parsing des Farbschemas fehlgeschlagen"
|
||||||
|
description: "Die angeforderten Daten wurden erfolgreich abgerufen, jedoch trat während des Farbschema-Parsings ein Fehler auf. Kontaktiere den Autor des Farbschemas. Detaillierte Fehlerinformationen können über die Javascript-Konsole abgerufen werden."
|
||||||
|
_themeInstallFailed:
|
||||||
|
title: "Das Farbschema konnte nicht installiert werden"
|
||||||
|
description: "Während der Installation des Farbschemas ist ein Problem aufgetreten. Bitte versuche es erneut. Detaillierte Fehlerinformationen können über die Javascript-Konsole abgerufen werden."
|
||||||
|
@@ -1132,6 +1132,10 @@ mutualFollow: "Mutual follow"
|
|||||||
fileAttachedOnly: "Only notes with files"
|
fileAttachedOnly: "Only notes with files"
|
||||||
showRepliesToOthersInTimeline: "Show replies to others in timeline"
|
showRepliesToOthersInTimeline: "Show replies to others in timeline"
|
||||||
hideRepliesToOthersInTimeline: "Hide replies to others from timeline"
|
hideRepliesToOthersInTimeline: "Hide replies to others from timeline"
|
||||||
|
showRepliesToOthersInTimelineAll: "Show replies to others from everyone you follow in timeline"
|
||||||
|
hideRepliesToOthersInTimelineAll: "Hide replies to others from everyone you follow in timeline"
|
||||||
|
confirmShowRepliesAll: "This operation is irreversible. Would you really like to show replies to others from everyone you follow in your timeline?"
|
||||||
|
confirmHideRepliesAll: "This operation is irreversible. Would you really like to hide replies to others from everyone you follow in your timeline?"
|
||||||
externalServices: "External Services"
|
externalServices: "External Services"
|
||||||
impressum: "Impressum"
|
impressum: "Impressum"
|
||||||
impressumUrl: "Impressum URL"
|
impressumUrl: "Impressum URL"
|
||||||
@@ -1139,6 +1143,12 @@ impressumDescription: "In some countries, like germany, the inclusion of operato
|
|||||||
privacyPolicy: "Privacy Policy"
|
privacyPolicy: "Privacy Policy"
|
||||||
privacyPolicyUrl: "Privacy Policy URL"
|
privacyPolicyUrl: "Privacy Policy URL"
|
||||||
tosAndPrivacyPolicy: "Terms of Service and Privacy Policy"
|
tosAndPrivacyPolicy: "Terms of Service and Privacy Policy"
|
||||||
|
avatarDecorations: "Avatar decorations"
|
||||||
|
attach: "Attach"
|
||||||
|
detach: "Remove"
|
||||||
|
angle: "Angle"
|
||||||
|
flip: "Flip"
|
||||||
|
showAvatarDecorations: "Show avatar decorations"
|
||||||
_announcement:
|
_announcement:
|
||||||
forExistingUsers: "Existing users only"
|
forExistingUsers: "Existing users only"
|
||||||
forExistingUsersDescription: "This announcement will only be shown to users existing at the point of publishment if enabled. If disabled, those newly signing up after it has been posted will also see it."
|
forExistingUsersDescription: "This announcement will only be shown to users existing at the point of publishment if enabled. If disabled, those newly signing up after it has been posted will also see it."
|
||||||
@@ -1174,6 +1184,7 @@ _serverSettings:
|
|||||||
manifestJsonOverride: "manifest.json Override"
|
manifestJsonOverride: "manifest.json Override"
|
||||||
shortName: "Short name"
|
shortName: "Short name"
|
||||||
shortNameDescription: "A shorthand for the instance's name that can be displayed if the full official name is long."
|
shortNameDescription: "A shorthand for the instance's name that can be displayed if the full official name is long."
|
||||||
|
fanoutTimelineDescription: "Greatly increases performance of timeline retrieval and reduces load on the database when enabled. In exchange, memory usage of Redis will increase. Consider disabling this in case of low server memory or server instability."
|
||||||
_accountMigration:
|
_accountMigration:
|
||||||
moveFrom: "Migrate another account to this one"
|
moveFrom: "Migrate another account to this one"
|
||||||
moveFromSub: "Create alias to another account"
|
moveFromSub: "Create alias to another account"
|
||||||
@@ -2146,6 +2157,9 @@ _moderationLogTypes:
|
|||||||
createAd: "Ad created"
|
createAd: "Ad created"
|
||||||
deleteAd: "Ad deleted"
|
deleteAd: "Ad deleted"
|
||||||
updateAd: "Ad updated"
|
updateAd: "Ad updated"
|
||||||
|
createAvatarDecoration: "Avatar decoration created"
|
||||||
|
updateAvatarDecoration: "Avatar decoration updated"
|
||||||
|
deleteAvatarDecoration: "Avatar decoration deleted"
|
||||||
_fileViewer:
|
_fileViewer:
|
||||||
title: "File details"
|
title: "File details"
|
||||||
type: "File type"
|
type: "File type"
|
||||||
@@ -2154,3 +2168,44 @@ _fileViewer:
|
|||||||
uploadedAt: "Uploaded at"
|
uploadedAt: "Uploaded at"
|
||||||
attachedNotes: "Attached notes"
|
attachedNotes: "Attached notes"
|
||||||
thisPageCanBeSeenFromTheAuthor: "This page can only be seen by the user who uploaded this file."
|
thisPageCanBeSeenFromTheAuthor: "This page can only be seen by the user who uploaded this file."
|
||||||
|
_externalResourceInstaller:
|
||||||
|
title: "Install from external site"
|
||||||
|
checkVendorBeforeInstall: "Make sure the distributor of this resource is trustworthy before installation."
|
||||||
|
_plugin:
|
||||||
|
title: "Do you want to install this plugin?"
|
||||||
|
metaTitle: "Plugin information"
|
||||||
|
_theme:
|
||||||
|
title: "Do you want to install this theme?"
|
||||||
|
metaTitle: "Theme information"
|
||||||
|
_meta:
|
||||||
|
base: "Base color scheme"
|
||||||
|
_vendorInfo:
|
||||||
|
title: "Distributor information"
|
||||||
|
endpoint: "Referenced endpoint"
|
||||||
|
hashVerify: "Hash verification"
|
||||||
|
_errors:
|
||||||
|
_invalidParams:
|
||||||
|
title: "Invalid parameters"
|
||||||
|
description: "There is not enough information to load data from an external site. Please confirm the entered URL."
|
||||||
|
_resourceTypeNotSupported:
|
||||||
|
title: "This external resource is not supported"
|
||||||
|
description: "The type of this external resource is not supported. Please contact the site administrator."
|
||||||
|
_failedToFetch:
|
||||||
|
title: "Failed to fetch data"
|
||||||
|
fetchErrorDescription: "An error occurred communicating with the external site. If trying again does not fix this issue, please contact the site administrator."
|
||||||
|
parseErrorDescription: "An error occurred processing the data loaded from the external site. Please contact the site administrator."
|
||||||
|
_hashUnmatched:
|
||||||
|
title: "Data verification failed"
|
||||||
|
description: "An error occurred verifying the integrity of the fetched data. As a security measure, installation cannot continue. Please contact the site administrator."
|
||||||
|
_pluginParseFailed:
|
||||||
|
title: "AiScript Error"
|
||||||
|
description: "The requested data was fetched successfully, but an error occurred during AiScript parsing. Please contact the plugin author. Error details can be viewed in the Javascript console."
|
||||||
|
_pluginInstallFailed:
|
||||||
|
title: "Plugin installation failed"
|
||||||
|
description: "A problem occurred during plugin installation. Please try again. Error details can be viewed in the Javascript console."
|
||||||
|
_themeParseFailed:
|
||||||
|
title: "Theme parsing failed"
|
||||||
|
description: "The requested data was fetched successfully, but an error occurred during theme parsing. Please contact the theme author. Error details can be viewed in the Javascript console."
|
||||||
|
_themeInstallFailed:
|
||||||
|
title: "Failed to install theme"
|
||||||
|
description: "A problem occurred during theme installation. Please try again. Error details can be viewed in the Javascript console."
|
||||||
|
@@ -1139,6 +1139,7 @@ impressumDescription: "En algunos países, como Alemania, la inclusión del oper
|
|||||||
privacyPolicy: "Política de Privacidad"
|
privacyPolicy: "Política de Privacidad"
|
||||||
privacyPolicyUrl: "URL de la Política de Privacidad"
|
privacyPolicyUrl: "URL de la Política de Privacidad"
|
||||||
tosAndPrivacyPolicy: "Condiciones de Uso y Política de Privacidad"
|
tosAndPrivacyPolicy: "Condiciones de Uso y Política de Privacidad"
|
||||||
|
flip: "Echar de un capirotazo"
|
||||||
_announcement:
|
_announcement:
|
||||||
forExistingUsers: "Solo para usuarios registrados"
|
forExistingUsers: "Solo para usuarios registrados"
|
||||||
forExistingUsersDescription: "Este anuncio solo se mostrará a aquellos usuarios registrados en el momento de su publicación. Si se deshabilita esta opción, aquellos usuarios que se registren tras su publicación también lo verán."
|
forExistingUsersDescription: "Este anuncio solo se mostrará a aquellos usuarios registrados en el momento de su publicación. Si se deshabilita esta opción, aquellos usuarios que se registren tras su publicación también lo verán."
|
||||||
|
@@ -528,6 +528,7 @@ objectStorageSetPublicRead: "Régler sur « public » lors de l'envoi"
|
|||||||
serverLogs: "Journal du serveur"
|
serverLogs: "Journal du serveur"
|
||||||
deleteAll: "Supprimer tout"
|
deleteAll: "Supprimer tout"
|
||||||
showFixedPostForm: "Afficher le formulaire de publication en haut du fil d'actualité"
|
showFixedPostForm: "Afficher le formulaire de publication en haut du fil d'actualité"
|
||||||
|
withRepliesByDefaultForNewlyFollowed: "Afficher les réponses des nouvelles personnes que vous suivez dans le fil par défaut"
|
||||||
newNoteRecived: "Voir les nouvelles notes"
|
newNoteRecived: "Voir les nouvelles notes"
|
||||||
sounds: "Sons"
|
sounds: "Sons"
|
||||||
sound: "Sons"
|
sound: "Sons"
|
||||||
@@ -610,7 +611,7 @@ permission: "Autorisations "
|
|||||||
enableAll: "Tout activer"
|
enableAll: "Tout activer"
|
||||||
disableAll: "Tout désactiver"
|
disableAll: "Tout désactiver"
|
||||||
tokenRequested: "Autoriser l'accès au compte"
|
tokenRequested: "Autoriser l'accès au compte"
|
||||||
pluginTokenRequestedDescription: "Ce plugin pourra utiliser les autorisations définies ici."
|
pluginTokenRequestedDescription: "Cette extension pourra utiliser les autorisations définies ici."
|
||||||
notificationType: "Type de notifications"
|
notificationType: "Type de notifications"
|
||||||
edit: "Editer"
|
edit: "Editer"
|
||||||
emailServer: "Serveur de messagerie"
|
emailServer: "Serveur de messagerie"
|
||||||
@@ -972,6 +973,7 @@ manageCustomEmojis: "Gestion des émojis personnalisés"
|
|||||||
youCannotCreateAnymore: "Vous avez atteint la limite de création."
|
youCannotCreateAnymore: "Vous avez atteint la limite de création."
|
||||||
cannotPerformTemporary: "Temporairement indisponible"
|
cannotPerformTemporary: "Temporairement indisponible"
|
||||||
invalidParamError: "Paramètres invalides"
|
invalidParamError: "Paramètres invalides"
|
||||||
|
permissionDeniedError: "Opération refusée"
|
||||||
preset: "Préréglage"
|
preset: "Préréglage"
|
||||||
selectFromPresets: "Sélectionner à partir des préréglages"
|
selectFromPresets: "Sélectionner à partir des préréglages"
|
||||||
achievements: "Accomplissements"
|
achievements: "Accomplissements"
|
||||||
@@ -1023,7 +1025,11 @@ displayOfNote: "Affichage de la note"
|
|||||||
initialAccountSetting: "Réglage initial du profil"
|
initialAccountSetting: "Réglage initial du profil"
|
||||||
youFollowing: "Abonné·e"
|
youFollowing: "Abonné·e"
|
||||||
preventAiLearning: "Refuser l'usage dans l'apprentissage automatique d'IA générative"
|
preventAiLearning: "Refuser l'usage dans l'apprentissage automatique d'IA générative"
|
||||||
|
preventAiLearningDescription: "Demander aux robots d'indexation de ne pas utiliser le contenu publié, tel que les notes et les images, dans l'apprentissage automatique d'IA générative. Cela est réalisé en incluant le drapeau « noai » dans la réponse HTML. Une prévention complète n'est toutefois pas possible, car il est au robot d'indexation de respecter cette demande."
|
||||||
options: "Options"
|
options: "Options"
|
||||||
|
specifyUser: "Spécifier l'utilisateur"
|
||||||
|
failedToPreviewUrl: "Aperçu d'URL échoué"
|
||||||
|
update: "Mettre à jour"
|
||||||
later: "Plus tard"
|
later: "Plus tard"
|
||||||
goToMisskey: "Retour vers Misskey"
|
goToMisskey: "Retour vers Misskey"
|
||||||
expirationDate: "Date d’expiration"
|
expirationDate: "Date d’expiration"
|
||||||
@@ -1047,6 +1053,25 @@ notifyNotes: "Notifier à propos des nouvelles notes"
|
|||||||
authentication: "Authentification"
|
authentication: "Authentification"
|
||||||
authenticationRequiredToContinue: "Veuillez vous authentifier pour continuer"
|
authenticationRequiredToContinue: "Veuillez vous authentifier pour continuer"
|
||||||
showRenotes: "Afficher les renotes"
|
showRenotes: "Afficher les renotes"
|
||||||
|
showRepliesToOthersInTimeline: "Afficher les réponses aux autres dans le fil"
|
||||||
|
hideRepliesToOthersInTimeline: "Masquer les réponses aux autres dans le fil"
|
||||||
|
showRepliesToOthersInTimelineAll: "Afficher les réponses de toutes les personnes que vous suivez dans le fil"
|
||||||
|
hideRepliesToOthersInTimelineAll: "Masquer les réponses de toutes les personnes que vous suivez dans le fil"
|
||||||
|
confirmShowRepliesAll: "Cette opération est irréversible. Voulez-vous vraiment afficher les réponses de toutes les personnes que vous suivez dans le fil ?"
|
||||||
|
confirmHideRepliesAll: "Cette opération est irréversible. Voulez-vous vraiment masquer les réponses de toutes les personnes que vous suivez dans le fil ?"
|
||||||
|
externalServices: "Services externes"
|
||||||
|
impressum: "Impressum"
|
||||||
|
impressumUrl: "URL de l'impressum"
|
||||||
|
impressumDescription: "Dans certains pays comme l'Allemagne, il est obligatoire d'afficher les informations sur l'opérateur d'un site (un impressum)."
|
||||||
|
privacyPolicy: "Politique de confidentialité"
|
||||||
|
privacyPolicyUrl: "URL de la politique de confidentialité"
|
||||||
|
tosAndPrivacyPolicy: "Conditions d'utilisation et politique de confidentialité"
|
||||||
|
avatarDecorations: "Décorations d'avatar"
|
||||||
|
attach: "Mettre"
|
||||||
|
detach: "Enlever"
|
||||||
|
angle: "Angle"
|
||||||
|
flip: "Inverser"
|
||||||
|
showAvatarDecorations: "Afficher les décorations d'avatar"
|
||||||
_announcement:
|
_announcement:
|
||||||
readConfirmTitle: "Marquer comme lu ?"
|
readConfirmTitle: "Marquer comme lu ?"
|
||||||
_initialAccountSetting:
|
_initialAccountSetting:
|
||||||
@@ -1239,6 +1264,8 @@ _ad:
|
|||||||
back: "Retour"
|
back: "Retour"
|
||||||
reduceFrequencyOfThisAd: "Voir cette publicité moins souvent"
|
reduceFrequencyOfThisAd: "Voir cette publicité moins souvent"
|
||||||
hide: "Cacher "
|
hide: "Cacher "
|
||||||
|
adsSettings: "Réglages des publicités"
|
||||||
|
notesPerOneAd: "Intervalle de diffusion de publicités lors de la mise à jour en temps réel (nombre de notes par publicité)"
|
||||||
_forgotPassword:
|
_forgotPassword:
|
||||||
enterEmail: "Entrez ici l'adresse e-mail que vous avez enregistrée pour votre compte. Un lien vous permettant de réinitialiser votre mot de passe sera envoyé à cette adresse."
|
enterEmail: "Entrez ici l'adresse e-mail que vous avez enregistrée pour votre compte. Un lien vous permettant de réinitialiser votre mot de passe sera envoyé à cette adresse."
|
||||||
ifNoEmail: "Si vous n'avez pas enregistré d'adresse e-mail, merci de contacter l'administrateur·rice de votre instance."
|
ifNoEmail: "Si vous n'avez pas enregistré d'adresse e-mail, merci de contacter l'administrateur·rice de votre instance."
|
||||||
@@ -1254,9 +1281,9 @@ _email:
|
|||||||
_receiveFollowRequest:
|
_receiveFollowRequest:
|
||||||
title: "Vous avez reçu une demande de suivi"
|
title: "Vous avez reçu une demande de suivi"
|
||||||
_plugin:
|
_plugin:
|
||||||
install: "Installation de plugin"
|
install: "Installation d'extensions"
|
||||||
installWarn: "N’installez que des extensions provenant de sources de confiance."
|
installWarn: "N’installez que des extensions provenant de sources de confiance."
|
||||||
manage: "Gestion des plugins"
|
manage: "Gestion des extensions"
|
||||||
viewSource: "Afficher la source"
|
viewSource: "Afficher la source"
|
||||||
_preferencesBackups:
|
_preferencesBackups:
|
||||||
list: "Sauvegardes créées"
|
list: "Sauvegardes créées"
|
||||||
@@ -1737,5 +1764,85 @@ _webhookSettings:
|
|||||||
name: "Nom"
|
name: "Nom"
|
||||||
active: "Activé"
|
active: "Activé"
|
||||||
_moderationLogTypes:
|
_moderationLogTypes:
|
||||||
suspend: "Suspendre"
|
createRole: "Rôle créé"
|
||||||
resetPassword: "Réinitialiser le mot de passe"
|
deleteRole: "Rôle supprimé"
|
||||||
|
updateRole: "Rôle mis à jour"
|
||||||
|
assignRole: "Rôle attribué"
|
||||||
|
unassignRole: "Rôle enlevé"
|
||||||
|
suspend: "Utilisateur suspendu"
|
||||||
|
unsuspend: "Suspension d'un utilisateur levée"
|
||||||
|
addCustomEmoji: "Émoji personnalisé ajouté"
|
||||||
|
updateCustomEmoji: "Émoji personnalisé mis à jour"
|
||||||
|
deleteCustomEmoji: "Émoji personnalisé supprimé"
|
||||||
|
updateServerSettings: "Réglages du serveur mis à jour"
|
||||||
|
updateUserNote: "Note de modération mise à jour"
|
||||||
|
deleteDriveFile: "Fichier supprimé"
|
||||||
|
deleteNote: "Note supprimée"
|
||||||
|
createGlobalAnnouncement: "Annonce globale créée"
|
||||||
|
createUserAnnouncement: "Annonce individuelle créée"
|
||||||
|
updateGlobalAnnouncement: "Annonce globale mise à jour"
|
||||||
|
updateUserAnnouncement: "Annonce individuelle mise à jour"
|
||||||
|
deleteGlobalAnnouncement: "Annonce globale supprimée"
|
||||||
|
deleteUserAnnouncement: "Annonce individuelle supprimée"
|
||||||
|
resetPassword: "Mot de passe réinitialisé"
|
||||||
|
suspendRemoteInstance: "Instance distante suspendue"
|
||||||
|
unsuspendRemoteInstance: "Suspension d'une instance distante levée"
|
||||||
|
markSensitiveDriveFile: "Fichier marqué comme sensible"
|
||||||
|
unmarkSensitiveDriveFile: "Marquage du fichier comme sensible enlevé"
|
||||||
|
resolveAbuseReport: "Signalement résolu"
|
||||||
|
createInvitation: "Code d'invitation créé"
|
||||||
|
createAd: "Publicité créée"
|
||||||
|
deleteAd: "Publicité supprimée"
|
||||||
|
updateAd: "Publicité mise à jour"
|
||||||
|
createAvatarDecoration: "Décoration d'avatar créée"
|
||||||
|
updateAvatarDecoration: "Décoration d'avatar mise à jour"
|
||||||
|
deleteAvatarDecoration: "Décoration d'avatar supprimée"
|
||||||
|
_fileViewer:
|
||||||
|
title: "Détails du fichier"
|
||||||
|
type: "Type du fichier"
|
||||||
|
size: "Taille du fichier"
|
||||||
|
url: "URL"
|
||||||
|
uploadedAt: "Date de téléversement"
|
||||||
|
attachedNotes: "Notes avec ce fichier"
|
||||||
|
thisPageCanBeSeenFromTheAuthor: "Cette page ne peut être vue que par l'utilisateur qui a téléversé ce fichier."
|
||||||
|
_externalResourceInstaller:
|
||||||
|
title: "Installer depuis un site externe"
|
||||||
|
checkVendorBeforeInstall: "Veuillez confirmer que le distributeur est fiable avant l'installation."
|
||||||
|
_plugin:
|
||||||
|
title: "Voulez-vous installer cette extension ?"
|
||||||
|
metaTitle: "Informations sur l'extension"
|
||||||
|
_theme:
|
||||||
|
title: "Voulez-vous installer ce thème ?"
|
||||||
|
metaTitle: "Informations sur le thème"
|
||||||
|
_meta:
|
||||||
|
base: "Palette de couleurs de base"
|
||||||
|
_vendorInfo:
|
||||||
|
title: "Informations sur le distributeur"
|
||||||
|
endpoint: "Point de terminaison référencé"
|
||||||
|
hashVerify: "Vérification de l'intégrité du fichier"
|
||||||
|
_errors:
|
||||||
|
_invalidParams:
|
||||||
|
title: "Paramètres invalides"
|
||||||
|
description: "Il y a un manque d'informations nécessaires pour obtenir des données à partir de sites externes. Veuillez vérifier l'URL."
|
||||||
|
_resourceTypeNotSupported:
|
||||||
|
title: "Cette ressource externe n'est pas prise en charge."
|
||||||
|
description: "Le type de ressource obtenue à partir de ce site externe n'est pas pris en charge. Veuillez contacter l'administrateur du site."
|
||||||
|
_failedToFetch:
|
||||||
|
title: "Échec de récupération des données"
|
||||||
|
fetchErrorDescription: "La communication avec le site externe a échoué. Si vous réessayez et que cela ne s'améliore pas, veuillez contacter l'administrateur du site."
|
||||||
|
parseErrorDescription: "Les données obtenues à partir du site externe n'ont pas pu être parsées. Veuillez contacter l'administrateur du site."
|
||||||
|
_hashUnmatched:
|
||||||
|
title: "Échec de vérification des données"
|
||||||
|
description: "La vérification de l'intégrité des données fournies a échoué. Pour des raisons de sécurité, l'installation ne peut pas continuer. Veuillez contacter l'administrateur du site."
|
||||||
|
_pluginParseFailed:
|
||||||
|
title: "Erreur d'AiScript"
|
||||||
|
description: "Bien que les données aient été obtenues, elles n'ont pas pu être lues, car il y a eu une erreur lors du parsage d'AiScript. Veuillez contacter l'auteur de l'extension. Pour plus de détails sur l'erreur, veuillez consulter la console JavaScript."
|
||||||
|
_pluginInstallFailed:
|
||||||
|
title: "Échec d'installation de l'extension"
|
||||||
|
description: "Il y a eu un problème lors de l'installation de l'extension. Veuillez réessayer. Pour plus de détails sur l'erreur, veuillez consulter la console JavaScript."
|
||||||
|
_themeParseFailed:
|
||||||
|
title: "Erreur de parsage du thème"
|
||||||
|
description: "Bien que les données aient été obtenues, elles n'ont pas pu être lues, car il y a eu une erreur lors du parsage du fichier du thème. Veuillez contacter l'auteur du thème. Pour plus de détails sur l'erreur, veuillez consulter la console JavaScript."
|
||||||
|
_themeInstallFailed:
|
||||||
|
title: "Échec d'installation du thème"
|
||||||
|
description: "Il y a eu un problème lors de l'installation du thème. Veuillez réessayer. Pour plus de détails sur l'erreur, veuillez consulter la console JavaScript."
|
||||||
|
@@ -45,6 +45,7 @@ pin: "Sematkan ke profil"
|
|||||||
unpin: "Lepas sematan dari profil"
|
unpin: "Lepas sematan dari profil"
|
||||||
copyContent: "Salin konten"
|
copyContent: "Salin konten"
|
||||||
copyLink: "Salin tautan"
|
copyLink: "Salin tautan"
|
||||||
|
copyLinkRenote: "Salin tautan renote"
|
||||||
delete: "Hapus"
|
delete: "Hapus"
|
||||||
deleteAndEdit: "Hapus dan sunting"
|
deleteAndEdit: "Hapus dan sunting"
|
||||||
deleteAndEditConfirm: "Apakah kamu yakin ingin menghapus note ini dan menyuntingnya? Kamu akan kehilangan semua reaksi, renote dan balasan di note ini."
|
deleteAndEditConfirm: "Apakah kamu yakin ingin menghapus note ini dan menyuntingnya? Kamu akan kehilangan semua reaksi, renote dan balasan di note ini."
|
||||||
@@ -156,6 +157,7 @@ addEmoji: "Tambahkan emoji"
|
|||||||
settingGuide: "Pengaturan rekomendasi"
|
settingGuide: "Pengaturan rekomendasi"
|
||||||
cacheRemoteFiles: "Tembolokkan berkas dari instansi luar"
|
cacheRemoteFiles: "Tembolokkan berkas dari instansi luar"
|
||||||
cacheRemoteFilesDescription: "Ketika pengaturan ini dinonaktifkan, berkas dari instansi luar akan dimuat langsung. Menonaktifkan ini akan mengurangi penggunaan penyimpanan peladen, namun dapat menyebabkan peningkatan lalu lintas bandwidth, karena keluku tidak dihasilkan."
|
cacheRemoteFilesDescription: "Ketika pengaturan ini dinonaktifkan, berkas dari instansi luar akan dimuat langsung. Menonaktifkan ini akan mengurangi penggunaan penyimpanan peladen, namun dapat menyebabkan peningkatan lalu lintas bandwidth, karena keluku tidak dihasilkan."
|
||||||
|
youCanCleanRemoteFilesCache: "Kamu dapat mengosongkan tembolok dengan mengeklik tombol 🗑️ pada layar manajemen berkas."
|
||||||
cacheRemoteSensitiveFiles: "Tembolokkan berkas dari instansi luar"
|
cacheRemoteSensitiveFiles: "Tembolokkan berkas dari instansi luar"
|
||||||
cacheRemoteSensitiveFilesDescription: "Menonaktifkan pengaturan ini menyebabkan berkas sensitif dari instansi luar ditautkan secara langsung, bukan ditembolok."
|
cacheRemoteSensitiveFilesDescription: "Menonaktifkan pengaturan ini menyebabkan berkas sensitif dari instansi luar ditautkan secara langsung, bukan ditembolok."
|
||||||
flagAsBot: "Atur akun ini sebagai Bot"
|
flagAsBot: "Atur akun ini sebagai Bot"
|
||||||
@@ -193,6 +195,7 @@ perHour: "per Jam"
|
|||||||
perDay: "per Hari"
|
perDay: "per Hari"
|
||||||
stopActivityDelivery: "Berhenti mengirim aktivitas"
|
stopActivityDelivery: "Berhenti mengirim aktivitas"
|
||||||
blockThisInstance: "Blokir instansi ini"
|
blockThisInstance: "Blokir instansi ini"
|
||||||
|
silenceThisInstance: "Senyapkan instansi ini"
|
||||||
operations: "Tindakan"
|
operations: "Tindakan"
|
||||||
software: "Perangkat lunak"
|
software: "Perangkat lunak"
|
||||||
version: "Versi"
|
version: "Versi"
|
||||||
@@ -212,6 +215,8 @@ clearCachedFiles: "Hapus tembolok"
|
|||||||
clearCachedFilesConfirm: "Apakah kamu yakin ingin menghapus seluruh tembolok berkas instansi luar?"
|
clearCachedFilesConfirm: "Apakah kamu yakin ingin menghapus seluruh tembolok berkas instansi luar?"
|
||||||
blockedInstances: "Instansi terblokir"
|
blockedInstances: "Instansi terblokir"
|
||||||
blockedInstancesDescription: "Daftar nama host dari instansi yang diperlukan untuk diblokir. Instansi yang didaftarkan tidak akan dapat berkomunikasi dengan instansi ini."
|
blockedInstancesDescription: "Daftar nama host dari instansi yang diperlukan untuk diblokir. Instansi yang didaftarkan tidak akan dapat berkomunikasi dengan instansi ini."
|
||||||
|
silencedInstances: "Instansi yang disenyapkan"
|
||||||
|
silencedInstancesDescription: "Daftar nama host dari instansi yang ingin kamu senyapkan. Semua akun dari instansi yang terdaftar akan diperlakukan sebagai disenyapkan. Hal ini membuat akun hanya dapat membuat permintaan mengikuti, dan tidak dapat menyebutkan akun lokal apabila tidak mengikuti. Hal ini tidak akan mempengaruhi instansi yang diblokir."
|
||||||
muteAndBlock: "Bisukan / Blokir"
|
muteAndBlock: "Bisukan / Blokir"
|
||||||
mutedUsers: "Pengguna yang dibisukan"
|
mutedUsers: "Pengguna yang dibisukan"
|
||||||
blockedUsers: "Pengguna yang diblokir"
|
blockedUsers: "Pengguna yang diblokir"
|
||||||
@@ -409,10 +414,14 @@ aboutMisskey: "Tentang Misskey"
|
|||||||
administrator: "Admin"
|
administrator: "Admin"
|
||||||
token: "Token"
|
token: "Token"
|
||||||
2fa: "Autentikasi 2-faktor"
|
2fa: "Autentikasi 2-faktor"
|
||||||
|
setupOf2fa: "Atur autentikasi 2-faktor"
|
||||||
totp: "Aplikasi autentikator"
|
totp: "Aplikasi autentikator"
|
||||||
totpDescription: "Gunakan aplikasi autentikator untuk mendapatkan kata sandi sekali pakai"
|
totpDescription: "Gunakan aplikasi autentikator untuk mendapatkan kata sandi sekali pakai"
|
||||||
moderator: "Moderator"
|
moderator: "Moderator"
|
||||||
moderation: "Moderasi"
|
moderation: "Moderasi"
|
||||||
|
moderationNote: "Catatan moderasi"
|
||||||
|
addModerationNote: "Tambahkan catatan moderasi"
|
||||||
|
moderationLogs: "Log moderasi"
|
||||||
nUsersMentioned: "{n} pengguna disebut"
|
nUsersMentioned: "{n} pengguna disebut"
|
||||||
securityKeyAndPasskey: "Security key dan passkey"
|
securityKeyAndPasskey: "Security key dan passkey"
|
||||||
securityKey: "Kunci keamanan"
|
securityKey: "Kunci keamanan"
|
||||||
@@ -435,7 +444,7 @@ markAsReadAllTalkMessages: "Tandai semua pesan telah dibaca"
|
|||||||
help: "Bantuan"
|
help: "Bantuan"
|
||||||
inputMessageHere: "Ketik pesan disini"
|
inputMessageHere: "Ketik pesan disini"
|
||||||
close: "Tutup"
|
close: "Tutup"
|
||||||
invites: "Undang"
|
invites: "Undangan"
|
||||||
members: "Anggota"
|
members: "Anggota"
|
||||||
transfer: "Transfer"
|
transfer: "Transfer"
|
||||||
title: "Judul"
|
title: "Judul"
|
||||||
@@ -450,7 +459,7 @@ noMessagesYet: "Tidak ada pesan"
|
|||||||
newMessageExists: "Kamu mendapatkan pesan baru"
|
newMessageExists: "Kamu mendapatkan pesan baru"
|
||||||
onlyOneFileCanBeAttached: "Kamu hanya dapat melampirkan satu berkas ke dalam pesan"
|
onlyOneFileCanBeAttached: "Kamu hanya dapat melampirkan satu berkas ke dalam pesan"
|
||||||
signinRequired: "Silahkan login"
|
signinRequired: "Silahkan login"
|
||||||
invitations: "Undang"
|
invitations: "Undangan"
|
||||||
invitationCode: "Kode undangan"
|
invitationCode: "Kode undangan"
|
||||||
checking: "Memeriksa"
|
checking: "Memeriksa"
|
||||||
available: "Tersedia"
|
available: "Tersedia"
|
||||||
@@ -506,7 +515,7 @@ showFeaturedNotesInTimeline: "Tampilkan catatan yang diunggulkan di lini masa"
|
|||||||
objectStorage: "Object Storage"
|
objectStorage: "Object Storage"
|
||||||
useObjectStorage: "Gunakan object storage"
|
useObjectStorage: "Gunakan object storage"
|
||||||
objectStorageBaseUrl: "Base URL"
|
objectStorageBaseUrl: "Base URL"
|
||||||
objectStorageBaseUrlDesc: "Prefix URL digunakan untuk mengkonstruksi URL ke object (media) referencing. Tentukan URL jika kamu menggunakan CDN atau Proxy, jika tidak tentukan alamat yang dapat diakses secara publik sesuai dengan panduan dari layanan yang akan kamu gunakan, contohnya. 'https://<bucket>.s3.amazonaws.com' untuk AWS S3, dan 'https://storage.googleapis.com/<bucket>' untuk GCS."
|
objectStorageBaseUrlDesc: "Prefix URL digunakan untuk mengonstruksi URL ke object (media) referencing. Tentukan URL jika kamu menggunakan CDN atau Proxy. Jika tidak, tentukan alamat yang dapat diakses secara publik sesuai dengan panduan dari layanan yang akan kamu gunakan. Contohnya: 'https://<bucket>.s3.amazonaws.com' untuk AWS S3, dan 'https://storage.googleapis.com/<bucket>' untuk GCS."
|
||||||
objectStorageBucket: "Bucket"
|
objectStorageBucket: "Bucket"
|
||||||
objectStorageBucketDesc: "Mohon tentukan nama bucket yang digunakan pada layanan yang telah dikonfigurasi."
|
objectStorageBucketDesc: "Mohon tentukan nama bucket yang digunakan pada layanan yang telah dikonfigurasi."
|
||||||
objectStoragePrefix: "Prefix"
|
objectStoragePrefix: "Prefix"
|
||||||
@@ -523,8 +532,9 @@ objectStorageSetPublicRead: "Setel \"public-read\" disaat mengunggah"
|
|||||||
s3ForcePathStyleDesc: "Jika s3ForcePathStyle dinyalakan, nama bucket harus dimasukkan dalam path URL dan bukan URL nama host tersebut. Kamu perlu menyalakan pengaturan ini jika menggunakan layanan seperti instansi Minio yang self-hosted."
|
s3ForcePathStyleDesc: "Jika s3ForcePathStyle dinyalakan, nama bucket harus dimasukkan dalam path URL dan bukan URL nama host tersebut. Kamu perlu menyalakan pengaturan ini jika menggunakan layanan seperti instansi Minio yang self-hosted."
|
||||||
serverLogs: "Log Peladen"
|
serverLogs: "Log Peladen"
|
||||||
deleteAll: "Hapus semua"
|
deleteAll: "Hapus semua"
|
||||||
showFixedPostForm: "Tampilkan form posting di atas lini masa."
|
showFixedPostForm: "Tampilkan form posting di atas lini masa"
|
||||||
showFixedPostFormInChannel: "Tampilkan form posting di atas lini masa (Kanal)"
|
showFixedPostFormInChannel: "Tampilkan form posting di atas lini masa (Kanal)"
|
||||||
|
withRepliesByDefaultForNewlyFollowed: "Termasuk balasan dari pengguna baru yang diikuti pada lini masa secara bawaan"
|
||||||
newNoteRecived: "Kamu mendapat catatan baru"
|
newNoteRecived: "Kamu mendapat catatan baru"
|
||||||
sounds: "Bunyi"
|
sounds: "Bunyi"
|
||||||
sound: "Bunyi"
|
sound: "Bunyi"
|
||||||
@@ -627,7 +637,7 @@ testEmail: "Tes pengiriman surel"
|
|||||||
wordMute: "Bisukan kata"
|
wordMute: "Bisukan kata"
|
||||||
regexpError: "Kesalahan ekspresi reguler"
|
regexpError: "Kesalahan ekspresi reguler"
|
||||||
regexpErrorDescription: "Galat terjadi pada baris {line} ekspresi reguler dari {tab} kata yang dibisukan:"
|
regexpErrorDescription: "Galat terjadi pada baris {line} ekspresi reguler dari {tab} kata yang dibisukan:"
|
||||||
instanceMute: "Bisuka instansi"
|
instanceMute: "Bisukan instansi"
|
||||||
userSaysSomething: "{name} mengatakan sesuatu"
|
userSaysSomething: "{name} mengatakan sesuatu"
|
||||||
makeActive: "Aktifkan"
|
makeActive: "Aktifkan"
|
||||||
display: "Tampilkan"
|
display: "Tampilkan"
|
||||||
@@ -652,6 +662,7 @@ behavior: "Perilaku"
|
|||||||
sample: "Contoh"
|
sample: "Contoh"
|
||||||
abuseReports: "Laporkan"
|
abuseReports: "Laporkan"
|
||||||
reportAbuse: "Laporkan"
|
reportAbuse: "Laporkan"
|
||||||
|
reportAbuseRenote: "Laporkan renote"
|
||||||
reportAbuseOf: "Laporkan {name}"
|
reportAbuseOf: "Laporkan {name}"
|
||||||
fillAbuseReportDescription: "Mohon isi rincian laporan. Jika laporan ini mengenai catatan yang spesifik, mohon lampirkan serta URL catatan tersebut."
|
fillAbuseReportDescription: "Mohon isi rincian laporan. Jika laporan ini mengenai catatan yang spesifik, mohon lampirkan serta URL catatan tersebut."
|
||||||
abuseReported: "Laporan kamu telah dikirimkan. Terima kasih."
|
abuseReported: "Laporan kamu telah dikirimkan. Terima kasih."
|
||||||
@@ -704,6 +715,7 @@ lockedAccountInfo: "Kecuali kamu menyetel visibilitas catatan milikmu ke \"Hanya
|
|||||||
alwaysMarkSensitive: "Tandai media dalam catatan sebagai media sensitif"
|
alwaysMarkSensitive: "Tandai media dalam catatan sebagai media sensitif"
|
||||||
loadRawImages: "Tampilkan lampiran gambar secara penuh daripada thumbnail"
|
loadRawImages: "Tampilkan lampiran gambar secara penuh daripada thumbnail"
|
||||||
disableShowingAnimatedImages: "Jangan mainkan gambar bergerak"
|
disableShowingAnimatedImages: "Jangan mainkan gambar bergerak"
|
||||||
|
highlightSensitiveMedia: "Sorot media sensitif"
|
||||||
verificationEmailSent: "Surel verifikasi telah dikirimkan. Mohon akses tautan yang telah disertakan untuk menyelesaikan verifikasi."
|
verificationEmailSent: "Surel verifikasi telah dikirimkan. Mohon akses tautan yang telah disertakan untuk menyelesaikan verifikasi."
|
||||||
notSet: "Tidak disetel"
|
notSet: "Tidak disetel"
|
||||||
emailVerified: "Surel telah diverifikasi"
|
emailVerified: "Surel telah diverifikasi"
|
||||||
@@ -1018,6 +1030,7 @@ retryAllQueuesConfirmText: "Hal ini akan meningkatkan beban sementara ke peladen
|
|||||||
enableChartsForRemoteUser: "Buat bagan data pengguna instansi luar"
|
enableChartsForRemoteUser: "Buat bagan data pengguna instansi luar"
|
||||||
enableChartsForFederatedInstances: "Buat bagan data peladen instansi luar"
|
enableChartsForFederatedInstances: "Buat bagan data peladen instansi luar"
|
||||||
showClipButtonInNoteFooter: "Tambahkan \"Klip\" ke menu aksi catatan"
|
showClipButtonInNoteFooter: "Tambahkan \"Klip\" ke menu aksi catatan"
|
||||||
|
reactionsDisplaySize: "Ukuran tampilan reaksi"
|
||||||
noteIdOrUrl: "ID catatan atau URL"
|
noteIdOrUrl: "ID catatan atau URL"
|
||||||
video: "Video"
|
video: "Video"
|
||||||
videos: "Video"
|
videos: "Video"
|
||||||
@@ -1098,9 +1111,44 @@ icon: "Avatar"
|
|||||||
forYou: "Untuk Anda"
|
forYou: "Untuk Anda"
|
||||||
currentAnnouncements: "Pengumuman Saat Ini"
|
currentAnnouncements: "Pengumuman Saat Ini"
|
||||||
pastAnnouncements: "Pengumuman Terdahulu"
|
pastAnnouncements: "Pengumuman Terdahulu"
|
||||||
|
youHaveUnreadAnnouncements: "Terdapat pengumuman yang belum dibaca"
|
||||||
|
useSecurityKey: "Mohon ikuti instruksi peramban atau perangkat kamu untuk menggunakan kunci pengaman atau passkey."
|
||||||
replies: "Balas"
|
replies: "Balas"
|
||||||
renotes: "Renote"
|
renotes: "Renote"
|
||||||
|
loadReplies: "Tampilkan balasan"
|
||||||
|
loadConversation: "Tampilkan percakapan"
|
||||||
|
pinnedList: "Daftar yang dipin"
|
||||||
|
keepScreenOn: "Biarkan layar tetap menyala"
|
||||||
|
verifiedLink: "Tautan kepemilikan telah diverifikasi"
|
||||||
|
notifyNotes: "Beritahu mengenai catatan baru"
|
||||||
|
unnotifyNotes: "Berhenti memberitahu mengenai catatan baru"
|
||||||
|
authentication: "Autentikasi"
|
||||||
|
authenticationRequiredToContinue: "Mohon autentikasikan terlebih dahulu sebelum melanjutkan"
|
||||||
dateAndTime: "Tanggal dan Waktu"
|
dateAndTime: "Tanggal dan Waktu"
|
||||||
|
showRenotes: "Tampilkan renote"
|
||||||
|
edited: "Telah disunting"
|
||||||
|
notificationRecieveConfig: "Pengaturan notifikasi"
|
||||||
|
mutualFollow: "Saling mengikuti"
|
||||||
|
fileAttachedOnly: "Hanya catatan dengan berkas"
|
||||||
|
showRepliesToOthersInTimeline: "Tampilkan balasan ke pengguna lain dalam lini masa"
|
||||||
|
hideRepliesToOthersInTimeline: "Sembunyikan balasan ke orang lain dari lini masa"
|
||||||
|
externalServices: "Layanan eksternal"
|
||||||
|
impressum: "Impressum"
|
||||||
|
impressumUrl: "Tautan Impressum"
|
||||||
|
impressumDescription: "Pada beberapa negara seperti Jerman, inklusi dari informasi kontak operator (sebuah Impressum) diperlukan secara legal untuk situs web komersil."
|
||||||
|
privacyPolicy: "Kebijakan Privasi"
|
||||||
|
privacyPolicyUrl: "Tautan Kebijakan Privasi"
|
||||||
|
tosAndPrivacyPolicy: "Syarat dan Ketentuan serta Kebijakan Privasi"
|
||||||
|
flip: "Balik"
|
||||||
|
_announcement:
|
||||||
|
forExistingUsers: "Hanya pengguna yang telah ada"
|
||||||
|
forExistingUsersDescription: "Pengumuman ini akan dimunculkan ke pengguna yang sudah ada dari titik waktu publikasi jika dinyalakan. Apabila dimatikan, mereka yang baru mendaftar setelah publikasi ini akan juga melihatnya."
|
||||||
|
needConfirmationToRead: "Membutuhkan konfirmasi terpisah bahwa telah dibaca"
|
||||||
|
needConfirmationToReadDescription: "Permintaan terpisah untuk mengonfirmasi menandai pengumuman ini telah dibaca akan ditampilkan apabila fitur ini dinyalakan. Pengumuman ini juga akan dikecualikan dari fungsi \"Tandai semua telah dibaca\"."
|
||||||
|
end: "Arsipkan pengumuman"
|
||||||
|
tooManyActiveAnnouncementDescription: "Terlalu banyak pengumuman dapat memperburuk pengalaman pengguna. Mohon pertimbangkan untuk mengarsipkan pengumuman yang sudah usang/tidak relevan."
|
||||||
|
readConfirmTitle: "Tandai telah dibaca?"
|
||||||
|
readConfirmText: "Aksi ini akan menandai konten dari \"{title}\" telah dibaca."
|
||||||
_initialAccountSetting:
|
_initialAccountSetting:
|
||||||
accountCreated: "Akun kamu telah sukses dibuat!"
|
accountCreated: "Akun kamu telah sukses dibuat!"
|
||||||
letsStartAccountSetup: "Untuk pemula, ayo atur profilmu dulu."
|
letsStartAccountSetup: "Untuk pemula, ayo atur profilmu dulu."
|
||||||
@@ -1120,6 +1168,13 @@ _serverRules:
|
|||||||
description: "Daftar peraturan akan ditampilkan sebelum pendaftaran. Mengatur ringkasan dari Syarat dan Ketentuan sangat direkomendasikan."
|
description: "Daftar peraturan akan ditampilkan sebelum pendaftaran. Mengatur ringkasan dari Syarat dan Ketentuan sangat direkomendasikan."
|
||||||
_serverSettings:
|
_serverSettings:
|
||||||
iconUrl: "URL ikon"
|
iconUrl: "URL ikon"
|
||||||
|
appIconDescription: "Tentukan ikon yang digunakan ketika {host} ditampilkan sebagai aplikasi."
|
||||||
|
appIconUsageExample: "Contoh: Sebagai PWA, atau ketika ditampilkan sebagai markah layar beranda pada ponsel"
|
||||||
|
appIconStyleRecommendation: "Karena ikon berkemungkinan dipotong menjadi persegi atau lingkaran, ikon dengan margin terwanai di sekeliling konten sangat direkomendasikan."
|
||||||
|
appIconResolutionMustBe: "Minimum resolusi adalah {resolution}."
|
||||||
|
manifestJsonOverride: "Ambil alih manifest.json"
|
||||||
|
shortName: "Nama pendek"
|
||||||
|
shortNameDescription: "Inisial untuk nama instansi yang dapat ditampilkan apabila nama lengkap resmi terlalu panjang."
|
||||||
_accountMigration:
|
_accountMigration:
|
||||||
moveFrom: "Pindahkan akun lain ke akun ini"
|
moveFrom: "Pindahkan akun lain ke akun ini"
|
||||||
moveFromSub: "Buat alias ke akun lain"
|
moveFromSub: "Buat alias ke akun lain"
|
||||||
@@ -1374,6 +1429,9 @@ _achievements:
|
|||||||
title: "Brain Diver"
|
title: "Brain Diver"
|
||||||
description: "Posting tautan mengenai Brain Diver"
|
description: "Posting tautan mengenai Brain Diver"
|
||||||
flavor: "Misskey-Misskey La-Tu-Ma"
|
flavor: "Misskey-Misskey La-Tu-Ma"
|
||||||
|
_smashTestNotificationButton:
|
||||||
|
title: "Tes overflow"
|
||||||
|
description: "Picu tes notifikasi secara berulang dalam waktu yang sangat pendek"
|
||||||
_role:
|
_role:
|
||||||
new: "Buat peran"
|
new: "Buat peran"
|
||||||
edit: "Sunting peran"
|
edit: "Sunting peran"
|
||||||
@@ -1431,6 +1489,7 @@ _role:
|
|||||||
descriptionOfRateLimitFactor: "Batas kecepatan yang rendah tidak begitu membatasi, batas kecepatan tinggi lebih membatasi. "
|
descriptionOfRateLimitFactor: "Batas kecepatan yang rendah tidak begitu membatasi, batas kecepatan tinggi lebih membatasi. "
|
||||||
canHideAds: "Dapat menyembunyikan iklan"
|
canHideAds: "Dapat menyembunyikan iklan"
|
||||||
canSearchNotes: "Penggunaan pencarian catatan"
|
canSearchNotes: "Penggunaan pencarian catatan"
|
||||||
|
canUseTranslator: "Penggunaan penerjemah"
|
||||||
_condition:
|
_condition:
|
||||||
isLocal: "Pengguna lokal"
|
isLocal: "Pengguna lokal"
|
||||||
isRemote: "Pengguna remote"
|
isRemote: "Pengguna remote"
|
||||||
@@ -1479,6 +1538,10 @@ _ad:
|
|||||||
reduceFrequencyOfThisAd: "Tampilkan iklan ini lebih sedikit"
|
reduceFrequencyOfThisAd: "Tampilkan iklan ini lebih sedikit"
|
||||||
hide: "Jangan tampilkan"
|
hide: "Jangan tampilkan"
|
||||||
timezoneinfo: "Hari dalam satu minggu ditentukan dari zona waktu peladen."
|
timezoneinfo: "Hari dalam satu minggu ditentukan dari zona waktu peladen."
|
||||||
|
adsSettings: "Pengaturan iklan"
|
||||||
|
notesPerOneAd: "Interval penempatan pemutakhiran iklan secara real-time (catatan per iklan)"
|
||||||
|
setZeroToDisable: "Atur nilai ini ke 0 untuk menonaktifkan pemutakhiran iklan secara real-time"
|
||||||
|
adsTooClose: "Interval iklan saat ini kemungkinan memperburuk pengalaman pengguna secara signifikan karena diatur pada nilai yang terlalu rendah."
|
||||||
_forgotPassword:
|
_forgotPassword:
|
||||||
enterEmail: "Masukkan alamat surel yang kamu gunakan pada saat mendaftar. Sebuah tautan untuk mengatur ulang kata sandi kamu akan dikirimkan ke alamat surel tersebut."
|
enterEmail: "Masukkan alamat surel yang kamu gunakan pada saat mendaftar. Sebuah tautan untuk mengatur ulang kata sandi kamu akan dikirimkan ke alamat surel tersebut."
|
||||||
ifNoEmail: "Apabila kamu tidak menggunakan surel pada saat pendaftaran, mohon hubungi admin segera."
|
ifNoEmail: "Apabila kamu tidak menggunakan surel pada saat pendaftaran, mohon hubungi admin segera."
|
||||||
@@ -1673,17 +1736,19 @@ _timelineTutorial:
|
|||||||
step4_1: "Kamu dapat menyisipkan \"Reaksi\" ke dalam catatan."
|
step4_1: "Kamu dapat menyisipkan \"Reaksi\" ke dalam catatan."
|
||||||
step4_2: "Untuk menyisipkan reaksi, tekan tanda \"+\" dalam catatan dan pilih emoji yang kamu suka untuk mereaksi catatan tersebut."
|
step4_2: "Untuk menyisipkan reaksi, tekan tanda \"+\" dalam catatan dan pilih emoji yang kamu suka untuk mereaksi catatan tersebut."
|
||||||
_2fa:
|
_2fa:
|
||||||
alreadyRegistered: "Kamu telah mendaftarkan perangkat otentikasi dua faktor."
|
alreadyRegistered: "Kamu telah mendaftarkan perangkat autentikasi 2-faktor."
|
||||||
registerTOTP: "Daftarkan aplikasi autentikator"
|
registerTOTP: "Daftarkan aplikasi autentikator"
|
||||||
step1: "Pertama, pasang aplikasi otentikasi (seperti {a} atau {b}) di perangkat kamu."
|
step1: "Pertama, pasang aplikasi autentikasi (seperti {a} atau {b}) di perangkat kamu."
|
||||||
step2: "Lalu, pindai kode QR yang ada di layar."
|
step2: "Lalu, pindai kode QR yang ada di layar."
|
||||||
step2Click: "Mengeklik kode QR ini akan membolehkanmu untuk mendaftarkan 2FA ke security-key atau aplikasi autentikator ponsel."
|
step2Click: "Mengeklik kode QR ini akan membolehkanmu untuk mendaftarkan 2FA ke security-key atau aplikasi autentikator ponsel."
|
||||||
|
step2Uri: "Masukkan URI berikut jika kamu menggunakan program desktop"
|
||||||
step3Title: "Masukkan kode autentikasi"
|
step3Title: "Masukkan kode autentikasi"
|
||||||
step3: "Masukkan token yang telah disediakan oleh aplikasimu untuk menyelesaikan pemasangan."
|
step3: "Masukkan token yang telah disediakan oleh aplikasimu untuk menyelesaikan pemasangan."
|
||||||
step4: "Mulai sekarang, upaya login apapun akan meminta token login dari aplikasi otentikasi kamu."
|
setupCompleted: "Penyetelan autentikasi 2-faktor selesai"
|
||||||
|
step4: "Mulai sekarang, upaya login apapun akan meminta token login dari aplikasi autentikasi kamu."
|
||||||
securityKeyNotSupported: "Peramban kamu tidak mendukung security key."
|
securityKeyNotSupported: "Peramban kamu tidak mendukung security key."
|
||||||
registerTOTPBeforeKey: "Mohon atur aplikasi autentikator untuk mendaftarkan security key atau passkey."
|
registerTOTPBeforeKey: "Mohon atur aplikasi autentikator untuk mendaftarkan security key atau passkey."
|
||||||
securityKeyInfo: "Kamu dapat memasang otentikasi WebAuthN untuk mengamankan proses login lebih lanjut dengan tidak hanya perangkat keras kunci keamanan yang mendukung FIDO2, namun juga sidik jari atau otentikasi PIN pada perangkatmu."
|
securityKeyInfo: "Kamu dapat memasang autentikasi WebAuthN untuk mengamankan proses login lebih lanjut dengan tidak hanya perangkat keras kunci keamanan yang mendukung FIDO2, namun juga sidik jari atau autentikasi PIN pada perangkatmu."
|
||||||
registerSecurityKey: "Daftarkan security key atau passkey."
|
registerSecurityKey: "Daftarkan security key atau passkey."
|
||||||
securityKeyName: "Masukkan nama key."
|
securityKeyName: "Masukkan nama key."
|
||||||
tapSecurityKey: "Mohon ikuti peramban kamu untuk mendaftarkan security key atau passkey"
|
tapSecurityKey: "Mohon ikuti peramban kamu untuk mendaftarkan security key atau passkey"
|
||||||
@@ -1694,7 +1759,11 @@ _2fa:
|
|||||||
renewTOTPConfirm: "Hal ini akan menyebabkan kode verifikasi dari aplikasi autentikator sebelumnya berhenti bekerja"
|
renewTOTPConfirm: "Hal ini akan menyebabkan kode verifikasi dari aplikasi autentikator sebelumnya berhenti bekerja"
|
||||||
renewTOTPOk: "Atur ulang"
|
renewTOTPOk: "Atur ulang"
|
||||||
renewTOTPCancel: "Tidak sekarang."
|
renewTOTPCancel: "Tidak sekarang."
|
||||||
|
checkBackupCodesBeforeCloseThisWizard: "Sebelum kamu menutup jendela ini, pastikan untuk memperhatikan dan mencadangkan kode cadangan berikut."
|
||||||
backupCodes: "Kode Pencadangan"
|
backupCodes: "Kode Pencadangan"
|
||||||
|
backupCodesDescription: "Kamu dapat menggunakan kode ini untuk mendapatkan akses ke akun kamu apabila berada dalam situasi tidak dapat menggunakan aplikasi autentikasi 2-faktor yang kamu miliki. Setiap kode hanya dapat digunakan satu kali. Mohon simpan kode ini di tempat yang aman."
|
||||||
|
backupCodeUsedWarning: "Kode cadangan telah digunakan. Mohon mengatur ulang autentikasi 2-faktor secepatnya apabila kamu sudah tidak dapat menggunakannya lagi."
|
||||||
|
backupCodesExhaustedWarning: "Semua kode cadangan telah digunakan. Apabila kamu kehilangan akses pada aplikasi autentikasi 2-faktor milikmu, kamu tidak dapat mengakses akun ini lagi. Mohon atur ulang autentikasi 2-faktor kamu."
|
||||||
_permissions:
|
_permissions:
|
||||||
"read:account": "Lihat informasi akun"
|
"read:account": "Lihat informasi akun"
|
||||||
"write:account": "Sunting informasi akun"
|
"write:account": "Sunting informasi akun"
|
||||||
@@ -1728,6 +1797,10 @@ _permissions:
|
|||||||
"write:gallery": "Sunting galeri"
|
"write:gallery": "Sunting galeri"
|
||||||
"read:gallery-likes": "Lihat daftar postingan galeri yang disukai"
|
"read:gallery-likes": "Lihat daftar postingan galeri yang disukai"
|
||||||
"write:gallery-likes": "Sunting daftar postingan galeri yang disukai"
|
"write:gallery-likes": "Sunting daftar postingan galeri yang disukai"
|
||||||
|
"read:flash": "Lihat Play"
|
||||||
|
"write:flash": "Sunting Play"
|
||||||
|
"read:flash-likes": "Lihat daftar Play yang disukai"
|
||||||
|
"write:flash-likes": "Sunting daftar Play yang disukai"
|
||||||
_auth:
|
_auth:
|
||||||
shareAccessTitle: "Mendapatkan ijin akses aplikasi"
|
shareAccessTitle: "Mendapatkan ijin akses aplikasi"
|
||||||
shareAccess: "Apakah kamu ingin mengijinkan \"{name}\" untuk mengakses akun ini?"
|
shareAccess: "Apakah kamu ingin mengijinkan \"{name}\" untuk mengakses akun ini?"
|
||||||
@@ -1743,6 +1816,7 @@ _antennaSources:
|
|||||||
homeTimeline: "Catatan dari pengguna yang diikuti"
|
homeTimeline: "Catatan dari pengguna yang diikuti"
|
||||||
users: "Catatan dari pengguna tertentu"
|
users: "Catatan dari pengguna tertentu"
|
||||||
userList: "Catatan dari daftar tertentu"
|
userList: "Catatan dari daftar tertentu"
|
||||||
|
userBlacklist: "Semua catatan kecuali untuk satu pengguna atau lebih yang telah ditentukan"
|
||||||
_weekday:
|
_weekday:
|
||||||
sunday: "Minggu"
|
sunday: "Minggu"
|
||||||
monday: "Senin"
|
monday: "Senin"
|
||||||
@@ -1842,6 +1916,7 @@ _profile:
|
|||||||
metadataContent: "Isi"
|
metadataContent: "Isi"
|
||||||
changeAvatar: "Ubah avatar"
|
changeAvatar: "Ubah avatar"
|
||||||
changeBanner: "Ubah header"
|
changeBanner: "Ubah header"
|
||||||
|
verifiedLinkDescription: "Dengan memasukkan URL yang mengandung tautan ke profil kamu di sini, ikon verifikasi kepemilikan dapat ditampilkan di sebelah kolom ini."
|
||||||
_exportOrImport:
|
_exportOrImport:
|
||||||
allNotes: "Semua catatan"
|
allNotes: "Semua catatan"
|
||||||
favoritedNotes: "Catatan favorit"
|
favoritedNotes: "Catatan favorit"
|
||||||
@@ -1851,6 +1926,7 @@ _exportOrImport:
|
|||||||
userLists: "Daftar"
|
userLists: "Daftar"
|
||||||
excludeMutingUsers: "Kecualikan pengguna yang dibisukan"
|
excludeMutingUsers: "Kecualikan pengguna yang dibisukan"
|
||||||
excludeInactiveUsers: "Kecualikan pengguna tidak aktif"
|
excludeInactiveUsers: "Kecualikan pengguna tidak aktif"
|
||||||
|
withReplies: "Termasuk balasan dari pengguna yang diimpor ke dalam lini masa"
|
||||||
_charts:
|
_charts:
|
||||||
federation: "Federasi"
|
federation: "Federasi"
|
||||||
apRequest: "Permintaan"
|
apRequest: "Permintaan"
|
||||||
@@ -1960,11 +2036,17 @@ _notification:
|
|||||||
youReceivedFollowRequest: "Kamu menerima permintaan mengikuti"
|
youReceivedFollowRequest: "Kamu menerima permintaan mengikuti"
|
||||||
yourFollowRequestAccepted: "Permintaan mengikuti kamu telah diterima"
|
yourFollowRequestAccepted: "Permintaan mengikuti kamu telah diterima"
|
||||||
pollEnded: "Hasil Kuesioner telah keluar"
|
pollEnded: "Hasil Kuesioner telah keluar"
|
||||||
|
newNote: "Catatan baru"
|
||||||
unreadAntennaNote: "Antena {name}"
|
unreadAntennaNote: "Antena {name}"
|
||||||
emptyPushNotificationMessage: "Pembaruan notifikasi dorong"
|
emptyPushNotificationMessage: "Pembaruan notifikasi dorong"
|
||||||
achievementEarned: "Pencapaian didapatkan"
|
achievementEarned: "Pencapaian didapatkan"
|
||||||
|
testNotification: "Tes notifikasi"
|
||||||
|
checkNotificationBehavior: "Cek tampilan notifikasi"
|
||||||
|
sendTestNotification: "Kirim tes notifikasi"
|
||||||
|
notificationWillBeDisplayedLikeThis: "Notifikasi akan terlihat seperti ini"
|
||||||
_types:
|
_types:
|
||||||
all: "Semua"
|
all: "Semua"
|
||||||
|
note: "Catatan baru"
|
||||||
follow: "Ikuti"
|
follow: "Ikuti"
|
||||||
mention: "Sebut"
|
mention: "Sebut"
|
||||||
reply: "Balasan"
|
reply: "Balasan"
|
||||||
@@ -1998,6 +2080,8 @@ _deck:
|
|||||||
introduction2: "Klik \"+\" pada kanan layar untuk menambahkan kolom baru kapanpun yang kamu mau."
|
introduction2: "Klik \"+\" pada kanan layar untuk menambahkan kolom baru kapanpun yang kamu mau."
|
||||||
widgetsIntroduction: "Mohon pilih \"Sunting gawit\" pada menu kolom dan tambahkan gawit."
|
widgetsIntroduction: "Mohon pilih \"Sunting gawit\" pada menu kolom dan tambahkan gawit."
|
||||||
useSimpleUiForNonRootPages: "Gunakan antarmuka sederhana ke halaman yang dituju"
|
useSimpleUiForNonRootPages: "Gunakan antarmuka sederhana ke halaman yang dituju"
|
||||||
|
usedAsMinWidthWhenFlexible: "Lebar minimum akan digunakan untuk ini ketika opsi \"Atur-otomatis lebar\" dinyalakan"
|
||||||
|
flexible: "Atur-otomatis lebar"
|
||||||
_columns:
|
_columns:
|
||||||
main: "Utama"
|
main: "Utama"
|
||||||
widgets: "Widget"
|
widgets: "Widget"
|
||||||
@@ -2033,6 +2117,41 @@ _webhookSettings:
|
|||||||
reaction: "Ketika menerima reaksi"
|
reaction: "Ketika menerima reaksi"
|
||||||
mention: "Ketika sedang disebut"
|
mention: "Ketika sedang disebut"
|
||||||
_moderationLogTypes:
|
_moderationLogTypes:
|
||||||
|
createRole: "Peran telah dibuat"
|
||||||
|
deleteRole: "Peran telah dihapus"
|
||||||
|
updateRole: "Peran telah diperbaharui"
|
||||||
|
assignRole: "Yang ditugaskan dalam peran"
|
||||||
|
unassignRole: "Dihapus dari peran"
|
||||||
suspend: "Tangguhkan"
|
suspend: "Tangguhkan"
|
||||||
|
unsuspend: "Batal ditangguhkan"
|
||||||
|
addCustomEmoji: "Emoji kustom ditambahkan"
|
||||||
|
updateCustomEmoji: "Emoji kustom diperbaharui"
|
||||||
|
deleteCustomEmoji: "Emoji kustom dihapus"
|
||||||
|
updateServerSettings: "Pengaturan peladen diperbaharui"
|
||||||
|
updateUserNote: "Catatan moderasi diperbaharui"
|
||||||
|
deleteDriveFile: "Berkas dihapus"
|
||||||
|
deleteNote: "Catatan dihapus"
|
||||||
|
createGlobalAnnouncement: "Pengumuman global dibuat"
|
||||||
|
createUserAnnouncement: "Pengumuman pengguna dibuat"
|
||||||
|
updateGlobalAnnouncement: "Pengumuman global diperbaharui"
|
||||||
|
updateUserAnnouncement: "Pengumuman pengguna diperbaharui"
|
||||||
|
deleteGlobalAnnouncement: "Pengumuman global telah dihapus"
|
||||||
|
deleteUserAnnouncement: "Pengumuman pengguna telah dihapus."
|
||||||
resetPassword: "Atur ulang kata sandi"
|
resetPassword: "Atur ulang kata sandi"
|
||||||
|
suspendRemoteInstance: "Instansi luar telah ditangguhkan"
|
||||||
|
unsuspendRemoteInstance: "Instansi luar batal ditangguhkan"
|
||||||
|
markSensitiveDriveFile: "Berkas ditandai sensitif"
|
||||||
|
unmarkSensitiveDriveFile: "Berkas batal ditandai sensitif"
|
||||||
|
resolveAbuseReport: "Laporan terselesaikan"
|
||||||
createInvitation: "Buat kode undangan"
|
createInvitation: "Buat kode undangan"
|
||||||
|
createAd: "Iklan telah dibuat"
|
||||||
|
deleteAd: "Iklan telah dihapus"
|
||||||
|
updateAd: "Iklan telah diperbaharui"
|
||||||
|
_fileViewer:
|
||||||
|
title: "Rincian berkas"
|
||||||
|
type: "Jenis berkas"
|
||||||
|
size: "Ukuran berkas"
|
||||||
|
url: "URL"
|
||||||
|
uploadedAt: "Diunggah pada"
|
||||||
|
attachedNotes: "Catatan yang dilampirkan"
|
||||||
|
thisPageCanBeSeenFromTheAuthor: "Halaman ini hanya dapat dilihat oleh pengguna yang mengunggah bekas ini."
|
||||||
|
80
locales/index.d.ts
vendored
80
locales/index.d.ts
vendored
@@ -982,6 +982,7 @@ export interface Locale {
|
|||||||
"unassign": string;
|
"unassign": string;
|
||||||
"color": string;
|
"color": string;
|
||||||
"manageCustomEmojis": string;
|
"manageCustomEmojis": string;
|
||||||
|
"manageAvatarDecorations": string;
|
||||||
"youCannotCreateAnymore": string;
|
"youCannotCreateAnymore": string;
|
||||||
"cannotPerformTemporary": string;
|
"cannotPerformTemporary": string;
|
||||||
"cannotPerformTemporaryDescription": string;
|
"cannotPerformTemporaryDescription": string;
|
||||||
@@ -1135,6 +1136,10 @@ export interface Locale {
|
|||||||
"fileAttachedOnly": string;
|
"fileAttachedOnly": string;
|
||||||
"showRepliesToOthersInTimeline": string;
|
"showRepliesToOthersInTimeline": string;
|
||||||
"hideRepliesToOthersInTimeline": string;
|
"hideRepliesToOthersInTimeline": string;
|
||||||
|
"showRepliesToOthersInTimelineAll": string;
|
||||||
|
"hideRepliesToOthersInTimelineAll": string;
|
||||||
|
"confirmShowRepliesAll": string;
|
||||||
|
"confirmHideRepliesAll": string;
|
||||||
"externalServices": string;
|
"externalServices": string;
|
||||||
"impressum": string;
|
"impressum": string;
|
||||||
"impressumUrl": string;
|
"impressumUrl": string;
|
||||||
@@ -1142,6 +1147,17 @@ export interface Locale {
|
|||||||
"privacyPolicy": string;
|
"privacyPolicy": string;
|
||||||
"privacyPolicyUrl": string;
|
"privacyPolicyUrl": string;
|
||||||
"tosAndPrivacyPolicy": string;
|
"tosAndPrivacyPolicy": string;
|
||||||
|
"avatarDecorations": string;
|
||||||
|
"attach": string;
|
||||||
|
"detach": string;
|
||||||
|
"angle": string;
|
||||||
|
"flip": string;
|
||||||
|
"showAvatarDecorations": string;
|
||||||
|
"releaseToRefresh": string;
|
||||||
|
"refreshing": string;
|
||||||
|
"pullDownToRefresh": string;
|
||||||
|
"disableStreamingTimeline": string;
|
||||||
|
"useGroupedNotifications": string;
|
||||||
"_announcement": {
|
"_announcement": {
|
||||||
"forExistingUsers": string;
|
"forExistingUsers": string;
|
||||||
"forExistingUsersDescription": string;
|
"forExistingUsersDescription": string;
|
||||||
@@ -1180,6 +1196,7 @@ export interface Locale {
|
|||||||
"manifestJsonOverride": string;
|
"manifestJsonOverride": string;
|
||||||
"shortName": string;
|
"shortName": string;
|
||||||
"shortNameDescription": string;
|
"shortNameDescription": string;
|
||||||
|
"fanoutTimelineDescription": string;
|
||||||
};
|
};
|
||||||
"_accountMigration": {
|
"_accountMigration": {
|
||||||
"moveFrom": string;
|
"moveFrom": string;
|
||||||
@@ -1560,6 +1577,7 @@ export interface Locale {
|
|||||||
"inviteLimitCycle": string;
|
"inviteLimitCycle": string;
|
||||||
"inviteExpirationTime": string;
|
"inviteExpirationTime": string;
|
||||||
"canManageCustomEmojis": string;
|
"canManageCustomEmojis": string;
|
||||||
|
"canManageAvatarDecorations": string;
|
||||||
"driveCapacity": string;
|
"driveCapacity": string;
|
||||||
"alwaysMarkNsfw": string;
|
"alwaysMarkNsfw": string;
|
||||||
"pinMax": string;
|
"pinMax": string;
|
||||||
@@ -1696,6 +1714,7 @@ export interface Locale {
|
|||||||
"donate": string;
|
"donate": string;
|
||||||
"morePatrons": string;
|
"morePatrons": string;
|
||||||
"patrons": string;
|
"patrons": string;
|
||||||
|
"projectMembers": string;
|
||||||
};
|
};
|
||||||
"_displayOfSensitiveMedia": {
|
"_displayOfSensitiveMedia": {
|
||||||
"respect": string;
|
"respect": string;
|
||||||
@@ -2182,6 +2201,9 @@ export interface Locale {
|
|||||||
"checkNotificationBehavior": string;
|
"checkNotificationBehavior": string;
|
||||||
"sendTestNotification": string;
|
"sendTestNotification": string;
|
||||||
"notificationWillBeDisplayedLikeThis": string;
|
"notificationWillBeDisplayedLikeThis": string;
|
||||||
|
"reactedBySomeUsers": string;
|
||||||
|
"renotedBySomeUsers": string;
|
||||||
|
"followedBySomeUsers": string;
|
||||||
"_types": {
|
"_types": {
|
||||||
"all": string;
|
"all": string;
|
||||||
"note": string;
|
"note": string;
|
||||||
@@ -2295,6 +2317,9 @@ export interface Locale {
|
|||||||
"createAd": string;
|
"createAd": string;
|
||||||
"deleteAd": string;
|
"deleteAd": string;
|
||||||
"updateAd": string;
|
"updateAd": string;
|
||||||
|
"createAvatarDecoration": string;
|
||||||
|
"updateAvatarDecoration": string;
|
||||||
|
"deleteAvatarDecoration": string;
|
||||||
};
|
};
|
||||||
"_fileViewer": {
|
"_fileViewer": {
|
||||||
"title": string;
|
"title": string;
|
||||||
@@ -2305,6 +2330,61 @@ export interface Locale {
|
|||||||
"attachedNotes": string;
|
"attachedNotes": string;
|
||||||
"thisPageCanBeSeenFromTheAuthor": string;
|
"thisPageCanBeSeenFromTheAuthor": string;
|
||||||
};
|
};
|
||||||
|
"_externalResourceInstaller": {
|
||||||
|
"title": string;
|
||||||
|
"checkVendorBeforeInstall": string;
|
||||||
|
"_plugin": {
|
||||||
|
"title": string;
|
||||||
|
"metaTitle": string;
|
||||||
|
};
|
||||||
|
"_theme": {
|
||||||
|
"title": string;
|
||||||
|
"metaTitle": string;
|
||||||
|
};
|
||||||
|
"_meta": {
|
||||||
|
"base": string;
|
||||||
|
};
|
||||||
|
"_vendorInfo": {
|
||||||
|
"title": string;
|
||||||
|
"endpoint": string;
|
||||||
|
"hashVerify": string;
|
||||||
|
};
|
||||||
|
"_errors": {
|
||||||
|
"_invalidParams": {
|
||||||
|
"title": string;
|
||||||
|
"description": string;
|
||||||
|
};
|
||||||
|
"_resourceTypeNotSupported": {
|
||||||
|
"title": string;
|
||||||
|
"description": string;
|
||||||
|
};
|
||||||
|
"_failedToFetch": {
|
||||||
|
"title": string;
|
||||||
|
"fetchErrorDescription": string;
|
||||||
|
"parseErrorDescription": string;
|
||||||
|
};
|
||||||
|
"_hashUnmatched": {
|
||||||
|
"title": string;
|
||||||
|
"description": string;
|
||||||
|
};
|
||||||
|
"_pluginParseFailed": {
|
||||||
|
"title": string;
|
||||||
|
"description": string;
|
||||||
|
};
|
||||||
|
"_pluginInstallFailed": {
|
||||||
|
"title": string;
|
||||||
|
"description": string;
|
||||||
|
};
|
||||||
|
"_themeParseFailed": {
|
||||||
|
"title": string;
|
||||||
|
"description": string;
|
||||||
|
};
|
||||||
|
"_themeInstallFailed": {
|
||||||
|
"title": string;
|
||||||
|
"description": string;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
declare const locales: {
|
declare const locales: {
|
||||||
[lang: string]: Locale;
|
[lang: string]: Locale;
|
||||||
|
@@ -250,7 +250,7 @@ newPassword: "Nuova Password"
|
|||||||
newPasswordRetype: "Conferma password"
|
newPasswordRetype: "Conferma password"
|
||||||
attachFile: "Allega file"
|
attachFile: "Allega file"
|
||||||
more: "Di più!"
|
more: "Di più!"
|
||||||
featured: "Tendenze"
|
featured: "In evidenza"
|
||||||
usernameOrUserId: "Nome utente o ID"
|
usernameOrUserId: "Nome utente o ID"
|
||||||
noSuchUser: "Profilo non trovato"
|
noSuchUser: "Profilo non trovato"
|
||||||
lookup: "Ricerca remota"
|
lookup: "Ricerca remota"
|
||||||
@@ -1132,13 +1132,23 @@ mutualFollow: "Follow reciproco"
|
|||||||
fileAttachedOnly: "Solo con allegati"
|
fileAttachedOnly: "Solo con allegati"
|
||||||
showRepliesToOthersInTimeline: "Risposte altrui nella TL"
|
showRepliesToOthersInTimeline: "Risposte altrui nella TL"
|
||||||
hideRepliesToOthersInTimeline: "Nascondi Riposte altrui nella TL"
|
hideRepliesToOthersInTimeline: "Nascondi Riposte altrui nella TL"
|
||||||
|
showRepliesToOthersInTimelineAll: "Mostra le risposte dei tuoi follow nella TL"
|
||||||
|
hideRepliesToOthersInTimelineAll: "Nascondi le risposte dei tuoi follow nella TL"
|
||||||
|
confirmShowRepliesAll: "Questa è una attività irreversibile. Vuoi davvero includere tutte le risposte dei following in TL?"
|
||||||
|
confirmHideRepliesAll: "Questa è una attività irreversibile. Vuoi davvero escludere tutte le risposte dei following in TL?"
|
||||||
externalServices: "Servizi esterni"
|
externalServices: "Servizi esterni"
|
||||||
impressum: "Dichiarazione di proprietà"
|
impressum: "Dichiarazione di proprietà"
|
||||||
impressumUrl: "URL della dichiarazione di proprietà"
|
impressumUrl: "URL della dichiarazione di proprietà"
|
||||||
impressumDescription: "La dichiarazione di proprietà, è obbligatoria in alcuni paesi come la Germania (Impressum)."
|
impressumDescription: "La dichiarazione di proprietà, è obbligatoria in alcuni paesi come la Germania (Impressum)."
|
||||||
privacyPolicy: "Informativa privacy ai sensi del Regolamento UE 2016/679 (GDPR)"
|
privacyPolicy: "Informativa ai sensi del Reg. UE 2016/679 (GDPR)"
|
||||||
privacyPolicyUrl: "URL della informativa privacy"
|
privacyPolicyUrl: "URL della informativa privacy"
|
||||||
tosAndPrivacyPolicy: "Condizioni d'uso e informativa privacy"
|
tosAndPrivacyPolicy: "Condizioni d'uso e informativa privacy"
|
||||||
|
avatarDecorations: "Decorazioni foto profilo"
|
||||||
|
attach: "Applica"
|
||||||
|
detach: "Rimuovi"
|
||||||
|
angle: "Angolo"
|
||||||
|
flip: "Inverti"
|
||||||
|
showAvatarDecorations: "Mostra decorazione della foto profilo"
|
||||||
_announcement:
|
_announcement:
|
||||||
forExistingUsers: "Solo ai profili attuali"
|
forExistingUsers: "Solo ai profili attuali"
|
||||||
forExistingUsersDescription: "L'annuncio sarà visibile solo ai profili esistenti in questo momento. Se disabilitato, sarà visibile anche ai profili che verranno creati dopo la pubblicazione di questo annuncio."
|
forExistingUsersDescription: "L'annuncio sarà visibile solo ai profili esistenti in questo momento. Se disabilitato, sarà visibile anche ai profili che verranno creati dopo la pubblicazione di questo annuncio."
|
||||||
@@ -1174,6 +1184,7 @@ _serverSettings:
|
|||||||
manifestJsonOverride: "Sostituire il file manifest.json"
|
manifestJsonOverride: "Sostituire il file manifest.json"
|
||||||
shortName: "Abbreviazione"
|
shortName: "Abbreviazione"
|
||||||
shortNameDescription: "Un'abbreviazione o un nome comune che può essere visualizzato al posto del nome ufficiale lungo del server."
|
shortNameDescription: "Un'abbreviazione o un nome comune che può essere visualizzato al posto del nome ufficiale lungo del server."
|
||||||
|
fanoutTimelineDescription: "Attivando questa funzionalità migliori notevolmente la capacità delle Timeline di collezionare Note, riducendo il carico sul database. Tuttavia, aumenterà l'impiego di memoria RAM per Redis. Disattiva se il tuo server ha poca RAM o la funzionalità è irregolare."
|
||||||
_accountMigration:
|
_accountMigration:
|
||||||
moveFrom: "Migra un altro profilo dentro a questo"
|
moveFrom: "Migra un altro profilo dentro a questo"
|
||||||
moveFromSub: "Crea un alias verso un altro profilo remoto"
|
moveFromSub: "Crea un alias verso un altro profilo remoto"
|
||||||
@@ -1610,7 +1621,7 @@ _channel:
|
|||||||
edit: "Gerisci canale"
|
edit: "Gerisci canale"
|
||||||
setBanner: "Scegli intestazione"
|
setBanner: "Scegli intestazione"
|
||||||
removeBanner: "Rimuovi intestazione"
|
removeBanner: "Rimuovi intestazione"
|
||||||
featured: "Tendenze"
|
featured: "Di tendenza"
|
||||||
owned: "I miei canali"
|
owned: "I miei canali"
|
||||||
following: "Seguiti"
|
following: "Seguiti"
|
||||||
usersCount: "{n} partecipanti"
|
usersCount: "{n} partecipanti"
|
||||||
@@ -1831,7 +1842,7 @@ _widgets:
|
|||||||
notifications: "Notifiche"
|
notifications: "Notifiche"
|
||||||
timeline: "Timeline"
|
timeline: "Timeline"
|
||||||
calendar: "Calendario"
|
calendar: "Calendario"
|
||||||
trends: "Tendenze"
|
trends: "Di tendenza"
|
||||||
clock: "Orologio"
|
clock: "Orologio"
|
||||||
rss: "Aggregatore rss"
|
rss: "Aggregatore rss"
|
||||||
rssTicker: "Ticker RSS"
|
rssTicker: "Ticker RSS"
|
||||||
@@ -2146,6 +2157,9 @@ _moderationLogTypes:
|
|||||||
createAd: "Banner creato"
|
createAd: "Banner creato"
|
||||||
deleteAd: "Banner eliminato"
|
deleteAd: "Banner eliminato"
|
||||||
updateAd: "Banner aggiornato"
|
updateAd: "Banner aggiornato"
|
||||||
|
createAvatarDecoration: "Creazione decorazione della foto profilo"
|
||||||
|
updateAvatarDecoration: "Aggiornamento decorazione foto profilo"
|
||||||
|
deleteAvatarDecoration: "Eliminazione decorazione della foto profilo"
|
||||||
_fileViewer:
|
_fileViewer:
|
||||||
title: "Dettagli del file"
|
title: "Dettagli del file"
|
||||||
type: "Tipo di file"
|
type: "Tipo di file"
|
||||||
@@ -2154,3 +2168,44 @@ _fileViewer:
|
|||||||
uploadedAt: "Caricato il"
|
uploadedAt: "Caricato il"
|
||||||
attachedNotes: "Note a cui è allegato"
|
attachedNotes: "Note a cui è allegato"
|
||||||
thisPageCanBeSeenFromTheAuthor: "Questa pagina può essere vista solo da chi ha caricato il file."
|
thisPageCanBeSeenFromTheAuthor: "Questa pagina può essere vista solo da chi ha caricato il file."
|
||||||
|
_externalResourceInstaller:
|
||||||
|
title: "Installa da sito esterno"
|
||||||
|
checkVendorBeforeInstall: "Prima di installare, assicurati che la fonte sia affidabile."
|
||||||
|
_plugin:
|
||||||
|
title: "Vuoi davvero installare questo componente aggiuntivo?"
|
||||||
|
metaTitle: "Informazioni sul componente aggiuntivo"
|
||||||
|
_theme:
|
||||||
|
title: "Vuoi davvero installare questa variazione grafica?"
|
||||||
|
metaTitle: "Informazioni sulla variazione grafica"
|
||||||
|
_meta:
|
||||||
|
base: "Combinazione base di colori"
|
||||||
|
_vendorInfo:
|
||||||
|
title: "Informazioni sulla fonte"
|
||||||
|
endpoint: "Punto di riferimento della fonte"
|
||||||
|
hashVerify: "Codice di verifica della fonte"
|
||||||
|
_errors:
|
||||||
|
_invalidParams:
|
||||||
|
title: "Parametri non validi"
|
||||||
|
description: "Mancano alcuni parametri per il caricamento, per favore, verifica la URL."
|
||||||
|
_resourceTypeNotSupported:
|
||||||
|
title: "Questa risorsa esterna non è supportata"
|
||||||
|
description: "Il tipo di risorsa ottenuta da questo sito esterno non è supportato. Si prega di contattare la fonte di distribuizone."
|
||||||
|
_failedToFetch:
|
||||||
|
title: "Impossibile ottenere i dati"
|
||||||
|
fetchErrorDescription: "Si è verificato un errore di comunicazione con la fonte. Se riprovare di nuovo non aiuta, contattare la fonte di distribuzione."
|
||||||
|
parseErrorDescription: "Si è verificato un errore elaborando i dati ottenuti dalla fonte. Per favore contattare il distributore."
|
||||||
|
_hashUnmatched:
|
||||||
|
title: "Dati non verificabili, diversi da quelli della fonte"
|
||||||
|
description: "Si è verificato un errore durante la verifica di integrità dei dati ottenuti. Per sicurezza, l'installazione è stata interrotta. Contattare la fonte di distribuzione."
|
||||||
|
_pluginParseFailed:
|
||||||
|
title: "Errore AiScript"
|
||||||
|
description: "Sebbene i dati ottenuti siano validi, non è stato possibile interpretarli, perché si è verificato un errore durante l'analisi di AiScript. Si prega di contattare gli autori del componente aggiuntivo. Potresti controllare la console di Javascript per ottenere dettagli aggiuntivi."
|
||||||
|
_pluginInstallFailed:
|
||||||
|
title: "Impossibile installare il componente aggiuntivo"
|
||||||
|
description: "Si è verificato un impedimento durante l'installazione del componente aggiuntivo. Per favore riprova e consulta la console di Javascript per ottenere dettagli aggiuntivi."
|
||||||
|
_themeParseFailed:
|
||||||
|
title: "Impossibile interpretare la variazione grafica"
|
||||||
|
description: "Sebbene i dati siano stati ottenuti, non è stato possibile interpretarli, si è verificato un errore durante l'analisi della variazione grafica. Si prega di contattare gli autori. Potresti anche controllare la console di Javascript per ottenere dettagli aggiuntivi."
|
||||||
|
_themeInstallFailed:
|
||||||
|
title: "Impossibile installare la variazione grafica"
|
||||||
|
description: "Si è verificato un impedimento durante l'installazione della variazione grafica. Per favore riprova e consulta la console di Javascript per ottenere dettagli aggiuntivi."
|
||||||
|
@@ -979,6 +979,7 @@ assign: "アサイン"
|
|||||||
unassign: "アサインを解除"
|
unassign: "アサインを解除"
|
||||||
color: "色"
|
color: "色"
|
||||||
manageCustomEmojis: "カスタム絵文字の管理"
|
manageCustomEmojis: "カスタム絵文字の管理"
|
||||||
|
manageAvatarDecorations: "アバターデコレーションの管理"
|
||||||
youCannotCreateAnymore: "これ以上作成することはできません。"
|
youCannotCreateAnymore: "これ以上作成することはできません。"
|
||||||
cannotPerformTemporary: "一時的に利用できません"
|
cannotPerformTemporary: "一時的に利用できません"
|
||||||
cannotPerformTemporaryDescription: "操作回数が制限を超過するため一時的に利用できません。しばらく時間を置いてから再度お試しください。"
|
cannotPerformTemporaryDescription: "操作回数が制限を超過するため一時的に利用できません。しばらく時間を置いてから再度お試しください。"
|
||||||
@@ -1132,6 +1133,10 @@ mutualFollow: "相互フォロー"
|
|||||||
fileAttachedOnly: "ファイル付きのみ"
|
fileAttachedOnly: "ファイル付きのみ"
|
||||||
showRepliesToOthersInTimeline: "TLに他の人への返信を含める"
|
showRepliesToOthersInTimeline: "TLに他の人への返信を含める"
|
||||||
hideRepliesToOthersInTimeline: "TLに他の人への返信を含めない"
|
hideRepliesToOthersInTimeline: "TLに他の人への返信を含めない"
|
||||||
|
showRepliesToOthersInTimelineAll: "TLに現在フォロー中の人全員の返信を含めるようにする"
|
||||||
|
hideRepliesToOthersInTimelineAll: "TLに現在フォロー中の人全員の返信を含めないようにする"
|
||||||
|
confirmShowRepliesAll: "この操作は元の戻せません。本当にTLに現在フォロー中の人全員の返信を含めるようにしますか"
|
||||||
|
confirmHideRepliesAll: "この操作は元の戻せません。本当にTLに現在フォロー中の人全員の返信を含めないようにしますか"
|
||||||
externalServices: "外部サービス"
|
externalServices: "外部サービス"
|
||||||
impressum: "運営者情報"
|
impressum: "運営者情報"
|
||||||
impressumUrl: "運営者情報URL"
|
impressumUrl: "運営者情報URL"
|
||||||
@@ -1139,6 +1144,17 @@ impressumDescription: "ドイツなどの一部の国と地域では表示が義
|
|||||||
privacyPolicy: "プライバシーポリシー"
|
privacyPolicy: "プライバシーポリシー"
|
||||||
privacyPolicyUrl: "プライバシーポリシーURL"
|
privacyPolicyUrl: "プライバシーポリシーURL"
|
||||||
tosAndPrivacyPolicy: "利用規約・プライバシーポリシー"
|
tosAndPrivacyPolicy: "利用規約・プライバシーポリシー"
|
||||||
|
avatarDecorations: "アイコンデコレーション"
|
||||||
|
attach: "付ける"
|
||||||
|
detach: "外す"
|
||||||
|
angle: "角度"
|
||||||
|
flip: "反転"
|
||||||
|
showAvatarDecorations: "アイコンのデコレーションを表示"
|
||||||
|
releaseToRefresh: "離してリロード"
|
||||||
|
refreshing: "リロード中"
|
||||||
|
pullDownToRefresh: "引っ張ってリロード"
|
||||||
|
disableStreamingTimeline: "タイムラインのリアルタイム更新を無効にする"
|
||||||
|
useGroupedNotifications: "通知をグルーピングして表示する"
|
||||||
|
|
||||||
_announcement:
|
_announcement:
|
||||||
forExistingUsers: "既存ユーザーのみ"
|
forExistingUsers: "既存ユーザーのみ"
|
||||||
@@ -1178,6 +1194,7 @@ _serverSettings:
|
|||||||
manifestJsonOverride: "manifest.jsonのオーバーライド"
|
manifestJsonOverride: "manifest.jsonのオーバーライド"
|
||||||
shortName: "略称"
|
shortName: "略称"
|
||||||
shortNameDescription: "サーバーの正式名称が長い場合に、代わりに表示することのできる略称や通称。"
|
shortNameDescription: "サーバーの正式名称が長い場合に、代わりに表示することのできる略称や通称。"
|
||||||
|
fanoutTimelineDescription: "有効にすると、各種タイムラインを取得する際のパフォーマンスが大幅に向上し、データベースへの負荷を軽減することが可能です。ただし、Redisのメモリ使用量は増加します。サーバーのメモリ容量が少ない場合、または動作が不安定な場合は無効にすることができます。"
|
||||||
|
|
||||||
_accountMigration:
|
_accountMigration:
|
||||||
moveFrom: "別のアカウントからこのアカウントに移行"
|
moveFrom: "別のアカウントからこのアカウントに移行"
|
||||||
@@ -1481,6 +1498,7 @@ _role:
|
|||||||
inviteLimitCycle: "招待コードの発行間隔"
|
inviteLimitCycle: "招待コードの発行間隔"
|
||||||
inviteExpirationTime: "招待コードの有効期限"
|
inviteExpirationTime: "招待コードの有効期限"
|
||||||
canManageCustomEmojis: "カスタム絵文字の管理"
|
canManageCustomEmojis: "カスタム絵文字の管理"
|
||||||
|
canManageAvatarDecorations: "アバターデコレーションの管理"
|
||||||
driveCapacity: "ドライブ容量"
|
driveCapacity: "ドライブ容量"
|
||||||
alwaysMarkNsfw: "ファイルにNSFWを常に付与"
|
alwaysMarkNsfw: "ファイルにNSFWを常に付与"
|
||||||
pinMax: "ノートのピン留めの最大数"
|
pinMax: "ノートのピン留めの最大数"
|
||||||
@@ -1606,13 +1624,14 @@ _registry:
|
|||||||
|
|
||||||
_aboutMisskey:
|
_aboutMisskey:
|
||||||
about: "Misskeyはsyuiloによって2014年から開発されている、オープンソースのソフトウェアです。"
|
about: "Misskeyはsyuiloによって2014年から開発されている、オープンソースのソフトウェアです。"
|
||||||
contributors: "主なコントリビューター"
|
contributors: "コントリビューター"
|
||||||
allContributors: "全てのコントリビューター"
|
allContributors: "全てのコントリビューター"
|
||||||
source: "ソースコード"
|
source: "ソースコード"
|
||||||
translation: "Misskeyを翻訳"
|
translation: "Misskeyを翻訳"
|
||||||
donate: "Misskeyに寄付"
|
donate: "Misskeyに寄付"
|
||||||
morePatrons: "他にも多くの方が支援してくれています。ありがとうございます🥰"
|
morePatrons: "他にも多くの方が支援してくれています。ありがとうございます🥰"
|
||||||
patrons: "支援者"
|
patrons: "支援者"
|
||||||
|
projectMembers: "プロジェクトメンバー"
|
||||||
|
|
||||||
_displayOfSensitiveMedia:
|
_displayOfSensitiveMedia:
|
||||||
respect: "センシティブ設定されたメディアを隠す"
|
respect: "センシティブ設定されたメディアを隠す"
|
||||||
@@ -2096,6 +2115,9 @@ _notification:
|
|||||||
checkNotificationBehavior: "通知の表示を確かめる"
|
checkNotificationBehavior: "通知の表示を確かめる"
|
||||||
sendTestNotification: "テスト通知を送信する"
|
sendTestNotification: "テスト通知を送信する"
|
||||||
notificationWillBeDisplayedLikeThis: "通知はこのように表示されます"
|
notificationWillBeDisplayedLikeThis: "通知はこのように表示されます"
|
||||||
|
reactedBySomeUsers: "{n}人がリアクションしました"
|
||||||
|
renotedBySomeUsers: "{n}人がリノートしました"
|
||||||
|
followedBySomeUsers: "{n}人にフォローされました"
|
||||||
|
|
||||||
_types:
|
_types:
|
||||||
all: "すべて"
|
all: "すべて"
|
||||||
@@ -2208,6 +2230,9 @@ _moderationLogTypes:
|
|||||||
createAd: "広告を作成"
|
createAd: "広告を作成"
|
||||||
deleteAd: "広告を削除"
|
deleteAd: "広告を削除"
|
||||||
updateAd: "広告を更新"
|
updateAd: "広告を更新"
|
||||||
|
createAvatarDecoration: "アイコンデコレーションを作成"
|
||||||
|
updateAvatarDecoration: "アイコンデコレーションを更新"
|
||||||
|
deleteAvatarDecoration: "アイコンデコレーションを削除"
|
||||||
|
|
||||||
_fileViewer:
|
_fileViewer:
|
||||||
title: "ファイルの詳細"
|
title: "ファイルの詳細"
|
||||||
@@ -2217,3 +2242,45 @@ _fileViewer:
|
|||||||
uploadedAt: "追加日"
|
uploadedAt: "追加日"
|
||||||
attachedNotes: "添付されているノート"
|
attachedNotes: "添付されているノート"
|
||||||
thisPageCanBeSeenFromTheAuthor: "このページは、このファイルをアップロードしたユーザーしか閲覧できません。"
|
thisPageCanBeSeenFromTheAuthor: "このページは、このファイルをアップロードしたユーザーしか閲覧できません。"
|
||||||
|
|
||||||
|
_externalResourceInstaller:
|
||||||
|
title: "外部サイトからインストール"
|
||||||
|
checkVendorBeforeInstall: "配布元が信頼できるかを確認した上でインストールしてください。"
|
||||||
|
_plugin:
|
||||||
|
title: "このプラグインをインストールしますか?"
|
||||||
|
metaTitle: "プラグイン情報"
|
||||||
|
_theme:
|
||||||
|
title: "このテーマをインストールしますか?"
|
||||||
|
metaTitle: "テーマ情報"
|
||||||
|
_meta:
|
||||||
|
base: "基本のカラースキーム"
|
||||||
|
_vendorInfo:
|
||||||
|
title: "配布元情報"
|
||||||
|
endpoint: "参照したエンドポイント"
|
||||||
|
hashVerify: "ファイル整合性の確認"
|
||||||
|
_errors:
|
||||||
|
_invalidParams:
|
||||||
|
title: "パラメータが不足しています"
|
||||||
|
description: "外部サイトからデータを取得するために必要な情報が不足しています。URLをお確かめください。"
|
||||||
|
_resourceTypeNotSupported:
|
||||||
|
title: "この外部リソースには対応していません"
|
||||||
|
description: "この外部サイトから取得したリソースの種別には対応していません。サイト管理者にお問い合わせください。"
|
||||||
|
_failedToFetch:
|
||||||
|
title: "データの取得に失敗しました"
|
||||||
|
fetchErrorDescription: "外部サイトとの通信に失敗しました。もう一度試しても改善しない場合、サイト管理者にお問い合わせください。"
|
||||||
|
parseErrorDescription: "外部サイトから取得したデータが読み取れませんでした。サイト管理者にお問い合わせください。"
|
||||||
|
_hashUnmatched:
|
||||||
|
title: "正しいデータが取得できませんでした"
|
||||||
|
description: "提供されたデータの整合性の確認に失敗しました。セキュリティ上、インストールは続行できません。サイト管理者にお問い合わせください。"
|
||||||
|
_pluginParseFailed:
|
||||||
|
title: "AiScript エラー"
|
||||||
|
description: "データは取得できたものの、AiScriptの解析時にエラーがあったため読み込めませんでした。プラグインの作者にお問い合わせください。エラーの詳細はJavascriptコンソールをご確認ください。"
|
||||||
|
_pluginInstallFailed:
|
||||||
|
title: "プラグインのインストールに失敗しました"
|
||||||
|
description: "プラグインのインストール中に問題が発生しました。もう一度お試しください。エラーの詳細はJavascriptコンソールをご覧ください。"
|
||||||
|
_themeParseFailed:
|
||||||
|
title: "テーマ解析エラー"
|
||||||
|
description: "データは取得できたものの、テーマファイルの解析時にエラーがあったため読み込めませんでした。テーマの作者にお問い合わせください。エラーの詳細はJavascriptコンソールをご確認ください。"
|
||||||
|
_themeInstallFailed:
|
||||||
|
title: "テーマのインストールに失敗しました"
|
||||||
|
description: "テーマのインストール中に問題が発生しました。もう一度お試しください。エラーの詳細はJavascriptコンソールをご覧ください。"
|
||||||
|
@@ -1132,6 +1132,7 @@ mutualFollow: "お互いフォローしてんで"
|
|||||||
fileAttachedOnly: "ファイル付きのみ"
|
fileAttachedOnly: "ファイル付きのみ"
|
||||||
showRepliesToOthersInTimeline: "タイムラインに他の人への返信とかも含めんで"
|
showRepliesToOthersInTimeline: "タイムラインに他の人への返信とかも含めんで"
|
||||||
hideRepliesToOthersInTimeline: "タイムラインに他の人への返信とかは見ーへんで"
|
hideRepliesToOthersInTimeline: "タイムラインに他の人への返信とかは見ーへんで"
|
||||||
|
showRepliesToOthersInTimelineAll: ""
|
||||||
externalServices: "他のサイトのサービス"
|
externalServices: "他のサイトのサービス"
|
||||||
impressum: "運営者の情報"
|
impressum: "運営者の情報"
|
||||||
impressumUrl: "運営者の情報URL"
|
impressumUrl: "運営者の情報URL"
|
||||||
@@ -1139,6 +1140,8 @@ impressumDescription: "ドイツなどのほんま1部の国と地域ではな
|
|||||||
privacyPolicy: "プライバシーポリシー"
|
privacyPolicy: "プライバシーポリシー"
|
||||||
privacyPolicyUrl: "プライバシーポリシーURL"
|
privacyPolicyUrl: "プライバシーポリシーURL"
|
||||||
tosAndPrivacyPolicy: "利用規約・プライバシーポリシー"
|
tosAndPrivacyPolicy: "利用規約・プライバシーポリシー"
|
||||||
|
avatarDecorations: "アイコンデコレーション"
|
||||||
|
flip: "反転"
|
||||||
_announcement:
|
_announcement:
|
||||||
forExistingUsers: "もうおるユーザーのみ"
|
forExistingUsers: "もうおるユーザーのみ"
|
||||||
forExistingUsersDescription: "有効にすると、このお知らせ作成時点でおるユーザーにのみお知らせが表示されます。無効にすると、このお知らせ作成後にアカウントを作成したユーザーにもお知らせが表示されます。"
|
forExistingUsersDescription: "有効にすると、このお知らせ作成時点でおるユーザーにのみお知らせが表示されます。無効にすると、このお知らせ作成後にアカウントを作成したユーザーにもお知らせが表示されます。"
|
||||||
@@ -2146,6 +2149,9 @@ _moderationLogTypes:
|
|||||||
createAd: "広告を作んで"
|
createAd: "広告を作んで"
|
||||||
deleteAd: "広告ほかす"
|
deleteAd: "広告ほかす"
|
||||||
updateAd: "広告を更新"
|
updateAd: "広告を更新"
|
||||||
|
createAvatarDecoration: "アイコンデコレーションを作成"
|
||||||
|
updateAvatarDecoration: "アイコンデコレーションを更新"
|
||||||
|
deleteAvatarDecoration: "アイコンデコレーションを削除"
|
||||||
_fileViewer:
|
_fileViewer:
|
||||||
title: "ファイルの詳しい情報"
|
title: "ファイルの詳しい情報"
|
||||||
type: "ファイルの種類"
|
type: "ファイルの種類"
|
||||||
@@ -2154,3 +2160,25 @@ _fileViewer:
|
|||||||
uploadedAt: "追加した日"
|
uploadedAt: "追加した日"
|
||||||
attachedNotes: "ファイルがついてきてるノート"
|
attachedNotes: "ファイルがついてきてるノート"
|
||||||
thisPageCanBeSeenFromTheAuthor: "このページはこのファイルをアップした人しか見れへんねん。"
|
thisPageCanBeSeenFromTheAuthor: "このページはこのファイルをアップした人しか見れへんねん。"
|
||||||
|
_externalResourceInstaller:
|
||||||
|
title: "ほかのサイトからインストール"
|
||||||
|
checkVendorBeforeInstall: "配ってるとこが信頼できるか確認した上でインストールしてな。"
|
||||||
|
_plugin:
|
||||||
|
title: "このプラグイン、インストールする?"
|
||||||
|
metaTitle: "プラグイン情報"
|
||||||
|
_theme:
|
||||||
|
title: "このテーマインストールする?"
|
||||||
|
metaTitle: "テーマ情報"
|
||||||
|
_errors:
|
||||||
|
_pluginParseFailed:
|
||||||
|
title: "AiScriptエラー起こしてもうたねん"
|
||||||
|
description: "データは取得できたものの、AiScript解析時にエラーがあったから読み込めへんかってん。すまんが、プラグインを作った人に問い合わせてくれへん?ごめんな。エラーの詳細はJavaScriptコンソール読んでな。"
|
||||||
|
_pluginInstallFailed:
|
||||||
|
title: "プラグインのインストール失敗してもた"
|
||||||
|
description: "プラグインのインストール中に問題発生してもた、もう1度試してな。エラーの詳細はJavaScriptのコンソール見てや。"
|
||||||
|
_themeParseFailed:
|
||||||
|
title: "テーマ解析エラー"
|
||||||
|
description: "データは取得できたものの、テーマファイル解析時にエラーがあったから読み込めへんかってん。すまんが、テーマ作った人に問い合わせてくれへん?ごめんな。エラーの詳細はJavaScriptコンソール読んでな。"
|
||||||
|
_themeInstallFailed:
|
||||||
|
title: "テーマインストールに失敗してもた"
|
||||||
|
description: "テーマのインストール中に問題発生してもた、もう1度試してな。エラーの詳細はJavaScriptのコンソール見てや。"
|
||||||
|
@@ -162,8 +162,8 @@ cacheRemoteSensitiveFiles: "리모트의 민감한 파일을 캐시"
|
|||||||
cacheRemoteSensitiveFilesDescription: "이 설정을 비활성화하면 리모트의 민감한 파일은 캐시하지 않고 리모트에서 직접 가져오도록 합니다."
|
cacheRemoteSensitiveFilesDescription: "이 설정을 비활성화하면 리모트의 민감한 파일은 캐시하지 않고 리모트에서 직접 가져오도록 합니다."
|
||||||
flagAsBot: "나는 봇입니다"
|
flagAsBot: "나는 봇입니다"
|
||||||
flagAsBotDescription: "이 계정을 자동화된 수단으로 운용할 경우에 활성화해 주세요. 이 플래그를 활성화하면, 다른 봇이 이를 참고하여 봇 끼리의 무한 연쇄 반응을 회피하거나, 이 계정의 시스템 상에서의 취급이 Bot 운영에 최적화되는 등의 변화가 생깁니다."
|
flagAsBotDescription: "이 계정을 자동화된 수단으로 운용할 경우에 활성화해 주세요. 이 플래그를 활성화하면, 다른 봇이 이를 참고하여 봇 끼리의 무한 연쇄 반응을 회피하거나, 이 계정의 시스템 상에서의 취급이 Bot 운영에 최적화되는 등의 변화가 생깁니다."
|
||||||
flagAsCat: "나는 고양이다냥"
|
flagAsCat: "미야아아아오오오오오오오오오옹!!!!!!!"
|
||||||
flagAsCatDescription: "이 계정이 고양이라면 활성화해 주세요."
|
flagAsCatDescription: "야옹?"
|
||||||
flagShowTimelineReplies: "타임라인에 노트의 답글을 표시하기"
|
flagShowTimelineReplies: "타임라인에 노트의 답글을 표시하기"
|
||||||
flagShowTimelineRepliesDescription: "이 설정을 활성화하면 타임라인에 다른 유저 간의 답글을 표시합니다."
|
flagShowTimelineRepliesDescription: "이 설정을 활성화하면 타임라인에 다른 유저 간의 답글을 표시합니다."
|
||||||
autoAcceptFollowed: "팔로우 중인 유저로부터의 팔로우 요청을 자동 수락"
|
autoAcceptFollowed: "팔로우 중인 유저로부터의 팔로우 요청을 자동 수락"
|
||||||
@@ -1122,6 +1122,7 @@ showRenotes: "리노트 표시"
|
|||||||
edited: "수정됨"
|
edited: "수정됨"
|
||||||
notificationRecieveConfig: "알림 설정"
|
notificationRecieveConfig: "알림 설정"
|
||||||
mutualFollow: "맞팔로우"
|
mutualFollow: "맞팔로우"
|
||||||
|
flip: "플립"
|
||||||
_announcement:
|
_announcement:
|
||||||
forExistingUsers: "기존 유저에게만 알림"
|
forExistingUsers: "기존 유저에게만 알림"
|
||||||
forExistingUsersDescription: "활성화하면 이 공지사항을 게시한 시점에서 이미 가입한 유저에게만 표시합니다. 비활성화하면 게시 후에 가입한 유저에게도 표시합니다."
|
forExistingUsersDescription: "활성화하면 이 공지사항을 게시한 시점에서 이미 가입한 유저에게만 표시합니다. 비활성화하면 게시 후에 가입한 유저에게도 표시합니다."
|
||||||
|
@@ -873,6 +873,7 @@ youFollowing: "Śledzeni"
|
|||||||
icon: "Awatar"
|
icon: "Awatar"
|
||||||
replies: "Odpowiedz"
|
replies: "Odpowiedz"
|
||||||
renotes: "Udostępnij"
|
renotes: "Udostępnij"
|
||||||
|
flip: "Odwróć"
|
||||||
_role:
|
_role:
|
||||||
priority: "Priorytet"
|
priority: "Priorytet"
|
||||||
_priority:
|
_priority:
|
||||||
|
@@ -1011,6 +1011,7 @@ icon: "Avatar"
|
|||||||
replies: "Responder"
|
replies: "Responder"
|
||||||
renotes: "Repostar"
|
renotes: "Repostar"
|
||||||
keepScreenOn: "Manter a tela do dispositivo sempre ligada"
|
keepScreenOn: "Manter a tela do dispositivo sempre ligada"
|
||||||
|
flip: "Inversão"
|
||||||
_initialAccountSetting:
|
_initialAccountSetting:
|
||||||
followUsers: "Siga usuários que lhe interessam para criar a sua linha do tempo."
|
followUsers: "Siga usuários que lhe interessam para criar a sua linha do tempo."
|
||||||
_serverSettings:
|
_serverSettings:
|
||||||
|
@@ -1067,6 +1067,7 @@ doYouAgree: "Согласны?"
|
|||||||
icon: "Аватар"
|
icon: "Аватар"
|
||||||
replies: "Ответить"
|
replies: "Ответить"
|
||||||
renotes: "Репост"
|
renotes: "Репост"
|
||||||
|
flip: "Переворот"
|
||||||
_initialAccountSetting:
|
_initialAccountSetting:
|
||||||
accountCreated: "Аккаунт успешно создан!"
|
accountCreated: "Аккаунт успешно создан!"
|
||||||
letsStartAccountSetup: "Давайте настроим вашу учётную запись."
|
letsStartAccountSetup: "Давайте настроим вашу учётную запись."
|
||||||
|
@@ -921,6 +921,7 @@ youFollowing: "Sledované"
|
|||||||
icon: "Avatar"
|
icon: "Avatar"
|
||||||
replies: "Odpovedať"
|
replies: "Odpovedať"
|
||||||
renotes: "Preposlať"
|
renotes: "Preposlať"
|
||||||
|
flip: "Preklopiť"
|
||||||
_role:
|
_role:
|
||||||
priority: "Priorita"
|
priority: "Priorita"
|
||||||
_priority:
|
_priority:
|
||||||
|
@@ -1132,6 +1132,7 @@ impressumUrl: "URL อิมเพรสชั่น"
|
|||||||
privacyPolicy: "นโยบายความเป็นส่วนตัว"
|
privacyPolicy: "นโยบายความเป็นส่วนตัว"
|
||||||
privacyPolicyUrl: "URL นโยบายความเป็นส่วนตัว"
|
privacyPolicyUrl: "URL นโยบายความเป็นส่วนตัว"
|
||||||
tosAndPrivacyPolicy: "เงื่อนไขในการให้บริการและนโยบายความเป็นส่วนตัว"
|
tosAndPrivacyPolicy: "เงื่อนไขในการให้บริการและนโยบายความเป็นส่วนตัว"
|
||||||
|
flip: "ย้อนกลับ"
|
||||||
_announcement:
|
_announcement:
|
||||||
forExistingUsers: "ผู้ใช้งานที่มีอยู่เท่านั้น"
|
forExistingUsers: "ผู้ใช้งานที่มีอยู่เท่านั้น"
|
||||||
forExistingUsersDescription: "การประกาศนี้จะแสดงต่อผู้ใช้ที่มีอยู่ ณ จุดที่เผยแพร่นั้นๆถ้าหากเปิดใช้งาน ถ้าหากปิดใช้งานผู้ที่กำลังสมัครใหม่หลังจากโพสต์แล้วนั้นก็จะเห็นเช่นกัน"
|
forExistingUsersDescription: "การประกาศนี้จะแสดงต่อผู้ใช้ที่มีอยู่ ณ จุดที่เผยแพร่นั้นๆถ้าหากเปิดใช้งาน ถ้าหากปิดใช้งานผู้ที่กำลังสมัครใหม่หลังจากโพสต์แล้วนั้นก็จะเห็นเช่นกัน"
|
||||||
|
@@ -907,6 +907,7 @@ youFollowing: "Підписки"
|
|||||||
icon: "Аватар"
|
icon: "Аватар"
|
||||||
replies: "Відповісти"
|
replies: "Відповісти"
|
||||||
renotes: "Поширити"
|
renotes: "Поширити"
|
||||||
|
flip: "Перевернути"
|
||||||
_achievements:
|
_achievements:
|
||||||
earnedAt: "Відкрито"
|
earnedAt: "Відкрито"
|
||||||
_types:
|
_types:
|
||||||
|
@@ -845,6 +845,7 @@ sensitiveWords: "Ta'sirchan so'zlar"
|
|||||||
icon: "Avatar"
|
icon: "Avatar"
|
||||||
replies: "Javob berish"
|
replies: "Javob berish"
|
||||||
renotes: "Qayta qayd etish"
|
renotes: "Qayta qayd etish"
|
||||||
|
flip: "Teskari"
|
||||||
_achievements:
|
_achievements:
|
||||||
_types:
|
_types:
|
||||||
_viewInstanceChart:
|
_viewInstanceChart:
|
||||||
|
@@ -1047,6 +1047,7 @@ loadReplies: "Hiển thị các trả lời"
|
|||||||
pinnedList: "Các mục đã được ghim"
|
pinnedList: "Các mục đã được ghim"
|
||||||
keepScreenOn: "Giữ màn hình luôn bật"
|
keepScreenOn: "Giữ màn hình luôn bật"
|
||||||
verifiedLink: "Chúng tôi đã xác nhận bạn là chủ sở hữu của đường dẫn này"
|
verifiedLink: "Chúng tôi đã xác nhận bạn là chủ sở hữu của đường dẫn này"
|
||||||
|
flip: "Lật"
|
||||||
_announcement:
|
_announcement:
|
||||||
forExistingUsers: "Chỉ những người dùng đã tồn tại"
|
forExistingUsers: "Chỉ những người dùng đã tồn tại"
|
||||||
forExistingUsersDescription: "Nếu được bật, thông báo này sẽ chỉ hiển thị với những người dùng đã tồn tại vào lúc thông báo được tạo. Nếu tắt đi, những tài khoản mới đăng ký sau khi thông báo được đăng lên cũng sẽ thấy nó."
|
forExistingUsersDescription: "Nếu được bật, thông báo này sẽ chỉ hiển thị với những người dùng đã tồn tại vào lúc thông báo được tạo. Nếu tắt đi, những tài khoản mới đăng ký sau khi thông báo được đăng lên cũng sẽ thấy nó."
|
||||||
|
@@ -1131,6 +1131,7 @@ mutualFollow: "互相关注"
|
|||||||
fileAttachedOnly: "仅限媒体"
|
fileAttachedOnly: "仅限媒体"
|
||||||
showRepliesToOthersInTimeline: "在时间线上显示给其他人的回复"
|
showRepliesToOthersInTimeline: "在时间线上显示给其他人的回复"
|
||||||
hideRepliesToOthersInTimeline: "在时间线上隐藏给其他人的回复"
|
hideRepliesToOthersInTimeline: "在时间线上隐藏给其他人的回复"
|
||||||
|
flip: "翻转"
|
||||||
_announcement:
|
_announcement:
|
||||||
forExistingUsers: "仅限现有用户"
|
forExistingUsers: "仅限现有用户"
|
||||||
forExistingUsersDescription: "若启用,该公告将仅对创建此公告时存在的用户可见。 如果禁用,则在创建此公告后注册的用户也可以看到该公告。"
|
forExistingUsersDescription: "若启用,该公告将仅对创建此公告时存在的用户可见。 如果禁用,则在创建此公告后注册的用户也可以看到该公告。"
|
||||||
|
@@ -1132,6 +1132,10 @@ mutualFollow: "互相追隨"
|
|||||||
fileAttachedOnly: "顯示包含附件的貼文"
|
fileAttachedOnly: "顯示包含附件的貼文"
|
||||||
showRepliesToOthersInTimeline: "顯示給其他人的回覆"
|
showRepliesToOthersInTimeline: "顯示給其他人的回覆"
|
||||||
hideRepliesToOthersInTimeline: "在時間軸上隱藏給其他人的回覆"
|
hideRepliesToOthersInTimeline: "在時間軸上隱藏給其他人的回覆"
|
||||||
|
showRepliesToOthersInTimelineAll: "在時間軸包含追隨中所有人的回覆"
|
||||||
|
hideRepliesToOthersInTimelineAll: "在時間軸不包含追隨中所有人的回覆"
|
||||||
|
confirmShowRepliesAll: "進行此操作後無法復原。您真的希望時間軸「包含」您目前追隨的所有人的回覆嗎?"
|
||||||
|
confirmHideRepliesAll: "進行此操作後無法復原。您真的希望時間軸「不包含」您目前追隨的所有人的回覆嗎?"
|
||||||
externalServices: "外部服務"
|
externalServices: "外部服務"
|
||||||
impressum: "營運者資訊"
|
impressum: "營運者資訊"
|
||||||
impressumUrl: "營運者資訊網址"
|
impressumUrl: "營運者資訊網址"
|
||||||
@@ -1139,6 +1143,12 @@ impressumDescription: "在德國與部份地區必須要明確顯示營運者資
|
|||||||
privacyPolicy: "隱私政策"
|
privacyPolicy: "隱私政策"
|
||||||
privacyPolicyUrl: "隱私政策網址"
|
privacyPolicyUrl: "隱私政策網址"
|
||||||
tosAndPrivacyPolicy: "服務條款和隱私政策"
|
tosAndPrivacyPolicy: "服務條款和隱私政策"
|
||||||
|
avatarDecorations: "頭像裝飾"
|
||||||
|
attach: "裝上"
|
||||||
|
detach: "取下"
|
||||||
|
angle: "角度"
|
||||||
|
flip: "翻轉"
|
||||||
|
showAvatarDecorations: "顯示頭像裝飾"
|
||||||
_announcement:
|
_announcement:
|
||||||
forExistingUsers: "僅限既有的使用者"
|
forExistingUsers: "僅限既有的使用者"
|
||||||
forExistingUsersDescription: "啟用代表僅向現存使用者顯示;停用代表張貼後註冊的新使用者也會看到。"
|
forExistingUsersDescription: "啟用代表僅向現存使用者顯示;停用代表張貼後註冊的新使用者也會看到。"
|
||||||
@@ -1174,6 +1184,7 @@ _serverSettings:
|
|||||||
manifestJsonOverride: "覆寫 manifest.json"
|
manifestJsonOverride: "覆寫 manifest.json"
|
||||||
shortName: "簡稱"
|
shortName: "簡稱"
|
||||||
shortNameDescription: "如果伺服器的正式名稱很長,可用簡稱或通稱代替。"
|
shortNameDescription: "如果伺服器的正式名稱很長,可用簡稱或通稱代替。"
|
||||||
|
fanoutTimelineDescription: "如果啟用的話,檢索各個時間軸的性能會顯著提昇,資料庫的負荷也會減少。不過,Redis 的記憶體使用量會增加。如果伺服器的記憶體容量比較少或者運行不穩定,可以停用。"
|
||||||
_accountMigration:
|
_accountMigration:
|
||||||
moveFrom: "從其他帳戶遷移到這個帳戶"
|
moveFrom: "從其他帳戶遷移到這個帳戶"
|
||||||
moveFromSub: "為另一個帳戶建立別名"
|
moveFromSub: "為另一個帳戶建立別名"
|
||||||
@@ -2146,6 +2157,9 @@ _moderationLogTypes:
|
|||||||
createAd: "建立廣告"
|
createAd: "建立廣告"
|
||||||
deleteAd: "刪除廣告"
|
deleteAd: "刪除廣告"
|
||||||
updateAd: "更新廣告"
|
updateAd: "更新廣告"
|
||||||
|
createAvatarDecoration: "建立頭像裝飾"
|
||||||
|
updateAvatarDecoration: "更新頭像裝飾"
|
||||||
|
deleteAvatarDecoration: "刪除頭像裝飾"
|
||||||
_fileViewer:
|
_fileViewer:
|
||||||
title: "檔案詳細資訊"
|
title: "檔案詳細資訊"
|
||||||
type: "檔案類型 "
|
type: "檔案類型 "
|
||||||
@@ -2154,3 +2168,44 @@ _fileViewer:
|
|||||||
uploadedAt: "加入日期"
|
uploadedAt: "加入日期"
|
||||||
attachedNotes: "含有附件的貼文"
|
attachedNotes: "含有附件的貼文"
|
||||||
thisPageCanBeSeenFromTheAuthor: "本頁面僅限上傳了這個檔案的使用者可以檢視。"
|
thisPageCanBeSeenFromTheAuthor: "本頁面僅限上傳了這個檔案的使用者可以檢視。"
|
||||||
|
_externalResourceInstaller:
|
||||||
|
title: "從外部網站安裝"
|
||||||
|
checkVendorBeforeInstall: "安裝前請確認提供者是可信賴的。"
|
||||||
|
_plugin:
|
||||||
|
title: "要安裝此外掛嘛?"
|
||||||
|
metaTitle: "外掛資訊"
|
||||||
|
_theme:
|
||||||
|
title: "要安裝此外觀主題嘛?"
|
||||||
|
metaTitle: "外觀主題資訊"
|
||||||
|
_meta:
|
||||||
|
base: "基本配色方案"
|
||||||
|
_vendorInfo:
|
||||||
|
title: "提供者資訊"
|
||||||
|
endpoint: "引用端點"
|
||||||
|
hashVerify: "確認檔案的完整性"
|
||||||
|
_errors:
|
||||||
|
_invalidParams:
|
||||||
|
title: "缺少參數"
|
||||||
|
description: "缺少從外部網站取得資料的必要資訊。請檢查 URL 是否正確。"
|
||||||
|
_resourceTypeNotSupported:
|
||||||
|
title: "不支援此外部資源。"
|
||||||
|
description: "不支援從此外部網站取得的資源類型。請聯絡網站管理員。"
|
||||||
|
_failedToFetch:
|
||||||
|
title: "無法取得資料"
|
||||||
|
fetchErrorDescription: "與外部站點的通訊失敗。如果重試後問題仍然存在,請聯絡網站管理員。"
|
||||||
|
parseErrorDescription: "無法讀取從外部站點取得的資料。請聯絡網站管理員。"
|
||||||
|
_hashUnmatched:
|
||||||
|
title: "無法取得正確資料"
|
||||||
|
description: "所提供資料的完整性驗證失敗。出於安全原因,安裝無法繼續。請聯絡網站管理員。"
|
||||||
|
_pluginParseFailed:
|
||||||
|
title: "AiScript 錯誤"
|
||||||
|
description: "已取得資料但解析 AiScript 時發生錯誤,導致無法載入。請聯絡外掛作者。請檢查 Javascript 控制台以取得錯誤詳細資訊。"
|
||||||
|
_pluginInstallFailed:
|
||||||
|
title: "外掛安裝失敗"
|
||||||
|
description: "安裝插件時出現問題。請再試一次。請參閱 Javascript 控制台以取得錯誤詳細資訊。"
|
||||||
|
_themeParseFailed:
|
||||||
|
title: "外觀主題解析錯誤"
|
||||||
|
description: "已取得資料但解析外觀主題時發生錯誤,導致無法載入。請聯絡主題作者。請檢查 Javascript 控制台以取得錯誤詳細資訊。"
|
||||||
|
_themeInstallFailed:
|
||||||
|
title: "無法安裝外觀主題"
|
||||||
|
description: "安裝外觀主題時出現問題。請再試一次。請參閱 Javascript 控制台以取得錯誤詳細資訊。"
|
||||||
|
15
package.json
15
package.json
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "misskey",
|
"name": "misskey",
|
||||||
"version": "2023.10.2",
|
"version": "2023.11.0-beta.7",
|
||||||
"codename": "nasubi",
|
"codename": "nasubi",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/misskey-dev/misskey.git"
|
"url": "https://github.com/misskey-dev/misskey.git"
|
||||||
},
|
},
|
||||||
"packageManager": "pnpm@8.9.2",
|
"packageManager": "pnpm@8.10.0",
|
||||||
"workspaces": [
|
"workspaces": [
|
||||||
"packages/frontend",
|
"packages/frontend",
|
||||||
"packages/backend",
|
"packages/backend",
|
||||||
@@ -22,6 +22,7 @@
|
|||||||
"start:test": "cd packages/backend && cross-env NODE_ENV=test node ./built/boot/entry.js",
|
"start:test": "cd packages/backend && cross-env NODE_ENV=test node ./built/boot/entry.js",
|
||||||
"init": "pnpm migrate",
|
"init": "pnpm migrate",
|
||||||
"migrate": "cd packages/backend && pnpm migrate",
|
"migrate": "cd packages/backend && pnpm migrate",
|
||||||
|
"revert": "cd packages/backend && pnpm revert",
|
||||||
"check:connect": "cd packages/backend && pnpm check:connect",
|
"check:connect": "cd packages/backend && pnpm check:connect",
|
||||||
"migrateandstart": "pnpm migrate && pnpm start",
|
"migrateandstart": "pnpm migrate && pnpm start",
|
||||||
"watch": "pnpm dev",
|
"watch": "pnpm dev",
|
||||||
@@ -47,15 +48,15 @@
|
|||||||
"cssnano": "6.0.1",
|
"cssnano": "6.0.1",
|
||||||
"js-yaml": "4.1.0",
|
"js-yaml": "4.1.0",
|
||||||
"postcss": "8.4.31",
|
"postcss": "8.4.31",
|
||||||
"terser": "5.22.0",
|
"terser": "5.24.0",
|
||||||
"typescript": "5.2.2"
|
"typescript": "5.2.2"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@typescript-eslint/eslint-plugin": "6.8.0",
|
"@typescript-eslint/eslint-plugin": "6.9.1",
|
||||||
"@typescript-eslint/parser": "6.8.0",
|
"@typescript-eslint/parser": "6.9.1",
|
||||||
"cross-env": "7.0.3",
|
"cross-env": "7.0.3",
|
||||||
"cypress": "13.3.2",
|
"cypress": "13.4.0",
|
||||||
"eslint": "8.51.0",
|
"eslint": "8.52.0",
|
||||||
"start-server-and-test": "2.0.1"
|
"start-server-and-test": "2.0.1"
|
||||||
},
|
},
|
||||||
"optionalDependencies": {
|
"optionalDependencies": {
|
||||||
|
BIN
packages/backend/assets/tabler-badges/bell.png
Normal file
BIN
packages/backend/assets/tabler-badges/bell.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.7 KiB |
@@ -0,0 +1,18 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
export class AvatarDecoration1697847397844 {
|
||||||
|
name = 'AvatarDecoration1697847397844'
|
||||||
|
|
||||||
|
async up(queryRunner) {
|
||||||
|
await queryRunner.query(`CREATE TABLE "avatar_decoration" ("id" character varying(32) NOT NULL, "updatedAt" TIMESTAMP WITH TIME ZONE, "url" character varying(1024) NOT NULL, "name" character varying(256) NOT NULL, "description" character varying(2048) NOT NULL, "roleIdsThatCanBeUsedThisDecoration" character varying(128) array NOT NULL DEFAULT '{}', CONSTRAINT "PK_b6de9296f6097078e1dc53f7603" PRIMARY KEY ("id"))`);
|
||||||
|
await queryRunner.query(`ALTER TABLE "user" ADD "avatarDecorations" character varying(512) array NOT NULL DEFAULT '{}'`);
|
||||||
|
}
|
||||||
|
|
||||||
|
async down(queryRunner) {
|
||||||
|
await queryRunner.query(`ALTER TABLE "user" DROP COLUMN "avatarDecorations"`);
|
||||||
|
await queryRunner.query(`DROP TABLE "avatar_decoration"`);
|
||||||
|
}
|
||||||
|
}
|
@@ -0,0 +1,18 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
export class AvatarDecoration21697941908548 {
|
||||||
|
name = 'AvatarDecoration21697941908548'
|
||||||
|
|
||||||
|
async up(queryRunner) {
|
||||||
|
await queryRunner.query(`ALTER TABLE "user" DROP COLUMN "avatarDecorations"`);
|
||||||
|
await queryRunner.query(`ALTER TABLE "user" ADD "avatarDecorations" jsonb NOT NULL DEFAULT '[]'`);
|
||||||
|
}
|
||||||
|
|
||||||
|
async down(queryRunner) {
|
||||||
|
await queryRunner.query(`ALTER TABLE "user" DROP COLUMN "avatarDecorations"`);
|
||||||
|
await queryRunner.query(`ALTER TABLE "user" ADD "avatarDecorations" character varying(512) array NOT NULL DEFAULT '{}'`);
|
||||||
|
}
|
||||||
|
}
|
16
packages/backend/migration/1698041201306-enable-ftt.js
Normal file
16
packages/backend/migration/1698041201306-enable-ftt.js
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
export class EnableFtt1698041201306 {
|
||||||
|
name = 'EnableFtt1698041201306'
|
||||||
|
|
||||||
|
async up(queryRunner) {
|
||||||
|
await queryRunner.query(`ALTER TABLE "meta" ADD "enableFanoutTimeline" boolean NOT NULL DEFAULT true`);
|
||||||
|
}
|
||||||
|
|
||||||
|
async down(queryRunner) {
|
||||||
|
await queryRunner.query(`ALTER TABLE "meta" DROP COLUMN "enableFanoutTimeline"`);
|
||||||
|
}
|
||||||
|
}
|
@@ -10,6 +10,7 @@
|
|||||||
"start": "node ./built/index.js",
|
"start": "node ./built/index.js",
|
||||||
"start:test": "NODE_ENV=test node ./built/index.js",
|
"start:test": "NODE_ENV=test node ./built/index.js",
|
||||||
"migrate": "pnpm typeorm migration:run -d ormconfig.js",
|
"migrate": "pnpm typeorm migration:run -d ormconfig.js",
|
||||||
|
"revert": "pnpm typeorm migration:revert -d ormconfig.js",
|
||||||
"check:connect": "node ./check_connect.js",
|
"check:connect": "node ./check_connect.js",
|
||||||
"build": "swc src -d built -D",
|
"build": "swc src -d built -D",
|
||||||
"watch:swc": "swc src -d built -D -w",
|
"watch:swc": "swc src -d built -D -w",
|
||||||
@@ -65,20 +66,20 @@
|
|||||||
"@discordapp/twemoji": "14.1.2",
|
"@discordapp/twemoji": "14.1.2",
|
||||||
"@fastify/accepts": "4.2.0",
|
"@fastify/accepts": "4.2.0",
|
||||||
"@fastify/cookie": "9.1.0",
|
"@fastify/cookie": "9.1.0",
|
||||||
"@fastify/cors": "8.4.0",
|
"@fastify/cors": "8.4.1",
|
||||||
"@fastify/express": "2.3.0",
|
"@fastify/express": "2.3.0",
|
||||||
"@fastify/http-proxy": "9.2.1",
|
"@fastify/http-proxy": "9.2.1",
|
||||||
"@fastify/multipart": "8.0.0",
|
"@fastify/multipart": "8.0.0",
|
||||||
"@fastify/static": "6.11.2",
|
"@fastify/static": "6.12.0",
|
||||||
"@fastify/view": "8.2.0",
|
"@fastify/view": "8.2.0",
|
||||||
"@nestjs/common": "10.2.7",
|
"@nestjs/common": "10.2.7",
|
||||||
"@nestjs/core": "10.2.7",
|
"@nestjs/core": "10.2.7",
|
||||||
"@nestjs/testing": "10.2.7",
|
"@nestjs/testing": "10.2.7",
|
||||||
"@peertube/http-signature": "1.7.0",
|
"@peertube/http-signature": "1.7.0",
|
||||||
"@simplewebauthn/server": "8.3.2",
|
"@simplewebauthn/server": "8.3.5",
|
||||||
"@sinonjs/fake-timers": "11.2.1",
|
"@sinonjs/fake-timers": "11.2.2",
|
||||||
"@swc/cli": "0.1.62",
|
"@swc/cli": "0.1.62",
|
||||||
"@swc/core": "1.3.93",
|
"@swc/core": "1.3.95",
|
||||||
"accepts": "1.3.8",
|
"accepts": "1.3.8",
|
||||||
"ajv": "8.12.0",
|
"ajv": "8.12.0",
|
||||||
"archiver": "6.0.1",
|
"archiver": "6.0.1",
|
||||||
@@ -86,7 +87,7 @@
|
|||||||
"bcryptjs": "2.4.3",
|
"bcryptjs": "2.4.3",
|
||||||
"blurhash": "2.0.5",
|
"blurhash": "2.0.5",
|
||||||
"body-parser": "1.20.2",
|
"body-parser": "1.20.2",
|
||||||
"bullmq": "4.12.5",
|
"bullmq": "4.12.7",
|
||||||
"cacheable-lookup": "7.0.0",
|
"cacheable-lookup": "7.0.0",
|
||||||
"cbor": "9.0.1",
|
"cbor": "9.0.1",
|
||||||
"chalk": "5.3.0",
|
"chalk": "5.3.0",
|
||||||
@@ -124,7 +125,7 @@
|
|||||||
"nanoid": "5.0.2",
|
"nanoid": "5.0.2",
|
||||||
"nested-property": "4.0.0",
|
"nested-property": "4.0.0",
|
||||||
"node-fetch": "3.3.2",
|
"node-fetch": "3.3.2",
|
||||||
"nodemailer": "6.9.6",
|
"nodemailer": "6.9.7",
|
||||||
"nsfwjs": "2.4.2",
|
"nsfwjs": "2.4.2",
|
||||||
"oauth": "0.10.0",
|
"oauth": "0.10.0",
|
||||||
"oauth2orize": "1.12.0",
|
"oauth2orize": "1.12.0",
|
||||||
@@ -137,12 +138,12 @@
|
|||||||
"probe-image-size": "7.2.3",
|
"probe-image-size": "7.2.3",
|
||||||
"promise-limit": "2.7.0",
|
"promise-limit": "2.7.0",
|
||||||
"pug": "3.0.2",
|
"pug": "3.0.2",
|
||||||
"punycode": "2.3.0",
|
"punycode": "2.3.1",
|
||||||
"pureimage": "0.3.17",
|
"pureimage": "0.3.17",
|
||||||
"qrcode": "1.5.3",
|
"qrcode": "1.5.3",
|
||||||
"random-seed": "0.3.0",
|
"random-seed": "0.3.0",
|
||||||
"ratelimiter": "3.4.1",
|
"ratelimiter": "3.4.1",
|
||||||
"re2": "1.20.3",
|
"re2": "1.20.5",
|
||||||
"redis-lock": "0.1.4",
|
"redis-lock": "0.1.4",
|
||||||
"reflect-metadata": "0.1.13",
|
"reflect-metadata": "0.1.13",
|
||||||
"rename": "1.0.4",
|
"rename": "1.0.4",
|
||||||
@@ -155,7 +156,7 @@
|
|||||||
"strict-event-emitter-types": "2.0.0",
|
"strict-event-emitter-types": "2.0.0",
|
||||||
"stringz": "2.1.0",
|
"stringz": "2.1.0",
|
||||||
"summaly": "github:misskey-dev/summaly",
|
"summaly": "github:misskey-dev/summaly",
|
||||||
"systeminformation": "5.21.12",
|
"systeminformation": "5.21.15",
|
||||||
"tinycolor2": "1.6.0",
|
"tinycolor2": "1.6.0",
|
||||||
"tmp": "0.2.1",
|
"tmp": "0.2.1",
|
||||||
"tsc-alias": "1.8.8",
|
"tsc-alias": "1.8.8",
|
||||||
@@ -171,10 +172,10 @@
|
|||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@jest/globals": "29.7.0",
|
"@jest/globals": "29.7.0",
|
||||||
"@simplewebauthn/typescript-types": "8.0.0",
|
"@simplewebauthn/typescript-types": "8.3.4",
|
||||||
"@swc/jest": "0.2.29",
|
"@swc/jest": "0.2.29",
|
||||||
"@types/accepts": "1.3.6",
|
"@types/accepts": "1.3.6",
|
||||||
"@types/archiver": "5.3.4",
|
"@types/archiver": "6.0.0",
|
||||||
"@types/bcryptjs": "2.4.5",
|
"@types/bcryptjs": "2.4.5",
|
||||||
"@types/body-parser": "1.19.4",
|
"@types/body-parser": "1.19.4",
|
||||||
"@types/cbor": "6.0.0",
|
"@types/cbor": "6.0.0",
|
||||||
@@ -182,14 +183,14 @@
|
|||||||
"@types/content-disposition": "0.5.7",
|
"@types/content-disposition": "0.5.7",
|
||||||
"@types/fluent-ffmpeg": "2.1.23",
|
"@types/fluent-ffmpeg": "2.1.23",
|
||||||
"@types/http-link-header": "1.0.4",
|
"@types/http-link-header": "1.0.4",
|
||||||
"@types/jest": "29.5.6",
|
"@types/jest": "29.5.7",
|
||||||
"@types/js-yaml": "4.0.8",
|
"@types/js-yaml": "4.0.8",
|
||||||
"@types/jsdom": "21.1.4",
|
"@types/jsdom": "21.1.4",
|
||||||
"@types/jsonld": "1.5.11",
|
"@types/jsonld": "1.5.11",
|
||||||
"@types/jsrsasign": "10.5.11",
|
"@types/jsrsasign": "10.5.11",
|
||||||
"@types/mime-types": "2.1.3",
|
"@types/mime-types": "2.1.3",
|
||||||
"@types/ms": "0.7.33",
|
"@types/ms": "0.7.33",
|
||||||
"@types/node": "20.8.7",
|
"@types/node": "20.8.10",
|
||||||
"@types/node-fetch": "3.0.3",
|
"@types/node-fetch": "3.0.3",
|
||||||
"@types/nodemailer": "6.4.13",
|
"@types/nodemailer": "6.4.13",
|
||||||
"@types/oauth": "0.9.3",
|
"@types/oauth": "0.9.3",
|
||||||
@@ -212,12 +213,12 @@
|
|||||||
"@types/vary": "1.1.2",
|
"@types/vary": "1.1.2",
|
||||||
"@types/web-push": "3.6.2",
|
"@types/web-push": "3.6.2",
|
||||||
"@types/ws": "8.5.8",
|
"@types/ws": "8.5.8",
|
||||||
"@typescript-eslint/eslint-plugin": "6.8.0",
|
"@typescript-eslint/eslint-plugin": "6.9.1",
|
||||||
"@typescript-eslint/parser": "6.8.0",
|
"@typescript-eslint/parser": "6.9.1",
|
||||||
"aws-sdk-client-mock": "3.0.0",
|
"aws-sdk-client-mock": "3.0.0",
|
||||||
"cross-env": "7.0.3",
|
"cross-env": "7.0.3",
|
||||||
"eslint": "8.51.0",
|
"eslint": "8.52.0",
|
||||||
"eslint-plugin-import": "2.28.1",
|
"eslint-plugin-import": "2.29.0",
|
||||||
"execa": "8.0.1",
|
"execa": "8.0.1",
|
||||||
"jest": "29.7.0",
|
"jest": "29.7.0",
|
||||||
"jest-mock": "29.7.0",
|
"jest-mock": "29.7.0",
|
||||||
|
@@ -258,7 +258,7 @@ export function loadConfig(): Config {
|
|||||||
clientEntry: clientManifest['src/_boot_.ts'],
|
clientEntry: clientManifest['src/_boot_.ts'],
|
||||||
clientManifestExists: clientManifestExists,
|
clientManifestExists: clientManifestExists,
|
||||||
perChannelMaxNoteCacheCount: config.perChannelMaxNoteCacheCount ?? 1000,
|
perChannelMaxNoteCacheCount: config.perChannelMaxNoteCacheCount ?? 1000,
|
||||||
perUserNotificationsMaxCount: config.perUserNotificationsMaxCount ?? 300,
|
perUserNotificationsMaxCount: config.perUserNotificationsMaxCount ?? 500,
|
||||||
deactivateAntennaThreshold: config.deactivateAntennaThreshold ?? (1000 * 60 * 60 * 24 * 7),
|
deactivateAntennaThreshold: config.deactivateAntennaThreshold ?? (1000 * 60 * 60 * 24 * 7),
|
||||||
pidFile: config.pidFile,
|
pidFile: config.pidFile,
|
||||||
};
|
};
|
||||||
|
129
packages/backend/src/core/AvatarDecorationService.ts
Normal file
129
packages/backend/src/core/AvatarDecorationService.ts
Normal file
@@ -0,0 +1,129 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { Inject, Injectable, OnApplicationShutdown } from '@nestjs/common';
|
||||||
|
import * as Redis from 'ioredis';
|
||||||
|
import type { AvatarDecorationsRepository, MiAvatarDecoration, MiUser } from '@/models/_.js';
|
||||||
|
import { IdService } from '@/core/IdService.js';
|
||||||
|
import { GlobalEventService } from '@/core/GlobalEventService.js';
|
||||||
|
import { DI } from '@/di-symbols.js';
|
||||||
|
import { bindThis } from '@/decorators.js';
|
||||||
|
import { MemorySingleCache } from '@/misc/cache.js';
|
||||||
|
import type { GlobalEvents } from '@/core/GlobalEventService.js';
|
||||||
|
import { ModerationLogService } from '@/core/ModerationLogService.js';
|
||||||
|
|
||||||
|
@Injectable()
|
||||||
|
export class AvatarDecorationService implements OnApplicationShutdown {
|
||||||
|
public cache: MemorySingleCache<MiAvatarDecoration[]>;
|
||||||
|
|
||||||
|
constructor(
|
||||||
|
@Inject(DI.redisForSub)
|
||||||
|
private redisForSub: Redis.Redis,
|
||||||
|
|
||||||
|
@Inject(DI.avatarDecorationsRepository)
|
||||||
|
private avatarDecorationsRepository: AvatarDecorationsRepository,
|
||||||
|
|
||||||
|
private idService: IdService,
|
||||||
|
private moderationLogService: ModerationLogService,
|
||||||
|
private globalEventService: GlobalEventService,
|
||||||
|
) {
|
||||||
|
this.cache = new MemorySingleCache<MiAvatarDecoration[]>(1000 * 60 * 30);
|
||||||
|
|
||||||
|
this.redisForSub.on('message', this.onMessage);
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
private async onMessage(_: string, data: string): Promise<void> {
|
||||||
|
const obj = JSON.parse(data);
|
||||||
|
|
||||||
|
if (obj.channel === 'internal') {
|
||||||
|
const { type, body } = obj.message as GlobalEvents['internal']['payload'];
|
||||||
|
switch (type) {
|
||||||
|
case 'avatarDecorationCreated':
|
||||||
|
case 'avatarDecorationUpdated':
|
||||||
|
case 'avatarDecorationDeleted': {
|
||||||
|
this.cache.delete();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public async create(options: Partial<MiAvatarDecoration>, moderator?: MiUser): Promise<MiAvatarDecoration> {
|
||||||
|
const created = await this.avatarDecorationsRepository.insert({
|
||||||
|
id: this.idService.gen(),
|
||||||
|
...options,
|
||||||
|
}).then(x => this.avatarDecorationsRepository.findOneByOrFail(x.identifiers[0]));
|
||||||
|
|
||||||
|
this.globalEventService.publishInternalEvent('avatarDecorationCreated', created);
|
||||||
|
|
||||||
|
if (moderator) {
|
||||||
|
this.moderationLogService.log(moderator, 'createAvatarDecoration', {
|
||||||
|
avatarDecorationId: created.id,
|
||||||
|
avatarDecoration: created,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
return created;
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public async update(id: MiAvatarDecoration['id'], params: Partial<MiAvatarDecoration>, moderator?: MiUser): Promise<void> {
|
||||||
|
const avatarDecoration = await this.avatarDecorationsRepository.findOneByOrFail({ id });
|
||||||
|
|
||||||
|
const date = new Date();
|
||||||
|
await this.avatarDecorationsRepository.update(avatarDecoration.id, {
|
||||||
|
updatedAt: date,
|
||||||
|
...params,
|
||||||
|
});
|
||||||
|
|
||||||
|
const updated = await this.avatarDecorationsRepository.findOneByOrFail({ id: avatarDecoration.id });
|
||||||
|
this.globalEventService.publishInternalEvent('avatarDecorationUpdated', updated);
|
||||||
|
|
||||||
|
if (moderator) {
|
||||||
|
this.moderationLogService.log(moderator, 'updateAvatarDecoration', {
|
||||||
|
avatarDecorationId: avatarDecoration.id,
|
||||||
|
before: avatarDecoration,
|
||||||
|
after: updated,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public async delete(id: MiAvatarDecoration['id'], moderator?: MiUser): Promise<void> {
|
||||||
|
const avatarDecoration = await this.avatarDecorationsRepository.findOneByOrFail({ id });
|
||||||
|
|
||||||
|
await this.avatarDecorationsRepository.delete({ id: avatarDecoration.id });
|
||||||
|
this.globalEventService.publishInternalEvent('avatarDecorationDeleted', avatarDecoration);
|
||||||
|
|
||||||
|
if (moderator) {
|
||||||
|
this.moderationLogService.log(moderator, 'deleteAvatarDecoration', {
|
||||||
|
avatarDecorationId: avatarDecoration.id,
|
||||||
|
avatarDecoration: avatarDecoration,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public async getAll(noCache = false): Promise<MiAvatarDecoration[]> {
|
||||||
|
if (noCache) {
|
||||||
|
this.cache.delete();
|
||||||
|
}
|
||||||
|
return this.cache.fetch(() => this.avatarDecorationsRepository.find());
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public dispose(): void {
|
||||||
|
this.redisForSub.off('message', this.onMessage);
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public onApplicationShutdown(signal?: string | undefined): void {
|
||||||
|
this.dispose();
|
||||||
|
}
|
||||||
|
}
|
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
import { Inject, Injectable } from '@nestjs/common';
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
import * as Redis from 'ioredis';
|
import * as Redis from 'ioredis';
|
||||||
import type { BlockingsRepository, ChannelFollowingsRepository, FollowingsRepository, MutingsRepository, RenoteMutingsRepository, MiUserProfile, UserProfilesRepository, UsersRepository, MiFollowing } from '@/models/_.js';
|
import type { BlockingsRepository, FollowingsRepository, MutingsRepository, RenoteMutingsRepository, MiUserProfile, UserProfilesRepository, UsersRepository, MiFollowing } from '@/models/_.js';
|
||||||
import { MemoryKVCache, RedisKVCache } from '@/misc/cache.js';
|
import { MemoryKVCache, RedisKVCache } from '@/misc/cache.js';
|
||||||
import type { MiLocalUser, MiUser } from '@/models/User.js';
|
import type { MiLocalUser, MiUser } from '@/models/User.js';
|
||||||
import { DI } from '@/di-symbols.js';
|
import { DI } from '@/di-symbols.js';
|
||||||
@@ -26,7 +26,6 @@ export class CacheService implements OnApplicationShutdown {
|
|||||||
public userBlockedCache: RedisKVCache<Set<string>>; // NOTE: 「被」Blockキャッシュ
|
public userBlockedCache: RedisKVCache<Set<string>>; // NOTE: 「被」Blockキャッシュ
|
||||||
public renoteMutingsCache: RedisKVCache<Set<string>>;
|
public renoteMutingsCache: RedisKVCache<Set<string>>;
|
||||||
public userFollowingsCache: RedisKVCache<Record<string, Pick<MiFollowing, 'withReplies'> | undefined>>;
|
public userFollowingsCache: RedisKVCache<Record<string, Pick<MiFollowing, 'withReplies'> | undefined>>;
|
||||||
public userFollowingChannelsCache: RedisKVCache<Set<string>>;
|
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
@Inject(DI.redis)
|
@Inject(DI.redis)
|
||||||
@@ -53,9 +52,6 @@ export class CacheService implements OnApplicationShutdown {
|
|||||||
@Inject(DI.followingsRepository)
|
@Inject(DI.followingsRepository)
|
||||||
private followingsRepository: FollowingsRepository,
|
private followingsRepository: FollowingsRepository,
|
||||||
|
|
||||||
@Inject(DI.channelFollowingsRepository)
|
|
||||||
private channelFollowingsRepository: ChannelFollowingsRepository,
|
|
||||||
|
|
||||||
private userEntityService: UserEntityService,
|
private userEntityService: UserEntityService,
|
||||||
) {
|
) {
|
||||||
//this.onMessage = this.onMessage.bind(this);
|
//this.onMessage = this.onMessage.bind(this);
|
||||||
@@ -150,13 +146,7 @@ export class CacheService implements OnApplicationShutdown {
|
|||||||
fromRedisConverter: (value) => JSON.parse(value),
|
fromRedisConverter: (value) => JSON.parse(value),
|
||||||
});
|
});
|
||||||
|
|
||||||
this.userFollowingChannelsCache = new RedisKVCache<Set<string>>(this.redisClient, 'userFollowingChannels', {
|
// NOTE: チャンネルのフォロー状況キャッシュはChannelFollowingServiceで行っている
|
||||||
lifetime: 1000 * 60 * 30, // 30m
|
|
||||||
memoryCacheLifetime: 1000 * 60, // 1m
|
|
||||||
fetcher: (key) => this.channelFollowingsRepository.find({ where: { followerId: key }, select: ['followeeId'] }).then(xs => new Set(xs.map(x => x.followeeId))),
|
|
||||||
toRedisConverter: (value) => JSON.stringify(Array.from(value)),
|
|
||||||
fromRedisConverter: (value) => new Set(JSON.parse(value)),
|
|
||||||
});
|
|
||||||
|
|
||||||
this.redisForSub.on('message', this.onMessage);
|
this.redisForSub.on('message', this.onMessage);
|
||||||
}
|
}
|
||||||
@@ -221,7 +211,6 @@ export class CacheService implements OnApplicationShutdown {
|
|||||||
this.userBlockedCache.dispose();
|
this.userBlockedCache.dispose();
|
||||||
this.renoteMutingsCache.dispose();
|
this.renoteMutingsCache.dispose();
|
||||||
this.userFollowingsCache.dispose();
|
this.userFollowingsCache.dispose();
|
||||||
this.userFollowingChannelsCache.dispose();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@bindThis
|
@bindThis
|
||||||
|
104
packages/backend/src/core/ChannelFollowingService.ts
Normal file
104
packages/backend/src/core/ChannelFollowingService.ts
Normal file
@@ -0,0 +1,104 @@
|
|||||||
|
import { Inject, Injectable, OnModuleInit } from '@nestjs/common';
|
||||||
|
import Redis from 'ioredis';
|
||||||
|
import { DI } from '@/di-symbols.js';
|
||||||
|
import type { ChannelFollowingsRepository } from '@/models/_.js';
|
||||||
|
import { MiChannel } from '@/models/_.js';
|
||||||
|
import { IdService } from '@/core/IdService.js';
|
||||||
|
import { GlobalEvents, GlobalEventService } from '@/core/GlobalEventService.js';
|
||||||
|
import { bindThis } from '@/decorators.js';
|
||||||
|
import type { MiLocalUser } from '@/models/User.js';
|
||||||
|
import { RedisKVCache } from '@/misc/cache.js';
|
||||||
|
|
||||||
|
@Injectable()
|
||||||
|
export class ChannelFollowingService implements OnModuleInit {
|
||||||
|
public userFollowingChannelsCache: RedisKVCache<Set<string>>;
|
||||||
|
|
||||||
|
constructor(
|
||||||
|
@Inject(DI.redis)
|
||||||
|
private redisClient: Redis.Redis,
|
||||||
|
@Inject(DI.redisForSub)
|
||||||
|
private redisForSub: Redis.Redis,
|
||||||
|
@Inject(DI.channelFollowingsRepository)
|
||||||
|
private channelFollowingsRepository: ChannelFollowingsRepository,
|
||||||
|
private idService: IdService,
|
||||||
|
private globalEventService: GlobalEventService,
|
||||||
|
) {
|
||||||
|
this.userFollowingChannelsCache = new RedisKVCache<Set<string>>(this.redisClient, 'userFollowingChannels', {
|
||||||
|
lifetime: 1000 * 60 * 30, // 30m
|
||||||
|
memoryCacheLifetime: 1000 * 60, // 1m
|
||||||
|
fetcher: (key) => this.channelFollowingsRepository.find({
|
||||||
|
where: { followerId: key },
|
||||||
|
select: ['followeeId'],
|
||||||
|
}).then(xs => new Set(xs.map(x => x.followeeId))),
|
||||||
|
toRedisConverter: (value) => JSON.stringify(Array.from(value)),
|
||||||
|
fromRedisConverter: (value) => new Set(JSON.parse(value)),
|
||||||
|
});
|
||||||
|
|
||||||
|
this.redisForSub.on('message', this.onMessage);
|
||||||
|
}
|
||||||
|
|
||||||
|
onModuleInit() {
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public async follow(
|
||||||
|
requestUser: MiLocalUser,
|
||||||
|
targetChannel: MiChannel,
|
||||||
|
): Promise<void> {
|
||||||
|
await this.channelFollowingsRepository.insert({
|
||||||
|
id: this.idService.gen(),
|
||||||
|
followerId: requestUser.id,
|
||||||
|
followeeId: targetChannel.id,
|
||||||
|
});
|
||||||
|
|
||||||
|
this.globalEventService.publishInternalEvent('followChannel', {
|
||||||
|
userId: requestUser.id,
|
||||||
|
channelId: targetChannel.id,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public async unfollow(
|
||||||
|
requestUser: MiLocalUser,
|
||||||
|
targetChannel: MiChannel,
|
||||||
|
): Promise<void> {
|
||||||
|
await this.channelFollowingsRepository.delete({
|
||||||
|
followerId: requestUser.id,
|
||||||
|
followeeId: targetChannel.id,
|
||||||
|
});
|
||||||
|
|
||||||
|
this.globalEventService.publishInternalEvent('unfollowChannel', {
|
||||||
|
userId: requestUser.id,
|
||||||
|
channelId: targetChannel.id,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
private async onMessage(_: string, data: string): Promise<void> {
|
||||||
|
const obj = JSON.parse(data);
|
||||||
|
|
||||||
|
if (obj.channel === 'internal') {
|
||||||
|
const { type, body } = obj.message as GlobalEvents['internal']['payload'];
|
||||||
|
switch (type) {
|
||||||
|
case 'followChannel': {
|
||||||
|
this.userFollowingChannelsCache.refresh(body.userId);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'unfollowChannel': {
|
||||||
|
this.userFollowingChannelsCache.delete(body.userId);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public dispose(): void {
|
||||||
|
this.userFollowingChannelsCache.dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public onApplicationShutdown(signal?: string | undefined): void {
|
||||||
|
this.dispose();
|
||||||
|
}
|
||||||
|
}
|
@@ -11,6 +11,7 @@ import { AnnouncementService } from './AnnouncementService.js';
|
|||||||
import { AntennaService } from './AntennaService.js';
|
import { AntennaService } from './AntennaService.js';
|
||||||
import { AppLockService } from './AppLockService.js';
|
import { AppLockService } from './AppLockService.js';
|
||||||
import { AchievementService } from './AchievementService.js';
|
import { AchievementService } from './AchievementService.js';
|
||||||
|
import { AvatarDecorationService } from './AvatarDecorationService.js';
|
||||||
import { CaptchaService } from './CaptchaService.js';
|
import { CaptchaService } from './CaptchaService.js';
|
||||||
import { CreateSystemUserService } from './CreateSystemUserService.js';
|
import { CreateSystemUserService } from './CreateSystemUserService.js';
|
||||||
import { CustomEmojiService } from './CustomEmojiService.js';
|
import { CustomEmojiService } from './CustomEmojiService.js';
|
||||||
@@ -62,6 +63,7 @@ import { SearchService } from './SearchService.js';
|
|||||||
import { ClipService } from './ClipService.js';
|
import { ClipService } from './ClipService.js';
|
||||||
import { FeaturedService } from './FeaturedService.js';
|
import { FeaturedService } from './FeaturedService.js';
|
||||||
import { FunoutTimelineService } from './FunoutTimelineService.js';
|
import { FunoutTimelineService } from './FunoutTimelineService.js';
|
||||||
|
import { ChannelFollowingService } from './ChannelFollowingService.js';
|
||||||
import { ChartLoggerService } from './chart/ChartLoggerService.js';
|
import { ChartLoggerService } from './chart/ChartLoggerService.js';
|
||||||
import FederationChart from './chart/charts/federation.js';
|
import FederationChart from './chart/charts/federation.js';
|
||||||
import NotesChart from './chart/charts/notes.js';
|
import NotesChart from './chart/charts/notes.js';
|
||||||
@@ -140,6 +142,7 @@ const $AnnouncementService: Provider = { provide: 'AnnouncementService', useExis
|
|||||||
const $AntennaService: Provider = { provide: 'AntennaService', useExisting: AntennaService };
|
const $AntennaService: Provider = { provide: 'AntennaService', useExisting: AntennaService };
|
||||||
const $AppLockService: Provider = { provide: 'AppLockService', useExisting: AppLockService };
|
const $AppLockService: Provider = { provide: 'AppLockService', useExisting: AppLockService };
|
||||||
const $AchievementService: Provider = { provide: 'AchievementService', useExisting: AchievementService };
|
const $AchievementService: Provider = { provide: 'AchievementService', useExisting: AchievementService };
|
||||||
|
const $AvatarDecorationService: Provider = { provide: 'AvatarDecorationService', useExisting: AvatarDecorationService };
|
||||||
const $CaptchaService: Provider = { provide: 'CaptchaService', useExisting: CaptchaService };
|
const $CaptchaService: Provider = { provide: 'CaptchaService', useExisting: CaptchaService };
|
||||||
const $CreateSystemUserService: Provider = { provide: 'CreateSystemUserService', useExisting: CreateSystemUserService };
|
const $CreateSystemUserService: Provider = { provide: 'CreateSystemUserService', useExisting: CreateSystemUserService };
|
||||||
const $CustomEmojiService: Provider = { provide: 'CustomEmojiService', useExisting: CustomEmojiService };
|
const $CustomEmojiService: Provider = { provide: 'CustomEmojiService', useExisting: CustomEmojiService };
|
||||||
@@ -191,6 +194,7 @@ const $SearchService: Provider = { provide: 'SearchService', useExisting: Search
|
|||||||
const $ClipService: Provider = { provide: 'ClipService', useExisting: ClipService };
|
const $ClipService: Provider = { provide: 'ClipService', useExisting: ClipService };
|
||||||
const $FeaturedService: Provider = { provide: 'FeaturedService', useExisting: FeaturedService };
|
const $FeaturedService: Provider = { provide: 'FeaturedService', useExisting: FeaturedService };
|
||||||
const $FunoutTimelineService: Provider = { provide: 'FunoutTimelineService', useExisting: FunoutTimelineService };
|
const $FunoutTimelineService: Provider = { provide: 'FunoutTimelineService', useExisting: FunoutTimelineService };
|
||||||
|
const $ChannelFollowingService: Provider = { provide: 'ChannelFollowingService', useExisting: ChannelFollowingService };
|
||||||
|
|
||||||
const $ChartLoggerService: Provider = { provide: 'ChartLoggerService', useExisting: ChartLoggerService };
|
const $ChartLoggerService: Provider = { provide: 'ChartLoggerService', useExisting: ChartLoggerService };
|
||||||
const $FederationChart: Provider = { provide: 'FederationChart', useExisting: FederationChart };
|
const $FederationChart: Provider = { provide: 'FederationChart', useExisting: FederationChart };
|
||||||
@@ -273,6 +277,7 @@ const $ApQuestionService: Provider = { provide: 'ApQuestionService', useExisting
|
|||||||
AntennaService,
|
AntennaService,
|
||||||
AppLockService,
|
AppLockService,
|
||||||
AchievementService,
|
AchievementService,
|
||||||
|
AvatarDecorationService,
|
||||||
CaptchaService,
|
CaptchaService,
|
||||||
CreateSystemUserService,
|
CreateSystemUserService,
|
||||||
CustomEmojiService,
|
CustomEmojiService,
|
||||||
@@ -324,6 +329,7 @@ const $ApQuestionService: Provider = { provide: 'ApQuestionService', useExisting
|
|||||||
ClipService,
|
ClipService,
|
||||||
FeaturedService,
|
FeaturedService,
|
||||||
FunoutTimelineService,
|
FunoutTimelineService,
|
||||||
|
ChannelFollowingService,
|
||||||
ChartLoggerService,
|
ChartLoggerService,
|
||||||
FederationChart,
|
FederationChart,
|
||||||
NotesChart,
|
NotesChart,
|
||||||
@@ -399,6 +405,7 @@ const $ApQuestionService: Provider = { provide: 'ApQuestionService', useExisting
|
|||||||
$AntennaService,
|
$AntennaService,
|
||||||
$AppLockService,
|
$AppLockService,
|
||||||
$AchievementService,
|
$AchievementService,
|
||||||
|
$AvatarDecorationService,
|
||||||
$CaptchaService,
|
$CaptchaService,
|
||||||
$CreateSystemUserService,
|
$CreateSystemUserService,
|
||||||
$CustomEmojiService,
|
$CustomEmojiService,
|
||||||
@@ -450,6 +457,7 @@ const $ApQuestionService: Provider = { provide: 'ApQuestionService', useExisting
|
|||||||
$ClipService,
|
$ClipService,
|
||||||
$FeaturedService,
|
$FeaturedService,
|
||||||
$FunoutTimelineService,
|
$FunoutTimelineService,
|
||||||
|
$ChannelFollowingService,
|
||||||
$ChartLoggerService,
|
$ChartLoggerService,
|
||||||
$FederationChart,
|
$FederationChart,
|
||||||
$NotesChart,
|
$NotesChart,
|
||||||
@@ -526,6 +534,7 @@ const $ApQuestionService: Provider = { provide: 'ApQuestionService', useExisting
|
|||||||
AntennaService,
|
AntennaService,
|
||||||
AppLockService,
|
AppLockService,
|
||||||
AchievementService,
|
AchievementService,
|
||||||
|
AvatarDecorationService,
|
||||||
CaptchaService,
|
CaptchaService,
|
||||||
CreateSystemUserService,
|
CreateSystemUserService,
|
||||||
CustomEmojiService,
|
CustomEmojiService,
|
||||||
@@ -577,6 +586,7 @@ const $ApQuestionService: Provider = { provide: 'ApQuestionService', useExisting
|
|||||||
ClipService,
|
ClipService,
|
||||||
FeaturedService,
|
FeaturedService,
|
||||||
FunoutTimelineService,
|
FunoutTimelineService,
|
||||||
|
ChannelFollowingService,
|
||||||
FederationChart,
|
FederationChart,
|
||||||
NotesChart,
|
NotesChart,
|
||||||
UsersChart,
|
UsersChart,
|
||||||
@@ -651,6 +661,7 @@ const $ApQuestionService: Provider = { provide: 'ApQuestionService', useExisting
|
|||||||
$AntennaService,
|
$AntennaService,
|
||||||
$AppLockService,
|
$AppLockService,
|
||||||
$AchievementService,
|
$AchievementService,
|
||||||
|
$AvatarDecorationService,
|
||||||
$CaptchaService,
|
$CaptchaService,
|
||||||
$CreateSystemUserService,
|
$CreateSystemUserService,
|
||||||
$CustomEmojiService,
|
$CustomEmojiService,
|
||||||
@@ -702,6 +713,7 @@ const $ApQuestionService: Provider = { provide: 'ApQuestionService', useExisting
|
|||||||
$ClipService,
|
$ClipService,
|
||||||
$FeaturedService,
|
$FeaturedService,
|
||||||
$FunoutTimelineService,
|
$FunoutTimelineService,
|
||||||
|
$ChannelFollowingService,
|
||||||
$FederationChart,
|
$FederationChart,
|
||||||
$NotesChart,
|
$NotesChart,
|
||||||
$UsersChart,
|
$UsersChart,
|
||||||
|
@@ -52,7 +52,7 @@ export class FeaturedService {
|
|||||||
`${name}:${currentWindow}`, 0, threshold, 'REV', 'WITHSCORES');
|
`${name}:${currentWindow}`, 0, threshold, 'REV', 'WITHSCORES');
|
||||||
redisPipeline.zrange(
|
redisPipeline.zrange(
|
||||||
`${name}:${previousWindow}`, 0, threshold, 'REV', 'WITHSCORES');
|
`${name}:${previousWindow}`, 0, threshold, 'REV', 'WITHSCORES');
|
||||||
const [currentRankingResult, previousRankingResult] = await redisPipeline.exec().then(result => result ? result.map(r => r[1] as string[]) : [[], []]);
|
const [currentRankingResult, previousRankingResult] = await redisPipeline.exec().then(result => result ? result.map(r => (r[1] ?? []) as string[]) : [[], []]);
|
||||||
|
|
||||||
const ranking = new Map<string, number>();
|
const ranking = new Map<string, number>();
|
||||||
for (let i = 0; i < currentRankingResult.length; i += 2) {
|
for (let i = 0; i < currentRankingResult.length; i += 2) {
|
||||||
|
@@ -18,7 +18,7 @@ import type { MiSignin } from '@/models/Signin.js';
|
|||||||
import type { MiPage } from '@/models/Page.js';
|
import type { MiPage } from '@/models/Page.js';
|
||||||
import type { MiWebhook } from '@/models/Webhook.js';
|
import type { MiWebhook } from '@/models/Webhook.js';
|
||||||
import type { MiMeta } from '@/models/Meta.js';
|
import type { MiMeta } from '@/models/Meta.js';
|
||||||
import { MiRole, MiRoleAssignment } from '@/models/_.js';
|
import { MiAvatarDecoration, MiRole, MiRoleAssignment } from '@/models/_.js';
|
||||||
import type { Packed } from '@/misc/json-schema.js';
|
import type { Packed } from '@/misc/json-schema.js';
|
||||||
import { DI } from '@/di-symbols.js';
|
import { DI } from '@/di-symbols.js';
|
||||||
import type { Config } from '@/config.js';
|
import type { Config } from '@/config.js';
|
||||||
@@ -77,7 +77,13 @@ export interface MainEventTypes {
|
|||||||
unreadAntenna: MiAntenna;
|
unreadAntenna: MiAntenna;
|
||||||
readAllAnnouncements: undefined;
|
readAllAnnouncements: undefined;
|
||||||
myTokenRegenerated: undefined;
|
myTokenRegenerated: undefined;
|
||||||
signin: MiSignin;
|
signin: {
|
||||||
|
id: MiSignin['id'];
|
||||||
|
createdAt: string;
|
||||||
|
ip: string;
|
||||||
|
headers: Record<string, any>;
|
||||||
|
success: boolean;
|
||||||
|
};
|
||||||
registryUpdated: {
|
registryUpdated: {
|
||||||
scope?: string[];
|
scope?: string[];
|
||||||
key: string;
|
key: string;
|
||||||
@@ -188,6 +194,9 @@ export interface InternalEventTypes {
|
|||||||
antennaCreated: MiAntenna;
|
antennaCreated: MiAntenna;
|
||||||
antennaDeleted: MiAntenna;
|
antennaDeleted: MiAntenna;
|
||||||
antennaUpdated: MiAntenna;
|
antennaUpdated: MiAntenna;
|
||||||
|
avatarDecorationCreated: MiAvatarDecoration;
|
||||||
|
avatarDecorationDeleted: MiAvatarDecoration;
|
||||||
|
avatarDecorationUpdated: MiAvatarDecoration;
|
||||||
metaUpdated: MiMeta;
|
metaUpdated: MiMeta;
|
||||||
followChannel: { userId: MiUser['id']; channelId: MiChannel['id']; };
|
followChannel: { userId: MiUser['id']; channelId: MiChannel['id']; };
|
||||||
unfollowChannel: { userId: MiUser['id']; channelId: MiChannel['id']; };
|
unfollowChannel: { userId: MiUser['id']; channelId: MiChannel['id']; };
|
||||||
|
@@ -56,6 +56,7 @@ import { SearchService } from '@/core/SearchService.js';
|
|||||||
import { FeaturedService } from '@/core/FeaturedService.js';
|
import { FeaturedService } from '@/core/FeaturedService.js';
|
||||||
import { FunoutTimelineService } from '@/core/FunoutTimelineService.js';
|
import { FunoutTimelineService } from '@/core/FunoutTimelineService.js';
|
||||||
import { UtilityService } from '@/core/UtilityService.js';
|
import { UtilityService } from '@/core/UtilityService.js';
|
||||||
|
import { UserBlockingService } from '@/core/UserBlockingService.js';
|
||||||
|
|
||||||
type NotificationType = 'reply' | 'renote' | 'quote' | 'mention';
|
type NotificationType = 'reply' | 'renote' | 'quote' | 'mention';
|
||||||
|
|
||||||
@@ -99,17 +100,14 @@ class NotificationManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@bindThis
|
@bindThis
|
||||||
public async deliver() {
|
public async notify() {
|
||||||
for (const x of this.queue) {
|
for (const x of this.queue) {
|
||||||
// ミュート情報を取得
|
if (x.reason === 'renote') {
|
||||||
const mentioneeMutes = await this.mutingsRepository.findBy({
|
this.notificationService.createNotification(x.target, 'renote', {
|
||||||
muterId: x.target,
|
noteId: this.note.id,
|
||||||
});
|
targetNoteId: this.note.renoteId!,
|
||||||
|
}, this.notifier.id);
|
||||||
const mentioneesMutedUserIds = mentioneeMutes.map(m => m.muteeId);
|
} else {
|
||||||
|
|
||||||
// 通知される側のユーザーが通知する側のユーザーをミュートしていない限りは通知する
|
|
||||||
if (!mentioneesMutedUserIds.includes(this.notifier.id)) {
|
|
||||||
this.notificationService.createNotification(x.target, x.reason, {
|
this.notificationService.createNotification(x.target, x.reason, {
|
||||||
noteId: this.note.id,
|
noteId: this.note.id,
|
||||||
}, this.notifier.id);
|
}, this.notifier.id);
|
||||||
@@ -216,6 +214,7 @@ export class NoteCreateService implements OnApplicationShutdown {
|
|||||||
private activeUsersChart: ActiveUsersChart,
|
private activeUsersChart: ActiveUsersChart,
|
||||||
private instanceChart: InstanceChart,
|
private instanceChart: InstanceChart,
|
||||||
private utilityService: UtilityService,
|
private utilityService: UtilityService,
|
||||||
|
private userBlockingService: UserBlockingService,
|
||||||
) { }
|
) { }
|
||||||
|
|
||||||
@bindThis
|
@bindThis
|
||||||
@@ -292,6 +291,18 @@ export class NoteCreateService implements OnApplicationShutdown {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Check blocking
|
||||||
|
if (data.renote && data.text == null && data.poll == null && (data.files == null || data.files.length === 0)) {
|
||||||
|
if (data.renote.userHost === null) {
|
||||||
|
if (data.renote.userId !== user.id) {
|
||||||
|
const blocked = await this.userBlockingService.checkBlocked(data.renote.userId, user.id);
|
||||||
|
if (blocked) {
|
||||||
|
throw new Error('blocked');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// 返信対象がpublicではないならhomeにする
|
// 返信対象がpublicではないならhomeにする
|
||||||
if (data.reply && data.reply.visibility !== 'public' && data.visibility === 'public') {
|
if (data.reply && data.reply.visibility !== 'public' && data.visibility === 'public') {
|
||||||
data.visibility = 'home';
|
data.visibility = 'home';
|
||||||
@@ -628,7 +639,7 @@ export class NoteCreateService implements OnApplicationShutdown {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
nm.deliver();
|
nm.notify();
|
||||||
|
|
||||||
//#region AP deliver
|
//#region AP deliver
|
||||||
if (this.userEntityService.isLocalUser(user)) {
|
if (this.userEntityService.isLocalUser(user)) {
|
||||||
@@ -825,6 +836,7 @@ export class NoteCreateService implements OnApplicationShutdown {
|
|||||||
@bindThis
|
@bindThis
|
||||||
private async pushToTl(note: MiNote, user: { id: MiUser['id']; host: MiUser['host']; }) {
|
private async pushToTl(note: MiNote, user: { id: MiUser['id']; host: MiUser['host']; }) {
|
||||||
const meta = await this.metaService.fetch();
|
const meta = await this.metaService.fetch();
|
||||||
|
if (!meta.enableFanoutTimeline) return;
|
||||||
|
|
||||||
const r = this.redisForTimelines.pipeline();
|
const r = this.redisForTimelines.pipeline();
|
||||||
|
|
||||||
@@ -868,7 +880,7 @@ export class NoteCreateService implements OnApplicationShutdown {
|
|||||||
|
|
||||||
if (note.visibility === 'followers') {
|
if (note.visibility === 'followers') {
|
||||||
// TODO: 重そうだから何とかしたい Set 使う?
|
// TODO: 重そうだから何とかしたい Set 使う?
|
||||||
userListMemberships = userListMemberships.filter(x => followings.some(f => f.followerId === x.userListUserId));
|
userListMemberships = userListMemberships.filter(x => x.userListUserId === user.id || followings.some(f => f.followerId === x.userListUserId));
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: あまりにも数が多いと redisPipeline.exec に失敗する(理由は不明)ため、3万件程度を目安に分割して実行するようにする
|
// TODO: あまりにも数が多いと redisPipeline.exec に失敗する(理由は不明)ため、3万件程度を目安に分割して実行するようにする
|
||||||
|
@@ -24,6 +24,7 @@ import { bindThis } from '@/decorators.js';
|
|||||||
import { MetaService } from '@/core/MetaService.js';
|
import { MetaService } from '@/core/MetaService.js';
|
||||||
import { SearchService } from '@/core/SearchService.js';
|
import { SearchService } from '@/core/SearchService.js';
|
||||||
import { ModerationLogService } from '@/core/ModerationLogService.js';
|
import { ModerationLogService } from '@/core/ModerationLogService.js';
|
||||||
|
import { isPureRenote } from '@/misc/is-pure-renote.js';
|
||||||
|
|
||||||
@Injectable()
|
@Injectable()
|
||||||
export class NoteDeleteService {
|
export class NoteDeleteService {
|
||||||
@@ -77,8 +78,8 @@ export class NoteDeleteService {
|
|||||||
if (this.userEntityService.isLocalUser(user) && !note.localOnly) {
|
if (this.userEntityService.isLocalUser(user) && !note.localOnly) {
|
||||||
let renote: MiNote | null = null;
|
let renote: MiNote | null = null;
|
||||||
|
|
||||||
// if deletd note is renote
|
// if deleted note is renote
|
||||||
if (note.renoteId && note.text == null && !note.hasPoll && (note.fileIds == null || note.fileIds.length === 0)) {
|
if (isPureRenote(note)) {
|
||||||
renote = await this.notesRepository.findOneBy({
|
renote = await this.notesRepository.findOneBy({
|
||||||
id: note.renoteId,
|
id: note.renoteId,
|
||||||
});
|
});
|
||||||
|
@@ -19,6 +19,7 @@ import { IdService } from '@/core/IdService.js';
|
|||||||
import { CacheService } from '@/core/CacheService.js';
|
import { CacheService } from '@/core/CacheService.js';
|
||||||
import type { Config } from '@/config.js';
|
import type { Config } from '@/config.js';
|
||||||
import { UserListService } from '@/core/UserListService.js';
|
import { UserListService } from '@/core/UserListService.js';
|
||||||
|
import type { FilterUnionByProperty } from '@/types.js';
|
||||||
|
|
||||||
@Injectable()
|
@Injectable()
|
||||||
export class NotificationService implements OnApplicationShutdown {
|
export class NotificationService implements OnApplicationShutdown {
|
||||||
@@ -73,10 +74,10 @@ export class NotificationService implements OnApplicationShutdown {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@bindThis
|
@bindThis
|
||||||
public async createNotification(
|
public async createNotification<T extends MiNotification['type']>(
|
||||||
notifieeId: MiUser['id'],
|
notifieeId: MiUser['id'],
|
||||||
type: MiNotification['type'],
|
type: T,
|
||||||
data: Omit<Partial<MiNotification>, 'notifierId'>,
|
data: Omit<FilterUnionByProperty<MiNotification, 'type', T>, 'type' | 'id' | 'createdAt' | 'notifierId'>,
|
||||||
notifierId?: MiUser['id'] | null,
|
notifierId?: MiUser['id'] | null,
|
||||||
): Promise<MiNotification | null> {
|
): Promise<MiNotification | null> {
|
||||||
const profile = await this.cacheService.userProfileCache.fetch(notifieeId);
|
const profile = await this.cacheService.userProfileCache.fetch(notifieeId);
|
||||||
@@ -128,9 +129,11 @@ export class NotificationService implements OnApplicationShutdown {
|
|||||||
id: this.idService.gen(),
|
id: this.idService.gen(),
|
||||||
createdAt: new Date(),
|
createdAt: new Date(),
|
||||||
type: type,
|
type: type,
|
||||||
notifierId: notifierId,
|
...(notifierId ? {
|
||||||
|
notifierId,
|
||||||
|
} : {}),
|
||||||
...data,
|
...data,
|
||||||
} as MiNotification;
|
} as any as FilterUnionByProperty<MiNotification, 'type', T>;
|
||||||
|
|
||||||
const redisIdPromise = this.redisClient.xadd(
|
const redisIdPromise = this.redisClient.xadd(
|
||||||
`notificationTimeline:${notifieeId}`,
|
`notificationTimeline:${notifieeId}`,
|
||||||
@@ -144,7 +147,9 @@ export class NotificationService implements OnApplicationShutdown {
|
|||||||
this.globalEventService.publishMainStream(notifieeId, 'notification', packed);
|
this.globalEventService.publishMainStream(notifieeId, 'notification', packed);
|
||||||
|
|
||||||
// 2秒経っても(今回作成した)通知が既読にならなかったら「未読の通知がありますよ」イベントを発行する
|
// 2秒経っても(今回作成した)通知が既読にならなかったら「未読の通知がありますよ」イベントを発行する
|
||||||
setTimeout(2000, 'unread notification', { signal: this.#shutdownController.signal }).then(async () => {
|
// テスト通知の場合は即時発行
|
||||||
|
const interval = notification.type === 'test' ? 0 : 2000;
|
||||||
|
setTimeout(interval, 'unread notification', { signal: this.#shutdownController.signal }).then(async () => {
|
||||||
const latestReadNotificationId = await this.redisClient.get(`latestReadNotification:${notifieeId}`);
|
const latestReadNotificationId = await this.redisClient.get(`latestReadNotification:${notifieeId}`);
|
||||||
if (latestReadNotificationId && (latestReadNotificationId >= (await redisIdPromise)!)) return;
|
if (latestReadNotificationId && (latestReadNotificationId >= (await redisIdPromise)!)) return;
|
||||||
|
|
||||||
|
@@ -40,7 +40,7 @@ export class QueryService {
|
|||||||
) {
|
) {
|
||||||
}
|
}
|
||||||
|
|
||||||
public makePaginationQuery<T extends ObjectLiteral>(q: SelectQueryBuilder<T>, sinceId?: string, untilId?: string, sinceDate?: number, untilDate?: number): SelectQueryBuilder<T> {
|
public makePaginationQuery<T extends ObjectLiteral>(q: SelectQueryBuilder<T>, sinceId?: string | null, untilId?: string | null, sinceDate?: number | null, untilDate?: number | null): SelectQueryBuilder<T> {
|
||||||
if (sinceId && untilId) {
|
if (sinceId && untilId) {
|
||||||
q.andWhere(`${q.alias}.id > :sinceId`, { sinceId: sinceId });
|
q.andWhere(`${q.alias}.id > :sinceId`, { sinceId: sinceId });
|
||||||
q.andWhere(`${q.alias}.id < :untilId`, { untilId: untilId });
|
q.andWhere(`${q.alias}.id < :untilId`, { untilId: untilId });
|
||||||
|
@@ -32,6 +32,7 @@ export type RolePolicies = {
|
|||||||
inviteLimitCycle: number;
|
inviteLimitCycle: number;
|
||||||
inviteExpirationTime: number;
|
inviteExpirationTime: number;
|
||||||
canManageCustomEmojis: boolean;
|
canManageCustomEmojis: boolean;
|
||||||
|
canManageAvatarDecorations: boolean;
|
||||||
canSearchNotes: boolean;
|
canSearchNotes: boolean;
|
||||||
canUseTranslator: boolean;
|
canUseTranslator: boolean;
|
||||||
canHideAds: boolean;
|
canHideAds: boolean;
|
||||||
@@ -57,6 +58,7 @@ export const DEFAULT_POLICIES: RolePolicies = {
|
|||||||
inviteLimitCycle: 60 * 24 * 7,
|
inviteLimitCycle: 60 * 24 * 7,
|
||||||
inviteExpirationTime: 0,
|
inviteExpirationTime: 0,
|
||||||
canManageCustomEmojis: false,
|
canManageCustomEmojis: false,
|
||||||
|
canManageAvatarDecorations: false,
|
||||||
canSearchNotes: false,
|
canSearchNotes: false,
|
||||||
canUseTranslator: true,
|
canUseTranslator: true,
|
||||||
canHideAds: false,
|
canHideAds: false,
|
||||||
@@ -227,6 +229,12 @@ export class RoleService implements OnApplicationShutdown {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public async getRoles() {
|
||||||
|
const roles = await this.rolesCache.fetch(() => this.rolesRepository.findBy({}));
|
||||||
|
return roles;
|
||||||
|
}
|
||||||
|
|
||||||
@bindThis
|
@bindThis
|
||||||
public async getUserAssigns(userId: MiUser['id']) {
|
public async getUserAssigns(userId: MiUser['id']) {
|
||||||
const now = Date.now();
|
const now = Date.now();
|
||||||
@@ -300,6 +308,7 @@ export class RoleService implements OnApplicationShutdown {
|
|||||||
inviteLimitCycle: calc('inviteLimitCycle', vs => Math.max(...vs)),
|
inviteLimitCycle: calc('inviteLimitCycle', vs => Math.max(...vs)),
|
||||||
inviteExpirationTime: calc('inviteExpirationTime', vs => Math.max(...vs)),
|
inviteExpirationTime: calc('inviteExpirationTime', vs => Math.max(...vs)),
|
||||||
canManageCustomEmojis: calc('canManageCustomEmojis', vs => vs.some(v => v === true)),
|
canManageCustomEmojis: calc('canManageCustomEmojis', vs => vs.some(v => v === true)),
|
||||||
|
canManageAvatarDecorations: calc('canManageAvatarDecorations', vs => vs.some(v => v === true)),
|
||||||
canSearchNotes: calc('canSearchNotes', vs => vs.some(v => v === true)),
|
canSearchNotes: calc('canSearchNotes', vs => vs.some(v => v === true)),
|
||||||
canUseTranslator: calc('canUseTranslator', vs => vs.some(v => v === true)),
|
canUseTranslator: calc('canUseTranslator', vs => vs.some(v => v === true)),
|
||||||
canHideAds: calc('canHideAds', vs => vs.some(v => v === true)),
|
canHideAds: calc('canHideAds', vs => vs.some(v => v === true)),
|
||||||
|
@@ -509,7 +509,6 @@ export class UserFollowingService implements OnModuleInit {
|
|||||||
|
|
||||||
// 通知を作成
|
// 通知を作成
|
||||||
this.notificationService.createNotification(followee.id, 'receiveFollowRequest', {
|
this.notificationService.createNotification(followee.id, 'receiveFollowRequest', {
|
||||||
followRequestId: followRequest.id,
|
|
||||||
}, follower.id);
|
}, follower.id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -495,6 +495,7 @@ export class ApRendererService {
|
|||||||
preferredUsername: user.username,
|
preferredUsername: user.username,
|
||||||
name: user.name,
|
name: user.name,
|
||||||
summary: profile.description ? this.mfmService.toHtml(mfm.parse(profile.description)) : null,
|
summary: profile.description ? this.mfmService.toHtml(mfm.parse(profile.description)) : null,
|
||||||
|
_misskey_summary: profile.description,
|
||||||
icon: avatar ? this.renderImage(avatar) : null,
|
icon: avatar ? this.renderImage(avatar) : null,
|
||||||
image: banner ? this.renderImage(banner) : null,
|
image: banner ? this.renderImage(banner) : null,
|
||||||
tag,
|
tag,
|
||||||
@@ -644,6 +645,7 @@ export class ApRendererService {
|
|||||||
'_misskey_quote': 'misskey:_misskey_quote',
|
'_misskey_quote': 'misskey:_misskey_quote',
|
||||||
'_misskey_reaction': 'misskey:_misskey_reaction',
|
'_misskey_reaction': 'misskey:_misskey_reaction',
|
||||||
'_misskey_votes': 'misskey:_misskey_votes',
|
'_misskey_votes': 'misskey:_misskey_votes',
|
||||||
|
'_misskey_summary': 'misskey:_misskey_summary',
|
||||||
'isCat': 'misskey:isCat',
|
'isCat': 'misskey:isCat',
|
||||||
// vcard
|
// vcard
|
||||||
vcard: 'http://www.w3.org/2006/vcard/ns#',
|
vcard: 'http://www.w3.org/2006/vcard/ns#',
|
||||||
|
@@ -319,9 +319,17 @@ export class ApPersonService implements OnModuleInit {
|
|||||||
emojis,
|
emojis,
|
||||||
})) as MiRemoteUser;
|
})) as MiRemoteUser;
|
||||||
|
|
||||||
|
let _description: string | null = null;
|
||||||
|
|
||||||
|
if (person._misskey_summary) {
|
||||||
|
_description = truncate(person._misskey_summary, summaryLength);
|
||||||
|
} else if (person.summary) {
|
||||||
|
_description = this.apMfmService.htmlToMfm(truncate(person.summary, summaryLength), person.tag);
|
||||||
|
}
|
||||||
|
|
||||||
await transactionalEntityManager.save(new MiUserProfile({
|
await transactionalEntityManager.save(new MiUserProfile({
|
||||||
userId: user.id,
|
userId: user.id,
|
||||||
description: person.summary ? this.apMfmService.htmlToMfm(truncate(person.summary, summaryLength), person.tag) : null,
|
description: _description,
|
||||||
url,
|
url,
|
||||||
fields,
|
fields,
|
||||||
birthday: bday?.[0] ?? null,
|
birthday: bday?.[0] ?? null,
|
||||||
@@ -487,10 +495,18 @@ export class ApPersonService implements OnModuleInit {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let _description: string | null = null;
|
||||||
|
|
||||||
|
if (person._misskey_summary) {
|
||||||
|
_description = truncate(person._misskey_summary, summaryLength);
|
||||||
|
} else if (person.summary) {
|
||||||
|
_description = this.apMfmService.htmlToMfm(truncate(person.summary, summaryLength), person.tag);
|
||||||
|
}
|
||||||
|
|
||||||
await this.userProfilesRepository.update({ userId: exist.id }, {
|
await this.userProfilesRepository.update({ userId: exist.id }, {
|
||||||
url,
|
url,
|
||||||
fields,
|
fields,
|
||||||
description: person.summary ? this.apMfmService.htmlToMfm(truncate(person.summary, summaryLength), person.tag) : null,
|
description: _description,
|
||||||
birthday: bday?.[0] ?? null,
|
birthday: bday?.[0] ?? null,
|
||||||
location: person['vcard:Address'] ?? null,
|
location: person['vcard:Address'] ?? null,
|
||||||
});
|
});
|
||||||
|
@@ -12,6 +12,7 @@ export interface IObject {
|
|||||||
id?: string;
|
id?: string;
|
||||||
name?: string | null;
|
name?: string | null;
|
||||||
summary?: string;
|
summary?: string;
|
||||||
|
_misskey_summary?: string;
|
||||||
published?: string;
|
published?: string;
|
||||||
cc?: ApObject;
|
cc?: ApObject;
|
||||||
to?: ApObject;
|
to?: ApObject;
|
||||||
|
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
import { Inject, Injectable } from '@nestjs/common';
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
import { DI } from '@/di-symbols.js';
|
import { DI } from '@/di-symbols.js';
|
||||||
import type { ChannelFavoritesRepository, ChannelFollowingsRepository, ChannelsRepository, DriveFilesRepository, NoteUnreadsRepository, NotesRepository } from '@/models/_.js';
|
import type { ChannelFavoritesRepository, ChannelFollowingsRepository, ChannelsRepository, DriveFilesRepository, NotesRepository } from '@/models/_.js';
|
||||||
import type { Packed } from '@/misc/json-schema.js';
|
import type { Packed } from '@/misc/json-schema.js';
|
||||||
import type { } from '@/models/Blocking.js';
|
import type { } from '@/models/Blocking.js';
|
||||||
import type { MiUser } from '@/models/User.js';
|
import type { MiUser } from '@/models/User.js';
|
||||||
@@ -31,9 +31,6 @@ export class ChannelEntityService {
|
|||||||
@Inject(DI.notesRepository)
|
@Inject(DI.notesRepository)
|
||||||
private notesRepository: NotesRepository,
|
private notesRepository: NotesRepository,
|
||||||
|
|
||||||
@Inject(DI.noteUnreadsRepository)
|
|
||||||
private noteUnreadsRepository: NoteUnreadsRepository,
|
|
||||||
|
|
||||||
@Inject(DI.driveFilesRepository)
|
@Inject(DI.driveFilesRepository)
|
||||||
private driveFilesRepository: DriveFilesRepository,
|
private driveFilesRepository: DriveFilesRepository,
|
||||||
|
|
||||||
@@ -54,13 +51,6 @@ export class ChannelEntityService {
|
|||||||
|
|
||||||
const banner = channel.bannerId ? await this.driveFilesRepository.findOneBy({ id: channel.bannerId }) : null;
|
const banner = channel.bannerId ? await this.driveFilesRepository.findOneBy({ id: channel.bannerId }) : null;
|
||||||
|
|
||||||
const hasUnreadNote = meId ? await this.noteUnreadsRepository.exist({
|
|
||||||
where: {
|
|
||||||
noteChannelId: channel.id,
|
|
||||||
userId: meId,
|
|
||||||
},
|
|
||||||
}) : undefined;
|
|
||||||
|
|
||||||
const isFollowing = meId ? await this.channelFollowingsRepository.exist({
|
const isFollowing = meId ? await this.channelFollowingsRepository.exist({
|
||||||
where: {
|
where: {
|
||||||
followerId: meId,
|
followerId: meId,
|
||||||
@@ -99,7 +89,7 @@ export class ChannelEntityService {
|
|||||||
...(me ? {
|
...(me ? {
|
||||||
isFollowing,
|
isFollowing,
|
||||||
isFavorited,
|
isFavorited,
|
||||||
hasUnreadNote,
|
hasUnreadNote: false, // 後方互換性のため
|
||||||
} : {}),
|
} : {}),
|
||||||
|
|
||||||
...(detailed ? {
|
...(detailed ? {
|
||||||
|
@@ -7,20 +7,21 @@ import { Inject, Injectable } from '@nestjs/common';
|
|||||||
import { ModuleRef } from '@nestjs/core';
|
import { ModuleRef } from '@nestjs/core';
|
||||||
import { In } from 'typeorm';
|
import { In } from 'typeorm';
|
||||||
import { DI } from '@/di-symbols.js';
|
import { DI } from '@/di-symbols.js';
|
||||||
import type { AccessTokensRepository, FollowRequestsRepository, NotesRepository, MiUser, UsersRepository } from '@/models/_.js';
|
import type { FollowRequestsRepository, NotesRepository, MiUser, UsersRepository } from '@/models/_.js';
|
||||||
import { awaitAll } from '@/misc/prelude/await-all.js';
|
import { awaitAll } from '@/misc/prelude/await-all.js';
|
||||||
import type { MiNotification } from '@/models/Notification.js';
|
import type { MiGroupedNotification, MiNotification } from '@/models/Notification.js';
|
||||||
import type { MiNote } from '@/models/Note.js';
|
import type { MiNote } from '@/models/Note.js';
|
||||||
import type { Packed } from '@/misc/json-schema.js';
|
import type { Packed } from '@/misc/json-schema.js';
|
||||||
import { bindThis } from '@/decorators.js';
|
import { bindThis } from '@/decorators.js';
|
||||||
import { isNotNull } from '@/misc/is-not-null.js';
|
import { isNotNull } from '@/misc/is-not-null.js';
|
||||||
import { notificationTypes } from '@/types.js';
|
import { FilterUnionByProperty, notificationTypes } from '@/types.js';
|
||||||
import type { OnModuleInit } from '@nestjs/common';
|
import type { OnModuleInit } from '@nestjs/common';
|
||||||
import type { CustomEmojiService } from '../CustomEmojiService.js';
|
import type { CustomEmojiService } from '../CustomEmojiService.js';
|
||||||
import type { UserEntityService } from './UserEntityService.js';
|
import type { UserEntityService } from './UserEntityService.js';
|
||||||
import type { NoteEntityService } from './NoteEntityService.js';
|
import type { NoteEntityService } from './NoteEntityService.js';
|
||||||
|
|
||||||
const NOTE_REQUIRED_NOTIFICATION_TYPES = new Set(['note', 'mention', 'reply', 'renote', 'quote', 'reaction', 'pollEnded'] as (typeof notificationTypes[number])[]);
|
const NOTE_REQUIRED_NOTIFICATION_TYPES = new Set(['note', 'mention', 'reply', 'renote', 'quote', 'reaction', 'pollEnded'] as (typeof notificationTypes[number])[]);
|
||||||
|
const NOTE_REQUIRED_GROUPED_NOTIFICATION_TYPES = new Set(['note', 'mention', 'reply', 'renote', 'renote:grouped', 'quote', 'reaction', 'reaction:grouped', 'pollEnded']);
|
||||||
|
|
||||||
@Injectable()
|
@Injectable()
|
||||||
export class NotificationEntityService implements OnModuleInit {
|
export class NotificationEntityService implements OnModuleInit {
|
||||||
@@ -40,9 +41,6 @@ export class NotificationEntityService implements OnModuleInit {
|
|||||||
@Inject(DI.followRequestsRepository)
|
@Inject(DI.followRequestsRepository)
|
||||||
private followRequestsRepository: FollowRequestsRepository,
|
private followRequestsRepository: FollowRequestsRepository,
|
||||||
|
|
||||||
@Inject(DI.accessTokensRepository)
|
|
||||||
private accessTokensRepository: AccessTokensRepository,
|
|
||||||
|
|
||||||
//private userEntityService: UserEntityService,
|
//private userEntityService: UserEntityService,
|
||||||
//private noteEntityService: NoteEntityService,
|
//private noteEntityService: NoteEntityService,
|
||||||
//private customEmojiService: CustomEmojiService,
|
//private customEmojiService: CustomEmojiService,
|
||||||
@@ -69,18 +67,17 @@ export class NotificationEntityService implements OnModuleInit {
|
|||||||
},
|
},
|
||||||
): Promise<Packed<'Notification'>> {
|
): Promise<Packed<'Notification'>> {
|
||||||
const notification = src;
|
const notification = src;
|
||||||
const token = notification.appAccessTokenId ? await this.accessTokensRepository.findOneByOrFail({ id: notification.appAccessTokenId }) : null;
|
const noteIfNeed = NOTE_REQUIRED_NOTIFICATION_TYPES.has(notification.type) && 'noteId' in notification ? (
|
||||||
const noteIfNeed = NOTE_REQUIRED_NOTIFICATION_TYPES.has(notification.type) && notification.noteId != null ? (
|
|
||||||
hint?.packedNotes != null
|
hint?.packedNotes != null
|
||||||
? hint.packedNotes.get(notification.noteId)
|
? hint.packedNotes.get(notification.noteId)
|
||||||
: this.noteEntityService.pack(notification.noteId!, { id: meId }, {
|
: this.noteEntityService.pack(notification.noteId, { id: meId }, {
|
||||||
detail: true,
|
detail: true,
|
||||||
})
|
})
|
||||||
) : undefined;
|
) : undefined;
|
||||||
const userIfNeed = notification.notifierId != null ? (
|
const userIfNeed = 'notifierId' in notification ? (
|
||||||
hint?.packedUsers != null
|
hint?.packedUsers != null
|
||||||
? hint.packedUsers.get(notification.notifierId)
|
? hint.packedUsers.get(notification.notifierId)
|
||||||
: this.userEntityService.pack(notification.notifierId!, { id: meId }, {
|
: this.userEntityService.pack(notification.notifierId, { id: meId }, {
|
||||||
detail: false,
|
detail: false,
|
||||||
})
|
})
|
||||||
) : undefined;
|
) : undefined;
|
||||||
@@ -89,7 +86,7 @@ export class NotificationEntityService implements OnModuleInit {
|
|||||||
id: notification.id,
|
id: notification.id,
|
||||||
createdAt: new Date(notification.createdAt).toISOString(),
|
createdAt: new Date(notification.createdAt).toISOString(),
|
||||||
type: notification.type,
|
type: notification.type,
|
||||||
userId: notification.notifierId,
|
userId: 'notifierId' in notification ? notification.notifierId : undefined,
|
||||||
...(userIfNeed != null ? { user: userIfNeed } : {}),
|
...(userIfNeed != null ? { user: userIfNeed } : {}),
|
||||||
...(noteIfNeed != null ? { note: noteIfNeed } : {}),
|
...(noteIfNeed != null ? { note: noteIfNeed } : {}),
|
||||||
...(notification.type === 'reaction' ? {
|
...(notification.type === 'reaction' ? {
|
||||||
@@ -100,8 +97,8 @@ export class NotificationEntityService implements OnModuleInit {
|
|||||||
} : {}),
|
} : {}),
|
||||||
...(notification.type === 'app' ? {
|
...(notification.type === 'app' ? {
|
||||||
body: notification.customBody,
|
body: notification.customBody,
|
||||||
header: notification.customHeader ?? token?.name,
|
header: notification.customHeader,
|
||||||
icon: notification.customIcon ?? token?.iconUrl,
|
icon: notification.customIcon,
|
||||||
} : {}),
|
} : {}),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -115,7 +112,7 @@ export class NotificationEntityService implements OnModuleInit {
|
|||||||
|
|
||||||
let validNotifications = notifications;
|
let validNotifications = notifications;
|
||||||
|
|
||||||
const noteIds = validNotifications.map(x => x.noteId).filter(isNotNull);
|
const noteIds = validNotifications.map(x => 'noteId' in x ? x.noteId : null).filter(isNotNull);
|
||||||
const notes = noteIds.length > 0 ? await this.notesRepository.find({
|
const notes = noteIds.length > 0 ? await this.notesRepository.find({
|
||||||
where: { id: In(noteIds) },
|
where: { id: In(noteIds) },
|
||||||
relations: ['user', 'reply', 'reply.user', 'renote', 'renote.user'],
|
relations: ['user', 'reply', 'reply.user', 'renote', 'renote.user'],
|
||||||
@@ -125,9 +122,9 @@ export class NotificationEntityService implements OnModuleInit {
|
|||||||
});
|
});
|
||||||
const packedNotes = new Map(packedNotesArray.map(p => [p.id, p]));
|
const packedNotes = new Map(packedNotesArray.map(p => [p.id, p]));
|
||||||
|
|
||||||
validNotifications = validNotifications.filter(x => x.noteId == null || packedNotes.has(x.noteId));
|
validNotifications = validNotifications.filter(x => !('noteId' in x) || packedNotes.has(x.noteId));
|
||||||
|
|
||||||
const userIds = validNotifications.map(x => x.notifierId).filter(isNotNull);
|
const userIds = validNotifications.map(x => 'notifierId' in x ? x.notifierId : null).filter(isNotNull);
|
||||||
const users = userIds.length > 0 ? await this.usersRepository.find({
|
const users = userIds.length > 0 ? await this.usersRepository.find({
|
||||||
where: { id: In(userIds) },
|
where: { id: In(userIds) },
|
||||||
}) : [];
|
}) : [];
|
||||||
@@ -137,10 +134,10 @@ export class NotificationEntityService implements OnModuleInit {
|
|||||||
const packedUsers = new Map(packedUsersArray.map(p => [p.id, p]));
|
const packedUsers = new Map(packedUsersArray.map(p => [p.id, p]));
|
||||||
|
|
||||||
// 既に解決されたフォローリクエストの通知を除外
|
// 既に解決されたフォローリクエストの通知を除外
|
||||||
const followRequestNotifications = validNotifications.filter(x => x.type === 'receiveFollowRequest');
|
const followRequestNotifications = validNotifications.filter((x): x is FilterUnionByProperty<MiGroupedNotification, 'type', 'receiveFollowRequest'> => x.type === 'receiveFollowRequest');
|
||||||
if (followRequestNotifications.length > 0) {
|
if (followRequestNotifications.length > 0) {
|
||||||
const reqs = await this.followRequestsRepository.find({
|
const reqs = await this.followRequestsRepository.find({
|
||||||
where: { followerId: In(followRequestNotifications.map(x => x.notifierId!)) },
|
where: { followerId: In(followRequestNotifications.map(x => x.notifierId)) },
|
||||||
});
|
});
|
||||||
validNotifications = validNotifications.filter(x => (x.type !== 'receiveFollowRequest') || reqs.some(r => r.followerId === x.notifierId));
|
validNotifications = validNotifications.filter(x => (x.type !== 'receiveFollowRequest') || reqs.some(r => r.followerId === x.notifierId));
|
||||||
}
|
}
|
||||||
@@ -150,4 +147,141 @@ export class NotificationEntityService implements OnModuleInit {
|
|||||||
packedUsers,
|
packedUsers,
|
||||||
})));
|
})));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public async packGrouped(
|
||||||
|
src: MiGroupedNotification,
|
||||||
|
meId: MiUser['id'],
|
||||||
|
// eslint-disable-next-line @typescript-eslint/ban-types
|
||||||
|
options: {
|
||||||
|
|
||||||
|
},
|
||||||
|
hint?: {
|
||||||
|
packedNotes: Map<MiNote['id'], Packed<'Note'>>;
|
||||||
|
packedUsers: Map<MiUser['id'], Packed<'User'>>;
|
||||||
|
},
|
||||||
|
): Promise<Packed<'Notification'>> {
|
||||||
|
const notification = src;
|
||||||
|
const noteIfNeed = NOTE_REQUIRED_GROUPED_NOTIFICATION_TYPES.has(notification.type) && 'noteId' in notification ? (
|
||||||
|
hint?.packedNotes != null
|
||||||
|
? hint.packedNotes.get(notification.noteId)
|
||||||
|
: this.noteEntityService.pack(notification.noteId, { id: meId }, {
|
||||||
|
detail: true,
|
||||||
|
})
|
||||||
|
) : undefined;
|
||||||
|
const userIfNeed = 'notifierId' in notification ? (
|
||||||
|
hint?.packedUsers != null
|
||||||
|
? hint.packedUsers.get(notification.notifierId)
|
||||||
|
: this.userEntityService.pack(notification.notifierId, { id: meId }, {
|
||||||
|
detail: false,
|
||||||
|
})
|
||||||
|
) : undefined;
|
||||||
|
|
||||||
|
if (notification.type === 'reaction:grouped') {
|
||||||
|
const reactions = await Promise.all(notification.reactions.map(async reaction => {
|
||||||
|
const user = hint?.packedUsers != null
|
||||||
|
? hint.packedUsers.get(reaction.userId)!
|
||||||
|
: await this.userEntityService.pack(reaction.userId, { id: meId }, {
|
||||||
|
detail: false,
|
||||||
|
});
|
||||||
|
return {
|
||||||
|
user,
|
||||||
|
reaction: reaction.reaction,
|
||||||
|
};
|
||||||
|
}));
|
||||||
|
return await awaitAll({
|
||||||
|
id: notification.id,
|
||||||
|
createdAt: new Date(notification.createdAt).toISOString(),
|
||||||
|
type: notification.type,
|
||||||
|
note: noteIfNeed,
|
||||||
|
reactions,
|
||||||
|
});
|
||||||
|
} else if (notification.type === 'renote:grouped') {
|
||||||
|
const users = await Promise.all(notification.userIds.map(userId => {
|
||||||
|
const user = hint?.packedUsers != null
|
||||||
|
? hint.packedUsers.get(userId)
|
||||||
|
: this.userEntityService.pack(userId!, { id: meId }, {
|
||||||
|
detail: false,
|
||||||
|
});
|
||||||
|
return user;
|
||||||
|
}));
|
||||||
|
return await awaitAll({
|
||||||
|
id: notification.id,
|
||||||
|
createdAt: new Date(notification.createdAt).toISOString(),
|
||||||
|
type: notification.type,
|
||||||
|
note: noteIfNeed,
|
||||||
|
users,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
return await awaitAll({
|
||||||
|
id: notification.id,
|
||||||
|
createdAt: new Date(notification.createdAt).toISOString(),
|
||||||
|
type: notification.type,
|
||||||
|
userId: 'notifierId' in notification ? notification.notifierId : undefined,
|
||||||
|
...(userIfNeed != null ? { user: userIfNeed } : {}),
|
||||||
|
...(noteIfNeed != null ? { note: noteIfNeed } : {}),
|
||||||
|
...(notification.type === 'reaction' ? {
|
||||||
|
reaction: notification.reaction,
|
||||||
|
} : {}),
|
||||||
|
...(notification.type === 'achievementEarned' ? {
|
||||||
|
achievement: notification.achievement,
|
||||||
|
} : {}),
|
||||||
|
...(notification.type === 'app' ? {
|
||||||
|
body: notification.customBody,
|
||||||
|
header: notification.customHeader,
|
||||||
|
icon: notification.customIcon,
|
||||||
|
} : {}),
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
@bindThis
|
||||||
|
public async packGroupedMany(
|
||||||
|
notifications: MiGroupedNotification[],
|
||||||
|
meId: MiUser['id'],
|
||||||
|
) {
|
||||||
|
if (notifications.length === 0) return [];
|
||||||
|
|
||||||
|
let validNotifications = notifications;
|
||||||
|
|
||||||
|
const noteIds = validNotifications.map(x => 'noteId' in x ? x.noteId : null).filter(isNotNull);
|
||||||
|
const notes = noteIds.length > 0 ? await this.notesRepository.find({
|
||||||
|
where: { id: In(noteIds) },
|
||||||
|
relations: ['user', 'reply', 'reply.user', 'renote', 'renote.user'],
|
||||||
|
}) : [];
|
||||||
|
const packedNotesArray = await this.noteEntityService.packMany(notes, { id: meId }, {
|
||||||
|
detail: true,
|
||||||
|
});
|
||||||
|
const packedNotes = new Map(packedNotesArray.map(p => [p.id, p]));
|
||||||
|
|
||||||
|
validNotifications = validNotifications.filter(x => !('noteId' in x) || packedNotes.has(x.noteId));
|
||||||
|
|
||||||
|
const userIds = [];
|
||||||
|
for (const notification of validNotifications) {
|
||||||
|
if ('notifierId' in notification) userIds.push(notification.notifierId);
|
||||||
|
if (notification.type === 'reaction:grouped') userIds.push(...notification.reactions.map(x => x.userId));
|
||||||
|
if (notification.type === 'renote:grouped') userIds.push(...notification.userIds);
|
||||||
|
}
|
||||||
|
const users = userIds.length > 0 ? await this.usersRepository.find({
|
||||||
|
where: { id: In(userIds) },
|
||||||
|
}) : [];
|
||||||
|
const packedUsersArray = await this.userEntityService.packMany(users, { id: meId }, {
|
||||||
|
detail: false,
|
||||||
|
});
|
||||||
|
const packedUsers = new Map(packedUsersArray.map(p => [p.id, p]));
|
||||||
|
|
||||||
|
// 既に解決されたフォローリクエストの通知を除外
|
||||||
|
const followRequestNotifications = validNotifications.filter((x): x is FilterUnionByProperty<MiGroupedNotification, 'type', 'receiveFollowRequest'> => x.type === 'receiveFollowRequest');
|
||||||
|
if (followRequestNotifications.length > 0) {
|
||||||
|
const reqs = await this.followRequestsRepository.find({
|
||||||
|
where: { followerId: In(followRequestNotifications.map(x => x.notifierId)) },
|
||||||
|
});
|
||||||
|
validNotifications = validNotifications.filter(x => (x.type !== 'receiveFollowRequest') || reqs.some(r => r.followerId === x.notifierId));
|
||||||
|
}
|
||||||
|
|
||||||
|
return await Promise.all(validNotifications.map(x => this.packGrouped(x, meId, {}, {
|
||||||
|
packedNotes,
|
||||||
|
packedUsers,
|
||||||
|
})));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -7,10 +7,12 @@ import { Injectable } from '@nestjs/common';
|
|||||||
import type { } from '@/models/Blocking.js';
|
import type { } from '@/models/Blocking.js';
|
||||||
import type { MiSignin } from '@/models/Signin.js';
|
import type { MiSignin } from '@/models/Signin.js';
|
||||||
import { bindThis } from '@/decorators.js';
|
import { bindThis } from '@/decorators.js';
|
||||||
|
import { IdService } from '@/core/IdService.js';
|
||||||
|
|
||||||
@Injectable()
|
@Injectable()
|
||||||
export class SigninEntityService {
|
export class SigninEntityService {
|
||||||
constructor(
|
constructor(
|
||||||
|
private idService: IdService,
|
||||||
) {
|
) {
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -18,7 +20,13 @@ export class SigninEntityService {
|
|||||||
public async pack(
|
public async pack(
|
||||||
src: MiSignin,
|
src: MiSignin,
|
||||||
) {
|
) {
|
||||||
return src;
|
return {
|
||||||
|
id: src.id,
|
||||||
|
createdAt: this.idService.parse(src.id).date.toISOString(),
|
||||||
|
ip: src.ip,
|
||||||
|
headers: src.headers,
|
||||||
|
success: src.success,
|
||||||
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -15,15 +15,17 @@ import { awaitAll } from '@/misc/prelude/await-all.js';
|
|||||||
import { USER_ACTIVE_THRESHOLD, USER_ONLINE_THRESHOLD } from '@/const.js';
|
import { USER_ACTIVE_THRESHOLD, USER_ONLINE_THRESHOLD } from '@/const.js';
|
||||||
import type { MiLocalUser, MiPartialLocalUser, MiPartialRemoteUser, MiRemoteUser, MiUser } from '@/models/User.js';
|
import type { MiLocalUser, MiPartialLocalUser, MiPartialRemoteUser, MiRemoteUser, MiUser } from '@/models/User.js';
|
||||||
import { birthdaySchema, descriptionSchema, localUsernameSchema, locationSchema, nameSchema, passwordSchema } from '@/models/User.js';
|
import { birthdaySchema, descriptionSchema, localUsernameSchema, locationSchema, nameSchema, passwordSchema } from '@/models/User.js';
|
||||||
|
import { MiNotification } from '@/models/Notification.js';
|
||||||
import type { UsersRepository, UserSecurityKeysRepository, FollowingsRepository, FollowRequestsRepository, BlockingsRepository, MutingsRepository, DriveFilesRepository, NoteUnreadsRepository, UserNotePiningsRepository, UserProfilesRepository, AnnouncementReadsRepository, AnnouncementsRepository, MiUserProfile, RenoteMutingsRepository, UserMemoRepository } from '@/models/_.js';
|
import type { UsersRepository, UserSecurityKeysRepository, FollowingsRepository, FollowRequestsRepository, BlockingsRepository, MutingsRepository, DriveFilesRepository, NoteUnreadsRepository, UserNotePiningsRepository, UserProfilesRepository, AnnouncementReadsRepository, AnnouncementsRepository, MiUserProfile, RenoteMutingsRepository, UserMemoRepository } from '@/models/_.js';
|
||||||
import { bindThis } from '@/decorators.js';
|
import { bindThis } from '@/decorators.js';
|
||||||
import { RoleService } from '@/core/RoleService.js';
|
import { RoleService } from '@/core/RoleService.js';
|
||||||
import { ApPersonService } from '@/core/activitypub/models/ApPersonService.js';
|
import { ApPersonService } from '@/core/activitypub/models/ApPersonService.js';
|
||||||
import { FederatedInstanceService } from '@/core/FederatedInstanceService.js';
|
import { FederatedInstanceService } from '@/core/FederatedInstanceService.js';
|
||||||
import { IdService } from '@/core/IdService.js';
|
import { IdService } from '@/core/IdService.js';
|
||||||
|
import type { AnnouncementService } from '@/core/AnnouncementService.js';
|
||||||
|
import type { CustomEmojiService } from '@/core/CustomEmojiService.js';
|
||||||
|
import { AvatarDecorationService } from '@/core/AvatarDecorationService.js';
|
||||||
import type { OnModuleInit } from '@nestjs/common';
|
import type { OnModuleInit } from '@nestjs/common';
|
||||||
import type { AnnouncementService } from '../AnnouncementService.js';
|
|
||||||
import type { CustomEmojiService } from '../CustomEmojiService.js';
|
|
||||||
import type { NoteEntityService } from './NoteEntityService.js';
|
import type { NoteEntityService } from './NoteEntityService.js';
|
||||||
import type { DriveFileEntityService } from './DriveFileEntityService.js';
|
import type { DriveFileEntityService } from './DriveFileEntityService.js';
|
||||||
import type { PageEntityService } from './PageEntityService.js';
|
import type { PageEntityService } from './PageEntityService.js';
|
||||||
@@ -62,6 +64,7 @@ export class UserEntityService implements OnModuleInit {
|
|||||||
private roleService: RoleService;
|
private roleService: RoleService;
|
||||||
private federatedInstanceService: FederatedInstanceService;
|
private federatedInstanceService: FederatedInstanceService;
|
||||||
private idService: IdService;
|
private idService: IdService;
|
||||||
|
private avatarDecorationService: AvatarDecorationService;
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
private moduleRef: ModuleRef,
|
private moduleRef: ModuleRef,
|
||||||
@@ -126,6 +129,7 @@ export class UserEntityService implements OnModuleInit {
|
|||||||
this.roleService = this.moduleRef.get('RoleService');
|
this.roleService = this.moduleRef.get('RoleService');
|
||||||
this.federatedInstanceService = this.moduleRef.get('FederatedInstanceService');
|
this.federatedInstanceService = this.moduleRef.get('FederatedInstanceService');
|
||||||
this.idService = this.moduleRef.get('IdService');
|
this.idService = this.moduleRef.get('IdService');
|
||||||
|
this.avatarDecorationService = this.moduleRef.get('AvatarDecorationService');
|
||||||
}
|
}
|
||||||
|
|
||||||
//#region Validators
|
//#region Validators
|
||||||
@@ -232,17 +236,34 @@ export class UserEntityService implements OnModuleInit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@bindThis
|
@bindThis
|
||||||
public async getHasUnreadNotification(userId: MiUser['id']): Promise<boolean> {
|
public async getNotificationsInfo(userId: MiUser['id']): Promise<{
|
||||||
|
hasUnread: boolean;
|
||||||
|
unreadCount: number;
|
||||||
|
}> {
|
||||||
|
const response = {
|
||||||
|
hasUnread: false,
|
||||||
|
unreadCount: 0,
|
||||||
|
};
|
||||||
|
|
||||||
const latestReadNotificationId = await this.redisClient.get(`latestReadNotification:${userId}`);
|
const latestReadNotificationId = await this.redisClient.get(`latestReadNotification:${userId}`);
|
||||||
|
|
||||||
|
if (!latestReadNotificationId) {
|
||||||
|
response.unreadCount = await this.redisClient.xlen(`notificationTimeline:${userId}`);
|
||||||
|
} else {
|
||||||
const latestNotificationIdsRes = await this.redisClient.xrevrange(
|
const latestNotificationIdsRes = await this.redisClient.xrevrange(
|
||||||
`notificationTimeline:${userId}`,
|
`notificationTimeline:${userId}`,
|
||||||
'+',
|
'+',
|
||||||
'-',
|
latestReadNotificationId,
|
||||||
'COUNT', 1);
|
);
|
||||||
const latestNotificationId = latestNotificationIdsRes[0]?.[0];
|
|
||||||
|
|
||||||
return latestNotificationId != null && (latestReadNotificationId == null || latestReadNotificationId < latestNotificationId);
|
response.unreadCount = (latestNotificationIdsRes.length - 1 >= 0) ? latestNotificationIdsRes.length - 1 : 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (response.unreadCount > 0) {
|
||||||
|
response.hasUnread = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return response;
|
||||||
}
|
}
|
||||||
|
|
||||||
@bindThis
|
@bindThis
|
||||||
@@ -328,7 +349,7 @@ export class UserEntityService implements OnModuleInit {
|
|||||||
...announcement,
|
...announcement,
|
||||||
})) : null;
|
})) : null;
|
||||||
|
|
||||||
const falsy = opts.detail ? false : undefined;
|
const notificationsInfo = isMe && opts.detail ? await this.getNotificationsInfo(user.id) : null;
|
||||||
|
|
||||||
const packed = {
|
const packed = {
|
||||||
id: user.id,
|
id: user.id,
|
||||||
@@ -337,6 +358,12 @@ export class UserEntityService implements OnModuleInit {
|
|||||||
host: user.host,
|
host: user.host,
|
||||||
avatarUrl: user.avatarUrl ?? this.getIdenticonUrl(user),
|
avatarUrl: user.avatarUrl ?? this.getIdenticonUrl(user),
|
||||||
avatarBlurhash: user.avatarBlurhash,
|
avatarBlurhash: user.avatarBlurhash,
|
||||||
|
avatarDecorations: user.avatarDecorations.length > 0 ? this.avatarDecorationService.getAll().then(decorations => user.avatarDecorations.filter(ud => decorations.some(d => d.id === ud.id)).map(ud => ({
|
||||||
|
id: ud.id,
|
||||||
|
angle: ud.angle || undefined,
|
||||||
|
flipH: ud.flipH || undefined,
|
||||||
|
url: decorations.find(d => d.id === ud.id)!.url,
|
||||||
|
}))) : [],
|
||||||
isBot: user.isBot,
|
isBot: user.isBot,
|
||||||
isCat: user.isCat,
|
isCat: user.isCat,
|
||||||
instance: user.host ? this.federatedInstanceService.federatedInstanceCache.fetch(user.host).then(instance => instance ? {
|
instance: user.host ? this.federatedInstanceService.federatedInstanceCache.fetch(user.host).then(instance => instance ? {
|
||||||
@@ -442,8 +469,9 @@ export class UserEntityService implements OnModuleInit {
|
|||||||
unreadAnnouncements,
|
unreadAnnouncements,
|
||||||
hasUnreadAntenna: this.getHasUnreadAntenna(user.id),
|
hasUnreadAntenna: this.getHasUnreadAntenna(user.id),
|
||||||
hasUnreadChannel: false, // 後方互換性のため
|
hasUnreadChannel: false, // 後方互換性のため
|
||||||
hasUnreadNotification: this.getHasUnreadNotification(user.id),
|
hasUnreadNotification: notificationsInfo?.hasUnread, // 後方互換性のため
|
||||||
hasPendingReceivedFollowRequest: this.getHasPendingReceivedFollowRequest(user.id),
|
hasPendingReceivedFollowRequest: this.getHasPendingReceivedFollowRequest(user.id),
|
||||||
|
unreadNotificationsCount: notificationsInfo?.unreadCount,
|
||||||
mutedWords: profile!.mutedWords,
|
mutedWords: profile!.mutedWords,
|
||||||
mutedInstances: profile!.mutedInstances,
|
mutedInstances: profile!.mutedInstances,
|
||||||
mutingNotificationTypes: [], // 後方互換性のため
|
mutingNotificationTypes: [], // 後方互換性のため
|
||||||
|
@@ -18,6 +18,7 @@ export const DI = {
|
|||||||
announcementsRepository: Symbol('announcementsRepository'),
|
announcementsRepository: Symbol('announcementsRepository'),
|
||||||
announcementReadsRepository: Symbol('announcementReadsRepository'),
|
announcementReadsRepository: Symbol('announcementReadsRepository'),
|
||||||
appsRepository: Symbol('appsRepository'),
|
appsRepository: Symbol('appsRepository'),
|
||||||
|
avatarDecorationsRepository: Symbol('avatarDecorationsRepository'),
|
||||||
noteFavoritesRepository: Symbol('noteFavoritesRepository'),
|
noteFavoritesRepository: Symbol('noteFavoritesRepository'),
|
||||||
noteThreadMutingsRepository: Symbol('noteThreadMutingsRepository'),
|
noteThreadMutingsRepository: Symbol('noteThreadMutingsRepository'),
|
||||||
noteReactionsRepository: Symbol('noteReactionsRepository'),
|
noteReactionsRepository: Symbol('noteReactionsRepository'),
|
||||||
|
10
packages/backend/src/misc/is-pure-renote.ts
Normal file
10
packages/backend/src/misc/is-pure-renote.ts
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
import type { MiNote } from '@/models/Note.js';
|
||||||
|
|
||||||
|
export function isPureRenote(note: MiNote): note is MiNote & { renoteId: NonNullable<MiNote['renoteId']> } {
|
||||||
|
if (!note.renoteId) return false;
|
||||||
|
|
||||||
|
if (note.text) return false; // it's quoted with text
|
||||||
|
if (note.fileIds.length !== 0) return false; // it's quoted with files
|
||||||
|
if (note.hasPoll) return false; // it's quoted with poll
|
||||||
|
return true;
|
||||||
|
}
|
39
packages/backend/src/models/AvatarDecoration.ts
Normal file
39
packages/backend/src/models/AvatarDecoration.ts
Normal file
@@ -0,0 +1,39 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { Entity, PrimaryColumn, Index, Column, ManyToOne, JoinColumn } from 'typeorm';
|
||||||
|
import { id } from './util/id.js';
|
||||||
|
|
||||||
|
@Entity('avatar_decoration')
|
||||||
|
export class MiAvatarDecoration {
|
||||||
|
@PrimaryColumn(id())
|
||||||
|
public id: string;
|
||||||
|
|
||||||
|
@Column('timestamp with time zone', {
|
||||||
|
nullable: true,
|
||||||
|
})
|
||||||
|
public updatedAt: Date | null;
|
||||||
|
|
||||||
|
@Column('varchar', {
|
||||||
|
length: 1024,
|
||||||
|
})
|
||||||
|
public url: string;
|
||||||
|
|
||||||
|
@Column('varchar', {
|
||||||
|
length: 256,
|
||||||
|
})
|
||||||
|
public name: string;
|
||||||
|
|
||||||
|
@Column('varchar', {
|
||||||
|
length: 2048,
|
||||||
|
})
|
||||||
|
public description: string;
|
||||||
|
|
||||||
|
// TODO: 定期ジョブで存在しなくなったロールIDを除去するようにする
|
||||||
|
@Column('varchar', {
|
||||||
|
array: true, length: 128, default: '{}',
|
||||||
|
})
|
||||||
|
public roleIdsThatCanBeUsedThisDecoration: string[];
|
||||||
|
}
|
@@ -489,6 +489,11 @@ export class MiMeta {
|
|||||||
})
|
})
|
||||||
public preservedUsernames: string[];
|
public preservedUsernames: string[];
|
||||||
|
|
||||||
|
@Column('boolean', {
|
||||||
|
default: true,
|
||||||
|
})
|
||||||
|
public enableFanoutTimeline: boolean;
|
||||||
|
|
||||||
@Column('integer', {
|
@Column('integer', {
|
||||||
default: 300,
|
default: 300,
|
||||||
})
|
})
|
||||||
|
@@ -10,30 +10,73 @@ import { MiFollowRequest } from './FollowRequest.js';
|
|||||||
import { MiAccessToken } from './AccessToken.js';
|
import { MiAccessToken } from './AccessToken.js';
|
||||||
|
|
||||||
export type MiNotification = {
|
export type MiNotification = {
|
||||||
|
type: 'note';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
notifierId: MiUser['id'];
|
||||||
|
noteId: MiNote['id'];
|
||||||
|
} | {
|
||||||
|
type: 'follow';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
notifierId: MiUser['id'];
|
||||||
|
} | {
|
||||||
|
type: 'mention';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
notifierId: MiUser['id'];
|
||||||
|
noteId: MiNote['id'];
|
||||||
|
} | {
|
||||||
|
type: 'reply';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
notifierId: MiUser['id'];
|
||||||
|
noteId: MiNote['id'];
|
||||||
|
} | {
|
||||||
|
type: 'renote';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
notifierId: MiUser['id'];
|
||||||
|
noteId: MiNote['id'];
|
||||||
|
targetNoteId: MiNote['id'];
|
||||||
|
} | {
|
||||||
|
type: 'quote';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
notifierId: MiUser['id'];
|
||||||
|
noteId: MiNote['id'];
|
||||||
|
} | {
|
||||||
|
type: 'reaction';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
notifierId: MiUser['id'];
|
||||||
|
noteId: MiNote['id'];
|
||||||
|
reaction: string;
|
||||||
|
} | {
|
||||||
|
type: 'pollEnded';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
notifierId: MiUser['id'];
|
||||||
|
noteId: MiNote['id'];
|
||||||
|
} | {
|
||||||
|
type: 'receiveFollowRequest';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
notifierId: MiUser['id'];
|
||||||
|
} | {
|
||||||
|
type: 'followRequestAccepted';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
notifierId: MiUser['id'];
|
||||||
|
} | {
|
||||||
|
type: 'achievementEarned';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
achievement: string;
|
||||||
|
} | {
|
||||||
|
type: 'app';
|
||||||
id: string;
|
id: string;
|
||||||
|
|
||||||
// RedisのためDateではなくstring
|
|
||||||
createdAt: string;
|
createdAt: string;
|
||||||
|
|
||||||
/**
|
|
||||||
* 通知の送信者(initiator)
|
|
||||||
*/
|
|
||||||
notifierId: MiUser['id'] | null;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 通知の種類。
|
|
||||||
*/
|
|
||||||
type: typeof notificationTypes[number];
|
|
||||||
|
|
||||||
noteId: MiNote['id'] | null;
|
|
||||||
|
|
||||||
followRequestId: MiFollowRequest['id'] | null;
|
|
||||||
|
|
||||||
reaction: string | null;
|
|
||||||
|
|
||||||
choice: number | null;
|
|
||||||
|
|
||||||
achievement: string | null;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* アプリ通知のbody
|
* アプリ通知のbody
|
||||||
@@ -56,4 +99,25 @@ export type MiNotification = {
|
|||||||
* アプリ通知のアプリ(のトークン)
|
* アプリ通知のアプリ(のトークン)
|
||||||
*/
|
*/
|
||||||
appAccessTokenId: MiAccessToken['id'] | null;
|
appAccessTokenId: MiAccessToken['id'] | null;
|
||||||
}
|
} | {
|
||||||
|
type: 'test';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type MiGroupedNotification = MiNotification | {
|
||||||
|
type: 'reaction:grouped';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
noteId: MiNote['id'];
|
||||||
|
reactions: {
|
||||||
|
userId: string;
|
||||||
|
reaction: string;
|
||||||
|
}[];
|
||||||
|
} | {
|
||||||
|
type: 'renote:grouped';
|
||||||
|
id: string;
|
||||||
|
createdAt: string;
|
||||||
|
noteId: MiNote['id'];
|
||||||
|
userIds: string[];
|
||||||
|
};
|
||||||
|
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
import { Module } from '@nestjs/common';
|
import { Module } from '@nestjs/common';
|
||||||
import { DI } from '@/di-symbols.js';
|
import { DI } from '@/di-symbols.js';
|
||||||
import { MiAbuseUserReport, MiAccessToken, MiAd, MiAnnouncement, MiAnnouncementRead, MiAntenna, MiApp, MiAuthSession, MiBlocking, MiChannel, MiChannelFavorite, MiChannelFollowing, MiClip, MiClipFavorite, MiClipNote, MiDriveFile, MiDriveFolder, MiEmoji, MiFlash, MiFlashLike, MiFollowRequest, MiFollowing, MiGalleryLike, MiGalleryPost, MiHashtag, MiInstance, MiMeta, MiModerationLog, MiMuting, MiNote, MiNoteFavorite, MiNoteReaction, MiNoteThreadMuting, MiNoteUnread, MiPage, MiPageLike, MiPasswordResetRequest, MiPoll, MiPollVote, MiPromoNote, MiPromoRead, MiRegistrationTicket, MiRegistryItem, MiRelay, MiRenoteMuting, MiRetentionAggregation, MiRole, MiRoleAssignment, MiSignin, MiSwSubscription, MiUsedUsername, MiUser, MiUserIp, MiUserKeypair, MiUserList, MiUserListFavorite, MiUserListMembership, MiUserMemo, MiUserNotePining, MiUserPending, MiUserProfile, MiUserPublickey, MiUserSecurityKey, MiWebhook } from './_.js';
|
import { MiAbuseUserReport, MiAccessToken, MiAd, MiAnnouncement, MiAnnouncementRead, MiAntenna, MiApp, MiAuthSession, MiAvatarDecoration, MiBlocking, MiChannel, MiChannelFavorite, MiChannelFollowing, MiClip, MiClipFavorite, MiClipNote, MiDriveFile, MiDriveFolder, MiEmoji, MiFlash, MiFlashLike, MiFollowRequest, MiFollowing, MiGalleryLike, MiGalleryPost, MiHashtag, MiInstance, MiMeta, MiModerationLog, MiMuting, MiNote, MiNoteFavorite, MiNoteReaction, MiNoteThreadMuting, MiNoteUnread, MiPage, MiPageLike, MiPasswordResetRequest, MiPoll, MiPollVote, MiPromoNote, MiPromoRead, MiRegistrationTicket, MiRegistryItem, MiRelay, MiRenoteMuting, MiRetentionAggregation, MiRole, MiRoleAssignment, MiSignin, MiSwSubscription, MiUsedUsername, MiUser, MiUserIp, MiUserKeypair, MiUserList, MiUserListFavorite, MiUserListMembership, MiUserMemo, MiUserNotePining, MiUserPending, MiUserProfile, MiUserPublickey, MiUserSecurityKey, MiWebhook } from './_.js';
|
||||||
import type { DataSource } from 'typeorm';
|
import type { DataSource } from 'typeorm';
|
||||||
import type { Provider } from '@nestjs/common';
|
import type { Provider } from '@nestjs/common';
|
||||||
|
|
||||||
@@ -39,6 +39,12 @@ const $appsRepository: Provider = {
|
|||||||
inject: [DI.db],
|
inject: [DI.db],
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const $avatarDecorationsRepository: Provider = {
|
||||||
|
provide: DI.avatarDecorationsRepository,
|
||||||
|
useFactory: (db: DataSource) => db.getRepository(MiAvatarDecoration),
|
||||||
|
inject: [DI.db],
|
||||||
|
};
|
||||||
|
|
||||||
const $noteFavoritesRepository: Provider = {
|
const $noteFavoritesRepository: Provider = {
|
||||||
provide: DI.noteFavoritesRepository,
|
provide: DI.noteFavoritesRepository,
|
||||||
useFactory: (db: DataSource) => db.getRepository(MiNoteFavorite),
|
useFactory: (db: DataSource) => db.getRepository(MiNoteFavorite),
|
||||||
@@ -402,6 +408,7 @@ const $userMemosRepository: Provider = {
|
|||||||
$announcementsRepository,
|
$announcementsRepository,
|
||||||
$announcementReadsRepository,
|
$announcementReadsRepository,
|
||||||
$appsRepository,
|
$appsRepository,
|
||||||
|
$avatarDecorationsRepository,
|
||||||
$noteFavoritesRepository,
|
$noteFavoritesRepository,
|
||||||
$noteThreadMutingsRepository,
|
$noteThreadMutingsRepository,
|
||||||
$noteReactionsRepository,
|
$noteReactionsRepository,
|
||||||
@@ -468,6 +475,7 @@ const $userMemosRepository: Provider = {
|
|||||||
$announcementsRepository,
|
$announcementsRepository,
|
||||||
$announcementReadsRepository,
|
$announcementReadsRepository,
|
||||||
$appsRepository,
|
$appsRepository,
|
||||||
|
$avatarDecorationsRepository,
|
||||||
$noteFavoritesRepository,
|
$noteFavoritesRepository,
|
||||||
$noteThreadMutingsRepository,
|
$noteThreadMutingsRepository,
|
||||||
$noteReactionsRepository,
|
$noteReactionsRepository,
|
||||||
|
@@ -138,6 +138,15 @@ export class MiUser {
|
|||||||
})
|
})
|
||||||
public bannerBlurhash: string | null;
|
public bannerBlurhash: string | null;
|
||||||
|
|
||||||
|
@Column('jsonb', {
|
||||||
|
default: [],
|
||||||
|
})
|
||||||
|
public avatarDecorations: {
|
||||||
|
id: string;
|
||||||
|
angle: number;
|
||||||
|
flipH: boolean;
|
||||||
|
}[];
|
||||||
|
|
||||||
@Index()
|
@Index()
|
||||||
@Column('varchar', {
|
@Column('varchar', {
|
||||||
length: 128, array: true, default: '{}',
|
length: 128, array: true, default: '{}',
|
||||||
|
@@ -10,6 +10,7 @@ import { MiAnnouncement } from '@/models/Announcement.js';
|
|||||||
import { MiAnnouncementRead } from '@/models/AnnouncementRead.js';
|
import { MiAnnouncementRead } from '@/models/AnnouncementRead.js';
|
||||||
import { MiAntenna } from '@/models/Antenna.js';
|
import { MiAntenna } from '@/models/Antenna.js';
|
||||||
import { MiApp } from '@/models/App.js';
|
import { MiApp } from '@/models/App.js';
|
||||||
|
import { MiAvatarDecoration } from '@/models/AvatarDecoration.js';
|
||||||
import { MiAuthSession } from '@/models/AuthSession.js';
|
import { MiAuthSession } from '@/models/AuthSession.js';
|
||||||
import { MiBlocking } from '@/models/Blocking.js';
|
import { MiBlocking } from '@/models/Blocking.js';
|
||||||
import { MiChannelFollowing } from '@/models/ChannelFollowing.js';
|
import { MiChannelFollowing } from '@/models/ChannelFollowing.js';
|
||||||
@@ -77,6 +78,7 @@ export {
|
|||||||
MiAnnouncementRead,
|
MiAnnouncementRead,
|
||||||
MiAntenna,
|
MiAntenna,
|
||||||
MiApp,
|
MiApp,
|
||||||
|
MiAvatarDecoration,
|
||||||
MiAuthSession,
|
MiAuthSession,
|
||||||
MiBlocking,
|
MiBlocking,
|
||||||
MiChannelFollowing,
|
MiChannelFollowing,
|
||||||
@@ -143,6 +145,7 @@ export type AnnouncementsRepository = Repository<MiAnnouncement>;
|
|||||||
export type AnnouncementReadsRepository = Repository<MiAnnouncementRead>;
|
export type AnnouncementReadsRepository = Repository<MiAnnouncementRead>;
|
||||||
export type AntennasRepository = Repository<MiAntenna>;
|
export type AntennasRepository = Repository<MiAntenna>;
|
||||||
export type AppsRepository = Repository<MiApp>;
|
export type AppsRepository = Repository<MiApp>;
|
||||||
|
export type AvatarDecorationsRepository = Repository<MiAvatarDecoration>;
|
||||||
export type AuthSessionsRepository = Repository<MiAuthSession>;
|
export type AuthSessionsRepository = Repository<MiAuthSession>;
|
||||||
export type BlockingsRepository = Repository<MiBlocking>;
|
export type BlockingsRepository = Repository<MiBlocking>;
|
||||||
export type ChannelFollowingsRepository = Repository<MiChannelFollowing>;
|
export type ChannelFollowingsRepository = Repository<MiChannelFollowing>;
|
||||||
|
@@ -12,7 +12,6 @@ export const packedNotificationSchema = {
|
|||||||
type: 'string',
|
type: 'string',
|
||||||
optional: false, nullable: false,
|
optional: false, nullable: false,
|
||||||
format: 'id',
|
format: 'id',
|
||||||
example: 'xxxxxxxxxx',
|
|
||||||
},
|
},
|
||||||
createdAt: {
|
createdAt: {
|
||||||
type: 'string',
|
type: 'string',
|
||||||
@@ -22,7 +21,7 @@ export const packedNotificationSchema = {
|
|||||||
type: {
|
type: {
|
||||||
type: 'string',
|
type: 'string',
|
||||||
optional: false, nullable: false,
|
optional: false, nullable: false,
|
||||||
enum: [...notificationTypes],
|
enum: [...notificationTypes, 'reaction:grouped', 'renote:grouped'],
|
||||||
},
|
},
|
||||||
user: {
|
user: {
|
||||||
type: 'object',
|
type: 'object',
|
||||||
@@ -63,5 +62,33 @@ export const packedNotificationSchema = {
|
|||||||
type: 'string',
|
type: 'string',
|
||||||
optional: true, nullable: true,
|
optional: true, nullable: true,
|
||||||
},
|
},
|
||||||
|
reactions: {
|
||||||
|
type: 'array',
|
||||||
|
optional: true, nullable: true,
|
||||||
|
items: {
|
||||||
|
type: 'object',
|
||||||
|
properties: {
|
||||||
|
user: {
|
||||||
|
type: 'object',
|
||||||
|
ref: 'UserLite',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
},
|
||||||
|
reaction: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
required: ['user', 'reaction'],
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
users: {
|
||||||
|
type: 'array',
|
||||||
|
optional: true, nullable: true,
|
||||||
|
items: {
|
||||||
|
type: 'object',
|
||||||
|
ref: 'UserLite',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
} as const;
|
} as const;
|
||||||
|
@@ -37,6 +37,34 @@ export const packedUserLiteSchema = {
|
|||||||
type: 'string',
|
type: 'string',
|
||||||
nullable: true, optional: false,
|
nullable: true, optional: false,
|
||||||
},
|
},
|
||||||
|
avatarDecorations: {
|
||||||
|
type: 'array',
|
||||||
|
nullable: false, optional: false,
|
||||||
|
items: {
|
||||||
|
type: 'object',
|
||||||
|
nullable: false, optional: false,
|
||||||
|
properties: {
|
||||||
|
id: {
|
||||||
|
type: 'string',
|
||||||
|
nullable: false, optional: false,
|
||||||
|
format: 'id',
|
||||||
|
},
|
||||||
|
url: {
|
||||||
|
type: 'string',
|
||||||
|
format: 'url',
|
||||||
|
nullable: false, optional: false,
|
||||||
|
},
|
||||||
|
angle: {
|
||||||
|
type: 'number',
|
||||||
|
nullable: false, optional: true,
|
||||||
|
},
|
||||||
|
flipH: {
|
||||||
|
type: 'boolean',
|
||||||
|
nullable: false, optional: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
isAdmin: {
|
isAdmin: {
|
||||||
type: 'boolean',
|
type: 'boolean',
|
||||||
nullable: false, optional: true,
|
nullable: false, optional: true,
|
||||||
@@ -371,6 +399,10 @@ export const packedMeDetailedOnlySchema = {
|
|||||||
type: 'boolean',
|
type: 'boolean',
|
||||||
nullable: false, optional: false,
|
nullable: false, optional: false,
|
||||||
},
|
},
|
||||||
|
unreadNotificationsCount: {
|
||||||
|
type: 'number',
|
||||||
|
nullable: false, optional: false,
|
||||||
|
},
|
||||||
mutedWords: {
|
mutedWords: {
|
||||||
type: 'array',
|
type: 'array',
|
||||||
nullable: false, optional: false,
|
nullable: false, optional: false,
|
||||||
|
@@ -18,6 +18,7 @@ import { MiAnnouncement } from '@/models/Announcement.js';
|
|||||||
import { MiAnnouncementRead } from '@/models/AnnouncementRead.js';
|
import { MiAnnouncementRead } from '@/models/AnnouncementRead.js';
|
||||||
import { MiAntenna } from '@/models/Antenna.js';
|
import { MiAntenna } from '@/models/Antenna.js';
|
||||||
import { MiApp } from '@/models/App.js';
|
import { MiApp } from '@/models/App.js';
|
||||||
|
import { MiAvatarDecoration } from '@/models/AvatarDecoration.js';
|
||||||
import { MiAuthSession } from '@/models/AuthSession.js';
|
import { MiAuthSession } from '@/models/AuthSession.js';
|
||||||
import { MiBlocking } from '@/models/Blocking.js';
|
import { MiBlocking } from '@/models/Blocking.js';
|
||||||
import { MiChannelFollowing } from '@/models/ChannelFollowing.js';
|
import { MiChannelFollowing } from '@/models/ChannelFollowing.js';
|
||||||
@@ -129,6 +130,7 @@ export const entities = [
|
|||||||
MiMeta,
|
MiMeta,
|
||||||
MiInstance,
|
MiInstance,
|
||||||
MiApp,
|
MiApp,
|
||||||
|
MiAvatarDecoration,
|
||||||
MiAuthSession,
|
MiAuthSession,
|
||||||
MiAccessToken,
|
MiAccessToken,
|
||||||
MiUser,
|
MiUser,
|
||||||
|
@@ -26,6 +26,7 @@ import { UtilityService } from '@/core/UtilityService.js';
|
|||||||
import { UserEntityService } from '@/core/entities/UserEntityService.js';
|
import { UserEntityService } from '@/core/entities/UserEntityService.js';
|
||||||
import { bindThis } from '@/decorators.js';
|
import { bindThis } from '@/decorators.js';
|
||||||
import { IActivity } from '@/core/activitypub/type.js';
|
import { IActivity } from '@/core/activitypub/type.js';
|
||||||
|
import { isPureRenote } from '@/misc/is-pure-renote.js';
|
||||||
import type { FastifyInstance, FastifyRequest, FastifyReply, FastifyPluginOptions } from 'fastify';
|
import type { FastifyInstance, FastifyRequest, FastifyReply, FastifyPluginOptions } from 'fastify';
|
||||||
import type { FindOptionsWhere } from 'typeorm';
|
import type { FindOptionsWhere } from 'typeorm';
|
||||||
|
|
||||||
@@ -88,7 +89,7 @@ export class ActivityPubServerService {
|
|||||||
*/
|
*/
|
||||||
@bindThis
|
@bindThis
|
||||||
private async packActivity(note: MiNote): Promise<any> {
|
private async packActivity(note: MiNote): Promise<any> {
|
||||||
if (note.renoteId && note.text == null && !note.hasPoll && (note.fileIds == null || note.fileIds.length === 0)) {
|
if (isPureRenote(note)) {
|
||||||
const renote = await this.notesRepository.findOneByOrFail({ id: note.renoteId });
|
const renote = await this.notesRepository.findOneByOrFail({ id: note.renoteId });
|
||||||
return this.apRendererService.renderAnnounce(renote.uri ? renote.uri : `${this.config.url}/notes/${renote.id}`, note);
|
return this.apRendererService.renderAnnounce(renote.uri ? renote.uri : `${this.config.url}/notes/${renote.id}`, note);
|
||||||
}
|
}
|
||||||
|
@@ -18,6 +18,10 @@ import * as ep___admin_announcements_create from './endpoints/admin/announcement
|
|||||||
import * as ep___admin_announcements_delete from './endpoints/admin/announcements/delete.js';
|
import * as ep___admin_announcements_delete from './endpoints/admin/announcements/delete.js';
|
||||||
import * as ep___admin_announcements_list from './endpoints/admin/announcements/list.js';
|
import * as ep___admin_announcements_list from './endpoints/admin/announcements/list.js';
|
||||||
import * as ep___admin_announcements_update from './endpoints/admin/announcements/update.js';
|
import * as ep___admin_announcements_update from './endpoints/admin/announcements/update.js';
|
||||||
|
import * as ep___admin_avatarDecorations_create from './endpoints/admin/avatar-decorations/create.js';
|
||||||
|
import * as ep___admin_avatarDecorations_delete from './endpoints/admin/avatar-decorations/delete.js';
|
||||||
|
import * as ep___admin_avatarDecorations_list from './endpoints/admin/avatar-decorations/list.js';
|
||||||
|
import * as ep___admin_avatarDecorations_update from './endpoints/admin/avatar-decorations/update.js';
|
||||||
import * as ep___admin_deleteAllFilesOfAUser from './endpoints/admin/delete-all-files-of-a-user.js';
|
import * as ep___admin_deleteAllFilesOfAUser from './endpoints/admin/delete-all-files-of-a-user.js';
|
||||||
import * as ep___admin_drive_cleanRemoteFiles from './endpoints/admin/drive/clean-remote-files.js';
|
import * as ep___admin_drive_cleanRemoteFiles from './endpoints/admin/drive/clean-remote-files.js';
|
||||||
import * as ep___admin_drive_cleanup from './endpoints/admin/drive/cleanup.js';
|
import * as ep___admin_drive_cleanup from './endpoints/admin/drive/cleanup.js';
|
||||||
@@ -161,6 +165,7 @@ import * as ep___federation_stats from './endpoints/federation/stats.js';
|
|||||||
import * as ep___following_create from './endpoints/following/create.js';
|
import * as ep___following_create from './endpoints/following/create.js';
|
||||||
import * as ep___following_delete from './endpoints/following/delete.js';
|
import * as ep___following_delete from './endpoints/following/delete.js';
|
||||||
import * as ep___following_update from './endpoints/following/update.js';
|
import * as ep___following_update from './endpoints/following/update.js';
|
||||||
|
import * as ep___following_update_all from './endpoints/following/update-all.js';
|
||||||
import * as ep___following_invalidate from './endpoints/following/invalidate.js';
|
import * as ep___following_invalidate from './endpoints/following/invalidate.js';
|
||||||
import * as ep___following_requests_accept from './endpoints/following/requests/accept.js';
|
import * as ep___following_requests_accept from './endpoints/following/requests/accept.js';
|
||||||
import * as ep___following_requests_cancel from './endpoints/following/requests/cancel.js';
|
import * as ep___following_requests_cancel from './endpoints/following/requests/cancel.js';
|
||||||
@@ -176,6 +181,7 @@ import * as ep___gallery_posts_show from './endpoints/gallery/posts/show.js';
|
|||||||
import * as ep___gallery_posts_unlike from './endpoints/gallery/posts/unlike.js';
|
import * as ep___gallery_posts_unlike from './endpoints/gallery/posts/unlike.js';
|
||||||
import * as ep___gallery_posts_update from './endpoints/gallery/posts/update.js';
|
import * as ep___gallery_posts_update from './endpoints/gallery/posts/update.js';
|
||||||
import * as ep___getOnlineUsersCount from './endpoints/get-online-users-count.js';
|
import * as ep___getOnlineUsersCount from './endpoints/get-online-users-count.js';
|
||||||
|
import * as ep___getAvatarDecorations from './endpoints/get-avatar-decorations.js';
|
||||||
import * as ep___hashtags_list from './endpoints/hashtags/list.js';
|
import * as ep___hashtags_list from './endpoints/hashtags/list.js';
|
||||||
import * as ep___hashtags_search from './endpoints/hashtags/search.js';
|
import * as ep___hashtags_search from './endpoints/hashtags/search.js';
|
||||||
import * as ep___hashtags_show from './endpoints/hashtags/show.js';
|
import * as ep___hashtags_show from './endpoints/hashtags/show.js';
|
||||||
@@ -211,6 +217,7 @@ import * as ep___i_importMuting from './endpoints/i/import-muting.js';
|
|||||||
import * as ep___i_importUserLists from './endpoints/i/import-user-lists.js';
|
import * as ep___i_importUserLists from './endpoints/i/import-user-lists.js';
|
||||||
import * as ep___i_importAntennas from './endpoints/i/import-antennas.js';
|
import * as ep___i_importAntennas from './endpoints/i/import-antennas.js';
|
||||||
import * as ep___i_notifications from './endpoints/i/notifications.js';
|
import * as ep___i_notifications from './endpoints/i/notifications.js';
|
||||||
|
import * as ep___i_notificationsGrouped from './endpoints/i/notifications-grouped.js';
|
||||||
import * as ep___i_pageLikes from './endpoints/i/page-likes.js';
|
import * as ep___i_pageLikes from './endpoints/i/page-likes.js';
|
||||||
import * as ep___i_pages from './endpoints/i/pages.js';
|
import * as ep___i_pages from './endpoints/i/pages.js';
|
||||||
import * as ep___i_pin from './endpoints/i/pin.js';
|
import * as ep___i_pin from './endpoints/i/pin.js';
|
||||||
@@ -351,6 +358,7 @@ import * as ep___users_show from './endpoints/users/show.js';
|
|||||||
import * as ep___users_achievements from './endpoints/users/achievements.js';
|
import * as ep___users_achievements from './endpoints/users/achievements.js';
|
||||||
import * as ep___users_updateMemo from './endpoints/users/update-memo.js';
|
import * as ep___users_updateMemo from './endpoints/users/update-memo.js';
|
||||||
import * as ep___fetchRss from './endpoints/fetch-rss.js';
|
import * as ep___fetchRss from './endpoints/fetch-rss.js';
|
||||||
|
import * as ep___fetchExternalResources from './endpoints/fetch-external-resources.js';
|
||||||
import * as ep___retention from './endpoints/retention.js';
|
import * as ep___retention from './endpoints/retention.js';
|
||||||
import { GetterService } from './GetterService.js';
|
import { GetterService } from './GetterService.js';
|
||||||
import { ApiLoggerService } from './ApiLoggerService.js';
|
import { ApiLoggerService } from './ApiLoggerService.js';
|
||||||
@@ -368,6 +376,10 @@ const $admin_announcements_create: Provider = { provide: 'ep:admin/announcements
|
|||||||
const $admin_announcements_delete: Provider = { provide: 'ep:admin/announcements/delete', useClass: ep___admin_announcements_delete.default };
|
const $admin_announcements_delete: Provider = { provide: 'ep:admin/announcements/delete', useClass: ep___admin_announcements_delete.default };
|
||||||
const $admin_announcements_list: Provider = { provide: 'ep:admin/announcements/list', useClass: ep___admin_announcements_list.default };
|
const $admin_announcements_list: Provider = { provide: 'ep:admin/announcements/list', useClass: ep___admin_announcements_list.default };
|
||||||
const $admin_announcements_update: Provider = { provide: 'ep:admin/announcements/update', useClass: ep___admin_announcements_update.default };
|
const $admin_announcements_update: Provider = { provide: 'ep:admin/announcements/update', useClass: ep___admin_announcements_update.default };
|
||||||
|
const $admin_avatarDecorations_create: Provider = { provide: 'ep:admin/avatar-decorations/create', useClass: ep___admin_avatarDecorations_create.default };
|
||||||
|
const $admin_avatarDecorations_delete: Provider = { provide: 'ep:admin/avatar-decorations/delete', useClass: ep___admin_avatarDecorations_delete.default };
|
||||||
|
const $admin_avatarDecorations_list: Provider = { provide: 'ep:admin/avatar-decorations/list', useClass: ep___admin_avatarDecorations_list.default };
|
||||||
|
const $admin_avatarDecorations_update: Provider = { provide: 'ep:admin/avatar-decorations/update', useClass: ep___admin_avatarDecorations_update.default };
|
||||||
const $admin_deleteAllFilesOfAUser: Provider = { provide: 'ep:admin/delete-all-files-of-a-user', useClass: ep___admin_deleteAllFilesOfAUser.default };
|
const $admin_deleteAllFilesOfAUser: Provider = { provide: 'ep:admin/delete-all-files-of-a-user', useClass: ep___admin_deleteAllFilesOfAUser.default };
|
||||||
const $admin_drive_cleanRemoteFiles: Provider = { provide: 'ep:admin/drive/clean-remote-files', useClass: ep___admin_drive_cleanRemoteFiles.default };
|
const $admin_drive_cleanRemoteFiles: Provider = { provide: 'ep:admin/drive/clean-remote-files', useClass: ep___admin_drive_cleanRemoteFiles.default };
|
||||||
const $admin_drive_cleanup: Provider = { provide: 'ep:admin/drive/cleanup', useClass: ep___admin_drive_cleanup.default };
|
const $admin_drive_cleanup: Provider = { provide: 'ep:admin/drive/cleanup', useClass: ep___admin_drive_cleanup.default };
|
||||||
@@ -511,6 +523,7 @@ const $federation_stats: Provider = { provide: 'ep:federation/stats', useClass:
|
|||||||
const $following_create: Provider = { provide: 'ep:following/create', useClass: ep___following_create.default };
|
const $following_create: Provider = { provide: 'ep:following/create', useClass: ep___following_create.default };
|
||||||
const $following_delete: Provider = { provide: 'ep:following/delete', useClass: ep___following_delete.default };
|
const $following_delete: Provider = { provide: 'ep:following/delete', useClass: ep___following_delete.default };
|
||||||
const $following_update: Provider = { provide: 'ep:following/update', useClass: ep___following_update.default };
|
const $following_update: Provider = { provide: 'ep:following/update', useClass: ep___following_update.default };
|
||||||
|
const $following_update_all: Provider = { provide: 'ep:following/update-all', useClass: ep___following_update_all.default };
|
||||||
const $following_invalidate: Provider = { provide: 'ep:following/invalidate', useClass: ep___following_invalidate.default };
|
const $following_invalidate: Provider = { provide: 'ep:following/invalidate', useClass: ep___following_invalidate.default };
|
||||||
const $following_requests_accept: Provider = { provide: 'ep:following/requests/accept', useClass: ep___following_requests_accept.default };
|
const $following_requests_accept: Provider = { provide: 'ep:following/requests/accept', useClass: ep___following_requests_accept.default };
|
||||||
const $following_requests_cancel: Provider = { provide: 'ep:following/requests/cancel', useClass: ep___following_requests_cancel.default };
|
const $following_requests_cancel: Provider = { provide: 'ep:following/requests/cancel', useClass: ep___following_requests_cancel.default };
|
||||||
@@ -526,6 +539,7 @@ const $gallery_posts_show: Provider = { provide: 'ep:gallery/posts/show', useCla
|
|||||||
const $gallery_posts_unlike: Provider = { provide: 'ep:gallery/posts/unlike', useClass: ep___gallery_posts_unlike.default };
|
const $gallery_posts_unlike: Provider = { provide: 'ep:gallery/posts/unlike', useClass: ep___gallery_posts_unlike.default };
|
||||||
const $gallery_posts_update: Provider = { provide: 'ep:gallery/posts/update', useClass: ep___gallery_posts_update.default };
|
const $gallery_posts_update: Provider = { provide: 'ep:gallery/posts/update', useClass: ep___gallery_posts_update.default };
|
||||||
const $getOnlineUsersCount: Provider = { provide: 'ep:get-online-users-count', useClass: ep___getOnlineUsersCount.default };
|
const $getOnlineUsersCount: Provider = { provide: 'ep:get-online-users-count', useClass: ep___getOnlineUsersCount.default };
|
||||||
|
const $getAvatarDecorations: Provider = { provide: 'ep:get-avatar-decorations', useClass: ep___getAvatarDecorations.default };
|
||||||
const $hashtags_list: Provider = { provide: 'ep:hashtags/list', useClass: ep___hashtags_list.default };
|
const $hashtags_list: Provider = { provide: 'ep:hashtags/list', useClass: ep___hashtags_list.default };
|
||||||
const $hashtags_search: Provider = { provide: 'ep:hashtags/search', useClass: ep___hashtags_search.default };
|
const $hashtags_search: Provider = { provide: 'ep:hashtags/search', useClass: ep___hashtags_search.default };
|
||||||
const $hashtags_show: Provider = { provide: 'ep:hashtags/show', useClass: ep___hashtags_show.default };
|
const $hashtags_show: Provider = { provide: 'ep:hashtags/show', useClass: ep___hashtags_show.default };
|
||||||
@@ -561,6 +575,7 @@ const $i_importMuting: Provider = { provide: 'ep:i/import-muting', useClass: ep_
|
|||||||
const $i_importUserLists: Provider = { provide: 'ep:i/import-user-lists', useClass: ep___i_importUserLists.default };
|
const $i_importUserLists: Provider = { provide: 'ep:i/import-user-lists', useClass: ep___i_importUserLists.default };
|
||||||
const $i_importAntennas: Provider = { provide: 'ep:i/import-antennas', useClass: ep___i_importAntennas.default };
|
const $i_importAntennas: Provider = { provide: 'ep:i/import-antennas', useClass: ep___i_importAntennas.default };
|
||||||
const $i_notifications: Provider = { provide: 'ep:i/notifications', useClass: ep___i_notifications.default };
|
const $i_notifications: Provider = { provide: 'ep:i/notifications', useClass: ep___i_notifications.default };
|
||||||
|
const $i_notificationsGrouped: Provider = { provide: 'ep:i/notifications-grouped', useClass: ep___i_notificationsGrouped.default };
|
||||||
const $i_pageLikes: Provider = { provide: 'ep:i/page-likes', useClass: ep___i_pageLikes.default };
|
const $i_pageLikes: Provider = { provide: 'ep:i/page-likes', useClass: ep___i_pageLikes.default };
|
||||||
const $i_pages: Provider = { provide: 'ep:i/pages', useClass: ep___i_pages.default };
|
const $i_pages: Provider = { provide: 'ep:i/pages', useClass: ep___i_pages.default };
|
||||||
const $i_pin: Provider = { provide: 'ep:i/pin', useClass: ep___i_pin.default };
|
const $i_pin: Provider = { provide: 'ep:i/pin', useClass: ep___i_pin.default };
|
||||||
@@ -701,6 +716,7 @@ const $users_show: Provider = { provide: 'ep:users/show', useClass: ep___users_s
|
|||||||
const $users_achievements: Provider = { provide: 'ep:users/achievements', useClass: ep___users_achievements.default };
|
const $users_achievements: Provider = { provide: 'ep:users/achievements', useClass: ep___users_achievements.default };
|
||||||
const $users_updateMemo: Provider = { provide: 'ep:users/update-memo', useClass: ep___users_updateMemo.default };
|
const $users_updateMemo: Provider = { provide: 'ep:users/update-memo', useClass: ep___users_updateMemo.default };
|
||||||
const $fetchRss: Provider = { provide: 'ep:fetch-rss', useClass: ep___fetchRss.default };
|
const $fetchRss: Provider = { provide: 'ep:fetch-rss', useClass: ep___fetchRss.default };
|
||||||
|
const $fetchExternalResources: Provider = { provide: 'ep:fetch-external-resources', useClass: ep___fetchExternalResources.default };
|
||||||
const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention.default };
|
const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention.default };
|
||||||
|
|
||||||
@Module({
|
@Module({
|
||||||
@@ -722,6 +738,10 @@ const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention
|
|||||||
$admin_announcements_delete,
|
$admin_announcements_delete,
|
||||||
$admin_announcements_list,
|
$admin_announcements_list,
|
||||||
$admin_announcements_update,
|
$admin_announcements_update,
|
||||||
|
$admin_avatarDecorations_create,
|
||||||
|
$admin_avatarDecorations_delete,
|
||||||
|
$admin_avatarDecorations_list,
|
||||||
|
$admin_avatarDecorations_update,
|
||||||
$admin_deleteAllFilesOfAUser,
|
$admin_deleteAllFilesOfAUser,
|
||||||
$admin_drive_cleanRemoteFiles,
|
$admin_drive_cleanRemoteFiles,
|
||||||
$admin_drive_cleanup,
|
$admin_drive_cleanup,
|
||||||
@@ -865,6 +885,7 @@ const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention
|
|||||||
$following_create,
|
$following_create,
|
||||||
$following_delete,
|
$following_delete,
|
||||||
$following_update,
|
$following_update,
|
||||||
|
$following_update_all,
|
||||||
$following_invalidate,
|
$following_invalidate,
|
||||||
$following_requests_accept,
|
$following_requests_accept,
|
||||||
$following_requests_cancel,
|
$following_requests_cancel,
|
||||||
@@ -880,6 +901,7 @@ const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention
|
|||||||
$gallery_posts_unlike,
|
$gallery_posts_unlike,
|
||||||
$gallery_posts_update,
|
$gallery_posts_update,
|
||||||
$getOnlineUsersCount,
|
$getOnlineUsersCount,
|
||||||
|
$getAvatarDecorations,
|
||||||
$hashtags_list,
|
$hashtags_list,
|
||||||
$hashtags_search,
|
$hashtags_search,
|
||||||
$hashtags_show,
|
$hashtags_show,
|
||||||
@@ -915,6 +937,7 @@ const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention
|
|||||||
$i_importUserLists,
|
$i_importUserLists,
|
||||||
$i_importAntennas,
|
$i_importAntennas,
|
||||||
$i_notifications,
|
$i_notifications,
|
||||||
|
$i_notificationsGrouped,
|
||||||
$i_pageLikes,
|
$i_pageLikes,
|
||||||
$i_pages,
|
$i_pages,
|
||||||
$i_pin,
|
$i_pin,
|
||||||
@@ -1055,6 +1078,7 @@ const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention
|
|||||||
$users_achievements,
|
$users_achievements,
|
||||||
$users_updateMemo,
|
$users_updateMemo,
|
||||||
$fetchRss,
|
$fetchRss,
|
||||||
|
$fetchExternalResources,
|
||||||
$retention,
|
$retention,
|
||||||
],
|
],
|
||||||
exports: [
|
exports: [
|
||||||
@@ -1070,6 +1094,10 @@ const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention
|
|||||||
$admin_announcements_delete,
|
$admin_announcements_delete,
|
||||||
$admin_announcements_list,
|
$admin_announcements_list,
|
||||||
$admin_announcements_update,
|
$admin_announcements_update,
|
||||||
|
$admin_avatarDecorations_create,
|
||||||
|
$admin_avatarDecorations_delete,
|
||||||
|
$admin_avatarDecorations_list,
|
||||||
|
$admin_avatarDecorations_update,
|
||||||
$admin_deleteAllFilesOfAUser,
|
$admin_deleteAllFilesOfAUser,
|
||||||
$admin_drive_cleanRemoteFiles,
|
$admin_drive_cleanRemoteFiles,
|
||||||
$admin_drive_cleanup,
|
$admin_drive_cleanup,
|
||||||
@@ -1213,6 +1241,7 @@ const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention
|
|||||||
$following_create,
|
$following_create,
|
||||||
$following_delete,
|
$following_delete,
|
||||||
$following_update,
|
$following_update,
|
||||||
|
$following_update_all,
|
||||||
$following_invalidate,
|
$following_invalidate,
|
||||||
$following_requests_accept,
|
$following_requests_accept,
|
||||||
$following_requests_cancel,
|
$following_requests_cancel,
|
||||||
@@ -1228,6 +1257,7 @@ const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention
|
|||||||
$gallery_posts_unlike,
|
$gallery_posts_unlike,
|
||||||
$gallery_posts_update,
|
$gallery_posts_update,
|
||||||
$getOnlineUsersCount,
|
$getOnlineUsersCount,
|
||||||
|
$getAvatarDecorations,
|
||||||
$hashtags_list,
|
$hashtags_list,
|
||||||
$hashtags_search,
|
$hashtags_search,
|
||||||
$hashtags_show,
|
$hashtags_show,
|
||||||
@@ -1263,6 +1293,7 @@ const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention
|
|||||||
$i_importUserLists,
|
$i_importUserLists,
|
||||||
$i_importAntennas,
|
$i_importAntennas,
|
||||||
$i_notifications,
|
$i_notifications,
|
||||||
|
$i_notificationsGrouped,
|
||||||
$i_pageLikes,
|
$i_pageLikes,
|
||||||
$i_pages,
|
$i_pages,
|
||||||
$i_pin,
|
$i_pin,
|
||||||
@@ -1400,6 +1431,7 @@ const $retention: Provider = { provide: 'ep:retention', useClass: ep___retention
|
|||||||
$users_achievements,
|
$users_achievements,
|
||||||
$users_updateMemo,
|
$users_updateMemo,
|
||||||
$fetchRss,
|
$fetchRss,
|
||||||
|
$fetchExternalResources,
|
||||||
$retention,
|
$retention,
|
||||||
],
|
],
|
||||||
})
|
})
|
||||||
|
@@ -15,6 +15,7 @@ import { bindThis } from '@/decorators.js';
|
|||||||
import { CacheService } from '@/core/CacheService.js';
|
import { CacheService } from '@/core/CacheService.js';
|
||||||
import { MiLocalUser } from '@/models/User.js';
|
import { MiLocalUser } from '@/models/User.js';
|
||||||
import { UserService } from '@/core/UserService.js';
|
import { UserService } from '@/core/UserService.js';
|
||||||
|
import { ChannelFollowingService } from '@/core/ChannelFollowingService.js';
|
||||||
import { AuthenticateService, AuthenticationError } from './AuthenticateService.js';
|
import { AuthenticateService, AuthenticationError } from './AuthenticateService.js';
|
||||||
import MainStreamConnection from './stream/Connection.js';
|
import MainStreamConnection from './stream/Connection.js';
|
||||||
import { ChannelsService } from './stream/ChannelsService.js';
|
import { ChannelsService } from './stream/ChannelsService.js';
|
||||||
@@ -39,6 +40,7 @@ export class StreamingApiServerService {
|
|||||||
private channelsService: ChannelsService,
|
private channelsService: ChannelsService,
|
||||||
private notificationService: NotificationService,
|
private notificationService: NotificationService,
|
||||||
private usersService: UserService,
|
private usersService: UserService,
|
||||||
|
private channelFollowingService: ChannelFollowingService,
|
||||||
) {
|
) {
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -93,6 +95,7 @@ export class StreamingApiServerService {
|
|||||||
this.noteReadService,
|
this.noteReadService,
|
||||||
this.notificationService,
|
this.notificationService,
|
||||||
this.cacheService,
|
this.cacheService,
|
||||||
|
this.channelFollowingService,
|
||||||
user, app,
|
user, app,
|
||||||
);
|
);
|
||||||
|
|
||||||
|
@@ -18,6 +18,10 @@ import * as ep___admin_announcements_create from './endpoints/admin/announcement
|
|||||||
import * as ep___admin_announcements_delete from './endpoints/admin/announcements/delete.js';
|
import * as ep___admin_announcements_delete from './endpoints/admin/announcements/delete.js';
|
||||||
import * as ep___admin_announcements_list from './endpoints/admin/announcements/list.js';
|
import * as ep___admin_announcements_list from './endpoints/admin/announcements/list.js';
|
||||||
import * as ep___admin_announcements_update from './endpoints/admin/announcements/update.js';
|
import * as ep___admin_announcements_update from './endpoints/admin/announcements/update.js';
|
||||||
|
import * as ep___admin_avatarDecorations_create from './endpoints/admin/avatar-decorations/create.js';
|
||||||
|
import * as ep___admin_avatarDecorations_delete from './endpoints/admin/avatar-decorations/delete.js';
|
||||||
|
import * as ep___admin_avatarDecorations_list from './endpoints/admin/avatar-decorations/list.js';
|
||||||
|
import * as ep___admin_avatarDecorations_update from './endpoints/admin/avatar-decorations/update.js';
|
||||||
import * as ep___admin_deleteAllFilesOfAUser from './endpoints/admin/delete-all-files-of-a-user.js';
|
import * as ep___admin_deleteAllFilesOfAUser from './endpoints/admin/delete-all-files-of-a-user.js';
|
||||||
import * as ep___admin_drive_cleanRemoteFiles from './endpoints/admin/drive/clean-remote-files.js';
|
import * as ep___admin_drive_cleanRemoteFiles from './endpoints/admin/drive/clean-remote-files.js';
|
||||||
import * as ep___admin_drive_cleanup from './endpoints/admin/drive/cleanup.js';
|
import * as ep___admin_drive_cleanup from './endpoints/admin/drive/cleanup.js';
|
||||||
@@ -161,6 +165,7 @@ import * as ep___federation_stats from './endpoints/federation/stats.js';
|
|||||||
import * as ep___following_create from './endpoints/following/create.js';
|
import * as ep___following_create from './endpoints/following/create.js';
|
||||||
import * as ep___following_delete from './endpoints/following/delete.js';
|
import * as ep___following_delete from './endpoints/following/delete.js';
|
||||||
import * as ep___following_update from './endpoints/following/update.js';
|
import * as ep___following_update from './endpoints/following/update.js';
|
||||||
|
import * as ep___following_update_all from './endpoints/following/update-all.js';
|
||||||
import * as ep___following_invalidate from './endpoints/following/invalidate.js';
|
import * as ep___following_invalidate from './endpoints/following/invalidate.js';
|
||||||
import * as ep___following_requests_accept from './endpoints/following/requests/accept.js';
|
import * as ep___following_requests_accept from './endpoints/following/requests/accept.js';
|
||||||
import * as ep___following_requests_cancel from './endpoints/following/requests/cancel.js';
|
import * as ep___following_requests_cancel from './endpoints/following/requests/cancel.js';
|
||||||
@@ -176,6 +181,7 @@ import * as ep___gallery_posts_show from './endpoints/gallery/posts/show.js';
|
|||||||
import * as ep___gallery_posts_unlike from './endpoints/gallery/posts/unlike.js';
|
import * as ep___gallery_posts_unlike from './endpoints/gallery/posts/unlike.js';
|
||||||
import * as ep___gallery_posts_update from './endpoints/gallery/posts/update.js';
|
import * as ep___gallery_posts_update from './endpoints/gallery/posts/update.js';
|
||||||
import * as ep___getOnlineUsersCount from './endpoints/get-online-users-count.js';
|
import * as ep___getOnlineUsersCount from './endpoints/get-online-users-count.js';
|
||||||
|
import * as ep___getAvatarDecorations from './endpoints/get-avatar-decorations.js';
|
||||||
import * as ep___hashtags_list from './endpoints/hashtags/list.js';
|
import * as ep___hashtags_list from './endpoints/hashtags/list.js';
|
||||||
import * as ep___hashtags_search from './endpoints/hashtags/search.js';
|
import * as ep___hashtags_search from './endpoints/hashtags/search.js';
|
||||||
import * as ep___hashtags_show from './endpoints/hashtags/show.js';
|
import * as ep___hashtags_show from './endpoints/hashtags/show.js';
|
||||||
@@ -211,6 +217,7 @@ import * as ep___i_importMuting from './endpoints/i/import-muting.js';
|
|||||||
import * as ep___i_importUserLists from './endpoints/i/import-user-lists.js';
|
import * as ep___i_importUserLists from './endpoints/i/import-user-lists.js';
|
||||||
import * as ep___i_importAntennas from './endpoints/i/import-antennas.js';
|
import * as ep___i_importAntennas from './endpoints/i/import-antennas.js';
|
||||||
import * as ep___i_notifications from './endpoints/i/notifications.js';
|
import * as ep___i_notifications from './endpoints/i/notifications.js';
|
||||||
|
import * as ep___i_notificationsGrouped from './endpoints/i/notifications-grouped.js';
|
||||||
import * as ep___i_pageLikes from './endpoints/i/page-likes.js';
|
import * as ep___i_pageLikes from './endpoints/i/page-likes.js';
|
||||||
import * as ep___i_pages from './endpoints/i/pages.js';
|
import * as ep___i_pages from './endpoints/i/pages.js';
|
||||||
import * as ep___i_pin from './endpoints/i/pin.js';
|
import * as ep___i_pin from './endpoints/i/pin.js';
|
||||||
@@ -351,6 +358,7 @@ import * as ep___users_show from './endpoints/users/show.js';
|
|||||||
import * as ep___users_achievements from './endpoints/users/achievements.js';
|
import * as ep___users_achievements from './endpoints/users/achievements.js';
|
||||||
import * as ep___users_updateMemo from './endpoints/users/update-memo.js';
|
import * as ep___users_updateMemo from './endpoints/users/update-memo.js';
|
||||||
import * as ep___fetchRss from './endpoints/fetch-rss.js';
|
import * as ep___fetchRss from './endpoints/fetch-rss.js';
|
||||||
|
import * as ep___fetchExternalResources from './endpoints/fetch-external-resources.js';
|
||||||
import * as ep___retention from './endpoints/retention.js';
|
import * as ep___retention from './endpoints/retention.js';
|
||||||
|
|
||||||
const eps = [
|
const eps = [
|
||||||
@@ -366,6 +374,10 @@ const eps = [
|
|||||||
['admin/announcements/delete', ep___admin_announcements_delete],
|
['admin/announcements/delete', ep___admin_announcements_delete],
|
||||||
['admin/announcements/list', ep___admin_announcements_list],
|
['admin/announcements/list', ep___admin_announcements_list],
|
||||||
['admin/announcements/update', ep___admin_announcements_update],
|
['admin/announcements/update', ep___admin_announcements_update],
|
||||||
|
['admin/avatar-decorations/create', ep___admin_avatarDecorations_create],
|
||||||
|
['admin/avatar-decorations/delete', ep___admin_avatarDecorations_delete],
|
||||||
|
['admin/avatar-decorations/list', ep___admin_avatarDecorations_list],
|
||||||
|
['admin/avatar-decorations/update', ep___admin_avatarDecorations_update],
|
||||||
['admin/delete-all-files-of-a-user', ep___admin_deleteAllFilesOfAUser],
|
['admin/delete-all-files-of-a-user', ep___admin_deleteAllFilesOfAUser],
|
||||||
['admin/drive/clean-remote-files', ep___admin_drive_cleanRemoteFiles],
|
['admin/drive/clean-remote-files', ep___admin_drive_cleanRemoteFiles],
|
||||||
['admin/drive/cleanup', ep___admin_drive_cleanup],
|
['admin/drive/cleanup', ep___admin_drive_cleanup],
|
||||||
@@ -509,6 +521,7 @@ const eps = [
|
|||||||
['following/create', ep___following_create],
|
['following/create', ep___following_create],
|
||||||
['following/delete', ep___following_delete],
|
['following/delete', ep___following_delete],
|
||||||
['following/update', ep___following_update],
|
['following/update', ep___following_update],
|
||||||
|
['following/update-all', ep___following_update_all],
|
||||||
['following/invalidate', ep___following_invalidate],
|
['following/invalidate', ep___following_invalidate],
|
||||||
['following/requests/accept', ep___following_requests_accept],
|
['following/requests/accept', ep___following_requests_accept],
|
||||||
['following/requests/cancel', ep___following_requests_cancel],
|
['following/requests/cancel', ep___following_requests_cancel],
|
||||||
@@ -524,6 +537,7 @@ const eps = [
|
|||||||
['gallery/posts/unlike', ep___gallery_posts_unlike],
|
['gallery/posts/unlike', ep___gallery_posts_unlike],
|
||||||
['gallery/posts/update', ep___gallery_posts_update],
|
['gallery/posts/update', ep___gallery_posts_update],
|
||||||
['get-online-users-count', ep___getOnlineUsersCount],
|
['get-online-users-count', ep___getOnlineUsersCount],
|
||||||
|
['get-avatar-decorations', ep___getAvatarDecorations],
|
||||||
['hashtags/list', ep___hashtags_list],
|
['hashtags/list', ep___hashtags_list],
|
||||||
['hashtags/search', ep___hashtags_search],
|
['hashtags/search', ep___hashtags_search],
|
||||||
['hashtags/show', ep___hashtags_show],
|
['hashtags/show', ep___hashtags_show],
|
||||||
@@ -559,6 +573,7 @@ const eps = [
|
|||||||
['i/import-user-lists', ep___i_importUserLists],
|
['i/import-user-lists', ep___i_importUserLists],
|
||||||
['i/import-antennas', ep___i_importAntennas],
|
['i/import-antennas', ep___i_importAntennas],
|
||||||
['i/notifications', ep___i_notifications],
|
['i/notifications', ep___i_notifications],
|
||||||
|
['i/notifications-grouped', ep___i_notificationsGrouped],
|
||||||
['i/page-likes', ep___i_pageLikes],
|
['i/page-likes', ep___i_pageLikes],
|
||||||
['i/pages', ep___i_pages],
|
['i/pages', ep___i_pages],
|
||||||
['i/pin', ep___i_pin],
|
['i/pin', ep___i_pin],
|
||||||
@@ -699,6 +714,7 @@ const eps = [
|
|||||||
['users/achievements', ep___users_achievements],
|
['users/achievements', ep___users_achievements],
|
||||||
['users/update-memo', ep___users_updateMemo],
|
['users/update-memo', ep___users_updateMemo],
|
||||||
['fetch-rss', ep___fetchRss],
|
['fetch-rss', ep___fetchRss],
|
||||||
|
['fetch-external-resources', ep___fetchExternalResources],
|
||||||
['retention', ep___retention],
|
['retention', ep___retention],
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@@ -0,0 +1,44 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { Injectable } from '@nestjs/common';
|
||||||
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
|
import { AvatarDecorationService } from '@/core/AvatarDecorationService.js';
|
||||||
|
|
||||||
|
export const meta = {
|
||||||
|
tags: ['admin'],
|
||||||
|
|
||||||
|
requireCredential: true,
|
||||||
|
requireRolePolicy: 'canManageAvatarDecorations',
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const paramDef = {
|
||||||
|
type: 'object',
|
||||||
|
properties: {
|
||||||
|
name: { type: 'string', minLength: 1 },
|
||||||
|
description: { type: 'string' },
|
||||||
|
url: { type: 'string', minLength: 1 },
|
||||||
|
roleIdsThatCanBeUsedThisDecoration: { type: 'array', items: {
|
||||||
|
type: 'string',
|
||||||
|
} },
|
||||||
|
},
|
||||||
|
required: ['name', 'description', 'url'],
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
@Injectable()
|
||||||
|
export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-disable-line import/no-default-export
|
||||||
|
constructor(
|
||||||
|
private avatarDecorationService: AvatarDecorationService,
|
||||||
|
) {
|
||||||
|
super(meta, paramDef, async (ps, me) => {
|
||||||
|
await this.avatarDecorationService.create({
|
||||||
|
name: ps.name,
|
||||||
|
description: ps.description,
|
||||||
|
url: ps.url,
|
||||||
|
roleIdsThatCanBeUsedThisDecoration: ps.roleIdsThatCanBeUsedThisDecoration,
|
||||||
|
}, me);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
@@ -0,0 +1,38 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
|
import { DI } from '@/di-symbols.js';
|
||||||
|
import { AvatarDecorationService } from '@/core/AvatarDecorationService.js';
|
||||||
|
import { ApiError } from '../../../error.js';
|
||||||
|
|
||||||
|
export const meta = {
|
||||||
|
tags: ['admin'],
|
||||||
|
|
||||||
|
requireCredential: true,
|
||||||
|
requireRolePolicy: 'canManageAvatarDecorations',
|
||||||
|
errors: {
|
||||||
|
},
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const paramDef = {
|
||||||
|
type: 'object',
|
||||||
|
properties: {
|
||||||
|
id: { type: 'string', format: 'misskey:id' },
|
||||||
|
},
|
||||||
|
required: ['id'],
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
@Injectable()
|
||||||
|
export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-disable-line import/no-default-export
|
||||||
|
constructor(
|
||||||
|
private avatarDecorationService: AvatarDecorationService,
|
||||||
|
) {
|
||||||
|
super(meta, paramDef, async (ps, me) => {
|
||||||
|
await this.avatarDecorationService.delete(ps.id, me);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
@@ -0,0 +1,101 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
|
import type { AnnouncementsRepository, AnnouncementReadsRepository } from '@/models/_.js';
|
||||||
|
import type { MiAnnouncement } from '@/models/Announcement.js';
|
||||||
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
|
import { QueryService } from '@/core/QueryService.js';
|
||||||
|
import { DI } from '@/di-symbols.js';
|
||||||
|
import { IdService } from '@/core/IdService.js';
|
||||||
|
import { AvatarDecorationService } from '@/core/AvatarDecorationService.js';
|
||||||
|
|
||||||
|
export const meta = {
|
||||||
|
tags: ['admin'],
|
||||||
|
|
||||||
|
requireCredential: true,
|
||||||
|
requireRolePolicy: 'canManageAvatarDecorations',
|
||||||
|
|
||||||
|
res: {
|
||||||
|
type: 'array',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
items: {
|
||||||
|
type: 'object',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
properties: {
|
||||||
|
id: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
format: 'id',
|
||||||
|
example: 'xxxxxxxxxx',
|
||||||
|
},
|
||||||
|
createdAt: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
format: 'date-time',
|
||||||
|
},
|
||||||
|
updatedAt: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: true,
|
||||||
|
format: 'date-time',
|
||||||
|
},
|
||||||
|
name: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
},
|
||||||
|
description: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
},
|
||||||
|
url: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
},
|
||||||
|
roleIdsThatCanBeUsedThisDecoration: {
|
||||||
|
type: 'array',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
items: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
format: 'id',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const paramDef = {
|
||||||
|
type: 'object',
|
||||||
|
properties: {
|
||||||
|
limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 },
|
||||||
|
sinceId: { type: 'string', format: 'misskey:id' },
|
||||||
|
untilId: { type: 'string', format: 'misskey:id' },
|
||||||
|
userId: { type: 'string', format: 'misskey:id', nullable: true },
|
||||||
|
},
|
||||||
|
required: [],
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
@Injectable()
|
||||||
|
export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-disable-line import/no-default-export
|
||||||
|
constructor(
|
||||||
|
private avatarDecorationService: AvatarDecorationService,
|
||||||
|
private idService: IdService,
|
||||||
|
) {
|
||||||
|
super(meta, paramDef, async (ps, me) => {
|
||||||
|
const avatarDecorations = await this.avatarDecorationService.getAll(true);
|
||||||
|
|
||||||
|
return avatarDecorations.map(avatarDecoration => ({
|
||||||
|
id: avatarDecoration.id,
|
||||||
|
createdAt: this.idService.parse(avatarDecoration.id).date.toISOString(),
|
||||||
|
updatedAt: avatarDecoration.updatedAt?.toISOString() ?? null,
|
||||||
|
name: avatarDecoration.name,
|
||||||
|
description: avatarDecoration.description,
|
||||||
|
url: avatarDecoration.url,
|
||||||
|
roleIdsThatCanBeUsedThisDecoration: avatarDecoration.roleIdsThatCanBeUsedThisDecoration,
|
||||||
|
}));
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
@@ -0,0 +1,50 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
|
import { DI } from '@/di-symbols.js';
|
||||||
|
import { AvatarDecorationService } from '@/core/AvatarDecorationService.js';
|
||||||
|
import { ApiError } from '../../../error.js';
|
||||||
|
|
||||||
|
export const meta = {
|
||||||
|
tags: ['admin'],
|
||||||
|
|
||||||
|
requireCredential: true,
|
||||||
|
requireRolePolicy: 'canManageAvatarDecorations',
|
||||||
|
|
||||||
|
errors: {
|
||||||
|
},
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const paramDef = {
|
||||||
|
type: 'object',
|
||||||
|
properties: {
|
||||||
|
id: { type: 'string', format: 'misskey:id' },
|
||||||
|
name: { type: 'string', minLength: 1 },
|
||||||
|
description: { type: 'string' },
|
||||||
|
url: { type: 'string', minLength: 1 },
|
||||||
|
roleIdsThatCanBeUsedThisDecoration: { type: 'array', items: {
|
||||||
|
type: 'string',
|
||||||
|
} },
|
||||||
|
},
|
||||||
|
required: ['id'],
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
@Injectable()
|
||||||
|
export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-disable-line import/no-default-export
|
||||||
|
constructor(
|
||||||
|
private avatarDecorationService: AvatarDecorationService,
|
||||||
|
) {
|
||||||
|
super(meta, paramDef, async (ps, me) => {
|
||||||
|
await this.avatarDecorationService.update(ps.id, {
|
||||||
|
name: ps.name,
|
||||||
|
description: ps.description,
|
||||||
|
url: ps.url,
|
||||||
|
roleIdsThatCanBeUsedThisDecoration: ps.roleIdsThatCanBeUsedThisDecoration,
|
||||||
|
}, me);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
@@ -106,11 +106,11 @@ export const meta = {
|
|||||||
optional: false, nullable: false,
|
optional: false, nullable: false,
|
||||||
},
|
},
|
||||||
silencedHosts: {
|
silencedHosts: {
|
||||||
type: "array",
|
type: 'array',
|
||||||
optional: true,
|
optional: true,
|
||||||
nullable: false,
|
nullable: false,
|
||||||
items: {
|
items: {
|
||||||
type: "string",
|
type: 'string',
|
||||||
optional: false,
|
optional: false,
|
||||||
nullable: false,
|
nullable: false,
|
||||||
},
|
},
|
||||||
@@ -291,6 +291,10 @@ export const meta = {
|
|||||||
type: 'object',
|
type: 'object',
|
||||||
optional: false, nullable: false,
|
optional: false, nullable: false,
|
||||||
},
|
},
|
||||||
|
enableFanoutTimeline: {
|
||||||
|
type: 'boolean',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
},
|
||||||
perLocalUserUserTimelineCacheMax: {
|
perLocalUserUserTimelineCacheMax: {
|
||||||
type: 'number',
|
type: 'number',
|
||||||
optional: false, nullable: false,
|
optional: false, nullable: false,
|
||||||
@@ -419,6 +423,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
enableIdenticonGeneration: instance.enableIdenticonGeneration,
|
enableIdenticonGeneration: instance.enableIdenticonGeneration,
|
||||||
policies: { ...DEFAULT_POLICIES, ...instance.policies },
|
policies: { ...DEFAULT_POLICIES, ...instance.policies },
|
||||||
manifestJsonOverride: instance.manifestJsonOverride,
|
manifestJsonOverride: instance.manifestJsonOverride,
|
||||||
|
enableFanoutTimeline: instance.enableFanoutTimeline,
|
||||||
perLocalUserUserTimelineCacheMax: instance.perLocalUserUserTimelineCacheMax,
|
perLocalUserUserTimelineCacheMax: instance.perLocalUserUserTimelineCacheMax,
|
||||||
perRemoteUserUserTimelineCacheMax: instance.perRemoteUserUserTimelineCacheMax,
|
perRemoteUserUserTimelineCacheMax: instance.perRemoteUserUserTimelineCacheMax,
|
||||||
perUserHomeTimelineCacheMax: instance.perUserHomeTimelineCacheMax,
|
perUserHomeTimelineCacheMax: instance.perUserHomeTimelineCacheMax,
|
||||||
|
@@ -120,6 +120,7 @@ export const paramDef = {
|
|||||||
serverRules: { type: 'array', items: { type: 'string' } },
|
serverRules: { type: 'array', items: { type: 'string' } },
|
||||||
preservedUsernames: { type: 'array', items: { type: 'string' } },
|
preservedUsernames: { type: 'array', items: { type: 'string' } },
|
||||||
manifestJsonOverride: { type: 'string' },
|
manifestJsonOverride: { type: 'string' },
|
||||||
|
enableFanoutTimeline: { type: 'boolean' },
|
||||||
perLocalUserUserTimelineCacheMax: { type: 'integer' },
|
perLocalUserUserTimelineCacheMax: { type: 'integer' },
|
||||||
perRemoteUserUserTimelineCacheMax: { type: 'integer' },
|
perRemoteUserUserTimelineCacheMax: { type: 'integer' },
|
||||||
perUserHomeTimelineCacheMax: { type: 'integer' },
|
perUserHomeTimelineCacheMax: { type: 'integer' },
|
||||||
@@ -480,6 +481,10 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
set.manifestJsonOverride = ps.manifestJsonOverride;
|
set.manifestJsonOverride = ps.manifestJsonOverride;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (ps.enableFanoutTimeline !== undefined) {
|
||||||
|
set.enableFanoutTimeline = ps.enableFanoutTimeline;
|
||||||
|
}
|
||||||
|
|
||||||
if (ps.perLocalUserUserTimelineCacheMax !== undefined) {
|
if (ps.perLocalUserUserTimelineCacheMax !== undefined) {
|
||||||
set.perLocalUserUserTimelineCacheMax = ps.perLocalUserUserTimelineCacheMax;
|
set.perLocalUserUserTimelineCacheMax = ps.perLocalUserUserTimelineCacheMax;
|
||||||
}
|
}
|
||||||
|
@@ -5,9 +5,9 @@
|
|||||||
|
|
||||||
import { Inject, Injectable } from '@nestjs/common';
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
import { Endpoint } from '@/server/api/endpoint-base.js';
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
import type { ChannelFollowingsRepository, ChannelsRepository } from '@/models/_.js';
|
import type { ChannelsRepository } from '@/models/_.js';
|
||||||
import { IdService } from '@/core/IdService.js';
|
|
||||||
import { DI } from '@/di-symbols.js';
|
import { DI } from '@/di-symbols.js';
|
||||||
|
import { ChannelFollowingService } from '@/core/ChannelFollowingService.js';
|
||||||
import { ApiError } from '../../error.js';
|
import { ApiError } from '../../error.js';
|
||||||
|
|
||||||
export const meta = {
|
export const meta = {
|
||||||
@@ -41,11 +41,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
constructor(
|
constructor(
|
||||||
@Inject(DI.channelsRepository)
|
@Inject(DI.channelsRepository)
|
||||||
private channelsRepository: ChannelsRepository,
|
private channelsRepository: ChannelsRepository,
|
||||||
|
private channelFollowingService: ChannelFollowingService,
|
||||||
@Inject(DI.channelFollowingsRepository)
|
|
||||||
private channelFollowingsRepository: ChannelFollowingsRepository,
|
|
||||||
|
|
||||||
private idService: IdService,
|
|
||||||
) {
|
) {
|
||||||
super(meta, paramDef, async (ps, me) => {
|
super(meta, paramDef, async (ps, me) => {
|
||||||
const channel = await this.channelsRepository.findOneBy({
|
const channel = await this.channelsRepository.findOneBy({
|
||||||
@@ -56,11 +52,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
throw new ApiError(meta.errors.noSuchChannel);
|
throw new ApiError(meta.errors.noSuchChannel);
|
||||||
}
|
}
|
||||||
|
|
||||||
await this.channelFollowingsRepository.insert({
|
await this.channelFollowingService.follow(me, channel);
|
||||||
id: this.idService.gen(),
|
|
||||||
followerId: me.id,
|
|
||||||
followeeId: channel.id,
|
|
||||||
});
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -5,8 +5,9 @@
|
|||||||
|
|
||||||
import { Inject, Injectable } from '@nestjs/common';
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
import { Endpoint } from '@/server/api/endpoint-base.js';
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
import type { ChannelFollowingsRepository, ChannelsRepository } from '@/models/_.js';
|
import type { ChannelsRepository } from '@/models/_.js';
|
||||||
import { DI } from '@/di-symbols.js';
|
import { DI } from '@/di-symbols.js';
|
||||||
|
import { ChannelFollowingService } from '@/core/ChannelFollowingService.js';
|
||||||
import { ApiError } from '../../error.js';
|
import { ApiError } from '../../error.js';
|
||||||
|
|
||||||
export const meta = {
|
export const meta = {
|
||||||
@@ -40,9 +41,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
constructor(
|
constructor(
|
||||||
@Inject(DI.channelsRepository)
|
@Inject(DI.channelsRepository)
|
||||||
private channelsRepository: ChannelsRepository,
|
private channelsRepository: ChannelsRepository,
|
||||||
|
private channelFollowingService: ChannelFollowingService,
|
||||||
@Inject(DI.channelFollowingsRepository)
|
|
||||||
private channelFollowingsRepository: ChannelFollowingsRepository,
|
|
||||||
) {
|
) {
|
||||||
super(meta, paramDef, async (ps, me) => {
|
super(meta, paramDef, async (ps, me) => {
|
||||||
const channel = await this.channelsRepository.findOneBy({
|
const channel = await this.channelsRepository.findOneBy({
|
||||||
@@ -53,10 +52,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
throw new ApiError(meta.errors.noSuchChannel);
|
throw new ApiError(meta.errors.noSuchChannel);
|
||||||
}
|
}
|
||||||
|
|
||||||
await this.channelFollowingsRepository.delete({
|
await this.channelFollowingService.unfollow(me, channel);
|
||||||
followerId: me.id,
|
|
||||||
followeeId: channel.id,
|
|
||||||
});
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -0,0 +1,72 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { createHash } from 'crypto';
|
||||||
|
import ms from 'ms';
|
||||||
|
import { Injectable } from '@nestjs/common';
|
||||||
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
|
import { HttpRequestService } from '@/core/HttpRequestService.js';
|
||||||
|
import { ApiError } from '../error.js';
|
||||||
|
|
||||||
|
export const meta = {
|
||||||
|
tags: ['meta'],
|
||||||
|
|
||||||
|
requireCredential: true,
|
||||||
|
|
||||||
|
limit: {
|
||||||
|
duration: ms('1hour'),
|
||||||
|
max: 50,
|
||||||
|
},
|
||||||
|
|
||||||
|
errors: {
|
||||||
|
invalidSchema: {
|
||||||
|
message: 'External resource returned invalid schema.',
|
||||||
|
code: 'EXT_RESOURCE_RETURNED_INVALID_SCHEMA',
|
||||||
|
id: 'bb774091-7a15-4a70-9dc5-6ac8cf125856',
|
||||||
|
},
|
||||||
|
hashUnmached: {
|
||||||
|
message: 'Hash did not match.',
|
||||||
|
code: 'EXT_RESOURCE_HASH_DIDNT_MATCH',
|
||||||
|
id: '693ba8ba-b486-40df-a174-72f8279b56a4',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const paramDef = {
|
||||||
|
type: 'object',
|
||||||
|
properties: {
|
||||||
|
url: { type: 'string' },
|
||||||
|
hash: { type: 'string' },
|
||||||
|
},
|
||||||
|
required: ['url', 'hash'],
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
@Injectable()
|
||||||
|
export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-disable-line import/no-default-export
|
||||||
|
constructor(
|
||||||
|
private httpRequestService: HttpRequestService,
|
||||||
|
) {
|
||||||
|
super(meta, paramDef, async (ps) => {
|
||||||
|
const res = await this.httpRequestService.getJson<{
|
||||||
|
type: string;
|
||||||
|
data: string;
|
||||||
|
}>(ps.url);
|
||||||
|
|
||||||
|
if (!res.data || !res.type) {
|
||||||
|
throw new ApiError(meta.errors.invalidSchema);
|
||||||
|
}
|
||||||
|
|
||||||
|
const resHash = createHash('sha512').update(res.data.replace(/\r\n/g, '\n')).digest('hex');
|
||||||
|
if (resHash !== ps.hash) {
|
||||||
|
throw new ApiError(meta.errors.hashUnmached);
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
type: res.type,
|
||||||
|
data: res.data,
|
||||||
|
};
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
@@ -0,0 +1,54 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
import ms from 'ms';
|
||||||
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
|
import type { FollowingsRepository } from '@/models/_.js';
|
||||||
|
import { UserEntityService } from '@/core/entities/UserEntityService.js';
|
||||||
|
import { UserFollowingService } from '@/core/UserFollowingService.js';
|
||||||
|
import { DI } from '@/di-symbols.js';
|
||||||
|
import { GetterService } from '@/server/api/GetterService.js';
|
||||||
|
import { ApiError } from '../../error.js';
|
||||||
|
|
||||||
|
export const meta = {
|
||||||
|
tags: ['following', 'users'],
|
||||||
|
|
||||||
|
limit: {
|
||||||
|
duration: ms('1hour'),
|
||||||
|
max: 10,
|
||||||
|
},
|
||||||
|
|
||||||
|
requireCredential: true,
|
||||||
|
|
||||||
|
kind: 'write:following',
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const paramDef = {
|
||||||
|
type: 'object',
|
||||||
|
properties: {
|
||||||
|
notify: { type: 'string', enum: ['normal', 'none'] },
|
||||||
|
withReplies: { type: 'boolean' },
|
||||||
|
},
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
@Injectable()
|
||||||
|
export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-disable-line import/no-default-export
|
||||||
|
constructor(
|
||||||
|
@Inject(DI.followingsRepository)
|
||||||
|
private followingsRepository: FollowingsRepository,
|
||||||
|
) {
|
||||||
|
super(meta, paramDef, async (ps, me) => {
|
||||||
|
await this.followingsRepository.update({
|
||||||
|
followerId: me.id,
|
||||||
|
}, {
|
||||||
|
notify: ps.notify != null ? (ps.notify === 'none' ? null : ps.notify) : undefined,
|
||||||
|
withReplies: ps.withReplies != null ? ps.withReplies : undefined,
|
||||||
|
});
|
||||||
|
|
||||||
|
return;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
@@ -0,0 +1,82 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { IsNull } from 'typeorm';
|
||||||
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
|
import { DI } from '@/di-symbols.js';
|
||||||
|
import { AvatarDecorationService } from '@/core/AvatarDecorationService.js';
|
||||||
|
import { RoleService } from '@/core/RoleService.js';
|
||||||
|
|
||||||
|
export const meta = {
|
||||||
|
tags: ['users'],
|
||||||
|
|
||||||
|
requireCredential: false,
|
||||||
|
|
||||||
|
res: {
|
||||||
|
type: 'array',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
items: {
|
||||||
|
type: 'object',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
properties: {
|
||||||
|
id: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
format: 'id',
|
||||||
|
example: 'xxxxxxxxxx',
|
||||||
|
},
|
||||||
|
name: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
},
|
||||||
|
description: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
},
|
||||||
|
url: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
},
|
||||||
|
roleIdsThatCanBeUsedThisDecoration: {
|
||||||
|
type: 'array',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
items: {
|
||||||
|
type: 'string',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
format: 'id',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const paramDef = {
|
||||||
|
type: 'object',
|
||||||
|
properties: {},
|
||||||
|
required: [],
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
@Injectable()
|
||||||
|
export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-disable-line import/no-default-export
|
||||||
|
constructor(
|
||||||
|
private avatarDecorationService: AvatarDecorationService,
|
||||||
|
private roleService: RoleService,
|
||||||
|
) {
|
||||||
|
super(meta, paramDef, async (ps, me) => {
|
||||||
|
const decorations = await this.avatarDecorationService.getAll(true);
|
||||||
|
const allRoles = await this.roleService.getRoles();
|
||||||
|
|
||||||
|
return decorations.map(decoration => ({
|
||||||
|
id: decoration.id,
|
||||||
|
name: decoration.name,
|
||||||
|
description: decoration.description,
|
||||||
|
url: decoration.url,
|
||||||
|
roleIdsThatCanBeUsedThisDecoration: decoration.roleIdsThatCanBeUsedThisDecoration.filter(roleId => allRoles.some(role => role.id === roleId)),
|
||||||
|
}));
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
@@ -0,0 +1,178 @@
|
|||||||
|
/*
|
||||||
|
* SPDX-FileCopyrightText: syuilo and other misskey contributors
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { Brackets, In } from 'typeorm';
|
||||||
|
import * as Redis from 'ioredis';
|
||||||
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
|
import type { NotesRepository } from '@/models/_.js';
|
||||||
|
import { obsoleteNotificationTypes, notificationTypes, FilterUnionByProperty } from '@/types.js';
|
||||||
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
|
import { NoteReadService } from '@/core/NoteReadService.js';
|
||||||
|
import { NotificationEntityService } from '@/core/entities/NotificationEntityService.js';
|
||||||
|
import { NotificationService } from '@/core/NotificationService.js';
|
||||||
|
import { DI } from '@/di-symbols.js';
|
||||||
|
import { IdService } from '@/core/IdService.js';
|
||||||
|
import { MiGroupedNotification, MiNotification } from '@/models/Notification.js';
|
||||||
|
|
||||||
|
export const meta = {
|
||||||
|
tags: ['account', 'notifications'],
|
||||||
|
|
||||||
|
requireCredential: true,
|
||||||
|
|
||||||
|
limit: {
|
||||||
|
duration: 30000,
|
||||||
|
max: 30,
|
||||||
|
},
|
||||||
|
|
||||||
|
kind: 'read:notifications',
|
||||||
|
|
||||||
|
res: {
|
||||||
|
type: 'array',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
items: {
|
||||||
|
type: 'object',
|
||||||
|
optional: false, nullable: false,
|
||||||
|
ref: 'Notification',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
export const paramDef = {
|
||||||
|
type: 'object',
|
||||||
|
properties: {
|
||||||
|
limit: { type: 'integer', minimum: 1, maximum: 100, default: 10 },
|
||||||
|
sinceId: { type: 'string', format: 'misskey:id' },
|
||||||
|
untilId: { type: 'string', format: 'misskey:id' },
|
||||||
|
markAsRead: { type: 'boolean', default: true },
|
||||||
|
// 後方互換のため、廃止された通知タイプも受け付ける
|
||||||
|
includeTypes: { type: 'array', items: {
|
||||||
|
type: 'string', enum: [...notificationTypes, ...obsoleteNotificationTypes],
|
||||||
|
} },
|
||||||
|
excludeTypes: { type: 'array', items: {
|
||||||
|
type: 'string', enum: [...notificationTypes, ...obsoleteNotificationTypes],
|
||||||
|
} },
|
||||||
|
},
|
||||||
|
required: [],
|
||||||
|
} as const;
|
||||||
|
|
||||||
|
@Injectable()
|
||||||
|
export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-disable-line import/no-default-export
|
||||||
|
constructor(
|
||||||
|
@Inject(DI.redis)
|
||||||
|
private redisClient: Redis.Redis,
|
||||||
|
|
||||||
|
@Inject(DI.notesRepository)
|
||||||
|
private notesRepository: NotesRepository,
|
||||||
|
|
||||||
|
private idService: IdService,
|
||||||
|
private notificationEntityService: NotificationEntityService,
|
||||||
|
private notificationService: NotificationService,
|
||||||
|
private noteReadService: NoteReadService,
|
||||||
|
) {
|
||||||
|
super(meta, paramDef, async (ps, me) => {
|
||||||
|
const EXTRA_LIMIT = 100;
|
||||||
|
|
||||||
|
// includeTypes が空の場合はクエリしない
|
||||||
|
if (ps.includeTypes && ps.includeTypes.length === 0) {
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
// excludeTypes に全指定されている場合はクエリしない
|
||||||
|
if (notificationTypes.every(type => ps.excludeTypes?.includes(type))) {
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
|
||||||
|
const includeTypes = ps.includeTypes && ps.includeTypes.filter(type => !(obsoleteNotificationTypes).includes(type as any)) as typeof notificationTypes[number][];
|
||||||
|
const excludeTypes = ps.excludeTypes && ps.excludeTypes.filter(type => !(obsoleteNotificationTypes).includes(type as any)) as typeof notificationTypes[number][];
|
||||||
|
|
||||||
|
const limit = (ps.limit + EXTRA_LIMIT) + (ps.untilId ? 1 : 0) + (ps.sinceId ? 1 : 0); // untilIdに指定したものも含まれるため+1
|
||||||
|
const notificationsRes = await this.redisClient.xrevrange(
|
||||||
|
`notificationTimeline:${me.id}`,
|
||||||
|
ps.untilId ? this.idService.parse(ps.untilId).date.getTime() : '+',
|
||||||
|
ps.sinceId ? this.idService.parse(ps.sinceId).date.getTime() : '-',
|
||||||
|
'COUNT', limit);
|
||||||
|
|
||||||
|
if (notificationsRes.length === 0) {
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
|
||||||
|
let notifications = notificationsRes.map(x => JSON.parse(x[1][1])).filter(x => x.id !== ps.untilId && x !== ps.sinceId) as MiNotification[];
|
||||||
|
|
||||||
|
if (includeTypes && includeTypes.length > 0) {
|
||||||
|
notifications = notifications.filter(notification => includeTypes.includes(notification.type));
|
||||||
|
} else if (excludeTypes && excludeTypes.length > 0) {
|
||||||
|
notifications = notifications.filter(notification => !excludeTypes.includes(notification.type));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (notifications.length === 0) {
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
|
||||||
|
// Mark all as read
|
||||||
|
if (ps.markAsRead) {
|
||||||
|
this.notificationService.readAllNotification(me.id);
|
||||||
|
}
|
||||||
|
|
||||||
|
// grouping
|
||||||
|
let groupedNotifications = [notifications[0]] as MiGroupedNotification[];
|
||||||
|
for (let i = 1; i < notifications.length; i++) {
|
||||||
|
const notification = notifications[i];
|
||||||
|
const prev = notifications[i - 1];
|
||||||
|
let prevGroupedNotification = groupedNotifications.at(-1)!;
|
||||||
|
|
||||||
|
if (prev.type === 'reaction' && notification.type === 'reaction' && prev.noteId === notification.noteId) {
|
||||||
|
if (prevGroupedNotification.type !== 'reaction:grouped') {
|
||||||
|
groupedNotifications[groupedNotifications.length - 1] = {
|
||||||
|
type: 'reaction:grouped',
|
||||||
|
id: '',
|
||||||
|
createdAt: prev.createdAt,
|
||||||
|
noteId: prev.noteId!,
|
||||||
|
reactions: [{
|
||||||
|
userId: prev.notifierId!,
|
||||||
|
reaction: prev.reaction!,
|
||||||
|
}],
|
||||||
|
};
|
||||||
|
prevGroupedNotification = groupedNotifications.at(-1)!;
|
||||||
|
}
|
||||||
|
(prevGroupedNotification as FilterUnionByProperty<MiGroupedNotification, 'type', 'reaction:grouped'>).reactions.push({
|
||||||
|
userId: notification.notifierId!,
|
||||||
|
reaction: notification.reaction!,
|
||||||
|
});
|
||||||
|
prevGroupedNotification.id = notification.id;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
if (prev.type === 'renote' && notification.type === 'renote' && prev.targetNoteId === notification.targetNoteId) {
|
||||||
|
if (prevGroupedNotification.type !== 'renote:grouped') {
|
||||||
|
groupedNotifications[groupedNotifications.length - 1] = {
|
||||||
|
type: 'renote:grouped',
|
||||||
|
id: '',
|
||||||
|
createdAt: notification.createdAt,
|
||||||
|
noteId: prev.noteId!,
|
||||||
|
userIds: [prev.notifierId!],
|
||||||
|
};
|
||||||
|
prevGroupedNotification = groupedNotifications.at(-1)!;
|
||||||
|
}
|
||||||
|
(prevGroupedNotification as FilterUnionByProperty<MiGroupedNotification, 'type', 'renote:grouped'>).userIds.push(notification.notifierId!);
|
||||||
|
prevGroupedNotification.id = notification.id;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
groupedNotifications.push(notification);
|
||||||
|
}
|
||||||
|
|
||||||
|
groupedNotifications = groupedNotifications.slice(0, ps.limit);
|
||||||
|
|
||||||
|
const noteIds = groupedNotifications
|
||||||
|
.filter((notification): notification is FilterUnionByProperty<MiNotification, 'type', 'mention' | 'reply' | 'quote'> => ['mention', 'reply', 'quote'].includes(notification.type))
|
||||||
|
.map(notification => notification.noteId!);
|
||||||
|
|
||||||
|
if (noteIds.length > 0) {
|
||||||
|
const notes = await this.notesRepository.findBy({ id: In(noteIds) });
|
||||||
|
this.noteReadService.read(me.id, notes);
|
||||||
|
}
|
||||||
|
|
||||||
|
return await this.notificationEntityService.packGroupedMany(groupedNotifications, me.id);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
@@ -7,7 +7,7 @@ import { Brackets, In } from 'typeorm';
|
|||||||
import * as Redis from 'ioredis';
|
import * as Redis from 'ioredis';
|
||||||
import { Inject, Injectable } from '@nestjs/common';
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
import type { NotesRepository } from '@/models/_.js';
|
import type { NotesRepository } from '@/models/_.js';
|
||||||
import { obsoleteNotificationTypes, notificationTypes } from '@/types.js';
|
import { obsoleteNotificationTypes, notificationTypes, FilterUnionByProperty } from '@/types.js';
|
||||||
import { Endpoint } from '@/server/api/endpoint-base.js';
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
import { NoteReadService } from '@/core/NoteReadService.js';
|
import { NoteReadService } from '@/core/NoteReadService.js';
|
||||||
import { NotificationEntityService } from '@/core/entities/NotificationEntityService.js';
|
import { NotificationEntityService } from '@/core/entities/NotificationEntityService.js';
|
||||||
@@ -113,8 +113,8 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
}
|
}
|
||||||
|
|
||||||
const noteIds = notifications
|
const noteIds = notifications
|
||||||
.filter(notification => ['mention', 'reply', 'quote'].includes(notification.type))
|
.filter((notification): notification is FilterUnionByProperty<MiNotification, 'type', 'mention' | 'reply' | 'quote'> => ['mention', 'reply', 'quote'].includes(notification.type))
|
||||||
.map(notification => notification.noteId!);
|
.map(notification => notification.noteId);
|
||||||
|
|
||||||
if (noteIds.length > 0) {
|
if (noteIds.length > 0) {
|
||||||
const notes = await this.notesRepository.findBy({ id: In(noteIds) });
|
const notes = await this.notesRepository.findBy({ id: In(noteIds) });
|
||||||
|
@@ -18,8 +18,12 @@ export const paramDef = {
|
|||||||
type: 'object',
|
type: 'object',
|
||||||
properties: {
|
properties: {
|
||||||
tokenId: { type: 'string', format: 'misskey:id' },
|
tokenId: { type: 'string', format: 'misskey:id' },
|
||||||
|
token: { type: 'string' },
|
||||||
},
|
},
|
||||||
required: ['tokenId'],
|
anyOf: [
|
||||||
|
{ required: ['tokenId'] },
|
||||||
|
{ required: ['token'] },
|
||||||
|
],
|
||||||
} as const;
|
} as const;
|
||||||
|
|
||||||
@Injectable()
|
@Injectable()
|
||||||
@@ -29,6 +33,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
private accessTokensRepository: AccessTokensRepository,
|
private accessTokensRepository: AccessTokensRepository,
|
||||||
) {
|
) {
|
||||||
super(meta, paramDef, async (ps, me) => {
|
super(meta, paramDef, async (ps, me) => {
|
||||||
|
if (ps.tokenId) {
|
||||||
const tokenExist = await this.accessTokensRepository.exist({ where: { id: ps.tokenId } });
|
const tokenExist = await this.accessTokensRepository.exist({ where: { id: ps.tokenId } });
|
||||||
|
|
||||||
if (tokenExist) {
|
if (tokenExist) {
|
||||||
@@ -37,6 +42,16 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
userId: me.id,
|
userId: me.id,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
} else if (ps.token) {
|
||||||
|
const tokenExist = await this.accessTokensRepository.exist({ where: { token: ps.token } });
|
||||||
|
|
||||||
|
if (tokenExist) {
|
||||||
|
await this.accessTokensRepository.delete({
|
||||||
|
token: ps.token,
|
||||||
|
userId: me.id,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -32,6 +32,7 @@ import { DriveFileEntityService } from '@/core/entities/DriveFileEntityService.j
|
|||||||
import { HttpRequestService } from '@/core/HttpRequestService.js';
|
import { HttpRequestService } from '@/core/HttpRequestService.js';
|
||||||
import type { Config } from '@/config.js';
|
import type { Config } from '@/config.js';
|
||||||
import { safeForSql } from '@/misc/safe-for-sql.js';
|
import { safeForSql } from '@/misc/safe-for-sql.js';
|
||||||
|
import { AvatarDecorationService } from '@/core/AvatarDecorationService.js';
|
||||||
import { ApiLoggerService } from '../../ApiLoggerService.js';
|
import { ApiLoggerService } from '../../ApiLoggerService.js';
|
||||||
import { ApiError } from '../../error.js';
|
import { ApiError } from '../../error.js';
|
||||||
|
|
||||||
@@ -44,7 +45,7 @@ export const meta = {
|
|||||||
|
|
||||||
limit: {
|
limit: {
|
||||||
duration: ms('1hour'),
|
duration: ms('1hour'),
|
||||||
max: 10,
|
max: 20,
|
||||||
},
|
},
|
||||||
|
|
||||||
errors: {
|
errors: {
|
||||||
@@ -131,6 +132,15 @@ export const paramDef = {
|
|||||||
birthday: { ...birthdaySchema, nullable: true },
|
birthday: { ...birthdaySchema, nullable: true },
|
||||||
lang: { type: 'string', enum: [null, ...Object.keys(langmap)] as string[], nullable: true },
|
lang: { type: 'string', enum: [null, ...Object.keys(langmap)] as string[], nullable: true },
|
||||||
avatarId: { type: 'string', format: 'misskey:id', nullable: true },
|
avatarId: { type: 'string', format: 'misskey:id', nullable: true },
|
||||||
|
avatarDecorations: { type: 'array', maxItems: 1, items: {
|
||||||
|
type: 'object',
|
||||||
|
properties: {
|
||||||
|
id: { type: 'string', format: 'misskey:id' },
|
||||||
|
angle: { type: 'number', nullable: true, maximum: 0.5, minimum: -0.5 },
|
||||||
|
flipH: { type: 'boolean', nullable: true },
|
||||||
|
},
|
||||||
|
required: ['id'],
|
||||||
|
} },
|
||||||
bannerId: { type: 'string', format: 'misskey:id', nullable: true },
|
bannerId: { type: 'string', format: 'misskey:id', nullable: true },
|
||||||
fields: {
|
fields: {
|
||||||
type: 'array',
|
type: 'array',
|
||||||
@@ -207,6 +217,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
private roleService: RoleService,
|
private roleService: RoleService,
|
||||||
private cacheService: CacheService,
|
private cacheService: CacheService,
|
||||||
private httpRequestService: HttpRequestService,
|
private httpRequestService: HttpRequestService,
|
||||||
|
private avatarDecorationService: AvatarDecorationService,
|
||||||
) {
|
) {
|
||||||
super(meta, paramDef, async (ps, _user, token) => {
|
super(meta, paramDef, async (ps, _user, token) => {
|
||||||
const user = await this.usersRepository.findOneByOrFail({ id: _user.id }) as MiLocalUser;
|
const user = await this.usersRepository.findOneByOrFail({ id: _user.id }) as MiLocalUser;
|
||||||
@@ -296,6 +307,21 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
updates.bannerBlurhash = null;
|
updates.bannerBlurhash = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (ps.avatarDecorations) {
|
||||||
|
const decorations = await this.avatarDecorationService.getAll(true);
|
||||||
|
const myRoles = await this.roleService.getUserRoles(user.id);
|
||||||
|
const allRoles = await this.roleService.getRoles();
|
||||||
|
const decorationIds = decorations
|
||||||
|
.filter(d => d.roleIdsThatCanBeUsedThisDecoration.filter(roleId => allRoles.some(r => r.id === roleId)).length === 0 || myRoles.some(r => d.roleIdsThatCanBeUsedThisDecoration.includes(r.id)))
|
||||||
|
.map(d => d.id);
|
||||||
|
|
||||||
|
updates.avatarDecorations = ps.avatarDecorations.filter(d => decorationIds.includes(d.id)).map(d => ({
|
||||||
|
id: d.id,
|
||||||
|
angle: d.angle ?? 0,
|
||||||
|
flipH: d.flipH ?? false,
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
|
||||||
if (ps.pinnedPageId) {
|
if (ps.pinnedPageId) {
|
||||||
const page = await this.pagesRepository.findOneBy({ id: ps.pinnedPageId });
|
const page = await this.pagesRepository.findOneBy({ id: ps.pinnedPageId });
|
||||||
|
|
||||||
@@ -421,9 +447,13 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
|
|
||||||
const myLink = `${this.config.url}/@${user.username}`;
|
const myLink = `${this.config.url}/@${user.username}`;
|
||||||
|
|
||||||
const includesMyLink = Array.from(doc.getElementsByTagName('a')).some(a => a.href === myLink);
|
const aEls = Array.from(doc.getElementsByTagName('a'));
|
||||||
|
const linkEls = Array.from(doc.getElementsByTagName('link'));
|
||||||
|
|
||||||
if (includesMyLink) {
|
const includesMyLink = aEls.some(a => a.href === myLink);
|
||||||
|
const includesRelMeLinks = [...aEls, ...linkEls].some(link => link.rel === 'me' && link.href === myLink);
|
||||||
|
|
||||||
|
if (includesMyLink || includesRelMeLinks) {
|
||||||
await this.userProfilesRepository.createQueryBuilder('profile').update()
|
await this.userProfilesRepository.createQueryBuilder('profile').update()
|
||||||
.where('userId = :userId', { userId: user.id })
|
.where('userId = :userId', { userId: user.id })
|
||||||
.set({
|
.set({
|
||||||
|
@@ -17,6 +17,7 @@ import { NoteEntityService } from '@/core/entities/NoteEntityService.js';
|
|||||||
import { NoteCreateService } from '@/core/NoteCreateService.js';
|
import { NoteCreateService } from '@/core/NoteCreateService.js';
|
||||||
import { DI } from '@/di-symbols.js';
|
import { DI } from '@/di-symbols.js';
|
||||||
import { ApiError } from '../../error.js';
|
import { ApiError } from '../../error.js';
|
||||||
|
import { isPureRenote } from '@/misc/is-pure-renote.js';
|
||||||
|
|
||||||
export const meta = {
|
export const meta = {
|
||||||
tags: ['notes'],
|
tags: ['notes'],
|
||||||
@@ -221,7 +222,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
|
|
||||||
if (renote == null) {
|
if (renote == null) {
|
||||||
throw new ApiError(meta.errors.noSuchRenoteTarget);
|
throw new ApiError(meta.errors.noSuchRenoteTarget);
|
||||||
} else if (renote.renoteId && !renote.text && !renote.fileIds && !renote.hasPoll) {
|
} else if (isPureRenote(renote)) {
|
||||||
throw new ApiError(meta.errors.cannotReRenote);
|
throw new ApiError(meta.errors.cannotReRenote);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -254,7 +255,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
|
|
||||||
if (reply == null) {
|
if (reply == null) {
|
||||||
throw new ApiError(meta.errors.noSuchReplyTarget);
|
throw new ApiError(meta.errors.noSuchReplyTarget);
|
||||||
} else if (reply.renoteId && !reply.text && !reply.fileIds && !reply.hasPoll) {
|
} else if (isPureRenote(reply)) {
|
||||||
throw new ApiError(meta.errors.cannotReplyToPureRenote);
|
throw new ApiError(meta.errors.cannotReplyToPureRenote);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
import { Brackets } from 'typeorm';
|
import { Brackets } from 'typeorm';
|
||||||
import { Inject, Injectable } from '@nestjs/common';
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
import type { NotesRepository, FollowingsRepository, MiNote } from '@/models/_.js';
|
import type { NotesRepository, FollowingsRepository, MiNote, ChannelFollowingsRepository } from '@/models/_.js';
|
||||||
import { Endpoint } from '@/server/api/endpoint-base.js';
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
import ActiveUsersChart from '@/core/chart/charts/active-users.js';
|
import ActiveUsersChart from '@/core/chart/charts/active-users.js';
|
||||||
import { NoteEntityService } from '@/core/entities/NoteEntityService.js';
|
import { NoteEntityService } from '@/core/entities/NoteEntityService.js';
|
||||||
@@ -17,6 +17,8 @@ import { CacheService } from '@/core/CacheService.js';
|
|||||||
import { FunoutTimelineService } from '@/core/FunoutTimelineService.js';
|
import { FunoutTimelineService } from '@/core/FunoutTimelineService.js';
|
||||||
import { QueryService } from '@/core/QueryService.js';
|
import { QueryService } from '@/core/QueryService.js';
|
||||||
import { UserFollowingService } from '@/core/UserFollowingService.js';
|
import { UserFollowingService } from '@/core/UserFollowingService.js';
|
||||||
|
import { MetaService } from '@/core/MetaService.js';
|
||||||
|
import { MiLocalUser } from '@/models/User.js';
|
||||||
import { ApiError } from '../../error.js';
|
import { ApiError } from '../../error.js';
|
||||||
|
|
||||||
export const meta = {
|
export const meta = {
|
||||||
@@ -67,6 +69,9 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
@Inject(DI.notesRepository)
|
@Inject(DI.notesRepository)
|
||||||
private notesRepository: NotesRepository,
|
private notesRepository: NotesRepository,
|
||||||
|
|
||||||
|
@Inject(DI.channelFollowingsRepository)
|
||||||
|
private channelFollowingsRepository: ChannelFollowingsRepository,
|
||||||
|
|
||||||
private noteEntityService: NoteEntityService,
|
private noteEntityService: NoteEntityService,
|
||||||
private roleService: RoleService,
|
private roleService: RoleService,
|
||||||
private activeUsersChart: ActiveUsersChart,
|
private activeUsersChart: ActiveUsersChart,
|
||||||
@@ -75,6 +80,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
private funoutTimelineService: FunoutTimelineService,
|
private funoutTimelineService: FunoutTimelineService,
|
||||||
private queryService: QueryService,
|
private queryService: QueryService,
|
||||||
private userFollowingService: UserFollowingService,
|
private userFollowingService: UserFollowingService,
|
||||||
|
private metaService: MetaService,
|
||||||
) {
|
) {
|
||||||
super(meta, paramDef, async (ps, me) => {
|
super(meta, paramDef, async (ps, me) => {
|
||||||
const untilId = ps.untilId ?? (ps.untilDate ? this.idService.gen(ps.untilDate!) : null);
|
const untilId = ps.untilId ?? (ps.untilDate ? this.idService.gen(ps.untilDate!) : null);
|
||||||
@@ -85,6 +91,9 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
throw new ApiError(meta.errors.stlDisabled);
|
throw new ApiError(meta.errors.stlDisabled);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const serverSettings = await this.metaService.fetch();
|
||||||
|
|
||||||
|
if (serverSettings.enableFanoutTimeline) {
|
||||||
const [
|
const [
|
||||||
userIdsWhoMeMuting,
|
userIdsWhoMeMuting,
|
||||||
userIdsWhoMeMutingRenotes,
|
userIdsWhoMeMutingRenotes,
|
||||||
@@ -125,6 +134,8 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
|
|
||||||
shouldFallbackToDb = shouldFallbackToDb || (noteIds.length === 0);
|
shouldFallbackToDb = shouldFallbackToDb || (noteIds.length === 0);
|
||||||
|
|
||||||
|
let redisTimeline: MiNote[] = [];
|
||||||
|
|
||||||
if (!shouldFallbackToDb) {
|
if (!shouldFallbackToDb) {
|
||||||
const query = this.notesRepository.createQueryBuilder('note')
|
const query = this.notesRepository.createQueryBuilder('note')
|
||||||
.where('note.id IN (:...noteIds)', { noteIds: noteIds })
|
.where('note.id IN (:...noteIds)', { noteIds: noteIds })
|
||||||
@@ -135,9 +146,9 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
.leftJoinAndSelect('renote.user', 'renoteUser')
|
.leftJoinAndSelect('renote.user', 'renoteUser')
|
||||||
.leftJoinAndSelect('note.channel', 'channel');
|
.leftJoinAndSelect('note.channel', 'channel');
|
||||||
|
|
||||||
let timeline = await query.getMany();
|
redisTimeline = await query.getMany();
|
||||||
|
|
||||||
timeline = timeline.filter(note => {
|
redisTimeline = redisTimeline.filter(note => {
|
||||||
if (note.userId === me.id) {
|
if (note.userId === me.id) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@@ -153,19 +164,60 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
return true;
|
return true;
|
||||||
});
|
});
|
||||||
|
|
||||||
// TODO: フィルタした結果件数が足りなかった場合の対応
|
redisTimeline.sort((a, b) => a.id > b.id ? -1 : 1);
|
||||||
|
}
|
||||||
timeline.sort((a, b) => a.id > b.id ? -1 : 1);
|
|
||||||
|
|
||||||
|
if (redisTimeline.length > 0) {
|
||||||
process.nextTick(() => {
|
process.nextTick(() => {
|
||||||
this.activeUsersChart.read(me);
|
this.activeUsersChart.read(me);
|
||||||
});
|
});
|
||||||
|
|
||||||
return await this.noteEntityService.packMany(timeline, me);
|
return await this.noteEntityService.packMany(redisTimeline, me);
|
||||||
} else { // fallback to db
|
} else { // fallback to db
|
||||||
const followees = await this.userFollowingService.getFollowees(me.id);
|
return await this.getFromDb({
|
||||||
|
untilId,
|
||||||
|
sinceId,
|
||||||
|
limit: ps.limit,
|
||||||
|
includeMyRenotes: ps.includeMyRenotes,
|
||||||
|
includeRenotedMyNotes: ps.includeRenotedMyNotes,
|
||||||
|
includeLocalRenotes: ps.includeLocalRenotes,
|
||||||
|
withFiles: ps.withFiles,
|
||||||
|
withReplies: ps.withReplies,
|
||||||
|
}, me);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
return await this.getFromDb({
|
||||||
|
untilId,
|
||||||
|
sinceId,
|
||||||
|
limit: ps.limit,
|
||||||
|
includeMyRenotes: ps.includeMyRenotes,
|
||||||
|
includeRenotedMyNotes: ps.includeRenotedMyNotes,
|
||||||
|
includeLocalRenotes: ps.includeLocalRenotes,
|
||||||
|
withFiles: ps.withFiles,
|
||||||
|
withReplies: ps.withReplies,
|
||||||
|
}, me);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
const query = this.queryService.makePaginationQuery(this.notesRepository.createQueryBuilder('note'), ps.sinceId, ps.untilId, ps.sinceDate, ps.untilDate)
|
private async getFromDb(ps: {
|
||||||
|
untilId: string | null,
|
||||||
|
sinceId: string | null,
|
||||||
|
limit: number,
|
||||||
|
includeMyRenotes: boolean,
|
||||||
|
includeRenotedMyNotes: boolean,
|
||||||
|
includeLocalRenotes: boolean,
|
||||||
|
withFiles: boolean,
|
||||||
|
withReplies: boolean,
|
||||||
|
}, me: MiLocalUser) {
|
||||||
|
const followees = await this.userFollowingService.getFollowees(me.id);
|
||||||
|
const followingChannels = await this.channelFollowingsRepository.find({
|
||||||
|
where: {
|
||||||
|
followerId: me.id,
|
||||||
|
},
|
||||||
|
});
|
||||||
|
|
||||||
|
const query = this.queryService.makePaginationQuery(this.notesRepository.createQueryBuilder('note'), ps.sinceId, ps.untilId)
|
||||||
.andWhere(new Brackets(qb => {
|
.andWhere(new Brackets(qb => {
|
||||||
if (followees.length > 0) {
|
if (followees.length > 0) {
|
||||||
const meOrFolloweeIds = [me.id, ...followees.map(f => f.followeeId)];
|
const meOrFolloweeIds = [me.id, ...followees.map(f => f.followeeId)];
|
||||||
@@ -182,6 +234,17 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
.leftJoinAndSelect('reply.user', 'replyUser')
|
.leftJoinAndSelect('reply.user', 'replyUser')
|
||||||
.leftJoinAndSelect('renote.user', 'renoteUser');
|
.leftJoinAndSelect('renote.user', 'renoteUser');
|
||||||
|
|
||||||
|
if (followingChannels.length > 0) {
|
||||||
|
const followingChannelIds = followingChannels.map(x => x.followeeId);
|
||||||
|
|
||||||
|
query.andWhere(new Brackets(qb => {
|
||||||
|
qb.where('note.channelId IN (:...followingChannelIds)', { followingChannelIds });
|
||||||
|
qb.orWhere('note.channelId IS NULL');
|
||||||
|
}));
|
||||||
|
} else {
|
||||||
|
query.andWhere('note.channelId IS NULL');
|
||||||
|
}
|
||||||
|
|
||||||
if (!ps.withReplies) {
|
if (!ps.withReplies) {
|
||||||
query.andWhere(new Brackets(qb => {
|
query.andWhere(new Brackets(qb => {
|
||||||
qb
|
qb
|
||||||
@@ -242,6 +305,4 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
|
|
||||||
return await this.noteEntityService.packMany(timeline, me);
|
return await this.noteEntityService.packMany(timeline, me);
|
||||||
}
|
}
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
@@ -16,6 +16,8 @@ import { CacheService } from '@/core/CacheService.js';
|
|||||||
import { isUserRelated } from '@/misc/is-user-related.js';
|
import { isUserRelated } from '@/misc/is-user-related.js';
|
||||||
import { FunoutTimelineService } from '@/core/FunoutTimelineService.js';
|
import { FunoutTimelineService } from '@/core/FunoutTimelineService.js';
|
||||||
import { QueryService } from '@/core/QueryService.js';
|
import { QueryService } from '@/core/QueryService.js';
|
||||||
|
import { MetaService } from '@/core/MetaService.js';
|
||||||
|
import { MiLocalUser } from '@/models/User.js';
|
||||||
import { ApiError } from '../../error.js';
|
import { ApiError } from '../../error.js';
|
||||||
|
|
||||||
export const meta = {
|
export const meta = {
|
||||||
@@ -69,6 +71,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
private cacheService: CacheService,
|
private cacheService: CacheService,
|
||||||
private funoutTimelineService: FunoutTimelineService,
|
private funoutTimelineService: FunoutTimelineService,
|
||||||
private queryService: QueryService,
|
private queryService: QueryService,
|
||||||
|
private metaService: MetaService,
|
||||||
) {
|
) {
|
||||||
super(meta, paramDef, async (ps, me) => {
|
super(meta, paramDef, async (ps, me) => {
|
||||||
const untilId = ps.untilId ?? (ps.untilDate ? this.idService.gen(ps.untilDate!) : null);
|
const untilId = ps.untilId ?? (ps.untilDate ? this.idService.gen(ps.untilDate!) : null);
|
||||||
@@ -79,6 +82,9 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
throw new ApiError(meta.errors.ltlDisabled);
|
throw new ApiError(meta.errors.ltlDisabled);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const serverSettings = await this.metaService.fetch();
|
||||||
|
|
||||||
|
if (serverSettings.enableFanoutTimeline) {
|
||||||
const [
|
const [
|
||||||
userIdsWhoMeMuting,
|
userIdsWhoMeMuting,
|
||||||
userIdsWhoMeMutingRenotes,
|
userIdsWhoMeMutingRenotes,
|
||||||
@@ -104,6 +110,8 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
|
|
||||||
noteIds = noteIds.slice(0, ps.limit);
|
noteIds = noteIds.slice(0, ps.limit);
|
||||||
|
|
||||||
|
let redisTimeline: MiNote[] = [];
|
||||||
|
|
||||||
if (noteIds.length > 0) {
|
if (noteIds.length > 0) {
|
||||||
const query = this.notesRepository.createQueryBuilder('note')
|
const query = this.notesRepository.createQueryBuilder('note')
|
||||||
.where('note.id IN (:...noteIds)', { noteIds: noteIds })
|
.where('note.id IN (:...noteIds)', { noteIds: noteIds })
|
||||||
@@ -114,13 +122,13 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
.leftJoinAndSelect('renote.user', 'renoteUser')
|
.leftJoinAndSelect('renote.user', 'renoteUser')
|
||||||
.leftJoinAndSelect('note.channel', 'channel');
|
.leftJoinAndSelect('note.channel', 'channel');
|
||||||
|
|
||||||
let timeline = await query.getMany();
|
redisTimeline = await query.getMany();
|
||||||
|
|
||||||
timeline = timeline.filter(note => {
|
redisTimeline = redisTimeline.filter(note => {
|
||||||
if (me && (note.userId === me.id)) {
|
if (me && (note.userId === me.id)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
if (!ps.withReplies && note.replyId && (me == null || note.replyUserId !== me.id)) return false;
|
if (!ps.withReplies && note.replyId && note.replyUserId !== note.userId && (me == null || note.replyUserId !== me.id)) return false;
|
||||||
if (me && isUserRelated(note, userIdsWhoBlockingMe)) return false;
|
if (me && isUserRelated(note, userIdsWhoBlockingMe)) return false;
|
||||||
if (me && isUserRelated(note, userIdsWhoMeMuting)) return false;
|
if (me && isUserRelated(note, userIdsWhoMeMuting)) return false;
|
||||||
if (note.renoteId) {
|
if (note.renoteId) {
|
||||||
@@ -133,20 +141,47 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
return true;
|
return true;
|
||||||
});
|
});
|
||||||
|
|
||||||
// TODO: フィルタした結果件数が足りなかった場合の対応
|
redisTimeline.sort((a, b) => a.id > b.id ? -1 : 1);
|
||||||
|
}
|
||||||
timeline.sort((a, b) => a.id > b.id ? -1 : 1);
|
|
||||||
|
|
||||||
|
if (redisTimeline.length > 0) {
|
||||||
process.nextTick(() => {
|
process.nextTick(() => {
|
||||||
if (me) {
|
if (me) {
|
||||||
this.activeUsersChart.read(me);
|
this.activeUsersChart.read(me);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
return await this.noteEntityService.packMany(timeline, me);
|
return await this.noteEntityService.packMany(redisTimeline, me);
|
||||||
} else { // fallback to db
|
} else { // fallback to db
|
||||||
|
return await this.getFromDb({
|
||||||
|
untilId,
|
||||||
|
sinceId,
|
||||||
|
limit: ps.limit,
|
||||||
|
withFiles: ps.withFiles,
|
||||||
|
withReplies: ps.withReplies,
|
||||||
|
}, me);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
return await this.getFromDb({
|
||||||
|
untilId,
|
||||||
|
sinceId,
|
||||||
|
limit: ps.limit,
|
||||||
|
withFiles: ps.withFiles,
|
||||||
|
withReplies: ps.withReplies,
|
||||||
|
}, me);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
private async getFromDb(ps: {
|
||||||
|
sinceId: string | null,
|
||||||
|
untilId: string | null,
|
||||||
|
limit: number,
|
||||||
|
withFiles: boolean,
|
||||||
|
withReplies: boolean,
|
||||||
|
}, me: MiLocalUser | null) {
|
||||||
const query = this.queryService.makePaginationQuery(this.notesRepository.createQueryBuilder('note'),
|
const query = this.queryService.makePaginationQuery(this.notesRepository.createQueryBuilder('note'),
|
||||||
ps.sinceId, ps.untilId, ps.sinceDate, ps.untilDate)
|
ps.sinceId, ps.untilId)
|
||||||
.andWhere('(note.visibility = \'public\') AND (note.userHost IS NULL)')
|
.andWhere('(note.visibility = \'public\') AND (note.userHost IS NULL)')
|
||||||
.innerJoinAndSelect('note.user', 'user')
|
.innerJoinAndSelect('note.user', 'user')
|
||||||
.leftJoinAndSelect('note.reply', 'reply')
|
.leftJoinAndSelect('note.reply', 'reply')
|
||||||
@@ -185,6 +220,4 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
|
|
||||||
return await this.noteEntityService.packMany(timeline, me);
|
return await this.noteEntityService.packMany(timeline, me);
|
||||||
}
|
}
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
import { Brackets } from 'typeorm';
|
import { Brackets } from 'typeorm';
|
||||||
import { Inject, Injectable } from '@nestjs/common';
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
import type { NotesRepository } from '@/models/_.js';
|
import type { MiNote, NotesRepository, ChannelFollowingsRepository } from '@/models/_.js';
|
||||||
import { Endpoint } from '@/server/api/endpoint-base.js';
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
import { QueryService } from '@/core/QueryService.js';
|
import { QueryService } from '@/core/QueryService.js';
|
||||||
import ActiveUsersChart from '@/core/chart/charts/active-users.js';
|
import ActiveUsersChart from '@/core/chart/charts/active-users.js';
|
||||||
@@ -16,6 +16,8 @@ import { CacheService } from '@/core/CacheService.js';
|
|||||||
import { isUserRelated } from '@/misc/is-user-related.js';
|
import { isUserRelated } from '@/misc/is-user-related.js';
|
||||||
import { FunoutTimelineService } from '@/core/FunoutTimelineService.js';
|
import { FunoutTimelineService } from '@/core/FunoutTimelineService.js';
|
||||||
import { UserFollowingService } from '@/core/UserFollowingService.js';
|
import { UserFollowingService } from '@/core/UserFollowingService.js';
|
||||||
|
import { MiLocalUser } from '@/models/User.js';
|
||||||
|
import { MetaService } from '@/core/MetaService.js';
|
||||||
|
|
||||||
export const meta = {
|
export const meta = {
|
||||||
tags: ['notes'],
|
tags: ['notes'],
|
||||||
@@ -56,6 +58,9 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
@Inject(DI.notesRepository)
|
@Inject(DI.notesRepository)
|
||||||
private notesRepository: NotesRepository,
|
private notesRepository: NotesRepository,
|
||||||
|
|
||||||
|
@Inject(DI.channelFollowingsRepository)
|
||||||
|
private channelFollowingsRepository: ChannelFollowingsRepository,
|
||||||
|
|
||||||
private noteEntityService: NoteEntityService,
|
private noteEntityService: NoteEntityService,
|
||||||
private activeUsersChart: ActiveUsersChart,
|
private activeUsersChart: ActiveUsersChart,
|
||||||
private idService: IdService,
|
private idService: IdService,
|
||||||
@@ -63,11 +68,15 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
private funoutTimelineService: FunoutTimelineService,
|
private funoutTimelineService: FunoutTimelineService,
|
||||||
private userFollowingService: UserFollowingService,
|
private userFollowingService: UserFollowingService,
|
||||||
private queryService: QueryService,
|
private queryService: QueryService,
|
||||||
|
private metaService: MetaService,
|
||||||
) {
|
) {
|
||||||
super(meta, paramDef, async (ps, me) => {
|
super(meta, paramDef, async (ps, me) => {
|
||||||
const untilId = ps.untilId ?? (ps.untilDate ? this.idService.gen(ps.untilDate!) : null);
|
const untilId = ps.untilId ?? (ps.untilDate ? this.idService.gen(ps.untilDate!) : null);
|
||||||
const sinceId = ps.sinceId ?? (ps.sinceDate ? this.idService.gen(ps.sinceDate!) : null);
|
const sinceId = ps.sinceId ?? (ps.sinceDate ? this.idService.gen(ps.sinceDate!) : null);
|
||||||
|
|
||||||
|
const serverSettings = await this.metaService.fetch();
|
||||||
|
|
||||||
|
if (serverSettings.enableFanoutTimeline) {
|
||||||
const [
|
const [
|
||||||
followings,
|
followings,
|
||||||
userIdsWhoMeMuting,
|
userIdsWhoMeMuting,
|
||||||
@@ -83,6 +92,8 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
let noteIds = await this.funoutTimelineService.get(ps.withFiles ? `homeTimelineWithFiles:${me.id}` : `homeTimeline:${me.id}`, untilId, sinceId);
|
let noteIds = await this.funoutTimelineService.get(ps.withFiles ? `homeTimelineWithFiles:${me.id}` : `homeTimeline:${me.id}`, untilId, sinceId);
|
||||||
noteIds = noteIds.slice(0, ps.limit);
|
noteIds = noteIds.slice(0, ps.limit);
|
||||||
|
|
||||||
|
let redisTimeline: MiNote[] = [];
|
||||||
|
|
||||||
if (noteIds.length > 0) {
|
if (noteIds.length > 0) {
|
||||||
const query = this.notesRepository.createQueryBuilder('note')
|
const query = this.notesRepository.createQueryBuilder('note')
|
||||||
.where('note.id IN (:...noteIds)', { noteIds: noteIds })
|
.where('note.id IN (:...noteIds)', { noteIds: noteIds })
|
||||||
@@ -93,9 +104,9 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
.leftJoinAndSelect('renote.user', 'renoteUser')
|
.leftJoinAndSelect('renote.user', 'renoteUser')
|
||||||
.leftJoinAndSelect('note.channel', 'channel');
|
.leftJoinAndSelect('note.channel', 'channel');
|
||||||
|
|
||||||
let timeline = await query.getMany();
|
redisTimeline = await query.getMany();
|
||||||
|
|
||||||
timeline = timeline.filter(note => {
|
redisTimeline = redisTimeline.filter(note => {
|
||||||
if (note.userId === me.id) {
|
if (note.userId === me.id) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@@ -114,33 +125,90 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
return true;
|
return true;
|
||||||
});
|
});
|
||||||
|
|
||||||
// TODO: フィルタした結果件数が足りなかった場合の対応
|
redisTimeline.sort((a, b) => a.id > b.id ? -1 : 1);
|
||||||
|
}
|
||||||
timeline.sort((a, b) => a.id > b.id ? -1 : 1);
|
|
||||||
|
|
||||||
|
if (redisTimeline.length > 0) {
|
||||||
process.nextTick(() => {
|
process.nextTick(() => {
|
||||||
this.activeUsersChart.read(me);
|
this.activeUsersChart.read(me);
|
||||||
});
|
});
|
||||||
|
|
||||||
return await this.noteEntityService.packMany(timeline, me);
|
return await this.noteEntityService.packMany(redisTimeline, me);
|
||||||
} else { // fallback to db
|
} else { // fallback to db
|
||||||
|
return await this.getFromDb({
|
||||||
|
untilId,
|
||||||
|
sinceId,
|
||||||
|
limit: ps.limit,
|
||||||
|
includeMyRenotes: ps.includeMyRenotes,
|
||||||
|
includeRenotedMyNotes: ps.includeRenotedMyNotes,
|
||||||
|
includeLocalRenotes: ps.includeLocalRenotes,
|
||||||
|
withFiles: ps.withFiles,
|
||||||
|
withRenotes: ps.withRenotes,
|
||||||
|
}, me);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
return await this.getFromDb({
|
||||||
|
untilId,
|
||||||
|
sinceId,
|
||||||
|
limit: ps.limit,
|
||||||
|
includeMyRenotes: ps.includeMyRenotes,
|
||||||
|
includeRenotedMyNotes: ps.includeRenotedMyNotes,
|
||||||
|
includeLocalRenotes: ps.includeLocalRenotes,
|
||||||
|
withFiles: ps.withFiles,
|
||||||
|
withRenotes: ps.withRenotes,
|
||||||
|
}, me);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
private async getFromDb(ps: { untilId: string | null; sinceId: string | null; limit: number; includeMyRenotes: boolean; includeRenotedMyNotes: boolean; includeLocalRenotes: boolean; withFiles: boolean; withRenotes: boolean; }, me: MiLocalUser) {
|
||||||
const followees = await this.userFollowingService.getFollowees(me.id);
|
const followees = await this.userFollowingService.getFollowees(me.id);
|
||||||
|
const followingChannels = await this.channelFollowingsRepository.find({
|
||||||
|
where: {
|
||||||
|
followerId: me.id,
|
||||||
|
},
|
||||||
|
});
|
||||||
|
|
||||||
//#region Construct query
|
//#region Construct query
|
||||||
const query = this.queryService.makePaginationQuery(this.notesRepository.createQueryBuilder('note'), ps.sinceId, ps.untilId, ps.sinceDate, ps.untilDate)
|
const query = this.queryService.makePaginationQuery(this.notesRepository.createQueryBuilder('note'), ps.sinceId, ps.untilId)
|
||||||
.andWhere('note.channelId IS NULL')
|
|
||||||
.innerJoinAndSelect('note.user', 'user')
|
.innerJoinAndSelect('note.user', 'user')
|
||||||
.leftJoinAndSelect('note.reply', 'reply')
|
.leftJoinAndSelect('note.reply', 'reply')
|
||||||
.leftJoinAndSelect('note.renote', 'renote')
|
.leftJoinAndSelect('note.renote', 'renote')
|
||||||
.leftJoinAndSelect('reply.user', 'replyUser')
|
.leftJoinAndSelect('reply.user', 'replyUser')
|
||||||
.leftJoinAndSelect('renote.user', 'renoteUser');
|
.leftJoinAndSelect('renote.user', 'renoteUser');
|
||||||
|
|
||||||
if (followees.length > 0) {
|
if (followees.length > 0 && followingChannels.length > 0) {
|
||||||
|
// ユーザー・チャンネルともにフォローあり
|
||||||
const meOrFolloweeIds = [me.id, ...followees.map(f => f.followeeId)];
|
const meOrFolloweeIds = [me.id, ...followees.map(f => f.followeeId)];
|
||||||
|
const followingChannelIds = followingChannels.map(x => x.followeeId);
|
||||||
query.andWhere('note.userId IN (:...meOrFolloweeIds)', { meOrFolloweeIds: meOrFolloweeIds });
|
query.andWhere(new Brackets(qb => {
|
||||||
|
qb
|
||||||
|
.where(new Brackets(qb2 => {
|
||||||
|
qb2
|
||||||
|
.where('note.userId IN (:...meOrFolloweeIds)', { meOrFolloweeIds: meOrFolloweeIds })
|
||||||
|
.andWhere('note.channelId IS NULL');
|
||||||
|
}))
|
||||||
|
.orWhere('note.channelId IN (:...followingChannelIds)', { followingChannelIds });
|
||||||
|
}));
|
||||||
|
} else if (followees.length > 0) {
|
||||||
|
// ユーザーフォローのみ(チャンネルフォローなし)
|
||||||
|
const meOrFolloweeIds = [me.id, ...followees.map(f => f.followeeId)];
|
||||||
|
query
|
||||||
|
.andWhere('note.channelId IS NULL')
|
||||||
|
.andWhere('note.userId IN (:...meOrFolloweeIds)', { meOrFolloweeIds: meOrFolloweeIds });
|
||||||
|
} else if (followingChannels.length > 0) {
|
||||||
|
// チャンネルフォローのみ(ユーザーフォローなし)
|
||||||
|
const followingChannelIds = followingChannels.map(x => x.followeeId);
|
||||||
|
query.andWhere(new Brackets(qb => {
|
||||||
|
qb
|
||||||
|
.where('note.channelId IN (:...followingChannelIds)', { followingChannelIds })
|
||||||
|
.orWhere('note.userId = :meId', { meId: me.id });
|
||||||
|
}));
|
||||||
} else {
|
} else {
|
||||||
query.andWhere('note.userId = :meId', { meId: me.id });
|
// フォローなし
|
||||||
|
query
|
||||||
|
.andWhere('note.channelId IS NULL')
|
||||||
|
.andWhere('note.userId = :meId', { meId: me.id });
|
||||||
}
|
}
|
||||||
|
|
||||||
query.andWhere(new Brackets(qb => {
|
query.andWhere(new Brackets(qb => {
|
||||||
@@ -191,6 +259,10 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
if (ps.withFiles) {
|
if (ps.withFiles) {
|
||||||
query.andWhere('note.fileIds != \'{}\'');
|
query.andWhere('note.fileIds != \'{}\'');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (ps.withRenotes === false) {
|
||||||
|
query.andWhere('note.renoteId IS NULL');
|
||||||
|
}
|
||||||
//#endregion
|
//#endregion
|
||||||
|
|
||||||
const timeline = await query.limit(ps.limit).getMany();
|
const timeline = await query.limit(ps.limit).getMany();
|
||||||
@@ -201,6 +273,4 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
|
|
||||||
return await this.noteEntityService.packMany(timeline, me);
|
return await this.noteEntityService.packMany(timeline, me);
|
||||||
}
|
}
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
@@ -4,7 +4,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
import { Inject, Injectable } from '@nestjs/common';
|
import { Inject, Injectable } from '@nestjs/common';
|
||||||
import type { NotesRepository, UserListsRepository } from '@/models/_.js';
|
import type { MiNote, NotesRepository, UserListMembershipsRepository, UserListsRepository } from '@/models/_.js';
|
||||||
import { Endpoint } from '@/server/api/endpoint-base.js';
|
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||||
import { NoteEntityService } from '@/core/entities/NoteEntityService.js';
|
import { NoteEntityService } from '@/core/entities/NoteEntityService.js';
|
||||||
import ActiveUsersChart from '@/core/chart/charts/active-users.js';
|
import ActiveUsersChart from '@/core/chart/charts/active-users.js';
|
||||||
@@ -13,7 +13,9 @@ import { CacheService } from '@/core/CacheService.js';
|
|||||||
import { IdService } from '@/core/IdService.js';
|
import { IdService } from '@/core/IdService.js';
|
||||||
import { isUserRelated } from '@/misc/is-user-related.js';
|
import { isUserRelated } from '@/misc/is-user-related.js';
|
||||||
import { FunoutTimelineService } from '@/core/FunoutTimelineService.js';
|
import { FunoutTimelineService } from '@/core/FunoutTimelineService.js';
|
||||||
|
import { QueryService } from '@/core/QueryService.js';
|
||||||
import { ApiError } from '../../error.js';
|
import { ApiError } from '../../error.js';
|
||||||
|
import { Brackets } from 'typeorm';
|
||||||
|
|
||||||
export const meta = {
|
export const meta = {
|
||||||
tags: ['notes', 'lists'],
|
tags: ['notes', 'lists'],
|
||||||
@@ -70,11 +72,16 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
@Inject(DI.userListsRepository)
|
@Inject(DI.userListsRepository)
|
||||||
private userListsRepository: UserListsRepository,
|
private userListsRepository: UserListsRepository,
|
||||||
|
|
||||||
|
@Inject(DI.userListMembershipsRepository)
|
||||||
|
private userListMembershipsRepository: UserListMembershipsRepository,
|
||||||
|
|
||||||
private noteEntityService: NoteEntityService,
|
private noteEntityService: NoteEntityService,
|
||||||
private activeUsersChart: ActiveUsersChart,
|
private activeUsersChart: ActiveUsersChart,
|
||||||
private cacheService: CacheService,
|
private cacheService: CacheService,
|
||||||
private idService: IdService,
|
private idService: IdService,
|
||||||
private funoutTimelineService: FunoutTimelineService,
|
private funoutTimelineService: FunoutTimelineService,
|
||||||
|
private queryService: QueryService,
|
||||||
|
|
||||||
) {
|
) {
|
||||||
super(meta, paramDef, async (ps, me) => {
|
super(meta, paramDef, async (ps, me) => {
|
||||||
const untilId = ps.untilId ?? (ps.untilDate ? this.idService.gen(ps.untilDate!) : null);
|
const untilId = ps.untilId ?? (ps.untilDate ? this.idService.gen(ps.untilDate!) : null);
|
||||||
@@ -102,10 +109,9 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
let noteIds = await this.funoutTimelineService.get(ps.withFiles ? `userListTimelineWithFiles:${list.id}` : `userListTimeline:${list.id}`, untilId, sinceId);
|
let noteIds = await this.funoutTimelineService.get(ps.withFiles ? `userListTimelineWithFiles:${list.id}` : `userListTimeline:${list.id}`, untilId, sinceId);
|
||||||
noteIds = noteIds.slice(0, ps.limit);
|
noteIds = noteIds.slice(0, ps.limit);
|
||||||
|
|
||||||
if (noteIds.length === 0) {
|
let redisTimeline: MiNote[] = [];
|
||||||
return [];
|
|
||||||
}
|
|
||||||
|
|
||||||
|
if (noteIds.length > 0) {
|
||||||
const query = this.notesRepository.createQueryBuilder('note')
|
const query = this.notesRepository.createQueryBuilder('note')
|
||||||
.where('note.id IN (:...noteIds)', { noteIds: noteIds })
|
.where('note.id IN (:...noteIds)', { noteIds: noteIds })
|
||||||
.innerJoinAndSelect('note.user', 'user')
|
.innerJoinAndSelect('note.user', 'user')
|
||||||
@@ -115,9 +121,9 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
.leftJoinAndSelect('renote.user', 'renoteUser')
|
.leftJoinAndSelect('renote.user', 'renoteUser')
|
||||||
.leftJoinAndSelect('note.channel', 'channel');
|
.leftJoinAndSelect('note.channel', 'channel');
|
||||||
|
|
||||||
let timeline = await query.getMany();
|
redisTimeline = await query.getMany();
|
||||||
|
|
||||||
timeline = timeline.filter(note => {
|
redisTimeline = redisTimeline.filter(note => {
|
||||||
if (note.userId === me.id) {
|
if (note.userId === me.id) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@@ -133,13 +139,99 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
return true;
|
return true;
|
||||||
});
|
});
|
||||||
|
|
||||||
// TODO: フィルタした結果件数が足りなかった場合の対応
|
redisTimeline.sort((a, b) => a.id > b.id ? -1 : 1);
|
||||||
|
}
|
||||||
|
|
||||||
timeline.sort((a, b) => a.id > b.id ? -1 : 1);
|
if (redisTimeline.length > 0) {
|
||||||
|
this.activeUsersChart.read(me);
|
||||||
|
return await this.noteEntityService.packMany(redisTimeline, me);
|
||||||
|
} else { // fallback to db
|
||||||
|
//#region Construct query
|
||||||
|
const query = this.queryService.makePaginationQuery(this.notesRepository.createQueryBuilder('note'), ps.sinceId, ps.untilId)
|
||||||
|
.innerJoin(this.userListMembershipsRepository.metadata.targetName, 'userListMemberships', 'userListMemberships.userId = note.userId')
|
||||||
|
.innerJoinAndSelect('note.user', 'user')
|
||||||
|
.leftJoinAndSelect('note.reply', 'reply')
|
||||||
|
.leftJoinAndSelect('note.renote', 'renote')
|
||||||
|
.leftJoinAndSelect('reply.user', 'replyUser')
|
||||||
|
.leftJoinAndSelect('renote.user', 'renoteUser')
|
||||||
|
.andWhere('userListMemberships.userListId = :userListId', { userListId: list.id })
|
||||||
|
.andWhere('note.channelId IS NULL') // チャンネルノートではない
|
||||||
|
.andWhere(new Brackets(qb => {
|
||||||
|
qb
|
||||||
|
.where('note.replyId IS NULL') // 返信ではない
|
||||||
|
.orWhere(new Brackets(qb => {
|
||||||
|
qb // 返信だけど投稿者自身への返信
|
||||||
|
.where('note.replyId IS NOT NULL')
|
||||||
|
.andWhere('note.replyUserId = note.userId');
|
||||||
|
}))
|
||||||
|
.orWhere(new Brackets(qb => {
|
||||||
|
qb // 返信だけど自分宛ての返信
|
||||||
|
.where('note.replyId IS NOT NULL')
|
||||||
|
.andWhere('note.replyUserId = :meId', { meId: me.id });
|
||||||
|
}))
|
||||||
|
.orWhere(new Brackets(qb => {
|
||||||
|
qb // 返信だけどwithRepliesがtrueの場合
|
||||||
|
.where('note.replyId IS NOT NULL')
|
||||||
|
.andWhere('userListMemberships.withReplies = true');
|
||||||
|
}));
|
||||||
|
}));
|
||||||
|
|
||||||
|
this.queryService.generateVisibilityQuery(query, me);
|
||||||
|
this.queryService.generateMutedUserQuery(query, me);
|
||||||
|
this.queryService.generateBlockedUserQuery(query, me);
|
||||||
|
this.queryService.generateMutedUserRenotesQueryForNotes(query, me);
|
||||||
|
|
||||||
|
if (ps.includeMyRenotes === false) {
|
||||||
|
query.andWhere(new Brackets(qb => {
|
||||||
|
qb.orWhere('note.userId != :meId', { meId: me.id });
|
||||||
|
qb.orWhere('note.renoteId IS NULL');
|
||||||
|
qb.orWhere('note.text IS NOT NULL');
|
||||||
|
qb.orWhere('note.fileIds != \'{}\'');
|
||||||
|
qb.orWhere('0 < (SELECT COUNT(*) FROM poll WHERE poll."noteId" = note.id)');
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (ps.includeRenotedMyNotes === false) {
|
||||||
|
query.andWhere(new Brackets(qb => {
|
||||||
|
qb.orWhere('note.renoteUserId != :meId', { meId: me.id });
|
||||||
|
qb.orWhere('note.renoteId IS NULL');
|
||||||
|
qb.orWhere('note.text IS NOT NULL');
|
||||||
|
qb.orWhere('note.fileIds != \'{}\'');
|
||||||
|
qb.orWhere('0 < (SELECT COUNT(*) FROM poll WHERE poll."noteId" = note.id)');
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (ps.includeLocalRenotes === false) {
|
||||||
|
query.andWhere(new Brackets(qb => {
|
||||||
|
qb.orWhere('note.renoteUserHost IS NOT NULL');
|
||||||
|
qb.orWhere('note.renoteId IS NULL');
|
||||||
|
qb.orWhere('note.text IS NOT NULL');
|
||||||
|
qb.orWhere('note.fileIds != \'{}\'');
|
||||||
|
qb.orWhere('0 < (SELECT COUNT(*) FROM poll WHERE poll."noteId" = note.id)');
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (ps.withRenotes === false) {
|
||||||
|
query.andWhere(new Brackets(qb => {
|
||||||
|
qb.orWhere('note.renoteId IS NULL');
|
||||||
|
qb.orWhere(new Brackets(qb => {
|
||||||
|
qb.orWhere('note.text IS NOT NULL');
|
||||||
|
qb.orWhere('note.fileIds != \'{}\'');
|
||||||
|
}));
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
|
||||||
|
if (ps.withFiles) {
|
||||||
|
query.andWhere('note.fileIds != \'{}\'');
|
||||||
|
}
|
||||||
|
//#endregion
|
||||||
|
|
||||||
|
const timeline = await query.limit(ps.limit).getMany();
|
||||||
|
|
||||||
this.activeUsersChart.read(me);
|
this.activeUsersChart.read(me);
|
||||||
|
|
||||||
return await this.noteEntityService.packMany(timeline, me);
|
return await this.noteEntityService.packMany(timeline, me);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -42,8 +42,8 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||||||
this.notificationService.createNotification(user.id, 'app', {
|
this.notificationService.createNotification(user.id, 'app', {
|
||||||
appAccessTokenId: token ? token.id : null,
|
appAccessTokenId: token ? token.id : null,
|
||||||
customBody: ps.body,
|
customBody: ps.body,
|
||||||
customHeader: ps.header,
|
customHeader: ps.header ?? token?.name ?? null,
|
||||||
customIcon: ps.icon,
|
customIcon: ps.icon ?? token?.iconUrl ?? null,
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@@ -26,7 +26,12 @@ export function convertSchemaToOpenApiSchema(schema: Schema) {
|
|||||||
if (schema.allOf) res.allOf = schema.allOf.map(convertSchemaToOpenApiSchema);
|
if (schema.allOf) res.allOf = schema.allOf.map(convertSchemaToOpenApiSchema);
|
||||||
|
|
||||||
if (schema.ref) {
|
if (schema.ref) {
|
||||||
res.$ref = `#/components/schemas/${schema.ref}`;
|
const $ref = `#/components/schemas/${schema.ref}`;
|
||||||
|
if (schema.nullable || schema.optional) {
|
||||||
|
res.allOf = [{ $ref }];
|
||||||
|
} else {
|
||||||
|
res.$ref = $ref;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return res;
|
return res;
|
||||||
|
@@ -13,6 +13,7 @@ import { bindThis } from '@/decorators.js';
|
|||||||
import { CacheService } from '@/core/CacheService.js';
|
import { CacheService } from '@/core/CacheService.js';
|
||||||
import { MiFollowing, MiUserProfile } from '@/models/_.js';
|
import { MiFollowing, MiUserProfile } from '@/models/_.js';
|
||||||
import type { StreamEventEmitter, GlobalEvents } from '@/core/GlobalEventService.js';
|
import type { StreamEventEmitter, GlobalEvents } from '@/core/GlobalEventService.js';
|
||||||
|
import { ChannelFollowingService } from '@/core/ChannelFollowingService.js';
|
||||||
import type { ChannelsService } from './ChannelsService.js';
|
import type { ChannelsService } from './ChannelsService.js';
|
||||||
import type { EventEmitter } from 'events';
|
import type { EventEmitter } from 'events';
|
||||||
import type Channel from './channel.js';
|
import type Channel from './channel.js';
|
||||||
@@ -42,6 +43,7 @@ export default class Connection {
|
|||||||
private noteReadService: NoteReadService,
|
private noteReadService: NoteReadService,
|
||||||
private notificationService: NotificationService,
|
private notificationService: NotificationService,
|
||||||
private cacheService: CacheService,
|
private cacheService: CacheService,
|
||||||
|
private channelFollowingService: ChannelFollowingService,
|
||||||
|
|
||||||
user: MiUser | null | undefined,
|
user: MiUser | null | undefined,
|
||||||
token: MiAccessToken | null | undefined,
|
token: MiAccessToken | null | undefined,
|
||||||
@@ -56,7 +58,7 @@ export default class Connection {
|
|||||||
const [userProfile, following, followingChannels, userIdsWhoMeMuting, userIdsWhoBlockingMe, userIdsWhoMeMutingRenotes] = await Promise.all([
|
const [userProfile, following, followingChannels, userIdsWhoMeMuting, userIdsWhoBlockingMe, userIdsWhoMeMutingRenotes] = await Promise.all([
|
||||||
this.cacheService.userProfileCache.fetch(this.user.id),
|
this.cacheService.userProfileCache.fetch(this.user.id),
|
||||||
this.cacheService.userFollowingsCache.fetch(this.user.id),
|
this.cacheService.userFollowingsCache.fetch(this.user.id),
|
||||||
this.cacheService.userFollowingChannelsCache.fetch(this.user.id),
|
this.channelFollowingService.userFollowingChannelsCache.fetch(this.user.id),
|
||||||
this.cacheService.userMutingsCache.fetch(this.user.id),
|
this.cacheService.userMutingsCache.fetch(this.user.id),
|
||||||
this.cacheService.userBlockedCache.fetch(this.user.id),
|
this.cacheService.userBlockedCache.fetch(this.user.id),
|
||||||
this.cacheService.renoteMutingsCache.fetch(this.user.id),
|
this.cacheService.renoteMutingsCache.fetch(this.user.id),
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user