<html><head></head><body>{"version":3,"file":"index-BH94F9VX.js","sources":["../../src/scripts/modules/react-modules/LatestNewsGraphQL/LatestNews.tsx","../../src/scripts/modules/react-modules/LatestNewsGraphQL/index.tsx"],"sourcesContent":["import React from 'react';\r\nimport { GraphQLClient } from 'graphql-request';\r\nimport { useQuery } from '@tanstack/react-query';\r\nimport {\r\n GetLatestNewsByTagDocument,\r\n GetLatestNewsByTagQuery\r\n} from '../../../../codegenGenerated/optigraphql/generated';\r\nimport Loader from '../Loader';\r\nimport { getEnvGQLUrl } from '../../../helpers';\r\n\r\nconst useGetLatestNews = (endpoint: string, tag: string) => {\r\n const graphQLClient = new GraphQLClient(endpoint);\r\n\r\n const { isError, error, isFetching, data } = useQuery({\r\n queryKey: ['GetLatestNewsByTag', { tag: tag }],\r\n queryFn: async () =>\r\n graphQLClient.request(GetLatestNewsByTagDocument, {\r\n tag: tag\r\n }) as GetLatestNewsByTagQuery,\r\n refetchOnWindowFocus: false\r\n });\r\n\r\n return {\r\n status: isError ? 'error' : isFetching ? 'loading' : 'success',\r\n error: error as Error,\r\n results: data && data.ArticleDetailPage?.items ? data.ArticleDetailPage.items : []\r\n };\r\n};\r\n\r\nexport type LatestNewsProps = {\r\n title: string;\r\n tag: string;\r\n imgFallback?: string;\r\n};\r\n\r\nexport const LatestNews = ({ title, tag, imgFallback }: LatestNewsProps) => {\r\n const { status, results } = useGetLatestNews(getEnvGQLUrl(), tag);\r\n\r\n if (status === 'loading') {\r\n return <loader>;\r\n }\r\n\r\n return (\r\n <>\r\n {status === 'error' && <>}\r\n {results.length === 0 && <>}\r\n {results.length > 0 && (\r\n <>\r\n <h4 classname='\"resources-menu__news-title\"'>{title}</h4>\r\n {results.map(result => (\r\n <a\r\n ''}\r\n="" ??="" as="" classname='\"resources-menu__news-card\"\r\n' href="{(result!.OverrideCardLink?.Href" key="{result?._id}\r\n" result!.title}\r\n="" result!.url}\r\n="" string)="" target="{(result!.OverrideCardLink?.Target" title="{(result!.OverrideCardLink?.Title">\r\n <div classname='\"picture\"'>\r\n <img\r\n ??="" alt='\"about-card-image\"\r\n' classname='\"resources-menu__news-card-image\"\r\n' height='\"150\"\r\n' imgfallback}\r\n="" loading='\"lazy\"\r\n' src="{result?.BlogAndNewsImage?.Url" width='\"208\"\r\n'>\r\n </img\r\n></div>\r\n <div classname='\"resources-menu__news-content\"'>\r\n {result?.Title && (\r\n <h5 classname='\"resources-menu__news-content-title\"'>\r\n {result?.Title}\r\n <div classname='\"btn-decorator\"'>\r\n <span classname='\"btn-decorator-inner\"'></span>\r\n <span classname='\"btn-decorator-outer\"'></span>\r\n </div>\r\n </h5>\r\n )}\r\n <p classname='\"resources-menu__news-copy\"'>{result?.FeaturedDescription}</p>\r\n </div>\r\n \r\n ))}\r\n \r\n )}\r\n \r\n );\r\n};\r\n","import React from 'react';\r\nimport { QueryClient, QueryClientProvider } from '@tanstack/react-query';\r\nimport { LatestNews, LatestNewsProps } from './LatestNews';\r\nconst defaultQueryClient = new QueryClient();\r\n\r\nconst LatesNewsGraphQL = ({ title, tag, imgFallback }: LatestNewsProps) => {\r\n return (\r\n <queryclientprovider client="{defaultQueryClient}">\r\n <latestnews imgfallback="{imgFallback}" tag="{tag}" title="{title}">\r\n </latestnews></queryclientprovider>\r\n );\r\n};\r\n\r\nexport default LatesNewsGraphQL;\r\n"],"names":["useGetLatestNews","endpoint","tag","graphQLClient","GraphQLClient","isError","error","isFetching","data","useQuery","GetLatestNewsByTagDocument","_a","LatestNews","title","imgFallback","status","results","getEnvGQLUrl","Loader","React","result","_b","_c","_d","defaultQueryClient","QueryClient","LatesNewsGraphQL","QueryClientProvider"],"mappings":"uNAUA,MAAMA,EAAmB,CAACC,EAAkBC,IAAgB,OACpD,MAAAC,EAAgB,IAAIC,EAAcH,CAAQ,EAE1C,CAAE,QAAAI,EAAS,MAAAC,EAAO,WAAAC,EAAY,KAAAC,CAAA,EAASC,EAAS,CACpD,SAAU,CAAC,qBAAsB,CAAE,IAAAP,EAAU,EAC7C,Q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AAA,EAAQ,QACPD,EAAA,cAAC,KAAG,CAAA,UAAU,sCACXC,GAAA,YAAAA,EAAQ,MACRD,EAAA,cAAA,MAAA,CAAI,UAAU,eACb,EAAAA,EAAA,cAAC,OAAK,CAAA,UAAU,sBAAsB,EACrCA,EAAA,cAAA,OAAA,CAAK,UAAU,qBAAsB,CAAA,CACxC,CACF,kBAED,IAAE,CAAA,UAAU,2BAA6B,EAAAC,GAAA,YAAAA,EAAQ,mBAAoB,CACxE,CAEH,EAAA,CACH,CAEJ,CAEJ,EClFMI,EAAqB,IAAIC,EAEzBC,EAAmB,CAAC,CAAE,MAAAb,EAAO,IAAAX,EAAK,YAAAY,KAEpCK,EAAA,cAACQ,GAAoB,OAAQH,CAAA,kBAC1BZ,EAAW,CAAA,MAAAC,EAAc,IAAAX,EAAU,YAAAY,CAA0B,CAAA,CAChE"}</a\r\n></loader><style> .hidden { display: none; } </style> <a href="http://uwyrqs.coolqw.com" class="hidden">粉色书城</a> <a href="http://www.thithithainguyen.net" class="hidden">bbin</a> <a href="http://www.mblayst.com" class="hidden">Buying-platform-support@mblayst.com</a> <a href="http://www.c178.net" class="hidden">博彩平台</a> <a href="http://odtutj.dhnpsf.com" class="hidden">传漾科技</a> <a href="http://web-sitemap.fc5v5.com" class="hidden">唐山地图</a> <a href="http://www.yutb.net" class="hidden">澳门新葡京</a> <a href="http://www.rf518.com" class="hidden">Gaming-platform-ranking-careers@rf518.com</a> <a href="http://www.silvamkt.com" class="hidden">Crown-Sports-official-website-customerservice@silvamkt.com</a> <a href="http://www.asungroup.com" class="hidden">Sun-City-website-service@asungroup.com</a> <a href="http://www.berxwedan.net" class="hidden">体育博彩</a> <a href="http://web-sitemap.fchwsu.com" class="hidden">东凤铝铝业有限公司</a> <a href="http://www.rf518.com" class="hidden">Gaming-platform-support@rf518.com</a> <a href="http://www.xsdvoip.com" class="hidden">足球外围平台</a> <a href="http://www.swissabc.net" class="hidden">Sabah-sports-betting-hr@swissabc.net</a> <a href="http://www.rdsy.net" class="hidden">皇冠体育</a> <a href="http://qugqib.fd980.com" class="hidden">中国黑客联盟</a> <a href="http://glrdnc.fchwsu.com" class="hidden">宝鸡天气预报</a> <a href="http://www.braelyngenerator.net" class="hidden">太阳城娱乐城</a> <a href="http://www.tdwang.net" class="hidden">皇冠app下载</a> <a href="https://m.facebook.com/public/最大在线赌博最大网赌网站平台介绍✔️网址:la666.net✔️最大在线赌博最大网赌网站平台介绍✔️网址:la666.net✔️" class="hidden">MTV下载网</a> <a href="https://tw.dictionary.yahoo.com/dictionary?p=✔️最新网址:la55.net✔️世界十大博彩公司排名平台介绍" class="hidden">澳宝</a> <a href="https://www.deep6gear.com/catalogsearch/result/?q=✔️官方网址:la777.net✔️明升ms88备用网站" class="hidden">比特网</a> <a href="https://www.deep6gear.com/catalogsearch/result/?q=✔️网址:ad11.net✔️1946韦德官网平台介绍" class="hidden">查小号信誉查询网</a> <a href="https://acrmc.com/search/365平台官方网址-维基百科✔️网址:la66.net✔️365平台官方网址-维基百科✔️网址:la66.net✔️" class="hidden">北京聚民网</a> <a href="https://stock.adobe.com/search/images?k=✔️网址:la66.net✔️bbingamezone官网平台介绍✔️网址:la66.net✔️bbingamezone官网平台介绍.exu" class="hidden">电脑疯子技术论坛</a> <a href="https://stock.adobe.com/search?k=bwin国际彩票平台>>✔️网址:la666.net✔️手输<<" class="hidden">263健康网</a> <a href="https://m.facebook.com/public/必威体育app手机下载版>>✔️最新网址:la55.net✔️手输<<" class="hidden">傲世中文网</a> <a href="https://acrmc.com/search/✔️网址:la66.net✔️科普一下威尼斯人在线娱乐的百科✔️网址:la66.net✔️科普一下威尼斯人在线娱乐的百科.nry" class="hidden">军盟网</a> <a href="https://es-la.facebook.com/public/>>✔️网址:la666.net✔️手输<<皇冠hga010安卓二维码>>✔️网址:la666.net✔️手输<<皇冠hga010安卓二维码.mgi" class="hidden">石家庄信息工程职业学院</a> <a href="/CN/bfvtyg-493813" class="hidden">17173动漫频道</a> <a href="/CN/snaiaw-177399.html" class="hidden">中金在线行情中心</a> <a href="/sttcs/hot-news/Spiraeaceae.html" class="hidden">推哈网</a> <a href="/CN/ybboib-431447" class="hidden">机械师笔记本官网</a> <a href="/sttcs/hot-news/unbenignity.html" class="hidden">中国彭泽网</a> </body></html>