update
parent
6d2e05f1e0
commit
655fca1a14
|
@ -4,6 +4,7 @@ import align from 'dom-align'
|
||||||
import addEventListener from '../_util/Dom/addEventListener'
|
import addEventListener from '../_util/Dom/addEventListener'
|
||||||
import { cloneElement } from '../_util/vnode.js'
|
import { cloneElement } from '../_util/vnode.js'
|
||||||
import isWindow from './isWindow'
|
import isWindow from './isWindow'
|
||||||
|
import isEqual from 'lodash.isequal'
|
||||||
function noop () {
|
function noop () {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -55,7 +56,7 @@ export default {
|
||||||
const props = this.$props
|
const props = this.$props
|
||||||
let reAlign = false
|
let reAlign = false
|
||||||
if (!props.disabled) {
|
if (!props.disabled) {
|
||||||
if (prevProps.disabled || prevProps.align !== props.align) {
|
if (prevProps.disabled || !isEqual(prevProps.align, props.align)) {
|
||||||
reAlign = true
|
reAlign = true
|
||||||
} else {
|
} else {
|
||||||
const lastTarget = prevProps.target()
|
const lastTarget = prevProps.target()
|
||||||
|
|
|
@ -33,10 +33,10 @@ export default {
|
||||||
icon: String,
|
icon: String,
|
||||||
},
|
},
|
||||||
data () {
|
data () {
|
||||||
|
this.isExistSlot = false
|
||||||
|
this.childrenWidth = 0
|
||||||
return {
|
return {
|
||||||
isExistSlot: false,
|
|
||||||
scale: 1,
|
scale: 1,
|
||||||
childrenWidth: 0,
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
|
@ -44,7 +44,7 @@ export default {
|
||||||
const { prefixCls, shape, size, src, icon } = this
|
const { prefixCls, shape, size, src, icon } = this
|
||||||
return {
|
return {
|
||||||
[`${prefixCls}`]: true,
|
[`${prefixCls}`]: true,
|
||||||
[`${prefixCls}-image`]: !!src,
|
[`${prefixCls}-image`]: !!src && this.state.isImgExist,
|
||||||
[`${prefixCls}-icon`]: !!icon,
|
[`${prefixCls}-icon`]: !!icon,
|
||||||
[`${prefixCls}-${shape}`]: true,
|
[`${prefixCls}-${shape}`]: true,
|
||||||
[`${prefixCls}-lg`]: size === 'large',
|
[`${prefixCls}-lg`]: size === 'large',
|
||||||
|
|
|
@ -24,6 +24,7 @@
|
||||||
text-align: center;
|
text-align: center;
|
||||||
padding: 0 6px;
|
padding: 0 6px;
|
||||||
font-size: @badge-font-size;
|
font-size: @badge-font-size;
|
||||||
|
font-weight: @badge-font-weight;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
transform-origin: -10% center;
|
transform-origin: -10% center;
|
||||||
box-shadow: 0 0 0 1px #fff;
|
box-shadow: 0 0 0 1px #fff;
|
||||||
|
|
|
@ -108,7 +108,6 @@
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
> .@{btnClassName} {
|
> .@{btnClassName} {
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 1;
|
|
||||||
|
|
||||||
&:hover,
|
&:hover,
|
||||||
&:focus,
|
&:focus,
|
||||||
|
@ -242,6 +241,8 @@
|
||||||
|
|
||||||
.@{btnClassName} + .@{btnClassName},
|
.@{btnClassName} + .@{btnClassName},
|
||||||
.@{btnClassName} + &,
|
.@{btnClassName} + &,
|
||||||
|
span + .@{btnClassName},
|
||||||
|
.@{btnClassName} + span,
|
||||||
& + .@{btnClassName},
|
& + .@{btnClassName},
|
||||||
& + & {
|
& + & {
|
||||||
margin-left: -1px;
|
margin-left: -1px;
|
||||||
|
@ -251,15 +252,19 @@
|
||||||
border-radius: 0;
|
border-radius: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
> .@{btnClassName}:first-child {
|
> .@{btnClassName}:first-child,
|
||||||
|
> span:first-child > .@{btnClassName} {
|
||||||
margin-left: 0;
|
margin-left: 0;
|
||||||
&:not(:last-child) {
|
}
|
||||||
|
|
||||||
|
> .@{btnClassName}:first-child:not(:last-child),
|
||||||
|
> span:first-child:not(:last-child) > .@{btnClassName} {
|
||||||
border-bottom-right-radius: 0;
|
border-bottom-right-radius: 0;
|
||||||
border-top-right-radius: 0;
|
border-top-right-radius: 0;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
> .@{btnClassName}:last-child:not(:first-child) {
|
> .@{btnClassName}:last-child:not(:first-child),
|
||||||
|
> span:last-child:not(:first-child) > .@{btnClassName} {
|
||||||
border-bottom-left-radius: 0;
|
border-bottom-left-radius: 0;
|
||||||
border-top-left-radius: 0;
|
border-top-left-radius: 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -54,6 +54,7 @@
|
||||||
|
|
||||||
&-submenu-popup {
|
&-submenu-popup {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
|
z-index: @zindex-dropdown;
|
||||||
}
|
}
|
||||||
|
|
||||||
&-item,
|
&-item,
|
||||||
|
|
|
@ -328,3 +328,13 @@
|
||||||
.@{iconfont-css-prefix}-alipay:before { content: "\e9b3"; }
|
.@{iconfont-css-prefix}-alipay:before { content: "\e9b3"; }
|
||||||
.@{iconfont-css-prefix}-ant-design:before { content: "\e9b2"; }
|
.@{iconfont-css-prefix}-ant-design:before { content: "\e9b2"; }
|
||||||
.@{iconfont-css-prefix}-aliyun:before { content: "\e9f4"; }
|
.@{iconfont-css-prefix}-aliyun:before { content: "\e9f4"; }
|
||||||
|
.@{iconfont-css-prefix}-zhihu:before { content: "\e703"; }
|
||||||
|
.@{iconfont-css-prefix}-file-markdown:before { content: "\e704"; }
|
||||||
|
.@{iconfont-css-prefix}-slack:before { content: "\e705"; }
|
||||||
|
.@{iconfont-css-prefix}-slack-square:before { content: "\e706"; }
|
||||||
|
.@{iconfont-css-prefix}-behance:before { content: "\e707"; }
|
||||||
|
.@{iconfont-css-prefix}-behance-square:before { content: "\e708"; }
|
||||||
|
.@{iconfont-css-prefix}-dribbble:before { content: "\e709"; }
|
||||||
|
.@{iconfont-css-prefix}-dribbble-square:before { content: "\e70a"; }
|
||||||
|
.@{iconfont-css-prefix}-instagram:before { content: "\e70b"; }
|
||||||
|
.@{iconfont-css-prefix}-yuque:before { content: "\e70c"; }
|
||||||
|
|
|
@ -67,7 +67,7 @@
|
||||||
|
|
||||||
// ICONFONT
|
// ICONFONT
|
||||||
@iconfont-css-prefix : anticon;
|
@iconfont-css-prefix : anticon;
|
||||||
@icon-url : "https://at.alicdn.com/t/font_148784_dky7e838xq4obt9";
|
@icon-url : "https://at.alicdn.com/t/font_148784_v4ggb6wrjmkotj4i";
|
||||||
|
|
||||||
// LINK
|
// LINK
|
||||||
@link-color : @primary-color;
|
@link-color : @primary-color;
|
||||||
|
@ -362,6 +362,7 @@
|
||||||
@badge-height: 20px;
|
@badge-height: 20px;
|
||||||
@badge-dot-size: 6px;
|
@badge-dot-size: 6px;
|
||||||
@badge-font-size: @font-size-sm;
|
@badge-font-size: @font-size-sm;
|
||||||
|
@badge-font-weight: normal;
|
||||||
@badge-status-size: 6px;
|
@badge-status-size: 6px;
|
||||||
|
|
||||||
// Rate
|
// Rate
|
||||||
|
@ -426,6 +427,7 @@
|
||||||
// ---
|
// ---
|
||||||
@pagination-item-size: 32px;
|
@pagination-item-size: 32px;
|
||||||
@pagination-item-size-sm: 24px;
|
@pagination-item-size-sm: 24px;
|
||||||
|
@pagination-font-family: Arial;
|
||||||
|
|
||||||
// Breadcrumb
|
// Breadcrumb
|
||||||
// ---
|
// ---
|
||||||
|
|
|
@ -167,7 +167,6 @@ export default {
|
||||||
key='popup'
|
key='popup'
|
||||||
ref='alignInstance'
|
ref='alignInstance'
|
||||||
monitorWindowResize
|
monitorWindowResize
|
||||||
disabled={!visible}
|
|
||||||
align={align}
|
align={align}
|
||||||
onAlign={this.onAlign}
|
onAlign={this.onAlign}
|
||||||
>
|
>
|
||||||
|
|
|
@ -166,6 +166,12 @@ export default {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
updateLabelAndTitleMap () {
|
||||||
|
const labelMap = {}
|
||||||
|
const titleMap = {}
|
||||||
|
this.labelMap = labelMap
|
||||||
|
this.titleMap = titleMap
|
||||||
|
},
|
||||||
updateState () {
|
updateState () {
|
||||||
const { combobox, $slots } = this
|
const { combobox, $slots } = this
|
||||||
let value = toArray(this.value)
|
let value = toArray(this.value)
|
||||||
|
|
|
@ -104,6 +104,7 @@
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|
||||||
.@{selectPrefixCls}-selection-selected-value {
|
.@{selectPrefixCls}-selection-selected-value {
|
||||||
|
pointer-events: none;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: 0;
|
left: 0;
|
||||||
top: 0;
|
top: 0;
|
||||||
|
|
Loading…
Reference in New Issue