Skip to content

Commit

Permalink
fix: default statblock now respected
Browse files Browse the repository at this point in the history
  • Loading branch information
valentine195 committed Dec 22, 2021
1 parent 082183c commit d517b02
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -438,8 +438,11 @@ export default class StatBlockPlugin extends Plugin {

let layout =
this.settings.layouts.find(
(layout) => layout.name == params?.layout
) ?? Layout5e;
(layout) =>
layout.name == params?.layout ||
layout.name == params?.statblock
) ?? this.defaultLayout;
console.log("🚀 ~ file: main.ts ~ line 440 ~ layout", layout);

let statblock = new StatBlockRenderer(
el,
Expand Down

0 comments on commit d517b02

Please sign in to comment.