Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: remove DOMAttributeMethods deprecated macro #23462

Merged
merged 1 commit into from
Sep 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions docs/ko/guides/macro-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,3 @@ EmbedLiveSample/MacroLiveSampleError 오류 찾는 [스크립트 링크 참고](
## 매크로 수정 및 번역

MDN은 초창기에 [kuma](https://github.com/mdn/kuma) 플랫폼으로 MDN 웹 문서를 구동해왔습니다. 그 당시 사용한 많은 매크로들이 레거시로 남아 있습니다. 레거시로 남은 매크로를 [Kumascript](https://github.com/mdn/kumascript)라고 부릅니다. 현재는 [yari 저장소 내의 kumascript 폴더](https://github.com/mdn/yari/tree/main/kumascript)로 대체되어 사용되고 있습니다([참고](https://egas.tistory.com/168#%EB%AF%B8%EC%82%AC%EC%9A%A9-macro-%EC%A0%9C%EA%B1%B0)).

만약 `{{DOMAttributeMethods}}` 매크로를 수정하자고 한다면 `kumascript/macros/DOMAttributeMethods.ejs`를 확인하면 됩니다([관련 PR](https://github.com/mdn/yari/pull/10502)).
2 changes: 0 additions & 2 deletions files/es/web/api/element/getattributenodens/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,6 @@ attributeNode = element.getAttributeNodeNS(namespace, nodeName);

`getAttributeNodeNS` es más específica [getAttributeNode](en/DOM/element.getAttributeNode) en el sentido de que puedes especificar atributos de un namespace en particular. Su método setter es [setAttributeNodeNS](en/DOM/element.setAttributeNodeNS).

{{ DOMAttributeMethods() }}

## Especificaciones

{{Specifications}}
Expand Down
2 changes: 0 additions & 2 deletions files/es/web/api/element/removeattribute/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@ Debe usarse preferiblemente `removeAttribute` en lugar de establecer el valor de

Intentar eliminar un atributo que no existe en el elemento no disparará una excepción.

{{ DOMAttributeMethods() }}

## Especificaciones

{{Specifications}}
Expand Down
4 changes: 0 additions & 4 deletions files/es/web/api/element/setattributens/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,6 @@ var d = document.getElementById("d1");
d.setAttributeNS("http://www.mozilla.org/ns/specialspace", "align", "center");
```

## Notas

{{ DOMAttributeMethods() }}

## Especificaciones

{{Specifications}}
Expand Down
2 changes: 0 additions & 2 deletions files/ja/web/api/element/getattributenode/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@ HTML 文書としてフラグが立てられた DOM 内の HTML 要素に対し

要素の属性の値を取得するためには、通常 `getAttributeNode` の代わりに [getAttribute](/ja/docs/Web/API/Element/getAttribute) が使用されます。

{{ DOMAttributeMethods() }}

## 仕様書

{{Specifications}}
Expand Down
2 changes: 0 additions & 2 deletions files/ja/web/api/element/getattributenodens/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@ getAttributeNodeNS(namespace, nodeName)

`getAttributeNodeNS` は [getAttributeNode](getAttributeNode) よりも、特定の名前空間に含まれる属性を特定することができる点でより具体的です。対応するセッターメソッドは [setAttributeNodeNS](/ja/docs/Web/API/Element/setAttributeNodeNS) です。

{{ DOMAttributeMethods() }}

## 仕様書

{{Specifications}}
Expand Down
2 changes: 0 additions & 2 deletions files/ja/web/api/element/getattributens/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,6 @@ HTML 文書では名前空間に対応していないため、この属性は `t

DOM4 より前の仕様では、このメソッドは属性が存在しない場合に null ではなく空文字列を返すように指定されていました。しかし、ほとんどのウェブブラウザーは null を返していました。 DOM4 以降は、仕様でも null を返すように指定されました。しかし、一部の古いウェブブラウザーは空文字列を返します。そのため、指定の要素に指定の属性が存在しない可能性があるなら、 `getAttributeNS` を呼ぶ前に {{domxref("element.hasAttributeNS()", "hasAttributeNS()")}} を使用して属性の存在を確かめる必要があります。

{{DOMAttributeMethods}}

## 仕様書

{{Specifications}}
Expand Down
4 changes: 0 additions & 4 deletions files/ja/web/api/element/hasattribute/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,6 @@ if (foo.hasAttribute("bar")) {
}
```

## メモ

{{DOMAttributeMethods}}

## 仕様書

{{Specifications}}
Expand Down
4 changes: 0 additions & 4 deletions files/ja/web/api/element/hasattributens/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,6 @@ if (
}
```

## メモ

{{ DOMAttributeMethods() }}

## 仕様書

{{Specifications}}
Expand Down
2 changes: 0 additions & 2 deletions files/ja/web/api/element/removeattribute/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@ removeAttribute(attrName)

属性の値を直接、または {{domxref("Element.setAttribute", "setAttribute()")}} を使用して `null` に設定するのではなく、 `removeAttribute()` を使用してください。多くの属性は `null` に設定しても、期待通りの動作をしません。

{{ DOMAttributeMethods() }}

## 例

```js
Expand Down
2 changes: 0 additions & 2 deletions files/ja/web/api/element/removeattributenode/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@ d.removeAttributeNode(d_align);

`removeAttributeNodeNS` メソッドはありません。`removeAttributeNode` メソッドは、名前空間付き属性と名前空間付きでない属性の両方を削除することができます。

{{ DOMAttributeMethods() }}

## 仕様書

{{Specifications}}
Expand Down
4 changes: 0 additions & 4 deletions files/ja/web/api/element/removeattributens/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,6 @@ d.removeAttributeNS("http://www.mozilla.org/ns/specialspace", "specialAlign");
// Now: <div id="div1" width="200px" />
```

## メモ

{{ DOMAttributeMethods() }}

## 仕様書

{{Specifications}}
Expand Down
2 changes: 0 additions & 2 deletions files/ja/web/api/element/setattribute/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,6 @@ button.setAttribute("disabled", "");
重要なことは、属性が存在する場合、実際の値に関係なく、その値は `true` とみなされるということです。
属性が存在しない場合、その値は `false` となります。`disabled` 属性の値を空文字列 (`""`) に設定することで、`disabled` を `true` に設定することになり、その結果ボタンは無効になります。

{{DOMAttributeMethods}}

## 仕様書

{{Specifications}}
Expand Down
2 changes: 0 additions & 2 deletions files/ja/web/api/element/setattributenode/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,6 @@ alert(d2.attributes[1].value);

このメソッドが使われることはあまりなく、通常は {{domxref("Element.setAttribute()")}} が要素の属性を変更するために使われます。

{{ DOMAttributeMethods() }}

## 仕様書

{{Specifications}}
Expand Down
2 changes: 0 additions & 2 deletions files/ja/web/api/element/setattributenodens/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,6 @@ alert(d2.attributes[1].value); // 返値: `utterleft'

なお、ノードを複製せずに設定しようとすると、Mozilla は NS_ERROR_DOM_INUSE_ATTRIBUTE_ERR "Attribute already in use" エラーを出します。DOM は Attr を再利用するにあたって複製することを要求しているからです(他のノードが移動できるのとは異なります)。

{{ DOMAttributeMethods() }}

## 仕様書

{{Specifications}}
Expand Down
2 changes: 0 additions & 2 deletions files/ja/web/api/element/setattributens/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@ d.setAttributeNS(

## メモ

{{ DOMAttributeMethods() }}

`setAttributeNS` は名前空間属性のための唯一のメソッドで、完全修飾名、つまり `"namespace:localname"` を期待します。

## 仕様書
Expand Down
2 changes: 0 additions & 2 deletions files/ja/web/api/element/toggleattribute/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,6 @@ button.addEventListener("click", () => {

{{ EmbedLiveSample('Examples', '300', '50') }}

{{DOMAttributeMethods}}

## 仕様書

{{Specifications}}
Expand Down
2 changes: 0 additions & 2 deletions files/ko/web/api/element/setattribute/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,6 @@ button.setAttribute("disabled", "");
- `disabled`와 같은 불리언 속성의 값을 설정하려면 아무 값으로든 설정할 수 있습니다.
빈 문자열 또는 속성의 이름이 권장되는 값입니다. 중요한 것은 속성이 존재하는 경우 **실제 값에 관계없이** 해당 값이 참으로 간주된다는 것입니다. 속성이 없다는 것은 해당 값이 `false`임을 의미합니다. `disabled` 속성의 값을 빈 문자열(`""`)로 설정하면 `disabled`를 `true`로 설정하여 버튼이 비활성화됩니다.

{{DOMAttributeMethods}}

## 명세서

{{Specifications}}
Expand Down
Loading