openreachtech/hora-skills-ort-furo/hof-css-z-index

Claude Code and agent skill by openreachtech/hora-skills-ort-furo

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Convention for the company's CSS z-index: the three layer base values and the calc() notation.

Install

npx vskill@latest install openreachtech/hora-skills-ort-furo/hof-css-z-index

SKILL.md

Frontend: CSS z-index

z-index is managed in three layers. The base values are defined as variables in :root.

css
:root {
/*
* z-index layers
* (max-value: 2147483647)
*/
--value-z-index-layer-content: 0000000;
--value-z-index-layer-staying: 1000000;
--value-z-index-layer-overlay: 2000000;
}
LayerVariableBase valueFor
ground--value-z-index-layer-content0000000Ordinary content
cloud--value-z-index-layer-staying1000000Elements that stay, e.g. Header / Footer / Nav / Sidebar
space--value-z-index-layer-overlay2000000Overlays such as Modals

Always use calc() (even when the right operand is 0)

Always write z-index in the form calc(layer-variable + number). Do not omit the right operand even when it is 0.

css
.modal {
z-index: calc(var(--value-z-index-layer-overlay) + 0); /* ✅ */
}
css
z-index: calc(var(--value-z-index-layer-staying) + 0); /* ✅ */
z-index: var(--value-z-index-layer-staying); /* ❌ */

Here we liken this notation to "chapter and verse". The chapter is which layer an element belongs to (the layer variable), and the verse is its ordering within that chapter (the right operand).

  • Chapter:

`` var(--value-z-index-layer-content) var(--value-z-index-layer-staying) var(--value-z-index-layer-overlay) ``

  • Verse:

```

  • 0
  • 1
  • 2

```

Always keeping the same notation shows later workers how to use --value-z-index-layer-* — that is, the convention itself. The existing styles become the example, so whoever writes z-index next can follow the same shape without hesitation. As a secondary benefit, it also keeps diffs small when making changes.

Within the same layer, stack in steps of 1000

When you want elements within the same layer to stack over one another, increase the right operand (the verse) of calc() in steps of thousands. When writing the verse, always keep the thousands place in mind: leave room by writing + 0, + 1000, + 2000. Even when you write + 0, read that 0 not as the ones place but as "a thousands place still left open".

css
.header {
z-index: calc(var(--value-z-index-layer-staying) + 0);
}
.sidebar {
z-index: calc(var(--value-z-index-layer-staying) + 1000);
}
.more-bar {
z-index: calc(var(--value-z-index-layer-staying) + 2000);
}

Reason: when you later need to insert an element between two levels, it is easier to insert between 1000 and 2000 than between 1 and 2.

Security

  • Security scanPassed, 100 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
5

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/openreachtech/hora-skills-ort-furo/hof-css-z-index/badge)](https://verified-skill.com/skills/openreachtech/hora-skills-ort-furo/hof-css-z-index)

Something wrong with this skill or its page? Tell us.