OpenSlides/client
GabrielMeyer 76d760bd41 Replaces the old angular2tree with a custom drag&drop tree
Calculates the direction of the moving.

Finishes the moving of nodes in same level

Adds some style

Sets the padding dynamically

Adds placeholder depends on the horizontal movement

Set the placeholder at the correct place, so the user can see, where he will drop the moved node

Finishes moving of nodes

- Old parents change their option to expand.
- New parents change their option to expand.
- If the user moves a node between nodes with a higher level, the node will be moved to the next index with same or lower level.

Fixes the visibility of moved node

- If the new parent is not visible, the moved node will not be seen.

If the user moves an expanded node, the new parent should expanded, too, if it's not already.

Sending successfully data to the server

- Sorting the items

Handles moving nodes between parent and children

- If the user moves a node between a parent and its children, the children will be relinked to the moved node as their new parent.

Replaces the old `sorting-tree` to a new one

- The new `sorted-tree` replaces the old `sorting-tree`.
- The old package `angular-tree-component` was removed.
- The user will only see the buttons to save or cancel his changes, if he made changes.
- The buttons, that do not work currently, were removed.

Adds a guard to check if the user made changes.

- If the user made changes but he has not saved them, then there is a dialog that will prompt to ask for confirmation.

Before cancelling the changes the user has to confirm this.
2019-03-19 13:19:35 +01:00
..
e2e change the global prefix to "os" 2018-09-03 18:13:57 +02:00
src Replaces the old angular2tree with a custom drag&drop tree 2019-03-19 13:19:35 +01:00
.editorconfig cleanup and refractor code 2018-08-15 10:19:46 +02:00
.prettierrc Fixed style issues introduced with #4025 2018-11-22 09:52:24 +01:00
angular.json Update to angular 7.2.5 2019-02-20 13:13:34 +01:00
ngsw-config.json Use OpenSlides as Progressive Web App (PWA). 2019-01-17 15:58:05 +01:00
package.json Replaces the old angular2tree with a custom drag&drop tree 2019-03-19 13:19:35 +01:00
proxy.conf.json Revert rest fix for proxy.conf.json 2019-01-19 21:59:32 +01:00
README.md updating the compodoc run command 2018-09-03 12:05:01 +02:00
sed_replacements po2json-tempfix 2019-01-28 16:14:51 +01:00
tsconfig.json cleanup and refractor code 2018-08-15 10:19:46 +02:00
tslint.json cleanup and refractor code 2018-08-15 10:19:46 +02:00

OpenSlides 3 Client

Prototype application for OpenSlides 3.0 (Client). Currently under constant heavy maintenance.

Development Info

As an Angular project, Angular CLI is highly recommended to create components and services. See https://angular.io/guide/quickstart for details.

Contribution Info

Please respect the code-style defined in .editorconf and .pretierrc.

Code alignment should be automatically corrected by the pre-commit hooks. Adjust your editor to the .editorconfig to avoid surprises. See https://editorconfig.org/ for details.

Pre-Commit Hooks

Before commiting, new code will automatically be aligned to the definitions set in the .prettierrc. Furthermore, new code has to pass linting.

Our pre-commit hooks are: pretty-quick --staged and lint See package.json for details.

Documentation Info

The documentation can be generated by running npm run compodoc. A new web server will be started on http://localhost:8080 Once running, the documentation will be updated automatically.

You can run it on another port, with adding your local port after the command. If no port specified, it will try to use 8080.

Please document new code using JSDoc tags. See https://compodoc.app/guides/jsdoc-tags.html for details.

Development server

Run npm start for a development server. Navigate to http://localhost:4200/. The app will automatically reload if you change any of the source files.

A running OpenSlides (2.2 or higher) instance is expected on port 8000.

Start OpenSlides as usual using python manage.py start --no-browser --host 0.0.0.0

Translation

We are using ngx-translate for translation purposes. Use npm run extract to extract strings and update elements an with translation functions.

Language files can be found in /src/assets/i18n.