Repository: platers/obsidian-linter (ts)

Issue:
Bug: There is a space between the underline and the Chinese text
- [x] I have verified that I am on the latest version of the Linter

## Describe the Bug

such as

English: Hello-World, that is no bug
Chinese: 你好 - 世界，I think this is a bug, not feature or regular.

## Expected Behavior

Expected output if applicable:

``` markdown
你好-世界
```

FR: Ignore hyphens in "Space between Chinese Japanese or Korean and English or numbers"
Thank you for maintaining this important plugin.

## Is Your Feature Request Related to a Problem? Please Describe.

In the CJK languages, mathematical terms often take the form of `<Latin or Greek alphabet>-<CJK characters>`. For example, "σ-field" is translated into Japanese as "σ-加法族".
Applying the rule [Space between Chinese Japanese or Korean and English or numbers](https://platers.github.io/obsidian-linter/settings/spacing-rules/#space-between-chinese-japanese-or-korean-and-english-or-numbers) to `σ-加法族` or `$\sigma$-加法族` results in `σ- 加法族` or `$\sigma$- 加法族`.

However, **there should not be a whitespace between the hyphen `-` and `加法族`**, i.e. those terms should be kept untouched.

## Describe the Solution You'd Like

It would be great if there were an option that does not treat hyphens as English characters.

Example:

Before
``` markdown
English日本語
English-日本語
```

After
``` markdown
English 日本語
English-日本語
```

## Describe Alternatives You've Considered

None

## Additional Context

None


Pull request description:
Feat: Customize CJK English Spacing
Fixes #1072 
Fixes #1036

There were a couple of requests to allow for some variation in how the CJK spacing rule picked up on which characters to consider to be English. It seems that "-" was one that several people were using as a non-English character even though it is not a fullwidth character. So as a compromise, the list of punctuation and symbols to consider English characters is being exposed in two options: before and after characters. This should make it more customizeable to the user's needs.

Changes Made:
- Added some tests for the scenarios mentioned
- Exposed the before and after English symbols and punctuation to users with the caveat that `*` is not exposed and will not be unless there is a really good reason to do so since it could cause issues with markdown formatting.
- Added the ability to fill out the default value onload if it is missing

Patch:
diff --git a/docs/additional-info/rules/paragraph-blank-lines.md b/docs/additional-info/rules/paragraph-blank-lines.md
index 4c33660..62faedb 100644
--- a/docs/additional-info/rules/paragraph-blank-lines.md
+++ b/docs/additional-info/rules/paragraph-blank-lines.md
@@ -3,4 +3,4 @@
 
 #### When Is a Blank Line Added?
 
-When a paragraph has another line after the current one and it does not end in 2 or more spaces, `<br>`, `<br/>`, or `\`.
+When a paragraph has another line after the current one and it does not end in 2 or more spaces or `<br>` or `<br/>`.
diff --git a/src/lang/locale/de.ts b/src/lang/locale/de.ts
index 2da616f..d99e784 100644
--- a/src/lang/locale/de.ts
+++ b/src/lang/locale/de.ts
@@ -785,10 +785,5 @@ export default {
     '‘’': '‘’', // leave as is
     '""': '""', // leave as is
     '“”': '“”', // leave as is
-    // yaml.ts
-    '\\': '\\', // leave as is
-    '<br>': '<br>', // leave as is
-    '  ': '  ', // leave as is
-    '<br/>': '<br/>', // leave as is
   },
 };
diff --git a/src/lang/locale/en.ts b/src/lang/locale/en.ts
index 9d0d6c2..2095b9f 100644
--- a/src/lang/locale/en.ts
+++ b/src/lang/locale/en.ts
@@ -696,6 +696,14 @@ export default {
     'space-between-chinese-japanese-or-korean-and-english-or-numbers': {
       'name': 'Space between Chinese Japanese or Korean and English or numbers',
       'description': 'Ensures that Chinese, Japanese, or Korean and English or numbers are separated by a single space. Follows these [guidelines](https://github.com/sparanoid/chinese-copywriting-guidelines)',
+      'english-symbols-punctuation-before': {
+        'name': 'English Punctuations and Symbols Before CJK',
+        'description': 'The list of non-letter punctuation and symbols to consider to be from English when found before Chinese, Japanese, or Korean characters. **Note: "*" is always considered to be English and is necessary for handling some markdown syntaxes properly.**',
+      },
+      'english-symbols-punctuation-after': {
+        'name': 'English Punctuations and Symbols After CJK',
+        'description': 'The list of non-letter punctuation and symbols to consider to be from English when found after Chinese, Japanese, or Korean characters. **Note: "*" is always considered to be English and is necessary for handling some markdown syntaxes properly.**',
+      },
     },
     // strong-style.ts
     'strong-style': {
@@ -717,12 +725,8 @@ export default {
     },
     // two-spaces-between-lines-with-content.ts
     'two-spaces-between-lines-with-content': {
-      'name': 'Line Break Between Lines with Content',
-      'description': 'Makes sure that the specified line break is added to the ends of lines with content continued on the next line for paragraphs, blockquotes, and list items',
-      'line-break-indicator': {
-        'name': 'Line Break Indicator',
-        'description': 'The line break indicator to use.',
-      },
+      'name': 'Two Spaces Between Lines with Content',
+      'description': 'Makes sure that two spaces are added to the ends of lines with content continued on the next line for paragraphs, blockquotes, and list items',
     },
     // unordered-list-style.ts
     'unordered-list-style': {
@@ -861,10 +865,5 @@ export default {
     '‘’': '‘’', // leave as is
     '""': '""', // leave as is
     '“”': '“”', // leave as is
-    // yaml.ts
-    '\\': '\\', // leave as is
-    '<br>': '<br>', // leave as is
-    '  ': '  ', // leave as is
-    '<br/>': '<br/>', // leave as is
   },
 };
diff --git a/src/lang/locale/es.ts b/src/lang/locale/es.ts
index 4dd3e96..98dbf91 100644
--- a/src/lang/locale/es.ts
+++ b/src/lang/locale/es.ts
@@ -565,11 +565,7 @@ export default {
     },
     'two-spaces-between-lines-with-content': {
       'name': 'Dos espacios entre líneas con contenido',
-      'description': 'Se asegura de que el salto de línea especificado se agregue al final de las líneas y el contenido continúe en la línea siguiente para párrafos, citas en bloque y elementos de lista.',
-      'line-break-indicator': {
-        'name': 'Indicador de salto de línea',
-        'description': 'El indicador de salto de línea a utilizar.',
-      },
+      'description': 'Se asegura de que se agreguen dos espacios al final de las líneas con contenido que continúa en la siguiente línea para párrafos, comillas y elementos de lista',
     },
     'unordered-list-style': {
       'name': 'Estilo de lista desordenada',
@@ -698,10 +694,5 @@ export default {
     '‘’': '‘’', // leave as is
     '""': '""', // leave as is
     '“”': '“”', // leave as is
-    // yaml.ts
-    '\\': '\\', // leave as is
-    '<br>': '<br>', // leave as is
-    '  ': '  ', // leave as is
-    '<br/>': '<br/>', // leave as is
   },
 };
diff --git a/src/lang/locale/tr.ts b/src/lang/locale/tr.ts
index 5429d11..86efbb6 100644
--- a/src/lang/locale/tr.ts
+++ b/src/lang/locale/tr.ts
@@ -781,10 +781,5 @@ export default {
     '‘’': '‘’', // leave as is
     '""': '""', // leave as is
     '“”': '“”', // leave as is
-    // yaml.ts
-    '\\': '\\', // leave as is
-    '<br>': '<br>', // leave as is
-    '  ': '  ', // leave as is
-    '<br/>': '<br/>', // leave as is
   },
 };
diff --git a/src/lang/locale/zh-cn.ts b/src/lang/locale/zh-cn.ts
index 3799a3f..329df63 100644
--- a/src/lang/locale/zh-cn.ts
+++ b/src/lang/locale/zh-cn.ts
@@ -844,10 +844,5 @@ export default {
     '‘’': '‘’', // leave as is
     '""': '""', // leave as is
     '“”': '“”', // leave as is
-    // yaml.ts
-    '\\': '\\', // leave as is
-    '<br>': '<br>', // leave as is
-    '  ': '  ', // leave as is
-    '<br/>': '<br/>', // leave as is
   },
 };
diff --git a/src/main.ts b/src/main.ts
index f96311d..4b2ce58 100644
--- a/src/main.ts
+++ b/src/main.ts
@@ -124,6 +124,18 @@ export default class LinterPlugin extends Plugin {
       if (!this.settings.ruleConfigs[rule.alias]) {
         this.settings.ruleConfigs[rule.alias] = rule.getDefaultOptions();
       }
+
+      // remove this after a reasonable amount of time
+      if (rule.alias == 'space-between-chinese-japanese-or-korean-and-english-or-numbers') {
+        const defaults = rule.getDefaultOptions();
+        if (!('english-symbols-punctuation-before' in this.settings.ruleConfigs[rule.alias])) {
+          this.settings.ruleConfigs[rule.alias]['english-symbols-punctuation-before'] = defaults['english-symbols-punctuation-before'];
+        }
+
+        if (!('english-symbols-punctuation-after' in this.settings.ruleConfigs[rule.alias])) {
+          this.settings.ruleConfigs[rule.alias]['english-symbols-punctuation-after'] = defaults['english-symbols-punctuation-after'];
+        }
+      }
     }
 
     this.updatePasteOverrideStatus();
diff --git a/src/rules/paragraph-blank-lines.ts b/src/rules/paragraph-blank-lines.ts
index d5acc90..90fd3be 100644
--- a/src/rules/paragraph-blank-lines.ts
+++ b/src/rules/paragraph-blank-lines.ts
@@ -40,13 +40,12 @@ export default class ParagraphBlankLines extends RuleBuilder<ParagraphBlankLines
         `,
       }),
       new ExampleBuilder({
-        description: 'Paragraphs can be extended via the use of 2 or more spaces at the end of a line, a line break html or xml, or a backslash (\\)',
+        description: 'Paragraphs can be extended via the use of 2 or more spaces at the end of a line or line break html',
         before: dedent`
           # H1
           Content${'  '}
           Paragraph content continued <br>
           Paragraph content continued once more <br/>
-          Paragraph content yet again\\
           Last line of paragraph
           A new paragraph
           # H2
@@ -57,7 +56,6 @@ export default class ParagraphBlankLines extends RuleBuilder<ParagraphBlankLines
           Content${'  '}
           Paragraph content continued <br>
           Paragraph content continued once more <br/>
-          Paragraph content yet again\\
           Last line of paragraph
           ${''}
           A new paragraph
diff --git a/src/rules/space-between-chinese-japanese-or-korean-and-english-or-numbers.ts b/src/rules/space-between-chinese-japanese-or-korean-and-english-or-numbers.ts
index 02e7865..525de4b 100644
--- a/src/rules/space-between-chinese-japanese-or-korean-and-english-or-numbers.ts
+++ b/src/rules/space-between-chinese-japanese-or-korean-and-english-or-numbers.ts
@@ -1,10 +1,14 @@
 import {Options, RuleType} from '../rules';
-import RuleBuilder, {ExampleBuilder, OptionBuilderBase} from './rule-builder';
+import RuleBuilder, {ExampleBuilder, OptionBuilderBase, TextOptionBuilder} from './rule-builder';
 import dedent from 'ts-dedent';
 import {ignoreListOfTypes, IgnoreTypes} from '../utils/ignore-types';
 import {updateBoldText, updateItalicsText} from '../utils/mdast';
+import {escapeRegExp} from '../utils/regex';
 
-class SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbersOptions implements Options {}
+class SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbersOptions implements Options {
+  englishNonLetterCharactersAfterCJKCharacters?: string = `-+'"([¥$`;
+  englishNonLetterCharactersBeforeCJKCharacters?: string = `-+;:'"°%$)]`;
+}
 
 @RuleBuilder.register
 export default class SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbers extends RuleBuilder<SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbersOptions> {
@@ -23,8 +27,8 @@ export default class SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbers exte
       text: string,
       options: SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbersOptions,
   ): string {
-    const head = /(\p{sc=Han}|\p{sc=Katakana}|\p{sc=Hiragana}|\p{sc=Hangul})( *)(\[[^[]*\]\(.*\)|`[^`]*`|\w+|[-+'"([¥$]|\*[^*])/gmu;
-    const tail = /(\[[^[]*\]\(.*\)|`[^`]*`|\w+|[-+;:'"°%$)\]]|[^*]\*)( *)(\p{sc=Han}|\p{sc=Katakana}|\p{sc=Hiragana}|\p{sc=Hangul})/gmu;
+    const head = this.buildHeadRegex(options.englishNonLetterCharactersAfterCJKCharacters);
+    const tail = this.buildTailRegex(options.englishNonLetterCharactersBeforeCJKCharacters);
     // inline math, inline code, markdown links, and wiki links are an exception in that even though they are to be ignored we want to keep a space around these types when surrounded by CJK characters
     const regexEscapedIgnoreExceptionPlaceHolders = `${IgnoreTypes.link.placeholder}|${IgnoreTypes.inlineMath.placeholder}|${IgnoreTypes.inlineCode.placeholder}|${IgnoreTypes.wikiLink.placeholder}`.replaceAll('{', '\\{').replaceAll('}', '\\}');
     const ignoreExceptionsHead = new RegExp(`(\\p{sc=Han}|\\p{sc=Katakana}|\\p{sc=Hiragana}|\\p{sc=Hangul})( *)(${regexEscapedIgnoreExceptionPlaceHolders})`, 'gmu');
@@ -43,6 +47,32 @@ export default class SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbers exte
 
     return newText;
   }
+  buildHeadRegex(englishPunctuationAndSymbols: string): RegExp {
+    if (englishPunctuationAndSymbols && englishPunctuationAndSymbols !== '') {
+      // strip all whitespace
+      englishPunctuationAndSymbols =englishPunctuationAndSymbols.replaceAll(/\s/g, '');
+    }
+
+    let puncAndSymbolGroup = '';
+    if (englishPunctuationAndSymbols && englishPunctuationAndSymbols.length != 0) {
+      puncAndSymbolGroup = `|[${escapeRegExp(englishPunctuationAndSymbols)}]`;
+    }
+
+    return new RegExp(`(\\p{sc=Han}|\\p{sc=Katakana}|\\p{sc=Hiragana}|\\p{sc=Hangul})( *)(\\[[^[]*\\]\\(.*\\)|\`[^\`]*\`|\\w+${puncAndSymbolGroup}|\\*[^*])`, 'gmu');
+  }
+  buildTailRegex(englishPunctuationAndSymbols: string): RegExp {
+    if (englishPunctuationAndSymbols && englishPunctuationAndSymbols !== '') {
+      // strip all whitespace
+      englishPunctuationAndSymbols =englishPunctuationAndSymbols.replaceAll(/\s/g, '');
+    }
+
+    let puncAndSymbolGroup = '';
+    if (englishPunctuationAndSymbols && englishPunctuationAndSymbols.length != 0) {
+      puncAndSymbolGroup = `|[${escapeRegExp(englishPunctuationAndSymbols)}]`;
+    }
+
+    return new RegExp(`(\\[[^[]*\\]\\(.*\\)|\`[^\`]*\`|\\w+${puncAndSymbolGroup}|[^*]\\*)( *)(\\p{sc=Han}|\\p{sc=Katakana}|\\p{sc=Hiragana}|\\p{sc=Hangul})`, 'gmu');
+  }
   get exampleBuilders(): ExampleBuilder<SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbersOptions>[] {
     return [
       new ExampleBuilder({
@@ -139,6 +169,19 @@ export default class SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbers exte
     ];
   }
   get optionBuilders(): OptionBuilderBase<SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbersOptions>[] {
-    return [];
+    return [
+      new TextOptionBuilder({
+        OptionsClass: SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbersOptions,
+        nameKey: 'rules.space-between-chinese-japanese-or-korean-and-english-or-numbers.english-symbols-punctuation-before.name',
+        descriptionKey: 'rules.space-between-chinese-japanese-or-korean-and-english-or-numbers.english-symbols-punctuation-before.description',
+        optionsKey: 'englishNonLetterCharactersBeforeCJKCharacters',
+      }),
+      new TextOptionBuilder({
+        OptionsClass: SpaceBetweenChineseJapaneseOrKoreanAndEnglishOrNumbersOptions,
+        nameKey: 'rules.space-between-chinese-japanese-or-korean-and-english-or-numbers.english-symbols-punctuation-after.name',
+        descriptionKey: 'rules.space-between-chinese-japanese-or-korean-and-english-or-numbers.english-symbols-punctuation-after.description',
+        optionsKey: 'englishNonLetterCharactersAfterCJKCharacters',
+      }),
+    ];
   }
 }
diff --git a/src/rules/two-spaces-between-lines-with-content.ts b/src/rules/two-spaces-between-lines-with-content.ts
index c46df11..b240d8f 100644
--- a/src/rules/two-spaces-between-lines-with-content.ts
+++ b/src/rules/two-spaces-between-lines-with-content.ts
@@ -1,12 +1,10 @@
 import {Options, RuleType} from '../rules';
-import RuleBuilder, {DropdownOptionBuilder, ExampleBuilder, OptionBuilderBase} from './rule-builder';
+import RuleBuilder, {ExampleBuilder, OptionBuilderBase} from './rule-builder';
 import dedent from 'ts-dedent';
 import {IgnoreTypes} from '../utils/ignore-types';
-import {LineBreakIndicators, addTwoSpacesAtEndOfLinesFollowedByAnotherLineOfTextContent} from '../utils/mdast';
+import {addTwoSpacesAtEndOfLinesFollowedByAnotherLineOfTextContent} from '../utils/mdast';
 
-class TwoSpacesBetweenLinesWithContentOptions implements Options {
-  lineBreakIndicator?: LineBreakIndicators = LineBreakIndicators.TwoSpaces;
-}
+class TwoSpacesBetweenLinesWithContentOptions implements Options {}
 
 @RuleBuilder.register
 export default class TwoSpacesBetweenLinesWithContent extends RuleBuilder<TwoSpacesBetweenLinesWithContentOptions> {
@@ -22,12 +20,12 @@ export default class TwoSpacesBetweenLinesWithContent extends RuleBuilder<TwoSpa
     return TwoSpacesBetweenLinesWithContentOptions;
   }
   apply(text: string, options: TwoSpacesBetweenLinesWithContentOptions): string {
-    return addTwoSpacesAtEndOfLinesFollowedByAnotherLineOfTextContent(text, options.lineBreakIndicator);
+    return addTwoSpacesAtEndOfLinesFollowedByAnotherLineOfTextContent(text);
   }
   get exampleBuilders(): ExampleBuilder<TwoSpacesBetweenLinesWithContentOptions>[] {
     return [
       new ExampleBuilder({
-        description: 'Make sure two spaces are added to the ends of lines that have content on it and the next line for lists, blockquotes, and paragraphs when the line break indicator is `  `',
+        description: 'Make sure two spaces are added to the ends of lines that have content on it and the next line for lists, blockquotes, and paragraphs',
         before: dedent`
           # Heading 1
           First paragraph stays as the first paragraph
@@ -48,7 +46,7 @@ export default class TwoSpacesBetweenLinesWithContent extends RuleBuilder<TwoSpa
           ${''}
           Paragraph lines that end in <br/>
           Or lines that end in <br>
-          Are left swapped
+          Are left alone
           Since they mean the same thing
           ${''}
           \`\`\` text
@@ -86,9 +84,9 @@ export default class TwoSpacesBetweenLinesWithContent extends RuleBuilder<TwoSpa
           Continuation *of* the paragraph has \`inline code block\` __in it__.  ${''}
           Even more continuation
           ${''}
-          Paragraph lines that end in  ${''}
-          Or lines that end in  ${''}
-          Are left swapped  ${''}
+          Paragraph lines that end in <br/>
+          Or lines that end in <br>
+          Are left alone  ${''}
           Since they mean the same thing
           ${''}
           \`\`\` text
@@ -108,38 +106,10 @@ export default class TwoSpacesBetweenLinesWithContent extends RuleBuilder<TwoSpa
           Even more content here
           ${''}
         `,
-        options: {
-          lineBreakIndicator: LineBreakIndicators.TwoSpaces,
-        },
       }),
     ];
   }
   get optionBuilders(): OptionBuilderBase<TwoSpacesBetweenLinesWithContentOptions>[] {
-    return [
-      new DropdownOptionBuilder<TwoSpacesBetweenLinesWithContentOptions, LineBreakIndicators>({
-        OptionsClass: TwoSpacesBetweenLinesWithContentOptions,
-        nameKey: 'rules.two-spaces-between-lines-with-content.line-break-indicator.name',
-        descriptionKey: 'rules.two-spaces-between-lines-with-content.line-break-indicator.description',
-        optionsKey: 'lineBreakIndicator',
-        records: [
-          {
-            value: LineBreakIndicators.TwoSpaces,
-            description: LineBreakIndicators.TwoSpaces,
-          },
-          {
-            value: LineBreakIndicators.LineBreakHtml,
-            description: LineBreakIndicators.LineBreakHtml,
-          },
-          {
-            value: LineBreakIndicators.LineBreakHtmlNotXml,
-            description: LineBreakIndicators.LineBreakHtmlNotXml,
-          },
-          {
-            value: LineBreakIndicators.Backslash,
-            description: LineBreakIndicators.Backslash,
-          },
-        ],
-      }),
-    ];
+    return [];
   }
 }
diff --git a/src/utils/mdast.ts b/src/utils/mdast.ts
index fe742e4..0b3e216 100644
--- a/src/utils/mdast.ts
+++ b/src/utils/mdast.ts
@@ -53,13 +53,6 @@ export enum UnorderedListItemStyles {
   Consistent = 'consistent',
 }
 
-export enum LineBreakIndicators {
-  TwoSpaces = '  ',
-  LineBreakHtmlNotXml = '<br>',
-  LineBreakHtml = '<br/>',
-  Backslash = '\\',
-}
-
 function parseTextToAST(text: string): Root {
   const textHash = hashString53Bit(text);
   if (LRU.has(textHash)) {
@@ -367,10 +360,9 @@ export function makeEmphasisOrBoldConsistent(text: string, style: string, type:
 /**
    * Makes sure that blockquotes, paragraphs, and list items have two spaces at the end of them if the following line continues its content.
    * @param {string} text The text to make sure that the two spaces are added to if there are consecutive lines of content
-   * @param {LineBreakIndicators} indicator The indicator to use for the lines that do not already use a blank line indicator
    * @return {string} The text with two spaces at the end of lines of paragraphs, list items, and blockquotes where there were consecutive lines of content.
    */
-export function addTwoSpacesAtEndOfLinesFollowedByAnotherLineOfTextContent(text: string, indicator: LineBreakIndicators): string {
+export function addTwoSpacesAtEndOfLinesFollowedByAnotherLineOfTextContent(text: string): string {
   const positions: Position[] = getPositions(MDAstTypes.Paragraph, text);
   if (positions.length === 0) {
     return text;
@@ -385,12 +377,13 @@ export function addTwoSpacesAtEndOfLinesFollowedByAnotherLineOfTextContent(text:
     }
 
     for (let i = 0; i < lastLineIndex; i++) {
-      const paragraphLine = paragraphLines[i];
+      const paragraphLine = paragraphLines[i].trimEnd();
 
-      if (lineEndsInLineBreak(paragraphLine, indicator)) {
+      // skip lines that end in <br> or <br/> as it is the same as two spaces in Markdown
+      if (paragraphLine.endsWith('<br>') || paragraphLine.endsWith('<br/>')) {
         continue;
       }
-      paragraphLines[i] = addOrReplaceLineEnding(paragraphLine, indicator);
+      paragraphLines[i] = paragraphLine + '  ';
     }
 
     text = replaceTextBetweenStartAndEndWithNewValue(text, position.start.offset, position.end.offset, paragraphLines.join('\n'));
@@ -399,48 +392,6 @@ export function addTwoSpacesAtEndOfLinesFollowedByAnotherLineOfTextContent(text:
   return text;
 }
 
-function lineEndsInLineBreak(paragraphLine: string, indicator: LineBreakIndicators): boolean {
-  if (paragraphLine.endsWith('<br>') && indicator == LineBreakIndicators.LineBreakHtmlNotXml) {
-    return true;
-  }
-
-  if (paragraphLine.endsWith('<br/>') && indicator == LineBreakIndicators.LineBreakHtml) {
-    return true;
-  }
-
-  if (paragraphLine.endsWith('  ') && indicator == LineBreakIndicators.TwoSpaces) {
-    return true;
-  }
-
-  if (!paragraphLine.endsWith('\\\\') && paragraphLine.endsWith('\\') && indicator == LineBreakIndicators.Backslash) {
-    return true;
-  }
-
-  return false;
-}
-
-function addOrReplaceLineEnding(paragraphLine: string, indicator: LineBreakIndicators): string {
-  paragraphLine = paragraphLine.trimEnd();
-  let numCharsToRemove = 0;
-  if (paragraphLine.endsWith('<br>')) {
-    numCharsToRemove = 4;
-  }
-
-  if (paragraphLine.endsWith('<br/>')) {
-    numCharsToRemove = 5;
-  }
-
-  if (!paragraphLine.endsWith('\\\\') && paragraphLine.endsWith('\\')) {
-    numCharsToRemove = 1;
-  }
-
-  if (numCharsToRemove) {
-    paragraphLine = paragraphLine.substring(0, paragraphLine.length - numCharsToRemove);
-  }
-
-  return paragraphLine.trimEnd() + indicator;
-}
-
 /**
  * Makes sure that paragraphs have a single new line before and after them.
  * @param {string} text The text to make sure that paragraphs have only 1 new line before and after them
@@ -486,8 +437,8 @@ export function makeSureThereIsOnlyOneBlankLineBeforeAndAfterParagraphs(text: st
         newParagraphLines.push(paragraphLine);
       }
 
-      // make sure that lines that end in \, <br>, <br/>, or two or more spaces are in the same paragraph
-      nextLineIsSameParagraph = paragraphLine.endsWith(LineBreakIndicators.LineBreakHtmlNotXml) || paragraphLine.endsWith(LineBreakIndicators.LineBreakHtml) || paragraphLine.endsWith(LineBreakIndicators.TwoSpaces) || (!paragraphLine.endsWith('\\\\') && paragraphLine.endsWith(LineBreakIndicators.Backslash));
+      // make sure that lines that end in <br>, <br/>, or two or more spaces are in the same paragraph
+      nextLineIsSameParagraph = paragraphLine.endsWith('<br>') || paragraphLine.endsWith('<br/>') || paragraphLine.endsWith('  ');
     }
 
     // remove new lines prior to paragraph


Test patch:
diff --git a/__tests__/paragraph-blank-lines.test.ts b/__tests__/paragraph-blank-lines.test.ts
index c95f25d..26cf16f 100644
--- a/__tests__/paragraph-blank-lines.test.ts
+++ b/__tests__/paragraph-blank-lines.test.ts
@@ -164,7 +164,6 @@ ruleTest({
         paragraph line 1 <br>
         paragraph line 2  ${''}
         paragraph line 3 <br/>
-        paragraph line 4 \\
         paragraph final line
         ${''}
         ${''}
@@ -175,7 +174,6 @@ ruleTest({
         paragraph line 1 <br>
         paragraph line 2  ${''}
         paragraph line 3 <br/>
-        paragraph line 4 \\
         paragraph final line
         ${''}
       `,
diff --git a/__tests__/space-between-chinese-japanese-or-korean-and-english-or-numbers.test.ts b/__tests__/space-between-chinese-japanese-or-korean-and-english-or-numbers.test.ts
index 7cc5a5a..f4ccf95 100644
--- a/__tests__/space-between-chinese-japanese-or-korean-and-english-or-numbers.test.ts
+++ b/__tests__/space-between-chinese-japanese-or-korean-and-english-or-numbers.test.ts
@@ -122,5 +122,33 @@ ruleTest({
         ![[流浪地球-1.webp|image title|600]]
       `,
     },
+    { // accounts for https://github.com/platers/obsidian-linter/issues/1036
+      testName: 'A dash can be removed from the characters to add space around for before and after CJK characters.',
+      before: dedent`
+        你好-世界
+      `,
+      after: dedent`
+        你好-世界
+      `,
+      options: {
+        englishNonLetterCharactersAfterCJKCharacters: `+'"([¥$`,
+        englishNonLetterCharactersBeforeCJKCharacters: `+;:'"°%$)]`,
+      },
+    },
+    {
+      testName: 'Make sure that whitespace is removed from the value of punctuation or symbols and that an empty value does not cause issues',
+      before: dedent`
+        你好\t\t世界
+        this测试-还
+      `,
+      after: dedent`
+        你好\t\t世界
+        this 测试-还
+      `,
+      options: {
+        englishNonLetterCharactersAfterCJKCharacters: ``,
+        englishNonLetterCharactersBeforeCJKCharacters: ` \t`,
+      },
+    },
   ],
 });
diff --git a/__tests__/two-spaces-between-lines-with-content.test.ts b/__tests__/two-spaces-between-lines-with-content.test.ts
index 02f23fb..ab79f47 100644
--- a/__tests__/two-spaces-between-lines-with-content.test.ts
+++ b/__tests__/two-spaces-between-lines-with-content.test.ts
@@ -1,7 +1,6 @@
 import TwoSpacesBetweenLinesWithContent from '../src/rules/two-spaces-between-lines-with-content';
 import dedent from 'ts-dedent';
 import {ruleTest} from './common';
-import {LineBreakIndicators} from '../src/utils/mdast';
 
 ruleTest({
   RuleBuilderClass: TwoSpacesBetweenLinesWithContent,
@@ -87,85 +86,5 @@ ruleTest({
         %%
       `,
     },
-    {
-      testName: 'Make sure that using a line break indicator of `<br>` replaces the other line break endings properly',
-      before: dedent`
-        Here is some text${'  '}
-        Here is some more text\\
-        Here is yet some more text<br>
-        Even more text<br/>
-        Once more...
-      `,
-      after: dedent`
-        Here is some text<br>
-        Here is some more text<br>
-        Here is yet some more text<br>
-        Even more text<br>
-        Once more...
-      `,
-      options: {
-        lineBreakIndicator: LineBreakIndicators.LineBreakHtmlNotXml,
-      },
-    },
-    {
-      testName: 'Make sure that using a line break indicator of `<br/>` replaces the other line break endings properly',
-      before: dedent`
-        Here is some text${'  '}
-        Here is some more text\\
-        Here is yet some more text<br>
-        Even more text<br/>
-        Once more...
-      `,
-      after: dedent`
-        Here is some text<br/>
-        Here is some more text<br/>
-        Here is yet some more text<br/>
-        Even more text<br/>
-        Once more...
-      `,
-      options: {
-        lineBreakIndicator: LineBreakIndicators.LineBreakHtml,
-      },
-    },
-    {
-      testName: 'Make sure that using a line break indicator of `\\` replaces the other line break endings properly',
-      before: dedent`
-        Here is some text${'  '}
-        Here is some more text\\
-        Here is yet some more text<br>
-        Even more text<br/>
-        Once more...
-      `,
-      after: dedent`
-        Here is some text\\
-        Here is some more text\\
-        Here is yet some more text\\
-        Even more text\\
-        Once more...
-      `,
-      options: {
-        lineBreakIndicator: LineBreakIndicators.Backslash,
-      },
-    },
-    {
-      testName: 'Make sure that using a line break indicator of `  ` replaces the other line break endings properly',
-      before: dedent`
-        Here is some text${'  '}
-        Here is some more text\\
-        Here is yet some more text<br>
-        Even more text<br/>
-        Once more...
-      `,
-      after: dedent`
-        Here is some text${'  '}
-        Here is some more text${'  '}
-        Here is yet some more text${'  '}
-        Even more text${'  '}
-        Once more...
-      `,
-      options: {
-        lineBreakIndicator: LineBreakIndicators.TwoSpaces,
-      },
-    },
   ],
 });