JSmiles 2021-03-15 16:53:22
我去官方 github(https://github.com/DIYgod/DPlayer) 地址下载了 demo 查看,发现 css 样式是动态生成的,文章的内容有误,给您造成的困扰十分抱歉,现奉上 demo 示例:https://www.wenjiangs.com/wp-content/uploads/2021/03/dplayer-demo.zip
JSmiles 2020-03-29 20:14:10
下载地址:https://www.wenjiangs.com/wp-content/themes/wtheme-2020-03-29.rar
JSmiles 2019-04-10 13:39:03
全局安装 less 后 再安装一个插件 less-plugin-clean-css 命令为:npm install -g less-plugin-clean-css,每次保存的时候,改 less 文件会自动保存到当前目录下变成 .css 文件。
Jsmile 2018-05-30 15:57:04
安装 WP No Category Base 即可,我使用的其他插件可有可无,不影响主题的运行
Jsmile 2017-11-16 14:37:29
afterSlideLoad
用于判断滚动到某个幻灯片的回调函数,用法如下:
$('#fullpage').fullpage({
anchors: ['firstPage', 'secondPage', 'thirdPage', 'fourthPage', 'lastPage'],
afterSlideLoad: function( anchorLink, index, slideAnchor, slideIndex){
var loadedSlide = $(this);
//first slide of the second section
if(anchorLink == 'secondPage' && slideIndex == 1){
alert("First slide loaded");
}
//second slide of the second section (supposing #secondSlide is the
//anchor for the second slide
if(index == 2 && slideIndex == 'secondSlide'){
alert("Second slide loaded");
}
}
});
Jsmile 2017-11-16 14:27:54
当鼠标划入的时候,使用setAllowScrolling(false)方法取消掉fullpage的鼠标滑轮监听。当鼠标滑出的时候,重新添加监听器。
$('#demo').mouseover(function(){ $.fn.fullpage.setAllowScrolling(false); }).mouseout(function(){ $.fn.fullpage.setAllowScrolling(true); })
Jsmile 2017-11-06 15:38:06
引用 jquery.slimscroll.min.js
设置 scrollOverflow
为 true
,如果内容超出了屏幕,就会自动在右边出现拖动滑条。
用相同的方法在 Windows 下做了实践,与 MacOX 的不同主要有两个部分
update.json
update.json 格式参考如下:
install
指定更新包的地址。build 配置
package.json
中electron-builder
配置内容如下:Electron 实践之自动更新