@things-factory/figure-ui 10.1.192 → 10.1.194
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/client/pages/figure-list-page.ts +27 -40
- package/client/pages/figure-public-list-page.ts +21 -0
- package/client/route.ts +4 -0
- package/client/viewparts/figure-detail-dock.ts +5 -2
- package/dist-client/pages/figure-list-page.d.ts +6 -3
- package/dist-client/pages/figure-list-page.js +25 -42
- package/dist-client/pages/figure-list-page.js.map +1 -1
- package/dist-client/pages/figure-public-list-page.d.ts +16 -0
- package/dist-client/pages/figure-public-list-page.js +21 -0
- package/dist-client/pages/figure-public-list-page.js.map +1 -0
- package/dist-client/route.d.ts +1 -1
- package/dist-client/route.js +3 -0
- package/dist-client/route.js.map +1 -1
- package/dist-client/tsconfig.tsbuildinfo +1 -1
- package/dist-client/viewparts/figure-detail-dock.d.ts +1 -0
- package/dist-client/viewparts/figure-detail-dock.js +4 -2
- package/dist-client/viewparts/figure-detail-dock.js.map +1 -1
- package/package.json +12 -12
- package/test/browser/list-page.js +35 -0
- package/test/browser/list.check.mjs +68 -0
- package/test/figure-released.test.ts +1 -1
- package/things-factory.config.js +1 -0
- package/translations/en.json +1 -1
- package/translations/es.json +1 -1
- package/translations/ja.json +1 -1
- package/translations/ko.json +1 -1
- package/translations/ms.json +1 -1
- package/translations/zh.json +1 -1
|
@@ -2,8 +2,8 @@ import '@operato/data-grist'
|
|
|
2
2
|
import '@material/web/icon/icon.js'
|
|
3
3
|
import '../viewparts/figure-thumb.js'
|
|
4
4
|
|
|
5
|
-
import { css, html } from 'lit'
|
|
6
|
-
import { customElement, property, query
|
|
5
|
+
import { css, html, nothing } from 'lit'
|
|
6
|
+
import { customElement, property, query } from 'lit/decorators.js'
|
|
7
7
|
|
|
8
8
|
import type { DataGrist, FetchOption } from '@operato/data-grist'
|
|
9
9
|
import { i18next, localize } from '@operato/i18n'
|
|
@@ -97,23 +97,6 @@ export class FigureListPage extends FigureListPageBase {
|
|
|
97
97
|
카드 · 그림 칸 · 만들기 FAB 는 모든 카드 카탈로그와 같다(@operato/styles CardCatalogStyles,
|
|
98
98
|
ADR-0117 개정 2026-10-13). 여기에는 이 화면에만 있는 것만 둔다.
|
|
99
99
|
*/
|
|
100
|
-
/* Which figures are listed: quiet words beside the filters, coloured when they are on. */
|
|
101
|
-
button[scope] {
|
|
102
|
-
font: inherit;
|
|
103
|
-
padding: 0 8px;
|
|
104
|
-
border: none;
|
|
105
|
-
background: none;
|
|
106
|
-
color: var(--md-sys-color-on-surface-variant);
|
|
107
|
-
cursor: pointer;
|
|
108
|
-
white-space: nowrap;
|
|
109
|
-
}
|
|
110
|
-
button[scope]:hover {
|
|
111
|
-
color: var(--md-sys-color-on-surface);
|
|
112
|
-
}
|
|
113
|
-
button[scope][aria-pressed='true'] {
|
|
114
|
-
color: var(--md-sys-color-primary);
|
|
115
|
-
font-weight: 600;
|
|
116
|
-
}
|
|
117
100
|
ox-grist {
|
|
118
101
|
/* 상태와 성숙도는 짧은 표식이다 — 두 줄로 세우지 않고 한 줄에 뉜다 */
|
|
119
102
|
--data-card-detail-direction: row;
|
|
@@ -127,14 +110,18 @@ export class FigureListPage extends FigureListPageBase {
|
|
|
127
110
|
|
|
128
111
|
@query('ox-grist') private grist!: DataGrist
|
|
129
112
|
|
|
130
|
-
/**
|
|
131
|
-
|
|
113
|
+
/**
|
|
114
|
+
* The domain's own figures, or other domains' public ones (LV figure-server design G2), read only. Each is a screen
|
|
115
|
+
* of its own on the rail (user 2026-10-19): the own catalogue is where figures are made and changed, the public one
|
|
116
|
+
* only looked at, so a switch inside one list mixed two jobs. `figure-public-list-page` sets it.
|
|
117
|
+
*/
|
|
118
|
+
protected readonly scope: 'own' | 'public' = 'own'
|
|
132
119
|
|
|
133
120
|
private listen?: () => void
|
|
134
121
|
|
|
135
122
|
get context() {
|
|
136
123
|
return {
|
|
137
|
-
title: i18next.t('figure.title.figures'),
|
|
124
|
+
title: i18next.t(this.scope === 'public' ? 'figure.title.public-figures' : 'figure.title.figures'),
|
|
138
125
|
search: {
|
|
139
126
|
handler: (search: string) => {
|
|
140
127
|
this.grist.searchText = search
|
|
@@ -171,15 +158,16 @@ export class FigureListPage extends FigureListPageBase {
|
|
|
171
158
|
<div class="filters">
|
|
172
159
|
<ox-filters-form autofocus without-search></ox-filters-form>
|
|
173
160
|
</div>
|
|
174
|
-
<button scope aria-pressed=${String(this.scope === 'public')} @click=${() => this.toggleScope()}>${i18next.t('figure.button.public-figures')}</button>
|
|
175
161
|
</div>
|
|
176
162
|
|
|
177
163
|
<ox-grist-personalizer slot="setting"></ox-grist-personalizer>
|
|
178
164
|
</ox-grist>
|
|
179
165
|
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
166
|
+
${this.scope === 'own'
|
|
167
|
+
? html`<button fab title=${i18next.t('figure.button.new-figure')} @click=${() => this.openModeller()}>
|
|
168
|
+
<md-icon>add</md-icon>${i18next.t('figure.button.new-figure')}
|
|
169
|
+
</button>`
|
|
170
|
+
: nothing}
|
|
183
171
|
`
|
|
184
172
|
}
|
|
185
173
|
|
|
@@ -340,15 +328,19 @@ export class FigureListPage extends FigureListPageBase {
|
|
|
340
328
|
이름표는 비워 둔다. 단추에 「초안」·「발행됨」이라고 적혀 있으니 그 앞의 「상태」는
|
|
341
329
|
같은 말을 한 번 더 하는 것이고, 걸러 보기 줄에서 자리만 먹는다.
|
|
342
330
|
*/
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
331
|
+
/* Another domain's public figures are released ones only: no draft to tell apart, no choice to offer. */
|
|
332
|
+
filter:
|
|
333
|
+
this.scope === 'own'
|
|
334
|
+
? {
|
|
335
|
+
type: 'select-buttons',
|
|
336
|
+
operator: 'in',
|
|
337
|
+
label: '',
|
|
338
|
+
options: [
|
|
339
|
+
{ display: i18next.t('figure.label.draft'), value: 'draft' },
|
|
340
|
+
{ display: i18next.t('figure.label.figure-released'), value: 'released' }
|
|
341
|
+
]
|
|
342
|
+
}
|
|
343
|
+
: undefined,
|
|
352
344
|
width: 120
|
|
353
345
|
},
|
|
354
346
|
{
|
|
@@ -559,11 +551,6 @@ export class FigureListPage extends FigureListPageBase {
|
|
|
559
551
|
navigate(modellerPathOf(figure))
|
|
560
552
|
}
|
|
561
553
|
|
|
562
|
-
private toggleScope() {
|
|
563
|
-
this.scope = this.scope === 'public' ? 'own' : 'public'
|
|
564
|
-
this.grist?.fetch()
|
|
565
|
-
}
|
|
566
|
-
|
|
567
554
|
/** `remove` 는 HTMLElement 의 메서드다 — 가리면 조용한 결함이 된다. */
|
|
568
555
|
private async removeFigure(figure: Figure) {
|
|
569
556
|
if (this.scope === 'public') return
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { customElement } from 'lit/decorators.js'
|
|
2
|
+
|
|
3
|
+
import { FigureListPage } from './figure-list-page.js'
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Other domains' public figures (LV figure-server design G2), a screen of its own on the rail (user 2026-10-19).
|
|
7
|
+
*
|
|
8
|
+
* Looked at only: each shows its latest release and its domain, and nothing on it is changed from here -- no new
|
|
9
|
+
* figure, no delete, no edit (`figure-detail-dock.ts` \`foreign\`). The catalogue's own class with the other scope, so
|
|
10
|
+
* the two lists are one list.
|
|
11
|
+
*/
|
|
12
|
+
@customElement('figure-public-list-page')
|
|
13
|
+
export class FigurePublicListPage extends FigureListPage {
|
|
14
|
+
protected readonly scope = 'public' as const
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
declare global {
|
|
18
|
+
interface HTMLElementTagNameMap {
|
|
19
|
+
'figure-public-list-page': FigurePublicListPage
|
|
20
|
+
}
|
|
21
|
+
}
|
package/client/route.ts
CHANGED
|
@@ -4,6 +4,10 @@ export default function route(page: string) {
|
|
|
4
4
|
import('./pages/figure-list-page')
|
|
5
5
|
return page
|
|
6
6
|
|
|
7
|
+
case 'figure-public-list':
|
|
8
|
+
import('./pages/figure-public-list-page')
|
|
9
|
+
return page
|
|
10
|
+
|
|
7
11
|
case 'figure-modeller':
|
|
8
12
|
import('./pages/figure-modeller-page')
|
|
9
13
|
return page
|
|
@@ -4,6 +4,7 @@ import { customElement, property, state } from 'lit/decorators.js'
|
|
|
4
4
|
import { i18next, localize } from '@operato/i18n'
|
|
5
5
|
import { appendViewpart, UPDATE_VIEWPART, VIEWPART_POSITION, VIEWPART_LEVEL } from '@operato/layout'
|
|
6
6
|
import { navigate, store } from '@operato/shell'
|
|
7
|
+
import { addressController } from '@operato/utils/address.js'
|
|
7
8
|
import { ScrollbarStyles } from '@operato/styles'
|
|
8
9
|
import { ASSISTANT_DOCK_VIEWPART } from '@things-factory/ai-assistant/dist-client/components/assistant-dock.js'
|
|
9
10
|
import { figureCostOf, parseFigureAsset, type FigureAsset } from '@hatiolab/figure-model'
|
|
@@ -129,6 +130,7 @@ export class FigureDetailDock extends localize(i18next)(LitElement) {
|
|
|
129
130
|
@state() private retireBusy = false
|
|
130
131
|
private ticket = 0
|
|
131
132
|
private unsubscribe?: () => void
|
|
133
|
+
private stopAddress?: () => void
|
|
132
134
|
private boundary?: Element
|
|
133
135
|
private boundaryObserver?: ResizeObserver
|
|
134
136
|
|
|
@@ -172,7 +174,8 @@ export class FigureDetailDock extends localize(i18next)(LitElement) {
|
|
|
172
174
|
connectedCallback() {
|
|
173
175
|
super.connectedCallback()
|
|
174
176
|
window.addEventListener('resize', this.place)
|
|
175
|
-
|
|
177
|
+
/* Every committed address, a link or a navigate() as much as a traversal - the address layer fires no popstate for its own writes. */
|
|
178
|
+
this.stopAddress = addressController().subscribe(() => this.place(), false)
|
|
176
179
|
this.unsubscribe = store.subscribe(() => {
|
|
177
180
|
const state = store.getState() as { layout?: { viewparts?: Record<string, { show?: boolean }> }; route?: { page?: string } }
|
|
178
181
|
const parts = state.layout?.viewparts
|
|
@@ -185,7 +188,7 @@ export class FigureDetailDock extends localize(i18next)(LitElement) {
|
|
|
185
188
|
disconnectedCallback() {
|
|
186
189
|
super.disconnectedCallback()
|
|
187
190
|
window.removeEventListener('resize', this.place)
|
|
188
|
-
|
|
191
|
+
this.stopAddress?.()
|
|
189
192
|
window.removeEventListener('keydown', this.escape)
|
|
190
193
|
this.unsubscribe?.()
|
|
191
194
|
this.boundaryObserver?.disconnect()
|
|
@@ -30,8 +30,12 @@ export declare class FigureListPage extends FigureListPageBase {
|
|
|
30
30
|
static styles: import("lit").CSSResult[];
|
|
31
31
|
gristConfig: any;
|
|
32
32
|
private grist;
|
|
33
|
-
/**
|
|
34
|
-
|
|
33
|
+
/**
|
|
34
|
+
* The domain's own figures, or other domains' public ones (LV figure-server design G2), read only. Each is a screen
|
|
35
|
+
* of its own on the rail (user 2026-10-19): the own catalogue is where figures are made and changed, the public one
|
|
36
|
+
* only looked at, so a switch inside one list mixed two jobs. `figure-public-list-page` sets it.
|
|
37
|
+
*/
|
|
38
|
+
protected readonly scope: 'own' | 'public';
|
|
35
39
|
private listen?;
|
|
36
40
|
get context(): {
|
|
37
41
|
title: string;
|
|
@@ -72,7 +76,6 @@ export declare class FigureListPage extends FigureListPageBase {
|
|
|
72
76
|
}>;
|
|
73
77
|
/** The modeller that can edit this figure, by its format; a new figure starts in (`modeller-route.ts`). */
|
|
74
78
|
private openModeller;
|
|
75
|
-
private toggleScope;
|
|
76
79
|
/** `remove` 는 HTMLElement 의 메서드다 — 가리면 조용한 결함이 된다. */
|
|
77
80
|
private removeFigure;
|
|
78
81
|
}
|
|
@@ -2,8 +2,8 @@ import { __decorate, __metadata } from "tslib";
|
|
|
2
2
|
import '@operato/data-grist';
|
|
3
3
|
import '@material/web/icon/icon.js';
|
|
4
4
|
import '../viewparts/figure-thumb.js';
|
|
5
|
-
import { css, html } from 'lit';
|
|
6
|
-
import { customElement, property, query
|
|
5
|
+
import { css, html, nothing } from 'lit';
|
|
6
|
+
import { customElement, property, query } from 'lit/decorators.js';
|
|
7
7
|
import { i18next, localize } from '@operato/i18n';
|
|
8
8
|
import { p13n } from '@operato/p13n';
|
|
9
9
|
import { auth } from '@things-factory/auth-base/dist-client';
|
|
@@ -72,7 +72,11 @@ const FigureListPageBase = p13n(localize(i18next)(PageView));
|
|
|
72
72
|
let FigureListPage = class FigureListPage extends FigureListPageBase {
|
|
73
73
|
constructor() {
|
|
74
74
|
super(...arguments);
|
|
75
|
-
/**
|
|
75
|
+
/**
|
|
76
|
+
* The domain's own figures, or other domains' public ones (LV figure-server design G2), read only. Each is a screen
|
|
77
|
+
* of its own on the rail (user 2026-10-19): the own catalogue is where figures are made and changed, the public one
|
|
78
|
+
* only looked at, so a switch inside one list mixed two jobs. `figure-public-list-page` sets it.
|
|
79
|
+
*/
|
|
76
80
|
this.scope = 'own';
|
|
77
81
|
this.cardsChanged = () => {
|
|
78
82
|
if (this.active)
|
|
@@ -96,23 +100,6 @@ let FigureListPage = class FigureListPage extends FigureListPageBase {
|
|
|
96
100
|
카드 · 그림 칸 · 만들기 FAB 는 모든 카드 카탈로그와 같다(@operato/styles CardCatalogStyles,
|
|
97
101
|
ADR-0117 개정 2026-10-13). 여기에는 이 화면에만 있는 것만 둔다.
|
|
98
102
|
*/
|
|
99
|
-
/* Which figures are listed: quiet words beside the filters, coloured when they are on. */
|
|
100
|
-
button[scope] {
|
|
101
|
-
font: inherit;
|
|
102
|
-
padding: 0 8px;
|
|
103
|
-
border: none;
|
|
104
|
-
background: none;
|
|
105
|
-
color: var(--md-sys-color-on-surface-variant);
|
|
106
|
-
cursor: pointer;
|
|
107
|
-
white-space: nowrap;
|
|
108
|
-
}
|
|
109
|
-
button[scope]:hover {
|
|
110
|
-
color: var(--md-sys-color-on-surface);
|
|
111
|
-
}
|
|
112
|
-
button[scope][aria-pressed='true'] {
|
|
113
|
-
color: var(--md-sys-color-primary);
|
|
114
|
-
font-weight: 600;
|
|
115
|
-
}
|
|
116
103
|
ox-grist {
|
|
117
104
|
/* 상태와 성숙도는 짧은 표식이다 — 두 줄로 세우지 않고 한 줄에 뉜다 */
|
|
118
105
|
--data-card-detail-direction: row;
|
|
@@ -123,7 +110,7 @@ let FigureListPage = class FigureListPage extends FigureListPageBase {
|
|
|
123
110
|
]; }
|
|
124
111
|
get context() {
|
|
125
112
|
return {
|
|
126
|
-
title: i18next.t('figure.title.figures'),
|
|
113
|
+
title: i18next.t(this.scope === 'public' ? 'figure.title.public-figures' : 'figure.title.figures'),
|
|
127
114
|
search: {
|
|
128
115
|
handler: (search) => {
|
|
129
116
|
this.grist.searchText = search;
|
|
@@ -159,15 +146,16 @@ let FigureListPage = class FigureListPage extends FigureListPageBase {
|
|
|
159
146
|
<div class="filters">
|
|
160
147
|
<ox-filters-form autofocus without-search></ox-filters-form>
|
|
161
148
|
</div>
|
|
162
|
-
<button scope aria-pressed=${String(this.scope === 'public')} @click=${() => this.toggleScope()}>${i18next.t('figure.button.public-figures')}</button>
|
|
163
149
|
</div>
|
|
164
150
|
|
|
165
151
|
<ox-grist-personalizer slot="setting"></ox-grist-personalizer>
|
|
166
152
|
</ox-grist>
|
|
167
153
|
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
154
|
+
${this.scope === 'own'
|
|
155
|
+
? html `<button fab title=${i18next.t('figure.button.new-figure')} @click=${() => this.openModeller()}>
|
|
156
|
+
<md-icon>add</md-icon>${i18next.t('figure.button.new-figure')}
|
|
157
|
+
</button>`
|
|
158
|
+
: nothing}
|
|
171
159
|
`;
|
|
172
160
|
}
|
|
173
161
|
/**
|
|
@@ -321,15 +309,18 @@ let FigureListPage = class FigureListPage extends FigureListPageBase {
|
|
|
321
309
|
이름표는 비워 둔다. 단추에 「초안」·「발행됨」이라고 적혀 있으니 그 앞의 「상태」는
|
|
322
310
|
같은 말을 한 번 더 하는 것이고, 걸러 보기 줄에서 자리만 먹는다.
|
|
323
311
|
*/
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
312
|
+
/* Another domain's public figures are released ones only: no draft to tell apart, no choice to offer. */
|
|
313
|
+
filter: this.scope === 'own'
|
|
314
|
+
? {
|
|
315
|
+
type: 'select-buttons',
|
|
316
|
+
operator: 'in',
|
|
317
|
+
label: '',
|
|
318
|
+
options: [
|
|
319
|
+
{ display: i18next.t('figure.label.draft'), value: 'draft' },
|
|
320
|
+
{ display: i18next.t('figure.label.figure-released'), value: 'released' }
|
|
321
|
+
]
|
|
322
|
+
}
|
|
323
|
+
: undefined,
|
|
333
324
|
width: 120
|
|
334
325
|
},
|
|
335
326
|
{
|
|
@@ -524,10 +515,6 @@ let FigureListPage = class FigureListPage extends FigureListPageBase {
|
|
|
524
515
|
openModeller(figure) {
|
|
525
516
|
navigate(modellerPathOf(figure));
|
|
526
517
|
}
|
|
527
|
-
toggleScope() {
|
|
528
|
-
this.scope = this.scope === 'public' ? 'own' : 'public';
|
|
529
|
-
this.grist?.fetch();
|
|
530
|
-
}
|
|
531
518
|
/** `remove` 는 HTMLElement 의 메서드다 — 가리면 조용한 결함이 된다. */
|
|
532
519
|
async removeFigure(figure) {
|
|
533
520
|
if (this.scope === 'public')
|
|
@@ -559,10 +546,6 @@ __decorate([
|
|
|
559
546
|
query('ox-grist'),
|
|
560
547
|
__metadata("design:type", Function)
|
|
561
548
|
], FigureListPage.prototype, "grist", void 0);
|
|
562
|
-
__decorate([
|
|
563
|
-
state(),
|
|
564
|
-
__metadata("design:type", String)
|
|
565
|
-
], FigureListPage.prototype, "scope", void 0);
|
|
566
549
|
FigureListPage = __decorate([
|
|
567
550
|
customElement('figure-list-page')
|
|
568
551
|
], FigureListPage);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"figure-list-page.js","sourceRoot":"","sources":["../../client/pages/figure-list-page.ts"],"names":[],"mappings":";AAAA,OAAO,qBAAqB,CAAA;AAC5B,OAAO,4BAA4B,CAAA;AACnC,OAAO,8BAA8B,CAAA;AAErC,OAAO,EAAE,GAAG,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AAE,CAAC,CAAA;QAC/B,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,MAAM,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,EAAG,CAAW,CAAC,OAAO,EAAE,CAAC,CAAA;YACzD,OAAM;QACR,CAAC;QACD,IAAI,CAAC,KAAK,CAAC,KAAK,EAAE,CAAA;IACpB,CAAC;;AA7c2B;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;mDAAiB;AAEjB;IAA1B,KAAK,CAAC,UAAU,CAAC;;6CAA0B;AAG3B;IAAhB,KAAK,EAAE;;6CAAwC;AAjDrC,cAAc;IAD1B,aAAa,CAAC,kBAAkB,CAAC;GACrB,cAAc,CA0f1B","sourcesContent":["import '@operato/data-grist'\nimport '@material/web/icon/icon.js'\nimport '../viewparts/figure-thumb.js'\n\nimport { css, html } from 'lit'\nimport { customElement, property, query, state } from 'lit/decorators.js'\n\nimport type { DataGrist, FetchOption } from '@operato/data-grist'\nimport { i18next, localize } from '@operato/i18n'\nimport { p13n } from '@operato/p13n'\nimport { auth } from '@things-factory/auth-base/dist-client'\nimport { navigate, PageView } from '@operato/shell'\nimport { notify } from '@operato/layout'\nimport { CardCatalogStyles, CommonGristStyles, CommonHeaderStyles, ScrollbarStyles, WorkSurfacePageStyles } from '@operato/styles'\n\nimport { capacityFrom } from '../modeller/scene-budget.js'\nimport { deleteFigure, fetchFigureList } from '../graphql/index.js'\nimport type { Figure } from '../types.js'\nimport { hasBeenReleased } from '../figure-released.js'\nimport { modellerPathOf } from '../modeller/modeller-route.js'\nimport { FIGURE_PUBLIC_CHANGED, FIGURE_RETIREMENT_CHANGED, FIGURE_THUMBNAIL_CHANGED, openFigureDetail } from '../viewparts/figure-detail-dock.js'\n\n/**\n * 이 값 아래면 점수를 색으로 눈에 띄게 한다.\n *\n * **등급 경계가 아니다.** 등급(A~D)은 `figure-model` 의 `scoreOf` 가 정하고 화면은 그것을\n * 베끼지 않는다. 이것은 「눈에 걸리게 할 선」이고, 화면의 판단이다.\n */\nconst ATTENTION_BELOW = 50\n\n/*\n * ── renderer 가 그리는 것은 이 파일의 CSS 가 닿지 않는다 ──────────────────────\n *\n * 컬럼 renderer 의 결과는 `ox-card-field` 의 shadow root 안에 그려진다. 이 페이지의 `static\n * styles` 는 그 경계를 넘지 못하므로 `code[figure-type]` 같은 선택자는 **아무 일도 하지 않는다.**\n * 넘어가는 것은 custom property 뿐이라, 색과 글꼴은 여기서 인라인으로 준다 — 값 자체는 테마\n * 토큰을 가리키므로 밝음·어둠은 따라온다. data-grist 의 image renderer 도 같은 방식이다.\n */\nconst CAPACITY = 'font-weight: 700; color: var(--md-sys-color-primary);'\nconst UNMEASURED = 'font-style: italic; color: var(--md-sys-color-outline);'\nconst RELEASED = 'font-weight: 700; color: var(--md-sys-color-primary);'\nconst DRAFT = 'color: var(--md-sys-color-tertiary);'\n/**\n * 조용히 적는 숫자. 낮은 것만 점으로 눈에 걸리게 한다.\n *\n * **`inline-flex` 를 쓰지 않는다.** 썼더니 점이 뜨는 카드에서만 이 값이 옆의 두 값과 밑줄이\n * 어긋났다 — inline-flex 상자의 밑줄은 **첫 항목**에서 오는데, 첫 항목이 글자 없는 점이라\n * 밑줄이 없어 브라우저가 상자 아래를 밑줄로 삼는다. 점이 없는 카드(50 이상)는 멀쩡했으므로\n * 한 줄에 세 값이 나란히 설 때만 눈에 띄었다.\n *\n * 그냥 인라인으로 두면 이 상자의 밑줄이 곧 숫자의 밑줄이라 옆의 둘과 맞는다. 점은 제 몫으로\n * 글자 가운데에 맞춘다.\n */\nconst SCORE = 'font-variant-numeric: tabular-nums;'\nconst LOW_DOT =\n 'display: inline-block; width: 5px; height: 5px; margin-right: 4px; vertical-align: middle; ' +\n 'border-radius: 50%; background-color: var(--md-sys-color-error);'\n\n/*\n * `as typeof PageView` 로 조이지 않는다 — 그렇게 하면 p13n 이 얹어 주는\n * `getPagePreferenceProvider` 가 타입에서 사라져 개인 설정을 붙일 수 없다.\n */\nconst FigureListPageBase = p13n(localize(i18next)(PageView))\n\n/**\n * Figure 카탈로그.\n *\n * 카드를 고르면 상세 패널에서 저장본과 발행판을 살펴본다. 크기와 움직임을 시험한 뒤\n * 「편집 화면 열기」로 저작면에 들어간다. 목록 질의는 자산 원본을 싣지 않는다.\n *\n * ## 왜 손으로 만든 카드가 아니라 격자인가\n *\n * 전에는 카드 격자와 걸러 보기 줄과 빈 화면을 이 파일이 직접 그렸다(200줄). 그 자리에서 빠져\n * 있던 것들은 하나같이 `ox-grist` 가 이미 가진 것이다 — 쪽 나누기, 정렬, 컬럼 걸러 보기,\n * 개인 설정(모드·정렬·쪽 크기를 사람마다 기억한다), 표 모드로 바꿔 보기, 내보내기.\n * 손으로 만든 카드는 그 중 아무것도 없었고, 목록이 늘어나면 전부 한 번에 그렸다.\n *\n * 카드에 실을 것은 `list` 가 정하고, 무엇을 어떻게 그릴지는 컬럼의 renderer 가 정한다. 같은\n * 설정이 표 모드에서도 그대로 쓰이므로 **두 모드가 다른 말을 하지 않는다.**\n */\n@customElement('figure-list-page')\nexport class FigureListPage extends FigureListPageBase {\n static styles = [\n /* The frame owns the page shell; the grist is the content it sizes (ADR-0060 decision 8). */\n WorkSurfacePageStyles,\n ScrollbarStyles,\n CommonGristStyles,\n CommonHeaderStyles,\n CardCatalogStyles,\n css`\n :host {\n background-color: var(--md-sys-color-surface);\n color: var(--md-sys-color-on-surface);\n }\n\n /*\n 카드 · 그림 칸 · 만들기 FAB 는 모든 카드 카탈로그와 같다(@operato/styles CardCatalogStyles,\n ADR-0117 개정 2026-10-13). 여기에는 이 화면에만 있는 것만 둔다.\n */\n /* Which figures are listed: quiet words beside the filters, coloured when they are on. */\n button[scope] {\n font: inherit;\n padding: 0 8px;\n border: none;\n background: none;\n color: var(--md-sys-color-on-surface-variant);\n cursor: pointer;\n white-space: nowrap;\n }\n button[scope]:hover {\n color: var(--md-sys-color-on-surface);\n }\n button[scope][aria-pressed='true'] {\n color: var(--md-sys-color-primary);\n font-weight: 600;\n }\n ox-grist {\n /* 상태와 성숙도는 짧은 표식이다 — 두 줄로 세우지 않고 한 줄에 뉜다 */\n --data-card-detail-direction: row;\n /* 표 모드의 맨 위로 단추도 만들기 단추 위로 비킨다 */\n --data-list-fab-position-vertical: 64px;\n }\n `\n ]\n\n @property({ type: Object }) gristConfig: any\n\n @query('ox-grist') private grist!: DataGrist\n\n /** The domain's own figures, or other domains' public ones (LV figure-server design G2), read only. */\n @state() private scope: 'own' | 'public' = 'own'\n\n private listen?: () => void\n\n get context() {\n return {\n title: i18next.t('figure.title.figures'),\n search: {\n handler: (search: string) => {\n this.grist.searchText = search\n },\n value: this.grist?.searchText || '',\n placeholder: i18next.t('figure.text.search-figure')\n },\n filter: {\n handler: () => {\n this.grist.toggleHeadroom()\n }\n }\n /*\n **만들기는 `actions` 가 아니라 FAB 이다.**\n\n `context.actions` 로 두면 페이지 바닥 줄에 글자 단추로 서는데, 그 줄은 「지금 화면에 대해\n 할 일」을 늘어놓는 자리다. 만들기는 이 화면의 유일한 주된 동작이므로 줄에 섞이지 않고\n 떠 있어야 한다. 카드를 가리지 않는 오른쪽 아래, 손이 가는 자리다(아래 render 의 [fab]).\n */\n }\n }\n\n render() {\n return html`\n <ox-grist\n class=\"page-fill\"\n mode=\"CARD\"\n @search-tag=${(e: CustomEvent) => this.findByTag(e.detail.tag)}\n .config=${this.gristConfig}\n .fetchHandler=${this.fetchHandler.bind(this)}\n .personalConfigProvider=${this.getPagePreferenceProvider('ox-grist')!}\n >\n <div slot=\"headroom\" class=\"header\">\n <div class=\"filters\">\n <ox-filters-form autofocus without-search></ox-filters-form>\n </div>\n <button scope aria-pressed=${String(this.scope === 'public')} @click=${() => this.toggleScope()}>${i18next.t('figure.button.public-figures')}</button>\n </div>\n\n <ox-grist-personalizer slot=\"setting\"></ox-grist-personalizer>\n </ox-grist>\n\n <button fab title=${i18next.t('figure.button.new-figure')} @click=${() => this.openModeller()}>\n <md-icon>add</md-icon>${i18next.t('figure.button.new-figure')}\n </button>\n `\n }\n\n /**\n * 카드의 태그 알약을 눌렀다 — **그 태그로 목록을 거른다.**\n *\n * 검색창에 그 말을 채워 넣는다. 격자에 조건만 걸고 창을 비워 두면 저작자는 **왜 목록이\n * 줄었는지 모른 채** 보게 되고, 되돌리려면 무엇을 지워야 하는지도 알 수 없다.\n *\n * 서버가 `tags` 뿐 아니라 이름·타입·설명·분류를 함께 훑으므로, 그 말이 다른 칸에 든 도형도\n * 같이 온다. 태그만 정확히 거르는 것이 아니라 **찾기**다.\n */\n private findByTag(tag: string) {\n this.grist.searchText = tag\n /* 창의 값은 `context` 에서 나온다 — 다시 알려야 헤더가 새 값을 그린다. */\n this.updateContext()\n }\n\n async pageInitialized() {\n this.gristConfig = {\n /*\n **쪽 나누기는 선택이 아니다.** 격자에 가상 스크롤이 없어 받은 것을 전부 DOM 에 그린다.\n 카드 모드는 끝까지 내려가면 다음 쪽을 이어 붙이므로, 한 쪽이 작아도 목록은 계속 읽힌다.\n */\n pagination: { pages: [24, 48, 96] },\n\n /*\n 아직 아무것도 없을 때 하는 말. **이 자리가 이 화면에서 가장 중요하다** — 처음 온 사람은\n 여기서 이 도구가 무엇을 만드는 것인지 알게 된다. 조건이 걸려 비었을 때는 격자가 스스로\n 다른 말을 한다(「찾는 것이 없다」). 그 둘을 섞지 않는 것이 격자 쪽에 이미 들어 있다.\n */\n emptyNote: {\n icon: 'deployed_code',\n title: i18next.t('figure.text.no-figure-yet'),\n description: i18next.t('figure.text.what-a-figure-is')\n },\n\n list: {\n /* 그림 칸은 그 컬럼의 renderer 가 그린다 — 그림 없을 때의 안내까지 `figure-thumb` 안이다 */\n thumbnail: 'thumbnail',\n fields: ['name', 'type'],\n /*\n ── 무게를 모른 채 고르게 두지 않는다 ────────────────────────────────\n 이름과 그림만 실으면 저작자는 **이 형상이 무거운지 모른 채** 고른다. 그것을 저작면에\n 들어가서야 아는 것은 늦다. 그래서 격자로 옮기기 전 손 카드가 실었던 셋을 그대로 싣는다 —\n 몇 개까지 놓을 수 있나(배치 한도) · 성숙도 · 삼각형 수.\n\n 한 줄에 뉜다(`--data-card-detail-direction: row`). 이름표는 달지 않는다 — 값 자체가\n 「625개까지」·「삼각형 440개」로 읽히고, 성숙도만 숫자 하나여서 손이 갔을 때 이름이 뜬다.\n\n 상태는 이 줄에 없다. 그림 위 초안 표시가 그 일을 한다(`figure-thumb`) — 발행된 것에는\n 아무 말도 하지 않으므로 빈 칸이 생기지 않는다.\n */\n details: ['capacity', 'score', 'triangles']\n },\n\n columns: [\n { type: 'gutter', gutterName: 'sequence', fixed: true },\n {\n /*\n 표 모드에서만 쓰는 삭제 칸. 카드에서는 `figure-thumb` 이 그림 위에 그리므로\n `forList: false` 로 내린다 — 카드 아래 단추 줄은 감춰도 자리가 남는다.\n */\n type: 'gutter',\n gutterName: 'button',\n icon: 'delete',\n title: i18next.t('figure.button.delete-figure'),\n danger: true,\n forList: false,\n width: 40,\n handlers: {\n click: (_columns: any, _data: any, _column: any, record: Figure) => this.removeFigure(record)\n }\n },\n {\n type: 'string',\n name: 'name',\n header: i18next.t('figure.label.name'),\n record: { editable: false },\n filter: 'search',\n sortable: true,\n width: 200\n },\n {\n /*\n 타입 이름은 **저장되는 식별자**다. 표시 이름과 다르게 보이게 두어야 도면이 무엇으로\n 이 형상을 찾는지 헷갈리지 않는다.\n */\n type: 'string',\n name: 'type',\n header: i18next.t('figure.label.figure-type'),\n record: {\n editable: false,\n /* The full name a board stores: {namespace}/{type} (ADR-0114). */\n renderer: (value: string, column: unknown, record: { namespace?: string }) =>\n html`<code>${record?.namespace ? `${record.namespace}/${value}` : value}</code>`\n },\n filter: 'search',\n sortable: true,\n width: 160\n },\n {\n /*\n 태그 — **카드에서 곁줄로 보이고 검색에 걸린다.**\n\n 서버가 이미 `type`·`name`·`description`·`category`·`tags` 를 함께 훑는다. 그런데\n 화면에는 태그가 어디에도 안 보여서, 저작자가 적은 태그가 **자기 눈에 돌아오지 않았다** —\n 적어 둔 것이 쓰이는지 알 수 없으면 아무도 적지 않는다.\n\n 정렬은 걸지 않는다. 배열이라 무엇을 기준으로 줄을 세우는지 답할 수 없다.\n\n **카드에서는 이 컬럼이 그리지 않는다.** 본문에 한 줄로 두었더니 태그가 있는 카드만\n 높아져 격자가 어긋났다 — 개수가 도형마다 다르므로 본문에 두는 한 남는 문제다.\n 카드에서는 `figure-thumb` 이 그림 위에 얹는다. 여기 남은 것은 표 모드의 칸이다.\n */\n type: 'string',\n name: 'tags',\n header: i18next.t('figure.label.tags'),\n record: {\n editable: false,\n renderer: (value: string[] | null) => (value || []).join(' · ')\n },\n filter: 'search',\n sortable: false,\n width: 180\n },\n {\n type: 'string',\n name: 'state',\n header: i18next.t('figure.label.state'),\n record: {\n editable: false,\n /*\n **발행된 것에는 아무 말도 하지 않는다.** 카탈로그에 있는 것은 대개 발행된 것이라,\n 카드마다 「발행됨」이 붙으면 그 말이 아무것도 가르지 않고 자리만 먹는다. 판 번호도\n 고를 때 쓰는 값이 아니다 — 이력 탭에 있다.\n\n 표 모드에서는 칸에 값이 있어야 하므로 그때는 발행됨도 적는다(`wide` 가 아니라 label\n 이 붙는 자리인지로 가른다 — 카드는 label 을 달지 않았다).\n */\n renderer: (value: string, _column: any, record: Figure, _rowIndex: number, field: Element) => {\n if (value !== 'released') {\n return html`<span style=${DRAFT}>${i18next.t('figure.label.draft')}</span>`\n }\n\n /* 표에서는 칸이 비면 안 된다. 카드에서만 입을 다문다 — 그리는 자리가 알려 준다. */\n return field?.tagName === 'OX-CARD-FIELD'\n ? ''\n : html`<span style=${RELEASED}\n >${i18next.t('figure.label.figure-released')}\n ${record.version ? i18next.t('figure.text.version-number', { version: record.version }) : ''}</span\n >`\n }\n },\n /*\n 전체·초안·발행됨을 단추로 고른다 — 값이 둘뿐인 조건을 펼침 목록에 넣지 않는다.\n\n 이름표는 비워 둔다. 단추에 「초안」·「발행됨」이라고 적혀 있으니 그 앞의 「상태」는\n 같은 말을 한 번 더 하는 것이고, 걸러 보기 줄에서 자리만 먹는다.\n */\n filter: {\n type: 'select-buttons',\n operator: 'in',\n label: '',\n options: [\n { display: i18next.t('figure.label.draft'), value: 'draft' },\n { display: i18next.t('figure.label.figure-released'), value: 'released' }\n ]\n },\n width: 120\n },\n {\n /*\n **몇 개까지 놓을 수 있나.** 카드에는 싣지 않고 표 모드의 칸으로 둔다 — 고른 뒤에\n 따지는 값이다. 서버에 없는 값이라 `groups` 와 `triangles` 에서 계산하는데, 저작면\n 머리와 **같은 함수**를 쓴다. 두 화면이 같은 형상을 다른 잣대로 말하면 무엇을 고칠지\n 모른다.\n */\n type: 'string',\n name: 'capacity',\n header: i18next.t('figure.label.placement-limit'),\n sortable: false,\n record: {\n editable: false,\n renderer: (_value: unknown, _column: any, record: Figure) => {\n const capacity = capacityFrom(record.groups ?? 0, record.triangles ?? 0)\n\n return capacity\n ? html`<span style=${CAPACITY} title=${i18next.t('figure.text.reuse-score-explained')}>\n ${i18next.t('figure.text.fits-n-instances', { n: capacity.instances.toLocaleString() })}\n </span>`\n : html`<span style=${UNMEASURED}>${i18next.t('figure.text.not-measured-yet')}</span>`\n }\n },\n width: 120\n },\n {\n type: 'float',\n name: 'score',\n header: i18next.t('figure.label.maturity'),\n record: {\n editable: false,\n /*\n 카드에 남긴 하나뿐인 숫자. **이름표를 달지 않으므로** 무엇인지는 손이 갔을 때 뜨는\n 말이 알려 준다.\n\n 색칠한 배지로 두지 않는다. 옛 draw call 한도 3 으로 재던 때는 카탈로그 거의 모두가 0 점이라\n 붉은 덩어리가 카드마다 섰고 아무것도 가르지 못했다. 이 모델은 「한 화면 N 대」 목표에 견준\n 여유라(`figureScoreOf`, 2026-09-24) 퍼지지만, 숫자는 조용히 적고 낮은 것에만 **점 하나**를 붙인다.\n\n 아직 재지 않은 것을 0 으로 보여 주지 않는다 — 0 은 「가볍다」는 뜻이 되어 버린다.\n 등급 문자(A~D)도 여기서 만들지 않는다: 경계는 `figure-model` 의 `scoreOf` · `figureScoreOf` 가 정하고,\n 화면이 그것을 베끼면 두 벌이 되어 목록과 저작면이 다른 등급을 말한다.\n */\n renderer: (value: number | null) =>\n value == null\n ? html`<span style=${UNMEASURED}>${i18next.t('figure.text.not-measured-yet')}</span>`\n : html`<span style=${SCORE} title=${i18next.t('figure.label.maturity')}>\n ${value < ATTENTION_BELOW ? html`<i style=${LOW_DOT}></i>` : ''}${Math.round(value)}\n </span>`\n },\n sortable: true,\n width: 90\n },\n {\n type: 'integer',\n name: 'triangles',\n header: i18next.t('figure.label.triangles'),\n record: {\n editable: false,\n /*\n 카드에서는 이름표 없이 서므로 숫자만 두면 옆의 성숙도와 구별되지 않는다. 무엇의\n 수인지 값이 스스로 말하게 한다 — 표 모드에서는 머리글이 그 일을 하므로 겹치지만,\n 그 겹침이 카드에서 뜻을 잃는 것보다 낫다.\n */\n renderer: (value: number | null) =>\n value == null ? '' : i18next.t('figure.text.triangle-count', { count: value })\n },\n sortable: true,\n width: 110\n },\n {\n type: 'integer',\n name: 'groups',\n header: i18next.t('figure.label.budget-groups'),\n record: { editable: false },\n hidden: true,\n width: 0\n },\n {\n /*\n **카드의 그림 칸 전체를 이 renderer 가 그린다.**\n\n 기본 image renderer 는 그림만 그리고, 그 위에 얹혀야 하는 것(초안 표시·삭제)은 카드\n 아래 gutter 줄로 밀린다. 격자로 옮기기 전 손 카드가 그것을 그림 위에 두었고 그 편이\n 맞다 — 그래서 그림 칸을 `figure-thumb` 에게 넘긴다. hover 가 필요해 컴포넌트여야\n 하는 사연은 그 파일에 적혀 있다.\n\n `renderEmpty` — 그림이 아직 없는 것도 자리를 지킨다. 그 카드에도 초안 표시와 삭제가\n 있어야 하고, 「그림 없음」이라고 말하는 것도 `figure-thumb` 이 한다.\n */\n type: 'image',\n name: 'thumbnail',\n header: i18next.t('field.thumbnail'),\n record: {\n editable: false,\n align: 'center',\n wide: true,\n renderEmpty: true,\n renderer: (_value: unknown, _column: any, record: Figure) => html`\n <figure-thumb .figure=${record} ?readonly=${this.scope === 'public'} @remove=${() => this.removeFigure(record)}></figure-thumb>\n `\n },\n hidden: true,\n width: 160\n },\n {\n type: 'datetime',\n name: 'updatedAt',\n header: i18next.t('field.updated_at'),\n label: true,\n record: { editable: false },\n sortable: true,\n width: 180\n },\n {\n /*\n `resource-object` 를 쓰지 않는다 — 그 renderer 는 다른 패키지(resource-ui)가 등록하고,\n 등록되지 않은 앱에서는 조용히 글자 renderer 로 떨어져 `[object Object]` 가 된다.\n 이름 하나 꺼내는 일에 그 위험을 질 이유가 없다.\n */\n type: 'string',\n name: 'updater',\n header: i18next.t('field.updater'),\n record: {\n editable: false,\n renderer: (value: { name?: string } | null) => value?.name || ''\n },\n hidden: true,\n width: 120\n }\n ],\n\n rows: {\n selectable: false,\n appendable: false,\n handlers: {\n click: (_columns: any, _data: any, _column: any, record: Figure) => {\n if (record?.id) {\n openFigureDetail(record, this.scope === 'public')\n }\n }\n }\n },\n\n sorters: [{ name: 'updatedAt', desc: true }]\n }\n }\n\n connectedCallback() {\n super.connectedCallback()\n\n /*\n **로그인 정보가 도착하면 다시 불러온다.**\n\n 화면이 서는 것과 프로필이 오는 것은 순서가 정해져 있지 않고, 목록 질의는 로그인된 사람으로\n 나간다. 첫 질의가 프로필보다 앞서면 그 한 번이 실패하고, 그 뒤로 다시 묻는 사람이 없으면\n 화면은 비어 있는 채로 남는다. lite-menu 도 같은 신호로 같은 순서 문제를 푼다\n (`auth.on('profile')` — 그쪽 주석에 그 사연이 적혀 있다).\n */\n this.listen = () => {\n if (this.active) {\n this.grist?.fetch()\n }\n }\n auth.on('profile', this.listen)\n /* A picture chosen in the preview, or a figure retired or brought back: the cards are read again. */\n window.addEventListener(FIGURE_THUMBNAIL_CHANGED, this.cardsChanged)\n window.addEventListener(FIGURE_RETIREMENT_CHANGED, this.cardsChanged)\n window.addEventListener(FIGURE_PUBLIC_CHANGED, this.cardsChanged)\n }\n private cardsChanged = () => {\n if (this.active) this.grist?.fetch()\n }\n\n disconnectedCallback() {\n if (this.listen) {\n auth.off?.('profile', this.listen)\n this.listen = undefined\n }\n window.removeEventListener(FIGURE_THUMBNAIL_CHANGED, this.cardsChanged)\n window.removeEventListener(FIGURE_RETIREMENT_CHANGED, this.cardsChanged)\n window.removeEventListener(FIGURE_PUBLIC_CHANGED, this.cardsChanged)\n super.disconnectedCallback()\n }\n\n async pageUpdated() {\n if (this.active) {\n this.grist.fetch()\n }\n }\n\n /**\n * 걸러 보기·정렬·쪽을 **격자가 만든 그대로** 서버에 넘긴다.\n *\n * 여기서 이름을 바꿔 담으면 격자가 아는 조건과 서버에 가는 조건이 어긋난다. 실패는 격자가\n * 받아 화면에 낸다 — 목록이 비어 있는 것과 못 불러온 것은 다른 사실이다.\n */\n async fetchHandler({ page = 1, limit = 24, sortings = [], filters = [] }: FetchOption) {\n const { items, total } = await fetchFigureList({ page, limit, filters, sortings, scope: this.scope })\n\n return { total: total || 0, records: items || [] }\n }\n\n /** The modeller that can edit this figure, by its format; a new figure starts in (`modeller-route.ts`). */\n private openModeller(figure?: Figure) {\n navigate(modellerPathOf(figure))\n }\n\n private toggleScope() {\n this.scope = this.scope === 'public' ? 'own' : 'public'\n this.grist?.fetch()\n }\n\n /** `remove` 는 HTMLElement 의 메서드다 — 가리면 조용한 결함이 된다. */\n private async removeFigure(figure: Figure) {\n if (this.scope === 'public') return\n // 되돌릴 수 없는 조작이므로 무엇이 사라지는지 이름으로 확인한다\n if (hasBeenReleased(figure)) {\n notify({ level: 'info', message: i18next.t('figure.text.released-figure-not-deletable', { name: figure.name }) })\n return\n }\n const message = i18next.t('figure.text.delete-figure-confirm', { name: figure.name })\n if (!confirm(message)) {\n return\n }\n\n try {\n await deleteFigure(figure.id)\n } catch (e) {\n notify({ level: 'error', message: (e as Error).message })\n return\n }\n this.grist.fetch()\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"figure-list-page.js","sourceRoot":"","sources":["../../client/pages/figure-list-page.ts"],"names":[],"mappings":";AAAA,OAAO,qBAAqB,CAAA;AAC5B,OAAO,4BAA4B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O,CAAC,EAAE,CAAC;YACX,MAAM,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,OAAO,EAAG,CAAW,CAAC,OAAO,EAAE,CAAC,CAAA;YACzD,OAAM;QACR,CAAC;QACD,IAAI,CAAC,KAAK,CAAC,KAAK,EAAE,CAAA;IACpB,CAAC;;AAjd2B;IAA3B,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;;mDAAiB;AAEjB;IAA1B,KAAK,CAAC,UAAU,CAAC;;6CAA0B;AA7BjC,cAAc;IAD1B,aAAa,CAAC,kBAAkB,CAAC;GACrB,cAAc,CA6e1B","sourcesContent":["import '@operato/data-grist'\nimport '@material/web/icon/icon.js'\nimport '../viewparts/figure-thumb.js'\n\nimport { css, html, nothing } from 'lit'\nimport { customElement, property, query } from 'lit/decorators.js'\n\nimport type { DataGrist, FetchOption } from '@operato/data-grist'\nimport { i18next, localize } from '@operato/i18n'\nimport { p13n } from '@operato/p13n'\nimport { auth } from '@things-factory/auth-base/dist-client'\nimport { navigate, PageView } from '@operato/shell'\nimport { notify } from '@operato/layout'\nimport { CardCatalogStyles, CommonGristStyles, CommonHeaderStyles, ScrollbarStyles, WorkSurfacePageStyles } from '@operato/styles'\n\nimport { capacityFrom } from '../modeller/scene-budget.js'\nimport { deleteFigure, fetchFigureList } from '../graphql/index.js'\nimport type { Figure } from '../types.js'\nimport { hasBeenReleased } from '../figure-released.js'\nimport { modellerPathOf } from '../modeller/modeller-route.js'\nimport { FIGURE_PUBLIC_CHANGED, FIGURE_RETIREMENT_CHANGED, FIGURE_THUMBNAIL_CHANGED, openFigureDetail } from '../viewparts/figure-detail-dock.js'\n\n/**\n * 이 값 아래면 점수를 색으로 눈에 띄게 한다.\n *\n * **등급 경계가 아니다.** 등급(A~D)은 `figure-model` 의 `scoreOf` 가 정하고 화면은 그것을\n * 베끼지 않는다. 이것은 「눈에 걸리게 할 선」이고, 화면의 판단이다.\n */\nconst ATTENTION_BELOW = 50\n\n/*\n * ── renderer 가 그리는 것은 이 파일의 CSS 가 닿지 않는다 ──────────────────────\n *\n * 컬럼 renderer 의 결과는 `ox-card-field` 의 shadow root 안에 그려진다. 이 페이지의 `static\n * styles` 는 그 경계를 넘지 못하므로 `code[figure-type]` 같은 선택자는 **아무 일도 하지 않는다.**\n * 넘어가는 것은 custom property 뿐이라, 색과 글꼴은 여기서 인라인으로 준다 — 값 자체는 테마\n * 토큰을 가리키므로 밝음·어둠은 따라온다. data-grist 의 image renderer 도 같은 방식이다.\n */\nconst CAPACITY = 'font-weight: 700; color: var(--md-sys-color-primary);'\nconst UNMEASURED = 'font-style: italic; color: var(--md-sys-color-outline);'\nconst RELEASED = 'font-weight: 700; color: var(--md-sys-color-primary);'\nconst DRAFT = 'color: var(--md-sys-color-tertiary);'\n/**\n * 조용히 적는 숫자. 낮은 것만 점으로 눈에 걸리게 한다.\n *\n * **`inline-flex` 를 쓰지 않는다.** 썼더니 점이 뜨는 카드에서만 이 값이 옆의 두 값과 밑줄이\n * 어긋났다 — inline-flex 상자의 밑줄은 **첫 항목**에서 오는데, 첫 항목이 글자 없는 점이라\n * 밑줄이 없어 브라우저가 상자 아래를 밑줄로 삼는다. 점이 없는 카드(50 이상)는 멀쩡했으므로\n * 한 줄에 세 값이 나란히 설 때만 눈에 띄었다.\n *\n * 그냥 인라인으로 두면 이 상자의 밑줄이 곧 숫자의 밑줄이라 옆의 둘과 맞는다. 점은 제 몫으로\n * 글자 가운데에 맞춘다.\n */\nconst SCORE = 'font-variant-numeric: tabular-nums;'\nconst LOW_DOT =\n 'display: inline-block; width: 5px; height: 5px; margin-right: 4px; vertical-align: middle; ' +\n 'border-radius: 50%; background-color: var(--md-sys-color-error);'\n\n/*\n * `as typeof PageView` 로 조이지 않는다 — 그렇게 하면 p13n 이 얹어 주는\n * `getPagePreferenceProvider` 가 타입에서 사라져 개인 설정을 붙일 수 없다.\n */\nconst FigureListPageBase = p13n(localize(i18next)(PageView))\n\n/**\n * Figure 카탈로그.\n *\n * 카드를 고르면 상세 패널에서 저장본과 발행판을 살펴본다. 크기와 움직임을 시험한 뒤\n * 「편집 화면 열기」로 저작면에 들어간다. 목록 질의는 자산 원본을 싣지 않는다.\n *\n * ## 왜 손으로 만든 카드가 아니라 격자인가\n *\n * 전에는 카드 격자와 걸러 보기 줄과 빈 화면을 이 파일이 직접 그렸다(200줄). 그 자리에서 빠져\n * 있던 것들은 하나같이 `ox-grist` 가 이미 가진 것이다 — 쪽 나누기, 정렬, 컬럼 걸러 보기,\n * 개인 설정(모드·정렬·쪽 크기를 사람마다 기억한다), 표 모드로 바꿔 보기, 내보내기.\n * 손으로 만든 카드는 그 중 아무것도 없었고, 목록이 늘어나면 전부 한 번에 그렸다.\n *\n * 카드에 실을 것은 `list` 가 정하고, 무엇을 어떻게 그릴지는 컬럼의 renderer 가 정한다. 같은\n * 설정이 표 모드에서도 그대로 쓰이므로 **두 모드가 다른 말을 하지 않는다.**\n */\n@customElement('figure-list-page')\nexport class FigureListPage extends FigureListPageBase {\n static styles = [\n /* The frame owns the page shell; the grist is the content it sizes (ADR-0060 decision 8). */\n WorkSurfacePageStyles,\n ScrollbarStyles,\n CommonGristStyles,\n CommonHeaderStyles,\n CardCatalogStyles,\n css`\n :host {\n background-color: var(--md-sys-color-surface);\n color: var(--md-sys-color-on-surface);\n }\n\n /*\n 카드 · 그림 칸 · 만들기 FAB 는 모든 카드 카탈로그와 같다(@operato/styles CardCatalogStyles,\n ADR-0117 개정 2026-10-13). 여기에는 이 화면에만 있는 것만 둔다.\n */\n ox-grist {\n /* 상태와 성숙도는 짧은 표식이다 — 두 줄로 세우지 않고 한 줄에 뉜다 */\n --data-card-detail-direction: row;\n /* 표 모드의 맨 위로 단추도 만들기 단추 위로 비킨다 */\n --data-list-fab-position-vertical: 64px;\n }\n `\n ]\n\n @property({ type: Object }) gristConfig: any\n\n @query('ox-grist') private grist!: DataGrist\n\n /**\n * The domain's own figures, or other domains' public ones (LV figure-server design G2), read only. Each is a screen\n * of its own on the rail (user 2026-10-19): the own catalogue is where figures are made and changed, the public one\n * only looked at, so a switch inside one list mixed two jobs. `figure-public-list-page` sets it.\n */\n protected readonly scope: 'own' | 'public' = 'own'\n\n private listen?: () => void\n\n get context() {\n return {\n title: i18next.t(this.scope === 'public' ? 'figure.title.public-figures' : 'figure.title.figures'),\n search: {\n handler: (search: string) => {\n this.grist.searchText = search\n },\n value: this.grist?.searchText || '',\n placeholder: i18next.t('figure.text.search-figure')\n },\n filter: {\n handler: () => {\n this.grist.toggleHeadroom()\n }\n }\n /*\n **만들기는 `actions` 가 아니라 FAB 이다.**\n\n `context.actions` 로 두면 페이지 바닥 줄에 글자 단추로 서는데, 그 줄은 「지금 화면에 대해\n 할 일」을 늘어놓는 자리다. 만들기는 이 화면의 유일한 주된 동작이므로 줄에 섞이지 않고\n 떠 있어야 한다. 카드를 가리지 않는 오른쪽 아래, 손이 가는 자리다(아래 render 의 [fab]).\n */\n }\n }\n\n render() {\n return html`\n <ox-grist\n class=\"page-fill\"\n mode=\"CARD\"\n @search-tag=${(e: CustomEvent) => this.findByTag(e.detail.tag)}\n .config=${this.gristConfig}\n .fetchHandler=${this.fetchHandler.bind(this)}\n .personalConfigProvider=${this.getPagePreferenceProvider('ox-grist')!}\n >\n <div slot=\"headroom\" class=\"header\">\n <div class=\"filters\">\n <ox-filters-form autofocus without-search></ox-filters-form>\n </div>\n </div>\n\n <ox-grist-personalizer slot=\"setting\"></ox-grist-personalizer>\n </ox-grist>\n\n ${this.scope === 'own'\n ? html`<button fab title=${i18next.t('figure.button.new-figure')} @click=${() => this.openModeller()}>\n <md-icon>add</md-icon>${i18next.t('figure.button.new-figure')}\n </button>`\n : nothing}\n `\n }\n\n /**\n * 카드의 태그 알약을 눌렀다 — **그 태그로 목록을 거른다.**\n *\n * 검색창에 그 말을 채워 넣는다. 격자에 조건만 걸고 창을 비워 두면 저작자는 **왜 목록이\n * 줄었는지 모른 채** 보게 되고, 되돌리려면 무엇을 지워야 하는지도 알 수 없다.\n *\n * 서버가 `tags` 뿐 아니라 이름·타입·설명·분류를 함께 훑으므로, 그 말이 다른 칸에 든 도형도\n * 같이 온다. 태그만 정확히 거르는 것이 아니라 **찾기**다.\n */\n private findByTag(tag: string) {\n this.grist.searchText = tag\n /* 창의 값은 `context` 에서 나온다 — 다시 알려야 헤더가 새 값을 그린다. */\n this.updateContext()\n }\n\n async pageInitialized() {\n this.gristConfig = {\n /*\n **쪽 나누기는 선택이 아니다.** 격자에 가상 스크롤이 없어 받은 것을 전부 DOM 에 그린다.\n 카드 모드는 끝까지 내려가면 다음 쪽을 이어 붙이므로, 한 쪽이 작아도 목록은 계속 읽힌다.\n */\n pagination: { pages: [24, 48, 96] },\n\n /*\n 아직 아무것도 없을 때 하는 말. **이 자리가 이 화면에서 가장 중요하다** — 처음 온 사람은\n 여기서 이 도구가 무엇을 만드는 것인지 알게 된다. 조건이 걸려 비었을 때는 격자가 스스로\n 다른 말을 한다(「찾는 것이 없다」). 그 둘을 섞지 않는 것이 격자 쪽에 이미 들어 있다.\n */\n emptyNote: {\n icon: 'deployed_code',\n title: i18next.t('figure.text.no-figure-yet'),\n description: i18next.t('figure.text.what-a-figure-is')\n },\n\n list: {\n /* 그림 칸은 그 컬럼의 renderer 가 그린다 — 그림 없을 때의 안내까지 `figure-thumb` 안이다 */\n thumbnail: 'thumbnail',\n fields: ['name', 'type'],\n /*\n ── 무게를 모른 채 고르게 두지 않는다 ────────────────────────────────\n 이름과 그림만 실으면 저작자는 **이 형상이 무거운지 모른 채** 고른다. 그것을 저작면에\n 들어가서야 아는 것은 늦다. 그래서 격자로 옮기기 전 손 카드가 실었던 셋을 그대로 싣는다 —\n 몇 개까지 놓을 수 있나(배치 한도) · 성숙도 · 삼각형 수.\n\n 한 줄에 뉜다(`--data-card-detail-direction: row`). 이름표는 달지 않는다 — 값 자체가\n 「625개까지」·「삼각형 440개」로 읽히고, 성숙도만 숫자 하나여서 손이 갔을 때 이름이 뜬다.\n\n 상태는 이 줄에 없다. 그림 위 초안 표시가 그 일을 한다(`figure-thumb`) — 발행된 것에는\n 아무 말도 하지 않으므로 빈 칸이 생기지 않는다.\n */\n details: ['capacity', 'score', 'triangles']\n },\n\n columns: [\n { type: 'gutter', gutterName: 'sequence', fixed: true },\n {\n /*\n 표 모드에서만 쓰는 삭제 칸. 카드에서는 `figure-thumb` 이 그림 위에 그리므로\n `forList: false` 로 내린다 — 카드 아래 단추 줄은 감춰도 자리가 남는다.\n */\n type: 'gutter',\n gutterName: 'button',\n icon: 'delete',\n title: i18next.t('figure.button.delete-figure'),\n danger: true,\n forList: false,\n width: 40,\n handlers: {\n click: (_columns: any, _data: any, _column: any, record: Figure) => this.removeFigure(record)\n }\n },\n {\n type: 'string',\n name: 'name',\n header: i18next.t('figure.label.name'),\n record: { editable: false },\n filter: 'search',\n sortable: true,\n width: 200\n },\n {\n /*\n 타입 이름은 **저장되는 식별자**다. 표시 이름과 다르게 보이게 두어야 도면이 무엇으로\n 이 형상을 찾는지 헷갈리지 않는다.\n */\n type: 'string',\n name: 'type',\n header: i18next.t('figure.label.figure-type'),\n record: {\n editable: false,\n /* The full name a board stores: {namespace}/{type} (ADR-0114). */\n renderer: (value: string, column: unknown, record: { namespace?: string }) =>\n html`<code>${record?.namespace ? `${record.namespace}/${value}` : value}</code>`\n },\n filter: 'search',\n sortable: true,\n width: 160\n },\n {\n /*\n 태그 — **카드에서 곁줄로 보이고 검색에 걸린다.**\n\n 서버가 이미 `type`·`name`·`description`·`category`·`tags` 를 함께 훑는다. 그런데\n 화면에는 태그가 어디에도 안 보여서, 저작자가 적은 태그가 **자기 눈에 돌아오지 않았다** —\n 적어 둔 것이 쓰이는지 알 수 없으면 아무도 적지 않는다.\n\n 정렬은 걸지 않는다. 배열이라 무엇을 기준으로 줄을 세우는지 답할 수 없다.\n\n **카드에서는 이 컬럼이 그리지 않는다.** 본문에 한 줄로 두었더니 태그가 있는 카드만\n 높아져 격자가 어긋났다 — 개수가 도형마다 다르므로 본문에 두는 한 남는 문제다.\n 카드에서는 `figure-thumb` 이 그림 위에 얹는다. 여기 남은 것은 표 모드의 칸이다.\n */\n type: 'string',\n name: 'tags',\n header: i18next.t('figure.label.tags'),\n record: {\n editable: false,\n renderer: (value: string[] | null) => (value || []).join(' · ')\n },\n filter: 'search',\n sortable: false,\n width: 180\n },\n {\n type: 'string',\n name: 'state',\n header: i18next.t('figure.label.state'),\n record: {\n editable: false,\n /*\n **발행된 것에는 아무 말도 하지 않는다.** 카탈로그에 있는 것은 대개 발행된 것이라,\n 카드마다 「발행됨」이 붙으면 그 말이 아무것도 가르지 않고 자리만 먹는다. 판 번호도\n 고를 때 쓰는 값이 아니다 — 이력 탭에 있다.\n\n 표 모드에서는 칸에 값이 있어야 하므로 그때는 발행됨도 적는다(`wide` 가 아니라 label\n 이 붙는 자리인지로 가른다 — 카드는 label 을 달지 않았다).\n */\n renderer: (value: string, _column: any, record: Figure, _rowIndex: number, field: Element) => {\n if (value !== 'released') {\n return html`<span style=${DRAFT}>${i18next.t('figure.label.draft')}</span>`\n }\n\n /* 표에서는 칸이 비면 안 된다. 카드에서만 입을 다문다 — 그리는 자리가 알려 준다. */\n return field?.tagName === 'OX-CARD-FIELD'\n ? ''\n : html`<span style=${RELEASED}\n >${i18next.t('figure.label.figure-released')}\n ${record.version ? i18next.t('figure.text.version-number', { version: record.version }) : ''}</span\n >`\n }\n },\n /*\n 전체·초안·발행됨을 단추로 고른다 — 값이 둘뿐인 조건을 펼침 목록에 넣지 않는다.\n\n 이름표는 비워 둔다. 단추에 「초안」·「발행됨」이라고 적혀 있으니 그 앞의 「상태」는\n 같은 말을 한 번 더 하는 것이고, 걸러 보기 줄에서 자리만 먹는다.\n */\n /* Another domain's public figures are released ones only: no draft to tell apart, no choice to offer. */\n filter:\n this.scope === 'own'\n ? {\n type: 'select-buttons',\n operator: 'in',\n label: '',\n options: [\n { display: i18next.t('figure.label.draft'), value: 'draft' },\n { display: i18next.t('figure.label.figure-released'), value: 'released' }\n ]\n }\n : undefined,\n width: 120\n },\n {\n /*\n **몇 개까지 놓을 수 있나.** 카드에는 싣지 않고 표 모드의 칸으로 둔다 — 고른 뒤에\n 따지는 값이다. 서버에 없는 값이라 `groups` 와 `triangles` 에서 계산하는데, 저작면\n 머리와 **같은 함수**를 쓴다. 두 화면이 같은 형상을 다른 잣대로 말하면 무엇을 고칠지\n 모른다.\n */\n type: 'string',\n name: 'capacity',\n header: i18next.t('figure.label.placement-limit'),\n sortable: false,\n record: {\n editable: false,\n renderer: (_value: unknown, _column: any, record: Figure) => {\n const capacity = capacityFrom(record.groups ?? 0, record.triangles ?? 0)\n\n return capacity\n ? html`<span style=${CAPACITY} title=${i18next.t('figure.text.reuse-score-explained')}>\n ${i18next.t('figure.text.fits-n-instances', { n: capacity.instances.toLocaleString() })}\n </span>`\n : html`<span style=${UNMEASURED}>${i18next.t('figure.text.not-measured-yet')}</span>`\n }\n },\n width: 120\n },\n {\n type: 'float',\n name: 'score',\n header: i18next.t('figure.label.maturity'),\n record: {\n editable: false,\n /*\n 카드에 남긴 하나뿐인 숫자. **이름표를 달지 않으므로** 무엇인지는 손이 갔을 때 뜨는\n 말이 알려 준다.\n\n 색칠한 배지로 두지 않는다. 옛 draw call 한도 3 으로 재던 때는 카탈로그 거의 모두가 0 점이라\n 붉은 덩어리가 카드마다 섰고 아무것도 가르지 못했다. 이 모델은 「한 화면 N 대」 목표에 견준\n 여유라(`figureScoreOf`, 2026-09-24) 퍼지지만, 숫자는 조용히 적고 낮은 것에만 **점 하나**를 붙인다.\n\n 아직 재지 않은 것을 0 으로 보여 주지 않는다 — 0 은 「가볍다」는 뜻이 되어 버린다.\n 등급 문자(A~D)도 여기서 만들지 않는다: 경계는 `figure-model` 의 `scoreOf` · `figureScoreOf` 가 정하고,\n 화면이 그것을 베끼면 두 벌이 되어 목록과 저작면이 다른 등급을 말한다.\n */\n renderer: (value: number | null) =>\n value == null\n ? html`<span style=${UNMEASURED}>${i18next.t('figure.text.not-measured-yet')}</span>`\n : html`<span style=${SCORE} title=${i18next.t('figure.label.maturity')}>\n ${value < ATTENTION_BELOW ? html`<i style=${LOW_DOT}></i>` : ''}${Math.round(value)}\n </span>`\n },\n sortable: true,\n width: 90\n },\n {\n type: 'integer',\n name: 'triangles',\n header: i18next.t('figure.label.triangles'),\n record: {\n editable: false,\n /*\n 카드에서는 이름표 없이 서므로 숫자만 두면 옆의 성숙도와 구별되지 않는다. 무엇의\n 수인지 값이 스스로 말하게 한다 — 표 모드에서는 머리글이 그 일을 하므로 겹치지만,\n 그 겹침이 카드에서 뜻을 잃는 것보다 낫다.\n */\n renderer: (value: number | null) =>\n value == null ? '' : i18next.t('figure.text.triangle-count', { count: value })\n },\n sortable: true,\n width: 110\n },\n {\n type: 'integer',\n name: 'groups',\n header: i18next.t('figure.label.budget-groups'),\n record: { editable: false },\n hidden: true,\n width: 0\n },\n {\n /*\n **카드의 그림 칸 전체를 이 renderer 가 그린다.**\n\n 기본 image renderer 는 그림만 그리고, 그 위에 얹혀야 하는 것(초안 표시·삭제)은 카드\n 아래 gutter 줄로 밀린다. 격자로 옮기기 전 손 카드가 그것을 그림 위에 두었고 그 편이\n 맞다 — 그래서 그림 칸을 `figure-thumb` 에게 넘긴다. hover 가 필요해 컴포넌트여야\n 하는 사연은 그 파일에 적혀 있다.\n\n `renderEmpty` — 그림이 아직 없는 것도 자리를 지킨다. 그 카드에도 초안 표시와 삭제가\n 있어야 하고, 「그림 없음」이라고 말하는 것도 `figure-thumb` 이 한다.\n */\n type: 'image',\n name: 'thumbnail',\n header: i18next.t('field.thumbnail'),\n record: {\n editable: false,\n align: 'center',\n wide: true,\n renderEmpty: true,\n renderer: (_value: unknown, _column: any, record: Figure) => html`\n <figure-thumb .figure=${record} ?readonly=${this.scope === 'public'} @remove=${() => this.removeFigure(record)}></figure-thumb>\n `\n },\n hidden: true,\n width: 160\n },\n {\n type: 'datetime',\n name: 'updatedAt',\n header: i18next.t('field.updated_at'),\n label: true,\n record: { editable: false },\n sortable: true,\n width: 180\n },\n {\n /*\n `resource-object` 를 쓰지 않는다 — 그 renderer 는 다른 패키지(resource-ui)가 등록하고,\n 등록되지 않은 앱에서는 조용히 글자 renderer 로 떨어져 `[object Object]` 가 된다.\n 이름 하나 꺼내는 일에 그 위험을 질 이유가 없다.\n */\n type: 'string',\n name: 'updater',\n header: i18next.t('field.updater'),\n record: {\n editable: false,\n renderer: (value: { name?: string } | null) => value?.name || ''\n },\n hidden: true,\n width: 120\n }\n ],\n\n rows: {\n selectable: false,\n appendable: false,\n handlers: {\n click: (_columns: any, _data: any, _column: any, record: Figure) => {\n if (record?.id) {\n openFigureDetail(record, this.scope === 'public')\n }\n }\n }\n },\n\n sorters: [{ name: 'updatedAt', desc: true }]\n }\n }\n\n connectedCallback() {\n super.connectedCallback()\n\n /*\n **로그인 정보가 도착하면 다시 불러온다.**\n\n 화면이 서는 것과 프로필이 오는 것은 순서가 정해져 있지 않고, 목록 질의는 로그인된 사람으로\n 나간다. 첫 질의가 프로필보다 앞서면 그 한 번이 실패하고, 그 뒤로 다시 묻는 사람이 없으면\n 화면은 비어 있는 채로 남는다. lite-menu 도 같은 신호로 같은 순서 문제를 푼다\n (`auth.on('profile')` — 그쪽 주석에 그 사연이 적혀 있다).\n */\n this.listen = () => {\n if (this.active) {\n this.grist?.fetch()\n }\n }\n auth.on('profile', this.listen)\n /* A picture chosen in the preview, or a figure retired or brought back: the cards are read again. */\n window.addEventListener(FIGURE_THUMBNAIL_CHANGED, this.cardsChanged)\n window.addEventListener(FIGURE_RETIREMENT_CHANGED, this.cardsChanged)\n window.addEventListener(FIGURE_PUBLIC_CHANGED, this.cardsChanged)\n }\n private cardsChanged = () => {\n if (this.active) this.grist?.fetch()\n }\n\n disconnectedCallback() {\n if (this.listen) {\n auth.off?.('profile', this.listen)\n this.listen = undefined\n }\n window.removeEventListener(FIGURE_THUMBNAIL_CHANGED, this.cardsChanged)\n window.removeEventListener(FIGURE_RETIREMENT_CHANGED, this.cardsChanged)\n window.removeEventListener(FIGURE_PUBLIC_CHANGED, this.cardsChanged)\n super.disconnectedCallback()\n }\n\n async pageUpdated() {\n if (this.active) {\n this.grist.fetch()\n }\n }\n\n /**\n * 걸러 보기·정렬·쪽을 **격자가 만든 그대로** 서버에 넘긴다.\n *\n * 여기서 이름을 바꿔 담으면 격자가 아는 조건과 서버에 가는 조건이 어긋난다. 실패는 격자가\n * 받아 화면에 낸다 — 목록이 비어 있는 것과 못 불러온 것은 다른 사실이다.\n */\n async fetchHandler({ page = 1, limit = 24, sortings = [], filters = [] }: FetchOption) {\n const { items, total } = await fetchFigureList({ page, limit, filters, sortings, scope: this.scope })\n\n return { total: total || 0, records: items || [] }\n }\n\n /** The modeller that can edit this figure, by its format; a new figure starts in (`modeller-route.ts`). */\n private openModeller(figure?: Figure) {\n navigate(modellerPathOf(figure))\n }\n\n /** `remove` 는 HTMLElement 의 메서드다 — 가리면 조용한 결함이 된다. */\n private async removeFigure(figure: Figure) {\n if (this.scope === 'public') return\n // 되돌릴 수 없는 조작이므로 무엇이 사라지는지 이름으로 확인한다\n if (hasBeenReleased(figure)) {\n notify({ level: 'info', message: i18next.t('figure.text.released-figure-not-deletable', { name: figure.name }) })\n return\n }\n const message = i18next.t('figure.text.delete-figure-confirm', { name: figure.name })\n if (!confirm(message)) {\n return\n }\n\n try {\n await deleteFigure(figure.id)\n } catch (e) {\n notify({ level: 'error', message: (e as Error).message })\n return\n }\n this.grist.fetch()\n }\n}\n"]}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { FigureListPage } from './figure-list-page.js';
|
|
2
|
+
/**
|
|
3
|
+
* Other domains' public figures (LV figure-server design G2), a screen of its own on the rail (user 2026-10-19).
|
|
4
|
+
*
|
|
5
|
+
* Looked at only: each shows its latest release and its domain, and nothing on it is changed from here -- no new
|
|
6
|
+
* figure, no delete, no edit (`figure-detail-dock.ts` \`foreign\`). The catalogue's own class with the other scope, so
|
|
7
|
+
* the two lists are one list.
|
|
8
|
+
*/
|
|
9
|
+
export declare class FigurePublicListPage extends FigureListPage {
|
|
10
|
+
protected readonly scope: "public";
|
|
11
|
+
}
|
|
12
|
+
declare global {
|
|
13
|
+
interface HTMLElementTagNameMap {
|
|
14
|
+
'figure-public-list-page': FigurePublicListPage;
|
|
15
|
+
}
|
|
16
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import { customElement } from 'lit/decorators.js';
|
|
3
|
+
import { FigureListPage } from './figure-list-page.js';
|
|
4
|
+
/**
|
|
5
|
+
* Other domains' public figures (LV figure-server design G2), a screen of its own on the rail (user 2026-10-19).
|
|
6
|
+
*
|
|
7
|
+
* Looked at only: each shows its latest release and its domain, and nothing on it is changed from here -- no new
|
|
8
|
+
* figure, no delete, no edit (`figure-detail-dock.ts` \`foreign\`). The catalogue's own class with the other scope, so
|
|
9
|
+
* the two lists are one list.
|
|
10
|
+
*/
|
|
11
|
+
let FigurePublicListPage = class FigurePublicListPage extends FigureListPage {
|
|
12
|
+
constructor() {
|
|
13
|
+
super(...arguments);
|
|
14
|
+
this.scope = 'public';
|
|
15
|
+
}
|
|
16
|
+
};
|
|
17
|
+
FigurePublicListPage = __decorate([
|
|
18
|
+
customElement('figure-public-list-page')
|
|
19
|
+
], FigurePublicListPage);
|
|
20
|
+
export { FigurePublicListPage };
|
|
21
|
+
//# sourceMappingURL=figure-public-list-page.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"figure-public-list-page.js","sourceRoot":"","sources":["../../client/pages/figure-public-list-page.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AAEjD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAA;AAEtD;;;;;;GAMG;AAEI,IAAM,oBAAoB,GAA1B,MAAM,oBAAqB,SAAQ,cAAc;IAAjD;;QACc,UAAK,GAAG,QAAiB,CAAA;IAC9C,CAAC;CAAA,CAAA;AAFY,oBAAoB;IADhC,aAAa,CAAC,yBAAyB,CAAC;GAC5B,oBAAoB,CAEhC","sourcesContent":["import { customElement } from 'lit/decorators.js'\n\nimport { FigureListPage } from './figure-list-page.js'\n\n/**\n * Other domains' public figures (LV figure-server design G2), a screen of its own on the rail (user 2026-10-19).\n *\n * Looked at only: each shows its latest release and its domain, and nothing on it is changed from here -- no new\n * figure, no delete, no edit (`figure-detail-dock.ts` \\`foreign\\`). The catalogue's own class with the other scope, so\n * the two lists are one list.\n */\n@customElement('figure-public-list-page')\nexport class FigurePublicListPage extends FigureListPage {\n protected readonly scope = 'public' as const\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'figure-public-list-page': FigurePublicListPage\n }\n}\n"]}
|
package/dist-client/route.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export default function route(page: string): "figure-
|
|
1
|
+
export default function route(page: string): "figure-list" | "figure-public-list" | "figure-modeller" | undefined;
|
package/dist-client/route.js
CHANGED
|
@@ -3,6 +3,9 @@ export default function route(page) {
|
|
|
3
3
|
case 'figure-list':
|
|
4
4
|
import('./pages/figure-list-page');
|
|
5
5
|
return page;
|
|
6
|
+
case 'figure-public-list':
|
|
7
|
+
import('./pages/figure-public-list-page');
|
|
8
|
+
return page;
|
|
6
9
|
case 'figure-modeller':
|
|
7
10
|
import('./pages/figure-modeller-page');
|
|
8
11
|
return page;
|
package/dist-client/route.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"route.js","sourceRoot":"","sources":["../client/route.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,UAAU,KAAK,CAAC,IAAY;IACxC,QAAQ,IAAI,EAAE,CAAC;QACb,KAAK,aAAa;YAChB,MAAM,CAAC,0BAA0B,CAAC,CAAA;YAClC,OAAO,IAAI,CAAA;QAEb,KAAK,iBAAiB;YACpB,MAAM,CAAC,8BAA8B,CAAC,CAAA;YACtC,OAAO,IAAI,CAAA;IACf,CAAC;AACH,CAAC","sourcesContent":["export default function route(page: string) {\n switch (page) {\n case 'figure-list':\n import('./pages/figure-list-page')\n return page\n\n case 'figure-modeller':\n import('./pages/figure-modeller-page')\n return page\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"route.js","sourceRoot":"","sources":["../client/route.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,UAAU,KAAK,CAAC,IAAY;IACxC,QAAQ,IAAI,EAAE,CAAC;QACb,KAAK,aAAa;YAChB,MAAM,CAAC,0BAA0B,CAAC,CAAA;YAClC,OAAO,IAAI,CAAA;QAEb,KAAK,oBAAoB;YACvB,MAAM,CAAC,iCAAiC,CAAC,CAAA;YACzC,OAAO,IAAI,CAAA;QAEb,KAAK,iBAAiB;YACpB,MAAM,CAAC,8BAA8B,CAAC,CAAA;YACtC,OAAO,IAAI,CAAA;IACf,CAAC;AACH,CAAC","sourcesContent":["export default function route(page: string) {\n switch (page) {\n case 'figure-list':\n import('./pages/figure-list-page')\n return page\n\n case 'figure-public-list':\n import('./pages/figure-public-list-page')\n return page\n\n case 'figure-modeller':\n import('./pages/figure-modeller-page')\n return page\n }\n}\n"]}
|