virtual-ui-lib 1.0.74 → 1.0.76

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
@@ -29,10 +29,12 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
29
29
  // src/index.js
30
30
  var index_exports = {};
31
31
  __export(index_exports, {
32
+ AnimatedForm: () => AnimatedForm,
32
33
  AvatarCard: () => AvatarCard,
33
34
  BackgoundImageSlider: () => BackgoundImageSlider,
34
35
  Charts: () => Charts,
35
36
  ColorPicker: () => ColorPicker,
37
+ EcommerceCard: () => EcommerceCard,
36
38
  FileUpload: () => FileUpload,
37
39
  Footer: () => Footer,
38
40
  ImageCard: () => ImageCard,
@@ -3575,12 +3577,197 @@ var ProgressBar = ({
3575
3577
  }
3576
3578
  return null;
3577
3579
  };
3580
+
3581
+ // src/components/EcommerceCard/EcommerceCard.jsx
3582
+ var import_react20 = __toESM(require("react"));
3583
+ var EcommerceCard = ({
3584
+ image = "https://images.unsplash.com/photo-1505740420928-5e560c06d30e?w=600&q=80",
3585
+ title = "Wireless Headphones",
3586
+ description = "Premium noise-cancelling headphones with 40 hours battery life.",
3587
+ price = 199,
3588
+ currency = "$",
3589
+ accent = "#6366f1",
3590
+ bg = "#0f172a",
3591
+ onAddToCart = () => {
3592
+ },
3593
+ onViewDetails = () => {
3594
+ }
3595
+ }) => {
3596
+ const [hovered, setHovered] = (0, import_react20.useState)(false);
3597
+ const alpha = (hex, op) => {
3598
+ const r = parseInt(hex.slice(1, 3), 16), g = parseInt(hex.slice(3, 5), 16), b = parseInt(hex.slice(5, 7), 16);
3599
+ return "rgba(" + r + "," + g + "," + b + "," + op + ")";
3600
+ };
3601
+ return /* @__PURE__ */ import_react20.default.createElement(
3602
+ "div",
3603
+ {
3604
+ onMouseEnter: () => setHovered(true),
3605
+ onMouseLeave: () => setHovered(false),
3606
+ style: {
3607
+ background: bg,
3608
+ borderRadius: "20px",
3609
+ overflow: "hidden",
3610
+ width: "300px",
3611
+ border: "1px solid " + (hovered ? alpha(accent, 0.3) : "rgba(255,255,255,0.07)"),
3612
+ fontFamily: "system-ui,sans-serif",
3613
+ transition: "transform 0.25s, box-shadow 0.25s",
3614
+ transform: hovered ? "translateY(-4px)" : "translateY(0px)",
3615
+ boxShadow: hovered ? "0 16px 40px rgba(0,0,0,0.5)" : "0 4px 20px rgba(0,0,0,0.3)"
3616
+ }
3617
+ },
3618
+ /* @__PURE__ */ import_react20.default.createElement("div", { style: { position: "relative", width: "100%", height: "200px", overflow: "hidden" } }, /* @__PURE__ */ import_react20.default.createElement("img", { src: image, alt: title, style: { width: "100%", height: "100%", objectFit: "cover", transform: hovered ? "scale(1.05)" : "scale(1)", transition: "transform 0.4s ease" } }), /* @__PURE__ */ import_react20.default.createElement("div", { style: { position: "absolute", inset: 0, background: "linear-gradient(to top, rgba(0,0,0,0.5) 0%, transparent 60%)" } })),
3619
+ /* @__PURE__ */ import_react20.default.createElement("div", { style: { padding: "18px" } }, /* @__PURE__ */ import_react20.default.createElement("h3", { style: { fontSize: "15px", fontWeight: "700", color: "#fff", margin: "0 0 8px", lineHeight: 1.4 } }, title), /* @__PURE__ */ import_react20.default.createElement("p", { style: { fontSize: "13px", color: "rgba(255,255,255,0.45)", lineHeight: 1.65, margin: "0 0 18px" } }, description), /* @__PURE__ */ import_react20.default.createElement("div", { style: { display: "flex", alignItems: "center", justifyContent: "space-between", marginBottom: "18px" } }, /* @__PURE__ */ import_react20.default.createElement("span", { style: { fontSize: "24px", fontWeight: "800", color: "#fff" } }, currency, price), /* @__PURE__ */ import_react20.default.createElement(
3620
+ "button",
3621
+ {
3622
+ onClick: onAddToCart,
3623
+ style: { padding: "8px 16px", borderRadius: "12px", border: "none", background: accent, color: "#fff", fontSize: "13px", fontWeight: "700", cursor: "pointer", fontFamily: "inherit" }
3624
+ },
3625
+ "Add to Cart"
3626
+ )), /* @__PURE__ */ import_react20.default.createElement(
3627
+ "button",
3628
+ {
3629
+ onClick: onViewDetails,
3630
+ style: { width: "100%", padding: "11px", borderRadius: "12px", border: "1px solid " + alpha(accent, 0.3), background: "transparent", color: accent, fontSize: "13px", fontWeight: "700", cursor: "pointer", fontFamily: "inherit" }
3631
+ },
3632
+ "View Details"
3633
+ ))
3634
+ );
3635
+ };
3636
+
3637
+ // src/components/AnimatedForm/AnimatedForm.jsx
3638
+ var import_react21 = __toESM(require("react"));
3639
+ var AnimatedForm = ({
3640
+ title = "Contact Us",
3641
+ description = "We'll get back to you shortly",
3642
+ submitText = "Send Message",
3643
+ accent = "#6366f1",
3644
+ bg = "#0f172a",
3645
+ onSubmit = () => {
3646
+ }
3647
+ }) => {
3648
+ const [name, setName] = (0, import_react21.useState)("");
3649
+ const [email, setEmail] = (0, import_react21.useState)("");
3650
+ const [message, setMessage] = (0, import_react21.useState)("");
3651
+ const [hovered, setHovered] = (0, import_react21.useState)(false);
3652
+ const alpha = (hex, op) => {
3653
+ const r = parseInt(hex.slice(1, 3), 16), g = parseInt(hex.slice(3, 5), 16), b = parseInt(hex.slice(5, 7), 16);
3654
+ return "rgba(" + r + "," + g + "," + b + "," + op + ")";
3655
+ };
3656
+ return /* @__PURE__ */ import_react21.default.createElement(
3657
+ "div",
3658
+ {
3659
+ onMouseEnter: () => setHovered(true),
3660
+ onMouseLeave: () => setHovered(false),
3661
+ style: {
3662
+ background: bg,
3663
+ borderRadius: "20px",
3664
+ padding: "28px",
3665
+ width: "400px",
3666
+ border: "1px solid " + (hovered ? alpha(accent, 0.3) : "rgba(255,255,255,0.07)"),
3667
+ fontFamily: "system-ui,sans-serif",
3668
+ transition: "transform 0.25s, box-shadow 0.25s",
3669
+ transform: hovered ? "translateY(-4px)" : "translateY(0px)",
3670
+ boxShadow: hovered ? "0 16px 40px rgba(0,0,0,0.5)" : "0 4px 20px rgba(0,0,0,0.3)"
3671
+ }
3672
+ },
3673
+ /* @__PURE__ */ import_react21.default.createElement("h2", { style: { fontSize: "20px", fontWeight: "700", color: "#fff", margin: "0 0 8px" } }, title),
3674
+ /* @__PURE__ */ import_react21.default.createElement("p", { style: { fontSize: "14px", color: "rgba(255,255,255,0.45)", margin: "0 0 24px" } }, description),
3675
+ /* @__PURE__ */ import_react21.default.createElement(
3676
+ "input",
3677
+ {
3678
+ type: "text",
3679
+ placeholder: "Your Name",
3680
+ value: name,
3681
+ onChange: (e) => setName(e.target.value),
3682
+ style: {
3683
+ width: "100%",
3684
+ padding: "12px",
3685
+ borderRadius: "10px",
3686
+ border: "1px solid rgba(255,255,255,0.1)",
3687
+ background: "#1e293b",
3688
+ color: "#fff",
3689
+ fontSize: "14px",
3690
+ marginBottom: "16px",
3691
+ outline: "none",
3692
+ transition: "border-color 0.2s",
3693
+ fontFamily: "inherit"
3694
+ }
3695
+ }
3696
+ ),
3697
+ /* @__PURE__ */ import_react21.default.createElement(
3698
+ "input",
3699
+ {
3700
+ type: "email",
3701
+ placeholder: "Your Email",
3702
+ value: email,
3703
+ onChange: (e) => setEmail(e.target.value),
3704
+ style: {
3705
+ width: "100%",
3706
+ padding: "12px",
3707
+ borderRadius: "10px",
3708
+ border: "1px solid rgba(255,255,255,0.1)",
3709
+ background: "#1e293b",
3710
+ color: "#fff",
3711
+ fontSize: "14px",
3712
+ marginBottom: "16px",
3713
+ outline: "none",
3714
+ transition: "border-color 0.2s",
3715
+ fontFamily: "inherit"
3716
+ }
3717
+ }
3718
+ ),
3719
+ /* @__PURE__ */ import_react21.default.createElement(
3720
+ "textarea",
3721
+ {
3722
+ placeholder: "Your Message",
3723
+ value: message,
3724
+ onChange: (e) => setMessage(e.target.value),
3725
+ style: {
3726
+ width: "100%",
3727
+ padding: "12px",
3728
+ borderRadius: "10px",
3729
+ border: "1px solid rgba(255,255,255,0.1)",
3730
+ background: "#1e293b",
3731
+ color: "#fff",
3732
+ fontSize: "14px",
3733
+ marginBottom: "24px",
3734
+ outline: "none",
3735
+ transition: "border-color 0.2s",
3736
+ fontFamily: "inherit",
3737
+ minHeight: "120px",
3738
+ resize: "vertical"
3739
+ }
3740
+ }
3741
+ ),
3742
+ /* @__PURE__ */ import_react21.default.createElement(
3743
+ "button",
3744
+ {
3745
+ onClick: () => onSubmit({ name, email, message }),
3746
+ style: {
3747
+ width: "100%",
3748
+ padding: "13px",
3749
+ borderRadius: "12px",
3750
+ border: "none",
3751
+ background: "linear-gradient(135deg, " + accent + ", " + alpha(accent, 0.7) + ")",
3752
+ color: "#fff",
3753
+ fontSize: "14px",
3754
+ fontWeight: "700",
3755
+ cursor: "pointer",
3756
+ fontFamily: "inherit"
3757
+ }
3758
+ },
3759
+ submitText
3760
+ )
3761
+ );
3762
+ };
3578
3763
  // Annotate the CommonJS export names for ESM import in node:
3579
3764
  0 && (module.exports = {
3765
+ AnimatedForm,
3580
3766
  AvatarCard,
3581
3767
  BackgoundImageSlider,
3582
3768
  Charts,
3583
3769
  ColorPicker,
3770
+ EcommerceCard,
3584
3771
  FileUpload,
3585
3772
  Footer,
3586
3773
  ImageCard,
package/dist/index.mjs CHANGED
@@ -3522,11 +3522,196 @@ var ProgressBar = ({
3522
3522
  }
3523
3523
  return null;
3524
3524
  };
3525
+
3526
+ // src/components/EcommerceCard/EcommerceCard.jsx
3527
+ import React20, { useState as useState18 } from "react";
3528
+ var EcommerceCard = ({
3529
+ image = "https://images.unsplash.com/photo-1505740420928-5e560c06d30e?w=600&q=80",
3530
+ title = "Wireless Headphones",
3531
+ description = "Premium noise-cancelling headphones with 40 hours battery life.",
3532
+ price = 199,
3533
+ currency = "$",
3534
+ accent = "#6366f1",
3535
+ bg = "#0f172a",
3536
+ onAddToCart = () => {
3537
+ },
3538
+ onViewDetails = () => {
3539
+ }
3540
+ }) => {
3541
+ const [hovered, setHovered] = useState18(false);
3542
+ const alpha = (hex, op) => {
3543
+ const r = parseInt(hex.slice(1, 3), 16), g = parseInt(hex.slice(3, 5), 16), b = parseInt(hex.slice(5, 7), 16);
3544
+ return "rgba(" + r + "," + g + "," + b + "," + op + ")";
3545
+ };
3546
+ return /* @__PURE__ */ React20.createElement(
3547
+ "div",
3548
+ {
3549
+ onMouseEnter: () => setHovered(true),
3550
+ onMouseLeave: () => setHovered(false),
3551
+ style: {
3552
+ background: bg,
3553
+ borderRadius: "20px",
3554
+ overflow: "hidden",
3555
+ width: "300px",
3556
+ border: "1px solid " + (hovered ? alpha(accent, 0.3) : "rgba(255,255,255,0.07)"),
3557
+ fontFamily: "system-ui,sans-serif",
3558
+ transition: "transform 0.25s, box-shadow 0.25s",
3559
+ transform: hovered ? "translateY(-4px)" : "translateY(0px)",
3560
+ boxShadow: hovered ? "0 16px 40px rgba(0,0,0,0.5)" : "0 4px 20px rgba(0,0,0,0.3)"
3561
+ }
3562
+ },
3563
+ /* @__PURE__ */ React20.createElement("div", { style: { position: "relative", width: "100%", height: "200px", overflow: "hidden" } }, /* @__PURE__ */ React20.createElement("img", { src: image, alt: title, style: { width: "100%", height: "100%", objectFit: "cover", transform: hovered ? "scale(1.05)" : "scale(1)", transition: "transform 0.4s ease" } }), /* @__PURE__ */ React20.createElement("div", { style: { position: "absolute", inset: 0, background: "linear-gradient(to top, rgba(0,0,0,0.5) 0%, transparent 60%)" } })),
3564
+ /* @__PURE__ */ React20.createElement("div", { style: { padding: "18px" } }, /* @__PURE__ */ React20.createElement("h3", { style: { fontSize: "15px", fontWeight: "700", color: "#fff", margin: "0 0 8px", lineHeight: 1.4 } }, title), /* @__PURE__ */ React20.createElement("p", { style: { fontSize: "13px", color: "rgba(255,255,255,0.45)", lineHeight: 1.65, margin: "0 0 18px" } }, description), /* @__PURE__ */ React20.createElement("div", { style: { display: "flex", alignItems: "center", justifyContent: "space-between", marginBottom: "18px" } }, /* @__PURE__ */ React20.createElement("span", { style: { fontSize: "24px", fontWeight: "800", color: "#fff" } }, currency, price), /* @__PURE__ */ React20.createElement(
3565
+ "button",
3566
+ {
3567
+ onClick: onAddToCart,
3568
+ style: { padding: "8px 16px", borderRadius: "12px", border: "none", background: accent, color: "#fff", fontSize: "13px", fontWeight: "700", cursor: "pointer", fontFamily: "inherit" }
3569
+ },
3570
+ "Add to Cart"
3571
+ )), /* @__PURE__ */ React20.createElement(
3572
+ "button",
3573
+ {
3574
+ onClick: onViewDetails,
3575
+ style: { width: "100%", padding: "11px", borderRadius: "12px", border: "1px solid " + alpha(accent, 0.3), background: "transparent", color: accent, fontSize: "13px", fontWeight: "700", cursor: "pointer", fontFamily: "inherit" }
3576
+ },
3577
+ "View Details"
3578
+ ))
3579
+ );
3580
+ };
3581
+
3582
+ // src/components/AnimatedForm/AnimatedForm.jsx
3583
+ import React21, { useState as useState19 } from "react";
3584
+ var AnimatedForm = ({
3585
+ title = "Contact Us",
3586
+ description = "We'll get back to you shortly",
3587
+ submitText = "Send Message",
3588
+ accent = "#6366f1",
3589
+ bg = "#0f172a",
3590
+ onSubmit = () => {
3591
+ }
3592
+ }) => {
3593
+ const [name, setName] = useState19("");
3594
+ const [email, setEmail] = useState19("");
3595
+ const [message, setMessage] = useState19("");
3596
+ const [hovered, setHovered] = useState19(false);
3597
+ const alpha = (hex, op) => {
3598
+ const r = parseInt(hex.slice(1, 3), 16), g = parseInt(hex.slice(3, 5), 16), b = parseInt(hex.slice(5, 7), 16);
3599
+ return "rgba(" + r + "," + g + "," + b + "," + op + ")";
3600
+ };
3601
+ return /* @__PURE__ */ React21.createElement(
3602
+ "div",
3603
+ {
3604
+ onMouseEnter: () => setHovered(true),
3605
+ onMouseLeave: () => setHovered(false),
3606
+ style: {
3607
+ background: bg,
3608
+ borderRadius: "20px",
3609
+ padding: "28px",
3610
+ width: "400px",
3611
+ border: "1px solid " + (hovered ? alpha(accent, 0.3) : "rgba(255,255,255,0.07)"),
3612
+ fontFamily: "system-ui,sans-serif",
3613
+ transition: "transform 0.25s, box-shadow 0.25s",
3614
+ transform: hovered ? "translateY(-4px)" : "translateY(0px)",
3615
+ boxShadow: hovered ? "0 16px 40px rgba(0,0,0,0.5)" : "0 4px 20px rgba(0,0,0,0.3)"
3616
+ }
3617
+ },
3618
+ /* @__PURE__ */ React21.createElement("h2", { style: { fontSize: "20px", fontWeight: "700", color: "#fff", margin: "0 0 8px" } }, title),
3619
+ /* @__PURE__ */ React21.createElement("p", { style: { fontSize: "14px", color: "rgba(255,255,255,0.45)", margin: "0 0 24px" } }, description),
3620
+ /* @__PURE__ */ React21.createElement(
3621
+ "input",
3622
+ {
3623
+ type: "text",
3624
+ placeholder: "Your Name",
3625
+ value: name,
3626
+ onChange: (e) => setName(e.target.value),
3627
+ style: {
3628
+ width: "100%",
3629
+ padding: "12px",
3630
+ borderRadius: "10px",
3631
+ border: "1px solid rgba(255,255,255,0.1)",
3632
+ background: "#1e293b",
3633
+ color: "#fff",
3634
+ fontSize: "14px",
3635
+ marginBottom: "16px",
3636
+ outline: "none",
3637
+ transition: "border-color 0.2s",
3638
+ fontFamily: "inherit"
3639
+ }
3640
+ }
3641
+ ),
3642
+ /* @__PURE__ */ React21.createElement(
3643
+ "input",
3644
+ {
3645
+ type: "email",
3646
+ placeholder: "Your Email",
3647
+ value: email,
3648
+ onChange: (e) => setEmail(e.target.value),
3649
+ style: {
3650
+ width: "100%",
3651
+ padding: "12px",
3652
+ borderRadius: "10px",
3653
+ border: "1px solid rgba(255,255,255,0.1)",
3654
+ background: "#1e293b",
3655
+ color: "#fff",
3656
+ fontSize: "14px",
3657
+ marginBottom: "16px",
3658
+ outline: "none",
3659
+ transition: "border-color 0.2s",
3660
+ fontFamily: "inherit"
3661
+ }
3662
+ }
3663
+ ),
3664
+ /* @__PURE__ */ React21.createElement(
3665
+ "textarea",
3666
+ {
3667
+ placeholder: "Your Message",
3668
+ value: message,
3669
+ onChange: (e) => setMessage(e.target.value),
3670
+ style: {
3671
+ width: "100%",
3672
+ padding: "12px",
3673
+ borderRadius: "10px",
3674
+ border: "1px solid rgba(255,255,255,0.1)",
3675
+ background: "#1e293b",
3676
+ color: "#fff",
3677
+ fontSize: "14px",
3678
+ marginBottom: "24px",
3679
+ outline: "none",
3680
+ transition: "border-color 0.2s",
3681
+ fontFamily: "inherit",
3682
+ minHeight: "120px",
3683
+ resize: "vertical"
3684
+ }
3685
+ }
3686
+ ),
3687
+ /* @__PURE__ */ React21.createElement(
3688
+ "button",
3689
+ {
3690
+ onClick: () => onSubmit({ name, email, message }),
3691
+ style: {
3692
+ width: "100%",
3693
+ padding: "13px",
3694
+ borderRadius: "12px",
3695
+ border: "none",
3696
+ background: "linear-gradient(135deg, " + accent + ", " + alpha(accent, 0.7) + ")",
3697
+ color: "#fff",
3698
+ fontSize: "14px",
3699
+ fontWeight: "700",
3700
+ cursor: "pointer",
3701
+ fontFamily: "inherit"
3702
+ }
3703
+ },
3704
+ submitText
3705
+ )
3706
+ );
3707
+ };
3525
3708
  export {
3709
+ AnimatedForm,
3526
3710
  AvatarCard,
3527
3711
  BackgoundImageSlider,
3528
3712
  Charts,
3529
3713
  ColorPicker,
3714
+ EcommerceCard,
3530
3715
  FileUpload,
3531
3716
  Footer,
3532
3717
  ImageCard,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "virtual-ui-lib",
3
- "version": "1.0.74",
3
+ "version": "1.0.76",
4
4
  "description": "Virtual UI React Component Library",
5
5
  "author": "Ankush",
6
6
  "license": "ISC",