Add rel="noopener" to anchor elements with target="_blank" (#9369)

* Add rel="noopener" to anchor elements with target="_blank"

* Add rel="noopener" to language files as well

* Fix link, link tp https and link to umbraco.com

* Add noreferrer value
This commit is contained in:
Bjarne Fyrstenborg
2020-12-05 02:13:41 +01:00
committed by GitHub
parent be0ac5e3f3
commit 0b6752e115
35 changed files with 159 additions and 156 deletions

View File

@@ -97,7 +97,7 @@
</h5>
<ul class="umb-help-list">
<li class="umb-help-list-item" ng-repeat="topic in vm.topics track by $index">
<a class="umb-help-list-item__content" data-element="help-article-{{topic.name}}" target="_blank" rel="noopener" href="" ng-href="{{topic.url}}?utm_source=core&utm_medium=help&utm_content=link&utm_campaign=tv">
<a class="umb-help-list-item__content" data-element="help-article-{{topic.name}}" href="#" ng-href="{{topic.url}}?utm_source=core&utm_medium=help&utm_content=link&utm_campaign=tv" target="_blank" rel="noopener">
<span>
<span class="umb-help-list-item__title">
<span class="bold">{{topic.name}}</span>
@@ -110,14 +110,14 @@
</ul>
</div>
<!-- Umbraco tv content -->
<!-- Umbraco tv content -->
<div class="umb-help-section" data-element="help-videos" ng-if="vm.hasAccessToSettings">
<h5 class="umb-help-section__title" ng-if="vm.videos.length > 0">
<localize key="general_videos">Videos</localize>
</h5>
<ul class="umb-help-list">
<li class="umb-help-list-item" ng-repeat="video in vm.videos track by $index">
<a class="umb-help-list-item__content" data-element="help-article-{{video.title}}" target="_blank" rel="noopener" href="" ng-href="{{video.link}}?utm_source=core&utm_medium=help&utm_content=link&utm_campaign=tv">
<a class="umb-help-list-item__content" data-element="help-article-{{video.title}}" href="#" ng-href="{{video.link}}?utm_source=core&utm_medium=help&utm_content=link&utm_campaign=tv" target="_blank" rel="noopener">
<i class="umb-help-list-item__icon icon-tv-old" aria-hidden="true"></i>
<span class="umb-help-list-item__title">{{video.title}}</span>
<i class="umb-help-list-item__open-icon icon-out" aria-hidden="true"></i>
@@ -126,9 +126,9 @@
</ul>
</div>
<!-- Links -->
<!-- Links -->
<div class="umb-help-section" data-element="help-links" ng-if="vm.hasAccessToSettings">
<a data-element="help-link-umbraco-tv" class="umb-help-badge" target="_blank" rel="noopener" href="https://umbraco.tv?utm_source=core&utm_medium=help&utm_content=link&utm_campaign=tv">
<a data-element="help-link-umbraco-tv" class="umb-help-badge" href="https://umbraco.tv?utm_source=core&utm_medium=help&utm_content=link&utm_campaign=tv" target="_blank" rel="noopener">
<i class="umb-help-badge__icon icon-tv-old" aria-hidden="true"></i>
<div class="umb-help-badge__title">
<localize key="help_umbracoTv">Visit umbraco.tv</localize>
@@ -138,7 +138,7 @@
</small>
</a>
<a data-element="help-link-our-umbraco" class="umb-help-badge" target="_blank" rel="noopener" href="https://our.umbraco.com?utm_source=core&utm_medium=help&utm_content=link&utm_campaign=our">
<a data-element="help-link-our-umbraco" class="umb-help-badge" href="https://our.umbraco.com?utm_source=core&utm_medium=help&utm_content=link&utm_campaign=our" target="_blank" rel="noopener">
<i class="umb-help-badge__icon icon-favorite" aria-hidden="true"></i>
<div class="umb-help-badge__title">

View File

@@ -7,8 +7,9 @@
<umb-box-content class="block-form">
<ul class="nav nav-stacked mb0">
<li ng-repeat="url in currentUrls">
<a href="{{url.text}}" target="_blank" ng-if="url.isUrl" class="umb-outline">
<a href="{{url.text}}" target="_blank" rel="noopener" ng-if="url.isUrl" class="umb-outline">
<span ng-if="currentUrlsHaveMultipleCultures && url.culture" style="font-size: 13px; color: #cccccc; width: 55px;display: inline-block">{{url.culture}}</span>
<i class="icon icon-out" aria-hidden="true"></i>
<span>{{url.text}}</span>
</a>
<div ng-if="!url.isUrl" style="margin-top: 4px;">
@@ -29,7 +30,7 @@
<p><localize key="redirectUrls_panelInformation" class="ng-isolate-scope ng-scope">The following URLs redirect to this content item:</localize></p>
<ul class="nav nav-stacked" style="margin-bottom: 0;">
<li ng-repeat="redirectUrl in redirectUrls">
<a href="{{redirectUrl.originalUrl}}" target="_blank" class="umb-outline">
<a href="{{redirectUrl.originalUrl}}" target="_blank" rel="noopener" class="umb-outline">
<i ng-class="value.icon" class="icon-out" aria-hidden="true"></i>
{{redirectUrl.originalUrl}}
</a>

View File

@@ -15,9 +15,10 @@
<localize key="content_noMediaLink"></localize>
</umb-empty-state>
<ul ng-if="nodeUrl" class="nav nav-stacked" style="margin-bottom: 0;">
<ul ng-if="nodeUrl" class="nav nav-stacked mb0">
<li>
<a ng-attr-href="{{node.extension !== 'svg' ? nodeUrl : undefined}}" ng-click="node.extension === 'svg' && openSVG()" target="_blank" class="umb-outline">
<a href="" ng-attr-href="{{node.extension !== 'svg' ? nodeUrl : undefined}}" ng-click="node.extension === 'svg' && openSVG()" target="_blank" rel="noopener" class="umb-outline">
<i class="icon icon-out" aria-hidden="true"></i>
<span>{{nodeFileName}}</span>
</a>
</li>

View File

@@ -18,7 +18,7 @@
<div class="gravity-container">
<div class="viewport">
<img ng-if="file.isClientSide" ng-src="{{file.fileSrc}}" style="max-width: 100%; max-height: 100%" alt="{{file.fileName}}" />
<a ng-if="!file.isClientSide" href="#" ng-href="{{file.fileSrc}}" target="_blank">
<a ng-if="!file.isClientSide" href="#" ng-href="{{file.fileSrc}}" target="_blank" rel="noopener">
<img ng-src="{{file.fileSrc}}" style="max-width: 100%; max-height: 100%" alt="{{file.fileName}}" />
</a>
</div>
@@ -26,7 +26,7 @@
</div>
<div ng-if="!file.isImage && file.extension !== 'svg'">
<a class="span6 thumbnail tc" ng-show="!file.isClientSide" href="#" ng-href="{{file.fileName}}" target="_blank">
<a class="span6 thumbnail tc" ng-show="!file.isClientSide" href="#" ng-href="{{file.fileName}}" target="_blank" rel="noopener">
<umb-file-icon
extension="{{file.extension}}"
size="m">

View File

@@ -68,7 +68,7 @@
{{redirect.culture ||'*'}}
</div>
<div class="umb-table-cell flx-s1 flx-g1 flx-b4">
<a class="umb-table-body__link" href="{{redirect.originalUrl}}" target="_blank" title="{{redirect.originalUrl}}">{{redirect.originalUrl}}</a>
<a class="umb-table-body__link" href="{{redirect.originalUrl}}" target="_blank" rel="noopener" title="{{redirect.originalUrl}}">{{redirect.originalUrl}}</a>
</div>
<div class="umb-table-cell flx-s0 flx-g0" style="flex-basis: 20px;">
@@ -77,7 +77,7 @@
<div class="umb-table-cell flx-s1 flx-g1 flx-b5 items-center">
<div class="flx-s1 flx-g1 flx-b0" style="margin-right: 20px;">
<a class="umb-table-body__link" href="{{redirect.destinationUrl}}" target="_blank" title="{{redirect.destinationUrl}}">{{redirect.destinationUrl}}</a>
<a class="umb-table-body__link" href="{{redirect.destinationUrl}}" target="_blank" rel="noopener" title="{{redirect.destinationUrl}}">{{redirect.destinationUrl}}</a>
</div>
<umb-button
type="button"

View File

@@ -1,5 +1,5 @@
<h3>Hours of Umbraco training videos are only a click away</h3>
<p>Want to master Umbraco? Spend a couple of minutes learning some best practices by watching one of these videos about using Umbraco. And visit <a href="https://umbraco.tv" target="_blank">umbraco.tv</a> for even more Umbraco videos</p>
<p>Want to master Umbraco? Spend a couple of minutes learning some best practices by watching one of these videos about using Umbraco. And visit <a href="https://umbraco.tv" target="_blank" rel="noopener">umbraco.tv</a> for even more Umbraco videos</p>
<h4>To get you started:</h4>
<div class="row-fluid"
@@ -9,7 +9,7 @@
<ul class="thumbnails">
<li class="span2" ng-repeat="video in videos">
<div class="thumbnail" style="margin-right: 20px">
<a target="_blank" href="{{video.link}}" title="{{video.title}}">
<a target="_blank" rel="noopener" href="{{video.link}}" title="{{video.title}}">
<img ng-src="{{video.thumbnail}}" alt="{{video.title}}">
</a>
</div>

View File

@@ -10,7 +10,7 @@
<ul class="thumbnails" >
<li class="span2" ng-repeat="video in videos">
<div class="thumbnail" style="margin-right: 20px">
<a target="_blank" href="{{video.link}}" title="{{video.title}}">
<a target="_blank" rel="noopener" href="{{video.link}}" title="{{video.title}}">
<img ng-src="{{video.thumbnail}}" alt="{{video.title}}">
</a>
</div>

View File

@@ -6,21 +6,21 @@
<umb-box-content>
<h3 class="bold"><localize key="settingsDashboardVideos_trainingHeadline">Hours of Umbraco training videos are only a click away</localize></h3>
<localize key="settingsDashboardVideos_trainingDescription">
<p>Want to master Umbraco? Spend a couple of minutes learning some best practices by watching one of these videos about using Umbraco. And visit <a href="http://umbraco.tv" target="_blank">umbraco.tv</a> for even more Umbraco videos</p>
<p>Want to master Umbraco? Spend a couple of minutes learning some best practices by watching one of these videos about using Umbraco. And visit <a href="http://umbraco.tv" target="_blank" rel="noopener">umbraco.tv</a> for even more Umbraco videos</p>
</localize>
</umb-box-content>
</umb-box>
<div ng-show="videos.length">
<h4><localize key="settingsDashboardVideos_getStarted">To get you started</localize>:</h4>
<ul class="thumbnails" >
<li class="span2" ng-repeat="video in videos">
<div class="thumbnail" style="margin-right: 20px">
<a target="_blank" href="{{video.link}}" title="{{video.title}}">
<img ng-src="{{video.thumbnail}}" alt="{{video.title}}">
</a>
</div>
</li>
</ul>
<h4><localize key="settingsDashboardVideos_getStarted">To get you started</localize>:</h4>
<ul class="thumbnails" >
<li class="span2" ng-repeat="video in videos">
<div class="thumbnail" style="margin-right: 20px">
<a target="_blank" rel="noopener" href="{{video.link}}" title="{{video.title}}">
<img ng-src="{{video.thumbnail}}" alt="{{video.title}}">
</a>
</div>
</li>
</ul>
</div>
</div>

View File

@@ -7,7 +7,7 @@
<div class="umb-healthcheck-help-text">
<localize key="healthcheck_helpText">
<p>The health checker evaluates various areas of your site for best practice settings, configuration, potential problems, etc. You can easily fix problems by pressing a button.
You can add your own health checks, have a look at <a href="https://our.umbraco.com/documentation/Extending/Healthcheck/" target="_blank" class="btn-link -underline">the documentation for more information</a> about custom health checks.</p>
You can add your own health checks, have a look at <a href="https://our.umbraco.com/documentation/Extending/Healthcheck/" target="_blank" rel="noopener" class="btn-link -underline">the documentation for more information</a> about custom health checks.</p>
</localize>
</div>
<div class="umb-panel-group__details-status-actions">

View File

@@ -11,19 +11,19 @@
</h5>
<ul>
<li>
<localize key="settingsDashboard_bulletPointOne">Read more about working with the items in Settings <a class="btn-link -underline" href="https://our.umbraco.com/documentation/Getting-Started/Backoffice/Sections/" target="_blank">in the Documentation section</a> of Our Umbraco</localize>
<localize key="settingsDashboard_bulletPointOne">Read more about working with the items in Settings <a class="btn-link -underline" href="https://our.umbraco.com/documentation/Getting-Started/Backoffice/Sections/" target="_blank" rel="noopener">in the Documentation section</a> of Our Umbraco</localize>
</li>
<li>
<localize key="settingsDashboard_bulletPointTwo">Ask a question in the <a class="btn-link -underline" href="https://our.umbraco.com/forum" target="_blank">Community Forum</a></localize>
<localize key="settingsDashboard_bulletPointTwo">Ask a question in the <a class="btn-link -underline" href="https://our.umbraco.com/forum" target="_blank" rel="noopener">Community Forum</a></localize>
</li>
<li>
<localize key="settingsDashboard_bulletPointThree">Watch our <a class="btn-link -underline" href="https://umbraco.tv" target="_blank">tutorial videos</a> (some are free, some require a subscription)</localize>
<localize key="settingsDashboard_bulletPointThree">Watch our <a class="btn-link -underline" href="https://umbraco.tv" target="_blank" rel="noopener">tutorial videos</a> (some are free, some require a subscription)</localize>
</li>
<li>
<localize key="settingsDashboard_bulletPointFour">Find out about our <a class="btn-link -underline" href="https://umbraco.com/products/" target="_blank">productivity boosting tools and commercial support</a></localize>
<localize key="settingsDashboard_bulletPointFour">Find out about our <a class="btn-link -underline" href="https://umbraco.com/products/" target="_blank" rel="noopener">productivity boosting tools and commercial support</a></localize>
</li>
<li>
<localize key="settingsDashboard_bulletPointFive">Find out about real-life <a class="btn-link -underline" href="https://umbraco.com/training/" target="_blank">training and certification</a> opportunities</localize>
<localize key="settingsDashboard_bulletPointFive">Find out about real-life <a class="btn-link -underline" href="https://umbraco.com/training/" target="_blank" rel="noopener">training and certification</a> opportunities</localize>
</li>
</ul>
</umb-box-content>

View File

@@ -2,7 +2,7 @@
<localize key="settingsDashboardVideos_trainingHeadline">Hours of Umbraco training videos are only a click away</localize>
</h3>
<localize key="settingsDashboardVideos_trainingDescription">
<p>Want to master Umbraco? Spend a couple of minutes learning some best practices by watching one of these videos about using Umbraco. And visit <a href="http://umbraco.tv" target="_blank">umbraco.tv</a> for even more Umbraco videos</p>
<p>Want to master Umbraco? Spend a couple of minutes learning some best practices by watching one of these videos about using Umbraco. And visit <a href="http://umbraco.tv" target="_blank" rel="noopener">umbraco.tv</a> for even more Umbraco videos</p>
</localize>
<div class="row-fluid"
@@ -16,7 +16,7 @@
<ul class="thumbnails" >
<li class="span2" ng-repeat="video in videos">
<div class="thumbnail" style="margin-right: 20px">
<a target="_blank" href="{{video.link}}" title="{{video.title}}">
<a target="_blank" rel="noopener" href="{{video.link}}" title="{{video.title}}">
<img ng-src="{{video.thumbnail}}" alt="{{video.title}}">
</a>
</div>

View File

@@ -271,7 +271,7 @@
description="Here you can add custom installer / uninstaller events to perform certain tasks during installation and uninstallation.
All actions are formed as a xml node, containing data for the action to be performed.">
<div>
<a href="" ng-href="https://our.umbraco.com/documentation/Reference/Packaging/" target="_blank" rel="noopener">Documentation</a>
<a href="https://our.umbraco.com/documentation/Reference/Packaging/" target="_blank" rel="noopener">Documentation</a>
<div>
<textarea class="umb-property-editor" rows="10" ng-model="vm.package.actions"></textarea>
</div>

View File

@@ -294,7 +294,7 @@
<div class="umb-package-details__section-title"><localize key="packager_packageExternalSources">External sources</localize></div>
<div>
<div class="umb-package-details__information-item" ng-repeat="externalSource in vm.package.externalSources">
<a class="umb-package-details__link" target="_blank" href="{{ externalSource.url }}">
<a class="umb-package-details__link" href="{{ externalSource.url }}" target="_blank" rel="noopener noreferrer">
<i class="icon-out" aria-hidden="true"></i>
{{ externalSource.name }}
</a>
@@ -335,7 +335,7 @@
<div class="umb-info-local-item">
<strong>Author</strong>
<a href="{{ vm.localPackage.authorLink }}" target="_blank">{{ vm.localPackage.author }}</a>
<a href="{{ vm.localPackage.authorLink }}" target="_blank" rel="noopener noreferrer">{{ vm.localPackage.author }}</a>
</div>
<div class="umb-info-local-item">
@@ -345,7 +345,7 @@
<div class="umb-info-local-item">
<strong><localize key="packager_packageLicense">License</localize></strong>
<a href="{{ vm.localPackage.licenseUrl }}" target="_blank">{{ vm.localPackage.license }}</a>
<a href="{{ vm.localPackage.licenseUrl }}" target="_blank" rel="noopener noreferrer">{{ vm.localPackage.license }}</a>
</div>
<div class="umb-info-local-item">
@@ -357,7 +357,7 @@
<div class="umb-info-local-item mt4 flex items-center flex-column" ng-if="vm.installState.status == '' && vm.localPackage.isCompatible">
<umb-checkbox model="vm.localPackage.packageLicenseAccept" required="true">
<strong class="label-text"><localize key="packager_accept">I accept</localize> <a href="#" ng-href="{{vm.localPackage.licenseUrl}}" target="_blank" rel="noopener"><localize key="packager_termsOfUse">terms of use</localize></a></strong>
<strong class="label-text"><localize key="packager_accept">I accept</localize> <a href="#" ng-href="{{vm.localPackage.licenseUrl}}" target="_blank" rel="noopener noreferrer"><localize key="packager_termsOfUse">terms of use</localize></a></strong>
</umb-checkbox>
<umb-button ng-if="vm.installState.type !== 'error'"

View File

@@ -22,16 +22,16 @@
<td class="col-link">
<div ng-show="!link.edit">
<i class="icon {{link.internalIcon}}" ng-show="link.internalIcon"></i>
<a href="{{link.link}}" target="_blank" ng-show="!link.isInternal">{{link.link}}</a>
<a href="#/content/content/edit/{{link.internal}}" target="_blank" ng-show="link.isInternal" ng-bind="link.internalName"></a>
<a href="{{link.link}}" target="_blank" rel="noopener" ng-show="!link.isInternal">{{link.link}}</a>
<a href="#/content/content/edit/{{link.internal}}" target="_blank" rel="noopener" ng-show="link.isInternal" ng-bind="link.internalName"></a>
</div>
<div ng-show="link.edit">
<div ng-show="!link.isInternal">
<div class="control-wrapper">
<input type="text" ng-model="link.link" />
</div>
<localize key="or">or</localize> <a href="#" ng-click="switchLinkType($event,link)"><localize key="relatedlinks_chooseInternal">choose internal page</localize></a>
<div class="control-wrapper">
<input type="text" ng-model="link.link" />
</div>
<localize key="or">or</localize> <a href="#" ng-click="switchLinkType($event,link)"><localize key="relatedlinks_chooseInternal">choose internal page</localize></a>
</div>
<div ng-show="link.isInternal">
<i class="icon {{link.internalIcon}}" ng-show="link.internalIcon"></i>
@@ -88,4 +88,4 @@
</tfoot>
</table>
</div>
</div>