Add Mastodon frontend.
This commit is contained in:
parent
414c52509b
commit
d293ceb1b5
170 changed files with 206601 additions and 5 deletions
|
|
@ -0,0 +1,2 @@
|
|||
webpackJsonp([25],{774:function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),a.d(t,"default",function(){return N});var i,n,o,r=a(2),s=a.n(r),d=a(1),l=a.n(d),m=a(3),c=a.n(m),u=a(4),f=a.n(u),b=a(0),h=a.n(b),p=a(5),v=a.n(p),y=a(11),g=a.n(y),w=a(6),_=a(72),k=a.n(_),N=Object(w.g)((o=n=function(e){function t(){var a,i,n;l()(this,t);for(var o=arguments.length,r=Array(o),s=0;s<o;s++)r[s]=arguments[s];return a=i=c()(this,e.call.apply(e,[this].concat(r))),i.state={loading:!1,oembed:null},i.setIframeRef=function(e){i.iframe=e},i.handleTextareaClick=function(e){e.target.select()},n=a,c()(i,n)}return f()(t,e),t.prototype.componentDidMount=function(){var e=this,t=this.props.url;this.setState({loading:!0}),k.a.post("/api/web/embed",{url:t}).then(function(t){e.setState({loading:!1,oembed:t.data});var a=e.iframe.contentWindow.document;a.open(),a.write(t.data.html),a.close(),a.body.style.margin=0,e.iframe.width=a.body.scrollWidth,e.iframe.height=a.body.scrollHeight})},t.prototype.render=function(){var e=this.state.oembed;return s()("div",{className:"modal-root__modal embed-modal"},void 0,s()("h4",{},void 0,s()(w.b,{id:"status.embed",defaultMessage:"Embed"})),s()("div",{className:"embed-modal__container"},void 0,s()("p",{className:"hint"},void 0,s()(w.b,{id:"embed.instructions",defaultMessage:"Embed this status on your website by copying the code below."})),s()("input",{type:"text",className:"embed-modal__html",readOnly:!0,value:e&&e.html||"",onClick:this.handleTextareaClick}),s()("p",{className:"hint"},void 0,s()(w.b,{id:"embed.preview",defaultMessage:"Here is what it will look like:"})),h.a.createElement("iframe",{className:"embed-modal__iframe",frameBorder:"0",ref:this.setIframeRef,title:"preview"})))},t}(g.a),n.propTypes={url:v.a.string.isRequired,onClose:v.a.func.isRequired,intl:v.a.object.isRequired},i=o))||i}});
|
||||
//# sourceMappingURL=embed_modal-c776fd6a0ea581675783.js.map
|
||||
BIN
priv/static/packs/modals/embed_modal-c776fd6a0ea581675783.js.gz
Normal file
BIN
priv/static/packs/modals/embed_modal-c776fd6a0ea581675783.js.gz
Normal file
Binary file not shown.
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Binary file not shown.
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
BIN
priv/static/packs/modals/report_modal-7a2950f40d4867b9cbb0.js.gz
Normal file
BIN
priv/static/packs/modals/report_modal-7a2950f40d4867b9cbb0.js.gz
Normal file
Binary file not shown.
File diff suppressed because one or more lines are too long
Loading…
Add table
Add a link
Reference in a new issue