File tree Expand file tree Collapse file tree 3 files changed +11
-7
lines changed
packages/documentation/src/components/DemoSandbox Expand file tree Collapse file tree 3 files changed +11
-7
lines changed Original file line number Diff line number Diff line change 1
1
@import ' ~@react-md/app-bar/dist/mixins' ;
2
+ @import ' ~@react-md/sheet/dist/variables' ;
2
3
@import ' ~@react-md/tree/dist/mixins' ;
3
4
5
+ .sheet {
6
+ background-color : $rmd-sheet-dark-elevation-background-color ;
7
+ }
8
+
4
9
.tree {
5
10
@include rmd-tree-depths (
6
11
$selector-prefix : ' :global ' ,
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ import {
14
14
TreeData ,
15
15
useTreeItemExpansion ,
16
16
} from "@react-md/tree" ;
17
- import { MobileOnly , useIsUserInteractionMode } from "@react-md/utils" ;
17
+ import { PhoneOnly , useIsUserInteractionMode } from "@react-md/utils" ;
18
18
19
19
import CssIcon from "icons/CssIcon" ;
20
20
import FileSVGIcon from "icons/FileSVGIcon" ;
@@ -122,7 +122,7 @@ export default function SandboxFileTree({
122
122
position = "left"
123
123
overlay = { ! inline }
124
124
portal = { false }
125
- className = { cn ( {
125
+ className = { cn ( styles . sheet , {
126
126
[ styles . inline ] : inline ,
127
127
} ) }
128
128
mountOnEnter = { ! inline }
@@ -131,11 +131,11 @@ export default function SandboxFileTree({
131
131
disableTransition = { disableTransition }
132
132
disableTabFocusWrap = { isKeyboard }
133
133
>
134
- < MobileOnly >
134
+ < PhoneOnly >
135
135
< AppBar theme = "default" >
136
136
< NavigationActions from = { from } onRequestClose = { onRequestClose } />
137
137
</ AppBar >
138
- </ MobileOnly >
138
+ </ PhoneOnly >
139
139
< Tree
140
140
id = "code-previewer-files"
141
141
className = { styles . tree }
Original file line number Diff line number Diff line change @@ -24,8 +24,7 @@ export default function SandboxNavigation({
24
24
onRequestFiles,
25
25
onRequestClose,
26
26
} : SandboxNavigationProps ) : ReactElement {
27
- const { isPhone, isTablet } = useAppSize ( ) ;
28
- const mobile = isPhone || isTablet ;
27
+ const { isPhone } = useAppSize ( ) ;
29
28
30
29
return (
31
30
< AppBar height = "prominent-dense" theme = "default" className = { styles . header } >
@@ -43,7 +42,7 @@ export default function SandboxNavigation({
43
42
< AppBarTitle id = "sandbox-dialog-title" noWrap >
44
43
{ name }
45
44
</ AppBarTitle >
46
- { ! mobile && (
45
+ { ! isPhone && (
47
46
< NavigationActions from = { from } onRequestClose = { onRequestClose } />
48
47
) }
49
48
</ AppBar >
You can’t perform that action at this time.
0 commit comments