Commit Graph

12 Commits

Author SHA1 Message Date
Jed Fox f0e2b054dc
Add Toggle implementation (#159)
* Fix Button.body

* Add support for renderers customizing default environment values

* Add ParentView conformances

* Add Toggle

* long lines

* Update Path.swift

* Update Path.swift

* Update Sources/TokamakDOM/DOMRenderer.swift

Co-authored-by: Max Desiatov <max@desiatov.com>

* bodyBuild → bodyClosure

* Update progress.md

* Update progress.md, implement Toggle(_ configuration: ToggleStyleConfiguration)

* Fix demo on native

* Hopefully fix issue

* Hopefully fix issue for real

* maybe this will work

* Update ToggleDemo.swift

* AnyToggleStyle → _AnyToggleStyle

* Fix remaining AnyToggleStyle

* Clean up unnecessary files

* Move typealias to Core.swift

* Revert change to ListDemo, remove unused let

Co-authored-by: Max Desiatov <max@desiatov.com>
2020-07-20 18:21:32 -04:00
Max Desiatov b495a2447d
Add `Picker` and `PopUpButtonPickerStyle` as default (#149)
The rest of the styles will be implemented as separate PRs.

Additionally, `LazyHGrid` demo is wrapped in a horizontal `ScrollView` so that it can be viewed in portrait phone layout in the native demo.
2020-07-17 12:57:40 +01:00
Carson Katri 11af0f8d98
Add LazyHGrid and LazyVGrid (#179)
* Add LazyHGrid and LazyVGrid

* iOS support & progress doc
2020-07-14 13:28:23 -04:00
Carson Katri 50be7b16f7
Add List and related Views (#147)
* List and Divider

* Add DisclosureGroup and OutlineGroup

* Add aria attributes

* OutlineGroup List initializers

* Make only chevron clickable

* ListStyle

* Fix line lengths

* Fix demo

* Section

* Modify progressmd

* Remove useless comment

* Switch to hr element

* Disable Divider for last row

* Make list and outline style defaults constant

* Minor cleanup

* ListStyleDeferredToRenderer

* Fix demo
2020-07-06 15:46:59 -04:00
Max Desiatov ebcac6db70
Add Group implementation (#150) 2020-07-02 23:21:33 +01:00
Max Desiatov afba02d2cc
Update AnyView status in progress.md (#151)
IDK, is there something that SwiftUI `AnyView` can do that ours can't? ¯\_(ツ)_/¯
2020-07-02 23:21:14 +01:00
Jed Fox 17463c43ed
Add TextFieldStyle (#125)
* Add TextFieldStyle

* oops

* Comment out the Semantic UI CSS

* Move the DOM-specific stuff to TokamakDOM

* SecureFIeld is implemented!

* Remove commented-out code

Co-authored-by: Max Desiatov <max@desiatov.com>

* Remove unncessary underscore and proxy method

* Enable building on Xcode for access to IDE tools

* Add an environment variable for TextField style

* Remove mandatory init()

* Update Sources/TokamakCore/CGStubs.swift

Co-authored-by: Max Desiatov <max@desiatov.com>

* Update Sources/TokamakCore/CGStubs.swift

Co-authored-by: Max Desiatov <max@desiatov.com>

* Remove the lock

* Move file to sources folder

Co-authored-by: Max Desiatov <max@desiatov.com>
2020-07-01 14:43:09 -04:00
Carson Katri f9f11a0113
Shape, Path, and some related modifiers (#119)
* Initial Shape support

* Border modifier

* Better demo

* Make Path conform to Shape

* Implement clipShape

* Add shapes/path/shapestyles to progress.md
2020-06-30 15:00:16 -04:00
Carson Katri 98a107f7fe
Add ScrollView (#128)
* Add ScrollView
* Root styles for ScrollView and Stack
2020-06-30 12:29:06 -04:00
Carson Katri e40a701752
Add Spacer support (#122)
1. If a Stack has a Spacer as a child, we need to fill the width or height of the parent so the Spacer's flex-grow: 1; works.
2. If a Stack has a child Stack along the cross axis (HStack with a nested VStack and vice vera) we need to fill the cross axis
3. If a Stack has a child Stack along the same axis (HStack with a nested HStack) we need to fill the axis.
2020-06-30 09:31:25 -04:00
Max Desiatov 9f5877e8ab
Update EmptyView status in progress.md 2020-06-30 14:23:39 +01:00
Jed Fox b2b5ec2ae5
Add TextField, SecureField, and a progress document (#116)
I’ve added two TextFields to the demo, which are supposed to have their values synced. Pressing enter in the second one will increment the commit counter.
2020-06-29 17:52:22 +01:00