Merge branch 'develop' into fix-msg-room
This commit is contained in:
		
						commit
						6f9ccf6b02
					
				
					 7 changed files with 13 additions and 8 deletions
				
			
		| 
						 | 
				
			
			@ -102,7 +102,7 @@ const props = withDefaults(defineProps<{
 | 
			
		|||
	initialLocalOnly?: boolean;
 | 
			
		||||
	initialVisibleUsers?: misskey.entities.User[];
 | 
			
		||||
	initialNote?: misskey.entities.Note;
 | 
			
		||||
	share?: boolean;
 | 
			
		||||
	instant?: boolean;
 | 
			
		||||
	fixed?: boolean;
 | 
			
		||||
	autofocus?: boolean;
 | 
			
		||||
}>(), {
 | 
			
		||||
| 
						 | 
				
			
			@ -641,7 +641,7 @@ onMounted(() => {
 | 
			
		|||
 | 
			
		||||
	nextTick(() => {
 | 
			
		||||
		// 書きかけの投稿を復元
 | 
			
		||||
		if (!props.share && !props.mention && !props.specified) {
 | 
			
		||||
		if (!props.instant && !props.mention && !props.specified) {
 | 
			
		||||
			const draft = JSON.parse(localStorage.getItem('drafts') || '{}')[draftKey];
 | 
			
		||||
			if (draft) {
 | 
			
		||||
				text = draft.data.text;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -182,6 +182,7 @@ function gravity() {
 | 
			
		|||
function iLoveMisskey() {
 | 
			
		||||
	os.post({
 | 
			
		||||
		initialText: 'I $[jelly ❤] #Misskey',
 | 
			
		||||
		instant: true,
 | 
			
		||||
	});
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -24,7 +24,7 @@
 | 
			
		|||
<script lang="ts">
 | 
			
		||||
import { defineComponent, defineAsyncComponent } from 'vue';
 | 
			
		||||
import insertTextAtCursor from 'insert-text-at-cursor';
 | 
			
		||||
import * as autosize from 'autosize';
 | 
			
		||||
import autosize from 'autosize';
 | 
			
		||||
import { formatTimeString } from '@/scripts/format-time-string';
 | 
			
		||||
import { selectFile } from '@/scripts/select-file';
 | 
			
		||||
import * as os from '@/os';
 | 
			
		||||
| 
						 | 
				
			
			@ -76,7 +76,8 @@ export default defineComponent({
 | 
			
		|||
		autosize(this.$refs.text);
 | 
			
		||||
 | 
			
		||||
		// TODO: detach when unmount
 | 
			
		||||
		new Autocomplete(this.$refs.text, this, { model: 'text' });
 | 
			
		||||
		// TODO
 | 
			
		||||
		//new Autocomplete(this.$refs.text, this, { model: 'text' });
 | 
			
		||||
 | 
			
		||||
		// 書きかけの投稿を復元
 | 
			
		||||
		const draft = JSON.parse(localStorage.getItem('message_drafts') || '{}')[this.draftKey];
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -12,12 +12,11 @@
 | 
			
		|||
				</template>
 | 
			
		||||
 | 
			
		||||
				<template #defalut="{ items: messages }">
 | 
			
		||||
					<XList v-slot="{ item: message }" class="messages" :items="messages" direction="up" reversed>
 | 
			
		||||
					<XList v-if="messages.length > 0" v-slot="{ item: message }" class="messages" :items="messages" direction="up" reversed>
 | 
			
		||||
						<XMessage :key="message.id" :message="message" :is-group="group != null"/>
 | 
			
		||||
					</XList>
 | 
			
		||||
				</template>
 | 
			
		||||
			</MkPagination>
 | 
			
		||||
			<MkLoading v-if="fetching"/>
 | 
			
		||||
		</div>
 | 
			
		||||
		<footer>
 | 
			
		||||
			<div v-if="typers.length > 0" class="typers">
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -5,7 +5,7 @@
 | 
			
		|||
			<XPostForm
 | 
			
		||||
				v-if="state === 'writing'"
 | 
			
		||||
				fixed
 | 
			
		||||
				:share="true"
 | 
			
		||||
				:instant="true"
 | 
			
		||||
				:initial-text="initialText"
 | 
			
		||||
				:initial-visibility="visibility"
 | 
			
		||||
				:initial-files="files"
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue