From 9f272d3cc51c63792b0b06c2ef538a1e51b37bcf Mon Sep 17 00:00:00 2001 From: Fabien Lelaquais <86590727+FabienLelaquais@users.noreply.github.com> Date: Fri, 17 May 2024 10:45:42 +0200 Subject: [PATCH] Reorder controls for the generated doc (#1291) --- taipy/gui/viselements.json | 966 ++++++++++++++++++------------------- 1 file changed, 483 insertions(+), 483 deletions(-) diff --git a/taipy/gui/viselements.json b/taipy/gui/viselements.json index 67359199da..3b2dc12dcf 100644 --- a/taipy/gui/viselements.json +++ b/taipy/gui/viselements.json @@ -113,30 +113,6 @@ ] } ], - [ - "number", - { - "inherits": [ - "sharedInput", - "on_change", - "propagate" - ], - "properties": [ - { - "name": "value", - "default_property": true, - "type": "dynamic(any)", - "doc": "The numerical value represented by this control." - }, - { - "name": "label", - "type": "str", - "default_value": "None", - "doc": "The label associated with the input." - } - ] - } - ], [ "slider", { @@ -212,6 +188,30 @@ ] } ], + [ + "number", + { + "inherits": [ + "sharedInput", + "on_change", + "propagate" + ], + "properties": [ + { + "name": "value", + "default_property": true, + "type": "dynamic(any)", + "doc": "The numerical value represented by this control." + }, + { + "name": "label", + "type": "str", + "default_value": "None", + "doc": "The label associated with the input." + } + ] + } + ], [ "toggle", { @@ -326,71 +326,6 @@ ] } ], - [ - "chat", - { - "inherits": [ - "active", - "shared" - ], - "properties": [ - { - "name": "messages", - "default_property": true, - "required": true, - "type": "dynamic(list[str])", - "doc": "The list of messages. Each element is a list composed of an id, a message and an user identifier." - }, - { - "name": "users", - "type": "dynamic(list[str|Icon])", - "doc": "The list of users. See the section on List of Values for details." - }, - { - "name": "on_action", - "type": "Callback", - "doc": "The name of a function that is triggered when the user enters a new message.
All parameters of that function are optional:\n.", - "signature": [ - [ - "state", - "State" - ], - [ - "var_name", - "str" - ], - [ - "payload", - "dict" - ] - ] - }, - { - "name": "with_input", - "type": "dynamic(bool)", - "default_value": "True", - "doc": "If True, the input field is visible." - }, - { - "name": "sender_id", - "type": "str", - "default_value": "taipy", - "doc": "The user id associated with the message sent from the input" - }, - { - "name": "height", - "type": "str|int|float", - "doc": "The maximum height, in CSS units, of this element." - }, - { - "name": "page_size", - "type": "int", - "default_value": "50", - "doc": "The number of rows retrieved on the frontend." - } - ] - } - ], [ "chart", { @@ -665,7 +600,7 @@ } ], [ - "file_download", + "table", { "inherits": [ "active", @@ -673,260 +608,160 @@ ], "properties": [ { - "name": "content", + "name": "data", "default_property": true, - "type": "dynamic(path|file|URL|ReadableBuffer|None)", - "doc": "The content to transfer.
If this is a string, a URL, or a file, then the content is read from this source.
If a readable buffer is provided (such as an array of bytes...), and to prevent the bandwidth from being consumed too much, the way the data is transferred depends on the data_url_max_size parameter of the application configuration (which is set to 50kB by default):\nIf this property is set to None, that indicates that dynamic content is generated. Please take a look at the examples below for details on dynamic generation." - }, - { - "name": "label", - "type": "dynamic(str)", - "doc": "The label of the button." + "required": true, + "type": "dynamic(any)", + "doc": "The data to be represented in this table. This property can be indexed to define other data for comparison." }, { - "name": "on_action", - "type": "Callback", - "doc": "The name of a function that is triggered when the download is terminated (or on user action if content is None).
All the parameters of that function are optional:\n", - "signature": [ - [ - "state", - "State" - ], - [ - "id", - "str" - ], - [ - "payload", - "dict" - ] - ] + "name": "page_size", + "type": "int", + "default_value": "100", + "doc": "For a paginated table, the number of visible rows." }, { - "name": "auto", + "name": "allow_all_rows", "type": "bool", "default_value": "False", - "doc": "If True, the download starts as soon as the page is loaded." + "doc": "For a paginated table, adds an option to show all the rows." }, { - "name": "render", - "type": "dynamic(bool)", - "default_value": "True", - "doc": "If True, the control is displayed.
If False, the control is not displayed." + "name": "show_all", + "type": "bool", + "default_value": "False", + "doc": "For a paginated table, show all the rows." }, { - "name": "bypass_preview", + "name": "auto_loading", "type": "bool", - "default_value": "True", - "doc": "If False, allows the browser to try to show the content in a different tab.
The file download is always performed." + "default_value": "False", + "doc": "If True, the data will be loaded on demand." }, { - "name": "name", + "name": "width[column_name]", "type": "str", - "doc": "A name proposition for the file to save, that the user can change." - } - ] - } - ], - [ - "file_selector", - { - "inherits": [ - "active", - "shared" - ], - "properties": [ + "doc": "The width, in CSS units, of the indicated column." + }, { - "name": "content", - "default_property": true, - "type": "dynamic(str)", - "doc": "The path or the list of paths of the uploaded files." + "name": "selected", + "type": "list[int]|str", + "doc": "The list of the indices of the rows to be displayed as selected." }, { - "name": "label", + "name": "page_size_options", + "type": "list[int]|str", + "default_value": "[50, 100, 500]", + "doc": "The list of available page sizes that users can choose from." + }, + { + "name": "columns", + "type": "str|list[str]|dict[str, dict[str, str|int]]", + "default_value": "shows all columns when empty", + "doc": "The list of the column names to display.\n" + }, + { + "name": "date_format", "type": "str", - "doc": "The label of the button." + "default_value": "\"MM/dd/yyyy\"", + "doc": "The date format used for all date columns when the format is not specifically defined." }, { - "name": "on_action", - "type": "Callback", - "doc": "The name of the function that will be triggered.
All the parameters of that function are optional:\n", - "signature": [ - [ - "state", - "State" - ], - [ - "id", - "str" - ], - [ - "payload", - "dict" - ] - ] + "name": "number_format", + "type": "str", + "doc": "The number format used for all number columns when the format is not specifically defined." }, { - "name": "multiple", + "name": "group_by[column_name]", "type": "bool", "default_value": "False", - "doc": "If set to True, multiple files can be uploaded." + "doc": "Indicates, if True, that the given column can be aggregated.
See below for details." }, { - "name": "extensions", + "name": "apply[column_name]", "type": "str", - "default_value": "\".csv,.xlsx\"", - "doc": "The list of file extensions that can be uploaded." + "default_value": "\"first\"", + "doc": "The name of the aggregation function to use.
This is used only if group_by[column_name] is set to True.
See below for details." }, { - "name": "drop_message", + "name": "style", "type": "str", - "default_value": "\"Drop here to Upload\"", - "doc": "The message that is displayed when the user drags a file above the button." + "doc": "Allows the styling of table lines.
See below for details." }, { - "name": "notify", - "type": "bool", - "default_value": "True", - "doc": "If set to False, the user won't be notified of upload finish." - } - ] - } - ], - [ - "image", - { - "inherits": [ - "active", - "shared" - ], - "properties": [ - { - "name": "content", - "default_property": true, - "type": "dynamic(path|URL|file|ReadableBuffer)", - "doc": "The image source.
If a buffer is provided (string, array of bytes...), and in order to prevent the bandwidth to be consumed too much, the way the image data is transferred depends on the data_url_max_size parameter of the application configuration (which is set to 50kB by default):\n" + "name": "style[column_name]", + "type": "str", + "doc": "Allows the styling of table cells.
See below for details." }, { - "name": "label", - "type": "dynamic(str)", - "doc": "The label for this image." + "name": "tooltip", + "type": "str", + "doc": "The name of the function that must return a tooltip text for a cell.
See below for details." }, { - "name": "on_action", - "type": "Callback", - "doc": "The name of a function that is triggered when the user clicks on the image.
All the parameters of that function are optional:\n", - "signature": [ - [ - "state", - "State" - ], - [ - "id", - "str" - ], - [ - "payload", - "dict" - ] - ] + "name": "tooltip[column_name]", + "type": "str", + "doc": "The name of the function that must return a tooltip text for a cell.
See below for details." }, { "name": "width", - "type": "str|int|float", - "default_value": "\"300px\"", - "doc": "The width, in CSS units, of this element." + "type": "str", + "default_value": "\"100%\"", + "doc": "The width, in CSS units, of this table control." }, { "name": "height", - "type": "str|int|float", - "doc": "The height, in CSS units, of this element." - } - ] - } - ], - [ - "indicator", - { - "inherits": [ - "shared" - ], - "properties": [ - { - "name": "display", - "default_property": true, - "type": "dynamic(any)", - "doc": "The label to be displayed.
This can be formatted if it is a numerical value." - }, - { - "name": "value", - "type": "dynamic(int,float)", - "default_value": "min", - "doc": "The location of the label on the [min, max] range." + "type": "str", + "default_value": "\"80vh\"", + "doc": "The height, in CSS units, of this table control." }, { - "name": "min", - "type": "int|float", - "default_value": "0", - "doc": "The minimum value of the range." + "name": "filter", + "type": "bool", + "default_value": "False", + "doc": "Indicates, if True, that all columns can be filtered." }, { - "name": "max", - "type": "int|float", - "default_value": "100", - "doc": "The maximum value of the range." + "name": "filter[column_name]", + "type": "bool", + "default_value": "False", + "doc": "Indicates, if True, that the indicated column can be filtered." }, { - "name": "format", + "name": "nan_value", "type": "str", - "doc": "The format to use when displaying the value.
This uses the printf syntax." + "default_value": "\"\"", + "doc": "The replacement text for NaN (not-a-number) values." }, { - "name": "orientation", + "name": "nan_value[column_name]", "type": "str", - "default_value": "\"horizontal\"", - "doc": "The orientation of this slider." + "default_value": "\"\"", + "doc": "The replacement text for NaN (not-a-number) values for the indicated column." }, { - "name": "width", - "type": "str", - "default_value": "None", - "doc": "The width, in CSS units, of the indicator (used when orientation is horizontal)." + "name": "editable", + "type": "dynamic(bool)", + "default_value": "True", + "doc": "Indicates, if True, that all columns can be edited." }, { - "name": "height", - "type": "str", - "default_value": "None", - "doc": "The height, in CSS units, of the indicator (used when orientation is vertical)." - } - ] - } - ], - [ - "login", - { - "inherits": [ - "shared" - ], - "properties": [ - { - "name": "title", - "default_property": true, - "type": "str", - "default_value": "\"Log in\"", - "doc": "The title of the login dialog." + "name": "editable[column_name]", + "type": "bool", + "default_value": "editable", + "doc": "Indicates, if False, that the indicated column cannot be edited when editable is True." }, { - "name": "on_action", + "name": "on_edit", "type": "Callback", - "doc": "The name of the function that is triggered when the dialog button is pressed.

All the parameters of that function are optional:\n
When the button is pressed, and if this property is not set, Taipy will try to find a callback function called on_login() and invoke it with the parameters listed above.", + "doc": "The name of a function that is triggered when a cell edition is validated.
All parameters of that function are optional:\n
If this property is not set, the user cannot edit cells.", "signature": [ [ "state", "State" ], [ - "id", + "var_name", "str" ], [ @@ -936,94 +771,106 @@ ] }, { - "name": "message", - "type": "dynamic(str)", - "doc": "The message shown in the dialog." - } - ] - } - ], - [ - "menu", - { - "inherits": [ - "active" - ], - "properties": [ + "name": "on_delete", + "type": "str", + "doc": "The name of a function that is triggered when a row is deleted.
All parameters of that function are optional:\n
If this property is not set, the user cannot delete rows.", + "signature": [ + [ + "state", + "State" + ], + [ + "var_name", + "str" + ], + [ + "payload", + "dict" + ] + ] + }, { - "name": "lov", - "default_property": true, - "type": "dynamic(str|list[str|Icon|any])", - "doc": "The list of menu option values." + "name": "on_add", + "type": "str", + "doc": "The name of a function that is triggered when the user requests a row to be added.
All parameters of that function are optional:\n
If this property is not set, the user cannot add rows.", + "signature": [ + [ + "state", + "State" + ], + [ + "var_name", + "str" + ], + [ + "payload", + "dict" + ] + ] }, { - "name": "adapter", - "type": "Function", - "default_value": "`\"lambda x: str(x)\"`", - "doc": "The function that transforms an element of lov into a tuple(id:str, label:str|Icon)." + "name": "on_action", + "type": "Callback", + "doc": "The name of a function that is triggered when the user selects a row.
All parameters of that function are optional:\n.", + "signature": [ + [ + "state", + "State" + ], + [ + "var_name", + "str" + ], + [ + "payload", + "dict" + ] + ] }, { - "name": "type", + "name": "size", "type": "str", - "default_value": "Type of the first lov element", - "doc": "Must be specified if lov contains a non specific type of data (ex: dict).
value must be of that type, lov must be an iterable on this type, and the adapter function will receive an object of this type." + "default_value": "\"small\"", + "doc": "The size of the rows.
Valid values are \"small\" and \"medium\"." }, { - "name": "label", - "type": "str", - "doc": "The title of the menu." + "name": "rebuild", + "type": "dynamic(bool)", + "default_value": "False", + "doc": "If set to True, this allows to dynamically refresh the columns." }, { - "name": "width", - "type": "str", - "default_value": "\"15vw\"", - "doc": "The width, in CSS units, of the menu when unfolded.
Note that when running on a mobile device, the property width[active] is used instead." + "name": "lov[column_name]", + "type": "list[str]|str", + "doc": "The list of values of the indicated column." }, { - "name": "width[mobile]", - "type": "str", - "default_value": "\"85vw\"", - "doc": "The width, in CSS units, of the menu when unfolded, on a mobile device." + "name": "downloadable", + "type": "boolean", + "doc": "If True, a clickable icon is shown so the user can download the data as CSV." }, { - "name": "on_action", - "type": "Callback", - "doc": "The name of the function that is triggered when a menu option is selected.

All the parameters of that function are optional:\n", + "name": "on_compare", + "type": "str", + "doc": "A data comparison function that would return a structure that identifies the differences between the different data passed as name. The default implementation compares the default data with the data[1] value.", "signature": [ [ "state", "State" ], [ - "id", + "main_data_name", "str" ], [ - "payload", - "dict" + "compare_data_names", + "list[str]" ] ] } ] } ], - [ - "navbar", - { - "inherits": [ - "active", - "shared" - ], - "properties": [ - { - "name": "lov", - "default_property": true, - "type": "dict[str, any]", - "doc": "The list of pages. The keys should be:\n\nThe values are labels. See the section on List of Values for details." - } - ] - } - ], [ "selector", { @@ -1076,29 +923,24 @@ } ], [ - "status", + "navbar", { "inherits": [ + "active", "shared" ], "properties": [ { - "name": "value", + "name": "lov", "default_property": true, - "type": "tuple|dict|list[dict]|list[tuple]", - "doc": "The different status items to represent. See below." - }, - { - "name": "without_close", - "type": "bool", - "default_value": "False", - "doc": "If True, the user cannot remove the status items from the list." + "type": "dict[str, any]", + "doc": "The list of pages. The keys should be:\n\nThe values are labels. See the section on List of Values for details." } ] } ], [ - "table", + "image", { "inherits": [ "active", @@ -1106,160 +948,158 @@ ], "properties": [ { - "name": "data", + "name": "content", "default_property": true, - "required": true, - "type": "dynamic(any)", - "doc": "The data to be represented in this table. This property can be indexed to define other data for comparison." - }, - { - "name": "page_size", - "type": "int", - "default_value": "100", - "doc": "For a paginated table, the number of visible rows." - }, - { - "name": "allow_all_rows", - "type": "bool", - "default_value": "False", - "doc": "For a paginated table, adds an option to show all the rows." - }, - { - "name": "show_all", - "type": "bool", - "default_value": "False", - "doc": "For a paginated table, show all the rows." - }, - { - "name": "auto_loading", - "type": "bool", - "default_value": "False", - "doc": "If True, the data will be loaded on demand." - }, - { - "name": "width[column_name]", - "type": "str", - "doc": "The width, in CSS units, of the indicated column." - }, - { - "name": "selected", - "type": "list[int]|str", - "doc": "The list of the indices of the rows to be displayed as selected." + "type": "dynamic(path|URL|file|ReadableBuffer)", + "doc": "The image source.
If a buffer is provided (string, array of bytes...), and in order to prevent the bandwidth to be consumed too much, the way the image data is transferred depends on the data_url_max_size parameter of the application configuration (which is set to 50kB by default):\n" }, { - "name": "page_size_options", - "type": "list[int]|str", - "default_value": "[50, 100, 500]", - "doc": "The list of available page sizes that users can choose from." + "name": "label", + "type": "dynamic(str)", + "doc": "The label for this image." }, { - "name": "columns", - "type": "str|list[str]|dict[str, dict[str, str|int]]", - "default_value": "shows all columns when empty", - "doc": "The list of the column names to display.\n" + "name": "on_action", + "type": "Callback", + "doc": "The name of a function that is triggered when the user clicks on the image.
All the parameters of that function are optional:\n", + "signature": [ + [ + "state", + "State" + ], + [ + "id", + "str" + ], + [ + "payload", + "dict" + ] + ] }, { - "name": "date_format", - "type": "str", - "default_value": "\"MM/dd/yyyy\"", - "doc": "The date format used for all date columns when the format is not specifically defined." + "name": "width", + "type": "str|int|float", + "default_value": "\"300px\"", + "doc": "The width, in CSS units, of this element." }, { - "name": "number_format", - "type": "str", - "doc": "The number format used for all number columns when the format is not specifically defined." - }, + "name": "height", + "type": "str|int|float", + "doc": "The height, in CSS units, of this element." + } + ] + } + ], + [ + "indicator", + { + "inherits": [ + "shared" + ], + "properties": [ { - "name": "group_by[column_name]", - "type": "bool", - "default_value": "False", - "doc": "Indicates, if True, that the given column can be aggregated.
See below for details." + "name": "display", + "default_property": true, + "type": "dynamic(any)", + "doc": "The label to be displayed.
This can be formatted if it is a numerical value." }, { - "name": "apply[column_name]", - "type": "str", - "default_value": "\"first\"", - "doc": "The name of the aggregation function to use.
This is used only if group_by[column_name] is set to True.
See below for details." + "name": "value", + "type": "dynamic(int,float)", + "default_value": "min", + "doc": "The location of the label on the [min, max] range." }, { - "name": "style", - "type": "str", - "doc": "Allows the styling of table lines.
See below for details." + "name": "min", + "type": "int|float", + "default_value": "0", + "doc": "The minimum value of the range." }, { - "name": "style[column_name]", - "type": "str", - "doc": "Allows the styling of table cells.
See below for details." + "name": "max", + "type": "int|float", + "default_value": "100", + "doc": "The maximum value of the range." }, { - "name": "tooltip", + "name": "format", "type": "str", - "doc": "The name of the function that must return a tooltip text for a cell.
See below for details." + "doc": "The format to use when displaying the value.
This uses the printf syntax." }, { - "name": "tooltip[column_name]", + "name": "orientation", "type": "str", - "doc": "The name of the function that must return a tooltip text for a cell.
See below for details." + "default_value": "\"horizontal\"", + "doc": "The orientation of this slider." }, { "name": "width", "type": "str", - "default_value": "\"100%\"", - "doc": "The width, in CSS units, of this table control." + "default_value": "None", + "doc": "The width, in CSS units, of the indicator (used when orientation is horizontal)." }, { "name": "height", "type": "str", - "default_value": "\"80vh\"", - "doc": "The height, in CSS units, of this table control." - }, - { - "name": "filter", - "type": "bool", - "default_value": "False", - "doc": "Indicates, if True, that all columns can be filtered." - }, - { - "name": "filter[column_name]", - "type": "bool", - "default_value": "False", - "doc": "Indicates, if True, that the indicated column can be filtered." - }, - { - "name": "nan_value", - "type": "str", - "default_value": "\"\"", - "doc": "The replacement text for NaN (not-a-number) values." - }, + "default_value": "None", + "doc": "The height, in CSS units, of the indicator (used when orientation is vertical)." + } + ] + } + ], + [ + "status", + { + "inherits": [ + "shared" + ], + "properties": [ { - "name": "nan_value[column_name]", - "type": "str", - "default_value": "\"\"", - "doc": "The replacement text for NaN (not-a-number) values for the indicated column." + "name": "value", + "default_property": true, + "type": "tuple|dict|list[dict]|list[tuple]", + "doc": "The different status items to represent. See below." }, { - "name": "editable", - "type": "dynamic(bool)", - "default_value": "True", - "doc": "Indicates, if True, that all columns can be edited." + "name": "without_close", + "type": "bool", + "default_value": "False", + "doc": "If True, the user cannot remove the status items from the list." + } + ] + } + ], + [ + "file_download", + { + "inherits": [ + "active", + "shared" + ], + "properties": [ + { + "name": "content", + "default_property": true, + "type": "dynamic(path|file|URL|ReadableBuffer|None)", + "doc": "The content to transfer.
If this is a string, a URL, or a file, then the content is read from this source.
If a readable buffer is provided (such as an array of bytes...), and to prevent the bandwidth from being consumed too much, the way the data is transferred depends on the data_url_max_size parameter of the application configuration (which is set to 50kB by default):\nIf this property is set to None, that indicates that dynamic content is generated. Please take a look at the examples below for details on dynamic generation." }, { - "name": "editable[column_name]", - "type": "bool", - "default_value": "editable", - "doc": "Indicates, if False, that the indicated column cannot be edited when editable is True." + "name": "label", + "type": "dynamic(str)", + "doc": "The label of the button." }, { - "name": "on_edit", + "name": "on_action", "type": "Callback", - "doc": "The name of a function that is triggered when a cell edition is validated.
All parameters of that function are optional:\n
If this property is not set, the user cannot edit cells.", + "doc": "The name of a function that is triggered when the download is terminated (or on user action if content is None).
All the parameters of that function are optional:\n", "signature": [ [ "state", "State" ], [ - "var_name", + "id", "str" ], [ @@ -1269,16 +1109,61 @@ ] }, { - "name": "on_delete", + "name": "auto", + "type": "bool", + "default_value": "False", + "doc": "If True, the download starts as soon as the page is loaded." + }, + { + "name": "render", + "type": "dynamic(bool)", + "default_value": "True", + "doc": "If True, the control is displayed.
If False, the control is not displayed." + }, + { + "name": "bypass_preview", + "type": "bool", + "default_value": "True", + "doc": "If False, allows the browser to try to show the content in a different tab.
The file download is always performed." + }, + { + "name": "name", "type": "str", - "doc": "The name of a function that is triggered when a row is deleted.
All parameters of that function are optional:\n
If this property is not set, the user cannot delete rows.", + "doc": "A name proposition for the file to save, that the user can change." + } + ] + } + ], + [ + "file_selector", + { + "inherits": [ + "active", + "shared" + ], + "properties": [ + { + "name": "content", + "default_property": true, + "type": "dynamic(str)", + "doc": "The path or the list of paths of the uploaded files." + }, + { + "name": "label", + "type": "str", + "doc": "The label of the button." + }, + { + "name": "on_action", + "type": "Callback", + "doc": "The name of the function that will be triggered.
All the parameters of that function are optional:\n", "signature": [ [ "state", "State" ], [ - "var_name", + "id", "str" ], [ @@ -1288,16 +1173,57 @@ ] }, { - "name": "on_add", + "name": "multiple", + "type": "bool", + "default_value": "False", + "doc": "If set to True, multiple files can be uploaded." + }, + { + "name": "extensions", "type": "str", - "doc": "The name of a function that is triggered when the user requests a row to be added.
All parameters of that function are optional:\n
If this property is not set, the user cannot add rows.", + "default_value": "\".csv,.xlsx\"", + "doc": "The list of file extensions that can be uploaded." + }, + { + "name": "drop_message", + "type": "str", + "default_value": "\"Drop here to Upload\"", + "doc": "The message that is displayed when the user drags a file above the button." + }, + { + "name": "notify", + "type": "bool", + "default_value": "True", + "doc": "If set to False, the user won't be notified of upload finish." + } + ] + } + ], + [ + "login", + { + "inherits": [ + "shared" + ], + "properties": [ + { + "name": "title", + "default_property": true, + "type": "str", + "default_value": "\"Log in\"", + "doc": "The title of the login dialog." + }, + { + "name": "on_action", + "type": "Callback", + "doc": "The name of the function that is triggered when the dialog button is pressed.

All the parameters of that function are optional:\n
When the button is pressed, and if this property is not set, Taipy will try to find a callback function called on_login() and invoke it with the parameters listed above.", "signature": [ [ "state", "State" ], [ - "var_name", + "id", "str" ], [ @@ -1306,10 +1232,38 @@ ] ] }, + { + "name": "message", + "type": "dynamic(str)", + "doc": "The message shown in the dialog." + } + ] + } + ], + [ + "chat", + { + "inherits": [ + "active", + "shared" + ], + "properties": [ + { + "name": "messages", + "default_property": true, + "required": true, + "type": "dynamic(list[str])", + "doc": "The list of messages. Each element is a list composed of an id, a message and an user identifier." + }, + { + "name": "users", + "type": "dynamic(list[str|Icon])", + "doc": "The list of users. See the section on List of Values for details." + }, { "name": "on_action", "type": "Callback", - "doc": "The name of a function that is triggered when the user selects a row.
All parameters of that function are optional:\n.", + "doc": "The name of a function that is triggered when the user enters a new message.
All parameters of that function are optional:\n.", "signature": [ [ "state", @@ -1326,43 +1280,89 @@ ] }, { - "name": "size", + "name": "with_input", + "type": "dynamic(bool)", + "default_value": "True", + "doc": "If True, the input field is visible." + }, + { + "name": "sender_id", "type": "str", - "default_value": "\"small\"", - "doc": "The size of the rows.
Valid values are \"small\" and \"medium\"." + "default_value": "\"taipy\"", + "doc": "The user id associated with the message sent from the input" }, { - "name": "rebuild", - "type": "dynamic(bool)", - "default_value": "False", - "doc": "If set to True, this allows to dynamically refresh the columns." + "name": "height", + "type": "str|int|float", + "doc": "The maximum height, in CSS units, of this element." }, { - "name": "lov[column_name]", - "type": "list[str]|str", - "doc": "The list of values of the indicated column." + "name": "page_size", + "type": "int", + "default_value": "50", + "doc": "The number of rows retrieved on the frontend." + } + ] + } + ], + [ + "menu", + { + "inherits": [ + "active" + ], + "properties": [ + { + "name": "lov", + "default_property": true, + "type": "dynamic(str|list[str|Icon|any])", + "doc": "The list of menu option values." }, { - "name": "downloadable", - "type": "boolean", - "doc": "If True, a clickable icon is shown so the user can download the data as CSV." + "name": "adapter", + "type": "Function", + "default_value": "`\"lambda x: str(x)\"`", + "doc": "The function that transforms an element of lov into a tuple(id:str, label:str|Icon)." }, { - "name": "on_compare", + "name": "type", "type": "str", - "doc": "A data comparison function that would return a structure that identifies the differences between the different data passed as name. The default implementation compares the default data with the data[1] value.", + "default_value": "Type of the first lov element", + "doc": "Must be specified if lov contains a non specific type of data (ex: dict).
value must be of that type, lov must be an iterable on this type, and the adapter function will receive an object of this type." + }, + { + "name": "label", + "type": "str", + "doc": "The title of the menu." + }, + { + "name": "width", + "type": "str", + "default_value": "\"15vw\"", + "doc": "The width, in CSS units, of the menu when unfolded.
Note that when running on a mobile device, the property width[active] is used instead." + }, + { + "name": "width[mobile]", + "type": "str", + "default_value": "\"85vw\"", + "doc": "The width, in CSS units, of the menu when unfolded, on a mobile device." + }, + { + "name": "on_action", + "type": "Callback", + "doc": "The name of the function that is triggered when a menu option is selected.

All the parameters of that function are optional:\n", "signature": [ [ "state", "State" ], [ - "main_data_name", + "id", "str" ], [ - "compare_data_names", - "list[str]" + "payload", + "dict" ] ] }