Skip to content
Discussion options

You must be logged in to vote

You can use the align parameter of the flexible layout zones. Here's an example:



@app('/')
async def serve(q: Q):
    q.page['meta'] = ui.meta_card(
        box='',
        layouts=[
            ui.layout(
                breakpoint='xs',
                width='1200px',
                zones=[
                    ui.zone('header'),
                    ui.zone('body', align='center'),
                    ui.zone('footer'),
                ]
            )
        ]
    )
    q.page['header'] = ui.header_card(
        box='header',
        title='Center Form Card',
        subtitle='Learning application',
    )
    q.page['body'] = ui.form_card(
        box=ui.box('body', width='50%'),
  …

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@mtanco
Comment options

mtanco May 20, 2021
Collaborator

@5675sp
Comment options

Answer selected by vopani
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Ideas
Labels
None yet
2 participants