Skip to content

Commit fffcc52

Browse files
authored
Merge pull request #497 from jeff-phillips-18/charts
Fix for charts in ng-docs, some component conversion fixes.
2 parents 216d77c + c22c1a5 commit fffcc52

File tree

6 files changed

+18
-18
lines changed

6 files changed

+18
-18
lines changed

Gruntfile.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,8 @@ module.exports = function (grunt) {
172172
'node_modules/datatables.net/js/jquery.dataTables.js',
173173
'node_modules/datatables.net-select/js/dataTables.select.js',
174174
'node_modules/moment/moment.js',
175-
'node_modules/c3/c3.js',
176175
'node_modules/d3/d3.js',
176+
'node_modules/c3/c3.js',
177177
'node_modules/patternfly/dist/js/patternfly-settings.js',
178178
'node_modules/patternfly/dist/js/patternfly-settings-colors.js',
179179
'node_modules/patternfly/dist/js/patternfly-settings-charts.js',

src/views/listview/list-view.component.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@
9090
<list-expanded-content>
9191
<div class="row">
9292
<div class="col-md-3">
93-
<div pf-donut-pct-chart config="exampleChartConfig" data="{'used': '350','total': '1000'}" center-label="'Percent Used'"></div>
93+
<pf-donut-pct-chart config="exampleChartConfig" data="{'used': '350','total': '1000'}" center-label="'Percent Used'"></pf-donut-pct-chart>
9494
</div>
9595
<div class="col-md-9">
9696
<dl class="dl-horizontal">

test/card/basic/card.spec.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ describe('Component: pfCard', function() {
5252

5353
it("should hide the top border", function() {
5454

55-
element = compileCard('<div pf-card head-title="My card title" sub-title="My card subtitle title" show-top-border="false">Inner content goes here</div>', $scope);
55+
element = compileCard('<pf-card head-title="My card title" sub-title="My card subtitle title" show-top-border="false">Inner content goes here</pf-card>', $scope);
5656

5757
// showTopBorder set to false, results in not having the .card-pf-accented class
5858
cardClass = angular.element(element).find('.card-pf').hasClass('card-pf-accented');
@@ -192,7 +192,7 @@ describe('Component: pfCard', function() {
192192
'position' : 'header'
193193
};
194194

195-
element = compileCard('<pf-card pf-card head-title="title" footer="{}" filter="filterConfig">Inner content</pf-card>', $scope);
195+
element = compileCard('<pf-card head-title="title" footer="{}" filter="filterConfig">Inner content</pf-card>', $scope);
196196

197197
// should NOT find any filters in the footer
198198
cardClass = angular.element(element).find('.card-pf-footer').find('a');

test/charts/c3/c3.spec.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,13 @@ describe('Directive: pfC3Chart', function() {
1313
beforeEach(function() {
1414
$scope.myChart = "myChartId";
1515
$scope.chartConfig = {};
16-
element = '<div pf-c3-chart id="myChart" config="chartConfig"></div>';
16+
element = '<pf-c3-chart id="myChart" config="chartConfig"></pf-c3-chart>';
1717
element = $compile(element)($scope);
1818
$scope.$digest();
1919
});
2020

2121
it("chart should find empty template", function() {
22-
expect(angular.element(element).html()).toBe("");
22+
expect(angular.element(element).html()).toBe('<div id=""></div>');
2323
});
2424

2525
});

test/wizard/detail-page.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
<div ng-controller="DetailsGeneralController">
22
<pf-wizard-substep step-title="General" next-enabled="detailsGeneralComplete" step-id="details-general" step-priority="0" on-show="onShow" review-template="{{reviewTemplate}}" show-review-details="true">
33
<form class="form-horizontal">
4-
<div pf-form-group pf-label="Name" required>
4+
<pf-form-group pf-label="Name" required>
55
<input id="new-name" name="name" ng-model="data.name" type="text" ng-change="updateName()" required/>
6-
</div>
7-
<div pf-form-group pf-label="Description">
6+
</pf-form-group>
7+
<pf-form-group pf-form-group pf-label="Description">
88
<input id="new-description" name="description" ng-model="data.description" type="text" />
9-
</div>
9+
</pf-form-group>
1010
</form>
1111
</pf-wizard-substep>
1212
</div>

test/wizard/wizard-test-steps.html

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,23 +3,23 @@
33
</div>
44
<pf-wizard-substep step-title="Details - Extra" next-enabled="true" step-id="details-extra" step-priority="1" show-review="true" show-review-details="true" review-template="test/wizard/review-second-template.html">
55
<form class="form-horizontal">
6-
<div pf-form-group pf-label="Lorem" required>
6+
<pf-form-group pf-label="Lorem" required>
77
<input id="new-lorem" name="lorem" ng-model="data.lorem" type="text" required/>
8-
</div>
9-
<div pf-form-group pf-label="Ipsum">
8+
</pf-form-group>
9+
<pf-form-group pf-label="Ipsum">
1010
<input id="new-ipsum" name="ipsum" ng-model="data.ipsum" type="text" />
11-
</div>
11+
</pf-form-group>
1212
</form>
1313
</pf-wizard-substep>
1414
</pf-wizard-step>
1515
<pf-wizard-step step-title="Second Step" substeps="false" step-id="configuration" step-priority="1" show-review="true" review-template="test/wizard/review-second-template.html" >
1616
<form class="form-horizontal">
17-
<div pf-form-group pf-label="Lorem">
17+
<pf-form-group pf-label="Lorem">
1818
<input id="new-lorem" name="lorem" ng-model="data.lorem" type="text"/>
19-
</div>
20-
<div pf-form-group pf-label="Ipsum">
19+
</pf-form-group>
20+
<pf-form-group pf-label="Ipsum">
2121
<input id="new-ipsum" name="ipsum" ng-model="data.ipsum" type="text" />
22-
</div>
22+
</pf-form-group>
2323
</form>
2424
</pf-wizard-step>
2525
<pf-wizard-step step-title="Review" substeps="true" step-id="review" step-priority="2">

0 commit comments

Comments
 (0)