@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,32 +0,0 @@
1
- 'use client';
2
-
3
- import React, { createContext, useContext, useState } from 'react';
4
-
5
- interface ChatContextType {
6
- isChatOpen: boolean;
7
- toggleChat: () => void;
8
- openChat: () => void;
9
- closeChat: () => void;
10
- }
11
-
12
- const ChatContext = createContext<ChatContextType | undefined>(undefined);
13
-
14
- export function ChatProvider({ children }: { children: React.ReactNode }) {
15
- const [isChatOpen, setIsChatOpen] = useState(false);
16
-
17
- const toggleChat = () => setIsChatOpen(!isChatOpen);
18
- const openChat = () => setIsChatOpen(true);
19
- const closeChat = () => setIsChatOpen(false);
20
-
21
- return (
22
- <ChatContext.Provider value={{ isChatOpen, toggleChat, openChat, closeChat }}>
23
- {children}
24
- </ChatContext.Provider>
25
- );
26
- }
27
-
28
- export function useChat() {
29
- const context = useContext(ChatContext);
30
- if (!context) throw new Error('useChat must be used within ChatProvider');
31
- return context;
32
- }
@@ -1,29 +0,0 @@
1
- 'use client';
2
-
3
- import React, { createContext, useContext, useState, ReactNode } from 'react';
4
-
5
- type LayoutContextType = {
6
- pageWidth: string; // Tailwind class like max-w-7xl or max-w-[80vw]
7
- setPageWidth: (width: string) => void;
8
- };
9
-
10
- const LayoutContext = createContext<LayoutContextType | undefined>(undefined);
11
-
12
- export function LayoutProvider({ children }: { children: ReactNode }) {
13
- // Varsayılan masaüstü değeri %80 olarak ayarlanmıştır.
14
- const [pageWidth, setPageWidth] = useState('max-w-[80%]');
15
-
16
- return (
17
- <LayoutContext.Provider value={{ pageWidth, setPageWidth }}>
18
- {children}
19
- </LayoutContext.Provider>
20
- );
21
- }
22
-
23
- export function useLayout() {
24
- const context = useContext(LayoutContext);
25
- if (!context) {
26
- throw new Error('useLayout must be used within a LayoutProvider');
27
- }
28
- return context;
29
- }
@@ -1,50 +0,0 @@
1
- 'use client';
2
-
3
- import React, { createContext, useContext, useState, useEffect } from 'react';
4
- import { socketService, SocketEvent } from '@armoyu/core';
5
-
6
-
7
- interface SocketContextType {
8
- isConnected: boolean;
9
- emit: (event: SocketEvent, data: any) => void;
10
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
11
- on: (event: SocketEvent, callback: (data: any) => void) => () => void;
12
- }
13
-
14
- const SocketContext = createContext<SocketContextType | undefined>(undefined);
15
-
16
- export function SocketProvider({ children }: { children: React.ReactNode }) {
17
- const [isConnected, setIsConnected] = useState(socketService.isConnected);
18
-
19
- useEffect(() => {
20
- const handleConnect = () => setIsConnected(true);
21
- const handleDisconnect = () => setIsConnected(false);
22
-
23
- const offConnect = socketService.on('connect', handleConnect);
24
- const offDisconnect = socketService.on('disconnect', handleDisconnect);
25
-
26
- return () => {
27
- offConnect();
28
- offDisconnect();
29
- };
30
- }, []);
31
-
32
- return (
33
- <SocketContext.Provider value={{
34
- isConnected,
35
- emit: socketService.emit.bind(socketService),
36
- on: socketService.on.bind(socketService)
37
- }}>
38
- {children}
39
- </SocketContext.Provider>
40
- );
41
- }
42
-
43
- export function useSocket() {
44
- const context = useContext(SocketContext);
45
- if (context === undefined) {
46
- throw new Error('useSocket must be used within a SocketProvider');
47
- }
48
- return context;
49
- }
50
-
@@ -1,52 +0,0 @@
1
- 'use client';
2
-
3
- import React, { createContext, useContext, useState, useEffect } from 'react';
4
-
5
- interface ThemeContextType {
6
- theme: 'dark' | 'light';
7
- toggleTheme: () => void;
8
- }
9
-
10
- const ThemeContext = createContext<ThemeContextType | undefined>(undefined);
11
-
12
- export function ThemeProvider({ children }: { children: React.ReactNode }) {
13
- const [theme, setTheme] = useState<'dark' | 'light'>('dark');
14
-
15
- // Tarayıcı hafızasını okuyarak temayı yükleme (Local Storage)
16
- useEffect(() => {
17
- const savedTheme = localStorage.getItem('armoyu_theme') as 'dark' | 'light';
18
- if (savedTheme === 'light') {
19
- setTheme('light');
20
- document.documentElement.classList.remove('dark');
21
- } else {
22
- setTheme('dark');
23
- document.documentElement.classList.add('dark');
24
- // İlk girişte varsayılan olarak depolanır
25
- localStorage.setItem('armoyu_theme', 'dark');
26
- }
27
- }, []);
28
-
29
- const toggleTheme = () => {
30
- const newTheme = theme === 'dark' ? 'light' : 'dark';
31
- setTheme(newTheme);
32
- localStorage.setItem('armoyu_theme', newTheme);
33
-
34
- if (newTheme === 'dark') {
35
- document.documentElement.classList.add('dark');
36
- } else {
37
- document.documentElement.classList.remove('dark');
38
- }
39
- };
40
-
41
- return (
42
- <ThemeContext.Provider value={{ theme, toggleTheme }}>
43
- {children}
44
- </ThemeContext.Provider>
45
- );
46
- }
47
-
48
- export function useTheme() {
49
- const context = useContext(ThemeContext);
50
- if (!context) throw new Error('useTheme hooks must be used inside ThemeProvider!');
51
- return context;
52
- }
package/src/index.ts DELETED
@@ -1,96 +0,0 @@
1
- export * from './components/Button';
2
- export * from './components/Slider';
3
- export * from './components/RollingNumber';
4
- export * from './components/ViewModeToggle';
5
- export * from './components/GenderStatsBar';
6
- export * from './components/StatsGrid';
7
-
8
- // Contexts
9
- export * from './context/AuthContext';
10
- export * from './context/CartContext';
11
- export * from './context/ChatContext';
12
- export * from './context/LayoutContext';
13
- export * from './context/SocketContext';
14
- export * from './context/ThemeContext';
15
-
16
- // Types & Constants
17
- export * from './types';
18
- export * from './lib/constants/seedData';
19
- export * from './lib/constants/educationData';
20
- export * from './lib/constants/punishmentData';
21
- export * from './lib/constants/stationData';
22
- export * from './lib/constants/surveyData';
23
- export * from './lib/constants/teamData';
24
- export * from './lib/utils/odpUtils';
25
-
26
-
27
- // Shared Components
28
- export { Header } from './components/shared/Header';
29
- export { Footer } from './components/shared/Footer';
30
- export { LoginModal } from './components/shared/LoginModal';
31
- export { FloatingChatButton } from './components/shared/FloatingChatButton';
32
- export { MainLayoutWrapper } from './components/shared/MainLayoutWrapper';
33
- export { PageWidth } from './components/shared/PageWidth';
34
-
35
- // Auth Module
36
- export { Dashboard as AuthDashboard } from './components/modules/auth/Dashboard';
37
- export { Dashboard } from './components/modules/auth/Dashboard';
38
- export { PostCard } from './components/modules/auth/PostCard';
39
- export { PostInteractionsModal } from './components/modules/auth/PostInteractionsModal';
40
- export { RepostModal } from './components/modules/auth/RepostModal';
41
- export { SidebarLeft as AuthSidebarLeft } from './components/modules/auth/SidebarLeft';
42
- export { Stories } from './components/modules/auth/Stories';
43
- export { StoryViewer } from './components/modules/auth/StoryViewer';
44
- export { MediaLightbox, type PostMedia } from './components/modules/auth/MediaLightbox';
45
-
46
- // Chat Module
47
- export { ChatContainer } from './components/modules/chat/ChatContainer';
48
- export { ChatInput } from './components/modules/chat/ChatInput';
49
- export { ChatList } from './components/modules/chat/ChatList';
50
- export { ChatMessage } from './components/modules/chat/ChatMessage';
51
- export { ChatNotes } from './components/modules/chat/ChatNotes';
52
-
53
- // Community Module
54
- export { GroupHeader } from './components/modules/community/GroupHeader';
55
- export { GroupMenu } from './components/modules/community/GroupMenu';
56
- export { SchoolCard } from './components/modules/community/SchoolCard';
57
- export { SurveyCard } from './components/modules/community/SurveyCard';
58
-
59
- // Forum Module
60
- export { ForumBoard } from './components/modules/forum/ForumBoard';
61
- export { ForumPost } from './components/modules/forum/ForumPost';
62
- export { NewTopicModal } from './components/modules/forum/NewTopicModal';
63
- export { TopicItem } from './components/modules/forum/TopicItem';
64
-
65
- // Galleries Module
66
- export { GalleryCard } from './components/modules/galleries/GalleryCard';
67
-
68
- // Giveaways Module
69
- export { GiveawayCard } from './components/modules/giveaways/GiveawayCard';
70
-
71
- // Groups Module
72
- export { GroupCard } from './components/modules/groups/GroupCard';
73
- export { ApplicationModal as GroupApplicationModal } from './components/modules/groups/ApplicationModal';
74
-
75
- // Guest Module
76
- export { Introduction } from './components/modules/guest/Introduction';
77
-
78
- // Magaza Module
79
- export { BackToStore } from './components/modules/magaza/BackToStore';
80
- export { StoreHeader } from './components/modules/magaza/StoreHeader';
81
-
82
- // News Module
83
- export { NewsCard } from './components/modules/news/NewsCard';
84
- export { NewsComments } from './components/modules/news/NewsComments';
85
-
86
- // Profile Module
87
- export { ProfileHeader } from './components/modules/profile/ProfileHeader';
88
- export { ProfileStats } from './components/modules/profile/ProfileStats';
89
- export { ProfileContent } from './components/modules/profile/ProfileContent';
90
- export { EditProfileModal } from './components/modules/profile/EditProfileModal';
91
- export { TeamSelectorModal } from './components/modules/profile/TeamSelectorModal';
92
- export { CloudStorageModal } from './components/modules/profile/CloudStorageModal';
93
-
94
- // Stations Module
95
- export { StationCard } from './components/modules/stations/StationCard';
96
- export { StationQRModal } from './components/modules/stations/StationQRModal';
@@ -1,124 +0,0 @@
1
- import { School, Faculty, Classroom, SchoolTeam, User } from '@armoyu/core';
2
-
3
-
4
- export const MOCK_EDUCATION_DATA = (userList: any[]) => {
5
- // 1. School Teams (Traditional & Esports)
6
- const teams = [
7
- new SchoolTeam({
8
- id: 'st1',
9
- name: 'ARMOYU CS2 Team',
10
- gameOrSport: 'Counter-Strike 2',
11
- type: 'ESPORTS',
12
- schoolId: 'sch1',
13
- captain: userList[0]
14
- }),
15
- new SchoolTeam({
16
- id: 'st2',
17
- name: 'UAV Football Varsity',
18
- gameOrSport: 'Football',
19
- type: 'TRADITIONAL_SPORTS',
20
- schoolId: 'sch1',
21
- captain: userList[11]
22
- }),
23
- new SchoolTeam({
24
- id: 'st3',
25
- name: 'Code Masters LoL',
26
- gameOrSport: 'League of Legends',
27
- type: 'ESPORTS',
28
- schoolId: 'sch2',
29
- captain: userList[1]
30
- })
31
- ];
32
-
33
- // 2. Faculties
34
- const faculties = [
35
- new Faculty({ id: 'f1', name: 'Mühendislik Fakültesi', schoolId: 'sch1', representative: userList[14] }),
36
- new Faculty({ id: 'f2', name: 'İktisadi ve İdari Bilimler Fakültesi', schoolId: 'sch1', representative: userList[12] }),
37
- new Faculty({ id: 'f3', name: 'Fen Edebiyat Fakültesi', schoolId: 'sch2', representative: userList[3] })
38
- ];
39
-
40
- // 3. Classrooms
41
- const classrooms = [
42
- new Classroom({ id: 'c1', name: 'Web Geliştirme 101', schoolId: 'sch1', teacher: userList[0], password: 'armoyu_learn' }),
43
- new Classroom({ id: 'c2', name: 'Algoritma ve Veri Yapıları', schoolId: 'sch1', teacher: userList[14] }),
44
- new Classroom({ id: 'c3', name: 'Dijital Tasarım', schoolId: 'sch2', teacher: userList[1] })
45
- ];
46
-
47
- // 4. Schools
48
- const schools = [
49
- new School({
50
- id: 'sch1',
51
- name: 'İstanbul Teknik Üniversitesi',
52
- slug: 'itu',
53
- logo: 'https://upload.wikimedia.org/wikipedia/tr/a/ae/%C4%B0T%C3%9C_Logo.png',
54
- representative: userList[0],
55
- faculties: faculties.filter(f => f.schoolId === 'sch1'),
56
- teams: teams.filter(t => t.schoolId === 'sch1'),
57
- classrooms: classrooms.filter(cl => cl.schoolId === 'sch1'),
58
- memberCount: 1250
59
- }),
60
- new School({
61
- id: 'sch2',
62
- name: 'Boğaziçi Üniversitesi',
63
- slug: 'bogazici',
64
- logo: 'https://upload.wikimedia.org/wikipedia/tr/b/b3/Bo%C4%9Fazi%C3%A7i_%C3%9Cniversitesi_Logosu.png',
65
- representative: userList[1],
66
- faculties: faculties.filter(f => f.schoolId === 'sch2'),
67
- teams: teams.filter(t => t.schoolId === 'sch2'),
68
- classrooms: classrooms.filter(cl => cl.schoolId === 'sch2'),
69
- memberCount: 890
70
- }),
71
- new School({
72
- id: 'sch3',
73
- name: 'Sivas Cumhuriyet Üniversitesi',
74
- slug: 'cumhuriyet',
75
- logo: 'https://upload.wikimedia.org/wikipedia/tr/a/ac/Cumhuriyet_%C3%9Cniversitesi_Logosu.png',
76
- representative: userList[2],
77
- faculties: [
78
- new Faculty({ id: 'f4', name: 'Tıp Fakültesi', schoolId: 'sch3', representative: userList[4] }),
79
- new Faculty({ id: 'f5', name: 'Eğitim Fakültesi', schoolId: 'sch3', representative: userList[5] })
80
- ],
81
- teams: [
82
- new SchoolTeam({ id: 'st4', name: 'CU Eagles Volleyball', gameOrSport: 'Volleyball', type: 'TRADITIONAL_SPORTS', schoolId: 'sch3', captain: userList[2] }),
83
- new SchoolTeam({ id: 'st5', name: 'CU Valorant', gameOrSport: 'Valorant', type: 'ESPORTS', schoolId: 'sch3', captain: userList[4] })
84
- ],
85
- classrooms: [
86
- new Classroom({ id: 'c4', name: 'Temel Programlama', schoolId: 'sch3', teacher: userList[2] })
87
- ],
88
- memberCount: 2100
89
- }),
90
- new School({
91
- id: 'sch4',
92
- name: 'Tokat Gaziosmanpaşa Üniversitesi',
93
- slug: 'gop',
94
- logo: 'https://upload.wikimedia.org/wikipedia/tr/5/5e/Tokat_Gaziosmanpa%C5%9Fa_%C3%9Cniversitesi_Logosu.png',
95
- representative: userList[3],
96
- faculties: [
97
- new Faculty({ id: 'f6', name: 'Ziraat Fakültesi', schoolId: 'sch4', representative: userList[3] })
98
- ],
99
- teams: [
100
- new SchoolTeam({ id: 'st6', name: 'GOP Football', gameOrSport: 'Football', type: 'TRADITIONAL_SPORTS', schoolId: 'sch4', captain: userList[3] })
101
- ],
102
- classrooms: [],
103
- memberCount: 1450
104
- }),
105
- new School({
106
- id: 'sch5',
107
- name: 'Samsun Ondokuz Mayıs Üniversitesi',
108
- slug: 'omu',
109
- logo: 'https://upload.wikimedia.org/wikipedia/tr/6/6d/Ondokuz_May%C4%B1s_%C3%9Cniversitesi_Logosu.png',
110
- representative: userList[10],
111
- faculties: [
112
- new Faculty({ id: 'f7', name: 'Hukuk Fakültesi', schoolId: 'sch5', representative: userList[10] })
113
- ],
114
- teams: [
115
- new SchoolTeam({ id: 'st7', name: 'OMU Cyber Sports', gameOrSport: 'DotA 2', type: 'ESPORTS', schoolId: 'sch5', captain: userList[11] })
116
- ],
117
- classrooms: [],
118
- memberCount: 3200
119
- })
120
- ];
121
-
122
- return { schools, faculties, teams, classrooms };
123
- };
124
-
@@ -1,201 +0,0 @@
1
- export type RestrictionType = 'CHAT_BAN' | 'POST_BAN' | 'PROFILE_EDIT_BAN' | 'LOGIN_BAN' | 'PERMANENT_BAN';
2
-
3
- export type RuleCategory = 'SOHBET' | 'GÜVENLİK' | 'İÇERİK' | 'HESAP' | 'ETKİNLİK';
4
-
5
- export interface PunishmentRule {
6
- id: string;
7
- article: string; // e.g., "M1.1"
8
- name: string;
9
- category: RuleCategory;
10
- description: string;
11
- duration: number; // in hours, 0 for permanent
12
- restrictions: RestrictionType[];
13
- severity: 'low' | 'medium' | 'high' | 'critical';
14
- isMajor?: boolean; // If true, escalation is stricter. If false, it's educational.
15
- }
16
-
17
- export const PUNISHMENT_RULES: PunishmentRule[] = [
18
- // SOHBET (M1.X)
19
- {
20
- id: 'spam-flood',
21
- article: 'M1.1',
22
- category: 'SOHBET',
23
- name: 'Spam / Flood',
24
- description: 'Sohbet veya yorum alanlarında tekrarlayıcı ve rahatsız edici içerik paylaşımı.',
25
- duration: 24,
26
- restrictions: ['CHAT_BAN'],
27
- severity: 'low',
28
- isMajor: false
29
- },
30
- {
31
- id: 'inappropriate-lang',
32
- article: 'M1.2',
33
- category: 'SOHBET',
34
- name: 'Uygunsuz Dil / Küfür',
35
- description: 'Diğer kullanıcılara yönelik hakaret, küfür veya aşağılayıcı ifadeler.',
36
- duration: 72,
37
- restrictions: ['CHAT_BAN'],
38
- severity: 'medium',
39
- isMajor: true
40
- },
41
- {
42
- id: 'toxic-behavior',
43
- article: 'M1.3',
44
- category: 'SOHBET',
45
- name: 'Toksik Davranış / Kışkırtma',
46
- description: 'Topluluk huzurunu bozmaya yönelik kışkırtmalar ve huzursuzluk çıkarma.',
47
- duration: 48,
48
- restrictions: ['CHAT_BAN'],
49
- severity: 'low',
50
- isMajor: false
51
- },
52
-
53
- // İÇERİK (M2.X)
54
- {
55
- id: 'misleading-content',
56
- article: 'M2.1',
57
- category: 'İÇERİK',
58
- name: 'Hatalı Paylaşım / Clickbait',
59
- description: 'Topluluğu yanıltıcı veya gereksiz (çöp) içerik üretimi.',
60
- duration: 48,
61
- restrictions: ['POST_BAN'],
62
- severity: 'low',
63
- isMajor: false
64
- },
65
- {
66
- id: 'illegal-content',
67
- article: 'M2.2',
68
- category: 'İÇERİK',
69
- name: 'İllegal / Uygunsuz Paylaşım',
70
- description: 'Yasal olmayan içeriklerin, korsan yazılım veya uygunsuz medyanın paylaşımı.',
71
- duration: 0,
72
- restrictions: ['PERMANENT_BAN'],
73
- severity: 'critical',
74
- isMajor: true
75
- },
76
- {
77
- id: 'ad-sharing',
78
- article: 'M2.3',
79
- category: 'İÇERİK',
80
- name: 'İzinsiz Reklam / Tanıtım',
81
- description: 'Yönetimden izin almadan yapılan topluluk, yayıncı veya ürün reklamları.',
82
- duration: 168,
83
- restrictions: ['POST_BAN', 'CHAT_BAN'],
84
- severity: 'medium',
85
- isMajor: false
86
- },
87
-
88
- // GÜVENLİK (M3.X)
89
- {
90
- id: 'harassment',
91
- article: 'M3.1',
92
- category: 'GÜVENLİK',
93
- name: 'Kullanıcı Taciz / Rahatsızlık',
94
- description: 'Kullanıcıları sistematik olarak rahatsız etme veya taciz etme.',
95
- duration: 168,
96
- restrictions: ['CHAT_BAN', 'POST_BAN', 'PROFILE_EDIT_BAN'],
97
- severity: 'high',
98
- isMajor: true
99
- },
100
- {
101
- id: 'doxxing',
102
- article: 'M3.2',
103
- category: 'GÜVENLİK',
104
- name: 'Kişisel Veri İhlali / Doxxing',
105
- description: 'Bir kullanıcının gerçek hayat verilerini, adresini veya telefonunu izinsiz paylaşma.',
106
- duration: 0,
107
- restrictions: ['PERMANENT_BAN'],
108
- severity: 'critical',
109
- isMajor: true
110
- },
111
- {
112
- id: 'bug-abuse',
113
- article: 'M3.3',
114
- category: 'GÜVENLİK',
115
- name: 'Sistem Odaklı Hata Kullanımı',
116
- description: 'Platformdaki hataları (bug) bildirmek yerine kendi çıkarı için kullanma.',
117
- duration: 720, // 1 month
118
- restrictions: ['LOGIN_BAN', 'POST_BAN'],
119
- severity: 'high',
120
- isMajor: true
121
- },
122
-
123
- // HESAP (M4.X)
124
- {
125
- id: 'fake-identity',
126
- article: 'M4.1',
127
- category: 'HESAP',
128
- name: 'Sahte Kimlik / Taklit',
129
- description: 'Başka bir kullanıcıyı veya yetkiliyi taklit etme.',
130
- duration: 0,
131
- restrictions: ['PERMANENT_BAN'],
132
- severity: 'critical',
133
- isMajor: true
134
- },
135
- {
136
- id: 'hate-speech',
137
- article: 'M4.2',
138
- category: 'HESAP',
139
- name: 'Nefret Söylemi / Değerlere Hakaret',
140
- description: 'Dini, milli veya manevi değerlere yönelik ağır hakaret ve saldırı.',
141
- duration: 0,
142
- restrictions: ['PERMANENT_BAN'],
143
- severity: 'critical',
144
- isMajor: true
145
- },
146
- {
147
- id: 'fraud',
148
- article: 'M4.3',
149
- category: 'HESAP',
150
- name: 'Dolandırıcılık / Sahtekarlık',
151
- description: 'Hizmet veya ürün alımlarında kullanıcıları veya sistemi dolandırma girişimi.',
152
- duration: 0,
153
- restrictions: ['PERMANENT_BAN'],
154
- severity: 'critical',
155
- isMajor: true
156
- },
157
- {
158
- id: 'multi-account',
159
- article: 'M4.4',
160
- category: 'HESAP',
161
- name: 'Çoklu Hesap / Multi Account',
162
- description: 'Yasaklandığı halde farklı hesaplarla sisteme tekrar dahil olma girişimi.',
163
- duration: 0,
164
- restrictions: ['PERMANENT_BAN'],
165
- severity: 'critical',
166
- isMajor: true
167
- }
168
- ];
169
-
170
- export const getRestrictionLabel = (type: RestrictionType): string => {
171
- switch (type) {
172
- case 'CHAT_BAN': return 'Sohbet Yasağı';
173
- case 'POST_BAN': return 'Paylaşım Yasağı';
174
- case 'PROFILE_EDIT_BAN': return 'Profil Düzenleme Yasağı';
175
- case 'LOGIN_BAN': return 'Giriş Yasağı';
176
- case 'PERMANENT_BAN': return 'Kalıcı Yasaklama (Ban)';
177
- default: return 'Bilinmeyen Kısıtlama';
178
- }
179
- };
180
-
181
- /**
182
- * Calculates the escalated duration based on the number of previous punishments.
183
- * Formula: base * multiplier
184
- */
185
- export const calculateEscalatedDuration = (baseDuration: number, punishmentCount: number): number => {
186
- if (baseDuration === 0) return 0; // Permanent stays permanent
187
-
188
- const level = getCommunityComplianceLevel(punishmentCount);
189
- return Math.round(baseDuration * level.multiplier);
190
- };
191
-
192
- /**
193
- * Returns the community compliance level details based on involvement count.
194
- */
195
- export const getCommunityComplianceLevel = (count: number) => {
196
- if (count === 0) return { label: 'Tam Uyumlu', color: '#10b981', multiplier: 1.0, severity: 'safe' };
197
- if (count < 3) return { label: 'Biliyor', color: '#3b82f6', multiplier: 1.1, severity: 'low' };
198
- if (count < 6) return { label: 'Dikkat Etmeli', color: '#eab308', multiplier: 1.3, severity: 'medium' };
199
- if (count < 9) return { label: 'Rehberlik Gerekli', color: '#f97316', multiplier: 1.6, severity: 'high' };
200
- return { label: 'İnceleme Altında', color: '#ef4444', multiplier: 2.0, severity: 'critical' };
201
- };