build
ci/woodpecker/push/woodpecker Pipeline was successful Details

This commit is contained in:
Malte Grosse 2024-02-12 13:55:08 +00:00
parent 5da76683e2
commit 2ae5a01ba3
16 changed files with 73 additions and 113 deletions

View File

@ -2,17 +2,17 @@
_commit: v4.2.5
_src_path: https://github.com/jupyterlab/extension-template
author_email: grosse@hdm-stuttgart.de
author_name: Sandbox Theme
author_name: Malte Grosse
data_format: string
file_extension: ''
has_binder: false
has_settings: false
kind: theme
labextension_name: sandbox_theme
labextension_name: jupyterlab-sandbox-theme
mimetype: ''
mimetype_name: ''
project_short_description: Sandbox Theme for JupyterLab
python_name: sandbox_theme
project_short_description: A JupyterLab Sandbox Theme extension.
python_name: jupyterlab_sandbox_theme
repository: https://git.sandbox.iuk.hdm-stuttgart.de/grosse/jupyterlab_sandbox_theme
test: false
viewer_name: ''

View File

@ -36,7 +36,7 @@ jobs:
python -m pip install .[test]
jupyter labextension list
jupyter labextension list 2>&1 | grep -ie "sandbox_theme.*OK"
jupyter labextension list 2>&1 | grep -ie "jupyterlab-sandbox-theme.*OK"
python -m jupyterlab.browser_check
- name: Package the extension
@ -45,13 +45,13 @@ jobs:
pip install build
python -m build
pip uninstall -y "sandbox_theme" jupyterlab
pip uninstall -y "jupyterlab_sandbox_theme" jupyterlab
- name: Upload extension packages
uses: actions/upload-artifact@v3
with:
name: extension-artifacts
path: dist/sandbox_theme*
path: dist/jupyterlab_sandbox_theme*
if-no-files-found: error
test_isolated:
@ -74,11 +74,11 @@ jobs:
sudo rm -rf $(which node)
sudo rm -rf $(which node)
pip install "jupyterlab>=4.0.0,<5" sandbox_theme*.whl
pip install "jupyterlab>=4.0.0,<5" jupyterlab_sandbox_theme*.whl
jupyter labextension list
jupyter labextension list 2>&1 | grep -ie "sandbox_theme.*OK"
jupyter labextension list 2>&1 | grep -ie "jupyterlab-sandbox-theme.*OK"
python -m jupyterlab.browser_check --no-browser-test

View File

@ -26,5 +26,5 @@ jobs:
- name: Upload Distributions
uses: actions/upload-artifact@v3
with:
name: sandbox_theme-releaser-dist-${{ github.run_number }}
name: jupyterlab_sandbox_theme-releaser-dist-${{ github.run_number }}
path: .jupyter_releaser_checkout/dist

4
.gitignore vendored
View File

@ -7,9 +7,9 @@ node_modules/
*.egg-info/
.ipynb_checkpoints
*.tsbuildinfo
sandbox_theme/labextension
jupyterlab_sandbox_theme/labextension
# Version file is handled by hatchling
sandbox_theme/_version.py
jupyterlab_sandbox_theme/_version.py
# Created by https://www.gitignore.io/api/python
# Edit at https://www.gitignore.io/?templates=python

View File

@ -3,4 +3,4 @@ node_modules
**/lib
**/package.json
!/package.json
sandbox_theme
jupyterlab_sandbox_theme

View File

@ -1,6 +1,6 @@
BSD 3-Clause License
Copyright (c) 2024, Sandbox Theme
Copyright (c) 2024, Malte Grosse
All rights reserved.
Redistribution and use in source and binary forms, with or without

View File

