Browse Source

Merge pull request #162375 in DEC/fineui from master to feature/x

* commit '4a64d0de80bf7351451785960b9ecfb77c93f1cf':
  auto upgrade version to 2.0.20220904090710
  bugfix: bug
  auto upgrade version to 2.0.20220903090829
  BI-112711 fix:单选按钮的选中视觉不对
master
superman 2 years ago
parent
commit
e64421a7cf
  1. 2
      package.json
  2. 8
      src/base/single/input/radio/radio.js
  3. 6
      src/less/base/single/input/radio.less
  4. 30
      src/widget/downlist/item.downlistgroup.js

2
package.json

@ -1,6 +1,6 @@
{ {
"name": "fineui", "name": "fineui",
"version": "2.0.20220902101333", "version": "2.0.20220904090710",
"description": "fineui", "description": "fineui",
"main": "dist/fineui_without_conflict.min.js", "main": "dist/fineui_without_conflict.min.js",
"types": "dist/lib/index.d.ts", "types": "dist/lib/index.d.ts",

8
src/base/single/input/radio/radio.js

@ -9,10 +9,10 @@ BI.Radio = BI.inherit(BI.BasicButton, {
baseCls: "bi-radio", baseCls: "bi-radio",
selected: false, selected: false,
handler: BI.emptyFn, handler: BI.emptyFn,
width: 14, width: 16,
height: 14, height: 16,
iconWidth: 14, iconWidth: 16,
iconHeight: 14, iconHeight: 16,
}, },
render: function () { render: function () {

6
src/less/base/single/input/radio.less

@ -18,13 +18,13 @@
border-color: @color-bi-border-hover-active-radio; border-color: @color-bi-border-hover-active-radio;
background-color: @color-bi-background-active-radio; background-color: @color-bi-background-active-radio;
&:after { &:after {
width: 6px; width: 8px;
height: 6px; height: 8px;
display: table; display: table;
position: absolute; position: absolute;
top: 50%; top: 50%;
left: 50%; left: 50%;
.border-radius(3px); .border-radius(4px);
background-color: @color-bi-background-active-radio-content; background-color: @color-bi-background-active-radio-content;
.transform(translate(-50%, -50%)); .transform(translate(-50%, -50%));
@transition: all .1s cubic-bezier(.71,-.46,.88,.6),opacity .1s; @transition: all .1s cubic-bezier(.71,-.46,.88,.6),opacity .1s;

30
src/widget/downlist/item.downlistgroup.js

@ -12,8 +12,7 @@ BI.DownListGroupItem = BI.inherit(BI.BasicButton, {
iconCls2: "pull-right-e-font" iconCls2: "pull-right-e-font"
}); });
}, },
_init: function () { render: function () {
BI.DownListGroupItem.superclass._init.apply(this, arguments);
var o = this.options; var o = this.options;
var self = this; var self = this;
this.text = BI.createWidget({ this.text = BI.createWidget({
@ -52,27 +51,6 @@ BI.DownListGroupItem = BI.inherit(BI.BasicButton, {
forceNotSelected: true forceNotSelected: true
}); });
var blank = BI.createWidget({
type: "bi.layout",
width: 24
});
BI.createWidget({
type: "bi.absolute",
element: this,
items: [{
el: this.icon2,
top: 0,
bottom: 0,
right: 0
}]
});
BI.createWidget(BI.extend({
element: this
}, BI.LogicFactory.createLogic("horizontal", BI.extend(o.logic, {
items: BI.LogicFactory.createLogicItemsByDirection("left", this.icon1, this.text, blank)
}))));
this.element.hover(function () { this.element.hover(function () {
if (self.isEnabled()) { if (self.isEnabled()) {
self.hover(); self.hover();
@ -82,6 +60,12 @@ BI.DownListGroupItem = BI.inherit(BI.BasicButton, {
self.dishover(); self.dishover();
} }
}); });
return {
type: "bi.horizontal_fill",
columnSize: [36, "fill", 24],
items: [this.icon1, this.text, this.icon2]
}
}, },
_getLevel: function () { _getLevel: function () {

Loading…
Cancel
Save