forked from elastic/kibana
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[UI Framework][K7]: Side nav component (elastic#13304)
Adds a responsive side nav component to KUI.
- Loading branch information
Showing
34 changed files
with
524 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import React from 'react'; | ||
|
||
import { | ||
KuiSideNav, | ||
KuiSideNavItem, | ||
KuiSideNavTitle, | ||
} from '../../../../components'; | ||
|
||
export default () => ( | ||
<KuiSideNav> | ||
<KuiSideNavTitle>Elasticsearch</KuiSideNavTitle> | ||
<KuiSideNavItem>Data sources</KuiSideNavItem> | ||
<KuiSideNavItem>Users</KuiSideNavItem> | ||
<KuiSideNavItem>Roles</KuiSideNavItem> | ||
<KuiSideNavItem isSelected>Watches</KuiSideNavItem> | ||
<KuiSideNavItem>Extremely long item is long</KuiSideNavItem> | ||
|
||
<KuiSideNavTitle>Kibana</KuiSideNavTitle> | ||
<KuiSideNavItem>Index Patterns</KuiSideNavItem> | ||
<KuiSideNavItem>Saved Objects</KuiSideNavItem> | ||
<KuiSideNavItem>Reporting</KuiSideNavItem> | ||
|
||
<KuiSideNavTitle>Logstash</KuiSideNavTitle> | ||
<KuiSideNavItem>Pipeline Viewer</KuiSideNavItem> | ||
</KuiSideNav> | ||
); |
39 changes: 39 additions & 0 deletions
39
ui_framework/doc_site/src/views/side_nav/side_nav_example.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
import React from 'react'; | ||
|
||
import { renderToHtml } from '../../services'; | ||
|
||
import { | ||
GuideDemo, | ||
GuidePage, | ||
GuideSection, | ||
GuideSectionTypes, | ||
GuideText, | ||
} from '../../components'; | ||
|
||
import SideNav from './side_nav'; | ||
const sideNavSource = require('!!raw!./side_nav'); | ||
const sideNavHtml = renderToHtml(SideNav); | ||
|
||
export default props => ( | ||
<GuidePage title={props.route.name}> | ||
<GuideSection | ||
title="SideNav" | ||
source={[{ | ||
type: GuideSectionTypes.JS, | ||
code: sideNavSource, | ||
}, { | ||
type: GuideSectionTypes.HTML, | ||
code: sideNavHtml, | ||
}]} | ||
> | ||
<GuideText> | ||
The sidenav is a responsive menu system that usually sits on the left side of a page layout. | ||
It will exapand to the width of its container. | ||
</GuideText> | ||
|
||
<GuideDemo> | ||
<SideNav /> | ||
</GuideDemo> | ||
</GuideSection> | ||
</GuidePage> | ||
); |
Oops, something went wrong.