@ -1,7 +1,7 @@
# sandbox_theme
# jupyterlab_sandbox_theme
[![Github Actions Status](https://git.sandbox.iuk.hdm-stuttgart.de/grosse/jupyterlab_sandbox_theme/workflows/Build/badge.svg)](https://git.sandbox.iuk.hdm-stuttgart.de/grosse/jupyterlab_sandbox_theme/actions/workflows/build.yml)
Sandbox Theme for JupyterLab
A JupyterLab Sandbox Theme extension.
## Requirements
@ -12,7 +12,7 @@ Sandbox Theme for JupyterLab
To install the extension, execute:
```bash
pip install sandbox_theme
pip install jupyterlab_sandbox_theme
```
## Uninstall
@ -20,7 +20,7 @@ pip install sandbox_theme
To remove the extension, execute:
```bash
pip uninstall sandbox_theme
pip uninstall jupyterlab_sandbox_theme
```
## Contributing
@ -35,7 +35,7 @@ The `jlpm` command is JupyterLab's pinned version of
```bash
# Clone the repo to your local environment
# Change directory to the sandbox_theme directory
# Change directory to the jupyterlab_sandbox_theme directory
# Install package in development mode
pip install -e "."
# Link your development version of the extension with JupyterLab
@ -64,12 +64,12 @@ jupyter lab build --minimize=False
### Development uninstall
```bash
pip uninstall sandbox_theme
pip uninstall jupyterlab_sandbox_theme
```
In development mode, you will also need to remove the symlink created by `jupyter labextension develop`
command. To find its location, you can run `jupyter labextension list` to figure out where the `labextensions`
folder is located. Then you can remove the symlink named `sandbox_theme` within that folder.
folder is located. Then you can remove the symlink named `jupyterlab-sandbox-theme` within that folder.
### Packaging the extension

View File

@ -1,4 +1,4 @@
# Making a new release of sandbox_theme
# Making a new release of jupyterlab_sandbox_theme
The extension can be published to `PyPI` and `npm` manually or using the [Jupyter Releaser](https://github.com/jupyter-server/jupyter_releaser).

View File

@ -1,5 +1,5 @@
{
"packageManager": "python",
"packageName": "sandbox_theme",
"uninstallInstructions": "Use your Python package manager (pip, conda, etc.) to uninstall the package sandbox_theme"
"packageName": "jupyterlab_sandbox_theme",
"uninstallInstructions": "Use your Python package manager (pip, conda, etc.) to uninstall the package jupyterlab_sandbox_theme"
}

View File

@ -5,12 +5,12 @@ except ImportError:
# in editable mode with pip. It is highly recommended to install
# the package from a stable release or in editable mode: https://pip.pypa.io/en/stable/topics/local-project-installs/#editable-installs
import warnings
warnings.warn("Importing 'sandbox_theme' outside a proper installation.")
warnings.warn("Importing 'jupyterlab_sandbox_theme' outside a proper installation.")
__version__ = "dev"
def _jupyter_labextension_paths():
return [{
"src": "labextension",
"dest": "sandbox_theme"
"dest": "jupyterlab-sandbox-theme"
}]

View File

@ -1,7 +1,7 @@
{
"name": "jupyterlab-sandbox-theme",
"version": "0.1.4",
"description": "Sandbox Theme for JupyterLab",
"description": "A JupyterLab Sandbox Theme extension.",
"keywords": [
"jupyter",
"jupyterlab",
@ -13,7 +13,7 @@
},
"license": "BSD-3-Clause",
"author": {
"name": "Sandbox Theme",
"name": "Malte Grosse",
"email": "grosse@hdm-stuttgart.de"
},
"files": [
@ -37,7 +37,7 @@
"clean": "jlpm clean:lib",
"clean:lib": "rimraf lib tsconfig.tsbuildinfo",
"clean:lintcache": "rimraf .eslintcache .stylelintcache",
"clean:labextension": "rimraf sandbox_theme/labextension sandbox_theme/_version.py",
"clean:labextension": "rimraf jupyterlab_sandbox_theme/labextension jupyterlab_sandbox_theme/_version.py",
"clean:all": "jlpm clean:lib && jlpm clean:labextension && jlpm clean:lintcache",
"eslint": "jlpm eslint:check --fix",
"eslint:check": "eslint . --cache --ext .ts,.tsx",
@ -89,7 +89,7 @@
},
"jupyterlab": {
"extension": true,
"outputDir": "sandbox_theme/labextension",
"outputDir": "jupyterlab_sandbox_theme/labextension",
"themePath": "style/index.css"
},
"eslintIgnore": [

View File

@ -3,7 +3,7 @@ requires = ["hatchling>=1.5.0", "jupyterlab>=4.0.0,<5", "hatch-nodejs-version>=0
build-backend = "hatchling.build"
[project]
name = "sandbox_theme"
name = "jupyterlab_sandbox_theme"
readme = "README.md"
license = { file = "LICENSE" }
requires-python = ">=3.8"
@ -33,23 +33,23 @@ source = "nodejs"
fields = ["description", "authors", "urls"]
[tool.hatch.build.targets.sdist]
artifacts = ["sandbox_theme/labextension"]
artifacts = ["jupyterlab_sandbox_theme/labextension"]
exclude = [".github", "binder"]
[tool.hatch.build.targets.wheel.shared-data]
"sandbox_theme/labextension" = "share/jupyter/labextensions/sandbox_theme"
"install.json" = "share/jupyter/labextensions/sandbox_theme/install.json"
"jupyterlab_sandbox_theme/labextension" = "share/jupyter/labextensions/jupyterlab-sandbox-theme"
"install.json" = "share/jupyter/labextensions/jupyterlab-sandbox-theme/install.json"
[tool.hatch.build.hooks.version]
path = "sandbox_theme/_version.py"
path = "jupyterlab_sandbox_theme/_version.py"
[tool.hatch.build.hooks.jupyter-builder]
dependencies = ["hatch-jupyter-builder>=0.5"]
build-function = "hatch_jupyter_builder.npm_builder"
ensured-targets = [
"sandbox_theme/labextension/package.json",
"jupyterlab_sandbox_theme/labextension/package.json",
]
skip-if-exists = ["sandbox_theme/labextension/static/style.js"]
skip-if-exists = ["jupyterlab_sandbox_theme/labextension/static/style.js"]
[tool.hatch.build.hooks.jupyter-builder.build-kwargs]
build_cmd = "build:prod"
@ -59,7 +59,7 @@ npm = ["jlpm"]
build_cmd = "install:extension"
npm = ["jlpm"]
source_dir = "src"
build_dir = "sandbox_theme/labextension"
build_dir = "jupyterlab_sandbox_theme/labextension"
[tool.jupyter-releaser.options]
version_cmd = "hatch version"

View File

@ -2,22 +2,22 @@ import { ILabShell, JupyterFrontEnd, JupyterFrontEndPlugin} from '@jupyterlab/ap
import { IThemeManager, ISplashScreen} from '@jupyterlab/apputils';
import { LabIcon, jupyterFaviconIcon, jupyterIcon, jupyterlabWordmarkIcon } from '@jupyterlab/ui-components';
import { Widget } from '@lumino/widgets';
import { Logo,FavIconIdle,FavIconBusy} from './images';
/**
* Initialization data for the sandbox_theme extension.
*/
const plugin: JupyterFrontEndPlugin<void> = {
id: 'sandbox_theme:plugin',
id: 'jupyterlab-sandbox-theme:plugin',
description: 'Sandbox Theme for JupyterLab',
autoStart: true,
requires: [IThemeManager,ILabShell,ISplashScreen],
activate: (app: JupyterFrontEnd, manager: IThemeManager, shell: ILabShell) => {
console.log('JupyterLab extension sandbox_theme is activated!');
const style = 'sandbox_theme/index.css';
const style = 'jupyterlab-sandbox-theme/index.css';
const logo_svg = Logo
const logo_icon = new LabIcon({ name: 'ui-components:sandbox', svgstr: logo_svg });

4
src/typings.d.ts vendored
View File

@ -1,4 +0,0 @@
declare module '*.svg' {
const script: string;
export default script;
}

View File

@ -1,36 +0,0 @@
<svg version="1.0" xmlns="http://www.w3.org/2000/svg"
width="512.000000pt" height="512.000000pt" viewBox="0 0 512.000000 512.000000"
preserveAspectRatio="xMidYMid meet">
<g transform="translate(0.000000,512.000000) scale(0.100000,-0.100000)"
fill="#000000" stroke="none">
<path d="M2365 5114 c-652 -67 -1178 -310 -1614 -745 -405 -405 -649 -902
-733 -1494 -17 -118 -17 -512 0 -630 84 -592 328 -1089 733 -1494 405 -405
902 -649 1494 -733 118 -17 512 -17 630 0 592 84 1089 328 1494 733 405 405
649 902 733 1494 17 118 17 512 0 630 -84 592 -328 1089 -733 1494 -395 395
-883 639 -1449 726 -101 15 -468 28 -555 19z m1255 -641 c91 -25 212 -58 269
-74 57 -15 106 -30 108 -33 10 -10 -112 -341 -142 -386 -16 -24 -52 -58 -79
-75 -45 -27 -57 -30 -138 -30 l-88 0 -55 -150 c-30 -82 -77 -211 -103 -285
l-49 -135 62 -20 c147 -48 225 -148 225 -288 0 -46 -27 -132 -133 -429 -34
-95 -34 -98 -15 -114 22 -21 53 -70 62 -101 7 -21 0 -19 -89 22 -410 190 -868
282 -1274 255 -78 -6 -154 -12 -169 -15 l-27 -6 30 17 c102 59 264 107 420
125 55 6 101 13 103 14 3 3 82 207 82 212 0 7 -197 2 -300 -7 -406 -37 -846
-182 -1256 -414 l-82 -46 -146 63 c-80 34 -146 65 -146 68 0 3 89 40 198 82
108 42 285 110 392 152 204 79 485 189 605 235 39 15 147 57 240 93 94 36 222
86 286 111 l116 45 79 -30 c166 -64 149 -60 175 -33 74 78 248 106 370 59 13
-5 26 20 67 137 28 79 74 208 102 286 28 79 50 145 48 146 -2 1 -22 10 -45 20
-81 35 -135 118 -135 206 0 39 26 121 126 396 3 8 24 6 73 -8 37 -10 142 -39
233 -65z m428 -1705 c177 -67 322 -124 322 -127 0 -3 -66 -35 -146 -70 l-146
-64 -57 32 c-31 17 -123 66 -206 107 -82 42 -152 78 -154 80 -5 4 52 164 59
164 3 0 150 -54 328 -122z m-2723 -528 c385 -171 798 -355 917 -408 l218 -97
0 -468 0 -469 -33 20 c-17 11 -84 49 -147 84 -63 36 -335 190 -605 343 -269
153 -578 327 -685 388 -107 61 -251 143 -320 182 l-125 71 -3 352 -2 351 42
-18 c24 -10 358 -159 743 -331z m3195 -3 l0 -353 -62 -36 c-35 -20 -151 -85
-258 -146 -537 -303 -1368 -772 -1470 -830 -63 -35 -118 -67 -122 -69 -5 -2
-8 206 -8 464 l0 468 278 123 c152 67 583 259 957 426 374 168 681 305 683
305 1 1 2 -158 2 -352z"/>
<path d="M3425 4308 c-2 -7 -13 -38 -25 -68 -23 -63 -25 -93 -7 -108 6 -6 70
-27 140 -47 113 -32 130 -35 149 -23 19 13 83 156 73 166 -5 5 -305 92 -318
92 -4 0 -10 -6 -12 -12z"/>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.2 KiB

View File

@ -3305,6 +3305,37 @@ __metadata:
languageName: node
linkType: hard
"jupyterlab-sandbox-theme@workspace:.":
version: 0.0.0-use.local
resolution: "jupyterlab-sandbox-theme@workspace:."
dependencies:
"@jupyterlab/application": ^4.0.0
"@jupyterlab/apputils": ^4.0.0
"@jupyterlab/builder": ^4.0.0
"@types/json-schema": ^7.0.11
"@types/react": ^18.0.26
"@types/react-addons-linked-state-mixin": ^0.14.22
"@typescript-eslint/eslint-plugin": ^6.1.0
"@typescript-eslint/parser": ^6.1.0
css-loader: ^6.7.1
eslint: ^8.36.0
eslint-config-prettier: ^8.8.0
eslint-plugin-prettier: ^5.0.0
npm-run-all: ^4.1.5
prettier: ^3.0.0
rimraf: ^5.0.1
source-map-loader: ^1.0.2
style-loader: ^3.3.1
stylelint: ^15.10.1
stylelint-config-recommended: ^13.0.0
stylelint-config-standard: ^34.0.0
stylelint-csstree-validator: ^3.0.0
stylelint-prettier: ^4.0.0
typescript: ~5.0.2
yjs: ^13.5.0
languageName: unknown
linkType: soft
"keyv@npm:^4.5.3":
version: 4.5.4
resolution: "keyv@npm:4.5.4"
@ -4401,37 +4432,6 @@ __metadata:
languageName: node
linkType: hard
"sandbox_theme@workspace:.":
version: 0.0.0-use.local
resolution: "sandbox_theme@workspace:."
dependencies:
"@jupyterlab/application": ^4.0.0
"@jupyterlab/apputils": ^4.0.0
"@jupyterlab/builder": ^4.0.0
"@types/json-schema": ^7.0.11
"@types/react": ^18.0.26
"@types/react-addons-linked-state-mixin": ^0.14.22
"@typescript-eslint/eslint-plugin": ^6.1.0
"@typescript-eslint/parser": ^6.1.0
css-loader: ^6.7.1
eslint: ^8.36.0
eslint-config-prettier: ^8.8.0
eslint-plugin-prettier: ^5.0.0
npm-run-all: ^4.1.5
prettier: ^3.0.0
rimraf: ^5.0.1
source-map-loader: ^1.0.2
style-loader: ^3.3.1
stylelint: ^15.10.1
stylelint-config-recommended: ^13.0.0
stylelint-config-standard: ^34.0.0
stylelint-csstree-validator: ^3.0.0
stylelint-prettier: ^4.0.0
typescript: ~5.0.2
yjs: ^13.5.0
languageName: unknown
linkType: soft
"sanitize-html@npm:~2.7.3":
version: 2.7.3
resolution: "sanitize-html@npm:2.7.3"