diff --git a/frontend/components/pop/hardcoded/PopShell.tsx b/frontend/components/pop/hardcoded/PopShell.tsx index 3d4b6ac6..7f538aef 100644 --- a/frontend/components/pop/hardcoded/PopShell.tsx +++ b/frontend/components/pop/hardcoded/PopShell.tsx @@ -3,6 +3,7 @@ import React, { useState, useEffect, useRef, ReactNode } from "react"; import { useRouter } from "next/navigation"; import { useAuth } from "@/hooks/useAuth"; +import { usePopSettings } from "@/hooks/pop/usePopSettings"; interface PopShellProps { children: ReactNode; @@ -98,8 +99,12 @@ export function PopShell({ children, showBanner = true, title, showBack = false, logout(); }; - const marqueeText = - "[공지] 금일 오후 3시 전체 안전교육 실시 예정입니다. 전 직원 필참 바랍니다. \u00a0\u00a0|\u00a0\u00a0 [알림] 내일 설비 정기점검으로 인한 3호기 가동 중지 예정 \u00a0\u00a0|\u00a0\u00a0 [안내] 4월 생산실적 우수팀 발표 - 생산1팀 축하드립니다!"; + // POP 설정에서 배너 텍스트 로드 (POP화면설정에서 관리) + const { settings: popSettings } = usePopSettings("/pop/home"); + const homeConfig = (popSettings as any)?.screens?.home; + const bannerEnabled = homeConfig?.bannerEnabled ?? true; + const bannerText = homeConfig?.bannerText; + const marqueeText = bannerText || "[공지] 금일 오후 3시 전체 안전교육 실시 예정입니다. 전 직원 필참 바랍니다. \u00a0\u00a0|\u00a0\u00a0 [알림] 내일 설비 정기점검으로 인한 3호기 가동 중지 예정 \u00a0\u00a0|\u00a0\u00a0 [안내] 4월 생산실적 우수팀 발표 - 생산1팀 축하드립니다!"; return (
@@ -296,7 +301,7 @@ export function PopShell({ children, showBanner = true, title, showBack = false, {/* ===== NOTICE BANNER (Marquee) ===== */} - {showBanner &&
+ {showBanner && bannerEnabled &&
📢 공지