Ticket #2657 (closed defect: wontfix)
'intern-strings' does not correctly expand URLs inside of CSS
| Reported by: | bradneuberg | Owned by: | jburke |
|---|---|---|---|
| Priority: | normal | Milestone: | 1.0 |
| Component: | BuildSystem | Version: | 0.4.2 |
| Severity: | major | Keywords: | |
| Cc: |
Description
The Dojo build system's 'intern-strings' directive is meant to inline widget HTML and CSS resources directly into the generated dojo.js file. If that CSS file contains a URL directive, such as the following from EditorToolbar?.css:
.dojoE2TBIcon {
background-image: url(buttons/aggregate.gif);
}
the 'intern-strings' widget doesn't correctly expand this into a relative address that is now relative to dojo.js, rather than the src/widgets/templates/ directory. This causes it to break and not display our images.
This impacts the Editor2 widget, which has a system to bundle up all the toolbar images into a single GIF file, which it then references using a CSS url() directive and CSS clipping directives to get each icon seperately. This can speed up page load time since all the GIF resources are essentially in one file. Without fixing this 'intern-strings' bug though, this doesn't work, which affects me with Moxie and Dojo Offline, contributing to slow page load.
I have attached a patch to fix this issue, applied to the file buildUtil.py.