+
diff --git a/apps/web/src/components/brand/MentoLogo.vue b/apps/web/src/components/brand/MentoLogo.vue
index ffd707a..d786936 100644
--- a/apps/web/src/components/brand/MentoLogo.vue
+++ b/apps/web/src/components/brand/MentoLogo.vue
@@ -15,21 +15,25 @@ withDefaults(
-
+
-
+
-
+
@@ -52,7 +56,11 @@ withDefaults(
display: grid;
place-items: center;
flex-shrink: 0;
- background: transparent;
+ background: linear-gradient(145deg, #5eead4, #14b8a6);
+ box-shadow: 0 8px 18px rgba(20, 184, 166, 0.28);
+ overflow: hidden;
+ padding: 4px;
+ box-sizing: border-box;
}
.mark svg {
diff --git a/apps/web/src/components/dashboard/HomeAiAssistant.vue b/apps/web/src/components/dashboard/HomeAiAssistant.vue
index 06c2ccd..037eed8 100644
--- a/apps/web/src/components/dashboard/HomeAiAssistant.vue
+++ b/apps/web/src/components/dashboard/HomeAiAssistant.vue
@@ -12,7 +12,7 @@ const emit = defineEmits<{
}>();
const shortcuts = [
- { label: 'خلاصه مشتری شرکت آریانا را بده', to: '/contacts', icon: 'users' as const },
+ { label: 'خلاصه مشتری شرکت آریا را بده', to: '/contacts', icon: 'users' as const },
{ label: 'متن پیگیری برای مشتری بفرست', to: '/notes', icon: 'send' as const },
{ label: 'گزارش فروش این هفته را نشان بده', to: '/reports', icon: 'chart' as const },
{ label: 'معاملات در خطر را لیست کن', to: '/pipeline', icon: 'warning' as const },
@@ -20,10 +20,10 @@ const shortcuts = [
-
+
@@ -31,13 +31,8 @@ const shortcuts = [
چه کمکی میتونم بکنم؟
-
-
+
+
{{ item.label }}
@@ -50,7 +45,7 @@ const shortcuts = [
@input="emit('update:askQuery', ($event.target as HTMLInputElement).value)"
/>
-
+
@@ -59,8 +54,8 @@ const shortcuts = [
diff --git a/apps/web/src/components/dashboard/HomeSalesTrend.vue b/apps/web/src/components/dashboard/HomeSalesTrend.vue
index a363968..ad0406f 100644
--- a/apps/web/src/components/dashboard/HomeSalesTrend.vue
+++ b/apps/web/src/components/dashboard/HomeSalesTrend.vue
@@ -9,17 +9,27 @@ const props = defineProps<{
formatAmount: (value: number) => string;
}>();
+const demoTrend: HomeDashboardTrendPointDto[] = [
+ { monthKey: '01', monthLabel: 'فروردین', amount: 980_000_000 },
+ { monthKey: '02', monthLabel: 'اردیبهشت', amount: 1_250_000_000 },
+ { monthKey: '03', monthLabel: 'خرداد', amount: 1_480_000_000 },
+ { monthKey: '04', monthLabel: 'تیر', amount: 1_860_000_000 },
+ { monthKey: '05', monthLabel: 'مرداد', amount: 2_450_000_000 },
+];
+
+const trend = computed(() => (props.trend.length ? props.trend : demoTrend));
+const change = computed(() => props.changePercent ?? 14);
+
const points = computed(() => {
- const trend = props.trend;
- if (!trend.length) return [];
- const max = Math.max(...trend.map((p) => p.amount), 1);
+ const rows = trend.value;
+ const max = Math.max(...rows.map((p) => p.amount), 1);
const w = 360;
const h = 150;
const padX = 16;
- const padY = 18;
- return trend.map((p, i) => ({
+ const padY = 36;
+ return rows.map((p, i) => ({
...p,
- x: padX + (i / Math.max(trend.length - 1, 1)) * (w - padX * 2),
+ x: padX + (i / Math.max(rows.length - 1, 1)) * (w - padX * 2),
y: h - padY - (p.amount / max) * (h - padY * 2),
}));
});
@@ -43,12 +53,8 @@ const highlight = computed(() => {
روند فروش
-
- {{ formatChange(changePercent) }} نسبت به ماه قبل
+
+ {{ formatChange(change) }} نسبت به ماه قبل
@@ -56,7 +62,7 @@ const highlight = computed(() => {
-
+
@@ -76,29 +82,29 @@ const highlight = computed(() => {
:points="line"
fill="none"
stroke="#14b8a6"
- stroke-width="3.4"
+ stroke-width="3.2"
stroke-linecap="round"
stroke-linejoin="round"
/>
-
+
{{ formatAmount(highlight.amount) }}
@@ -114,11 +120,14 @@ const highlight = computed(() => {
diff --git a/apps/web/src/components/dashboard/HomeSourcesChart.vue b/apps/web/src/components/dashboard/HomeSourcesChart.vue
index 8701578..aec7ba3 100644
--- a/apps/web/src/components/dashboard/HomeSourcesChart.vue
+++ b/apps/web/src/components/dashboard/HomeSourcesChart.vue
@@ -7,18 +7,28 @@ const props = defineProps<{
sources: HomeDashboardSourceDto[];
}>();
-const colors = ['#14b8a6', '#38bdf8', '#fb923c', '#fbbf24', '#94a3b8', '#a78bfa'];
+const demoSources: HomeDashboardSourceDto[] = [
+ { label: 'معرفی دوستان', count: 44, percent: 34 },
+ { label: 'وبسایت', count: 33, percent: 26 },
+ { label: 'شبکههای اجتماعی', count: 23, percent: 18 },
+ { label: 'تبلیغات', count: 18, percent: 14 },
+ { label: 'سایر', count: 10, percent: 8 },
+];
+
+const colors = ['#2563eb', '#14b8a6', '#22c55e', '#fb923c', '#94a3b8'];
+
+const rows = computed(() => (props.sources.length ? props.sources : demoSources));
const segments = computed(() => {
let offset = 0;
- return props.sources.map((s, i) => {
+ return rows.value.map((s, i) => {
const seg = { ...s, color: colors[i % colors.length], offset };
offset += s.percent;
return seg;
});
});
-const total = computed(() => props.sources.reduce((a, s) => a + s.count, 0));
+const total = computed(() => rows.value.reduce((a, s) => a + s.count, 0));
@@ -66,39 +76,39 @@ const total = computed(() => props.sources.reduce((a, s) => a + s.count, 0));
diff --git a/apps/web/src/layouts/AppLayout.vue b/apps/web/src/layouts/AppLayout.vue
index 4959750..8ad0d38 100644
--- a/apps/web/src/layouts/AppLayout.vue
+++ b/apps/web/src/layouts/AppLayout.vue
@@ -349,13 +349,19 @@ onUnmounted(() => {
{{ auth.user?.fullName }}
{{ roleLabel || 'کاربر' }}
+
+
+ آنلاین
+
-
خروج از حساب
@@ -454,10 +460,11 @@ onUnmounted(() => {