{"action":"created","issue":{"url":"https://api.github.com/repos/Teradata/covalent/issues/701","repository_url":"https://api.github.com/repos/Teradata/covalent","labels_url":"https://api.github.com/repos/Teradata/covalent/issues/701/labels{/name}","comments_url":"https://api.github.com/repos/Teradata/covalent/issues/701/comments","events_url":"https://api.github.com/repos/Teradata/covalent/issues/701/events","html_url":"https://github.com/Teradata/covalent/issues/701","id":236867554,"number":701,"title":"Providing custom width to td-data-table columns","user":{"login":"Saif03","id":15065985,"avatar_url":"https://avatars2.githubusercontent.com/u/15065985?v=3","gravatar_id":"","url":"https://api.github.com/users/Saif03","html_url":"https://github.com/Saif03","followers_url":"https://api.github.com/users/Saif03/followers","following_url":"https://api.github.com/users/Saif03/following{/other_user}","gists_url":"https://api.github.com/users/Saif03/gists{/gist_id}","starred_url":"https://api.github.com/users/Saif03/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Saif03/subscriptions","organizations_url":"https://api.github.com/users/Saif03/orgs","repos_url":"https://api.github.com/users/Saif03/repos","events_url":"https://api.github.com/users/Saif03/events{/privacy}","received_events_url":"https://api.github.com/users/Saif03/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-06-19T11:58:15Z","updated_at":"2017-06-19T17:23:44Z","closed_at":null,"body":"I am new to covalent, I was going through docs and tried replicating one of the data table examples.\r\n\r\n![image](https://user-images.githubusercontent.com/15065985/27283675-c8d04160-550e-11e7-8ed5-819284a80983.png)\r\nIn the above example I want that the fields with more content in it should make its column with to increase either dynamically or any custom tweak to make that happen. Currently I am trying to do:\r\n\r\n```\r\n<td-data-table #dataTable [data]=\"filteredData\" [columns]=\"columns\" [(ngModel)]=\"selectedRows\" (sortChange)=\"sort($event)\">\r\n    <ng-template tdDataTableTemplate=\"action\" let-value=\"value\" let-row=\"row\" let-column=\"column\">\r\n        <button md-icon-button id=\"icon-btn\"><md-icon>mode_edit</md-icon></button>\r\n    </ng-template>\r\n</td-data-table>\r\n```\r\n\r\nI also tried customizing via the following method:\r\n\r\n```\r\n<table td-data-table>\r\n    <th td-data-table-column *ngFor=\"let column of columns\" [numeric]=\"column.numeric\">\r\n        {{column.label}}\r\n    </th>\r\n    <tr td-data-table-row *ngFor=\"let row of data\">\r\n        <td td-data-table-cell *ngFor=\"let column of columns\" [numeric]=\"column.numeric\">\r\n            {{column.format ? column.format(row[column.name]) : row[column.name]}}\r\n        </td>\r\n    </tr>\r\n</table>\r\n```\r\n\r\nbut this piece of code generates the following error on  line *ngFor=\"let row of data\"\r\n\r\n![image](https://user-images.githubusercontent.com/15065985/27283846-ad60ad06-550f-11e7-9493-420ad003d232.png)\r\n"},"comment":{"url":"https://api.github.com/repos/Teradata/covalent/issues/comments/309508623","html_url":"https://github.com/Teradata/covalent/issues/701#issuecomment-309508623","issue_url":"https://api.github.com/repos/Teradata/covalent/issues/701","id":309508623,"user":{"login":"emoralesb05","id":5846742,"avatar_url":"https://avatars1.githubusercontent.com/u/5846742?v=3","gravatar_id":"","url":"https://api.github.com/users/emoralesb05","html_url":"https://github.com/emoralesb05","followers_url":"https://api.github.com/users/emoralesb05/followers","following_url":"https://api.github.com/users/emoralesb05/following{/other_user}","gists_url":"https://api.github.com/users/emoralesb05/gists{/gist_id}","starred_url":"https://api.github.com/users/emoralesb05/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emoralesb05/subscriptions","organizations_url":"https://api.github.com/users/emoralesb05/orgs","repos_url":"https://api.github.com/users/emoralesb05/repos","events_url":"https://api.github.com/users/emoralesb05/events{/privacy}","received_events_url":"https://api.github.com/users/emoralesb05/received_events","type":"User","site_admin":false},"created_at":"2017-06-19T17:23:44Z","updated_at":"2017-06-19T17:23:44Z","body":"That `.hasData` error is a markup error on your side when copying the demo code.\r\n\r\nThat being said, you can add widths as wanted with the atomic components, but the feature to customize them in the `td-data-table` is coming soon. Probably for next release."}}
{"actor":{"display_login":"emoralesb05"}}