Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion apps/blog/src/routes/+layout.server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@ export const load: LayoutServerLoad = (async (event) => {
'Referrer-Policy': 'no-referrer-when-downgrade',
'Strict-Transport-Security': 'max-age=31536000; includeSubDomains; preload',
'Cross-Origin-Opener-Policy': 'same-origin',
'Permissions-Policy': 'camera=(), microphone=(), geolocation=()'
'Permissions-Policy':
'camera=(), microphone=(), geolocation=(), payment=(), usb=(), magnetometer=(), gyroscope=(), accelerometer=()',
'Content-Security-Policy':
"default-src 'self'; script-src 'self' 'unsafe-inline'; style-src 'self' 'unsafe-inline'; img-src 'self' data: https:; font-src 'self' data:; connect-src 'self'; object-src 'none'; base-uri 'none';"
});

const home = await getHome();
Expand Down
52 changes: 52 additions & 0 deletions apps/blog/src/routes/sitemap.xml/+server.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
import { getPosts } from '@a11y.cool/data';

type SitemapPage = {
url: string;
priority: string;
changefreq: string;
lastmod?: string;
};

export const GET = async ({ url }: { url: URL }) => {
const posts = await getPosts();
const baseUrl = url.origin;

// Static pages (excluding sensitive pages with personal information)
const staticPages: SitemapPage[] = [
{ url: '/', priority: '1.0', changefreq: 'weekly' },
{ url: '/about', priority: '0.8', changefreq: 'monthly' },
{ url: '/blog', priority: '0.9', changefreq: 'weekly' }
];

// Blog posts
const blogPages: SitemapPage[] = posts.map((post) => ({
url: `/blog/${post.slug}`,
priority: '0.7',
changefreq: 'monthly',
lastmod: post.publishedAt ? new Date(post.publishedAt).toISOString() : undefined
}));

// Combine all pages
const allPages = [...staticPages, ...blogPages];

// Generate XML sitemap
const sitemap = `<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
${allPages
.map(
(page) => ` <url>
<loc>${baseUrl}${page.url}</loc>
<changefreq>${page.changefreq}</changefreq>
<priority>${page.priority}</priority>${page.lastmod ? `\n <lastmod>${page.lastmod}</lastmod>` : ''}
</url>`
)
.join('\n')}
</urlset>`;

return new Response(sitemap, {
headers: {
'Content-Type': 'application/xml',
'Cache-Control': 'public, max-age=3600' // Cache for 1 hour
}
});
};
4 changes: 4 additions & 0 deletions apps/blog/static/.well-known/security.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Contact: mailto:privacy@accessibility.cool
Expires: 2025-12-31T23:59:59.000Z
Preferred-Languages: en
Canonical: https://accessibility.cool/.well-known/security.txt
13 changes: 13 additions & 0 deletions apps/blog/static/humans.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
/* TEAM */
Developer: Simon Phumin Schweikert & Oliver Schwamb
Contact: accessibility.cool
From: Germany

/* SITE */
Last update: 2025
Language: English
Doctype: HTML5
IDE: Cursor
Standards: HTML5, CSS3, JavaScript ES6+
Components: SvelteKit 5, TypeScript, Tailwind CSS
Software: Vite, Turbo, pnpm
42 changes: 42 additions & 0 deletions apps/blog/static/robots.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
User-agent: *
Allow: /

Disallow: /privacy-policy/
Disallow: /imprint/

# Sitemap location
Sitemap: https://accessibility.cool/sitemap.xml

# Crawl delay (optional - helps with server load)
Crawl-delay: 1

# Allow all major search engines
User-agent: Googlebot
Allow: /
Disallow: /privacy-policy/
Disallow: /imprint/

User-agent: Bingbot
Allow: /
Disallow: /privacy-policy/
Disallow: /imprint/

User-agent: Slurp
Allow: /
Disallow: /privacy-policy/
Disallow: /imprint/

User-agent: DuckDuckBot
Allow: /
Disallow: /privacy-policy/
Disallow: /imprint/

