UNPKG

@mornya/react-social-libs

Version:

The project of React.js Social Share and Widget modules.

1 lines 1.29 kB
var o,t,e=this&&this.__extends||(o=function(t,e){return(o=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){t.__proto__=e}:function(t,e){for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o])}))(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function __(){this.constructor=t}o(t,e),t.prototype=null===e?Object.create(e):(__.prototype=e.prototype,new __)}),n=(Object.defineProperty(exports,"__esModule",{value:!0}),require("../utils/BaseShareComponent")),r=require("../utils/UI"),n=(t=n.BaseShareComponent,e(NaverBlog,t),NaverBlog.prototype.onInit=function(){this.initialize("NaverBlog",{title:function(t){return null!=(t=t.title)?t:""}})},NaverBlog.prototype.onMount=function(t){this.setApiStep()},NaverBlog.prototype.onShare=function(t,e){var o,n=this;(0,r.openShareWindow)(this.mapToParam(NaverBlog.LINK_URL,{url:e.url,title:null==(o=t.title)?void 0:o.call(t,e)}),"naverblog",this.deviceInfo.isMobile?[]:[573,640]).then(function(){return n.onComplete(!0,null)}).catch(function(t){return console.error(t)})},NaverBlog.LINK_URL="https://blog.naver.com/openapi/share",NaverBlog);function NaverBlog(){return null!==t&&t.apply(this,arguments)||this}exports.default=n;