fullPage.js icon indicating copy to clipboard operation
fullPage.js copied to clipboard

Can't select text by click-and-drag when using scrollOverflow

Open ryoarmanda opened this issue 8 years ago • 6 comments

Cannot select text by click-and-drag when scrollOverflow=true, the movement however drags the section. The problem does not reproduce when scrollOverflow=false. Selecting text by Ctrl-A or Shift-Arrow Key is still possible (only inside focus-able elements like <textarea>). Please make a fix on this.

Link to isolated reproduction with no external CSS / JS

https://jsfiddle.net/7f58uoyw/ (jQuery 3.1.1, fullPage.min.js 2.9.2, scrolloverflow.min.js 2.9.2)

Steps to reproduce it

Try to select any text by clicking and dragging the cursor.

Versions

Chrome Version 55.0.2883.87 m

ryoarmanda avatar Jan 06 '17 10:01 ryoarmanda

Try using the following fullPage.js option:

    scrollOverflowOptions: {
    	preventDefault: false
    },

Not sure of the consequences this might have on some devices, but let me know if you find any.

Demo online

alvarotrigo avatar Jan 06 '17 10:01 alvarotrigo

preventDefault: false didn't do it for me, and as you can see in your jsfiddle, it is pretty difficult to select multi-line text in the orange section.

scrollOverflowOptions: { disablePointer: true, }, however solved my particular problem.

magnussuther avatar Aug 06 '17 09:08 magnussuther

None of the aforementioned options exist anymore as of version 3.0.1. dragAndMove has been added and requires a license.

Are the easiest ways to select text w/ scrollOverflow just using an older version or buying a license?

EDIT: Because iscroll is now used, this is handled by setting scrollOverflowOptions: {preventDefault:false}

mikelui avatar Jul 14 '18 04:07 mikelui

None of the aforementioned options exist anymore as of version 3.0.1.

Sure they do. Those options are for iScroll, the vendor library used when using scrolloverflow, and therefore has nothing to do with the new fullPage.js version.

See this demo.

alvarotrigo avatar Jul 14 '18 09:07 alvarotrigo

dragAndMove has been added and requires a license.

Drag And Move has nothing to do with scrollOverflow. In fact, they are not fully compatible.

alvarotrigo avatar Jul 14 '18 09:07 alvarotrigo

@magnussuther Thank you man! you're a lifesaver)

Korveld avatar Dec 17 '20 15:12 Korveld