Skip to content

Commit

Permalink
fix: import old sdf #103
Browse files Browse the repository at this point in the history
  • Loading branch information
SilenceLeo committed Jun 24, 2024
1 parent efdf59a commit 4cddc56
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap"
/>
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<link rel="canonical" href="https://snowb.org/" />
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
Expand Down
3 changes: 2 additions & 1 deletion src/store/project.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ class Project {
get glyphList() {
return Array.from(` ${this.text}`)
.map((letter) => this.getGlyph(letter) as GlyphFont | GlyphImage)
.filter((glyph) => glyph)
}

get rectangleList(): TextRectangle[] {
Expand Down Expand Up @@ -331,7 +332,7 @@ class Project {
this.text = str.replace(/\s/gm, '')
this.addGlyphs(oldText)
}

addGlyphs(oldText = ''): void {
const currentList = Array.from(new Set(Array.from(this.text)))
const oldList = Array.from(new Set(Array.from(oldText)))
Expand Down

0 comments on commit 4cddc56

Please sign in to comment.