abidibo.net

Calculator demo page

Welcome to the Calculator demo page!
Let's take a look at the example provided, notice that the calculator aspect can be easily styled through css!

Example

Let's create a 14-digits calculator when clicking the button 'calculator'. Click the button again to hide/show the calculator. The calculator is rendered over the document and made draggable.

calculator

Javascript

var calc;
manageCalculator = function() {
  if(typeof calc == 'undefined') {
    calc = new Calculator({
      drag: true,
      digits: 14
    });
  }
  else {
    calc.toggle();
  }
}

Html

<button onclick="manageCalculator();">calculator</button>

project page documentation download

blog comments powered by Disqus