Build an Infinite Logo and Text Marquee with Pause, Direction and Speed Controls

Get one HTML page with a seamless looping marquee of logos or text chips built in pure CSS, with hover pause, reverse direction, speed control, edge fade masks and a static reduced-motion layout.

You getComplete HTML in one code block, test checklist table and risks and next actions

The prompt

Prompt
Role: You are a front-end engineer who builds accessible, smooth ticker and marquee components.Context: Brightpath Learning (example value for {company_name}) needs a looping strip of integration partner names (example value for {item_type}) for its landing page. The job to be done is to ship a marquee that loops without a visible jump, stays accessible, and lets the team choose speed and direction before committing.

Inputs:
- Company: Brightpath Learning (example value for {company_name})
- Item type: integration partner names (example value for {item_type})
- Items (comma-separated): Slack, Notion, Zoom, Google Drive, Canvas, Teams (example value for {items})
- Speed in pixels per second: 60 (example value for {speed_px_per_second})
List assumptions separately under Assumptions.

Task: Build ONE self-contained HTML file with inline CSS and a small vanilla JS block. No libraries or external images; render items as styled text chips or simple inline SVG shapes.

Workflow:
1. Render Slack, Notion, Zoom, Google Drive, Canvas, Teams (example value for {items}) in a track, then duplicate the set so the loop is seamless. Use a CSS keyframe translateX from 0 to -50%, with duration calculated in JS from track width and 60 (example value for {speed_px_per_second}).
2. Add two rows: one moving left, one moving right at a slightly different speed.
3. Add edge fade using mask-image with linear-gradient.
4. Pause on hover and on keyboard focus within the strip, via animation-play-state.
5. Add a control bar: speed slider, direction toggle, and a visible Pause/Play button.
6. Recalculate duration on resize and when fonts finish loading.

Constraints:
- The duplicated set must be hidden from assistive tech with aria-hidden='true'; the original list stays a real ul with readable items.
- Under prefers-reduced-motion, show a static wrapped grid with no animation and no duplicates.
- Animate transform only; avoid layout-triggering properties.
- Keep it under 250 lines.

Output format:
1. Assumptions
2. Complete HTML in one code block
3. Test checklist table: scenario, expected result (narrow screen, long item list, reduced motion, tab focus)
4. Risks and next actions (for example few items not filling wide screens, how to add more)

Acceptance criteria:
- No visible jump or gap at the loop point on wide screens.
- Speed matches the slider within a reasonable visual margin.
- Pause works by mouse, keyboard and button.
- Static fallback is fully usable.

Quality checks: Verify the track is wide enough to fill the viewport even with few items (repeat as needed), that duplicates are hidden from screen readers, and that every {variable} was applied. Tool note: in Claude, return a single HTML artifact; in ChatGPT, one code block; in Cursor, create index.html only; in Gemini, avoid external dependencies.

Dashed parts are example values, so the prompt runs as copied. Change them in Fill in the blanks.

Use for client logo bars, feature tickers or announcement strips. Replace chips with real SVG logos only if you have usage rights. Add enough items so the set is wider than the widest screen you support.

Make it repeatable

Keep using this prompt without pasting it in every time.

Prompt details

By
Prompts-GPT editors
Published
How prompts are written and checked

Did this prompt work?

Keep exploring

More in Animations & Effects