chunk-ZRX5UNQH.js 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. import {
  2. d
  3. } from "./chunk-KMAHKQ2G.js";
  4. import {
  5. y
  6. } from "./chunk-BJHM4JNS.js";
  7. import {
  8. y as y2
  9. } from "./chunk-WZQZRKNH.js";
  10. import {
  11. s
  12. } from "./chunk-EMJ4ZSM2.js";
  13. // node_modules/@arcgis/core/layers/support/fieldProperties.js
  14. var s2 = s.getLogger("esri.layers.support.fieldProperties");
  15. function l() {
  16. return { fields: { type: [y], value: null }, fieldsIndex: { readOnly: true, get() {
  17. return new d(this.fields || []);
  18. } }, outFields: { type: [String], json: { read: false }, set: function(e) {
  19. this._userOutFields = e, this.notifyChange("outFields");
  20. }, get: function() {
  21. const e = this._userOutFields;
  22. if (!e || !e.length)
  23. return null;
  24. if (e.includes("*"))
  25. return ["*"];
  26. if (!this.fields)
  27. return e;
  28. for (const i of e) {
  29. this.fieldsIndex.has(i) || s2.error("field-attributes-layer:invalid-field", `Invalid field ${i} found in outFields`, { layer: this, outFields: e });
  30. }
  31. return y2(this.fieldsIndex, e);
  32. } } };
  33. }
  34. export {
  35. l
  36. };
  37. //# sourceMappingURL=chunk-ZRX5UNQH.js.map