{I" class:ETI"BundledAsset; FI"logical_path; TI"rails_admin/ra.widgets.js; FI" pathname; TI"x/Users/jirikolarik/.rvm/gems/ruby-2.1.1/gems/rails_admin-0.6.1/app/assets/javascripts/rails_admin/ra.widgets.coffee; FI"content_type; TI"application/javascript; TI" mtime; Tl+–SI"length; TiP)I"digest; TI"%1ae8351dc24c4902580e81c39e6bfcfd; FI"source; TI"P)(function() { $(document).on('rails_admin.dom_ready', function(e, content) { var $editors, array, config_options, goBootstrapWysihtml5s, goCkeditors, goCodeMirrors, options; content = content ? content : $('form'); if (content.length) { content.find('[data-color]').each(function() { var that; that = this; return $(this).ColorPicker({ color: $(that).val(), onShow: function(el) { $(el).fadeIn(500); return false; }, onHide: function(el) { $(el).fadeOut(500); return false; }, onChange: function(hsb, hex, rgb) { $(that).val(hex); return $(that).css('backgroundColor', '#' + hex); } }); }); content.find('[data-datetimepicker]').each(function() { return $(this).datetimepicker($(this).data('options')); }); content.find('[data-enumeration]').each(function() { if ($(this).is('[multiple]')) { return $(this).filteringMultiselect($(this).data('options')); } else { return $(this).filteringSelect($(this).data('options')); } }); content.find('[data-fileupload]').each(function() { var input; input = this; return $(this).on('click', ".delete input[type='checkbox']", function() { return $(input).children('.toggle').toggle('slow'); }); }); content.find('[data-fileupload]').change(function() { var ext, image_container, input, reader; input = this; image_container = $("#" + input.id).parent().children(".preview"); if (!image_container.length) { image_container = $("#" + input.id).parent().prepend($('').addClass('preview')).find('img.preview'); image_container.parent().find('img:not(.preview)').hide(); } ext = $("#" + input.id).val().split('.').pop().toLowerCase(); if (input.files && input.files[0] && $.inArray(ext, ['gif', 'png', 'jpg', 'jpeg', 'bmp']) !== -1) { reader = new FileReader(); reader.onload = function(e) { return image_container.attr("src", e.target.result); }; reader.readAsDataURL(input.files[0]); return image_container.show(); } else { return image_container.hide(); } }); content.find('[data-filteringmultiselect]').each(function() { $(this).filteringMultiselect($(this).data('options')); if ($(this).parents("#modal").length) { return $(this).parents('.control-group').find('.btn').remove(); } else { return $(this).parents('.control-group').first().remoteForm(); } }); content.find('[data-filteringselect]').each(function() { $(this).filteringSelect($(this).data('options')); if ($(this).parents("#modal").length) { return $(this).parents('.control-group').find('.btn').remove(); } else { return $(this).parents('.control-group').first().remoteForm(); } }); content.find('[data-nestedmany]').each(function() { var field, nav, tab_content, toggler; field = $(this).parents('.control-group').first(); nav = field.find('> .controls > .nav'); tab_content = field.find('> .tab-content'); toggler = field.find('> .controls > .btn-group > .toggler'); tab_content.children('.fields:not(.tab-pane)').addClass('tab-pane').each(function() { $(this).attr('id', 'unique-id-' + (new Date().getTime()) + Math.floor(Math.random() * 100000)); return nav.append('