Skip to content

Commit

Permalink
revert: "fix(sentenceCase): preserve casing for words with non-letter…
Browse files Browse the repository at this point in the history
… characters"

This reverts commit 028a2f4.

ref: #263
  • Loading branch information
northword committed Jan 15, 2025
1 parent f4d7a44 commit 34f16f8
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions src/utils/str.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,11 +148,6 @@ export function toSentenceCase(text: string) {
return word;
}

// If the word contains any non-letter character, retain its original case
if (unmasked.match(/[^a-z]/i)) {
return word;
}

// northword patch: 支持化学元素识别
if (chemElements.includes(word)) {
return word;
Expand Down

0 comments on commit 34f16f8

Please sign in to comment.