-
-
Notifications
You must be signed in to change notification settings - Fork 831
Implement updated open dialog method of the Module API #11395
Implement updated open dialog method of the Module API #11395
Conversation
Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net>
Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net>
Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net>
Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net>
Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net>
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.
Looks good to me but I'll leave @richvdh to tick in case he has more context.
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.
Looks great otherwise!
@@ -61,11 +65,23 @@ export class ModuleUiDialog<P extends DialogProps, C extends DialogContent<P>> e | |||
this.props.onFinished(false); | |||
} | |||
|
|||
protected setOptions(options: ModuleUiDialogOptions): void { |
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.
could this be private?
contentProps: P; | ||
title: string; | ||
onFinished(ok?: boolean, model?: Awaited<ReturnType<DialogContent<P>["trySubmit"]>>): void; | ||
contentProps: Omit<P, keyof DialogProps> | undefined; |
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.
wonder if this should be called additionalContentProps
to distinguish it from the actual contentProps
cancel: this.cancel.bind(this), | ||
}; | ||
|
||
// Typescript isn't very happy understanding that `contentProps` satisfies `Omit<P, keyof DialogProps>` |
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.
// Typescript isn't very happy understanding that `contentProps` satisfies `Omit<P, keyof DialogProps>` | |
// Typescript isn't very happy understanding that `contentProps` satisfies `P` |
Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net>
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.
thank you!
No, it needs a review from someone on @matrix-org/element-web-app-team due to the changes in package.json. |
I resolved the merge conflict. |
* Implement updated open dialog method Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net> * Apply the review comments Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net> * Add unit tests for the module system dialog Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net> * Bump @matrix-org/react-sdk-module-api from 1.0.0 to 2.0.0 Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net> * Run prettier Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net> * Apply review comments Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net> --------- Signed-off-by: Dominik Henneke <dominik.henneke@nordeck.net>
Changes in [1.11.40](https://github.com/vector-im/element-web/releases/tag/v1.11.40) (2023-08-29) ================================================================================================= ## ✨ Features * Hide account deactivation for externally managed accounts ([\#11445](matrix-org/matrix-react-sdk#11445)). Fixes #26022. Contributed by @kerryarchibald. * OIDC: Redirect to delegated auth provider when signing out ([\#11432](matrix-org/matrix-react-sdk#11432)). Fixes #26000. Contributed by @kerryarchibald. * Disable 3pid fields in settings when `m.3pid_changes` capability is disabled ([\#11430](matrix-org/matrix-react-sdk#11430)). Fixes #25995. Contributed by @kerryarchibald. * OIDC: disable multi session signout for OIDC-aware servers in session manager ([\#11431](matrix-org/matrix-react-sdk#11431)). Contributed by @kerryarchibald. * Implement updated open dialog method of the Module API ([\#11395](matrix-org/matrix-react-sdk#11395)). Contributed by @dhenneke. * Polish & delabs `Exploring public spaces` feature ([\#11423](matrix-org/matrix-react-sdk#11423)). * Treat lists with a single empty item as plain text, not Markdown. ([\#6833](matrix-org/matrix-react-sdk#6833)). Fixes element-hq/element-meta#1265. * Allow managing room knocks ([\#11404](matrix-org/matrix-react-sdk#11404)). Contributed by @charlynguyen. * Pin the action buttons to the bottom of the scrollable dialogs ([\#11407](matrix-org/matrix-react-sdk#11407)). Contributed by @dhenneke. * Support Matrix 1.1 (drop legacy r0 versions) ([\#9819](matrix-org/matrix-react-sdk#9819)). ## 🐛 Bug Fixes * Fix path separator for Windows based systems ([\#25997](element-hq/element-web#25997)). * Fix instances of double translation and guard translation calls using typescript ([\#11443](matrix-org/matrix-react-sdk#11443)). * Fix export type "Current timeline" to match its behaviour to its name ([\#11426](matrix-org/matrix-react-sdk#11426)). Fixes #25988. * Fix Room Settings > Notifications file upload input being shown superfluously ([\#11415](matrix-org/matrix-react-sdk#11415)). Fixes #18392. * Simplify registration with email validation ([\#11398](matrix-org/matrix-react-sdk#11398)). Fixes #25832 #23601 and #22297. * correct home server URL ([\#11391](matrix-org/matrix-react-sdk#11391)). Fixes #25931. Contributed by @NSV1991. * Include non-matching DMs in Spotlight recent conversations when the DM's userId is part of the search API results ([\#11374](matrix-org/matrix-react-sdk#11374)). Contributed by @mgcm. * Fix useRoomMembers missing updates causing incorrect membership counts ([\#11392](matrix-org/matrix-react-sdk#11392)). Fixes #17096. * Show error when searching public rooms fails ([\#11378](matrix-org/matrix-react-sdk#11378)).
Implements the changes of matrix-org/matrix-react-sdk-module-api#14
Replaces the outdated PR #10536
Companion PR: element-hq/element-web#25986
Checklist
Type: enhancement
Here's what your changelog entry will look like:
✨ Features