Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: 🐛 schema syns inte om kalender är tom #342

Merged
merged 1 commit into from
Apr 29, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 3 additions & 10 deletions packages/app/components/calendar.component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { CalendarItem } from '@skolplattformen/embedded-api'
import { Divider, List, ListItem, Text } from '@ui-kitten/components'
import moment from 'moment'
import React from 'react'
import { Image, ListRenderItemInfo, StyleSheet, View } from 'react-native'
import { ListRenderItemInfo, StyleSheet, View } from 'react-native'
import { Colors, Typography } from '../styles'
import { useChild } from './childContext.component'
import { CalendarOutlineIcon } from './icon.component'
Expand All @@ -15,12 +15,8 @@ export const Calendar = () => {
const { data } = useCalendar(child)

return !data?.length ? (
<View style={styles.emptyState}>
<Image
source={require('../assets/girls.png')}
style={styles.emptyStateImage}
/>
<Text category="h5">Det ser lite tomt ut i kalendern</Text>
<View>
<Week child={child} />
</View>
) : (
<View>
Expand Down Expand Up @@ -54,9 +50,6 @@ export const Calendar = () => {
}

const styles = StyleSheet.create({
emptyState: {
flex: 1,
},
emptyStateImage: {
height: 200,
width: '100%',
Expand Down