@xiriframework/xiri-ng 0.2.28 → 0.2.29
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/fesm2022/xiriframework-xiri-ng.mjs +15 -3
- package/fesm2022/xiriframework-xiri-ng.mjs.map +1 -1
- package/package.json +1 -1
- package/skills/xiri-ng-expert/references/components.md +5 -1
- package/styles/material-components.scss +12 -0
- package/types/xiriframework-xiri-ng.d.ts +3 -2
- package/types/xiriframework-xiri-ng.d.ts.map +1 -1
|
@@ -2629,6 +2629,13 @@ function parseHttpError(err) {
|
|
|
2629
2629
|
return 'Unknown error';
|
|
2630
2630
|
}
|
|
2631
2631
|
|
|
2632
|
+
const DIALOG_SIZE_MAP = {
|
|
2633
|
+
sm: '400px',
|
|
2634
|
+
md: '600px',
|
|
2635
|
+
lg: '900px',
|
|
2636
|
+
xl: '1200px',
|
|
2637
|
+
full: '95vw',
|
|
2638
|
+
};
|
|
2632
2639
|
class XiriDialogComponent {
|
|
2633
2640
|
constructor() {
|
|
2634
2641
|
this.dialogRef = inject(MatDialogRef);
|
|
@@ -2657,10 +2664,15 @@ class XiriDialogComponent {
|
|
|
2657
2664
|
.observe([Breakpoints.XSmall, Breakpoints.Small])
|
|
2658
2665
|
.pipe(takeUntilDestroyed(this.destroyRef))
|
|
2659
2666
|
.subscribe((state) => {
|
|
2660
|
-
if (state.matches)
|
|
2667
|
+
if (state.matches) {
|
|
2661
2668
|
this.dialogRef.updateSize('90vw');
|
|
2662
|
-
|
|
2663
|
-
|
|
2669
|
+
return;
|
|
2670
|
+
}
|
|
2671
|
+
const raw = this.initData.size;
|
|
2672
|
+
const width = DIALOG_SIZE_MAP[raw] ?? raw ?? '600px';
|
|
2673
|
+
this.dialogRef.updateSize(width);
|
|
2674
|
+
if (raw === 'full')
|
|
2675
|
+
this.dialogRef.addPanelClass('xiri-dialog-full');
|
|
2664
2676
|
});
|
|
2665
2677
|
if (this.initData.url)
|
|
2666
2678
|
this.url = this.initData.url;
|