Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import workflow-kotlin-compose repo into the compose/ directory. #301

Merged
merged 122 commits into from
Feb 4, 2021

Conversation

zach-klippenstein
Copy link
Collaborator

@zach-klippenstein zach-klippenstein commented Feb 4, 2021

  • As far as gradle are concerned, this is entirely separate from the main workflow gradle project. We might merge them later, but this PR does not attempt to do so.
  • Includes all commits from the compose repo (which includes some duplicates from the early workflow days – this is a little weird, but i don't think it's critical, and fixing that would be very difficult).
  • Merges the CODEOWNERs files.
  • The compose github actions configurations are already in their own file, so no merge conflict.
  • I have already transferred open issues over
  • Will push branches from compose to this repo so we can pick those up from where we left them.

Fixes #289.

zach-klippenstein and others added 30 commits May 11, 2020 10:57
Add workaround for Nexus issue with sha256/512 checksums.
Remove unused JMH dependencies and configuration.
* zachklipp/cleanup-dependencies:
  Remove unused dependencies.
Upgrade workflow dependencies to latest version.
Cleanup how ComposableViewFactory handles initial rendering.
`ComposeWorkflow` is like a `StatelessWorkflow`, but it has a special `render` method:
it's a `@Composable` function, and it functions like the body of a `bindCompose` lambda
where the rendering is just the workflow's props and a `Sink` accepting `OutputT`s.
* zachklipp/composeworkflow:
  Introduce ComposeWorkflow, a self-rendering Workflow.
This is the Compose analog to `WorkflowViewStub`, and delegates to
`WorkflowViewStub` except when the child `ViewFactory` was also created
with `bindCompose`. In that case, it just invokes that factory's
Composable function directly to avoid jumping back out into legacy
View land.
Add the ability to display nested renderings with bindCompose.
…pose factories.

Also introduces a `ComposeViewFactoryRoot` `ViewEnvironment` key to allow
"initializing" ambients and other compose context for all nested composables.

Fixes #9.
Make nested bindCompose factories child compositions of outer bindCompose factories.
Requires forcing the version of the coroutine libraries that the Workflow
core artifacts transitively bring in down to 1.3.0, due to a bug in
version dev10 of Compose (see #13, and
[this slack message](https://kotlinlang.slack.com/archives/CJLTWPH7S/p1589450805381700?thread_ts=1588232959.054500&cid=CJLTWPH7S)).
Add previews to composables in samples.
Move all common UI test dependencies into shared setup file.
Introduce tooling module with support for previewing ViewBindings with Compose's Preview.
This is the third flavor of integration, it replaces `setContentWorkflow`,
`WorkflowLayout`, `WorkflowRunnerViewModel`, etc., and makes it really
easy to run a `Workflow` inside a pure Compose app. It's compatible with
`ViewEnvironment`/`ViewRegistry`, but doesn't require it – it gives you the
root rendering, and you can do whatever you want with it.

It also supports running root `ComposeWorkflow`s directly, since they are
self-rendering.
Introduce WorkflowContainer for running a workflow inside a Compose app.
This change reorganizes some of the wrapper logic to live closer to related code, and moves
a bunch of internal-only helper code into an internal package to make the public API more browseable.
Input to legacy views hosted inside a composition seems to (partially) work now!
The positions are a little off, but you can see buttons being clicked. There's
a bug in our subcomposition infra that causes infinite rerenders, and prevents
updates from actually showing up in legacy views, but I'll fix that in a follow-
up.
zach-klippenstein and others added 20 commits October 14, 2020 12:21
Fix the samples not being full-size.
This seems to fix #79.
Update indentation to match latest code style.
Replace individual UI Systems team members with the ui-systems-android team in CODEOWNERS.
Move everything into a compose subdirectory to prep for importing into the main workflow-kotlin repo.
…pose

* compose/main: (66 commits)
  Move everything into a compose subdirectory to prep for importing into the main workflow-kotlin repo.
  Replace individual UI Systems team members with the ui-systems-android team in CODEOWNERS.
  Update indentation to match latest code style.
  Upgrade Compose to alpha07.
  Fix the samples not being full-size.
  Upgrade compose to alpha06.
  Upgrade AGP.
  Upgrade AGP to alpha14.
  Upgrade Gradle to latest version.
  Upgrade Compose to latest version.
  Remove redundant parentheses after @composable annotations.
  Remove coroutine forced dependency resolution.
  Upgrade Compose and AGP to latest versions.
  Upgrade Kotlin to 1.4.10.
  Upgrade Compose to alpha02.
  Upgrade AGP to 4.2.0-alpha10.
  Upgrade gradle to 6.6.1.
  Upgrade Compose to 1.0.0-alpha01.
  Upgrade to Kotlin 1.4.
  Upgrade Gradle to 6.6.
  ...
@zach-klippenstein
Copy link
Collaborator Author

zach-klippenstein commented Feb 4, 2021

Since there are a lot of commits here, note the last one in particular: 6a9257c. This commit excludes the compose directory from some of our build tooling.

@zach-klippenstein zach-klippenstein marked this pull request as ready for review February 4, 2021 21:59
@zach-klippenstein zach-klippenstein requested a review from a team February 4, 2021 21:59
@zach-klippenstein zach-klippenstein merged commit 4b37e1e into main Feb 4, 2021
@zach-klippenstein zach-klippenstein deleted the zachklipp/import-compose branch February 4, 2021 22:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Import the workflow-kotlin-compose repo into this one.
3 participants