| * Licensed to the Apache Software Foundation (ASF) under one |
| * or more contributor license agreements. See the NOTICE file |
| * distributed with this work for additional information |
| * regarding copyright ownership. The ASF licenses this file |
| * to you under the Apache License, Version 2.0 (the |
| * "License"); you may not use this file except in compliance |
| * with the License. You may obtain a copy of the License at |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| * Unless required by applicable law or agreed to in writing, |
| * software distributed under the License is distributed on an |
| * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| * KIND, either express or implied. See the License for the |
| * specific language governing permissions and limitations |
| !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).barRangeCustomSeriesInstaller=t()}(this,(function(){"use strict";var e=function(e,t){var i=t.value(0),l=t.value(1),o=t.coord([i,l]),r=t.value(2),n=t.coord([i,r]),a=t.coord([1,0])[0]-t.coord([0,0])[0],s=e.itemPayload.barWidth;null==s&&(s="70%");var d="string"==typeof s&&s.endsWith("%")?parseFloat(s)/100*a:s,u=e.itemPayload.borderRadius||0,f={type:"rect",shape:{x:o[0]-d/2,y:o[1],width:d,height:n[1]-o[1],r:u},style:{fill:t.visual("color")}},c=e.itemPayload.margin,y=null==c?10:c;return{type:"group",children:[f,{type:"text",x:n[0],y:n[1]-y,style:{text:r.toString()+"℃",textAlign:"center",textVerticalAlign:"bottom",fill:"#333"}},{type:"text",x:o[0],y:o[1]+y,style:{text:l.toString()+"℃",textAlign:"center",textVerticalAlign:"top",fill:"#333"}}]}};return{install:function(t){t.registerCustomSeries("barRange",e)}}})); |
| //# sourceMappingURL=index.min.js.map |