diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/icon.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/ui/CtrIcon.tsx
similarity index 50%
rename from apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/icon.tsx
rename to apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/ui/CtrIcon.tsx
index f51598c4..bbdd8e3d 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/icon.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/ui/CtrIcon.tsx
@@ -1,12 +1,12 @@
import cx from 'classnames';
import type { ReactNode } from 'react';
-import type { IconProps } from '@/services/juxt-web/views/web/components/icon';
+import type { IconProps } from '@/services/juxt-web/views/web/components/ui/WebIcon';
export function CtrIcon(props: IconProps): ReactNode {
- const baseClass = props.baseClass ?? 'icon';
+ const type = props.type ?? 'icon';
return (
-
-
+
+
);
}
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/mii-icon.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/ui/CtrMiiIcon.tsx
similarity index 82%
rename from apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/mii-icon.tsx
rename to apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/ui/CtrMiiIcon.tsx
index d4993d64..a6f6e2cf 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/mii-icon.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/components/ui/CtrMiiIcon.tsx
@@ -1,19 +1,19 @@
import { utils } from '@/services/juxt-web/views/utils';
-import { CtrIcon } from '@/services/juxt-web/views/ctr/components/icon';
+import { CtrIcon } from '@/services/juxt-web/views/ctr/components/ui/CtrIcon';
import type { ReactNode } from 'react';
-import type { MiiIconProps } from '@/services/juxt-web/views/web/components/mii-icon';
+import type { MiiIconProps } from '@/services/juxt-web/views/web/components/ui/WebMiiIcon';
export function CtrMiiIcon(props: MiiIconProps): ReactNode {
const url = props.face_url ?? utils.cdn(props.ctx, `/mii/${props.pid}/normal_face.png`);
const href = `/users/${props.pid}`;
- const baseClass = !props.big ? 'mii-icon' : undefined;
+ const type = props.type ?? 'mii-icon';
return (
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/messageThread.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/messageThread.tsx
index 875e7388..ab0abeda 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/messageThread.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/messageThread.tsx
@@ -3,7 +3,7 @@ import cx from 'classnames';
import { CtrPageBody, CtrRoot } from '@/services/juxt-web/views/ctr/root';
import { CtrNewPostView } from '@/services/juxt-web/views/ctr/newPostView';
import { utils } from '@/services/juxt-web/views/utils';
-import { CtrMiiIcon } from '@/services/juxt-web/views/ctr/components/mii-icon';
+import { CtrMiiIcon } from '@/services/juxt-web/views/ctr/components/ui/CtrMiiIcon';
import type { ReactNode } from 'react';
import type { MessageThreadItemProps, MessageThreadViewProps } from '@/services/juxt-web/views/web/messageThread';
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/messages.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/messages.tsx
index 65e3851a..0ba684ca 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/messages.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/messages.tsx
@@ -1,5 +1,5 @@
import cx from 'classnames';
-import { CtrMiiIcon } from '@/services/juxt-web/views/ctr/components/mii-icon';
+import { CtrMiiIcon } from '@/services/juxt-web/views/ctr/components/ui/CtrMiiIcon';
import { humanFromNow } from '@/util';
import type { ReactNode } from 'react';
import type {
@@ -40,7 +40,7 @@ export function CtrMessagesView(props: MessagesViewProps): ReactNode {
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/notificationListView.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/notificationListView.tsx
index b4e132c3..c0530544 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/notificationListView.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/notificationListView.tsx
@@ -1,7 +1,7 @@
import cx from 'classnames';
import { CtrPageBody, CtrRoot } from '@/services/juxt-web/views/ctr/root';
-import { CtrMiiIcon } from '@/services/juxt-web/views/ctr/components/mii-icon';
-import { CtrIcon } from '@/services/juxt-web/views/ctr/components/icon';
+import { CtrMiiIcon } from '@/services/juxt-web/views/ctr/components/ui/CtrMiiIcon';
+import { CtrIcon } from '@/services/juxt-web/views/ctr/components/ui/CtrIcon';
import { humanFromNow } from '@/util';
import type { ReactNode } from 'react';
import type { NotificationItemProps, NotificationListViewProps, NotificationWrapperViewProps } from '@/services/juxt-web/views/web/notificationListView';
@@ -12,7 +12,7 @@ function CtrNotificationItem(props: NotificationItemProps): ReactNode {
const NickName = ({ userId }: { userId: string | number | null | undefined }): ReactNode => {userId ? props.ctx.usersMap.get(Number(userId)) : null};
return (
<>
-
+
{notif.users.length === 1
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/post.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/post.tsx
index 7ab3160c..ddb7521e 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/post.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/ctr/post.tsx
@@ -1,7 +1,7 @@
import cx from 'classnames';
import moment from 'moment';
import { utils } from '@/services/juxt-web/views/utils';
-import { CtrMiiIcon } from '@/services/juxt-web/views/ctr/components/mii-icon';
+import { CtrMiiIcon } from '@/services/juxt-web/views/ctr/components/ui/CtrMiiIcon';
import type { ReactNode } from 'react';
import type { PostScreenshotProps, PostViewProps } from '@/services/juxt-web/views/web/post';
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/communityView.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/communityView.tsx
index 254a0e0a..2011b80c 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/communityView.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/communityView.tsx
@@ -4,7 +4,7 @@ import { PortalPageBody, PortalRoot } from '@/services/juxt-web/views/portal/roo
import { PortalNavBar } from '@/services/juxt-web/views/portal/navbar';
import { PortalNewPostView } from '@/services/juxt-web/views/portal/newPostView';
import { PortalPostListClosedView } from '@/services/juxt-web/views/portal/postList';
-import { PortalIcon } from '@/services/juxt-web/views/portal/icons';
+import { PortalUIIcon } from '@/services/juxt-web/views/portal/components/ui/PortalUIIcon';
import type { ReactNode } from 'react';
import type { CommunityViewProps } from '@/services/juxt-web/views/web/communityView';
@@ -71,13 +71,13 @@ export function PortalCommunityView(props: CommunityViewProps): ReactNode {
{community.name}
-
+
{' '}
{props.totalPosts}
{' | '}
-
+
{' '}
{community.followers}
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/icon.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/icon.tsx
deleted file mode 100644
index 2f3df92d..00000000
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/icon.tsx
+++ /dev/null
@@ -1,12 +0,0 @@
-import cx from 'classnames';
-import type { ReactNode } from 'react';
-import type { IconProps } from '@/services/juxt-web/views/web/components/icon';
-
-export function PortalIconView(props: IconProps): ReactNode {
- const baseClass = props.baseClass ?? 'icon';
- return (
-
-
-
- );
-}
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/ui/PortalIcon.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/ui/PortalIcon.tsx
new file mode 100644
index 00000000..a315e245
--- /dev/null
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/ui/PortalIcon.tsx
@@ -0,0 +1,12 @@
+import cx from 'classnames';
+import type { ReactNode } from 'react';
+import type { IconProps } from '@/services/juxt-web/views/web/components/ui/WebIcon';
+
+export function PortalIcon(props: IconProps): ReactNode {
+ const type = props.type ?? 'icon';
+ return (
+
+
+
+ );
+}
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/mii-icon.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/ui/PortalMiiIcon.tsx
similarity index 66%
rename from apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/mii-icon.tsx
rename to apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/ui/PortalMiiIcon.tsx
index bd54c797..ed20da01 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/mii-icon.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/ui/PortalMiiIcon.tsx
@@ -1,21 +1,21 @@
import { utils } from '@/services/juxt-web/views/utils';
-import { PortalIconView } from '@/services/juxt-web/views/portal/components/icon';
+import { PortalIcon } from '@/services/juxt-web/views/portal/components/ui/PortalIcon';
import type { ReactNode } from 'react';
-import type { MiiIconProps } from '@/services/juxt-web/views/web/components/mii-icon';
+import type { MiiIconProps } from '@/services/juxt-web/views/web/components/ui/WebMiiIcon';
export function PortalMiiIcon(props: MiiIconProps): ReactNode {
const url = props.face_url ?? utils.cdn(props.ctx, `/mii/${props.pid}/normal_face.png`);
const href = `/users/${props.pid}`;
- const baseClass = !props.big ? 'mii-icon' : undefined;
+ const type = props.type ?? 'mii-icon';
return (
-
-
+
);
}
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/ui/PortalUIIcon.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/ui/PortalUIIcon.tsx
new file mode 100644
index 00000000..7bc12599
--- /dev/null
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/components/ui/PortalUIIcon.tsx
@@ -0,0 +1,36 @@
+/* eslint-disable no-restricted-imports -- raw import plugin does not support path aliases */
+import devBadgeIcon from '../../assets/dev_badge.svg?raw';
+import modBadgeIcon from '../../assets/mod_badge.svg?raw';
+import starBadgeIcon from '../../assets/star_badge.svg?raw';
+import testerBadgeIcon from '../../assets/tester_badge.svg?raw';
+import birthdayIcon from '../../assets/birthday.svg?raw';
+import countryIcon from '../../assets/country.svg?raw';
+import followersIcon from '../../assets/followers.svg?raw';
+import postsIcon from '../../assets/posts.svg?raw';
+import skillIcon from '../../assets/skill.svg?raw';
+import topicIcon from '../../assets/topic.svg?raw';
+import type { ReactNode } from 'react';
+
+const icons = {
+ 'dev-badge': devBadgeIcon,
+ 'mod-badge': modBadgeIcon,
+ 'star-badge': starBadgeIcon,
+ 'tester-badge': testerBadgeIcon,
+ 'birthday': birthdayIcon,
+ 'country': countryIcon,
+ 'followers': followersIcon,
+ 'posts': postsIcon,
+ 'skill': skillIcon,
+ 'topic': topicIcon
+} as const;
+
+type PortalUIIcon = keyof typeof icons;
+
+export type PortalUIIconProps = {
+ name: PortalUIIcon;
+};
+
+export function PortalUIIcon(props: PortalUIIconProps): ReactNode {
+ const iconHtml = icons[props.name];
+ return ;
+}
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/icons.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/icons.tsx
deleted file mode 100644
index 06e33d59..00000000
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/icons.tsx
+++ /dev/null
@@ -1,36 +0,0 @@
-/* eslint-disable no-restricted-imports -- raw import plugin does not support path aliases */
-import devBadgeIcon from './assets/dev_badge.svg?raw';
-import modBadgeIcon from './assets/mod_badge.svg?raw';
-import starBadgeIcon from './assets/star_badge.svg?raw';
-import testerBadgeIcon from './assets/tester_badge.svg?raw';
-import birthdayIcon from './assets/birthday.svg?raw';
-import countryIcon from './assets/country.svg?raw';
-import followersIcon from './assets/followers.svg?raw';
-import postsIcon from './assets/posts.svg?raw';
-import skillIcon from './assets/skill.svg?raw';
-import topicIcon from './assets/topic.svg?raw';
-import type { ReactNode } from 'react';
-
-const icons = {
- 'dev-badge': devBadgeIcon,
- 'mod-badge': modBadgeIcon,
- 'star-badge': starBadgeIcon,
- 'tester-badge': testerBadgeIcon,
- 'birthday': birthdayIcon,
- 'country': countryIcon,
- 'followers': followersIcon,
- 'posts': postsIcon,
- 'skill': skillIcon,
- 'topic': topicIcon
-} as const;
-
-type PortalIcon = keyof typeof icons;
-
-export type PortalIconProps = {
- name: PortalIcon;
-};
-
-export function PortalIcon(props: PortalIconProps): ReactNode {
- const iconHtml = icons[props.name];
- return ;
-}
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/notificationListView.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/notificationListView.tsx
index f61bec5c..2f8c8c8c 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/notificationListView.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/notificationListView.tsx
@@ -2,8 +2,8 @@ import cx from 'classnames';
import { PortalPageBody, PortalRoot } from '@/services/juxt-web/views/portal/root';
import { PortalNavBar } from '@/services/juxt-web/views/portal/navbar';
import { humanFromNow } from '@/util';
-import { PortalMiiIcon } from '@/services/juxt-web/views/portal/components/mii-icon';
-import { PortalIconView } from '@/services/juxt-web/views/portal/components/icon';
+import { PortalMiiIcon } from '@/services/juxt-web/views/portal/components/ui/PortalMiiIcon';
+import { PortalIcon } from '@/services/juxt-web/views/portal/components/ui/PortalIcon';
import type { ReactNode } from 'react';
import type { NotificationItemProps, NotificationListViewProps, NotificationWrapperViewProps } from '@/services/juxt-web/views/web/notificationListView';
@@ -13,7 +13,7 @@ function PortalNotificationItem(props: NotificationItemProps): ReactNode {
const NickName = ({ userId }: { userId: string | number | null | undefined }): ReactNode => {userId ? props.ctx.usersMap.get(Number(userId)) : null};
return (
<>
-
+
{notif.users.length === 1
@@ -63,7 +63,7 @@ function PortalNotificationItem(props: NotificationItemProps): ReactNode {
if (notif.type === 'notice') {
return (
<>
-
+
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/post.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/post.tsx
index c24457fe..0311866e 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/post.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/post.tsx
@@ -1,7 +1,7 @@
import cx from 'classnames';
import moment from 'moment';
import { utils } from '@/services/juxt-web/views/utils';
-import { PortalIcon } from '@/services/juxt-web/views/portal/icons';
+import { PortalUIIcon } from '@/services/juxt-web/views/portal/components/ui/PortalUIIcon';
import type { ReactNode } from 'react';
import type { PostScreenshotProps, PostViewProps } from '@/services/juxt-web/views/web/post';
@@ -68,7 +68,7 @@ export function PortalPostView(props: PostViewProps): ReactNode {
? (
{/* TODO this has been modified due to inbalanced tags */}
-
+
{post.topic_tag}
)
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/userPageView.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/userPageView.tsx
index 8d316047..92721c9e 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/portal/userPageView.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/portal/userPageView.tsx
@@ -3,7 +3,7 @@ import moment from 'moment';
import { utils } from '@/services/juxt-web/views/utils';
import { PortalPageBody, PortalRoot } from '@/services/juxt-web/views/portal/root';
import { PortalNavBar } from '@/services/juxt-web/views/portal/navbar';
-import { PortalIcon } from '@/services/juxt-web/views/portal/icons';
+import { PortalUIIcon } from '@/services/juxt-web/views/portal/components/ui/PortalUIIcon';
import type { ReactNode } from 'react';
import type { UserPageViewProps } from '@/services/juxt-web/views/web/userPageView';
@@ -16,7 +16,7 @@ export function PortalUserTier(props: { user: UserPageViewProps['user'] }): Reac
tierPart = (
{' | '}
-
+
);
}
@@ -24,7 +24,7 @@ export function PortalUserTier(props: { user: UserPageViewProps['user'] }): Reac
tierPart = (
{' | '}
-
+
);
}
@@ -32,7 +32,7 @@ export function PortalUserTier(props: { user: UserPageViewProps['user'] }): Reac
tierPart = (
{' | '}
-
+
);
}
@@ -41,7 +41,7 @@ export function PortalUserTier(props: { user: UserPageViewProps['user'] }): Reac
accessLevelPart = (
{' | '}
-
+
);
}
@@ -49,7 +49,7 @@ export function PortalUserTier(props: { user: UserPageViewProps['user'] }): Reac
accessLevelPart = (
{' | '}
-
+
);
}
@@ -57,7 +57,7 @@ export function PortalUserTier(props: { user: UserPageViewProps['user'] }): Reac
accessLevelPart = (
{' | '}
-
+
);
}
@@ -120,13 +120,13 @@ export function PortalUserPageView(props: UserPageViewProps): ReactNode {
{' | '}
-
+
{' '}
{props.totalPosts}
{' | '}
-
+
{' '}
{props.userContent.following_users.length - 1}
@@ -134,7 +134,7 @@ export function PortalUserPageView(props: UserPageViewProps): ReactNode {
? (
{' | '}
-
+
{' '}
{props.user.country}
@@ -144,7 +144,7 @@ export function PortalUserPageView(props: UserPageViewProps): ReactNode {
? (
{' | '}
-
+
{' '}
{moment.utc(props.user.birthdate).format('MMM Do')}
@@ -154,7 +154,7 @@ export function PortalUserPageView(props: UserPageViewProps): ReactNode {
? (
{' | '}
-
+
{' '}
{props.userSettings.game_skill === 0
? (
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/editCommunityView.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/editCommunityView.tsx
index a0df0e44..e92a09f1 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/editCommunityView.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/editCommunityView.tsx
@@ -17,8 +17,6 @@ export function WebEditCommunityView(props: EditCommunityViewProps): ReactNode {
const imageId = community.parent ? community.parent : community.olive_community_id;
const head = (
<>
-
-
Juxt -
{community.name}
@@ -27,7 +25,7 @@ export function WebEditCommunityView(props: EditCommunityViewProps): ReactNode {
);
return (
-
+
Edit Community
@@ -62,8 +60,9 @@ export function WebEditCommunityView(props: EditCommunityViewProps): ReactNode {
-
-
+
+
+
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/manageCommunityView.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/manageCommunityView.tsx
index 701b6bd2..46573462 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/manageCommunityView.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/manageCommunityView.tsx
@@ -2,6 +2,7 @@ import { WebRoot, WebWrapper } from '@/services/juxt-web/views/web/root';
import { WebNavBar } from '@/services/juxt-web/views/web/navbar';
import { WebModerationTabs } from '@/services/juxt-web/views/web/admin/admin';
import { utils } from '@/services/juxt-web/views/utils';
+import { WebSearchBar } from '@/services/juxt-web/views/web/components/ui/WebSearchBar';
import type { ReactNode } from 'react';
import type { InferSchemaType } from 'mongoose';
import type { RenderContext } from '@/services/juxt-web/views/context';
@@ -16,12 +17,11 @@ export type ManageCommunityViewProps = {
};
export function WebManageCommunityView(props: ManageCommunityViewProps): ReactNode {
- const head = ;
const prevUrl = utils.url('/admin/communities', { page: props.page - 1, search: props.search });
const nextUrl = utils.url('/admin/communities', { page: props.page + 1, search: props.search });
return (
-
+
Manage Communities
@@ -29,7 +29,7 @@ export function WebManageCommunityView(props: ManageCommunityViewProps): ReactNo
-
+
diff --git a/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/moderateUserView.tsx b/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/moderateUserView.tsx
index fa3f506a..d1c1da95 100644
--- a/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/moderateUserView.tsx
+++ b/apps/juxtaposition-ui/src/services/juxt-web/views/web/admin/moderateUserView.tsx
@@ -32,14 +32,12 @@ export function WebModerateUserView(props: ModerateUserViewProps): ReactNode {
const pnidName = props.pnid.mii?.name ?? props.pnid.username;
const head = (
<>
-
-
>
);
return (
-
+
{props.ctx.lang.global.user_page}
@@ -134,7 +132,7 @@ export function WebModerateUserView(props: ModerateUserViewProps): ReactNode {
-
+