ux: table design work

pull/9993/head
Torkel Ödegaard 8 years ago
parent 00df24b348
commit ac17684f50
  1. 1
      public/app/core/components/search/search.html
  2. 1
      public/app/core/routes/routes.ts
  3. 21
      public/app/features/templating/partials/editor.html
  4. 2
      public/sass/_variables.scss
  5. 38
      public/sass/components/_filter-table.scss
  6. 2
      public/sass/components/_navbar.scss
  7. 6
      public/sass/pages/_login.scss

@ -70,7 +70,6 @@
<span class="search-item__body"> <span class="search-item__body">
<div class="search-item__body-title">{{::item.title}}</div> <div class="search-item__body-title">{{::item.title}}</div>
<div class="search-item__body-sub-title" ng-show="item.folderTitle && section.hideHeader"> <div class="search-item__body-sub-title" ng-show="item.folderTitle && section.hideHeader">
<i class="fa fa-folder-o"></i>
{{::item.folderTitle}} {{::item.folderTitle}}
</div> </div>
</span> </span>

@ -174,6 +174,7 @@ function setupAngularRoutes($routeProvider, $locationProvider) {
.when('/login', { .when('/login', {
templateUrl: 'public/app/partials/login.html', templateUrl: 'public/app/partials/login.html',
controller : 'LoginCtrl', controller : 'LoginCtrl',
pageClass: 'page-login',
}) })
.when('/invite/:code', { .when('/invite/:code', {
templateUrl: 'public/app/partials/signup_invited.html', templateUrl: 'public/app/partials/signup_invited.html',

@ -37,14 +37,22 @@
<em>No template variables defined</em> <em>No template variables defined</em>
<br /> <br /> <br /> <br />
</div> </div>
<table class="grafana-options-table"> <table class="filter-table filter-table--hover">
<thead>
<tr>
<th>Variable</th>
<th>Definition</th>
<th colspan="5"></th>
</tr>
</thead>
<tbody>
<tr ng-repeat="variable in variables"> <tr ng-repeat="variable in variables">
<td style="width: 1%"> <td style="width: 1%">
<span class="template-variable"> <span ng-click="edit(variable)" class="pointer template-variable">
${{variable.name}} ${{variable.name}}
</span> </span>
</td> </td>
<td class="max-width" style="max-width: 200px;"> <td style="max-width: 200px;" ng-click="edit(variable)" class="pointer max-width">
{{variable.query}} {{variable.query}}
</td> </td>
@ -55,18 +63,13 @@
Duplicate Duplicate
</a> </a>
</td> </td>
<td style="width: 1%">
<a ng-click="edit(variable)" class="btn btn-inverse btn-mini">
<i class="fa fa-edit"></i>
Edit
</a>
</td>
<td style="width: 1%"> <td style="width: 1%">
<a ng-click="removeVariable(variable)" class="btn btn-danger btn-mini"> <a ng-click="removeVariable(variable)" class="btn btn-danger btn-mini">
<i class="fa fa-remove"></i> <i class="fa fa-remove"></i>
</a> </a>
</td> </td>
</tr> </tr>
</tbody>
</table> </table>
</div> </div>

@ -155,7 +155,7 @@ $link-hover-decoration: none !default;
// //
// Customizes the `.table` component with basic values, each used across all table variations. // Customizes the `.table` component with basic values, each used across all table variations.
$table-cell-padding: .75rem !default; $table-cell-padding: 4px 10px !default;
$table-sm-cell-padding: .3rem !default; $table-sm-cell-padding: .3rem !default;
// Forms // Forms

@ -13,22 +13,35 @@
.filter-table { .filter-table {
width: 100%; width: 100%;
border-collapse: collapse; border-collapse: separate;
tbody {
tr:nth-child(odd) {
background: $dark-2;
}
} }
.filter-table tr { thead {
background-color: $list-item-bg; tr {
border-bottom: 3px solid $page-bg; background: linear-gradient(0deg, #3c3f5a, #292f44);
}
} }
.filter-table th { th {
width: auto; width: auto;
padding: $table-cell-padding; padding: $table-cell-padding;
text-align: left; text-align: left;
line-height: 30px;
height: 30px;
white-space: nowrap;
} }
.filter-table td { td {
padding: $table-cell-padding; padding: $table-cell-padding;
line-height: 30px;
height: 30px;
border-bottom: 1px solid black;
white-space: nowrap;
&.filter-table__switch-cell { &.filter-table__switch-cell {
padding: 0; padding: 0;
@ -36,7 +49,7 @@
} }
} }
.filter-table .ellipsis { .ellipsis {
display: block; display: block;
width: 100%; width: 100%;
white-space: nowrap; white-space: nowrap;
@ -44,11 +57,11 @@
text-overflow: ellipsis; text-overflow: ellipsis;
} }
.filter-table .expanded { .expanded {
border-color: $panel-bg; border-color: $panel-bg;
} }
.filter-table .expanded > td { .expanded > td {
padding-bottom: 0; padding-bottom: 0;
} }
@ -57,3 +70,10 @@
height: 25px; height: 25px;
border-radius: 50%; border-radius: 50%;
} }
&--hover {
tbody tr:hover {
background: $dark-3;
}
}
}

@ -6,7 +6,7 @@
padding-left: $side-menu-width; padding-left: $side-menu-width;
box-shadow: $navbarShadow; box-shadow: $navbarShadow;
z-index: 1; z-index: 1;
background-color: $navbarBackground; background: $navbarBackground;
} }
.navbar-inner { .navbar-inner {

@ -8,6 +8,12 @@
padding-top: $spacer * 5; /* BAD HACK - experiement to see how it looks */ padding-top: $spacer * 5; /* BAD HACK - experiement to see how it looks */
} }
.page-login {
.sidemenu {
display: none;
}
}
.login-form { .login-form {
display: inline-block; display: inline-block;
max-width: 24rem; max-width: 24rem;

Loading…
Cancel
Save