Is there a way to specify the width of an embedded gist?

自作多情 提交于 2020-01-02 09:36:13

问题


I am trying to embed a gist into a webpage. Take the gist below as an example:

<script src="https://gist.github.com/Astr0surf3r/5208714.js"></script>

I wonder if there is a way to set the width of the gist. For example, I would like to to make the gist narrower than the default width.


回答1:


You can control the width by modifying the CSS class that this gist is using.

.gist { width: 250px; }

Example: http://jsfiddle.net/aFwEd/



来源:https://stackoverflow.com/questions/15535272/is-there-a-way-to-specify-the-width-of-an-embedded-gist

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!