File tree 6 files changed +15
-15
lines changed
v4/registry/new-york-v4/ui
6 files changed +15
-15
lines changed Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ const SIDEBAR_WIDTH_MOBILE = "18rem"
32
32
const SIDEBAR_WIDTH_ICON = "3rem"
33
33
const SIDEBAR_KEYBOARD_SHORTCUT = "b"
34
34
35
- type SidebarContext = {
35
+ type SidebarContextProps = {
36
36
state : "expanded" | "collapsed"
37
37
open : boolean
38
38
setOpen : ( open : boolean ) => void
@@ -42,7 +42,7 @@ type SidebarContext = {
42
42
toggleSidebar : ( ) => void
43
43
}
44
44
45
- const SidebarContext = React . createContext < SidebarContext | null > ( null )
45
+ const SidebarContext = React . createContext < SidebarContextProps | null > ( null )
46
46
47
47
function useSidebar ( ) {
48
48
const context = React . useContext ( SidebarContext )
@@ -113,7 +113,7 @@ function SidebarProvider({
113
113
// This makes it easier to style the sidebar with Tailwind classes.
114
114
const state = open ? "expanded" : "collapsed"
115
115
116
- const contextValue = React . useMemo < SidebarContext > (
116
+ const contextValue = React . useMemo < SidebarContextProps > (
117
117
( ) => ( {
118
118
state,
119
119
open,
Load Diff Large diffs are not rendered by default.
Load Diff Large diffs are not rendered by default.
Load Diff Large diffs are not rendered by default.
Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ const SIDEBAR_WIDTH_MOBILE = "18rem"
32
32
const SIDEBAR_WIDTH_ICON = "3rem"
33
33
const SIDEBAR_KEYBOARD_SHORTCUT = "b"
34
34
35
- type SidebarContext = {
35
+ type SidebarContextProps = {
36
36
state : "expanded" | "collapsed"
37
37
open : boolean
38
38
setOpen : ( open : boolean ) => void
@@ -42,7 +42,7 @@ type SidebarContext = {
42
42
toggleSidebar : ( ) => void
43
43
}
44
44
45
- const SidebarContext = React . createContext < SidebarContext | null > ( null )
45
+ const SidebarContext = React . createContext < SidebarContextProps | null > ( null )
46
46
47
47
function useSidebar ( ) {
48
48
const context = React . useContext ( SidebarContext )
@@ -122,7 +122,7 @@ const SidebarProvider = React.forwardRef<
122
122
// This makes it easier to style the sidebar with Tailwind classes.
123
123
const state = open ? "expanded" : "collapsed"
124
124
125
- const contextValue = React . useMemo < SidebarContext > (
125
+ const contextValue = React . useMemo < SidebarContextProps > (
126
126
( ) => ( {
127
127
state,
128
128
open,
Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ const SIDEBAR_WIDTH_MOBILE = "18rem"
32
32
const SIDEBAR_WIDTH_ICON = "3rem"
33
33
const SIDEBAR_KEYBOARD_SHORTCUT = "b"
34
34
35
- type SidebarContext = {
35
+ type SidebarContextProps = {
36
36
state : "expanded" | "collapsed"
37
37
open : boolean
38
38
setOpen : ( open : boolean ) => void
@@ -42,7 +42,7 @@ type SidebarContext = {
42
42
toggleSidebar : ( ) => void
43
43
}
44
44
45
- const SidebarContext = React . createContext < SidebarContext | null > ( null )
45
+ const SidebarContext = React . createContext < SidebarContextProps | null > ( null )
46
46
47
47
function useSidebar ( ) {
48
48
const context = React . useContext ( SidebarContext )
@@ -122,7 +122,7 @@ const SidebarProvider = React.forwardRef<
122
122
// This makes it easier to style the sidebar with Tailwind classes.
123
123
const state = open ? "expanded" : "collapsed"
124
124
125
- const contextValue = React . useMemo < SidebarContext > (
125
+ const contextValue = React . useMemo < SidebarContextProps > (
126
126
( ) => ( {
127
127
state,
128
128
open,
You can’t perform that action at this time.
0 commit comments