Skip to content

Commit 75bc243

Browse files
committed
Merge branch 'develop'
Signed-off-by: Pedro Lamas <pedrolamas@gmail.com>
2 parents d8cff51 + 501851f commit 75bc243

226 files changed

Lines changed: 5756 additions & 4768 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

eslint.config.mjs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@ export default defineConfigWithVueTs(
2626
'no-debugger': process.env.NODE_ENV === 'production' ? 'warn' : 'off',
2727
camelcase: 'off',
2828
'no-use-before-define': 'off',
29-
'vue/no-v-html': 'off',
30-
'vue/no-v-text-v-html-on-component': 'off',
3129
'@typescript-eslint/no-explicit-any': 'off',
3230
'@typescript-eslint/no-empty-object-type': 'off'
3331
}

package-lock.json

Lines changed: 171 additions & 170 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
"hls.js": "^1.6.15",
4545
"ipaddr.js": "^2.3.0",
4646
"jwt-decode": "^4.0.0",
47-
"lodash-es": "^4.17.21",
47+
"lodash-es": "^4.17.22",
4848
"marked": "^17.0.1",
4949
"marked-base-url": "^1.1.8",
5050
"md5": "^2.3.0",
@@ -81,28 +81,28 @@
8181
"@types/jsdom": "^27.0.0",
8282
"@types/lodash-es": "^4.17.12",
8383
"@types/md5": "^2.3.6",
84-
"@types/node": "^24.10.2",
84+
"@types/node": "^24.10.4",
8585
"@types/semver": "^7.7.1",
8686
"@types/sortablejs": "^1.15.9",
8787
"@vitejs/plugin-vue2": "^2.3.4",
8888
"@vue/eslint-config-typescript": "^14.6.0",
8989
"@vue/test-utils": "^1.3.6",
9090
"@vue/tsconfig": "~0.1.3",
91-
"eslint": "^9.39.1",
91+
"eslint": "^9.39.2",
9292
"eslint-plugin-regexp": "^2.10.0",
9393
"eslint-plugin-vue": "^9.33.0",
9494
"husky": "^9.1.7",
9595
"jsdom": "^27.3.0",
9696
"mockdate": "^3.0.5",
9797
"monaco-vscode-textmate-theme-converter": "^0.1.7",
9898
"neostandard": "^0.12.2",
99-
"rollup": "^4.53.3",
99+
"rollup": "^4.53.5",
100100
"sass": "~1.32.13",
101101
"skott": "^0.35.6",
102102
"standard-version": "^9.5.0",
103103
"svgo": "^4.0.0",
104104
"typescript": "^5.9.3",
105-
"typescript-eslint": "^8.49.0",
105+
"typescript-eslint": "^8.50.0",
106106
"unplugin-vue-components": "^30.0.0",
107107
"vite": "^6.4.1",
108108
"vite-plugin-checker": "^0.12.0",

public/img/mmu/mmu_EMU.svg

Lines changed: 4 additions & 6 deletions
Loading

src/api/httpClientActions.ts

