Button
يُنفّذ إجراءً. ستة أنماط، ونسختان للإجراءات المدمّرة وللخلفيات الملونة، وثلاثة أحجام، وزر الأيقونة فقط وحالة التحميل.
الإصدار 0.2.0 ·
التثبيت
bunx --bun shadcn@latest add @dga/buttonيثبّت هذا الأمر أيضًا Spinner لحالة التحميل.
الاستخدام
import { Button } from "@/components/ui/button";
export default function Page() {
return <Button>إرسال الطلب</Button>;
}البنية
Root (<button type="button">، أو أي عنصر عبر render)، وIcon اختيارية قبل Label أو بعده، وSpinner يحل محل الأيقونة الأولى أثناء loading.
أمثلة
الأنماط
| النمط | متى يُستخدم |
|---|---|
primary | الإجراء الرئيسي. واحد في كل عرض. |
neutral | إجراء قوي بلا لون العلامة (في Figma: Primary-Neutral). |
secondary | إجراءات مساندة بجوار الإجراء الرئيسي (في Figma: Secondary-Solid). |
outline | إجراءات مساندة على الخلفيات المزدحمة (في Figma: Secondary-Outline). |
subtle | إجراءات منخفضة الأهمية في أشرطة الأدوات والجداول. |
transparent | إجراءات تشبه النص. يتغير لون التسمية عند التمرير. |
الإجراء المدمّر
أضف destructive للإجراءات التي تحذف أو لا يمكن التراجع عنها. لكل نمط ما عدا neutral نسخة مدمّرة، وneutral يرجع إلى primary المدمّر.
للخلفيات الملونة
أضف onColor على تعبئات العلامة (background-primary وترويسة التنقل). تكون تسميات الإجراء المدمّر بيضاء هناك، والنص هو الذي يحمل المعنى.
الأحجام
ارتفاع sm 24px، وmd 32px (الافتراضي)، وlg 40px.
الحالات
يشير aria-pressed إلى زر تبديل (أو data-selected في القوائم والمجموعات)، ويمنع disabled الإجراء، ويعرض loading التقدّم.
يستبدل loading الأيقونة الأولى بمؤشر دوّار، ويحافظ على العرض، ويتجاهل النقرات. ويبقى الزر قابلًا لاستقبال التركيز.
الأيقونات
ضع على أيقونة Hugeicons الوسم data-icon="inline-start" أو "inline-end". تحتاج أزرار الأيقونة فقط إلى iconOnly وإلى aria-label.
كرابط
لجعل الرابط يبدو كزر، اعرض عنصر a عبر الخاصية render:
<Button nativeButton={false} render={<a href="/services" />}>
الخدمات
</Button>اتجاه RTL
تتبدل جهات الأيقونات والمسافات والحشوات من تلقاء نفسها (خصائص منطقية). أما الأيقونات الاتجاهية كالأسهم فلا تنقلب: أضف rtl:-scale-x-100.
إمكانية الوصول
| المفتاح | الإجراء |
|---|---|
| Tab | ينقل التركيز إلى الزر. |
| Enter أو Space | يُفعّله. |
- عنصر
<button type="button">أصلي: يُعلَن دورbuttonواسمه. - حلقة التركيز على
:focus-visibleفقط: حدborder-blackبسمك 2px (أبيض في الوضع الداكن وعلى تعبئات العلامة)، وفاصل 1px. - تحتاج أزرار الأيقونة فقط إلى
aria-label؛ والأيقونات مخفية عن قارئات الشاشة. - يشير
aria-pressedإلى زر تبديل مضغوط. ويضبطloadingالقيمتينaria-busyوaria-disabled؛ والمؤشر الدوّار زخرفي.
مرجع API
Button
ينفّذ إجراءً. ستة أنماط، ونسختان للإجراءات المدمّرة وللخلفيات الملونة، وثلاثة أحجام، وزر بأيقونة فقط وحالة تحميل.
| الخاصية | النوع | القيمة الافتراضية |
|---|---|---|
"primary" | "neutral" | "secondary" | "outline" | "subtle" | "transparent"النمط. `neutral` يقابل Primary-Neutral في Figma، و`secondary` يقابل Secondary-Solid، و`outline` يقابل Secondary-Outline. | "primary" | |
| ||
"sm" | "md" | "lg"الارتفاع: `sm` 24px، و`md` 32px، و`lg` 40px. | "md" | |
| ||
booleanالنسخة المدمّرة من النمط. لا يوجد لـ `neutral` نسخة مدمّرة في Figma، فيعود إلى `primary` المدمّر. | false | |
| ||
booleanللأزرار على خلفيات لون العلامة (`background-primary`، وترويسة التنقل). | false | |
| ||
booleanمربع بأيقونة فقط. يحتاج إلى `aria-label`. | false | |
| ||
booleanيعرض مؤشر تحميل مكان الأيقونة الأولى (أو الأيقونة نفسها في الأزرار ذات الأيقونة فقط)، ويضبط aria-busy، ويتجاهل النقرات. يحافظ الزر على عرضه ويبقى قابلًا للتركيز. | false | |
| ||
ReactElement | functionيتيح لك استبدال عنصر HTML الخاص بالمكوّن بوسم آخر، أو تركيبه مع مكوّن آخر. يقبل `ReactElement` أو دالة تعيد العنصر المراد عرضه. | لا توجد قيمة افتراضية | |
| ||
يقبل أيضًا جميع خصائص Base UI Button (يفتح في نافذة جديدة).
الدالة buttonVariants() مُصدَّرة لتنسيق عناصر أخرى كأزرار.
الاختلافات عن DGA
| التغيير | السبب |
|---|---|
--button-background-transparent-hovered (light) | White label on white-20 over the brand fill fails AA (down to 2.38:1). Black-20 darkens the fill instead (6.30:1 or better), as dark mode already does. |
--button-background-transparent-pressed (light) | White label on white-40 over the brand fill fails AA (down to 2.38:1). Black-40 darkens the fill instead (6.30:1 or better), as dark mode already does. |
--button-background-transparent-selected (light) | White label on white-30 over the brand fill fails AA (down to 2.38:1). Black-30 darkens the fill instead (6.30:1 or better), as dark mode already does. |
--button-label-transparent-hovered-on-color (light) و11 غيرها | Green-300/400 on the brand fill is 2.10–2.82:1. The label stays white and the state is shown with an underline instead. |
عرض جميع الاختلافات (46) لهذا المكوّن أسباب الاختلافات مكتوبة بالإنجليزية.
التباين
1,210 زوجًا لونيًا فُحص · جميعها تجتاز WCAG 2.1 AAعرض 242 حالةإخفاء
| النمط / الحالة | الفاتح | الداكن |
|---|---|---|
| primary / default | 4.74:1 AA | 4.74:1 AA |
| primary / default (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| primary / hovered | 6.60:1 AA | 6.60:1 AA |
| primary / hovered (icon) | 6.60:1 3:1 | 6.60:1 3:1 |
| primary / pressed | 10.81:1 AAA | 10.81:1 AAA |
| primary / pressed (icon) | 10.81:1 3:1 | 10.81:1 3:1 |
| primary / selected | 8.55:1 AAA | 8.55:1 AAA |
| primary / selected (icon) | 8.55:1 3:1 | 8.55:1 3:1 |
| primary / focused | 4.74:1 AA | 4.74:1 AA |
| primary / focused (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| primary / focus ring | 17.31:1 3:1 | 17.49:1 3:1 |
| neutral / default | 18.74:1 AAA | 15.89:1 AAA |
| neutral / default (icon) | 18.74:1 3:1 | 15.89:1 3:1 |
| neutral / hovered | 14.53:1 AAA | 10.57:1 AAA |
| neutral / hovered (icon) | 14.53:1 3:1 | 10.57:1 3:1 |
| neutral / pressed | 7.36:1 AAA | 7.66:1 AAA |
| neutral / pressed (icon) | 7.36:1 3:1 | 7.66:1 3:1 |
| neutral / selected | 10.17:1 AAA | 10.57:1 AAA |
| neutral / selected (icon) | 10.17:1 3:1 | 10.57:1 3:1 |
| neutral / focused | 18.74:1 AAA | 15.89:1 AAA |
| neutral / focused (icon) | 18.74:1 3:1 | 15.89:1 3:1 |
| neutral / focus ring | 17.31:1 3:1 | 17.49:1 3:1 |
| secondary / default | 16.44:1 AAA | 12.71:1 AAA |
| secondary / default (icon) | 16.44:1 3:1 | 12.71:1 3:1 |
| secondary / hovered | 14.61:1 AAA | 6.95:1 AA |
| secondary / hovered (icon) | 14.61:1 3:1 | 6.95:1 3:1 |
| secondary / pressed | 14.61:1 AAA | 6.95:1 AA |
| secondary / pressed (icon) | 14.61:1 3:1 | 6.95:1 3:1 |
| secondary / selected | 14.61:1 AAA | 9.59:1 AAA |
| secondary / selected (icon) | 14.61:1 3:1 | 9.59:1 3:1 |
| secondary / focused | 16.44:1 AAA | 12.71:1 AAA |
| secondary / focused (icon) | 16.44:1 3:1 | 12.71:1 3:1 |
| secondary / focus ring | 17.31:1 3:1 | 17.49:1 3:1 |
| outline / default | 17.31:1 AAA | 15.87:1 AAA |
| outline / default (icon) | 17.31:1 3:1 | 15.87:1 3:1 |
| outline / hovered | 16.44:1 AAA | 12.71:1 AAA |
| outline / hovered (icon) | 16.44:1 3:1 | 12.71:1 3:1 |
| outline / pressed | 14.61:1 AAA | 6.95:1 AA |
| outline / pressed (icon) | 14.61:1 3:1 | 6.95:1 3:1 |
| outline / selected | 14.61:1 AAA | 9.59:1 AAA |
| outline / selected (icon) | 14.61:1 3:1 | 9.59:1 3:1 |
| outline / focused | 17.31:1 AAA | 15.87:1 AAA |
| outline / focused (icon) | 17.31:1 3:1 | 15.87:1 3:1 |
| outline / focus ring | 17.31:1 3:1 | 17.49:1 3:1 |
| subtle / default | 17.31:1 AAA | 15.87:1 AAA |
| subtle / default (icon) | 17.31:1 3:1 | 15.87:1 3:1 |
| subtle / hovered | 16.44:1 AAA | 12.71:1 AAA |
| subtle / hovered (icon) | 16.44:1 3:1 | 12.71:1 3:1 |
| subtle / pressed | 14.61:1 AAA | 6.95:1 AA |
| subtle / pressed (icon) | 14.61:1 3:1 | 6.95:1 3:1 |
| subtle / selected | 14.61:1 AAA | 9.59:1 AAA |
| subtle / selected (icon) | 14.61:1 3:1 | 9.59:1 3:1 |
| subtle / focused | 17.31:1 AAA | 15.87:1 AAA |
| subtle / focused (icon) | 17.31:1 3:1 | 15.87:1 3:1 |
| subtle / focus ring | 17.31:1 3:1 | 17.49:1 3:1 |
| transparent / default | 17.31:1 AAA | 15.87:1 AAA |
| transparent / default (icon) | 17.31:1 3:1 | 15.87:1 3:1 |
| transparent / hovered | 6.31:1 AA | 10.38:1 AAA |
| transparent / hovered (icon) | 6.31:1 3:1 | 10.38:1 3:1 |
| transparent / pressed | 10.34:1 AAA | 13.05:1 AAA |
| transparent / pressed (icon) | 10.34:1 3:1 | 13.05:1 3:1 |
| transparent / selected | 8.18:1 AAA | 10.38:1 AAA |
| transparent / selected (icon) | 8.18:1 3:1 | 10.38:1 3:1 |
| transparent / focused | 17.31:1 AAA | 15.87:1 AAA |
| transparent / focused (icon) | 17.31:1 3:1 | 15.87:1 3:1 |
| transparent / focus ring | 17.31:1 3:1 | 17.49:1 3:1 |
| primary on-colour / default | 18.09:1 AAA | 17.04:1 AAA |
| primary on-colour / default (icon) | 18.09:1 3:1 | 17.04:1 3:1 |
| primary on-colour / hovered | 12.97:1 AAA | 13.44:1 AAA |
| primary on-colour / hovered (icon) | 12.97:1 3:1 | 13.44:1 3:1 |
| primary on-colour / pressed | 8.89:1 AAA | 10.30:1 AAA |
| primary on-colour / pressed (icon) | 8.89:1 3:1 | 10.30:1 3:1 |
| primary on-colour / selected | 8.89:1 AAA | 10.30:1 AAA |
| primary on-colour / selected (icon) | 8.89:1 3:1 | 10.30:1 3:1 |
| primary on-colour / focused | 18.09:1 AAA | 16.42:1 AAA |
| primary on-colour / focused (icon) | 18.09:1 3:1 | 16.42:1 3:1 |
| primary on-colour / focus ring | 4.74:1 3:1 | 4.74:1 3:1 |
| neutral on-colour / default | 18.09:1 AAA | 17.04:1 AAA |
| neutral on-colour / default (icon) | 18.09:1 3:1 | 17.04:1 3:1 |
| neutral on-colour / hovered | 12.97:1 AAA | 13.44:1 AAA |
| neutral on-colour / hovered (icon) | 12.97:1 3:1 | 13.44:1 3:1 |
| neutral on-colour / pressed | 8.89:1 AAA | 10.30:1 AAA |
| neutral on-colour / pressed (icon) | 8.89:1 3:1 | 10.30:1 3:1 |
| neutral on-colour / selected | 10.76:1 AAA | 11.80:1 AAA |
| neutral on-colour / selected (icon) | 10.76:1 3:1 | 11.80:1 3:1 |
| neutral on-colour / focused | 18.09:1 AAA | 16.42:1 AAA |
| neutral on-colour / focused (icon) | 18.09:1 3:1 | 16.42:1 3:1 |
| neutral on-colour / focus ring | 4.74:1 3:1 | 4.74:1 3:1 |
| secondary on-colour / default | 6.30:1 AA | 6.30:1 AA |
| secondary on-colour / default (icon) | 6.30:1 3:1 | 6.30:1 3:1 |
| secondary on-colour / hovered | 6.30:1 AA | 6.30:1 AA |
| secondary on-colour / hovered (icon) | 6.30:1 3:1 | 6.30:1 3:1 |
| secondary on-colour / pressed | 8.46:1 AAA | 8.46:1 AAA |
| secondary on-colour / pressed (icon) | 8.46:1 3:1 | 8.46:1 3:1 |
| secondary on-colour / selected | 7.31:1 AAA | 7.31:1 AAA |
| secondary on-colour / selected (icon) | 7.31:1 3:1 | 7.31:1 3:1 |
| secondary on-colour / focused | 6.30:1 AA | 6.30:1 AA |
| secondary on-colour / focused (icon) | 6.30:1 3:1 | 6.30:1 3:1 |
| secondary on-colour / focus ring | 4.74:1 3:1 | 4.74:1 3:1 |
| outline on-colour / default | 4.74:1 AA | 4.74:1 AA |
| outline on-colour / default (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| outline on-colour / hovered | 6.30:1 AA | 6.30:1 AA |
| outline on-colour / hovered (icon) | 6.30:1 3:1 | 6.30:1 3:1 |
| outline on-colour / pressed | 8.46:1 AAA | 8.46:1 AAA |
| outline on-colour / pressed (icon) | 8.46:1 3:1 | 8.46:1 3:1 |
| outline on-colour / selected | 7.31:1 AAA | 7.31:1 AAA |
| outline on-colour / selected (icon) | 7.31:1 3:1 | 7.31:1 3:1 |
| outline on-colour / focused | 4.74:1 AA | 4.74:1 AA |
| outline on-colour / focused (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| outline on-colour / focus ring | 4.74:1 3:1 | 4.74:1 3:1 |
| subtle on-colour / default | 4.74:1 AA | 4.74:1 AA |
| subtle on-colour / default (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| subtle on-colour / hovered | 6.30:1 AA | 6.30:1 AA |
| subtle on-colour / hovered (icon) | 6.30:1 3:1 | 6.30:1 3:1 |
| subtle on-colour / pressed | 8.46:1 AAA | 8.46:1 AAA |
| subtle on-colour / pressed (icon) | 8.46:1 3:1 | 8.46:1 3:1 |
| subtle on-colour / selected | 7.31:1 AAA | 7.31:1 AAA |
| subtle on-colour / selected (icon) | 7.31:1 3:1 | 7.31:1 3:1 |
| subtle on-colour / focused | 4.74:1 AA | 4.74:1 AA |
| subtle on-colour / focused (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| subtle on-colour / focus ring | 4.74:1 3:1 | 4.74:1 3:1 |
| transparent on-colour / default | 4.74:1 AA | 4.74:1 AA |
| transparent on-colour / default (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| transparent on-colour / hovered | 4.74:1 AA | 4.74:1 AA |
| transparent on-colour / hovered (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| transparent on-colour / pressed | 4.74:1 AA | 4.74:1 AA |
| transparent on-colour / pressed (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| transparent on-colour / selected | 4.74:1 AA | 4.74:1 AA |
| transparent on-colour / selected (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| transparent on-colour / focused | 4.74:1 AA | 4.74:1 AA |
| transparent on-colour / focused (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| transparent on-colour / focus ring | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive primary / default | 4.83:1 AA | 4.83:1 AA |
| destructive primary / default (icon) | 4.83:1 3:1 | 4.83:1 3:1 |
| destructive primary / hovered | 6.57:1 AA | 6.57:1 AA |
| destructive primary / hovered (icon) | 6.57:1 3:1 | 6.57:1 3:1 |
| destructive primary / pressed | 9.84:1 AAA | 9.84:1 AAA |
| destructive primary / pressed (icon) | 9.84:1 3:1 | 9.84:1 3:1 |
| destructive primary / selected | 8.66:1 AAA | 8.66:1 AAA |
| destructive primary / selected (icon) | 8.66:1 3:1 | 8.66:1 3:1 |
| destructive primary / focused | 4.83:1 AA | 4.83:1 AA |
| destructive primary / focused (icon) | 4.83:1 3:1 | 4.83:1 3:1 |
| destructive primary / focus ring | 17.31:1 3:1 | 17.49:1 3:1 |
| destructive secondary / default | 6.04:1 AA | 8.59:1 AAA |
| destructive secondary / default (icon) | 6.04:1 3:1 | 8.59:1 3:1 |
| destructive secondary / hovered | 5.45:1 AA | 7.94:1 AAA |
| destructive secondary / hovered (icon) | 5.45:1 3:1 | 7.94:1 3:1 |
| destructive secondary / pressed | 4.63:1 AA | 7.50:1 AAA |
| destructive secondary / pressed (icon) | 4.63:1 3:1 | 7.50:1 3:1 |
| destructive secondary / selected | 6.04:1 AA | 8.59:1 AAA |
| destructive secondary / selected (icon) | 6.04:1 3:1 | 8.59:1 3:1 |
| destructive secondary / focused | 6.04:1 AA | 8.59:1 AAA |
| destructive secondary / focused (icon) | 6.04:1 3:1 | 8.59:1 3:1 |
| destructive secondary / focus ring | 17.31:1 3:1 | 17.49:1 3:1 |
| destructive primary on-colour / default | 4.83:1 AA | 4.83:1 AA |
| destructive primary on-colour / default (icon) | 4.83:1 3:1 | 4.83:1 3:1 |
| destructive primary on-colour / hovered | 6.57:1 AA | 6.57:1 AA |
| destructive primary on-colour / hovered (icon) | 6.57:1 3:1 | 6.57:1 3:1 |
| destructive primary on-colour / pressed | 9.84:1 AAA | 9.84:1 AAA |
| destructive primary on-colour / pressed (icon) | 9.84:1 3:1 | 9.84:1 3:1 |
| destructive primary on-colour / selected | 8.66:1 AAA | 8.66:1 AAA |
| destructive primary on-colour / selected (icon) | 8.66:1 3:1 | 8.66:1 3:1 |
| destructive primary on-colour / focused | 4.83:1 AA | 4.83:1 AA |
| destructive primary on-colour / focused (icon) | 4.83:1 3:1 | 4.83:1 3:1 |
| destructive primary on-colour / focus ring | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive secondary on-colour / default | 6.04:1 AA | 6.04:1 AA |
| destructive secondary on-colour / default (icon) | 6.04:1 3:1 | 6.04:1 3:1 |
| destructive secondary on-colour / hovered | 5.45:1 AA | 5.45:1 AA |
| destructive secondary on-colour / hovered (icon) | 5.45:1 3:1 | 5.45:1 3:1 |
| destructive secondary on-colour / pressed | 4.63:1 AA | 4.63:1 AA |
| destructive secondary on-colour / pressed (icon) | 4.63:1 3:1 | 4.63:1 3:1 |
| destructive secondary on-colour / selected | 6.04:1 AA | 6.04:1 AA |
| destructive secondary on-colour / selected (icon) | 6.04:1 3:1 | 6.04:1 3:1 |
| destructive secondary on-colour / focused | 6.04:1 AA | 6.04:1 AA |
| destructive secondary on-colour / focused (icon) | 6.04:1 3:1 | 6.04:1 3:1 |
| destructive secondary on-colour / focus ring | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive outline / default | 6.29:1 AA | 9.01:1 AAA |
| destructive outline / default (icon) | 6.29:1 3:1 | 9.01:1 3:1 |
| destructive outline / hovered | 5.45:1 AA | 7.94:1 AAA |
| destructive outline / hovered (icon) | 5.45:1 3:1 | 7.94:1 3:1 |
| destructive outline / pressed | 4.63:1 AA | 7.50:1 AAA |
| destructive outline / pressed (icon) | 4.63:1 3:1 | 7.50:1 3:1 |
| destructive outline / selected | 6.04:1 AA | 8.59:1 AAA |
| destructive outline / selected (icon) | 6.04:1 3:1 | 8.59:1 3:1 |
| destructive outline / focused | 6.29:1 AA | 9.01:1 AAA |
| destructive outline / focused (icon) | 6.29:1 3:1 | 9.01:1 3:1 |
| destructive outline / focus ring | 17.31:1 3:1 | 17.49:1 3:1 |
| destructive outline on-colour / default | 4.74:1 AA | 4.74:1 AA |
| destructive outline on-colour / default (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive outline on-colour / hovered | 6.30:1 AA | 6.30:1 AA |
| destructive outline on-colour / hovered (icon) | 6.30:1 3:1 | 6.30:1 3:1 |
| destructive outline on-colour / pressed | 8.46:1 AAA | 8.46:1 AAA |
| destructive outline on-colour / pressed (icon) | 8.46:1 3:1 | 8.46:1 3:1 |
| destructive outline on-colour / selected | 7.31:1 AAA | 7.31:1 AAA |
| destructive outline on-colour / selected (icon) | 7.31:1 3:1 | 7.31:1 3:1 |
| destructive outline on-colour / focused | 4.74:1 AA | 4.74:1 AA |
| destructive outline on-colour / focused (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive outline on-colour / focus ring | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive subtle / default | 6.29:1 AA | 9.01:1 AAA |
| destructive subtle / default (icon) | 6.29:1 3:1 | 9.01:1 3:1 |
| destructive subtle / hovered | 5.45:1 AA | 7.94:1 AAA |
| destructive subtle / hovered (icon) | 5.45:1 3:1 | 7.94:1 3:1 |
| destructive subtle / pressed | 4.63:1 AA | 7.50:1 AAA |
| destructive subtle / pressed (icon) | 4.63:1 3:1 | 7.50:1 3:1 |
| destructive subtle / selected | 6.04:1 AA | 8.59:1 AAA |
| destructive subtle / selected (icon) | 6.04:1 3:1 | 8.59:1 3:1 |
| destructive subtle / focused | 6.29:1 AA | 9.01:1 AAA |
| destructive subtle / focused (icon) | 6.29:1 3:1 | 9.01:1 3:1 |
| destructive subtle / focus ring | 17.31:1 3:1 | 17.49:1 3:1 |
| destructive subtle on-colour / default | 4.74:1 AA | 4.74:1 AA |
| destructive subtle on-colour / default (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive subtle on-colour / hovered | 6.30:1 AA | 6.30:1 AA |
| destructive subtle on-colour / hovered (icon) | 6.30:1 3:1 | 6.30:1 3:1 |
| destructive subtle on-colour / pressed | 8.46:1 AAA | 8.46:1 AAA |
| destructive subtle on-colour / pressed (icon) | 8.46:1 3:1 | 8.46:1 3:1 |
| destructive subtle on-colour / selected | 7.31:1 AAA | 7.31:1 AAA |
| destructive subtle on-colour / selected (icon) | 7.31:1 3:1 | 7.31:1 3:1 |
| destructive subtle on-colour / focused | 4.74:1 AA | 4.74:1 AA |
| destructive subtle on-colour / focused (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive subtle on-colour / focus ring | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive transparent / default | 4.62:1 AA | 6.27:1 AA |
| destructive transparent / default (icon) | 4.62:1 3:1 | 6.27:1 3:1 |
| destructive transparent / hovered | 6.29:1 AA | 9.01:1 AAA |
| destructive transparent / hovered (icon) | 6.29:1 3:1 | 9.01:1 3:1 |
| destructive transparent / pressed | 9.42:1 AAA | 12.32:1 AAA |
| destructive transparent / pressed (icon) | 9.42:1 3:1 | 12.32:1 3:1 |
| destructive transparent / selected | 8.29:1 AAA | 9.01:1 AAA |
| destructive transparent / selected (icon) | 8.29:1 3:1 | 9.01:1 3:1 |
| destructive transparent / focused | 4.62:1 AA | 6.27:1 AA |
| destructive transparent / focused (icon) | 4.62:1 3:1 | 6.27:1 3:1 |
| destructive transparent / focus ring | 17.31:1 3:1 | 17.49:1 3:1 |
| destructive transparent on-colour / default | 4.74:1 AA | 4.74:1 AA |
| destructive transparent on-colour / default (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive transparent on-colour / hovered | 4.74:1 AA | 4.74:1 AA |
| destructive transparent on-colour / hovered (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive transparent on-colour / pressed | 4.74:1 AA | 4.74:1 AA |
| destructive transparent on-colour / pressed (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive transparent on-colour / selected | 4.74:1 AA | 4.74:1 AA |
| destructive transparent on-colour / selected (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive transparent on-colour / focused | 4.74:1 AA | 4.74:1 AA |
| destructive transparent on-colour / focused (icon) | 4.74:1 3:1 | 4.74:1 3:1 |
| destructive transparent on-colour / focus ring | 4.74:1 3:1 | 4.74:1 3:1 |
يحتاج النص إلى تباين 4.5:1، والأيقونات وحلقات التركيز إلى 3:1. الحالات المعطّلة مستثناة. تقرير التباين الكامل