From da78a9e329e272dedb2400b79a3bdeebff387d47 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:42:17 -0500 Subject: initial commit --- files/ko/web/html/element/optgroup/index.html | 120 ++++++++++++++++++++++++++ 1 file changed, 120 insertions(+) create mode 100644 files/ko/web/html/element/optgroup/index.html (limited to 'files/ko/web/html/element/optgroup') diff --git a/files/ko/web/html/element/optgroup/index.html b/files/ko/web/html/element/optgroup/index.html new file mode 100644 index 0000000000..b735d6ec1b --- /dev/null +++ b/files/ko/web/html/element/optgroup/index.html @@ -0,0 +1,120 @@ +--- +title: +slug: Web/HTML/Element/optgroup +tags: + - Element + - Forms + - HTML + - HTML forms + - Reference + - Web +translation_of: Web/HTML/Element/optgroup +--- +
{{HTMLRef}}
+ +

HTML <optgroup> 요소는 {{HTMLElement("select")}} 요소의 옵션을 묶을 수 있습니다.

+ +
{{EmbedInteractiveExample("pages/tabbed/optgroup.html", "tabbed-standard")}}
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
콘텐츠 카테고리없음.
가능한 콘텐츠0개 이상의 {{htmlelement("option")}} 요소.
태그 생략여는 태그는 필수입니다. 바로 뒤따르는 요소가 다른 <optgroup>이거나, 자신이 부모의 마지막 자식이라면 닫는 태그를 생략할 수 있습니다.
가능한 부모 요소{{HTMLElement("select")}} 요소.
가능한 ARIA 역할없음
DOM 인터페이스{{domxref("HTMLOptGroupElement")}}
+ +
+

참고: <optgroup> 요소는 중첩할 수 없습니다.

+
+ +

특성

+ +

이 요소는 전역 특성을 포함합니다.

+ +
+
{{htmlattrdef("disabled")}}
+
지정한 경우 모든 하위 옵션을 선택할 수 없습니다. 브라우저에서, 비활성화 옵션은 주로 회색으로 보이며, 클릭과 포커스 등 모든 이벤트를 받지 않습니다.
+
{{htmlattrdef("label")}}
+
옵션 그룹의 이름. 브라우저가 그룹의 이름을 표시할 때 사용할 수 있습니다. 필수로 지정해야 합니다.
+
+ +

예제

+ +
<select>
+  <optgroup label="Group 1">
+    <option>Option 1.1</option>
+  </optgroup>
+  <optgroup label="Group 2">
+    <option>Option 2.1</option>
+    <option>Option 2.2</option>
+  </optgroup>
+  <optgroup label="Group 3" disabled>
+    <option>Option 3.1</option>
+    <option>Option 3.2</option>
+    <option>Option 3.3</option>
+  </optgroup>
+</select>
+
+ +

결과

+ +

{{EmbedLiveSample("예제")}}

+ +

명세

+ + + + + + + + + + + + + + + + + + + + + + + + + + +
SpecificationStatusComment
{{SpecName('HTML WHATWG', 'forms.html#the-optgroup-element', '<optgroup>')}}{{Spec2('HTML WHATWG')}}
{{SpecName('HTML5 W3C', 'sec-forms.html#the-optgroup-element', '<optgroup>')}}{{Spec2('HTML5 W3C')}}
{{SpecName('HTML4.01', 'interact/forms.html#h-17.6', '<optgroup>')}}{{Spec2('HTML4.01')}}
+ +

브라우저 호환성

+ + + +

{{Compat("html.elements.optgroup")}}

-- cgit v1.2.3-54-g00ecf