mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2026-01-13 01:21:58 +00:00
feat: meta 增加 hideSelectTools
This commit is contained in:
parent
ac051241d2
commit
e7287d47b1
@ -46,6 +46,12 @@ export class BorderSelectingInstance extends Component<{
|
||||
dragging,
|
||||
});
|
||||
|
||||
const hideSelectTools = observed.node.componentMeta.getMetadata().experimental?.hideSelectTools;
|
||||
|
||||
if (hideSelectTools) {
|
||||
return null;
|
||||
}
|
||||
|
||||
return (
|
||||
<div className={className} style={style}>
|
||||
{!dragging && <Toolbar observed={observed} />}
|
||||
|
||||
@ -137,6 +137,7 @@ export interface OldPrototypeConfig {
|
||||
|
||||
isContainer?: boolean; // => configure.component.isContainer
|
||||
isAbsoluteLayoutContainer?: boolean; // => meta.experimental.isAbsoluteLayoutContainer 是否是绝对定位容器
|
||||
hideSelectTools?: boolean; // => meta.experimental.hideSelectTools
|
||||
isModal?: boolean; // => configure.component.isModal
|
||||
isFloating?: boolean; // => configure.component.isFloating
|
||||
descriptor?: string; // => configure.component.descriptor
|
||||
@ -595,6 +596,7 @@ export function upgradeMetadata(oldConfig: OldPrototypeConfig) {
|
||||
transducers,
|
||||
isContainer,
|
||||
isAbsoluteLayoutContainer,
|
||||
hideSelectTools,
|
||||
rectSelector,
|
||||
isModal,
|
||||
isFloating,
|
||||
@ -684,6 +686,7 @@ export function upgradeMetadata(oldConfig: OldPrototypeConfig) {
|
||||
// 未考虑清楚的,放在实验性段落
|
||||
const experimental: any = {
|
||||
isAbsoluteLayoutContainer,
|
||||
hideSelectTools,
|
||||
};
|
||||
if (context) {
|
||||
// for prototype.getContextInfo
|
||||
|
||||
@ -66,6 +66,7 @@ export interface Experimental {
|
||||
callbacks?: Callbacks;
|
||||
initialChildren?: NodeData[] | ((target: SettingTarget) => NodeData[]);
|
||||
isAbsoluteLayoutContainer: boolean;
|
||||
hideSelectTools?: boolean;
|
||||
|
||||
// 样式 及 位置,handle上必须有明确的标识以便事件路由判断,或者主动设置事件独占模式
|
||||
// NWSE 是交给引擎计算放置位置,ReactElement 必须自己控制初始位置
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user