@acorex/platform 20.6.0-next.24 → 20.6.0-next.26
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/common/index.d.ts +4 -0
- package/core/index.d.ts +1 -1
- package/fesm2022/acorex-platform-common.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-components.mjs +2 -2
- package/fesm2022/acorex-platform-layout-components.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-entity.mjs +4 -3
- package/fesm2022/acorex-platform-layout-entity.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-widgets.mjs +54 -40
- package/fesm2022/acorex-platform-layout-widgets.mjs.map +1 -1
- package/package.json +9 -9
|
@@ -1482,32 +1482,27 @@ class AXPCheckBoxWidgetColumnComponent extends AXPColumnWidgetComponent {
|
|
|
1482
1482
|
this.falsyText = this.options['falsyText'];
|
|
1483
1483
|
}
|
|
1484
1484
|
getVisual(isTrue) {
|
|
1485
|
-
const semantic = isTrue
|
|
1486
|
-
? this.negative
|
|
1487
|
-
? 'danger'
|
|
1488
|
-
: 'success'
|
|
1489
|
-
: this.negative
|
|
1490
|
-
? 'success'
|
|
1491
|
-
: 'danger';
|
|
1485
|
+
const semantic = isTrue ? (this.negative ? 'danger' : 'success') : this.negative ? 'success' : 'danger';
|
|
1492
1486
|
return resolveStatusVisual(semantic);
|
|
1493
1487
|
}
|
|
1494
1488
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.12", ngImport: i0, type: AXPCheckBoxWidgetColumnComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
1495
1489
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.12", type: AXPCheckBoxWidgetColumnComponent, isStandalone: true, selector: "axp-checkbox-widget-column", inputs: { rawValue: "rawValue", rowData: "rowData" }, usesInheritance: true, ngImport: i0, template: ` <div>
|
|
1496
1490
|
@if (this.rawValue === null || this.rawValue === undefined) {
|
|
1497
|
-
@if (nullText
|
|
1498
|
-
<span>{{ nullText
|
|
1491
|
+
@if (nullText) {
|
|
1492
|
+
<span>{{ nullText }}</span>
|
|
1499
1493
|
} @else {
|
|
1500
1494
|
<span>---</span>
|
|
1501
1495
|
}
|
|
1502
1496
|
} @else if (this.rawValue) {
|
|
1503
1497
|
@if (trulyText) {
|
|
1504
1498
|
@let visual = getVisual(true);
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1499
|
+
<span
|
|
1500
|
+
class="ax-inline-flex ax-items-center ax-gap-1.5 ax-rounded-md ax-px-2 ax-py-0.5 ax-text-xs ax-font-medium"
|
|
1501
|
+
[ngClass]="visual.chipClass"
|
|
1502
|
+
[ngStyle]="visual.chipStyle"
|
|
1503
|
+
>
|
|
1504
|
+
{{ trulyText }}
|
|
1505
|
+
</span>
|
|
1511
1506
|
} @else {
|
|
1512
1507
|
@if (negative) {
|
|
1513
1508
|
<ax-icon class="fa-solid fa-xmark ax-text-danger-500"> </ax-icon>
|
|
@@ -1518,9 +1513,10 @@ class AXPCheckBoxWidgetColumnComponent extends AXPColumnWidgetComponent {
|
|
|
1518
1513
|
} @else {
|
|
1519
1514
|
@if (falsyText) {
|
|
1520
1515
|
@let visual = getVisual(false);
|
|
1521
|
-
<span
|
|
1522
|
-
|
|
1523
|
-
|
|
1516
|
+
<span
|
|
1517
|
+
class="ax-inline-flex ax-items-center ax-gap-1.5 ax-rounded-md ax-px-2 ax-py-0.5 ax-text-xs ax-font-medium"
|
|
1518
|
+
[ngClass]="visual.chipClass"
|
|
1519
|
+
[ngStyle]="visual.chipStyle"
|
|
1524
1520
|
>
|
|
1525
1521
|
{{ falsyText }}
|
|
1526
1522
|
</span>
|
|
@@ -1540,20 +1536,21 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
|
|
|
1540
1536
|
selector: 'axp-checkbox-widget-column',
|
|
1541
1537
|
template: ` <div>
|
|
1542
1538
|
@if (this.rawValue === null || this.rawValue === undefined) {
|
|
1543
|
-
@if (nullText
|
|
1544
|
-
<span>{{ nullText
|
|
1539
|
+
@if (nullText) {
|
|
1540
|
+
<span>{{ nullText }}</span>
|
|
1545
1541
|
} @else {
|
|
1546
1542
|
<span>---</span>
|
|
1547
1543
|
}
|
|
1548
1544
|
} @else if (this.rawValue) {
|
|
1549
1545
|
@if (trulyText) {
|
|
1550
1546
|
@let visual = getVisual(true);
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1547
|
+
<span
|
|
1548
|
+
class="ax-inline-flex ax-items-center ax-gap-1.5 ax-rounded-md ax-px-2 ax-py-0.5 ax-text-xs ax-font-medium"
|
|
1549
|
+
[ngClass]="visual.chipClass"
|
|
1550
|
+
[ngStyle]="visual.chipStyle"
|
|
1551
|
+
>
|
|
1552
|
+
{{ trulyText }}
|
|
1553
|
+
</span>
|
|
1557
1554
|
} @else {
|
|
1558
1555
|
@if (negative) {
|
|
1559
1556
|
<ax-icon class="fa-solid fa-xmark ax-text-danger-500"> </ax-icon>
|
|
@@ -1564,9 +1561,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.12", ngImpo
|
|
|
1564
1561
|
} @else {
|
|
1565
1562
|
@if (falsyText) {
|
|
1566
1563
|
@let visual = getVisual(false);
|
|
1567
|
-
<span
|
|
1568
|
-
|
|
1569
|
-
|
|
1564
|
+
<span
|
|
1565
|
+
class="ax-inline-flex ax-items-center ax-gap-1.5 ax-rounded-md ax-px-2 ax-py-0.5 ax-text-xs ax-font-medium"
|
|
1566
|
+
[ngClass]="visual.chipClass"
|
|
1567
|
+
[ngStyle]="visual.chipStyle"
|
|
1570
1568
|
>
|
|
1571
1569
|
{{ falsyText }}
|
|
1572
1570
|
</span>
|
|
@@ -9682,7 +9680,19 @@ class AXPFileUploaderWidgetEditComponent extends AXPValueWidgetComponent {
|
|
|
9682
9680
|
* Handle file rename action
|
|
9683
9681
|
*/
|
|
9684
9682
|
handleFileRename(file) {
|
|
9685
|
-
this.
|
|
9683
|
+
const currentFiles = this.getValue() ?? [];
|
|
9684
|
+
const previousFile = currentFiles.find((f) => f.id === file.id);
|
|
9685
|
+
// Check if name has changed and previous status was 'uploaded' or 'remote'
|
|
9686
|
+
const nameChanged = previousFile && previousFile.name !== file.name;
|
|
9687
|
+
const shouldChangeStatus = nameChanged &&
|
|
9688
|
+
previousFile &&
|
|
9689
|
+
(previousFile.status === 'uploaded' || previousFile.status === 'remote');
|
|
9690
|
+
// Update file data and change status to 'editing' if name changed and status was 'uploaded' or 'remote'
|
|
9691
|
+
const updatedFile = {
|
|
9692
|
+
...file,
|
|
9693
|
+
status: shouldChangeStatus ? 'editing' : file.status,
|
|
9694
|
+
};
|
|
9695
|
+
this.setValue(currentFiles.map((f) => (f.id === file.id ? updatedFile : f)) ?? []);
|
|
9686
9696
|
}
|
|
9687
9697
|
clear() {
|
|
9688
9698
|
for (const file of this.files()) {
|
|
@@ -22005,22 +22015,26 @@ class AXPTimeDurationFilterComponent extends AXPValueWidgetComponent {
|
|
|
22005
22015
|
path: this.editorPath,
|
|
22006
22016
|
}, ...(ngDevMode ? [{ debugName: "timeDurationNode" }] : []));
|
|
22007
22017
|
this.#efUpdateTimeDurationNode = effect(() => {
|
|
22008
|
-
|
|
22009
|
-
|
|
22010
|
-
|
|
22011
|
-
|
|
22012
|
-
|
|
22013
|
-
|
|
22014
|
-
|
|
22015
|
-
|
|
22016
|
-
|
|
22017
|
-
|
|
22018
|
+
untracked(async () => {
|
|
22019
|
+
const node = {
|
|
22020
|
+
type: 'time-duration',
|
|
22021
|
+
path: this.editorPath,
|
|
22022
|
+
defaultValue: this.value(),
|
|
22023
|
+
options: {
|
|
22024
|
+
from: { title: 'HOUR' },
|
|
22025
|
+
to: { title: 'MINUTE' },
|
|
22026
|
+
},
|
|
22027
|
+
};
|
|
22028
|
+
this.timeDurationNode.set(node);
|
|
22029
|
+
});
|
|
22018
22030
|
}, ...(ngDevMode ? [{ debugName: "#efUpdateTimeDurationNode" }] : []));
|
|
22019
22031
|
this.displayText = async () => {
|
|
22020
22032
|
return await this.timeDurationFormatter.millisecondsToMask(this.value(), 'HOUR', 'MINUTE', false, '00:00:00:00:00:00:00:000', true);
|
|
22021
22033
|
};
|
|
22022
22034
|
this.#efUpdateValue = effect(async () => {
|
|
22023
22035
|
const newValue = this.contextService.getValue(this.editorPath);
|
|
22036
|
+
if (!newValue)
|
|
22037
|
+
return;
|
|
22024
22038
|
untracked(async () => {
|
|
22025
22039
|
this.setValue({
|
|
22026
22040
|
value: newValue,
|