Add statistics panel
This commit is contained in:
@@ -13,6 +13,7 @@ import { BehaviorDetails } from "@Panel/BehaviorDetails/BehaviorDetails";
|
||||
import { ClipPlayer } from "@Panel/ClipPlayer/ClipPlayer";
|
||||
import { ClipRecorder } from "@Panel/ClipPlayer/ClipRecorder";
|
||||
import { ClipDetails } from "@Panel/ClipDetails/ClipDetails";
|
||||
import { Statistics } from "@Panel/Statistics/Statistics";
|
||||
|
||||
interface IPanelInfo {
|
||||
nameKey: string;
|
||||
@@ -36,6 +37,7 @@ type PanelId = ""
|
||||
| "BehaviorDetails" // 行为属性
|
||||
| "ClipPlayer" // 剪辑影片
|
||||
| "ClipDetails" // 剪辑详情
|
||||
| "Statistics" // 统计信息
|
||||
;
|
||||
|
||||
const PanelInfoMap = new Map<PanelId, IPanelInfo>();
|
||||
@@ -79,6 +81,10 @@ PanelInfoMap.set("ClipDetails", {
|
||||
nameKey: "Panel.Title.Behavior.Clip.Details", introKay: "Panel.Info.Behavior.Clip.Details",
|
||||
class: ClipDetails
|
||||
});
|
||||
PanelInfoMap.set("Statistics", {
|
||||
nameKey: "Panel.Title.Statistics", introKay: "Panel.Info.Statistics",
|
||||
class: Statistics
|
||||
});
|
||||
|
||||
function getPanelById(panelId: PanelId): ReactNode {
|
||||
switch (panelId) {
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
@import "../../Component/Theme/Theme.scss";
|
||||
|
||||
div.statistics-panel {
|
||||
width: 100%;
|
||||
min-height: 100%;
|
||||
padding: 10px;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
import { Component, ReactNode } from "react";
|
||||
import { useStatusWithEvent, IMixinStatusProps } from "@Context/Status";
|
||||
import { useSetting, IMixinSettingProps } from "@Context/Setting";
|
||||
import Theme from "@Component/Theme/Theme";
|
||||
import "./Statistics.scss";
|
||||
|
||||
interface IStatisticsProps {
|
||||
|
||||
}
|
||||
|
||||
@useSetting
|
||||
@useStatusWithEvent("labelChange", "focusLabelChange", "labelAttrChange")
|
||||
class Statistics extends Component<IStatisticsProps & IMixinStatusProps & IMixinSettingProps> {
|
||||
|
||||
public render(): ReactNode {
|
||||
return <Theme className="statistics-panel">
|
||||
|
||||
</Theme>;
|
||||
}
|
||||
}
|
||||
|
||||
export { Statistics };
|
||||
Reference in New Issue
Block a user