- Add new static methods to user model
- `findByEmailAndUsername`
- renames `findByMailOrName` to `findByEmailOrUsername`
- `findByUsername`
- `findByEmail`
- Reverts case insensitive behavior for username
* Converts import script to use public API endpoints
The endpoints don't exist yet, but this is a good way to see how
the implementation of the data structures differ.
* Exposes public API endpoint to fetch user's sketches
* Implements public API delete endpoint
* Adds helper to create custom ApplicationError classes
* Adds create project endpoint that understand API's data structure
This transforms the nested tree of file data into a mongoose
Project model
* Returns '201 Created' to match API spec
* Removes 'CustomError' variable assignment as it shows up in test output
* transformFiles will return file validation errors
* Tests API project controller
* Tests toModel()
* Creates default files if no root-level .html file is provided
* Do not auto-generate a slug if it is provided
Fixes a bug where the slug was auto-generated using the sketch name,
even if a slug property had been provided.
* Validates uniqueness of slugs for projects created by the public API
* Adds tests for slug uniqueness
* Configures node's Promise implementation for mongoose (fixes warnings)
* Moves createProject tests to match controller location
* Adds support for code to ApplicationErrors
* deleteProject controller tests
* getProjectsForUser controller tests
- implements tests
- update apiKey tests to use new User mocks
* Ensure error objects have consistent property names
`message` is used as a high-level description of the errors
`detail` is optional and has an plain language explanation of the
individual errors
`errors` is an array of each individual problem from `detail` in a
machine-readable format
* Assert environment variables are provided at script start
* Version public API
* Expect "files" property to always be provided
* Fixes linting error
* Converts import script to use public API endpoints
The endpoints don't exist yet, but this is a good way to see how
the implementation of the data structures differ.
* Exposes public API endpoint to fetch user's sketches
* Implements public API delete endpoint
* Adds helper to create custom ApplicationError classes
* Adds create project endpoint that understand API's data structure
This transforms the nested tree of file data into a mongoose
Project model
* Returns '201 Created' to match API spec
* Removes 'CustomError' variable assignment as it shows up in test output
* transformFiles will return file validation errors
* Tests API project controller
* Tests toModel()
* Creates default files if no root-level .html file is provided
* Do not auto-generate a slug if it is provided
Fixes a bug where the slug was auto-generated using the sketch name,
even if a slug property had been provided.
* Validates uniqueness of slugs for projects created by the public API
* Adds tests for slug uniqueness
* Configures node's Promise implementation for mongoose (fixes warnings)
* Moves createProject tests to match controller location
* deleteProject controller tests
* Adds support for code to ApplicationErrors
* getProjectsForUser controller tests
- implements tests
- update apiKey tests to use new User mocks
* Ensure error objects have consistent property names
`message` is used as a high-level description of the errors
`detail` is optional and has an plain language explanation of the
individual errors
`errors` is an array of each individual problem from `detail` in a
machine-readable format
* Assert environment variables are provided at script start
* Version public API
* Expect "files" property to always be provided
* Fixes linting error
* Checks that authenticated user has permission to create under this namespace
Previously, the project was always created under the authenticated user's
namespace, but this not obvious behaviour.
* parent b3c3efcec9
author Laksh Singla <lakshsingla@gmail.com> 1549106083 +0530
committer Cassie Tarakajian <ctarakajian@gmail.com> 1560540243 -0400
parent b3c3efcec9
author Laksh Singla <lakshsingla@gmail.com> 1549106083 +0530
committer Cassie Tarakajian <ctarakajian@gmail.com> 1560540198 -0400
parent b3c3efcec9
author Laksh Singla <lakshsingla@gmail.com> 1549106083 +0530
committer Cassie Tarakajian <ctarakajian@gmail.com> 1560539667 -0400
Created initial html structure and styling for new SketchList design
Final styling of ActionDialogueBox commplete
Dropdown menu disappearing while clicking anywhere on the table
Fixed linting issues and renamed variables
Minor tweaks in the SketchList dropdown dialogue UI
Themifyed the dropdown
Made changes in the dropdown: Arrow positioned slightly updwards, Removed blank space and added box-shadow in dropdown, themifyed dropdowns dashed border color
Added Delete and Share functionality to Dialog box
Added Duplicate functionality to Dialog box
Added download functionality to Dialog box
SketchList does not open a sketch if dialogue box is opened
SketchList Rename initial UI completed
Enter key handled for rename project option
[WIP] Updating rename functionality
Download option now working for all the sketches
Duplicate functionality extended for non opened sketches too
Modified overlay behaviour to close only the last overlay
Share modal can now display different projects
Dropdown closes when Share and Delete are closing for a more natural UX
fix broken files from rebasing
Created initial html structure and styling for new SketchList design
Final styling of ActionDialogueBox commplete
Added Delete and Share functionality to Dialog box
Added Duplicate functionality to Dialog box
[WIP] Updating rename functionality
Duplicate functionality extended for non opened sketches too
Modified overlay behaviour to close only the last overlay
Share modal can now display different projects
Final styling of ActionDialogueBox commplete
Fixed linting issues and renamed variables
Minor tweaks in the SketchList dropdown dialogue UI
Themifyed the dropdown
Added Delete and Share functionality to Dialog box
[WIP] Updating rename functionality
Modified overlay behaviour to close only the last overlay
Share modal can now display different projects
Dropdown closes when Share and Delete are closing for a more natural UX
fix broken files from rebasing
Final styling of ActionDialogueBox commplete
Minor tweaks in the SketchList dropdown dialogue UI
Themifyed the dropdown
[WIP] Updating rename functionality
Duplicate functionality extended for non opened sketches too
Modified overlay behaviour to close only the last overlay
Share modal can now display different projects
Dropdown closes when Share and Delete are closing for a more natural UX
* fix bugs in merge commit
* move sketch list dialogue to ul/li
* update sketch option dropdown to use dropdown placeholder, remove unused css
* major refactor of sketchlist component, fix showShareModal action, minor updates ot icon sizing
* fix broken links on asset list
* remove unused image, fix options for different users in sketch list
* upgrades jest to latest version
* tests Project model with mockingoose
* extracts createProject controller to own file
* tests createProject controller with sinon-mongoose
* add isSaving to project reducer, move actions to functions, start work to get comprehensive frontend/backend syncing working
* handle making changes while saving project, handle saving from another window
* add change to handle saving new sketch, and adding new changes while saving
* External libraries are bundled with zip when project is downloaded (#44)
* Fix linting errors
* Add a check for valid URLs before trying to bundle a library into project
* Add is-url lib to package.json
* start to create asset list
* begin refactoring overlay component to remove duplicate code
* refactoring of overlays, asset list styles
* changes to add size to asset list
* fixes to asset list
* handle case in which a user hasn't uploaded any assets
* fix bug in which asset list only grabbed first asset
* remove console.log
* update overlay exit styling to use icon mixin
* update eslint and dependencies, fix linting errors that can be fixed with --fix
* fix lots of linting errors
* update eslintrc, fix some linting errors
* fix all server side linting errors, untested
* fix errors that fixing linting errors had caused
* fix client side eslint errors
* fix client side linting errors
* fix refs lint errors
* fix more linting errors
* update eslint and dependencies, fix linting errors that can be fixed with --fix
* fix lots of linting errors
* update eslintrc, fix some linting errors
* fix all server side linting errors, untested
* fix errors that fixing linting errors had caused
* fix client side eslint errors
* fix client side linting errors
* fix refs lint errors
* fix more linting errors
* fix some accessibility linting errors
* fix a lot of linting errors
* fix a billion more linting errors
* hopefully fix all linting errors, still need to test
* fix bugs that fixing linting had caused
* Changed unsaved changes asterisk to an svg circle. #158
* Fixed#100
Unmatched routes are handled by react-router on the client side
and a single wildcard route on server.routes.js renders the index
html.
When the /:username/sketches route is matched and the username is not
valid, the user will be redirected to the index route and a toast
will explain what happened. When the username is 'p5' (default when
logged out) it will show all sketches. Maybe this should be changed
to just public or 'local' sketches?
* Moved unsaved changes SVG to a separate file.
* User not found is now a 404 error.
* Added server rendered 404 page.
* Removed console.log
* 404 Page now renders a random p5 sketch. TODO: make 404 sketches.
* Added 404 header
404 page now fetches a random example sketch
* Moved circle closer to file name
* Render 404 page in SketchList route if !user