-
Notifications
You must be signed in to change notification settings - Fork 356
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update dashboard widget styling #728
Conversation
@miq-bot add_label bug, euwe/no, enhancement, formatting/styling |
@miq-bot assign @dclarizio |
Checked commit https://github.com/epwinchell/manageiq-ui-classic/commit/f02468a0948fd7ef910f77bf14d3f9cd4630d4d5 with ruby 2.2.6, rubocop 0.47.1, and haml-lint 0.20.0 app/views/dashboard/_widget_blank.html.haml
app/views/dashboard/_widget_chart.html.haml
app/views/dashboard/_widget_report.html.haml
app/views/dashboard/_widget_rss.html.haml
|
@miq-bot rm_label euwe/no |
@miq-bot add_label euwe/yes |
@epwinchell Please resolve conflict and create an Euwe-specific PR (referencing this one) or suggest other PRs to backport. $ git diff
diff --cc app/assets/stylesheets/patternfly_overrides.scss
index 3ce7ccc,de96da5..0000000
--- a/app/assets/stylesheets/patternfly_overrides.scss
+++ b/app/assets/stylesheets/patternfly_overrides.scss
@@@ -101,8 -101,12 +101,17 @@@ li.brand-white-label.whitelabeled
/* Dashboard overrides */
++<<<<<<< HEAD
+body#dashboard .container-cards-pf {
+ margin-top: 0;
++=======
+ body#dashboard .blank-slate-pf {
+ padding: 0 !important;
+ }
+
+ .blank-slate-pf .pficon-warning-triangle-o:before {
+ color: #9c9c9c;
++>>>>>>> 384a802... Merge pull request #728 from epwinchell/dashboard_update
}
body#dashboard table {
diff --cc app/views/dashboard/_widget_chart.html.haml
index 3e17a29,e394f91..0000000
--- a/app/views/dashboard/_widget_chart.html.haml
+++ b/app/views/dashboard/_widget_chart.html.haml
@@@ -1,26 -1,28 +1,45 @@@
-#
Parameters:
widget -- MiqWidget instance
++<<<<<<< HEAD
+- width ||= 350
+- height ||= 250
+.card-pf-body.chart_widget
+ .mc{:id => "dd_w#{widget.id}_box",
+ :style => @sb[:dashboards][@sb[:active_db]][:minimized].include?(widget.id) ? 'display:none' : ''}
++=======
+ .mc{:id => "dd_w#{widget.id}_box",
+ :style => @sb[:dashboards][@sb[:active_db]][:minimized].include?(widget.id) ? 'display:none' : ''}
++>>>>>>> 384a802... Merge pull request #728 from epwinchell/dashboard_update
- - if widget.contents_for_user(current_user).contents.blank?
- = _('No chart data found')
- \. . .
- - datum = widget.contents_for_user(current_user).contents
- - if Charting.data_ok?(datum)
- -# we need to count all charts to be able to display multiple
- -# charts on a dashboard screen
- - WidgetPresenter.chart_data.push(:xml => datum)
- - chart_index = WidgetPresenter.chart_data.length - 1
- - chart_data = Charting.deserialized(datum)
+ - if widget.contents_for_user(current_user).contents.blank?
+ .blank-slate-pf{:style => "padding: 10px"}
+ .blank-slate-pf-icon
+ %i.fa.fa-cog
+ %h1= _('No chart data found.')
++<<<<<<< HEAD
+ = chart_local(chart_data,
+ :id => "miq_widgetchart_#{chart_index}".html_safe,
+ :width => width,
+ :height => height)
+ - else
+ = _('Invalid chart data. Try regenerating the widgets.')
++=======
+ - datum = widget.contents_for_user(current_user).contents
+ - if Charting.data_ok?(datum)
+ -# we need to count all charts to be able to display multiple
+ -# charts on a dashboard screen
+ - WidgetPresenter.chart_data.push(:xml => datum)
+ - chart_index = WidgetPresenter.chart_data.length - 1
+ - chart_data = Charting.deserialized(datum)
+
+ = chart_local(chart_data,
+ :id => "miq_widgetchart_#{chart_index}".html_safe)
+ - else
+ .blank-slate-pf{:style => "padding: 10px"}
+ .blank-slate-pf-icon
+ %i.pficon.pficon-warning-triangle-o
+ %h1= _('Invalid chart data.')
+ %p= _('Invalid chart data. Try regenerating the widgets.')
++>>>>>>> 384a802... Merge pull request #728 from epwinchell/dashboard_update |
Backported to Euwe via ManageIQ/manageiq#14417 |
Backported to Darga via ManageIQ/manageiq#14789 |
This PR updates the styling of the main dashboard widgets with the latest Patternfly Card markup, fixing a bug where the drop-downs in the right column widgets appear off the screen. It also adds PF "empty state" styling for the various widget types when no data is present.
https://bugzilla.redhat.com/show_bug.cgi?id=1426752
Old
New