Skip to content

Commit

Permalink
#6546 - Macro structure duplicated on canvas when using ketcher.getMo…
Browse files Browse the repository at this point in the history
…lfile() and pasting (#6547)

* #6546 - Macro structure duplicated on canvas when using ketcher.getMolfile() and pasting
* - updated ketcher to 3.0.1
  • Loading branch information
rrodionov91 authored Feb 20, 2025
1 parent 9ee9140 commit 4c1fce2
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 9 deletions.
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/ketcher-core/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ketcher-core",
"version": "3.0.0",
"version": "3.0.1",
"description": "Web-based molecule sketcher",
"license": "Apache-2.0",
"homepage": "http://lifescience.opensource.epam.com/ketcher",
Expand Down
1 change: 1 addition & 0 deletions packages/ketcher-core/src/application/editor/Editor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -759,6 +759,7 @@ export class CoreEditor {
}
this._monomersLibraryParsedJson = null;
this._type = EditorType.Micromolecules;
this.drawingEntitiesManager = new DrawingEntitiesManager();
}

private switchToMacromolecules() {
Expand Down
5 changes: 4 additions & 1 deletion packages/ketcher-core/src/application/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,13 @@ export function getStructure(
): Promise<string> {
const serverSettings = ketcherProvider.getKetcher().editor.serverSettings;
const formatter = formatterFactory.create(structureFormat, serverSettings);
const drawingEntitiesManagerCloningResult = drawingEntitiesManager?.mergeInto(
new DrawingEntitiesManager(),
);

return formatter.getStructureFromStructAsync(
struct,
drawingEntitiesManager,
drawingEntitiesManagerCloningResult?.mergedDrawingEntities,
selection,
);
}
Expand Down
2 changes: 1 addition & 1 deletion packages/ketcher-macromolecules/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ketcher-macromolecules",
"version": "3.0.0",
"version": "3.0.1",
"description": "Web-based molecule sketcher",
"license": "Apache-2.0",
"homepage": "http://lifescience.opensource.epam.com/ketcher",
Expand Down
2 changes: 1 addition & 1 deletion packages/ketcher-react/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ketcher-react",
"version": "3.0.0",
"version": "3.0.1",
"description": "Web-based molecule sketcher",
"license": "Apache-2.0",
"homepage": "http://lifescience.opensource.epam.com/ketcher",
Expand Down
2 changes: 1 addition & 1 deletion packages/ketcher-standalone/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ketcher-standalone",
"version": "3.0.0",
"version": "3.0.1",
"description": "Web-based molecule sketcher",
"license": "Apache-2.0",
"homepage": "http://lifescience.opensource.epam.com/ketcher",
Expand Down

0 comments on commit 4c1fce2

Please sign in to comment.