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N,CACFtC,MAAOyC,EAASE,iBAChB1C,OAAQwC,EAASG,mBAMnB/I,EAAWiJ,gBAAgB9E,EAAIN,EAAUmF,EAAe,KAAM,CAC5D9C,GAAIrC,EAASqC,GACbgD,aAAcrF,EAASsF,UAhBzB,CAkBF,CACF,EAOA9B,OAAQ,WACN,IAAIvD,EAAQrC,KAAKwF,OACjBnD,EAAMtB,MAAK,SAAU2B,GACnBI,EAASJ,EAAIL,EACf,IACArC,KAAKwF,OAASpH,EAAOqH,eACvB,EAKAkC,QAAS,WACP3H,KAAK4F,QACP,G,wBC7YF,EAAQ,OAER,EAAQ,OAER,EAAQ,M,wBCJR,IAAI1H,EAAU,EAAQ,OAElBE,EAAS,EAAQ,OAEjBkB,EAAU,EAAQ,OAEtB,EAAQ,OAER,EAAQ,OAqBRpB,EAAQkH,oBAAoB,CAC1BzF,KAAM,OACNgG,OAAQ,SAAUiC,EAAWtC,GAC3BtF,KAAKnB,MAAMgJ,YAEPD,EAAU5B,IAAI,SAChBhG,KAAKnB,MAAM8D,IAAI,IAAIrD,EAAQwI,KAAK,CAC9BC,MAAOH,EAAUI,iBAAiBC,UAClC/B,MAAO9H,EAAO8J,SAAS,CACrB7B,KAAMuB,EAAU5B,IAAI,oBACnB4B,EAAUO,gBACbpD,QAAQ,EACRqD,IAAK,IAGX,IAEFlK,EAAQiB,sBAAqB,SAAUC,GAEjCA,EAAOiJ,OAASjJ,EAAOkJ,QAAUlJ,EAAOmJ,OAC1CnJ,EAAOmJ,KAAO,CAAC,EAEnB,G","sources":["webpack://i4proportal/./node_modules/echarts/lib/component/graphic.js","webpack://i4proportal/./node_modules/echarts/lib/component/grid.js","webpack://i4proportal/./node_modules/echarts/lib/component/gridSimple.js"],"sourcesContent":["\n/*\n* Licensed to the Apache Software Foundation (ASF) under one\n* or more contributor license agreements. See the NOTICE file\n* distributed with this work for additional information\n* regarding copyright ownership. The ASF licenses this file\n* to you under the Apache License, Version 2.0 (the\n* \"License\"); you may not use this file except in compliance\n* with the License. You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing,\n* software distributed under the License is distributed on an\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n* KIND, either express or implied. See the License for the\n* specific language governing permissions and limitations\n* under the License.\n*/\n\nvar _config = require(\"../config\");\n\nvar __DEV__ = _config.__DEV__;\n\nvar echarts = require(\"../echarts\");\n\nvar zrUtil = require(\"zrender/lib/core/util\");\n\nvar modelUtil = require(\"../util/model\");\n\nvar graphicUtil = require(\"../util/graphic\");\n\nvar layoutUtil = require(\"../util/layout\");\n\nvar _number = require(\"../util/number\");\n\nvar parsePercent = _number.parsePercent;\n\n/*\n* Licensed to the Apache Software Foundation (ASF) under one\n* or more contributor license agreements. See the NOTICE file\n* distributed with this work for additional information\n* regarding copyright ownership. The ASF licenses this file\n* to you under the Apache License, Version 2.0 (the\n* \"License\"); you may not use this file except in compliance\n* with the License. You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing,\n* software distributed under the License is distributed on an\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n* KIND, either express or implied. See the License for the\n* specific language governing permissions and limitations\n* under the License.\n*/\nvar _nonShapeGraphicElements = {\n // Reserved but not supported in graphic component.\n path: null,\n compoundPath: null,\n // Supported in graphic component.\n group: graphicUtil.Group,\n image: graphicUtil.Image,\n text: graphicUtil.Text\n}; // -------------\n// Preprocessor\n// -------------\n\necharts.registerPreprocessor(function (option) {\n var graphicOption = option.graphic; // Convert\n // {graphic: [{left: 10, type: 'circle'}, ...]}\n // or\n // {graphic: {left: 10, type: 'circle'}}\n // to\n // {graphic: [{elements: [{left: 10, type: 'circle'}, ...]}]}\n\n if (zrUtil.isArray(graphicOption)) {\n if (!graphicOption[0] || !graphicOption[0].elements) {\n option.graphic = [{\n elements: graphicOption\n }];\n } else {\n // Only one graphic instance can be instantiated. (We dont\n // want that too many views are created in echarts._viewMap)\n option.graphic = [option.graphic[0]];\n }\n } else if (graphicOption && !graphicOption.elements) {\n option.graphic = [{\n elements: [graphicOption]\n }];\n }\n}); // ------\n// Model\n// ------\n\nvar GraphicModel = echarts.extendComponentModel({\n type: 'graphic',\n defaultOption: {\n // Extra properties for each elements:\n //\n // left/right/top/bottom: (like 12, '22%', 'center', default undefined)\n // If left/rigth is set, shape.x/shape.cx/position will not be used.\n // If top/bottom is set, shape.y/shape.cy/position will not be used.\n // This mechanism is useful when you want to position a group/element\n // against the right side or the center of this container.\n //\n // width/height: (can only be pixel value, default 0)\n // Only be used to specify contianer(group) size, if needed. And\n // can not be percentage value (like '33%'). See the reason in the\n // layout algorithm below.\n //\n // bounding: (enum: 'all' (default) | 'raw')\n // Specify how to calculate boundingRect when locating.\n // 'all': Get uioned and transformed boundingRect\n // from both itself and its descendants.\n // This mode simplies confining a group of elements in the bounding\n // of their ancester container (e.g., using 'right: 0').\n // 'raw': Only use the boundingRect of itself and before transformed.\n // This mode is similar to css behavior, which is useful when you\n // want an element to be able to overflow its container. (Consider\n // a rotated circle needs to be located in a corner.)\n // info: custom info. enables user to mount some info on elements and use them\n // in event handlers. Update them only when user specified, otherwise, remain.\n // Note: elements is always behind its ancestors in this elements array.\n elements: [],\n parentId: null\n },\n\n /**\n * Save el options for the sake of the performance (only update modified graphics).\n * The order is the same as those in option. (ancesters -> descendants)\n *\n * @private\n * @type {Array.}\n */\n _elOptionsToUpdate: null,\n\n /**\n * @override\n */\n mergeOption: function (option) {\n // Prevent default merge to elements\n var elements = this.option.elements;\n this.option.elements = null;\n GraphicModel.superApply(this, 'mergeOption', arguments);\n this.option.elements = elements;\n },\n\n /**\n * @override\n */\n optionUpdated: function (newOption, isInit) {\n var thisOption = this.option;\n var newList = (isInit ? thisOption : newOption).elements;\n var existList = thisOption.elements = isInit ? [] : thisOption.elements;\n var flattenedList = [];\n\n this._flatten(newList, flattenedList);\n\n var mappingResult = modelUtil.mappingToExists(existList, flattenedList);\n modelUtil.makeIdAndName(mappingResult); // Clear elOptionsToUpdate\n\n var elOptionsToUpdate = this._elOptionsToUpdate = [];\n zrUtil.each(mappingResult, function (resultItem, index) {\n var newElOption = resultItem.option;\n\n if (!newElOption) {\n return;\n }\n\n elOptionsToUpdate.push(newElOption);\n setKeyInfoToNewElOption(resultItem, newElOption);\n mergeNewElOptionToExist(existList, index, newElOption);\n setLayoutInfoToExist(existList[index], newElOption);\n }, this); // Clean\n\n for (var i = existList.length - 1; i >= 0; i--) {\n if (existList[i] == null) {\n existList.splice(i, 1);\n } else {\n // $action should be volatile, otherwise option gotten from\n // `getOption` will contain unexpected $action.\n delete existList[i].$action;\n }\n }\n },\n\n /**\n * Convert\n * [{\n * type: 'group',\n * id: 'xx',\n * children: [{type: 'circle'}, {type: 'polygon'}]\n * }]\n * to\n * [\n * {type: 'group', id: 'xx'},\n * {type: 'circle', parentId: 'xx'},\n * {type: 'polygon', parentId: 'xx'}\n * ]\n *\n * @private\n * @param {Array.} optionList option list\n * @param {Array.} result result of flatten\n * @param {Object} parentOption parent option\n */\n _flatten: function (optionList, result, parentOption) {\n zrUtil.each(optionList, function (option) {\n if (!option) {\n return;\n }\n\n if (parentOption) {\n option.parentOption = parentOption;\n }\n\n result.push(option);\n var children = option.children;\n\n if (option.type === 'group' && children) {\n this._flatten(children, result, option);\n } // Deleting for JSON output, and for not affecting group creation.\n\n\n delete option.children;\n }, this);\n },\n // FIXME\n // Pass to view using payload? setOption has a payload?\n useElOptionsToUpdate: function () {\n var els = this._elOptionsToUpdate; // Clear to avoid render duplicately when zooming.\n\n this._elOptionsToUpdate = null;\n return els;\n }\n}); // -----\n// View\n// -----\n\necharts.extendComponentView({\n type: 'graphic',\n\n /**\n * @override\n */\n init: function (ecModel, api) {\n /**\n * @private\n * @type {module:zrender/core/util.HashMap}\n */\n this._elMap = zrUtil.createHashMap();\n /**\n * @private\n * @type {module:echarts/graphic/GraphicModel}\n */\n\n this._lastGraphicModel;\n },\n\n /**\n * @override\n */\n render: function (graphicModel, ecModel, api) {\n // Having leveraged between use cases and algorithm complexity, a very\n // simple layout mechanism is used:\n // The size(width/height) can be determined by itself or its parent (not\n // implemented yet), but can not by its children. (Top-down travel)\n // The location(x/y) can be determined by the bounding rect of itself\n // (can including its descendants or not) and the size of its parent.\n // (Bottom-up travel)\n // When `chart.clear()` or `chart.setOption({...}, true)` with the same id,\n // view will be reused.\n if (graphicModel !== this._lastGraphicModel) {\n this._clear();\n }\n\n this._lastGraphicModel = graphicModel;\n\n this._updateElements(graphicModel);\n\n this._relocate(graphicModel, api);\n },\n\n /**\n * Update graphic elements.\n *\n * @private\n * @param {Object} graphicModel graphic model\n */\n _updateElements: function (graphicModel) {\n var elOptionsToUpdate = graphicModel.useElOptionsToUpdate();\n\n if (!elOptionsToUpdate) {\n return;\n }\n\n var elMap = this._elMap;\n var rootGroup = this.group; // Top-down tranverse to assign graphic settings to each elements.\n\n zrUtil.each(elOptionsToUpdate, function (elOption) {\n var $action = elOption.$action;\n var id = elOption.id;\n var existEl = elMap.get(id);\n var parentId = elOption.parentId;\n var targetElParent = parentId != null ? elMap.get(parentId) : rootGroup;\n var elOptionStyle = elOption.style;\n\n if (elOption.type === 'text' && elOptionStyle) {\n // In top/bottom mode, textVerticalAlign should not be used, which cause\n // inaccurately locating.\n if (elOption.hv && elOption.hv[1]) {\n elOptionStyle.textVerticalAlign = elOptionStyle.textBaseline = null;\n } // Compatible with previous setting: both support fill and textFill,\n // stroke and textStroke.\n\n\n !elOptionStyle.hasOwnProperty('textFill') && elOptionStyle.fill && (elOptionStyle.textFill = elOptionStyle.fill);\n !elOptionStyle.hasOwnProperty('textStroke') && elOptionStyle.stroke && (elOptionStyle.textStroke = elOptionStyle.stroke);\n } // Remove unnecessary props to avoid potential problems.\n\n\n var elOptionCleaned = getCleanedElOption(elOption); // For simple, do not support parent change, otherwise reorder is needed.\n\n if (!$action || $action === 'merge') {\n existEl ? existEl.attr(elOptionCleaned) : createEl(id, targetElParent, elOptionCleaned, elMap);\n } else if ($action === 'replace') {\n removeEl(existEl, elMap);\n createEl(id, targetElParent, elOptionCleaned, elMap);\n } else if ($action === 'remove') {\n removeEl(existEl, elMap);\n }\n\n var el = elMap.get(id);\n\n if (el) {\n el.__ecGraphicWidthOption = elOption.width;\n el.__ecGraphicHeightOption = elOption.height;\n setEventData(el, graphicModel, elOption);\n }\n });\n },\n\n /**\n * Locate graphic elements.\n *\n * @private\n * @param {Object} graphicModel graphic model\n * @param {module:echarts/ExtensionAPI} api extension API\n */\n _relocate: function (graphicModel, api) {\n var elOptions = graphicModel.option.elements;\n var rootGroup = this.group;\n var elMap = this._elMap;\n var apiWidth = api.getWidth();\n var apiHeight = api.getHeight(); // Top-down to calculate percentage width/height of group\n\n for (var i = 0; i < elOptions.length; i++) {\n var elOption = elOptions[i];\n var el = elMap.get(elOption.id);\n\n if (!el || !el.isGroup) {\n continue;\n }\n\n var parentEl = el.parent;\n var isParentRoot = parentEl === rootGroup; // Like 'position:absolut' in css, default 0.\n\n el.__ecGraphicWidth = parsePercent(el.__ecGraphicWidthOption, isParentRoot ? apiWidth : parentEl.__ecGraphicWidth) || 0;\n el.__ecGraphicHeight = parsePercent(el.__ecGraphicHeightOption, isParentRoot ? apiHeight : parentEl.__ecGraphicHeight) || 0;\n } // Bottom-up tranvese all elements (consider ec resize) to locate elements.\n\n\n for (var i = elOptions.length - 1; i >= 0; i--) {\n var elOption = elOptions[i];\n var el = elMap.get(elOption.id);\n\n if (!el) {\n continue;\n }\n\n var parentEl = el.parent;\n var containerInfo = parentEl === rootGroup ? {\n width: apiWidth,\n height: apiHeight\n } : {\n width: parentEl.__ecGraphicWidth,\n height: parentEl.__ecGraphicHeight\n }; // PENDING\n // Currently, when `bounding: 'all'`, the union bounding rect of the group\n // does not include the rect of [0, 0, group.width, group.height], which\n // is probably weird for users. Should we make a break change for it?\n\n layoutUtil.positionElement(el, elOption, containerInfo, null, {\n hv: elOption.hv,\n boundingMode: elOption.bounding\n });\n }\n },\n\n /**\n * Clear all elements.\n *\n * @private\n */\n _clear: function () {\n var elMap = this._elMap;\n elMap.each(function (el) {\n removeEl(el, elMap);\n });\n this._elMap = zrUtil.createHashMap();\n },\n\n /**\n * @override\n */\n dispose: function () {\n this._clear();\n }\n});\n\nfunction createEl(id, targetElParent, elOption, elMap) {\n var graphicType = elOption.type;\n var Clz = _nonShapeGraphicElements.hasOwnProperty(graphicType) // Those graphic elements are not shapes. They should not be\n // overwritten by users, so do them first.\n ? _nonShapeGraphicElements[graphicType] : graphicUtil.getShapeClass(graphicType);\n var el = new Clz(elOption);\n targetElParent.add(el);\n elMap.set(id, el);\n el.__ecGraphicId = id;\n}\n\nfunction removeEl(existEl, elMap) {\n var existElParent = existEl && existEl.parent;\n\n if (existElParent) {\n existEl.type === 'group' && existEl.traverse(function (el) {\n removeEl(el, elMap);\n });\n elMap.removeKey(existEl.__ecGraphicId);\n existElParent.remove(existEl);\n }\n} // Remove unnecessary props to avoid potential problems.\n\n\nfunction getCleanedElOption(elOption) {\n elOption = zrUtil.extend({}, elOption);\n zrUtil.each(['id', 'parentId', '$action', 'hv', 'bounding'].concat(layoutUtil.LOCATION_PARAMS), function (name) {\n delete elOption[name];\n });\n return elOption;\n}\n\nfunction isSetLoc(obj, props) {\n var isSet;\n zrUtil.each(props, function (prop) {\n obj[prop] != null && obj[prop] !== 'auto' && (isSet = true);\n });\n return isSet;\n}\n\nfunction setKeyInfoToNewElOption(resultItem, newElOption) {\n var existElOption = resultItem.exist; // Set id and type after id assigned.\n\n newElOption.id = resultItem.keyInfo.id;\n !newElOption.type && existElOption && (newElOption.type = existElOption.type); // Set parent id if not specified\n\n if (newElOption.parentId == null) {\n var newElParentOption = newElOption.parentOption;\n\n if (newElParentOption) {\n newElOption.parentId = newElParentOption.id;\n } else if (existElOption) {\n newElOption.parentId = existElOption.parentId;\n }\n } // Clear\n\n\n newElOption.parentOption = null;\n}\n\nfunction mergeNewElOptionToExist(existList, index, newElOption) {\n // Update existing options, for `getOption` feature.\n var newElOptCopy = zrUtil.extend({}, newElOption);\n var existElOption = existList[index];\n var $action = newElOption.$action || 'merge';\n\n if ($action === 'merge') {\n if (existElOption) {\n // We can ensure that newElOptCopy and existElOption are not\n // the same object, so `merge` will not change newElOptCopy.\n zrUtil.merge(existElOption, newElOptCopy, true); // Rigid body, use ignoreSize.\n\n layoutUtil.mergeLayoutParam(existElOption, newElOptCopy, {\n ignoreSize: true\n }); // Will be used in render.\n\n layoutUtil.copyLayoutParams(newElOption, existElOption);\n } else {\n existList[index] = newElOptCopy;\n }\n } else if ($action === 'replace') {\n existList[index] = newElOptCopy;\n } else if ($action === 'remove') {\n // null will be cleaned later.\n existElOption && (existList[index] = null);\n }\n}\n\nfunction setLayoutInfoToExist(existItem, newElOption) {\n if (!existItem) {\n return;\n }\n\n existItem.hv = newElOption.hv = [// Rigid body, dont care `width`.\n isSetLoc(newElOption, ['left', 'right']), // Rigid body, dont care `height`.\n isSetLoc(newElOption, ['top', 'bottom'])]; // Give default group size. Otherwise layout error may occur.\n\n if (existItem.type === 'group') {\n existItem.width == null && (existItem.width = newElOption.width = 0);\n existItem.height == null && (existItem.height = newElOption.height = 0);\n }\n}\n\nfunction setEventData(el, graphicModel, elOption) {\n var eventData = el.eventData; // Simple optimize for large amount of elements that no need event.\n\n if (!el.silent && !el.ignore && !eventData) {\n eventData = el.eventData = {\n componentType: 'graphic',\n componentIndex: graphicModel.componentIndex,\n name: el.name\n };\n } // `elOption.info` enables user to mount some info on\n // elements and use them in event handlers.\n\n\n if (eventData) {\n eventData.info = el.info;\n }\n}","\n/*\n* Licensed to the Apache Software Foundation (ASF) under one\n* or more contributor license agreements. See the NOTICE file\n* distributed with this work for additional information\n* regarding copyright ownership. The ASF licenses this file\n* to you under the Apache License, Version 2.0 (the\n* \"License\"); you may not use this file except in compliance\n* with the License. You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing,\n* software distributed under the License is distributed on an\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n* KIND, either express or implied. See the License for the\n* specific language governing permissions and limitations\n* under the License.\n*/\n\nrequire(\"./gridSimple\");\n\nrequire(\"./axisPointer/CartesianAxisPointer\");\n\nrequire(\"./axisPointer\");","\n/*\n* Licensed to the Apache Software Foundation (ASF) under one\n* or more contributor license agreements. See the NOTICE file\n* distributed with this work for additional information\n* regarding copyright ownership. The ASF licenses this file\n* to you under the Apache License, Version 2.0 (the\n* \"License\"); you may not use this file except in compliance\n* with the License. You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing,\n* software distributed under the License is distributed on an\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n* KIND, either express or implied. See the License for the\n* specific language governing permissions and limitations\n* under the License.\n*/\n\nvar echarts = require(\"../echarts\");\n\nvar zrUtil = require(\"zrender/lib/core/util\");\n\nvar graphic = require(\"../util/graphic\");\n\nrequire(\"../coord/cartesian/Grid\");\n\nrequire(\"./axis\");\n\n/*\n* Licensed to the Apache Software Foundation (ASF) under one\n* or more contributor license agreements. See the NOTICE file\n* distributed with this work for additional information\n* regarding copyright ownership. The ASF licenses this file\n* to you under the Apache License, Version 2.0 (the\n* \"License\"); you may not use this file except in compliance\n* with the License. You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing,\n* software distributed under the License is distributed on an\n* \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n* KIND, either express or implied. See the License for the\n* specific language governing permissions and limitations\n* under the License.\n*/\n// Grid view\necharts.extendComponentView({\n type: 'grid',\n render: function (gridModel, ecModel) {\n this.group.removeAll();\n\n if (gridModel.get('show')) {\n this.group.add(new graphic.Rect({\n shape: gridModel.coordinateSystem.getRect(),\n style: zrUtil.defaults({\n fill: gridModel.get('backgroundColor')\n }, gridModel.getItemStyle()),\n silent: true,\n z2: -1\n }));\n }\n }\n});\necharts.registerPreprocessor(function (option) {\n // Only create grid when need\n if (option.xAxis && option.yAxis && !option.grid) {\n option.grid = {};\n }\n});"],"names":["_config","echarts","__DEV__","zrUtil","modelUtil","graphicUtil","layoutUtil","_number","parsePercent","_nonShapeGraphicElements","path","compoundPath","group","Group","image","Image","text","Text","registerPreprocessor","option","graphicOption","graphic","isArray","elements","GraphicModel","extendComponentModel","type","defaultOption","parentId","_elOptionsToUpdate","mergeOption","this","superApply","arguments","optionUpdated","newOption","isInit","thisOption","newList","existList","flattenedList","_flatten","mappingResult","mappingToExists","makeIdAndName","elOptionsToUpdate","each","resultItem","index","newElOption","push","setKeyInfoToNewElOption","mergeNewElOptionToExist","setLayoutInfoToExist","i","length","splice","$action","optionList","result","parentOption","children","useElOptionsToUpdate","els","createEl","id","targetElParent","elOption","elMap","graphicType","Clz","hasOwnProperty","getShapeClass","el","add","set","__ecGraphicId","removeEl","existEl","existElParent","parent","traverse","removeKey","remove","getCleanedElOption","extend","concat","LOCATION_PARAMS","name","isSetLoc","obj","props","isSet","prop","existElOption","exist","keyInfo","newElParentOption","newElOptCopy","merge","mergeLayoutParam","ignoreSize","copyLayoutParams","existItem","hv","width","height","setEventData","graphicModel","eventData","silent","ignore","componentType","componentIndex","info","extendComponentView","init","ecModel","api","_elMap","createHashMap","_lastGraphicModel","render","_clear","_updateElements","_relocate","rootGroup","get","elOptionStyle","style","textVerticalAlign","textBaseline","fill","textFill","stroke","textStroke","elOptionCleaned","attr","__ecGraphicWidthOption","__ecGraphicHeightOption","elOptions","apiWidth","getWidth","apiHeight","getHeight","isGroup","parentEl","isParentRoot","__ecGraphicWidth","__ecGraphicHeight","containerInfo","positionElement","boundingMode","bounding","dispose","gridModel","removeAll","Rect","shape","coordinateSystem","getRect","defaults","getItemStyle","z2","xAxis","yAxis","grid"],"sourceRoot":""}