Skip to content

feat: polish session list & redesign settings UI#5

Merged
endo-ly merged 7 commits intomainfrom
feat/session-list-ui-polish
Apr 4, 2026
Merged

feat: polish session list & redesign settings UI#5
endo-ly merged 7 commits intomainfrom
feat/session-list-ui-polish

Conversation

@endo-ly
Copy link
Copy Markdown
Owner

@endo-ly endo-ly commented Apr 4, 2026

Summary

  • Redesign session list header with terminal icon, ghost buttons, and monospace typography
  • Add folder badge and layout improvements to session cards
  • Add relative time formatting (e.g. "5m ago") for session last activity
  • Redesign gateway settings screen with terminal-themed card UI matching the session list
    • Card-based sections with surfaceContainer background and Teal accents
    • Pill badge theme selector replacing RadioButton
    • Ghost-style outlined save button with "SAVE" → "SAVED" feedback
    • Reset to "SAVE" when URL or Token is modified after saving

Test plan

  • ./gradlew :shared:testDebugUnitTest — all tests pass
  • ./gradlew ktlintCheck — no violations
  • ./gradlew detekt — no issues
  • ./gradlew :androidApp:installDebug — visual verification on device

🤖 Generated with Claude Code

Summary by CodeRabbit

リリースノート

  • New Features

    • タイムスタンプを相対時間形式(「5分前」「3時間前」など)で表示するよう改善
    • ゲートウェイ設定画面にテーマ選択機能を追加
    • 設定保存の成功状態をUIで視覚的にフィードバック
  • Refactor

    • ターミナルセッションリストのヘッダーとセッション詳細表示をリデザイン
    • ゲートウェイ設定画面のレイアウトとコンポーネント構成を改善

endo-ly and others added 6 commits April 4, 2026 12:34
Display timestamps as relative time strings (e.g. "just now", "5m ago",
"3h ago", "2d ago") instead of absolute "MM/DD HH:MM" format. Falls back
to compact date for timestamps older than 30 days.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Replace OutlinedButton with IconButton (ghost style, no borders)
- Replace green dot indicator with Canvas-drawn terminal icon (>_ prompt)
- Change title from "TERMINAL SESSIONS" to "SESSIONS" (titleMedium Bold)
- Move "X Active" count from right-aligned to left side below title
- Enlarge icon button touch target from 28dp to 48dp
- Fix dark theme ripple visibility via CompositionLocalProvider
- Add monospaceTitleLarge typography extension

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Replace absolute timestamp with relative time (toRelativeTimeString)
- Add FolderBadge component showing only last directory name as pill
- Swap layout: folder badge (left) + tmux title (right-aligned)
- Use surfaceContainerHigh for badge background (works in both themes)
- Simplify header row layout by removing nested Box wrappers

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Replace standard Material3 form (Scaffold+TopAppBar+RadioButton+Button)
with terminal-aesthetic card layout matching the session list screen:
card-based sections, pill theme selector, ghost save button, monospace
typography, and Teal accents throughout.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Show "SAVED" on button after successful save, stay on screen
- Reset to "SAVE" when URL or Token field is modified
- Remove unused import in SessionListItem

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Remove unused imports and apply ktlint formatting fixes.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 4, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: dc8f269d-d7d9-48bd-86fc-7dbffa207023

📥 Commits

Reviewing files that changed from the base of the PR and between d62f2a3 and 74b36d8.

📒 Files selected for processing (1)
  • frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreen.kt
✅ Files skipped from review due to trivial changes (1)
  • frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreen.kt

Walkthrough

相対時間表示機能を追加し、ターミナルセッション画面のUIを大幅リデザイン。ヘッダーインジケータ、ボタンスタイル、フォルダパス表示を更新。ゲートウェイ設定画面はカード型レイアウトに変更し、保存成功状態の管理を追加。テスト一式も新規追加。

Changes

