ADE
AngularJS Datatype Editors
Install / Use
/learn @offsky/ADEREADME
AngularJS Datatype Editors (ADE)
ADE is a bunch of filters and directives for displaying and editing various types of data in an <a href="http://angularjs.org/">AngularJS</a> App. For example, if you have a unix timestamp that you want to display and make editable, ADE can display a formatted date string and make a popup calendar for editing.
Try our <a href="http://toodledo.github.com/ADE/index.html">Demo</a> and take a look at the demo examples in our source files.
ADE currently supports the following datatypes:
- Text (short)
- Text (long)
- URL
- Email Address
- Phone number
- Date
- Date + Time
- Year
- Time
- Money
- Decimal
- Integer
- Percent
- Length
- List (pick one)
- List (pick multiple)
- Rating
- Boolean
- Multi select
- Icon
Dependencies
All ADE datatypes depend on the following packages:
- angular 1.2.13
- jquery 1.11.0
The following packages are needed by their respective ADE datatypes:
- angular-sanitize 1.2.13: email and url
- bootstrap: date, email, icon, list, phone, rich, time, url
- font-awesome: icon directive
- tinymce 4.0.4 (for rich directive only) Use our modified version if you want keyboard commands to work.
The following packages included in ADE were modified to support a variety of use cases. You can use the unmodified packages available in bower, but we have not tested the results yet.
- datejs: date and time
- bootstrap-datepicker: date
- bootstrap-timepicker: time
- ngTagsInput: list and tag
We are working to reduce external dependencies as much as possible.
Installation
- Install ADE using bower:
$ bower install ADE
Or <a href="https://github.com/Toodledo/ADE/archive/master.zip">Download ZIP</a>.
Take a look at the "dist/build" directory.
- Add ADE's css and file to your HTML file:
CSS
<link rel="stylesheet" href="../bower_components/bootstrap/docs/assets/css/bootstrap.css"/>
<link rel="stylesheet" href="../bower_components/ADE/dist/build/ade.min.css"/>
JavaScript
<script src="../bower_components/jquery/jquery.js"></script>
<script src="../bower_components/angular/angular.js"></script>
<script src="../bower_components/angular-sanitize/angular-sanitize.js"></script>
<script src="../bower_components/ADE/dist/build/ade.min.js"></script>
- Inject ADE in your angular project:
var app = angular.module('app', ['ADE', 'ngSanitize']);
- Use the directives and filters in your HTML:
<div class="sample" ade-url='{"className":"input-medium"}' ng-model="dataurl" ng-bind-html="dataurl | url"></div>
Individual datatypes
You can also choose individual ADE datatypes to include in your project. Take a look at the example source files to know which files to include.
The following directives are required by their respective ADE datatypes. These directives are available in the "app/common" directory.
- number: decimal, integer, money and percent
- url: email, phone and url
Build
You can build the project for your specific use case. For example, you may want to pick several components and have their minifed/uglified result available in dist/build.
- Install node and grunt on your system
- Install node modules by running "npm install"
- Run our build script "scripts/build.sh"
License
ADE is freely distributable under the terms of the MIT license.
Related Skills
node-connect
337.3kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
83.2kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
337.3kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
commit-push-pr
83.2kCommit, push, and open a PR
