Skip to content

Commit

Permalink
Express' value_box() no longer includes named positional args (#966)
Browse files Browse the repository at this point in the history
  • Loading branch information
cpsievert authored Jan 3, 2024
1 parent a821c38 commit f926cc3
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions shiny/express/ui/_cm_components.py
Original file line number Diff line number Diff line change
Expand Up @@ -1115,8 +1115,6 @@ def nav_menu(
# Value boxes
# ======================================================================================
def value_box(
title: TagChild,
value: TagChild,
*,
showcase: Optional[TagChild] = None,
showcase_layout: ui._valuebox.SHOWCASE_LAYOUTS_STR
Expand All @@ -1134,16 +1132,14 @@ def value_box(
This function wraps :func:`~shiny.ui.value_box`.
An opinionated (:func:`~shiny.ui.card`-powered) box, designed for
displaying a `value` and `title`. Optionally, a `showcase` can provide for context
for what the `value` represents (for example, it could hold an icon, or even a
An opinionated (:func:`~shiny.ui.card`-powered) box, designed for displaying a title
(the 1st child), value (the 2nd child), and other explanation text (other children,
if any). Optionally, a `showcase` can provide for context for what the `value`
represents (for example, it could hold an icon, or even a
:func:`~shiny.ui.output_plot`).
Parameters
----------
title,value
A string, number, or :class:`~htmltools.Tag` child to display as
the title or value of the value box. The `title` appears above the `value`.
showcase
A :class:`~htmltools.Tag` child to showcase (e.g., an icon, a
:func:`~shiny.ui.output_plot`, etc).
Expand Down Expand Up @@ -1184,7 +1180,6 @@ def value_box(
"""
return RecallContextManager(
ui.value_box,
args=(title, value),
kwargs=dict(
showcase=showcase,
showcase_layout=showcase_layout,
Expand Down

0 comments on commit f926cc3

Please sign in to comment.