Skip to content
This repository was archived by the owner on Apr 18, 2024. It is now read-only.

Commit 1e33c4b

Browse files
authored
fix: DEV-3742: Toggling textrange visibility works in outliner (#1013)
1 parent 229fd84 commit 1e33c4b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/components/SidePanels/OutlinerPanel/OutlinerTree.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,7 @@ const RegionControls: FC<RegionControlsProps> = observer(({
366366
const { regions: regionStore } = useContext(OutlinerContext);
367367

368368
const hidden = useMemo(() => {
369-
if (type?.includes('region')) {
369+
if (type?.includes('region') || type?.includes('range')) {
370370
return entity.hidden;
371371
} else if ((!type || type.includes('label')) && regions) {
372372
return Object.values(regions).every(({ hidden }) => hidden);
@@ -375,7 +375,7 @@ const RegionControls: FC<RegionControlsProps> = observer(({
375375
}, [entity, type, regions]);
376376

377377
const onToggleHidden = useCallback(() => {
378-
if (type?.includes('region')) {
378+
if (type?.includes('region') || type?.includes('range')) {
379379
entity.toggleHidden();
380380
} else if(!type || type.includes('label')) {
381381
regionStore.setHiddenByLabel(!hidden, entity);

0 commit comments

Comments
 (0)