UNPKG

weex-nuke

Version:

基于 Rax 、Weex 的高性能组件体系 ~~

140 lines (132 loc) 3.1 kB
'use strict'; import { vLoader } from '../util/var-loader'; const fontFamilyBase = vLoader( 'Roboto, "Helvetica Neue", Helvetica, Tahoma, Arial, "PingFang SC", "Microsoft YaHei"' ); const fontSizeDisplay3 = vLoader(112); const fontSizeDisplay2 = vLoader(96); const fontSizeDisplay1 = vLoader(72); const fontSizeHeadline = vLoader(48, 40); const fontSizeTitle = vLoader(40, 34); const fontSizeSubhead = vLoader(32); const fontSizeBody3 = vLoader(28, 30); const fontSizeBody2 = vLoader(28, 26); const fontSizeBody1 = vLoader(28, 24); const fontSizeCaption = vLoader(24, 22); const fontWeight1 = vLoader(300); const fontWeight2 = vLoader(600); const fontWeight3 = vLoader(900); const fontLineHeight1 = vLoader(1.3); const fontLineHeight2 = vLoader(1.5); const fontLineHeight3 = vLoader(1.7); /** * 字体 * @namespace component * @property module font * @property category style */ const varMap = { /** * family * @property semantic 字体 * @property export */ 'font-family-base': fontFamilyBase, /** * display-3 * @property semantic 运营标题-大 * @property export size */ 'font-size-display-3': fontSizeDisplay3, /** * display-2 * @property semantic 运营标题-中 * @property export size */ 'font-size-display-2': fontSizeDisplay2, /** * display-1 * @property semantic 运营标题-小 * @property export size */ 'font-size-display-1': fontSizeDisplay1, /** * headline * @property semantic 标题-大 * @property export size */ 'font-size-headline': fontSizeHeadline, /** * title * @property semantic 标题-中 * @property export size */ 'font-size-title': fontSizeTitle, /** * subhead * @property semantic 标题-小 * @property export size */ 'font-size-subhead': fontSizeSubhead, /** * body-3 * @property semantic 正文 * @property export size */ 'font-size-body-3': fontSizeBody3, /** * body-2 * @property semantic 正文-强调 * @property export size */ 'font-size-body-2': fontSizeBody2, /** * body-1 * @property semantic 正文-常规 * @property export size */ 'font-size-body-1': fontSizeBody1, /** * caption * @property semantic 水印文本 * @property export size */ 'font-size-caption': fontSizeCaption, /** * light * @property semantic 细体 * @property export weightcore */ 'font-weight-1': fontWeight1, /** * regular * @property semantic 常规 * @property export weightcore */ 'font-weight-2': fontWeight2, /** * bold * @property semantic 粗体 * @property export weightcore */ 'font-weight-3': fontWeight3, /** * lineheight-1 * @property semantic 密集 * @property export lineheight */ 'font-lineheight-1': fontLineHeight1, /** * lineheight-2 * @property semantic 常规 * @property export lineheight */ 'font-lineheight-2': fontLineHeight2, /** * lineheight-3 * @property semantic 宽松 * @property export lineheight */ 'font-lineheight-3': fontLineHeight3, }; export default varMap;