浏览代码

add note about stopEditingWhenCellsLoseFocus

Falko Schindler 1 年之前
父节点
当前提交
96796e9a22
共有 1 个文件被更改,包括 6 次插入0 次删除
  1. 6 0
      nicegui/elements/aggrid.py

+ 6 - 0
nicegui/elements/aggrid.py

@@ -87,6 +87,9 @@ class AgGrid(Element):
 
         See `AG Grid API <https://www.ag-grid.com/javascript-data-grid/accessing-data/>`_ for more information.
 
+        Note that when editing a cell, the row data is not updated until the cell exits the edit mode.
+        This does not happen when the cell loses focus, unless ``stopEditingWhenCellsLoseFocus: True`` is set.
+
         :return: list of row data
         """
         result = await run_javascript(f'''
@@ -100,6 +103,9 @@ class AgGrid(Element):
         """Obtain client data and update the element's row data with it.
 
         This syncs edits made by the client in editable cells to the server.
+
+        Note that when editing a cell, the row data is not updated until the cell exits the edit mode.
+        This does not happen when the cell loses focus, unless ``stopEditingWhenCellsLoseFocus: True`` is set.
         """
         client_row_data = await self.get_client_data()
         self.options['rowData'] = client_row_data