Skip to content

Commit a5697fd

Browse files
committed
Revert "Prepare domain switch for Changelog (#9152)"
This reverts commit 8bfa518.
1 parent ace2f9a commit a5697fd

File tree

5 files changed

+19
-26
lines changed

5 files changed

+19
-26
lines changed

app/changelog/globals.css

-4
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,6 @@
44
@tailwind components;
55
@tailwind utilities;
66

7-
8-
#changelogcontent {
9-
font-family: var(--font-rubik);
10-
}
117
.radix-themes {
128
--cursor-button: pointer;
139
}

app/changelog/header.tsx

+4-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
1+
import Image from 'next/image';
2+
13
export default function Header({loading}) {
24
return (
35
<div className="w-full mx-auto h-96 relative bg-darkPurple">
46
<div className="relative w-full lg:max-w-7xl mx-auto px-4 lg:px-8 pt-8 grid grid-cols-12 items-center">
5-
<img
7+
<Image
68
className={`justify-self-center col-span-10 z-20 hidden lg:block ${loading ? 'animate-fade-in-left' : ''}`}
7-
src="https://docs.sentry.io/changelog/assets/hero.png"
9+
src="/changelog/assets/hero.png"
810
alt="Sentry Changelog"
911
height={273}
1012
width={450}

app/changelog/layout.tsx

+1-2
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ const rubik = Rubik({
1313
weight: ['400', '500', '700'],
1414
style: ['normal', 'italic'],
1515
subsets: ['latin'],
16-
variable: '--font-rubik',
1716
});
1817

1918
export const metadata: Metadata = {
@@ -24,7 +23,7 @@ export default function ChangelogLayout({children}: {children: ReactNode}) {
2423
return (
2524
<Theme accentColor="violet" grayColor="sand" radius="large" scaling="95%">
2625
<NextTopLoader color="#8d5494" />
27-
<div id="changelogcontent" className={`${rubik.variable}`}>
26+
<div className={`${rubik.className}`}>
2827
<Navbar />
2928
<div className="bg-gray-100">{children}</div>
3029
<div className="w-full mx-auto h-16 relative bg-darkPurple">

next.config.js

+4-13
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,8 @@
11
const createMDX = require('@next/mdx');
22
const remarkPrism = require('remark-prism');
33

4-
const isProd = process.env.NODE_ENV === 'production' && !process.env.IS_PREVIEW;
5-
64
/** @type {import('next').NextConfig} */
75
const nextConfig = {
8-
headers() {
9-
return [
10-
{
11-
source: '/_next/static/([^/]+/pages|chunks|runtime|css|fonts|media)/(.+)',
12-
headers: [{key: 'Access-Control-Allow-Origin', value: '*'}],
13-
},
14-
];
15-
},
16-
assetPrefix: isProd ? 'https://docs.sentry.io' : undefined,
17-
186
pageExtensions: ['js', 'jsx', 'mdx', 'ts', 'tsx'],
197

208
images: {
@@ -3157,7 +3145,7 @@ module.exports = withSentryConfig(
31573145
// Suppresses source map uploading logs during build
31583146
silent: true,
31593147
org: 'sentry',
3160-
project: 'docs',
3148+
project: 'sentry-docs-nextjs',
31613149
},
31623150
{
31633151
// For all available options, see:
@@ -3169,6 +3157,9 @@ module.exports = withSentryConfig(
31693157
// Transpiles SDK to be compatible with IE11 (increases bundle size)
31703158
transpileClientSDK: true,
31713159

3160+
// Routes browser requests to Sentry through a Next.js rewrite to circumvent ad-blockers (increases server load)
3161+
tunnelRoute: '/monitoring',
3162+
31723163
// Hides source maps from generated client bundles
31733164
hideSourceMaps: true,
31743165

src/components/changelog/article.tsx

+10-5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import {ReactNode} from 'react';
2+
import Image from 'next/image';
23

34
import Date from './date';
45
import Tag from './tag';
@@ -30,11 +31,15 @@ export default function Article({
3031
return (
3132
<article className={`bg-white rounded-lg shadow-lg mb-8 ${className}`}>
3233
{image && (
33-
<img
34-
className="object-cover relative w-full h-64 rounded-lg rounded-b-none"
35-
src={image}
36-
alt={title}
37-
/>
34+
<div className="relative w-full h-64">
35+
<Image
36+
className="object-cover rounded-lg rounded-b-none"
37+
src={image}
38+
fill
39+
alt={title}
40+
sizes="(max-width: 768px) 100vw"
41+
/>
42+
</div>
3843
)}
3944
<div className="p-6">
4045
<h3 className="text-3xl text-primary font-semibold mb-2">{title}</h3>

0 commit comments

Comments
 (0)