diff --git a/package/kedro_viz/launchers/jupyter.py b/package/kedro_viz/launchers/jupyter.py index 420bb2087e..75e492f1aa 100644 --- a/package/kedro_viz/launchers/jupyter.py +++ b/package/kedro_viz/launchers/jupyter.py @@ -139,3 +139,15 @@ def run_viz(port: int = None, line=None, local_ns=None) -> None: port ) display(HTML(wrapper)) + + +def jupyter_server_proxy(): + return { + "command": ["kedro", "viz", "--port", "{port}"], + "timeout": 20, + # absolute_url=True was worse + "launcher_entry": { + "icon_path": "/Users/antony_milne/kedro_stuff/kedro-viz/kedro-icon-color.svg", + "title": "Kedro-Viz", + }, + } diff --git a/package/setup.py b/package/setup.py index 688a20c659..ad6719827e 100644 --- a/package/setup.py +++ b/package/setup.py @@ -50,6 +50,10 @@ package_data={"kedro_viz": list(files)}, zip_safe=False, entry_points={ + "jupyter_serverproxy_servers": [ + # name = packagename:function_name + "kedro_viz = kedro_viz.launchers.jupyter:jupyter_server_proxy", + ], "kedro.global_commands": ["kedro-viz = kedro_viz.launchers.cli:commands"], "kedro.line_magic": ["line_magic = kedro_viz.launchers.jupyter:run_viz"], }, diff --git a/src/components/icons/logo.js b/src/components/icons/logo.js index 0036213e21..cbc01791ee 100644 --- a/src/components/icons/logo.js +++ b/src/components/icons/logo.js @@ -1,7 +1,7 @@ import React from 'react'; const LogoIcon = ({ className }) => ( - +