const linearColorForDualAxis = (spec, context)=>{
    const result = {
        ...spec
    };
    const { advancedVSeed } = context;
    const { datasetReshapeInfo, chartType } = advancedVSeed;
    const { unfoldInfo } = datasetReshapeInfo[0];
    const baseConfig = advancedVSeed.config[chartType];
    if (!baseConfig || !baseConfig.color) return result;
    const { color } = baseConfig;
    const { colorScheme, linearColorScheme } = color;
    result.color = {
        type: 'linear',
        range: linearColorScheme || colorScheme || [],
        domain: spec.series.map((s)=>({
                dataId: s.data.id,
                fields: [
                    unfoldInfo.encodingColor
                ]
            }))
    };
    return result;
};
export { linearColorForDualAxis };

//# sourceMappingURL=linearColorForDualAxis.js.map