Projekt

Obecné

Profil

« Předchozí | Další » 

Revize a62d7c92

Přidáno uživatelem Michal Schwob před více než 1 rok

FIX: compilation error fixes
re #10847

Zobrazit rozdíly:

src/components/item/ItemTabBar.tsx
3 3
import { Certainty, Concordance } from "../../types/item";
4 4
import LoadingBox from "../loading/LoadingBox";
5 5
import { DrawerNavigationProp } from "@react-navigation/drawer";
6
import { RootDrawerParamList } from "../../pages/Navigation";
6
import { RootStackParamList } from "../../pages/Navigation";
7 7
import { InfoToast } from "../toast/InfoToast";
8 8

  
9 9
// custom render Tab
10
const ItemTabBar = (props: { navigationState: { routes: any[] }, concordances: Concordance[], index: number, onIndexChange: any, onBackPressed: any, navigation: DrawerNavigationProp<RootDrawerParamList, "Item", undefined>, nextItem?: string | boolean, prevItem?:string | boolean }) => {
10
const ItemTabBar = (props: { navigationState: { routes: any[] }, concordances: Concordance[], index: number, onIndexChange: any, onBackPressed: any, navigation: DrawerNavigationProp<RootStackParamList, "Item", undefined>, nextItem?: string | boolean, prevItem?:string | boolean }) => {
11 11

  
12 12
    const { concordances, onIndexChange, index, onBackPressed, nextItem, prevItem } = props
13 13

  
src/components/item/ItemView.tsx
13 13

  
14 14
import { Dimensions } from "react-native";
15 15
import { DrawerNavigationProp } from "@react-navigation/drawer"
16
import { RootDrawerParamList } from "../../pages/Navigation"
16
import { RootStackParamList } from "../../pages/Navigation"
17 17

  
18 18
interface ItemDetailProps {
19 19
    item: Item,
20 20
    itemLoading: boolean,
21 21
    notes: Note[],
22 22
    notesLoading: boolean,
23
    navigation: DrawerNavigationProp<RootDrawerParamList, "Item", undefined>
23
    navigation: DrawerNavigationProp<RootStackParamList, "Item", undefined>
24 24
}
25 25

  
26 26
const ItemDetail = (props: { item: Item, itemLoading: boolean }) => {
......
137 137

  
138 138

  
139 139

  
140
const ItemNotes = (props: { item: Item, notes: Note[], notesLoading: boolean, navigation: DrawerNavigationProp<RootDrawerParamList, "Item", undefined> }) => {
140
const ItemNotes = (props: { item: Item, notes: Note[], notesLoading: boolean, navigation: DrawerNavigationProp<RootStackParamList, "Item", undefined> }) => {
141 141

  
142 142
    const [showRelatedComments, setShowRelatedComments] = useState(true);
143 143

  
src/components/listView/ItemPreview.tsx
1 1
import { Box, Center, HStack, Image, Pressable, ScrollView, Text, VStack } from "native-base"
2 2
import { useEffect } from "react"
3 3
import { DrawerScreenProps } from "@react-navigation/drawer"
4
import { RootDrawerParamList } from "../../pages/Navigation"
4
import { RootStackParamList } from "../../pages/Navigation"
5 5
import { ItemPreviewMissingImage } from "./ItemPreviewMissingImage"
6 6
import { ITEM_PREVIEW_IMG_PREFIX_URL } from "../../api/constants"
7 7

  
src/pages/HomePage.tsx
6 6
import { ApplicationHeading } from "../components/reusables/ApplicationHeading"
7 7
import LoadingBox from "../components/loading/LoadingBox"
8 8
import { DrawerScreenProps } from "@react-navigation/drawer"
9
import { RootDrawerParamList } from "./Navigation"
9
import { RootStackParamList } from "./Navigation"
10 10
import { log } from "../logging/logger"
11 11
import { HOME_PAGE_IMG_URL } from "../api/constants"
12 12
import { ErrorToast } from "../components/toast/ErrorToast"
13 13
// import { Image } from "react-native"
14 14

  
15
const HomePage = ({navigation}: DrawerScreenProps<RootDrawerParamList, 'Home'>) => {
15
const HomePage = ({navigation}: DrawerScreenProps<RootStackParamList, 'Home'>) => {
16 16
    const data = useSelector((state: RootState) => state.homePage.data)
17 17
    const loading = useSelector((state: RootState) => state.homePage.loading)
18 18
    const lastError = useSelector((state: RootState) => state.itemViewState.lastError)
src/pages/ItemViewPage.tsx
10 10
import ItemTabBar from "../components/item/ItemTabBar"
11 11
import { log } from "../logging/logger"
12 12
import { DrawerScreenProps } from "@react-navigation/drawer"
13
import { RootDrawerParamList } from "./Navigation"
13
import { RootStackParamList } from "./Navigation"
14 14
import { useToast } from "native-base"
15 15
import { ErrorToast } from "../components/toast/ErrorToast"
16 16

  
17 17

  
18
const ItemViewPage = ({ route, navigation }: DrawerScreenProps<RootDrawerParamList, 'Item'>) => {
18
const ItemViewPage = ({ route, navigation }: DrawerScreenProps<RootStackParamList, 'Item'>) => {
19 19

  
20 20
  const layout = useWindowDimensions();
21 21

  
src/pages/NotesViewPage.tsx
9 9
import { AppDispatch, RootState } from "../stores/store"
10 10
import LoadingBox from "../components/loading/LoadingBox"
11 11
import { createNote, getAllNotes } from "../stores/actions/notesThunks"
12
import { RootDrawerParamList } from "./Navigation"
12
import { RootStackParamList } from "./Navigation"
13 13
import { ErrorToast } from "../components/toast/ErrorToast"
14 14
import { InfoToast } from "../components/toast/InfoToast"
15 15

  
16 16
import { Dimensions } from "react-native";
17 17

  
18
const NotesViewPage = ({ navigation }: DrawerScreenProps<RootDrawerParamList, 'Notes'>) => {
18
const NotesViewPage = ({ navigation }: DrawerScreenProps<RootStackParamList, 'Notes'>) => {
19 19

  
20 20
  const { notes, notesLoading, requestPending, triggerRefresh } = useSelector((state: RootState) => state.noteViewState);
21 21

  
src/pages/SearchPage.tsx
21 21
import { AppDispatch } from "../stores/store"
22 22
import { log } from "../logging/logger"
23 23
import { DrawerScreenProps } from "@react-navigation/drawer"
24
import { RootDrawerParamList } from "./Navigation"
24
import { RootStackParamList } from "./Navigation"
25 25

  
26 26

  
27
const SearchPage = ({route, navigation}: DrawerScreenProps<RootDrawerParamList, 'Search'>) => {
27
const SearchPage = ({route, navigation}: DrawerScreenProps<RootStackParamList, 'Search'>) => {
28 28
    const dispatch = useDispatch<AppDispatch>()
29 29

  
30 30
    useEffect(() => {

Také k dispozici: Unified diff