OGX.JS Javascript Framework version 1.20.0
2022-09-13

We are pleased to announce that OGX.JS Javascript Framework version 1.20.0 have been released.
What is OGX.JS ? It is the fastest framework to build mobile, web and desktop apps from scratch!
Here is the changelog for this version:
Experimental Features
[Workers] New object to manage and execute `WebWorkers` on the fly
New Features
events vs callbacks
Starting at version 1.20, events for most `Uxi`'s now have an equivalent method, if you do not wish to use events. It also opens more possibility, like adding some of your business logic in `OML`.
You can now set your callbacks in the config when creating a `Uxi`, i.e., for `DynamicList` if you are creating at runtime:
{
...,
"callbacks" : {
"select" : YOUR_FUNCTION
"unselect" : YOUR_FUNCTION
}
}
You can also use the new `OSE` `method` keyword to target a `Uxi`'s method when creating from `OML`, such as, for a method of the view instance
{
...,
"callbacks" : {
"select:OSE" : "method the_method_of_my_view myView:View"
}
}
Dynamic Forms
Another new feature that was missing, was the ability to create dynamic forms on the fly. So far, forms relied on Templates. Now you can generate forms using OGX objects to control each type of field. See the Form section for mpore info
let myFormInstance = OGX.Form.fromObject(MY_OBJECT, PARENT_UXI, SELECTOR); myFormInstance.onChange = function(obj){...};
Changes
[OSE] new keyword `method` to target a `Uxi`'s `method`, format `method METHOD_NAME UXI_ID:UXI_TYPE`
[DynamicList] added `onSelect` and `onUnselect` methods, and `callbacks.select`, `callbacks.unselect` in `config`
[Tabs] added `onSelect`, `onAdd`, `onRemove` methods, and `callbacks.select`, `callbacks.add`, `callbacks.remove` in `config`
[Tags] added `onSelect`, `onAdd`, `onRemove` methods, and `callbacks.select`, `callbacks.add`, `callbacks.remove` in `config`
[Iceberg] added `onUp`, `onDown`, `onLeft`, `onRight`, `onRestore` methods, and `callbacks.up`, `callbacks.down`, `callbacks.left`, `callbacks.right`, `callbacks.restore` in `config`
[Tree] added `onSelect`, `onUnselect`, `onOpen`, `onClose`, `onMove` methods, and `callbacks.select`, `callbacks.unselect`, `callbacks.open`, `callbacks.close`, `callbacks.move` in `config`
[GridSwiper] added `onUp`, `onDown`, `onLeft`, `onRight` methods, and `callbacks.up`, `callbacks.down`, `callbacks.left`, `callbacks.right` in `config`
[NestList] added `onOpen`, `onClose` method, and `callbacks.open`, `callbacks.close` in `config`
[Calendar] added `onSelect`,` onUnselect` method, and `callbacks.select`, `callbacks.unselect` in `config`
[Carousel] added `onChange` method, and `callbacks.change` in `config`
[Dots] added `onSelect` method, and `callbacks.select` in `config`
[Roulette] added `onChange` method, and `callbacks.change` in `config`
[Switch] added `onChange` method, and `callbacks.change` in `config`
[Form] new `FormInstance` subclass created from `fromObject` method
Other Changes
[Calendar] `format` of built-in `layouts` can now be overridden in the config of the layout
[Calendar] custom layout can now receive a config object
[OSE] prevent reserved keywords interferring with scripts
Breaking Changes
Calendar layout and engine setup format has changed to allow custom parameters to built-in layouts, without the need to create a custom layout. Before 1.20, only the engine could receive data via a config object
{
"layout":"WEEK_DAYS", "engine":"CUSTOM_ENGINE", "config":{}
}
Since 1.20, both the layout and engine can be passed a custom object. The layout and the engine must be declared by name now.
{
"layout":{
"name":"WEEK_DAYS", "config":{"format" : "YYYY"}
},
"engine":{
"name":"CUSTOM_ENGINE", "config":{}
}
}
Bug Fixes
[Touch] fix issue with `Swipe` and `Carousel`
[App] fix issue if `App` is created without config object
[Tree] fix issue when creating an empty `Tree`
[Tree] fix issue with selection and icons
[Tree] fix issue with `Scroller` on new tree
[Tree] `icons` now handled via `css`
Other changes
[Theme] default theme updated to version `1.2.61`
OGX.JSJavascript