fix(lab): Fixed lab after moving to esm and named exports
This commit is contained in:
parent
dc1f1d7029
commit
d6d8c6f122
31 changed files with 244 additions and 248 deletions
34
sites/shared/components/workbench/menu/xray/path.mjs
Normal file
34
sites/shared/components/workbench/menu/xray/path.mjs
Normal file
|
@ -0,0 +1,34 @@
|
|||
import { Ul, Li, NoSumDiv, Deg } from 'shared/components/workbench/menu/index.mjs'
|
||||
import { formatMm } from 'shared/utils.mjs'
|
||||
import Attributes from './attributes.mjs'
|
||||
import Ops from './path-ops.mjs'
|
||||
|
||||
export const XrayPath = ({ pathName, partName, draft, t, units }) => {
|
||||
const path = draft?.parts?.[partName]?.paths?.[pathName]
|
||||
|
||||
if (!path) return null
|
||||
return (
|
||||
<Ul>
|
||||
<Attributes attr={path.attributes} />
|
||||
<Li>
|
||||
<NoSumDiv>
|
||||
<Deg />
|
||||
<span className="font-bold mr-2">path.render =</span>
|
||||
<span>{JSON.stringify(path.render)}</span>
|
||||
</NoSumDiv>
|
||||
</Li>
|
||||
<Li>
|
||||
<NoSumDiv>
|
||||
<Deg />
|
||||
<span className="font-bold mr-2">path.length() =</span>
|
||||
<span
|
||||
dangerouslySetInnerHTML={{
|
||||
__html: formatMm(path.length(), units),
|
||||
}}
|
||||
/>
|
||||
</NoSumDiv>
|
||||
</Li>
|
||||
<Ops ops={path.ops} />
|
||||
</Ul>
|
||||
)
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue