@cntrl-site/components 0.1.10-alpha.0 → 0.1.10-alpha.3

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/index.js CHANGED
@@ -1051,12 +1051,12 @@ const ControlSliderComponent = {
1051
1051
  }
1052
1052
  };
1053
1053
  const imageRevealSlider = "ImageRevealSlider-module__imageRevealSlider___UE5Ob";
1054
- const image = "ImageRevealSlider-module__image___Qjt-e";
1054
+ const image$1 = "ImageRevealSlider-module__image___Qjt-e";
1055
1055
  const link = "ImageRevealSlider-module__link___N-iLG";
1056
1056
  const cursor = "ImageRevealSlider-module__cursor___2U03d";
1057
1057
  const styles = {
1058
1058
  imageRevealSlider,
1059
- image,
1059
+ image: image$1,
1060
1060
  link,
1061
1061
  cursor
1062
1062
  };
@@ -1724,9 +1724,9 @@ const getPositionStyles = (position, offset, isEditor) => {
1724
1724
  return styles2;
1725
1725
  };
1726
1726
  function getDisplayedImageRect(img2) {
1727
- const container = img2.getBoundingClientRect();
1728
- const containerW = container.width;
1729
- const containerH = container.height;
1727
+ const container2 = img2.getBoundingClientRect();
1728
+ const containerW = container2.width;
1729
+ const containerH = container2.height;
1730
1730
  const imgW = img2.naturalWidth;
1731
1731
  const imgH = img2.naturalHeight;
1732
1732
  const containerRatio = containerW / containerH;
@@ -1739,8 +1739,8 @@ function getDisplayedImageRect(img2) {
1739
1739
  renderedH = containerH;
1740
1740
  renderedW = containerH * imgRatio;
1741
1741
  }
1742
- const offsetX = (containerW - renderedW) / 2 + container.left;
1743
- const offsetY = (containerH - renderedH) / 2 + container.top;
1742
+ const offsetX = (containerW - renderedW) / 2 + container2.left;
1743
+ const offsetY = (containerH - renderedH) / 2 + container2.top;
1744
1744
  return {
1745
1745
  x: offsetX,
1746
1746
  y: offsetY,
@@ -3428,10 +3428,12 @@ const LightboxComponent = {
3428
3428
  required: ["settings", "content", "styles"]
3429
3429
  }
3430
3430
  };
3431
+ const container = "Testimonials-module__container___H14Dc";
3431
3432
  const wrapper = "Testimonials-module__wrapper___eCRwv";
3432
3433
  const cover = "Testimonials-module__cover___5I7Fh";
3433
3434
  const caption = "Testimonials-module__caption___-YQRG";
3434
3435
  const creds = "Testimonials-module__creds___KKvX1";
3436
+ const image = "Testimonials-module__image___nHD1Y";
3435
3437
  const icon = "Testimonials-module__icon___SstqT";
3436
3438
  const arrow = "Testimonials-module__arrow___NO6BN";
3437
3439
  const nextArrow = "Testimonials-module__nextArrow___L3G-W";
@@ -3440,10 +3442,12 @@ const arrowIcon = "Testimonials-module__arrowIcon___fw7vy";
3440
3442
  const arrowImg = "Testimonials-module__arrowImg___7R9fl";
3441
3443
  const mirror = "Testimonials-module__mirror___JkFna";
3442
3444
  const classes = {
3445
+ container,
3443
3446
  wrapper,
3444
3447
  cover,
3445
3448
  caption,
3446
3449
  creds,
3450
+ image,
3447
3451
  icon,
3448
3452
  arrow,
3449
3453
  nextArrow,
@@ -3486,38 +3490,69 @@ function getAlignPosition(alignment, offset, isEditor) {
3486
3490
  }
3487
3491
  return styles2;
3488
3492
  }
3489
- const Testimonials = ({ settings, content, styles: styles2 }) => {
3493
+ const parseSpeedToMs = (speed) => {
3494
+ if (!speed) return 0;
3495
+ const match = speed.match(/^(\d+)(ms|s)$/);
3496
+ if (!match) return 0;
3497
+ const value = parseInt(match[1], 10);
3498
+ const unit = match[2];
3499
+ return unit === "s" ? value * 1e3 : value;
3500
+ };
3501
+ const Testimonials = ({ settings, content, styles: styles2, isEditor }) => {
3490
3502
  const sliderRef = React.useRef(null);
3491
3503
  const { general, card, controls } = settings;
3492
3504
  const { width, height } = card.dimensions;
3493
3505
  const perMove = settings.general.move === "one" ? 1 : settings.general.inView || 1;
3494
3506
  const perPage = settings.general.inView || 3;
3495
- const wrapperWidth = !settings.general.autoplay ? width * perPage + settings.card.gap * (perPage - 1) + card.borderWidth * 2 : void 0;
3507
+ const isAutoplay = settings.general.autoplay === "on";
3508
+ const marqueePerMove = isAutoplay ? 1 : perMove;
3509
+ const speedMs = isAutoplay ? settings.general.speed ? parseSpeedToMs(settings.general.speed) : 0 : 500;
3510
+ const wrapperWidth = !isAutoplay ? scalingValue(width * perPage + settings.card.gap * (perPage - 1) + card.borders.width * 2 * perPage, isEditor ?? false) : void 0;
3511
+ const splideKey = `${general.autoplay}-${general.inView}`;
3512
+ React.useEffect(() => {
3513
+ var _a;
3514
+ if ((_a = sliderRef.current) == null ? void 0 : _a.splide) {
3515
+ const splide = sliderRef.current.splide;
3516
+ splide.options = {
3517
+ ...splide.options,
3518
+ autoplay: isAutoplay,
3519
+ perPage,
3520
+ perMove: marqueePerMove,
3521
+ interval: isAutoplay ? speedMs || 500 : 0,
3522
+ rewind: !isAutoplay
3523
+ };
3524
+ splide.refresh();
3525
+ }
3526
+ }, [general.autoplay, general.inView, isAutoplay, perPage, marqueePerMove, speedMs]);
3496
3527
  return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
3497
- /* @__PURE__ */ jsxRuntime.jsx("div", { style: { overflow: "hidden", display: "flex", justifyContent: settings.general.alignment }, children: /* @__PURE__ */ jsxRuntime.jsx(
3528
+ /* @__PURE__ */ jsxRuntime.jsx("div", { className: classes.container, style: { justifyContent: settings.general.alignment }, children: /* @__PURE__ */ jsxRuntime.jsx(
3498
3529
  "div",
3499
3530
  {
3500
3531
  className: `${classes.wrapper}`,
3501
- style: wrapperWidth ? { width: `${scalingValue(wrapperWidth, false)}` } : void 0,
3532
+ style: wrapperWidth ? { width: wrapperWidth } : void 0,
3502
3533
  children: /* @__PURE__ */ jsxRuntime.jsx(
3503
3534
  reactSplide.Splide,
3504
3535
  {
3505
3536
  ref: sliderRef,
3506
3537
  options: {
3507
3538
  type: "loop",
3508
- fixedWidth: width,
3509
- ...!settings.general.autoplay && {
3539
+ fixedWidth: scalingValue(width + card.borders.width * 2, isEditor ?? false),
3540
+ ...settings.general.autoplay === "off" && {
3510
3541
  perPage,
3511
3542
  width: wrapperWidth
3512
3543
  },
3513
3544
  arrows: false,
3514
- perMove,
3515
- gap: settings.card.gap,
3545
+ perMove: isAutoplay ? marqueePerMove : perMove,
3546
+ gap: scalingValue(settings.card.gap, isEditor ?? false),
3516
3547
  padding: 0,
3517
- autoplay: settings.general.autoplay,
3518
- speed: settings.general.speed,
3519
- interval: settings.general.autoplay ? settings.general.speed : 0,
3520
- rewind: true,
3548
+ drag: false,
3549
+ autoplay: isAutoplay,
3550
+ speed: speedMs,
3551
+ // Transition duration (default to 500ms if not set)
3552
+ interval: speedMs,
3553
+ // Match speed for continuous marquee flow
3554
+ rewind: !isAutoplay,
3555
+ // Disable rewind for smooth marquee, enable for manual mode
3521
3556
  easing: "linear",
3522
3557
  direction: settings.general.direction === "left" ? "ltr" : "rtl",
3523
3558
  pagination: false,
@@ -3526,17 +3561,71 @@ const Testimonials = ({ settings, content, styles: styles2 }) => {
3526
3561
  },
3527
3562
  children: content.map((item, index) => {
3528
3563
  var _a, _b, _c, _d, _e;
3529
- return /* @__PURE__ */ jsxRuntime.jsx(reactSplide.SplideSlide, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { width: `${width}px`, height: `${height}px`, borderRadius: `${settings.card.corner}px`, border: `${settings.card.borderWidth}px solid ${settings.card.borderColor}`, backgroundColor: settings.card.bgColor, overflow: "hidden", boxSizing: "border-box" }, children: [
3530
- /* @__PURE__ */ jsxRuntime.jsx("img", { src: (_a = item.image) == null ? void 0 : _a.url, alt: (_b = item.image) == null ? void 0 : _b.name, style: { width: "100%", height: "100%", objectFit: ((_c = item.image) == null ? void 0 : _c.objectFit) || "cover" } }),
3531
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: classes.cover, style: { background: settings.elements.cover.gradient, borderRadius: `${settings.card.corner}px` } }),
3532
- /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
3533
- /* @__PURE__ */ jsxRuntime.jsx("img", { src: (_d = item.icon) == null ? void 0 : _d.url, alt: (_e = item.icon) == null ? void 0 : _e.name, className: classes.icon, style: getAlignPosition(settings.elements.icon.alignment, settings.elements.icon.offset) }),
3534
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: classes.caption, style: getAlignPosition(settings.elements.text.alignment, settings.elements.text.offset), children: /* @__PURE__ */ jsxRuntime.jsx(RichTextRenderer, { content: item.imageCaption }) }),
3535
- /* @__PURE__ */ jsxRuntime.jsx("div", { className: classes.creds, style: getAlignPosition(settings.elements.creds.alignment, settings.elements.creds.offset), children: /* @__PURE__ */ jsxRuntime.jsx(RichTextRenderer, { content: item.creds }) })
3536
- ] })
3537
- ] }) }, index);
3564
+ const iconPositionStyles = getAlignPosition(settings.elements.icon.alignment, settings.elements.icon.offset, isEditor);
3565
+ return /* @__PURE__ */ jsxRuntime.jsx(reactSplide.SplideSlide, { children: /* @__PURE__ */ jsxRuntime.jsxs(
3566
+ "div",
3567
+ {
3568
+ style: {
3569
+ width: scalingValue(width, isEditor ?? false),
3570
+ height: scalingValue(height, isEditor ?? false),
3571
+ borderRadius: scalingValue(settings.card.corner, isEditor ?? false),
3572
+ border: `${scalingValue(settings.card.borders.width, isEditor ?? false)} solid ${settings.card.borders.color}`,
3573
+ overflow: "hidden",
3574
+ boxSizing: "border-box"
3575
+ },
3576
+ children: [
3577
+ /* @__PURE__ */ jsxRuntime.jsx(
3578
+ "img",
3579
+ {
3580
+ className: classes.image,
3581
+ src: (_a = item.image) == null ? void 0 : _a.url,
3582
+ alt: (_b = item.image) == null ? void 0 : _b.name,
3583
+ style: { objectFit: ((_c = item.image) == null ? void 0 : _c.objectFit) || "cover" }
3584
+ }
3585
+ ),
3586
+ /* @__PURE__ */ jsxRuntime.jsx(
3587
+ "div",
3588
+ {
3589
+ className: classes.cover,
3590
+ style: { background: settings.card.bgColor, borderRadius: `${scalingValue(settings.card.corner, isEditor ?? false)}` }
3591
+ }
3592
+ ),
3593
+ /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
3594
+ /* @__PURE__ */ jsxRuntime.jsx(
3595
+ "img",
3596
+ {
3597
+ src: (_d = item.icon) == null ? void 0 : _d.url,
3598
+ alt: (_e = item.icon) == null ? void 0 : _e.name,
3599
+ className: classes.icon,
3600
+ style: {
3601
+ ...iconPositionStyles,
3602
+ transform: `${iconPositionStyles.transform || ""} scale(${settings.elements.icon.scale / 100})`
3603
+ }
3604
+ }
3605
+ ),
3606
+ /* @__PURE__ */ jsxRuntime.jsx(
3607
+ "div",
3608
+ {
3609
+ className: classes.caption,
3610
+ style: getAlignPosition(settings.elements.text.alignment, settings.elements.text.offset, isEditor),
3611
+ children: /* @__PURE__ */ jsxRuntime.jsx(RichTextRenderer, { content: item.imageCaption })
3612
+ }
3613
+ ),
3614
+ /* @__PURE__ */ jsxRuntime.jsx(
3615
+ "div",
3616
+ {
3617
+ className: classes.creds,
3618
+ style: getAlignPosition(settings.elements.creds.alignment, settings.elements.creds.offset, isEditor),
3619
+ children: /* @__PURE__ */ jsxRuntime.jsx(RichTextRenderer, { content: item.creds })
3620
+ }
3621
+ )
3622
+ ] })
3623
+ ]
3624
+ }
3625
+ ) }, index);
3538
3626
  })
3539
- }
3627
+ },
3628
+ splideKey
3540
3629
  )
