-
Notifications
You must be signed in to change notification settings - Fork 370
feat: support message dialogs with 3 buttons #2641
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: v2
Are you sure you want to change the base?
Conversation
Package Changes Through e3fc76eThere are 7 changes which include dialog with minor, dialog-js with minor, single-instance with patch, fs with minor, fs-js with minor, http with patch, http-js with patch Planned Package VersionsThe following package releases are the planned based on the context of changes in this pull request.
Add another change file through the GitHub UI by following this link. Read about change files or the docs at github.com/jbolda/covector |
iOS is not tested ofc Windows and Android are tested and works. |
Co-authored-by: Tony <[email protected]>
@FabianLars or @lucasfernog can you test the iOS stuff? |
…uri-apps/plugins-workspace into feat/message-dialog-3-buttons
Can do but I'm kinda away over the weekend so please remind me on Monday if I or Lucas didn't get to it yet by then. |
don't worry about it, enjoy your weekend |
I started taking a look at it but got carried away to other things. I was trying to improve the return type but.. it's complicated |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Desktop code looks good, tested on Windows
export type MessageDialogButtonsYesNoCancel = { | ||
/** The Yes button. */ | ||
yes: string | ||
/** The No button. */ | ||
no: string | ||
/** The Cancel button. */ | ||
cancel: string | ||
} | ||
|
||
/** | ||
* The Ok and Cancel buttons of a message dialog. | ||
* | ||
* @since 2.3.0 | ||
*/ | ||
export type MessageDialogButtonsOkCancel = { | ||
/** The Ok button. */ | ||
ok: string | ||
/** The Cancel button. */ | ||
cancel: string | ||
} | ||
|
||
/** | ||
* The Ok button of a message dialog. | ||
* | ||
* @since 2.3.0 | ||
*/ | ||
export type MessageDialogButtonsOk = { | ||
/** The Ok button. */ | ||
ok: string | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a small suggestion, maybe we can change these to something like this, so typescript doesn't hint ok
and yes
at the same type
export type MessageDialogButtonsYesNoCancel = { | |
/** The Yes button. */ | |
yes: string | |
/** The No button. */ | |
no: string | |
/** The Cancel button. */ | |
cancel: string | |
} | |
/** | |
* The Ok and Cancel buttons of a message dialog. | |
* | |
* @since 2.3.0 | |
*/ | |
export type MessageDialogButtonsOkCancel = { | |
/** The Ok button. */ | |
ok: string | |
/** The Cancel button. */ | |
cancel: string | |
} | |
/** | |
* The Ok button of a message dialog. | |
* | |
* @since 2.3.0 | |
*/ | |
export type MessageDialogButtonsOk = { | |
/** The Ok button. */ | |
ok: string | |
} | |
export type MessageDialogButtonsYesNoCancel = { | |
/** The Yes button. */ | |
yes: string | |
/** The No button. */ | |
no: string | |
/** The Cancel button. */ | |
cancel: string | |
} | |
/** | |
* The Ok and Cancel buttons of a message dialog. | |
* | |
* @since 2.3.0 | |
*/ | |
export type MessageDialogButtonsOkCancel = { | |
/** The Ok button. */ | |
yes: string | |
/** The Cancel button. */ | |
cancel: string | |
} | |
/** | |
* The Ok button of a message dialog. | |
* | |
* @since 2.3.0 | |
*/ | |
export type MessageDialogButtonsOk = { | |
/** The Ok button. */ | |
yes: string | |
} |
closes #2640