Commit Graph

225 Commits

Author SHA1 Message Date
Cory Rivera
8e04d3992a Register additional editor overrides when adding new notebook file types (#17708)
* Also standardized file extension contributions to always start with a period, and to always do lower case string comparisons for file extensions.
2021-11-19 09:14:41 -08:00
Maddy
1d3debb897 Maddy/edit mode events cleanup (#17636)
* remove multiple events

* correct preview check

* add test
2021-11-10 10:59:29 -08:00
Cory Rivera
329ea4103c Make various enhancements to Notebook Provider registration. (#17609)
* Use built-in SQL ExecuteProvider by default if no other provider exists.

* Gracefully handle case where standardKernels are not defined for a provider.

* Standardize on just using arrays for various provider registration details.
2021-11-09 16:00:34 -08:00
Daniel Grajeda
6200a61382 Notebook Views initialization fix (#17109)
Separate the Views load from the initialization. This way we can load previously created views, and only add the new views data to the document when needed. For now, this happens only when a view is created.
2021-10-22 14:50:21 -07:00
rajeshka
914ac2b09d remove trailing line after the cursor (#17431)
* remove trailing line after the cursor

* Addressed PR
2021-10-21 11:04:31 -07:00
rajeshka
d251bbd1a1 Fix for Split Cell duplicates cell #17400 (#17417) 2021-10-20 14:47:58 -07:00
Lucy Zhang
e315115f00 Hide notebook toolbar icons in diff editor (#17303)
* hide notebook toolbar icons in diff editor

* move showActions to notebookInput

* make showActions readonly
2021-10-15 05:19:14 -07:00
Maddy
53ab99761f save lastEditMode and use that as default (#17206)
* save lastEditMode

* change style to active

* addActiveClassFromEditMode

* add undefined to declaration

* remove from public interface

* private

* lastEditMode to last selected mode

* comments

* set active in one place

* rename method
2021-10-14 11:01:54 -07:00
rajeshka
f5331e3d69 Added code to enable disable split cell icon (#17331)
* Added code to enable diable split cell icon

* adding back the deleted code

* refactored

* minimized lines

* simplified code

* minor change

* minor change

* Addressed PR

* Addressed PR

* removing unused enum value
2021-10-11 09:47:25 -07:00
Maddy
f88bef8b4c save richTextCursorPosition/markdownCursorPosition (#17180)
* save richTextCursorPosition/markdownCursorPosition

* rename variables

* check to see if the nodes exist

* added comments

* add comments

* check if valid offset

* pr comments

* sqllint error fix
2021-10-06 23:24:22 -07:00
Cory Rivera
56e961c972 Fix issues with notebook providers not appearing, or being waited on for too long during startup. (#17288) 2021-10-06 21:58:24 -07:00
rajeshka
671c062e59 Split notebookcell (#17185)
* Initial Split code

* minor change

* minor changes

* Added split cell button to initActionBar, created split cell class to pss cell context.

* added changes

* fixed index

* Split Cell Working in markdown mode

* Fixed highlighting

* Preserve the edit state

* Added new icon and updated styles and cellToolbar component with new icon name.

* Addressed PR

* Addressed PR

* Added back isEditMode flag

* Moved split action to after edit toggle.

* Fixed typo

* Addressed PR

* Addressed PR

* Removed deletion of the cell

* fixed the comments

Co-authored-by: Hale Rankin <harankin@microsoft.com>
2021-10-06 18:18:22 -07:00
Cory Rivera
14904bb671 Split up NotebookProvider into separate providers for handling file serialization and cell execution. (#17176) 2021-09-29 16:15:28 -07:00
Daniel Grajeda
08acd6aadc Notebook Views grid fixes (#17170) 2021-09-28 14:52:00 -07:00
Vasu Bhog
db1d3cc517 Markdown Horizontal Scrollbar Fix (#17083)
* dynamically change horizontal scrollbar

* working horizontal scrollbar

* created new event to handle both scrollbar and mouse wheel

* only show scrollbar when needed
2021-09-27 16:54:43 -07:00
Daniel Grajeda
4a715e473a Add guids to RunAll and RunCell events (#17123)
Add guids to RunAll and RunCell events
2021-09-21 20:56:46 -07:00
Justin M
dec5be6915 Set kernelAlias in startSession when isValidConnection is truthy (#17102) 2021-09-20 14:01:21 -07:00
Chris LaFreniere
502feba76d Hide suggest widget on cell execution (#16895)
* Hide suggest widget on cell execution

* Also hide for query editor

* Fix compile issue with tests
2021-09-01 16:27:08 -07:00
Daniel Grajeda
e02ae0865a Notebook Views Insert Cells Modal (#16836)
* Add html-to-image package

* Add image card type
2021-08-31 13:11:21 -07:00
Cory Rivera
cb7b7da0a4 Merge from vscode e3c4990c67c40213af168300d1cfeb71d680f877 (#16569) 2021-08-25 16:28:29 -07:00
Daniel Grajeda
640c6f30f4 Notebook views UI 2 (#15865)
Provide access to the Notebook Views UI. Feature is hidden behind a feature flag.

Co-authored-by: rkselfhost <rkselfhost@outlook.com>
2021-08-17 14:15:28 -07:00
Daniel Grajeda
e2dd257fa9 Add Notebook Views dropdown (#16228)
This adds the entry point to NVs. It is currently hidden behind a feature flag, which can be enabled in the settings.
2021-08-03 21:15:11 -07:00
Daniel Grajeda
c5c7ca019d Notebook Views autodash feature (#16238)
The autodash feature in notebook views creates an initial grid layout for users when a view is created. It is intended to reduce the effort required by the user to start editing their view. Instead of displaying every cell and stacking them vertically like the default notebook layout, we use guidelines to determine which cells are worth displaying and how to arrange them.
2021-07-21 20:46:58 -07:00
Charles Gagnon
8faa0cf0e2 Update compile pipeline and fix eslint (#16129)
* Update pipelines

* eslint

* Fix layering

* update tsec exemption
2021-07-14 14:43:23 -07:00
Maddy
90b90afeab remove images from metadata on source update (#15640)
* remove images from metadata on update

* update comment

* reset only on html update

* add comment

* fixes

Co-authored-by: chgagnon <chgagnon@microsoft.com>
2021-06-21 13:55:37 -07:00
Charles Gagnon
3cb2f552a6 Merge from vscode a348d103d1256a06a2c9b3f9b406298a9fef6898 (#15681)
* Merge from vscode a348d103d1256a06a2c9b3f9b406298a9fef6898

* Fixes and cleanup

* Distro

* Fix hygiene yarn

* delete no yarn lock changes file

* Fix hygiene

* Fix layer check

* Fix CI

* Skip lib checks

* Remove tests deleted in vs code

* Fix tests

* Distro

* Fix tests and add removed extension point

* Skip failing notebook tests for now

* Disable broken tests and cleanup build folder

* Update yarn.lock and fix smoke tests

* Bump sqlite

* fix contributed actions and file spacing

* Fix user data path

* Update yarn.locks

Co-authored-by: ADS Merger <karlb@microsoft.com>
2021-06-17 08:17:11 -07:00
Maddy
d04451985c Highlight all matches in Notebook on Find (#15562)
* iterate over every cell and highlight ranges.

* fix yellow for all matches and orange for current

* fix

* avoid duplicate deltaDecorations call

* initialize on declare
2021-06-04 15:45:51 -07:00
Maddy
b490d53284 Add image as attachment on copy/paste into cell (#15602)
* add pasted image as attachment

* handle duplicate image logic

* replace with regex

* address PR comments
2021-06-04 15:20:18 -07:00
Vasu Bhog
730367494b Run with Parameters learn more link to use correct format and kernels (#15547)
* indicate to users correct format and kernels

* add test for unsupported kernel

* replace with enum
2021-05-25 17:39:19 -07:00
Vasu Bhog
8a0c183114 fix changing kernels from kusto to other kernels (#15545) 2021-05-24 13:52:32 -07:00
Cory Rivera
d582a955dd Add Markdown as a default editing option for text cells (#15540) 2021-05-21 10:05:55 -07:00
Daniel Grajeda
2781279644 Notebook views UI (#13914)
* Add notebook editor

Introduce notebook editor component to allow for separate notebook displays in order to accomodate notebook views

* Localize notebook views configuration title

* Refactor view mode and remove the views configuration while it is unused

* Only fire view mode changed event when the value has been changed

* Remove notebook views contribution

* Add metadata capabilities

* Notebook views definitions

* Add notebook views models

* Views test

* Rename type arguments

* Additional tests

* Fix unused import

* Notebook views changes

* Add notebookviews.css

* Update notebookViewModel.ts

* Add cell toolbar styles

* Upgrade gridstack

* Add gridstack styles

* Remove ununsed references

These are part of the next PR and not available yet

* Remove gridstack static file

* Add gridstack as a module in the electron unit tests

* Spacing fixes

* Add copyright notice

* Remove commented code

* Spacing fixes in notebook styles

* Move handle svg to image

* Add typing for gridstack

* Move notebook styles to file

* Rename selector constant

* Rename grid css file

* Add nb-grid-stack class to views grid

* Cell toolbar style adjustments

* Remove unused imports

* Update .eslintrc.json

* Fix outdated instantiation of LabeledMenuItemActionItem

* Address feedback

* Fix from update to main
2021-05-17 10:16:43 -07:00
Maddy
1af8fdbb45 fix attach image on rehydration (#15359) 2021-05-06 17:13:00 -07:00
Maddy
ef8b26b7ae Insert local/online images using image call out (#15238)
* changes from Chris's branch and cell model updates

* get base64 value

* handle spaces in image names

* add comments

* add tests for imageCallOut dialog

* format document for hygiene errors

* address comments

* check base64 validity using regex

* replace space with regex

* add parameter and return type

* split into two functions

* move functions to fileUtilities

* correct import

* fix for layering issue

* revert file function changes
2021-04-30 19:43:55 -07:00
Maddy
bec1916c62 show notebook as trusted when it belongs to a trusted book (#15093)
* check for trusted books

* don't add to trustedNotebooksMomento

* update comment

* added comments

* remove empty line
2021-04-15 10:30:51 -07:00
Vasu Bhog
3a1885491f Update run w/parameters icon and increment parameterized notebook (#15127)
* update icon and increment parameterized notebook
2021-04-14 15:28:27 -07:00
Charles Gagnon
e7571410e0 Add notebook query event listeners before connect (#15136) 2021-04-14 15:09:18 -07:00
Vasu Bhog
58d0add46f Save Kusto Notebook with proper language notebook info (#15113)
* save kusto language info
2021-04-13 17:28:33 -07:00
Vasu Bhog
9f63653a53 Fixes notebook integration tests + running parameterized notebook (#15107)
* fix interface

* fix run all cells on new parameterized notebook

* add getNotebookUri function
2021-04-13 17:23:15 -07:00
Vasu Bhog
d76a6698a9 [Notebook] Run Parameters Action openNotebook Functionality in Core (#14978)
* NotebookService update

* openNotebook functionality in NbService

* Add tests for RunParametersAction
2021-04-08 14:48:37 -07:00
Maddy
43db30d1da Add more Notebook telemetry events (#14755)
* initial checkin

* telemetry for search in notebooks

* telemetry for move notebook

* address comments

* feedback changes

* fix tests paasing NullAdsTelemetryService

* move changeKernel telemetry higher up

* remove telemetry service

* Fix new Notebook events (#14982)

* Notebook telemetry fixes

* update2

* Move event location

* remove service

* remove unused

Co-authored-by: chgagnon <chgagnon@microsoft.com>
2021-04-05 16:08:39 -07:00
Chris LaFreniere
0d3112ef35 Adding Rendered Notebook Diff Option (#14860)
* First attempt nb diff preview

* First attempt nb diff preview

* Simplify everything

* Interim scroll one way

* Double scroll

* Add setting

* Add tests

* Add comment

* Fix tests

* first round PR comments

* Ensure scrollable portion has scrollbar in diff

* Fix sqllint errors, register events

* Fix scrolling, readonly
2021-04-02 14:49:52 -07:00
Charles Gagnon
4c2969d4ca Don't log race condition error (#14922) 2021-04-01 11:11:43 -07:00
Lucy Zhang
f59e9b5695 Notebooks: Use new Python installation after configuration change (#14765)
* start new jupyter server

* restart session working (removed extra code)

* only restart server once

* shutdown session first then stop server

* add comments remove extra lines

* add comment

* fix test

* only restart jupyter sessions

* Dispose jupytersessionmanager and create new one

* move restart server logic out of notebookmodel

* move methods to azdata proposed

* pr comment
2021-03-24 15:31:20 -07:00
Lucy Zhang
780ca84f9a Enable status bar for notebooks (#14817)
* enable status bar for notebooks

* add onCellExecutionStart event to notebook service

* fix test, change var name
2021-03-22 14:54:13 -07:00
Lucy Zhang
af19f93b78 clean up sqlnotebookmanager (#14793) 2021-03-18 15:01:14 -07:00
Vasu Bhog
0141db80bc [Notebook] Open Kernel Alias (Kusto) notebook with Kernel Alias (Kusto) as selected kernel (#14504)
* Open kernel alias notebook with kernel alias as selected kernel

* Add language info test

* fix test

Co-authored-by: Vasu Bhog <bhogvu@mail.uc.edu>
2021-03-04 12:36:25 -08:00
Chris LaFreniere
8c04266ff4 Notebooks: Persist Chart Data when Re-Executing Cell (#14512)
* empty chart

* Update chart data appropriately

* Adding tests

* wip, cleanup

* PR feedback
2021-03-03 22:40:11 -08:00
Chris LaFreniere
56dcd4ba50 Only serialize attachments in JSON if exists (#14516) 2021-03-03 09:06:16 -08:00
Chris LaFreniere
9273572d5a Fix cell attachment types (#14485) 2021-03-01 15:06:12 -08:00