menu-interactions

menu-interactions is a skill for Claude Code, Codex from asmyshlyaev177/react-horizontal-scrolling-menu. It costs 147 tokens per session (3,395 once invoked), scanned A, original, MIT.

Input handling for a React horizontal scrolling menu. It covers mouse dragging, the mouse wheel, touch events, and scroll callbacks, including the different function shapes expected by the menu.

In plain words
What is it for?
Use it to add desktop drag-to-scroll, respond to wheel movement, handle touch gestures, and run code when the menu scrolls.
Why use it?
It prevents handlers from being connected incorrectly, especially because wheel and scroll callbacks differ from mouse and touch handlers. It also clarifies when basic mobile swiping needs no extra code.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to add desktop drag-to-scroll, respond to wheel movement, handle touch gestures, and run code when the menu scrolls.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/asmyshlyaev177/react-horizontal-scrolling-menu/menu-interactions
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add asmyshlyaev177/react-horizontal-scrolling-menu --skill menu-interactions
Clone the repo
git clone --depth 1 https://github.com/asmyshlyaev177/react-horizontal-scrolling-menu

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for menu-interactions

README.md
[![agentmods](https://agentmods.dev/badge/skills/asmyshlyaev177/react-horizontal-scrolling-menu/menu-interactions/github.svg)](https://agentmods.dev/skills/asmyshlyaev177/react-horizontal-scrolling-menu/menu-interactions)
Your own site
<a href="https://agentmods.dev/skills/asmyshlyaev177/react-horizontal-scrolling-menu/menu-interactions"><img src="https://agentmods.dev/badge/skills/asmyshlyaev177/react-horizontal-scrolling-menu/menu-interactions/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for menu-interactions

Your own site · 80×15
<a href="https://agentmods.dev/skills/asmyshlyaev177/react-horizontal-scrolling-menu/menu-interactions"><img src="https://agentmods.dev/badge/skills/asmyshlyaev177/react-horizontal-scrolling-menu/menu-interactions.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 147 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,395 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00147 $0.03395
Opus 5.5 $0.00059 $0.01358
Sonnet 5.5 $0.00029 $0.00679
Haiku 4.5 $0.00015 $0.00340

Measured 1mo ago against content hash 3277d31ad94f, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

menu-interactions scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/menu-interactions/SKILL.md · 461 lines

How it starts

The opening of the file, as written. The whole thing — 461 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Pointer, Wheel and Touch Interactions

ScrollMenu has two callback shapes. Getting this wrong is the #1 input bug:

  • onWheel / onScroll are plain callbacks: (api, event) => void
  • ALL mouse and touch props (onMouseDown, onMouseUp, onMouseMove, onMouseLeave, onTouchStart, onTouchMove, onTouchEnd) are handler factories: (api) => (event) => void. ScrollMenu invokes the factory with the api during render and attaches the returned function as the DOM handler.

All wheel/mouse/touch handlers attach to the outermost wrapper div (so they also fire over arrows, Header and Footer); onScroll attaches to the scroll container itself (src/index.tsx:319-347). api is the same publicApiType object that VisibilityContext provides.

Touch devices scroll the menu natively — no touch props are needed for basic mobile swipe. Drag-to-scroll below is the desktop "swipe" equivalent.

Setup

Both shapes wired on a minimal menu:

import React from 'react';
import {
  ScrollMenu,
  VisibilityContext,
  type publicApiType,
} from 'react-horizontal-scrolling-menu';
import 'react-horizontal-scrolling-menu/dist/styles.css';

function Card({ itemId }: { itemId: string }) {
  const api = React.useContext<publicApiType>(VisibilityContext);
  const visible = api.useIsVisible(itemId, true);
  return <div style={{ width: 160, opacity: visible ? 1 : 0.5 }}>{itemId}</div>;
}

// Plain shape — (api, event) => void
const onWheel = (api: publicApiType, ev: React.WheelEvent): void => {
  if (ev.deltaY < 0) api.scrollNext();
  else api.scrollPrev();
};

// Factory shape — (api) => (event) => void
const onMouseDown =
  (_api: publicApiType) =>
  (ev: React.MouseEvent): void => {
    ev.preventDefault(); // block native image/link drag inside items
  };

const ids = ['a', 'b', 'c', 'd', 'e', 'f'];

export function Menu() {
  return (
    <ScrollMenu onWheel={onWheel} onMouseDown={onMouseDown}>
      {ids.map((id) => (
        <Card itemId={id} key={id} />
      ))}
    </ScrollMenu>
  );
}

Read the full file on GitHub · 461 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago Changed · +5 lines 3277d31ad94f
  2. 1mo ago First seen · 456 lines · 147 tokens per session scan A 1aa4060c37c9

Subscribe to this mod's changes

menu-interactions is a skill published in the GitHub repository asmyshlyaev177/react-horizontal-scrolling-menu (789 stars, last pushed 19d ago), licensed MIT. It adds 147 tokens to every session and 3,395 once invoked, about $0.0006 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

build-with-simplepdf

Integrate SimplePDF into a web application for PDF viewing, editing, filling, signing, programmatic control, AI-agent interaction, human-in-the-loop form prefilling, submissions, webhooks, or customer-controlled storage. Use when a developer wants to add or improve PDF workflows in React, Next.js, JavaScript…

SimplePDF/simplepdf-embed · 103 tokens

capture-api-response-test-fixture

For provider response parsing tests, we aim at storing test fixtures with the true responses from the providers (unless they are too large in which case some cutting that does not change semantics is advised).

vercel/ai · 13 tokens

consuming-endpoints-from-client-code

Wire a PostHog endpoint into a client app or SDK. Covers fetching the OpenAPI spec, generating a typed client with openapi-generator or @hey-api/openapi-ts, sending the right auth header, shaping the variables payload (HogQL codename vs insight breakdown property), handling rate-limit and materialised-endpoint error…

PostHog/posthog · 105 tokens

creating-an-endpoint

Create a PostHog endpoint with the right shape on the first try — covers query kind choice, name conventions, what to expose as variables (HogQL codename vs insight breakdown), datafreshnessseconds, and whether to materialise on day one. Use when the user says "create an endpoint", "expose this query as an API", "turn…

PostHog/posthog · 134 tokens

query-clickhouse-via-metabase

Run ClickHouse system.querylog analysis via the internal Metabase API. Use when investigating slow queries, materialization candidates, per-team query performance, ClickHouse cost or memory issues, or any system.querylog question. Covers prod-us and prod-eu, SSO-gated cookie auth via hogli, and ready-to-run query…

PostHog/posthog · 79 tokens

mcp-servers

Install, configure, authenticate, and troubleshoot MCP (Model Context Protocol) servers for this agent. Use when the user asks to add/install/remove an MCP server, connect a tool like Linear/Sentry/Supabase/GitHub via MCP, set up mcp.json, or when MCP tools are failing or need OAuth login.

PostHog/posthog · 70 tokens