このアカウントは、notestockで公開設定になっていません。
このアカウントは、notestockで公開設定になっていません。
このアカウントは、notestockで公開設定になっていません。
ちなみに、デフォのミスキーはAPI呼び出しが16回までに制限されているのでこのプラグインはほぼ使い物にならないです…
鯖缶の方はhttps://github.com/misskey-dev/misskey/blob/master/packages/frontend/src/scripts/aiscript/api.ts#L36 辺りを変更すると幸せになれるかも…?
ノートが表示される度に他のサーバーへ聞きにいく実装が良いとは言えないけども…
RE: https://mk.loupe.page/notes/9efz4luf80
リアクション情報を投稿元のサーバーから取得し置き換えるプラグイン v0.4
misskeyを使用しているサーバー全てを対象にしてみました。
今回からトークンは必要無いので設定不要です。
/// @ 0.12.4
### {
name: "投稿元サーバーのリアクションみるやつ"
id: "0013df5f-29a0-4b86-a979-9744abc461eb"
version: "0.4.0"
author: "@mikan@mk.loupe.page"
description: "リアクションを投稿元のサーバーから取得した物に置き換えます"
permissions: []
config: {
debug_note: {
type: 'boolean'
label: 'デバッグ: ノートオブジェクト'
description: 'ノートメニューにノートオブジェクトを表示するボタンを追加します'
default: false
}
}
}
let support = [
'misskey',
]
@reactionDomain(reactions domain) {
let new_obj = {}
each let kv Obj:kvs(reactions) {
Obj:set(new_obj kv[0].replace('@.' `@{domain}`) kv[1])
}
return new_obj
}
Plugin:register_note_view_interruptor(@(original) {
let note = match true {
original.renoteId != null && original.text == null && original.files.len == 0 => original.renote
* => original
}
if (!support.incl(note.user.instance.softwareName)) {
return original
}
if (note.uri == null) {
return original
}
let index_of = note.uri.index_of('/notes/')
let domain = note.uri.slice(0 index_of)
let id = note.uri.slice(index_of+7 99).split('/')[0]
if (id == null || id == '') {
return original
}
let nt = Mk:api(`{domain}/api/notes/show` {noteId: id})
if (nt != null) {
note.reactions = reactionDomain(nt.reactions domain.replace('https://' ''))
note.reactionEmojis = nt.reactionEmojis
}
return original
})
if (Plugin:config.debug_note) {
Plugin:register_note_action("ノートオブジェクトを表示" @(note) {
note.text = match true {
note.text != null => note.text.replace('$' '$').replace('<' '<').replace('>' '>').replace(':' ':')
* => 'null'
}
Mk:dialog(`ノートオブジェクト` Json:stringify(note))
})
}