@@ -5,18 +5,34 @@ const isValid = ref(true)
55const copied = ref (false )
66
77const types = [
8- ' version' , ' license' , ' size' , ' downloads' , ' downloads-day' ,
9- ' downloads-week' , ' downloads-month' , ' downloads-year' ,
10- ' vulnerabilities' , ' dependencies' , ' created' , ' updated' ,
11- ' engines' , ' types' , ' maintainers' , ' deprecated' ,
12- ' quality' , ' popularity' , ' maintenance' , ' score' , ' name' ,
8+ ' version' ,
9+ ' license' ,
10+ ' size' ,
11+ ' downloads' ,
12+ ' downloads-day' ,
13+ ' downloads-week' ,
14+ ' downloads-month' ,
15+ ' downloads-year' ,
16+ ' vulnerabilities' ,
17+ ' dependencies' ,
18+ ' created' ,
19+ ' updated' ,
20+ ' engines' ,
21+ ' types' ,
22+ ' maintainers' ,
23+ ' deprecated' ,
24+ ' quality' ,
25+ ' popularity' ,
26+ ' maintenance' ,
27+ ' score' ,
28+ ' name' ,
1329]
1430
1531watch (pkg, () => {
1632 isValid .value = true
1733})
1834
19- const formatLabel = ( str ) => {
35+ const formatLabel = str => {
2036 if (! str || typeof str !== ' string' ) return ' '
2137 return str
2238 .split (' -' )
@@ -65,7 +81,9 @@ const copyToClipboard = async () => {
6581 v-model =" type"
6682 class =" w-full h-10.5 px-4 py-2 rounded-lg border border-gray-200 dark:border-white/10 bg-white dark:bg-black/20 focus:ring-2 focus:ring-emerald-500/20 focus:border-emerald-500 outline-none text-sm transition-all appearance-none cursor-pointer"
6783 >
68- <option v-for =" t in types" :key =" t" :value =" t" class =" dark:bg-gray-900" >{{ formatLabel(t) }}</option >
84+ <option v-for =" t in types" :key =" t" :value =" t" class =" dark:bg-gray-900" >
85+ {{ formatLabel(t) }}
86+ </option >
6987 </select >
7088 <span
7189 class =" absolute right-3 top-1/2 -translate-y-1/2 i-lucide-chevron-down w-4 h-4 text-gray-400 pointer-events-none"
0 commit comments