data-primals-engine 1.5.1 → 1.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +924 -913
- package/client/README.md +136 -136
- package/client/index.js +0 -1
- package/client/public/doc/API.postman_collection.json +213 -213
- package/client/public/react.svg +9 -9
- package/client/src/AddWidgetTypeModal.jsx +47 -47
- package/client/src/App.css +42 -42
- package/client/src/App.jsx +92 -150
- package/client/src/App.scss +7 -1
- package/client/src/AssistantChat.jsx +362 -363
- package/client/src/Button.jsx +12 -12
- package/client/src/Dashboard.jsx +480 -480
- package/client/src/DashboardHtmlViewItem.jsx +146 -146
- package/client/src/DashboardView.jsx +654 -654
- package/client/src/DataEditor.jsx +383 -383
- package/client/src/DataLayout.jsx +779 -806
- package/client/src/DataTable.jsx +782 -822
- package/client/src/DataTable.scss +186 -186
- package/client/src/GeolocationField.jsx +93 -93
- package/client/src/HistoryDialog.jsx +307 -285
- package/client/src/HistoryDialog.scss +319 -319
- package/client/src/HtmlViewBuilderModal.jsx +90 -90
- package/client/src/HtmlViewBuilderModal.scss +17 -17
- package/client/src/HtmlViewCard.jsx +43 -43
- package/client/src/ModelCreatorField.jsx +950 -950
- package/client/src/ModelList.jsx +7 -2
- package/client/src/Notification.jsx +136 -136
- package/client/src/PackGallery.jsx +391 -391
- package/client/src/PackGallery.scss +231 -231
- package/client/src/Pagination.jsx +143 -143
- package/client/src/RelationField.jsx +354 -354
- package/client/src/RelationSelectorWidget.jsx +172 -172
- package/client/src/RelationValue.jsx +2 -1
- package/client/src/contexts/CommandContext.jsx +260 -0
- package/client/src/contexts/ModelContext.jsx +4 -1
- package/client/src/contexts/UIContext.jsx +72 -72
- package/client/src/filter.js +263 -262
- package/client/src/index.css +90 -90
- package/package.json +11 -10
- package/perf/artillery-hooks.js +37 -37
- package/perf/setup.yml +25 -25
- package/src/constants.js +4 -0
- package/src/core.js +8 -1
- package/src/engine.js +335 -293
- package/src/events.js +140 -21
- package/src/filter.js +274 -274
- package/src/index.js +3 -0
- package/src/modules/assistant/assistant.js +323 -192
- package/src/modules/assistant/constants.js +2 -1
- package/src/modules/auth-google/index.js +50 -50
- package/src/modules/auth-microsoft/index.js +81 -81
- package/src/modules/data/data.core.js +118 -118
- package/src/modules/data/data.history.js +555 -531
- package/src/modules/data/data.operations.js +145 -26
- package/src/modules/data/data.relations.js +686 -686
- package/src/modules/data/data.routes.js +1879 -1879
- package/src/modules/data/data.validation.js +2 -2
- package/src/modules/file.js +247 -247
- package/src/modules/user.js +1 -0
- package/src/modules/workflow.js +2 -2
- package/src/openai.jobs.js +3 -2
- package/src/packs.js +2 -2
- package/src/providers.js +2 -2
- package/src/services/stripe.js +196 -196
- package/src/sso.js +193 -193
- package/src/workers/import-export-worker.js +1 -1
- package/test/data.history.integration.test.js +72 -0
- package/test/data.integration.test.js +92 -1
- package/test/events.test.js +108 -10
- package/test/model.integration.test.js +377 -377
|
@@ -1,320 +1,320 @@
|
|
|
1
|
-
.history-dialog {
|
|
2
|
-
|
|
3
|
-
.dialog-content {
|
|
4
|
-
display: flex;
|
|
5
|
-
flex-direction: column;
|
|
6
|
-
height: 100%;
|
|
7
|
-
padding: 0; // Le padding sera sur le content wrapper
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
.history-dialog-content {
|
|
12
|
-
overflow-y: auto;
|
|
13
|
-
padding: 1rem;
|
|
14
|
-
background-color: #f4f4f4;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
.history-list {
|
|
18
|
-
display: flex;
|
|
19
|
-
flex-direction: column;
|
|
20
|
-
gap: 1rem;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.history-entry {
|
|
24
|
-
border: 1px solid #ddd;
|
|
25
|
-
border-radius: 4px;
|
|
26
|
-
background-color: #fff;
|
|
27
|
-
box-shadow: 0 1px 3px rgba(0,0,0,0.05);
|
|
28
|
-
|
|
29
|
-
.history-entry-header {
|
|
30
|
-
display: flex;
|
|
31
|
-
align-items: center;
|
|
32
|
-
gap: 1rem;
|
|
33
|
-
padding: 0.5rem 1rem;
|
|
34
|
-
background-color: #f9f9f9;
|
|
35
|
-
border-bottom: 1px solid #eee;
|
|
36
|
-
font-size: 0.9em;
|
|
37
|
-
color: #333;
|
|
38
|
-
|
|
39
|
-
.op-badge {
|
|
40
|
-
padding: 0.2rem 0.6rem;
|
|
41
|
-
border-radius: 12px;
|
|
42
|
-
color: white;
|
|
43
|
-
font-weight: bold;
|
|
44
|
-
font-size: 0.8em;
|
|
45
|
-
text-transform: uppercase;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
.op-insert { background-color: #28a745; } // green
|
|
49
|
-
.op-update { background-color: #007bff; } // blue
|
|
50
|
-
.op-delete { background-color: #dc3545; } // red
|
|
51
|
-
|
|
52
|
-
.history-version {
|
|
53
|
-
margin-left: auto;
|
|
54
|
-
font-weight: bold;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
.history-entry-data {
|
|
59
|
-
padding: 1rem;
|
|
60
|
-
|
|
61
|
-
pre {
|
|
62
|
-
white-space: pre-wrap;
|
|
63
|
-
word-wrap: break-word;
|
|
64
|
-
background-color: #2d2d2d;
|
|
65
|
-
color: #f8f8f2;
|
|
66
|
-
padding: 1rem;
|
|
67
|
-
border-radius: 4px;
|
|
68
|
-
margin: 0;
|
|
69
|
-
font-family: 'Courier New', Courier, monospace;
|
|
70
|
-
font-size: 0.85em;
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
// In C:/Dev/data-primals-engine/client/src/HistoryDialog.scss
|
|
76
|
-
|
|
77
|
-
.history-dialog .dialog-content {
|
|
78
|
-
// The new layout handles its own padding and structure.
|
|
79
|
-
padding: 0;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
.history-dialog-content-split {
|
|
83
|
-
display: flex;
|
|
84
|
-
gap: 1rem;
|
|
85
|
-
height: 65vh; /* Adjust height as needed */
|
|
86
|
-
max-height: 700px;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
.history-list-container {
|
|
90
|
-
flex: 1;
|
|
91
|
-
overflow-y: auto;
|
|
92
|
-
border-right: 1px solid #e2e2e2;
|
|
93
|
-
padding: 0 1rem 1rem 0;
|
|
94
|
-
min-width: 300px;
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
.history-preview-container {
|
|
98
|
-
flex: 0.8; /* Give preview a bit more space */
|
|
99
|
-
display: flex;
|
|
100
|
-
flex-direction: column;
|
|
101
|
-
min-width: 300px;
|
|
102
|
-
|
|
103
|
-
.preview-header {
|
|
104
|
-
display: flex;
|
|
105
|
-
justify-content: space-between;
|
|
106
|
-
align-items: center;
|
|
107
|
-
margin-bottom: 0.5rem;
|
|
108
|
-
padding-bottom: 0.5rem;
|
|
109
|
-
border-bottom: 1px solid #e2e2e2;
|
|
110
|
-
|
|
111
|
-
h4 {
|
|
112
|
-
margin: 0;
|
|
113
|
-
padding: 0;
|
|
114
|
-
border: none;
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
.btn-revert {
|
|
118
|
-
padding: 0.3rem 0.8rem;
|
|
119
|
-
font-size: 0.85em;
|
|
120
|
-
background-color: #ffc107; // A warning color like amber
|
|
121
|
-
color: black;
|
|
122
|
-
border: 1px solid #e0a800;
|
|
123
|
-
|
|
124
|
-
&:hover:not(:disabled) {
|
|
125
|
-
background-color: #e0a800;
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
&:disabled {
|
|
129
|
-
background-color: #ffca2c;
|
|
130
|
-
opacity: 0.7;
|
|
131
|
-
cursor: not-allowed;
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
.history-preview-area {
|
|
138
|
-
flex-grow: 1;
|
|
139
|
-
overflow-y: auto;
|
|
140
|
-
background-color: #f9f9f9;
|
|
141
|
-
padding: 0.75rem;
|
|
142
|
-
border: 1px solid #ddd;
|
|
143
|
-
border-radius: 4px;
|
|
144
|
-
|
|
145
|
-
pre {
|
|
146
|
-
white-space: pre-wrap;
|
|
147
|
-
word-wrap: break-word;
|
|
148
|
-
margin: 0;
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
.placeholder {
|
|
152
|
-
color: #666;
|
|
153
|
-
display: flex;
|
|
154
|
-
align-items: center;
|
|
155
|
-
justify-content: center;
|
|
156
|
-
height: 100%;
|
|
157
|
-
text-align: center;
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
.history-entry {
|
|
162
|
-
border: 1px solid #ddd;
|
|
163
|
-
border-radius: 4px;
|
|
164
|
-
margin-bottom: 0.75rem;
|
|
165
|
-
padding: 0.75rem;
|
|
166
|
-
transition: border-color 0.2s, box-shadow 0.2s;
|
|
167
|
-
|
|
168
|
-
&.selected {
|
|
169
|
-
border-color: #007bff;
|
|
170
|
-
box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
|
|
171
|
-
}
|
|
172
|
-
}
|
|
173
|
-
|
|
174
|
-
.history-entry-header {
|
|
175
|
-
display: flex;
|
|
176
|
-
align-items: center;
|
|
177
|
-
flex-wrap: wrap;
|
|
178
|
-
gap: 0.5rem 1rem;
|
|
179
|
-
margin-bottom: 0.5rem;
|
|
180
|
-
|
|
181
|
-
.btn-preview {
|
|
182
|
-
margin-left: auto;
|
|
183
|
-
padding: 0.2rem 0.6rem;
|
|
184
|
-
font-size: 0.8em;
|
|
185
|
-
}
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
.history-entry-data pre {
|
|
189
|
-
background-color: #f0f0f0;
|
|
190
|
-
padding: 0.5rem;
|
|
191
|
-
border-radius: 4px;
|
|
192
|
-
max-height: 150px;
|
|
193
|
-
overflow-y: auto;
|
|
194
|
-
margin: 0;
|
|
195
|
-
}
|
|
196
|
-
|
|
197
|
-
/* Dark Theme Adjustments */
|
|
198
|
-
.dark .history-list-container { border-right-color: #3f3f3f;
|
|
199
|
-
}
|
|
200
|
-
.dark .history-preview-container .preview-header {
|
|
201
|
-
border-bottom-color: #3f3f3f;
|
|
202
|
-
.btn-revert {
|
|
203
|
-
background-color: #d8a100;
|
|
204
|
-
border-color: #b38600;
|
|
205
|
-
color: white;
|
|
206
|
-
&:hover:not(:disabled) {
|
|
207
|
-
background-color: #b38600;
|
|
208
|
-
}
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
.dark .history-preview-area { background-color: #2a2a2a; border-color: #3f3f3f; }
|
|
212
|
-
.dark .history-entry { border-color: #3f3f3f; }
|
|
213
|
-
.dark .history-entry.selected { border-color: #58a6ff; box-shadow: 0 0 0 2px rgba(88, 166, 255, 0.25); }
|
|
214
|
-
.dark .history-entry-data pre { background-color: #2a2a2a; }
|
|
215
|
-
|
|
216
|
-
/* Styles for human-friendly history data display */
|
|
217
|
-
.history-entry-data {
|
|
218
|
-
padding: 0.75rem 1rem;
|
|
219
|
-
font-size: 0.9em;
|
|
220
|
-
background-color: #fdfdfd;
|
|
221
|
-
border-top: 1px solid #f0f0f0;
|
|
222
|
-
|
|
223
|
-
/* The new implementation doesn't use <pre> here anymore */
|
|
224
|
-
pre {
|
|
225
|
-
display: none;
|
|
226
|
-
}
|
|
227
|
-
}
|
|
228
|
-
|
|
229
|
-
.changes-list, .snapshot-list {
|
|
230
|
-
display: flex;
|
|
231
|
-
flex-direction: column;
|
|
232
|
-
gap: 0.5rem;
|
|
233
|
-
}
|
|
234
|
-
|
|
235
|
-
.change-detail, .snapshot-item {
|
|
236
|
-
display: grid;
|
|
237
|
-
grid-template-columns: minmax(100px, 150px) 1fr;
|
|
238
|
-
gap: 0.5rem;
|
|
239
|
-
align-items: start;
|
|
240
|
-
}
|
|
241
|
-
|
|
242
|
-
.change-field-name, .snapshot-key {
|
|
243
|
-
font-weight: 600;
|
|
244
|
-
color: #333;
|
|
245
|
-
white-space: nowrap;
|
|
246
|
-
overflow: hidden;
|
|
247
|
-
text-overflow: ellipsis;
|
|
248
|
-
padding-top: 4px; /* Align with value */
|
|
249
|
-
}
|
|
250
|
-
|
|
251
|
-
.change-values {
|
|
252
|
-
display: flex;
|
|
253
|
-
align-items: center;
|
|
254
|
-
gap: 0.5rem;
|
|
255
|
-
background-color: #f0f0f0;
|
|
256
|
-
padding: 0.25rem 0.5rem;
|
|
257
|
-
border-radius: 4px;
|
|
258
|
-
overflow: hidden;
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
.change-arrow {
|
|
262
|
-
color: #888;
|
|
263
|
-
font-weight: bold;
|
|
264
|
-
}
|
|
265
|
-
|
|
266
|
-
.value-from {
|
|
267
|
-
text-decoration: line-through;
|
|
268
|
-
color: #d9534f; /* red-ish */
|
|
269
|
-
}
|
|
270
|
-
|
|
271
|
-
.value-to {
|
|
272
|
-
color: #5cb85c; /* green-ish */
|
|
273
|
-
font-weight: 500;
|
|
274
|
-
}
|
|
275
|
-
|
|
276
|
-
.snapshot-value, .value-from, .value-to {
|
|
277
|
-
white-space: nowrap;
|
|
278
|
-
overflow: hidden;
|
|
279
|
-
text-overflow: ellipsis;
|
|
280
|
-
display: block; /* Ensure it takes up the block for ellipsis */
|
|
281
|
-
}
|
|
282
|
-
|
|
283
|
-
.value-empty {
|
|
284
|
-
color: #999;
|
|
285
|
-
font-style: italic;
|
|
286
|
-
}
|
|
287
|
-
|
|
288
|
-
.value-object, .value-boolean {
|
|
289
|
-
font-family: 'Courier New', Courier, monospace;
|
|
290
|
-
background-color: #e9e9e9;
|
|
291
|
-
padding: 0.1rem 0.3rem;
|
|
292
|
-
border-radius: 3px;
|
|
293
|
-
display: inline-block;
|
|
294
|
-
}
|
|
295
|
-
|
|
296
|
-
.no-changes-text {
|
|
297
|
-
color: #777;
|
|
298
|
-
font-style: italic;
|
|
299
|
-
padding: 0.5rem 0;
|
|
300
|
-
}
|
|
301
|
-
|
|
302
|
-
/* Dark Theme Adjustments */
|
|
303
|
-
.dark .history-entry-data {
|
|
304
|
-
background-color: #2c2c2c;
|
|
305
|
-
border-top-color: #3a3a3a;
|
|
306
|
-
}
|
|
307
|
-
.dark .change-field-name, .dark .snapshot-key {
|
|
308
|
-
color: #e0e0e0;
|
|
309
|
-
}
|
|
310
|
-
.dark .change-values {
|
|
311
|
-
background-color: #3a3a3a;
|
|
312
|
-
}
|
|
313
|
-
.dark .value-from { color: #ff7b7b; }
|
|
314
|
-
.dark .value-to { color: #73d173; }
|
|
315
|
-
.dark .value-object, .dark .value-boolean {
|
|
316
|
-
background-color: #444;
|
|
317
|
-
}
|
|
318
|
-
.dark .no-changes-text, .dark .value-empty {
|
|
319
|
-
color: #888;
|
|
1
|
+
.history-dialog {
|
|
2
|
+
|
|
3
|
+
.dialog-content {
|
|
4
|
+
display: flex;
|
|
5
|
+
flex-direction: column;
|
|
6
|
+
height: 100%;
|
|
7
|
+
padding: 0; // Le padding sera sur le content wrapper
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.history-dialog-content {
|
|
12
|
+
overflow-y: auto;
|
|
13
|
+
padding: 1rem;
|
|
14
|
+
background-color: #f4f4f4;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.history-list {
|
|
18
|
+
display: flex;
|
|
19
|
+
flex-direction: column;
|
|
20
|
+
gap: 1rem;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.history-entry {
|
|
24
|
+
border: 1px solid #ddd;
|
|
25
|
+
border-radius: 4px;
|
|
26
|
+
background-color: #fff;
|
|
27
|
+
box-shadow: 0 1px 3px rgba(0,0,0,0.05);
|
|
28
|
+
|
|
29
|
+
.history-entry-header {
|
|
30
|
+
display: flex;
|
|
31
|
+
align-items: center;
|
|
32
|
+
gap: 1rem;
|
|
33
|
+
padding: 0.5rem 1rem;
|
|
34
|
+
background-color: #f9f9f9;
|
|
35
|
+
border-bottom: 1px solid #eee;
|
|
36
|
+
font-size: 0.9em;
|
|
37
|
+
color: #333;
|
|
38
|
+
|
|
39
|
+
.op-badge {
|
|
40
|
+
padding: 0.2rem 0.6rem;
|
|
41
|
+
border-radius: 12px;
|
|
42
|
+
color: white;
|
|
43
|
+
font-weight: bold;
|
|
44
|
+
font-size: 0.8em;
|
|
45
|
+
text-transform: uppercase;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.op-insert { background-color: #28a745; } // green
|
|
49
|
+
.op-update { background-color: #007bff; } // blue
|
|
50
|
+
.op-delete { background-color: #dc3545; } // red
|
|
51
|
+
|
|
52
|
+
.history-version {
|
|
53
|
+
margin-left: auto;
|
|
54
|
+
font-weight: bold;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.history-entry-data {
|
|
59
|
+
padding: 1rem;
|
|
60
|
+
|
|
61
|
+
pre {
|
|
62
|
+
white-space: pre-wrap;
|
|
63
|
+
word-wrap: break-word;
|
|
64
|
+
background-color: #2d2d2d;
|
|
65
|
+
color: #f8f8f2;
|
|
66
|
+
padding: 1rem;
|
|
67
|
+
border-radius: 4px;
|
|
68
|
+
margin: 0;
|
|
69
|
+
font-family: 'Courier New', Courier, monospace;
|
|
70
|
+
font-size: 0.85em;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
// In C:/Dev/data-primals-engine/client/src/HistoryDialog.scss
|
|
76
|
+
|
|
77
|
+
.history-dialog .dialog-content {
|
|
78
|
+
// The new layout handles its own padding and structure.
|
|
79
|
+
padding: 0;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.history-dialog-content-split {
|
|
83
|
+
display: flex;
|
|
84
|
+
gap: 1rem;
|
|
85
|
+
height: 65vh; /* Adjust height as needed */
|
|
86
|
+
max-height: 700px;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.history-list-container {
|
|
90
|
+
flex: 1;
|
|
91
|
+
overflow-y: auto;
|
|
92
|
+
border-right: 1px solid #e2e2e2;
|
|
93
|
+
padding: 0 1rem 1rem 0;
|
|
94
|
+
min-width: 300px;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
.history-preview-container {
|
|
98
|
+
flex: 0.8; /* Give preview a bit more space */
|
|
99
|
+
display: flex;
|
|
100
|
+
flex-direction: column;
|
|
101
|
+
min-width: 300px;
|
|
102
|
+
|
|
103
|
+
.preview-header {
|
|
104
|
+
display: flex;
|
|
105
|
+
justify-content: space-between;
|
|
106
|
+
align-items: center;
|
|
107
|
+
margin-bottom: 0.5rem;
|
|
108
|
+
padding-bottom: 0.5rem;
|
|
109
|
+
border-bottom: 1px solid #e2e2e2;
|
|
110
|
+
|
|
111
|
+
h4 {
|
|
112
|
+
margin: 0;
|
|
113
|
+
padding: 0;
|
|
114
|
+
border: none;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.btn-revert {
|
|
118
|
+
padding: 0.3rem 0.8rem;
|
|
119
|
+
font-size: 0.85em;
|
|
120
|
+
background-color: #ffc107; // A warning color like amber
|
|
121
|
+
color: black;
|
|
122
|
+
border: 1px solid #e0a800;
|
|
123
|
+
|
|
124
|
+
&:hover:not(:disabled) {
|
|
125
|
+
background-color: #e0a800;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
&:disabled {
|
|
129
|
+
background-color: #ffca2c;
|
|
130
|
+
opacity: 0.7;
|
|
131
|
+
cursor: not-allowed;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.history-preview-area {
|
|
138
|
+
flex-grow: 1;
|
|
139
|
+
overflow-y: auto;
|
|
140
|
+
background-color: #f9f9f9;
|
|
141
|
+
padding: 0.75rem;
|
|
142
|
+
border: 1px solid #ddd;
|
|
143
|
+
border-radius: 4px;
|
|
144
|
+
|
|
145
|
+
pre {
|
|
146
|
+
white-space: pre-wrap;
|
|
147
|
+
word-wrap: break-word;
|
|
148
|
+
margin: 0;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.placeholder {
|
|
152
|
+
color: #666;
|
|
153
|
+
display: flex;
|
|
154
|
+
align-items: center;
|
|
155
|
+
justify-content: center;
|
|
156
|
+
height: 100%;
|
|
157
|
+
text-align: center;
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.history-entry {
|
|
162
|
+
border: 1px solid #ddd;
|
|
163
|
+
border-radius: 4px;
|
|
164
|
+
margin-bottom: 0.75rem;
|
|
165
|
+
padding: 0.75rem;
|
|
166
|
+
transition: border-color 0.2s, box-shadow 0.2s;
|
|
167
|
+
|
|
168
|
+
&.selected {
|
|
169
|
+
border-color: #007bff;
|
|
170
|
+
box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.history-entry-header {
|
|
175
|
+
display: flex;
|
|
176
|
+
align-items: center;
|
|
177
|
+
flex-wrap: wrap;
|
|
178
|
+
gap: 0.5rem 1rem;
|
|
179
|
+
margin-bottom: 0.5rem;
|
|
180
|
+
|
|
181
|
+
.btn-preview {
|
|
182
|
+
margin-left: auto;
|
|
183
|
+
padding: 0.2rem 0.6rem;
|
|
184
|
+
font-size: 0.8em;
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
.history-entry-data pre {
|
|
189
|
+
background-color: #f0f0f0;
|
|
190
|
+
padding: 0.5rem;
|
|
191
|
+
border-radius: 4px;
|
|
192
|
+
max-height: 150px;
|
|
193
|
+
overflow-y: auto;
|
|
194
|
+
margin: 0;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
/* Dark Theme Adjustments */
|
|
198
|
+
.dark .history-list-container { border-right-color: #3f3f3f;
|
|
199
|
+
}
|
|
200
|
+
.dark .history-preview-container .preview-header {
|
|
201
|
+
border-bottom-color: #3f3f3f;
|
|
202
|
+
.btn-revert {
|
|
203
|
+
background-color: #d8a100;
|
|
204
|
+
border-color: #b38600;
|
|
205
|
+
color: white;
|
|
206
|
+
&:hover:not(:disabled) {
|
|
207
|
+
background-color: #b38600;
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
.dark .history-preview-area { background-color: #2a2a2a; border-color: #3f3f3f; }
|
|
212
|
+
.dark .history-entry { border-color: #3f3f3f; }
|
|
213
|
+
.dark .history-entry.selected { border-color: #58a6ff; box-shadow: 0 0 0 2px rgba(88, 166, 255, 0.25); }
|
|
214
|
+
.dark .history-entry-data pre { background-color: #2a2a2a; }
|
|
215
|
+
|
|
216
|
+
/* Styles for human-friendly history data display */
|
|
217
|
+
.history-entry-data {
|
|
218
|
+
padding: 0.75rem 1rem;
|
|
219
|
+
font-size: 0.9em;
|
|
220
|
+
background-color: #fdfdfd;
|
|
221
|
+
border-top: 1px solid #f0f0f0;
|
|
222
|
+
|
|
223
|
+
/* The new implementation doesn't use <pre> here anymore */
|
|
224
|
+
pre {
|
|
225
|
+
display: none;
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
.changes-list, .snapshot-list {
|
|
230
|
+
display: flex;
|
|
231
|
+
flex-direction: column;
|
|
232
|
+
gap: 0.5rem;
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
.change-detail, .snapshot-item {
|
|
236
|
+
display: grid;
|
|
237
|
+
grid-template-columns: minmax(100px, 150px) 1fr;
|
|
238
|
+
gap: 0.5rem;
|
|
239
|
+
align-items: start;
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
.change-field-name, .snapshot-key {
|
|
243
|
+
font-weight: 600;
|
|
244
|
+
color: #333;
|
|
245
|
+
white-space: nowrap;
|
|
246
|
+
overflow: hidden;
|
|
247
|
+
text-overflow: ellipsis;
|
|
248
|
+
padding-top: 4px; /* Align with value */
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
.change-values {
|
|
252
|
+
display: flex;
|
|
253
|
+
align-items: center;
|
|
254
|
+
gap: 0.5rem;
|
|
255
|
+
background-color: #f0f0f0;
|
|
256
|
+
padding: 0.25rem 0.5rem;
|
|
257
|
+
border-radius: 4px;
|
|
258
|
+
overflow: hidden;
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
.change-arrow {
|
|
262
|
+
color: #888;
|
|
263
|
+
font-weight: bold;
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
.value-from {
|
|
267
|
+
text-decoration: line-through;
|
|
268
|
+
color: #d9534f; /* red-ish */
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
.value-to {
|
|
272
|
+
color: #5cb85c; /* green-ish */
|
|
273
|
+
font-weight: 500;
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
.snapshot-value, .value-from, .value-to {
|
|
277
|
+
white-space: nowrap;
|
|
278
|
+
overflow: hidden;
|
|
279
|
+
text-overflow: ellipsis;
|
|
280
|
+
display: block; /* Ensure it takes up the block for ellipsis */
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
.value-empty {
|
|
284
|
+
color: #999;
|
|
285
|
+
font-style: italic;
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
.value-object, .value-boolean {
|
|
289
|
+
font-family: 'Courier New', Courier, monospace;
|
|
290
|
+
background-color: #e9e9e9;
|
|
291
|
+
padding: 0.1rem 0.3rem;
|
|
292
|
+
border-radius: 3px;
|
|
293
|
+
display: inline-block;
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
.no-changes-text {
|
|
297
|
+
color: #777;
|
|
298
|
+
font-style: italic;
|
|
299
|
+
padding: 0.5rem 0;
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
/* Dark Theme Adjustments */
|
|
303
|
+
.dark .history-entry-data {
|
|
304
|
+
background-color: #2c2c2c;
|
|
305
|
+
border-top-color: #3a3a3a;
|
|
306
|
+
}
|
|
307
|
+
.dark .change-field-name, .dark .snapshot-key {
|
|
308
|
+
color: #e0e0e0;
|
|
309
|
+
}
|
|
310
|
+
.dark .change-values {
|
|
311
|
+
background-color: #3a3a3a;
|
|
312
|
+
}
|
|
313
|
+
.dark .value-from { color: #ff7b7b; }
|
|
314
|
+
.dark .value-to { color: #73d173; }
|
|
315
|
+
.dark .value-object, .dark .value-boolean {
|
|
316
|
+
background-color: #444;
|
|
317
|
+
}
|
|
318
|
+
.dark .no-changes-text, .dark .value-empty {
|
|
319
|
+
color: #888;
|
|
320
320
|
}
|