Commit Graph

486 Commits

Author SHA1 Message Date
Max Desiatov d32bc3cd80
Fix README Travis badge not pointing to master 2019-02-25 12:28:47 +00:00
Max Desiatov 923ffd02fd
Define and set RefTarget in TokamakUIKit (#54)
Also add `UIView.animate` animation effect to example code. Also removes redundant `Updatable` protocol.

Resolves #49 

* Define and set RefTarget in TokamakUIKit
* Add animation example
* Rename backgroundColor to currentColor
* Add comments to Animation example
2019-02-25 11:50:09 +00:00
Max Desiatov 5fabe139dd
Implement node ref updates in TestRenderer (#51)
This is a prerequisite for #49, the actual `UIKitRenderer` implementation will follow in a separate PR.
2019-02-23 11:30:48 +00:00
Max Desiatov c9ae90e96f
Restore indentation settings in the main project 2019-02-22 12:09:07 +00:00
matvii a7ce2fab11
Expose accessibility configuration on view props (#50)
* Rename StyleProps to ViewProps

* Init new argument order

* Init accessibility

* Add Accessibility.swift to project

* Sort Style init arguments

* Reorder arguments in Example

* Add Props init to StackView

* Fix arguments order in test

* Expose accessibility configuration on view props

* Rename ViewProps to StyleProps
2019-02-22 13:41:44 +02:00
Max Desiatov 25340c6cda
Restore indentation settings in the main project 2019-02-22 11:24:16 +00:00
Max Desiatov d6abc1df55
Refine links in README and StandardComponents doc 2019-02-22 09:53:03 +00:00
Max Desiatov f894a4d78e
Fix Swift 5 compatibility, refine Timer demo (#48) 2019-02-22 08:46:39 +00:00
Max Desiatov 1576c8eb74
Add link to Hooks section in README FAQ 2019-02-21 11:53:33 +00:00
Max Desiatov a7e7311d6d
Fix typo in README, add more links across sections 2019-02-21 11:51:05 +00:00
Max Desiatov 225b5e04bc
More links to local sections in README 2019-02-21 11:46:13 +00:00
Max Desiatov 8f247dd212
Add links to local sections in README 2019-02-21 11:45:26 +00:00
Max Desiatov 832ad4ce17
Improve README Props intro, cleanup constraints 2019-02-21 09:54:51 +00:00
matvii 29e5a2b0a1
Add Stepper missing props (#47) 2019-02-20 20:50:29 +02:00
Max Desiatov 669c8f9493
Refine README sections and wording 2019-02-20 10:10:47 +00:00
matvii 9a584ba044
Add contentMode to Style (#46)
* Add contentMode to Style

* Change ImageExample protocol to PureLeafComponent

* Add ContentMode to main project
2019-02-19 19:27:16 +02:00
matvii cac728b7b5
Add Image component (#45)
* Init Image

* Fix RenderingMode, merge Tokamak renaming

* Add image props

* Add image example

* Format comment

* Switch image to implicit member expression
2019-02-18 20:14:08 +02:00
Max Desiatov 7f0373d8c1
Replace swiftlint from .travis.yml with Hound CI 2019-02-18 15:44:43 +00:00
Max Desiatov 8b218ba2b8
Add .hound.yml, add commented Spectrum link to README 2019-02-18 15:41:57 +00:00
Max Desiatov c197701e36
Rename Gluon to Tokamak (#44)
* Rename Gluon to Tokamak
* Fix scheme in .travis.yml, fix storyboard
2019-02-18 10:54:49 +00:00
Max Desiatov 22cce69d3a
Add `ref` and `effect` hooks, `Updatable` protocol (#41)
This also cleans up and refines some of the `Example` code and removes unused `key` property from `AnyNode`, which greatly improves error-reporting of Swift type-checker when wrong props are passed to `node` function.

Resolves #10 
Resolves #9 
Resolves #16

* Add Ref class and RefComponent protocol
* Add AnyRef protocol, add ref to AnyNode.init
* Cleanup hooks, add Target class to Gluon module
* Fix tests, avoid optionality in Target class
* Improve doc comments on Hooks.effect overload
* Implement effects scheduling with finalizers
* Add HookedComponents protocol, Hooks as class
* Cleanup after rebased on `master`
* Fix tests failing after Hooks refactoring
* Remove `key` argument from AnyNode.init, cleanups
* Efficient Reduceable state fully working w/ tests
* Fix use of comments for Equatable AnyNode operator
* Cleanup comments in Hooks and MHC
* Add TimerCounter, fix host not unmounting children
* Rename Reduceable to Updatable, fix effects bugs
* Fix TestRenderer compilation issues
* Remove `print` remnants in Timer Example code
2019-02-18 09:00:20 +00:00
Max Desiatov 3715feefef
Add a note about Props being value types to README 2019-02-17 10:20:09 +00:00
Max Desiatov 6f4b706441
Fix .safeArea constraints, apply to Example code (#42)
Turns out `.safeArea` auto layout constraints didn't work. This is now fixed, which allows cleaning up Example layout code.

Also, there's no easy way to implement `topLayoutGuide` and `bottomLayoutGuide` support for old versions of iOS that don't have `safeAreaLayoutGuide`. It's much easier to just drop iOS 10 or older ¯\_(ツ)_/¯ 

* Add {top,bottom}LayoutGuide constraints
* Fix .safeArea constraints, bump iOS requirements
2019-02-16 20:53:30 +00:00
Max Desiatov ee2af79dd0
Bump iOS requirements in README 2019-02-16 19:00:33 +00:00
Max Desiatov fb5d236846
Refine .swiftformat 2019-02-15 12:44:27 +00:00
Max Desiatov aa9592c836
Fix wording in README 2019-02-14 13:51:18 +00:00
Max Desiatov be15a30b3f
Fix wording in README 2019-02-14 13:48:05 +00:00
Max Desiatov 3620ca823d
Fix wording in README 2019-02-14 13:47:09 +00:00
Max Desiatov 3ecc5e5683
Add stability note to README 2019-02-14 13:45:01 +00:00
Max Desiatov 89cde27de5
Rework Example navigation, add LineBreakMode 2019-02-14 13:42:40 +00:00
Max Desiatov a5fa21e84d
Enable test renderer runs for GluonUIKit scheme 2019-02-14 10:20:30 +00:00
Max Desiatov 65264dc4b9
Bump code example link to the top in README 2019-02-14 10:20:03 +00:00
Max Desiatov d01dfff3c3
Fix formatting 2019-02-14 09:48:35 +00:00
Max Desiatov cce1d572b4
Add ListView.Props.onSelect (#40)
This allows `ListView` components to handle selection of items. Example `TableModal` component was refined to demo the new property.

* Add onSelect parameter to ListView.Props
* Implemented `onSelected` prop, test in demo app
2019-02-14 07:54:27 +00:00
Max Desiatov ca91125f92
Clarify styling docs in StandardComponents.md 2019-02-11 11:20:00 +00:00
Max Desiatov e413b06683
Add NavigationItem host component (#27)
Resolves #22

* Add StackControllerItem host component
* Move {Stack,Navigation}Presenter, related changes
* Update StandardComponents doc with new name
* Fix styling after view controller behavior change
* Remove style from StackView.Props.init
* Add `viewDidLoad` comment to UIViewComponent
* Fix tests not compiling
* Implement basic UIHostComponent for NavigationItem
* Implement prefersLargeTitles, test item titles
* Remove unused public func isSubtypeOf<T, U, V, W>
* Remove unused NavigationItemBox, fix formatting
* Remove missing file from the project
2019-02-11 08:24:51 +00:00
Max Desiatov dfe658fe5b
Fix section order in table of contents in README 2019-02-08 10:17:35 +00:00
Max Desiatov fb7fba591a
Add "Render function" section 2019-02-08 10:14:13 +00:00
Max Desiatov 98cf2a7be4
Update code example in README.md 2019-02-07 08:53:37 +00:00
matvii 73f6921ed2
Add isAnimated to Switch (#38) 2019-02-06 17:56:40 +02:00
Max Desiatov a789611b03
Refine README (intro points, links, wording) 2019-02-06 11:52:42 +00:00
matvii 8ee92cb42b
Add properties for CALayer appearance (#34)
* Add modifiers the layer’s appearance

* Rename CALayerModal variable

* Add missing masksToBounds to UIViewComponent
2019-02-06 12:23:38 +02:00
matvii ac6dcbb354
Add DatePicker
* Add DatePicker

* Change TableModal protocol

* Update DatePicker example

* Add isAnimated to DatePicker
2019-02-05 15:30:46 +02:00
Max Desiatov 7616faba23
Fix links and typos in StandardComponents.md 2019-02-04 09:52:42 +00:00
Max Desiatov 07bcc61753
Fix typo in ListView doc comments 2019-02-04 09:50:49 +00:00
Max Desiatov e6662343f0
Refine wording in StandardComponents.md 2019-02-04 09:48:26 +00:00
Max Desiatov 399724ebac
Update standard components docs and fix links 2019-02-04 09:45:09 +00:00
Max Desiatov 7562a45ca4
Update standard components link in README 2019-02-03 19:12:06 +00:00
Max Desiatov 53ee7752e7
Add "Standard components" section to README.md 2019-02-03 19:10:36 +00:00
matvii ed4ac34bd9 Add Top, Bottom, Left, Right, Leading, Trailing constraints (#14)
* Add Top, Bottom, Left, Right, Leading, Trailing constraints
* Remove .own from Top, Bottom, Left, Right, Leading, Trailing constraints
* Add OffsetConstraint protocol to Bottom, Height, Leading, Left, Right, Top, Trailing, Width
* Add CenterX, CenterY, FirstBaseline, LastBaseline
* Update constraints protocol
* Add constrain example
* Apply swift format
* Delegate most of the remaining constraints
* Fix GluonTests module compilation errors
* Implement Center and .safeArea constraints
* Add {First,Last}Baseline, improve docs
2019-02-03 18:59:47 +00:00