Complete Story 1-1 and fix TypeScript issues
Add TypeScript strict mode and typecheck tasks to monorepo infrastructure. Fix E2E test @payload-config alias and frontend TypeScript errors. - Add tsconfig.json to backend with strict mode and path aliases - Add typecheck task to Turborepo and all packages - Fix @payload-config alias for E2E tests and dev server - Add setToken method to AuthService for middleware use - Fix implicit any types in Footer.astro and Header.astro - Remove invalid typescript config from astro.config.mjs
This commit is contained in:
@@ -51,6 +51,13 @@ import { Image } from 'astro:assets';
|
||||
|
||||
<script>
|
||||
// Client-side data fetching for footer
|
||||
interface LinkItem {
|
||||
link?: {
|
||||
url?: string;
|
||||
label?: string;
|
||||
};
|
||||
}
|
||||
|
||||
async function loadFooterData() {
|
||||
try {
|
||||
console.log('Fetching footer data...');
|
||||
@@ -61,7 +68,7 @@ import { Image } from 'astro:assets';
|
||||
// Update marketing solutions
|
||||
const marketingUl = document.getElementById('marketing-solutions');
|
||||
if (marketingUl && data.navItems?.[0]?.childNavItems) {
|
||||
const links = data.navItems[0].childNavItems.map(item =>
|
||||
const links = data.navItems[0].childNavItems.map((item: LinkItem) =>
|
||||
`<li><a href="${item.link?.url || '#'}" class="font-normal text-[var(--color-st-tropaz)] hover:text-[var(--color-dove-gray)] transition-colors">${item.link?.label}</a></li>`
|
||||
).join('');
|
||||
marketingUl.innerHTML = links;
|
||||
@@ -70,7 +77,7 @@ import { Image } from 'astro:assets';
|
||||
// Update marketing articles (行銷放大鏡)
|
||||
const articlesUl = document.getElementById('marketing-articles');
|
||||
if (articlesUl && data.navItems?.[1]?.childNavItems) {
|
||||
const links = data.navItems[1].childNavItems.map(item =>
|
||||
const links = data.navItems[1].childNavItems.map((item: LinkItem) =>
|
||||
`<li><a href="${item.link?.url || '#'}" class="font-normal text-[var(--color-st-tropaz)] hover:text-[var(--color-dove-gray)] transition-colors">${item.link?.label}</a></li>`
|
||||
).join('');
|
||||
articlesUl.innerHTML = links;
|
||||
|
||||
Reference in New Issue
Block a user