diff --git a/packages/demo/src/center.js b/packages/demo/src/center.js index bb120071b..0f7beadb3 100644 --- a/packages/demo/src/center.js +++ b/packages/demo/src/center.js @@ -1,6 +1,6 @@ -import { shortcut, Widget, RouterView, Router } from '@fui/core'; +import { Decorators , Widget, RouterView, Router } from '@fui/core'; -@shortcut() +@Decorators.shortcut() export class Center extends Widget { static xtype = 'demo.center'; @@ -15,7 +15,7 @@ export class Center extends Widget { } } -@shortcut() +@Decorators.shortcut() export class RouterDemo extends Widget { static xtype = 'demo.router'; diff --git a/packages/demo/src/demo/base/button/demo.button.js b/packages/demo/src/demo/base/button/demo.button.js index 66bd2cff9..5da0253b6 100644 --- a/packages/demo/src/demo/base/button/demo.button.js +++ b/packages/demo/src/demo/base/button/demo.button.js @@ -1,8 +1,8 @@ -import { Button, TextButton, FloatLeftLayout, shortcut, Widget, parseInt, Msg, map } from "@fui/core" +import { Button, TextButton, FloatLeftLayout, Decorators, Widget, parseInt, Msg, map } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class ButtonDemo extends Widget { static xtype = "demo.button"; diff --git a/packages/demo/src/demo/base/button/demo.icon_button.js b/packages/demo/src/demo/base/button/demo.icon_button.js index 4fb252337..9c6aa1efc 100644 --- a/packages/demo/src/demo/base/button/demo.icon_button.js +++ b/packages/demo/src/demo/base/button/demo.icon_button.js @@ -1,8 +1,8 @@ -import { IconButton, FloatLeftLayout, shortcut, Widget } from "@fui/core" +import { IconButton, FloatLeftLayout, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class IconButtonDemo extends Widget { static xtype = "demo.icon_button"; diff --git a/packages/demo/src/demo/base/button/demo.image_button.js b/packages/demo/src/demo/base/button/demo.image_button.js index ba46d0d75..b152b9b84 100644 --- a/packages/demo/src/demo/base/button/demo.image_button.js +++ b/packages/demo/src/demo/base/button/demo.image_button.js @@ -1,8 +1,8 @@ -import { ImageButton, FloatLeftLayout, shortcut, Widget } from "@fui/core" +import { ImageButton, FloatLeftLayout, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class ImageButtonDemo extends Widget { static xtype = "demo.image_button"; @@ -19,7 +19,7 @@ export class ImageButtonDemo extends Widget { }, } ]; - + return { type: FloatLeftLayout.xtype, vgap: 200, diff --git a/packages/demo/src/demo/base/button/demo.text_button.js b/packages/demo/src/demo/base/button/demo.text_button.js index 4f4a2e292..d402480bb 100644 --- a/packages/demo/src/demo/base/button/demo.text_button.js +++ b/packages/demo/src/demo/base/button/demo.text_button.js @@ -1,8 +1,8 @@ -import { TextButton, FloatLeftLayout, shortcut, Widget } from "@fui/core" +import { TextButton, FloatLeftLayout, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class TextButtonDemo extends Widget { static xtype = "demo.text_button"; diff --git a/packages/demo/src/demo/base/demo.html.js b/packages/demo/src/demo/base/demo.html.js index fc612e4ed..ace76ca7a 100644 --- a/packages/demo/src/demo/base/demo.html.js +++ b/packages/demo/src/demo/base/demo.html.js @@ -1,6 +1,6 @@ -import { shortcut, Widget, VerticalLayout, Html } from "@fui/core"; +import { Decorators, Widget, VerticalLayout, Html } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class HtmlDemo extends Widget { static xtype = "demo.html"; diff --git a/packages/demo/src/demo/base/demo.icon_label.js b/packages/demo/src/demo/base/demo.icon_label.js index bbc85fc4d..6393120b5 100644 --- a/packages/demo/src/demo/base/demo.icon_label.js +++ b/packages/demo/src/demo/base/demo.icon_label.js @@ -1,6 +1,6 @@ -import { DefaultLayout, Label, IconLabel, shortcut, Widget } from "@fui/core"; +import { DefaultLayout, Label, IconLabel, Decorators, Widget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class IconLabelDemo extends Widget { static xtype = "demo.icon_label"; diff --git a/packages/demo/src/demo/base/demo.label.js b/packages/demo/src/demo/base/demo.label.js index b396f57d3..7a2acd4a2 100644 --- a/packages/demo/src/demo/base/demo.label.js +++ b/packages/demo/src/demo/base/demo.label.js @@ -1,12 +1,12 @@ import { VerticalLayout, FloatLeftLayout, - shortcut, + Decorators, Widget, Label } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class LabelDemo extends Widget { static xtype = "demo.label"; diff --git a/packages/demo/src/demo/base/demo.label.scene.js b/packages/demo/src/demo/base/demo.label.scene.js index b797ca169..fe4e8dc9e 100644 --- a/packages/demo/src/demo/base/demo.label.scene.js +++ b/packages/demo/src/demo/base/demo.label.scene.js @@ -1,12 +1,12 @@ import { Label, AbsoluteLayout, - shortcut, + Decorators, Widget, VerticalLayout } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class LabelSceneDemo extends Widget { static xtype = "demo.label_scene"; diff --git a/packages/demo/src/demo/base/demo.message.js b/packages/demo/src/demo/base/demo.message.js index b9db94862..8249d1c9f 100644 --- a/packages/demo/src/demo/base/demo.message.js +++ b/packages/demo/src/demo/base/demo.message.js @@ -1,6 +1,6 @@ -import { shortcut, Widget, Msg, CenterAdaptLayout, Button } from "@fui/core"; +import { Decorators, Widget, Msg, CenterAdaptLayout, Button } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class MessageDemo extends Widget { static xtype = "demo.message"; diff --git a/packages/demo/src/demo/base/demo.pager.js b/packages/demo/src/demo/base/demo.pager.js index cf1cf55df..3421e45cf 100644 --- a/packages/demo/src/demo/base/demo.pager.js +++ b/packages/demo/src/demo/base/demo.pager.js @@ -1,6 +1,6 @@ -import { VerticalLayout, Label, shortcut, Widget, Pager } from "@fui/core"; +import { VerticalLayout, Label, Decorators, Widget, Pager } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class FuncDemo extends Widget { static xtype = "demo.pager"; diff --git a/packages/demo/src/demo/base/editor/demo.editor.js b/packages/demo/src/demo/base/editor/demo.editor.js index 1fa233ad3..e855d5336 100644 --- a/packages/demo/src/demo/base/editor/demo.editor.js +++ b/packages/demo/src/demo/base/editor/demo.editor.js @@ -1,9 +1,9 @@ -import { Editor, AbsoluteLayout, Button, shortcut, Widget, createWidget, Editor as BIEditor } from "@fui/core" +import { Editor, AbsoluteLayout, Button, Decorators, Widget, createWidget, Editor as BIEditor } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class EditorDemo extends Widget { static xtype = "demo.editor"; diff --git a/packages/demo/src/demo/base/editor/demo.multifile_editor.js b/packages/demo/src/demo/base/editor/demo.multifile_editor.js index 9bbcdfd39..ec5ae4942 100644 --- a/packages/demo/src/demo/base/editor/demo.multifile_editor.js +++ b/packages/demo/src/demo/base/editor/demo.multifile_editor.js @@ -1,8 +1,8 @@ -import { AbsoluteLayout, AdaptiveLayout, MultifileEditor, shortcut, Widget } from "@fui/core" +import { AbsoluteLayout, AdaptiveLayout, MultifileEditor, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class CodeEditorDemo extends Widget { static xtype = "demo.multifile_editor"; diff --git a/packages/demo/src/demo/base/editor/demo.textarea_editor.js b/packages/demo/src/demo/base/editor/demo.textarea_editor.js index 6a62b6f8e..41ad85840 100644 --- a/packages/demo/src/demo/base/editor/demo.textarea_editor.js +++ b/packages/demo/src/demo/base/editor/demo.textarea_editor.js @@ -1,9 +1,9 @@ -import { TextAreaEditor, VerticalLayout, Button, shortcut, Widget, createWidget, isNotEmptyString, Msg } from "@fui/core" +import { TextAreaEditor, VerticalLayout, Button, Decorators, Widget, createWidget, isNotEmptyString, Msg } from "@fui/core" - -@shortcut() + +@Decorators.shortcut() export class TextareaEditorDemo extends Widget { static xtype = "demo.textarea_editor"; diff --git a/packages/demo/src/demo/base/tip/demo.bubble.js b/packages/demo/src/demo/base/tip/demo.bubble.js index e59b83f3a..0c7df5539 100644 --- a/packages/demo/src/demo/base/tip/demo.bubble.js +++ b/packages/demo/src/demo/base/tip/demo.bubble.js @@ -1,8 +1,8 @@ -import { Button, FloatLeftLayout, shortcut, Widget, Bubbles } from "@fui/core" +import { Button, FloatLeftLayout, Decorators, Widget, Bubbles } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class BubbleDemo extends Widget { static xtype = "demo.bubble"; diff --git a/packages/demo/src/demo/base/tip/demo.title.js b/packages/demo/src/demo/base/tip/demo.title.js index e3c86b260..ef429812e 100644 --- a/packages/demo/src/demo/base/tip/demo.title.js +++ b/packages/demo/src/demo/base/tip/demo.title.js @@ -1,8 +1,8 @@ -import { VerticalLayout, Label, shortcut, Widget } from "@fui/core" +import { VerticalLayout, Label, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class TitleDemo extends Widget { static xtype = "demo.title"; diff --git a/packages/demo/src/demo/base/tip/demo.toast.js b/packages/demo/src/demo/base/tip/demo.toast.js index 0866a7708..06b44d20e 100644 --- a/packages/demo/src/demo/base/tip/demo.toast.js +++ b/packages/demo/src/demo/base/tip/demo.toast.js @@ -1,9 +1,9 @@ -import { Button, FloatLeftLayout, shortcut, Widget, createWidget, Msg } from "@fui/core" +import { Button, FloatLeftLayout, Decorators, Widget, createWidget, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class ToastDemo extends Widget { static xtype = "demo.toast"; diff --git a/packages/demo/src/demo/base/tree/demo.part_tree.js b/packages/demo/src/demo/base/tree/demo.part_tree.js index deaffcb03..7fcfb86c6 100644 --- a/packages/demo/src/demo/base/tree/demo.part_tree.js +++ b/packages/demo/src/demo/base/tree/demo.part_tree.js @@ -1,9 +1,9 @@ -import { VTapeLayout, Label, PartTree, shortcut, Widget, isNull, TreeView } from "@fui/core" +import { VTapeLayout, Label, PartTree, Decorators, Widget, isNull, TreeView } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class PartTreeDemo extends Widget { static xtype = "demo.part_tree"; diff --git a/packages/demo/src/demo/base/tree/demo.sync_tree.js b/packages/demo/src/demo/base/tree/demo.sync_tree.js index 7fb153bb3..18f406e75 100644 --- a/packages/demo/src/demo/base/tree/demo.sync_tree.js +++ b/packages/demo/src/demo/base/tree/demo.sync_tree.js @@ -1,8 +1,8 @@ -import { VTapeLayout, Label, AsyncTree, shortcut, Widget, isNull } from "@fui/core" +import { VTapeLayout, Label, AsyncTree, Decorators, Widget, isNull } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class SyncTreeDemo extends Widget { static xtype = "demo.sync_tree"; diff --git a/packages/demo/src/demo/base/tree/demo.tree_view.js b/packages/demo/src/demo/base/tree/demo.tree_view.js index 01f87667e..2b77abdbb 100644 --- a/packages/demo/src/demo/base/tree/demo.tree_view.js +++ b/packages/demo/src/demo/base/tree/demo.tree_view.js @@ -1,8 +1,8 @@ -import { TreeView, GridLayout, VTapeLayout, Label, shortcut, Widget, createWidget } from "@fui/core" +import { TreeView, GridLayout, VTapeLayout, Label, Decorators, Widget, createWidget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class FuncDemo extends Widget { static xtype = "demo.tree_view"; diff --git a/packages/demo/src/demo/case/combo/demo.bubble_combo.js b/packages/demo/src/demo/case/combo/demo.bubble_combo.js index b882ed4e8..ab5b8482e 100644 --- a/packages/demo/src/demo/case/combo/demo.bubble_combo.js +++ b/packages/demo/src/demo/case/combo/demo.bubble_combo.js @@ -6,13 +6,13 @@ import { VerticalLayout, TextBubblePopupBarView, AbsoluteLayout, - shortcut, + Decorators, Widget, createWidget, makeArray } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class BubbleComboDemo extends Widget { static xtype = "demo.bubble_combo"; diff --git a/packages/demo/src/demo/case/combo/demo.editor_icon_check_combo.js b/packages/demo/src/demo/case/combo/demo.editor_icon_check_combo.js index 6faaa49c7..9730e6c69 100644 --- a/packages/demo/src/demo/case/combo/demo.editor_icon_check_combo.js +++ b/packages/demo/src/demo/case/combo/demo.editor_icon_check_combo.js @@ -1,8 +1,8 @@ -import { HorizontalAutoLayout, EditorIconCheckCombo, Button, shortcut, Widget } from "@fui/core" +import { HorizontalAutoLayout, EditorIconCheckCombo, Button, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class EditorIconCheckComboDemo extends Widget { static xtype = "demo.editor_icon_check_combo"; diff --git a/packages/demo/src/demo/case/combo/demo.icon_combo.js b/packages/demo/src/demo/case/combo/demo.icon_combo.js index 271f7f326..652b8993f 100644 --- a/packages/demo/src/demo/case/combo/demo.icon_combo.js +++ b/packages/demo/src/demo/case/combo/demo.icon_combo.js @@ -1,8 +1,8 @@ -import { HorizontalAutoLayout, IconCombo, shortcut, Widget } from "@fui/core" +import { HorizontalAutoLayout, IconCombo, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class IconComboDemo extends Widget { static xtype = "demo.icon_combo"; diff --git a/packages/demo/src/demo/case/combo/demo.icon_text_value_combo.js b/packages/demo/src/demo/case/combo/demo.icon_text_value_combo.js index b631b7548..09ccb6c21 100644 --- a/packages/demo/src/demo/case/combo/demo.icon_text_value_combo.js +++ b/packages/demo/src/demo/case/combo/demo.icon_text_value_combo.js @@ -1,8 +1,8 @@ -import { HorizontalAutoLayout, IconTextValueCombo, shortcut, Widget } from "@fui/core" +import { HorizontalAutoLayout, IconTextValueCombo, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class IconTextValueComboDemo extends Widget { static xtype = "demo.icon_text_value_combo"; diff --git a/packages/demo/src/demo/case/combo/demo.search_text_value_combo.js b/packages/demo/src/demo/case/combo/demo.search_text_value_combo.js index a4558e64f..4a9dfcf70 100644 --- a/packages/demo/src/demo/case/combo/demo.search_text_value_combo.js +++ b/packages/demo/src/demo/case/combo/demo.search_text_value_combo.js @@ -4,12 +4,12 @@ import { SearchTextValueCombo, AllValueMultiTextValueCombo, Button, - shortcut, + Decorators, Widget, Msg } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SearchTextValueComboDemo extends Widget { static xtype = "demo.search_text_value_combo"; diff --git a/packages/demo/src/demo/case/combo/demo.text_value_combo.js b/packages/demo/src/demo/case/combo/demo.text_value_combo.js index 6c16c4d03..aa2d8c912 100644 --- a/packages/demo/src/demo/case/combo/demo.text_value_combo.js +++ b/packages/demo/src/demo/case/combo/demo.text_value_combo.js @@ -3,14 +3,14 @@ import { TextValueCombo, Button, Label, - shortcut, + Decorators, Selection, Widget } from "@fui/core"; /** * Created by Dailer on 2017/7/11. */ -@shortcut() +@Decorators.shortcut() export class TextValueComboDemo extends Widget { static xtype = "demo.text_value_combo"; diff --git a/packages/demo/src/demo/case/combo/demo.text_value_down_list_combo.js b/packages/demo/src/demo/case/combo/demo.text_value_down_list_combo.js index 0cac0148e..b054db1de 100644 --- a/packages/demo/src/demo/case/combo/demo.text_value_down_list_combo.js +++ b/packages/demo/src/demo/case/combo/demo.text_value_down_list_combo.js @@ -1,9 +1,9 @@ -import { HorizontalAutoLayout, TextValueDownListCombo, Button, shortcut, Widget, Msg } from "@fui/core" +import { HorizontalAutoLayout, TextValueDownListCombo, Button, Decorators, Widget, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class TextValueDownListComboDemo extends Widget { static xtype = "demo.text_value_down_list_combo"; diff --git a/packages/demo/src/demo/case/combo/demo.text_vlaue_check_combo.js b/packages/demo/src/demo/case/combo/demo.text_vlaue_check_combo.js index 92d340976..59b0e8792 100644 --- a/packages/demo/src/demo/case/combo/demo.text_vlaue_check_combo.js +++ b/packages/demo/src/demo/case/combo/demo.text_vlaue_check_combo.js @@ -1,9 +1,9 @@ -import { Msg, HorizontalAutoLayout, TextValueCheckCombo, Button, shortcut, Widget } from "@fui/core" +import { Msg, HorizontalAutoLayout, TextValueCheckCombo, Button, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class TextValueCheckComboDemo extends Widget { static xtype = "demo.text_value_check_combo"; @@ -11,7 +11,7 @@ export class TextValueCheckComboDemo extends Widget { render() { const self = this; - + return { type: HorizontalAutoLayout.xtype, items: [ diff --git a/packages/demo/src/demo/case/demo.calendar.js b/packages/demo/src/demo/case/demo.calendar.js index 402aeee9a..ee066762a 100644 --- a/packages/demo/src/demo/case/demo.calendar.js +++ b/packages/demo/src/demo/case/demo.calendar.js @@ -1,8 +1,8 @@ -import { Calendar, shortcut, Widget } from "@fui/core" +import { Calendar, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class CalendarDemo extends Widget { static xtype = "demo.calendar"; diff --git a/packages/demo/src/demo/case/demo.click.effect.js b/packages/demo/src/demo/case/demo.click.effect.js index a475f3829..f870f833c 100644 --- a/packages/demo/src/demo/case/demo.click.effect.js +++ b/packages/demo/src/demo/case/demo.click.effect.js @@ -1,8 +1,8 @@ -import { VerticalLayout, IconTextItem, shortcut, Widget, createItems } from "@fui/core" +import { VerticalLayout, IconTextItem, Decorators, Widget, createItems } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class ClickItemEffectDemo extends Widget { static xtype = "demo.click_item_effect"; diff --git a/packages/demo/src/demo/case/demo.color_chooser.js b/packages/demo/src/demo/case/demo.color_chooser.js index 5489839a0..dcecbf2cb 100644 --- a/packages/demo/src/demo/case/demo.color_chooser.js +++ b/packages/demo/src/demo/case/demo.color_chooser.js @@ -1,8 +1,8 @@ -import { AbsoluteLayout, ColorChooser, SimpleColorChooser, shortcut, Widget } from "@fui/core" +import { AbsoluteLayout, ColorChooser, SimpleColorChooser, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class ColorChooserDemo extends Widget { static xtype = "demo.color_chooser"; diff --git a/packages/demo/src/demo/case/demo.color_chooser_popup.js b/packages/demo/src/demo/case/demo.color_chooser_popup.js index 1c641a97d..260fe26e3 100644 --- a/packages/demo/src/demo/case/demo.color_chooser_popup.js +++ b/packages/demo/src/demo/case/demo.color_chooser_popup.js @@ -1,8 +1,8 @@ -import { AbsoluteLayout, ColorChooserPopup, SimpleColorChooserPopup, shortcut, Widget } from "@fui/core" +import { AbsoluteLayout, ColorChooserPopup, SimpleColorChooserPopup, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class ColorChooserPopupDemo extends Widget { static xtype = "demo.color_chooser_popup"; diff --git a/packages/demo/src/demo/case/demo.segment.js b/packages/demo/src/demo/case/demo.segment.js index a8e09e948..6d82ce6c8 100644 --- a/packages/demo/src/demo/case/demo.segment.js +++ b/packages/demo/src/demo/case/demo.segment.js @@ -1,8 +1,8 @@ -import { HorizontalLayout, Segment, shortcut, Widget, createWidget } from "@fui/core" +import { HorizontalLayout, Segment, Decorators, Widget, createWidget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class SegmentDemo extends Widget { static xtype = "demo.segment"; diff --git a/packages/demo/src/demo/case/editor/demo.clear_editor.js b/packages/demo/src/demo/case/editor/demo.clear_editor.js index 7c78a0ffa..5a11a19c2 100644 --- a/packages/demo/src/demo/case/editor/demo.clear_editor.js +++ b/packages/demo/src/demo/case/editor/demo.clear_editor.js @@ -1,8 +1,8 @@ -import { HorizontalAutoLayout, ClearEditor, shortcut, Widget } from "@fui/core" +import { HorizontalAutoLayout, ClearEditor, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class ClearEditorDemo extends Widget { static xtype = "demo.clear_editor"; diff --git a/packages/demo/src/demo/case/editor/demo.shelter_editor.js b/packages/demo/src/demo/case/editor/demo.shelter_editor.js index 6c0cc3802..cb057c682 100644 --- a/packages/demo/src/demo/case/editor/demo.shelter_editor.js +++ b/packages/demo/src/demo/case/editor/demo.shelter_editor.js @@ -1,8 +1,8 @@ -import { ShelterEditor, VerticalLayout, AbsoluteLayout, Button, shortcut, Widget, createWidget } from "@fui/core" +import { ShelterEditor, VerticalLayout, AbsoluteLayout, Button, Decorators, Widget, createWidget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class ShelterEditorDemo extends Widget { static xtype = "demo.shelter_editor"; diff --git a/packages/demo/src/demo/case/editor/demo.sign_editor.js b/packages/demo/src/demo/case/editor/demo.sign_editor.js index 8a7ffb7cf..a46085f43 100644 --- a/packages/demo/src/demo/case/editor/demo.sign_editor.js +++ b/packages/demo/src/demo/case/editor/demo.sign_editor.js @@ -1,8 +1,8 @@ -import { SignEditor, VerticalLayout, shortcut, Widget, createWidget } from "@fui/core" +import { SignEditor, VerticalLayout, Decorators, Widget, createWidget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class SignEditorDemo extends Widget { static xtype = "demo.sign_editor"; diff --git a/packages/demo/src/demo/case/editor/demo.simple_state_editor.js b/packages/demo/src/demo/case/editor/demo.simple_state_editor.js index 9ddface18..ca521209c 100644 --- a/packages/demo/src/demo/case/editor/demo.simple_state_editor.js +++ b/packages/demo/src/demo/case/editor/demo.simple_state_editor.js @@ -1,8 +1,8 @@ -import { HorizontalAdaptLayout, SimpleStateEditor, shortcut, Widget } from "@fui/core" +import { HorizontalAdaptLayout, SimpleStateEditor, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class SimpleStateEditorDemo extends Widget { static xtype = "demo.simple_state_editor"; diff --git a/packages/demo/src/demo/case/editor/demo.state_editor.js b/packages/demo/src/demo/case/editor/demo.state_editor.js index 98da9f000..a96f81934 100644 --- a/packages/demo/src/demo/case/editor/demo.state_editor.js +++ b/packages/demo/src/demo/case/editor/demo.state_editor.js @@ -1,8 +1,8 @@ -import { HorizontalAdaptLayout, StateEditor, shortcut, Widget } from "@fui/core" +import { HorizontalAdaptLayout, StateEditor, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class StateEditorDemo extends Widget { static xtype = "demo.state_editor"; diff --git a/packages/demo/src/demo/case/item/demo.multi_select_item.js b/packages/demo/src/demo/case/item/demo.multi_select_item.js index 575bcd55b..03a1ad362 100644 --- a/packages/demo/src/demo/case/item/demo.multi_select_item.js +++ b/packages/demo/src/demo/case/item/demo.multi_select_item.js @@ -1,8 +1,8 @@ -import { VerticalLayout, Label, MultiSelectItem, shortcut, Widget } from "@fui/core" +import { VerticalLayout, Label, MultiSelectItem, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class MultiSelectItemDemo extends Widget { static xtype = "demo.multi_select_item"; diff --git a/packages/demo/src/demo/case/item/demo.single_select_item.js b/packages/demo/src/demo/case/item/demo.single_select_item.js index 1c9e51748..eacea0001 100644 --- a/packages/demo/src/demo/case/item/demo.single_select_item.js +++ b/packages/demo/src/demo/case/item/demo.single_select_item.js @@ -1,8 +1,8 @@ -import { VerticalLayout, Label, SingleSelectItem, shortcut, Widget } from "@fui/core" +import { VerticalLayout, Label, SingleSelectItem, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class SingleSelectItemDemo extends Widget { static xtype = "demo.single_select_item"; diff --git a/packages/demo/src/demo/case/item/demo.single_select_radio_item.js b/packages/demo/src/demo/case/item/demo.single_select_radio_item.js index 22f3ce14e..a36de29ce 100644 --- a/packages/demo/src/demo/case/item/demo.single_select_radio_item.js +++ b/packages/demo/src/demo/case/item/demo.single_select_radio_item.js @@ -2,11 +2,11 @@ import { VerticalLayout, Label, SingleSelectRadioItem, - shortcut, + Decorators, Widget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SingleSelectRadioItemDemo extends Widget { static xtype = "demo.single_select_radio_item"; diff --git a/packages/demo/src/demo/case/list/demo.lazy_loader.js b/packages/demo/src/demo/case/list/demo.lazy_loader.js index b99ee13ac..e6914637e 100644 --- a/packages/demo/src/demo/case/list/demo.lazy_loader.js +++ b/packages/demo/src/demo/case/list/demo.lazy_loader.js @@ -3,14 +3,14 @@ import { LazyLoader, FloatLeftLayout, Button, - shortcut, + Decorators, Widget, createWidget, createItems, deepClone } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class LazyLoaderDemo extends Widget { static xtype = "demo.lazy_loader"; diff --git a/packages/demo/src/demo/case/list/demo.select_list.js b/packages/demo/src/demo/case/list/demo.select_list.js index 5e115d0c9..9dde9066d 100644 --- a/packages/demo/src/demo/case/list/demo.select_list.js +++ b/packages/demo/src/demo/case/list/demo.select_list.js @@ -3,7 +3,7 @@ import { SelectList, MultiSelectBar, MultiSelectItem, - shortcut, + Decorators, Widget, createWidget, createItems, @@ -11,7 +11,7 @@ import { Selection } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SelectListDemo extends Widget { static xtype = "demo.select_list"; diff --git a/packages/demo/src/demo/case/pager/demo.all_count_pager.js b/packages/demo/src/demo/case/pager/demo.all_count_pager.js index 25b8babc3..fb159af62 100644 --- a/packages/demo/src/demo/case/pager/demo.all_count_pager.js +++ b/packages/demo/src/demo/case/pager/demo.all_count_pager.js @@ -2,12 +2,12 @@ import { VerticalLayout, Label, AllCountPager, - shortcut, + Decorators, Widget, createWidget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class AllCountPagerDemo extends Widget { static xtype = "demo.all_count_pager"; diff --git a/packages/demo/src/demo/case/pager/demo.direction_pager.js b/packages/demo/src/demo/case/pager/demo.direction_pager.js index dca9914bf..e83f76685 100644 --- a/packages/demo/src/demo/case/pager/demo.direction_pager.js +++ b/packages/demo/src/demo/case/pager/demo.direction_pager.js @@ -1,8 +1,8 @@ -import { VerticalLayout, DirectionPager, shortcut, Widget, createWidget } from "@fui/core" +import { VerticalLayout, DirectionPager, Decorators, Widget, createWidget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class DirectionPagerDemo extends Widget { static xtype = "demo.direction_pager"; diff --git a/packages/demo/src/demo/case/pane/demo.list_pane.js b/packages/demo/src/demo/case/pane/demo.list_pane.js index b68799cde..649ed4498 100644 --- a/packages/demo/src/demo/case/pane/demo.list_pane.js +++ b/packages/demo/src/demo/case/pane/demo.list_pane.js @@ -4,13 +4,13 @@ import { MultiSelectItem, ButtonGroup, VerticalLayout, - shortcut, + Decorators, Widget, createItems, deepClone } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class ListPaneDemo extends Widget { static xtype = "demo.list_pane"; diff --git a/packages/demo/src/demo/case/pane/demo.multi_popup_view.js b/packages/demo/src/demo/case/pane/demo.multi_popup_view.js index 8a4263d67..a5cc7d231 100644 --- a/packages/demo/src/demo/case/pane/demo.multi_popup_view.js +++ b/packages/demo/src/demo/case/pane/demo.multi_popup_view.js @@ -7,13 +7,13 @@ import { ButtonGroup, VerticalLayout, MultiSelectItem, - shortcut, + Decorators, Widget, createItems, deepClone } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class MultiPopupViewDemo extends Widget { static xtype = "demo.multi_popup_view"; diff --git a/packages/demo/src/demo/case/pane/demo.panel.js b/packages/demo/src/demo/case/pane/demo.panel.js index fc3ead71c..64f1f5d63 100644 --- a/packages/demo/src/demo/case/pane/demo.panel.js +++ b/packages/demo/src/demo/case/pane/demo.panel.js @@ -5,13 +5,13 @@ import { ButtonGroup, VerticalLayout, MultiSelectItem, - shortcut, + Decorators, Widget, createItems, deepClone } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class PanelDemo extends Widget { static xtype = "demo.panel"; diff --git a/packages/demo/src/demo/case/pane/demo.popup_panel.js b/packages/demo/src/demo/case/pane/demo.popup_panel.js index b4a437a35..672e5cfe2 100644 --- a/packages/demo/src/demo/case/pane/demo.popup_panel.js +++ b/packages/demo/src/demo/case/pane/demo.popup_panel.js @@ -7,13 +7,13 @@ import { ButtonGroup, VerticalLayout, MultiSelectItem, - shortcut, + Decorators, Widget, createItems, deepClone } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class PopupPanelDemo extends Widget { static xtype = "demo.popup_panel"; diff --git a/packages/demo/src/demo/case/tree/demo.display_tree.js b/packages/demo/src/demo/case/tree/demo.display_tree.js index 35584c4de..a7122a533 100644 --- a/packages/demo/src/demo/case/tree/demo.display_tree.js +++ b/packages/demo/src/demo/case/tree/demo.display_tree.js @@ -1,8 +1,8 @@ -import { DisplayTree, shortcut, Widget, createWidget } from "@fui/core" +import { DisplayTree, Decorators, Widget, createWidget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class DisplayTreeDemo extends Widget { static xtype = "demo.display_tree"; diff --git a/packages/demo/src/demo/case/tree/demo.level_tree.js b/packages/demo/src/demo/case/tree/demo.level_tree.js index 6a432c673..564ff16ca 100644 --- a/packages/demo/src/demo/case/tree/demo.level_tree.js +++ b/packages/demo/src/demo/case/tree/demo.level_tree.js @@ -1,9 +1,9 @@ -import { createWidget, Msg, LevelTree, VTapeLayout, Button, shortcut, Widget } from "@fui/core" +import { createWidget, Msg, LevelTree, VTapeLayout, Button, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class LevelTreeDemo extends Widget { static xtype = "demo.level_tree"; diff --git a/packages/demo/src/demo/case/tree/demo.simple_tree.js b/packages/demo/src/demo/case/tree/demo.simple_tree.js index dce211fd4..67ced9ce9 100644 --- a/packages/demo/src/demo/case/tree/demo.simple_tree.js +++ b/packages/demo/src/demo/case/tree/demo.simple_tree.js @@ -2,13 +2,13 @@ import { SimpleTreeView, VTapeLayout, Button, - shortcut, + Decorators, Widget, createWidget, Msg } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SimpleTreeDemo extends Widget { static xtype = "demo.simple_tree"; diff --git a/packages/demo/src/demo/case/triggers/demo.editor_trigger.js b/packages/demo/src/demo/case/triggers/demo.editor_trigger.js index f492e7dc6..07a869ade 100644 --- a/packages/demo/src/demo/case/triggers/demo.editor_trigger.js +++ b/packages/demo/src/demo/case/triggers/demo.editor_trigger.js @@ -2,12 +2,12 @@ import { VerticalLayout, Label, EditorTrigger, - shortcut, + Decorators, Widget, createWidget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class EditorTriggerDemo extends Widget { static xtype = "demo.editor_trigger"; diff --git a/packages/demo/src/demo/case/triggers/demo.icon_trigger.js b/packages/demo/src/demo/case/triggers/demo.icon_trigger.js index 867820dee..fc53a5b1c 100644 --- a/packages/demo/src/demo/case/triggers/demo.icon_trigger.js +++ b/packages/demo/src/demo/case/triggers/demo.icon_trigger.js @@ -2,12 +2,12 @@ import { VerticalLayout, Label, IconTrigger, - shortcut, + Decorators, Widget, createWidget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class IconTriggerDemo extends Widget { static xtype = "demo.icon_trigger"; diff --git a/packages/demo/src/demo/case/triggers/demo.select_text_trigger.js b/packages/demo/src/demo/case/triggers/demo.select_text_trigger.js index dc7fd502b..a34b2c0c2 100644 --- a/packages/demo/src/demo/case/triggers/demo.select_text_trigger.js +++ b/packages/demo/src/demo/case/triggers/demo.select_text_trigger.js @@ -2,12 +2,12 @@ import { VerticalLayout, Label, SelectTextTrigger, - shortcut, + Decorators, Widget, createWidget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SelectTextTriggerDemo extends Widget { static xtype = "demo.select_text_trigger"; diff --git a/packages/demo/src/demo/case/triggers/demo.text_trigger.js b/packages/demo/src/demo/case/triggers/demo.text_trigger.js index c9ec4447d..f7a3a2317 100644 --- a/packages/demo/src/demo/case/triggers/demo.text_trigger.js +++ b/packages/demo/src/demo/case/triggers/demo.text_trigger.js @@ -2,12 +2,12 @@ import { VerticalLayout, Label, TextTrigger, - shortcut, + Decorators, Widget, createWidget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class TextTriggerDemo extends Widget { static xtype = "demo.text_trigger"; diff --git a/packages/demo/src/demo/component/demo.form.js b/packages/demo/src/demo/component/demo.form.js index bd26bcc4b..b1172775f 100644 --- a/packages/demo/src/demo/component/demo.form.js +++ b/packages/demo/src/demo/component/demo.form.js @@ -1,8 +1,8 @@ -import { createWidget, isEmpty, isNotEmptyArray, Form, TextEditor, TextValueCombo, TextAreaEditor, VerticalLayout, Button, shortcut, Widget } from "@fui/core" +import { createWidget, isEmpty, isNotEmptyArray, Form, TextEditor, TextValueCombo, TextAreaEditor, VerticalLayout, Button, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class FormDemo extends Widget { static xtype = "demo.form"; diff --git a/packages/demo/src/demo/component/demo.treevaluechoosercombo.js b/packages/demo/src/demo/component/demo.treevaluechoosercombo.js index 09e846dfb..92ee248ef 100644 --- a/packages/demo/src/demo/component/demo.treevaluechoosercombo.js +++ b/packages/demo/src/demo/component/demo.treevaluechoosercombo.js @@ -1,9 +1,9 @@ import { CONSTANTS } from "@/config/constant"; -import { TreeValueChooserCombo, VerticalLayout, shortcut, Widget, createWidget, deepClone } from "@fui/core" +import { TreeValueChooserCombo, VerticalLayout, Decorators, Widget, createWidget, deepClone } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class TreeValueChooserDemo extends Widget { static xtype = "demo.tree_value_chooser_combo"; diff --git a/packages/demo/src/demo/component/demo.treevaluechooserpane.js b/packages/demo/src/demo/component/demo.treevaluechooserpane.js index 74d105be7..f2a5a4809 100644 --- a/packages/demo/src/demo/component/demo.treevaluechooserpane.js +++ b/packages/demo/src/demo/component/demo.treevaluechooserpane.js @@ -1,7 +1,7 @@ import { CONSTANTS } from "@/config/constant"; -import { TreeValueChooserPane, shortcut, Widget, deepClone } from "@fui/core"; +import { TreeValueChooserPane, Decorators, Widget, deepClone } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class TreeValueChooserPaneDemo extends Widget { static xtype = "demo.tree_value_chooser_pane"; diff --git a/packages/demo/src/demo/component/demo.valuechoosercombo.js b/packages/demo/src/demo/component/demo.valuechoosercombo.js index 419005a4f..c14cd4462 100644 --- a/packages/demo/src/demo/component/demo.valuechoosercombo.js +++ b/packages/demo/src/demo/component/demo.valuechoosercombo.js @@ -1,9 +1,9 @@ import { CONSTANTS } from "@/config/constant"; -import { ValueChooserCombo, VerticalLayout, shortcut, Widget, createWidget, deepClone } from "@fui/core" +import { ValueChooserCombo, VerticalLayout, Decorators, Widget, createWidget, deepClone } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class ValueChooserComboDemo extends Widget { static xtype = "demo.value_chooser_combo"; @@ -16,7 +16,7 @@ export class ValueChooserComboDemo extends Widget { callback(deepClone(CONSTANTS.ITEMS)); }, }); - + return { type: VerticalLayout.xtype, hgap: 200, diff --git a/packages/demo/src/demo/component/demo.valuechooserpane.js b/packages/demo/src/demo/component/demo.valuechooserpane.js index 94d49f7cf..ce0b2cc24 100644 --- a/packages/demo/src/demo/component/demo.valuechooserpane.js +++ b/packages/demo/src/demo/component/demo.valuechooserpane.js @@ -1,7 +1,7 @@ import { CONSTANTS } from "@/config/constant"; -import { ValueChooserPane, shortcut, Widget, deepClone } from "@fui/core"; +import { ValueChooserPane, Decorators, Widget, deepClone } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class ValueChooserPaneDemo extends Widget { static xtype = "demo.value_chooser_pane"; diff --git a/packages/demo/src/demo/core/abstract/combination/demo.combo.js b/packages/demo/src/demo/core/abstract/combination/demo.combo.js index c56563b77..343865be5 100644 --- a/packages/demo/src/demo/core/abstract/combination/demo.combo.js +++ b/packages/demo/src/demo/core/abstract/combination/demo.combo.js @@ -1,9 +1,38 @@ +import { + ComboGroup, + IconTextIconItem, + SingleSelectItem, + Combo, + Button, + ButtonGroup, + Decorators, + SingleSelectRadioItem, + VerticalLayout, + MultiSelectItem, + Label, + MultiSelectBar, + TextButton, + Loader, + FloatLeftLayout, + ButtonTree, + AdaptiveLayout, + TableLayout, + AbsoluteLayout, + Navigation, + GridLayout, + Widget, + createWidget, + createItems, + deepClone, + map, + delay, + random, + makeArray, + Msg +} from "@fui/core"; -import { ComboGroup, IconTextIconItem, SingleSelectItem, Combo, Button, ButtonGroup, SingleSelectRadioItem, VerticalLayout, MultiSelectItem, Label, MultiSelectBar, TextButton, Loader, FloatLeftLayout, ButtonTree, AdaptiveLayout, TableLayout, AbsoluteLayout, Navigation, GridLayout, shortcut, Widget, createWidget, createItems, deepClone, map, delay, random, makeArray, Msg } from "@fui/core" - - -@shortcut() +@Decorators.shortcut() export class ComboDemo extends Widget { static xtype = "demo.combo"; @@ -92,7 +121,8 @@ export class ComboDemo extends Widget { items: createItems(deepClone(this.years), { type: SingleSelectRadioItem.xtype, height: 25, - handler(v) {}, + handler(v) { + }, }), layouts: [ { @@ -116,7 +146,8 @@ export class ComboDemo extends Widget { items: createItems(deepClone(this.years), { type: MultiSelectItem.xtype, height: 25, - handler(v) {}, + handler(v) { + }, }), chooseType: 1, layouts: [ @@ -296,7 +327,8 @@ export class ComboDemo extends Widget { type: SingleSelectItem.xtype, iconWidth: 25, height: 25, - handler(v) {}, + handler(v) { + }, }), chooseType: 1, layouts: [ @@ -323,7 +355,8 @@ export class ComboDemo extends Widget { items: createItems(deepClone(this.child), { type: SingleSelectItem.xtype, height: 25, - handler(v) {}, + handler(v) { + }, }), layouts: [ { @@ -348,7 +381,8 @@ export class ComboDemo extends Widget { items: createItems(deepClone(this.months), { type: SingleSelectItem.xtype, cls: "button-combo", - handler(v) {}, + handler(v) { + }, }), layouts: [ { diff --git a/packages/demo/src/demo/core/abstract/combination/demo.combo2.js b/packages/demo/src/demo/core/abstract/combination/demo.combo2.js index b2fc9eb7e..5acd394d5 100644 --- a/packages/demo/src/demo/core/abstract/combination/demo.combo2.js +++ b/packages/demo/src/demo/core/abstract/combination/demo.combo2.js @@ -3,12 +3,12 @@ import { Combo, Layout, GridLayout, - shortcut, Widget, - createWidget + createWidget, + Decorators } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class Combo2Demo extends Widget { static xtype = "demo.combo2"; diff --git a/packages/demo/src/demo/core/abstract/combination/demo.combo3.js b/packages/demo/src/demo/core/abstract/combination/demo.combo3.js index 6b4e80401..80078e7a8 100644 --- a/packages/demo/src/demo/core/abstract/combination/demo.combo3.js +++ b/packages/demo/src/demo/core/abstract/combination/demo.combo3.js @@ -3,12 +3,12 @@ import { Combo, Layout, GridLayout, - shortcut, Widget, - createWidget + createWidget, + Decorators } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class Combo3Demo extends Widget { static xtype = "demo.combo3"; diff --git a/packages/demo/src/demo/core/abstract/combination/demo.combo_group.js b/packages/demo/src/demo/core/abstract/combination/demo.combo_group.js index 67aadd452..925f36fc7 100644 --- a/packages/demo/src/demo/core/abstract/combination/demo.combo_group.js +++ b/packages/demo/src/demo/core/abstract/combination/demo.combo_group.js @@ -8,14 +8,14 @@ import { VerticalLayout, FloatLeftLayout, GridLayout, - shortcut, Widget, createWidget, createItems, - deepClone + deepClone, + Decorators } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class ComboGroupDemo extends Widget { static xtype = "demo.combo.group"; diff --git a/packages/demo/src/demo/core/abstract/combination/demo.expander.js b/packages/demo/src/demo/core/abstract/combination/demo.expander.js index 49533e4b0..2316adfa5 100644 --- a/packages/demo/src/demo/core/abstract/combination/demo.expander.js +++ b/packages/demo/src/demo/core/abstract/combination/demo.expander.js @@ -3,12 +3,12 @@ import { Expander, IconTextNode, SingleSelectItem, - shortcut, Widget, - createItems + createItems, + Decorators } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class ExpanderDemo extends Widget { static xtype = "demo.expander"; diff --git a/packages/demo/src/demo/core/abstract/combination/demo.loader.js b/packages/demo/src/demo/core/abstract/combination/demo.loader.js index 0cb891c6c..53d9044e6 100644 --- a/packages/demo/src/demo/core/abstract/combination/demo.loader.js +++ b/packages/demo/src/demo/core/abstract/combination/demo.loader.js @@ -1,7 +1,7 @@ -import { Loader, SingleSelectItem, shortcut, Widget, deepClone, map, extend } from '@fui/core'; +import { Loader,Decorators, SingleSelectItem, Widget, deepClone, map, extend } from '@fui/core'; import { CONSTANTS } from '@/config/constant'; -@shortcut() +@Decorators.shortcut() export class LoaderDemo extends Widget { static xtype = 'demo.loader'; diff --git a/packages/demo/src/demo/core/abstract/combination/demo.navigation.js b/packages/demo/src/demo/core/abstract/combination/demo.navigation.js index 43620d356..aa0d398c8 100644 --- a/packages/demo/src/demo/core/abstract/combination/demo.navigation.js +++ b/packages/demo/src/demo/core/abstract/combination/demo.navigation.js @@ -1,14 +1,14 @@ import { Label, Navigation, - shortcut, Widget, createWidget, random, - bind + bind, + Decorators } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class NagvigationDemo extends Widget { static xtype = "demo.navigation"; diff --git a/packages/demo/src/demo/core/abstract/combination/demo.sercher.js b/packages/demo/src/demo/core/abstract/combination/demo.sercher.js index 50487eef5..0c1792d6f 100644 --- a/packages/demo/src/demo/core/abstract/combination/demo.sercher.js +++ b/packages/demo/src/demo/core/abstract/combination/demo.sercher.js @@ -4,13 +4,13 @@ import { VerticalLayout, AbsoluteLayout, Searcher, - shortcut, Widget, createItems, - createWidget + createWidget, + Decorators } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SearcherDemo extends Widget { static xtype = "demo.searcher"; diff --git a/packages/demo/src/demo/core/abstract/combination/demo.switcher.js b/packages/demo/src/demo/core/abstract/combination/demo.switcher.js index d18a7c3f4..af833c03c 100644 --- a/packages/demo/src/demo/core/abstract/combination/demo.switcher.js +++ b/packages/demo/src/demo/core/abstract/combination/demo.switcher.js @@ -5,13 +5,13 @@ import { Switcher, Button, SingleSelectItem, - shortcut, Widget, createWidget, - createItems + createItems, + Decorators } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SwitcherDemo extends Widget { static xtype = "demo.switcher"; diff --git a/packages/demo/src/demo/core/abstract/combination/demo.tab.js b/packages/demo/src/demo/core/abstract/combination/demo.tab.js index a597c331c..5867d8a0b 100644 --- a/packages/demo/src/demo/core/abstract/combination/demo.tab.js +++ b/packages/demo/src/demo/core/abstract/combination/demo.tab.js @@ -5,13 +5,13 @@ import { HorizontalLayout, Tab, AbsoluteLayout, - shortcut, Widget, createWidget, - bind + bind, + Decorators } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class TabDemo extends Widget { static xtype = "demo.tab"; diff --git a/packages/demo/src/demo/core/abstract/demo.button_group.js b/packages/demo/src/demo/core/abstract/demo.button_group.js index ca43fdaa6..1d679c10c 100644 --- a/packages/demo/src/demo/core/abstract/demo.button_group.js +++ b/packages/demo/src/demo/core/abstract/demo.button_group.js @@ -4,11 +4,11 @@ import { VTapeLayout, Label, Button, - shortcut, + Decorators, Widget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class ButtonGroupDemo extends Widget { static xtype = "demo.button_group"; diff --git a/packages/demo/src/demo/core/abstract/demo.button_tree.js b/packages/demo/src/demo/core/abstract/demo.button_tree.js index 5411f68ea..1da884922 100644 --- a/packages/demo/src/demo/core/abstract/demo.button_tree.js +++ b/packages/demo/src/demo/core/abstract/demo.button_tree.js @@ -4,12 +4,12 @@ import { CenterAdaptLayout, Label, Button, - shortcut, + Decorators, Widget, ButtonGroup } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class ButtonTreeDemo extends Widget { static xtype = "demo.button_tree"; diff --git a/packages/demo/src/demo/core/abstract/demo.collection_view.js b/packages/demo/src/demo/core/abstract/demo.collection_view.js index 85d34f0dc..eef001c9a 100644 --- a/packages/demo/src/demo/core/abstract/demo.collection_view.js +++ b/packages/demo/src/demo/core/abstract/demo.collection_view.js @@ -2,12 +2,12 @@ import { Label, CollectionView, AbsoluteLayout, - shortcut, + Decorators, Widget, createWidget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class CollectionViewDemo extends Widget { static xtype = "demo.collection_view"; diff --git a/packages/demo/src/demo/core/abstract/demo.custom_tree.js b/packages/demo/src/demo/core/abstract/demo.custom_tree.js index 6a6c2f244..9e130db06 100644 --- a/packages/demo/src/demo/core/abstract/demo.custom_tree.js +++ b/packages/demo/src/demo/core/abstract/demo.custom_tree.js @@ -10,14 +10,14 @@ import { CenterLayout, TextButton, Label, - shortcut, + Decorators, Widget, createWidget, deepClone, Msg } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class CustomTreeDemo extends Widget { static xtype = "demo.custom_tree"; diff --git a/packages/demo/src/demo/core/abstract/demo.grid_view.js b/packages/demo/src/demo/core/abstract/demo.grid_view.js index 505a23c33..53b28cf80 100644 --- a/packages/demo/src/demo/core/abstract/demo.grid_view.js +++ b/packages/demo/src/demo/core/abstract/demo.grid_view.js @@ -3,12 +3,12 @@ import { GridView, AbsoluteLayout, GridLayout, - shortcut, + Decorators, Widget, createWidget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class GridViewDemo extends Widget { static xtype = "demo.grid_view"; diff --git a/packages/demo/src/demo/core/abstract/demo.list_view.js b/packages/demo/src/demo/core/abstract/demo.list_view.js index 39f5e1c10..4b37a32ff 100644 --- a/packages/demo/src/demo/core/abstract/demo.list_view.js +++ b/packages/demo/src/demo/core/abstract/demo.list_view.js @@ -1,7 +1,7 @@ -import { ListView, FloatLeftLayout, Label, shortcut, Widget, map, extend } from '@fui/core'; +import { ListView, FloatLeftLayout, Label, Decorators, Widget, map, extend } from '@fui/core'; import { CONSTANTS } from '@/config/constant'; -@shortcut() +@Decorators.shortcut() export class ListViewDemo extends Widget { static xtype = 'demo.list_view'; diff --git a/packages/demo/src/demo/core/abstract/demo.virtual_group.js b/packages/demo/src/demo/core/abstract/demo.virtual_group.js index 92131d284..07467ead0 100644 --- a/packages/demo/src/demo/core/abstract/demo.virtual_group.js +++ b/packages/demo/src/demo/core/abstract/demo.virtual_group.js @@ -4,14 +4,14 @@ import { ButtonGroup, Button, VirtualGroup, - shortcut, + Decorators, Widget, map, range, deepClone } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class VirtualGroupDemo extends Widget { static xtype = "demo.virtual_group"; diff --git a/packages/demo/src/demo/core/abstract/demo.virtual_group_item.js b/packages/demo/src/demo/core/abstract/demo.virtual_group_item.js index 4a42f08c6..35a8ef699 100644 --- a/packages/demo/src/demo/core/abstract/demo.virtual_group_item.js +++ b/packages/demo/src/demo/core/abstract/demo.virtual_group_item.js @@ -1,6 +1,6 @@ -import { Label, shortcut, Widget, UUID } from "@fui/core"; +import { Label, Decorators, Widget, UUID } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class VirtualGroupItemDemo extends Widget { static xtype = "demo.virtual_group_item"; diff --git a/packages/demo/src/demo/core/abstract/demo.virtual_list.js b/packages/demo/src/demo/core/abstract/demo.virtual_list.js index b6fa4a624..0545d449d 100644 --- a/packages/demo/src/demo/core/abstract/demo.virtual_list.js +++ b/packages/demo/src/demo/core/abstract/demo.virtual_list.js @@ -1,7 +1,7 @@ -import { VirtualList, Label, shortcut, Widget, map, extend } from '@fui/core'; +import { VirtualList, Label, Decorators, Widget, map, extend } from '@fui/core'; import { CONSTANTS } from '@/config/constant'; -@shortcut() +@Decorators.shortcut() export class VirtualListDemo extends Widget { static xtype = 'demo.virtual_list'; diff --git a/packages/demo/src/demo/core/layout/demo.absolute.js b/packages/demo/src/demo/core/layout/demo.absolute.js index 3df7b8b4c..65d4a4ea6 100644 --- a/packages/demo/src/demo/core/layout/demo.absolute.js +++ b/packages/demo/src/demo/core/layout/demo.absolute.js @@ -1,8 +1,8 @@ -import { AbsoluteLayout, Label, shortcut, Widget } from "@fui/core" +import { AbsoluteLayout, Label, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class AbsoluteLayoutDemo extends Widget { static xtype = "demo.absolute"; diff --git a/packages/demo/src/demo/core/layout/demo.border.js b/packages/demo/src/demo/core/layout/demo.border.js index cff86a08b..f5c58c715 100644 --- a/packages/demo/src/demo/core/layout/demo.border.js +++ b/packages/demo/src/demo/core/layout/demo.border.js @@ -1,8 +1,8 @@ -import { Label, CenterLayout, BorderLayout, shortcut, Widget, createWidget } from "@fui/core" +import { Label, CenterLayout, BorderLayout, Decorators, Widget, createWidget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class BorderLayoutDemo extends Widget { static xtype = "demo.border"; diff --git a/packages/demo/src/demo/core/layout/demo.center_adapt.js b/packages/demo/src/demo/core/layout/demo.center_adapt.js index 5b39be5e3..52ae2d035 100644 --- a/packages/demo/src/demo/core/layout/demo.center_adapt.js +++ b/packages/demo/src/demo/core/layout/demo.center_adapt.js @@ -1,8 +1,8 @@ -import { CenterAdaptLayout, Label, shortcut, Widget } from "@fui/core" +import { CenterAdaptLayout, Label, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class CenterAdaptDemo extends Widget { static xtype = "demo.center_adapt"; diff --git a/packages/demo/src/demo/core/layout/demo.float_center.js b/packages/demo/src/demo/core/layout/demo.float_center.js index dde4c36e4..a4ea3684a 100644 --- a/packages/demo/src/demo/core/layout/demo.float_center.js +++ b/packages/demo/src/demo/core/layout/demo.float_center.js @@ -1,8 +1,8 @@ -import { FloatCenterLayout, Label, shortcut, Widget } from "@fui/core" +import { FloatCenterLayout, Label, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class FloatCenterLayoutDemo extends Widget { static xtype = "demo.float_center"; diff --git a/packages/demo/src/demo/core/layout/demo.flow.js b/packages/demo/src/demo/core/layout/demo.flow.js index 31e897428..3f95628c1 100644 --- a/packages/demo/src/demo/core/layout/demo.flow.js +++ b/packages/demo/src/demo/core/layout/demo.flow.js @@ -1,8 +1,8 @@ -import { CenterAdaptLayout, FloatLeftLayout, Label, FloatRightLayout, shortcut, Widget } from "@fui/core" +import { CenterAdaptLayout, FloatLeftLayout, Label, FloatRightLayout, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class FlowLayoutDemo extends Widget { static xtype = "demo.flow"; diff --git a/packages/demo/src/demo/core/layout/demo.grid.js b/packages/demo/src/demo/core/layout/demo.grid.js index f84f1607f..e22805f04 100644 --- a/packages/demo/src/demo/core/layout/demo.grid.js +++ b/packages/demo/src/demo/core/layout/demo.grid.js @@ -1,8 +1,8 @@ -import { GridLayout, Label, shortcut, Widget } from "@fui/core" +import { GridLayout, Label, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class GridLayoutDemo extends Widget { static xtype = "demo.grid"; diff --git a/packages/demo/src/demo/core/layout/demo.horizontal.js b/packages/demo/src/demo/core/layout/demo.horizontal.js index 8e76a19bc..de2205257 100644 --- a/packages/demo/src/demo/core/layout/demo.horizontal.js +++ b/packages/demo/src/demo/core/layout/demo.horizontal.js @@ -1,9 +1,9 @@ -import { VerticalLayout, HorizontalLayout, Label, Layout, CenterAdaptLayout, shortcut, Widget, VerticalAlign, HorizontalAlign } from "@fui/core" +import { VerticalLayout, HorizontalLayout, Label, Layout, CenterAdaptLayout, Decorators, Widget, VerticalAlign, HorizontalAlign } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class HorizontalDemo extends Widget { static xtype = "demo.horizontal"; diff --git a/packages/demo/src/demo/core/layout/demo.horizontal_adapt.js b/packages/demo/src/demo/core/layout/demo.horizontal_adapt.js index d89efab6c..ed122355e 100644 --- a/packages/demo/src/demo/core/layout/demo.horizontal_adapt.js +++ b/packages/demo/src/demo/core/layout/demo.horizontal_adapt.js @@ -1,8 +1,8 @@ -import { HorizontalAdaptLayout, Label, GridLayout, shortcut, Widget, createWidget } from "@fui/core" +import { HorizontalAdaptLayout, Label, GridLayout, Decorators, Widget, createWidget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class HorizontalAdaptDemo extends Widget { static xtype = "demo.horizontal_adapt"; diff --git a/packages/demo/src/demo/core/layout/demo.horizontal_auto.js b/packages/demo/src/demo/core/layout/demo.horizontal_auto.js index 572b9cf6b..7981937b8 100644 --- a/packages/demo/src/demo/core/layout/demo.horizontal_auto.js +++ b/packages/demo/src/demo/core/layout/demo.horizontal_auto.js @@ -1,8 +1,8 @@ -import { HorizontalAutoLayout, Label, GridLayout, shortcut, Widget, createWidget } from "@fui/core" +import { HorizontalAutoLayout, Label, GridLayout, Decorators, Widget, createWidget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class HorizontalAutoDemo extends Widget { static xtype = "demo.horizontal_auto"; diff --git a/packages/demo/src/demo/core/layout/demo.horizontal_float.js b/packages/demo/src/demo/core/layout/demo.horizontal_float.js index 5cf44e22d..135137825 100644 --- a/packages/demo/src/demo/core/layout/demo.horizontal_float.js +++ b/packages/demo/src/demo/core/layout/demo.horizontal_float.js @@ -1,8 +1,8 @@ -import { FloatHorizontalLayout, Label, shortcut, Widget } from "@fui/core" +import { FloatHorizontalLayout, Label, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class HorizontalFloatDemo extends Widget { static xtype = "demo.horizontal_float"; diff --git a/packages/demo/src/demo/core/layout/demo.htape.js b/packages/demo/src/demo/core/layout/demo.htape.js index 52c1a92d1..7ea214d7a 100644 --- a/packages/demo/src/demo/core/layout/demo.htape.js +++ b/packages/demo/src/demo/core/layout/demo.htape.js @@ -1,8 +1,8 @@ -import { HTapeLayout, Label, shortcut, Widget } from "@fui/core" +import { HTapeLayout, Label, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class HtapeLayoutDemo extends Widget { static xtype = "demo.htape"; diff --git a/packages/demo/src/demo/core/layout/demo.left_right_vertical_adapt.js b/packages/demo/src/demo/core/layout/demo.left_right_vertical_adapt.js index 438236051..522c76757 100644 --- a/packages/demo/src/demo/core/layout/demo.left_right_vertical_adapt.js +++ b/packages/demo/src/demo/core/layout/demo.left_right_vertical_adapt.js @@ -1,8 +1,8 @@ -import { LeftRightVerticalAdaptLayout, Label, shortcut, Widget } from "@fui/core" +import { LeftRightVerticalAdaptLayout, Label, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class LeftRightVerticalAdaptLayoutDemo extends Widget { static xtype = "demo.left_right_vertical_adapt"; diff --git a/packages/demo/src/demo/core/layout/demo.table.js b/packages/demo/src/demo/core/layout/demo.table.js index e988d4a9e..cdb546894 100644 --- a/packages/demo/src/demo/core/layout/demo.table.js +++ b/packages/demo/src/demo/core/layout/demo.table.js @@ -1,8 +1,8 @@ -import { TableLayout, Layout, GridLayout, shortcut, Widget, createItems } from "@fui/core" +import { TableLayout, Layout, GridLayout, Decorators, Widget, createItems } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class TableLayoutDemo extends Widget { static xtype = "demo.table_layout"; diff --git a/packages/demo/src/demo/core/layout/demo.td.js b/packages/demo/src/demo/core/layout/demo.td.js index ddd5f70ff..e36d535c4 100644 --- a/packages/demo/src/demo/core/layout/demo.td.js +++ b/packages/demo/src/demo/core/layout/demo.td.js @@ -1,8 +1,8 @@ -import { VerticalLayout, TdLayout, Label, shortcut, Widget, createItems } from "@fui/core" +import { VerticalLayout, TdLayout, Label, Decorators, Widget, createItems } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class TdLayoutDemo extends Widget { static xtype = "demo.td"; diff --git a/packages/demo/src/demo/core/layout/demo.vertical.js b/packages/demo/src/demo/core/layout/demo.vertical.js index 263214e1b..7ff15d4a0 100644 --- a/packages/demo/src/demo/core/layout/demo.vertical.js +++ b/packages/demo/src/demo/core/layout/demo.vertical.js @@ -1,8 +1,8 @@ -import { VerticalLayout, Label, shortcut, Widget } from "@fui/core" +import { VerticalLayout, Label, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class VerticalLayoutDemo extends Widget { static xtype = "demo.vertical"; diff --git a/packages/demo/src/demo/core/layout/demo.vertical_adapt.js b/packages/demo/src/demo/core/layout/demo.vertical_adapt.js index a6c825d54..061624a0b 100644 --- a/packages/demo/src/demo/core/layout/demo.vertical_adapt.js +++ b/packages/demo/src/demo/core/layout/demo.vertical_adapt.js @@ -1,8 +1,8 @@ -import { VerticalAdaptLayout, Label, GridLayout, shortcut, Widget, createWidget } from "@fui/core" +import { VerticalAdaptLayout, Label, GridLayout, Decorators, Widget, createWidget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class VerticalAdaptLayoutDemo extends Widget { static xtype = "demo.vertical_adapt"; diff --git a/packages/demo/src/demo/core/layout/demo.vtape.js b/packages/demo/src/demo/core/layout/demo.vtape.js index 370c46e60..8023e193b 100644 --- a/packages/demo/src/demo/core/layout/demo.vtape.js +++ b/packages/demo/src/demo/core/layout/demo.vtape.js @@ -1,8 +1,8 @@ -import { VTapeLayout, Label, shortcut, Widget } from "@fui/core" +import { VTapeLayout, Label, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class VtapeLayoutDemo extends Widget { static xtype = "demo.vtape"; diff --git a/packages/demo/src/demo/core/popup/demo.layer.js b/packages/demo/src/demo/core/popup/demo.layer.js index b0fdc81a4..dcecd9ef4 100644 --- a/packages/demo/src/demo/core/popup/demo.layer.js +++ b/packages/demo/src/demo/core/popup/demo.layer.js @@ -1,9 +1,9 @@ -import { VerticalLayout, Button, CenterAdaptLayout, shortcut, Widget, UUID, Layers } from "@fui/core" +import { VerticalLayout, Button, CenterAdaptLayout, Decorators, Widget, UUID, Layers } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class LayerDemo extends Widget { static xtype = "demo.layer"; diff --git a/packages/demo/src/demo/core/popup/demo.popover.js b/packages/demo/src/demo/core/popup/demo.popover.js index 394b4863d..cf8211daa 100644 --- a/packages/demo/src/demo/core/popup/demo.popover.js +++ b/packages/demo/src/demo/core/popup/demo.popover.js @@ -1,9 +1,9 @@ -import { VerticalLayout, TextButton, BarPopover, Label, ButtonGroup, shortcut, Widget, UUID, map, range, Popovers } from "@fui/core" +import { VerticalLayout, TextButton, BarPopover, Label, ButtonGroup, Decorators, Widget, UUID, map, range, Popovers } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class PopoverDemo extends Widget { static xtype = "demo.popover"; diff --git a/packages/demo/src/demo/core/popup/demo.popup_view.js b/packages/demo/src/demo/core/popup/demo.popup_view.js index 69d404bf3..833177f50 100644 --- a/packages/demo/src/demo/core/popup/demo.popup_view.js +++ b/packages/demo/src/demo/core/popup/demo.popup_view.js @@ -1,9 +1,9 @@ -import { AbsoluteLayout, Combo, TextButton, PopupView, ButtonGroup, VerticalLayout, MultiSelectItem, shortcut, Widget, createItems, deepClone } from "@fui/core" +import { AbsoluteLayout, Combo, TextButton, PopupView, ButtonGroup, VerticalLayout, MultiSelectItem, Decorators, Widget, createItems, deepClone } from "@fui/core" import { CONSTANTS } from "@/config/constant"; -@shortcut() +@Decorators.shortcut() export class PopupViewDemo extends Widget { static xtype = "demo.popup_view"; diff --git a/packages/demo/src/demo/core/popup/demo.searcher_view.js b/packages/demo/src/demo/core/popup/demo.searcher_view.js index 241c54350..d8fd1858f 100644 --- a/packages/demo/src/demo/core/popup/demo.searcher_view.js +++ b/packages/demo/src/demo/core/popup/demo.searcher_view.js @@ -2,12 +2,12 @@ import { AbsoluteLayout, SearcherView, Label, - shortcut, + Decorators, Widget, createItems } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SearcherViewDemo extends Widget { static xtype = "demo.searcher_view"; diff --git a/packages/demo/src/demo/fix-2.0/context.js b/packages/demo/src/demo/fix-2.0/context.js index 2264ef9b6..376877ff2 100644 --- a/packages/demo/src/demo/fix-2.0/context.js +++ b/packages/demo/src/demo/fix-2.0/context.js @@ -1,4 +1,4 @@ -import { shortcut, Widget, AbsoluteLayout, Button, Fix, model, Models } from '@fui/core'; +import { Decorators, Widget, AbsoluteLayout, Button, Fix, model, Models } from '@fui/core'; @model() class ParentStore extends Fix.Model { @@ -29,7 +29,7 @@ class ChildStore extends Fix.Model { }; } -@shortcut() +@Decorators.shortcut() class Child extends Widget { static xtype = 'demo.fix_context_child'; @@ -58,7 +58,7 @@ class Child extends Widget { } } -@shortcut() +@Decorators.shortcut() export class FixContextDemo extends Widget { static xtype = 'demo.fix_context'; diff --git a/packages/demo/src/demo/fix-2.0/define.js b/packages/demo/src/demo/fix-2.0/define.js index 851c2bbe3..f16152fbb 100644 --- a/packages/demo/src/demo/fix-2.0/define.js +++ b/packages/demo/src/demo/fix-2.0/define.js @@ -1,6 +1,6 @@ -import { shortcut, AbsoluteLayout, Button, Widget, Fix } from '@fui/core'; +import { Decorators, AbsoluteLayout, Button, Widget, Fix } from '@fui/core'; -@shortcut() +@Decorators.shortcut() export class DefineDemo extends Widget { static xtype = 'demo.fix2.define'; diff --git a/packages/demo/src/demo/widget/basewidget/demo.buttons.js b/packages/demo/src/demo/widget/basewidget/demo.buttons.js index 8f60986da..cf92caae7 100644 --- a/packages/demo/src/demo/widget/basewidget/demo.buttons.js +++ b/packages/demo/src/demo/widget/basewidget/demo.buttons.js @@ -2,13 +2,13 @@ import { Button, MultiSelectBar, FloatLeftLayout, - shortcut, Widget, each, - Msg + Msg, + Decorators } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class ButtonsDemo extends Widget { static xtype = "demo.buttons"; diff --git a/packages/demo/src/demo/widget/basewidget/demo.items.js b/packages/demo/src/demo/widget/basewidget/demo.items.js index 11a3959c1..0a9f8780b 100644 --- a/packages/demo/src/demo/widget/basewidget/demo.items.js +++ b/packages/demo/src/demo/widget/basewidget/demo.items.js @@ -1,5 +1,4 @@ import { - shortcut, Widget, VerticalLayout, TextButton, @@ -7,10 +6,11 @@ import { SingleSelectRadioItem, Label, MultiSelectItem, - Switch + Switch, + Decorators } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class Items extends Widget { static xtype = "demo.items"; diff --git a/packages/demo/src/demo/widget/basewidget/demo.nodes.js b/packages/demo/src/demo/widget/basewidget/demo.nodes.js index 494d37697..8392f6659 100644 --- a/packages/demo/src/demo/widget/basewidget/demo.nodes.js +++ b/packages/demo/src/demo/widget/basewidget/demo.nodes.js @@ -1,15 +1,15 @@ import { - shortcut, Widget, VerticalLayout, Label, PlusGroupNode, ArrowNode, IconArrowNode, - MultiLayerIconArrowNode + MultiLayerIconArrowNode, + Decorators, } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class NodesDemo extends Widget { static xtype = "demo.nodes"; diff --git a/packages/demo/src/demo/widget/basewidget/demo.sagments.js b/packages/demo/src/demo/widget/basewidget/demo.sagments.js index ccbc2105c..fe36cbc68 100644 --- a/packages/demo/src/demo/widget/basewidget/demo.sagments.js +++ b/packages/demo/src/demo/widget/basewidget/demo.sagments.js @@ -1,6 +1,6 @@ -import { VerticalLayout, Label, Segment, shortcut, Widget } from "@fui/core"; +import { VerticalLayout, Label, Segment, Decorators, Widget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SegmentsDemo extends Widget { static xtype = "demo.segments"; diff --git a/packages/demo/src/demo/widget/basewidget/demo.tips.js b/packages/demo/src/demo/widget/basewidget/demo.tips.js index 3cb3fbff5..fd519dc0a 100644 --- a/packages/demo/src/demo/widget/basewidget/demo.tips.js +++ b/packages/demo/src/demo/widget/basewidget/demo.tips.js @@ -1,7 +1,6 @@ import { Bubbles, Msg, - shortcut, Widget, createWidget, each, @@ -9,10 +8,11 @@ import { Button, VerticalLayout, Label, + Decorators, HorizontalAutoLayout } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class TipsDemo extends Widget { static xtype = "demo.tips"; diff --git a/packages/demo/src/demo/widget/collapase/demo.collapse.js b/packages/demo/src/demo/widget/collapase/demo.collapse.js index 7a9da8d11..0558523f1 100644 --- a/packages/demo/src/demo/widget/collapase/demo.collapse.js +++ b/packages/demo/src/demo/widget/collapase/demo.collapse.js @@ -1,14 +1,14 @@ import { - shortcut, Widget, createItems, SingleSelectItem, Label, VerticalLayout, + Decorators, Collapse } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class CollapseDemo extends Widget { static xtype = "demo.collapse"; diff --git a/packages/demo/src/demo/widget/date/demo.datepane.js b/packages/demo/src/demo/widget/date/demo.datepane.js index 98bd52dd1..14c092a32 100644 --- a/packages/demo/src/demo/widget/date/demo.datepane.js +++ b/packages/demo/src/demo/widget/date/demo.datepane.js @@ -1,5 +1,5 @@ import { - shortcut, + Decorators, Widget, Msg, HorizontalAutoLayout, @@ -9,7 +9,7 @@ import { DynamicDateTimePane } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class DatePane extends Widget { static xtype = "demo.date_pane"; diff --git a/packages/demo/src/demo/widget/date/demo.multidate_combo.js b/packages/demo/src/demo/widget/date/demo.multidate_combo.js index dfc684802..5ebe494d3 100644 --- a/packages/demo/src/demo/widget/date/demo.multidate_combo.js +++ b/packages/demo/src/demo/widget/date/demo.multidate_combo.js @@ -1,5 +1,5 @@ import { - shortcut, + Decorators, Widget, Msg, HorizontalAutoLayout, @@ -8,7 +8,7 @@ import { DynamicDateTimeCombo } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class Date extends Widget { static xtype = "demo.multidate_combo"; diff --git a/packages/demo/src/demo/widget/datetime/demo.datetime.js b/packages/demo/src/demo/widget/datetime/demo.datetime.js index c13242cfe..62c484409 100644 --- a/packages/demo/src/demo/widget/datetime/demo.datetime.js +++ b/packages/demo/src/demo/widget/datetime/demo.datetime.js @@ -1,13 +1,13 @@ import { AbsoluteLayout, DateTimeCombo, - shortcut, + Decorators, Widget, print, Msg, } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class CustomDateTimeDemo extends Widget { static xtype = "demo.date_time"; diff --git a/packages/demo/src/demo/widget/downlist/demo.downlist.icon.js b/packages/demo/src/demo/widget/downlist/demo.downlist.icon.js index 7ead43c98..8905caf28 100644 --- a/packages/demo/src/demo/widget/downlist/demo.downlist.icon.js +++ b/packages/demo/src/demo/widget/downlist/demo.downlist.icon.js @@ -1,7 +1,7 @@ -import { Label, shortcut, Widget } from "@fui/core" +import { Label, Decorators, Widget } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class CustomIcon extends Widget { static xtype = "demo.downlist.icon"; diff --git a/packages/demo/src/demo/widget/downlist/demo.downlist.js b/packages/demo/src/demo/widget/downlist/demo.downlist.js index fccb8c3e6..9d92558cd 100644 --- a/packages/demo/src/demo/widget/downlist/demo.downlist.js +++ b/packages/demo/src/demo/widget/downlist/demo.downlist.js @@ -1,5 +1,5 @@ import { - shortcut, + Decorators, Widget, i18nText, DownListCombo, @@ -9,7 +9,7 @@ import { Label } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class DownlistDemo extends Widget { static xtype = "demo.down_list"; diff --git a/packages/demo/src/demo/widget/editor/demo.search_editor.js b/packages/demo/src/demo/widget/editor/demo.search_editor.js index 0b3cfa9ba..6a64bba16 100644 --- a/packages/demo/src/demo/widget/editor/demo.search_editor.js +++ b/packages/demo/src/demo/widget/editor/demo.search_editor.js @@ -2,11 +2,11 @@ import { HorizontalAutoLayout, SearchEditor, SmallSearchEditor, - shortcut, + Decorators, Widget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SearchEditorDemo extends Widget { static xtype = "demo.search_editor"; diff --git a/packages/demo/src/demo/widget/editor/demo.text_editor.js b/packages/demo/src/demo/widget/editor/demo.text_editor.js index 8ea69c4d3..cfab878ab 100644 --- a/packages/demo/src/demo/widget/editor/demo.text_editor.js +++ b/packages/demo/src/demo/widget/editor/demo.text_editor.js @@ -1,6 +1,6 @@ -import { HorizontalAutoLayout, TextEditor, shortcut, Widget } from "@fui/core"; +import { HorizontalAutoLayout, TextEditor, Decorators, Widget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class TextEditorDemo extends Widget { static xtype = "demo.text_editor"; diff --git a/packages/demo/src/demo/widget/multiselect/demo.multi_select_combo.js b/packages/demo/src/demo/widget/multiselect/demo.multi_select_combo.js index ecc3818bc..a9e35b6e5 100644 --- a/packages/demo/src/demo/widget/multiselect/demo.multi_select_combo.js +++ b/packages/demo/src/demo/widget/multiselect/demo.multi_select_combo.js @@ -2,7 +2,7 @@ import { CONSTANTS } from "@/config/constant"; import { MultiSelectInsertCombo, AbsoluteLayout, - shortcut, + Decorators, Widget, Func, createWidget, @@ -14,7 +14,7 @@ import { Msg } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class MultiSelectComboDemo extends Widget { static xtype = "demo.multi_select_combo"; static EVENT_CONFIRM = "EVENT_CONFIRM"; diff --git a/packages/demo/src/demo/widget/multiselect/demo.multi_select_list.js b/packages/demo/src/demo/widget/multiselect/demo.multi_select_list.js index f071f54c7..3ae93b7dd 100644 --- a/packages/demo/src/demo/widget/multiselect/demo.multi_select_list.js +++ b/packages/demo/src/demo/widget/multiselect/demo.multi_select_list.js @@ -2,7 +2,7 @@ import { CONSTANTS } from "@/config/constant"; import { MultiSelectInsertList, AbsoluteLayout, - shortcut, + Decorators, Widget, createWidget, Func, @@ -15,7 +15,7 @@ import { MultiSelectCombo } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class MultiSelectListDemo extends Widget { static xtype = "demo.multi_select_list"; diff --git a/packages/demo/src/demo/widget/multitree/demo.multi_tree_combo.js b/packages/demo/src/demo/widget/multitree/demo.multi_tree_combo.js index d5660d147..8cd5fac45 100644 --- a/packages/demo/src/demo/widget/multitree/demo.multi_tree_combo.js +++ b/packages/demo/src/demo/widget/multitree/demo.multi_tree_combo.js @@ -3,14 +3,14 @@ import { HorizontalAutoLayout, MultiTreeCombo, Button, - shortcut, + Decorators, Widget, deepClone, Msg, TreeView } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class MultiTreeComboDemo extends Widget { static xtype = "demo.multi_tree_combo"; diff --git a/packages/demo/src/demo/widget/multitree/demo.multi_tree_list.js b/packages/demo/src/demo/widget/multitree/demo.multi_tree_list.js index 002933000..b92934144 100644 --- a/packages/demo/src/demo/widget/multitree/demo.multi_tree_list.js +++ b/packages/demo/src/demo/widget/multitree/demo.multi_tree_list.js @@ -3,14 +3,14 @@ import { AbsoluteLayout, MultiSelectTree, Button, - shortcut, + Decorators, Widget, deepClone, Msg, TreeView } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class MultiSelectTreeDemo extends Widget { static xtype = "demo.multi_select_tree"; diff --git a/packages/demo/src/demo/widget/numbereditor/demo.number_editor.js b/packages/demo/src/demo/widget/numbereditor/demo.number_editor.js index 727cb9ba5..63a8ab40f 100644 --- a/packages/demo/src/demo/widget/numbereditor/demo.number_editor.js +++ b/packages/demo/src/demo/widget/numbereditor/demo.number_editor.js @@ -1,14 +1,14 @@ import { NumberEditor, VerticalLayout, - shortcut, + Decorators, Widget, createWidget, parseFloat, Msg } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class FileManagerDemo extends Widget { static xtype = "demo.number_editor"; diff --git a/packages/demo/src/demo/widget/numberinterval/demo.number_interval.js b/packages/demo/src/demo/widget/numberinterval/demo.number_interval.js index 295cd8b9a..aa11c27ae 100644 --- a/packages/demo/src/demo/widget/numberinterval/demo.number_interval.js +++ b/packages/demo/src/demo/widget/numberinterval/demo.number_interval.js @@ -2,11 +2,11 @@ import { HorizontalAutoLayout, NumberInterval, Label, - shortcut, + Decorators, Widget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class NumericalIntervalDemo extends Widget { static xtype = "demo.number_interval"; diff --git a/packages/demo/src/demo/widget/selecttree/demo.multilayer_select_tree_combo.js b/packages/demo/src/demo/widget/selecttree/demo.multilayer_select_tree_combo.js index 30fb4b21a..eb0736b77 100644 --- a/packages/demo/src/demo/widget/selecttree/demo.multilayer_select_tree_combo.js +++ b/packages/demo/src/demo/widget/selecttree/demo.multilayer_select_tree_combo.js @@ -1,10 +1,10 @@ import { CONSTANTS } from "@/config/constant"; -import { HorizontalAutoLayout, MultiLayerSelectTreeCombo, Button, shortcut, Widget, deepClone, Msg } from "@fui/core" +import { HorizontalAutoLayout, MultiLayerSelectTreeCombo, Button, Decorators, Widget, deepClone, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class MultiLayerSelectTreeComboDemo extends Widget { static xtype = "demo.multilayer_select_tree_combo"; diff --git a/packages/demo/src/demo/widget/selecttree/demo.select_tree_combo.js b/packages/demo/src/demo/widget/selecttree/demo.select_tree_combo.js index c891f46a8..3fcaf900a 100644 --- a/packages/demo/src/demo/widget/selecttree/demo.select_tree_combo.js +++ b/packages/demo/src/demo/widget/selecttree/demo.select_tree_combo.js @@ -3,13 +3,13 @@ import { HorizontalAutoLayout, SelectTreeCombo, Button, - shortcut, + Decorators, Widget, deepClone, Msg } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SelectTreeComboDemo extends Widget { static xtype = "demo.select_tree_combo"; diff --git a/packages/demo/src/demo/widget/singleselct/demo.single_select_combo.js b/packages/demo/src/demo/widget/singleselct/demo.single_select_combo.js index 86ffbe8bc..d4c9fc97f 100644 --- a/packages/demo/src/demo/widget/singleselct/demo.single_select_combo.js +++ b/packages/demo/src/demo/widget/singleselct/demo.single_select_combo.js @@ -1,9 +1,9 @@ import { CONSTANTS } from "@/config/constant"; -import { SingleSelectCombo, AbsoluteLayout, Button, shortcut, Widget, Func, createWidget, bind, each, makeObject, filter, delay } from "@fui/core" +import { SingleSelectCombo, AbsoluteLayout, Button, Decorators, Widget, Func, createWidget, bind, each, makeObject, filter, delay } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class SingleSelectComboDemo extends Widget { static xtype = "demo.single_select_combo"; diff --git a/packages/demo/src/demo/widget/singletree/demo.multilayer_single_tree_combo.js b/packages/demo/src/demo/widget/singletree/demo.multilayer_single_tree_combo.js index e9364ff99..8f4bcd926 100644 --- a/packages/demo/src/demo/widget/singletree/demo.multilayer_single_tree_combo.js +++ b/packages/demo/src/demo/widget/singletree/demo.multilayer_single_tree_combo.js @@ -1,10 +1,10 @@ import { CONSTANTS } from "@/config/constant"; -import { HorizontalAutoLayout, MultiLayerSingleTreeCombo, Button, shortcut, Widget, deepClone, Msg } from "@fui/core" +import { HorizontalAutoLayout, MultiLayerSingleTreeCombo, Button, Decorators, Widget, deepClone, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class MultiLayerSingleTreeComboDemo extends Widget { static xtype = "demo.multilayer_single_tree_combo"; diff --git a/packages/demo/src/demo/widget/singletree/demo.single_tree_combo.js b/packages/demo/src/demo/widget/singletree/demo.single_tree_combo.js index 930c87383..932a4ffc9 100644 --- a/packages/demo/src/demo/widget/singletree/demo.single_tree_combo.js +++ b/packages/demo/src/demo/widget/singletree/demo.single_tree_combo.js @@ -1,10 +1,10 @@ import { CONSTANTS } from "@/config/constant"; -import { HorizontalAutoLayout, SingleTreeCombo, Button, shortcut, Widget, deepClone, Msg } from "@fui/core" +import { HorizontalAutoLayout, SingleTreeCombo, Button, Decorators, Widget, deepClone, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class SingleTreeComboDemo extends Widget { static xtype = "demo.single_tree_combo"; diff --git a/packages/demo/src/demo/widget/slider/demo.slider.js b/packages/demo/src/demo/widget/slider/demo.slider.js index d19e1a896..681f9f633 100644 --- a/packages/demo/src/demo/widget/slider/demo.slider.js +++ b/packages/demo/src/demo/widget/slider/demo.slider.js @@ -5,12 +5,12 @@ import { IntervalSlider, VerticalLayout, CenterAdaptLayout, - shortcut, + Decorators, Widget, createWidget } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SliderDemo extends Widget { static xtype = "demo.slider"; diff --git a/packages/demo/src/demo/widget/timecombo/demo.timecombo.js b/packages/demo/src/demo/widget/timecombo/demo.timecombo.js index 62fbdd0a2..6d795b00b 100644 --- a/packages/demo/src/demo/widget/timecombo/demo.timecombo.js +++ b/packages/demo/src/demo/widget/timecombo/demo.timecombo.js @@ -1,9 +1,9 @@ -import { HorizontalAutoLayout, TimeCombo, Button, shortcut, Widget, Msg } from "@fui/core" +import { HorizontalAutoLayout, TimeCombo, Button, Decorators, Widget, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class TimeComboDemo extends Widget { static xtype = "demo.time_combo"; diff --git a/packages/demo/src/demo/widget/timeinterval/demo.time_interval.js b/packages/demo/src/demo/widget/timeinterval/demo.time_interval.js index 989a101b7..184f33173 100644 --- a/packages/demo/src/demo/widget/timeinterval/demo.time_interval.js +++ b/packages/demo/src/demo/widget/timeinterval/demo.time_interval.js @@ -1,9 +1,9 @@ import { CONSTANTS } from "@/config/constant"; -import { HorizontalAutoLayout, DateInterval, Button, TimeInterval, TimePeriods, shortcut, Widget, deepClone, Msg } from "@fui/core" +import { HorizontalAutoLayout, DateInterval, Button, TimeInterval, TimePeriods, Decorators, Widget, deepClone, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class TimeIntervalDemo extends Widget { static xtype = "demo.time_interval"; diff --git a/packages/demo/src/demo/widget/tree/demo.multilayer_select_level_tree.js b/packages/demo/src/demo/widget/tree/demo.multilayer_select_level_tree.js index 3820912fa..b9d5b48de 100644 --- a/packages/demo/src/demo/widget/tree/demo.multilayer_select_level_tree.js +++ b/packages/demo/src/demo/widget/tree/demo.multilayer_select_level_tree.js @@ -3,14 +3,14 @@ import { MultiLayerSelectLevelTree, VTapeLayout, Button, - shortcut, + Decorators, Widget, createWidget, deepClone, Msg } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class MultiLayerSelectLevelTreeDemo extends Widget { static xtype = "demo.multilayer_select_level_tree"; diff --git a/packages/demo/src/demo/widget/tree/demo.multilayer_single_level_tree.js b/packages/demo/src/demo/widget/tree/demo.multilayer_single_level_tree.js index 9b142450f..3b1140430 100644 --- a/packages/demo/src/demo/widget/tree/demo.multilayer_single_level_tree.js +++ b/packages/demo/src/demo/widget/tree/demo.multilayer_single_level_tree.js @@ -1,9 +1,9 @@ -import { MultiLayerSingleLevelTree, VTapeLayout, Button, shortcut, Widget, createWidget, Msg } from "@fui/core" +import { MultiLayerSingleLevelTree, VTapeLayout, Button, Decorators, Widget, createWidget, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class MultiLayerSingleLevelTreeDemo extends Widget { static xtype = "demo.multilayer_single_level_tree"; diff --git a/packages/demo/src/demo/widget/tree/demo.select_level_tree.js b/packages/demo/src/demo/widget/tree/demo.select_level_tree.js index cbe9dd096..bc7b1f01c 100644 --- a/packages/demo/src/demo/widget/tree/demo.select_level_tree.js +++ b/packages/demo/src/demo/widget/tree/demo.select_level_tree.js @@ -3,14 +3,14 @@ import { SelectTreePopup, VTapeLayout, Button, - shortcut, + Decorators, Widget, createWidget, deepClone, Msg } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SelectLevelTreeDemo extends Widget { static xtype = "demo.select_level_tree"; diff --git a/packages/demo/src/demo/widget/tree/demo.single_level_tree.js b/packages/demo/src/demo/widget/tree/demo.single_level_tree.js index 8615a811e..8014ac46e 100644 --- a/packages/demo/src/demo/widget/tree/demo.single_level_tree.js +++ b/packages/demo/src/demo/widget/tree/demo.single_level_tree.js @@ -3,14 +3,14 @@ import { SingleTreePopup, VTapeLayout, Button, - shortcut, + Decorators, Widget, createWidget, deepClone, Msg } from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class SingleLevelTreeDemo extends Widget { static xtype = "demo.single_level_tree"; diff --git a/packages/demo/src/demo/widget/year/demo.year.js b/packages/demo/src/demo/widget/year/demo.year.js index a007a3b87..d4dc87658 100644 --- a/packages/demo/src/demo/widget/year/demo.year.js +++ b/packages/demo/src/demo/widget/year/demo.year.js @@ -1,9 +1,9 @@ -import { HorizontalAutoLayout, DynamicYearCombo, Button, shortcut, Widget, Msg } from "@fui/core" +import { HorizontalAutoLayout, DynamicYearCombo, Button, Decorators, Widget, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class YearDemo extends Widget { static xtype = "demo.year"; diff --git a/packages/demo/src/demo/widget/yearinterval/demo.year_interval.js b/packages/demo/src/demo/widget/yearinterval/demo.year_interval.js index 5fe5cf16c..4899bb8f4 100644 --- a/packages/demo/src/demo/widget/yearinterval/demo.year_interval.js +++ b/packages/demo/src/demo/widget/yearinterval/demo.year_interval.js @@ -1,9 +1,9 @@ -import { HorizontalAutoLayout, YearInterval, Button, shortcut, Widget, Msg } from "@fui/core" +import { HorizontalAutoLayout, YearInterval, Button, Decorators, Widget, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class YearIntervalDemo extends Widget { static xtype = "demo.year_interval"; diff --git a/packages/demo/src/demo/widget/yearmonth/demo.year_month_combo.js b/packages/demo/src/demo/widget/yearmonth/demo.year_month_combo.js index 1995fe9c9..86fd00651 100644 --- a/packages/demo/src/demo/widget/yearmonth/demo.year_month_combo.js +++ b/packages/demo/src/demo/widget/yearmonth/demo.year_month_combo.js @@ -1,9 +1,9 @@ -import { HorizontalAutoLayout, DynamicYearMonthCombo, Button, shortcut, Widget, Msg } from "@fui/core" +import { HorizontalAutoLayout, DynamicYearMonthCombo, Button, Decorators, Widget, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class YearMonthComboDemo extends Widget { static xtype = "demo.year_month_combo"; diff --git a/packages/demo/src/demo/widget/yearmonthinterval/demo.year_month_interval.js b/packages/demo/src/demo/widget/yearmonthinterval/demo.year_month_interval.js index 95c9a3555..014c80565 100644 --- a/packages/demo/src/demo/widget/yearmonthinterval/demo.year_month_interval.js +++ b/packages/demo/src/demo/widget/yearmonthinterval/demo.year_month_interval.js @@ -1,9 +1,9 @@ -import { HorizontalAutoLayout, YearMonthInterval, Button, shortcut, Widget, Msg } from "@fui/core" +import { HorizontalAutoLayout, YearMonthInterval, Button, Decorators, Widget, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class YearMonthIntervalDemo extends Widget { static xtype = "demo.year_month_interval"; diff --git a/packages/demo/src/demo/widget/yearquarter/demo.year_quarter_combo.js b/packages/demo/src/demo/widget/yearquarter/demo.year_quarter_combo.js index 62f05fbf2..c3cef10d5 100644 --- a/packages/demo/src/demo/widget/yearquarter/demo.year_quarter_combo.js +++ b/packages/demo/src/demo/widget/yearquarter/demo.year_quarter_combo.js @@ -1,9 +1,9 @@ -import { HorizontalAutoLayout, DynamicYearQuarterCombo, Button, shortcut, Widget, Msg } from "@fui/core" +import { HorizontalAutoLayout, DynamicYearQuarterCombo, Button, Decorators, Widget, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class YearQuarterComboDemo extends Widget { static xtype = "demo.year_quarter_combo"; diff --git a/packages/demo/src/demo/widget/yearquarterinterval/demo.yearquarterinterval.js b/packages/demo/src/demo/widget/yearquarterinterval/demo.yearquarterinterval.js index fd2bd1c68..f21b2acc8 100644 --- a/packages/demo/src/demo/widget/yearquarterinterval/demo.yearquarterinterval.js +++ b/packages/demo/src/demo/widget/yearquarterinterval/demo.yearquarterinterval.js @@ -1,9 +1,9 @@ -import { HorizontalAutoLayout, YearQuarterInterval, Button, shortcut, Widget, Msg } from "@fui/core" +import { HorizontalAutoLayout, YearQuarterInterval, Button, Decorators, Widget, Msg } from "@fui/core" -@shortcut() +@Decorators.shortcut() export class YearQuarterIntervalDemo extends Widget { static xtype = "demo.year_quarter_interval"; diff --git a/packages/demo/src/face.js b/packages/demo/src/face.js index c19045449..31be872f6 100644 --- a/packages/demo/src/face.js +++ b/packages/demo/src/face.js @@ -1,7 +1,7 @@ import { Widget, Label, - shortcut, + Decorators, each, Msg, StyleLoaders, @@ -16,14 +16,15 @@ import { IconTextIconItem, GridLayout, Layout, -} from '@fui/core'; + Fix, +} from "@fui/core"; -@shortcut() +@Decorators.shortcut() export class Face extends Widget { - static xtype = 'demo.face'; + static xtype = "demo.face"; props = { - baseCls: 'demo-face', + baseCls: "demo-face", }; _createLabel(text) { @@ -32,10 +33,10 @@ export class Face extends Widget { el: { type: Label.xtyp, text: text, - textAlign: 'left', + textAlign: "left", hgap: 5, height: 40, - cls: 'config-label', + cls: "config-label", }, }; } @@ -66,15 +67,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('背景色:'), + this._createLabel("背景色:"), this._createColorPicker( - function () { + function() { self.backgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -86,15 +87,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('字体颜色:'), + this._createLabel("字体颜色:"), this._createColorPicker( - function () { + function() { self.fontColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -106,15 +107,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('激活状态字体颜色:'), + this._createLabel("激活状态字体颜色:"), this._createColorPicker( - function () { + function() { self.activeFontColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -122,8 +123,8 @@ export class Face extends Widget { width: 100, el: { type: TextButton.xtype, - cls: 'bi-list-item-active', - text: '测试激活状态', + cls: "bi-list-item-active", + text: "测试激活状态", }, }, ], @@ -134,15 +135,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('选中状态字体颜色:'), + this._createLabel("选中状态字体颜色:"), this._createColorPicker( - function () { + function() { self.selectFontColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -150,8 +151,8 @@ export class Face extends Widget { width: 100, el: { type: TextButton.xtype, - cls: 'bi-list-item-active', - text: '测试选中状态', + cls: "bi-list-item-active", + text: "测试选中状态", }, }, ], @@ -162,15 +163,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('tip提示字体颜色:'), + this._createLabel("tip提示字体颜色:"), this._createColorPicker( - function () { + function() { self.grayFontColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -178,9 +179,9 @@ export class Face extends Widget { width: 100, el: { type: IconTextItem.xtype, - cls: 'bi-tips copy-font', + cls: "bi-tips copy-font", height: 40, - text: '测试提示文字', + text: "测试提示文字", }, }, ], @@ -191,15 +192,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('灰化字体颜色:'), + this._createLabel("灰化字体颜色:"), this._createColorPicker( - function () { + function() { self.disabledFontColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -207,7 +208,7 @@ export class Face extends Widget { width: 100, el: { type: TextButton.xtype, - text: '这个按钮是灰化的', + text: "这个按钮是灰化的", disabled: true, }, }, @@ -219,15 +220,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('Card背景颜色:'), + this._createLabel("Card背景颜色:"), this._createColorPicker( - function () { + function() { self.cardBackgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -239,15 +240,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('悬浮状态背景颜色:'), + this._createLabel("悬浮状态背景颜色:"), this._createColorPicker( - function () { + function() { self.hoverBackgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -255,8 +256,8 @@ export class Face extends Widget { width: 100, el: { type: TextButton.xtype, - cls: 'bi-list-item-active', - text: '测试悬浮状态', + cls: "bi-list-item-active", + text: "测试悬浮状态", }, }, ], @@ -267,15 +268,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('激活状态背景颜色:'), + this._createLabel("激活状态背景颜色:"), this._createColorPicker( - function () { + function() { self.activeBackgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -283,8 +284,8 @@ export class Face extends Widget { width: 100, el: { type: TextButton.xtype, - cls: 'bi-list-item-active', - text: '测试激活状态', + cls: "bi-list-item-active", + text: "测试激活状态", }, }, ], @@ -295,15 +296,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('选中状态背景颜色:'), + this._createLabel("选中状态背景颜色:"), this._createColorPicker( - function () { + function() { self.selectBackgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -311,8 +312,8 @@ export class Face extends Widget { width: 100, el: { type: TextButton.xtype, - cls: 'bi-list-item-active', - text: '测试选中状态', + cls: "bi-list-item-active", + text: "测试选中状态", }, }, ], @@ -323,15 +324,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('分割线颜色:'), + this._createLabel("分割线颜色:"), this._createColorPicker( - function () { + function() { self.slitColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -343,7 +344,7 @@ export class Face extends Widget { return { type: VerticalLayout.xtype, items: [ - this._createLabel('--通用配色--'), + this._createLabel("--通用配色--"), this._createBackgroundConfig(), this._createCardBackgroundConfig(), this._createFontConfig(), @@ -363,15 +364,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('按钮背景色1:'), + this._createLabel("按钮背景色1:"), this._createColorPicker( - function () { + function() { self.button1BackgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -383,8 +384,8 @@ export class Face extends Widget { items: [ { type: Button.xtype, - cls: 'config-button1', - text: '测试按钮', + cls: "config-button1", + text: "测试按钮", }, ], }, @@ -397,15 +398,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('按钮背景色2:'), + this._createLabel("按钮背景色2:"), this._createColorPicker( - function () { + function() { self.button2BackgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -417,9 +418,9 @@ export class Face extends Widget { items: [ { type: Button.xtype, - level: 'success', - cls: 'config-button2', - text: '测试按钮', + level: "success", + cls: "config-button2", + text: "测试按钮", }, ], }, @@ -432,15 +433,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('按钮背景色3:'), + this._createLabel("按钮背景色3:"), this._createColorPicker( - function () { + function() { self.button3BackgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -452,9 +453,9 @@ export class Face extends Widget { items: [ { type: Button.xtype, - level: 'warning', - cls: 'config-button3', - text: '测试按钮', + level: "warning", + cls: "config-button3", + text: "测试按钮", }, ], }, @@ -467,15 +468,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('按钮背景色4:'), + this._createLabel("按钮背景色4:"), this._createColorPicker( - function () { + function() { self.button4BackgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -487,9 +488,9 @@ export class Face extends Widget { items: [ { type: Button.xtype, - level: 'ignore', - cls: 'config-button4', - text: '测试按钮', + level: "ignore", + cls: "config-button4", + text: "测试按钮", }, ], }, @@ -502,15 +503,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('滚动条底色:'), + this._createLabel("滚动条底色:"), this._createColorPicker( - function () { + function() { self.scrollBackgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -522,15 +523,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('滚动条thumb颜色:'), + this._createLabel("滚动条thumb颜色:"), this._createColorPicker( - function () { + function() { self.scrollThumbColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -542,15 +543,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('下拉框背景颜色:'), + this._createLabel("下拉框背景颜色:"), this._createColorPicker( - function () { + function() { self.popupBackgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -565,35 +566,35 @@ export class Face extends Widget { [ { el: { - text: 'column 1111', - iconCls1: 'check-mark-e-font', + text: "column 1111", + iconCls1: "check-mark-e-font", value: 11, }, children: [ { - text: 'column 1.1', + text: "column 1.1", value: 21, - cls: 'dot-e-font', + cls: "dot-e-font", selected: true, }, { - text: 'column 1.222222222222222222222222222222222222', - cls: 'dot-e-font', + text: "column 1.222222222222222222222222222222222222", + cls: "dot-e-font", value: 22, }, { - text: 'column 1.3', - cls: 'dot-e-font', + text: "column 1.3", + cls: "dot-e-font", value: 23, }, { - text: 'column 1.4', - cls: 'dot-e-font', + text: "column 1.4", + cls: "dot-e-font", value: 24, }, { - text: 'column 1.5', - cls: 'dot-e-font', + text: "column 1.5", + cls: "dot-e-font", value: 25, }, ], @@ -603,56 +604,56 @@ export class Face extends Widget { { el: { type: IconTextIconItem.xtype, - text: 'column 2', - iconCls1: 'chart-type-e-font', - cls: 'dot-e-font', + text: "column 2", + iconCls1: "chart-type-e-font", + cls: "dot-e-font", value: 12, }, disabled: true, children: [ { type: IconTextItem.xtype, - cls: 'dot-e-font', + cls: "dot-e-font", height: 25, - text: 'column 2.1', + text: "column 2.1", value: 11, }, - { text: 'column 2.2', value: 12, cls: 'dot-e-font' }, + { text: "column 2.2", value: 12, cls: "dot-e-font" }, ], }, ], [ { - text: 'column 33333333333333333333333333333333', - cls: 'style-set-e-font', + text: "column 33333333333333333333333333333333", + cls: "style-set-e-font", value: 13, }, ], [ { - text: 'column 4', - cls: 'filter-e-font', + text: "column 4", + cls: "filter-e-font", value: 14, }, ], [ { - text: 'column 5', - cls: 'copy-e-font', + text: "column 5", + cls: "copy-e-font", value: 15, }, ], [ { - text: 'column 6', - cls: 'delete-e-font', + text: "column 6", + cls: "delete-e-font", value: 16, }, ], [ { - text: 'column 7', - cls: 'dimension-from-e-font', + text: "column 7", + cls: "dimension-from-e-font", value: 17, disabled: true, }, @@ -670,15 +671,15 @@ export class Face extends Widget { var self = this; return { type: HTapeLayout.xtype, - cls: 'config-item bi-border-bottom', + cls: "config-item bi-border-bottom", height: 40, items: [ - this._createLabel('弹出层蒙版颜色:'), + this._createLabel("弹出层蒙版颜色:"), this._createColorPicker( - function () { + function() { self.maskBackgroundColor = this; }, - function () { + function() { self._runGlobalStyle(); } ), @@ -689,9 +690,9 @@ export class Face extends Widget { items: [ { type: Button.xtype, - text: 'mask测试', + text: "mask测试", handler() { - Msg.alert('弹出层', '弹出层面板'); + Msg.alert("弹出层", "弹出层面板"); }, }, ], @@ -705,7 +706,7 @@ export class Face extends Widget { return { type: VerticalLayout.xtype, items: [ - this._createLabel('--一般配色--'), + this._createLabel("--一般配色--"), this._createButton1BackgroundConfig(), this._createButton2BackgroundConfig(), this._createButton3BackgroundConfig(), @@ -727,7 +728,7 @@ export class Face extends Widget { { el: { type: VerticalLayout.xtype, - cls: 'face-config bi-border-right', + cls: "face-config bi-border-right", items: [this._createBaseConfig(), this._createCommonConfig()], }, }, @@ -742,15 +743,15 @@ export class Face extends Widget { } _setStyle(objects) { - var result = ''; - each(objects, function (cls, object) { - result += cls + '{'; - each(object, function (name, value) { - result += name + ':' + value + ';'; + var result = ""; + each(objects, function(cls, object) { + result += cls + "{"; + each(object, function(name, value) { + result += name + ":" + value + ";"; }); - result += '} '; + result += "} "; }); - StyleLoaders.removeStyle('style').loadStyle('style', result); + StyleLoaders.removeStyle("style").loadStyle("style", result); } _runGlobalStyle() { @@ -776,101 +777,101 @@ export class Face extends Widget { var maskBackgroundColor = this.maskBackgroundColor.getValue(); this._setStyle({ - 'body.bi-background, body .bi-background': { - 'background-color': backgroundColor, + "body.bi-background, body .bi-background": { + "background-color": backgroundColor, color: fontColor, }, - 'body .bi-card': { - 'background-color': cardBackgroundColor, + "body .bi-card": { + "background-color": cardBackgroundColor, color: fontColor, }, - 'body .bi-tips': { + "body .bi-tips": { color: grayFontColor, }, - 'div::-webkit-scrollbar,.scrollbar-layout-main': { - 'background-color': scrollBackgroundColor + '!important', + "div::-webkit-scrollbar,.scrollbar-layout-main": { + "background-color": scrollBackgroundColor + "!important", }, - 'div::-webkit-scrollbar-thumb,.public-scrollbar-face:after': { - 'background-color': scrollThumbColor + '!important', + "div::-webkit-scrollbar-thumb,.public-scrollbar-face:after": { + "background-color": scrollThumbColor + "!important", }, - '.base-disabled': { - color: disabledFontColor + '!important', + ".base-disabled": { + color: disabledFontColor + "!important", }, - '.base-disabled .b-font:before': { - color: disabledFontColor + '!important', + ".base-disabled .b-font:before": { + color: disabledFontColor + "!important", }, - '.list-view-outer': { - 'background-color': popupBackgroundColor + '!important', + ".list-view-outer": { + "background-color": popupBackgroundColor + "!important", }, - '.bi-z-index-mask': { - 'background-color': maskBackgroundColor + '!important', + ".bi-z-index-mask": { + "background-color": maskBackgroundColor + "!important", }, - '.bi-list-item:hover,.bi-list-item-hover:hover,.bi-list-item-active:hover,.bi-list-item-select:hover,.bi-list-item-effect:hover': + ".bi-list-item:hover,.bi-list-item-hover:hover,.bi-list-item-active:hover,.bi-list-item-select:hover,.bi-list-item-effect:hover": { - 'background-color': hoverBackgroundColor + '!important', + "background-color": hoverBackgroundColor + "!important", }, - '.bi-list-item-active:active,.bi-list-item-select:active,.bi-list-item-effect:active': { - 'background-color': activeBackgroundColor + '!important', - color: activeFontColor + '!important', + ".bi-list-item-active:active,.bi-list-item-select:active,.bi-list-item-effect:active": { + "background-color": activeBackgroundColor + "!important", + color: activeFontColor + "!important", }, - '.bi-list-item-active.active,.bi-list-item-select.active,.bi-list-item-effect.active': { - 'background-color': selectBackgroundColor + '!important', - color: selectFontColor + '!important', + ".bi-list-item-active.active,.bi-list-item-select.active,.bi-list-item-effect.active": { + "background-color": selectBackgroundColor + "!important", + color: selectFontColor + "!important", }, - 'body .bi-button.button-common': { - 'background-color': button1BackgroundColor, - 'border-color': button1BackgroundColor, + "body .bi-button.button-common": { + "background-color": button1BackgroundColor, + "border-color": button1BackgroundColor, }, - 'body .bi-button.button-success': { - 'background-color': button2BackgroundColor, - 'border-color': button2BackgroundColor, + "body .bi-button.button-success": { + "background-color": button2BackgroundColor, + "border-color": button2BackgroundColor, }, - 'body .bi-button.button-warning': { - 'background-color': button3BackgroundColor, - 'border-color': button3BackgroundColor, + "body .bi-button.button-warning": { + "background-color": button3BackgroundColor, + "border-color": button3BackgroundColor, }, - 'body .bi-button.button-ignore': { - 'background-color': button4BackgroundColor, + "body .bi-button.button-ignore": { + "background-color": button4BackgroundColor, }, // 以下是分割线颜色 - 'body .bi-border,body .bi-border-top,#wrapper .bi-border-bottom,body .bi-border-left,body .bi-border-right': + "body .bi-border,body .bi-border-top,#wrapper .bi-border-bottom,body .bi-border-left,body .bi-border-right": { - 'border-color': slitColor, + "border-color": slitColor, }, - '.bi-collection-table-cell': { - 'border-right-color': slitColor, - 'border-bottom-color': slitColor, + ".bi-collection-table-cell": { + "border-right-color": slitColor, + "border-bottom-color": slitColor, }, - '.bi-collection-table-cell.first-col': { - 'border-left-color': slitColor, + ".bi-collection-table-cell.first-col": { + "border-left-color": slitColor, }, - '.bi-collection-table-cell.first-row': { - 'border-top-color': slitColor, + ".bi-collection-table-cell.first-row": { + "border-top-color": slitColor, }, }); } mounted() { - this.backgroundColor.setValue(''); - this.fontColor.setValue(''); - this.activeFontColor.setValue(''); - this.selectFontColor.setValue(''); - this.grayFontColor.setValue(''); - this.disabledFontColor.setValue(''); - this.cardBackgroundColor.setValue(''); - this.hoverBackgroundColor.setValue(''); - this.activeBackgroundColor.setValue(''); - this.selectBackgroundColor.setValue(''); - - this.button1BackgroundColor.setValue(''); - this.button2BackgroundColor.setValue(''); - this.button3BackgroundColor.setValue(''); - this.button4BackgroundColor.setValue(''); - this.scrollBackgroundColor.setValue(''); - this.scrollThumbColor.setValue(''); - this.popupBackgroundColor.setValue(''); - this.maskBackgroundColor.setValue(''); - this.slitColor.setValue(''); + this.backgroundColor.setValue(""); + this.fontColor.setValue(""); + this.activeFontColor.setValue(""); + this.selectFontColor.setValue(""); + this.grayFontColor.setValue(""); + this.disabledFontColor.setValue(""); + this.cardBackgroundColor.setValue(""); + this.hoverBackgroundColor.setValue(""); + this.activeBackgroundColor.setValue(""); + this.selectBackgroundColor.setValue(""); + + this.button1BackgroundColor.setValue(""); + this.button2BackgroundColor.setValue(""); + this.button3BackgroundColor.setValue(""); + this.button4BackgroundColor.setValue(""); + this.scrollBackgroundColor.setValue(""); + this.scrollThumbColor.setValue(""); + this.popupBackgroundColor.setValue(""); + this.maskBackgroundColor.setValue(""); + this.slitColor.setValue(""); this._runGlobalStyle(); } } diff --git a/packages/demo/src/main.js b/packages/demo/src/main.js index ecfe5095b..a3f8dcccb 100644 --- a/packages/demo/src/main.js +++ b/packages/demo/src/main.js @@ -1,9 +1,9 @@ -import { shortcut, Widget, BorderLayout } from "@fui/core"; +import { Decorators, Widget, BorderLayout } from "@fui/core"; import { West } from "./west"; import { Center } from "./center"; import { North } from "./north"; -@shortcut() +@Decorators.shortcut() export class Main extends Widget { static xtype = "demo.main"; diff --git a/packages/demo/src/west.js b/packages/demo/src/west.js index 13109b203..f4ad12737 100644 --- a/packages/demo/src/west.js +++ b/packages/demo/src/west.js @@ -1,6 +1,6 @@ import { Widget, - shortcut, + Decorators, VTapeLayout, CenterAdaptLayout, Searcher, @@ -13,7 +13,7 @@ import { } from '@fui/core'; import { demoConfig } from './config'; -@shortcut() +@Decorators.shortcut() export class West extends Widget { static xtype = 'demo.west'; static EVENT_VALUE_CHANGE = 'EVENT_VALUE_CHANGE'; diff --git a/packages/fineui/esm.babel.js b/packages/fineui/esm.babel.js index f6cf3fc75..c73949ee2 100644 --- a/packages/fineui/esm.babel.js +++ b/packages/fineui/esm.babel.js @@ -3,7 +3,7 @@ const modules = ["./core/platform/web/config"]; module.exports = { plugins: [ - function (babel) { + function(babel) { const { types: t } = babel; return { visitor: { diff --git a/packages/fineui/package.json b/packages/fineui/package.json index 4c3b25799..61570fc75 100644 --- a/packages/fineui/package.json +++ b/packages/fineui/package.json @@ -25,7 +25,9 @@ "build:es": "babel src -d dist/lib --config-file ./esm.babel.js", "build:fineui": "webpack --progress --config=webpack/webpack.prod.js", "prepublishToPrivate": "npm run build && node ./lib/prepublish.js", - "publishToPrivate": "npm publish" + "publishToPrivate": "npm publish", + "tsc": "tsc", + "link": "pnpm link --global" }, "files": [ "dist", @@ -54,4 +56,4 @@ "devDependencies": { "cross-env": "^7.0.3" } -} \ No newline at end of file +} diff --git a/packages/fineui/typescript/base/base.ts b/packages/fineui/typescript/base/base.ts index f5aacbfd5..a15f037c5 100644 --- a/packages/fineui/typescript/base/base.ts +++ b/packages/fineui/typescript/base/base.ts @@ -1,9 +1,12 @@ import { LayerController } from "../core/controller/controller.layer"; import { BroadcastController } from "../core/controller/controller.broadcast"; import { StyleLoaderManager } from "../core/loader/loader.style"; +import { BubblesController } from "../core/controller/controller.bubbles"; export const Layers = new LayerController(); +export const Bubbles = new BubblesController(); + export const Broadcasts = new BroadcastController(); export const StyleLoaders = new StyleLoaderManager(); diff --git a/packages/fineui/typescript/case/button/node/node.multilayer.icon.arrow.ts b/packages/fineui/typescript/case/button/node/node.multilayer.icon.arrow.ts new file mode 100644 index 000000000..9010fe6c4 --- /dev/null +++ b/packages/fineui/typescript/case/button/node/node.multilayer.icon.arrow.ts @@ -0,0 +1,9 @@ +import { NodeButton } from '../../../base/single/button/button.node'; + +export declare class MultiLayerIconArrowNode extends NodeButton { + static xtype: string; + + doRedMark(...args: any[]): void; + + unRedMark(...args: any[]): void; +} diff --git a/packages/fineui/typescript/case/button/treeitem/item.multilayer.icon.treeleaf.ts b/packages/fineui/typescript/case/button/treeitem/item.multilayer.icon.treeleaf.ts new file mode 100644 index 000000000..d22cddd8c --- /dev/null +++ b/packages/fineui/typescript/case/button/treeitem/item.multilayer.icon.treeleaf.ts @@ -0,0 +1,17 @@ +import { BasicButton } from '../../../base/single/button/button.basic'; + +export declare class MultiLayerIconTreeLeafItem extends BasicButton { + static xtype: string; + + doRedMark(...args: any[]): void; + + unRedMark(...args: any[]): void; + + doHighLight(...args: any[]): void; + + unHighLight(...args: any[]): void; + + getId(): string; + + getPId(): string; +} diff --git a/packages/fineui/typescript/core/base.ts b/packages/fineui/typescript/core/base.ts index 225b79d5c..8b8b48732 100644 --- a/packages/fineui/typescript/core/base.ts +++ b/packages/fineui/typescript/core/base.ts @@ -403,3 +403,15 @@ export declare function getTime(...args: any[]): number; * @param obj 对象 */ export declare function isPromise(obj: any): obj is Promise; + +export declare function set( + object: TObject, + path: string | string[], + value: any +): TObject; + +export declare function get( + object: TObject, + path: TKey | [TKey] | string | null | undefined, + defaultValue?: any +): TObject[TKey] | any; diff --git a/packages/fineui/typescript/core/controller/controller.bubbles.ts b/packages/fineui/typescript/core/controller/controller.bubbles.ts new file mode 100644 index 000000000..63a2e44bd --- /dev/null +++ b/packages/fineui/typescript/core/controller/controller.bubbles.ts @@ -0,0 +1,14 @@ +import { Controller } from './controller'; + +export declare class BubblesController extends Controller { + + show(name: string, text: string, context: any, opt: any): BubblesController + + hide(name: string): BubblesController + + has(name: string): boolean + + remove(name: string): BubblesController + + removeAll(): BubblesController +} diff --git a/packages/fineui/typescript/core/decorator/decorator.ts b/packages/fineui/typescript/core/decorator/decorator.ts index bc5db42bf..6389f8b68 100644 --- a/packages/fineui/typescript/core/decorator/decorator.ts +++ b/packages/fineui/typescript/core/decorator/decorator.ts @@ -1,10 +1,12 @@ +import { Fix } from "../../fix/fix"; + export type Constructor = new(...args: any[]) => T; /** * 注册widget */ export function shortcut() { - return function decorator(Target: Constructor & {xtype: string}): void { + return function decorator(Target: Constructor & { xtype: string }): void { BI.shortcut(Target.xtype, Target); }; } @@ -13,7 +15,7 @@ export function shortcut() { * 注册provider */ export function provider() { - return function decorator(Target: Constructor & {xtype: string}): void { + return function decorator(Target: Constructor & { xtype: string }): void { BI.provider(Target.xtype, Target); }; } @@ -22,7 +24,10 @@ export function provider() { * 注册model */ export function model() { - return function decorator}>(Target: U): void { + return function decorator + }>(Target: U): void { BI.model(Target.xtype, Target); }; } @@ -32,8 +37,10 @@ export function model() { * @param Model model类 * @param opts 额外条件 */ -export function store(Model: Constructor & {xtype: string}, opts: { props?(this: unknown): { [key: string]: unknown } } = {}) { - return function classDecorator(constructor:U) { +export function store(Model: Constructor & { xtype: string }, opts: { + props?(this: unknown): { [key: string]: unknown } +} = {}) { + return function classDecorator(constructor: U) { return class extends constructor { _store() { const props = opts.props ? opts.props.apply(this) : undefined; @@ -55,7 +62,7 @@ export function mixin() { } = {}; Object.getOwnPropertyNames(Target.prototype).forEach(name => { - if (name === 'constructor') { + if (name === "constructor") { return; } @@ -71,8 +78,8 @@ export function mixin() { * ie8下不能使用 * @param Mixins */ -export function mixins(...Mixins: ({ new (...args: any[]): {} } & { xtype: string })[]) { - return function classDecorator(constructor: U) { +export function mixins(...Mixins: ({ new(...args: any[]): {} } & { xtype: string })[]) { + return function classDecorator(constructor: U) { const mixins: string[] = []; Mixins.forEach(mixin => { @@ -88,26 +95,29 @@ export function mixins(...Mixins: ({ new (...args: any[]): {} } & { xtype: strin /** * Model基类 */ -export class Model} = {}> extends Fix.Model { +export class Model +} = {}> extends Fix.Model { // @ts-ignore this["computed"][key]为空 - model: Pick<{[key in keyof U["types"]]: U["types"][key]}, U["context"][number]> & ReturnType & {[key in keyof this["computed"]]: ReturnType}; + model: Pick<{ [key in keyof U["types"]]: U["types"][key] }, U["context"][number]> & ReturnType & { [key in keyof this["computed"]]: ReturnType }; store: this["actions"]; - state(): {[key: string]: unknown} | {} { + state(): { [key: string]: unknown } | {} { return {}; } context: U["context"]; - actions:{[key: string]: (...args: any[]) => any} | {}; + actions: { [key: string]: (...args: any[]) => any } | {}; childContext: ReadonlyArray)>; // @ts-ignore this["computed"][key]为空 - TYPE: Pick<{[key in keyof this["computed"]]: ReturnType} & {[key in keyof ReturnType]: ReturnType[key]}, this["childContext"][number]>; + TYPE: Pick<{ [key in keyof this["computed"]]: ReturnType } & { [key in keyof ReturnType]: ReturnType[key] }, this["childContext"][number]>; - computed: {[key: string]: () => unknown} | {}; + computed: { [key: string]: () => unknown } | {}; } /* 分享一段很好看的代码 diff --git a/packages/fineui/typescript/core/foundation.ts b/packages/fineui/typescript/core/foundation.ts new file mode 100644 index 000000000..74899e9fc --- /dev/null +++ b/packages/fineui/typescript/core/foundation.ts @@ -0,0 +1,3 @@ +export declare const _global: any; + +export declare const prepares: Function[]; diff --git a/packages/fineui/typescript/core/func/index.ts b/packages/fineui/typescript/core/func/index.ts index 49b6cebc9..a485a1c48 100644 --- a/packages/fineui/typescript/core/func/index.ts +++ b/packages/fineui/typescript/core/func/index.ts @@ -1,5 +1,5 @@ export * from "./array"; export * from "./string"; export * from "./number"; -export * from "./function"; +export * as Func from "./function"; export * from "./date"; diff --git a/packages/fineui/typescript/core/inject.ts b/packages/fineui/typescript/core/inject.ts index cd8001e69..b54d60cf4 100644 --- a/packages/fineui/typescript/core/inject.ts +++ b/packages/fineui/typescript/core/inject.ts @@ -1,3 +1,5 @@ +import { Widget } from "./widget"; + export declare function module(xtype: string, cls: any): void; export declare function constant(xtype: string, cls: T): (() => T); @@ -36,7 +38,4 @@ export declare namespace Services { function getService(type: string, options?: any): any; } - -// export declare function shortcut(xtype: string, cls: any): void - -// export declare function component(xtype: string, cls: any): void +export declare function createWidget(item: any, options?: any, context?: Widget, lazy?: boolean): Widget diff --git a/packages/fineui/typescript/core/var.ts b/packages/fineui/typescript/core/var.ts index d4c4e05fd..d4c8f6077 100644 --- a/packages/fineui/typescript/core/var.ts +++ b/packages/fineui/typescript/core/var.ts @@ -129,6 +129,7 @@ export declare const VerticalAlign: { }; export declare const StartOfWeek: number; export declare const BlankSplitChar: string; +export declare const Events: Record; export declare const setToPix: Function; -export declare const setPixFormat: Function; \ No newline at end of file +export declare const setPixFormat: Function; diff --git a/packages/fineui/typescript/core/wrapper/layout/layout.border.ts b/packages/fineui/typescript/core/wrapper/layout/layout.border.ts new file mode 100644 index 000000000..d65f18a57 --- /dev/null +++ b/packages/fineui/typescript/core/wrapper/layout/layout.border.ts @@ -0,0 +1,5 @@ +import { Layout } from "../layout"; + +export declare class BorderLayout extends Layout { + static xtype: string; +} diff --git a/packages/fineui/typescript/fix/fix.ts b/packages/fineui/typescript/fix/fix.ts index 7f60d7495..2e1019e2e 100644 --- a/packages/fineui/typescript/fix/fix.ts +++ b/packages/fineui/typescript/fix/fix.ts @@ -1,4 +1,4 @@ -declare namespace Fix { +export declare namespace Fix { function define(model: any): any function watch(model: any, expOrFn: string | Function, cb: Function, options: Obj): Function[] diff --git a/packages/fineui/typescript/index.ts b/packages/fineui/typescript/index.ts index edabf6532..25081eece 100644 --- a/packages/fineui/typescript/index.ts +++ b/packages/fineui/typescript/index.ts @@ -1,3 +1,4 @@ +export * from "./core/foundation"; export * from "./core/action/action.show"; export * from "./core/action/action"; export * from "./core/behavior/behavior"; @@ -85,9 +86,11 @@ export { DynamicDateCombo } from "./widget/dynamicdate/dynamicdate.combo"; export { CustomTree } from "./base/tree/customtree"; export { ButtonTree } from "./base/combination/tree.button"; export { IconArrowNode } from "./case/button/node/node.icon.arrow"; +export { MultiLayerIconArrowNode } from "./case/button/node/node.multilayer.icon.arrow"; export { MidTreeLeafItem } from "./case/button/treeitem/item.mid.treeleaf"; export { FirstTreeLeafItem } from "./case/button/treeitem/item.first.treeleaf"; export { LastTreeLeafItem } from "./case/button/treeitem/item.last.treeleaf"; +export { MultiLayerIconTreeLeafItem } from "./case/button/treeitem/item.multilayer.icon.treeleaf"; export { SmallTextEditor } from "./widget/editor/editor.text.small"; export { MultifileEditor } from "./widget/editor/editor.multifile"; export { AbsoluteCenterLayout } from "./core/wrapper/layout/adapt/absolute.center"; @@ -184,13 +187,13 @@ export { Tree, Node } from "./core/utils/tree"; export { TextNode } from "./base/single/button/node/textnode"; export { TextValueCheckComboPopup } from "./case/combo/textvaluecheckcombo/popup.textvaluecheck"; export { ImageButton } from "./base/single/button/buttons/button.image"; -export { History, Router } from "./router/router"; +export { History, Router, RouterWidget, RouterView } from "./router/router"; export { DateTimeCombo } from "./widget/datetime/datetime.combo"; export { FloatHorizontalLayout } from "./core/wrapper/layout/adapt/float.horizontal"; export { AdaptiveLayout } from "./core/wrapper/layout/layout.adaptive"; export { HexColorChooserPopup } from "./case/colorchooser/colorchooser.popup.hex"; export { BlankIconTextItem } from "./base/single/button/listitem/blankicontextitem"; -export { Broadcasts, Layers, StyleLoaders } from "./base/base"; +export { Broadcasts, Layers, StyleLoaders, Bubbles } from "./base/base"; export { BroadcastController } from "./core/controller/controller.broadcast"; export { Pager } from "./base/pager/pager"; export { TimeInterval } from "./widget/timeinterval/timeinterval"; @@ -206,6 +209,6 @@ export { DownListGroupItem } from "./widget/downlist/item.downlistgroup"; export { VerticalStickyLayout } from "./core/wrapper/layout/sticky/sticky.vertical"; export { HorizontalStickyLayout } from "./core/wrapper/layout/sticky/sticky.horizontal"; export { TableLayout } from "./core/wrapper/layout/layout.table"; +export { Collapse } from "./widget/collapse/collapse"; export { Workers } from "./core/worker/workers"; - -import "./fix/fix"; +export { Fix } from "./fix/fix"; diff --git a/packages/fineui/typescript/router/router.ts b/packages/fineui/typescript/router/router.ts index 75fded652..53311c6b1 100644 --- a/packages/fineui/typescript/router/router.ts +++ b/packages/fineui/typescript/router/router.ts @@ -6,13 +6,13 @@ export type RouterMode = "hash" | "history" | "abstract" export type RawLocation = string | Location export type RedirectOption = RawLocation | ((to: Route) => RawLocation) export type NavigationGuardNext = ( - to?: RawLocation | false | void, + to?: RawLocation | false | void ) => void export type NavigationGuard = ( to: Route, from: Route, - next: NavigationGuardNext, + next: NavigationGuardNext ) => any interface _History { @@ -40,13 +40,13 @@ export declare class VueRouter { push( location: RawLocation, onComplete?: Function, - onAbort?: ErrorHandler, + onAbort?: ErrorHandler ): void replace( location: RawLocation, onComplete?: Function, - onAbort?: ErrorHandler, + onAbort?: ErrorHandler ): void go(n: number): void @@ -73,7 +73,7 @@ export declare class VueRouter { resolve( to: RawLocation, current?: Route, - append?: boolean, + append?: boolean ): { location: Location route: Route @@ -141,7 +141,7 @@ interface RouteRecord { beforeEnter?: ( route: Route, redirect: (location: RawLocation) => void, - next: () => void, + next: () => void ) => any; props: | boolean @@ -159,7 +159,7 @@ interface RouteRecordPublic { beforeEnter?: ( route: Route, redirect: (location: RawLocation) => void, - next: () => void, + next: () => void ) => any; props: | boolean @@ -200,6 +200,8 @@ export declare class Router { static $router: VueRouter; + static isSameRoute: (a: Route, b: Route, onlyPath?: boolean) => boolean; + route(route: string, callback: Function): this; route(route: string, name: string, callback?: Function): this; @@ -235,3 +237,11 @@ export declare class History { navigate(fragment: string, options?: { [key: string]: any } | boolean): void; } + +export declare class RouterWidget { + static xtype: string; +} + +export declare class RouterView { + static xtype: string; +}