User-agent: Baiduspider
Allow: /
Disallow: /privacy-policy/
Disallow: /imprint/

User-agent: YandexBot
Allow: /
Disallow: /privacy-policy/
Disallow: /imprint/
7 changes: 1 addition & 6 deletions apps/blog/svelte.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,7 @@ const config = {
// adapter-auto only supports some environments, see https://kit.svelte.dev/docs/adapter-auto for a list.
// If your environment is not supported or you settled on a specific environment, switch out the adapter.
// See https://kit.svelte.dev/docs/adapters for more information about adapters.
adapter: adapter(),
csp: {
directives: {
'script-src': ['self']
}
}
adapter: adapter()
}
};

Expand Down
35 changes: 28 additions & 7 deletions packages/data/src/default/metaDefault.data.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,38 @@ export const defaultMetaTags = (url: { pathname: string; origin: string }) =>
Object.freeze({
title: '',
titleTemplate: '%s — Accessibility.cool',
description: 'Digital Accessibility Resources, Tips and Guidance.',
description:
'Expert digital accessibility guidance, WCAG compliance tips, and inclusive design resources. Learn web accessibility best practices, testing tools, and how to create accessible websites for all users.',
canonical: new URL(url.pathname, url.origin).href,
keywords: [
'digital accessibility',
'web accessibility',
'inclusive design',
'WCAG compliance',
'accessibility testing',
'screen reader accessibility',
'keyboard navigation',
'ARIA labels',
'semantic HTML',
'accessibility guidelines',
'universal design',
'accessible websites',
'UX accessibility',
'disability-friendly design',
'assistive technology'
],
openGraph: {
type: 'website',
url: new URL(url.pathname, url.origin).href,
locale: 'en_US',
title: 'Accessibility.cool',
description: 'Digital Accessibility Resources, Tips and Guidance.',
title: 'Accessibility.cool - Digital Accessibility & Inclusive Design Resources',
description:
'Expert digital accessibility guidance, WCAG compliance tips, and inclusive design resources. Learn web accessibility best practices, testing tools, and how to create accessible websites for all users.',
siteName: 'Accessibility.cool',
images: [
{
url: 'https://accessibility.cool/accessibility-cool-meta.jpg',
alt: 'Accessibility.cool Logo',
alt: 'Accessibility.cool Logo - Digital Accessibility and Inclusive Design Resources',
width: 1200,
height: 630,
secureUrl: 'https://accessibility.cool/accessibility-cool-meta.jpg',
Expand All @@ -26,9 +45,11 @@ export const defaultMetaTags = (url: { pathname: string; origin: string }) =>
},
twitter: {
cardType: 'summary_large_image' as const,
title: 'Accessibility.cool',
description: 'Digital Accessibility Resources, Tips and Guidance.',
title: 'Accessibility.cool - Digital Accessibility & Inclusive Design Resources',
description:
'Expert digital accessibility guidance, WCAG compliance tips, and inclusive design resources. Learn web accessibility best practices, testing tools, and how to create accessible websites for all users.',
image: 'https://accessibility.cool/accessibility-cool-meta.jpg',
imageAlt: 'Accessibility.cool Logo'
imageAlt:
'Accessibility.cool Logo - Digital Accessibility and Inclusive Design Resources'
}
}) satisfies MetaTagsProps;
6 changes: 2 additions & 4 deletions packages/ui/src/styles/typography.css
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
:where(h1) {
@apply font-highlight;
@apply text-2xl md:text-3xl lg:text-4xl tracking-wide text-foreground;
margin-block: 0.67em;
font-size: 2em;
}
h2,
h3,
Expand All @@ -11,10 +13,6 @@
@apply font-sans font-medium;
}

h1 {
@apply text-2xl md:text-3xl lg:text-4xl tracking-tight text-foreground;
}

h2 {
@apply text-xl md:text-2xl lg:text-3xl tracking-tight text-foreground;
}
Expand Down