Jump to content
Search Community

daveg

Members
  • Posts

    3
  • Joined

  • Last visited

Posts posted by daveg

  1. 1 hour ago, OSUblake said:

    If you want to set the starting zIndex, do this.

    
    Draggable.zIndex = 9099;

    https://greensock.com/docs/v2/Utilities/Draggable/zIndex

     

    You have zIndex boost to true, to it will keep adding 1 to that value every time you drag something.

    Okay, yes this works.  I had been setting it as a variable and it did not work that way.  But setting it as the Docs say (go figure) works.
    Thanks - thanks for setting me straight.

  2. 1 hour ago, OSUblake said:

    And this is incorrect syntax.

    
    this.draggableElems = new Draggable.create(droppables); // bad
    
    // for one element
    this.draggableElems = new Draggable(droppables);
    
    // for multiple elements
    this.draggableElems = Draggable.create(droppables);

    Thanks for the tip on this.

     

  3. Hi,

    I and setting the zIndex parameter of the draggable, but it does not seem to work.

    No matter what I do, the starting index stays at 1000.

    this.draggableElems = new Draggable.create(droppables, {
          bounds: this.container.nativeElement,
          edgeResistance: 0.65,
          type: 'x,y',
          throwProps: true,
          liveSnap: false,
          zIndexBoost: true,
          zIndex: 9099,
      
      ETC

     

×
×
  • Create New...