diff --git a/_collection-base/08-visualization/02-graphs/02-python/03-intro-to-dash-widgets.md b/_collection-base/08-visualization/02-graphs/02-python/03-intro-to-dash-widgets.md index a324aea..d9ac6d3 100644 --- a/_collection-base/08-visualization/02-graphs/02-python/03-intro-to-dash-widgets.md +++ b/_collection-base/08-visualization/02-graphs/02-python/03-intro-to-dash-widgets.md @@ -168,7 +168,7 @@ if __name__ == '__main__': app.run(debug=True) ``` -
What the code does? +
What the script does? *This setup creates a basic interactive web application with a title and a placeholder for a graph.* The provided code: @@ -202,7 +202,7 @@ Dash components are the building blocks of Dash application layout, enabling you These components are integrated into the layout of a Dash application to create a user interface that responds dynamically to user interactions. *For example, a dropdown component can store options that filter or switch data on a plot interactively when selected by a user.* types of dash components -Figure 2. Examples of Dash widgets for interactive web applications, including Core, HTM and Bootstrap components. +Examples of Dash widgets for interactive web applications, including Core, HTM and Bootstrap components. **Dash modules and example components** @@ -220,26 +220,26 @@ These components are integrated into the layout of a Dash application to create The `html` module in Dash provides a suite of components that mirror standard HTML elements, enabling you to structure the layout of your Dash application. These components include headings, paragraphs, divs, etc. They allow you to create a well-organized and visually appealing interface.
-Each Dash HTML component formats and displays text or other content in a specific way, helping to arrange and organize visual elements on the app's page. For example, a heading component makes text appear larger and bolder, while a division component groups selected elements together. +Each Dash HTML component **formats and displays text** or other content in a specific way, helping to arrange and **organize visual elements** on the app's page. For example, a `heading` component makes text appear larger and bolder, while a division component groups selected elements together.
**Commonly used HTML components** | component | description | example instance | rendering | |---------------|---------------------------|------------------------------------------|-----------| -| `html.H1` | main heading (h1) | `html.H1('Title of Dash App')` |

Title of Dash App

| -| `html.H2` | secondary heading (h2) | `html.H2('Subtitle')` |

Subtitle

| -| `html.Div` | division or section (div) | `html.Div(children='content goes here')` |
Content goes here
| -| `html.P` | paragraph (p) | `html.P('This is a paragraph.')` |

This is a paragraph.

| +| `html.H1` | main heading (h1) | `html.H1('Title of Dash App')` | Title of Dash App | +| `html.H2` | secondary heading (h2) | `html.H2('Subtitle')` | Subtitle | +| `html.Div` | division or section (div) | `html.Div(children='content goes here')` | content goes here | +| `html.P` | paragraph (p) | `html.P('This is a paragraph.')` | This is a paragraph. | | `html.Span` | inline container (span) | `html.Span('This is a span.')` | This is a span. | | `html.A` | hyperlink (a) | `html.A('Link Text', href='https://dash.plotly.com/')` | Link Text | | `html.Img` | image (img) | `html.Img(src='path/to/image.jpg')` | | -| `html.Button` | button (button) | `html.Button('Click Me', id='button')` | | -| `html.Label` | label for form elements | `html.Label('Label Text')` | | -| `html.Input` | input field | `html.Input(type='text', value='input')` | | -| `html.Ul` | unordered list (ul) | `html.Ul(children=[html.Li('Item 1'), html.Li('Item 2')])` |