mirror of
https://github.com/jxxghp/MoviePilot-Frontend.git
synced 2026-09-05 07:28:37 +08:00
fix(charts): disable zoom interactions
This commit is contained in:
@@ -3,6 +3,9 @@
|
|||||||
|
|
||||||
// 👉 Apex chart
|
// 👉 Apex chart
|
||||||
.apexcharts-canvas {
|
.apexcharts-canvas {
|
||||||
|
// 图表仅保留纵向页面滚动,禁止双指缩放等触摸手势。
|
||||||
|
touch-action: pan-y;
|
||||||
|
|
||||||
// For RTL alignment
|
// For RTL alignment
|
||||||
.apexcharts-yaxis-texts-g {
|
.apexcharts-yaxis-texts-g {
|
||||||
text-align: start;
|
text-align: start;
|
||||||
|
|||||||
@@ -64,8 +64,10 @@ const historyChartOptions = computed(() => {
|
|||||||
enabled: true,
|
enabled: true,
|
||||||
},
|
},
|
||||||
zoom: {
|
zoom: {
|
||||||
autoScaleYaxis: true,
|
enabled: false,
|
||||||
|
allowMouseWheelZoom: false,
|
||||||
},
|
},
|
||||||
|
selection: { enabled: false },
|
||||||
},
|
},
|
||||||
theme: {
|
theme: {
|
||||||
mode: vuetifyTheme.global.current.value.dark ? 'dark' : 'light', // 同步主题模式
|
mode: vuetifyTheme.global.current.value.dark ? 'dark' : 'light', // 同步主题模式
|
||||||
@@ -156,8 +158,10 @@ const seedingChartOptions = computed(() => {
|
|||||||
background: currentTheme.value.surface, // 新增背景色同步
|
background: currentTheme.value.surface, // 新增背景色同步
|
||||||
foreColor: currentTheme.value.onSurface, // 新增文字颜色同步
|
foreColor: currentTheme.value.onSurface, // 新增文字颜色同步
|
||||||
zoom: {
|
zoom: {
|
||||||
autoScaleYaxis: true,
|
enabled: false,
|
||||||
|
allowMouseWheelZoom: false,
|
||||||
},
|
},
|
||||||
|
selection: { enabled: false },
|
||||||
},
|
},
|
||||||
theme: {
|
theme: {
|
||||||
mode: vuetifyTheme.global.current.value.dark ? 'dark' : 'light', // 同步主题模式
|
mode: vuetifyTheme.global.current.value.dark ? 'dark' : 'light', // 同步主题模式
|
||||||
|
|||||||
@@ -75,6 +75,8 @@ const chartOptions = controlledComputed(
|
|||||||
chart: {
|
chart: {
|
||||||
parentHeightOffset: 0,
|
parentHeightOffset: 0,
|
||||||
toolbar: { show: false },
|
toolbar: { show: false },
|
||||||
|
zoom: { enabled: false, allowMouseWheelZoom: false },
|
||||||
|
selection: { enabled: false },
|
||||||
animations: { enabled: false },
|
animations: { enabled: false },
|
||||||
foreColor: axisLabelColor,
|
foreColor: axisLabelColor,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -81,6 +81,8 @@ const chartOptions = controlledComputed(
|
|||||||
chart: {
|
chart: {
|
||||||
parentHeightOffset: 0,
|
parentHeightOffset: 0,
|
||||||
toolbar: { show: false },
|
toolbar: { show: false },
|
||||||
|
zoom: { enabled: false, allowMouseWheelZoom: false },
|
||||||
|
selection: { enabled: false },
|
||||||
animations: { enabled: false },
|
animations: { enabled: false },
|
||||||
foreColor: axisLabelColor,
|
foreColor: axisLabelColor,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -76,6 +76,8 @@ const chartOptions = controlledComputed(
|
|||||||
chart: {
|
chart: {
|
||||||
parentHeightOffset: 0,
|
parentHeightOffset: 0,
|
||||||
toolbar: { show: false },
|
toolbar: { show: false },
|
||||||
|
zoom: { enabled: false, allowMouseWheelZoom: false },
|
||||||
|
selection: { enabled: false },
|
||||||
animations: { enabled: false },
|
animations: { enabled: false },
|
||||||
foreColor: axisLabelColor,
|
foreColor: axisLabelColor,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -28,6 +28,8 @@ const options = controlledComputed(
|
|||||||
chart: {
|
chart: {
|
||||||
parentHeightOffset: 0,
|
parentHeightOffset: 0,
|
||||||
toolbar: { show: false },
|
toolbar: { show: false },
|
||||||
|
zoom: { enabled: false, allowMouseWheelZoom: false },
|
||||||
|
selection: { enabled: false },
|
||||||
animations: { enabled: false },
|
animations: { enabled: false },
|
||||||
},
|
},
|
||||||
plotOptions: {
|
plotOptions: {
|
||||||
|
|||||||
Reference in New Issue
Block a user