UNPKG

weex-nuke

Version:

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

129 lines (123 loc) 2.78 kB
'use strict'; function VariableMix(theme) { const core = theme.Core; const ComponentCustomStyle = theme.SearchBar; /** * 搜索 * @namespace component * @property module search-bar * @property tag SearchBar * @property category component */ const SearchBarVariables = { /** * height * @property namespace size/bounding */ height: core['s-11'], /** * height * @property namespace size/input */ 'body-height': core['s-8'], /** * background * @property namespace statement */ 'bg-color': core['color-white'], /** * margin(r) * @property namespace size/menu */ 'menu-margin-right': core['s-2'], /** * padding(l,r) * @property namespace size */ 'padding-left-right': core['s-2'], /** * padding(l,r) * @property namespace size/body */ 'body-padding-l-r': core['s-2'], /** * background * @property namespace statement/input */ 'input-bg-color': core['color-white'], /** * padding(l) * @property namespace size/input */ 'input-padding-left': core['s-7'], /** * corner * @property namespace statement/input */ 'border-radius': core['corner-1'], /** * text * @property namespace statement/input */ color: core['color-text1-4'], /** * text * @property namespace statement/placeholder */ 'placeholder-color': core['color-text1-1'], /** * text * @property namespace size */ 'font-size': core['font-size-body-2'], /** * border-color * @property namespace statement/focus */ 'bottom-color': core['color-line1-2'], /** * width * @property namespace size/border */ 'border-width': core['line-1'], /** * border-style * @property namespace statement */ 'border-style': core['line-solid'], /** * size * @property namespace size/icon */ 'icon-size': core['icon-s'], /** * margin(l) * @property namespace size/icon */ 'icon-margin-right': core['s-1'], /** * margin(l) * @property namespace size/cancel */ 'cancel-margin-left': core['s-2'], /** * color * @property namespace statement/clear */ 'clear-color': core['color-text1-2'], /** * size * @property namespace size/clear */ 'clear-size': core['icon-s'], /** * margin(r) * @property namespace size/clear */ 'clear-margin-right': core['s-2'], }; // should alway use var statement to carray a assigngg const variable = Object.assign(SearchBarVariables, ComponentCustomStyle); return variable; } module.exports = VariableMix;