Skip to content

Commit 3c6c154

Browse files
committed
Fixed a couple of issues with the directives.
1 parent e36a462 commit 3c6c154

File tree

13 files changed

+47121
-38
lines changed

13 files changed

+47121
-38
lines changed

gulpfile.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,6 @@ pages.forEach(function(page) {
153153
],
154154
js: [
155155
replace(/\.version = \"0\";/, ".version = \"" + pkg.version + "\""),
156-
uglify(),
157156
header(banner)
158157
],
159158
html: [

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
<!doctype html><html ng-app=angular-contentful-starter><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width, initial-scale=1.0"><title>angular-contentful-starter</title><link rel=stylesheet href=public/index.min.css><link href="https://fonts.googleapis.com/css?family=Catamaran:100,200,300,400,500,600,700,800,900" rel=stylesheet><link href="https://fonts.googleapis.com/css?family=Lato:100,100i,300,300i,400,400i,700,700i,900,900i" rel=stylesheet></head><body><navigation></navigation><carousel></carousel><div ui-view></div><footer></footer><script async defer src="https://maps.googleapis.com/maps/api/js?key=AIzaSyAYUxfnjxus1rXx-ntGcxqWD1BPRZrI1IM" type=text/javascript></script><script src=public/index.min.js></script></body></html>
1+
<!doctype html><html ng-app=angular-contentful-starter><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width, initial-scale=1.0"><title>angular-contentful-starter</title><link rel=stylesheet href=public/index.min.css><link href="https://fonts.googleapis.com/css?family=Catamaran:100,200,300,400,500,600,700,800,900" rel=stylesheet><link href="https://fonts.googleapis.com/css?family=Lato:100,100i,300,300i,400,400i,700,700i,900,900i" rel=stylesheet></head><body><navigation></navigation><carousel></carousel><div ui-view></div><footer-section></footer-section><script async defer src="https://maps.googleapis.com/maps/api/js?key=AIzaSyAYUxfnjxus1rXx-ntGcxqWD1BPRZrI1IM" type=text/javascript></script><script src=public/index.min.js></script></body></html>

index.src.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@
2121
<body>
2222
<!-- Main Navigation (views/navigation.html) -->
2323
<navigation></navigation>
24-
24+
2525
<!-- Carousel (views/carousel.html) -->
26-
<carousel></carousel>
26+
<carousel></carousel>
2727

2828
<!-- Render the Angular views. -->
2929
<div ui-view></div>

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "angular-contentful-starter",
3-
"version": "0.2.0",
3+
"version": "1.0.0",
44
"description": "AngularJS Contentful Starter Kit",
55
"devDependencies": {
66
"dateformat": "^1.0.11",

public/index.min.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/index.min.js

Lines changed: 47101 additions & 18 deletions
Large diffs are not rendered by default.

src/config/route.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ app.config(["$stateProvider", "$urlRouterProvider", function ($stateProvider, $u
4141
contentful
4242
.entries('content_type=productLine&fields.urlSlug=' + $stateParams.productLine).then(
4343
function (response) {
44-
console.log(response);
4544
if (response.data && response.data.items && response.data.items.length > 0) {
4645
$scope.productLine = response.data.items[0].fields; } } );
4746
}

src/directives/carousel.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,16 @@
66
*
77
*/
88
app.directive("carousel", function() {
9-
return {
10-
restrict: 'E',
9+
return {
10+
restrict: 'E',
11+
replace: true,
1112
templateUrl: "src/views/carousel.html",
1213
controller: function($scope, contentful) {
1314
contentful
1415
// Query Contentful for 'banner' objects.
1516
.entries('content_type=banner').then(
1617
function (response) {
18+
console.log(response.data.items[0]);
1719
if (response.data && response.data.items && response.data.items.length > 0) {
1820
$scope.banners = response.data.items;
1921
}

src/directives/featured-products.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
app.directive("featuredProducts", function() {
99
return {
1010
restrict: 'E',
11+
replace: true,
1112
scope: {
1213
products: '='
1314
},

src/directives/footer.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
app.directive("footerSection", function() {
99
return {
1010
restrict: 'E',
11+
replace: true,
1112
templateUrl: "src/views/footer.html"
1213
}
1314
});

0 commit comments

Comments
 (0)