1"use strict";(self.webpackChunkmangane_fe=self.webpackChunkmangane_fe||[]).push([[66],{1191:function(e,s,a){a.r(s),a.d(s,{default:function(){return L}});var t=a(1855),n=a(1841),r=a(1842),o=a(2),u=a(595),c=a(5),i=a.n(c),d=a(0),l=a(1871),m=a(191),h=a(576),f=a(598),v=a(55),g=a(20),Z=a(23),p=a(158),_=a(210),M=a(1882),y=function(){return(0,t.Z)("div",{className:"account"},void 0,(0,t.Z)("div",{className:"account__wrapper"},void 0,(0,t.Z)("span",{className:"account__display-name"},void 0,(0,t.Z)("div",{className:"account__avatar-wrapper"},void 0,(0,t.Z)(_.Z,{size:36})),(0,t.Z)(M.Z,{minLength:3,maxLength:25}))))},b=a(1880),C=function(){var e=(0,b.lv)(15,30);return(0,t.Z)("div",{className:"placeholder-hashtag"},void 0,(0,t.Z)("div",{className:"trends__item"},void 0,(0,t.Z)("div",{className:"trends__item__name"},void 0,(0,b._4)(e))))},N=a(284),w=a(3),k=(0,n.vU)({accounts:{id:"search_results.accounts",defaultMessage:"People"},statuses:{id:"search_results.statuses",defaultMessage:"Posts"},hashtags:{id:"search_results.hashtags",defaultMessage:"Hashtags"}}),x=function(){var e,s,n=(0,d.useRef)(null),u=(0,r.Z)(),c=(0,w.TL)(),_=(0,w.CG)((function(e){return e.search.submittedValue})),M=(0,w.CG)((function(e){return e.search.results})),b=(0,w.CG)((function(e){return e.suggestions.items})),x=(0,w.CG)((function(e){return e.trending_statuses.items})),G=(0,w.CG)((function(e){return e.trends.items})),L=(0,w.CG)((function(e){return e.search.submitted})),E=(0,w.CG)((function(e){return e.search.filter})),H=(0,w.CG)((function(e){return e.search.accountId})),T=(0,w.CG)((function(e){var s;return null===(s=e.accounts.get(H))||void 0===s?void 0:s.acct})),U=function(e){return c((0,m.Tv)(e))},z=function(e){var s;return null===(s=F)||void 0===s?void 0:s.keySeq().findIndex((function(s){return s===e}))},I=function(e){if(F){var s=z(e)-1;q(s)}},S=function(e){if(F){var s=z(e)+1;q(s)}},q=function(e){var s;null===(s=n.current)||void 0===s||s.scrollIntoView({index:e,behavior:"smooth",done:function(){var s=document.querySelector('#search-results [data-index="'.concat(e,'"] .focusable'));null==s||s.focus()}})};(0,d.useEffect)((function(){c((0,h.AJ)())}),[]);var A,D,F,P,Q=!1,V=N.Z;return"accounts"===E&&(Q=M.accountsHasMore,A=M.accountsLoaded,V=y,M.accounts&&M.accounts.size>0?s=M.accounts.map((function(e){return(0,t.Z)(Z.Z,{id:e},e)})):L||!b||b.isEmpty()?A&&(D=(0,t.Z)("div",{className:"empty-column-indicator"},void 0,(0,t.Z)(l.Z,{id:"empty_column.search.accounts",defaultMessage:'There are no people results for "{term}"',values:{term:_}}))):s=b.map((function(e){return(0,t.Z)(Z.Z,{id:e.account},e.account)}))),"statuses"===E&&(Q=M.statusesHasMore,A=M.statusesLoaded,M.statuses&&M.statuses.size>0?(s=M.statuses.map((function(e){return(0,t.Z)(p.Z,{id:e,onMoveUp:I,onMoveDown:S},e)})),F=M.statuses):L||!x||x.isEmpty()?A&&(D=(0,t.Z)("div",{className:"empty-column-indicator"},void 0,(0,t.Z)(l.Z,{id:"empty_column.search.statuses",defaultMessage:'There are no posts results for "{term}"',values:{term:_}}))):(s=x.map((function(e){return(0,t.Z)(p.Z,{id:e,onMoveUp:I,onMoveDown:S},e)})),F=x)),"hashtags"===E&&(Q=M.hashtagsHasMore,A=M.hashtagsLoaded,V=C,M.hashtags&&M.hashtags.size>0?s=M.hashtags.map((function(e){return(0,t.Z)(f.Z,{hashtag:e},e.name)})):L||!b||b.isEmpty()?A&&(D=(0,t.Z)("div",{className:"empty-column-indicator"},void 0,(0,t.Z)(l.Z,{id:"empty_column.search.hashtags",defaultMessage:'There are no hashtags results for "{term}"',values:{term:_}}))):s=G.map((function(e){return(0,t.Z)(f.Z,{hashtag:e},e.name)}))),d.createElement(d.Fragment,null,H?(0,t.Z)(o.Ug,{className:"mb-4 pb-4 px-2 border-solid border-b border-gray-200 dark:border-gray-800",space:2},void 0,(0,t.Z)(v.Z,{iconClassName:"h-5 w-5",src:a(26),onClick:function(){return c((0,m.AQ)())}}),(0,t.Z)(o.xv,{},void 0,(0,t.Z)(l.Z,{id:"search_results.filter_message",defaultMessage:"You are searching for posts from @{acct}.",values:{acct:T}}))):(P=[{text:u.formatMessage(k.statuses),action:function(){return U("statuses")},name:"statuses"},{text:u.formatMessage(k.accounts),action:function(){return U("accounts")},name:"accounts"},{text:u.formatMessage(k.hashtags),action:function(){return U("hashtags")},name:"hashtags"}],(0,t.Z)(o.mQ,{items:P,activeItem:E})),D||d.createElement(g.Z,{id:"search-results",ref:n,key:E,scrollKey:"".concat(E,":").concat(_),isLoading:L&&!A,showLoading:L&&!A&&(null===(e=s)||void 0===e?void 0:e.isEmpty()),hasMore:Q,onLoadMore:function(){return c((0,m.i9)(E))},placeholderComponent:V,placeholderCount:20,className:i()({"divide-gray-200 dark:divide-slate-700 divide-solid divide-y":"statuses"===E}),itemClassName:i()({"pb-4":"accounts"===E,"pb-3":"hashtags"===E})},s||[]))},G=(0,n.vU)({heading:{id:"column.search",defaultMessage:"Search"}}),L=function(){var e=(0,r.Z)();return(0,t.Z)(o.sg,{withHeader:!1,label:e.formatMessage(G.heading)},void 0,(0,t.Z)("div",{className:"space-y-4"},void 0,(0,t.Z)(u.Z,{autoFocus:!0,autoSubmit:!0}),(0,t.Z)(x,{})))}}}]);
2//# sourceMappingURL=search-8a455bbfd9dc5276191c.chunk.js.map
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.