diff --git a/app/assets/css/main.css b/app/assets/css/main.css index d9f4489..4f1d4ce 100644 --- a/app/assets/css/main.css +++ b/app/assets/css/main.css @@ -3,85 +3,53 @@ /* ---- local fonts ---- */ @font-face { font-family: "IRANSans"; - src: url("/fonts/IRANSansWeb_UltraLight.woff2") format("woff2"); + src: url("/fonts/IRANSansWebFaNum_UltraLight.woff2") format("woff2"); font-weight: 200; font-style: normal; font-display: swap; } @font-face { font-family: "IRANSans"; - src: url("/fonts/IRANSansWeb_Light.woff2") format("woff2"); + src: url("/fonts/IRANSansWebFaNum_Light.woff2") format("woff2"); font-weight: 300; font-style: normal; font-display: swap; } @font-face { font-family: "IRANSans"; - src: url("/fonts/IRANSansWeb.woff2") format("woff2"); + src: url("/fonts/IRANSansWebFaNum.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; } @font-face { font-family: "IRANSans"; - src: url("/fonts/IRANSansWeb_Medium.woff2") format("woff2"); + src: url("/fonts/IRANSansWebFaNum_Medium.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; } @font-face { font-family: "IRANSans"; - src: url("/fonts/IRANSansWeb_Bold.woff2") format("woff2"); + src: url("/fonts/IRANSansWebFaNum_Bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; } @font-face { - font-family: "IRANSans Fallback"; - src: local("Arial"); - ascent-override: 100%; - descent-override: 35%; - line-gap-override: 0%; - size-adjust: 100%; -} -@font-face { - font-family: "ibmPlexMono"; - src: url("/fonts/IBMPlexMono-Regular.woff2") format("woff2"); - font-weight: 400; + font-family: "IRANSans"; + src: url("/fonts/IRANSansWebFaNum_Black.woff2") format("woff2"); + font-weight: 900; font-style: normal; font-display: swap; } -@font-face { - font-family: "ibmPlexMono"; - src: url("/fonts/IBMPlexMono-Medium.woff2") format("woff2"); - font-weight: 500; - font-style: normal; - font-display: swap; -} -@font-face { - font-family: "ibmPlexMono"; - src: url("/fonts/IBMPlexMono-SemiBold.woff2") format("woff2"); - font-weight: 600; - font-style: normal; - font-display: swap; -} -@font-face { - font-family: "ibmPlexMono Fallback"; - src: local("Arial"); - ascent-override: 77.95%; - descent-override: 20.91%; - line-gap-override: 0%; - size-adjust: 131.49%; -} - :root { - --font-iransans: "IRANSans", "IRANSans Fallback", Tahoma, system-ui, sans-serif; - --font-ibm-plex-mono: "ibmPlexMono", "ibmPlexMono Fallback", ui-monospace, monospace; + --font-iransans: "IRANSans", sans-serif; } @theme { - --font-sans: var(--font-iransans), ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif; - --font-mono: var(--font-ibm-plex-mono), "IRANSans", ui-monospace, monospace; + --font-sans: var(--font-iransans); + --font-mono: var(--font-iransans); --color-bg: #0b1224; --color-panel: #101a32; diff --git a/app/pages/categories/[slug].vue b/app/pages/categories/[slug].vue index 528753d..5b586e7 100644 --- a/app/pages/categories/[slug].vue +++ b/app/pages/categories/[slug].vue @@ -42,6 +42,17 @@ useSeoMeta({ ogDescription: category.fullDesc, }); useJsonLd(categoryPageSchema(category), `category-${slug}`); + +const activeGroup = ref(null); +const visibleProducts = computed(() => + activeGroup.value + ? category.products.filter((p) => p.group === activeGroup.value) + : category.products, +); +const activeGroupDesc = computed( + () => category.groups?.find((g) => g.slug === activeGroup.value)?.desc, +); +const groupCount = (g: string) => category.products.filter((p) => p.group === g).length;