@vectoriox/iox-builder 1.4.79 → 1.4.81
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.
|
@@ -4387,6 +4387,21 @@ class BuilderComponent {
|
|
|
4387
4387
|
this.panelEventService.emit(PanelEventTypes.LAYOUT_CHANGED, this.layout);
|
|
4388
4388
|
break;
|
|
4389
4389
|
}
|
|
4390
|
+
case ToolbarAction.AddSlide: {
|
|
4391
|
+
if (!Array.isArray(node.children))
|
|
4392
|
+
break;
|
|
4393
|
+
const slide = this.registry.createConfig('SliderSlide');
|
|
4394
|
+
if (!slide)
|
|
4395
|
+
break;
|
|
4396
|
+
node.children = [...node.children, slide];
|
|
4397
|
+
const ref = this.overlayService.getNodeRef(node);
|
|
4398
|
+
if (ref?.componentRef) {
|
|
4399
|
+
ref.componentRef.setInput('children', node.children);
|
|
4400
|
+
ref.componentRef.changeDetectorRef.detectChanges();
|
|
4401
|
+
}
|
|
4402
|
+
this.panelEventService.emit(PanelEventTypes.LAYOUT_CHANGED, this.layout);
|
|
4403
|
+
break;
|
|
4404
|
+
}
|
|
4390
4405
|
}
|
|
4391
4406
|
}
|
|
4392
4407
|
confirmSaveBlock() {
|
|
@@ -5431,7 +5446,7 @@ class SliderContainerComponent {
|
|
|
5431
5446
|
// Swiper core config
|
|
5432
5447
|
this.direction = 'horizontal';
|
|
5433
5448
|
this.loop = false;
|
|
5434
|
-
this.slidesPerView =
|
|
5449
|
+
this.slidesPerView = 'auto';
|
|
5435
5450
|
this.spaceBetween = 0;
|
|
5436
5451
|
this.speed = 300;
|
|
5437
5452
|
this.effect = 'slide';
|
|
@@ -5867,7 +5882,7 @@ class SliderSlideComponent {
|
|
|
5867
5882
|
</ng-container>
|
|
5868
5883
|
</div>
|
|
5869
5884
|
</div>
|
|
5870
|
-
`, isInline: true, styles: [".swiper-slide,.slide-edit-block{position:relative;box-sizing:border-box;
|
|
5885
|
+
`, isInline: true, styles: [".swiper-slide,.slide-edit-block{position:relative;box-sizing:border-box;display:flex;align-items:center;justify-content:center;overflow:hidden}.slide-placeholder{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.5rem;border:1.5px dashed rgba(100,116,139,.35);border-radius:4px;color:#64748b80;font-size:12px;pointer-events:none;-webkit-user-select:none;user-select:none;opacity:0;transition:opacity .15s}:host:hover .slide-placeholder,:host.iox-drag-over .slide-placeholder{opacity:1}.slide-placeholder i{font-size:22px}\n"], dependencies: [{ kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: RenderDirective, selector: "[ioxRender]", inputs: ["ioxRender"], outputs: ["onClick", "onMouseEnter", "onMouseLeave"] }, { kind: "directive", type: IoxDraggableDirective, selector: "[ioxDraggable]", inputs: ["ioxDragData", "ioxDragSourceId"] }, { kind: "directive", type: IoxDropzoneDirective, selector: "[ioxDropzone]", inputs: ["ioxDropzoneId", "ioxDropzoneData", "ioxDropzonePostDrop"], outputs: ["ioxDrop"] }] }); }
|
|
5871
5886
|
}
|
|
5872
5887
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImport: i0, type: SliderSlideComponent, decorators: [{
|
|
5873
5888
|
type: Component,
|
|
@@ -5929,7 +5944,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
|
|
|
5929
5944
|
</ng-container>
|
|
5930
5945
|
</div>
|
|
5931
5946
|
</div>
|
|
5932
|
-
`, standalone: false, styles: [".swiper-slide,.slide-edit-block{position:relative;box-sizing:border-box;
|
|
5947
|
+
`, standalone: false, styles: [".swiper-slide,.slide-edit-block{position:relative;box-sizing:border-box;display:flex;align-items:center;justify-content:center;overflow:hidden}.slide-placeholder{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.5rem;border:1.5px dashed rgba(100,116,139,.35);border-radius:4px;color:#64748b80;font-size:12px;pointer-events:none;-webkit-user-select:none;user-select:none;opacity:0;transition:opacity .15s}:host:hover .slide-placeholder,:host.iox-drag-over .slide-placeholder{opacity:1}.slide-placeholder i{font-size:22px}\n"] }]
|
|
5933
5948
|
}], ctorParameters: () => [{ type: DragEngineService }, { type: i0.ChangeDetectorRef }, { type: undefined, decorators: [{
|
|
5934
5949
|
type: Optional
|
|
5935
5950
|
}, {
|
|
@@ -6792,10 +6807,41 @@ class SectionComponentConfig extends ComponentConfig {
|
|
|
6792
6807
|
}
|
|
6793
6808
|
}
|
|
6794
6809
|
|
|
6810
|
+
class SliderSlideConfig extends ComponentConfig {
|
|
6811
|
+
constructor() {
|
|
6812
|
+
super('SliderSlide', 'app-slider-slide', 'ph-thin ph-rectangle', 'Media');
|
|
6813
|
+
this.children = [];
|
|
6814
|
+
// Hidden: SliderSlide is created only via the "Add Slide" toolbar button,
|
|
6815
|
+
// not by dragging from the Components panel.
|
|
6816
|
+
this.hidden = true;
|
|
6817
|
+
this.componentEvents = [
|
|
6818
|
+
{ value: 'swiperSlideActive', label: 'This Slide Becomes Active', icon: 'ph-thin ph-eye' },
|
|
6819
|
+
{ value: 'swiperSlideInactive', label: 'This Slide Becomes Inactive', icon: 'ph-thin ph-eye-slash' },
|
|
6820
|
+
];
|
|
6821
|
+
this.traits = [];
|
|
6822
|
+
this.styleTraits = [
|
|
6823
|
+
new PositionGroupStyleConfig(),
|
|
6824
|
+
new SizeGroupStyleConfig(),
|
|
6825
|
+
new SpacingGroupStyleConfig(),
|
|
6826
|
+
new BorderGroupStyleConfig(),
|
|
6827
|
+
new BackgroundGroupStyleConfig(),
|
|
6828
|
+
];
|
|
6829
|
+
this.applyStyleDefaults({
|
|
6830
|
+
width: '33%',
|
|
6831
|
+
aspectRatio: '1 / 1',
|
|
6832
|
+
});
|
|
6833
|
+
}
|
|
6834
|
+
}
|
|
6835
|
+
|
|
6795
6836
|
class SliderContainerConfig extends ComponentConfig {
|
|
6796
6837
|
constructor() {
|
|
6797
6838
|
super('SliderContainer', 'app-slider-container', 'ph-thin ph-slideshow', 'Media');
|
|
6798
|
-
this.children = [
|
|
6839
|
+
this.children = [
|
|
6840
|
+
new SliderSlideConfig(),
|
|
6841
|
+
new SliderSlideConfig(),
|
|
6842
|
+
new SliderSlideConfig(),
|
|
6843
|
+
new SliderSlideConfig(),
|
|
6844
|
+
];
|
|
6799
6845
|
this.componentEvents = [
|
|
6800
6846
|
{ value: 'swiperSlideChange', label: 'Slide Changes', icon: 'ph-thin ph-arrows-left-right' },
|
|
6801
6847
|
{ value: 'swiperReachBeginning', label: 'Reaches First Slide', icon: 'ph-thin ph-skip-back' },
|
|
@@ -6823,7 +6869,15 @@ class SliderContainerConfig extends ComponentConfig {
|
|
|
6823
6869
|
{ label: 'Cards', value: 'cards' },
|
|
6824
6870
|
{ label: 'Creative', value: 'creative' },
|
|
6825
6871
|
], 'slide'),
|
|
6826
|
-
new TraitConfig('slidesPerView', 'Slides per view', TraitInputType.
|
|
6872
|
+
new TraitConfig('slidesPerView', 'Slides per view', TraitInputType.Select, [
|
|
6873
|
+
{ label: 'Auto (use slide width)', value: 'auto' },
|
|
6874
|
+
{ label: '1', value: 1 },
|
|
6875
|
+
{ label: '2', value: 2 },
|
|
6876
|
+
{ label: '3', value: 3 },
|
|
6877
|
+
{ label: '4', value: 4 },
|
|
6878
|
+
{ label: '5', value: 5 },
|
|
6879
|
+
{ label: '6', value: 6 },
|
|
6880
|
+
], 'auto'),
|
|
6827
6881
|
new TraitConfig('spaceBetween', 'Space between (px)', TraitInputType.Number, undefined, 0),
|
|
6828
6882
|
new TraitConfig('speed', 'Transition speed (ms)', TraitInputType.Number, undefined, 300),
|
|
6829
6883
|
new TraitConfig('initialSlide', 'Initial slide', TraitInputType.Number, undefined, 0),
|
|
@@ -6865,6 +6919,7 @@ class SliderContainerConfig extends ComponentConfig {
|
|
|
6865
6919
|
this.styleTraits = [
|
|
6866
6920
|
new PositionGroupStyleConfig(),
|
|
6867
6921
|
new SizeGroupStyleConfig(),
|
|
6922
|
+
new LayoutGroupStyleConfig(),
|
|
6868
6923
|
new SpacingGroupStyleConfig(),
|
|
6869
6924
|
new BorderGroupStyleConfig(),
|
|
6870
6925
|
new BackgroundGroupStyleConfig(),
|
|
@@ -6877,32 +6932,6 @@ class SliderContainerConfig extends ComponentConfig {
|
|
|
6877
6932
|
}
|
|
6878
6933
|
}
|
|
6879
6934
|
|
|
6880
|
-
class SliderSlideConfig extends ComponentConfig {
|
|
6881
|
-
constructor() {
|
|
6882
|
-
super('SliderSlide', 'app-slider-slide', 'ph-thin ph-rectangle', 'Media');
|
|
6883
|
-
this.children = [];
|
|
6884
|
-
// Hidden: SliderSlide is created only via the "Add Slide" toolbar button,
|
|
6885
|
-
// not by dragging from the Components panel.
|
|
6886
|
-
this.hidden = true;
|
|
6887
|
-
this.componentEvents = [
|
|
6888
|
-
{ value: 'swiperSlideActive', label: 'This Slide Becomes Active', icon: 'ph-thin ph-eye' },
|
|
6889
|
-
{ value: 'swiperSlideInactive', label: 'This Slide Becomes Inactive', icon: 'ph-thin ph-eye-slash' },
|
|
6890
|
-
];
|
|
6891
|
-
this.traits = [];
|
|
6892
|
-
this.styleTraits = [
|
|
6893
|
-
new PositionGroupStyleConfig(),
|
|
6894
|
-
new SizeGroupStyleConfig(),
|
|
6895
|
-
new SpacingGroupStyleConfig(),
|
|
6896
|
-
new BorderGroupStyleConfig(),
|
|
6897
|
-
new BackgroundGroupStyleConfig(),
|
|
6898
|
-
];
|
|
6899
|
-
this.applyStyleDefaults({
|
|
6900
|
-
width: '100%',
|
|
6901
|
-
height: '100%',
|
|
6902
|
-
});
|
|
6903
|
-
}
|
|
6904
|
-
}
|
|
6905
|
-
|
|
6906
6935
|
class BuilderSpacerComponentConfig extends ComponentConfig {
|
|
6907
6936
|
constructor() {
|
|
6908
6937
|
super('Spacer', 'app-builder-spacer', 'ph-thin ph-arrows-vertical', 'Layout');
|