Skip to content

Commit

Permalink
adding description of the new link navigate options
Browse files Browse the repository at this point in the history
  • Loading branch information
devajmeireles committed Jul 5, 2024
1 parent b10049a commit 4072fd2
Show file tree
Hide file tree
Showing 4 changed files with 47 additions and 24 deletions.
13 changes: 13 additions & 0 deletions app/Enums/Examples/Ui/Link.php
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,19 @@ class Link
:color="null" />
HTML;

public const NAVIGATE = <<<'HTML'
<!-- For `wire:navigate` -->
<x-link :href="route('route-name-goes-here')"
text="Navigate"
navigate />
<!-- For `wire:navigate.hover` -->
<x-link :href="route('route-name-goes-here')"
text="Navigate Hover"
navigate-hover />
HTML;


public const PERSONALIZATION = <<<'HTML'
TallStackUi::personalize()
->link()
Expand Down
47 changes: 24 additions & 23 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion contents/on-this-page.json
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,8 @@
"3": "Target Blank & Style Options",
"4": "Query String & Fragment Options",
"5": "Color Variations",
"6": "Without Color"
"6": "Without Color",
"7": "Livewire SPA Navigation"
},
"docs.ui.loading": {
"0": "Concept",
Expand Down
8 changes: 8 additions & 0 deletions resources/views/documentation/ui/link.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,4 +105,12 @@
</div>
</x-preview>
</x-section>
<x-section title="Livewire SPA Navigation" description="An option to easily add Livewire 3 navigation effects in SPA mode." new>
<x-preview language="blade" :contents="$navigate">
<div class="flex flex-col gap-x-2">
<x-link :href="route('documentation.ui.link')" text="Navigate" navigate />
<x-link :href="route('documentation.ui.link')" text="Navigate Hover" navigate-hover />
</div>
</x-preview>
</x-section>
</x-layout>

0 comments on commit 4072fd2

Please sign in to comment.