variant) { self::VARIANT_SECONDARY => [ 'base' => 'bg-secondary text-text', 'hover' => 'hover:bg-secondary-dark', 'disabled' => 'disabled:bg-secondary', ], self::VARIANT_OUTLINE => [ 'base' => 'bg-surface border border-primary text-primary', 'hover' => 'hover:bg-primary hover:text-text-inverted', 'disabled' => 'disabled:bg-surface disabled:text-primary', ], default => [ 'base' => 'bg-primary text-text-inverted', 'hover' => 'hover:bg-primary-dark', 'disabled' => 'disabled:bg-primary' ] }; $baseDisabled = 'disabled:cursor-not-allowed disabled:opacity-60'; return trim( $base . ' ' . $classes['base'] . ' ' . $classes['hover'] . ' ' . $baseDisabled . ' ' . $classes['disabled'] ); } /** * Get the view / contents that represent the component. */ public function render(): View { return view('components.button'); } }