Create a Javascript object (see example below) that represents a limited dictionary and use it to translate a holiday card message from English into another language.
{"merry":"god", "christmas":"jul", "and":"och", "happy":"gott", "new":"nytt", "year":"år"}
This is Swedish, so please choose other languages. You can add as many words/translations as you wish so that the user can write more complex holiday cards.
- Your translator should work for 3 languages other than English, so you should have 3 different dictionary objects.
- Your project should have one HTML file that includes a textarea (for users to enter limited phrases with words contained in your dictionaries), 3 buttons that have the language to translate to, and an empty DOM element into which the translated text will be inserted.
- The user types something in, clicks the button they want to translate to, and that translated statement should appear in the empty DOM element.
- Your JS file should be comprised of functions, no actions should happen in your code outside of a function
- Your HTML and JS should all have proper indentations
- You should not start coding until all steps in this planning section are complete (you may push the README.md to master but no other code)
- Create a github project for this assignment
- Determine how you are going to break this assignment into different features and make a github projects card for each feature. Each card should have the following:
- Card Title (Example: "Create Navbar")
- User story: (Example: "As a user, when I am on the site, there should be a navbar")
- Dev Notes: (Example: "Create a nav element with an li for about, projects, and blogs. Clicking on the li should take me to a blank page with an h1 tag of that element")
- Acceptance Criteria: (Example: "There should be a navbar, its should have 3 links, the links should work, the pages they go to should display a single h1 tag with the page title")
- Use a wireframe tool like Moqups to create wireframes for your page.
- Include the appropriate section of your Moqup on the github project card.
- I'm Feeling Lucky
Have an additional button that says I'm Feeling Lucky. When the user clicks that button your code should randomly decide what language to translate to and output it to the DOM.
- Read the answer
In addition to inserting the translated text into the HTML document, have the browser read the translated text to the user.
- Make Your Own Bonus
After you complete all of the above, you may come up with your own feature and get it approved by your product owners (the instructors) before you implement it.