From 2aefa390a9a93179f134438dfa15888159b5d46e Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期二, 04 七月 2023 14:32:24 +0800 Subject: [PATCH] Merge branch 'develop' --- src/menu/components/card/balcony/index.jsx | 32 ++ src/tabviews/custom/components/card/double-data-card/index.scss | 1 src/components/normalform/modalform/index.jsx | 2 src/menu/stylecontroller/index.jsx | 153 ++++--------- src/mob/components/tabs/antv-tabs/index.jsx | 26 + src/mob/components/tabs/antv-tabs/options.jsx | 78 +++--- src/menu/components/card/doublecardcomponent/index.scss | 1 src/menu/components/card/balcony/options.jsx | 178 ++++++++-------- src/menu/components/tabs/antv-tabs/options.jsx | 54 +++- src/menu/stylecontroller/styleInput/index.jsx | 38 ++- src/menu/components/card/balcony/index.scss | 4 src/tabviews/custom/components/card/balcony/index.jsx | 32 +- src/components/normalform/modalform/mkTable/index.jsx | 3 src/menu/components/card/cardcomponent/index.scss | 1 src/tabviews/custom/components/card/data-card/index.scss | 1 src/menu/components/tabs/antv-tabs/index.jsx | 26 + 16 files changed, 342 insertions(+), 288 deletions(-) diff --git a/src/components/normalform/modalform/index.jsx b/src/components/normalform/modalform/index.jsx index 7ce6bc5..2b9b80c 100644 --- a/src/components/normalform/modalform/index.jsx +++ b/src/components/normalform/modalform/index.jsx @@ -299,7 +299,7 @@ } else if (item.type === 'source') { content = (<SourceComponent type="" placement="right"/>) } else if (item.type === 'table') { - content = (<MKTable tip={item.tip || ''} columns={item.columns || []} actions={item.actions || []}/>) + content = (<MKTable tip={item.tip || ''} fixed={item.fixed === true} columns={item.columns || []} actions={item.actions || []}/>) } else if (item.type === 'hint') { fields.push( <Col span={24} key={index}> diff --git a/src/components/normalform/modalform/mkTable/index.jsx b/src/components/normalform/modalform/mkTable/index.jsx index ae23f22..3fdd300 100644 --- a/src/components/normalform/modalform/mkTable/index.jsx +++ b/src/components/normalform/modalform/mkTable/index.jsx @@ -392,6 +392,7 @@ } render() { + const { fixed } = this.props let components = { body: { cell: EditableCell @@ -436,7 +437,7 @@ return ( <EditableContext.Provider value={this.props.form}> <div className="modal-editable-table"> - <Button disabled={!!this.state.editingKey} type="link" onClick={this.addline}><PlusOutlined style={{}}/></Button> + {!fixed ? <Button disabled={!!this.state.editingKey} type="link" onClick={this.addline}><PlusOutlined style={{}}/></Button> : null} <DndProvider> <Table bordered diff --git a/src/menu/components/card/balcony/index.jsx b/src/menu/components/card/balcony/index.jsx index 691e7f3..7359268 100644 --- a/src/menu/components/card/balcony/index.jsx +++ b/src/menu/components/card/balcony/index.jsx @@ -46,8 +46,8 @@ name: card.name, subtype: card.subtype, setting: { interType: 'system' }, - wrap: { name: card.name, width: card.width || 24, linkType: 'static', position: 'relative', datatype: 'static' }, - style: { marginLeft: '0px', marginRight: '0px', marginTop: '0px', marginBottom: '0px' }, + wrap: { name: card.name, width: card.width || 24, linkType: 'static', datatype: 'static' }, + style: { marginLeft: '0px', marginRight: '0px', marginTop: '0px', marginBottom: '0px', position: 'unset' }, columns: [], scripts: [], elements: [], @@ -72,8 +72,32 @@ this.updateComponent(_card) } else { + let _card = fromJS(card).toJS() + + if (!_card.style.position) { // 鍏煎 + if (_card.wrap.position === 'fixed' || _card.wrap.position === 'absolute') { + _card.style.position = _card.wrap.position + _card.style.zIndex = _card.wrap.position === 'fixed' ? 3 : 2 + _card.style.left = _card.wrap.left || '' + _card.style.right = _card.wrap.right || '' + _card.style.top = _card.wrap.top || '' + _card.style.bottom = _card.wrap.bottom || '' + _card.style.transform = _card.wrap.transform || '' + _card.style.width = _card.wrap.realwidth || '' + } else if (_card.wrap.left || _card.wrap.right || _card.wrap.top || _card.wrap.bottom) { + _card.style.position = 'relative' + _card.style.zIndex = 1 + _card.style.left = _card.wrap.left || '' + _card.style.right = _card.wrap.right || '' + _card.style.top = _card.wrap.top || '' + _card.style.bottom = _card.wrap.bottom || '' + } else { + _card.style.position = 'unset' + } + } + this.setState({ - card: fromJS(card).toJS() + card: _card }) } } @@ -155,7 +179,7 @@ changeStyle = () => { const { card } = this.state - MKEmitter.emit('changeStyle', ['height', 'background', 'border', 'padding', 'margin', 'shadow', 'clear', 'minHeight'], card.style, this.getStyle) + MKEmitter.emit('changeStyle', ['width', 'height', 'background', 'border', 'padding', 'margin', 'shadow', 'clear', 'minHeight', 'position', 'transform'], card.style, this.getStyle) } getStyle = (style) => { diff --git a/src/menu/components/card/balcony/index.scss b/src/menu/components/card/balcony/index.scss index 1108b2c..418b226 100644 --- a/src/menu/components/card/balcony/index.scss +++ b/src/menu/components/card/balcony/index.scss @@ -1,5 +1,5 @@ .menu-balcony-edit-box { - position: relative; + position: unset!important; box-sizing: border-box; background: #ffffff; background-position: center center; @@ -8,6 +8,8 @@ min-height: 30px; display: flex; overflow: hidden; + max-width: 100%; + transform: none!important; .check-all { width: 70px; diff --git a/src/menu/components/card/balcony/options.jsx b/src/menu/components/card/balcony/options.jsx index b7dd426..95227ce 100644 --- a/src/menu/components/card/balcony/options.jsx +++ b/src/menu/components/card/balcony/options.jsx @@ -166,95 +166,95 @@ {value: 'show', label: '鏄剧ず'}, ] }, - { - type: 'radio', - field: 'position', - label: '浣嶇疆', - initval: wrap.position || 'relative', - tooltip: '鐩稿瀹氫綅鏄浉瀵瑰叾姝e父浣嶇疆鐨勫亸绉伙紱缁濆瀹氫綅鏄浉瀵逛簬鍘熺粍浠剁殑鍋忕Щ锛屽師缁勪欢楂樺害鍙涓�0锛涘浐瀹氬畾浣嶆槸鐩稿浜庣獥鍙g殑浣嶇疆锛屽畾浣嶆晥鏋滄祴璇曠幆澧冧腑鏌ョ湅銆�', - required: false, - options: [ - {value: 'relative', label: '鐩稿瀹氫綅'}, - {value: 'absolute', label: '缁濆瀹氫綅'}, - {value: 'fixed', label: '鍥哄畾瀹氫綅'}, - ], - controlFields: [ - {field: 'quick', values: ['fixed']}, - {field: 'realwidth', values: ['fixed', 'absolute']}, - {field: 'transform', values: ['fixed', 'absolute']}, - ] - }, - { - type: 'select', - field: 'quick', - label: '蹇嵎閫夋嫨', - initval: '', - required: false, - subFields: ['top', 'left', 'right', 'bottom', 'transform'], - options: [ - {value: 'top', label: '涓�', top: '0px', left: '0px', right: '0px', bottom: '', transform: ''}, - {value: 'top-left', label: '宸︿笂', top: '0px', left: '0px', right: '', bottom: '', transform: ''}, - {value: 'top-right', label: '鍙充笂', top: '0px', left: '', right: '0px', bottom: '', transform: ''}, - {value: 'left-middle', label: '宸︿腑', top: '50%', left: '0px', right: '', bottom: '', transform: 'translateY(-50%)'}, - {value: 'right-middle', label: '鍙充腑', top: '50%', left: '', right: '0px', bottom: '', transform: 'translateY(-50%)'}, - {value: 'bottom-left', label: '宸︿笅', top: '', left: '0px', right: '', bottom: '0px', transform: ''}, - {value: 'bottom-right', label: '鍙充笅', top: '', left: '', right: '0px', bottom: '0px', transform: ''}, - {value: 'bottom', label: '涓�', top: '', left: '0px', right: '0px', bottom: '0px', transform: ''}, - {value: 'middle', label: '涓棿', top: '50%', left: '50%', right: '', bottom: '', transform: 'translate(-50%, -50%)'} - ] - }, - { - type: 'styleInput', - field: 'top', - label: '璺濅笂', - initval: wrap.top || '', - required: false - }, - { - type: 'styleInput', - field: 'right', - label: '璺濆彸', - initval: wrap.right || '', - required: false - }, - { - type: 'styleInput', - field: 'bottom', - label: '璺濅笅', - initval: wrap.bottom || '', - required: false - }, - { - type: 'styleInput', - field: 'left', - label: '璺濆乏', - initval: wrap.left || '', - required: false - }, - { - type: 'styleInput', - field: 'realwidth', - label: '瀹為檯瀹藉害', - initval: wrap.realwidth || '', - required: false - }, - { - type: 'select', - field: 'transform', - label: '鍙樻崲', - initval: wrap.transform || '', - required: false, - options: [ - {value: 'translateY(-50%)', label: '涓婄Щ50%'}, - {value: 'translateY(50%)', label: '涓嬬Щ50%'}, - {value: 'translateX(-50%)', label: '宸︾Щ50%'}, - {value: 'translateX(50%)', label: '鍙崇Щ50%'}, - {value: 'translate(-50%, -50%)', label: '宸︿笂绉�50%'}, - {value: 'translate(-50%, 50%)', label: '宸︿笅绉�50%'}, - {value: 'translate(50%, -50%)', label: '鍙充笂绉�50%'}, - {value: 'translate(50%, 50%)', label: '鍙充笅绉�50%'}, - ] - }, + // { + // type: 'radio', + // field: 'position', + // label: '浣嶇疆', + // initval: wrap.position || 'relative', + // tooltip: '鐩稿瀹氫綅鏄浉瀵瑰叾姝e父浣嶇疆鐨勫亸绉伙紱缁濆瀹氫綅鏄浉瀵逛簬鍘熺粍浠剁殑鍋忕Щ锛屽師缁勪欢楂樺害鍙涓�0锛涘浐瀹氬畾浣嶆槸鐩稿浜庣獥鍙g殑浣嶇疆锛屽畾浣嶆晥鏋滄祴璇曠幆澧冧腑鏌ョ湅銆�', + // required: false, + // options: [ + // {value: 'relative', label: '鐩稿瀹氫綅'}, + // {value: 'absolute', label: '缁濆瀹氫綅'}, + // {value: 'fixed', label: '鍥哄畾瀹氫綅'}, + // ], + // controlFields: [ + // {field: 'quick', values: ['fixed']}, + // {field: 'realwidth', values: ['fixed', 'absolute']}, + // {field: 'transform', values: ['fixed', 'absolute']}, + // ] + // }, + // { + // type: 'select', + // field: 'quick', + // label: '蹇嵎閫夋嫨', + // initval: '', + // required: false, + // subFields: ['top', 'left', 'right', 'bottom', 'transform'], + // options: [ + // {value: 'top', label: '涓�', top: '0px', left: '0px', right: '0px', bottom: '', transform: ''}, + // {value: 'top-left', label: '宸︿笂', top: '0px', left: '0px', right: '', bottom: '', transform: ''}, + // {value: 'top-right', label: '鍙充笂', top: '0px', left: '', right: '0px', bottom: '', transform: ''}, + // {value: 'left-middle', label: '宸︿腑', top: '50%', left: '0px', right: '', bottom: '', transform: 'translateY(-50%)'}, + // {value: 'right-middle', label: '鍙充腑', top: '50%', left: '', right: '0px', bottom: '', transform: 'translateY(-50%)'}, + // {value: 'bottom-left', label: '宸︿笅', top: '', left: '0px', right: '', bottom: '0px', transform: ''}, + // {value: 'bottom-right', label: '鍙充笅', top: '', left: '', right: '0px', bottom: '0px', transform: ''}, + // {value: 'bottom', label: '涓�', top: '', left: '0px', right: '0px', bottom: '0px', transform: ''}, + // {value: 'middle', label: '涓棿', top: '50%', left: '50%', right: '', bottom: '', transform: 'translate(-50%, -50%)'} + // ] + // }, + // { + // type: 'styleInput', + // field: 'top', + // label: '璺濅笂', + // initval: wrap.top || '', + // required: false + // }, + // { + // type: 'styleInput', + // field: 'right', + // label: '璺濆彸', + // initval: wrap.right || '', + // required: false + // }, + // { + // type: 'styleInput', + // field: 'bottom', + // label: '璺濅笅', + // initval: wrap.bottom || '', + // required: false + // }, + // { + // type: 'styleInput', + // field: 'left', + // label: '璺濆乏', + // initval: wrap.left || '', + // required: false + // }, + // { + // type: 'styleInput', + // field: 'realwidth', + // label: '瀹為檯瀹藉害', + // initval: wrap.realwidth || '', + // required: false + // }, + // { + // type: 'select', + // field: 'transform', + // label: '鍙樻崲', + // initval: wrap.transform || '', + // required: false, + // options: [ + // {value: 'translateY(-50%)', label: '涓婄Щ50%'}, + // {value: 'translateY(50%)', label: '涓嬬Щ50%'}, + // {value: 'translateX(-50%)', label: '宸︾Щ50%'}, + // {value: 'translateX(50%)', label: '鍙崇Щ50%'}, + // {value: 'translate(-50%, -50%)', label: '宸︿笂绉�50%'}, + // {value: 'translate(-50%, 50%)', label: '宸︿笅绉�50%'}, + // {value: 'translate(50%, -50%)', label: '鍙充笂绉�50%'}, + // {value: 'translate(50%, 50%)', label: '鍙充笅绉�50%'}, + // ] + // }, { type: 'radio', field: 'empty', diff --git a/src/menu/components/card/cardcomponent/index.scss b/src/menu/components/card/cardcomponent/index.scss index 930a06f..35933f8 100644 --- a/src/menu/components/card/cardcomponent/index.scss +++ b/src/menu/components/card/cardcomponent/index.scss @@ -68,6 +68,7 @@ display: none; width: 16px; height: 16px; + min-width: 16px; border: 1px solid #cccccc; border-radius: 50%; box-sizing: content-box; diff --git a/src/menu/components/card/doublecardcomponent/index.scss b/src/menu/components/card/doublecardcomponent/index.scss index 344ab73..63e0e13 100644 --- a/src/menu/components/card/doublecardcomponent/index.scss +++ b/src/menu/components/card/doublecardcomponent/index.scss @@ -69,6 +69,7 @@ display: none; width: 16px; height: 16px; + min-width: 16px; border: 1px solid #cccccc; border-radius: 50%; box-sizing: content-box; diff --git a/src/menu/components/tabs/antv-tabs/index.jsx b/src/menu/components/tabs/antv-tabs/index.jsx index 523c8b2..9f1a261 100644 --- a/src/menu/components/tabs/antv-tabs/index.jsx +++ b/src/menu/components/tabs/antv-tabs/index.jsx @@ -195,8 +195,6 @@ } getTabForms = (tab) => { - const { tabs } = this.state - if (!tab) { tab = { uuid: '', @@ -210,7 +208,7 @@ editab: tab }) - return getTabForm(tab, tabs.setting) + return getTabForm(tab) } updateTab = (res) => { @@ -221,7 +219,7 @@ editab.icon = res.icon editab.hide = res.hide || 'false' editab.backgroundColor = res.backgroundColor - editab.controlVal = res.controlVal || '' + // editab.controlVal = res.controlVal || '' editab.selectVal = res.selectVal || '' editab.blacklist = res.blacklist @@ -249,11 +247,27 @@ getTabsForms = () => { const { tabs } = this.state - return getTabsSetForm(tabs.setting, tabs.uuid) + return getTabsSetForm(tabs.setting, tabs.uuid, tabs.subtabs) } updateTabs = (res) => { - this.updateComponent({...this.state.tabs, setting: res}) + let tabs = fromJS(this.state.tabs).toJS() + + if (res.controlVals) { + let values = {} + res.controlVals.forEach(item => { + values[item.uuid] = item.value + }) + tabs.subtabs.forEach(tab => { + tab.controlVal = values[tab.uuid] + }) + + delete res.controlVals + } + + tabs.setting = res + + this.updateComponent(tabs) } onChange = (key) => { diff --git a/src/menu/components/tabs/antv-tabs/options.jsx b/src/menu/components/tabs/antv-tabs/options.jsx index 8654b25..df84fdf 100644 --- a/src/menu/components/tabs/antv-tabs/options.jsx +++ b/src/menu/components/tabs/antv-tabs/options.jsx @@ -3,7 +3,7 @@ /** * @description tab琛ㄥ崟閰嶇疆淇℃伅 */ -export function getTabForm(tab, setting) { +export function getTabForm(tab) { let appType = sessionStorage.getItem('appType') let roleList = sessionStorage.getItem('sysRoles') @@ -34,14 +34,14 @@ required: false, allowClear: true, }, - { - type: 'text', - field: 'controlVal', - label: '闅愯棌鏍囪', - initval: tab.controlVal || '', - tooltip: '褰撶鐢ㄥ瓧娈靛�间笌闅愯棌鏍囪鐩哥瓑鏃讹紝鏍囩椤典細闅愯棌銆傛敞锛�1銆佸涓�艰鐢ㄩ�楀彿鍒嗛殧锛�2銆丂pass@鍊艰〃绀哄拷鐣ユ璁剧疆锛堝缁堟樉绀猴級锛�2銆丂pass_empty@鍊艰〃绀哄拷鐣ョ┖鍊硷紝鍗虫湭鑾峰彇涓婄骇缁勪欢淇℃伅鏃舵樉绀猴紙鍙笌鍏朵粬鍊兼嫾鎺ワ級銆�', - required: false, - }, + // { + // type: 'text', + // field: 'controlVal', + // label: '闅愯棌鏍囪', + // initval: tab.controlVal || '', + // tooltip: '褰撶鐢ㄥ瓧娈靛�间笌闅愯棌鏍囪鐩哥瓑鏃讹紝鏍囩椤典細闅愯棌銆傛敞锛�1銆佸涓�艰鐢ㄩ�楀彿鍒嗛殧锛�2銆丂pass@鍊艰〃绀哄拷鐣ユ璁剧疆锛堝缁堟樉绀猴級锛�2銆丂pass_empty@鍊艰〃绀哄拷鐣ョ┖鍊硷紝鍗虫湭鑾峰彇涓婄骇缁勪欢淇℃伅鏃舵樉绀猴紙鍙笌鍏朵粬鍊兼嫾鎺ワ級銆�', + // required: false, + // }, { type: 'text', field: 'selectVal', @@ -85,7 +85,7 @@ /** * @description tabs琛ㄥ崟閰嶇疆淇℃伅 */ -export function getTabsSetForm(setting, uuid) { +export function getTabsSetForm(setting, uuid, subtabs) { let appType = sessionStorage.getItem('appType') let roleList = sessionStorage.getItem('sysRoles') @@ -104,6 +104,8 @@ } else { roleList = [] } + + let controlVals = subtabs.map(item => ({uuid: item.uuid, label: item.label, value: item.controlVal})) const tabForm = [ { @@ -202,6 +204,7 @@ options: modules, controlFields: [ {field: 'controlField', notNull: true}, + {field: 'controlVals', notNull: true}, ], }, { @@ -209,7 +212,7 @@ field: 'controlField', label: '绂佺敤瀛楁', initval: setting.controlField || '', - tooltip: '鐢ㄤ簬鎺у埗鏍囩闅愯棌鐨勫瓧娈碉紝鍦ㄦ爣绛句腑濉叆闅愯棌鏍囪銆傛敞锛氭爲褰㈢粍浠朵腑涓嶅悓灞傜骇浼氳嚜鍔ㄧ敓鎴恗k_floor锛堝眰绾у瓧娈�1銆�2銆�3...锛夈��', + tooltip: '鐢ㄤ簬鎺у埗鏍囩闅愯棌鐨勫瓧娈点�傛敞锛氭爲褰㈢粍浠朵腑涓嶅悓灞傜骇浼氳嚜鍔ㄧ敓鎴恗k_floor锛堝眰绾у瓧娈�1銆�2銆�3...锛夈��', required: true, }, { @@ -217,7 +220,7 @@ field: 'selectField', label: '閫変腑瀛楁', initval: setting.selectField || '', - tooltip: '鐢ㄤ簬鎺у埗鏍囩椤靛垵濮嬪寲閫変腑锛屽湪鏍囩涓~鍏ラ�変腑鏍囪锛屾敞锛氭暟鎹簮浜巙rl鍙傛暟銆�', + tooltip: '鐢ㄤ簬鎺у埗鏍囩椤靛垵濮嬪寲閫変腑锛屽湪鏍囩涓~鍏ラ�変腑鏍囪锛屾敞锛氭暟鎹潵婧愪簬url鍙傛暟銆�', required: false }, { @@ -248,6 +251,33 @@ options: roleList, forbid: !!appType }, + { + type: 'table', + field: 'controlVals', + label: '鏍囩缁�', + initval: controlVals, + tooltip: '褰撶鐢ㄥ瓧娈靛�间笌闅愯棌鏍囪鐩哥瓑鏃讹紝鏍囩椤典細闅愯棌銆傛敞锛�1銆佸涓�艰鐢ㄩ�楀彿鍒嗛殧锛�2銆丂pass@鍊艰〃绀哄拷鐣ユ璁剧疆锛堝缁堟樉绀猴級锛�2銆丂pass_empty@鍊艰〃绀哄拷鐣ョ┖鍊硷紝鍗虫湭鑾峰彇涓婄骇缁勪欢淇℃伅鏃舵樉绀猴紙鍙笌鍏朵粬鍊兼嫾鎺ワ級銆�', + required: false, + fixed: true, + span: 24, + columns: [ + { + title: '鏍囩鍚嶇О', + dataIndex: 'label', + editable: false, + required: false, + width: '30%' + }, + { + title: '闅愯棌鏍囪', + dataIndex: 'value', + inputType: 'input', + editable: true, + required: false, + width: '50%' + } + ] + } ] return tabForm diff --git a/src/menu/stylecontroller/index.jsx b/src/menu/stylecontroller/index.jsx index a781f01..bf7ce71 100644 --- a/src/menu/stylecontroller/index.jsx +++ b/src/menu/stylecontroller/index.jsx @@ -28,7 +28,8 @@ ArrowLeftOutlined, ArrowRightOutlined, SwapOutlined, - EnterOutlined + EnterOutlined, + DragOutlined } from '@ant-design/icons' import MKEmitter from '@/utils/events.js' @@ -176,8 +177,12 @@ } }) - if (_style.position === 'relative' || _style.position === 'absolute') { + if (_style.position === 'relative') { _style.zIndex = 1 + } else if (_style.position === 'absolute') { + _style.zIndex = 2 + } else if (_style.position === 'fixed') { + _style.zIndex = 3 } else { delete _style.zIndex } @@ -239,55 +244,6 @@ this.updateStyle({textIndent: `${value}px`}) } - /** - * @description 淇敼瀛椾綋绮楃粏 - */ - boldChange = (val) => { - this.updateStyle({fontWeight: val}) - } - - /** - * @description 鑷姩鎹㈣ - */ - wordBreakChange = (val) => { - this.updateStyle({wordBreak: val}) - } - - /** - * @description 淇敼瀛椾綋棰滆壊 锛岄鑹叉帶浠� - */ - changeFontColor = (val) => { - this.updateStyle({color: val}) - } - - /** - * @description 瀛椾綋瀵归綈 - */ - changeTextAlign = (e) => { - this.updateStyle({textAlign: e.target.value}) - } - - /** - * @description 瀛椾綋鏍峰紡锛屽�炬枩 - */ - changeFontStyle = (e) => { - this.updateStyle({fontStyle: e.target.value}) - } - - /** - * @description 瀛椾綋瑁呴グ锛屼笅鍒掔嚎銆佽疮绌跨嚎銆佷笂鍒掔嚎 - */ - changeTextDecoration = (e) => { - this.updateStyle({textDecoration: e.target.value}) - } - - /** - * @description 淇敼鑳屾櫙棰滆壊 锛岄鑹叉帶浠� - */ - changeBackgroundColor = (val) => { - this.updateStyle({backgroundColor: val}) - } - changeBackground = (val) => { const { card } = this.state @@ -309,27 +265,6 @@ if (!val || /(^linear-gradient|^radial-gradient)\(.*\)$/.test(val)) { this.callback && this.callback(_style) } - } - - /** - * @description 淇敼鑳屾櫙澶у皬 - */ - changeBackgroundSize = (val) => { - this.updateStyle({backgroundSize: val}) - } - - /** - * @description 淇敼鑳屾櫙浣嶇疆 - */ - changeBackgroundPositon= (val) => { - this.updateStyle({backgroundPosition: val}) - } - - /** - * @description 淇敼鑳屾櫙閲嶅璁剧疆 - */ - changeBackgroundRepeat = (val) => { - this.updateStyle({backgroundRepeat: val}) } /** @@ -442,14 +377,6 @@ } this.updateStyle(_style) - } - - changeWidth = (val) => { - this.updateStyle({width: val}) - } - - changeHeight = (val) => { - this.updateStyle({height: val}) } changeNormalStyle = (val, type) => { @@ -566,7 +493,7 @@ label={<ColumnWidthOutlined title="瀹藉害"/>} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <StyleInput clear={true} defaultValue={card.width || ''} options={['px', 'vh', 'vw', '%', 'auto']} onChange={this.changeWidth}/> + <StyleInput clear={true} defaultValue={card.width || ''} options={['px', 'vh', 'vw', '%', 'auto']} onChange={(val) => this.changeNormalStyle(val, 'width')}/> </Form.Item> </Col> </Panel> : null} @@ -577,7 +504,7 @@ label={<ColumnHeightOutlined title="楂樺害"/>} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <StyleInput clear={true} defaultValue={card.height || ''} options={['px', 'vh', 'vw']} onChange={this.changeHeight}/> + <StyleInput clear={true} defaultValue={card.height || ''} options={['px', 'vh', 'vw']} onChange={(val) => this.changeNormalStyle(val, 'height')}/> </Form.Item> </Col> </Panel> : null} @@ -589,7 +516,7 @@ </Col> : null} {fonts.includes('fontWeight') ? <Col span={12}> <Form.Item colon={false} label={<BoldOutlined title="瀛椾綋绮楃粏"/>}> - <Select defaultValue={card.fontWeight || 'normal'} onChange={this.boldChange}> + <Select defaultValue={card.fontWeight || 'normal'} onChange={(val) => this.changeNormalStyle(val, 'fontWeight')}> <Option value="normal">normal</Option> <Option value="bold">bold</Option> <Option value="bolder">bolder</Option> @@ -623,7 +550,7 @@ </Col> : null} {fonts.includes('wordBreak') ? <Col span={12}> <Form.Item colon={false} label={<EnterOutlined title="鑷姩鎹㈣"/>}> - <Select defaultValue={card.wordBreak || 'normal'} onChange={this.wordBreakChange}> + <Select defaultValue={card.wordBreak || 'normal'} onChange={(val) => this.changeNormalStyle(val, 'wordBreak')}> <Option value="normal">normal</Option> <Option value="break-all">break-all</Option> </Select> @@ -635,14 +562,14 @@ label={<FontColorsOutlined title="瀛椾綋棰滆壊"/>} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <ColorSketch value={card.color || ''} onChange={this.changeFontColor} /> + <ColorSketch value={card.color || ''} onChange={(val) => this.changeNormalStyle(val, 'color')} /> </Form.Item> <Form.Item colon={false} label={<BgColorsOutlined title="绯荤粺鑹�"/>} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <SysColorSketch onChange={this.changeFontColor} /> + <SysColorSketch onChange={(val) => this.changeNormalStyle(val, 'color')} /> </Form.Item> </Col> : null} {fonts.includes('fontStyle') ? <Col span={24}> @@ -651,7 +578,7 @@ label={' '} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <Radio.Group defaultValue={card.fontStyle || 'normal'} onChange={this.changeFontStyle}> + <Radio.Group defaultValue={card.fontStyle || 'normal'} onChange={(e) => this.changeNormalStyle(e.target.value, 'fontStyle')}> <Radio.Button value="normal"><span title="鏍囧噯">N</span></Radio.Button> <Radio.Button value="italic"><ItalicOutlined title="鏂滀綋"/></Radio.Button> <Radio.Button value="oblique" style={{fontStyle: 'oblique'}}><span title="鍊炬枩">B</span></Radio.Button> @@ -664,7 +591,7 @@ label={' '} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <Radio.Group className="text-align" defaultValue={card.textAlign || 'left'} onChange={this.changeTextAlign}> + <Radio.Group className="text-align" defaultValue={card.textAlign || 'left'} onChange={(e) => this.changeNormalStyle(e.target.value, 'textAlign')}> <Radio.Button value="left"><AlignLeftOutlined title="宸﹀榻�"/></Radio.Button> <Radio.Button value="center"><AlignCenterOutlined title="灞呬腑瀵归綈"/></Radio.Button> <Radio.Button value="right"><AlignRightOutlined title="鍙冲榻�"/></Radio.Button> @@ -677,7 +604,7 @@ label={' '} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <Radio.Group className="text-decoration" defaultValue={card.textDecoration || 'none'} onChange={this.changeTextDecoration}> + <Radio.Group className="text-decoration" defaultValue={card.textDecoration || 'none'} onChange={(e) => this.changeNormalStyle(e.target.value, 'textDecoration')}> <Radio.Button value="none"><span title="鏍囧噯">N</span></Radio.Button> <Radio.Button value="underline"><UnderlineOutlined title="涓嬪垝绾�"/></Radio.Button> <Radio.Button value="line-through"><StrikethroughOutlined title="涓垝绾�"/></Radio.Button> @@ -693,14 +620,14 @@ label={<BgColorsOutlined title="鑳屾櫙棰滆壊"/>} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <ColorSketch allowClear={true} value={card.backgroundColor || ''} onChange={this.changeBackgroundColor} /> + <ColorSketch allowClear={true} value={card.backgroundColor || ''} onChange={(val) => this.changeNormalStyle(val, 'backgroundColor')} /> </Form.Item> <Form.Item colon={false} label={<BgColorsOutlined title="绯荤粺鑹�"/>} labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <SysColorSketch onChange={this.changeBackgroundColor} /> + <SysColorSketch onChange={(val) => this.changeNormalStyle(val, 'backgroundColor')} /> </Form.Item> </Col> {window.develop === true ? <Col span={24}> @@ -727,7 +654,7 @@ label="姣斾緥" labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <Select defaultValue={card.backgroundSize || 'cover'} onChange={this.changeBackgroundSize}> + <Select defaultValue={card.backgroundSize || 'cover'} onChange={(val) => this.changeNormalStyle(val, 'backgroundSize')}> <Option value="100%">100%</Option> <Option value="100% 100%">100% 100%</Option> <Option value="auto 100%">auto 100%</Option> @@ -744,7 +671,7 @@ label="閲嶅" labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <Select defaultValue={card.backgroundRepeat || 'no-repeat'} onChange={this.changeBackgroundRepeat}> + <Select defaultValue={card.backgroundRepeat || 'no-repeat'} onChange={(val) => this.changeNormalStyle(val, 'backgroundRepeat')}> <Option value="repeat">repeat</Option> <Option value="no-repeat">no-repeat</Option> <Option value="repeat-x">repeat-x</Option> @@ -758,7 +685,7 @@ label="浣嶇疆" labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } > - <Select defaultValue={card.backgroundPosition || 'center'} onChange={this.changeBackgroundPositon}> + <Select defaultValue={card.backgroundPosition || 'center'} onChange={(val) => this.changeNormalStyle(val, 'backgroundPosition')}> <Option value="center">center</Option> <Option value="center top">center top</Option> <Option value="center bottom">center bottom</Option> @@ -1045,16 +972,18 @@ </Col> </Panel> : null} {options.includes('position') ? <Panel header="瀹氫綅" key="position"> + <div style={{paddingLeft: '35px', fontSize: '12px'}}>娉細瀹氫綅鏁堟灉璇峰湪杩愯鐜涓煡鐪嬨��</div> <Col span={24}> <Form.Item colon={false} label={<SwapOutlined title="瀹氫綅"/>} - labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } + labelCol={{xs: { span: 24 }, sm: { span: 3 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 21 }} } > <Radio.Group style={{whiteSpace: 'nowrap'}} defaultValue={card.position || 'unset'} onChange={(e) => this.changeNormalStyle(e.target.value, 'position')}> <Radio value="unset">鏃�</Radio> - <Radio value="relative">鐩稿瀹氫綅</Radio> - <Radio value="absolute">缁濆瀹氫綅</Radio> + <Radio value="relative">鐩稿</Radio> + <Radio value="absolute">缁濆</Radio> + <Radio value="fixed">鍥哄畾</Radio> </Radio.Group> </Form.Item> </Col> @@ -1062,7 +991,7 @@ <Form.Item colon={false} label={<ArrowUpOutlined title="涓�"/>} - labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } + labelCol={{xs: { span: 24 }, sm: { span: 3 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 21 }} } > <StyleInput clear={true} defaultValue={card.top || ''} options={['px', 'vh', 'vw', '%']} onChange={(val) => this.changeNormalStyle(val, 'top')}/> </Form.Item> @@ -1071,7 +1000,7 @@ <Form.Item colon={false} label={<ArrowDownOutlined title="涓�"/>} - labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } + labelCol={{xs: { span: 24 }, sm: { span: 3 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 21 }} } > <StyleInput clear={true} defaultValue={card.bottom || ''} options={['px', 'vh', 'vw', '%']} onChange={(val) => this.changeNormalStyle(val, 'bottom')}/> </Form.Item> @@ -1080,7 +1009,7 @@ <Form.Item colon={false} label={<ArrowLeftOutlined title="宸�"/>} - labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } + labelCol={{xs: { span: 24 }, sm: { span: 3 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 21 }} } > <StyleInput clear={true} defaultValue={card.left || ''} options={['px', 'vh', 'vw', '%']} onChange={(val) => this.changeNormalStyle(val, 'left')}/> </Form.Item> @@ -1089,12 +1018,34 @@ <Form.Item colon={false} label={<ArrowRightOutlined title="鍙�"/>} - labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } + labelCol={{xs: { span: 24 }, sm: { span: 3 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 21 }} } > <StyleInput clear={true} defaultValue={card.right || ''} options={['px', 'vh', 'vw', '%']} onChange={(val) => this.changeNormalStyle(val, 'right')}/> </Form.Item> </Col> </Panel> : null} + {options.includes('transform') ? <Panel header="浣嶇疆鍙樻崲" key="transform"> + <div style={{paddingLeft: '50px', fontSize: '12px'}}>娉細鍙樻崲鏁堟灉璇峰湪杩愯鐜涓煡鐪嬨��</div> + <Col span={24}> + <Form.Item + colon={false} + label={<DragOutlined title="鍙樻崲"/>} + labelCol={{xs: { span: 24 }, sm: { span: 4 }}} wrapperCol={ {xs: { span: 24 }, sm: { span: 20 }} } + > + <Select defaultValue={card.transform || ''} onChange={(val) => this.changeNormalStyle(val, 'transform')}> + <Option value="">鏃�</Option> + <Option value="translateY(-50%)">涓婄Щ50%</Option> + <Option value="translateY(50%)">涓嬬Щ50%</Option> + <Option value="translateX(-50%)">宸︾Щ50%</Option> + <Option value="translateX(50%)">鍙崇Щ50%</Option> + <Option value="translate(-50%, -50%)">宸︿笂绉�50%</Option> + <Option value="translate(-50%, 50%)">宸︿笅绉�50%</Option> + <Option value="translate(50%, -50%)">鍙充笂绉�50%</Option> + <Option value="translate(50%, 50%)">鍙充笅绉�50%</Option> + </Select> + </Form.Item> + </Col> + </Panel> : null} </Collapse> : null} </Form> <div style={{textAlign: 'right', lineHeight: '60px', marginBottom: '30px'}}> diff --git a/src/menu/stylecontroller/styleInput/index.jsx b/src/menu/stylecontroller/styleInput/index.jsx index d3a93a0..52b9c1c 100644 --- a/src/menu/stylecontroller/styleInput/index.jsx +++ b/src/menu/stylecontroller/styleInput/index.jsx @@ -21,6 +21,8 @@ options: null } + timer = null + UNSAFE_componentWillMount () { const { defaultValue, value, options } = this.props let val = '' @@ -125,28 +127,34 @@ value: _val, }) - if (this.props.onChange) { - if (!_val) { - this.props.onChange(clear ? '' : '0px') - } else { - this.props.onChange(`${_val}${unit}`) + clearTimeout(this.timer) + + this.timer = setTimeout(() => { + if (this.props.onChange) { + if (_val === '') { + this.props.onChange(clear ? '' : '0px') + } else { + this.props.onChange(`${_val}${unit}`) + } } - } + }, 100) } changeUnit = (val) => { const { value } = this.state - this.setState({unit: val}) - - if (val === 'auto') { - this.setState({value: ''}) - this.props.onChange('auto') - } else { - if (value && this.props.onChange) { - this.props.onChange(`${value}${val}`) + this.setState({unit: val}, () => { + if (val === 'auto') { + this.setState({value: ''}) + this.props.onChange('auto') + } else { + if (value && this.props.onChange) { + this.props.onChange(`${value}${val}`) + } else { + this.props.onChange('') + } } - } + }) } render () { diff --git a/src/mob/components/tabs/antv-tabs/index.jsx b/src/mob/components/tabs/antv-tabs/index.jsx index 45181e1..fdd6b21 100644 --- a/src/mob/components/tabs/antv-tabs/index.jsx +++ b/src/mob/components/tabs/antv-tabs/index.jsx @@ -226,8 +226,6 @@ } getTabForms = (tab) => { - const { tabs } = this.state - if (!tab) { tab = { uuid: '', @@ -241,7 +239,7 @@ editab: tab }) - return getTabForm(tab, tabs.setting) + return getTabForm(tab) } updateTab = (res) => { @@ -252,7 +250,7 @@ editab.icon = res.icon editab.hide = res.hide || 'false' editab.backgroundColor = res.backgroundColor - editab.controlVal = res.controlVal || '' + // editab.controlVal = res.controlVal || '' editab.selectVal = res.selectVal || '' editab.blacklist = res.blacklist @@ -280,11 +278,27 @@ getTabsForms = () => { const { tabs } = this.state - return getTabsSetForm(tabs.setting, tabs.uuid) + return getTabsSetForm(tabs.setting, tabs.uuid, tabs.subtabs) } updateTabs = (res) => { - this.updateComponent({...this.state.tabs, setting: res}) + let tabs = fromJS(this.state.tabs).toJS() + + if (res.controlVals) { + let values = {} + res.controlVals.forEach(item => { + values[item.uuid] = item.value + }) + tabs.subtabs.forEach(tab => { + tab.controlVal = values[tab.uuid] + }) + + delete res.controlVals + } + + tabs.setting = res + + this.updateComponent(tabs) } onChange = (key) => { diff --git a/src/mob/components/tabs/antv-tabs/options.jsx b/src/mob/components/tabs/antv-tabs/options.jsx index 9c4ddc7..3fe37fb 100644 --- a/src/mob/components/tabs/antv-tabs/options.jsx +++ b/src/mob/components/tabs/antv-tabs/options.jsx @@ -3,8 +3,7 @@ /** * @description Wrap琛ㄥ崟閰嶇疆淇℃伅 */ -export function getTabForm(tab, setting) { - // let appType = sessionStorage.getItem('appType') +export function getTabForm(tab) { let roleList = sessionStorage.getItem('sysRoles') if (roleList) { @@ -34,14 +33,14 @@ required: false, allowClear: true, }, - { - type: 'text', - field: 'controlVal', - label: '闅愯棌鏍囪', - initval: tab.controlVal || '', - tooltip: '褰撶鐢ㄥ瓧娈靛�间笌闅愯棌鏍囪鐩哥瓑鏃讹紝鏍囩椤典細闅愯棌銆傛敞锛氬涓�艰鐢ㄩ�楀彿鍒嗛殧銆�', - required: false - }, + // { + // type: 'text', + // field: 'controlVal', + // label: '闅愯棌鏍囪', + // initval: tab.controlVal || '', + // tooltip: '褰撶鐢ㄥ瓧娈靛�间笌闅愯棌鏍囪鐩哥瓑鏃讹紝鏍囩椤典細闅愯棌銆傛敞锛氬涓�艰鐢ㄩ�楀彿鍒嗛殧銆�', + // required: false + // }, { type: 'text', field: 'selectVal', @@ -67,16 +66,7 @@ {value: 'false', label: '鍚�'}, {value: 'true', label: '鏄�'}, ], - }, - // { - // type: 'multiselect', - // field: 'blacklist', - // label: '榛戝悕鍗�', - // initval: tab.blacklist || [], - // required: false, - // options: roleList, - // forbid: !!appType, - // }, + } ] return tabForm @@ -85,12 +75,14 @@ /** * @description tabs琛ㄥ崟閰嶇疆淇℃伅 */ -export function getTabsSetForm(setting, uuid) { +export function getTabsSetForm(setting, uuid, subtabs) { let modules = MenuUtils.getSupModules(window.GLOB.customMenu.components, uuid, window.GLOB.customMenu.interfaces) modules.push({ value: 'preview', label: '涓婁竴椤碉紙url鍙傛暟锛�' }) + + let controlVals = subtabs.map(item => ({uuid: item.uuid, label: item.label, value: item.controlVal})) const tabForm = [ { @@ -112,22 +104,6 @@ precision: 0, required: true }, - // { - // type: 'select', - // field: 'position', - // label: '鏍囩浣嶇疆', - // initval: setting.position || 'top', - // required: true, - // options: [ - // {value: 'top', label: 'top'}, - // {value: 'bottom', label: 'bottom'}, - // {value: 'left', label: 'left'}, - // {value: 'right', label: 'right'}, - // ], - // controlFields: [ - // {field: 'display', values: ['top', 'bottom']}, - // ] - // }, { type: 'radio', field: 'display', @@ -151,6 +127,7 @@ options: modules, controlFields: [ {field: 'controlField', notNull: true}, + {field: 'controlVals', notNull: true}, {field: 'swiper', values: ['']}, ], }, @@ -200,6 +177,33 @@ ], forbid: sessionStorage.getItem('editMenuType') === 'popview' }, + { + type: 'table', + field: 'controlVals', + label: '鏍囩缁�', + initval: controlVals, + tooltip: '褰撶鐢ㄥ瓧娈靛�间笌闅愯棌鏍囪鐩哥瓑鏃讹紝鏍囩椤典細闅愯棌銆傛敞锛�1銆佸涓�艰鐢ㄩ�楀彿鍒嗛殧锛�2銆丂pass@鍊艰〃绀哄拷鐣ユ璁剧疆锛堝缁堟樉绀猴級锛�2銆丂pass_empty@鍊艰〃绀哄拷鐣ョ┖鍊硷紝鍗虫湭鑾峰彇涓婄骇缁勪欢淇℃伅鏃舵樉绀猴紙鍙笌鍏朵粬鍊兼嫾鎺ワ級銆�', + required: false, + fixed: true, + span: 24, + columns: [ + { + title: '鏍囩鍚嶇О', + dataIndex: 'label', + editable: false, + required: false, + width: '30%' + }, + { + title: '闅愯棌鏍囪', + dataIndex: 'value', + inputType: 'input', + editable: true, + required: false, + width: '50%' + } + ] + } ] return tabForm diff --git a/src/tabviews/custom/components/card/balcony/index.jsx b/src/tabviews/custom/components/card/balcony/index.jsx index 119c77e..78d631f 100644 --- a/src/tabviews/custom/components/card/balcony/index.jsx +++ b/src/tabviews/custom/components/card/balcony/index.jsx @@ -84,21 +84,23 @@ _data.$$uuid = _data[_config.setting.primaryKey] || '' } - if (_config.wrap.position === 'fixed' || _config.wrap.position === 'absolute') { - _config.style.position = _config.wrap.position - _config.style.zIndex = _config.wrap.position === 'fixed' ? 3 : 2 - _config.style.left = _config.wrap.left || '' - _config.style.right = _config.wrap.right || '' - _config.style.top = _config.wrap.top || '' - _config.style.bottom = _config.wrap.bottom || '' - _config.style.transform = _config.wrap.transform || '' - _config.style.width = _config.wrap.realwidth || '' - } else { - _config.style.zIndex = 1 - _config.style.left = _config.wrap.left || '' - _config.style.right = _config.wrap.right || '' - _config.style.top = _config.wrap.top || '' - _config.style.bottom = _config.wrap.bottom || '' + if (!_config.style.position) { + if (_config.wrap.position === 'fixed' || _config.wrap.position === 'absolute') { + _config.style.position = _config.wrap.position + _config.style.zIndex = _config.wrap.position === 'fixed' ? 3 : 2 + _config.style.left = _config.wrap.left || '' + _config.style.right = _config.wrap.right || '' + _config.style.top = _config.wrap.top || '' + _config.style.bottom = _config.wrap.bottom || '' + _config.style.transform = _config.wrap.transform || '' + _config.style.width = _config.wrap.realwidth || '' + } else { + _config.style.zIndex = 1 + _config.style.left = _config.wrap.left || '' + _config.style.right = _config.wrap.right || '' + _config.style.top = _config.wrap.top || '' + _config.style.bottom = _config.wrap.bottom || '' + } } let show = true diff --git a/src/tabviews/custom/components/card/data-card/index.scss b/src/tabviews/custom/components/card/data-card/index.scss index bb71f96..988dbf2 100644 --- a/src/tabviews/custom/components/card/data-card/index.scss +++ b/src/tabviews/custom/components/card/data-card/index.scss @@ -158,6 +158,7 @@ display: none; width: 16px; height: 16px; + min-width: 16px; border: 1px solid #cccccc; border-radius: 50%; box-sizing: content-box; diff --git a/src/tabviews/custom/components/card/double-data-card/index.scss b/src/tabviews/custom/components/card/double-data-card/index.scss index 0ee2e47..40c3146 100644 --- a/src/tabviews/custom/components/card/double-data-card/index.scss +++ b/src/tabviews/custom/components/card/double-data-card/index.scss @@ -130,6 +130,7 @@ display: none; width: 16px; height: 16px; + min-width: 16px; border: 1px solid #cccccc; border-radius: 50%; box-sizing: content-box; -- Gitblit v1.8.0