Files
deerflow-code/web-code/components/taskManagement/XingdongTy.tsx
T
2026-05-27 19:43:15 +08:00

36 lines
952 B
TypeScript

import React, { useEffect, useState } from "react";
import "./css/iframe.css";
import { useTheme } from "@/contexts/ThemeContext";
import { PageType } from "@/components/Sidebar";
interface XingdongTyPageProps {
title: string;
category: string;
subCategory: string;
onNavigate: (page: PageType) => void;
}
const TYURL = import.meta.env.VITE_AIPI_B2ACTOR_URL || "";
const XingdongTyPage: React.FC<XingdongTyPageProps> = ({ onNavigate }) => {
const { theme } = useTheme();
const isDark = theme === "dark";
const [iframeUrl, setIframeUrl] = useState("");
useEffect(() => {
initIframeUrl();
}, []);
const initIframeUrl = () => {
const url = `${TYURL}/fromB/toPage?defaultPage=iframeXdty`;
console.log({ iframeUrl: url });
setIframeUrl(url);
};
return (
<div className="iframe-container">
<iframe src={iframeUrl} className="full-size-iframe"></iframe>
</div>
);
};
export default XingdongTyPage;