# Copyright 2021-2025 Avaiga Private Limited # # Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with # the License. You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on # an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the # specific language governing permissions and limitations under the License. import datetime import inspect import random import typing as t import taipy.gui.builder as tgb from taipy.gui import Gui def test_chart_builder_1(gui: Gui, helpers, csvdata): selected_indices = [14258] # noqa: F841 subplot_layout = { # noqa: F841 "grid": {"rows": 1, "columns": 2, "subplots": [["xy", "x2y"]], "roworder": "bottom to top"} } y = ["Daily hospital occupancy", "Daily hospital occupancy"] # noqa: F841 label = ["Entity", "Code"] # noqa: F841 mode = [None, "markers"] # noqa: F841 color = [None, "red"] # noqa: F841 chart_type = [None, "scatter"] # noqa: F841 xaxis = [None, "x2"] # noqa: F841 with tgb.Page(frame=None) as page: tgb.chart( # type: ignore[attr-defined] data="{csvdata}", x="Day", selected_color="green", y="{y}", label="{label}", mode="{mode}", color="{color}", type="{chart_type}", xaxis="{xaxis}", layout="{subplot_layout}", on_range_change="range_change", width="100%", height="100%", selected="{selected_indices}", ) expected_list = [ "