canGate && $this->canResource && $this->autoDisable) { $hasPermission = Gate::allows($this->canGate, $this->canResource); if (! $hasPermission) { $this->disabled = true; } } if ($this->noStyle) { $this->defaultClass = ''; } } public function render(): View|Closure|string { return view('components.forms.button'); } }