HomePluginsToolsWorkflowAboutContact
GetSet

Premium UI/UX layout engines, customizable micro-interaction plugins, and high-performance components for modern web developers.

Plugins

  • Carousel
  • Select
  • Zoom
  • FlexoGrid
  • Sortable
  • Modal
  • Drawer
  • Tooltip
  • Popover
  • Toast
  • ContextMenu
  • Tabs
  • Accordion
  • Reveal
  • Autocomplete
  • Tags
  • Range
  • DatePicker
  • Upload
  • Cropper
  • Table
  • Tree
  • Editor

Company

  • Home
  • Plugins
  • Developer Tools
  • Showcase
  • Our Process
  • About Us
  • Contact

Policies

  • Terms and Conditions
  • Privacy Policy
  • Accessibility Policy
  • Cookie Policy

© 2026 GetSet. All rights reserved.

Crafted for frontend excellence.

Your Bundle

Your bundle is empty

Add plugins from the catalog to build one combined CDN link — like picking font families.

Browse plugins
Overlay Plugin

GS Drawer

Off-canvas drawer for all four edges with a backdrop layer catalog, push-content mode, swipe-to-close, and focus management.

Latest: v1.0.2
Downloads last month: 170
Visit Demo Website

Install Package

npm i @get-set/gs-drawer
or via CDN
<link rel="stylesheet" href="https://cdn.get-set.it/gs-drawer/latest/gs-drawer.min.css">
<script src="https://cdn.get-set.it/gs-drawer/latest/gs-drawer.min.js"></script>
Interactive Playground

Live Sandbox

Drawer.jsx
1
2
3
4
5
6
7
8
9
import Drawer from '@get-set/gs-drawer';

export default function App() {
  return (
    <Drawer>
      <div className="content">Your Drawer content</div>
    </Drawer>
  );
}
Live Preview

This drawer is a real GSDrawer instance running your current option set.

Tip Change Side / Animation / Backdrop options below, then reopen.

Options

Configuration Values

Reference?Reference option.
Side?Which edge the drawer is anchored to and slides from.
Size?Size preset (width for left/right, height for top/bottom).
Width?Explicit width (overrides `size` for left/right drawers).
Height?Explicit height (overrides `size` for top/bottom drawers).
Push Selector?Element(s) to translate when `pushContent` is on.
Swipe Threshold?Fraction of the panel size (0–1) past which releasing a swipe closes the drawer (otherwise it snaps back open).
Backdrop Type?Rich backdrop layer catalog preset.
Backdrop Color?Overlay color. Default: rgba(17,24,39,.5).
Backdrop Opacity?Overlay opacity (0–1).
Backdrop Blur?Backdrop blur. `true`=8px; number=px; string=raw CSS length.
Animation?Entrance animation name from the catalog.
Exit Animation?Separate exit animation name.
Animation Duration?Animation duration in ms.
Animation Easing?CSS easing applied to the panel enter/exit animation.
Backdrop Animation?Backdrop's own animation (independent of the panel).
Backdrop Animation Duration?Backdrop fade duration in ms.
Title?Optional header title.
Subtitle?Secondary line shown under the title in the header.
Footer?Footer area content (HTML string).
Close Button Position?Where the × close button sits (RTL-aware).
Initial Focus?Explicit element to focus on open.
Theme?Visual theme. `auto` follows prefers-color-scheme.
Accent Color?Accent color for the focus ring / handle / close button (CSS var --gsd-accent).
Class Name?Extra class name applied to the overlay root.
Trigger?Element(s) that open the drawer on click.
Close Handler?Element(s) inside the content that close the drawer on click.

Feature Flags

API Specifications

