@mediacubeco/expo-template-fsd 2.3.1 → 2.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/commands/git-commit.md +164 -0
- package/.claude/rules/architecture.md +38 -0
- package/.claude/rules/{prettier-eslint-typescript.mdc → prettier-eslint-typescript.md} +5 -10
- package/.claude/settings.json +2 -2
- package/.claude/skills/api/SKILL.md +362 -0
- package/.claude/skills/api/references/client/overview.md +106 -0
- package/.claude/skills/api/references/hooks/index.ts +3 -0
- package/.claude/skills/api/references/hooks/use-api-health.ts +25 -0
- package/.claude/skills/api/references/hooks/use-api-post.ts +46 -0
- package/.claude/skills/api/references/hooks/use-api-posts.ts +24 -0
- package/.claude/skills/api/references/mock/post.mock.ts +29 -0
- package/.claude/skills/{generate-api-model/references → api/references/model}/entities/common.ts +5 -2
- package/.claude/skills/api/references/model/resources/common.ts +9 -0
- package/.claude/skills/api/references/queries/health.ts +14 -0
- package/.claude/skills/api/references/queries/index.ts +2 -0
- package/.claude/skills/api/references/queries/post.ts +23 -0
- package/.claude/skills/api/references/repository/health/health.ts +11 -0
- package/.claude/skills/api/references/repository/health/health.types.ts +25 -0
- package/.claude/skills/api/references/repository/health/index.ts +2 -0
- package/.claude/skills/api/references/repository/post/index.ts +9 -0
- package/.claude/skills/api/references/repository/post/post.ts +34 -0
- package/.claude/skills/api/references/repository/post/post.types.ts +61 -0
- package/.claude/skills/code-style/SKILL.md +1025 -1
- package/.claude/skills/code-style/references/components/payout-speed-option/index.ts +2 -0
- package/.claude/skills/code-style/references/components/payout-speed-option/payout-speed-option.styles.ts +76 -0
- package/.claude/skills/code-style/references/components/payout-speed-option/payout-speed-option.tsx +58 -0
- package/.claude/skills/code-style/references/components/payout-speed-option/payout-speed-option.types.ts +22 -0
- package/.claude/skills/code-style/references/components/post/index.ts +2 -0
- package/.claude/skills/code-style/references/components/post/post.styles.ts +19 -0
- package/.claude/skills/code-style/references/components/post/post.tsx +21 -0
- package/.claude/skills/code-style/references/components/post/post.types.ts +9 -0
- package/.claude/skills/code-style/references/components/wrap/index.ts +2 -0
- package/.claude/skills/code-style/references/components/wrap/wrap.styles.ts +15 -0
- package/.claude/skills/code-style/references/components/wrap/wrap.tsx +31 -0
- package/.claude/skills/code-style/references/components/wrap/wrap.types.ts +10 -0
- package/.claude/skills/code-style/references/hooks/use-posts.ts +37 -0
- package/.claude/skills/code-style/references/pages/post/index.ts +4 -0
- package/.claude/skills/code-style/references/pages/post/post-details/index.ts +1 -0
- package/.claude/skills/code-style/references/pages/post/post-details/post-details.tsx +13 -0
- package/.claude/skills/code-style/references/pages/post/post-guide/index.ts +1 -0
- package/.claude/skills/code-style/references/pages/post/post-guide/post-guide.tsx +17 -0
- package/.claude/skills/code-style/references/pages/post/post-list/index.ts +1 -0
- package/.claude/skills/code-style/references/pages/post/post-list/post-list.styles.ts +17 -0
- package/.claude/skills/code-style/references/pages/post/post-list/post-list.tsx +25 -0
- package/.claude/skills/code-style/references/pages/post/post-share/index.ts +1 -0
- package/.claude/skills/code-style/references/pages/post/post-share/post-share.tsx +13 -0
- package/.claude/skills/code-style/references/routes/(stack)/_layout.tsx +18 -0
- package/.claude/skills/code-style/references/routes/(stack)/details.tsx +8 -0
- package/.claude/skills/code-style/references/routes/(stack)/guide.tsx +8 -0
- package/.claude/skills/code-style/references/routes/(stack)/index.tsx +8 -0
- package/.claude/skills/code-style/references/routes/(stack)/share.tsx +8 -0
- package/.claude/skills/code-style/references/routes/(tabs)/(post-details)/index.tsx +8 -0
- package/.claude/skills/code-style/references/routes/(tabs)/(post-list)/index.tsx +8 -0
- package/.claude/skills/code-style/references/routes/(tabs)/_layout.tsx +50 -0
- package/.claude/skills/code-style/references/routes/_app.tsx +20 -0
- package/.claude/skills/code-style/references/routes/guide.tsx +8 -0
- package/.claude/skills/code-style/references/routes/share.tsx +8 -0
- package/.claude/skills/code-style/references/store/use-post-draft-store.ts +62 -0
- package/.claude/skills/design-style/SKILL.md +320 -0
- package/.env +3 -1
- package/.env.example +3 -1
- package/CLAUDE.md +5 -11
- package/app.json +6 -3
- package/axios.d.ts +5 -0
- package/env.d.ts +3 -1
- package/package.json +33 -40
- package/patches/react-native-screens+4.25.2.patch +118 -0
- package/react-query.d.ts +13 -0
- package/src/app/(root)/(home)/_layout.tsx +2 -2
- package/src/app/(root)/(home)/index.tsx +2 -2
- package/src/app/(root)/(settings)/_layout.tsx +2 -2
- package/src/app/(root)/(settings)/index.tsx +2 -2
- package/src/app/(root)/_layout.tsx +35 -32
- package/src/pages/home/home-main.tsx +3 -7
- package/src/pages/settings/settings-main.tsx +3 -7
- package/src/shared/assets/fonts/index.ts +3 -3
- package/src/shared/assets/fonts/sf-pro-text-bold.ttf +0 -0
- package/src/shared/assets/fonts/sf-pro-text-regular.ttf +0 -0
- package/src/shared/assets/fonts/sf-pro-text-semibold.ttf +0 -0
- package/src/shared/assets/icons/back.tsx +21 -0
- package/src/shared/assets/icons/close.tsx +21 -0
- package/src/shared/assets/icons/common.ts +8 -0
- package/src/shared/assets/icons/default.tsx +44 -0
- package/src/shared/assets/icons/index.ts +13 -1
- package/src/shared/assets/icons/refresh.tsx +23 -0
- package/src/shared/assets/icons/share.tsx +38 -0
- package/src/shared/assets/icons/type.ts +7 -0
- package/src/shared/assets/translations/index.ts +4 -4
- package/src/shared/constants/config.ts +13 -0
- package/src/shared/constants/environment.ts +16 -4
- package/src/shared/constants/index.ts +1 -0
- package/src/shared/hooks/index.ts +1 -4
- package/src/shared/hooks/use-compose.ts +23 -0
- package/src/shared/lib/api/api.client.ts +157 -0
- package/src/shared/lib/api/api.provider.tsx +14 -36
- package/src/shared/lib/api/api.ts +1 -5
- package/src/shared/lib/api/api.types.ts +6 -3
- package/src/shared/lib/api/hooks/index.ts +1 -0
- package/src/shared/lib/api/index.ts +2 -3
- package/src/shared/lib/api/models/api-instance/api-instance.client.ts +50 -0
- package/src/shared/lib/api/models/api-instance/api-instance.ts +30 -82
- package/src/shared/lib/api/models/api-instance/api-instance.types.ts +16 -18
- package/src/shared/lib/api/models/api-instance/api-instance.utils.ts +13 -20
- package/src/shared/lib/api/models/api-instance/index.ts +3 -0
- package/src/shared/lib/api/queries/index.ts +1 -0
- package/src/shared/lib/api/repositories/index.ts +1 -1
- package/src/shared/lib/localization/constants/index.ts +16 -5
- package/src/shared/lib/localization/index.ts +5 -1
- package/src/shared/lib/navigation/hooks/index.ts +8 -3
- package/src/shared/{hooks/use-breakpoints.ts → lib/navigation/hooks/use-navigation-breakpoints.ts} +2 -5
- package/src/shared/lib/navigation/hooks/use-navigation-dimensions.ts +12 -0
- package/src/shared/lib/navigation/hooks/use-navigation-options.tsx +175 -0
- package/src/shared/lib/navigation/hooks/{use-navigation.ts → use-navigation-route.ts} +2 -2
- package/src/shared/lib/navigation/hooks/use-navigation-safe-area.ts +61 -0
- package/src/shared/lib/navigation/hooks/use-navigation-tabs-native.ts +10 -0
- package/src/shared/lib/navigation/hooks/use-navigation-tabs.tsx +10 -0
- package/src/shared/lib/navigation/hooks/use-navigation-transition.ts +27 -0
- package/src/shared/lib/navigation/index.ts +11 -4
- package/src/shared/lib/navigation/navigation-tabs-native.context.tsx +5 -0
- package/src/shared/lib/navigation/navigation-tabs-native.provider.tsx +17 -0
- package/src/shared/lib/navigation/navigation-tabs.context.tsx +10 -0
- package/src/shared/lib/navigation/navigation-tabs.provider.tsx +22 -0
- package/src/shared/lib/navigation/navigation.provider.tsx +6 -1
- package/src/shared/lib/storage/index.ts +1 -1
- package/src/shared/lib/storage/storage.provider.tsx +4 -0
- package/src/shared/lib/storage/storage.ts +29 -25
- package/src/shared/lib/theme/constants/animations.ts +26 -0
- package/src/shared/lib/theme/constants/colors.ts +336 -43
- package/src/shared/lib/theme/constants/delays.ts +1 -1
- package/src/shared/lib/theme/constants/durations.ts +1 -1
- package/src/shared/lib/theme/constants/fonts.ts +2 -1
- package/src/shared/lib/theme/constants/index.ts +42 -20
- package/src/shared/lib/theme/constants/shadows.ts +7 -25
- package/src/shared/lib/theme/constants/sizes.ts +11 -2
- package/src/shared/lib/theme/constants/transparencies.ts +1 -1
- package/src/shared/lib/theme/hooks/use-theme-setup.ts +3 -1
- package/src/shared/lib/theme/index.ts +10 -1
- package/src/shared/lib/theme/theme.provider.tsx +45 -19
- package/src/shared/lib/theme/theme.scope.tsx +43 -0
- package/src/shared/lib/theme/theme.types.ts +15 -3
- package/src/shared/lib/theme/utils/color.ts +81 -0
- package/src/shared/lib/theme/utils/index.ts +2 -0
- package/src/shared/lib/theme/utils/snapshot.ts +17 -0
- package/src/shared/lib/theme/utils/storage.ts +5 -2
- package/src/shared/services/browser/browser.ts +66 -0
- package/src/shared/services/browser/index.ts +1 -0
- package/src/shared/services/cookies/cookies.ts +73 -0
- package/src/shared/services/cookies/index.ts +1 -0
- package/src/shared/services/index.ts +5 -0
- package/src/shared/services/linking/index.ts +1 -0
- package/src/shared/services/linking/linking.ts +22 -0
- package/src/shared/services/share/index.ts +1 -0
- package/src/shared/services/share/share.ts +28 -0
- package/src/shared/services/universal-links/index.ts +104 -0
- package/src/shared/services/universal-links/universal-links.ts +25 -0
- package/src/shared/services/universal-links/universal-links.types.ts +5 -0
- package/src/shared/ui/atoms/blur/blur.tsx +9 -4
- package/src/shared/ui/atoms/blur/blur.types.ts +1 -1
- package/src/shared/ui/atoms/blur-progress/blur-progress.styles.ts +16 -0
- package/src/shared/ui/atoms/blur-progress/blur-progress.tsx +30 -0
- package/src/shared/ui/atoms/blur-progress/blur-progress.types.tsx +5 -0
- package/src/shared/ui/atoms/blur-progress/index.ts +1 -0
- package/src/shared/ui/atoms/glass/glass.tsx +13 -5
- package/src/shared/ui/atoms/glass/glass.types.ts +1 -1
- package/src/shared/ui/atoms/icon/icon.styles.ts +82 -0
- package/src/shared/ui/atoms/icon/icon.tsx +21 -0
- package/src/shared/ui/atoms/icon/icon.types.ts +23 -0
- package/src/shared/ui/atoms/icon/index.ts +2 -0
- package/src/shared/ui/atoms/index.ts +7 -0
- package/src/shared/ui/atoms/skeleton/index.ts +2 -0
- package/src/shared/ui/atoms/skeleton/skeleton.styles.ts +69 -0
- package/src/shared/ui/atoms/skeleton/skeleton.tsx +26 -0
- package/src/shared/ui/atoms/skeleton/skeleton.types.ts +9 -0
- package/src/shared/ui/atoms/spinner/index.ts +2 -0
- package/src/shared/ui/atoms/spinner/spinner.styles.ts +102 -0
- package/src/shared/ui/atoms/spinner/spinner.tsx +48 -0
- package/src/shared/ui/atoms/spinner/spinner.types.ts +25 -0
- package/src/shared/ui/atoms/text/index.ts +2 -0
- package/src/shared/ui/atoms/text/text.styles.ts +186 -0
- package/src/shared/ui/atoms/text/text.tsx +37 -0
- package/src/shared/ui/atoms/text/text.types.ts +35 -0
- package/src/shared/ui/atoms/touch/components/haptics/haptics.styles.ts +21 -0
- package/src/shared/ui/atoms/touch/components/haptics/haptics.tsx +28 -0
- package/src/shared/ui/atoms/touch/components/haptics/haptics.types.ts +17 -0
- package/src/shared/ui/atoms/touch/components/haptics/index.ts +2 -0
- package/src/shared/ui/atoms/touch/components/index.ts +3 -0
- package/src/shared/ui/atoms/touch/components/ripple/index.ts +2 -0
- package/src/shared/ui/atoms/touch/components/ripple/ripple.styles.ts +78 -0
- package/src/shared/ui/atoms/touch/components/ripple/ripple.tsx +29 -0
- package/src/shared/ui/atoms/touch/components/ripple/ripple.types.ts +17 -0
- package/src/shared/ui/atoms/touch/components/spring/index.ts +2 -0
- package/src/shared/ui/atoms/touch/components/spring/spring.styles.ts +31 -0
- package/src/shared/ui/atoms/touch/components/spring/spring.tsx +28 -0
- package/src/shared/ui/atoms/touch/components/spring/spring.types.ts +17 -0
- package/src/shared/ui/atoms/touch/index.ts +2 -0
- package/src/shared/ui/atoms/touch/touch.styles.ts +14 -0
- package/src/shared/ui/atoms/touch/touch.tsx +137 -0
- package/src/shared/ui/atoms/touch/touch.types.ts +27 -0
- package/src/shared/ui/atoms/visibility/index.ts +2 -0
- package/src/shared/ui/atoms/visibility/visibility.styles.ts +85 -0
- package/src/shared/ui/atoms/visibility/visibility.tsx +61 -0
- package/src/shared/ui/atoms/visibility/visibility.types.ts +34 -0
- package/src/shared/ui/molecules/keyboard-area/keyboard-area.styles.ts +11 -9
- package/src/shared/ui/molecules/keyboard-area/keyboard-area.tsx +3 -6
- package/src/shared/ui/molecules/refresh-control/refresh-control.tsx +3 -5
- package/src/shared/ui/molecules/refresh-control/refresh-control.types.ts +1 -1
- package/src/shared/ui/molecules/slider/components/indicator/components/dot/dot.styles.ts +41 -0
- package/src/shared/ui/molecules/slider/components/indicator/components/dot/dot.tsx +12 -0
- package/src/shared/ui/molecules/slider/components/indicator/components/dot/dot.types.ts +13 -0
- package/src/shared/ui/molecules/slider/components/indicator/components/dot/index.ts +2 -0
- package/src/shared/ui/molecules/slider/components/indicator/index.ts +2 -0
- package/src/shared/ui/molecules/slider/components/indicator/indicator.styles.ts +20 -0
- package/src/shared/ui/molecules/slider/components/indicator/indicator.tsx +22 -0
- package/src/shared/ui/molecules/slider/components/indicator/indicator.types.ts +10 -0
- package/src/shared/ui/molecules/slider/index.ts +3 -0
- package/src/shared/ui/molecules/slider/slider.styles.ts +68 -0
- package/src/shared/ui/molecules/slider/slider.tsx +64 -0
- package/src/shared/ui/molecules/slider/slider.types.ts +28 -0
- package/src/shared/ui/organisms/bar/bar.styles.ts +100 -0
- package/src/shared/ui/organisms/bar/bar.tsx +89 -0
- package/src/shared/ui/organisms/bar/bar.types.ts +49 -0
- package/src/shared/ui/organisms/bar/index.ts +2 -0
- package/src/shared/ui/organisms/bar-tab/bar-tab.tsx +9 -0
- package/src/shared/ui/organisms/bar-tab/bar-tab.types.ts +5 -0
- package/src/shared/ui/organisms/bar-tab/components/index.ts +1 -0
- package/src/shared/ui/organisms/bar-tab/components/tab/index.ts +2 -0
- package/src/shared/ui/organisms/bar-tab/components/tab/tab.styles.ts +21 -0
- package/src/shared/ui/organisms/bar-tab/components/tab/tab.tsx +18 -0
- package/src/shared/ui/organisms/bar-tab/components/tab/tab.types.ts +5 -0
- package/src/shared/ui/organisms/bar-tab/index.ts +2 -0
- package/src/shared/ui/organisms/bar-tab-navigation/bar-tab-navigation.styles.ts +22 -0
- package/src/shared/ui/organisms/bar-tab-navigation/bar-tab-navigation.tsx +66 -0
- package/src/shared/ui/organisms/bar-tab-navigation/bar-tab-navigation.types.ts +5 -0
- package/src/shared/ui/organisms/bar-tab-navigation/components/index.ts +1 -0
- package/src/shared/ui/organisms/bar-tab-navigation/components/tab-navigation/index.ts +2 -0
- package/src/shared/ui/organisms/bar-tab-navigation/components/tab-navigation/tab-navigation.styles.ts +56 -0
- package/src/shared/ui/organisms/bar-tab-navigation/components/tab-navigation/tab-navigation.tsx +30 -0
- package/src/shared/ui/organisms/bar-tab-navigation/components/tab-navigation/tab-navigation.types.ts +7 -0
- package/src/shared/ui/organisms/bar-tab-navigation/index.ts +2 -0
- package/src/shared/ui/organisms/index.ts +4 -1
- package/src/shared/ui/organisms/slider/components/indicator/components/dot/dot.styles.ts +41 -0
- package/src/shared/ui/organisms/slider/components/indicator/components/dot/dot.tsx +12 -0
- package/src/shared/ui/organisms/slider/components/indicator/components/dot/dot.types.ts +13 -0
- package/src/shared/ui/organisms/slider/components/indicator/components/dot/index.ts +2 -0
- package/src/shared/ui/organisms/slider/components/indicator/index.ts +2 -0
- package/src/shared/ui/organisms/slider/components/indicator/indicator.styles.ts +20 -0
- package/src/shared/ui/organisms/slider/components/indicator/indicator.tsx +22 -0
- package/src/shared/ui/organisms/slider/components/indicator/indicator.types.ts +10 -0
- package/src/shared/ui/organisms/slider/index.ts +3 -0
- package/src/shared/ui/organisms/slider/slider.styles.ts +68 -0
- package/src/shared/ui/organisms/slider/slider.tsx +64 -0
- package/src/shared/ui/organisms/slider/slider.types.ts +28 -0
- package/src/shared/ui/templates/index.ts +3 -0
- package/src/shared/ui/templates/modal-container/index.ts +13 -0
- package/src/shared/ui/templates/modal-container/modal-container-list.tsx +45 -0
- package/src/shared/ui/templates/modal-container/modal-container-scroll.tsx +66 -0
- package/src/shared/ui/templates/modal-container/modal-container-section-list.tsx +46 -0
- package/src/shared/ui/templates/modal-container/modal-container.hooks.tsx +172 -0
- package/src/shared/ui/templates/modal-container/modal-container.styles.ts +121 -0
- package/src/shared/ui/templates/modal-container/modal-container.types.ts +69 -0
- package/src/shared/ui/templates/screen-container/index.ts +1 -1
- package/src/shared/ui/templates/screen-container/screen-container-list.tsx +28 -10
- package/src/shared/ui/templates/screen-container/screen-container-scroll.tsx +28 -10
- package/src/shared/ui/templates/screen-container/screen-container-section-list.tsx +29 -11
- package/src/shared/ui/templates/screen-container/screen-container.hooks.tsx +79 -8
- package/src/shared/ui/templates/screen-container/screen-container.styles.ts +105 -15
- package/src/shared/ui/templates/screen-container/screen-container.types.tsx +34 -7
- package/src/shared/ui/templates/screen-header/components/index.ts +6 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-description/index.ts +2 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-description/screen-header-description.tsx +15 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-description/screen-header-description.types.ts +11 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-icon/index.ts +2 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-icon/screen-header-icon.styles.ts +44 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-icon/screen-header-icon.tsx +65 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-icon/screen-header-icon.types.ts +14 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-icon-back/index.ts +2 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-icon-back/screen-header-icon-back.tsx +17 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-icon-back/screen-header-icon-back.types.ts +6 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-icon-close/index.ts +2 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-icon-close/screen-header-icon-close.tsx +27 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-icon-close/screen-header-icon-close.types.ts +10 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-info/index.ts +2 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-info/screen-header-info.tsx +15 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-info/screen-header-info.types.ts +10 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-title/index.ts +2 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-title/screen-header-title.tsx +19 -0
- package/src/shared/ui/templates/screen-header/components/screen-header-title/screen-header-title.types.ts +13 -0
- package/src/shared/ui/templates/screen-header/index.ts +3 -0
- package/src/shared/ui/templates/screen-header/screen-header.styles.ts +49 -0
- package/src/shared/ui/templates/screen-header/screen-header.tsx +26 -0
- package/src/shared/ui/templates/screen-header/screen-header.types.ts +15 -0
- package/src/shared/ui/templates/web-container/index.ts +2 -0
- package/src/shared/ui/templates/web-container/web-container.styles.ts +34 -0
- package/src/shared/ui/templates/web-container/web-container.tsx +172 -0
- package/src/shared/ui/templates/web-container/web-container.types.ts +21 -0
- package/.claude/rules/app-routing.mdc +0 -47
- package/.claude/rules/exports-at-end.mdc +0 -55
- package/.claude/rules/kebab-case-naming.mdc +0 -29
- package/.claude/rules/mediacubeco-packages.mdc +0 -56
- package/.claude/skills/generate-api-model/SKILL.md +0 -230
- package/.claude/skills/generate-api-model/references/resources/common.ts +0 -8
- package/.claude/skills/generate-api-model-mock/SKILL.md +0 -56
- package/.claude/skills/git-commit/SKILL.md +0 -139
- package/.gitignore +0 -34
- package/src/shared/assets/icons/like.tsx +0 -17
- package/src/shared/hooks/use-animated.ts +0 -200
- package/src/shared/hooks/use-mixins.ts +0 -36
- package/src/shared/hooks/use-safe-area.ts +0 -75
- package/src/shared/lib/api/repositories/auth/auth.ts +0 -23
- package/src/shared/lib/api/repositories/auth/auth.types.ts +0 -22
- package/src/shared/lib/api/repositories/auth/index.ts +0 -1
- package/src/shared/lib/navigation/hooks/use-navigation-native-tabs.ts +0 -10
- package/src/shared/lib/navigation/hooks/use-navigation-options.ts +0 -123
- package/src/shared/lib/navigation/navigation-native-tabs.context.tsx +0 -5
- package/src/shared/lib/navigation/navigation-native-tabs.provider.tsx +0 -12
- package/src/shared/lib/theme/constants/borders.ts +0 -8
- package/src/shared/lib/theme/constants/weights.ts +0 -13
- /package/.claude/skills/{generate-api-model/references → api/references/model}/entities/index.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/entities/post/index.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/entities/post/post-comment.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/entities/post/post.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/entities/user/index.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/entities/user/user-settings.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/entities/user/user-verification.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/entities/user/user.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/resources/index.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/resources/post/index.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/resources/post/post-comment.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/resources/post/post.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/resources/user/index.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/resources/user/user-settings.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/resources/user/user-verification.ts +0 -0
- /package/.claude/skills/{generate-api-model/references → api/references/model}/resources/user/user.ts +0 -0
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
diff --git a/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenStackFragment.kt b/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenStackFragment.kt
|
|
2
|
+
index 7aee121..9a3cc9b 100644
|
|
3
|
+
--- a/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenStackFragment.kt
|
|
4
|
+
+++ b/node_modules/react-native-screens/android/src/main/java/com/swmansion/rnscreens/ScreenStackFragment.kt
|
|
5
|
+
@@ -388,7 +388,7 @@ class ScreenStackFragment :
|
|
6
|
+
return sheetDelegate.createSheetExitAnimator(sheetAnimationContext)
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
- private fun createBottomSheetBehaviour(): BottomSheetBehavior<Screen> = BottomSheetBehavior<Screen>()
|
|
10
|
+
+ private fun createBottomSheetBehaviour(): BottomSheetBehavior<Screen> = ScrollAwareSheetBehavior<Screen>()
|
|
11
|
+
|
|
12
|
+
private fun resolveBackgroundColor(screen: Screen): Int? {
|
|
13
|
+
val screenColor =
|
|
14
|
+
@@ -596,3 +596,48 @@ class ScreenStackFragment :
|
|
15
|
+
return bottomSheetWindowInsetListenerChain!!
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
+
|
|
19
|
+
+/**
|
|
20
|
+
+ * PATCHED (app-local): BottomSheetBehavior which hands the sheet over to a downward
|
|
21
|
+
+ * nested-scroll gesture only if that gesture started with the content already scrolled to the
|
|
22
|
+
+ * top. A drag that begins on scrolled-away content spends its full travel inside the scroll
|
|
23
|
+
+ * view (matching the iOS sheet behavior), so the sheet cannot be dismissed accidentally while
|
|
24
|
+
+ * scrolling the content up — dismissal requires a fresh swipe started at the top.
|
|
25
|
+
+ */
|
|
26
|
+
+private class ScrollAwareSheetBehavior<T : View> : BottomSheetBehavior<T>() {
|
|
27
|
+
+ private var canDragDownFromNestedScroll = true
|
|
28
|
+
+
|
|
29
|
+
+ override fun onStartNestedScroll(
|
|
30
|
+
+ coordinatorLayout: CoordinatorLayout,
|
|
31
|
+
+ child: T,
|
|
32
|
+
+ directTargetChild: View,
|
|
33
|
+
+ target: View,
|
|
34
|
+
+ axes: Int,
|
|
35
|
+
+ type: Int,
|
|
36
|
+
+ ): Boolean {
|
|
37
|
+
+ if (type == ViewCompat.TYPE_TOUCH) {
|
|
38
|
+
+ canDragDownFromNestedScroll = !target.canScrollVertically(-1)
|
|
39
|
+
+ }
|
|
40
|
+
+ return super.onStartNestedScroll(coordinatorLayout, child, directTargetChild, target, axes, type)
|
|
41
|
+
+ }
|
|
42
|
+
+
|
|
43
|
+
+ override fun onNestedPreScroll(
|
|
44
|
+
+ coordinatorLayout: CoordinatorLayout,
|
|
45
|
+
+ child: T,
|
|
46
|
+
+ target: View,
|
|
47
|
+
+ dx: Int,
|
|
48
|
+
+ dy: Int,
|
|
49
|
+
+ consumed: IntArray,
|
|
50
|
+
+ type: Int,
|
|
51
|
+
+ ) {
|
|
52
|
+
+ if (type == ViewCompat.TYPE_TOUCH && target.canScrollVertically(-1)) {
|
|
53
|
+
+ // Контент прокручен внутри жеста — жест теряет право таскать лист до конца касания.
|
|
54
|
+
+ canDragDownFromNestedScroll = false
|
|
55
|
+
+ }
|
|
56
|
+
+ if (dy < 0 && !canDragDownFromNestedScroll && !target.canScrollVertically(-1)) {
|
|
57
|
+
+ // Глотаем handoff вниз: лист стоит на месте, контент показывает overscroll.
|
|
58
|
+
+ return
|
|
59
|
+
+ }
|
|
60
|
+
+ super.onNestedPreScroll(coordinatorLayout, child, target, dx, dy, consumed, type)
|
|
61
|
+
+ }
|
|
62
|
+
+}
|
|
63
|
+
diff --git a/node_modules/react-native-screens/ios/RNSScreen.mm b/node_modules/react-native-screens/ios/RNSScreen.mm
|
|
64
|
+
index 69d4d9a..7dd6164 100644
|
|
65
|
+
--- a/node_modules/react-native-screens/ios/RNSScreen.mm
|
|
66
|
+
+++ b/node_modules/react-native-screens/ios/RNSScreen.mm
|
|
67
|
+
@@ -191,6 +191,27 @@ RNS_IGNORE_SUPER_CALL_END
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
+// PATCHED (app-local): the frame correction below assumes the sheet's ScrollView is meant
|
|
72
|
+
+// to span the whole sheet. When the developer deliberately lays the scroll view out below
|
|
73
|
+
+// other in-flow content (e.g. an in-flow header), forcing the sheet frame onto it shifts
|
|
74
|
+
+// the content under that header and leaves an empty track at the bottom.
|
|
75
|
+
+//
|
|
76
|
+
+// The correction exists to keep the scroll view viewport in sync while the sheet resizes
|
|
77
|
+
+// (multiple detents / fitToContents), because for form sheets the JS side is deliberately
|
|
78
|
+
+// not notified about height changes. A sheet with a single fixed detent never resizes, so
|
|
79
|
+
+// for such sheets the correction is unnecessary — skip it when the developer also placed
|
|
80
|
+
+// in-flow content above the scroll view, and let React own the scroll view frame instead.
|
|
81
|
+
+- (BOOL)rnsAppShouldSkipFrameCorrectionForScrollView:(nonnull UIView *)scrollView
|
|
82
|
+
+{
|
|
83
|
+
+ const BOOL hasSingleFixedDetent =
|
|
84
|
+
+ _sheetAllowedDetents.count == 1 && _sheetAllowedDetents[0].intValue != SHEET_FIT_TO_CONTENTS;
|
|
85
|
+
+ if (!hasSingleFixedDetent || scrollView.superview == nil) {
|
|
86
|
+
+ return NO;
|
|
87
|
+
+ }
|
|
88
|
+
+ const CGPoint originInScreen = [scrollView.superview convertPoint:scrollView.frame.origin toView:self];
|
|
89
|
+
+ return originInScreen.y > 0.5;
|
|
90
|
+
+}
|
|
91
|
+
+
|
|
92
|
+
- (void)applyFrameCorrectionForDescendantScrollView
|
|
93
|
+
{
|
|
94
|
+
RNS_REACT_SCROLL_VIEW_COMPONENT *scrollView = [self tryFindDescendantScrollView];
|
|
95
|
+
@@ -210,6 +231,11 @@ RNS_IGNORE_SUPER_CALL_END
|
|
96
|
+
- (void)correctScrollViewFrame:(nonnull RNS_REACT_SCROLL_VIEW_COMPONENT *)scrollViewComponent
|
|
97
|
+
withHeader:(nullable UIView *)headerView
|
|
98
|
+
{
|
|
99
|
+
+ // PATCHED (app-local): respect React layout for scroll views placed below in-flow content.
|
|
100
|
+
+ if ([self rnsAppShouldSkipFrameCorrectionForScrollView:scrollViewComponent]) {
|
|
101
|
+
+ return;
|
|
102
|
+
+ }
|
|
103
|
+
+
|
|
104
|
+
RNSScreenContentWrapper *_Nullable contentWrapper = _contentWrapperBox.contentWrapper;
|
|
105
|
+
if (contentWrapper != nil && [contentWrapper coerceChildScrollViewComponentSizeToSize:self.frame.size]) {
|
|
106
|
+
return;
|
|
107
|
+
@@ -230,6 +256,11 @@ RNS_IGNORE_SUPER_CALL_END
|
|
108
|
+
return;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
+ // PATCHED (app-local): respect React layout for scroll views placed below in-flow content.
|
|
112
|
+
+ if ([self rnsAppShouldSkipFrameCorrectionForScrollView:scrollView]) {
|
|
113
|
+
+ return;
|
|
114
|
+
+ }
|
|
115
|
+
+
|
|
116
|
+
RNSScreenContentWrapper *_Nullable contentWrapper = _contentWrapperBox.contentWrapper;
|
|
117
|
+
if (contentWrapper != nil && [contentWrapper coerceChildScrollViewComponentSizeToSize:self.frame.size]) {
|
|
118
|
+
return;
|
package/react-query.d.ts
ADDED
|
@@ -2,11 +2,11 @@ import { Stack } from 'expo-router'
|
|
|
2
2
|
import { useLocalizationText, useNavigationStackOptions } from '~shared/lib'
|
|
3
3
|
|
|
4
4
|
const Layout = () => {
|
|
5
|
-
const {
|
|
5
|
+
const { stackOptions, createScreenOptions } = useNavigationStackOptions()
|
|
6
6
|
const t = useLocalizationText()
|
|
7
7
|
|
|
8
8
|
return (
|
|
9
|
-
<Stack screenOptions={
|
|
9
|
+
<Stack screenOptions={stackOptions}>
|
|
10
10
|
<Stack.Screen name={'index'} options={createScreenOptions({ title: t('home.title') })} />
|
|
11
11
|
</Stack>
|
|
12
12
|
)
|
|
@@ -2,11 +2,11 @@ import { Stack } from 'expo-router'
|
|
|
2
2
|
import { useLocalizationText, useNavigationStackOptions } from '~shared/lib'
|
|
3
3
|
|
|
4
4
|
const Layout = () => {
|
|
5
|
-
const {
|
|
5
|
+
const { stackOptions, createScreenOptions } = useNavigationStackOptions()
|
|
6
6
|
const t = useLocalizationText()
|
|
7
7
|
|
|
8
8
|
return (
|
|
9
|
-
<Stack screenOptions={
|
|
9
|
+
<Stack screenOptions={stackOptions}>
|
|
10
10
|
<Stack.Screen name={'index'} options={createScreenOptions({ title: t('settings.title') })} />
|
|
11
11
|
</Stack>
|
|
12
12
|
)
|
|
@@ -1,44 +1,47 @@
|
|
|
1
|
+
import { isGlassEffectAPIAvailable } from 'expo-glass-effect'
|
|
2
|
+
import { Tabs } from 'expo-router'
|
|
1
3
|
import { NativeTabs } from 'expo-router/build/native-tabs'
|
|
2
4
|
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
+
NavigationTabsNativeProvider,
|
|
6
|
+
NavigationTabsProvider,
|
|
7
|
+
useNavigationTabBarNativeOptions,
|
|
5
8
|
useNavigationTabBarOptions,
|
|
6
9
|
} from '~shared/lib'
|
|
10
|
+
import { BarTabNavigation } from '~shared/ui'
|
|
7
11
|
|
|
8
12
|
const Layout = () => {
|
|
9
|
-
const { createTabBarOptions
|
|
10
|
-
const
|
|
13
|
+
const { createTabBarOptions } = useNavigationTabBarOptions(BarTabNavigation)
|
|
14
|
+
const { createTabBarNativeOptions } = useNavigationTabBarNativeOptions()
|
|
11
15
|
|
|
12
|
-
|
|
16
|
+
if (isGlassEffectAPIAvailable()) {
|
|
17
|
+
const tabBarNativeOptions = createTabBarNativeOptions()
|
|
13
18
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
return (
|
|
20
|
+
<NavigationTabsNativeProvider>
|
|
21
|
+
<NativeTabs {...tabBarNativeOptions}>
|
|
22
|
+
<NativeTabs.Trigger name={'(home)'}>
|
|
23
|
+
<NativeTabs.Trigger.Label>{'home'}</NativeTabs.Trigger.Label>
|
|
24
|
+
<NativeTabs.Trigger.Icon sf={'house'} md={'home'} />
|
|
25
|
+
</NativeTabs.Trigger>
|
|
26
|
+
<NativeTabs.Trigger name={'(settings)'}>
|
|
27
|
+
<NativeTabs.Trigger.Label>{'home'}</NativeTabs.Trigger.Label>
|
|
28
|
+
<NativeTabs.Trigger.Icon sf={'gear'} md={'settings'} />
|
|
29
|
+
</NativeTabs.Trigger>
|
|
30
|
+
</NativeTabs>
|
|
31
|
+
</NavigationTabsNativeProvider>
|
|
32
|
+
)
|
|
33
|
+
} else {
|
|
34
|
+
const tabBarOptions = createTabBarOptions()
|
|
20
35
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
<NativeTabs {...tabBarOptions}>
|
|
31
|
-
<NativeTabs.Trigger {...homeTabOptions.triggerProps}>
|
|
32
|
-
<NativeTabs.Trigger.Label {...homeTabOptions.triggerLabelProps} />
|
|
33
|
-
<NativeTabs.Trigger.Icon {...homeTabOptions.triggerIconProps} />
|
|
34
|
-
</NativeTabs.Trigger>
|
|
35
|
-
<NativeTabs.Trigger {...settingsTabOptions.triggerProps}>
|
|
36
|
-
<NativeTabs.Trigger.Label {...settingsTabOptions.triggerLabelProps} />
|
|
37
|
-
<NativeTabs.Trigger.Icon {...settingsTabOptions.triggerIconProps} />
|
|
38
|
-
</NativeTabs.Trigger>
|
|
39
|
-
</NativeTabs>
|
|
40
|
-
</NavigationNativeTabsProvider>
|
|
41
|
-
)
|
|
36
|
+
return (
|
|
37
|
+
<NavigationTabsProvider>
|
|
38
|
+
<Tabs {...tabBarOptions}>
|
|
39
|
+
<Tabs.Screen name={'(home)'} options={{ title: 'home' }} />
|
|
40
|
+
<Tabs.Screen name={'(settings)'} options={{ title: 'settings' }} />
|
|
41
|
+
</Tabs>
|
|
42
|
+
</NavigationTabsProvider>
|
|
43
|
+
)
|
|
44
|
+
}
|
|
42
45
|
}
|
|
43
46
|
|
|
44
47
|
export default Layout
|
|
@@ -1,16 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { ScreenContainerScroll } from '~shared/ui'
|
|
1
|
+
import { useLocalizationText } from '~shared/lib'
|
|
2
|
+
import { ScreenContainerScroll, Text } from '~shared/ui'
|
|
4
3
|
|
|
5
4
|
const HomeMain = () => {
|
|
6
5
|
const t = useLocalizationText()
|
|
7
|
-
const { COLORS } = useThemeMode()
|
|
8
6
|
|
|
9
7
|
return (
|
|
10
8
|
<ScreenContainerScroll>
|
|
11
|
-
<Text
|
|
12
|
-
{t('home.description')}
|
|
13
|
-
</Text>
|
|
9
|
+
<Text type={'h1'}>{t('home.description')}</Text>
|
|
14
10
|
</ScreenContainerScroll>
|
|
15
11
|
)
|
|
16
12
|
}
|
|
@@ -1,16 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { ScreenContainerScroll } from '~shared/ui/templates'
|
|
1
|
+
import { useLocalizationText } from '~shared/lib'
|
|
2
|
+
import { ScreenContainerScroll, Text } from '~shared/ui'
|
|
4
3
|
|
|
5
4
|
const SettingsMain = () => {
|
|
6
5
|
const t = useLocalizationText()
|
|
7
|
-
const { COLORS } = useThemeMode()
|
|
8
6
|
|
|
9
7
|
return (
|
|
10
8
|
<ScreenContainerScroll>
|
|
11
|
-
<Text
|
|
12
|
-
{t('settings.description')}
|
|
13
|
-
</Text>
|
|
9
|
+
<Text type={'h1'}>{t('home.description')}</Text>
|
|
14
10
|
</ScreenContainerScroll>
|
|
15
11
|
)
|
|
16
12
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
const FONTS = {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
BASE_REGULAR: require('./sf-pro-text-regular.ttf'),
|
|
3
|
+
BASE_SEMIBOLD: require('./sf-pro-text-semibold.ttf'),
|
|
4
|
+
BASE_BOLD: require('./sf-pro-text-bold.ttf'),
|
|
5
5
|
}
|
|
6
6
|
|
|
7
7
|
export { FONTS }
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Svg } from 'react-native-svg'
|
|
2
|
+
import { AnimatedPath } from './common'
|
|
3
|
+
import { type IconProps } from './type'
|
|
4
|
+
|
|
5
|
+
/** Иконка стрелки назад (влево). */
|
|
6
|
+
const Back = ({ ref, style, size, color, animatedProps }: IconProps) => {
|
|
7
|
+
return (
|
|
8
|
+
<Svg ref={ref} width={size} height={size} viewBox={'0 0 24 24'} fill={'none'} style={style}>
|
|
9
|
+
<AnimatedPath
|
|
10
|
+
d={'M20 12.01L4 12.01M10.3904 6L4.00748 12L10.3904 18'}
|
|
11
|
+
stroke={color}
|
|
12
|
+
strokeWidth={1.5}
|
|
13
|
+
strokeLinecap={'round'}
|
|
14
|
+
strokeLinejoin={'round'}
|
|
15
|
+
animatedProps={animatedProps}
|
|
16
|
+
/>
|
|
17
|
+
</Svg>
|
|
18
|
+
)
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export default Back
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Svg } from 'react-native-svg'
|
|
2
|
+
import { AnimatedPath } from './common'
|
|
3
|
+
import { type IconProps } from './type'
|
|
4
|
+
|
|
5
|
+
/** Иконка крестика (закрыть). */
|
|
6
|
+
const Close = ({ ref, style, size, color, animatedProps }: IconProps) => {
|
|
7
|
+
return (
|
|
8
|
+
<Svg ref={ref} width={size} height={size} viewBox={'0 0 24 24'} fill={'none'} style={style}>
|
|
9
|
+
<AnimatedPath
|
|
10
|
+
d={'M7 7L17 17M17 7L7 17'}
|
|
11
|
+
stroke={color}
|
|
12
|
+
strokeWidth={1.5}
|
|
13
|
+
strokeLinecap={'round'}
|
|
14
|
+
strokeLinejoin={'round'}
|
|
15
|
+
animatedProps={animatedProps}
|
|
16
|
+
/>
|
|
17
|
+
</Svg>
|
|
18
|
+
)
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export default Close
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { Svg } from 'react-native-svg'
|
|
2
|
+
import { AnimatedPath, AnimatedRect } from './common'
|
|
3
|
+
import { type IconProps } from './type'
|
|
4
|
+
|
|
5
|
+
const Default = ({ ref, style, size, color, animatedProps }: IconProps) => {
|
|
6
|
+
return (
|
|
7
|
+
<Svg ref={ref} width={size} height={size} viewBox={'0 0 24 24'} fill={'none'} style={style}>
|
|
8
|
+
<AnimatedRect
|
|
9
|
+
x={3}
|
|
10
|
+
y={4}
|
|
11
|
+
width={18}
|
|
12
|
+
height={16}
|
|
13
|
+
rx={2}
|
|
14
|
+
stroke={color}
|
|
15
|
+
strokeWidth={1.8}
|
|
16
|
+
animatedProps={animatedProps as any}
|
|
17
|
+
/>
|
|
18
|
+
<AnimatedPath
|
|
19
|
+
d={'M4 17L8 13L11 16L14 13L20 19'}
|
|
20
|
+
stroke={color}
|
|
21
|
+
strokeWidth={1.8}
|
|
22
|
+
strokeLinecap={'round'}
|
|
23
|
+
strokeLinejoin={'round'}
|
|
24
|
+
animatedProps={animatedProps}
|
|
25
|
+
/>
|
|
26
|
+
<AnimatedPath
|
|
27
|
+
d={'M15 9.5H15.01'}
|
|
28
|
+
stroke={color}
|
|
29
|
+
strokeWidth={2.2}
|
|
30
|
+
strokeLinecap={'round'}
|
|
31
|
+
animatedProps={animatedProps}
|
|
32
|
+
/>
|
|
33
|
+
<AnimatedPath
|
|
34
|
+
d={'M5 5L19 19'}
|
|
35
|
+
stroke={color}
|
|
36
|
+
strokeWidth={1.8}
|
|
37
|
+
strokeLinecap={'round'}
|
|
38
|
+
animatedProps={animatedProps}
|
|
39
|
+
/>
|
|
40
|
+
</Svg>
|
|
41
|
+
)
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export default Default
|
|
@@ -1,3 +1,15 @@
|
|
|
1
|
-
|
|
1
|
+
import back from './back.tsx'
|
|
2
|
+
import close from './close.tsx'
|
|
3
|
+
import DEFAULT from './default.tsx'
|
|
4
|
+
import refresh from './refresh.tsx'
|
|
5
|
+
import share from './share.tsx'
|
|
6
|
+
|
|
7
|
+
const ICONS = {
|
|
8
|
+
back,
|
|
9
|
+
close,
|
|
10
|
+
refresh,
|
|
11
|
+
share,
|
|
12
|
+
default: DEFAULT,
|
|
13
|
+
}
|
|
2
14
|
|
|
3
15
|
export { ICONS }
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { Svg } from 'react-native-svg'
|
|
2
|
+
import { AnimatedPath } from './common'
|
|
3
|
+
import { type IconProps } from './type'
|
|
4
|
+
|
|
5
|
+
/** Иконка обновления (круговая стрелка). */
|
|
6
|
+
const Refresh = ({ ref, style, size, color, animatedProps }: IconProps) => {
|
|
7
|
+
return (
|
|
8
|
+
<Svg ref={ref} width={size} height={size} viewBox={'0 0 24 24'} fill={'none'} style={style}>
|
|
9
|
+
<AnimatedPath
|
|
10
|
+
d={
|
|
11
|
+
'M20 12C20 16.4183 16.4183 20 12 20C7.58172 20 4 16.4183 4 12C4 7.58172 7.58172 4 12 4C14.9611 4 17.6168 5.60879 19 8M19 4V8H15'
|
|
12
|
+
}
|
|
13
|
+
stroke={color}
|
|
14
|
+
strokeWidth={1.5}
|
|
15
|
+
strokeLinecap={'round'}
|
|
16
|
+
strokeLinejoin={'round'}
|
|
17
|
+
animatedProps={animatedProps}
|
|
18
|
+
/>
|
|
19
|
+
</Svg>
|
|
20
|
+
)
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export default Refresh
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { Svg } from 'react-native-svg'
|
|
2
|
+
import { AnimatedPath } from './common'
|
|
3
|
+
import { type IconProps } from './type'
|
|
4
|
+
|
|
5
|
+
const Share = ({ ref, style, size, color, animatedProps }: IconProps) => {
|
|
6
|
+
return (
|
|
7
|
+
<Svg ref={ref} width={size} height={size} viewBox={'0 0 24 24'} fill={'none'} style={style}>
|
|
8
|
+
<AnimatedPath
|
|
9
|
+
d={
|
|
10
|
+
'M8 10H7C5.89543 10 5 10.8954 5 12V19C5 20.1046 5.89543 21 7 21H17C18.1046 21 19 20.1046 19 19V12C19 10.8954 18.1046 10 17 10H16'
|
|
11
|
+
}
|
|
12
|
+
stroke={color}
|
|
13
|
+
strokeWidth={1.5}
|
|
14
|
+
strokeLinecap={'round'}
|
|
15
|
+
strokeLinejoin={'round'}
|
|
16
|
+
animatedProps={animatedProps}
|
|
17
|
+
/>
|
|
18
|
+
<AnimatedPath
|
|
19
|
+
d={'M12 14V3'}
|
|
20
|
+
stroke={color}
|
|
21
|
+
strokeWidth={1.5}
|
|
22
|
+
strokeLinecap={'round'}
|
|
23
|
+
strokeLinejoin={'round'}
|
|
24
|
+
animatedProps={animatedProps}
|
|
25
|
+
/>
|
|
26
|
+
<AnimatedPath
|
|
27
|
+
d={'M8.5 6.5L12 3L15.5 6.5'}
|
|
28
|
+
stroke={color}
|
|
29
|
+
strokeWidth={1.5}
|
|
30
|
+
strokeLinecap={'round'}
|
|
31
|
+
strokeLinejoin={'round'}
|
|
32
|
+
animatedProps={animatedProps}
|
|
33
|
+
/>
|
|
34
|
+
</Svg>
|
|
35
|
+
)
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export default Share
|
|
@@ -1,6 +1,13 @@
|
|
|
1
|
+
import { type Ref } from 'react'
|
|
2
|
+
import type Svg from 'react-native-svg'
|
|
3
|
+
import { type SvgProps } from 'react-native-svg'
|
|
4
|
+
|
|
1
5
|
type IconProps = {
|
|
6
|
+
ref?: Ref<Svg>
|
|
7
|
+
style?: SvgProps['style']
|
|
2
8
|
size?: number
|
|
3
9
|
color?: string
|
|
10
|
+
animatedProps?: SvgProps
|
|
4
11
|
}
|
|
5
12
|
|
|
6
13
|
export type { IconProps }
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { type NotNullable } from '@mediacubeco/base/types'
|
|
2
|
+
import { isArray } from '@mediacubeco/base/utils'
|
|
3
|
+
import Constants, { type NativeConstants } from 'expo-constants'
|
|
4
|
+
|
|
5
|
+
const { scheme } = Constants.expoConfig ?? ({} as NotNullable<NativeConstants['expoConfig']>)
|
|
6
|
+
|
|
7
|
+
const APP_SCHEME = isArray(scheme) ? scheme[0] : scheme
|
|
8
|
+
|
|
9
|
+
if (!APP_SCHEME) {
|
|
10
|
+
throw new Error('APP_SCHEME is not set')
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export { APP_SCHEME }
|
|
@@ -1,7 +1,19 @@
|
|
|
1
|
-
const
|
|
1
|
+
const APP_URL = process.env.EXPO_PUBLIC_APP_URL
|
|
2
2
|
|
|
3
|
-
if (!
|
|
4
|
-
throw new Error(`
|
|
3
|
+
if (!APP_URL || !APP_URL.startsWith('https://')) {
|
|
4
|
+
throw new Error(`APP_URL is invalid: ${APP_URL}`)
|
|
5
5
|
}
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
const APP_URL_API = process.env.EXPO_PUBLIC_APP_URL_API
|
|
8
|
+
|
|
9
|
+
if (!APP_URL_API || !APP_URL_API.startsWith('https://')) {
|
|
10
|
+
throw new Error(`APP_URL_API is invalid: ${APP_URL_API}`)
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
const APP_ID_STORAGE = process.env.EXPO_PUBLIC_APP_ID_STORAGE
|
|
14
|
+
|
|
15
|
+
if (!APP_ID_STORAGE) {
|
|
16
|
+
throw new Error(`APP_ID_STORAGE is invalid: ${APP_ID_STORAGE}`)
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
export { APP_URL, APP_URL_API, APP_ID_STORAGE }
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { type Nullable } from '@mediacubeco/base/types'
|
|
2
|
+
import { type RefObject, useRef } from 'react'
|
|
3
|
+
import { type SharedValue, useSharedValue } from 'react-native-reanimated'
|
|
4
|
+
|
|
5
|
+
const useComposeRef = <Ref, InitValue extends Ref = Ref>(
|
|
6
|
+
ref: Nullable<RefObject<Ref>>,
|
|
7
|
+
initValue: InitValue = null as InitValue
|
|
8
|
+
) => {
|
|
9
|
+
const defaultRef = useRef<Ref>(initValue)
|
|
10
|
+
|
|
11
|
+
return ref && 'current' in ref ? ref : defaultRef
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
const useComposeSharedValue = <Value, InitValue extends Value = Value>(
|
|
15
|
+
value: Nullable<SharedValue<Value>>,
|
|
16
|
+
initValue: InitValue = 0 as InitValue
|
|
17
|
+
) => {
|
|
18
|
+
const defaultValue = useSharedValue<Value>(initValue)
|
|
19
|
+
|
|
20
|
+
return value && 'value' in value ? value : defaultValue
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export { useComposeRef, useComposeSharedValue }
|