Browse Source

无JIRA任务 统一item.mulitselect和item.singleselect.radio 图标和文字的布局行为

es6
zsmj1994 4 years ago
parent
commit
8e213098d4
  1. 11
      src/case/button/item.multiselect.js
  2. 7
      src/case/button/item.singleselect.radio.js

11
src/case/button/item.multiselect.js

@ -11,7 +11,8 @@ BI.MultiSelectItem = BI.inherit(BI.BasicButton, {
logic: {
dynamic: false
},
iconWrapperWidth: 26
textHgap: 5,
textRgap: 0
});
},
_init: function () {
@ -27,8 +28,8 @@ BI.MultiSelectItem = BI.inherit(BI.BasicButton, {
whiteSpace: "nowrap",
textHeight: o.height,
height: o.height,
hgap: o.hgap,
rgap: o.rgap,
hgap: o.textHgap,
rgap: o.textHgap,
text: o.text,
keyword: o.keyword,
value: o.value,
@ -46,7 +47,7 @@ BI.MultiSelectItem = BI.inherit(BI.BasicButton, {
items: BI.LogicFactory.createLogicItemsByDirection("left", {
type: "bi.center_adapt",
items: [this.checkbox],
width: o.iconWrapperWidth
width: 16
}, this.text)
}))));
},
@ -73,4 +74,4 @@ BI.MultiSelectItem = BI.inherit(BI.BasicButton, {
}
});
BI.MultiSelectItem.EVENT_CHANGE = "EVENT_CHANGE";
BI.shortcut("bi.multi_select_item", BI.MultiSelectItem);
BI.shortcut("bi.multi_select_item", BI.MultiSelectItem);

7
src/case/button/item.singleselect.radio.js

@ -10,7 +10,9 @@ BI.SingleSelectRadioItem = BI.inherit(BI.BasicButton, {
logic: {
dynamic: false
},
height: 24
height: 24,
textHgap: 5,
textRgap: 0
});
},
_init: function () {
@ -26,7 +28,8 @@ BI.SingleSelectRadioItem = BI.inherit(BI.BasicButton, {
whiteSpace: "nowrap",
textHeight: o.height,
height: o.height,
hgap: o.hgap,
hgap: o.textHgap,
rgap: o.textHgap,
text: o.text,
keyword: o.keyword,
value: o.value,

Loading…
Cancel
Save