Skip to content

Commit ef5ee30

Browse files
tidy(ui): minor type fix
1 parent 5d5c49b commit ef5ee30

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

invokeai/frontend/web/src/features/controlLayers/konva/CanvasEntity/CanvasEntityFilterer.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { addCoords, getKonvaNodeDebugAttrs, getPrefixedId } from 'features/contr
99
import { selectAutoProcess } from 'features/controlLayers/store/canvasSettingsSlice';
1010
import type { FilterConfig } from 'features/controlLayers/store/filters';
1111
import { getFilterForModel, IMAGE_FILTERS } from 'features/controlLayers/store/filters';
12-
import type { CanvasEntityType, CanvasImageState } from 'features/controlLayers/store/types';
12+
import type { CanvasImageState, CanvasRenderableEntityType } from 'features/controlLayers/store/types';
1313
import { imageDTOToImageObject } from 'features/controlLayers/store/util';
1414
import Konva from 'konva';
1515
import { debounce } from 'lodash-es';
@@ -350,7 +350,7 @@ export class CanvasEntityFilterer extends CanvasModuleBase {
350350
* Saves the filtered image as a new entity of the given type.
351351
* @param type The type of entity to save the filtered image as.
352352
*/
353-
saveAs = (type: Exclude<CanvasEntityType, 'reference_image'>) => {
353+
saveAs = (type: CanvasRenderableEntityType) => {
354354
const imageState = this.$imageState.get();
355355
if (!imageState) {
356356
this.log.warn('No image state to apply filter to');

invokeai/frontend/web/src/features/controlLayers/konva/CanvasSegmentAnythingModule.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ import {
1515
} from 'features/controlLayers/konva/util';
1616
import { selectAutoProcess } from 'features/controlLayers/store/canvasSettingsSlice';
1717
import type {
18-
CanvasEntityType,
1918
CanvasImageState,
19+
CanvasRenderableEntityType,
2020
Coordinate,
2121
RgbaColor,
2222
SAMPointLabel,
@@ -697,7 +697,7 @@ export class CanvasSegmentAnythingModule extends CanvasModuleBase {
697697
* Saves the segmented image as a new entity of the given type.
698698
* @param type The type of entity to save the segmented image as.
699699
*/
700-
saveAs = (type: Exclude<CanvasEntityType, 'reference_image'>) => {
700+
saveAs = (type: CanvasRenderableEntityType) => {
701701
const imageState = this.$imageState.get();
702702
if (!imageState) {
703703
this.log.error('No image state to save as');

0 commit comments

Comments
 (0)