Publishing sectionsCaseNext
Searchastronomic.dev# CaseNext
At the foot of a case study: one large link to the next project, with its photo.
Static: no JavaScript.
## Usage
```astro
import CaseNext from "@astronomic/ui-pro/components/CaseNext.astro";
```
## Examples
### Next project
Your eyebrow, the next project's title large with an arrow, and its photo beside it from a 42rem block (under it below that). The whole block is one link.
```astro
---
import CaseNext from "@astronomic/ui-pro/components/CaseNext.astro";
// Your own photo.
import stairway from "../../photos/white-stairway.webp";
---
<!-- At a case study's foot: the whole block is one link to the next project. -->
<div class="mx-auto max-w-6xl px-6 py-10">
<CaseNext eyebrow="Next project" title="Quarry Street Library" href="#quarry" image={{ src: stairway }} />
</div>
```
## Props
### CaseNext
| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `title` | `string` | None | Required. The next project's name: the block's one link. |
| `href` | `string` | None | Required. The next project's page. |
| `eyebrow` | `string` | None | Required. A short line above the title, in your words, such as "Next project". |
| `image` | `DecorativeImage` | None | The next project's photo, { src, width?, height?, ratio?, focalPoint?, loading? }: decoration, so the part writes alt="" (the title names it). 16/9 by default. |
| `headingTag` | `"h2" \| "h3" \| "h4"` | `"h2"` | The title's element. |
| `imageComponent` | `ImageComponent` | None | Your image component: Astro's <Image>, or a small wrapper for your CMS. |
| `imageSizes` | `string` | `"(min-width: 48rem) 40vw, 100vw"` | How wide the photo shows, as the sizes attribute, for your component's srcset. |
| `class` | `string` | None | More classes for the root <div>, merged with cn(). It is a named size container (case-next). |
Any other attribute goes on the root <div>.
## Accessibility
- One link, named by the title alone: the arrow is hidden from screen readers, and the photo is decoration.
- A click anywhere on the block follows the link, and the focus ring goes round the whole block.
CaseNext
ProAt the foot of a case study: one large link to the next project, with its photo.
- File
- CaseNext.astro
- Group
- Publishing sections
- Kind
- Static: no JavaScript
- Examples
- 1
Examples
Drag the orange handle to set the width. Frames get real breakpoints.
- Static
- Interactive
- Framed
Next project
Your eyebrow, the next project's title large with an arrow, and its photo beside it from a 42rem block (under it below that). The whole block is one link.
This preview did not load.
main.astro
examples/casenext/main.astro
---
import CaseNext from "@astronomic/ui-pro/components/CaseNext.astro";
// Your own photo.
import stairway from "../../photos/white-stairway.webp";
---
<!-- At a case study's foot: the whole block is one link to the next project. -->
<div class="mx-auto max-w-6xl px-6 py-10">
<CaseNext eyebrow="Next project" title="Quarry Street Library" href="#quarry" image={{ src: stairway }} />
</div>Minimal · Light