mirror of
https://github.com/bckelley/cgm-remote-monitor.git
synced 2026-08-24 03:14:12 -05:00
remove clipping path that wasn't needed and caused problems on iOS
This commit is contained in:
@@ -295,14 +295,6 @@ function init (client, d3, $) {
|
||||
d3.select('.x.brush').select('.resize.e').style('cursor', 'move');
|
||||
d3.select('.x.brush').select('.resize.w').style('cursor', 'move');
|
||||
|
||||
// create a clipPath for when brushing
|
||||
chart.clip = chart.charts.append('defs')
|
||||
.append('clipPath')
|
||||
.attr('id', 'clip')
|
||||
.append('rect')
|
||||
.attr('height', chartHeight)
|
||||
.attr('width', chartWidth);
|
||||
|
||||
// add a line that marks the current time
|
||||
chart.focus.append('line')
|
||||
.attr('class', 'now-line')
|
||||
@@ -424,13 +416,6 @@ function init (client, d3, $) {
|
||||
// .attr('transform', 'translate(0,' + 0 + ')')
|
||||
// .call(chart.yAxisBasals);
|
||||
|
||||
if (chart.clip) {
|
||||
// reset clip to new dimensions
|
||||
chart.clip.transition()
|
||||
.attr('width', chartWidth)
|
||||
.attr('height', chartHeight);
|
||||
}
|
||||
|
||||
// reset brush location
|
||||
chart.context.select('.x.brush')
|
||||
.selectAll('rect')
|
||||
|
||||
@@ -164,9 +164,6 @@ function init (client, d3) {
|
||||
.on('mouseout', hideTooltip);
|
||||
|
||||
focusCircles.exit().remove();
|
||||
|
||||
// add clipping path so that data stays within axis
|
||||
focusCircles.attr('clip-path', 'url(#clip)');
|
||||
};
|
||||
|
||||
renderer.addTreatmentCircles = function addTreatmentCircles ( ) {
|
||||
@@ -259,8 +256,6 @@ function init (client, d3) {
|
||||
})
|
||||
.on('mouseout', hideTooltip);
|
||||
|
||||
treatCircles.attr('clip-path', 'url(#clip)');
|
||||
|
||||
var durationTreatments = client.ddata.treatments.filter(function(treatment) {
|
||||
return !treatment.carbs && !treatment.insulin && treatment.duration &&
|
||||
! _.includes(['Temp Basal', 'Profile Switch', 'Combo Bolus', 'Temporary Target'], treatment.eventType);
|
||||
@@ -352,9 +347,6 @@ function init (client, d3) {
|
||||
}
|
||||
return d.notes || d.eventType;
|
||||
});
|
||||
|
||||
|
||||
treatRects.attr('clip-path', 'url(#clip)');
|
||||
};
|
||||
|
||||
renderer.addContextCircles = function addContextCircles ( ) {
|
||||
@@ -974,7 +966,6 @@ function init (client, d3) {
|
||||
.attr('stroke-width', 1)
|
||||
.attr('fill', 'none')
|
||||
.attr('d', valueline(linedata))
|
||||
.attr('clip-path', 'url(#clip)');
|
||||
|
||||
g.append('path')
|
||||
.attr('class', 'line notempline')
|
||||
@@ -983,7 +974,6 @@ function init (client, d3) {
|
||||
.attr('stroke-dasharray', ('3, 3'))
|
||||
.attr('fill', 'none')
|
||||
.attr('d', valueline(notemplinedata))
|
||||
.attr('clip-path', 'url(#clip)');
|
||||
|
||||
g.append('path')
|
||||
.attr('class', 'area basalarea')
|
||||
|
||||
Reference in New Issue
Block a user