Skip to content

Commit

Permalink
fix: add g/m3 and kg/m3 to units
Browse files Browse the repository at this point in the history
  • Loading branch information
YAlekseichuk authored Feb 12, 2024
1 parent 57be9ba commit 535a14b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/utils/units.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,12 @@ const conversions = {
'kN/m³': {
'N/m³': (nm3) => nm3.div(1000),
},
'kg/m³': {
'g/m³': (gm3) => gm3.div(1000),
},
'g/m³': {
'kg/m³': (kgm3) => kgm3.times(1000),
},
kNm: {
Nm: (nm) => nm.div(1000),
},
Expand Down Expand Up @@ -149,6 +155,8 @@ const unitToSIMap = {
'N/mm²': 'N/m²',
'N/m³': 'N/m³',
'kN/m³': 'N/m³',
'kg/m³': 'g/m³',
'g/m³': 'kg/m³',
'N/mm³': 'N/m³',
MPa: 'N/m²',
in: 'm',
Expand Down

0 comments on commit 535a14b

Please sign in to comment.