Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support for white bg color shell #346

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/elements/autocomplete.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ class AutocompletePrompt extends Prompt {
if (this.clearFirst && this.input.length > 0) {
this.reset();
} else {
this.done = this.exited = true;
this.done = this.exited = true;
this.aborted = false;
this.fire();
this.render();
Expand Down Expand Up @@ -239,7 +239,7 @@ class AutocompletePrompt extends Prompt {

this.outputText = [
style.symbol(this.done, this.aborted, this.exited),
color.bold(this.msg),
color.bold(color.reset(this.msg)),
style.delimiter(this.completing),
this.done && this.suggestions[this.select]
? this.suggestions[this.select].title
Expand Down
2 changes: 1 addition & 1 deletion lib/elements/autocompleteMultiselect.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ Filtered results for: ${this.inputValue ? this.inputValue : color.gray('Enter so

let prompt = [
style.symbol(this.done, this.aborted),
color.bold(this.msg),
color.bold(color.reset(this.msg)),
style.delimiter(false),
this.renderDoneOrInstructions()
].join(' ');
Expand Down
2 changes: 1 addition & 1 deletion lib/elements/confirm.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ class ConfirmPrompt extends Prompt {

this.outputText = [
style.symbol(this.done, this.aborted),
color.bold(this.msg),
color.bold(color.reset(this.msg)),
style.delimiter(this.done),
this.done ? (this.value ? this.yesMsg : this.noMsg)
: color.gray(this.initialValue ? this.yesOption : this.noOption)
Expand Down
2 changes: 1 addition & 1 deletion lib/elements/date.js
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ class DatePrompt extends Prompt {
// Print prompt
this.outputText = [
style.symbol(this.done, this.aborted),
color.bold(this.msg),
color.bold(color.reset(this.msg)),
style.delimiter(false),
this.parts.reduce((arr, p, idx) => arr.concat(idx === this.cursor && !this.done ? color.cyan().underline(p.toString()) : p), [])
.join('')
Expand Down
2 changes: 1 addition & 1 deletion lib/elements/multiselect.js
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ class MultiselectPrompt extends Prompt {
// print prompt
let prompt = [
style.symbol(this.done, this.aborted),
color.bold(this.msg),
color.bold(color.reset(this.msg)),
style.delimiter(false),
this.renderDoneOrInstructions()
].join(' ');
Expand Down
2 changes: 1 addition & 1 deletion lib/elements/number.js
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ class NumberPrompt extends Prompt {
// Print prompt
this.outputText = [
style.symbol(this.done, this.aborted),
color.bold(this.msg),
color.bold(color.reset(this.msg)),
style.delimiter(this.done),
!this.done || (!this.done && !this.placeholder)
? color[this.color]().underline(this.rendered) : this.rendered
Expand Down
2 changes: 1 addition & 1 deletion lib/elements/select.js
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ class SelectPrompt extends Prompt {
// Print prompt
this.outputText = [
style.symbol(this.done, this.aborted),
color.bold(this.msg),
color.bold(color.reset(this.msg)),
style.delimiter(false),
this.done ? this.selection.title : this.selection.disabled
? color.yellow(this.warn) : color.gray(this.hint)
Expand Down
4 changes: 2 additions & 2 deletions lib/elements/text.js
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ class TextPrompt extends Prompt {

this.outputText = [
style.symbol(this.done, this.aborted),
color.bold(this.msg),
color.bold(color.reset(this.msg)),
style.delimiter(this.done),
this.red ? color.red(this.rendered) : this.rendered
].join(` `);
Expand All @@ -205,4 +205,4 @@ class TextPrompt extends Prompt {
}
}

module.exports = TextPrompt;
module.exports = TextPrompt;
2 changes: 1 addition & 1 deletion lib/elements/toggle.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ class TogglePrompt extends Prompt {

this.outputText = [
style.symbol(this.done, this.aborted),
color.bold(this.msg),
color.bold(color.reset(this.msg)),
style.delimiter(this.done),
this.value ? this.inactive : color.cyan().underline(this.inactive),
color.gray('/'),
Expand Down