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:
parent
ea41cc6ec0
commit
fa9c4a19b9
191 changed files with 581 additions and 468 deletions
|
|
@ -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(() => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue