Skip to content

Modern, high-performance Blazor components and utilities designed to enhance web development productivity. Features include enhanced navigation, state management, and reusable UI components for building robust Blazor applications.

License

Notifications You must be signed in to change notification settings

crazyants/Osirion.Blazor

Β 
Β 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Osirion.Blazor

NuGet License Security Rating codecov

A modular, high-performance component library for Blazor applications with SSR compatibility and zero-JS dependencies (when possible).

✨ Features

Osirion.Blazor is composed of specialized modules that can be used independently or together:

🎯 Core Components

Docs

  • Layout Components: HeroSection, PageLayout, Footer, Sticky Sidebar
  • Navigation Components: Breadcrumbs, Article Metadata
  • Content Components: HTML Renderer, Background Patterns
  • State Components: Loading indicators, 404 pages
  • Interactive Components: Cookie Consent, Logo Carousel
  • SSR Compatible: All components work without JavaScript
  • Framework Integration: Bootstrap, FluentUI, MudBlazor, Radzen support

πŸ“Š Analytics

Docs

  • Multiple provider support (Microsoft Clarity, Matomo, GA4, Yandex Metrica)
  • SSR compatibility with progressive enhancement
  • Privacy-focused with consent management
  • Easily extendable with your own providers

🧭 Navigation

Docs

  • Enhanced navigation with scroll restoration
  • Smooth scrolling and "back to top" functionality
  • Menu components with hierarchical support
  • Works without JavaScript through progressive enhancement
  • Fully customizable appearance

πŸ“ Content Management

Docs

  • GitHub and file system content providers
  • Markdown rendering with frontmatter support
  • Content organization with categories and tags
  • Directory-based navigation and search
  • SEO optimization out of the box
  • Localization support with multi-language content
  • Admin interface for content editing

🎨 Theming

Docs

  • Integration with popular CSS frameworks (Bootstrap, FluentUI, MudBlazor, Radzen)
  • Dark mode support with system preference detection
  • CSS variable-based styling system
  • Minimal JavaScript with progressive enhancement

πŸ“¦ Installation

Install the complete package:

dotnet add package Osirion.Blazor

Or just the modules you need:

dotnet add package Osirion.Blazor.Core
dotnet add package Osirion.Blazor.Analytics
dotnet add package Osirion.Blazor.Navigation
dotnet add package Osirion.Blazor.Cms
dotnet add package Osirion.Blazor.Theming

πŸš€ Quick Start

Service Registration

// In Program.cs
using Osirion.Blazor.Extensions;

// Register all services at once with fluent API
builder.Services.AddOsirionBlazor(osirion => {
    osirion
        .AddGitHubCms(options => {
            options.Owner = "username";
            options.Repository = "content-repo";
        })
        .AddScrollToTop()
        .AddClarityTracker(options => {
            options.SiteId = "clarity-id";
        })
        .AddOsirionStyle(CssFramework.Bootstrap);
});

// Or from configuration
builder.Services.AddOsirionBlazor(builder.Configuration);

Component Usage

@using Osirion.Blazor.Components

<!-- In your layout -->
<OsirionStyles FrameworkIntegration="CssFramework.Bootstrap" />
<EnhancedNavigation Behavior="ScrollBehavior.Smooth" />
<ScrollToTop Position="Position.BottomRight" />
<ClarityTracker />

<!-- Hero section for landing pages -->
<HeroSection 
    Title="Welcome to Our Platform"
    Subtitle="Build amazing applications with ease"
    Summary="Experience the power of modern web development."
    PrimaryButtonText="Get Started"
    PrimaryButtonUrl="/getting-started"
    ImageUrl="/images/hero.jpg"
    UseBackgroundImage="true" />

<!-- Breadcrumb navigation -->
<OsirionBreadcrumbs Path="@Navigation.Uri" />

<!-- Content management -->
<ContentList Directory="blog" />
<ContentView Path="blog/my-post.md" />
<SearchBox />
<TagCloud />

<!-- Cookie consent (GDPR compliant) -->
<OsirionCookieConsent 
    PolicyLink="/privacy-policy"
    ShowCustomizeButton="true" />

<!-- Logo carousel -->
<InfiniteLogoCarousel 
    Title="Our Partners"
    CustomLogos="@partnerLogos" />

πŸ“š Documentation

Component-Specific Documentation

🌟 Key Principles

  • SSR First: All components designed for Server-Side Rendering compatibility
  • Zero-JS Dependencies: No JavaScript dependencies where possible
  • Progressive Enhancement: Core functionality works without JavaScript, enhanced with JS when available
  • Framework Integration: Seamless integration with popular CSS frameworks
  • Multi-Platform: Supports .NET 8 and .NET 9 (and future versions)
  • Provider Pattern: Easily extend with your own providers for analytics, content, etc.
  • Accessibility: WCAG 2.1 compliant components with full keyboard and screen reader support
  • GDPR Compliance: Built-in privacy and consent management features

πŸ“‹ Requirements

  • .NET 8.0 or higher
  • Blazor (Server, WebAssembly, or Auto)

πŸ†• What's New in v1.5.0

Major Features

  • Fluent API: New AddOsirionBlazor() method for streamlined service registration
  • CSS Framework Integration: Automatic integration with Bootstrap, FluentUI, MudBlazor, and Radzen
  • Comprehensive Core Components: HeroSection, Breadcrumbs, Cookie Consent, and more
  • Enhanced Documentation: Component-specific documentation with examples
  • Improved Styling: Renamed osirion-cms.css to osirion.css for broader scope

Breaking Changes

  • osirion-cms.css renamed to osirion.css
  • Styling options moved from GitHubCmsOptions to dedicated OsirionStyleOptions
  • Service registration methods updated (legacy methods still supported)

See Migration Guide for upgrade instructions.

πŸ§ͺ Features Coming Soon

  • Headless CMS support with Contentful, Sanity, and Strapi providers
  • Form validation and submission components
  • Authentication integration
  • Enhanced SEO components with structured data
  • Performance optimizations for large content repositories
  • Visual component editor for admin interface
  • Multi-tenant content management

🀝 Contributing

Contributions are welcome! Please see our Contributing Guidelines for details.

Current Focus Areas

  • Additional CSS framework integrations
  • Performance optimizations
  • Accessibility improvements
  • Documentation enhancements
  • Test coverage expansion

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ™ Acknowledgments

πŸ“Š Project Stats

  • Components: 15+ production-ready components
  • Packages: 10+ NuGet packages
  • Frameworks: .NET 8 & .NET 9 support
  • CSS Frameworks: 4 major frameworks supported
  • Test Coverage: 85%+ code coverage
  • Documentation: Comprehensive guides and examples

About

Modern, high-performance Blazor components and utilities designed to enhance web development productivity. Features include enhanced navigation, state management, and reusable UI components for building robust Blazor applications.

Resources

License

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 64.0%
  • CSS 19.3%
  • HTML 8.9%
  • SCSS 5.8%
  • JavaScript 1.8%
  • PowerShell 0.2%