Single Image Callout Component: Difference between revisions
No edit summary |
|||
| (One intermediate revision by the same user not shown) | |||
| Line 1: | Line 1: | ||
The Single Image Callout component is a simple yet visually compelling component consisting of an image | {{DrupalBack}} | ||
The '''Single Image Callout''' component is a simple yet visually compelling component consisting of an image or video, abstract, and label. The abstract slightly repositions itself as the visitor scrolls the page, creating a subtle parallax effect. | |||
== Elements == | == Elements == | ||
| Line 11: | Line 12: | ||
## <u>Options</u>: Red (''default''), Gray | ## <u>Options</u>: Red (''default''), Gray | ||
{{Screenshot|Screenshot 2024-06-14 at 1.40.43 PM.png|800px|Diagram showing the fields that make up the Single Image Callout component.|The Single Image Callout component fields.}} | |||
== Examples == | == Examples == | ||
{{Callout|type=tip|title=Interactive Example|content=The preview below shows the Single Image Callout component using its default configuration. | |||
To experiment with different layouts and other settings, open the interactive component playground. | |||
'''[https://toolkit.swarthmore.edu/?path=/story/swarthmore-theme-components-single-image-callout Open Component Playground]'''}} | |||
{{StorybookComponent|id=swarthmore-theme-components-single-image-callout|height=650}} | {{StorybookComponent|id=swarthmore-theme-components-single-image-callout|height=650}} | ||
| Line 19: | Line 26: | ||
== Step-by-step Instructions == | == Step-by-step Instructions == | ||
# Provide a | # Provide a '''Title''' for the '''Single Image Callout'''. | ||
# Optionally, add a short | # Optionally, add a short '''Label''' to provide additional context. For example, '''Sustainability''' for a callout about composting on campus. | ||
# Add the | # Add the '''Abstract''' that will appear beside the image. | ||
# Add the | # Add the '''Image''' (optimal dimensions: '''1530px × 1020px'''). | ||
## <u>If using an existing image already in the system</u>: | ## <u>If using an existing image already in the system</u>: | ||
### Click | ### Click the '''Insert an Image''' button to launch the image browser. | ||
### Navigate to the image under | ### Navigate to the image under '''Select Image''', select it using the radio button, and click '''Select Image'''. | ||
## <u>If using a new image</u>: | ## <u>If using a new image</u>: | ||
### | ### Click the '''Insert an Image''' button to launch the image browser. | ||
### Click | ### Click '''Upload Image''', then click '''Browse…''' to locate the image on your computer. Finally, click '''Select Image'''. | ||
## Optionally, add a | ## Optionally, add a '''Video URL'''. The system expects videos to come from YouTube. | ||
### ''Note'' | ### ''Note:'' If both a '''Video URL''' and '''Image File''' are present, the image will be used as the video's poster image. This is the intended behavior but is not required. | ||
# Use the | # Use the '''Reverse Alignment''' checkbox to optionally flip the alignment of the image. | ||
# Set the | # Set the '''Callout Color''' (the "callout" is the box that contains the text). | ||
[[Category:Drupal]] | [[Category:Drupal]] | ||
Latest revision as of 13:15, 10 July 2026
The Single Image Callout component is a simple yet visually compelling component consisting of an image or video, abstract, and label. The abstract slightly repositions itself as the visitor scrolls the page, creating a subtle parallax effect.
Elements
- Title (required, not displayed)
- Label
- Image/Video (not required, but strongly recommended)
- Abstract (not required, but strongly recommended)
- Reverse Alignment
- Callout Color
- Options: Red (default), Gray
Examples
Interactive Example
The preview below shows the Single Image Callout component using its default configuration.
To experiment with different layouts and other settings, open the interactive component playground.
Open Component Playground
Step-by-step Instructions
- Provide a Title for the Single Image Callout.
- Optionally, add a short Label to provide additional context. For example, Sustainability for a callout about composting on campus.
- Add the Abstract that will appear beside the image.
- Add the Image (optimal dimensions: 1530px × 1020px).
- If using an existing image already in the system:
- Click the Insert an Image button to launch the image browser.
- Navigate to the image under Select Image, select it using the radio button, and click Select Image.
- If using a new image:
- Click the Insert an Image button to launch the image browser.
- Click Upload Image, then click Browse… to locate the image on your computer. Finally, click Select Image.
- Optionally, add a Video URL. The system expects videos to come from YouTube.
- Note: If both a Video URL and Image File are present, the image will be used as the video's poster image. This is the intended behavior but is not required.
- If using an existing image already in the system:
- Use the Reverse Alignment checkbox to optionally flip the alignment of the image.
- Set the Callout Color (the "callout" is the box that contains the text).
