Skip to content
Myr

Set character limits on text input examples

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Christian Rocha · committed by Christian Rocha · parent b8bc66e · Browse files · 2 files+4 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+4 added−0 removed

  • other:+4 added−0 removed

2 files+4 added−0 removed

modified:examples/textinput/main.go+1 added
29 unmodified lines
30func initialModel() model {31 inputModel := input.NewModel()32 inputModel.Placeholder = "Pikachu"33 inputModel.Focus()34 inputModel.CharLimit = 203536 return model{37 textInput: inputModel,38 err: nil,
38 unmodified lines
modified:examples/textinputs/main.go+3 added
41 unmodified lines
42 name.Placeholder = "Name"43 name.Focus()44 name.Prompt = focusedPrompt45 name.TextColor = focusedTextColor46 name.CharLimit = 324748 nickName := input.NewModel()49 nickName.Placeholder = "Nickname"50 nickName.Prompt = blurredPrompt51 nickName.CharLimit = 325253 email := input.NewModel()54 email.Placeholder = "Email"55 email.Prompt = blurredPrompt56 email.CharLimit = 645758 return model{0, name, nickName, email, blurredSubmitButton}5960}
121 unmodified lines