From 65626480c87c42538a60e2123fad9a1eeb7ff931 Mon Sep 17 00:00:00 2001 From: "Xavier.Meng" Date: Mon, 21 Nov 2022 14:52:57 +0800 Subject: [PATCH] =?UTF-8?q?=E6=97=A0JIRA=20refactor(TextValueCombo):=20?= =?UTF-8?q?=E8=A1=A5=E5=85=85=20ts=20=E7=B1=BB=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- typescript/case/combo/combo.textvalue.ts | 7 ++++++- typescript/case/combo/popup.textvalue.ts | 13 +++++++++++++ typescript/index.ts | 3 +++ 3 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 typescript/case/combo/popup.textvalue.ts diff --git a/typescript/case/combo/combo.textvalue.ts b/typescript/case/combo/combo.textvalue.ts index 0a50d2342..128ec03b6 100644 --- a/typescript/case/combo/combo.textvalue.ts +++ b/typescript/case/combo/combo.textvalue.ts @@ -5,5 +5,10 @@ export declare class TextValueCombo extends Widget { static EVENT_CHANGE: string; - populate(items: any): void; + clear(): void; + setText(text: string): void; + setValue(value: any): void; + setStatus(status: "success" | "warning" | "error"): void; + getValue(): any[]; + populate(items: any[]): void; } diff --git a/typescript/case/combo/popup.textvalue.ts b/typescript/case/combo/popup.textvalue.ts new file mode 100644 index 000000000..a3fe1b0d1 --- /dev/null +++ b/typescript/case/combo/popup.textvalue.ts @@ -0,0 +1,13 @@ +import { Pane } from "../../base/pane"; + +export declare class TextValueComboPopup extends Pane { + static xtype: string; + + static EVENT_CHANGE: string; + static EVENT_CLEAR: string; + static EVENT_CONFIRM: string; + + populate(items: any[]): void; + getValue(): any; + setValue(value: any): void; +} diff --git a/typescript/index.ts b/typescript/index.ts index a1b9831c9..cf63c604d 100644 --- a/typescript/index.ts +++ b/typescript/index.ts @@ -20,6 +20,7 @@ import { IconChangeButton } from "./case/button/icon/icon.change"; import { MultiSelectItem } from "./case/button/item.multiselect"; import { BubbleCombo } from "./case/combo/bubblecombo/combo.bubble"; import { TextValueCombo } from "./case/combo/combo.textvalue"; +import { TextValueComboPopup } from "./case/combo/popup.textvalue"; import { SmallTextValueCombo } from "./case/combo/combo.textvaluesmall"; import { SearchTextValueCombo } from "./case/combo/searchtextvaluecombo/combo.searchtextvalue"; import { SignEditor } from "./case/editor/editor.sign"; @@ -226,6 +227,7 @@ export interface BI extends _func, _i18n, _base, _inject, _var, _web, _utils { ButtonGroup: typeof ButtonGroup; Combo: typeof Combo; TextValueCombo: typeof TextValueCombo; + TextValueComboPopup: typeof TextValueComboPopup; SmallTextValueCombo: typeof SmallTextValueCombo; BubbleCombo: typeof BubbleCombo; AllValueMultiTextValueCombo: typeof AllValueMultiTextValueCombo; @@ -464,6 +466,7 @@ export { MultiSelectBar, SelectList, TextValueCombo, + TextValueComboPopup, SmallTextValueCombo, Editor, IconLabel,