
Product
Introducing Tier 1 Reachability: Precision CVE Triage for Enterprise Teams
Socket’s new Tier 1 Reachability filters out up to 80% of irrelevant CVEs, so security teams can focus on the vulnerabilities that matter.
目标:一致化浏览器排版效果,构建最适合中文阅读的网页排版。包括桌面和移动平台。
预览:typo.css
.
├── README.md --- 使用帮助
├── license.txt --- 许可证
├── typo.css --- 将应用于你的项目
└── typo.html --- Demo/预览
1、一般 reset.css 所需的内容
目前的设计是这样的,尽量保持完整的 reset,比如让 ul/ol 无样式并且无多余的 padding
/margin
,这是必须的,因为一个网可能需要很多自定义的的内容,在实践中我们并不希望像 ul/ol 有样式,这样我们得用优先级去覆盖,这是非常麻烦的事。所以 typo.css 并不像 normalize.css,后者给每一个元素都预先定义了样式,这样在自定义的时候将是非常痛苦的。要大保持干净的所有元素一致化的 reset 才是最佳实践。
2、class="typo"
阅读内容排版
在文章/文档阅读的页面,需添加 .typo
这个 class,这样 table/ol/ul 等都会有预定的样式,让你的排版像 http://typo.sofi.sh 一样,让用户阅读起来更舒服。
在父容器在没有添加 class="typo"
的时候,可以使用 class="typo-标签"
(如 class="typo-ul"
)来实现像 .typo > ul
这样结构的样式。
3、增加类:
主要是一些需要中文日常排版需要的元素和语文对应样式的增强,目前包括:
(1) 专名号:使用标签 <u>
或者 .typo-u
(2) 着重号:使用 class .typo-em
(3) 清理浮动:与一般 reset.css 保持一致 .clearfix
(4) 强制换行:添加 .textwrap
到文本所在的容器,如果是 table
测还需要 .textwrap-table
(5) 衬线字体:添加 .serif
(6) 创建 border-box:在 html 中添加 .borderbox
#why
基于 MIT License 开源,使用代码只需说明来源,或者引用 license.txt 即可。
FAQs
中文网页重设与排版:一致化浏览器排版效果,构建最适合中文阅读的网页排版 http://typo.sofi.sh
We found that typocss demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Socket’s new Tier 1 Reachability filters out up to 80% of irrelevant CVEs, so security teams can focus on the vulnerabilities that matter.
Research
/Security News
Ongoing npm supply chain attack spreads to DuckDB: multiple packages compromised with the same wallet-drainer malware.
Security News
The MCP Steering Committee has launched the official MCP Registry in preview, a central hub for discovering and publishing MCP servers.