"use strict";(self.webpackChunkcnblogs_theme_simplememory_2_2_12=self.webpackChunkcnblogs_theme_simplememory_2_2_12||[]).push([[191],{5289:function(o,e,i){i.a(o,(async function(o,n){try{i.r(e),i.d(e,{default:function(){return d}});var c=i(9343),t=i(6545);function d(){let o=$("#main pre");function e(){if(!$.__config.code.options.line)return!0;let o=$("code-box pre code");$.each(o,(function(e){let i=$(o[e]),n=i.html().replace(/\<br\>/g,"\n").split("\n"),c=[];$.each(n,(o=>{(n[o].trim()||o<n.length-1)&&"</code>"!==n[o]&&c.push('<code-line class="line-numbers-rows"></code-line>'+n[o])})),i.html(c.join("\n")),i.addClass("code-pre-line")}))}(0,c.Z)(),$.each(o,(function(e){let i=$(o[e]),n="code-"+$.__tools.randomString(6);i.wrap('<code-box id="'+n+'"></code-box>'),i.attr("boxid",n)})),(()=>{if($.__config.code.options.macStyle){let o=$("code-box");$.each(o,(function(e){$(o[e]).prepend('<div class="code-tools"></div>')}))}else o.css("border-radius","4px")})(),(()=>{let o=$("code-box");$.each(o,(function(e){let i=$(o[e]),n=i.attr("id"),c='<button boxid="'+n+'" type="button" class="clipboard code-copay-btn" data-clipboard-action="copy" data-clipboard-target="#'+n+' pre" aria-label="复制代码" ><i class="iconfont icon-fuzhi"></i></button>';i.prepend(c)})),$("code-box .code-copay-btn").click((function(){$(this).find("i").removeClass("icon-fuzhi").addClass("icon-right"),setTimeout("$('code-box button[boxid='"+$(this).attr("boxid")+"'] i').removeClass('icon-right').addClass('icon-fuzhi')",1500)})),o.on({mouseover:function(){$(this).find(".code-copay-btn").css({opacity:1,visibility:"visible"})},mouseout:function(){$(this).find(".code-copay-btn").css({opacity:0,visibility:"hidden"})}}),new ClipboardJS(".clipboard")})(),$.__config.code.options.maxHeight&&$("code-box pre").css("max-height",$.__config.code.options.maxHeight),"hljs"===$.__config.code.type.toLowerCase()?i.e(586).then(i.bind(i,2209)).then((o=>{(0,o.default)(e)})):(o.css("background","#f5f5fa"),$("code-box .code-tools").css("background","#f5f5fa"),$("pre .hljs").css({background:"none",border:"0","border-radius":"0",padding:"0"}),e()),(0,t.Z)()}await $.__tools.dynamicLoadingJs($.__config.default.clipboard).catch((o=>console.error("clipboard.js",o))),n()}catch(s){n(s)}}),1)},6545:function(o,e,i){function n(){"function"==typeof $.__config.hooks.afterCode&&$.__config.hooks.afterCode()}i.d(e,{Z:function(){return n}})},9343:function(o,e,i){function n(){"function"==typeof $.__config.hooks.beforeCode&&$.__config.hooks.beforeCode()}i.d(e,{Z:function(){return n}})}}]);