diff --git a/native/chat/settings/delete-thread.react.js b/native/chat/settings/delete-thread.react.js --- a/native/chat/settings/delete-thread.react.js +++ b/native/chat/settings/delete-thread.react.js @@ -143,7 +143,13 @@ @@ -167,6 +173,10 @@ }; submitDeletion = () => { + if (this.state.password === '') { + return; + } + this.props.dispatchActionPromise( deleteThreadActionTypes, this.deleteThread(), @@ -221,14 +231,19 @@ } const unboundStyles = { - deleteButton: { - backgroundColor: 'redButton', + baseDeleteButton: { borderRadius: 5, flex: 1, marginHorizontal: 24, marginVertical: 12, padding: 12, }, + deleteButtonEnabled: { + backgroundColor: 'redButton', + }, + deleteButtonDisabled: { + backgroundColor: 'disabledButton', + }, deleteText: { color: 'white', fontSize: 18, diff --git a/native/themes/colors.js b/native/themes/colors.js --- a/native/themes/colors.js +++ b/native/themes/colors.js @@ -14,6 +14,7 @@ blockQuoteBackground: '#D3D3D3', blockQuoteBorder: '#C0C0C0', codeBackground: '#DCDCDC', + disabledButton: '#D3D3D3', disconnectedBarBackground: '#FFFFFF', editButton: '#A4A4A2', floatingButtonBackground: '#999999', @@ -85,6 +86,7 @@ blockQuoteBackground: '#A9A9A9', blockQuoteBorder: '#808080', codeBackground: '#0A0A0A', + disabledButton: '#444444', disconnectedBarBackground: '#1D1D1D', editButton: '#5B5B5D', floatingButtonBackground: '#666666',