error in node module when use the library

This issue has been tracked since 2022-10-11.

Simple-keyboard version
"simple-keyboard": "latest",

Describe the bug
i install the latest version of the library in my angular project (angular 11) and use
this is my implement code:

in ts file:

import Keyboard from 'simple-keyboard';


keyboard!: Keyboard;
value = "";
keyboard!: Keyboard;
  value = "";
  ngAfterViewInit() {
    this.keyboard = new Keyboard({
      onChange: input => this.onChange(input),
      onKeyPress: (button:any) => this.onKeyPress(button)
    });
  }

  onChange = (input: string) => {
    this.value = input;
    console.log("Input changed", input);
  };

  onKeyPress = (button: string) => {
    console.log("Button pressed", button);

    /**
     * If you want to handle the shift and caps lock buttons
     */
    if (button === "{shift}" || button === "{lock}") this.handleShift();
  };

  onInputChange = (event: any) => {
    this.keyboard.setInput(event.target.value);
  };

  handleShift = () => {
    let currentLayout = this.keyboard.options.layoutName;
    let shiftToggle = currentLayout === "default" ? "shift" : "default";

    this.keyboard.setOptions({
      layoutName: shiftToggle
    });
  };

and in html :

<div style="text-align:center">
	<input (input)="onInputChange($event)" class="input" value={{value}} placeholder="Tap on the virtual keyboard to start" />
	<div class="simple-keyboard"></div>
</div>

and when i serve the project the following error accurs in my console:

Screenshots
tempsnip

hodgef wrote this answer on 2022-10-16

Wow that's a new one. Do you mind providing a test git repo so I can debug this issue?

Will reopen once I get the repro. Thanks!

More Details About Repo
Owner Name hodgef
Repo Name simple-keyboard
Full Name hodgef/simple-keyboard
Language JavaScript
Created Date 2018-03-02
Updated Date 2022-12-06
Star Count 1738
Watcher Count 20
Fork Count 130
Issue Count 0

YOU MAY BE INTERESTED

Issue Title Created Date Updated Date