Cohort / File(s) Summary
相対時間表示機能
DateTimeText.kt, DateTimeTextTest.kt
ISO-8601タイムスタンプを相対時間文字列に変換する新しいメソッド追加(「just now」「Xm ago」「Xd ago」など)。パース失敗時は元の文字列を返す。テストで各時間帯のフォーマット検証。
セッションリスト画面UI更新
SessionList.kt, SessionListItem.kt
カスタムターミナルインジケータアイコンの追加、ヘッダーテキスト削減、ボタンスタイル変更。最後のアクティビティに相対時間表示を適用。フォルダバッジ新規追加で経路表示を改善。
ゲートウェイ設定画面リデザイン
GatewaySettingsScreen.kt, GatewaySettingsState.kt, GatewaySettingsScreenModel.kt
カスタムヘッダ導入、カード型レイアウト採用、テーマ選択をピル型に変更。保存成功状態フィールド追加し、UI側で成功フィードバック表示。入力変更時に成功状態を自動リセット。

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Poem

ウサギが彩る相対時刻 ✨
ターミナルはもっと美しく
カードに包まれ設定画面
セッションたちが新しい顔で踊る
コードの庭園、季節が変わったね 🌸

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 40.74% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed タイトルは「feat: polish session list & redesign settings UI」で、セッションリストのポーランドと設定UIの再設計という主要な変更を正確に要約している。

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/session-list-ui-polish

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🧹 Nitpick comments (9)
frontend/shared/src/commonTest/kotlin/dev/plexus/shared/core/ui/common/DateTimeTextTest.kt (1)

63-71: 未来のタイムスタンプに対するテストケースが欲しいな〜

now より未来のタイムスタンプが渡された場合のテストがないよ!elapsed がマイナスになるケースだね。現在の実装だと elapsed < 60.seconds は負の値でも true になるから "just now" が返されるけど、それが期待する挙動かどうか確認しておくといいかも 🐰

🧪 未来のタイムスタンプ用のテスト例
`@Test`
fun `toRelativeTimeString handles future timestamp`() {
    val now = Instant.parse("2026-04-04T12:00:00Z")
    val input = "2026-04-04T12:05:00Z" // 5分後

    val result = input.toRelativeTimeString(now)

    // 期待される挙動を明確にする
    assertEquals("just now", result) // または別の期待値
}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@frontend/shared/src/commonTest/kotlin/dev/plexus/shared/core/ui/common/DateTimeTextTest.kt`
around lines 63 - 71, Add a test for future timestamps in DateTimeTextTest.kt:
create a fixed now Instant and an input string later than now, call
input.toRelativeTimeString(now) in a new test named `toRelativeTimeString
handles future timestamp`, and assert the expected result (e.g., "just now" or
another agreed value) so the behavior when elapsed is negative is explicit for
the toRelativeTimeString function.
frontend/shared/src/commonMain/kotlin/dev/plexus/shared/core/ui/common/DateTimeText.kt (1)

27-39: 未来のタイムスタンプだと "just now" になっちゃうよ

elapsed が負の値(未来の日時)のとき、elapsed < 60.seconds が true になるから "just now" が返される。これが意図した挙動ならOKだけど、明示的にハンドリングしておくと後で困らないと思うな 🐇

💡 未来のタイムスタンプを明示的に処理する案
 `@OptIn`(ExperimentalTime::class)
 internal fun String.toRelativeTimeString(now: Instant): String =
     runCatching {
         val eventTime = Instant.parse(this)
         val elapsed = now - eventTime

         when {
+            elapsed.isNegative() -> "just now" // または this.toCompactIsoDateTime()
             elapsed < 60.seconds -> "just now"
             elapsed < 60.minutes -> "${elapsed.inWholeMinutes}m ago"
             elapsed < 24.hours -> "${elapsed.inWholeHours}h ago"
             elapsed < 30.days -> "${elapsed.inWholeDays}d ago"
             else -> this.toCompactIsoDateTime()
         }
     }.getOrElse { this }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/core/ui/common/DateTimeText.kt`
around lines 27 - 39, The function String.toRelativeTimeString currently treats
future timestamps as "just now" because elapsed is negative; update the logic in
String.toRelativeTimeString (after parsing Instant.parse(this) and computing
elapsed) to explicitly handle future times by checking if elapsed.isNegative (or
elapsed < Duration.ZERO) and return a clear representation (e.g.,
this.toCompactIsoDateTime() or another chosen future-format) before the when
block so future timestamps are not classified as "just now".
frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/agentlist/components/SessionListItem.kt (1)

237-238: lastPathSegment() の空文字列ケースはどうなる?

空文字列や "/" だけが渡されると、trimEnd('/') の後に空文字列になって、substringAfterLast も空文字列を返しちゃう。FolderBadge が空文字列で表示されることになるけど、UI的には大丈夫かな? 🤔

