@@ -2,16 +2,17 @@ package RuleDialog
2
2
3
3
import (
4
4
"fmt"
5
- "github.com/charmbracelet/bubbles/list"
6
- "github.com/charmbracelet/bubbles/textinput"
7
- tea "github.com/charmbracelet/bubbletea"
8
- "github.com/charmbracelet/lipgloss"
9
- "github.com/redis/go-redis/v9"
10
5
"io"
11
6
"smart-cache-cli/ConfirmationDialog"
12
7
"smart-cache-cli/RedisCommon"
13
8
"smart-cache-cli/util"
14
9
"strings"
10
+
11
+ "github.com/charmbracelet/bubbles/list"
12
+ "github.com/charmbracelet/bubbles/textinput"
13
+ tea "github.com/charmbracelet/bubbletea"
14
+ "github.com/charmbracelet/lipgloss"
15
+ "github.com/redis/go-redis/v9"
15
16
)
16
17
17
18
type item struct { ruleType RedisCommon.RuleType }
@@ -242,22 +243,22 @@ func (m Model) View() string {
242
243
var b strings.Builder
243
244
244
245
if m .ruleType == RedisCommon .Unknown {
245
- b .WriteString ("select a rule type, press ctrl+b to return to the previous screen\n " )
246
+ b .WriteString (" == Create rule menu == \n \n Select the type of rule you want to create. \n Press [CTRL+B] to return to the previous screen. \n \n " )
246
247
b .WriteString (m .typeSelectorList .View ())
247
248
return b .String ()
248
249
} else if m .match == "" && m .ruleType != RedisCommon .All {
249
250
b .WriteString (m .ruleSoFar ())
250
251
if m .ruleType == RedisCommon .Regex {
251
- b .WriteString ("Input a regular expression to match against:" )
252
+ b .WriteString ("Enter a regular expression to match against:" )
252
253
} else if m .ruleType == RedisCommon .QueryIds {
253
- b .WriteString ("Input a comma delimited list of Query Ids to match against:" )
254
+ b .WriteString ("Enter a comma-separated list of Query IDs to match against:" )
254
255
} else {
255
- b .WriteString ("Input a comma delimited list of tables to match against:" )
256
+ b .WriteString ("Enter a comma-separated list of tables to match against:" )
256
257
}
257
258
b .WriteString (m .textInput .View ())
258
259
} else {
259
260
b .WriteString (m .ruleSoFar ())
260
- b .WriteString ("Input TTL in the form of a duration e.g. 1h, 300s, 5m: " )
261
+ b .WriteString ("Enter a TTL in the form of a duration ( e.g. 1h, 300s, 5m): " )
261
262
b .WriteString (m .textInput .View ())
262
263
}
263
264
0 commit comments