Skip to content

Commit b16631d

Browse files
authored
v0.2.2 (#73)
* Update submodules to latest * Set shiny to v0.6.0 tag * Revert mizani and plotnine submodule updates * Bump version to 0.2.2 * Add shinyswatch to deps from pypi; Update lock file * Roll back ipywidgets to 8.0.6 * Add `exceptiongroup` dep for `anyio` * Update orbit app to not use `x.`
1 parent 0cd59dc commit b16631d

File tree

9 files changed

+205
-207
lines changed

9 files changed

+205
-207
lines changed

examples/python/orbit/app.py

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
import astropy.units as u
44
import matplotlib.pyplot as plt
55
import numpy as np
6-
import shiny.experimental as x
76
from body import body_server, body_ui
87
from faicons import icon_svg
98
from shiny import App, reactive, render, ui
@@ -13,13 +12,13 @@
1312
# https://prappleizer.github.io/
1413

1514

16-
app_ui = x.ui.page_sidebar(
17-
x.ui.sidebar(
15+
app_ui = ui.page_sidebar(
16+
ui.sidebar(
1817
ui.img(
1918
src="coords.png", style="width: 100%; max-width: 225px;", class_="border"
2019
),
21-
x.ui.accordion(
22-
x.ui.accordion_panel(
20+
ui.accordion(
21+
ui.accordion_panel(
2322
"Settings",
2423
ui.input_slider("days", "Simulation duration (days)", 0, 200, value=60),
2524
ui.input_slider(
@@ -31,31 +30,29 @@
3130
step=0.5,
3231
),
3332
),
34-
x.ui.accordion_panel(
33+
ui.accordion_panel(
3534
"Earth",
3635
body_ui(
3736
"earth", enable=True, mass=597.216, speed=0.0126, theta=270, phi=90
3837
),
3938
),
40-
x.ui.accordion_panel(
39+
ui.accordion_panel(
4140
"Moon",
4241
body_ui("moon", enable=True, mass=7.347, speed=1.022, theta=60, phi=90),
4342
),
44-
x.ui.accordion_panel(
43+
ui.accordion_panel(
4544
"Planet X",
4645
body_ui(
4746
"planetx", enable=True, mass=7.347, speed=1.022, theta=270, phi=60
4847
),
4948
),
50-
open=False,
51-
multiple=False,
5249
# mt-4: margin top 4; adds a bit of space above the accordion
5350
class_="mt-4",
5451
# Give the accordion the same background color as the sidebar
5552
style="--bs-accordion-bg: --bslib-sidebar-bg;",
5653
),
5754
position="right",
58-
open="open",
55+
open="always",
5956
# In mobile mode, let the sidebar be as tall as it wants
6057
max_height_mobile="auto",
6158
),
@@ -64,7 +61,7 @@
6461
"run", "Run simulation", icon=icon_svg("play"), class_="btn-primary"
6562
)
6663
),
67-
x.ui.output_plot("orbits"),
64+
ui.output_plot("orbits"),
6865
)
6966

7067

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"private": true,
33
"name": "shinylive",
4-
"version": "0.2.1",
4+
"version": "0.2.2",
55
"description": "Run Shiny applications with Python running in the browser.",
66
"main": "index.js",
77
"repository": {

packages/py-htmltools

packages/py-shiny

packages/py-shinywidgets

scripts/pyodide_packages.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,9 @@
9393
# Pandas doesn't list jinja2 as a hard depedency, but it is needed when
9494
# doing table styling.
9595
"jinja2",
96-
]
96+
],
97+
# Can be removed when we moved to pyodide w/ python 3.11
98+
"anyio": ["exceptiongroup"],
9799
}
98100

99101

0 commit comments

Comments
 (0)