Add MarkdownEditor component, asset image upload, and rich description editing
Introduce MarkdownEditor built on @mdxeditor/editor with headings, lists, links, quotes, image upload with drag-and-drop, and themed CSS integration. Add asset image upload API (routes, service, storage) and wire image upload into InlineEditor multiline mode, NewIssueDialog, NewProjectDialog, GoalDetail, IssueDetail, and ProjectDetail description fields. Tighten prompt template editor styling. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
14
ui/src/api/assets.ts
Normal file
14
ui/src/api/assets.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
import type { AssetImage } from "@paperclip/shared";
|
||||
import { api } from "./client";
|
||||
|
||||
export const assetsApi = {
|
||||
uploadImage: (companyId: string, file: File, namespace?: string) => {
|
||||
const form = new FormData();
|
||||
form.append("file", file);
|
||||
if (namespace && namespace.trim().length > 0) {
|
||||
form.append("namespace", namespace.trim());
|
||||
}
|
||||
return api.postForm<AssetImage>(`/companies/${companyId}/assets/images`, form);
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user