figpack 0.2.10__py3-none-any.whl → 0.2.11__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of figpack might be problematic. Click here for more details.
- figpack/__init__.py +1 -1
- figpack/core/extension_view.py +6 -0
- figpack/core/figpack_view.py +6 -1
- figpack/figpack-figure-dist/assets/{index-D2FnM_hN.js → index-DvunBzII.js} +66 -66
- figpack/figpack-figure-dist/index.html +1 -1
- figpack/views/PlotlyExtension/PlotlyExtension.py +121 -0
- figpack/views/PlotlyExtension/__init__.py +3 -0
- figpack/views/__init__.py +1 -1
- {figpack-0.2.10.dist-info → figpack-0.2.11.dist-info}/METADATA +1 -1
- {figpack-0.2.10.dist-info → figpack-0.2.11.dist-info}/RECORD +14 -13
- figpack/views/PlotlyFigure.py +0 -76
- {figpack-0.2.10.dist-info → figpack-0.2.11.dist-info}/WHEEL +0 -0
- {figpack-0.2.10.dist-info → figpack-0.2.11.dist-info}/entry_points.txt +0 -0
- {figpack-0.2.10.dist-info → figpack-0.2.11.dist-info}/licenses/LICENSE +0 -0
- {figpack-0.2.10.dist-info → figpack-0.2.11.dist-info}/top_level.txt +0 -0
figpack/__init__.py
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
figpack - A Python package for creating shareable, interactive visualizations in the browser
|
|
3
3
|
"""
|
|
4
4
|
|
|
5
|
-
__version__ = "0.2.
|
|
5
|
+
__version__ = "0.2.11"
|
|
6
6
|
|
|
7
7
|
from .cli import view_figure
|
|
8
8
|
from .core import FigpackView, FigpackExtension, ExtensionRegistry, ExtensionView
|
figpack/core/extension_view.py
CHANGED
|
@@ -30,6 +30,7 @@ class ExtensionView(FigpackView):
|
|
|
30
30
|
f"Extension '{extension_name}' is not registered. "
|
|
31
31
|
f"Make sure to register the extension before creating views that use it."
|
|
32
32
|
)
|
|
33
|
+
self.extension = extension
|
|
33
34
|
|
|
34
35
|
def _write_to_zarr_group(self, group: zarr.Group) -> None:
|
|
35
36
|
"""
|
|
@@ -46,6 +47,11 @@ class ExtensionView(FigpackView):
|
|
|
46
47
|
# Store the extension name so the frontend knows which extension to use
|
|
47
48
|
group.attrs["extension_name"] = self.extension_name
|
|
48
49
|
|
|
50
|
+
# Store additional script names
|
|
51
|
+
group.attrs["additional_script_names"] = list(
|
|
52
|
+
self.extension.get_additional_filenames().keys()
|
|
53
|
+
)
|
|
54
|
+
|
|
49
55
|
# Store extension metadata for debugging/compatibility
|
|
50
56
|
registry = ExtensionRegistry.get_instance()
|
|
51
57
|
extension = registry.get_extension(self.extension_name)
|
figpack/core/figpack_view.py
CHANGED
|
@@ -70,7 +70,12 @@ class FigpackView:
|
|
|
70
70
|
|
|
71
71
|
# determine inline
|
|
72
72
|
if inline is None:
|
|
73
|
-
|
|
73
|
+
if os.environ.get("FIGPACK_INLINE") == "1":
|
|
74
|
+
inline = True
|
|
75
|
+
elif os.environ.get("FIGPACK_INLINE") == "0":
|
|
76
|
+
inline = False
|
|
77
|
+
elif _is_in_notebook() and not upload:
|
|
78
|
+
inline = True
|
|
74
79
|
|
|
75
80
|
# determine open_in_browser
|
|
76
81
|
if open_in_browser is None:
|