Browse Source

Automatic link to Taipy's doc page from the element properties doc in the IDE (Page Builder API) (#2484)

- xrefs from IDE to Classes page doc
- Elements doc homogeneity
- Remove Gui doc examples from coverage
- Avoid coverage test break if no related file was detected.
Fabien Lelaquais 2 months ago
parent
commit
047784b79c

+ 1 - 0
.coveragerc

@@ -1,6 +1,7 @@
 [run]
 omit =
     tests/*
+    doc/gui/*.py
 
 [report]
 exclude_lines =

+ 3 - 3
doc/gui/examples/controls/toggle_styling.py

@@ -21,12 +21,12 @@ page = Markdown(
     "<|{value}|toggle|lov=Item 1;Item 2;Item 3;Item 4;Item 5|>",
     style={
         ".taipy-toggle": {
-            ".MuiToggleButtonGroup-root": {  # Select the list
-                ".MuiToggleButton-root:nth-child(even)": {  # Even button colors
+            ".MuiToggleButtonGroup-root": {  # Select the buttons group
+                ".MuiToggleButton-root:nth-child(even)": {  # Style for even buttons
                     "background-color": "lightgrey",
                     "color": "black",
                 },
-                ".MuiToggleButton-root:nth-child(odd)": {  # Odd button colors
+                ".MuiToggleButton-root:nth-child(odd)": {  # Style for odd buttons
                     "background-color": "darkgrey",
                     "color": "white",
                 },

+ 36 - 32
taipy/gui/viselements.json

@@ -69,7 +69,7 @@
                     {
                         "name": "on_action",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the button is pressed.<br/>This function is invoked with the following parameters:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>id (str): the identifier of the button it it has one.</li><li>payload (dict): a dictionary that contains the key \"action\" set to the name of the action that triggered this callback.</li></ul>",
+                        "doc": "A function or the name of a function that is triggered when the button is pressed.<br/>This function is invoked with the following parameters:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the identifier of the button it it has one.</li><li><i>payload</i> (dict): a dictionary that contains the key \"action\" set to the name of the action that triggered this callback.</li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -237,7 +237,7 @@
                         "name": "text_anchor",
                         "type": "str",
                         "default_value": "\"bottom\"",
-                        "doc": "When the <i>lov</i> property is used, this property indicates the location of the label.<br/>Possible values are:\n<ul>\n<li>\"bottom\"</li><li>\"top\"</li><li>\"left\"</li><li>\"right\"</li><li>\"none\" (no label is displayed)</li></ul>"
+                        "doc": "When the <i>lov</i> property is used, this property indicates the location of the label.<br/>Possible values are:\n<ul><li>\"bottom\"</li><li>\"top\"</li><li>\"left\"</li><li>\"right\"</li><li>\"none\" (no label is displayed)</li></ul>"
                     },
                     {
                         "name": "labels",
@@ -612,7 +612,7 @@
                     {
                         "name": "on_range_change",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the visible part of the x axis changes.<br/>This function is invoked with the following parameters:<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>id (str): the identifier of the chart control if it has one.</li><li>payload (dict[str, Any]): the full details on this callback's invocation, as emitted by <a href=\"https://plotly.com/javascript/plotlyjs-events/#update-data\">Plotly</a>.</li></ul>",
+                        "doc": "A function or the name of a function that is triggered when the visible part of the x axis changes.<br/>This function is invoked with the following parameters:<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the identifier of the chart control if it has one.</li><li><i>payload</i> (dict[str, Any]): the full details on this callback's invocation, as emitted by <a href=\"https://plotly.com/javascript/plotlyjs-events/#update-data\">Plotly</a>.</li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -632,7 +632,7 @@
                         "name": "columns",
                         "type": "Union[str, list[str], dict[str, dict[str, str]]]",
                         "default_value": "<i>All columns</i>",
-                        "doc": "The list of column names to represent.\n<ul>\n<li>str: ;-separated list of column names</li><li>list[str]: list of names</li><li>dict: {\"column_name\": {format: \"format\", index: 1}} if index is specified, it represents the display order of the columns.\nIf not, the list order defines the index</li></ul><br/>If <i>columns</i> is omitted or set to None, all columns of <i>data</i> are represented."
+                        "doc": "The list of column names to represent.\n<ul><li>str: ;-separated list of column names</li><li>list[str]: list of names</li><li>dict: {\"column_name\": {format: \"format\", index: 1}} if index is specified, it represents the display order of the columns.\nIf not, the list order defines the index</li></ul><br/>If <i>columns</i> is omitted or set to None, all columns of <i>data</i> are represented."
                     },
                     {
                         "name": "label",
@@ -754,7 +754,7 @@
                     {
                         "name": "on_click",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the user clicks in the chart background.<br/>This function is invoked with the following parameters:<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>id (str): the identifier of the chart control if it has one.</li><li>payload (dict[str, Any]): a dictionary containing the <i>x</i> and <i>y</i> coordinates of the click <b>or</b> <i>latitude</i> and <i>longitude</i> in the case of a map. This feature relies on non-public Plotly structured information.</li></ul>",
+                        "doc": "A function or the name of a function that is triggered when the user clicks in the chart background.<br/>This function is invoked with the following parameters:<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the identifier of the chart control if it has one.</li><li><i>payload</i> (dict[str, Any]): a dictionary containing the <i>x</i> and <i>y</i> coordinates of the click <b>or</b> <i>latitude</i> and <i>longitude</i> in the case of a map. This feature relies on non-public Plotly structured information.</li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -832,7 +832,7 @@
                         "name": "columns",
                         "type": "Union[str, list[str], dict[str, dict[str, Union[str, int]]]]",
                         "default_value": "<i>All columns</i>",
-                        "doc": "The list of the column names to display.\n<ul>\n<li>str: semicolon (';')-separated list of column names.</li><li>list[str]: the list of column names.</li><li>dict: a dictionary with entries matching: {\"&lt;column_name&gt;\": {\"format\": \"&lt;format&gt;\", \"index\": 1}}.<br/>\nif <i>index</i> is specified, it represents the display order of this column.\nIf <i>index</i> is not specified, the list order defines the index.<br/>\nIf <i>format</i> is specified, it is used for numbers or dates.</li></ul><br/>If <i>columns</i> is omitted or set to None, all columns of <i>data</i> are represented."
+                        "doc": "The list of the column names to display.\n<ul><li>str: semicolon (';')-separated list of column names.</li><li>list[str]: the list of column names.</li><li>dict: a dictionary with entries matching: {\"&lt;column_name&gt;\": {\"format\": \"&lt;format&gt;\", \"index\": 1}}.<br/>\nif <i>index</i> is specified, it represents the display order of this column.\nIf <i>index</i> is not specified, the list order defines the index.<br/>\nIf <i>format</i> is specified, it is used for numbers or dates.</li></ul><br/>If <i>columns</i> is omitted or set to None, all columns of <i>data</i> are represented."
                     },
                     {
                         "name": "date_format",
@@ -880,7 +880,7 @@
                     {
                         "name": "format_fn[<i>column_name</i>]",
                         "type": "Union[str, Callable]",
-                        "doc": "Defines custom formatting for table cells. This property must be a function or the name of a function that returns a formatted string for each cell.<br/>The function is invoked when the cells in the specified column (<i>column_name</i>) are rendered. It should return a string that represents the cell value to provide the best user experience.<br/>This function is invoked with the following parameters:<ul>  <li><i>state</i> (<code>State^</code>): the state instance.</li>  <li><i>value</i> (Any): the value of the cell.</li>  <li><i>index</i> (int): the index of the row.</li>  <li><i>row</i> (Any): the entire row. The type depends on the type of <i>data</i>.</li>  <li><i>column_name</i> (str): the name of the column.</li></ul>By default, no custom formatting is applied to the column.<br/>For more details, see the <a href=\"#cell-formats\">section</a>.",
+                        "doc": "Defines custom formatting for table cells. This property must be a function or the name of a function that returns a formatted string for each cell.<br/>The function is invoked when the cells in the specified column (<i>column_name</i>) are rendered. It should return a string that represents the cell value to provide the best user experience.<br/>This function is invoked with the following parameters:<ul><li><i>state</i> (<code>State^</code>): the state instance.</li>  <li><i>value</i> (Any): the value of the cell.</li>  <li><i>index</i> (int): the index of the row.</li>  <li><i>row</i> (Any): the entire row. The type depends on the type of <i>data</i>.</li>  <li><i>column_name</i> (str): the name of the column.</li></ul>By default, no custom formatting is applied to the column.<br/>For more details, see the <a href=\"#cell-formats\">section</a>.",
                         "signature": [
                             [
                                 "state",
@@ -975,7 +975,7 @@
                     {
                         "name": "on_add",
                         "type": "Union[bool, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the user requests a row to be added to the table.<br/>This function is invoked with the following parameters:\n<ul>\n<li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>var_name</i> (str): the name of the tabular data variable.</li><li><i>payload</i> (dict): the details on this callback's invocation.<br/>This dictionary has the following key:\n<ul>\n<li><i>index</i> (int): the row index.</li></ul></li></ul><br/>If this property is not set, the table uses the default implementation for adding a new row<br/>If this property is set to False, you cannot add new rows.",
+                        "doc": "A function or the name of a function that is triggered when the user requests a row to be added to the table.<br/>This function is invoked with the following parameters:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>var_name</i> (str): the name of the tabular data variable.</li><li><i>payload</i> (dict): the details on this callback's invocation.<br/>This dictionary has the following key:\n<ul><li><i>index</i> (int): the row index.</li></ul></li></ul><br/>If this property is not set, the table uses the default implementation for adding a new row<br/>If this property is set to False, you cannot add new rows.",
                         "signature": [
                             [
                                 "state",
@@ -995,7 +995,7 @@
                         "name": "on_delete",
                         "type": "Union[bool, Callable]",
                         "default_value": "<i>default implementation</i>",
-                        "doc": "A function or the name of a function triggered when a row is deleted.<br/>This function is invoked with the following parameters:\n<ul>\n<li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>var_name</i> (str): the name of the tabular data variable.</li><li><i>payload</i> (dict): the details on this callback's invocation.<br/>\nThis dictionary has one key:\n<ul>\n<li><i>index</i> (int): the row index.</li></ul></li></ul><br/>If this property is not set, the table uses the default implementation for deleting rows.",
+                        "doc": "A function or the name of a function triggered when a row is deleted.<br/>This function is invoked with the following parameters:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>var_name</i> (str): the name of the tabular data variable.</li><li><i>payload</i> (dict): the details on this callback's invocation.<br/>\nThis dictionary has one key:\n<ul><li><i>index</i> (int): the row index.</li></ul></li></ul><br/>If this property is not set, the table uses the default implementation for deleting rows.",
                         "signature": [
                             [
                                 "state",
@@ -1014,7 +1014,7 @@
                     {
                         "name": "on_action",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the user selects a row.<br/>This function is invoked with the following parameters:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>var_name (str): the name of the tabular data variable.</li><li>payload (dict): the details on this callback's invocation.<br/>This dictionary has the following keys:\n<ul>\n<li>action: the name of the action that triggered this callback.</li><li>index (int): the row index.</li><li>col (str): the column name.</li><li>reason (str): the origin of the action: \"click\", or \"button\" if the cell contains a Markdown link syntax.</li><li>value (str): the <i>link value</i> indicated in the cell when using a Markdown link syntax (that is, <i>reason</i> is set to \"button\").</li></ul></li></ul>.",
+                        "doc": "A function or the name of a function that is triggered when the user selects a row.<br/>This function is invoked with the following parameters:\n<ul><li>state (<code>State^</code>): the state instance.</li><li>var_name (str): the name of the tabular data variable.</li><li>payload (dict): the details on this callback's invocation.<br/>This dictionary has the following keys:\n<ul><li>action: the name of the action that triggered this callback.</li><li>index (int): the row index.</li><li>col (str): the column name.</li><li>reason (str): the origin of the action: \"click\", or \"button\" if the cell contains a Markdown link syntax.</li><li>value (str): the <i>link value</i> indicated in the cell when using a Markdown link syntax (that is, <i>reason</i> is set to \"button\").</li></ul></li></ul>.",
                         "signature": [
                             [
                                 "state",
@@ -1115,7 +1115,7 @@
                     {
                         "name": "selection_message",
                         "type": "dynamic(str)",
-                        "doc": "TODO the message shown in the selection area of a dropdown selector when at least one element is selected, list the selected elements if None."
+                        "doc": "The message shown in the selection area of a dropdown selector when at least one element is selected. If None, the message is the list of all the selected elements."
                     },
                     {
                         "name": "multiple",
@@ -1127,7 +1127,7 @@
                         "name": "show_select_all",
                         "type": "bool",
                         "default_value": "False",
-                        "doc": "TODO If True and multiple, show a select all option"
+                        "doc": "If True and <i>multiple</i> is True, the selector shows a &quot;Select all option&quot; button."
                     },
                     {
                         "name": "filter",
@@ -1161,7 +1161,7 @@
                         "name": "content",
                         "default_property": true,
                         "type": "dynamic(Union[path, file, URL, ReadableBuffer])",
-                        "doc": "The content to transfer.<br/>If this is a string, a URL, or a file, then the content is read from this source.<br/>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 <i>data_url_max_size</i> parameter of the application configuration (which is set to 50kB by default):\n<ul>\n<li>If the buffer size is smaller than this setting, then the raw content is generated as a data URL, encoded using base64 (i.e. <code>\"data:&lt;mimetype&gt;;base64,&lt;data&gt;\"</code>).</li><li>If the buffer size exceeds this setting, then it is transferred through a temporary file.</li></ul>If this property is set to None, that indicates that dynamic content is generated. Please take a look at the examples below for more details on dynamic generation."
+                        "doc": "The content to transfer.<br/>If this is a string, a URL, or a file, then the content is read from this source.<br/>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 <i>data_url_max_size</i> parameter of the application configuration (which is set to 50kB by default):\n<ul><li>If the buffer size is smaller than this setting, then the raw content is generated as a data URL, encoded using base64 (i.e. <code>\"data:&lt;mimetype&gt;;base64,&lt;data&gt;\"</code>).</li><li>If the buffer size exceeds this setting, then it is transferred through a temporary file.</li></ul>If this property is set to None, that indicates that dynamic content is generated. Please take a look at the examples below for more details on dynamic generation."
                     },
                     {
                         "name": "label",
@@ -1171,7 +1171,7 @@
                     {
                         "name": "on_action",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the download is terminated (or on user action if <i>content</i> is None).<br/>This function is invoked with the following parameters:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>id (str): the identifier of the button if it has one.</li><li>payload (dict): the details on this callback's invocation.<br/>\nThis dictionary has two keys:\n<ul>\n<li>action: the name of the action that triggered this callback.</li><li>args: a list of two elements: <i>args[0]</i> reflects the <i>name</i> property and <i>args[1]</i> holds the file URL.</li></ul></li></ul>",
+                        "doc": "A function or the name of a function that is triggered when the download is terminated (or on user action if <i>content</i> is None).<br/>This function is invoked with the following parameters:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the identifier of the button if it has one.</li><li><i>payload</i> (dict): the details on this callback's invocation.<br/>\nThis dictionary has two keys:\n<ul><li><i><i>action:</i>: the name of the action that triggered this callback.</li><li><i>args</i>: a list of two elements: <i>args[0]</i> reflects the <i>name</i> property and <i>args[1]</i> holds the file URL.</li></ul></li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -1241,7 +1241,7 @@
                     {
                         "name": "on_action",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that will be triggered.<br/>This function is invoked with the following parameters:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>id (str): the identifier of the button if it has one.</li><li>payload (dict): a dictionary that contains the key \"action\" set to the name of the action that triggered this callback.</li></ul>",
+                        "doc": "A function or the name of a function that will be triggered.<br/>This function is invoked with the following parameters:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the identifier of the button if it has one.</li><li><i>payload</i> (dict): a dictionary that contains the key \"action\" set to the name of the action that triggered this callback.</li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -1308,7 +1308,7 @@
                         "name": "content",
                         "default_property": true,
                         "type": "dynamic(Union[path, file, URL, ReadableBuffer])",
-                        "doc": "The image source.<br/>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 <i>data_url_max_size</i> parameter of the application configuration (which is set to 50kB by default):\n<ul>\n<li>If the size of the buffer is smaller than this setting, then the raw content is generated as a\n  data URL, encoded using base64 (i.e. <code>\"data:&lt;mimetype&gt;;base64,&lt;data&gt;\"</code>).</li><li>If the size of the buffer is greater than this setting, then it is transferred through a temporary\n  file.</li></ul>"
+                        "doc": "The image source.<br/>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 <i>data_url_max_size</i> parameter of the application configuration (which is set to 50kB by default):\n<ul><li>If the size of the buffer is smaller than this setting, then the raw content is generated as a\n  data URL, encoded using base64 (i.e. <code>\"data:&lt;mimetype&gt;;base64,&lt;data&gt;\"</code>).</li><li>If the size of the buffer is greater than this setting, then it is transferred through a temporary\n  file.</li></ul>"
                     },
                     {
                         "name": "label",
@@ -1318,7 +1318,7 @@
                     {
                         "name": "on_action",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the user clicks on the image.<br/>This function is invoked with the following parameters:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>id (str): the identifier of the button if it has one.</li><li>payload (dict): a dictionary that contains the key \"action\" set to the name of the action that triggered this callback.</li></ul>",
+                        "doc": "A function or the name of a function that is triggered when the user clicks on the image.<br/>This function is invoked with the following parameters:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the identifier of the button if it has one.</li><li><i>payload</i> (dict): a dictionary that contains the key \"action\" set to the name of the action that triggered this callback.</li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -1365,7 +1365,7 @@
                         "name": "type",
                         "default_value": "\"circular\"",
                         "type": "str",
-                        "doc": "The type of the gauge.<br/>Possible values are:\n<ul>\n<li>\"none\"</li><li>\"circular\"</li><li>\"linear\"</li></ul>Setting this value to \"none\" remove the gauge."
+                        "doc": "The type of the gauge.<br/>Possible values are:\n<ul><li>\"none\"</li><li>\"circular\"</li><li>\"linear\"</li></ul>Setting this value to \"none\" remove the gauge."
                     },
                     {
                         "name": "min",
@@ -1498,7 +1498,7 @@
                         "name": "title_anchor",
                         "type": "str",
                         "default_value": "\"bottom\"",
-                        "doc": "The anchor of the title.<br/>Possible values are:\n<ul>\n<li>\"bottom\"</li><li>\"top\"</li><li>\"left\"</li><li>\"right\"</li><li>\"none\" (no title is displayed)</li></ul>"
+                        "doc": "The anchor of the title.<br/>Possible values are:\n<ul><li>\"bottom\"</li><li>\"top\"</li><li>\"left\"</li><li>\"right\"</li><li>\"none\" (no title is displayed)</li></ul>"
                     },
                     {
                         "name": "render",
@@ -1597,7 +1597,7 @@
                     {
                         "name": "on_action",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when a menu option is selected.<br/><br/>This function is invoked with the following parameters:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>id (str): the identifier of the button, if it has one.</li><li>payload (dict): a dictionary containing details about the callback invocation, with the following keys:<ul>\n<li>action: the name of the action that triggered this callback.</li><li>args: a list where the first element contains the identifier of the selected option.</li></ul></li></ul>",
+                        "doc": "A function or the name of a function that is triggered when a menu option is selected.<br/><br/>This function is invoked with the following parameters:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the identifier of the button, if it has one.</li><li><i>payload</i> (dict): a dictionary containing details about the callback invocation, with the following keys:<ul><li><i>action:</i>: the name of the action that triggered this callback.</li><li><i>args</i>: a list where the first element contains the identifier of the selected option.</li></ul></li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -1662,7 +1662,7 @@
                         "name": "lov",
                         "default_property": true,
                         "type": "dict[str, Any]",
-                        "doc": "The list of pages. The keys should be:\n<ul>\n<li>page id (start with \"/\")</li><li>or full URL</li></ul>\nThe values are labels. See the <a href=\"../../../../../userman/gui/binding/#list-of-values\">section on List of Values</a> for more details."
+                        "doc": "The list of pages. The keys should be:\n<ul><li><i>page id</i> (start with \"/\")</li><li>or full URL</li></ul>\nThe values are labels. See the <a href=\"../../../../../userman/gui/binding/#list-of-values\">section on List of Values</a> for more details."
                     }
                 ]
             }
@@ -1723,9 +1723,9 @@
                     },
                     {
                         "name": "use_icon",
-                        "type": "indexed(Union[bool,str])",
+                        "type": "indexed(Union[bool, str])",
                         "default_value": "False",
-                        "doc": "TODO If True, status shows a predefined icon. A string shows as svg content (URL or element). Key from \"info\", \"success\", \"warning\", \"error\"."
+                        "doc": "TODO If True, the status control shows a predefined icon. A string shows as svg content (URL or element). Key from \"info\", \"success\", \"warning\", \"error\"."
                     }
                 ]
             }
@@ -1747,7 +1747,7 @@
                     {
                         "name": "on_action",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the dialog button is pressed.<br/><br/>This function is invoked with the following parameters:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>id (str): the identifier of the button if it has one.</li><li>payload (dict): the details on this callback's invocation.<br/>\nThis dictionary has the following keys:\n<ul>\n<li>action: the name of the action that triggered this callback.</li><li>args: a list with three elements:\n<ul><li>The first element is the username</li><li>The second element is the password</li><li>The third element is the current page name</li></ul></li></li></ul></li></ul><br/>When the button is pressed, and if this property is not set, Taipy will try to find a callback function called <i>on_login()</i> and invoke it with the parameters listed above.",
+                        "doc": "A function or the name of a function that is triggered when the dialog button is pressed.<br/><br/>This function is invoked with the following parameters:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the identifier of the button if it has one.</li><li><i>payload</i> (dict): the details on this callback's invocation.<br/>This dictionary has the following keys:\n<ul><li><i>action:</i>: the name of the action that triggered this callback.</li><li><i>args:</i>: a list with three elements:\n<ul><li>The first element is the username</li><li>The second element is the password</li><li>The third element is the current page name</li></ul></li></li></ul></li></ul><br/>When the button is pressed, and if this property is not set, Taipy will try to find a callback function called <i>on_login()</i> and invoke it with the parameters listed above.",
                         "signature": [
                             [
                                 "state",
@@ -1811,7 +1811,7 @@
                     {
                         "name": "on_action",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the user enters a new message.<br/>This function is invoked with the following parameters:<ul>\n<li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>var_name</i> (str): the name of the variable bound to the <i>messages</i> property.</li><li><i>payload</i> (dict): the details on this callback's invocation.<br/>This dictionary has the following keys:\n<ul>\n<li><i>action</i>: the name of the action that triggered this callback.</li><li><i>args</i> (list): a list composed of a reason (\"click\" or \"Enter\"), the variable name, the message, and the user identifier of the sender.</li></ul></li></ul>",
+                        "doc": "A function or the name of a function that is triggered when the user enters a new message.<br/>This function is invoked with the following parameters:<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>var_name</i> (str): the name of the variable bound to the <i>messages</i> property.</li><li><i>payload</i> (dict): the details on this callback's invocation.<br/>This dictionary has the following keys:\n<ul><li><i>action</i>: the name of the action that triggered this callback.</li><li><i>args</i> (list): a list composed of a reason (\"click\" or \"Enter\"), the variable name, the message, and the user identifier of the sender.</li></ul></li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -1860,7 +1860,7 @@
                         "name": "allow_send_images",
                         "type": "bool",
                         "default_value": "True",
-                        "doc": "TODO if True, an upload image icon is shown."
+                        "doc": "If False, the &quot;Upload image&quot; button is hidden."
                     }
                 ]
             }
@@ -1989,7 +1989,7 @@
                     {
                         "name": "on_action",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function triggered when a button is pressed.<br/>This function is invoked with the following parameters:<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>id (str): the identifier of the dialog if it has one.</li><li>payload (dict): the details on this callback's invocation.<br/>This dictionary has the following keys:\n<ul>\n<li>action: the name of the action that triggered this callback.</li><li>args: a list where the first element contains the index of the selected label.</li></ul></li></ul>",
+                        "doc": "A function or the name of a function triggered when a button is pressed.<br/>This function is invoked with the following parameters:<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the identifier of the dialog if it has one.</li><li><i>payload</i> (dict): the details on this callback's invocation.<br/>This dictionary has the following keys:\n<ul><li><i>action:</i>: the name of the action that triggered this callback.</li><li><i>args:</i>: a list where the first element contains the index of the selected label.</li></ul></li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -2026,7 +2026,11 @@
                         "type": "Union[str,int,float]",
                         "doc": "The height of the dialog, in CSS units."
                     },
-                    {"name": "ref_id", "type": "dynamic(str)", "doc": "TODO an id or a query selector that allows to identify an HTML component that would be the anchor for the dialog."}
+                    {
+			"name": "ref_id",
+			"type": "dynamic(str)",
+			"doc": "The id of an HTML element or a query selector that identifies the reference element serving as the anchor for the dialog."
+		    }
                 ]
             }
         ],
@@ -2042,7 +2046,7 @@
                         "default_property": true,
                         "type": "str",
                         "default_value": "\"1 1\"",
-                        "doc": "The list of weights for each column.<br/>For example, \"1 2\" creates a 2 column grid:\n<ul>\n<li>1fr</li><li>2fr</li></ul><br/>The creation of multiple same size columns can be simplified by using the multiply sign eg. \"5*1\" is equivalent to \"1 1 1 1 1\"."
+                        "doc": "The list of weights for each column.<br/>For example, \"1 2\" creates a 2 column grid:\n<ul><li>1fr</li><li>2fr</li></ul><br/>The creation of multiple same size columns can be simplified by using the multiply sign eg. \"5*1\" is equivalent to \"1 1 1 1 1\"."
                     },
                     {
                         "name": "columns[mobile]",
@@ -2079,7 +2083,7 @@
                     {
                         "name": "on_close",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when this pane is closed (if the user clicks outside of it or presses the Esc key).<br/>This function is invoked with the following parameters:<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>id (Optional[str]): the identifier of the <i>close</i> button if it has one.</li></ul><br/>If this property is not set, no function is called when this pane is closed.",
+                        "doc": "A function or the name of a function that is triggered when this pane is closed (if the user clicks outside of it or presses the Esc key).<br/>This function is invoked with the following parameters:<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (Optional[str]): the identifier of the <i>close</i> button if it has one.</li></ul><br/>If this property is not set, no function is called when this pane is closed.",
                         "signature": [
                             [
                                 "state",
@@ -2185,7 +2189,7 @@
                     {
                         "name": "on_change",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the value changes.<br/>The callback function receives the following parameters:<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>var_name (str): the bound variable name.</li><li>value (Any): the updated value.</li></ul>",
+                        "doc": "A function or the name of a function that is triggered when the value changes.<br/>The callback function receives the following parameters:<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>var_name</i> (str): the bound variable name.</li><li><i>value</i> (Any): the updated value.</li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -2251,7 +2255,7 @@
                     {
                         "name": "on_action",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when a specific key is pressed.<br/>The callback function is invoked with the following parameters:<ul>\n<li>state (<code>State^</code>): the state instance.</li><li>id (str): the identifier of the control if it has one.</li><li>payload (dict): the callback details<br/>\nThis dictionary has the following keys:\n<ul>\n<li>action: the name of the action that triggered this callback.</li><li>args (list):\n<ul><li>The key name pressed.</li><li>The variable name.</li><li>The current value of the variable.</li></ul></li></ul></li></ul>",
+                        "doc": "A function or the name of a function that is triggered when a specific key is pressed.<br/>The callback function is invoked with the following parameters:<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the identifier of the control if it has one.</li><li><i>payload</i> (dict): the callback details<br/>This dictionary has the following keys:\n<ul><li><i>action:</i>: the name of the action that triggered this callback.</li><li><i>args</i> (list):\n<ul><li><i>[0]</i>: The key name pressed.</li><li><i>[1]</i>: The variable name.</li><li><i>[2]</i>: The current value of the variable.</li></ul></li></ul></li></ul>",
                         "signature": [
                             [
                                 "state",

+ 7 - 7
taipy/gui_core/viselements.json

@@ -70,7 +70,7 @@
                     {
                         "name": "on_change",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the value is updated.<br/>The parameters of that function are all optional:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li>\n<li>var_name (str): the variable name.</li>\n<li>value (<code>Scenario^</code>): the selected scenario.</li>\n</ul>",
+                        "doc": "A function or the name of a function that is triggered when the value is updated.<br/>The parameters of that function are all optional:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>var_name</i> (str): the variable name.</li><li><i>value</i> (<code>Scenario^</code>): the selected scenario.</li>\n</ul>",
                         "signature": [
                             [
                                 "state",
@@ -95,7 +95,7 @@
                     {
                         "name": "on_creation",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when a scenario is about to be created.<br/><br/>All the parameters of that function are optional:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li>\n<li>id (str): the identifier of this scenario selector.</li>\n<li>payload (dict): the details on this callback's invocation.<br/>\nThis dictionary has the following keys:\n<ul>\n<li>config (str): the name of the selected scenario configuration.</li>\n<li>date (datetime): the creation date for the new scenario.</li>\n<li>label (str): the user-specified label.</li>\n<li>properties (dict): a dictionary containing all the user-defined custom properties.</li>\n</ul>\n</li>\n<li>The callback function can return a scenario, a string containing an error message (a scenario will not be created), or None (then a new scenario is created with the user parameters).</li>\n</ul>",
+                        "doc": "A function or the name of a function that is triggered when a scenario is about to be created.<br/><br/>All the parameters of that function are optional:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the identifier of this scenario selector.</li><li><i>payload</i> (dict): the details on this callback's invocation.<br/>This dictionary has the following keys:\n<ul><li><i>config</i> (str): the name of the selected scenario configuration.</li><li><i>date</i> (datetime): the creation date for the new scenario.</li><li><i>label</i> (str): the user-specified label.</li><li><i>properties</i> (dict): a dictionary containing all the user-defined custom properties.</li></ul>\n</li>\n<li>The callback function can return a scenario, a string containing an error message (a scenario will not be created), or None (then a new scenario is created with the user parameters).</li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -208,7 +208,7 @@
                     {
                         "name": "on_submission_change",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when a submission status is changed.<br/><br/>All the parameters of that function are optional:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li>\n<li>submission (Submission): the submission entity containing submission information.</li>\n<li>details (dict): the details on this callback's invocation.<br/>\nThis dictionary has the following keys:\n<ul>\n<li>submission_status (str): the new status of the submission (possible values are: \"SUBMITTED\", \"COMPLETED\", \"CANCELED\", \"FAILED\", \"BLOCKED\", \"WAITING\", or \"RUNNING\").</li>\n<li>job: the Job (if any) that is at the origin of the submission status change.</li>\n<li>submittable_entity (Submittable): the entity (usually a Scenario) that was submitted.</li></ul></ul>",
+                        "doc": "A function or the name of a function that is triggered when a submission status is changed.<br/><br/>All the parameters of that function are optional:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>submission</i> (Submission): the submission entity containing submission information.</li><li><i>details</i> (dict): the details on this callback's invocation.<br/>This dictionary has the following keys:\n<ul><li><i>submission_status</i> (str): the new status of the submission (possible values are: \"SUBMITTED\", \"COMPLETED\", \"CANCELED\", \"FAILED\", \"BLOCKED\", \"WAITING\", or \"RUNNING\").</li>\n<li><i>job:</i>: the Job (if any) that is at the origin of the submission status change.</li>\n<li><i>submittable_entity</i> (Submittable): the entity (usually a Scenario) that was submitted.</li></ul></ul>",
                         "signature": [
                             [
                                 "state",
@@ -267,7 +267,7 @@
                     {
                         "name": "on_action",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when a a node is selected.<br/><br/>All the parameters of that function are optional:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li>\n<li>entity (DataNode or Task): the entity that was selected.</li>\n</ul>",
+                        "doc": "A function or the name of a function that is triggered when a a node is selected.<br/><br/>All the parameters of that function are optional:\n<ul>\n<li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>entity</i> (DataNode or Task): the entity that was selected.</li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -350,7 +350,7 @@
                     {
                         "name": "on_change",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when a data node is selected.<br/>The parameters of that function are all optional:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li>\n<li>var_name (str): the variable name.</li>\n<li>value (<code>DataNode^</code>): the selected data node.</li>\n</ul>",
+                        "doc": "A function or the name of a function that is triggered when a data node is selected.<br/>The parameters of that function are all optional:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>var_name</i> (str): the variable name.</li><li><i>value</i> (<code>DataNode^</code>): the selected data node.</li>\n</ul>",
                         "signature": [
                             [
                                 "state",
@@ -531,7 +531,7 @@
                     {
                         "name": "on_change",
                         "type": "Union[str, Callable]",
-                        "doc": "A function or the name of a function that is triggered when the selection is updated.<br/>The parameters of that function are all optional:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li>\n<li>var_name (str): the variable name.</li>\n<li>value (<code>Job^</code>): the selected job.</li>\n</ul>",
+                        "doc": "A function or the name of a function that is triggered when the selection is updated.<br/>The parameters of that function are all optional:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>var_name</i> (str): the variable name.</li>\n<li><i>value</i> (<code>Job^</code>): the selected job.</li></ul>",
                         "signature": [
                             [
                                 "state",
@@ -556,7 +556,7 @@
                     {
                         "name": "on_details",
                         "type": "Union[str, Callable, bool]",
-                        "doc": "The name of a function that is triggered when the details icon is pressed.<br/>The parameters of that function are all optional:\n<ul>\n<li>state (<code>State^</code>): the state instance.</li>\n<li>id (str): the id of the control.</li>\n<li>payload (<code>dict</code>): a dictionary that contains the Job Id in the value for key <i>args</i>.</li>\n</ul></br>If False, the icon is not shown.",
+                        "doc": "The name of a function that is triggered when the details icon is pressed.<br/>The parameters of that function are all optional:\n<ul><li><i>state</i> (<code>State^</code>): the state instance.</li><li><i>id</i> (str): the id of the control.</li><li><i>payload</i> (<code>dict</code>): a dictionary that contains the Job id in the value for key <i>args</i>.</li></ul></br>If False, the icon is not shown.",
                         "signature": [
                             [
                                 "state",

+ 7 - 4
tools/coverage_check.py

@@ -55,10 +55,13 @@ def check_changed_files_coverage(coverage_file, changed_files, threshold=80):
         else:
             print(f"No coverage data found for {file}")
 
-    if sum_coverage/qty < threshold:
-        print(f"Coverage for changed files is below {threshold}%: {sum_coverage/qty:.2f}%")
-        sys.exit(1)
-    print(f"Coverage for changed files: {sum_coverage/qty:.2f}%")
+    if qty:
+        if sum_coverage/qty < threshold:
+            print(f"Coverage for changed files is below {threshold}%: {sum_coverage/qty:.2f}%")
+            sys.exit(1)
+        print(f"Coverage for changed files: {sum_coverage/qty:.2f}%")
+    else:
+        print("No file detected to run coverage for.")
 
 
 def get_changed_files(base_branch):

+ 30 - 1
tools/gui/generate_pyi.py

@@ -22,11 +22,30 @@ __RE_INDEXED_PROPERTY = re.compile(r"^([\w_]+)\[(<\w+>)?([\w]+)(</\w+>)?\]$")
 # Script should be located in <taipy_root>/tools
 script_dir = os.path.dirname(os.path.realpath(__file__))
 # Move to <taipy_root>
-os.chdir(os.path.dirname(os.path.dirname(script_dir)))
+root_dir = os.path.dirname(os.path.dirname(script_dir))
+os.chdir(root_dir)
 # Make sure we can import the mandatory packages
 if not os.path.isdir(os.path.abspath(os.path.join(script_dir, "taipy"))):
     sys.path.append(os.path.abspath(os.path.join(script_dir, os.pardir, os.pardir)))
 
+# Classes package
+classes_xrefs = {
+    "Cycle": "core",
+    "DataNode": "core",
+    "Job": "core",
+    "Scenario": "core",
+    "Sequence": "core",
+    "State": "gui",
+}
+# Read package version - Point to 'develop' branch if 'ext' is not null
+reference_url = "https://docs.taipy.io/en/[BRANCH]/refmans/reference/pkg_taipy/"
+with open(os.path.join(os.path.join(root_dir, "taipy", "version.json"))) as version_file:
+    version = json.load(version_file)
+    branch = "develop"
+    if not version.get("ext"):
+        branch = f"release-{version.get('major', 0)}.{version.get('minor', 0)}"
+    reference_url = reference_url.replace("[BRANCH]", branch)
+
 # ##################################################################################################
 # Generate gui pyi file (gui/gui.pyi)
 # ##################################################################################################
@@ -193,6 +212,14 @@ def format_as_parameter(property: Dict[str, str], element_name: str):
     return f"{name}{type}{default_value}"
 
 
+
+def replace_ref_xref(match: re.Match) -> str:
+    if package := classes_xrefs.get(match[1]):
+        return ("<a href=\"" + reference_url + "/".join([f"pkg_{p}" for p in package.split(".")])
+                + f"/{match[1]}/\">" + match[1] + "</a>")
+    else:
+        return match[0]
+
 def build_doc(name: str, desc: Dict[str, Any]):
     if "doc" not in desc:
         return ""
@@ -212,6 +239,8 @@ def build_doc(name: str, desc: Dict[str, Any]):
     # Link anchors # signs are prefixed with a \
     doc = re.sub(r"\\(#[a-z_]+\))", r"\1", doc)
     doc = re.sub(r"(?:\s+\\n)?\s+See below(?:[^\.]*)?\.", "", doc).replace("\n", "\\n")
+    # External links
+    doc = re.sub(r"`(\w+)\^`", replace_ref_xref, doc)
     return f"{desc['name']}{desc['dynamic']}{desc['indexed']}\\n  {doc}\\n\\n"