import { mixin } from "../../../../../../zrender@5.4.4/node_modules/zrender/lib/core/util.mjs";
import createSeriesData from "../../chart/helper/createSeriesData.mjs";
import { createScaleByModel, niceScaleExtent } from "../../coord/axisHelper.mjs";
import { AxisModelCommonMixin } from "../../coord/axisModelCommonMixin.mjs";
import Model from "../../model/Model.mjs";
import { getLayoutRect } from "../../util/layout.mjs";
import { isDimensionStacked, enableDataStack, getStackedDimension } from "../../data/helper/dataStackHelper.mjs";
import { getECData } from "../../util/innerStore.mjs";
import { createTextStyle as createTextStyle$1 } from "../../label/labelStyle.mjs";
import { createDimensions } from "../../data/helper/createDimensions.mjs";
import { createSymbol } from "../../util/symbol.mjs";
import { enableHoverEmphasis } from "../../util/states.mjs";
function createList(seriesModel) {
  return createSeriesData(null, seriesModel);
}
var dataStack = {
  isDimensionStacked,
  enableDataStack,
  getStackedDimension
};
function createScale(dataExtent, option) {
  var axisModel = option;
  if (!(option instanceof Model)) {
    axisModel = new Model(option);
  }
  var scale = createScaleByModel(axisModel);
  scale.setExtent(dataExtent[0], dataExtent[1]);
  niceScaleExtent(scale, axisModel);
  return scale;
}
function mixinAxisModelCommonMethods(Model2) {
  mixin(Model2, AxisModelCommonMixin);
}
function createTextStyle(textStyleModel, opts) {
  opts = opts || {};
  return createTextStyle$1(textStyleModel, null, null, opts.state !== "normal");
}
export {
  createDimensions,
  createList,
  createScale,
  createSymbol,
  createTextStyle,
  dataStack,
  enableHoverEmphasis,
  getECData,
  getLayoutRect,
  mixinAxisModelCommonMethods
};