呼び出し元の sessionHeaderPath が空文字チェック(takeUnless { it.isBlank() })してるから実際は問題ないと思うけど、防御的に書くならこんな感じ:

🛡️ 防御的なバージョン
-private fun String.lastPathSegment(): String = trimEnd('/').substringAfterLast('/', this)
+private fun String.lastPathSegment(): String = trimEnd('/').substringAfterLast('/').ifEmpty { this }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/agentlist/components/SessionListItem.kt`
around lines 237 - 238, The extension function lastPathSegment() can return an
empty string for inputs like "" or "/", causing FolderBadge to render blank;
update lastPathSegment() to defensively handle empty/root inputs by trimming and
computing the segment but returning a sensible default (e.g. "/" or "root") when
the computed segment.isBlank(); reference the function name lastPathSegment(),
the caller sessionHeaderPath and the consumer FolderBadge so you ensure the
default choice aligns with UI expectations.
frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/agentlist/components/SessionList.kt (1)

219-251: Canvas 描画、ターミナルっぽくていい雰囲気!

角丸の矩形に >_ プロンプトを描くのはクリエイティブでいいね!ただ、マジックナンバーがたくさんあって後で調整するとき大変かも 🐇

🎨 マジックナンバーを定数化する案(お好みで)
 `@Composable`
 private fun TerminalIndicatorIcon(
     tint: Color,
     modifier: Modifier = Modifier,
 ) {
     Canvas(modifier = modifier) {
         val strokeWidth = 1.4.dp.toPx()
-        val pad = size.width * 0.06f
-        val w = size.width - pad * 2
-        val h = size.height * 0.72f
+        val paddingRatio = 0.06f
+        val heightRatio = 0.72f
+        val pad = size.width * paddingRatio
+        val w = size.width - pad * 2
+        val h = size.height * heightRatio
         val tl = Offset(pad, (size.height - h) / 2)

         // ... 以下同様に chevronStartX, chevronMidX などの名前をつける
     }
 }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/agentlist/components/SessionList.kt`
around lines 219 - 251, The Canvas drawing in SessionList.kt uses many magic
numbers (e.g., 0.06f, 0.72f, 0.2f, 0.4f, 0.28f, 0.50f, 0.72f, 0.52f, 0.78f,
1.4.dp) making tweaks error-prone; replace these literals with named local
constants (for example: STROKE_WIDTH_DP, PADDING_RATIO, HEIGHT_RATIO,
CHEVRON_LEFT_RATIO, CHEVRON_MID_RATIO, CHEVRON_TOP_RATIO, CHEVRON_MIDY_RATIO,
CHEVRON_BOTTOM_RATIO, CURSOR_START_RATIO, CURSOR_END_RATIO) inside the Canvas
lambda and use those constants when computing strokeWidth, pad, w, h, tl, cx,
mx, ty, my, by and the cursor drawLine calls so the intent is clear and values
are easy to adjust.
frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreen.kt (3)

342-353: アクセシビリティのために role を指定したほうがいいかも

clickablerole パラメータがないから、スクリーンリーダーがこれをインタラクティブな要素として正しく認識できないかもしれないよ。選択可能なピルコンポーネントだから、Role.Button を追加するとアクセシビリティが向上するね。

♿ 修正案
+import androidx.compose.ui.semantics.Role

     Box(
         modifier =
             Modifier
                 .clip(shapes.radiusMd)
                 .background(backgroundColor)
                 .border(
                     width = dimens.borderWidthThin,
                     color = borderColor,
                     shape = shapes.radiusMd,
-                ).clickable(onClick = onClick)
+                ).clickable(role = Role.Button, onClick = onClick)
                 .padding(horizontal = dimens.space20, vertical = dimens.space10),
         contentAlignment = Alignment.Center,
     )
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreen.kt`
around lines 342 - 353, The Box's interactive Modifier uses .clickable(onClick =
onClick) without a semantics role, so screen readers may not treat it as a
button; update the Modifier.clickable call used in GatewaySettingsScreen's Box
to pass role = Role.Button (importing androidx.compose.ui.semantics.Role) so the
component is announced as a button by accessibility services, keeping the
existing onClick handler intact.

400-408: UI 文字列が直書きされてるね

「SAVE」「SAVING...」「SAVED」などの文字列が直接コードに書かれてる。将来的にローカライズ対応するなら、文字列リソースに切り出しておくと楽になるよ。今すぐ必要じゃないけど、頭の片隅に置いておくといいかも。

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreen.kt`
around lines 400 - 408, The Text composable in GatewaySettingsScreen.kt
currently hardcodes UI strings ("SAVE", "SAVING...", "SAVED") based on
isSaveSuccess/isSaving; extract these into string resources or a localization
provider and replace the direct literals with references (e.g., use a Strings
object/getString or Compose stringResource) so the UI uses resource keys for
"save_label", "saving_label", and "saved_label" instead of inline text; update
the when branch in the Text call to return the resource-backed strings and
ensure any preview/sample usages are updated to provide the localized strings.

