jupiter-dynamic-forms 1.9.10 → 1.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/add-column-dialog.d.ts.map +1 -1
- package/dist/core/dynamic-form.d.ts.map +1 -1
- package/dist/core/filter-roles-dialog.d.ts.map +1 -1
- package/dist/core/form-section.d.ts.map +1 -1
- package/dist/index.js +68 -69
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +435 -200
- package/dist/index.mjs.map +1 -1
- package/dist/utils/i18n.d.ts +38 -0
- package/dist/utils/i18n.d.ts.map +1 -0
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -573,9 +573,9 @@ class XBRLFormBuilder {
|
|
|
573
573
|
return a2.role.localeCompare(b2.role);
|
|
574
574
|
});
|
|
575
575
|
sortedRoles.forEach((role) => {
|
|
576
|
-
const
|
|
577
|
-
this.assignFieldColumnIds(
|
|
578
|
-
sections.push(
|
|
576
|
+
const section2 = this.buildSectionFromRole(role, periodStartDate, periodEndDate, hypercubeData, language, periodPreferences);
|
|
577
|
+
this.assignFieldColumnIds(section2);
|
|
578
|
+
sections.push(section2);
|
|
579
579
|
});
|
|
580
580
|
return {
|
|
581
581
|
formId: `xbrl-form-${Date.now()}`,
|
|
@@ -789,12 +789,12 @@ class XBRLFormBuilder {
|
|
|
789
789
|
/**
|
|
790
790
|
* Assign appropriate column IDs to fields based on section's generated columns
|
|
791
791
|
*/
|
|
792
|
-
static assignFieldColumnIds(
|
|
793
|
-
if (!
|
|
792
|
+
static assignFieldColumnIds(section2) {
|
|
793
|
+
if (!section2.columns || section2.columns.length === 0) {
|
|
794
794
|
return;
|
|
795
795
|
}
|
|
796
|
-
const columnIds =
|
|
797
|
-
|
|
796
|
+
const columnIds = section2.columns.map((col) => col.id);
|
|
797
|
+
section2.concepts.forEach((conceptTree) => {
|
|
798
798
|
this.assignColumnIdsToConceptFields(conceptTree, columnIds);
|
|
799
799
|
});
|
|
800
800
|
}
|
|
@@ -961,52 +961,52 @@ class XBRLFormBuilder {
|
|
|
961
961
|
const previousYearColumns = [];
|
|
962
962
|
const prevStartDate = this.getPreviousYearDate(periodStartDate);
|
|
963
963
|
const prevEndDate = this.getPreviousYearDate(periodEndDate);
|
|
964
|
-
currentYearColumns.forEach((
|
|
965
|
-
let prevTitle =
|
|
964
|
+
currentYearColumns.forEach((column2, index) => {
|
|
965
|
+
let prevTitle = column2.title;
|
|
966
966
|
let prevDescription = "";
|
|
967
967
|
let prevId = "";
|
|
968
|
-
if (
|
|
969
|
-
prevTitle =
|
|
970
|
-
if (
|
|
968
|
+
if (column2.dimensionData) {
|
|
969
|
+
prevTitle = column2.title;
|
|
970
|
+
if (column2.description && column2.description.includes("/")) {
|
|
971
971
|
prevDescription = `${prevStartDate} / ${prevEndDate}`;
|
|
972
972
|
} else {
|
|
973
973
|
prevDescription = prevEndDate;
|
|
974
974
|
}
|
|
975
|
-
prevId = `${
|
|
975
|
+
prevId = `${column2.id}_prev`;
|
|
976
976
|
} else {
|
|
977
|
-
if (
|
|
977
|
+
if (column2.id === "instant" || column2.id.includes("instant")) {
|
|
978
978
|
prevTitle = prevEndDate;
|
|
979
979
|
prevDescription = "";
|
|
980
980
|
prevId = `instant_prev_${index}`;
|
|
981
|
-
} else if (
|
|
981
|
+
} else if (column2.id === "duration" || column2.id.includes("duration")) {
|
|
982
982
|
prevTitle = `${prevStartDate} / ${prevEndDate}`;
|
|
983
983
|
prevDescription = "";
|
|
984
984
|
prevId = `duration_prev_${index}`;
|
|
985
|
-
} else if (
|
|
985
|
+
} else if (column2.title.includes("/")) {
|
|
986
986
|
prevTitle = `${prevStartDate} / ${prevEndDate}`;
|
|
987
987
|
prevDescription = "";
|
|
988
|
-
prevId = `${
|
|
988
|
+
prevId = `${column2.id}_prev`;
|
|
989
989
|
} else {
|
|
990
990
|
prevTitle = prevEndDate;
|
|
991
991
|
prevDescription = "";
|
|
992
|
-
prevId = `${
|
|
992
|
+
prevId = `${column2.id}_prev`;
|
|
993
993
|
}
|
|
994
994
|
}
|
|
995
995
|
previousYearColumns.push({
|
|
996
|
-
...
|
|
996
|
+
...column2,
|
|
997
997
|
id: prevId,
|
|
998
998
|
title: prevTitle,
|
|
999
999
|
description: prevDescription,
|
|
1000
|
-
order:
|
|
1000
|
+
order: column2.order + 100,
|
|
1001
1001
|
// Place after current year columns
|
|
1002
1002
|
removable: true,
|
|
1003
1003
|
periodStartDate: prevStartDate,
|
|
1004
1004
|
// Set previous year start date
|
|
1005
1005
|
periodEndDate: prevEndDate,
|
|
1006
1006
|
// Set previous year end date
|
|
1007
|
-
dimensionData:
|
|
1008
|
-
...
|
|
1009
|
-
dimensionId: `${
|
|
1007
|
+
dimensionData: column2.dimensionData ? {
|
|
1008
|
+
...column2.dimensionData,
|
|
1009
|
+
dimensionId: `${column2.dimensionData.dimensionId}_prev`
|
|
1010
1010
|
} : void 0
|
|
1011
1011
|
});
|
|
1012
1012
|
});
|
|
@@ -1016,10 +1016,10 @@ class XBRLFormBuilder {
|
|
|
1016
1016
|
* Filter columns based on user's period preferences
|
|
1017
1017
|
*/
|
|
1018
1018
|
static filterColumnsByPeriodPreferences(columns, preferences) {
|
|
1019
|
-
return columns.filter((
|
|
1019
|
+
return columns.filter((column2) => {
|
|
1020
1020
|
var _a, _b, _c, _d;
|
|
1021
|
-
const isDuration =
|
|
1022
|
-
const isInstant =
|
|
1021
|
+
const isDuration = column2.id.includes("duration") || ((_b = (_a = column2.dimensionData) == null ? void 0 : _a.dimensionId) == null ? void 0 : _b.includes("duration"));
|
|
1022
|
+
const isInstant = column2.id.includes("instant") || ((_d = (_c = column2.dimensionData) == null ? void 0 : _c.dimensionId) == null ? void 0 : _d.includes("instant"));
|
|
1023
1023
|
if (!isDuration && !isInstant) {
|
|
1024
1024
|
return true;
|
|
1025
1025
|
}
|
|
@@ -1558,6 +1558,239 @@ class XBRLFormBuilder {
|
|
|
1558
1558
|
}];
|
|
1559
1559
|
}
|
|
1560
1560
|
}
|
|
1561
|
+
const form$1 = {
|
|
1562
|
+
loading: "Loading form...",
|
|
1563
|
+
submit: "Submit",
|
|
1564
|
+
saveDraft: "Save Draft",
|
|
1565
|
+
errors: "Errors",
|
|
1566
|
+
modified: "Modified",
|
|
1567
|
+
valid: "Valid",
|
|
1568
|
+
yes: "Yes",
|
|
1569
|
+
no: "No",
|
|
1570
|
+
noRoleSelected: "No Role Selected",
|
|
1571
|
+
pleaseSelectRole: "Please select a role from the list on the left."
|
|
1572
|
+
};
|
|
1573
|
+
const filter$1 = {
|
|
1574
|
+
selectRoles: "Select Roles",
|
|
1575
|
+
filterRoles: "Filter Roles",
|
|
1576
|
+
title: "Filter Roles",
|
|
1577
|
+
description: "Select the roles you want to display in the form. You can search and choose specific roles to focus on or manage all available roles.",
|
|
1578
|
+
searchPlaceholder: "Search roles by name, ID, or URI...",
|
|
1579
|
+
clearSearch: "Clear search",
|
|
1580
|
+
showingResults: "Showing",
|
|
1581
|
+
of: "of",
|
|
1582
|
+
roles: "roles",
|
|
1583
|
+
matching: "matching",
|
|
1584
|
+
selectAll: "Select All",
|
|
1585
|
+
selectNone: "Select None",
|
|
1586
|
+
selectFiltered: "Select Filtered",
|
|
1587
|
+
deselectFiltered: "Deselect Filtered",
|
|
1588
|
+
deselectAll: "Deselect All",
|
|
1589
|
+
reset: "Reset",
|
|
1590
|
+
noRolesFound: "No roles found matching",
|
|
1591
|
+
tryDifferentSearch: "Try a different search term or clear the search.",
|
|
1592
|
+
noRolesAvailable: "No roles available.",
|
|
1593
|
+
cancel: "Cancel",
|
|
1594
|
+
applyFilter: "Apply Filter",
|
|
1595
|
+
showPeriodColumn: "Show Period Column:",
|
|
1596
|
+
additionalOptions: "Additional Options:",
|
|
1597
|
+
showPreviousYear: "Show previous year",
|
|
1598
|
+
duration: "Duration",
|
|
1599
|
+
instant: "Instant",
|
|
1600
|
+
uri: "URI"
|
|
1601
|
+
};
|
|
1602
|
+
const column$1 = {
|
|
1603
|
+
addColumn: "Add Column",
|
|
1604
|
+
columnType: "Column Type",
|
|
1605
|
+
instantSingleDate: "Instant (single date)",
|
|
1606
|
+
durationDates: "Duration (start and end dates)",
|
|
1607
|
+
instantDate: "Instant Date",
|
|
1608
|
+
startPeriodDate: "Start Period Date",
|
|
1609
|
+
endPeriodDate: "End Period Date",
|
|
1610
|
+
availableDimensions: "Available Dimensions",
|
|
1611
|
+
dimensionsDescription: "Select dimensions to include in the column. Domain members can be selected here, while typed dimension values will be entered directly in the column header.",
|
|
1612
|
+
enterValue: "Enter value for",
|
|
1613
|
+
enterValuePlaceholder: "Enter value...",
|
|
1614
|
+
selectMember: "Select member:",
|
|
1615
|
+
noMembersAvailable: "No members available for this dimension",
|
|
1616
|
+
cancel: "Cancel",
|
|
1617
|
+
removeColumn: "Remove column",
|
|
1618
|
+
required: "required"
|
|
1619
|
+
};
|
|
1620
|
+
const section$1 = {
|
|
1621
|
+
enterPlaceholder: "Enter"
|
|
1622
|
+
};
|
|
1623
|
+
const admin$1 = {
|
|
1624
|
+
title: "Configure Roles",
|
|
1625
|
+
description: "Select which roles should display the 'Show Previous Year' checkbox and configure period type columns."
|
|
1626
|
+
};
|
|
1627
|
+
const validation$1 = {
|
|
1628
|
+
summary: "Please fix the following errors before submitting:",
|
|
1629
|
+
errorsFound: "errors found"
|
|
1630
|
+
};
|
|
1631
|
+
const enTranslations = {
|
|
1632
|
+
form: form$1,
|
|
1633
|
+
filter: filter$1,
|
|
1634
|
+
column: column$1,
|
|
1635
|
+
section: section$1,
|
|
1636
|
+
admin: admin$1,
|
|
1637
|
+
validation: validation$1
|
|
1638
|
+
};
|
|
1639
|
+
const form = {
|
|
1640
|
+
loading: "Formulier laden...",
|
|
1641
|
+
submit: "Indienen",
|
|
1642
|
+
saveDraft: "Concept opslaan",
|
|
1643
|
+
errors: "Fouten",
|
|
1644
|
+
modified: "Gewijzigd",
|
|
1645
|
+
valid: "Geldig",
|
|
1646
|
+
yes: "Ja",
|
|
1647
|
+
no: "Nee",
|
|
1648
|
+
noRoleSelected: "Geen rol geselecteerd",
|
|
1649
|
+
pleaseSelectRole: "Selecteer een rol uit de lijst aan de linkerkant."
|
|
1650
|
+
};
|
|
1651
|
+
const filter = {
|
|
1652
|
+
selectRoles: "Rollen selecteren",
|
|
1653
|
+
filterRoles: "Rollen filteren",
|
|
1654
|
+
title: "Rollen filteren",
|
|
1655
|
+
description: "Selecteer de rollen die u in het formulier wilt weergeven. U kunt zoeken en specifieke rollen kiezen om op te focussen of alle beschikbare rollen beheren.",
|
|
1656
|
+
searchPlaceholder: "Zoek rollen op naam, ID of URI...",
|
|
1657
|
+
clearSearch: "Zoekopdracht wissen",
|
|
1658
|
+
showingResults: "Weergeven",
|
|
1659
|
+
of: "van",
|
|
1660
|
+
roles: "rollen",
|
|
1661
|
+
matching: "overeenkomend met",
|
|
1662
|
+
selectAll: "Alles selecteren",
|
|
1663
|
+
selectNone: "Niets selecteren",
|
|
1664
|
+
selectFiltered: "Gefilterd selecteren",
|
|
1665
|
+
deselectFiltered: "Gefilterd deselecteren",
|
|
1666
|
+
deselectAll: "Alles deselecteren",
|
|
1667
|
+
reset: "Resetten",
|
|
1668
|
+
noRolesFound: "Geen rollen gevonden die overeenkomen met",
|
|
1669
|
+
tryDifferentSearch: "Probeer een andere zoekterm of wis de zoekopdracht.",
|
|
1670
|
+
noRolesAvailable: "Geen rollen beschikbaar.",
|
|
1671
|
+
cancel: "Annuleren",
|
|
1672
|
+
applyFilter: "Filter toepassen",
|
|
1673
|
+
showPeriodColumn: "Periodekolom weergeven:",
|
|
1674
|
+
additionalOptions: "Aanvullende opties:",
|
|
1675
|
+
showPreviousYear: "Vorig jaar weergeven",
|
|
1676
|
+
duration: "Duur",
|
|
1677
|
+
instant: "Moment",
|
|
1678
|
+
uri: "URI"
|
|
1679
|
+
};
|
|
1680
|
+
const column = {
|
|
1681
|
+
addColumn: "Kolom toevoegen",
|
|
1682
|
+
columnType: "Kolomtype",
|
|
1683
|
+
instantSingleDate: "Moment (enkele datum)",
|
|
1684
|
+
durationDates: "Duur (begin- en einddatum)",
|
|
1685
|
+
instantDate: "Momentdatum",
|
|
1686
|
+
startPeriodDate: "Startdatum periode",
|
|
1687
|
+
endPeriodDate: "Einddatum periode",
|
|
1688
|
+
availableDimensions: "Beschikbare dimensies",
|
|
1689
|
+
dimensionsDescription: "Selecteer dimensies om in de kolom op te nemen. Domeinleden kunnen hier worden geselecteerd, terwijl getypte dimensiewaarden direct in de kolomkop worden ingevoerd.",
|
|
1690
|
+
enterValue: "Voer waarde in voor",
|
|
1691
|
+
enterValuePlaceholder: "Voer waarde in...",
|
|
1692
|
+
selectMember: "Selecteer lid:",
|
|
1693
|
+
noMembersAvailable: "Geen leden beschikbaar voor deze dimensie",
|
|
1694
|
+
cancel: "Annuleren",
|
|
1695
|
+
removeColumn: "Kolom verwijderen",
|
|
1696
|
+
required: "verplicht"
|
|
1697
|
+
};
|
|
1698
|
+
const section = {
|
|
1699
|
+
enterPlaceholder: "Invoeren"
|
|
1700
|
+
};
|
|
1701
|
+
const admin = {
|
|
1702
|
+
title: "Rollen configureren",
|
|
1703
|
+
description: "Selecteer welke rollen het selectievakje 'Vorig jaar weergeven' moeten weergeven en configureer periodetype kolommen."
|
|
1704
|
+
};
|
|
1705
|
+
const validation = {
|
|
1706
|
+
summary: "Corrigeer de volgende fouten voordat u indient:",
|
|
1707
|
+
errorsFound: "fouten gevonden"
|
|
1708
|
+
};
|
|
1709
|
+
const nlTranslations = {
|
|
1710
|
+
form,
|
|
1711
|
+
filter,
|
|
1712
|
+
column,
|
|
1713
|
+
section,
|
|
1714
|
+
admin,
|
|
1715
|
+
validation
|
|
1716
|
+
};
|
|
1717
|
+
const translations = {
|
|
1718
|
+
en: enTranslations,
|
|
1719
|
+
nl: nlTranslations
|
|
1720
|
+
};
|
|
1721
|
+
class I18n {
|
|
1722
|
+
/**
|
|
1723
|
+
* Set the current language
|
|
1724
|
+
* @param language Language code ('en' or 'nl')
|
|
1725
|
+
*/
|
|
1726
|
+
static setLanguage(language) {
|
|
1727
|
+
if (translations[language]) {
|
|
1728
|
+
this.currentLanguage = language;
|
|
1729
|
+
} else {
|
|
1730
|
+
console.warn(`Language '${language}' not supported, falling back to 'en'`);
|
|
1731
|
+
this.currentLanguage = "en";
|
|
1732
|
+
}
|
|
1733
|
+
}
|
|
1734
|
+
/**
|
|
1735
|
+
* Get the current language
|
|
1736
|
+
*/
|
|
1737
|
+
static getLanguage() {
|
|
1738
|
+
return this.currentLanguage;
|
|
1739
|
+
}
|
|
1740
|
+
/**
|
|
1741
|
+
* Translate a key to the current language
|
|
1742
|
+
* @param key Translation key in dot notation (e.g., 'form.submit')
|
|
1743
|
+
* @param params Optional parameters to replace in the translation
|
|
1744
|
+
* @returns Translated string
|
|
1745
|
+
*/
|
|
1746
|
+
static t(key, params) {
|
|
1747
|
+
const keys = key.split(".");
|
|
1748
|
+
let value = translations[this.currentLanguage];
|
|
1749
|
+
for (const k of keys) {
|
|
1750
|
+
if (value && typeof value === "object" && k in value) {
|
|
1751
|
+
value = value[k];
|
|
1752
|
+
} else {
|
|
1753
|
+
console.warn(`Translation key '${key}' not found for language '${this.currentLanguage}'`);
|
|
1754
|
+
return key;
|
|
1755
|
+
}
|
|
1756
|
+
}
|
|
1757
|
+
if (params && typeof value === "string") {
|
|
1758
|
+
return this.interpolate(value, params);
|
|
1759
|
+
}
|
|
1760
|
+
return value;
|
|
1761
|
+
}
|
|
1762
|
+
/**
|
|
1763
|
+
* Interpolate parameters into a string
|
|
1764
|
+
* Supports {{paramName}} syntax
|
|
1765
|
+
*/
|
|
1766
|
+
static interpolate(str, params) {
|
|
1767
|
+
return str.replace(/\{\{(\w+)\}\}/g, (match, key) => {
|
|
1768
|
+
return key in params ? String(params[key]) : match;
|
|
1769
|
+
});
|
|
1770
|
+
}
|
|
1771
|
+
/**
|
|
1772
|
+
* Check if a translation exists for a key
|
|
1773
|
+
*/
|
|
1774
|
+
static has(key) {
|
|
1775
|
+
const keys = key.split(".");
|
|
1776
|
+
let value = translations[this.currentLanguage];
|
|
1777
|
+
for (const k of keys) {
|
|
1778
|
+
if (value && typeof value === "object" && k in value) {
|
|
1779
|
+
value = value[k];
|
|
1780
|
+
} else {
|
|
1781
|
+
return false;
|
|
1782
|
+
}
|
|
1783
|
+
}
|
|
1784
|
+
return value !== void 0;
|
|
1785
|
+
}
|
|
1786
|
+
/**
|
|
1787
|
+
* Get all available languages
|
|
1788
|
+
*/
|
|
1789
|
+
static getAvailableLanguages() {
|
|
1790
|
+
return Object.keys(translations);
|
|
1791
|
+
}
|
|
1792
|
+
}
|
|
1793
|
+
I18n.currentLanguage = "en";
|
|
1561
1794
|
const TYPE_INPUT_MAP = {
|
|
1562
1795
|
// ==========================================
|
|
1563
1796
|
// Dutch XBRL Types (nl-types namespace)
|
|
@@ -2236,8 +2469,8 @@ let JupiterConceptTree = class extends LitElement {
|
|
|
2236
2469
|
</td>
|
|
2237
2470
|
|
|
2238
2471
|
<!-- Input Field Cells (Period Columns) - Only for non-abstract concepts -->
|
|
2239
|
-
${this.columns.map((
|
|
2240
|
-
const field = this._getFieldForColumn(
|
|
2472
|
+
${this.columns.map((column2) => {
|
|
2473
|
+
const field = this._getFieldForColumn(column2.id);
|
|
2241
2474
|
const shouldShowField = !isAbstract && field;
|
|
2242
2475
|
return html`
|
|
2243
2476
|
<td class="field-cell ${!shouldShowField ? "empty" : ""} ${isAbstract ? "abstract-row" : ""}">
|
|
@@ -2246,7 +2479,7 @@ let JupiterConceptTree = class extends LitElement {
|
|
|
2246
2479
|
.field="${field}"
|
|
2247
2480
|
.conceptId="${this.concept.id}"
|
|
2248
2481
|
.conceptType="${this.concept.type}"
|
|
2249
|
-
.columnId="${
|
|
2482
|
+
.columnId="${column2.id}"
|
|
2250
2483
|
.value="${this._getFieldValue(field)}"
|
|
2251
2484
|
.disabled="${this.disabled}"
|
|
2252
2485
|
.locale="${this.locale}"
|
|
@@ -2551,29 +2784,29 @@ let JupiterAddColumnDialog = class extends LitElement {
|
|
|
2551
2784
|
return html`
|
|
2552
2785
|
<div class="dialog" @click="${(e2) => e2.stopPropagation()}">
|
|
2553
2786
|
<div class="dialog-header">
|
|
2554
|
-
<h2 class="dialog-title"
|
|
2787
|
+
<h2 class="dialog-title">${I18n.t("column.addColumn")}</h2>
|
|
2555
2788
|
|
|
2556
2789
|
</div>
|
|
2557
2790
|
|
|
2558
2791
|
<div class="dialog-content">
|
|
2559
2792
|
${this.periodType === "mixed" ? html`
|
|
2560
2793
|
<div class="form-group">
|
|
2561
|
-
<label class="form-label required"
|
|
2794
|
+
<label class="form-label required">${I18n.t("column.columnType")}</label>
|
|
2562
2795
|
<select
|
|
2563
2796
|
class="form-input"
|
|
2564
2797
|
.value="${this._selectedType}"
|
|
2565
2798
|
@change="${this._handleSelectedTypeChange}"
|
|
2566
2799
|
required
|
|
2567
2800
|
>
|
|
2568
|
-
<option value="instant"
|
|
2569
|
-
<option value="duration"
|
|
2801
|
+
<option value="instant">${I18n.t("column.instantSingleDate")}</option>
|
|
2802
|
+
<option value="duration">${I18n.t("column.durationDates")}</option>
|
|
2570
2803
|
</select>
|
|
2571
2804
|
</div>
|
|
2572
2805
|
` : ""}
|
|
2573
2806
|
|
|
2574
2807
|
${this.periodType === "instant" || this.periodType === "mixed" && this._selectedType === "instant" ? html`
|
|
2575
2808
|
<div class="form-group">
|
|
2576
|
-
<label class="form-label required"
|
|
2809
|
+
<label class="form-label required">${I18n.t("column.instantDate")}</label>
|
|
2577
2810
|
<input
|
|
2578
2811
|
type="date"
|
|
2579
2812
|
class="form-input"
|
|
@@ -2585,7 +2818,7 @@ let JupiterAddColumnDialog = class extends LitElement {
|
|
|
2585
2818
|
` : html`
|
|
2586
2819
|
<div class="form-group date-row">
|
|
2587
2820
|
<div class="date-field">
|
|
2588
|
-
<label class="form-label required"
|
|
2821
|
+
<label class="form-label required">${I18n.t("column.startPeriodDate")}</label>
|
|
2589
2822
|
<input
|
|
2590
2823
|
type="date"
|
|
2591
2824
|
class="form-input"
|
|
@@ -2595,7 +2828,7 @@ let JupiterAddColumnDialog = class extends LitElement {
|
|
|
2595
2828
|
/>
|
|
2596
2829
|
</div>
|
|
2597
2830
|
<div class="date-field">
|
|
2598
|
-
<label class="form-label required"
|
|
2831
|
+
<label class="form-label required">${I18n.t("column.endPeriodDate")}</label>
|
|
2599
2832
|
<input
|
|
2600
2833
|
type="date"
|
|
2601
2834
|
class="form-input"
|
|
@@ -2610,8 +2843,8 @@ let JupiterAddColumnDialog = class extends LitElement {
|
|
|
2610
2843
|
<!-- Dimensions Section -->
|
|
2611
2844
|
${this.availableDimensions.length > 0 ? html`
|
|
2612
2845
|
<div class="dimensions-section">
|
|
2613
|
-
<h3
|
|
2614
|
-
<p class="form-description"
|
|
2846
|
+
<h3>${I18n.t("column.availableDimensions")}</h3>
|
|
2847
|
+
<p class="form-description">${I18n.t("column.dimensionsDescription")}</p>
|
|
2615
2848
|
|
|
2616
2849
|
${this.availableDimensions.map((dimension) => {
|
|
2617
2850
|
const isSelected = this._selectedDimensions.has(dimension.id);
|
|
@@ -2637,20 +2870,20 @@ let JupiterAddColumnDialog = class extends LitElement {
|
|
|
2637
2870
|
${isTypedDimension ? html`
|
|
2638
2871
|
<!-- Typed Dimension Input -->
|
|
2639
2872
|
<div class="member-selection">
|
|
2640
|
-
<label
|
|
2873
|
+
<label>${I18n.t("column.enterValue")} ${dimension.conceptName}:</label>
|
|
2641
2874
|
<input
|
|
2642
2875
|
type="text"
|
|
2643
2876
|
class="typed-input"
|
|
2644
2877
|
.value="${(selection == null ? void 0 : selection.typedValue) || ""}"
|
|
2645
2878
|
@input="${(e2) => this._handleTypedValueChange(dimension.id, e2)}"
|
|
2646
|
-
placeholder="
|
|
2879
|
+
placeholder="${I18n.t("column.enterValuePlaceholder")}"
|
|
2647
2880
|
/>
|
|
2648
2881
|
</div>
|
|
2649
2882
|
` : html`
|
|
2650
2883
|
<!-- Domain Members Selection -->
|
|
2651
2884
|
${dimension.members && dimension.members.length > 0 ? html`
|
|
2652
2885
|
<div class="member-selection">
|
|
2653
|
-
<label
|
|
2886
|
+
<label>${I18n.t("column.selectMember")}</label>
|
|
2654
2887
|
<div class="member-list">
|
|
2655
2888
|
${dimension.members.map((member) => html`
|
|
2656
2889
|
<div class="member-option">
|
|
@@ -2669,7 +2902,7 @@ let JupiterAddColumnDialog = class extends LitElement {
|
|
|
2669
2902
|
</div>
|
|
2670
2903
|
</div>
|
|
2671
2904
|
` : html`
|
|
2672
|
-
<p class="form-description"
|
|
2905
|
+
<p class="form-description">${I18n.t("column.noMembersAvailable")}</p>
|
|
2673
2906
|
`}
|
|
2674
2907
|
`}
|
|
2675
2908
|
</div>
|
|
@@ -2683,14 +2916,14 @@ let JupiterAddColumnDialog = class extends LitElement {
|
|
|
2683
2916
|
|
|
2684
2917
|
<div class="dialog-actions">
|
|
2685
2918
|
<button class="btn btn-cancel" @click="${this._handleCancel}">
|
|
2686
|
-
|
|
2919
|
+
${I18n.t("column.cancel")}
|
|
2687
2920
|
</button>
|
|
2688
2921
|
<button
|
|
2689
2922
|
class="btn btn-primary"
|
|
2690
2923
|
?disabled="${!isValid}"
|
|
2691
2924
|
@click="${this._handleConfirm}"
|
|
2692
2925
|
>
|
|
2693
|
-
|
|
2926
|
+
${I18n.t("column.addColumn")}
|
|
2694
2927
|
</button>
|
|
2695
2928
|
</div>
|
|
2696
2929
|
</div>
|
|
@@ -3254,41 +3487,41 @@ let JupiterFormSection = class extends LitElement {
|
|
|
3254
3487
|
<thead class="table-header">
|
|
3255
3488
|
<tr class="header-row">
|
|
3256
3489
|
<th class="header-cell concept-column"></th>
|
|
3257
|
-
${this.columns.map((
|
|
3490
|
+
${this.columns.map((column2) => {
|
|
3258
3491
|
var _a, _b, _c;
|
|
3259
3492
|
return html`
|
|
3260
|
-
<th class="header-cell ${
|
|
3493
|
+
<th class="header-cell ${column2.removable ? "removable" : ""}">
|
|
3261
3494
|
<div class="column-header-content">
|
|
3262
3495
|
<div class="column-title">
|
|
3263
|
-
${
|
|
3264
|
-
${
|
|
3496
|
+
${column2.title}
|
|
3497
|
+
${column2.description ? html`<div style="font-weight: normal; font-size: 12px; color: var(--jupiter-text-secondary, #666);">${column2.description}</div>` : ""}
|
|
3265
3498
|
</div>
|
|
3266
3499
|
|
|
3267
3500
|
<!-- Typed member input fields in column header -->
|
|
3268
|
-
${((_a =
|
|
3501
|
+
${((_a = column2.dimensionData) == null ? void 0 : _a.hasTypedMembers) ? html`
|
|
3269
3502
|
<div class="typed-members-header">
|
|
3270
|
-
${(_c = (_b =
|
|
3503
|
+
${(_c = (_b = column2.dimensionData) == null ? void 0 : _b.typedMembers) == null ? void 0 : _c.map((typedMember) => html`
|
|
3271
3504
|
<div class="typed-member-header-input">
|
|
3272
3505
|
<input
|
|
3273
3506
|
type="text"
|
|
3274
3507
|
class="typed-member-header-field"
|
|
3275
|
-
placeholder="
|
|
3276
|
-
.value="${this._getTypedMemberHeaderValue(
|
|
3277
|
-
@input="${(e2) => this._handleTypedMemberHeaderChange(e2,
|
|
3508
|
+
placeholder="${I18n.t("section.enterPlaceholder")} ${typedMember.axisLabel}"
|
|
3509
|
+
.value="${this._getTypedMemberHeaderValue(column2.id, typedMember.axisId)}"
|
|
3510
|
+
@input="${(e2) => this._handleTypedMemberHeaderChange(e2, column2.id, typedMember.axisId)}"
|
|
3278
3511
|
/>
|
|
3279
3512
|
</div>
|
|
3280
3513
|
`)}
|
|
3281
3514
|
</div>
|
|
3282
3515
|
` : ""}
|
|
3283
3516
|
|
|
3284
|
-
${
|
|
3517
|
+
${column2.removable ? html`
|
|
3285
3518
|
<button
|
|
3286
3519
|
class="remove-column-btn"
|
|
3287
3520
|
@click="${(e2) => {
|
|
3288
3521
|
e2.stopPropagation();
|
|
3289
|
-
this._handleRemoveColumn(
|
|
3522
|
+
this._handleRemoveColumn(column2.id);
|
|
3290
3523
|
}}"
|
|
3291
|
-
title="
|
|
3524
|
+
title="${I18n.t("column.removeColumn")}"
|
|
3292
3525
|
>×</button>
|
|
3293
3526
|
` : ""}
|
|
3294
3527
|
</div>
|
|
@@ -3299,8 +3532,8 @@ let JupiterFormSection = class extends LitElement {
|
|
|
3299
3532
|
<button class="add-column-btn" @click="${(e2) => {
|
|
3300
3533
|
e2.stopPropagation();
|
|
3301
3534
|
this._handleAddColumn();
|
|
3302
|
-
}}" title="
|
|
3303
|
-
+
|
|
3535
|
+
}}" title="${I18n.t("column.addColumn")}">
|
|
3536
|
+
+ ${I18n.t("column.addColumn")}
|
|
3304
3537
|
</button>
|
|
3305
3538
|
</th>
|
|
3306
3539
|
</tr>
|
|
@@ -3850,15 +4083,14 @@ let JupiterFilterRolesDialog = class extends LitElement {
|
|
|
3850
4083
|
<svg class="filter-icon" viewBox="0 0 24 24">
|
|
3851
4084
|
<path d="M10 18h4v-2h-4v2zM3 6v2h18V6H3zm3 7h12v-2H6v2z"/>
|
|
3852
4085
|
</svg>
|
|
3853
|
-
<h2 class="dialog-title"
|
|
4086
|
+
<h2 class="dialog-title">${I18n.t("filter.title")}</h2>
|
|
3854
4087
|
<button class="close-button" @click="${this._handleCancel}">×</button>
|
|
3855
4088
|
</div>
|
|
3856
4089
|
|
|
3857
4090
|
<!-- Dialog Content -->
|
|
3858
4091
|
<div class="dialog-content">
|
|
3859
4092
|
<p class="description">
|
|
3860
|
-
|
|
3861
|
-
to focus on or manage all ${totalCount} available roles.
|
|
4093
|
+
${I18n.t("filter.description")}
|
|
3862
4094
|
</p>
|
|
3863
4095
|
|
|
3864
4096
|
<!-- Search Input -->
|
|
@@ -3866,12 +4098,12 @@ let JupiterFilterRolesDialog = class extends LitElement {
|
|
|
3866
4098
|
<input
|
|
3867
4099
|
type="text"
|
|
3868
4100
|
class="search-input"
|
|
3869
|
-
placeholder="
|
|
4101
|
+
placeholder="${I18n.t("filter.searchPlaceholder")}"
|
|
3870
4102
|
.value="${this._searchQuery}"
|
|
3871
4103
|
@input="${this._handleSearchInput}"
|
|
3872
4104
|
/>
|
|
3873
4105
|
${this._searchQuery ? html`
|
|
3874
|
-
<button class="clear-search" @click="${this._clearSearch}" title="
|
|
4106
|
+
<button class="clear-search" @click="${this._clearSearch}" title="${I18n.t("filter.clearSearch")}">
|
|
3875
4107
|
×
|
|
3876
4108
|
</button>
|
|
3877
4109
|
` : html`
|
|
@@ -3884,8 +4116,8 @@ let JupiterFilterRolesDialog = class extends LitElement {
|
|
|
3884
4116
|
<!-- Search Results Info -->
|
|
3885
4117
|
${hasSearchQuery ? html`
|
|
3886
4118
|
<div class="search-results-info">
|
|
3887
|
-
|
|
3888
|
-
${filteredCount !== totalCount ? html
|
|
4119
|
+
${I18n.t("filter.showingResults")} ${filteredCount} ${I18n.t("filter.of")} ${totalCount} ${I18n.t("filter.roles")}
|
|
4120
|
+
${filteredCount !== totalCount ? html`${I18n.t("filter.matching")} "${this._searchQuery}"` : ""}
|
|
3889
4121
|
</div>
|
|
3890
4122
|
` : ""}
|
|
3891
4123
|
|
|
@@ -3893,27 +4125,27 @@ let JupiterFilterRolesDialog = class extends LitElement {
|
|
|
3893
4125
|
<div class="selection-controls">
|
|
3894
4126
|
${hasSearchQuery ? html`
|
|
3895
4127
|
<button class="selection-control" @click="${this._selectAll}">
|
|
3896
|
-
|
|
4128
|
+
${I18n.t("filter.selectFiltered")} (${filteredCount})
|
|
3897
4129
|
</button>
|
|
3898
4130
|
<button class="selection-control" @click="${this._selectNone}">
|
|
3899
|
-
|
|
4131
|
+
${I18n.t("filter.deselectFiltered")}
|
|
3900
4132
|
</button>
|
|
3901
4133
|
<button class="selection-control" @click="${this._selectAllGlobal}">
|
|
3902
|
-
|
|
4134
|
+
${I18n.t("filter.selectAll")} (${totalCount})
|
|
3903
4135
|
</button>
|
|
3904
4136
|
<button class="selection-control" @click="${this._selectNoneGlobal}">
|
|
3905
|
-
|
|
4137
|
+
${I18n.t("filter.deselectAll")}
|
|
3906
4138
|
</button>
|
|
3907
4139
|
` : html`
|
|
3908
4140
|
<button class="selection-control" @click="${this._selectAll}">
|
|
3909
|
-
|
|
4141
|
+
${I18n.t("filter.selectAll")}
|
|
3910
4142
|
</button>
|
|
3911
4143
|
<button class="selection-control" @click="${this._selectNone}">
|
|
3912
|
-
|
|
4144
|
+
${I18n.t("filter.selectNone")}
|
|
3913
4145
|
</button>
|
|
3914
4146
|
`}
|
|
3915
4147
|
<button class="selection-control" @click="${this._resetToOriginal}">
|
|
3916
|
-
|
|
4148
|
+
${I18n.t("filter.reset")}
|
|
3917
4149
|
</button>
|
|
3918
4150
|
</div>
|
|
3919
4151
|
|
|
@@ -3922,10 +4154,10 @@ let JupiterFilterRolesDialog = class extends LitElement {
|
|
|
3922
4154
|
${this._filteredRoles.length === 0 ? html`
|
|
3923
4155
|
<div class="no-results">
|
|
3924
4156
|
${hasSearchQuery ? html`
|
|
3925
|
-
|
|
3926
|
-
|
|
4157
|
+
${I18n.t("filter.noRolesFound")} "${this._searchQuery}".<br>
|
|
4158
|
+
${I18n.t("filter.tryDifferentSearch")}
|
|
3927
4159
|
` : html`
|
|
3928
|
-
|
|
4160
|
+
${I18n.t("filter.noRolesAvailable")}
|
|
3929
4161
|
`}
|
|
3930
4162
|
</div>
|
|
3931
4163
|
` : html`
|
|
@@ -3945,12 +4177,12 @@ let JupiterFilterRolesDialog = class extends LitElement {
|
|
|
3945
4177
|
<div class="role-info">
|
|
3946
4178
|
<h4 class="role-title">${role.title}</h4>
|
|
3947
4179
|
${((_a = role.metadata) == null ? void 0 : _a.roleURI) ? html`
|
|
3948
|
-
<p class="role-description"
|
|
4180
|
+
<p class="role-description">${I18n.t("filter.uri")}: ${role.metadata.roleURI}</p>
|
|
3949
4181
|
` : ""}
|
|
3950
4182
|
|
|
3951
4183
|
${showPeriodControls ? html`
|
|
3952
4184
|
<div class="period-controls">
|
|
3953
|
-
<p class="period-controls-label"
|
|
4185
|
+
<p class="period-controls-label">${I18n.t("filter.showPeriodColumn")}</p>
|
|
3954
4186
|
<div class="period-checkboxes">
|
|
3955
4187
|
<label class="period-checkbox-item">
|
|
3956
4188
|
<input
|
|
@@ -3959,7 +4191,7 @@ let JupiterFilterRolesDialog = class extends LitElement {
|
|
|
3959
4191
|
.checked="${preferences.showDuration}"
|
|
3960
4192
|
@change="${(e2) => this._handlePeriodCheckboxChange(e2, role.id, "duration")}"
|
|
3961
4193
|
/>
|
|
3962
|
-
<span class="period-checkbox-label"
|
|
4194
|
+
<span class="period-checkbox-label">${I18n.t("filter.duration")}</span>
|
|
3963
4195
|
</label>
|
|
3964
4196
|
<label class="period-checkbox-item">
|
|
3965
4197
|
<input
|
|
@@ -3968,14 +4200,14 @@ let JupiterFilterRolesDialog = class extends LitElement {
|
|
|
3968
4200
|
.checked="${preferences.showInstant}"
|
|
3969
4201
|
@change="${(e2) => this._handlePeriodCheckboxChange(e2, role.id, "instant")}"
|
|
3970
4202
|
/>
|
|
3971
|
-
<span class="period-checkbox-label"
|
|
4203
|
+
<span class="period-checkbox-label">${I18n.t("filter.instant")}</span>
|
|
3972
4204
|
</label>
|
|
3973
4205
|
</div>
|
|
3974
4206
|
</div>
|
|
3975
4207
|
` : ""}
|
|
3976
4208
|
|
|
3977
4209
|
<div class="period-controls">
|
|
3978
|
-
<p class="period-controls-label"
|
|
4210
|
+
<p class="period-controls-label">${I18n.t("filter.additionalOptions")}</p>
|
|
3979
4211
|
<div class="period-checkboxes">
|
|
3980
4212
|
<label class="period-checkbox-item">
|
|
3981
4213
|
<input
|
|
@@ -3984,7 +4216,7 @@ let JupiterFilterRolesDialog = class extends LitElement {
|
|
|
3984
4216
|
.checked="${preferences.showPreviousYear}"
|
|
3985
4217
|
@change="${(e2) => this._handlePeriodCheckboxChange(e2, role.id, "previousYear")}"
|
|
3986
4218
|
/>
|
|
3987
|
-
<span class="period-checkbox-label"
|
|
4219
|
+
<span class="period-checkbox-label">${I18n.t("filter.showPreviousYear")}</span>
|
|
3988
4220
|
</label>
|
|
3989
4221
|
</div>
|
|
3990
4222
|
</div>
|
|
@@ -4001,14 +4233,14 @@ let JupiterFilterRolesDialog = class extends LitElement {
|
|
|
4001
4233
|
<!-- Dialog Actions -->
|
|
4002
4234
|
<div class="dialog-actions">
|
|
4003
4235
|
<button class="btn-secondary" @click="${this._handleCancel}">
|
|
4004
|
-
|
|
4236
|
+
${I18n.t("filter.cancel")}
|
|
4005
4237
|
</button>
|
|
4006
4238
|
<button
|
|
4007
4239
|
class="btn-primary"
|
|
4008
4240
|
@click="${this._handleApply}"
|
|
4009
4241
|
?disabled="${selectedCount === 0}"
|
|
4010
4242
|
>
|
|
4011
|
-
|
|
4243
|
+
${I18n.t("filter.applyFilter")} (${selectedCount})
|
|
4012
4244
|
</button>
|
|
4013
4245
|
</div>
|
|
4014
4246
|
</div>
|
|
@@ -4414,6 +4646,9 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
4414
4646
|
this._initializeForm();
|
|
4415
4647
|
}
|
|
4416
4648
|
updated(changedProperties) {
|
|
4649
|
+
if (changedProperties.has("language")) {
|
|
4650
|
+
I18n.setLanguage(this.language);
|
|
4651
|
+
}
|
|
4417
4652
|
if (changedProperties.has("financialStatementsTypeAxis")) {
|
|
4418
4653
|
console.log("🔄 financialStatementsTypeAxis changed:", this.financialStatementsTypeAxis);
|
|
4419
4654
|
}
|
|
@@ -4446,7 +4681,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
4446
4681
|
console.log("📊 Sections after filter:", this._allSections.length);
|
|
4447
4682
|
}
|
|
4448
4683
|
if (this._selectedRoleIds.length === 0) {
|
|
4449
|
-
this._selectedRoleIds = this._allSections.map((
|
|
4684
|
+
this._selectedRoleIds = this._allSections.map((section2) => section2.id);
|
|
4450
4685
|
console.log("✅ Auto-selected all roles:", this._selectedRoleIds.length);
|
|
4451
4686
|
}
|
|
4452
4687
|
this._applyRoleFilter();
|
|
@@ -4470,7 +4705,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
4470
4705
|
} else if (this.schema) {
|
|
4471
4706
|
this._currentSchema = this.schema;
|
|
4472
4707
|
this._allSections = [...this.schema.sections];
|
|
4473
|
-
this._selectedRoleIds = this._allSections.map((
|
|
4708
|
+
this._selectedRoleIds = this._allSections.map((section2) => section2.id);
|
|
4474
4709
|
this._columns = this._getDefaultColumns();
|
|
4475
4710
|
} else {
|
|
4476
4711
|
this._currentSchema = this._getDefaultSchema();
|
|
@@ -4545,7 +4780,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
4545
4780
|
}
|
|
4546
4781
|
this._preserveDataForHiddenSections();
|
|
4547
4782
|
const filteredSections = this._allSections.filter(
|
|
4548
|
-
(
|
|
4783
|
+
(section2) => this._selectedRoleIds.includes(section2.id)
|
|
4549
4784
|
);
|
|
4550
4785
|
console.log(`📊 Filtered sections: ${filteredSections.length} (IDs: ${filteredSections.map((s2) => s2.id).join(", ")})`);
|
|
4551
4786
|
this._restoreDataForVisibleSections(filteredSections);
|
|
@@ -4574,11 +4809,11 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
4574
4809
|
const hypercubeData = this.xbrlInput.hypercubes[0];
|
|
4575
4810
|
const financialStatementsAxisId = "bw2-titel9_FinancialStatementsTypeAxis";
|
|
4576
4811
|
console.log("🔍 Filter values:", this.financialStatementsTypeAxis);
|
|
4577
|
-
return sections.filter((
|
|
4812
|
+
return sections.filter((section2) => {
|
|
4578
4813
|
var _a2;
|
|
4579
|
-
const hypercubeRole = (_a2 = hypercubeData.roles) == null ? void 0 : _a2.find((r2) => r2.roleId ===
|
|
4814
|
+
const hypercubeRole = (_a2 = hypercubeData.roles) == null ? void 0 : _a2.find((r2) => r2.roleId === section2.id);
|
|
4580
4815
|
if (!hypercubeRole || !hypercubeRole.items || hypercubeRole.items.length === 0) {
|
|
4581
|
-
console.log(`✅ ${
|
|
4816
|
+
console.log(`✅ ${section2.title}: No hypercube entry - INCLUDED`);
|
|
4582
4817
|
return true;
|
|
4583
4818
|
}
|
|
4584
4819
|
let hasFinancialStatementsAxis = false;
|
|
@@ -4630,20 +4865,20 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
4630
4865
|
(sectionId) => !this._selectedRoleIds.includes(sectionId)
|
|
4631
4866
|
);
|
|
4632
4867
|
sectionsThatWillBeHidden.forEach((sectionId) => {
|
|
4633
|
-
const
|
|
4634
|
-
if (
|
|
4635
|
-
this._preserveSectionData(
|
|
4868
|
+
const section2 = this._allSections.find((s2) => s2.id === sectionId);
|
|
4869
|
+
if (section2) {
|
|
4870
|
+
this._preserveSectionData(section2);
|
|
4636
4871
|
}
|
|
4637
4872
|
});
|
|
4638
4873
|
}
|
|
4639
4874
|
_restoreDataForVisibleSections(visibleSections) {
|
|
4640
|
-
visibleSections.forEach((
|
|
4641
|
-
this._restoreSectionData(
|
|
4875
|
+
visibleSections.forEach((section2) => {
|
|
4876
|
+
this._restoreSectionData(section2);
|
|
4642
4877
|
});
|
|
4643
4878
|
console.log(`🔄 Restored data for ${visibleSections.length} visible sections`);
|
|
4644
4879
|
}
|
|
4645
|
-
_preserveSectionData(
|
|
4646
|
-
|
|
4880
|
+
_preserveSectionData(section2) {
|
|
4881
|
+
section2.concepts.forEach((concept) => {
|
|
4647
4882
|
this._preserveConceptData(concept);
|
|
4648
4883
|
});
|
|
4649
4884
|
}
|
|
@@ -4662,8 +4897,8 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
4662
4897
|
});
|
|
4663
4898
|
}
|
|
4664
4899
|
}
|
|
4665
|
-
_restoreSectionData(
|
|
4666
|
-
|
|
4900
|
+
_restoreSectionData(section2) {
|
|
4901
|
+
section2.concepts.forEach((concept) => {
|
|
4667
4902
|
this._restoreConceptData(concept);
|
|
4668
4903
|
});
|
|
4669
4904
|
}
|
|
@@ -4721,8 +4956,8 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
4721
4956
|
const schema = this._currentSchema;
|
|
4722
4957
|
if (!schema)
|
|
4723
4958
|
return;
|
|
4724
|
-
for (const
|
|
4725
|
-
for (const concept of
|
|
4959
|
+
for (const section2 of schema.sections) {
|
|
4960
|
+
for (const concept of section2.concepts) {
|
|
4726
4961
|
for (const field of concept.fields) {
|
|
4727
4962
|
const value = (_a = this._formData[concept.id]) == null ? void 0 : _a[field.columnId];
|
|
4728
4963
|
const fieldErrors = FormValidator.validateField(
|
|
@@ -4802,16 +5037,16 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
4802
5037
|
_handleColumnRemove(event) {
|
|
4803
5038
|
const { columnId, sectionId } = event.detail;
|
|
4804
5039
|
if (this._currentSchema && sectionId) {
|
|
4805
|
-
const targetSection = this._currentSchema.sections.find((
|
|
5040
|
+
const targetSection = this._currentSchema.sections.find((section2) => section2.id === sectionId);
|
|
4806
5041
|
if (targetSection && targetSection.columns) {
|
|
4807
5042
|
targetSection.columns = targetSection.columns.filter((col) => col.id !== columnId);
|
|
4808
5043
|
}
|
|
4809
5044
|
} else {
|
|
4810
5045
|
this._columns = this._columns.filter((col) => col.id !== columnId);
|
|
4811
5046
|
if (this._currentSchema) {
|
|
4812
|
-
this._currentSchema.sections.forEach((
|
|
4813
|
-
if (
|
|
4814
|
-
|
|
5047
|
+
this._currentSchema.sections.forEach((section2) => {
|
|
5048
|
+
if (section2.columns) {
|
|
5049
|
+
section2.columns = section2.columns.filter((col) => col.id !== columnId);
|
|
4815
5050
|
}
|
|
4816
5051
|
});
|
|
4817
5052
|
}
|
|
@@ -4981,7 +5216,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
4981
5216
|
}
|
|
4982
5217
|
}
|
|
4983
5218
|
if (this._currentSchema) {
|
|
4984
|
-
const targetSection = this._currentSchema.sections.find((
|
|
5219
|
+
const targetSection = this._currentSchema.sections.find((section2) => section2.id === sectionId);
|
|
4985
5220
|
if (targetSection) {
|
|
4986
5221
|
if (!targetSection.columns) {
|
|
4987
5222
|
targetSection.columns = [...this._columns];
|
|
@@ -5001,7 +5236,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5001
5236
|
if (!this._currentSchema)
|
|
5002
5237
|
return;
|
|
5003
5238
|
if (sectionId) {
|
|
5004
|
-
const targetSection = this._currentSchema.sections.find((
|
|
5239
|
+
const targetSection = this._currentSchema.sections.find((section2) => section2.id === sectionId);
|
|
5005
5240
|
if (targetSection) {
|
|
5006
5241
|
this._removeColumnDataFromConcepts(targetSection.concepts, columnId);
|
|
5007
5242
|
}
|
|
@@ -5044,7 +5279,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5044
5279
|
if (!this._currentSchema)
|
|
5045
5280
|
return;
|
|
5046
5281
|
const formBuilder = new XBRLFormBuilder();
|
|
5047
|
-
const targetSection = this._currentSchema.sections.find((
|
|
5282
|
+
const targetSection = this._currentSchema.sections.find((section2) => section2.id === sectionId);
|
|
5048
5283
|
if (targetSection) {
|
|
5049
5284
|
this._replicateFieldsForSection(targetSection.concepts, columnId, request, formBuilder);
|
|
5050
5285
|
}
|
|
@@ -5158,8 +5393,8 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5158
5393
|
if (!this._currentSchema) {
|
|
5159
5394
|
return submissionData;
|
|
5160
5395
|
}
|
|
5161
|
-
this._currentSchema.sections.forEach((
|
|
5162
|
-
this._processConceptsForSubmission(
|
|
5396
|
+
this._currentSchema.sections.forEach((section2) => {
|
|
5397
|
+
this._processConceptsForSubmission(section2.concepts, submissionData, section2);
|
|
5163
5398
|
});
|
|
5164
5399
|
this._includePreservedDataInSubmission(submissionData);
|
|
5165
5400
|
const uniqueSubmissionData = this._removeDuplicateSubmissions(submissionData);
|
|
@@ -5184,8 +5419,8 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5184
5419
|
console.log(`📤 Included preserved data in submission. Total entries: ${submissionData.length}`);
|
|
5185
5420
|
}
|
|
5186
5421
|
_findConceptInAllSections(conceptId) {
|
|
5187
|
-
for (const
|
|
5188
|
-
const concept = this._findConceptInSection(
|
|
5422
|
+
for (const section2 of this._allSections) {
|
|
5423
|
+
const concept = this._findConceptInSection(section2.concepts, conceptId);
|
|
5189
5424
|
if (concept) {
|
|
5190
5425
|
return concept;
|
|
5191
5426
|
}
|
|
@@ -5207,45 +5442,45 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5207
5442
|
return null;
|
|
5208
5443
|
}
|
|
5209
5444
|
_findSectionForConcept(conceptId) {
|
|
5210
|
-
for (const
|
|
5211
|
-
const concept = this._findConceptInSection(
|
|
5445
|
+
for (const section2 of this._allSections) {
|
|
5446
|
+
const concept = this._findConceptInSection(section2.concepts, conceptId);
|
|
5212
5447
|
if (concept) {
|
|
5213
|
-
return
|
|
5448
|
+
return section2;
|
|
5214
5449
|
}
|
|
5215
5450
|
}
|
|
5216
5451
|
return null;
|
|
5217
5452
|
}
|
|
5218
|
-
_addConceptDataToSubmission(concept, columnId, value, submissionData,
|
|
5453
|
+
_addConceptDataToSubmission(concept, columnId, value, submissionData, section2) {
|
|
5219
5454
|
var _a;
|
|
5220
5455
|
const field = concept.fields.find((f2) => f2.columnId === columnId);
|
|
5221
5456
|
if (!field)
|
|
5222
5457
|
return;
|
|
5223
5458
|
const isInstant = concept.periodType === "instant";
|
|
5224
|
-
const
|
|
5459
|
+
const column2 = this._findColumnByIdInAllSections(columnId);
|
|
5225
5460
|
alert("hi");
|
|
5226
|
-
console.log(`🔍 [Submission] Concept: ${concept.id}, Column: ${columnId}, Column Period: ${(
|
|
5461
|
+
console.log(`🔍 [Submission] Concept: ${concept.id}, Column: ${columnId}, Column Period: ${(column2 == null ? void 0 : column2.periodStartDate) || "none"} - ${(column2 == null ? void 0 : column2.periodEndDate) || "none"}`);
|
|
5227
5462
|
const entry = {
|
|
5228
5463
|
conceptId: concept.originalConceptId || concept.id,
|
|
5229
5464
|
value,
|
|
5230
5465
|
period: {
|
|
5231
5466
|
type: concept.periodType || "duration",
|
|
5232
|
-
...isInstant ? { date: (
|
|
5233
|
-
startDate: (
|
|
5234
|
-
endDate: (
|
|
5467
|
+
...isInstant ? { date: (column2 == null ? void 0 : column2.periodEndDate) || field.periodStartDate || this.periodStartDate } : {
|
|
5468
|
+
startDate: (column2 == null ? void 0 : column2.periodStartDate) || field.periodStartDate || this.periodStartDate,
|
|
5469
|
+
endDate: (column2 == null ? void 0 : column2.periodEndDate) || field.periodEndDate || this.periodEndDate
|
|
5235
5470
|
}
|
|
5236
5471
|
}
|
|
5237
5472
|
};
|
|
5238
|
-
if ((_a =
|
|
5239
|
-
entry.dimension =
|
|
5473
|
+
if ((_a = column2 == null ? void 0 : column2.dimensionData) == null ? void 0 : _a.memberLabel) {
|
|
5474
|
+
entry.dimension = column2.dimensionData.memberLabel;
|
|
5240
5475
|
}
|
|
5241
5476
|
submissionData.push(entry);
|
|
5242
5477
|
}
|
|
5243
5478
|
_findColumnByIdInAllSections(columnId) {
|
|
5244
|
-
for (const
|
|
5245
|
-
if (
|
|
5246
|
-
const
|
|
5247
|
-
if (
|
|
5248
|
-
return
|
|
5479
|
+
for (const section2 of this._allSections) {
|
|
5480
|
+
if (section2.columns) {
|
|
5481
|
+
const column2 = section2.columns.find((col) => col.id === columnId);
|
|
5482
|
+
if (column2) {
|
|
5483
|
+
return column2;
|
|
5249
5484
|
}
|
|
5250
5485
|
}
|
|
5251
5486
|
}
|
|
@@ -5266,28 +5501,28 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5266
5501
|
if (!this._currentSchema) {
|
|
5267
5502
|
return void 0;
|
|
5268
5503
|
}
|
|
5269
|
-
for (const
|
|
5270
|
-
if (
|
|
5271
|
-
const
|
|
5272
|
-
if (
|
|
5273
|
-
return
|
|
5504
|
+
for (const section2 of this._currentSchema.sections) {
|
|
5505
|
+
if (section2.columns) {
|
|
5506
|
+
const column2 = section2.columns.find((col) => col.id === columnId);
|
|
5507
|
+
if (column2) {
|
|
5508
|
+
return column2;
|
|
5274
5509
|
}
|
|
5275
5510
|
}
|
|
5276
5511
|
}
|
|
5277
5512
|
return void 0;
|
|
5278
5513
|
}
|
|
5279
|
-
_findColumnByIdInSection(columnId,
|
|
5280
|
-
if (!(
|
|
5514
|
+
_findColumnByIdInSection(columnId, section2) {
|
|
5515
|
+
if (!(section2 == null ? void 0 : section2.columns)) {
|
|
5281
5516
|
return void 0;
|
|
5282
5517
|
}
|
|
5283
|
-
return
|
|
5518
|
+
return section2.columns.find((col) => col.id === columnId);
|
|
5284
5519
|
}
|
|
5285
|
-
_getTypedMemberNameForAxis(axisId,
|
|
5520
|
+
_getTypedMemberNameForAxis(axisId, section2) {
|
|
5286
5521
|
var _a, _b, _c, _d;
|
|
5287
5522
|
if (!((_b = (_a = this.xbrlInput) == null ? void 0 : _a.hypercubes) == null ? void 0 : _b[0])) {
|
|
5288
5523
|
return null;
|
|
5289
5524
|
}
|
|
5290
|
-
const sectionRoleId =
|
|
5525
|
+
const sectionRoleId = section2 == null ? void 0 : section2.id;
|
|
5291
5526
|
if (!sectionRoleId) {
|
|
5292
5527
|
return null;
|
|
5293
5528
|
}
|
|
@@ -5306,12 +5541,12 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5306
5541
|
}
|
|
5307
5542
|
return null;
|
|
5308
5543
|
}
|
|
5309
|
-
_doesConceptApplyToTypedDimension(concept,
|
|
5544
|
+
_doesConceptApplyToTypedDimension(concept, section2, columnId) {
|
|
5310
5545
|
var _a, _b, _c;
|
|
5311
5546
|
if (!((_b = (_a = this.xbrlInput) == null ? void 0 : _a.hypercubes) == null ? void 0 : _b[0])) {
|
|
5312
5547
|
return false;
|
|
5313
5548
|
}
|
|
5314
|
-
const sectionRoleId =
|
|
5549
|
+
const sectionRoleId = section2 == null ? void 0 : section2.id;
|
|
5315
5550
|
if (!sectionRoleId) {
|
|
5316
5551
|
return false;
|
|
5317
5552
|
}
|
|
@@ -5333,12 +5568,12 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5333
5568
|
/**
|
|
5334
5569
|
* Get the specific typed dimensions that apply to a concept in its role
|
|
5335
5570
|
*/
|
|
5336
|
-
_getApplicableTypedDimensions(concept,
|
|
5571
|
+
_getApplicableTypedDimensions(concept, section2) {
|
|
5337
5572
|
var _a, _b, _c;
|
|
5338
|
-
if (!((_b = (_a = this.xbrlInput) == null ? void 0 : _a.hypercubes) == null ? void 0 : _b[0]) || !(
|
|
5573
|
+
if (!((_b = (_a = this.xbrlInput) == null ? void 0 : _a.hypercubes) == null ? void 0 : _b[0]) || !(section2 == null ? void 0 : section2.id)) {
|
|
5339
5574
|
return [];
|
|
5340
5575
|
}
|
|
5341
|
-
const hypercubeRole = this.xbrlInput.hypercubes[0].roles.find((hr) => hr.roleId ===
|
|
5576
|
+
const hypercubeRole = this.xbrlInput.hypercubes[0].roles.find((hr) => hr.roleId === section2.id);
|
|
5342
5577
|
if (!((_c = hypercubeRole == null ? void 0 : hypercubeRole.items) == null ? void 0 : _c.length)) {
|
|
5343
5578
|
return [];
|
|
5344
5579
|
}
|
|
@@ -5352,9 +5587,9 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5352
5587
|
}
|
|
5353
5588
|
return [];
|
|
5354
5589
|
}
|
|
5355
|
-
_processConceptsForSubmission(concepts, submissionData,
|
|
5590
|
+
_processConceptsForSubmission(concepts, submissionData, section2) {
|
|
5356
5591
|
const targetRole = "Toelichting op de geconsolideerde jaarrekening - Financiële vaste activa: Deelnemingen: Volledig geconsolideerd: Specificatie";
|
|
5357
|
-
const sectionTitle = (
|
|
5592
|
+
const sectionTitle = (section2 == null ? void 0 : section2.title) || "Unknown";
|
|
5358
5593
|
concepts.forEach((concept) => {
|
|
5359
5594
|
if (sectionTitle === targetRole) {
|
|
5360
5595
|
console.warn(`[DUPLICATE DEBUG] Processing concept ${concept.originalConceptId || concept.id} in target role`);
|
|
@@ -5376,7 +5611,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5376
5611
|
const conceptData = this._formData[concept.id];
|
|
5377
5612
|
const fieldValue = conceptData == null ? void 0 : conceptData[field.columnId];
|
|
5378
5613
|
if (fieldValue !== void 0 && fieldValue !== null && fieldValue !== "") {
|
|
5379
|
-
const
|
|
5614
|
+
const column2 = this._findColumnByIdInSection(field.columnId, section2);
|
|
5380
5615
|
const submissionEntry = {
|
|
5381
5616
|
conceptId: concept.id,
|
|
5382
5617
|
value: fieldValue,
|
|
@@ -5385,27 +5620,27 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5385
5620
|
}
|
|
5386
5621
|
};
|
|
5387
5622
|
if (concept.periodType === "instant") {
|
|
5388
|
-
submissionEntry.period.date = (
|
|
5623
|
+
submissionEntry.period.date = (column2 == null ? void 0 : column2.periodEndDate) || field.periodStartDate || this.periodStartDate;
|
|
5389
5624
|
} else {
|
|
5390
|
-
submissionEntry.period.startDate = (
|
|
5391
|
-
submissionEntry.period.endDate = (
|
|
5625
|
+
submissionEntry.period.startDate = (column2 == null ? void 0 : column2.periodStartDate) || field.periodStartDate || this.periodStartDate;
|
|
5626
|
+
submissionEntry.period.endDate = (column2 == null ? void 0 : column2.periodEndDate) || field.periodEndDate || this.periodEndDate;
|
|
5392
5627
|
}
|
|
5393
|
-
console.log(`🔍 [Submission] Concept: ${concept.id}, Column: ${field.columnId}, Column Period: ${(
|
|
5394
|
-
if ((
|
|
5395
|
-
submissionEntry.dimension =
|
|
5396
|
-
console.log(`🔍 [DynamicForm] Using dimension key from field's column (${field.columnId}):`,
|
|
5628
|
+
console.log(`🔍 [Submission] Concept: ${concept.id}, Column: ${field.columnId}, Column Period: ${(column2 == null ? void 0 : column2.periodStartDate) || "none"} - ${(column2 == null ? void 0 : column2.periodEndDate) || "none"}, Used Period: ${submissionEntry.period.type === "instant" ? submissionEntry.period.date : `${submissionEntry.period.startDate} - ${submissionEntry.period.endDate}`}`);
|
|
5629
|
+
if ((column2 == null ? void 0 : column2.type) === "dimension" && ((_a = column2.dimensionData) == null ? void 0 : _a.dimensionIdKey)) {
|
|
5630
|
+
submissionEntry.dimension = column2.dimensionData.dimensionIdKey;
|
|
5631
|
+
console.log(`🔍 [DynamicForm] Using dimension key from field's column (${field.columnId}):`, column2.dimensionData.dimensionIdKey);
|
|
5397
5632
|
} else {
|
|
5398
|
-
console.log(`🔍 [DynamicForm] No dimension data found for field column ${field.columnId}. Column type: ${
|
|
5633
|
+
console.log(`🔍 [DynamicForm] No dimension data found for field column ${field.columnId}. Column type: ${column2 == null ? void 0 : column2.type}, has dimensionData: ${!!(column2 == null ? void 0 : column2.dimensionData)}`);
|
|
5399
5634
|
}
|
|
5400
5635
|
if (this._typedMemberData[field.columnId]) {
|
|
5401
|
-
const applicableTypedDimensions = this._getApplicableTypedDimensions(concept,
|
|
5636
|
+
const applicableTypedDimensions = this._getApplicableTypedDimensions(concept, section2);
|
|
5402
5637
|
console.log(`🔍 [DynamicForm] Concept ${concept.id} applicable typed dimensions:`, applicableTypedDimensions);
|
|
5403
5638
|
if (applicableTypedDimensions.length > 0) {
|
|
5404
5639
|
const filteredTypedMembers = {};
|
|
5405
5640
|
const allTypedMemberData = this._typedMemberData[field.columnId];
|
|
5406
5641
|
applicableTypedDimensions.forEach((dimensionId) => {
|
|
5407
5642
|
if (allTypedMemberData[dimensionId]) {
|
|
5408
|
-
const memberName = this._getTypedMemberNameForAxis(dimensionId,
|
|
5643
|
+
const memberName = this._getTypedMemberNameForAxis(dimensionId, section2);
|
|
5409
5644
|
filteredTypedMembers[dimensionId] = {
|
|
5410
5645
|
value: allTypedMemberData[dimensionId],
|
|
5411
5646
|
memberName: memberName || "Unknown"
|
|
@@ -5423,12 +5658,12 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5423
5658
|
}
|
|
5424
5659
|
} else {
|
|
5425
5660
|
console.log(`🔍 [DynamicForm] No typed member data found for column ${field.columnId}. Available columns:`, Object.keys(this._typedMemberData));
|
|
5426
|
-
if (
|
|
5661
|
+
if (column2) {
|
|
5427
5662
|
console.log(`🔍 [DynamicForm] Column details:`, {
|
|
5428
|
-
id:
|
|
5429
|
-
type:
|
|
5430
|
-
hasTypedMembers: (_b =
|
|
5431
|
-
dimensionData:
|
|
5663
|
+
id: column2.id,
|
|
5664
|
+
type: column2.type,
|
|
5665
|
+
hasTypedMembers: (_b = column2.dimensionData) == null ? void 0 : _b.hasTypedMembers,
|
|
5666
|
+
dimensionData: column2.dimensionData
|
|
5432
5667
|
});
|
|
5433
5668
|
}
|
|
5434
5669
|
}
|
|
@@ -5440,7 +5675,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5440
5675
|
});
|
|
5441
5676
|
}
|
|
5442
5677
|
if (concept.children) {
|
|
5443
|
-
this._processConceptsForSubmission(concept.children, submissionData,
|
|
5678
|
+
this._processConceptsForSubmission(concept.children, submissionData, section2);
|
|
5444
5679
|
}
|
|
5445
5680
|
});
|
|
5446
5681
|
}
|
|
@@ -5472,32 +5707,32 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5472
5707
|
_handleSidePanelRoleClick(roleId) {
|
|
5473
5708
|
this._activeSidePanelRoleId = roleId;
|
|
5474
5709
|
}
|
|
5475
|
-
_renderAdminModeContent(
|
|
5710
|
+
_renderAdminModeContent(section2) {
|
|
5476
5711
|
var _a, _b, _c;
|
|
5477
|
-
if (!
|
|
5712
|
+
if (!section2) {
|
|
5478
5713
|
return html`
|
|
5479
5714
|
<div class="admin-mode-container">
|
|
5480
5715
|
<p>No role selected</p>
|
|
5481
5716
|
</div>
|
|
5482
5717
|
`;
|
|
5483
5718
|
}
|
|
5484
|
-
const showPreviousYearChecked = ((_a = this._adminRoleConfigs[
|
|
5485
|
-
const instantChecked = ((_b = this._adminRoleConfigs[
|
|
5486
|
-
const durationChecked = ((_c = this._adminRoleConfigs[
|
|
5487
|
-
const hasMixedPeriodTypes =
|
|
5719
|
+
const showPreviousYearChecked = ((_a = this._adminRoleConfigs[section2.id]) == null ? void 0 : _a.showPreviousYear) ?? section2.showPreviousYear ?? false;
|
|
5720
|
+
const instantChecked = ((_b = this._adminRoleConfigs[section2.id]) == null ? void 0 : _b.instant) ?? section2.instant ?? false;
|
|
5721
|
+
const durationChecked = ((_c = this._adminRoleConfigs[section2.id]) == null ? void 0 : _c.duration) ?? section2.duration ?? false;
|
|
5722
|
+
const hasMixedPeriodTypes = section2.showPeriodControl === true;
|
|
5488
5723
|
return html`
|
|
5489
5724
|
<div class="admin-mode-container">
|
|
5490
|
-
<h2 class="admin-mode-title">Role Configuration: ${
|
|
5725
|
+
<h2 class="admin-mode-title">Role Configuration: ${section2.title}</h2>
|
|
5491
5726
|
<div class="admin-roles-list">
|
|
5492
5727
|
<div class="admin-role-item">
|
|
5493
5728
|
<div class="admin-role-checkbox">
|
|
5494
5729
|
<input
|
|
5495
5730
|
type="checkbox"
|
|
5496
|
-
id="admin-prev-year-${
|
|
5731
|
+
id="admin-prev-year-${section2.id}"
|
|
5497
5732
|
.checked="${showPreviousYearChecked}"
|
|
5498
|
-
@change="${(e2) => this._handleAdminCheckboxChange(
|
|
5733
|
+
@change="${(e2) => this._handleAdminCheckboxChange(section2.id, "showPreviousYear", e2.target.checked)}"
|
|
5499
5734
|
/>
|
|
5500
|
-
<label for="admin-prev-year-${
|
|
5735
|
+
<label for="admin-prev-year-${section2.id}">Show Previous Year Column</label>
|
|
5501
5736
|
</div>
|
|
5502
5737
|
</div>
|
|
5503
5738
|
|
|
@@ -5506,11 +5741,11 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5506
5741
|
<div class="admin-role-checkbox">
|
|
5507
5742
|
<input
|
|
5508
5743
|
type="checkbox"
|
|
5509
|
-
id="admin-instant-${
|
|
5744
|
+
id="admin-instant-${section2.id}"
|
|
5510
5745
|
.checked="${instantChecked}"
|
|
5511
|
-
@change="${(e2) => this._handleAdminCheckboxChange(
|
|
5746
|
+
@change="${(e2) => this._handleAdminCheckboxChange(section2.id, "instant", e2.target.checked)}"
|
|
5512
5747
|
/>
|
|
5513
|
-
<label for="admin-instant-${
|
|
5748
|
+
<label for="admin-instant-${section2.id}">Show Instant Column</label>
|
|
5514
5749
|
</div>
|
|
5515
5750
|
</div>
|
|
5516
5751
|
|
|
@@ -5518,11 +5753,11 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5518
5753
|
<div class="admin-role-checkbox">
|
|
5519
5754
|
<input
|
|
5520
5755
|
type="checkbox"
|
|
5521
|
-
id="admin-duration-${
|
|
5756
|
+
id="admin-duration-${section2.id}"
|
|
5522
5757
|
.checked="${durationChecked}"
|
|
5523
|
-
@change="${(e2) => this._handleAdminCheckboxChange(
|
|
5758
|
+
@change="${(e2) => this._handleAdminCheckboxChange(section2.id, "duration", e2.target.checked)}"
|
|
5524
5759
|
/>
|
|
5525
|
-
<label for="admin-duration-${
|
|
5760
|
+
<label for="admin-duration-${section2.id}">Show Duration Column</label>
|
|
5526
5761
|
</div>
|
|
5527
5762
|
</div>
|
|
5528
5763
|
` : ""}
|
|
@@ -5584,7 +5819,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5584
5819
|
<!-- Validation Summary -->
|
|
5585
5820
|
${showValidationSummary ? html`
|
|
5586
5821
|
<div class="validation-summary">
|
|
5587
|
-
<h4 class="validation-summary-title"
|
|
5822
|
+
<h4 class="validation-summary-title">${I18n.t("validation.summary")}</h4>
|
|
5588
5823
|
<ul class="validation-summary-list">
|
|
5589
5824
|
${this._errors.filter((e2) => e2.severity === "error").map((error) => html`
|
|
5590
5825
|
<li class="validation-summary-item">${error.message}</li>
|
|
@@ -5594,27 +5829,27 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5594
5829
|
` : ""}
|
|
5595
5830
|
|
|
5596
5831
|
<!-- Form Sections or No Selection Message (hidden in admin mode) -->
|
|
5597
|
-
${this.mode === "admin" ? schema.sections.map((
|
|
5832
|
+
${this.mode === "admin" ? schema.sections.map((section2, index) => html`
|
|
5598
5833
|
<div class="admin-mode-placeholder">
|
|
5599
|
-
${this._renderAdminModeContent(
|
|
5834
|
+
${this._renderAdminModeContent(section2)}
|
|
5600
5835
|
</div>
|
|
5601
5836
|
`) : schema.sections.length === 0 ? html`
|
|
5602
5837
|
<div class="no-roles-message">
|
|
5603
|
-
<h3
|
|
5604
|
-
<p
|
|
5605
|
-
<p
|
|
5838
|
+
<h3>${I18n.t("form.noRoleSelected")}</h3>
|
|
5839
|
+
<p>${I18n.t("filter.selectRoles")}</p>
|
|
5840
|
+
<p>${I18n.t("filter.roles")}: ${this._allSections.length}</p>
|
|
5606
5841
|
</div>
|
|
5607
|
-
` : schema.sections.map((
|
|
5842
|
+
` : schema.sections.map((section2, index) => html`
|
|
5608
5843
|
<jupiter-form-section
|
|
5609
|
-
.section="${
|
|
5610
|
-
.columns="${
|
|
5844
|
+
.section="${section2}"
|
|
5845
|
+
.columns="${section2.columns || this._columns}"
|
|
5611
5846
|
.formData="${this._formData}"
|
|
5612
5847
|
.typedMemberData="${this._typedMemberData}"
|
|
5613
5848
|
.disabled="${this.disabled || this.readonly}"
|
|
5614
5849
|
.collapsible="${config.collapsibleSections !== false}"
|
|
5615
5850
|
.locale="${config.locale || "en-US"}"
|
|
5616
5851
|
.isFirstSection="${index === 0}"
|
|
5617
|
-
.availableDimensions="${this._getAvailableDimensionsForSection(
|
|
5852
|
+
.availableDimensions="${this._getAvailableDimensionsForSection(section2.id)}"
|
|
5618
5853
|
@field-change="${this._handleFieldChange}"
|
|
5619
5854
|
@typed-member-change="${this._handleTypedMemberChange}"
|
|
5620
5855
|
@section-expand="${this._handleSectionExpand}"
|
|
@@ -5636,12 +5871,12 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5636
5871
|
<div class="side-panel-layout">
|
|
5637
5872
|
<!-- Left: Roles List (filtered) -->
|
|
5638
5873
|
<div class="side-panel-roles-list">
|
|
5639
|
-
${visibleSections.map((
|
|
5874
|
+
${visibleSections.map((section2) => html`
|
|
5640
5875
|
<div
|
|
5641
|
-
class="side-panel-role-item ${
|
|
5642
|
-
@click="${() => this._handleSidePanelRoleClick(
|
|
5876
|
+
class="side-panel-role-item ${section2.id === this._activeSidePanelRoleId ? "active" : ""}"
|
|
5877
|
+
@click="${() => this._handleSidePanelRoleClick(section2.id)}"
|
|
5643
5878
|
>
|
|
5644
|
-
${
|
|
5879
|
+
${section2.title}
|
|
5645
5880
|
</div>
|
|
5646
5881
|
`)}
|
|
5647
5882
|
</div>
|
|
@@ -5687,8 +5922,8 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5687
5922
|
></jupiter-form-section>
|
|
5688
5923
|
` : html`
|
|
5689
5924
|
<div class="no-roles-message">
|
|
5690
|
-
<h3
|
|
5691
|
-
<p
|
|
5925
|
+
<h3>${I18n.t("form.noRoleSelected")}</h3>
|
|
5926
|
+
<p>${I18n.t("form.pleaseSelectRole")}</p>
|
|
5692
5927
|
</div>
|
|
5693
5928
|
`}
|
|
5694
5929
|
</div>
|
|
@@ -5722,7 +5957,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5722
5957
|
const showValidationSummary = config.showValidationSummary !== false && errorCount > 0 && this._submitted;
|
|
5723
5958
|
const schema = this._currentSchema;
|
|
5724
5959
|
if (!schema) {
|
|
5725
|
-
return html`<div
|
|
5960
|
+
return html`<div>${I18n.t("form.loading")}</div>`;
|
|
5726
5961
|
}
|
|
5727
5962
|
return html`
|
|
5728
5963
|
<div class="form-container">
|
|
@@ -5751,7 +5986,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5751
5986
|
<svg class="filter-icon" viewBox="0 0 24 24">
|
|
5752
5987
|
<path d="M10 18h4v-2h-4v2zM3 6v2h18V6H3zm3 7h12v-2H6v2z"/>
|
|
5753
5988
|
</svg>
|
|
5754
|
-
${this._selectedRoleIds.length === 0 ? "
|
|
5989
|
+
${this._selectedRoleIds.length === 0 ? I18n.t("filter.selectRoles") : I18n.t("filter.filterRoles")}
|
|
5755
5990
|
<span class="roles-count">${this._selectedRoleIds.length}/${this._allSections.length}</span>
|
|
5756
5991
|
</button>
|
|
5757
5992
|
` : ""}
|
|
@@ -5761,7 +5996,7 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5761
5996
|
@click="${this._handleSaveDraft}"
|
|
5762
5997
|
?disabled="${this.disabled || this.readonly}"
|
|
5763
5998
|
>
|
|
5764
|
-
|
|
5999
|
+
${I18n.t("form.saveDraft")}
|
|
5765
6000
|
</button>
|
|
5766
6001
|
|
|
5767
6002
|
<button
|
|
@@ -5769,13 +6004,13 @@ let JupiterDynamicForm = class extends LitElement {
|
|
|
5769
6004
|
@click="${this._handleSubmit}"
|
|
5770
6005
|
?disabled="${this.disabled || this.readonly}"
|
|
5771
6006
|
>
|
|
5772
|
-
|
|
6007
|
+
${I18n.t("form.submit")}
|
|
5773
6008
|
</button>
|
|
5774
6009
|
|
|
5775
6010
|
<div class="form-meta">
|
|
5776
|
-
<span
|
|
5777
|
-
<span
|
|
5778
|
-
<span
|
|
6011
|
+
<span>${I18n.t("form.errors")}: ${errorCount}</span>
|
|
6012
|
+
<span>${I18n.t("form.modified")}: ${this._dirty ? I18n.t("form.yes") : I18n.t("form.no")}</span>
|
|
6013
|
+
<span>${I18n.t("form.valid")}: ${this._valid ? I18n.t("form.yes") : I18n.t("form.no")}</span>
|
|
5779
6014
|
</div>
|
|
5780
6015
|
</div>
|
|
5781
6016
|
|