snapshot of https://github.com/shadcn-ui/ui.git (main, 2026-09-15; blobs > 131072B omitted)
This commit is contained in:
24
apps/v4/content/docs/changelog/2026-04-pointer-cursor.mdx
Normal file
24
apps/v4/content/docs/changelog/2026-04-pointer-cursor.mdx
Normal file
@@ -0,0 +1,24 @@
|
||||
---
|
||||
title: April 2026 - Pointer Cursor
|
||||
description: Add cursor pointer behavior for buttons during project setup.
|
||||
date: 2026-04-25
|
||||
---
|
||||
|
||||
You can now enable `cursor: pointer` for buttons when initializing a project.
|
||||
|
||||
```bash
|
||||
npx shadcn@latest init --pointer
|
||||
```
|
||||
|
||||
This adds the following CSS to your global CSS file:
|
||||
|
||||
```css title="globals.css"
|
||||
@layer base {
|
||||
button:not(:disabled),
|
||||
[role="button"]:not(:disabled) {
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
The `--pointer` option is not part of preset codes. It is applied as a project setup option, similar to `--rtl`.
|
||||
Reference in New Issue
Block a user