use Time::Local qw(timelocal);
use Moo;
+with 'SCSite::PageChildren';
+
has $_ => (is => 'ro') for qw(
title subtitle description keywords body created path
);
has "_$_" => (is => 'ro', init_arg => $_) for qw(page_set);
-sub children {
- my ($self, %args) = @_;
- if (my $at = delete $args{at_depth}) {
- @args{qw(min_depth max_depth)} = ($at, $at);
- }
- my $ps = $self->_page_set;
- (ref $ps)->new(
- top_dir => $ps->base_dir,
- base_dir => io->dir($ps->base_dir)->catdir($self->path),
- max_depth => 1,
- %args,
- );
-}
+sub _page_set_class { ref($_[0]->_page_set) }
+sub _top_dir { $_[0]->_page_set->top_dir }
+sub _my_path { io->dir($_[0]->_top_dir)->catdir($_[0]->path) }
1;