@techdocs/cli 0.0.0-nightly-20251126024544 → 0.0.0-nightly-20251128024112
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/CHANGELOG.md +4 -4
- package/dist/embedded-app/.config-schema.json +123 -126
- package/dist/embedded-app/index.html +1 -1
- package/dist/embedded-app/index.html.tmpl +1 -1
- package/dist/embedded-app/static/4591.25e74053.chunk.js +2 -0
- package/dist/embedded-app/static/4591.25e74053.chunk.js.map +1 -0
- package/dist/embedded-app/static/{main.9f641a04.js → main.1e32ff7a.js} +2 -2
- package/dist/embedded-app/static/main.1e32ff7a.js.map +1 -0
- package/dist/embedded-app/static/{runtime.f182b572.js → runtime.b161f61e.js} +2 -2
- package/dist/embedded-app/static/{runtime.f182b572.js.map → runtime.b161f61e.js.map} +1 -1
- package/dist/embedded-app/static/vendor.4b7983a7.js +2 -0
- package/dist/embedded-app/static/vendor.4b7983a7.js.map +1 -0
- package/dist/package.json.cjs.js +1 -1
- package/package.json +5 -5
- package/dist/embedded-app/static/4591.5aa5d796.chunk.js +0 -2
- package/dist/embedded-app/static/4591.5aa5d796.chunk.js.map +0 -1
- package/dist/embedded-app/static/main.9f641a04.js.map +0 -1
- package/dist/embedded-app/static/vendor.18e925a8.js +0 -2
- package/dist/embedded-app/static/vendor.18e925a8.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
# @techdocs/cli
|
|
2
2
|
|
|
3
|
-
## 0.0.0-nightly-
|
|
3
|
+
## 0.0.0-nightly-20251128024112
|
|
4
4
|
|
|
5
5
|
### Patch Changes
|
|
6
6
|
|
|
7
7
|
- Updated dependencies
|
|
8
|
-
- @backstage/backend-defaults@0.0.0-nightly-
|
|
9
|
-
- @backstage/cli-common@0.0.0-nightly-
|
|
10
|
-
- @backstage/plugin-techdocs-node@0.0.0-nightly-
|
|
8
|
+
- @backstage/backend-defaults@0.0.0-nightly-20251128024112
|
|
9
|
+
- @backstage/cli-common@0.0.0-nightly-20251128024112
|
|
10
|
+
- @backstage/plugin-techdocs-node@0.0.0-nightly-20251128024112
|
|
11
11
|
- @backstage/config@1.3.6
|
|
12
12
|
- @backstage/catalog-model@1.7.6
|
|
13
13
|
|
|
@@ -458,9 +458,6 @@
|
|
|
458
458
|
}
|
|
459
459
|
}
|
|
460
460
|
},
|
|
461
|
-
"required": [
|
|
462
|
-
"techdocs"
|
|
463
|
-
],
|
|
464
461
|
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
465
462
|
},
|
|
466
463
|
"packageName": "@backstage/plugin-techdocs"
|
|
@@ -1481,6 +1478,129 @@
|
|
|
1481
1478
|
},
|
|
1482
1479
|
"packageName": "@backstage/plugin-auth-backend-module-guest-provider"
|
|
1483
1480
|
},
|
|
1481
|
+
{
|
|
1482
|
+
"path": "../backend-app-api/config.d.ts",
|
|
1483
|
+
"value": {
|
|
1484
|
+
"type": "object",
|
|
1485
|
+
"properties": {
|
|
1486
|
+
"backend": {
|
|
1487
|
+
"type": "object",
|
|
1488
|
+
"properties": {
|
|
1489
|
+
"packages": {
|
|
1490
|
+
"description": "Used by the feature discovery service",
|
|
1491
|
+
"anyOf": [
|
|
1492
|
+
{
|
|
1493
|
+
"type": "object",
|
|
1494
|
+
"properties": {
|
|
1495
|
+
"include": {
|
|
1496
|
+
"type": "array",
|
|
1497
|
+
"items": {
|
|
1498
|
+
"type": "string"
|
|
1499
|
+
}
|
|
1500
|
+
},
|
|
1501
|
+
"exclude": {
|
|
1502
|
+
"type": "array",
|
|
1503
|
+
"items": {
|
|
1504
|
+
"type": "string"
|
|
1505
|
+
}
|
|
1506
|
+
}
|
|
1507
|
+
}
|
|
1508
|
+
},
|
|
1509
|
+
{
|
|
1510
|
+
"const": "all",
|
|
1511
|
+
"type": "string"
|
|
1512
|
+
}
|
|
1513
|
+
]
|
|
1514
|
+
},
|
|
1515
|
+
"startup": {
|
|
1516
|
+
"type": "object",
|
|
1517
|
+
"properties": {
|
|
1518
|
+
"default": {
|
|
1519
|
+
"type": "object",
|
|
1520
|
+
"properties": {
|
|
1521
|
+
"onPluginBootFailure": {
|
|
1522
|
+
"description": "The default value for `onPluginBootFailure` if not specified for a particular plugin.\nThis defaults to 'abort', which means `onPluginBootFailure: continue` must be specified\nfor backend startup to continue on plugin boot failure. This can also be set to\n'continue', which flips the logic for individual plugins so that they must be set to\n`onPluginBootFailure: abort` to be required.",
|
|
1523
|
+
"enum": [
|
|
1524
|
+
"abort",
|
|
1525
|
+
"continue"
|
|
1526
|
+
],
|
|
1527
|
+
"type": "string"
|
|
1528
|
+
},
|
|
1529
|
+
"onPluginModuleBootFailure": {
|
|
1530
|
+
"description": "The default value for `onPluginModuleBootFailure` if not specified for a particular plugin module.\nThis defaults to 'abort', which means `onPluginModuleBootFailure: continue` must be specified\nfor backend startup to continue on plugin module boot failure. This can also be set to\n'continue', which flips the logic for individual plugin modules so that they must be set to\n`onPluginModuleBootFailure: abort` to be required.",
|
|
1531
|
+
"enum": [
|
|
1532
|
+
"abort",
|
|
1533
|
+
"continue"
|
|
1534
|
+
],
|
|
1535
|
+
"type": "string"
|
|
1536
|
+
}
|
|
1537
|
+
}
|
|
1538
|
+
},
|
|
1539
|
+
"plugins": {
|
|
1540
|
+
"type": "object",
|
|
1541
|
+
"additionalProperties": {
|
|
1542
|
+
"type": "object",
|
|
1543
|
+
"properties": {
|
|
1544
|
+
"onPluginBootFailure": {
|
|
1545
|
+
"description": "Used to control backend startup behavior when this plugin fails to boot up. Setting\nthis to `continue` allows the backend to continue starting up, even if this plugin\nfails. This can enable leaving a crashing plugin installed, but still permit backend\nstartup, which may help troubleshoot data-dependent issues. Plugin failures for plugins\nset to `abort` are fatal (this is the default unless overridden by the `default`\nsetting).",
|
|
1546
|
+
"enum": [
|
|
1547
|
+
"abort",
|
|
1548
|
+
"continue"
|
|
1549
|
+
],
|
|
1550
|
+
"type": "string"
|
|
1551
|
+
},
|
|
1552
|
+
"modules": {
|
|
1553
|
+
"type": "object",
|
|
1554
|
+
"additionalProperties": {
|
|
1555
|
+
"type": "object",
|
|
1556
|
+
"properties": {
|
|
1557
|
+
"onPluginModuleBootFailure": {
|
|
1558
|
+
"description": "Used to control backend startup behavior when this plugin module fails to boot up. Setting\nthis to `continue` allows the backend to continue starting up, even if this plugin\nmodule fails. This can enable leaving a crashing plugin installed, but still permit backend\nstartup, which may help troubleshoot data-dependent issues. Plugin module failures for plugin modules\nset to `abort` are fatal (this is the default unless overridden by the `default`\nsetting).",
|
|
1559
|
+
"enum": [
|
|
1560
|
+
"abort",
|
|
1561
|
+
"continue"
|
|
1562
|
+
],
|
|
1563
|
+
"type": "string"
|
|
1564
|
+
}
|
|
1565
|
+
}
|
|
1566
|
+
}
|
|
1567
|
+
}
|
|
1568
|
+
}
|
|
1569
|
+
}
|
|
1570
|
+
}
|
|
1571
|
+
}
|
|
1572
|
+
}
|
|
1573
|
+
}
|
|
1574
|
+
}
|
|
1575
|
+
},
|
|
1576
|
+
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
1577
|
+
},
|
|
1578
|
+
"packageName": "@backstage/backend-app-api"
|
|
1579
|
+
},
|
|
1580
|
+
{
|
|
1581
|
+
"path": "../../plugins/events-node/config.d.ts",
|
|
1582
|
+
"value": {
|
|
1583
|
+
"type": "object",
|
|
1584
|
+
"properties": {
|
|
1585
|
+
"events": {
|
|
1586
|
+
"type": "object",
|
|
1587
|
+
"properties": {
|
|
1588
|
+
"useEventBus": {
|
|
1589
|
+
"description": "Whether to use the event bus API in the events plugin backend to\ndistribute events across multiple instances when publishing and\nsubscribing to events.\n\nThe default is 'auto', which means means that the event bus API will be\nused if it's available, but will be disabled if the events backend\nreturns a 404.\n\nIf set to 'never', the events service will only ever publish events\nlocally to the same instance, while if set to 'always', the event bus API\nwill never be disabled, even if the events backend returns a 404.",
|
|
1590
|
+
"enum": [
|
|
1591
|
+
"always",
|
|
1592
|
+
"auto",
|
|
1593
|
+
"never"
|
|
1594
|
+
],
|
|
1595
|
+
"type": "string"
|
|
1596
|
+
}
|
|
1597
|
+
}
|
|
1598
|
+
}
|
|
1599
|
+
},
|
|
1600
|
+
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
1601
|
+
},
|
|
1602
|
+
"packageName": "@backstage/plugin-events-node"
|
|
1603
|
+
},
|
|
1484
1604
|
{
|
|
1485
1605
|
"path": "../backend-defaults/config.d.ts",
|
|
1486
1606
|
"value": {
|
|
@@ -3053,129 +3173,6 @@
|
|
|
3053
3173
|
},
|
|
3054
3174
|
"packageName": "@backstage/backend-defaults"
|
|
3055
3175
|
},
|
|
3056
|
-
{
|
|
3057
|
-
"path": "../backend-app-api/config.d.ts",
|
|
3058
|
-
"value": {
|
|
3059
|
-
"type": "object",
|
|
3060
|
-
"properties": {
|
|
3061
|
-
"backend": {
|
|
3062
|
-
"type": "object",
|
|
3063
|
-
"properties": {
|
|
3064
|
-
"packages": {
|
|
3065
|
-
"description": "Used by the feature discovery service",
|
|
3066
|
-
"anyOf": [
|
|
3067
|
-
{
|
|
3068
|
-
"type": "object",
|
|
3069
|
-
"properties": {
|
|
3070
|
-
"include": {
|
|
3071
|
-
"type": "array",
|
|
3072
|
-
"items": {
|
|
3073
|
-
"type": "string"
|
|
3074
|
-
}
|
|
3075
|
-
},
|
|
3076
|
-
"exclude": {
|
|
3077
|
-
"type": "array",
|
|
3078
|
-
"items": {
|
|
3079
|
-
"type": "string"
|
|
3080
|
-
}
|
|
3081
|
-
}
|
|
3082
|
-
}
|
|
3083
|
-
},
|
|
3084
|
-
{
|
|
3085
|
-
"const": "all",
|
|
3086
|
-
"type": "string"
|
|
3087
|
-
}
|
|
3088
|
-
]
|
|
3089
|
-
},
|
|
3090
|
-
"startup": {
|
|
3091
|
-
"type": "object",
|
|
3092
|
-
"properties": {
|
|
3093
|
-
"default": {
|
|
3094
|
-
"type": "object",
|
|
3095
|
-
"properties": {
|
|
3096
|
-
"onPluginBootFailure": {
|
|
3097
|
-
"description": "The default value for `onPluginBootFailure` if not specified for a particular plugin.\nThis defaults to 'abort', which means `onPluginBootFailure: continue` must be specified\nfor backend startup to continue on plugin boot failure. This can also be set to\n'continue', which flips the logic for individual plugins so that they must be set to\n`onPluginBootFailure: abort` to be required.",
|
|
3098
|
-
"enum": [
|
|
3099
|
-
"abort",
|
|
3100
|
-
"continue"
|
|
3101
|
-
],
|
|
3102
|
-
"type": "string"
|
|
3103
|
-
},
|
|
3104
|
-
"onPluginModuleBootFailure": {
|
|
3105
|
-
"description": "The default value for `onPluginModuleBootFailure` if not specified for a particular plugin module.\nThis defaults to 'abort', which means `onPluginModuleBootFailure: continue` must be specified\nfor backend startup to continue on plugin module boot failure. This can also be set to\n'continue', which flips the logic for individual plugin modules so that they must be set to\n`onPluginModuleBootFailure: abort` to be required.",
|
|
3106
|
-
"enum": [
|
|
3107
|
-
"abort",
|
|
3108
|
-
"continue"
|
|
3109
|
-
],
|
|
3110
|
-
"type": "string"
|
|
3111
|
-
}
|
|
3112
|
-
}
|
|
3113
|
-
},
|
|
3114
|
-
"plugins": {
|
|
3115
|
-
"type": "object",
|
|
3116
|
-
"additionalProperties": {
|
|
3117
|
-
"type": "object",
|
|
3118
|
-
"properties": {
|
|
3119
|
-
"onPluginBootFailure": {
|
|
3120
|
-
"description": "Used to control backend startup behavior when this plugin fails to boot up. Setting\nthis to `continue` allows the backend to continue starting up, even if this plugin\nfails. This can enable leaving a crashing plugin installed, but still permit backend\nstartup, which may help troubleshoot data-dependent issues. Plugin failures for plugins\nset to `abort` are fatal (this is the default unless overridden by the `default`\nsetting).",
|
|
3121
|
-
"enum": [
|
|
3122
|
-
"abort",
|
|
3123
|
-
"continue"
|
|
3124
|
-
],
|
|
3125
|
-
"type": "string"
|
|
3126
|
-
},
|
|
3127
|
-
"modules": {
|
|
3128
|
-
"type": "object",
|
|
3129
|
-
"additionalProperties": {
|
|
3130
|
-
"type": "object",
|
|
3131
|
-
"properties": {
|
|
3132
|
-
"onPluginModuleBootFailure": {
|
|
3133
|
-
"description": "Used to control backend startup behavior when this plugin module fails to boot up. Setting\nthis to `continue` allows the backend to continue starting up, even if this plugin\nmodule fails. This can enable leaving a crashing plugin installed, but still permit backend\nstartup, which may help troubleshoot data-dependent issues. Plugin module failures for plugin modules\nset to `abort` are fatal (this is the default unless overridden by the `default`\nsetting).",
|
|
3134
|
-
"enum": [
|
|
3135
|
-
"abort",
|
|
3136
|
-
"continue"
|
|
3137
|
-
],
|
|
3138
|
-
"type": "string"
|
|
3139
|
-
}
|
|
3140
|
-
}
|
|
3141
|
-
}
|
|
3142
|
-
}
|
|
3143
|
-
}
|
|
3144
|
-
}
|
|
3145
|
-
}
|
|
3146
|
-
}
|
|
3147
|
-
}
|
|
3148
|
-
}
|
|
3149
|
-
}
|
|
3150
|
-
},
|
|
3151
|
-
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
3152
|
-
},
|
|
3153
|
-
"packageName": "@backstage/backend-app-api"
|
|
3154
|
-
},
|
|
3155
|
-
{
|
|
3156
|
-
"path": "../../plugins/events-node/config.d.ts",
|
|
3157
|
-
"value": {
|
|
3158
|
-
"type": "object",
|
|
3159
|
-
"properties": {
|
|
3160
|
-
"events": {
|
|
3161
|
-
"type": "object",
|
|
3162
|
-
"properties": {
|
|
3163
|
-
"useEventBus": {
|
|
3164
|
-
"description": "Whether to use the event bus API in the events plugin backend to\ndistribute events across multiple instances when publishing and\nsubscribing to events.\n\nThe default is 'auto', which means means that the event bus API will be\nused if it's available, but will be disabled if the events backend\nreturns a 404.\n\nIf set to 'never', the events service will only ever publish events\nlocally to the same instance, while if set to 'always', the event bus API\nwill never be disabled, even if the events backend returns a 404.",
|
|
3165
|
-
"enum": [
|
|
3166
|
-
"always",
|
|
3167
|
-
"auto",
|
|
3168
|
-
"never"
|
|
3169
|
-
],
|
|
3170
|
-
"type": "string"
|
|
3171
|
-
}
|
|
3172
|
-
}
|
|
3173
|
-
}
|
|
3174
|
-
},
|
|
3175
|
-
"$schema": "http://json-schema.org/draft-07/schema#"
|
|
3176
|
-
},
|
|
3177
|
-
"packageName": "@backstage/plugin-events-node"
|
|
3178
|
-
},
|
|
3179
3176
|
{
|
|
3180
3177
|
"path": "../../plugins/auth-backend-module-google-provider/config.d.ts",
|
|
3181
3178
|
"value": {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<!doctype html><html lang="en"><head><meta charset="utf-8"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="color-scheme" content="light dark"/><meta name="description" content="Backstage is an open source framework for building developer portals"/><link rel="manifest" href="/manifest.json" crossorigin="use-credentials"/><link rel="icon" href="/favicon.ico"/><link rel="shortcut icon" href="/favicon.ico"/><link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png"/><link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png"/><link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png"/><link rel="mask-icon" href="/safari-pinned-tab.svg" color="#5bbad5"/><title>Techdocs Preview App</title><meta name="backstage-app-mode" content="public"><script defer="defer" src="/static/runtime.
|
|
1
|
+
<!doctype html><html lang="en"><head><meta charset="utf-8"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="color-scheme" content="light dark"/><meta name="description" content="Backstage is an open source framework for building developer portals"/><link rel="manifest" href="/manifest.json" crossorigin="use-credentials"/><link rel="icon" href="/favicon.ico"/><link rel="shortcut icon" href="/favicon.ico"/><link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png"/><link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png"/><link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png"/><link rel="mask-icon" href="/safari-pinned-tab.svg" color="#5bbad5"/><title>Techdocs Preview App</title><meta name="backstage-app-mode" content="public"><script defer="defer" src="/static/runtime.b161f61e.js"></script><script defer="defer" src="/static/module-material-ui.d7e935bd.js"></script><script defer="defer" src="/static/module-lodash.4c0b97a0.js"></script><script defer="defer" src="/static/module-date-fns.ea38f57b.js"></script><script defer="defer" src="/static/module-mui.5d4d7042.js"></script><script defer="defer" src="/static/module-material-table.3ca211ef.js"></script><script defer="defer" src="/static/module-zod.ebbb06c8.js"></script><script defer="defer" src="/static/module-react-dom.e29ff3c5.js"></script><script defer="defer" src="/static/module-i18next.2dc1c3e2.js"></script><script defer="defer" src="/static/module-react-beautiful-dnd.ba954a31.js"></script><script defer="defer" src="/static/module-remix-run.a4991870.js"></script><script defer="defer" src="/static/vendor.4b7983a7.js"></script><script defer="defer" src="/static/main.1e32ff7a.js"></script><link href="/static/main.5f8bd308.css" rel="stylesheet"><script type="backstage.io/config">[
|
|
2
2
|
{
|
|
3
3
|
"context": "app-config.yaml",
|
|
4
4
|
"data": {
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
color="#5bbad5"
|
|
44
44
|
/>
|
|
45
45
|
<title><%= config.getString('app.title') %></title>
|
|
46
|
-
<meta name="backstage-app-mode" content="public"><meta name="backstage-public-path" content="<%= publicPath %>/"><script defer src="<%= publicPath %>/static/runtime.
|
|
46
|
+
<meta name="backstage-app-mode" content="public"><meta name="backstage-public-path" content="<%= publicPath %>/"><script defer src="<%= publicPath %>/static/runtime.b161f61e.js"></script><script defer src="<%= publicPath %>/static/module-material-ui.d7e935bd.js"></script><script defer src="<%= publicPath %>/static/module-lodash.4c0b97a0.js"></script><script defer src="<%= publicPath %>/static/module-date-fns.ea38f57b.js"></script><script defer src="<%= publicPath %>/static/module-mui.5d4d7042.js"></script><script defer src="<%= publicPath %>/static/module-material-table.3ca211ef.js"></script><script defer src="<%= publicPath %>/static/module-zod.ebbb06c8.js"></script><script defer src="<%= publicPath %>/static/module-react-dom.e29ff3c5.js"></script><script defer src="<%= publicPath %>/static/module-i18next.2dc1c3e2.js"></script><script defer src="<%= publicPath %>/static/module-react-beautiful-dnd.ba954a31.js"></script><script defer src="<%= publicPath %>/static/module-remix-run.a4991870.js"></script><script defer src="<%= publicPath %>/static/vendor.4b7983a7.js"></script><script defer src="<%= publicPath %>/static/main.1e32ff7a.js"></script><link href="<%= publicPath %>/static/main.5f8bd308.css" rel="stylesheet"></head>
|
|
47
47
|
<body>
|
|
48
48
|
<noscript>You need to enable JavaScript to run this app.</noscript>
|
|
49
49
|
<div id="root"></div>
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";(self.webpackChunktechdocs_cli_embedded_app=self.webpackChunktechdocs_cli_embedded_app||[]).push([["4591"],{69890:function(e,t,n){n.d(t,{RealLogViewer:()=>Y});var i=n(31085),r=n(9720),l=n(29365),o=n(99594),s=n(53373),a=n.n(s),c=n(14041),d=n(18690),u=n(19686),h=n(84392);let g=(0,n(84774).A)(),f=/\n\r?/g,m=Object.fromEntries(Object.entries({1:e=>({...e,bold:!0}),3:e=>({...e,italic:!0}),4:e=>({...e,underline:!0}),22:({bold:e,...t})=>t,23:({italic:e,...t})=>t,24:({underline:e,...t})=>t,30:e=>({...e,foreground:"black"}),31:e=>({...e,foreground:"red"}),32:e=>({...e,foreground:"green"}),33:e=>({...e,foreground:"yellow"}),34:e=>({...e,foreground:"blue"}),35:e=>({...e,foreground:"magenta"}),36:e=>({...e,foreground:"cyan"}),37:e=>({...e,foreground:"white"}),39:({foreground:e,...t})=>t,90:e=>({...e,foreground:"grey"}),40:e=>({...e,background:"black"}),41:e=>({...e,background:"red"}),42:e=>({...e,background:"green"}),43:e=>({...e,background:"yellow"}),44:e=>({...e,background:"blue"}),45:e=>({...e,background:"magenta"}),46:e=>({...e,background:"cyan"}),47:e=>({...e,background:"white"}),49:({background:e,...t})=>t}).map(([e,t])=>[`\x1b[${e}m`,t]));class p{text;lineNumber;chunks;constructor(e=1,t=[]){this.lineNumber=e,this.chunks=t,this.text=t.map(e=>e.text).join("").toLocaleLowerCase("en-US")}lastChunk(){return this.chunks[this.chunks.length-1]}replaceLastChunk(e){e&&(this.chunks.splice(this.chunks.length-1,1,...e),this.text=this.chunks.map(e=>e.text).join("").toLocaleLowerCase("en-US"))}}class x{text="";lines=[];process(e){if(this.text===e)return this.lines;if(this.text&&e.startsWith(this.text)){let t=this.lines.length>0?this.lines.length-1:0,n=this.lines[t]??new p,i=n.lastChunk(),r=this.processLines((i?.text??"")+e.slice(this.text.length),i?.modifiers,n?.lineNumber);n.replaceLastChunk(r[0]?.chunks),this.lines[t]=n,this.lines=this.lines.concat(r.slice(1))}else this.lines=this.processLines(e);return this.text=e,this.lines}processLines=(e,t={},n=1)=>{let i=[],r=t,l=n,o=0;for(f.lastIndex=0;;){let t=f.exec(e);if(!t){let t=this.processText(e.slice(o),r);return i.push(new p(l,t)),i}let n=e.slice(o,t.index);o=t.index+t[0].length;let s=this.processText(n,r);i.push(new p(l,s)),r=s[s.length-1].modifiers??r,l+=1}};processText=(e,t)=>{let n=[],i=t,r=0;for(g.lastIndex=0;;){let t=g.exec(e);if(!t)return n.push({text:e.slice(r),modifiers:i}),n;let l=e.slice(r,t.index);n.push({text:l,modifiers:i}),r=t.index+t[0].length,i=this.processCode(t[0],i)}};processCode=(e,t)=>m[e]?.(t)??t}var k=n(95479),b=n.n(k),y=n(60075),j=n(60603);let A=({attributes:e,content:t})=>{let{href:n,...r}=e;return(0,i.jsx)(j.N_,{to:n,...r,children:t})};function S({line:e,classes:t,searchText:n,highlightResultIndex:r,setRowHeight:l}){let o=(0,c.useRef)(null),s=(0,c.useMemo)(()=>(function(e,t){let n=function(e,t){if(!t||!e.includes(t))return;let n=[],i=0;for(;;){let r=e.indexOf(t,i);if(-1===r)break;let l=r+t.length;n.push({start:r,end:l}),i=l}return n}(e.text,t);if(!n)return e.chunks;let i=[],r=0,l=0,o=n[0];for(let t of e.chunks){let{text:e,modifiers:s}=t;if(!o||r+e.length<o.start){i.push(t),r+=e.length;continue}let a=0;for(;o;){let t=Math.max(o.start-r,0);if(t>e.length)break;let c=Math.min(o.end-r,e.length);if(t>a&&i.push({text:e.slice(a,t),modifiers:s}),c>t&&i.push({modifiers:s,highlight:l,text:e.slice(t,c)}),a=c,o.end-r===c)l+=1,o=n[l];else break}a<e.length&&i.push({text:e.slice(a),modifiers:s}),r+=e.length}return i})(e,n),[e,n]);(0,c.useEffect)(()=>{o.current&&l&&l(e.lineNumber,o.current.offsetHeight)},[e.lineNumber,l]);let d=(0,c.useMemo)(()=>s.map(({text:e,modifiers:n,highlight:o},s)=>(0,i.jsx)("span",{className:a()(function(e,t){let n=[];if(t.bold&&n.push(e.modifierBold),t.italic&&n.push(e.modifierItalic),t.underline&&n.push(e.modifierUnderline),t.foreground){let i=`modifierForeground${b()(t.foreground)}`;n.push(e[i])}if(t.background){let i=`modifierBackground${b()(t.background)}`;n.push(e[i])}return n.length>0?n.join(" "):void 0}(t,n),void 0!==o&&(o===r?t.textSelectedHighlight:t.textHighlight),{[t.textWrap]:!!l}),children:(0,i.jsx)(y.A,{options:{render:A},children:e})},s)),[s,r,t,l]);return(0,i.jsx)("span",{ref:o,children:d})}var w=n(89595),v=n(16249),B=n(72501),C=n(68887),I=n(63798),L=n(65859),N=n(89332);function M(e){let{t}=(0,w.i)(N.O),{resultCount:n,resultIndexStep:r,toggleShouldFilter:o}=e,s=e.resultIndex??0;return(0,i.jsxs)(i.Fragment,{children:[void 0!==n&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(l.A,{size:"small",onClick:()=>r(!0),children:(0,i.jsx)(C.default,{})}),(0,i.jsxs)(B.A,{children:[Math.min(s+1,n),"/",n]}),(0,i.jsx)(l.A,{size:"small",onClick:()=>r(),children:(0,i.jsx)(I.default,{})})]}),(0,i.jsx)(v.A,{size:"small",variant:"standard",placeholder:t("logViewer.searchField.placeholder"),value:e.searchInput,onKeyPress:e=>{"Enter"===e.key&&(e.metaKey||e.ctrlKey||e.altKey?o():r(e.shiftKey))},onChange:t=>e.setSearchInput(t.target.value)}),(0,i.jsx)(l.A,{size:"small",onClick:o,children:e.shouldFilter?(0,i.jsx)(L.default,{color:"primary"}):(0,i.jsx)(L.default,{color:"disabled"})})]})}var F=n(58837),z=n(268),T=n(95186),R=n(38084),_=n(54024),W=n(40935),E=n(4499),H=n(85229),K=n(42020),O=n(6456);let U=(0,F.A)(e=>({root:{background:e.palette.background.paper},header:{height:40,display:"flex",alignItems:"center",justifyContent:"flex-end"},log:{fontFamily:'"Monaco", monospace',fontSize:e.typography.pxToRem(12),lineHeight:"20px"},line:{position:"relative",whiteSpace:"pre",display:"flex",alignItems:"flex-start","&:hover":{background:e.palette.action.hover}},lineSelected:{background:e.palette.action.selected,"&:hover":{background:e.palette.action.selected}},lineCopyButton:{position:"absolute",paddingTop:0,paddingBottom:0},lineNumber:{display:"inline-block",textAlign:"end",width:60,marginRight:e.spacing(1),cursor:"pointer",flexShrink:0,userSelect:"none"},textHighlight:{background:(0,z.X4)(e.palette.info.main,.15)},textSelectedHighlight:{background:(0,z.X4)(e.palette.info.main,.4)},modifierBold:{fontWeight:e.typography.fontWeightBold},modifierItalic:{fontStyle:"italic"},modifierUnderline:{textDecoration:"underline"},modifierForegroundBlack:{color:T.A.black},modifierForegroundRed:{color:R.A["500"]},modifierForegroundGreen:{color:_.A["500"]},modifierForegroundYellow:{color:W.A["500"]},modifierForegroundBlue:{color:E.A["500"]},modifierForegroundMagenta:{color:H.A["500"]},modifierForegroundCyan:{color:K.A["500"]},modifierForegroundWhite:{color:T.A.white},modifierForegroundGrey:{color:O.A["500"]},modifierBackgroundBlack:{background:T.A.black},modifierBackgroundRed:{background:R.A["500"]},modifierBackgroundGreen:{background:_.A["500"]},modifierBackgroundYellow:{background:W.A["500"]},modifierBackgroundBlue:{background:E.A["500"]},modifierBackgroundMagenta:{background:H.A["500"]},modifierBackgroundCyan:{background:K.A["500"]},modifierBackgroundWhite:{background:T.A.white},modifierBackgroundGrey:{background:O.A["500"]},textWrap:{whiteSpace:"pre-wrap",wordBreak:"break-all"}}),{name:"BackstageLogViewer"});var G=n(54633),$=n(50509),D=n(151),V=n(11688);function Y(e){let t=U({classes:e.classes}),[n,s]=(0,c.useState)(null),g=e.textWrap??!1,f=(0,c.useRef)({}),m=(0,c.useMemo)(()=>new x,[]).process(e.text),p=function(e){let[t,n]=(0,c.useState)(""),i=t.toLocaleLowerCase("en-US"),[r,l]=(0,c.useState)(0),[o,s]=(0,G.e)(!1),a=(0,c.useMemo)(()=>(function(e,t){if(!t)return{lines:e};let n=[],i=[];for(let r of e)if(r.text.includes(t)){n.push(r);let e=0,l=0;for(;;){let n=r.text.indexOf(t,e);if(-1===n)break;i.push({lineNumber:r.lineNumber,lineIndex:l++}),e=n+t.length}}return{lines:n,results:i}})(e,i),[e,i]),d=a.results?a.results[Math.min(r,a.results.length-1)]:void 0,u=a.results?.length;return{lines:o?a.lines:e,searchText:i,searchInput:t,setSearchInput:n,shouldFilter:o,toggleShouldFilter:s,resultCount:u,resultIndex:r,resultIndexStep:e=>{if(e){if(void 0!==u){let e=Math.min(r-1,u-2);l(e<0?u-1:e)}}else if(void 0!==u){let e=r+1;l(e>=u?0:e)}},resultLine:d?.lineNumber,resultLineIndex:d?.lineIndex}}(m),k=function(e){let t=(0,$.gf)(D.m),[n,i]=(0,c.useState)(),r=n?Math.min(n.start,n.end):void 0,l=n?Math.max(n.start,n.end):void 0,[{error:o},s]=(0,V.A)();return(0,c.useEffect)(()=>{o&&t.post(o)},[o,t]),{shouldShowButton:e=>r===e||l===e,isSelected:e=>!!n&&r<=e&&e<=l,setSelection(e,t){t?i(t=>t?{start:t.start,end:e}:{start:e,end:e}):i(t=>t?.start===e&&t?.end===e?void 0:{start:e,end:e})},copySelection(){n&&(s(e.slice(Math.min(n.start,n.end)-1,Math.max(n.start,n.end)).map(e=>e.chunks.map(e=>e.text).join("")).join("\n")),i(void 0))}}}(m),b=(0,d.zy)();(0,c.useEffect)(()=>{n&&n.scrollToItem(m.length-1,"end")},[n,m]),(0,c.useEffect)(()=>{n&&(p.resultLine?n.scrollToItem(p.resultLine-1,"center"):n.scrollToItem(m.length-1,"end"))},[n,p.resultLine,m]),(0,c.useEffect)(()=>{if(b.hash){let e=parseInt(b.hash.replace(/\D/g,""),10);k.setSelection(e,!1)}},[]);let y=(e,t)=>{k.setSelection(e,t.shiftKey)};function j(e,t){g&&n&&(n.resetAfterIndex(0),f.current[e-1]=t)}function A(e){return f.current[e]||20}return(0,i.jsx)(u.Ay,{children:({height:e,width:n})=>{let c={ref:s,className:t.log,height:(e||480)-40,width:n||640,itemData:p.lines,itemCount:p.lines.length},d=({index:e,style:n,data:s})=>{let c=s[e],{lineNumber:d}=c;return(0,i.jsxs)(r.A,{style:{...n},className:a()(t.line,{[t.lineSelected]:k.isSelected(d)}),children:[k.shouldShowButton(d)&&(0,i.jsx)(l.A,{"data-testid":"copy-button",size:"small",className:t.lineCopyButton,onClick:()=>k.copySelection(),children:(0,i.jsx)(o.default,{fontSize:"inherit"})}),(0,i.jsx)("a",{role:"row",target:"_self",href:`#line-${d}`,className:t.lineNumber,onClick:e=>y(d,e),onKeyPress:e=>y(d,e),children:d}),(0,i.jsx)(S,{setRowHeight:g?j:void 0,line:c,classes:t,searchText:p.searchText,highlightResultIndex:p.resultLine===d?p.resultLineIndex:void 0})]})};return(0,i.jsxs)(r.A,{style:{width:n,height:e},className:t.root,children:[(0,i.jsx)(r.A,{className:t.header,children:(0,i.jsx)(M,{...p})}),g?(0,i.jsx)(h._m,{...c,itemSize:A,children:d}):(0,i.jsx)(h.Y1,{...c,itemSize:20,children:d})]})}})}}}]);
|
|
2
|
+
//# sourceMappingURL=4591.25e74053.chunk.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"static/4591.25e74053.chunk.js","sources":["webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/AnsiProcessor.ts","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/LogLine.tsx","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/LogViewerControls.tsx","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/styles.ts","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/RealLogViewer.tsx","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/useLogViewerSearch.tsx","webpack://techdocs-cli-embedded-app/../core-components/src/components/LogViewer/useLogViewerSelection.tsx"],"sourcesContent":["/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport ansiRegexMaker from 'ansi-regex';\n\nconst ansiRegex = ansiRegexMaker();\nconst newlineRegex = /\\n\\r?/g;\n\n// A mapping of how each escape code changes the modifiers\nconst codeModifiers = Object.fromEntries(\n Object.entries({\n 1: m => ({ ...m, bold: true }),\n 3: m => ({ ...m, italic: true }),\n 4: m => ({ ...m, underline: true }),\n 22: ({ bold: _, ...m }) => m,\n 23: ({ italic: _, ...m }) => m,\n 24: ({ underline: _, ...m }) => m,\n 30: m => ({ ...m, foreground: 'black' }),\n 31: m => ({ ...m, foreground: 'red' }),\n 32: m => ({ ...m, foreground: 'green' }),\n 33: m => ({ ...m, foreground: 'yellow' }),\n 34: m => ({ ...m, foreground: 'blue' }),\n 35: m => ({ ...m, foreground: 'magenta' }),\n 36: m => ({ ...m, foreground: 'cyan' }),\n 37: m => ({ ...m, foreground: 'white' }),\n 39: ({ foreground: _, ...m }) => m,\n 90: m => ({ ...m, foreground: 'grey' }),\n 40: m => ({ ...m, background: 'black' }),\n 41: m => ({ ...m, background: 'red' }),\n 42: m => ({ ...m, background: 'green' }),\n 43: m => ({ ...m, background: 'yellow' }),\n 44: m => ({ ...m, background: 'blue' }),\n 45: m => ({ ...m, background: 'magenta' }),\n 46: m => ({ ...m, background: 'cyan' }),\n 47: m => ({ ...m, background: 'white' }),\n 49: ({ background: _, ...m }) => m,\n } as Record<string, (m: ChunkModifiers) => ChunkModifiers>).map(\n ([code, modifier]) => [`\\x1b[${code}m`, modifier],\n ),\n);\n\nexport type AnsiColor =\n | 'black'\n | 'red'\n | 'green'\n | 'yellow'\n | 'blue'\n | 'magenta'\n | 'cyan'\n | 'white'\n | 'grey';\n\nexport interface ChunkModifiers {\n foreground?: AnsiColor;\n background?: AnsiColor;\n bold?: boolean;\n italic?: boolean;\n underline?: boolean;\n}\n\nexport interface AnsiChunk {\n text: string;\n modifiers: ChunkModifiers;\n}\n\nexport class AnsiLine {\n text: string;\n readonly lineNumber: number;\n readonly chunks: AnsiChunk[];\n\n constructor(lineNumber: number = 1, chunks: AnsiChunk[] = []) {\n this.lineNumber = lineNumber;\n this.chunks = chunks;\n this.text = chunks\n .map(c => c.text)\n .join('')\n .toLocaleLowerCase('en-US');\n }\n\n lastChunk(): AnsiChunk | undefined {\n return this.chunks[this.chunks.length - 1];\n }\n\n replaceLastChunk(newChunks?: AnsiChunk[]) {\n if (newChunks) {\n this.chunks.splice(this.chunks.length - 1, 1, ...newChunks);\n this.text = this.chunks\n .map(c => c.text)\n .join('')\n .toLocaleLowerCase('en-US');\n }\n }\n}\n\nexport class AnsiProcessor {\n private text: string = '';\n private lines: AnsiLine[] = [];\n\n /**\n * Processes a chunk of text while keeping internal state that optimizes\n * subsequent processing that appends to the text.\n */\n process(text: string): AnsiLine[] {\n if (this.text === text) {\n return this.lines;\n }\n\n if (this.text && text.startsWith(this.text)) {\n const lastLineIndex = this.lines.length > 0 ? this.lines.length - 1 : 0;\n const lastLine = this.lines[lastLineIndex] ?? new AnsiLine();\n const lastChunk = lastLine.lastChunk();\n\n const newLines = this.processLines(\n (lastChunk?.text ?? '') + text.slice(this.text.length),\n lastChunk?.modifiers,\n lastLine?.lineNumber,\n );\n lastLine.replaceLastChunk(newLines[0]?.chunks);\n\n this.lines[lastLineIndex] = lastLine;\n this.lines = this.lines.concat(newLines.slice(1));\n } else {\n this.lines = this.processLines(text);\n }\n this.text = text;\n\n return this.lines;\n }\n\n // Split a chunk of text up into lines and process each line individually\n private processLines = (\n text: string,\n modifiers: ChunkModifiers = {},\n startingLineNumber: number = 1,\n ): AnsiLine[] => {\n const lines: AnsiLine[] = [];\n\n let currentModifiers = modifiers;\n let currentLineNumber = startingLineNumber;\n\n let prevIndex = 0;\n newlineRegex.lastIndex = 0;\n for (;;) {\n const match = newlineRegex.exec(text);\n if (!match) {\n const chunks = this.processText(\n text.slice(prevIndex),\n currentModifiers,\n );\n lines.push(new AnsiLine(currentLineNumber, chunks));\n return lines;\n }\n\n const line = text.slice(prevIndex, match.index);\n prevIndex = match.index + match[0].length;\n\n const chunks = this.processText(line, currentModifiers);\n lines.push(new AnsiLine(currentLineNumber, chunks));\n\n // Modifiers that are active in the last chunk are carried over to the next line\n currentModifiers =\n chunks[chunks.length - 1].modifiers ?? currentModifiers;\n currentLineNumber += 1;\n }\n };\n\n // Processing of a one individual text chunk\n private processText = (\n fullText: string,\n modifiers: ChunkModifiers,\n ): AnsiChunk[] => {\n const chunks: AnsiChunk[] = [];\n\n let currentModifiers = modifiers;\n\n let prevIndex = 0;\n ansiRegex.lastIndex = 0;\n for (;;) {\n const match = ansiRegex.exec(fullText);\n if (!match) {\n chunks.push({\n text: fullText.slice(prevIndex),\n modifiers: currentModifiers,\n });\n return chunks;\n }\n\n const text = fullText.slice(prevIndex, match.index);\n chunks.push({ text, modifiers: currentModifiers });\n\n // For every escape code that we encounter we keep track of where the\n // next chunk of text starts, and what modifiers it has\n prevIndex = match.index + match[0].length;\n currentModifiers = this.processCode(match[0], currentModifiers);\n }\n };\n\n private processCode = (\n code: string,\n modifiers: ChunkModifiers,\n ): ChunkModifiers => {\n return codeModifiers[code]?.(modifiers) ?? modifiers;\n };\n}\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { useEffect, useMemo, useRef } from 'react';\nimport { AnsiChunk, AnsiLine, ChunkModifiers } from './AnsiProcessor';\nimport startCase from 'lodash/startCase';\nimport classnames from 'classnames';\nimport { useStyles } from './styles';\nimport Linkify from 'linkify-react';\nimport { Link } from '../Link';\n\nexport function getModifierClasses(\n classes: ReturnType<typeof useStyles>,\n modifiers: ChunkModifiers,\n) {\n const classNames = new Array<string>();\n if (modifiers.bold) {\n classNames.push(classes.modifierBold);\n }\n if (modifiers.italic) {\n classNames.push(classes.modifierItalic);\n }\n if (modifiers.underline) {\n classNames.push(classes.modifierUnderline);\n }\n if (modifiers.foreground) {\n const key = `modifierForeground${startCase(\n modifiers.foreground,\n )}` as keyof typeof classes;\n classNames.push(classes[key]);\n }\n if (modifiers.background) {\n const key = `modifierBackground${startCase(\n modifiers.background,\n )}` as keyof typeof classes;\n classNames.push(classes[key]);\n }\n return classNames.length > 0 ? classNames.join(' ') : undefined;\n}\n\nexport function findSearchResults(text: string, searchText: string) {\n if (!searchText || !text.includes(searchText)) {\n return undefined;\n }\n const searchResults = new Array<{ start: number; end: number }>();\n let offset = 0;\n for (;;) {\n const start = text.indexOf(searchText, offset);\n if (start === -1) {\n break;\n }\n const end = start + searchText.length;\n searchResults.push({ start, end });\n offset = end;\n }\n return searchResults;\n}\n\nexport interface HighlightAnsiChunk extends AnsiChunk {\n highlight?: number;\n}\n\nexport function calculateHighlightedChunks(\n line: AnsiLine,\n searchText: string,\n): HighlightAnsiChunk[] {\n const results = findSearchResults(line.text, searchText);\n if (!results) {\n return line.chunks;\n }\n\n const chunks = new Array<HighlightAnsiChunk>();\n\n let lineOffset = 0;\n let resultIndex = 0;\n let result = results[resultIndex];\n for (const chunk of line.chunks) {\n const { text, modifiers } = chunk;\n if (!result || lineOffset + text.length < result.start) {\n chunks.push(chunk);\n lineOffset += text.length;\n continue;\n }\n\n let localOffset = 0;\n while (result) {\n const localStart = Math.max(result.start - lineOffset, 0);\n if (localStart > text.length) {\n break; // The next result is not in this chunk\n }\n\n const localEnd = Math.min(result.end - lineOffset, text.length);\n\n const hasTextBeforeResult = localStart > localOffset;\n if (hasTextBeforeResult) {\n chunks.push({ text: text.slice(localOffset, localStart), modifiers });\n }\n const hasResultText = localEnd > localStart;\n if (hasResultText) {\n chunks.push({\n modifiers,\n highlight: resultIndex,\n text: text.slice(localStart, localEnd),\n });\n }\n\n localOffset = localEnd;\n\n const foundCompleteResult = result.end - lineOffset === localEnd;\n if (foundCompleteResult) {\n resultIndex += 1;\n result = results[resultIndex];\n } else {\n break; // The rest of the result is in the following chunks\n }\n }\n\n const hasTextAfterResult = localOffset < text.length;\n if (hasTextAfterResult) {\n chunks.push({ text: text.slice(localOffset), modifiers });\n }\n\n lineOffset += text.length;\n }\n\n return chunks;\n}\n\nconst renderLink = ({\n attributes,\n content,\n}: {\n attributes: { [attr: string]: any };\n content: string;\n}) => {\n const { href, ...props } = attributes;\n return (\n <Link to={href} {...props}>\n {content}\n </Link>\n );\n};\n\nexport interface LogLineProps {\n line: AnsiLine;\n classes: ReturnType<typeof useStyles>;\n searchText: string;\n highlightResultIndex?: number;\n setRowHeight?: (index: number, size: number) => void;\n}\n\nexport function LogLine({\n line,\n classes,\n searchText,\n highlightResultIndex,\n setRowHeight,\n}: LogLineProps) {\n const lineRef = useRef<HTMLSpanElement>(null);\n const chunks = useMemo(\n () => calculateHighlightedChunks(line, searchText),\n [line, searchText],\n );\n\n useEffect(() => {\n if (lineRef.current && setRowHeight) {\n setRowHeight(line.lineNumber, lineRef.current.offsetHeight);\n }\n }, [line.lineNumber, setRowHeight]);\n\n const elements = useMemo(\n () =>\n chunks.map(({ text, modifiers, highlight }, index) => (\n // eslint-disable-next-line react/forbid-elements\n <span\n key={index}\n className={classnames(\n getModifierClasses(classes, modifiers),\n highlight !== undefined &&\n (highlight === highlightResultIndex\n ? classes.textSelectedHighlight\n : classes.textHighlight),\n { [classes.textWrap]: !!setRowHeight },\n )}\n >\n <Linkify options={{ render: renderLink }}>{text}</Linkify>\n </span>\n )),\n [chunks, highlightResultIndex, classes, setRowHeight],\n );\n\n return <span ref={lineRef}>{elements}</span>;\n}\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { KeyboardEvent } from 'react';\nimport { useTranslationRef } from '@backstage/core-plugin-api/alpha';\nimport IconButton from '@material-ui/core/IconButton';\nimport TextField from '@material-ui/core/TextField';\nimport Typography from '@material-ui/core/Typography';\nimport ChevronLeftIcon from '@material-ui/icons/ChevronLeft';\nimport ChevronRightIcon from '@material-ui/icons/ChevronRight';\nimport FilterListIcon from '@material-ui/icons/FilterList';\nimport { coreComponentsTranslationRef } from '../../translation';\nimport { LogViewerSearch } from './useLogViewerSearch';\n\nexport interface LogViewerControlsProps extends LogViewerSearch {}\n\nexport function LogViewerControls(props: LogViewerControlsProps) {\n const { t } = useTranslationRef(coreComponentsTranslationRef);\n const { resultCount, resultIndexStep, toggleShouldFilter } = props;\n const resultIndex = props.resultIndex ?? 0;\n\n const handleKeyPress = (event: KeyboardEvent<HTMLInputElement>) => {\n if (event.key === 'Enter') {\n if (event.metaKey || event.ctrlKey || event.altKey) {\n toggleShouldFilter();\n } else {\n resultIndexStep(event.shiftKey);\n }\n }\n };\n\n return (\n <>\n {resultCount !== undefined && (\n <>\n <IconButton size=\"small\" onClick={() => resultIndexStep(true)}>\n <ChevronLeftIcon />\n </IconButton>\n <Typography>\n {Math.min(resultIndex + 1, resultCount)}/{resultCount}\n </Typography>\n <IconButton size=\"small\" onClick={() => resultIndexStep()}>\n <ChevronRightIcon />\n </IconButton>\n </>\n )}\n <TextField\n size=\"small\"\n variant=\"standard\"\n placeholder={t('logViewer.searchField.placeholder')}\n value={props.searchInput}\n onKeyPress={handleKeyPress}\n onChange={e => props.setSearchInput(e.target.value)}\n />\n <IconButton size=\"small\" onClick={toggleShouldFilter}>\n {props.shouldFilter ? (\n <FilterListIcon color=\"primary\" />\n ) : (\n <FilterListIcon color=\"disabled\" />\n )}\n </IconButton>\n </>\n );\n}\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { alpha, makeStyles } from '@material-ui/core/styles';\nimport * as colors from '@material-ui/core/colors';\n\nexport const HEADER_SIZE = 40;\n\n/** @public Class keys for overriding LogViewer styles */\nexport type LogViewerClassKey =\n | 'root'\n | 'header'\n | 'log'\n | 'line'\n | 'lineSelected'\n | 'lineCopyButton'\n | 'lineNumber'\n | 'textHighlight'\n | 'textSelectedHighlight'\n | 'modifierBold'\n | 'modifierItalic'\n | 'modifierUnderline'\n | 'modifierForegroundBlack'\n | 'modifierForegroundRed'\n | 'modifierForegroundGreen'\n | 'modifierForegroundYellow'\n | 'modifierForegroundBlue'\n | 'modifierForegroundMagenta'\n | 'modifierForegroundCyan'\n | 'modifierForegroundWhite'\n | 'modifierForegroundGrey'\n | 'modifierBackgroundBlack'\n | 'modifierBackgroundRed'\n | 'modifierBackgroundGreen'\n | 'modifierBackgroundYellow'\n | 'modifierBackgroundBlue'\n | 'modifierBackgroundMagenta'\n | 'modifierBackgroundCyan'\n | 'modifierBackgroundWhite'\n | 'modifierBackgroundGrey';\n\nexport const useStyles = makeStyles(\n theme => ({\n root: {\n background: theme.palette.background.paper,\n },\n header: {\n height: HEADER_SIZE,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'flex-end',\n },\n log: {\n fontFamily: '\"Monaco\", monospace',\n fontSize: theme.typography.pxToRem(12),\n lineHeight: '20px',\n },\n line: {\n position: 'relative',\n whiteSpace: 'pre',\n display: 'flex',\n alignItems: 'flex-start',\n\n '&:hover': {\n background: theme.palette.action.hover,\n },\n },\n lineSelected: {\n background: theme.palette.action.selected,\n\n '&:hover': {\n background: theme.palette.action.selected,\n },\n },\n lineCopyButton: {\n position: 'absolute',\n paddingTop: 0,\n paddingBottom: 0,\n },\n lineNumber: {\n display: 'inline-block',\n textAlign: 'end',\n width: 60,\n marginRight: theme.spacing(1),\n cursor: 'pointer',\n flexShrink: 0,\n userSelect: 'none',\n },\n textHighlight: {\n background: alpha(theme.palette.info.main, 0.15),\n },\n textSelectedHighlight: {\n background: alpha(theme.palette.info.main, 0.4),\n },\n modifierBold: {\n fontWeight: theme.typography.fontWeightBold,\n },\n modifierItalic: {\n fontStyle: 'italic',\n },\n modifierUnderline: {\n textDecoration: 'underline',\n },\n modifierForegroundBlack: {\n color: colors.common.black,\n },\n modifierForegroundRed: {\n color: colors.red[500],\n },\n modifierForegroundGreen: {\n color: colors.green[500],\n },\n modifierForegroundYellow: {\n color: colors.yellow[500],\n },\n modifierForegroundBlue: {\n color: colors.blue[500],\n },\n modifierForegroundMagenta: {\n color: colors.purple[500],\n },\n modifierForegroundCyan: {\n color: colors.cyan[500],\n },\n modifierForegroundWhite: {\n color: colors.common.white,\n },\n modifierForegroundGrey: {\n color: colors.grey[500],\n },\n modifierBackgroundBlack: {\n background: colors.common.black,\n },\n modifierBackgroundRed: {\n background: colors.red[500],\n },\n modifierBackgroundGreen: {\n background: colors.green[500],\n },\n modifierBackgroundYellow: {\n background: colors.yellow[500],\n },\n modifierBackgroundBlue: {\n background: colors.blue[500],\n },\n modifierBackgroundMagenta: {\n background: colors.purple[500],\n },\n modifierBackgroundCyan: {\n background: colors.cyan[500],\n },\n modifierBackgroundWhite: {\n background: colors.common.white,\n },\n modifierBackgroundGrey: {\n background: colors.grey[500],\n },\n textWrap: {\n whiteSpace: 'pre-wrap',\n wordBreak: 'break-all',\n },\n }),\n { name: 'BackstageLogViewer' },\n);\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport Box from '@material-ui/core/Box';\nimport IconButton from '@material-ui/core/IconButton';\nimport CopyIcon from '@material-ui/icons/FileCopy';\nimport classnames from 'classnames';\nimport { useEffect, useMemo, useRef, useState } from 'react';\nimport { useLocation } from 'react-router-dom';\nimport AutoSizer from 'react-virtualized-auto-sizer';\nimport { VariableSizeList, FixedSizeList } from 'react-window';\n\nimport { AnsiLine, AnsiProcessor } from './AnsiProcessor';\nimport { LogLine } from './LogLine';\nimport { LogViewerControls } from './LogViewerControls';\nimport { HEADER_SIZE, useStyles } from './styles';\nimport { useLogViewerSearch } from './useLogViewerSearch';\nimport { useLogViewerSelection } from './useLogViewerSelection';\n\nexport interface RealLogViewerProps {\n text: string;\n textWrap?: boolean;\n classes?: { root?: string };\n}\n\nexport function RealLogViewer(props: RealLogViewerProps) {\n const classes = useStyles({ classes: props.classes });\n const [listInstance, setListInstance] = useState<\n VariableSizeList<AnsiLine[]> | FixedSizeList<AnsiLine[]> | null\n >(null);\n const shouldTextWrap = props.textWrap ?? false;\n const heights = useRef<{ [key: number]: number }>({});\n\n // The processor keeps state that optimizes appending to the text\n const processor = useMemo(() => new AnsiProcessor(), []);\n const lines = processor.process(props.text);\n\n const search = useLogViewerSearch(lines);\n const selection = useLogViewerSelection(lines);\n const location = useLocation();\n\n useEffect(() => {\n if (listInstance) {\n listInstance.scrollToItem(lines.length - 1, 'end');\n }\n }, [listInstance, lines]);\n\n useEffect(() => {\n if (!listInstance) {\n return;\n }\n if (search.resultLine) {\n listInstance.scrollToItem(search.resultLine - 1, 'center');\n } else {\n listInstance.scrollToItem(lines.length - 1, 'end');\n }\n }, [listInstance, search.resultLine, lines]);\n\n useEffect(() => {\n if (location.hash) {\n // #line-6 -> 6\n const line = parseInt(location.hash.replace(/\\D/g, ''), 10);\n selection.setSelection(line, false);\n }\n }, []); // eslint-disable-line react-hooks/exhaustive-deps\n\n const handleSelectLine = (\n line: number,\n event: { shiftKey: boolean; preventDefault: () => void },\n ) => {\n selection.setSelection(line, event.shiftKey);\n };\n\n function setRowHeight(index: number, size: number) {\n if (shouldTextWrap && listInstance) {\n (listInstance as VariableSizeList<AnsiLine[]>).resetAfterIndex(0);\n // lineNumber is 1-based but index is 0-based\n heights.current[index - 1] = size;\n }\n }\n\n function getRowHeight(index: number) {\n return heights.current[index] || 20;\n }\n\n return (\n <AutoSizer>\n {({ height, width }: { height?: number; width?: number }) => {\n const commonProps = {\n ref: setListInstance,\n className: classes.log,\n height: (height || 480) - HEADER_SIZE,\n width: width || 640,\n itemData: search.lines,\n itemCount: search.lines.length,\n };\n\n const renderItem = ({\n index,\n style,\n data,\n }: {\n index: number;\n style: React.CSSProperties;\n data: AnsiLine[];\n }) => {\n const line = data[index];\n const { lineNumber } = line;\n return (\n <Box\n style={{ ...style }}\n className={classnames(classes.line, {\n [classes.lineSelected]: selection.isSelected(lineNumber),\n })}\n >\n {selection.shouldShowButton(lineNumber) && (\n <IconButton\n data-testid=\"copy-button\"\n size=\"small\"\n className={classes.lineCopyButton}\n onClick={() => selection.copySelection()}\n >\n <CopyIcon fontSize=\"inherit\" />\n </IconButton>\n )}\n <a\n role=\"row\"\n target=\"_self\"\n href={`#line-${lineNumber}`}\n className={classes.lineNumber}\n onClick={event => handleSelectLine(lineNumber, event)}\n onKeyPress={event => handleSelectLine(lineNumber, event)}\n >\n {lineNumber}\n </a>\n <LogLine\n setRowHeight={shouldTextWrap ? setRowHeight : undefined}\n line={line}\n classes={classes}\n searchText={search.searchText}\n highlightResultIndex={\n search.resultLine === lineNumber\n ? search.resultLineIndex\n : undefined\n }\n />\n </Box>\n );\n };\n\n return (\n <Box style={{ width, height }} className={classes.root}>\n <Box className={classes.header}>\n <LogViewerControls {...search} />\n </Box>\n {shouldTextWrap ? (\n <VariableSizeList<AnsiLine[]>\n {...commonProps}\n itemSize={getRowHeight}\n >\n {renderItem}\n </VariableSizeList>\n ) : (\n <FixedSizeList<AnsiLine[]> {...commonProps} itemSize={20}>\n {renderItem}\n </FixedSizeList>\n )}\n </Box>\n );\n }}\n </AutoSizer>\n );\n}\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { useMemo, useState } from 'react';\nimport { useToggle } from '@react-hookz/web';\nimport { AnsiLine } from './AnsiProcessor';\n\nexport function applySearchFilter(lines: AnsiLine[], searchText: string) {\n if (!searchText) {\n return { lines };\n }\n\n const matchingLines = [];\n const searchResults = [];\n for (const line of lines) {\n if (line.text.includes(searchText)) {\n matchingLines.push(line);\n\n let offset = 0;\n let lineResultIndex = 0;\n for (;;) {\n const start = line.text.indexOf(searchText, offset);\n if (start === -1) {\n break;\n }\n searchResults.push({\n lineNumber: line.lineNumber,\n lineIndex: lineResultIndex++,\n });\n offset = start + searchText.length;\n }\n }\n }\n\n return {\n lines: matchingLines,\n results: searchResults,\n };\n}\n\nexport interface LogViewerSearch {\n lines: AnsiLine[];\n\n searchText: string;\n searchInput: string;\n setSearchInput: (searchInput: string) => void;\n\n shouldFilter: boolean;\n toggleShouldFilter: () => void;\n\n resultCount: number | undefined;\n resultIndex: number | undefined;\n resultIndexStep: (decrement?: boolean) => void;\n\n resultLine: number | undefined;\n resultLineIndex: number | undefined;\n}\n\nexport function useLogViewerSearch(lines: AnsiLine[]): LogViewerSearch {\n const [searchInput, setSearchInput] = useState('');\n const searchText = searchInput.toLocaleLowerCase('en-US');\n\n const [resultIndex, setResultIndex] = useState<number>(0);\n\n const [shouldFilter, toggleShouldFilter] = useToggle(false);\n\n const filter = useMemo(\n () => applySearchFilter(lines, searchText),\n [lines, searchText],\n );\n\n const searchResult = filter.results\n ? filter.results[Math.min(resultIndex, filter.results.length - 1)]\n : undefined;\n const resultCount = filter.results?.length;\n\n const resultIndexStep = (decrement?: boolean) => {\n if (decrement) {\n if (resultCount !== undefined) {\n const next = Math.min(resultIndex - 1, resultCount - 2);\n setResultIndex(next < 0 ? resultCount - 1 : next);\n }\n } else {\n if (resultCount !== undefined) {\n const next = resultIndex + 1;\n setResultIndex(next >= resultCount ? 0 : next);\n }\n }\n };\n\n return {\n lines: shouldFilter ? filter.lines : lines,\n searchText,\n searchInput,\n setSearchInput,\n shouldFilter,\n toggleShouldFilter,\n resultCount,\n resultIndex,\n resultIndexStep,\n resultLine: searchResult?.lineNumber,\n resultLineIndex: searchResult?.lineIndex,\n };\n}\n","/*\n * Copyright 2021 The Backstage Authors\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { errorApiRef, useApi } from '@backstage/core-plugin-api';\nimport { useEffect, useState } from 'react';\nimport useCopyToClipboard from 'react-use/esm/useCopyToClipboard';\nimport { AnsiLine } from './AnsiProcessor';\n\nexport function useLogViewerSelection(lines: AnsiLine[]) {\n const errorApi = useApi(errorApiRef);\n const [sel, setSelection] = useState<{ start: number; end: number }>();\n const start = sel ? Math.min(sel.start, sel.end) : undefined;\n const end = sel ? Math.max(sel.start, sel.end) : undefined;\n\n const [{ error }, copyToClipboard] = useCopyToClipboard();\n\n useEffect(() => {\n if (error) {\n errorApi.post(error);\n }\n }, [error, errorApi]);\n\n return {\n shouldShowButton(line: number) {\n return start === line || end === line;\n },\n isSelected(line: number) {\n if (!sel) {\n return false;\n }\n return start! <= line && line <= end!;\n },\n setSelection(line: number, add: boolean) {\n if (add) {\n setSelection(s =>\n s ? { start: s.start, end: line } : { start: line, end: line },\n );\n } else {\n setSelection(s =>\n s?.start === line && s?.end === line\n ? undefined\n : { start: line, end: line },\n );\n }\n },\n copySelection() {\n if (sel) {\n const copyText = lines\n .slice(Math.min(sel.start, sel.end) - 1, Math.max(sel.start, sel.end))\n .map(l => l.chunks.map(c => c.text).join(''))\n .join('\\n');\n copyToClipboard(copyText);\n setSelection(undefined);\n }\n },\n };\n}\n"],"names":["ansiRegex","ansiRegexMaker","newlineRegex","codeModifiers","Object","m","_","code","modifier","AnsiLine","lineNumber","chunks","c","newChunks","AnsiProcessor","text","lastLineIndex","lastLine","lastChunk","newLines","modifiers","startingLineNumber","lines","currentModifiers","currentLineNumber","prevIndex","match","line","fullText","renderLink","attributes","content","href","props","Link","LogLine","classes","searchText","highlightResultIndex","setRowHeight","lineRef","useRef","useMemo","calculateHighlightedChunks","results","findSearchResults","searchResults","Array","offset","start","end","lineOffset","resultIndex","result","chunk","localOffset","localStart","Math","localEnd","hasTextBeforeResult","hasResultText","hasTextAfterResult","useEffect","elements","highlight","index","classnames","getModifierClasses","classNames","key","startCase","undefined","Linkify","LogViewerControls","t","useTranslationRef","coreComponentsTranslationRef","resultCount","resultIndexStep","toggleShouldFilter","IconButton","ChevronLeftIcon","Typography","ChevronRightIcon","TextField","event","e","FilterListIcon","useStyles","makeStyles","theme","alpha","colors","RealLogViewer","listInstance","setListInstance","useState","shouldTextWrap","heights","processor","search","useLogViewerSearch","searchInput","setSearchInput","setResultIndex","shouldFilter","useToggle","filter","applySearchFilter","matchingLines","lineResultIndex","searchResult","decrement","next","selection","useLogViewerSelection","errorApi","useApi","errorApiRef","sel","setSelection","error","copyToClipboard","useCopyToClipboard","add","s","l","location","useLocation","parseInt","handleSelectLine","size","getRowHeight","AutoSizer","height","width","commonProps","renderItem","style","data","Box","CopyIcon","VariableSizeList","FixedSizeList"],"mappings":"2RAkBA,IAAMA,EAAYC,AAAAA,GAAAA,A,SAAAA,CAAAA,AAAAA,IACZC,EAAe,SAGfC,EAAgBC,OAAO,WAAW,CACtCA,OAAO,OAAO,CAAC,CACb,EAAGC,AAAAA,GAAM,EAAE,GAAGA,CAAC,CAAE,KAAM,EAAK,GAC5B,EAAGA,AAAAA,GAAM,EAAE,GAAGA,CAAC,CAAE,OAAQ,EAAK,GAC9B,EAAGA,AAAAA,GAAM,EAAE,GAAGA,CAAC,CAAE,UAAW,EAAK,GACjC,GAAI,CAAC,CAAE,KAAMC,CAAC,CAAE,GAAGD,EAAG,GAAKA,EAC3B,GAAI,CAAC,CAAE,OAAQC,CAAC,CAAE,GAAGD,EAAG,GAAKA,EAC7B,GAAI,CAAC,CAAE,UAAWC,CAAC,CAAE,GAAGD,EAAG,GAAKA,EAChC,GAAIA,AAAAA,GAAM,EAAE,GAAGA,CAAC,CAAE,WAAY,OAAQ,GACtC,GAAIA,AAAAA,GAAM,EAAE,GAAGA,CAAC,CAAE,WAAY,KAAM,GACpC,GAAIA,AAAAA,GAAM,EAAE,GAAGA,CAAC,CAAE,WAAY,OAAQ,GACtC,GAAIA,AAAAA,GAA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