sidebar working
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
// src/components/handlers/sidebar.rs
|
||||
use ratatui::{
|
||||
widgets::{Block, Borders, List, ListItem},
|
||||
widgets::{Block, List, ListItem},
|
||||
layout::Rect,
|
||||
style::Style,
|
||||
text::Text,
|
||||
@@ -10,8 +10,6 @@ use crate::config::colors::Theme;
|
||||
|
||||
pub fn render_sidebar(f: &mut Frame, area: Rect, theme: &Theme) {
|
||||
let sidebar_block = Block::default()
|
||||
.borders(Borders::RIGHT)
|
||||
.border_style(Style::default().fg(theme.border))
|
||||
.style(Style::default().bg(theme.bg));
|
||||
|
||||
let items = vec![
|
||||
|
||||
@@ -38,8 +38,8 @@ pub fn render_ui(
|
||||
let chunks = Layout::default()
|
||||
.direction(Direction::Horizontal)
|
||||
.constraints([
|
||||
Constraint::Min(10), // Sidebar minimum width
|
||||
Constraint::Fill(1), // Remaining space for form/preview
|
||||
Constraint::Length(16), // Fixed sidebar width
|
||||
Constraint::Fill(1), // Remaining space for form/preview
|
||||
])
|
||||
.split(main_content_area);
|
||||
(Some(chunks[0]), chunks[1])
|
||||
|
||||
Reference in New Issue
Block a user