@decky/ui 4.13.2 → 4.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -13,6 +13,7 @@ export interface ShowModalProps {
|
|
|
13
13
|
}
|
|
14
14
|
export interface ShowModalResult {
|
|
15
15
|
Close: () => void;
|
|
16
|
+
ClosedPromise: Promise<void>;
|
|
16
17
|
Update: (modal: ReactNode) => void;
|
|
17
18
|
}
|
|
18
19
|
export declare const showModal: (modal: ReactNode, parent?: EventTarget, props?: ShowModalProps) => ShowModalResult;
|
package/package.json
CHANGED
package/src/components/Item.ts
CHANGED
package/src/components/Modal.ts
CHANGED
|
@@ -21,6 +21,9 @@ export interface ShowModalResult {
|
|
|
21
21
|
// This method will not invoke any of the variations of "closeModal" callbacks!
|
|
22
22
|
Close: () => void;
|
|
23
23
|
|
|
24
|
+
// This property resolves as soon as the modal closes
|
|
25
|
+
ClosedPromise: Promise<void>;
|
|
26
|
+
|
|
24
27
|
// This method will replace the modal element completely and will not update the callback chains,
|
|
25
28
|
// meaning that "closeModal" and etc. will not automatically close the modal anymore (also "fnOnClose"
|
|
26
29
|
// will not be even called upon close anymore)! You have to manually call the "Close" method when, for example,
|