Skip to content

Commit

Permalink
feat: update ts defined
Browse files Browse the repository at this point in the history
  • Loading branch information
liujuping authored and JackLian committed Feb 1, 2024
1 parent ac1d462 commit 238828c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 16 deletions.
5 changes: 4 additions & 1 deletion packages/types/src/shell/api/workspace.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import { IPublicModelWindow } from '../model';
import { IPublicApiPlugins, IPublicModelResource, IPublicResourceList, IPublicTypeDisposable, IPublicTypeResourceType } from '@alilc/lowcode-types';
import { IPublicApiPlugins, IPublicApiSkeleton, IPublicModelResource, IPublicResourceList, IPublicTypeDisposable, IPublicTypeResourceType } from '@alilc/lowcode-types';

export interface IPublicApiWorkspace<
Plugins = IPublicApiPlugins,
Skeleton = IPublicApiSkeleton,
ModelWindow = IPublicModelWindow,
Resource = IPublicModelResource,
> {
Expand All @@ -15,6 +16,8 @@ export interface IPublicApiWorkspace<

plugins: Plugins;

skeleton: Skeleton;

/** 当前设计器的编辑窗口 */
windows: ModelWindow[];

Expand Down
18 changes: 3 additions & 15 deletions packages/types/src/shell/type/command.ts
Original file line number Diff line number Diff line change
@@ -1,22 +1,10 @@
import { IPublicTypePropType } from './prop-types';

// 定义命令处理函数的参数类型
export interface IPublicTypeCommandHandlerArgs {
[key: string]: any;
}

// 定义复杂参数类型的接口
export interface IPublicTypeCommandPropType {

/**
* 参数基础类型
*/
type: string;

/**
* 参数是否必需(可选)
*/
isRequired?: boolean;
}

// 定义命令参数的接口
export interface IPublicTypeCommandParameter {

Expand All @@ -28,7 +16,7 @@ export interface IPublicTypeCommandParameter {
/**
* 参数类型或详细类型描述
*/
propType: string | IPublicTypeCommandPropType;
propType: string | IPublicTypePropType;

/**
* 参数描述
Expand Down

0 comments on commit 238828c

Please sign in to comment.