-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/5061/
-----------------------------------------------------------

Review request for rave.


Summary
-------

This adds the ability to register new popup definitions to be used inside the 
container. This is to overcome the issue where we can't skin the current popups.

This is my initial approach. Let me know if there is a better way to handle 
this. Ref mailing list discussion at: 
http://markmail.org/thread/nipyntndlktosi67


This addresses bug RAVE-613.
    https://issues.apache.org/jira/browse/RAVE-613


Diffs
-----

  /trunk/rave-portal-resources/src/main/webapp/script/rave.js 1335243 

Diff: https://reviews.apache.org/r/5061/diff


Testing
-------

This capability requires having custom js so it isn't able to test as part of 
the standard rave install. I use the files below to register my popup which 
works. Then I use a modified open_views gadget to load it. The JS below needs 
to be loaded through the custom_js.tag mechanism into the container.

var rave = rave || {};

var fullwidth_dialog = {
        name:"dialog",
        containerSelector:'.popup.dialog',
        contentSelector:'.modal-body',
        markup:'<div class="popup dialog modal fade"><div 
class="modal-body"></div></div>',
        initialize:function (container) {
            container.find(this.contentSelector).data('popupType', this.name);
            var cfg = {
            };
            container.modal(cfg);

            container.on('hidden', function () {
                container.detach();
            })
        },
        cleanup:function (content) {
            var container = content.parents(this.containerSelector);

            container.modal('hide');
        },
        singleton:false
    };

rave.registerPopup("fullwidth_dialog", fullwidth_dialog);


Thanks,

Chris

Reply via email to