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

Revamping the "Understanding GUI" tutorial #1232

Merged
merged 16 commits into from
Jan 10, 2025
Merged

Conversation

AlexandreSajus
Copy link
Contributor

This is a work in progress:

  • Please review and share what you think needs to be edited or added
  • Some links need to be updated as they link to my personal GitHub and YouTube accounts instead of Avaiga
  • I would also be open to expanding this tutorial to authentication and deployment if that makes sense, as they are Enterprise features

screen1

This tutorial intends to replace the "Understanding GUI" tutorial and should be the first tutorial users follow after the "Getting Started".

screen4

The tutorial worked well when training new customers, so it would be appropriate to include it in the docs. It creates a simple sales dashboard by focusing on visual elements, styling, charts, and multiple pages.

screen3

The tutorial is also available in video format on YouTube

screen2

@AlexandreSajus AlexandreSajus added 📈 Improvement Improvement of a feature. 📄 Documentation Internal or public documentation 🟨 Priority: Medium Not blocking but should be fixed soon labels Dec 11, 2024
@AlexandreSajus AlexandreSajus self-assigned this Dec 11, 2024
}
```

This will add a margin to the top of the button to align it with the filters.
Copy link
Member

Choose a reason for hiding this comment

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

I think this will be now resolved in develop

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is not the case for this one. The margin is a big one to align the widgets
image

develop will probably force me to change the margin pixel value though. Is there a better way to align the button to the other widgets?

Copy link
Member

Choose a reason for hiding this comment

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

Is this done with develop?

.reset_index()
)

layout = {"yaxis": {"title": "Revenue (USD)"}, "title": "Sales by State"}
Copy link
Member

Choose a reason for hiding this comment

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

I think these properties are already exposed yaxis and title. We should use them. What do you think?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Indeed, I'm pushing a commit for this

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Actually, yaxis and title do not seem to work. I'm creating an issue on this

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@FlorianJacta
Copy link
Member

FlorianJacta commented Dec 12, 2024

I like this tutorial as this is easy and straight to the point. I like it. It is missing from Understand Gui some info but I don't how important it is:

  • what is the state
  • indexed properties
  • Python expressions
  • references to the user man

The tutorial should also be proposed in Markdown.

@github-actions github-actions bot added the 🥶Waiting for contributor Issues or PRs waiting for a long time label Dec 26, 2024
@AlexandreSajus AlexandreSajus added 🔒 Staff only Restricted to CC staff members and removed 🥶Waiting for contributor Issues or PRs waiting for a long time labels Dec 26, 2024
@Avaiga Avaiga deleted a comment from github-actions bot Dec 26, 2024
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.

Nice job though!

type="bar",
layout="{layout}",
)
tgb.chart(figure="{map_fig}")
Copy link
Member

Choose a reason for hiding this comment

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

As I said hundreds of times.
It is a bad idea to rely on figures. That does not provide the data management capabilities of Taipy GUI, and breaks the added value compared to competitors.
If things need to be improved on the chart side, please let R&D know.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The example I give is relevant: the map I create is really difficult to create using Taipy charts so I use a Plotly one. I used Taipy charts for the other charts.

We need to introduce this feature to prove that it is easy to create good looking charts using figure=. If you want I can put a disclaimer that this is not the optimal way to create charts.

lov="{subcategories}",
dropdown=True,
)
with tgb.part(class_name="text-center"):
Copy link
Member

Choose a reason for hiding this comment

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

Why do you need a part if there's only one element?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Parts are a good way to visually separate in the code the contents of different columns. Also here I use part to center the button horizontally. Is there another way to center the button without using part nor CSS?

Let's now add a new container for the filters:

```python
with tgb.part(class_name="card"):
Copy link
Member

Choose a reason for hiding this comment

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

Why a part if there's only a block?
Why all those parts all over the place??

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Parts are a good way to visually separate in the code the contents of different parts of the app

@@ -30,6 +30,12 @@ nav:
- "5 - Python expressions in properties": tutorials/articles/understanding_gui/step_05/step_05.md
- "6 - Page layouts": tutorials/articles/understanding_gui/step_06/step_06.md
- "7 - Multi-pages, navbars, and menus": tutorials/articles/understanding_gui/step_07/step_07.md
Copy link
Member

Choose a reason for hiding this comment

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

I thought the purpose was to replace the "Understanding GUI" tutorial. Here you just added a new one.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah, I was not sure if you guys would agree to replace the "Understanding GUI" tutorial so for the time I put it separately. When I'm done with the requested changes and if everyone agrees, this tutorial will replace "Understanding GUI"

@AlexandreSajus
Copy link
Contributor Author

Note: I should deploy this application so that people can try the application before even doing the tutorial

@AlexandreSajus
Copy link
Contributor Author

I have implemented most of the requested changes, and the PR is now ready to be merged. Please review it again and let me know if additional changes need to be made.

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.

🫤

@FabienLelaquais FabienLelaquais self-requested a review January 10, 2025 14:35
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.

👌

@AlexandreSajus AlexandreSajus merged commit db6ad38 into develop Jan 10, 2025
1 check passed
@AlexandreSajus AlexandreSajus deleted the new-first-tutorial branch January 10, 2025 14:36
AlexandreSajus added a commit that referenced this pull request Jan 10, 2025
Revamping the "Understanding GUI" tutorial
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📄 Documentation Internal or public documentation 📈 Improvement Improvement of a feature. 🟨 Priority: Medium Not blocking but should be fixed soon 🔒 Staff only Restricted to CC staff members
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants