@septkit/ui 0.0.45 → 0.0.47

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.
@@ -2,48 +2,52 @@ import e from "../button/button.js";
2
2
  import { SplitterGroup_default as t } from "../external/.pnpm/reka-ui@2.10.1_vue@3.5.39_typescript@5.8.3_/node_modules/reka-ui/dist/Splitter/SplitterGroup.js";
3
3
  import { SplitterPanel_default as n } from "../external/.pnpm/reka-ui@2.10.1_vue@3.5.39_typescript@5.8.3_/node_modules/reka-ui/dist/Splitter/SplitterPanel.js";
4
4
  import { SplitterResizeHandle_default as r } from "../external/.pnpm/reka-ui@2.10.1_vue@3.5.39_typescript@5.8.3_/node_modules/reka-ui/dist/Splitter/SplitterResizeHandle.js";
5
- import { StepperRoot_default as ee } from "../external/.pnpm/reka-ui@2.10.1_vue@3.5.39_typescript@5.8.3_/node_modules/reka-ui/dist/Stepper/StepperRoot.js";
6
- import { StepperItem_default as te } from "../external/.pnpm/reka-ui@2.10.1_vue@3.5.39_typescript@5.8.3_/node_modules/reka-ui/dist/Stepper/StepperItem.js";
7
- import { StepperIndicator_default as i } from "../external/.pnpm/reka-ui@2.10.1_vue@3.5.39_typescript@5.8.3_/node_modules/reka-ui/dist/Stepper/StepperIndicator.js";
8
- import { StepperTitle_default as ne } from "../external/.pnpm/reka-ui@2.10.1_vue@3.5.39_typescript@5.8.3_/node_modules/reka-ui/dist/Stepper/StepperTitle.js";
9
- import re from "../external/.pnpm/@lucide_vue@1.23.0_vue@3.5.39_typescript@5.8.3_/node_modules/@lucide/vue/dist/esm/icons/arrow-right.js";
10
- import ie from "../external/.pnpm/@lucide_vue@1.23.0_vue@3.5.39_typescript@5.8.3_/node_modules/@lucide/vue/dist/esm/icons/check.js";
11
- import ae from "../code/xml-diff.js";
5
+ import { StepperRoot_default as i } from "../external/.pnpm/reka-ui@2.10.1_vue@3.5.39_typescript@5.8.3_/node_modules/reka-ui/dist/Stepper/StepperRoot.js";
6
+ import { StepperItem_default as a } from "../external/.pnpm/reka-ui@2.10.1_vue@3.5.39_typescript@5.8.3_/node_modules/reka-ui/dist/Stepper/StepperItem.js";
7
+ import { StepperIndicator_default as o } from "../external/.pnpm/reka-ui@2.10.1_vue@3.5.39_typescript@5.8.3_/node_modules/reka-ui/dist/Stepper/StepperIndicator.js";
8
+ import { StepperTitle_default as ee } from "../external/.pnpm/reka-ui@2.10.1_vue@3.5.39_typescript@5.8.3_/node_modules/reka-ui/dist/Stepper/StepperTitle.js";
9
+ import te from "../external/.pnpm/@lucide_vue@1.23.0_vue@3.5.39_typescript@5.8.3_/node_modules/@lucide/vue/dist/esm/icons/arrow-right.js";
10
+ import ne from "../external/.pnpm/@lucide_vue@1.23.0_vue@3.5.39_typescript@5.8.3_/node_modules/@lucide/vue/dist/esm/icons/check.js";
11
+ import re from "../external/.pnpm/@lucide_vue@1.23.0_vue@3.5.39_typescript@5.8.3_/node_modules/@lucide/vue/dist/esm/icons/eye-off.js";
12
+ import ie from "../external/.pnpm/@lucide_vue@1.23.0_vue@3.5.39_typescript@5.8.3_/node_modules/@lucide/vue/dist/esm/icons/eye.js";
13
+ import ae from "../external/.pnpm/@lucide_vue@1.23.0_vue@3.5.39_typescript@5.8.3_/node_modules/@lucide/vue/dist/esm/icons/list-tree.js";
14
+ import oe from "../code/xml-diff.js";
12
15
  import "../code/index.js";
