feat: update IPublicTypeComponentMetadata interface

This commit is contained in:
liujuping 2023-03-24 16:59:27 +08:00 committed by 林熠
parent affdfbbb1c
commit 3fea312906
3 changed files with 23 additions and 2 deletions

View File

@ -63,7 +63,7 @@ export class Material implements IPublicApiMaterial {
* *
* @returns * @returns
*/ */
getAssets() { getAssets(): IPublicTypeAssetsJson | undefined {
return this[editorSymbol].get('assets'); return this[editorSymbol].get('assets');
} }

View File

@ -22,7 +22,7 @@ export interface IPublicApiMaterial {
* get AssetsJson data * get AssetsJson data
* @returns IPublicTypeAssetsJson * @returns IPublicTypeAssetsJson
*/ */
getAssets(): IPublicTypeAssetsJson; getAssets(): IPublicTypeAssetsJson | undefined;
/** /**
* *

View File

@ -5,74 +5,95 @@ import { IPublicTypeIconType, IPublicTypeNpmInfo, IPublicTypeFieldConfig, IPubli
*/ */
export interface IPublicTypeComponentMetadata { export interface IPublicTypeComponentMetadata {
/** 其他扩展协议 */
[key: string]: any;
/** /**
* *
*/ */
componentName: string; componentName: string;
/** /**
* unique id * unique id
*/ */
uri?: string; uri?: string;
/** /**
* title or description * title or description
*/ */
title?: IPublicTypeTitleContent; title?: IPublicTypeTitleContent;
/** /**
* svg icon for component * svg icon for component
*/ */
icon?: IPublicTypeIconType; icon?: IPublicTypeIconType;
/** /**
* *
*/ */
tags?: string[]; tags?: string[];
/** /**
* *
*/ */
description?: string; description?: string;
/** /**
* *
*/ */
docUrl?: string; docUrl?: string;
/** /**
* *
*/ */
screenshot?: string; screenshot?: string;
/** /**
* *
*/ */
devMode?: 'proCode' | 'lowCode'; devMode?: 'proCode' | 'lowCode';
/** /**
* npm * npm
*/ */
npm?: IPublicTypeNpmInfo; npm?: IPublicTypeNpmInfo;
/** /**
* *
*/ */
props?: IPublicTypePropConfig[]; props?: IPublicTypePropConfig[];
/** /**
* *
*/ */
configure?: IPublicTypeFieldConfig[] | IPublicTypeConfigure; configure?: IPublicTypeFieldConfig[] | IPublicTypeConfigure;
/** /**
* @deprecated, use advanced instead * @deprecated, use advanced instead
*/ */
experimental?: IPublicTypeAdvanced; experimental?: IPublicTypeAdvanced;
/** /**
* @todo * @todo
*/ */
schema?: IPublicTypeComponentSchema; schema?: IPublicTypeComponentSchema;
/** /**
* *
*/ */
snippets?: IPublicTypeSnippet[]; snippets?: IPublicTypeSnippet[];
/** /**
* *
*/ */
group?: string | IPublicTypeI18nData; group?: string | IPublicTypeI18nData;
/** /**
* *
*/ */
category?: string | IPublicTypeI18nData; category?: string | IPublicTypeI18nData;
/** /**
* *
*/ */