# 成員

誰在工作區裡、各是什麼身分：可變更的角色、要寄出的邀請，以及尚未回覆的邀請。

成員區塊讓工作區擁有者查看誰能進入、各是什麼身分，變更角色，並邀請新的人加入。成員是[面板](https://ui.master.co/tw/components/surface#sheet)上的一個[清單](https://ui.master.co/tw/components/list.md)，每個角色是原生的[下拉選單](https://ui.master.co/tw/components/select.md)，邀請則是[對話框](https://ui.master.co/tw/components/dialog.md)中的表單。還沒有人回覆的邀請排在成員下方，與成員分開，因為收到邀請信的地址還不是成員。

**成員**

```html
<section class="container-inline flex flex-col gap-lg max-w(720) mx-auto" aria-labelledby="members-title">
  <header class="flex flex-wrap items-end justify-between gap-md">
    <div class="flex flex-col gap-2xs min-w(0)">
      <h2 class="heading heading-lg" id="members-title">Members</h2>
      <p class="m(0) fg-text-muted">Five people work in Atlas Labs. Each takes one seat on Pro.</p>
    </div>
    <button type="button" class="btn btn-primary" commandfor="members-invite" command="show-modal"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L13 8"/><path d="M8 3L8 13"/></svg>Invite a member</button>
  </header>
  <div class="sheet px-md py-xs px-lg@container(--md)">
    <ul class="list">
      <li class="list-row">
        <span class="avatar list-media"><img class="avatar-image" src="/demo/people/yiching-lin.webp" alt="" width="256" height="256"></span>
        <div class="list-body">
          <p class="list-title">Yi-ching Lin <span class="badge badge-sm vertical-middle">You</span></p>
          <p class="list-description">yiching@atlaslabs.dev</p>
        </div>
        <span class="list-end fg-text-muted">Owner</span>
      </li>
      <li class="list-row">
        <span class="avatar list-media"><img class="avatar-image" src="/demo/people/pohan-chen.webp" alt="" width="256" height="256"></span>
        <div class="list-body">
          <p class="list-title">Po-han Chen</p>
          <p class="list-description">pohan@atlaslabs.dev</p>
        </div>
        <div class="list-end flex items-center gap-2xs">
          <select class="select select-sm w(104)@container(--md)" aria-label="Role of Po-han Chen">
            <option class="select-option" selected>Admin</option>
            <option class="select-option">Member</option>
            <option class="select-option">Viewer</option>
          </select>
          <button type="button" class="btn btn-quiet btn-square btn-sm" popovertarget="members-menu-pohan" aria-label="More for Po-han Chen"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="3.5" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="8" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="12.5" cy="8" r="1.05" fill="currentColor" stroke="none"/></svg></button>
          <div id="members-menu-pohan" popover class="menu menu-end">
            <button type="button" class="menu-item" popovertarget="members-menu-pohan" popovertargetaction="hide">Make owner</button>
            <hr class="menu-separator">
            <button type="button" class="menu-item menu-item-danger" popovertarget="members-menu-pohan" popovertargetaction="hide">Remove from Atlas Labs</button>
          </div>
        </div>
      </li>
      <li class="list-row">
        <span class="avatar list-media"><img class="avatar-image" src="/demo/people/misaki-sato.webp" alt="" width="256" height="256"></span>
        <div class="list-body">
          <p class="list-title">Misaki Sato</p>
          <p class="list-description">misaki@atlaslabs.dev</p>
        </div>
        <div class="list-end flex items-center gap-2xs">
          <select class="select select-sm w(104)@container(--md)" aria-label="Role of Misaki Sato">
            <option class="select-option" selected>Admin</option>
            <option class="select-option">Member</option>
            <option class="select-option">Viewer</option>
          </select>
          <button type="button" class="btn btn-quiet btn-square btn-sm" popovertarget="members-menu-misaki" aria-label="More for Misaki Sato"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="3.5" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="8" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="12.5" cy="8" r="1.05" fill="currentColor" stroke="none"/></svg></button>
          <div id="members-menu-misaki" popover class="menu menu-end">
            <button type="button" class="menu-item" popovertarget="members-menu-misaki" popovertargetaction="hide">Make owner</button>
            <hr class="menu-separator">
            <button type="button" class="menu-item menu-item-danger" popovertarget="members-menu-misaki" popovertargetaction="hide">Remove from Atlas Labs</button>
          </div>
        </div>
      </li>
      <li class="list-row">
        <span class="avatar list-media"><img class="avatar-image" src="/demo/people/seoyeon-kim.webp" alt="" width="256" height="256"></span>
        <div class="list-body">
          <p class="list-title">Seo-yeon Kim</p>
          <p class="list-description">seoyeon@atlaslabs.dev</p>
        </div>
        <div class="list-end flex items-center gap-2xs">
          <select class="select select-sm w(104)@container(--md)" aria-label="Role of Seo-yeon Kim">
            <option class="select-option">Admin</option>
            <option class="select-option" selected>Member</option>
            <option class="select-option">Viewer</option>
          </select>
          <button type="button" class="btn btn-quiet btn-square btn-sm" popovertarget="members-menu-seoyeon" aria-label="More for Seo-yeon Kim"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="3.5" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="8" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="12.5" cy="8" r="1.05" fill="currentColor" stroke="none"/></svg></button>
          <div id="members-menu-seoyeon" popover class="menu menu-end">
            <button type="button" class="menu-item" popovertarget="members-menu-seoyeon" popovertargetaction="hide">Make owner</button>
            <hr class="menu-separator">
            <button type="button" class="menu-item menu-item-danger" popovertarget="members-menu-seoyeon" popovertargetaction="hide">Remove from Atlas Labs</button>
          </div>
        </div>
      </li>
      <li class="list-row">
        <span class="avatar list-media"><img class="avatar-image" src="/demo/people/kenta-nakamura.webp" alt="" width="256" height="256"></span>
        <div class="list-body">
          <p class="list-title">Kenta Nakamura</p>
          <p class="list-description">kenta@atlaslabs.dev</p>
        </div>
        <div class="list-end flex items-center gap-2xs">
          <select class="select select-sm w(104)@container(--md)" aria-label="Role of Kenta Nakamura">
            <option class="select-option">Admin</option>
            <option class="select-option" selected>Member</option>
            <option class="select-option">Viewer</option>
          </select>
          <button type="button" class="btn btn-quiet btn-square btn-sm" popovertarget="members-menu-kenta" aria-label="More for Kenta Nakamura"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="3.5" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="8" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="12.5" cy="8" r="1.05" fill="currentColor" stroke="none"/></svg></button>
          <div id="members-menu-kenta" popover class="menu menu-end">
            <button type="button" class="menu-item" popovertarget="members-menu-kenta" popovertargetaction="hide">Make owner</button>
            <hr class="menu-separator">
            <button type="button" class="menu-item menu-item-danger" popovertarget="members-menu-kenta" popovertargetaction="hide">Remove from Atlas Labs</button>
          </div>
        </div>
      </li>
    </ul>
  </div>
  <section class="flex flex-col gap-sm" aria-labelledby="members-pending-title">
    <h3 class="heading heading-sm" id="members-pending-title">Pending invitations</h3>
    <div class="sheet px-md py-xs px-lg@container(--md)">
      <ul class="list">
        <li class="list-row">
          <div class="list-body">
            <p class="list-title">chiahao@atlaslabs.dev</p>
            <p class="list-description">Member, expires <time datetime="2026-11-28">28 Nov</time></p>
          </div>
          <div class="list-end flex items-center gap-2xs">
            <button type="button" class="btn btn-quiet btn-sm hidden inline-flex@container(--md)" aria-label="Resend the invitation to chiahao@atlaslabs.dev">Resend</button>
            <button type="button" class="btn btn-quiet btn-sm hidden inline-flex@container(--md)" aria-label="Revoke the invitation to chiahao@atlaslabs.dev">Revoke</button>
            <button type="button" class="btn btn-quiet btn-square btn-sm hidden@container(--md)" popovertarget="members-menu-chiahao" aria-label="More for the invitation to chiahao@atlaslabs.dev"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="3.5" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="8" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="12.5" cy="8" r="1.05" fill="currentColor" stroke="none"/></svg></button>
            <div id="members-menu-chiahao" popover class="menu menu-end">
              <button type="button" class="menu-item" popovertarget="members-menu-chiahao" popovertargetaction="hide">Resend invitation</button>
              <button type="button" class="menu-item menu-item-danger" popovertarget="members-menu-chiahao" popovertargetaction="hide">Revoke invitation</button>
            </div>
          </div>
          <p class="list-meta"><span>Invited by Po-han Chen on <time datetime="2026-11-21">21 Nov</time></span></p>
        </li>
        <li class="list-row">
          <div class="list-body">
            <p class="list-title">yuna@atlaslabs.dev</p>
            <p class="list-description">Viewer, expires <time datetime="2026-11-30">30 Nov</time></p>
          </div>
          <div class="list-end flex items-center gap-2xs">
            <button type="button" class="btn btn-quiet btn-sm hidden inline-flex@container(--md)" aria-label="Resend the invitation to yuna@atlaslabs.dev">Resend</button>
            <button type="button" class="btn btn-quiet btn-sm hidden inline-flex@container(--md)" aria-label="Revoke the invitation to yuna@atlaslabs.dev">Revoke</button>
            <button type="button" class="btn btn-quiet btn-square btn-sm hidden@container(--md)" popovertarget="members-menu-yuna" aria-label="More for the invitation to yuna@atlaslabs.dev"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><circle cx="3.5" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="8" cy="8" r="1.05" fill="currentColor" stroke="none"/><circle cx="12.5" cy="8" r="1.05" fill="currentColor" stroke="none"/></svg></button>
            <div id="members-menu-yuna" popover class="menu menu-end">
              <button type="button" class="menu-item" popovertarget="members-menu-yuna" popovertargetaction="hide">Resend invitation</button>
              <button type="button" class="menu-item menu-item-danger" popovertarget="members-menu-yuna" popovertargetaction="hide">Revoke invitation</button>
            </div>
          </div>
          <p class="list-meta"><span>Invited by you on <time datetime="2026-11-23">23 Nov</time></span></p>
        </li>
      </ul>
    </div>
  </section>
  <dialog id="members-invite" class="dialog" aria-labelledby="members-invite-title" aria-describedby="members-invite-description">
    <header class="dialog-header">
      <h2 class="dialog-title" id="members-invite-title">Invite a member</h2>
      <p class="dialog-description" id="members-invite-description">They get an email with a link that works for seven days.</p>
    </header>
    <form class="dialog-body flex flex-col gap-md" method="dialog" id="members-invite-form">
      <label class="field">
        Email
        <input class="input" type="email" name="email" autocomplete="off" required autofocus>
      </label>
      <div class="field">
        <label for="members-invite-role">Role</label>
        <select class="select" id="members-invite-role" name="role" aria-describedby="members-invite-role-hint">
          <option class="select-option">Admin</option>
          <option class="select-option" selected>Member</option>
          <option class="select-option">Viewer</option>
        </select>
        <p class="field-hint" id="members-invite-role-hint">A member deploys and reads logs. An admin also manages people and environment variables. A viewer only reads.</p>
      </div>
      <p class="m(0) fg-text-muted">All five seats are taken. A sixth adds $20 a month from the day the invitation is accepted.</p>
    </form>
    <footer class="dialog-footer">
      <button type="button" class="btn" commandfor="members-invite" command="close">Cancel</button>
      <button type="submit" class="btn btn-primary" form="members-invite-form">Send invitation</button>
    </footer>
    <button type="button" class="btn btn-quiet btn-square btn-sm dialog-close" commandfor="members-invite" command="close" aria-label="Close"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M4 4L12 12"/><path d="M4 12L12 4"/></svg></button>
  </dialog>
</section>
```

區塊提供可直接複製的標記，沿用頁面的文字顏色和字級。預覽在 body 上設定 `fg-text-body text-sm`。每個區塊都是尺寸容器，無論放在寬大的頁面、側邊欄大小的空間，還是對話框裡，都會依自身寬度重新排列。

<a id="anatomy"></a>

## 組成

- **人數，以及它的費用。** 標題下方的那一行說明有多少人，以及每人占一個席位。在這裡新增成員就是在花錢，使用者應該在對話框開啟前就知道這件事。
- **整頁只有一個主要操作。** 「Invite a member」（邀請成員）是唯一的主要[按鈕](https://ui.master.co/tw/components/button.md)，位於標頭的結尾側。它以 `commandfor` 和 `command="show-modal"` 開啟對話框，因此開啟和關閉都不需要腳本。
- **成員是 `list` 的各列。** [頭像](https://ui.master.co/tw/components/avatar.md)是 `list-media`，姓名和地址是 `list-body`，角色和該列的選單則是 `list-end`。頭像和結尾側的內容會對齊兩行文字的中央。
- **角色是原生的 `<select>`。** `select-sm` 讓它與旁邊的小型按鈕等高。列中沒有多餘的空間放標籤，所以每個下拉選單都以所屬的人命名：「Role of Po-han Chen」（Po-han Chen 的角色）。
- **擁有者的那一列沒有控制項。** 登入者不能將自己降級或移除，所以他們的角色是較淡的文字，標題中的[徽章](https://ui.master.co/tw/components/badge.md)寫著「You」（你）。擁有權從另一列的[選單](https://ui.master.co/tw/components/menu.md)移轉：「Make owner」（設為擁有者）。
- **無法復原的操作收在選單裡**，使用危險色，並寫明要將這個人從哪裡移除。它不會以按鈕的形式放在列中：一排五個紅色按鈕會讓整頁變成在談離開。
- **邀請是第二個清單。** 邀請只有地址，還沒有對應的人，所以它的列沒有頭像。說明文字寫出角色、邀請者和邀請失效的時間，每個日期都放在 `<time>` 中。
- **對話框說明這個選擇的費用。** 角色下方的提示用一句話說明各角色可以做什麼，最後一行則說明席位已滿，以及多一個席位會增加多少費用。數字與[帳務摘要](https://ui.master.co/tw/blocks/billing-summary.md)一致：五個席位，每個 $20。

區塊顯示的是伺服器保存的狀態。變更角色、重寄和撤銷都是由你的應用程式送出的請求；每次完成後，請把結果寫入 `role="status"` 區域讓它被讀出，並在某一列離開時把焦點移到下一列。

<a id="roles"></a>

## 各角色可以做什麼

選擇角色之前，讀者會想比較各個角色。這就是一張[表格](https://ui.master.co/tw/components/table.md)：角色是欄，可執行的操作是列，每個儲存格回答是或否。它放在成員下方，或放在獨立的頁面上，由對話框的提示連過去。

**各角色可以做什麼**

```html
<section class="container-inline flex flex-col gap-md max-w(720) mx-auto" aria-labelledby="members-roles-title">
  <header class="flex flex-col gap-2xs">
    <h2 class="heading heading-lg" id="members-roles-title">Roles</h2>
    <p class="m(0) fg-text-muted">A workspace has one owner. Every other person is an admin, a member or a viewer.</p>
  </header>
  <div class="sheet overflow-hidden">
    <div class="scroll-area scroll-area-inline" tabindex="0" role="region" aria-labelledby="members-roles-title">
      <table class="table">
        <thead>
          <tr class="table-row">
            <th class="table-heading" scope="col"><span class="sr-only">What can be done</span></th>
            <th class="table-heading" scope="col">Owner</th>
            <th class="table-heading" scope="col">Admin</th>
            <th class="table-heading" scope="col">Member</th>
            <th class="table-heading" scope="col">Viewer</th>
          </tr>
        </thead>
        <tbody>
          <tr class="table-row">
            <th class="table-cell table-primary whitespace-nowrap" scope="row">Read deployments and logs</th>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
          </tr>
          <tr class="table-row">
            <th class="table-cell table-primary whitespace-nowrap" scope="row">Deploy a preview</th>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
          </tr>
          <tr class="table-row">
            <th class="table-cell table-primary whitespace-nowrap" scope="row">Promote to production</th>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
          </tr>
          <tr class="table-row">
            <th class="table-cell table-primary whitespace-nowrap" scope="row">Edit environment variables</th>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
          </tr>
          <tr class="table-row">
            <th class="table-cell table-primary whitespace-nowrap" scope="row">Invite and remove people</th>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
          </tr>
          <tr class="table-row">
            <th class="table-cell table-primary whitespace-nowrap" scope="row">Change the plan and pay</th>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
          </tr>
          <tr class="table-row">
            <th class="table-cell table-primary whitespace-nowrap" scope="row">Delete the workspace</th>
            <td class="table-cell"><svg class="icon" viewBox="0 0 16 16" fill="none" stroke="currentColor" stroke-width="1" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M3 8L6.3532 11.3532A0.2 0.2 0 0 0 6.6412 11.3479L13 4.5"/></svg><span class="sr-only">Yes</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
            <td class="table-cell fg-text-muted"><span aria-hidden="true">–</span><span class="sr-only">No</span></td>
          </tr>
        </tbody>
      </table>
    </div>
  </div>
</section>
```

- **勾號和短橫線，各搭配一個詞。** 勾號是對輔助技術隱藏的[圖示](https://ui.master.co/tw/components/icon.md)，短橫線則是一個字元；兩者旁邊都有 `sr-only` 的「Yes」（是）或「No」（否），因此儲存格會被讀成一個答案，而不是「圖片」或什麼都沒有。
- **各列從所有人都能做的事，排到只有一個人能做的事。** 順著一欄往下讀，勾號結束的地方就是該角色權限的盡頭；順著一列橫向讀，短橫線從權限停止的地方開始。
- **它會橫向捲動，不會重新堆疊。** 讀成卡片的矩陣就不再是比較。空間狹窄時，`scroll-area` 沿行內軸捲動，並讓還有更多欄的那一側邊緣淡出；它帶有 `tabindex="0"`、角色和名稱，因為其中沒有任何元素能取得焦點。

<a id="accessibility"></a>

## 無障礙

- 區塊是一個 `<section>`，以其 `<h2>` 命名。待回覆的邀請是另一個區段，位於 `<h3>` 之下，因此依標題移動的讀者能找到兩個清單。
- 列中的控制項會連同所在的列一起命名：「Role of Seo-yeon Kim」（Seo-yeon Kim 的角色）、「More for Seo-yeon Kim」（Seo-yeon Kim 的更多操作）、「Revoke the invitation to yuna@atlaslabs.dev」（撤銷給 yuna@atlaslabs.dev 的邀請）。五個都叫「Role」的控制項，在表單欄位清單中無從分辨。
- 肖像重複了旁邊的姓名，所以它們的 `alt` 留空。
- 對話框以其標題命名，並以標題下方的句子作為描述，開啟時焦點會移到電子郵件欄位。關閉時，瀏覽器會把焦點交還給開啟它的按鈕。
- 對話框的送出按鈕位於對話框的頁尾，在表單之外，並以 `form` 與表單相連。在電子郵件欄位按 Enter 就會送出，遇到無法寄達的地址時，瀏覽器本身的驗證會讓對話框保持開啟。

<a id="related"></a>

## 相關內容

- [清單](https://ui.master.co/tw/components/list.md)
- [頭像](https://ui.master.co/tw/components/avatar.md)
- [下拉選單](https://ui.master.co/tw/components/select.md)
- [選單](https://ui.master.co/tw/components/menu.md)
- [對話框](https://ui.master.co/tw/components/dialog.md)
- [表格](https://ui.master.co/tw/components/table.md)
- [捲動區域](https://ui.master.co/tw/components/scroll-area.md)
- [徽章](https://ui.master.co/tw/components/badge.md)

- [帳務摘要](https://ui.master.co/tw/blocks/billing-summary.md)
- [表格檢視](https://ui.master.co/tw/blocks/table-view.md)
- [團隊](https://ui.master.co/tw/blocks/team.md)
- [登入](https://ui.master.co/tw/blocks/sign-in.md)
