1
0
mirror of https://github.com/ZSCNetSupportDept/website.git synced 2025-10-30 01:46:19 +08:00
Files
website/assets/js/9e4087bc.f4dad74f.js
2025-10-21 23:42:59 +08:00

1 line
2.0 KiB
JavaScript

"use strict";(self.webpackChunkdeveloper_zsc=self.webpackChunkdeveloper_zsc||[]).push([[2711],{36266:(e,r,a)=>{a.d(r,{i:()=>s});var t=a(44586);function s(e={}){const{i18n:{currentLocale:r}}=(0,t.A)(),a=function(){const{i18n:{currentLocale:e,localeConfigs:r}}=(0,t.A)();return r[e].calendar}();return new Intl.DateTimeFormat(r,{calendar:a,...e})}},89331:(e,r,a)=>{a.r(r),a.d(r,{default:()=>m});a(96540);var t=a(28774),s=a(21312),n=a(61213),i=a(36266),c=a(86849),l=a(51107),o=a(74848);function d({year:e,posts:r}){const a=(0,i.i)({day:"numeric",month:"long",timeZone:"UTC"});return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(l.A,{as:"h3",id:e,children:e}),(0,o.jsx)("ul",{children:r.map((e=>{return(0,o.jsx)("li",{children:(0,o.jsxs)(t.A,{to:e.metadata.permalink,children:[(r=e.metadata.date,a.format(new Date(r)))," - ",e.metadata.title]})},e.metadata.date);var r}))})]})}function h({years:e}){return(0,o.jsx)("section",{className:"margin-vert--lg",children:(0,o.jsx)("div",{className:"container",children:(0,o.jsx)("div",{className:"row",children:e.map(((e,r)=>(0,o.jsx)("div",{className:"col col--4 margin-vert--lg",children:(0,o.jsx)(d,{...e})},r)))})})})}function m({archive:e}){const r=(0,s.T)({id:"theme.blog.archive.title",message:"Archive",description:"The page & hero title of the blog archive page"}),a=(0,s.T)({id:"theme.blog.archive.description",message:"Archive",description:"The page & hero description of the blog archive page"}),t=function(e){const r=e.reduce(((e,r)=>{const a=r.metadata.date.split("-")[0],t=e.get(a)??[];return e.set(a,[r,...t])}),new Map);return Array.from(r,(([e,r])=>({year:e,posts:r})))}(e.blogPosts);return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(n.be,{title:r,description:a}),(0,o.jsxs)(c.A,{children:[(0,o.jsx)("header",{className:"hero hero--primary",children:(0,o.jsxs)("div",{className:"container",children:[(0,o.jsx)(l.A,{as:"h1",className:"hero__title",children:r}),(0,o.jsx)("p",{className:"hero__subtitle",children:a})]})}),(0,o.jsx)("main",{children:t.length>0&&(0,o.jsx)(h,{years:t})})]})]})}}}]);