npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

amatsuchi

v0.0.10

Published

「縦書き・横スクロール・レスポンシブWebサイト」専用のCSSフレームワーク

Readme

amatsuchi

amatsuchi は「縦書き・横スクロール・レスポンシブWebサイト」専用のCSS・jsフレームワークです。

Web雑誌「偏向」のためのスタイルシートをライブラリ化しています。

  • 手軽に印刷された縦書き文書のようなページを作ることができます。

  • 「CSS Writing Modes Level3」を最大限活かした上で、ブラウザごとの差異を吸収できるよう微調整しています。多数あるjavascriptを利用した縦書きライブラリよりもレンダリングが美しく、軽量です。

  • スマートフォンでも美しいデザインを目指し実装しています。

使い方

  1. CSSファイルをインストールしてください。
npm install --save amatsuchi
  1. HTMLファイルのheadタグ内に、以下のようにlinkタグを追加してください。
<link rel="stylesheet" href="node_modules/amatsuchi/dist/amatsuchi.css">

ブラウザ判定(傍線などに使用)、句読点ぶら下げ機能を使う場合は、以下のjsも読み込んでください。

<script src="node_modules/amatsuchi/dist/main.js"/>
  1. ページにamatsuchiクラスを追加してください。これにより、縦書きに最適化されたページが生成されます。
<body class="amatsuchi">
    ...
</body>

CSS

amatsuchiは、基本的なタグのオーバーライドやページ用のクラスを提供しています。ページに追加することで、簡単に縦書きに最適化されたデザインを実現できます。

また、Amatsuchi.cssはSCSSで記述されています。カスタムデザインを作成する場合は、変数をオーバーライドするか、SCSSファイルを編集してください。

.midashi-box

.midashi-boxは、見出しを囲む要素に追加するクラスです。以下のスタイルが適用されます。

  • padding: 0 0 20px 20px;

.midashi-boxの子要素には.midashiと.hisshaがあります。.midashiは見出しのスタイルを設定し、.hisshaは署名を右寄せにします。

.yoko-bo

.yoko-boは、横書きに最適化された要素に追加するクラスです。以下のスタイルが適用されます。

  • writing-mode: horizontal-tb;

.rinku

.rinkuは、下線を引く要素に追加するクラスです。以下のスタイルが適用されます。

  • text-decoration-skip-ink: none;
  • text-decoration-line: underline;

.migi-bo

.migi-boは、右に線を引く要素に追加するクラスです。以下のスタイルが適用されます。

  • text-decoration-line: overline;
  • text-decoration-skip-ink: none;
  • text-decoration-thickness: from-font;

.hidari-bo

.hidari-boは、左に線を引く要素に追加するクラスです。以下のスタイルが適用されます。

  • text-decoration-skip-ink: none;
  • text-decoration-line: underline;
  • text-decoration-thickness: from-font;

.migi-nami

.migi-namiは、右に波線を引く要素に追加するクラスです。以下のスタイルが適用されます。

  • text-decoration-line: overline;
  • text-decoration-skip-ink: none;
  • text-decoration-thickness: from-font;
  • text-decoration-style: wavy;

.hidari-nami

.hidari-namiは、左に波線を引く要素に追加するクラスです。以下のスタイルが適用されます。

  • text-decoration-skip-ink: none;
  • text-decoration-line: underline;
  • text-decoration-thickness: from-font;
  • text-decoration-style: wavy;

.dash

.dashは、文字と文字の間にダッシュを入れる要素に追加するクラスです。以下のスタイルが適用されます。

  • letter-spacing: -0.2em;
  • margin: 2px 0 4px 0;

.jisage

.jisageは、段落の先頭に字下げを設定する要素に追加するクラスです。以下のスタイルが適用されます。

  • text-indent: 1rem;

js

句読点ぶら下げ

以下のように"burasage"クラスを付与してください。かつて存在したhanging-punctuationのような句読点ぶら下げをjavascriptによる処理で実現します。改行が減り、文章が読みやすくなります。

<body class="amatsuchi burasage">
    ...
</body>

フロートボタン

amatsuchiには、フロートボタン用のスタイルも含まれています。以下のように、ボタンを実装することができます。

<div id="ama-float">
    <a href="#">トップへ</a>
</div>

ライセンス

amatsuchiはMITライセンスのもとで公開されています。詳細については、LICENSEファイルを参照してください。

最後に

amatsuchi は協力者を探しています。協力いただける方は [email protected] or Twitter までご連絡お待ちしています。

本ライブラリはnpmに公開されています。