@armoyu/ui 1.0.1 → 1.0.3

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.
Files changed (239) hide show
  1. package/dist/app/Providers.d.ts +6 -0
  2. package/dist/app/Providers.d.ts.map +1 -0
  3. package/dist/app/Providers.js +37 -0
  4. package/dist/app/Providers.js.map +1 -0
  5. package/dist/app/api/proxy/[...path]/route.d.ts +22 -0
  6. package/dist/app/api/proxy/[...path]/route.d.ts.map +1 -0
  7. package/dist/app/api/proxy/[...path]/route.js +97 -0
  8. package/dist/app/api/proxy/[...path]/route.js.map +1 -0
  9. package/dist/app/layout.d.ts.map +1 -1
  10. package/dist/app/layout.js +16 -23
  11. package/dist/app/layout.js.map +1 -1
  12. package/dist/components/RollingNumber.d.ts +6 -6
  13. package/dist/components/RollingNumber.js +23 -23
  14. package/dist/components/RollingNumber.js.map +1 -1
  15. package/dist/components/StatsGrid.d.ts +5 -5
  16. package/dist/components/modules/auth/Dashboard.d.ts +1 -1
  17. package/dist/components/modules/auth/PostCard.d.ts +25 -24
  18. package/dist/components/modules/auth/PostCard.d.ts.map +1 -1
  19. package/dist/components/modules/auth/PostCard.js +115 -112
  20. package/dist/components/modules/auth/PostCard.js.map +1 -1
  21. package/dist/components/modules/auth/PostInteractionsModal.d.ts +11 -11
  22. package/dist/components/modules/auth/RepostModal.d.ts +21 -21
  23. package/dist/components/modules/auth/SidebarLeft.d.ts +1 -1
  24. package/dist/components/modules/auth/SidebarLeft.d.ts.map +1 -1
  25. package/dist/components/modules/auth/SidebarLeft.js +8 -40
  26. package/dist/components/modules/auth/SidebarLeft.js.map +1 -1
  27. package/dist/components/modules/auth/Stories.d.ts +1 -1
  28. package/dist/components/modules/auth/StoryViewer.d.ts +9 -9
  29. package/dist/components/modules/auth/widgets/EconomyWidget.d.ts +2 -0
  30. package/dist/components/modules/auth/widgets/EconomyWidget.d.ts.map +1 -0
  31. package/dist/components/modules/auth/widgets/EconomyWidget.js +38 -0
  32. package/dist/components/modules/auth/widgets/EconomyWidget.js.map +1 -0
  33. package/dist/components/modules/auth/widgets/LeagueWidget.d.ts +2 -0
  34. package/dist/components/modules/auth/widgets/LeagueWidget.d.ts.map +1 -0
  35. package/dist/components/modules/auth/widgets/LeagueWidget.js +36 -0
  36. package/dist/components/modules/auth/widgets/LeagueWidget.js.map +1 -0
  37. package/dist/components/modules/auth/widgets/MinecraftWidget.d.ts +2 -0
  38. package/dist/components/modules/auth/widgets/MinecraftWidget.d.ts.map +1 -0
  39. package/dist/components/modules/auth/widgets/MinecraftWidget.js +36 -0
  40. package/dist/components/modules/auth/widgets/MinecraftWidget.js.map +1 -0
  41. package/dist/components/modules/auth/widgets/RankingWidget.d.ts +5 -0
  42. package/dist/components/modules/auth/widgets/RankingWidget.d.ts.map +1 -0
  43. package/dist/components/modules/auth/widgets/RankingWidget.js +79 -0
  44. package/dist/components/modules/auth/widgets/RankingWidget.js.map +1 -0
  45. package/dist/components/modules/chat/ChatContainer.d.ts +1 -1
  46. package/dist/components/modules/chat/ChatInput.d.ts +4 -4
  47. package/dist/components/modules/chat/ChatList.d.ts +6 -6
  48. package/dist/components/modules/chat/ChatNotes.d.ts +1 -1
  49. package/dist/components/modules/community/GroupHeader.d.ts +10 -10
  50. package/dist/components/modules/community/GroupMenu.d.ts +9 -9
  51. package/dist/components/modules/community/SchoolCard.d.ts +6 -6
  52. package/dist/components/modules/community/SurveyCard.d.ts +6 -6
  53. package/dist/components/modules/forum/ForumBoard.d.ts +16 -16
  54. package/dist/components/modules/forum/ForumBoard.js +6 -6
  55. package/dist/components/modules/forum/ForumBoard.js.map +1 -1
  56. package/dist/components/modules/forum/TopicItem.d.ts +15 -15
  57. package/dist/components/modules/forum/TopicItem.js +6 -6
  58. package/dist/components/modules/forum/TopicItem.js.map +1 -1
  59. package/dist/components/modules/guest/Introduction.d.ts +1 -1
  60. package/dist/components/modules/magaza/BackToStore.d.ts +1 -1
  61. package/dist/components/modules/magaza/StoreHeader.d.ts +5 -5
  62. package/dist/components/modules/news/NewsCard.d.ts +11 -11
  63. package/dist/components/modules/news/NewsComments.d.ts +1 -1
  64. package/dist/components/modules/profile/ProfileContent.d.ts +4 -4
  65. package/dist/components/modules/profile/ProfileContent.d.ts.map +1 -1
  66. package/dist/components/modules/profile/ProfileContent.js +98 -70
  67. package/dist/components/modules/profile/ProfileContent.js.map +1 -1
  68. package/dist/components/modules/profile/ProfileHeader.d.ts +7 -7
  69. package/dist/components/modules/profile/ProfileHeader.js +19 -19
  70. package/dist/components/modules/profile/ProfileHeader.js.map +1 -1
  71. package/dist/components/modules/profile/ProfileStats.d.ts +6 -1
  72. package/dist/components/modules/profile/ProfileStats.d.ts.map +1 -1
  73. package/dist/components/modules/profile/ProfileStats.js +11 -6
  74. package/dist/components/modules/profile/ProfileStats.js.map +1 -1
  75. package/dist/components/modules/profile/TeamSelectorModal.d.ts +10 -10
  76. package/dist/components/modules/profile/tabs/AboutTab.d.ts +10 -0
  77. package/dist/components/modules/profile/tabs/AboutTab.d.ts.map +1 -0
  78. package/dist/components/modules/profile/tabs/AboutTab.js +9 -0
  79. package/dist/components/modules/profile/tabs/AboutTab.js.map +1 -0
  80. package/dist/components/modules/profile/tabs/CareerTab.d.ts +7 -0
  81. package/dist/components/modules/profile/tabs/CareerTab.d.ts.map +1 -0
  82. package/dist/components/modules/profile/tabs/CareerTab.js +46 -0
  83. package/dist/components/modules/profile/tabs/CareerTab.js.map +1 -0
  84. package/dist/components/modules/profile/tabs/FriendsTab.d.ts +7 -0
  85. package/dist/components/modules/profile/tabs/FriendsTab.d.ts.map +1 -0
  86. package/dist/components/modules/profile/tabs/FriendsTab.js +8 -0
  87. package/dist/components/modules/profile/tabs/FriendsTab.js.map +1 -0
  88. package/dist/components/modules/profile/tabs/GamesTab.d.ts +7 -0
  89. package/dist/components/modules/profile/tabs/GamesTab.d.ts.map +1 -0
  90. package/dist/components/modules/profile/tabs/GamesTab.js +37 -0
  91. package/dist/components/modules/profile/tabs/GamesTab.js.map +1 -0
  92. package/dist/components/modules/profile/tabs/PostsTab.d.ts +7 -0
  93. package/dist/components/modules/profile/tabs/PostsTab.d.ts.map +1 -0
  94. package/dist/components/modules/profile/tabs/PostsTab.js +81 -0
  95. package/dist/components/modules/profile/tabs/PostsTab.js.map +1 -0
  96. package/dist/components/modules/profile/widgets/ProfileBadgesWidget.d.ts +2 -0
  97. package/dist/components/modules/profile/widgets/ProfileBadgesWidget.d.ts.map +1 -0
  98. package/dist/components/modules/profile/widgets/ProfileBadgesWidget.js +6 -0
  99. package/dist/components/modules/profile/widgets/ProfileBadgesWidget.js.map +1 -0
  100. package/dist/components/modules/profile/widgets/ProfileCloudWidget.d.ts +6 -0
  101. package/dist/components/modules/profile/widgets/ProfileCloudWidget.d.ts.map +1 -0
  102. package/dist/components/modules/profile/widgets/ProfileCloudWidget.js +6 -0
  103. package/dist/components/modules/profile/widgets/ProfileCloudWidget.js.map +1 -0
  104. package/dist/components/modules/profile/widgets/ProfileFriendsWidget.d.ts +8 -0
  105. package/dist/components/modules/profile/widgets/ProfileFriendsWidget.d.ts.map +1 -0
  106. package/dist/components/modules/profile/widgets/ProfileFriendsWidget.js +12 -0
  107. package/dist/components/modules/profile/widgets/ProfileFriendsWidget.js.map +1 -0
  108. package/dist/components/modules/stations/StationCard.d.ts +2 -2
  109. package/dist/components/modules/stations/StationQRModal.d.ts +9 -9
  110. package/dist/components/shared/DevTools.d.ts +2 -0
  111. package/dist/components/shared/DevTools.d.ts.map +1 -0
  112. package/dist/components/shared/DevTools.js +39 -0
  113. package/dist/components/shared/DevTools.js.map +1 -0
  114. package/dist/components/shared/FloatingChatButton.d.ts +4 -4
  115. package/dist/components/shared/Header.d.ts +1 -1
  116. package/dist/components/shared/Header.d.ts.map +1 -1
  117. package/dist/components/shared/Header.js +108 -97
  118. package/dist/components/shared/Header.js.map +1 -1
  119. package/dist/components/shared/LoginModal.d.ts +4 -4
  120. package/dist/components/shared/LoginModal.d.ts.map +1 -1
  121. package/dist/components/shared/LoginModal.js +65 -69
  122. package/dist/components/shared/LoginModal.js.map +1 -1
  123. package/dist/components/shared/MainLayoutWrapper.d.ts +3 -3
  124. package/dist/components/showcase/ProfileTab.d.ts.map +1 -1
  125. package/dist/components/showcase/ProfileTab.js +43 -3
  126. package/dist/components/showcase/ProfileTab.js.map +1 -1
  127. package/dist/components/showcase/SocialTab.d.ts.map +1 -1
  128. package/dist/components/showcase/SocialTab.js +86 -2
  129. package/dist/components/showcase/SocialTab.js.map +1 -1
  130. package/dist/context/ArmoyuContext.d.ts +42 -0
  131. package/dist/context/ArmoyuContext.d.ts.map +1 -0
  132. package/dist/context/ArmoyuContext.js +76 -0
  133. package/dist/context/ArmoyuContext.js.map +1 -0
  134. package/dist/context/AuthContext.d.ts +18 -18
  135. package/dist/context/AuthContext.d.ts.map +1 -1
  136. package/dist/context/AuthContext.js +97 -74
  137. package/dist/context/AuthContext.js.map +1 -1
  138. package/dist/context/CartContext.d.ts +16 -16
  139. package/dist/context/SocketContext.d.ts +12 -12
  140. package/dist/context/SocketContext.d.ts.map +1 -1
  141. package/dist/context/SocketContext.js +31 -30
  142. package/dist/context/SocketContext.js.map +1 -1
  143. package/dist/index.d.ts +67 -65
  144. package/dist/index.d.ts.map +1 -1
  145. package/dist/index.js +83 -80
  146. package/dist/index.js.map +1 -1
  147. package/dist/lib/ArmoyuUI.d.ts +18 -0
  148. package/dist/lib/ArmoyuUI.d.ts.map +1 -0
  149. package/dist/lib/ArmoyuUI.js +25 -0
  150. package/dist/lib/ArmoyuUI.js.map +1 -0
  151. package/dist/lib/constants/educationData.d.ts +7 -7
  152. package/dist/lib/constants/seedData.d.ts +164 -164
  153. package/dist/lib/constants/seedData.d.ts.map +1 -1
  154. package/dist/lib/constants/seedData.js +694 -694
  155. package/dist/lib/constants/seedData.js.map +1 -1
  156. package/dist/lib/constants/stationData.d.ts +13 -13
  157. package/dist/lib/constants/stationData.js +166 -166
  158. package/dist/lib/constants/stationData.js.map +1 -1
  159. package/dist/lib/constants/surveyData.d.ts +2 -2
  160. package/dist/lib/constants/teamData.d.ts +12 -12
  161. package/package.json +14 -12
  162. package/next.config.ts +0 -13
  163. package/postcss.config.js +0 -6
  164. package/src/app/layout.tsx +0 -67
  165. package/src/app/page.tsx +0 -101
  166. package/src/components/Button.tsx +0 -41
  167. package/src/components/GenderStatsBar.tsx +0 -66
  168. package/src/components/RollingNumber.tsx +0 -50
  169. package/src/components/Slider.tsx +0 -114
  170. package/src/components/StatsGrid.tsx +0 -35
  171. package/src/components/ViewModeToggle.tsx +0 -39
  172. package/src/components/modules/auth/Dashboard.tsx +0 -649
  173. package/src/components/modules/auth/MediaLightbox.tsx +0 -112
  174. package/src/components/modules/auth/PostCard.tsx +0 -556
  175. package/src/components/modules/auth/PostInteractionsModal.tsx +0 -138
  176. package/src/components/modules/auth/RepostModal.tsx +0 -167
  177. package/src/components/modules/auth/SidebarLeft.tsx +0 -237
  178. package/src/components/modules/auth/Stories.tsx +0 -69
  179. package/src/components/modules/auth/StoryViewer.tsx +0 -146
  180. package/src/components/modules/chat/ChatContainer.tsx +0 -332
  181. package/src/components/modules/chat/ChatInput.tsx +0 -57
  182. package/src/components/modules/chat/ChatList.tsx +0 -179
  183. package/src/components/modules/chat/ChatMessage.tsx +0 -43
  184. package/src/components/modules/chat/ChatNotes.tsx +0 -58
  185. package/src/components/modules/community/GroupHeader.tsx +0 -111
  186. package/src/components/modules/community/GroupMenu.tsx +0 -82
  187. package/src/components/modules/community/SchoolCard.tsx +0 -104
  188. package/src/components/modules/community/SurveyCard.tsx +0 -149
  189. package/src/components/modules/forum/ForumBoard.tsx +0 -78
  190. package/src/components/modules/forum/ForumPost.tsx +0 -71
  191. package/src/components/modules/forum/NewTopicModal.tsx +0 -112
  192. package/src/components/modules/forum/TopicItem.tsx +0 -72
  193. package/src/components/modules/galleries/GalleryCard.tsx +0 -66
  194. package/src/components/modules/giveaways/GiveawayCard.tsx +0 -76
  195. package/src/components/modules/groups/ApplicationModal.tsx +0 -133
  196. package/src/components/modules/groups/GroupCard.tsx +0 -96
  197. package/src/components/modules/guest/Introduction.tsx +0 -60
  198. package/src/components/modules/magaza/BackToStore.tsx +0 -53
  199. package/src/components/modules/magaza/StoreHeader.tsx +0 -74
  200. package/src/components/modules/news/NewsCard.tsx +0 -66
  201. package/src/components/modules/news/NewsComments.tsx +0 -141
  202. package/src/components/modules/profile/CloudStorageModal.tsx +0 -200
  203. package/src/components/modules/profile/EditProfileModal.tsx +0 -191
  204. package/src/components/modules/profile/ProfileContent.tsx +0 -491
  205. package/src/components/modules/profile/ProfileHeader.tsx +0 -128
  206. package/src/components/modules/profile/ProfileStats.tsx +0 -72
  207. package/src/components/modules/profile/TeamSelectorModal.tsx +0 -129
  208. package/src/components/modules/stations/StationCard.tsx +0 -95
  209. package/src/components/modules/stations/StationQRModal.tsx +0 -102
  210. package/src/components/shared/FloatingChatButton.tsx +0 -57
  211. package/src/components/shared/Footer.tsx +0 -77
  212. package/src/components/shared/Header.tsx +0 -799
  213. package/src/components/shared/LoginModal.tsx +0 -208
  214. package/src/components/shared/MainLayoutWrapper.tsx +0 -15
  215. package/src/components/shared/PageWidth.tsx +0 -22
  216. package/src/components/showcase/CommunityTab.tsx +0 -22
  217. package/src/components/showcase/CorporateTab.tsx +0 -38
  218. package/src/components/showcase/GeneralTab.tsx +0 -41
  219. package/src/components/showcase/MessagesTab.tsx +0 -26
  220. package/src/components/showcase/ProfileTab.tsx +0 -20
  221. package/src/components/showcase/ShopTab.tsx +0 -24
  222. package/src/components/showcase/SocialTab.tsx +0 -28
  223. package/src/context/AuthContext.tsx +0 -104
  224. package/src/context/CartContext.tsx +0 -93
  225. package/src/context/ChatContext.tsx +0 -32
  226. package/src/context/LayoutContext.tsx +0 -29
  227. package/src/context/SocketContext.tsx +0 -50
  228. package/src/context/ThemeContext.tsx +0 -52
  229. package/src/index.ts +0 -96
  230. package/src/lib/constants/educationData.ts +0 -124
  231. package/src/lib/constants/punishmentData.ts +0 -201
  232. package/src/lib/constants/seedData.ts +0 -758
  233. package/src/lib/constants/stationData.ts +0 -170
  234. package/src/lib/constants/surveyData.ts +0 -53
  235. package/src/lib/constants/teamData.ts +0 -69
  236. package/src/lib/utils/numberFormat.ts +0 -16
  237. package/src/lib/utils/odpUtils.ts +0 -51
  238. package/src/types/index.ts +0 -1
  239. package/src/types/stats.ts +0 -17
