Movatterモバイル変換


[0]ホーム

URL:


  1. 開発者向けのウェブ技術
  2. Web API
  3. Element
  4. ariaMultiSelectable

このページはコミュニティーの尽力で英語から翻訳されました。MDN Web Docsコミュニティーについてもっと知り、仲間になるにはこちらから。

View in EnglishAlways switch to English

Element: ariaMultiSelectable プロパティ

Baseline 2023
Newly available

Since October 2023, this feature works across the latest devices and browser versions. This feature might not work in older devices or browsers.

ariaMultiSelectableElement インターフェイスのプロパティで、aria-multiselectable 属性の値を反映し、ユーザーが現在の選択可能な子孫から複数の項目を選択できることを示します。

メモ:可能であれば、HTML の<select> 要素を使用してください。これは意味づけが組み込まれており、ARIA 属性を必要としないからです。

以下のいずれかの値を持つ文字列です。

"true"

一度に複数の項目を選択することができます。

"false"

選択できる項目は 1 つです。

この例では、ID がlistbox1 の要素のaria-multiselectable 属性が "true" に設定されており、この入力が複数の選択項目を受け入れることを示しています。ariaMultiSelectable を使用して、値を "false" に更新します。

html
<div role="listbox" tabindex="0"  aria-multiselectable="true" aria-labelledby="listbox1label" aria-activedescendant="listbox1-1">  <div role="option" aria-selected="true">Green</div>  <div role="option">Orange</div>  <div role="option">Red</div<</div>
js
let el = document.getElementById("listbox1");console.log(el.ariaMultiSelectable); // "true"el.ariaMultiSelectable = "false";console.log(el.ariaMultiSelectable); // "false"

仕様書

Specification
Accessible Rich Internet Applications (WAI-ARIA)
# dom-ariamixin-ariamultiselectable

ブラウザーの互換性

関連情報

Help improve MDN

Learn how to contribute

This page was last modified on byMDN contributors.


[8]ページ先頭

©2009-2026 Movatter.jp