Closed kochis closed 9 months ago
This pull request is automatically built and testable in CodeSandbox.
To see build info of the built libraries, click here or the icon next to each commit SHA.
Latest deployment of this branch, based on commit 8a1a5ac42baaca86be4394adc4a9788a6f0cab20:
Sandbox | Source |
---|---|
maputnik | Configuration |
@kochis thx! Could you give some instructions on testing this? I'm slowly getting back into reviewing it
@kochis I see how this makes sense (assuming style spec diff is trust worthy). We have now brought everything to a state where this can be maintained. There's e2e test that checks undo/redo, but they don't check this scenario, so I think it would be good to have either an e2e test or a unit test around this code. You'll need to migrate this code to use maplibre diff and move it to the relevant typescript file. Hope this is still relevant for you.
I've tested this code for comments change, which is not defined as a change in terms of the maplibre-style-spec code. I'm not sure if this is a bug there as comments are not considered to be a style change for maplibre-gl. The redo fix is probably correct anyway and needs to be added to the code.
Closing this PR for now, I think a proper style change mechanism should be used here but I'm not sure the diff
of maplibre-style-spec is the right solution.
Similar to issue https://github.com/maputnik/editor/issues/753, I've run into some odd behavior when trying undo/redo recent changes.
I've been using this change in a local fork, and it's seemed to be running pretty well. The main logic changes are: