daniel-nagy / fixed-table-header

Fixed table header directive.
MIT License
88 stars 36 forks source link

disappears when used with ng-repeat #30

Open garretwilson opened 7 years ago

garretwilson commented 7 years ago

With Angular 1.6.4 and agular-material 1.1.3 I have a table something like this:

<md-content flex layout="column">
    <md-table-container>
        <table md-table>
            <thead md-head fix-head>
                <tr md-row>
                    <th md-column>Apple</th>
                    <th md-column>Banana</th>
                    <th md-column>Cat</th>
                    <th md-column>Dog</th>
                </tr>
            </thead>
            <tbody md-body>
                <tr md-row>
                    <td md-cell>{{foo.foo}}</td>
                    <td md-cell>{{foo.bar}}</td>
                    <td md-cell>{{foo.example}}</td>
                    <td md-cell>{{foo.test}}</td>
                </tr>
            </tbody>
        </table>
    </md-table-container>
</md-content>

I can fill it with fake data and it works, but when I change the row to <tr md-row ng-repeat="foo in $ctrl.getFoos()">, when the entities are loaded the "fixed" header completely disappears.

mitrpathak commented 7 years ago

I have the same issue. Is there any fix found for this so far?