@@ -1,112 +0,0 @@
1
- 'use client';
2
- import React, { useState, useEffect, useCallback } from 'react';
3
- import { createPortal } from 'react-dom';
4
-
5
- export interface PostMedia {
6
- type: 'image' | 'video';
7
- url: string;
8
- }
9
-
10
- interface MediaLightboxProps {
11
- isOpen: boolean;
12
- onClose: () => void;
13
- media: PostMedia[];
14
- initialIndex?: number;
15
- }
16
-
17
- export function MediaLightbox({ isOpen, onClose, media, initialIndex = 0 }: MediaLightboxProps) {
18
- const [currentIndex, setCurrentIndex] = useState(initialIndex);
19
- const [mounted, setMounted] = useState(false);
20
-
21
- const handlePrev = useCallback((e?: React.MouseEvent | KeyboardEvent) => {
22
- e?.stopPropagation();
23
- setCurrentIndex(prev => (prev === 0 ? media.length - 1 : prev - 1));
24
- }, [media.length]);
25
-
26
- const handleNext = useCallback((e?: React.MouseEvent | KeyboardEvent) => {
27
- e?.stopPropagation();
28
- setCurrentIndex(prev => (prev === media.length - 1 ? 0 : prev + 1));
29
- }, [media.length]);
30
-
31
- useEffect(() => {
32
- setMounted(true);
33
- if (isOpen) {
34
- setCurrentIndex(initialIndex);
35
- document.body.style.overflow = 'hidden';
36
- }
37
-
38
- // Klavye Desteği
39
- const handleKeyDown = (e: KeyboardEvent) => {
40
- if (!isOpen) return;
41
- if (e.key === 'ArrowLeft') handlePrev(e);
42
- if (e.key === 'ArrowRight') handleNext(e);
43
- if (e.key === 'Escape') onClose();
44
- };
45
-
46
- window.addEventListener('keydown', handleKeyDown);
47
- return () => {
48
- document.body.style.overflow = '';
49
- window.removeEventListener('keydown', handleKeyDown);
50
- };
51
- }, [isOpen, initialIndex, handlePrev, handleNext, onClose]);
52
-
53
- if (!isOpen || !media || media.length === 0 || !mounted) return null;
54
-
55
- const currentMedia = media[currentIndex];
56
-
57
- const modalContent = (
58
- <div className="fixed inset-0 z-[9999] flex items-center justify-center animate-in fade-in duration-200">
59
- {/* Background Dar Overlay */}
60
- <div className="absolute inset-0 bg-[#0a0a0f]/95 backdrop-blur-md" onClick={onClose} />
61
-
62
- {/* Kapat Butonu */}
63
- <button onClick={onClose} className="absolute top-4 md:top-6 right-4 md:right-6 text-white/50 hover:text-white bg-white/10 hover:bg-white/20 p-2.5 md:p-3 rounded-full transition-all z-[10001] border border-white/10 active:scale-90">
64
- <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2.5" strokeLinecap="round" strokeLinejoin="round"><line x1="18" y1="6" x2="6" y2="18"></line><line x1="6" y1="6" x2="18" y2="18"></line></svg>
65
- </button>
66
-
67
- {/* İndeks Sayacı */}
68
- {media.length > 1 && (
69
- <div className="absolute top-4 md:top-6 left-4 md:left-6 text-white bg-white/10 px-4 py-1.5 rounded-full font-black text-[10px] tracking-widest z-[10001] border border-white/10 backdrop-blur-md uppercase">
70
- {currentIndex + 1} / {media.length}
71
- </div>
72
- )}
73
-
74
- {/* Sol Gezinme Oku */}
75
- {media.length > 1 && (
76
- <button onClick={(e) => handlePrev(e)} className="absolute left-4 md:left-8 top-1/2 -translate-y-1/2 text-white/40 hover:text-white bg-white/5 hover:bg-white/10 p-4 md:p-5 rounded-full transition-all z-[10001] border border-transparent hover:border-white/10 backdrop-blur-md group active:scale-90">
77
- <svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="3" strokeLinecap="round" strokeLinejoin="round" className="group-hover:-translate-x-0.5 transition-transform"><polyline points="15 18 9 12 15 6"></polyline></svg>
78
- </button>
79
- )}
80
-
81
- {/* Sağ Gezinme Oku */}
82
- {media.length > 1 && (
83
- <button onClick={(e) => handleNext(e)} className="absolute right-4 md:right-8 top-1/2 -translate-y-1/2 text-white/40 hover:text-white bg-white/5 hover:bg-white/10 p-4 md:p-5 rounded-full transition-all z-[10001] border border-transparent hover:border-white/10 backdrop-blur-md group active:scale-90">
84
- <svg xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="3" strokeLinecap="round" strokeLinejoin="round" className="group-hover:translate-x-0.5 transition-transform"><polyline points="9 18 15 12 9 6"></polyline></svg>
85
- </button>
86
- )}
87
-
88
- {/* Medya Render Motoru */}
89
- <div className="relative w-full h-full max-w-7xl max-h-[92vh] flex items-center justify-center p-4 md:p-12 z-[10000]" onClick={onClose}>
90
- {currentMedia.type === 'video' ? (
91
- // eslint-disable-next-line jsx-a11y/media-has-caption
92
- <video
93
- src={currentMedia.url}
94
- controls
95
- autoPlay
96
- className="max-w-full max-h-full rounded-2xl shadow-[0_0_80px_rgba(0,0,0,0.8)] object-contain animate-in zoom-in-95 duration-500 ring-1 ring-white/10"
97
- onClick={(e) => e.stopPropagation()}
98
- />
99
- ) : (
100
- <img
101
- src={currentMedia.url}
102
- alt="Galeri Medyası"
103
- className="max-w-full max-h-full rounded-2xl shadow-[0_0_80px_rgba(0,0,0,0.8)] object-contain animate-in zoom-in-95 duration-500 ring-1 ring-white/10"
104
- onClick={(e) => e.stopPropagation()}
105
- />
106
- )}
107
- </div>
108
- </div>
109
- );
110
-
111
- return createPortal(modalContent, document.body);
112
- }