Bug 141068

Summary: SVG "clip-path" property chooses the wrong element, when multiple elements have a matching ID
Product: WebKit Reporter: Daniel Holbert <dholbert>
Component: SVGAssignee: Nobody <webkit-unassigned>
Status: NEW ---    
Severity: Normal CC: ahmad.saleem792, gsnedders, webkit-bug-importer, zimmermann
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
See Also: http://code.google.com/p/chromium/issues/detail?id=453722
Bug Depends on:    
Bug Blocks: 126207    
Attachments:
Description Flags
testcase 1 none

Description Daniel Holbert 2015-01-29 22:17:43 PST
Created attachment 245695 [details]
testcase 1

STR:
 1. Load attached testcase

Expected output:
  Yellow rect inside of a blue rect.

Actual output:
  Red shows up between the yellow and the blue.
  In particular: the yellow rect is clipped to be too small (because there are two clipRect elements with an ID that matches its "clip-path" attribute, and it's choosing the wrong one)

IE 11 and Firefox/Gecko both give me the expected output. Blink & WebKit give me the incorrect output (with red & the wrong clipRect chosen.)


VERSION INFO: I've tested Safari 8 on Mac OS X Yosemite, and midori on Ubuntu 14.10. (both webkit-based). Both show the bug.
Comment 1 Daniel Holbert 2015-01-29 22:18:09 PST
I also filed a Chrome/Blink bug: https://code.google.com/p/chromium/issues/detail?id=453722
Comment 2 Radar WebKit Bug Importer 2022-04-13 17:30:02 PDT
<rdar://problem/91725385>
Comment 3 Sam Sneddon [:gsnedders] 2022-04-14 07:47:12 PDT
There's seemingly also some dynamic bugginess here, c.f. https://twitter.com/sophiebits/status/1514404762422181889 about elements getting removed.
Comment 4 Ahmad Saleem 2023-06-12 07:07:15 PDT
Fixed by following commit in Blink - https://chromium.googlesource.com/chromium/src/+/533d683571c860e69bb3ecaf6214c5ceed25a808