# frozen_string_literal: true
module Widgets
class Main < Container
def initialize(_parent)
super
@sidebar = Widgets::Sidebar.new self
@chat = Widgets::Chat.new self
end
def focus
case props[:focus]
when :sidebar then @sidebar
when :chat then @chat
def props=(_value)
@sidebar.props = props[:sidebar]
@chat.props = props[:chat]
def children
[@sidebar, @chat]