Bug Tracker

Modify

Ticket #10667 (closed bug: fixed)

Opened 2 years ago

Last modified 2 years ago

HTML5 Support in .wrapAll() does add a ":" to element

Reported by: t.fellinger@… Owned by: t.fellinger@…
Priority: blocker Milestone: 1.7.1
Component: manipulation Version: 1.7
Keywords: Cc:
Blocking: Blocked by:

Description

Hi there - im testing the HTML5 support for adding some content in IE 8

$('#content section.content').clone()

.find('h2') .prependTo('#content section.content') .wrapAll('<aside class="sidebar"></aside>');

leads to <:aside class="sidebar"><h2>...</h2>

jsFiddle: take a look at it on IE 8

Change History

comment:1 Changed 2 years ago by rwaldron

  • Owner set to rwaldron
  • Priority changed from undecided to blocker
  • Status changed from new to assigned
  • Component changed from unfiled to manipulation
  • Milestone changed from None to 1.7.1

comment:2 Changed 2 years ago by rwaldron

  • Owner changed from rwaldron to t.fellinger@…
  • Status changed from assigned to pending

I'm not able to reproduce this - how are you testing and/or observing this issue?

comment:3 Changed 2 years ago by dmethvin

  • Status changed from pending to open

I can see it in the html view from F12 Developer Tools.

 http://gyazo.com/776ee2f77dccdec42ff077a20c6c4772

comment:4 Changed 2 years ago by dmethvin

Ah! See #10670 I think that explains it.

comment:5 Changed 2 years ago by dmethvin

#10670 is a duplicate of this ticket.

comment:6 Changed 2 years ago by timmywil

comment:7 Changed 2 years ago by timmywil

comment:8 Changed 2 years ago by timmywil

So, I propose we do something similar to the newCloneNode function in  http://www.iecss.com/shimprove/javascript/shimprove.1-0-1.js, but with the html5-safe fragment that we have and only for html5 elements. elem.cloneNode( true ) is not sufficient for initial creation.

There are a couple different codepaths I'm envisioning. We should keep in mind that using cloneNode and then attaching it to the safeFragment also fixes it.

 http://jsfiddle.net/timmywil/hkRaK/11/

comment:9 Changed 2 years ago by Rick Waldron

  • Status changed from open to closed
  • Resolution set to fixed

Fix busted rnoshimcache. Correctly clone detached unknown elems. Fixes #10667, #10670.

  • \s => |, Removes 4 bytes from gzipped build

comment:10 Changed 2 years ago by t.fellinger@…

Thanks for that, how can i test it?

greets

tom

comment:11 Changed 2 years ago by rwaldron

@tom - the patch has landed and will be included in the 1.7.1 bug-fix release

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.