1 line
10 KiB
JavaScript
Vendored
1 line
10 KiB
JavaScript
Vendored
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1873],{63606:function(e,t,r){"use strict";r.d(t,{Z:function(){return s}});var n=r(1413),o=r(67294),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"}}]},name:"check",theme:"outlined"},c=r(42135),l=function(e,t){return o.createElement(c.Z,(0,n.Z)((0,n.Z)({},e),{},{ref:t,icon:a}))};l.displayName="CheckOutlined";var s=o.forwardRef(l)},80882:function(e,t,r){"use strict";r.d(t,{Z:function(){return s}});var n=r(1413),o=r(67294),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}}]},name:"down",theme:"outlined"},c=r(42135),l=function(e,t){return o.createElement(c.Z,(0,n.Z)((0,n.Z)({},e),{},{ref:t,icon:a}))};l.displayName="DownOutlined";var s=o.forwardRef(l)},68795:function(e,t,r){"use strict";r.d(t,{Z:function(){return s}});var n=r(1413),o=r(67294),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z"}}]},name:"search",theme:"outlined"},c=r(42135),l=function(e,t){return o.createElement(c.Z,(0,n.Z)((0,n.Z)({},e),{},{ref:t,icon:a}))};l.displayName="SearchOutlined";var s=o.forwardRef(l)},9708:function(e,t,r){"use strict";r.d(t,{F:function(){return l},Z:function(){return c}});var n=r(4942),o=r(94184),a=r.n(o);function c(e,t,r){var o;return a()((o={},(0,n.Z)(o,"".concat(e,"-status-success"),"success"===t),(0,n.Z)(o,"".concat(e,"-status-warning"),"warning"===t),(0,n.Z)(o,"".concat(e,"-status-error"),"error"===t),(0,n.Z)(o,"".concat(e,"-status-validating"),"validating"===t),(0,n.Z)(o,"".concat(e,"-has-feedback"),r),o))}(0,r(93355).b)("warning","error","");var l=function(e,t){return t||e}},15746:function(e,t,r){"use strict";var n=r(21584);t.Z=n.Z},99134:function(e,t,r){"use strict";var n=(0,r(67294).createContext)({});t.Z=n},21584:function(e,t,r){"use strict";var n=r(4942),o=r(87462),a=r(71002),c=r(94184),l=r.n(c),s=r(67294),i=r(53124),u=r(99134),f=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&0>t.indexOf(n)&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)0>t.indexOf(n[o])&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r},d=["xs","sm","md","lg","xl","xxl"],p=s.forwardRef(function(e,t){var r,c=s.useContext(i.E_),p=c.getPrefixCls,h=c.direction,v=s.useContext(u.Z),m=v.gutter,w=v.wrap,Z=v.supportFlexGap,g=e.prefixCls,x=e.span,y=e.order,b=e.offset,j=e.push,_=e.pull,C=e.className,O=e.children,S=e.flex,N=e.style,F=f(e,["prefixCls","span","order","offset","push","pull","className","children","flex","style"]),E=p("col",g),k={};d.forEach(function(t){var r,c={},l=e[t];"number"==typeof l?c.span=l:"object"===(0,a.Z)(l)&&(c=l||{}),delete F[t],k=(0,o.Z)((0,o.Z)({},k),(r={},(0,n.Z)(r,"".concat(E,"-").concat(t,"-").concat(c.span),void 0!==c.span),(0,n.Z)(r,"".concat(E,"-").concat(t,"-order-").concat(c.order),c.order||0===c.order),(0,n.Z)(r,"".concat(E,"-").concat(t,"-offset-").concat(c.offset),c.offset||0===c.offset),(0,n.Z)(r,"".concat(E,"-").concat(t,"-push-").concat(c.push),c.push||0===c.push),(0,n.Z)(r,"".concat(E,"-").concat(t,"-pull-").concat(c.pull),c.pull||0===c.pull),(0,n.Z)(r,"".concat(E,"-rtl"),"rtl"===h),r))});var R=l()(E,(r={},(0,n.Z)(r,"".concat(E,"-").concat(x),void 0!==x),(0,n.Z)(r,"".concat(E,"-order-").concat(y),y),(0,n.Z)(r,"".concat(E,"-offset-").concat(b),b),(0,n.Z)(r,"".concat(E,"-push-").concat(j),j),(0,n.Z)(r,"".concat(E,"-pull-").concat(_),_),r),C,k),P={};if(m&&m[0]>0){var z=m[0]/2;P.paddingLeft=z,P.paddingRight=z}if(m&&m[1]>0&&!Z){var A=m[1]/2;P.paddingTop=A,P.paddingBottom=A}return S&&(P.flex="number"==typeof S?"".concat(S," ").concat(S," auto"):/^\d+(\.\d+)?(px|em|rem|%)$/.test(S)?"0 0 ".concat(S):S,!1!==w||P.minWidth||(P.minWidth=0)),s.createElement("div",(0,o.Z)({},F,{style:(0,o.Z)((0,o.Z)({},P),N),className:R,ref:t}),O)});t.Z=p},92820:function(e,t,r){"use strict";var n=r(87462),o=r(4942),a=r(71002),c=r(97685),l=r(94184),s=r.n(l),i=r(67294),u=r(53124),f=r(98082),d=r(24308),p=r(93355),h=r(99134),v=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&0>t.indexOf(n)&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,n=Object.getOwnPropertySymbols(e);o<n.length;o++)0>t.indexOf(n[o])&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]]);return r};function m(e,t){var r=i.useState("string"==typeof e?e:""),n=(0,c.Z)(r,2),o=n[0],l=n[1],s=function(){if("string"==typeof e&&l(e),"object"===(0,a.Z)(e))for(var r=0;r<d.c4.length;r++){var n=d.c4[r];if(t[n]){var o=e[n];if(void 0!==o){l(o);return}}}};return i.useEffect(function(){s()},[JSON.stringify(e),t]),o}(0,p.b)("top","middle","bottom","stretch"),(0,p.b)("start","end","center","space-around","space-between","space-evenly");var w=i.forwardRef(function(e,t){var r,l,p=e.prefixCls,w=e.justify,Z=e.align,g=e.className,x=e.style,y=e.children,b=e.gutter,j=void 0===b?0:b,_=e.wrap,C=v(e,["prefixCls","justify","align","className","style","children","gutter","wrap"]),O=i.useContext(u.E_),S=O.getPrefixCls,N=O.direction,F=i.useState({xs:!0,sm:!0,md:!0,lg:!0,xl:!0,xxl:!0}),E=(0,c.Z)(F,2),k=E[0],R=E[1],P=i.useState({xs:!1,sm:!1,md:!1,lg:!1,xl:!1,xxl:!1}),z=(0,c.Z)(P,2),A=z[0],B=z[1],L=m(Z,A),G=m(w,A),M=(0,f.Z)(),U=i.useRef(j);i.useEffect(function(){var e=d.ZP.subscribe(function(e){B(e);var t=U.current||0;(!Array.isArray(t)&&"object"===(0,a.Z)(t)||Array.isArray(t)&&("object"===(0,a.Z)(t[0])||"object"===(0,a.Z)(t[1])))&&R(e)});return function(){return d.ZP.unsubscribe(e)}},[]);var T=S("row",p),I=(r=[void 0,void 0],(Array.isArray(j)?j:[j,void 0]).forEach(function(e,t){if("object"===(0,a.Z)(e))for(var n=0;n<d.c4.length;n++){var o=d.c4[n];if(k[o]&&void 0!==e[o]){r[t]=e[o];break}}else r[t]=e}),r),V=s()(T,(l={},(0,o.Z)(l,"".concat(T,"-no-wrap"),!1===_),(0,o.Z)(l,"".concat(T,"-").concat(G),G),(0,o.Z)(l,"".concat(T,"-").concat(L),L),(0,o.Z)(l,"".concat(T,"-rtl"),"rtl"===N),l),g),W={},D=null!=I[0]&&I[0]>0?-(I[0]/2):void 0,H=null!=I[1]&&I[1]>0?-(I[1]/2):void 0;if(D&&(W.marginLeft=D,W.marginRight=D),M){var J=(0,c.Z)(I,2);W.rowGap=J[1]}else H&&(W.marginTop=H,W.marginBottom=H);var $=(0,c.Z)(I,2),q=$[0],K=$[1],Q=i.useMemo(function(){return{gutter:[q,K],wrap:_,supportFlexGap:M}},[q,K,_,M]);return i.createElement(h.Z.Provider,{value:Q},i.createElement("div",(0,n.Z)({},C,{className:V,style:(0,n.Z)((0,n.Z)({},W),x),ref:t}),y))});t.Z=w},71230:function(e,t,r){"use strict";var n=r(92820);t.Z=n.Z},77558:function(e,t,r){"use strict";r.r(t),r.d(t,{FollowerCollection:function(){return x}});var n=r(85893),o=r(67294),a=r(11382),c=r(3698),l=r(37068),s=r(71230),i=r(15746),u=r(24093),f=r(94184),d=r.n(f),p=r(37104),h=r.n(p);let v=e=>{let{follower:t}=e;return(0,n.jsx)("div",{children:(0,n.jsx)("a",{href:t.link,target:"_blank",rel:"noreferrer",children:(0,n.jsxs)(s.Z,{wrap:!1,className:d()([h().follower,"followers-follower"]),children:[(0,n.jsx)(i.Z,{span:6,className:h().avatarColumn,children:(0,n.jsx)(u.C,{src:t.image,alt:(t.name||t.username).charAt(0).toUpperCase(),className:h().avatar,size:"large",children:(t.name||t.username).charAt(0).toUpperCase()})}),(0,n.jsxs)(i.Z,{children:[(0,n.jsx)(s.Z,{className:h().username,children:t.name||t.username.split("@",2)[0]}),(0,n.jsx)(s.Z,{className:h().account,children:t.username})]})]})})})};var m=r(38149),w=r.n(m),Z=r(42093),g=r(69183);let x=e=>{let{name:t,onFollowButtonClick:r}=e,[s,i]=(0,o.useState)([]),[u,f]=(0,o.useState)(0),[d,p]=(0,o.useState)(1),[h,m]=(0,o.useState)(!0),x=async()=>{try{m(!0);let e=await fetch("".concat("/api/followers","?offset=").concat((d-1)*24,"&limit=").concat(24)),t=await e.json(),{results:r,total:n}=t;i(r),f(n),m(!1)}catch(e){console.error(e)}};(0,o.useEffect)(()=>{x()},[d]);let y=(0,n.jsxs)("div",{className:w().noFollowers,id:"followers-collection",children:[(0,n.jsx)("h2",{children:"Be the first follower!"}),(0,n.jsxs)("p",{children:["Owncast"!==t?t:"This server"," is a part of the"," ",(0,n.jsx)("a",{href:"https://owncast.online/join-fediverse",children:"Fediverse"}),", an interconnected network of independent users and servers."]}),(0,n.jsxs)("p",{children:["By following ","Owncast"!==t?t:"this server"," you'll be able to get updates from the stream, share it with others, and show your appreciation when it goes live, all from your own Fediverse account."]}),(0,n.jsx)(Z.e,{onClick:r})]});return(null==s?void 0:s.length)||h?(0,n.jsx)(l.SV,{fallbackRender:e=>{let{error:t,resetErrorBoundary:r}=e;return(0,n.jsx)(g.A,{componentName:"FollowerCollection",message:t.message,retryFunction:r})},children:(0,n.jsx)(a.Z,{spinning:h,size:"large",children:(0,n.jsxs)("div",{className:w().followers,id:"followers-collection",children:[(0,n.jsx)("div",{className:w().followerRow,children:s.map(e=>(0,n.jsx)(v,{follower:e},e.link))}),(0,n.jsx)(c.Z,{className:w().pagination,current:d,pageSize:24,defaultPageSize:24,total:u,showSizeChanger:!1,onChange:e=>{p(e)},hideOnSinglePage:!0})]})})}):y}},38149:function(e){e.exports={followers:"FollowerCollection_followers__e_EUS",followerRow:"FollowerCollection_followerRow__T1mFd",noFollowers:"FollowerCollection_noFollowers__UaCVW",pagination:"FollowerCollection_pagination___wGRd"}},37104:function(e){e.exports={follower:"SingleFollower_follower__EyBDI",avatar:"SingleFollower_avatar__V9jHG",avatarColumn:"SingleFollower_avatarColumn__teRL9",account:"SingleFollower_account__Z66vo",username:"SingleFollower_username__ENweU"}}}]); |