-
Notifications
You must be signed in to change notification settings - Fork 3
Migrate Storybook for Next.js #1525
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
* Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput
Resolve linting errors for nextjs branch and introduce nextjs linting plugin
- Removes unnecessary Client Component wrappers and "use client" directives.
- Set `<Suspense />` boundaries to client render components that useSearchParams() around:
- all of the Search page.
- the Learning Resource drawer.
- the dashboard carousels.
…on script package updates
* Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput
Resolve linting errors for nextjs branch and introduce nextjs linting plugin
- Removes unnecessary Client Component wrappers and "use client" directives.
- Set `<Suspense />` boundaries to client render components that useSearchParams() around:
- all of the Search page.
- the Learning Resource drawer.
- the dashboard carousels.
35c32c4 to
4dfc6e5
Compare
| isMedia: boolean, | ||
| ) => { | ||
| if (!process.env.NEXT_PUBLIC_EMBEDLY_KEY!) { | ||
| return resource.image!.url! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will cause an error for resources like https://learn.mit.edu/search?q=Negotiation+Strategy+Sprint%3A+AI-Accelerated+Learning&resource=16078 that do not have an image. We really should not use non-null assertions. Probably should enable the linting rule that forbids these.
Three thoughts:
- Approving, because this doesn't introduce a new issue,
resource.image!.url!is on the next unchanged line anyway. - In isolation, I would fix by changing
resourceto `resource & Required<Pick<LearningResource, "image">>. - But I removed the embedly url here in [NextJS] fix frontend tests outside of
mainworkspace #1527 ... if we agree about that, we can remove the embedly here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We're checking for the image before calling, e.g.
resource.image?.url
? getEmbedlyUrl(resource, size, isMedia)
: DEFAULT_RESOURCE_IMG
I agree though we have the defense here, bit will merge for as your PR removes.
|
|
||
|
|
||
| /* Fix for this error: | ||
| Module not found: Error: Can't resolve 'react-dom/test-utils' in './node_modules/@testing-library/react/dist/@testing-library' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This surprised me because:
- yes,
react-dom/test-utilsis deprecated; its main export,acthas been moved to the mainreactpackage. @testing-library/reactimportsactfromreact, but imports it fromreact-dom/test-utilsas a fallback for older versions of react.
I suspect what's happening is... NextJS's app router uses the canary channel of react (see blog), and in that channel, react-dom/test-utils may not just be deprecated, but removed all together. Hence the error.
* Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Move Storybook root to ol-components * Move GlobalStyles to ol-components * Self contained images * Storybook for Next.js * Remove react-router addon. Upgrade Storybook addons * Fix issue trying to resolve react-dom/test-utils. Storybook 8 migration script package updates * Local image * Replace react-router useLocation * Images fixes. Copy images into ol-components. Embedly fallback * Migrate routed drawer stories for @storybook/nextjs * Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Enable Storybook action * Enable Storybook action * Update lockfile * Use client directive missing from layout --------- Co-authored-by: Chris Chudzicki <christopher.chudzicki@gmail.com>
* Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Move Storybook root to ol-components * Move GlobalStyles to ol-components * Self contained images * Storybook for Next.js * Remove react-router addon. Upgrade Storybook addons * Fix issue trying to resolve react-dom/test-utils. Storybook 8 migration script package updates * Local image * Replace react-router useLocation * Images fixes. Copy images into ol-components. Embedly fallback * Migrate routed drawer stories for @storybook/nextjs * Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Enable Storybook action * Enable Storybook action * Update lockfile * Use client directive missing from layout --------- Co-authored-by: Chris Chudzicki <christopher.chudzicki@gmail.com>
* Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Move Storybook root to ol-components * Move GlobalStyles to ol-components * Self contained images * Storybook for Next.js * Remove react-router addon. Upgrade Storybook addons * Fix issue trying to resolve react-dom/test-utils. Storybook 8 migration script package updates * Local image * Replace react-router useLocation * Images fixes. Copy images into ol-components. Embedly fallback * Migrate routed drawer stories for @storybook/nextjs * Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Enable Storybook action * Enable Storybook action * Update lockfile * Use client directive missing from layout --------- Co-authored-by: Chris Chudzicki <christopher.chudzicki@gmail.com>
* Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Move Storybook root to ol-components * Move GlobalStyles to ol-components * Self contained images * Storybook for Next.js * Remove react-router addon. Upgrade Storybook addons * Fix issue trying to resolve react-dom/test-utils. Storybook 8 migration script package updates * Local image * Replace react-router useLocation * Images fixes. Copy images into ol-components. Embedly fallback * Migrate routed drawer stories for @storybook/nextjs * Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Enable Storybook action * Enable Storybook action * Update lockfile * Use client directive missing from layout --------- Co-authored-by: Chris Chudzicki <christopher.chudzicki@gmail.com>
* Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Move Storybook root to ol-components * Move GlobalStyles to ol-components * Self contained images * Storybook for Next.js * Remove react-router addon. Upgrade Storybook addons * Fix issue trying to resolve react-dom/test-utils. Storybook 8 migration script package updates * Local image * Replace react-router useLocation * Images fixes. Copy images into ol-components. Embedly fallback * Migrate routed drawer stories for @storybook/nextjs * Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Enable Storybook action * Enable Storybook action * Update lockfile * Use client directive missing from layout --------- Co-authored-by: Chris Chudzicki <christopher.chudzicki@gmail.com>
* Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Move Storybook root to ol-components * Move GlobalStyles to ol-components * Self contained images * Storybook for Next.js * Remove react-router addon. Upgrade Storybook addons * Fix issue trying to resolve react-dom/test-utils. Storybook 8 migration script package updates * Local image * Replace react-router useLocation * Images fixes. Copy images into ol-components. Embedly fallback * Migrate routed drawer stories for @storybook/nextjs * Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Enable Storybook action * Enable Storybook action * Update lockfile * Use client directive missing from layout --------- Co-authored-by: Chris Chudzicki <christopher.chudzicki@gmail.com>
* Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Move Storybook root to ol-components * Move GlobalStyles to ol-components * Self contained images * Storybook for Next.js * Remove react-router addon. Upgrade Storybook addons * Fix issue trying to resolve react-dom/test-utils. Storybook 8 migration script package updates * Local image * Replace react-router useLocation * Images fixes. Copy images into ol-components. Embedly fallback * Migrate routed drawer stories for @storybook/nextjs * Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Enable Storybook action * Enable Storybook action * Update lockfile * Use client directive missing from layout --------- Co-authored-by: Chris Chudzicki <christopher.chudzicki@gmail.com>
* Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Move Storybook root to ol-components * Move GlobalStyles to ol-components * Self contained images * Storybook for Next.js * Remove react-router addon. Upgrade Storybook addons * Fix issue trying to resolve react-dom/test-utils. Storybook 8 migration script package updates * Local image * Replace react-router useLocation * Images fixes. Copy images into ol-components. Embedly fallback * Migrate routed drawer stories for @storybook/nextjs * Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Enable Storybook action * Enable Storybook action * Update lockfile * Use client directive missing from layout --------- Co-authored-by: Chris Chudzicki <christopher.chudzicki@gmail.com>
* Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Move Storybook root to ol-components * Move GlobalStyles to ol-components * Self contained images * Storybook for Next.js * Remove react-router addon. Upgrade Storybook addons * Fix issue trying to resolve react-dom/test-utils. Storybook 8 migration script package updates * Local image * Replace react-router useLocation * Images fixes. Copy images into ol-components. Embedly fallback * Migrate routed drawer stories for @storybook/nextjs * Next.js Initial Migration (#1505) * Next.js scaffold * Supply env vars on process.env.NEXT_PUBLIC_ * Replace react-router hook with next/navigation * MUI theme provider for Next.js * Styled elements * Restructuring to bring pages and components into ssr project * Images and link fixes * Set up prerendering with React Query and fetch Featured Courses carousel on server * Head meta tags * Main entrypoint. Include in yarn workspaces. API URL for local * Add remaining homepage sections * Move into frontends * Lint fixes * Routed drawer and updates for homepage resource drawer search triggers * Move pages (conflict with Next.js Pages Router) * Webpack configs for babel loader (import type) and ignore test files from build * Typescript config, move common/urls * Updates towards successful build * Suspense boudary for header useSearchParam * Provide origin on environment (cannot reference window) * Update drawer hooks for next/navigation * Unit listing page and dependencies * Image fixes. ol-component compatibility updates * Logo image fixes and footer image * Search page * Remove temp course-serach-utils * Remove temp course-serach-utils * Channel Page. Rewrite for image paths * Move @mui/material-nextjs into ol-components * Department listing page * Topic listing page * Terms page * Privacy page * Image paths * Lockfile * Migrates the dashboard pages * Migrate learning path listing page * Migrate learning path details page * Prettier fixes * Migrate test utils. Fixes for passing typechecks on test files (excluding React Router dependencies) * Migrate the onboarding page * Migrate program letter page * Migrate error page * Resolves issue with Server Components treated as Client Components (transpiler). Wraps library imports for use in Next.js. User lists detail page. * Metadata utility * Fetch learning resource for metadata when drawer is open * Async and sync metadata utilities * .env example file * Preserve hero image aspect * Put back SliderInput * Fix linting on nextjs branch (#1509) Resolve linting errors for nextjs branch and introduce nextjs linting plugin * Fixes for successful build (#1516) - Removes unnecessary Client Component wrappers and "use client" directives. - Set `<Suspense />` boundaries to client render components that useSearchParams() around: - all of the Search page. - the Learning Resource drawer. - the dashboard carousels. * Enable Storybook action * Enable Storybook action * Update lockfile * Use client directive missing from layout --------- Co-authored-by: Chris Chudzicki <christopher.chudzicki@gmail.com>
What are the relevant tickets?
Closes: https://github.com/mitodl/hq/issues/5405
Description (What does it do?)
How can this be tested?
Storybook should build and run and all component render and function correctly: