Skip to content

Commit

Permalink
typing improvement
Browse files Browse the repository at this point in the history
  • Loading branch information
IKoshelev committed Dec 24, 2023
1 parent c59e985 commit c2436b3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions main.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { CanvasData, CanvasEdgeData, CanvasFileData, CanvasLinkData, CanvasNodeData, CanvasTextData } from 'obsidian/canvas';
import { App, FuzzySuggestModal, getAllTags, ItemView, Notice, Plugin } from 'obsidian';

export interface CanvasGroupData {
export interface CanvasGroupData extends CanvasNodeData {
type: 'group',
label: string
}

function isCanvasGroupData(node: any): node is CanvasGroupData {
return node?.type === 'group';
function isCanvasGroupData(node: CanvasNodeData): node is CanvasGroupData {
return (node as any)?.type === 'group';
}

function nodeBondingBoxContains(outerNode: CanvasNodeData, innerNode: CanvasNodeData) {
Expand Down

0 comments on commit c2436b3

Please sign in to comment.