Sha256: 2967b18fd34f7642ceeef4fafa7816f6f413e8a8c7d28f3aff3b8200b195923a
Contents?: true
Size: 1.21 KB
Versions: 2
Compression:
Stored size: 1.21 KB
Contents
/******************************************************************************* * KindEditor - WYSIWYG HTML Editor for Internet * Copyright (C) 2006-2011 kindsoft.net * * @author javy <javyquan@gmail.com> * @site http://www.kindsoft.net/ * @licence http://www.kindsoft.net/license.php *******************************************************************************/ KindEditor.plugin('modal', function(K) { var self = this, name = 'modal', lang = self.lang(name + '.'); self.plugin.modalDialog = function(options) { var clickFn = options.clickFn; var html = '<div style="padding:10px 20px;" id="modal_content"></div>' var dialogWidth = options.width || 400, dialogHeight = options.height || 250, title = options.title || "modal"; var dialog = self.createDialog({ name : name, width : dialogWidth, height : dialogHeight, title : title, body : html, yesBtn : { name : self.lang('yes'), click : function(e) { if (dialog.isLoading) { return; } clickFn.call(self, remote_content); } } }), div = dialog.div; var remote_content = K('#modal_content', div); return dialog; }; });
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
rails_editor_liu-0.5.1 | vendor/assets/javascripts/kindeditor/plugins/modal/modal.js |
rails_editor_liu-0.5.0 | vendor/assets/javascripts/kindeditor/plugins/modal/modal.js |