mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-17 17:49:39 +02:00
fixes
This commit is contained in:
parent
e9caa4a217
commit
843cf1e678
36 changed files with 400 additions and 55 deletions
|
|
@ -10,7 +10,6 @@
|
|||
"preview": "astro preview",
|
||||
"astro": "astro",
|
||||
"type-check": "astro check",
|
||||
"lint": "prettier --check . && eslint .",
|
||||
"format": "prettier --write .",
|
||||
"clean": "rm -rf dist .astro node_modules"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -11,8 +11,7 @@
|
|||
"./constants": "./src/constants/index.ts"
|
||||
},
|
||||
"scripts": {
|
||||
"type-check": "tsc --noEmit",
|
||||
"lint": "eslint src"
|
||||
"type-check": "tsc --noEmit"
|
||||
},
|
||||
"devDependencies": {
|
||||
"typescript": "~5.9.2"
|
||||
|
|
|
|||
|
|
@ -9,8 +9,7 @@
|
|||
"build": "astro check && astro build",
|
||||
"preview": "astro preview",
|
||||
"astro": "astro",
|
||||
"type-check": "astro check",
|
||||
"lint": "eslint ."
|
||||
"type-check": "astro check"
|
||||
},
|
||||
"dependencies": {
|
||||
"@astrojs/check": "^0.9.0",
|
||||
|
|
|
|||
|
|
@ -8,7 +8,5 @@
|
|||
"exports": {
|
||||
".": "./src/index.ts"
|
||||
},
|
||||
"scripts": {
|
||||
"lint": "eslint ."
|
||||
}
|
||||
"scripts": {}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,8 +5,7 @@
|
|||
"scripts": {
|
||||
"dev": "astro dev",
|
||||
"build": "astro build",
|
||||
"preview": "astro preview",
|
||||
"lint": "eslint ."
|
||||
"preview": "astro preview"
|
||||
},
|
||||
"dependencies": {
|
||||
"@astrojs/react": "^3.6.0",
|
||||
|
|
|
|||
|
|
@ -9,8 +9,7 @@
|
|||
"build": "astro check && astro build",
|
||||
"preview": "astro preview",
|
||||
"astro": "astro",
|
||||
"type-check": "astro check",
|
||||
"lint": "eslint ."
|
||||
"type-check": "astro check"
|
||||
},
|
||||
"dependencies": {
|
||||
"@astrojs/check": "^0.9.0",
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@
|
|||
"preview": "astro preview",
|
||||
"astro": "astro",
|
||||
"type-check": "astro check",
|
||||
"lint": "prettier --check . && eslint .",
|
||||
"format": "prettier --write .",
|
||||
"clean": "rm -rf dist .astro node_modules"
|
||||
},
|
||||
|
|
|
|||
|
|
@ -9,8 +9,7 @@
|
|||
"build": "astro check && astro build",
|
||||
"preview": "astro preview",
|
||||
"astro": "astro",
|
||||
"type-check": "astro check",
|
||||
"lint": "eslint ."
|
||||
"type-check": "astro check"
|
||||
},
|
||||
"dependencies": {
|
||||
"@astrojs/check": "^0.9.0",
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ function StackNavigator() {
|
|||
header: ({ route, options }) => {
|
||||
let title = options.title || '';
|
||||
let showAddDeck = false;
|
||||
let rightContent = options.headerRight?.({});
|
||||
const rightContent = options.headerRight?.({});
|
||||
|
||||
if (route.name === 'index') {
|
||||
title = `My Decks (${route.params?.deckCount || 0})`;
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ import {
|
|||
} from 'react-native';
|
||||
import { useLocalSearchParams, useRouter } from 'expo-router';
|
||||
import { getDeckSlides, getDeck, deleteSlide, reorderSlide } from '../../services/firestore';
|
||||
import { Slide, Deck } from '../../types/models';
|
||||
import { type Slide, type Deck } from '../../types/models';
|
||||
import { SlideList } from '../../components/slides/SlideList';
|
||||
import { SlideEditor } from '../../components/slides/SlideEditor';
|
||||
import { PresentationMode } from '../../components/presentation/PresentationMode';
|
||||
|
|
@ -234,7 +234,7 @@ export default function DeckScreen() {
|
|||
/>
|
||||
<Header
|
||||
title={deck?.name || 'Loading...'}
|
||||
showPresent={true}
|
||||
showPresent
|
||||
onPresentPress={handleStartPresentation}
|
||||
disabled={!slides.length}
|
||||
slideCount={slides.length}
|
||||
|
|
@ -244,7 +244,7 @@ export default function DeckScreen() {
|
|||
<Modal
|
||||
visible={isCreateModalVisible}
|
||||
animationType="fade"
|
||||
transparent={true}
|
||||
transparent
|
||||
onRequestClose={() => {
|
||||
setIsCreateModalVisible(false);
|
||||
setEditingSlide(null);
|
||||
|
|
@ -314,7 +314,7 @@ export default function DeckScreen() {
|
|||
<Modal
|
||||
visible={isDeleteModalVisible}
|
||||
animationType="fade"
|
||||
transparent={true}
|
||||
transparent
|
||||
onRequestClose={() => setIsDeleteModalVisible(false)}
|
||||
>
|
||||
<View
|
||||
|
|
@ -386,7 +386,7 @@ export default function DeckScreen() {
|
|||
animationType="fade"
|
||||
transparent={false}
|
||||
onRequestClose={() => setIsPresentationMode(false)}
|
||||
statusBarTranslucent={true}
|
||||
statusBarTranslucent
|
||||
>
|
||||
<View style={{ flex: 1, backgroundColor: theme.colors.backgroundPage }}>
|
||||
<PresentationMode slides={slides} onClose={() => setIsPresentationMode(false)} />
|
||||
|
|
|
|||
|
|
@ -7,12 +7,12 @@ import {
|
|||
getDeckSlides,
|
||||
migrateDecksToNewSchema,
|
||||
} from '../services/firestore';
|
||||
import { Deck, Slide } from '../types/models';
|
||||
import { type Deck, Slide } from '../types/models';
|
||||
import { DeckList } from '../components/decks/DeckList';
|
||||
import { CreateDeckForm } from '../components/forms/CreateDeckForm';
|
||||
import { DeckShareSettings } from '../components/decks/DeckShareSettings';
|
||||
import { auth } from '../firebaseConfig';
|
||||
import { onAuthStateChanged, User } from 'firebase/auth';
|
||||
import { onAuthStateChanged, type User } from 'firebase/auth';
|
||||
import MaterialIcons from 'react-native-vector-icons/MaterialIcons';
|
||||
import { ThemeProvider } from '../components/ThemeProvider';
|
||||
import { useTheme } from '../components/ThemeProvider';
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ import { useLocalSearchParams } from 'expo-router';
|
|||
import React, { useEffect, useState } from 'react';
|
||||
import { View, Text, StyleSheet } from 'react-native';
|
||||
import { useTheme } from '../../components/ThemeProvider';
|
||||
import { Deck } from '../../types/models';
|
||||
import { type Deck } from '../../types/models';
|
||||
import { doc, getDoc } from 'firebase/firestore';
|
||||
import { db } from '../../firebaseConfig';
|
||||
import { SlideList } from '../../components/slides/SlideList';
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import React from 'react';
|
||||
import { View, Text, StyleSheet, ScrollView, TouchableOpacity, Image } from 'react-native';
|
||||
import { useRouter } from 'expo-router';
|
||||
import { useTheme, ThemeVariant } from '../components/ThemeProvider';
|
||||
import { useTheme, type ThemeVariant } from '../components/ThemeProvider';
|
||||
import MaterialIcons from '@expo/vector-icons/MaterialIcons';
|
||||
|
||||
const THEME_PATTERNS: Record<ThemeVariant, any> = {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import React, { createContext, useContext, useState, useEffect, useMemo } from 'react';
|
||||
import { useColorScheme } from 'react-native';
|
||||
import { getTheme, Theme, ThemeVariant } from '../constants/theme';
|
||||
import { getTheme, type Theme, type ThemeVariant } from '../constants/theme';
|
||||
|
||||
export type ColorMode = 'system' | 'light' | 'dark';
|
||||
export type ContrastLevel = 1 | 2 | 3 | 4 | 5;
|
||||
|
|
@ -18,7 +18,7 @@ const hexToRgb = (hex: string) => {
|
|||
};
|
||||
|
||||
// Hilfsfunktion zum Konvertieren von RGB zu Hex mit Alpha
|
||||
const rgbaToHex = (r: number, g: number, b: number, a: number = 1) => {
|
||||
const rgbaToHex = (r: number, g: number, b: number, a = 1) => {
|
||||
const alpha = Math.round(a * 255);
|
||||
return (
|
||||
'#' +
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import { TouchableOpacity, Text, StyleSheet, ActivityIndicator } from 'react-native';
|
||||
import { ReactNode } from 'react';
|
||||
import { type ReactNode } from 'react';
|
||||
|
||||
interface ButtonProps {
|
||||
onPress: () => void;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import React from 'react';
|
||||
import { View, Text, TouchableOpacity, StyleSheet, Pressable } from 'react-native';
|
||||
import { useTheme, ColorMode, ContrastLevel } from '../ThemeProvider';
|
||||
import { useTheme, type ColorMode, type ContrastLevel } from '../ThemeProvider';
|
||||
|
||||
const COLOR_MODES: { label: string; value: ColorMode }[] = [
|
||||
{ label: 'System', value: 'system' },
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import React from 'react';
|
||||
import { View, Text, TouchableOpacity, StyleSheet, Image } from 'react-native';
|
||||
import { Deck } from '../../types/models';
|
||||
import { type Deck } from '../../types/models';
|
||||
import { MaterialIcons } from '@expo/vector-icons';
|
||||
import { useTheme } from '../../components/ThemeProvider';
|
||||
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ import {
|
|||
Pressable,
|
||||
} from 'react-native';
|
||||
import MaterialIcons from '@expo/vector-icons/MaterialIcons';
|
||||
import { Deck } from '../../types/models';
|
||||
import { type Deck } from '../../types/models';
|
||||
import { useTheme } from '../../components/ThemeProvider';
|
||||
import { CreateItemButton } from '../common/CreateItemButton';
|
||||
import { MenuRoot, MenuTrigger, MenuContent, MenuItem, MenuItemTitle } from '../common/menu';
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ import {
|
|||
} from 'react-native';
|
||||
import { useTheme } from '../ThemeProvider';
|
||||
import MaterialIcons from '@expo/vector-icons/MaterialIcons';
|
||||
import { Deck, CollaboratorRole } from '../../types/models';
|
||||
import { type Deck, type CollaboratorRole } from '../../types/models';
|
||||
|
||||
interface DeckShareSettingsProps {
|
||||
deck: Deck;
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ import {
|
|||
} from 'react-native';
|
||||
import { useTheme } from '../ThemeProvider';
|
||||
import { createDeck } from '../../services/firestore';
|
||||
import { Deck } from '../../types/models';
|
||||
import { type Deck } from '../../types/models';
|
||||
import MaterialIcons from '@expo/vector-icons/MaterialIcons';
|
||||
|
||||
interface CreateDeckFormProps {
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ import {
|
|||
} from 'react-native';
|
||||
import { Ionicons } from '@expo/vector-icons';
|
||||
import { SlideView } from '../slides/SlideView';
|
||||
import { Slide } from '../../types/models';
|
||||
import { type Slide } from '../../types/models';
|
||||
import * as ScreenOrientation from 'expo-screen-orientation';
|
||||
import { useTheme } from '../ThemeProvider';
|
||||
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ import * as ImagePicker from 'expo-image-picker';
|
|||
import { storage } from '../../firebaseConfig';
|
||||
import { ref, uploadBytes, getDownloadURL } from 'firebase/storage';
|
||||
import { createSlide, updateSlide } from '../../services/firestore';
|
||||
import { Slide } from '../../types/models';
|
||||
import { type Slide } from '../../types/models';
|
||||
import MaterialIcons from '@expo/vector-icons/MaterialIcons';
|
||||
import { useTheme } from '../ThemeProvider';
|
||||
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ import {
|
|||
Pressable,
|
||||
} from 'react-native';
|
||||
import MaterialIcons from '@expo/vector-icons/MaterialIcons';
|
||||
import { Slide } from '../../types/models';
|
||||
import { type Slide } from '../../types/models';
|
||||
import { useTheme } from '../ThemeProvider';
|
||||
import { MenuRoot, MenuTrigger, MenuContent, MenuItem, MenuItemTitle } from '../common/menu';
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import React from 'react';
|
||||
import { View, Text, Image, StyleSheet, Dimensions, TouchableOpacity } from 'react-native';
|
||||
import { Slide } from '../../types/models';
|
||||
import { type Slide } from '../../types/models';
|
||||
import MaterialIcons from 'react-native-vector-icons/MaterialIcons';
|
||||
import { useTheme } from '../ThemeProvider';
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import { ColorSchemeName } from 'react-native';
|
||||
import { type ColorSchemeName } from 'react-native';
|
||||
|
||||
// Theme types
|
||||
export type ThemeVariant = 'lume' | 'nature' | 'stone';
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ import {
|
|||
signOut,
|
||||
sendPasswordResetEmail,
|
||||
onAuthStateChanged,
|
||||
User,
|
||||
type User,
|
||||
} from 'firebase/auth';
|
||||
import { auth } from '../firebaseConfig';
|
||||
import { doc, setDoc } from 'firebase/firestore';
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ import {
|
|||
writeBatch,
|
||||
} from 'firebase/firestore';
|
||||
import { db, auth } from '../firebaseConfig';
|
||||
import { Deck, Slide } from '../types/models';
|
||||
import { type Deck, type Slide } from '../types/models';
|
||||
|
||||
// Decks
|
||||
export const getUserDecks = async (userId: string): Promise<Deck[]> => {
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import React, { createContext, useContext, useState, useEffect } from 'react';
|
||||
import { useColorScheme } from 'react-native';
|
||||
import AsyncStorage from '@react-native-async-storage/async-storage';
|
||||
import { getTheme, Theme } from './constants';
|
||||
import { getTheme, type Theme } from './constants';
|
||||
|
||||
export type ColorMode = 'system' | 'light' | 'dark';
|
||||
export type ContrastLevel = 1 | 2 | 3 | 4 | 5;
|
||||
|
|
@ -42,7 +42,7 @@ const hexToRgb = (hex: string) => {
|
|||
};
|
||||
|
||||
// Hilfsfunktion zum Konvertieren von RGB zu Hex mit Alpha
|
||||
const rgbaToHex = (r: number, g: number, b: number, a: number = 1) => {
|
||||
const rgbaToHex = (r: number, g: number, b: number, a = 1) => {
|
||||
const alpha = Math.round(a * 255);
|
||||
return (
|
||||
'#' +
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import React from 'react';
|
||||
import { View, Text, TouchableOpacity, StyleSheet, Pressable } from 'react-native';
|
||||
import { useTheme, ColorMode, ContrastLevel } from './ThemeProvider';
|
||||
import { useTheme, type ColorMode, type ContrastLevel } from './ThemeProvider';
|
||||
|
||||
const COLOR_MODES: { label: string; value: ColorMode }[] = [
|
||||
{ label: 'System', value: 'system' },
|
||||
|
|
|
|||
|
|
@ -5,8 +5,7 @@
|
|||
"main": "./src/index.ts",
|
||||
"types": "./src/index.ts",
|
||||
"scripts": {
|
||||
"type-check": "tsc --noEmit",
|
||||
"lint": "eslint ."
|
||||
"type-check": "tsc --noEmit"
|
||||
},
|
||||
"devDependencies": {
|
||||
"typescript": "^5.7.2"
|
||||
|
|
|
|||
|
|
@ -9,8 +9,7 @@
|
|||
"./types": "./src/types/index.ts"
|
||||
},
|
||||
"scripts": {
|
||||
"type-check": "tsc --noEmit",
|
||||
"lint": "eslint ."
|
||||
"type-check": "tsc --noEmit"
|
||||
},
|
||||
"devDependencies": {
|
||||
"typescript": "^5.7.3"
|
||||
|
|
|
|||
|
|
@ -6,8 +6,7 @@
|
|||
"dev": "astro dev",
|
||||
"build": "astro build",
|
||||
"preview": "astro preview",
|
||||
"astro": "astro",
|
||||
"lint": "eslint ."
|
||||
"astro": "astro"
|
||||
},
|
||||
"dependencies": {
|
||||
"@manacore/shared-landing-ui": "workspace:*",
|
||||
|
|
|
|||
|
|
@ -10,8 +10,7 @@
|
|||
"./config": "./src/config/index.ts"
|
||||
},
|
||||
"scripts": {
|
||||
"type-check": "tsc --noEmit",
|
||||
"lint": "eslint ."
|
||||
"type-check": "tsc --noEmit"
|
||||
},
|
||||
"dependencies": {
|
||||
"@zitare/shared": "workspace:*"
|
||||
|
|
|
|||
|
|
@ -12,8 +12,7 @@
|
|||
"./services": "./src/services/index.ts"
|
||||
},
|
||||
"scripts": {
|
||||
"type-check": "tsc --noEmit",
|
||||
"lint": "eslint src"
|
||||
"type-check": "tsc --noEmit"
|
||||
},
|
||||
"devDependencies": {
|
||||
"typescript": "~5.9.2"
|
||||
|
|
|
|||
|
|
@ -9,8 +9,7 @@
|
|||
"./stores/*": "./src/stores/*.ts"
|
||||
},
|
||||
"scripts": {
|
||||
"check": "svelte-check --tsconfig ./tsconfig.json",
|
||||
"lint": "eslint ."
|
||||
"check": "svelte-check --tsconfig ./tsconfig.json"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"svelte": "^5.0.0"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue