* Document page now loads list of docs and displays selection
* DocumentsTabV2 now properly loads documents, show partition keys and display first doc with proper selection behavior. Move it to its own folder.
* Extract table in a separate component
* Resizable columns on the document table
* Fix selection behavior and some layout issue
* Adding table scrolling
* Fix NaN height issue
* Fix NaN height issue
* Fix column sizing + cell selection
* Improvement in width size. Add Load More
* Add react editor and pass column headers
* Dynamic columns for pk
* Fix initial columns size
* Add nav buttons
* Editing content updates buttons state
* Discard and save buttons working
* Fix save new document. Implement delete.
* Remove debug display
* Fix unexpand filter and reformat
* Fix compil issues
* Add refresh button
* Update column header placeholder style
* Implement delete multiple docs
* Fix multi delete
* Fix show/hide delete button
* Fix selection behavior
* Fix UX with buttons behavior and editor display
* Fix UX issue with not discarding edit changes
* Add some TODO's
* Remove debugging info and reformat
* Add mongo support
* Fix build issues
* Fix table header. Remove debug statement
* Restore broken nosql
* Fix mongo save new document/update document
* Fix bugs with clicking on newly created documents
* Fix comment
* Fix double fetch issue when clicking on an item
* Auto-select last document when saving new document
* Fix resourceTokenPartitionKey code
* Fix format
* Fix isQueryCopilotSampleContainer flag
* Fix unused code
* Call tab when updating error flag
* Destructure props to make useEffect dependencies work
* Fix loadStartKey
* minor update
* Fix format
* Add title to table
* Fix table coming off its container with unwanted horizontal scrollbar
* Increase table width. Fix eslint issue.
* Move refresh documents button from table back to DocumentsTabV2
* Fix load more text centering
* Don't show Load More if nothing to show
* Fix columns min width
* Add keyboard shortcuts
* Add keyboard handlers to load more and refresh button
* Add keyboard support to select table row
* Disable eslint issue from fluent library
* Connect cancel query button
* Add Fluent V9 theme for Fabric (#1821)
* Clean up dependencies and memoize internal functions and object. Move methods and object that don't depend on state outside of component.
* Fix filter disappearing when clicking Apply Filter
* Fix typo and format
* Implement bulk delete for nosql
* Replace filter ui components with fluent ui
* Remove jquery calls
* Migrate unit test to DocumentsTabV2
* Remove DocumentsTab and MongoDocumentsTab. Fix build issues.
* Properly handle activetab
* Remove comments and unused code
* Port keyboard shortcuts from commitId 1f4d0f2
* Port item editor shortcuts to improved Items tab branch (#1831)
* set filter focus on Ctrl+Shift+F
* implement filter enter/esc keybinds
* remove debugging
* Collapse filter when query is executed
* Fix monaco editor not happy when parent is null
* Fix how bulk delete operation gets called when no partition key
* Fix update id list after delete
* Fix deleteDocuments
* Fix build issue
* Fix bug in mongo delete
* Fix mongo delete flow
* Proper error handling in mongo
* Handle >100 bulk delete operations
* Add unit tests for DocumentsTableComponent
* More improvements to table unit tests
* Fix import. Disable selection test for now
* Add more DocumentsTab unit react tests
* Remove selection test
* Add more unit tests. Add lcov coverage report to display in vscode
* Move unit tests to correct file
* Add unit test on command bar
* Fix build issues
* Add more unit tests
* Remove unneeded call
* Add DocumentsTab for Mongo API
* Fix linting errors
* Update fluent ui v9 dependency. Color columns separation. Fix refresh button placement to not interfere with header cell width.
* Revert @fluentui/react-components to a safe version that compiles
* Add confirmation window when documents have been deleted
* Fix mongo unit tests
* Fix format
* Update src/Common/dataAccess/deleteDocument.ts
Co-authored-by: Ashley Stanton-Nurse <ashleyst@microsoft.com>
* Update src/Common/dataAccess/deleteDocument.ts
Co-authored-by: Ashley Stanton-Nurse <ashleyst@microsoft.com>
* Update src/Common/dataAccess/deleteDocument.ts
Co-authored-by: Ashley Stanton-Nurse <ashleyst@microsoft.com>
* Fix bug with markup. Simplify code.
* Protect against creating React editor without parent node
* Replace rendering tests with snapshot match
* Add test screenshot to troubleshoot e2e test
* Revert "Add test screenshot to troubleshoot e2e test"
This reverts commit 1b8138ade0.
* Attempt 2 at troubleshooting failing test
* Revert "Attempt 2 at troubleshooting failing test"
This reverts commit 3e51a593bf.
* Delete button now shows if one or more rows are selected
---------
Co-authored-by: Vsevolod Kukol <sevoku@microsoft.com>
Co-authored-by: Ashley Stanton-Nurse <ashleyst@microsoft.com>
* Update d3, webpack-dev-server, typedoc dependencies.
* Fix unit test failures.
* Revert change to snapshot as it doesn't seem required when running in
github.
* keyboard shortcuts using tinykeys
* refmt and fix lints
* retarget keyboard shortcuts to the body instead of the root element of the React component tree
* refmt
* Update src/Explorer/Menus/CommandBar/CommandBarUtil.tsx
Co-authored-by: Laurent Nguyen <laurent.nguyen@microsoft.com>
* add Save binding to New Item command bar
---------
Co-authored-by: Laurent Nguyen <laurent.nguyen@microsoft.com>
* Fix datatables issue and indicator not loading for Table API > Entities
* Fix jquery and datatables compile issues. Add patch for datatables.net-colreorder error in types
* Fix side panel size. Fix bug resizing side panel.
* Update PanelContainerComponent unit test snapshot
* Fix commented code
* cancel query option
* query timeout
* run prettier
* removed comments
* fixed npm run compile errors
* fixed tests
* fixed unit test errors
* fixed unit test errors
* fixed unit test errors
* fixed unit test errors
* fixed unit test errors
* increased min timeout
* added automatican cancel query option
* added react string format
* npm run format
* added unless automatic cancellation has been enabled
---------
Co-authored-by: Asier Isayas <aisayas@microsoft.com>
* Listen to iframe messages. Test posting message.
* Plug new container message to show New Container dialog
* Rename message action to type
* Fix format
* Fix format
* Remove console.log() statement
* Rework fabric init flow. Implement open Collection Tab from fabric.
* Rename method to better match its purpose
* Update src/hooks/useKnockoutExplorer.ts
Use connectionString from message
Co-authored-by: Vsevolod Kukol <sevoku@microsoft.com>
* Fix format
* For openTab action open first collection if not specified. Clean up FabricContract.
* Reformat FabricContracts
* Highlight current node selection using them token
* Reformat
* Automatically expand nodes in resource tree if underlying database or collection is expanded. Fix AllowedOrigins. Cleanup code.
* Fix format
* Fix lint issue
* Don't show the home screen for Fabric (#1636)
* Fix formatting
* Database name to open can be overridden by value in session storage
---------
Co-authored-by: Vsevolod Kukol <sevoku@microsoft.com>
* Alternate tree running fluentui v9 Tree component
* Fix tree update after sp, udf and trigger load
* Enable scrolling for subtrees
* Clean up duplicates
* Restore current tree
* Reformat
* Update package-lock.json
* Add carousel for quick start
* Put carousel behind feature flag
* Install type definition for react-youtube
* Install type definition for react-youtube
* Remove @types/youtube-player
* Move feature flag outside of quickstarttutorial component
[Preview this branch](https://cosmos-explorer-preview.azurewebsites.net/pull/762?feature.someFeatureFlagYouMightNeed=true)
The main change in this PR fixes the snapshot functionality in the Publish pane-related components. Because the code cell outputs are now rendered in their own iframes for security reasons, a single snapshot of the notebook is no longer possible: each cell output takes its own snapshot and the snapshots are collated on the main notebook snapshot.
- Move the snapshot functionality to notebook components: this removes the reference of the notebook DOM node that we must pass to the Publish pane via explorer.
- Add slice in the state and actions in notebook redux for notebook snapshot requests and result
- Add post robot message to take snapshots and receive results
- Add logic in `NotebookRenderer` to wait for all output snapshots done before taking the main one collating.
- Use `zustand` to share snapshot between Redux world and React world. This solves the issue of keeping the `PanelContainer` component generic, while being able to update its children (`PublishPanel` component) with the new snapshot.
Additional changes:
- Add `local()` in `@font-face` to check if font is already installed before downloading the font (must be done for Safari, but not Edge/Chrome)
- Add "Export output to image" menu item in notebook cell, since each cell output can take its own snapshot (which can be downloaded)
![image](https://user-images.githubusercontent.com/21954022/117454706-b5f16600-af46-11eb-8535-6bf99f3d9170.png)
This change enables notebooks to escape HTML (which is a vector for malicious attacks).
We import `MarkdownCell` from the `@nteract/stateful-components` sources so that we can point it to the version of `@nteract/markdown` which contains [this fix](e19c7cc590).
This is a temporary workaround from upgrading to `@nteract/stateful-components` to `7.0.0` which causes build and runtime issues see #599).