File tree 4 files changed +68
-0
lines changed
Http/Livewire/Documentation
resources/views/livewire/documentation
4 files changed +68
-0
lines changed Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ namespace App \Http \Livewire \Documentation ;
4
+
5
+ use App \View \Components \Layouts \Documentation ;
6
+ use Illuminate \Contracts \View \View ;
7
+ use Livewire \Component ;
8
+
9
+ class PasswordInput extends Component
10
+ {
11
+ public string $ passwordExample = <<<HTML
12
+ <x-inputs.password label="Secret 🙈" value="I love WireUI ❤️" />
13
+ HTML ;
14
+
15
+ public function render (): View
16
+ {
17
+ return view ('livewire.documentation.password-input ' )->layout (Documentation::class);
18
+ }
19
+ }
Original file line number Diff line number Diff line change @@ -34,6 +34,10 @@ public function getSidebarMenu(): array
34
34
'label ' => 'Inputs ' ,
35
35
'route ' => route ('docs.inputs ' ),
36
36
],
37
+ [
38
+ 'label ' => 'Password Input ' ,
39
+ 'route ' => route ('docs.inputs.password ' ),
40
+ ],
37
41
[
38
42
'label ' => 'Textarea ' ,
39
43
'route ' => route ('docs.textarea ' ),
Original file line number Diff line number Diff line change
1
+ <div class =" space-y-10" >
2
+ <x-slot name =" summary" >
3
+ <x-summary >
4
+ <x-summary .header href =" #inputs" label =" Password Inputs" >
5
+ <x-summary .item href =" #password-input" label =" Password Input" />
6
+ </x-summary .header >
7
+
8
+ <x-summary .header href =" #input-options" label =" Inputs Options" />
9
+ </x-summary >
10
+ </x-slot >
11
+
12
+ <div >
13
+ <x-section .title id =" inputs" title =" Password Input" />
14
+
15
+ <div class =" mt-5 prose text-gray-500 xl:max-w-4xl xl:mb-8 dark:text-gray-400" >
16
+ This component will add an toggle button to see/hide the password value
17
+ </div >
18
+ </div >
19
+
20
+ <div class =" space-y-4" >
21
+ <x-code-preview
22
+ title =" Password Input"
23
+ href =" #password-input"
24
+ id =" password-input"
25
+ language =" blade"
26
+ :code =" $passwordExample" >
27
+ <div class =" max-w-sm mx-auto" >
28
+ <x-inputs .password label =" Secret 🙈" value =" I love WireUI ❤️" />
29
+ </div >
30
+ </x-code-preview >
31
+ </div >
32
+
33
+ <div id =" input-options" >
34
+ <x-section .title href =" #input-options" title =" Input Options" />
35
+
36
+ <div class =" mt-5 prose xl:max-w-3xl xl:mb-8 text-gray-500" >
37
+ <p >
38
+ The phone input accepts all
39
+ <a class =" dark:text-secondary-500" href =" {{ route (' docs.inputs' ) } } #input-options" >input</a >
40
+ options and slots
41
+ </p >
42
+ </div >
43
+ </div >
44
+ </div >
Original file line number Diff line number Diff line change 25
25
Route::get ('notifications ' , Documentation \Notifications::class)->name ('notifications ' );
26
26
Route::get ('hooks ' , Documentation \Hooks::class)->name ('hooks ' );
27
27
Route::get ('inputs ' , Documentation \Inputs::class)->name ('inputs ' );
28
+ Route::get ('inputs-password ' , Documentation \PasswordInput::class)->name ('inputs.password ' );
28
29
Route::get ('errors ' , Documentation \Errors::class)->name ('errors ' );
29
30
Route::get ('maskable-inputs ' , Documentation \MaskableInput::class)->name ('maskable-inputs ' );
30
31
Route::get ('phone-input ' , Documentation \PhoneInput::class)->name ('phone-input ' );
You can’t perform that action at this time.
0 commit comments