GithubHelp home page GithubHelp logo

test-mass-forker-org-1 / electionguard-ballot-marking-device Goto Github PK

View Code? Open in Web Editor NEW

This project forked from infernored/electionguard-sdk-ballot-marking-device-reference-implementation

0.0 0.0 0.0 12.82 MB

This repository contains code to implement a Ballot Marking Device that uses the ElectionGuard API to encrypt ballots and generate a tracking ID used by the voter to identify their ballot as being counted in the election when results are published.

License: MIT License

JavaScript 5.16% TypeScript 92.78% CSS 1.77% Makefile 0.08% HTML 0.21%

electionguard-ballot-marking-device's Introduction

Microsoft Defending Democracy Program: ElectionGuard

๐Ÿ—ณ ElectionGuard Ballot Marking Device

license

The ElectionGuard Reference Ballot Marking Device (BMD) is a fully functional implementation of a BMD built in ReactJS. It uses the Gamepad API to support a physically-connected Xbox Adaptive Controller for navigating ballots with the A/B buttons, D-pad, or other devices plugged into the XAC's connection ports.

The BMD was designed under the supervision of the Center for Civic Design as an update of the Anywhere Ballot and built by the team at VotingWorks. It runs locally in a web browser (Chrome or Edge Beta). A sample set of ballots (in json format) is available in both the /public/data/ and /src/data directories that showcases a variety of contests and referenda use cases.

By default, when a ballot is printed, the BMD also generates a static tracking ID. End-to-end verifiable elections create tracking IDs generated when the ballot is encrypted. It's used by voters to check that their vote was included in the final tally when all the artifacts of an end-to-end verifiable election are published. When you have built working encryption capability (using the C Implementation), the election.json configuration file can be modified to retrieve the tracking ID by updating this code block.

Install and Run App Locally

This assumes you have git and yarn installed.

  1. Clone the repo:

    git clone [email protected]:microsoft/ElectionGuard-SDK-Ballot-Marking-Device-Reference-Implementation.git
    
  2. Navigate to the top level of the cloned directory

    cd ElectionGuard-SDK-Ballot-Marking-Device-Reference-Implementation
    
  3. Install dependencies:

    yarn install
    
  4. Run the app in your local browser:

    yarn start
    

Local Development Scripts

  • yarn install - Install the dependencies.
  • yarn start - Run the app locally.
  • yarn test- Run tests in interactive mode.
  • yarn test:coverage - Run all tests and update test coverage report.

See package.json for all available scripts.

Technical Implementation

This project was bootstrapped with Create React App for TypeScript. It uses Styled Components for styles (and some css files too). ESLint is configured to lint Javascript and TypeScript files, and format code using Prettier. stylelint is used to lint modern css. Jest, dom-testing-library, react-testing-library, and Cypress are used to test components and end-to-end user flows.

Contributing

Help defend democracy and contribute to the project.

electionguard-ballot-marking-device's People

Contributors

beausmith avatar benadida avatar dependabot[bot] avatar dependabot-support avatar dependabot-preview[bot] avatar case avatar rc-ms avatar cjerdonek avatar electionguard avatar keithrfung avatar sarob avatar

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.