Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Custom Theme not being applied on buttons and other UI components #5743

Open
MITIN33 opened this issue Sep 22, 2024 · 1 comment
Open
Assignees
Labels
Type: Bug 🐞 Something isn't working
Milestone

Comments

@MITIN33
Copy link

MITIN33 commented Sep 22, 2024

Blazorise Version

1.6.1

What Blazorise provider are you running on?

Tailwind

Link to minimal reproduction or a simple code snippet

NA

Steps to reproduce

App.razor

<head>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <base href="/" />
    <link rel="icon" type="image/png" href="favicon.png" />

    <link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&amp;display=swap" rel="stylesheet">
    <link rel="stylesheet" href="https://unpkg.com/[email protected]/dist/flowbite.min.css" />
    <link href="_content/Blazorise.Icons.FontAwesome/v6/css/all.min.css" rel="stylesheet">

    <script src="https://cdn.tailwindcss.com"></script>
    <script src="_content/Blazorise.Tailwind/blazorise.tailwind.config.js?v=1.6.1.0"></script>
    <link href="_content/Blazorise/blazorise.css" rel="stylesheet" />
    <link href="_content/Blazorise.Tailwind/blazorise.tailwind.css" rel="stylesheet" />

    <HeadOutlet />
</head>

<body>
    <Routes />
    <script src="https://unpkg.com/[email protected]/dist/flowbite.js"></script>
    <script src="_framework/blazor.web.js"></script>
</body>

</html>

Routes.razor

<Blazorise.ThemeProvider Theme="@theme">
    <Router AppAssembly="typeof(Program).Assembly">
        <Found Context="routeData">
            <RouteView RouteData="routeData" DefaultLayout="typeof(Layout.MainLayout)" />
            <FocusOnNavigate RouteData="routeData" Selector="h1" />
        </Found>
    </Router>
</Blazorise.ThemeProvider>

@code {
    private Theme theme = new Theme
        {
            ColorOptions = new ThemeColorOptions
            {
                Primary = "#9f5c14",
            },
            BackgroundOptions = new ThemeBackgroundOptions
            {
                Primary = "#9f5c14",
            },
            TextColorOptions = new ThemeTextColorOptions
            {
                Primary = "#9f5c14",
            }
        };
}

What is expected?

Color should change on hover as well

What is actually happening?

Only Button color is changing

What browsers do you see the problem on?

Chrome, Microsoft Edge

Any additional comments?

No response

@MITIN33 MITIN33 added the Type: Bug 🐞 Something isn't working label Sep 22, 2024
@stsrki
Copy link
Collaborator

stsrki commented Sep 23, 2024

I can confirm that it improperly renders the default blue color. The hover should be calculated based on the supplied color.

Going on the list.

@stsrki stsrki self-assigned this Sep 23, 2024
@stsrki stsrki added this to the 1.6 support milestone Sep 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug 🐞 Something isn't working
Projects
Status: 🔙 Backlog
Development

No branches or pull requests

2 participants