Chandra

 view release on metacpan or  search on metacpan

lib/Chandra/Theme.pm  view on Meta::CPAN

    min-width: 180px;
}
.chandra-context-menu-item {
    padding: 6px 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}
.chandra-context-menu-item:hover { background: var(--chandra-hover); }

/* ── Scrollbar (webkit) ───────────────────────────────── */

::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
    background: var(--chandra-border);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover { background: var(--chandra-text-muted); }

CSS
}

1;

__END__

=head1 NAME

Chandra::Theme - CSS theme system for Chandra apps

=head1 SYNOPSIS

    use Chandra::App;
    use Chandra::Theme;

    my $app = Chandra::App->new(title => 'My App');

    # Built-in themes
    Chandra::Theme->apply($app, 'dark');
    Chandra::Theme->apply($app, 'light');

    # Auto-detect OS preference
    Chandra::Theme->apply($app, 'auto');

    # Custom theme (merged with light as base)
    Chandra::Theme->apply($app, {
        primary => '#6200ea',
        bg      => '#fafafa',
        surface => '#ffffff',
        radius  => '12px',
    });

    $app->run;

=head1 DESCRIPTION

C<Chandra::Theme> provides a CSS theme system using CSS custom properties.
It includes built-in light and dark themes, styles for all Chandra
components (Form, Table, ContextMenu), and base typography/reset styles.

=head1 CSS CUSTOM PROPERTIES

All tokens are available as C<--chandra-*> CSS variables:

    --chandra-primary, --chandra-secondary, --chandra-danger,
    --chandra-warning, --chandra-info, --chandra-success,
    --chandra-bg, --chandra-surface, --chandra-text,
    --chandra-text-muted, --chandra-border,
    --chandra-input-bg, --chandra-input-border,
    --chandra-hover, --chandra-selected, --chandra-shadow,
    --chandra-font, --chandra-font-mono,
    --chandra-radius, --chandra-font-size, --chandra-line-height

=head1 SEE ALSO

L<Chandra::App>, L<Chandra::Table>, L<Chandra::Form>

=cut



( run in 1.117 second using v1.01-cache-2.11-cpan-6aa56a78535 )