-
Notifications
You must be signed in to change notification settings - Fork 3
Mediawiki settings #409
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Mediawiki settings #409
Changes from all commits
6d29cc7
d7e4139
e0ed5d8
49b9bf9
f61e694
cdeb255
bdbc178
3b68136
b67ff9c
276f863
a2a43c1
f17b9ef
5c1a90a
21e18d4
6af39b2
f81e775
cc5b55c
0fc9633
2a149ab
5742dca
ff1ddbb
23902c2
1edfeea
f144bfb
dd71d3c
d841147
587b08f
fa776f8
1d49e90
be8f266
e1258c8
5a4080a
ab60457
67af038
0748710
4ab6c20
c4a48bf
bb25d2e
532e1be
5fbade1
f9fcd77
8426666
d1ab37b
a405478
894e1d0
1152b84
8053091
9421003
ad4944d
3fede2d
26f17ea
45dbe1b
0780b83
5dbc24f
8f65689
5114387
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -36,3 +36,4 @@ yarn-error.log* | |
| next-env.d.ts | ||
|
|
||
| .env | ||
| .wrangler | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,13 +1,35 @@ | ||
| /** @type {import('next').NextConfig} */ | ||
| // import { setupDevPlatform } from '@cloudflare/next-on-pages/next-dev'; | ||
|
|
||
| /** @type {import('next').NextConfig} */ | ||
| const nextConfig = { | ||
| output: 'export', | ||
| reactStrictMode: false, | ||
| swcMinify: true, | ||
| trailingSlash: true, | ||
| images: { | ||
| unoptimized: true, | ||
| }, | ||
| }; | ||
| } | ||
|
|
||
| // if (process.env.NODE_ENV === 'development') { | ||
| // setupDevPlatform(nextConfig); | ||
| // } | ||
|
|
||
| // export default nextConfig; | ||
|
|
||
| // module.exports = nextConfig; | ||
|
|
||
| // const withBundleAnalyzer = require('@next/bundle-analyzer')({ | ||
| // enabled: process.env.ANALYZE === 'true', | ||
| // }) | ||
|
|
||
| // const nextConfig = withBundleAnalyzer({ | ||
| // // distDir: 'out', | ||
| // output: 'export', | ||
| // reactStrictMode: false, | ||
| // swcMinify: true, | ||
| // trailingSlash: true, | ||
| // images: { | ||
| // unoptimized: true, | ||
| // }, | ||
| // }) | ||
|
|
||
| module.exports = nextConfig; | ||
| module.exports = nextConfig; |
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | ||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,62 @@ | ||||||||||||||||
| 'use client' | ||||||||||||||||
|
|
||||||||||||||||
| import { useRouter } from "next/navigation" | ||||||||||||||||
| import { FaDiscord, FaTelegram } from "react-icons/fa" | ||||||||||||||||
| import { FaXTwitter } from "react-icons/fa6" | ||||||||||||||||
|
|
||||||||||||||||
| import { MODULE_CONTEXT } from "@/constants/ModuleContext" | ||||||||||||||||
|
|
||||||||||||||||
| export default function CommunityGuardianPage() { | ||||||||||||||||
| const router = useRouter() | ||||||||||||||||
|
|
||||||||||||||||
| // TODO: rename to community-guardian | ||||||||||||||||
| const data = MODULE_CONTEXT.find(module => module.name === 'violationDetection') | ||||||||||||||||
|
|
||||||||||||||||
| if (!data || data === undefined) { | ||||||||||||||||
| router.push('/dashboard') | ||||||||||||||||
| } | ||||||||||||||||
|
Comment on lines
+15
to
+17
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Improve redirect logic to handle async navigation. The component immediately redirects if data is not found, but doesn't handle the loading state during redirect. Consider adding a return statement after the redirect to prevent rendering the rest of the component. if (!data || data === undefined) {
router.push('/dashboard')
+ return null; // Prevent rendering the rest of the component during redirect
}📝 Committable suggestion
Suggested change
|
||||||||||||||||
|
|
||||||||||||||||
| return ( | ||||||||||||||||
| <div className="flex flex-col gap-4"> | ||||||||||||||||
| <div className="flex items-center gap-2"> | ||||||||||||||||
| {data && <data.icon size={24} className="text-secondary" />} | ||||||||||||||||
| <h1 className="text-2xl font-semibold">{data?.title}</h1> | ||||||||||||||||
| </div> | ||||||||||||||||
| <p className="text-md text-gray-400"> | ||||||||||||||||
| Neutral, AI-powered Code of Conduct enforcement for safer, healthier communities. | ||||||||||||||||
| </p> | ||||||||||||||||
|
|
||||||||||||||||
| <div className="flex flex-col gap-4 w-full md:w-1/2"> | ||||||||||||||||
|
|
||||||||||||||||
| <p className="text-sm leading-relaxed">Community Guardian helps maintain respectful and inclusive conversations by detecting potential Code of Conduct violations and flagging them early.</p> | ||||||||||||||||
|
|
||||||||||||||||
| <p className="text-sm leading-relaxed">This module is currently in beta and access is limited.</p> | ||||||||||||||||
|
|
||||||||||||||||
| <p className="text-sm leading-relaxed">We're working with selected communities to fine-tune detection, alerts, and recommendations. If you're interested in early access or want to learn more, reach out to us on:</p> | ||||||||||||||||
|
|
||||||||||||||||
| <ul className="flex flex-col gap-2 text-sm"> | ||||||||||||||||
| <li className="w-fit"> | ||||||||||||||||
| <a href="https://discord.gg/QNJGeZeT" target="_blank" className="text-blue-500 hover:text-blue-600 hover:underline flex items-center gap-2" rel="noreferrer"> | ||||||||||||||||
| <FaDiscord /> | ||||||||||||||||
| <span>Discord</span> | ||||||||||||||||
| </a> | ||||||||||||||||
| </li> | ||||||||||||||||
| <li className="w-fit"> | ||||||||||||||||
| <a href="https://x.com/together_crew" target="_blank" className="text-blue-500 hover:text-blue-600 hover:underline flex items-center gap-2" rel="noreferrer"> | ||||||||||||||||
| <FaXTwitter /> | ||||||||||||||||
| <span>Twitter</span> | ||||||||||||||||
| </a> | ||||||||||||||||
| </li> | ||||||||||||||||
| <li className="w-fit"> | ||||||||||||||||
| <a href="https://t.me/k_bc0" target="_blank" className="text-blue-500 hover:text-blue-600 hover:underline flex items-center gap-2" rel="noreferrer"> | ||||||||||||||||
| <FaTelegram /> | ||||||||||||||||
| <span>Telegram</span> | ||||||||||||||||
| </a> | ||||||||||||||||
| </li> | ||||||||||||||||
| </ul> | ||||||||||||||||
|
|
||||||||||||||||
| </div> | ||||||||||||||||
| </div > | ||||||||||||||||
|
|
||||||||||||||||
| ) | ||||||||||||||||
| } | ||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| "use client"; | ||
|
|
||
| import { QueryClient, QueryClientProvider } from "@tanstack/react-query"; | ||
|
|
||
| import ProtectedRoute from "@/components/auth/ProtectedRoute"; | ||
| import Breadcrumbs from "@/components/layouts/Breadcrumbs"; | ||
| import DashboardLayout from "@/components/layouts/DashboardLayout"; | ||
|
|
||
| import { TokenProvider } from "@/context/TokenContext"; | ||
|
|
||
| const queryClient = new QueryClient(); | ||
|
|
||
| export default function RootLayout({ children }: { children: React.ReactNode }) { | ||
|
|
||
|
|
||
| return ( | ||
| <ProtectedRoute> | ||
| <QueryClientProvider client={queryClient}> | ||
| <TokenProvider> | ||
| <DashboardLayout> | ||
| <Breadcrumbs /> | ||
| {children} | ||
| </DashboardLayout> | ||
| </TokenProvider> | ||
| </QueryClientProvider> | ||
| </ProtectedRoute> | ||
| ) | ||
| } |
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,32 @@ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 'use client'; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| import { FaHome } from "react-icons/fa"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| import SEO from "@/components/global/SEO"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| import ModuleList from "@/components/home/modules/ModuleList"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| import PlatformList from "@/components/home/platforms/PlatformList"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| export default function Page() { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| return ( | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <SEO title="Home" /> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <div className="flex flex-col gap-6 sm:gap-8"> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <h1 className="text-2xl font-semibold flex items-center gap-2"> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <FaHome className="text-secondary" /> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <span>Dashboard</span> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </h1> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| {/* <OnlyAdminWarning /> */} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <div className="flex flex-col md:flex-row gap-6 md:gap-8"> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <div className="flex-1"> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <PlatformList /> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </div> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <div className="flex-1"> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <ModuleList /> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </div> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </div > | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </div> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </ > | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+9
to
+32
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💡 Verification agent 🧩 Analysis chainWell-structured dashboard page with responsive layout. The dashboard page is well-structured with semantic HTML and responsive design using Tailwind's responsive prefixes. The layout adapts from a single column on mobile to two columns on medium and larger screens. Consider whether the commented-out 🏁 Script executed: #!/bin/bash
# Check if OnlyAdminWarning is used elsewhere in the codebase
rg -l "OnlyAdminWarning" --type tsx --type jsxLength of output: 74 🏁 Script executed: #!/bin/bash
# Retry searching for OnlyAdminWarning without relying on tsx/jsx type definitions
rg -l "OnlyAdminWarning" --glob '*.tsx' --glob '*.jsx'Length of output: 81 🏁 Script executed: #!/bin/bash
# Show import statements and early code of page.tsx to check for OnlyAdminWarning import
sed -n '1,20p' src/app/dashboard/page.tsxLength of output: 677 Clean up unused commented code The • Remove the commented line in - {/* <OnlyAdminWarning /> */}📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| // src/app/dashboard/settings/layout.tsx | ||
| 'use client' | ||
|
|
||
| export default function SettingsLayout({ children }: { children: React.ReactNode }) { | ||
| return children | ||
| } |
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,32 @@ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 'use client' | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| export const runtime = 'edge'; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| import { useQuery } from "@tanstack/react-query"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| import { useParams } from "next/navigation"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| import MediaWikiForm from "@/components/mediawiki/Form"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| import { axiosInstance } from "@/axiosInstance"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| import { IPlatformProps } from "@/utils/interfaces"; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| export default function MediaWikiEditPage() { | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| const params = useParams(); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| const id = params?.id as string; | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| const { data } = useQuery({ | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| queryKey: ["platform", id], | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| queryFn: () => axiosInstance.get(`/platforms/${id}`), | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| }) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+16
to
+20
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Add error handling for the query. Your query implementation doesn't handle errors. If the API request fails, users won't see any feedback. - const { data } = useQuery({
+ const { data, isLoading, error } = useQuery({
queryKey: ["platform", id],
queryFn: () => axiosInstance.get(`/platforms/${id}`),
})📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| return ( | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <div className="flex flex-col gap-4"> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <div className="flex justify-between"> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <h1 className="text-2xl font-bold">Edit MediaWiki</h1> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </div> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| <div className="bg-base-100 p-8 rounded-lg"> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| {data && <MediaWikiForm edit={data.data as unknown as IPlatformProps} />} | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </div> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| </div> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ); | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+22
to
+31
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Add loading and error states to improve user experience. The component doesn't show loading or error states while fetching data. return (
<div className="flex flex-col gap-4">
<div className="flex justify-between">
<h1 className="text-2xl font-bold">Edit MediaWiki</h1>
</div>
<div className="bg-base-100 p-8 rounded-lg">
- {data && <MediaWikiForm edit={data.data as unknown as IPlatformProps} />}
+ {isLoading ? (
+ <div className="flex justify-center p-4">
+ <span className="loading loading-spinner loading-md"></span>
+ </div>
+ ) : error ? (
+ <div className="alert alert-error">
+ <span>Failed to load platform data. Please try again.</span>
+ </div>
+ ) : data && (
+ <MediaWikiForm edit={data.data as unknown as IPlatformProps} />
+ )}
</div>
</div>
);📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,29 @@ | ||||||||||||||||||||||||||||||||||||||||||
| 'use client' | ||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||
| export const runtime = 'edge'; | ||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||
| import { useQuery } from "@tanstack/react-query"; | ||||||||||||||||||||||||||||||||||||||||||
| import { useParams } from "next/navigation"; | ||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||
| import { axiosInstance } from "@/axiosInstance"; | ||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||
| export default function MediaWikiPage() { | ||||||||||||||||||||||||||||||||||||||||||
| const params = useParams(); | ||||||||||||||||||||||||||||||||||||||||||
| const id = params?.id as string; | ||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||
| const { data } = useQuery({ | ||||||||||||||||||||||||||||||||||||||||||
| queryKey: ["platform", id], | ||||||||||||||||||||||||||||||||||||||||||
| queryFn: () => axiosInstance.get(`/platforms/${id}`), | ||||||||||||||||||||||||||||||||||||||||||
| }) | ||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+14
to
+17
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Missing error and loading states for query The component doesn't handle loading or error states from the React Query hook, which could lead to a poor user experience if the API request fails or takes time to load. Consider adding error and loading states: - const { data } = useQuery({
+ const { data, isLoading, error } = useQuery({
queryKey: ["platform", id],
queryFn: () => axiosInstance.get(`/platforms/${id}`),
})
// Then in the return statement:
<div className="bg-base-100 p-8 rounded-lg">
+ {isLoading && <p>Loading...</p>}
+ {error && <p className="text-error">Error loading platform details</p>}
+ {data?.data && (
+ // Display data here
+ )}
</div>📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||
| return ( | ||||||||||||||||||||||||||||||||||||||||||
| <div className="flex flex-col gap-4"> | ||||||||||||||||||||||||||||||||||||||||||
| <div className="flex justify-between"> | ||||||||||||||||||||||||||||||||||||||||||
| <h1 className="text-2xl font-bold">MediaWiki</h1> | ||||||||||||||||||||||||||||||||||||||||||
| </div> | ||||||||||||||||||||||||||||||||||||||||||
| <div className="bg-base-100 p-8 rounded-lg"> | ||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||
| </div> | ||||||||||||||||||||||||||||||||||||||||||
| </div> | ||||||||||||||||||||||||||||||||||||||||||
| ) | ||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| 'use client' | ||
|
|
||
| import MediaWikiForm from "@/components/mediawiki/Form"; | ||
|
|
||
| export default function MediaWikiNewPage() { | ||
| return ( | ||
| <div className="flex flex-col gap-4"> | ||
| <div className="flex justify-between"> | ||
| <h1 className="text-2xl font-bold">New MediaWiki</h1> | ||
| </div> | ||
| <div className="bg-base-100 p-8 rounded-lg"> | ||
| <MediaWikiForm /> | ||
| </div> | ||
| </div> | ||
| ); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Verification agent
🧩 Analysis chain
Address the TODO comment about renaming.
There's a TODO comment about renaming to 'community-guardian'. Since this file is already in the community-guardian directory, this might be referring to the module name in ModuleContext.ts.
🏁 Script executed:
Length of output: 460
🏁 Script executed:
Length of output: 2860
Update the Community Guardian module identifier and remove the TODO
The module’s internal
nameandconfigPathstill use “violationDetection,” but your new directory and URLs are “community-guardian.” You’ll need to update both the module context and the lookup in your page.• In
src/constants/ModuleContext.ts:• In
src/app/dashboard/community-guardian/page.tsx:Once these changes are applied, you can remove the TODO comment.