Skip to content

GkBottomSheet

A bottom sheet built on GkOverlay: v-model, scrim, Escape / scrim dismiss (unless persistent), transitionName="gk-bottom-sheet" (scrim fades, panel slides up), full-width surface with top-rounded corners, and optional inset padding from the viewport edges.

This is intentionally smaller than Vuetify’s VBottomSheet: no VDialog prop proxy beyond what GkOverlay already provides, no separate contentClass merge API — use attributes on the root or extend styles via tokens.

When to use

Use for bottom-anchored mobile-first action surfaces, short task pickers, or contextual actions that should not fully block page context.

Live demo

API

Props

PropTypeDefaultDescription
modelValuebooleanfalseOpen state; use v-model
insetbooleanfalseAdds horizontal padding around the sheet (see gk-overlay--inset on GkOverlay)
scrollablebooleantrueoverflow-y: auto on the surface when content exceeds max-height
persistentbooleanfalsePassed to GkOverlay
tostring | HTMLElement'body'Teleport target
zIndexnumber | string--gk-bottom-sheet-z-indexStack order
showScrimbooleantruePassed to GkOverlay
restoreFocusbooleantruePassed to GkOverlay
maxHeightstring | numberOptional surface max-height (numbers become px)

Additional attributes (aria-labelledby, aria-describedby, etc.) are forwarded to GkOverlay (panel element).

Slots

SlotDescription
defaultSheet body

Events

EventPayloadDescription
update:modelValuebooleanOpen state
click:outsideMouseEventScrim click (GkOverlay)
afterEnterTransition finished entering
afterLeaveTransition finished leaving

Tokens

TokenPurpose
--gk-bottom-sheet-z-indexDefault stacking (2400)
--gk-bottom-sheet-max-heightDefault max-height on the surface (90vh)
--gk-bottom-sheet-shadowPanel shadow

Examples

Basic

vue
<script setup lang="ts">
import { ref } from 'vue'
import { GkButton, GkBottomSheet } from 'god-kit/vue'
</script>

<template>
  <GkButton type="button" @click="open = true">Open sheet</GkButton>
  <GkBottomSheet v-model="open" aria-labelledby="sheet-title" inset>
    <h2 id="sheet-title">Actions</h2>
    <GkButton type="button" variant="secondary" @click="open = false">Close</GkButton>
  </GkBottomSheet>
</template>

Advanced

vue
<GkBottomSheet
  v-model="open"
  inset
  scrollable
  :max-height="560"
/>

Edge case

vue
<GkBottomSheet
  v-model="open"
  persistent
  :show-scrim="false"
/>

Accessibility notes

  • Provide aria-labelledby for sheet title regions.
  • Keep a clear close action when using persistent.
  • For long content, prefer scrollable to keep controls reachable on small screens.

Out of scope (v1)

Activator slot, VDialog-style prop filtering, router back, and global overlay stack.

Released under the MIT License.