From aecac1668e9854e978427ee6c67ab706f71fa788 Mon Sep 17 00:00:00 2001 From: Robbie Antenesse Date: Wed, 8 May 2019 12:20:30 -0600 Subject: [PATCH] Show a message when no words --- src/js/render.js | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/js/render.js b/src/js/render.js index e811063..b74524f 100644 --- a/src/js/render.js +++ b/src/js/render.js @@ -106,8 +106,19 @@ export function renderPartsOfSpeech() { } export function renderWords() { - const words = getMatchingSearchWords(); let wordsHTML = ''; + if (window.currentDictionary.words.length === 0) { + wordsHTML = `
+
+

No Words Created

+
+
+
Use the Word Form to create words or click the Help button below!
+
+
`; + } + + const words = getMatchingSearchWords(); const openEditForms = getOpenEditForms();