From deb945d8821939f0a5cf58bfa9220ce82c2492d3 Mon Sep 17 00:00:00 2001 From: Carlos Tamagawa Date: Tue, 20 Feb 2024 14:37:38 -0300 Subject: [PATCH] feat(doc) Ajustes exemplo de radios --- docs/form.md | 108 +++++++++++++++++++++ src/View/Components/Forms/Inputs/Radio.php | 3 + 2 files changed, 111 insertions(+) diff --git a/docs/form.md b/docs/form.md index af90df9..60a9c3e 100644 --- a/docs/form.md +++ b/docs/form.md @@ -150,6 +150,114 @@ @endverbatim +## Radios + +@demo +
+ + + + + +
+
+ + + + + +
+
+ + + + + +
+@enddemo + +@verbatim + +```blade +
+ + + + + +
+
+ + + + + +
+
+ + + + + +
+``` + +@endverbatim + +## Inline Radios + +@demo +
+ + + + + +
+
+ + + + + +
+
+ + + + + +
+@enddemo + +@verbatim + +```blade +
+ + + + + +
+
+ + + + + +
+
+ + + + + +
+``` + +@endverbatim + ## Checkboxes @demo diff --git a/src/View/Components/Forms/Inputs/Radio.php b/src/View/Components/Forms/Inputs/Radio.php index 73c45f5..4c95a54 100644 --- a/src/View/Components/Forms/Inputs/Radio.php +++ b/src/View/Components/Forms/Inputs/Radio.php @@ -12,6 +12,7 @@ class Radio extends Component public function __construct( public string $name = '', public string $label = '', + public string $hint = '', public bool $inline = false, ) { $this->uuid = '-' . str(serialize($this)) @@ -42,6 +43,8 @@ public function render(): string|View {{ str($label)->lower()->ucfirst() }} @endif + + HTML; } }