Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Context size fixed #248

Merged
merged 1 commit into from
Jan 2, 2018
Merged

Context size fixed #248

merged 1 commit into from
Jan 2, 2018

Conversation

Androbin
Copy link
Contributor

@Androbin Androbin commented Jan 1, 2018

Deconflicts #78

$(this).attr('id', 'wordGettingSuggested');
var wrapLength = parseInt(config.SUGGESTIONS.context_size);
context = getContext(fromWord, wrapLength);
$('#translatedTextClone').html(context);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'context' is not defined no-undef

var fromWord = $(this).html();
$(this).attr('id', 'wordGettingSuggested');
var wrapLength = parseInt(config.SUGGESTIONS.context_size);
context = getContext(fromWord, wrapLength);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'context' is not defined no-undef

$('#translatedTextClone').html($('#translatedText').attr('pristineText'));
var fromWord = $(this).html();
$(this).attr('id', 'wordGettingSuggested');
var wrapLength = parseInt(config.SUGGESTIONS.context_size);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing radix parameter radix

var markedWord = mark + fromWord;
var rawText = $("#translatedText").html();
var cleanMarkedText = rawText.replace(/<span[^>]*id="wordGettingSuggested"[^>]*>/g, mark);
var cleanMarkedText = cleanMarkedText.replace(/<[/]?span[^>]*>/g, '');

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'cleanMarkedText' is already defined no-redeclare

function getContext(fromWord, wrapLength) {
var mark = 'MEGAWORD!';
var markedWord = mark + fromWord;
var rawText = $("#translatedText").html();

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strings must use singlequote quotes

@sushain97
Copy link
Member

I don't really know what this does but I'm going to merge it anyway since the suggestions branch will be reviewed fully in the future anyway.

@sushain97 sushain97 merged commit e074cae into apertium:issue-55-suggestions Jan 2, 2018
@Androbin Androbin deleted the kira branch January 2, 2018 18:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants