Comments (4)
I could replicate this issue
from taipy.
The problem comes from the fact that for this visual element, the first property is not value so the visual element is not properly bound. This is indeed not intended.
Try with this code:
import taipy.gui as tg
import taipy.gui.builder as tgb
def my_on_change(state: tg.State, var_name: str, var_value) -> None:
print("Value changed!")
print(f"var_name: {var_name}, var_value: {var_value}")
value = "Item 1"
with tgb.Page() as page:
tgb.tree(
value="{value}",
lov="Item 1;Item 2;Item 3",
on_change=my_on_change,
)
tg.Gui(page=page).run(port=5001)
Everything should work fine.
This should have been fixed with this issue already: #994
Can you confirm @dinhlongviolin1 ?
from taipy.
Ah I see, but then docs should be updated since they assume value is the first argument
from taipy.
Yes, it should be the first argument. The docs are correct, and not the code itself. It comes from how the TGB syntax was created incorrectly for this visual element. It has already been fixed but is not released yet
from taipy.
Related Issues (20)
- Scenario selector - Search bar HOT 4
- Issue template improvement
- [Feature] Support polars in your ParquetDataNode (or maybe some sort of dataset abstraction?) HOT 1
- Chat control should support images
- [🐛 BUG] tgb.toggle("{value}") does not work but tgb.toggle(value="{value}") works HOT 2
- Scenario Selector "Search" UX HOT 3
- [OTHER] How to Contribute to the Frontend of Taipy HOT 4
- Analytics: Use remote default favicon HOT 1
- Scenario selector - Make the filter and sort persistent
- [Refactor] Default stylekit applies too much margin to text HOT 4
- [DOCS] How to stop/ shutdown taipy gracefully without a long traceback? HOT 2
- [🐛 BUG] Chart disappears after a change HOT 4
- [🐛 BUG] Screenshot in Markdown issue report and no response
- Make TaiPy GUI search and run local on_init(state) functions HOT 1
- [🐛 BUG] Interoperability with Dataiku
- [Refactor] Scenario Selector - Default filters should be consistent with config HOT 1
- Evaluate feasibility - Polars exposed type.
- Updating stylekitcss and hover_text for metric component
- [🐛 BUG] <center> tag not working in Markdown files HOT 2
- [Refactor] Data Node Selector - Default filters should be consistent with config HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from taipy.