Coder Social home page Coder Social logo

world-class / compass Goto Github PK

View Code? Open in Web Editor NEW
11.0 11.0 3.0 641 KB

Compass is a suite of tools for students enrolled in the University of London's online BSc in Computer Science program.

License: MIT License

JavaScript 51.70% HTML 34.31% Shell 0.69% CSS 1.10% EJS 12.20%
coursera london-bsc online-education reviews university-of-london

compass's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

compass's Issues

Allow users to edit reviews

Users should be able to edit or delete their reviews somehow.

We can achieve this by giving each review a specific page e.g. /review/id/ or as get parameter. Either way it would work.

Another way is to have per user reviews page. A page showing all reviews from logged in user.

Depends on #31

Cannot retrieve any full review

Steps taken:

Following any link to any specific review - for example following the path reviews -> link to specific review from the home page, I get the following error:
reviewNotFound

It seems the end of the url with the review id is not being appended properly or similar error?

Add sanitization and validation on inputs

  • Sanitize review text
  • limit review text to some maximum limit #44
  • Validate difficulty, workload, rating and sessions on server side too
  • Validate sessions field
    - [ ] Remove weird UTF-8 characters that go out of review card.
    - [x] Sanitize username updates.

We can use express-validator for this.

Escape all values in HTML

I don't know if you want to but it might be worth having EJS escape all output just as a precaution to avoid any potential XSS issues.

The code looks safe but escaping all output would prevent any issues if some user input did accidentally sneak in. I can create a PR for it if you want to do it.

Add single review route

Sub goal of #32

  • Add a route for a single review, determined by query parameter
  • Add a link to the cards in review.html that passes that review's id to the new route and leads to page with just that review

Add personalized dashboard for tracking modules

Summary of slack discussions:

  • Allow users to select modules they are taking and save this information.
  • Each module should have a resource page like REPL, so others can quickly submit resources they found useful.
  • Some important messages should be fetched from Slack channels. ๐Ÿ‘ reactions can be used as proxy for usefulness. Pinned messages should also be pulled automatically. This will give a single page where user can see summary of all important resources for a module.

Problems with Displayed Text

Issues

  • "1 courses" in review section of profile
  • Flash message repetition when user tries to submit duplicate review

Feature request: "Report" button next to reviews

"Report" button next to reviews, in case of abusive comments. Or if the review appears to be, for example, completely the wrong course. Could lead to a simple form with a free text box to type the reason to report in, to email the admin for a human to review it.

Could maybe have some text around it with valid (and invalid) reasons to report reviews?

improve navbar styling

  • move Login and greeting to the right side
  • change greeting styling. Currently it's a normal link. Could be changed to a different element or maybe use the bootstrap "disabled" class which removes on hover and attributes and link styling

Highlight if data is not found

Some pages do not clearly specify absence of relevant data.

  • /review/id/num should let user know if review with id num does not exist. Right now it's a blank page.
  • /reviews?course_id=subjcode should let user know if subject code is not valid. right now it returns blank page.

Render whitespace in reviews

Improve review text in cards in reviews.html. For example, paragraphs defined in addreview form are not observed. Everything get's condensed to a continuous line.

Improve UI of review cards

UI of review cards is very basic and textual. Some CSS jazz can be added to improve the looks of it.

Some suggestions:

  • print only date instead of huge date string with timezone details
  • Add filters on top of page
  • Change the layout a bit to use horizontal space. Move username / difficulty / workload / rating details to right side.
  • Add some visuals like stars or rotary sliders with relevant colors for showing numbers.

image

Non user-friendly error when review comment is too large

Nasty raw JS error when review text is too large (afraid I didn't note how many characters it was, I just pasted a lot). Suggest a more user-friendly error, or some validation:

PayloadTooLargeError: request entity too large
at readStream (/home/ubuntu/compass/node_modules/raw-body/index.js:155:17)
at getRawBody (/home/ubuntu/compass/node_modules/raw-body/index.js:108:12)
at read (/home/ubuntu/compass/node_modules/body-parser/lib/read.js:77:3)
at urlencodedParser (/home/ubuntu/compass/node_modules/body-parser/lib/types/urlencoded.js:116:5)
at Layer.handle [as handle_request] (/home/ubuntu/compass/node_modules/express/lib/router/layer.js:95:5)
at trim_prefix (/home/ubuntu/compass/node_modules/express/lib/router/index.js:317:13)
at /home/ubuntu/compass/node_modules/express/lib/router/index.js:284:7
at Function.process_params (/home/ubuntu/compass/node_modules/express/lib/router/index.js:335:12)
at next (/home/ubuntu/compass/node_modules/express/lib/router/index.js:275:10)
at serveStatic (/home/ubuntu/compass/node_modules/serve-static/index.js:75:16)

Redundant steer to "visit review" when duplicate module review is entered

Journey:

  1. Already reviewed ITP1
  2. Go to Courses and select ITP1 again (and fill in other boxes with valid input)
  3. Hit Submit
  4. My original review is presented to me (not the new review), however this page also has "You have already reviewed this course. Would you like to edit it? Visit review" link on it which is redundant, as I am already there.

Suggest after hitting Submit, the new review remains on the page, in case the user has selected the wrong module by accident. Then their text isn't lost.

After a 500: internal server error, going back loses the module and session and unable to select original without selecting another first

Journey:

  1. Complete a review for ITP1, October to March 2020, valid content for Difficulty, Workload, Rating; Comment field contains an emoji (invalid character)
  2. Submit
  3. 500: internal server error
  4. Browser back button
  5. All fields except Module and Session are remembered
  6. Original Module and Session (ITP1, October to March 2020) are unable to be selected - visible in list but clicking does not select them
  7. Select any other Module and Session
  8. Able now to select original Module and Session
  9. Remove cat emoji from comment field :(
  10. Submit (successfully)

I will upload a screen recording on Slack, makes it clearer.

Improve authentication process

Some suggestions received:

- [ ] Password double-typing to improve accessibility.
- [ ] Fix duplicate alerts for account/profile verification.
- [ ] Show proper errors in login/registration forms
- [ ] Account creation form: Change the label of the button from "Submit" to "Create account"
- [ ] Use red alerts only if an error occurred, use amber or blue otherwise
- [ ] "Already an account?" -> "Already have an account?"

  • Allow logins with slack. Since we are already using it for account verification it would be a good idea to let users log in directly with Slack.

JS error on account creation

On creating an account I encountered the error message attached.

Steps taken:

Followed the login -> register for an account steps from the home page
Entered name, email, and password, hit 'submit' or equivalent button.
Was taken to the route: http://www.ucompass.tech/profile where I saw this error message.

registrationError

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.