Skip to content

Commit

Permalink
Merge pull request #1172 from nataliauvarova/kalmyk_markup
Browse files Browse the repository at this point in the history
kalmyk markup: fix modal
  • Loading branch information
nataliauvarova authored Dec 19, 2024
2 parents e751af9 + bea9bda commit 1d92f8a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 24 deletions.
4 changes: 4 additions & 0 deletions src/api/i18n.js
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,7 @@ export const stringsToTranslate = [
"Definitely endangered",
"Delete",
"Delete image file",
"Delete groups",
"Delete markup",
"Delete markup file",
"Delete markup group",
Expand Down Expand Up @@ -865,6 +866,7 @@ export const stringsToTranslate = [
"subjunctive",
"Submit",
"Subscribe all the existing dictionaries and corpora related to this language and its sublanguages",
"Success",
"Successfully added",
"Successfully created perspective.",
"Successfully deleted organization",
Expand All @@ -882,6 +884,8 @@ export const stringsToTranslate = [
"Tense-Aspect",
"text entities analysed",
"Text markup",
"The group was successfully added.",
"The group was successfully deleted.",
"The entity is currently published. Click to unpublish.",
"The entity is NOT currently published. Click to publish.",
"The pros of the LingvoDoc platform",
Expand Down
25 changes: 2 additions & 23 deletions src/components/JoinMarkupsModal/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -147,8 +147,6 @@ const JoinMarkupsModal = ({ perspectiveId, onClose }) => {
});

const onAddRelation = useCallback(() => {
//console.log("onAddRelation!!!!!!!");

resetMessages();

if (!firstTextRelation || !secondTextRelation || !typeRelation) {
Expand Down Expand Up @@ -189,14 +187,6 @@ const JoinMarkupsModal = ({ perspectiveId, onClose }) => {
markups.push(...group_markups);
});

/*
console.log("onDeleteRelation!!!!!!!");
console.log("Их будем удалять: selectedRelations====");
console.log(groupIds);
console.log("Их будем удалять: selectedMarkups====");
console.log(markups);
*/

deleteMarkupGroup({
variables: { groupIds, markups }
}).then(refetch);
Expand All @@ -208,8 +198,6 @@ const JoinMarkupsModal = ({ perspectiveId, onClose }) => {
}, [groupDict, selectedRelations]);

const onRelationSelect = (relation_id, checked) => {
//console.log("onRelationSelect!!!!!!!");

const selectedIds = selectedRelations;

const position = selectedIds.indexOf(relation_id);
Expand All @@ -231,9 +219,6 @@ const JoinMarkupsModal = ({ perspectiveId, onClose }) => {
/*console.log("perspectiveId====");
console.log(perspectiveId);
console.log("mode====");
console.log(mode);
console.log("onClose====");
console.log(onClose);
Expand Down Expand Up @@ -274,12 +259,9 @@ const JoinMarkupsModal = ({ perspectiveId, onClose }) => {
<Table.Header>
<Table.Row>
<Table.HeaderCell>
{/* new!!!! */}
<div className="selected-markup">
{firstField.split("_")[1]}: <span className="selected-markup__text">{firstText}</span>
</div>
{/*{firstField.split("_")[1]}: {firstText}*/}
{/* /new!!!! */}
</Table.HeaderCell>
</Table.Row>
</Table.Header>
Expand Down Expand Up @@ -308,12 +290,9 @@ const JoinMarkupsModal = ({ perspectiveId, onClose }) => {
<Table.Header>
<Table.Row>
<Table.HeaderCell>
{/* new!!!! */}
<div className="selected-markup">
{secondField.split("_")[1]}: <span className="selected-markup__text">{secondText}</span>
</div>
{/*{secondField.split("_")[1]}: {secondText}*/}
{/* /new!!!! */}
</Table.HeaderCell>
</Table.Row>
</Table.Header>
Expand Down Expand Up @@ -389,13 +368,13 @@ const JoinMarkupsModal = ({ perspectiveId, onClose }) => {
</div>

{warnMessage && (
<Message warning>
<Message warning style={{ minHeight: "auto", marginTop: "0" }}>
<Message.Header>{getTranslation("Warning")}</Message.Header>
<p>{getTranslation(warnMessage)}</p>
</Message>
)}
{successMessage && (
<Message positive>
<Message positive style={{ minHeight: "auto", marginTop: "0" }}>
<Message.Header>{getTranslation("Success")}</Message.Header>
<p>{getTranslation(successMessage)}</p>
</Message>
Expand Down
1 change: 0 additions & 1 deletion src/components/JoinMarkupsModal/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 1;
/*-webkit-line-clamp: 2;*/
overflow: hidden;
overflow-wrap: break-word;
}
Expand Down

0 comments on commit 1d92f8a

Please sign in to comment.