Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
69305c20
Commit
69305c20
authored
Dec 15, 2017
by
Torkel Ödegaard
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop' of github.com:grafana/grafana into develop
parents
25d8f21b
a84e03dd
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
112 additions
and
76 deletions
+112
-76
public/app/core/components/manage_dashboards/manage_dashboards.html
+94
-76
public/app/core/components/manage_dashboards/manage_dashboards.ts
+6
-0
public/sass/components/_dashboard_list.scss
+4
-0
public/sass/components/_gf-form.scss
+4
-0
public/sass/layout/_page.scss
+4
-0
No files found.
public/app/core/components/manage_dashboards/manage_dashboards.html
View file @
69305c20
<div
class=
"page-action-bar"
ng-hide=
"!ctrl.hasFilters && ctrl.sections.length === 0"
>
<div
class=
"dashboard-list"
>
<label
class=
"gf-form gf-form--grow gf-form--has-input-icon"
>
<div
class=
"page-action-bar page-action-bar--narrow"
ng-hide=
"!ctrl.hasFilters && ctrl.sections.length === 0"
>
<input
type=
"text"
class=
"gf-form-input max-width-30"
placeholder=
"Find Dashboard by name"
tabindex=
"1"
give-focus=
"true"
ng-model=
"ctrl.query.query"
ng-model-options=
"{ debounce: 500 }"
spellcheck=
'false'
ng-change=
"ctrl.onQueryChange()"
/>
<label
class=
"gf-form gf-form--grow gf-form--has-input-icon"
>
<i
class=
"gf-form-input-icon fa fa-search"
></i>
<input
type=
"text"
class=
"gf-form-input max-width-30"
placeholder=
"Find Dashboard by name"
tabindex=
"1"
give-focus=
"true"
ng-model=
"ctrl.query.query"
ng-model-options=
"{ debounce: 500 }"
spellcheck=
'false'
ng-change=
"ctrl.onQueryChange()"
/>
</label>
<i
class=
"gf-form-input-icon fa fa-search"
></i>
<div
class=
"page-action-bar__spacer"
></div>
</label>
<a
class=
"btn btn-success"
href=
"/dashboard/new?folderId={{ctrl.folderId}}"
>
<div
class=
"page-action-bar__spacer"
></div>
<i
class=
"fa fa-plus"
></i>
<a
class=
"btn btn-success"
href=
"/dashboard/new?folderId={{ctrl.folderId}}"
>
Dashboard
<i
class=
"fa fa-plus"
></i>
</a>
Dashboard
<a
class=
"btn btn-success"
href=
"/dashboards/folder/new"
ng-if=
"!ctrl.folderId"
>
</a>
<i
class=
"fa fa-plus"
></i>
<a
class=
"btn btn-success"
href=
"/dashboards/folder/new"
ng-if=
"!ctrl.folderId"
>
Folder
<i
class=
"fa fa-plus"
></i>
</a>
Folder
</div>
</a>
</div>
<div
class=
"gf-form"
ng-if=
"ctrl.query.tag.length"
>
<div
class=
"page-action-bar page-action-bar--narrow"
ng-show=
"ctrl.hasFilters"
>
Filters:
<div
class=
"gf-form-inline"
>
<span
ng-repeat=
"tagName in ctrl.query.tag"
>
<div
class=
"gf-form"
ng-show=
"ctrl.query.tag.length > 0"
>
<a
ng-click=
"ctrl.removeTag(tagName, $event)"
tag-color-from-name=
"tagName"
class=
"label label-tag"
>
<label
class=
"gf-form-label width-4"
>
<i
class=
"fa fa-remove"
></i>
Tags
{{tagName}}
</label>
</a>
<div
class=
"gf-form-input gf-form-input--plaintext"
ng-show=
"ctrl.query.tag.length > 0"
>
</span>
<span
ng-repeat=
"tagName in ctrl.query.tag"
>
</div>
<a
ng-click=
"ctrl.removeTag(tagName, $event)"
tag-color-from-name=
"tagName"
class=
"tag label label-tag"
>
<i
class=
"fa fa-remove"
></i>
{{tagName}}
</a>
</span>
</div>
</div>
<div
class=
"gf-form"
ng-show=
"ctrl.query.starred"
>
<label
class=
"gf-form-label"
>
<a
class=
"pointer"
ng-click=
"ctrl.removeStarred()"
>
<i
class=
"fa fa-fw fa-check"
></i>
Starred
</a>
</label>
</div>
<div
class=
"gf-form"
>
<label
class=
"gf-form-label"
>
<a
class=
"pointer"
ng-click=
"ctrl.clearFilters()"
bs-tooltip=
"'Clear current search query and filters'"
>
<i
class=
"fa fa-remove"
></i>
Clear
</a>
</label>
</div>
</div>
</div>
<div
class=
"gf-form"
>
<div
class=
"search-results"
ng-show=
"ctrl.hasFilters && ctrl.sections.length === 0"
>
<div
class=
"gf-form-button-row"
ng-show=
"ctrl.hasFilters"
>
<em
class=
"muted"
>
<button
No dashboards matching your query were found.
type=
"button"
</em>
class=
"btn gf-form-button btn-inverse btn-small"
ng-click=
"ctrl.clearFilters()"
>
<i
class=
"fa fa-close"
></i>
Clear current search query and filters
</button>
</div>
</div>
</div>
<div
class=
"dashboard-list"
ng-show=
"ctrl.sections.length > 0"
>
<div
class=
"search-results"
ng-show=
"ctrl.sections.length > 0"
>
<div
class=
"search-results-filter-row"
>
<div
class=
"search-results-filter-row"
>
<gf-form-switch
<gf-form-switch
on-change=
"ctrl.onSelectAllChanged()"
on-change=
"ctrl.onSelectAllChanged()"
checked=
"ctrl.selectAllChecked"
checked=
"ctrl.selectAllChecked"
switch-class=
"gf-form-switch--transparent gf-form-switch--search-result-filter-row__checkbox"
switch-class=
"gf-form-switch--transparent gf-form-switch--search-result-filter-row__checkbox"
/>
<div
class=
"search-results-filter-row__filters"
>
<select
class=
"search-results-filter-row__filters-item gf-form-input"
ng-model=
"ctrl.selectedStarredFilter"
ng-options=
"t.text disable when t.disabled for t in ctrl.starredFilterOptions"
ng-change=
"ctrl.onStarredFilterChange()"
ng-show=
"!(ctrl.canMove || ctrl.canDelete)"
/>
/>
<select
<div
class=
"search-results-filter-row__filters"
>
class=
"search-results-filter-row__filters-item gf-form-input"
<select
ng-model=
"ctrl.selectedTagFilter"
class=
"search-results-filter-row__filters-item gf-form-input"
ng-options=
"t.term disable when t.disabled for t in ctrl.tagFilterOptions"
ng-model=
"ctrl.selectedStarredFilter"
ng-change=
"ctrl.onTagFilterChange()"
ng-options=
"t.text disable when t.disabled for t in ctrl.starredFilterOptions"
ng-show=
"!(ctrl.canMove || ctrl.canDelete)"
ng-change=
"ctrl.onStarredFilterChange()"
/>
ng-show=
"!(ctrl.canMove || ctrl.canDelete)"
<div
class=
"gf-form-button-row"
ng-show=
"ctrl.canMove || ctrl.canDelete"
>
/>
<button
type=
"button"
<select
class=
"btn gf-form-button btn-inverse"
class=
"search-results-filter-row__filters-item gf-form-input"
ng-disabled=
"!ctrl.canMove"
ng-model=
"ctrl.selectedTagFilter"
ng-click=
"ctrl.moveTo()"
ng-options=
"t.term disable when t.disabled for t in ctrl.tagFilterOptions"
bs-tooltip=
"ctrl.canMove ? '' : 'Select a dashboard to move (cannot move folders)'"
ng-change=
"ctrl.onTagFilterChange()"
data-placement=
"bottom"
>
ng-show=
"!(ctrl.canMove || ctrl.canDelete)"
<i
class=
"fa fa-exchange"
></i>
Move
/>
</button>
<div
class=
"gf-form-button-row"
ng-show=
"ctrl.canMove || ctrl.canDelete"
>
<button
type=
"button"
<button
type=
"button"
class=
"btn gf-form-button btn-danger"
class=
"btn gf-form-button btn-inverse"
ng-click=
"ctrl.delete()"
ng-disabled=
"!ctrl.canMove"
ng-disabled=
"!ctrl.canDelete"
>
ng-click=
"ctrl.moveTo()"
<i
class=
"fa fa-trash"
></i>
Delete
bs-tooltip=
"ctrl.canMove ? '' : 'Select a dashboard to move (cannot move folders)'"
</button>
data-placement=
"bottom"
>
<i
class=
"fa fa-exchange"
></i>
Move
</button>
<button
type=
"button"
class=
"btn gf-form-button btn-danger"
ng-click=
"ctrl.delete()"
ng-disabled=
"!ctrl.canDelete"
>
<i
class=
"fa fa-trash"
></i>
Delete
</button>
</div>
</div>
</div>
</div>
</div>
</div
>
<div
class=
"search-results-container"
>
<div
class=
"search-results-container"
>
<dashboard-search-results
<dashboard-search-results
results=
"ctrl.sections"
results=
"ctrl.sections
"
editable=
"true
"
editable=
"true
"
on-selection-changed=
"ctrl.selectionChanged()
"
on-selection-changed=
"ctrl.selectionChanged()"
on-tag-selected=
"ctrl.filterByTag($tag)"
/>
on-tag-selected=
"ctrl.filterByTag($tag)"
/
>
</div
>
</div>
</div>
</div>
</div>
...
...
public/app/core/components/manage_dashboards/manage_dashboards.ts
View file @
69305c20
...
@@ -231,8 +231,14 @@ export class ManageDashboardsCtrl {
...
@@ -231,8 +231,14 @@ export class ManageDashboardsCtrl {
}
}
}
}
removeStarred
()
{
this
.
query
.
starred
=
false
;
return
this
.
getDashboards
();
}
onStarredFilterChange
()
{
onStarredFilterChange
()
{
this
.
query
.
starred
=
this
.
selectedStarredFilter
.
text
===
'Yes'
;
this
.
query
.
starred
=
this
.
selectedStarredFilter
.
text
===
'Yes'
;
this
.
selectedStarredFilter
=
this
.
starredFilterOptions
[
0
];
return
this
.
getDashboards
();
return
this
.
getDashboards
();
}
}
...
...
public/sass/components/_dashboard_list.scss
View file @
69305c20
...
@@ -4,6 +4,10 @@
...
@@ -4,6 +4,10 @@
}
}
}
}
.search-results
{
margin-top
:
2rem
;
}
.search-results-filter-row
{
.search-results-filter-row
{
height
:
35px
;
height
:
35px
;
display
:
flex
;
display
:
flex
;
...
...
public/sass/components/_gf-form.scss
View file @
69305c20
...
@@ -221,6 +221,10 @@ $input-border: 1px solid $input-border-color;
...
@@ -221,6 +221,10 @@ $input-border: 1px solid $input-border-color;
padding-bottom
:
4px
;
padding-bottom
:
4px
;
font-size
:
$font-size-sm
;
font-size
:
$font-size-sm
;
}
}
&
--plaintext
{
white-space
:
unset
;
}
}
}
.gf-form-hint
{
.gf-form-hint
{
...
...
public/sass/layout/_page.scss
View file @
69305c20
...
@@ -55,6 +55,10 @@
...
@@ -55,6 +55,10 @@
}
}
}
}
.page-action-bar--narrow
{
margin-bottom
:
0
;
}
.page-action-bar__spacer
{
.page-action-bar__spacer
{
width
:
$spacer
*
2
;
width
:
$spacer
*
2
;
flex-grow
:
1
;
flex-grow
:
1
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment