Hack sectional

This commit is contained in:
Pierre Jacquier
2025-03-10 18:09:21 -04:00
parent 434f1045ef
commit 9744d13d4f
2 changed files with 38 additions and 24 deletions

View File

@ -1435,30 +1435,42 @@ sketch002 = startSketchOn('XZ')
// TODO: this test hits a case that happens sometimes in manual testing where // TODO: this test hits a case that happens sometimes in manual testing where
// we can't edit the sweep right after its creation. As if the codemod didn't fully // we can't edit the sweep right after its creation. As if the codemod didn't fully
// register during the initall add flow. // register during the initall add flow.
// await test.step('Edit sweep via feature tree selection works', async () => { await test.step('Edit sweep via feature tree selection works', async () => {
// await toolbar.openPane('feature-tree') await toolbar.openPane('feature-tree')
// const operationButton = await toolbar.getFeatureTreeOperation('Sweep', 0) const operationButton = await toolbar.getFeatureTreeOperation('Sweep', 0)
// await operationButton.dblclick({ button: 'left' }) await operationButton.dblclick({ button: 'left' })
// await cmdBar.selectOption({ name: 'True' }).click() await cmdBar.selectOption({ name: 'True' }).click()
// await cmdBar.expectState({ await cmdBar.expectState({
// commandName: 'Sweep', commandName: 'Sweep',
// headerArguments: { headerArguments: {
// Target: '1 face', Target: '1 face',
// Trajectory: '1 segment', Trajectory: '1 segment',
// Sectional: '', Sectional: '',
// }, },
// stage: 'review', stage: 'review',
// }) })
// await cmdBar.progressCmdBar() const submitButton = page.getByRole('button', { name: 'Submit command' })
// await toolbar.closePane('feature-tree') await submitButton.press('Shift+Backspace')
// await toolbar.openPane('code') await cmdBar.selectOption({ name: 'True' }).click()
// await editor.expectEditor.toContain(editedSweepDeclaration) await cmdBar.expectState({
// await editor.expectState({ commandName: 'Sweep',
// diagnostics: [], headerArguments: {
// activeLines: [editedSweepDeclaration], Target: '1 face',
// highlightedCode: '', Trajectory: '1 segment',
// }) Sectional: '',
// }) },
stage: 'review',
})
await cmdBar.progressCmdBar()
await toolbar.closePane('feature-tree')
await toolbar.openPane('code')
await editor.expectEditor.toContain(editedSweepDeclaration)
await editor.expectState({
diagnostics: [],
activeLines: [editedSweepDeclaration],
highlightedCode: '',
})
})
await test.step('Delete sweep via feature tree selection', async () => { await test.step('Delete sweep via feature tree selection', async () => {
await toolbar.openPane('feature-tree') await toolbar.openPane('feature-tree')

View File

@ -195,6 +195,8 @@ pub(crate) async fn do_post_extrude(
for (curve_id, face_id) in face_infos for (curve_id, face_id) in face_infos
.iter() .iter()
.filter(|face_info| face_info.cap == ExtrusionFaceCapType::None) .filter(|face_info| face_info.cap == ExtrusionFaceCapType::None)
// TODO: change this hack to a filtering of internal faces for sweep
.filter(|_face_info| false)
.filter_map(|face_info| { .filter_map(|face_info| {
if let (Some(curve_id), Some(face_id)) = (face_info.curve_id, face_info.face_id) { if let (Some(curve_id), Some(face_id)) = (face_info.curve_id, face_info.face_id) {
Some((curve_id, face_id)) Some((curve_id, face_id))