Giter Club home page Giter Club logo

ascii-ui's Introduction

ascii-ui

Build Status

There are several projects [1][2] allowing you to use the JavaScript canvas in the terminal, while other projects [1][2][3][4] (know more? tell me!) give you some IU tools to create text-based interfaces in the terminal, but... have you ever needed (or just wanted) to use a text-based UI in a HTML page?

Really

Not even once?

. . .

Well, thanks to my lack of empathy, this project gives you access to a ncurses-like low-level interface working over a HTMLCanvasElement buffer to render characters like the old style terminals (apart from the great perk of using your time to fight with this library instead of being laying in the corner of a dark street giving yourself to the drugs and alcohol).

Input Widget demo

Excited yet? Jump directly to the API documentation!

Not enough? Well, lucky you, there are some prepared examples already deployed here, and here is their code so you to see how to use the library.

You can play with these examples, modify the code and try it running npm run start (or yarn start) to have a local server for development (or even build your own static version via npm run examples or yarn examples).

Just remember that this is a 0.x.x version and the interface can change from time to time until the version 1.0.0 is reached ;)

Changelog

0.3.0

  • Text (tokenizer) now supports new lines with \n

0.2.0

Core:

  • Added support for spriteFonts (Terminal.setImage)
  • Added minWidth, minHeight, maxWidth and maxHeight options to the Terminal
  • Added Widget.destruct

Widgets:

  • Added border feature in widgets/Grid
  • Improved widgets/Select with new methods and styling options

Others:

  • Added EventManager.removeListener (and rename listen to addListener)
  • Cleaner code with new tslint rules
  • Removed some dependencies

0.1.0

First version of the Terminal with a few widgets (Box, Grid, Input, ProgressBar, Select, Text), a FocusManager and an EventManager.

Usable but still in development, so the interface could change and bugs can happen.

Feel free to test it and create an issue with any bug you found or any idea/request you might have.

ascii-ui's People

Contributors

danikaze avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.