官网链接 <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Document</title> <script type="text/javascript" src="http://wheelnavjs.softwaretailoring.net/js/raphael.min.js"></script> <script type="text/javascript" src="http://wheelnavjs.softwaretailoring.net/js/wheelnav.min.js"></script> <style type="text/css"> #divWheel{width: 300px;height: 300px;} </style> </head> <body> <div id="divWheel" data-wheelnav data-wheelnav-colors="#E34C26,#F06529" data-wheelnav-slicepath="DonutSlice" data-wheelnav-navangle="30" data-wheelnav-init> <div data-wheelnav-navitemtext=""></div> <div data-wheelnav-navitemtext=""></div> <div data-wheelnav-navitemtext=""></div> <div data-wheelnav-navitemtext=""></div> <div data-wheelnav-navitemtext=""></div> <div data-wheelnav-navitemtext=""></div> </div> <script type="text/javascript"> window.onload = function(){ var wheel = new wheelnav("divWheel"); wheel.navItems[1].slicePathFunction = slicePath().PieSlice; wheel.navItems[3].slicePathFunction = slicePath().PieSlice; wheel.navItems[5].slicePathFunction = slicePath().PieSlice; wheel.createWheel(); } </script> </body> </html> 提示:你可以先修改部分代码再运行。 转载请注明:有爱前端 » wheelnav.js笔记 喜欢 (0)or分享 (0)