title: AngularJS only shows last Element in ng-repeat
body: <p>I've got a strange behaviour using flexslider to render a bunch of galleries. As shown below I've got an array of several objects that conclude an array of images. When I "render" the galleries, all galleries appear but only the last one shows its images. On all galleries the indicator for the number of images in that particular, as well as the title and link, are correct, but the images are missing.</p>
  
  <p>Do I do something(/a lot) wrong here?
  Here is my code:</p>
  
  <pre><code>$scope.galleries = [{title: 'gallery1', 'link': 'http://...', elements: 
                          ['img/img1.jpg','img/img2.jpg']},
                      {title: 'gallery2', 'link': 'http://...', elements: 
                          ['img/img3.jpg','img/img4.jpg']}];
  </code></pre>
  
  <p>I want to show each gallery with a directive and ng-repeat. The directive should show the title and render the gallery with flexslider(<a href="https://github.com/thenikso/angular-flexslider" rel="nofollow">https://github.com/thenikso/angular-flexslider</a>). Directive:</p>
  
  <pre><code>.directive('gallery', function() {
        return {
            restrict: 'A',
            templateUrl: 'views/gallery.html',
            scope: {
                gallery: '='
            },
            link: function(scope, element, attrs) {
                // first generate html, the
  
                // set content here
                scope.link = scope.gallery.link;
                scope.title = scope.gallery.title;
                scope.elements = angular.copy(scope.gallery.elements);
                scope.num = scope.gallery.elements.length;
  
            }
        };
    }
  </code></pre>
  
  <p>Here the template:</p>
  
  <pre><code>&lt;a ng-href="{{link}}" target="_blank" ng-bind="title"&gt;&lt;/a&gt;
  &lt;div class="gallery"&gt;
    &lt;div class="flexslider"&gt;
      &lt;div class="slides-control"&gt;
      &lt;a href="" ng-click="prevSlideshow()" class="prev"&gt;
      &lt;
        &lt;/a&gt;
        &lt;span class="current_pos"&gt;1&lt;/span&gt;
        /
        &lt;span ng-bind="num" class="total"&gt;&lt;/span&gt;
          &lt;a href="" ng-click="nextSlideshow()" class="next"&gt;
          &gt;
        &lt;/a&gt;
      &lt;/div&gt;
  
          &lt;ul ng-click="nextSlideshow()" class="slides" slideshow="false" control-nav="false" direction-nav="false" flex-slider slide="element in elements"&gt;
              &lt;li&gt;&lt;img ng-src="{{element}}" alt=""&gt;&lt;/li&gt;
          &lt;/ul&gt;
    &lt;/div&gt;
    &lt;a ng-href="{{link}}" target="_blank"&gt;&lt;h4&gt;more&lt;/h4&gt;&lt;/a&gt;
  &lt;h5&gt;---------------------------------------&lt;/h5&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>And finally how i call it:</p>
  
  <pre><code>&lt;ul class="publications" &gt;
      &lt;li ng-repeat="gallery in galleries"&gt;
          &lt;div gallery="gallery"&gt;&lt;/div&gt;
      &lt;/li&gt;
  &lt;/ul&gt;
  </code></pre>