I’ve been excited by the potential of text-box-trim, text-edge and text-box for a while. They’re in draft status at the moment, but when more browser support is available, this capability will open up some exciting possibilities for improving typesetting in the browser, as well as giving us more control of alignment and internal spacing in our components, such as a button. Daniel Schwarz wrote a g
Current music:toe — 風と記憶Current drink:Yunnan teaTable of Contents Introduction In a few of my latest experiments and articles (“Fit-to-Width Text: A New Technique” and “Querying the Color Scheme”), I used one naming pattern for registered custom properties that I think worth highlighting in a separate blog post. Registered custom properties are invaluable, as they unlock many things previously not
The new CSS Color 4 specification has added the new oklch() notation for declaring colors. In this post, we explain why this is important for design systems and color palettes. The extremely short version oklch() is a new way to define CSS colors. In oklch(L C H) or oklch(L C H / a), each item corresponds as follows: L is perceived lightness (0-1). “Perceived” means that it has consistent lightnes
OKLCH is a new way to encode colors (like hex, RGBA, or HSL)
css-text-4-memo-ja.md CSS Text Level 4 を読む(抄訳) CSS Text Module Level 4 W3C Working Draft, 19 February 2024 This version: https://www.w3.org/TR/2024/WD-css-text-4-20240219/ Latest published version: https://www.w3.org/TR/css-text-4/ Editor's Draft: https://drafts.csswg.org/css-text-4/ この文書はCSS Text Level 4を読むための参考として部分的に訳した抄訳です。 この仕様書全体の日本語訳は https://triple-underscore.github.io/css-text-ja.html に公開
CSS Text Module Level 4 の 4 つの新しい国際 CSS 機能が Chrome に導入されます。この投稿では、すでにリリースされている機能と、まもなくリリースされる機能について説明します。 Chrome 119 以降: word-break: auto-phrase を使用して日本語のフレーズを改行。 Chrome 120 のフラグ: text-autospace プロパティによるスクリプト間のスペース。 開発中: text-spacing-trim プロパティを使用した中国語、日本語、韓国語(CJK)の句読点のケーニング。 言語間で最小フォントサイズを統一する。 日本語のフレーズでの改行: word-break: auto-phrase この機能は日本語の読みやすさを向上させ、Chrome 119 以降で利用できます。 中国語や日本語などの東アジアの言語では、単語を
17 October, 2023 The Three Cs: 🤝 Concatenate, 🗜️ Compress, 🗳️ Cache Written by Harry Roberts on CSS Wizardry. Table of Contents Independent writing is brought to you via my wonderful Supporters. 🤝 Concatenate 🗜️ Compress 🗳️ Cache 📡 Connection 📱 Client My Advice The Future Is Brighter Shared Dictionary Compression for HTTP Compression Dictionaries tl;dr Appendix: Test Methodology I began wr
If you’ve ever attempted to create responsive type that seamlessly adapts and scales between pre-determined sizes within a type scale based on viewport or container widths, you may have wrestled with JavaScript or wrangled with CSS calculators. But with the help of calc(), clamp(), and a somewhat wonky use of CSS vars, we can simplify this process and tap into the dynamism that modern CSS affords.
後日追記: このブログの内容を再考して「Tailwind CSSで引数のあるMixinのような仕組みを作る方法(改)」として書き直した。 Sassでは、引数の値に応じて宣言をクラスに注入できるMixinの機能がある。たとえば次のようにすれば、フォントサイズがビューポートの幅に応じて流動的に変化するように実装できる。 @function rem($px) { @return ($px / 16 * 1rem); } // https://www.smashingmagazine.com/2022/01/modern-fluid-typography-css-clamp/ @function fluid-size($min-size, $max-size, $min-width: 640, $max-width: 1280) { $v: (100 * ($max-size - $min-siz
CSSは普通、セレクタの記述から始まる。目の前にあるHTML片に対してどのようなスタイリングを施すかという前に、いかにしてそのHTML片を選択するかという意識が先に来る。あらかじめ完成したHTML文書へ向けてスタイルを適用していくのであればそれでうまくやれるのかもしれない。だが広く行われているウェブデザインの制作では、まずゴールとして定められた描画結果だけがあり、そこから逆算してHTMLとCSSを書き進めていく。つまり個別の結果だけがある状態で実装に取り掛かることになる。実装のために必要な構造化はたいてい後手に回る。 それでもCSSがセレクタから始まることは変わらない。実装を進めるためにはまずセレクタを書かなければならない。セレクタは規則の根幹である。バグを減らし、開発を効率的にするためには、あらゆるスタイリングの意図をセレクタに反映させるのが基本だ。しかし最初から正確にその意図を把握でき
2021/10/25追記 おまたせしました。この記事の後編も公開しておりますので、合わせてお読みください。 inside.pixiv.blog こんにちは。プロダクトデザイナーの yksk とフロントエンドエンジニアの f_subal です。 ピクシブにはデザインシステムを開発するチームがあります。ピクシブが運営する数多くのプロダクトが共通のガイドライン、コードを使ってUIを設計できる体制への移行を目的としており、そのための仕組みづくりに取り組んでいます。 今回は、先日行われた pixiv DEV MEETUP 2021 のセッション「PIXIV Design System 2021」で発表した、技術的な取り組みについて前後編に分けて発表します。 前編にあたるこの記事では f_subal パートの内容をおさらいをしていきます。 PIXIV Design System 2021 昨年のpix
皆さんこんにちは。最近とある事情でTailwind CSSにわりと真剣に向き合わないといけなくなった筆者です。 Tailwind CSSの話題は、Twitterのフロントエンド界隈では定番のトークテーマのひとつです。しかし、筆者の考えを文章にまとめたことは無かったので、このたびブログ記事にすることにしました。 結論筆者が一番みなさんに伝えたいことは、Tailwind CSSは考え無しに採用してよい技術ではなく、採用するには熟慮が必要だということです。とくに、フロントエンドのスターターキット的なプロジェクトの中にTailwind CSSが混ざっていることがありますが、あれはけっこうな罠です。気軽に採用すべきものではありません。 筆者の考えでは、Tailwind CSSの採用を考慮に入れてよいのは次の2つの場合です。 デザインにこだわりがなく、最低限整っていればいい場合。デザイナー不在のプロジ
Sep 18, 2023 by Jen Simmons and the Safari / WebKit Team Today’s the day for Safari 17.0. It’s now available for iOS 17 and iPadOS 17. [Update September 26th] And now, Safari 17.0 is available for macOS Ventura, and macOS Monterey, and macOS Sonoma. Safari 17.0 is also available in the vision OS Simulator, where you can test your website by downloading the latest beta of Xcode 15, which supports t
CSS types are a worthy investment into type safety in your front-end work. We're still awaiting cross browser interop, but we'll get there 🙂 In case you've never seen one, here's a typed CSS variable with @property: @property --focal-size { syntax: '<length-percentage>'; initial-value: 100%; inherits: false; } Used that one so I could animate a gradient mask image. Pretty sweet. Here's a preview
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く