ModulePanel is a simple extension for Sencha ExtJS that creates a standard panel that is segmented in "module" panels, each being a child item of the main panel. Modules component can than be re-arranged by the user and the custom layout saved in the browser.
The component can be created using Ext.create (Ext.ux.ModulePanel) or using the xtype (modulepanel). Passed configuration can include the following, as well as any other panel properties. Properties marked with
* are required.
*modules: array of Ext.Panel items
columns: number of module columns in the layout (default 3)
animateModules: true/false to enable module swapping animation (default true)
The component has the following public methods/functions:
saveModuleLayout(): Saves the module layout via cookies
resetModuleLayout(): Clears layout cookies
configureModules(state): Sets modules to allow user to configure. Passed single state variable, directly from button handlers.
You can view the source file here.