Skip to content

Commit 40113c8

Browse files
committedApr 23, 2024
Update Columns & Tab.md
1 parent a792070 commit 40113c8

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed
 

‎Columns & Tab.md

+13
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,16 @@ This syntax uses a 'with' statement to specify that the following code block sho
1717

1818

1919

20+
**Tabs Details**
21+
22+
tab1, tab2 = st.tabs(["Tab 1", "Tab2"])
23+
24+
This line creates two tabs labeled "Tab 1" and "Tab 2" within the Streamlit app. It assigns the first tab to the variable `tab1` and the second tab to the variable `tab2`.
25+
26+
tab1.write("this is tab 1")` and `tab2.write("this is tab 2")
27+
28+
These lines write text within their respective tabs, allowing you to display content specifically within each tab.
29+
30+
`with tab1:` and `st.radio('Select one:', [1, 2])
31+
32+
This syntax uses a 'with' statement to specify that the following code block should be executed within `tab1`. In this case, it displays a radio button widget labeled "Select one:" with options 1 and 2 within `tab1`.

0 commit comments

Comments
 (0)
Please sign in to comment.