HedgeDoc - Ideas grow better together
Find a file
Erik Michelson 9e9108ec9a
Add read-only view (/s/note) (#563)
* Update Link classes to allow tooltips/titles

* Added read-only-view, Move note title extraction into separate file

(cherry picked from commit be23083ca3966f26b1b841d5cf4f21e299c8a55a)
(cherry picked from commit cbc595d3fc336b0a649c396dfae30fa08082384c)

* Optimized look of document-infobar

(cherry picked from commit 0176668b156da3fd7c534161a839ca0e3495119c)

# Conflicts:
#	src/components/editor/document-bar/document-info/document-info-time-line.tsx

* Show help-button only in Editor-variant of AppBar

(cherry picked from commit 3c26e1619c774fe162cb3d8fae9e79ced92c9c3e)

* Update CHANGELOG

(cherry picked from commit d0d29e7d408515cc8f86df45d13fff60d741873e)

* Move motd-banner to top of page

(cherry picked from commit 43a9a274bf5da3fdf640ec905ab38153c81b014b)

* Refactor isInline to size property

(cherry picked from commit cb4ee74b7c97ec9711946f28924e9c890b752ea3)

# Conflicts:
#	src/components/editor/document-bar/document-info/document-info-time-line.tsx

* Add size attribute to user-avatar

(cherry picked from commit 9629b58911b9d4f3aed81ef8c271fbc8e5a15aa4)

* Add mode-enum to app-bar

(cherry picked from commit 08f95be58974468c1e2897b475e5e3235b79c230)

* Split DocumentRenderPane into scrollable- and non-scrollable variant

(cherry picked from commit 44dd27edfd967745c548f7ae1fd2047e812cdc22)

* Removed unnecessary className
2020-10-12 21:58:00 +02:00
.github Rename codimd to hedgedoc (#434) 2020-09-02 21:17:26 +02:00
.idea/dictionaries Rename codimd to hedgedoc (#434) 2020-09-02 21:17:26 +02:00
cypress Replace emoji-mart with emoji-picker-element (#620) 2020-10-10 23:12:17 +02:00
icon Replace react icon with default codimd icon 2020-05-31 19:17:24 +02:00
public Add read-only view (/s/note) (#563) 2020-10-12 21:58:00 +02:00
src Add read-only view (/s/note) (#563) 2020-10-12 21:58:00 +02:00
.editorconfig Change indentation for json files to 4 spaces and reformat json files 2020-08-15 22:53:44 +02:00
.gitignore Fix missed code (#530) 2020-09-02 21:57:31 +02:00
CHANGELOG.md Add read-only view (/s/note) (#563) 2020-10-12 21:58:00 +02:00
CONTRIBUTING.md Create CONTRIBUTING.md (#402) 2020-08-12 23:12:59 +02:00
craco.config.js Replace emoji-mart with emoji-picker-element (#620) 2020-10-10 23:12:17 +02:00
cypress.json Use prod build for e2e tests (#432) 2020-08-19 22:43:56 +02:00
LICENSE Add AGPL 3.0 2020-05-26 17:19:37 +02:00
package.json updated flowchart.js to 1.14.2 (#671) 2020-10-11 21:03:23 +02:00
README.md Add webpack-bundle-analyzer as dev-tool (#591) 2020-09-20 23:22:37 +02:00
renovate.json Add automerge config to renovatebot 2020-08-01 15:49:41 +02:00
tsconfig.json imported current state of the mockup into the public repo 2020-05-14 15:41:38 +02:00
yarn.lock updated flowchart.js to 1.14.2 (#671) 2020-10-11 21:03:23 +02:00

HedgeDoc - React Client

test, build e2e lint

This is the new, improved and better looking frontend for HedgeDoc 2.0. Our goal is to recreate the current frontend in react and to improve it.

Preparation

You'll need at least Node 12. We use yarn for our dependencies.

Development mode

  1. Clone this repo (e.g. git clone https://github.com/codimd/react-client.git hedgedoc-react-client)
  2. Go inside the repo (e.g. cd hedgedoc-react-client)
  3. Run yarn install
  4. Either run

This should run the app in the development mode and open http://localhost:3001 in your browser.

The page will reload if you make edits. You will also see any lint errors in the console.

Tests

Unit

Unit testing is done via jest.

  1. Run yarn test

End2End

We use cypress for e2e tests.

  1. Start the frontend with yarn start
  2. Run yarn cy:open to open the cypress test loader
  3. Choose your browser and test
  4. Let the tests run

Bundle analysis

You can inspect the generated production-bundle files to look for optimization issues.

  1. Run yarn analyze
  2. Open the generated build/report.html in your favourite browser

Production mode

  1. Clone this repo (e.g. git clone https://github.com/codimd/react-client.git hedgedoc-react-client)
  2. Go inside the repo (e.g. cd hedgedoc-react-client)
  3. Run yarn install
  4. Run yarn build

Builds the app for production to the build folder. It correctly bundles React in production mode and optimizes the build for the best performance.

The build is minified and the filenames include a hash value of the content.