Commit Graph

1193 Commits

Author SHA1 Message Date
Radosław Waśko
c401694fa9
Add missing icon to Excel DataLink schema (#9370)
I forgot to do this in the previous PR #9346, so following up.
2024-03-11 22:46:01 +00:00
James Dunkerley
29784de391
Fix issues with labels in qualified entry names. (#9368)
- Use label for entries by qualified name.
![image](https://github.com/enso-org/enso/assets/4699705/e299dae7-7165-4bde-a055-dc5c05326a15)
2024-03-11 22:27:59 +00:00
Radosław Waśko
e98306f170
Excel DataLink (#9346)
- Adds the Excel format as one of the formats supported when creating a data link.
- The data link can choose to read the file as a workbook, or read a sheet or range from it as a table, like `Excel_Format`.
- Also updated Delimited format dialog to allow customizing the quote style.
2024-03-11 16:12:12 +00:00
Kaz Wesley
1f6db1ef43
Move selections to a new layer (#9344)
Move selections to a new Vue component so that they don't interfere with clicking on edges.

https://github.com/enso-org/enso/assets/1047859/190006df-1402-4a5f-9117-f43788fa4187

# Important Notes
- The new `GraphNodeSelection` components are drawn in a `GraphNodeSelections` container. They are created by the `GraphNode`s and teleported so that the node can set properties directly.
2024-03-11 15:40:16 +00:00
Sergei Garin
b2215bed2c
Fix broken login flow (#9352) 2024-03-11 15:26:59 +00:00
Ilya Bogdanov
38ffcd09de
Use vue’s Transitions for animation of the placeholders (#9335)
Closes #9333

https://github.com/enso-org/enso/assets/6566674/705e23c2-0ee0-40b0-9919-9c320f8788c5
2024-03-11 13:29:53 +00:00
Ilya Bogdanov
793fb8f48e
Use labels from the engine if they are available (#9290)
Fix small regression on develop for dropdown labels.

<img width="645" alt="Screenshot 2024-03-05 at 7 09 22 PM" src="https://github.com/enso-org/enso/assets/6566674/caec9cbc-ef8d-4ac2-8ec1-cf2de909f2d4">
2024-03-11 10:56:56 +00:00
Kaz Wesley
8e437fa52a
Ast.Vector (#9328)
Add `Vector` AST type, corresponding to the `RawAst.Tree.Array` type (name `Array` not used for obvious reasons).

This is the first step of #5138.

### Important Notes

- Switched some string-based vector construction to `Vector.new`, improving type-safety.
- The `Ast` changes are covered by the round-trip tests; the use-site changes have been tested manually.
2024-03-08 15:14:06 -05:00
James Dunkerley
2df2d958ed
Correct bug with qualified name of Float. (#9341)
Numeric Input wasn't showing up for floats.
2024-03-08 19:11:23 +00:00
Kaz Wesley
dcad48e66f
Add-node buttons (#9247)
Introduce add-node button below circular menu or open visualization.

https://github.com/enso-org/enso/assets/1047859/aa6cedba-ca7e-44c5-ab27-2f5d5f9421e8
2024-03-08 19:00:39 +00:00
Kaz Wesley
614a5a610b
Zoom steps (#9327)
When zooming with Ctrl+wheel, used fixed-factor steps instead of scroll wheel rate information.

Fixes #9177.

Important Notes
  - Wheel events are distinguished from trackpad gestures, so that OS X pinch-zoom still works nicely.
  - When zooming with the mouse wheel, scale factor is rounded (geometrically) to the nearest power of √2, and then stepped up or down by the same factor; this ensures that round values like 100% are never skipped over.
  - Added directed-clamping logic, so that if the zoom is moved outside the clamping range of a zoom-method, it can be stepped back into range without jumping.
2024-03-08 13:33:54 -05:00
Paweł Grabarz
cee795b5e3
fix text caret not showing for empty input (#9336)
Fixes #9331

Fixed issues with wrong initial size and missing edit caret in text widgets.

<img width="311" alt="image" src="https://github.com/enso-org/enso/assets/919491/44f257cc-18a1-4a9f-9ae0-c1dd9b86674e">

# Important Notes
Automated tests for font loading/initial size will follow shortly. The text caret is not really testable, since it is a hosted object visual issue.
2024-03-08 18:03:23 +00:00
Ilya Bogdanov
df72b38f60
Visualizations fixes follow-up (#9252)
Addressing review suggestions from #9130

- Removing `N` binding
- Removing duplicated `Toggle fullscreen vis` binding

A few important differences from the suggested implementation:
1. There is no easy way to implement `nextType` on GraphEditor – we simply don’t have the required API
2. The keydown handler in `GraphVisualization` must be defined on window level still, otherwise it won’t get keydown events unless visualization is focused, and thus `nextType` won’t work because of (1)

No visual changes to the IDE.
2024-03-08 15:59:15 +00:00
Ilya Bogdanov
ed46fdcf18
Disable qualified name substitution (#9286)
As discussed in discord: https://discord.com/channels/401396655599124480/1201853512409939968/1214547995207663646
2024-03-08 12:57:20 +00:00
somebody1234
6c2b2383d3
Change "Override Execution Context" button to "Record" button on nodes (#9188)
- Close #9164
- Fix appearance of Record/Record Once icon in top menu
- Change icon for overriding execution context to record icon
- Unconditionally show per-node record icon if it is set
- Remove the ability to override the execution context to disabled
- Fix the icon for nodes with an overridden execution context always being the Enso icon

# Important Notes
None
2024-03-08 04:31:32 +00:00
somebody1234
d2f6b1026a
Refactor configuration keys out of repository (#8895)
- Close https://github.com/enso-org/cloud-v2/issues/866
- Remove *all* references to client keys and API base URLs from the codebase.
- The app can still be built by external contributors. *However*, the cloud backend (among some other things) will be completely disabled, as the required keys and base URLs will be missing.
- Add entry to `.gitignore` to allow `*.env` files in `app/ide-desktop/lib/dashboard/`

# Important Notes
- Tested (no `.env`; `.env` with prod backend; `.pbuchu.env`) on:
- `npm run dev` in `app/ide-desktop/lib/dashboard/`
- `./run ide build`
- `./run ide2 build`
- `./run gui watch`
2024-03-08 03:14:26 +00:00
somebody1234
0b271d4b04
Minor improvements (#9187)
- Close https://github.com/enso-org/cloud-v2/issues/918
- Close https://github.com/enso-org/cloud-v2/issues/920

# Important Notes
None
2024-03-08 03:04:13 +00:00
James Dunkerley
c7d693dfc8
Move Standard.Database.Data to Standard.Database. (#9321)
Moves the types out of `Data`.
2024-03-07 14:43:38 +00:00
Michael Mauderer
7c68bf170d
Remove gui1 codebase (#9242)
Removes the old GUI1 code base and reduces the Rust code footprint by removing unused code.

# Important Notes
Updates build scripts and reformats part of the codebase with the autoformatter.
2024-03-07 02:20:21 +00:00
Kaz Wesley
79a6a6a1c0
Pan to CB (#9273)
When the CB is opened, pan to show it.

Large screen:
<video src="https://github.com/enso-org/enso/assets/1047859/1a07c8cc-5818-420a-9fb3-1d1cb308cb87">

Small screen:
<video src="https://github.com/enso-org/enso/assets/1047859/a9f18df5-c0ca-426c-959a-bda5cd077541">

# Important Notes
A prioritized-coordinates approach is used to adjust panning goals based on screen space:
- Fitting the input area is highest-priority.
- If possible, the whole component panel area will be fit.
- If possible, the visualization preview will be fit.
- If there's extra room, margins will be included; the top and left are prioritized because those margins prevent overlap with fixed UI elements.
2024-03-06 20:09:56 +00:00
Paweł Grabarz
b7a8909818
Vue dependency update, better selection performance, visible quotes in text inputs (#9204)
- Improved performance by batching simulatenous node edits, including metadata updates when dragging many selected nodes together.
- Updated Vue to new version, allowing us to use `defineModel`.
- Fixed #9161
- Unified all handling of auto-blur by making `useAutoBlur` cheap to register - all logic goes through a single window event handler.
- Combined all `ResizeObserver`s into one.
- Fixed the behaviour of repeated toast messages. Now only the latest compilation status is visible at any given time, and the errors disappear once compilation passes.
- Actually fixed broken interaction of node and visualization widths. There no longer is a style feedback loop and the visible node backdrop width no longer jumps or randomly fails to update.
2024-03-06 15:34:07 +00:00
James Dunkerley
d4b2390fc1
Small change limiting the number of decimal places to 12 digits. (#9298)
Format numbers in the ag-grid so we don't get loads on pointless digits.
![image](https://github.com/enso-org/enso/assets/4699705/0731af47-1e7e-46f5-8bf3-5503ab74a8e3)
2024-03-06 14:08:43 +00:00
Radosław Waśko
e37862b09d
Implement a Data Link for Postgres (#9269)
- Closes #9124
2024-03-06 11:57:12 +00:00
Adam Obuchowicz
d2a0bdd9cd
Restore whenReady, as I do not see the freeze (#9262)
When cleaning up board, I stumbled upon https://github.com/enso-org/enso/issues/5851 I tried to replace whenReady, and it just worked. Perhaps the freeze was fixed during some electron version bump.

Tests on other platforms (I'm using Garuda Linux) advised.

Fixes #5851
2024-03-06 11:04:54 +00:00
somebody1234
d481ccac94
Extract tests to their own files (#9229)
Move tests to their own files, for consistency

# Important Notes
None
2024-03-06 09:53:12 +00:00
somebody1234
1cc7ca1338
Fix typechecking (#9279)
- Fix issue where `playwright-report/` is being typechecked by `npm run typecheck` in the dashboard, causing CI to fail
- Attempt to fix flaky dashboard test

# Important Notes
To test that typechecking isn't completely broken, it's recommended to intentionally create a type error in the dashboard code base.
2024-03-06 08:20:08 +00:00
somebody1234
618080b803
Hard delete of items in Trash (#9091)
- Close https://github.com/enso-org/cloud-v2/issues/698
- Requires https://github.com/enso-org/cloud-v2/pull/905

# Important Notes
None
2024-03-06 03:12:14 +00:00
Kaz Wesley
b0842feea2
Hide placeholders (#9246)
* New menuVisible logic

* Hide placeholders unless sole selected node, required argument, or requested by dynamic config
2024-03-05 09:16:38 -05:00
Adam Obuchowicz
ba9b7f199a
E2E test fixing and bring back reports (#9238)
After investigating some errors, I found another two missing awaits in our tests. Because those are so easy to overlook, I added a lint rule which makes failure on unhandled promise (for e2e tests only).

Also, enabled HTML reports again, with traces this time, to enable closer investigation of any failure in the future. @mwu-tow added code for uploading them in GH.
2024-03-05 07:06:11 +00:00
Ilya Bogdanov
9ee4348ee5
Add delete node icon to circular menu (#9264)
Closes #9168, also adds `Show full menu` icon back and hides `edit comment`.

https://github.com/enso-org/enso/assets/6566674/43af88a7-2b08-4f7d-8f4a-f47b41e51b2e
2024-03-04 16:05:56 +00:00
Ilya Bogdanov
6f4963d7d1
Add imports on editing nodes (#9253)
Closes #9241

Demonstration with import conflict resolution:


https://github.com/enso-org/enso/assets/6566674/2397ecf1-7d77-4fa9-93bc-15b81d7fd042
2024-03-04 14:43:15 +00:00
Michael Mauderer
94666e6727
Dropdown widget improvements. (#9186)
Closes  #8995

[Peek 2024-03-01 16-06.webm](https://github.com/enso-org/enso/assets/1428930/3f62aad8-8426-4f8f-b49e-57769b22bfb4)
2024-03-04 12:54:38 +00:00
Ilya Bogdanov
3be5e585f2
Imports conflict resolution (#9093)
Closes #5353


When name conflict is detected, we use fully qualified name instead of the usual one.

https://github.com/enso-org/enso/assets/6566674/2dab40ce-b925-4443-ab37-acd0a8968e47
2024-03-04 11:17:53 +00:00
somebody1234
b4cea527db
Add Warning indicator. (#9160)
- Close #9125
- Display the new warning icon to the left of the node, when the node is not being hovered over.

# Important Notes
None
2024-03-04 10:16:08 +00:00
Kaz Wesley
44a1d9138b
Create and edit comments (#9230)
* CodeEditor: Fix dynamic imports

* Doc editing: AST support

* Doc editing

* Button and comment creation

* Fix concrete syntax edge case

* Remove testing code

* Fix
2024-03-01 12:56:18 -05:00
Kaz Wesley
ac4bbd89c7
Close dropdowns (#9206)
Fixes #7562. Close a dropdown when:
- A click outside the dropdown occurs
- `Esc` is pressed
- Any other `Interaction` is started (i.e. using a shortcut)

# Important Notes
- Simplifies `Interaction` API and uses it for closing/canceling CB as well as dropdowns.
- Adjusted some event handlers so that handled clicks don't also register as GraphEditor background clicks.
- Introduces a CSS approach to prevent unwanted text-selections; we were doing it with JS until my previous PR, and the JS solution was breaking things.
2024-03-01 17:49:23 +00:00
Adam Obuchowicz
55f3820cf9
Fix selection tests (#9240)
Sometimes our test realizes, that `currentTarget` of `MouseEvent` is a read-only property. I have no idea why it does not do it every time, but this fix should work.
2024-03-01 15:51:33 +00:00
Radosław Waśko
4316709379
Implementing reading Data Links (#9215)
- Close #9123
2024-03-01 15:33:21 +00:00
Adam Obuchowicz
cabd3ac072
Turn off flaky test (#9232) 2024-03-01 13:37:46 +01:00
Ilya Bogdanov
c44b7f2c2d
Small visualization fixes (#9130)
Closes #9009

- [x] Fixed big white space above full screen viz.
- [x] Escape closes the full screen visualization.
- [x] Viz shortcuts (Shift-Space for toggling fullscreen vis, Ctrl-Space for switching vis type) are implemented.
- [x] The width of visualizations is preserved across project reopens (do we need height as well?)

New video:


https://github.com/enso-org/enso/assets/6566674/d9036ce9-57a4-429b-9bd9-6392782136ea

Older videos:

https://github.com/enso-org/enso/assets/6566674/d7129307-0626-4343-8a76-b9bf764c6a5b


https://github.com/enso-org/enso/assets/6566674/0518d3d8-9ed1-4e6c-bbe0-b7ed00bf7db3

# Important Notes
- Metadata format changed in backward-compatible way
2024-02-29 16:37:40 +00:00
Kaz Wesley
d7e8f271eb
Ensure objects obtained from Y.Js are not modified (#9217)
Y.Js caches values it returns from getters, so they must not be modified. Use `DeepReadonly` to protect values returned from `Y.Map`s in AST logic.
2024-02-29 16:22:33 +00:00
Kaz Wesley
b027a7ee92
Display comments (#9218)
Introduce basic display of node documentation-comments.

![image](https://github.com/enso-org/enso/assets/1047859/b1960097-d265-4d77-a924-fd3c309dc3fd)

Part of #9162.

# Important Notes
- Add synchronization of `documentation` updates to the GraphDB; add a type assertion that ensures `Node` synchronization is updated when new fields are added to `Node`.
- Introduce read-only comment rendering.
2024-02-29 15:42:11 +00:00
Adam Obuchowicz
874e9efe74
Add workaround for huge idmap diffs (#9207)
Fixes probably #9198 See [this comment](https://github.com/enso-org/enso/issues/9198#issuecomment-1968484269) for justification. TLDR: the diff algorithm is too slow for our huge idmap.

The proper fix would be to reduce idmap size. Expect tasks for that soon.
2024-02-29 14:42:59 +00:00
somebody1234
0a28d91d35
Switch to AJV for validating JSON Schema (#9191)
As ~~requested~~ suggested by @radeusgd

# Important Notes
None
2024-02-29 10:36:47 +00:00
Kaz Wesley
97033a2ff4
Represent documentation in AST, load into Node (#9205)
Part of #9162.

- Add support for representing and interpreting the full text-literal/documentation syntax (escape codes, platform-independent newlines, string interpolations); build on generalized operations for structured-fields that will simplify future representation of other types like `Vector`.
- Load parsed and interpreted node documentation into `Node`s.
2024-02-28 20:43:23 +01:00
somebody1234
fecdd534b1
Fix Component Browser aliases (#9163)
- Fix #9107
- Allow matching initials of aliases
- Allow matching spaces instead of underscores (aliases use spaces, not underscores)
- Fix only the first alias being detected. This is due to incorrect docs parsing keeping the leading space - `foo, bar` turns into `["foo", " bar"]`

# Important Notes
None
2024-02-28 15:33:22 +00:00
Adam Obuchowicz
c69ba4ee70
Fix area select regression (#9197)
Fixes #9182

Now we are careful when to handle events - before or after updating intersected set.

Added general E2E and detailed unit tests for selecting.

Also discovered, that sometimes the test are running while nodes are not yet in right positions. Added an instruction ensuring the position is right.
2024-02-28 13:14:48 +00:00
somebody1234
d232b9252c
Re-enable vibrancy and add support for Linux (#9003)
- Fixes support for vibrancy
- Disable background when vibrancy is enabled
- Minor refactors to pass the relevant config option to dashboard, so that the dashboard knows whether vibrancy is enabled
- Enable vibrancy on Linux if a special environment variable is set

# Important Notes
- MUST be tested on macOS
- Windows *does not support resizing* when vibrancy is enabled. This is a limitation of Windows - see [this issue](https://github.com/electron/electron/issues/6107).
2024-02-28 13:01:03 +00:00
Kaz Wesley
edb349f8fc
Allow setting CB viz type; determine default from suggestion type info. (#9196)
Fixes #8570.

- Visualization type can be set per suggestion entry.
- Default visualization type for each suggestion is determined by suggestion type info.

# Important Notes
Previewing non-default visualizations seems to be broken (#9194), but this PR updates the GUI to select visualization types appropriately.
2024-02-27 15:49:56 +00:00
somebody1234
e59b422612
"Keyboard shortcuts" settings page (#9071)
- Close https://github.com/enso-org/cloud-v2/issues/896
- Add new settings page for viewing and editing keyboard shortcuts
- Refactor shortcut manager to resemble GUI2's shortcuts module
- Minor refactor moving `dashboard/layouts/dashboard` to `dashboard/layouts`; and moving all moals to `dashboard/modals`

# Important Notes
- The modal for capturing keyboard shortcuts has not been tested on macOS.
2024-02-27 12:52:21 +00:00
Kaz Wesley
e4383cb3bd
Fix CB reloading when vis-selector opened (#9192)
Fixes a bug blocking #8570.
2024-02-26 20:41:47 +00:00
somebody1234
a7251eb8d4
Improve mouse and keyboard UX (#9100)
- Close https://github.com/enso-org/cloud-v2/issues/914
- Add selection brush for selecting multiple assets using mouse
- Port selection brush over from GUI2
- Support <kbd>Ctrl</kbd>-select to select multiple ranges
- Add various actions when *exactly one* asset is selected:
- <kbd>Enter</kbd> for various assets to trigger their double-click actions
- Projects are opened
- Directories are toggled open/closed
- Secrets show the "upsert secret modal"
- <kbd>ArrowLeft</kbd> now collapses the selected folder
- <kbd>ArrowRight</kbd> now expands the selected folder
- <kbd>ArrowUp</kbd> and <kbd>ArrowDown</kbd> change the selected asset to the previous/next asset
- The newly selected asset (technically: any asset that is the only selected asset, whether this is a result of a drag, mouse click, or keypress) is automatically smoothly scrolled to.
- Improvements to the search bar
- <kbd>Escape</kbd> cancels tabbing through suggestions (and discards the selected suggestion)
- <kbd>ArrowUp</kbd> and <kbd>ArrowDown</kbd> behave like <kbd>Shift</kbd>+<kbd>Tab</kbd> and <kbd>Tab</kbd> to move to the previous/next suggestion respectively
- <kbd>Shift</kbd>+<kbd>ArrowUp</kbd> and <kbd>Shift</kbd>+<kbd>ArrowDown</kbd> to select multiple assets using the keyboard
- <kbd>Ctrl</kbd>+<kbd>Space</kbd> to toggle assets using the keyboard
- <kbd>Escape</kbd> to deselect all assets
- Add CSS-only focus ring to highlight most recently selected item, but only when navigating via keyboard
- Enter and double-click to temporarily open the sidebar to edit a Data Link

Optional features that have not yet been implemented:
- Move the "update secret" modal to the sidebar as well

# Important Notes
None
2024-02-26 16:49:49 +00:00
somebody1234
86d268b198
Fix type error caused by bad merge (#9189) 2024-02-26 17:40:52 +01:00
somebody1234
d71e8c4742
Move "change password" to settings (#9079)
- Close https://github.com/enso-org/cloud-v2/issues/893
- Remove "Change Password" modal
- Remove "Change Password" option from user menu
- Add "Change Password" section to "General -> Account" in settings

# Important Notes
None
2024-02-26 15:50:00 +00:00
somebody1234
207f6a06e5
Fix E2E tests (#9185)
- Fix #9184
- It turns out the logic for handling macOS was already present elsewhere - and even *in the same file*! It seems like this was an oversight

# Important Notes
None
2024-02-26 15:34:43 +00:00
somebody1234
65f66fabb6
Remove forceCreate from backend requests; minor bugfixes (#9074)
- Remove unused `forceCreate` parameter from backend requests
- Also undo bad change to behavior of sorting assets:
- https://github.com/enso-org/enso/pull/7540#issuecomment-1683699696
- Fix https://github.com/enso-org/cloud-v2/issues/910
- Closing a project now doesn't close other projects.
- Unable to properly test, as I cannot get the second project to open
- Fix https://github.com/enso-org/cloud-v2/issues/908
- Use the `download` module that already exists to download the app...
- Add correct arrow icon for collapsing/expanding folders
- Turns out this icon had always existed, and I just didn't see it for the longest time
- Hide irrelevant parts of search bar on Local Backend
- The row of labels
- `no:`, `has:`, `label:`, `-label:`, `description:`, `-description:` (and their corresponding autocomplete entries)
- Also change text to say "Type to search for projects." because the other asset types mentioned do not (and will never) exist on the Local Backend.
- Fix search bar eating up `"` and ` ` keypresses
- Fix icons for Data Links and Secrets being swapped in `AssetIcon`

# Important Notes
- The fix for https://github.com/enso-org/cloud-v2/issues/908 has not been tested on Safari (I don't have a macOS machine.)
2024-02-26 15:10:38 +00:00
somebody1234
4e8f066ec0
Use backend errors in toast notifications (#9078)
Adds the `message` returned by the backend to the toast notification, so that the user gets a more detailed error message.

# Important Notes
- Not sure what's the best way to properly test this, as for a lot of the backend endpoints there is no easy way to (even intentionally) trigger them from the frontend, because the frontend does a decent amount of validation as well.
2024-02-26 14:51:44 +00:00
Kaz Wesley
92624126ba
Fix minor visual glitch in record-control background (#9170)
Before:
![image](https://github.com/enso-org/enso/assets/1047859/dcf083b2-c169-42a9-a120-4aa730f05962)

After:
![image](https://github.com/enso-org/enso/assets/1047859/7d9b774a-1ccd-4225-9a2d-a313e40e0c4f)
2024-02-26 08:38:43 +00:00
Kaz Wesley
245ec7afe8
Replace execution context controls with record mode controls (#9133)
Closes #8673. Stacked on #9132.

Before:
![image](https://github.com/enso-org/enso/assets/1047859/1b1ca9f4-eda9-45fd-bec1-cd7e255112fa)
![image](https://github.com/enso-org/enso/assets/1047859/b8cf6de1-d75c-48d0-ac0d-9e6e0c659dd4)

After:
![image](https://github.com/enso-org/enso/assets/1047859/91d13862-96e7-4175-a61e-40aecd6d62b0)
![image](https://github.com/enso-org/enso/assets/1047859/ef20511f-00f2-4042-b4d4-97728817500b)

# Important Notes
- The model has been refactored from execution-modes (live/design) to record-mode (on/off) up to the point of the project store, where it's translated (since the backend still uses the live/design concepts).
2024-02-23 20:10:43 +00:00
James Dunkerley
880562a503
Add comment, warning, error icons. (#9169)
Add some state icons.
![image](https://github.com/enso-org/enso/assets/4699705/ab4060f5-7814-4a0d-a0af-bb775235ff98)
2024-02-23 17:25:17 +00:00
Kaz Wesley
9c872c653e
Checkbox shows argument name if not already shown (#9146)
Fixes #9002. This is not a great solution; doing this properly would require some refactoring of widget selection. Proposal:  #9145.
2024-02-23 15:48:10 +00:00
Adam Obuchowicz
8c286da21b
Proper fix for editing node (#9153)
The replacement for https://github.com/enso-org/enso/pull/9144

We try to match bindings using "buttons" field, but it in fact does not contain the just-released buttons.

# Important Notes
I added tests for editing node. Also, I decided that the cursor position should be at the end of line when starting editing by clicking at "edit" icon.
2024-02-23 14:54:34 +00:00
Kaz Wesley
bc99941736
Move project name (#9132)
Closes #8672.

Before:
![image](https://github.com/enso-org/enso/assets/1047859/9d95178f-24c1-4e82-bf90-a37c3d1ca450)

After:
![image](https://github.com/enso-org/enso/assets/1047859/84e6dae9-e309-46c5-9be8-6b82dcb9ddc4)

# Important Notes
- The execution context controls are no longer aligned nicely, but we are about to make major changes to their display anyway: #8673
2024-02-23 13:48:33 +00:00
Kaz Wesley
990ba2fc64
Fix flickering when resizing visualization (#9147) 2024-02-23 08:47:57 -05:00
Kaz Wesley
d650798898
Display alias when searching by alias (#9148)
* Display alias when searching by alias

* Fix tests
2024-02-23 08:47:11 -05:00
somebody1234
bdebe904b3
Make alt key keep dropdown open (#9157)
- Fix #9083

# Important Notes
None
2024-02-23 13:41:58 +00:00
Adam Obuchowicz
e7a9221618
Fix escaping \ (#9155)
Fixes #9151

In one of my previous PRs I merged two `escape` implementations having exactly the same documentation. However, one of it missed escaping `\` character.

# Important Notes
One test even expected that `\` are _not_ escaped, but I doubt it should, given the above bug report?
2024-02-23 12:10:45 +00:00
Michael Mauderer
a900fb5c43
Add docs to highlight order of processing dirty nodes in readFunctionAst. (#9141) 2024-02-23 11:19:35 +00:00
Nikita Pekin
5e4a7cf01c
Add Stripe for Billing Support (#8841)
* feat: Stripe billing support

Squashed commit of the following:

commit b7ab361d2e2a3b11819ee0c964dd25dde2850eac
Author: Nikita Pekin <nikita@frecency.com>
Date:   Wed Jan 10 04:14:14 2024 -0500

    fixes

commit 2b7f525be95d8d9e50dea9c5f31828dc2c823eae
Merge: 717fba94a1 942e6c2305
Author: Nikita Pekin <nikita@frecency.com>
Date:   Mon Jan 8 08:54:15 2024 -0500

    Merge branch 'develop' into wip/np/payment-page-2

commit 717fba94a1b900318ae7d32664b1cb292cb47364
Author: Nikita Pekin <nikita@frecency.com>
Date:   Mon Jan 8 08:32:38 2024 -0500

    fix

commit 66a278effddfe57d326acfe93b9fd6ce9f849a65
Author: Nikita Pekin <nikita@frecency.com>
Date:   Mon Jan 8 06:10:37 2024 -0500

    rename endpoints

commit 05ca2276d796d5431a19623f18d97503d730746c
Author: Nikita Pekin <nikita@frecency.com>
Date:   Thu Jan 4 03:13:07 2024 -0500

    update for new API

commit ecc65a4b3bbf8167c91eb9cc9a71f05367ee41f6
Author: Nikita Pekin <nikita@frecency.com>
Date:   Tue Jan 2 09:02:23 2024 -0500

    make subscribe appear in app

commit 048883e343cc42ba75e2e1ebbfa50b9d3033255c
Author: Nikita Pekin <nikita@frecency.com>
Date:   Mon Jan 1 05:13:04 2024 -0500

    unify pricename and price

commit 5439299eaa01732bcee3204c72987845a569029b
Author: Nikita Pekin <nikita@frecency.com>
Date:   Sun Dec 31 22:57:52 2023 -0500

    rename checkout sessions endpoint

commit 67537302f9183918272324723b34e26659d10dbe
Author: Nikita Pekin <nikita@frecency.com>
Date:   Sun Dec 31 22:57:44 2023 -0500

    fix session ID

commit 637968331bf3d2c10b9c6130ae994529b9606fdd
Author: Nikita Pekin <nikita@frecency.com>
Date:   Sun Dec 31 19:59:29 2023 -0500

    fix stripe JS

commit 051a01e1988f62931e2b7f3f436b6490a09602e0
Author: Nikita Pekin <nikita@frecency.com>
Date:   Sat Dec 30 23:32:41 2023 -0500

    tmp: add AWS profile and refactor

commit 9f4199b22dfc5565bea737e31f8d379e098712a7
Author: somebody1234 <ehern.lee@gmail.com>
Date:   Sat Nov 4 04:49:29 2023 +1000

    Fix `ALL_PATHS_REGEX`

commit 4b53bcf7f82fe30c21db013d01dae58e20afb605
Author: somebody1234 <ehern.lee@gmail.com>
Date:   Mon Dec 18 17:15:33 2023 +1000

    Expose `unauthenticatedBackend` from backend context

commit 8d554ac16747392c9cd5d10a2c3ad6d79afb7268
Author: somebody1234 <ehern.lee@gmail.com>
Date:   Mon Dec 18 17:12:17 2023 +1000

    Add methods for making HTTP requests to unauthenticated backend

commit 2010890cbd38bff31b18e0847ea22a5b71f926d1
Author: somebody1234 <ehern.lee@gmail.com>
Date:   Mon Dec 18 17:04:49 2023 +1000

    Add unauthenticated backend

commit 04ac84533bee493194e32129f934ccd9c1df78d6
Merge: 1fa45bc73c d4714af826
Author: somebody1234 <ehern.lee@gmail.com>
Date:   Mon Dec 18 16:26:27 2023 +1000

    Merge branch 'develop' into wip/np/payment-page-2

commit 1fa45bc73cbbf50e53c6f3273559210e85b66c7e
Author: Nikita Pekin <nikita@frecency.com>
Date:   Sun Nov 12 07:01:45 2023 +0000

    tmp: Complete checkoutSession flow

commit 30ec2792256db5b2b448119b07213b79e3f8a3c5
Author: somebody1234 <ehern.lee@gmail.com>
Date:   Wed Nov 1 19:20:15 2023 +1000

    Initial Stripe integration

* revert requestedPlan changes

* switch to path from query

* Prettier

* Fix type error

* Switch environment back to production

* Fix errors

* Fix dev server by removing COOP/COEP/CORP on the dev server specifically

* Redirect after upgrading plan is successful

* Fix errors; fix initial size of Subscribe page

---------

Co-authored-by: somebody1234 <ehern.lee@gmail.com>
2024-02-22 19:56:36 +03:00
Adam Obuchowicz
7f5b2edbf5
Fix interfering click handlers (#9127)
Fixes one failure in #8942 which caught a real issue: clicks at various panels were triggering many handlers at once, often unexpectedly - for example quick clicking at breadcrumbs (and automatic tests always click fast) we could also trigger getting out the current node.

Therefore, I added `stopPropagation` for all mouse events on "panel" level + where I think the event should be considered "handled" and no longer bother anyone. Also, to unify things, most actions are for `click` event.

Additionally I spotted and fixed some issues:
* When "clicking-off" Component Browser, it creates new node only if anything was actually typed in (no more dangling `operatorX.` nodes)
* Filtering now works for operators
* When, after opening CB with source node, user starts typing operator, we replace dot with space
* Fixed our shortcut handler, so it works properly with `click` event.
* Fixed problems with defocusing input in CB when clicking at links.

# Important Notes
I removed `PointerMain` binding for deselectAll, because it was triggered every time did the area selection.
2024-02-22 15:18:28 +00:00
Kaz Wesley
323d46ec4e
Add property test for textChangeToEdits and applyTextEdits. (#9131)
Add a test for some functionality introduced in #9055.
2024-02-21 21:48:37 +00:00
Kaz Wesley
fdec1d0671
Self-arrows: Distinguish self arguments (#9116)
Distinguish self arguments; render edges to them as arrows, and use icons for their widgets.
2024-02-21 08:40:08 -08:00
Kaz Wesley
01fc65eec5
Self-argument arrows: New edge rendering mode (#9099)
Self-argument arrow rendering
2024-02-21 09:43:22 -05:00
somebody1234
c60d1ba36d
Fix bug in map visualization (#9119)
- Fix a bug where longitude was used as both latitude and longitude, due to a typo....

# Important Notes
- As our Mapbox token is no longer valid, the map visualization no longer works, even with this fix. As a result, this cannot be tested properly.
- However, this can still be tested somewhat, by seeing that the error is no longer present in the repro:
- Open the `Colorado COVID` template
- Open the viz on this node (at the bottom right of graph. it may help to zoom out using Ctrl+Shift+A.):
![image](https://github.com/enso-org/enso/assets/4046547/54849e5f-8a53-4f5b-8bdf-f08fe8ca51f0)
- Compare the errors logged in the console between `develop`, and this branch. This branch should not have the error about `lat` (latitude) being out of range.
2024-02-21 12:21:20 +00:00
Michael Mauderer
6c4c791d87
Display warnings on components (#9108)
Closes #8678

[Peek 2024-02-20 12-45.webm](https://github.com/enso-org/enso/assets/1428930/6bb6c4ad-5507-4b11-b2c9-b295bf10c745)
2024-02-21 11:40:07 +00:00
Paweł Grabarz
d415d133bb
Fix node edits (#9111)
* Prevent duplication of external IDs in syncTree

* trim component browser accepted value

* use flush post for visualization data watcher

* do not create empty nodes when closing component browser

* Lint

---------

Co-authored-by: Kaz <kaz@lambdaverse.org>
2024-02-20 16:40:50 -05:00
Michael Mauderer
e264189f6a
New ... menu in the top bar with zoom controls (#9073)
Closes #8614

https://github.com/enso-org/enso/assets/1428930/8b5b47e4-5ce5-4bf0-a42f-0b6c3d7d9323
2024-02-20 15:44:49 +00:00
mwu
3a2ca2ae0f we don't need to hardcode version numbers probably 2024-02-20 16:32:04 +01:00
Kaz Wesley
c811a5ae8b
Enable the Code Editor, with new apply-text-edits algo. (#9055)
- Fix the UI problems with our CodeMirror integration (Fixed view stability; Fixed a focus bug; Fixed errors caused by diagnostics range exceptions; Fixed linter invalidation--see https://discuss.codemirror.net/t/problem-trying-to-force-linting/5823; Implemented edit-coalescing for performance).
- Introduce an algorithm for applying text edits to an AST. Compared to the GUI1 approach, the new algorithm supports deeper identity-stability for expressions (which is important for subexpression metadata and Y.Js sync), as well as reordered-subtree identification.
- Enable the code editor.
2024-02-19 23:57:42 +00:00
Kaz Wesley
d75523b46f
Render target attachment bit as part of port. (#9068)
Fixes one issue from #8139.

Before:
![image](https://github.com/enso-org/enso/assets/1047859/1db71cda-7f9e-4d15-ac0f-14cb3c0b7c09)

After:
![image](https://github.com/enso-org/enso/assets/1047859/c5aafc56-d81d-447e-b725-fcb2e30b3c4e)
2024-02-19 20:02:29 +00:00
AdRiley
27ec236c19
rename database Table to DB_Table (#9067)
Rename database.Table to database.DB_Table to avoid name collisions as part of https://github.com/enso-org/enso/issues/8981
2024-02-19 17:31:58 +00:00
Kaz Wesley
760afbc7f4
Render unconnected edges above nodes. (#9069)
Fixes one issue from #8139.

Before:
![image](https://github.com/enso-org/enso/assets/1047859/b6d05734-f186-4213-b943-81fd868cf565)

After:
![image](https://github.com/enso-org/enso/assets/1047859/4e42907f-8579-4869-99a3-74aac920e65b)
2024-02-19 15:12:15 +00:00
somebody1234
50d5f32570
Fix dashboard tests (#9050)
Fixes issues that were causing CI to fail.

# Important Notes
None
2024-02-19 11:47:48 +00:00
Adam Obuchowicz
fddfa1150a
Fix for adding node in collapsed functions (#9060)
Fixes #9049

There were still some stubs left in node creation code.

# Important Notes
I haven't added any tests, as unit testing the graph store is very difficult - it has much tangled logic there. I'm going to try to untangle it a bit, but in a separate PR.
2024-02-19 09:14:46 +00:00
Michael Mauderer
6746bdc148
Implement full wheel component menu (#9029)
Closes #8612.


[Peek 2024-02-12 14-11.webm](https://github.com/enso-org/enso/assets/1428930/504a0e17-9d75-46b2-b5e9-d23ec09d6613)

# Important Notes
The `...` menu was added at the top of the menu as there is less visual interference with an opened visualisation.
2024-02-15 14:01:38 +00:00
Michał Wawrzyniec Urbańczyk
06c8776099
CI: Fix macOS notarization (#9066) 2024-02-15 11:53:51 +01:00
Adam Obuchowicz
8489316d83
WidgetFunction: merge dynamic config for a call with inherited one (#9042)
Fixes #9008

Now, even if we inherit FunctionCall config from parent widget (e.g. drop down), we still ask for config of the current call and try to merge them (preferring the inherited parameters).
2024-02-14 23:05:45 +00:00
Kaz Wesley
cfe3d99da0
Fix Code Editor click (#9051)
Clearing the selection on mouseup breaks the CodeMirror integration. Adding this exception for contenteditable elements would fix it. Is this compatible with whatever this event handler is needed for?
2024-02-14 17:27:27 +00:00
Adam Obuchowicz
ee381369b0
Remove vite-plugin-top-level-await plugin (#9038)
We've used the vite-plugin-top-level-await to support top level await. But most of them were removed anyway, because the ide-desktop/lib/client is bundled as CJS and use some of gui2 code. And the plugin [is causing problems](https://github.com/Menci/vite-plugin-top-level-await/issues/25), [also in our CI](https://github.com/enso-org/enso/actions/runs/7842841953/job/21402194728?pr=9013#step:8:458)
2024-02-14 09:42:37 +00:00
AdRiley
5c7947ce60
Rename database column to DB_Column (#9046)
Rename database column to DB_Column to avoid name collisions as part of https://github.com/enso-org/enso/issues/8981
2024-02-14 09:11:52 +00:00
somebody1234
92f420efec
Add "Invite" button on top right (#8987)
- Implement https://github.com/enso-org/cloud-v2/issues/884
- Add an "Invite" button that is present when the "Share" button is not present

# Important Notes
None
2024-02-13 12:17:45 +00:00
Adam Obuchowicz
36722eaf55
Retry E2E tests on CI (#9040)
To guard us from flaky tests, CI will run every test three times and fail if _any_ of the run fails.

This way we hope most flakiness will be catch before merging PR.

Configured dashboard in the same way.
2024-02-13 11:43:56 +00:00
somebody1234
f7a84d06e4
Organization settings page (#8960)
- Close https://github.com/enso-org/cloud-v2/issues/840
- Add organization page
- Add wrappers for required API endpoints (get, update, delete org; upload org picture)

# Important Notes
None
2024-02-13 09:21:40 +00:00
somebody1234
ecc434e788
Fix dashboard issues (#9015)
- Fix https://github.com/enso-org/cloud-v2/issues/892
- Fix listing recent projects (currently errors ⚠️)
- Fix "update" action in the "duplicate files found when uploading" modal doing nothing, when overwriting a file newly created in the current session
- Remove dropzone (very oudated) in favor of dropping directly onto directory rows
- Fix various issues with dragging
- Fix all spinners not animating on Firefox
- Fix column selector disappearing all the way to the right on Firefox
- Change auto-generated name of duplicate files from `foo (2)` to `foo 2`

# Important Notes
None
2024-02-12 14:07:58 +00:00
somebody1234
a8d5dcceac
Fix chat styling; fix focus issues in chat (#8988)
- Implement https://github.com/enso-org/cloud-v2/issues/885
- Adjust chat styling to match more with the rest of the `ide2` Figma design (and the screenshots from the original issue...)

# Important Notes
None
2024-02-12 12:48:08 +00:00
Adam Obuchowicz
a0029f2451
Small boolean widget tweaks (#8994)
Fixes #8962
2024-02-12 11:33:03 +00:00
Ilya Bogdanov
e1943bdd49
Properly propagate dynamic configuration inside dropdown widget (#8983)
Closes #8932

Now we use a bit more robust mechanism for passing dynamic configuration down the widget tree inside dropdowns, no longer relying on the `label`s used for dropdown items.

Curiously, we still need to use a hotfix implemented earlier, as we won’t have info about the currently selected item otherwise. Highlight for the currently selected item is not crucial as proper dynamic config, so we can leave with the current solution in the meantime.

No visual changes to the IDE, apart from fixed highlight for currently selected item.

# Important Notes
Target branch: #8950, for easier testing.
2024-02-12 10:17:29 +00:00
somebody1234
129022ae12
Support for creating and editing Data Links (#8882)
- Close https://github.com/enso-org/cloud-v2/issues/734
- Add modal to create a new Data Link
- Add the same input to the asset right panel
- Add entries on context menu and Drive Bar
- The shortcut is <kbd>Cmd</kbd>+<kbd>Shift</kbd>+<kbd>Alt</kbd>+<kbd>N</kbd>
- Add (and use) corresponding backend endpoints

# Important Notes
- All UI is currently generated based off of a single-source-of-truth JSON Schema file.
- JSON Schema was chosen for a few reasons:
- trivial to parse (it's plain JSON)
- sufficiently powerful (supports unions (used in the initial schema), objects, and singleton/literal types)
- but still quite simple (this makes it easier to implement various utilities for, because there are fewer cases to cover)
- Note that it is definitely possible to change this. The original suggestion was a TypeScript file, which can definitely be done even using just the `typescript` package itself - I just prefer to avoid adding another step in the build process, especially one that depends on the `typescript` package at runtime.
- Note also that we *do* actually bundle transpilers as part of the visualization loading code in GUI2 - so for now at least, the size of the dependency isn't a primary concern, but rather just the mental overhead of having another dependency for this one specific task.
2024-02-12 10:05:30 +00:00
James Dunkerley
aed59d316d
Text Editor shows up for Text only parameters. (#9014)
- Fix type name so that Text Editor shows for parameters.
- Following on from #9010, now show the default text values.
![image](https://github.com/enso-org/enso/assets/4699705/da68fec4-25b9-4e04-ba13-a2d112cf67c9)
2024-02-09 17:26:15 +00:00
Ilya Bogdanov
6881bc844e
Fix eslints in the project (#9005)
When using `npm run lint`, there are a lot of warnings for the last couple of weeks, and it is really annoying because I keep skipping important warnings for my files.
2024-02-09 11:22:33 +01:00
Adam Obuchowicz
1c46eecd90
Dispose ydocs provider when closing app (#8990) 2024-02-08 18:39:05 +04:00
Michael Mauderer
1619b2d64f
New scenarios for e2 e tests: Loading Table Visualization & Fullscreen Vis (#8989)
Adds e2e test for table visualisation and full-screen visualisaiton.
2024-02-08 12:17:56 +00:00
James Dunkerley
93f2a44633
Add some ICON tags and a few new Icons. (#8996)
- Apply @Cassandra-Clark's ICON tags to the library code.

- Fix bug with Table viz not showing row count in dropdown list. **Doesn't fix defect with dropdown not changing data.**
![image](https://github.com/enso-org/enso/assets/4699705/dfbdba91-5f4f-4c89-8ae8-f30156047162)

- Added missing icons.
![image](https://github.com/enso-org/enso/assets/4699705/145191cd-d31a-45f1-8bb2-fcc3cf0f1207)
![image](https://github.com/enso-org/enso/assets/4699705/2a8e0530-2470-4ec8-b836-57bed8520c28)
2024-02-08 09:56:57 +00:00
Ilya Bogdanov
851791183d
Add a small arrow for dropdowns (#8950)
A **temporary** solution for #8949. Not pretty, but it solves the issue for now.

https://github.com/enso-org/enso/assets/6566674/d8b28c60-b210-486f-8c93-c6041a2062e3
2024-02-07 14:59:02 +00:00
somebody1234
784d06912f
Make (almost) all interfaces readonly (#8800)
This is not strictly necessary (as indicated by the fact that no actual logic needed to be changed), but it doesn't hurt to make this change.
- Make (almost) all `interface`s `readonly`
- Some of them are *not* readonly; this is intentional as those *do* need to be mutated
- A `no-restricted-syntax` lint rule has been added, but only for `interfaces` - it has been added neither for `classes` nor for `readonly T[]`
- A lint rule for `extends React.PropsWithChildren` instead of `extends Readonly<React.PropsWithChildren>` would be easy to add though...

# Important Notes
- There should be no logic changes, so QA shouldn't need to test anything in particular.
2024-02-07 11:26:59 +00:00
somebody1234
2db13bd168
Fix saved project validation (#8951)
Fix an oversight of project validation disallowing `accessToken: null`, which will be the case when in offline mode/not logged in.

# Important Notes
None
2024-02-07 10:47:04 +00:00
Kaz Wesley
e0ba39ed3e
Introduce SourceDocument for text edit support (#8957)
Introduce `SourceDocument`, a reactive source code representation that can be synced from a `MutableModule`. `SourceDocument` replaces various logic for tracking source code and spans--most importantly, `ReactiveModule`. There is no longer any reactively-tracked `Module`, per-se: Changes to the `MutableModule` attached to the synchronized `ydoc` are pushed as Y.Js events to the `SourceDocument` and `GraphDb`, which are reactively tracked. This avoids a problem in the upcoming text-synchronization (next PR) that was caused by a reactive back channel bypassing the `GraphDb` and resulting in observation of inconsistent states.

Stacked on #8956. Part of #8238.
2024-02-06 16:44:24 +00:00
Michael Mauderer
678270ac69
New scenarios for E2E tests - Interactions with Edges (#8917)
Adds e2e test for interactions with edges.
2024-02-06 16:15:00 +00:00
somebody1234
8bfdf0063a
Bump expect timeout and add retries for dashboard E2E tests (#8939)
- Fix flaky dashboard E2E tests that occur because of timeouts

# Important Notes
None
2024-02-06 15:52:03 +00:00
Kaz Wesley
06f18864f4
Refactoring before text edits (#8956)
Changes in preparation for #8238 features.

# Important Notes
Changed edit APIs:
- **`graph.astModule` is deprecated.** It will be removed in my next PR.
- Prefer `graph.edit` to start and commit an edit.
- Use `graph.startEdit` / `graph.commitEdit` if the edit can't be confined to one scope.
2024-02-06 14:43:17 +00:00
Adam Obuchowicz
6517384bbb
Interpret documented nodes properly (#8978)
When a node has documentation, it becomes a special "Documented" AST node.
2024-02-06 10:45:16 +00:00
Adam Obuchowicz
e88d8d8756
Fix vector widget in non-argument literal (#8972)
Fix vector widget not appearing in non-argument list literals. Added tests for showing widgets for various literals.
2024-02-06 09:43:38 +00:00
Paweł Grabarz
d418a02014
Update icon definitions to new figma export format (#8860)
Related to #8387

Updated icons file to match the export format of figma plugin.
2024-02-05 15:29:45 +00:00
Adam Obuchowicz
fa4b980d67
Reduce test flakiness (#8947)
Probably fixes the first point in #8942

My guess is that the mockExpressionUpdate may be not set in cases when the test runs before App mounting. To make sure all the setup is done, we wait for `App` widget to being mounted before proceeding.

# Important Notes
This PR also change the way we run test's server. Before it was always a production build, but this makes development iteration long. Now we test production build only on CI or when `PROD=true` env variable is set.
2024-02-05 14:20:24 +00:00
Ilya Bogdanov
801cc7b37d
Fix dangling node connection (#8902)
Fixes #8871

The issue was caused by invalid port registration. Because of the existing context switch expression (which is not visible in GUI),  the port incorrectly considered itself to belong to another node. This happened because the port was only aware of the visible part of the node’s AST and considered it the whole node.

There are two fixes in this PR. Either of them fixes the issue, and they are both implemented for robustness:
1. We provide `nodeId` information to the widget tree, so it no longer assumes the node ID from AST.
2. The order of checks in `getPortNodeId` is swapped. Now we first search by AST, only then try to look up the port. It makes sense to me because the AST is a single root of truth, and we should only rely on registered ports if AST does not exist (which happens for unconnected ports).
2024-02-05 10:49:55 +01:00
Adam Obuchowicz
1a8b82e237
Another set of small fixes (#8946)
* `Enter` key accepts the edit in Numeric and Text input
* Newly added node are selected
* Placement of new nodes takes opened visualizations into account.

[Screencast from 2024-02-02 13-02-26.webm](https://github.com/enso-org/enso/assets/3919101/0f328824-1cbc-4b07-988e-dbf17b94dc2f)
2024-02-02 18:11:28 +01:00
Adam Obuchowicz
8eeef71c26
Fix loading wasm for ydocs server (#8952)
#8893 introduced a fatal regression for old IDE + new IDE also does not work on every system.

The fix:
1. Don't assume that WASM needed by ydocs server is bundled
2. Don't assume we know its exact name.
2024-02-02 17:01:58 +01:00
Ilya Bogdanov
45221d9167
A quick fix for incorrectly working dropdowns. (#8933)
Partial fix for #8932 

https://github.com/enso-org/enso/assets/6566674/75a878fb-891b-44fc-bdfd-c3cbb90c9f35

This is not a correct fix, as comparing strings is not what we really want, but it should fix most of use cases.
2024-02-02 15:55:22 +01:00
Kaz Wesley
343a644051
Syntactic synchronization, automatic parentheses, metadata in Ast (#8893)
- Synchronize Y.Js clients by AST (implements #8237).
- Before committing an edit, insert any parentheses-nodes needed for the concrete syntax to reflect tree structure (fixes #8884).
- Move `externalId` and all node metadata into a Y.Map owned by each `Ast`. This allows including metadata changes in an edit, enables Y.Js merging of changes to different metadata fields, and will enable the use of Y.Js objects in metadata. (Implements #8804.)

### Important Notes

- Metadata is now set and retrieved through accessors on the `Ast` objects.
- Since some metadata edits need to take effect in real time (e.g. node dragging), new lower-overhead APIs (`commitDirect`, `skipTreeRepair`) are provided for careful use in certain cases.
- The client is now bundled as ESM.
- The build script cleans up git-untracked generated files in an outdated location, which fixes lint errors related to `src/generated` that may occur when switching branches.
2024-02-02 10:22:18 +01:00
Adam Obuchowicz
ed65af7005
CB preview debounce (#8909)
To make engine's life a bit easier, we added 200ms debounce to CB preview updates.
2024-02-01 17:37:00 +00:00
Michał Wawrzyniec Urbańczyk
9a2bb19a89
CI: Native aarch64 macOS builds, refactoring workflow generation (#8864)
This PR adds a native aarch64 target to our release process.

It also includes refactoring of workflow generation and minor tweaks:
* removing some workarounds in the generated action code that are not needed anymore;
* some version bumps that are harmless;
* release builds have cleaning enabled unconditionally.
2024-02-01 13:53:50 +01:00
somebody1234
4f7032f966
Add dashboard tests to GUI2 CI; fix dashboard tests (#8922)
- Close #8911
- Add dashboard unit tests to GUI2 CI
- Add dashboard E2E tests to GUI2 CI
- Fix (minor) issues in dashboard unit tests

# Important Notes
None
2024-02-01 11:03:58 +00:00
somebody1234
41c7b5afb4
Version panel (#8746)
- Closes https://github.com/enso-org/cloud-v2/issues/784
- Add version panel

# Important Notes
- The backend sends an `isLatest` field in the response, but this is currently *not* shown in the UI because I think it isn't particularly useful.
- Versions are displayed in descending order (most recent first)
- Versions have hover effects, but there is not yet any relevant behavior that can be triggered on click.
- The versions breadcrumbs control displays the version number in the Figma design, however it is not yet returned by the cloud backend (and should ideally not take an extra request)
2024-02-01 08:47:43 +00:00
Michael Mauderer
1ba28a3c5c
New scenarios for E2E tests - Displaying Edges (#8904)
Adds e2e test for rendering edges.
2024-01-31 13:42:36 +00:00
somebody1234
cbf6d41e4c
More E2E tests; export default classes from modules (#8730)
This is a prerequisite for adding a CI action for E2E tests.

- Fix E2E tests
- Remove visual regression testing (VRT) and associated fixtures (screenshots) for now
- Switch dashboard almost fully to Vite, from ESBuild, to match GUI2's build tooling.
- Add some new E2E tests:
- Creating assets
- Deleting assets
- Creating assets from the samples on the home page
- Sort assets
- Includes fixes for sorting:
- Group sorted assets by type again (regression) (see https://github.com/enso-org/cloud-v2/issues/554)
- Make sorting by title, case insensitive. This is because it is more intuitive for non-programmers if all items with uppercase names *aren't* separated from those with lowercase names - especially since the Windows FS is case-insensitive.
- Normalization of Unicode letters is *not* currently being done. It can potentially be added later.
- Double-clicking *anywhere* on a directory row now expands it. Previously it was only being expanded when double clicking
- Add recursive label adding/removal to mirror backend
- Note: The current implementation is not exactly the same as the backend's implementation.
- Fix https://github.com/enso-org/cloud-v2/issues/872
- Unset "saved project details" (for opening the last open project) if fetching it produces an error.

# Important Notes
- All tests pass. (run `npm run test:e2e` in `app/ide-desktop/lib/dashboard`)
- All `npm` commands should be run in `app/ide-desktop/lib/dashboard`. `dashboard:*` npm scripts have been removed from `app/ide-desktop` to prevent a mess.
- `npm run dev` confirmed to still work. Note that it has not been changed as it was already using Vite.
- `npm run build` now uses `vite build`. This has been tested using a local HTTP server that supports `404.html`.
- Other cases have been tested:
- `npm run test:e2e` works (all tests pass)
- `./run ide build` works
- `./run ide watch` works
- `./run ide2 build` works
- `./run gui watch` works
2024-01-31 11:35:41 +00:00
Ilya Bogdanov
057bf17ffb
Fix wrapping in doc panel (#8887)
Fixes soft-wrapping of lines in documentation panel.
2024-01-30 15:05:39 +01:00
Ilya Bogdanov
ad6348a12a
Text input widget (#8873)
Closes #8823

https://github.com/enso-org/enso/assets/6566674/966576ec-6507-401c-98d3-bd71c2ffc6b2

Adds a basic text widget for text literals. 

### Important Notes

Several known restrictions:
- Separators would always be replaced with single quotation marks. All types of separators in Enso are supported though, and they would be correctly escaped if needed.
- Logic for widget selection probably needs refinement (works for text literals and `Text` types, but does not work for `Text | Integer`, for example)
- **(!)** There is a very annoying issue when the input field suddenly loses focus, closing the editing mode and discarding any changes. Debugging shows that it happens when we receive an engine update (and probably recreate the node component/widget tree (???)). It requires a separate investigation.
2024-01-30 15:05:28 +01:00
Adam Obuchowicz
2ca4fe94e2
Fix breadcrumbs navigation (#8874)
Fixes #8756

The items were added to stack in wrong order (I wonder how on earth it worked with the engine).
2024-01-29 10:53:44 +00:00
Michael Mauderer
abe0875072
New scenarios for E2E - Displaying proper types on nodes on hover (#8856)
Adds a new test scenario that checks that types are correctly set and displayed after an expression update. Includes checking the string set on the node as well as showing the type label when hovering the output port of a node.
2024-01-29 10:37:44 +00:00
Adam Obuchowicz
ad7fad42fa
Make run button execute in live mode (#8876)
What can I say? It's not quite a bug. Rather a wrong implementation

Anyway, fixes #8810
2024-01-29 09:50:52 +00:00
Adam Obuchowicz
057245ea5e
Fix nested drop downs + test scenarios for drop-down and vector widgets. (#8859)
Part of #8518
Closes #8822

The drop downs were missing, because WidgetFunction had a higher score than them and took precedence. The fix was to adjust scores, so drop down is before both argument name and function. Generally, any widget expecting to "overlap" existing code (and possibly further widgets) should go before WidgetFunction.

# Important Notes
* Extended mockExpressionUpdate to accept a subexpression of a node. Also, I removed it from GraphDb - I want this function to have as little impact on app code as possible.
2024-01-26 17:18:27 +00:00
Kaz Wesley
a04385a6a4
New AST APIs (#8851)
Introduce new AST APIs. They will be used for synchronization in the next PR.

# Important Notes
- `Module.edit` now clones a YDoc containing all the module's data; the resulting `MutableModule` can be edited with mutation APIs.
- Every AST type now has a mutable subtype. These `MutableAst` types expose all editing operations that were previously in `MutableModule`, such as `replace`; they also provide field setters.
2024-01-26 11:32:35 +00:00
Adam Obuchowicz
5dd2dc1c93
Fix gui2 typecheck (#8870) 2024-01-26 09:15:01 +01:00
Ilya Bogdanov
6f51894273
Align collapsed node to the leftmost selected one (#8844)
As discussed on the latest demo.


https://github.com/enso-org/enso/assets/6566674/c68f1df4-285e-413b-b05e-13394dffe3bd
2024-01-25 16:19:41 +01:00
somebody1234
6e7672a424
Add settings page; add endpoints for deleting user and uploading profile picture (#8720)
- Depends on unmerged backend features:
- https://github.com/enso-org/cloud-v2/issues/832
- https://github.com/enso-org/cloud-v2/issues/833
- Close https://github.com/enso-org/cloud-v2/issues/829
- Add scaffold for settings page
- Add endpoint for deleting user
- Add endpoint for uploading profile picture
- Modify API types to add profile picture to user info
- Add shortcuts:
- <kbd>Cmd</kbd>+<kbd>,</kbd> to open settings page (shortcut taken from VS Code)
- <kbd>Esc</kbd> to close settings page
- ℹ️ Note that, while the settings page is considered as a page by the logic, it is not saved for the next session, as the settings page should be a transitional page (it should only ever be open to do one specific task, and then immediately closed again)
- Partly implement https://github.com/enso-org/cloud-v2/issues/840
- Add "members" tab with member list
- Add "Invite Users" button to be able to invite multiple users
- Misc. QoL improvements
- Deselect selections when clicking away from the selection

# Important Notes
None
2024-01-25 15:10:51 +00:00
Adam Obuchowicz
3a849ea01b
Connection and visualization fixes (#8803)
Fixes several points from #8745
* Brought back cursor pointer in full screen visualization
* Changed behavior of edge disconnected from one side: Esc will bring the connection back, while click will remove it (and start creating new node if the source was connected).
* When hovering connection, the "active" part (i.e. the part which will be the hanging connection after click) is in normal color, and the rest is dimmed.

[Screencast from 2024-01-19 09-06-48.webm](https://github.com/enso-org/enso/assets/3919101/6df28a9c-51b3-4f98-be10-a35275eac800)
2024-01-25 14:18:26 +00:00
Ilya Bogdanov
a3873b9565
Numeric input widget (#8837)
Closes #8751
Closes #8752

- The numeric widget allows the use of the input field after clicking with LMB
- Slider is only visible if the engine provides widget configuration with set limits (see below for testing)
- Setting value outside limits is possible
- For now, to distinguish drag from click, we compare relative mouse movement on the mouse up event. We might benefit from using a timer instead, but let’s see how good it is now.
- Changes after demo
- No more input validation. You can enter literally anything and it would be accepted.
- Updates debouncing – the code is updated on defocus or when slider dragging has finished.


https://github.com/enso-org/enso/assets/6566674/b3580083-c678-4734-881c-97f8ac56176b
2024-01-25 09:41:37 +00:00
somebody1234
899f7e4e61
Fix offline detection (#8829)
- Closes https://github.com/enso-org/cloud-v2/issues/860

# Important Notes
None
2024-01-25 06:36:03 +00:00
Kaz Wesley
f88bd90ebb
Refactor for YJs AST (#8840)
Some refactoring separated from #8825 for easier review.

# Important Notes
**ID types**

The new *synchronization IDs* will replace `ExprId` for `Ast` references in frontend logic. `ExprId` (now called `ExternalId`) is now used only for module serialization and engine communication. The graph database will maintain an index that is used to translate at the boundaries. For now, this translation is implemented as a type cast, as the IDs have the same values until the next PR.

- `AstId`: Identifies an `Ast` node.
- `NodeId`: A subtype of `AstId`.
- `ExternalId`: UUID used for serialization and engine communication.

**Other changes**:

- Immediate validation of `Owned` usage.
- Eliminate `Ast.RawCode`.
- Prepare to remove `IdMap` from yjsModel.
2024-01-24 19:22:05 +00:00
Adam Obuchowicz
f5c02d36e2
Fix addRequiredImport so it is not fooled by existing module changes (#8813)
A follow-up of [this comment](https://github.com/enso-org/enso/pull/8740#discussion_r1452282468)

`addRequiredImport` now reads the existing import from the edit instead of taking them from the current module. This way, it will consider any imports added so far as part of this edit.
2024-01-24 12:03:25 +00:00
somebody1234
0a493de012
Update uploaded files (#8797)
- Close https://github.com/enso-org/cloud-v2/issues/856
- Implement upload for existing files
- This is triggered by uploading a file with the same name.
- Add a modal that allows the user to select whether to rename or update the file, for each conflicting file

# Important Notes
- There are a *lot* of buttons in the modal. Any ideas on how to make this screen clearer/simpler/easier to understand would be greatly appreciated.
- There are currently a few minor backend issues preventing all functionality from fully working:
- Projects currently cannot be updated due to a bug
- Neither files nor projects can be uploaded if their name contains `()` - e.g. `foo (2).txt`
2024-01-23 09:55:15 +00:00
somebody1234
5f1333a519
Change dashboard to use 2 spaces for indentation (#8798)
This makes it consistent with the indentation style of GUI2.

# Important Notes
- This commit *will* need to be added to [`.git-blame-ignore-revs`](https://github.com/enso-org/enso/blob/develop/.git-blame-ignore-revs) *after* it is merged.
- This shouldn't need any particular QA (although QA doesn't hurt), as the only thing that was done is a `npx prettier -w .`, meaning that there should be zero logic changes.
2024-01-22 21:26:15 +00:00
somebody1234
bd4f46499f
Remove underscores from default project and folder names (#8819)
- Closes https://github.com/enso-org/cloud-v2/issues/857
- Changes format for new folders from `New_Folder_1` to `New Folder 1`
- Changes format for new projects from `New_Project_1` to `New Project 1`
- Uses names for projects created from templates, rather than `Upper_Snake_Case`d IDs

# Important Notes
- Folders containing spaces work fine on cloud backend
- ⚠️ Unable to test opening a project with a space in its name on the cloud backend.
- Projects containing spaces work (open, edit, and execute fine on local backend
2024-01-22 11:38:15 +00:00
somebody1234
d16a645e8e
Prevent dragging rows when editing, and when on local backend (#8747)
- Fix https://github.com/enso-org/cloud-v2/issues/848
- Disables dragging rows when a row is being edited
- Also disables dragging rows on the local backend, as folders are not yet supported there
- Fix other issues found (not sure if they were introduced by this PR):
- Cut (Cmd+X) does not fade out assets
- Cancelling editing names actually still renames the asset
- Cut/Copy/Paste/Undo shortcuts when renaming *also* trigger "copy assets" (etc.) shortcuts
- Apply suggested QoL improvement:
- Disallow renaming an asset to a blank name (a name consisting only of whitespace). Current (new) behavior is to silently revert the asset name to its original name.

# Important Notes
None
2024-01-22 11:06:45 +00:00
Ilya Bogdanov
d5d4793e0e
Positioning for nodes created when collapsing (#8771)
Closes #8699


https://github.com/enso-org/enso/assets/6566674/82e1bdb3-3f37-4122-9e73-92d39acd0f13
2024-01-18 14:30:13 +00:00
Ilya Bogdanov
f96e5dddd6
e2e tests for collapsing and entering nodes (#8758)
Related to https://github.com/enso-org/enso/issues/8518

These tests already caught one regression in nav breadcrumbs: https://github.com/enso-org/enso/issues/8756

It also provides API for mocking expression updates for arbitrary nodes on the screen. The implementation is a bit convoluted and includes setting a callback on `window`, but it looks like the only possible solution given our architecture and playwright restrictions.
2024-01-18 13:45:18 +00:00
Paweł Grabarz
48a5599eb6
improve argument placeholder resolution for partial applications and … (#8794)
Fixes #8788

- Fixed missing argument lists on constructors, and improved handling for various cases of partially applied functions.
- Extended tests to check for correct `self` argument placeholders.
- Additionally reworked some questionable test code to maintain separation between server and client code.

<img width="1241" alt="image" src="https://github.com/enso-org/enso/assets/919491/5377f57f-18f0-4a50-a8ab-9331862ca547">
2024-01-18 13:13:31 +00:00
AdRiley
ac0d4c9f5f
Make Random.Seed private. Remove unused TEXT_ONLY (#8783)
Random.Seed doesn't work in the GUI and the TEXT_ONLY tag doesn't do anything so it was incorrectly showing up in the component browser.

This MR makes Random.Seed private to hide it from the GUI and completely removes the TEXT_ONLY tag which is unused and unimplemented.
2024-01-17 17:15:51 +00:00
Michael Mauderer
080690b3ad
Fix for code enabling/disabling output context on single node (#8776) 2024-01-17 10:18:40 +00:00
somebody1234
318cc2d81b
Inline Table, TableRow and TableColumn (#8760)
These components are a legacy remnant of the old design, where `Table` needed to be reusable because there was a separate table for each asset type.

# Important Notes
None
2024-01-16 22:13:15 +00:00
Paweł Grabarz
a880fe80b6
[GUI2] Implement proper connect and disconnect operation on argument placeholders (#8731)
- Correctly applying code edits when connecting to argument placeholders or disconnecting existing arguments.
- Prevented the placeholders from temporarily flickering right after the edit operation.
- Rewritten the placeholder argument placing logic to match the old GUI exactly - the argument should never move right after being connected.
- Fixes #8494
- Fixed some cases of ports either not existing, or existing where they shouldn't.
2024-01-16 21:20:43 +00:00
somebody1234
da7dcd8bd5
Rename index.js.gz to entrypoint.js.gz (#8757)
This is required because `index.ts` was renamed to `entrypoint.ts` in order to avoid colliding with the main export of the `enso-dashboard` module, which is used by `gui2` as `dashboard.run()`. This file was renamed in #8587, causing the issue.

Build script changes also included thanks to @mwu-tow.

# Important Notes
This should only affect projects opened against the remote (cloud) backend, meaning that to test this, you should open a project against the cloud backend.
2024-01-16 19:10:49 +00:00
Adam Obuchowicz
db2d3f1d01
Shorter tag values in WidgetSelection (#8740)
Fixes #8727

Ported GUI1 behavior: The tags in WidgetSelection which are fully qualified names have only last segment displayed, and inserted expression is also shorter (with proper import added).

[Screencast from 2024-01-11 15-14-08.webm](https://github.com/enso-org/enso/assets/3919101/afdf2c1a-3110-4ddd-83ff-fd0c3551afb6)
2024-01-15 11:57:24 +00:00
Adam Obuchowicz
b28b743ae4
Set of GUI2 widgets fixes (#8749)
Implements first two points of #8745

1. The fix for drop-down was simple, just stop click propagation
2. The fix for connections was much more complicated. It turned out, that it's about keeping track of hovered ports; when picking an option in WidgetSelection makes the drop-down disappear - but that won't emit `pointerleave` event, so the port was still deemed hovered. Changed the mechanism for tracking hovered port to more "centralized" one.
2024-01-15 08:12:34 +00:00
Ilya Bogdanov
58cf4e5244
Collapsing nodes (#8686)
Closes #8067

Also fixes `nodeRects` map, as it no longer stores invlisible nodes.

https://github.com/enso-org/enso/assets/6566674/ba66c99f-df74-497b-8924-dc779cce8ef5

# Important Notes
Positioning of newly created nodes is not handled yet, as it requires fixes in the Ast editing API.
2024-01-12 14:08:17 +00:00
somebody1234
fc0361f502
Download files (#8733)
Adds the `getFileDetails` endpoint and uses it to download files on the cloud.

# Important Notes
None
2024-01-11 12:37:58 +00:00
somebody1234
b52c81f7e9
Minor dashboard fixes (#8732)
- Use `rootDirectoryId` returned by backend instead of mirroring backend behavior to generate the root directory ID
- To test this, move/copy an asset *to* the root directory.
- Move the right side of the top bar back to the right edge in editor view (oops)
- To test this one just open any project and make sure the top bar doesn't look funny.
- Delete the barrel export of `#/hooks` in the dashboard (left over due to an oversight when removing the other barrel exports)
- Should not need to be tested; all imports have simply been moved to point to the actual declaring file. As such, as long as the code still typechecks, it should be working fine.
- Delete a duplicated (unused) file caused by a bad merge.

# Important Notes
None
2024-01-11 11:12:59 +00:00
Kaz Wesley
ec2de192ce
Fix replaceRef (#8729)
Fix a bug when `replaceRef` is used to replace an object that had children.
2024-01-10 22:55:20 +00:00
somebody1234
2142e7d273
Fix secrets, add "update secret" endpoint, fix search bar RWD (#8713)
- Fix https://github.com/enso-org/cloud-v2/issues/828
- Fix appearance of search bar on small screens
- Close https://github.com/enso-org/cloud-v2/issues/830
- Rename "Data Connector" back to "Secret" for now
- Fix "create secret" endpoint
- Add "update secret" endpoint
- Repurpose "create secret" modal to also be usable for updating secrets
- Add new context menu option for editing secrets
- Add new shortcut (<kbd>Ctrl</kbd>+<kbd>E</kbd>) for editing secrets
- Add double-click trigger for editing secrets
- Fix https://github.com/enso-org/cloud-v2/issues/831
- Add the redirect, that was previously missing (only present in the very old dashboard)
- Fix https://github.com/enso-org/cloud-v2/issues/835
- Fix search query not updating when clicking label in sidebar
- Fix search query breaking when clicking a suggested label, after tabbing into a selection
- Fix https://github.com/enso-org/cloud-v2/issues/839
- Make search query refresh when pressing <kbd>Enter</kbd>
- Fix some buggy behavior when applying autocomplete

# Important Notes
None
2024-01-10 21:17:14 +00:00
Kaz Wesley
1af1175716
Reference rewriting (#8711)
Implements #8683.
2024-01-10 16:34:19 +00:00
somebody1234
8597de1d43
Re-organize lib/dashboard/ (#8587)
- Significantly flattens directory structure of `lib/dashboard/`

# Important Notes
- Basic testing done on:
- dashboard's `npm run dev` which (since quite recently) uses Vite.
- specifically: `npm run dev` in `app/ide-desktop/lib/dashboard`, OR `npm run dashboard:dev` in `app/ide-desktop`
- dashboard's bundle script (`npm run build`) which uses ESBuild.
- GUI2's own entry point (GUI2's `npm run dev`).
- `./run ide build`
- `./run ide watch`
- `./run ide2 build`
- `./run gui watch`
2024-01-10 16:22:11 +00:00
somebody1234
b8f4dc32c9
Fix dashboard tests (#8715)
Fix failing `AssetQuery` test

# Important Notes
None
2024-01-09 15:14:59 +00:00
somebody1234
b201577fca
Switch Table viz to AG Grid Enterprise (#8702)
- Closes #8660
- Switches Table viz to use AG Grid Enterprise

# Important Notes
- Not sure this is the proper way to enable full AG Grid Enterprise.
2024-01-09 12:26:28 +00:00
somebody1234
9ba676b234
Copy/Duplicate/Copy-paste assets (#8700)
- Closes https://github.com/enso-org/cloud-v2/issues/822
- Implements the following actions and their associated keyboard shortcuts
- "Duplicate"
- "Copy" and "Copy All" (= copy all selected items)
- "Paste" and "Paste All" (with copied assets - cut-and-paste already worked previously)

# Important Notes
None
2024-01-09 11:49:23 +00:00
somebody1234
8ad8a338fc
More unit tests for dashboard (#8586)
Adds more unit tests for utility modules used by the dashboard.

# Important Notes
None
2024-01-09 10:43:18 +00:00
somebody1234
486f54421b
Fix opening deeplinks when IDE is not yet opened in background (#8540)
- Fixes https://github.com/enso-org/cloud-v2/issues/525

# Important Notes
- Needs to be tested on macOS and Windows.
2024-01-09 10:21:00 +00:00
Adam Obuchowicz
c64e833307
Widget refactoring & show widget in placeholders (#8687)
[Screencast from 2024-01-05 12-18-55.webm](https://github.com/enso-org/enso/assets/3919101/f083512f-f698-42d1-b43a-4e50546b958a)

* Before most widgets didn't show in placeholders, because the argument name widget did not create further widgets. Now it try in more cases, and ignores the problem if no widget is found.
* WidgetInput is no longer a set of classes - instead it contains a set of common fields, and every widget can just extend it with new fields. Adjusted priorities accordingly.
* Updated widget definitions: they better try to match types, and take care about default values.

# Important Notes
Setting value on placeholder breaks widgets. The issue is also present in develop (when connecting to placeholder). To restore node, you have to reopen the project.
2024-01-08 13:51:51 +00:00
somebody1234
942e6c2305
Smart search (#8554)
- Closes https://github.com/enso-org/cloud-v2/issues/782
- `owner:` to do exact matches against owner username
- `label:` (already existed)
- `name:` to do exact matches against asset name (exact match; case insensitive; the glob character `*` matches 0 or more characters)
- negated searches (`-owner:`, `-label:`, `-:` for negating keywords)
- Related changes that were not explicitly requested:
- add `no:`, `-no:`, `has:` and `-has:` to filter for assets that lack a specific field. Currently this only works for labels, because most (if not all) other fields cannot be empty.
- `label:a,b,c` to OR results together. `label:a label:b` ANDs results as usual.
- shift-click labels to add/remove it to the last search term as an OR
- clicking labels now cycles them from: absent -> present (positive) -> present (negative)
- Unrelated changes
- Switches unit tests to use `vitest`

# Important Notes
Some other suggestions have been added in the original issue, but currently intentionally left out to avoid prematurely over-engineering this feature.
2024-01-08 12:58:09 +00:00
Ilya Bogdanov
bbf71ec4f1
Preparations for collapsing nodes (#8569)
Preparations for https://github.com/enso-org/enso/issues/8067. The actual implementation requires AST editing.

The implementation resembles the algorithm from the Rust gui.
2024-01-04 16:03:41 +00:00
Michael Mauderer
cd30815c05
Report more errors to the user (#8623) 2024-01-04 14:12:03 +01:00
Kaz Wesley
a215521c10
Tweak commitEdit API (#8667)
Improve `commitEdit` API.

# Important Notes
- `commitEdit` now warns if it is called before a previous edit has been observed. The preferred approach is to ensure all related changes reside in the same `MutableModule`.
- Remove `root` parameter. I included it to avoid a null check/fallible operation, but it's better to repeat the check and simplify the API.
2024-01-04 08:24:33 +00:00
Adam Obuchowicz
2e7d71d459
Refactor widgets to handle dynamic config in input (#8624)
* Merged ArgumentAst and ArgumentPlaceholder into single class.
* Created `AnyWidget` input being a "general use" widget input. Most wigets try to match with it; the `Argument` input is now solely for WidgetArgument(Name) or those handling arguments in a specific way (like selector which want to show on arg name click).
* dynamic config is now part of widget input, and is properly propagated through vector editor/function widgets.

# Important Notes
The widgets still does not work perfectly:
* The chosen options often don't have argument placeholders - that's because we don't display them for constructors. Needs to be added on our side, or engine should send us methodCall info for constructors.
* There are issues with engine's messages sent to us. This makes widgets does not set up (so there is no drop-down, or vector adds `_` instead of default). I'm investigating them and going to fill issues.
2024-01-03 13:37:52 +00:00
Adam Obuchowicz
9c17b260dc
More E2E tests for Component Browser (#8559)
More cases in E2E tests checking all ways of using component browser.

The tests found one actual bug: sometimes we displayed only a few entries after opening CB because the scroller size was not refreshed (we assumed it will be available in the next tick). Refactored Component Browser so it does not use nextTick anymore.
2024-01-03 09:12:38 +00:00
Kaz Wesley
19d0707334
Preparing for AST-based synchronization (#8625)
Further AST integration and API refinement before introducing the new synchronization mechanism.

closes #8609

# Important Notes
API changes:
- Renamed `Ast.parseExpression` / `Ast.parse` to better reflect their usage:
- `Ast.parse` returns a block or a single expression, depending on its input; this is convenient for expressions expected to be single-line.
- `Ast.parseBlock` always treats its input as a block; this is suitable for parsing a file.
- `astExtended` is no longer needed to access span information. `Ast.span` provides access to the value when appropriate (the project's committed modules have spans; uncommitted changes or other parsed expressions don't).
- `SourceRange` is now used everywhere in place of `ContentRange`--the two types had the same definition.

Features:
- Fix CodeEditor viewing.

Implementation improvements:
- Updated widget update handlers (#8545) implementation to Ast API.
- Integrated `imports` more thoroughly with new AST APIs.
- More tests.
2024-01-02 15:18:11 +00:00
Paweł Grabarz
56657cc684
[GUI2] Widget update handlers (#8545)
Fixes #8258 #8267

Added a generic way of setting a new expression value from within a widget, and ability to intercept those update calls from the child widgets. Used that to implement function argument assignment and clearing.

https://github.com/enso-org/enso/assets/919491/513b823b-eb2c-45d8-88ac-4971ba061c59
2023-12-22 10:59:57 +00:00
Michael Mauderer
2d6e4b4813
Display initialization message (#8573)
Implements #8525

[Screencast from 18-12-23 14:40:29.webm](https://github.com/enso-org/enso/assets/1428930/c7db2a9d-0020-4bce-b44c-d6712df58098)

# Important Notes
Previously, we re-used the API from the dashboard. But this mechanism is brittle and is currently even broken with the new GUI. So instead, I just used the Vue equivalent toast API, which seems easier to use.
2023-12-21 16:15:30 +00:00
somebody1234
cbd7397b5e
Fix GUI2 entrypoint (#8542)
- Closes https://github.com/enso-org/cloud-v2/issues/804
- The GUI should now properly configure deep links and auth settings, among other things, because the logic has been ported over from the GUI1 runner.
- The porting was very basic; it may be a good idea to refactor it later, but that is out of scope of this PR.
- This also means that `runner/` should be safe to remove along with GUI1 in the future, as all code relevant to GUI2 now resides in `app/gui2/runner`.

# Important Notes
- The built `ide2` has been tested on Windows, but should also be tested on macOS.
- Should *also* be fully tested in `npm run dev`.
2023-12-21 15:04:30 +00:00
James Dunkerley
ac9d8c710f
Add a quick support for pasting data from Excel. (#8605)
A simple first implementation of pasting data from Excel.

https://github.com/enso-org/enso/assets/4699705/0c2c41ba-6679-4eb8-8d38-0bf14d5f5f24
2023-12-21 11:35:32 +00:00
Adam Obuchowicz
f97e2393dd
Fix E2E tests (#8599)
E2E were failing on develop, now they're fixed.

1. There was a problem in CB which I don't know by what was triggered (But this test is fixed/extended anyway in #8559
2. Otherwise, the test scenes didn't have any nodes due to some races in initialization.
2023-12-20 14:54:55 +00:00
somebody1234
62c9366708
Fix dashboard background on Safari (#8584)
- Closes https://github.com/enso-org/cloud-v2/issues/787

# Important Notes
- Only an issue on macOS. This fix has been tested a bit on macOS, but it doesn't hurt to test again. It also wouldn't hurt to test on Windows and perhaps mobile too.
2023-12-20 10:43:58 +00:00
Kaz Wesley
277dfb1991
Ast edits (#8576)
- The module is edited by changing the AST, not the text representation.
- `IdMap`s no longer need to be maintained in parallel with the module content; they are snapshots produced as needed from the ASTs.
- Simplistic synchronization is in place until #8237: Edits are never merged; if two edits are started from the same state, one will be overwritten.
2023-12-19 17:58:11 +00:00
somebody1234
cbf7248370
Fixes for Language Server sync server (#8514)
- Closes #8398

# Important Notes
- The original error caused by a failing `text/openFile` (`openTextFile`) is still present, but (seemingly?) harder to repro now
2023-12-19 05:41:14 +00:00
Michael Mauderer
23e0bafc75
Graph editor breadcrumbs integration (#8519)
Implements  #7788

[Peek 2023-12-12 10-46.webm](https://github.com/enso-org/enso/assets/1428930/7d1f45f6-8323-4adc-9a8c-f6f4bcaeb143)
2023-12-19 04:47:15 +00:00
James Dunkerley
a1508beb8c
A few minor fixes from release testing today. (#8562)
- Remove validation from old password and login password.
- Use login and logout consistently (rather than sign in and sign out in some places).
- Change message on user not found.
2023-12-15 17:28:08 +00:00
Ilya Bogdanov
9d27edafce
Fix dropdown widget style (#8531)
Fixing the dropdown widget, as discussed at the last demo.


https://github.com/enso-org/enso/assets/6566674/052462ca-1a09-428f-ba44-437355e2da1c
2023-12-15 15:07:30 +00:00
Ilya Bogdanov
41cb4e32c4
Doc panel improvements (#8530)
Fixes parts of #8135

- Fixed rendering of the documentation panel when no entry is selected.
- Multiple improvements of tags in the documentation panel:
- Group color for `GROUP` tag
- Custom styling for `DEPRECATED`, `UNSTABLE`, and `ADVANCED` tags.
- Sorting
- Collapsing tags that exceed one line with a button
- Filtering out some tags (`ICON` and `TEXT_ONLY` for now)
- Filtering out private items from the documentation
- Fixing group colors (was incorrectly assuming unique group names) and fallback color (was incorrectly replacing every character in the name with `-` before hashing, which was hilarious).
- Fixing ComponentBrowser demo scene.
- Minor fixes for mock database in demo scenes (removed duplicated entry, added an additional one for testing tags)


https://github.com/enso-org/enso/assets/6566674/10f4f5d0-9332-40c6-93c6-8263eb5fd85a
2023-12-15 14:58:57 +00:00
somebody1234
927df167d7
Set output evaluation context for a single node (#8440)
- Closes #8072
- Implement handlers for the corresponding buttons on the circular menu
- Add missing icons and styles
- Add functionality to match and extract ASTs

# Important Notes
None
2023-12-15 10:29:15 +00:00
somebody1234
c265787506
Fix console error when dragging assets (#8541)
- Fixes https://github.com/enso-org/cloud-v2/issues/808

# Important Notes
None
2023-12-14 10:33:33 +00:00
somebody1234
9fb3d9a2fa
Cleanup @/util folder (#8501)
- Partially addresses #8228
- Moves several files into `@/util/vue` and `@/util/data`
- Makes imports more consistent:
- Remove redundant trailing `.ts`
- Convert *some* imports to use `@/` rather than `./`
- Ideally it should be all imports other than the ones outside of `src/`, but I can't be sure I've found all of them
- Merge *some* duplicated imports (caused by one being an `import type`)

# Important Notes
None
2023-12-13 22:27:31 +00:00
somebody1234
f5c3713f87
Fixes for Enso Font in GUI2 (#8508)
- Fixes issue reported in Discord.

# Important Notes
None
2023-12-13 22:17:12 +00:00
Adam Obuchowicz
af50d32553
Small GUI improvements (#8535)
Minor improvements requested by @jdunkerley recently:
* Removed system cursor
* Changed shortcut for Code Editor
* Added `import Standard.Visualization` as a workaround allowing visualization previews. See https://github.com/orgs/enso-org/discussions/6832#discussioncomment-7789804

https://github.com/enso-org/enso/assets/3919101/38d822ac-28df-4a9c-a2dc-dee7adbd58ea
2023-12-13 16:26:13 +00:00
Adam Obuchowicz
ab938e896b
Some CB fixes (#8507)
Partially addresses #8495

* Delete key not working in CB and in Code Editor
* Cursor not placed at the end when adding new node with source node
* Garbage added when edited node while having another one selected.
* Closing CB when navigating.
* Too eager selecting component after filtering update.
* Premature node creation when dropping edges
* Discarding changes when clicking-off CB
2023-12-13 12:15:53 +00:00
somebody1234
857e87430d
Dashboard improvements (#8449)
- Closes https://github.com/enso-org/cloud-v2/issues/799
- Pressing return in the label name input creates a label with a color defaulting the color used by the fewest number of tags
- Right click on a label brings up a context menu
- If you drag into a folder the folder should be expanded - this should work for all kinds of drag, including labels and assets
- ⚠️ Drag & drop in Mac likely still does not work - I currently cannot test on macOS
- Closes https://github.com/enso-org/cloud-v2/issues/800
- Hide likes and the views on homepage view
- Hide "New Project" (and other items that are not applicable) in context menu when on local backend
- Download context menu option implemented for local mode
- ⚠️ Copy not implemented as backend functionality does not yet exist.

# Important Notes
None
2023-12-13 10:23:28 +00:00
Kaz Wesley
ce6c770fd7
Parse inline function signatures (#8470)
Implements #6166.

# Important Notes
- More consistent handling of `default` arguments. `default` is a valid identifier, and only has special meaning when it isn't bound in scope. Since distinguishing the builtin `default` from an identifier called `default` cannot be done until alias analysis has been performed, `default` is now represented in the AST as a regular identifier.
- `TreeToIr`: Remove `insideTypeAscription`. It was only used for bug-for-bug compatibility with the old parser during the transition.
2023-12-12 14:48:44 +00:00
Adam Obuchowicz
be2ae3279c
E2E Tests in CI (#8462)
Fixes #8433 

* Adds E2E test to `test` script in gui2 (without server)
* Add options to `run` script to specify what test should be run: `unit` (default), `e2e`, or `ci` (which runs both unit and e2e without watching/spawning report server).
* The CI test step now checks e2e tests.

### Important Notes

~~One of e2e tests was disabled because it caught the regression on develop: #8476 ~~
2023-12-12 15:27:40 +01:00
somebody1234
56a6dcc875
Hide GUI2 when not in Editor tab (#8445)
Fixes #8443

# Important Notes
None
2023-12-12 12:18:10 +00:00
somebody1234
3d76459ba7
Fix missing edges (#8461)
- Closes #8420
- Fix missing edges
- Fix displayed output type of node
- Verify that undos properly restore edges

# Important Notes
None
2023-12-11 22:36:34 +00:00
somebody1234
0974d5ff1e
Add new magnet axes (#8506)
- Closes #8460
- Add new magnet axes 32px below the bottom of the previous node, and 32px above the top of the next node

- Fix a bug where magnet alignment and "zoom to all" take into account nodes that no longer exist
- Fix a bug where "zoom to all" breaks completely right after deleting a node

# Important Notes
- Snapping with bounded cross axes were discussed during refinement, but are out of scope of this PR.
2023-12-11 17:55:37 +00:00
Michael Mauderer
b89d1b692a
Entering and leaving nodes (#8492)
Implements #8068

[Peek 2023-12-07 13-28.webm](https://github.com/enso-org/enso/assets/1428930/85da0dd6-0c08-4bef-b8e1-ba9573a3e6cd)
2023-12-10 23:48:10 +00:00
somebody1234
777ae9a047
Use Enso font (#8499)
- Closes #8485

# Important Notes
None
2023-12-08 18:45:42 +00:00
somebody1234
e562f65b99
Read file directly from location (#8490)
- Closes #6263

# Important Notes
- Still needs to be tested on Windows and macOS
- Currently does not check whether <kbd>Ctrl</kbd> is pressed to forcibly upload the file
2023-12-07 15:21:29 +00:00
Ilya Bogdanov
3d63272345
Sync presenter state not only on abort, but also on commit (#8464) 2023-12-07 18:57:31 +04:00
somebody1234
f6cf8271ca
Fix node output type (#8488)
- Partially fixes #8420

# Important Notes
- Extracted out from #8461 as the other issue may need further investigation to fix.
2023-12-07 14:35:48 +00:00
Michael Mauderer
0ec3277695
Selection widget improvements (#8477) 2023-12-07 13:26:20 +00:00
Adam Obuchowicz
32f68b7ac2
Fix visualizations (#8479)
closes #8476
2023-12-07 12:31:00 +00:00
Ilya Bogdanov
503d3d86ce
Small fixes for GUI2 (#8478)
Includes the following fixes:

1. Closes #8472
Adding animation when hovering entries, align them to the left, improve vertical alignment, make sure the currently selected entry is marked with rounded background shape.


https://github.com/enso-org/enso/assets/6566674/322748de-1321-4b32-8eef-a80a07cf8215

2. <kbd>Backspace</kbd> is now used on MacOS for deleting nodes, instead of awkward combination <kbd>Fn+Backspace</kbd>.
3. Fixed layout for vector editor.

Before:
<img width="529" alt="Screenshot 2023-12-06 at 3 23 39 PM" src="https://github.com/enso-org/enso/assets/6566674/f3d3573c-c2c0-41c4-aba3-d7350b585c8d">
After:
<img width="509" alt="Screenshot 2023-12-06 at 6 21 56 PM" src="https://github.com/enso-org/enso/assets/6566674/b4581097-e555-4d07-a812-5c6d0e7a7f62">

Also includes the fix for dynamic dropdowns from #8474. Closes #8473
2023-12-06 20:28:39 +00:00
Ilya Bogdanov
c5a6859654
Reading widget configuration from the engine (#8400)
Closes #8260

<img width="846" alt="Screenshot 2023-11-27 at 5 24 57 PM" src="https://github.com/enso-org/enso/assets/6566674/da1ba325-8e9a-43e9-9e56-c672b4987e1e">

Parsed information is not used anywhere at the moment, on the screenshot you can see a temporary debug logging not included in the PR.
2023-12-06 08:04:57 +00:00
Adam Obuchowicz
c814e5efbc
Component Browser Preview Panel (#8451)
Add CB preview panel, using engine's `executeExpression` method to get input's evaluation result without changing actual code. Also, visualization evaluation failures are reported.

![image](https://github.com/enso-org/enso/assets/3919101/1c364a7e-2f90-4397-801d-e05927762658)

# Important Notes
* **The preview does not work yet due to engine issues**.
* The full screen preview does not work properly (it closes Component Browser). Will make a separate issue for that.
* The evaluated expression calls the visualization preprocessor in such a way it handles built-in visualizations properly, but not in general case. Will start discussion with engine how to fix that.
2023-12-06 08:01:52 +00:00
somebody1234
496822b564
Add button to toggle whether passwords are visible (#8414)
- Closes https://github.com/enso-org/cloud-v2/issues/785

# Important Notes
- Added to (and hence should be tested on):
- Login screen
- Registration screen
- "Change password" modal
- Reset password screen
2023-12-06 07:50:44 +00:00
somebody1234
0fbb467507
Use MIME type parameter for drag instead of a unique MIME type (#8444)
# Important Notes
None
2023-12-06 07:47:46 +00:00
Adam Obuchowicz
6b837c31c5
Quickfix for editing problem (#8456)
I can edit nodes after this fix. ~~However, the cursor always lands at the end.~~ - this is also fixed.
2023-12-05 18:10:39 +00:00
Kaz Wesley
98988e8145
New AST types (#8263)
Introduce new AST type; use it to replace current uses of AstExtended; for now edits and synchronization are implemented on the old mechanisms (text edits / RelativeRange id map).

# Important Notes
- Edit-related code is commented out until the next PR because it is incompatible with the transitional IdMap-based synchronization.
2023-12-05 17:59:52 +00:00
somebody1234
71659882c6
Zoom to all/zoom to selected (#8459)
- Closes #6206
- Zoom to all/zoom to selected in visualizations, are now both `Mod+A`
- Implement Zoom to all/zoom to selected for the graph - shortcut is `Mod+Shift+A`, as `Mod+A` is "select all nodes"
- Animate zoom+pan

# Important Notes
None
2023-12-05 15:20:16 +00:00
Adam Obuchowicz
ee519e979b
Fix package (#8458)
Fixes #8457
2023-12-05 14:40:51 +00:00
Pavel Marek
a67297aebf
Add graalpy packages to the component directory (#8351)
Adds these JAR modules to the `component` directory inside Engine distribution:
- `graal-language-23.1.0`
- `org.bouncycastle.*` - these need to be added for graalpy language

# Important Notes
- Remove `org.bouncycastle.*` packages from `runtime.jar` fat jar.
- Make sure that the `./run` script preinstalls GraalPy standalone distribution before starting engine tests
- Note that using `python -m venv` is only possible from standalone distribution, we cannot distribute `graalpython-launcher`.
- Make sure that installation of `numpy` and its polyglot execution example works.
- Convert `Text` to `TruffleString` before passing to GraalPy - 8ee9a2816f
2023-12-04 11:50:59 +00:00
somebody1234
c60bf6e892
Fallback to default visualization based on type, when no viz has been explicitly set (#8389)
- Closes #8386
- Attempts to execute `<expr>.default_visualization` to query the engine for the *correct* fallback type
- If that is not possible, falls back to checking `inputType` - first for an exact match, then falling back to `Any` (i.e. the text/JSON visualization)
- Does not decide fallback based on the shape of the returned JSON

# Important Notes
Contains pretty significant refactors of `VisualizationMetadata` to allow it to be unset.
2023-12-01 12:41:24 +00:00
somebody1234
731fd11a74
Fix node not being draggable (#8435)
Minor regression caused by #8361.

# Important Notes
None
2023-12-01 12:40:56 +00:00
somebody1234
27072622f7
Vector editor widget (#8361)
- Closes #8261
- Add vector editor widget
- Adding element to end
- Dragging elements
- Removing elements by dragging away

# Important Notes
- Both <kbd>Left Click</kbd> and <kbd>Ctrl</kbd> + <kbd>Left Click</kbd> are supported to begin a drag.
- Just <kbd>Left Click</kbd> alone is not sufficient as some widgets interact via left click
2023-11-30 20:27:04 +00:00
somebody1234
2d35be96b4
Fix GUI2 not being interactable (#8434)
- Broken by #7612, which restructured the JSX markup for the main Dashboard component.
- Should affect (and be reproducible) on GUI1 as well.

# Important Notes
None
2023-11-30 19:34:32 +00:00
somebody1234
19ea8243b9
Fix Tailwind config for gui2 (#8427)
Fixes broken Tailwind config caused by recent dashboard changes.

# Important Notes
None
2023-11-30 13:20:09 +00:00
somebody1234
405f4be605
Project Description/Settings sidebar (#7612)
- Closes https://github.com/enso-org/cloud-v2/issues/629
- Project Description/Settings sidebar

# Important Notes
⚠️ This is blocked by backend support for asset descriptions.

When the sidebar is opening, there is one jumpy animation:
- The search bar switches from being centered in the screen, to having an equal gap between itself and its siblings
2023-11-30 12:40:01 +00:00
somebody1234
3de37bd7d3
Minor QoL improvements (#8422)
- Minor fixes for CodeMirror highlighting (the `!` to stop recursion was making the entire import line purple, and preventing strings inside operators from being highlighted)
- Change some icons that contain dark blue, to use `currentColor` instead
- Add execution time to hover tooltip (the LS is sending it, so might as well display it)

# Important Notes
None
2023-11-30 11:58:08 +00:00
Michael Mauderer
2014c88254
Implement Dropdown Widgets. (#8411)
Closes #8259

[Peek 2023-11-28 12-22.webm](https://github.com/enso-org/enso/assets/1428930/8696bb0f-15de-46a6-9664-a30da931d6df)

# Important Notes
Some TODOs left for after the AST refactoring:
* Updating the AST with the elected value.
* Getting the Expr ID from the parent node to determine the correct color.
2023-11-30 11:56:23 +00:00
somebody1234
1e93e69523
Improve label interactions (#8417)
- Fixes https://github.com/enso-org/cloud-v2/issues/781
- Implement parser for search query
- Change all UI (labels column, labels side panel, searcher in top bar) to use search query parser
- Change "remove label from asset" to right click
- Also add a tooltip to notify user that right click removes the label
- Change click action on label on asset, to toggle the label from the search
- Stop sending the list of labels for filtering on the server side

Unrelated changes:
- Switch dashboard dev server to use Vite. All other servers should be unaffected.
- `ide watch` works
- `ide build` works
- `gui watch` works
- `dashboard build` works

# Important Notes
There are quite a lot of new interactions with the search bar which should probably all be tested.
2023-11-29 17:29:25 +00:00
somebody1234
dff1c0c88b
Errors on nodes (#8409)
- Closes #8288
- Show both `Panic`s and `DataflowError`s on nodes
- Update Code Editor diagnostics to use the same functionality to properly display `DataflowError`s

# Important Notes
- Does not include warnings
- ✔️ Done basic testing to ensure that errors *should* disappear and reappear as appropriate
2023-11-29 14:34:07 +00:00
somebody1234
5216b8c0cb
Make node expand to visualization width (#8394)
- Closes #8234
- Make node expand to full width of visualization
- Have a fixed minimum width for visualizations, to be able to show at least the toolbar
- Clip viz-defined toolbars to the width visualization (don't let them overflow)
- We can consider wrapping viz-defined toolbars onto a separate line, later down the line

# Important Notes
None
2023-11-29 04:40:51 +00:00
somebody1234
195faed9e4
Avoid placing a new node over a visualization (#8412)
- Closes #8368

# Important Notes
Could not repro the leftwards drift of new nodes. It is possible that this has already been fixed by another PR.
2023-11-29 03:22:50 +00:00
somebody1234
05d613fdc9
Download latest release instead of nightly (#8402)
The download button previously pointed to the latest nightly, instead of the latest stable release. This is bad, because (like now) the nightlies may be broken.

# Important Notes
None
2023-11-28 16:02:05 +00:00
somebody1234
93a4937cc4
Add profiling shortcuts to GUI2 (#8406)
- Closes #8404

# Important Notes
- All relevant documentation has already been updated in #8358.
- I've tested that the keyboard shortcuts send appropriate messages over the LS connection, and have confirmed that a non-error response is received, but I'm not sure that the profiling actually works.
- There seem to be no entries in `~/.enso/`, nor in `~/enso/`
2023-11-28 14:44:46 +00:00
Adam Obuchowicz
a38680adf4
CB Fixes and Improvements (#8385)
* The "main view" (when no self type/module nor pattern is specified) contains all methods defined in top modules of every library
* Entries defined inside any "Internal" module from stdlib will be hidden by default; they will be visible only when self type is specified or the module path leading to such module internals.
* Fixed an issue with missing groups sometimes - we must wait with asking for groups for first executionComplete message.
* Modules and local variables have different default icon.

![image](https://github.com/enso-org/enso/assets/3919101/cb33691e-222b-413e-a92e-2cf84e9fe4bb)

![image](https://github.com/enso-org/enso/assets/3919101/beab202d-4feb-4b00-ba0c-c141862da53c)
2023-11-28 10:38:28 +00:00
Paweł Grabarz
1ad7a4bf5a
fix edge dragging and method argument assignment (#8388)
Fixed broken edge dragging and creating nodes from ports. Added basic support for multiple output ports, driven by already existing analysis of the port binding structure. Those constructs are not yet supported by the engine (hence the error in code), but the IDE has easier time already dealing with ports as individual binding expressions, not whole nodes.

<img width="865" alt="image" src="https://github.com/enso-org/enso/assets/919491/73126593-05c0-4553-ba6d-dad97d083c48">

Also improved the ability to interpret applied method arguments. Different cases of dynamic, static calls or partially applied functions are now properly supported.

<img width="961" alt="image" src="https://github.com/enso-org/enso/assets/919491/ffe02d79-841c-411d-a218-de89c2522f7b">
2023-11-27 16:34:34 +00:00
somebody1234
9b7e3d0f16
E2E tests (#8239)
- Closes #8179

# Important Notes
- ⚠️ These tests are currently *not run* on any CI workflow.
- There is some unused code for mocking the PM. This has been intentionally kept, as this may be useful in the future.
Note that this may be useful for testing the dashboard, however the dashboard is currently only tested in cloud mode
- that is, without the backend switcher, and with only the remote backend available. As such, currently it uses HTTP API mocks, and no PM mock.
2023-11-27 15:48:37 +00:00
Michał Wawrzyniec Urbańczyk
b51dfe5a5b
macOS notarization fix (#8392) 2023-11-27 16:05:09 +01:00
Ilya Bogdanov
8516ed5cbb
Imports in CB (#8315)
Closes #8066


https://github.com/enso-org/enso/assets/6566674/ecd3d032-286b-4bfa-8dc6-96e178f595f3
2023-11-24 14:22:26 +00:00
somebody1234
b33285c634
Fix auto layout (#8345)
So it turns out auto-layout was broken if there were existing, already positioned nodes

# Important Notes
None
2023-11-24 10:49:15 +00:00
Paweł Grabarz
ec5c60b74d
fix incorrect byte array comparison (#8379)
Fixes an exception when opening the code editor. `indexedDB.cmp` doesn't accept `undefined` values. Moved its usage to a separate function to guard against that.
2023-11-24 08:54:23 +00:00
Michał Wawrzyniec Urbańczyk
8021109d8c
Build script fixes & improvements (#8285) 2023-11-23 21:19:31 +01:00
Michael Mauderer
76fb9f5c4b
All ways of creating node (+ button, dragging out edges) (#8341)
Closes #8054

[Peek 2023-11-20 13-50.webm](https://github.com/enso-org/enso/assets/1428930/064ad921-25dc-44f4-bed4-10b4f0ec0242)
2023-11-23 17:47:53 +00:00
Adam Obuchowicz
ce584862ff
Fix a set of issues in Component Browser (#8377)
Part of #8372

* Sorting was broken (sort's argument was removed)
* searching by initials now does not skip words
* icons: now we use same logic as existing nodes.
* local entities has worse score if "showLocals" option is toggled off.

# Important Notes
Please be aware that there is still an important issue with groups; sometimes they're not loaded. Reported [here](8376)
2023-11-23 15:53:59 +00:00
Dmitry Bushev
4b3ba78b52
Add shortcuts to start and stop the backend profiling (#8358)
close #8329

Changelog:
- add: `cmd`+`shift`+`,` and `cmd`+`shift`+`.` shortcuts to start and stop the backend profiling. Profiling data is stored on disk.
2023-11-23 15:31:17 +00:00
somebody1234
87dfb57f53
Show diagnostics in Code Editor (#8375)
As suggested by @JaroslavTulach.

- Shows diagnostics sent by `executionContext/executionStatus`
- Shows `Panic`s and `DataflowError`s sent by `executionContext/expressionUpdates`

# Important Notes
None
2023-11-23 14:15:48 +00:00
Adam Obuchowicz
2ddcaad6fe
Fix startup in the electron package (#8365)
Fixes #8334

There were two issues: one is bad code generated by vite. I needed to rephrase Rect.Zero definition. The second were missing widgets - that was caused by the fact that Vue components have a bit different properties than on test builds, apparently.
2023-11-23 11:03:23 +00:00
Adam Obuchowicz
fbe4221c46
Edges from alias analysis (#8316)
Fixes #8252

As we use proper alias analysis, we no longer display connections to overshadowed identifiers.

![Screenshot from 2023-11-16 15-50-27](https://github.com/enso-org/enso/assets/3919101/691aac6c-1951-4988-a338-4449c0413ef7)

# Important Notes
I've changed the meaning of edge's "source" - now it's expression ID of the constituted identifier, not the node ID. This will allow proper handling nodes like `[x, y] = Main.get_point` once the engine will support them.
2023-11-23 10:54:35 +00:00
James Dunkerley
ed9e71c4eb
Make ICON section work consistently between old and new GUI. (#8369)
- Handle name mismatch in icons between old and new IDE.
- Set the default icon for a few types.
- If can't find and icon use the Enso logo.

![image](https://github.com/enso-org/enso/assets/4699705/43d828b4-58cf-429e-b659-b1c389953b23)
2023-11-23 09:03:34 +00:00
somebody1234
1cf5ea96d6
More consistent reactive indices (#8353)
- Renames all `ReactiveIndex` and `ReactiveDb`s into the format `<key>To<value>`
- `ReactiveMapping`s (in `graphDatabase.ts`) currently have not been renamed - I'm not sure they need to be
- Removes various methods that have been made unnecessary by this change
- Simplifies some other methods
- Changes `SuggestionDb` to extend `ReactiveDb`

# Important Notes
None
2023-11-23 04:48:12 +00:00
Paweł Grabarz
e492d3f260
[GUI2] Render widget arguments (#8339)
Fixes #8256 #8257

Implemented displaying node argument placeholders. Refactored widgets to allow arbitrary input types, and split widget matching into two phases, separating input type validation step and allowing it to influence the derived TypeScript type of widget component props.

Connecting an edge to the placeholder is not implemented yet. Only connections to existing arguments are supported for now.

https://github.com/enso-org/enso/assets/919491/ad3bf254-5f56-4f2f-8c0d-616a7195c6d8


Nested argument lists are also supported:
<img width="396" alt="image" src="https://github.com/enso-org/enso/assets/919491/b61f6870-0f01-48c3-9b45-c7c6bc464638">
2023-11-22 14:43:58 +00:00
somebody1234
d136c8e40c
Fix dashboard issues (#8347)
- Fixes https://github.com/enso-org/cloud-v2/issues/770
- Fixes https://github.com/enso-org/cloud-v2/issues/772
- Fixes https://github.com/enso-org/cloud-v2/issues/775
- Fixes #8335

# Important Notes
The fix for "Reopening cloud projects" has not been tested, as opening projects on the cloud are currently broken - *however*, the logic change is very small - the only thing it does is make the reopening conditional. This means that, at the very least, it should not be a regression.
2023-11-21 10:37:45 +00:00
somebody1234
feb59be0a1
Fix styles for confirm delete modal (#8312)
The background for the "confirm delete" modal was offset - the fix is to add `inset-0`.

# Important Notes
None
2023-11-21 06:51:15 +00:00
somebody1234
5e1a3124dc
Download and upgrade buttons (#8265)
- Adds a download button in the user menu

# Important Notes
- The "upgrade to" button will be absent when the user already has a plan, as the only place where an "upgrade to" button shows up is the cloud view, when the user's account has not yet been enabled.
- The upgrade button currently links to https://enso.org/pricing - which does not yet exist. This is intentional, as another PR would be required to switch the URL, if we were to initially point to the one at https://enso-org.github.io.
- The pricing page would still not work, as that requires payment functionality, which is not yet complete
2023-11-21 06:34:46 +00:00
somebody1234
375e610660
Layout nodes without position (#8326)
- Closes #8071

# Important Notes
There is currently no way to predict the width a node, taking into account the width of widgets.
This should probably be done in another task.
2023-11-20 14:17:34 +00:00