diff --git a/actions.js b/actions.js index 27a734c..6f03069 100755 --- a/actions.js +++ b/actions.js @@ -1724,7 +1724,8 @@ module.MetaActions = { // defaults... options = options || {} var descriptors = options.descriptors == null ? true : false - var all_attr_types = options.all_attr_types == null ? false : true + var all_attr_types = !!options.all_attr_types + var action_handlers = !!options.action_handlers var source_tag = options.source_tag resetHandlerCache = (this.resetHandlerCache || MetaActions.resetHandlerCache) @@ -1763,6 +1764,13 @@ module.MetaActions = { || attr instanceof Action){ that[k] = attr } + // copy the action handlers... + if(action_handlers && k == '__action_handlers' && attr){ + var h = that[k] = {} + Object.entries(attr) + .forEach(function([k, v]){ + h[k] = v.slice() }) } + // source tag actions... // XXX should this set action and method .source_tag or only action??? //if(source_tag && attr instanceof Action){ @@ -1833,6 +1841,8 @@ module.MetaActions = { // not be affected... // NOTE: this will not affect event handlers, they should be removed // manually if needed... + // + // XXX do .__action_handlers??? inlineMixout: function(from, options){ // defaults... options = options || {} diff --git a/package.json b/package.json index 31733f4..54bc4c0 100755 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ig-actions", - "version": "3.24.27", + "version": "3.24.28", "description": "", "main": "actions.js", "scripts": {