-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- Loading branch information
Showing
15 changed files
with
285 additions
and
76 deletions.
There are no files selected for viewing
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
<.flash_group flash={@flash} /> | ||
<%= @inner_content %> |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<.csrf_token /> | ||
<Style url={~p"/assets/app.swiftui.styles"} /> | ||
<NavigationStack> | ||
<%= @inner_content %> | ||
</NavigationStack> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
defmodule Bonfire.UI.Common.Themes.Default.App.SwiftUI do | ||
use LiveViewNative.Stylesheet, :swiftui | ||
|
||
# Add your styles here | ||
# Refer to your client's documentation on what the proper syntax | ||
# is for defining rules within classes | ||
~SHEET""" | ||
""" | ||
|
||
def class("main_header") do | ||
~RULES""" | ||
toolbar(content: :toolbar) | ||
navigationTitle(:title) | ||
toolbarTitleMenu(content: :content) | ||
navigationBarTitleDisplayMode(.inline) | ||
toolbarBackgroundVisibility(.visible, for: .navigationBar) | ||
toolbarBackground(.ultraThinMaterial, for: .navigationBar) | ||
""" | ||
end | ||
|
||
def class("simple_header") do | ||
~RULES""" | ||
toolbar(content: :toolbar) | ||
navigationTitle(:title) | ||
navigationBarTitleDisplayMode(.inline) | ||
""" | ||
end | ||
|
||
def class("detents:" <> props) do | ||
[height, size] = String.split(props, ":") | ||
|
||
# {height, _} = Integer.parse(height) | ||
|
||
~RULES""" | ||
presentationDetents([.{height}, .{size}]) | ||
""" | ||
end | ||
|
||
def class("dragindicator:" <> props) do | ||
|
||
~RULES""" | ||
presentationDragIndicator(.{props}) | ||
""" | ||
end | ||
|
||
|
||
def class("ultrathinmaterial") do | ||
~RULES""" | ||
presentationBackground(.ultraThinMaterial) | ||
""" | ||
end | ||
|
||
# If you need to have greater control over how your style rules are created | ||
# you can use the function defintion style which is more verbose but allows | ||
# for more fine-grained controled | ||
# | ||
# This example shows what is not possible within the more concise ~SHEET | ||
# use `<Text class="frame:w100:h200" />` allows for a setting | ||
# of both the `width` and `height` values. | ||
|
||
# def class("frame:" <> dims) do | ||
# [width] = Regex.run(~r/w(\d+)/, dims, capture: :all_but_first) | ||
# [height] = Regex.run(~r/h(\d+)/, dims, capture: :all_but_first) | ||
|
||
# ~RULES""" | ||
# frame(width: {width}, height: {height}) | ||
# """ | ||
# end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.