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

chore: update example #6

Merged
merged 1 commit into from
Dec 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
81 changes: 45 additions & 36 deletions example/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
"""

"""
----
## Bar Chart
"""

Expand All @@ -36,7 +35,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand All @@ -61,10 +61,11 @@

g2(options=options)
```
"""
""")



"""
----
## Column Chart
"""

Expand Down Expand Up @@ -93,7 +94,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand Down Expand Up @@ -123,11 +125,11 @@

g2(options=options)
```
"""
""")



"""
----
## Line Chart
"""

Expand All @@ -147,7 +149,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand All @@ -168,11 +171,11 @@

g2(options=options)
```
"""
""")



"""
----
## Area Chart
"""

Expand All @@ -192,7 +195,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand All @@ -213,15 +217,17 @@

g2(options=options)
```
"""
""")



"""
----
## Pie Chart
"""

options = {
"autoFit": True,
"theme": "dark",
"type": "interval",
"coordinate": {
"type": "theta"
Expand Down Expand Up @@ -262,7 +268,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand Down Expand Up @@ -308,12 +315,11 @@

g2(options=options)
```
"""
""")



"""
----
## DualAxes Chart
"""

Expand Down Expand Up @@ -475,7 +481,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand Down Expand Up @@ -638,11 +645,11 @@

g2(options=options)
```
"""
""")



"""
----
## Scatter Chart
"""

Expand All @@ -664,7 +671,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand All @@ -687,12 +695,11 @@

g2(options=options)
```
"""
""")



"""
----
## Liquid Chart
"""

Expand All @@ -712,7 +719,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand All @@ -733,12 +741,11 @@

g2(options=options)
```
"""
""")



"""
----
## Ring Chart
"""

Expand Down Expand Up @@ -810,7 +817,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand Down Expand Up @@ -883,11 +891,11 @@

g2(options=options)
```
"""
""")



"""
----
## Boxplot
"""

Expand All @@ -914,7 +922,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand Down Expand Up @@ -942,12 +951,11 @@

g2(options=options)
```
"""
""")



"""
----
## Funnel Chart
"""

Expand Down Expand Up @@ -1002,7 +1010,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand Down Expand Up @@ -1058,12 +1067,11 @@

g2(options=options)
```
"""
""")



"""
----
## Histogram
"""

Expand Down Expand Up @@ -1096,7 +1104,8 @@

g2(options=options)

"""
source = st.expander("Source Code")
source.markdown("""
```py
import streamlit as st
from streamlit_g2 import g2
Expand Down Expand Up @@ -1130,4 +1139,4 @@

g2(options=options)
```
"""
""")
2 changes: 1 addition & 1 deletion streamlit_g2/frontend/src/g2.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React, { useEffect } from 'react';
import React from 'react';
import {
Streamlit,
withStreamlitConnection,
Expand Down
Loading