This commit is contained in:
syuilo 2019-02-27 05:31:16 +09:00
parent ec3a6d7097
commit 20de9a5e35
No known key found for this signature in database
GPG Key ID: BDC4C49D06AB9D69
3 changed files with 7 additions and 4 deletions

View File

@ -14,6 +14,7 @@ import wTips from './tips.vue';
import wNav from './nav.vue'; import wNav from './nav.vue';
import wHashtags from './hashtags.vue'; import wHashtags from './hashtags.vue';
import wInstance from './instance.vue'; import wInstance from './instance.vue';
import wPostForm from './post-form.vue';
Vue.component('mkw-analog-clock', wAnalogClock); Vue.component('mkw-analog-clock', wAnalogClock);
Vue.component('mkw-nav', wNav); Vue.component('mkw-nav', wNav);
@ -29,3 +30,4 @@ Vue.component('mkw-rss', wRss);
Vue.component('mkw-version', wVersion); Vue.component('mkw-version', wVersion);
Vue.component('mkw-hashtags', wHashtags); Vue.component('mkw-hashtags', wHashtags);
Vue.component('mkw-instance', wInstance); Vue.component('mkw-instance', wInstance);
Vue.component('mkw-post-form', wPostForm);

View File

@ -17,7 +17,7 @@
ref="text" ref="text"
v-autocomplete="{ model: 'text' }" v-autocomplete="{ model: 'text' }"
></textarea> ></textarea>
<button class="emoji" @click="emoji" ref="emoji"> <button class="emoji" @click="emoji" ref="emoji" v-if="!$root.isMobile">
<fa :icon="['far', 'laugh']"/> <fa :icon="['far', 'laugh']"/>
</button> </button>
</div> </div>
@ -161,7 +161,7 @@ export default define({
}, },
async emoji() { async emoji() {
const Picker = await import('../components/emoji-picker-dialog.vue').then(m => m.default); const Picker = await import('../../../desktop/views/components/emoji-picker-dialog.vue').then(m => m.default);
const button = this.$refs.emoji; const button = this.$refs.emoji;
const rect = button.getBoundingClientRect(); const rect = button.getBoundingClientRect();
const vm = this.$root.new(Picker, { const vm = this.$root.new(Picker, {
@ -186,6 +186,9 @@ export default define({
alert('Something happened'); alert('Something happened');
}).then(() => { }).then(() => {
this.posting = false; this.posting = false;
this.$nextTick(() => {
this.$refs.text.focus();
});
}); });
}, },

View File

@ -6,7 +6,6 @@ import wActivity from './activity.vue';
import wTrends from './trends.vue'; import wTrends from './trends.vue';
import wUsers from './users.vue'; import wUsers from './users.vue';
import wPolls from './polls.vue'; import wPolls from './polls.vue';
import wPostForm from './post-form.vue';
import wMessaging from './messaging.vue'; import wMessaging from './messaging.vue';
import wProfile from './profile.vue'; import wProfile from './profile.vue';
import wCustomize from './customize.vue'; import wCustomize from './customize.vue';
@ -17,7 +16,6 @@ Vue.component('mkw-activity', wActivity);
Vue.component('mkw-trends', wTrends); Vue.component('mkw-trends', wTrends);
Vue.component('mkw-users', wUsers); Vue.component('mkw-users', wUsers);
Vue.component('mkw-polls', wPolls); Vue.component('mkw-polls', wPolls);
Vue.component('mkw-post-form', wPostForm);
Vue.component('mkw-messaging', wMessaging); Vue.component('mkw-messaging', wMessaging);
Vue.component('mkw-profile', wProfile); Vue.component('mkw-profile', wProfile);
Vue.component('mkw-customize', wCustomize); Vue.component('mkw-customize', wCustomize);