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

console.image log twice in console log #19

Open
afiqiqmal opened this issue Sep 5, 2018 · 3 comments
Open

console.image log twice in console log #19

afiqiqmal opened this issue Sep 5, 2018 · 3 comments

Comments

@afiqiqmal
Copy link

console.image log twice in console log

console.meme("Not sure if memes in dev tools is stupid", "or disastrous.", "Not Sure Fry");

see this screenshot : https://image.ibb.co/jqWope/Screen_Shot_2018_09_05_at_4_08_49_PM.png

@Mehvix
Copy link

Mehvix commented Oct 11, 2018

same issue here

@nchutchind
Copy link

I'm not sure what the actual solution is, since it seems to be related to Chrome changing how things work in the console, but I have found how to fix it if you're comfortable changing the code on your end.

In the getBox method, padding is applied to make room for the image, and the top/bottom padding is what's making the box too big and causing the background to repeat. If you change the following line:

style: "font-size: 1px; padding: " + Math.floor(height/2) + "px " + Math.floor(width/2) + "px; line-height: " + height + "px;"

to

style: "font-size: 1px; padding: 0 " + Math.floor(width/2) + "px; line-height: " + height + "px;"

then it will work as normal.

@cyqsimon
Copy link

In case you are lazy you can use this fork I found.
It works quite crudely (by dividing height by 2...) but works nonetheless.
See #22

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

4 participants