Comments (4)
i also have this problem when the page is first loaded. But when i reload it it works fine. But that is not how it should be. Not sure if i have done something wrong?
from readmore.js.
We have a similar problem in our application. Sometimes expanding "Read more" in a container with a smaller height can cause it to overflow and produce a scrollbar. The now reduced width of the container can in turn cause the text to resize. The plugin however does not account for that and a part of the text stays hidden, as can be seen on OP's screenshot.
It can also sometimes happen with applications that use lazy loading of data - when the plugin is initially loaded, the parent container doesn't have a scrollbar. However, when the data (e.g. comments) is later loaded and the container overflows, the plugin still uses the old width of the container, not accounting for the scrollbar. This can sometimes be demonstrated on this page, depending on the racing condition caused by lazy loading: http://scadattle.com/events/516cab3a3c5447400b000009
from readmore.js.
@bricealef I suspect that images for your social media links are throwing off Readmore's calculations; its calculating the height of that section before the images have loaded. I believe that this issue and #51 have similar root causes. I'm working on a 2.0 version that will call init()
inside a window load event callback, which should solve these issues.
@vdsabev I took a look at your link, and I'm not seeing the issue you describe, were you able to find a solution?
from readmore.js.
@jedfoster we worked around the issue by adding some extra padding to the bottom of the expanded section. Now that I think about it, it makes sense that the social media buttons at the bottom were the culprit. Hopefully your fix will solve the problem permanently, I'll let you know if there are any further issues. Thanks!
from readmore.js.
Related Issues (20)
- With jquery-3.1.1 animation not working HOT 5
- Read more not work if content has div tag HOT 1
- Can't use 3.0.0-beta-1 with Parcel HOT 1
- getBoundingClientRect needs to be parsed HOT 1
- v3.0.0-1 UglifyJs Error HOT 1
- Toggle should consider content changes applied within beforeToggle hook HOT 2
- Doesn't work?
- Not working on IE11 and EDGE with jQuery 3.3.1 HOT 1
- Hide readmore if text fits HOT 1
- What is the best way to import it in webpack HOT 2
- Any way to use this on content that's injected into the dom using JavaScript? HOT 2
- 2 vulnerabilities found
- Is there away to change the read more/less button tag HOT 1
- Link is created but not clickable on Galaxy a21s
- Tailwind support for max-h-[none]
- Version 3.0 HOT 1
- Undefined id prefix HOT 1
- More link over text (help) HOT 1
- How to have readmore return to a anchor
- Readmore can not working on tabs bootstrap HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from readmore.js.