File tree Expand file tree Collapse file tree 5 files changed +14
-10
lines changed
example/example-website/src/routes Expand file tree Collapse file tree 5 files changed +14
-10
lines changed Original file line number Diff line number Diff line change 11<script lang =" ts" >
22 import ' ../app.css' ;
33 import { page } from ' $app/state' ;
4+ import { base } from ' $app/paths' ;
45 import { onMount } from ' svelte' ;
56
67 let { children } = $props ();
78 let mobileMenuOpen = $state (false );
89
910 const navigation = [
10- { name: ' Home' , href: ' /' },
11- { name: ' Features' , href: ' /features' },
12- { name: ' Demo' , href: ' /demo' },
11+ { name: ' Home' , href: base || ' /' },
12+ { name: ' Features' , href: ` ${ base } /features` },
13+ { name: ' Demo' , href: ` ${ base } /demo` },
1314 {
1415 name: ' Documentation' ,
1516 href: ' https://pub.dev/documentation/dart_imagehash/latest/' ,
389390 <div class =" mx-auto max-w-7xl px-4 sm:px-6 lg:px-8" >
390391 <div class =" flex h-16 items-center justify-between" >
391392 <div class =" flex items-center" >
392- <a href =" / " class =" gradient-text text-2xl font-bold" > dart_imagehash </a >
393+ <a href ={ base || ' / ' } class =" gradient-text text-2xl font-bold" > dart_imagehash </a >
393394 </div >
394395
395396 <!-- Desktop Navigation -->
Original file line number Diff line number Diff line change 11<script lang =" ts" >
22 import { onMount } from ' svelte' ;
3+ import { base } from ' $app/paths' ;
34
45 let isVisible = $state (false );
56
8283 Get Started
8384 </a >
8485 <a
85- href =" /demo"
86+ href =" { base } /demo"
8687 class =" rounded-lg border border-white/20 bg-white/10 px-8 py-3 font-semibold text-white backdrop-blur-sm transition-all duration-300 hover:bg-white/20"
8788 >
8889 Try Demo
Original file line number Diff line number Diff line change 11<script lang =" ts" >
2- import { onMount } from ' svelte ' ;
2+ import { base } from ' $app/paths ' ;
33 </script >
44
55<svelte:head >
4040 Perfect for understanding how each algorithm works.
4141 </p >
4242 <a
43- href =" /demo/basic"
43+ href =" { base } /demo/basic"
4444 class =" inline-block rounded-lg bg-gradient-to-r from-purple-600 to-blue-600 px-6 py-3 font-semibold text-white shadow-lg transition-all duration-300 hover:from-purple-700 hover:to-blue-700"
4545 >
4646 Try Basic Demo
6363 Python implementations. Great for understanding real-world applications.
6464 </p >
6565 <a
66- href =" /demo/github-icons"
66+ href =" { base } /demo/github-icons"
6767 class =" inline-block rounded-lg bg-gradient-to-r from-green-600 to-teal-600 px-6 py-3 font-semibold text-white shadow-lg transition-all duration-300 hover:from-green-700 hover:to-teal-700"
6868 >
6969 View GitHub Icons Demo
Original file line number Diff line number Diff line change 22 import dartData from ' $lib/data/basic-demo-dart.json' ;
33 import pythonData from ' $lib/data/basic-demo-python.json' ;
44 import type { Algorithms } from ' $lib/types' ;
5+ import { base } from ' $app/paths' ;
56
67 let selectedAlgorithm = $state <Algorithms >(' ahash' );
78 let selectedImage1 = $state (' ' );
134135 <div class =" relative mb-6" >
135136 <div class =" absolute -top-12 right-0 sm:-top-8 md:-top-6" >
136137 <a
137- href =" /demo"
138+ href =" { base } /demo"
138139 class =" rounded-lg border border-white/20 bg-white/10 px-3 py-1.5 text-xs text-white transition-all hover:bg-white/20 sm:px-4 sm:py-2 sm:text-sm"
139140 >
140141 β Back to Demo Selection
Original file line number Diff line number Diff line change 22 import dartHashes from ' $lib/data/github-icons-dart.json' ;
33 import pythonHashes from ' $lib/data/github-icons-python.json' ;
44 import type { AlgorithmsWithZ } from ' $lib/types' ;
5+ import { base } from ' $app/paths' ;
56
67 let selectedAlgorithm: AlgorithmsWithZ = $state (' ahash' );
78 let isLoading = $state (false );
108109 <div class =" relative mb-6" >
109110 <div class =" absolute -top-12 right-0 sm:-top-8 md:-top-6" >
110111 <a
111- href =" /demo"
112+ href =" { base } /demo"
112113 class =" rounded-lg border border-white/20 bg-white/10 px-3 py-1.5 text-xs text-white transition-all hover:bg-white/20 sm:px-4 sm:py-2 sm:text-sm"
113114 >
114115 β Back to Demo Selection
You canβt perform that action at this time.
0 commit comments