diff --git a/crates/nu-command/src/platform/ansi/gradient.rs b/crates/nu-command/src/platform/ansi/gradient.rs index 76b99dfeb..cbfc337f5 100644 --- a/crates/nu-command/src/platform/ansi/gradient.rs +++ b/crates/nu-command/src/platform/ansi/gradient.rs @@ -2,8 +2,9 @@ use nu_ansi_term::{build_all_gradient_text, gradient::TargetGround, Gradient, Rg use nu_engine::CallExt; use nu_protocol::{ ast::Call, ast::CellPath, engine::Command, engine::EngineState, engine::Stack, Category, - Example, PipelineData, ShellError, Signature, Span, SyntaxShape, Value, + Example, PipelineData, ShellError, Signature, Span, SyntaxShape, Type, Value, }; + #[derive(Clone)] pub struct SubCommand; @@ -43,6 +44,12 @@ impl Command for SubCommand { SyntaxShape::CellPath, "for a data structure input, add a gradient to strings at the given cell paths", ) + .input_output_types(vec![ + (Type::String, Type::String), + (Type::Table(vec![]), Type::Table(vec![])), + ]) + .vectorizes_over_list(true) + .allow_variants_without_examples(true) .category(Category::Platform) }