refactor(topics): 멀티 에이전트용 지식 재편 — _Common(공통 기본기) + Domain_* 구조
에이전트 8종(대화형/프로그래머 C·S/디자이너/설계자/기획자/QA/PD/PM)에게 [공통 기본 능력 + 롤별 Specialty] 2층으로 지식을 주입하기 위한 재분류. 문서 내용·포맷은 무수정, 폴더 이동만 (6,372개 문서 수 보존 확인). - Topic_Programming → Domain_Programming (내부 구조 보존) - Topic_Graphic → Domain_Design - Topic_Business → Domain_Product - Topic_General → Domain_General - _Common 신설: Math(구 Topic_Math_Specialty), Reasoning(구 General/From_Thinking & Reasoning), Reasoning_Creativity(구 General/From_창의성), Communication(Poetic_Blog_Writing + From_writing) - 타 도메인의 From_* 폴더는 유지 (출처 표기일 뿐, 이미 도메인에 맞게 분류된 문서) - 빈 폴더 정리 (memory/procedures) - 에이전트→폴더 매핑은 workspace의 .astra/agent-knowledge-map.json (9개 에이전트) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,205 @@
|
||||
---
|
||||
id: html-classes
|
||||
title: "HTML Classes"
|
||||
category: "Frontend"
|
||||
status: "draft"
|
||||
verification_status: "conceptual"
|
||||
canonical_id: ""
|
||||
aliases: ["class attribute", "HTML class", "CSS class selector", "getElementsByClassName", "multiple classes"]
|
||||
duplicate_of: ""
|
||||
source_trust_level: "B"
|
||||
confidence_score: 0.90
|
||||
created_at: 2026-06-23
|
||||
updated_at: 2026-06-23
|
||||
review_reason: ""
|
||||
merge_history: []
|
||||
tags: ["html", "web", "frontend", "w3schools", "css"]
|
||||
raw_sources: ["https://www.w3schools.com/html/html_classes.asp"]
|
||||
applied_in: []
|
||||
github_commit: ""
|
||||
---
|
||||
|
||||
# [[HTML Classes]]
|
||||
|
||||
## 🎯 한 줄 통찰 (One-line insight)
|
||||
The HTML `class` attribute assigns one or more class names to elements so CSS and JavaScript can select and act on a whole group of elements at once. [S1]
|
||||
|
||||
## 🧠 핵심 개념 (Core concepts)
|
||||
- **Purpose** — the `class` attribute is often used to point to a class name in a style sheet; it can also be used by JavaScript to access and manipulate elements with the specific class name. [S1]
|
||||
- **CSS selector** — in a stylesheet a class is referenced with a period (e.g. `.city`). [S1]
|
||||
- **Shared by many elements** — multiple HTML elements can share the same class. [S1]
|
||||
- **Multiple classes per element** — separate class names with a space (e.g. `class="city main"`); the element is styled according to all classes specified. [S1]
|
||||
- **Works across element types** — different HTML elements can point to the same class name. [S1]
|
||||
- **JavaScript access** — `getElementsByClassName()` returns all elements with a given class name. [S1]
|
||||
- **Usable anywhere** — the `class` attribute can be used on any HTML element, and the class name is case sensitive. [S1]
|
||||
|
||||
## 🧩 추출된 패턴 (Extracted patterns)
|
||||
- **Shared-style pattern** — give several elements the same class so one CSS rule styles them all. [S1]
|
||||
- **Multi-class pattern** — combine general and specific classes on one element (`class="city main"`). [S1]
|
||||
- **Inline-styling pattern** — apply a class to a `<span>` to style a fragment of text. [S1]
|
||||
- **JS-grouping pattern** — collect and manipulate all elements of a class with `getElementsByClassName()`. [S1]
|
||||
|
||||
## 📖 세부 내용 (Details)
|
||||
**The class Attribute.** The `class` attribute is often used to point to a class name in a style sheet. It can also be used by JavaScript to access and manipulate elements with the specific class name. [S1]
|
||||
|
||||
Basic class with CSS styling — three headings share the `city` class: [S1]
|
||||
```html
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<style>
|
||||
.city {
|
||||
background-color: tomato;
|
||||
color: white;
|
||||
padding: 10px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h2 class="city">London</h2>
|
||||
<p>London is the capital of England.</p>
|
||||
|
||||
<h2 class="city">Paris</h2>
|
||||
<p>Paris is the capital of France.</p>
|
||||
|
||||
<h2 class="city">Tokyo</h2>
|
||||
<p>Tokyo is the capital of Japan.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
```
|
||||
|
||||
**Using the class attribute on `<div>` elements.** [S1]
|
||||
```html
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<style>
|
||||
.city {
|
||||
background-color: tomato;
|
||||
color: white;
|
||||
border: 2px solid black;
|
||||
margin: 20px;
|
||||
padding: 20px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="city">
|
||||
<h2>London</h2>
|
||||
<p>London is the capital of England.</p>
|
||||
</div>
|
||||
|
||||
<div class="city">
|
||||
<h2>Paris</h2>
|
||||
<p>Paris is the capital of France.</p>
|
||||
</div>
|
||||
|
||||
<div class="city">
|
||||
<h2>Tokyo</h2>
|
||||
<p>Tokyo is the capital of Japan.</p>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
```
|
||||
|
||||
**The class attribute on inline (`<span>`) elements.** [S1]
|
||||
```html
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<style>
|
||||
.note {
|
||||
font-size: 120%;
|
||||
color: red;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>My <span class="note">Important</span> Heading</h1>
|
||||
<p>This is some <span class="note">important</span> text.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
```
|
||||
|
||||
**Multiple Classes.** HTML elements can belong to more than one class. To define multiple classes, separate the class names with a space, e.g. `<div class="city main">`. The element will be styled according to all the classes specified. [S1]
|
||||
```html
|
||||
<h2 class="city main">London</h2>
|
||||
<h2 class="city">Paris</h2>
|
||||
<h2 class="city">Tokyo</h2>
|
||||
```
|
||||
|
||||
**Different Elements Can Share Same Class.** Different HTML elements can point to the same class name. [S1]
|
||||
```html
|
||||
<h2 class="city">Paris</h2>
|
||||
<p class="city">Paris is the capital of France</p>
|
||||
```
|
||||
|
||||
**Using the class Attribute in JavaScript.** JavaScript can access elements with a specific class name by using the `getElementsByClassName()` method. [S1]
|
||||
```javascript
|
||||
<script>
|
||||
function myFunction() {
|
||||
var x = document.getElementsByClassName("city");
|
||||
for (var i = 0; i < x.length; i++) {
|
||||
x[i].style.display = "none";
|
||||
}
|
||||
}
|
||||
</script>
|
||||
```
|
||||
|
||||
> **Tip:** The `class` attribute can be used on **any** HTML element. [S1]
|
||||
> **Note:** The class name is case sensitive! [S1]
|
||||
|
||||
**Chapter Summary.** [S1]
|
||||
- The HTML `class` attribute specifies one or more class names for an element.
|
||||
- Classes are used by CSS and JavaScript to select and access specific elements.
|
||||
- The `class` attribute can be used on any HTML element.
|
||||
- The class name is case sensitive.
|
||||
- Different HTML elements can point to the same class name.
|
||||
- JavaScript can access elements with a specific class name with the `getElementsByClassName()` method.
|
||||
|
||||
## 🛠️ 적용 사례 (Applied in summary)
|
||||
The shared `city` class (across headings, divs, and paragraphs), the multi-class `city main` heading, and the `getElementsByClassName("city")` hide-function are the canonical applied examples. No external project/commit applications found in the source.
|
||||
|
||||
## 💻 코드 패턴 (Code patterns)
|
||||
Define and apply a class (HTML + CSS):
|
||||
```html
|
||||
<style>
|
||||
.city { color: white; }
|
||||
</style>
|
||||
<h2 class="city">London</h2>
|
||||
```
|
||||
Multiple classes (HTML):
|
||||
```html
|
||||
<div class="city main">...</div>
|
||||
```
|
||||
Select by class in JavaScript:
|
||||
```javascript
|
||||
var x = document.getElementsByClassName("city");
|
||||
```
|
||||
|
||||
## ⚖️ 모순 및 업데이트 (Contradictions & updates)
|
||||
No contradictions found in the source. [S1]
|
||||
|
||||
## ✅ 검증 상태 및 신뢰도
|
||||
- **상태:** draft
|
||||
- **검증 단계:** conceptual (실제 적용 사례 발견 시 applied/validated로 승격 가능)
|
||||
- **출처 신뢰도:** B (W3Schools — widely used educational reference, not a primary standards body)
|
||||
- **신뢰 점수:** 0.90
|
||||
- **중복 검사 결과:** 신규 생성 (New discovery)
|
||||
|
||||
## 🔗 지식 그래프 (Knowledge Graph)
|
||||
- **상위/루트:** [[HTML Tutorial]]
|
||||
- **관련 개념:** [[HTML Id]], [[HTML Div]], [[HTML Block and Inline]], [[HTML JavaScript]]
|
||||
- **참조 맥락:** Referenced whenever a group of elements must share styling or be selected together by CSS or JavaScript.
|
||||
|
||||
## 📚 출처 (Sources)
|
||||
- [S1] W3Schools — HTML Classes — https://www.w3schools.com/html/html_classes.asp
|
||||
|
||||
## 📝 변경 이력 (Change history)
|
||||
- 2026-06-23: Initial draft synthesized from the W3Schools "HTML Classes" page (Astra wiki-curation, P-Reinforce v3.1 format).
|
||||
Reference in New Issue
Block a user