Skip to content
Snippets Groups Projects
This project is mirrored from https://*****@github.com/iqb-berlin/verona-modules-aspect.git. Pull mirroring updated .
  1. Nov 20, 2022
    • rhenck's avatar
      [editor] Cleanup code · 29fc040b
      rhenck authored
      - Remove unused variable
      - Add typing
      29fc040b
    • rhenck's avatar
      [editor] Add control to allow element interaction · 596a70c1
      rhenck authored
      - Part of the properties panel for every element (like delete and 
      duplicate)
      - This allows interacting with elements, generating events and inpect 
      their usage. Usually this is unwanted since it might interfere with 
      dragging the overlay, but sometimes you want to get a feel for the 
      element or check it's contents (GeoGebra for example)
      596a70c1
  2. Sep 21, 2022
  3. Aug 10, 2022
  4. Aug 01, 2022
  5. Jun 03, 2022
  6. May 17, 2022
    • rhenck's avatar
      Refactor model interfaces to classes · 2e9be6e9
      rhenck authored
      This way elements can handle their logic themselves without having to
      rely on outside utility classes.
      
      Also restructure files in common in a more logical way.
      2e9be6e9
  7. May 05, 2022
  8. Apr 14, 2022
  9. Mar 23, 2022
  10. Feb 17, 2022
    • rhenck's avatar
      Rework models from classes to interfaces · f416ce14
      rhenck authored
      This removes all the classes and goes back to simple interfaces for
      unit, pages etc and all elements. This makes creating them easier and
      cleaner.
      Things like specific needs when setting element properties and most
      importantly compatibility handling is done by a special service module,
      that knows all the elements and how to repair old their potentially
      outdated definitions.
      f416ce14
  11. Jan 22, 2022
  12. Jan 20, 2022
    • rhenck's avatar
      Make cloze element children not directly clickable · 0493fd04
      rhenck authored
      Only the overlay can be clicked. This way the statre of the elements can 
      not be changed which might be confused for actual value changes. Those 
      can still only be done via properties panel.
      
      Unfortunately we need another variable so the cloze elements knows when 
      it runs in the editor or not.
      0493fd04
  13. Jan 19, 2022
    • rhenck's avatar
      Rework compound child components · 87effdf7
      rhenck authored
      Compound elements are now supposed to use overlays for their child
      elements. This overlay makes selecting child components (by clicking on
      them) and marking them as selected (done by the selection service)
      possible.
      The SelectionService no longer needs special logic to handle compound
      children selection, as they now also have an overlay with the same
      interface as normal (canvas) elements.
      
      A few modifications in connected directives are necessary. The now
      handle children components in a proper array instead of QueryList.
      
      Likert elements do not have clickable children yet and work a little
      differently. This should probably be unitized in the future.
      87effdf7
  14. Dec 10, 2021
  15. Dec 07, 2021
    • rhenck's avatar
      Improve code style · 9acf89b3
      rhenck authored
      9acf89b3
    • rhenck's avatar
      [editor] Add section element list · af1b9ad7
      rhenck authored
      This allows to select elements without clicking them on the canvas, as 
      elements may be obstructed or not visible for some reason.
      
      The selection logic is a bit complicated because usually only the 
      overlay components are usd for selection which are also the place to 
      apply any highlighting on. Here we have to find the component element 
      reference from the section. Therefore the double looping 
      'getElementComponent' method.
      
      Also when an elements is selected it briefly gets z-index 100 so it is 
      moved to the front and visible and manipulatable.
      af1b9ad7
  16. Nov 26, 2021
    • rhenck's avatar
      Refactor element class and interface structure · 4a413b60
      rhenck authored
      The problem being solved is that compound-sub-elements must not have
      all the properties other elements have. For exampe positioning info.
      Sub-Elements are positioned inline. To avoid having similar class
      inheritance structures for positioned and inline elements, we use
      interface. Positioning is done via interface and is therefore optional.
      
      Those optional properties are kept in an object in a variable. This
      allows to hide specifics from element classes and removes the need to
      initialize all the fields in every class using the interface.
      The elements mostly care about their own specific properties anyway.
      
      The same technique is used for font and surface elements. Here we also
      don't want to initialize all the styles in every class.
      
      Changing values of element properties works like before. Just set the
      property as if it would be a direkt prop of the element. The element
      itself puts the value in the currect sub-object (positioningProps,
      fontProps etc).
      
      For reading the values there is a similar method, but it is not used
      anywhere by now. Since the properties panel operates on the raw values
      anyway (refer CombinedProperties) and for element components this would
      mean calling a function in the template, which caused change detection
      to run the function very often and is therefore bad practice.
      
      Additional notes and refactorings:
      - Restructure all files in common. UIElements in the same folder etc.
      - Move all interfaces to the UIElement file. This avoids circular
        imports, which would be needed to allow PositionedElement to extend
        UIElement.
      - Interface initializers also handle reading values in the old form.
      - Add PositionedElement for use in canvas overlays. This is a UIElement
        with guaranteed postionProps.
      - Don't export all Material packages from common, only the ones
        used in player and editor. The rest is only used in common and
        does not need to be exported.
      4a413b60
  17. Nov 20, 2021
  18. Nov 19, 2021
  19. Nov 11, 2021
  20. Nov 10, 2021
    • rhenck's avatar
      Refactor elements to use the model's value · 373108a5
      rhenck authored
      This change mainly helps the editor.
      The idea is to make the element components have the correct value of
      their model and don't rely on the formcontrol value. The formcontrol
      can be hard to manipulate, especially in compound elements. Setting
      the model value is way easier.
      
      The formcontrols are kept and should not interfere.
      373108a5
  21. Oct 28, 2021
    • jojohoch's avatar
      Refactor form-element-component.directive.ts · 6c38e1c0
      jojohoch authored
      * Remove FormService Injection
      * Move FormService and form types to player
      * Move interface ValueChangeElement to uI-element.ts
      * Use interface InputElementValue instead of
      string | number | boolean | null
      6c38e1c0
  22. Oct 22, 2021
  23. Oct 18, 2021
    • rhenck's avatar
      [editor] Refactor directory structure · 9f65f0c9
      rhenck authored
      The main components are right at top level and the directories below
      mimic the data structure (unit->page->section).
      The toolbar is only used in dev mode and does not belong directly to the
      unit view.
      The TextEditor is a complex component and deserves it's own directory
      even though it is used within the unit-view. Might be refactored to its
      own module later.
      9f65f0c9
  24. Oct 17, 2021
    • rhenck's avatar
      [editor] Fix element deletion via Delete key · b2961b58
      rhenck authored
      This is now done via listener directly on the element overlay. The 
      overlay's div is made selectable with 'tabindex'. Then the key event is 
      caught and delete logic started. The actual logic did not change and 
      still deletes all selected elements not just the one catching the delete 
      key event.
      b2961b58
    • rhenck's avatar
      [editor] Make all elements unclickable, only the overlay · 148f82a8
      rhenck authored
      - This helps getting rid of annoying element interaction and solves some
        selection issues (for example double clicking text elements to bring
        up the editor). While creating units, the placement and properties of
        the elements are important and not interacting with the elements.
        This is what the preview/player is for.
      - This may also help with detecting selection for the Delete-key logic.
      148f82a8
  25. Oct 15, 2021
  26. Oct 14, 2021
  27. Oct 13, 2021
Loading