Skip to content

Commit

Permalink
fix(grid): last nested Grid inherits row styles
Browse files Browse the repository at this point in the history
  • Loading branch information
PreslavKozovski authored and joneff committed Jun 2, 2020
1 parent a202bb9 commit f83fb58
Show file tree
Hide file tree
Showing 2 changed files with 112 additions and 1 deletion.
2 changes: 1 addition & 1 deletion packages/default/scss/grid/_layout.scss
Original file line number Diff line number Diff line change
Expand Up @@ -819,7 +819,7 @@
table {
table-layout: fixed;
}
tr:last-child td {
tr:last-child > td {
border-bottom-width: 0;
}
}
Expand Down
111 changes: 111 additions & 0 deletions tests/visual/grid-hierarchy.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,111 @@
<!doctype html>
<html lang="en" class="k-typography k-no-animations">
<head>
<title>Grid Hierarchy</title>
<meta charset="utf-8" />
<link rel="stylesheet" data-role="kendo-theme" href="../../packages/default/dist/all.css" />
<link rel="stylesheet" href="assets/styles.css" />
<script src="assets/scripts.js"></script>

<style>
#test-area {
grid-template-columns: 1fr;
}
</style>
</head>
<body>

<div id="test-area" class="grid">

<section>
<div class="k-widget k-grid k-grid-no-scrollbar" style="width: 600px; height: 400px;">
<div class="k-grid-header">
<div class="k-grid-header-wrap">
<table>
<colgroup>
<col class="k-hierarchy-col" /><col />
</colgroup>
<thead>
<tr>
<th class="k-header k-hierarchy-cell">
</th>
<th class="k-header">
<a class="k-link">Title<span></span></a>
</th>
</tr>
</thead>
</table>
</div>
</div>
<div class="k-grid-content">
<table class="k-grid-table">
<colgroup>
<col class="k-hierarchy-col" /><col />
</colgroup>
<tbody>
<tr class="k-master-row">
<td class="k-hierarchy-cell">
<a class="k-icon k-i-expand"></a>
</td>
<td>1</td>
</tr>
<tr class="k-alt k-master-row">
<td class="k-hierarchy-cell">
<a class="k-icon k-i-collapse"></a>
</td>
<td>2</td>
</tr>
<tr class="k-detail-row">
<td class="k-hierarchy-cell"></td>
<td class="k-detail-cell" colspan="1">
<!-- hierarchy child content -->
<div class="k-widget k-grid k-grid-no-scrollbar" style="height: 200px;">
<div class="k-grid-header">
<div class="k-grid-header-wrap">
<table>
<colgroup>
<col /><col />
</colgroup>
<thead>
<tr>
<th class="k-header">
<a class="k-link">Title<span></span></a>
</th>
<th class="k-header">
<a class="k-link">Title<span></span></a>
</th>
</tr>
</thead>
</table>
</div>
</div>
<div class="k-grid-content">
<table class="k-grid-table">
<colgroup>
<col /><col />
</colgroup>
<tbody>
<tr class="k-master-row">
<td>Text</td>
<td>Text</td>
</tr>
<tr class="k-alt k-master-row">
<td>Text</td>
<td>Text</td>
</tr>
</tbody>
</table>
</div>
</div>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</section>

</div>

</body>
</html>

0 comments on commit f83fb58

Please sign in to comment.