refactor(frontend): os.tsに引き込んだscripts/api.tsの再exportをやめる (#12694)
* refactor(frontend): os.tsに引き込んだscripts/api.tsの再exportをやめる * fix * fix * renate to "misskeyApi" * rename file
This commit is contained in:
@@ -76,6 +76,7 @@ import MkInput from '@/components/MkInput.vue';
|
||||
import MkColorInput from '@/components/MkColorInput.vue';
|
||||
import { selectFile } from '@/scripts/select-file.js';
|
||||
import * as os from '@/os.js';
|
||||
import { misskeyApi } from '@/scripts/misskey-api.js';
|
||||
import { useRouter } from '@/router.js';
|
||||
import { definePageMetadata } from '@/scripts/page-metadata.js';
|
||||
import { i18n } from '@/i18n.js';
|
||||
@@ -105,7 +106,7 @@ watch(() => bannerId.value, async () => {
|
||||
if (bannerId.value == null) {
|
||||
bannerUrl.value = null;
|
||||
} else {
|
||||
bannerUrl.value = (await os.api('drive/files/show', {
|
||||
bannerUrl.value = (await misskeyApi('drive/files/show', {
|
||||
fileId: bannerId.value,
|
||||
})).url;
|
||||
}
|
||||
@@ -114,7 +115,7 @@ watch(() => bannerId.value, async () => {
|
||||
async function fetchChannel() {
|
||||
if (props.channelId == null) return;
|
||||
|
||||
channel.value = await os.api('channels/show', {
|
||||
channel.value = await misskeyApi('channels/show', {
|
||||
channelId: props.channelId,
|
||||
});
|
||||
|
||||
@@ -179,7 +180,7 @@ async function archive() {
|
||||
|
||||
if (canceled) return;
|
||||
|
||||
os.api('channels/update', {
|
||||
misskeyApi('channels/update', {
|
||||
channelId: props.channelId,
|
||||
isArchived: true,
|
||||
}).then(() => {
|
||||
|
Reference in New Issue
Block a user