R

ReflexKR

Reflex公式ドキュメント

コンポーネント工房:Reflexライブラリ100

·

講座の概要

レイアウト

·

Box

·

Flex

·

Stack

·

Grid

·

Container

·

Section

·

Center

·

Spacer

·

Separator

·

Card

·

Inset

·

Aspect Ratio

·

Fragment

タイポグラフィ

·

Text

·

Heading

·

Link

·

Code

·

Markdown

·

Blockquote

·

Quote

·

Strong

·

Em

·

Kbd

フォーム

·

Button

·

Input

·

Text Area

·

Checkbox

·

Switch

·

Radio Group

·

Select

·

Slider

·

Form

·

Upload

データ表示

·

Badge

·

Avatar

·

Icon

·

Callout

·

List

·

Data List

·

Code Block

·

Progress

·

Spinner

·

Scroll Area

·

Moment

開閉と切り替え

·

Tabs

·

Accordion

·

Segmented Control

オーバーレイ

·

Tooltip

·

Popover

·

Hover Card

·

Dialog

·

Alert Dialog

·

Drawer

·

Dropdown Menu

·

Context Menu

·

Toast

動的レンダリング

·

Cond

·

Match

·

Foreach

·

Auto Scroll

メディア

·

Image

·

Audio

·

Video

表とデータグリッド

·

Table

·

Data Table

·

Data Editor

チャート

·

Area Chart

·

Bar Chart

·

Line Chart

·

Composed Chart

·

Pie Chart

·

Radar Chart

·

Radial Bar Chart

·

Scatter Chart

·

Funnel Chart

·

Treemap

·

Sankey Chart

·

Error Bar

チャートの部品

·

Axis

·

Cartesian Grid

·

Chart Tooltip

·

Legend

·

Label

·

Reference

·

Brush

ほかのチャートライブラリ

·

Plotly

·

Pyplot

HTML要素

·

HTML

·

HTML Text

·

HTML Layout

·

HTML Forms

·

HTML Media

·

HTML Tables

·

SVG

そのほかの道具

·

Theme

·

Skeleton

·

Clipboard

·

Html Embed

·

Script

·

Memo

コンポーネント工房:Reflexライブラリ100
タイポグラフィ

Quote

工房の注文書

会社紹介の段落の中に、お客さまの言葉を2つ、文を途切れさせずに引用として入れてください。

rx.text.quote は文の中に入る短い引用です。HTML の <q> タグになり、斜めのセリフ体(Radix テーマの引用用フォント)で区別されます。ブラウザやスクリーンリーダーにも、その部分が引用だと伝わります。文を区切って切り出して引用するなら rx.blockquote を使います。

His famous quote, Styles come and go. Good design is a language, not a style, elegantly sums up Massimo's philosophy of design.

rx.text(
    "His famous quote, ",
    rx.text.quote("Styles come and go. Good design is a language, not a style"),
    ", elegantly sums up Massimo's philosophy of design.",
)

プロパティ

Quote にはサイズや色のような見た目のプロパティがありません。周りの rx.text のサイズと色をそのまま受け継ぐので、見た目は外側の文字で決めます。そのためこのページには、プロパティの実習台の代わりに State で動く例があります。

プロパティ値既定値用途
子文字列、State の値必須引用する言葉
citeアドレス文字列なし引用元のアドレス(画面には表示されない)

このほか id、title、lang などの HTML 共通属性と基本イベントを受け取ります。

出典のアドレス:cite

cite に出典のアドレスを書くと、HTML 属性として残ります。画面には表示されないので、人に見せる出典は文中に直接書きます。

The guide says Simple is better than complex, and we agree.

rx.text(
    "The guide says ",
    rx.text.quote("Simple is better than complex", cite="https://peps.python.org/pep-0020/"),
    ", and we agree.",
    size="4",
)

外側の文字に従う

同じ Quote でも、小さなグレーの文の中では小さくグレーに、大きな太字の文や見出しの中では大きく太く表示されます。

Small: Less is more

Large: Less is more

In a heading: Less is more

rx.flex(
    rx.text("Small: ", rx.text.quote("Less is more"), size="2", color_scheme="gray"),
    rx.text("Large: ", rx.text.quote("Less is more"), size="6", weight="bold"),
    rx.heading("In a heading: ", rx.text.quote("Less is more"), as_="h3", size="5"),
    direction="column",
    spacing="3",
)

State の値を引用する

子に State の値を入れると、値が変わったときに引用も変わります。下のボタンは引用リストの番号だけを変えます。

As The Zen of Python puts it, Simple is better than complex.

class QuoteSayingState(rx.State):
    sayings: list[dict[str, str]] = [
        {"text": "Simple is better than complex", "who": "The Zen of Python"},
        {"text": "Readability counts", "who": "The Zen of Python"},
        {"text": "Now is better than never", "who": "The Zen of Python"},
    ]
    pick: int = 0

    @rx.event
    def next_saying(self):
        self.pick = (self.pick + 1) % len(self.sayings)


rx.flex(
    rx.text(
        "As ",
        QuoteSayingState.sayings[QuoteSayingState.pick]["who"],
        " puts it, ",
        rx.text.quote(QuoteSayingState.sayings[QuoteSayingState.pick]["text"]),
        ".",
        size="4",
    ),
    rx.button("Another one", on_click=QuoteSayingState.next_saying, size="1", variant="soft"),
    direction="column",
    align="start",
    spacing="3",
)

注文書を仕上げる

紹介文は1つの rx.text にして、お客さまの言葉2つだけを rx.text.quote で包みます。文が途切れず自然につながります。

Our support lead calls this the ten-minute rule: every message gets a first reply within ten minutes. Customers say it feels like talking to a friend.

rx.card(
    rx.text(
        "Our support lead calls this the ",
        rx.text.quote("ten-minute rule"),
        ": every message gets a first reply within ten minutes. Customers say it feels ",
        rx.text.quote("like talking to a friend"),
        ".",
        size="3",
    ),
    max_width="440px",
)

工房ノート

  • rx.text.quote("…") は文中の短い引用(<q>)。rx.text の中に子として入れる。

  • 見た目のプロパティはなく、周りの文字のサイズ・色に従う。

  • cite は出典のアドレスを HTML にだけ残す。

  • 切り出して見せる長い引用は rx.blockquote。

← 前へ

タイポグラフィ · Blockquote

次へ →

タイポグラフィ · Strong

新しい授業・講座のお知らせを受け取る

この講座に授業が追加されたり、続きの講座が公開されたりしたらメールでお知らせします。

収集項目:メールアドレス・目的:この講座の新しい授業・公開のお知らせ・保有期間:解除のご依頼まで。他の目的には使わず、第三者にも提供しません。お知らせメールに返信いただければすぐに削除します。

質問と回答

この回について気になることを書き込んでください。すべての言語のページの質問がここに集まります。

リンクや書式なしで、そのままの文字で表示されます。

R

ReflexKR

触って学ぶPythonとReflex。すべての例はReflex 0.10.0で実際に動かして確認しています。

ReflexKRはバナー広告なし・無料で運営しています。役に立ったら、コーヒー一杯で応援してください。 ☕ コーヒーで応援する

アフィリエイトと支援について
한국어English日本語简体中文EspañolDeutsch

© 2026 ReflexKR · Since 2026 · CC BY-NC 4.0

Built with Reflex