From 2b41481a1253a0eeb086e349fa2578f6dd72ecc4 Mon Sep 17 00:00:00 2001 From: Dmitrii Polovnev Date: Tue, 14 May 2024 04:41:56 +0300 Subject: [PATCH] #4380 - Refactor (RnaPresetGroup.tsx): Specify the type --- .../monomerLibrary/RnaPresetGroup/RnaPresetGroup.tsx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/packages/ketcher-macromolecules/src/components/monomerLibrary/RnaPresetGroup/RnaPresetGroup.tsx b/packages/ketcher-macromolecules/src/components/monomerLibrary/RnaPresetGroup/RnaPresetGroup.tsx index 11ab8e4bd4..02d9e63e22 100644 --- a/packages/ketcher-macromolecules/src/components/monomerLibrary/RnaPresetGroup/RnaPresetGroup.tsx +++ b/packages/ketcher-macromolecules/src/components/monomerLibrary/RnaPresetGroup/RnaPresetGroup.tsx @@ -16,6 +16,7 @@ import { calculateNucleosideOrNucleotidePreviewTop } from 'helpers'; import { useAppSelector } from 'hooks'; +import { MonomerItemType } from 'ketcher-core'; import { debounce } from 'lodash'; import { MouseEvent, useCallback, useMemo } from 'react'; import { @@ -96,7 +97,11 @@ export const RnaPresetGroup = ({ presets, duplicatePreset, editPreset }) => { if (preview.nucleotide || !e.currentTarget) { return; } - const nucleotideParts = [preset.sugar, preset.base, preset.phosphate]; + const nucleotideParts: ReadonlyArray = [ + preset.sugar, + preset.base, + preset.phosphate, + ]; const cardCoordinates = e.currentTarget.getBoundingClientRect(); const previewStyle = calculateNucleosideOrNucleotidePreviewTop(cardCoordinates);