reflex/pynecone/components/feedback/alert.py
Nikhil Rao 7ec4b3f8fe
Improve component docs (#35)
* Update component docstrings
* Remove transitions libs
* Add span component
* Add lock files
2022-12-07 15:04:49 -08:00

35 lines
696 B
Python

"""Alert components."""
from pynecone.components.libs.chakra import ChakraComponent
from pynecone.var import Var
class Alert(ChakraComponent):
"""An alert feedback box."""
tag = "Alert"
# The status of the alert ("success" | "info" | "warning" | "error")
status: Var[str]
# "subtle" | "left-accent" | "top-accent" | "solid"
variant: Var[str]
class AlertIcon(ChakraComponent):
"""An icon displayed in the alert."""
tag = "AlertIcon"
class AlertTitle(ChakraComponent):
"""The title of the alert."""
tag = "AlertTitle"
class AlertDescription(ChakraComponent):
"""AlertDescription composes the Box component."""
tag = "AlertDescription"