Jump to content
Search Community

chriswyl

Members
  • Posts

    23
  • Joined

  • Last visited

Posts posted by chriswyl

  1. I've the <image element inner group id="A" . This group is inner another group id="B"

    the group "A" has attribute transform .

     

     transform="matrix(.997 .0745 -.0745 .997 97 -406)" Draggable FAIL  - this code was produced by Inkscape with optimization save option.

     

    Now when I want apply draggable to Image element, The group "B" is going far far away tranform matrix x and y about 16300px.

     

    When I changed to transform matrix group "A" like showed below ALL is working OK

     

     

    transform="matrix(0.997, 0.0745, -0.0745, 0.997, 97, -406)" Draggable OK 

     

    Maybe worth to detecting kind matrix deklaration.

     

     

     
     

  2. Hello,

     

    I'm trying to solve the problem.

     

    In this example , when I drag red box on to circle , the image is change in both element (rectangle and circle with photo).

    Second situation, problem, drag red box on circle , but little bit outer (in bounds circle). The image is change in the circle it should not do this.

    I know that hitTest gets a bounds of object.

     

    Maybe do you have some idea?

    See the Pen NqbBvd?editors=101 by amonk (@amonk) on CodePen

  3. Hello,

     

    I'm trying to resolve this problem.

     

    I've one "main" draggable element which includes 3 elements.

    One with litter "M" - using for moving main element, and second with 'gradient' (is draggable too) to change "crop".

    Last element greenbox is now not usable.

    I want drag main element only when I use yellow box with "M"

    But  when I drag 'green' element I don't need drag only this element without change position of all object.

    See the Pen dPaxXw by amonk (@amonk) on CodePen

  4. Hello,

     

    How can I update bounds attribute, without creating new instance?

     

     

     Draggable.create("#elmnt", {
            edgeResistance:1,
            force3d:false,
            bounds:{minX:-200, maxX:0, minY:-200, maxY:0},
            throwProps:true,
            type:"x,y"});
     
     
    It it would look like this ;)
     
    Draggable.update("#elmnt",{ bounds:{minX:-100, maxX:0, minY:-150, maxY:0}});
     
     
     
×
×
  • Create New...