Implements operation that pulls out @imports from CSS and turns them into external references in the proper order. Logic separated from HTMLContentRewriter.
http://codereview.appspot.com/223098/diff/2001/2003 File java/gadgets/src/main/java/org/apache/shindig/gadgets/rewrite/StyleTagContentRewriter.java (right): http://codereview.appspot.com/223098/diff/2001/2003#newcode33 java/gadgets/src/main/java/org/apache/shindig/gadgets/rewrite/StyleTagContentRewriter.java:33: public class StyleTagContentRewriter extends DomWalker.Rewriter { create tests http://codereview.appspot.com/223098/diff/2001/2003#newcode55 ...
15 years, 10 months ago
(2010-03-07 19:17:37 UTC)
#4
http://codereview.appspot.com/223098/diff/2001/2003
File
java/gadgets/src/main/java/org/apache/shindig/gadgets/rewrite/StyleTagContentRewriter.java
(right):
http://codereview.appspot.com/223098/diff/2001/2003#newcode33
java/gadgets/src/main/java/org/apache/shindig/gadgets/rewrite/StyleTagContentRewriter.java:33:
public class StyleTagContentRewriter extends DomWalker.Rewriter {
create tests
http://codereview.appspot.com/223098/diff/2001/2003#newcode55
java/gadgets/src/main/java/org/apache/shindig/gadgets/rewrite/StyleTagContentRewriter.java:55:
new ConcatLinkRewriter.Css(config, concatUriManager));
Two comments:
- Class name consistency, one Visitor and one Rewriter.Css but both are same
interface
- New link tags that created by StyleTagExtractor are not being concatenate.
Consider using separate Dom Walkers (concat activated after tag extractor)
On Sun, Mar 7, 2010 at 11:17 AM, <zhoresh@gmail.com> wrote: > > http://codereview.appspot.com/223098/diff/2001/2003 > File ...
15 years, 10 months ago
(2010-03-09 01:19:32 UTC)
#5
On Sun, Mar 7, 2010 at 11:17 AM, <zhoresh@gmail.com> wrote:
>
> http://codereview.appspot.com/223098/diff/2001/2003
> File
>
>
>
java/gadgets/src/main/java/org/apache/shindig/gadgets/rewrite/StyleTagContentRewriter.java
> (right):
>
> http://codereview.appspot.com/223098/diff/2001/2003#newcode33
>
>
java/gadgets/src/main/java/org/apache/shindig/gadgets/rewrite/StyleTagContentRewriter.java:33:
> public class StyleTagContentRewriter extends DomWalker.Rewriter {
> create tests
>
IMO the [Gadget|Request|Content]Rewriter classes are a good place to put
integration tests, while VisitorTests will serve as unit testing. Thoughts?
Stub put in for the moment; new patch in a moment. I'll migrate the old
HTMLContentRewriter test (pieces) over in a separate CL.
>
> http://codereview.appspot.com/223098/diff/2001/2003#newcode55
>
>
java/gadgets/src/main/java/org/apache/shindig/gadgets/rewrite/StyleTagContentRewriter.java:55:
> new ConcatLinkRewriter.Css(config, concatUriManager));
> Two comments:
> - Class name consistency, one Visitor and one Rewriter.Css but both are
> same interface
> - New link tags that created by StyleTagExtractor are not being
> concatenate. Consider using separate Dom Walkers (concat activated after
> tag extractor)
Renamed in previous CL -- will attach patch reflecting this shortly.
>
>
> http://codereview.appspot.com/223098/show
>
Issue 223098: StyleTagExtractorVisitor implementation
(Closed)
Created 15 years, 10 months ago by johnfargo
Modified 15 years, 10 months ago
Reviewers: shindig.remailer_gmail.com, zhoresh
Base URL: http://svn.apache.org/repos/asf/shindig/trunk/
Comments: 2