Git Product home page Git Product logo

typing-tutor's People

Contributors

arthurhwang avatar

Watchers

 avatar  avatar

typing-tutor's Issues

User can see the text

๐Ÿ’ฐ Motivation

The user will need to see the whole phrase they are about to type.

โš™๏ธ Implementation

  • Create an index.html for the markup.
  • Put background and text colors in styles.css.
  • Select a font from Google Fonts for the text.
  • Create an Array of Objects representing the characters in the phrase.
  • Define a function that renders a single character.
  • Define a function that renders all characters and appends them to the page.
  • Adjust CSS styles to look visually appealing.
    see-the-text

User can get feedback

๐Ÿ’ฐ Motivation

The user needs to be alerted to successful or failed attempts at typing a character.

โš™๏ธ Implementation

  • Add failures property to each character in the application state set to 0.
  • Add an event listener to the window to listen for 'keydown' events that re-renders the phrase.
  • Compare the pressed key with the current character. Record failures to match the current character.
  • Enhance function for rendering a single character to conditionally add a special failed class to the element.
  • When a matching key is pressed, update the currentCharacter property of the application state.
    get-feedback

restyle page

  • Redo theme colors

  • Redo font sizing

  • Redo font colors

  • Add animations if possible

User can see next letter

๐Ÿ’ฐ Motivation

The user needs to know how far along they are in the phrase.

โš™๏ธ Implementation

  • Create an Object to represent the application state, and make the characters a property.
  • Add a property to the application state to track the index of the currentCharacter.
  • Define a CSS class to highlight the current-character.
  • Enhance function that renders a character to conditionally add a special current-character class.
    see-next-letter

User can see score

๐Ÿ’ฐ Motivation

The user will need to know that the game is over and how they performed.

โš™๏ธ Implementation

  • Define a function that calculates the user's success rate given the recorded failures.
  • Define a function that renders the user's score and a "game over" message.
  • Enhance 'keydown' listener to render and show the user's score when they've reached the end.
    see-score

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.