nuxt-overlay-slot

nuxt-overlay-slot is a cursor rule for Cursor from YuDefine/nuxt-supabase-starter. It costs 0 tokens per session (1,294 once invoked), scanned A, original, MIT.

A Nuxt UI rule for placing the contents of slideovers, modals, and drawers in the correct body slot and setting their width through the component's UI settings. Titles and descriptions must be provided through their dedicated props or slots.

In plain words
What is it for?
It helps implement scrollable dialogs, side panels, and drawers with correctly placed body content, headers, descriptions, footers, and custom widths.
Why use it?
Putting content in the wrong slot can prevent long overlay content from scrolling and can leave an empty header taking up space. The rule keeps overlay layout and behavior predictable.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/. Also seen: mentions Codex.

Good fit It helps implement scrollable dialogs, side panels, and drawers with correctly placed body content, headers, descriptions, footers, and custom widths.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/yudefine/nuxt-supabase-starter/nuxt-overlay-slot
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.

Clone the repo
git clone --depth 1 https://github.com/YuDefine/nuxt-supabase-starter

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 nuxt-overlay-slot

README.md
[![agentmods](https://agentmods.dev/badge/rules/yudefine/nuxt-supabase-starter/nuxt-overlay-slot/github.svg)](https://agentmods.dev/rules/yudefine/nuxt-supabase-starter/nuxt-overlay-slot)
Your own site
<a href="https://agentmods.dev/rules/yudefine/nuxt-supabase-starter/nuxt-overlay-slot"><img src="https://agentmods.dev/badge/rules/yudefine/nuxt-supabase-starter/nuxt-overlay-slot/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 nuxt-overlay-slot

Your own site · 80×15
<a href="https://agentmods.dev/rules/yudefine/nuxt-supabase-starter/nuxt-overlay-slot"><img src="https://agentmods.dev/badge/rules/yudefine/nuxt-supabase-starter/nuxt-overlay-slot.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 1,294 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.
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.00000 $0.01294
Opus 5 $0.00000 $0.00647
Sonnet 5 $0.00000 $0.00259
Haiku 4.5 $0.00000 $0.00129

Measured yesterday against content hash 4139dd5cedcf, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

nuxt-overlay-slot 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 yesterday.

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.

template/.cursor/rules/nuxt-overlay-slot.mdc · 89 lines

How it starts

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

Overlay 元件 slot 與寬度規約

#body slot(MUST)

Nuxt UI v3 的 USlideover / UModal / UDrawer default slot 語意是 trigger(開啟 overlay 的按鈕),#body slot 才有內建 overflow-y-auto

body 內容放 default slot → 超出 viewport 高度時無法捲動

<!-- ✅ 正確:controlled mode,body 在 #body slot -->
<USlideover :open="open" title="校正資料" @update:open="emit('update:open', $event)">
  <template #body>
    <div class="space-y-4">...</div>
  </template>
  <template #footer>
    <div class="flex justify-end gap-3">...</div>
  </template>
</USlideover>

NEVER 把 body 內容放 default slot(即非 <template #body> / <template #content> 包裹的直接子元素)。

標題走 props,不進 body(MUST)

每一個#bodyUModal / USlideover / UDrawer,標題與副標 MUSTtitle / description prop(或 #title / #description slot)承載——不是只有新寫的那個,既有檔案改到時一併補。

close prop 預設 true,header 的 v-if 條件含 props.close,所以 header 一定會渲染;而 title/description 的 wrapper 只認 props.title / props.description。兩者皆缺時的實際結果:

  • header 塌成一條只有 X 的空白帶,且 theme headermin-h-(--ui-header-height)空的也佔固定高度
  • theme contentdivide-y,那條空白帶下方還會畫出分隔線 → 看起來像巢狀 card
  • <DialogTitle /> 渲染為空 → dialog 沒有 accessible name
<!-- ✅ 正確 -->
<UModal :title="editing ? '編輯假別' : '新增假別'" :description="editing ? '修改假別設定' : '建立新的請假類型'">
  <template #body>
    <UForm class="flex flex-col gap-4" :schema="schema" :state="state">…</UForm>
  </template>
</UModal>

<!-- ❌ 空 header + 標題錯位 + 無 accessible name -->
<UModal>
  <template #body>
    <UForm class="flex flex-col gap-4 p-6" :schema="schema" :state="state">
      <div class="flex flex-col gap-1">
        <h3 class="text-base font-semibold">新增假別</h3>
        <p class="text-sm text-muted">建立新的請假類型</p>
      </div>
      …

body wrapper 元件(AppFormLayout 這類自帶 title prop 的)同受此約束:title 給外層 overlay,不給 body 內的 wrapper,否則同樣是空 header + 標題掉進 body。

Read the full file on GitHub · 89 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. yesterday Changed · +1 lines 4139dd5cedcf
  2. 5d ago First seen · 88 lines · 0 tokens per session scan A dbf15399c028

Subscribe to this mod's changes

nuxt-overlay-slot is a cursor rule published in the GitHub repository YuDefine/nuxt-supabase-starter (45 stars, last pushed today), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,294 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-09-03.