본문 바로가기
명함 만들기 캐릭터 모음 16가지 디자인 · PNG / SVG / PDF

아이콘 버튼

자리는 좁고, 뜻은 설명 없이도 통하는 동작에만 쓰는 조각.

버튼 · 액션

실제 미리보기

출처

<button type="button" class="dc-ibtn" aria-pressed="false">
  <svg class="dc-ibtn__icon" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" aria-hidden="true">
    <path d="M12 20C9 18 5 15 5 11a4 4 0 0 1 7-2.6A4 4 0 0 1 19 11c0 4-4 7-7 9z"></path>
  </svg>
  <span class="dc-sr">관심 목록에 담기</span>
</button>
.dc-ibtn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px;
  border: 1px solid var(--dc-line-field); border-radius: var(--dc-r-sm);
  background: var(--dc-surface); color: var(--dc-text-sub);
  transition: background var(--dc-fast), color var(--dc-fast), border-color var(--dc-fast);
}
.dc-ibtn:hover { background: var(--dc-sunken); color: var(--dc-text); }
.dc-ibtn[aria-pressed="true"] {
  background: var(--dc-brand-soft); border-color: var(--dc-brand); color: var(--dc-brand-text);
}
.dc-ibtn[aria-pressed="true"] .dc-ibtn__icon { fill: currentColor; }
.dc-ibtn[disabled] {
  background: var(--dc-sunken); color: var(--dc-text-mute);
  border-color: var(--dc-line); cursor: not-allowed;
}
.dc-ibtn__icon { width: 20px; height: 20px; }
.dc-ibtn--quiet { background: transparent; border-color: transparent; }
.dc-ibtn--quiet:hover { background: var(--dc-sunken); }
.dc-ibtn--solid {
  background: var(--dc-brand); border-color: var(--dc-brand); color: var(--dc-text-on);
}
.dc-ibtn--solid:hover { background: var(--dc-brand-hi); color: var(--dc-text-on); }
.dc-ibtn--badge { position: relative; }
.dc-ibtn__dot {
  position: absolute; top: 7px; right: 7px;
  width: 8px; height: 8px; border-radius: var(--dc-r-full);
  background: var(--dc-danger);
  box-shadow: 0 0 0 2px var(--dc-surface);
}

이렇게 씁니다

  • 뜻이 굳은 아이콘(닫기·검색·알림·더보기)에만 쓴다
  • 아이콘은 20px 라도 누르는 영역은 44×44px 로 둔다
  • 켜짐이 남는 것이면 aria-pressed 로 상태를 알린다

주의할 점

  • dc-sr 로 이름을 반드시 넣어라 — 없으면 스크린 리더는 '버튼'이라고만 읽는다
  • 새로운 뜻을 아이콘으로 가르치려 들지 마라. 글자를 붙이는 쪽이 빠르다

다음에 볼 것