Add label list panel
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
|
||||
div.label-list-command-bar {
|
||||
width: 100%;
|
||||
height: 30px;
|
||||
flex-shrink: 0;
|
||||
display: flex;
|
||||
|
||||
div.command-item {
|
||||
width: 30px;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
flex-shrink: 0;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
user-select: none;
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
import { Theme } from "@Component/Theme/Theme";
|
||||
import { Component } from "react";
|
||||
import "./LabelList.scss";
|
||||
|
||||
interface ILabelListProps {
|
||||
|
||||
}
|
||||
|
||||
class LabelList extends Component<ILabelListProps> {
|
||||
|
||||
public render() {
|
||||
return <Theme>LabelList</Theme>
|
||||
}
|
||||
}
|
||||
|
||||
export { LabelList };
|
||||
@@ -0,0 +1,23 @@
|
||||
import { BackgroundLevel, FontLevel, Theme } from "@Component/Theme/Theme";
|
||||
import { Icon } from "@fluentui/react";
|
||||
import { Component } from "react";
|
||||
import "./LabelList.scss";
|
||||
|
||||
interface ILabelListCommandProps {}
|
||||
|
||||
class LabelListCommand extends Component<ILabelListCommandProps> {
|
||||
|
||||
public render() {
|
||||
return <Theme
|
||||
className="label-list-command-bar"
|
||||
backgroundLevel={BackgroundLevel.Level4}
|
||||
fontLevel={FontLevel.normal}
|
||||
>
|
||||
<div className="command-item">
|
||||
<Icon iconName="Tag"></Icon>
|
||||
</div>
|
||||
</Theme>
|
||||
}
|
||||
}
|
||||
|
||||
export { LabelListCommand };
|
||||
@@ -1,11 +1,12 @@
|
||||
import { ReactNode, Component, FunctionComponent } from "react";
|
||||
import { Theme } from "@Component/Theme/Theme";
|
||||
import { Localization } from "@Component/Localization/Localization";
|
||||
import { ErrorMessage } from "@Component/ErrorMessage/ErrorMessage";
|
||||
import { RenderView } from "./RenderView/RenderView";
|
||||
import { ObjectList } from "./ObjectList/ObjectList";
|
||||
import { ObjectCommand } from "./ObjectList/ObjectCommand";
|
||||
import { RangeDetails } from "./RangeDetails/RangeDetails";
|
||||
import { LabelList } from "./LabelList/LabelList";
|
||||
import { LabelListCommand } from "./LabelList/LabelListCommand";
|
||||
|
||||
interface IPanelInfo {
|
||||
nameKey: string;
|
||||
@@ -22,6 +23,7 @@ type PanelId = ""
|
||||
| "RenderView" // 主渲染器
|
||||
| "ObjectList" // 对象列表
|
||||
| "RangeDetails" // 范围属性
|
||||
| "LabelList" // 标签列表
|
||||
;
|
||||
|
||||
const PanelInfoMap = new Map<PanelId, IPanelInfo>();
|
||||
@@ -37,6 +39,10 @@ PanelInfoMap.set("RangeDetails", {
|
||||
nameKey: "Panel.Title.Range.Details.View", introKay: "Panel.Info.Range.Details.View",
|
||||
class: RangeDetails
|
||||
})
|
||||
PanelInfoMap.set("LabelList", {
|
||||
nameKey: "Panel.Title.Label.List.View", introKay: "Panel.Info.Label.List.View",
|
||||
class: LabelList, header: LabelListCommand, hidePadding: true
|
||||
})
|
||||
|
||||
function getPanelById(panelId: PanelId): ReactNode {
|
||||
switch (panelId) {
|
||||
|
||||
Reference in New Issue
Block a user