Genie Discord forum

Author AvatarWhiskers 1600X3D
10/28/2023, 12:27:54 PM

I am unable to get the 1st row and it's only showing one row despite declaring two in the UI code....code is shown below and problem shown in pic:

using GenieFramework, Genie.Router, Genie.Renderer.Html
using .Stipple, .StippleUI
using CSV

@genietools

@app begin
    @in ID=IDinput
    @in Name=Nameinput
end

function ui()
    row([
        cell(class = "col-md-12", [
            textfield(class = "q-my-md", "Student ID", :IDinput)
        ])
            textfield(class = "q-my-md", "Student Name", :Nameinput) 
    ])
    row([
        cell(class = "st-module", [
            btn(class="q-my-md", "Enter", color = "primary", @click("granted =! granted"))
        ])   
            btn(class="q-my-md", "Save", color = "primary", @click("granted =! granted"))
    ])
    
end

@page("/", ui)
up()
Author AvatarPere
10/30/2023, 10:29:22 AM

The ui function must return a string or a list of strings. Try enclosing it all in a list like

[
  row(...),
  row(...)
]
Author AvatarWhiskers 1600X3D
10/31/2023, 12:59:45 PM

Also can you show how to position widgets in Stipple UI with an example, when there are two rows declared?