@forgerock/iframe-manager 1.2.0 → 2.0.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/CHANGELOG.md +25 -0
- package/README.md +18 -18
- package/coverage/base.css +224 -0
- package/coverage/block-navigation.js +87 -0
- package/coverage/coverage-final.json +3 -0
- package/coverage/favicon.png +0 -0
- package/coverage/index.html +131 -0
- package/coverage/prettify.css +1 -0
- package/coverage/prettify.js +2 -0
- package/coverage/sort-arrow-sprite.png +0 -0
- package/coverage/sorter.js +210 -0
- package/coverage/src/index.html +116 -0
- package/coverage/src/index.ts.html +88 -0
- package/coverage/src/lib/iframe-manager.effects.ts.html +604 -0
- package/coverage/src/lib/index.html +116 -0
- package/dist/src/lib/iframe-manager.effects.d.ts +2 -3
- package/dist/src/lib/iframe-manager.effects.d.ts.map +1 -1
- package/dist/src/lib/iframe-manager.effects.js +4 -4
- package/dist/tsconfig.lib.tsbuildinfo +1 -1
- package/eslint.config.mjs +2 -2
- package/package.json +1 -1
- package/src/lib/iframe-manager.effects.ts +5 -5
- package/vite.config.ts +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,30 @@
|
|
|
1
1
|
# @forgerock/iframe-manager
|
|
2
2
|
|
|
3
|
+
## 2.0.0
|
|
4
|
+
|
|
5
|
+
### Major Changes
|
|
6
|
+
|
|
7
|
+
- [#502](https://github.com/ForgeRock/ping-javascript-sdk/pull/502) [`9ad4062`](https://github.com/ForgeRock/ping-javascript-sdk/commit/9ad406268dd568d8d6f6447a07b656e317a9da8d) Thanks [@ryanbas21](https://github.com/ryanbas21)! - releasing version 2 of the ping javascript sdk
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- [#526](https://github.com/ForgeRock/ping-javascript-sdk/pull/526) [`5a9ea40`](https://github.com/ForgeRock/ping-javascript-sdk/commit/5a9ea4079af4698f2d7df4bb5e7b40261aece15c) Thanks [@ancheetah](https://github.com/ancheetah)! - Update READMES. Fix types and comments.
|
|
12
|
+
|
|
13
|
+
## 1.3.0
|
|
14
|
+
|
|
15
|
+
### Minor Changes
|
|
16
|
+
|
|
17
|
+
- [#348](https://github.com/ForgeRock/ping-javascript-sdk/pull/348) [`beb349a`](https://github.com/ForgeRock/ping-javascript-sdk/commit/beb349a9a13e7bb8fbad35bf9bda9e340545cffa) Thanks [@cerebrl](https://github.com/cerebrl)! - Implemented token exchange within OIDC Client
|
|
18
|
+
|
|
19
|
+
- [#344](https://github.com/ForgeRock/ping-javascript-sdk/pull/344) [`dc4d4bd`](https://github.com/ForgeRock/ping-javascript-sdk/commit/dc4d4bdb5aa781660de631f45b22620e400d9f4a) Thanks [@cerebrl](https://github.com/cerebrl)! - Implement authorize functionality in oidc-client
|
|
20
|
+
- Provide authorize URL method for URL creation
|
|
21
|
+
- Provide background method for authorization without redirection
|
|
22
|
+
- Introduce Micro from the Effect package
|
|
23
|
+
|
|
24
|
+
- [#412](https://github.com/ForgeRock/ping-javascript-sdk/pull/412) [`b0f4368`](https://github.com/ForgeRock/ping-javascript-sdk/commit/b0f4368637a788c5472587f5232678312a7eabfe) Thanks [@ryanbas21](https://github.com/ryanbas21)! - feat: Update iframe-manager
|
|
25
|
+
- Updated ESLint configurations for consistent code style and linting rules.
|
|
26
|
+
- Ensured compatibility with `verbatimModuleSyntax` by correcting type-only imports and module exports.
|
|
27
|
+
|
|
3
28
|
## 1.2.0
|
|
4
29
|
|
|
5
30
|
### Minor Changes
|
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# IFrame Manager (`@
|
|
1
|
+
# IFrame Manager (`@forgerock/iframe-manager`)
|
|
2
2
|
|
|
3
3
|
## Overview
|
|
4
4
|
|
|
@@ -7,11 +7,11 @@ The IFrame Manager Effect provides a mechanism to perform operations within a hi
|
|
|
7
7
|
The core functionality involves:
|
|
8
8
|
|
|
9
9
|
1. Creating a hidden `<iframe>` dynamically.
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
10
|
+
2. Navigating the iframe to a specified URL.
|
|
11
|
+
3. Monitoring the iframe's `load` events to detect navigation changes.
|
|
12
|
+
4. Once a navigation occurs back to the **same origin** as the parent application, parsing the query parameters from the iframe's URL.
|
|
13
|
+
5. Resolving or rejecting a Promise based on the presence of predefined "success" or "error" query parameters.
|
|
14
|
+
6. Handling timeouts and potential errors (like cross-origin access restrictions).
|
|
15
15
|
|
|
16
16
|
**Key Constraint: Same-Origin Policy**
|
|
17
17
|
|
|
@@ -19,10 +19,8 @@ This utility fundamentally relies on the browser's **Same-Origin Policy**. The f
|
|
|
19
19
|
|
|
20
20
|
## Installation
|
|
21
21
|
|
|
22
|
-
This effect is typically part of a larger SDK. Assume it's imported or available within your project structure like so (adjust path as necessary):
|
|
23
|
-
|
|
24
22
|
```typescript
|
|
25
|
-
import iFrameManager from '
|
|
23
|
+
import iFrameManager from '@forgerock/iframe-manager';
|
|
26
24
|
|
|
27
25
|
const iframeMgr = iFrameManager();
|
|
28
26
|
```
|
|
@@ -40,19 +38,16 @@ This is the main factory function that initializes the effect.
|
|
|
40
38
|
This method creates a hidden iframe, initiates navigation, and waits for a redirect back to the application's origin containing specific query parameters.
|
|
41
39
|
|
|
42
40
|
- **`options`**: `GetParamsFromIFrameOptions` - An object containing configuration for the iframe request.
|
|
43
|
-
|
|
44
41
|
- **`url: string`**: The initial URL to load within the hidden iframe. This URL is expected to eventually redirect back to the application's origin.
|
|
45
42
|
- **`timeout: number`**: The maximum time in milliseconds to wait for the entire operation to complete successfully (i.e., for a redirect containing success or error parameters). If the timeout is reached before completion, the promise rejects.
|
|
46
|
-
|
|
47
43
|
* **`successParams: string[]`**: An array of query parameter _keys_. If the final redirect URL (on the same origin) contains **at least one** of these keys in its query string, the promise will **resolve**.
|
|
48
|
-
* **`errorParams: string[]`**: An array of query parameter _keys_. If the final redirect URL (on the same origin) contains **any** of these keys in its query string, the promise will **
|
|
44
|
+
* **`errorParams: string[]`**: An array of query parameter _keys_. If the final redirect URL (on the same origin) contains **any** of these keys in its query string, the promise will **resolve** with all parsed parameters (including the error parameters). The caller must check the returned parameters for error keys. Error parameters are checked _before_ success parameters.
|
|
49
45
|
- _Note:_ Both `successParams` and `errorParams` must be provided and contain at least one key.
|
|
50
46
|
|
|
51
47
|
- **Returns**: `Promise<ResolvedParams>`
|
|
52
|
-
|
|
53
48
|
- **On Success**: Resolves with `ResolvedParams`, an object containing _all_ query parameters parsed from the final redirect URL's query string. This occurs when the iframe redirects back to the same origin and its URL contains at least one key listed in `successParams` (and no keys listed in `errorParams`).
|
|
49
|
+
- **On Error Params**: Resolves with `ResolvedParams` containing _all_ parsed query parameters if the final redirect URL contains any key listed in `errorParams`. The caller must inspect the result for error keys.
|
|
54
50
|
- **On Failure**: Rejects with:
|
|
55
|
-
- `ResolvedParams`: An object containing _all_ parsed query parameters if the final redirect URL contains any key listed in `errorParams`.
|
|
56
51
|
- An object `{ type: 'internal_error', message: 'iframe timed out' }` if the specified `timeout` is reached before a success or error condition is met.
|
|
57
52
|
- An object `{ type: 'internal_error', message: 'unexpected failure' }` if there's an error accessing the iframe's content window (most likely due to a cross-origin redirect that wasn't expected or handled).
|
|
58
53
|
- An object `{ type: 'internal_error', message: 'error setting up iframe' }` if there was an issue creating or configuring the iframe initially.
|
|
@@ -63,7 +58,7 @@ This method creates a hidden iframe, initiates navigation, and waits for a redir
|
|
|
63
58
|
## Usage Example
|
|
64
59
|
|
|
65
60
|
```typescript
|
|
66
|
-
import iFrameManager from '
|
|
61
|
+
import iFrameManager from '@forgerock/iframe-manager';
|
|
67
62
|
|
|
68
63
|
const iframeMgr = iFrameManager();
|
|
69
64
|
|
|
@@ -77,10 +72,15 @@ async function performSilentLogin(authUrl: string) {
|
|
|
77
72
|
|
|
78
73
|
try {
|
|
79
74
|
console.log('Attempting silent login via iframe...');
|
|
80
|
-
// The promise resolves
|
|
81
|
-
// with appropriate query parameters.
|
|
75
|
+
// The promise resolves with all parsed params regardless of success/error.
|
|
82
76
|
const resultParams = await iframeMgr.getParamsByRedirect(options);
|
|
83
77
|
|
|
78
|
+
// Check if the server returned an error
|
|
79
|
+
if (resultParams.error || resultParams.error_description) {
|
|
80
|
+
console.error('Silent login failed. Server returned error:', resultParams);
|
|
81
|
+
return;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
84
|
// Success case: 'code', 'id_token', or 'session_state' was present
|
|
85
85
|
console.log('Silent login successful. Received params:', resultParams);
|
|
86
86
|
// Process the received parameters (e.g., exchange code for token)
|
|
@@ -117,4 +117,4 @@ performSilentLogin(authorizationUrl);
|
|
|
117
117
|
1. **Timeout:** Choose a reasonable `timeout` value. If the external service is slow or the redirect chain is long, the operation might time out prematurely. Conversely, too long a timeout might delay feedback to the user if something goes wrong.
|
|
118
118
|
1. **Intermediate Redirects:** The code handles intermediate redirects (pages loaded within the iframe that don't contain success or error parameters) by simply waiting for the next `load` event. The process only completes upon detecting success/error parameters or timing out.
|
|
119
119
|
1. **Cleanup:** The utility ensures the iframe element is removed from the DOM and the timeout timer is cleared upon completion (resolve, reject, or timeout) to prevent memory leaks.
|
|
120
|
-
1. **Error Parameter Precedence:** Error parameters (`errorParams`) are checked before success parameters (`successParams`). If a redirect URL contains both an error parameter and a success parameter, the promise will
|
|
120
|
+
1. **Error Parameter Precedence:** Error parameters (`errorParams`) are checked before success parameters (`successParams`). If a redirect URL contains both an error parameter and a success parameter, the promise will **resolve** with all parameters, and the caller must check for the error parameter keys to determine it's an error state.
|
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
body, html {
|
|
2
|
+
margin:0; padding: 0;
|
|
3
|
+
height: 100%;
|
|
4
|
+
}
|
|
5
|
+
body {
|
|
6
|
+
font-family: Helvetica Neue, Helvetica, Arial;
|
|
7
|
+
font-size: 14px;
|
|
8
|
+
color:#333;
|
|
9
|
+
}
|
|
10
|
+
.small { font-size: 12px; }
|
|
11
|
+
*, *:after, *:before {
|
|
12
|
+
-webkit-box-sizing:border-box;
|
|
13
|
+
-moz-box-sizing:border-box;
|
|
14
|
+
box-sizing:border-box;
|
|
15
|
+
}
|
|
16
|
+
h1 { font-size: 20px; margin: 0;}
|
|
17
|
+
h2 { font-size: 14px; }
|
|
18
|
+
pre {
|
|
19
|
+
font: 12px/1.4 Consolas, "Liberation Mono", Menlo, Courier, monospace;
|
|
20
|
+
margin: 0;
|
|
21
|
+
padding: 0;
|
|
22
|
+
-moz-tab-size: 2;
|
|
23
|
+
-o-tab-size: 2;
|
|
24
|
+
tab-size: 2;
|
|
25
|
+
}
|
|
26
|
+
a { color:#0074D9; text-decoration:none; }
|
|
27
|
+
a:hover { text-decoration:underline; }
|
|
28
|
+
.strong { font-weight: bold; }
|
|
29
|
+
.space-top1 { padding: 10px 0 0 0; }
|
|
30
|
+
.pad2y { padding: 20px 0; }
|
|
31
|
+
.pad1y { padding: 10px 0; }
|
|
32
|
+
.pad2x { padding: 0 20px; }
|
|
33
|
+
.pad2 { padding: 20px; }
|
|
34
|
+
.pad1 { padding: 10px; }
|
|
35
|
+
.space-left2 { padding-left:55px; }
|
|
36
|
+
.space-right2 { padding-right:20px; }
|
|
37
|
+
.center { text-align:center; }
|
|
38
|
+
.clearfix { display:block; }
|
|
39
|
+
.clearfix:after {
|
|
40
|
+
content:'';
|
|
41
|
+
display:block;
|
|
42
|
+
height:0;
|
|
43
|
+
clear:both;
|
|
44
|
+
visibility:hidden;
|
|
45
|
+
}
|
|
46
|
+
.fl { float: left; }
|
|
47
|
+
@media only screen and (max-width:640px) {
|
|
48
|
+
.col3 { width:100%; max-width:100%; }
|
|
49
|
+
.hide-mobile { display:none!important; }
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.quiet {
|
|
53
|
+
color: #7f7f7f;
|
|
54
|
+
color: rgba(0,0,0,0.5);
|
|
55
|
+
}
|
|
56
|
+
.quiet a { opacity: 0.7; }
|
|
57
|
+
|
|
58
|
+
.fraction {
|
|
59
|
+
font-family: Consolas, 'Liberation Mono', Menlo, Courier, monospace;
|
|
60
|
+
font-size: 10px;
|
|
61
|
+
color: #555;
|
|
62
|
+
background: #E8E8E8;
|
|
63
|
+
padding: 4px 5px;
|
|
64
|
+
border-radius: 3px;
|
|
65
|
+
vertical-align: middle;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
div.path a:link, div.path a:visited { color: #333; }
|
|
69
|
+
table.coverage {
|
|
70
|
+
border-collapse: collapse;
|
|
71
|
+
margin: 10px 0 0 0;
|
|
72
|
+
padding: 0;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
table.coverage td {
|
|
76
|
+
margin: 0;
|
|
77
|
+
padding: 0;
|
|
78
|
+
vertical-align: top;
|
|
79
|
+
}
|
|
80
|
+
table.coverage td.line-count {
|
|
81
|
+
text-align: right;
|
|
82
|
+
padding: 0 5px 0 20px;
|
|
83
|
+
}
|
|
84
|
+
table.coverage td.line-coverage {
|
|
85
|
+
text-align: right;
|
|
86
|
+
padding-right: 10px;
|
|
87
|
+
min-width:20px;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
table.coverage td span.cline-any {
|
|
91
|
+
display: inline-block;
|
|
92
|
+
padding: 0 5px;
|
|
93
|
+
width: 100%;
|
|
94
|
+
}
|
|
95
|
+
.missing-if-branch {
|
|
96
|
+
display: inline-block;
|
|
97
|
+
margin-right: 5px;
|
|
98
|
+
border-radius: 3px;
|
|
99
|
+
position: relative;
|
|
100
|
+
padding: 0 4px;
|
|
101
|
+
background: #333;
|
|
102
|
+
color: yellow;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.skip-if-branch {
|
|
106
|
+
display: none;
|
|
107
|
+
margin-right: 10px;
|
|
108
|
+
position: relative;
|
|
109
|
+
padding: 0 4px;
|
|
110
|
+
background: #ccc;
|
|
111
|
+
color: white;
|
|
112
|
+
}
|
|
113
|
+
.missing-if-branch .typ, .skip-if-branch .typ {
|
|
114
|
+
color: inherit !important;
|
|
115
|
+
}
|
|
116
|
+
.coverage-summary {
|
|
117
|
+
border-collapse: collapse;
|
|
118
|
+
width: 100%;
|
|
119
|
+
}
|
|
120
|
+
.coverage-summary tr { border-bottom: 1px solid #bbb; }
|
|
121
|
+
.keyline-all { border: 1px solid #ddd; }
|
|
122
|
+
.coverage-summary td, .coverage-summary th { padding: 10px; }
|
|
123
|
+
.coverage-summary tbody { border: 1px solid #bbb; }
|
|
124
|
+
.coverage-summary td { border-right: 1px solid #bbb; }
|
|
125
|
+
.coverage-summary td:last-child { border-right: none; }
|
|
126
|
+
.coverage-summary th {
|
|
127
|
+
text-align: left;
|
|
128
|
+
font-weight: normal;
|
|
129
|
+
white-space: nowrap;
|
|
130
|
+
}
|
|
131
|
+
.coverage-summary th.file { border-right: none !important; }
|
|
132
|
+
.coverage-summary th.pct { }
|
|
133
|
+
.coverage-summary th.pic,
|
|
134
|
+
.coverage-summary th.abs,
|
|
135
|
+
.coverage-summary td.pct,
|
|
136
|
+
.coverage-summary td.abs { text-align: right; }
|
|
137
|
+
.coverage-summary td.file { white-space: nowrap; }
|
|
138
|
+
.coverage-summary td.pic { min-width: 120px !important; }
|
|
139
|
+
.coverage-summary tfoot td { }
|
|
140
|
+
|
|
141
|
+
.coverage-summary .sorter {
|
|
142
|
+
height: 10px;
|
|
143
|
+
width: 7px;
|
|
144
|
+
display: inline-block;
|
|
145
|
+
margin-left: 0.5em;
|
|
146
|
+
background: url(sort-arrow-sprite.png) no-repeat scroll 0 0 transparent;
|
|
147
|
+
}
|
|
148
|
+
.coverage-summary .sorted .sorter {
|
|
149
|
+
background-position: 0 -20px;
|
|
150
|
+
}
|
|
151
|
+
.coverage-summary .sorted-desc .sorter {
|
|
152
|
+
background-position: 0 -10px;
|
|
153
|
+
}
|
|
154
|
+
.status-line { height: 10px; }
|
|
155
|
+
/* yellow */
|
|
156
|
+
.cbranch-no { background: yellow !important; color: #111; }
|
|
157
|
+
/* dark red */
|
|
158
|
+
.red.solid, .status-line.low, .low .cover-fill { background:#C21F39 }
|
|
159
|
+
.low .chart { border:1px solid #C21F39 }
|
|
160
|
+
.highlighted,
|
|
161
|
+
.highlighted .cstat-no, .highlighted .fstat-no, .highlighted .cbranch-no{
|
|
162
|
+
background: #C21F39 !important;
|
|
163
|
+
}
|
|
164
|
+
/* medium red */
|
|
165
|
+
.cstat-no, .fstat-no, .cbranch-no, .cbranch-no { background:#F6C6CE }
|
|
166
|
+
/* light red */
|
|
167
|
+
.low, .cline-no { background:#FCE1E5 }
|
|
168
|
+
/* light green */
|
|
169
|
+
.high, .cline-yes { background:rgb(230,245,208) }
|
|
170
|
+
/* medium green */
|
|
171
|
+
.cstat-yes { background:rgb(161,215,106) }
|
|
172
|
+
/* dark green */
|
|
173
|
+
.status-line.high, .high .cover-fill { background:rgb(77,146,33) }
|
|
174
|
+
.high .chart { border:1px solid rgb(77,146,33) }
|
|
175
|
+
/* dark yellow (gold) */
|
|
176
|
+
.status-line.medium, .medium .cover-fill { background: #f9cd0b; }
|
|
177
|
+
.medium .chart { border:1px solid #f9cd0b; }
|
|
178
|
+
/* light yellow */
|
|
179
|
+
.medium { background: #fff4c2; }
|
|
180
|
+
|
|
181
|
+
.cstat-skip { background: #ddd; color: #111; }
|
|
182
|
+
.fstat-skip { background: #ddd; color: #111 !important; }
|
|
183
|
+
.cbranch-skip { background: #ddd !important; color: #111; }
|
|
184
|
+
|
|
185
|
+
span.cline-neutral { background: #eaeaea; }
|
|
186
|
+
|
|
187
|
+
.coverage-summary td.empty {
|
|
188
|
+
opacity: .5;
|
|
189
|
+
padding-top: 4px;
|
|
190
|
+
padding-bottom: 4px;
|
|
191
|
+
line-height: 1;
|
|
192
|
+
color: #888;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
.cover-fill, .cover-empty {
|
|
196
|
+
display:inline-block;
|
|
197
|
+
height: 12px;
|
|
198
|
+
}
|
|
199
|
+
.chart {
|
|
200
|
+
line-height: 0;
|
|
201
|
+
}
|
|
202
|
+
.cover-empty {
|
|
203
|
+
background: white;
|
|
204
|
+
}
|
|
205
|
+
.cover-full {
|
|
206
|
+
border-right: none !important;
|
|
207
|
+
}
|
|
208
|
+
pre.prettyprint {
|
|
209
|
+
border: none !important;
|
|
210
|
+
padding: 0 !important;
|
|
211
|
+
margin: 0 !important;
|
|
212
|
+
}
|
|
213
|
+
.com { color: #999 !important; }
|
|
214
|
+
.ignore-none { color: #999; font-weight: normal; }
|
|
215
|
+
|
|
216
|
+
.wrapper {
|
|
217
|
+
min-height: 100%;
|
|
218
|
+
height: auto !important;
|
|
219
|
+
height: 100%;
|
|
220
|
+
margin: 0 auto -48px;
|
|
221
|
+
}
|
|
222
|
+
.footer, .push {
|
|
223
|
+
height: 48px;
|
|
224
|
+
}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
var jumpToCode = (function init() {
|
|
3
|
+
// Classes of code we would like to highlight in the file view
|
|
4
|
+
var missingCoverageClasses = ['.cbranch-no', '.cstat-no', '.fstat-no'];
|
|
5
|
+
|
|
6
|
+
// Elements to highlight in the file listing view
|
|
7
|
+
var fileListingElements = ['td.pct.low'];
|
|
8
|
+
|
|
9
|
+
// We don't want to select elements that are direct descendants of another match
|
|
10
|
+
var notSelector = ':not(' + missingCoverageClasses.join('):not(') + ') > '; // becomes `:not(a):not(b) > `
|
|
11
|
+
|
|
12
|
+
// Selector that finds elements on the page to which we can jump
|
|
13
|
+
var selector =
|
|
14
|
+
fileListingElements.join(', ') +
|
|
15
|
+
', ' +
|
|
16
|
+
notSelector +
|
|
17
|
+
missingCoverageClasses.join(', ' + notSelector); // becomes `:not(a):not(b) > a, :not(a):not(b) > b`
|
|
18
|
+
|
|
19
|
+
// The NodeList of matching elements
|
|
20
|
+
var missingCoverageElements = document.querySelectorAll(selector);
|
|
21
|
+
|
|
22
|
+
var currentIndex;
|
|
23
|
+
|
|
24
|
+
function toggleClass(index) {
|
|
25
|
+
missingCoverageElements
|
|
26
|
+
.item(currentIndex)
|
|
27
|
+
.classList.remove('highlighted');
|
|
28
|
+
missingCoverageElements.item(index).classList.add('highlighted');
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
function makeCurrent(index) {
|
|
32
|
+
toggleClass(index);
|
|
33
|
+
currentIndex = index;
|
|
34
|
+
missingCoverageElements.item(index).scrollIntoView({
|
|
35
|
+
behavior: 'smooth',
|
|
36
|
+
block: 'center',
|
|
37
|
+
inline: 'center'
|
|
38
|
+
});
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
function goToPrevious() {
|
|
42
|
+
var nextIndex = 0;
|
|
43
|
+
if (typeof currentIndex !== 'number' || currentIndex === 0) {
|
|
44
|
+
nextIndex = missingCoverageElements.length - 1;
|
|
45
|
+
} else if (missingCoverageElements.length > 1) {
|
|
46
|
+
nextIndex = currentIndex - 1;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
makeCurrent(nextIndex);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
function goToNext() {
|
|
53
|
+
var nextIndex = 0;
|
|
54
|
+
|
|
55
|
+
if (
|
|
56
|
+
typeof currentIndex === 'number' &&
|
|
57
|
+
currentIndex < missingCoverageElements.length - 1
|
|
58
|
+
) {
|
|
59
|
+
nextIndex = currentIndex + 1;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
makeCurrent(nextIndex);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
return function jump(event) {
|
|
66
|
+
if (
|
|
67
|
+
document.getElementById('fileSearch') === document.activeElement &&
|
|
68
|
+
document.activeElement != null
|
|
69
|
+
) {
|
|
70
|
+
// if we're currently focused on the search input, we don't want to navigate
|
|
71
|
+
return;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
switch (event.which) {
|
|
75
|
+
case 78: // n
|
|
76
|
+
case 74: // j
|
|
77
|
+
goToNext();
|
|
78
|
+
break;
|
|
79
|
+
case 66: // b
|
|
80
|
+
case 75: // k
|
|
81
|
+
case 80: // p
|
|
82
|
+
goToPrevious();
|
|
83
|
+
break;
|
|
84
|
+
}
|
|
85
|
+
};
|
|
86
|
+
})();
|
|
87
|
+
window.addEventListener('keydown', jumpToCode);
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
{"/home/workflows/workspace/packages/sdk-effects/iframe-manager/src/index.ts": {"path":"/home/workflows/workspace/packages/sdk-effects/iframe-manager/src/index.ts","all":true,"statementMap":{"0":{"start":{"line":1,"column":0},"end":{"line":1,"column":48}}},"s":{"0":0},"branchMap":{"0":{"type":"branch","line":1,"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":48}},"locations":[{"start":{"line":1,"column":0},"end":{"line":1,"column":48}}]}},"b":{"0":[0]},"fnMap":{"0":{"name":"(empty-report)","decl":{"start":{"line":1,"column":0},"end":{"line":1,"column":48}},"loc":{"start":{"line":1,"column":0},"end":{"line":1,"column":48}},"line":1}},"f":{"0":0}}
|
|
2
|
+
,"/home/workflows/workspace/packages/sdk-effects/iframe-manager/src/lib/iframe-manager.effects.ts": {"path":"/home/workflows/workspace/packages/sdk-effects/iframe-manager/src/lib/iframe-manager.effects.ts","all":true,"statementMap":{"24":{"start":{"line":25,"column":0},"end":{"line":25,"column":82}},"25":{"start":{"line":26,"column":0},"end":{"line":26,"column":34}},"26":{"start":{"line":27,"column":0},"end":{"line":27,"column":26}},"27":{"start":{"line":28,"column":0},"end":{"line":28,"column":18}},"28":{"start":{"line":29,"column":0},"end":{"line":29,"column":5}},"29":{"start":{"line":30,"column":0},"end":{"line":30,"column":3}},"30":{"start":{"line":31,"column":0},"end":{"line":31,"column":15}},"31":{"start":{"line":32,"column":0},"end":{"line":32,"column":1}},"34":{"start":{"line":35,"column":0},"end":{"line":35,"column":90}},"35":{"start":{"line":36,"column":0},"end":{"line":36,"column":54}},"36":{"start":{"line":37,"column":0},"end":{"line":37,"column":1}},"38":{"start":{"line":39,"column":0},"end":{"line":39,"column":72}},"39":{"start":{"line":40,"column":0},"end":{"line":40,"column":36}},"40":{"start":{"line":41,"column":0},"end":{"line":41,"column":34}},"41":{"start":{"line":42,"column":0},"end":{"line":42,"column":24}},"42":{"start":{"line":43,"column":0},"end":{"line":43,"column":5}},"43":{"start":{"line":44,"column":0},"end":{"line":44,"column":16}},"44":{"start":{"line":45,"column":0},"end":{"line":45,"column":1}},"50":{"start":{"line":51,"column":0},"end":{"line":51,"column":33}},"63":{"start":{"line":64,"column":0},"end":{"line":64,"column":10}},"64":{"start":{"line":65,"column":0},"end":{"line":65,"column":92}},"65":{"start":{"line":66,"column":0},"end":{"line":66,"column":67}},"67":{"start":{"line":68,"column":0},"end":{"line":68,"column":10}},"68":{"start":{"line":69,"column":0},"end":{"line":69,"column":25}},"69":{"start":{"line":70,"column":0},"end":{"line":70,"column":23}},"70":{"start":{"line":71,"column":0},"end":{"line":71,"column":37}},"71":{"start":{"line":72,"column":0},"end":{"line":72,"column":32}},"72":{"start":{"line":73,"column":0},"end":{"line":73,"column":9}},"73":{"start":{"line":74,"column":0},"end":{"line":74,"column":82}},"74":{"start":{"line":75,"column":0},"end":{"line":75,"column":20}},"75":{"start":{"line":76,"column":0},"end":{"line":76,"column":7}},"77":{"start":{"line":78,"column":0},"end":{"line":78,"column":63}},"78":{"start":{"line":79,"column":0},"end":{"line":79,"column":52}},"79":{"start":{"line":80,"column":0},"end":{"line":80,"column":65}},"81":{"start":{"line":82,"column":0},"end":{"line":82,"column":49}},"82":{"start":{"line":83,"column":0},"end":{"line":83,"column":37}},"84":{"start":{"line":85,"column":0},"end":{"line":85,"column":31}},"85":{"start":{"line":86,"column":0},"end":{"line":86,"column":42}},"87":{"start":{"line":88,"column":0},"end":{"line":88,"column":24}},"88":{"start":{"line":89,"column":0},"end":{"line":89,"column":34}},"89":{"start":{"line":90,"column":0},"end":{"line":90,"column":27}},"90":{"start":{"line":91,"column":0},"end":{"line":91,"column":11}},"91":{"start":{"line":92,"column":0},"end":{"line":92,"column":23}},"92":{"start":{"line":93,"column":0},"end":{"line":93,"column":62}},"93":{"start":{"line":94,"column":0},"end":{"line":94,"column":36}},"94":{"start":{"line":95,"column":0},"end":{"line":95,"column":30}},"95":{"start":{"line":96,"column":0},"end":{"line":96,"column":13}},"96":{"start":{"line":97,"column":0},"end":{"line":97,"column":26}},"97":{"start":{"line":98,"column":0},"end":{"line":98,"column":11}},"98":{"start":{"line":99,"column":0},"end":{"line":99,"column":35}},"99":{"start":{"line":100,"column":0},"end":{"line":100,"column":29}},"100":{"start":{"line":101,"column":0},"end":{"line":101,"column":10}},"102":{"start":{"line":103,"column":0},"end":{"line":103,"column":37}},"103":{"start":{"line":104,"column":0},"end":{"line":104,"column":15}},"104":{"start":{"line":105,"column":0},"end":{"line":105,"column":49}},"105":{"start":{"line":106,"column":0},"end":{"line":106,"column":75}},"107":{"start":{"line":108,"column":0},"end":{"line":108,"column":78}},"108":{"start":{"line":109,"column":0},"end":{"line":109,"column":53}},"109":{"start":{"line":110,"column":0},"end":{"line":110,"column":15}},"111":{"start":{"line":112,"column":0},"end":{"line":112,"column":61}},"112":{"start":{"line":113,"column":0},"end":{"line":113,"column":60}},"113":{"start":{"line":114,"column":0},"end":{"line":114,"column":70}},"116":{"start":{"line":117,"column":0},"end":{"line":117,"column":62}},"117":{"start":{"line":118,"column":0},"end":{"line":118,"column":26}},"118":{"start":{"line":119,"column":0},"end":{"line":119,"column":84}},"119":{"start":{"line":120,"column":0},"end":{"line":120,"column":23}},"120":{"start":{"line":121,"column":0},"end":{"line":121,"column":15}},"123":{"start":{"line":124,"column":0},"end":{"line":124,"column":70}},"124":{"start":{"line":125,"column":0},"end":{"line":125,"column":26}},"125":{"start":{"line":126,"column":0},"end":{"line":126,"column":72}},"126":{"start":{"line":127,"column":0},"end":{"line":127,"column":23}},"127":{"start":{"line":128,"column":0},"end":{"line":128,"column":15}},"136":{"start":{"line":137,"column":0},"end":{"line":137,"column":13}},"137":{"start":{"line":138,"column":0},"end":{"line":138,"column":19}},"139":{"start":{"line":140,"column":0},"end":{"line":140,"column":22}},"140":{"start":{"line":141,"column":0},"end":{"line":141,"column":20}},"141":{"start":{"line":142,"column":0},"end":{"line":142,"column":37}},"142":{"start":{"line":143,"column":0},"end":{"line":143,"column":44}},"143":{"start":{"line":144,"column":0},"end":{"line":144,"column":15}},"144":{"start":{"line":145,"column":0},"end":{"line":145,"column":11}},"145":{"start":{"line":146,"column":0},"end":{"line":146,"column":10}},"147":{"start":{"line":148,"column":0},"end":{"line":148,"column":13}},"148":{"start":{"line":149,"column":0},"end":{"line":149,"column":52}},"149":{"start":{"line":150,"column":0},"end":{"line":150,"column":59}},"150":{"start":{"line":151,"column":0},"end":{"line":151,"column":57}},"151":{"start":{"line":152,"column":0},"end":{"line":152,"column":44}},"153":{"start":{"line":154,"column":0},"end":{"line":154,"column":38}},"154":{"start":{"line":155,"column":0},"end":{"line":155,"column":22}},"155":{"start":{"line":156,"column":0},"end":{"line":156,"column":20}},"156":{"start":{"line":157,"column":0},"end":{"line":157,"column":37}},"157":{"start":{"line":158,"column":0},"end":{"line":158,"column":42}},"158":{"start":{"line":159,"column":0},"end":{"line":159,"column":15}},"159":{"start":{"line":160,"column":0},"end":{"line":160,"column":22}},"161":{"start":{"line":162,"column":0},"end":{"line":162,"column":27}},"162":{"start":{"line":163,"column":0},"end":{"line":163,"column":17}},"163":{"start":{"line":164,"column":0},"end":{"line":164,"column":70}},"164":{"start":{"line":165,"column":0},"end":{"line":165,"column":18}},"165":{"start":{"line":166,"column":0},"end":{"line":166,"column":35}},"166":{"start":{"line":167,"column":0},"end":{"line":167,"column":47}},"167":{"start":{"line":168,"column":0},"end":{"line":168,"column":13}},"168":{"start":{"line":169,"column":0},"end":{"line":169,"column":9}},"169":{"start":{"line":170,"column":0},"end":{"line":170,"column":9}},"170":{"start":{"line":171,"column":0},"end":{"line":171,"column":6}},"171":{"start":{"line":172,"column":0},"end":{"line":172,"column":4}},"172":{"start":{"line":173,"column":0},"end":{"line":173,"column":1}}},"s":{"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"34":0,"35":0,"36":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"50":0,"63":0,"64":0,"65":0,"67":0,"68":0,"69":0,"70":0,"71":0,"72":0,"73":0,"74":0,"75":0,"77":0,"78":0,"79":0,"81":0,"82":0,"84":0,"85":0,"87":0,"88":0,"89":0,"90":0,"91":0,"92":0,"93":0,"94":0,"95":0,"96":0,"97":0,"98":0,"99":0,"100":0,"102":0,"103":0,"104":0,"105":0,"107":0,"108":0,"109":0,"111":0,"112":0,"113":0,"116":0,"117":0,"118":0,"119":0,"120":0,"123":0,"124":0,"125":0,"126":0,"127":0,"136":0,"137":0,"139":0,"140":0,"141":0,"142":0,"143":0,"144":0,"145":0,"147":0,"148":0,"149":0,"150":0,"151":0,"153":0,"154":0,"155":0,"156":0,"157":0,"158":0,"159":0,"161":0,"162":0,"163":0,"164":0,"165":0,"166":0,"167":0,"168":0,"169":0,"170":0,"171":0,"172":0},"branchMap":{"0":{"type":"branch","line":1,"loc":{"start":{"line":1,"column":5829},"end":{"line":173,"column":1}},"locations":[{"start":{"line":1,"column":5829},"end":{"line":173,"column":1}}]}},"b":{"0":[1]},"fnMap":{"0":{"name":"(empty-report)","decl":{"start":{"line":1,"column":5829},"end":{"line":173,"column":1}},"loc":{"start":{"line":1,"column":5829},"end":{"line":173,"column":1}},"line":1}},"f":{"0":1}}
|
|
3
|
+
}
|
|
Binary file
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
|
|
2
|
+
<!doctype html>
|
|
3
|
+
<html lang="en">
|
|
4
|
+
|
|
5
|
+
<head>
|
|
6
|
+
<title>Code coverage report for All files</title>
|
|
7
|
+
<meta charset="utf-8" />
|
|
8
|
+
<link rel="stylesheet" href="prettify.css" />
|
|
9
|
+
<link rel="stylesheet" href="base.css" />
|
|
10
|
+
<link rel="shortcut icon" type="image/x-icon" href="favicon.png" />
|
|
11
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
12
|
+
<style type='text/css'>
|
|
13
|
+
.coverage-summary .sorter {
|
|
14
|
+
background-image: url(sort-arrow-sprite.png);
|
|
15
|
+
}
|
|
16
|
+
</style>
|
|
17
|
+
</head>
|
|
18
|
+
|
|
19
|
+
<body>
|
|
20
|
+
<div class='wrapper'>
|
|
21
|
+
<div class='pad1'>
|
|
22
|
+
<h1>All files</h1>
|
|
23
|
+
<div class='clearfix'>
|
|
24
|
+
|
|
25
|
+
<div class='fl pad1y space-right2'>
|
|
26
|
+
<span class="strong">0% </span>
|
|
27
|
+
<span class="quiet">Statements</span>
|
|
28
|
+
<span class='fraction'>0/106</span>
|
|
29
|
+
</div>
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
<div class='fl pad1y space-right2'>
|
|
33
|
+
<span class="strong">50% </span>
|
|
34
|
+
<span class="quiet">Branches</span>
|
|
35
|
+
<span class='fraction'>1/2</span>
|
|
36
|
+
</div>
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
<div class='fl pad1y space-right2'>
|
|
40
|
+
<span class="strong">50% </span>
|
|
41
|
+
<span class="quiet">Functions</span>
|
|
42
|
+
<span class='fraction'>1/2</span>
|
|
43
|
+
</div>
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
<div class='fl pad1y space-right2'>
|
|
47
|
+
<span class="strong">0% </span>
|
|
48
|
+
<span class="quiet">Lines</span>
|
|
49
|
+
<span class='fraction'>0/106</span>
|
|
50
|
+
</div>
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
</div>
|
|
54
|
+
<p class="quiet">
|
|
55
|
+
Press <em>n</em> or <em>j</em> to go to the next uncovered block, <em>b</em>, <em>p</em> or <em>k</em> for the previous block.
|
|
56
|
+
</p>
|
|
57
|
+
<template id="filterTemplate">
|
|
58
|
+
<div class="quiet">
|
|
59
|
+
Filter:
|
|
60
|
+
<input type="search" id="fileSearch">
|
|
61
|
+
</div>
|
|
62
|
+
</template>
|
|
63
|
+
</div>
|
|
64
|
+
<div class='status-line low'></div>
|
|
65
|
+
<div class="pad1">
|
|
66
|
+
<table class="coverage-summary">
|
|
67
|
+
<thead>
|
|
68
|
+
<tr>
|
|
69
|
+
<th data-col="file" data-fmt="html" data-html="true" class="file">File</th>
|
|
70
|
+
<th data-col="pic" data-type="number" data-fmt="html" data-html="true" class="pic"></th>
|
|
71
|
+
<th data-col="statements" data-type="number" data-fmt="pct" class="pct">Statements</th>
|
|
72
|
+
<th data-col="statements_raw" data-type="number" data-fmt="html" class="abs"></th>
|
|
73
|
+
<th data-col="branches" data-type="number" data-fmt="pct" class="pct">Branches</th>
|
|
74
|
+
<th data-col="branches_raw" data-type="number" data-fmt="html" class="abs"></th>
|
|
75
|
+
<th data-col="functions" data-type="number" data-fmt="pct" class="pct">Functions</th>
|
|
76
|
+
<th data-col="functions_raw" data-type="number" data-fmt="html" class="abs"></th>
|
|
77
|
+
<th data-col="lines" data-type="number" data-fmt="pct" class="pct">Lines</th>
|
|
78
|
+
<th data-col="lines_raw" data-type="number" data-fmt="html" class="abs"></th>
|
|
79
|
+
</tr>
|
|
80
|
+
</thead>
|
|
81
|
+
<tbody><tr>
|
|
82
|
+
<td class="file low" data-value="src"><a href="src/index.html">src</a></td>
|
|
83
|
+
<td data-value="0" class="pic low">
|
|
84
|
+
<div class="chart"><div class="cover-fill" style="width: 0%"></div><div class="cover-empty" style="width: 100%"></div></div>
|
|
85
|
+
</td>
|
|
86
|
+
<td data-value="0" class="pct low">0%</td>
|
|
87
|
+
<td data-value="1" class="abs low">0/1</td>
|
|
88
|
+
<td data-value="0" class="pct low">0%</td>
|
|
89
|
+
<td data-value="1" class="abs low">0/1</td>
|
|
90
|
+
<td data-value="0" class="pct low">0%</td>
|
|
91
|
+
<td data-value="1" class="abs low">0/1</td>
|
|
92
|
+
<td data-value="0" class="pct low">0%</td>
|
|
93
|
+
<td data-value="1" class="abs low">0/1</td>
|
|
94
|
+
</tr>
|
|
95
|
+
|
|
96
|
+
<tr>
|
|
97
|
+
<td class="file low" data-value="src/lib"><a href="src/lib/index.html">src/lib</a></td>
|
|
98
|
+
<td data-value="0" class="pic low">
|
|
99
|
+
<div class="chart"><div class="cover-fill" style="width: 0%"></div><div class="cover-empty" style="width: 100%"></div></div>
|
|
100
|
+
</td>
|
|
101
|
+
<td data-value="0" class="pct low">0%</td>
|
|
102
|
+
<td data-value="105" class="abs low">0/105</td>
|
|
103
|
+
<td data-value="100" class="pct high">100%</td>
|
|
104
|
+
<td data-value="1" class="abs high">1/1</td>
|
|
105
|
+
<td data-value="100" class="pct high">100%</td>
|
|
106
|
+
<td data-value="1" class="abs high">1/1</td>
|
|
107
|
+
<td data-value="0" class="pct low">0%</td>
|
|
108
|
+
<td data-value="105" class="abs low">0/105</td>
|
|
109
|
+
</tr>
|
|
110
|
+
|
|
111
|
+
</tbody>
|
|
112
|
+
</table>
|
|
113
|
+
</div>
|
|
114
|
+
<div class='push'></div><!-- for sticky footer -->
|
|
115
|
+
</div><!-- /wrapper -->
|
|
116
|
+
<div class='footer quiet pad2 space-top1 center small'>
|
|
117
|
+
Code coverage generated by
|
|
118
|
+
<a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
|
|
119
|
+
at 2026-03-19T17:04:15.646Z
|
|
120
|
+
</div>
|
|
121
|
+
<script src="prettify.js"></script>
|
|
122
|
+
<script>
|
|
123
|
+
window.onload = function () {
|
|
124
|
+
prettyPrint();
|
|
125
|
+
};
|
|
126
|
+
</script>
|
|
127
|
+
<script src="sorter.js"></script>
|
|
128
|
+
<script src="block-navigation.js"></script>
|
|
129
|
+
</body>
|
|
130
|
+
</html>
|
|
131
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.pln{color:#000}@media screen{.str{color:#080}.kwd{color:#008}.com{color:#800}.typ{color:#606}.lit{color:#066}.pun,.opn,.clo{color:#660}.tag{color:#008}.atn{color:#606}.atv{color:#080}.dec,.var{color:#606}.fun{color:red}}@media print,projection{.str{color:#060}.kwd{color:#006;font-weight:bold}.com{color:#600;font-style:italic}.typ{color:#404;font-weight:bold}.lit{color:#044}.pun,.opn,.clo{color:#440}.tag{color:#006;font-weight:bold}.atn{color:#404}.atv{color:#060}}pre.prettyprint{padding:2px;border:1px solid #888}ol.linenums{margin-top:0;margin-bottom:0}li.L0,li.L1,li.L2,li.L3,li.L5,li.L6,li.L7,li.L8{list-style-type:none}li.L1,li.L3,li.L5,li.L7,li.L9{background:#eee}
|