#
# Copyright (c) Daniel Sheffield 2023
#
# All rights reserved
#
# THIS SOFTWARE IS PROVIDED AS IS WITHOUT WARRANTY
from urwid import AttrMap, Padding, Pile, Text, AttrMap
from .. import COPYRIGHT

def banner(title: str) -> AttrMap:
    header = Text(title, 'center')
    _copyright = Text(COPYRIGHT, 'center')
    return AttrMap(Pile([
            Padding(header, 'center', width=('relative', 100)),
            Padding(_copyright, 'center', width=('relative', 100)),
        ]), 'banner')
