>#### 圓角
~~~
option = {
title: {
text: '頂部顯示文字',
textStyle: {
color: '#ffffff'
},
top: 5,
left: 'center',
},
toolbox: {
feature: {
saveAsImage: {}
}
},
backgroundColor: "#0f375f",
color: [
'#60acfc',
'#feb64d',
'#5bc49f',
'#ff7b7b',
'#32d3eb',
'#9287e7',
'#4777cd',
'#70ad47',
'#61a6e4',
'#ffc900',
'#ff7820',
'#8d50bf',
'#02b67a',
'#5470c6',
'#91cc75',
'#fac858',
'#ee6666',
'#73c0de',
'#3ba272',
'#fc8452',
'#ea7ccc',
'#00bfb7',
'#ff6480',
'#9a60b4',
],
tooltip: {
trigger: 'axis',
axisPointer: {
type: 'shadow',
},
},
legend: {
orient: 'vertical',
x: 'right',
y: 'center',
align: 'left',
textStyle: {
color: '#81b0d6',
},
padding: 10,
data: ['蘇寧', '考拉', '京東', '天貓', '淘寶'],
},
grid: {
top: '14%',
right: 160,
containLabel: true,
},
xAxis: {
type: 'category',
axisTick: {
show: false,
},
data: ['Total', 'suning', 'kaola', 'jd', 'tmall', 'tb'],
},
yAxis: {
type: 'value',
axisLabel: {
show: false,
},
axisLine: {
show: false,
},
axisTick: {
show: false,
},
splitLine: {
show: false,
},
},
series: [{
type: 'bar',
stack: 'one',
align: 'inside',
name: '淘寶',
data: [12.51, '-', 10, '-', '-', 43],
barWidth: '40%',
label: {
show: true,
position: 'inside',
fontSize: 12,
color: 'white',
textBorderWidth: 1,
textBorderColor: 'inherit',
},
labelLayout: {
hideOverlap: true,
},
},
{
type: 'bar',
stack: 'one',
align: 'inside',
name: '天貓',
data: [53.08, 10, 8, '-', 14, 17],
barWidth: '40%',
label: {
show: true,
position: 'inside',
fontSize: 12,
color: 'white',
textBorderWidth: 1,
textBorderColor: 'inherit',
},
labelLayout: {
hideOverlap: true,
},
},
{
type: 'bar',
stack: 'one',
align: 'inside',
name: '京東',
data: [32.34, 27, 20, 100, 24, 12],
barWidth: '40%',
label: {
show: true,
position: 'inside',
fontSize: 12,
color: 'white',
textBorderWidth: 1,
textBorderColor: 'inherit',
},
labelLayout: {
hideOverlap: true,
},
},
{
type: 'bar',
stack: 'one',
align: 'inside',
name: '考拉',
data: [0.09, '-', 52, '-', 32, 18],
barWidth: '40%',
label: {
show: true,
position: 'inside',
fontSize: 12,
color: 'white',
textBorderWidth: 1,
textBorderColor: 'inherit',
},
labelLayout: {
hideOverlap: true,
},
},
{
type: 'bar',
stack: 'one',
align: 'inside',
name: '蘇寧',
data: [1.97, 13, 10, '-', 20, 10],
barWidth: '40%',
label: {
show: true,
position: 'inside',
fontSize: 12,
color: 'white',
textBorderWidth: 1,
textBorderColor: 'inherit',
},
labelLayout: {
hideOverlap: true,
},
},
{
type: 'bar',
name: '總數',
color: 'rgba(0,0,0,0)',
data: [100, 50, 100, 100, 90, 100],
barWidth: 0,
label: {
show: true,
position: 'top',
fontSize: 12,
},
z: -1,
barGap: '-100%',
labelLayout: {
hideOverlap: true,
},
},
],
};
~~~
>#### 效果圖

<hr>
- html
- 頭部標簽
- canvas
- md
- DOM
- git常用命令
- css
- 網站
- 默認
- 前綴
- 文本
- 圖片
- 選擇器
- 滾動條
- 強制橫屏
- 響應式
- 動畫
- animation(動畫)
- transition(過渡)
- transform(變形)
- translate(移動)
- 漸變
- 鼠標
- 自定義 Web 字體
- 可視化
- echarts
- 折線圖
- 區域顏色標識
- 分段顯示不同顏色
- 柱狀圖
- 子彈圖
- 分組、柱體寬度、指示器寬度
- 圓角
- 頂部顯示文字
- 雙軸柱狀折線圖
- 雙軸雙列柱狀圖
- 單個柱狀圖
- 多縱向坐標
- 走勢圖
- 橫向百分比
- 最大值和最小值
- 餅圖
- 嵌套
- 分組顯示
- 餅圖結合柱狀圖
- 折線結合餅圖
- 關系圖
- 樹圖
- 地圖
- 標點
- 選中
- 常用
- 圖片超出可拖拽
- 百度導航
- 短信驗證碼倒計時
- video
- TS
- 未整理
- 消失的邊界線問題
- 跟隨
- js
- 兼容
- 數組去重
- 解析 URL 參數為對象
- 圖片懶加載
- 正則
- Photoshop
- 快捷鍵
- 混合模式
- vscode
- vue
- 指令