@design.estate/dees-catalog 3.35.1 → 3.37.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/dist_bundle/bundle.js +1391 -247
- package/dist_ts_web/00_commitinfo_data.js +1 -1
- package/dist_ts_web/elements/00group-button/dees-button/dees-button.d.ts +6 -0
- package/dist_ts_web/elements/00group-button/dees-button/dees-button.demo.js +69 -29
- package/dist_ts_web/elements/00group-button/dees-button/dees-button.js +75 -6
- package/dist_ts_web/elements/00group-chart/dees-chart-log/dees-chart-log.d.ts +104 -6
- package/dist_ts_web/elements/00group-chart/dees-chart-log/dees-chart-log.demo.js +153 -54
- package/dist_ts_web/elements/00group-chart/dees-chart-log/dees-chart-log.js +716 -153
- package/dist_ts_web/elements/dees-statsgrid/dees-statsgrid.d.ts +22 -1
- package/dist_ts_web/elements/dees-statsgrid/dees-statsgrid.demo.js +130 -2
- package/dist_ts_web/elements/dees-statsgrid/dees-statsgrid.js +322 -1
- package/dist_ts_web/services/DeesServiceLibLoader.d.ts +34 -1
- package/dist_ts_web/services/DeesServiceLibLoader.js +27 -1
- package/dist_ts_web/services/index.d.ts +1 -1
- package/dist_ts_web/services/versions.d.ts +1 -0
- package/dist_ts_web/services/versions.js +2 -1
- package/dist_watch/bundle.js +1389 -245
- package/dist_watch/bundle.js.map +3 -3
- package/package.json +1 -1
- package/ts_web/00_commitinfo_data.ts +1 -1
- package/ts_web/elements/00group-button/dees-button/dees-button.demo.ts +68 -28
- package/ts_web/elements/00group-button/dees-button/dees-button.ts +78 -6
- package/ts_web/elements/00group-chart/dees-chart-log/dees-chart-log.demo.ts +163 -56
- package/ts_web/elements/00group-chart/dees-chart-log/dees-chart-log.ts +756 -161
- package/ts_web/elements/dees-statsgrid/dees-statsgrid.demo.ts +130 -2
- package/ts_web/elements/dees-statsgrid/dees-statsgrid.ts +352 -1
- package/ts_web/services/DeesServiceLibLoader.ts +50 -1
- package/ts_web/services/index.ts +1 -1
- package/ts_web/services/versions.ts +1 -0
package/dist_watch/bundle.js
CHANGED
|
@@ -53587,26 +53587,26 @@ var init_fontawesome_svg_core = __esm({
|
|
|
53587
53587
|
}
|
|
53588
53588
|
};
|
|
53589
53589
|
parse7 = {
|
|
53590
|
-
icon: function icon(
|
|
53591
|
-
if (
|
|
53590
|
+
icon: function icon(_icon3) {
|
|
53591
|
+
if (_icon3 === null) {
|
|
53592
53592
|
return null;
|
|
53593
53593
|
}
|
|
53594
|
-
if (_typeof(
|
|
53594
|
+
if (_typeof(_icon3) === "object" && _icon3.prefix && _icon3.iconName) {
|
|
53595
53595
|
return {
|
|
53596
|
-
prefix:
|
|
53597
|
-
iconName: byAlias(
|
|
53596
|
+
prefix: _icon3.prefix,
|
|
53597
|
+
iconName: byAlias(_icon3.prefix, _icon3.iconName) || _icon3.iconName
|
|
53598
53598
|
};
|
|
53599
53599
|
}
|
|
53600
|
-
if (Array.isArray(
|
|
53601
|
-
var iconName =
|
|
53602
|
-
var prefix4 = getCanonicalPrefix(
|
|
53600
|
+
if (Array.isArray(_icon3) && _icon3.length === 2) {
|
|
53601
|
+
var iconName = _icon3[1].indexOf("fa-") === 0 ? _icon3[1].slice(3) : _icon3[1];
|
|
53602
|
+
var prefix4 = getCanonicalPrefix(_icon3[0]);
|
|
53603
53603
|
return {
|
|
53604
53604
|
prefix: prefix4,
|
|
53605
53605
|
iconName: byAlias(prefix4, iconName) || iconName
|
|
53606
53606
|
};
|
|
53607
53607
|
}
|
|
53608
|
-
if (typeof
|
|
53609
|
-
var canonicalIcon = getCanonicalIcon(
|
|
53608
|
+
if (typeof _icon3 === "string" && (_icon3.indexOf("".concat(config2.cssPrefix, "-")) > -1 || _icon3.match(ICON_SELECTION_SYNTAX_PATTERN))) {
|
|
53609
|
+
var canonicalIcon = getCanonicalIcon(_icon3.split(" "), {
|
|
53610
53610
|
skipLookups: true
|
|
53611
53611
|
});
|
|
53612
53612
|
return {
|
|
@@ -53614,11 +53614,11 @@ var init_fontawesome_svg_core = __esm({
|
|
|
53614
53614
|
iconName: byAlias(canonicalIcon.prefix, canonicalIcon.iconName) || canonicalIcon.iconName
|
|
53615
53615
|
};
|
|
53616
53616
|
}
|
|
53617
|
-
if (typeof
|
|
53617
|
+
if (typeof _icon3 === "string") {
|
|
53618
53618
|
var _prefix = getDefaultUsablePrefix();
|
|
53619
53619
|
return {
|
|
53620
53620
|
prefix: _prefix,
|
|
53621
|
-
iconName: byAlias(_prefix,
|
|
53621
|
+
iconName: byAlias(_prefix, _icon3) || _icon3
|
|
53622
53622
|
};
|
|
53623
53623
|
}
|
|
53624
53624
|
}
|
|
@@ -101154,6 +101154,7 @@ var init_versions = __esm({
|
|
|
101154
101154
|
CDN_VERSIONS = {
|
|
101155
101155
|
xterm: "5.3.0",
|
|
101156
101156
|
xtermAddonFit: "0.8.0",
|
|
101157
|
+
xtermAddonSearch: "0.13.0",
|
|
101157
101158
|
highlightJs: "11.11.1",
|
|
101158
101159
|
apexcharts: "5.3.6",
|
|
101159
101160
|
tiptap: "2.23.0",
|
|
@@ -101173,12 +101174,14 @@ var init_DeesServiceLibLoader = __esm({
|
|
|
101173
101174
|
// Cached library references
|
|
101174
101175
|
xtermLib = null;
|
|
101175
101176
|
xtermFitAddonLib = null;
|
|
101177
|
+
xtermSearchAddonLib = null;
|
|
101176
101178
|
highlightJsLib = null;
|
|
101177
101179
|
apexChartsLib = null;
|
|
101178
101180
|
tiptapLib = null;
|
|
101179
101181
|
// Loading promises to prevent duplicate concurrent loads
|
|
101180
101182
|
xtermLoadingPromise = null;
|
|
101181
101183
|
xtermFitAddonLoadingPromise = null;
|
|
101184
|
+
xtermSearchAddonLoadingPromise = null;
|
|
101182
101185
|
highlightJsLoadingPromise = null;
|
|
101183
101186
|
apexChartsLoadingPromise = null;
|
|
101184
101187
|
tiptapLoadingPromise = null;
|
|
@@ -101242,6 +101245,30 @@ var init_DeesServiceLibLoader = __esm({
|
|
|
101242
101245
|
})();
|
|
101243
101246
|
return this.xtermFitAddonLoadingPromise;
|
|
101244
101247
|
}
|
|
101248
|
+
/**
|
|
101249
|
+
* Load xterm-addon-search from CDN
|
|
101250
|
+
* @returns Promise resolving to SearchAddon class
|
|
101251
|
+
*/
|
|
101252
|
+
async loadXtermSearchAddon() {
|
|
101253
|
+
if (this.xtermSearchAddonLib) {
|
|
101254
|
+
return this.xtermSearchAddonLib;
|
|
101255
|
+
}
|
|
101256
|
+
if (this.xtermSearchAddonLoadingPromise) {
|
|
101257
|
+
return this.xtermSearchAddonLoadingPromise;
|
|
101258
|
+
}
|
|
101259
|
+
this.xtermSearchAddonLoadingPromise = (async () => {
|
|
101260
|
+
const url = `${CDN_BASE}/xterm-addon-search@${CDN_VERSIONS.xtermAddonSearch}/+esm`;
|
|
101261
|
+
const module = await import(
|
|
101262
|
+
/* @vite-ignore */
|
|
101263
|
+
url
|
|
101264
|
+
);
|
|
101265
|
+
this.xtermSearchAddonLib = {
|
|
101266
|
+
SearchAddon: module.SearchAddon
|
|
101267
|
+
};
|
|
101268
|
+
return this.xtermSearchAddonLib;
|
|
101269
|
+
})();
|
|
101270
|
+
return this.xtermSearchAddonLoadingPromise;
|
|
101271
|
+
}
|
|
101245
101272
|
/**
|
|
101246
101273
|
* Inject xterm CSS styles into the document head
|
|
101247
101274
|
*/
|
|
@@ -101368,6 +101395,7 @@ var init_DeesServiceLibLoader = __esm({
|
|
|
101368
101395
|
await Promise.all([
|
|
101369
101396
|
this.loadXterm(),
|
|
101370
101397
|
this.loadXtermFitAddon(),
|
|
101398
|
+
this.loadXtermSearchAddon(),
|
|
101371
101399
|
this.loadHighlightJs(),
|
|
101372
101400
|
this.loadApexCharts(),
|
|
101373
101401
|
this.loadTiptap()
|
|
@@ -101382,6 +101410,8 @@ var init_DeesServiceLibLoader = __esm({
|
|
|
101382
101410
|
return this.xtermLib !== null;
|
|
101383
101411
|
case "xtermFitAddon":
|
|
101384
101412
|
return this.xtermFitAddonLib !== null;
|
|
101413
|
+
case "xtermSearchAddon":
|
|
101414
|
+
return this.xtermSearchAddonLib !== null;
|
|
101385
101415
|
case "highlightJs":
|
|
101386
101416
|
return this.highlightJsLib !== null;
|
|
101387
101417
|
case "apexCharts":
|
|
@@ -113546,7 +113576,49 @@ var generateCpuCores = (count2) => {
|
|
|
113546
113576
|
}));
|
|
113547
113577
|
};
|
|
113548
113578
|
var demoFunc7 = () => {
|
|
113549
|
-
return b2(_a11 || (_a11 = __template(["\n <dees-demowrapper>\n <style>\n ", '\n </style>\n \n <div class="demo-container">\n <dees-panel .title=', " .subtitle=", ">\n <dees-statsgrid\n .tiles=", "\n .gridActions=", "\n .minTileWidth=", "\n .gap=", '\n ></dees-statsgrid>\n \n <div id="action-output" style="margin-top: 16px; padding: 12px; background: ', "; border-radius: 6px; font-size: 14px; font-family: monospace; color: ", ';">\n <em>Click on tile actions or grid actions to see the result...</em>\n </div>\n </dees-panel>\n \n <dees-panel .title=', " .subtitle=", ">\n <dees-statsgrid\n .tiles=", "\n .minTileWidth=", "\n .gap=", '\n ></dees-statsgrid>\n \n <div class="tile-config">\n <div class="config-section">\n <div class="config-title">Configuration Options</div>\n <div class="config-description">\n Each tile type supports different properties:\n <ul style="margin: 8px 0; padding-left: 20px;">\n <li><strong>Number:</strong> value, unit, color, description</li>\n <li><strong>Gauge:</strong> value, unit, gaugeOptions (min, max, thresholds)</li>\n <li><strong>Percentage:</strong> value (0-100), color, description</li>\n <li><strong>Trend:</strong> value, unit, trendData array, description</li>\n <li><strong>Text:</strong> value (string), color, description</li>\n </ul>\n </div>\n </div>\n </div>\n </dees-panel>\n \n <dees-panel .title=', " .subtitle=", '>\n <h4 style="margin: 0 0 16px 0; font-size: 16px; font-weight: 600;">Compact Layout (180px tiles)</h4>\n <dees-statsgrid\n .tiles=', "\n .minTileWidth=", "\n .gap=", '\n ></dees-statsgrid>\n \n <h4 style="margin: 24px 0 16px 0; font-size: 16px; font-weight: 600;">Spacious Layout (320px tiles)</h4>\n <dees-statsgrid\n .tiles=', "\n .minTileWidth=", "\n .gap=", "\n ></dees-statsgrid>\n </dees-panel>\n \n <dees-panel .title=", " .subtitle=", '>\n <dees-statsgrid\n id="cpu-cores-grid"\n .tiles=', "\n .gridActions=", "\n .minTileWidth=", "\n .gap=", "\n ></dees-statsgrid>\n </dees-panel>\n\n <dees-panel .title=", " .subtitle=", '>\n <dees-statsgrid\n id="interactive-grid"\n .tiles=', "\n .gridActions=", "\n .minTileWidth=", "\n .gap=", "\n ></dees-statsgrid>\n </dees-panel>\n \n <dees-panel .title=", " .subtitle=", '>\n <div class="code-block">', "</div>\n </dees-panel>\n
|
|
113579
|
+
return b2(_a11 || (_a11 = __template(["\n <dees-demowrapper>\n <style>\n ", '\n </style>\n \n <div class="demo-container">\n <dees-panel .title=', " .subtitle=", ">\n <dees-statsgrid\n .tiles=", "\n .gridActions=", "\n .minTileWidth=", "\n .gap=", '\n ></dees-statsgrid>\n \n <div id="action-output" style="margin-top: 16px; padding: 12px; background: ', "; border-radius: 6px; font-size: 14px; font-family: monospace; color: ", ';">\n <em>Click on tile actions or grid actions to see the result...</em>\n </div>\n </dees-panel>\n \n <dees-panel .title=', " .subtitle=", ">\n <dees-statsgrid\n .tiles=", "\n .minTileWidth=", "\n .gap=", '\n ></dees-statsgrid>\n \n <div class="tile-config">\n <div class="config-section">\n <div class="config-title">Configuration Options</div>\n <div class="config-description">\n Each tile type supports different properties:\n <ul style="margin: 8px 0; padding-left: 20px;">\n <li><strong>Number:</strong> value, unit, color, description</li>\n <li><strong>Gauge:</strong> value, unit, gaugeOptions (min, max, thresholds)</li>\n <li><strong>Percentage:</strong> value (0-100), color, description</li>\n <li><strong>Trend:</strong> value, unit, trendData array, description</li>\n <li><strong>Text:</strong> value (string), color, description</li>\n </ul>\n </div>\n </div>\n </div>\n </dees-panel>\n \n <dees-panel .title=', " .subtitle=", '>\n <h4 style="margin: 0 0 16px 0; font-size: 16px; font-weight: 600;">Compact Layout (180px tiles)</h4>\n <dees-statsgrid\n .tiles=', "\n .minTileWidth=", "\n .gap=", '\n ></dees-statsgrid>\n \n <h4 style="margin: 24px 0 16px 0; font-size: 16px; font-weight: 600;">Spacious Layout (320px tiles)</h4>\n <dees-statsgrid\n .tiles=', "\n .minTileWidth=", "\n .gap=", "\n ></dees-statsgrid>\n </dees-panel>\n \n <dees-panel .title=", " .subtitle=", '>\n <dees-statsgrid\n id="cpu-cores-grid"\n .tiles=', "\n .gridActions=", "\n .minTileWidth=", "\n .gap=", "\n ></dees-statsgrid>\n </dees-panel>\n\n <dees-panel .title=", " .subtitle=", '>\n <dees-statsgrid\n id="interactive-grid"\n .tiles=', "\n .gridActions=", "\n .minTileWidth=", "\n .gap=", "\n ></dees-statsgrid>\n </dees-panel>\n \n <dees-panel .title=", " .subtitle=", '>\n <div class="code-block">', "</div>\n </dees-panel>\n\n <dees-panel .title=", " .subtitle=", ">\n <dees-statsgrid\n .tiles=", "\n .minTileWidth=", "\n .gap=", `
|
|
113580
|
+
></dees-statsgrid>
|
|
113581
|
+
|
|
113582
|
+
<div class="tile-config">
|
|
113583
|
+
<div class="config-section">
|
|
113584
|
+
<div class="config-title">Partition Tile Properties</div>
|
|
113585
|
+
<div class="config-description">
|
|
113586
|
+
<ul style="margin: 8px 0; padding-left: 20px;">
|
|
113587
|
+
<li><strong>partitionData.used:</strong> Used space in bytes (auto-formatted)</li>
|
|
113588
|
+
<li><strong>partitionData.total:</strong> Total capacity in bytes</li>
|
|
113589
|
+
<li><strong>partitionData.filesystem:</strong> Filesystem type (ext4, xfs, ntfs)</li>
|
|
113590
|
+
<li><strong>partitionData.mountPoint:</strong> Mount point path (optional)</li>
|
|
113591
|
+
</ul>
|
|
113592
|
+
Color thresholds: Normal (<75%), Warning (75-90%), Critical (>90%)
|
|
113593
|
+
</div>
|
|
113594
|
+
</div>
|
|
113595
|
+
<div class="config-section">
|
|
113596
|
+
<div class="config-title">Disk Tile Properties</div>
|
|
113597
|
+
<div class="config-description">
|
|
113598
|
+
<ul style="margin: 8px 0; padding-left: 20px;">
|
|
113599
|
+
<li><strong>diskData.capacity:</strong> Total capacity in bytes</li>
|
|
113600
|
+
<li><strong>diskData.model:</strong> Disk model name (optional)</li>
|
|
113601
|
+
<li><strong>diskData.type:</strong> Disk type: 'ssd', 'hdd', or 'nvme'</li>
|
|
113602
|
+
<li><strong>diskData.iops:</strong> Read/write IOPS (optional)</li>
|
|
113603
|
+
<li><strong>diskData.health:</strong> Health percentage 0-100 (optional)</li>
|
|
113604
|
+
</ul>
|
|
113605
|
+
Health thresholds: Good (70-100%), Warning (30-70%), Critical (<30%)
|
|
113606
|
+
</div>
|
|
113607
|
+
</div>
|
|
113608
|
+
</div>
|
|
113609
|
+
</dees-panel>
|
|
113610
|
+
</div>
|
|
113611
|
+
|
|
113612
|
+
<script>
|
|
113613
|
+
// Cleanup live updates on page unload
|
|
113614
|
+
window.addEventListener('beforeunload', () => {
|
|
113615
|
+
if ((window as any).liveUpdateInterval) {
|
|
113616
|
+
clearInterval((window as any).liveUpdateInterval);
|
|
113617
|
+
}
|
|
113618
|
+
});
|
|
113619
|
+
<\/script>
|
|
113620
|
+
</dees-demowrapper>
|
|
113621
|
+
`])), i`
|
|
113550
113622
|
.demo-container {
|
|
113551
113623
|
display: flex;
|
|
113552
113624
|
flex-direction: column;
|
|
@@ -114042,7 +114114,108 @@ html\`
|
|
|
114042
114114
|
}
|
|
114043
114115
|
]}
|
|
114044
114116
|
></dees-statsgrid>
|
|
114045
|
-
|
|
114117
|
+
\`;`, "7. Disk & Storage Tiles", "Partition and physical disk visualization tiles", [
|
|
114118
|
+
{
|
|
114119
|
+
id: "root-partition",
|
|
114120
|
+
title: "Root Partition",
|
|
114121
|
+
value: 0,
|
|
114122
|
+
type: "partition",
|
|
114123
|
+
icon: "lucide:folder-root",
|
|
114124
|
+
partitionData: {
|
|
114125
|
+
used: 698341425152,
|
|
114126
|
+
// ~650 GB
|
|
114127
|
+
total: 1073741824e3,
|
|
114128
|
+
// ~1 TB
|
|
114129
|
+
filesystem: "ext4",
|
|
114130
|
+
mountPoint: "/"
|
|
114131
|
+
}
|
|
114132
|
+
},
|
|
114133
|
+
{
|
|
114134
|
+
id: "home-partition",
|
|
114135
|
+
title: "Home Partition",
|
|
114136
|
+
value: 0,
|
|
114137
|
+
type: "partition",
|
|
114138
|
+
icon: "lucide:home",
|
|
114139
|
+
partitionData: {
|
|
114140
|
+
used: 214748364800,
|
|
114141
|
+
// ~200 GB
|
|
114142
|
+
total: 536870912e3,
|
|
114143
|
+
// ~500 GB
|
|
114144
|
+
filesystem: "ext4",
|
|
114145
|
+
mountPoint: "/home"
|
|
114146
|
+
}
|
|
114147
|
+
},
|
|
114148
|
+
{
|
|
114149
|
+
id: "data-partition",
|
|
114150
|
+
title: "Data Partition",
|
|
114151
|
+
value: 0,
|
|
114152
|
+
type: "partition",
|
|
114153
|
+
icon: "lucide:database",
|
|
114154
|
+
partitionData: {
|
|
114155
|
+
used: 1932735283200,
|
|
114156
|
+
// ~1.8 TB (90% - critical)
|
|
114157
|
+
total: 2147483648e3,
|
|
114158
|
+
// ~2 TB
|
|
114159
|
+
filesystem: "xfs",
|
|
114160
|
+
mountPoint: "/data"
|
|
114161
|
+
}
|
|
114162
|
+
},
|
|
114163
|
+
{
|
|
114164
|
+
id: "nvme-ssd",
|
|
114165
|
+
title: "Primary NVMe",
|
|
114166
|
+
value: 0,
|
|
114167
|
+
type: "disk",
|
|
114168
|
+
icon: "lucide:hard-drive",
|
|
114169
|
+
columnSpan: 2,
|
|
114170
|
+
diskData: {
|
|
114171
|
+
capacity: 2e12,
|
|
114172
|
+
// 2 TB
|
|
114173
|
+
model: "Samsung 990 Pro",
|
|
114174
|
+
type: "nvme",
|
|
114175
|
+
iops: {
|
|
114176
|
+
read: 7450,
|
|
114177
|
+
write: 6900
|
|
114178
|
+
},
|
|
114179
|
+
health: 98
|
|
114180
|
+
}
|
|
114181
|
+
},
|
|
114182
|
+
{
|
|
114183
|
+
id: "sata-ssd",
|
|
114184
|
+
title: "Secondary SSD",
|
|
114185
|
+
value: 0,
|
|
114186
|
+
type: "disk",
|
|
114187
|
+
icon: "lucide:hard-drive",
|
|
114188
|
+
diskData: {
|
|
114189
|
+
capacity: 1e12,
|
|
114190
|
+
// 1 TB
|
|
114191
|
+
model: "Crucial MX500",
|
|
114192
|
+
type: "ssd",
|
|
114193
|
+
iops: {
|
|
114194
|
+
read: 560,
|
|
114195
|
+
write: 510
|
|
114196
|
+
},
|
|
114197
|
+
health: 85
|
|
114198
|
+
}
|
|
114199
|
+
},
|
|
114200
|
+
{
|
|
114201
|
+
id: "hdd-storage",
|
|
114202
|
+
title: "Backup HDD",
|
|
114203
|
+
value: 0,
|
|
114204
|
+
type: "disk",
|
|
114205
|
+
icon: "lucide:archive",
|
|
114206
|
+
diskData: {
|
|
114207
|
+
capacity: 8e12,
|
|
114208
|
+
// 8 TB
|
|
114209
|
+
model: "Seagate IronWolf",
|
|
114210
|
+
type: "hdd",
|
|
114211
|
+
iops: {
|
|
114212
|
+
read: 210,
|
|
114213
|
+
write: 195
|
|
114214
|
+
},
|
|
114215
|
+
health: 42
|
|
114216
|
+
}
|
|
114217
|
+
}
|
|
114218
|
+
], 280, 16);
|
|
114046
114219
|
};
|
|
114047
114220
|
|
|
114048
114221
|
// ts_web/elements/00group-input/dees-input-base/dees-input-base.ts
|
|
@@ -127613,54 +127786,94 @@ var demoFunc26 = () => b2`
|
|
|
127613
127786
|
<dees-panel .title=${"3. Buttons with Icons"} .subtitle=${"Combining icons with text for enhanced visual communication"}>
|
|
127614
127787
|
<div class="icon-row">
|
|
127615
127788
|
<dees-button>
|
|
127616
|
-
<dees-icon
|
|
127789
|
+
<dees-icon icon="fa:plus"></dees-icon>
|
|
127617
127790
|
Add Item
|
|
127618
127791
|
</dees-button>
|
|
127619
127792
|
<dees-button type="destructive">
|
|
127620
|
-
<dees-icon
|
|
127793
|
+
<dees-icon icon="fa:trash"></dees-icon>
|
|
127621
127794
|
Delete
|
|
127622
127795
|
</dees-button>
|
|
127623
127796
|
<dees-button type="outline">
|
|
127624
|
-
<dees-icon
|
|
127797
|
+
<dees-icon icon="lucide:Download"></dees-icon>
|
|
127625
127798
|
Download
|
|
127626
127799
|
</dees-button>
|
|
127627
127800
|
</div>
|
|
127628
|
-
|
|
127801
|
+
|
|
127629
127802
|
<div class="icon-row">
|
|
127630
127803
|
<dees-button type="secondary" size="sm">
|
|
127631
|
-
<dees-icon
|
|
127804
|
+
<dees-icon icon="fa:gear"></dees-icon>
|
|
127632
127805
|
Settings
|
|
127633
127806
|
</dees-button>
|
|
127634
127807
|
<dees-button type="ghost">
|
|
127635
|
-
<dees-icon
|
|
127808
|
+
<dees-icon icon="fa:caretLeft"></dees-icon>
|
|
127636
127809
|
Back
|
|
127637
127810
|
</dees-button>
|
|
127638
127811
|
<dees-button type="ghost">
|
|
127639
127812
|
Next
|
|
127640
|
-
<dees-icon
|
|
127813
|
+
<dees-icon icon="fa:caretRight"></dees-icon>
|
|
127641
127814
|
</dees-button>
|
|
127642
127815
|
</div>
|
|
127643
|
-
|
|
127816
|
+
|
|
127644
127817
|
<div class="icon-row">
|
|
127645
127818
|
<dees-button size="icon" type="default">
|
|
127646
|
-
<dees-icon
|
|
127819
|
+
<dees-icon icon="fa:plus"></dees-icon>
|
|
127647
127820
|
</dees-button>
|
|
127648
127821
|
<dees-button size="icon" type="secondary">
|
|
127649
|
-
<dees-icon
|
|
127822
|
+
<dees-icon icon="fa:gear"></dees-icon>
|
|
127650
127823
|
</dees-button>
|
|
127651
127824
|
<dees-button size="icon" type="outline">
|
|
127652
|
-
<dees-icon
|
|
127825
|
+
<dees-icon icon="lucide:Search"></dees-icon>
|
|
127653
127826
|
</dees-button>
|
|
127654
127827
|
<dees-button size="icon" type="ghost">
|
|
127655
|
-
<dees-icon
|
|
127828
|
+
<dees-icon icon="lucide:MoreVertical"></dees-icon>
|
|
127656
127829
|
</dees-button>
|
|
127657
127830
|
<dees-button size="icon" type="destructive">
|
|
127658
|
-
<dees-icon
|
|
127831
|
+
<dees-icon icon="fa:trash"></dees-icon>
|
|
127659
127832
|
</dees-button>
|
|
127660
127833
|
</div>
|
|
127661
127834
|
</dees-panel>
|
|
127662
127835
|
</dees-demowrapper>
|
|
127663
|
-
|
|
127836
|
+
|
|
127837
|
+
<dees-demowrapper .runAfterRender=${async (elementArg) => {
|
|
127838
|
+
const buttons = elementArg.querySelectorAll("dees-button");
|
|
127839
|
+
buttons.forEach((button) => {
|
|
127840
|
+
button.addEventListener("clicked", () => {
|
|
127841
|
+
const icon3 = button.getAttribute("icon") || "none";
|
|
127842
|
+
const position3 = button.getAttribute("iconPosition") || "left";
|
|
127843
|
+
console.log(`Icon property button: icon=${icon3}, position=${position3}`);
|
|
127844
|
+
});
|
|
127845
|
+
});
|
|
127846
|
+
}}>
|
|
127847
|
+
<dees-panel .title=${"4. Icons via Property"} .subtitle=${"Simplified icon syntax using the icon property"}>
|
|
127848
|
+
<div class="icon-row">
|
|
127849
|
+
<dees-button icon="fa:plus">Add Item</dees-button>
|
|
127850
|
+
<dees-button type="destructive" icon="fa:trash">Delete</dees-button>
|
|
127851
|
+
<dees-button type="outline" icon="lucide:Download">Download</dees-button>
|
|
127852
|
+
</div>
|
|
127853
|
+
|
|
127854
|
+
<div class="icon-row">
|
|
127855
|
+
<dees-button type="secondary" size="sm" icon="fa:gear">Settings</dees-button>
|
|
127856
|
+
<dees-button type="ghost" icon="fa:caretLeft">Back</dees-button>
|
|
127857
|
+
<dees-button type="ghost" icon="fa:caretRight" iconPosition="right">Next</dees-button>
|
|
127858
|
+
</div>
|
|
127859
|
+
|
|
127860
|
+
<div class="icon-row">
|
|
127861
|
+
<dees-button size="icon" type="default" icon="fa:plus"></dees-button>
|
|
127862
|
+
<dees-button size="icon" type="secondary" icon="lucide:Settings"></dees-button>
|
|
127863
|
+
<dees-button size="icon" type="outline" icon="lucide:Search"></dees-button>
|
|
127864
|
+
<dees-button size="icon" type="ghost" icon="lucide:MoreVertical"></dees-button>
|
|
127865
|
+
<dees-button size="icon" type="destructive" icon="fa:trash"></dees-button>
|
|
127866
|
+
</div>
|
|
127867
|
+
|
|
127868
|
+
<div style="margin-top: 16px;">
|
|
127869
|
+
<div class="code-snippet">
|
|
127870
|
+
<dees-button icon="fa:plus">Add Item</dees-button><br>
|
|
127871
|
+
<dees-button icon="fa:caretRight" iconPosition="right">Next</dees-button>
|
|
127872
|
+
</div>
|
|
127873
|
+
</div>
|
|
127874
|
+
</dees-panel>
|
|
127875
|
+
</dees-demowrapper>
|
|
127876
|
+
|
|
127664
127877
|
<dees-demowrapper .runAfterRender=${async (elementArg) => {
|
|
127665
127878
|
const pendingButton = elementArg.querySelector('dees-button[status="pending"]');
|
|
127666
127879
|
const successButton = elementArg.querySelector('dees-button[status="success"]');
|
|
@@ -127681,7 +127894,7 @@ var demoFunc26 = () => b2`
|
|
|
127681
127894
|
});
|
|
127682
127895
|
}
|
|
127683
127896
|
}}>
|
|
127684
|
-
<dees-panel .title=${"
|
|
127897
|
+
<dees-panel .title=${"5. Button States"} .subtitle=${"Different states to indicate button status and loading conditions"}>
|
|
127685
127898
|
<div class="button-group">
|
|
127686
127899
|
<dees-button status="normal">Normal</dees-button>
|
|
127687
127900
|
<dees-button status="pending">Processing...</dees-button>
|
|
@@ -127721,7 +127934,7 @@ var demoFunc26 = () => b2`
|
|
|
127721
127934
|
});
|
|
127722
127935
|
}
|
|
127723
127936
|
}}>
|
|
127724
|
-
<dees-panel .title=${"
|
|
127937
|
+
<dees-panel .title=${"6. Event Handling"} .subtitle=${"Interactive examples with click event handling"}>
|
|
127725
127938
|
<div class="button-group">
|
|
127726
127939
|
<dees-button>Click Me</dees-button>
|
|
127727
127940
|
<dees-button type="secondary" .eventDetailData=${"custom-data-123"}>
|
|
@@ -127757,7 +127970,7 @@ var demoFunc26 = () => b2`
|
|
|
127757
127970
|
});
|
|
127758
127971
|
}
|
|
127759
127972
|
}}>
|
|
127760
|
-
<dees-panel .title=${"
|
|
127973
|
+
<dees-panel .title=${"7. Form Integration"} .subtitle=${"Buttons working within forms with automatic spacing"}>
|
|
127761
127974
|
<dees-form>
|
|
127762
127975
|
<dees-input-text label="Name" key="name" required></dees-input-text>
|
|
127763
127976
|
<dees-input-text label="Email" key="email" type="email" required></dees-input-text>
|
|
@@ -127783,7 +127996,7 @@ var demoFunc26 = () => b2`
|
|
|
127783
127996
|
}
|
|
127784
127997
|
});
|
|
127785
127998
|
}}>
|
|
127786
|
-
<dees-panel .title=${"
|
|
127999
|
+
<dees-panel .title=${"8. Backward Compatibility"} .subtitle=${"Old button types are automatically mapped to new variants"}>
|
|
127787
128000
|
<div class="button-group">
|
|
127788
128001
|
<dees-button type="normal">Normal → Default</dees-button>
|
|
127789
128002
|
<dees-button type="highlighted">Highlighted → Destructive</dees-button>
|
|
@@ -127821,36 +128034,36 @@ var demoFunc26 = () => b2`
|
|
|
127821
128034
|
});
|
|
127822
128035
|
}
|
|
127823
128036
|
}}>
|
|
127824
|
-
<dees-panel .title=${"
|
|
128037
|
+
<dees-panel .title=${"9. Advanced Examples"} .subtitle=${"Complex button configurations and real-world use cases"}>
|
|
127825
128038
|
<div class="horizontal-group">
|
|
127826
128039
|
<div class="vertical-group">
|
|
127827
128040
|
<h4 style="margin: 0 0 8px 0; font-size: 14px; font-weight: 500;">Action Group</h4>
|
|
127828
128041
|
<dees-button type="default" size="sm">
|
|
127829
|
-
<dees-icon
|
|
128042
|
+
<dees-icon icon="lucide:Save"></dees-icon>
|
|
127830
128043
|
Save Changes
|
|
127831
128044
|
</dees-button>
|
|
127832
128045
|
<dees-button type="secondary" size="sm">
|
|
127833
|
-
<dees-icon
|
|
128046
|
+
<dees-icon icon="lucide:Undo2"></dees-icon>
|
|
127834
128047
|
Discard
|
|
127835
128048
|
</dees-button>
|
|
127836
128049
|
<dees-button type="ghost" size="sm">
|
|
127837
|
-
<dees-icon
|
|
128050
|
+
<dees-icon icon="lucide:HelpCircle"></dees-icon>
|
|
127838
128051
|
Help
|
|
127839
128052
|
</dees-button>
|
|
127840
128053
|
</div>
|
|
127841
|
-
|
|
128054
|
+
|
|
127842
128055
|
<div class="vertical-group">
|
|
127843
128056
|
<h4 style="margin: 0 0 8px 0; font-size: 14px; font-weight: 500;">Danger Zone</h4>
|
|
127844
128057
|
<dees-button type="destructive" size="sm">
|
|
127845
|
-
<dees-icon
|
|
128058
|
+
<dees-icon icon="fa:trash"></dees-icon>
|
|
127846
128059
|
Delete Account
|
|
127847
128060
|
</dees-button>
|
|
127848
128061
|
<dees-button type="outline" size="sm">
|
|
127849
|
-
<dees-icon
|
|
128062
|
+
<dees-icon icon="lucide:Archive"></dees-icon>
|
|
127850
128063
|
Archive Data
|
|
127851
128064
|
</dees-button>
|
|
127852
128065
|
<dees-button type="ghost" size="sm" disabled>
|
|
127853
|
-
<dees-icon
|
|
128066
|
+
<dees-icon icon="lucide:Ban"></dees-icon>
|
|
127854
128067
|
Not Available
|
|
127855
128068
|
</dees-button>
|
|
127856
128069
|
</div>
|
|
@@ -127859,8 +128072,7 @@ var demoFunc26 = () => b2`
|
|
|
127859
128072
|
<div style="margin-top: 24px;">
|
|
127860
128073
|
<h4 style="margin: 0 0 8px 0; font-size: 14px; font-weight: 500;">Code Example:</h4>
|
|
127861
128074
|
<div class="code-snippet">
|
|
127862
|
-
<dees-button type="default" size="sm" @clicked="\${handleClick}"><br>
|
|
127863
|
-
<dees-icon iconFA="faSave"></dees-icon><br>
|
|
128075
|
+
<dees-button type="default" size="sm" icon="lucide:Save" @clicked="\${handleClick}"><br>
|
|
127864
128076
|
Save Changes<br>
|
|
127865
128077
|
</dees-button>
|
|
127866
128078
|
</div>
|
|
@@ -127874,7 +128086,7 @@ var demoFunc26 = () => b2`
|
|
|
127874
128086
|
init_dist_ts26();
|
|
127875
128087
|
init_dist_ts25();
|
|
127876
128088
|
init_theme();
|
|
127877
|
-
var _insideForm_dec, _status_dec2, _size_dec2, _type_dec3, _isHidden_dec, _disabled_dec4, _eventDetailData_dec, _text_dec2, _a33, _DeesButton_decorators, _init31, _text2, _eventDetailData, _disabled4, _isHidden, _type3, _size2, _status2, _insideForm;
|
|
128089
|
+
var _iconPosition_dec, _icon_dec2, _insideForm_dec, _status_dec2, _size_dec2, _type_dec3, _isHidden_dec, _disabled_dec4, _eventDetailData_dec, _text_dec2, _a33, _DeesButton_decorators, _init31, _text2, _eventDetailData, _disabled4, _isHidden, _type3, _size2, _status2, _insideForm, _icon2, _iconPosition;
|
|
127878
128090
|
_DeesButton_decorators = [t4("dees-button")];
|
|
127879
128091
|
var DeesButton = class extends (_a33 = DeesElement, _text_dec2 = [n5({
|
|
127880
128092
|
reflect: true,
|
|
@@ -127895,7 +128107,7 @@ var DeesButton = class extends (_a33 = DeesElement, _text_dec2 = [n5({
|
|
|
127895
128107
|
})], _insideForm_dec = [n5({
|
|
127896
128108
|
type: Boolean,
|
|
127897
128109
|
reflect: true
|
|
127898
|
-
})], _a33) {
|
|
128110
|
+
})], _icon_dec2 = [n5({ type: String, reflect: true })], _iconPosition_dec = [n5({ type: String, reflect: true })], _a33) {
|
|
127899
128111
|
constructor() {
|
|
127900
128112
|
super();
|
|
127901
128113
|
__privateAdd(this, _text2, __runInitializers(_init31, 8, this)), __runInitializers(_init31, 11, this);
|
|
@@ -127906,6 +128118,8 @@ var DeesButton = class extends (_a33 = DeesElement, _text_dec2 = [n5({
|
|
|
127906
128118
|
__privateAdd(this, _size2, __runInitializers(_init31, 28, this, "default")), __runInitializers(_init31, 31, this);
|
|
127907
128119
|
__privateAdd(this, _status2, __runInitializers(_init31, 32, this, "normal")), __runInitializers(_init31, 35, this);
|
|
127908
128120
|
__privateAdd(this, _insideForm, __runInitializers(_init31, 36, this, false)), __runInitializers(_init31, 39, this);
|
|
128121
|
+
__privateAdd(this, _icon2, __runInitializers(_init31, 40, this)), __runInitializers(_init31, 43, this);
|
|
128122
|
+
__privateAdd(this, _iconPosition, __runInitializers(_init31, 44, this, "left")), __runInitializers(_init31, 47, this);
|
|
127909
128123
|
}
|
|
127910
128124
|
async connectedCallback() {
|
|
127911
128125
|
await super.connectedCallback();
|
|
@@ -127913,6 +128127,33 @@ var DeesButton = class extends (_a33 = DeesElement, _text_dec2 = [n5({
|
|
|
127913
128127
|
this.insideForm = true;
|
|
127914
128128
|
}
|
|
127915
128129
|
}
|
|
128130
|
+
/**
|
|
128131
|
+
* Extracts icon and text from light DOM and sets properties
|
|
128132
|
+
*/
|
|
128133
|
+
extractLightDom() {
|
|
128134
|
+
const iconElement = this.querySelector("dees-icon");
|
|
128135
|
+
const textContent = Array.from(this.childNodes).filter((node2) => node2.nodeType === Node.TEXT_NODE).map((node2) => node2.textContent?.trim()).filter(Boolean).join(" ");
|
|
128136
|
+
if (textContent && !this.text) {
|
|
128137
|
+
this.text = textContent;
|
|
128138
|
+
}
|
|
128139
|
+
if (iconElement) {
|
|
128140
|
+
const iconValue = iconElement.icon || iconElement.getAttribute("icon") || (iconElement.iconFA ? `fa:${iconElement.iconFA}` : null);
|
|
128141
|
+
if (iconValue) {
|
|
128142
|
+
const children2 = Array.from(this.childNodes);
|
|
128143
|
+
const iconIndex = children2.indexOf(iconElement);
|
|
128144
|
+
const textNodes = children2.filter(
|
|
128145
|
+
(node2) => node2.nodeType === Node.TEXT_NODE && node2.textContent?.trim()
|
|
128146
|
+
);
|
|
128147
|
+
if (textNodes.length > 0) {
|
|
128148
|
+
const firstTextIndex = children2.indexOf(textNodes[0]);
|
|
128149
|
+
this.iconPosition = iconIndex < firstTextIndex ? "left" : "right";
|
|
128150
|
+
}
|
|
128151
|
+
this.icon = iconValue;
|
|
128152
|
+
}
|
|
128153
|
+
iconElement.remove();
|
|
128154
|
+
}
|
|
128155
|
+
this.innerHTML = "";
|
|
128156
|
+
}
|
|
127916
128157
|
render() {
|
|
127917
128158
|
const typeMap = {
|
|
127918
128159
|
"normal": "default",
|
|
@@ -127923,19 +128164,24 @@ var DeesButton = class extends (_a33 = DeesElement, _text_dec2 = [n5({
|
|
|
127923
128164
|
};
|
|
127924
128165
|
const actualType = typeMap[this.type] || this.type;
|
|
127925
128166
|
const actualSize = this.type === "big" ? "lg" : this.size;
|
|
128167
|
+
const leftIcon = this.iconPosition === "left" && this.icon ? b2`<dees-icon .icon=${this.icon}></dees-icon>` : "";
|
|
128168
|
+
const rightIcon = this.iconPosition === "right" && this.icon ? b2`<dees-icon .icon=${this.icon}></dees-icon>` : "";
|
|
128169
|
+
const isIconOnly = actualSize === "icon" && this.icon;
|
|
127926
128170
|
return b2`
|
|
127927
128171
|
<div
|
|
127928
128172
|
class="button ${this.isHidden ? "hidden" : ""} ${actualType} size-${actualSize} ${this.status} ${this.disabled ? "disabled" : ""}"
|
|
127929
128173
|
@click="${this.dispatchClick}"
|
|
127930
128174
|
>
|
|
127931
128175
|
${this.status === "normal" ? b2`` : b2`
|
|
127932
|
-
<dees-spinner
|
|
127933
|
-
.bnw=${true}
|
|
128176
|
+
<dees-spinner
|
|
128177
|
+
.bnw=${true}
|
|
127934
128178
|
status="${this.status}"
|
|
127935
128179
|
size="${actualSize === "sm" ? 14 : actualSize === "lg" ? 18 : 16}"
|
|
127936
128180
|
></dees-spinner>
|
|
127937
128181
|
`}
|
|
127938
|
-
|
|
128182
|
+
${leftIcon}
|
|
128183
|
+
${isIconOnly ? "" : b2`<div class="textbox">${this.text || "Button"}</div>`}
|
|
128184
|
+
${rightIcon}
|
|
127939
128185
|
</div>
|
|
127940
128186
|
`;
|
|
127941
128187
|
}
|
|
@@ -127953,6 +128199,7 @@ var DeesButton = class extends (_a33 = DeesElement, _text_dec2 = [n5({
|
|
|
127953
128199
|
);
|
|
127954
128200
|
}
|
|
127955
128201
|
async firstUpdated() {
|
|
128202
|
+
this.extractLightDom();
|
|
127956
128203
|
}
|
|
127957
128204
|
};
|
|
127958
128205
|
_init31 = __decoratorStart(_a33);
|
|
@@ -127964,6 +128211,8 @@ _type3 = new WeakMap();
|
|
|
127964
128211
|
_size2 = new WeakMap();
|
|
127965
128212
|
_status2 = new WeakMap();
|
|
127966
128213
|
_insideForm = new WeakMap();
|
|
128214
|
+
_icon2 = new WeakMap();
|
|
128215
|
+
_iconPosition = new WeakMap();
|
|
127967
128216
|
__decorateElement(_init31, 4, "text", _text_dec2, DeesButton, _text2);
|
|
127968
128217
|
__decorateElement(_init31, 4, "eventDetailData", _eventDetailData_dec, DeesButton, _eventDetailData);
|
|
127969
128218
|
__decorateElement(_init31, 4, "disabled", _disabled_dec4, DeesButton, _disabled4);
|
|
@@ -127972,6 +128221,8 @@ __decorateElement(_init31, 4, "type", _type_dec3, DeesButton, _type3);
|
|
|
127972
128221
|
__decorateElement(_init31, 4, "size", _size_dec2, DeesButton, _size2);
|
|
127973
128222
|
__decorateElement(_init31, 4, "status", _status_dec2, DeesButton, _status2);
|
|
127974
128223
|
__decorateElement(_init31, 4, "insideForm", _insideForm_dec, DeesButton, _insideForm);
|
|
128224
|
+
__decorateElement(_init31, 4, "icon", _icon_dec2, DeesButton, _icon2);
|
|
128225
|
+
__decorateElement(_init31, 4, "iconPosition", _iconPosition_dec, DeesButton, _iconPosition);
|
|
127975
128226
|
DeesButton = __decorateElement(_init31, 0, "DeesButton", _DeesButton_decorators, DeesButton);
|
|
127976
128227
|
__publicField(DeesButton, "demo", demoFunc26);
|
|
127977
128228
|
__publicField(DeesButton, "demoGroup", "Button");
|
|
@@ -128235,6 +128486,12 @@ __publicField(DeesButton, "styles", [
|
|
|
128235
128486
|
height: 18px;
|
|
128236
128487
|
}
|
|
128237
128488
|
|
|
128489
|
+
/* Text alignment */
|
|
128490
|
+
.textbox {
|
|
128491
|
+
display: flex;
|
|
128492
|
+
align-items: center;
|
|
128493
|
+
}
|
|
128494
|
+
|
|
128238
128495
|
`
|
|
128239
128496
|
]);
|
|
128240
128497
|
__runInitializers(_init31, 1, DeesButton);
|
|
@@ -128337,6 +128594,10 @@ var DeesStatsGrid = class extends (_a34 = DeesElement, _tiles_dec = [n5({ type:
|
|
|
128337
128594
|
return this.renderMultiPercentage(tile);
|
|
128338
128595
|
case "cpuCores":
|
|
128339
128596
|
return this.renderCpuCores(tile);
|
|
128597
|
+
case "partition":
|
|
128598
|
+
return this.renderPartition(tile);
|
|
128599
|
+
case "disk":
|
|
128600
|
+
return this.renderDisk(tile);
|
|
128340
128601
|
case "text":
|
|
128341
128602
|
return b2`
|
|
128342
128603
|
<div class="text-value" style="${tile.color ? `color: ${tile.color}` : ""}">
|
|
@@ -128522,6 +128783,103 @@ var DeesStatsGrid = class extends (_a34 = DeesElement, _tiles_dec = [n5({ type:
|
|
|
128522
128783
|
</div>
|
|
128523
128784
|
`;
|
|
128524
128785
|
}
|
|
128786
|
+
formatBytes(bytes) {
|
|
128787
|
+
if (bytes === 0) return "0 B";
|
|
128788
|
+
const k4 = 1024;
|
|
128789
|
+
const sizes = ["B", "KB", "MB", "GB", "TB", "PB"];
|
|
128790
|
+
const i11 = Math.floor(Math.log(bytes) / Math.log(k4));
|
|
128791
|
+
return parseFloat((bytes / Math.pow(k4, i11)).toFixed(1)) + " " + sizes[i11];
|
|
128792
|
+
}
|
|
128793
|
+
renderPartition(tile) {
|
|
128794
|
+
if (!tile.partitionData) {
|
|
128795
|
+
return b2`<div class="tile-value">${tile.value}</div>`;
|
|
128796
|
+
}
|
|
128797
|
+
const { used, total, filesystem, mountPoint } = tile.partitionData;
|
|
128798
|
+
const percentage = Math.min(100, Math.max(0, used / total * 100));
|
|
128799
|
+
const free = total - used;
|
|
128800
|
+
const getColorClass = () => {
|
|
128801
|
+
if (percentage >= 90) return "critical";
|
|
128802
|
+
if (percentage >= 75) return "warning";
|
|
128803
|
+
return "";
|
|
128804
|
+
};
|
|
128805
|
+
return b2`
|
|
128806
|
+
<div class="partition-wrapper">
|
|
128807
|
+
<div class="partition-header">
|
|
128808
|
+
<span class="partition-percentage">${Math.round(percentage)}%</span>
|
|
128809
|
+
</div>
|
|
128810
|
+
<div class="partition-bar">
|
|
128811
|
+
<div
|
|
128812
|
+
class="partition-bar-fill ${getColorClass()}"
|
|
128813
|
+
style="width: ${percentage}%"
|
|
128814
|
+
></div>
|
|
128815
|
+
</div>
|
|
128816
|
+
<div class="partition-stats">
|
|
128817
|
+
<div class="partition-stat">
|
|
128818
|
+
<span class="partition-stat-label">Used</span>
|
|
128819
|
+
<span class="partition-stat-value">${this.formatBytes(used)}</span>
|
|
128820
|
+
</div>
|
|
128821
|
+
<div class="partition-stat">
|
|
128822
|
+
<span class="partition-stat-label">Free</span>
|
|
128823
|
+
<span class="partition-stat-value">${this.formatBytes(free)}</span>
|
|
128824
|
+
</div>
|
|
128825
|
+
</div>
|
|
128826
|
+
<div class="partition-meta">
|
|
128827
|
+
<span class="partition-filesystem">${filesystem}</span>
|
|
128828
|
+
${mountPoint ? b2`<span class="partition-mountpoint">${mountPoint}</span>` : ""}
|
|
128829
|
+
</div>
|
|
128830
|
+
</div>
|
|
128831
|
+
`;
|
|
128832
|
+
}
|
|
128833
|
+
renderDisk(tile) {
|
|
128834
|
+
if (!tile.diskData) {
|
|
128835
|
+
return b2`<div class="tile-value">${tile.value}</div>`;
|
|
128836
|
+
}
|
|
128837
|
+
const { capacity, model, type: type5, iops, health } = tile.diskData;
|
|
128838
|
+
const getHealthClass = (value2) => {
|
|
128839
|
+
if (value2 >= 70) return "good";
|
|
128840
|
+
if (value2 >= 30) return "warning";
|
|
128841
|
+
return "critical";
|
|
128842
|
+
};
|
|
128843
|
+
return b2`
|
|
128844
|
+
<div class="disk-wrapper">
|
|
128845
|
+
<div class="disk-capacity">${this.formatBytes(capacity)}</div>
|
|
128846
|
+
${model || type5 ? b2`
|
|
128847
|
+
<div class="disk-model">
|
|
128848
|
+
${model ? b2`<span>${model}</span>` : ""}
|
|
128849
|
+
${type5 ? b2`<span class="disk-type-badge">${type5}</span>` : ""}
|
|
128850
|
+
</div>
|
|
128851
|
+
` : ""}
|
|
128852
|
+
<div class="disk-metrics">
|
|
128853
|
+
${iops ? b2`
|
|
128854
|
+
<div class="disk-iops">
|
|
128855
|
+
<div class="disk-iops-item">
|
|
128856
|
+
<span class="disk-iops-label">Read</span>
|
|
128857
|
+
<span class="disk-iops-value">${iops.read.toLocaleString()}</span>
|
|
128858
|
+
</div>
|
|
128859
|
+
<div class="disk-iops-item">
|
|
128860
|
+
<span class="disk-iops-label">Write</span>
|
|
128861
|
+
<span class="disk-iops-value">${iops.write.toLocaleString()}</span>
|
|
128862
|
+
</div>
|
|
128863
|
+
</div>
|
|
128864
|
+
` : ""}
|
|
128865
|
+
${health !== void 0 ? b2`
|
|
128866
|
+
<div class="disk-health">
|
|
128867
|
+
<div class="disk-health-header">
|
|
128868
|
+
<span class="disk-health-label">Health</span>
|
|
128869
|
+
<span class="disk-health-value">${health}%</span>
|
|
128870
|
+
</div>
|
|
128871
|
+
<div class="disk-health-bar">
|
|
128872
|
+
<div
|
|
128873
|
+
class="disk-health-fill ${getHealthClass(health)}"
|
|
128874
|
+
style="width: ${health}%"
|
|
128875
|
+
></div>
|
|
128876
|
+
</div>
|
|
128877
|
+
</div>
|
|
128878
|
+
` : ""}
|
|
128879
|
+
</div>
|
|
128880
|
+
</div>
|
|
128881
|
+
`;
|
|
128882
|
+
}
|
|
128525
128883
|
async handleGridAction(action) {
|
|
128526
128884
|
if (action.action) {
|
|
128527
128885
|
await action.action();
|
|
@@ -128955,6 +129313,219 @@ __publicField(DeesStatsGrid, "styles", [
|
|
|
128955
129313
|
max-width: 100%;
|
|
128956
129314
|
}
|
|
128957
129315
|
|
|
129316
|
+
/* Partition Styles */
|
|
129317
|
+
.partition-wrapper {
|
|
129318
|
+
width: 100%;
|
|
129319
|
+
display: flex;
|
|
129320
|
+
flex-direction: column;
|
|
129321
|
+
flex: 1;
|
|
129322
|
+
gap: 8px;
|
|
129323
|
+
}
|
|
129324
|
+
|
|
129325
|
+
.partition-header {
|
|
129326
|
+
display: flex;
|
|
129327
|
+
align-items: baseline;
|
|
129328
|
+
gap: 8px;
|
|
129329
|
+
}
|
|
129330
|
+
|
|
129331
|
+
.partition-percentage {
|
|
129332
|
+
font-size: var(--value-font-size);
|
|
129333
|
+
font-weight: 600;
|
|
129334
|
+
color: ${cssManager.bdTheme("hsl(215.3 25% 8.8%)", "hsl(210 40% 98%)")};
|
|
129335
|
+
line-height: 1.1;
|
|
129336
|
+
letter-spacing: -0.025em;
|
|
129337
|
+
}
|
|
129338
|
+
|
|
129339
|
+
.partition-bar {
|
|
129340
|
+
width: 100%;
|
|
129341
|
+
height: 6px;
|
|
129342
|
+
background: ${cssManager.bdTheme("#e8e8e8", "#1a1a1a")};
|
|
129343
|
+
border-radius: 3px;
|
|
129344
|
+
overflow: hidden;
|
|
129345
|
+
}
|
|
129346
|
+
|
|
129347
|
+
.partition-bar-fill {
|
|
129348
|
+
height: 100%;
|
|
129349
|
+
background: ${cssManager.bdTheme("#333333", "#e0e0e0")};
|
|
129350
|
+
transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
|
|
129351
|
+
border-radius: 3px;
|
|
129352
|
+
}
|
|
129353
|
+
|
|
129354
|
+
.partition-bar-fill.warning {
|
|
129355
|
+
background: ${cssManager.bdTheme("hsl(45.4 93.4% 47.5%)", "hsl(45.4 93.4% 47.5%)")};
|
|
129356
|
+
}
|
|
129357
|
+
|
|
129358
|
+
.partition-bar-fill.critical {
|
|
129359
|
+
background: ${cssManager.bdTheme("hsl(0 84.2% 60.2%)", "hsl(0 84.2% 60.2%)")};
|
|
129360
|
+
}
|
|
129361
|
+
|
|
129362
|
+
.partition-stats {
|
|
129363
|
+
display: flex;
|
|
129364
|
+
justify-content: space-between;
|
|
129365
|
+
align-items: center;
|
|
129366
|
+
margin-top: auto;
|
|
129367
|
+
}
|
|
129368
|
+
|
|
129369
|
+
.partition-stat {
|
|
129370
|
+
display: flex;
|
|
129371
|
+
flex-direction: column;
|
|
129372
|
+
gap: 2px;
|
|
129373
|
+
}
|
|
129374
|
+
|
|
129375
|
+
.partition-stat-label {
|
|
129376
|
+
font-size: 10px;
|
|
129377
|
+
font-weight: 500;
|
|
129378
|
+
color: ${cssManager.bdTheme("hsl(215.4 16.3% 56.9%)", "hsl(215 20.2% 55.1%)")};
|
|
129379
|
+
text-transform: uppercase;
|
|
129380
|
+
letter-spacing: 0.02em;
|
|
129381
|
+
}
|
|
129382
|
+
|
|
129383
|
+
.partition-stat-value {
|
|
129384
|
+
font-size: 13px;
|
|
129385
|
+
font-weight: 600;
|
|
129386
|
+
color: ${cssManager.bdTheme("hsl(215.3 25% 8.8%)", "hsl(210 40% 98%)")};
|
|
129387
|
+
letter-spacing: -0.01em;
|
|
129388
|
+
}
|
|
129389
|
+
|
|
129390
|
+
.partition-meta {
|
|
129391
|
+
display: flex;
|
|
129392
|
+
align-items: center;
|
|
129393
|
+
gap: 6px;
|
|
129394
|
+
margin-top: 4px;
|
|
129395
|
+
}
|
|
129396
|
+
|
|
129397
|
+
.partition-filesystem {
|
|
129398
|
+
font-size: 11px;
|
|
129399
|
+
font-weight: 500;
|
|
129400
|
+
color: ${cssManager.bdTheme("hsl(215.4 16.3% 46.9%)", "hsl(215 20.2% 65.1%)")};
|
|
129401
|
+
background: ${cssManager.bdTheme("hsl(210 40% 96.1%)", "hsl(215 20.2% 16.8%)")};
|
|
129402
|
+
padding: 2px 6px;
|
|
129403
|
+
border-radius: 3px;
|
|
129404
|
+
}
|
|
129405
|
+
|
|
129406
|
+
.partition-mountpoint {
|
|
129407
|
+
font-size: 11px;
|
|
129408
|
+
color: ${cssManager.bdTheme("hsl(215.4 16.3% 56.9%)", "hsl(215 20.2% 55.1%)")};
|
|
129409
|
+
}
|
|
129410
|
+
|
|
129411
|
+
/* Disk Styles */
|
|
129412
|
+
.disk-wrapper {
|
|
129413
|
+
width: 100%;
|
|
129414
|
+
display: flex;
|
|
129415
|
+
flex-direction: column;
|
|
129416
|
+
flex: 1;
|
|
129417
|
+
gap: 8px;
|
|
129418
|
+
}
|
|
129419
|
+
|
|
129420
|
+
.disk-capacity {
|
|
129421
|
+
font-size: var(--value-font-size);
|
|
129422
|
+
font-weight: 600;
|
|
129423
|
+
color: ${cssManager.bdTheme("hsl(215.3 25% 8.8%)", "hsl(210 40% 98%)")};
|
|
129424
|
+
line-height: 1.1;
|
|
129425
|
+
letter-spacing: -0.025em;
|
|
129426
|
+
}
|
|
129427
|
+
|
|
129428
|
+
.disk-model {
|
|
129429
|
+
font-size: 12px;
|
|
129430
|
+
color: ${cssManager.bdTheme("hsl(215.4 16.3% 46.9%)", "hsl(215 20.2% 65.1%)")};
|
|
129431
|
+
display: flex;
|
|
129432
|
+
align-items: center;
|
|
129433
|
+
gap: 6px;
|
|
129434
|
+
}
|
|
129435
|
+
|
|
129436
|
+
.disk-type-badge {
|
|
129437
|
+
font-size: 10px;
|
|
129438
|
+
font-weight: 600;
|
|
129439
|
+
text-transform: uppercase;
|
|
129440
|
+
color: ${cssManager.bdTheme("hsl(215.4 16.3% 46.9%)", "hsl(215 20.2% 65.1%)")};
|
|
129441
|
+
background: ${cssManager.bdTheme("hsl(210 40% 96.1%)", "hsl(215 20.2% 16.8%)")};
|
|
129442
|
+
padding: 2px 6px;
|
|
129443
|
+
border-radius: 3px;
|
|
129444
|
+
}
|
|
129445
|
+
|
|
129446
|
+
.disk-metrics {
|
|
129447
|
+
display: flex;
|
|
129448
|
+
flex-direction: column;
|
|
129449
|
+
gap: 8px;
|
|
129450
|
+
margin-top: auto;
|
|
129451
|
+
}
|
|
129452
|
+
|
|
129453
|
+
.disk-iops {
|
|
129454
|
+
display: flex;
|
|
129455
|
+
align-items: center;
|
|
129456
|
+
gap: 12px;
|
|
129457
|
+
}
|
|
129458
|
+
|
|
129459
|
+
.disk-iops-item {
|
|
129460
|
+
display: flex;
|
|
129461
|
+
align-items: baseline;
|
|
129462
|
+
gap: 4px;
|
|
129463
|
+
}
|
|
129464
|
+
|
|
129465
|
+
.disk-iops-label {
|
|
129466
|
+
font-size: 10px;
|
|
129467
|
+
font-weight: 500;
|
|
129468
|
+
color: ${cssManager.bdTheme("hsl(215.4 16.3% 56.9%)", "hsl(215 20.2% 55.1%)")};
|
|
129469
|
+
text-transform: uppercase;
|
|
129470
|
+
}
|
|
129471
|
+
|
|
129472
|
+
.disk-iops-value {
|
|
129473
|
+
font-size: 13px;
|
|
129474
|
+
font-weight: 600;
|
|
129475
|
+
color: ${cssManager.bdTheme("hsl(215.3 25% 8.8%)", "hsl(210 40% 98%)")};
|
|
129476
|
+
}
|
|
129477
|
+
|
|
129478
|
+
.disk-health {
|
|
129479
|
+
display: flex;
|
|
129480
|
+
flex-direction: column;
|
|
129481
|
+
gap: 4px;
|
|
129482
|
+
}
|
|
129483
|
+
|
|
129484
|
+
.disk-health-header {
|
|
129485
|
+
display: flex;
|
|
129486
|
+
justify-content: space-between;
|
|
129487
|
+
align-items: baseline;
|
|
129488
|
+
}
|
|
129489
|
+
|
|
129490
|
+
.disk-health-label {
|
|
129491
|
+
font-size: 10px;
|
|
129492
|
+
font-weight: 500;
|
|
129493
|
+
color: ${cssManager.bdTheme("hsl(215.4 16.3% 56.9%)", "hsl(215 20.2% 55.1%)")};
|
|
129494
|
+
text-transform: uppercase;
|
|
129495
|
+
}
|
|
129496
|
+
|
|
129497
|
+
.disk-health-value {
|
|
129498
|
+
font-size: 12px;
|
|
129499
|
+
font-weight: 600;
|
|
129500
|
+
color: ${cssManager.bdTheme("hsl(215.3 25% 8.8%)", "hsl(210 40% 98%)")};
|
|
129501
|
+
}
|
|
129502
|
+
|
|
129503
|
+
.disk-health-bar {
|
|
129504
|
+
width: 100%;
|
|
129505
|
+
height: 4px;
|
|
129506
|
+
background: ${cssManager.bdTheme("#e8e8e8", "#1a1a1a")};
|
|
129507
|
+
border-radius: 2px;
|
|
129508
|
+
overflow: hidden;
|
|
129509
|
+
}
|
|
129510
|
+
|
|
129511
|
+
.disk-health-fill {
|
|
129512
|
+
height: 100%;
|
|
129513
|
+
transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
|
|
129514
|
+
border-radius: 2px;
|
|
129515
|
+
}
|
|
129516
|
+
|
|
129517
|
+
.disk-health-fill.good {
|
|
129518
|
+
background: ${cssManager.bdTheme("hsl(142.1 76.2% 36.3%)", "hsl(142.1 70.6% 45.3%)")};
|
|
129519
|
+
}
|
|
129520
|
+
|
|
129521
|
+
.disk-health-fill.warning {
|
|
129522
|
+
background: ${cssManager.bdTheme("hsl(45.4 93.4% 47.5%)", "hsl(45.4 93.4% 47.5%)")};
|
|
129523
|
+
}
|
|
129524
|
+
|
|
129525
|
+
.disk-health-fill.critical {
|
|
129526
|
+
background: ${cssManager.bdTheme("hsl(0 84.2% 60.2%)", "hsl(0 84.2% 60.2%)")};
|
|
129527
|
+
}
|
|
129528
|
+
|
|
128958
129529
|
/* Trend Styles */
|
|
128959
129530
|
.trend-container {
|
|
128960
129531
|
width: 100%;
|
|
@@ -135051,8 +135622,10 @@ init_dist_ts26();
|
|
|
135051
135622
|
var demoFunc33 = () => {
|
|
135052
135623
|
return b2`
|
|
135053
135624
|
<dees-demowrapper .runAfterRender=${async (elementArg) => {
|
|
135054
|
-
const
|
|
135055
|
-
|
|
135625
|
+
const structuredLog = elementArg.querySelector("#structured-log");
|
|
135626
|
+
const rawLog = elementArg.querySelector("#raw-log");
|
|
135627
|
+
let structuredIntervalId;
|
|
135628
|
+
let rawIntervalId;
|
|
135056
135629
|
const serverSources = ["Server", "Database", "API", "Auth", "Cache", "Queue", "WebSocket", "Scheduler"];
|
|
135057
135630
|
const logTemplates = {
|
|
135058
135631
|
debug: [
|
|
@@ -135091,6 +135664,20 @@ var demoFunc33 = () => {
|
|
|
135091
135664
|
"Health check passed: all systems operational"
|
|
135092
135665
|
]
|
|
135093
135666
|
};
|
|
135667
|
+
const dockerLogTemplates = [
|
|
135668
|
+
"\x1B[90m2024-01-15T10:23:45.123Z\x1B[0m \x1B[36mINFO\x1B[0m [nginx] GET /api/health 200 - 2ms",
|
|
135669
|
+
"\x1B[90m2024-01-15T10:23:45.456Z\x1B[0m \x1B[33mWARN\x1B[0m [redis] Connection pool running low: 3/10",
|
|
135670
|
+
"\x1B[90m2024-01-15T10:23:45.789Z\x1B[0m \x1B[31mERROR\x1B[0m [mongodb] Query timeout after 30000ms",
|
|
135671
|
+
"\x1B[90m2024-01-15T10:23:46.012Z\x1B[0m \x1B[36mINFO\x1B[0m [app] Processing batch job #{{jobId}}",
|
|
135672
|
+
"\x1B[90m2024-01-15T10:23:46.345Z\x1B[0m \x1B[32mOK\x1B[0m [health] All services healthy",
|
|
135673
|
+
"\x1B[90m2024-01-15T10:23:46.678Z\x1B[0m \x1B[36mINFO\x1B[0m [kafka] Message consumed from topic: events",
|
|
135674
|
+
"\x1B[90m2024-01-15T10:23:47.001Z\x1B[0m \x1B[35mDEBUG\x1B[0m [grpc] Request received: GetUser(id={{userId}})",
|
|
135675
|
+
"\x1B[90m2024-01-15T10:23:47.234Z\x1B[0m \x1B[31mERROR\x1B[0m [auth] Token validation failed: expired",
|
|
135676
|
+
"\x1B[90m2024-01-15T10:23:47.567Z\x1B[0m \x1B[33mWARN\x1B[0m [rate-limit] IP {{ip}} approaching rate limit",
|
|
135677
|
+
"\x1B[90m2024-01-15T10:23:47.890Z\x1B[0m \x1B[36mINFO\x1B[0m [websocket] Client connected: session={{session}}",
|
|
135678
|
+
// Multi-line log entry like stack traces
|
|
135679
|
+
"\x1B[31mError: Connection refused\x1B[0m\n at TcpConnection.connect (/app/node_modules/pg/lib/connection.js:12:15)\n at Pool.connect (/app/node_modules/pg/lib/pool.js:45:23)\n at async DatabaseService.query (/app/src/db/service.ts:89:12)"
|
|
135680
|
+
];
|
|
135094
135681
|
const generateRandomLog = () => {
|
|
135095
135682
|
const levels = ["debug", "info", "warn", "error", "success"];
|
|
135096
135683
|
const weights = [0.2, 0.5, 0.15, 0.1, 0.05];
|
|
@@ -135108,15 +135695,21 @@ var demoFunc33 = () => {
|
|
|
135108
135695
|
const templates = logTemplates[level];
|
|
135109
135696
|
const template = templates[Math.floor(Math.random() * templates.length)];
|
|
135110
135697
|
const message2 = template.replace("{{module}}", ["express", "mongoose", "redis", "socket.io"][Math.floor(Math.random() * 4)]).replace("{{key}}", "user:" + Math.floor(Math.random() * 1e3)).replace("{{time}}", String(Math.floor(Math.random() * 500) + 50)).replace("{{headers}}", "Content-Type: application/json, Authorization: Bearer ...").replace("{{var}}", ["NODE_ENV", "DATABASE_URL", "API_KEY", "PORT"][Math.floor(Math.random() * 4)]).replace("{{method}}", ["GET", "POST", "PUT", "DELETE"][Math.floor(Math.random() * 4)]).replace("{{path}}", ["/api/users", "/api/auth/login", "/api/products", "/health"][Math.floor(Math.random() * 4)]).replace("{{userId}}", String(Math.floor(Math.random() * 1e4))).replace("{{jobId}}", "job_" + Math.random().toString(36).substring(2, 11)).replace("{{task}}", ["cleanup", "backup", "report-generation", "cache-refresh"][Math.floor(Math.random() * 4)]).replace("{{ip}}", `192.168.1.${Math.floor(Math.random() * 255)}`).replace("{{query}}", "SELECT * FROM users WHERE ...").replace("{{percent}}", String(Math.floor(Math.random() * 30) + 70)).replace("{{endpoint}}", "/api/v1/legacy").replace("{{days}}", String(Math.floor(Math.random() * 30) + 1)).replace("{{error}}", ["ECONNREFUSED", "ETIMEDOUT", "ENOTFOUND"][Math.floor(Math.random() * 3)]).replace("{{user}}", "user_" + Math.floor(Math.random() * 1e3)).replace("{{service}}", ["Redis", "MongoDB", "ElasticSearch"][Math.floor(Math.random() * 3)]).replace("{{port}}", String(3e3 + Math.floor(Math.random() * 10))).replace("{{size}}", String(Math.floor(Math.random() * 500) + 100));
|
|
135111
|
-
|
|
135698
|
+
structuredLog.addLog(level, message2, source);
|
|
135112
135699
|
};
|
|
135113
|
-
const
|
|
135114
|
-
|
|
135700
|
+
const generateDockerLog = () => {
|
|
135701
|
+
const template = dockerLogTemplates[Math.floor(Math.random() * dockerLogTemplates.length)];
|
|
135702
|
+
const now2 = (/* @__PURE__ */ new Date()).toISOString();
|
|
135703
|
+
const logLine = template.replace(/2024-01-15T10:23:\d{2}\.\d{3}Z/g, now2).replace("{{jobId}}", String(Math.floor(Math.random() * 1e4))).replace("{{userId}}", String(Math.floor(Math.random() * 1e4))).replace("{{ip}}", `192.168.1.${Math.floor(Math.random() * 255)}`).replace("{{session}}", Math.random().toString(36).substring(2, 11));
|
|
135704
|
+
rawLog.writelnRaw(logLine);
|
|
135705
|
+
};
|
|
135706
|
+
const startStructuredSimulation = () => {
|
|
135707
|
+
if (!structuredIntervalId) {
|
|
135115
135708
|
const scheduleNext = () => {
|
|
135116
135709
|
generateRandomLog();
|
|
135117
135710
|
const nextDelay = Math.random() * 2e3 + 500;
|
|
135118
|
-
|
|
135119
|
-
if (
|
|
135711
|
+
structuredIntervalId = window.setTimeout(() => {
|
|
135712
|
+
if (structuredIntervalId) {
|
|
135120
135713
|
scheduleNext();
|
|
135121
135714
|
}
|
|
135122
135715
|
}, nextDelay);
|
|
@@ -135124,57 +135717,131 @@ var demoFunc33 = () => {
|
|
|
135124
135717
|
scheduleNext();
|
|
135125
135718
|
}
|
|
135126
135719
|
};
|
|
135127
|
-
const
|
|
135128
|
-
if (
|
|
135129
|
-
window.clearTimeout(
|
|
135130
|
-
|
|
135720
|
+
const stopStructuredSimulation = () => {
|
|
135721
|
+
if (structuredIntervalId) {
|
|
135722
|
+
window.clearTimeout(structuredIntervalId);
|
|
135723
|
+
structuredIntervalId = null;
|
|
135724
|
+
}
|
|
135725
|
+
};
|
|
135726
|
+
const startRawSimulation = () => {
|
|
135727
|
+
if (!rawIntervalId) {
|
|
135728
|
+
const scheduleNext = () => {
|
|
135729
|
+
generateDockerLog();
|
|
135730
|
+
const nextDelay = Math.random() * 1e3 + 200;
|
|
135731
|
+
rawIntervalId = window.setTimeout(() => {
|
|
135732
|
+
if (rawIntervalId) {
|
|
135733
|
+
scheduleNext();
|
|
135734
|
+
}
|
|
135735
|
+
}, nextDelay);
|
|
135736
|
+
};
|
|
135737
|
+
scheduleNext();
|
|
135738
|
+
}
|
|
135739
|
+
};
|
|
135740
|
+
const stopRawSimulation = () => {
|
|
135741
|
+
if (rawIntervalId) {
|
|
135742
|
+
window.clearTimeout(rawIntervalId);
|
|
135743
|
+
rawIntervalId = null;
|
|
135131
135744
|
}
|
|
135132
135745
|
};
|
|
135133
135746
|
const buttons = elementArg.querySelectorAll("dees-button");
|
|
135134
135747
|
buttons.forEach((button) => {
|
|
135135
135748
|
const text9 = button.textContent?.trim();
|
|
135136
|
-
|
|
135137
|
-
|
|
135138
|
-
|
|
135139
|
-
|
|
135140
|
-
|
|
135141
|
-
|
|
135749
|
+
switch (text9) {
|
|
135750
|
+
case "Add Structured Log":
|
|
135751
|
+
button.addEventListener("click", () => generateRandomLog());
|
|
135752
|
+
break;
|
|
135753
|
+
case "Start Structured":
|
|
135754
|
+
button.addEventListener("click", () => startStructuredSimulation());
|
|
135755
|
+
break;
|
|
135756
|
+
case "Stop Structured":
|
|
135757
|
+
button.addEventListener("click", () => stopStructuredSimulation());
|
|
135758
|
+
break;
|
|
135759
|
+
case "Add Docker Log":
|
|
135760
|
+
button.addEventListener("click", () => generateDockerLog());
|
|
135761
|
+
break;
|
|
135762
|
+
case "Start Docker":
|
|
135763
|
+
button.addEventListener("click", () => startRawSimulation());
|
|
135764
|
+
break;
|
|
135765
|
+
case "Stop Docker":
|
|
135766
|
+
button.addEventListener("click", () => stopRawSimulation());
|
|
135767
|
+
break;
|
|
135142
135768
|
}
|
|
135143
135769
|
});
|
|
135144
135770
|
}}>
|
|
135145
135771
|
<style>
|
|
135146
|
-
|
|
135147
|
-
|
|
135148
|
-
|
|
135149
|
-
|
|
135150
|
-
|
|
135151
|
-
|
|
135152
|
-
|
|
135153
|
-
|
|
135154
|
-
|
|
135155
|
-
|
|
135156
|
-
|
|
135157
|
-
|
|
135158
|
-
|
|
135159
|
-
|
|
135160
|
-
|
|
135161
|
-
|
|
135162
|
-
|
|
135163
|
-
|
|
135164
|
-
|
|
135165
|
-
|
|
135166
|
-
|
|
135167
|
-
|
|
135772
|
+
${i`
|
|
135773
|
+
.demoBox {
|
|
135774
|
+
position: relative;
|
|
135775
|
+
background: ${cssManager.bdTheme("hsl(0 0% 95%)", "hsl(0 0% 5%)")};
|
|
135776
|
+
height: 100%;
|
|
135777
|
+
width: 100%;
|
|
135778
|
+
padding: 40px;
|
|
135779
|
+
box-sizing: border-box;
|
|
135780
|
+
display: flex;
|
|
135781
|
+
flex-direction: column;
|
|
135782
|
+
gap: 24px;
|
|
135783
|
+
}
|
|
135784
|
+
.section {
|
|
135785
|
+
display: flex;
|
|
135786
|
+
flex-direction: column;
|
|
135787
|
+
gap: 12px;
|
|
135788
|
+
}
|
|
135789
|
+
.section-title {
|
|
135790
|
+
color: ${cssManager.bdTheme("hsl(0 0% 9%)", "hsl(0 0% 95%)")};
|
|
135791
|
+
font-size: 14px;
|
|
135792
|
+
font-weight: 600;
|
|
135793
|
+
font-family: 'Geist Sans', sans-serif;
|
|
135794
|
+
}
|
|
135795
|
+
.section-description {
|
|
135796
|
+
color: ${cssManager.bdTheme("hsl(215.4 16.3% 46.9%)", "hsl(215 20.2% 65.1%)")};
|
|
135797
|
+
font-size: 12px;
|
|
135798
|
+
font-family: 'Geist Sans', sans-serif;
|
|
135799
|
+
}
|
|
135800
|
+
.controls {
|
|
135801
|
+
display: flex;
|
|
135802
|
+
gap: 10px;
|
|
135803
|
+
flex-wrap: wrap;
|
|
135804
|
+
}
|
|
135805
|
+
`}
|
|
135806
|
+
</style>
|
|
135168
135807
|
<div class="demoBox">
|
|
135169
|
-
|
|
135170
|
-
|
|
135171
|
-
<
|
|
135172
|
-
<
|
|
135808
|
+
<!-- Structured Logs Section -->
|
|
135809
|
+
<div class="section">
|
|
135810
|
+
<div class="section-title">Structured Logs (ILogEntry)</div>
|
|
135811
|
+
<div class="section-description">
|
|
135812
|
+
Structured log entries with level, message, and source. Supports search and keyword highlighting.
|
|
135813
|
+
</div>
|
|
135814
|
+
<div class="controls">
|
|
135815
|
+
<dees-button>Add Structured Log</dees-button>
|
|
135816
|
+
<dees-button>Start Structured</dees-button>
|
|
135817
|
+
<dees-button>Stop Structured</dees-button>
|
|
135818
|
+
</div>
|
|
135819
|
+
<dees-chart-log
|
|
135820
|
+
id="structured-log"
|
|
135821
|
+
.label=${"Production Server Logs"}
|
|
135822
|
+
.highlightKeywords=${["error", "failed", "timeout"]}
|
|
135823
|
+
.showMetrics=${true}
|
|
135824
|
+
></dees-chart-log>
|
|
135825
|
+
</div>
|
|
135826
|
+
|
|
135827
|
+
<!-- Raw Logs Section -->
|
|
135828
|
+
<div class="section">
|
|
135829
|
+
<div class="section-title">Raw Logs (Docker/Container Style)</div>
|
|
135830
|
+
<div class="section-description">
|
|
135831
|
+
Raw log output with ANSI escape sequences for real Docker/container logs.
|
|
135832
|
+
</div>
|
|
135833
|
+
<div class="controls">
|
|
135834
|
+
<dees-button>Add Docker Log</dees-button>
|
|
135835
|
+
<dees-button>Start Docker</dees-button>
|
|
135836
|
+
<dees-button>Stop Docker</dees-button>
|
|
135837
|
+
</div>
|
|
135838
|
+
<dees-chart-log
|
|
135839
|
+
id="raw-log"
|
|
135840
|
+
.label=${"Docker Container Logs"}
|
|
135841
|
+
.mode=${"raw"}
|
|
135842
|
+
.showMetrics=${false}
|
|
135843
|
+
></dees-chart-log>
|
|
135173
135844
|
</div>
|
|
135174
|
-
<div class="info">Simulating realistic server logs with various levels and sources</div>
|
|
135175
|
-
<dees-chart-log
|
|
135176
|
-
.label=${"Production Server Logs"}
|
|
135177
|
-
></dees-chart-log>
|
|
135178
135845
|
</div>
|
|
135179
135846
|
</dees-demowrapper>
|
|
135180
135847
|
`;
|
|
@@ -135184,16 +135851,37 @@ var demoFunc33 = () => {
|
|
|
135184
135851
|
init_dist_ts26();
|
|
135185
135852
|
init_dist_ts25();
|
|
135186
135853
|
init_theme();
|
|
135187
|
-
|
|
135854
|
+
init_services();
|
|
135855
|
+
var _terminalReady_dec, _metrics_dec, _filterMode_dec, _searchQuery_dec2, _showMetrics_dec, _highlightKeywords_dec, _maxEntries_dec, _autoScroll_dec, _logEntries_dec, _mode_dec, _label_dec6, _a45, _DeesChartLog_decorators, _init47, _label6, _mode, _logEntries, _autoScroll, _maxEntries, _highlightKeywords, _showMetrics, _searchQuery2, _filterMode, _metrics, _terminalReady;
|
|
135188
135856
|
_DeesChartLog_decorators = [t4("dees-chart-log")];
|
|
135189
|
-
var DeesChartLog = class extends (_a45 = DeesElement, _label_dec6 = [n5()], _logEntries_dec = [n5({ type: Array })], _autoScroll_dec = [n5({ type: Boolean })], _maxEntries_dec = [n5({ type: Number })], _a45) {
|
|
135857
|
+
var DeesChartLog = class extends (_a45 = DeesElement, _label_dec6 = [n5()], _mode_dec = [n5({ type: String })], _logEntries_dec = [n5({ type: Array })], _autoScroll_dec = [n5({ type: Boolean })], _maxEntries_dec = [n5({ type: Number })], _highlightKeywords_dec = [n5({ type: Array })], _showMetrics_dec = [n5({ type: Boolean })], _searchQuery_dec2 = [r5()], _filterMode_dec = [r5()], _metrics_dec = [r5()], _terminalReady_dec = [r5()], _a45) {
|
|
135190
135858
|
constructor() {
|
|
135191
135859
|
super();
|
|
135192
135860
|
__privateAdd(this, _label6, __runInitializers(_init47, 8, this, "Server Logs")), __runInitializers(_init47, 11, this);
|
|
135193
|
-
__privateAdd(this,
|
|
135194
|
-
__privateAdd(this,
|
|
135195
|
-
__privateAdd(this,
|
|
135196
|
-
|
|
135861
|
+
__privateAdd(this, _mode, __runInitializers(_init47, 12, this, "structured")), __runInitializers(_init47, 15, this);
|
|
135862
|
+
__privateAdd(this, _logEntries, __runInitializers(_init47, 16, this, [])), __runInitializers(_init47, 19, this);
|
|
135863
|
+
__privateAdd(this, _autoScroll, __runInitializers(_init47, 20, this, true)), __runInitializers(_init47, 23, this);
|
|
135864
|
+
__privateAdd(this, _maxEntries, __runInitializers(_init47, 24, this, 1e4)), __runInitializers(_init47, 27, this);
|
|
135865
|
+
__privateAdd(this, _highlightKeywords, __runInitializers(_init47, 28, this, [])), __runInitializers(_init47, 31, this);
|
|
135866
|
+
__privateAdd(this, _showMetrics, __runInitializers(_init47, 32, this, true)), __runInitializers(_init47, 35, this);
|
|
135867
|
+
__privateAdd(this, _searchQuery2, __runInitializers(_init47, 36, this, "")), __runInitializers(_init47, 39, this);
|
|
135868
|
+
__privateAdd(this, _filterMode, __runInitializers(_init47, 40, this, false)), __runInitializers(_init47, 43, this);
|
|
135869
|
+
__privateAdd(this, _metrics, __runInitializers(_init47, 44, this, { debug: 0, info: 0, warn: 0, error: 0, success: 0, total: 0, rate: 0 })), __runInitializers(_init47, 47, this);
|
|
135870
|
+
__privateAdd(this, _terminalReady, __runInitializers(_init47, 48, this, false)), __runInitializers(_init47, 51, this);
|
|
135871
|
+
// Buffer of all log entries for filter mode
|
|
135872
|
+
__publicField(this, "logBuffer", []);
|
|
135873
|
+
// Track trailing hidden entries count for live updates in filter mode
|
|
135874
|
+
__publicField(this, "trailingHiddenCount", 0);
|
|
135875
|
+
// xterm instances
|
|
135876
|
+
__publicField(this, "terminal", null);
|
|
135877
|
+
__publicField(this, "fitAddon", null);
|
|
135878
|
+
__publicField(this, "searchAddon", null);
|
|
135879
|
+
__publicField(this, "resizeObserver", null);
|
|
135880
|
+
__publicField(this, "terminalThemeSubscription", null);
|
|
135881
|
+
__publicField(this, "domtoolsInstance", null);
|
|
135882
|
+
// Rate calculation
|
|
135883
|
+
__publicField(this, "rateBuffer", []);
|
|
135884
|
+
__publicField(this, "rateInterval", null);
|
|
135197
135885
|
domtools_elementbasic_exports.setup();
|
|
135198
135886
|
}
|
|
135199
135887
|
render() {
|
|
@@ -135201,105 +135889,508 @@ var DeesChartLog = class extends (_a45 = DeesElement, _label_dec6 = [n5()], _log
|
|
|
135201
135889
|
<div class="mainbox">
|
|
135202
135890
|
<div class="header">
|
|
135203
135891
|
<div class="title">${this.label}</div>
|
|
135892
|
+
<div class="search-box">
|
|
135893
|
+
<input
|
|
135894
|
+
type="text"
|
|
135895
|
+
placeholder="Search logs..."
|
|
135896
|
+
.value=${this.searchQuery}
|
|
135897
|
+
@input=${(e11) => this.handleSearchInput(e11)}
|
|
135898
|
+
@keydown=${(e11) => this.handleSearchKeydown(e11)}
|
|
135899
|
+
/>
|
|
135900
|
+
<div class="search-nav">
|
|
135901
|
+
<button @click=${() => this.searchPrevious()} title="Previous match">↑</button>
|
|
135902
|
+
<button @click=${() => this.searchNext()} title="Next match">↓</button>
|
|
135903
|
+
</div>
|
|
135904
|
+
<button
|
|
135905
|
+
class="filter-toggle ${this.filterMode ? "active" : ""}"
|
|
135906
|
+
@click=${() => this.toggleFilterMode()}
|
|
135907
|
+
title="${this.filterMode ? "Switch to highlight mode" : "Switch to filter mode"}"
|
|
135908
|
+
>
|
|
135909
|
+
${this.filterMode ? "Filter" : "Highlight"}
|
|
135910
|
+
</button>
|
|
135911
|
+
</div>
|
|
135204
135912
|
<div class="controls">
|
|
135205
|
-
<button
|
|
135913
|
+
<button
|
|
135206
135914
|
class="control-button ${this.autoScroll ? "active" : ""}"
|
|
135207
|
-
@click=${() =>
|
|
135208
|
-
this.autoScroll = !this.autoScroll;
|
|
135209
|
-
}}
|
|
135915
|
+
@click=${() => this.toggleAutoScroll()}
|
|
135210
135916
|
>
|
|
135211
135917
|
Auto Scroll
|
|
135212
135918
|
</button>
|
|
135213
|
-
<button
|
|
135214
|
-
class="control-button"
|
|
135215
|
-
@click=${() => {
|
|
135216
|
-
this.clearLogs();
|
|
135217
|
-
}}
|
|
135218
|
-
>
|
|
135919
|
+
<button class="control-button" @click=${() => this.clearLogs()}>
|
|
135219
135920
|
Clear
|
|
135220
135921
|
</button>
|
|
135221
135922
|
</div>
|
|
135222
135923
|
</div>
|
|
135223
|
-
|
|
135224
|
-
|
|
135924
|
+
|
|
135925
|
+
<div class="terminal-container">
|
|
135926
|
+
${!this.terminalReady ? b2`<div class="loading-state">Loading terminal...</div>` : ""}
|
|
135225
135927
|
</div>
|
|
135928
|
+
|
|
135929
|
+
${this.showMetrics ? b2`
|
|
135930
|
+
<div class="metrics-bar">
|
|
135931
|
+
<span class="metric error">errors: ${this.metrics.error}</span>
|
|
135932
|
+
<span class="metric warn">warns: ${this.metrics.warn}</span>
|
|
135933
|
+
<span class="metric info">info: ${this.metrics.info}</span>
|
|
135934
|
+
<span class="metric success">success: ${this.metrics.success}</span>
|
|
135935
|
+
<span class="metric debug">debug: ${this.metrics.debug}</span>
|
|
135936
|
+
<span class="metric rate">${this.metrics.rate.toFixed(1)} logs/sec</span>
|
|
135937
|
+
</div>
|
|
135938
|
+
` : ""}
|
|
135226
135939
|
</div>
|
|
135227
135940
|
`;
|
|
135228
135941
|
}
|
|
135229
|
-
|
|
135230
|
-
|
|
135942
|
+
async firstUpdated() {
|
|
135943
|
+
this.domtoolsInstance = await this.domtoolsPromise;
|
|
135944
|
+
await this.initializeTerminal();
|
|
135945
|
+
if (this.logEntries.length > 0) {
|
|
135946
|
+
for (const entry of this.logEntries) {
|
|
135947
|
+
this.writeLogEntry(entry);
|
|
135948
|
+
}
|
|
135949
|
+
}
|
|
135950
|
+
}
|
|
135951
|
+
async initializeTerminal() {
|
|
135952
|
+
const libLoader = DeesServiceLibLoader.getInstance();
|
|
135953
|
+
const [xtermBundle, fitBundle, searchBundle] = await Promise.all([
|
|
135954
|
+
libLoader.loadXterm(),
|
|
135955
|
+
libLoader.loadXtermFitAddon(),
|
|
135956
|
+
libLoader.loadXtermSearchAddon()
|
|
135957
|
+
]);
|
|
135958
|
+
await this.injectXtermStylesIntoShadow();
|
|
135959
|
+
this.terminal = new xtermBundle.Terminal({
|
|
135960
|
+
cursorBlink: false,
|
|
135961
|
+
disableStdin: true,
|
|
135962
|
+
fontSize: 12,
|
|
135963
|
+
fontFamily: "'SF Mono', 'Monaco', 'Consolas', 'Liberation Mono', 'Courier New', monospace",
|
|
135964
|
+
theme: this.getTerminalTheme(),
|
|
135965
|
+
scrollback: this.maxEntries,
|
|
135966
|
+
convertEol: true
|
|
135967
|
+
});
|
|
135968
|
+
this.fitAddon = new fitBundle.FitAddon();
|
|
135969
|
+
this.searchAddon = new searchBundle.SearchAddon();
|
|
135970
|
+
this.terminal.loadAddon(this.fitAddon);
|
|
135971
|
+
this.terminal.loadAddon(this.searchAddon);
|
|
135972
|
+
const container = this.shadowRoot.querySelector(".terminal-container");
|
|
135973
|
+
this.terminal.open(container);
|
|
135974
|
+
await new Promise((resolve2) => requestAnimationFrame(resolve2));
|
|
135975
|
+
this.fitAddon.fit();
|
|
135976
|
+
this.resizeObserver = new ResizeObserver(() => {
|
|
135977
|
+
this.fitAddon?.fit();
|
|
135978
|
+
});
|
|
135979
|
+
this.resizeObserver.observe(container);
|
|
135980
|
+
this.terminalThemeSubscription = this.domtoolsInstance.themeManager.themeObservable.subscribe(() => {
|
|
135981
|
+
if (this.terminal) {
|
|
135982
|
+
this.terminal.options.theme = this.getTerminalTheme();
|
|
135983
|
+
}
|
|
135984
|
+
});
|
|
135985
|
+
this.rateInterval = setInterval(() => this.calculateRate(), 1e3);
|
|
135986
|
+
this.terminalReady = true;
|
|
135987
|
+
}
|
|
135988
|
+
getTerminalTheme() {
|
|
135989
|
+
const isDark = this.domtoolsInstance?.themeManager?.isDarkMode ?? true;
|
|
135990
|
+
return isDark ? {
|
|
135991
|
+
background: "#0a0a0a",
|
|
135992
|
+
foreground: "#e0e0e0",
|
|
135993
|
+
cursor: "#e0e0e0",
|
|
135994
|
+
selectionBackground: "#404040",
|
|
135995
|
+
black: "#000000",
|
|
135996
|
+
red: "#ff5555",
|
|
135997
|
+
green: "#50fa7b",
|
|
135998
|
+
yellow: "#f1fa8c",
|
|
135999
|
+
blue: "#6272a4",
|
|
136000
|
+
magenta: "#ff79c6",
|
|
136001
|
+
cyan: "#8be9fd",
|
|
136002
|
+
white: "#f8f8f2",
|
|
136003
|
+
brightBlack: "#6272a4",
|
|
136004
|
+
brightRed: "#ff6e6e",
|
|
136005
|
+
brightGreen: "#69ff94",
|
|
136006
|
+
brightYellow: "#ffffa5",
|
|
136007
|
+
brightBlue: "#d6acff",
|
|
136008
|
+
brightMagenta: "#ff92df",
|
|
136009
|
+
brightCyan: "#a4ffff",
|
|
136010
|
+
brightWhite: "#ffffff"
|
|
136011
|
+
} : {
|
|
136012
|
+
background: "#ffffff",
|
|
136013
|
+
foreground: "#333333",
|
|
136014
|
+
cursor: "#333333",
|
|
136015
|
+
selectionBackground: "#add6ff",
|
|
136016
|
+
black: "#000000",
|
|
136017
|
+
red: "#cd3131",
|
|
136018
|
+
green: "#00bc00",
|
|
136019
|
+
yellow: "#949800",
|
|
136020
|
+
blue: "#0451a5",
|
|
136021
|
+
magenta: "#bc05bc",
|
|
136022
|
+
cyan: "#0598bc",
|
|
136023
|
+
white: "#555555",
|
|
136024
|
+
brightBlack: "#666666",
|
|
136025
|
+
brightRed: "#cd3131",
|
|
136026
|
+
brightGreen: "#14ce14",
|
|
136027
|
+
brightYellow: "#b5ba00",
|
|
136028
|
+
brightBlue: "#0451a5",
|
|
136029
|
+
brightMagenta: "#bc05bc",
|
|
136030
|
+
brightCyan: "#0598bc",
|
|
136031
|
+
brightWhite: "#a5a5a5"
|
|
136032
|
+
};
|
|
136033
|
+
}
|
|
136034
|
+
/**
|
|
136035
|
+
* Inject xterm CSS styles into shadow root
|
|
136036
|
+
* This is needed because shadow DOM doesn't inherit styles from document.head
|
|
136037
|
+
*/
|
|
136038
|
+
async injectXtermStylesIntoShadow() {
|
|
136039
|
+
const styleId = "xterm-shadow-styles";
|
|
136040
|
+
if (this.shadowRoot.getElementById(styleId)) {
|
|
136041
|
+
return;
|
|
136042
|
+
}
|
|
136043
|
+
const cssUrl = `${CDN_BASE}/xterm@${CDN_VERSIONS.xterm}/css/xterm.css`;
|
|
136044
|
+
const response = await fetch(cssUrl);
|
|
136045
|
+
const cssText = await response.text();
|
|
136046
|
+
const style = document.createElement("style");
|
|
136047
|
+
style.id = styleId;
|
|
136048
|
+
style.textContent = cssText;
|
|
136049
|
+
this.shadowRoot.appendChild(style);
|
|
136050
|
+
}
|
|
136051
|
+
// =====================
|
|
136052
|
+
// Structured Log Methods
|
|
136053
|
+
// =====================
|
|
136054
|
+
/**
|
|
136055
|
+
* Add a single structured log entry
|
|
136056
|
+
*/
|
|
136057
|
+
addLog(level, message2, source) {
|
|
136058
|
+
const entry = {
|
|
136059
|
+
timestamp: (/* @__PURE__ */ new Date()).toISOString(),
|
|
136060
|
+
level,
|
|
136061
|
+
message: message2,
|
|
136062
|
+
source
|
|
136063
|
+
};
|
|
136064
|
+
this.logBuffer.push(entry);
|
|
136065
|
+
if (this.logBuffer.length > this.maxEntries) {
|
|
136066
|
+
this.logBuffer.shift();
|
|
136067
|
+
}
|
|
136068
|
+
if (!this.filterMode || !this.searchQuery) {
|
|
136069
|
+
this.writeLogEntry(entry);
|
|
136070
|
+
} else if (this.entryMatchesFilter(entry)) {
|
|
136071
|
+
this.trailingHiddenCount = 0;
|
|
136072
|
+
this.writeLogEntry(entry);
|
|
136073
|
+
} else {
|
|
136074
|
+
this.updateTrailingPlaceholder();
|
|
136075
|
+
}
|
|
136076
|
+
this.updateMetrics(entry.level);
|
|
136077
|
+
}
|
|
136078
|
+
/**
|
|
136079
|
+
* Add multiple structured log entries
|
|
136080
|
+
*/
|
|
136081
|
+
updateLog(entries) {
|
|
136082
|
+
if (!entries) return;
|
|
136083
|
+
for (const entry of entries) {
|
|
136084
|
+
this.logBuffer.push(entry);
|
|
136085
|
+
if (this.logBuffer.length > this.maxEntries) {
|
|
136086
|
+
this.logBuffer.shift();
|
|
136087
|
+
}
|
|
136088
|
+
if (!this.filterMode || !this.searchQuery) {
|
|
136089
|
+
this.writeLogEntry(entry);
|
|
136090
|
+
} else if (this.entryMatchesFilter(entry)) {
|
|
136091
|
+
this.trailingHiddenCount = 0;
|
|
136092
|
+
this.writeLogEntry(entry);
|
|
136093
|
+
} else {
|
|
136094
|
+
this.updateTrailingPlaceholder();
|
|
136095
|
+
}
|
|
136096
|
+
this.updateMetrics(entry.level);
|
|
136097
|
+
}
|
|
136098
|
+
}
|
|
136099
|
+
/**
|
|
136100
|
+
* Update the trailing hidden placeholder in real-time
|
|
136101
|
+
* Clears the last line if a placeholder already exists, then writes updated count
|
|
136102
|
+
*/
|
|
136103
|
+
updateTrailingPlaceholder() {
|
|
136104
|
+
if (!this.terminal) return;
|
|
136105
|
+
if (this.trailingHiddenCount > 0) {
|
|
136106
|
+
this.terminal.write("\x1B[1A\x1B[2K\r");
|
|
136107
|
+
}
|
|
136108
|
+
this.trailingHiddenCount++;
|
|
136109
|
+
this.writeHiddenPlaceholder(this.trailingHiddenCount);
|
|
136110
|
+
if (this.autoScroll) {
|
|
136111
|
+
this.terminal.scrollToBottom();
|
|
136112
|
+
}
|
|
136113
|
+
}
|
|
136114
|
+
/**
|
|
136115
|
+
* Check if a log entry matches the current filter
|
|
136116
|
+
*/
|
|
136117
|
+
entryMatchesFilter(entry) {
|
|
136118
|
+
if (!this.searchQuery) return true;
|
|
136119
|
+
const query4 = this.searchQuery.toLowerCase();
|
|
136120
|
+
return entry.message.toLowerCase().includes(query4) || entry.level.toLowerCase().includes(query4) || (entry.source?.toLowerCase().includes(query4) ?? false);
|
|
136121
|
+
}
|
|
136122
|
+
writeLogEntry(entry) {
|
|
136123
|
+
if (!this.terminal) return;
|
|
136124
|
+
const formatted = this.formatLogEntry(entry);
|
|
136125
|
+
this.terminal.writeln(formatted);
|
|
136126
|
+
if (this.autoScroll) {
|
|
136127
|
+
this.terminal.scrollToBottom();
|
|
136128
|
+
}
|
|
136129
|
+
}
|
|
136130
|
+
formatLogEntry(entry) {
|
|
136131
|
+
const timestamp2 = this.formatTimestamp(entry.timestamp);
|
|
136132
|
+
const levelColors = {
|
|
136133
|
+
debug: "\x1B[90m",
|
|
136134
|
+
// Gray
|
|
136135
|
+
info: "\x1B[36m",
|
|
136136
|
+
// Cyan
|
|
136137
|
+
warn: "\x1B[33m",
|
|
136138
|
+
// Yellow
|
|
136139
|
+
error: "\x1B[31m",
|
|
136140
|
+
// Red
|
|
136141
|
+
success: "\x1B[32m"
|
|
136142
|
+
// Green
|
|
136143
|
+
};
|
|
136144
|
+
const reset = "\x1B[0m";
|
|
136145
|
+
const dim = "\x1B[2m";
|
|
136146
|
+
const levelStr = `${levelColors[entry.level]}[${entry.level.toUpperCase().padEnd(7)}]${reset}`;
|
|
136147
|
+
const sourceStr = entry.source ? `${dim}[${entry.source}]${reset} ` : "";
|
|
136148
|
+
const messageStr = this.applyHighlights(entry.message);
|
|
136149
|
+
return `${dim}${timestamp2}${reset} ${levelStr} ${sourceStr}${messageStr}`;
|
|
136150
|
+
}
|
|
136151
|
+
formatTimestamp(isoString) {
|
|
136152
|
+
const date = new Date(isoString);
|
|
136153
|
+
return date.toLocaleTimeString("en-US", {
|
|
135231
136154
|
hour12: false,
|
|
135232
136155
|
hour: "2-digit",
|
|
135233
136156
|
minute: "2-digit",
|
|
135234
136157
|
second: "2-digit",
|
|
135235
136158
|
fractionalSecondDigits: 3
|
|
135236
136159
|
});
|
|
135237
|
-
return b2`
|
|
135238
|
-
<div class="logEntry">
|
|
135239
|
-
<span class="timestamp">${timestamp2}</span>
|
|
135240
|
-
<span class="level ${entry.level}">${entry.level}</span>
|
|
135241
|
-
${entry.source ? b2`<span class="source">[${entry.source}]</span>` : ""}
|
|
135242
|
-
<span class="message">${entry.message}</span>
|
|
135243
|
-
</div>
|
|
135244
|
-
`;
|
|
135245
136160
|
}
|
|
135246
|
-
|
|
135247
|
-
|
|
135248
|
-
this.
|
|
135249
|
-
|
|
135250
|
-
|
|
135251
|
-
|
|
135252
|
-
|
|
135253
|
-
|
|
135254
|
-
|
|
135255
|
-
|
|
135256
|
-
|
|
135257
|
-
|
|
135258
|
-
|
|
135259
|
-
|
|
135260
|
-
|
|
135261
|
-
|
|
135262
|
-
|
|
135263
|
-
|
|
135264
|
-
|
|
135265
|
-
|
|
135266
|
-
|
|
136161
|
+
applyHighlights(text9) {
|
|
136162
|
+
const keywords = [...this.highlightKeywords];
|
|
136163
|
+
if (this.filterMode && this.searchQuery) {
|
|
136164
|
+
keywords.push(this.searchQuery);
|
|
136165
|
+
}
|
|
136166
|
+
if (keywords.length === 0) return text9;
|
|
136167
|
+
let result = text9;
|
|
136168
|
+
for (const keyword of keywords) {
|
|
136169
|
+
const escaped = keyword.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
136170
|
+
const regex = new RegExp(`(${escaped})`, "gi");
|
|
136171
|
+
result = result.replace(regex, "\x1B[43m\x1B[30m$1\x1B[0m");
|
|
136172
|
+
}
|
|
136173
|
+
return result;
|
|
136174
|
+
}
|
|
136175
|
+
// =====================
|
|
136176
|
+
// Raw Log Methods
|
|
136177
|
+
// =====================
|
|
136178
|
+
/**
|
|
136179
|
+
* Write raw data to the terminal (for Docker logs, etc.)
|
|
136180
|
+
*/
|
|
136181
|
+
writeRaw(data) {
|
|
136182
|
+
if (!this.terminal) return;
|
|
136183
|
+
this.terminal.write(data);
|
|
136184
|
+
this.recordLogEvent();
|
|
136185
|
+
if (this.autoScroll) {
|
|
136186
|
+
this.terminal.scrollToBottom();
|
|
136187
|
+
}
|
|
136188
|
+
}
|
|
136189
|
+
/**
|
|
136190
|
+
* Write a raw line to the terminal
|
|
136191
|
+
*/
|
|
136192
|
+
writelnRaw(line) {
|
|
136193
|
+
if (!this.terminal) return;
|
|
136194
|
+
this.terminal.writeln(line);
|
|
136195
|
+
this.recordLogEvent();
|
|
136196
|
+
if (this.autoScroll) {
|
|
136197
|
+
this.terminal.scrollToBottom();
|
|
136198
|
+
}
|
|
136199
|
+
}
|
|
136200
|
+
// =====================
|
|
136201
|
+
// Search Methods
|
|
136202
|
+
// =====================
|
|
136203
|
+
handleSearchInput(e11) {
|
|
136204
|
+
const input = e11.target;
|
|
136205
|
+
const newQuery = input.value;
|
|
136206
|
+
const queryChanged = this.searchQuery !== newQuery;
|
|
136207
|
+
this.searchQuery = newQuery;
|
|
136208
|
+
if (this.filterMode && queryChanged) {
|
|
136209
|
+
this.reRenderFilteredLogs();
|
|
136210
|
+
} else if (this.searchQuery) {
|
|
136211
|
+
this.searchAddon?.findNext(this.searchQuery);
|
|
136212
|
+
}
|
|
136213
|
+
}
|
|
136214
|
+
handleSearchKeydown(e11) {
|
|
136215
|
+
if (e11.key === "Enter") {
|
|
136216
|
+
if (e11.shiftKey) {
|
|
136217
|
+
this.searchPrevious();
|
|
136218
|
+
} else {
|
|
136219
|
+
this.searchNext();
|
|
135267
136220
|
}
|
|
135268
|
-
|
|
135269
|
-
|
|
135270
|
-
|
|
135271
|
-
|
|
136221
|
+
} else if (e11.key === "Escape") {
|
|
136222
|
+
this.searchQuery = "";
|
|
136223
|
+
e11.target.value = "";
|
|
136224
|
+
}
|
|
136225
|
+
}
|
|
136226
|
+
/**
|
|
136227
|
+
* Search for a query in the terminal
|
|
136228
|
+
*/
|
|
136229
|
+
search(query4) {
|
|
136230
|
+
this.searchQuery = query4;
|
|
136231
|
+
this.searchAddon?.findNext(query4);
|
|
136232
|
+
}
|
|
136233
|
+
/**
|
|
136234
|
+
* Find next search match
|
|
136235
|
+
*/
|
|
136236
|
+
searchNext() {
|
|
136237
|
+
if (this.searchQuery) {
|
|
136238
|
+
this.searchAddon?.findNext(this.searchQuery);
|
|
136239
|
+
}
|
|
136240
|
+
}
|
|
136241
|
+
/**
|
|
136242
|
+
* Find previous search match
|
|
136243
|
+
*/
|
|
136244
|
+
searchPrevious() {
|
|
136245
|
+
if (this.searchQuery) {
|
|
136246
|
+
this.searchAddon?.findPrevious(this.searchQuery);
|
|
136247
|
+
}
|
|
136248
|
+
}
|
|
136249
|
+
// =====================
|
|
136250
|
+
// Control Methods
|
|
136251
|
+
// =====================
|
|
136252
|
+
toggleAutoScroll() {
|
|
136253
|
+
this.autoScroll = !this.autoScroll;
|
|
136254
|
+
if (this.autoScroll && this.terminal) {
|
|
136255
|
+
this.terminal.scrollToBottom();
|
|
136256
|
+
}
|
|
136257
|
+
}
|
|
136258
|
+
/**
|
|
136259
|
+
* Toggle between filter mode and highlight mode
|
|
136260
|
+
*/
|
|
136261
|
+
toggleFilterMode() {
|
|
136262
|
+
this.filterMode = !this.filterMode;
|
|
136263
|
+
this.reRenderFilteredLogs();
|
|
136264
|
+
}
|
|
136265
|
+
/**
|
|
136266
|
+
* Re-render logs based on current filter state
|
|
136267
|
+
* In filter mode: show matching logs with placeholders for hidden entries
|
|
136268
|
+
* In highlight mode: show all logs
|
|
136269
|
+
*/
|
|
136270
|
+
reRenderFilteredLogs() {
|
|
136271
|
+
if (!this.terminal) return;
|
|
136272
|
+
this.terminal.clear();
|
|
136273
|
+
this.trailingHiddenCount = 0;
|
|
136274
|
+
if (!this.filterMode || !this.searchQuery) {
|
|
136275
|
+
for (const entry of this.logBuffer) {
|
|
136276
|
+
const formatted = this.formatLogEntry(entry);
|
|
136277
|
+
this.terminal.writeln(formatted);
|
|
135272
136278
|
}
|
|
136279
|
+
} else {
|
|
136280
|
+
let hiddenCount = 0;
|
|
136281
|
+
for (const entry of this.logBuffer) {
|
|
136282
|
+
if (this.entryMatchesFilter(entry)) {
|
|
136283
|
+
if (hiddenCount > 0) {
|
|
136284
|
+
this.writeHiddenPlaceholder(hiddenCount);
|
|
136285
|
+
hiddenCount = 0;
|
|
136286
|
+
}
|
|
136287
|
+
const formatted = this.formatLogEntry(entry);
|
|
136288
|
+
this.terminal.writeln(formatted);
|
|
136289
|
+
} else {
|
|
136290
|
+
hiddenCount++;
|
|
136291
|
+
}
|
|
136292
|
+
}
|
|
136293
|
+
if (hiddenCount > 0) {
|
|
136294
|
+
this.writeHiddenPlaceholder(hiddenCount);
|
|
136295
|
+
this.trailingHiddenCount = hiddenCount;
|
|
136296
|
+
}
|
|
136297
|
+
}
|
|
136298
|
+
if (this.autoScroll) {
|
|
136299
|
+
this.terminal.scrollToBottom();
|
|
135273
136300
|
}
|
|
135274
136301
|
}
|
|
136302
|
+
/**
|
|
136303
|
+
* Write a placeholder line showing how many log entries are hidden by filter
|
|
136304
|
+
*/
|
|
136305
|
+
writeHiddenPlaceholder(count2) {
|
|
136306
|
+
const dim = "\x1B[2m";
|
|
136307
|
+
const reset = "\x1B[0m";
|
|
136308
|
+
const text9 = count2 === 1 ? `[1 log line hidden by filter ...]` : `[${count2} log lines hidden by filter ...]`;
|
|
136309
|
+
this.terminal?.writeln(`${dim}${text9}${reset}`);
|
|
136310
|
+
}
|
|
136311
|
+
/**
|
|
136312
|
+
* Clear all logs and reset metrics
|
|
136313
|
+
*/
|
|
135275
136314
|
clearLogs() {
|
|
135276
|
-
this.
|
|
135277
|
-
this.
|
|
136315
|
+
this.terminal?.clear();
|
|
136316
|
+
this.logBuffer = [];
|
|
136317
|
+
this.trailingHiddenCount = 0;
|
|
136318
|
+
this.resetMetrics();
|
|
135278
136319
|
}
|
|
136320
|
+
/**
|
|
136321
|
+
* Scroll to the bottom of the log
|
|
136322
|
+
*/
|
|
135279
136323
|
scrollToBottom() {
|
|
135280
|
-
|
|
135281
|
-
this.logContainer.scrollTop = this.logContainer.scrollHeight;
|
|
135282
|
-
}
|
|
136324
|
+
this.terminal?.scrollToBottom();
|
|
135283
136325
|
}
|
|
135284
|
-
|
|
135285
|
-
|
|
135286
|
-
|
|
135287
|
-
|
|
135288
|
-
|
|
135289
|
-
|
|
136326
|
+
// =====================
|
|
136327
|
+
// Metrics Methods
|
|
136328
|
+
// =====================
|
|
136329
|
+
updateMetrics(level) {
|
|
136330
|
+
this.metrics = {
|
|
136331
|
+
...this.metrics,
|
|
136332
|
+
[level]: this.metrics[level] + 1,
|
|
136333
|
+
total: this.metrics.total + 1
|
|
135290
136334
|
};
|
|
135291
|
-
this.
|
|
136335
|
+
this.recordLogEvent();
|
|
136336
|
+
}
|
|
136337
|
+
recordLogEvent() {
|
|
136338
|
+
this.rateBuffer.push(Date.now());
|
|
136339
|
+
}
|
|
136340
|
+
calculateRate() {
|
|
136341
|
+
const now2 = Date.now();
|
|
136342
|
+
this.rateBuffer = this.rateBuffer.filter((t9) => now2 - t9 < 1e4);
|
|
136343
|
+
const rate = this.rateBuffer.length / 10;
|
|
136344
|
+
if (rate !== this.metrics.rate) {
|
|
136345
|
+
this.metrics = { ...this.metrics, rate };
|
|
136346
|
+
}
|
|
136347
|
+
}
|
|
136348
|
+
resetMetrics() {
|
|
136349
|
+
this.metrics = { debug: 0, info: 0, warn: 0, error: 0, success: 0, total: 0, rate: 0 };
|
|
136350
|
+
this.rateBuffer = [];
|
|
136351
|
+
}
|
|
136352
|
+
// =====================
|
|
136353
|
+
// Lifecycle
|
|
136354
|
+
// =====================
|
|
136355
|
+
async disconnectedCallback() {
|
|
136356
|
+
await super.disconnectedCallback();
|
|
136357
|
+
if (this.resizeObserver) {
|
|
136358
|
+
this.resizeObserver.disconnect();
|
|
136359
|
+
}
|
|
136360
|
+
if (this.terminalThemeSubscription) {
|
|
136361
|
+
this.terminalThemeSubscription.unsubscribe();
|
|
136362
|
+
}
|
|
136363
|
+
if (this.rateInterval) {
|
|
136364
|
+
clearInterval(this.rateInterval);
|
|
136365
|
+
}
|
|
136366
|
+
if (this.terminal) {
|
|
136367
|
+
this.terminal.dispose();
|
|
136368
|
+
}
|
|
135292
136369
|
}
|
|
135293
136370
|
};
|
|
135294
136371
|
_init47 = __decoratorStart(_a45);
|
|
135295
136372
|
_label6 = new WeakMap();
|
|
136373
|
+
_mode = new WeakMap();
|
|
135296
136374
|
_logEntries = new WeakMap();
|
|
135297
136375
|
_autoScroll = new WeakMap();
|
|
135298
136376
|
_maxEntries = new WeakMap();
|
|
136377
|
+
_highlightKeywords = new WeakMap();
|
|
136378
|
+
_showMetrics = new WeakMap();
|
|
136379
|
+
_searchQuery2 = new WeakMap();
|
|
136380
|
+
_filterMode = new WeakMap();
|
|
136381
|
+
_metrics = new WeakMap();
|
|
136382
|
+
_terminalReady = new WeakMap();
|
|
135299
136383
|
__decorateElement(_init47, 4, "label", _label_dec6, DeesChartLog, _label6);
|
|
136384
|
+
__decorateElement(_init47, 4, "mode", _mode_dec, DeesChartLog, _mode);
|
|
135300
136385
|
__decorateElement(_init47, 4, "logEntries", _logEntries_dec, DeesChartLog, _logEntries);
|
|
135301
136386
|
__decorateElement(_init47, 4, "autoScroll", _autoScroll_dec, DeesChartLog, _autoScroll);
|
|
135302
136387
|
__decorateElement(_init47, 4, "maxEntries", _maxEntries_dec, DeesChartLog, _maxEntries);
|
|
136388
|
+
__decorateElement(_init47, 4, "highlightKeywords", _highlightKeywords_dec, DeesChartLog, _highlightKeywords);
|
|
136389
|
+
__decorateElement(_init47, 4, "showMetrics", _showMetrics_dec, DeesChartLog, _showMetrics);
|
|
136390
|
+
__decorateElement(_init47, 4, "searchQuery", _searchQuery_dec2, DeesChartLog, _searchQuery2);
|
|
136391
|
+
__decorateElement(_init47, 4, "filterMode", _filterMode_dec, DeesChartLog, _filterMode);
|
|
136392
|
+
__decorateElement(_init47, 4, "metrics", _metrics_dec, DeesChartLog, _metrics);
|
|
136393
|
+
__decorateElement(_init47, 4, "terminalReady", _terminalReady_dec, DeesChartLog, _terminalReady);
|
|
135303
136394
|
DeesChartLog = __decorateElement(_init47, 0, "DeesChartLog", _DeesChartLog_decorators, DeesChartLog);
|
|
135304
136395
|
__publicField(DeesChartLog, "demo", demoFunc33);
|
|
135305
136396
|
__publicField(DeesChartLog, "demoGroup", "Chart");
|
|
@@ -135307,13 +136398,12 @@ __publicField(DeesChartLog, "styles", [
|
|
|
135307
136398
|
themeDefaultStyles,
|
|
135308
136399
|
cssManager.defaultStyles,
|
|
135309
136400
|
i`
|
|
135310
|
-
/* TODO: Migrate hardcoded values to --dees-* CSS variables */
|
|
135311
136401
|
:host {
|
|
135312
|
-
|
|
136402
|
+
display: block;
|
|
136403
|
+
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
|
135313
136404
|
color: ${cssManager.bdTheme("hsl(0 0% 3.9%)", "hsl(0 0% 98%)")};
|
|
135314
|
-
font-size: 12px;
|
|
135315
|
-
line-height: 1.5;
|
|
135316
136405
|
}
|
|
136406
|
+
|
|
135317
136407
|
.mainbox {
|
|
135318
136408
|
position: relative;
|
|
135319
136409
|
width: 100%;
|
|
@@ -135328,143 +136418,197 @@ __publicField(DeesChartLog, "styles", [
|
|
|
135328
136418
|
|
|
135329
136419
|
.header {
|
|
135330
136420
|
background: ${cssManager.bdTheme("hsl(0 0% 97%)", "hsl(0 0% 7%)")};
|
|
135331
|
-
padding: 12px
|
|
136421
|
+
padding: 8px 12px;
|
|
135332
136422
|
border-bottom: 1px solid ${cssManager.bdTheme("hsl(0 0% 89.8%)", "hsl(0 0% 14.9%)")};
|
|
135333
136423
|
display: flex;
|
|
135334
|
-
justify-content: space-between;
|
|
135335
136424
|
align-items: center;
|
|
136425
|
+
gap: 12px;
|
|
135336
136426
|
flex-shrink: 0;
|
|
136427
|
+
flex-wrap: wrap;
|
|
135337
136428
|
}
|
|
135338
136429
|
|
|
135339
136430
|
.title {
|
|
135340
136431
|
font-weight: 500;
|
|
135341
136432
|
font-size: 14px;
|
|
135342
136433
|
color: ${cssManager.bdTheme("hsl(0 0% 9%)", "hsl(0 0% 95%)")};
|
|
135343
|
-
|
|
136434
|
+
white-space: nowrap;
|
|
135344
136435
|
}
|
|
135345
136436
|
|
|
135346
|
-
.
|
|
136437
|
+
.search-box {
|
|
135347
136438
|
display: flex;
|
|
135348
|
-
|
|
136439
|
+
align-items: center;
|
|
136440
|
+
gap: 4px;
|
|
136441
|
+
flex: 1;
|
|
136442
|
+
min-width: 150px;
|
|
136443
|
+
max-width: 300px;
|
|
135349
136444
|
}
|
|
135350
136445
|
|
|
135351
|
-
.
|
|
135352
|
-
|
|
135353
|
-
|
|
135354
|
-
border-radius: 6px;
|
|
135355
|
-
padding: 6px 12px;
|
|
135356
|
-
color: ${cssManager.bdTheme("hsl(0 0% 45.1%)", "hsl(0 0% 63.9%)")};
|
|
135357
|
-
cursor: pointer;
|
|
136446
|
+
.search-box input {
|
|
136447
|
+
flex: 1;
|
|
136448
|
+
padding: 4px 8px;
|
|
135358
136449
|
font-size: 12px;
|
|
135359
|
-
|
|
135360
|
-
|
|
135361
|
-
|
|
135362
|
-
|
|
135363
|
-
|
|
135364
|
-
.control-button:hover {
|
|
135365
|
-
background: ${cssManager.bdTheme("hsl(0 0% 95.1%)", "hsl(0 0% 14.9%)")};
|
|
135366
|
-
border-color: ${cssManager.bdTheme("hsl(0 0% 79.8%)", "hsl(0 0% 20.9%)")};
|
|
135367
|
-
color: ${cssManager.bdTheme("hsl(0 0% 15%)", "hsl(0 0% 93.9%)")};
|
|
136450
|
+
border: 1px solid ${cssManager.bdTheme("hsl(0 0% 89.8%)", "hsl(0 0% 14.9%)")};
|
|
136451
|
+
border-radius: 4px;
|
|
136452
|
+
background: ${cssManager.bdTheme("hsl(0 0% 100%)", "hsl(0 0% 9%)")};
|
|
136453
|
+
color: ${cssManager.bdTheme("hsl(0 0% 9%)", "hsl(0 0% 95%)")};
|
|
136454
|
+
outline: none;
|
|
135368
136455
|
}
|
|
135369
136456
|
|
|
135370
|
-
.
|
|
135371
|
-
|
|
135372
|
-
color: ${cssManager.bdTheme("hsl(0 0% 98%)", "hsl(0 0% 3.9%)")};
|
|
136457
|
+
.search-box input:focus {
|
|
136458
|
+
border-color: ${cssManager.bdTheme("hsl(222.2 47.4% 51.2%)", "hsl(217.2 91.2% 59.8%)")};
|
|
135373
136459
|
}
|
|
135374
136460
|
|
|
135375
|
-
.
|
|
135376
|
-
|
|
135377
|
-
overflow-y: auto;
|
|
135378
|
-
overflow-x: hidden;
|
|
135379
|
-
padding: 16px;
|
|
135380
|
-
font-size: 12px;
|
|
136461
|
+
.search-box input::placeholder {
|
|
136462
|
+
color: ${cssManager.bdTheme("hsl(0 0% 63.9%)", "hsl(0 0% 45.1%)")};
|
|
135381
136463
|
}
|
|
135382
136464
|
|
|
135383
|
-
.
|
|
135384
|
-
margin-bottom: 4px;
|
|
136465
|
+
.search-nav {
|
|
135385
136466
|
display: flex;
|
|
135386
|
-
|
|
135387
|
-
word-break: break-all;
|
|
135388
|
-
font-variant-numeric: tabular-nums;
|
|
136467
|
+
gap: 2px;
|
|
135389
136468
|
}
|
|
135390
136469
|
|
|
135391
|
-
.
|
|
135392
|
-
|
|
135393
|
-
|
|
135394
|
-
|
|
136470
|
+
.search-nav button {
|
|
136471
|
+
padding: 4px 6px;
|
|
136472
|
+
font-size: 11px;
|
|
136473
|
+
background: ${cssManager.bdTheme("hsl(0 0% 100%)", "hsl(0 0% 14.9%)")};
|
|
136474
|
+
border: 1px solid ${cssManager.bdTheme("hsl(0 0% 89.8%)", "hsl(0 0% 14.9%)")};
|
|
136475
|
+
border-radius: 3px;
|
|
136476
|
+
color: ${cssManager.bdTheme("hsl(0 0% 45.1%)", "hsl(0 0% 63.9%)")};
|
|
136477
|
+
cursor: pointer;
|
|
136478
|
+
line-height: 1;
|
|
135395
136479
|
}
|
|
135396
136480
|
|
|
135397
|
-
.
|
|
135398
|
-
|
|
135399
|
-
|
|
135400
|
-
border-radius: 3px;
|
|
135401
|
-
font-weight: 600;
|
|
135402
|
-
text-transform: uppercase;
|
|
135403
|
-
font-size: 10px;
|
|
135404
|
-
flex-shrink: 0;
|
|
136481
|
+
.search-nav button:hover {
|
|
136482
|
+
background: ${cssManager.bdTheme("hsl(0 0% 95.1%)", "hsl(0 0% 20%)")};
|
|
136483
|
+
color: ${cssManager.bdTheme("hsl(0 0% 15%)", "hsl(0 0% 93.9%)")};
|
|
135405
136484
|
}
|
|
135406
136485
|
|
|
135407
|
-
.
|
|
136486
|
+
.filter-toggle {
|
|
136487
|
+
padding: 4px 8px;
|
|
136488
|
+
font-size: 11px;
|
|
136489
|
+
font-weight: 500;
|
|
136490
|
+
background: ${cssManager.bdTheme("hsl(0 0% 100%)", "hsl(0 0% 14.9%)")};
|
|
136491
|
+
border: 1px solid ${cssManager.bdTheme("hsl(0 0% 89.8%)", "hsl(0 0% 14.9%)")};
|
|
136492
|
+
border-radius: 4px;
|
|
135408
136493
|
color: ${cssManager.bdTheme("hsl(0 0% 45.1%)", "hsl(0 0% 63.9%)")};
|
|
135409
|
-
|
|
136494
|
+
cursor: pointer;
|
|
136495
|
+
transition: all 0.15s;
|
|
136496
|
+
white-space: nowrap;
|
|
135410
136497
|
}
|
|
135411
136498
|
|
|
135412
|
-
.
|
|
135413
|
-
|
|
135414
|
-
|
|
136499
|
+
.filter-toggle:hover {
|
|
136500
|
+
background: ${cssManager.bdTheme("hsl(0 0% 95.1%)", "hsl(0 0% 20%)")};
|
|
136501
|
+
color: ${cssManager.bdTheme("hsl(0 0% 15%)", "hsl(0 0% 93.9%)")};
|
|
135415
136502
|
}
|
|
135416
136503
|
|
|
135417
|
-
.
|
|
135418
|
-
|
|
135419
|
-
|
|
136504
|
+
.filter-toggle.active {
|
|
136505
|
+
background: ${cssManager.bdTheme("hsl(45 93% 47%)", "hsl(45 93% 47%)")};
|
|
136506
|
+
border-color: ${cssManager.bdTheme("hsl(45 93% 47%)", "hsl(45 93% 47%)")};
|
|
136507
|
+
color: hsl(0 0% 9%);
|
|
135420
136508
|
}
|
|
135421
136509
|
|
|
135422
|
-
.
|
|
135423
|
-
|
|
135424
|
-
|
|
136510
|
+
.controls {
|
|
136511
|
+
display: flex;
|
|
136512
|
+
gap: 6px;
|
|
136513
|
+
margin-left: auto;
|
|
135425
136514
|
}
|
|
135426
136515
|
|
|
135427
|
-
.
|
|
135428
|
-
|
|
135429
|
-
|
|
136516
|
+
.control-button {
|
|
136517
|
+
background: ${cssManager.bdTheme("hsl(0 0% 100%)", "hsl(0 0% 14.9%)")};
|
|
136518
|
+
border: 1px solid ${cssManager.bdTheme("hsl(0 0% 89.8%)", "hsl(0 0% 14.9%)")};
|
|
136519
|
+
border-radius: 4px;
|
|
136520
|
+
padding: 4px 10px;
|
|
136521
|
+
color: ${cssManager.bdTheme("hsl(0 0% 45.1%)", "hsl(0 0% 63.9%)")};
|
|
136522
|
+
cursor: pointer;
|
|
136523
|
+
font-size: 12px;
|
|
136524
|
+
font-weight: 500;
|
|
136525
|
+
transition: all 0.15s;
|
|
135430
136526
|
}
|
|
135431
136527
|
|
|
135432
|
-
.
|
|
135433
|
-
|
|
135434
|
-
|
|
135435
|
-
|
|
136528
|
+
.control-button:hover {
|
|
136529
|
+
background: ${cssManager.bdTheme("hsl(0 0% 95.1%)", "hsl(0 0% 20%)")};
|
|
136530
|
+
border-color: ${cssManager.bdTheme("hsl(0 0% 79.8%)", "hsl(0 0% 25%)")};
|
|
136531
|
+
color: ${cssManager.bdTheme("hsl(0 0% 15%)", "hsl(0 0% 93.9%)")};
|
|
135436
136532
|
}
|
|
135437
136533
|
|
|
135438
|
-
.
|
|
135439
|
-
|
|
136534
|
+
.control-button.active {
|
|
136535
|
+
background: ${cssManager.bdTheme("hsl(222.2 47.4% 51.2%)", "hsl(217.2 91.2% 59.8%)")};
|
|
136536
|
+
border-color: ${cssManager.bdTheme("hsl(222.2 47.4% 51.2%)", "hsl(217.2 91.2% 59.8%)")};
|
|
136537
|
+
color: white;
|
|
136538
|
+
}
|
|
136539
|
+
|
|
136540
|
+
.terminal-container {
|
|
135440
136541
|
flex: 1;
|
|
136542
|
+
overflow: hidden;
|
|
136543
|
+
padding: 8px;
|
|
136544
|
+
background: ${cssManager.bdTheme("hsl(0 0% 100%)", "hsl(0 0% 3.9%)")};
|
|
135441
136545
|
}
|
|
135442
136546
|
|
|
135443
|
-
.
|
|
136547
|
+
.terminal-container .xterm {
|
|
136548
|
+
height: 100%;
|
|
136549
|
+
}
|
|
136550
|
+
|
|
136551
|
+
.loading-state {
|
|
135444
136552
|
display: flex;
|
|
135445
136553
|
align-items: center;
|
|
135446
136554
|
justify-content: center;
|
|
135447
136555
|
height: 100%;
|
|
135448
136556
|
color: ${cssManager.bdTheme("hsl(0 0% 45.1%)", "hsl(0 0% 63.9%)")};
|
|
135449
136557
|
font-style: italic;
|
|
136558
|
+
font-size: 13px;
|
|
136559
|
+
}
|
|
136560
|
+
|
|
136561
|
+
.metrics-bar {
|
|
136562
|
+
background: ${cssManager.bdTheme("hsl(0 0% 97%)", "hsl(0 0% 7%)")};
|
|
136563
|
+
border-top: 1px solid ${cssManager.bdTheme("hsl(0 0% 89.8%)", "hsl(0 0% 14.9%)")};
|
|
136564
|
+
padding: 6px 12px;
|
|
136565
|
+
display: flex;
|
|
136566
|
+
gap: 16px;
|
|
136567
|
+
font-size: 11px;
|
|
136568
|
+
font-weight: 500;
|
|
136569
|
+
flex-shrink: 0;
|
|
135450
136570
|
}
|
|
135451
136571
|
|
|
135452
|
-
|
|
135453
|
-
|
|
136572
|
+
.metric {
|
|
136573
|
+
display: flex;
|
|
136574
|
+
align-items: center;
|
|
136575
|
+
gap: 4px;
|
|
136576
|
+
}
|
|
136577
|
+
|
|
136578
|
+
.metric::before {
|
|
136579
|
+
content: '';
|
|
135454
136580
|
width: 8px;
|
|
136581
|
+
height: 8px;
|
|
136582
|
+
border-radius: 50%;
|
|
136583
|
+
}
|
|
136584
|
+
|
|
136585
|
+
.metric.error::before {
|
|
136586
|
+
background: hsl(0 84.2% 60.2%);
|
|
135455
136587
|
}
|
|
135456
136588
|
|
|
135457
|
-
.
|
|
135458
|
-
background:
|
|
136589
|
+
.metric.warn::before {
|
|
136590
|
+
background: hsl(25 95% 53%);
|
|
135459
136591
|
}
|
|
135460
136592
|
|
|
135461
|
-
.
|
|
135462
|
-
background:
|
|
135463
|
-
border-radius: 4px;
|
|
136593
|
+
.metric.info::before {
|
|
136594
|
+
background: hsl(222.2 47.4% 51.2%);
|
|
135464
136595
|
}
|
|
135465
136596
|
|
|
135466
|
-
.
|
|
135467
|
-
background:
|
|
136597
|
+
.metric.success::before {
|
|
136598
|
+
background: hsl(142.1 76.2% 36.3%);
|
|
136599
|
+
}
|
|
136600
|
+
|
|
136601
|
+
.metric.debug::before {
|
|
136602
|
+
background: hsl(0 0% 63.9%);
|
|
136603
|
+
}
|
|
136604
|
+
|
|
136605
|
+
.metric.rate {
|
|
136606
|
+
margin-left: auto;
|
|
136607
|
+
color: ${cssManager.bdTheme("hsl(0 0% 45.1%)", "hsl(0 0% 63.9%)")};
|
|
136608
|
+
}
|
|
136609
|
+
|
|
136610
|
+
.metric.rate::before {
|
|
136611
|
+
display: none;
|
|
135468
136612
|
}
|
|
135469
136613
|
`
|
|
135470
136614
|
]);
|
|
@@ -159358,9 +160502,9 @@ var openWidgetContextMenu = ({
|
|
|
159358
160502
|
// ts_web/elements/dees-dashboardgrid/dees-dashboardgrid.ts
|
|
159359
160503
|
init_dist_ts26();
|
|
159360
160504
|
init_dees_icon();
|
|
159361
|
-
var _previewWidgets_dec, _resolvedMargins_dec,
|
|
160505
|
+
var _previewWidgets_dec, _resolvedMargins_dec, _metrics_dec2, _placeholderPosition_dec, _activeBreakpoint_dec, _layouts_dec, _showGridLines_dec, _rtl_dec, _cellHeightUnit_dec, _enableAnimation_dec, _editable_dec, _columns_dec2, _margin_dec, _cellHeight_dec, _widgets_dec2, _a75, _DeesDashboardgrid_decorators, _init78, _widgets2, _cellHeight, _margin, _columns2, _editable, _enableAnimation, _cellHeightUnit, _rtl, _showGridLines, _layouts, _activeBreakpoint, _placeholderPosition, _metrics2, _resolvedMargins, _previewWidgets;
|
|
159362
160506
|
_DeesDashboardgrid_decorators = [t4("dees-dashboardgrid")];
|
|
159363
|
-
var DeesDashboardgrid = class extends (_a75 = DeesElement, _widgets_dec2 = [n5({ type: Array })], _cellHeight_dec = [n5({ type: Number })], _margin_dec = [n5({ type: Object })], _columns_dec2 = [n5({ type: Number })], _editable_dec = [n5({ type: Boolean })], _enableAnimation_dec = [n5({ type: Boolean, reflect: true })], _cellHeightUnit_dec = [n5({ type: String })], _rtl_dec = [n5({ type: Boolean })], _showGridLines_dec = [n5({ type: Boolean })], _layouts_dec = [n5({ attribute: false })], _activeBreakpoint_dec = [n5({ type: String })], _placeholderPosition_dec = [r5()],
|
|
160507
|
+
var DeesDashboardgrid = class extends (_a75 = DeesElement, _widgets_dec2 = [n5({ type: Array })], _cellHeight_dec = [n5({ type: Number })], _margin_dec = [n5({ type: Object })], _columns_dec2 = [n5({ type: Number })], _editable_dec = [n5({ type: Boolean })], _enableAnimation_dec = [n5({ type: Boolean, reflect: true })], _cellHeightUnit_dec = [n5({ type: String })], _rtl_dec = [n5({ type: Boolean })], _showGridLines_dec = [n5({ type: Boolean })], _layouts_dec = [n5({ attribute: false })], _activeBreakpoint_dec = [n5({ type: String })], _placeholderPosition_dec = [r5()], _metrics_dec2 = [r5()], _resolvedMargins_dec = [r5()], _previewWidgets_dec = [r5()], _a75) {
|
|
159364
160508
|
constructor() {
|
|
159365
160509
|
super(...arguments);
|
|
159366
160510
|
__privateAdd(this, _widgets2, __runInitializers(_init78, 8, this, [])), __runInitializers(_init78, 11, this);
|
|
@@ -159375,7 +160519,7 @@ var DeesDashboardgrid = class extends (_a75 = DeesElement, _widgets_dec2 = [n5({
|
|
|
159375
160519
|
__privateAdd(this, _layouts, __runInitializers(_init78, 44, this)), __runInitializers(_init78, 47, this);
|
|
159376
160520
|
__privateAdd(this, _activeBreakpoint, __runInitializers(_init78, 48, this, "base")), __runInitializers(_init78, 51, this);
|
|
159377
160521
|
__privateAdd(this, _placeholderPosition, __runInitializers(_init78, 52, this, null)), __runInitializers(_init78, 55, this);
|
|
159378
|
-
__privateAdd(this,
|
|
160522
|
+
__privateAdd(this, _metrics2, __runInitializers(_init78, 56, this, null)), __runInitializers(_init78, 59, this);
|
|
159379
160523
|
__privateAdd(this, _resolvedMargins, __runInitializers(_init78, 60, this, null)), __runInitializers(_init78, 63, this);
|
|
159380
160524
|
__privateAdd(this, _previewWidgets, __runInitializers(_init78, 64, this, null)), __runInitializers(_init78, 67, this);
|
|
159381
160525
|
__publicField(this, "containerBounds", null);
|
|
@@ -159952,7 +161096,7 @@ _showGridLines = new WeakMap();
|
|
|
159952
161096
|
_layouts = new WeakMap();
|
|
159953
161097
|
_activeBreakpoint = new WeakMap();
|
|
159954
161098
|
_placeholderPosition = new WeakMap();
|
|
159955
|
-
|
|
161099
|
+
_metrics2 = new WeakMap();
|
|
159956
161100
|
_resolvedMargins = new WeakMap();
|
|
159957
161101
|
_previewWidgets = new WeakMap();
|
|
159958
161102
|
__decorateElement(_init78, 4, "widgets", _widgets_dec2, DeesDashboardgrid, _widgets2);
|
|
@@ -159967,7 +161111,7 @@ __decorateElement(_init78, 4, "showGridLines", _showGridLines_dec, DeesDashboard
|
|
|
159967
161111
|
__decorateElement(_init78, 4, "layouts", _layouts_dec, DeesDashboardgrid, _layouts);
|
|
159968
161112
|
__decorateElement(_init78, 4, "activeBreakpoint", _activeBreakpoint_dec, DeesDashboardgrid, _activeBreakpoint);
|
|
159969
161113
|
__decorateElement(_init78, 4, "placeholderPosition", _placeholderPosition_dec, DeesDashboardgrid, _placeholderPosition);
|
|
159970
|
-
__decorateElement(_init78, 4, "metrics",
|
|
161114
|
+
__decorateElement(_init78, 4, "metrics", _metrics_dec2, DeesDashboardgrid, _metrics2);
|
|
159971
161115
|
__decorateElement(_init78, 4, "resolvedMargins", _resolvedMargins_dec, DeesDashboardgrid, _resolvedMargins);
|
|
159972
161116
|
__decorateElement(_init78, 4, "previewWidgets", _previewWidgets_dec, DeesDashboardgrid, _previewWidgets);
|
|
159973
161117
|
DeesDashboardgrid = __decorateElement(_init78, 0, "DeesDashboardgrid", _DeesDashboardgrid_decorators, DeesDashboardgrid);
|