var $=require("jquery"),Base=require("basePC"),Dialog=require("./../lib/js/dialogPC.js"),UIkit=require("./../uikit/uikit.js"),Util=require("./../lib/js/util.js"),LinkSelectDialog=require("./../lib/js/linkSelectDialog.js"),CommonSelectDialog=require("./../lib/js/commonSelectDialog.js"),Convenient=require("./../lib/js/convenient.js"),JqueryTimeago=require("./../lib/js/jqueryTimeago.js"),Share=require("./../share.js/share.js"),Lazyload=require("./../lib/js/jqueryLazyload.js"),RadioWidget=require("./../lib/js/radioWidget.js"),TabWidget=require("./../lib/js/tabWidget.js"),ImageWidget=require("./../lib/js/imageWidget.js"),ImageTemplateWidget=require("./../lib/js/imageTemplateWidget.js"),Qrcode=require("./../lib/js/qrcode.js"),Clipboard=require("./../clipboard/clipboard.js"),Editor=require("./../lib/js/editor.js"),ColorPicker=require("./../color-picker/color-picker.js"),ColorPickerCSS=require("./../color-picker/color-picker.css"),EXField=require("./../ex-field/ex-field.js"),EXFieldCSS=require("./../ex-field/ex-field.less");$.timeago.settings.allowFuture=!0,$(function(){$("[datetime]").timeago(),$("[data-src]").lazyload({data_attribute:"src"}),$("[data-colorpicker]").colpick({submit:0,onChange:function(e,i,a,r,o){$(r).css("border-color","#"+i),$(r).val("#"+i)}}),Share.init(),RadioWidget.init(),TabWidget.init(),ImageWidget.init(),ImageTemplateWidget.init(),Qrcode.init(Dialog),new Clipboard("[data-clipboard-text]").on("success",function(e){Dialog.tipSuccess("复制成功")})});var commonInit=function(){$(document).on("click","[data-user-info]",function(){var e=$(this).attr("data-user-info");Dialog.dialog("/module/manage/user_info/"+e)}),$(document).on("click","[data-link-selector]",function(){var e=$('[data-link-selector-value="'+$(this).attr("data-link-selector")+'"]');new LinkSelectDialog({limitMin:1,limitMax:1,server:"/module/link_dialog",callback:function(i){var a=i[0];e.val(a)}},Dialog).show()}),$(document).on("click","[data-audio-selector]",function(){var e=$('[data-audio-selector-value="'+$(this).attr("data-audio-selector")+'"]');new window.api.commonSelectDialog($.extend({server:__env.adminPath+"system/data/select_dialog/audio"},{callback:function(i){var a=i[0];e.val(a),e.trigger("audio-selector-value.change",[a])}})).show()})};module.exports={init:function(){commonInit()},Base:Base,Dialog:Dialog,Util:Util};