-
Notifications
You must be signed in to change notification settings - Fork 3
/
themes.js
77 lines (76 loc) · 1.74 KB
/
themes.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
import {
clearApiCache,
invokeFetch
} from "./chunks/OZPJW5CV.js";
import "./chunks/Q6KIM6ZM.js";
import "./chunks/2ZQ3ZX7F.js";
// src/public/rest/themes.ts
var getThemes = async (options) => invokeFetch("themes", {
method: "get",
pathTemplate: "/api/v1/themes",
options
});
var uploadTheme = async (body, options) => invokeFetch("themes", {
method: "post",
pathTemplate: "/api/v1/themes",
body,
contentType: "multipart/form-data",
options
});
var deleteTheme = async (id, options) => invokeFetch("themes", {
method: "delete",
pathTemplate: "/api/v1/themes/{id}",
pathVariables: { id },
options
});
var getTheme = async (id, options) => invokeFetch("themes", {
method: "get",
pathTemplate: "/api/v1/themes/{id}",
pathVariables: { id },
options
});
var patchTheme = async (id, body, options) => invokeFetch("themes", {
method: "patch",
pathTemplate: "/api/v1/themes/{id}",
pathVariables: { id },
body,
contentType: "multipart/form-data",
options
});
var downloadTheme = async (id, options) => invokeFetch("themes", {
method: "get",
pathTemplate: "/api/v1/themes/{id}/file",
pathVariables: { id },
options
});
var downloadFileFromTheme = async (id, filepath, options) => invokeFetch("themes", {
method: "get",
pathTemplate: "/api/v1/themes/{id}/file/{filepath}",
pathVariables: { id, filepath },
options
});
function clearCache() {
return clearApiCache("themes");
}
var themesExport = {
getThemes,
uploadTheme,
deleteTheme,
getTheme,
patchTheme,
downloadTheme,
downloadFileFromTheme,
clearCache
};
var themes_default = themesExport;
export {
clearCache,
themes_default as default,
deleteTheme,
downloadFileFromTheme,
downloadTheme,
getTheme,
getThemes,
patchTheme,
uploadTheme
};