Fix import e2e key dialog staying disabled after paste (#10375)

This commit is contained in:
Michael Telatynski
2023-03-15 09:20:20 +00:00
committed by GitHub
parent ad65b4e444
commit 0c38bd7beb
3 changed files with 181 additions and 2 deletions
@@ -0,0 +1,113 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`ImportE2eKeysDialog renders 1`] = `
<DocumentFragment>
<div
data-focus-guard="true"
style="width: 1px; height: 0px; padding: 0px; overflow: hidden; position: fixed; top: 1px; left: 1px;"
tabindex="0"
/>
<div
aria-labelledby="mx_BaseDialog_title"
class="mx_importE2eKeysDialog mx_Dialog_fixedWidth"
data-focus-lock-disabled="false"
role="dialog"
>
<div
class="mx_Dialog_header mx_Dialog_headerWithCancel"
>
<h2
class="mx_Heading_h2 mx_Dialog_title"
id="mx_BaseDialog_title"
>
Import room keys
</h2>
<div
aria-label="Close dialog"
class="mx_AccessibleButton mx_Dialog_cancelButton"
role="button"
tabindex="0"
/>
</div>
<form>
<div
class="mx_Dialog_content"
>
<p>
This process allows you to import encryption keys that you had previously exported from another Matrix client. You will then be able to decrypt any messages that the other client could decrypt.
</p>
<p>
The export file will be protected with a passphrase. You should enter the passphrase here, to decrypt the file.
</p>
<div
class="error"
/>
<div
class="mx_E2eKeysDialog_inputTable"
>
<div
class="mx_E2eKeysDialog_inputRow"
>
<div
class="mx_E2eKeysDialog_inputLabel"
>
<label
for="importFile"
>
File to import
</label>
</div>
<div
class="mx_E2eKeysDialog_inputCell"
>
<input
id="importFile"
type="file"
/>
</div>
</div>
<div
class="mx_E2eKeysDialog_inputRow"
>
<div
class="mx_Field mx_Field_input"
>
<input
id="mx_Field_1"
label="Enter passphrase"
placeholder="Enter passphrase"
size="64"
type="password"
value=""
/>
<label
for="mx_Field_1"
>
Enter passphrase
</label>
</div>
</div>
</div>
</div>
<div
class="mx_Dialog_buttons"
>
<input
class="mx_Dialog_primary"
disabled=""
type="submit"
value="Import"
/>
<button>
Cancel
</button>
</div>
</form>
</div>
<div
data-focus-guard="true"
style="width: 1px; height: 0px; padding: 0px; overflow: hidden; position: fixed; top: 1px; left: 1px;"
tabindex="0"
/>
</DocumentFragment>
`;