1
0
mirror of https://github.com/misskey-dev/misskey synced 2024-11-29 07:18:52 +09:00

fix client

This commit is contained in:
syuilo 2022-06-20 19:49:51 +09:00
parent 699f24f3dc
commit 8e20e27ff9
2 changed files with 194 additions and 192 deletions

View File

@ -1,4 +1,5 @@
<template><MkStickyContainer> <template>
<MkStickyContainer>
<template #header><MkPageHeader :actions="headerActions" :tabs="headerTabs"/></template> <template #header><MkPageHeader :actions="headerActions" :tabs="headerTabs"/></template>
<MkSpacer :content-max="600" :margin-min="16" :margin-max="32"> <MkSpacer :content-max="600" :margin-min="16" :margin-max="32">
<div v-if="instance" class="_formRoot"> <div v-if="instance" class="_formRoot">
@ -103,7 +104,8 @@
<FormLink :to="`https://${host}/manifest.json`" external style="margin-bottom: 8px;">manifest.json</FormLink> <FormLink :to="`https://${host}/manifest.json`" external style="margin-bottom: 8px;">manifest.json</FormLink>
</FormSection> </FormSection>
</div> </div>
</MkSpacer></MkStickyContainer> </MkSpacer>
</MkStickyContainer>
</template> </template>
<script lang="ts" setup> <script lang="ts" setup>
@ -169,7 +171,13 @@ function refreshMetadata() {
fetch(); fetch();
const headerActions = $computed(() => []); const headerActions = $computed(() => [{
text: `https://${props.host}`,
icon: 'fas fa-external-link-alt',
handler: () => {
window.open(`https://${props.host}`, '_blank');
},
}]);
const headerTabs = $computed(() => []); const headerTabs = $computed(() => []);
@ -177,13 +185,6 @@ definePageMetadata({
title: props.host, title: props.host,
icon: 'fas fa-info-circle', icon: 'fas fa-info-circle',
bg: 'var(--bg)', bg: 'var(--bg)',
actions: [{
text: `https://${props.host}`,
icon: 'fas fa-external-link-alt',
handler: () => {
window.open(`https://${props.host}`, '_blank');
},
}],
}); });
</script> </script>

View File

@ -1,4 +1,5 @@
<template><MkStickyContainer> <template>
<MkStickyContainer>
<template #header><MkPageHeader :actions="headerActions" :tabs="headerTabs"/></template> <template #header><MkPageHeader :actions="headerActions" :tabs="headerTabs"/></template>
<MkSpacer :content-max="700"> <MkSpacer :content-max="700">
<div class="jqqmcavi"> <div class="jqqmcavi">
@ -76,7 +77,8 @@
<MkTextarea v-model="script" class="_code"/> <MkTextarea v-model="script" class="_code"/>
</div> </div>
</div> </div>
</MkSpacer></MkStickyContainer> </MkSpacer>
</MkStickyContainer>
</template> </template>
<script lang="ts" setup> <script lang="ts" setup>
@ -408,21 +410,7 @@ init();
const headerActions = $computed(() => []); const headerActions = $computed(() => []);
const headerTabs = $computed(() => []); const headerTabs = $computed(() => [{
definePageMetadata(computed(() => {
let title = i18n.ts._pages.newPage;
if (props.initPageId) {
title = i18n.ts._pages.editPage;
}
else if (props.initPageName && props.initUser) {
title = i18n.ts._pages.readPage;
}
return {
title: title,
icon: 'fas fa-pencil-alt',
bg: 'var(--bg)',
tabs: [{
active: tab === 'settings', active: tab === 'settings',
title: i18n.ts._pages.pageSetting, title: i18n.ts._pages.pageSetting,
icon: 'fas fa-cog', icon: 'fas fa-cog',
@ -442,7 +430,20 @@ definePageMetadata(computed(() => {
title: i18n.ts.script, title: i18n.ts.script,
icon: 'fas fa-code', icon: 'fas fa-code',
onClick: () => { tab = 'script'; }, onClick: () => { tab = 'script'; },
}], }]);
definePageMetadata(computed(() => {
let title = i18n.ts._pages.newPage;
if (props.initPageId) {
title = i18n.ts._pages.editPage;
}
else if (props.initPageName && props.initUser) {
title = i18n.ts._pages.readPage;
}
return {
title: title,
icon: 'fas fa-pencil-alt',
bg: 'var(--bg)',
}; };
})); }));
</script> </script>