Skip to content

Commit b946173

Browse files
stevietvmynameisbogdan
authored andcommittedJan 24, 2024
Add Regular Expression Custom Format translation
(cherry picked from commit 9f50166fa62a71d0a23e2c2d331651792285dc0e) Closes #9678
1 parent e5ccc32 commit b946173

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed
 

‎frontend/src/Settings/CustomFormats/CustomFormats/Specifications/EditSpecificationModalContent.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ function EditSpecificationModalContent(props) {
4949
{...otherProps}
5050
>
5151
{
52-
fields && fields.some((x) => x.label === 'Regular Expression') &&
52+
fields && fields.some((x) => x.label === translate('CustomFormatsSpecificationRegularExpression')) &&
5353
<Alert kind={kinds.INFO}>
5454
<div>
5555
<div dangerouslySetInnerHTML={{ __html: translate('ThisConditionMatchesUsingRegularExpressions', ['<code>\\^$.|?*+()[{</code>', '<code>\\</code>']) }} />

‎src/NzbDrone.Core/CustomFormats/Specifications/RegexSpecificationBase.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ public abstract class RegexSpecificationBase : CustomFormatSpecificationBase
2121
protected Regex _regex;
2222
protected string _raw;
2323

24-
[FieldDefinition(1, Label = "Regular Expression", HelpText = "Custom Format RegEx is Case Insensitive")]
24+
[FieldDefinition(1, Label = "CustomFormatsSpecificationRegularExpression", HelpText = "CustomFormatsSpecificationRegularExpressionHelpText")]
2525
public string Value
2626
{
2727
get => _raw;

‎src/NzbDrone.Core/Localization/Core/en.json

+2
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,8 @@
220220
"CustomFormats": "Custom Formats",
221221
"CustomFormatsSettings": "Custom Formats Settings",
222222
"CustomFormatsSettingsSummary": "Custom Formats and Settings",
223+
"CustomFormatsSpecificationRegularExpression": "Regular Expression",
224+
"CustomFormatsSpecificationRegularExpressionHelpText": "Custom Format RegEx is Case Insensitive",
223225
"Cutoff": "Cutoff",
224226
"CutoffFormatScoreHelpText": "Once the quality cutoff is met or exceeded and this custom format score is reached {appName} will no longer grab or import upgrades for those movies",
225227
"CutoffHelpText": "Once this quality is reached {appName} will no longer download movies after the custom format cutoff score is met or exceeded",

0 commit comments

Comments
 (0)
Please sign in to comment.