mirror of
https://github.com/PanJiaChen/vue-element-admin.git
synced 2025-08-10 12:01:57 +08:00
Inserted line breaks in side menu (#915)
* changed hover styling of card * improved styling of menu cards * other minor styling improvements in cards layout * Fields always have same size * style fix active-inactive text in yes-no-field * moved popover to own component * refactored labelPopover * added info icon to label * truncated placeholder * bugfix - added missing method back in * set resizable in textareas to false * style fix for context info * fixes due to merge form develop * reverted padding for context info box * inserted line breaks in side menu
This commit is contained in:
parent
f4c9df712e
commit
0b0d6a5f00
@ -61,7 +61,6 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { DEFAULT_SIZE } from '@/utils/ADempiere/references'
|
|
||||||
import { evalutateTypeField, fieldIsDisplayed } from '@/utils/ADempiere/dictionaryUtils'
|
import { evalutateTypeField, fieldIsDisplayed } from '@/utils/ADempiere/dictionaryUtils'
|
||||||
import FieldOptions from '@/components/ADempiere/Field/FieldOptions'
|
import FieldOptions from '@/components/ADempiere/Field/FieldOptions'
|
||||||
|
|
||||||
|
@ -1,7 +1,19 @@
|
|||||||
|
<template>
|
||||||
|
<el-row class="item-wrapper">
|
||||||
|
<el-col :span="3">
|
||||||
|
<i v-if="icon.includes('el-icon')" class="icon sub-el-icon" />
|
||||||
|
<svg-icon v-else :icon-class="icon" />
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="21">
|
||||||
|
|
||||||
|
<p class="item-title">{{ title }}</p>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: 'MenuItem',
|
name: 'MenuItem',
|
||||||
functional: true,
|
|
||||||
props: {
|
props: {
|
||||||
icon: {
|
icon: {
|
||||||
type: String,
|
type: String,
|
||||||
@ -11,31 +23,24 @@ export default {
|
|||||||
type: String,
|
type: String,
|
||||||
default: ''
|
default: ''
|
||||||
}
|
}
|
||||||
},
|
|
||||||
render(h, context) {
|
|
||||||
const { icon, title } = context.props
|
|
||||||
const vnodes = []
|
|
||||||
|
|
||||||
if (icon) {
|
|
||||||
if (icon.includes('el-icon')) {
|
|
||||||
vnodes.push(<i class={[icon, 'sub-el-icon']} />)
|
|
||||||
} else {
|
|
||||||
vnodes.push(<svg-icon icon-class={icon}/>)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (title) {
|
|
||||||
vnodes.push(<span slot='title'>{(title)}</span>)
|
|
||||||
}
|
|
||||||
return vnodes
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.sub-el-icon {
|
.sub-el-icon {
|
||||||
color: currentColor;
|
|
||||||
width: 1em;
|
width: 1em;
|
||||||
height: 1em;
|
height: 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.item-wrapper {
|
||||||
|
white-space: break-spaces;
|
||||||
|
line-height: 20px;
|
||||||
|
height: auto;
|
||||||
|
margin: 18px 23px 18px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.item-title {
|
||||||
|
margin: 0 0 0 7px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
@ -68,6 +68,15 @@
|
|||||||
width: 100% !important;
|
width: 100% !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.el-menu-item {
|
||||||
|
height: auto !important;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.el-submenu__title {
|
||||||
|
height: auto !important;
|
||||||
|
}
|
||||||
|
|
||||||
// menu hover
|
// menu hover
|
||||||
.submenu-title-noDropdown,
|
.submenu-title-noDropdown,
|
||||||
.el-submenu__title {
|
.el-submenu__title {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user