aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/ComponentUI/Controller/Root.pm2
-rw-r--r--lib/Reaction/UI/LayoutSet.pm11
-rw-r--r--share/skin/componentui/layout/site_layout.tt19
3 files changed, 16 insertions, 16 deletions
diff --git a/lib/ComponentUI/Controller/Root.pm b/lib/ComponentUI/Controller/Root.pm
index 2e2a181..4113a73 100644
--- a/lib/ComponentUI/Controller/Root.pm
+++ b/lib/ComponentUI/Controller/Root.pm
@@ -22,7 +22,7 @@ sub base :Chained('/') :PathPart('') :CaptureArgs(0) {
my ($self, $c) = @_;
$self->push_viewport(SiteLayout,
title => 'ComponentUI test title',
- static_base_uri => "${\$c->uri_for('static')}",
+ static_base_uri => "${\$c->uri_for('/static')}",
);
}
diff --git a/lib/Reaction/UI/LayoutSet.pm b/lib/Reaction/UI/LayoutSet.pm
index 44a137c..4185033 100644
--- a/lib/Reaction/UI/LayoutSet.pm
+++ b/lib/Reaction/UI/LayoutSet.pm
@@ -73,7 +73,16 @@ class LayoutSet which {
$layouts->{$fname} = $text;
} elsif ($data =~ /^extends (\S+)/) {
my $super_name = $1;
- $self->super($build_args->{skin}->create_layout_set($super_name))
+ my $skin;
+ if ($super_name eq 'NEXT') {
+ confess "No next skin and layout extends NEXT"
+ unless $build_args->{next_skin};
+ $skin = $build_args->{next_skin};
+ $super_name = $self->name;
+ } else {
+ $skin = $build_args->{skin};
+ }
+ $self->super($skin->create_layout_set($super_name));
} elsif ($data =~ /^widget (\S+)/) {
my $widget_type = $1;
$self->widget_type($1);
diff --git a/share/skin/componentui/layout/site_layout.tt b/share/skin/componentui/layout/site_layout.tt
index 0a1448a..8c6b7c2 100644
--- a/share/skin/componentui/layout/site_layout.tt
+++ b/share/skin/componentui/layout/site_layout.tt
@@ -1,18 +1,12 @@
-=for layout widget
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+=extends NEXT
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
+=for layout head_style
-<head>
- <title>Component UI Test Title</title>
-
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
- <link rel="stylesheet" type="text/css" href="/static/componentui-basic.css" />
+ <link rel="stylesheet" type="text/css"
+ href="[% static_base %]/componentui-basic.css" />
-</head>
+=for layout body
-<body>
<div id="container">
<div id="header">
[% header %]
@@ -30,9 +24,6 @@
<div class="spacer"></div>
</div>
</div>
-</body>
-
-</html>
=for layout inner
<!-- main content start -->