Merge remote-tracking branch 'upstream/develop' into fix/12553
This commit is contained in:
commit
d8f380b7b3
|
@ -23,16 +23,35 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
if: github.event_name == 'issue_comment' && github.event.issue.pull_request && startsWith(github.event.comment.body, '/preview')
|
||||
outputs:
|
||||
is-allowed-user: ${{ steps.check-allowed-users.outputs.is-allowed-user }}
|
||||
pr-ref: ${{ steps.get-ref.outputs.pr-ref }}
|
||||
wait_time: ${{ steps.get-wait-time.outputs.wait_time }}
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Check allowed users
|
||||
id: check-allowed-users
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
ORG_ID: ${{ github.repository_owner_id }}
|
||||
COMMENT_AUTHOR: ${{ github.event.comment.user.login }}
|
||||
run: |
|
||||
MEMBERSHIP_STATUS=$(curl -s -H "Authorization: Bearer $GITHUB_TOKEN" \
|
||||
-H "Accept: application/vnd.github+json" \
|
||||
-H "X-GitHub-Api-Version: 2022-11-28" \
|
||||
"https://api.github.com/organizations/$ORG_ID/public_members/$COMMENT_AUTHOR" \
|
||||
-o /dev/null -w '%{http_code}\n' -s)
|
||||
if [ "$MEMBERSHIP_STATUS" -eq 204 ]; then
|
||||
echo "is-allowed-user=true" > $GITHUB_OUTPUT
|
||||
else
|
||||
echo "is-allowed-user=false" > $GITHUB_OUTPUT
|
||||
fi
|
||||
|
||||
- name: Get PR ref
|
||||
id: get-ref
|
||||
env:
|
||||
GH_TOKEN: ${{ github.token }}
|
||||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
run: |
|
||||
PR_NUMBER=$(jq --raw-output .issue.number $GITHUB_EVENT_PATH)
|
||||
PR_REF=$(gh pr view $PR_NUMBER --json headRefName -q '.headRefName')
|
||||
|
@ -40,13 +59,15 @@ jobs:
|
|||
|
||||
- name: Extract wait time
|
||||
id: get-wait-time
|
||||
env:
|
||||
COMMENT_BODY: ${{ github.event.comment.body }}
|
||||
run: |
|
||||
COMMENT_BODY="${{ github.event.comment.body }}"
|
||||
WAIT_TIME=$(echo "$COMMENT_BODY" | grep -oP '(?<=/preview\s)\d+' || echo "1800")
|
||||
echo "wait_time=$WAIT_TIME" > $GITHUB_OUTPUT
|
||||
|
||||
deploy-test-environment-pr-comment:
|
||||
needs: get-pr-ref
|
||||
if: needs.get-pr-ref.outputs.is-allowed-user == 'true'
|
||||
uses: joinmisskey/misskey-tga/.github/workflows/deploy-test-environment.yml@main
|
||||
with:
|
||||
repository: ${{ github.repository }}
|
||||
|
|
|
@ -6,38 +6,84 @@ on:
|
|||
- develop
|
||||
workflow_dispatch:
|
||||
|
||||
env:
|
||||
REGISTRY_IMAGE: misskey/misskey
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
# see https://docs.docker.com/build/ci/github-actions/multi-platform/#distribute-build-across-multiple-runners
|
||||
build:
|
||||
name: Build
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
platform:
|
||||
- linux/amd64
|
||||
- linux/arm64
|
||||
if: github.repository == 'misskey-dev/misskey'
|
||||
steps:
|
||||
- name: Prepare
|
||||
run: |
|
||||
platform=${{ matrix.platform }}
|
||||
echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4.1.1
|
||||
- name: Set up Docker Buildx
|
||||
id: buildx
|
||||
uses: docker/setup-buildx-action@v3.0.0
|
||||
with:
|
||||
platforms: linux/amd64,linux/arm64
|
||||
- name: Docker meta
|
||||
id: meta
|
||||
uses: docker/metadata-action@v5
|
||||
with:
|
||||
images: misskey/misskey
|
||||
uses: docker/setup-buildx-action@v3
|
||||
- name: Log in to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
- name: Build and Push to Docker Hub
|
||||
- name: Build and push by digest
|
||||
id: build
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
builder: ${{ steps.buildx.outputs.name }}
|
||||
context: .
|
||||
push: true
|
||||
platforms: ${{ steps.buildx.outputs.platforms }}
|
||||
platforms: ${{ matrix.platform }}
|
||||
provenance: false
|
||||
tags: misskey/misskey:develop
|
||||
tags: ${{ env.REGISTRY_IMAGE }}:develop
|
||||
labels: develop
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
outputs: type=image,name=${{ env.REGISTRY_IMAGE }},push-by-digest=true,name-canonical=true,push=true
|
||||
- name: Export digest
|
||||
run: |
|
||||
mkdir -p /tmp/digests
|
||||
digest="${{ steps.build.outputs.digest }}"
|
||||
touch "/tmp/digests/${digest#sha256:}"
|
||||
- name: Upload digest
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: digests-${{ env.PLATFORM_PAIR }}
|
||||
path: /tmp/digests/*
|
||||
if-no-files-found: error
|
||||
retention-days: 1
|
||||
|
||||
merge:
|
||||
runs-on: ubuntu-latest
|
||||
needs:
|
||||
- build
|
||||
steps:
|
||||
- name: Download digests
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
path: /tmp/digests
|
||||
pattern: digests-*
|
||||
merge-multiple: true
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
- name: Create manifest list and push
|
||||
working-directory: /tmp/digests
|
||||
run: |
|
||||
docker buildx imagetools create --tag ${{ env.REGISTRY_IMAGE }}:develop \
|
||||
$(printf '${{ env.REGISTRY_IMAGE }}@sha256:%s ' *)
|
||||
- name: Inspect image
|
||||
run: |
|
||||
docker buildx imagetools inspect ${{ env.REGISTRY_IMAGE }}:develop
|
||||
|
|
|
@ -5,24 +5,34 @@ on:
|
|||
types: [published]
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
name: Push Docker image to Docker Hub
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
REGISTRY_IMAGE: misskey/misskey
|
||||
|
||||
jobs:
|
||||
# see https://docs.docker.com/build/ci/github-actions/multi-platform/#distribute-build-across-multiple-runners
|
||||
build:
|
||||
name: Build
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
platform:
|
||||
- linux/amd64
|
||||
- linux/arm64
|
||||
steps:
|
||||
- name: Prepare
|
||||
run: |
|
||||
platform=${{ matrix.platform }}
|
||||
echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV
|
||||
- name: Check out the repo
|
||||
uses: actions/checkout@v4.1.1
|
||||
- name: Set up Docker Buildx
|
||||
id: buildx
|
||||
uses: docker/setup-buildx-action@v3.0.0
|
||||
with:
|
||||
platforms: linux/amd64,linux/arm64
|
||||
uses: docker/setup-buildx-action@v3
|
||||
- name: Docker meta
|
||||
id: meta
|
||||
uses: docker/metadata-action@v5
|
||||
with:
|
||||
images: misskey/misskey
|
||||
images: ${{ env.REGISTRY_IMAGE }}
|
||||
tags: |
|
||||
type=edge
|
||||
type=ref,event=pr
|
||||
|
@ -36,14 +46,59 @@ jobs:
|
|||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
- name: Build and Push to Docker Hub
|
||||
id: build
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
builder: ${{ steps.buildx.outputs.name }}
|
||||
context: .
|
||||
push: true
|
||||
platforms: ${{ steps.buildx.outputs.platforms }}
|
||||
platforms: ${{ matrix.platform }}
|
||||
provenance: false
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
cache-from: type=gha
|
||||
cache-to: type=gha,mode=max
|
||||
outputs: type=image,name=${{ env.REGISTRY_IMAGE }},push-by-digest=true,name-canonical=true,push=true
|
||||
- name: Export digest
|
||||
run: |
|
||||
mkdir -p /tmp/digests
|
||||
digest="${{ steps.build.outputs.digest }}"
|
||||
touch "/tmp/digests/${digest#sha256:}"
|
||||
- name: Upload digest
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: digests-${{ env.PLATFORM_PAIR }}
|
||||
path: /tmp/digests/*
|
||||
if-no-files-found: error
|
||||
retention-days: 1
|
||||
|
||||
merge:
|
||||
runs-on: ubuntu-latest
|
||||
needs:
|
||||
- build
|
||||
steps:
|
||||
- name: Download digests
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
path: /tmp/digests
|
||||
pattern: digests-*
|
||||
merge-multiple: true
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
- name: Docker meta
|
||||
id: meta
|
||||
uses: docker/metadata-action@v5
|
||||
with:
|
||||
images: ${{ env.REGISTRY_IMAGE }}
|
||||
- name: Login to Docker Hub
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.DOCKER_USERNAME }}
|
||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||
- name: Create manifest list and push
|
||||
working-directory: /tmp/digests
|
||||
run: |
|
||||
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
|
||||
$(printf '${{ env.REGISTRY_IMAGE }}@sha256:%s ' *)
|
||||
- name: Inspect image
|
||||
run: |
|
||||
docker buildx imagetools inspect ${{ env.REGISTRY_IMAGE }}:${{ steps.meta.outputs.version }}
|
||||
|
|
|
@ -0,0 +1,113 @@
|
|||
name: Storybook
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
- develop
|
||||
- dev/storybook8 # for testing
|
||||
pull_request_target:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
env:
|
||||
NODE_OPTIONS: "--max_old_space_size=7168"
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3.6.0
|
||||
if: github.event_name != 'pull_request_target'
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: true
|
||||
- uses: actions/checkout@v3.6.0
|
||||
if: github.event_name == 'pull_request_target'
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: true
|
||||
ref: "refs/pull/${{ github.event.number }}/merge"
|
||||
- name: Checkout actual HEAD
|
||||
if: github.event_name == 'pull_request_target'
|
||||
id: rev
|
||||
run: |
|
||||
echo "base=$(git rev-list --parents -n1 HEAD | cut -d" " -f2)" >> $GITHUB_OUTPUT
|
||||
git checkout $(git rev-list --parents -n1 HEAD | cut -d" " -f3)
|
||||
- name: Install pnpm
|
||||
uses: pnpm/action-setup@v2
|
||||
with:
|
||||
version: 8
|
||||
run_install: false
|
||||
- name: Use Node.js 20.x
|
||||
uses: actions/setup-node@v3.8.1
|
||||
with:
|
||||
node-version-file: '.node-version'
|
||||
cache: 'pnpm'
|
||||
- run: corepack enable
|
||||
- run: pnpm i --frozen-lockfile
|
||||
- name: Check pnpm-lock.yaml
|
||||
run: git diff --exit-code pnpm-lock.yaml
|
||||
- name: Build misskey-js
|
||||
run: pnpm --filter misskey-js build
|
||||
- name: Build storybook
|
||||
run: pnpm --filter frontend build-storybook
|
||||
- name: Publish to Chromatic
|
||||
if: github.event_name != 'pull_request_target' && github.ref == 'refs/heads/master'
|
||||
run: pnpm --filter frontend chromatic --exit-once-uploaded -d storybook-static
|
||||
env:
|
||||
CHROMATIC_PROJECT_TOKEN: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
|
||||
- name: Publish to Chromatic
|
||||
if: github.event_name != 'pull_request_target' && github.ref != 'refs/heads/master'
|
||||
id: chromatic_push
|
||||
run: |
|
||||
DIFF="${{ github.event.before }} HEAD"
|
||||
if [ "$DIFF" = "0000000000000000000000000000000000000000 HEAD" ]; then
|
||||
DIFF="HEAD"
|
||||
fi
|
||||
CHROMATIC_PARAMETER="$(node packages/frontend/.storybook/changes.js $(git diff-tree --no-commit-id --name-only -r $(echo "$DIFF") | xargs))"
|
||||
if [ "$CHROMATIC_PARAMETER" = " --skip" ]; then
|
||||
echo "skip=true" >> $GITHUB_OUTPUT
|
||||
fi
|
||||
if pnpm --filter frontend chromatic -d storybook-static $(echo "$CHROMATIC_PARAMETER"); then
|
||||
echo "success=true" >> $GITHUB_OUTPUT
|
||||
else
|
||||
echo "success=false" >> $GITHUB_OUTPUT
|
||||
fi
|
||||
env:
|
||||
CHROMATIC_PROJECT_TOKEN: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
|
||||
- name: Publish to Chromatic
|
||||
if: github.event_name == 'pull_request_target'
|
||||
id: chromatic_pull_request
|
||||
run: |
|
||||
DIFF="${{ steps.rev.outputs.base }} HEAD"
|
||||
if [ "$DIFF" = "0000000000000000000000000000000000000000 HEAD" ]; then
|
||||
DIFF="HEAD"
|
||||
fi
|
||||
CHROMATIC_PARAMETER="$(node packages/frontend/.storybook/changes.js $(git diff-tree --no-commit-id --name-only -r $(echo "$DIFF") | xargs))"
|
||||
if [ "$CHROMATIC_PARAMETER" = " --skip" ]; then
|
||||
echo "skip=true" >> $GITHUB_OUTPUT
|
||||
fi
|
||||
BRANCH="${{ github.event.pull_request.head.user.login }}:${{ github.event.pull_request.head.ref }}"
|
||||
if [ "$BRANCH" = "misskey-dev:${{ github.event.pull_request.head.ref }}" ]; then
|
||||
BRANCH="${{ github.event.pull_request.head.ref }}"
|
||||
fi
|
||||
pnpm --filter frontend chromatic --exit-once-uploaded -d storybook-static --branch-name $BRANCH $(echo "$CHROMATIC_PARAMETER")
|
||||
env:
|
||||
CHROMATIC_PROJECT_TOKEN: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
|
||||
- name: Notify that Chromatic detects changes
|
||||
uses: actions/github-script@v6.4.0
|
||||
if: github.event_name != 'pull_request_target' && steps.chromatic_push.outputs.success == 'false'
|
||||
with:
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
script: |
|
||||
github.rest.repos.createCommitComment({
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
commit_sha: context.sha,
|
||||
body: 'Chromatic detects changes. Please [review the changes on Chromatic](https://www.chromatic.com/builds?appId=6428f7d7b962f0b79f97d6e4).'
|
||||
})
|
||||
- name: Upload Artifacts
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: storybook
|
||||
path: packages/frontend/storybook-static
|
|
@ -93,6 +93,7 @@
|
|||
- Fix: ジョブに関する設定の名前を修正 relashionshipJobPerSec -> relationshipJobPerSec
|
||||
- Fix: コントロールパネル->モデレーション->「誰でも新規登録できるようにする」の初期値をONからOFFに変更 #13122
|
||||
- Enhance: 連合向けのノート配信を軽量化 #13192
|
||||
- Fix: リモートユーザーが復活してもキャッシュにより該当ユーザーのActivityが受け入れられないのを修正 #13273
|
||||
- Fix: フォルダーの作成・更新を行う際、フォルダー名に最低1文字要求するように変更
|
||||
|
||||
### Service Worker
|
||||
|
|
|
@ -85,6 +85,7 @@ export class CacheService implements OnApplicationShutdown {
|
|||
this.uriPersonCache = new MemoryKVCache<MiUser | null, string | null>(Infinity, {
|
||||
toMapConverter: user => {
|
||||
if (user === null) return null;
|
||||
if (user.isDeleted) return null;
|
||||
|
||||
userByIdCache.set(user.id, user);
|
||||
return user.id;
|
||||
|
@ -160,16 +161,25 @@ export class CacheService implements OnApplicationShutdown {
|
|||
switch (type) {
|
||||
case 'userChangeSuspendedState':
|
||||
case 'remoteUserUpdated': {
|
||||
const user = await this.usersRepository.findOneByOrFail({ id: body.id });
|
||||
this.userByIdCache.set(user.id, user);
|
||||
for (const [k, v] of this.uriPersonCache.cache.entries()) {
|
||||
if (v.value === user.id) {
|
||||
this.uriPersonCache.set(k, user);
|
||||
const user = await this.usersRepository.findOneBy({ id: body.id });
|
||||
if (user == null) {
|
||||
this.userByIdCache.delete(body.id);
|
||||
for (const [k, v] of this.uriPersonCache.cache.entries()) {
|
||||
if (v.value === body.id) {
|
||||
this.uriPersonCache.delete(k);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
this.userByIdCache.set(user.id, user);
|
||||
for (const [k, v] of this.uriPersonCache.cache.entries()) {
|
||||
if (v.value === user.id) {
|
||||
this.uriPersonCache.set(k, user);
|
||||
}
|
||||
}
|
||||
if (this.userEntityService.isLocalUser(user)) {
|
||||
this.localUserByNativeTokenCache.set(user.token!, user);
|
||||
this.localUserByIdCache.set(user.id, user);
|
||||
}
|
||||
}
|
||||
if (this.userEntityService.isLocalUser(user)) {
|
||||
this.localUserByNativeTokenCache.set(user.token!, user);
|
||||
this.localUserByIdCache.set(user.id, user);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -14,9 +14,9 @@ export type FanoutTimelineName =
|
|||
| `homeTimeline:${string}`
|
||||
| `homeTimelineWithFiles:${string}` // only notes with files are included
|
||||
// local timeline
|
||||
| 'localTimeline' // replies are not included
|
||||
| 'localTimelineWithFiles' // only non-reply notes with files are included
|
||||
| 'localTimelineWithReplies' // only replies are included
|
||||
| `localTimeline` // replies are not included
|
||||
| `localTimelineWithFiles` // only non-reply notes with files are included
|
||||
| `localTimelineWithReplies` // only replies are included
|
||||
| `localTimelineWithReplyTo:${string}` // Only replies to specific local user are included. Parameter is reply user id.
|
||||
|
||||
// antenna
|
||||
|
|
|
@ -12,11 +12,11 @@ import type { Config } from '@/config.js';
|
|||
import { DI } from '@/di-symbols.js';
|
||||
import { bindThis } from '@/decorators.js';
|
||||
import type { Antenna } from '@/server/api/endpoints/i/import-antennas.js';
|
||||
import { ApRequestCreator } from '@/core/activitypub/ApRequestService.js';
|
||||
import type { DbQueue, DeliverQueue, EndedPollNotificationQueue, InboxQueue, ObjectStorageQueue, RelationshipQueue, SystemQueue, WebhookDeliverQueue } from './QueueModule.js';
|
||||
import type { DbJobData, DeliverJobData, RelationshipJobData, ThinUser } from '../queue/types.js';
|
||||
import type httpSignature from '@peertube/http-signature';
|
||||
import type * as Bull from 'bullmq';
|
||||
import { ApRequestCreator } from '@/core/activitypub/ApRequestService.js';
|
||||
|
||||
@Injectable()
|
||||
export class QueueService {
|
||||
|
|
|
@ -30,12 +30,12 @@ import { RoleService } from '@/core/RoleService.js';
|
|||
import { FeaturedService } from '@/core/FeaturedService.js';
|
||||
import { trackPromise } from '@/misc/promise-tracker.js';
|
||||
|
||||
const FALLBACK = '❤';
|
||||
const FALLBACK = '\u2764';
|
||||
const PER_NOTE_REACTION_USER_PAIR_CACHE_MAX = 16;
|
||||
|
||||
const legacies: Record<string, string> = {
|
||||
'like': '👍',
|
||||
'love': '❤', // ここに記述する場合は異体字セレクタを入れない
|
||||
'love': '\u2764', // ハート、異体字セレクタを入れない
|
||||
'laugh': '😆',
|
||||
'hmm': '🤔',
|
||||
'surprise': '😮',
|
||||
|
@ -120,7 +120,7 @@ export class ReactionService {
|
|||
let reaction = _reaction ?? FALLBACK;
|
||||
|
||||
if (note.reactionAcceptance === 'likeOnly' || ((note.reactionAcceptance === 'likeOnlyForRemote' || note.reactionAcceptance === 'nonSensitiveOnlyForLocalLikeOnlyForRemote') && (user.host != null))) {
|
||||
reaction = '❤️';
|
||||
reaction = '\u2764';
|
||||
} else if (_reaction) {
|
||||
const custom = reaction.match(isCustomEmojiRegexp);
|
||||
if (custom) {
|
||||
|
|
|
@ -106,12 +106,12 @@ export class ApDbResolverService implements OnApplicationShutdown {
|
|||
|
||||
return await this.cacheService.userByIdCache.fetchMaybe(
|
||||
parsed.id,
|
||||
() => this.usersRepository.findOneBy({ id: parsed.id }).then(x => x ?? undefined),
|
||||
() => this.usersRepository.findOneBy({ id: parsed.id, isDeleted: false }).then(x => x ?? undefined),
|
||||
) as MiLocalUser | undefined ?? null;
|
||||
} else {
|
||||
return await this.cacheService.uriPersonCache.fetch(
|
||||
parsed.uri,
|
||||
() => this.usersRepository.findOneBy({ uri: parsed.uri }),
|
||||
() => this.usersRepository.findOneBy({ uri: parsed.uri, isDeleted: false }),
|
||||
) as MiRemoteUser | null;
|
||||
}
|
||||
}
|
||||
|
@ -136,8 +136,12 @@ export class ApDbResolverService implements OnApplicationShutdown {
|
|||
|
||||
if (key == null) return null;
|
||||
|
||||
const user = await this.cacheService.findUserById(key.userId).catch(() => null) as MiRemoteUser | null;
|
||||
if (user == null) return null;
|
||||
if (user.isDeleted) return null;
|
||||
|
||||
return {
|
||||
user: await this.cacheService.findUserById(key.userId) as MiRemoteUser,
|
||||
user,
|
||||
key,
|
||||
};
|
||||
}
|
||||
|
@ -151,6 +155,7 @@ export class ApDbResolverService implements OnApplicationShutdown {
|
|||
key: MiUserPublickey | null;
|
||||
} | null> {
|
||||
const user = await this.apPersonService.resolvePerson(uri) as MiRemoteUser;
|
||||
if (user.isDeleted) return null;
|
||||
|
||||
const key = await this.publicKeyByUserIdCache.fetch(
|
||||
user.id,
|
||||
|
|
|
@ -35,6 +35,8 @@ import { ApResolverService } from './ApResolverService.js';
|
|||
import { ApAudienceService } from './ApAudienceService.js';
|
||||
import { ApPersonService } from './models/ApPersonService.js';
|
||||
import { ApQuestionService } from './models/ApQuestionService.js';
|
||||
import { CacheService } from '@/core/CacheService.js';
|
||||
import { GlobalEventService } from '@/core/GlobalEventService.js';
|
||||
import type { Resolver } from './ApResolverService.js';
|
||||
import type { IAccept, IAdd, IAnnounce, IBlock, ICreate, IDelete, IFlag, IFollow, ILike, IObject, IReject, IRemove, IUndo, IUpdate, IMove } from './type.js';
|
||||
|
||||
|
@ -82,6 +84,8 @@ export class ApInboxService {
|
|||
private apPersonService: ApPersonService,
|
||||
private apQuestionService: ApQuestionService,
|
||||
private queueService: QueueService,
|
||||
private cacheService: CacheService,
|
||||
private globalEventService: GlobalEventService,
|
||||
) {
|
||||
this.logger = this.apLoggerService.logger;
|
||||
}
|
||||
|
@ -479,6 +483,8 @@ export class ApInboxService {
|
|||
isDeleted: true,
|
||||
});
|
||||
|
||||
this.globalEventService.publishInternalEvent('remoteUserUpdated', { id: actor.id });
|
||||
|
||||
return `ok: queued ${job.name} ${job.id}`;
|
||||
}
|
||||
|
||||
|
|
|
@ -31,7 +31,7 @@ export class ApMfmService {
|
|||
|
||||
const parsed = mfm.parse(srcMfm);
|
||||
|
||||
if (!apAppend && parsed.every(n => ['text', 'unicodeEmoji', 'emojiCode', 'mention', 'hashtag', 'url'].includes(n.type))) {
|
||||
if (!apAppend && parsed?.every(n => ['text', 'unicodeEmoji', 'emojiCode', 'mention', 'hashtag', 'url'].includes(n.type))) {
|
||||
noMisskeyContent = true;
|
||||
}
|
||||
|
||||
|
|
|
@ -37,7 +37,17 @@ import { packedEmojiDetailedSchema, packedEmojiSimpleSchema } from '@/models/jso
|
|||
import { packedFlashSchema } from '@/models/json-schema/flash.js';
|
||||
import { packedAnnouncementSchema } from '@/models/json-schema/announcement.js';
|
||||
import { packedSigninSchema } from '@/models/json-schema/signin.js';
|
||||
import { packedRoleLiteSchema, packedRoleSchema, packedRolePoliciesSchema } from '@/models/json-schema/role.js';
|
||||
import {
|
||||
packedRoleLiteSchema,
|
||||
packedRoleSchema,
|
||||
packedRolePoliciesSchema,
|
||||
packedRoleCondFormulaLogicsSchema,
|
||||
packedRoleCondFormulaValueNot,
|
||||
packedRoleCondFormulaValueIsLocalOrRemoteSchema,
|
||||
packedRoleCondFormulaValueCreatedSchema,
|
||||
packedRoleCondFormulaFollowersOrFollowingOrNotesSchema,
|
||||
packedRoleCondFormulaValueSchema,
|
||||
} from '@/models/json-schema/role.js';
|
||||
import { packedAdSchema } from '@/models/json-schema/ad.js';
|
||||
import { packedReversiGameLiteSchema, packedReversiGameDetailedSchema } from '@/models/json-schema/reversi-game.js';
|
||||
|
||||
|
@ -78,6 +88,12 @@ export const refs = {
|
|||
EmojiDetailed: packedEmojiDetailedSchema,
|
||||
Flash: packedFlashSchema,
|
||||
Signin: packedSigninSchema,
|
||||
RoleCondFormulaLogics: packedRoleCondFormulaLogicsSchema,
|
||||
RoleCondFormulaValueNot: packedRoleCondFormulaValueNot,
|
||||
RoleCondFormulaValueIsLocalOrRemote: packedRoleCondFormulaValueIsLocalOrRemoteSchema,
|
||||
RoleCondFormulaValueCreated: packedRoleCondFormulaValueCreatedSchema,
|
||||
RoleCondFormulaFollowersOrFollowingOrNotes: packedRoleCondFormulaFollowersOrFollowingOrNotesSchema,
|
||||
RoleCondFormulaValue: packedRoleCondFormulaValueSchema,
|
||||
RoleLite: packedRoleLiteSchema,
|
||||
Role: packedRoleSchema,
|
||||
RolePolicies: packedRolePoliciesSchema,
|
||||
|
|
|
@ -48,7 +48,7 @@ export class MiBubbleGameRecord {
|
|||
@Column('jsonb', {
|
||||
default: [],
|
||||
})
|
||||
public logs: any[];
|
||||
public logs: number[][];
|
||||
|
||||
@Column('boolean', {
|
||||
default: false,
|
||||
|
|
|
@ -69,7 +69,7 @@ type CondFormulaValueNotesMoreThanOrEq = {
|
|||
value: number;
|
||||
};
|
||||
|
||||
export type RoleCondFormulaValue =
|
||||
export type RoleCondFormulaValue = { id: string } & (
|
||||
CondFormulaValueAnd |
|
||||
CondFormulaValueOr |
|
||||
CondFormulaValueNot |
|
||||
|
@ -82,7 +82,8 @@ export type RoleCondFormulaValue =
|
|||
CondFormulaValueFollowingLessThanOrEq |
|
||||
CondFormulaValueFollowingMoreThanOrEq |
|
||||
CondFormulaValueNotesLessThanOrEq |
|
||||
CondFormulaValueNotesMoreThanOrEq;
|
||||
CondFormulaValueNotesMoreThanOrEq
|
||||
);
|
||||
|
||||
@Entity('role')
|
||||
export class MiRole {
|
||||
|
|
|
@ -47,12 +47,12 @@ export const packedReversiGameLiteSchema = {
|
|||
user1: {
|
||||
type: 'object',
|
||||
optional: false, nullable: false,
|
||||
ref: 'User',
|
||||
ref: 'UserLite',
|
||||
},
|
||||
user2: {
|
||||
type: 'object',
|
||||
optional: false, nullable: false,
|
||||
ref: 'User',
|
||||
ref: 'UserLite',
|
||||
},
|
||||
winnerId: {
|
||||
type: 'string',
|
||||
|
@ -62,7 +62,7 @@ export const packedReversiGameLiteSchema = {
|
|||
winner: {
|
||||
type: 'object',
|
||||
optional: false, nullable: true,
|
||||
ref: 'User',
|
||||
ref: 'UserLite',
|
||||
},
|
||||
surrenderedUserId: {
|
||||
type: 'string',
|
||||
|
@ -165,12 +165,12 @@ export const packedReversiGameDetailedSchema = {
|
|||
user1: {
|
||||
type: 'object',
|
||||
optional: false, nullable: false,
|
||||
ref: 'User',
|
||||
ref: 'UserLite',
|
||||
},
|
||||
user2: {
|
||||
type: 'object',
|
||||
optional: false, nullable: false,
|
||||
ref: 'User',
|
||||
ref: 'UserLite',
|
||||
},
|
||||
winnerId: {
|
||||
type: 'string',
|
||||
|
@ -180,7 +180,7 @@ export const packedReversiGameDetailedSchema = {
|
|||
winner: {
|
||||
type: 'object',
|
||||
optional: false, nullable: true,
|
||||
ref: 'User',
|
||||
ref: 'UserLite',
|
||||
},
|
||||
surrenderedUserId: {
|
||||
type: 'string',
|
||||
|
@ -226,6 +226,9 @@ export const packedReversiGameDetailedSchema = {
|
|||
items: {
|
||||
type: 'array',
|
||||
optional: false, nullable: false,
|
||||
items: {
|
||||
type: 'number',
|
||||
},
|
||||
},
|
||||
},
|
||||
map: {
|
||||
|
|
|
@ -1,3 +1,129 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: syuilo and misskey-project
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
export const packedRoleCondFormulaLogicsSchema = {
|
||||
type: 'object',
|
||||
properties: {
|
||||
id: {
|
||||
type: 'string', optional: false,
|
||||
},
|
||||
type: {
|
||||
type: 'string',
|
||||
nullable: false, optional: false,
|
||||
enum: ['and', 'or'],
|
||||
},
|
||||
values: {
|
||||
type: 'array',
|
||||
nullable: false, optional: false,
|
||||
items: {
|
||||
ref: 'RoleCondFormulaValue',
|
||||
},
|
||||
},
|
||||
},
|
||||
} as const;
|
||||
|
||||
export const packedRoleCondFormulaValueNot = {
|
||||
type: 'object',
|
||||
properties: {
|
||||
id: {
|
||||
type: 'string', optional: false,
|
||||
},
|
||||
type: {
|
||||
type: 'string',
|
||||
nullable: false, optional: false,
|
||||
enum: ['not'],
|
||||
},
|
||||
value: {
|
||||
type: 'object',
|
||||
optional: false,
|
||||
ref: 'RoleCondFormulaValue',
|
||||
},
|
||||
},
|
||||
} as const;
|
||||
|
||||
export const packedRoleCondFormulaValueIsLocalOrRemoteSchema = {
|
||||
type: 'object',
|
||||
properties: {
|
||||
id: {
|
||||
type: 'string', optional: false,
|
||||
},
|
||||
type: {
|
||||
type: 'string',
|
||||
nullable: false, optional: false,
|
||||
enum: ['isLocal', 'isRemote'],
|
||||
},
|
||||
},
|
||||
} as const;
|
||||
|
||||
export const packedRoleCondFormulaValueCreatedSchema = {
|
||||
type: 'object',
|
||||
properties: {
|
||||
id: {
|
||||
type: 'string', optional: false,
|
||||
},
|
||||
type: {
|
||||
type: 'string',
|
||||
nullable: false, optional: false,
|
||||
enum: [
|
||||
'createdLessThan',
|
||||
'createdMoreThan',
|
||||
],
|
||||
},
|
||||
sec: {
|
||||
type: 'number',
|
||||
nullable: false, optional: false,
|
||||
},
|
||||
},
|
||||
} as const;
|
||||
|
||||
export const packedRoleCondFormulaFollowersOrFollowingOrNotesSchema = {
|
||||
type: 'object',
|
||||
properties: {
|
||||
id: {
|
||||
type: 'string', optional: false,
|
||||
},
|
||||
type: {
|
||||
type: 'string',
|
||||
nullable: false, optional: false,
|
||||
enum: [
|
||||
'followersLessThanOrEq',
|
||||
'followersMoreThanOrEq',
|
||||
'followingLessThanOrEq',
|
||||
'followingMoreThanOrEq',
|
||||
'notesLessThanOrEq',
|
||||
'notesMoreThanOrEq',
|
||||
],
|
||||
},
|
||||
value: {
|
||||
type: 'number',
|
||||
nullable: false, optional: false,
|
||||
},
|
||||
},
|
||||
} as const;
|
||||
|
||||
export const packedRoleCondFormulaValueSchema = {
|
||||
type: 'object',
|
||||
oneOf: [
|
||||
{
|
||||
ref: 'RoleCondFormulaLogics',
|
||||
},
|
||||
{
|
||||
ref: 'RoleCondFormulaValueNot',
|
||||
},
|
||||
{
|
||||
ref: 'RoleCondFormulaValueIsLocalOrRemote',
|
||||
},
|
||||
{
|
||||
ref: 'RoleCondFormulaValueCreated',
|
||||
},
|
||||
{
|
||||
ref: 'RoleCondFormulaFollowersOrFollowingOrNotes',
|
||||
},
|
||||
],
|
||||
} as const;
|
||||
|
||||
export const packedRolePoliciesSchema = {
|
||||
type: 'object',
|
||||
optional: false, nullable: false,
|
||||
|
@ -174,6 +300,7 @@ export const packedRoleSchema = {
|
|||
condFormula: {
|
||||
type: 'object',
|
||||
optional: false, nullable: false,
|
||||
ref: 'RoleCondFormulaValue',
|
||||
},
|
||||
isPublic: {
|
||||
type: 'boolean',
|
||||
|
|
|
@ -3,16 +3,38 @@
|
|||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
const notificationRecieveConfig = {
|
||||
export const notificationRecieveConfig = {
|
||||
type: 'object',
|
||||
nullable: false, optional: true,
|
||||
properties: {
|
||||
type: {
|
||||
type: 'string',
|
||||
nullable: false, optional: false,
|
||||
enum: ['all', 'following', 'follower', 'mutualFollow', 'list', 'never'],
|
||||
oneOf: [
|
||||
{
|
||||
type: 'object',
|
||||
nullable: false,
|
||||
properties: {
|
||||
type: {
|
||||
type: 'string',
|
||||
nullable: false,
|
||||
enum: ['all', 'following', 'follower', 'mutualFollow', 'never'],
|
||||
},
|
||||
},
|
||||
required: ['type'],
|
||||
},
|
||||
},
|
||||
{
|
||||
type: 'object',
|
||||
nullable: false,
|
||||
properties: {
|
||||
type: {
|
||||
type: 'string',
|
||||
nullable: false,
|
||||
enum: ['list'],
|
||||
},
|
||||
userListId: {
|
||||
type: 'string',
|
||||
format: 'misskey:id',
|
||||
},
|
||||
},
|
||||
required: ['type', 'userListId'],
|
||||
},
|
||||
],
|
||||
} as const;
|
||||
|
||||
export const packedUserLiteSchema = {
|
||||
|
@ -546,15 +568,20 @@ export const packedMeDetailedOnlySchema = {
|
|||
type: 'object',
|
||||
nullable: false, optional: false,
|
||||
properties: {
|
||||
app: notificationRecieveConfig,
|
||||
quote: notificationRecieveConfig,
|
||||
reply: notificationRecieveConfig,
|
||||
follow: notificationRecieveConfig,
|
||||
renote: notificationRecieveConfig,
|
||||
mention: notificationRecieveConfig,
|
||||
reaction: notificationRecieveConfig,
|
||||
pollEnded: notificationRecieveConfig,
|
||||
receiveFollowRequest: notificationRecieveConfig,
|
||||
note: { optional: true, ...notificationRecieveConfig },
|
||||
follow: { optional: true, ...notificationRecieveConfig },
|
||||
mention: { optional: true, ...notificationRecieveConfig },
|
||||
reply: { optional: true, ...notificationRecieveConfig },
|
||||
renote: { optional: true, ...notificationRecieveConfig },
|
||||
quote: { optional: true, ...notificationRecieveConfig },
|
||||
reaction: { optional: true, ...notificationRecieveConfig },
|
||||
pollEnded: { optional: true, ...notificationRecieveConfig },
|
||||
receiveFollowRequest: { optional: true, ...notificationRecieveConfig },
|
||||
followRequestAccepted: { optional: true, ...notificationRecieveConfig },
|
||||
roleAssigned: { optional: true, ...notificationRecieveConfig },
|
||||
achievementEarned: { optional: true, ...notificationRecieveConfig },
|
||||
app: { optional: true, ...notificationRecieveConfig },
|
||||
test: { optional: true, ...notificationRecieveConfig },
|
||||
},
|
||||
},
|
||||
emailNotificationTypes: {
|
||||
|
|
|
@ -34,7 +34,7 @@ export class RelationshipProcessorService {
|
|||
|
||||
@bindThis
|
||||
public async processFollow(job: Bull.Job<RelationshipJobData>): Promise<string> {
|
||||
this.logger.info(`${job.data.from.id} is trying to follow ${job.data.to.id} ${job.data.withReplies ? 'with replies' : 'without replies'}`);
|
||||
this.logger.info(`${job.data.from.id} is trying to follow ${job.data.to.id} ${job.data.withReplies ? "with replies" : "without replies"}`);
|
||||
await this.userFollowingService.follow(job.data.from, job.data.to, {
|
||||
requestId: job.data.requestId,
|
||||
silent: job.data.silent,
|
||||
|
|
|
@ -37,12 +37,12 @@ export class NodeinfoServerService {
|
|||
@bindThis
|
||||
public getLinks() {
|
||||
return [{
|
||||
rel: 'http://nodeinfo.diaspora.software/ns/schema/2.1',
|
||||
href: this.config.url + nodeinfo2_1path,
|
||||
}, {
|
||||
rel: 'http://nodeinfo.diaspora.software/ns/schema/2.0',
|
||||
href: this.config.url + nodeinfo2_0path,
|
||||
}];
|
||||
rel: 'http://nodeinfo.diaspora.software/ns/schema/2.1',
|
||||
href: this.config.url + nodeinfo2_1path
|
||||
}, {
|
||||
rel: 'http://nodeinfo.diaspora.software/ns/schema/2.0',
|
||||
href: this.config.url + nodeinfo2_0path,
|
||||
}];
|
||||
}
|
||||
|
||||
@bindThis
|
||||
|
|
|
@ -15,9 +15,6 @@ export const meta = {
|
|||
requireCredential: true,
|
||||
requireAdmin: true,
|
||||
kind: 'write:admin:delete-account',
|
||||
|
||||
res: {
|
||||
},
|
||||
} as const;
|
||||
|
||||
export const paramDef = {
|
||||
|
|
|
@ -84,6 +84,24 @@ export const meta = {
|
|||
properties: {
|
||||
type: 'object',
|
||||
optional: false, nullable: false,
|
||||
properties: {
|
||||
width: {
|
||||
type: 'number',
|
||||
optional: true, nullable: false,
|
||||
},
|
||||
height: {
|
||||
type: 'number',
|
||||
optional: true, nullable: false,
|
||||
},
|
||||
orientation: {
|
||||
type: 'number',
|
||||
optional: true, nullable: false,
|
||||
},
|
||||
avgColor: {
|
||||
type: 'string',
|
||||
optional: true, nullable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
storedInternal: {
|
||||
type: 'boolean',
|
||||
|
|
|
@ -18,6 +18,18 @@ export const meta = {
|
|||
res: {
|
||||
type: 'object',
|
||||
optional: false, nullable: false,
|
||||
additionalProperties: {
|
||||
type: 'object',
|
||||
properties: {
|
||||
count: {
|
||||
type: 'number',
|
||||
},
|
||||
size: {
|
||||
type: 'number',
|
||||
},
|
||||
},
|
||||
required: ['count', 'size'],
|
||||
},
|
||||
example: {
|
||||
migrations: {
|
||||
count: 66,
|
||||
|
|
|
@ -10,6 +10,7 @@ import { DI } from '@/di-symbols.js';
|
|||
import { RoleService } from '@/core/RoleService.js';
|
||||
import { RoleEntityService } from '@/core/entities/RoleEntityService.js';
|
||||
import { IdService } from '@/core/IdService.js';
|
||||
import { notificationRecieveConfig } from '@/models/json-schema/user.js';
|
||||
|
||||
export const meta = {
|
||||
tags: ['admin'],
|
||||
|
@ -21,6 +22,157 @@ export const meta = {
|
|||
res: {
|
||||
type: 'object',
|
||||
nullable: false, optional: false,
|
||||
properties: {
|
||||
email: {
|
||||
type: 'string',
|
||||
optional: false, nullable: true,
|
||||
},
|
||||
emailVerified: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
autoAcceptFollowed: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
noCrawle: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
preventAiLearning: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
alwaysMarkNsfw: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
autoSensitive: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
carefulBot: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
injectFeaturedNote: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
receiveAnnouncementEmail: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
mutedWords: {
|
||||
type: 'array',
|
||||
optional: false, nullable: false,
|
||||
items: {
|
||||
anyOf: [
|
||||
{
|
||||
type: 'string',
|
||||
},
|
||||
{
|
||||
type: 'array',
|
||||
items: {
|
||||
type: 'string',
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
},
|
||||
mutedInstances: {
|
||||
type: 'array',
|
||||
optional: false, nullable: false,
|
||||
items: {
|
||||
type: 'string',
|
||||
},
|
||||
},
|
||||
notificationRecieveConfig: {
|
||||
type: 'object',
|
||||
optional: false, nullable: false,
|
||||
properties: {
|
||||
note: { optional: true, ...notificationRecieveConfig },
|
||||
follow: { optional: true, ...notificationRecieveConfig },
|
||||
mention: { optional: true, ...notificationRecieveConfig },
|
||||
reply: { optional: true, ...notificationRecieveConfig },
|
||||
renote: { optional: true, ...notificationRecieveConfig },
|
||||
quote: { optional: true, ...notificationRecieveConfig },
|
||||
reaction: { optional: true, ...notificationRecieveConfig },
|
||||
pollEnded: { optional: true, ...notificationRecieveConfig },
|
||||
receiveFollowRequest: { optional: true, ...notificationRecieveConfig },
|
||||
followRequestAccepted: { optional: true, ...notificationRecieveConfig },
|
||||
roleAssigned: { optional: true, ...notificationRecieveConfig },
|
||||
achievementEarned: { optional: true, ...notificationRecieveConfig },
|
||||
app: { optional: true, ...notificationRecieveConfig },
|
||||
test: { optional: true, ...notificationRecieveConfig },
|
||||
},
|
||||
},
|
||||
isModerator: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
isSilenced: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
isSuspended: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
isHibernated: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
lastActiveDate: {
|
||||
type: 'string',
|
||||
optional: false, nullable: true,
|
||||
},
|
||||
moderationNote: {
|
||||
type: 'string',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
signins: {
|
||||
type: 'array',
|
||||
optional: false, nullable: false,
|
||||
items: {
|
||||
ref: 'Signin',
|
||||
},
|
||||
},
|
||||
policies: {
|
||||
type: 'object',
|
||||
optional: false, nullable: false,
|
||||
ref: 'RolePolicies',
|
||||
},
|
||||
roles: {
|
||||
type: 'array',
|
||||
optional: false, nullable: false,
|
||||
items: {
|
||||
type: 'object',
|
||||
ref: 'Role',
|
||||
},
|
||||
},
|
||||
roleAssigns: {
|
||||
type: 'array',
|
||||
optional: false, nullable: false,
|
||||
items: {
|
||||
type: 'object',
|
||||
properties: {
|
||||
createdAt: {
|
||||
type: 'string',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
expiresAt: {
|
||||
type: 'string',
|
||||
optional: false, nullable: true,
|
||||
},
|
||||
roleId: {
|
||||
type: 'string',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
} as const;
|
||||
|
||||
|
@ -89,7 +241,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
isSilenced: isSilenced,
|
||||
isSuspended: user.isSuspended,
|
||||
isHibernated: user.isHibernated,
|
||||
lastActiveDate: user.lastActiveDate,
|
||||
lastActiveDate: user.lastActiveDate ? user.lastActiveDate.toISOString() : null,
|
||||
moderationNote: profile.moderationNote ?? '',
|
||||
signins,
|
||||
policies: await this.roleService.getUserPolicies(user.id),
|
||||
|
|
|
@ -24,9 +24,19 @@ export const meta = {
|
|||
type: 'object',
|
||||
optional: false, nullable: false,
|
||||
properties: {
|
||||
id: { type: 'string', format: 'misskey:id' },
|
||||
score: { type: 'integer' },
|
||||
user: { ref: 'UserLite' },
|
||||
id: {
|
||||
type: 'string', format: 'misskey:id',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
score: {
|
||||
type: 'integer',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
user: {
|
||||
type: 'object',
|
||||
optional: true, nullable: false,
|
||||
ref: 'UserLite',
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
|
|
|
@ -29,9 +29,6 @@ export const meta = {
|
|||
id: 'eb627bc7-574b-4a52-a860-3c3eae772b88',
|
||||
},
|
||||
},
|
||||
|
||||
res: {
|
||||
},
|
||||
} as const;
|
||||
|
||||
export const paramDef = {
|
||||
|
@ -39,7 +36,15 @@ export const paramDef = {
|
|||
properties: {
|
||||
score: { type: 'integer', minimum: 0 },
|
||||
seed: { type: 'string', minLength: 1, maxLength: 1024 },
|
||||
logs: { type: 'array' },
|
||||
logs: {
|
||||
type: 'array',
|
||||
items: {
|
||||
type: 'array',
|
||||
items: {
|
||||
type: 'number',
|
||||
},
|
||||
},
|
||||
},
|
||||
gameMode: { type: 'string' },
|
||||
gameVersion: { type: 'integer' },
|
||||
},
|
||||
|
|
|
@ -25,8 +25,8 @@ export const meta = {
|
|||
items: {
|
||||
type: 'object',
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
},
|
||||
} as const;
|
||||
|
||||
|
|
|
@ -71,7 +71,7 @@ export const paramDef = {
|
|||
type: 'object',
|
||||
properties: {
|
||||
userId: { type: 'string', format: 'misskey:id' },
|
||||
withReplies: { type: 'boolean' },
|
||||
withReplies: { type: 'boolean' }
|
||||
},
|
||||
required: ['userId'],
|
||||
} as const;
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
import { Inject, Injectable } from '@nestjs/common';
|
||||
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||
import type { UsersRepository } from '@/models/_.js';
|
||||
import { safeForSql } from '@/misc/safe-for-sql.js';
|
||||
import { safeForSql } from "@/misc/safe-for-sql.js";
|
||||
import { normalizeForSearch } from '@/misc/normalize-for-search.js';
|
||||
import { UserEntityService } from '@/core/entities/UserEntityService.js';
|
||||
import { DI } from '@/di-symbols.js';
|
||||
|
|
|
@ -14,7 +14,7 @@ export const meta = {
|
|||
tags: ['account'],
|
||||
|
||||
requireCredential: true,
|
||||
kind: 'read:account',
|
||||
kind: "read:account",
|
||||
|
||||
res: {
|
||||
type: 'object',
|
||||
|
|
|
@ -15,6 +15,19 @@ export const meta = {
|
|||
requireCredential: true,
|
||||
|
||||
secure: true,
|
||||
|
||||
res: {
|
||||
type: 'object',
|
||||
properties: {
|
||||
backupCodes: {
|
||||
type: 'array',
|
||||
optional: false,
|
||||
items: {
|
||||
type: 'string',
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
} as const;
|
||||
|
||||
export const paramDef = {
|
||||
|
|
|
@ -47,7 +47,7 @@ export const meta = {
|
|||
properties: {
|
||||
id: {
|
||||
type: 'string',
|
||||
nullable: true,
|
||||
optional: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
|
|
|
@ -21,21 +21,26 @@ export const meta = {
|
|||
properties: {
|
||||
id: {
|
||||
type: 'string',
|
||||
optional: false,
|
||||
format: 'misskey:id',
|
||||
},
|
||||
name: {
|
||||
type: 'string',
|
||||
optional: true,
|
||||
},
|
||||
createdAt: {
|
||||
type: 'string',
|
||||
optional: false,
|
||||
format: 'date-time',
|
||||
},
|
||||
lastUsedAt: {
|
||||
type: 'string',
|
||||
optional: true,
|
||||
format: 'date-time',
|
||||
},
|
||||
permission: {
|
||||
type: 'array',
|
||||
optional: false,
|
||||
uniqueItems: true,
|
||||
items: {
|
||||
type: 'string',
|
||||
|
|
|
@ -23,16 +23,19 @@ export const meta = {
|
|||
id: {
|
||||
type: 'string',
|
||||
format: 'misskey:id',
|
||||
optional: false,
|
||||
},
|
||||
name: {
|
||||
type: 'string',
|
||||
optional: false,
|
||||
},
|
||||
callbackUrl: {
|
||||
type: 'string',
|
||||
nullable: true,
|
||||
optional: false, nullable: true,
|
||||
},
|
||||
permission: {
|
||||
type: 'array',
|
||||
optional: false,
|
||||
uniqueItems: true,
|
||||
items: {
|
||||
type: 'string',
|
||||
|
@ -40,6 +43,7 @@ export const meta = {
|
|||
},
|
||||
isAuthorized: {
|
||||
type: 'boolean',
|
||||
optional: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
|
|
|
@ -22,6 +22,15 @@ export const meta = {
|
|||
|
||||
res: {
|
||||
type: 'object',
|
||||
properties: {
|
||||
updatedAt: {
|
||||
type: 'string',
|
||||
optional: false,
|
||||
},
|
||||
value: {
|
||||
optional: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
} as const;
|
||||
|
||||
|
@ -50,7 +59,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
}
|
||||
|
||||
return {
|
||||
updatedAt: item.updatedAt,
|
||||
updatedAt: item.updatedAt.toISOString(),
|
||||
value: item.value,
|
||||
};
|
||||
});
|
||||
|
|
|
@ -22,7 +22,7 @@ export const meta = {
|
|||
|
||||
res: {
|
||||
type: 'object',
|
||||
},
|
||||
}
|
||||
} as const;
|
||||
|
||||
export const paramDef = {
|
||||
|
|
|
@ -13,6 +13,9 @@ export const meta = {
|
|||
|
||||
res: {
|
||||
type: 'object',
|
||||
additionalProperties: {
|
||||
type: 'string',
|
||||
},
|
||||
},
|
||||
} as const;
|
||||
|
||||
|
|
|
@ -10,6 +10,13 @@ import { RegistryApiService } from '@/core/RegistryApiService.js';
|
|||
export const meta = {
|
||||
requireCredential: true,
|
||||
kind: 'read:account',
|
||||
|
||||
res: {
|
||||
type: 'array',
|
||||
items: {
|
||||
type: 'string',
|
||||
},
|
||||
},
|
||||
} as const;
|
||||
|
||||
export const paramDef = {
|
||||
|
|
|
@ -22,8 +22,8 @@ export const meta = {
|
|||
type: 'array',
|
||||
items: {
|
||||
type: 'string',
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
},
|
||||
domain: {
|
||||
type: 'string',
|
||||
|
@ -31,7 +31,7 @@ export const meta = {
|
|||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
} as const;
|
||||
|
||||
export const paramDef = {
|
||||
|
|
|
@ -33,6 +33,7 @@ import { HttpRequestService } from '@/core/HttpRequestService.js';
|
|||
import type { Config } from '@/config.js';
|
||||
import { safeForSql } from '@/misc/safe-for-sql.js';
|
||||
import { AvatarDecorationService } from '@/core/AvatarDecorationService.js';
|
||||
import { notificationRecieveConfig } from '@/models/json-schema/user.js';
|
||||
import { ApiLoggerService } from '../../ApiLoggerService.js';
|
||||
import { ApiError } from '../../error.js';
|
||||
|
||||
|
@ -184,7 +185,26 @@ export const paramDef = {
|
|||
mutedInstances: { type: 'array', items: {
|
||||
type: 'string',
|
||||
} },
|
||||
notificationRecieveConfig: { type: 'object' },
|
||||
notificationRecieveConfig: {
|
||||
type: 'object',
|
||||
nullable: false,
|
||||
properties: {
|
||||
note: notificationRecieveConfig,
|
||||
follow: notificationRecieveConfig,
|
||||
mention: notificationRecieveConfig,
|
||||
reply: notificationRecieveConfig,
|
||||
renote: notificationRecieveConfig,
|
||||
quote: notificationRecieveConfig,
|
||||
reaction: notificationRecieveConfig,
|
||||
pollEnded: notificationRecieveConfig,
|
||||
receiveFollowRequest: notificationRecieveConfig,
|
||||
followRequestAccepted: notificationRecieveConfig,
|
||||
roleAssigned: notificationRecieveConfig,
|
||||
achievementEarned: notificationRecieveConfig,
|
||||
app: notificationRecieveConfig,
|
||||
test: notificationRecieveConfig,
|
||||
},
|
||||
},
|
||||
emailNotificationTypes: { type: 'array', items: {
|
||||
type: 'string',
|
||||
} },
|
||||
|
|
|
@ -108,7 +108,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
url: webhook.url,
|
||||
secret: webhook.secret,
|
||||
active: webhook.active,
|
||||
latestSentAt: webhook.latestSentAt?.toISOString(),
|
||||
latestSentAt: webhook.latestSentAt ? webhook.latestSentAt.toISOString() : null,
|
||||
latestStatus: webhook.latestStatus,
|
||||
};
|
||||
});
|
||||
|
|
|
@ -73,7 +73,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
url: webhook.url,
|
||||
secret: webhook.secret,
|
||||
active: webhook.active,
|
||||
latestSentAt: webhook.latestSentAt?.toISOString(),
|
||||
latestSentAt: webhook.latestSentAt ? webhook.latestSentAt.toISOString() : null,
|
||||
latestStatus: webhook.latestStatus,
|
||||
}
|
||||
));
|
||||
|
|
|
@ -85,7 +85,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
url: webhook.url,
|
||||
secret: webhook.secret,
|
||||
active: webhook.active,
|
||||
latestSentAt: webhook.latestSentAt?.toISOString(),
|
||||
latestSentAt: webhook.latestSentAt ? webhook.latestSentAt.toISOString() : null,
|
||||
latestStatus: webhook.latestStatus,
|
||||
};
|
||||
});
|
||||
|
|
|
@ -47,7 +47,7 @@ export const meta = {
|
|||
bothWithRepliesAndWithFiles: {
|
||||
message: 'Specifying both withReplies and withFiles is not supported',
|
||||
code: 'BOTH_WITH_REPLIES_AND_WITH_FILES',
|
||||
id: 'dfaa3eb7-8002-4cb7-bcc4-1095df46656f',
|
||||
id: 'dfaa3eb7-8002-4cb7-bcc4-1095df46656f'
|
||||
},
|
||||
},
|
||||
} as const;
|
||||
|
|
|
@ -14,9 +14,6 @@ export const meta = {
|
|||
|
||||
errors: {
|
||||
},
|
||||
|
||||
res: {
|
||||
},
|
||||
} as const;
|
||||
|
||||
export const paramDef = {
|
||||
|
|
|
@ -30,6 +30,9 @@ export const meta = {
|
|||
},
|
||||
|
||||
res: {
|
||||
type: 'object',
|
||||
optional: true,
|
||||
ref: 'ReversiGameDetailed',
|
||||
},
|
||||
} as const;
|
||||
|
||||
|
|
|
@ -19,20 +19,24 @@ export const meta = {
|
|||
id: {
|
||||
type: 'string',
|
||||
format: 'misskey:id',
|
||||
optional: true, nullable: false,
|
||||
},
|
||||
required: {
|
||||
type: 'boolean',
|
||||
optional: false, nullable: false,
|
||||
},
|
||||
string: {
|
||||
type: 'string',
|
||||
optional: true, nullable: false,
|
||||
},
|
||||
default: {
|
||||
type: 'string',
|
||||
optional: true, nullable: false,
|
||||
},
|
||||
nullableDefault: {
|
||||
type: 'string',
|
||||
default: 'hello',
|
||||
nullable: true,
|
||||
optional: true, nullable: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
|
|
|
@ -7,10 +7,11 @@ process.env.NODE_ENV = 'test';
|
|||
|
||||
import * as assert from 'assert';
|
||||
import { MiNote } from '@/models/Note.js';
|
||||
import type { Packed } from '@/misc/json-schema.js';
|
||||
import { api, initTestDb, makeStreamCatcher, post, signup, uploadFile } from '../utils.js';
|
||||
import type * as misskey from 'misskey-js';
|
||||
import type{ Repository } from 'typeorm';
|
||||
import type{ Repository } from 'typeorm'
|
||||
import type { Packed } from '@/misc/json-schema.js';
|
||||
|
||||
|
||||
describe('Drive', () => {
|
||||
let Notes: Repository<MiNote>;
|
||||
|
@ -30,7 +31,7 @@ describe('Drive', () => {
|
|||
|
||||
const marker = Math.random().toString();
|
||||
|
||||
const url = 'https://raw.githubusercontent.com/misskey-dev/misskey/develop/packages/backend/test/resources/Lenna.jpg';
|
||||
const url = 'https://raw.githubusercontent.com/misskey-dev/misskey/develop/packages/backend/test/resources/Lenna.jpg'
|
||||
|
||||
const catcher = makeStreamCatcher(
|
||||
alice,
|
||||
|
@ -50,7 +51,7 @@ describe('Drive', () => {
|
|||
assert.strictEqual(res.status, 204);
|
||||
assert.strictEqual(file.name, 'Lenna.jpg');
|
||||
assert.strictEqual(file.type, 'image/jpeg');
|
||||
});
|
||||
})
|
||||
|
||||
test('ローカルからアップロードできる', async () => {
|
||||
// APIレスポンスを直接使用するので utils.js uploadFile が通過することで成功とする
|
||||
|
@ -58,27 +59,27 @@ describe('Drive', () => {
|
|||
const res = await uploadFile(alice, { path: 'Lenna.jpg', name: 'テスト画像' });
|
||||
|
||||
assert.strictEqual(res.body?.name, 'テスト画像.jpg');
|
||||
assert.strictEqual(res.body.type, 'image/jpeg');
|
||||
});
|
||||
assert.strictEqual(res.body?.type, 'image/jpeg');
|
||||
})
|
||||
|
||||
test('添付ノート一覧を取得できる', async () => {
|
||||
const ids = (await Promise.all([uploadFile(alice), uploadFile(alice), uploadFile(alice)])).map(elm => elm.body!.id);
|
||||
const ids = (await Promise.all([uploadFile(alice), uploadFile(alice), uploadFile(alice)])).map(elm => elm.body!.id)
|
||||
|
||||
const note0 = await post(alice, { fileIds: [ids[0]] });
|
||||
const note1 = await post(alice, { fileIds: [ids[0], ids[1]] });
|
||||
|
||||
const attached0 = await api('drive/files/attached-notes', { fileId: ids[0] }, alice);
|
||||
assert.strictEqual(attached0.body.length, 2);
|
||||
assert.strictEqual(attached0.body[0].id, note1.id);
|
||||
assert.strictEqual(attached0.body[1].id, note0.id);
|
||||
assert.strictEqual(attached0.body[0].id, note1.id)
|
||||
assert.strictEqual(attached0.body[1].id, note0.id)
|
||||
|
||||
const attached1 = await api('drive/files/attached-notes', { fileId: ids[1] }, alice);
|
||||
assert.strictEqual(attached1.body.length, 1);
|
||||
assert.strictEqual(attached1.body[0].id, note1.id);
|
||||
assert.strictEqual(attached1.body[0].id, note1.id)
|
||||
|
||||
const attached2 = await api('drive/files/attached-notes', { fileId: ids[2] }, alice);
|
||||
assert.strictEqual(attached2.body.length, 0);
|
||||
});
|
||||
assert.strictEqual(attached2.body.length, 0)
|
||||
})
|
||||
|
||||
test('添付ノート一覧は他の人から見えない', async () => {
|
||||
const file = await uploadFile(alice);
|
||||
|
@ -88,6 +89,7 @@ describe('Drive', () => {
|
|||
const res = await api('drive/files/attached-notes', { fileId: file.body!.id }, bob);
|
||||
assert.strictEqual(res.status, 400);
|
||||
assert.strictEqual('error' in res.body, true);
|
||||
});
|
||||
|
||||
})
|
||||
});
|
||||
|
||||
|
|
|
@ -13,10 +13,10 @@ import fetch, { File, RequestInit } from 'node-fetch';
|
|||
import { DataSource } from 'typeorm';
|
||||
import { JSDOM } from 'jsdom';
|
||||
import { DEFAULT_POLICIES } from '@/core/RoleService.js';
|
||||
import { Packed } from '@/misc/json-schema.js';
|
||||
import { entities } from '../src/postgres.js';
|
||||
import { loadConfig } from '../src/config.js';
|
||||
import type * as misskey from 'misskey-js';
|
||||
import { Packed } from '@/misc/json-schema.js';
|
||||
|
||||
export { server as startServer, jobQueue as startJobQueue } from '@/boot/common.js';
|
||||
|
||||
|
@ -123,9 +123,9 @@ export function randomString(chars = 'abcdefghijklmnopqrstuvwxyz0123456789', len
|
|||
function timeoutPromise<T>(p: Promise<T>, timeout: number): Promise<T> {
|
||||
return Promise.race([
|
||||
p,
|
||||
new Promise((reject) => {
|
||||
setTimeout(() => { reject(new Error('timed out')); }, timeout);
|
||||
}) as never,
|
||||
new Promise((reject) =>{
|
||||
setTimeout(() => { reject(new Error('timed out')); }, timeout)
|
||||
}) as never
|
||||
]);
|
||||
}
|
||||
|
||||
|
@ -343,7 +343,7 @@ export const uploadUrl = async (user: UserToken, url: string): Promise<Packed<'D
|
|||
'main',
|
||||
(msg) => msg.type === 'urlUploadFinished' && msg.body.marker === marker,
|
||||
(msg) => msg.body.file as Packed<'DriveFile'>,
|
||||
60 * 1000,
|
||||
60 * 1000
|
||||
);
|
||||
|
||||
await api('drive/files/upload-from-url', {
|
||||
|
@ -434,20 +434,20 @@ export const waitFire = async (user: UserToken, channel: string, trgr: () => any
|
|||
* @returns 時間内に正常に処理できた場合に通知からextractorを通した値を得る
|
||||
*/
|
||||
export function makeStreamCatcher<T>(
|
||||
user: UserToken,
|
||||
channel: string,
|
||||
cond: (message: Record<string, any>) => boolean,
|
||||
extractor: (message: Record<string, any>) => T,
|
||||
timeout = 60 * 1000): Promise<T> {
|
||||
let ws: WebSocket;
|
||||
user: UserToken,
|
||||
channel: string,
|
||||
cond: (message: Record<string, any>) => boolean,
|
||||
extractor: (message: Record<string, any>) => T,
|
||||
timeout = 60 * 1000): Promise<T> {
|
||||
let ws: WebSocket
|
||||
const p = new Promise<T>(async (resolve) => {
|
||||
ws = await connectStream(user, channel, (msg) => {
|
||||
if (cond(msg)) {
|
||||
resolve(extractor(msg));
|
||||
resolve(extractor(msg))
|
||||
}
|
||||
});
|
||||
}).finally(() => {
|
||||
ws.close();
|
||||
ws?.close();
|
||||
});
|
||||
|
||||
return timeoutPromise(p, timeout);
|
||||
|
|
|
@ -3,25 +3,28 @@
|
|||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import { resolve } from 'node:path';
|
||||
import { createRequire } from 'node:module';
|
||||
import { dirname, join, resolve } from 'node:path';
|
||||
import { fileURLToPath } from 'node:url';
|
||||
import type { StorybookConfig } from '@storybook/vue3-vite';
|
||||
import { type Plugin, mergeConfig } from 'vite';
|
||||
import turbosnap from 'vite-plugin-turbosnap';
|
||||
|
||||
const dirname = fileURLToPath(new URL('.', import.meta.url));
|
||||
const require = createRequire(import.meta.url);
|
||||
const _dirname = fileURLToPath(new URL('.', import.meta.url));
|
||||
|
||||
const config = {
|
||||
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|ts|tsx)'],
|
||||
addons: [
|
||||
'@storybook/addon-essentials',
|
||||
'@storybook/addon-interactions',
|
||||
'@storybook/addon-links',
|
||||
'@storybook/addon-storysource',
|
||||
resolve(dirname, '../node_modules/storybook-addon-misskey-theme'),
|
||||
getAbsolutePath('@storybook/addon-essentials'),
|
||||
getAbsolutePath('@storybook/addon-interactions'),
|
||||
getAbsolutePath('@storybook/addon-links'),
|
||||
getAbsolutePath('@storybook/addon-storysource'),
|
||||
getAbsolutePath('@storybook/addon-mdx-gfm'),
|
||||
resolve(_dirname, '../node_modules/storybook-addon-misskey-theme'),
|
||||
],
|
||||
framework: {
|
||||
name: '@storybook/vue3-vite',
|
||||
name: getAbsolutePath('@storybook/vue3-vite') as '@storybook/vue3-vite',
|
||||
options: {},
|
||||
},
|
||||
docs: {
|
||||
|
@ -37,10 +40,13 @@ const config = {
|
|||
}
|
||||
return mergeConfig(config, {
|
||||
plugins: [
|
||||
// XXX: https://github.com/IanVS/vite-plugin-turbosnap/issues/8
|
||||
(turbosnap as any as typeof turbosnap['default'])({
|
||||
rootDir: config.root ?? process.cwd(),
|
||||
}),
|
||||
{
|
||||
// XXX: https://github.com/IanVS/vite-plugin-turbosnap/issues/8
|
||||
...(turbosnap as any as typeof turbosnap['default'])({
|
||||
rootDir: config.root ?? process.cwd(),
|
||||
}),
|
||||
name: 'fake-turbosnap',
|
||||
},
|
||||
],
|
||||
build: {
|
||||
target: [
|
||||
|
@ -53,3 +59,7 @@ const config = {
|
|||
},
|
||||
} satisfies StorybookConfig;
|
||||
export default config;
|
||||
|
||||
function getAbsolutePath(value: string): string {
|
||||
return dirname(require.resolve(join(value, 'package.json')));
|
||||
}
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
import { addons } from '@storybook/addons';
|
||||
import { FORCE_REMOUNT } from '@storybook/core-events';
|
||||
import { addons } from '@storybook/preview-api';
|
||||
import { type Preview, setup } from '@storybook/vue3';
|
||||
import isChromatic from 'chromatic/isChromatic';
|
||||
import { initialize, mswDecorator } from 'msw-storybook-addon';
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
"build": "vite build",
|
||||
"storybook-dev": "nodemon --verbose --watch src --ext \"mdx,ts,vue\" --ignore \"*.stories.ts\" --exec \"pnpm build-storybook-pre && pnpm exec storybook dev -p 6006 --ci\"",
|
||||
"build-storybook-pre": "(tsc -p .storybook || echo done.) && node .storybook/generate.js && node .storybook/preload-locale.js && node .storybook/preload-theme.js",
|
||||
"build-storybook": "pnpm build-storybook-pre && storybook build",
|
||||
"build-storybook": "pnpm build-storybook-pre && storybook build --webpack-stats-json storybook-static",
|
||||
"chromatic": "chromatic",
|
||||
"test": "vitest --run --globals",
|
||||
"test-and-coverage": "vitest --run --coverage --globals",
|
||||
|
@ -78,24 +78,24 @@
|
|||
"devDependencies": {
|
||||
"@misskey-dev/eslint-plugin": "1.0.0",
|
||||
"@misskey-dev/summaly": "5.0.3",
|
||||
"@storybook/addon-actions": "7.6.10",
|
||||
"@storybook/addon-essentials": "7.6.10",
|
||||
"@storybook/addon-interactions": "7.6.10",
|
||||
"@storybook/addon-links": "7.6.10",
|
||||
"@storybook/addon-storysource": "7.6.10",
|
||||
"@storybook/addons": "7.6.10",
|
||||
"@storybook/blocks": "7.6.10",
|
||||
"@storybook/core-events": "7.6.10",
|
||||
"@storybook/jest": "0.2.3",
|
||||
"@storybook/manager-api": "7.6.10",
|
||||
"@storybook/preview-api": "7.6.10",
|
||||
"@storybook/react": "7.6.10",
|
||||
"@storybook/react-vite": "7.6.10",
|
||||
"@storybook/testing-library": "0.2.2",
|
||||
"@storybook/theming": "7.6.10",
|
||||
"@storybook/types": "7.6.10",
|
||||
"@storybook/vue3": "7.6.10",
|
||||
"@storybook/vue3-vite": "7.6.10",
|
||||
"@storybook/addon-actions": "8.0.0-beta.2",
|
||||
"@storybook/addon-essentials": "8.0.0-beta.2",
|
||||
"@storybook/addon-interactions": "8.0.0-beta.2",
|
||||
"@storybook/addon-links": "8.0.0-beta.2",
|
||||
"@storybook/addon-mdx-gfm": "8.0.0-beta.2",
|
||||
"@storybook/addon-storysource": "8.0.0-beta.2",
|
||||
"@storybook/blocks": "8.0.0-beta.2",
|
||||
"@storybook/components": "8.0.0-beta.2",
|
||||
"@storybook/core-events": "8.0.0-beta.2",
|
||||
"@storybook/manager-api": "8.0.0-beta.2",
|
||||
"@storybook/preview-api": "8.0.0-beta.2",
|
||||
"@storybook/react": "8.0.0-beta.2",
|
||||
"@storybook/react-vite": "8.0.0-beta.2",
|
||||
"@storybook/test": "8.0.0-beta.2",
|
||||
"@storybook/theming": "8.0.0-beta.2",
|
||||
"@storybook/types": "8.0.0-beta.2",
|
||||
"@storybook/vue3": "8.0.0-beta.2",
|
||||
"@storybook/vue3-vite": "8.0.0-beta.2",
|
||||
"@testing-library/vue": "8.0.2",
|
||||
"@types/escape-regexp": "0.0.3",
|
||||
"@types/estree": "1.0.5",
|
||||
|
@ -129,12 +129,12 @@
|
|||
"react": "18.2.0",
|
||||
"react-dom": "18.2.0",
|
||||
"start-server-and-test": "2.0.3",
|
||||
"storybook": "7.6.10",
|
||||
"storybook": "8.0.0-beta.2",
|
||||
"storybook-addon-misskey-theme": "github:misskey-dev/storybook-addon-misskey-theme",
|
||||
"vite-plugin-turbosnap": "1.0.3",
|
||||
"vitest": "0.34.6",
|
||||
"vitest-fetch-mock": "0.2.2",
|
||||
"vue-component-type-helpers": "^1.8.27",
|
||||
"vue-component-type-helpers": "1.8.27",
|
||||
"vue-eslint-parser": "9.4.2",
|
||||
"vue-tsc": "1.8.27"
|
||||
}
|
||||
|
|
|
@ -5,8 +5,7 @@
|
|||
|
||||
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
||||
import { action } from '@storybook/addon-actions';
|
||||
import { expect } from '@storybook/jest';
|
||||
import { userEvent, waitFor, within } from '@storybook/testing-library';
|
||||
import { expect, userEvent, waitFor, within } from '@storybook/test';
|
||||
import { StoryObj } from '@storybook/vue3';
|
||||
import { HttpResponse, http } from 'msw';
|
||||
import { userDetailed } from '../../.storybook/fakes.js';
|
||||
|
|
|
@ -123,7 +123,7 @@ function callback(response?: string) {
|
|||
function onReceivedMessage(message: MessageEvent) {
|
||||
if (message.data.token) {
|
||||
if (props.instanceUrl && new URL(message.origin).host === new URL(props.instanceUrl).host) {
|
||||
callback(<string>message.data.token);
|
||||
callback(message.data.token);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -4,8 +4,7 @@
|
|||
*/
|
||||
|
||||
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
||||
import { expect } from '@storybook/jest';
|
||||
import { userEvent, waitFor, within } from '@storybook/testing-library';
|
||||
import { expect, userEvent, waitFor, within } from '@storybook/test';
|
||||
import { StoryObj } from '@storybook/vue3';
|
||||
import { galleryPost } from '../../.storybook/fakes.js';
|
||||
import MkGalleryPostPreview from './MkGalleryPostPreview.vue';
|
||||
|
|
|
@ -4,8 +4,7 @@
|
|||
*/
|
||||
|
||||
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
||||
import { expect } from '@storybook/jest';
|
||||
import { userEvent, waitFor, within } from '@storybook/testing-library';
|
||||
import { expect, userEvent, waitFor, within } from '@storybook/test';
|
||||
import { StoryObj } from '@storybook/vue3';
|
||||
import { onBeforeUnmount } from 'vue';
|
||||
import MkSignupServerRules from './MkSignupDialog.rules.vue';
|
||||
|
|
|
@ -4,8 +4,7 @@
|
|||
*/
|
||||
|
||||
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
||||
import { expect } from '@storybook/jest';
|
||||
import { userEvent, within } from '@storybook/testing-library';
|
||||
import { expect, userEvent, within } from '@storybook/test';
|
||||
import { StoryObj } from '@storybook/vue3';
|
||||
import MkA from './MkA.vue';
|
||||
import { tick } from '@/scripts/test-utils.js';
|
||||
|
|
|
@ -5,8 +5,7 @@
|
|||
|
||||
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
||||
import { action } from '@storybook/addon-actions';
|
||||
import { expect } from '@storybook/jest';
|
||||
import { waitFor } from '@storybook/testing-library';
|
||||
import { expect, waitFor } from '@storybook/test';
|
||||
import { StoryObj } from '@storybook/vue3';
|
||||
import MkError from './MkError.vue';
|
||||
export const Default = {
|
||||
|
|
|
@ -5,8 +5,7 @@
|
|||
|
||||
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
||||
import { StoryObj } from '@storybook/vue3';
|
||||
import { within } from '@storybook/testing-library';
|
||||
import { expect } from '@storybook/jest';
|
||||
import { expect, within } from '@storybook/test';
|
||||
import MkMisskeyFlavoredMarkdown from './MkMisskeyFlavoredMarkdown.js';
|
||||
export const Default = {
|
||||
render(args) {
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
*/
|
||||
|
||||
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
||||
import { waitFor } from '@storybook/testing-library';
|
||||
import { waitFor } from '@storybook/test';
|
||||
import { StoryObj } from '@storybook/vue3';
|
||||
import MkPageHeader from './MkPageHeader.vue';
|
||||
export const Empty = {
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
*/
|
||||
|
||||
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
||||
import { expect } from '@storybook/jest';
|
||||
import { expect } from '@storybook/test';
|
||||
import { StoryObj } from '@storybook/vue3';
|
||||
import MkTime from './MkTime.vue';
|
||||
import { i18n } from '@/i18n.js';
|
||||
|
|
|
@ -4,8 +4,7 @@
|
|||
*/
|
||||
|
||||
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
||||
import { expect } from '@storybook/jest';
|
||||
import { userEvent, waitFor, within } from '@storybook/testing-library';
|
||||
import { expect, userEvent, waitFor, within } from '@storybook/test';
|
||||
import { StoryObj } from '@storybook/vue3';
|
||||
import { HttpResponse, http } from 'msw';
|
||||
import { commonHandlers } from '../../../.storybook/mocks.js';
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
*/
|
||||
|
||||
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
||||
import { expect } from '@storybook/jest';
|
||||
import { expect } from '@storybook/test';
|
||||
import { StoryObj } from '@storybook/vue3';
|
||||
import { userDetailed } from '../../../.storybook/fakes.js';
|
||||
import MkUserName from './MkUserName.vue';
|
||||
|
|
|
@ -17,7 +17,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
<div>{{ i18n.ts.youShouldUpgradeClient }}</div>
|
||||
<MkButton style="margin: 8px auto;" @click="reload">{{ i18n.ts.reload }}</MkButton>
|
||||
</template>
|
||||
<div><MkA to="/docs/general/troubleshooting" class="_link">{{ i18n.ts.troubleshooting }}</MkA></div>
|
||||
<div><MkLink url="https://misskey-hub.net/docs/for-users/resources/troubleshooting/" target="_blank">{{ i18n.ts.troubleshooting }}</MkLink></div>
|
||||
<div v-if="error" style="opacity: 0.7;">ERROR: {{ error }}</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -28,6 +28,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
import { ref, computed } from 'vue';
|
||||
import * as Misskey from 'misskey-js';
|
||||
import MkButton from '@/components/MkButton.vue';
|
||||
import MkLink from '@/components/MkLink.vue';
|
||||
import { version } from '@/config.js';
|
||||
import { misskeyApi } from '@/scripts/misskey-api.js';
|
||||
import { unisonReload } from '@/scripts/unison-reload.js';
|
||||
|
|
|
@ -101,7 +101,7 @@ const announcements = {
|
|||
limit: 10,
|
||||
};
|
||||
|
||||
const isTimelineAvailable = ref(instance.policies.ltlAvailable || instance.policies.gtlAvailable);
|
||||
const isTimelineAvailable = ref(instance.policies?.ltlAvailable || instance.policies?.gtlAvailable);
|
||||
|
||||
const showMenu = ref(false);
|
||||
const isDesktop = ref(window.innerWidth >= DESKTOP_THRESHOLD);
|
||||
|
|
|
@ -103,9 +103,6 @@ type AdminAvatarDecorationsUpdateRequest = operations['admin/avatar-decorations/
|
|||
// @public (undocumented)
|
||||
type AdminDeleteAccountRequest = operations['admin/delete-account']['requestBody']['content']['application/json'];
|
||||
|
||||
// @public (undocumented)
|
||||
type AdminDeleteAccountResponse = operations['admin/delete-account']['responses']['200']['content']['application/json'];
|
||||
|
||||
// @public (undocumented)
|
||||
type AdminDeleteAllFilesOfAUserRequest = operations['admin/delete-all-files-of-a-user']['requestBody']['content']['application/json'];
|
||||
|
||||
|
@ -482,9 +479,6 @@ type BubbleGameRankingResponse = operations['bubble-game/ranking']['responses'][
|
|||
// @public (undocumented)
|
||||
type BubbleGameRegisterRequest = operations['bubble-game/register']['requestBody']['content']['application/json'];
|
||||
|
||||
// @public (undocumented)
|
||||
type BubbleGameRegisterResponse = operations['bubble-game/register']['responses']['200']['content']['application/json'];
|
||||
|
||||
// @public (undocumented)
|
||||
type Channel = components['schemas']['Channel'];
|
||||
|
||||
|
@ -1210,7 +1204,6 @@ declare namespace entities {
|
|||
AdminUnsuspendUserRequest,
|
||||
AdminUpdateMetaRequest,
|
||||
AdminDeleteAccountRequest,
|
||||
AdminDeleteAccountResponse,
|
||||
AdminUpdateUserNoteRequest,
|
||||
AdminRolesCreateRequest,
|
||||
AdminRolesCreateResponse,
|
||||
|
@ -1408,6 +1401,7 @@ declare namespace entities {
|
|||
HashtagsUsersResponse,
|
||||
IResponse,
|
||||
I2faDoneRequest,
|
||||
I2faDoneResponse,
|
||||
I2faKeyDoneRequest,
|
||||
I2faKeyDoneResponse,
|
||||
I2faPasswordLessRequest,
|
||||
|
@ -1458,6 +1452,7 @@ declare namespace entities {
|
|||
IRegistryKeysWithTypeRequest,
|
||||
IRegistryKeysWithTypeResponse,
|
||||
IRegistryKeysRequest,
|
||||
IRegistryKeysResponse,
|
||||
IRegistryRemoveRequest,
|
||||
IRegistryScopesWithDomainResponse,
|
||||
IRegistrySetRequest,
|
||||
|
@ -1661,11 +1656,9 @@ declare namespace entities {
|
|||
FetchExternalResourcesResponse,
|
||||
RetentionResponse,
|
||||
BubbleGameRegisterRequest,
|
||||
BubbleGameRegisterResponse,
|
||||
BubbleGameRankingRequest,
|
||||
BubbleGameRankingResponse,
|
||||
ReversiCancelMatchRequest,
|
||||
ReversiCancelMatchResponse,
|
||||
ReversiGamesRequest,
|
||||
ReversiGamesResponse,
|
||||
ReversiMatchRequest,
|
||||
|
@ -1712,6 +1705,12 @@ declare namespace entities {
|
|||
EmojiDetailed,
|
||||
Flash,
|
||||
Signin,
|
||||
RoleCondFormulaLogics,
|
||||
RoleCondFormulaValueNot,
|
||||
RoleCondFormulaValueIsLocalOrRemote,
|
||||
RoleCondFormulaValueCreated,
|
||||
RoleCondFormulaFollowersOrFollowingOrNotes,
|
||||
RoleCondFormulaValue,
|
||||
RoleLite,
|
||||
Role,
|
||||
RolePolicies,
|
||||
|
@ -1972,6 +1971,9 @@ type HashtagsUsersResponse = operations['hashtags/users']['responses']['200']['c
|
|||
// @public (undocumented)
|
||||
type I2faDoneRequest = operations['i/2fa/done']['requestBody']['content']['application/json'];
|
||||
|
||||
// @public (undocumented)
|
||||
type I2faDoneResponse = operations['i/2fa/done']['responses']['200']['content']['application/json'];
|
||||
|
||||
// @public (undocumented)
|
||||
type I2faKeyDoneRequest = operations['i/2fa/key-done']['requestBody']['content']['application/json'];
|
||||
|
||||
|
@ -2143,6 +2145,9 @@ type IRegistryGetResponse = operations['i/registry/get']['responses']['200']['co
|
|||
// @public (undocumented)
|
||||
type IRegistryKeysRequest = operations['i/registry/keys']['requestBody']['content']['application/json'];
|
||||
|
||||
// @public (undocumented)
|
||||
type IRegistryKeysResponse = operations['i/registry/keys']['responses']['200']['content']['application/json'];
|
||||
|
||||
// @public (undocumented)
|
||||
type IRegistryKeysWithTypeRequest = operations['i/registry/keys-with-type']['requestBody']['content']['application/json'];
|
||||
|
||||
|
@ -2659,9 +2664,6 @@ type RetentionResponse = operations['retention']['responses']['200']['content'][
|
|||
// @public (undocumented)
|
||||
type ReversiCancelMatchRequest = operations['reversi/cancel-match']['requestBody']['content']['application/json'];
|
||||
|
||||
// @public (undocumented)
|
||||
type ReversiCancelMatchResponse = operations['reversi/cancel-match']['responses']['200']['content']['application/json'];
|
||||
|
||||
// @public (undocumented)
|
||||
type ReversiGameDetailed = components['schemas']['ReversiGameDetailed'];
|
||||
|
||||
|
@ -2701,6 +2703,24 @@ type ReversiVerifyResponse = operations['reversi/verify']['responses']['200']['c
|
|||
// @public (undocumented)
|
||||
type Role = components['schemas']['Role'];
|
||||
|
||||
// @public (undocumented)
|
||||
type RoleCondFormulaFollowersOrFollowingOrNotes = components['schemas']['RoleCondFormulaFollowersOrFollowingOrNotes'];
|
||||
|
||||
// @public (undocumented)
|
||||
type RoleCondFormulaLogics = components['schemas']['RoleCondFormulaLogics'];
|
||||
|
||||
// @public (undocumented)
|
||||
type RoleCondFormulaValue = components['schemas']['RoleCondFormulaValue'];
|
||||
|
||||
// @public (undocumented)
|
||||
type RoleCondFormulaValueCreated = components['schemas']['RoleCondFormulaValueCreated'];
|
||||
|
||||
// @public (undocumented)
|
||||
type RoleCondFormulaValueIsLocalOrRemote = components['schemas']['RoleCondFormulaValueIsLocalOrRemote'];
|
||||
|
||||
// @public (undocumented)
|
||||
type RoleCondFormulaValueNot = components['schemas']['RoleCondFormulaValueNot'];
|
||||
|
||||
// @public (undocumented)
|
||||
type RoleLite = components['schemas']['RoleLite'];
|
||||
|
||||
|
|
|
@ -85,7 +85,6 @@ import type {
|
|||
AdminUnsuspendUserRequest,
|
||||
AdminUpdateMetaRequest,
|
||||
AdminDeleteAccountRequest,
|
||||
AdminDeleteAccountResponse,
|
||||
AdminUpdateUserNoteRequest,
|
||||
AdminRolesCreateRequest,
|
||||
AdminRolesCreateResponse,
|
||||
|
@ -283,6 +282,7 @@ import type {
|
|||
HashtagsUsersResponse,
|
||||
IResponse,
|
||||
I2faDoneRequest,
|
||||
I2faDoneResponse,
|
||||
I2faKeyDoneRequest,
|
||||
I2faKeyDoneResponse,
|
||||
I2faPasswordLessRequest,
|
||||
|
@ -333,6 +333,7 @@ import type {
|
|||
IRegistryKeysWithTypeRequest,
|
||||
IRegistryKeysWithTypeResponse,
|
||||
IRegistryKeysRequest,
|
||||
IRegistryKeysResponse,
|
||||
IRegistryRemoveRequest,
|
||||
IRegistryScopesWithDomainResponse,
|
||||
IRegistrySetRequest,
|
||||
|
@ -536,11 +537,9 @@ import type {
|
|||
FetchExternalResourcesResponse,
|
||||
RetentionResponse,
|
||||
BubbleGameRegisterRequest,
|
||||
BubbleGameRegisterResponse,
|
||||
BubbleGameRankingRequest,
|
||||
BubbleGameRankingResponse,
|
||||
ReversiCancelMatchRequest,
|
||||
ReversiCancelMatchResponse,
|
||||
ReversiGamesRequest,
|
||||
ReversiGamesResponse,
|
||||
ReversiMatchRequest,
|
||||
|
@ -619,7 +618,7 @@ export type Endpoints = {
|
|||
'admin/suspend-user': { req: AdminSuspendUserRequest; res: EmptyResponse };
|
||||
'admin/unsuspend-user': { req: AdminUnsuspendUserRequest; res: EmptyResponse };
|
||||
'admin/update-meta': { req: AdminUpdateMetaRequest; res: EmptyResponse };
|
||||
'admin/delete-account': { req: AdminDeleteAccountRequest; res: AdminDeleteAccountResponse };
|
||||
'admin/delete-account': { req: AdminDeleteAccountRequest; res: EmptyResponse };
|
||||
'admin/update-user-note': { req: AdminUpdateUserNoteRequest; res: EmptyResponse };
|
||||
'admin/roles/create': { req: AdminRolesCreateRequest; res: AdminRolesCreateResponse };
|
||||
'admin/roles/delete': { req: AdminRolesDeleteRequest; res: EmptyResponse };
|
||||
|
@ -739,7 +738,7 @@ export type Endpoints = {
|
|||
'hashtags/trend': { req: EmptyRequest; res: HashtagsTrendResponse };
|
||||
'hashtags/users': { req: HashtagsUsersRequest; res: HashtagsUsersResponse };
|
||||
'i': { req: EmptyRequest; res: IResponse };
|
||||
'i/2fa/done': { req: I2faDoneRequest; res: EmptyResponse };
|
||||
'i/2fa/done': { req: I2faDoneRequest; res: I2faDoneResponse };
|
||||
'i/2fa/key-done': { req: I2faKeyDoneRequest; res: I2faKeyDoneResponse };
|
||||
'i/2fa/password-less': { req: I2faPasswordLessRequest; res: EmptyResponse };
|
||||
'i/2fa/register-key': { req: I2faRegisterKeyRequest; res: I2faRegisterKeyResponse };
|
||||
|
@ -780,7 +779,7 @@ export type Endpoints = {
|
|||
'i/registry/get-detail': { req: IRegistryGetDetailRequest; res: IRegistryGetDetailResponse };
|
||||
'i/registry/get': { req: IRegistryGetRequest; res: IRegistryGetResponse };
|
||||
'i/registry/keys-with-type': { req: IRegistryKeysWithTypeRequest; res: IRegistryKeysWithTypeResponse };
|
||||
'i/registry/keys': { req: IRegistryKeysRequest; res: EmptyResponse };
|
||||
'i/registry/keys': { req: IRegistryKeysRequest; res: IRegistryKeysResponse };
|
||||
'i/registry/remove': { req: IRegistryRemoveRequest; res: EmptyResponse };
|
||||
'i/registry/scopes-with-domain': { req: EmptyRequest; res: IRegistryScopesWithDomainResponse };
|
||||
'i/registry/set': { req: IRegistrySetRequest; res: EmptyResponse };
|
||||
|
@ -912,9 +911,9 @@ export type Endpoints = {
|
|||
'fetch-rss': { req: FetchRssRequest; res: FetchRssResponse };
|
||||
'fetch-external-resources': { req: FetchExternalResourcesRequest; res: FetchExternalResourcesResponse };
|
||||
'retention': { req: EmptyRequest; res: RetentionResponse };
|
||||
'bubble-game/register': { req: BubbleGameRegisterRequest; res: BubbleGameRegisterResponse };
|
||||
'bubble-game/register': { req: BubbleGameRegisterRequest; res: EmptyResponse };
|
||||
'bubble-game/ranking': { req: BubbleGameRankingRequest; res: BubbleGameRankingResponse };
|
||||
'reversi/cancel-match': { req: ReversiCancelMatchRequest; res: ReversiCancelMatchResponse };
|
||||
'reversi/cancel-match': { req: ReversiCancelMatchRequest; res: EmptyResponse };
|
||||
'reversi/games': { req: ReversiGamesRequest; res: ReversiGamesResponse };
|
||||
'reversi/match': { req: ReversiMatchRequest; res: ReversiMatchResponse };
|
||||
'reversi/invitations': { req: EmptyRequest; res: ReversiInvitationsResponse };
|
||||
|
|
|
@ -87,7 +87,6 @@ export type AdminSuspendUserRequest = operations['admin/suspend-user']['requestB
|
|||
export type AdminUnsuspendUserRequest = operations['admin/unsuspend-user']['requestBody']['content']['application/json'];
|
||||
export type AdminUpdateMetaRequest = operations['admin/update-meta']['requestBody']['content']['application/json'];
|
||||
export type AdminDeleteAccountRequest = operations['admin/delete-account']['requestBody']['content']['application/json'];
|
||||
export type AdminDeleteAccountResponse = operations['admin/delete-account']['responses']['200']['content']['application/json'];
|
||||
export type AdminUpdateUserNoteRequest = operations['admin/update-user-note']['requestBody']['content']['application/json'];
|
||||
export type AdminRolesCreateRequest = operations['admin/roles/create']['requestBody']['content']['application/json'];
|
||||
export type AdminRolesCreateResponse = operations['admin/roles/create']['responses']['200']['content']['application/json'];
|
||||
|
@ -285,6 +284,7 @@ export type HashtagsUsersRequest = operations['hashtags/users']['requestBody']['
|
|||
export type HashtagsUsersResponse = operations['hashtags/users']['responses']['200']['content']['application/json'];
|
||||
export type IResponse = operations['i']['responses']['200']['content']['application/json'];
|
||||
export type I2faDoneRequest = operations['i/2fa/done']['requestBody']['content']['application/json'];
|
||||
export type I2faDoneResponse = operations['i/2fa/done']['responses']['200']['content']['application/json'];
|
||||
export type I2faKeyDoneRequest = operations['i/2fa/key-done']['requestBody']['content']['application/json'];
|
||||
export type I2faKeyDoneResponse = operations['i/2fa/key-done']['responses']['200']['content']['application/json'];
|
||||
export type I2faPasswordLessRequest = operations['i/2fa/password-less']['requestBody']['content']['application/json'];
|
||||
|
@ -335,6 +335,7 @@ export type IRegistryGetResponse = operations['i/registry/get']['responses']['20
|
|||
export type IRegistryKeysWithTypeRequest = operations['i/registry/keys-with-type']['requestBody']['content']['application/json'];
|
||||
export type IRegistryKeysWithTypeResponse = operations['i/registry/keys-with-type']['responses']['200']['content']['application/json'];
|
||||
export type IRegistryKeysRequest = operations['i/registry/keys']['requestBody']['content']['application/json'];
|
||||
export type IRegistryKeysResponse = operations['i/registry/keys']['responses']['200']['content']['application/json'];
|
||||
export type IRegistryRemoveRequest = operations['i/registry/remove']['requestBody']['content']['application/json'];
|
||||
export type IRegistryScopesWithDomainResponse = operations['i/registry/scopes-with-domain']['responses']['200']['content']['application/json'];
|
||||
export type IRegistrySetRequest = operations['i/registry/set']['requestBody']['content']['application/json'];
|
||||
|
@ -538,11 +539,9 @@ export type FetchExternalResourcesRequest = operations['fetch-external-resources
|
|||
export type FetchExternalResourcesResponse = operations['fetch-external-resources']['responses']['200']['content']['application/json'];
|
||||
export type RetentionResponse = operations['retention']['responses']['200']['content']['application/json'];
|
||||
export type BubbleGameRegisterRequest = operations['bubble-game/register']['requestBody']['content']['application/json'];
|
||||
export type BubbleGameRegisterResponse = operations['bubble-game/register']['responses']['200']['content']['application/json'];
|
||||
export type BubbleGameRankingRequest = operations['bubble-game/ranking']['requestBody']['content']['application/json'];
|
||||
export type BubbleGameRankingResponse = operations['bubble-game/ranking']['responses']['200']['content']['application/json'];
|
||||
export type ReversiCancelMatchRequest = operations['reversi/cancel-match']['requestBody']['content']['application/json'];
|
||||
export type ReversiCancelMatchResponse = operations['reversi/cancel-match']['responses']['200']['content']['application/json'];
|
||||
export type ReversiGamesRequest = operations['reversi/games']['requestBody']['content']['application/json'];
|
||||
export type ReversiGamesResponse = operations['reversi/games']['responses']['200']['content']['application/json'];
|
||||
export type ReversiMatchRequest = operations['reversi/match']['requestBody']['content']['application/json'];
|
||||
|
|
|
@ -35,6 +35,12 @@ export type EmojiSimple = components['schemas']['EmojiSimple'];
|
|||
export type EmojiDetailed = components['schemas']['EmojiDetailed'];
|
||||
export type Flash = components['schemas']['Flash'];
|
||||
export type Signin = components['schemas']['Signin'];
|
||||
export type RoleCondFormulaLogics = components['schemas']['RoleCondFormulaLogics'];
|
||||
export type RoleCondFormulaValueNot = components['schemas']['RoleCondFormulaValueNot'];
|
||||
export type RoleCondFormulaValueIsLocalOrRemote = components['schemas']['RoleCondFormulaValueIsLocalOrRemote'];
|
||||
export type RoleCondFormulaValueCreated = components['schemas']['RoleCondFormulaValueCreated'];
|
||||
export type RoleCondFormulaFollowersOrFollowingOrNotes = components['schemas']['RoleCondFormulaFollowersOrFollowingOrNotes'];
|
||||
export type RoleCondFormulaValue = components['schemas']['RoleCondFormulaValue'];
|
||||
export type RoleLite = components['schemas']['RoleLite'];
|
||||
export type Role = components['schemas']['Role'];
|
||||
export type RolePolicies = components['schemas']['RolePolicies'];
|
||||
|
|
|
@ -3696,42 +3696,132 @@ export type components = {
|
|||
hardMutedWords: string[][];
|
||||
mutedInstances: string[] | null;
|
||||
notificationRecieveConfig: {
|
||||
app?: {
|
||||
note?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'list' | 'never';
|
||||
};
|
||||
quote?: {
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'list' | 'never';
|
||||
};
|
||||
reply?: {
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
follow?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'list' | 'never';
|
||||
};
|
||||
follow?: {
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'list' | 'never';
|
||||
};
|
||||
renote?: {
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
mention?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'list' | 'never';
|
||||
};
|
||||
mention?: {
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'list' | 'never';
|
||||
};
|
||||
reaction?: {
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
reply?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'list' | 'never';
|
||||
};
|
||||
pollEnded?: {
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'list' | 'never';
|
||||
};
|
||||
receiveFollowRequest?: {
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
renote?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'list' | 'never';
|
||||
};
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
quote?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
reaction?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
pollEnded?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
receiveFollowRequest?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
followRequestAccepted?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
roleAssigned?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
achievementEarned?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
app?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
test?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
};
|
||||
emailNotificationTypes: string[];
|
||||
achievements: {
|
||||
|
@ -4463,6 +4553,36 @@ export type components = {
|
|||
headers: Record<string, never>;
|
||||
success: boolean;
|
||||
};
|
||||
RoleCondFormulaLogics: {
|
||||
id: string;
|
||||
/** @enum {string} */
|
||||
type: 'and' | 'or';
|
||||
values: components['schemas']['RoleCondFormulaValue'][];
|
||||
};
|
||||
RoleCondFormulaValueNot: {
|
||||
id: string;
|
||||
/** @enum {string} */
|
||||
type: 'not';
|
||||
value: components['schemas']['RoleCondFormulaValue'];
|
||||
};
|
||||
RoleCondFormulaValueIsLocalOrRemote: {
|
||||
id: string;
|
||||
/** @enum {string} */
|
||||
type: 'isLocal' | 'isRemote';
|
||||
};
|
||||
RoleCondFormulaValueCreated: {
|
||||
id: string;
|
||||
/** @enum {string} */
|
||||
type: 'createdLessThan' | 'createdMoreThan';
|
||||
sec: number;
|
||||
};
|
||||
RoleCondFormulaFollowersOrFollowingOrNotes: {
|
||||
id: string;
|
||||
/** @enum {string} */
|
||||
type: 'followersLessThanOrEq' | 'followersMoreThanOrEq' | 'followingLessThanOrEq' | 'followingMoreThanOrEq' | 'notesLessThanOrEq' | 'notesMoreThanOrEq';
|
||||
value: number;
|
||||
};
|
||||
RoleCondFormulaValue: components['schemas']['RoleCondFormulaLogics'] | components['schemas']['RoleCondFormulaValueNot'] | components['schemas']['RoleCondFormulaValueIsLocalOrRemote'] | components['schemas']['RoleCondFormulaValueCreated'] | components['schemas']['RoleCondFormulaFollowersOrFollowingOrNotes'];
|
||||
RoleLite: {
|
||||
/**
|
||||
* Format: id
|
||||
|
@ -4489,7 +4609,7 @@ export type components = {
|
|||
updatedAt: string;
|
||||
/** @enum {string} */
|
||||
target: 'manual' | 'conditional';
|
||||
condFormula: Record<string, never>;
|
||||
condFormula: components['schemas']['RoleCondFormulaValue'];
|
||||
/** @example false */
|
||||
isPublic: boolean;
|
||||
/** @example false */
|
||||
|
@ -4548,11 +4668,11 @@ export type components = {
|
|||
user1Id: string;
|
||||
/** Format: id */
|
||||
user2Id: string;
|
||||
user1: components['schemas']['User'];
|
||||
user2: components['schemas']['User'];
|
||||
user1: components['schemas']['UserLite'];
|
||||
user2: components['schemas']['UserLite'];
|
||||
/** Format: id */
|
||||
winnerId: string | null;
|
||||
winner: components['schemas']['User'] | null;
|
||||
winner: components['schemas']['UserLite'] | null;
|
||||
/** Format: id */
|
||||
surrenderedUserId: string | null;
|
||||
/** Format: id */
|
||||
|
@ -4584,11 +4704,11 @@ export type components = {
|
|||
user1Id: string;
|
||||
/** Format: id */
|
||||
user2Id: string;
|
||||
user1: components['schemas']['User'];
|
||||
user2: components['schemas']['User'];
|
||||
user1: components['schemas']['UserLite'];
|
||||
user2: components['schemas']['UserLite'];
|
||||
/** Format: id */
|
||||
winnerId: string | null;
|
||||
winner: components['schemas']['User'] | null;
|
||||
winner: components['schemas']['UserLite'] | null;
|
||||
/** Format: id */
|
||||
surrenderedUserId: string | null;
|
||||
/** Format: id */
|
||||
|
@ -4600,7 +4720,7 @@ export type components = {
|
|||
canPutEverywhere: boolean;
|
||||
loopedBoard: boolean;
|
||||
timeLimitForEachTurn: number;
|
||||
logs: unknown[][];
|
||||
logs: number[][];
|
||||
map: string[];
|
||||
};
|
||||
};
|
||||
|
@ -6128,7 +6248,12 @@ export type operations = {
|
|||
size: number;
|
||||
comment: string | null;
|
||||
blurhash: string | null;
|
||||
properties: Record<string, never>;
|
||||
properties: {
|
||||
width?: number;
|
||||
height?: number;
|
||||
orientation?: number;
|
||||
avgColor?: string;
|
||||
};
|
||||
/** @example true */
|
||||
storedInternal: boolean | null;
|
||||
/** Format: url */
|
||||
|
@ -7189,7 +7314,12 @@ export type operations = {
|
|||
/** @description OK (with results) */
|
||||
200: {
|
||||
content: {
|
||||
'application/json': Record<string, never>;
|
||||
'application/json': {
|
||||
[key: string]: {
|
||||
count: number;
|
||||
size: number;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
/** @description Client error */
|
||||
|
@ -8185,7 +8315,162 @@ export type operations = {
|
|||
/** @description OK (with results) */
|
||||
200: {
|
||||
content: {
|
||||
'application/json': Record<string, never>;
|
||||
'application/json': {
|
||||
email: string | null;
|
||||
emailVerified: boolean;
|
||||
autoAcceptFollowed: boolean;
|
||||
noCrawle: boolean;
|
||||
preventAiLearning: boolean;
|
||||
alwaysMarkNsfw: boolean;
|
||||
autoSensitive: boolean;
|
||||
carefulBot: boolean;
|
||||
injectFeaturedNote: boolean;
|
||||
receiveAnnouncementEmail: boolean;
|
||||
mutedWords: (string | string[])[];
|
||||
mutedInstances: string[];
|
||||
notificationRecieveConfig: {
|
||||
note?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
follow?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
mention?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
reply?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
renote?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
quote?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
reaction?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
pollEnded?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
receiveFollowRequest?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
followRequestAccepted?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
roleAssigned?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
achievementEarned?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
app?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
test?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
};
|
||||
isModerator: boolean;
|
||||
isSilenced: boolean;
|
||||
isSuspended: boolean;
|
||||
isHibernated: boolean;
|
||||
lastActiveDate: string | null;
|
||||
moderationNote: string;
|
||||
signins: components['schemas']['Signin'][];
|
||||
policies: components['schemas']['RolePolicies'];
|
||||
roles: components['schemas']['Role'][];
|
||||
roleAssigns: ({
|
||||
createdAt: string;
|
||||
expiresAt: string | null;
|
||||
roleId: string;
|
||||
})[];
|
||||
};
|
||||
};
|
||||
};
|
||||
/** @description Client error */
|
||||
|
@ -8568,11 +8853,9 @@ export type operations = {
|
|||
};
|
||||
};
|
||||
responses: {
|
||||
/** @description OK (with results) */
|
||||
200: {
|
||||
content: {
|
||||
'application/json': unknown;
|
||||
};
|
||||
/** @description OK (without any results) */
|
||||
204: {
|
||||
content: never;
|
||||
};
|
||||
/** @description Client error */
|
||||
400: {
|
||||
|
@ -15567,9 +15850,13 @@ export type operations = {
|
|||
};
|
||||
};
|
||||
responses: {
|
||||
/** @description OK (without any results) */
|
||||
204: {
|
||||
content: never;
|
||||
/** @description OK (with results) */
|
||||
200: {
|
||||
content: {
|
||||
'application/json': {
|
||||
backupCodes: string[];
|
||||
};
|
||||
};
|
||||
};
|
||||
/** @description Client error */
|
||||
400: {
|
||||
|
@ -15737,7 +16024,7 @@ export type operations = {
|
|||
content: {
|
||||
'application/json': {
|
||||
rp: {
|
||||
id: string | null;
|
||||
id?: string;
|
||||
};
|
||||
user: {
|
||||
id: string;
|
||||
|
@ -16048,11 +16335,11 @@ export type operations = {
|
|||
'application/json': {
|
||||
/** Format: misskey:id */
|
||||
id: string;
|
||||
name: string;
|
||||
name?: string;
|
||||
/** Format: date-time */
|
||||
createdAt: string;
|
||||
/** Format: date-time */
|
||||
lastUsedAt: string;
|
||||
lastUsedAt?: string;
|
||||
permission: string[];
|
||||
}[];
|
||||
};
|
||||
|
@ -16122,7 +16409,7 @@ export type operations = {
|
|||
name: string;
|
||||
callbackUrl: string | null;
|
||||
permission: string[];
|
||||
isAuthorized: boolean;
|
||||
isAuthorized?: boolean;
|
||||
})[];
|
||||
};
|
||||
};
|
||||
|
@ -17743,7 +18030,10 @@ export type operations = {
|
|||
/** @description OK (with results) */
|
||||
200: {
|
||||
content: {
|
||||
'application/json': Record<string, never>;
|
||||
'application/json': {
|
||||
updatedAt: string;
|
||||
value: unknown;
|
||||
};
|
||||
};
|
||||
};
|
||||
/** @description Client error */
|
||||
|
@ -17854,7 +18144,9 @@ export type operations = {
|
|||
/** @description OK (with results) */
|
||||
200: {
|
||||
content: {
|
||||
'application/json': Record<string, never>;
|
||||
'application/json': {
|
||||
[key: string]: string;
|
||||
};
|
||||
};
|
||||
};
|
||||
/** @description Client error */
|
||||
|
@ -17906,9 +18198,11 @@ export type operations = {
|
|||
};
|
||||
};
|
||||
responses: {
|
||||
/** @description OK (without any results) */
|
||||
204: {
|
||||
content: never;
|
||||
/** @description OK (with results) */
|
||||
200: {
|
||||
content: {
|
||||
'application/json': string[];
|
||||
};
|
||||
};
|
||||
/** @description Client error */
|
||||
400: {
|
||||
|
@ -18385,7 +18679,134 @@ export type operations = {
|
|||
mutedWords?: (string[] | string)[];
|
||||
hardMutedWords?: (string[] | string)[];
|
||||
mutedInstances?: string[];
|
||||
notificationRecieveConfig?: Record<string, never>;
|
||||
notificationRecieveConfig?: {
|
||||
note?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
follow?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
mention?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
reply?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
renote?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
quote?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
reaction?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
pollEnded?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
receiveFollowRequest?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
followRequestAccepted?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
roleAssigned?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
achievementEarned?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
app?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
test?: OneOf<[{
|
||||
/** @enum {string} */
|
||||
type: 'all' | 'following' | 'follower' | 'mutualFollow' | 'never';
|
||||
}, {
|
||||
/** @enum {string} */
|
||||
type: 'list';
|
||||
/** Format: misskey:id */
|
||||
userListId: string;
|
||||
}]>;
|
||||
};
|
||||
emailNotificationTypes?: string[];
|
||||
alsoKnownAs?: string[];
|
||||
};
|
||||
|
@ -23578,12 +23999,12 @@ export type operations = {
|
|||
content: {
|
||||
'application/json': {
|
||||
/** Format: misskey:id */
|
||||
id: string;
|
||||
id?: string;
|
||||
required: boolean;
|
||||
string: string;
|
||||
default: string;
|
||||
string?: string;
|
||||
default?: string;
|
||||
/** @default hello */
|
||||
nullableDefault: string | null;
|
||||
nullableDefault?: string | null;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
@ -25694,18 +26115,16 @@ export type operations = {
|
|||
'application/json': {
|
||||
score: number;
|
||||
seed: string;
|
||||
logs: unknown[];
|
||||
logs: number[][];
|
||||
gameMode: string;
|
||||
gameVersion: number;
|
||||
};
|
||||
};
|
||||
};
|
||||
responses: {
|
||||
/** @description OK (with results) */
|
||||
200: {
|
||||
content: {
|
||||
'application/json': unknown;
|
||||
};
|
||||
/** @description OK (without any results) */
|
||||
204: {
|
||||
content: never;
|
||||
};
|
||||
/** @description Client error */
|
||||
400: {
|
||||
|
@ -25767,7 +26186,7 @@ export type operations = {
|
|||
/** Format: misskey:id */
|
||||
id: string;
|
||||
score: number;
|
||||
user: components['schemas']['UserLite'];
|
||||
user?: components['schemas']['UserLite'];
|
||||
}[];
|
||||
};
|
||||
};
|
||||
|
@ -25819,11 +26238,9 @@ export type operations = {
|
|||
};
|
||||
};
|
||||
responses: {
|
||||
/** @description OK (with results) */
|
||||
200: {
|
||||
content: {
|
||||
'application/json': unknown;
|
||||
};
|
||||
/** @description OK (without any results) */
|
||||
204: {
|
||||
content: never;
|
||||
};
|
||||
/** @description Client error */
|
||||
400: {
|
||||
|
@ -25940,9 +26357,13 @@ export type operations = {
|
|||
/** @description OK (with results) */
|
||||
200: {
|
||||
content: {
|
||||
'application/json': unknown;
|
||||
'application/json': components['schemas']['ReversiGameDetailed'];
|
||||
};
|
||||
};
|
||||
/** @description OK (without any results) */
|
||||
204: {
|
||||
content: never;
|
||||
};
|
||||
/** @description Client error */
|
||||
400: {
|
||||
content: {
|
||||
|
|
3355
pnpm-lock.yaml
3355
pnpm-lock.yaml
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue