1
0
Fork 0

chore: linter issues

This commit is contained in:
joostdecock 2023-02-05 19:58:25 +01:00
parent c894deb912
commit 86aa0f20da
34 changed files with 83 additions and 102 deletions

View file

@ -1,4 +1,5 @@
import { useTranslation } from 'next-i18next'
import { ClearIcon } from 'shared/components/icons.mjs'
const Triangle = ({ transform = 'translate(0,0)', fill = 'currentColor' }) => (
<path
@ -11,6 +12,10 @@ const Triangle = ({ transform = 'translate(0,0)', fill = 'currentColor' }) => (
/>
)
const Line = () => (
<path strokeLinecap="round" strokeLinejoin="round" transform="translate(12, 2)" d="M0 0L0 20" />
)
const FlipIconInner = ({ x = 0, y = 0, rotate = 0, ...style }) => (
<g transform={`translate(${x},${y}) rotate(${rotate})`} transform-origin="12 12" style={style}>
<Triangle fill="none" transform="translate(0, 2.5)" />
@ -49,7 +54,7 @@ const Button = ({ onClickCb, transform, Icon, children }) => {
}
/** buttons for manipulating the part */
export const Buttons = ({ transform, flip, rotate, setRotate, resetPart, rotate90 }) => {
export const Buttons = ({ transform, flip, rotate, resetPart, rotate90 }) => {
const { t } = useTranslation('workbench')
return (
<g transform={transform}>
@ -61,7 +66,7 @@ export const Buttons = ({ transform, flip, rotate, setRotate, resetPart, rotate9
<Button
onClickCb={resetPart}
transform={`translate(${rectSize / -2}, ${rectSize / -2})`}
Icon={ClearIconInner}
Icon={ClearIcon}
>
{t('toolbar.resetPart')}
</Button>