Text Case Converter: show how identifiers are split into words

クローズ
#409 コメント 2 件 リアクション 0 件 担当者 1 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@srikar-naidu がすでに取り組んでいます。

2026年10月28日 から。

  • #418 @srikar-naidu による — マージ済み

評価

この issue はまだ評価されていません。

説明

enhancement hacktoberfest
What problem does this solve?

The Text Case Converter converts identifiers between naming conventions, but users cannot see how the input was segmented before conversion.

Inputs containing acronyms, digits, or mixed separators can have ambiguous word boundaries. Showing the detected words would help users understand results such as converting XMLHttpRequest to xml_http_request.

Proposed solution

Add a “Detected words” section below the input, showing the word segments used by the existing case-conversion logic.

Scope
  • Reuse the existing word-splitting logic so the displayed segments match the conversion results.
  • Display each segment as a readable token, preserving its original casing.
  • Handle camelCase, PascalCase, acronyms, and supported separators.
  • For multi-line input, show detected words separately for each non-empty line, labeled with its original line number.
  • Explain that acronym and digit boundaries follow the converter’s existing rules.
  • Show a helpful empty state when the input contains no detected words.
  • Keep existing conversion behavior unchanged.
Acceptance criteria
  • XMLHttpRequest displays XML, Http, and Request.
  • user_id displays user and id.
  • HTTP_status_code displays HTTP, status, and code.
  • Digit boundaries match the existing conversion behavior and are covered by tests.
  • Repeated separators and surrounding whitespace do not create empty tokens.
  • Unicode input follows the same rules as the existing converter.
  • The detected words update as the input changes.
  • Multi-line results preserve the association with their source lines.
  • Tokens remain readable in both site themes and are accessible to screen readers.
  • Word segmentation lives in lib/ with tests covering acronyms, digits, separators, Unicode, and multi-line input.
  • All processing happens locally in the browser.
  • npm run lint && npm run test && npm run build pass.

Custom splitting rules, editable tokens, and changes to existing conversion algorithms are outside this issue’s scope.

Fit
  • This can work entirely in the browser with no server or data leaving the tab.
主要言語
TypeScript
スター
1
フォーク
9
平均マージ
7時間 3分
マージ済み PR(30日)
199

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

codercops/toolbelt のほかの issue

codercops/toolbelt の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。