mirror of
https://github.com/Kilo-Org/kilocode.git
synced 2026-08-30 17:14:40 +08:00
fix(jetbrains): keep auto-approve shield neutral
This commit is contained in:
+1
-7
@@ -12,7 +12,6 @@ import ai.kilocode.client.session.ui.model.ModelPicker
|
||||
import ai.kilocode.client.ui.HoverIcon
|
||||
import ai.kilocode.client.ui.RoundedContentPanel
|
||||
import ai.kilocode.client.ui.UiStyle
|
||||
import ai.kilocode.client.ui.colorizeIfPossible
|
||||
import ai.kilocode.client.ui.iconButton
|
||||
import ai.kilocode.log.ChatLogSummary
|
||||
import ai.kilocode.log.KiloLog
|
||||
@@ -299,12 +298,7 @@ class PromptPanel(
|
||||
|
||||
private fun syncAutoApprove() {
|
||||
auto.isSelected = autoApprove
|
||||
auto.icon = if (autoApprove) {
|
||||
val color = SessionUiStyle.View.Prompt.autoApproveActive()
|
||||
SHIELD_ICON.colorizeIfPossible(color, color)
|
||||
} else {
|
||||
SHIELD_ICON
|
||||
}
|
||||
auto.icon = SHIELD_ICON
|
||||
auto.toolTipText = if (autoApprove) {
|
||||
KiloBundle.message("prompt.action.autoApprove.enabled.tooltip")
|
||||
} else {
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
<svg width="16" height="16" viewBox="0 0 16 16" fill="#6C707E" xmlns="http://www.w3.org/2000/svg">
|
||||
<svg width="16" height="16" viewBox="0 0 16 16" fill="#000000" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M1.5 1.5L14.5 8L1.5 14.5V9L10 8L1.5 7V1.5Z"/>
|
||||
</svg>
|
||||
|
||||
|
Before Width: | Height: | Size: 163 B After Width: | Height: | Size: 163 B |
@@ -1,3 +1,3 @@
|
||||
<svg width="16" height="16" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||
<path d="M7.49935 9.3737L9.16602 11.0404L12.4994 7.70703M9.99935 2.08203L17.0827 4.3737V9.92565C17.0827 14.0694 13.3327 16.2487 9.99935 18.047C6.66602 16.2487 2.91602 14.0694 2.91602 9.92565V4.3737L9.99935 2.08203Z" stroke="#6C707E" stroke-linecap="square"/>
|
||||
<path d="M7.49935 9.3737L9.16602 11.0404L12.4994 7.70703M9.99935 2.08203L17.0827 4.3737V9.92565C17.0827 14.0694 13.3327 16.2487 9.99935 18.047C6.66602 16.2487 2.91602 14.0694 2.91602 9.92565V4.3737L9.99935 2.08203Z" stroke="#000000" stroke-linecap="square"/>
|
||||
</svg>
|
||||
|
||||
|
Before Width: | Height: | Size: 364 B After Width: | Height: | Size: 364 B |
+2
@@ -122,6 +122,7 @@ class PromptPanelTest : BasePlatformTestCase() {
|
||||
assertFalse(button.isSelected)
|
||||
assertEquals(KiloBundle.message("prompt.action.autoApprove.enable"), button.accessibleContext.accessibleName)
|
||||
assertEquals(KiloBundle.message("prompt.action.autoApprove.disabled.tooltip"), button.toolTipText)
|
||||
val icon = button.icon
|
||||
|
||||
button.doClick()
|
||||
|
||||
@@ -130,6 +131,7 @@ class PromptPanelTest : BasePlatformTestCase() {
|
||||
panel.setAutoApprove(true)
|
||||
|
||||
assertTrue(button.isSelected)
|
||||
assertSame(icon, button.icon)
|
||||
assertEquals(KiloBundle.message("prompt.action.autoApprove.disable"), button.accessibleContext.accessibleName)
|
||||
assertEquals(KiloBundle.message("prompt.action.autoApprove.enabled.tooltip"), button.toolTipText)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user