diff --git a/packages/mermaid/src/diagrams/architecture/architectureDb.ts b/packages/mermaid/src/diagrams/architecture/architectureDb.ts index 5d90bd8a6..4764671e8 100644 --- a/packages/mermaid/src/diagrams/architecture/architectureDb.ts +++ b/packages/mermaid/src/diagrams/architecture/architectureDb.ts @@ -41,7 +41,6 @@ export class ArchitectureDB implements DiagramDB { private groups: Record = {}; private edges: ArchitectureEdge[] = []; private registeredIds: Record = {}; - // private config: Required = DEFAULT_ARCHITECTURE_CONFIG; private dataStructures?: ArchitectureState['dataStructures']; private elements: Record = {}; @@ -184,7 +183,7 @@ export class ArchitectureDB implements DiagramDB { `The left-hand id [${lhsId}] does not yet exist. Please create the service/group before declaring an edge to it.` ); } - if (this.nodes[rhsId] === undefined && this.groups[lhsId] === undefined) { + if (this.nodes[rhsId] === undefined && this.groups[rhsId] === undefined) { throw new Error( `The right-hand id [${rhsId}] does not yet exist. Please create the service/group before declaring an edge to it.` ); @@ -359,7 +358,7 @@ export class ArchitectureDB implements DiagramDB { * @param field - the config field to access * @returns */ -// export function getConfigField( +// export function getConfigField( // field: T // ): Required[T] { // return db.getConfig()[field]; diff --git a/packages/mermaid/src/diagrams/architecture/architectureParser.ts b/packages/mermaid/src/diagrams/architecture/architectureParser.ts index f3d7771be..58820dad4 100644 --- a/packages/mermaid/src/diagrams/architecture/architectureParser.ts +++ b/packages/mermaid/src/diagrams/architecture/architectureParser.ts @@ -10,7 +10,7 @@ const populateDb = (ast: Architecture, db: ArchitectureDB) => { ast.groups.map((group) => db.addGroup(group)); ast.services.map((service) => db.addService({ ...service, type: 'service' })); ast.junctions.map((service) => db.addJunction({ ...service, type: 'junction' })); - // @ts-ignore ToDo our parser guarantees the type is L/R/T/B and not string. How to change to union type? + // @ts-ignore TODO our parser guarantees the type is L/R/T/B and not string. How to change to union type? ast.edges.map((edge) => db.addEdge(edge)); }; diff --git a/packages/mermaid/src/diagrams/architecture/architectureRenderer.ts b/packages/mermaid/src/diagrams/architecture/architectureRenderer.ts index ad435a29f..b29567236 100644 --- a/packages/mermaid/src/diagrams/architecture/architectureRenderer.ts +++ b/packages/mermaid/src/diagrams/architecture/architectureRenderer.ts @@ -191,7 +191,7 @@ function getAlignments( prev[dir] ??= []; prev[dir] = [...prev[dir], ...aNodeIds, ...bNodeIds]; // add the node ids of both groups to the axis array in prev } else if (aGroupId === 'default' || bGroupId === 'default') { - // If either of the groups are in the default space (not in a group), use the same behaviour as above + // If either of the groups are in the default space (not in a group), use the same behavior as above prev[dir] ??= []; prev[dir] = [...prev[dir], ...aNodeIds, ...bNodeIds]; } else {