diff --git a/development/ui/front-end/src/app/shared/components/filter-panel/filter-panel.component.ts b/development/ui/front-end/src/app/shared/components/filter-panel/filter-panel.component.ts index c952c14a..459fdd20 100644 --- a/development/ui/front-end/src/app/shared/components/filter-panel/filter-panel.component.ts +++ b/development/ui/front-end/src/app/shared/components/filter-panel/filter-panel.component.ts @@ -8,7 +8,7 @@ import { Component, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChange export class FilterPanelComponent implements OnInit, OnChanges { @Input() filters: any = []; - @Input() colSize: any = "md:col-span-3 xs:col-span-6 xmd:col-span-4"; + @Input() colSize: any = "md:col-span-3 xs:col-span-12 xmd:col-span-4"; @Input() resetOthers = true; @Output() filtersUpdated = new EventEmitter(); diff --git a/development/ui/front-end/src/app/shared/components/level-n-metric-filter-panel/level-n-metric-filter-panel.component.html b/development/ui/front-end/src/app/shared/components/level-n-metric-filter-panel/level-n-metric-filter-panel.component.html index 5dad0c5b..992a1c71 100644 --- a/development/ui/front-end/src/app/shared/components/level-n-metric-filter-panel/level-n-metric-filter-panel.component.html +++ b/development/ui/front-end/src/app/shared/components/level-n-metric-filter-panel/level-n-metric-filter-panel.component.html @@ -2,7 +2,7 @@
-
+
{{ option.label }} diff --git a/development/ui/front-end/src/app/shared/components/maps/leaflet-map/leaflet-map.component.ts b/development/ui/front-end/src/app/shared/components/maps/leaflet-map/leaflet-map.component.ts index 3aa03a53..5caffe5d 100644 --- a/development/ui/front-end/src/app/shared/components/maps/leaflet-map/leaflet-map.component.ts +++ b/development/ui/front-end/src/app/shared/components/maps/leaflet-map/leaflet-map.component.ts @@ -72,7 +72,7 @@ export class LeafletMapComponent implements OnInit, AfterViewInit, OnChanges { // var imageUrl ='https://i.stack.imgur.com/khgzZ.png', // imageBounds = [[80.0, -350.0], [-40.0, 400.0]]; // L.imageOverlay(imageUrl, imageBounds, {opacity: 0.3}).addTo(this.map); - if(environment.config === 'NVSK' && this.level === 'district'){ + if (environment.config === 'NVSK' && this.level === 'district') { this.createMarkers(this.mapData); } this.map.on('resize', () => { @@ -125,10 +125,10 @@ export class LeafletMapComponent implements OnInit, AfterViewInit, OnChanges { // else { // return "#fff" // } - if(environment.config === 'NVSK' && this.level === 'district' && !legend){ + if (environment.config === 'NVSK' && this.level === 'district' && !legend) { return '#FFFFFF' } - else{ + else { let reportTypeBoolean = false; if (typeof e === 'string') { reportTypeBoolean = true; @@ -189,32 +189,38 @@ export class LeafletMapComponent implements OnInit, AfterViewInit, OnChanges { }); let range = max - min; - // let partSize = (range / 10 % 1 === 0) ? range / 10 : Number((range / 10).toFixed(2)); - let partSize = (range / 4 % 1 === 0) ? range / 4 : Number((range / 4).toFixed(2)); - for (let i = 1; i <= 5; i++) { - if (i === 5) { - if(min === 0){ - values.push(this.perCapitaReport ? 0.1 : 1); + if (range) { + let partSize = (range / 4 % 1 === 0) ? range / 4 : Number((range / 4).toFixed(2)); + for (let i = 1; i <= 5; i++) { + if (i === 5) { + if (min === 0) { + values.push(this.perCapitaReport ? 0.1 : 1); + } + else { + values.push(this.perCapitaReport ? min : min.toFixed(0)); + } + continue; } - else{ - values.push(this.perCapitaReport ? min :min.toFixed(0)); + + if (i === 1) { + values.push(this.perCapitaReport ? max : max.toFixed(0)); + continue; + } + if (this.perCapitaReport) { + let value = Number((max - partSize * (i - 1)).toFixed(2)) + values.push(value) + } + else { + let value = Number((max - partSize * (i - 1)).toFixed(0)) + values.push(value >= 1 ? value : 1) } - continue; - } - - if (i === 1) { - values.push(this.perCapitaReport ? max :max.toFixed(0)); - continue; - } - if(this.perCapitaReport){ - let value = Number((max - partSize * (i - 1)).toFixed(2)) - values.push(value) - } - else{ - let value = Number((max - partSize * (i - 1)).toFixed(0)) - values.push(value >= 1 ? value : 1) } } + else{ + values.push(min); + } + // let partSize = (range / 10 % 1 === 0) ? range / 10 : Number((range / 10).toFixed(2)); + } function styleStates(feature: any) { @@ -228,7 +234,7 @@ export class LeafletMapComponent implements OnInit, AfterViewInit, OnChanges { if (state.state_code == feature.properties.state_code && !state.district_code) { color = parent.getLayerColor(state.indicator ? (max - min ? (state.indicator - min) / (max - min) * 100 : state.indicator) : -1); } - else if(state.district_code && state.district_code == feature.properties.dtcode11){ + else if (state.district_code && state.district_code == feature.properties.dtcode11) { color = parent.getLayerColor(state.indicator ? (max - min ? (state.indicator - min) / (max - min) * 100 : state.indicator) : -1); } }); @@ -250,17 +256,17 @@ export class LeafletMapComponent implements OnInit, AfterViewInit, OnChanges { if (state.state_code == feature.properties.state_code && !state.district_code) { popup = state.tooltip } - else if(state.district_code && state.district_code == feature.properties.dtcode11){ + else if (state.district_code && state.district_code == feature.properties.dtcode11) { popup = state.tooltip } }); return popup; } - + this.countryGeoJSON = L.geoJSON(data['features'], { onEachFeature: function (feature: any, layer: any) { - if(!(environment.config === 'NVSK' && parent.level === 'district')){ - if(getPopUp(feature)){ + if (!(environment.config === 'NVSK' && parent.level === 'district')) { + if (getPopUp(feature)) { layer.bindTooltip(getPopUp(feature), { classname: "app-leaflet-tooltip", sticky: true }); } } @@ -309,10 +315,10 @@ export class LeafletMapComponent implements OnInit, AfterViewInit, OnChanges { let partSize = (range / 4 % 1 === 0) ? range / 4 : Number((range / 4).toFixed(2)); for (let i = 1; i <= 5; i++) { if (i === 5) { - if(min === 0){ + if (min === 0) { values.push(1); } - else{ + else { values.push(min.toFixed(0)); } // values.push(min); @@ -377,9 +383,11 @@ export class LeafletMapComponent implements OnInit, AfterViewInit, OnChanges { if (mapOptions.legend && mapOptions.legend.title) { labels.push(`${mapOptions.legend.title}:`) } - if (reportTypeIndicator === 'boolean') { + if(values.length <= 1 && reportTypeIndicator !== 'boolean'){ + labels.push(` ${values[0]}`); + } + else if (reportTypeIndicator === 'boolean') { values = ["Yes", "No"]; - for (let i = 0; i < values.length; i++) { labels.push(` ${values[i]}`); } diff --git a/development/ui/front-end/src/app/views/foundational-literacy-numeracy/pages/garde-wise-resource/garde-wise-resource.component.html b/development/ui/front-end/src/app/views/foundational-literacy-numeracy/pages/garde-wise-resource/garde-wise-resource.component.html index d2c07ab9..f57a92ce 100644 --- a/development/ui/front-end/src/app/views/foundational-literacy-numeracy/pages/garde-wise-resource/garde-wise-resource.component.html +++ b/development/ui/front-end/src/app/views/foundational-literacy-numeracy/pages/garde-wise-resource/garde-wise-resource.component.html @@ -1,6 +1,6 @@
- +
diff --git a/development/ui/front-end/src/app/views/nishtha/pages/nishitha-table/nishitha-table.component.html b/development/ui/front-end/src/app/views/nishtha/pages/nishitha-table/nishitha-table.component.html index bfffaeb6..64d57b5c 100644 --- a/development/ui/front-end/src/app/views/nishtha/pages/nishitha-table/nishitha-table.component.html +++ b/development/ui/front-end/src/app/views/nishtha/pages/nishitha-table/nishitha-table.component.html @@ -1,6 +1,6 @@
- +
diff --git a/development/ui/front-end/src/app/views/nishtha/pages/nishtha-program-detail/nishtha-program-detail.component.html b/development/ui/front-end/src/app/views/nishtha/pages/nishtha-program-detail/nishtha-program-detail.component.html index f65332cd..908a1211 100644 --- a/development/ui/front-end/src/app/views/nishtha/pages/nishtha-program-detail/nishtha-program-detail.component.html +++ b/development/ui/front-end/src/app/views/nishtha/pages/nishtha-program-detail/nishtha-program-detail.component.html @@ -1,7 +1,7 @@
- +

Loading...

diff --git a/development/ui/front-end/src/app/views/nishtha/pages/nisitha-stacked-bar/nisitha-stacked-bar.component.html b/development/ui/front-end/src/app/views/nishtha/pages/nisitha-stacked-bar/nisitha-stacked-bar.component.html index 631c6291..56e3034f 100644 --- a/development/ui/front-end/src/app/views/nishtha/pages/nisitha-stacked-bar/nisitha-stacked-bar.component.html +++ b/development/ui/front-end/src/app/views/nishtha/pages/nisitha-stacked-bar/nisitha-stacked-bar.component.html @@ -1,6 +1,6 @@
- +
diff --git a/development/ui/front-end/src/app/views/nishtha/pages/total-courses-table/total-courses-table.component.html b/development/ui/front-end/src/app/views/nishtha/pages/total-courses-table/total-courses-table.component.html index d05fbfc7..07c32afd 100644 --- a/development/ui/front-end/src/app/views/nishtha/pages/total-courses-table/total-courses-table.component.html +++ b/development/ui/front-end/src/app/views/nishtha/pages/total-courses-table/total-courses-table.component.html @@ -1,6 +1,6 @@
- +
\ No newline at end of file diff --git a/development/ui/front-end/src/app/views/quiz/quiz.component.html b/development/ui/front-end/src/app/views/quiz/quiz.component.html index 4614bdc7..1994dc7f 100644 --- a/development/ui/front-end/src/app/views/quiz/quiz.component.html +++ b/development/ui/front-end/src/app/views/quiz/quiz.component.html @@ -21,7 +21,7 @@
- +
diff --git a/development/ui/front-end/src/app/views/school-registry/pages/school-facilities-comparision/school-facilities-comparision.component.html b/development/ui/front-end/src/app/views/school-registry/pages/school-facilities-comparision/school-facilities-comparision.component.html index 4c5ba410..870791f9 100644 --- a/development/ui/front-end/src/app/views/school-registry/pages/school-facilities-comparision/school-facilities-comparision.component.html +++ b/development/ui/front-end/src/app/views/school-registry/pages/school-facilities-comparision/school-facilities-comparision.component.html @@ -23,9 +23,9 @@
- +
-
+