我尝试生成具有“自定义原始类型”(NonEmptyString)的有效载荷类,但代码生成是在String中生成的。
你能帮我吗?规格有很多变化吗?还是自定义生成器? 这是我的YAML示例文件
.subBar {
fill: gray;
opacity: 0.5;
}
.axis path,
.y-axis line {
fill: none;
stroke: #000;
shape-rendering: crispEdges;
}
.brush .extent {
stroke: #fff;
fill: steelblue;
fill-opacity: .25;
shape-rendering: crispEdges;
}
rect.mover {
stroke: red;
stroke-opacity: .1;
fill: lightSteelBlue ;
fill-opacity: .5;
}
.disable{
fill: #c0c0c0 !important;
}
.y-axis line{
stroke: lightgray;
stroke-opacity: 0.7;
shape-rendering: crispEdges;
}
我想吃这个
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.17/d3.min.js"></script>
<div>
<select name = "userId" id="userId" href = "javascript:void(0);" onchange="buildBar(1)">
<option selected disabled>Select User ID</option>
<option value="AAAA0009">AAAA0009</option>
<option value="AAAA0010">AAAA0010</option>
<option value="AAAA0011">AAAA0011</option>
<option value="AAAA0003">AAAA0003</option>
<option value="AAAA0002">AAAA0002</option>
<option value="AAAA0004">AAAA0004</option>
<option value="AAAA0006">AAAA0006</option>
<option value="AAAA0007">AAAA0007</option>
<option value="AAAA0008">AAAA0008</option>
<option value="AAAA0005">AAAA0005</option>
<option value="AAAA0001">AAAA0001</option>
<option value="AAAA0000">AAAA0000</option>
<option value="clay">clay</option>
<option value="rohi1234">rohi1234</option>
<option value="rohi1236">rohi1236</option>
<option value="AAAA0012">AAAA0012</option>
<option value="AAAA0013">AAAA0013</option>
<option value="AAAA0014">AAAA0014</option>
<option value="AAAA0015">AAAA0015</option>
<option value="AAAA0016">AAAA0016</option>
<option value="AAAA0017">AAAA0017</option>
<option value="daca2111">daca2111</option>
</select>
</div>
<div id="topChart" style=" width: 800px;">
<!-- <div id="barChartLegend"></div> -->
<svg id="barChartLegend"></svg>
<div id="barChart" href = "javascript:void(0);" onclick="buildBar(0)"></div>
</div>
但是codegen给我这个:
function clearText(){
var exp = document.getElementById('id');
exp.innerHTML = '';
}
感谢您的帮助