fix color and componenet

This commit is contained in:
Saeed AB 2025-09-24 15:15:23 +03:30
parent 585e66570d
commit 9205653736
2 changed files with 10 additions and 12 deletions

View File

@ -230,11 +230,11 @@ export function DashboardHome() {
style={{ height: `${Math.random() * 80 + 20}%` }}
></div>
<div
className="w-full bg-green-400/30 rounded-t-sm"
className="w-full bg-pr-green rounded-t-sm"
style={{ height: `${Math.random() * 80 + 20}%` }}
></div>
<div
className="w-full bg-red-400/30 rounded-t-sm"
className="w-full bg-pr-red rounded-t-sm"
style={{ height: `${Math.random() * 80 + 20}%` }}
></div>
</div>
@ -345,7 +345,7 @@ export function DashboardHome() {
100,
)
: 0,
fill: "green",
fill: "var(--color-green)",
},
]}
startAngle={90}
@ -378,7 +378,7 @@ export function DashboardHome() {
gridType="circle"
radialLines={false}
stroke="none"
className="first:fill-red-400 last:fill-[#24273A]"
className="first:fill-pr-red last:fill-[#24273A]"
polarRadius={[38, 31]}
/>
<RadialBar
@ -488,7 +488,7 @@ export function DashboardHome() {
dashboardData.topData
?.innovation_budget_achievement_percent || "0",
),
fill: "green",
fill: "var(--color-green)",
},
]}
startAngle={90}
@ -506,7 +506,7 @@ export function DashboardHome() {
gridType="circle"
radialLines={false}
stroke="none"
className="first:fill-red-400 last:fill-[#24273A]"
className="first:fill-pr-red last:fill-[#24273A]"
polarRadius={[38, 31]}
/>
<RadialBar
@ -734,7 +734,7 @@ export function DashboardHome() {
</div>
<div className="flex items-center justify-center gap-4">
<div className="flex items-center gap-2">
<Book className="w-4 h-4 text-green-400" />
<Book className="w-4 h-4 text-pr-green" />
<span className="text-sm">مقاله:</span>
</div>
<span className="text-base font-bold ">
@ -791,7 +791,7 @@ export function DashboardHome() {
</div>
<div className="flex items-center justify-center gap-4">
<div className="flex items-center gap-2">
<Book className="w-4 h-4 text-green-400" />
<Book className="w-4 h-4 text-pr-green" />
<span className="text-sm">برگزاری رویداد:</span>
</div>
<span className="text-base font-bold ">

View File

@ -16,13 +16,11 @@ const Progress = React.forwardRef<
{...props}
>
<span className="left-0 text-sm absolute z-10 px-2 text-[#5F6284]">۰%</span>
<span className="w-full text-sm absolute z-10 px-2 text-[#5F6284]"
style={{ transform: `translateX(-${10 - (value || 0)}%)` }}
<span className="w-full right-0 text-sm absolute z-10 px-2 text-[#5F6284]"
>{formatNumber(Math.ceil(value || 0 * 10) / 10)}%</span>
<span className="right-0 text-sm absolute z-10 px-2 text-[#5F6284]">{formatNumber(.2)}%</span>
<ProgressPrimitive.Indicator
className="h-full w-full flex-1 bg-primary transition-all"
style={{ transform: `translateX(-${20 - (value || 0)}%)` }}
style={{ transform: `translateX(-${15 - (value || 0)}%)` }}
/>
</ProgressPrimitive.Root>
))