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

Make superset-logo-horiz.png bigger #30933

Open
acolgecen opened this issue Nov 15, 2024 · 1 comment
Open

Make superset-logo-horiz.png bigger #30933

acolgecen opened this issue Nov 15, 2024 · 1 comment

Comments

@acolgecen
Copy link

I would like to enlarge the superset-logo-horiz.png logo on the Superset UI's frontend.
I understand that the superset_config.py file does not recognize CUSTOM_CSS = "/static/assets/".

Does anyone know the correct way to achieve this?

Copy link

dosubot bot commented Nov 15, 2024

To enlarge the superset-logo-horiz.png logo in the Superset UI, you can use custom CSS. Here's how you can achieve this:

  1. Inject Custom CSS: Use the injectCustomCss function to apply your custom styles. This function allows you to add CSS directly to the document's head.
import injectCustomCss from 'path/to/injectCustomCss';

const customCss = `
  /* Example CSS to enlarge the logo */
  .navbar-brand img {
    width: 200px; /* Adjust the width as needed */
    height: auto; /* Maintain aspect ratio */
  }
`;

const removeCustomCSS = injectCustomCss(customCss);

// Call removeCustomCSS() if you need to remove the custom styles later
  1. CSS Templates: Alternatively, you can create a CSS template using the CssTemplate model in Superset. This allows you to manage and apply styles across the application consistently.

By using these methods, you can customize the size of the logo without modifying the core Superset files.

To continue talking to Dosu, mention @dosu.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant