Add reviewed FXML View generation in both hosts

This commit is contained in:
2026-11-13 21:39:06 +01:00
parent 1856f69637
commit 9ab1a4f530
18 changed files with 1463 additions and 9 deletions
@@ -401,6 +401,10 @@ public final class BindingDiscovery {
var tables = new TableDiscovery(loader, repeats, modelType, owner);
var problems = new ArrayList<>(validate(doc, imports, ids, converters));
problems.addAll(tables.validate(doc));
var componentOptions = repeats.candidates(selected);
for (var a : attributes)
if (a.path().equals(selected) && a.kind().equals("COMPLEX"))
componentOptions = repeats.modelCandidates(a.type());
return new BindingMetadata(
model,
selected,
@@ -414,7 +418,7 @@ public final class BindingDiscovery {
owner.viewModel == null ? "" : owner.viewModel.getName(),
owner.methods(chosen == null ? null : chosen.type()),
repeats.collections(),
repeats.candidates(selected),
componentOptions,
repeats.panes(),
tables.collections(),
tables.rows(selected),
@@ -115,6 +115,11 @@ final class RepeatDiscovery {
.toList();
}
List<RepeatOption> modelCandidates(String type) {
var source = new RepeatOption("", type, "COMPATIBLE", "Nested Model type");
return names.stream().map(n -> component(n, source)).toList();
}
List<RepeatOption> candidates(String path) {
return names.stream().map(n -> component(n, path)).toList();
}