Skip to content

A simple web app that translates Morse code to English or English to Morse code.

Notifications You must be signed in to change notification settings

Kris-Martin/morse-translator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Morse Code Translator

Description

A simple web app using HTML, SCSS and Javascript to translate English to Morse Code or Morse Code to English.

You can test the app here:

https://kris-martin.github.io/morse-translator/

Morse Code App UI

Features

  • Detects if input is English or Morse and then translates and outputs result
  • Detects if input is valid Morse or uses invalid characters
  • Shows user error messages if empty input or invalid characters

Project Brief

Create a web page Morse Code translator. The User Interface should be simple.

MVP

  • Create a user interface that allows the user to either input some English text or some Morse Code

  • Create JS functions that would allow the user to:

    • translate their English text into Morse Code
    • Morse Code into English text
  • Make sure to handle spaces properly (ie. there is 1 space between English words, but one space between Morse Code characters)

  • Make sure to keep your pure functions separated from the JS DOM interaction code.

// A to Z in Morse Code
{
   "A": ".-",
   "B": "-...",
   "C": "-.-.",
   "D": "-..",
   "E": ".",
   "F": "..-.",
   "G": "--.",
   "H": "....",
   "I": "..",
   "J": ".---",
   "K": "-.-",
   "L": ".-..",
   "M": "--",
   "N": "-.",
   "O": "---",
   "P": ".--.",
   "Q": "--.-",
   "R": ".-.",
   "S": "...",
   "T": "-",
   "U": "..-",
   "V": "...-",
   "W": ".--",
   "X": "-..-",
   "Y": "-.--",
   "Z": "--.."
   // Add space handling
   // " ": "/"
}

About

A simple web app that translates Morse code to English or English to Morse code.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published