Live update
i have a amount field that keep amount
and i have a button that pays the amount that has been entered
i want to live update the button lable to the input amount
TextInput::make('amount'),
protected function getFormActions(): array
{
return [
$this->getSaveFormAction()
->label(function(){
return "Pay Now $" . ;
})
]; }
})
]; }
5 Replies
Something like this
I am getting this error
Target [Closure] is not instantiable.
Did you use this
use Closure;
or you can also use function (callable $get)
both Closure and callable giving me error
TextInput::make('amount')->reactive()
->label('Amount')->required(),
protected function getFormActions(): array
{
return [
$this->getSaveFormAction()
->label(function () {
return "Pay Now $" . $this->data["amount"];
// dd("esdrtyu"); })
]; } now working ``` its working
// dd("esdrtyu"); })
]; } now working ``` its working