Skip to content

Commit

Permalink
stipple
Browse files Browse the repository at this point in the history
  • Loading branch information
montyvesselinov committed Mar 15, 2024
1 parent 08ef3be commit a28ca59
Show file tree
Hide file tree
Showing 5 changed files with 108 additions and 43 deletions.
3 changes: 1 addition & 2 deletions scripts/stipple_new.jl → scripts/stipple_hello.jl
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import Stipple

@Stipple.vars Name begin
name::Stipple.R{String} = "World!"
name::String = "World!"
end

function ui()
Expand All @@ -10,7 +10,6 @@ function ui()
"Hello "
Stipple.span("", @Stipple.text(:name))
])

Stipple.p([
"What is your name? "
Stipple.input("", placeholder="Type your name", @Stipple.bind(:name))
Expand Down
File renamed without changes.
41 changes: 0 additions & 41 deletions scripts/stipple_newer.jl

This file was deleted.

65 changes: 65 additions & 0 deletions scripts/stipple_row_cell.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
import Stipple
import StippleUI

@Stipple.vars Name begin
name::String = "World!"
end

function ui()
[
Stipple.row([
Stipple.p(class="st-module", "Hello, Stipple long long long long long long long long long long long long long long long long long long long long long long!"),
Stipple.p(class="st-module", "Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
])
Stipple.row([
Stipple.cell(class="st-module", Stipple.p("Hello, Stipple long long long long long long long long long long long long long long long long long long long long long long!")),
Stipple.cell(class="st-module", Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!"))
])
Stipple.row([
Stipple.cell(class="st-module", [
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
]),
Stipple.cell(class="st-module", [
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
])
])
Stipple.row([
Stipple.cell(class="st-module st-col col-2 col-xs-12 col-sm-12 col-md-6 col-lg-6 col-xl-6", [
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
]),
Stipple.cell(class="st-module st-col col-2 col-xs-12 col-sm-12 col-md-6 col-lg-6 col-xl-6", [
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
])
])
Stipple.row([
Stipple.cell(class="st-module st-col col-2 col-xs-5 col-sm-3 col-md-6", [
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
]),
Stipple.cell(class="st-module st-col col-2 col-xs-6 col-sm-8 col-md-6", [
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
])
])
Stipple.row(size=10, [
Stipple.cell(xs=5, sm=3, md=4, lg=1, xl=2,
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
),
Stipple.cell(xs=5, sm=8, md=6, lg=6, xl=6,
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
)
])
Stipple.row([
Stipple.cell(class="st-module", size=2, xs=4, sm=3, md=4, lg=1, xl=2,
StippleUI.textfield(class = "q-my-md", "Who am I?", :input, hint = "Please enter some words")
),
Stipple.cell(class="st-module", size=2, xs=6, sm=8, md=6, lg=6, xl=6,
StippleUI.textfield(class = "q-my-md", "Input", :input, hint = "Please enter some words")
)
])
]
end

Stipple.route("/") do
Stipple.page(Stipple.init(Name), ui()) |> Stipple.html
end

Stipple.up()
42 changes: 42 additions & 0 deletions scripts/stipple_row_cell_simple.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
import Stipple
import StippleUI

@Stipple.vars Name begin
name::String = "World!"
names::Vector{String} = ["World!", "Stipple!"]
end

function ui()
[
Stipple.row([
Stipple.cell(class="st-module", xs=5, sm=4, md=3, lg=2, xl=1,
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
),
Stipple.cell(class="st-module", xs=7, sm=8, md=9, lg=10, xl=11,
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
)
])
Stipple.row([
Stipple.cell(class="st-module", xs=5, sm=4, md=3, lg=2, xl=1,
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
),
Stipple.cell(class="st-module", xs=6, sm=7, md=8, lg=9, xl=10,
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
)
])
Stipple.row([
Stipple.cell(class="st-module", xs=5, sm=4, md=3, lg=2, xl=1,
Stipple.select(name; options=names, class="text-p", style="font-size: 13px;", color="white", bgcolor="bg-grey-8", popupcontentclass="bg-grey-9", label="Dataset:", labelcolor="orange")
),
Stipple.cell(class="st-module", xs=6, sm=7, md=8, lg=9, xl=10,
Stipple.p("Hello, World long long long long long long long long long long long long long long long long long long long long long long long!")
)
])
]
end

Stipple.route("/") do
Stipple.page(Stipple.init(Name), ui()) |> Stipple.html
end

Stipple.up()

0 comments on commit a28ca59

Please sign in to comment.