fix, lint
This commit is contained in:
parent
977a9d632b
commit
481c9d9dbd
@ -82,13 +82,18 @@ class Progress(SimpleNamespace):
|
|||||||
"""High level API for progress bar.
|
"""High level API for progress bar.
|
||||||
|
|
||||||
Args:
|
Args:
|
||||||
|
width: The width of the progerss bar
|
||||||
**props: The props of the progress bar
|
**props: The props of the progress bar
|
||||||
|
|
||||||
Returns:
|
Returns:
|
||||||
The progress bar.
|
The progress bar.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
style = props.setdefault("style", {})
|
||||||
|
style.update({"width": width})
|
||||||
|
|
||||||
return ProgressRoot.create(
|
return ProgressRoot.create(
|
||||||
ProgressIndicator.create(width=width, value=props.get("value")),
|
ProgressIndicator.create(value=props.get("value")),
|
||||||
**props,
|
**props,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -275,6 +275,6 @@ class Progress(SimpleNamespace):
|
|||||||
indicator = staticmethod(ProgressIndicator.create)
|
indicator = staticmethod(ProgressIndicator.create)
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def __call__(**props) -> Component: ...
|
def __call__(width: Optional[str] = "100%", **props) -> Component: ...
|
||||||
|
|
||||||
progress = Progress()
|
progress = Progress()
|
||||||
|
Loading…
Reference in New Issue
Block a user