forked from fanruan/fineui
Browse Source
* commit 'b010bcf71058be72390b423557e6a18fbf6d5786': KERNEL-14215 fix:index.html配置的BI.pixUnit和BI.pixRatio失效-bug48 KERNEL-14124 fix: 打包fineui.min.js需要吧_和$挂载到全局 KERNEL-14215 fix:bi.editor组件errorText无法更新-bug46 KERNEL-14215 fix:bi.card组件切换时tab消失-bug43 KERNEL-14215 fix:bi.search_text_value_combo下拉无法展示和搜索mask无法展示的问题-bug20 KERNEL-14215 fix:bi.text_value_check_combo无法显示-bug21 KERNEL-14222 fix: 无法弹出bubble KERNEL-14215 fix:bi.icon_arrow_node组件文本消失的问题-bug26 KERNEL-14222 fix: virtual_group 刷新按钮失效 KERNEL-14215 fix:bi.time_interval无法显示-bug37 KERNEL-14215 fix:bi.year_interval组件下拉框无法显示-bug40 KERNEL-14215 fix:slider滑块左侧大于右侧无法交换的问题-bug42 KERNEL-14124 refactor: 优化优化 KERNEL-14124 fix: 解决报错,调整打包 KERNEL-14124 fix: import错的 KERNEL-14124 fix: 再梳理一遍去脚本难去掉的BI.以及eslint标红 KERNEL-14124 chore: 调整tsconfig解决tsc时的报错es6
Dailer-刘荣歆
2 years ago
181 changed files with 2986 additions and 2763 deletions
@ -1,38 +1,131 @@
|
||||
import { shortcut, extend } from "@/core"; |
||||
import { shortcut, extend, i18nText, each, isWidget, createWidget } from "@/core"; |
||||
import { PopupView } from "@/base/layer/layer.popup"; |
||||
import { Button } from "@/base"; |
||||
import { Label } from "@/base/single/label/label"; |
||||
|
||||
|
||||
@shortcut() |
||||
export class BubblePopupView extends PopupView { |
||||
static xtype = "bi.text_bubble_bar_popup_view"; |
||||
static xtype = "bi.bubble_popup_view"; |
||||
|
||||
static EVENT_CLICK_TOOLBAR_BUTTON = "EVENT_CLICK_TOOLBAR_BUTTON"; |
||||
static EVENT_CHANGE = "EVENT_CLICK_TOOLBAR_BUTTON"; |
||||
|
||||
_defaultConfig() { |
||||
const config = super._defaultConfig(...arguments); |
||||
|
||||
return extend(config, { |
||||
baseCls: `${config.baseCls} bi-bubble-popup-view`, |
||||
minWidth: 70, |
||||
maxWidth: 300, |
||||
// minHeight: 50,
|
||||
showArrow: true, |
||||
}); |
||||
} |
||||
} |
||||
|
||||
@shortcut() |
||||
export class BubblePopupBarView extends BubblePopupView { |
||||
static xtype = "bi.bubble_bar_popup_view"; |
||||
|
||||
static EVENT_CLICK_TOOLBAR_BUTTON = "EVENT_CLICK_TOOLBAR_BUTTON"; |
||||
|
||||
_defaultConfig () { |
||||
return extend(super._defaultConfig(...arguments), { |
||||
extraCls: "bi-bubble-bar-popup-view", |
||||
buttons: [{ |
||||
value: false, |
||||
text: i18nText("BI-Basic_Cancel"), |
||||
level: "ignore", |
||||
}, { |
||||
text: i18nText(i18nText("BI-Basic_OK")), |
||||
value: true, |
||||
}], |
||||
innerVgap: 16, |
||||
innerHgap: 16, |
||||
}); |
||||
} |
||||
|
||||
_createToolBar () { |
||||
const o = this.options; |
||||
|
||||
const items = []; |
||||
each(o.buttons, (i, buttonOpt) => { |
||||
if (isWidget(buttonOpt)) { |
||||
items.push({ |
||||
el: buttonOpt, |
||||
lgap: 12, |
||||
}); |
||||
} else { |
||||
items.push({ |
||||
el: extend({ |
||||
type: Button.xtype, |
||||
height: 24, |
||||
handler: v => { |
||||
this.fireEvent(BubblePopupBarView.EVENT_CLICK_TOOLBAR_BUTTON, v); |
||||
}, |
||||
}, buttonOpt), |
||||
lgap: 12, |
||||
}); |
||||
} |
||||
}); |
||||
|
||||
return createWidget({ |
||||
type: "bi.right_vertical_adapt", |
||||
innerVgap: o.innerVgap, |
||||
innerHgap: o.innerHgap, |
||||
items, |
||||
}); |
||||
} |
||||
|
||||
_createContent () { |
||||
return this.options.el; |
||||
} |
||||
|
||||
_createView () { |
||||
const o = this.options; |
||||
|
||||
const view = createWidget({ |
||||
type: "bi.vertical", |
||||
items: [this._createContent()], |
||||
cls: "bar-popup-container", |
||||
hgap: o.innerHgap, |
||||
tgap: o.innerVgap, |
||||
}); |
||||
|
||||
view.element.css("min-height", o.minHeight); |
||||
|
||||
return view; |
||||
} |
||||
} |
||||
|
||||
@shortcut() |
||||
export class TextBubblePopupBarView extends BubblePopupBarView { |
||||
static xtype = "bi.text_bubble_bar_popup_view"; |
||||
|
||||
static EVENT_CHANGE = "EVENT_CLICK_TOOLBAR_BUTTON"; |
||||
|
||||
_defaultConfig () { |
||||
const config = super._defaultConfig(...arguments); |
||||
|
||||
return extend(config, { |
||||
baseCls: `${config.baseCls} bi-text-bubble-bar-popup-view`, |
||||
text: "", |
||||
}); |
||||
} |
||||
|
||||
_createContent() { |
||||
_createContent () { |
||||
const o = this.options; |
||||
|
||||
|
||||
return { |
||||
type: Label.xtype, |
||||
text: o.text, |
||||
whiteSpace: "normal", |
||||
textAlign: "left", |
||||
ref: (_ref) => { |
||||
ref: _ref => { |
||||
this.text = _ref; |
||||
}, |
||||
}; |
||||
} |
||||
|
||||
populate(v) { |
||||
populate (v) { |
||||
this.text.setText(v || this.options.text); |
||||
} |
||||
} |
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue