[OpenAjaxIDE] JSON serialization of OAM
Jon Ferraiolo
jferrai at us.ibm.com
Wed Sep 15 08:41:03 PDT 2010
There hasn't been any recent email on this list, but I wanted to make sure
everyone was aware that IBM has a browser-based project where we are using
a JSON version of OpenAjax Widgets as our primary format for widgets. We
will send detailed spec proposals at some point and will submit code to the
OpenAjax open source repository, but right now we are all busy with our day
jobs.
But to show what we have in mind, below is a sample widget where the JSON
version of OAM wraps a Dojo button widget. Note that we still have some
work to do with <library> and <require>. Our current code works now because
Dojo/Dijit are installed at particular locations but we need to clean
things up so that the OAM widgets are portable to other tools.
Button_oam.json:
{
"xmlns": "http://openajax.org/metadata",
"spec": "1.0",
"version": "1.0",
"name": "dijit.form.Button",
"id": "http://dojotoolkit.org/dijit/form/Button",
"jsClass": "dijit.form.Button",
"property": {
"type": {
"datatype": "string",
"option": [
{
"value": "button"
},
{
"value": "submit"
},
{
"value": "reset"
}
],
"defaultValue": "button",
"title": "Type"
},
"name": {
"datatype": "string",
"title": "Name"
},
"alt": {
"datatype": "string",
"hidden": true
},
"value": {
"datatype": "string",
"title": "Value"
},
"tabIndex": {
"datatype": "string",
"defaultValue": "0",
"title": "Tab Index"
},
"disabled": {
"datatype": "boolean",
"title": "Disabled"
},
"readOnly": {
"datatype": "boolean",
"hidden": true
},
"intermediateChanges": {
"datatype": "boolean",
"hidden": true
},
"label": {
"datatype": "string",
"title": "Label"
},
"showLabel": {
"datatype": "boolean",
"defaultValue": true,
"title": "Show Label"
},
"iconClass": {
"datatype": "string",
"title": "Icon Class"
},
"scrollOnFocus": {
"datatype": "boolean",
"description": "On focus, should this widget scroll into
view?",
"hidden": false,
"defaultValue": true
},
},
"content": "<input type='button'></input>",
"require": [
{
"type": "javascript",
"src": "dijit/form/Button.js"
}
]
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://openajax.org/pipermail/ide/attachments/20100915/4fc657f3/attachment.html
More information about the IDE
mailing list