import { MeasureId, MeasureName } from "../../../../../dataReshape/index.js";
import { intl } from "../../../../../i18n/index.js";
import { findAllMeasures } from "../../../../utils/measures/find.js";
import { findTreeNodesBy } from "../../../../utils/tree/traverse.js";
const defaultMeasureId = (advancedVSeed)=>{
    const result = {
        ...advancedVSeed
    };
    const measures = findAllMeasures(advancedVSeed.measureTree);
    if (measures.length > 1 && !findTreeNodesBy(advancedVSeed.dimensionTree, (dim)=>dim.id === MeasureId || dim.id === MeasureName).length) result.dimensionTree.push({
        id: MeasureId,
        alias: intl.i18n`指标名称`,
        encoding: 'row'
    });
    return result;
};
export { defaultMeasureId };

//# sourceMappingURL=defaultMeasureId.js.map