Skip to content

Commit 739db35

Browse files
Merge pull request #39 from oracle/release-notes-links
Open release notes links in external browser
2 parents 4af37f9 + 2247357 commit 739db35

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

webui/src/js/viewModels/app-update-dialog.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ function(accUtils, ko, i18n, viewHelper) {
2121
viewHelper.componentReady(this.dialogContainer).then(() => {
2222
this.dialogContainer.open();
2323
});
24+
25+
this.dialogContainer.addEventListener('click', this.clickHandler);
2426
};
2527

2628
this.labelMapper = (labelId, args) => {
@@ -44,6 +46,16 @@ function(accUtils, ko, i18n, viewHelper) {
4446
updateInfo.setValue('ignore');
4547
this.dialogContainer.close();
4648
};
49+
50+
this.clickHandler = (event) => {
51+
if (event.target.matches('.wkt-app-update-notes a')) {
52+
event.preventDefault();
53+
let link = event.target.href;
54+
if (link) {
55+
window.api.ipc.invoke('open-external-link', link).then();
56+
}
57+
}
58+
};
4759
}
4860

4961
return AppUpdateDialogModel;

0 commit comments

Comments
 (0)