File tree Expand file tree Collapse file tree 2 files changed +16
-3
lines changed Expand file tree Collapse file tree 2 files changed +16
-3
lines changed Original file line number Diff line number Diff line change 33import * as d3 from " d3"
44
55/** Services */
6- import { capitalizeAndReplace } from " @/services/utils"
6+ import { capitalizeAndReplace , isMobile } from " @/services/utils"
77
88const props = defineProps ({
99 series: {
@@ -62,7 +62,7 @@ const buildChart = (chart) => {
6262 const cursorAngle = Math .atan2 (y, x)
6363 const cursorDist = Math .sqrt (x * x + y * y)
6464
65- if (cursorDist > maxRadius) {
65+ if (cursorDist < 10 || cursorDist > maxRadius) {
6666 clearHighlight ()
6767 return
6868 }
@@ -99,7 +99,12 @@ const buildChart = (chart) => {
9999
100100 nextTick (() => {
101101 const tooltipWidth = tooltipEl .value ? .wrapper ? tooltipEl .value ? .wrapper ? .getBoundingClientRect ()? .width : 100
102- const offsetX = (cursorAngle < 0 && cursorAngle - 0.5 > - Math .PI / 2 ) || (cursorAngle > 0 && cursorAngle < Math .PI / 2 ) ? - (tooltipWidth + 20 ) : 20
102+ const offsetX =
103+ (cursorAngle < 0 && cursorAngle - 0.5 > - Math .PI / 2 ) ||
104+ (cursorAngle > 0 && cursorAngle < Math .PI / 2 ) ||
105+ isMobile ()
106+ ? - (tooltipWidth + 20 )
107+ : 20
103108 const offsetY = - 40
104109 tooltip .value .x = event .offsetX + offsetX
105110 tooltip .value .y = event .offsetY + offsetY
Original file line number Diff line number Diff line change 1+ export default defineNuxtRouteMiddleware ( ( ) => {
2+ if ( import . meta. client ) return
3+
4+ const host = useRequestHeaders ( [ "host" ] ) ?. host
5+ if ( host === "https://mammoth.celenium.io/" ) {
6+ return navigateTo ( "https://celenium.io/" , { redirectCode : 301 } )
7+ }
8+ } )
You can’t perform that action at this time.
0 commit comments