diff --git a/typescript/index.ts b/typescript/index.ts index 54f7106a8..bcb501473 100644 --- a/typescript/index.ts +++ b/typescript/index.ts @@ -180,6 +180,7 @@ import { TdLayout } from './core/wrapper/layout/layout.td'; import { MultiLayerSelectLevelTree } from './widget/multilayerselecttree/multilayerselecttree.leveltree'; import { SelectTreeExpander } from './widget/selecttree/selecttree.expander'; import { DownListGroupItem } from "./widget/downlist/item.downlistgroup"; +import './shims-tsx'; export interface BI extends _func, _i18n, _base, _inject, _var, _web, _utils { diff --git a/typescript/shims-tsx.ts b/typescript/shims-tsx.ts index 9b8abdb03..c30bdee66 100644 --- a/typescript/shims-tsx.ts +++ b/typescript/shims-tsx.ts @@ -63,7 +63,14 @@ interface ElementClassProps extends UIProps { destroyed(): void; } +type Widget = import('./index').Widget; +type Props = Partial & AdditionalProps>; + declare namespace JSX { + interface Element extends Props { + type: string; + } + interface ElementClass extends Widget {} // for undefined interface IntrinsicElements { [elemName: string]: Partial;