@iyulab/chat-components 0.11.9 → 0.12.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +63 -0
- package/README.md +16 -0
- package/dist/_virtual/{_@oxc-project_runtime@0.148.0 → _@oxc-project_runtime@0.149.0}/helpers/esm/decorate.js +1 -1
- package/dist/_virtual/{_@oxc-project_runtime@0.148.0 → _@oxc-project_runtime@0.149.0}/helpers/esm/decorateMetadata.js +1 -1
- package/dist/components/blocks/UCodeBlock.js +2 -2
- package/dist/components/blocks/UElementBlock.js +2 -2
- package/dist/components/blocks/UFileBlock.d.ts +2 -0
- package/dist/components/blocks/UFileBlock.js +21 -18
- package/dist/components/blocks/UFileBlock.styles.js +24 -4
- package/dist/components/blocks/UMarkedBlock.js +3 -3
- package/dist/components/blocks/URefBlock.js +2 -2
- package/dist/components/blocks/UTableBlock.js +13 -9
- package/dist/components/blocks/UTableBlock.styles.js +30 -3
- package/dist/components/blocks/UTextBlock.js +2 -2
- package/dist/components/message/UMessage.js +2 -2
- package/dist/components/prompt/UPrompt.js +2 -2
- package/dist/components/references/URefCard.js +2 -2
- package/dist/components/references/URefCardGroup.js +2 -2
- package/dist/components/references/URefCardGroup.styles.js +5 -0
- package/dist/components/references/URefTag.js +2 -2
- package/dist/components-extra/UChartBlock.js +2 -2
- package/dist/components-extra/UChartBlock.styles.js +15 -1
- package/dist/components-extra/UImagesBlock.js +9 -6
- package/dist/components-extra/UImagesBlock.styles.js +13 -0
- package/dist/components-extra/UMapBlock.js +2 -2
- package/dist/components-extra/UMapBlock.styles.js +11 -1
- package/dist/components-extra/UVideoBlock.js +2 -2
- package/dist/node_modules/katex/dist/katex.js +26367 -0
- package/dist/utilities/markedKatex.d.ts +10 -0
- package/dist/utilities/markedKatex.js +106 -0
- package/dist/utilities/messages.d.ts +1 -1
- package/dist/utilities/messages.js +6 -2
- package/package.json +10 -11
- package/skills/iyulab-chat-components/references/components/chart-block.md +17 -0
- package/skills/iyulab-chat-components/references/components/code-block.md +12 -0
- package/skills/iyulab-chat-components/references/components/images-block.md +10 -0
- package/skills/iyulab-chat-components/references/components/map-block.md +15 -0
- package/skills/iyulab-chat-components/references/components/marked-block.md +8 -0
- package/skills/iyulab-chat-components/references/components/message.md +8 -0
- package/skills/iyulab-chat-components/references/components/prompt.md +11 -0
- package/skills/iyulab-chat-components/references/components/table-block.md +15 -0
- package/skills/iyulab-chat-components/references/components/video-block.md +10 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,68 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.12.1] - 2026-09-15
|
|
4
|
+
|
|
5
|
+
### Fixed
|
|
6
|
+
|
|
7
|
+
- **`u-table-block` columns could not be sorted from the keyboard.** The sortable header cell only
|
|
8
|
+
listened for clicks, took no focus and exposed no sort state. Each header now holds a button that
|
|
9
|
+
fills the cell (the pointer target is unchanged), Enter or Space toggles the sort, and the header
|
|
10
|
+
carries `aria-sort`. The button is exposed as the `sort-button` part.
|
|
11
|
+
- **`u-images-block` thumbnails and `u-file-block` previews could not be opened from the
|
|
12
|
+
keyboard.** Both were click-only `div`s. A thumbnail is now a button (named by the image's `alt`,
|
|
13
|
+
or "Open image N"); a previewable file card's body is a button named "Preview <name>", exposed as
|
|
14
|
+
the `card-main` part, with the remove button kept outside it. Cards that cannot be previewed no
|
|
15
|
+
longer show a pointer cursor or hover state. New locale keys: `openImage`, `previewFile`.
|
|
16
|
+
|
|
17
|
+
## [0.12.0] - 2026-09-10
|
|
18
|
+
|
|
19
|
+
### Changed
|
|
20
|
+
|
|
21
|
+
- **`@iyulab/components` moved from `dependencies` to `peerDependencies`.** It owns
|
|
22
|
+
process-global state — the custom element registry and module-level singletons — so two
|
|
23
|
+
copies in one install tree split that state with no error raised. Consumers already
|
|
24
|
+
installing `@iyulab/components` are unaffected; the declaration now says that this package
|
|
25
|
+
uses the copy they installed rather than fetching one of its own.
|
|
26
|
+
|
|
27
|
+
- **The KaTeX `marked` extension is now owned in-package**, replacing the third-party
|
|
28
|
+
`marked-katex-extension`, and `katex` moves to `^0.18.7`. No published version of that
|
|
29
|
+
extension satisfied both a `katex <0.19` peer range and compiled `.d.ts`/`.js` output, so
|
|
30
|
+
depending on it pinned `katex` to 0.17 and required an install-time override that does not
|
|
31
|
+
reach consumers of the published package at all. A browser regression pins the render
|
|
32
|
+
contract first — delimiter parsing, `displayMode` versus block placement, and the inputs that
|
|
33
|
+
must *not* be treated as maths (currency pairs, newlines inside inline maths) — so the
|
|
34
|
+
replacement is demonstrably equivalent rather than merely plausible. The `.katex` coupling
|
|
35
|
+
point is unchanged across both minors.
|
|
36
|
+
|
|
37
|
+
### Fixed
|
|
38
|
+
|
|
39
|
+
- **A `max-height` on `u-chart-block` or `u-map-block` now actually constrains the block.** Both
|
|
40
|
+
laid their inner box out independently of the host — the chart viewport kept its content height
|
|
41
|
+
and the map's frame kept a flat 300px — so a height set on the component shrank the component
|
|
42
|
+
without shrinking what was inside it, and the surplus was clipped away by the block's own
|
|
43
|
+
`overflow: hidden` with no scrollbar left to reach it. Measured at 600px wide against a 120px
|
|
44
|
+
host: 248px of the chart and 180px of the map were unreachable. The toolbar and the chart area
|
|
45
|
+
(and the map frame) now divide the component's height by layout, so a constraint on the component
|
|
46
|
+
reaches them. The map's 300px is unchanged as the height you get when nothing constrains it.
|
|
47
|
+
- `u-images-block`, `u-video-block` and `u-message` deliberately do **not** follow such a
|
|
48
|
+
constraint: the first two derive height from width through `aspect-ratio`, and squeezing a
|
|
49
|
+
message bubble hides content that the conversation itself already scrolls. They overflow
|
|
50
|
+
visibly rather than clipping, and a browser regression now pins that distinction — not
|
|
51
|
+
following a constraint and silently clipping are different things.
|
|
52
|
+
|
|
53
|
+
- **A `max-height` on `u-table-block` now actually constrains the table.** The scrolling table area
|
|
54
|
+
carried a fixed 480px maximum of its own, so a height set on the component shrank the component
|
|
55
|
+
without shrinking the table inside it: the surplus was clipped away by the block's own
|
|
56
|
+
`overflow: hidden` with no scrollbar left to reach it. Measured with 40 rows and a 200px
|
|
57
|
+
`max-height`, 330px of rows became unreachable. The header row and the table area now divide the
|
|
58
|
+
component's height by layout, so a constraint on the component reaches the table and the rows
|
|
59
|
+
stay reachable by scrolling. The 480px default is unchanged: left unconstrained, a long table
|
|
60
|
+
still stops there rather than swallowing the conversation.
|
|
61
|
+
|
|
62
|
+
- **The reference carousel's navigation buttons presented a 16×16 pointer target**, below the
|
|
63
|
+
24×24 CSS px minimum (WCAG 2.2 SC 2.5.8). Nothing visible changes: the buttons carry no
|
|
64
|
+
border or background, and the icon size is still set by `font-size`.
|
|
65
|
+
|
|
3
66
|
## [0.11.9] - 2026-09-08
|
|
4
67
|
|
|
5
68
|
### Fixed
|
package/README.md
CHANGED
|
@@ -112,6 +112,22 @@ markedBlock.value = llmResponse;
|
|
|
112
112
|
|
|
113
113
|
---
|
|
114
114
|
|
|
115
|
+
## Accessibility
|
|
116
|
+
|
|
117
|
+
The baseline is **WCAG 2.2**. The table lists what this package **measures in tests** — it is not a
|
|
118
|
+
conformance claim for the success criteria it does not list.
|
|
119
|
+
|
|
120
|
+
| Success criterion | Guarantee | Measured by |
|
|
121
|
+
|---|---|---|
|
|
122
|
+
| SC 2.5.8 Target Size (Minimum) | Every pointer target inside the registered blocks (`.` and `./extra` entries) is at least 24×24 CSS px or meets the spacing exception (24px between centers), and is actually hit at that position | `tests/browser/target-size.browser.test.ts` (real Chromium) |
|
|
123
|
+
| SC 2.1.1 Keyboard (pointer-cursor check) | Nothing a block renders shows a pointer cursor without being an interactive element — table sort headers, image thumbnails and previewable file cards are buttons | `tests/browser/target-size.browser.test.ts` · `tests/browser/table-block-sort-keyboard.browser.test.ts` |
|
|
124
|
+
|
|
125
|
+
`u-ref-tag` uses the SC's **inline exception** — it is a citation badge set inside a sentence, where
|
|
126
|
+
growing it to 24px would push the line height. It is still measured and reported.
|
|
127
|
+
|
|
128
|
+
Color contrast comes from the `@iyulab/components` tokens this package renders with — see that
|
|
129
|
+
package's Accessibility section.
|
|
130
|
+
|
|
115
131
|
## Documentation
|
|
116
132
|
|
|
117
133
|
| File | Description |
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
//#region \0@oxc-project+runtime@0.
|
|
1
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/decorate.js
|
|
2
2
|
function __decorate(decorators, target, key, desc) {
|
|
3
3
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
4
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
//#region \0@oxc-project+runtime@0.
|
|
1
|
+
//#region \0@oxc-project+runtime@0.149.0/helpers/esm/decorateMetadata.js
|
|
2
2
|
function __decorateMetadata(k, v) {
|
|
3
3
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
4
4
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { styles } from "./UCodeBlock.styles.js";
|
|
2
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
3
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
3
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
4
4
|
import { html } from "lit";
|
|
5
5
|
import { customElement, property } from "lit/decorators.js";
|
|
6
6
|
import { unsafeHTML } from "lit/directives/unsafe-html.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { UDataElement } from "../UDataElement.js";
|
|
4
4
|
import { styles } from "./UElementBlock.styles.js";
|
|
5
5
|
import { html, nothing } from "lit";
|
|
@@ -25,6 +25,8 @@ export declare class UFileBlock extends UElement {
|
|
|
25
25
|
/** 클릭 시 오버레이로 미리볼 수 있는 타입인지 여부 */
|
|
26
26
|
private get previewable();
|
|
27
27
|
render(): import('lit-html').TemplateResult<1>;
|
|
28
|
+
/** 썸네일과 이름·메타 — 버튼 안에 들어가므로 구문 콘텐츠(`span`)로만 짓는다. */
|
|
29
|
+
private renderCardMain;
|
|
28
30
|
private handleCardClick;
|
|
29
31
|
private closePreview;
|
|
30
32
|
private handleKeyDown;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { messages } from "../../utilities/messages.js";
|
|
4
4
|
import { styles } from "./UFileBlock.styles.js";
|
|
5
5
|
import { html, nothing } from "lit";
|
|
@@ -52,22 +52,10 @@ var UFileBlock = class UFileBlock extends UElement {
|
|
|
52
52
|
}
|
|
53
53
|
render() {
|
|
54
54
|
return html`
|
|
55
|
-
<div class="card"
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
<div class="info">
|
|
61
|
-
<div class="name">${this.name}</div>
|
|
62
|
-
<div class="meta">
|
|
63
|
-
<span class="type">
|
|
64
|
-
${this.resolveExt(this.name, this.type)}
|
|
65
|
-
</span>
|
|
66
|
-
<span class="size">
|
|
67
|
-
${this.formatSize(this.size || 0)}
|
|
68
|
-
</span>
|
|
69
|
-
</div>
|
|
70
|
-
</div>
|
|
55
|
+
<div class="card" ?previewable=${this.previewable}>
|
|
56
|
+
${this.previewable ? html`<button type="button" class="card-main" part="card-main"
|
|
57
|
+
aria-label=${messages.text("previewFile", { name: this.name || "" })}
|
|
58
|
+
@click=${this.handleCardClick}>${this.renderCardMain()}</button>` : html`<span class="card-main">${this.renderCardMain()}</span>`}
|
|
71
59
|
|
|
72
60
|
<u-button class="remove-btn"
|
|
73
61
|
?hidden=${!this.removable}
|
|
@@ -91,6 +79,21 @@ var UFileBlock = class UFileBlock extends UElement {
|
|
|
91
79
|
</div>
|
|
92
80
|
</div>
|
|
93
81
|
` : nothing}
|
|
82
|
+
`;
|
|
83
|
+
}
|
|
84
|
+
/** 썸네일과 이름·메타 — 버튼 안에 들어가므로 구문 콘텐츠(`span`)로만 짓는다. */
|
|
85
|
+
renderCardMain() {
|
|
86
|
+
return html`
|
|
87
|
+
<span class="thumbnail">
|
|
88
|
+
${this.isImage ? html`<img src=${this.url} alt=${this.name || ""} loading="lazy" />` : this.isVideo ? html`<video src="${this.url}#t=0.1" preload="metadata" muted playsinline></video>` : html`<u-icon lib="internal-chat" name=${this.resolveIcon(this.type)}></u-icon>`}
|
|
89
|
+
</span>
|
|
90
|
+
<span class="info">
|
|
91
|
+
<span class="name">${this.name}</span>
|
|
92
|
+
<span class="meta">
|
|
93
|
+
<span class="type">${this.resolveExt(this.name, this.type)}</span>
|
|
94
|
+
<span class="size">${this.formatSize(this.size || 0)}</span>
|
|
95
|
+
</span>
|
|
96
|
+
</span>
|
|
94
97
|
`;
|
|
95
98
|
}
|
|
96
99
|
/** MIME 타입 → Tabler Icon 이름 */
|
|
@@ -15,20 +15,39 @@ var styles = css`
|
|
|
15
15
|
flex-direction: row;
|
|
16
16
|
align-items: center;
|
|
17
17
|
min-width: 0;
|
|
18
|
-
gap: 10px;
|
|
19
|
-
padding: 8px 10px;
|
|
20
18
|
border: 1px solid var(--u-border-color);
|
|
21
19
|
border-radius: 8px;
|
|
22
20
|
background-color: var(--u-neutral-50);
|
|
23
21
|
overflow: visible;
|
|
24
|
-
cursor: pointer;
|
|
25
22
|
transition: background-color 0.12s ease, border-color 0.12s ease;
|
|
26
23
|
}
|
|
27
|
-
.card:hover {
|
|
24
|
+
.card[previewable]:hover {
|
|
28
25
|
background-color: var(--u-neutral-100);
|
|
29
26
|
border-color: var(--u-border-color-strong);
|
|
30
27
|
}
|
|
31
28
|
|
|
29
|
+
/* 카드 본문 — 미리볼 수 있으면 버튼, 아니면 span. 둘 다 같은 배치를 갖는다.
|
|
30
|
+
카드의 여백을 본문이 가져, 누를 면이 종전(카드 전체)과 같다 — 제거 버튼은 절대 배치라 흐름에 없다. */
|
|
31
|
+
.card-main {
|
|
32
|
+
all: unset;
|
|
33
|
+
box-sizing: border-box;
|
|
34
|
+
display: flex;
|
|
35
|
+
flex-direction: row;
|
|
36
|
+
align-items: center;
|
|
37
|
+
flex: 1;
|
|
38
|
+
min-width: 0;
|
|
39
|
+
gap: 10px;
|
|
40
|
+
padding: 8px 10px;
|
|
41
|
+
border-radius: 8px;
|
|
42
|
+
}
|
|
43
|
+
button.card-main {
|
|
44
|
+
cursor: pointer;
|
|
45
|
+
}
|
|
46
|
+
button.card-main:focus-visible {
|
|
47
|
+
outline: 2px solid var(--u-primary-color, #1976D2);
|
|
48
|
+
outline-offset: 1px;
|
|
49
|
+
}
|
|
50
|
+
|
|
32
51
|
.thumbnail {
|
|
33
52
|
position: relative;
|
|
34
53
|
flex-shrink: 0;
|
|
@@ -62,6 +81,7 @@ var styles = css`
|
|
|
62
81
|
}
|
|
63
82
|
|
|
64
83
|
.name {
|
|
84
|
+
display: block;
|
|
65
85
|
font-size: 13px;
|
|
66
86
|
font-weight: 500;
|
|
67
87
|
color: var(--u-txt-color-strong);
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import "./UCodeBlock.js";
|
|
4
4
|
import { escapeHtmlAttr, escapeHtmlHref, escapeHtmlText, stripZeroWidth } from "../../utilities/sanitizers.js";
|
|
5
5
|
import { HtmlBuilder } from "../../utilities/HtmlBuilder.js";
|
|
6
6
|
import { UElementBlock } from "./UElementBlock.js";
|
|
7
|
+
import { markedKatex } from "../../utilities/markedKatex.js";
|
|
7
8
|
import "../references/URefTag.js";
|
|
8
9
|
import { URefCard } from "../references/URefCard.js";
|
|
9
10
|
import "../references/URefCardGroup.js";
|
|
@@ -15,7 +16,6 @@ import { customElement, property, state } from "lit/decorators.js";
|
|
|
15
16
|
import { unsafeHTML } from "lit/directives/unsafe-html.js";
|
|
16
17
|
import { UElement } from "@iyulab/components/dist/components/UElement.js";
|
|
17
18
|
import { Marked, Parser } from "marked";
|
|
18
|
-
import markedKatex from "marked-katex-extension";
|
|
19
19
|
//#region src/components/blocks/UMarkedBlock.ts
|
|
20
20
|
var UMarkedBlock = class UMarkedBlock extends UElement {
|
|
21
21
|
constructor(..._args) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import "../references/URefCard.js";
|
|
4
4
|
import { styles } from "./URefBlock.styles.js";
|
|
5
5
|
import { html } from "lit";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { UDataElement } from "../UDataElement.js";
|
|
4
4
|
import { messages } from "../../utilities/messages.js";
|
|
5
5
|
import { styles } from "./UTableBlock.styles.js";
|
|
@@ -69,14 +69,18 @@ var UTableBlock = class UTableBlock extends UDataElement {
|
|
|
69
69
|
<th
|
|
70
70
|
?active=${isActive}
|
|
71
71
|
align=${h.align ?? "left"}
|
|
72
|
-
|
|
72
|
+
aria-sort=${isActive ? this.sort.dir === "asc" ? "ascending" : "descending" : "none"}
|
|
73
73
|
>
|
|
74
|
-
|
|
75
|
-
<
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
74
|
+
<!-- 정렬은 머리 칸 전체를 채우는 버튼이다 — 클릭만 받는 th 는 키보드로 닿지 않았다. -->
|
|
75
|
+
<button type="button" class="sort-button" part="sort-button"
|
|
76
|
+
@click=${() => this.handleSortColumn(i)}>
|
|
77
|
+
${unsafeHTML(h.text)}
|
|
78
|
+
<u-icon
|
|
79
|
+
class="sort-icon"
|
|
80
|
+
lib="internal-chat"
|
|
81
|
+
name=${isActive ? this.sort.dir === "asc" ? "sort-ascending-letters" : "sort-descending-letters" : "arrows-sort"}
|
|
82
|
+
></u-icon>
|
|
83
|
+
</button>
|
|
80
84
|
</th>
|
|
81
85
|
`;
|
|
82
86
|
})}
|
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
import { css } from "lit";
|
|
2
2
|
//#region src/components/blocks/UTableBlock.styles.ts
|
|
3
3
|
var styles = css`
|
|
4
|
+
/* 세로 flex 인 이유: 소비자가 호스트에 높이·max-height 를 주면 그 제약이 .table-wrapper 까지
|
|
5
|
+
닿아야 한다. 종전에는 display:block + 래퍼의 max-height:480px 리터럴이라, 호스트를 200px 로
|
|
6
|
+
줄이면 래퍼가 480 을 유지해 330px 이 overflow:hidden 에 잘리고 스크롤바도 없었다. */
|
|
4
7
|
:host {
|
|
5
|
-
display:
|
|
8
|
+
display: flex;
|
|
9
|
+
flex-direction: column;
|
|
6
10
|
width: 100%;
|
|
7
11
|
margin: 8px 0;
|
|
8
12
|
border: 1px solid var(--u-border-color);
|
|
@@ -11,6 +15,7 @@ var styles = css`
|
|
|
11
15
|
}
|
|
12
16
|
|
|
13
17
|
.toolbar {
|
|
18
|
+
flex: none;
|
|
14
19
|
display: flex;
|
|
15
20
|
align-items: center;
|
|
16
21
|
justify-content: space-between;
|
|
@@ -52,8 +57,12 @@ var styles = css`
|
|
|
52
57
|
}
|
|
53
58
|
|
|
54
59
|
.table-wrapper {
|
|
60
|
+
flex: 1 1 auto;
|
|
61
|
+
min-height: 0;
|
|
55
62
|
overflow-x: auto;
|
|
56
63
|
overflow-y: auto;
|
|
64
|
+
/* 제약이 없을 때의 기본 상한 — 채팅 스트림에서 긴 표가 화면을 삼키지 않게 한다.
|
|
65
|
+
«최대» 이므로 위 flex 수축을 막지 않는다(호스트 제약이 이긴다). */
|
|
57
66
|
max-height: 480px;
|
|
58
67
|
width: 100%;
|
|
59
68
|
}
|
|
@@ -74,14 +83,32 @@ var styles = css`
|
|
|
74
83
|
}
|
|
75
84
|
|
|
76
85
|
th {
|
|
77
|
-
padding:
|
|
86
|
+
padding: 0;
|
|
78
87
|
font-weight: 600;
|
|
79
88
|
text-align: left;
|
|
80
89
|
border-bottom: 2px solid var(--u-border-color);
|
|
81
90
|
white-space: nowrap;
|
|
82
|
-
cursor: pointer;
|
|
83
91
|
user-select: none;
|
|
84
92
|
}
|
|
93
|
+
|
|
94
|
+
/* 칸 전체가 누를 면이다 — 여백을 th 가 아니라 버튼이 갖는다. */
|
|
95
|
+
.sort-button {
|
|
96
|
+
all: unset;
|
|
97
|
+
box-sizing: border-box;
|
|
98
|
+
display: flex;
|
|
99
|
+
align-items: center;
|
|
100
|
+
inline-size: 100%;
|
|
101
|
+
padding: 8px 12px;
|
|
102
|
+
font: inherit;
|
|
103
|
+
color: inherit;
|
|
104
|
+
cursor: pointer;
|
|
105
|
+
}
|
|
106
|
+
th[align="center"] .sort-button { justify-content: center; }
|
|
107
|
+
th[align="right"] .sort-button { justify-content: flex-end; }
|
|
108
|
+
.sort-button:focus-visible {
|
|
109
|
+
outline: 2px solid var(--u-primary-color, #1976D2);
|
|
110
|
+
outline-offset: -2px;
|
|
111
|
+
}
|
|
85
112
|
th:hover {
|
|
86
113
|
background-color: var(--u-neutral-200);
|
|
87
114
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { styles } from "./UTextBlock.styles.js";
|
|
4
4
|
import { html } from "lit";
|
|
5
5
|
import { customElement, property, query } from "lit/decorators.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { styles } from "./UMessage.styles.js";
|
|
4
4
|
import { html } from "lit";
|
|
5
5
|
import { customElement, property } from "lit/decorators.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { messages } from "../../utilities/messages.js";
|
|
4
4
|
import "../blocks/UFileBlock.js";
|
|
5
5
|
import { styles } from "./UPrompt.styles.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { UDataElement } from "../UDataElement.js";
|
|
4
4
|
import { styles } from "./URefCard.styles.js";
|
|
5
5
|
import { html } from "lit";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { messages } from "../../utilities/messages.js";
|
|
4
4
|
import { URefCard } from "./URefCard.js";
|
|
5
5
|
import { styles } from "./URefCardGroup.styles.js";
|
|
@@ -33,6 +33,11 @@ var styles = css`
|
|
|
33
33
|
color: inherit;
|
|
34
34
|
font-size: 16px;
|
|
35
35
|
cursor: pointer;
|
|
36
|
+
/* WCAG 2.2 SC 2.5.8 — 실측 16x16 이라 포인터 타깃이 모자랐다. 배경도 테두리도 없는
|
|
37
|
+
아이콘 버튼이라 상자를 키워도 **보이는 것은 그대로**다: 아이콘 치수는 위 font-size 가
|
|
38
|
+
정하고 여기서 늘어나는 것은 잡히는 영역뿐이다. */
|
|
39
|
+
min-inline-size: 24px;
|
|
40
|
+
min-block-size: 24px;
|
|
36
41
|
}
|
|
37
42
|
.nav-button:hover u-icon {
|
|
38
43
|
opacity: 0.6;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { styles } from "./URefTag.styles.js";
|
|
4
4
|
import { html } from "lit";
|
|
5
5
|
import { customElement, property } from "lit/decorators.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { messages } from "../utilities/messages.js";
|
|
4
4
|
import { styles } from "./UChartBlock.styles.js";
|
|
5
5
|
import { html, nothing } from "lit";
|
|
@@ -1,9 +1,16 @@
|
|
|
1
1
|
import { css } from "lit";
|
|
2
2
|
//#region src/components-extra/UChartBlock.styles.ts
|
|
3
3
|
var styles = css`
|
|
4
|
+
/* 🔴호스트를 «세로 flex» 로 둔다 — display:block 이면 사슬이 여기서 끊긴다.
|
|
5
|
+
내부는 툴바(고정) + 뷰포트(가변) 구조인데, 호스트가 block 이면 그 둘이 호스트의
|
|
6
|
+
max-height 에 참여하지 못해 호스트만 줄고 뷰포트는 제 높이를 유지한다.
|
|
7
|
+
그러면 overflow:hidden 에 잘리고 스크롤도 없어 도달할 수 없다 — 실측(자연 368):
|
|
8
|
+
호스트 120 에서 뷰포트가 316 그대로였고 248px 이 잘렸다.
|
|
9
|
+
계약은 tests/browser/extra-block-size-model.browser.test.ts 가 고정한다. */
|
|
4
10
|
:host {
|
|
5
11
|
margin: 0.75em auto;
|
|
6
|
-
display:
|
|
12
|
+
display: flex;
|
|
13
|
+
flex-direction: column;
|
|
7
14
|
width: 100%;
|
|
8
15
|
background: var(--u-bg-color);
|
|
9
16
|
border: 1px solid var(--u-border-color);
|
|
@@ -19,6 +26,8 @@ var styles = css`
|
|
|
19
26
|
background-color: var(--u-neutral-100);
|
|
20
27
|
border-bottom: 1px solid var(--u-border-color);
|
|
21
28
|
gap: 8px;
|
|
29
|
+
/* 툴바는 줄어들지 않는다 — 제약이 들어오면 차트가 양보한다. */
|
|
30
|
+
flex: none;
|
|
22
31
|
}
|
|
23
32
|
|
|
24
33
|
.toolbar-left {
|
|
@@ -42,6 +51,11 @@ var styles = css`
|
|
|
42
51
|
.viewport {
|
|
43
52
|
position: relative;
|
|
44
53
|
padding: 1em;
|
|
54
|
+
/* ⚠min-height:0 이 없으면 flex 아이템의 기본 min-height:auto 가 «줄어들지 않음» 이라
|
|
55
|
+
위 사슬이 그대로 무효가 된다(이 리포가 여러 번 밟은 자리). */
|
|
56
|
+
flex: 1 1 auto;
|
|
57
|
+
min-height: 0;
|
|
58
|
+
overflow: auto;
|
|
45
59
|
}
|
|
46
60
|
|
|
47
61
|
.viewport:fullscreen {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { messages } from "../utilities/messages.js";
|
|
4
4
|
import { styles } from "./UImagesBlock.styles.js";
|
|
5
5
|
import { html, nothing } from "lit";
|
|
@@ -65,18 +65,21 @@ var UImagesBlock = class UImagesBlock extends UElement {
|
|
|
65
65
|
.gap=${8}
|
|
66
66
|
>
|
|
67
67
|
${repeat(this.items, (item, i) => html`
|
|
68
|
-
|
|
68
|
+
<!-- 썸네일은 라이트박스를 여는 버튼이다 — 클릭만 받는 div 는 키보드로 열 수 없었다.
|
|
69
|
+
대체 텍스트가 있으면 그것이 이름이고, 없으면 «이미지 N 열기» 로 이름을 준다. -->
|
|
70
|
+
<button type="button" class="slide"
|
|
71
|
+
aria-label=${item.alt ? nothing : messages.text("openImage", { index: i + 1 })}
|
|
69
72
|
@click=${() => this.open(i)}>
|
|
70
73
|
<img
|
|
71
74
|
src=${item.src}
|
|
72
75
|
alt=${item.alt || ""}
|
|
73
76
|
loading="lazy"
|
|
74
77
|
/>
|
|
75
|
-
<
|
|
78
|
+
<span class="caption"
|
|
76
79
|
?hidden=${!item.caption}>
|
|
77
80
|
${item.caption}
|
|
78
|
-
</
|
|
79
|
-
</
|
|
81
|
+
</span>
|
|
82
|
+
</button>
|
|
80
83
|
`)}
|
|
81
84
|
</u-carousel>
|
|
82
85
|
|
|
@@ -9,11 +9,24 @@ var styles = css`
|
|
|
9
9
|
|
|
10
10
|
.slide {
|
|
11
11
|
position: relative;
|
|
12
|
+
display: block;
|
|
13
|
+
inline-size: 100%;
|
|
14
|
+
margin: 0;
|
|
15
|
+
padding: 0;
|
|
16
|
+
border: 0;
|
|
17
|
+
background: none;
|
|
18
|
+
font: inherit;
|
|
19
|
+
color: inherit;
|
|
20
|
+
text-align: start;
|
|
12
21
|
border-radius: 10px;
|
|
13
22
|
overflow: hidden;
|
|
14
23
|
cursor: pointer;
|
|
15
24
|
aspect-ratio: 4 / 3;
|
|
16
25
|
}
|
|
26
|
+
.slide:focus-visible {
|
|
27
|
+
outline: 2px solid var(--u-primary-color, #1976D2);
|
|
28
|
+
outline-offset: 2px;
|
|
29
|
+
}
|
|
17
30
|
.slide img {
|
|
18
31
|
display: block;
|
|
19
32
|
width: 100%;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { styles } from "./UMapBlock.styles.js";
|
|
4
4
|
import { html, nothing } from "lit";
|
|
5
5
|
import { customElement, property } from "lit/decorators.js";
|
|
@@ -1,9 +1,14 @@
|
|
|
1
1
|
import { css } from "lit";
|
|
2
2
|
//#region src/components-extra/UMapBlock.styles.ts
|
|
3
3
|
var styles = css`
|
|
4
|
+
/* 🔴호스트를 «세로 flex» 로 둔다 — display:block 이면 아래 iframe 의 300px 이
|
|
5
|
+
호스트의 max-height 에 참여하지 못한다. 실측: 호스트 120 에서 지도가 300 그대로였고
|
|
6
|
+
180px 이 overflow:hidden 에 잘렸다(스크롤도 없어 도달 불가).
|
|
7
|
+
계약은 tests/browser/extra-block-size-model.browser.test.ts 가 고정한다. */
|
|
4
8
|
:host {
|
|
5
9
|
position: relative;
|
|
6
|
-
display:
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-direction: column;
|
|
7
12
|
width: 100%;
|
|
8
13
|
border-radius: 8px;
|
|
9
14
|
overflow: hidden;
|
|
@@ -12,7 +17,12 @@ var styles = css`
|
|
|
12
17
|
|
|
13
18
|
iframe {
|
|
14
19
|
width: 100%;
|
|
20
|
+
/* ⚠이 300px 은 «고정» 이 아니라 «제약이 없을 때의 기본» 이다 — flex-basis 가 auto 라
|
|
21
|
+
선언이 그대로 기본값이 되고, 호스트가 제약을 주면 flex 가 그것을 이긴다.
|
|
22
|
+
(이름과 값을 유지하고 의미만 재정의한 것은 u-widgets 의 차트 높이와 같은 처리다.) */
|
|
15
23
|
height: 300px;
|
|
24
|
+
flex: 1 1 auto;
|
|
25
|
+
min-height: 0;
|
|
16
26
|
display: block;
|
|
17
27
|
border: none;
|
|
18
28
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import __decorateMetadata from "../_virtual/_@oxc-project_runtime@0.
|
|
2
|
-
import __decorate from "../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import __decorateMetadata from "../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorateMetadata.js";
|
|
2
|
+
import __decorate from "../_virtual/_@oxc-project_runtime@0.149.0/helpers/esm/decorate.js";
|
|
3
3
|
import { styles } from "./UVideoBlock.styles.js";
|
|
4
4
|
import { html, nothing } from "lit";
|
|
5
5
|
import { customElement, property } from "lit/decorators.js";
|