Skip to content

Commit

Permalink
Make font-size constant
Browse files Browse the repository at this point in the history
  • Loading branch information
fatih-erikli committed Dec 20, 2023
1 parent 0bca7d3 commit 576a11b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/fontra/views/editor/panel-reference-font.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ import { registerVisualizationLayerDefinition } from "./visualization-layer-defi
let referenceFontModel;

const fontFileExtensions = new Set(["ttf", "otf", "woff", "woff2"]);
const DEFAULT_FONT_SIZE = 100;

registerVisualizationLayerDefinition({
identifier: "fontra.reference.font",
Expand Down Expand Up @@ -255,7 +256,6 @@ export default class ReferenceFontPanel extends Panel {
}
.current-character {
font-size: 14px;
overflow: auto;
}
Expand Down Expand Up @@ -379,7 +379,7 @@ export default class ReferenceFontPanel extends Panel {
type: "range",
value: this.model.fontSize,
minValue: 10,
defaultValue: 100,
defaultValue: DEFAULT_FONT_SIZE,
maxValue: 300,
step: 0.1,
onChangeCallback: (event) => {
Expand Down Expand Up @@ -606,7 +606,7 @@ export default class ReferenceFontPanel extends Panel {

this.controller = new ObservableController({
languageCode: "",
fontSize: 14,
fontSize: DEFAULT_FONT_SIZE,
selectedFontIndex: -1,
fontList: [],
charOverride: "",
Expand Down

0 comments on commit 576a11b

Please sign in to comment.