Lewati ke konten
MarkasUI
Ketik untuk mencari

    Panduan

    MarkasUI

    Form

    Feedback

    Overlay

    Navigasi

    Data

    Section

    Animasi

    Latar

    Tombol

    Template

    Halaman

    Ripple Background

    Lingkaran konsentris yang berdenyut dari tengah, cocok di belakang logo, avatar, atau ikon status.

    Connect your favorite tools

    Bring in GitHub, Slack, and Figma. Updates flow both ways.

    Connect your favorite tools

    Bring in GitHub, Slack, and Figma. Updates flow both ways.

    Connect your favorite tools

    Bring in GitHub, Slack, and Figma. Updates flow both ways.

    Connect your favorite tools

    Bring in GitHub, Slack, and Figma. Updates flow both ways.

    Connect your favorite tools

    Bring in GitHub, Slack, and Figma. Updates flow both ways.

    <div class="overflow-hidden rounded-xl border border-line bg-surface">
      <x-markas.ripple-background :size="88" :gap="56" class="grid h-48 place-items-center border-b border-line bg-canvas">
        <span class="grid size-14 place-items-center rounded-full border border-line bg-surface text-ink">
          <svg class="size-6" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M10 14a3.5 3.5 0 0 0 5 0l3-3a3.5 3.5 0 0 0-5-5l-1 1" /><path d="M14 10a3.5 3.5 0 0 0-5 0l-3 3a3.5 3.5 0 0 0 5 5l1-1" /></svg>
        </span>
      </x-markas.ripple-background>
      <div class="grid justify-items-center gap-3 p-6 text-center">
        <h2 class="text-xl font-semibold text-ink">Connect your favorite tools</h2>
        <p class="max-w-72 text-sm text-muted">Bring in GitHub, Slack, and Figma. Updates flow both ways.</p>
        <x-markas.button>Browse integrations</x-markas.button>
      </div>
    </div>
    import { Button } from "@/components/markas/Button";
    import { RippleBackground } from "@/components/markas/RippleBackground";
    
    export default function RippleBackgroundExample() {
      return (
        <div className="overflow-hidden rounded-xl border border-line bg-surface">
          <RippleBackground
            size={88}
            gap={56}
            className="grid h-48 place-items-center border-b border-line bg-canvas"
          >
            <span className="grid size-14 place-items-center rounded-full border border-line bg-surface text-ink">
              <svg
                className="size-6"
                viewBox="0 0 24 24"
                fill="none"
                stroke="currentColor"
                strokeWidth="1.5"
                strokeLinecap="round"
                strokeLinejoin="round"
                aria-hidden="true"
              >
                <path d="M10 14a3.5 3.5 0 0 0 5 0l3-3a3.5 3.5 0 0 0-5-5l-1 1" />
                <path d="M14 10a3.5 3.5 0 0 0-5 0l-3 3a3.5 3.5 0 0 0 5 5l1-1" />
              </svg>
            </span>
          </RippleBackground>
          <div className="grid justify-items-center gap-3 p-6 text-center">
            <h2 className="text-xl font-semibold text-ink">
              Connect your favorite tools
            </h2>
            <p className="max-w-72 text-sm text-muted">
              Bring in GitHub, Slack, and Figma. Updates flow both ways.
            </p>
            <Button>Browse integrations</Button>
          </div>
        </div>
      );
    }
    <script setup lang="ts">
    import Button from "@/components/markas/Button.vue";
    import RippleBackground from "@/components/markas/RippleBackground.vue";
    </script>
    
    <template>
      <div class="overflow-hidden rounded-xl border border-line bg-surface">
        <RippleBackground
          :size="88"
          :gap="56"
          class="grid h-48 place-items-center border-b border-line bg-canvas"
        >
          <span
            class="grid size-14 place-items-center rounded-full border border-line bg-surface text-ink"
          >
            <svg
              class="size-6"
              viewBox="0 0 24 24"
              fill="none"
              stroke="currentColor"
              stroke-width="1.5"
              stroke-linecap="round"
              stroke-linejoin="round"
              aria-hidden="true"
            >
              <path d="M10 14a3.5 3.5 0 0 0 5 0l3-3a3.5 3.5 0 0 0-5-5l-1 1" />
              <path d="M14 10a3.5 3.5 0 0 0-5 0l-3 3a3.5 3.5 0 0 0 5 5l1-1" />
            </svg>
          </span>
        </RippleBackground>
        <div class="grid justify-items-center gap-3 p-6 text-center">
          <h2 class="text-xl font-semibold text-ink">
            Connect your favorite tools
          </h2>
          <p class="max-w-72 text-sm text-muted">
            Bring in GitHub, Slack, and Figma. Updates flow both ways.
          </p>
          <Button>Browse integrations</Button>
        </div>
      </div>
    </template>
    <script lang="ts">
      import Button from "$lib/components/markas/Button.svelte";
      import RippleBackground from "$lib/components/markas/RippleBackground.svelte";
    </script>
    
    <div class="overflow-hidden rounded-xl border border-line bg-surface">
      <RippleBackground
        size={88}
        gap={56}
        class="grid h-48 place-items-center border-b border-line bg-canvas"
      >
        <span
          class="grid size-14 place-items-center rounded-full border border-line bg-surface text-ink"
        >
          <svg
            class="size-6"
            viewBox="0 0 24 24"
            fill="none"
            stroke="currentColor"
            stroke-width="1.5"
            stroke-linecap="round"
            stroke-linejoin="round"
            aria-hidden="true"
          >
            <path d="M10 14a3.5 3.5 0 0 0 5 0l3-3a3.5 3.5 0 0 0-5-5l-1 1" />
            <path d="M14 10a3.5 3.5 0 0 0-5 0l-3 3a3.5 3.5 0 0 0 5 5l1-1" />
          </svg>
        </span>
      </RippleBackground>
      <div class="grid justify-items-center gap-3 p-6 text-center">
        <h2 class="text-xl font-semibold text-ink">Connect your favorite tools</h2>
        <p class="max-w-72 text-sm text-muted">
          Bring in GitHub, Slack, and Figma. Updates flow both ways.
        </p>
        <Button>Browse integrations</Button>
      </div>
    </div>
    ---
    import Button from "@/components/markas/Button.astro";
    import RippleBackground from "@/components/markas/RippleBackground.astro";
    ---
    
    <div class="overflow-hidden rounded-xl border border-line bg-surface">
      <RippleBackground
        size={88}
        gap={56}
        class="grid h-48 place-items-center border-b border-line bg-canvas"
      >
        <span class="grid size-14 place-items-center rounded-full border border-line bg-surface text-ink">
          <svg
            class="size-6"
            viewBox="0 0 24 24"
            fill="none"
            stroke="currentColor"
            stroke-width="1.5"
            stroke-linecap="round"
            stroke-linejoin="round"
            aria-hidden="true"
          >
            <path d="M10 14a3.5 3.5 0 0 0 5 0l3-3a3.5 3.5 0 0 0-5-5l-1 1" />
            <path d="M14 10a3.5 3.5 0 0 0-5 0l-3 3a3.5 3.5 0 0 0 5 5l1-1" />
          </svg>
        </span>
      </RippleBackground>
      <div class="grid justify-items-center gap-3 p-6 text-center">
        <h2 class="text-xl font-semibold text-ink">
          Connect your favorite tools
        </h2>
        <p class="max-w-72 text-sm text-muted">
          Bring in GitHub, Slack, and Figma. Updates flow both ways.
        </p>
        <Button>Browse integrations</Button>
      </div>
    </div>
    import { Component } from "@angular/core";
    import { Button } from "./markas/button.component";
    import { RippleBackground } from "./markas/ripple-background.component";
    
    @Component({
      selector: "markas-example",
      imports: [Button, RippleBackground],
      template: `
        <div class="overflow-hidden rounded-xl border border-line bg-surface">
          <div
            markas-ripple-background
            size="88"
            gap="56"
            class="grid h-48 place-items-center border-b border-line bg-canvas"
          >
            <span
              class="grid size-14 place-items-center rounded-full border border-line bg-surface text-ink"
            >
              <svg
                class="size-6"
                viewBox="0 0 24 24"
                fill="none"
                stroke="currentColor"
                stroke-width="1.5"
                stroke-linecap="round"
                stroke-linejoin="round"
                aria-hidden="true"
              >
                <path d="M10 14a3.5 3.5 0 0 0 5 0l3-3a3.5 3.5 0 0 0-5-5l-1 1" />
                <path d="M14 10a3.5 3.5 0 0 0-5 0l-3 3a3.5 3.5 0 0 0 5 5l1-1" />
              </svg>
            </span>
          </div>
          <div class="grid justify-items-center gap-3 p-6 text-center">
            <h2 class="text-xl font-semibold text-ink">
              Connect your favorite tools
            </h2>
            <p class="max-w-72 text-sm text-muted">
              Bring in GitHub, Slack, and Figma. Updates flow both ways.
            </p>
            <button markas-button>Browse integrations</button>
          </div>
        </div>
      `,
    })
    export default class RippleBackgroundExample {}

    Contoh

    Keadaan mencari

    Looking for nearby devices

    Keep your phone unlocked and close to this screen.

    Looking for nearby devices

    Keep your phone unlocked and close to this screen.

    Looking for nearby devices

    Keep your phone unlocked and close to this screen.

    Looking for nearby devices

    Keep your phone unlocked and close to this screen.

    Looking for nearby devices

    Keep your phone unlocked and close to this screen.

    Panggilan masuk

    MC

    Calling Maya Chen

    Ringing on desktop and mobile

    MC

    Calling Maya Chen

    Ringing on desktop and mobile

    MC

    Calling Maya Chen

    Ringing on desktop and mobile

    MC

    Calling Maya Chen

    Ringing on desktop and mobile

    MC

    Calling Maya Chen

    Ringing on desktop and mobile

    Ubin ringkas

    Inbox zero

    New replies will show up here as soon as they arrive.

    Inbox zero

    New replies will show up here as soon as they arrive.

    Inbox zero

    New replies will show up here as soon as they arrive.

    Inbox zero

    New replies will show up here as soon as they arrive.

    Inbox zero

    New replies will show up here as soon as they arrive.

    Instalasi

    npx markasui@latest add ripple-background

    Pemakaian

    <x-markas.ripple-background :size="88" :gap="56" class="grid h-48 place-items-center rounded-xl bg-canvas">
        <span class="grid size-14 place-items-center rounded-full border border-line bg-surface">MC</span>
    </x-markas.ripple-background>

    Tidak butuh JavaScript atau Alpine.js.

    import { RippleBackground } from "@/components/markas/RippleBackground";
    
    <RippleBackground
      size={88}
      gap={56}
      className="grid h-48 place-items-center rounded-xl bg-canvas"
    >
      <span className="grid size-14 place-items-center rounded-full border border-line bg-surface">
        MC
      </span>
    </RippleBackground>;
    <template>
      <RippleBackground
        :size="88"
        :gap="56"
        class="grid h-48 place-items-center rounded-xl bg-canvas"
      >
        <span
          class="grid size-14 place-items-center rounded-full border border-line bg-surface"
          >MC</span
        >
      </RippleBackground>
    </template>
    <script lang="ts">
      import RippleBackground from "$lib/components/markas/RippleBackground.svelte";
    </script>
    
    <RippleBackground
      size={88}
      gap={56}
      class="grid h-48 place-items-center rounded-xl bg-canvas"
    >
      <span
        class="grid size-14 place-items-center rounded-full border border-line bg-surface"
      >
        MC
      </span>
    </RippleBackground>
    ---
    import RippleBackground from "@/components/markas/RippleBackground.astro";
    ---
    
    <RippleBackground
      size={88}
      gap={56}
      class="grid h-48 place-items-center rounded-xl bg-canvas"
    >
      <span class="grid size-14 place-items-center rounded-full border border-line bg-surface">
        MC
      </span>
    </RippleBackground>
    import { Component } from "@angular/core";
    import { RippleBackground } from "./markas/ripple-background.component";
    
    @Component({
      selector: "app-call",
      imports: [RippleBackground],
      template: `
        <div
          markas-ripple-background
          size="88"
          gap="56"
          class="grid h-48 place-items-center rounded-xl bg-canvas"
        >
          <span
            class="grid size-14 place-items-center rounded-full border border-line bg-surface"
          >
            MC
          </span>
        </div>
      `,
    })
    export class Call {}

    Angular memakai attribute selector pada div native, jadi class, aria-*, dan atribut lain tetap di elemen akar.

    • Lingkaran berada di tengah komponen. Letakkan ikon atau avatar di tengah dengan grid place-items-center.
    • Kalau denyut punya arti, misalnya sedang mencari, sampaikan juga lewat teks (misalnya dengan role="status").
    • Komponen ini tidak punya teks bawaan, jadi tidak ada prop label yang perlu diterjemahkan.

    Props

    NamaTipeDefaultKeterangan
    ringsnumber6Jumlah lingkaran, maksimal 12.
    sizenumber120Diameter lingkaran paling dalam dalam piksel.
    gapnumber64Pertambahan diameter tiap lingkaran dari lingkaran sebelumnya, dalam piksel.
    colormuted | primary | success | warning | dangermutedWarna token lingkaran. Lingkaran luar memudar otomatis.
    children / slotslot / ReactNode-Konten yang tampil di atas lingkaran, biasanya di tengah.

    Aksesibilitas

    • Lapisan lingkaran memakai aria-hidden dan mengabaikan pointer.
    • Dengan reduced motion, lingkaran berhenti berdenyut.
    • Kalau denyut punya arti (misalnya sedang mencari), sampaikan juga lewat teks.

    Komponen terkait

    Komponen latar lain dengan class yang sama di setiap framework.