Control Bar

Default js-dos interface includes control bar component. It can be opened by pressing on โ–ผ button. This bar implement some useful actions that needed very often:

  • Text input field for sending textual data on mobile devices
  • Save feature
  • Fullscreen button that toggles fullscreen on supported browsers


If you don't like the style of control bar or you need to place it somewhere else then you can detach it. To do this you need to provide optional controlSelector parametr to Dos function.

Control selector interface:

export interface ControlSelector {
input: () => HTMLInputElement;
send: () => HTMLElement;
save: () => HTMLElement;
fullscreen: () => HTMLElement;
  • input must return <input> element to read text from
  • send is a clickable element that triggers reading from input
  • save is a clickable element that triggers save feature
  • fullscreen is a clickable element that toggles fullscreen

Complete example: