Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...

Xristi

SimplyGreen
  • Content Count

    44
  • Joined

  • Last visited

Community Reputation

10 Newbie

About Xristi

  • Rank
    storyproblemdoctor

Profile Information

  • Gender
    Female
  • Location
    Phoenix, AZ
  • Interests
    Intelligent Tutoring Systems, Interactive Instruction, Educational Psychology
  1. Never mind... found the list. Thank you anyway
  2. Hi, I want to use the ScrollToPlugin. As a SimplyGreen member is this available to me? If so, how do I download it (or make it available to my scripting efforts)?
  3. Yes... for sure. But the conflict exists in the larger page - not something I would expect anyone to dig through I'll just keep whittling away. If it does get down to a manageable codePen and I haven't found the problem I'll send a codePen at that point. Many thanks!!
  4. Thank you for your replies. Before including the DnD functionality (using draggable elements that are absolutely positioned in a relatively positioned grid) on the main page I created an abbreviated trial page. It works fine. When transferred to the main page, though, the hittest no longer fires even though all elements have identical id's and css properties. I just thought that there might be a scope issue with "this" as there is mention of onDragEndScope in the documentation but there is no "+" to click on for more information. Again, I am grateful for all of your help over the years but sending a minimal codePen wouldn't seem to help much... I'm in the process of comparing the two instances to find the anomaly causing the problem. Thanks again.
  5. Hello. I have 3 different grids containing the same elements in the same configuration. They occupy the same position on the page and their presentation is controlled through style.visibility (either visible or hidden) with none of the grids showing initially. I use Draggable functionality in which the draggable elements are positioned absolutely and the drop areas are positioned relatively. My trial version drag and drop hit-test works just fine but it has just one of the grids and it is visible from the start of the page presentation. The actual page described previously does not register the hit-test and the DnD element always returns to its home. I'm thinking perhaps scope for "this" needs to be defined but can't seem to find any documention on how to do it. I have tried "focus" on the grid presently showing but that didn't work. This is a Draggable create situation with "this.hitTest" and the drop area element has been thoroughly checked. Going on a day and half trying to figure it out. I'm learning by doing and most probably am missing a simple concept. I would be grateful for any ideas, information, or instruction.
  6. Hi, Thank you for your quick reply... I created a CodePen @ https://codepen.io/storyproblemdoctor/pen/JjjbjJE
  7. Hi Jack, I am changing from hit-testing a draggable to using the liveSnap referenced above (posted 09/24/2017 ~ not sure I should use the poster's name) with my drag and drop functionality. How would your script change if the draggable is required to move on both the x and y axis? I have created a page that approximates yours but uses a grid to put the draggable and the target in two different rows. Currently, when the draggable has snapped to the target it snaps back to the target when moved positively along the y axis, but if it is moved negatively (up) the draggable does not return to the target as long as its position is negative relative to the target - just sticks there. When moved on the x axis it will return to its "home".
  8. Hello Zach, I was able to arrive at a solution. Between your comments and OSUBlake's and Diaco's codepens for multiple drag objects and multiple targets I was able to piece together some code that worked. Thank you all for your time in helping all of us grateful GSAP users.
  9. Yes. I get the x/y coordinates but the the tween doesn't complete. When I put your "this.x..." in the onComplete function x/y comes back undefined. Why would the tween not complete? Some other part of my code must be wrong...
  10. What is the code to access the x/y properties of the object being dragged. I've seen the x/y property used but it's always referred to as element.x. How do you use dot syntax with a div object that has an ID?
  11. Will this give me the object's relative position within its stated bounds? Might you give me an example of its use in a Draggable function? Thank you!
  12. No, and thank you for your almost instantaneous response! I will do it now...
  13. Hi, I need to get the current position of a dragged object on the completion of its tweening to another location. Here is my code: Draggable.create("#firstNamedQuanDragImage1", {type:"x,y", bounds:"#nQL_DragDropGrid1", edgeResistance:0.5, cursor: "pointer", onDragEnd: function(e) { if (this.hitTest(dropAreasArray[0], overlapThreshold)) { TweenMax.to(this.target, 0.5, {x:ecksPos, y:wyePos, onComplete:resetPermissionsArray_Target}); //disAbleTiles2("2nd"); studentAnswer = "EXPRESSION"; removeCheckAnsButton1(false); function resetPermissionsArray_Target() { var firstTileLocus_X = $("#firstNamedQuanDragImage1").offset(); var firstTileLeft = firstTileLocus_X.left; alert("location of first tile is: " + firstTileLeft); } With this code I get the object location just fine but the tween ends and the object does not continue to its desired x/y position If I remove the the onComplete and its function the tweening completes just fine but, obviously, no position info on the object. Thank you for your invaluable assistance - I'm getting there!
  14. Thank you, Julius! I'll put it in my functions file - won't have to ask next time...
×