import e from"@babel/runtime/helpers/defineProperty";import{convertValue as t}from"../convert.js";import{COMPONENT_FAMILIES as r}from"../../constants/casing.js";function n(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function i(t){for(var r=1;r<arguments.length;r++){var i=null!=arguments[r]?arguments[r]:{};r%2?n(Object(i),!0).forEach((function(r){e(t,r,i[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}function o(e){var t=r.find((function(t){return t.type===e}));return t?t.name:""}function c(e){for(var r=[],n=0,c=0;c<e.length;c+=1){var a=e[c],f=i(i({},a),{},{family_name:o(a.family),inner_diameter:t(a.inner_diameter,"shortLength","in"),outer_diameter:t(a.outer_diameter,"shortLength","in"),linear_weight:t(a.linear_weight,"massPerLength","lb-ft"),weight:t(a.linear_weight,"mass","lb"),length:t(a.linear_weight,"length","ft")});n+=f.length,f.cum_length=n,r.push(f)}return r}export{c as convertComponents,o as getFamilyName};
//# sourceMappingURL=conversion.js.map
