- 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.
* 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>
- 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.
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.
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).
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?
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.
- 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
- 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
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.
- 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.
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.
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.
Fix an oversight of project validation disallowing `accessToken: null`, which will be the case when in offline mode/not logged in.
# Important Notes
None
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.
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.
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.
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).
#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.
- 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.