sheerly 0.0.2 → 0.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +48 -0
- package/lib/accordion.css +1 -1
- package/lib/accordion.d.ts +2 -2
- package/lib/alert.css +1 -1
- package/lib/alert.d.ts +4 -4
- package/lib/avatar.css +1 -1
- package/lib/avatar.d.ts +4 -4
- package/lib/badge.css +1 -1
- package/lib/badge.d.ts +1 -1
- package/lib/breadcrumb.css +1 -1
- package/lib/breadcrumb.d.ts +34 -8
- package/lib/button.css +1 -1
- package/lib/button.d.ts +1 -1
- package/lib/card.css +1 -1
- package/lib/card.d.ts +7 -7
- package/lib/carousel.d.ts +2 -2
- package/lib/checkbox.d.ts +1 -1
- package/lib/dialog.css +1 -1
- package/lib/dialog.d.ts +7 -7
- package/lib/dropdown-menu.css +1 -1
- package/lib/dropdown-menu.d.ts +20 -15
- package/lib/hover-card.css +1 -1
- package/lib/hover-card.d.ts +2 -2
- package/lib/index.css +1 -1
- package/lib/index.js +95 -95
- package/lib/input.css +1 -1
- package/lib/input.d.ts +1 -1
- package/lib/kbd.css +1 -1
- package/lib/kbd.d.ts +2 -2
- package/lib/label.css +1 -1
- package/lib/label.d.ts +1 -1
- package/lib/pagination.css +1 -1
- package/lib/pagination.d.ts +38 -13
- package/lib/popover.css +1 -1
- package/lib/popover.d.ts +2 -2
- package/lib/progress.d.ts +1 -1
- package/lib/radio.d.ts +2 -2
- package/lib/root.css +1 -1
- package/lib/root.terminal.css +1 -0
- package/lib/scrollbar.d.ts +1 -1
- package/lib/select.css +1 -1
- package/lib/select.d.ts +1 -1
- package/lib/separator.d.ts +1 -1
- package/lib/sheet.css +1 -1
- package/lib/sheet.d.ts +7 -7
- package/lib/skeleton.d.ts +1 -1
- package/lib/slider.d.ts +1 -1
- package/lib/spinner.d.ts +1 -1
- package/lib/switch.d.ts +1 -1
- package/lib/table.css +1 -1
- package/lib/table.d.ts +2 -2
- package/lib/tabs.css +1 -1
- package/lib/tabs.d.ts +10 -7
- package/lib/textarea.css +1 -1
- package/lib/textarea.d.ts +1 -1
- package/lib/toggle.css +1 -1
- package/lib/toggle.d.ts +1 -1
- package/lib/tooltip.css +1 -1
- package/lib/tooltip.d.ts +2 -2
- package/lib/typography.css +1 -1
- package/lib/typography.d.ts +1 -1
- package/package.json +17 -15
- package/src/accordion.css +2 -2
- package/src/alert.css +1 -1
- package/src/avatar.css +1 -1
- package/src/badge.css +1 -1
- package/src/breadcrumb.css +1 -1
- package/src/breadcrumb.tsx +67 -20
- package/src/button.css +1 -1
- package/src/card.css +2 -2
- package/src/dialog.css +2 -2
- package/src/dropdown-menu.css +1 -1
- package/src/dropdown-menu.tsx +21 -8
- package/src/hover-card.css +1 -1
- package/src/input.css +1 -1
- package/src/kbd.css +1 -1
- package/src/label.css +1 -1
- package/src/pagination.css +1 -1
- package/src/pagination.tsx +85 -26
- package/src/popover.css +1 -1
- package/src/root.css +6 -0
- package/src/root.terminal.css +77 -0
- package/src/select.css +1 -1
- package/src/sheet.css +2 -2
- package/src/table.css +1 -1
- package/src/tabs.css +1 -1
- package/src/tabs.tsx +16 -9
- package/src/textarea.css +1 -1
- package/src/toggle.css +1 -1
- package/src/tooltip.css +1 -1
- package/src/typography.css +2 -2
package/src/dropdown-menu.tsx
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ButtonHTMLAttributes, ElementType } from 'react'
|
|
2
2
|
import { cn } from './utils/cn'
|
|
3
3
|
import type { PolymorphicProps } from './utils/polymorphic'
|
|
4
4
|
|
|
@@ -78,14 +78,27 @@ export function DropdownMenuItem({ className, type = 'button', ...props }: Dropd
|
|
|
78
78
|
return <button type={type} className={cn('sheerly-dropdown-menu-item', className)} {...props} />
|
|
79
79
|
}
|
|
80
80
|
|
|
81
|
-
/**
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
}
|
|
81
|
+
/**
|
|
82
|
+
* An interactive menu row rendered as a link.
|
|
83
|
+
*
|
|
84
|
+
* Polymorphic: pass `as` to change the rendered tag (defaults to `a`, e.g.
|
|
85
|
+
* `as={Link}` for a router link).
|
|
86
|
+
*/
|
|
87
|
+
export type DropdownMenuLinkItemProps<T extends ElementType = 'a'> = PolymorphicProps<
|
|
88
|
+
T,
|
|
89
|
+
{
|
|
90
|
+
'data-variant'?: 'destructive'
|
|
91
|
+
'data-inset'?: boolean
|
|
92
|
+
}
|
|
93
|
+
>
|
|
86
94
|
|
|
87
|
-
export function DropdownMenuLinkItem
|
|
88
|
-
|
|
95
|
+
export function DropdownMenuLinkItem<T extends ElementType = 'a'>({
|
|
96
|
+
as,
|
|
97
|
+
className,
|
|
98
|
+
...props
|
|
99
|
+
}: DropdownMenuLinkItemProps<T>) {
|
|
100
|
+
const Tag = as ?? 'a'
|
|
101
|
+
return <Tag className={cn('sheerly-dropdown-menu-item', className)} {...props} />
|
|
89
102
|
}
|
|
90
103
|
|
|
91
104
|
/** A trailing keyboard-shortcut hint inside an item. */
|
package/src/hover-card.css
CHANGED
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
/* Neutral card-like surface */
|
|
48
48
|
background-color: var(--sheerly-popover);
|
|
49
49
|
color: var(--sheerly-popover-foreground);
|
|
50
|
-
font-family:
|
|
50
|
+
font-family: var(--sheerly-font-sans);
|
|
51
51
|
font-size: 14px;
|
|
52
52
|
line-height: 20px;
|
|
53
53
|
width: max-content;
|
package/src/input.css
CHANGED
package/src/kbd.css
CHANGED
package/src/label.css
CHANGED
package/src/pagination.css
CHANGED
package/src/pagination.tsx
CHANGED
|
@@ -1,10 +1,14 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ElementType } from 'react'
|
|
2
2
|
import { cn } from './utils/cn'
|
|
3
3
|
import type { PolymorphicProps } from './utils/polymorphic'
|
|
4
4
|
|
|
5
|
+
export type PaginationProps<T extends ElementType = 'nav'> = PolymorphicProps<T>
|
|
6
|
+
|
|
5
7
|
/**
|
|
6
8
|
* Page navigation. Mark the current page's link with `isActive`.
|
|
7
9
|
*
|
|
10
|
+
* Polymorphic: pass `as` to change the rendered tag (defaults to `nav`).
|
|
11
|
+
*
|
|
8
12
|
* @example
|
|
9
13
|
* <Pagination>
|
|
10
14
|
* <PaginationContent>
|
|
@@ -14,9 +18,14 @@ import type { PolymorphicProps } from './utils/polymorphic'
|
|
|
14
18
|
* </PaginationContent>
|
|
15
19
|
* </Pagination>
|
|
16
20
|
*/
|
|
17
|
-
export function Pagination
|
|
21
|
+
export function Pagination<T extends ElementType = 'nav'>({
|
|
22
|
+
as,
|
|
23
|
+
className,
|
|
24
|
+
...props
|
|
25
|
+
}: PaginationProps<T>) {
|
|
26
|
+
const Tag = as ?? 'nav'
|
|
18
27
|
return (
|
|
19
|
-
<
|
|
28
|
+
<Tag
|
|
20
29
|
role="navigation"
|
|
21
30
|
aria-label="pagination"
|
|
22
31
|
className={cn('sheerly-pagination', className)}
|
|
@@ -25,30 +34,56 @@ export function Pagination({ className, ...props }: HTMLAttributes<HTMLElement>)
|
|
|
25
34
|
)
|
|
26
35
|
}
|
|
27
36
|
|
|
28
|
-
export
|
|
37
|
+
export type PaginationContentProps<T extends ElementType = 'ul'> = PolymorphicProps<T>
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* Polymorphic: pass `as` to change the rendered tag (defaults to `ul`).
|
|
41
|
+
*/
|
|
42
|
+
export function PaginationContent<T extends ElementType = 'ul'>({
|
|
43
|
+
as,
|
|
29
44
|
className,
|
|
30
45
|
...props
|
|
31
|
-
}:
|
|
32
|
-
|
|
46
|
+
}: PaginationContentProps<T>) {
|
|
47
|
+
const Tag = as ?? 'ul'
|
|
48
|
+
return <Tag className={cn('sheerly-pagination-content', className)} {...props} />
|
|
33
49
|
}
|
|
34
50
|
|
|
35
|
-
export
|
|
36
|
-
return <li className={cn('sheerly-pagination-item', className)} {...props} />
|
|
37
|
-
}
|
|
51
|
+
export type PaginationItemProps<T extends ElementType = 'li'> = PolymorphicProps<T>
|
|
38
52
|
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
53
|
+
/**
|
|
54
|
+
* Polymorphic: pass `as` to change the rendered tag (defaults to `li`).
|
|
55
|
+
*/
|
|
56
|
+
export function PaginationItem<T extends ElementType = 'li'>({
|
|
57
|
+
as,
|
|
58
|
+
className,
|
|
59
|
+
...props
|
|
60
|
+
}: PaginationItemProps<T>) {
|
|
61
|
+
const Tag = as ?? 'li'
|
|
62
|
+
return <Tag className={cn('sheerly-pagination-item', className)} {...props} />
|
|
43
63
|
}
|
|
44
64
|
|
|
45
|
-
export
|
|
65
|
+
export type PaginationLinkProps<T extends ElementType = 'a'> = PolymorphicProps<
|
|
66
|
+
T,
|
|
67
|
+
{
|
|
68
|
+
/** Marks the current page (renders like the outline button). */
|
|
69
|
+
isActive?: boolean
|
|
70
|
+
'data-role'?: 'previous' | 'next'
|
|
71
|
+
}
|
|
72
|
+
>
|
|
73
|
+
|
|
74
|
+
/**
|
|
75
|
+
* Polymorphic: pass `as` to change the rendered tag (defaults to `a`, e.g.
|
|
76
|
+
* `as={Link}` for a router link).
|
|
77
|
+
*/
|
|
78
|
+
export function PaginationLink<T extends ElementType = 'a'>({
|
|
79
|
+
as,
|
|
46
80
|
className,
|
|
47
81
|
isActive,
|
|
48
82
|
...props
|
|
49
|
-
}: PaginationLinkProps) {
|
|
83
|
+
}: PaginationLinkProps<T>) {
|
|
84
|
+
const Tag = as ?? 'a'
|
|
50
85
|
return (
|
|
51
|
-
<
|
|
86
|
+
<Tag
|
|
52
87
|
aria-current={isActive ? 'page' : undefined}
|
|
53
88
|
className={cn('sheerly-pagination-link', className)}
|
|
54
89
|
{...props}
|
|
@@ -56,44 +91,68 @@ export function PaginationLink({
|
|
|
56
91
|
)
|
|
57
92
|
}
|
|
58
93
|
|
|
59
|
-
export
|
|
94
|
+
export type PaginationPreviousProps<T extends ElementType = 'a'> = PaginationLinkProps<T> & {
|
|
95
|
+
/** Visible label. Children override it. */
|
|
96
|
+
text?: string
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
/**
|
|
100
|
+
* Polymorphic: pass `as` to change the rendered tag (defaults to `a`).
|
|
101
|
+
*/
|
|
102
|
+
export function PaginationPrevious<T extends ElementType = 'a'>({
|
|
103
|
+
as,
|
|
60
104
|
className,
|
|
105
|
+
isActive,
|
|
61
106
|
text = 'Previous',
|
|
62
107
|
children,
|
|
63
108
|
...props
|
|
64
|
-
}:
|
|
109
|
+
}: PaginationPreviousProps<T>) {
|
|
110
|
+
const Tag = as ?? 'a'
|
|
65
111
|
return (
|
|
66
|
-
<
|
|
112
|
+
<Tag
|
|
67
113
|
aria-label="Go to previous page"
|
|
114
|
+
aria-current={isActive ? 'page' : undefined}
|
|
68
115
|
data-role="previous"
|
|
69
|
-
className={className}
|
|
116
|
+
className={cn('sheerly-pagination-link', className)}
|
|
70
117
|
{...props}
|
|
71
118
|
>
|
|
72
119
|
{children ?? text}
|
|
73
|
-
</
|
|
120
|
+
</Tag>
|
|
74
121
|
)
|
|
75
122
|
}
|
|
76
123
|
|
|
77
|
-
export
|
|
124
|
+
export type PaginationNextProps<T extends ElementType = 'a'> = PaginationPreviousProps<T>
|
|
125
|
+
|
|
126
|
+
/**
|
|
127
|
+
* Polymorphic: pass `as` to change the rendered tag (defaults to `a`).
|
|
128
|
+
*/
|
|
129
|
+
export function PaginationNext<T extends ElementType = 'a'>({
|
|
130
|
+
as,
|
|
78
131
|
className,
|
|
132
|
+
isActive,
|
|
79
133
|
text = 'Next',
|
|
80
134
|
children,
|
|
81
135
|
...props
|
|
82
|
-
}:
|
|
136
|
+
}: PaginationNextProps<T>) {
|
|
137
|
+
const Tag = as ?? 'a'
|
|
83
138
|
return (
|
|
84
|
-
<
|
|
139
|
+
<Tag
|
|
85
140
|
aria-label="Go to next page"
|
|
141
|
+
aria-current={isActive ? 'page' : undefined}
|
|
86
142
|
data-role="next"
|
|
87
|
-
className={className}
|
|
143
|
+
className={cn('sheerly-pagination-link', className)}
|
|
88
144
|
{...props}
|
|
89
145
|
>
|
|
90
146
|
{children ?? text}
|
|
91
|
-
</
|
|
147
|
+
</Tag>
|
|
92
148
|
)
|
|
93
149
|
}
|
|
94
150
|
|
|
95
151
|
export type PaginationEllipsisProps<T extends ElementType = 'span'> = PolymorphicProps<T>
|
|
96
152
|
|
|
153
|
+
/**
|
|
154
|
+
* Polymorphic: pass `as` to change the rendered tag (defaults to `span`).
|
|
155
|
+
*/
|
|
97
156
|
export function PaginationEllipsis<T extends ElementType = 'span'>({
|
|
98
157
|
as,
|
|
99
158
|
className,
|
package/src/popover.css
CHANGED
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
/* Neutral popover surface */
|
|
38
38
|
background-color: var(--sheerly-popover);
|
|
39
39
|
color: var(--sheerly-popover-foreground);
|
|
40
|
-
font-family:
|
|
40
|
+
font-family: var(--sheerly-font-sans);
|
|
41
41
|
font-size: 14px;
|
|
42
42
|
line-height: 20px;
|
|
43
43
|
width: max-content;
|
package/src/root.css
CHANGED
|
@@ -1,4 +1,10 @@
|
|
|
1
|
+
/* @import url("https://fonts.googleapis.com/css2?family=Geist:wght@400;500;600&family=Geist+Mono:wght@400&display=swap"); */
|
|
2
|
+
|
|
1
3
|
:root {
|
|
4
|
+
/* Typography */
|
|
5
|
+
--sheerly-font-sans: "Geist", "Geist Sans", system-ui, -apple-system, sans-serif;
|
|
6
|
+
--sheerly-font-mono: "Geist Mono", ui-monospace, monospace;
|
|
7
|
+
|
|
2
8
|
/* Radius (Nova: 0.625rem base) */
|
|
3
9
|
--sheerly-radius: 0.625rem;
|
|
4
10
|
--sheerly-radius-sm: calc(var(--sheerly-radius) * 0.6);
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
/* Terminal theme — IBM Plex Mono everywhere, square corners, orange accent.
|
|
2
|
+
Theme override: import AFTER the base library so these tokens win.
|
|
3
|
+
@import "sheerly/index.css";
|
|
4
|
+
@import "sheerly/root.terminal.css"; */
|
|
5
|
+
|
|
6
|
+
/* @import url("https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500;600&display=swap"); */
|
|
7
|
+
|
|
8
|
+
:root {
|
|
9
|
+
/* Typography */
|
|
10
|
+
--sheerly-font-sans: "IBM Plex Mono", ui-monospace, monospace;
|
|
11
|
+
--sheerly-font-mono: "IBM Plex Mono", ui-monospace, monospace;
|
|
12
|
+
|
|
13
|
+
/* Radius (square) — derived radii scale to 0 automatically */
|
|
14
|
+
--sheerly-radius: 0rem;
|
|
15
|
+
|
|
16
|
+
/* Semantic colors (terminal light) */
|
|
17
|
+
--sheerly-background: oklch(0.9851 0 0);
|
|
18
|
+
--sheerly-foreground: oklch(0.1448 0 0);
|
|
19
|
+
--sheerly-card: oklch(0.9702 0 0);
|
|
20
|
+
--sheerly-card-foreground: oklch(0.1448 0 0);
|
|
21
|
+
--sheerly-popover: oklch(0.9851 0 0);
|
|
22
|
+
--sheerly-popover-foreground: oklch(0.1448 0 0);
|
|
23
|
+
--sheerly-primary: oklch(0.6996 0.202 44.4414);
|
|
24
|
+
--sheerly-primary-foreground: oklch(0 0 0);
|
|
25
|
+
--sheerly-secondary: oklch(0.9219 0 0);
|
|
26
|
+
--sheerly-secondary-foreground: oklch(0.1448 0 0);
|
|
27
|
+
--sheerly-muted: oklch(0.9401 0 0);
|
|
28
|
+
--sheerly-muted-foreground: oklch(0.4495 0 0);
|
|
29
|
+
--sheerly-accent: oklch(0.7512 0.168 52.0772);
|
|
30
|
+
--sheerly-accent-foreground: oklch(0 0 0);
|
|
31
|
+
--sheerly-destructive: oklch(0.628 0.2577 29.2339);
|
|
32
|
+
--sheerly-border: oklch(0.8514 0 0);
|
|
33
|
+
--sheerly-input: oklch(0.8514 0 0);
|
|
34
|
+
--sheerly-ring: oklch(0.6996 0.202 44.4414);
|
|
35
|
+
|
|
36
|
+
/* Sidebar */
|
|
37
|
+
--sheerly-sidebar: oklch(0.9851 0 0);
|
|
38
|
+
--sheerly-sidebar-foreground: oklch(0.1448 0 0);
|
|
39
|
+
--sheerly-sidebar-primary: oklch(0.2046 0 0);
|
|
40
|
+
--sheerly-sidebar-primary-foreground: oklch(0.9851 0 0);
|
|
41
|
+
--sheerly-sidebar-accent: oklch(0.9702 0 0);
|
|
42
|
+
--sheerly-sidebar-accent-foreground: oklch(0.2046 0 0);
|
|
43
|
+
--sheerly-sidebar-border: oklch(0.9219 0 0);
|
|
44
|
+
--sheerly-sidebar-ring: oklch(0.709 0 0);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.dark {
|
|
48
|
+
/* Semantic colors (terminal dark) */
|
|
49
|
+
--sheerly-background: oklch(0.1822 0 0);
|
|
50
|
+
--sheerly-foreground: oklch(0.9612 0 0);
|
|
51
|
+
--sheerly-card: oklch(0.2178 0 0);
|
|
52
|
+
--sheerly-card-foreground: oklch(0.9612 0 0);
|
|
53
|
+
--sheerly-popover: oklch(0.1822 0 0);
|
|
54
|
+
--sheerly-popover-foreground: oklch(0.9612 0 0);
|
|
55
|
+
--sheerly-primary: oklch(0.6996 0.202 44.4414);
|
|
56
|
+
--sheerly-primary-foreground: oklch(0 0 0);
|
|
57
|
+
--sheerly-secondary: oklch(0.3211 0 0);
|
|
58
|
+
--sheerly-secondary-foreground: oklch(0.9612 0 0);
|
|
59
|
+
--sheerly-muted: oklch(0.2686 0 0);
|
|
60
|
+
--sheerly-muted-foreground: oklch(0.7252 0 0);
|
|
61
|
+
--sheerly-accent: oklch(0.7512 0.168 52.0772);
|
|
62
|
+
--sheerly-accent-foreground: oklch(0 0 0);
|
|
63
|
+
--sheerly-destructive: oklch(0.628 0.2577 29.2339);
|
|
64
|
+
--sheerly-border: oklch(0.3715 0 0);
|
|
65
|
+
--sheerly-input: oklch(0.3715 0 0);
|
|
66
|
+
--sheerly-ring: oklch(0.6996 0.202 44.4414);
|
|
67
|
+
|
|
68
|
+
/* Sidebar */
|
|
69
|
+
--sheerly-sidebar: oklch(0.2046 0 0);
|
|
70
|
+
--sheerly-sidebar-foreground: oklch(0.9851 0 0);
|
|
71
|
+
--sheerly-sidebar-primary: oklch(0.4878 0.2432 264.4045);
|
|
72
|
+
--sheerly-sidebar-primary-foreground: oklch(0.9851 0 0);
|
|
73
|
+
--sheerly-sidebar-accent: oklch(0.2686 0 0);
|
|
74
|
+
--sheerly-sidebar-accent-foreground: oklch(0.9851 0 0);
|
|
75
|
+
--sheerly-sidebar-border: oklch(0.2768 0 0);
|
|
76
|
+
--sheerly-sidebar-ring: oklch(0.4386 0 0);
|
|
77
|
+
}
|
package/src/select.css
CHANGED
package/src/sheet.css
CHANGED
|
@@ -142,7 +142,7 @@
|
|
|
142
142
|
}
|
|
143
143
|
|
|
144
144
|
.sheerly-sheet-title {
|
|
145
|
-
font-family:
|
|
145
|
+
font-family: var(--sheerly-font-sans);
|
|
146
146
|
font-size: 16px;
|
|
147
147
|
font-weight: 500;
|
|
148
148
|
line-height: 1;
|
|
@@ -152,7 +152,7 @@
|
|
|
152
152
|
}
|
|
153
153
|
|
|
154
154
|
.sheerly-sheet-description {
|
|
155
|
-
font-family:
|
|
155
|
+
font-family: var(--sheerly-font-sans);
|
|
156
156
|
font-size: 14px;
|
|
157
157
|
font-weight: 400;
|
|
158
158
|
line-height: 20px;
|
package/src/table.css
CHANGED
package/src/tabs.css
CHANGED
package/src/tabs.tsx
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ElementType } from 'react'
|
|
2
2
|
import { cn } from './utils/cn'
|
|
3
3
|
import type { PolymorphicProps } from './utils/polymorphic'
|
|
4
4
|
|
|
@@ -46,14 +46,21 @@ export function TabsList<T extends ElementType = 'div'>({
|
|
|
46
46
|
return <Tag role="tablist" className={cn('sheerly-tabs-list', className)} {...props} />
|
|
47
47
|
}
|
|
48
48
|
|
|
49
|
-
export
|
|
50
|
-
|
|
51
|
-
}
|
|
49
|
+
export type TabsTriggerProps<T extends ElementType = 'button'> = PolymorphicProps<
|
|
50
|
+
T,
|
|
51
|
+
{ 'data-state'?: 'active' }
|
|
52
|
+
>
|
|
52
53
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
54
|
+
/**
|
|
55
|
+
* Polymorphic: pass `as` to change the rendered tag (defaults to `button`).
|
|
56
|
+
*/
|
|
57
|
+
export function TabsTrigger<T extends ElementType = 'button'>({
|
|
58
|
+
as,
|
|
59
|
+
className,
|
|
60
|
+
...props
|
|
61
|
+
}: TabsTriggerProps<T>) {
|
|
62
|
+
const Tag = as ?? 'button'
|
|
63
|
+
return <Tag role="tab" className={cn('sheerly-tabs-trigger', className)} {...props} />
|
|
57
64
|
}
|
|
58
65
|
|
|
59
66
|
export type TabsContentProps<T extends ElementType = 'div'> = PolymorphicProps<T>
|
|
@@ -68,4 +75,4 @@ export function TabsContent<T extends ElementType = 'div'>({
|
|
|
68
75
|
}: TabsContentProps<T>) {
|
|
69
76
|
const Tag = as ?? 'div'
|
|
70
77
|
return <Tag role="tabpanel" className={cn('sheerly-tabs-content', className)} {...props} />
|
|
71
|
-
}
|
|
78
|
+
}
|
package/src/textarea.css
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
border: 1px solid var(--sheerly-input);
|
|
8
8
|
background-color: transparent;
|
|
9
9
|
padding: 6px 10px;
|
|
10
|
-
font-family:
|
|
10
|
+
font-family: var(--sheerly-font-sans);
|
|
11
11
|
font-size: 14px;
|
|
12
12
|
font-weight: 400;
|
|
13
13
|
line-height: 20px;
|
package/src/toggle.css
CHANGED
package/src/tooltip.css
CHANGED
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
/* Visual style */
|
|
30
30
|
background-color: var(--sheerly-foreground);
|
|
31
31
|
color: var(--sheerly-background);
|
|
32
|
-
font-family:
|
|
32
|
+
font-family: var(--sheerly-font-sans);
|
|
33
33
|
font-size: 12px;
|
|
34
34
|
font-weight: 400;
|
|
35
35
|
line-height: 16px;
|
package/src/typography.css
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* element (h1–h4, p, a, blockquote, ul/ol, li, code, table, small, etc.).
|
|
6
6
|
* Follows the shadcn Nova typography scale. */
|
|
7
7
|
.sheerly-typography {
|
|
8
|
-
font-family:
|
|
8
|
+
font-family: var(--sheerly-font-sans);
|
|
9
9
|
color: var(--sheerly-foreground);
|
|
10
10
|
font-size: 16px;
|
|
11
11
|
line-height: 1.75;
|
|
@@ -110,7 +110,7 @@
|
|
|
110
110
|
}
|
|
111
111
|
|
|
112
112
|
& code {
|
|
113
|
-
font-family:
|
|
113
|
+
font-family: var(--sheerly-font-mono);
|
|
114
114
|
font-size: 0.875em;
|
|
115
115
|
font-weight: 600;
|
|
116
116
|
border-radius: var(--sheerly-radius-sm);
|