
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
@gentleduck/primitives
Advanced tools
Unstyled, accessibility-first UI primitives for React.
Root, Trigger, Content, and friends to build exactly the UI you need without prop drilling.asChild pattern, same data-state attributes. Migration from Radix is a namespace change in your imports.| Primitive | Description |
|---|---|
alert-dialog | Modal dialog that requires user acknowledgment |
arrow | Positioning arrow for floating elements |
avatar | User avatar with image and fallback support |
calendar | Date grid with keyboard navigation and multi-view support |
checkers | Checkbox and switch toggle primitive |
command | Command palette with search filtering |
context-menu | Right-click context menu with submenus |
dialog | Modal and non-modal dialog windows |
direction | RTL/LTR direction provider |
dismissable-layer | Layer that dismisses on outside interaction |
dropdown-menu | Dropdown menu with submenus, checkboxes, and radio items |
focus-scope | Traps and manages focus within a boundary |
hover-card | Card triggered by hover with open/close delay |
input-otp | One-time password input with slots and separators |
menu | Base menu primitive used by dropdown, context, and menubar |
menubar | Horizontal menu bar with keyboard navigation |
mount | Deferred mounting with lifecycle callbacks |
navigation-menu | Site navigation with animated indicator and viewport |
pagination | Page navigation controls |
popover | Floating content anchored to a trigger |
popper | Low-level floating element positioning via Floating UI |
portal | Renders children into a DOM portal |
presence | Animate mount/unmount transitions |
primitive-elements | Base Primitive element factory (asChild support) |
progress | Determinate and indeterminate progress indicator |
radio-group | Radio button group with roving focus |
roving-focus | Roving tabindex focus management for groups |
select | Listbox-style select with typeahead and scroll buttons |
sheet | Slide-out panel (re-exports dialog internals) |
slider | Range slider with single or multiple thumbs |
slot | Merges props and ref onto a child element (asChild engine) |
toggle | Two-state toggle button |
toggle-group | Single or multi-select group of toggles |
tooltip | Accessible tooltip with provider-level delay |
visibility-hidden | Visually hidden element for screen readers |
npm install @gentleduck/primitives
import * as Dialog from '@gentleduck/primitives/dialog'
function Demo() {
return (
<Dialog.Root>
<Dialog.Trigger>Open</Dialog.Trigger>
<Dialog.Portal>
<Dialog.Overlay />
<Dialog.Content>
<Dialog.Title>Heading</Dialog.Title>
<Dialog.Description>Body text here.</Dialog.Description>
<Dialog.Close>Close</Dialog.Close>
</Dialog.Content>
</Dialog.Portal>
</Dialog.Root>
)
}
asChild / Slot - render any primitive as your own element via the asChild prop, powered by the Slot utility.createContextScope - scoped React context factory that prevents cross-instance state leaks.forwardRef everywhere - every component forwards refs for imperative access and composition.data-slot attributes - every component root emits a data-slot for style targeting without class names.Presence primitive lets you animate enter/exit transitions before unmounting.FocusScope locks focus inside modals, dialogs, and popovers with configurable loop behavior.DismissableLayer handles outside clicks, Escape key, and nested layer stacking.gentleduck.org/docs/packages/duck-primitives
FAQs
Unstyled, accessibility-first UI primitives for React.
The npm package @gentleduck/primitives receives a total of 356 weekly downloads. As such, @gentleduck/primitives popularity was classified as not popular.
We found that @gentleduck/primitives demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.