Merge branch 'develop'
This commit is contained in:
commit
94c362cbb6
@ -107,6 +107,7 @@ clickToShow: "クリックして表示"
|
|||||||
sensitive: "閲覧注意"
|
sensitive: "閲覧注意"
|
||||||
add: "追加"
|
add: "追加"
|
||||||
reaction: "リアクション"
|
reaction: "リアクション"
|
||||||
|
reactWithRenote: "ついでにRenoteする"
|
||||||
reactionSetting: "ピッカーに表示するリアクション"
|
reactionSetting: "ピッカーに表示するリアクション"
|
||||||
reactionSettingDescription2: "ドラッグして並び替え、クリックして削除、+を押して追加します。"
|
reactionSettingDescription2: "ドラッグして並び替え、クリックして削除、+を押して追加します。"
|
||||||
rememberNoteVisibility: "公開範囲を記憶する"
|
rememberNoteVisibility: "公開範囲を記憶する"
|
||||||
|
@ -837,6 +837,8 @@ emojiColor: "カラーコード"
|
|||||||
colorPicker: "カラーピッカー"
|
colorPicker: "カラーピッカー"
|
||||||
emojiApproval: "絵文字を登録"
|
emojiApproval: "絵文字を登録"
|
||||||
deckOld: "旧デッキ"
|
deckOld: "旧デッキ"
|
||||||
|
pakuruConfirm: "パクりますか?"
|
||||||
|
pakuru: "パクる"
|
||||||
|
|
||||||
|
|
||||||
_emailUnavailable:
|
_emailUnavailable:
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "misskey",
|
"name": "misskey",
|
||||||
"version": "12.119.0-simkey-v2",
|
"version": "12.119.0-simkey-v3",
|
||||||
"codename": "indigo",
|
"codename": "indigo",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
@ -74,6 +74,7 @@
|
|||||||
<button class="_button tab" :class="{ active: tab === 'unicode' }" @click="tab = 'unicode'"><i class="fas fa-leaf fa-fw"></i></button>
|
<button class="_button tab" :class="{ active: tab === 'unicode' }" @click="tab = 'unicode'"><i class="fas fa-leaf fa-fw"></i></button>
|
||||||
<button class="_button tab" :class="{ active: tab === 'tags' }" @click="tab = 'tags'"><i class="fas fa-hashtag fa-fw"></i></button>
|
<button class="_button tab" :class="{ active: tab === 'tags' }" @click="tab = 'tags'"><i class="fas fa-hashtag fa-fw"></i></button>
|
||||||
</div>
|
</div>
|
||||||
|
<MkSwitch v-if="props.asReactionPicker" v-model="withRenote" class="withRenote">{{ i18n.ts.reactWithRenote }}</MkSwitch>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -90,6 +91,7 @@ import { deviceKind } from '@/scripts/device-kind';
|
|||||||
import { emojiCategories, instance } from '@/instance';
|
import { emojiCategories, instance } from '@/instance';
|
||||||
import { i18n } from '@/i18n';
|
import { i18n } from '@/i18n';
|
||||||
import { defaultStore } from '@/store';
|
import { defaultStore } from '@/store';
|
||||||
|
import MkSwitch from '@/components/form/switch.vue';
|
||||||
|
|
||||||
const props = withDefaults(defineProps<{
|
const props = withDefaults(defineProps<{
|
||||||
showPinned?: boolean;
|
showPinned?: boolean;
|
||||||
@ -101,10 +103,11 @@ const props = withDefaults(defineProps<{
|
|||||||
});
|
});
|
||||||
|
|
||||||
const emit = defineEmits<{
|
const emit = defineEmits<{
|
||||||
(ev: 'chosen', v: string): void;
|
(ev: 'chosen', v: { reaction: string, withRenote: boolean } | string): void;
|
||||||
}>();
|
}>();
|
||||||
|
|
||||||
const search = ref<HTMLInputElement>();
|
const search = ref<HTMLInputElement>();
|
||||||
|
const withRenote = ref<boolean>(true);
|
||||||
const emojis = ref<HTMLDivElement>();
|
const emojis = ref<HTMLDivElement>();
|
||||||
|
|
||||||
const {
|
const {
|
||||||
@ -278,6 +281,7 @@ function focus() {
|
|||||||
function reset() {
|
function reset() {
|
||||||
if (emojis.value) emojis.value.scrollTop = 0;
|
if (emojis.value) emojis.value.scrollTop = 0;
|
||||||
q.value = '';
|
q.value = '';
|
||||||
|
withRenote.value = false; // 毎回Renoteをfalseに戻す
|
||||||
}
|
}
|
||||||
|
|
||||||
function getKey(emoji: string | Misskey.entities.CustomEmoji | UnicodeEmojiDef): string {
|
function getKey(emoji: string | Misskey.entities.CustomEmoji | UnicodeEmojiDef): string {
|
||||||
@ -294,7 +298,7 @@ function chosen(emoji: any, ev?: MouseEvent) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const key = getKey(emoji);
|
const key = getKey(emoji);
|
||||||
emit('chosen', key);
|
emit('chosen', (props.asReactionPicker) ? { reaction: key, withRenote: withRenote.value } : key);
|
||||||
|
|
||||||
// 最近使った絵文字更新
|
// 最近使った絵文字更新
|
||||||
if (!pinned.value.includes(key)) {
|
if (!pinned.value.includes(key)) {
|
||||||
@ -452,6 +456,10 @@ defineExpose({
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
> .withRenote {
|
||||||
|
padding: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
> .tabs {
|
> .tabs {
|
||||||
display: flex;
|
display: flex;
|
||||||
display: none;
|
display: none;
|
||||||
|
@ -51,8 +51,8 @@ const emit = defineEmits<{
|
|||||||
const modal = ref<InstanceType<typeof MkModal>>();
|
const modal = ref<InstanceType<typeof MkModal>>();
|
||||||
const picker = ref<InstanceType<typeof MkEmojiPicker>>();
|
const picker = ref<InstanceType<typeof MkEmojiPicker>>();
|
||||||
|
|
||||||
function chosen(emoji: any) {
|
function chosen(results: { reaction: string, withRenote: boolean }) {
|
||||||
emit('done', emoji);
|
emit('done', results);
|
||||||
modal.value?.close();
|
modal.value?.close();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -207,11 +207,17 @@ function reply(viaKeyboard = false): void {
|
|||||||
function react(viaKeyboard = false): void {
|
function react(viaKeyboard = false): void {
|
||||||
pleaseLogin();
|
pleaseLogin();
|
||||||
blur();
|
blur();
|
||||||
reactionPicker.show(reactButton.value, reaction => {
|
reactionPicker.show(reactButton.value, results => {
|
||||||
os.api('notes/reactions/create', {
|
os.api('notes/reactions/create', {
|
||||||
noteId: appearNote.id,
|
noteId: appearNote.id,
|
||||||
reaction: reaction,
|
reaction: results.reaction,
|
||||||
});
|
});
|
||||||
|
if (results.withRenote) {
|
||||||
|
os.api('notes/create', {
|
||||||
|
renoteId: appearNote.id,
|
||||||
|
isRenote: true,
|
||||||
|
});
|
||||||
|
}
|
||||||
}, () => {
|
}, () => {
|
||||||
focus();
|
focus();
|
||||||
});
|
});
|
||||||
|
@ -6,7 +6,6 @@
|
|||||||
<p><img :src="previewUrl" class="img" :alt="emojiName" /></p>
|
<p><img :src="previewUrl" class="img" :alt="emojiName" /></p>
|
||||||
</FormSection>
|
</FormSection>
|
||||||
<FormButton primary class="_formBlock" @click="uploadEmoji">{{ $ts.emojiApproval }}</FormButton>
|
<FormButton primary class="_formBlock" @click="uploadEmoji">{{ $ts.emojiApproval }}</FormButton>
|
||||||
<!-- <FormButton primary class="_formBlock" @click="preview">{{ $ts.emojiGenerate }}</FormButton> -->
|
|
||||||
<FormSection>
|
<FormSection>
|
||||||
<template #label>{{ $ts.settings }}</template>
|
<template #label>{{ $ts.settings }}</template>
|
||||||
<FormInput v-model="emojiName" class="_formBlock">
|
<FormInput v-model="emojiName" class="_formBlock">
|
||||||
|
@ -26,6 +26,22 @@ export function getNoteMenu(props: {
|
|||||||
|
|
||||||
const appearNote = isRenote ? props.note.renote as misskey.entities.Note : props.note;
|
const appearNote = isRenote ? props.note.renote as misskey.entities.Note : props.note;
|
||||||
|
|
||||||
|
function pakuru(): void {
|
||||||
|
os.confirm({
|
||||||
|
type: 'question',
|
||||||
|
text: i18n.ts.pakuruConfirm,
|
||||||
|
}).then(({ canceled }) => {
|
||||||
|
if (canceled) return;
|
||||||
|
const postData = {
|
||||||
|
text: appearNote.text,
|
||||||
|
cw: appearNote.cw ? appearNote.cw || '' : undefined,
|
||||||
|
localOnly: appearNote.localOnly,
|
||||||
|
visibility: appearNote.visibility,
|
||||||
|
}
|
||||||
|
os.api('notes/create', postData, undefined);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
function del(): void {
|
function del(): void {
|
||||||
os.confirm({
|
os.confirm({
|
||||||
type: 'warning',
|
type: 'warning',
|
||||||
@ -205,6 +221,11 @@ export function getNoteMenu(props: {
|
|||||||
action: unclip,
|
action: unclip,
|
||||||
}, null] : []
|
}, null] : []
|
||||||
),
|
),
|
||||||
|
{
|
||||||
|
icon: 'fas fa-copy',
|
||||||
|
text: i18n.ts.pakuru,
|
||||||
|
action: pakuru,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
icon: 'fas fa-copy',
|
icon: 'fas fa-copy',
|
||||||
text: i18n.ts.copyContent,
|
text: i18n.ts.copyContent,
|
||||||
|
@ -4,7 +4,7 @@ import { popup } from '@/os';
|
|||||||
class ReactionPicker {
|
class ReactionPicker {
|
||||||
private src: Ref<HTMLElement | null> = ref(null);
|
private src: Ref<HTMLElement | null> = ref(null);
|
||||||
private manualShowing = ref(false);
|
private manualShowing = ref(false);
|
||||||
private onChosen?: (reaction: string) => void;
|
private onChosen?: ({ reaction: string, withRenote: boolean }) => void;
|
||||||
private onClosed?: () => void;
|
private onClosed?: () => void;
|
||||||
|
|
||||||
constructor() {
|
constructor() {
|
||||||
@ -17,8 +17,8 @@ class ReactionPicker {
|
|||||||
asReactionPicker: true,
|
asReactionPicker: true,
|
||||||
manualShowing: this.manualShowing
|
manualShowing: this.manualShowing
|
||||||
}, {
|
}, {
|
||||||
done: reaction => {
|
done: results => {
|
||||||
this.onChosen!(reaction);
|
this.onChosen!({ reaction: results.reaction, withRenote: results.withRenote });
|
||||||
},
|
},
|
||||||
close: () => {
|
close: () => {
|
||||||
this.manualShowing.value = false;
|
this.manualShowing.value = false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user