chore: fix instant form handling
This commit is contained in:
parent
47edc18931
commit
779bd244a6
@ -102,7 +102,7 @@ const props = withDefaults(defineProps<{
|
|||||||
initialLocalOnly?: boolean;
|
initialLocalOnly?: boolean;
|
||||||
initialVisibleUsers?: misskey.entities.User[];
|
initialVisibleUsers?: misskey.entities.User[];
|
||||||
initialNote?: misskey.entities.Note;
|
initialNote?: misskey.entities.Note;
|
||||||
share?: boolean;
|
instant?: boolean;
|
||||||
fixed?: boolean;
|
fixed?: boolean;
|
||||||
autofocus?: boolean;
|
autofocus?: boolean;
|
||||||
}>(), {
|
}>(), {
|
||||||
@ -641,7 +641,7 @@ onMounted(() => {
|
|||||||
|
|
||||||
nextTick(() => {
|
nextTick(() => {
|
||||||
// 書きかけの投稿を復元
|
// 書きかけの投稿を復元
|
||||||
if (!props.share && !props.mention && !props.specified) {
|
if (!props.instant && !props.mention && !props.specified) {
|
||||||
const draft = JSON.parse(localStorage.getItem('drafts') || '{}')[draftKey];
|
const draft = JSON.parse(localStorage.getItem('drafts') || '{}')[draftKey];
|
||||||
if (draft) {
|
if (draft) {
|
||||||
text = draft.data.text;
|
text = draft.data.text;
|
||||||
|
@ -182,6 +182,7 @@ function gravity() {
|
|||||||
function iLoveMisskey() {
|
function iLoveMisskey() {
|
||||||
os.post({
|
os.post({
|
||||||
initialText: 'I $[jelly ❤] #Misskey',
|
initialText: 'I $[jelly ❤] #Misskey',
|
||||||
|
instant: true,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
<XPostForm
|
<XPostForm
|
||||||
v-if="state === 'writing'"
|
v-if="state === 'writing'"
|
||||||
fixed
|
fixed
|
||||||
:share="true"
|
:instant="true"
|
||||||
:initial-text="initialText"
|
:initial-text="initialText"
|
||||||
:initial-visibility="visibility"
|
:initial-visibility="visibility"
|
||||||
:initial-files="files"
|
:initial-files="files"
|
||||||
|
Loading…
Reference in New Issue
Block a user