2019-02-18 11:03:52 +01:00
|
|
|
/***
|
|
|
|
|
* !!! THIS FILE WAS GENERATED AUTOMATICALLY !!!
|
|
|
|
|
*
|
2019-02-18 11:05:02 +01:00
|
|
|
* Do not modify this file!
|
2019-02-18 11:03:52 +01:00
|
|
|
* - Edit grafana-ui/src/themes/light.ts to regenerate
|
|
|
|
|
* - Edit grafana-ui/src/themes/_variable.light.scss.tmpl.ts to update template
|
|
|
|
|
*
|
|
|
|
|
* !!! THIS FILE WAS GENERATED AUTOMATICALLY !!!
|
|
|
|
|
*/
|
|
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
// Global values
|
|
|
|
|
// --------------------------------------------------
|
|
|
|
|
|
2017-10-18 07:49:52 +02:00
|
|
|
$theme-name: light;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2019-02-19 13:57:56 +01:00
|
|
|
// New Colors
|
|
|
|
|
// -------------------------
|
2019-02-20 16:11:36 +01:00
|
|
|
$blue-faint: #f5f9ff;
|
|
|
|
|
$blue-light: #5794f2;
|
|
|
|
|
$blue-base: #3274d9;
|
|
|
|
|
$blue-shade: #1f60c4;
|
|
|
|
|
$red-base: #e02f44;
|
|
|
|
|
$red-shade: #c4162a;
|
2019-02-19 13:57:56 +01:00
|
|
|
$green-base: #3eb15b;
|
|
|
|
|
$green-shade: #369b4f;
|
2019-09-26 09:32:32 +02:00
|
|
|
$orange-dark: #ed5700;
|
2019-02-19 13:57:56 +01:00
|
|
|
|
2020-03-24 10:30:53 +01:00
|
|
|
$gray98: #f7f8fa;
|
|
|
|
|
$gray95: #e9edf2;
|
|
|
|
|
$gray85: #c7d0d9;
|
|
|
|
|
$gray70: #9fa7b3;
|
|
|
|
|
$gray60: #7b8087;
|
|
|
|
|
$gray33: #464c54;
|
|
|
|
|
$gray25: #343b40;
|
|
|
|
|
$gray15: #202226;
|
|
|
|
|
$gray10: #141619;
|
|
|
|
|
$gray05: #0b0c0e;
|
|
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
// Grays
|
|
|
|
|
// -------------------------
|
2019-02-20 16:11:36 +01:00
|
|
|
$black: #000000;
|
|
|
|
|
|
|
|
|
|
$dark-1: #1e2028;
|
|
|
|
|
$dark-2: #41444b;
|
2019-06-24 14:39:59 +02:00
|
|
|
$dark-4: #35373f;
|
|
|
|
|
$dark-10: #424345;
|
2019-02-19 13:57:56 +01:00
|
|
|
$gray-1: #52545c;
|
|
|
|
|
$gray-2: #767980;
|
|
|
|
|
$gray-3: #acb6bf;
|
|
|
|
|
$gray-4: #c7d0d9;
|
|
|
|
|
$gray-5: #dde4ed;
|
|
|
|
|
$gray-6: #e9edf2;
|
|
|
|
|
$gray-7: #f7f8fa;
|
|
|
|
|
|
2019-02-12 21:54:20 +01:00
|
|
|
$white: #ffffff;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
|
|
|
|
// Accent colors
|
|
|
|
|
// -------------------------
|
2018-07-20 16:02:41 +02:00
|
|
|
$blue: #0083b3;
|
2019-02-20 16:11:36 +01:00
|
|
|
$red: $red-base;
|
2017-12-19 16:22:41 +01:00
|
|
|
$yellow: #ff851b;
|
|
|
|
|
$orange: #ff7941;
|
|
|
|
|
$purple: #9954bb;
|
2019-02-20 16:11:36 +01:00
|
|
|
$variable: #0083b3;
|
2017-12-19 16:22:41 +01:00
|
|
|
|
2019-02-21 15:05:17 +01:00
|
|
|
$brand-primary: #ff7941;
|
|
|
|
|
$brand-success: #3eb15b;
|
|
|
|
|
$brand-warning: #ff7941;
|
|
|
|
|
$brand-danger: #e02f44;
|
2017-12-19 16:22:41 +01:00
|
|
|
|
2019-02-21 15:05:17 +01:00
|
|
|
$query-red: #e02f44;
|
|
|
|
|
$query-green: #3eb15b;
|
|
|
|
|
$query-purple: #9954bb;
|
|
|
|
|
$query-orange: #ff7941;
|
|
|
|
|
$query-keyword: #3274d9;
|
2017-12-15 11:01:18 +01:00
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
// Status colors
|
|
|
|
|
// -------------------------
|
2019-02-21 15:05:17 +01:00
|
|
|
$online: #369b4f;
|
2017-12-19 16:22:41 +01:00
|
|
|
$warn: #f79520;
|
2019-02-21 15:05:17 +01:00
|
|
|
$critical: #c4162a;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2016-02-15 16:02:58 +01:00
|
|
|
// Scaffolding
|
|
|
|
|
// -------------------------
|
2019-02-21 12:32:29 +01:00
|
|
|
$body-bg: #f7f8fa;
|
2020-03-24 10:30:53 +01:00
|
|
|
$page-bg: #ffffff;
|
2019-02-06 15:45:40 +01:00
|
|
|
|
2019-02-21 15:05:17 +01:00
|
|
|
$body-color: #52545c;
|
|
|
|
|
$text-color: #52545c;
|
|
|
|
|
$text-color-strong: #41444b;
|
|
|
|
|
$text-color-weak: #767980;
|
|
|
|
|
$text-color-faint: #35373f;
|
2019-04-07 19:01:59 +02:00
|
|
|
$text-color-emphasis: #41444b;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2016-03-28 13:10:42 +02:00
|
|
|
$text-shadow-faint: none;
|
|
|
|
|
|
2016-02-24 10:32:22 +01:00
|
|
|
// gradients
|
2019-09-04 11:28:35 +02:00
|
|
|
$brand-gradient-horizontal: linear-gradient(to right, #f05a28 30%, #fbca0a 99%);
|
|
|
|
|
$brand-gradient-vertical: linear-gradient(#f05a28 30%, #fbca0a 99%);
|
2016-02-24 10:32:22 +01:00
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
// Links
|
|
|
|
|
// -------------------------
|
2019-02-21 15:05:17 +01:00
|
|
|
$link-color: #52545c;
|
2019-04-08 10:52:00 +02:00
|
|
|
$link-color-disabled: #acb6bf;
|
|
|
|
|
$link-hover-color: #1e2028;
|
2019-02-21 15:05:17 +01:00
|
|
|
$external-link-color: #5794f2;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
|
|
|
|
// Typography
|
|
|
|
|
// -------------------------
|
2019-02-21 15:05:17 +01:00
|
|
|
$headings-color: #52545c;
|
2017-12-19 16:22:41 +01:00
|
|
|
$abbr-border-color: $gray-2 !default;
|
|
|
|
|
$text-muted: $text-color-weak;
|
2016-02-16 10:42:06 +01:00
|
|
|
|
2019-02-19 13:57:56 +01:00
|
|
|
$hr-border-color: $gray-4 !default;
|
2016-02-16 09:42:46 +01:00
|
|
|
|
|
|
|
|
// Panel
|
|
|
|
|
// -------------------------
|
2019-12-23 07:22:44 +01:00
|
|
|
$panel-bg: #ffffff;
|
2020-03-24 10:30:53 +01:00
|
|
|
$panel-border: 1px solid #e9edf2;
|
2017-12-19 16:22:41 +01:00
|
|
|
$panel-header-hover-bg: $gray-6;
|
2019-01-07 13:56:36 +01:00
|
|
|
$panel-corner: $gray-4;
|
2016-02-16 09:42:46 +01:00
|
|
|
|
2017-12-03 08:11:07 +01:00
|
|
|
// Page header
|
2020-03-24 10:30:53 +01:00
|
|
|
$page-header-bg: linear-gradient(90deg, $white, #e9edf2);
|
2017-12-05 12:48:16 +01:00
|
|
|
$page-header-shadow: inset 0px -3px 10px $gray-6;
|
|
|
|
|
$page-header-border-color: $gray-4;
|
2017-12-03 08:11:07 +01:00
|
|
|
|
2017-12-19 16:22:41 +01:00
|
|
|
$divider-border-color: $gray-2;
|
2016-02-16 09:42:46 +01:00
|
|
|
|
|
|
|
|
// Graphite Target Editor
|
2017-12-19 16:22:41 +01:00
|
|
|
$tight-form-func-bg: $gray-5;
|
|
|
|
|
$tight-form-func-highlight-bg: $gray-6;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2017-10-10 17:57:53 +02:00
|
|
|
$modal-backdrop-bg: $body-bg;
|
2017-12-19 16:22:41 +01:00
|
|
|
$code-tag-bg: $gray-6;
|
2019-02-19 13:57:56 +01:00
|
|
|
$code-tag-border: $gray-4;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2017-11-23 12:54:12 +01:00
|
|
|
// cards
|
2020-01-17 09:43:17 +01:00
|
|
|
$card-background: linear-gradient(135deg, $gray-6, $gray-7);
|
|
|
|
|
$card-background-hover: linear-gradient(135deg, $gray-6, $gray-5);
|
2018-01-25 12:17:16 +01:00
|
|
|
$card-shadow: -1px -1px 0 0 hsla(0, 0%, 100%, 0.1), 1px 1px 0 0 rgba(0, 0, 0, 0.1);
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2017-11-23 12:54:12 +01:00
|
|
|
// Lists
|
2020-01-17 09:43:17 +01:00
|
|
|
$list-item-bg: $gray-7;
|
|
|
|
|
$list-item-hover-bg: $gray-6;
|
2017-11-23 12:54:12 +01:00
|
|
|
$list-item-link-color: $text-color;
|
2017-12-19 16:22:41 +01:00
|
|
|
$list-item-shadow: $card-shadow;
|
2019-02-06 15:45:40 +01:00
|
|
|
|
2018-01-31 14:14:11 +01:00
|
|
|
$empty-list-cta-bg: $gray-6;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2019-02-06 15:45:40 +01:00
|
|
|
// Scrollbars
|
2019-02-19 13:57:56 +01:00
|
|
|
$scrollbarBackground: $gray-4;
|
|
|
|
|
$scrollbarBackground2: $gray-4;
|
2019-02-21 09:41:53 +01:00
|
|
|
$scrollbarBorder: $gray-7;
|
2019-02-06 15:45:40 +01:00
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
// Tables
|
|
|
|
|
// -------------------------
|
2017-12-19 16:22:41 +01:00
|
|
|
$table-bg-accent: $gray-5; // for striping
|
|
|
|
|
$table-border: $gray-3; // table and cell border
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2018-01-25 12:17:16 +01:00
|
|
|
$table-bg-odd: $gray-6;
|
|
|
|
|
$table-bg-hover: $gray-5;
|
2017-12-05 12:48:16 +01:00
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
// Buttons
|
|
|
|
|
// -------------------------
|
2020-03-26 11:50:27 +01:00
|
|
|
$btn-secondary-bg: $gray-5;
|
|
|
|
|
$btn-secondary-bg-hl: $gray-4;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2020-03-26 11:50:27 +01:00
|
|
|
$btn-primary-bg: $blue-base;
|
|
|
|
|
$btn-primary-bg-hl: $blue-shade;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2019-02-19 13:57:56 +01:00
|
|
|
$btn-success-bg: $green-base;
|
|
|
|
|
$btn-success-bg-hl: $green-shade;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2019-02-20 16:11:36 +01:00
|
|
|
$btn-danger-bg: $red-base;
|
|
|
|
|
$btn-danger-bg-hl: $red-shade;
|
2019-02-12 21:54:20 +01:00
|
|
|
|
2019-02-19 13:57:56 +01:00
|
|
|
$btn-inverse-bg: $gray-5;
|
|
|
|
|
$btn-inverse-bg-hl: $gray-4;
|
2017-12-19 16:22:41 +01:00
|
|
|
$btn-inverse-text-color: $gray-1;
|
|
|
|
|
$btn-inverse-text-shadow: 0 1px 0 rgba(255, 255, 255, 0.4);
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2016-02-19 14:21:57 +01:00
|
|
|
$btn-link-color: $gray-1;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2019-02-06 15:45:40 +01:00
|
|
|
$iconContainerBackground: $white;
|
|
|
|
|
|
2017-12-19 16:22:41 +01:00
|
|
|
$btn-divider-left: $gray-4;
|
|
|
|
|
$btn-divider-right: $gray-7;
|
2016-08-11 18:25:41 +02:00
|
|
|
|
2019-02-06 15:45:40 +01:00
|
|
|
$btn-drag-image: '../img/grab_light.svg';
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2019-04-17 15:18:32 +02:00
|
|
|
$navbar-btn-gicon-brightness: brightness(1.5);
|
|
|
|
|
|
2019-11-22 12:26:14 +01:00
|
|
|
$btn-active-box-shadow: 0px 0px 4px rgba(234, 161, 51, 0.6);
|
|
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
// Forms
|
|
|
|
|
// -------------------------
|
2017-12-19 16:22:41 +01:00
|
|
|
$input-bg: $white;
|
|
|
|
|
$input-bg-disabled: $gray-5;
|
|
|
|
|
|
2020-04-05 20:02:52 +02:00
|
|
|
$input-color: #343b40;
|
|
|
|
|
$input-border-color: #e9edf2;
|
2017-12-19 16:22:41 +01:00
|
|
|
$input-box-shadow: none;
|
2020-04-05 20:02:52 +02:00
|
|
|
$input-border-focus: #5794f2;
|
|
|
|
|
$input-box-shadow-focus: #5794f2;
|
2020-04-01 16:56:42 +02:00
|
|
|
$input-color-placeholder: #9fa7b3;
|
2020-04-05 20:02:52 +02:00
|
|
|
$input-label-bg: #e9edf2;
|
|
|
|
|
$input-label-border-color: #e9edf2;
|
|
|
|
|
$input-color-select-arrow: #7b8087;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
|
|
|
|
// search
|
2019-04-22 16:04:35 +02:00
|
|
|
$search-shadow: 0 1px 5px 0 $gray-5;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2018-05-25 12:51:27 +02:00
|
|
|
// Typeahead
|
|
|
|
|
$typeahead-shadow: 0 5px 10px 0 $gray-5;
|
2018-12-03 17:20:02 +01:00
|
|
|
$typeahead-selected-bg: $gray-6;
|
|
|
|
|
$typeahead-selected-color: $yellow;
|
2018-05-25 12:51:27 +02:00
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
// Dropdowns
|
|
|
|
|
// -------------------------
|
2017-12-19 16:22:41 +01:00
|
|
|
$dropdownBackground: $white;
|
|
|
|
|
$dropdownBorder: $gray-4;
|
|
|
|
|
$dropdownDividerTop: $gray-6;
|
|
|
|
|
$dropdownDividerBottom: $white;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2019-02-20 16:11:36 +01:00
|
|
|
$dropdownLinkColor: $dark-2;
|
2017-12-19 16:22:41 +01:00
|
|
|
$dropdownLinkColorHover: $link-color;
|
|
|
|
|
$dropdownLinkColorActive: $link-color;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2017-12-19 16:22:41 +01:00
|
|
|
$dropdownLinkBackgroundHover: $gray-6;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
|
|
|
|
// Horizontal forms & lists
|
|
|
|
|
// -------------------------
|
2017-12-19 16:22:41 +01:00
|
|
|
$horizontalComponentOffset: 180px;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
|
|
|
|
// Navbar
|
|
|
|
|
// -------------------------
|
2017-12-19 16:22:41 +01:00
|
|
|
$navbarHeight: 52px;
|
2019-02-19 13:57:56 +01:00
|
|
|
$navbarBorder: 1px solid $gray-5;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2020-03-24 10:30:53 +01:00
|
|
|
$navbarButtonBackground: $panel-bg;
|
2017-12-19 16:22:41 +01:00
|
|
|
$navbar-button-border: $gray-4;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2019-02-06 15:45:40 +01:00
|
|
|
// Sidemenu
|
2016-02-15 15:27:41 +01:00
|
|
|
// -------------------------
|
2020-03-24 10:30:53 +01:00
|
|
|
$side-menu-bg: #202226;
|
|
|
|
|
$side-menu-border: 1px solid #343b40;
|
2019-02-06 15:45:40 +01:00
|
|
|
$side-menu-bg-mobile: rgba(0, 0, 0, 0); //$gray-6;
|
2020-03-24 10:30:53 +01:00
|
|
|
$side-menu-item-hover-bg: #343b40;
|
2019-02-06 15:45:40 +01:00
|
|
|
$side-menu-shadow: 5px 0px 10px -5px $gray-1;
|
|
|
|
|
$side-menu-link-color: $gray-6;
|
|
|
|
|
|
|
|
|
|
// Menu dropdowns
|
|
|
|
|
// -------------------------
|
2020-03-24 10:30:53 +01:00
|
|
|
$menu-dropdown-bg: $panel-bg;
|
2019-02-06 15:45:40 +01:00
|
|
|
$menu-dropdown-hover-bg: $gray-6;
|
|
|
|
|
$menu-dropdown-shadow: 5px 5px 10px -5px $gray-1;
|
|
|
|
|
|
|
|
|
|
// Tabs
|
|
|
|
|
// -------------------------
|
|
|
|
|
$tab-border-color: $gray-5;
|
|
|
|
|
|
|
|
|
|
// Toolbar
|
|
|
|
|
$toolbar-bg: white;
|
2016-02-15 15:27:41 +01:00
|
|
|
|
|
|
|
|
// Form states and alerts
|
|
|
|
|
// -------------------------
|
2017-12-19 16:22:41 +01:00
|
|
|
$warning-text-color: lighten($orange, 10%);
|
2019-02-20 16:11:36 +01:00
|
|
|
$error-text-color: $red-shade;
|
|
|
|
|
$success-text-color: lighten($green-base, 10%);
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2019-02-20 16:11:36 +01:00
|
|
|
$alert-error-bg: linear-gradient(90deg, $red-base, $red-shade);
|
2019-02-19 13:57:56 +01:00
|
|
|
$alert-success-bg: linear-gradient(90deg, $green-base, $green-shade);
|
2019-02-20 16:11:36 +01:00
|
|
|
$alert-warning-bg: linear-gradient(90deg, $red-base, $red-shade);
|
|
|
|
|
$alert-info-bg: linear-gradient(100deg, $blue-base, $blue-shade);
|
2016-02-15 15:27:41 +01:00
|
|
|
|
2020-03-30 16:31:53 +02:00
|
|
|
// Tooltips and popovers
|
|
|
|
|
$tooltipBackground: $gray-1;
|
|
|
|
|
$tooltipColor: $gray-7;
|
|
|
|
|
$tooltipArrowColor: $tooltipBackground; // Used by Angular tooltip
|
|
|
|
|
$tooltipBackgroundError: $brand-danger;
|
|
|
|
|
$tooltipShadow: 0 0 5px $gray60;
|
|
|
|
|
$graph-tooltip-bg: $gray-5;
|
|
|
|
|
|
|
|
|
|
$tooltipArrowWidth: 5px;
|
|
|
|
|
$tooltipLinkColor: lighten($tooltipColor, 5%);
|
|
|
|
|
|
2017-12-19 16:22:41 +01:00
|
|
|
$popover-bg: $page-bg;
|
|
|
|
|
$popover-color: $text-color;
|
|
|
|
|
$popover-border-color: $gray-5;
|
2019-06-24 14:39:59 +02:00
|
|
|
$popover-header-bg: $gray-5;
|
2017-12-19 16:22:41 +01:00
|
|
|
$popover-shadow: 0 0 20px $white;
|
2017-10-07 10:31:39 +02:00
|
|
|
|
2017-12-19 16:22:41 +01:00
|
|
|
$popover-error-bg: $btn-danger-bg;
|
2020-03-30 16:31:53 +02:00
|
|
|
$popover-help-bg: $tooltipBackground;
|
|
|
|
|
$popover-help-color: $tooltipColor;
|
2019-01-07 13:05:27 +01:00
|
|
|
|
2016-02-15 15:27:41 +01:00
|
|
|
// images
|
2018-01-25 12:17:16 +01:00
|
|
|
$checkboxImageUrl: '../img/checkbox_white.png';
|
2016-03-15 09:15:24 +01:00
|
|
|
|
2017-07-31 14:39:33 +02:00
|
|
|
// info box
|
2019-02-20 16:11:36 +01:00
|
|
|
$info-box-border-color: $blue-base;
|
2017-07-31 14:39:33 +02:00
|
|
|
|
2016-05-24 08:11:28 +02:00
|
|
|
// footer
|
2017-12-19 16:22:41 +01:00
|
|
|
$footer-link-color: $gray-3;
|
2019-02-20 16:11:36 +01:00
|
|
|
$footer-link-hover: $dark-2;
|
History and Version Control for Dashboard Updates
A simple version control system for dashboards. Closes #1504.
Goals
1. To create a new dashboard version every time a dashboard is saved.
2. To allow users to view all versions of a given dashboard.
3. To allow users to rollback to a previous version of a dashboard.
4. To allow users to compare two versions of a dashboard.
Usage
Navigate to a dashboard, and click the settings cog. From there, click
the "Changelog" button to be brought to the Changelog view. In this
view, a table containing each version of a dashboard can be seen. Each
entry in the table represents a dashboard version. A selectable
checkbox, the version number, date created, name of the user who created
that version, and commit message is shown in the table, along with a
button that allows a user to restore to a previous version of that
dashboard. If a user wants to restore to a previous version of their
dashboard, they can do so by clicking the previously mentioned button.
If a user wants to compare two different versions of a dashboard, they
can do so by clicking the checkbox of two different dashboard versions,
then clicking the "Compare versions" button located below the dashboard.
From there, the user is brought to a view showing a summary of the
dashboard differences. Each summarized change contains a link that can
be clicked to take the user a JSON diff highlighting the changes line by
line.
Overview of Changes
Backend Changes
- A `dashboard_version` table was created to store each dashboard
version, along with a dashboard version model and structs to represent
the queries and commands necessary for the dashboard version API
methods.
- API endpoints were created to support working with dashboard
versions.
- Methods were added to create, update, read, and destroy dashboard
versions in the database.
- Logic was added to compute the diff between two versions, and
display it to the user.
- The dashboard migration logic was updated to save a "Version
1" of each existing dashboard in the database.
Frontend Changes
- New views
- Methods to pull JSON and HTML from endpoints
New API Endpoints
Each endpoint requires the authorization header to be sent in
the format,
```
Authorization: Bearer <jwt>
```
where `<jwt>` is a JSON web token obtained from the Grafana
admin panel.
`GET "/api/dashboards/db/:dashboardId/versions?orderBy=<string>&limit=<int>&start=<int>"`
Get all dashboard versions for the given dashboard ID. Accepts
three URL parameters:
- `orderBy` String to order the results by. Possible values
are `version`, `created`, `created_by`, `message`. Default
is `versions`. Ordering is always in descending order.
- `limit` Maximum number of results to return
- `start` Position in results to start from
`GET "/api/dashboards/db/:dashboardId/versions/:id"`
Get an individual dashboard version by ID, for the given
dashboard ID.
`POST "/api/dashboards/db/:dashboardId/restore"`
Restore to the given dashboard version. Post body is of
content-type `application/json`, and must contain.
```json
{
"dashboardId": <int>,
"version": <int>
}
```
`GET "/api/dashboards/db/:dashboardId/compare/:versionA...:versionB"`
Compare two dashboard versions by ID for the given
dashboard ID, returning a JSON delta formatted
representation of the diff. The URL format follows
what GitHub does. For example, visiting
[/api/dashboards/db/18/compare/22...33](http://ec2-54-80-139-44.compute-1.amazonaws.com:3000/api/dashboards/db/18/compare/22...33)
will return the diff between versions 22 and 33 for
the dashboard ID 18.
Dependencies Added
- The Go package [gojsondiff](https://github.com/yudai/gojsondiff)
was added and vendored.
2017-05-24 19:14:39 -04:00
|
|
|
|
2017-05-20 18:21:41 +02:00
|
|
|
// json explorer
|
|
|
|
|
$json-explorer-default-color: black;
|
|
|
|
|
$json-explorer-string-color: green;
|
2019-02-20 16:11:36 +01:00
|
|
|
$json-explorer-number-color: $blue-base;
|
|
|
|
|
$json-explorer-boolean-color: $red-base;
|
2017-12-19 16:22:41 +01:00
|
|
|
$json-explorer-null-color: #855a00;
|
2017-05-20 18:21:41 +02:00
|
|
|
$json-explorer-undefined-color: rgb(202, 11, 105);
|
2017-12-19 16:22:41 +01:00
|
|
|
$json-explorer-function-color: #ff20ed;
|
2017-05-20 18:21:41 +02:00
|
|
|
$json-explorer-rotate-time: 100ms;
|
|
|
|
|
$json-explorer-toggler-opacity: 0.6;
|
2019-02-20 16:11:36 +01:00
|
|
|
$json-explorer-bracket-color: $blue-base;
|
2017-12-19 16:22:41 +01:00
|
|
|
$json-explorer-key-color: #00008b;
|
2019-02-20 16:11:36 +01:00
|
|
|
$json-explorer-url-color: $blue-base;
|
History and Version Control for Dashboard Updates
A simple version control system for dashboards. Closes #1504.
Goals
1. To create a new dashboard version every time a dashboard is saved.
2. To allow users to view all versions of a given dashboard.
3. To allow users to rollback to a previous version of a dashboard.
4. To allow users to compare two versions of a dashboard.
Usage
Navigate to a dashboard, and click the settings cog. From there, click
the "Changelog" button to be brought to the Changelog view. In this
view, a table containing each version of a dashboard can be seen. Each
entry in the table represents a dashboard version. A selectable
checkbox, the version number, date created, name of the user who created
that version, and commit message is shown in the table, along with a
button that allows a user to restore to a previous version of that
dashboard. If a user wants to restore to a previous version of their
dashboard, they can do so by clicking the previously mentioned button.
If a user wants to compare two different versions of a dashboard, they
can do so by clicking the checkbox of two different dashboard versions,
then clicking the "Compare versions" button located below the dashboard.
From there, the user is brought to a view showing a summary of the
dashboard differences. Each summarized change contains a link that can
be clicked to take the user a JSON diff highlighting the changes line by
line.
Overview of Changes
Backend Changes
- A `dashboard_version` table was created to store each dashboard
version, along with a dashboard version model and structs to represent
the queries and commands necessary for the dashboard version API
methods.
- API endpoints were created to support working with dashboard
versions.
- Methods were added to create, update, read, and destroy dashboard
versions in the database.
- Logic was added to compute the diff between two versions, and
display it to the user.
- The dashboard migration logic was updated to save a "Version
1" of each existing dashboard in the database.
Frontend Changes
- New views
- Methods to pull JSON and HTML from endpoints
New API Endpoints
Each endpoint requires the authorization header to be sent in
the format,
```
Authorization: Bearer <jwt>
```
where `<jwt>` is a JSON web token obtained from the Grafana
admin panel.
`GET "/api/dashboards/db/:dashboardId/versions?orderBy=<string>&limit=<int>&start=<int>"`
Get all dashboard versions for the given dashboard ID. Accepts
three URL parameters:
- `orderBy` String to order the results by. Possible values
are `version`, `created`, `created_by`, `message`. Default
is `versions`. Ordering is always in descending order.
- `limit` Maximum number of results to return
- `start` Position in results to start from
`GET "/api/dashboards/db/:dashboardId/versions/:id"`
Get an individual dashboard version by ID, for the given
dashboard ID.
`POST "/api/dashboards/db/:dashboardId/restore"`
Restore to the given dashboard version. Post body is of
content-type `application/json`, and must contain.
```json
{
"dashboardId": <int>,
"version": <int>
}
```
`GET "/api/dashboards/db/:dashboardId/compare/:versionA...:versionB"`
Compare two dashboard versions by ID for the given
dashboard ID, returning a JSON delta formatted
representation of the diff. The URL format follows
what GitHub does. For example, visiting
[/api/dashboards/db/18/compare/22...33](http://ec2-54-80-139-44.compute-1.amazonaws.com:3000/api/dashboards/db/18/compare/22...33)
will return the diff between versions 22 and 33 for
the dashboard ID 18.
Dependencies Added
- The Go package [gojsondiff](https://github.com/yudai/gojsondiff)
was added and vendored.
2017-05-24 19:14:39 -04:00
|
|
|
|
|
|
|
|
// Changelog and diff
|
|
|
|
|
// -------------------------
|
2019-02-19 13:57:56 +01:00
|
|
|
$diff-label-bg: $gray-7;
|
2017-12-19 16:22:41 +01:00
|
|
|
$diff-label-fg: $gray-2;
|
History and Version Control for Dashboard Updates
A simple version control system for dashboards. Closes #1504.
Goals
1. To create a new dashboard version every time a dashboard is saved.
2. To allow users to view all versions of a given dashboard.
3. To allow users to rollback to a previous version of a dashboard.
4. To allow users to compare two versions of a dashboard.
Usage
Navigate to a dashboard, and click the settings cog. From there, click
the "Changelog" button to be brought to the Changelog view. In this
view, a table containing each version of a dashboard can be seen. Each
entry in the table represents a dashboard version. A selectable
checkbox, the version number, date created, name of the user who created
that version, and commit message is shown in the table, along with a
button that allows a user to restore to a previous version of that
dashboard. If a user wants to restore to a previous version of their
dashboard, they can do so by clicking the previously mentioned button.
If a user wants to compare two different versions of a dashboard, they
can do so by clicking the checkbox of two different dashboard versions,
then clicking the "Compare versions" button located below the dashboard.
From there, the user is brought to a view showing a summary of the
dashboard differences. Each summarized change contains a link that can
be clicked to take the user a JSON diff highlighting the changes line by
line.
Overview of Changes
Backend Changes
- A `dashboard_version` table was created to store each dashboard
version, along with a dashboard version model and structs to represent
the queries and commands necessary for the dashboard version API
methods.
- API endpoints were created to support working with dashboard
versions.
- Methods were added to create, update, read, and destroy dashboard
versions in the database.
- Logic was added to compute the diff between two versions, and
display it to the user.
- The dashboard migration logic was updated to save a "Version
1" of each existing dashboard in the database.
Frontend Changes
- New views
- Methods to pull JSON and HTML from endpoints
New API Endpoints
Each endpoint requires the authorization header to be sent in
the format,
```
Authorization: Bearer <jwt>
```
where `<jwt>` is a JSON web token obtained from the Grafana
admin panel.
`GET "/api/dashboards/db/:dashboardId/versions?orderBy=<string>&limit=<int>&start=<int>"`
Get all dashboard versions for the given dashboard ID. Accepts
three URL parameters:
- `orderBy` String to order the results by. Possible values
are `version`, `created`, `created_by`, `message`. Default
is `versions`. Ordering is always in descending order.
- `limit` Maximum number of results to return
- `start` Position in results to start from
`GET "/api/dashboards/db/:dashboardId/versions/:id"`
Get an individual dashboard version by ID, for the given
dashboard ID.
`POST "/api/dashboards/db/:dashboardId/restore"`
Restore to the given dashboard version. Post body is of
content-type `application/json`, and must contain.
```json
{
"dashboardId": <int>,
"version": <int>
}
```
`GET "/api/dashboards/db/:dashboardId/compare/:versionA...:versionB"`
Compare two dashboard versions by ID for the given
dashboard ID, returning a JSON delta formatted
representation of the diff. The URL format follows
what GitHub does. For example, visiting
[/api/dashboards/db/18/compare/22...33](http://ec2-54-80-139-44.compute-1.amazonaws.com:3000/api/dashboards/db/18/compare/22...33)
will return the diff between versions 22 and 33 for
the dashboard ID 18.
Dependencies Added
- The Go package [gojsondiff](https://github.com/yudai/gojsondiff)
was added and vendored.
2017-05-24 19:14:39 -04:00
|
|
|
|
2019-02-20 16:11:36 +01:00
|
|
|
$diff-arrow-color: $dark-2;
|
2019-02-19 13:57:56 +01:00
|
|
|
$diff-group-bg: $gray-6;
|
History and Version Control for Dashboard Updates
A simple version control system for dashboards. Closes #1504.
Goals
1. To create a new dashboard version every time a dashboard is saved.
2. To allow users to view all versions of a given dashboard.
3. To allow users to rollback to a previous version of a dashboard.
4. To allow users to compare two versions of a dashboard.
Usage
Navigate to a dashboard, and click the settings cog. From there, click
the "Changelog" button to be brought to the Changelog view. In this
view, a table containing each version of a dashboard can be seen. Each
entry in the table represents a dashboard version. A selectable
checkbox, the version number, date created, name of the user who created
that version, and commit message is shown in the table, along with a
button that allows a user to restore to a previous version of that
dashboard. If a user wants to restore to a previous version of their
dashboard, they can do so by clicking the previously mentioned button.
If a user wants to compare two different versions of a dashboard, they
can do so by clicking the checkbox of two different dashboard versions,
then clicking the "Compare versions" button located below the dashboard.
From there, the user is brought to a view showing a summary of the
dashboard differences. Each summarized change contains a link that can
be clicked to take the user a JSON diff highlighting the changes line by
line.
Overview of Changes
Backend Changes
- A `dashboard_version` table was created to store each dashboard
version, along with a dashboard version model and structs to represent
the queries and commands necessary for the dashboard version API
methods.
- API endpoints were created to support working with dashboard
versions.
- Methods were added to create, update, read, and destroy dashboard
versions in the database.
- Logic was added to compute the diff between two versions, and
display it to the user.
- The dashboard migration logic was updated to save a "Version
1" of each existing dashboard in the database.
Frontend Changes
- New views
- Methods to pull JSON and HTML from endpoints
New API Endpoints
Each endpoint requires the authorization header to be sent in
the format,
```
Authorization: Bearer <jwt>
```
where `<jwt>` is a JSON web token obtained from the Grafana
admin panel.
`GET "/api/dashboards/db/:dashboardId/versions?orderBy=<string>&limit=<int>&start=<int>"`
Get all dashboard versions for the given dashboard ID. Accepts
three URL parameters:
- `orderBy` String to order the results by. Possible values
are `version`, `created`, `created_by`, `message`. Default
is `versions`. Ordering is always in descending order.
- `limit` Maximum number of results to return
- `start` Position in results to start from
`GET "/api/dashboards/db/:dashboardId/versions/:id"`
Get an individual dashboard version by ID, for the given
dashboard ID.
`POST "/api/dashboards/db/:dashboardId/restore"`
Restore to the given dashboard version. Post body is of
content-type `application/json`, and must contain.
```json
{
"dashboardId": <int>,
"version": <int>
}
```
`GET "/api/dashboards/db/:dashboardId/compare/:versionA...:versionB"`
Compare two dashboard versions by ID for the given
dashboard ID, returning a JSON delta formatted
representation of the diff. The URL format follows
what GitHub does. For example, visiting
[/api/dashboards/db/18/compare/22...33](http://ec2-54-80-139-44.compute-1.amazonaws.com:3000/api/dashboards/db/18/compare/22...33)
will return the diff between versions 22 and 33 for
the dashboard ID 18.
Dependencies Added
- The Go package [gojsondiff](https://github.com/yudai/gojsondiff)
was added and vendored.
2017-05-24 19:14:39 -04:00
|
|
|
|
2019-02-19 13:57:56 +01:00
|
|
|
$diff-json-bg: $gray-6;
|
|
|
|
|
$diff-json-fg: $gray-1;
|
History and Version Control for Dashboard Updates
A simple version control system for dashboards. Closes #1504.
Goals
1. To create a new dashboard version every time a dashboard is saved.
2. To allow users to view all versions of a given dashboard.
3. To allow users to rollback to a previous version of a dashboard.
4. To allow users to compare two versions of a dashboard.
Usage
Navigate to a dashboard, and click the settings cog. From there, click
the "Changelog" button to be brought to the Changelog view. In this
view, a table containing each version of a dashboard can be seen. Each
entry in the table represents a dashboard version. A selectable
checkbox, the version number, date created, name of the user who created
that version, and commit message is shown in the table, along with a
button that allows a user to restore to a previous version of that
dashboard. If a user wants to restore to a previous version of their
dashboard, they can do so by clicking the previously mentioned button.
If a user wants to compare two different versions of a dashboard, they
can do so by clicking the checkbox of two different dashboard versions,
then clicking the "Compare versions" button located below the dashboard.
From there, the user is brought to a view showing a summary of the
dashboard differences. Each summarized change contains a link that can
be clicked to take the user a JSON diff highlighting the changes line by
line.
Overview of Changes
Backend Changes
- A `dashboard_version` table was created to store each dashboard
version, along with a dashboard version model and structs to represent
the queries and commands necessary for the dashboard version API
methods.
- API endpoints were created to support working with dashboard
versions.
- Methods were added to create, update, read, and destroy dashboard
versions in the database.
- Logic was added to compute the diff between two versions, and
display it to the user.
- The dashboard migration logic was updated to save a "Version
1" of each existing dashboard in the database.
Frontend Changes
- New views
- Methods to pull JSON and HTML from endpoints
New API Endpoints
Each endpoint requires the authorization header to be sent in
the format,
```
Authorization: Bearer <jwt>
```
where `<jwt>` is a JSON web token obtained from the Grafana
admin panel.
`GET "/api/dashboards/db/:dashboardId/versions?orderBy=<string>&limit=<int>&start=<int>"`
Get all dashboard versions for the given dashboard ID. Accepts
three URL parameters:
- `orderBy` String to order the results by. Possible values
are `version`, `created`, `created_by`, `message`. Default
is `versions`. Ordering is always in descending order.
- `limit` Maximum number of results to return
- `start` Position in results to start from
`GET "/api/dashboards/db/:dashboardId/versions/:id"`
Get an individual dashboard version by ID, for the given
dashboard ID.
`POST "/api/dashboards/db/:dashboardId/restore"`
Restore to the given dashboard version. Post body is of
content-type `application/json`, and must contain.
```json
{
"dashboardId": <int>,
"version": <int>
}
```
`GET "/api/dashboards/db/:dashboardId/compare/:versionA...:versionB"`
Compare two dashboard versions by ID for the given
dashboard ID, returning a JSON delta formatted
representation of the diff. The URL format follows
what GitHub does. For example, visiting
[/api/dashboards/db/18/compare/22...33](http://ec2-54-80-139-44.compute-1.amazonaws.com:3000/api/dashboards/db/18/compare/22...33)
will return the diff between versions 22 and 33 for
the dashboard ID 18.
Dependencies Added
- The Go package [gojsondiff](https://github.com/yudai/gojsondiff)
was added and vendored.
2017-05-24 19:14:39 -04:00
|
|
|
|
2019-02-20 16:11:36 +01:00
|
|
|
$diff-json-added: $blue-shade;
|
|
|
|
|
$diff-json-deleted: $red-shade;
|
History and Version Control for Dashboard Updates
A simple version control system for dashboards. Closes #1504.
Goals
1. To create a new dashboard version every time a dashboard is saved.
2. To allow users to view all versions of a given dashboard.
3. To allow users to rollback to a previous version of a dashboard.
4. To allow users to compare two versions of a dashboard.
Usage
Navigate to a dashboard, and click the settings cog. From there, click
the "Changelog" button to be brought to the Changelog view. In this
view, a table containing each version of a dashboard can be seen. Each
entry in the table represents a dashboard version. A selectable
checkbox, the version number, date created, name of the user who created
that version, and commit message is shown in the table, along with a
button that allows a user to restore to a previous version of that
dashboard. If a user wants to restore to a previous version of their
dashboard, they can do so by clicking the previously mentioned button.
If a user wants to compare two different versions of a dashboard, they
can do so by clicking the checkbox of two different dashboard versions,
then clicking the "Compare versions" button located below the dashboard.
From there, the user is brought to a view showing a summary of the
dashboard differences. Each summarized change contains a link that can
be clicked to take the user a JSON diff highlighting the changes line by
line.
Overview of Changes
Backend Changes
- A `dashboard_version` table was created to store each dashboard
version, along with a dashboard version model and structs to represent
the queries and commands necessary for the dashboard version API
methods.
- API endpoints were created to support working with dashboard
versions.
- Methods were added to create, update, read, and destroy dashboard
versions in the database.
- Logic was added to compute the diff between two versions, and
display it to the user.
- The dashboard migration logic was updated to save a "Version
1" of each existing dashboard in the database.
Frontend Changes
- New views
- Methods to pull JSON and HTML from endpoints
New API Endpoints
Each endpoint requires the authorization header to be sent in
the format,
```
Authorization: Bearer <jwt>
```
where `<jwt>` is a JSON web token obtained from the Grafana
admin panel.
`GET "/api/dashboards/db/:dashboardId/versions?orderBy=<string>&limit=<int>&start=<int>"`
Get all dashboard versions for the given dashboard ID. Accepts
three URL parameters:
- `orderBy` String to order the results by. Possible values
are `version`, `created`, `created_by`, `message`. Default
is `versions`. Ordering is always in descending order.
- `limit` Maximum number of results to return
- `start` Position in results to start from
`GET "/api/dashboards/db/:dashboardId/versions/:id"`
Get an individual dashboard version by ID, for the given
dashboard ID.
`POST "/api/dashboards/db/:dashboardId/restore"`
Restore to the given dashboard version. Post body is of
content-type `application/json`, and must contain.
```json
{
"dashboardId": <int>,
"version": <int>
}
```
`GET "/api/dashboards/db/:dashboardId/compare/:versionA...:versionB"`
Compare two dashboard versions by ID for the given
dashboard ID, returning a JSON delta formatted
representation of the diff. The URL format follows
what GitHub does. For example, visiting
[/api/dashboards/db/18/compare/22...33](http://ec2-54-80-139-44.compute-1.amazonaws.com:3000/api/dashboards/db/18/compare/22...33)
will return the diff between versions 22 and 33 for
the dashboard ID 18.
Dependencies Added
- The Go package [gojsondiff](https://github.com/yudai/gojsondiff)
was added and vendored.
2017-05-24 19:14:39 -04:00
|
|
|
|
2017-12-19 16:22:41 +01:00
|
|
|
$diff-json-old: #5a372a;
|
|
|
|
|
$diff-json-new: #664e33;
|
History and Version Control for Dashboard Updates
A simple version control system for dashboards. Closes #1504.
Goals
1. To create a new dashboard version every time a dashboard is saved.
2. To allow users to view all versions of a given dashboard.
3. To allow users to rollback to a previous version of a dashboard.
4. To allow users to compare two versions of a dashboard.
Usage
Navigate to a dashboard, and click the settings cog. From there, click
the "Changelog" button to be brought to the Changelog view. In this
view, a table containing each version of a dashboard can be seen. Each
entry in the table represents a dashboard version. A selectable
checkbox, the version number, date created, name of the user who created
that version, and commit message is shown in the table, along with a
button that allows a user to restore to a previous version of that
dashboard. If a user wants to restore to a previous version of their
dashboard, they can do so by clicking the previously mentioned button.
If a user wants to compare two different versions of a dashboard, they
can do so by clicking the checkbox of two different dashboard versions,
then clicking the "Compare versions" button located below the dashboard.
From there, the user is brought to a view showing a summary of the
dashboard differences. Each summarized change contains a link that can
be clicked to take the user a JSON diff highlighting the changes line by
line.
Overview of Changes
Backend Changes
- A `dashboard_version` table was created to store each dashboard
version, along with a dashboard version model and structs to represent
the queries and commands necessary for the dashboard version API
methods.
- API endpoints were created to support working with dashboard
versions.
- Methods were added to create, update, read, and destroy dashboard
versions in the database.
- Logic was added to compute the diff between two versions, and
display it to the user.
- The dashboard migration logic was updated to save a "Version
1" of each existing dashboard in the database.
Frontend Changes
- New views
- Methods to pull JSON and HTML from endpoints
New API Endpoints
Each endpoint requires the authorization header to be sent in
the format,
```
Authorization: Bearer <jwt>
```
where `<jwt>` is a JSON web token obtained from the Grafana
admin panel.
`GET "/api/dashboards/db/:dashboardId/versions?orderBy=<string>&limit=<int>&start=<int>"`
Get all dashboard versions for the given dashboard ID. Accepts
three URL parameters:
- `orderBy` String to order the results by. Possible values
are `version`, `created`, `created_by`, `message`. Default
is `versions`. Ordering is always in descending order.
- `limit` Maximum number of results to return
- `start` Position in results to start from
`GET "/api/dashboards/db/:dashboardId/versions/:id"`
Get an individual dashboard version by ID, for the given
dashboard ID.
`POST "/api/dashboards/db/:dashboardId/restore"`
Restore to the given dashboard version. Post body is of
content-type `application/json`, and must contain.
```json
{
"dashboardId": <int>,
"version": <int>
}
```
`GET "/api/dashboards/db/:dashboardId/compare/:versionA...:versionB"`
Compare two dashboard versions by ID for the given
dashboard ID, returning a JSON delta formatted
representation of the diff. The URL format follows
what GitHub does. For example, visiting
[/api/dashboards/db/18/compare/22...33](http://ec2-54-80-139-44.compute-1.amazonaws.com:3000/api/dashboards/db/18/compare/22...33)
will return the diff between versions 22 and 33 for
the dashboard ID 18.
Dependencies Added
- The Go package [gojsondiff](https://github.com/yudai/gojsondiff)
was added and vendored.
2017-05-24 19:14:39 -04:00
|
|
|
|
2019-02-19 13:57:56 +01:00
|
|
|
$diff-json-changed-fg: $gray-7;
|
History and Version Control for Dashboard Updates
A simple version control system for dashboards. Closes #1504.
Goals
1. To create a new dashboard version every time a dashboard is saved.
2. To allow users to view all versions of a given dashboard.
3. To allow users to rollback to a previous version of a dashboard.
4. To allow users to compare two versions of a dashboard.
Usage
Navigate to a dashboard, and click the settings cog. From there, click
the "Changelog" button to be brought to the Changelog view. In this
view, a table containing each version of a dashboard can be seen. Each
entry in the table represents a dashboard version. A selectable
checkbox, the version number, date created, name of the user who created
that version, and commit message is shown in the table, along with a
button that allows a user to restore to a previous version of that
dashboard. If a user wants to restore to a previous version of their
dashboard, they can do so by clicking the previously mentioned button.
If a user wants to compare two different versions of a dashboard, they
can do so by clicking the checkbox of two different dashboard versions,
then clicking the "Compare versions" button located below the dashboard.
From there, the user is brought to a view showing a summary of the
dashboard differences. Each summarized change contains a link that can
be clicked to take the user a JSON diff highlighting the changes line by
line.
Overview of Changes
Backend Changes
- A `dashboard_version` table was created to store each dashboard
version, along with a dashboard version model and structs to represent
the queries and commands necessary for the dashboard version API
methods.
- API endpoints were created to support working with dashboard
versions.
- Methods were added to create, update, read, and destroy dashboard
versions in the database.
- Logic was added to compute the diff between two versions, and
display it to the user.
- The dashboard migration logic was updated to save a "Version
1" of each existing dashboard in the database.
Frontend Changes
- New views
- Methods to pull JSON and HTML from endpoints
New API Endpoints
Each endpoint requires the authorization header to be sent in
the format,
```
Authorization: Bearer <jwt>
```
where `<jwt>` is a JSON web token obtained from the Grafana
admin panel.
`GET "/api/dashboards/db/:dashboardId/versions?orderBy=<string>&limit=<int>&start=<int>"`
Get all dashboard versions for the given dashboard ID. Accepts
three URL parameters:
- `orderBy` String to order the results by. Possible values
are `version`, `created`, `created_by`, `message`. Default
is `versions`. Ordering is always in descending order.
- `limit` Maximum number of results to return
- `start` Position in results to start from
`GET "/api/dashboards/db/:dashboardId/versions/:id"`
Get an individual dashboard version by ID, for the given
dashboard ID.
`POST "/api/dashboards/db/:dashboardId/restore"`
Restore to the given dashboard version. Post body is of
content-type `application/json`, and must contain.
```json
{
"dashboardId": <int>,
"version": <int>
}
```
`GET "/api/dashboards/db/:dashboardId/compare/:versionA...:versionB"`
Compare two dashboard versions by ID for the given
dashboard ID, returning a JSON delta formatted
representation of the diff. The URL format follows
what GitHub does. For example, visiting
[/api/dashboards/db/18/compare/22...33](http://ec2-54-80-139-44.compute-1.amazonaws.com:3000/api/dashboards/db/18/compare/22...33)
will return the diff between versions 22 and 33 for
the dashboard ID 18.
Dependencies Added
- The Go package [gojsondiff](https://github.com/yudai/gojsondiff)
was added and vendored.
2017-05-24 19:14:39 -04:00
|
|
|
$diff-json-changed-num: $gray-4;
|
2019-02-06 15:45:40 +01:00
|
|
|
|
2017-12-19 16:22:41 +01:00
|
|
|
$diff-json-icon: $gray-4;
|
2018-07-20 16:02:41 +02:00
|
|
|
|
|
|
|
|
//Submenu
|
2019-02-19 13:57:56 +01:00
|
|
|
$variable-option-bg: $dropdownLinkBackgroundHover;
|
2018-11-16 13:02:29 +01:00
|
|
|
|
|
|
|
|
//Switch Slider
|
|
|
|
|
// -------------------------
|
|
|
|
|
$switch-bg: $white;
|
|
|
|
|
$switch-slider-color: $gray-7;
|
|
|
|
|
$switch-slider-off-bg: $gray-5;
|
2019-02-19 13:57:56 +01:00
|
|
|
$switch-slider-on-bg: linear-gradient(90deg, #ff9830, #e55400);
|
2019-02-20 16:11:36 +01:00
|
|
|
$switch-slider-shadow: 0 0 3px $dark-2;
|
2018-11-16 16:35:04 +01:00
|
|
|
|
|
|
|
|
//Checkbox
|
|
|
|
|
// -------------------------
|
|
|
|
|
$checkbox-bg: $gray-6;
|
|
|
|
|
$checkbox-border: 1px solid $gray-3;
|
2019-02-19 13:57:56 +01:00
|
|
|
$checkbox-checked-bg: linear-gradient(0deg, #ff9830, #e55400);
|
2018-11-16 16:35:04 +01:00
|
|
|
$checkbox-color: $gray-7;
|
2018-11-28 15:51:45 +01:00
|
|
|
|
|
|
|
|
//Panel Edit
|
|
|
|
|
// -------------------------
|
2018-12-16 10:30:48 -08:00
|
|
|
$panel-editor-shadow: 0px 0px 8px $gray-3;
|
2018-11-28 15:51:45 +01:00
|
|
|
$panel-editor-side-menu-shadow: drop-shadow(0 0 2px $gray-3);
|
|
|
|
|
$panel-editor-viz-item-shadow: 0 0 4px $gray-3;
|
|
|
|
|
$panel-editor-viz-item-border: 1px solid $gray-3;
|
2019-02-20 16:11:36 +01:00
|
|
|
$panel-editor-viz-item-shadow-hover: 0 0 4px $blue-light;
|
|
|
|
|
$panel-editor-viz-item-border-hover: 1px solid $blue-light;
|
2018-11-28 15:51:45 +01:00
|
|
|
$panel-editor-viz-item-bg: $white;
|
2019-02-20 16:11:36 +01:00
|
|
|
$panel-editor-tabs-line-color: $dark-2;
|
2019-02-19 13:57:56 +01:00
|
|
|
|
2019-02-20 16:11:36 +01:00
|
|
|
$panel-editor-viz-item-bg-hover: lighten($blue-base, 45%);
|
2019-02-12 21:54:20 +01:00
|
|
|
|
2019-01-29 15:37:22 +01:00
|
|
|
$panel-options-group-border: none;
|
|
|
|
|
$panel-options-group-header-bg: $gray-5;
|
2018-12-13 16:02:14 +01:00
|
|
|
|
2019-02-20 16:11:36 +01:00
|
|
|
$panel-grid-placeholder-bg: $blue-faint;
|
|
|
|
|
$panel-grid-placeholder-shadow: 0 0 4px $blue-light;
|
2018-12-07 14:59:38 +01:00
|
|
|
|
2018-12-06 11:55:01 -08:00
|
|
|
// logs
|
|
|
|
|
$logs-color-unkown: $gray-5;
|
2018-12-07 17:15:46 +01:00
|
|
|
|
|
|
|
|
// toggle-group
|
2018-12-07 12:13:23 -08:00
|
|
|
$button-toggle-group-btn-active-bg: $brand-primary;
|
|
|
|
|
$button-toggle-group-btn-active-shadow: inset 0 0 4px $white;
|
2018-12-07 17:15:46 +01:00
|
|
|
$button-toggle-group-btn-seperator-border: 1px solid $gray-6;
|
2018-12-18 17:20:09 +01:00
|
|
|
|
|
|
|
|
$vertical-resize-handle-bg: $gray-4;
|
|
|
|
|
$vertical-resize-handle-dots: $gray-3;
|
|
|
|
|
$vertical-resize-handle-dots-hover: $gray-2;
|
2019-06-24 14:39:59 +02:00
|
|
|
|
|
|
|
|
// Calendar
|
|
|
|
|
$calendar-bg-days: $white;
|
|
|
|
|
$calendar-bg-now: $gray-6;
|