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

using <script> ... </script> broken css ? #492

Closed
emper0r opened this issue Mar 23, 2016 · 5 comments
Closed

using <script> ... </script> broken css ? #492

emper0r opened this issue Mar 23, 2016 · 5 comments

Comments

@emper0r
Copy link

emper0r commented Mar 23, 2016

Hi, it's possible the < script > tag broke the css of django-suit?

i'm trying to implement a little dashboard using http://netdata.firehol.org/
according to wiki, i can use it with < script type="text/javascript" src="http://localhost:19999/dashboard.js" ></script>
but the left-nav for menus of django-suit lost the position when I use it.... how can i solve this?

using the new dashboard live
broking_left-nav

without script and using a simple < img > in this case mrtg works fine.
img_mrtg

i'm trying to use < span > or another < div > trying to override this error but nothing... :|

a snippet here: https://dpaste.de/1D67

@darklow
Copy link
Owner

darklow commented Mar 23, 2016

Looks like dashboard.js injects some inline styles which override django-suit menu styles.
You'll have to compare resulting CSS for both views and override manually to set it back to original.

@emper0r
Copy link
Author

emper0r commented Mar 23, 2016

Hi, thanks for a quick response, in fact, i see when i wrote the code, I lost the colors, and I must put this to override again to get back the css from django-suit

on the code with dashboard live... inserting this lines i can recovery from blue to my red style:

'< link rel="stylesheet" type="text/css" href="/static/suit/bootstrap/css/bootstrap.min.css"/>'
'< link rel="stylesheet" type="text/css" href="/static/suit/css/suit.css" media="all">'

those lines are from the mrtg view on comparasion. but not appears anithyng about left-nav css...
maybe inserting here another links for the left-nav ? what lines must be?

@darklow
Copy link
Owner

darklow commented Mar 23, 2016

It will be impossible to paste all styles here.
But you can use Chrome or Firefox console to see resulting CSS and where each style definition comes from.
For example:
image

@emper0r
Copy link
Author

emper0r commented Mar 23, 2016

Ok, I'll keep trying , thanks

@emper0r
Copy link
Author

emper0r commented Mar 23, 2016

ok, found it!!....
need override suit.css: 9
#suit-left {
width: 200px;
right: 240px;
margin-left: -94%; (before -100%) just moving 6px
}

@emper0r emper0r closed this as completed Mar 23, 2016
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

2 participants