13
- import oe from "./element-detail.js";
14
- import { buildDetail as se, buildSummary as a } from "./build-view-model.js";
15
- import ce from "./merge-progress.js";
16
- import le from "./merge-summary.js";
17
- import ue from "./merge-tree.js";
18
- import { useDocumentProgress as de } from "./use-document-progress.js";
19
- import { useMergeSession as fe } from "./use-merge-session.js";
20
- import { Fragment as o, computed as s, createBlock as c, createCommentVNode as l, createElementBlock as u, createElementVNode as d, createTextVNode as f, createVNode as p, defineComponent as m, normalizeClass as h, onMounted as pe, openBlock as g, ref as _, renderList as me, toDisplayString as v, unref as y, vShow as he, withCtx as b, withDirectives as x } from "vue";
16
+ import se from "./element-detail.js";
17
+ import { buildDetail as ce, buildSummary as s } from "./build-view-model.js";
18
+ import le from "./merge-progress.js";
19
+ import ue from "./merge-summary.js";
20
+ import de from "./merge-tree.js";
21
+ import fe from "./type-name-authority.js";
22
+ import { useDocumentProgress as pe } from "./use-document-progress.js";
23
+ import { useMergeSession as me } from "./use-merge-session.js";
24
+ import { Fragment as c, computed as l, createBlock as u, createCommentVNode as d, createElementBlock as f, createElementVNode as p, createTextVNode as m, createVNode as h, defineComponent as g, normalizeClass as _, onMounted as he, openBlock as v, ref as y, renderList as ge, resolveDynamicComponent as _e, toDisplayString as b, unref as x, vShow as ve, watch as ye, withCtx as S, withDirectives as C } from "vue";
21
25
  //#region lib/merge/merge-review.vue?vue&type=script&setup=true&lang.ts
