$new static method

$Value? $new(
  1. Runtime runtime,
  2. $Value? target,
  3. List<$Value?> args
)

Implementation

static $Value? $new(Runtime runtime, $Value? target, List<$Value?> args) {
  return $TextField.wrap(TextField(
    controller: args[0]?.$value,
    enabled: args[1]?.$value,
    style: args[2]?.$value,
    onChanged: args[3] == null
        ? null
        : (value) =>
            (args[3]! as EvalCallable).call(runtime, null, [$String(value)]),
    onSubmitted: args[4] == null
        ? null
        : (value) =>
            (args[4]! as EvalCallable).call(runtime, null, [$String(value)]),
  ));
}