I was able to get only the rectangle. Not able to figure out how to produce the cut in the bottom?
define(['jquery', 'knockout', 'd3', 'data/server', 'css!app/css/vista'],function($, ko, d3, server){
return {
activate: function(){
},
compositionComplete: function(){
var self = this;
self.loadyourRank();
},
loadyourRank: function(){
var data = [3];
var width = 325, height = 430;
var svgContainer = d3.select("#yourrank")
.append("svg")
.attr("width", width)
.attr("height", height);
svgContainer.selectAll("rect")
.data(data)
.enter()
.append("rect")
.attr("x", 30)
.attr("y", 50)
.attr("width", 255)
.attr("height", 340)
.attr("fill", "#F2135D")
.attr("stroke", "gray");
}
};
});
<div class="card">
<div class="row">
<div id="yourrank" class="col-xs-4">
<h4>Your Rank</h4>
</div>
<div id="bestrank" class="col-xs-8">
<h4>Your Best Ranked Specialities</h4>
</div>
</div>
</div>
How to get the above shape or element in svg using d3.js ?? somebody help