export const setPresetOptions = (option, isDark) => {
    const xAxisStyle = {
        type: 'category',
        boundaryGap: ['10%', '10%'],
        axisLabel: {
            fontFamily: 'PingFangSC-Regular',
            color: isDark ? '#fff8' : 'rgba(0, 0, 0, 0.5)',
        },
        axisLine: {
            lineStyle: {
                type: 'dashed',
                color: isDark ? '#fff8' : 'rgba(0, 0, 0, 0.5)',
            },
        },
    };

    const yAxisStyle = {
        type: 'value',
        nameTextStyle: {
            fontFamily: 'PingFangSC-Regular',
            color: isDark ? '#fff8' : '#0008',
        },
        axisLabel: {
            fontFamily: 'PingFangSC-Regular',
            color: isDark ? '#fff8' : '#0008',
        },
        splitLine: {
            lineStyle: {
                type: 'dashed',
                color: isDark ? '#fff4' : '#0004',
            },
        },
    };

    option.legend = {
        textStyle: {
            fontSize: 12,
            fontFamily: 'PingFangSC-Regular',
            color: isDark ? 'white' : '#666',
        },
        ...option.legend,
    };
    option.xAxis = option.xAxis
        ? Array.isArray(option.xAxis)
            ? option.xAxis.map(item => ({ ...xAxisStyle, ...item }))
            : {
                  ...xAxisStyle,
                  ...option.xAxis,
              }
        : undefined;
    option.yAxis = option.yAxis
        ? Array.isArray(option.yAxis)
            ? option.yAxis.map(item => ({ ...yAxisStyle, ...item }))
            : {
                  ...yAxisStyle,
                  ...option.yAxis,
              }
        : undefined;
};
//# sourceMappingURL=theme.js.map
