/**
 * @license
 * Copyright 2022-2026 Matter.js Authors
 * SPDX-License-Identifier: Apache-2.0
 */
import { camelize, ImplementationError } from "#general";
function SupportedBehaviors(...types) {
  const result = {};
  addBehaviors(result, types);
  return result;
}
((SupportedBehaviors2) => {
  function extend(currentTypes, newTypes) {
    const result = { ...currentTypes };
    addBehaviors(result, newTypes);
    return result;
  }
  SupportedBehaviors2.extend = extend;
})(SupportedBehaviors || (SupportedBehaviors = {}));
function addBehaviors(target, types) {
  for (const type of types) {
    if (typeof type.id !== "string") {
      throw new ImplementationError("Behavior type has no ID");
    }
    target[camelize(type.id)] = type;
  }
}
export {
  SupportedBehaviors
};
//# sourceMappingURL=SupportedBehaviors.js.map
