diff --git a/frontend/index.html b/frontend/index.html
index d2ed33d..67f8749 100644
--- a/frontend/index.html
+++ b/frontend/index.html
@@ -4,8 +4,10 @@
+
wordl
+
diff --git a/frontend/public/robots.txt b/frontend/public/robots.txt
new file mode 100644
index 0000000..4f9540b
--- /dev/null
+++ b/frontend/public/robots.txt
@@ -0,0 +1 @@
+User-agent: *
\ No newline at end of file
diff --git a/frontend/src/pages/home.rs b/frontend/src/pages/home.rs
index ba0dce9..2f1ca72 100644
--- a/frontend/src/pages/home.rs
+++ b/frontend/src/pages/home.rs
@@ -15,10 +15,14 @@ static WORDS_URI: &str = "https://wordl.shuttleapp.rs/public/wordlist.json";
static MAX_TRIES: usize = 5;
fn set_focus(index: usize) {
+ let prefix = match index {
+ 0 => "",
+ _ => "-"
+ };
if let Some(w) = web_sys::window() {
if let Some(d) = w.document() {
if let Some(n) = d
- .query_selector(&format!("[tabindex='{index}']"))
+ .query_selector(&format!("[tabindex='{prefix}{index}']"))
.ok()
.flatten()
{
@@ -478,11 +482,24 @@ pub fn Home() -> Html {
})
};
+ let prefix = match index {
+ 0 => String::new(),
+ _ => "-".to_owned(),
+ };
html! {
"one",
+ 1 => "two",
+ 2 => "three",
+ 3 => "four",
+ 4 => "five",
+ _ => "",
+
+ })}
onkeyup={on_enter.clone()}
oninput={on_input.clone()}
- tabindex={index.to_string()}
+ tabindex={ format!("{prefix}{index}")}
ref={node_ref.clone()}
value={input_values[index].clone()}
onfocus={on_focus.clone()}
@@ -519,7 +536,8 @@ pub fn Home() -> Html {
}
>