building-blocks

building-blocks is a cursor rule for Cursor from Ocean-Industries-Concept-Lab/openbridge-webcomponents. It costs 0 tokens per session (2,557 once invoked), scanned A, original, Apache-2.0.

Coding rules for SVG-based building-block components and the shared helpers they use. SVG is a format for drawing scalable graphics such as charts, bars, and instrument displays.

In plain words
What is it for?
It helps modify chart, bar, scale, and other SVG components while checking both sides and orientations. It also guides safe changes to shared SVG helper utilities.
Why use it?
It reduces bugs caused by editing only one part of a mirrored or rotated layout. Reading the full file first helps account for related rendering, state, helper, and event logic.

Cursor rule for Cursor

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.

agentmods
npx agentmods add rules/ocean-industries-concept-lab/openbridge-webcomponents/building-blocks
Clone the repo
git clone --depth 1 https://github.com/Ocean-Industries-Concept-Lab/openbridge-webcomponents

Made for: Cursor.

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 building-blocks

README.md
[![agentmods](https://agentmods.dev/badge/rules/ocean-industries-concept-lab/openbridge-webcomponents/building-blocks.svg)](https://agentmods.dev/rules/ocean-industries-concept-lab/openbridge-webcomponents/building-blocks)
Your own site
<a href="https://agentmods.dev/rules/ocean-industries-concept-lab/openbridge-webcomponents/building-blocks"><img src="https://agentmods.dev/badge/rules/ocean-industries-concept-lab/openbridge-webcomponents/building-blocks.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 2,557 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00000 $0.02557
Opus 5 $0.00000 $0.01278
Sonnet 5 $0.00000 $0.00511
Haiku 4.5 $0.00000 $0.00256

Measured 5d ago against content hash 5a06b3dfb0ad, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

building-blocks 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 5d 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.

.cursor/rules/building-blocks.mdc · 201 lines

How it starts

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

Building Blocks & SVG Helpers

These instructions apply to SVG-based building block components (instrument-linear, bar-vertical, etc.) and their shared SVG helper utilities.

Agent Safety Rules (Context + Mirroring)

When implementing changes in this area, avoid narrow/local fixes that can introduce regressions:

  1. Always load the full file into context before editing

    • Read the entire file you are about to change (not just snippets) so you understand how helpers, state, rendering, and events fit together.
    • This is required to avoid “local fixes” that miss related logic and accidentally introduce new bugs.
  2. Always think in mirrored / generalized layouts (sides + orientations)

    • For components like:
      • packages/openbridge-webcomponents/src/building-blocks/external-scale/external-scale.ts
      • packages/openbridge-webcomponents/src/building-blocks/bar-horizontal/bar-horizontal.ts
      • packages/openbridge-webcomponents/src/building-blocks/bar-vertical/bar-vertical.ts
      • packages/openbridge-webcomponents/src/building-blocks/chart-line/chart-line-base.ts
      • packages/openbridge-webcomponents/src/bars-graphs/line-graph/line-graph.ts
      • packages/openbridge-webcomponents/src/bars-graphs/area-graph/area-graph.ts
    • If a task changes behavior for one side (e.g. right), validate the equivalent behavior for the opposite side (left) and for the orthogonal orientation (top/bottom) where applicable.
    • Prefer implementing via shared helpers/config so “all sides / all orientations” stay consistent.

packages/openbridge-webcomponents/src/building-blocks/**

When working with building block components in this directory:

  1. SVG-Based Architecture:
    • Building blocks are pure SVG components rendered using Lit's svg template tag
    • Components typically render into a <svg> element with a viewBox for coordinate system control
    • Use shared helpers from svghelpers/ for coordinate transformations and rendering utilities
    • Consider checking existing building blocks (e.g., instrument-linear) for similar patterns before implementing new features

Read the full file on GitHub · 201 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. 5d ago First seen · 201 lines · 0 tokens per session scan A 5a06b3dfb0ad

Subscribe to this mod's changes

building-blocks is a cursor rule published in the GitHub repository Ocean-Industries-Concept-Lab/openbridge-webcomponents (91 stars, last pushed yesterday), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 2,557 tokens. 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.