import e from "../namespace.js";
//#region ../../node_modules/d3-selection/src/selection/attr.js
function t(e) {
	return function() {
		this.removeAttribute(e);
	};
}
function n(e) {
	return function() {
		this.removeAttributeNS(e.space, e.local);
	};
}
function r(e, t) {
	return function() {
		this.setAttribute(e, t);
	};
}
function i(e, t) {
	return function() {
		this.setAttributeNS(e.space, e.local, t);
	};
}
function a(e, t) {
	return function() {
		var n = t.apply(this, arguments);
		n == null ? this.removeAttribute(e) : this.setAttribute(e, n);
	};
}
function o(e, t) {
	return function() {
		var n = t.apply(this, arguments);
		n == null ? this.removeAttributeNS(e.space, e.local) : this.setAttributeNS(e.space, e.local, n);
	};
}
function s(s, c) {
	var l = e(s);
	if (arguments.length < 2) {
		var u = this.node();
		return l.local ? u.getAttributeNS(l.space, l.local) : u.getAttribute(l);
	}
	return this.each((c == null ? l.local ? n : t : typeof c == "function" ? l.local ? o : a : l.local ? i : r)(l, c));
}
//#endregion
export { s as default };