82-92: 背景色が二重に設定されてるよ

ScaffoldcontainerColor (line 84) と ColumnModifier.background (line 90) で同じ背景色を2回設定してる。どっちか一方で十分だから、冗長なほうを削除するとスッキリするね。

♻️ 修正案
         Scaffold(
             snackbarHost = { SnackbarHost(snackbarHostState) },
             containerColor = MaterialTheme.colorScheme.background,
         ) { paddingValues ->
             Column(
                 modifier =
                     Modifier
                         .fillMaxSize()
-                        .background(MaterialTheme.colorScheme.background)
                         .statusBarsPadding()
                         .padding(paddingValues),
             ) {
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreen.kt`
around lines 82 - 92, Scaffold の containerColor と Column の Modifier.background
で同じ背景色を二重に指定しているので冗長です;どちらか一方を削除してください。具体的には GatewaySettingsScreen 内の Scaffold の
containerColor プロパティか Column の Modifier.background
呼び出しのどちらかを残し、もう一方を削除して背景色指定を一箇所にまとめてください(参照シンボル: Scaffold, containerColor,
Column, Modifier.background)。
frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsState.kt (1)

5-19: KDoc に isSaveSuccess の説明が抜けてるよ!

他のプロパティは全部ドキュメント化されてるのに、新しく追加した isSaveSuccess だけ説明がないね。一貫性のために追加しておくといいかも。

📝 KDoc 追加の提案
 /**
  * Gateway設定画面のUI状態
  *
  * `@property` inputGatewayUrl 入力されたGateway URL
  * `@property` inputApiKey 入力されたAPI Key
  * `@property` selectedTheme 選択中のテーマ
  * `@property` isSaving 保存処理中かどうか
+ * `@property` isSaveSuccess 保存が成功したかどうか
  */
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsState.kt`
around lines 5 - 19, GatewaySettingsState の KDoc is missing a description for
the new property isSaveSuccess; update the class-level KDoc (above data class
GatewaySettingsState) to add a `@property` entry describing isSaveSuccess (e.g.,
whether the save completed successfully) so it matches the other documented
properties and keeps documentation consistent with properties inputGatewayUrl,
inputApiKey, selectedTheme, and isSaving.
frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreenModel.kt (1)

114-120: NavigateBack エフェクトが誰からも発行されてない

保存成功後に isSaveSuccess = true を設定するようになったのはいいんだけど、そのせいで GatewaySettingsEffect.NavigateBack がデッドコードになってる。定義は残ってるしハンドラーもあるけど、実際には誰も発行してないから実行されることはない。GatewaySettingsEffect.ktGatewaySettingsScreen.kt の該当部分をサッと整理しちゃおう。

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreenModel.kt`
around lines 114 - 120, 現在の保存成功ハンドリングは _state.update(... isSaveSuccess = true)
を使しているため、GatewaySettingsEffect.NavigateBack
は誰からも発行されずデッドコードになっているので、GatewaySettingsEffect.kt から NavigateBack
ケース(またはクラス/オブジェクト)を削除し、GatewaySettingsScreen.kt にあるそのハンドラー(NavigateBack
を待ってナビゲーションするロジック)も削除して、画面側では isSaveSuccess
の変更を監視してナビゲーション/閉じる処理を行うように統一してください;逆にエフェクト方式に戻したい場合は、GatewaySettingsScreenModel
の保存成功箇所(現在の _state.update(...) ブロック)で GatewaySettingsEffect.NavigateBack
を発行するコードに差し替え、不要になった isSaveSuccess
のフィールドと関連コードを削除してください(変更対象の識別子:GatewaySettingsScreenModel, _state.update(...
isSaveSuccess = true), GatewaySettingsEffect.NavigateBack, GatewaySettingsScreen
のエフェクトハンドラー)。
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/core/ui/theme/AppTypography.kt`:
- Around line 34-41: The new extension property Typography.monospaceTitleLarge
is defined but not used anywhere in the PR; either remove the unused property or
add its usage where a bold monospace large headline is intended (e.g., replace
existing calls that should use a monospace headline with
Typography.monospaceTitleLarge or reference it in the relevant
composable/theme). Locate the property named monospaceTitleLarge in
AppTypography.kt and either delete the property or update the components that
render large title text to use Typography.monospaceTitleLarge so the definition
is actually consumed.

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreen.kt`:
- Around line 383-398: OutlinedButton's visual state can differ from its actual
enabled state because enabled = enabled && !isSaving && !isSaveSuccess but
containerColor/contentColor only check the incoming enabled flag; update the
color logic in GatewaySettingsScreen's OutlinedButton (containerColor,
contentColor, and border color decisions) to use the same combined condition
(e.g., enabled && !isSaving && !isSaveSuccess) or add an explicit branch for
isSaveSuccess to render a distinct "success" style so the button's visuals
always match its interactive state (refer to OutlinedButton, the enabled
parameter, isSaving, isSaveSuccess, containerColor, contentColor, and border).

---

Nitpick comments:
In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/core/ui/common/DateTimeText.kt`:
- Around line 27-39: The function String.toRelativeTimeString currently treats
future timestamps as "just now" because elapsed is negative; update the logic in
String.toRelativeTimeString (after parsing Instant.parse(this) and computing
elapsed) to explicitly handle future times by checking if elapsed.isNegative (or
elapsed < Duration.ZERO) and return a clear representation (e.g.,
this.toCompactIsoDateTime() or another chosen future-format) before the when
block so future timestamps are not classified as "just now".

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/agentlist/components/SessionList.kt`:
- Around line 219-251: The Canvas drawing in SessionList.kt uses many magic
numbers (e.g., 0.06f, 0.72f, 0.2f, 0.4f, 0.28f, 0.50f, 0.72f, 0.52f, 0.78f,
1.4.dp) making tweaks error-prone; replace these literals with named local
constants (for example: STROKE_WIDTH_DP, PADDING_RATIO, HEIGHT_RATIO,
CHEVRON_LEFT_RATIO, CHEVRON_MID_RATIO, CHEVRON_TOP_RATIO, CHEVRON_MIDY_RATIO,
CHEVRON_BOTTOM_RATIO, CURSOR_START_RATIO, CURSOR_END_RATIO) inside the Canvas
lambda and use those constants when computing strokeWidth, pad, w, h, tl, cx,
mx, ty, my, by and the cursor drawLine calls so the intent is clear and values
are easy to adjust.

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/agentlist/components/SessionListItem.kt`:
- Around line 237-238: The extension function lastPathSegment() can return an
empty string for inputs like "" or "/", causing FolderBadge to render blank;
update lastPathSegment() to defensively handle empty/root inputs by trimming and
computing the segment but returning a sensible default (e.g. "/" or "root") when
the computed segment.isBlank(); reference the function name lastPathSegment(),
the caller sessionHeaderPath and the consumer FolderBadge so you ensure the
default choice aligns with UI expectations.

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreen.kt`:
- Around line 342-353: The Box's interactive Modifier uses .clickable(onClick =
onClick) without a semantics role, so screen readers may not treat it as a
button; update the Modifier.clickable call used in GatewaySettingsScreen's Box
to pass role = Role.Button (importing androidx.compose.ui.semantics.Role) so the
component is announced as a button by accessibility services, keeping the
existing onClick handler intact.
- Around line 400-408: The Text composable in GatewaySettingsScreen.kt currently
hardcodes UI strings ("SAVE", "SAVING...", "SAVED") based on
isSaveSuccess/isSaving; extract these into string resources or a localization
provider and replace the direct literals with references (e.g., use a Strings
object/getString or Compose stringResource) so the UI uses resource keys for
"save_label", "saving_label", and "saved_label" instead of inline text; update
the when branch in the Text call to return the resource-backed strings and
ensure any preview/sample usages are updated to provide the localized strings.
- Around line 82-92: Scaffold の containerColor と Column の Modifier.background
で同じ背景色を二重に指定しているので冗長です;どちらか一方を削除してください。具体的には GatewaySettingsScreen 内の Scaffold の
containerColor プロパティか Column の Modifier.background
呼び出しのどちらかを残し、もう一方を削除して背景色指定を一箇所にまとめてください(参照シンボル: Scaffold, containerColor,
Column, Modifier.background)。

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreenModel.kt`:
- Around line 114-120: 現在の保存成功ハンドリングは _state.update(... isSaveSuccess = true)
を使しているため、GatewaySettingsEffect.NavigateBack
は誰からも発行されずデッドコードになっているので、GatewaySettingsEffect.kt から NavigateBack
ケース(またはクラス/オブジェクト)を削除し、GatewaySettingsScreen.kt にあるそのハンドラー(NavigateBack
を待ってナビゲーションするロジック)も削除して、画面側では isSaveSuccess
の変更を監視してナビゲーション/閉じる処理を行うように統一してください;逆にエフェクト方式に戻したい場合は、GatewaySettingsScreenModel
の保存成功箇所(現在の _state.update(...) ブロック)で GatewaySettingsEffect.NavigateBack
を発行するコードに差し替え、不要になった isSaveSuccess
のフィールドと関連コードを削除してください(変更対象の識別子:GatewaySettingsScreenModel, _state.update(...
isSaveSuccess = true), GatewaySettingsEffect.NavigateBack, GatewaySettingsScreen
のエフェクトハンドラー)。

In
`@frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsState.kt`:
- Around line 5-19: GatewaySettingsState の KDoc is missing a description for the
new property isSaveSuccess; update the class-level KDoc (above data class
GatewaySettingsState) to add a `@property` entry describing isSaveSuccess (e.g.,
whether the save completed successfully) so it matches the other documented
properties and keeps documentation consistent with properties inputGatewayUrl,
inputApiKey, selectedTheme, and isSaving.

In
`@frontend/shared/src/commonTest/kotlin/dev/plexus/shared/core/ui/common/DateTimeTextTest.kt`:
- Around line 63-71: Add a test for future timestamps in DateTimeTextTest.kt:
create a fixed now Instant and an input string later than now, call
input.toRelativeTimeString(now) in a new test named `toRelativeTimeString
handles future timestamp`, and assert the expected result (e.g., "just now" or
another agreed value) so the behavior when elapsed is negative is explicit for
the toRelativeTimeString function.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 081d4c99-61a5-45e7-879b-9e7cb4c3181e

📥 Commits

Reviewing files that changed from the base of the PR and between 5635fd5 and d62f2a3.

📒 Files selected for processing (8)
  • frontend/shared/src/commonMain/kotlin/dev/plexus/shared/core/ui/common/DateTimeText.kt
  • frontend/shared/src/commonMain/kotlin/dev/plexus/shared/core/ui/theme/AppTypography.kt
  • frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/agentlist/components/SessionList.kt
  • frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/agentlist/components/SessionListItem.kt
  • frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreen.kt
  • frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsScreenModel.kt
  • frontend/shared/src/commonMain/kotlin/dev/plexus/shared/features/terminal/settings/GatewaySettingsState.kt
  • frontend/shared/src/commonTest/kotlin/dev/plexus/shared/core/ui/common/DateTimeTextTest.kt

…tton state

- Remove unused monospaceTitleLarge typography extension
- Fix button color logic to use combined enabled state (isButtonEnabled)
- Show success style (Teal) when isSaveSuccess for visual consistency

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@endo-ly
Copy link
Copy Markdown
Owner Author

endo-ly commented Apr 4, 2026

レビュー対応完了

対応したレビューコメント: 2件

対象ファイル 修正内容 ステータス
AppTypography.kt monospaceTitleLarge が未使用だったため削除 ✅ 修正済み
GatewaySettingsScreen.kt ボタンの enabled と色ロジックが不一致だった。isButtonEnabled 変数で統一し、isSaveSuccess 時は成功スタイル(Teal)を明示的に適用 ✅ 修正済み

@endo-ly endo-ly merged commit 90eff08 into main Apr 4, 2026
3 checks passed
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.

1 participant