Skip to content

Commit becefcd

Browse files
committed
⚡ Added right border color to left panel
Signed-off-by: Vildan Safin <[email protected]>
1 parent ab7b1ab commit becefcd

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

theme_kit/models/theme.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -287,6 +287,9 @@ class ThemeLeftPanel(models.Model):
287287
left_panel_hover_item_bg = fields.Char('Hover item Background color', help="Hover item Background color for Left Menu Bar")
288288
left_panel_hover_item_bg_active = fields.Boolean(default=False, help="Hover item Background color for Left Menu Bar")
289289

290+
left_panel_right_border = fields.Char('Right border color', help="Right border color for Left Menu Bar")
291+
left_panel_right_border_active = fields.Boolean(default=False, help="Right border color for Left Menu Bar")
292+
290293
less = fields.Text('less', help='technical computed field', compute='_compute_less')
291294

292295
@api.multi
@@ -417,6 +420,13 @@ def _compute_less(self):
417420
}}
418421
"""
419422
)
423+
if self.left_panel_right_border_active:
424+
code = code + '''#app-sidebar{{
425+
border: 3px solid {theme.left_panel_right_border};
426+
border-top: 0;
427+
border-bottom: 0;
428+
border-left: 0;
429+
}}'''
420430
code = code.format(
421431
theme=r,
422432
)

theme_kit/views/theme.xml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,11 @@
150150
<field name="left_panel_hover_item_bg_active" nolabel="1" class="oe_inline"/>
151151
<field name="left_panel_hover_item_bg" widget="color" attrs="{'readonly':[('left_panel_hover_item_bg_active','=',False)]}" class="oe_inline"/>
152152
</div>
153+
<div>
154+
<label for="left_panel_right_border"/>
155+
<field name="left_panel_right_border_active" nolabel="1" class="oe_inline"/>
156+
<field name="left_panel_right_border" widget="color" attrs="{'readonly':[('left_panel_right_border_active','=',False)]}" class="oe_inline"/>
157+
</div>
153158
</group>
154159
</group>
155160
</sheet>

0 commit comments

Comments
 (0)