adata-ui 2.0.96 → 2.0.97

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -17,6 +17,10 @@ const props = defineProps<{
17
17
  currentModule: boolean
18
18
  }>()
19
19
 
20
+ const colorMode = useColorMode()
21
+
22
+ const isDark = computed(() => colorMode.value === 'dark')
23
+
20
24
  function isActive(itemPath: string) {
21
25
  if (!props.currentModule) return false
22
26
 
@@ -69,7 +73,7 @@ function isActive(itemPath: string) {
69
73
  class="flex flex-col gap-2"
70
74
  :class="{ 'rounded-md bg-gray-50 p-2 dark:bg-gray-800': currentModule }"
71
75
  >
72
- <div class="flex items-center gap-2 pl-[10px]">
76
+ <nuxt-link-locale class="flex items-center gap-2 pl-[10px] hover:text-blue-700 dark:hover:text-blue-500" :to="navList[0].to">
73
77
  <p class="text-sm font-semibold">
74
78
  {{ title }}
75
79
  </p>
@@ -82,15 +86,15 @@ function isActive(itemPath: string) {
82
86
  >
83
87
  NEW
84
88
  </a-status-badge>
85
- </div>
89
+ </nuxt-link-locale>
86
90
  <ul class="flex flex-col gap-2">
87
91
  <li
88
92
  v-for="item in navList"
89
93
  :key="item.title"
90
- class="flex w-full items-center gap-2 rounded-md px-[10px] py-[6px] hover:bg-deepblue-900/5 dark:hover:bg-gray-200/5"
94
+ class="flex w-full items-center gap-2 rounded-md px-[10px] py-[6px] hover:bg-blue-100 dark:hover:bg-gray-200/10 text-gray-600 dark:text-gray-200 hover:text-blue-700 dark:hover:text-blue-500"
91
95
  :class="{ 'bg-blue-100 dark:bg-gray-200/10': isActive(item.to) }"
92
96
  >
93
- <div class="bg-gradient-blue g-white rounded-lg p-1 dark:bg-gray-900">
97
+ <div class="rounded-lg p-1" :class="{ 'bg-gradient-blue-dark ': isDark, 'bg-gradient-blue-light': !isDark }">
94
98
  <component
95
99
  :is="item.icon"
96
100
  class="size-[18px] text-white dark:text-gray-900"
@@ -100,7 +104,7 @@ function isActive(itemPath: string) {
100
104
  v-if="item.to"
101
105
  :to="item.to"
102
106
  itemprop="name"
103
- class="inline-block normal-case w-full cursor-pointer align-middle text-sm font-semibold text-gray-600 dark:text-gray-200"
107
+ class="inline-block normal-case w-full cursor-pointer align-middle text-sm font-semibold text-inherit hover:text-inherit"
104
108
  >
105
109
  {{ item.title }}
106
110
  </nuxt-link-locale>
@@ -114,3 +118,13 @@ function isActive(itemPath: string) {
114
118
  </ul>
115
119
  </div>
116
120
  </template>
121
+
122
+ <style scoped lang="scss">
123
+ .bg-gradient-blue-dark {
124
+ background: linear-gradient(236.46deg, #4FBDFF -2.39%, #1B98E2 79.1%);
125
+ }
126
+
127
+ .bg-gradient-blue-light {
128
+ background: linear-gradient(236.46deg, #479FFF -2.39%, #0070EB 79.1%);
129
+ }
130
+ </style>
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "adata-ui",
3
3
  "type": "module",
4
- "version": "2.0.96",
4
+ "version": "2.0.97",
5
5
  "main": "./nuxt.config.ts",
6
6
  "scripts": {
7
7
  "dev": "nuxi dev .playground",