mirror of
https://github.com/jupyter/notebook.git
synced 2025-04-12 14:00:27 +08:00
Additional renaming
This commit is contained in:
parent
dfa72c804d
commit
e049582f4d
@ -147,7 +147,7 @@ async function main() {
|
||||
|
||||
// The motivation here is to only load a specific set of plugins dependending on
|
||||
// the current page
|
||||
const page = PageConfig.getOption('retroPage');
|
||||
const page = PageConfig.getOption('notebookPage');
|
||||
switch (page) {
|
||||
case 'tree': {
|
||||
baseMods = baseMods.concat([
|
||||
|
@ -17,7 +17,7 @@
|
||||
{% set _ = page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %}
|
||||
|
||||
{# Sentinel value to say that we are on the tree page #}
|
||||
{% set _ = page_config_full.update(retroPage='consoles') %}
|
||||
{% set _ = page_config_full.update(notebookPage='consoles') %}
|
||||
|
||||
<script id="jupyter-config-data" type="application/json">
|
||||
{{ page_config_full | tojson }}
|
||||
|
@ -17,7 +17,7 @@
|
||||
{% set _ = page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %}
|
||||
|
||||
{# Sentinel value to say that we are on the tree page #}
|
||||
{% set _ = page_config_full.update(retroPage='edit') %}
|
||||
{% set _ = page_config_full.update(notebookPage='edit') %}
|
||||
|
||||
<script id="jupyter-config-data" type="application/json">
|
||||
{{ page_config_full | tojson }}
|
||||
|
@ -8,7 +8,7 @@
|
||||
<link rel="icon" type="image/x-icon" href="{{ base_url | escape }}static/favicons/favicon-notebook.ico" class="favicon">
|
||||
{% endblock %}
|
||||
</head>
|
||||
<body data-retro="notebooks">
|
||||
<body data-notebook="notebooks">
|
||||
|
||||
{# Copy so we do not modify the page_config with updates. #}
|
||||
{% set page_config_full = page_config.copy() %}
|
||||
@ -17,7 +17,7 @@
|
||||
{% set _ = page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %}
|
||||
|
||||
{# Sentinel value to say that we are on the tree page #}
|
||||
{% set _ = page_config_full.update(retroPage='notebooks') %}
|
||||
{% set _ = page_config_full.update(notebookPage='notebooks') %}
|
||||
|
||||
<script id="jupyter-config-data" type="application/json">
|
||||
{{ page_config_full | tojson }}
|
||||
|
@ -17,7 +17,7 @@
|
||||
{% set _ = page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %}
|
||||
|
||||
{# Sentinel value to say that we are on the tree page #}
|
||||
{% set _ = page_config_full.update(retroPage='terminals') %}
|
||||
{% set _ = page_config_full.update(notebookPage='terminals') %}
|
||||
|
||||
<script id="jupyter-config-data" type="application/json">
|
||||
{{ page_config_full | tojson }}
|
||||
|
@ -14,7 +14,7 @@
|
||||
{% set _ = page_config_full.update(baseUrl=base_url, wsUrl=ws_url) %}
|
||||
|
||||
{# Sentinel value to say that we are on the tree page #}
|
||||
{% set _ = page_config_full.update(retroPage='tree') %}
|
||||
{% set _ = page_config_full.update(notebookPage='tree') %}
|
||||
|
||||
<script id="jupyter-config-data" type="application/json">
|
||||
{{ page_config_full | tojson }}
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"jupyter.lab.setting-icon": "retro-ui-components:retroSun",
|
||||
"jupyter.lab.setting-icon": "notebook-ui-components:jupyter",
|
||||
"jupyter.lab.setting-icon-label": "Jupyter Notebook Top Area",
|
||||
"title": "Jupyter Notebook Top Area",
|
||||
"description": "Jupyter Notebook Top Area settings",
|
||||
|
@ -115,7 +115,7 @@ const dirty: JupyterFrontEndPlugin<void> = {
|
||||
if (!(app instanceof NotebookApp)) {
|
||||
throw new Error(`${dirty.id} must be activated in Jupyter Notebook.`);
|
||||
}
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
const message = trans.__(
|
||||
'Are you sure you want to exit Jupyter Notebook?\n\nAny unsaved changes will be lost.'
|
||||
);
|
||||
@ -149,7 +149,7 @@ const logo: JupyterFrontEndPlugin<void> = {
|
||||
height: '28px',
|
||||
width: 'auto'
|
||||
});
|
||||
logo.id = 'jp-RetroLogo';
|
||||
logo.id = 'jp-NotebookLogo';
|
||||
app.shell.add(logo, 'top', { rank: 0 });
|
||||
}
|
||||
};
|
||||
@ -212,7 +212,7 @@ const menus: JupyterFrontEndPlugin<void> = {
|
||||
// always disable the Tabs menu
|
||||
menu.tabsMenu.dispose();
|
||||
|
||||
const page = PageConfig.getOption('retroPage');
|
||||
const page = PageConfig.getOption('notebookPage');
|
||||
switch (page) {
|
||||
case 'consoles':
|
||||
case 'terminals':
|
||||
@ -245,7 +245,7 @@ const pages: JupyterFrontEndPlugin<void> = {
|
||||
palette: ICommandPalette | null,
|
||||
menu: IMainMenu | null
|
||||
): void => {
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
const baseUrl = PageConfig.getBaseUrl();
|
||||
|
||||
app.commands.addCommand(CommandIDs.openLab, {
|
||||
@ -353,12 +353,12 @@ const spacer: JupyterFrontEndPlugin<void> = {
|
||||
activate: (app: JupyterFrontEnd) => {
|
||||
const top = new Widget();
|
||||
top.id = DOMUtils.createDomID();
|
||||
top.addClass('jp-RetroSpacer');
|
||||
top.addClass('jp-NotebookSpacer');
|
||||
app.shell.add(top, 'top', { rank: 900 });
|
||||
|
||||
const menu = new Widget();
|
||||
menu.id = DOMUtils.createDomID();
|
||||
menu.addClass('jp-RetroSpacer');
|
||||
menu.addClass('jp-NotebookSpacer');
|
||||
app.shell.add(menu, 'menu', { rank: 900 });
|
||||
}
|
||||
};
|
||||
@ -430,7 +430,7 @@ const title: JupyterFrontEndPlugin<void> = {
|
||||
router: IRouter | null
|
||||
) => {
|
||||
const { commands } = app;
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
|
||||
const widget = new Widget();
|
||||
widget.id = 'jp-title';
|
||||
@ -520,7 +520,7 @@ const topVisibility: JupyterFrontEndPlugin<void> = {
|
||||
menu: IMainMenu | null,
|
||||
settingRegistry: ISettingRegistry | null
|
||||
) => {
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
const top = notebookShell.top;
|
||||
const pluginId = topVisibility.id;
|
||||
|
||||
@ -681,7 +681,7 @@ const zen: JupyterFrontEndPlugin<void> = {
|
||||
): void => {
|
||||
const { commands } = app;
|
||||
const elem = document.documentElement;
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
|
||||
const toggleOn = () => {
|
||||
notebookShell?.collapseTop();
|
||||
|
@ -4,7 +4,7 @@
|
||||
| Distributed under the terms of the Modified BSD License.
|
||||
|----------------------------------------------------------------------------*/
|
||||
|
||||
.jp-RetroSpacer {
|
||||
.jp-NotebookSpacer {
|
||||
flex-grow: 1;
|
||||
flex-shrink: 1;
|
||||
}
|
||||
|
@ -71,12 +71,12 @@ body {
|
||||
|
||||
/* Special case notebooks as document oriented pages */
|
||||
|
||||
body[data-retro='notebooks'] #main-panel {
|
||||
body[data-notebook='notebooks'] #main-panel {
|
||||
margin-left: unset;
|
||||
margin-right: unset;
|
||||
max-width: unset;
|
||||
}
|
||||
|
||||
body[data-retro='notebooks'] #spacer-widget {
|
||||
body[data-notebook='notebooks'] #spacer-widget {
|
||||
min-height: unset;
|
||||
}
|
||||
|
@ -12,7 +12,7 @@ import { IMainMenu } from '@jupyterlab/mainmenu';
|
||||
|
||||
import { ITranslator } from '@jupyterlab/translation';
|
||||
|
||||
import { retroIcon } from '@jupyter-notebook/ui-components';
|
||||
import { jupyterIcon } from '@jupyter-notebook/ui-components';
|
||||
|
||||
import * as React from 'react';
|
||||
|
||||
@ -55,7 +55,7 @@ const plugin: JupyterFrontEndPlugin<void> = {
|
||||
menu: IMainMenu | null
|
||||
): void => {
|
||||
const { commands } = app;
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
|
||||
commands.addCommand(CommandIDs.open, {
|
||||
label: args => args['text'] as string,
|
||||
@ -119,17 +119,17 @@ const plugin: JupyterFrontEndPlugin<void> = {
|
||||
const title = (
|
||||
<>
|
||||
<span className="jp-AboutRetro-header">
|
||||
<retroIcon.react height="256px" width="auto" />
|
||||
<jupyterIcon.react height="256px" width="auto" />
|
||||
</span>
|
||||
</>
|
||||
);
|
||||
|
||||
const retroNotebookURL = 'https://github.com/jupyter/notebook';
|
||||
const notebookURL = 'https://github.com/jupyter/notebook';
|
||||
const linkLabel = trans.__('JUPYTER NOTEBOOK ON GITHUB');
|
||||
const externalLinks = (
|
||||
<span>
|
||||
<a
|
||||
href={retroNotebookURL}
|
||||
href={notebookURL}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
className="jp-Button-flat jp-AboutRetro-about-externalLinks"
|
||||
|
@ -33,12 +33,7 @@ namespace CommandIDs {
|
||||
/**
|
||||
* Open Jupyter Notebook
|
||||
*/
|
||||
export const openRetro = 'jupyter-notebook:open-retro';
|
||||
|
||||
/**
|
||||
* Open in Classic Notebook
|
||||
*/
|
||||
export const openClassic = 'jupyter-notebook:open-classic';
|
||||
export const openNotebook = 'jupyter-notebook:open-notebook';
|
||||
|
||||
/**
|
||||
* Open in JupyterLab
|
||||
@ -85,7 +80,7 @@ const launchButtons: JupyterFrontEndPlugin<void> = {
|
||||
|
||||
const { commands, shell } = app;
|
||||
const baseUrl = PageConfig.getBaseUrl();
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
const menubar = new MenuBar();
|
||||
const switcher = new Menu({ commands });
|
||||
switcher.title.label = trans.__('Interface');
|
||||
@ -124,17 +119,9 @@ const launchButtons: JupyterFrontEndPlugin<void> = {
|
||||
switcher.addItem({ command });
|
||||
};
|
||||
|
||||
// always add Classic
|
||||
addInterface({
|
||||
command: 'jupyter-notebook:open-classic',
|
||||
commandLabel: trans.__('Open With %1', 'Classic Notebook'),
|
||||
buttonLabel: 'openClassic',
|
||||
urlPrefix: `${baseUrl}tree/`
|
||||
});
|
||||
|
||||
if (!notebookShell) {
|
||||
addInterface({
|
||||
command: 'jupyter-notebook:open-retro',
|
||||
command: CommandIDs.openNotebook,
|
||||
commandLabel: trans.__('Open With %1', 'Jupyter Notebook'),
|
||||
buttonLabel: 'openRetro',
|
||||
urlPrefix: `${baseUrl}tree/`
|
||||
@ -143,7 +130,7 @@ const launchButtons: JupyterFrontEndPlugin<void> = {
|
||||
|
||||
if (!labShell) {
|
||||
addInterface({
|
||||
command: 'jupyter-notebook:open-lab',
|
||||
command: CommandIDs.openLab,
|
||||
commandLabel: trans.__('Open With %1', 'JupyterLab'),
|
||||
buttonLabel: 'openLab',
|
||||
urlPrefix: `${baseUrl}doc/tree/`
|
||||
@ -169,7 +156,7 @@ const launchButtons: JupyterFrontEndPlugin<void> = {
|
||||
* A plugin to add a command to open the Jupyter Notebook Tree.
|
||||
*/
|
||||
const launchRetroTree: JupyterFrontEndPlugin<void> = {
|
||||
id: '@jupyter-notebook/lab-extension:launch-retrotree',
|
||||
id: '@jupyter-notebook/lab-extension:launch-tree',
|
||||
autoStart: true,
|
||||
requires: [ITranslator],
|
||||
optional: [IMainMenu, ICommandPalette],
|
||||
@ -180,7 +167,7 @@ const launchRetroTree: JupyterFrontEndPlugin<void> = {
|
||||
palette: ICommandPalette | null
|
||||
): void => {
|
||||
const { commands } = app;
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
const category = trans.__('Help');
|
||||
|
||||
commands.addCommand(CommandIDs.launchRetroTree, {
|
||||
|
@ -1,5 +1,5 @@
|
||||
{
|
||||
"jupyter.lab.setting-icon": "retro-ui-components:retroSun",
|
||||
"jupyter.lab.setting-icon": "notebook-ui-components:jupyter",
|
||||
"jupyter.lab.setting-icon-label": "Jupyter Notebook Notebook",
|
||||
"title": "Jupyter Notebook Notebook",
|
||||
"description": "Jupyter Notebook Notebook settings",
|
||||
|
@ -31,22 +31,22 @@ import { Menu, Widget } from '@lumino/widgets';
|
||||
/**
|
||||
* The class for kernel status errors.
|
||||
*/
|
||||
const KERNEL_STATUS_ERROR_CLASS = 'jp-RetroKernelStatus-error';
|
||||
const KERNEL_STATUS_ERROR_CLASS = 'jp-NotebookKernelStatus-error';
|
||||
|
||||
/**
|
||||
* The class for kernel status warnings.
|
||||
*/
|
||||
const KERNEL_STATUS_WARN_CLASS = 'jp-RetroKernelStatus-warn';
|
||||
const KERNEL_STATUS_WARN_CLASS = 'jp-NotebookKernelStatus-warn';
|
||||
|
||||
/**
|
||||
* The class for kernel status infos.
|
||||
*/
|
||||
const KERNEL_STATUS_INFO_CLASS = 'jp-RetroKernelStatus-info';
|
||||
const KERNEL_STATUS_INFO_CLASS = 'jp-NotebookKernelStatus-info';
|
||||
|
||||
/**
|
||||
* The class to fade out the kernel status.
|
||||
*/
|
||||
const KERNEL_STATUS_FADE_OUT_CLASS = 'jp-RetroKernelStatus-fade';
|
||||
const KERNEL_STATUS_FADE_OUT_CLASS = 'jp-NotebookKernelStatus-fade';
|
||||
|
||||
/**
|
||||
* The class for scrolled outputs
|
||||
@ -68,10 +68,10 @@ const checkpoints: JupyterFrontEndPlugin<void> = {
|
||||
notebookShell: INotebookShell | null
|
||||
) => {
|
||||
const { shell } = app;
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
const widget = new Widget();
|
||||
widget.id = DOMUtils.createDomID();
|
||||
widget.addClass('jp-RetroCheckpoint');
|
||||
widget.addClass('jp-NotebookCheckpoint');
|
||||
app.shell.add(widget, 'top', { rank: 100 });
|
||||
|
||||
const onChange = async () => {
|
||||
@ -153,7 +153,7 @@ const kernelLogo: JupyterFrontEndPlugin<void> = {
|
||||
img.title = spec.display_name;
|
||||
node.appendChild(img);
|
||||
widget = new Widget({ node });
|
||||
widget.addClass('jp-RetroKernelLogo');
|
||||
widget.addClass('jp-NotebookKernelLogo');
|
||||
app.shell.add(widget, 'top', { rank: 10_010 });
|
||||
};
|
||||
|
||||
@ -175,9 +175,9 @@ const kernelStatus: JupyterFrontEndPlugin<void> = {
|
||||
shell: INotebookShell,
|
||||
translator: ITranslator
|
||||
) => {
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
const widget = new Widget();
|
||||
widget.addClass('jp-RetroKernelStatus');
|
||||
widget.addClass('jp-NotebookKernelStatus');
|
||||
app.shell.add(widget, 'menu', { rank: 10_010 });
|
||||
|
||||
const removeClasses = () => {
|
||||
@ -230,7 +230,7 @@ const kernelStatus: JupyterFrontEndPlugin<void> = {
|
||||
* TODO: switch to settings define menus when fixed upstream: https://github.com/jupyterlab/jupyterlab/issues/11754
|
||||
*/
|
||||
const menuPlugin: JupyterFrontEndPlugin<void> = {
|
||||
id: '@retrolab/notebook-extension:menu-plugin',
|
||||
id: '@jupyter-notebook/notebook-extension:menu-plugin',
|
||||
autoStart: true,
|
||||
requires: [IMainMenu, ITranslator],
|
||||
activate: (
|
||||
@ -239,7 +239,7 @@ const menuPlugin: JupyterFrontEndPlugin<void> = {
|
||||
translator: ITranslator
|
||||
) => {
|
||||
const { commands } = app;
|
||||
const trans = translator.load('retrolab');
|
||||
const trans = translator.load('notebook');
|
||||
|
||||
const cellTypeSubmenu = new Menu({ commands });
|
||||
cellTypeSubmenu.title.label = trans._p('menu', 'Cell Type');
|
||||
@ -267,7 +267,7 @@ const menuPlugin: JupyterFrontEndPlugin<void> = {
|
||||
* TODO: switch to settings define menus when fixed upstream: https://github.com/jupyterlab/jupyterlab/issues/11754
|
||||
*/
|
||||
const runShortcut: JupyterFrontEndPlugin<void> = {
|
||||
id: '@retrolab/notebook-extension:run-shortcut',
|
||||
id: '@jupyter-notebook/notebook-extension:run-shortcut',
|
||||
autoStart: true,
|
||||
activate: (app: JupyterFrontEnd) => {
|
||||
app.commands.addKeyBinding({
|
||||
|
@ -8,28 +8,28 @@
|
||||
|
||||
/* Document oriented look for the notebook (scrollbar to the right of the page) */
|
||||
|
||||
body[data-retro='notebooks'] .jp-NotebookPanel-toolbar {
|
||||
body[data-notebook='notebooks'] .jp-NotebookPanel-toolbar {
|
||||
padding-left: calc(calc(100% - var(--jp-notebook-max-width)) * 0.5);
|
||||
padding-right: calc(calc(100% - var(--jp-notebook-max-width)) * 0.5);
|
||||
}
|
||||
|
||||
body[data-retro='notebooks'] .jp-Notebook > * {
|
||||
body[data-notebook='notebooks'] .jp-Notebook > * {
|
||||
background: var(--jp-layout-color0);
|
||||
padding: var(--jp-notebook-padding);
|
||||
}
|
||||
|
||||
body[data-retro='notebooks']
|
||||
body[data-notebook='notebooks']
|
||||
.jp-Notebook.jp-mod-commandMode
|
||||
.jp-Cell.jp-mod-active.jp-mod-selected:not(.jp-mod-multiSelected) {
|
||||
background: var(--jp-layout-color0) !important;
|
||||
}
|
||||
|
||||
body[data-retro='notebooks'] .jp-Notebook > *:first-child {
|
||||
body[data-notebook='notebooks'] .jp-Notebook > *:first-child {
|
||||
padding-top: var(--jp-notebook-padding-offset);
|
||||
margin-top: var(--jp-notebook-toolbar-margin-bottom);
|
||||
}
|
||||
|
||||
body[data-retro='notebooks'] .jp-Notebook {
|
||||
body[data-notebook='notebooks'] .jp-Notebook {
|
||||
padding-top: unset;
|
||||
padding-bottom: unset;
|
||||
padding-left: calc(calc(100% - var(--jp-notebook-max-width)) * 0.5);
|
||||
@ -41,13 +41,13 @@ body[data-retro='notebooks'] .jp-Notebook {
|
||||
background: var(--jp-layout-color2);
|
||||
}
|
||||
|
||||
body[data-retro='notebooks'] .jp-Notebook.jp-mod-scrollPastEnd::after {
|
||||
body[data-notebook='notebooks'] .jp-Notebook.jp-mod-scrollPastEnd::after {
|
||||
background: var(--jp-layout-color0);
|
||||
}
|
||||
|
||||
/* ---- */
|
||||
|
||||
.jp-RetroKernelLogo {
|
||||
.jp-NotebookKernelLogo {
|
||||
flex: 0 0 auto;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@ -55,13 +55,13 @@ body[data-retro='notebooks'] .jp-Notebook.jp-mod-scrollPastEnd::after {
|
||||
margin-right: 8px;
|
||||
}
|
||||
|
||||
.jp-RetroKernelLogo img {
|
||||
.jp-NotebookKernelLogo img {
|
||||
max-width: 28px;
|
||||
max-height: 28px;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.jp-RetroKernelStatus {
|
||||
.jp-NotebookKernelStatus {
|
||||
margin: 0;
|
||||
font-weight: normal;
|
||||
font-size: var(--jp-ui-font-size1);
|
||||
@ -72,19 +72,19 @@ body[data-retro='notebooks'] .jp-Notebook.jp-mod-scrollPastEnd::after {
|
||||
padding-right: var(--jp-kernel-status-padding);
|
||||
}
|
||||
|
||||
.jp-RetroKernelStatus-error {
|
||||
.jp-NotebookKernelStatus-error {
|
||||
background-color: var(--jp-error-color0);
|
||||
}
|
||||
|
||||
.jp-RetroKernelStatus-warn {
|
||||
.jp-NotebookKernelStatus-warn {
|
||||
background-color: var(--jp-warn-color0);
|
||||
}
|
||||
|
||||
.jp-RetroKernelStatus-info {
|
||||
.jp-NotebookKernelStatus-info {
|
||||
background-color: var(--jp-info-color0);
|
||||
}
|
||||
|
||||
.jp-RetroKernelStatus-fade {
|
||||
.jp-NotebookKernelStatus-fade {
|
||||
animation: 0.5s fade-out forwards;
|
||||
}
|
||||
|
||||
@ -114,7 +114,7 @@ body[data-retro='notebooks'] .jp-Notebook.jp-mod-scrollPastEnd::after {
|
||||
background: var(--jp-layout-color2);
|
||||
}
|
||||
|
||||
.jp-RetroCheckpoint {
|
||||
.jp-NotebookCheckpoint {
|
||||
font-size: 14px;
|
||||
margin-left: 5px;
|
||||
margin-right: 5px;
|
||||
@ -129,7 +129,7 @@ body[data-retro='notebooks'] .jp-Notebook.jp-mod-scrollPastEnd::after {
|
||||
|
||||
/* Mobile View */
|
||||
|
||||
body[data-format='mobile'] .jp-RetroCheckpoint {
|
||||
body[data-format='mobile'] .jp-NotebookCheckpoint {
|
||||
display: none;
|
||||
}
|
||||
|
||||
|
@ -37,7 +37,7 @@ const newFiles: JupyterFrontEndPlugin<void> = {
|
||||
) => {
|
||||
const { commands } = app;
|
||||
const browser = filebrowser.defaultBrowser;
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
|
||||
// wrapper commands to be able to override the label
|
||||
const newNotebookCommand = 'tree:new-notebook';
|
||||
@ -78,7 +78,7 @@ const newConsole: JupyterFrontEndPlugin<void> = {
|
||||
) => {
|
||||
const { commands } = app;
|
||||
const browser = filebrowser.defaultBrowser;
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
|
||||
const newConsoleCommand = 'tree:new-console';
|
||||
commands.addCommand(newConsoleCommand, {
|
||||
@ -112,7 +112,7 @@ const newTerminal: JupyterFrontEndPlugin<void> = {
|
||||
) => {
|
||||
const { commands } = app;
|
||||
const browser = filebrowser.defaultBrowser;
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
|
||||
const newTerminalCommand = 'tree:new-terminal';
|
||||
commands.addCommand(newTerminalCommand, {
|
||||
@ -149,7 +149,7 @@ const browserWidget: JupyterFrontEndPlugin<void> = {
|
||||
const tabPanel = new TabPanel({ tabPlacement: 'top', tabsMovable: true });
|
||||
tabPanel.addClass('jp-TreePanel');
|
||||
|
||||
const trans = translator.load('jupyter-notebook');
|
||||
const trans = translator.load('notebook');
|
||||
|
||||
const { defaultBrowser: browser } = factory;
|
||||
browser.title.label = trans.__('Files');
|
||||
|
@ -7,28 +7,7 @@ import { LabIcon } from '@jupyterlab/ui-components';
|
||||
|
||||
import jupyterSvgstr from '../../style/icons/jupyter.svg';
|
||||
|
||||
import retroSvgstr from '../../style/icons/retrolab.svg';
|
||||
|
||||
import retroInlineSvgstr from '../../style/icons/retrolabInline.svg';
|
||||
|
||||
import retroSunSvgstr from '../../style/icons/retrolabSun.svg';
|
||||
|
||||
export const jupyterIcon = new LabIcon({
|
||||
name: 'retro-ui-components:jupyter',
|
||||
name: 'notebook-ui-components:jupyter',
|
||||
svgstr: jupyterSvgstr
|
||||
});
|
||||
|
||||
export const retroIcon = new LabIcon({
|
||||
name: 'retro-ui-components:retrolab',
|
||||
svgstr: retroSvgstr
|
||||
});
|
||||
|
||||
export const retroInlineIcon = new LabIcon({
|
||||
name: 'retro-ui-components:retrolabInline',
|
||||
svgstr: retroInlineSvgstr
|
||||
});
|
||||
|
||||
export const retroSunIcon = new LabIcon({
|
||||
name: 'retro-ui-components:retroSun',
|
||||
svgstr: retroSunSvgstr
|
||||
});
|
||||
|
@ -1,39 +0,0 @@
|
||||
<svg width="2048" height="2048" version="1.1" viewBox="0 0 541.87 541.87" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<defs>
|
||||
<linearGradient id="linearGradient11104-2" x1="-276.78" x2="-276.78" y1="181.02" y2="208.49" gradientTransform="matrix(2.3947 0 0 2.3947 444.54 -117.45)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient4992"/>
|
||||
<linearGradient id="linearGradient4992">
|
||||
<stop stop-color="#faf327" offset="0"/>
|
||||
<stop stop-color="#fa2c8d" offset="1"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="linearGradient22598" x1="-143.43" x2="-143.43" y1="645.46" y2="751.2" gradientTransform="matrix(8.122 0 0 8.122 2145 -4828.8)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient4992"/>
|
||||
<linearGradient id="linearGradient22600" x1="-33.991" x2="-25.952" y1="344.73" y2="362.6" gradientTransform="translate(18.881 -401.29)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient19205"/>
|
||||
<linearGradient id="linearGradient19205">
|
||||
<stop stop-color="#f95" offset="0"/>
|
||||
<stop stop-color="#fff" stop-opacity="0" offset="1"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="linearGradient22602" x1="-33.991" x2="-25.952" y1="344.73" y2="362.6" gradientTransform="matrix(.49643 0 0 .49643 -126.98 -208.56)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient19205"/>
|
||||
<linearGradient id="linearGradient22604" x1="-33.991" x2="-25.952" y1="344.73" y2="362.6" gradientTransform="matrix(.64523 0 0 .64523 -113.31 -194.34)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient19205"/>
|
||||
</defs>
|
||||
<g transform="translate(436.78 15.802)">
|
||||
<g transform="translate(0 44.183)">
|
||||
<g transform="matrix(2.1489 0 0 2.1489 4.8812 178.2)" stroke-width=".73932">
|
||||
<path transform="matrix(.12312 0 0 .12312 -205.52 -110.84)" d="m995.89 373.2a434.86 434.86 0 0 0-434.86 434.86 434.86 434.86 0 0 0 0.48047 20.422h868.77a434.86 434.86 0 0 0 0.4805-20.422 434.86 434.86 0 0 0-434.86-434.86zm-426.51 519.71a434.86 434.86 0 0 0 8.8066 36.123h835.4a434.86 434.86 0 0 0 8.8066-36.123h-853.01zm33.141 100.54a434.86 434.86 0 0 0 17.799 33.828h751.13a434.86 434.86 0 0 0 17.801-33.828h-786.73zm45.984 76.205a434.86 434.86 0 0 0 26.217 31.594h642.33a434.86 434.86 0 0 0 26.219-31.594h-694.77zm69.4 72.82a434.86 434.86 0 0 0 34.543 25.926h486.88a434.86 434.86 0 0 0 34.545-25.926h-555.96zm124.95 72.633a434.86 434.86 0 0 0 153.04 27.82 434.86 434.86 0 0 0 153.04-27.82h-306.08z" fill="url(#linearGradient22598)" style="mix-blend-mode:normal"/>
|
||||
<g>
|
||||
<circle cx="-17.476" cy="-50.398" r="11.615" fill="url(#linearGradient22600)" style="mix-blend-mode:normal"/>
|
||||
<circle cx="-145.03" cy="-34.367" r="5.7663" fill="url(#linearGradient22602)" style="mix-blend-mode:normal"/>
|
||||
<circle cx="-136.77" cy="32.057" r="7.4946" fill="url(#linearGradient22604)" style="mix-blend-mode:normal"/>
|
||||
</g>
|
||||
</g>
|
||||
<g fill="url(#linearGradient11104-2)" stroke-width=".2858" aria-label="RETROLAB">
|
||||
<path d="m-397.29 345.41q5.7466 0 8.6857-2.6759 2.983-2.6759 2.983-7.8522 0-3.2462-2.0618-4.7376-2.0179-1.5354-6.4046-1.5354h-6.9749l-3.3339 16.801zm-9.3437 11.669-4.8692 24.785h-16.889l12.765-65.494h24.96q10.791 0 16.362 4.0358 5.5711 4.0358 5.5711 11.888 0 7.9399-4.3867 13.072-4.3867 5.1324-11.888 5.8782 3.4216 0.70187 5.7027 3.5094 2.2811 2.7636 3.9919 8.5102l5.5711 18.6h-16.801l-4.9131-16.275q-1.4915-4.8692-3.641-6.6678-2.1056-1.8424-6.1414-1.8424z"/>
|
||||
<path d="m-346.45 316.37h45.534l-2.5004 12.765h-28.645l-2.3688 12.195h26.978l-2.5443 12.765h-26.934l-2.8952 15.003h29.566l-2.4127 12.765h-46.543z"/>
|
||||
<path d="m-292.89 316.37h60.361l-2.5004 12.765h-21.758l-10.265 52.728h-16.889l10.265-52.728h-21.758z"/>
|
||||
<path d="m-205.46 345.41q5.7466 0 8.6857-2.6759 2.983-2.6759 2.983-7.8522 0-3.2462-2.0618-4.7376-2.0179-1.5354-6.4046-1.5354h-6.9749l-3.3339 16.801zm-9.3437 11.669-4.8692 24.785h-16.889l12.765-65.494h24.96q10.791 0 16.362 4.0358 5.5711 4.0358 5.5711 11.888 0 7.9399-4.3867 13.072-4.3867 5.1324-11.888 5.8782 3.4216 0.70187 5.7027 3.5094 2.2811 2.7636 3.9919 8.5102l5.5711 18.6h-16.801l-4.9131-16.275q-1.4915-4.8692-3.641-6.6678-2.1056-1.8424-6.1414-1.8424z"/>
|
||||
<path d="m-114 343.22q0-7.7206-3.5094-11.756-3.4655-4.0358-10.089-4.0358-8.7734 0-14.739 7.8961-5.9221 7.8522-5.9221 19.696 0 7.5451 3.4655 11.713t9.6508 4.1674q5.0447 0 8.9489-2.1056 3.948-2.1495 6.7117-6.3169 2.632-3.9919 4.0358-8.9928 1.4476-5.0008 1.4476-10.265zm-11.142-28.031q13.072 0 21.012 7.2819 7.9838 7.2381 7.9838 18.951 0 7.9838-2.4566 15.09-2.4127 7.1065-7.0626 12.765-5.7027 6.9749-13.511 10.44-7.7645 3.4216-17.942 3.4216-13.029 0-20.968-7.2381-7.9399-7.2381-7.9399-18.994 0-8.0277 2.4127-15.134t7.1065-12.809q5.615-6.931 13.379-10.353 7.8083-3.4216 17.986-3.4216z"/>
|
||||
<path d="m-78.244 316.37h16.889l-10.265 52.728h29.566l-2.4127 12.765h-46.543z"/>
|
||||
<path d="m8.4808 369.93h-26.145l-6.4923 11.932h-17.328l37.024-65.494h19.302l11.581 65.494h-16.055zm-19.784-11.888h17.591l-3.948-25.224z"/>
|
||||
<path d="m69.807 341.73q4.5183 0 7.0626-2.2811t2.5443-6.273q0-2.5882-1.7986-3.948-1.7547-1.3599-5.0886-1.3599h-9.4314l-2.7198 13.862zm-5.0008 28.645q5.7905 0 8.905-2.7636 3.1146-2.7636 3.1146-7.9399 0-3.29-2.1495-4.8692-2.1495-1.5792-6.5801-1.5792h-9.9578l-3.3339 17.152zm20.003-23.557q4.299 1.2283 6.6239 4.5183 2.3688 3.2462 2.3688 8.0716 0 10.572-7.8961 16.538-7.8522 5.9221-22.109 5.9221h-28.031l12.765-65.494h25.311q11.669 0 17.24 3.4216 5.615 3.4216 5.615 10.572 0 6.0098-3.29 10.572-3.29 4.5183-8.5979 5.8782z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
Before Width: | Height: | Size: 5.4 KiB |
@ -1,39 +0,0 @@
|
||||
<svg width="4240.5" height="879.73" version="1.1" viewBox="0 0 1122 232.76" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<defs>
|
||||
<linearGradient id="linearGradient11104-2" x1="-276.78" x2="-276.78" y1="181.02" y2="208.49" gradientTransform="matrix(2.3947 0 0 2.3947 444.54 -117.45)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient4992"/>
|
||||
<linearGradient id="linearGradient4992">
|
||||
<stop stop-color="#faf327" offset="0"/>
|
||||
<stop stop-color="#fa2c8d" offset="1"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="linearGradient22598" x1="-143.43" x2="-143.43" y1="645.46" y2="751.2" gradientTransform="matrix(8.122 0 0 8.122 2145 -4828.8)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient4992"/>
|
||||
<linearGradient id="linearGradient22600" x1="-33.991" x2="-25.952" y1="344.73" y2="362.6" gradientTransform="translate(18.881 -401.29)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient19205"/>
|
||||
<linearGradient id="linearGradient19205">
|
||||
<stop stop-color="#f95" offset="0"/>
|
||||
<stop stop-color="#fff" stop-opacity="0" offset="1"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="linearGradient22602" x1="-33.991" x2="-25.952" y1="344.73" y2="362.6" gradientTransform="matrix(.49643 0 0 .49643 -126.98 -208.56)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient19205"/>
|
||||
<linearGradient id="linearGradient22604" x1="-33.991" x2="-25.952" y1="344.73" y2="362.6" gradientTransform="matrix(.64523 0 0 .64523 -113.31 -194.34)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient19205"/>
|
||||
</defs>
|
||||
<g transform="translate(838.25 -264.07)">
|
||||
<g transform="translate(0 44.183)">
|
||||
<g transform="matrix(2.1489 0 0 2.1489 -512.88 360.65)" stroke-width=".73932">
|
||||
<path transform="matrix(.12312 0 0 .12312 -205.52 -110.84)" d="m995.89 373.2a434.86 434.86 0 0 0-434.86 434.86 434.86 434.86 0 0 0 0.48047 20.422h868.77a434.86 434.86 0 0 0 0.4805-20.422 434.86 434.86 0 0 0-434.86-434.86zm-426.51 519.71a434.86 434.86 0 0 0 8.8066 36.123h835.4a434.86 434.86 0 0 0 8.8066-36.123zm33.141 100.54a434.86 434.86 0 0 0 17.799 33.828h751.13a434.86 434.86 0 0 0 17.801-33.828zm45.984 76.205a434.86 434.86 0 0 0 26.217 31.594h642.33a434.86 434.86 0 0 0 26.219-31.594zm69.4 72.82a434.86 434.86 0 0 0 34.543 25.926h486.88a434.86 434.86 0 0 0 34.545-25.926zm124.95 72.633a434.86 434.86 0 0 0 153.04 27.82 434.86 434.86 0 0 0 153.04-27.82z" fill="url(#linearGradient22598)" style="mix-blend-mode:normal"/>
|
||||
<g>
|
||||
<circle cx="-17.476" cy="-50.398" r="11.615" fill="url(#linearGradient22600)" style="mix-blend-mode:normal"/>
|
||||
<circle cx="-145.03" cy="-34.367" r="5.7663" fill="url(#linearGradient22602)" style="mix-blend-mode:normal"/>
|
||||
<circle cx="-136.77" cy="32.057" r="7.4946" fill="url(#linearGradient22604)" style="mix-blend-mode:normal"/>
|
||||
</g>
|
||||
</g>
|
||||
<g transform="matrix(1.5533 0 0 1.5533 132.2 -206.08)" fill="url(#linearGradient11104-2)" stroke-width=".2858" aria-label="RETROLAB">
|
||||
<path d="m-397.29 345.41q5.7466 0 8.6857-2.6759 2.983-2.6759 2.983-7.8522 0-3.2462-2.0618-4.7376-2.0179-1.5354-6.4046-1.5354h-6.9749l-3.3339 16.801zm-9.3437 11.669-4.8692 24.785h-16.889l12.765-65.494h24.96q10.791 0 16.362 4.0358 5.5711 4.0358 5.5711 11.888 0 7.9399-4.3867 13.072-4.3867 5.1324-11.888 5.8782 3.4216 0.70187 5.7027 3.5094 2.2811 2.7636 3.9919 8.5102l5.5711 18.6h-16.801l-4.9131-16.275q-1.4915-4.8692-3.641-6.6678-2.1056-1.8424-6.1414-1.8424z"/>
|
||||
<path d="m-346.45 316.37h45.534l-2.5004 12.765h-28.645l-2.3688 12.195h26.978l-2.5443 12.765h-26.934l-2.8952 15.003h29.566l-2.4127 12.765h-46.543z"/>
|
||||
<path d="m-292.89 316.37h60.361l-2.5004 12.765h-21.758l-10.265 52.728h-16.889l10.265-52.728h-21.758z"/>
|
||||
<path d="m-205.46 345.41q5.7466 0 8.6857-2.6759 2.983-2.6759 2.983-7.8522 0-3.2462-2.0618-4.7376-2.0179-1.5354-6.4046-1.5354h-6.9749l-3.3339 16.801zm-9.3437 11.669-4.8692 24.785h-16.889l12.765-65.494h24.96q10.791 0 16.362 4.0358 5.5711 4.0358 5.5711 11.888 0 7.9399-4.3867 13.072-4.3867 5.1324-11.888 5.8782 3.4216 0.70187 5.7027 3.5094 2.2811 2.7636 3.9919 8.5102l5.5711 18.6h-16.801l-4.9131-16.275q-1.4915-4.8692-3.641-6.6678-2.1056-1.8424-6.1414-1.8424z"/>
|
||||
<path d="m-114 343.22q0-7.7206-3.5094-11.756-3.4655-4.0358-10.089-4.0358-8.7734 0-14.739 7.8961-5.9221 7.8522-5.9221 19.696 0 7.5451 3.4655 11.713t9.6508 4.1674q5.0447 0 8.9489-2.1056 3.948-2.1495 6.7117-6.3169 2.632-3.9919 4.0358-8.9928 1.4476-5.0008 1.4476-10.265zm-11.142-28.031q13.072 0 21.012 7.2819 7.9838 7.2381 7.9838 18.951 0 7.9838-2.4566 15.09-2.4127 7.1065-7.0626 12.765-5.7027 6.9749-13.511 10.44-7.7645 3.4216-17.942 3.4216-13.029 0-20.968-7.2381-7.9399-7.2381-7.9399-18.994 0-8.0277 2.4127-15.134t7.1065-12.809q5.615-6.931 13.379-10.353 7.8083-3.4216 17.986-3.4216z"/>
|
||||
<path d="m-78.244 316.37h16.889l-10.265 52.728h29.566l-2.4127 12.765h-46.543z"/>
|
||||
<path d="m8.4808 369.93h-26.145l-6.4923 11.932h-17.328l37.024-65.494h19.302l11.581 65.494h-16.055zm-19.784-11.888h17.591l-3.948-25.224z"/>
|
||||
<path d="m69.807 341.73q4.5183 0 7.0626-2.2811t2.5443-6.273q0-2.5882-1.7986-3.948-1.7547-1.3599-5.0886-1.3599h-9.4314l-2.7198 13.862zm-5.0008 28.645q5.7905 0 8.905-2.7636 3.1146-2.7636 3.1146-7.9399 0-3.29-2.1495-4.8692-2.1495-1.5792-6.5801-1.5792h-9.9578l-3.3339 17.152zm20.003-23.557q4.299 1.2283 6.6239 4.5183 2.3688 3.2462 2.3688 8.0716 0 10.572-7.8961 16.538-7.8522 5.9221-22.109 5.9221h-28.031l12.765-65.494h25.311q11.669 0 17.24 3.4216 5.615 3.4216 5.615 10.572 0 6.0098-3.29 10.572-3.29 4.5183-8.5979 5.8782z"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
Before Width: | Height: | Size: 5.4 KiB |
@ -1,25 +0,0 @@
|
||||
<svg width="2048" height="1935.1" version="1.1" viewBox="0 0 541.87 512" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
<defs>
|
||||
<linearGradient id="linearGradient22598" x1="-143.43" x2="-143.43" y1="645.46" y2="751.2" gradientTransform="matrix(8.122 0 0 8.122 2145 -4828.8)" gradientUnits="userSpaceOnUse">
|
||||
<stop stop-color="#faf327" offset="0"/>
|
||||
<stop stop-color="#fa2c8d" offset="1"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="linearGradient22600" x1="-33.991" x2="-25.952" y1="344.73" y2="362.6" gradientTransform="translate(18.881 -401.29)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient19205"/>
|
||||
<linearGradient id="linearGradient19205">
|
||||
<stop stop-color="#f95" offset="0"/>
|
||||
<stop stop-color="#fff" stop-opacity="0" offset="1"/>
|
||||
</linearGradient>
|
||||
<linearGradient id="linearGradient22602" x1="-33.991" x2="-25.952" y1="344.73" y2="362.6" gradientTransform="matrix(.49643 0 0 .49643 -126.98 -208.56)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient19205"/>
|
||||
<linearGradient id="linearGradient22604" x1="-33.991" x2="-25.952" y1="344.73" y2="362.6" gradientTransform="matrix(.64523 0 0 .64523 -113.31 -194.34)" gradientUnits="userSpaceOnUse" xlink:href="#linearGradient19205"/>
|
||||
</defs>
|
||||
<g transform="translate(164.04 182.34)">
|
||||
<g transform="matrix(3.5327 0 0 3.5327 383.6 103.21)" stroke-width=".73932">
|
||||
<path transform="matrix(.12312 0 0 .12312 -205.52 -110.84)" d="m995.89 373.2a434.86 434.86 0 0 0-434.86 434.86 434.86 434.86 0 0 0 0.48047 20.422h868.77a434.86 434.86 0 0 0 0.4805-20.422 434.86 434.86 0 0 0-434.86-434.86zm-426.51 519.71a434.86 434.86 0 0 0 8.8066 36.123h835.4a434.86 434.86 0 0 0 8.8066-36.123zm33.141 100.54a434.86 434.86 0 0 0 17.799 33.828h751.13a434.86 434.86 0 0 0 17.801-33.828zm45.984 76.205a434.86 434.86 0 0 0 26.217 31.594h642.33a434.86 434.86 0 0 0 26.219-31.594zm69.4 72.82a434.86 434.86 0 0 0 34.543 25.926h486.88a434.86 434.86 0 0 0 34.545-25.926zm124.95 72.633a434.86 434.86 0 0 0 153.04 27.82 434.86 434.86 0 0 0 153.04-27.82z" fill="url(#linearGradient22598)" style="mix-blend-mode:normal"/>
|
||||
<g>
|
||||
<circle cx="-17.476" cy="-50.398" r="11.615" fill="url(#linearGradient22600)" style="mix-blend-mode:normal"/>
|
||||
<circle cx="-145.03" cy="-34.367" r="5.7663" fill="url(#linearGradient22602)" style="mix-blend-mode:normal"/>
|
||||
<circle cx="-136.77" cy="32.057" r="7.4946" fill="url(#linearGradient22604)" style="mix-blend-mode:normal"/>
|
||||
</g>
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
Before Width: | Height: | Size: 2.4 KiB |
@ -24,7 +24,7 @@ test.describe('Notebook', () => {
|
||||
test('Title should be rendered', async ({ page, tmpPath }) => {
|
||||
await page.goto(`notebooks/${tmpPath}/${NOTEBOOK}`);
|
||||
const href = await page.evaluate(() => {
|
||||
return document.querySelector('#jp-RetroLogo')?.getAttribute('href');
|
||||
return document.querySelector('#jp-NotebookLogo')?.getAttribute('href');
|
||||
});
|
||||
expect(href).toContain('/tree');
|
||||
});
|
||||
|
@ -17,10 +17,10 @@ export async function runAndAdvance(
|
||||
export async function waitForKernelReady(
|
||||
page: IJupyterLabPageFixture
|
||||
): Promise<void> {
|
||||
await page.waitForSelector('.jp-RetroKernelStatus-fade');
|
||||
await page.waitForSelector('.jp-NotebookKernelStatus-fade');
|
||||
await page.waitForFunction(() => {
|
||||
const status = window.document.getElementsByClassName(
|
||||
'jp-RetroKernelStatus'
|
||||
'jp-NotebookKernelStatus'
|
||||
)[0];
|
||||
|
||||
if (!status) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user