Panel 0.12.1 is out

Panel 0.12.1 is out.

Check out

Panel 0.12.0 Blog: HoloViz Blog

Panel 0.12.1 Change log: Release Version 0.12.1 · holoviz/panel · GitHub

1 Like

The code to create the above app is

import panel as pn

import folium
import time

STYLE = """
.bk progress {
    margin-top: 20px;
}
"""
pn.config.raw_css.append(STYLE)
pn.extension(sizing_mode="stretch_width")



accent_base_color = "#F08080"
logo="https://raw.githubusercontent.com/holoviz/panel/98389a8dead125bcb7c60dc2c1564e112d89d3fa/doc/_static/logo_stacked.png"
template = pn.template.FastListTemplate(
    title="Panel 0.12.1 is Out",
    logo=logo,
    accent_base_color=accent_base_color,
    header_background=accent_base_color,
    header_accent_base_color="white",
)
theme = "dark" if template.theme == pn.template.DarkTheme else "default"

def get_logo_pane():
    announcement_pane = """\
# Panel 0.12.1 Is Out

This is a patch release with a small number of fixes following the 0.12.0 release. Many thanks to the maintainers @MarcSkovMadsen and @philippjfr for the fixes in this release.

Enhancements:

- Bundle .map files during build to allow source mapping ([#2591](https://github.com/holoviz/panel/issues/2591))
- Various style improvements for Fast templates ([#2604](https://github.com/holoviz/panel/issues/2604), [#2609](https://github.com/holoviz/panel/issues/2609), [#2611](https://github.com/holoviz/panel/issues/2611), [#2615](https://github.com/holoviz/panel/issues/2615))
- Implement hierarchical aggregation for `Tabulator` ([#2624](https://github.com/holoviz/panel/issues/2624))

Bug fixes:

- Fix logo on Fast templates ([#2184](https://github.com/holoviz/panel/issues/2184))
- Fix height responsiveness of Folium pane ([#2231](https://github.com/holoviz/panel/issues/2231))
- Fix bug updating `Tqdm` indicator ([#2554](https://github.com/holoviz/panel/issues/2554))
- Ensure `--autoreload` doesn't error on cleaned up session ([#2570](https://github.com/holoviz/panel/issues/2570))
- Don't use persisted layout if `save_layout=False` ([#2579](https://github.com/holoviz/panel/issues/2579))
- Pin version of tqdm with asyncio support ([#2595](https://github.com/holoviz/panel/issues/2595))
- Reset layout when resetting grid template layout ([#2576](https://github.com/holoviz/panel/issues/2576))
- Fix line-height issues in Fast templates ([#2600](https://github.com/holoviz/panel/issues/2600))
- Clean up sessions after warmup and ensure periodic callbacks are cleaned up ([#2601](https://github.com/holoviz/panel/issues/2601))

Documentation:

- Enable JupyterLab preview button on binder ([#2545](https://github.com/holoviz/panel/issues/2545))
- Update theme toggle documentation for Fast templates ([#2560](https://github.com/holoviz/panel/issues/2560))
- Update Fast template documentation and enable full screen ([#2577](https://github.com/holoviz/panel/issues/2577))
- Fix binder links on website ([#2590](https://github.com/holoviz/panel/issues/2590))
- Add docs about loading the ipywidgets extension ([#2594](https://github.com/holoviz/panel/issues/2594))
"""
    logo_pane = pn.pane.PNG(
        logo,
        link_url="https://panel.holoviz.org",
        embed=False,
        sizing_mode="fixed",
        align="center",
        margin=(10,5,10,50)
    )
    return pn.Row(announcement_pane, logo_pane, min_height=200, sizing_mode="stretch_both")

def get_folium_pane():
    def get_plot(theme="default", accent_base_color="blue"):
        plot = folium.Map(location=[45.372, -121.6972], zoom_start=12, tiles="Stamen Terrain") #,  width='100%', height="50%")

        folium.Marker(
            location=[45.3288, -121.6625],
            popup="Mt. Hood Meadows",
            icon=folium.Icon(icon="cloud"),
        ).add_to(plot)

        folium.Marker(
            location=[45.3311, -121.7113],
            popup="Timberline Lodge",
            icon=folium.Icon(color="green"),
        ).add_to(plot)

        folium.Marker(
            location=[45.3300, -121.6823],
            popup="Some Other Location",
            icon=folium.Icon(color="red", icon="info-sign"),
        ).add_to(plot)
        return plot

    return pn.Column(
        "# Folium is now Height Responsive",
        pn.pane.plot.Folium(get_plot(), min_height=500, sizing_mode="stretch_both"),
    )

def get_tqdm():
    tqdm = pn.widgets.Tqdm(height=50)

    def run_loop(*events, timeout=0.2):
        for i in tqdm(range(0,10), desc="My loop bar", leave=True, colour='#666666'):
            time.sleep(timeout)

    button = pn.widgets.Button(name="Run Loop", button_type="success")
    button.on_click(run_loop)
    return pn.Column(
        "# TDQM Package version pinned", button, tqdm
    )

template.main[:]=[
    get_logo_pane(),
    get_folium_pane(),
    get_tqdm(),
    pn.pane.HTML('<blockquote class="twitter-tweet"><p lang="en" dir="ltr">Pushed a fix to <a href="https://twitter.com/Panel_org?ref_src=twsrc%5Etfw">@Panel_org</a> to make the new Jupyterlab Preview work on Binder<br><br>Preview: <a href="https://t.co/upnYIeQ10x">https://t.co/upnYIeQ10x</a><br>Fix: <a href="https://t.co/m2eaXovgFr">https://t.co/m2eaXovgFr</a><a href="https://twitter.com/hashtag/DataScience?src=hash&amp;ref_src=twsrc%5Etfw">#DataScience</a> <a href="https://twitter.com/mybinderteam?ref_src=twsrc%5Etfw">@mybinderteam</a> <a href="https://twitter.com/ProjectJupyter?ref_src=twsrc%5Etfw">@ProjectJupyter</a> <a href="https://twitter.com/hashtag/Python?src=hash&amp;ref_src=twsrc%5Etfw">#Python</a> <a href="https://twitter.com/hashtag/machinelearning?src=hash&amp;ref_src=twsrc%5Etfw">#machinelearning</a> <a href="https://twitter.com/hashtag/mlapps?src=hash&amp;ref_src=twsrc%5Etfw">#mlapps</a> <a href="https://t.co/0ABrqUSTPM">pic.twitter.com/0ABrqUSTPM</a></p>&mdash; Marc Skov Madsen (@MarcSkovMadsen) <a href="https://twitter.com/MarcSkovMadsen/status/1424986223811178496?ref_src=twsrc%5Etfw">August 10, 2021</a></blockquote> <script async src="https://platform.twitter.com/widgets.js" charset="utf-8"></script> ', min_height=700, sizing_mode="stretch_both", align="center"),
]
template.servable()