Skip to content
This repository was archived by the owner on Nov 4, 2024. It is now read-only.

Commit f8c20fe

Browse files
committed
feat(settings): add resizable column to AppSettingsConfigurable.kt
Added a resizable column to the AppSettingsConfigurable.kt file to improve UI/UX.
1 parent 67e4f0d commit f8c20fe

2 files changed

Lines changed: 5 additions & 6 deletions

File tree

src/main/kotlin/com/github/blarc/ai/commits/intellij/plugin/settings/AppSettings.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class AppSettings : PersistentStateComponent<AppSettings> {
2222
private val openAITokenTitle = "OpenAIToken"
2323
private val openAIPromptTitle = "OpenAIPrompt"
2424

25-
private var defaultPrompt = "As a professional developer working with a Git repository, it's important to maintain clear and concise commit messages that follow the standard format. Please create a commit message for the following changes: {diffs}. Remember to label everything logically and keep it short. Please use the following format <type>(<scope>): <short> /n/n [...]'. Thank you very much!" // And here's a helpful hint to remember: {hint}.
25+
private var defaultPrompt = "As a professional developer working with a Git repository, it's important to maintain clear and concise commit messages that follow the standard format. Please create a commit message for the following changes: {diffs}. Remember to label everything logically and keep it short. Please use the following format <type>(<scope>): <short> \n\n [...]'. Thank you very much!" // And here's a helpful hint to remember: {hint}.
2626

2727
var requestSupport = true
2828

src/main/kotlin/com/github/blarc/ai/commits/intellij/plugin/settings/AppSettingsConfigurable.kt

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ class AppSettingsConfigurable : BoundConfigurable(message("settings.general.grou
5353
{ AppSettings.instance.savePrompt(it) }
5454
)
5555
.align(Align.FILL)
56+
.resizableColumn()
5657
}
5758
}
5859

@@ -72,12 +73,10 @@ class AppSettingsConfigurable : BoundConfigurable(message("settings.general.grou
7273
OpenAIService.instance.verifyToken(String(tokenPasswordField.password))
7374
verifyLabel.text = message("settings.verify.valid")
7475
verifyLabel.icon = AllIcons.General.InspectionsOK
75-
}
76-
catch (e: OpenAIAPIException) {
76+
} catch (e: OpenAIAPIException) {
7777
verifyLabel.text = message("settings.verify.invalid", e.statusCode)
7878
verifyLabel.icon = AllIcons.General.InspectionsError
79-
}
80-
catch (e: Exception) {
79+
} catch (e: Exception) {
8180
verifyLabel.text = message("settings.verify.invalid", "Unknown")
8281
verifyLabel.icon = AllIcons.General.InspectionsError
8382
}
@@ -86,4 +85,4 @@ class AppSettingsConfigurable : BoundConfigurable(message("settings.general.grou
8685
}
8786

8887
}
89-
}
88+
}

0 commit comments

Comments
 (0)