@@ -19,7 +19,6 @@ import AccessSecretStorageDialog, {
1919 type KeyParams ,
2020} from "./components/views/dialogs/security/AccessSecretStorageDialog" ;
2121import { ModuleRunner } from "./modules/ModuleRunner" ;
22- import QuestionDialog from "./components/views/dialogs/QuestionDialog" ;
2322import InteractiveAuthDialog from "./components/views/dialogs/InteractiveAuthDialog" ;
2423
2524// This stores the secret storage private keys in memory for the JS SDK. This is
@@ -50,17 +49,6 @@ export class AccessCancelledError extends Error {
5049 }
5150}
5251
53- async function confirmToDismiss ( ) : Promise < boolean > {
54- const [ sure ] = await Modal . createDialog ( QuestionDialog , {
55- title : _t ( "encryption|cancel_entering_passphrase_title" ) ,
56- description : _t ( "encryption|cancel_entering_passphrase_description" ) ,
57- danger : false ,
58- button : _t ( "action|go_back" ) ,
59- cancelButton : _t ( "action|cancel" ) ,
60- } ) . finished ;
61- return ! sure ;
62- }
63-
6452function makeInputToKey (
6553 keyInfo : SecretStorage . SecretStorageKeyDescription ,
6654) : ( keyParams : KeyParams ) => Promise < Uint8Array > {
@@ -134,17 +122,6 @@ async function getSecretStorageKey(
134122 return MatrixClientPeg . safeGet ( ) . secretStorage . checkKey ( key , keyInfo ) ;
135123 } ,
136124 } ,
137- /* className= */ undefined ,
138- /* isPriorityModal= */ false ,
139- /* isStaticModal= */ false ,
140- /* options= */ {
141- onBeforeClose : async ( reason ) : Promise < boolean > => {
142- if ( reason === "backgroundClick" ) {
143- return confirmToDismiss ( ) ;
144- }
145- return true ;
146- } ,
147- } ,
148125 ) ;
149126 const [ keyParams ] = await finished ;
150127 if ( ! keyParams ) {
0 commit comments