"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
  for (var name in all)
    __defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
  if (from && typeof from === "object" || typeof from === "function") {
    for (let key of __getOwnPropNames(from))
      if (!__hasOwnProp.call(to, key) && key !== except)
        __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
  }
  return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var ValueElement_exports = {};
__export(ValueElement_exports, {
  ValueElement: () => ValueElement
});
module.exports = __toCommonJS(ValueElement_exports);
var import_BaseElement = require("./BaseElement.js");
/**
 * @license
 * Copyright 2022-2026 Matter.js Authors
 * SPDX-License-Identifier: Apache-2.0
 */
function ValueElement(tag, definition, children) {
  definition = { ...definition };
  if (definition.constraint?.toString().toLowerCase() === "all") {
    delete definition.constraint;
  }
  for (const k of ["conformance", "quality", "access", "quality"]) {
    if (definition[k] === "") {
      delete definition[k];
    }
  }
  return (0, import_BaseElement.BaseElement)(tag, definition, children);
}
((ValueElement2) => {
  let Metatype;
  ((Metatype2) => {
    Metatype2[Metatype2["bool"] = 0] = "bool";
    Metatype2[Metatype2["map"] = 1] = "map";
  })(Metatype = ValueElement2.Metatype || (ValueElement2.Metatype = {}));
})(ValueElement || (ValueElement = {}));
//# sourceMappingURL=ValueElement.js.map