3541
3630
  }
3542
3631
  ) }),
@@ -3550,10 +3639,10 @@ const Testimonials = ({ settings, content, styles: styles2 }) => {
3550
3639
  "button",
3551
3640
  {
3552
3641
  className: classes.arrowInner,
3553
- style: { transform: `translate(${scalingValue(controls.offset.x, false)}, ${scalingValue(controls.offset.y, false)}) scale(${controls.scale / 100})` },
3642
+ style: { transform: `translate(${scalingValue(controls.offset.x, isEditor ?? false)}, ${scalingValue(controls.offset.y, isEditor ?? false)}) scale(${controls.scale / 100})` },
3554
3643
  onClick: () => {
3555
3644
  var _a;
3556
- return (_a = sliderRef.current) == null ? void 0 : _a.go("-1");
3645
+ return (_a = sliderRef.current) == null ? void 0 : _a.go(isAutoplay ? "-1" : `-${perMove}`);
3557
3646
  },
3558
3647
  "aria-label": "Previous",
3559
3648
  children: [
@@ -3581,10 +3670,10 @@ const Testimonials = ({ settings, content, styles: styles2 }) => {
3581
3670
  "button",
3582
3671
  {
3583
3672
  className: classes.arrowInner,
3584
- style: { transform: `translate(${scalingValue(controls.offset.x * -1, false)}, ${scalingValue(controls.offset.y, false)}) scale(${controls.scale / 100})` },
3673
+ style: { transform: `translate(${scalingValue(controls.offset.x * -1, isEditor ?? false)}, ${scalingValue(controls.offset.y, isEditor ?? false)}) scale(${controls.scale / 100})` },
3585
3674
  onClick: () => {
3586
3675
  var _a;
3587
- return (_a = sliderRef.current) == null ? void 0 : _a.go("+1");
3676
+ return (_a = sliderRef.current) == null ? void 0 : _a.go(isAutoplay ? "+1" : `+${perMove}`);
3588
3677
  },
3589
3678
  "aria-label": "Next",
3590
3679
  children: [
@@ -3632,20 +3721,21 @@ const TestimonialsComponent = {
3632
3721
  },
3633
3722
  properties: {
3634
3723
  general: {
3635
- title: "general",
3636
3724
  icon: "thumbnail",
3637
- tooltip: "General",
3638
3725
  type: "object",
3639
3726
  properties: {
3640
3727
  autoplay: {
3641
- type: "boolean",
3728
+ type: "string",
3729
+ title: "Autoplay",
3642
3730
  display: {
3643
- type: "setting-toggle"
3644
- }
3731
+ type: "ratio-group",
3732
+ direction: "horizontal"
3733
+ },
3734
+ enum: ["on", "off"]
3645
3735
  },
3646
3736
  inView: {
3647
3737
  type: "number",
3648
- label: "In View",
3738
+ title: "In View",
3649
3739
  min: 1,
3650
3740
  display: {
3651
3741
  type: "numeric-input"
@@ -3653,27 +3743,29 @@ const TestimonialsComponent = {
3653
3743
  },
3654
3744
  alignment: {
3655
3745
  type: "string",
3746
+ title: "Alignment",
3656
3747
  display: {
3657
- type: "ratio-group"
3748
+ type: "align-group",
3749
+ direction: "vertical"
3658
3750
  },
3659
3751
  enum: ["left", "center", "right"]
3660
3752
  },
3661
3753
  move: {
3662
3754
  type: "string",
3755
+ title: "Move",
3663
3756
  display: {
3664
- type: "ratio-group"
3757
+ type: "ratio-group",
3758
+ direction: "horizontal"
3665
3759
  },
3666
3760
  enum: ["one", "view"]
3667
3761
  },
3668
3762
  speed: {
3669
- type: "number",
3670
- label: "Speed",
3671
- min: 100,
3672
- max: 1e4,
3673
- step: 100,
3763
+ type: ["string", "null"],
3764
+ title: "Speed",
3674
3765
  display: {
3675
- type: "numeric-input"
3676
- }
3766
+ type: "step-selector"
3767
+ },
3768
+ enum: ["100ms", "250ms", "500ms", "1000ms", "1500ms", "2000ms"]
3677
3769
  },
3678
3770
  direction: {
3679
3771
  type: "string",
@@ -3683,6 +3775,7 @@ const TestimonialsComponent = {
3683
3775
  enum: ["left", "right"]
3684
3776
  },
3685
3777
  pause: {
3778
+ title: "Pause on",
3686
3779
  type: "string",
3687
3780
  display: {
3688
3781
  type: "ratio-group"
@@ -3692,21 +3785,19 @@ const TestimonialsComponent = {
3692
3785
  }
3693
3786
  },
3694
3787
  card: {
3695
- title: "card",
3696
3788
  icon: "card",
3697
- tooltip: "Card",
3698
3789
  type: "object",
3699
3790
  properties: {
3700
3791
  dimensions: {
3701
3792
  type: "object",
3702
- title: "Dimensions",
3793
+ title: "Size",
3703
3794
  display: {
3704
3795
  type: "group"
3705
3796
  },
3706
3797
  properties: {
3707
3798
  width: {
3708
3799
  type: "number",
3709
- label: "Width",
3800
+ label: "W",
3710
3801
  scalingEnabled: true,
3711
3802
  display: {
3712
3803
  type: "numeric-input",
@@ -3715,7 +3806,7 @@ const TestimonialsComponent = {
3715
3806
  },
3716
3807
  height: {
3717
3808
  type: "number",
3718
- label: "Height",
3809
+ label: "H",
3719
3810
  scalingEnabled: true,
3720
3811
  display: {
3721
3812
  type: "numeric-input",
@@ -3726,7 +3817,7 @@ const TestimonialsComponent = {
3726
3817
  },
3727
3818
  gap: {
3728
3819
  type: "number",
3729
- label: "Gap",
3820
+ title: "Gap",
3730
3821
  scalingEnabled: true,
3731
3822
  min: 0,
3732
3823
  display: {
@@ -3735,32 +3826,41 @@ const TestimonialsComponent = {
3735
3826
  },
3736
3827
  corner: {
3737
3828
  type: "number",
3738
- label: "Corners",
3739
- scalingEnabled: true,
3740
- min: 0,
3741
- display: {
3742
- type: "numeric-input"
3743
- }
3744
- },
3745
- borderWidth: {
3746
- type: "number",
3747
- label: "Borders",
3829
+ title: "Corners",
3748
3830
  scalingEnabled: true,
3749
3831
  min: 0,
3832
+ label: "icon:border-radius",
3750
3833
  display: {
3751
3834
  type: "numeric-input"
3752
3835
  }
3753
3836
  },
3754
- borderColor: {
3755
- title: "Border Color",
3756
- type: "string",
3837
+ borders: {
3838
+ type: "object",
3839
+ title: "Borders",
3757
3840
  display: {
3758
- type: "settings-color-picker",
3759
- format: "single"
3841
+ type: "group"
3842
+ },
3843
+ properties: {
3844
+ width: {
3845
+ type: "number",
3846
+ label: "icon:border-width",
3847
+ scalingEnabled: true,
3848
+ min: 0,
3849
+ display: {
3850
+ type: "numeric-input"
3851
+ }
3852
+ },
3853
+ color: {
3854
+ type: "string",
3855
+ display: {
3856
+ type: "settings-color-picker",
3857
+ format: "single"
3858
+ }
3859
+ }
3760
3860
  }
3761
3861
  },
3762
3862
  bgColor: {
3763
- title: "Background Color",
3863
+ title: "BG color",
3764
3864
  type: "string",
3765
3865
  display: {
3766
3866
  type: "settings-color-picker",
@@ -3772,12 +3872,17 @@ const TestimonialsComponent = {
3772
3872
  elements: {
3773
3873
  title: "elements",
3774
3874
  icon: "star",
3775
- tooltip: "Elements",
3776
3875
  type: "object",
3777
3876
  properties: {
3877
+ elements: {
3878
+ type: "string",
3879
+ display: {
3880
+ type: "ratio-group"
3881
+ },
3882
+ enum: ["text", "icon", "caption"]
3883
+ },
3778
3884
  text: {
3779
3885
  type: "object",
3780
- title: "Text",
3781
3886
  display: {
3782
3887
  type: "group"
3783
3888
  },
@@ -3785,7 +3890,8 @@ const TestimonialsComponent = {
3785
3890
  alignment: {
3786
3891
  type: "string",
3787
3892
  display: {
3788
- type: "position-selector"
3893
+ type: "align-grid",
3894
+ visible: true
3789
3895
  },
3790
3896
  enum: ["top-left", "top-center", "top-right", "middle-left", "middle-center", "middle-right", "bottom-left", "bottom-center", "bottom-right"]
3791
3897
  },
@@ -3793,7 +3899,8 @@ const TestimonialsComponent = {
3793
3899
  type: "object",
3794
3900
  title: "Offset",
3795
3901
  display: {
3796
- type: "group"
3902
+ type: "group",
3903
+ visible: true
3797
3904
  },
3798
3905
  properties: {
3799
3906
  x: {
@@ -3820,7 +3927,6 @@ const TestimonialsComponent = {
3820
3927
  },
3821
3928
  icon: {
3822
3929
  type: "object",
3823
- title: "Icon",
3824
3930
  display: {
3825
3931
  type: "group"
3826
3932
  },
@@ -3828,7 +3934,7 @@ const TestimonialsComponent = {
3828
3934
  alignment: {
3829
3935
  type: "string",
3830
3936
  display: {
3831
- type: "position-selector"
3937
+ type: "align-grid"
3832
3938
  },
3833
3939
  enum: ["top-left", "top-center", "top-right", "middle-left", "middle-center", "middle-right", "bottom-left", "bottom-center", "bottom-right"]
3834
3940
  },
@@ -3865,14 +3971,14 @@ const TestimonialsComponent = {
3865
3971
  min: 50,
3866
3972
  max: 600,
3867
3973
  display: {
3868
- type: "range-control"
3974
+ type: "range-control",
3975
+ visible: false
3869
3976
  }
3870
3977
  }
3871
3978
  }
3872
3979
  },
3873
3980
  creds: {
3874
3981
  type: "object",
3875
- title: "Credentials",
3876
3982
  display: {
3877
3983
  type: "group"
3878
3984
  },
@@ -3880,7 +3986,7 @@ const TestimonialsComponent = {
3880
3986
  alignment: {
3881
3987
  type: "string",
3882
3988
  display: {
3883
- type: "position-selector"
3989
+ type: "align-grid"
3884
3990
  },
3885
3991
  enum: ["top-left", "top-center", "top-right", "middle-left", "middle-center", "middle-right", "bottom-left", "bottom-center", "bottom-right"]
3886
3992
  },
@@ -3912,23 +4018,6 @@ const TestimonialsComponent = {
3912
4018
  }
3913
4019
  }
3914
4020
  }
3915
- },
3916
- cover: {
3917
- type: "object",
3918
- title: "Cover",
3919
- display: {
3920
- type: "group"
3921
- },
3922
- properties: {
3923
- gradient: {
3924
- title: "Gradient",
3925
- type: "string",
3926
- display: {
3927
- type: "settings-color-picker",
3928
- format: "gradient"
3929
- }
3930
- }
3931
- }
3932
4021
  }
3933
4022
  }
3934
4023
  },
@@ -4007,27 +4096,29 @@ const TestimonialsComponent = {
4007
4096
  },
4008
4097
  default: {
4009
4098
  general: {
4010
- autoplay: false,
4099
+ autoplay: "off",
4011
4100
  inView: 3,
4012
4101
  alignment: "center",
4013
4102
  move: "one",
4014
- speed: 3e3,
4103
+ speed: "3s",
4015
4104
  direction: "left",
4016
- pause: "hover"
4105
+ pause: "off"
4017
4106
  },
4018
4107
  card: {
4019
4108
  dimensions: {
4020
- width: 300,
4021
- height: 400
4109
+ width: 0.1,
4110
+ height: 0.2
4111
+ },
4112
+ gap: 0.02,
4113
+ corner: 0.01,
4114
+ borders: {
4115
+ width: 1e-3,
4116
+ color: "#000000"
4022
4117
  },
4023
- gap: 20,
4024
- corner: 0,
4025
- borderWidth: 0,
4026
- borderColor: "#000000",
4027
- bgColor: "#ffffff"
4118
+ bgColor: "rgba(255, 255, 255, 0.2)"
4028
4119
  },
4029
4120
  controls: {
4030
- isActive: true,
4121
+ isActive: false,
4031
4122
  arrowsImgUrl: null,
4032
4123
  offset: {
4033
4124
  x: 0,
@@ -4038,8 +4129,9 @@ const TestimonialsComponent = {
4038
4129
  hover: "#cccccc"
4039
4130
  },
4040
4131
  elements: {
4132
+ elements: "text",
4041
4133
  text: {
4042
- alignment: "bottom-center",
4134
+ alignment: "middle-left",
4043
4135
  offset: {
4044
4136
  x: 0,
4045
4137
  y: 0
@@ -4054,17 +4146,346 @@ const TestimonialsComponent = {
4054
4146
  scale: 100
4055
4147
  },
4056
4148
  creds: {
4057
- alignment: "bottom-center",
4149
+ alignment: "bottom-left",
4058
4150
  offset: {
4059
4151
  x: 0,
4060
4152
  y: 0
4061
4153
  }
4154
+ }
4155
+ }
4156
+ },
4157
+ displayRules: [
4158
+ {
4159
+ if: {
4160
+ name: "general.autoplay",
4161
+ value: "off"
4162
+ },
4163
+ then: {
4164
+ name: "properties.general.properties.inView.display.visible",
4165
+ value: true
4166
+ }
4167
+ },
4168
+ {
4169
+ if: {
4170
+ name: "general.autoplay",
4171
+ value: "off"
4172
+ },
4173
+ then: {
4174
+ name: "properties.general.properties.alignment.display.visible",
4175
+ value: true
4176
+ }
4177
+ },
4178
+ {
4179
+ if: {
4180
+ name: "general.autoplay",
4181
+ value: "off"
4062
4182
  },
4063
- cover: {
4064
- gradient: "linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.5) 100%)"
4183
+ then: {
4184
+ name: "properties.general.properties.move.display.visible",
4185
+ value: true
4186
+ }
4187
+ },
4188
+ {
4189
+ if: {
4190
+ name: "general.autoplay",
4191
+ value: "on"
4192
+ },
4193
+ then: {
4194
+ name: "properties.general.properties.inView.display.visible",
4195
+ value: false
4196
+ }
4197
+ },
4198
+ {
4199
+ if: {
4200
+ name: "general.autoplay",
4201
+ value: "on"
4202
+ },
4203
+ then: {
4204
+ name: "properties.general.properties.alignment.display.visible",
4205
+ value: false
4206
+ }
4207
+ },
4208
+ {
4209
+ if: {
4210
+ name: "general.autoplay",
4211
+ value: "on"
4212
+ },
4213
+ then: {
4214
+ name: "properties.general.properties.move.display.visible",
4215
+ value: false
4216
+ }
4217
+ },
4218
+ {
4219
+ if: {
4220
+ name: "general.autoplay",
4221
+ value: "on"
4222
+ },
4223
+ then: {
4224
+ name: "properties.general.properties.speed.display.visible",
4225
+ value: true
4226
+ }
4227
+ },
4228
+ {
4229
+ if: {
4230
+ name: "general.autoplay",
4231
+ value: "on"
4232
+ },
4233
+ then: {
4234
+ name: "properties.general.properties.direction.display.visible",
4235
+ value: true
4236
+ }
4237
+ },
4238
+ {
4239
+ if: {
4240
+ name: "general.autoplay",
4241
+ value: "on"
4242
+ },
4243
+ then: {
4244
+ name: "properties.general.properties.pause.display.visible",
4245
+ value: true
4246
+ }
4247
+ },
4248
+ {
4249
+ if: {
4250
+ name: "general.autoplay",
4251
+ value: "off"
4252
+ },
4253
+ then: {
4254
+ name: "properties.general.properties.speed.display.visible",
4255
+ value: false
4256
+ }
4257
+ },
4258
+ {
4259
+ if: {
4260
+ name: "general.autoplay",
4261
+ value: "off"
4262
+ },
4263
+ then: {
4264
+ name: "properties.general.properties.direction.display.visible",
4265
+ value: false
4266
+ }
4267
+ },
4268
+ {
4269
+ if: {
4270
+ name: "general.autoplay",
4271
+ value: "off"
4272
+ },
4273
+ then: {
4274
+ name: "properties.general.properties.pause.display.visible",
4275
+ value: false
4276
+ }
4277
+ },
4278
+ {
4279
+ if: {
4280
+ name: "elements.elements",
4281
+ value: "text"
4282
+ },
4283
+ then: {
4284
+ name: "properties.elements.properties.text.properties.alignment.display.visible",
4285
+ value: true
4286
+ }
4287
+ },
4288
+ {
4289
+ if: {
4290
+ name: "elements.elements",
4291
+ value: "text"
4292
+ },
4293
+ then: {
4294
+ name: "properties.elements.properties.text.properties.offset.display.visible",
4295
+ value: true
4296
+ }
4297
+ },
4298
+ {
4299
+ if: {
4300
+ name: "elements.elements",
4301
+ value: "text"
4302
+ },
4303
+ then: {
4304
+ name: "properties.elements.properties.icon.properties.alignment.display.visible",
4305
+ value: false
4306
+ }
4307
+ },
4308
+ {
4309
+ if: {
4310
+ name: "elements.elements",
4311
+ value: "text"
4312
+ },
4313
+ then: {
4314
+ name: "properties.elements.properties.icon.properties.offset.display.visible",
4315
+ value: false
4316
+ }
4317
+ },
4318
+ {
4319
+ if: {
4320
+ name: "elements.elements",
4321
+ value: "text"
4322
+ },
4323
+ then: {
4324
+ name: "properties.elements.properties.creds.properties.alignment.display.visible",
4325
+ value: false
4326
+ }
4327
+ },
4328
+ {
4329
+ if: {
4330
+ name: "elements.elements",
4331
+ value: "text"
4332
+ },
4333
+ then: {
4334
+ name: "properties.elements.properties.creds.properties.offset.display.visible",
4335
+ value: false
4336
+ }
4337
+ },
4338
+ {
4339
+ if: {
4340
+ name: "elements.elements",
4341
+ value: "icon"
4342
+ },
4343
+ then: {
4344
+ name: "properties.elements.properties.icon.properties.alignment.display.visible",
4345
+ value: true
4346
+ }
4347
+ },
4348
+ {
4349
+ if: {
4350
+ name: "elements.elements",
4351
+ value: "icon"
4352
+ },
4353
+ then: {
4354
+ name: "properties.elements.properties.icon.properties.offset.display.visible",
4355
+ value: true
4356
+ }
4357
+ },
4358
+ {
4359
+ if: {
4360
+ name: "elements.elements",
4361
+ value: "icon"
4362
+ },
4363
+ then: {
4364
+ name: "properties.elements.properties.text.properties.alignment.display.visible",
4365
+ value: false
4366
+ }
4367
+ },
4368
+ {
4369
+ if: {
4370
+ name: "elements.elements",
4371
+ value: "icon"
4372
+ },
4373
+ then: {
4374
+ name: "properties.elements.properties.text.properties.offset.display.visible",
4375
+ value: false
4376
+ }
4377
+ },
4378
+ {
4379
+ if: {
4380
+ name: "elements.elements",
4381
+ value: "icon"
4382
+ },
4383
+ then: {
4384
+ name: "properties.elements.properties.creds.properties.alignment.display.visible",
4385
+ value: false
4386
+ }
4387
+ },
4388
+ {
4389
+ if: {
4390
+ name: "elements.elements",
4391
+ value: "icon"
4392
+ },
4393
+ then: {
4394
+ name: "properties.elements.properties.creds.properties.offset.display.visible",
4395
+ value: false
4396
+ }
4397
+ },
4398
+ {
4399
+ if: {
4400
+ name: "elements.elements",
4401
+ value: "caption"
4402
+ },
4403
+ then: {
4404
+ name: "properties.elements.properties.creds.properties.alignment.display.visible",
4405
+ value: true
4406
+ }
4407
+ },
4408
+ {
4409
+ if: {
4410
+ name: "elements.elements",
4411
+ value: "caption"
4412
+ },
4413
+ then: {
4414
+ name: "properties.elements.properties.creds.properties.offset.display.visible",
4415
+ value: true
4416
+ }
4417
+ },
4418
+ {
4419
+ if: {
4420
+ name: "elements.elements",
4421
+ value: "caption"
4422
+ },
4423
+ then: {
4424
+ name: "properties.elements.properties.text.properties.alignment.display.visible",
4425
+ value: false
4426
+ }
4427
+ },
4428
+ {
4429
+ if: {
4430
+ name: "elements.elements",
4431
+ value: "caption"
4432
+ },
4433
+ then: {
4434
+ name: "properties.elements.properties.text.properties.offset.display.visible",
4435
+ value: false
4436
+ }
4437
+ },
4438
+ {
4439
+ if: {
4440
+ name: "elements.elements",
4441
+ value: "caption"
4442
+ },
4443
+ then: {
4444
+ name: "properties.elements.properties.icon.properties.alignment.display.visible",
4445
+ value: false
4446
+ }
4447
+ },
4448
+ {
4449
+ if: {
4450
+ name: "elements.elements",
4451
+ value: "caption"
4452
+ },
4453
+ then: {
4454
+ name: "properties.elements.properties.icon.properties.offset.display.visible",
4455
+ value: false
4456
+ }
4457
+ },
4458
+ {
4459
+ if: {
4460
+ name: "elements.elements",
4461
+ value: "icon"
4462
+ },
4463
+ then: {
4464
+ name: "properties.elements.properties.icon.properties.scale.display.visible",
4465
+ value: true
4466
+ }
4467
+ },
4468
+ {
4469
+ if: {
4470
+ name: "elements.elements",
4471
+ value: "text"
4472
+ },
4473
+ then: {
4474
+ name: "properties.elements.properties.icon.properties.scale.display.visible",
4475
+ value: false
4476
+ }
4477
+ },
4478
+ {
4479
+ if: {
4480
+ name: "elements.elements",
4481
+ value: "caption"
4482
+ },
4483
+ then: {
4484
+ name: "properties.elements.properties.icon.properties.scale.display.visible",
4485
+ value: false
4065
4486
  }
4066
4487
  }
4067
- }
4488
+ ]
4068
4489
  },
4069
4490
  content: {
4070
4491
  layoutBased: false,
@@ -4121,8 +4542,8 @@ const TestimonialsComponent = {
4121
4542
  required: ["url", "name"]
4122
4543
  },
4123
4544
  imageCaption: {
4124
- placeholder: "Add Caption...",
4125
- label: "Description",
4545
+ placeholder: "Add Text...",
4546
+ label: "Text",
4126
4547
  display: {
4127
4548
  type: "rich-text",
4128
4549
  minWidth: 300,
@@ -4130,8 +4551,8 @@ const TestimonialsComponent = {
4130
4551
  }
4131
4552
  },
4132
4553
  creds: {
4133
- placeholder: "Add Credentials...",
4134
- label: "Credentials",
4554
+ placeholder: "Add Caption...",
4555
+ label: "Caption",
4135
4556
  display: {
4136
4557
  type: "rich-text",
4137
4558
  minWidth: 300,
@@ -4145,12 +4566,12 @@ const TestimonialsComponent = {
4145
4566
  {
4146
4567
  image: {
4147
4568
  objectFit: "cover",
4148
- url: "https://cdn.cntrl.site/projects/01JJKT02AWY2FGN2QJ7A173RNZ/articles-assets/01K7ERMHNP08T27H1649S67NZV.png",
4569
+ url: "https://cdn.cntrl.site/component-assets/2.jpg",
4149
4570
  name: "Testimonial-1.png"
4150
4571
  },
4151
4572
  icon: {
4152
4573
  objectFit: "cover",
4153
- url: "",
4574
+ url: "https://cdn.cntrl.site/projects/01GJ2SPNXG3V5P35ZA35YM1JTW/articles-assets/01KEXYWFPR7GB70E4YBF28T8R6.png",
4154
4575
  name: ""
4155
4576
  },
4156
4577
  imageCaption: [
@@ -4169,12 +4590,12 @@ const TestimonialsComponent = {
4169
4590
  {
4170
4591
  image: {
4171
4592
  objectFit: "cover",
4172
- url: "https://cdn.cntrl.site/projects/01JJKT02AWY2FGN2QJ7A173RNZ/articles-assets/01K7ERMTZA3RYMXKF0M095D6JD.png",
4593
+ url: "https://cdn.cntrl.site/component-assets/3.jpg",
4173
4594
  name: "Testimonial-2.png"
4174
4595
  },
4175
4596
  icon: {
4176
4597
  objectFit: "cover",
4177
- url: "",
4598
+ url: "https://cdn.cntrl.site/projects/01GJ2SPNXG3V5P35ZA35YM1JTW/articles-assets/01KEXYWFPR7GB70E4YBF28T8R6.png",
4178
4599
  name: ""
4179
4600
  },
4180
4601
  imageCaption: [
@@ -4193,12 +4614,12 @@ const TestimonialsComponent = {
4193
4614
  {
4194
4615
  image: {
4195
4616
  objectFit: "cover",
4196
- url: "https://cdn.cntrl.site/projects/01JJKT02AWY2FGN2QJ7A173RNZ/articles-assets/01K7ERMVSCMPVJBG2WF5KJZYHZ.png",
4617
+ url: "https://cdn.cntrl.site/component-assets/4.jpg",
4197
4618
  name: "Testimonial-3.png"
4198
4619
  },
4199
4620
  icon: {
4200
4621
  objectFit: "cover",
4201
- url: "",
4622
+ url: "https://cdn.cntrl.site/projects/01GJ2SPNXG3V5P35ZA35YM1JTW/articles-assets/01KEXYWFPR7GB70E4YBF28T8R6.png",
4202
4623
  name: ""
4203
4624
  },
4204
4625
  imageCaption: [