diff --git a/images/cards_conversation_no.svg b/images/cards_conversation_no.svg
new file mode 100644
index 0000000..7d676fa
--- /dev/null
+++ b/images/cards_conversation_no.svg
@@ -0,0 +1,29 @@
+
diff --git a/images/cards_food_hungry.svg b/images/cards_food_hungry.svg
new file mode 100644
index 0000000..e58296d
--- /dev/null
+++ b/images/cards_food_hungry.svg
@@ -0,0 +1,50 @@
+
diff --git a/images/cards_food_thirsty.svg b/images/cards_food_thirsty.svg
new file mode 100644
index 0000000..3a8450f
--- /dev/null
+++ b/images/cards_food_thirsty.svg
@@ -0,0 +1,25 @@
+
diff --git a/images/cards_people_father.svg b/images/cards_people_father.svg
new file mode 100644
index 0000000..8aca265
--- /dev/null
+++ b/images/cards_people_father.svg
@@ -0,0 +1,22 @@
+
diff --git a/images/cards_people_mother.svg b/images/cards_people_mother.svg
new file mode 100644
index 0000000..dae693a
--- /dev/null
+++ b/images/cards_people_mother.svg
@@ -0,0 +1,19 @@
+
diff --git a/pecslib.js b/pecslib.js
index 8554e49..7cdbc81 100644
--- a/pecslib.js
+++ b/pecslib.js
@@ -14,12 +14,18 @@ class pec {
root.appendChild(img);
var name = document.createElement("span");
name.innerText = word;
- name.classList.add("pecNane");
+ name.classList.add("pecName");
root.appendChild(name);
root.mom = this;
root.addEventListener("click",(e)=>{
+ // tts synth api is inconsistant at best,
+ // need to find a more reliable solution.
var targ = e.currentTarget.mom;
- window.speechSynthesis.speak(targ.utterance);
+ var utter = new SpeechSynthesisUtterance(targ.word);
+ console.log(targ.word);
+ utter.lang = utter.voice.lang
+ utter.onend = () => { console.log("Talked?"); };
+ window.speechSynthesis.speak(utter);
});
this.DOM = root;
}