Commit 9f009acf authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

update renderjs : rev b30668ded565234de3e72bf0f4f9919c4ccf1d5b.

* add minified version
* now depend on jquery on erp5_jquery_plugin_json instead of erp5_jquery_plugin_jstorage.
parent d22d7a11
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="File" module="OFS.Image"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Cacheable__manager_id</string> </key>
<value> <string>http_cache</string> </value>
</item>
<item>
<key> <string>_EtagSupport__etag</string> </key>
<value> <string>ts58177449.44</string> </value>
</item>
<item>
<key> <string>__name__</string> </key>
<value> <string>renderjs.min.js</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>application/javascript</string> </value>
</item>
<item>
<key> <string>data</string> </key>
<value> <string encoding="cdata"><![CDATA[
/*global console, require, $, localStorage, document */"use strict";var RENDERJS_ENABLE_IMPLICIT_GADGET_RENDERING=!0,RENDERJS_ENABLE_IMPLICIT_INTERACTION_BIND=!0;if(typeof console=="undefined"||typeof console.log=="undefined")console={},console.log=function(){};var RenderJs=function(){var is_ready=!1;return{init:function(){RENDERJS_ENABLE_IMPLICIT_GADGET_RENDERING&&RenderJs.bootstrap($("body"));if(RENDERJS_ENABLE_IMPLICIT_INTERACTION_BIND){var a=RenderJs.GadgetIndex.getRootGadget();a!==undefined&&RenderJs.bindReady(function(){$("div[data-gadget-connection]").each(function(a,b){RenderJs.InteractionGadget.bind($(b))})})}},bootstrap:function(a){var b,c;b=a.attr("id"),c=a.attr("data-gadget")!==undefined,RenderJs.setReady(!1),c&&b!==undefined&&RenderJs.loadGadget(a),RenderJs.loadRecursiveGadget(a)},loadRecursiveGadget:function(a){var b,c,d,e;b=a.find("[data-gadget]"),b.each(function(){c=$(this),d=c.attr("id"),e=new RenderJs.Gadget(d,c),RenderJs.GadgetIndex.registerGadget(e)}),b.each(function(){RenderJs.loadGadget($(this))})},setGadgetAndRecurse:function(a,b){a.append(b),RenderJs.loadRecursiveGadget(a)},loadGadget:function(a){var b,c,d,e,f,g,h,i,j;b=a.attr("data-gadget"),c=a.attr("id"),i=RenderJs.GadgetIndex.getGadgetById(c),i===undefined&&(i=new RenderJs.Gadget(c,a),RenderJs.GadgetIndex.registerGadget(i)),d=a.attr("data-gadget-property"),d!==undefined&&(d=$.parseJSON(d),$.each(d,function(a,b){i[a]=b})),b!==undefined&&b!==""?(e=a.attr("data-gadget-cacheable"),f=a.attr("data-gadget-cache-id"),e!==undefined&&f!==undefined&&(e=Boolean(parseInt(e,10))),e?(g=RenderJs.Cache.get(f,undefined),g===undefined||g===null?$.ajax({url:b,yourCustomData:{gadget_id:c,cache_id:f},success:function(b){f=this.yourCustomData.cache_id,c=this.yourCustomData.gadget_id,RenderJs.Cache.set(f,b),RenderJs.GadgetIndex.getGadgetById(c).setReady(),RenderJs.setGadgetAndRecurse(a,b),RenderJs.checkAndTriggerReady(),RenderJs.updateGadgetData(a)}}):(h=g,i.setReady(),this.setGadgetAndRecurse(a,h),this.checkAndTriggerReady(),RenderJs.updateGadgetData(a))):$.ajax({url:b,yourCustomData:{gadget_id:c},success:function(b){c=this.yourCustomData.gadget_id,RenderJs.GadgetIndex.getGadgetById(c).setReady(),RenderJs.setGadgetAndRecurse(a,b),RenderJs.checkAndTriggerReady(),RenderJs.updateGadgetData(a)}})):(j=RenderJs.updateGadgetData(a),j||i.setReady(),RenderJs.checkAndTriggerReady())},isReady:function(){return is_ready},setReady:function(a){is_ready=a},bindReady:function(a){$("body").one("ready",a)},checkAndTriggerReady:function(){var a;return a=RenderJs.GadgetIndex.isGadgetListLoaded(),a&&(RenderJs.isReady()||(RenderJs.GadgetIndex.getRootGadget().getDom().trigger("ready"),$("body").trigger("ready"),RenderJs.setReady(!0))),a},updateGadgetData:function(gadget){var data_source,data_handler;return data_source=gadget.attr("data-gadget-source"),data_handler=gadget.attr("data-gadget-handler"),data_source!==undefined&&data_source!==""?($.ajax({url:data_source,dataType:"json",yourCustomData:{data_handler:data_handler,gadget_id:gadget.attr("id")},success:function(result){var data_handler,gadget_id;data_handler=this.yourCustomData.data_handler,gadget_id=this.yourCustomData.gadget_id,data_handler!==undefined&&(eval(data_handler+"(result)"),gadget=RenderJs.GadgetIndex.getGadgetById(gadget_id),gadget.setReady(),RenderJs.checkAndTriggerReady())}}),!0):!1},addGadget:function(a,b,c,d,e){var f,g,h;return g=$("#"+a),g.empty(),f=[\'<div id="\'+b+\'"\',\'data-gadget="\'+c+\'"\',\'data-gadget-handler="\'+d+\'" \',\'data-gadget-source="\'+e+\'"></div>\'].join("\\n"),g.append(f),h=g.find(".gadget"),RenderJs.bootstrap(g),h},Cache:function(){return{ROOT_CACHE_ID:"APP_CACHE",getCacheId:function(a){return this.ROOT_CACHE_ID+a},hasLocalStorage:function(){var a;a="localstorage_test_12345678";try{return localStorage.setItem(a,a),localStorage.removeItem(a),!0}catch(b){return!1}},get:function(a,b){return a=this.getCacheId(a),this.hasLocalStorage()?this.LocalStorageCachePlugin.get(a,b):this.NameSpaceStorageCachePlugin.get(a,b)},set:function(a,b){a=this.getCacheId(a),this.hasLocalStorage()?this.LocalStorageCachePlugin.set(a,b):this.NameSpaceStorageCachePlugin.set(a,b)},LocalStorageCachePlugin:function(){return{get:function(a,b){return a in localStorage?JSON.parse(localStorage.getItem(a)):b},set:function(a,b){localStorage.setItem(a,JSON.stringify(b))}}}(),NameSpaceStorageCachePlugin:function(){var a={};return{get:function(b,c){return a[b]},set:function(b,c){a[b]=c}}}()}}(),Gadget:function(a,b){this.id=a,this.dom=b,this.is_ready=!1,this.getId=function(){return this.id},this.getDom=function(){return this.dom},this.isReady=function(){return this.is_ready},this.setReady=function(){this.is_ready=!0},this.remove=function(){RenderJs.GadgetIndex.unregisterGadget(this),$(this.getDom()).remove()}},TabbularGadget:function(){return{toggleVisibility:function(a){$(".selected").addClass("not_selected"),$(".selected").removeClass("selected"),a.addClass("selected"),a.removeClass("not_selected")},addNewTabGadget:function(a,b,c,d,e){var f;f=RenderJs.addGadget(a,b,c,d,e)}}}(),GadgetIndex:function(){var a=[];return{getGadgetIdListFromDom:function(a){var b=[];return $.each(a.find("[data-gadget]"),function(a,c){b.push($(c).attr("id"))}),b},setGadgetList:function(b){a=b},getGadgetList:function(){return a},registerGadget:function(b){a.push(b)},unregisterGadget:function(b){var c=$.inArray(b,a);c!==-1&&a.splice(c,1)},getGadgetById:function(a){var b;return b=undefined,$(RenderJs.GadgetIndex.getGadgetList()).each(function(c,d){d.getId()===a&&(b=d)}),b},getRootGadget:function(){return this.getGadgetList()[0]},isGadgetListLoaded:function(){var a;return a=!0,$(this.getGadgetList()).each(function(b,c){c.isReady()===!1&&(a=!1)}),a}}}(),InteractionGadget:function(){return{bind:function(a){var b,c,d=function(a,b,c,d,e){var f=function(){RenderJs.GadgetIndex.getGadgetById(b)[a].apply(null,arguments),RenderJs.GadgetIndex.getGadgetById(d).dom.trigger(c)};return f},e=function(a,b){var c=function(){RenderJs.GadgetIndex.getGadgetById(a)[b].apply(null,arguments)};return c};b=a.attr("id"),c=a.attr("data-gadget-connection"),c=$.parseJSON(c),$.each(c,function(a,b){var c,f,g,h,i,j,k,l,m;c=b.source.split("."),f=c[0],g=c[1],h=RenderJs.GadgetIndex.getGadgetById(f),i=b.destination.split("."),j=i[0],k=i[1],l=RenderJs.GadgetIndex.getGadgetById(j),h.hasOwnProperty(g)?(m="original_"+g,h[m]=h[g],h[g]=d(m,f,g,j,k),l.dom.bind(g,e(j,k))):h.dom.bind(g,e(j,k))})}}}()}}();
]]></string> </value>
</item>
<item>
<key> <string>precondition</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>size</string> </key>
<value> <int>6425</int> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>renderjs.min.js</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
2012 (c) Nexedi SA
\ No newline at end of file
2012-2013 © Nexedi SA
\ No newline at end of file
erp5_jquery
erp5_jquery_plugin_jstorage
\ No newline at end of file
erp5_jquery_plugin_json
\ No newline at end of file
This Business Template contains only static files of RenderJS library.
\ No newline at end of file
This Business Template contains only static files of RenderJS library.
* http://www.renderjs.org/
\ No newline at end of file
21
\ No newline at end of file
22
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment