Browse Source

💄 Use yellow color for dangerous buttons, keep red color for error display

master
KaKi87 2 months ago
parent
commit
46fb63a779
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      lib/tui/index.js

+ 2
- 2
lib/tui/index.js View File

@ -229,7 +229,7 @@ const getViews = screen => {
});
button({ content: 'Edit' }, undefined, selectedHostActions)
.on('press', () => callback({ action: 'edit', host: selectedHost }));
const removeButton = button({ content: 'Remove' }, { color: 'red' }, selectedHostActions);
const removeButton = button({ content: 'Remove' }, { color: 'yellow' }, selectedHostActions);
removeButton.on('press', () => {
if(removeButton.content === 'Remove'){
removeButton.setContent('Confirm');
@ -402,7 +402,7 @@ const getViews = screen => {
const actions = flexContainer({ top: n += 2 }, deleteAccountForm);
button({ content: 'Cancel' }, undefined, actions)
.on('press', () => callback({ isCancelled: true }));
const submitButton = button({ content: 'Submit' }, { color: 'red' }, actions)
const submitButton = button({ content: 'Submit' }, { color: 'yellow' }, actions)
submitButton.on('press', () => deleteAccountForm.submit());
const errorText = text(
{ top: n + 4 },


Loading…
Cancel
Save