v1.0.1
修复Windows下的样式错误
This commit is contained in:
parent
5b84e95638
commit
342217669b
@ -5,6 +5,8 @@
|
||||
|
||||
前身`formSelectes`, 移除了对`jquery`的依赖, 提高渲染速度
|
||||
|
||||
[演示站点](https://maplemei.gitee.io/xm-select/)
|
||||
|
||||
> 历史版本
|
||||
|
||||
[formSelectes](https://github.com/hnzzmsf/layui-formSelects)
|
||||
|
2
dist/xm-select.js
vendored
2
dist/xm-select.js
vendored
File diff suppressed because one or more lines are too long
@ -60,10 +60,8 @@ export function watch(data) {
|
||||
|
||||
export function checkUserAgent(){
|
||||
const ua = navigator.userAgent;
|
||||
if(ua.indexOf('Mac OS')){
|
||||
if(ua.indexOf('Mac OS') != -1){
|
||||
return 'mac';
|
||||
}
|
||||
|
||||
|
||||
return 'win';
|
||||
}
|
@ -181,11 +181,13 @@ class General extends Component{
|
||||
arr = arr.map(item => {
|
||||
|
||||
const selected = !!sels.find(sel => sel[value] == item[value])
|
||||
const iconStyle = {
|
||||
color: selected ? theme.color : '',
|
||||
const iconStyle = selected ? {
|
||||
color: theme.color,
|
||||
border: 'none',
|
||||
fontSize: '18px'
|
||||
} : {
|
||||
borderColor: theme.color,
|
||||
}
|
||||
// const className = 'xm-option' + (item.disabled ? ' disabled' : '');
|
||||
};
|
||||
const className = ['xm-option', (item[disabled] ? ' disabled' : ''), (selected ? ' selected' : '')].join(' ');
|
||||
|
||||
return (
|
||||
|
@ -188,14 +188,11 @@ xm-select{
|
||||
color: #FFF;
|
||||
display: flex;
|
||||
border: @border;
|
||||
border-radius: 5px;
|
||||
&:before{
|
||||
height: 18px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-top: -1px;
|
||||
margin-bottom: -1px;
|
||||
}
|
||||
border-radius: 3px;
|
||||
height: 18px;
|
||||
width: 18px;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
&-content{
|
||||
@ -332,9 +329,9 @@ xm-select{
|
||||
|
||||
}
|
||||
|
||||
xm-select[ua='win']{
|
||||
.xm-option-icon{
|
||||
margin-top: 0px;
|
||||
margin-bottom: -2px;
|
||||
}
|
||||
}
|
||||
// xm-select[ua='win']{
|
||||
// .xm-option-icon{
|
||||
// margin-top: 0px;
|
||||
// margin-bottom: -2px;
|
||||
// }
|
||||
// }
|
Loading…
Reference in New Issue
Block a user