diff --git a/src/components/menu/submenu.vue b/src/components/menu/submenu.vue
index b723f1f0..e4e5ae10 100644
--- a/src/components/menu/submenu.vue
+++ b/src/components/menu/submenu.vue
@@ -2,7 +2,7 @@
-
+
@@ -75,6 +75,41 @@
return this.hasParentSubmenu && this.mode !== 'horizontal' ? {
paddingLeft: 43 + (this.parentSubmenuNum - 1) * 24 + 'px'
} : {};
+ },
+ // 3.4.0, global setting customArrow 有值时,arrow 赋值空
+ arrowType () {
+ let type = 'ios-arrow-down';
+
+ if (this.$IVIEW) {
+ if (this.$IVIEW.menu.customArrow) {
+ type = '';
+ } else if (this.$IVIEW.menu.arrow) {
+ type = this.$IVIEW.menu.arrow;
+ }
+ }
+ return type;
+ },
+ // 3.4.0, global setting
+ customArrowType () {
+ let type = '';
+
+ if (this.$IVIEW) {
+ if (this.$IVIEW.menu.customArrow) {
+ type = this.$IVIEW.menu.customArrow;
+ }
+ }
+ return type;
+ },
+ // 3.4.0, global setting
+ arrowSize () {
+ let size = '';
+
+ if (this.$IVIEW) {
+ if (this.$IVIEW.menu.arrowSize) {
+ size = this.$IVIEW.menu.arrowSize;
+ }
+ }
+ return size;
}
},
methods: {
diff --git a/src/index.js b/src/index.js
index 21d2c753..34fd5d97 100644
--- a/src/index.js
+++ b/src/index.js
@@ -178,6 +178,11 @@ const install = function(Vue, opts = {}) {
arrow: opts.cell ? opts.cell.arrow ? opts.cell.arrow : '' : '',
customArrow: opts.cell ? opts.cell.customArrow ? opts.cell.customArrow : '' : '',
arrowSize: opts.cell ? opts.cell.arrowSize ? opts.cell.arrowSize : '' : ''
+ },
+ menu: {
+ arrow: opts.menu ? opts.menu.arrow ? opts.menu.arrow : '' : '',
+ customArrow: opts.menu ? opts.menu.customArrow ? opts.menu.customArrow : '' : '',
+ arrowSize: opts.menu ? opts.menu.arrowSize ? opts.menu.arrowSize : '' : ''
}
};
diff --git a/src/styles/components/menu.less b/src/styles/components/menu.less
index a9377390..bd5d2dd7 100644
--- a/src/styles/components/menu.less
+++ b/src/styles/components/menu.less
@@ -160,16 +160,24 @@
}
&-vertical &-submenu-title-icon{
- float: right;
- position: relative;
- top: 4px;
+ // #5592 支持自定义图标 size 后,换一种位置
+ //float: right;
+ //position: relative;
+ //top: 4px;
+ position: absolute;
+ top: 50%;
+ right: 24px;
+ transform: translateY(-50%);
}
&-submenu-title-icon {
transition: transform @transition-time @ease-in-out;
}
- &-opened > * > &-submenu-title-icon{
+ &-horizontal &-opened > * > &-submenu-title-icon{
transform: rotate(180deg);
}
+ &-vertical &-opened > * > &-submenu-title-icon{
+ transform: translateY(-50%) rotate(180deg);
+ }
&-vertical &-submenu{
&-nested{