In jQuery 3 "#" is disallowed as a selector

here is a somewhat hacky way to force use an empty selector where "#"
was used as a selector before

closes #7372
This commit is contained in:
cmrd Senya 2017-01-30 02:47:53 +02:00 committed by Steffen van Bergerem
parent 3a6e5d5446
commit 526ebcfa13
No known key found for this signature in database
GPG key ID: 315C9787D548DC6B
4 changed files with 5 additions and 4 deletions

View file

@ -3,6 +3,7 @@
## Refactor
* Remove unused setPreload function [#7354](https://github.com/diaspora/diaspora/pull/7354)
* Remove jQuery deprecations [#7356](https://github.com/diaspora/diaspora/pull/7356)
* Use empty selector where "#" was used as a selector before (prepare jQuery 3 upgrade) [#7372](https://github.com/diaspora/diaspora/pull/7372)
## Bug fixes

View file

@ -65,7 +65,7 @@ Diaspora.MarkdownEditor.prototype = {
var tabElement = $("<ul class='nav nav-tabs btn-group write-preview-tabs'></ul>");
var writeTab = $("<li class='active full-height' role='presentation'></li>");
this.writeLink = $("<a class='full-height md-write-tab' href='#'></a>")
this.writeLink = $("<a class='full-height md-write-tab' href='#' data-target=' '></a>")
.attr("title", Diaspora.I18n.t("publisher.markdown_editor.tooltips.write"));
this.writeLink.append($("<i class='visible-sm visible-xs visible-md diaspora-custom-compose'></i>"));
@ -80,7 +80,7 @@ Diaspora.MarkdownEditor.prototype = {
writeTab.append(this.writeLink);
var previewTab = $("<li class='full-height' role='presentation'></li>");
this.previewLink = $("<a class='full-height md-preview-tab' href='#'></a>")
this.previewLink = $("<a class='full-height md-preview-tab' href='#' data-target=' '></a>")
.attr("title", Diaspora.I18n.t("publisher.markdown_editor.tooltips.preview"));
this.previewLink.append($("<i class='visible-sm visible-xs visible-md entypo-search'>"));

View file

@ -43,7 +43,7 @@
<ul class="nav navbar-nav navbar-left nav-badges hidden-sm hidden-xs">
<li class="dropdown" id="notification-dropdown">
<a id="notifications-link" href="/notifications" title="{{t "header.notifications"}}" class="notifications-link nav-badge hidden-sm hidden-xs" role="button" data-toggle="dropdown" aria-expanded="false" data-target="#">
<a id="notifications-link" href="/notifications" title="{{t "header.notifications"}}" class="notifications-link nav-badge hidden-sm hidden-xs" role="button" data-toggle="dropdown" aria-expanded="false" data-target=" ">
<i class="entypo-bell"></i>
<span class="badge badge-important {{#unless current_user.notifications_count}} hidden {{/unless}}">
{{current_user.notifications_count}}

View file

@ -9,7 +9,7 @@
%p
!= t(".try_adding_some_more_contacts",
invite_link: link_to(t(".invite_link_text"),
"#",
" ",
class: "invitations-link",
data: {toggle: "modal"}))