Skip to content

Commit 0b0d6a5

Browse files
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
1 parent f4c9df7 commit 0b0d6a5

File tree

3 files changed

+33
-20
lines changed

3 files changed

+33
-20
lines changed

src/components/ADempiere/Field/index.vue

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,6 @@
6161
</template>
6262

6363
<script>
64-
import { DEFAULT_SIZE } from '@/utils/ADempiere/references'
6564
import { evalutateTypeField, fieldIsDisplayed } from '@/utils/ADempiere/dictionaryUtils'
6665
import FieldOptions from '@/components/ADempiere/Field/FieldOptions'
6766
Lines changed: 24 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,19 @@
1+
<template>
2+
<el-row class="item-wrapper">
3+
<el-col :span="3">
4+
<i v-if="icon.includes('el-icon')" class="icon sub-el-icon" />
5+
<svg-icon v-else :icon-class="icon" />
6+
</el-col>
7+
<el-col :span="21">
8+
9+
<p class="item-title">{{ title }}</p>
10+
</el-col>
11+
</el-row>
12+
</template>
13+
114
<script>
215
export default {
316
name: 'MenuItem',
4-
functional: true,
517
props: {
618
icon: {
719
type: String,
@@ -11,31 +23,24 @@ export default {
1123
type: String,
1224
default: ''
1325
}
14-
},
15-
render(h, context) {
16-
const { icon, title } = context.props
17-
const vnodes = []
18-
19-
if (icon) {
20-
if (icon.includes('el-icon')) {
21-
vnodes.push(<i class={[icon, 'sub-el-icon']} />)
22-
} else {
23-
vnodes.push(<svg-icon icon-class={icon}/>)
24-
}
25-
}
26-
27-
if (title) {
28-
vnodes.push(<span slot='title'>{(title)}</span>)
29-
}
30-
return vnodes
3126
}
3227
}
3328
</script>
3429

3530
<style scoped>
3631
.sub-el-icon {
37-
color: currentColor;
3832
width: 1em;
3933
height: 1em;
4034
}
35+
36+
.item-wrapper {
37+
white-space: break-spaces;
38+
line-height: 20px;
39+
height: auto;
40+
margin: 18px 23px 18px 0;
41+
}
42+
43+
.item-title {
44+
margin: 0 0 0 7px;
45+
}
4146
</style>

src/styles/sidebar.scss

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,15 @@
6868
width: 100% !important;
6969
}
7070

71+
.el-menu-item {
72+
height: auto !important;
73+
padding: 0;
74+
}
75+
76+
.el-submenu__title {
77+
height: auto !important;
78+
}
79+
7180
// menu hover
7281
.submenu-title-noDropdown,
7382
.el-submenu__title {

0 commit comments

Comments
 (0)