Skip to content

Commit

Permalink
eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
omervk committed Feb 25, 2024
1 parent 619e67e commit d9e3c25
Showing 1 changed file with 23 additions and 18 deletions.
41 changes: 23 additions & 18 deletions packages/design/src/diagram/parser.d.ts
Original file line number Diff line number Diff line change
@@ -1,28 +1,33 @@
export type DirStatement = { stmt: 'dir', value: 'TB' | 'BT' | 'LR' | 'RL' }
export type DirStatement = { stmt: 'dir'; value: 'TB' | 'BT' | 'LR' | 'RL' }
export type StateStatement = {
stmt: 'state',
id: string,
type: 'default' | 'choice' | 'fork' | 'join' | 'divider',
classes?: string[],
description?: string,
doc?: string,
note?: { position: string, text: string }
stmt: 'state'
id: string
type: 'default' | 'choice' | 'fork' | 'join' | 'divider'
classes?: string[]
description?: string
doc?: string
note?: { position: string; text: string }
}
export type RelationStatement = { stmt: 'relation', state1: { id: string }, state2: { id: string }, description?: string }
export type ClassDefStatement = { stmt: 'classDef', id: string, classes: string[] }
export type ApplyClassStatement = { stmt: 'applyClass', id: string, styleClass: string }
export type RelationStatement = {
stmt: 'relation'
state1: { id: string }
state2: { id: string }
description?: string
}
export type ClassDefStatement = { stmt: 'classDef'; id: string; classes: string[] }
export type ApplyClassStatement = { stmt: 'applyClass'; id: string; styleClass: string }
export type Statement = DirStatement | StateStatement | RelationStatement | ClassDefStatement | ApplyClassStatement

export interface YY {
getDividerId: () => string;
setAccTitle: (string) => void;
setAccDescription: (string) => void;
setDirection: (string) => void;
setRootDoc: (string) => void;
trimColon: (string) => string;
getDividerId: () => string
setAccTitle: (string) => void
setAccDescription: (string) => void
setDirection: (string) => void
setRootDoc: (string) => void
trimColon: (string) => string
}

export const parser: {
yy: YY
parse: (string) => Statement[]
}
}

0 comments on commit d9e3c25

Please sign in to comment.