Skip to content

bkatzung/fauxcus

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

Fauxcus (Fake Focus)

This module implements a minimalist <input> text input UI (by directly handling keyboard events) without setting the actual browser focus on the element.

It does not implement a movable cursor (additions or deletions are always at the end) or text selections.

It was created to allow text input within CKEditor 5 (CKE5) formatting-menu items. CKE5 has a tendency to either remove the selection highlight (best case) or completely terminate editing and remove the editing interface (worst case) when it detects browser focus changes.

The module will manage the "fauxcus" for any <input> element that is a descendent of an element with class fauxcus.

The module currently shows "fauxcus" by setting the text to be white on a dark background, but this can easily be customized by changing a little bit of CSS.

Key Assignments

  • Command/Ctrl-A or Home - clears the input
  • Command/Ctrl-C - copies the (entire) input to the clipboard
  • Command/Ctrl-V - replaces the input with the clipboard contents
  • Backspace or Delete - deletes the last input character
  • Tab and Shift-Tab - navigates between elements (which will set focus, if navigating to a non-"fauxcus" element!)

About

Fake input focus

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published