[英]fallback for jquery isotope if javascript is disabled?
Is there a fallback for jQuery isotope if JavaScript is disabled? 如果JavaScript被禁用,是否有jQuery同位素的后备?
Suppose if I m using there fitColumns property, is there a fallback to that layout style if JavaScript is disabled, like what u have in d new myspace . 假设我在那里使用了fitColumns属性,如果禁用了JavaScript,那么是否会回退到该布局样式,就像你在新的myspace中所拥有的那样。
the initial posts, which appears on your myspace home page, will be styled properly but no additional post will load when you further scroll. 显示在您的myspace主页上的初始帖子将被正确设置样式,但是当您进一步滚动时不会加载其他帖子。
What kind of CSS structure or fallback methodology can be used for such situations? 什么样的CSS结构或回退方法可以用于这种情况?
If JavaScript is disabled and if you want to keep the elements positioned nicely like as if the jQuery Isotope is doing its job then you can only rely on CSS. 如果JavaScript被禁用,并且如果你想保持元素定位很好,就好像jQuery Isotope正在做它的工作那么你只能依赖CSS。 That would mean you would have to manually position those elements in the order that you want.
这意味着你必须按照你想要的顺序手动定位这些元素。
If you're OK with that then follow these steps below to start: 如果您对此没问题,请按照以下步骤开始:
off
. off
。 For example: <div id="isotope-container" class="isotope off">
<div id="isotope-container" class="isotope off">
.off
as one of the selectors. .off
作为选择器之一。 For example: .isotope.off .isotope-element-1 { position:absolute; top: 10px; left: 10px; }
.isotope.off .isotope-element-1 { position:absolute; top: 10px; left: 10px; }
.isotope.off .isotope-element-1 { position:absolute; top: 10px; left: 10px; }
.isotope.off .isotope-element-1 { position:absolute; top: 10px; left: 10px; }
.isotope.off .isotope-element-2 { position:absolute; top: 10px; left: 100px; }
.isotope.off .isotope-element-1 { position:absolute; top: 10px; left: 10px; }
.isotope.off .isotope-element-2 { position:absolute; top: 10px; left: 100px; }
.isotope.off .isotope-element-2 { position:absolute; top: 10px; left: 100px; }
.off
class exists and if it does, remove it. .off
类是否存在,如果存在,删除它。 For example: if($('#isotope-container.isotope').hasClass('off')){ $('#isotope-container.isotope').removeClass('off'); }
if($('#isotope-container.isotope').hasClass('off')){ $('#isotope-container.isotope').removeClass('off'); }
if($('#isotope-container.isotope').hasClass('off')){ $('#isotope-container.isotope').removeClass('off'); }
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.