fillet ui follow up (#3035)

This commit is contained in:
Kurt Hutten
2024-07-17 13:58:48 +10:00
committed by GitHub
parent 2f0002e53c
commit 36464e6984
4 changed files with 4 additions and 5 deletions

View File

@ -3,6 +3,7 @@ import { useCommandsContext } from 'hooks/useCommandsContext'
import { useKclContext } from 'lang/KclProvider'
import { CommandArgument } from 'lib/commandTypes'
import {
Selection,
canSubmitSelectionArg,
getSelectionType,
getSelectionTypeDisplayText,
@ -11,13 +12,13 @@ import { modelingMachine } from 'machines/modelingMachine'
import { useCallback, useEffect, useRef, useState } from 'react'
import { StateFrom } from 'xstate'
const semanticEntityNames = {
const semanticEntityNames: { [key: string]: Array<Selection['type']> } = {
face: ['extrude-wall', 'start-cap', 'end-cap'],
edge: ['edge', 'line', 'arc'],
point: ['point', 'line-end', 'line-mid'],
}
function getSemanticSelectionType(selectionType: string[]) {
function getSemanticSelectionType(selectionType: Array<Selection['type']>) {
const semanticSelectionType = new Set()
selectionType.forEach((type) => {
Object.entries(semanticEntityNames).forEach(([entity, entityTypes]) => {

View File

@ -33,7 +33,6 @@ import { applyConstraintAngleLength } from './Toolbar/setAngleLength'
import {
Selections,
canExtrudeSelection,
canFilletSelection,
handleSelectionBatch,
isSelectionLastLine,
isRangeInbetweenCharacters,

View File

@ -30,7 +30,6 @@ import {
} from '../std/sketch'
import { err } from 'lib/trap'
import { Selections, canFilletSelection } from 'lib/selections'
// import { forEach } from 'jszip'
export function addFillet(
node: Program,

File diff suppressed because one or more lines are too long