diff --git a/components/details/details-content.tsx b/components/details/details-content.tsx index f80029d..bf0a483 100644 --- a/components/details/details-content.tsx +++ b/components/details/details-content.tsx @@ -21,7 +21,7 @@ type Article = { title: string; }[]; files: { - file_url: string; + fileUrl: string; file_alt: string; }[]; }; @@ -206,9 +206,9 @@ export default function DetailContent() {
- {articleDetail?.files?.[0]?.file_url ? ( + {articleDetail?.files?.[0]?.fileUrl ? ( Berita
@@ -631,7 +629,7 @@ export default function EditArticleForm(props: { isDetail: boolean }) { width={480} height={360} alt={`image-${index}`} - src={file.file_url || "/default-avatar.png"} + src={file.fileUrl || "/default-avatar.png"} className="h-[100px] object-cover w-[150px]" /> @@ -654,7 +652,7 @@ export default function EditArticleForm(props: { isDetail: boolean }) { width={480} height={360} alt={`image-${index}`} - src={file?.file_url || "/default-avatar.png"} + src={file?.fileUrl || "/default-avatar.png"} className="h-[100px] object-cover w-[150px]" /> diff --git a/components/form/login.tsx b/components/form/login.tsx index 2d5ba59..c55d7ed 100644 --- a/components/form/login.tsx +++ b/components/form/login.tsx @@ -196,16 +196,14 @@ export default function Login() {
Mikul News Logo
-

- Portal Kebaikan Indonesia -

+

Portal Kabar Harapan

Platform berita terpercaya untuk informasi terkini

@@ -428,7 +426,7 @@ export default function Login() { Selamat Datang

- Portal Kebaikan Indonesia- Platform berita terpercaya + Portal Kabar Harapan- Platform berita terpercaya

diff --git a/components/landing-page/banner-news.tsx b/components/landing-page/banner-news.tsx index 65fb4f2..7ac0e8b 100644 --- a/components/landing-page/banner-news.tsx +++ b/components/landing-page/banner-news.tsx @@ -11,7 +11,7 @@ type Article = { createdByName: string; thumbnailUrl: string; categories: { title: string }[]; - files: { file_url: string; file_alt: string }[]; + files: { fileUrl: string; file_alt: string }[]; }; export default function BannerNews() { @@ -51,7 +51,7 @@ export default function BannerNews() { {/* Artikel utama */}
{mainArticle.files?.[0]?.file_alt @@ -70,7 +70,7 @@ export default function BannerNews() { {sideArticles.map((article) => (
{article.files?.[0]?.file_alt diff --git a/components/landing-page/breaking-news.tsx b/components/landing-page/breaking-news.tsx index ca12a9e..8477bfc 100644 --- a/components/landing-page/breaking-news.tsx +++ b/components/landing-page/breaking-news.tsx @@ -15,7 +15,7 @@ type Article = { createdByName: string; thumbnailUrl: string; categories: { title: string }[]; - files: { file_url: string; file_alt: string }[]; + files: { fileUrl: string; file_alt: string }[]; }; type PaginationMeta = { @@ -82,7 +82,7 @@ export default function BreakingNews() { {article.files?.[0]?.file_alt { {post.files?.[0]?.file_alt
@@ -224,7 +224,7 @@ const SidebarContent = ({ className="flex flex-col" > - Kebaikan Indonesia + Kabar Harapan Admin Panel diff --git a/service/http-config/axios-base-instance.ts b/service/http-config/axios-base-instance.ts index de3efbe..4b3e309 100644 --- a/service/http-config/axios-base-instance.ts +++ b/service/http-config/axios-base-instance.ts @@ -6,7 +6,7 @@ const axiosBaseInstance = axios.create({ baseURL, headers: { "Content-Type": "application/json", - "X-Client-Key": "bb65b1ad-e954-4a1a-b4d0-74df5bb0b640" + "X-Client-Key": "f5a4ef1b-53ba-48df-9520-4c105dbec533", }, }); diff --git a/service/http-config/axios-interceptor-instance.ts b/service/http-config/axios-interceptor-instance.ts index 422a192..f414c73 100644 --- a/service/http-config/axios-interceptor-instance.ts +++ b/service/http-config/axios-interceptor-instance.ts @@ -10,7 +10,7 @@ const axiosInterceptorInstance = axios.create({ baseURL, headers: { "Content-Type": "application/json", - "X-Client-Key": "bb65b1ad-e954-4a1a-b4d0-74df5bb0b640" + "X-Client-Key": "f5a4ef1b-53ba-48df-9520-4c105dbec533", }, withCredentials: true, }); diff --git a/service/http-config/http-base-services.ts b/service/http-config/http-base-services.ts index 755d158..af73f4c 100644 --- a/service/http-config/http-base-services.ts +++ b/service/http-config/http-base-services.ts @@ -2,11 +2,11 @@ import axiosBaseInstance from "./axios-base-instance"; const defaultHeaders = { "Content-Type": "application/json", - "X-Client-Key": "bb65b1ad-e954-4a1a-b4d0-74df5bb0b640" + "X-Client-Key": "f5a4ef1b-53ba-48df-9520-4c105dbec533", }; -export async function httpGet(pathUrl: any, headers?: any) { - console.log("X-HEADERS : ", defaultHeaders) +export async function httpGet(pathUrl: any, headers?: any) { + console.log("X-HEADERS : ", defaultHeaders); const mergedHeaders = { ...defaultHeaders, ...headers, diff --git a/service/http-config/http-interceptor-services.ts b/service/http-config/http-interceptor-services.ts index 4d33d96..a707b38 100644 --- a/service/http-config/http-interceptor-services.ts +++ b/service/http-config/http-interceptor-services.ts @@ -5,11 +5,11 @@ import { getCsrfToken } from "../master-user"; const defaultHeaders = { "Content-Type": "application/json", - "X-Client-Key": "bb65b1ad-e954-4a1a-b4d0-74df5bb0b640" + "X-Client-Key": "f5a4ef1b-53ba-48df-9520-4c105dbec533", }; export async function httpGetInterceptor(pathUrl: any) { - console.log("X-HEADERS : ", defaultHeaders) + console.log("X-HEADERS : ", defaultHeaders); const response = await axiosInterceptorInstance .get(pathUrl, { headers: defaultHeaders }) .catch((error) => error.response); @@ -35,7 +35,11 @@ export async function httpGetInterceptor(pathUrl: any) { } } -export async function httpPostInterceptor(pathUrl: any, data: any, headers?: any) { +export async function httpPostInterceptor( + pathUrl: any, + data: any, + headers?: any +) { const resCsrf = await getCsrfToken(); const csrfToken = resCsrf?.data?.csrf_token; @@ -67,7 +71,11 @@ export async function httpPostInterceptor(pathUrl: any, data: any, headers?: any } } -export async function httpPutInterceptor(pathUrl: any, data: any, headers?: any) { +export async function httpPutInterceptor( + pathUrl: any, + data: any, + headers?: any +) { const resCsrf = await getCsrfToken(); const csrfToken = resCsrf?.data?.csrf_token; @@ -99,7 +107,7 @@ export async function httpPutInterceptor(pathUrl: any, data: any, headers?: any) } export async function httpDeleteInterceptor(pathUrl: any, headers?: any) { - const resCsrf = await getCsrfToken(); + const resCsrf = await getCsrfToken(); const csrfToken = resCsrf?.data?.csrf_token; const mergedHeaders = {