diff --git a/vizro-core/docs/pages/user_guides/table.md b/vizro-core/docs/pages/user_guides/table.md index 0363ca015..4dd6420af 100755 --- a/vizro-core/docs/pages/user_guides/table.md +++ b/vizro-core/docs/pages/user_guides/table.md @@ -27,7 +27,7 @@ from vizro.tables import dash_data_table ``` The Vizro version of the table differs in one way from the original table: it requires the user to provide a pandas dataframe as source of data. This must be entered under the argument `data_frame`. -All other parameters of the [Dash DataTable](https://dash.plotly.com/datatable) can be entered as kwargs. +All other [parameters of the Dash DataTable](https://dash.plotly.com/datatable/reference) can be entered as kwargs. !!! example "Dash DataTable" === "app.py" diff --git a/vizro-core/src/vizro/models/_components/graph.py b/vizro-core/src/vizro/models/_components/graph.py index 25a555f24..253007582 100644 --- a/vizro-core/src/vizro/models/_components/graph.py +++ b/vizro-core/src/vizro/models/_components/graph.py @@ -38,9 +38,7 @@ class Graph(VizroBaseModel): """ type: Literal["graph"] = "graph" - figure: CapturedCallable = Field( - ..., import_path=px - ) # TODO: needs to be refactored so plotly-independent or extendable - No, as within the boundaries of Graph model + figure: CapturedCallable = Field(..., import_path=px) actions: List[Action] = [] # Component properties for actions and interactions @@ -48,7 +46,7 @@ class Graph(VizroBaseModel): # Re-used validators _set_actions = _action_validator_factory("clickData") - _validate_callable = validator("figure", allow_reuse=True, always=True)(_process_callable_data_frame) + _validate_callable = validator("figure", allow_reuse=True)(_process_callable_data_frame) # Convenience wrapper/syntactic sugar. def __call__(self, **kwargs): diff --git a/vizro-core/src/vizro/models/types.py b/vizro-core/src/vizro/models/types.py index 7db9f08c0..f15522c12 100644 --- a/vizro-core/src/vizro/models/types.py +++ b/vizro-core/src/vizro/models/types.py @@ -219,7 +219,7 @@ def wrapped(*args, **kwargs): return wrapped elif self._mode == "table": - # The table component + @functools.wraps(func) def wrapped(*args, **kwargs): if "data_frame" not in inspect.signature(func).parameters: diff --git a/vizro-core/src/vizro/static/css/table.css b/vizro-core/src/vizro/static/css/table.css index a6fd902ee..06092f80c 100644 --- a/vizro-core/src/vizro/static/css/table.css +++ b/vizro-core/src/vizro/static/css/table.css @@ -30,3 +30,12 @@ div.right_side .dash-table-container .dash-spreadsheet-container .dash-spreadsheet-inner th { padding: 0px 4px; } + +.table-title { + padding-bottom: 14px; +} + +.table-container { + padding: 12px; + padding-left: 18px; +} \ No newline at end of file