资源简介
Nifty Admin提供了丰富的模版组件,虽然基于Bootstrap,体积上略显臃肿,但功能非常强劲,界面上的设计感更是专业十足,可基本满足所有的后台需求
代码片段和文件信息
from subprocess import call
import os
import json
BUILDER_PATH = os.path.dirname(os.path.abspath(__file__))
ROOT_PATH = os.path.join(BUILDER_PATH ‘..‘)
FONTS_FOLDER_PATH = os.path.join(ROOT_PATH ‘fonts‘)
CSS_FOLDER_PATH = os.path.join(ROOT_PATH ‘css‘)
SCSS_FOLDER_PATH = os.path.join(ROOT_PATH ‘scss‘)
LESS_FOLDER_PATH = os.path.join(ROOT_PATH ‘less‘)
def main():
generate_font_files()
data = get_build_data()
rename_svg_glyph_names(data)
generate_scss(data)
generate_less(data)
generate_cheatsheet(data)
generate_component_json(data)
generate_composer_json(data)
generate_bower_json(data)
def generate_font_files():
print “Generate Fonts“
cmd = “fontforge -script %s/scripts/generate_font.py“ % (BUILDER_PATH)
call(cmd shell=True)
def rename_svg_glyph_names(data):
# hacky and slow (but safe) way to rename glyph-name attributes
svg_path = os.path.join(FONTS_FOLDER_PATH ‘ionicons.svg‘)
svg_file = open(svg_path ‘r+‘)
svg_text = svg_file.read()
svg_file.seek(0)
for ionicon in data[‘icons‘]:
# uniF2CA
org_name = ‘uni%s‘ % (ionicon[‘code‘].replace(‘0x‘ ‘‘).upper())
ion_name = ‘ion-%s‘ % (ionicon[‘name‘])
svg_text = svg_text.replace(org_name ion_name)
svg_file.write(svg_text)
svg_file.close()
def generate_less(data):
print “Generate LESS“
font_name = data[‘name‘]
font_version = data[‘version‘]
css_prefix = data[‘prefix‘]
variables_file_path = os.path.join(LESS_FOLDER_PATH ‘_ionicons-variables.less‘)
icons_file_path = os.path.join(LESS_FOLDER_PATH ‘_ionicons-icons.less‘)
d = []
d.append(‘/*!‘);
d.append(‘Ionicons v%s‘ % (font_version) );
d.append(‘Created by Ben Sperry for the Ionic framework http://ionicons.com/‘);
d.append(‘https://twitter.com/benjsperry https://twitter.com/ionicframework‘);
d.append(‘MIT License: https://github.com/driftyco/ionicons‘);
d.append(‘*/‘);
d.append(‘// Ionicons Variables‘)
d.append(‘// --------------------------\n‘)
d.append(‘@ionicons-font-path: “../fonts“;‘)
d.append(‘@ionicons-font-family: “%s“;‘ % (font_name) )
d.append(‘@ionicons-version: “%s“;‘ % (font_version) )
d.append(‘@ionicons-prefix: %s;‘ % (css_prefix) )
d.append(‘‘)
for ionicon in data[‘icons‘]:
chr_code = ionicon[‘code‘].replace(‘0x‘ ‘\\‘)
d.append(‘@ionicon-var-%s: “%s“;‘ % (ionicon[‘name‘] chr_code) )
f = open(variables_file_path ‘w‘)
f.write( ‘\n‘.join(d) )
f.close()
d = []
d.append(‘// Ionicons Icons‘)
d.append(‘// --------------------------\n‘)
group = [ ‘.%s‘ % (data[‘name‘].lower()) ]
for ionicon in data[‘icons‘]:
group.append(‘.@{ionicons-prefix}%s:before‘ % (ionicon[‘name‘]) )
d.append( ‘\n‘.join(group) )
d.append(‘{‘)
d.append(‘ &:extend(.ion);‘)
d.append(‘}‘)
for ionicon in data[‘icons‘]:
chr_code = ionicon[‘code‘].replace(‘0x‘ ‘\\‘)
d.append(‘.@{ionicons-prefix}%s:before { content: @ionicon-var-%s; }‘ % (ionicon[‘name‘] ionicon[‘name‘]) )
f = open(icons_file_path ‘w‘)
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2016-08-25 18:54 nifty\
目录 0 2016-06-21 07:35 nifty\demo\
文件 112924 2016-06-16 08:27 nifty\demo\charts.html
目录 0 2016-06-21 07:34 nifty\demo\css\
目录 0 2016-06-21 07:34 nifty\demo\css-preprocessors\
目录 0 2016-06-21 07:34 nifty\demo\css-preprocessors\less\
目录 0 2016-06-21 07:34 nifty\demo\css-preprocessors\less\nifty\
文件 969 2016-06-14 10:48 nifty\demo\css-preprocessors\less\nifty.less
文件 3720 2016-06-19 23:52 nifty\demo\css-preprocessors\less\nifty\_animations.less
文件 11144 2016-06-15 22:56 nifty\demo\css-preprocessors\less\nifty\_aside.less
文件 72165 2016-06-14 09:31 nifty\demo\css-preprocessors\less\nifty\_bs-overwrite.less
文件 62318 2016-06-16 04:10 nifty\demo\css-preprocessors\less\nifty\_extras.less
文件 953 2016-06-09 11:41 nifty\demo\css-preprocessors\less\nifty\_footer.less
文件 8352 2016-05-31 11:46 nifty\demo\css-preprocessors\less\nifty\_helper-classes.less
文件 13001 2016-06-16 04:15 nifty\demo\css-preprocessors\less\nifty\_layout.less
文件 22785 2016-06-19 23:47 nifty\demo\css-preprocessors\less\nifty\_mainnav.less
文件 7688 2016-06-16 05:50 nifty\demo\css-preprocessors\less\nifty\_navbar.less
目录 0 2016-06-21 07:34 nifty\demo\css-preprocessors\less\themes\
目录 0 2016-06-21 07:34 nifty\demo\css-preprocessors\less\themes\type-a\
文件 2072 2016-06-14 23:02 nifty\demo\css-preprocessors\less\themes\type-a\theme-coffee.less
文件 2073 2016-06-14 23:13 nifty\demo\css-preprocessors\less\themes\type-a\theme-dark.less
文件 2069 2016-06-14 23:13 nifty\demo\css-preprocessors\less\themes\type-a\theme-dust.less
文件 2033 2016-06-14 23:13 nifty\demo\css-preprocessors\less\themes\type-a\theme-light.less
文件 2073 2016-06-14 23:13 nifty\demo\css-preprocessors\less\themes\type-a\theme-lime.less
文件 2081 2016-06-14 23:14 nifty\demo\css-preprocessors\less\themes\type-a\theme-mint.less
文件 2092 2016-06-14 23:14 nifty\demo\css-preprocessors\less\themes\type-a\theme-navy.less
文件 2073 2016-06-14 23:14 nifty\demo\css-preprocessors\less\themes\type-a\theme-ocean.less
文件 2073 2016-06-14 23:15 nifty\demo\css-preprocessors\less\themes\type-a\theme-prickly-pear.less
文件 2080 2016-06-14 23:15 nifty\demo\css-preprocessors\less\themes\type-a\theme-purple.less
文件 2080 2016-06-14 23:15 nifty\demo\css-preprocessors\less\themes\type-a\theme-well-red.less
文件 2098 2016-06-14 23:15 nifty\demo\css-preprocessors\less\themes\type-a\theme-yellow.less
............此处省略2198个文件信息
相关资源
- [FastVideo]Web Html5 无插件方式连接海康
- Web前端开发精品课 HTML与CSS进阶教程
- Word HTML Cleaner
- phantomjs html转pdf 完美版本
- Ace Admin V1.4.0 Bootstrap v3.3.6最新版
- 网页音乐播放器 html5 实验报告
- H+ 后台主题UI框架
- 京东网页代码
- Super Admin - Responsive Admin Template 后台管
- 李炎恢HTML5第一季讲义课件+代码超全
- 使用iText-2.0.8将Html转换为pdf,带图片
- html5的ppt课件及代码
- 一款HTML模板,非常适合做SEO
- 写个一个简单的web项目把前端技术:
- 李炎恢 xhtml 课程 素材源代码
- html5 汤姆猫
- 电商-书店基础版HTML静态页面
- 最新精美后台管理系统模版html源文件
- BOSS - Multipurpose Template
-
疯狂HTML5CSS3ja
vasc ript讲义_源码 - Html5代码_微信H5微场景10个)源码
- HTML大作业源码
- HTML5+CSS3网站设计基础教程 传智播客全
- 纯HTML+CSS的旅游网
- html静态网页导航条、表格、表单、音
- 电商网站前端页面
- xiaomi.zip
- html转pdf工具
- 15套HTML5微场景源码
- 简单的HTML我的家乡+doc文档
评论
共有 条评论