@@ -135,118 +135,3 @@ const Divider = () => (
135
135
} }
136
136
/>
137
137
)
138
-
139
- // import { UserPermission } from '@stump/graphql'
140
- // import { useMemo } from 'react'
141
- // import { useWindowDimensions, View } from 'react-native'
142
- // import { ScrollView } from 'react-native-gesture-handler'
143
- // import { useSafeAreaInsets } from 'react-native-safe-area-context'
144
- // import { SimpleGrid } from 'react-native-super-grid'
145
-
146
- // import { useStumpServer } from '~/components/activeServer'
147
- // import { StackedBookThumbnails } from '~/components/book'
148
- // import { StackedLibraryThumbnails } from '~/components/library'
149
- // import { StackedSeriesThumbnails } from '~/components/series'
150
- // import { StackedSmartListThumbnails } from '~/components/smartList'
151
- // import { Heading, icons, Text } from '~/components/ui'
152
- // const { Crown, Slash } = icons
153
-
154
- // const ITEM_SPACING = 10
155
-
156
- // export default function Screen() {
157
- // const { width } = useWindowDimensions()
158
- // const {
159
- // activeServer: { id: serverID },
160
- // checkPermission,
161
- // } = useStumpServer()
162
-
163
- // const insets = useSafeAreaInsets()
164
- // const showSmartLists = checkPermission(UserPermission.AccessSmartList)
165
- // // iPad or other large screens can have more columns (i.e., smaller itemDimension) but most phones should have 2 columns
166
- // const isTablet = useMemo(() => width > 768, [width])
167
- // const itemDimension = useMemo(
168
- // () =>
169
- // width /
170
- // // 2 columns on phones
171
- // (isTablet ? 4 : 2) -
172
- // 16 * 2, // 16px padding on each side
173
- // [isTablet, width],
174
- // )
175
-
176
- // const sections = useMemo(
177
- // () => [
178
- // {
179
- // title: 'Libraries',
180
- // href: `/server/${serverID}/libraries`,
181
- // render: () => <StackedLibraryThumbnails />,
182
- // },
183
- // {
184
- // title: 'Series',
185
- // href: `/server/${serverID}/series`,
186
- // render: () => <StackedSeriesThumbnails />,
187
- // },
188
- // {
189
- // title: 'Books',
190
- // href: `/server/${serverID}/books`,
191
- // render: () => <StackedBookThumbnails />,
192
- // },
193
- // ...(showSmartLists
194
- // ? [
195
- // {
196
- // title: 'Smart Lists',
197
- // href: `/server/${serverID}/smart-lists`,
198
- // render: () => <StackedSmartListThumbnails />,
199
- // },
200
- // ]
201
- // : []),
202
- // ],
203
- // [serverID, showSmartLists],
204
- // )
205
-
206
- // return (
207
- // <View
208
- // className="flex-1 bg-background"
209
- // style={{
210
- // paddingTop: insets.top,
211
- // }}
212
- // >
213
- // <ScrollView className="flex-1 bg-background p-4">
214
- // {/* TODO: sticky header once heading isn't visible? */}
215
- // <Heading size="xl">Browse</Heading>
216
-
217
- // <View className="mt-8 flex-1 gap-8">
218
- // <View>
219
- // <Text className="mb-3 text-foreground-muted">Favorites</Text>
220
-
221
- // <View className="h-24 w-full items-center justify-center gap-2 rounded-lg border border-dashed border-edge p-3">
222
- // <View className="relative flex justify-center">
223
- // <View className="flex items-center justify-center rounded-lg bg-background-surface p-1.5">
224
- // <Crown className="h-6 w-6 text-foreground-muted" />
225
- // <Slash className="absolute h-6 w-6 scale-x-[-1] transform text-foreground opacity-80" />
226
- // </View>
227
- // </View>
228
-
229
- // <Text>No favorites</Text>
230
- // </View>
231
- // </View>
232
-
233
- // <View>
234
- // <Text className="mb-3 text-foreground-muted">All</Text>
235
-
236
- // {/* TODO: figure out spacing issues... */}
237
- // <SimpleGrid
238
- // fixed
239
- // style={{ flex: 1 }}
240
- // listKey={'browse-defaults'}
241
- // itemDimension={itemDimension}
242
- // data={sections}
243
- // renderItem={({ item: { render } }) => <View className="pb-2">{render()}</View> }
244
- // keyExtractor={(item) => item.title}
245
- // spacing={ITEM_SPACING}
246
- // />
247
- // </View>
248
- // </View>
249
- // </ScrollView>
250
- // </View>
251
- // )
252
- // }
0 commit comments