/* COPYRIGHT Esri - https://js.arcgis.com/5.0/LICENSE.txt */
import { cloneDeep as l } from "lodash-es";
import { C as n, m as b } from "./model-setter.js";
import { aP as f, bI as i, aN as d } from "./index.js";
var c = Object.defineProperty, m = Object.getOwnPropertyDescriptor, p = (e, t, a, y) => {
  for (var s = m(t, a), o = e.length - 1, r; o >= 0; o--)
    (r = e[o]) && (s = r(t, a, s) || s);
  return s && c(t, a, s), s;
};
function h(e) {
  return e !== void 0 && "dataLabelsSymbol" in e;
}
const L = (e) => {
  for (const t of e.series)
    if (t.dataLabels !== void 0)
      return t.dataLabels.content;
}, v = (e, t) => {
  for (const a of t.series)
    (a.dataLabels === void 0 || e === void 0) && (a.dataLabels = f({
      text: "",
      visible: !0,
      font: d(i.DataLabels),
      type: i.DataLabels
    })), e !== void 0 && (a.dataLabels.content = l(e));
};
class u extends n {
  /**
   * Data labels text symbol (font, color, style).
   */
  get dataLabelsSymbol() {
    return L(this._config);
  }
  set dataLabelsSymbol(t) {
    v(t, this._config);
  }
}
p([
  b
], u.prototype, "dataLabelsSymbol");
export {
  u as W,
  h as i
};
