Merge branch 'develop' of https://github.com/misskey-dev/misskey into develop
This commit is contained in:
commit
c25a922928
|
@ -44,6 +44,8 @@
|
||||||
- Fix: テーマエディタが動作しない問題を修正
|
- Fix: テーマエディタが動作しない問題を修正
|
||||||
- Fix: チャンネルのハイライトページにノートが表示されない問題を修正
|
- Fix: チャンネルのハイライトページにノートが表示されない問題を修正
|
||||||
- Fix: カラムの名前が正しくリスト/チャンネルの名前にならない問題を修正
|
- Fix: カラムの名前が正しくリスト/チャンネルの名前にならない問題を修正
|
||||||
|
- Fix: 複数のメンションを1行に記述した場合に、サジェストが正しく表示されない問題を修正
|
||||||
|
- Fix: メンションとしての条件を満たしていても、特定の条件(`-`が含まれる場合など)で正しくサジェストされない問題を一部修正
|
||||||
|
|
||||||
### Server
|
### Server
|
||||||
- Enhance: ノートの削除処理の効率化
|
- Enhance: ノートの削除処理の効率化
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -1092,6 +1092,7 @@ prohibitedWordsDescription2: "AND 条件用空格分隔,正则表达式用斜
|
||||||
hiddenTags: "隐藏标签"
|
hiddenTags: "隐藏标签"
|
||||||
hiddenTagsDescription: "设定的标签将不会在时间线上显示。可使用换行来设置多个标签。"
|
hiddenTagsDescription: "设定的标签将不会在时间线上显示。可使用换行来设置多个标签。"
|
||||||
notesSearchNotAvailable: "帖子检索不可用"
|
notesSearchNotAvailable: "帖子检索不可用"
|
||||||
|
usersSearchNotAvailable: "用户检索不可用"
|
||||||
license: "许可信息"
|
license: "许可信息"
|
||||||
unfavoriteConfirm: "确定要取消收藏吗?"
|
unfavoriteConfirm: "确定要取消收藏吗?"
|
||||||
myClips: "我的便签"
|
myClips: "我的便签"
|
||||||
|
@ -1999,6 +2000,7 @@ _role:
|
||||||
descriptionOfRateLimitFactor: "值越小限制越少,值越大限制越多。"
|
descriptionOfRateLimitFactor: "值越小限制越少,值越大限制越多。"
|
||||||
canHideAds: "可以隐藏广告"
|
canHideAds: "可以隐藏广告"
|
||||||
canSearchNotes: "是否可以搜索帖子"
|
canSearchNotes: "是否可以搜索帖子"
|
||||||
|
canSearchUsers: "使用用户检索"
|
||||||
canUseTranslator: "使用翻译功能"
|
canUseTranslator: "使用翻译功能"
|
||||||
avatarDecorationLimit: "可添加头像挂件的最大个数"
|
avatarDecorationLimit: "可添加头像挂件的最大个数"
|
||||||
canImportAntennas: "允许导入天线"
|
canImportAntennas: "允许导入天线"
|
||||||
|
@ -3179,6 +3181,7 @@ _imageEffector:
|
||||||
title: "效果"
|
title: "效果"
|
||||||
addEffect: "添加效果"
|
addEffect: "添加效果"
|
||||||
discardChangesConfirm: "丢弃当前设置并退出?"
|
discardChangesConfirm: "丢弃当前设置并退出?"
|
||||||
|
nothingToConfigure: "还没有设置"
|
||||||
_fxs:
|
_fxs:
|
||||||
chromaticAberration: "色差"
|
chromaticAberration: "色差"
|
||||||
glitch: "故障"
|
glitch: "故障"
|
||||||
|
@ -3202,7 +3205,32 @@ _imageEffector:
|
||||||
size: "大小"
|
size: "大小"
|
||||||
color: "颜色"
|
color: "颜色"
|
||||||
opacity: "不透明度"
|
opacity: "不透明度"
|
||||||
|
normalize: "标准化"
|
||||||
|
amount: "数量"
|
||||||
lightness: "浅色"
|
lightness: "浅色"
|
||||||
|
contrast: "对比度"
|
||||||
|
hue: "色调"
|
||||||
|
brightness: "亮度"
|
||||||
|
saturation: "饱和度"
|
||||||
|
max: "最大值"
|
||||||
|
min: "最小值"
|
||||||
|
direction: "方向"
|
||||||
|
phase: "相位"
|
||||||
|
frequency: "频率"
|
||||||
|
strength: "强度"
|
||||||
|
glitchChannelShift: "错位"
|
||||||
|
seed: "种子"
|
||||||
|
redComponent: "红色成分"
|
||||||
|
greenComponent: "绿色成分"
|
||||||
|
blueComponent: "蓝色成分"
|
||||||
|
threshold: "阈值"
|
||||||
|
centerX: "中心 X "
|
||||||
|
centerY: "中心 Y"
|
||||||
|
zoomLinesSmoothing: "平滑"
|
||||||
|
zoomLinesSmoothingDescription: "平滑和集中线宽度设置不能同时使用。"
|
||||||
|
zoomLinesThreshold: "集中线宽度"
|
||||||
|
zoomLinesMaskSize: "中心直径"
|
||||||
|
zoomLinesBlack: "变成黑色"
|
||||||
drafts: "草稿"
|
drafts: "草稿"
|
||||||
_drafts:
|
_drafts:
|
||||||
select: "选择草稿"
|
select: "选择草稿"
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "misskey",
|
"name": "misskey",
|
||||||
"version": "2025.8.0-alpha.9",
|
"version": "2025.8.0-alpha.10",
|
||||||
"codename": "nasubi",
|
"codename": "nasubi",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
|
|
@ -78,7 +78,10 @@ export class Autocomplete {
|
||||||
const caretPos = Number(this.textarea.selectionStart);
|
const caretPos = Number(this.textarea.selectionStart);
|
||||||
const text = this.text.substring(0, caretPos).split('\n').pop()!;
|
const text = this.text.substring(0, caretPos).split('\n').pop()!;
|
||||||
|
|
||||||
const mentionIndex = text.lastIndexOf('@');
|
// メンションに含められる文字のみで構成された、最も末尾にある文字列を抽出
|
||||||
|
const mentionCandidate = text.split(/[^a-zA-Z0-9_@.\-]+/).pop()!;
|
||||||
|
|
||||||
|
const mentionIndex = mentionCandidate.lastIndexOf('@');
|
||||||
const hashtagIndex = text.lastIndexOf('#');
|
const hashtagIndex = text.lastIndexOf('#');
|
||||||
const emojiIndex = text.lastIndexOf(':');
|
const emojiIndex = text.lastIndexOf(':');
|
||||||
const mfmTagIndex = text.lastIndexOf('$');
|
const mfmTagIndex = text.lastIndexOf('$');
|
||||||
|
@ -97,7 +100,7 @@ export class Autocomplete {
|
||||||
|
|
||||||
const afterLastMfmParam = text.split(/\$\[[a-zA-Z]+/).pop();
|
const afterLastMfmParam = text.split(/\$\[[a-zA-Z]+/).pop();
|
||||||
|
|
||||||
const isMention = mentionIndex !== -1;
|
const maybeMention = mentionIndex !== -1;
|
||||||
const isHashtag = hashtagIndex !== -1;
|
const isHashtag = hashtagIndex !== -1;
|
||||||
const isMfmParam = mfmParamIndex !== -1 && afterLastMfmParam?.includes('.') && !afterLastMfmParam.includes(' ');
|
const isMfmParam = mfmParamIndex !== -1 && afterLastMfmParam?.includes('.') && !afterLastMfmParam.includes(' ');
|
||||||
const isMfmTag = mfmTagIndex !== -1 && !isMfmParam;
|
const isMfmTag = mfmTagIndex !== -1 && !isMfmParam;
|
||||||
|
@ -107,15 +110,21 @@ export class Autocomplete {
|
||||||
|
|
||||||
let opened = false;
|
let opened = false;
|
||||||
|
|
||||||
if (isMention && this.onlyType.includes('user')) {
|
if (maybeMention && this.onlyType.includes('user')) {
|
||||||
// ユーザのサジェスト中に@を入力すると、その位置から新たにユーザ名を取りなおそうとしてしまう
|
// ユーザのサジェスト中に@を入力すると、その位置から新たにユーザ名を取りなおそうとしてしまう
|
||||||
// この動きはリモートユーザのサジェストを阻害するので、@を検知したらその位置よりも前の@を探し、
|
// この動きはリモートユーザのサジェストを阻害するので、@を検知したらその位置よりも前の@を探し、
|
||||||
// ホスト名を含むリモートのユーザ名を全て拾えるようにする
|
// ホスト名を含むリモートのユーザ名を全て拾えるようにする
|
||||||
const mentionIndexAlt = text.lastIndexOf('@', mentionIndex - 1);
|
const mentionIndexAlt = mentionCandidate.lastIndexOf('@', mentionIndex - 1);
|
||||||
const username = mentionIndexAlt === -1
|
|
||||||
? text.substring(mentionIndex + 1)
|
// @が連続している場合、1つ目を無視する
|
||||||
: text.substring(mentionIndexAlt + 1);
|
const mentionIndexLeft = (mentionIndexAlt !== -1 && mentionIndexAlt !== mentionIndex - 1) ? mentionIndexAlt : mentionIndex;
|
||||||
if (username !== '' && username.match(/^[a-zA-Z0-9_@.]+$/)) {
|
|
||||||
|
// メンションを構成する条件を満たしているか確認する
|
||||||
|
const isMention = mentionIndexLeft === 0 || '_@.-'.includes(mentionCandidate[mentionIndexLeft - 1]);
|
||||||
|
|
||||||
|
if (isMention) {
|
||||||
|
const username = mentionCandidate.substring(mentionIndexLeft + 1);
|
||||||
|
if (username !== '' && username.match(/^[a-zA-Z0-9_@.\-]+$/)) {
|
||||||
this.open('user', username);
|
this.open('user', username);
|
||||||
opened = true;
|
opened = true;
|
||||||
} else if (username === '') {
|
} else if (username === '') {
|
||||||
|
@ -123,6 +132,7 @@ export class Autocomplete {
|
||||||
opened = true;
|
opened = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (isHashtag && !opened && this.onlyType.includes('hashtag')) {
|
if (isHashtag && !opened && this.onlyType.includes('hashtag')) {
|
||||||
const hashtag = text.substring(hashtagIndex + 1);
|
const hashtag = text.substring(hashtagIndex + 1);
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"name": "misskey-js",
|
"name": "misskey-js",
|
||||||
"version": "2025.8.0-alpha.9",
|
"version": "2025.8.0-alpha.10",
|
||||||
"description": "Misskey SDK for JavaScript",
|
"description": "Misskey SDK for JavaScript",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"main": "./built/index.js",
|
"main": "./built/index.js",
|
||||||
|
|
Loading…
Reference in New Issue