Skip to content

Commit

Permalink
Add NoResults and Panel components.
Browse files Browse the repository at this point in the history
Backports PR #9516

**Commit 1:**
Add NoResults and Panel components.

* Original sha: 7fe7f31
* Authored by CJ Cenizal <[email protected]> on 2016-12-15T23:44:37Z

**Commit 2:**
Lighten noResults text.

* Original sha: 022da42
* Authored by CJ Cenizal <[email protected]> on 2016-12-16T17:00:07Z
  • Loading branch information
elastic-jasper committed Dec 16, 2016
1 parent 87a7a35 commit 404ac63
Show file tree
Hide file tree
Showing 8 changed files with 95 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/ui_framework/components/form/_text_input.scss
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
}

&:focus {
@include focus;
outline: none;
border-color: $selectedBorderColor;
}
}
3 changes: 3 additions & 0 deletions src/ui_framework/components/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ $successColor: #417505;
$warningColor: #ffac15;
$errorColor: #D86051;
$fontColor: #191E23;
$subduedFontColor: #9fa3a7;
$panelColor: #E4E4E4;
$selectedBorderColor: #6EADC1;
$errorBorderColor: $errorColor;
Expand Down Expand Up @@ -68,5 +69,7 @@ body {
@import "icon/index";
@import "link/index";
@import "local_nav/index";
@import "no_results/index";
@import "panel/index";
@import "table/index";
@import "tool_bar/index";
1 change: 1 addition & 0 deletions src/ui_framework/components/no_results/_index.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@import "no_results";
6 changes: 6 additions & 0 deletions src/ui_framework/components/no_results/_no_results.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.kuiNoResults {
padding: 30px;
font-size: 18px;
color: $subduedFontColor;
line-height: $lineHeight;
}
1 change: 1 addition & 0 deletions src/ui_framework/components/panel/_index.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@import "panel";
9 changes: 9 additions & 0 deletions src/ui_framework/components/panel/_panel.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
.kuiPanel {
border: $tableBorder;
}

.kuiPanel--centered {
display: flex;
justify-content: center;
align-items: center;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
<div class="kuiControlledTable">
<!-- ToolBar -->
<div class="kuiToolBar">
<div class="kuiToolBarSearch">
<div class="kuiToolBarSearchBox">
<div class="kuiToolBarSearchBox__icon kuiIcon fa-search"></div>
<input
class="kuiToolBarSearchBox__input"
type="text"
placeholder="Search..."
>
</div>
</div>

<div class="kuiToolBarSection">
<button class="kuiButton kuiButton--primary">
Add
</button>

<button class="kuiButton kuiButton--basic kuiButton--icon">
<span class="kuiButton__icon kuiIcon fa-gear"></span>
</button>

<button class="kuiButton kuiButton--basic kuiButton--icon">
<span class="kuiButton__icon kuiIcon fa-bars"></span>
</button>
</div>

<div class="kuiToolBarSection">
<div class="kuiToolBarText">
1 &ndash; 20 of 33
</div>

<div class="kuiButtonGroup">
<button class="kuiButton kuiButton--basic kuiButton--icon">
<span class="kuiButton__icon kuiIcon fa-chevron-left"></span>
</button>
<button class="kuiButton kuiButton--basic kuiButton--icon">
<span class="kuiButton__icon kuiIcon fa-chevron-right"></span>
</button>
</div>
</div>
</div>

<!-- NoResults -->
<div class="kuiPanel kuiPanel--centered">
<div class="kuiNoResults">
No Items matched your search.
</div>
</div>

<!-- ToolBarFooter -->
<div class="kuiToolBarFooter">
<div class="kuiToolBarFooterSection">
<div class="kuiToolBarText">
1 &ndash; 20 of 33
</div>

<div class="kuiButtonGroup">
<button class="kuiButton kuiButton--basic kuiButton--icon">
<span class="kuiButton__icon kuiIcon fa-chevron-left"></span>
</button>
<button class="kuiButton kuiButton--basic kuiButton--icon">
<span class="kuiButton__icon kuiIcon fa-chevron-right"></span>
</button>
</div>
</div>
</div>

</div>
4 changes: 4 additions & 0 deletions src/ui_framework/doc_site/src/views/table/table_example.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,8 @@ export default createExample([{
title: 'ControlledTable',
html: require('./controlled_table.html'),
hasDarkTheme: false,
}, {
title: 'ControlledTable with NoResults',
html: require('./controlled_table_no_results.html'),
hasDarkTheme: false,
}]);

0 comments on commit 404ac63

Please sign in to comment.