adminforth 1.2.77 → 1.2.78

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.
@@ -1,6 +1,8 @@
1
1
  export const styles = () => ({
2
2
  colors: {
3
3
  lightHtml: "#FFFFFF", // main background
4
+ lightPrimary: "#3B82F6", // primary color
5
+ lightPrimaryOpacity: "alias:lightPrimary opacity:0.1", // primary color opacity
4
6
  lightNavbar: "#FFFFFF", // navbar background
5
7
  lightNavbarBorder: "rgb(229 231 235)", // border
6
8
  lightNavbarText: "#111827", // navbar text
@@ -48,6 +50,8 @@ export const styles = () => ({
48
50
  lightButtonsIcon: "#333333", // button icon
49
51
  // colors for dark theme
50
52
  darkHtml: "#111827",
53
+ darkPrimary: "#3B82F6", // primary color
54
+ darkPrimaryOpacity: "alias:darkPrimary opacity:0.1", // primary color opacity
51
55
  darkNavbar: "#111827",
52
56
  darkNavbarBorder: "#e5e7eb",
53
57
  darkNavbarText: "#9ca3af",
package/modules/styles.ts CHANGED
@@ -4,6 +4,9 @@ export const styles = () => ({
4
4
  colors: {
5
5
  lightHtml: "#FFFFFF", // main background
6
6
 
7
+ lightPrimary: "#3B82F6", // primary color
8
+ lightPrimaryOpacity: "alias:lightPrimary opacity:0.1", // primary color opacity
9
+
7
10
  lightNavbar: "#FFFFFF", // navbar background
8
11
  lightNavbarBorder: "rgb(229 231 235)", // border
9
12
  lightNavbarText: "#111827", // navbar text
@@ -59,6 +62,9 @@ export const styles = () => ({
59
62
  // colors for dark theme
60
63
  darkHtml: "#111827",
61
64
 
65
+ darkPrimary: "#3B82F6", // primary color
66
+ darkPrimaryOpacity: "alias:darkPrimary opacity:0.1", // primary color opacity
67
+
62
68
  darkNavbar: "#111827",
63
69
  darkNavbarBorder: "#e5e7eb",
64
70
  darkNavbarText: "#9ca3af",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "adminforth",
3
- "version": "1.2.77",
3
+ "version": "1.2.78",
4
4
  "description": "OpenSource Vue3 powered forth-generation admin panel",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
package/spa/src/App.vue CHANGED
@@ -107,7 +107,7 @@
107
107
  </ul>
108
108
 
109
109
 
110
- <div id="dropdown-cta" class="p-4 mt-6 rounded-lg bg-blue-50 dark:bg-blue-900" role="alert"
110
+ <div id="dropdown-cta" class="p-4 mt-6 rounded-lg bg-lightPrimaryOpacity dark:bg-darkPrimaryOpacity" role="alert"
111
111
  v-if="ctaBadge"
112
112
  >
113
113
  <div class="flex items-center mb-3">
@@ -119,7 +119,7 @@
119
119
  <button type="button"
120
120
  class="ms-auto -mx-1.5 -my-1.5 bg-blue-50 inline-flex justify-center items-center w-6 h-6 text-blue-900 rounded-lg focus:ring-2 focus:ring-blue-400 p-1 hover:bg-blue-200 dark:bg-blue-900 dark:text-blue-400 dark:hover:bg-blue-800"
121
121
  data-dismiss-target="#dropdown-cta" aria-label="Close"
122
- v-if="ctaBadge.closable" @click="closeCTA"
122
+ v-if="ctaBadge?.closable" @click="closeCTA"
123
123
  >
124
124
  <span class="sr-only">Close</span>
125
125
  <svg class="w-2.5 h-2.5" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 14 14">
@@ -127,8 +127,8 @@
127
127
  </svg>
128
128
  </button>
129
129
  </div>
130
- <p class="mb-3 text-sm fill-blue-800 dark:fill-blue-400 text-blue-800 dark:text-blue-400" v-if="ctaBadge.html" v-html="ctaBadge.html"></p>
131
- <p class="text-sm text-blue-800 dark:text-blue-400" v-else>
130
+ <p class="mb-3 text-sm fill-lightPrimary dark:fill-darkPrimary text-lightPrimary dark:text-darkPrimary" v-if="ctaBadge.html" v-html="ctaBadge.html"></p>
131
+ <p class="mb-3 text-sm fill-lightPrimary dark:fill-darkPrimary text-lightPrimary dark:text-darkPrimary" v-else>
132
132
  {{ ctaBadge.text }}
133
133
  </p>
134
134
  <!-- <a class="text-sm text-blue-800 underline font-medium hover:text-blue-900 dark:text-blue-400 dark:hover:text-blue-300" href="#">Turn new navigation off</a> -->
@@ -342,8 +342,8 @@ onBeforeMount(()=>{
342
342
 
343
343
  const ctaBadge = computed(() => {
344
344
  const badge = coreStore.config?.announcementBadge;
345
- const hash = badge.closable ? JSON.stringify(badge).split('').reduce((a,b)=>{a=((a<<5)-a)+b.charCodeAt(0);return a&a},0) : '';
346
- if (badge.closable && window.localStorage.getItem(`ctaBadge-${hash}`)) {
345
+ const hash = badge?.closable ? JSON.stringify(badge).split('').reduce((a,b)=>{a=((a<<5)-a)+b.charCodeAt(0);return a&a},0) : '';
346
+ if (badge?.closable && window.localStorage.getItem(`ctaBadge-${hash}`)) {
347
347
  return null;
348
348
  }
349
349
  return {...badge, hash};
@@ -108,7 +108,7 @@
108
108
  primaryKey: row._primaryKeyValue,
109
109
  }
110
110
  }"
111
- class="font-medium text-blue-600 dark:text-blue-500 hover:underline"
111
+ class="font-medium text-lightPrimary dark:text-darkPrimary hover:underline"
112
112
  :data-tooltip-target="`tooltip-show-${rowI}`"
113
113
  >
114
114
  <IconEyeSolid class="w-5 h-5 me-2"/>
@@ -129,7 +129,7 @@
129
129
  primaryKey: row._primaryKeyValue
130
130
  }
131
131
  }"
132
- class="font-medium text-blue-600 dark:text-blue-500 hover:underline ms-3"
132
+ class="font-medium text-lightPrimary dark:text-darkPrimary hover:underline ms-3"
133
133
  :data-tooltip-target="`tooltip-edit-${rowI}`"
134
134
  >
135
135
  <IconPenSolid class="w-5 h-5 me-2"/>
@@ -143,7 +143,7 @@
143
143
  </div>
144
144
 
145
145
  <button v-if="resource.options?.allowedActions.delete"
146
- class="font-medium text-red-600 dark:text-red-500 hover:underline ms-3"
146
+ class="font-medium text-lightPrimary dark:text-darkPrimary hover:underline ms-3"
147
147
  :data-tooltip-target="`tooltip-delete-${rowI}`"
148
148
  @click="deleteRecord(row)"
149
149
  >