Lines changed: 10 additions & 112 deletions
Original file line numberDiff line numberDiff line change
@@ -36,33 +36,13 @@ export const httpClientActions = {
3636

3737
accessInfoGet (options?: AxiosRequestConfig) {
3838
return this.get<{
39-
result: {
40-
default_source: string,
41-
available_sources: string[]
42-
}
39+
result: Moonraker.Authorization.InfoResponse
4340
}>('/access/info', options)
4441
},
4542

46-
accessRefreshJwtPost (refresh_token: string, options?: AxiosRequestConfig) {
47-
return this.post<{
48-
result: {
49-
username: string,
50-
token: string,
51-
action: 'user_jwt_refresh',
52-
source: string
53-
}
54-
}>('/access/refresh_jwt', { refresh_token }, options)
55-
},
56-
5743
accessLoginPost (username: string, password: string, source: string = 'moonraker', options?: AxiosRequestConfig) {
5844
return this.post<{
59-
result: {
60-
username: string,
61-
token: string,
62-
refresh_token: string,
63-
action: 'user_logged_in',
64-
source: string
65-
}
45+
result: Moonraker.Authorization.LoginResponse
6646
}>('/access/login', {
6747
username,
6848
password,
@@ -72,109 +52,31 @@ export const httpClientActions = {
7252

7353
accessLogoutPost (options?: AxiosRequestConfig) {
7454
return this.post<{
75-
result: {
76-
username: string,
77-
action: 'user_logged_out'
78-
}
55+
result: Moonraker.Authorization.LogoutResponse
7956
}>('access/logout', undefined, options)
8057
},
8158

8259
accessOneshotTokenGet (options?: AxiosRequestConfig) {
8360
return this.get<{
84-
result: string
61+
result: Moonraker.StringResponse
8562
}>('/access/oneshot_token', options)
8663
},
8764

8865
accessCurrentUserGet (options?: AxiosRequestConfig) {
8966
return this.get<{
90-
result: {
91-
username: string,
92-
source: string,
93-
created_on: number
94-
}
67+
result: Moonraker.Authorization.GetUserResponse
9568
}>('/access/user', options)
9669
},
9770

98-
accessUsersListGet (options?: AxiosRequestConfig) {
71+
serverDatabaseItemGet<T = unknown> (namespace: string, key?: string, options?: AxiosRequestConfig) {
9972
return this.get<{
100-
result: {
101-
users: Array<{
102-
username: string,
103-
source: string,
104-
created_on: number
105-
}>
106-
}
107-
}>('/access/users/list', options)
108-
},
109-
110-
accessUserPost (username: string, password: string, options?: AxiosRequestConfig) {
111-
return this.post<{
112-
result: {
113-
username: string,
114-
token: string,
115-
refresh_token: string,
116-
action: 'user_created',
117-
source: 'moonraker'
118-
}
119-
}>('/access/user', {
120-
username,
121-
password
122-
}, options)
123-
},
124-
125-
accessUserDelete (username: string, options?: AxiosRequestConfig) {
126-
return this.delete<{
127-
result: {
128-
username: string,
129-
action: 'user_deleted'
130-
}
131-
}>('/access/user', {
132-
...options,
133-
params: { username }
134-
})
135-
},
136-
137-
accessUserPasswordPost (password: string, new_password: string, options?: AxiosRequestConfig) {
138-
return this.post<{
139-
result: {
140-
username: string,
141-
action: 'user_password_reset'
142-
}
143-
}>('/access/user/password', {
144-
password,
145-
new_password
146-
}, options)
147-
},
148-
149-
accessApiKeyGet (options?: AxiosRequestConfig) {
150-
return this.get<{
151-
result: string
152-
}>('/access/api_key', options)
153-
},
154-
155-
accessApiKeyPost (options?: AxiosRequestConfig) {
156-
return this.post<{
157-
result: string
158-
}>('/access/api_key', undefined, options)
159-
},
160-
161-
serverDatabaseItemGet<T = unknown> (namespace: string, options?: AxiosRequestConfig) {
162-
return this.get<{
163-
result: {
164-
namespace: string,
165-
key: string,
166-
value: T
167-
}
168-
}>(`/server/database/item?namespace=${namespace}`, options)
73+
result: Moonraker.Database.GetItemResponse<T>
74+
}>(`/server/database/item?namespace=${namespace}${key != null ? `&key=${key}` : ''}`, options)
16975
},
17076

17177
serverDatabaseItemPost<T = unknown> (namespace: string, key: string, value: T, options?: AxiosRequestConfig) {
17278
return this.post<{
173-
result: {
174-
namespace: string,
175-
key: string,
176-
value: T
177-
}
79+
result: Moonraker.Database.PostItemResponse<T>
17880
}>('/server/database/item', {
17981
namespace,
18082
key,
@@ -184,11 +86,7 @@ export const httpClientActions = {
18486

18587
serverDatabaseItemDelete<T = unknown> (namespace: string, key: string, options?: AxiosRequestConfig) {
18688
return this.delete<{
187-
result: {
188-
namespace: string,
189-
key: string,
190-
value: T
191-
}
89+
result: Moonraker.Database.DeleteItemResponse<T>
19290
}>(`/server/database/item?namespace=${namespace}&key=${key}`, options)
19391
},
19492

0 commit comments

Comments
 (0)