Skip to content

Commit

Permalink
redeploy
Browse files Browse the repository at this point in the history
  • Loading branch information
kleenpulse committed Jul 25, 2024
1 parent 19ae1cb commit 2183012
Show file tree
Hide file tree
Showing 16 changed files with 80 additions and 69 deletions.
6 changes: 4 additions & 2 deletions src/app/(landing-routes)/blog/[id]/BlogDetailsPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,10 @@ import Link from "next/link";
import { useSearchParams } from "next/navigation";
import { useEffect, useState } from "react";

import Comment, { CommentProperties } from "~/components/common/Comment";
import { sampleComments } from "~/components/common/Comment/sample-comments";
import Comment, {
CommentProperties,
} from "~/components/common/comment-component";
import { sampleComments } from "~/components/common/comment-component/sample-comments";
import LoadingSpinner from "~/components/miscellaneous/loading-spinner";
import RelatedArticle from "./RelatedArticle";

Expand Down
2 changes: 1 addition & 1 deletion src/app/(landing-routes)/blog/[id]/RelatedArticle.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { useRouter } from "next/navigation";

import BlogCard from "~/components/layouts/BlogCards";
import { blogPosts } from "../page";
import { blogPosts } from "../data/mock";

export type New = {
id: number;
Expand Down
4 changes: 2 additions & 2 deletions src/app/(landing-routes)/blog/comments/page.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { Session } from "next-auth";

import Comment from "~/components/common/comment";
import { sampleComments } from "~/components/common/comment/sample-comments";
import Comment from "~/components/common/comment-component";
import { sampleComments } from "~/components/common/comment-component/sample-comments";

const CommentPage = () => {
const mockSession: Session = {
Expand Down
65 changes: 65 additions & 0 deletions src/app/(landing-routes)/blog/data/mock.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
import {
blogCard1,
blogCard2,
blogCard3,
blogCard4,
blogCard5,
blogCard6,
} from "../../../../../public/images/blogPage/utils";

export const blogPosts = [
{
id: 1,
title: "The Power of Networking: How to Build Meaningful Connections",
date: "Jul 12, 2024",
readTime: "5",
category: "Business",
image: blogCard1,
labelClassName: "bg-primary",
},
{
id: 2,
title: "The Global Impact of Climate Change: A Look at the Evidence",
date: "Jul 12, 2024",
readTime: "5",
category: "World News",
image: blogCard2,
labelClassName: "bg-warning",
},
{
id: 3,
title: "5 Easy and Delicious Recipes for Busy Weeknights",
date: "Jul 12, 2024",
readTime: "5",
category: "Food",
image: blogCard3,
labelClassName: "bg-success",
},
{
id: 4,
title: "5 Simple Habits to Improve Your Mental Wellbeing",
date: "Jul 12, 2024",
readTime: "5",
category: "Lifestyle",
image: blogCard4,
labelClassName: "bg-primary",
},
{
id: 5,
title: "The Ultimate Guide to Dressing Stylishly with Fewer Clothes",
date: "Jul 12, 2024",
readTime: "5",
category: "Fashion",
image: blogCard5,
labelClassName: "bg-success",
},
{
id: 6,
title: "The Future of Travel: What Will the World Look Like in 2030?",
date: "Jul 12, 2024",
readTime: "5",
category: "World News",
image: blogCard6,
labelClassName: "bg-warning",
},
];
60 changes: 1 addition & 59 deletions src/app/(landing-routes)/blog/page.tsx
Original file line number Diff line number Diff line change
@@ -1,67 +1,9 @@
import CustomButton from "~/components/common/common-button/common-button";
import BlogCard from "~/components/layouts/BlogCards";
import {
blogCard1,
blogCard2,
blogCard3,
blogCard4,
blogCard5,
blogCard6,
} from "../../../../public/images/blogPage/utils";
import HeroSection from "../../../components/extDynamicPages/blogCollection/BlogPageHero";
import { blogPosts } from "./data/mock";

const BlogHome = () => {
const blogPosts = [
{
title: "The Power of Networking: How to Build Meaningful Connections",
date: "Jul 12, 2024",
readTime: "5",
category: "Business",
image: blogCard1,
labelClassName: "bg-primary",
},
{
title: "The Global Impact of Climate Change: A Look at the Evidence",
date: "Jul 12, 2024",
readTime: "5",
category: "World News",
image: blogCard2,
labelClassName: "bg-warning",
},
{
title: "5 Easy and Delicious Recipes for Busy Weeknights",
date: "Jul 12, 2024",
readTime: "5",
category: "Food",
image: blogCard3,
labelClassName: "bg-success",
},
{
title: "5 Simple Habits to Improve Your Mental Wellbeing",
date: "Jul 12, 2024",
readTime: "5",
category: "Lifestyle",
image: blogCard4,
labelClassName: "bg-primary",
},
{
title: "The Ultimate Guide to Dressing Stylishly with Fewer Clothes",
date: "Jul 12, 2024",
readTime: "5",
category: "Fashion",
image: blogCard5,
labelClassName: "bg-success",
},
{
title: "The Future of Travel: What Will the World Look Like in 2030?",
date: "Jul 12, 2024",
readTime: "5",
category: "World News",
image: blogCard6,
labelClassName: "bg-warning",
},
];

return (
<div>
<HeroSection />
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/test/blog/comment/button-wrapper.test.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { render, screen } from "@testing-library/react";

import ButtonWrapper from "~/components/common/comment/button-wrapper";
import ButtonWrapper from "~/components/common/comment-component/button-wrapper";

describe("button wrapper component", () => {
it("should render children correctly", () => {
Expand Down
2 changes: 1 addition & 1 deletion src/test/blog/comment/comment-actions.test.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { fireEvent, render, screen } from "@testing-library/react";

import CommentActions from "~/components/common/comment/comment-actions";
import CommentActions from "~/components/common/comment-component/comment-actions";

describe("comment actions component", () => {
const mockOnLike = vi.fn();
Expand Down
2 changes: 1 addition & 1 deletion src/test/blog/comment/comment-body.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { fireEvent, render, screen } from "@testing-library/react";
import moment from "moment";
import { Session } from "next-auth";

import { CommentBody } from "~/components/common/comment/comment-body";
import { CommentBody } from "~/components/common/comment-component/comment-body";

describe("comment body component", () => {
const mockSession: Session = {
Expand Down
2 changes: 1 addition & 1 deletion src/test/blog/comment/comment-reply.test.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { fireEvent, render, screen } from "@testing-library/react";
import { Session } from "next-auth";

import { ReplyForm } from "~/components/common/comment/comment-reply";
import { ReplyForm } from "~/components/common/comment-component/comment-reply";

describe("comment reply component", () => {
const mockSession: Session = {
Expand Down
4 changes: 3 additions & 1 deletion src/test/blog/comment/index.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@ import { fireEvent, render, screen } from "@testing-library/react";
import { Session } from "next-auth";
import { describe, expect, it } from "vitest";

import Comment, { CommentProperties } from "~/components/common/comment";
import Comment, {
CommentProperties,
} from "~/components/common/comment-component";

describe("comment box component", () => {
const mockSession: Session = {
Expand Down

0 comments on commit 2183012

Please sign in to comment.