import { __require as L } from "./index-lib2.js";
import { __require as P } from "./index-utilities.js";
var n, f;
function A() {
  if (f) return n;
  f = 1;
  var a = L(), p = P(), T = ["checked", "value"], v = ["input", "select", "textarea"], E = {
    reset: !0,
    submit: !0
  };
  n = function(r, _) {
    r = r || {};
    var i, u, o, e, s, t = {}, c = r.type && E[r.type];
    for (i in r) {
      if (o = r[i], a.isCustomAttribute(i)) {
        t[i] = o;
        continue;
      }
      if (u = i.toLowerCase(), e = O(u), e) {
        switch (s = a.getPropertyInfo(e), T.indexOf(e) !== -1 && v.indexOf(_) !== -1 && !c && (e = O("default" + u)), t[e] = o, s && s.type) {
          case a.BOOLEAN:
            t[e] = !0;
            break;
          case a.OVERLOADED_BOOLEAN:
            o === "" && (t[e] = !0);
            break;
        }
        continue;
      }
      p.PRESERVE_CUSTOM_ATTRIBUTES && (t[i] = o);
    }
    return p.setStyleProp(r.style, t), t;
  };
  function O(N) {
    return a.possibleStandardNames[N];
  }
  return n;
}
export {
  A as __require
};
