Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle bound var theme toggle (#1492) #2363

Merged
merged 2 commits into from
Dec 23, 2024

Conversation

dinhlongviolin1
Copy link
Member

Resolve #1492

from taipy.gui import Gui


def on_change(state, var, val):
    print(var, val)


isDark = True

gui = Gui("<|{isDark}|toggle|theme|>")

gui.run(run_browser=True)

@dinhlongviolin1 dinhlongviolin1 added 🖰 GUI Related to GUI 🟩 Priority: Low Low priority and doesn't need to be rushed ✨New feature 📝Release Notes Impacts the Release Notes or the Documentation in general labels Dec 23, 2024
@dinhlongviolin1 dinhlongviolin1 self-assigned this Dec 23, 2024
Copy link
Contributor

github-actions bot commented Dec 23, 2024

Coverage report for ./frontend/taipy

Caution

Coverage does not meet threshold
Statements coverage not met for global: expected >=80%, but got 51.87376725838264%

St.
Category Percentage Covered / Total
🔴 Statements 51.87% 263/507
🔴 Branches 21.61% 67/310
🔴 Functions 14.66% 17/116
🔴 Lines 53.19% 242/455

Test suite run success

7 tests passing in 1 suite.

Report generated by 🧪jest coverage report action from 158dd26

Copy link
Contributor

github-actions bot commented Dec 23, 2024

☂️ Python Coverage

current status: ✅

Overall Coverage

Lines Covered Coverage Threshold Status
19471 16975 87% 0% 🟢

New Files

No new covered files...

Modified Files

No covered modified files...

updated for commit: 158dd26 by action🐍

FredLL-Avaiga
FredLL-Avaiga previously approved these changes Dec 23, 2024
Copy link
Member

@FredLL-Avaiga FredLL-Avaiga left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Easy for you

Copy link
Member

@FabienLelaquais FabienLelaquais left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks so easy indeed.

taipy/gui/viselements.json Outdated Show resolved Hide resolved
Co-authored-by: Fabien Lelaquais <[email protected]>
@dinhlongviolin1 dinhlongviolin1 merged commit c9aff0e into develop Dec 23, 2024
61 checks passed
@dinhlongviolin1 dinhlongviolin1 deleted the feature/#1492-theme-toggle-mode branch December 23, 2024 08:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🖰 GUI Related to GUI ✨New feature 🟩 Priority: Low Low priority and doesn't need to be rushed 📝Release Notes Impacts the Release Notes or the Documentation in general
Projects
None yet
Development

Successfully merging this pull request may close these issues.

User theme (light or dark mode) should be an accessible variable
3 participants