mirror of
https://github.com/versia-pub/frontend.git
synced 2026-03-13 03:29:16 +01:00
feat: ✨ Add file uploads to composer
This commit is contained in:
parent
294740c97f
commit
027847aa03
27 changed files with 718 additions and 31 deletions
|
|
@ -1,4 +1,5 @@
|
|||
import { Client, type Token } from "@versia/client";
|
||||
import { toast } from "vue-sonner";
|
||||
|
||||
export const useClient = (
|
||||
customToken: MaybeRef<Token | null> = null,
|
||||
|
|
@ -11,13 +12,10 @@ export const useClient = (
|
|||
identity.value?.tokens.access_token ??
|
||||
undefined,
|
||||
(error) => {
|
||||
useEvent("notification:new", {
|
||||
title: "An error occured",
|
||||
type: "error",
|
||||
description:
|
||||
error.response.data.error ??
|
||||
toast.error(
|
||||
error.response.data.error ??
|
||||
"No error message provided",
|
||||
});
|
||||
);
|
||||
},
|
||||
),
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue