6
6
"github.com/charmbracelet/lipgloss"
7
7
"github.com/charmbracelet/lipgloss/list"
8
8
"github.com/charmbracelet/lipgloss/table"
9
- "github.com/charmbracelet/lipgloss/tree"
10
9
"github.com/lucasb-eyer/go-colorful"
11
10
)
12
11
@@ -119,16 +118,16 @@ func main() {
119
118
Item ("Lip Gloss" ).
120
119
Item ("Lip Gloss" ).
121
120
Item (
122
- tree .New ().
121
+ list .New ().
123
122
EnumeratorStyle (lipgloss .NewStyle ().Foreground (lipgloss .Color (colors [4 ][0 ])).MarginRight (1 )).
124
- Child ("\n Style Definitions for Nice Terminal Layouts\n βββββ" ).
125
- Child ("From Charm" ).
126
- Child ("https://github.com/charmbracelet/lipgloss" ).
127
- Child (
128
- tree .New ().
123
+ Item ("\n Style Definitions for Nice Terminal Layouts\n βββββ" ).
124
+ Item ("From Charm" ).
125
+ Item ("https://github.com/charmbracelet/lipgloss" ).
126
+ Item (
127
+ list .New ().
129
128
EnumeratorStyle (lipgloss .NewStyle ().Foreground (lipgloss .Color (colors [3 ][0 ])).MarginRight (1 )).
130
- Child ("Emperors: Julio-Claudian dynasty" ).
131
- Child (
129
+ Item ("Emperors: Julio-Claudian dynasty" ).
130
+ Item (
132
131
lipgloss .NewStyle ().Padding (1 ).Render (
133
132
list .New (
134
133
"Augustus" ,
@@ -139,7 +138,7 @@ func main() {
139
138
).Enumerator (list .Roman ).String (),
140
139
),
141
140
).
142
- Child (
141
+ Item (
143
142
lipgloss .NewStyle ().
144
143
Bold (true ).
145
144
Foreground (lipgloss .Color ("#FAFAFA" )).
@@ -151,7 +150,7 @@ func main() {
151
150
Width (40 ).
152
151
Render (history ),
153
152
).
154
- Child (
153
+ Item (
155
154
table .New ().
156
155
Width (30 ).
157
156
BorderStyle (purple .MarginRight (0 )).
@@ -174,8 +173,8 @@ func main() {
174
173
Row ("Orange" , "2" ).
175
174
Row ("Strawberry" , "12" ),
176
175
).
177
- Child ("Documents" ).
178
- Child (
176
+ Item ("Documents" ).
177
+ Item (
179
178
list .New ().
180
179
Enumerator (func (_ list.Items , i int ) string {
181
180
if i == 1 {
@@ -200,9 +199,9 @@ func main() {
200
199
Item ("Baz Document\n " + faint .Render ("10 minutes ago" )).
201
200
Item ("Qux Document\n " + faint .Render ("1 month ago" )),
202
201
).
203
- Child ("EOF" ),
202
+ Item ("EOF" ),
204
203
).
205
- Child ("go get github.com/charmbracelet/lipgloss/list\n " ),
204
+ Item ("go get github.com/charmbracelet/lipgloss/list\n " ),
206
205
).
207
206
Item ("See ya later" ),
208
207
),
0 commit comments