@things-factory/figure-ui 10.1.208 → 10.1.211
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/modeller/data-interface.ts +5 -5
- package/client/modeller/editor.ts +97 -88
- package/client/modeller/fasten-geometry.ts +2 -1
- package/client/modeller/figure-links.ts +87 -157
- package/client/modeller/figure-size-editor.ts +233 -0
- package/client/modeller/joint-drag.ts +25 -21
- package/client/modeller/joint-fan.ts +4 -3
- package/client/modeller/links.ts +87 -36
- package/client/modeller/live.ts +33 -0
- package/client/modeller/motion-ends.ts +10 -6
- package/client/modeller/size-response.ts +95 -0
- package/dist-client/modeller/data-interface.d.ts +1 -1
- package/dist-client/modeller/data-interface.js +5 -5
- package/dist-client/modeller/data-interface.js.map +1 -1
- package/dist-client/modeller/editor.d.ts +14 -1
- package/dist-client/modeller/editor.js +103 -89
- package/dist-client/modeller/editor.js.map +1 -1
- package/dist-client/modeller/fasten-geometry.js +1 -1
- package/dist-client/modeller/fasten-geometry.js.map +1 -1
- package/dist-client/modeller/figure-links.d.ts +3 -4
- package/dist-client/modeller/figure-links.js +91 -145
- package/dist-client/modeller/figure-links.js.map +1 -1
- package/dist-client/modeller/figure-size-editor.d.ts +29 -0
- package/dist-client/modeller/figure-size-editor.js +262 -0
- package/dist-client/modeller/figure-size-editor.js.map +1 -0
- package/dist-client/modeller/joint-drag.d.ts +1 -1
- package/dist-client/modeller/joint-drag.js +27 -22
- package/dist-client/modeller/joint-drag.js.map +1 -1
- package/dist-client/modeller/joint-fan.js +4 -3
- package/dist-client/modeller/joint-fan.js.map +1 -1
- package/dist-client/modeller/links.d.ts +21 -9
- package/dist-client/modeller/links.js +85 -35
- package/dist-client/modeller/links.js.map +1 -1
- package/dist-client/modeller/live.d.ts +14 -0
- package/dist-client/modeller/live.js +31 -0
- package/dist-client/modeller/live.js.map +1 -1
- package/dist-client/modeller/motion-ends.d.ts +4 -1
- package/dist-client/modeller/motion-ends.js +10 -6
- package/dist-client/modeller/motion-ends.js.map +1 -1
- package/dist-client/modeller/size-response.d.ts +29 -0
- package/dist-client/modeller/size-response.js +99 -0
- package/dist-client/modeller/size-response.js.map +1 -0
- package/dist-client/tsconfig.tsbuildinfo +1 -1
- package/docs/evidence/2026-10-24/current-size-panel.png +0 -0
- package/docs/evidence/2026-10-24/integrated-size.png +0 -0
- package/docs/evidence/2026-10-24/multipart-response.png +0 -0
- package/docs/evidence/2026-10-24/repeat-layout.png +0 -0
- package/docs/evidence/2026-10-24/repeat-shared-style.png +0 -0
- package/docs/evidence/2026-10-24/size-in-layout.png +0 -0
- package/docs/evidence/2026-10-24/size-shared-style.png +0 -0
- package/docs/evidence/2026-10-24/width-preview.png +0 -0
- package/docs/multipart-response-review-2026-10-24.md +77 -0
- package/docs/response-authoring-2026-10-24.md +46 -0
- package/docs/size-and-repeat-ux-2026-10-24.md +67 -0
- package/package.json +7 -7
- package/test/attachment-size-contract.test.ts +47 -0
- package/test/browser/acceptance-page.js +1 -1
- package/test/browser/detail-page.js +1 -1
- package/test/browser/detail-tabs-page.js +1 -1
- package/test/browser/editing-page.js +1 -1
- package/test/browser/editing.check.mjs +66 -14
- package/test/browser/links.check.mjs +41 -22
- package/test/browser/modeller-page.js +1 -1
- package/test/browser/modeller-revision.check.mjs +21 -7
- package/test/browser/modeller.check.mjs +106 -39
- package/test/browser/multipart-response-page.js +8 -0
- package/test/browser/parts.check.mjs +2 -1
- package/test/browser/product-page.js +1 -1
- package/test/browser/props.check.mjs +17 -14
- package/test/browser/response-page.js +12 -0
- package/test/browser/row-preview.check.mjs +3 -3
- package/test/browser/screen.check.mjs +57 -13
- package/test/browser/serve-response.mjs +24 -0
- package/test/clip-ai-proposal.test.ts +1 -1
- package/test/clip-consent.test.ts +2 -2
- package/test/command-preview.test.ts +7 -7
- package/test/joint-drag.test.ts +6 -6
- package/test/joint-frames.test.ts +33 -32
- package/test/joints.ts +1 -6
- package/test/links.test.ts +60 -20
- package/test/multipart-response-fixture.js +17 -0
- package/test/multipart-response.test.ts +37 -0
- package/test/refusals.test.ts +2 -2
- package/test/resize-with-placement.test.ts +23 -1
- package/test/size-response.test.ts +49 -0
- package/test/size-source-pairing.test.ts +66 -0
- package/translations/en.json +47 -10
- package/translations/es.json +47 -10
- package/translations/ja.json +47 -10
- package/translations/ko.json +52 -15
- package/translations/ms.json +47 -10
- package/translations/zh.json +47 -10
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"figure-links.js","sourceRoot":"","sources":["../../client/modeller/figure-links.ts"],"names":[],"mappings":";AAAA,OAAO,4BAA4B,CAAA;AAEnC,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,KAAK,CAAA;AACpD,OAAO,2CAA2C,CAAA;AAClD,OAAO,+BAA+B,CAAA;AACtC,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAA;AAElE,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AACjD,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAA;AAG7D,OAAO,EACL,SAAS,EACT,IAAI,EACJ,SAAS,EACT,SAAS,EACT,eAAe,EACf,cAAc,EACd,eAAe,EACf,QAAQ,EACR,aAAa,EACb,MAAM,EACN,QAAQ,EACR,WAAW,EACX,oBAAoB,EACpB,WAAW,EACX,eAAe,EACf,WAAW,EACX,UAAU,EACV,QAAQ,EACR,YAAY,EACZ,mBAAmB,EACnB,aAAa,EACb,WAAW,EACX,YAAY,EACZ,UAAU,EACV,QAAQ,EACR,SAAS,EACT,UAAU,EACV,YAAY,EACZ,KAAK,EACL,kBAAkB,EAClB,UAAU,EAIX,MAAM,YAAY,CAAA;AACnB,OAAO,EAAE,eAAe,EAAE,MAAM,gEAAgE,CAAA;AAChG,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAA;AACxD,OAAO,EAAE,YAAY,EAAE,Y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E,OAAO,EAAE,CAAC;;2CAAc;AAEV;IAA/B,QAAQ,CAAC,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;;iDAA4B;AAE3B;IAA/B,QAAQ,CAAC,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;;+CAAsF;AAErF;IAA/B,QAAQ,CAAC,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;;kDAA6B;AAE5B;IAA/B,QAAQ,CAAC,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;;iDAA4B;AAE3B;IAA/B,QAAQ,CAAC,EAAE,SAAS,EAAE,KAAK,EAAE,CAAC;;gDAA2B;AAQzC;IAAhB,KAAK,EAAE;;4CAAwB;AAIf;IAAhB,KAAK,EAAE;;4CAAqB;AACZ;IAAhB,KAAK,EAAE;;2CAA2C;AAClC;IAAhB,KAAK,EAAE;;0CAA6B;AAEpB;IAAhB,KAAK,EAAE;;6CAAkC;AACzB;IAAhB,KAAK,EAAE;;wCAAyB;AAEhB;IAAhB,KAAK,EAAE;;kDAA8B;AArH3B,WAAW;IADvB,aAAa,CAAC,cAAc,CAAC;GACjB,WAAW,CAsxBvB","sourcesContent":["import '@material/web/icon/icon.js'\n\nimport { css, html, LitElement, nothing } from 'lit'\nimport '@operato/input/ox-input-select-buttons.js'\nimport './figure-slot-layout-panel.js'\nimport { customElement, property, state } from 'lit/decorators.js'\n\nimport { i18next, localize } from '@operato/i18n'\nimport { figureFaceOverhangOf } from '@hatiolab/figure-model'\nimport type { FigureAsset, FigureAuthoringAction, FigureDimensionSource, FigureFace } from '@hatiolab/figure-model'\n\nimport {\n acceptsOf,\n AXES,\n canFasten,\n canFollow,\n followCommandOf,\n followableAxes,\n positionIsShare,\n choiceOf,\n followWordsOf,\n heldBy,\n followOf,\n shownWhenOf,\n visibilityControlsOf,\n fasteningOf,\n hasInstanceSize,\n holdsThings,\n leadersFor,\n motionOf,\n motionFormOf,\n motionFormRefusalOf,\n endPlaceKeyOf,\n motionJoint,\n placeFacesOf,\n placeIdFor,\n placesOn,\n rowAxesOf,\n rowBlockOf,\n fixedJointOf,\n rowOf,\n positionsWorkedOut,\n measureNow,\n type Axis,\n type Follow,\n type MotionForm\n} from './links.js'\nimport { SidePanelStyles } from '@things-factory/figure-viewer/dist-client/side-panel-styles.js'\nimport { insideAlignmentOf } from './fasten-geometry.js'\nimport { fastenFormOf, fastenPlanOf, fastenSentenceOf } from './fasten-form.js'\nimport type { FigureRevision } from './revision.js'\nimport { HelpToggles } from './help.js'\nimport { groupMenu, GroupMenuStyles } from './group-menu.js'\nimport { jointAxisWord } from './joint-axis.js'\nimport { placeTerms } from '@things-factory/figure-viewer/dist-client/detail-facts.js'\n\nconst freshMotion = (): MotionForm => ({ kind: 'slide', axis: 'x', id: '', min: 0, max: 500, follow: '', multiplier: 1, offset: 0, travel: '', travelPlus: 0 })\nconst freshRow = () => ({ axis: '' as Axis | '', pitch: 200, fills: true, count: 5 })\nconst freshPlace = () => ({ role: 'grip' as 'seat' | 'grip', face: 'top' as FigureFace, label: '', accepts: '', capacity: 1 })\n\n/**\n * What a part is tied to — its size response, what it is fastened to, how it moves.\n *\n * 「Build Once, Fit Anywhere」 lives here: a dimension that follows the instance size or another part is what lets\n * a figure be placed at any size, and a part fastened to the face it rests on is what keeps it there when that\n * happens. The release gate refuses a figure that falls apart when resized, and tells the author to fasten the\n * parts that come away — this is where they do it. Motion is a joint: a slide or a turn driven by a control.\n *\n * The sections are dimensions, placement and joint, in that order. Every\n * change is one figure-model authoring command, sent as `command` and run by the editor through the session — one\n * step of the undo history. The fastening is said here in one line; it is chosen in the fastening window\n * (`figure-fasten-dialog.ts`), which the editor opens when this asks (`fasten-open`). Choices the command would refuse (a round body fastened, a size following an instance\n * size the figure does not declare) are not offered, so the author is not sent into a refusal.\n */\n@customElement('figure-links')\nexport class FigureLinks extends localize(i18next)(LitElement) {\n private readonly help = new HelpToggles(this)\n static styles = [SidePanelStyles, GroupMenuStyles, css`\n :host {\n display: block;\n }\n /* A group's sub-question, under its title: quieter than the title, as a label is. */\n p[group-question] {\n margin: 4px 0 0;\n color: var(--md-sys-color-on-surface-variant);\n }\n /* The fastening a part has, in one line, and 「바꾸기」 at its end. */\n div[fastened-summary] {\n display: flex;\n align-items: center;\n gap: 8px;\n }\n div[fastened-summary] > p {\n flex: 1;\n margin: 0;\n }\n /* Opening the form is an action: the primary colour, at the line's end. */\n div[fastened-summary] > button[act] {\n flex: none;\n margin: 0 -6px 0 0;\n }\n /* The measure's name, then its rule: X, or a cylinder's 반지름 · 길이, on one line. */\n div[row] > b {\n white-space: nowrap;\n }\n div[row] {\n display: grid;\n grid-template-columns: minmax(24px, max-content) minmax(0, 1fr);\n gap: 6px;\n align-items: center;\n }\n b[bound] {\n font-weight: 600;\n }\n /* What each direction does now: read-only rows. */\n div[resize-now] { display: grid; gap: 4px; margin: 12px 0; }\n div[resize-now] div[row] { grid-template-columns: 1fr auto auto auto; align-items: center; gap: 8px; }\n div[resize-now] span[measure] { font-variant-numeric: tabular-nums; }\n /* Size behaviour is a choice about dimensions only. It never implies a placement or a fastening. */\n /* One of the size group's rows: the group's gap spaces it, as it does the rest (a margin on top of it left a hole). */\n details[resize-choice] { margin: 0; padding: 0; border: 0; }\n details[resize-choice] > div { display: grid; gap: 8px; padding: 8px 0; }\n p[fasten-mode] { margin: 0; font-weight: 600; }\n details { margin-top: 8px; }\n details[row-fold] { margin: 0; }\n details[row-fold] > summary { padding: 0; color: var(--md-sys-color-on-surface); }\n details[row-fold] > summary h3 { margin: 0; }\n details[row-fold][open] > summary { margin-bottom: 8px; }\n /* What the command would do, said beside the result drawn on the canvas. */\n ul[preview-words] { margin: 8px 0; padding: 8px 12px 8px 26px; border-radius: 6px; background: var(--md-sys-color-surface-container, #8881); display: grid; gap: 4px; }\n p[preview-words] { margin: 8px 0; padding: 8px 12px; border-radius: 6px; background: var(--md-sys-color-surface-container, #8881); }\n div[row-basis] { display: grid; gap: 4px; margin: 8px 0; }\n div[row-basis] label { display: flex; align-items: center; gap: 6px; }\n div[overhang] { display: grid; gap: 6px; margin: 8px 0; padding: 8px 12px; border-radius: 6px; border: 1px solid var(--md-sys-color-outline-variant, #8884); }\n div[overhang] p { margin: 0; }\n ul[detach-words] { margin: 4px 0 10px; padding-left: 20px; display: grid; gap: 2px; }\n /* The difference a following measure keeps: under its choice, on the same line as its words. */\n label[inline-plus] {\n display: flex;\n align-items: center;\n gap: 6px;\n }\n label[inline-plus] input {\n flex: 1;\n min-width: 0;\n }\n `]\n\n /** The figure at the version on screen. */\n @property({ attribute: false }) revision?: FigureRevision\n private get asset(): FigureAsset | undefined {\n return this.revision?.asset\n }\n /** The selected part. */\n @property() partId = ''\n @property({ type: Boolean }) locked = false\n /** Which ties this shows: the part's shape (size and placement, in 속성), its places (자리·능력) or its motion (움직임). */\n @property() section: 'shape' | 'response' | 'places' | 'motion' = 'shape'\n /**\n * Its tab is the one shown, and no window over it speaks instead. The response's row speaks of what a command would\n * draw, and the properties' says there is none: only the one in sight may, as the hidden one's silence would clear what\n * the shown one draws. While the fastening window is open it alone speaks (the editor sets this false).\n */\n @property({ type: Boolean }) active = true\n /** What the row's command would do, in words (the editor works it out: `command-preview.ts`). */\n @property({ attribute: false }) previewWords: string[] = []\n /** Where the selected part's motion takes it, at both ends of its range (the editor draws them on the canvas). */\n @property({ attribute: false }) motionEnds: { control: string; min: number; max: number; unit: string } | null = null\n /** Past the edge of the face it is fastened to, or parts fastened to it past theirs (ADR-0097 §5.5, Q3). */\n @property({ attribute: false }) overhangWords: string[] = []\n /** Wider than the face it is fastened to: how far past each edge, and whether off to one side -- a fact, not a warning. */\n @property({ attribute: false }) overhangNote: string[] = []\n /** What taking this part off would do, said beside the buttons that do it (worked out on a copy by the editor). */\n @property({ attribute: false }) detachWords: string[] = []\n /*\n What a section speaks of on the canvas: the response's row while its fold is open; the properties', the fastening the\n part has -- its face lit, as the one-line result says it.\n */\n private candidate?: { action: FigureAuthoringAction; face?: { part: string; face: string } }\n private fastenCandidate?: { action: FigureAuthoringAction; face?: { part: string; face: string } }\n private told = ''\n @state() private rowOpen = false\n private rowCandidate?: FigureAuthoringAction\n\n /** Why 정렬·간격 고치기 moved nothing, said under it; empty once it moved the part or the part changed. */\n @state() private fixNote = ''\n @state() private motion: MotionForm = freshMotion()\n @state() private place = freshPlace()\n /** How places are made here: one at a time, or by the figure's rule. Unset: by the rule when the figure has one. */\n @state() private placesBy?: 'one' | 'rule'\n @state() private row = freshRow()\n /** The motion form is open over the part's own motion, to change it where it is. */\n @state() private editingMotion = false\n\n /*\n The forms describe the next command for the selected part, so another part starts from the defaults: carrying the\n last part's choices over fastened a shutter curtain level with a right edge nobody chose for it (2026-09-25).\n */\n /* The part the forms were loaded for. A panel made with a part already chosen loaded nothing, and said \"editing the\n fastening it has\" over an empty target (2026-09-27, :3391, the doors). */\n private loadedFor?: string\n willUpdate(changed: Map<string, unknown>) {\n /* Its tab shown again: what it would draw is said again, over whatever the other tab left. */\n if (changed.has('active') && this.active && changed.get('active') === false) this.told = ''\n /* What 고치기 said is about the figure as it was: another step or another part, and it no longer holds. */\n if (changed.has('asset') || changed.has('partId')) this.fixNote = ''\n if (this.asset && this.partId && this.partId !== this.loadedFor) {\n this.loadedFor = this.partId\n this.motion = freshMotion()\n this.place = freshPlace()\n this.row = freshRow()\n this.editingMotion = false\n }\n }\n\n updated() {\n /* Only the sections that hold a form speak of what it would do, and only while their tab is shown: the panel has\n one of these per section, and the others' silence cleared what it showed (2026-09-27, :3391). */\n const speaks = this.active && (this.section === 'shape' || this.section === 'response')\n if (!speaks) return\n const said = JSON.stringify(this.candidate ?? null)\n if (said === this.told) return\n this.told = said\n this.dispatchEvent(new CustomEvent('preview-command', { detail: this.candidate ?? null, bubbles: true, composed: true }))\n }\n\n disconnectedCallback() {\n super.disconnectedCallback()\n /* The panel left: what it showed goes with it. */\n if (this.told && this.told !== 'null') this.dispatchEvent(new CustomEvent('preview-command', { detail: null, bubbles: true, composed: true }))\n this.told = ''\n }\n\n render() {\n const asset = this.asset\n this.candidate = undefined\n this.fastenCandidate = undefined\n this.rowCandidate = undefined\n if (!asset || !this.partId) return nothing\n if (this.section === 'motion')\n return html`<section><h3>${i18next.t('figure.label.motion')}${this.help.button('figure.text.motion-explained')}</h3>${this.help.hint('figure.text.motion-explained')}\n ${this.renderMotion(asset)}${this.renderShown(asset)}</section>`\n if (this.section === 'places') {\n /*\n One idea, places, two ways to make them (ADR-0118): one at a time on this part, or many by a rule -- the figure's\n slot layout. One section with a choice, not two screens for the same thing (chief architect, 2026-10-11).\n */\n const byRule = (this.placesBy ?? (asset.document.capabilities.slotLayout ? 'rule' : 'one')) === 'rule'\n return html`<section><h3>${i18next.t('figure.label.places-on-part', { part: this.partId })}${this.help.button('figure.text.place-explained')}</h3>${this.help.hint('figure.text.place-explained')}\n <ox-input-select-buttons\n places-by\n .value=${byRule ? 'rule' : 'one'}\n .options=${[\n { value: 'one', display: i18next.t('figure.label.places-one') },\n { value: 'rule', display: i18next.t('figure.label.places-by-rule') }\n ]}\n @change=${(e: CustomEvent) => (this.placesBy = e.detail === 'rule' ? 'rule' : 'one')}\n ></ox-input-select-buttons>\n ${byRule\n ? html`<figure-slot-layout-panel .asset=${asset} .partId=${this.partId} ?locked=${this.locked}></figure-slot-layout-panel>`\n : placeFacesOf(asset, this.partId).length\n ? this.renderPlaces(asset)\n : html`<p hint>${i18next.t('figure.text.places-need-a-box')}</p>`}</section>`\n }\n /*\n Three groups in one order whatever the part's state (chief architect 2026-10-16): its size, its place, its row. The\n editor's own numbers go in through the slots, so a group keeps its place when a rule or a fastening takes them over.\n */\n /* Fastened, by a face or by an origin: either can be taken off, from the place group's 「⋯」. */\n const held = !!heldBy(asset, this.partId) || !!(this.revision && fasteningOf(this.revision, this.partId)?.atOrigin)\n if (this.section === 'response') {\n /*\n How the part answers a size it is placed at (user 2026-10-17, the 「반응형」 tab): its own measures, where it\n stands, and the row it may make -- what Build Once, Fit Anywhere is authored with, in one place.\n */\n const positions = positionsWorkedOut(asset, this.partId)\n const response = html`\n <section size-response>\n <h3>${i18next.t('figure.label.group-size')}</h3>\n <p group-question>${i18next.t('figure.label.resize-intent')}</p>\n ${canFollow(asset, this.partId) ? this.renderDimensions(asset) : html`<p hint>${i18next.t('figure.text.part-cannot-follow')}</p>`}\n </section>\n ${positions.length\n ? html`<section position-response>\n <h3>${i18next.t('figure.label.group-position-response')}</h3>\n ${this.renderPositions(asset)}\n </section>`\n : nothing}\n ${rowOf(asset, this.partId) ? html`<slot name=\"row\"></slot>` : this.renderRow(asset)}\n `\n this.candidate = this.rowOpen && this.rowCandidate ? { action: this.rowCandidate } : undefined\n return response\n }\n const shown = html`\n <section size>\n <h3>${i18next.t('figure.label.group-size')}</h3>\n <slot name=\"size\"></slot>\n </section>\n <section fastening>\n <h3>\n ${i18next.t('figure.label.group-place')}${this.help.button('figure.text.fastening-explained')}\n ${groupMenu([{ label: i18next.t('figure.button.detach'), icon: 'link_off', disabled: this.locked || !held, run: () => this.command({ kind: 'detach', part: this.partId }) }])}\n </h3>${this.help.hint('figure.text.fastening-explained')}\n <slot name=\"place\"></slot>\n ${canFasten(asset, this.partId) ? this.renderFastening(asset) : html`<p hint>${i18next.t('figure.text.part-cannot-fasten')}</p>`}\n </section>\n `\n this.candidate = this.fastenCandidate\n return shown\n }\n\n /** Where things are held on this part: a seat things rest on, or a grip things are held in. */\n private renderPlaces(asset: FigureAsset) {\n const faces = placeFacesOf(asset, this.partId)\n const p = this.place\n const face = faces.includes(p.face) ? p.face : faces[0]!\n const accepts = acceptsOf(p.accepts)\n const capacityOk = Number.isSafeInteger(p.capacity) && p.capacity >= 1\n const roleName = (role: string) => i18next.t('figure.label.place-' + role)\n return html`\n ${placesOn(asset, this.partId).map(\n one => html`<div pair>\n <span>\n <b bound>${one.label}</b>\n <small>${one.face ? i18next.t('figure.label.face-' + one.face) + ' · ' : ''}${placeTerms(one, (key, params) => i18next.t(key, params))}</small>\n </span>\n <button quiet ?disabled=${this.locked} @click=${() => this.command({ kind: 'remove-binding', id: one.id })}>\n <md-icon>close</md-icon>${i18next.t('figure.button.remove-place')}\n </button>\n </div>`\n )}\n ${holdsThings(asset)\n ? nothing\n : html`<p hint>${i18next.t('figure.text.place-needs-holding')}</p>\n <button act ?disabled=${this.locked} @click=${() => this.declareHolding(asset)}>\n <md-icon>inventory_2</md-icon>${i18next.t('figure.button.declare-holding')}\n </button>`}\n <div pair>\n <select @change=${(e: Event) => (this.place = { ...p, role: (e.target as HTMLSelectElement).value as 'seat' | 'grip' })}>\n <option value=\"grip\" ?selected=${p.role === 'grip'}>${roleName('grip')}</option>\n <option value=\"seat\" ?selected=${p.role === 'seat'}>${roleName('seat')}</option>\n </select>\n <select @change=${(e: Event) => (this.place = { ...p, face: (e.target as HTMLSelectElement).value as FigureFace })}>\n ${faces.map(one => html`<option value=${one} ?selected=${one === face}>${i18next.t('figure.label.face-' + one)}</option>`)}\n </select>\n </div>\n <div form>\n <span>${i18next.t('figure.label.place-name')}</span>\n <input .value=${p.label} placeholder=${roleName(p.role)} @change=${(e: Event) => (this.place = { ...p, label: (e.target as HTMLInputElement).value })} />\n <span>${i18next.t('figure.label.place-accepts')}</span>\n <input .value=${p.accepts} placeholder=\"BOX, TOTE\" @input=${(e: Event) => (this.place = { ...p, accepts: (e.target as HTMLInputElement).value })} />\n <span>${i18next.t('figure.label.place-capacity')}</span>\n <input type=\"number\" min=\"1\" step=\"1\" .value=${String(p.capacity)} @change=${(e: Event) => (this.place = { ...p, capacity: (e.target as HTMLInputElement).valueAsNumber })} />\n </div>\n ${accepts.length ? nothing : html`<small>${i18next.t('figure.text.place-accepts-needed')}</small>`}\n <button\n act\n ?disabled=${this.locked || !accepts.length || !capacityOk}\n @click=${() =>\n this.command({\n kind: 'add-binding',\n id: placeIdFor(asset, this.partId, p.role),\n label: p.label.trim() || roleName(p.role),\n role: p.role,\n part: this.partId,\n face,\n accepts,\n capacity: p.capacity\n })}\n >\n <md-icon>back_hand</md-icon>${i18next.t('figure.button.add-place')}\n </button>\n `\n }\n\n /** The figure holds things: `Capacity` and `Holdable`, the ladder's middle rung. One part edit, one undo step. */\n private declareHolding(asset: FigureAsset) {\n const names = [...new Set([...(asset.document.capabilities.names ?? []), 'Capacity', 'Holdable'])]\n this.dispatchEvent(new CustomEvent('part-edit', { detail: { edit: { kind: 'set-capabilities', names } }, bubbles: true, composed: true }))\n }\n\n private renderDimensions(asset: FigureAsset) {\n const editable = followableAxes(asset, this.partId)\n const round = editable.length === 2\n const word = (axis: Axis) => i18next.t(round && axis === 'x' ? 'figure.label.resize-diameter' : `figure.label.resize-${axis}`)\n const others = asset.appearance.map(look => look.target).filter(one => one !== this.partId && canFollow(asset, one))\n const followsAll = editable.every(axis => followOf(asset, this.partId, axis).of === 'instance')\n /* A size of its own on every axis is the usual: nothing to read, only the way to make it follow (user 2026-10-01). */\n const allOwn = editable.every(axis => followOf(asset, this.partId, axis).of === 'own')\n return html`${asset.sizing === 'uniform' ? html`<p hint>${i18next.t('figure.text.resize-uniform-warning')}</p>` : nothing}\n ${allOwn ? nothing : html`<div resize-now>${editable.map(axis => {\n const now = followOf(asset, this.partId, axis)\n const following = now.of === 'instance' && now.axis === axis\n const custom = now.of !== 'own' && !following\n const mm = measureNow(this.revision!, this.partId, axis)\n return html`<div row>\n <b>${word(axis)}</b>\n <span measure>${mm === undefined ? '—' : `${Math.round(mm)} mm`}</span>\n <span>${custom ? followWordsOf(now, (key, params) => i18next.t(key, params)) : i18next.t(following ? 'figure.label.resize-following' : 'figure.label.follows-nothing')}</span>\n ${following\n ? html`<button quiet resize-unfollow=${axis} ?disabled=${this.locked}\n @click=${() => {\n this.follow(axis, 'own', now)\n }}>${i18next.t('figure.button.resize-unfollow')}</button>`\n : nothing}\n </div>`\n })}</div>`}\n ${followsAll\n ? nothing\n : html`<button act follow-size ?disabled=${this.locked || asset.sizing === 'uniform'} @click=${() => this.command({ kind: 'follow-size', part: this.partId })}>\n <md-icon>open_in_full</md-icon>${i18next.t('figure.button.follow-size')}\n </button>`}\n <details resize-choice><summary>${i18next.t('figure.label.resize-advanced')}</summary><div>${followableAxes(asset, this.partId).map(axis => {\n const now = followOf(asset, this.partId, axis)\n const value = choiceOf(now)\n /* A cylinder's two measures are its radius and its length; its X and Y name them. */\n const name = round ? i18next.t(axis === 'x' ? 'figure.label.field-radius' : 'figure.label.field-length') : axis.toUpperCase()\n return html`<div row>\n <b>${name}</b>\n <select ?disabled=${this.locked} @change=${(e: Event) => this.follow(axis, (e.target as HTMLSelectElement).value, now)}>\n <option value=\"own\" ?selected=${value === 'own'}>${i18next.t('figure.label.follows-nothing')}</option>\n ${AXES.filter(one => hasInstanceSize(asset, one)).map(\n one => html`<option value=${`share:${one}`} ?selected=${value === `share:${one}`}>\n ${i18next.t('figure.label.follows-instance-share', { axis: one.toUpperCase() })}\n </option>\n <option value=${`instance:${one}`} ?selected=${value === `instance:${one}`}>\n ${i18next.t('figure.label.follows-instance', { axis: one.toUpperCase() })}\n </option>`\n )}\n ${others.flatMap(other =>\n AXES.map(\n one => html`<option value=${`part:${other}:${one}`} ?selected=${value === `part:${other}:${one}`}>${i18next.t('figure.label.follows-part-axis', { part: other, axis: one.toUpperCase() })}</option>`\n )\n )}\n ${now.of === 'expression' || now.of === 'input'\n ? html`<option value=${value} selected>${now.of === 'input' ? now.input : i18next.t('figure.label.follows-expression')}</option>`\n : nothing}\n </select>\n ${now.of === 'instance' || now.of === 'part'\n ? html`<span></span>\n <label inline-plus>\n ${i18next.t('figure.label.follows-plus')}\n <input\n type=\"number\"\n step=\"any\"\n ?disabled=${this.locked}\n .value=${String(now.plus ?? 0)}\n @change=${(e: Event) => this.followPlus(axis, now, Number((e.target as HTMLInputElement).value) || 0)}\n />\n </label>`\n : nothing}\n </div>`\n })}</div></details>`\n }\n\n /**\n * 정렬·간격 고치기: the part moved inside the face it is fastened on, as one step -- the least move on each side it is\n * out, or centred when it is wider than the face. When nothing of it can be moved, why is said under the button, not\n * nothing at all (:3300, 2026-10-11: the button only scrolled to the drawing, which was already in view). The command\n * is the fastening window's for the same choice (`fasten-form.ts`), with only the place across the face changed.\n */\n private fixAlignment() {\n const revision = this.revision\n if (!revision) return\n const form = fastenFormOf(revision, this.partId)\n /* Whether it is out, and the least move that brings it in, are the kernel's measure (ADR-0140 3.8). */\n const own = figureFaceOverhangOf(revision.asset, this.partId, revision.inputs)\n const fixed =\n own?.state === 'unknown'\n ? ({ cannot: 'unmeasured' } as const)\n : own?.state === 'out' || own?.state === 'possible'\n ? insideAlignmentOf(fastenPlanOf(revision, this.partId, form).view, form.align, form.alignMm)\n : ({ cannot: 'inside' } as const)\n if ('cannot' in fixed) {\n this.fixNote = i18next.t(`figure.text.fix-alignment-${fixed.cannot}`, { part: this.partId, on: form.target })\n return\n }\n this.fixNote = ''\n const action = fastenPlanOf(revision, this.partId, { ...form, align: fixed.align, alignMm: fixed.alignMm }).action\n if (action) this.command(action)\n }\n\n /** The fastening window, asked of the editor: it opens over the canvas on what the part has now. */\n private openFastening() {\n this.dispatchEvent(new CustomEvent('fasten-open', { bubbles: true, composed: true }))\n }\n\n /**\n * What holds the part, said as its state -- 「바닥에 붙어 있음」 -- with the ways to change it: open the fastening,\n * or take it off. Right after \"follow size, attached\" this is the result, not a refusal (designer 2026-09-27).\n */\n private heldWords(asset: FigureAsset) {\n const joint = (asset.joints ?? []).find(j => j.body1.part === this.partId)\n const gap = joint?.origin?.gap ?? 0\n const place = i18next.t(`figure.label.resize-place-${asset.placement ?? 'floor'}`)\n const where = !joint\n ? i18next.t('figure.text.held-by-rule')\n : 'plane' in joint.body0\n ? typeof gap === 'number'\n ? i18next.t('figure.text.held-on-plane', { place, gap: String(gap) })\n : i18next.t('figure.text.held-on-plane-worked-out', { place })\n : i18next.t('figure.text.held-on-part', { other: joint.body0.part, otherFace: i18next.t(endPlaceKeyOf(joint.body0)) })\n return where\n }\n\n /** The same source, the same share, a new difference: a leaf the opening less its gaps (link-dimension's `plus`). */\n private followPlus(axis: Axis, now: Follow, plus: number) {\n if (now.of !== 'instance' && now.of !== 'part') return\n if ((now.plus ?? 0) === plus) return\n const source: FigureDimensionSource = now.of === 'instance' ? { of: 'instance', axis: now.axis } : { of: 'part', part: now.part, axis: now.axis }\n const times = now.of === 'instance' ? now.times : (now.times ?? 1)\n this.command({ kind: 'link-dimension', part: this.partId, axis, source, ...(times !== 1 ? { times } : {}), ...(plus ? { plus } : {}), replace: true })\n }\n\n private follow(axis: Axis, choice: string, now: Follow) {\n const action = followCommandOf(this.revision!, this.partId, axis, choice, now)\n if (action) this.command(action)\n }\n\n /**\n * Positions worked out from other values, each with the way to\n * keep it where it is. This is the way out the release gate names when a resize leaves a part in the air.\n */\n private renderPositions(asset: FigureAsset) {\n return positionsWorkedOut(asset, this.partId).map(\n axis => html`<div pair>\n <span>${axis.toUpperCase()} · ${i18next.t(positionIsShare(asset, this.partId, axis) ? 'figure.label.position-in-proportion' : 'figure.label.position-worked-out')}</span>\n <button act ?disabled=${this.locked} @click=${() => this.command({ kind: 'fix-position', part: this.partId, axis })}>\n <md-icon>push_pin</md-icon>${i18next.t('figure.button.fix-position')}\n </button>\n ${hasInstanceSize(asset, axis) && !positionIsShare(asset, this.partId, axis)\n ? html`<button act ?disabled=${this.locked} title=${i18next.t('figure.text.scale-position-explained')} @click=${() => this.command({ kind: 'scale-position', part: this.partId, axis })}>\n <md-icon>open_in_full</md-icon>${i18next.t('figure.button.scale-position')}\n </button>`\n : nothing}\n </div>`\n )\n }\n\n /**\n * The fastening in one line -- what, on which face, how -- and 「바꾸기」 to open the window where it is chosen (chief\n * architect 2026-10-16; user 2026-10-17: the result here, the editing in a window with room). Taking it off is in the\n * group's 「⋯」. What hangs over the face, and the way to fix it, stay here: they are about the fastening as it is now.\n */\n private renderFastening(asset: FigureAsset) {\n const revision = this.revision!\n const own = fasteningOf(revision, this.partId)\n /* Placed by an origin (ADR-0107 decision 4): attach writes faces, so the window would move it off its origin. Said, and taken off only. */\n if (own?.atOrigin)\n return html`<div fastened fasten-at-origin>\n <p>${this.heldWords(asset)}</p>\n ${this.renderDetachWords()}\n </div>`\n const overhang = html`${this.overhangNote.length ? html`<p hint overhang-note>${this.overhangNote.join(' ')}</p>` : nothing}\n ${this.overhangWords.length\n ? html`<div overhang role=\"status\">\n ${this.overhangWords.map(line => html`<p>${line}</p>`)}\n ${own\n ? html`<button act fix-alignment ?disabled=${this.locked} @click=${() => this.fixAlignment()}>\n <md-icon>tune</md-icon>${i18next.t('figure.button.fix-alignment')}\n </button>\n ${this.fixNote ? html`<p hint fix-note>${this.fixNote}</p>` : nothing}`\n : nothing}\n </div>`\n : nothing}`\n if (own && heldBy(asset, this.partId)) {\n const form = fastenFormOf(revision, this.partId)\n const plan = fastenPlanOf(revision, this.partId, form)\n if (plan.action) this.fastenCandidate = { action: plan.action, ...(plan.face ? { face: plan.face } : {}) }\n const planeWord = i18next.t('figure.label.resize-place-' + (asset.placement ?? 'floor'))\n return html`\n ${overhang}\n <div fastened-summary>\n <p fasten-sentence>${fastenSentenceOf(form, plan, planeWord, (key, params) => i18next.t(key, params))}</p>\n <button act change-fastening ?disabled=${this.locked} @click=${() => this.openFastening()}>${i18next.t('figure.button.change-fastening')}</button>\n </div>\n ${this.renderDetachWords()}\n `\n }\n /* A blank attachment is not a form to decipher: what it does, and the way to the window. */\n return html`\n ${overhang}\n <p hint>${i18next.t('figure.text.fasten-start')}</p>\n <button act fasten-start ?disabled=${this.locked} @click=${() => this.openFastening()}>\n <md-icon>link</md-icon>${i18next.t('figure.button.fasten-start')}\n </button>\n `\n }\n\n private renderDetachWords() {\n /* One thing to say is a line, not a list of one. */\n if (this.detachWords.length === 1) return html`<p hint detach-words>${this.detachWords[0]}</p>`\n return this.detachWords.length ? html`<ul detach-words>${this.detachWords.map(line => html`<li>${line}</li>`)}</ul>` : nothing\n }\n\n /**\n * Making the part a row across what it is fastened to (figure-model `make-repeat`): along one of the axes across its\n * face, copies a pitch apart filling the parent's length, or a count spread over it. Once made, the row's own section\n * (the editor's) shows it and takes it away.\n */\n private renderPreviewWords() {\n if (this.previewWords.length === 1) return html`<p preview-words role=\"status\">${this.previewWords[0]}</p>`\n return this.previewWords.length ? html`<ul preview-words role=\"status\">${this.previewWords.map(line => html`<li>${line}</li>`)}</ul>` : nothing\n }\n\n /**\n * A row (ADR-0097 §5.5): said as what it makes, \"arranged in a row\". Where it cannot be made here, why, rather than\n * nothing. Filling the length, the centre spacing is the author's; a count of their own is spread evenly over the\n * length -- figure-model draws it so, and the form does not ask for a spacing it would not use.\n */\n private renderRow(asset: FigureAsset) {\n if (rowOf(asset, this.partId)) return nothing\n const blocked = rowBlockOf(asset, this.partId)\n const axes = rowAxesOf(asset, this.partId)\n const r = this.row\n /*\n Folded, open while it is being worked (2026-10-02): a row is made now and then, and most parts stand on the plane,\n where the section said its reason open on every one. Opened, it says why or asks how.\n */\n const head = html`<summary><h3>${i18next.t('figure.label.repeat')}</h3></summary>`\n if (blocked || !axes.length)\n return html`<section row><details row-fold>\n ${head}\n <p hint row-blocked>${i18next.t(`figure.text.row-blocked-${blocked ?? 'unfastened'}`, { part: this.partId })}</p>\n ${blocked === 'unfastened'\n ? html`<button act @click=${() => this.dispatchEvent(new CustomEvent('go-fasten', { bubbles: true, composed: true }))}><md-icon>link</md-icon>${i18next.t('figure.button.go-fasten')}</button>`\n : nothing}\n </details></section>`\n const axis = axes.includes(r.axis as Axis) ? (r.axis as Axis) : axes[0]!\n const ok = r.fills ? r.pitch > 0 : Number.isSafeInteger(r.count) && r.count >= 1\n const action = ok\n ? ({ kind: 'make-repeat', part: this.partId, axis, pitch: r.fills ? r.pitch : Math.max(r.pitch, 1), ...(r.fills ? {} : { count: r.count }) } as FigureAuthoringAction)\n : undefined\n this.rowCandidate = action\n const set = (next: typeof r) => ((this.row = next), (this.rowOpen = true))\n /*\n Whether the row is being worked follows the fold's own toggle. A press on the heading focuses it before the click;\n set on focus, the fold opened there and the click then folded it again (2026-10-11: it took two clicks to open).\n */\n const toggled = (e: Event) => (this.rowOpen = (e.target as HTMLDetailsElement).open)\n return html`<section row><details row-fold ?open=${this.rowOpen} @toggle=${toggled}>\n ${head}\n <div form>\n <span>${i18next.t('figure.label.repeat-axis')}</span>\n <select @change=${(e: Event) => set({ ...r, axis: (e.target as HTMLSelectElement).value as Axis })}>\n ${axes.map(a => html`<option value=${a} ?selected=${a === axis}>${a.toUpperCase()}</option>`)}\n </select>\n </div>\n <div row-basis role=\"radiogroup\" aria-label=${i18next.t('figure.label.row-basis')}>\n <label><input type=\"radio\" name=\"row-basis\" .checked=${r.fills} @change=${() => set({ ...r, fills: true })} />${i18next.t('figure.label.repeat-fills')}</label>\n <label><input type=\"radio\" name=\"row-basis\" .checked=${!r.fills} @change=${() => set({ ...r, fills: false })} />${i18next.t('figure.label.row-by-count')}</label>\n </div>\n ${r.fills\n ? html`<div form>\n <span>${i18next.t('figure.label.repeat-pitch')} · mm</span>\n <input type=\"number\" step=\"any\" min=\"0\" .value=${String(r.pitch)} @change=${(e: Event) => set({ ...r, pitch: Number((e.target as HTMLInputElement).value) })} />\n </div>`\n : html`<div form>\n <span>${i18next.t('figure.label.repeat-count')}</span>\n <input type=\"number\" step=\"1\" min=\"1\" .value=${String(r.count)} @change=${(e: Event) => set({ ...r, count: Number((e.target as HTMLInputElement).value) })} />\n </div>\n <p hint>${i18next.t('figure.text.row-count-spreads')}</p>`}\n ${action && this.rowOpen ? this.renderPreviewWords() : nothing}\n <button act ?disabled=${this.locked || !action} @click=${() => action && this.command(action)}>\n <md-icon>view_week</md-icon>${i18next.t('figure.button.make-repeat')}\n </button>\n </details></section>`\n }\n\n /**\n * When the part is drawn: always, or while a control is at least a value -- a lamp lit while the gate is open. One\n * part edit (`set-visibility`), one step. Offered once the figure has a control; a motion is what makes one.\n */\n private renderShown(asset: FigureAsset) {\n const controls = visibilityControlsOf(asset)\n if (!controls.length) return nothing\n const now = shownWhenOf(asset, this.partId)\n const send = (shownWhen: { input: string; atLeast: number } | null) =>\n this.dispatchEvent(new CustomEvent('part-edit', { detail: { edit: { kind: 'set-visibility', target: this.partId, shownWhen } }, bubbles: true, composed: true }))\n const first = (id: string) => {\n const c = controls.find(one => one.id === id)!\n return Math.round((c.min + (c.max - c.min) * 0.01) * 1000) / 1000\n }\n const unit = now ? controls.find(c => c.id === now.input)?.unit : ''\n return html`<div form>\n <span>${i18next.t('figure.label.shown-when')}</span>\n <select\n ?disabled=${this.locked}\n @change=${(e: Event) => {\n const id = (e.target as HTMLSelectElement).value\n send(id ? { input: id, atLeast: now?.input === id ? now.atLeast : first(id) } : null)\n }}\n >\n <option value=\"\" ?selected=${!now}>${i18next.t('figure.label.shown-always')}</option>\n ${controls.map(c => html`<option value=${c.id} ?selected=${now?.input === c.id}>${i18next.t('figure.label.shown-while', { control: c.label })}</option>`)}\n </select>\n ${now\n ? html`<span>${i18next.t('figure.label.shown-at-least')}${unit ? ` (${unit})` : ''}</span>\n <input\n type=\"number\"\n step=\"any\"\n ?disabled=${this.locked}\n .value=${String(now.atLeast)}\n @change=${(e: Event) => {\n const v = (e.target as HTMLInputElement).valueAsNumber\n if (Number.isFinite(v)) send({ input: now.input, atLeast: v })\n }}\n />`\n : nothing}\n </div>`\n }\n\n private renderMotion(asset: FigureAsset) {\n const now = motionOf(asset, this.partId)\n const joint = asset.joints?.find(j => j.body1.part === this.partId)\n if (now && !(this.editingMotion && joint)) {\n /* Which part moves, against what, which way, how far -- by name (ADR-0097 §5.5). */\n const against = joint ? ('plane' in joint.body0 ? i18next.t('figure.label.mounting-plane') : joint.body0.part) : ''\n const ends = this.motionEnds\n return html`<p motion-summary>\n ${i18next.t('figure.text.motion-summary', {\n part: this.partId,\n against,\n kind: i18next.t('figure.label.motion-' + now.kind),\n axis: now.vector ? jointAxisWord(now.vector) : String(now.axis).toUpperCase()\n })}\n </p>\n ${ends\n ? html`<p hint motion-ends>${i18next.t('figure.text.motion-ends-shown', { min: String(ends.min), max: String(ends.max), unit: ends.unit })}</p>`\n : nothing}\n <div pair>\n <span>\n ${i18next.t('figure.label.motion-' + now.kind)} · ${now.vector ? jointAxisWord(now.vector) : String(now.axis).toUpperCase()}\n ${now.travel\n ? html`<small>${i18next.t('figure.label.motion-travel-is', { part: now.travel.part, axis: now.travel.axis.toUpperCase(), plus: now.travel.plus ?? 0 })}</small>`\n : nothing}\n ${now.follows?.sum.length === 1\n ? html`<small>${i18next.t('figure.label.motion-follows', { joint: now.follows.sum[0]!.joint, multiplier: now.follows.sum[0]!.multiplier, offset: now.follows.offset })}</small>`\n : now.follows\n ? html`<small>${i18next.t('figure.label.motion-follow')}: ${now.follows.sum.map(t => `${t.joint} × ${t.multiplier}`).join(' + ')} + ${now.follows.offset}</small>`\n : now.control\n ? html`<small>${now.control.id} (${now.control.unit}) ${now.control.min} … ${now.control.max}</small>`\n : nothing}\n </span>\n <button\n act\n ?disabled=${this.locked || !joint}\n @click=${() => joint && this.command({ kind: 'set-joint', joint: fixedJointOf(joint) })}\n >\n <md-icon>close</md-icon>${i18next.t('figure.button.remove-motion')}\n </button>\n <button\n act\n ?disabled=${this.locked || !joint}\n @click=${() => {\n if (!joint) return\n this.motion = motionFormOf(joint)\n this.editingMotion = true\n }}\n >\n <md-icon>edit</md-icon>${i18next.t('figure.button.change-motion')}\n </button>\n </div>`\n }\n /* A joint needs a parent (URDF): a part fastened to nothing is fastened first. */\n if (!joint)\n return html`<p hint>${i18next.t('figure.text.fasten-before-moving')}</p>\n <button act go-fasten @click=${() => this.dispatchEvent(new CustomEvent('go-fasten', { bubbles: true, composed: true }))}>\n <md-icon>link</md-icon>${i18next.t('figure.button.go-fasten')}\n </button>`\n const m = this.motion\n const unit = m.kind === 'slide' ? 'mm' : 'deg'\n /* A follower follows a joint that moves the same way; a choice the kind no longer allows is dropped. */\n const leaders = leadersFor(asset, this.partId, m.kind)\n const follow = leaders.some(j => j.id === m.follow) ? m.follow : ''\n const refusal = motionFormRefusalOf(m, follow)\n return html`\n <div pair>\n <select @change=${(e: Event) => this.setKind((e.target as HTMLSelectElement).value as 'slide' | 'turn' | 'continuous')}>\n <option value=\"slide\" ?selected=${m.kind === 'slide'}>${i18next.t('figure.label.motion-slide')}</option>\n <option value=\"turn\" ?selected=${m.kind === 'turn'}>${i18next.t('figure.label.motion-turn')}</option>\n <option value=\"continuous\" ?selected=${m.kind === 'continuous'}>${i18next.t('figure.label.motion-continuous')}</option>\n </select>\n ${m.axisVector\n ? html`<span motion-axis-vector>${i18next.t('figure.label.motion-axis')} ${jointAxisWord(m.axisVector)}</span>`\n : html`<select @change=${(e: Event) => (this.motion = { ...m, axis: (e.target as HTMLSelectElement).value as Axis })}>\n ${AXES.map(a => html`<option value=${a} ?selected=${a === m.axis}>${i18next.t('figure.label.motion-axis')} ${a.toUpperCase()}</option>`)}\n </select>`}\n </div>\n ${m.followSum\n ? html`<div form>\n <span>${i18next.t('figure.label.motion-follow')}</span>\n <span>${m.followSum.map(t => `${t.joint} × ${t.multiplier}`).join(' + ')}</span>\n <span>${i18next.t('figure.label.motion-offset')} (${unit})</span>\n <input type=\"number\" step=\"any\" .value=${String(m.offset)} @change=${(e: Event) => (this.motion = { ...m, offset: Number((e.target as HTMLInputElement).value) || 0 })} />\n </div>`\n : leaders.length\n ? html`<div form>\n <span>${i18next.t('figure.label.motion-follow')}</span>\n <select @change=${(e: Event) => (this.motion = { ...m, follow: (e.target as HTMLSelectElement).value })}>\n <option value=\"\" ?selected=${!follow}>${i18next.t('figure.label.motion-own-control')}</option>\n ${leaders.map(j => html`<option value=${j.id} ?selected=${j.id === follow}>${j.body1.part}${j.state ? ` · ${j.state.id}` : ''}</option>`)}\n </select>\n </div>`\n : nothing}\n ${m.followSum\n ? nothing\n : follow\n ? html`<div form>\n <span>${i18next.t('figure.label.motion-multiplier')}</span>\n <input type=\"number\" step=\"any\" .value=${String(m.multiplier)} @change=${(e: Event) => (this.motion = { ...m, multiplier: Number((e.target as HTMLInputElement).value) })} />\n <span>${i18next.t('figure.label.motion-offset')} (${unit})</span>\n <input type=\"number\" step=\"any\" .value=${String(m.offset)} @change=${(e: Event) => (this.motion = { ...m, offset: Number((e.target as HTMLInputElement).value) || 0 })} />\n </div>`\n : html`<div form>\n ${m.kind === 'slide'\n ? html`<span>${i18next.t('figure.label.motion-travel')}</span>\n <select @change=${(e: Event) => (this.motion = { ...m, travel: (e.target as HTMLSelectElement).value })}>\n ${m.travelSum\n ? html`<option value=\"\" ?selected=${!m.travel}>${m.travelSum.sum.map(t => `${t.from.of === 'input' ? t.from.input : `${t.from.of === 'part' ? t.from.part : i18next.t('figure.label.motion-travel')} · ${t.from.axis.toUpperCase()}`}${t.times !== undefined && t.times !== 1 ? ` × ${t.times}` : ''}`).join(' + ')}</option>`\n : html`<option value=\"\" ?selected=${!m.travel}>${i18next.t('figure.label.motion-travel-mm')}</option>`}\n ${asset.appearance\n .map(look => look.target)\n .filter(one => canFollow(asset, one))\n .flatMap(one => AXES.map(a => html`<option value=${`${one}:${a}`} ?selected=${m.travel === `${one}:${a}`}>${one} · ${a.toUpperCase()}</option>`))}\n </select>\n ${m.travel\n ? html`<span>${i18next.t('figure.label.follows-plus')}</span>\n <input type=\"number\" step=\"any\" .value=${String(m.travelPlus ?? 0)} @change=${(e: Event) => (this.motion = { ...m, travelPlus: Number((e.target as HTMLInputElement).value) || 0 })} />`\n : nothing}`\n : nothing}\n <span>${i18next.t('figure.label.control-id')}</span>\n <input .value=${m.id} placeholder=${`${this.partId}-${m.kind}`} @change=${(e: Event) => (this.motion = { ...m, id: (e.target as HTMLInputElement).value.trim() })} />\n ${m.kind === 'continuous' || (m.kind === 'slide' && (m.travel || m.travelSum))\n ? nothing\n : html`<span>${i18next.t('figure.label.control-range')} (${unit})</span>\n <div pair>\n <input type=\"number\" step=\"any\" .value=${String(m.min)} @change=${(e: Event) => (this.motion = { ...m, min: Number((e.target as HTMLInputElement).value) })} />\n <input type=\"number\" step=\"any\" .value=${String(m.max)} @change=${(e: Event) => (this.motion = { ...m, max: Number((e.target as HTMLInputElement).value) })} />\n </div>`}\n </div>`}\n <button\n act\n ?disabled=${this.locked || !!refusal}\n title=${refusal === 'range' ? i18next.t('figure.text.range-needs-room') : ''}\n @click=${() => {\n this.command({ kind: 'set-joint', joint: motionJoint(joint, { ...m, follow }, this.partId) })\n this.editingMotion = false\n }}\n >\n <md-icon>animation</md-icon>${i18next.t(this.editingMotion ? 'figure.button.apply-motion-change' : 'figure.button.add-motion')}\n </button>\n ${this.editingMotion\n ? html`<button act @click=${() => (this.editingMotion = false)}><md-icon>undo</md-icon>${i18next.t('figure.button.cancel-motion-change')}</button>`\n : nothing}\n `\n }\n\n private setKind(kind: 'slide' | 'turn' | 'continuous') {\n this.motion = kind === 'slide' ? { ...this.motion, kind, min: 0, max: 500 } : { ...this.motion, kind, min: -90, max: 90 }\n }\n\n private command(action: FigureAuthoringAction) {\n this.dispatchEvent(new CustomEvent('command', { detail: { action }, bubbles: true, composed: true }))\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"figure-links.js","sourceRoot":"","sources":["../../client/modeller/figure-links.ts"],"names":[],"mappings":";AAAA,OAAO,4BAA4B,CAAA;AAEnC,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,KAAK,CAAA;AACpD,OAAO,2CAA2C,CAAA;AAClD,OAAO,+BAA+B,CAAA;AACtC,OAAO,yBAAyB,CAAA;AAChC,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAA;AAElE,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AACjD,OAAO,EAAE,oBAAoB,EAAE,eAAe,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAA;AAG1F,OAAO,EACL,SAAS,EACT,IAAI,EACJ,SAAS,EACT,SAAS,EACT,eAAe,EACf,MAAM,EACN,WAAW,EACX,oBAAoB,EACpB,WAAW,EACX,eAAe,EACf,WAAW,EACX,UAAU,EACV,QAAQ,EACR,YAAY,EACZ,mBAAmB,EACnB,aAAa,EACb,WAAW,EACX,YAAY,EACZ,WAAW,EACX,YAAY,EACZ,UAAU,EACV,Q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C;AACzB;IAAhB,KAAK,EAAE;;wCAAyB;AAEhB;IAAhB,KAAK,EAAE;;kDAA8B;AAErB;IAAhB,KAAK,EAAE;;+CAAuB;AArHpB,WAAW;IADvB,aAAa,CAAC,cAAc,CAAC;GACjB,WAAW,CAotBvB","sourcesContent":["import '@material/web/icon/icon.js'\n\nimport { css, html, LitElement, nothing } from 'lit'\nimport '@operato/input/ox-input-select-buttons.js'\nimport './figure-slot-layout-panel.js'\nimport './figure-size-editor.js'\nimport { customElement, property, state } from 'lit/decorators.js'\n\nimport { i18next, localize } from '@operato/i18n'\nimport { figureFaceOverhangOf, figureMotionsOf, motionIdOf } from '@hatiolab/figure-model'\nimport type { FigureAsset, FigureAuthoringAction, FigureFace } from '@hatiolab/figure-model'\n\nimport {\n acceptsOf,\n AXES,\n canFasten,\n canFollow,\n positionIsShare,\n heldBy,\n shownWhenOf,\n visibilityControlsOf,\n fasteningOf,\n hasInstanceSize,\n holdsThings,\n leadersFor,\n motionOf,\n motionFormOf,\n motionFormRefusalOf,\n endPlaceKeyOf,\n motionJoint,\n controlIdFor,\n withoutAxis,\n placeFacesOf,\n placeIdFor,\n placesOn,\n rowAxesOf,\n rowBlockOf,\n fixedJointOf,\n rowOf,\n positionsWorkedOut,\n type Axis,\n type MotionForm\n} from './links.js'\nimport { SidePanelStyles } from '@things-factory/figure-viewer/dist-client/side-panel-styles.js'\nimport { insideAlignmentOf } from './fasten-geometry.js'\nimport { fastenFormOf, fastenPlanOf, fastenSentenceOf } from './fasten-form.js'\nimport type { FigureRevision } from './revision.js'\nimport { HelpToggles } from './help.js'\nimport { groupMenu, GroupMenuStyles } from './group-menu.js'\nimport { jointAxisWord } from './joint-axis.js'\nimport { placeTerms } from '@things-factory/figure-viewer/dist-client/detail-facts.js'\n\nconst freshMotion = (): MotionForm => ({ kind: 'slide', axis: 'x', id: '', min: 0, max: 500, follow: '', multiplier: 1, offset: 0, travel: '', travelPlus: 0 })\nconst freshRow = () => ({ axis: '' as Axis | '', pitch: 200, fills: true, count: 5 })\nconst freshPlace = () => ({ role: 'grip' as 'seat' | 'grip', face: 'top' as FigureFace, label: '', accepts: '', capacity: 1 })\n\n/**\n * What a part is tied to — its size response, what it is fastened to, how it moves.\n *\n * 「Build Once, Fit Anywhere」 lives here: a dimension that follows the instance size or another part is what lets\n * a figure be placed at any size, and a part fastened to the face it rests on is what keeps it there when that\n * happens. The release gate refuses a figure that falls apart when resized, and tells the author to fasten the\n * parts that come away — this is where they do it. Motion is a joint: a slide or a turn driven by a control.\n *\n * The sections are dimensions, placement and joint, in that order. Every\n * change is one figure-model authoring command, sent as `command` and run by the editor through the session — one\n * step of the undo history. The fastening is said here in one line; it is chosen in the fastening window\n * (`figure-fasten-dialog.ts`), which the editor opens when this asks (`fasten-open`). Choices the command would refuse (a round body fastened, a size following an instance\n * size the figure does not declare) are not offered, so the author is not sent into a refusal.\n */\n@customElement('figure-links')\nexport class FigureLinks extends localize(i18next)(LitElement) {\n private readonly help = new HelpToggles(this)\n static styles = [SidePanelStyles, GroupMenuStyles, css`\n :host {\n display: block;\n }\n /* A group's sub-question, under its title: quieter than the title, as a label is. */\n p[group-question] {\n margin: 4px 0 0;\n color: var(--md-sys-color-on-surface-variant);\n }\n /* The fastening a part has, in one line, and 「바꾸기」 at its end. */\n div[fastened-summary] {\n display: flex;\n align-items: center;\n gap: 8px;\n }\n div[fastened-summary] > p {\n flex: 1;\n margin: 0;\n }\n /* Opening the form is an action: the primary colour, at the line's end. */\n div[fastened-summary] > button[act] {\n flex: none;\n margin: 0 -6px 0 0;\n }\n /* The measure's name, then its rule: X, or a cylinder's 반지름 · 길이, on one line. */\n div[row] > b {\n white-space: nowrap;\n }\n div[row] {\n display: grid;\n grid-template-columns: minmax(24px, max-content) minmax(0, 1fr);\n gap: 6px;\n align-items: center;\n }\n b[bound] {\n font-weight: 600;\n }\n /* What each direction does now: read-only rows. */\n div[resize-now] { display: grid; grid-template-columns: 1fr auto auto auto; gap: 4px 8px; margin: 12px 0; }\n div[resize-now] div[row] { grid-column: 1 / -1; grid-template-columns: subgrid; align-items: center; }\n div[resize-now] span[measure] { font-variant-numeric: tabular-nums; }\n /* Size behaviour is a choice about dimensions only. It never implies a placement or a fastening. */\n /* One of the size group's rows: the group's gap spaces it, as it does the rest (a margin on top of it left a hole). */\n details[resize-choice] { margin: 0; padding: 0; border: 0; }\n details[resize-choice] > div { display: grid; gap: 8px; padding: 8px 0; }\n p[fasten-mode] { margin: 0; font-weight: 600; }\n details { margin-top: 8px; }\n details[row-fold] { margin: 0; }\n details[row-fold] > summary { padding: 0; color: var(--md-sys-color-on-surface); }\n details[row-fold] > summary h3 { margin: 0; flex: 1; }\n details[row-fold][open] > summary { margin-bottom: 8px; }\n /* What the command would do, said beside the result drawn on the canvas. */\n ul[preview-words] { margin: 8px 0; padding: 8px 12px 8px 26px; border-radius: 6px; background: var(--md-sys-color-surface-container, #8881); display: grid; gap: 4px; }\n p[preview-words] { margin: 8px 0; padding: 8px 12px; border-radius: 6px; background: var(--md-sys-color-surface-container, #8881); }\n div[overhang] { display: grid; gap: 6px; margin: 8px 0; padding: 8px 12px; border-radius: 6px; border: 1px solid var(--md-sys-color-outline-variant, #8884); }\n div[overhang] p { margin: 0; }\n ul[detach-words] { margin: 4px 0 10px; padding-left: 20px; display: grid; gap: 2px; }\n /* The difference a following measure keeps: under its choice, on the same line as its words. */\n label[inline-plus] {\n display: flex;\n align-items: center;\n gap: 6px;\n }\n label[inline-plus] input {\n flex: 1;\n min-width: 0;\n }\n `]\n\n /** The figure at the version on screen. */\n @property({ attribute: false }) revision?: FigureRevision\n private get asset(): FigureAsset | undefined {\n return this.revision?.asset\n }\n /** The selected part. */\n @property() partId = ''\n @property({ type: Boolean }) locked = false\n /** Which ties this shows: the part's shape (size and placement, in 속성), its places (자리·능력) or its motion (움직임). */\n @property() section: 'shape' | 'response' | 'places' | 'motion' = 'shape'\n /**\n * Its tab is the one shown, and no window over it speaks instead. The response's row speaks of what a command would\n * draw, and the properties' says there is none: only the one in sight may, as the hidden one's silence would clear what\n * the shown one draws. While the fastening window is open it alone speaks (the editor sets this false).\n */\n @property({ type: Boolean }) active = true\n /** What the row's command would do, in words (the editor works it out: `command-preview.ts`). */\n @property({ attribute: false }) previewWords: string[] = []\n /** Where the selected part's motion takes it, at both ends of its range (the editor draws them on the canvas). */\n @property({ attribute: false }) motionEnds: { control: string; min: number; max: number; unit: string } | null = null\n /** Past the edge of the face it is fastened to, or parts fastened to it past theirs (ADR-0097 §5.5, Q3). */\n @property({ attribute: false }) overhangWords: string[] = []\n /** Wider than the face it is fastened to: how far past each edge, and whether off to one side -- a fact, not a warning. */\n @property({ attribute: false }) overhangNote: string[] = []\n /** What taking this part off would do, said beside the buttons that do it (worked out on a copy by the editor). */\n @property({ attribute: false }) detachWords: string[] = []\n /*\n What a section speaks of on the canvas: the response's row while its fold is open; the properties', the fastening the\n part has -- its face lit, as the one-line result says it.\n */\n private candidate?: { action: FigureAuthoringAction; face?: { part: string; face: string } }\n private fastenCandidate?: { action: FigureAuthoringAction; face?: { part: string; face: string } }\n private told = ''\n @state() private rowOpen = false\n private rowCandidate?: FigureAuthoringAction\n\n /** Why 정렬·간격 고치기 moved nothing, said under it; empty once it moved the part or the part changed. */\n @state() private fixNote = ''\n @state() private motion: MotionForm = freshMotion()\n @state() private place = freshPlace()\n /** How places are made here: one at a time, or by the figure's rule. Unset: by the rule when the figure has one. */\n @state() private placesBy?: 'one' | 'rule'\n @state() private row = freshRow()\n /** The motion form is open over the part's own motion, to change it where it is. */\n @state() private editingMotion = false\n /** Which of the joint's axes the form is over (ADR-0159); one past the last is a new axis. */\n @state() private motionAxis = 0\n\n /*\n The forms describe the next command for the selected part, so another part starts from the defaults: carrying the\n last part's choices over fastened a shutter curtain level with a right edge nobody chose for it (2026-09-25).\n */\n /* The part the forms were loaded for. A panel made with a part already chosen loaded nothing, and said \"editing the\n fastening it has\" over an empty target (2026-09-27, :3391, the doors). */\n private loadedFor?: string\n willUpdate(changed: Map<string, unknown>) {\n /* Its tab shown again: what it would draw is said again, over whatever the other tab left. */\n if (changed.has('active') && this.active && changed.get('active') === false) this.told = ''\n /* What 고치기 said is about the figure as it was: another step or another part, and it no longer holds. */\n if (changed.has('asset') || changed.has('partId')) this.fixNote = ''\n if (this.asset && this.partId && this.partId !== this.loadedFor) {\n this.loadedFor = this.partId\n this.motion = freshMotion()\n this.place = freshPlace()\n this.row = freshRow()\n this.rowOpen = false\n this.rowCandidate = undefined\n this.editingMotion = false\n this.motionAxis = 0\n }\n }\n\n updated() {\n /* Only the sections that hold a form speak of what it would do, and only while their tab is shown: the panel has\n one of these per section, and the others' silence cleared what it showed (2026-09-27, :3391). */\n const speaks = this.active && (this.section === 'shape' || this.section === 'response')\n if (!speaks) return\n const said = JSON.stringify(this.candidate ?? null)\n if (said === this.told) return\n this.told = said\n this.dispatchEvent(new CustomEvent('preview-command', { detail: this.candidate ?? null, bubbles: true, composed: true }))\n }\n\n disconnectedCallback() {\n super.disconnectedCallback()\n /* The panel left: what it showed goes with it. */\n if (this.told && this.told !== 'null') this.dispatchEvent(new CustomEvent('preview-command', { detail: null, bubbles: true, composed: true }))\n this.told = ''\n }\n\n render() {\n const asset = this.asset\n this.candidate = undefined\n this.fastenCandidate = undefined\n this.rowCandidate = undefined\n if (!asset || !this.partId) return nothing\n if (this.section === 'motion')\n return html`<section><h3>${i18next.t('figure.label.motion')}${this.help.button('figure.text.motion-explained')}</h3>${this.help.hint('figure.text.motion-explained')}\n ${this.renderMotion(asset)}${this.renderShown(asset)}</section>`\n if (this.section === 'places') {\n /*\n One idea, places, two ways to make them (ADR-0118): one at a time on this part, or many by a rule -- the figure's\n slot layout. One section with a choice, not two screens for the same thing (chief architect, 2026-10-11).\n */\n const byRule = (this.placesBy ?? (asset.document.capabilities.slotLayout ? 'rule' : 'one')) === 'rule'\n return html`<section><h3>${i18next.t('figure.label.places-on-part', { part: this.partId })}${this.help.button('figure.text.place-explained')}</h3>${this.help.hint('figure.text.place-explained')}\n <ox-input-select-buttons\n places-by\n .value=${byRule ? 'rule' : 'one'}\n .options=${[\n { value: 'one', display: i18next.t('figure.label.places-one') },\n { value: 'rule', display: i18next.t('figure.label.places-by-rule') }\n ]}\n @change=${(e: CustomEvent) => (this.placesBy = e.detail === 'rule' ? 'rule' : 'one')}\n ></ox-input-select-buttons>\n ${byRule\n ? html`<figure-slot-layout-panel .asset=${asset} .partId=${this.partId} ?locked=${this.locked}></figure-slot-layout-panel>`\n : placeFacesOf(asset, this.partId).length\n ? this.renderPlaces(asset)\n : html`<p hint>${i18next.t('figure.text.places-need-a-box')}</p>`}</section>`\n }\n /*\n Three groups in one order whatever the part's state (chief architect 2026-10-16): its size, its place, its row. The\n editor's own numbers go in through the slots, so a group keeps its place when a rule or a fastening takes them over.\n */\n /* Fastened, by a face or by an origin: either can be taken off, from the place group's 「⋯」. */\n const held = !!heldBy(asset, this.partId) || !!(this.revision && fasteningOf(this.revision, this.partId)?.atOrigin)\n if (this.section === 'response') {\n /*\n How the part answers a size it is placed at (user 2026-10-17, the 「반응형」 tab): its own measures, where it\n stands, and the row it may make -- what Build Once, Fit Anywhere is authored with, in one place.\n */\n const positions = held ? [] : positionsWorkedOut(asset, this.partId)\n this.rowCandidate = undefined\n const response = html`\n ${canFollow(asset, this.partId) ? html`<section size>\n <h3>${i18next.t('figure.label.group-size')}</h3>\n <figure-size-editor .revision=${this.revision} .partId=${this.partId} ?locked=${this.locked}></figure-size-editor>\n <slot name=\"size-note\"></slot>\n </section>` : nothing}\n ${positions.length\n ? html`<section position-response>\n <h3>${i18next.t('figure.label.group-position-response')}</h3>\n ${this.renderPositions(asset)}\n </section>`\n : nothing}\n ${rowOf(asset, this.partId) ? html`<slot name=\"row\"></slot>` : this.renderRow(asset)}\n `\n this.candidate = this.rowOpen && this.rowCandidate ? { action: this.rowCandidate } : undefined\n return response\n }\n const shown = html`\n <slot name=\"size\"></slot>\n <section fastening>\n <h3>\n ${i18next.t('figure.label.group-place')}${this.help.button('figure.text.fastening-explained')}\n ${groupMenu([{ label: i18next.t('figure.button.detach'), icon: 'link_off', disabled: this.locked || !held, run: () => this.command({ kind: 'detach', part: this.partId }) }])}\n </h3>${this.help.hint('figure.text.fastening-explained')}\n <slot name=\"place\"></slot>\n ${canFasten(asset, this.partId) ? this.renderFastening(asset) : html`<p hint>${i18next.t('figure.text.part-cannot-fasten')}</p>`}\n </section>\n `\n this.candidate = this.fastenCandidate\n return shown\n }\n\n /** Where things are held on this part: a seat things rest on, or a grip things are held in. */\n private renderPlaces(asset: FigureAsset) {\n const faces = placeFacesOf(asset, this.partId)\n const p = this.place\n const face = faces.includes(p.face) ? p.face : faces[0]!\n const accepts = acceptsOf(p.accepts)\n const capacityOk = Number.isSafeInteger(p.capacity) && p.capacity >= 1\n const roleName = (role: string) => i18next.t('figure.label.place-' + role)\n return html`\n ${placesOn(asset, this.partId).map(\n one => html`<div pair>\n <span>\n <b bound>${one.label}</b>\n <small>${one.face ? i18next.t('figure.label.face-' + one.face) + ' · ' : ''}${placeTerms(one, (key, params) => i18next.t(key, params))}</small>\n </span>\n <button quiet ?disabled=${this.locked} @click=${() => this.command({ kind: 'remove-binding', id: one.id })}>\n <md-icon>close</md-icon>${i18next.t('figure.button.remove-place')}\n </button>\n </div>`\n )}\n ${holdsThings(asset)\n ? nothing\n : html`<p hint>${i18next.t('figure.text.place-needs-holding')}</p>\n <button act ?disabled=${this.locked} @click=${() => this.declareHolding(asset)}>\n <md-icon>inventory_2</md-icon>${i18next.t('figure.button.declare-holding')}\n </button>`}\n <div pair>\n <select @change=${(e: Event) => (this.place = { ...p, role: (e.target as HTMLSelectElement).value as 'seat' | 'grip' })}>\n <option value=\"grip\" ?selected=${p.role === 'grip'}>${roleName('grip')}</option>\n <option value=\"seat\" ?selected=${p.role === 'seat'}>${roleName('seat')}</option>\n </select>\n <select @change=${(e: Event) => (this.place = { ...p, face: (e.target as HTMLSelectElement).value as FigureFace })}>\n ${faces.map(one => html`<option value=${one} ?selected=${one === face}>${i18next.t('figure.label.face-' + one)}</option>`)}\n </select>\n </div>\n <div form>\n <span>${i18next.t('figure.label.place-name')}</span>\n <input .value=${p.label} placeholder=${roleName(p.role)} @change=${(e: Event) => (this.place = { ...p, label: (e.target as HTMLInputElement).value })} />\n <span>${i18next.t('figure.label.place-accepts')}</span>\n <input .value=${p.accepts} placeholder=\"BOX, TOTE\" @input=${(e: Event) => (this.place = { ...p, accepts: (e.target as HTMLInputElement).value })} />\n <span>${i18next.t('figure.label.place-capacity')}</span>\n <input type=\"number\" min=\"1\" step=\"1\" .value=${String(p.capacity)} @change=${(e: Event) => (this.place = { ...p, capacity: (e.target as HTMLInputElement).valueAsNumber })} />\n </div>\n ${accepts.length ? nothing : html`<small>${i18next.t('figure.text.place-accepts-needed')}</small>`}\n <button\n act\n ?disabled=${this.locked || !accepts.length || !capacityOk}\n @click=${() =>\n this.command({\n kind: 'add-binding',\n id: placeIdFor(asset, this.partId, p.role),\n label: p.label.trim() || roleName(p.role),\n role: p.role,\n part: this.partId,\n face,\n accepts,\n capacity: p.capacity\n })}\n >\n <md-icon>back_hand</md-icon>${i18next.t('figure.button.add-place')}\n </button>\n `\n }\n\n /** The figure holds things: `Capacity` and `Holdable`, the ladder's middle rung. One part edit, one undo step. */\n private declareHolding(asset: FigureAsset) {\n const names = [...new Set([...(asset.document.capabilities.names ?? []), 'Capacity', 'Holdable'])]\n this.dispatchEvent(new CustomEvent('part-edit', { detail: { edit: { kind: 'set-capabilities', names } }, bubbles: true, composed: true }))\n }\n\n /**\n * 정렬·간격 고치기: the part moved inside the face it is fastened on, as one step -- the least move on each side it is\n * out, or centred when it is wider than the face. When nothing of it can be moved, why is said under the button, not\n * nothing at all (:3300, 2026-10-11: the button only scrolled to the drawing, which was already in view). The command\n * is the fastening window's for the same choice (`fasten-form.ts`), with only the place across the face changed.\n */\n private fixAlignment() {\n const revision = this.revision\n if (!revision) return\n const form = fastenFormOf(revision, this.partId)\n /* Whether it is out, and the least move that brings it in, are the kernel's measure (ADR-0140 3.8). */\n const own = figureFaceOverhangOf(revision.asset, this.partId, revision.inputs)\n const fixed =\n own?.state === 'unknown'\n ? ({ cannot: 'unmeasured' } as const)\n : own?.state === 'out' || own?.state === 'possible'\n ? insideAlignmentOf(fastenPlanOf(revision, this.partId, form).view, form.align, form.alignMm)\n : ({ cannot: 'inside' } as const)\n if ('cannot' in fixed) {\n this.fixNote = i18next.t(`figure.text.fix-alignment-${fixed.cannot}`, { part: this.partId, on: form.target })\n return\n }\n this.fixNote = ''\n const action = fastenPlanOf(revision, this.partId, { ...form, align: fixed.align, alignMm: fixed.alignMm }).action\n if (action) this.command(action)\n }\n\n /** The fastening window, asked of the editor: it opens over the canvas on what the part has now. */\n private openFastening() {\n this.dispatchEvent(new CustomEvent('fasten-open', { bubbles: true, composed: true }))\n }\n\n /**\n * What holds the part, said as its state -- 「바닥에 붙어 있음」 -- with the ways to change it: open the fastening,\n * or take it off. Right after \"follow size, attached\" this is the result, not a refusal (designer 2026-09-27).\n */\n private heldWords(asset: FigureAsset) {\n const joint = (asset.joints ?? []).find(j => j.body1.part === this.partId)\n const gap = joint?.origin?.gap ?? 0\n const place = i18next.t(`figure.label.resize-place-${asset.placement ?? 'floor'}`)\n const where = !joint\n ? i18next.t('figure.text.held-by-rule')\n : 'plane' in joint.body0\n ? typeof gap === 'number'\n ? i18next.t('figure.text.held-on-plane', { place, gap: String(gap) })\n : i18next.t('figure.text.held-on-plane-worked-out', { place })\n : i18next.t('figure.text.held-on-part', { other: joint.body0.part, otherFace: i18next.t(endPlaceKeyOf(joint.body0)) })\n return where\n }\n\n /**\n * Positions worked out from other values, each with the way to\n * keep it where it is. This is the way out the release gate names when a resize leaves a part in the air.\n */\n private renderPositions(asset: FigureAsset) {\n return positionsWorkedOut(asset, this.partId).map(\n axis => html`<div pair>\n <span>${axis.toUpperCase()} · ${i18next.t(positionIsShare(asset, this.partId, axis) ? 'figure.label.position-in-proportion' : 'figure.label.position-worked-out')}</span>\n <button act ?disabled=${this.locked} @click=${() => this.command({ kind: 'fix-position', part: this.partId, axis })}>\n <md-icon>push_pin</md-icon>${i18next.t('figure.button.fix-position')}\n </button>\n ${hasInstanceSize(asset, axis) && !positionIsShare(asset, this.partId, axis)\n ? html`<button act ?disabled=${this.locked} title=${i18next.t('figure.text.scale-position-explained')} @click=${() => this.command({ kind: 'scale-position', part: this.partId, axis })}>\n <md-icon>open_in_full</md-icon>${i18next.t('figure.button.scale-position')}\n </button>`\n : nothing}\n </div>`\n )\n }\n\n /**\n * The fastening in one line -- what, on which face, how -- and 「바꾸기」 to open the window where it is chosen (chief\n * architect 2026-10-16; user 2026-10-17: the result here, the editing in a window with room). Taking it off is in the\n * group's 「⋯」. What hangs over the face, and the way to fix it, stay here: they are about the fastening as it is now.\n */\n private renderFastening(asset: FigureAsset) {\n const revision = this.revision!\n const own = fasteningOf(revision, this.partId)\n /* Placed by an origin (ADR-0107 decision 4): attach writes faces, so the window would move it off its origin. Said, and taken off only. */\n if (own?.atOrigin)\n return html`<div fastened fasten-at-origin>\n <p>${this.heldWords(asset)}</p>\n ${this.renderDetachWords()}\n </div>`\n const overhang = html`${this.overhangNote.length ? html`<p hint overhang-note>${this.overhangNote.join(' ')}</p>` : nothing}\n ${this.overhangWords.length\n ? html`<div overhang role=\"status\">\n ${this.overhangWords.map(line => html`<p>${line}</p>`)}\n ${own\n ? html`<button act fix-alignment ?disabled=${this.locked} @click=${() => this.fixAlignment()}>\n <md-icon>tune</md-icon>${i18next.t('figure.button.fix-alignment')}\n </button>\n ${this.fixNote ? html`<p hint fix-note>${this.fixNote}</p>` : nothing}`\n : nothing}\n </div>`\n : nothing}`\n if (own && heldBy(asset, this.partId)) {\n const form = fastenFormOf(revision, this.partId)\n const plan = fastenPlanOf(revision, this.partId, form)\n if (plan.action) this.fastenCandidate = { action: plan.action, ...(plan.face ? { face: plan.face } : {}) }\n const planeWord = i18next.t('figure.label.resize-place-' + (asset.placement ?? 'floor'))\n return html`\n ${overhang}\n <div fastened-summary>\n <p fasten-sentence>${fastenSentenceOf(form, plan, planeWord, (key, params) => i18next.t(key, params))}</p>\n <button act change-fastening ?disabled=${this.locked} @click=${() => this.openFastening()}>${i18next.t('figure.button.change-fastening')}</button>\n </div>\n ${this.renderDetachWords()}\n `\n }\n /* A blank attachment is not a form to decipher: what it does, and the way to the window. */\n return html`\n ${overhang}\n <p hint>${i18next.t('figure.text.fasten-start')}</p>\n <button act fasten-start ?disabled=${this.locked} @click=${() => this.openFastening()}>\n <md-icon>link</md-icon>${i18next.t('figure.button.fasten-start')}\n </button>\n `\n }\n\n private renderDetachWords() {\n /* One thing to say is a line, not a list of one. */\n if (this.detachWords.length === 1) return html`<p hint detach-words>${this.detachWords[0]}</p>`\n return this.detachWords.length ? html`<ul detach-words>${this.detachWords.map(line => html`<li>${line}</li>`)}</ul>` : nothing\n }\n\n /**\n * Making the part a row across what it is fastened to (figure-model `make-repeat`): along one of the axes across its\n * face, copies a pitch apart filling the parent's length, or a count spread over it. Once made, the row's own section\n * (the editor's) shows it and takes it away.\n */\n private renderPreviewWords() {\n if (this.previewWords.length === 1) return html`<p preview-words role=\"status\">${this.previewWords[0]}</p>`\n return this.previewWords.length ? html`<ul preview-words role=\"status\">${this.previewWords.map(line => html`<li>${line}</li>`)}</ul>` : nothing\n }\n\n /**\n * A row (ADR-0097 §5.5): said as what it makes, \"arranged in a row\". Where it cannot be made here, why, rather than\n * nothing. Filling the length, the centre spacing is the author's; a count of their own is spread evenly over the\n * length -- figure-model draws it so, and the form does not ask for a spacing it would not use.\n */\n private renderRow(asset: FigureAsset) {\n if (rowOf(asset, this.partId)) return nothing\n const blocked = rowBlockOf(asset, this.partId)\n const axes = rowAxesOf(asset, this.partId)\n const r = this.row\n /*\n Folded, open while it is being worked (2026-10-02): a row is made now and then, and most parts stand on the plane,\n where the section said its reason open on every one. Opened, it says why or asks how.\n */\n const head = html`<summary><h3>${i18next.t('figure.label.repeat')} <span section-state>${i18next.t('figure.label.repeat-inactive')}</span></h3></summary>`\n if (blocked || !axes.length)\n return html`<section row><details row-fold open>\n ${head}\n <p hint row-blocked>${i18next.t(`figure.text.row-blocked-${blocked ?? 'unfastened'}`, { part: this.partId })}</p>\n ${blocked === 'unfastened'\n ? html`<button act @click=${() => this.dispatchEvent(new CustomEvent('go-fasten', { bubbles: true, composed: true }))}><md-icon>link</md-icon>${i18next.t('figure.button.go-fasten')}</button>`\n : nothing}\n </details></section>`\n const axis = axes.includes(r.axis as Axis) ? (r.axis as Axis) : axes[0]!\n const ok = r.fills ? r.pitch > 0 : Number.isSafeInteger(r.count) && r.count >= 1\n const action = ok\n ? ({ kind: 'make-repeat', part: this.partId, axis, pitch: r.fills ? r.pitch : Math.max(r.pitch, 1), ...(r.fills ? {} : { count: r.count }) } as FigureAuthoringAction)\n : undefined\n this.rowCandidate = action\n const set = (next: typeof r) => ((this.row = next), (this.rowOpen = true))\n /*\n Whether the row is being worked follows the fold's own toggle. A press on the heading focuses it before the click;\n set on focus, the fold opened there and the click then folded it again (2026-10-11: it took two clicks to open).\n */\n const toggled = (e: Event) => (this.rowOpen = (e.target as HTMLDetailsElement).open)\n return html`<section row><details row-fold ?open=${this.rowOpen} @toggle=${toggled}>\n ${head}\n <p hint>${i18next.t('figure.text.repeat-intro')}</p>\n <div form>\n <span>${i18next.t('figure.label.repeat-axis')}</span>\n <select aria-label=${i18next.t('figure.label.repeat-axis')} ?disabled=${this.locked} @change=${(e: Event) => set({ ...r, axis: (e.target as HTMLSelectElement).value as Axis })}>\n ${axes.map(a => html`<option value=${a} ?selected=${a === axis}>${a.toUpperCase()}</option>`)}\n </select>\n </div>\n <p hint>${i18next.t('figure.text.repeat-direction')}</p>\n <div choice-row role=\"radiogroup\" aria-label=${i18next.t('figure.label.row-basis')}>\n <label toggle><input type=\"radio\" name=\"row-basis\" ?disabled=${this.locked} .checked=${r.fills} @change=${() => set({ ...r, fills: true })} />${i18next.t('figure.label.repeat-fills')}</label>\n <label toggle><input type=\"radio\" name=\"row-basis\" ?disabled=${this.locked} .checked=${!r.fills} @change=${() => set({ ...r, fills: false })} />${i18next.t('figure.label.row-by-count')}</label>\n </div>\n ${r.fills\n ? html`<div form>\n <span>${i18next.t('figure.label.repeat-pitch')} · mm</span>\n <input aria-label=${i18next.t('figure.label.repeat-pitch')} ?disabled=${this.locked} type=\"number\" step=\"any\" min=\"0\" .value=${String(r.pitch)} @change=${(e: Event) => set({ ...r, pitch: Number((e.target as HTMLInputElement).value) })} />\n </div>`\n : html`<div form>\n <span>${i18next.t('figure.label.repeat-count')}</span>\n <input aria-label=${i18next.t('figure.label.repeat-count')} ?disabled=${this.locked} type=\"number\" step=\"1\" min=\"1\" .value=${String(r.count)} @change=${(e: Event) => set({ ...r, count: Number((e.target as HTMLInputElement).value) })} />\n </div>\n <p hint>${i18next.t('figure.text.row-count-spreads')}</p>`}\n ${action && this.rowOpen ? html`<p hint>${i18next.t('figure.text.repeat-draft')}</p>${this.renderPreviewWords()}` : nothing}\n <button act ?disabled=${this.locked || !action} @click=${() => action && this.command(action)}>\n <md-icon>view_week</md-icon>${i18next.t('figure.button.make-repeat')}\n </button>\n </details></section>`\n }\n\n /**\n * When the part is drawn: always, or while a control is at least a value -- a lamp lit while the gate is open. One\n * part edit (`set-visibility`), one step. Offered once the figure has a control; a motion is what makes one.\n */\n private renderShown(asset: FigureAsset) {\n const controls = visibilityControlsOf(asset)\n if (!controls.length) return nothing\n const now = shownWhenOf(asset, this.partId)\n const send = (shownWhen: { input: string; atLeast: number } | null) =>\n this.dispatchEvent(new CustomEvent('part-edit', { detail: { edit: { kind: 'set-visibility', target: this.partId, shownWhen } }, bubbles: true, composed: true }))\n const first = (id: string) => {\n const c = controls.find(one => one.id === id)!\n return Math.round((c.min + (c.max - c.min) * 0.01) * 1000) / 1000\n }\n const unit = now ? controls.find(c => c.id === now.input)?.unit : ''\n return html`<div form>\n <span>${i18next.t('figure.label.shown-when')}</span>\n <select\n ?disabled=${this.locked}\n @change=${(e: Event) => {\n const id = (e.target as HTMLSelectElement).value\n send(id ? { input: id, atLeast: now?.input === id ? now.atLeast : first(id) } : null)\n }}\n >\n <option value=\"\" ?selected=${!now}>${i18next.t('figure.label.shown-always')}</option>\n ${controls.map(c => html`<option value=${c.id} ?selected=${now?.input === c.id}>${i18next.t('figure.label.shown-while', { control: c.label })}</option>`)}\n </select>\n ${now\n ? html`<span>${i18next.t('figure.label.shown-at-least')}${unit ? ` (${unit})` : ''}</span>\n <input\n type=\"number\"\n step=\"any\"\n ?disabled=${this.locked}\n .value=${String(now.atLeast)}\n @change=${(e: Event) => {\n const v = (e.target as HTMLInputElement).valueAsNumber\n if (Number.isFinite(v)) send({ input: now.input, atLeast: v })\n }}\n />`\n : nothing}\n </div>`\n }\n\n private renderMotion(asset: FigureAsset) {\n const now = motionOf(asset, this.partId)\n const joint = asset.joints?.find(j => j.body1.part === this.partId)\n if (now && !(this.editingMotion && joint)) {\n /* Which part moves, against what, which way, how far -- by name (ADR-0097 §5.5). */\n const against = joint ? ('plane' in joint.body0 ? i18next.t('figure.label.mounting-plane') : joint.body0.part) : ''\n const ends = this.motionEnds\n /* One row an axis (ADR-0159): how it moves and by what, changed or taken away where it is; more added under them. */\n const count = joint ? figureMotionsOf(joint).length : 1\n const edit = (k: number) => {\n if (!joint) return\n this.motionAxis = k\n this.motion = motionFormOf(joint, k)\n this.editingMotion = true\n }\n const row = (k: number) => {\n const it = k === 0 ? now : motionOf(asset, this.partId, k)\n if (!it) return nothing\n return html`<div pair motion-axis=${k}>\n <span>\n ${count > 1 ? html`<b>${i18next.t('figure.label.motion-axis-n', { n: k + 1 })}</b> ` : nothing}${i18next.t('figure.label.motion-' + it.kind)} · ${it.vector ? jointAxisWord(it.vector) : String(it.axis).toUpperCase()}\n ${it.travel\n ? html`<small>${i18next.t('figure.label.motion-travel-is', { part: it.travel.part, axis: it.travel.axis.toUpperCase(), plus: it.travel.plus ?? 0 })}</small>`\n : nothing}\n ${it.follows?.sum.length === 1\n ? html`<small>${i18next.t('figure.label.motion-follows', { joint: it.follows.sum[0]!.joint, multiplier: it.follows.sum[0]!.multiplier, offset: it.follows.offset })}</small>`\n : it.follows\n ? html`<small>${i18next.t('figure.label.motion-follow')}: ${it.follows.sum.map(t => `${t.joint} × ${t.multiplier}`).join(' + ')} + ${it.follows.offset}</small>`\n : it.control\n ? html`<small>${it.control.id} (${it.control.unit}) ${it.control.min} … ${it.control.max}</small>`\n : nothing}\n </span>\n ${count > 1\n ? html`<button act remove-axis ?disabled=${this.locked || !joint} @click=${() => joint && this.command({ kind: 'set-joint', joint: withoutAxis(joint, k) })}>\n <md-icon>close</md-icon>${i18next.t('figure.button.remove-axis')}\n </button>`\n : html`<button act ?disabled=${this.locked || !joint} @click=${() => joint && this.command({ kind: 'set-joint', joint: fixedJointOf(joint) })}>\n <md-icon>close</md-icon>${i18next.t('figure.button.remove-motion')}\n </button>`}\n <button act ?disabled=${this.locked || !joint} @click=${() => edit(k)}>\n <md-icon>edit</md-icon>${i18next.t('figure.button.change-motion')}\n </button>\n </div>`\n }\n return html`<p motion-summary>\n ${i18next.t('figure.text.motion-summary', {\n part: this.partId,\n against,\n kind: i18next.t('figure.label.motion-' + now.kind),\n axis: now.vector ? jointAxisWord(now.vector) : String(now.axis).toUpperCase()\n })}\n </p>\n ${ends\n ? html`<p hint motion-ends>${i18next.t('figure.text.motion-ends-shown', { min: String(ends.min), max: String(ends.max), unit: ends.unit })}</p>`\n : nothing}\n ${Array.from({ length: count }, (_, k) => row(k))}\n <div pair>\n <button act add-axis ?disabled=${this.locked || !joint} @click=${() => edit(count)}>\n <md-icon>add</md-icon>${i18next.t('figure.button.add-axis')}\n </button>\n ${count > 1\n ? html`<button act ?disabled=${this.locked || !joint} @click=${() => joint && this.command({ kind: 'set-joint', joint: fixedJointOf(joint) })}>\n <md-icon>close</md-icon>${i18next.t('figure.button.remove-motion')}\n </button>`\n : nothing}\n </div>`\n }\n /* A joint needs a parent (URDF): a part fastened to nothing is fastened first. */\n if (!joint)\n return html`<p hint>${i18next.t('figure.text.fasten-before-moving')}</p>\n <button act go-fasten @click=${() => this.dispatchEvent(new CustomEvent('go-fasten', { bubbles: true, composed: true }))}>\n <md-icon>link</md-icon>${i18next.t('figure.button.go-fasten')}\n </button>`\n const m = this.motion\n const unit = m.kind === 'slide' ? 'mm' : 'deg'\n /* A follower follows a joint that moves the same way; a choice the kind no longer allows is dropped. */\n const k = this.motionAxis\n const leaders = leadersFor(asset, this.partId, m.kind, motionIdOf(joint, k))\n const adding = k > 0 && k >= figureMotionsOf(joint).length\n const follow = leaders.some(j => j.id === m.follow) ? m.follow : ''\n const refusal = motionFormRefusalOf(m, follow)\n return html`\n ${k > 0 ? html`<p motion-axis-heading><b>${i18next.t('figure.label.motion-axis-n', { n: k + 1 })}</b></p>` : nothing}\n <div pair>\n <select @change=${(e: Event) => this.setKind((e.target as HTMLSelectElement).value as 'slide' | 'turn' | 'continuous')}>\n <option value=\"slide\" ?selected=${m.kind === 'slide'}>${i18next.t('figure.label.motion-slide')}</option>\n <option value=\"turn\" ?selected=${m.kind === 'turn'}>${i18next.t('figure.label.motion-turn')}</option>\n <option value=\"continuous\" ?selected=${m.kind === 'continuous'}>${i18next.t('figure.label.motion-continuous')}</option>\n </select>\n ${m.axisVector\n ? html`<span motion-axis-vector>${i18next.t('figure.label.motion-axis')} ${jointAxisWord(m.axisVector)}</span>`\n : html`<select @change=${(e: Event) => (this.motion = { ...m, axis: (e.target as HTMLSelectElement).value as Axis })}>\n ${AXES.map(a => html`<option value=${a} ?selected=${a === m.axis}>${i18next.t('figure.label.motion-axis')} ${a.toUpperCase()}</option>`)}\n </select>`}\n </div>\n ${m.followSum\n ? html`<div form>\n <span>${i18next.t('figure.label.motion-follow')}</span>\n <span>${m.followSum.map(t => `${t.joint} × ${t.multiplier}`).join(' + ')}</span>\n <span>${i18next.t('figure.label.motion-offset')} (${unit})</span>\n <input type=\"number\" step=\"any\" .value=${String(m.offset)} @change=${(e: Event) => (this.motion = { ...m, offset: Number((e.target as HTMLInputElement).value) || 0 })} />\n </div>`\n : leaders.length\n ? html`<div form>\n <span>${i18next.t('figure.label.motion-follow')}</span>\n <select @change=${(e: Event) => (this.motion = { ...m, follow: (e.target as HTMLSelectElement).value })}>\n <option value=\"\" ?selected=${!follow}>${i18next.t('figure.label.motion-own-control')}</option>\n ${leaders.map(j => html`<option value=${j.id} ?selected=${j.id === follow}>${j.part}${j.state?.id ? ` · ${j.state.id}` : j.id !== j.part ? ` · ${j.id}` : ''}</option>`)}\n </select>\n </div>`\n : nothing}\n ${m.followSum\n ? nothing\n : follow\n ? html`<div form>\n <span>${i18next.t('figure.label.motion-multiplier')}</span>\n <input type=\"number\" step=\"any\" .value=${String(m.multiplier)} @change=${(e: Event) => (this.motion = { ...m, multiplier: Number((e.target as HTMLInputElement).value) })} />\n <span>${i18next.t('figure.label.motion-offset')} (${unit})</span>\n <input type=\"number\" step=\"any\" .value=${String(m.offset)} @change=${(e: Event) => (this.motion = { ...m, offset: Number((e.target as HTMLInputElement).value) || 0 })} />\n </div>`\n : html`<div form>\n ${m.kind === 'slide'\n ? html`<span>${i18next.t('figure.label.motion-travel')}</span>\n <select @change=${(e: Event) => (this.motion = { ...m, travel: (e.target as HTMLSelectElement).value })}>\n ${m.travelSum\n ? html`<option value=\"\" ?selected=${!m.travel}>${m.travelSum.sum.map(t => `${t.from.of === 'input' ? t.from.input : `${t.from.of === 'part' ? t.from.part : i18next.t('figure.label.motion-travel')} · ${t.from.axis.toUpperCase()}`}${t.times !== undefined && t.times !== 1 ? ` × ${t.times}` : ''}`).join(' + ')}</option>`\n : html`<option value=\"\" ?selected=${!m.travel}>${i18next.t('figure.label.motion-travel-mm')}</option>`}\n ${asset.appearance\n .map(look => look.target)\n .filter(one => canFollow(asset, one))\n .flatMap(one => AXES.map(a => html`<option value=${`${one}:${a}`} ?selected=${m.travel === `${one}:${a}`}>${one} · ${a.toUpperCase()}</option>`))}\n </select>\n ${m.travel\n ? html`<span>${i18next.t('figure.label.follows-plus')}</span>\n <input type=\"number\" step=\"any\" .value=${String(m.travelPlus ?? 0)} @change=${(e: Event) => (this.motion = { ...m, travelPlus: Number((e.target as HTMLInputElement).value) || 0 })} />`\n : nothing}`\n : nothing}\n <span>${i18next.t('figure.label.control-id')}</span>\n <input .value=${m.id} placeholder=${controlIdFor(this.partId, m.kind, k)} @change=${(e: Event) => (this.motion = { ...m, id: (e.target as HTMLInputElement).value.trim() })} />\n ${m.kind === 'continuous' || (m.kind === 'slide' && (m.travel || m.travelSum))\n ? nothing\n : html`<span>${i18next.t('figure.label.control-range')} (${unit})</span>\n <div pair>\n <input type=\"number\" step=\"any\" .value=${String(m.min)} @change=${(e: Event) => (this.motion = { ...m, min: Number((e.target as HTMLInputElement).value) })} />\n <input type=\"number\" step=\"any\" .value=${String(m.max)} @change=${(e: Event) => (this.motion = { ...m, max: Number((e.target as HTMLInputElement).value) })} />\n </div>`}\n </div>`}\n <button\n act\n ?disabled=${this.locked || !!refusal}\n title=${refusal === 'range' ? i18next.t('figure.text.range-needs-room') : ''}\n @click=${() => {\n this.command({ kind: 'set-joint', joint: motionJoint(joint, { ...m, follow }, this.partId, k) })\n this.editingMotion = false\n this.motionAxis = 0\n }}\n >\n <md-icon>animation</md-icon>${i18next.t(adding ? 'figure.button.add-axis' : this.editingMotion ? 'figure.button.apply-motion-change' : 'figure.button.add-motion')}\n </button>\n ${this.editingMotion\n ? html`<button act @click=${() => ((this.editingMotion = false), (this.motionAxis = 0))}><md-icon>undo</md-icon>${i18next.t('figure.button.cancel-motion-change')}</button>`\n : nothing}\n `\n }\n\n private setKind(kind: 'slide' | 'turn' | 'continuous') {\n this.motion = kind === 'slide' ? { ...this.motion, kind, min: 0, max: 500 } : { ...this.motion, kind, min: -90, max: 90 }\n }\n\n private command(action: FigureAuthoringAction) {\n this.dispatchEvent(new CustomEvent('command', { detail: { action }, bubbles: true, composed: true }))\n }\n}\n"]}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { LitElement, nothing } from 'lit';
|
|
2
|
+
import type { FigureRevision } from './revision.js';
|
|
3
|
+
declare const FigureSizeEditor_base: (new (...args: any[]) => LitElement) & typeof LitElement;
|
|
4
|
+
/**
|
|
5
|
+
* A part's measures and what each follows, one row an axis (ADR-0159 3). Made to follow, a measure takes what the part
|
|
6
|
+
* hangs from, along the axis its own axis lies on as it stands -- the author turns it on, nothing more. Another source
|
|
7
|
+
* is there when asked for, or when there is no such axis (the part lies at an angle) or the measure already follows
|
|
8
|
+
* something else; each way of following says what it will do, in millimetres. A measure of the part's own is a value in
|
|
9
|
+
* hand as on any field (user 2026-09-24): drawn while it is typed or its label is dragged, written once on the release.
|
|
10
|
+
*/
|
|
11
|
+
export declare class FigureSizeEditor extends FigureSizeEditor_base {
|
|
12
|
+
revision?: FigureRevision;
|
|
13
|
+
partId: string;
|
|
14
|
+
locked: boolean;
|
|
15
|
+
private error;
|
|
16
|
+
private choosing;
|
|
17
|
+
private equivalentModes;
|
|
18
|
+
static styles: import("lit").CSSResult[];
|
|
19
|
+
private tell;
|
|
20
|
+
private apply;
|
|
21
|
+
private configure;
|
|
22
|
+
private choose;
|
|
23
|
+
/** What a source is called on the panel: the figure, or the part, with the axis it is measured along. */
|
|
24
|
+
private sourceWords;
|
|
25
|
+
/** What following this way does, in millimetres: the share it is of its source, or the difference it keeps. */
|
|
26
|
+
private resultWords;
|
|
27
|
+
render(): import("lit-html").TemplateResult<1> | typeof nothing;
|
|
28
|
+
}
|
|
29
|
+
export {};
|