Skip to content

Commit

Permalink
Refactoring and renaming
Browse files Browse the repository at this point in the history
  • Loading branch information
shettysach committed Feb 21, 2024
1 parent 3fb5bd5 commit 26cb766
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
File renamed without changes.
13 changes: 11 additions & 2 deletions src/base/prompt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,20 @@ pub fn Prompt(
//On submit
let on_submit = move |ev: SubmitEvent| {
ev.prevent_default();
let value = input_element().unwrap().value();
let input_value = input_element().unwrap().value();
let next = next.clone();

spawn_local(async move {
general_commands(value, state, next, set_out, submitter, updater, history).await
general_commands(
input_value,
state,
next,
set_out,
submitter,
updater,
history,
)
.await
});

form_element().unwrap().set_inert(true);
Expand Down
4 changes: 2 additions & 2 deletions src/fetch/formats.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use crate::fetch::{About, Links, Repository, UserInfo, UserStats};
use std::collections::HashMap;

const IMG_G: &str = include_str!("../../configs/img_g.txt");
const NEOFETCH: &str = include_str!("../../configs/neofetch.txt");
const RUST: &str = include_str!("../../configs/lang_icons/ferris.txt");
const PYTHON: &str = include_str!("../../configs/lang_icons/pythons.txt");
const JAVASCRIPT: &str = include_str!("../../configs/lang_icons/javascript.txt");
Expand Down Expand Up @@ -140,7 +140,7 @@ pub fn format_github(
<div class="gcols">{}</div>
<div class="gcols">{}</div>
</div>"#,
IMG_G, text
NEOFETCH, text
)
}

Expand Down

0 comments on commit 26cb766

Please sign in to comment.