fix
This commit is contained in:
parent
654f31bc83
commit
8683037677
1 changed files with 1 additions and 35 deletions
|
@ -16,37 +16,9 @@
|
|||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { computed } from 'vue';
|
||||
import XModalWindow from '@/components/MkModalWindow.vue';
|
||||
import XCheatSheet from '@/pages/mfm-cheat-sheet.vue';
|
||||
import { defaultStore } from '@/store';
|
||||
import { i18n } from '@/i18n';
|
||||
import { $i } from '@/account';
|
||||
import { instance } from '@/instance';
|
||||
|
||||
const isLocalTimelineAvailable =
|
||||
!instance.disableLocalTimeline ||
|
||||
($i != null && ($i.isModerator || $i.isAdmin));
|
||||
const isRecommendedTimelineAvailable =
|
||||
!instance.disableRecommendedTimeline ||
|
||||
($i != null && ($i.isModerator || $i.isAdmin));
|
||||
const isGlobalTimelineAvailable =
|
||||
!instance.disableGlobalTimeline ||
|
||||
($i != null && ($i.isModerator || $i.isAdmin));
|
||||
|
||||
let timelines = ['home'];
|
||||
|
||||
if (isLocalTimelineAvailable) {
|
||||
timelines.push('local');
|
||||
}
|
||||
if (isRecommendedTimelineAvailable) {
|
||||
timelines.push('recommended');
|
||||
}
|
||||
if (isLocalTimelineAvailable) {
|
||||
timelines.push('social');
|
||||
}
|
||||
if (isGlobalTimelineAvailable) {
|
||||
timelines.push('global');
|
||||
}
|
||||
|
||||
const emit = defineEmits<{
|
||||
(ev: 'done'): void;
|
||||
|
@ -55,13 +27,7 @@ const emit = defineEmits<{
|
|||
|
||||
const dialog = $ref<InstanceType<typeof XModalWindow>>();
|
||||
|
||||
const tutorial = computed({
|
||||
get() { return defaultStore.reactiveState.tutorial.value || 0; },
|
||||
set(value) { defaultStore.set('tutorial', value); },
|
||||
});
|
||||
|
||||
function close(res) {
|
||||
tutorial.value = -1;
|
||||
dialog.close();
|
||||
}
|
||||
</script>
|
||||
|
|
Loading…
Reference in a new issue