File tree 2 files changed +11
-4
lines changed
2 files changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ import DataLayout from '@component/template/DataLayout';
4
4
import { DATE_OPTIONS } from '@constant/Date' ;
5
5
import useProjectTraffic from '@hook/api/useProjectTraffic' ;
6
6
import { DateType } from '@type/Date' ;
7
+ import { Link } from 'lucide-react' ;
7
8
import { useState } from 'react' ;
8
9
9
10
type Props = {
@@ -134,10 +135,15 @@ export default function ProjectTrafficChart({ id }: Props) {
134
135
< DataLayout cssOption = 'flex flex-col p-[8px] rounded-lg shadow-md w-full h-full' >
135
136
< div className = 'mb-[8px] flex items-center justify-between' >
136
137
< div className = 'flex-1 items-center pl-12 pt-2 text-xl text-gray' > Total: { data . total } </ div >
137
- < div className = 'text-navy items-center text-center text-xl' >
138
- < span className = 'mr-2 text-2xl font-bold' > { data . projectName } </ span >
139
- Traffic Chart
140
- </ div >
138
+ < a
139
+ className = 'mr-2 inline-flex items-center gap-1 text-2xl font-bold hover:text-blue'
140
+ href = { `http://${ data . domain } ` }
141
+ target = '_blank'
142
+ rel = 'noreferrer' >
143
+ < Link className = 'h-5 w-5' />
144
+ { data . projectName }
145
+ </ a >
146
+ < div className = 'flex justify-center' > Traffic Chart</ div >
141
147
< div className = 'flex flex-1 justify-end p-4' >
142
148
< Select
143
149
cssOption = 'p-2 border rounded'
Original file line number Diff line number Diff line change @@ -52,6 +52,7 @@ type ProjectDAU = {
52
52
type ProjectTraffic = {
53
53
projectName : string ;
54
54
timeRange : string ;
55
+ domain : string ;
55
56
total : number ;
56
57
trafficData : {
57
58
timestamp : string ;
You can’t perform that action at this time.
0 commit comments