OptionTypeDefaultDescription
referencestringnoneReference.
sideDrawerSide'left'Which edge the drawer is anchored to and slides from. Default: 'left'.
sizeDrawerSize'md'Size preset (width for left/right, height for top/bottom). Default: 'md'.
widthnumber | stringnoneExplicit width (overrides `size` for left/right drawers). Number = px.
heightnumber | stringnoneExplicit height (overrides `size` for top/bottom drawers). Number = px.
closeOnBackdropbooleantrueClose when the backdrop (area outside the panel) is clicked. Default: true.
closeOnEscbooleantrueClose when Escape is pressed (topmost drawer only). Default: true.
persistentbooleanfalseNon-dismissable mode: backdrop click, Esc and the × close button no longer dismiss the drawer (only programmatic close()/closeDrawer()). Default: false.
pushContentbooleanfalsePush the page content aside instead of overlaying it. The tagged `pushSelector` element (default `<body>`'s first non-drawer content) is translated by the panel size while the drawer is open. Default: false.
pushSelectorHandlerTargetnoneElement(s) to translate when `pushContent` is on. Default: document.body.
swipeToClosebooleanfalseEnable edge-drag / swipe-to-close on the panel. Default: false.
swipeThresholdnumber0.4Fraction of the panel size (0–1) past which releasing a swipe closes the drawer (otherwise it snaps back open). Default: 0.4.
backdropboolean | 'static'trueBackdrop mode. `true` = dimmed, click-to-close. `false` = no overlay. `'static'` = overlay present but click does not close (plays a shake).
backdropTypeGSDrawerBackdropType'dim'Rich backdrop layer catalog preset. Default: 'dim'.
backdropColorstringnoneOverlay color. Default: rgba(17,24,39,.5).
backdropOpacitynumbernoneOverlay opacity (0–1). Applied as the overlay's alpha.
backdropBlurboolean | number | stringfalseBackdrop blur. `true`=8px; number=px; string=raw CSS length. Default: false.
animationGSDrawerAnimation | false'slide'Entrance animation name from the catalog. `false` disables all panel motion. Default: 'slide'.
exitAnimationGSDrawerAnimation | falsenoneSeparate exit animation name. Defaults to mirroring `animation` when omitted. `false` disables exit motion.
animationDurationnumber | { enter?: number; exit?: number }320Animation duration in ms. A number applies to both enter and exit; an object sets each independently. Default: 320.
animationEasingstring'cubic-bezier(.32,.72,0,1)'CSS easing applied to the panel enter/exit animation.
backdropAnimationGSDrawerAnimation | false'fade'Backdrop's own animation (independent of the panel). Default: 'fade'.
backdropAnimationDurationnumber240Backdrop fade duration in ms. Default: 240.
reducedMotion'auto' | boolean'auto'Honor `prefers-reduced-motion`. `'auto'` follows the OS setting; `true` always reduces; `false` never reduces. Default: 'auto'.
titlestringnoneOptional header title. When set, renders a header and wires aria-labelledby.
subtitlestringnoneSecondary line shown under the title in the header.
footerstring | falsenoneFooter area content (HTML string). `false` (default) = no footer.
showClosebooleantrueShow the built-in × close button. Default: true.
closeButtonPositionCloseButtonPosition'top-end'Where the × close button sits (RTL-aware). Default: 'top-end'.
scrollablebooleantrueBody scrolls independently; header & footer stay pinned. Default: true.
stickyHeaderbooleantruePin the header while the body scrolls (requires `scrollable`). Default: true.
stickyFooterbooleantruePin the footer while the body scrolls (requires `scrollable`). Default: true.
lockScrollbooleantrueLock `<body>` scroll while the drawer is open. Combine with `scrollbarPadding` to avoid layout shift. Default: true.
scrollbarPaddingbooleantrueCompensate for the scrollbar width on `<body>` while locking scroll, so the page does not shift when the scrollbar disappears. Default: true.
autofocusbooleantrueAuto-focus the first focusable element (or `[autofocus]`) on open. Default: true.
initialFocusHandlerTarget | falsenoneExplicit element to focus on open. `false` focuses the panel container.
disableFocusbooleanfalseSkip auto-focus entirely. Default: false.
returnFocusbooleantrueRestore focus to the previously focused element on close. Default: true.
themeGSDrawerTheme'auto'Visual theme. `auto` follows prefers-color-scheme. Default: 'auto'.
accentColorstringnoneAccent color for the focus ring / handle / close button (CSS var --gsd-accent).
rtlbooleanfalseRight-to-left layout. Default: false.
customClassGSDrawerCustomClassnonePer-part class overrides.
classNamestringnoneExtra class name applied to the overlay root.
triggerHandlerTargetnoneElement(s) that open the drawer on click. selector | HTMLElement | React ref.
closeHandlerHandlerTargetnoneElement(s) inside the content that close the drawer on click. selector | HTMLElement | React ref.

Technical Features

Four Edges

Slide in from left, right, top or bottom.

Push Content

Optionally shove the page instead of overlaying it.

Swipe To Close

Touch drag dismissal with velocity tracking.

Backdrop Layers

Dim, blur and glass backdrop variants.