mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
feat(ui): use query to populate infill methods dropdown
- available infill methods is server state - remove it from client state, use the query to populate the dropdown - add listener to ensure the selected infill method is an available one
This commit is contained in:
@ -1,5 +1,5 @@
|
||||
import { api } from '..';
|
||||
import { AppVersion, AppConfig } from '../types';
|
||||
import { AppConfig, AppVersion } from '../types';
|
||||
|
||||
export const appInfoApi = api.injectEndpoints({
|
||||
endpoints: (build) => ({
|
||||
@ -8,12 +8,14 @@ export const appInfoApi = api.injectEndpoints({
|
||||
url: `app/version`,
|
||||
method: 'GET',
|
||||
}),
|
||||
keepUnusedDataFor: 86400000, // 1 day
|
||||
}),
|
||||
getAppConfig: build.query<AppConfig, void>({
|
||||
query: () => ({
|
||||
url: `app/config`,
|
||||
method: 'GET',
|
||||
}),
|
||||
keepUnusedDataFor: 86400000, // 1 day
|
||||
}),
|
||||
}),
|
||||
});
|
||||
|
Reference in New Issue
Block a user