-
Notifications
You must be signed in to change notification settings - Fork 169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added jupyterlab-toparea-text widget example. #240
Added jupyterlab-toparea-text widget example. #240
Conversation
Thanks for submitting your first pull request! You are awesome! 🤗 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @ericsnekbytes
Could you add the new folder name in the following lists so it get taken into account:
- codemirror-extension extension-examples/package.json
Line 21 in eba1de1
"codemirror-extension",
Could you also clear a bit the files to align with the other examples:
- .github folder
- binder folder
- CHANGELOG.md
- LICENSE
- RELEASE.md
I let you replace the README by some prose describing the purpose of the example (see other examples like commands or main-menu).
This should be done. |
@fcollonval Can you re-review/approve this? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @ericsnekbytes
We want every examples to have integration tests to ease maintenance. Would you mind adding one?
It could be as simple as :
import { test, expect } from '@jupyterlab/galata';
test('should add a top area text', async ({ page }) => {
await expect(page.locator('.jp-TopAreaText')).toHaveText('Hello World');
});
You can execute
copier update .
to rerun the extension template to generate the skeleton files for integration tests.
I'll add this. |
@fcollonval If you have time to review I'd like to get this approved, the Dual Compatibility document (see top post description) depends on this example so this should be merged first. My plan now is to try to get the document and examples merged first, then do a follow-up PR for the unit tests and repo-referencing for the code snippets. |
8b68a42
to
85f01c2
Compare
https://jupyterlab.readthedocs.io/en/stable/developer/css.html | ||
*/ | ||
|
||
/* stylelint-disable selector-class-pattern */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to change this rule in config (in package JSON) here and in the template as it goes against our style conventions: https://jupyterlab.readthedocs.io/en/stable/developer/css.html#css-class-naming-conventions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I opened jupyterlab/extension-template#52
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We had a conversation in JupyterLab gitter and I believe Mike was okay with this, for the sake of preserving the original video tutorial's code verbatim (to reduce differences and help beginners).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/* stylelint-disable selector-class-pattern */ |
This can be removed given jupyterlab/extension-template#52, right?
Co-authored-by: Michał Krassowski <5832902+krassowski@users.noreply.github.com>
c4135d0
to
000755e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @ericsnekbytes
Merging... the remaining issue is due to the JupyterLab documentation not yet available
This adds the example toparea-text-widget from @jtpio's YouTube video. This example extension is a part of the JupyterLab Dual Compatibility Guide, and should be merged first before that document (as it depends on this example):