How to use
A component to display a label with an optional icon. Allows you to configure the side the label should be displayed on.
use Hiker\Components\Label\Label; use Hiker\Components\Label\LabelPosition; Label::make('Date of birth') ->icon('calendar') ->position(LabelPosition::Left),
Available methods
__construct(string $text)
Construct the component with the given text.
Label::make('Date of birth');
position(Hiker\Components\Label\LabelPosition $position): static
Set the label's position relative to the component it is attached to.
use Hiker\Components\Label\LabelPosition; /** * Available positions * LabelPosition::Top * LabelPosition::Left * LabelPosition::Right */ Label::make() ->position(LabelPosition::Left);
Inherited methods
The Label component extends the base component and inherits all of its methods.
It also inherits the methods from the following traits: