demo_index.html 31 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8"/>
  5. <title>iconfont Demo</title>
  6. <link rel="shortcut icon" href="//img.alicdn.com/imgextra/i4/O1CN01Z5paLz1O0zuCC7osS_!!6000000001644-55-tps-83-82.svg" type="image/x-icon"/>
  7. <link rel="icon" type="image/svg+xml" href="//img.alicdn.com/imgextra/i4/O1CN01Z5paLz1O0zuCC7osS_!!6000000001644-55-tps-83-82.svg"/>
  8. <link rel="stylesheet" href="https://g.alicdn.com/thx/cube/1.3.2/cube.min.css">
  9. <link rel="stylesheet" href="demo.css">
  10. <link rel="stylesheet" href="iconfont.css">
  11. <script src="iconfont.js"></script>
  12. <!-- jQuery -->
  13. <script src="https://a1.alicdn.com/oss/uploads/2018/12/26/7bfddb60-08e8-11e9-9b04-53e73bb6408b.js"></script>
  14. <!-- 代码高亮 -->
  15. <script src="https://a1.alicdn.com/oss/uploads/2018/12/26/a3f714d0-08e6-11e9-8a15-ebf944d7534c.js"></script>
  16. <style>
  17. .main .logo {
  18. margin-top: 0;
  19. height: auto;
  20. }
  21. .main .logo a {
  22. display: flex;
  23. align-items: center;
  24. }
  25. .main .logo .sub-title {
  26. margin-left: 0.5em;
  27. font-size: 22px;
  28. color: #fff;
  29. background: linear-gradient(-45deg, #3967FF, #B500FE);
  30. -webkit-background-clip: text;
  31. -webkit-text-fill-color: transparent;
  32. }
  33. </style>
  34. </head>
  35. <body>
  36. <div class="main">
  37. <h1 class="logo"><a href="https://www.iconfont.cn/" title="iconfont 首页" target="_blank">
  38. <img width="200" src="https://img.alicdn.com/imgextra/i3/O1CN01Mn65HV1FfSEzR6DKv_!!6000000000514-55-tps-228-59.svg">
  39. </a></h1>
  40. <div class="nav-tabs">
  41. <ul id="tabs" class="dib-box">
  42. <li class="dib active"><span>Unicode</span></li>
  43. <li class="dib"><span>Font class</span></li>
  44. <li class="dib"><span>Symbol</span></li>
  45. </ul>
  46. <a href="https://www.iconfont.cn/manage/index?manage_type=myprojects&projectId=4304860" target="_blank" class="nav-more">查看项目</a>
  47. </div>
  48. <div class="tab-container">
  49. <div class="content unicode" style="display: block;">
  50. <ul class="icon_lists dib-box">
  51. <li class="dib">
  52. <span class="icon newicon">&#xe68b;</span>
  53. <div class="name">绑定</div>
  54. <div class="code-name">&amp;#xe68b;</div>
  55. </li>
  56. <li class="dib">
  57. <span class="icon newicon">&#xe633;</span>
  58. <div class="name">右箭头</div>
  59. <div class="code-name">&amp;#xe633;</div>
  60. </li>
  61. <li class="dib">
  62. <span class="icon newicon">&#xe661;</span>
  63. <div class="name">扫一扫</div>
  64. <div class="code-name">&amp;#xe661;</div>
  65. </li>
  66. <li class="dib">
  67. <span class="icon newicon">&#xe63d;</span>
  68. <div class="name">知识库</div>
  69. <div class="code-name">&amp;#xe63d;</div>
  70. </li>
  71. <li class="dib">
  72. <span class="icon newicon">&#xe634;</span>
  73. <div class="name">返回</div>
  74. <div class="code-name">&amp;#xe634;</div>
  75. </li>
  76. <li class="dib">
  77. <span class="icon newicon">&#xe660;</span>
  78. <div class="name">上传</div>
  79. <div class="code-name">&amp;#xe660;</div>
  80. </li>
  81. <li class="dib">
  82. <span class="icon newicon">&#xe60e;</span>
  83. <div class="name">下载</div>
  84. <div class="code-name">&amp;#xe60e;</div>
  85. </li>
  86. <li class="dib">
  87. <span class="icon newicon">&#xe640;</span>
  88. <div class="name">11</div>
  89. <div class="code-name">&amp;#xe640;</div>
  90. </li>
  91. <li class="dib">
  92. <span class="icon newicon">&#xe602;</span>
  93. <div class="name">下箭头</div>
  94. <div class="code-name">&amp;#xe602;</div>
  95. </li>
  96. <li class="dib">
  97. <span class="icon newicon">&#xe601;</span>
  98. <div class="name">3.1拍摄</div>
  99. <div class="code-name">&amp;#xe601;</div>
  100. </li>
  101. <li class="dib">
  102. <span class="icon newicon">&#xe6a0;</span>
  103. <div class="name">录制管理</div>
  104. <div class="code-name">&amp;#xe6a0;</div>
  105. </li>
  106. <li class="dib">
  107. <span class="icon newicon">&#xe621;</span>
  108. <div class="name">知识库</div>
  109. <div class="code-name">&amp;#xe621;</div>
  110. </li>
  111. <li class="dib">
  112. <span class="icon newicon">&#xe689;</span>
  113. <div class="name">快速报修</div>
  114. <div class="code-name">&amp;#xe689;</div>
  115. </li>
  116. <li class="dib">
  117. <span class="icon newicon">&#xe6cf;</span>
  118. <div class="name">暂无</div>
  119. <div class="code-name">&amp;#xe6cf;</div>
  120. </li>
  121. <li class="dib">
  122. <span class="icon newicon">&#xe717;</span>
  123. <div class="name">选择角标</div>
  124. <div class="code-name">&amp;#xe717;</div>
  125. </li>
  126. <li class="dib">
  127. <span class="icon newicon">&#xe6da;</span>
  128. <div class="name">公告</div>
  129. <div class="code-name">&amp;#xe6da;</div>
  130. </li>
  131. <li class="dib">
  132. <span class="icon newicon">&#xe655;</span>
  133. <div class="name">bitian</div>
  134. <div class="code-name">&amp;#xe655;</div>
  135. </li>
  136. <li class="dib">
  137. <span class="icon newicon">&#xe66d;</span>
  138. <div class="name">资源 2-wode</div>
  139. <div class="code-name">&amp;#xe66d;</div>
  140. </li>
  141. <li class="dib">
  142. <span class="icon newicon">&#xe66e;</span>
  143. <div class="name">资源 1-zhuye</div>
  144. <div class="code-name">&amp;#xe66e;</div>
  145. </li>
  146. <li class="dib">
  147. <span class="icon newicon">&#xe66f;</span>
  148. <div class="name">资源 2-baoxiu</div>
  149. <div class="code-name">&amp;#xe66f;</div>
  150. </li>
  151. <li class="dib">
  152. <span class="icon newicon">&#xe670;</span>
  153. <div class="name">资源 1-baoxiu</div>
  154. <div class="code-name">&amp;#xe670;</div>
  155. </li>
  156. <li class="dib">
  157. <span class="icon newicon">&#xe600;</span>
  158. <div class="name">3.1选中</div>
  159. <div class="code-name">&amp;#xe600;</div>
  160. </li>
  161. <li class="dib">
  162. <span class="icon newicon">&#xe63a;</span>
  163. <div class="name">修改</div>
  164. <div class="code-name">&amp;#xe63a;</div>
  165. </li>
  166. <li class="dib">
  167. <span class="icon newicon">&#xe610;</span>
  168. <div class="name">主页</div>
  169. <div class="code-name">&amp;#xe610;</div>
  170. </li>
  171. <li class="dib">
  172. <span class="icon newicon">&#xe66c;</span>
  173. <div class="name">资源 1-wode</div>
  174. <div class="code-name">&amp;#xe66c;</div>
  175. </li>
  176. <li class="dib">
  177. <span class="icon newicon">&#xe65c;</span>
  178. <div class="name">筛选</div>
  179. <div class="code-name">&amp;#xe65c;</div>
  180. </li>
  181. <li class="dib">
  182. <span class="icon newicon">&#xe638;</span>
  183. <div class="name">消息管理</div>
  184. <div class="code-name">&amp;#xe638;</div>
  185. </li>
  186. <li class="dib">
  187. <span class="icon newicon">&#xe673;</span>
  188. <div class="name">新建 (1)</div>
  189. <div class="code-name">&amp;#xe673;</div>
  190. </li>
  191. <li class="dib">
  192. <span class="icon newicon">&#xe606;</span>
  193. <div class="name">图片</div>
  194. <div class="code-name">&amp;#xe606;</div>
  195. </li>
  196. <li class="dib">
  197. <span class="icon newicon">&#xe609;</span>
  198. <div class="name">设备巡检</div>
  199. <div class="code-name">&amp;#xe609;</div>
  200. </li>
  201. </ul>
  202. <div class="article markdown">
  203. <h2 id="unicode-">Unicode 引用</h2>
  204. <hr>
  205. <p>Unicode 是字体在网页端最原始的应用方式,特点是:</p>
  206. <ul>
  207. <li>支持按字体的方式去动态调整图标大小,颜色等等。</li>
  208. <li>默认情况下不支持多色,直接添加多色图标会自动去色。</li>
  209. </ul>
  210. <blockquote>
  211. <p>注意:新版 iconfont 支持两种方式引用多色图标:SVG symbol 引用方式和彩色字体图标模式。(使用彩色字体图标需要在「编辑项目」中开启「彩色」选项后并重新生成。)</p>
  212. </blockquote>
  213. <p>Unicode 使用步骤如下:</p>
  214. <h3 id="-font-face">第一步:拷贝项目下面生成的 <code>@font-face</code></h3>
  215. <pre><code class="language-css"
  216. >@font-face {
  217. font-family: 'newicon';
  218. src: url('iconfont.woff2?t=1741933729857') format('woff2'),
  219. url('iconfont.woff?t=1741933729857') format('woff'),
  220. url('iconfont.ttf?t=1741933729857') format('truetype');
  221. }
  222. </code></pre>
  223. <h3 id="-iconfont-">第二步:定义使用 iconfont 的样式</h3>
  224. <pre><code class="language-css"
  225. >.newicon {
  226. font-family: "newicon" !important;
  227. font-size: 16px;
  228. font-style: normal;
  229. -webkit-font-smoothing: antialiased;
  230. -moz-osx-font-smoothing: grayscale;
  231. }
  232. </code></pre>
  233. <h3 id="-">第三步:挑选相应图标并获取字体编码,应用于页面</h3>
  234. <pre>
  235. <code class="language-html"
  236. >&lt;span class="newicon"&gt;&amp;#x33;&lt;/span&gt;
  237. </code></pre>
  238. <blockquote>
  239. <p>"newicon" 是你项目下的 font-family。可以通过编辑项目查看,默认是 "iconfont"。</p>
  240. </blockquote>
  241. </div>
  242. </div>
  243. <div class="content font-class">
  244. <ul class="icon_lists dib-box">
  245. <li class="dib">
  246. <span class="icon newicon newicon-bangding"></span>
  247. <div class="name">
  248. 绑定
  249. </div>
  250. <div class="code-name">.newicon-bangding
  251. </div>
  252. </li>
  253. <li class="dib">
  254. <span class="icon newicon newicon-youjiantou"></span>
  255. <div class="name">
  256. 右箭头
  257. </div>
  258. <div class="code-name">.newicon-youjiantou
  259. </div>
  260. </li>
  261. <li class="dib">
  262. <span class="icon newicon newicon-saoma"></span>
  263. <div class="name">
  264. 扫一扫
  265. </div>
  266. <div class="code-name">.newicon-saoma
  267. </div>
  268. </li>
  269. <li class="dib">
  270. <span class="icon newicon newicon-zhishiku1"></span>
  271. <div class="name">
  272. 知识库
  273. </div>
  274. <div class="code-name">.newicon-zhishiku1
  275. </div>
  276. </li>
  277. <li class="dib">
  278. <span class="icon newicon newicon-fanhui1"></span>
  279. <div class="name">
  280. 返回
  281. </div>
  282. <div class="code-name">.newicon-fanhui1
  283. </div>
  284. </li>
  285. <li class="dib">
  286. <span class="icon newicon newicon-shangchuan"></span>
  287. <div class="name">
  288. 上传
  289. </div>
  290. <div class="code-name">.newicon-shangchuan
  291. </div>
  292. </li>
  293. <li class="dib">
  294. <span class="icon newicon newicon-xiazai"></span>
  295. <div class="name">
  296. 下载
  297. </div>
  298. <div class="code-name">.newicon-xiazai
  299. </div>
  300. </li>
  301. <li class="dib">
  302. <span class="icon newicon newicon-icon-test"></span>
  303. <div class="name">
  304. 11
  305. </div>
  306. <div class="code-name">.newicon-icon-test
  307. </div>
  308. </li>
  309. <li class="dib">
  310. <span class="icon newicon newicon-xiajiantou"></span>
  311. <div class="name">
  312. 下箭头
  313. </div>
  314. <div class="code-name">.newicon-xiajiantou
  315. </div>
  316. </li>
  317. <li class="dib">
  318. <span class="icon newicon newicon-31paishe"></span>
  319. <div class="name">
  320. 3.1拍摄
  321. </div>
  322. <div class="code-name">.newicon-31paishe
  323. </div>
  324. </li>
  325. <li class="dib">
  326. <span class="icon newicon newicon-luzhiguanli"></span>
  327. <div class="name">
  328. 录制管理
  329. </div>
  330. <div class="code-name">.newicon-luzhiguanli
  331. </div>
  332. </li>
  333. <li class="dib">
  334. <span class="icon newicon newicon-zhishiku"></span>
  335. <div class="name">
  336. 知识库
  337. </div>
  338. <div class="code-name">.newicon-zhishiku
  339. </div>
  340. </li>
  341. <li class="dib">
  342. <span class="icon newicon newicon-kuaisubaoxiu"></span>
  343. <div class="name">
  344. 快速报修
  345. </div>
  346. <div class="code-name">.newicon-kuaisubaoxiu
  347. </div>
  348. </li>
  349. <li class="dib">
  350. <span class="icon newicon newicon-zanwu"></span>
  351. <div class="name">
  352. 暂无
  353. </div>
  354. <div class="code-name">.newicon-zanwu
  355. </div>
  356. </li>
  357. <li class="dib">
  358. <span class="icon newicon newicon-xuanzejiaobiao"></span>
  359. <div class="name">
  360. 选择角标
  361. </div>
  362. <div class="code-name">.newicon-xuanzejiaobiao
  363. </div>
  364. </li>
  365. <li class="dib">
  366. <span class="icon newicon newicon-gonggao"></span>
  367. <div class="name">
  368. 公告
  369. </div>
  370. <div class="code-name">.newicon-gonggao
  371. </div>
  372. </li>
  373. <li class="dib">
  374. <span class="icon newicon newicon-bitian"></span>
  375. <div class="name">
  376. bitian
  377. </div>
  378. <div class="code-name">.newicon-bitian
  379. </div>
  380. </li>
  381. <li class="dib">
  382. <span class="icon newicon newicon-ziyuan-wode1"></span>
  383. <div class="name">
  384. 资源 2-wode
  385. </div>
  386. <div class="code-name">.newicon-ziyuan-wode1
  387. </div>
  388. </li>
  389. <li class="dib">
  390. <span class="icon newicon newicon-ziyuan-zhuye"></span>
  391. <div class="name">
  392. 资源 1-zhuye
  393. </div>
  394. <div class="code-name">.newicon-ziyuan-zhuye
  395. </div>
  396. </li>
  397. <li class="dib">
  398. <span class="icon newicon newicon-ziyuan-baoxiu"></span>
  399. <div class="name">
  400. 资源 2-baoxiu
  401. </div>
  402. <div class="code-name">.newicon-ziyuan-baoxiu
  403. </div>
  404. </li>
  405. <li class="dib">
  406. <span class="icon newicon newicon-ziyuan-baoxiu1"></span>
  407. <div class="name">
  408. 资源 1-baoxiu
  409. </div>
  410. <div class="code-name">.newicon-ziyuan-baoxiu1
  411. </div>
  412. </li>
  413. <li class="dib">
  414. <span class="icon newicon newicon-31xuanzhong"></span>
  415. <div class="name">
  416. 3.1选中
  417. </div>
  418. <div class="code-name">.newicon-31xuanzhong
  419. </div>
  420. </li>
  421. <li class="dib">
  422. <span class="icon newicon newicon-weibiaoti2010104"></span>
  423. <div class="name">
  424. 修改
  425. </div>
  426. <div class="code-name">.newicon-weibiaoti2010104
  427. </div>
  428. </li>
  429. <li class="dib">
  430. <span class="icon newicon newicon-zhuye"></span>
  431. <div class="name">
  432. 主页
  433. </div>
  434. <div class="code-name">.newicon-zhuye
  435. </div>
  436. </li>
  437. <li class="dib">
  438. <span class="icon newicon newicon-ziyuan-wode"></span>
  439. <div class="name">
  440. 资源 1-wode
  441. </div>
  442. <div class="code-name">.newicon-ziyuan-wode
  443. </div>
  444. </li>
  445. <li class="dib">
  446. <span class="icon newicon newicon-shaixuan"></span>
  447. <div class="name">
  448. 筛选
  449. </div>
  450. <div class="code-name">.newicon-shaixuan
  451. </div>
  452. </li>
  453. <li class="dib">
  454. <span class="icon newicon newicon-xiaoxiguanli"></span>
  455. <div class="name">
  456. 消息管理
  457. </div>
  458. <div class="code-name">.newicon-xiaoxiguanli
  459. </div>
  460. </li>
  461. <li class="dib">
  462. <span class="icon newicon newicon-xinjian2"></span>
  463. <div class="name">
  464. 新建 (1)
  465. </div>
  466. <div class="code-name">.newicon-xinjian2
  467. </div>
  468. </li>
  469. <li class="dib">
  470. <span class="icon newicon newicon-a-11111"></span>
  471. <div class="name">
  472. 图片
  473. </div>
  474. <div class="code-name">.newicon-a-11111
  475. </div>
  476. </li>
  477. <li class="dib">
  478. <span class="icon newicon newicon-shebeixunjian"></span>
  479. <div class="name">
  480. 设备巡检
  481. </div>
  482. <div class="code-name">.newicon-shebeixunjian
  483. </div>
  484. </li>
  485. </ul>
  486. <div class="article markdown">
  487. <h2 id="font-class-">font-class 引用</h2>
  488. <hr>
  489. <p>font-class 是 Unicode 使用方式的一种变种,主要是解决 Unicode 书写不直观,语意不明确的问题。</p>
  490. <p>与 Unicode 使用方式相比,具有如下特点:</p>
  491. <ul>
  492. <li>相比于 Unicode 语意明确,书写更直观。可以很容易分辨这个 icon 是什么。</li>
  493. <li>因为使用 class 来定义图标,所以当要替换图标时,只需要修改 class 里面的 Unicode 引用。</li>
  494. </ul>
  495. <p>使用步骤如下:</p>
  496. <h3 id="-fontclass-">第一步:引入项目下面生成的 fontclass 代码:</h3>
  497. <pre><code class="language-html">&lt;link rel="stylesheet" href="./iconfont.css"&gt;
  498. </code></pre>
  499. <h3 id="-">第二步:挑选相应图标并获取类名,应用于页面:</h3>
  500. <pre><code class="language-html">&lt;span class="newicon newicon-xxx"&gt;&lt;/span&gt;
  501. </code></pre>
  502. <blockquote>
  503. <p>"
  504. newicon" 是你项目下的 font-family。可以通过编辑项目查看,默认是 "iconfont"。</p>
  505. </blockquote>
  506. </div>
  507. </div>
  508. <div class="content symbol">
  509. <ul class="icon_lists dib-box">
  510. <li class="dib">
  511. <svg class="icon svg-icon" aria-hidden="true">
  512. <use xlink:href="#newicon-bangding"></use>
  513. </svg>
  514. <div class="name">绑定</div>
  515. <div class="code-name">#newicon-bangding</div>
  516. </li>
  517. <li class="dib">
  518. <svg class="icon svg-icon" aria-hidden="true">
  519. <use xlink:href="#newicon-youjiantou"></use>
  520. </svg>
  521. <div class="name">右箭头</div>
  522. <div class="code-name">#newicon-youjiantou</div>
  523. </li>
  524. <li class="dib">
  525. <svg class="icon svg-icon" aria-hidden="true">
  526. <use xlink:href="#newicon-saoma"></use>
  527. </svg>
  528. <div class="name">扫一扫</div>
  529. <div class="code-name">#newicon-saoma</div>
  530. </li>
  531. <li class="dib">
  532. <svg class="icon svg-icon" aria-hidden="true">
  533. <use xlink:href="#newicon-zhishiku1"></use>
  534. </svg>
  535. <div class="name">知识库</div>
  536. <div class="code-name">#newicon-zhishiku1</div>
  537. </li>
  538. <li class="dib">
  539. <svg class="icon svg-icon" aria-hidden="true">
  540. <use xlink:href="#newicon-fanhui1"></use>
  541. </svg>
  542. <div class="name">返回</div>
  543. <div class="code-name">#newicon-fanhui1</div>
  544. </li>
  545. <li class="dib">
  546. <svg class="icon svg-icon" aria-hidden="true">
  547. <use xlink:href="#newicon-shangchuan"></use>
  548. </svg>
  549. <div class="name">上传</div>
  550. <div class="code-name">#newicon-shangchuan</div>
  551. </li>
  552. <li class="dib">
  553. <svg class="icon svg-icon" aria-hidden="true">
  554. <use xlink:href="#newicon-xiazai"></use>
  555. </svg>
  556. <div class="name">下载</div>
  557. <div class="code-name">#newicon-xiazai</div>
  558. </li>
  559. <li class="dib">
  560. <svg class="icon svg-icon" aria-hidden="true">
  561. <use xlink:href="#newicon-icon-test"></use>
  562. </svg>
  563. <div class="name">11</div>
  564. <div class="code-name">#newicon-icon-test</div>
  565. </li>
  566. <li class="dib">
  567. <svg class="icon svg-icon" aria-hidden="true">
  568. <use xlink:href="#newicon-xiajiantou"></use>
  569. </svg>
  570. <div class="name">下箭头</div>
  571. <div class="code-name">#newicon-xiajiantou</div>
  572. </li>
  573. <li class="dib">
  574. <svg class="icon svg-icon" aria-hidden="true">
  575. <use xlink:href="#newicon-31paishe"></use>
  576. </svg>
  577. <div class="name">3.1拍摄</div>
  578. <div class="code-name">#newicon-31paishe</div>
  579. </li>
  580. <li class="dib">
  581. <svg class="icon svg-icon" aria-hidden="true">
  582. <use xlink:href="#newicon-luzhiguanli"></use>
  583. </svg>
  584. <div class="name">录制管理</div>
  585. <div class="code-name">#newicon-luzhiguanli</div>
  586. </li>
  587. <li class="dib">
  588. <svg class="icon svg-icon" aria-hidden="true">
  589. <use xlink:href="#newicon-zhishiku"></use>
  590. </svg>
  591. <div class="name">知识库</div>
  592. <div class="code-name">#newicon-zhishiku</div>
  593. </li>
  594. <li class="dib">
  595. <svg class="icon svg-icon" aria-hidden="true">
  596. <use xlink:href="#newicon-kuaisubaoxiu"></use>
  597. </svg>
  598. <div class="name">快速报修</div>
  599. <div class="code-name">#newicon-kuaisubaoxiu</div>
  600. </li>
  601. <li class="dib">
  602. <svg class="icon svg-icon" aria-hidden="true">
  603. <use xlink:href="#newicon-zanwu"></use>
  604. </svg>
  605. <div class="name">暂无</div>
  606. <div class="code-name">#newicon-zanwu</div>
  607. </li>
  608. <li class="dib">
  609. <svg class="icon svg-icon" aria-hidden="true">
  610. <use xlink:href="#newicon-xuanzejiaobiao"></use>
  611. </svg>
  612. <div class="name">选择角标</div>
  613. <div class="code-name">#newicon-xuanzejiaobiao</div>
  614. </li>
  615. <li class="dib">
  616. <svg class="icon svg-icon" aria-hidden="true">
  617. <use xlink:href="#newicon-gonggao"></use>
  618. </svg>
  619. <div class="name">公告</div>
  620. <div class="code-name">#newicon-gonggao</div>
  621. </li>
  622. <li class="dib">
  623. <svg class="icon svg-icon" aria-hidden="true">
  624. <use xlink:href="#newicon-bitian"></use>
  625. </svg>
  626. <div class="name">bitian</div>
  627. <div class="code-name">#newicon-bitian</div>
  628. </li>
  629. <li class="dib">
  630. <svg class="icon svg-icon" aria-hidden="true">
  631. <use xlink:href="#newicon-ziyuan-wode1"></use>
  632. </svg>
  633. <div class="name">资源 2-wode</div>
  634. <div class="code-name">#newicon-ziyuan-wode1</div>
  635. </li>
  636. <li class="dib">
  637. <svg class="icon svg-icon" aria-hidden="true">
  638. <use xlink:href="#newicon-ziyuan-zhuye"></use>
  639. </svg>
  640. <div class="name">资源 1-zhuye</div>
  641. <div class="code-name">#newicon-ziyuan-zhuye</div>
  642. </li>
  643. <li class="dib">
  644. <svg class="icon svg-icon" aria-hidden="true">
  645. <use xlink:href="#newicon-ziyuan-baoxiu"></use>
  646. </svg>
  647. <div class="name">资源 2-baoxiu</div>
  648. <div class="code-name">#newicon-ziyuan-baoxiu</div>
  649. </li>
  650. <li class="dib">
  651. <svg class="icon svg-icon" aria-hidden="true">
  652. <use xlink:href="#newicon-ziyuan-baoxiu1"></use>
  653. </svg>
  654. <div class="name">资源 1-baoxiu</div>
  655. <div class="code-name">#newicon-ziyuan-baoxiu1</div>
  656. </li>
  657. <li class="dib">
  658. <svg class="icon svg-icon" aria-hidden="true">
  659. <use xlink:href="#newicon-31xuanzhong"></use>
  660. </svg>
  661. <div class="name">3.1选中</div>
  662. <div class="code-name">#newicon-31xuanzhong</div>
  663. </li>
  664. <li class="dib">
  665. <svg class="icon svg-icon" aria-hidden="true">
  666. <use xlink:href="#newicon-weibiaoti2010104"></use>
  667. </svg>
  668. <div class="name">修改</div>
  669. <div class="code-name">#newicon-weibiaoti2010104</div>
  670. </li>
  671. <li class="dib">
  672. <svg class="icon svg-icon" aria-hidden="true">
  673. <use xlink:href="#newicon-zhuye"></use>
  674. </svg>
  675. <div class="name">主页</div>
  676. <div class="code-name">#newicon-zhuye</div>
  677. </li>
  678. <li class="dib">
  679. <svg class="icon svg-icon" aria-hidden="true">
  680. <use xlink:href="#newicon-ziyuan-wode"></use>
  681. </svg>
  682. <div class="name">资源 1-wode</div>
  683. <div class="code-name">#newicon-ziyuan-wode</div>
  684. </li>
  685. <li class="dib">
  686. <svg class="icon svg-icon" aria-hidden="true">
  687. <use xlink:href="#newicon-shaixuan"></use>
  688. </svg>
  689. <div class="name">筛选</div>
  690. <div class="code-name">#newicon-shaixuan</div>
  691. </li>
  692. <li class="dib">
  693. <svg class="icon svg-icon" aria-hidden="true">
  694. <use xlink:href="#newicon-xiaoxiguanli"></use>
  695. </svg>
  696. <div class="name">消息管理</div>
  697. <div class="code-name">#newicon-xiaoxiguanli</div>
  698. </li>
  699. <li class="dib">
  700. <svg class="icon svg-icon" aria-hidden="true">
  701. <use xlink:href="#newicon-xinjian2"></use>
  702. </svg>
  703. <div class="name">新建 (1)</div>
  704. <div class="code-name">#newicon-xinjian2</div>
  705. </li>
  706. <li class="dib">
  707. <svg class="icon svg-icon" aria-hidden="true">
  708. <use xlink:href="#newicon-a-11111"></use>
  709. </svg>
  710. <div class="name">图片</div>
  711. <div class="code-name">#newicon-a-11111</div>
  712. </li>
  713. <li class="dib">
  714. <svg class="icon svg-icon" aria-hidden="true">
  715. <use xlink:href="#newicon-shebeixunjian"></use>
  716. </svg>
  717. <div class="name">设备巡检</div>
  718. <div class="code-name">#newicon-shebeixunjian</div>
  719. </li>
  720. </ul>
  721. <div class="article markdown">
  722. <h2 id="symbol-">Symbol 引用</h2>
  723. <hr>
  724. <p>这是一种全新的使用方式,应该说这才是未来的主流,也是平台目前推荐的用法。相关介绍可以参考这篇<a href="">文章</a>
  725. 这种用法其实是做了一个 SVG 的集合,与另外两种相比具有如下特点:</p>
  726. <ul>
  727. <li>支持多色图标了,不再受单色限制。</li>
  728. <li>通过一些技巧,支持像字体那样,通过 <code>font-size</code>, <code>color</code> 来调整样式。</li>
  729. <li>兼容性较差,支持 IE9+,及现代浏览器。</li>
  730. <li>浏览器渲染 SVG 的性能一般,还不如 png。</li>
  731. </ul>
  732. <p>使用步骤如下:</p>
  733. <h3 id="-symbol-">第一步:引入项目下面生成的 symbol 代码:</h3>
  734. <pre><code class="language-html">&lt;script src="./iconfont.js"&gt;&lt;/script&gt;
  735. </code></pre>
  736. <h3 id="-css-">第二步:加入通用 CSS 代码(引入一次就行):</h3>
  737. <pre><code class="language-html">&lt;style&gt;
  738. .icon {
  739. width: 1em;
  740. height: 1em;
  741. vertical-align: -0.15em;
  742. fill: currentColor;
  743. overflow: hidden;
  744. }
  745. &lt;/style&gt;
  746. </code></pre>
  747. <h3 id="-">第三步:挑选相应图标并获取类名,应用于页面:</h3>
  748. <pre><code class="language-html">&lt;svg class="icon" aria-hidden="true"&gt;
  749. &lt;use xlink:href="#icon-xxx"&gt;&lt;/use&gt;
  750. &lt;/svg&gt;
  751. </code></pre>
  752. </div>
  753. </div>
  754. </div>
  755. </div>
  756. <script>
  757. $(document).ready(function () {
  758. $('.tab-container .content:first').show()
  759. $('#tabs li').click(function (e) {
  760. var tabContent = $('.tab-container .content')
  761. var index = $(this).index()
  762. if ($(this).hasClass('active')) {
  763. return
  764. } else {
  765. $('#tabs li').removeClass('active')
  766. $(this).addClass('active')
  767. tabContent.hide().eq(index).fadeIn()
  768. }
  769. })
  770. })
  771. </script>
  772. </body>
  773. </html>