Skip to content

Commit

Permalink
Add props for wrap component (#41)
Browse files Browse the repository at this point in the history
  • Loading branch information
picklelo committed Dec 9, 2022
1 parent 7bb95b4 commit 1d22571
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 2 deletions.
22 changes: 22 additions & 0 deletions pynecone/components/layout/wrap.py
@@ -1,13 +1,35 @@
"""Container to stack elements with spacing."""

from pynecone.components.libs.chakra import ChakraComponent
from pynecone.var import Var


class Wrap(ChakraComponent):
"""Layout component used to add space between elements and wrap automatically if there isn't enough space."""

tag = "Wrap"

# How to align the items.
align: Var[str]

# The flex direction of the wrap.
direction: Var[str]

# How to justify the items.
justify: Var[str]

# Whether to wrap children in `pc.wrap_item`.
should_wrap_children: Var[bool]

# The spacing between the items.
spacing: Var[str]

# The horizontal spacing between the items.
spacing_x: Var[str]

# The vertical spacing between the items.
spacing_y: Var[str]


class WrapItem(ChakraComponent):
"""Item of the Wrap component."""
Expand Down
1 change: 0 additions & 1 deletion pynecone/pc.py
Expand Up @@ -94,7 +94,6 @@ def deploy(dry_run: bool = False):
# Check if the deploy url is set.
if config.deploy_url is None:
typer.echo("This feature is coming soon!")
typer.echo("Join our waitlist to be notified: https://pynecone.io/waitlist")
return

# Compile the app in production mode.
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
@@ -1,6 +1,6 @@
[tool.poetry]
name = "pynecone-io"
version = "0.1.7"
version = "0.1.8"
description = "The easiest way to build web apps."
license = "Apache-2.0"
authors = [
Expand Down

0 comments on commit 1d22571

Please sign in to comment.