blob: f7633de9d8592517c50c838c757a0603d3619792 [file] [log] [blame]
Alex Savatieievd48994d2018-12-13 12:13:00 +01001<!DOCTYPE html>
2<html lang="en">
3<head>
4 <meta charset="UTF-8">
5 <title>Model Tree Changes</title>
6 <style>
7 body {
8 font-family: Verdana, Geneva, Tahoma, sans-serif;
9 font-size: 90% !important;
10 }
11 .dot_green {
12 float: left;
13 color: green;
14 margin-right: 0.5em;
15 margin-top: 0.2em;
16 }
17 .dot_red {
18 float: left;
19 color: red;
20 margin-right: 0.5em;
21 margin-top: 0.2em;
22 }
23 .dot_empty {
24 float: left;
25 color: darkgray;
26 margin-right: 0.5em;
27 margin-top: 0.2em;
28 }
29 /* Style the tab */
30 .tab {
31 float: left;
32 width: 130px;
33 border: 1px solid #fff;
34 background-color: #efe;
35 }
36
37 /* Style the buttons that are used to open the tab content */
38 .tab button {
39 display: block;
40 background-color: inherit;
41 color: Black;
42 border: none;
43 outline: none;
44 font-family: "Lucida Console", Monaco, monospace;
45 text-align: left;
46 cursor: pointer;
47 transition: 0.3s;
48 font-size: 1.3em;
49 width: 100%;
50 padding: 1px;
51 margin: 1px;
52 }
53
54 button > div.node_name {
55 float: left;
56 font-size: 1.3em;
57 }
58
59 .smallgreytext {
60 float: right;
61 font-size: 0.7em;
62 color: gray;
63 }
64
65 /* Change background color of buttons on hover */
66 .tab button:hover {
67 background-color: #7b7;
68 }
69
70 /* Create an active/current "tab button" class */
71 .tab button.active {
72 background-color: #8c8;
73 color: white;
74 }
75
76 /* Style the tab content */
77 .tabcontent {
78 display: none;
79 position: absolute;
80 font-size: 1em;
81 padding: 0.5em;
82 right: -10%;
83 top: 0%;
84 transform: translateX(-12%);
85 width: calc(100% - 170px);
86 overflow-x: scroll;
87 overflow-wrap: break-word;
88 }
89
90 table {
91 border: 0 hidden;
92 width: 100%;
93 }
94 tr:nth-child(even) {
95 background-color: #fff;
96 }
97 tr:nth-child(odd) {
98 background-color: #ddd;
99 }
100 .Header {
101 background-color: #bbb;
102 color: Black;
103 width: 30%;
104 text-align: center;
105 }
106 .pkgName {
107 font-size: 1em;
108 padding-left: 10px;
109 }
110
111 .version {
112 font-size: 1.1em;
113 text-align: left;
114 }
115
116 .differ {
117 background-color: #eaa;
118 }
119 /* Tooltip container */
120 .tooltip {
121 position: relative;
122 display: inline-block;
123 border-bottom: 1px dotted black;
124 }
125
126 .tooltip .tooltiptext {
127 visibility: hidden;
128 background-color: black;
129 font-family: "Lucida Console", Monaco, monospace;
130 font-size: 0.5em;
131 width: auto;
132 color: #fff;
133 border-radius: 6px;
134 padding: 5px 5px;
135
136 /* Position the tooltip */
137 position: absolute;
138 z-index: 1;
139 }
140
141 .tooltip:hover .tooltiptext {
142 visibility: visible;
143 }
144
145 </style>
146 <script language="JavaScript">
147 function init() {
148 // Declare all variables
149 var i, tabcontent, tablinks;
150
151 // Get all elements with class="tabcontent" and hide them
152 tabcontent = document.getElementsByClassName("tabcontent");
153 for (i = 1; i < tabcontent.length; i++) {
154 tabcontent[i].style.display = "none";
155 }
156 tabcontent[0].style.display = "block";
157
158 // Get all elements with class="tablinks" and remove the class "active"
159 tablinks = document.getElementsByClassName("tablinks");
160 for (i = 1; i < tablinks.length; i++) {
161 tablinks[i].className = tablinks[i].className.replace(" active", "");
162 }
163 tablinks[0].className += " active";
164
165 }
166 function openTab(evt, tabName) {
167 // Declare all variables
168 var i, tabcontent, tablinks;
169
170 // Get all elements with class="tabcontent" and hide them
171 tabcontent = document.getElementsByClassName("tabcontent");
172 for (i = 0; i < tabcontent.length; i++) {
173 tabcontent[i].style.display = "none";
174 }
175
176 // Get all elements with class="tablinks" and remove the class "active"
177 tablinks = document.getElementsByClassName("tablinks");
178 for (i = 0; i < tablinks.length; i++) {
179 tablinks[i].className = tablinks[i].className.replace(" active", "");
180 }
181
182 // Show the current tab, and add an "active" class to the link that opened the tab
183 document.getElementById(tabName).style.display = "block";
184 evt.currentTarget.className += " active";
185 }
186 </script>
187</head>
188<body onload="init()">
189<div class="tab">
190 <button class="tablinks" onclick="openTab(event, 'mdl_changes')">
191 <div class="node_name">Model changes</div>
192 <div class="smallgreytext">({{ counters['mdl_diff'] }})</div>
193 </button>
194</div>
195<div id="mdl_changes" class="tabcontent">
196 <table class="pkgversions">
197 <tbody>
198 <tr>
199 <td class="Header">Package name</td>
200 <td class="Header">Installed</td>
201 <td class="Header">Candidate</td>
202 </tr>
203 <tr><td colspan=3>Package with different versions uniq for this node</td></tr>
204 <td class="pkgName">class:cluster:param1</td>
205 <td class="version differ">
206 <div class="tooltip">Value1
207 <pre class="tooltiptext">raw text from the diff | linebreaks }}</pre>
208 </div>
209 </td>
210 <td class="version">Value2</td>
211 </tbody>
212 </table>
213</div>
214</body>
215</html>