My favorites | Sign in
Project Home Downloads Wiki Issues Source
Search
for
TextWidget  
Build text interactions into your application.
Updated Feb 4, 2010 by julien.c...@gmail.com

Introduction

TextWidget is a small javascript library, which simplifies the creation of interactive sentences.

The text interface of the widget is user-friendly, as it displays it's current state as a natural language sentence, and it can easily be modified by the user clicking some hyperlinks until the desired state/configuration is achieved.

Example

If the user wanted to configure a reminder for an appointment in his calendar:

Do not remind me.

If the user clicks "Do not", the sentence changes to:

Do remind me 15 minutes before the appointment, with an alarm.

Both "15 minutes" and "alarm" are clickable so that the user can achieve the desired configuration.

Install

Just get a copy of TextWidget.js and include it into your web application. You can see an example in the Unittest.html file.

Testing

Aside from running the interactive demo implemented in Unittest.html, there is also a set of automated unittests in that file. To run them, you need a test harness, jsUnit. You will need to get a copy of jsUnit.

Here is an example of how to use it (after adjusting the paths):

file:///D:/data/TextWidget/jsunit/testRunner.html?testpage=D:/data/TextWidget/Unittest.html

You can also load the page to do manual testing: file:///D:/data/TextWidget/Unittest.html

More information at: http://blog.monstuff.com/archives/000317.html


Sign in to add a comment
Powered by Google Project Hosting