LEDGERMACHINE

LM-EFFECT-001

Find duplicate box shadows in CSS

Two shadows have nearly identical geometry and color signatures.

What Ledgermachine reports

Similar shadows serve the same purpose

Decision, not automatic repair

Reuse one recipe unless the difference creates a clearly distinct elevation or focus state.

Source example

What this finding can look like

The exact candidate comes from the project’s own tokens and repeated values. This example shows the shape of the issue, not a universal replacement.

Flagged source
.menu { box-shadow: 0 8px 30px rgb(0 0 0 / 8%); }
.modal { box-shadow: 0 8px 32px rgb(0 0 0 / 8%); }
One possible resolution
:root { --shadow-overlay: 0 8px 32px rgb(0 0 0 / 8%); }
.menu, .modal { box-shadow: var(--shadow-overlay); }

Resolution workflow

Fix the source without erasing intent

  1. Inspect

    Review every reported occurrence and the established candidates Ledgermachine found in the same project.

  2. Decide

    Reuse one recipe unless the difference creates a clearly distinct elevation or focus state.

  3. Verify

    Make the change in your editor or coding agent, then rescan. Ledgermachine stays read-only and records whether the finding cleared.

Run it on your source

See the evidence behind this rule.

Open a folder locally, inspect the exact occurrences, and decide whether to repair or preserve the difference.

Open Ledgermachine