avbhatt / SOCS

0 stars 0 forks source link

EECS498: Social Computing Final Project

Web Accessibility Helper Adit Bhatt, Angelina Fahs, Christina Liu, Ian McKenzie

Setup

Prerequisites

Local Testing

  1. Clone the entire repository
    • git clone https://github.com/avbhatt/SOCS.git
  2. Navigate to the root folder SOCS
  3. To set up the npm dependencies, type npm install from the root directory
    • Confirm that all packages from package.json were installed correctly
  4. Run the node server with node index.js
  5. Navigate to the plugin folder within SOCS
  6. Begin two instances of the Firefox Developer Edition using web-ext
    • web-ext run --firefox="/Applications/Firefox Developer Edition.app/Contents/MacOS/firefox-bin"
    • The value for option --firefox will change depending on where Firefox Developer Edition is installed
    • This opens the browser with the extension preinstalled as per the manifest.json
    • This command does not exit until the browser is closed, so two command terminals are necessary to start two instances
  7. Change one browser to helper view via the popup
  8. Navigate both browsers to the same website
    • Static webpages such as Wikipedia articles work better
    • Our extension does not work on browser pages that are not websites (the new tab page, setting pages, etc.)
  9. Hit I Need Help on the User view
    • This should begin a chat with the waiting helper by sending a default message
  10. Chat

Architecture

Server

index.js

popup/options.[js,css,html]

Dropdown for changing between user and helper. Sends updated type to background in message.

sidebar/chat.js

Handles message input by sending message to background dealing with message content. Also handles close button and help button.

Receives messages from background with message replies and updates UI to display.

sidebar/annotation-list.js

Fetches annotations for a website on website updates via GET request to /getAnnotations and updates the sidebar with these annotations

sidebar/sidebar.[css,html]

Creates buttons, divs, lists needed for chat and annotation interface. In-line style used to change display types dynamically.

sidebar/submit_annotation.js

Handles the annotation submission form by sending message to annotation-form.js upon clicking the submit annotation button.

annotation-form.js

Content script that creates the annotation submission form as a modal. Sends the annotation content to background in message.

Resources

Browser Extensions

Socket.IO

ExpressJS

Database Info