mirror of
https://github.com/luckfox-eng29/kvm.git
synced 2026-05-11 09:48:23 +02:00
Feature/usb config - Rebasing USB Config Changes on Dev Branch (#185)
* rebasing on dev branch * fixed formatting * fixed formatting * removed query params * moved usb settings to hardware setting * swapped from error to log * added fix for any change to product name now resulting in show the spinner as custom on page reload * formatting --------- Co-authored-by: JackTheRooster <adrian@rydeas.com> Co-authored-by: Adam Shiervani <adam.shiervani@gmail.com>
This commit is contained in:
@@ -526,6 +526,30 @@ export const useUpdateStore = create<UpdateState>(set => ({
|
||||
setUpdateErrorMessage: errorMessage => set({ updateErrorMessage: errorMessage }),
|
||||
}));
|
||||
|
||||
interface UsbConfigModalState {
|
||||
modalView:
|
||||
| "updateUsbConfig"
|
||||
| "updateUsbConfigSuccess";
|
||||
errorMessage: string | null;
|
||||
setModalView: (view: UsbConfigModalState["modalView"]) => void;
|
||||
setErrorMessage: (message: string | null) => void;
|
||||
}
|
||||
|
||||
export interface UsbConfigState {
|
||||
vendor_id: string;
|
||||
product_id: string;
|
||||
serial_number: string;
|
||||
manufacturer: string;
|
||||
product: string;
|
||||
}
|
||||
|
||||
export const useUsbConfigModalStore = create<UsbConfigModalState>(set => ({
|
||||
modalView: "updateUsbConfig",
|
||||
errorMessage: null,
|
||||
setModalView: view => set({ modalView: view }),
|
||||
setErrorMessage: message => set({ errorMessage: message }),
|
||||
}));
|
||||
|
||||
interface LocalAuthModalState {
|
||||
modalView:
|
||||
| "createPassword"
|
||||
|
||||
Reference in New Issue
Block a user