1use crate::ui::{
2 AURORA_GREEN, CELESTIAL_BLUE, COMET_ORANGE, GALAXY_PINK, METEOR_RED, NEBULA_PURPLE,
3 PLASMA_CYAN, SOLAR_YELLOW, STARLIGHT,
4};
5use lazy_static::lazy_static;
6use rand::prelude::*;
7use ratatui::style::Color;
8
9#[derive(Clone)]
10pub struct ColoredMessage {
11 pub text: String,
12 pub color: Color,
13}
14
15lazy_static! {
16 static ref WAITING_MESSAGES: Vec<ColoredMessage> = vec![
17 ColoredMessage {
18 text: "๐ฎ Consulting the cosmic commit oracle...".to_string(),
19 color: NEBULA_PURPLE
20 },
21 ColoredMessage {
22 text: "๐ Aligning the celestial code spheres...".to_string(),
23 color: CELESTIAL_BLUE
24 },
25 ColoredMessage {
26 text: "๐ป Channeling the spirit of clean commits...".to_string(),
27 color: AURORA_GREEN
28 },
29 ColoredMessage {
30 text: "๐ Launching commit ideas into the coding cosmos...".to_string(),
31 color: METEOR_RED
32 },
33 ColoredMessage {
34 text: "๐ Exploring the galaxy of potential messages...".to_string(),
35 color: PLASMA_CYAN
36 },
37 ColoredMessage {
38 text: "๐ญ Peering into the commit-verse for inspiration...".to_string(),
39 color: SOLAR_YELLOW
40 },
41 ColoredMessage {
42 text: "๐ง Casting a spell for the perfect commit message...".to_string(),
43 color: GALAXY_PINK
44 },
45 ColoredMessage {
46 text: "โจ Harnessing the power of a thousand code stars...".to_string(),
47 color: STARLIGHT
48 },
49 ColoredMessage {
50 text: "๐ช Orbiting the planet of precise git descriptions...".to_string(),
51 color: CELESTIAL_BLUE
52 },
53 ColoredMessage {
54 text: "๐จ Weaving a tapestry of colorful commit prose...".to_string(),
55 color: PLASMA_CYAN
56 },
57 ColoredMessage {
58 text: "๐ Igniting the fireworks of code brilliance...".to_string(),
59 color: COMET_ORANGE
60 },
61 ColoredMessage {
62 text: "๐ง Syncing with the collective coding consciousness...".to_string(),
63 color: AURORA_GREEN
64 },
65 ColoredMessage {
66 text: "๐ Aligning the moon phases for optimal commit clarity...".to_string(),
67 color: STARLIGHT
68 },
69 ColoredMessage {
70 text: "๐ฌ Analyzing code particles at the quantum level...".to_string(),
71 color: NEBULA_PURPLE
72 },
73 ColoredMessage {
74 text: "๐งฌ Decoding the DNA of your changes...".to_string(),
75 color: GALAXY_PINK
76 },
77 ColoredMessage {
78 text: "๐บ Summoning the ancient spirits of version control...".to_string(),
79 color: METEOR_RED
80 },
81 ColoredMessage {
82 text: "๐ก Tuning into the frequency of flawless commits...".to_string(),
83 color: CELESTIAL_BLUE
84 },
85 ColoredMessage {
86 text: "๐ Charging the commit crystals with cosmic energy...".to_string(),
87 color: PLASMA_CYAN
88 },
89 ColoredMessage {
90 text: "๐ Translating your changes into universal code...".to_string(),
91 color: AURORA_GREEN
92 },
93 ColoredMessage {
94 text: "๐งช Distilling the essence of your modifications...".to_string(),
95 color: SOLAR_YELLOW
96 },
97 ColoredMessage {
98 text: "๐ธ๏ธ Unraveling the threads of your code tapestry...".to_string(),
99 color: NEBULA_PURPLE
100 },
101 ColoredMessage {
102 text: "๐ฆ Consulting the all-knowing git guardians...".to_string(),
103 color: CELESTIAL_BLUE
104 },
105 ColoredMessage {
106 text: "๐ต Harmonizing with the rhythms of the coding universe...".to_string(),
107 color: GALAXY_PINK
108 },
109 ColoredMessage {
110 text: "๐ Diving into the depths of the code ocean...".to_string(),
111 color: PLASMA_CYAN
112 },
113 ColoredMessage {
114 text: "๐ง Seeking wisdom from the repository sages...".to_string(),
115 color: AURORA_GREEN
116 },
117 ColoredMessage {
118 text: "๐งญ Calibrating the commit compass for true north...".to_string(),
119 color: SOLAR_YELLOW
120 },
121 ColoredMessage {
122 text: "๐ Unlocking the secrets of the commit constellations...".to_string(),
123 color: NEBULA_PURPLE
124 },
125 ColoredMessage {
126 text: "โญ Gathering stardust for your stellar commit...".to_string(),
127 color: STARLIGHT
128 },
129 ColoredMessage {
130 text: "๐ Focusing the lens of the code telescope...".to_string(),
131 color: CELESTIAL_BLUE
132 },
133 ColoredMessage {
134 text: "๐ Riding the waves of inspiration through the code cosmos...".to_string(),
135 color: PLASMA_CYAN
136 },
137 ];
138 static ref USER_MESSAGES: Vec<ColoredMessage> = vec![
139 ColoredMessage {
140 text: "๐ Launching commit rocket".to_string(),
141 color: METEOR_RED
142 },
143 ColoredMessage {
144 text: "๐ Illuminating code cosmos".to_string(),
145 color: STARLIGHT
146 },
147 ColoredMessage {
148 text: "๐ญ Observing code constellations".to_string(),
149 color: CELESTIAL_BLUE
150 },
151 ColoredMessage {
152 text: "๐งโโ๏ธ Weaving code enchantments".to_string(),
153 color: GALAXY_PINK
154 },
155 ColoredMessage {
156 text: "โ๏ธ Splitting code atoms".to_string(),
157 color: PLASMA_CYAN
158 },
159 ColoredMessage {
160 text: "๐ Painting commit rainbows".to_string(),
161 color: AURORA_GREEN
162 },
163 ColoredMessage {
164 text: "๐ Unlocking git portals".to_string(),
165 color: SOLAR_YELLOW
166 },
167 ColoredMessage {
168 text: "๐ญ Staging code drama".to_string(),
169 color: COMET_ORANGE
170 },
171 ColoredMessage {
172 text: "๐ Expanding code universe".to_string(),
173 color: NEBULA_PURPLE
174 },
175 ColoredMessage {
176 text: "๐น Aiming commit arrows".to_string(),
177 color: METEOR_RED
178 },
179 ColoredMessage {
180 text: "๐จ Brushing commit strokes".to_string(),
181 color: PLASMA_CYAN
182 },
183 ColoredMessage {
184 text: "๐ฑ Growing code forests".to_string(),
185 color: AURORA_GREEN
186 },
187 ColoredMessage {
188 text: "๐งฉ Assembling code puzzle".to_string(),
189 color: GALAXY_PINK
190 },
191 ColoredMessage {
192 text: "๐ถ Orchestrating commit symphony".to_string(),
193 color: CELESTIAL_BLUE
194 },
195 ColoredMessage {
196 text: "โ๏ธ Balancing code forces".to_string(),
197 color: SOLAR_YELLOW
198 },
199 ];
200}
201
202pub fn get_waiting_message() -> ColoredMessage {
203 let mut rng = rand::rng();
204 WAITING_MESSAGES
205 .choose(&mut rng)
206 .cloned()
207 .unwrap_or_else(|| ColoredMessage {
208 text: "Processing your request...".to_string(),
209 color: SOLAR_YELLOW,
210 })
211}
212
213pub fn get_user_message() -> ColoredMessage {
214 let mut rng = rand::rng();
215 USER_MESSAGES
216 .choose(&mut rng)
217 .cloned()
218 .unwrap_or_else(|| ColoredMessage {
219 text: "What would you like to do?".to_string(),
220 color: CELESTIAL_BLUE,
221 })
222}