22
- var S = { class: "flex h-full flex-col" }, C = { class: "flex flex-wrap items-center justify-between gap-x-8 gap-y-3 border-b border-base-300 px-4 py-2.5" }, w = {
26
+ var w = { class: "flex h-full flex-col" }, T = { class: "flex flex-wrap items-center justify-between gap-x-8 gap-y-3 border-b border-base-300 px-4 py-2.5" }, E = {
23
27
  key: 0,
24
28
  class: "flex flex-col items-start gap-x-4 gap-y-1 text-xs md:flex-row md:items-center"
25
- }, T = {
29
+ }, D = {
26
30
  key: 0,
27
31
  class: "flex items-baseline gap-1.5"
28
- }, E = { class: "font-semibold" }, D = { class: "text-base-content/60" }, O = {
32
+ }, O = { class: "font-semibold" }, k = { class: "text-base-content/60" }, A = {
29
33
  key: 0,
30
34
  class: "uppercase"
31
- }, k = { key: 1 }, A = {
35
+ }, j = { key: 1 }, M = {
32
36
  key: 1,
33
37
  class: "flex items-baseline gap-1.5"
34
- }, j = { class: "font-semibold" }, M = { class: "text-base-content/60" }, N = {
38
+ }, N = { class: "font-semibold" }, P = { class: "text-base-content/60" }, be = {
35
39
  key: 0,
36
40
  class: "uppercase"
37
- }, P = { key: 1 }, F = {
41
+ }, xe = { key: 1 }, Se = {
38
42
  key: 0,
39
43
  class: "border-b border-error/40 bg-error/10 p-2 text-xs whitespace-pre-wrap text-error"
40
- }, I = { class: "min-h-0 flex-1" }, L = { class: "h-full" }, R = {
44
+ }, Ce = { class: "min-h-0 flex-1" }, we = { class: "h-full" }, Te = { class: "flex shrink-0 items-center gap-3 border-b border-base-300 px-3 py-1.5 text-xs" }, Ee = { class: "flex items-center gap-1" }, De = ["title"], Oe = { class: "min-h-0 flex-1 overflow-y-auto" }, ke = {
41
45
  key: 2,
42
46
  class: "grid h-full place-items-center p-6 text-center"
43
- }, ge = { class: "flex flex-col items-center gap-1" }, _e = {
47
+ }, Ae = { class: "flex flex-col items-center gap-1" }, je = {
44
48
  key: 0,
45
49
  class: "text-xs opacity-70"
46
- }, ve = { class: "flex items-center justify-end gap-2 border-t border-base-300 p-2" }, z = /*@__PURE__*/ m({
50
+ }, Me = { class: "flex items-center justify-end gap-2 border-t border-base-300 p-2" }, F = /*@__PURE__*/ g({
47
51
  __name: "merge-review",
48
52
  props: {
49
53
  targetDocument: {},
@@ -57,176 +61,225 @@ var S = { class: "flex h-full flex-col" }, C = { class: "flex flex-wrap items-ce
57
61
  target: {}
58
62
  },
59
63
  emits: ["applied", "close"],
60
- setup(m, { emit: z }) {
61
- let B = m, V = z, H = fe(B), { structuralTree: U, previewXml: ye, previewBeforeXml: be, previewLoading: xe } = H, { progress: Se, history: Ce, track: W } = de(() => B.targetDocument.state), G = _("review"), K = _(!1), q = _(), J = _(), Y = _(), X = _(), Z = _(), we = [
64
+ setup(g, { emit: F }) {
65
+ let I = g, L = F, R = me(I), { structuralTree: z, previewXml: B, previewBeforeXml: Ne, previewLoading: Pe } = R, V = l({
66
+ get: () => R.keepNameTypesFrom.value,
67
+ set: (e) => R.setKeepNameTypesFrom(e)
68
+ }), { progress: Fe, history: Ie, track: H } = pe(() => I.targetDocument.state), U = y("review"), W = y(!1), G = y(), K = y(), q = y(), J = y(), Y = y(), X = y(!0), Z = y(), Le = [
62
69
  "Review",
63
70
  "Confirm",
64
71
  "Done"
65
- ], Q = s(() => ({
72
+ ], Q = l(() => ({
66
73
  review: 0,
67
74
  confirm: 1,
68
75
  done: 2
69
- })[G.value]), Te = s(() => {
76
+ })[U.value]), Re = l(() => {
70
77
  let e = {};
71
- for (let t of H.report.value?.groups ?? []) e[t.id] = H.decisionOf(t.id);
78
+ for (let t of R.report.value?.groups ?? []) e[t.id] = R.decisionOf(t.id);
72
79
  return e;
73
- });
74
- pe(async () => {
75
- q.value = "Analyzing template…", K.value = !0;
80
+ }), ze = l(() => {
81
+ let e = z.value;
82
+ if (X.value) return e.items;
83
+ let t = new Set(e.expanded);
84
+ function n(e) {
85
+ let r = [];
86
+ for (let i of e) {
87
+ if (!t.has(i.id)) continue;
88
+ let e = i.children ? n(i.children) : void 0;
89
+ r.push({
90
+ ...i,
91
+ children: e?.length ? e : void 0
92
+ });
93
+ }
94
+ return r;
95
+ }
96
+ return n(e.items);
97
+ }), Be = l(() => Z.value ?? z.value.expanded);
98
+ ye(z, () => {
99
+ Z.value = void 0;
100
+ }), he(async () => {
101
+ G.value = "Analyzing template…", W.value = !0;
76
102
  try {
77
- await W(H.load());
103
+ await H(R.load());
78
104
  } catch (e) {
79
- J.value = e instanceof Error ? e.stack ?? e.message : String(e);
105
+ K.value = e instanceof Error ? e.stack ?? e.message : String(e);
80
106
  } finally {
81
- K.value = !1;
107
+ W.value = !1;
82
108
  }
83
109
  });
84
110
  function $() {
85
111
  return {
86
- sourceQuery: B.sourceQuery,
87
- targetQuery: B.targetDocument.query
112
+ sourceQuery: I.sourceQuery,
113
+ targetQuery: I.targetDocument.query
88
114
  };
89
115
  }
90
- async function Ee(e) {
91
- let t = U.value.index[e.id];
116
+ function Ve() {
117
+ let e = z.value, t = new Set(e.expanded);
118
+ function n(r, i) {
119
+ for (let a of r) {
120
+ let r = (e.meta[a.id]?.change ?? "unchanged") !== "unchanged", o = i || r;
121
+ o && a.children?.length && t.add(a.id), a.children && n(a.children, o);
122
+ }
123
+ }
124
+ n(e.items, !1), Z.value = [...t];
125
+ }
126
+ async function He(e) {
127
+ let t = z.value.index[e.id];
92
128
  if (!t) return;
93
- H.select(t), X.value = t.role === "primary" ? t.groupId : void 0;
94
- let n = X.value ? H.report.value?.groups.find((e) => e.id === X.value) : void 0, r = t.node ? await se(t.node, n, $()) : void 0;
129
+ R.select(t), J.value = t.role === "primary" ? t.groupId : void 0;
130
+ let n = J.value ? R.report.value?.groups.find((e) => e.id === J.value) : void 0, r = t.node ? await ce(t.node, n, $()) : void 0;
95
131
  if (r) {
96
- let e = await H.stagedAttributes(t.previewRef);
132
+ let e = await R.stagedAttributes(t.previewRef);
97
133
  for (let t of r.attributes) t.editable && e[t.name] != null && (t.after = e[t.name]);
98
134
  }
99
- Y.value = r;
135
+ q.value = r;
100
136
  }
101
- function De(e, t) {
102
- H.setDecision(e, t);
137
+ function Ue(e, t) {
138
+ R.setDecision(e, t);
103
139
  }
104
- function Oe(e, t) {
105
- if (!X.value || !Y.value) return;
106
- H.setValue(X.value, e, t);
107
- let n = Y.value.attributes.find((t) => t.name === e);
140
+ function We(e, t) {
141
+ if (!J.value || !q.value) return;
142
+ R.setValue(J.value, e, t);
143
+ let n = q.value.attributes.find((t) => t.name === e);
108
144
  n && (n.after = t);
109
145
  }
110
- async function ke() {
111
- let e = H.report.value;
112
- e && (Z.value = await a(e, H.decisionOf, H.editedValue, $()), G.value = "confirm");
146
+ async function Ge() {
147
+ let e = R.report.value;
148
+ e && (Y.value = await s(e, R.decisionOf, R.editedValue, $()), U.value = "confirm");
113
149
  }
114
- async function Ae() {
115
- q.value = "Applying changes…", K.value = !0;
150
+ async function Ke() {
151
+ G.value = "Applying changes…", W.value = !0;
116
152
  try {
117
- await W(H.commit()), G.value = "done";
153
+ await H(R.commit()), U.value = "done";
118
154
  } catch (e) {
119
- J.value = e instanceof Error ? e.stack ?? e.message : String(e);
155
+ K.value = e instanceof Error ? e.stack ?? e.message : String(e);
120
156
  } finally {
121
- K.value = !1;
157
+ W.value = !1;
122
158
  }
123
159
  }
124
- return (se, a) => (g(), u("div", S, [
125
- d("header", C, [p(y(ee), {
160
+ return (ce, s) => (v(), f("div", w, [
161
+ p("header", T, [h(x(i), {
126
162
  "model-value": Q.value + 1,
127
163
  class: "flex items-center",
128
164
  "aria-label": "Merge steps"
129
165
  }, {
130
- default: b(() => [(g(), u(o, null, me(we, (e, t) => (g(), u(o, { key: e }, [t > 0 ? (g(), u("div", {
166
+ default: S(() => [(v(), f(c, null, ge(Le, (e, t) => (v(), f(c, { key: e }, [t > 0 ? (v(), f("div", {
131
167
  key: 0,
132
- class: h(["mx-3 h-px w-8 transition-colors", t <= Q.value ? "bg-primary" : "bg-base-300"])
133
- }, null, 2)) : l("", !0), p(y(te), {
168
+ class: _(["mx-3 h-px w-8 transition-colors", t <= Q.value ? "bg-primary" : "bg-base-300"])
169
+ }, null, 2)) : d("", !0), h(x(a), {
134
170
  step: t + 1,
135
171
  class: "flex items-center gap-2"
136
172
  }, {
137
- default: b(() => [p(y(i), { class: h(["grid size-6 place-items-center rounded-full border text-xs font-semibold transition-colors", t < Q.value ? "border-primary bg-primary text-primary-content" : t === Q.value ? "border-primary text-primary" : "border-base-300 text-base-content/40"]) }, {
138
- default: b(() => [t < Q.value ? (g(), c(y(ie), {
173
+ default: S(() => [h(x(o), { class: _(["grid size-6 place-items-center rounded-full border text-xs font-semibold transition-colors", t < Q.value ? "border-primary bg-primary text-primary-content" : t === Q.value ? "border-primary text-primary" : "border-base-300 text-base-content/40"]) }, {
174
+ default: S(() => [t < Q.value ? (v(), u(x(ne), {
139
175
  key: 0,
140
176
  class: "size-3.5"
141
- })) : (g(), u(o, { key: 1 }, [f(v(t + 1), 1)], 64))]),
177
+ })) : (v(), f(c, { key: 1 }, [m(b(t + 1), 1)], 64))]),
142
178
  _: 2
143
- }, 1032, ["class"]), p(y(ne), { class: h(["text-xs font-medium transition-colors", t === Q.value ? "text-base-content" : t < Q.value ? "text-base-content/70" : "text-base-content/40"]) }, {
144
- default: b(() => [f(v(e), 1)]),
179
+ }, 1032, ["class"]), h(x(ee), { class: _(["text-xs font-medium transition-colors", t === Q.value ? "text-base-content" : t < Q.value ? "text-base-content/70" : "text-base-content/40"]) }, {
180
+ default: S(() => [m(b(e), 1)]),
145
181
  _: 2
146
182
  }, 1032, ["class"])]),
147
183
  _: 2
148
184
  }, 1032, ["step"])], 64))), 64))]),
149
185
  _: 1
150
- }, 8, ["model-value"]), m.source || m.target ? (g(), u("div", w, [
151
- m.source ? (g(), u("span", T, [
152
- a[3] ||= d("span", { class: "text-[10px] font-medium uppercase tracking-wide text-base-content/45" }, " Source ", -1),
153
- d("span", E, v(m.source.label), 1),
154
- d("span", D, [
155
- m.source.type ? (g(), u("span", O, v(m.source.type), 1)) : l("", !0),
156
- m.source.type ? (g(), u("span", k, " · ")) : l("", !0),
157
- f("v" + v(m.source.version || "0") + "." + v(m.source.revision || "0"), 1)
186
+ }, 8, ["model-value"]), g.source || g.target ? (v(), f("div", E, [
187
+ g.source ? (v(), f("span", D, [
188
+ s[5] ||= p("span", { class: "text-[10px] font-medium uppercase tracking-wide text-base-content/45" }, " Source ", -1),
189
+ p("span", O, b(g.source.label), 1),
190
+ p("span", k, [
191
+ g.source.type ? (v(), f("span", A, b(g.source.type), 1)) : d("", !0),
192
+ g.source.type ? (v(), f("span", j, " · ")) : d("", !0),
193
+ m("v" + b(g.source.version || "0") + "." + b(g.source.revision || "0"), 1)
158
194
  ])
159
- ])) : l("", !0),
160
- p(y(re), { class: "hidden size-4 shrink-0 text-base-content/40 md:block" }),
161
- m.target ? (g(), u("span", A, [
162
- a[4] ||= d("span", { class: "text-[10px] font-medium uppercase tracking-wide text-base-content/45" }, " Target ", -1),
163
- d("span", j, v(m.target.label), 1),
164
- d("span", M, [
165
- m.target.type ? (g(), u("span", N, v(m.target.type), 1)) : l("", !0),
166
- m.target.type ? (g(), u("span", P, " · ")) : l("", !0),
167
- f("v" + v(m.target.version || "0") + "." + v(m.target.revision || "0"), 1)
195
+ ])) : d("", !0),
196
+ h(x(te), { class: "hidden size-4 shrink-0 text-base-content/40 md:block" }),
197
+ g.target ? (v(), f("span", M, [
198
+ s[6] ||= p("span", { class: "text-[10px] font-medium uppercase tracking-wide text-base-content/45" }, " Target ", -1),
199
+ p("span", N, b(g.target.label), 1),
200
+ p("span", P, [
201
+ g.target.type ? (v(), f("span", be, b(g.target.type), 1)) : d("", !0),
202
+ g.target.type ? (v(), f("span", xe, " · ")) : d("", !0),
203
+ m("v" + b(g.target.version || "0") + "." + b(g.target.revision || "0"), 1)
168
204
  ])
169
- ])) : l("", !0)
170
- ])) : l("", !0)]),
171
- J.value ? (g(), u("div", F, v(J.value), 1)) : l("", !0),
172
- d("div", I, [
173
- K.value ? (g(), c(ce, {
205
+ ])) : d("", !0)
206
+ ])) : d("", !0)]),
207
+ K.value ? (v(), f("div", Se, b(K.value), 1)) : d("", !0),
208
+ p("div", Ce, [
209
+ W.value ? (v(), u(le, {
174
210
  key: 0,
175
- label: q.value,
176
- progress: y(Se),
177
- history: y(Ce)
211
+ label: G.value,
212
+ progress: x(Fe),
213
+ history: x(Ie)
178
214
  }, null, 8, [
179
215
  "label",
180
216
  "progress",
181
217
  "history"
182
- ])) : l("", !0),
183
- x(d("div", L, [p(y(t), {
218
+ ])) : d("", !0),
219
+ C(p("div", we, [h(x(t), {
184
220
  direction: "horizontal",
185
221
  class: "h-full min-h-0"
186
222
  }, {
187
- default: b(() => [
188
- p(y(n), {
223
+ default: S(() => [
224
+ h(x(n), {
189
225
  "default-size": 42,
190
- class: "h-full overflow-auto"
226
+ class: "flex h-full min-h-0 flex-col"
191
227
  }, {
192
- default: b(() => [p(ue, {
193
- items: y(U).items,
194
- meta: y(U).meta,
195
- decisions: Te.value,
196
- "expanded-items": y(U).expanded,
197
- onSelect: Ee,
198
- "onUpdate:decision": De
228
+ default: S(() => [p("div", Te, [
229
+ h(fe, {
230
+ modelValue: V.value,
231
+ "onUpdate:modelValue": s[0] ||= (e) => V.value = e
232
+ }, null, 8, ["modelValue"]),
233
+ s[7] ||= p("div", { class: "ml-auto h-4 w-px shrink-0 bg-base-300" }, null, -1),
234
+ p("div", Ee, [p("button", {
235
+ type: "button",
236
+ class: _(["btn btn-ghost btn-xs btn-square", { "text-primary": X.value }]),
237
+ title: X.value ? "Hide unchanged elements" : "Show unchanged elements",
238
+ onClick: s[1] ||= (e) => X.value = !X.value
239
+ }, [(v(), u(_e(X.value ? x(ie) : x(re)), { class: "h-4 w-4" }))], 10, De), p("button", {
240
+ type: "button",
241
+ class: "btn btn-ghost btn-xs btn-square",
242
+ title: "Expand all differences",
243
+ onClick: Ve
244
+ }, [h(x(ae), { class: "h-4 w-4" })])])
245
+ ]), p("div", Oe, [h(de, {
246
+ items: ze.value,
247
+ meta: x(z).meta,
248
+ decisions: Re.value,
249
+ "expanded-items": Be.value,
250
+ onSelect: He,
251
+ "onUpdate:decision": Ue
199
252
  }, null, 8, [
200
253
  "items",
201
254
  "meta",
202
255
  "decisions",
203
256
  "expanded-items"
204
- ])]),
257
+ ])])]),
205
258
  _: 1
206
259
  }),
207
- p(y(r), { class: "w-px bg-base-300" }),
208
- p(y(n), { class: "h-full border-s border-base-300" }, {
209
- default: b(() => [p(y(t), {
260
+ h(x(r), { class: "w-px bg-base-300" }),
261
+ h(x(n), { class: "h-full border-s border-base-300" }, {
262
+ default: S(() => [h(x(t), {
210
263
  direction: "vertical",
211
264
  class: "h-full"
212
265
  }, {
213
- default: b(() => [
214
- p(y(n), {
266
+ default: S(() => [
267
+ h(x(n), {
215
268
  "default-size": 55,
216
269
  class: "min-h-0 overflow-auto"
217
270
  }, {
218
- default: b(() => [p(oe, {
219
- detail: Y.value,
220
- onEdit: Oe
271
+ default: S(() => [h(se, {
272
+ detail: q.value,
273
+ onEdit: We
221
274
  }, null, 8, ["detail"])]),
222
275
  _: 1
223
276
  }),
224
- p(y(r), { class: "h-px bg-base-300" }),
225
- p(y(n), { class: "min-h-0" }, {
226
- default: b(() => [p(y(ae), {
227
- before: y(be),
228
- after: y(ye),
229
- loading: y(xe)
277
+ h(x(r), { class: "h-px bg-base-300" }),
278
+ h(x(n), { class: "min-h-0" }, {
279
+ default: S(() => [h(x(oe), {
280
+ before: x(Ne),
281
+ after: x(B),
282
+ loading: x(Pe)
230
283
  }, null, 8, [
231
284
  "before",
232
285
  "after",
@@ -241,65 +294,65 @@ var S = { class: "flex h-full flex-col" }, C = { class: "flex flex-wrap items-ce
241
294
  })
242
295
  ]),
243
296
  _: 1
244
- })], 512), [[he, !K.value && G.value === "review"]]),
245
- !K.value && G.value === "confirm" && Z.value ? (g(), c(le, {
297
+ })], 512), [[ve, !W.value && U.value === "review"]]),
298
+ !W.value && U.value === "confirm" && Y.value ? (v(), u(ue, {
246
299
  key: 1,
247
- summary: Z.value,
248
- scenario: m.scenario,
249
- verb: m.verb
300
+ summary: Y.value,
301
+ scenario: g.scenario,
302
+ verb: g.verb
250
303
  }, null, 8, [
251
304
  "summary",
252
305
  "scenario",
253
306
  "verb"
254
- ])) : l("", !0),
255
- !K.value && G.value === "done" ? (g(), u("div", R, [d("div", ge, [
256
- a[5] ||= d("span", { class: "text-3xl text-success" }, "✓", -1),
257
- a[6] ||= d("p", { class: "font-medium" }, "Applied", -1),
258
- Z.value ? (g(), u("p", _e, v(Z.value.added.length) + " added · " + v(Z.value.updated.length) + " updated · " + v(Z.value.skipped.length) + " skipped ", 1)) : l("", !0)
259
- ])])) : l("", !0)
307
+ ])) : d("", !0),
308
+ !W.value && U.value === "done" ? (v(), f("div", ke, [p("div", Ae, [
309
+ s[8] ||= p("span", { class: "text-3xl text-success" }, "✓", -1),
310
+ s[9] ||= p("p", { class: "font-medium" }, "Applied", -1),
311
+ Y.value ? (v(), f("p", je, b(Y.value.added.length) + " added · " + b(Y.value.updated.length) + " updated · " + b(Y.value.skipped.length) + " skipped ", 1)) : d("", !0)
312
+ ])])) : d("", !0)
260
313
  ]),
261
- d("footer", ve, [G.value === "review" ? (g(), u(o, { key: 0 }, [p(e, {
314
+ p("footer", Me, [U.value === "review" ? (v(), f(c, { key: 0 }, [h(e, {
262
315
  variant: "ghost",
263
316
  size: "sm",
264
- onClick: a[0] ||= (e) => V("close")
317
+ onClick: s[2] ||= (e) => L("close")
265
318
  }, {
266
- default: b(() => [...a[7] ||= [f("Close", -1)]]),
319
+ default: S(() => [...s[10] ||= [m("Close", -1)]]),
267
320
  _: 1
268
- }), p(e, {
321
+ }), h(e, {
269
322
  color: "primary",
270
323
  size: "sm",
271
- disabled: K.value || !!J.value,
272
- onClick: ke
324
+ disabled: W.value || !!K.value,
325
+ onClick: Ge
273
326
  }, {
274
- default: b(() => [...a[8] ||= [f(" Next: Confirm ", -1)]]),
327
+ default: S(() => [...s[11] ||= [m(" Next: Confirm ", -1)]]),
275
328
  _: 1
276
- }, 8, ["disabled"])], 64)) : G.value === "confirm" ? (g(), u(o, { key: 1 }, [p(e, {
329
+ }, 8, ["disabled"])], 64)) : U.value === "confirm" ? (v(), f(c, { key: 1 }, [h(e, {
277
330
  variant: "ghost",
278
331
  size: "sm",
279
- disabled: K.value,
280
- onClick: a[1] ||= (e) => G.value = "review"
332
+ disabled: W.value,
333
+ onClick: s[3] ||= (e) => U.value = "review"
281
334
  }, {
282
- default: b(() => [...a[9] ||= [f("Back", -1)]]),
335
+ default: S(() => [...s[12] ||= [m("Back", -1)]]),
283
336
  _: 1
284
- }, 8, ["disabled"]), p(e, {
337
+ }, 8, ["disabled"]), h(e, {
285
338
  color: "primary",
286
339
  size: "sm",
287
- disabled: K.value,
288
- onClick: Ae
340
+ disabled: W.value,
341
+ onClick: Ke
289
342
  }, {
290
- default: b(() => [...a[10] ||= [f("Apply", -1)]]),
343
+ default: S(() => [...s[13] ||= [m("Apply", -1)]]),
291
344
  _: 1
292
- }, 8, ["disabled"])], 64)) : (g(), c(e, {
345
+ }, 8, ["disabled"])], 64)) : (v(), u(e, {
293
346
  key: 2,
294
347
  color: "primary",
295
348
  size: "sm",
296
- onClick: a[2] ||= (e) => V("applied")
349
+ onClick: s[4] ||= (e) => L("applied")
297
350
  }, {
298
- default: b(() => [...a[11] ||= [f("Close", -1)]]),
351
+ default: S(() => [...s[14] ||= [m("Close", -1)]]),
299
352
  _: 1
300
353
  }))])
301
354
  ]));
302
355
  }
303
356
  });
304
357
  //#endregion
305
- export { z as default };
358
+ export { F as default };
@@ -1,36 +1,38 @@
1
- import { i as e } from "../external/.pnpm/@dialecte_scl@0.3.5/node_modules/@dialecte/scl/dist/hooks-abaf9148.js";
2
- import "../external/.pnpm/@dialecte_scl@0.3.5/node_modules/@dialecte/scl/dist/v2019C1/index.js";
1
+ import { i as e } from "../external/.pnpm/@dialecte_scl@0.3.7/node_modules/@dialecte/scl/dist/hooks-ByGralT8.js";
2
+ import "../external/.pnpm/@dialecte_scl@0.3.7/node_modules/@dialecte/scl/dist/v2019C1/index.js";
3
3
  //#region lib/merge/merge.service.ts
4
4
  async function t(e, t) {
5
5
  return e.query.lifecycle.report(t);
6
6
  }
7
- async function n(e, t, n, r, i) {
7
+ async function n({ doc: e, target: t, report: n, decisions: r, keepNameTypesFrom: i, afterApply: a }) {
8
8
  return e.prepare(async (e) => {
9
- let a = await e.lifecycle.apply({
9
+ let o = await e.lifecycle.apply({
10
10
  ...t,
11
11
  report: n,
12
- decisions: r
12
+ decisions: r,
13
+ keepNameTypesFrom: i
13
14
  });
14
- await i?.(e, {
15
+ await a?.(e, {
15
16
  target: t,
16
17
  report: n,
17
18
  decisions: r,
18
- result: a
19
+ result: o
19
20
  });
20
21
  });
21
22
  }
22
- async function r(e, t, n, r, i) {
23
+ async function r({ doc: e, target: t, report: n, decisions: r, keepNameTypesFrom: i, afterApply: a }) {
23
24
  await e.transaction(async (e) => {
24
- let a = await e.lifecycle.apply({
25
+ let o = await e.lifecycle.apply({
25
26
  ...t,
26
27
  report: n,
27
- decisions: r
28
+ decisions: r,
29
+ keepNameTypesFrom: i
28
30
  });
29
- await i?.(e, {
31
+ await a?.(e, {
30
32
  target: t,
31
33
  report: n,
32
34
  decisions: r,
33
- result: a
35
+ result: o
34
36
  });
35
37
  });
36
38
  }
@@ -0,0 +1,5 @@
1
+ import e from "./type-name-authority.vue_vue_type_script_setup_true_lang.js";
2
+ //#region lib/merge/type-name-authority.vue
3
+ var t = e;
4
+ //#endregion
5
+ export { t as default };
@@ -0,0 +1,46 @@
1
+ import { ELEMENT_TO_COLOR as e } from "../icons/element-color-map.generated.js";
2
+ import { ELEMENT_TO_ICON as t } from "../icons/element-icon-mapper.js";
3
+ import { Fragment as n, computed as r, createBlock as i, createCommentVNode as a, createElementBlock as o, createElementVNode as s, defineComponent as c, mergeModels as l, normalizeClass as u, openBlock as d, resolveDynamicComponent as f, unref as p, useModel as m } from "vue";
4
+ //#region lib/merge/type-name-authority.vue?vue&type=script&setup=true&lang.ts
5
+ var h = {
6
+ class: "flex items-center gap-1.5",
7
+ title: "Type de-duplication in the DataTypeTemplates section: when an incoming type is identical to an existing one but named differently, keep the name from this document"
8
+ }, g = {
9
+ class: "join",
10
+ role: "group",
11
+ "aria-label": "Keep type names from the target or the source document"
12
+ }, _ = ["disabled", "aria-pressed"], v = ["disabled", "aria-pressed"], y = /*@__PURE__*/ c({
13
+ __name: "type-name-authority",
14
+ props: /*@__PURE__*/ l({
15
+ size: {},
16
+ disabled: { type: Boolean },
17
+ hideLabel: { type: Boolean }
18
+ }, {
19
+ modelValue: { required: !0 },
20
+ modelModifiers: {}
21
+ }),
22
+ emits: ["update:modelValue"],
23
+ setup(c) {
24
+ let l = m(c, "modelValue"), y = c, b = t.DataTypeTemplates, x = e.DataTypeTemplates, S = r(() => ({
25
+ xs: "btn-xs",
26
+ sm: "btn-sm",
27
+ md: "btn-md",
28
+ undefined: "btn-xs"
29
+ })[y.size ?? "undefined"]);
30
+ return (e, t) => (d(), o("div", h, [c.hideLabel ? a("", !0) : (d(), o(n, { key: 0 }, [s("span", { class: u(["inline-flex items-center justify-center rounded-full p-1", [p(x).text, p(x).background]]) }, [(d(), i(f(p(b)), { class: "h-3.5 w-3.5" }))], 2), t[2] ||= s("span", { class: "text-base-content/60" }, "DataTypeTemplates - keep type names from:", -1)], 64)), s("div", g, [s("button", {
31
+ type: "button",
32
+ class: u(["btn join-item", [S.value, l.value === "target" ? "btn-primary" : "btn-ghost"]]),
33
+ disabled: c.disabled,
34
+ "aria-pressed": l.value === "target",
35
+ onClick: t[0] ||= (e) => l.value = "target"
36
+ }, " Target ", 10, _), s("button", {
37
+ type: "button",
38
+ class: u(["btn join-item", [S.value, l.value === "source" ? "btn-primary" : "btn-ghost"]]),
39
+ disabled: c.disabled,
40
+ "aria-pressed": l.value === "source",
41
+ onClick: t[1] ||= (e) => l.value = "source"
42
+ }, " Source ", 10, v)])]));
43
+ }
44
+ });
45
+ //#endregion
46
+ export { y as default };