Simplify create key backup maze

The download / copy actions to store the new recovery key now send you forward
(the most likely case) with a Back button in case you wanted to also do the
other storing type.
This commit is contained in:
J. Ryan Stinnett 2019-01-04 11:16:06 -06:00
parent 2769e68169
commit 5419b4279b
2 changed files with 6 additions and 14 deletions

View file

@ -180,7 +180,7 @@ export default React.createClass({
}); });
}, },
_onKeepItSafeGotItClick: function() { _onKeepItSafeBackClick: function() {
this.setState({ this.setState({
phase: PHASE_SHOWKEY, phase: PHASE_SHOWKEY,
}); });
@ -342,8 +342,6 @@ export default React.createClass({
}, },
_renderPhaseShowKey: function() { _renderPhaseShowKey: function() {
const DialogButtons = sdk.getComponent('views.elements.DialogButtons');
let bodyText; let bodyText;
if (this.state.setPassPhrase) { if (this.state.setPassPhrase) {
bodyText = _t("As a safety net, you can use it to restore your encrypted message history if you forget your Recovery Passphrase."); bodyText = _t("As a safety net, you can use it to restore your encrypted message history if you forget your Recovery Passphrase.");
@ -372,12 +370,6 @@ export default React.createClass({
</div> </div>
</div> </div>
</p> </p>
<br />
<DialogButtons primaryButton={_t("I've made a copy")}
onPrimaryButtonClick={this._createBackup}
hasCancel={false}
disabled={!this.state.copied && !this.state.downloaded}
/>
</div>; </div>;
}, },
@ -402,10 +394,11 @@ export default React.createClass({
<li>{_t("<b>Save it</b> on a USB key or backup drive", {}, {b: s => <b>{s}</b>})}</li> <li>{_t("<b>Save it</b> on a USB key or backup drive", {}, {b: s => <b>{s}</b>})}</li>
<li>{_t("<b>Copy it</b> to your personal cloud storage", {}, {b: s => <b>{s}</b>})}</li> <li>{_t("<b>Copy it</b> to your personal cloud storage", {}, {b: s => <b>{s}</b>})}</li>
</ul> </ul>
<DialogButtons primaryButton={_t("Got it")} <DialogButtons primaryButton={_t("OK")}
onPrimaryButtonClick={this._onKeepItSafeGotItClick} onPrimaryButtonClick={this._createBackup}
hasCancel={false} hasCancel={false}>
/> <button onClick={this._onKeepItSafeBackClick}>{_t("Back")}</button>
</DialogButtons>
</div>; </div>;
}, },

View file

@ -1382,7 +1382,6 @@
"<b>Print it</b> and store it somewhere safe": "<b>Print it</b> and store it somewhere safe", "<b>Print it</b> and store it somewhere safe": "<b>Print it</b> and store it somewhere safe",
"<b>Save it</b> on a USB key or backup drive": "<b>Save it</b> on a USB key or backup drive", "<b>Save it</b> on a USB key or backup drive": "<b>Save it</b> on a USB key or backup drive",
"<b>Copy it</b> to your personal cloud storage": "<b>Copy it</b> to your personal cloud storage", "<b>Copy it</b> to your personal cloud storage": "<b>Copy it</b> to your personal cloud storage",
"Got it": "Got it",
"Backup created": "Backup created", "Backup created": "Backup created",
"Your encryption keys are now being backed up to your Homeserver.": "Your encryption keys are now being backed up to your Homeserver.", "Your encryption keys are now being backed up to your Homeserver.": "Your encryption keys are now being backed up to your Homeserver.",
"Without setting up Secure Message Recovery, you won't be able to restore your encrypted message history if you log out or use another device.": "Without setting up Secure Message Recovery, you won't be able to restore your encrypted message history if you log out or use another device.", "Without setting up Secure Message Recovery, you won't be able to restore your encrypted message history if you log out or use another device.": "Without setting up Secure Message Recovery, you won't be able to restore your encrypted message history if you log out or use another device.",