Skip to content
COMPONENT / DATA-DISPLAY

Typography.

Tampilkan title, text dan quote opsional dengan ritme tipografi yang konsisten..

PHP + native HTML/CSSNo build

Preview

Words with a little room.

Readable pages start with simple structure and a considered rhythm.

Make the useful thing easy.

Usage

Tampilkan title, text dan quote opsional dengan ritme tipografi yang konsisten.

  1. Gunakan layout DL yang sudah memuat CSS dan dl.js.
  2. Letakkan kode berikut di view PHP Anda.
  3. Ganti data contoh dengan nilai aplikasi. Teks di-escape otomatis.
PHP view
<?= component('typography', ['title' => 'Words with a little room.', 'text' => 'Readable pages start with simple structure and a considered rhythm.', 'quote' => 'Make the useful thing easy.']) ?>

API reference

Props PHP yang didukung implementasi DL. Field di dalam array mengikuti bentuk pada kolom Type. Props yang tidak dicantumkan tidak menjadi bagian API komponen.

Typography props
PropType / valuesPanduan
titlestringJudul konten yang ditampilkan.
textstringIsi teks biasa; HTML di-escape.
quotestringKutipan opsional.

Behavior & accessibility

Menghasilkan h2, paragraf dan blockquote. Atur hierarki judul halaman di luar komponen.

Uji keyboard, fokus, dan pembaca layar pada halaman aplikasi Anda. Contoh ini tidak menggantikan audit aksesibilitas aplikasi secara menyeluruh.

Source & agent context

Source tersedia di views/components/typography.php. Edit template ini jika membutuhkan perilaku tambahan. API PHP DL berbeda dari API React sumber rujukan.

Terminal
php dl component typography

Component guide · JavaScript & events · Styling

Icons: Solar by 480 Design (CC BY 4.0) & Iconsax (MIT). PHP UI adapted from Coordiation. Logo: DesignLof.