@app-studio/web 0.8.90 → 0.8.92
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/components/CookieConsent/CookieConsent/CookieConsent.props.d.ts +57 -0
- package/dist/components/CookieConsent/CookieConsent/CookieConsent.state.d.ts +13 -0
- package/dist/components/CookieConsent/CookieConsent/CookieConsent.style.d.ts +68 -0
- package/dist/components/CookieConsent/CookieConsent/CookieConsent.type.d.ts +13 -0
- package/dist/components/CookieConsent/CookieConsent/CookieConsent.view.d.ts +8 -0
- package/dist/components/CookieConsent/CookieConsent.d.ts +3 -0
- package/dist/components/CookieConsent/examples/custom.d.ts +5 -0
- package/dist/components/CookieConsent/examples/default.d.ts +5 -0
- package/dist/components/CookieConsent/examples/index.d.ts +4 -0
- package/dist/components/CookieConsent/examples/positions.d.ts +5 -0
- package/dist/components/CookieConsent/examples/variants.d.ts +5 -0
- package/dist/components/Icon/Icon.d.ts +4 -1
- package/dist/components/Title/Title/Title.props.d.ts +88 -0
- package/dist/components/Title/Title/Title.state.d.ts +10 -0
- package/dist/components/Title/Title/Title.style.d.ts +25 -0
- package/dist/components/Title/Title/Title.type.d.ts +17 -0
- package/dist/components/Title/Title/Title.view.d.ts +4 -0
- package/dist/components/Title/Title/TypewriterEffect.d.ts +17 -0
- package/dist/components/Title/Title/useInView.d.ts +9 -0
- package/dist/components/Title/Title.d.ts +3 -0
- package/dist/components/Title/examples/alternating.d.ts +5 -0
- package/dist/components/Title/examples/animated.d.ts +5 -0
- package/dist/components/Title/examples/custom.d.ts +5 -0
- package/dist/components/Title/examples/default.d.ts +5 -0
- package/dist/components/Title/examples/directAnimation.d.ts +5 -0
- package/dist/components/Title/examples/gradient.d.ts +5 -0
- package/dist/components/Title/examples/hero.d.ts +5 -0
- package/dist/components/Title/examples/highlight.d.ts +5 -0
- package/dist/components/Title/examples/highlightStyles.d.ts +5 -0
- package/dist/components/Title/examples/highlighted.d.ts +5 -0
- package/dist/components/Title/examples/index.d.ts +12 -0
- package/dist/components/Title/examples/responsive.d.ts +5 -0
- package/dist/components/Title/examples/typewriterHighlight.d.ts +5 -0
- package/dist/components/Title/index.d.ts +1 -0
- package/dist/components/index.d.ts +4 -0
- package/dist/pages/cookieConsent.page.d.ts +6 -0
- package/dist/pages/title.page.d.ts +6 -0
- package/dist/web.cjs.development.js +842 -133
- package/dist/web.cjs.development.js.map +1 -1
- package/dist/web.cjs.production.min.js +1 -1
- package/dist/web.cjs.production.min.js.map +1 -1
- package/dist/web.esm.js +839 -135
- package/dist/web.esm.js.map +1 -1
- package/dist/web.umd.development.js +843 -135
- package/dist/web.umd.development.js.map +1 -1
- package/dist/web.umd.production.min.js +1 -1
- package/dist/web.umd.production.min.js.map +1 -1
- package/package.json +2 -2
|
@@ -31,6 +31,7 @@ require('core-js/modules/web.url.js');
|
|
|
31
31
|
require('core-js/modules/web.url.to-json.js');
|
|
32
32
|
require('core-js/modules/web.url-search-params.js');
|
|
33
33
|
var zustand = require('zustand');
|
|
34
|
+
require('core-js/modules/es.string.replace.js');
|
|
34
35
|
require('core-js/modules/es.string.ends-with.js');
|
|
35
36
|
require('core-js/modules/es.string.match.js');
|
|
36
37
|
require('core-js/modules/es.string.search.js');
|
|
@@ -593,7 +594,7 @@ var TruncateText = _ref2 => {
|
|
|
593
594
|
n.style.lineHeight = lineHeight;
|
|
594
595
|
}
|
|
595
596
|
}, [text, maxLines]);
|
|
596
|
-
return /*#__PURE__*/React__default.createElement(appStudio.
|
|
597
|
+
return /*#__PURE__*/React__default.createElement(appStudio.Text, Object.assign({
|
|
597
598
|
ref: containerRef,
|
|
598
599
|
overflow: "hidden" // Crucial for final display state
|
|
599
600
|
}, views == null ? void 0 : views.truncateText, rest, {
|
|
@@ -658,7 +659,7 @@ var Text = TextComponent;
|
|
|
658
659
|
|
|
659
660
|
var _excluded$3 = ["widthHeight", "color", "transform", "orientation", "children"],
|
|
660
661
|
_excluded2$2 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
661
|
-
_excluded3$1 = ["widthHeight", "color", "
|
|
662
|
+
_excluded3$1 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
662
663
|
_excluded4$1 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
663
664
|
_excluded5 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
664
665
|
_excluded6 = ["widthHeight", "color", "filled", "strokeWidth"],
|
|
@@ -732,7 +733,9 @@ var _excluded$3 = ["widthHeight", "color", "transform", "orientation", "children
|
|
|
732
733
|
_excluded74 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
733
734
|
_excluded75 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
734
735
|
_excluded76 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
735
|
-
_excluded77 = ["widthHeight", "color", "strokeWidth", "filled"]
|
|
736
|
+
_excluded77 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
737
|
+
_excluded78 = ["widthHeight", "color", "strokeWidth", "filled"],
|
|
738
|
+
_excluded79 = ["widthHeight", "color", "strokeWidth", "filled"];
|
|
736
739
|
// Default wrapper component for consistent sizing and styling
|
|
737
740
|
var IconWrapper = _ref => {
|
|
738
741
|
var {
|
|
@@ -787,8 +790,8 @@ var HelpIcon = _ref3 => {
|
|
|
787
790
|
var {
|
|
788
791
|
widthHeight = 24,
|
|
789
792
|
color = 'currentColor',
|
|
790
|
-
|
|
791
|
-
|
|
793
|
+
strokeWidth = 1,
|
|
794
|
+
filled = false
|
|
792
795
|
} = _ref3,
|
|
793
796
|
props = _objectWithoutPropertiesLoose(_ref3, _excluded3$1);
|
|
794
797
|
return /*#__PURE__*/React__default.createElement(IconWrapper, Object.assign({
|
|
@@ -796,10 +799,19 @@ var HelpIcon = _ref3 => {
|
|
|
796
799
|
color: color
|
|
797
800
|
}, props), /*#__PURE__*/React__default.createElement("svg", Object.assign({
|
|
798
801
|
viewBox: "0 0 24 24",
|
|
799
|
-
"aria-hidden": "
|
|
802
|
+
"aria-hidden": "false",
|
|
800
803
|
focusable: "false"
|
|
801
|
-
}, getSvgProps(filled, color, strokeWidth)), /*#__PURE__*/React__default.createElement("
|
|
802
|
-
|
|
804
|
+
}, getSvgProps(filled, color, strokeWidth)), /*#__PURE__*/React__default.createElement("circle", {
|
|
805
|
+
cx: "12",
|
|
806
|
+
cy: "12",
|
|
807
|
+
r: "10"
|
|
808
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
809
|
+
d: "M9.09 9a3 3 0 1 1 5.91 1c0 2-3 3-3 3"
|
|
810
|
+
}), /*#__PURE__*/React__default.createElement("line", {
|
|
811
|
+
x1: "12",
|
|
812
|
+
y1: "17",
|
|
813
|
+
x2: "12",
|
|
814
|
+
y2: "17"
|
|
803
815
|
})));
|
|
804
816
|
};
|
|
805
817
|
// Example Icon Component: ChevronIcon
|
|
@@ -1779,31 +1791,13 @@ var PanelIcon = _ref40 => {
|
|
|
1779
1791
|
"aria-hidden": "false",
|
|
1780
1792
|
focusable: "false"
|
|
1781
1793
|
}, getSvgProps(filled, color, strokeWidth)), /*#__PURE__*/React__default.createElement("rect", {
|
|
1782
|
-
x: "3",
|
|
1783
|
-
y: "3",
|
|
1784
1794
|
width: "18",
|
|
1785
1795
|
height: "18",
|
|
1796
|
+
x: "3",
|
|
1797
|
+
y: "3",
|
|
1786
1798
|
rx: "2"
|
|
1787
|
-
}), /*#__PURE__*/React__default.createElement("
|
|
1788
|
-
|
|
1789
|
-
y1: "3",
|
|
1790
|
-
x2: "9",
|
|
1791
|
-
y2: "21"
|
|
1792
|
-
}), /*#__PURE__*/React__default.createElement("line", {
|
|
1793
|
-
x1: "12",
|
|
1794
|
-
y1: "7",
|
|
1795
|
-
x2: "17",
|
|
1796
|
-
y2: "7"
|
|
1797
|
-
}), /*#__PURE__*/React__default.createElement("line", {
|
|
1798
|
-
x1: "12",
|
|
1799
|
-
y1: "11",
|
|
1800
|
-
x2: "17",
|
|
1801
|
-
y2: "11"
|
|
1802
|
-
}), /*#__PURE__*/React__default.createElement("line", {
|
|
1803
|
-
x1: "12",
|
|
1804
|
-
y1: "15",
|
|
1805
|
-
x2: "17",
|
|
1806
|
-
y2: "15"
|
|
1799
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
1800
|
+
d: "M9 3v18"
|
|
1807
1801
|
})));
|
|
1808
1802
|
};
|
|
1809
1803
|
var FilterIcon = _ref41 => {
|
|
@@ -2756,6 +2750,59 @@ var ChartIcon = _ref77 => {
|
|
|
2756
2750
|
y2: "17"
|
|
2757
2751
|
})));
|
|
2758
2752
|
};
|
|
2753
|
+
var GiftIcon = _ref78 => {
|
|
2754
|
+
var {
|
|
2755
|
+
widthHeight = 24,
|
|
2756
|
+
color = 'currentColor',
|
|
2757
|
+
strokeWidth = 1,
|
|
2758
|
+
filled = false
|
|
2759
|
+
} = _ref78,
|
|
2760
|
+
props = _objectWithoutPropertiesLoose(_ref78, _excluded78);
|
|
2761
|
+
return /*#__PURE__*/React__default.createElement(IconWrapper, Object.assign({
|
|
2762
|
+
widthHeight: widthHeight,
|
|
2763
|
+
color: color
|
|
2764
|
+
}, props), /*#__PURE__*/React__default.createElement("svg", Object.assign({
|
|
2765
|
+
viewBox: "0 0 24 24",
|
|
2766
|
+
"aria-hidden": "false",
|
|
2767
|
+
focusable: "false"
|
|
2768
|
+
}, getSvgProps(filled, color, strokeWidth)), /*#__PURE__*/React__default.createElement("rect", {
|
|
2769
|
+
x: "3",
|
|
2770
|
+
y: "8",
|
|
2771
|
+
width: "18",
|
|
2772
|
+
height: "4",
|
|
2773
|
+
rx: "1"
|
|
2774
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
2775
|
+
d: "M12 8V21"
|
|
2776
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
2777
|
+
d: "M3 12v6a3 3 0 0 0 3 3h3V12"
|
|
2778
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
2779
|
+
d: "M18 21h-3v-9h6v6a3 3 0 0 1-3 3z"
|
|
2780
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
2781
|
+
d: "M12 8c-.5-2.5-4-3-5-1.5S9 10 12 8z"
|
|
2782
|
+
}), /*#__PURE__*/React__default.createElement("path", {
|
|
2783
|
+
d: "M12 8c.5-2.5 4-3 5-1.5S15 10 12 8z"
|
|
2784
|
+
})));
|
|
2785
|
+
};
|
|
2786
|
+
var ShieldIcon = _ref79 => {
|
|
2787
|
+
var {
|
|
2788
|
+
widthHeight = 24,
|
|
2789
|
+
color = 'currentColor',
|
|
2790
|
+
strokeWidth = 1,
|
|
2791
|
+
filled = true
|
|
2792
|
+
} = _ref79,
|
|
2793
|
+
props = _objectWithoutPropertiesLoose(_ref79, _excluded79);
|
|
2794
|
+
return /*#__PURE__*/React__default.createElement(IconWrapper, Object.assign({
|
|
2795
|
+
widthHeight: widthHeight,
|
|
2796
|
+
color: color
|
|
2797
|
+
}, props), /*#__PURE__*/React__default.createElement("svg", Object.assign({
|
|
2798
|
+
viewBox: "0 0 24 24",
|
|
2799
|
+
"aria-hidden": "false",
|
|
2800
|
+
focusable: "false"
|
|
2801
|
+
}, getSvgProps(filled, color, strokeWidth)), /*#__PURE__*/React__default.createElement("path", {
|
|
2802
|
+
d: "M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z"
|
|
2803
|
+
})));
|
|
2804
|
+
};
|
|
2805
|
+
var CheckIcon = TickIcon;
|
|
2759
2806
|
|
|
2760
2807
|
var Icon = {
|
|
2761
2808
|
__proto__: null,
|
|
@@ -2835,7 +2882,10 @@ var Icon = {
|
|
|
2835
2882
|
ShapeIcon: ShapeIcon,
|
|
2836
2883
|
RotateIcon: RotateIcon,
|
|
2837
2884
|
DocumentIcon: DocumentIcon,
|
|
2838
|
-
ChartIcon: ChartIcon
|
|
2885
|
+
ChartIcon: ChartIcon,
|
|
2886
|
+
GiftIcon: GiftIcon,
|
|
2887
|
+
ShieldIcon: ShieldIcon,
|
|
2888
|
+
CheckIcon: CheckIcon
|
|
2839
2889
|
};
|
|
2840
2890
|
|
|
2841
2891
|
/**
|
|
@@ -5581,6 +5631,273 @@ var ChartComponent = props => {
|
|
|
5581
5631
|
};
|
|
5582
5632
|
var Chart = ChartComponent;
|
|
5583
5633
|
|
|
5634
|
+
/**
|
|
5635
|
+
* Custom hook to manage cookie consent state
|
|
5636
|
+
* @param cookieExpiration Number of days until the cookie expires
|
|
5637
|
+
* @returns State and functions for managing cookie consent
|
|
5638
|
+
*/
|
|
5639
|
+
var useCookieConsentState = function useCookieConsentState(cookieExpiration) {
|
|
5640
|
+
if (cookieExpiration === void 0) {
|
|
5641
|
+
cookieExpiration = 365;
|
|
5642
|
+
}
|
|
5643
|
+
// State for hover effects
|
|
5644
|
+
var [isHovered, setIsHovered] = React.useState(false);
|
|
5645
|
+
// State for tracking if consent has been given
|
|
5646
|
+
var [hasConsent, setHasConsent] = React.useState(null);
|
|
5647
|
+
// Cookie name for storing consent
|
|
5648
|
+
var COOKIE_CONSENT_KEY = 'app-studio-cookie-consent';
|
|
5649
|
+
// Check for existing consent when component mounts
|
|
5650
|
+
React.useEffect(() => {
|
|
5651
|
+
var storedConsent = localStorage.getItem(COOKIE_CONSENT_KEY);
|
|
5652
|
+
if (storedConsent !== null) {
|
|
5653
|
+
setHasConsent(storedConsent === 'true');
|
|
5654
|
+
} else {
|
|
5655
|
+
setHasConsent(false);
|
|
5656
|
+
}
|
|
5657
|
+
}, []);
|
|
5658
|
+
/**
|
|
5659
|
+
* Save consent to localStorage with expiration
|
|
5660
|
+
*/
|
|
5661
|
+
var saveConsent = consent => {
|
|
5662
|
+
localStorage.setItem(COOKIE_CONSENT_KEY, String(consent));
|
|
5663
|
+
// Set expiration date
|
|
5664
|
+
var expirationDate = new Date();
|
|
5665
|
+
expirationDate.setDate(expirationDate.getDate() + cookieExpiration);
|
|
5666
|
+
localStorage.setItem(COOKIE_CONSENT_KEY + "-expires", expirationDate.toISOString());
|
|
5667
|
+
setHasConsent(consent);
|
|
5668
|
+
};
|
|
5669
|
+
/**
|
|
5670
|
+
* Accept cookies
|
|
5671
|
+
*/
|
|
5672
|
+
var acceptCookies = () => {
|
|
5673
|
+
saveConsent(true);
|
|
5674
|
+
};
|
|
5675
|
+
/**
|
|
5676
|
+
* Reset cookie consent (for testing)
|
|
5677
|
+
*/
|
|
5678
|
+
var resetConsent = () => {
|
|
5679
|
+
localStorage.removeItem(COOKIE_CONSENT_KEY);
|
|
5680
|
+
localStorage.removeItem(COOKIE_CONSENT_KEY + "-expires");
|
|
5681
|
+
setHasConsent(false);
|
|
5682
|
+
};
|
|
5683
|
+
return {
|
|
5684
|
+
isHovered,
|
|
5685
|
+
setIsHovered,
|
|
5686
|
+
hasConsent,
|
|
5687
|
+
acceptCookies,
|
|
5688
|
+
resetConsent
|
|
5689
|
+
};
|
|
5690
|
+
};
|
|
5691
|
+
|
|
5692
|
+
/**
|
|
5693
|
+
* Get theme-based styles for the CookieConsent component
|
|
5694
|
+
*/
|
|
5695
|
+
var getThemes$1 = themeMode => {
|
|
5696
|
+
var isDark = themeMode === 'dark';
|
|
5697
|
+
return {
|
|
5698
|
+
default: {
|
|
5699
|
+
container: {
|
|
5700
|
+
backgroundColor: isDark ? '#1f2937' : '#ffffff',
|
|
5701
|
+
borderColor: isDark ? '#374151' : '#e5e7eb',
|
|
5702
|
+
boxShadow: '0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06)'
|
|
5703
|
+
},
|
|
5704
|
+
content: {
|
|
5705
|
+
color: isDark ? '#e5e7eb' : '#1f2937'
|
|
5706
|
+
},
|
|
5707
|
+
acceptButton: {
|
|
5708
|
+
backgroundColor: '#3b82f6',
|
|
5709
|
+
color: '#ffffff',
|
|
5710
|
+
hoverBackgroundColor: '#2563eb'
|
|
5711
|
+
},
|
|
5712
|
+
customizeButton: {
|
|
5713
|
+
backgroundColor: 'transparent',
|
|
5714
|
+
color: isDark ? '#e5e7eb' : '#4b5563',
|
|
5715
|
+
borderColor: isDark ? '#4b5563' : '#d1d5db',
|
|
5716
|
+
hoverBackgroundColor: isDark ? '#374151' : '#f3f4f6'
|
|
5717
|
+
}
|
|
5718
|
+
},
|
|
5719
|
+
info: {
|
|
5720
|
+
container: {
|
|
5721
|
+
backgroundColor: isDark ? '#1e3a8a' : '#eff6ff',
|
|
5722
|
+
borderColor: isDark ? '#1e40af' : '#bfdbfe',
|
|
5723
|
+
boxShadow: '0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06)'
|
|
5724
|
+
},
|
|
5725
|
+
content: {
|
|
5726
|
+
color: isDark ? '#bfdbfe' : '#1e40af'
|
|
5727
|
+
},
|
|
5728
|
+
acceptButton: {
|
|
5729
|
+
backgroundColor: '#3b82f6',
|
|
5730
|
+
color: '#ffffff',
|
|
5731
|
+
hoverBackgroundColor: '#2563eb'
|
|
5732
|
+
},
|
|
5733
|
+
customizeButton: {
|
|
5734
|
+
backgroundColor: 'transparent',
|
|
5735
|
+
color: isDark ? '#bfdbfe' : '#1e40af',
|
|
5736
|
+
borderColor: isDark ? '#3b82f6' : '#93c5fd',
|
|
5737
|
+
hoverBackgroundColor: isDark ? '#1e40af' : '#dbeafe'
|
|
5738
|
+
}
|
|
5739
|
+
},
|
|
5740
|
+
primary: {
|
|
5741
|
+
container: {
|
|
5742
|
+
backgroundColor: isDark ? '#0c4a6e' : '#f0f9ff',
|
|
5743
|
+
borderColor: isDark ? '#0369a1' : '#bae6fd',
|
|
5744
|
+
boxShadow: '0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06)'
|
|
5745
|
+
},
|
|
5746
|
+
content: {
|
|
5747
|
+
color: isDark ? '#bae6fd' : '#0369a1'
|
|
5748
|
+
},
|
|
5749
|
+
acceptButton: {
|
|
5750
|
+
backgroundColor: '#0ea5e9',
|
|
5751
|
+
color: '#ffffff',
|
|
5752
|
+
hoverBackgroundColor: '#0284c7'
|
|
5753
|
+
},
|
|
5754
|
+
customizeButton: {
|
|
5755
|
+
backgroundColor: 'transparent',
|
|
5756
|
+
color: isDark ? '#bae6fd' : '#0369a1',
|
|
5757
|
+
borderColor: isDark ? '#0ea5e9' : '#7dd3fc',
|
|
5758
|
+
hoverBackgroundColor: isDark ? '#0369a1' : '#e0f2fe'
|
|
5759
|
+
}
|
|
5760
|
+
}
|
|
5761
|
+
};
|
|
5762
|
+
};
|
|
5763
|
+
|
|
5764
|
+
var _excluded$e = ["title", "description", "acceptButtonText", "customizeButtonText", "position", "variant", "onAccept", "onCustomize", "views", "showCustomizeButton", "cookieExpiration", "themeMode"];
|
|
5765
|
+
/**
|
|
5766
|
+
* CookieConsent View Component
|
|
5767
|
+
*
|
|
5768
|
+
* Renders a cookie consent banner with customizable styling, position, and content.
|
|
5769
|
+
*/
|
|
5770
|
+
var CookieConsentView = _ref => {
|
|
5771
|
+
var {
|
|
5772
|
+
title = 'Nous utilisons des cookies',
|
|
5773
|
+
description = 'Ce site utilise des cookies pour améliorer votre expérience. En continuant à naviguer sur ce site, vous acceptez notre utilisation des cookies conformément à notre politique de confidentialité.',
|
|
5774
|
+
acceptButtonText = 'Accepter',
|
|
5775
|
+
customizeButtonText = 'Personnaliser',
|
|
5776
|
+
position = 'bottom',
|
|
5777
|
+
variant = 'default',
|
|
5778
|
+
onAccept,
|
|
5779
|
+
onCustomize,
|
|
5780
|
+
views,
|
|
5781
|
+
showCustomizeButton = true,
|
|
5782
|
+
cookieExpiration = 365,
|
|
5783
|
+
themeMode: propThemeMode
|
|
5784
|
+
} = _ref,
|
|
5785
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$e);
|
|
5786
|
+
// Get theme context
|
|
5787
|
+
var {
|
|
5788
|
+
themeMode: contextThemeMode
|
|
5789
|
+
} = appStudio.useTheme();
|
|
5790
|
+
// Use provided theme mode or fall back to context
|
|
5791
|
+
var themeMode = propThemeMode || contextThemeMode || 'light';
|
|
5792
|
+
// Get state and functions from custom hook
|
|
5793
|
+
var {
|
|
5794
|
+
hasConsent,
|
|
5795
|
+
acceptCookies
|
|
5796
|
+
} = useCookieConsentState(cookieExpiration);
|
|
5797
|
+
// Get theme-based styles
|
|
5798
|
+
var themes = getThemes$1(themeMode);
|
|
5799
|
+
var themeStyles = themes[variant];
|
|
5800
|
+
// If user has already given consent, don't show the banner
|
|
5801
|
+
if (hasConsent) {
|
|
5802
|
+
return null;
|
|
5803
|
+
}
|
|
5804
|
+
// Handle accept button click
|
|
5805
|
+
var handleAccept = () => {
|
|
5806
|
+
acceptCookies();
|
|
5807
|
+
if (onAccept) {
|
|
5808
|
+
onAccept();
|
|
5809
|
+
}
|
|
5810
|
+
};
|
|
5811
|
+
// Handle customize button click
|
|
5812
|
+
var handleCustomize = () => {
|
|
5813
|
+
if (onCustomize) {
|
|
5814
|
+
onCustomize();
|
|
5815
|
+
}
|
|
5816
|
+
};
|
|
5817
|
+
return /*#__PURE__*/React__default.createElement(appStudio.View, Object.assign({
|
|
5818
|
+
position: "fixed",
|
|
5819
|
+
left: 16,
|
|
5820
|
+
right: 16,
|
|
5821
|
+
zIndex: 1000,
|
|
5822
|
+
padding: 16,
|
|
5823
|
+
borderWidth: "1px",
|
|
5824
|
+
borderStyle: "solid",
|
|
5825
|
+
borderRadius: 8,
|
|
5826
|
+
maxWidth: "800px",
|
|
5827
|
+
marginX: "auto"
|
|
5828
|
+
}, position === 'bottom' ? {
|
|
5829
|
+
bottom: 16
|
|
5830
|
+
} : {
|
|
5831
|
+
top: 16
|
|
5832
|
+
}, themeStyles.container, views == null ? void 0 : views.container, props), /*#__PURE__*/React__default.createElement(appStudio.Vertical, {
|
|
5833
|
+
gap: 12,
|
|
5834
|
+
maxWidth: 1200,
|
|
5835
|
+
marginX: "auto"
|
|
5836
|
+
}, title && (/*#__PURE__*/React__default.createElement(appStudio.Text, Object.assign({
|
|
5837
|
+
fontWeight: "bold",
|
|
5838
|
+
fontSize: 18,
|
|
5839
|
+
color: "color.black"
|
|
5840
|
+
}, views == null ? void 0 : views.title), title)), description && (/*#__PURE__*/React__default.createElement(appStudio.Text, Object.assign({
|
|
5841
|
+
fontSize: 14,
|
|
5842
|
+
color: "color.black"
|
|
5843
|
+
}, views == null ? void 0 : views.description), typeof description === 'string' ? description : description)), /*#__PURE__*/React__default.createElement(appStudio.Horizontal, Object.assign({
|
|
5844
|
+
gap: 12,
|
|
5845
|
+
justifyContent: "flex-end",
|
|
5846
|
+
marginTop: 8
|
|
5847
|
+
}, views == null ? void 0 : views.buttonGroup), showCustomizeButton && (/*#__PURE__*/React__default.createElement(Button, Object.assign({
|
|
5848
|
+
variant: "outline",
|
|
5849
|
+
onClick: handleCustomize,
|
|
5850
|
+
size: "sm"
|
|
5851
|
+
}, views == null ? void 0 : views.customizeButton), customizeButtonText)), /*#__PURE__*/React__default.createElement(Button, Object.assign({
|
|
5852
|
+
variant: "primary",
|
|
5853
|
+
onClick: handleAccept,
|
|
5854
|
+
size: "sm"
|
|
5855
|
+
}, views == null ? void 0 : views.acceptButton), acceptButtonText))));
|
|
5856
|
+
};
|
|
5857
|
+
|
|
5858
|
+
/**
|
|
5859
|
+
* CookieConsent Component
|
|
5860
|
+
*
|
|
5861
|
+
* A component for displaying a cookie consent banner with customizable styling and content.
|
|
5862
|
+
*
|
|
5863
|
+
* Features:
|
|
5864
|
+
* - Customizable title and description
|
|
5865
|
+
* - Configurable button text
|
|
5866
|
+
* - Multiple visual variants
|
|
5867
|
+
* - Position control (top or bottom)
|
|
5868
|
+
* - Theme mode support (light or dark)
|
|
5869
|
+
* - Custom styling via views prop
|
|
5870
|
+
*
|
|
5871
|
+
* @example
|
|
5872
|
+
* // Basic usage
|
|
5873
|
+
* <CookieConsent />
|
|
5874
|
+
*
|
|
5875
|
+
* @example
|
|
5876
|
+
* // With custom text
|
|
5877
|
+
* <CookieConsent
|
|
5878
|
+
* title="Avis de confidentialité"
|
|
5879
|
+
* description="Nous utilisons des cookies pour améliorer votre expérience."
|
|
5880
|
+
* acceptButtonText="J'accepte"
|
|
5881
|
+
* />
|
|
5882
|
+
*
|
|
5883
|
+
* @example
|
|
5884
|
+
* // With custom styling and callbacks
|
|
5885
|
+
* <CookieConsent
|
|
5886
|
+
* variant="primary"
|
|
5887
|
+
* position="top"
|
|
5888
|
+
* onAccept={() => console.log('Cookies accepted')}
|
|
5889
|
+
* onCustomize={() => openPreferencesModal()}
|
|
5890
|
+
* views={{
|
|
5891
|
+
* container: { backgroundColor: 'color.blue.50' },
|
|
5892
|
+
* title: { color: 'color.blue.800' }
|
|
5893
|
+
* }}
|
|
5894
|
+
* />
|
|
5895
|
+
*/
|
|
5896
|
+
var CookieConsentComponent = props => {
|
|
5897
|
+
return /*#__PURE__*/React__default.createElement(CookieConsentView, Object.assign({}, props));
|
|
5898
|
+
};
|
|
5899
|
+
var CookieConsent = CookieConsentComponent;
|
|
5900
|
+
|
|
5584
5901
|
var useContextMenuState = props => {
|
|
5585
5902
|
var {
|
|
5586
5903
|
size,
|
|
@@ -5758,7 +6075,7 @@ var calculateMenuPosition = function calculateMenuPosition(x, y, menuWidth, menu
|
|
|
5758
6075
|
};
|
|
5759
6076
|
};
|
|
5760
6077
|
|
|
5761
|
-
var _excluded$
|
|
6078
|
+
var _excluded$f = ["children", "disableNativeContextMenu", "asChild", "isDisabled", "views"],
|
|
5762
6079
|
_excluded2$6 = ["items", "children", "position", "side", "align", "views", "style"],
|
|
5763
6080
|
_excluded3$5 = ["item", "children", "onSelect", "isDisabled", "views"],
|
|
5764
6081
|
_excluded4$5 = ["views"],
|
|
@@ -5814,7 +6131,7 @@ var ContextMenuTrigger = _ref2 => {
|
|
|
5814
6131
|
isDisabled = false,
|
|
5815
6132
|
views
|
|
5816
6133
|
} = _ref2,
|
|
5817
|
-
props = _objectWithoutPropertiesLoose(_ref2, _excluded$
|
|
6134
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$f);
|
|
5818
6135
|
var {
|
|
5819
6136
|
triggerRef,
|
|
5820
6137
|
contentId,
|
|
@@ -6097,7 +6414,7 @@ var ContextMenuView = _ref7 => {
|
|
|
6097
6414
|
}));
|
|
6098
6415
|
};
|
|
6099
6416
|
|
|
6100
|
-
var _excluded$
|
|
6417
|
+
var _excluded$g = ["children", "items", "size", "variant", "disableNativeContextMenu", "onOpenChange", "views"];
|
|
6101
6418
|
/**
|
|
6102
6419
|
* ContextMenu component for displaying a custom context menu on right-click.
|
|
6103
6420
|
* Supports both data-driven approach (with items prop) and compound component pattern.
|
|
@@ -6112,7 +6429,7 @@ var ContextMenuComponent = _ref => {
|
|
|
6112
6429
|
onOpenChange,
|
|
6113
6430
|
views
|
|
6114
6431
|
} = _ref,
|
|
6115
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
6432
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$g);
|
|
6116
6433
|
var state = useContextMenuState({
|
|
6117
6434
|
size,
|
|
6118
6435
|
variant,
|
|
@@ -6164,7 +6481,7 @@ ContextMenu.Item = ContextMenuItem;
|
|
|
6164
6481
|
ContextMenu.Divider = ContextMenuDivider;
|
|
6165
6482
|
ContextMenu.Separator = ContextMenuSeparator; // Add the Separator component
|
|
6166
6483
|
|
|
6167
|
-
var _excluded$
|
|
6484
|
+
var _excluded$h = ["src", "color", "views", "themeMode"],
|
|
6168
6485
|
_excluded2$7 = ["path"];
|
|
6169
6486
|
var FileSVG = _ref => {
|
|
6170
6487
|
var {
|
|
@@ -6172,7 +6489,7 @@ var FileSVG = _ref => {
|
|
|
6172
6489
|
color,
|
|
6173
6490
|
views
|
|
6174
6491
|
} = _ref,
|
|
6175
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
6492
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$h);
|
|
6176
6493
|
var {
|
|
6177
6494
|
getColor,
|
|
6178
6495
|
themeMode
|
|
@@ -6246,7 +6563,7 @@ var useItemState = () => {
|
|
|
6246
6563
|
};
|
|
6247
6564
|
};
|
|
6248
6565
|
|
|
6249
|
-
var _excluded$
|
|
6566
|
+
var _excluded$i = ["children", "views"];
|
|
6250
6567
|
var HelperText = _ref => {
|
|
6251
6568
|
var {
|
|
6252
6569
|
children,
|
|
@@ -6254,7 +6571,7 @@ var HelperText = _ref => {
|
|
|
6254
6571
|
helperText: {}
|
|
6255
6572
|
}
|
|
6256
6573
|
} = _ref,
|
|
6257
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
6574
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$i);
|
|
6258
6575
|
return /*#__PURE__*/React__default.createElement(Text
|
|
6259
6576
|
// Typography properties
|
|
6260
6577
|
, Object.assign({
|
|
@@ -6280,7 +6597,7 @@ var HelperText = _ref => {
|
|
|
6280
6597
|
}, views['helperText'], props), children);
|
|
6281
6598
|
};
|
|
6282
6599
|
|
|
6283
|
-
var _excluded$
|
|
6600
|
+
var _excluded$j = ["children", "helperText", "error", "views"];
|
|
6284
6601
|
var FieldContainer = _ref => {
|
|
6285
6602
|
var {
|
|
6286
6603
|
children,
|
|
@@ -6288,7 +6605,7 @@ var FieldContainer = _ref => {
|
|
|
6288
6605
|
error = false,
|
|
6289
6606
|
views
|
|
6290
6607
|
} = _ref,
|
|
6291
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
6608
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$j);
|
|
6292
6609
|
return /*#__PURE__*/React__default.createElement(appStudio.Vertical
|
|
6293
6610
|
// Layout properties
|
|
6294
6611
|
, Object.assign({
|
|
@@ -6404,7 +6721,7 @@ var PaddingWithoutLabel = {
|
|
|
6404
6721
|
paddingRight: '16px'
|
|
6405
6722
|
};
|
|
6406
6723
|
|
|
6407
|
-
var _excluded$
|
|
6724
|
+
var _excluded$k = ["label", "shadow", "children", "value", "size", "shape", "variant", "error", "showLabel", "isFocused", "isHovered", "isDisabled", "isReadOnly", "views"];
|
|
6408
6725
|
var FieldContent = _ref => {
|
|
6409
6726
|
var {
|
|
6410
6727
|
shadow,
|
|
@@ -6422,7 +6739,7 @@ var FieldContent = _ref => {
|
|
|
6422
6739
|
pickerBox: {}
|
|
6423
6740
|
}
|
|
6424
6741
|
} = _ref,
|
|
6425
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
6742
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$k);
|
|
6426
6743
|
// Determine if the field is in an interactive state
|
|
6427
6744
|
var isInteractive = (isHovered || isFocused) && !isDisabled;
|
|
6428
6745
|
// Set the appropriate color based on state
|
|
@@ -6451,12 +6768,12 @@ var FieldContent = _ref => {
|
|
|
6451
6768
|
}, showLabel ? PadddingWithLabel : PaddingWithoutLabel, shadow, Shapes[shape], InputVariants[variant], views['box'], props), children);
|
|
6452
6769
|
};
|
|
6453
6770
|
|
|
6454
|
-
var _excluded$
|
|
6771
|
+
var _excluded$l = ["children"];
|
|
6455
6772
|
var FieldIcons = _ref => {
|
|
6456
6773
|
var {
|
|
6457
6774
|
children
|
|
6458
6775
|
} = _ref,
|
|
6459
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
6776
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$l);
|
|
6460
6777
|
return /*#__PURE__*/React__default.createElement(appStudio.Center, Object.assign({
|
|
6461
6778
|
gap: 10,
|
|
6462
6779
|
right: 16,
|
|
@@ -6508,7 +6825,7 @@ var HeadingSizes$1 = {
|
|
|
6508
6825
|
}
|
|
6509
6826
|
};
|
|
6510
6827
|
|
|
6511
|
-
var _excluded$
|
|
6828
|
+
var _excluded$m = ["children", "heading", "isItalic", "isUnderlined", "isStriked", "weight", "size", "dropDown"];
|
|
6512
6829
|
var LabelView = _ref => {
|
|
6513
6830
|
var {
|
|
6514
6831
|
children,
|
|
@@ -6524,7 +6841,7 @@ var LabelView = _ref => {
|
|
|
6524
6841
|
size = 'sm'
|
|
6525
6842
|
// The fontSize prop for the Element is determined by the 'size' prop passed to LabelView.
|
|
6526
6843
|
} = _ref,
|
|
6527
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
6844
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$m);
|
|
6528
6845
|
// The fontStyle prop toggles between 'italic' and 'normal' based on the 'isItalic' boolean prop.
|
|
6529
6846
|
var headingStyles = heading ? HeadingSizes$1[heading] : {};
|
|
6530
6847
|
// fontWeight is derived from the Typography module, ensuring consistent font weighting across the app.
|
|
@@ -6556,7 +6873,7 @@ React__default.createElement(LabelView, Object.assign({}, props))
|
|
|
6556
6873
|
var Label = LabelComponent;
|
|
6557
6874
|
// Export the 'LabelComponent' as 'Label' to be reused throughout the project.
|
|
6558
6875
|
|
|
6559
|
-
var _excluded$
|
|
6876
|
+
var _excluded$n = ["children", "size", "error", "color", "views", "helperText"];
|
|
6560
6877
|
var FieldLabel = _ref => {
|
|
6561
6878
|
var {
|
|
6562
6879
|
children,
|
|
@@ -6567,7 +6884,7 @@ var FieldLabel = _ref => {
|
|
|
6567
6884
|
label: {}
|
|
6568
6885
|
}
|
|
6569
6886
|
} = _ref,
|
|
6570
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
6887
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$n);
|
|
6571
6888
|
return /*#__PURE__*/React__default.createElement(Label
|
|
6572
6889
|
// Position properties
|
|
6573
6890
|
, Object.assign({
|
|
@@ -6588,12 +6905,12 @@ var FieldLabel = _ref => {
|
|
|
6588
6905
|
}, views['label'], props), children);
|
|
6589
6906
|
};
|
|
6590
6907
|
|
|
6591
|
-
var _excluded$
|
|
6908
|
+
var _excluded$o = ["children"];
|
|
6592
6909
|
var FieldWrapper = _ref => {
|
|
6593
6910
|
var {
|
|
6594
6911
|
children
|
|
6595
6912
|
} = _ref,
|
|
6596
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
6913
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$o);
|
|
6597
6914
|
return /*#__PURE__*/React__default.createElement(appStudio.Vertical
|
|
6598
6915
|
// Layout properties
|
|
6599
6916
|
, Object.assign({
|
|
@@ -6626,7 +6943,7 @@ var IconSizes$2 = {
|
|
|
6626
6943
|
xl: 28
|
|
6627
6944
|
};
|
|
6628
6945
|
|
|
6629
|
-
var _excluded$
|
|
6946
|
+
var _excluded$p = ["isHovered", "setIsHovered", "option", "size", "callback", "style"],
|
|
6630
6947
|
_excluded2$8 = ["id", "name", "value", "onChange", "isMulti", "isDisabled", "isReadOnly", "options"],
|
|
6631
6948
|
_excluded3$6 = ["option", "size", "removeOption"],
|
|
6632
6949
|
_excluded4$6 = ["id", "name", "label", "value", "placeholder", "helperText", "hide", "error", "isMulti", "isFocused", "isHovered", "isDisabled", "isReadOnly", "options", "shadow", "size", "shape", "variant", "views", "onChange", "setHide", "setValue", "setIsHovered", "setIsFocused", "setHighlightedIndex", "highlightedIndex"];
|
|
@@ -6644,7 +6961,7 @@ var Item = _ref => {
|
|
|
6644
6961
|
callback = () => {},
|
|
6645
6962
|
style
|
|
6646
6963
|
} = _ref,
|
|
6647
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
6964
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$p);
|
|
6648
6965
|
// Handles the click event on an option by invoking the callback with the selected option's value
|
|
6649
6966
|
var handleOptionClick = option => callback(option);
|
|
6650
6967
|
// Toggles the hover state on the item
|
|
@@ -7137,7 +7454,7 @@ var ColorSchemes = {
|
|
|
7137
7454
|
}
|
|
7138
7455
|
};
|
|
7139
7456
|
|
|
7140
|
-
var _excluded$
|
|
7457
|
+
var _excluded$q = ["id", "name", "label", "inActiveChild", "isChecked", "activeChild", "labelPosition", "shadow", "size", "value", "isHovered", "isDisabled", "isReadOnly", "on", "setOn", "onChange", "setValue", "setIsHovered", "helperText", "views"];
|
|
7141
7458
|
var SwitchContent = props => /*#__PURE__*/React__default.createElement(appStudio.Input, Object.assign({
|
|
7142
7459
|
type: "checkbox"
|
|
7143
7460
|
}, props));
|
|
@@ -7166,7 +7483,7 @@ var SwitchView = _ref => {
|
|
|
7166
7483
|
label: {}
|
|
7167
7484
|
}
|
|
7168
7485
|
} = _ref,
|
|
7169
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
7486
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$q);
|
|
7170
7487
|
var handleToggle = event => {
|
|
7171
7488
|
if (!isReadOnly) {
|
|
7172
7489
|
setValue(!value);
|
|
@@ -7290,7 +7607,7 @@ var useTextAreaState = _ref => {
|
|
|
7290
7607
|
// Export of the useTextAreaState hook for external usage.
|
|
7291
7608
|
};
|
|
7292
7609
|
|
|
7293
|
-
var _excluded$
|
|
7610
|
+
var _excluded$r = ["id", "name", "hint", "error", "value", "label", "shadow", "helperText", "placeholder", "size", "shape", "variant", "isHovered", "isFocused", "isEditable", "isReadOnly", "isDisabled", "isAutoFocus", "isMultiline", "maxRows", "maxCols", "onBlur", "onChange", "onFocus", "setHint", "setValue", "setIsFocused", "setIsHovered", "views"];
|
|
7294
7611
|
var TextAreaView = _ref => {
|
|
7295
7612
|
var {
|
|
7296
7613
|
id,
|
|
@@ -7325,7 +7642,7 @@ var TextAreaView = _ref => {
|
|
|
7325
7642
|
helperText: {}
|
|
7326
7643
|
}
|
|
7327
7644
|
} = _ref,
|
|
7328
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
7645
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$r);
|
|
7329
7646
|
var showLabel = !!(isFocused && label);
|
|
7330
7647
|
/**
|
|
7331
7648
|
* Styles for the textarea field
|
|
@@ -7464,7 +7781,7 @@ var useTextFieldState = _ref => {
|
|
|
7464
7781
|
};
|
|
7465
7782
|
};
|
|
7466
7783
|
|
|
7467
|
-
var _excluded$
|
|
7784
|
+
var _excluded$s = ["id", "name", "label", "hint", "value", "onChange", "left", "right", "helperText", "placeholder", "onChangeText", "shadow", "views", "size", "shape", "variant", "error", "isFocused", "isHovered", "isDisabled", "isReadOnly", "isClearable", "isAutoFocus", "setHint", "setIsFocused", "setIsHovered", "setValue", "onClick", "onFocus", "onBlur", "themeMode"];
|
|
7468
7785
|
/**
|
|
7469
7786
|
* Input component for text fields
|
|
7470
7787
|
*/
|
|
@@ -7510,7 +7827,7 @@ var TextFieldView = _ref => {
|
|
|
7510
7827
|
onBlur = () => {},
|
|
7511
7828
|
themeMode: elementMode
|
|
7512
7829
|
} = _ref,
|
|
7513
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
7830
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$s);
|
|
7514
7831
|
var {
|
|
7515
7832
|
getColor,
|
|
7516
7833
|
themeMode
|
|
@@ -7766,7 +8083,7 @@ var StateStyles = {
|
|
|
7766
8083
|
}
|
|
7767
8084
|
};
|
|
7768
8085
|
|
|
7769
|
-
var _excluded$
|
|
8086
|
+
var _excluded$t = ["id", "icon", "name", "label", "isChecked", "onChange", "onValueChange", "shadow", "labelPosition", "size", "error", "isSelected", "isHovered", "isDisabled", "isReadOnly", "isIndeterminate", "defaultIsSelected", "setIsSelected", "setIsHovered", "views", "infoText", "helperText"];
|
|
7770
8087
|
var CheckboxView = _ref => {
|
|
7771
8088
|
var {
|
|
7772
8089
|
id,
|
|
@@ -7793,7 +8110,7 @@ var CheckboxView = _ref => {
|
|
|
7793
8110
|
},
|
|
7794
8111
|
infoText
|
|
7795
8112
|
} = _ref,
|
|
7796
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
8113
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$t);
|
|
7797
8114
|
var handleHover = () => setIsHovered(!isHovered);
|
|
7798
8115
|
var handleChange = () => {
|
|
7799
8116
|
if (!isReadOnly && !isDisabled) {
|
|
@@ -9379,11 +9696,11 @@ var IconSizes$4 = {
|
|
|
9379
9696
|
xl: 16
|
|
9380
9697
|
};
|
|
9381
9698
|
|
|
9382
|
-
var _excluded$
|
|
9699
|
+
var _excluded$u = ["size"],
|
|
9383
9700
|
_excluded2$9 = ["size"],
|
|
9384
9701
|
_excluded3$7 = ["id", "name", "label", "value", "placeholder", "helperText", "hide", "error", "isHovered", "isFocused", "isAutoFocus", "isDisabled", "isReadOnly", "shadow", "newOptions", "size", "variant", "shape", "onChange", "onBlur", "setHide", "setNewOptions", "setIsHovered", "setIsFocused", "setValue", "views", "themeMode"];
|
|
9385
9702
|
var CountryList = _ref => {
|
|
9386
|
-
var props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
9703
|
+
var props = _objectWithoutPropertiesLoose(_ref, _excluded$u);
|
|
9387
9704
|
return /*#__PURE__*/React__default.createElement(appStudio.Element, Object.assign({
|
|
9388
9705
|
as: "ul"
|
|
9389
9706
|
}, props));
|
|
@@ -9624,7 +9941,7 @@ var useDatePickerState = () => {
|
|
|
9624
9941
|
};
|
|
9625
9942
|
};
|
|
9626
9943
|
|
|
9627
|
-
var _excluded$
|
|
9944
|
+
var _excluded$v = ["id", "icon", "name", "label", "date", "children", "helperText", "shadow", "size", "variant", "shape", "views", "error", "isHovered", "isFocused", "isDisabled", "isReadOnly", "setDate", "setIsFocused", "setIsHovered", "onChange", "onChangeText"];
|
|
9628
9945
|
var DatePickerContent = props => /*#__PURE__*/React__default.createElement(appStudio.Input, Object.assign({
|
|
9629
9946
|
type: "date"
|
|
9630
9947
|
}, props));
|
|
@@ -9657,7 +9974,7 @@ var DatePickerView = _ref => {
|
|
|
9657
9974
|
onChange,
|
|
9658
9975
|
onChangeText
|
|
9659
9976
|
} = _ref,
|
|
9660
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
9977
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$v);
|
|
9661
9978
|
var showLabel = !!(isFocused && label);
|
|
9662
9979
|
var handleHover = () => setIsHovered(!isHovered);
|
|
9663
9980
|
var handleFocus = () => setIsFocused(true);
|
|
@@ -9744,7 +10061,7 @@ var usePasswordState = props => {
|
|
|
9744
10061
|
}, props, textFieldStates);
|
|
9745
10062
|
};
|
|
9746
10063
|
|
|
9747
|
-
var _excluded$
|
|
10064
|
+
var _excluded$w = ["visibleIcon", "hiddenIcon"],
|
|
9748
10065
|
_excluded2$a = ["isVisible", "setIsVisible"];
|
|
9749
10066
|
var PasswordComponent = _ref => {
|
|
9750
10067
|
var {
|
|
@@ -9755,7 +10072,7 @@ var PasswordComponent = _ref => {
|
|
|
9755
10072
|
widthHeight: 14
|
|
9756
10073
|
})
|
|
9757
10074
|
} = _ref,
|
|
9758
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
10075
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$w);
|
|
9759
10076
|
var _usePasswordState = usePasswordState(props),
|
|
9760
10077
|
{
|
|
9761
10078
|
isVisible,
|
|
@@ -9809,7 +10126,7 @@ var useComboBoxState = (items, placeholder, searchPlaceholder) => {
|
|
|
9809
10126
|
};
|
|
9810
10127
|
};
|
|
9811
10128
|
|
|
9812
|
-
var _excluded$
|
|
10129
|
+
var _excluded$x = ["placeholder", "items", "showTick", "onSelect", "searchEnabled", "left", "right", "label", "filteredItems", "setSelectedItem", "selectedItem", "highlightedIndex", "setHighlightedIndex", "searchQuery", "setSearchQuery", "setFilteredItems", "views", "isDropdownVisible", "setIsDropdownVisible"];
|
|
9813
10130
|
// Defines the functional component 'ComboBoxView' with destructured props.
|
|
9814
10131
|
var ComboBoxView = _ref => {
|
|
9815
10132
|
var {
|
|
@@ -9834,7 +10151,7 @@ var ComboBoxView = _ref => {
|
|
|
9834
10151
|
setIsDropdownVisible
|
|
9835
10152
|
// Collects all further props not destructured explicitly.
|
|
9836
10153
|
} = _ref,
|
|
9837
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
10154
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$x);
|
|
9838
10155
|
// Sets up an effect to handle clicking outside the dropdown to close it.
|
|
9839
10156
|
React.useEffect(() => {
|
|
9840
10157
|
var handleClickOutside = event => {
|
|
@@ -9946,7 +10263,7 @@ var ComboBoxView = _ref => {
|
|
|
9946
10263
|
}))))))))))));
|
|
9947
10264
|
};
|
|
9948
10265
|
|
|
9949
|
-
var _excluded$
|
|
10266
|
+
var _excluded$y = ["id", "name", "items", "placeholder", "searchPlaceholder"];
|
|
9950
10267
|
// Defines the ComboBoxComponent functional component with ComboBoxProps
|
|
9951
10268
|
var ComboBoxComponent = _ref => {
|
|
9952
10269
|
var {
|
|
@@ -9962,7 +10279,7 @@ var ComboBoxComponent = _ref => {
|
|
|
9962
10279
|
searchPlaceholder
|
|
9963
10280
|
// Destructures the rest of the props not explicitly defined
|
|
9964
10281
|
} = _ref,
|
|
9965
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
10282
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$y);
|
|
9966
10283
|
// Initializes ComboBox state using custom hook with items and placeholders
|
|
9967
10284
|
var state = useComboBoxState(items, placeholder, searchPlaceholder);
|
|
9968
10285
|
return (
|
|
@@ -10284,7 +10601,7 @@ var useOTPInputState = _ref => {
|
|
|
10284
10601
|
};
|
|
10285
10602
|
};
|
|
10286
10603
|
|
|
10287
|
-
var _excluded$
|
|
10604
|
+
var _excluded$z = ["id", "name", "label", "value", "length", "onChange", "onChangeText", "onComplete", "helperText", "placeholder", "shadow", "views", "size", "shape", "variant", "gap", "type", "error", "isFocused", "isHovered", "isDisabled", "isReadOnly", "isAutoFocus", "setValue", "setIsFocused", "setIsHovered", "inputRef", "containerRef", "mirrorSelectionStart", "mirrorSelectionEnd", "setMirrorSelectionStart", "setMirrorSelectionEnd", "handlePaste", "handleChange", "handleFocus", "handleBlur", "handleKeyDown", "handleKeyPress", "secureTextEntry", "isFirstColumn", "stepValues", "setInputRef", "onBlur", "onClick", "onFocus"];
|
|
10288
10605
|
// Create a context for OTP input slots
|
|
10289
10606
|
var OTPInputContext = /*#__PURE__*/React.createContext({
|
|
10290
10607
|
slots: [],
|
|
@@ -10338,7 +10655,7 @@ var OTPInputView = _ref => {
|
|
|
10338
10655
|
onFocus = () => {}
|
|
10339
10656
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
10340
10657
|
} = _ref,
|
|
10341
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
10658
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$z);
|
|
10342
10659
|
appStudio.useTheme(); // Initialize theme context
|
|
10343
10660
|
var showLabel = !!label;
|
|
10344
10661
|
// Create context value for slots
|
|
@@ -10570,7 +10887,7 @@ var OTPInputComponent = props => {
|
|
|
10570
10887
|
};
|
|
10571
10888
|
var OTPInput = OTPInputComponent;
|
|
10572
10889
|
|
|
10573
|
-
var _excluded$
|
|
10890
|
+
var _excluded$A = ["children", "autoFocus", "initFocus", "onChange"];
|
|
10574
10891
|
var FocusContext = /*#__PURE__*/React.createContext({
|
|
10575
10892
|
active: false,
|
|
10576
10893
|
focusNextInput: () => {},
|
|
@@ -10586,7 +10903,7 @@ var FormikForm = _ref => {
|
|
|
10586
10903
|
initFocus,
|
|
10587
10904
|
onChange = () => {}
|
|
10588
10905
|
} = _ref,
|
|
10589
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
10906
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$A);
|
|
10590
10907
|
var formik$1 = formik.useFormikContext();
|
|
10591
10908
|
React.useEffect(() => {
|
|
10592
10909
|
onChange(formik$1.values);
|
|
@@ -10634,7 +10951,7 @@ var FormikForm = _ref => {
|
|
|
10634
10951
|
}, /*#__PURE__*/React__default.createElement(appStudio.Form, Object.assign({}, props), children));
|
|
10635
10952
|
};
|
|
10636
10953
|
|
|
10637
|
-
var _excluded$
|
|
10954
|
+
var _excluded$B = ["name", "type"];
|
|
10638
10955
|
var getInputTypeProps = type => {
|
|
10639
10956
|
switch (type) {
|
|
10640
10957
|
case 'email':
|
|
@@ -10673,7 +10990,7 @@ var useFormikInput = _ref => {
|
|
|
10673
10990
|
name,
|
|
10674
10991
|
type
|
|
10675
10992
|
} = _ref,
|
|
10676
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
10993
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$B);
|
|
10677
10994
|
var focus = useFormFocus();
|
|
10678
10995
|
var {
|
|
10679
10996
|
touched,
|
|
@@ -10717,13 +11034,13 @@ var useFormikInput = _ref => {
|
|
|
10717
11034
|
} : {});
|
|
10718
11035
|
};
|
|
10719
11036
|
|
|
10720
|
-
var _excluded$
|
|
11037
|
+
var _excluded$C = ["value"];
|
|
10721
11038
|
var CheckboxComponent$1 = props => {
|
|
10722
11039
|
var _useFormikInput = useFormikInput(props),
|
|
10723
11040
|
{
|
|
10724
11041
|
value
|
|
10725
11042
|
} = _useFormikInput,
|
|
10726
|
-
formProps = _objectWithoutPropertiesLoose(_useFormikInput, _excluded$
|
|
11043
|
+
formProps = _objectWithoutPropertiesLoose(_useFormikInput, _excluded$C);
|
|
10727
11044
|
formProps.isChecked = value;
|
|
10728
11045
|
var checkboxStates = useCheckboxState(props);
|
|
10729
11046
|
return /*#__PURE__*/React__default.createElement(CheckboxView, Object.assign({}, checkboxStates, formProps));
|
|
@@ -10781,11 +11098,11 @@ var TextAreaComponent$1 = props => {
|
|
|
10781
11098
|
*/
|
|
10782
11099
|
var FormikTextArea = TextAreaComponent$1;
|
|
10783
11100
|
|
|
10784
|
-
var _excluded$
|
|
11101
|
+
var _excluded$D = ["value"];
|
|
10785
11102
|
var TextFieldComponent$1 = props => {
|
|
10786
11103
|
var formProps = useFormikInput(props);
|
|
10787
11104
|
var _useTextFieldState = useTextFieldState(props),
|
|
10788
|
-
textFieldStates = _objectWithoutPropertiesLoose(_useTextFieldState, _excluded$
|
|
11105
|
+
textFieldStates = _objectWithoutPropertiesLoose(_useTextFieldState, _excluded$D);
|
|
10789
11106
|
return /*#__PURE__*/React__default.createElement(TextFieldView, Object.assign({}, textFieldStates, formProps));
|
|
10790
11107
|
};
|
|
10791
11108
|
/**
|
|
@@ -10793,7 +11110,7 @@ var TextFieldComponent$1 = props => {
|
|
|
10793
11110
|
*/
|
|
10794
11111
|
var FormikTextField = TextFieldComponent$1;
|
|
10795
11112
|
|
|
10796
|
-
var _excluded$
|
|
11113
|
+
var _excluded$E = ["visibleIcon", "hiddenIcon"],
|
|
10797
11114
|
_excluded2$b = ["isVisible", "setIsVisible"];
|
|
10798
11115
|
var PasswordComponent$1 = _ref => {
|
|
10799
11116
|
var {
|
|
@@ -10804,7 +11121,7 @@ var PasswordComponent$1 = _ref => {
|
|
|
10804
11121
|
widthHeight: 14
|
|
10805
11122
|
})
|
|
10806
11123
|
} = _ref,
|
|
10807
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
11124
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$E);
|
|
10808
11125
|
var formProps = useFormikInput(props);
|
|
10809
11126
|
var _usePasswordState = usePasswordState(formProps),
|
|
10810
11127
|
{
|
|
@@ -10829,14 +11146,14 @@ var PasswordComponent$1 = _ref => {
|
|
|
10829
11146
|
*/
|
|
10830
11147
|
var FormikPassword = PasswordComponent$1;
|
|
10831
11148
|
|
|
10832
|
-
var _excluded$
|
|
11149
|
+
var _excluded$F = ["items", "placeholder", "searchPlaceholder"];
|
|
10833
11150
|
var ComboBoxComponent$1 = _ref => {
|
|
10834
11151
|
var {
|
|
10835
11152
|
items,
|
|
10836
11153
|
placeholder,
|
|
10837
11154
|
searchPlaceholder
|
|
10838
11155
|
} = _ref,
|
|
10839
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
11156
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$F);
|
|
10840
11157
|
var formProps = useFormikInput(props);
|
|
10841
11158
|
var ComboBoxStates = useComboBoxState(items, placeholder, searchPlaceholder);
|
|
10842
11159
|
// Ensure the onChange function from formProps is being called when an item is selected
|
|
@@ -11117,7 +11434,7 @@ var OrientationStyles = {
|
|
|
11117
11434
|
}
|
|
11118
11435
|
};
|
|
11119
11436
|
|
|
11120
|
-
var _excluded$
|
|
11437
|
+
var _excluded$G = ["min", "max", "step", "currentValue", "stepValues", "shape", "size", "variant", "orientation", "isDisabled", "showValue", "showTooltip", "backgroundColor", "label", "helperText", "themeMode", "shadow", "isDragging", "isHovered", "setIsHovered", "trackRef", "thumbRef", "handleThumbMouseDown", "handleTrackMouseDown", "handleKeyDown", "thumbPositionPercent", "ariaLabel", "views"];
|
|
11121
11438
|
var SliderView = _ref => {
|
|
11122
11439
|
var _views$tooltip, _views$tooltip2;
|
|
11123
11440
|
var {
|
|
@@ -11160,7 +11477,7 @@ var SliderView = _ref => {
|
|
|
11160
11477
|
tooltip: {}
|
|
11161
11478
|
}
|
|
11162
11479
|
} = _ref,
|
|
11163
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
11480
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$G);
|
|
11164
11481
|
var {
|
|
11165
11482
|
getColor,
|
|
11166
11483
|
themeMode
|
|
@@ -12038,7 +12355,7 @@ var UploadView = _ref => {
|
|
|
12038
12355
|
}, views == null ? void 0 : views.view)));
|
|
12039
12356
|
};
|
|
12040
12357
|
|
|
12041
|
-
var _excluded$
|
|
12358
|
+
var _excluded$H = ["accept", "icon", "text", "maxSize", "onFileSelect", "validateFile", "isLoading", "progress", "fileType"];
|
|
12042
12359
|
var Uploader = _ref => {
|
|
12043
12360
|
var {
|
|
12044
12361
|
accept = '*/*',
|
|
@@ -12051,7 +12368,7 @@ var Uploader = _ref => {
|
|
|
12051
12368
|
progress = 0,
|
|
12052
12369
|
fileType
|
|
12053
12370
|
} = _ref,
|
|
12054
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
12371
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$H);
|
|
12055
12372
|
var {
|
|
12056
12373
|
previewUrl,
|
|
12057
12374
|
thumbnailUrl,
|
|
@@ -12242,7 +12559,7 @@ var ModalTypography = {
|
|
|
12242
12559
|
}
|
|
12243
12560
|
};
|
|
12244
12561
|
|
|
12245
|
-
var _excluded$
|
|
12562
|
+
var _excluded$I = ["children", "blur", "isOpen", "isClosePrevented", "onClose", "position", "views"],
|
|
12246
12563
|
_excluded2$c = ["children", "shadow", "isFullScreen", "shape", "views", "isOpen"],
|
|
12247
12564
|
_excluded3$8 = ["children", "buttonColor", "iconSize", "buttonPosition", "views"],
|
|
12248
12565
|
_excluded4$7 = ["children", "views"],
|
|
@@ -12257,7 +12574,7 @@ var ModalOverlay = _ref => {
|
|
|
12257
12574
|
position = 'center',
|
|
12258
12575
|
views
|
|
12259
12576
|
} = _ref,
|
|
12260
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
12577
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$I);
|
|
12261
12578
|
var handleClick = () => {
|
|
12262
12579
|
if (!isClosePrevented) onClose();
|
|
12263
12580
|
};
|
|
@@ -12553,7 +12870,7 @@ var NavigationMenuItemStates = {
|
|
|
12553
12870
|
}
|
|
12554
12871
|
};
|
|
12555
12872
|
|
|
12556
|
-
var _excluded$
|
|
12873
|
+
var _excluded$J = ["href", "children", "views"];
|
|
12557
12874
|
// Create context for the NavigationMenu
|
|
12558
12875
|
var NavigationMenuContext = /*#__PURE__*/React.createContext({
|
|
12559
12876
|
activeItemId: null,
|
|
@@ -12788,7 +13105,7 @@ var NavigationMenuLink = _ref6 => {
|
|
|
12788
13105
|
children,
|
|
12789
13106
|
views
|
|
12790
13107
|
} = _ref6,
|
|
12791
|
-
props = _objectWithoutPropertiesLoose(_ref6, _excluded$
|
|
13108
|
+
props = _objectWithoutPropertiesLoose(_ref6, _excluded$J);
|
|
12792
13109
|
var {
|
|
12793
13110
|
itemValue,
|
|
12794
13111
|
isDisabled
|
|
@@ -12855,7 +13172,7 @@ var NavigationMenuView = _ref7 => {
|
|
|
12855
13172
|
})))));
|
|
12856
13173
|
};
|
|
12857
13174
|
|
|
12858
|
-
var _excluded$
|
|
13175
|
+
var _excluded$K = ["items", "children", "orientation", "size", "variant", "defaultActiveItemId", "defaultExpandedItemIds", "onItemActivate", "views"];
|
|
12859
13176
|
/**
|
|
12860
13177
|
* NavigationMenu component for creating navigation menus with optional nested items.
|
|
12861
13178
|
* Supports both data-driven approach (with items prop) and compound component pattern.
|
|
@@ -12872,7 +13189,7 @@ var NavigationMenuComponent = _ref => {
|
|
|
12872
13189
|
onItemActivate,
|
|
12873
13190
|
views
|
|
12874
13191
|
} = _ref,
|
|
12875
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
13192
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$K);
|
|
12876
13193
|
var {
|
|
12877
13194
|
activeItemId,
|
|
12878
13195
|
setActiveItemId,
|
|
@@ -13327,6 +13644,393 @@ var TabsComponent = _ref => {
|
|
|
13327
13644
|
// Export the component wrapped in React.memo for performance optimization
|
|
13328
13645
|
var Tabs = /*#__PURE__*/React__default.memo(TabsComponent);
|
|
13329
13646
|
|
|
13647
|
+
/**
|
|
13648
|
+
* Custom hook for managing Title component state
|
|
13649
|
+
*/
|
|
13650
|
+
var useTitleState = props => {
|
|
13651
|
+
var {
|
|
13652
|
+
children,
|
|
13653
|
+
// Original children
|
|
13654
|
+
_isInView = false,
|
|
13655
|
+
alternateHighlightText = [],
|
|
13656
|
+
alternateAnimation = false,
|
|
13657
|
+
// Default to false as per prop definition
|
|
13658
|
+
alternateDuration = 3000,
|
|
13659
|
+
highlightText: initialHighlightText,
|
|
13660
|
+
// Renamed to avoid confusion with the dynamic target
|
|
13661
|
+
highlightTypewriter = false,
|
|
13662
|
+
highlightTypewriterDuration = 1500
|
|
13663
|
+
} = props;
|
|
13664
|
+
// State for the final text to be displayed (could be original children or alternating text)
|
|
13665
|
+
var [finalDisplayedText, setFinalDisplayedText] = React.useState(children);
|
|
13666
|
+
// State for the text that should be actively highlighted (could be initialHighlightText or a word from alternateHighlightText)
|
|
13667
|
+
var [activeHighlightTarget, setActiveHighlightTarget] = React.useState(initialHighlightText);
|
|
13668
|
+
// We don't need state for typewriter text anymore as we're using the TypewriterEffect component
|
|
13669
|
+
// Handle alternating highlight text animation
|
|
13670
|
+
React.useEffect(() => {
|
|
13671
|
+
// If not using alternating animation or conditions not met, reset to initial/non-alternating state
|
|
13672
|
+
if (!alternateAnimation || alternateHighlightText.length === 0 || !_isInView || typeof children !== 'string' ||
|
|
13673
|
+
// Base text must be a string for replacement
|
|
13674
|
+
typeof initialHighlightText !== 'string' // Placeholder must be a string
|
|
13675
|
+
) {
|
|
13676
|
+
setFinalDisplayedText(children);
|
|
13677
|
+
setActiveHighlightTarget(initialHighlightText);
|
|
13678
|
+
return () => {};
|
|
13679
|
+
}
|
|
13680
|
+
// Proceed with alternating animation
|
|
13681
|
+
var baseText = children;
|
|
13682
|
+
var placeholder = initialHighlightText;
|
|
13683
|
+
var currentIndex = 0;
|
|
13684
|
+
// Function to update the state for alternating text
|
|
13685
|
+
var updateAlternatingState = index => {
|
|
13686
|
+
var currentWordToHighlight = alternateHighlightText[index];
|
|
13687
|
+
// Replace the placeholder in the baseText with the current alternating word
|
|
13688
|
+
var regex = new RegExp(placeholder, 'gi');
|
|
13689
|
+
var newContent = baseText.replace(regex, currentWordToHighlight);
|
|
13690
|
+
setFinalDisplayedText(newContent);
|
|
13691
|
+
setActiveHighlightTarget(currentWordToHighlight); // Set the current word as the highlight target
|
|
13692
|
+
};
|
|
13693
|
+
// Set initial alternating state
|
|
13694
|
+
updateAlternatingState(currentIndex);
|
|
13695
|
+
// Create interval to cycle through the alternateHighlightText array
|
|
13696
|
+
var interval = setInterval(() => {
|
|
13697
|
+
currentIndex = (currentIndex + 1) % alternateHighlightText.length;
|
|
13698
|
+
updateAlternatingState(currentIndex);
|
|
13699
|
+
}, alternateDuration);
|
|
13700
|
+
return () => clearInterval(interval);
|
|
13701
|
+
}, [alternateAnimation, alternateHighlightText, alternateDuration, initialHighlightText, children, _isInView]);
|
|
13702
|
+
// We don't need a separate effect for typewriter animation anymore
|
|
13703
|
+
// as we're using the TypewriterEffect component directly in the view
|
|
13704
|
+
return {
|
|
13705
|
+
finalDisplayedText,
|
|
13706
|
+
activeHighlightTarget,
|
|
13707
|
+
highlightTypewriter
|
|
13708
|
+
};
|
|
13709
|
+
};
|
|
13710
|
+
|
|
13711
|
+
/**
|
|
13712
|
+
* Font sizes for different title sizes
|
|
13713
|
+
*/
|
|
13714
|
+
var TitleSizes = {
|
|
13715
|
+
xs: 16,
|
|
13716
|
+
sm: 20,
|
|
13717
|
+
md: 24,
|
|
13718
|
+
lg: 32,
|
|
13719
|
+
xl: 40,
|
|
13720
|
+
'2xl': 48,
|
|
13721
|
+
'3xl': 56,
|
|
13722
|
+
'4xl': 64,
|
|
13723
|
+
'5xl': 72,
|
|
13724
|
+
'6xl': 80
|
|
13725
|
+
};
|
|
13726
|
+
/**
|
|
13727
|
+
* Line heights for different title sizes
|
|
13728
|
+
*/
|
|
13729
|
+
var LineHeights$1 = {
|
|
13730
|
+
xs: 24,
|
|
13731
|
+
sm: 28,
|
|
13732
|
+
md: 32,
|
|
13733
|
+
lg: 40,
|
|
13734
|
+
xl: 48,
|
|
13735
|
+
'2xl': 56,
|
|
13736
|
+
'3xl': 64,
|
|
13737
|
+
'4xl': 72,
|
|
13738
|
+
'5xl': 80,
|
|
13739
|
+
'6xl': 88
|
|
13740
|
+
};
|
|
13741
|
+
/**
|
|
13742
|
+
* Default styles for different highlight types
|
|
13743
|
+
*/
|
|
13744
|
+
var HighlightStyles = {
|
|
13745
|
+
underline: color => ({
|
|
13746
|
+
textDecoration: 'underline',
|
|
13747
|
+
textDecorationColor: color,
|
|
13748
|
+
textDecorationThickness: '4px',
|
|
13749
|
+
textUnderlineOffset: '4px'
|
|
13750
|
+
}),
|
|
13751
|
+
background: color => ({
|
|
13752
|
+
backgroundColor: color,
|
|
13753
|
+
color: 'color.white',
|
|
13754
|
+
padding: '0 8px',
|
|
13755
|
+
borderRadius: '4px'
|
|
13756
|
+
}),
|
|
13757
|
+
gradient: (color, secondaryColor) => ({
|
|
13758
|
+
background: "linear-gradient(135deg, " + color + ", " + (secondaryColor || color) + ")",
|
|
13759
|
+
backgroundClip: 'text',
|
|
13760
|
+
webkitBackgroundClip: 'text',
|
|
13761
|
+
color: 'transparent',
|
|
13762
|
+
webkitTextFillColor: 'transparent',
|
|
13763
|
+
display: 'inline-block',
|
|
13764
|
+
textShadow: 'none'
|
|
13765
|
+
}),
|
|
13766
|
+
outline: color => ({
|
|
13767
|
+
webkitTextStroke: "1px " + color,
|
|
13768
|
+
webkitTextFillColor: 'transparent',
|
|
13769
|
+
color: 'transparent',
|
|
13770
|
+
textShadow: 'none'
|
|
13771
|
+
}),
|
|
13772
|
+
glow: color => ({
|
|
13773
|
+
color: color,
|
|
13774
|
+
textShadow: "0 0 10px " + color + "80, 0 0 20px " + color + "40, 0 0 30px " + color + "20"
|
|
13775
|
+
})
|
|
13776
|
+
};
|
|
13777
|
+
|
|
13778
|
+
var _excluded$L = ["text", "typingSpeed", "pauseTime", "onComplete", "showCursor", "cursorColor", "textStyle", "as"];
|
|
13779
|
+
/**
|
|
13780
|
+
* A component that creates a typewriter effect for text
|
|
13781
|
+
*/
|
|
13782
|
+
var TypewriterEffect = _ref => {
|
|
13783
|
+
var {
|
|
13784
|
+
text,
|
|
13785
|
+
typingSpeed = 50,
|
|
13786
|
+
pauseTime = 500,
|
|
13787
|
+
onComplete,
|
|
13788
|
+
showCursor = true,
|
|
13789
|
+
cursorColor = 'currentColor',
|
|
13790
|
+
textStyle
|
|
13791
|
+
} = _ref,
|
|
13792
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$L);
|
|
13793
|
+
// Convert text to array if it's a string
|
|
13794
|
+
var textArray = Array.isArray(text) ? text : [text];
|
|
13795
|
+
// State for the currently displayed text
|
|
13796
|
+
var [displayedText, setDisplayedText] = React.useState(textArray.map(() => ''));
|
|
13797
|
+
// State to track if typing is complete
|
|
13798
|
+
var [isComplete, setIsComplete] = React.useState(false);
|
|
13799
|
+
// State to track which text item we're currently typing
|
|
13800
|
+
var [currentTextIndex, setCurrentTextIndex] = React.useState(0);
|
|
13801
|
+
// State to track the character position within the current text
|
|
13802
|
+
var [charIndex, setCharIndex] = React.useState(0);
|
|
13803
|
+
React.useEffect(() => {
|
|
13804
|
+
// Reset state when text changes
|
|
13805
|
+
setDisplayedText(textArray.map(() => ''));
|
|
13806
|
+
setIsComplete(false);
|
|
13807
|
+
setCurrentTextIndex(0);
|
|
13808
|
+
setCharIndex(0);
|
|
13809
|
+
}, [text]);
|
|
13810
|
+
React.useEffect(() => {
|
|
13811
|
+
// If all text is typed, call onComplete and return
|
|
13812
|
+
if (isComplete) {
|
|
13813
|
+
if (onComplete) onComplete();
|
|
13814
|
+
return;
|
|
13815
|
+
}
|
|
13816
|
+
// Get the current text we're typing
|
|
13817
|
+
var currentText = textArray[currentTextIndex];
|
|
13818
|
+
// If we've typed all characters in the current text
|
|
13819
|
+
if (charIndex >= currentText.length) {
|
|
13820
|
+
// If we've typed all texts, we're done
|
|
13821
|
+
if (currentTextIndex >= textArray.length - 1) {
|
|
13822
|
+
setIsComplete(true);
|
|
13823
|
+
return;
|
|
13824
|
+
}
|
|
13825
|
+
// Otherwise, move to the next text after a pause
|
|
13826
|
+
var _timeout = setTimeout(() => {
|
|
13827
|
+
setCurrentTextIndex(prev => prev + 1);
|
|
13828
|
+
setCharIndex(0);
|
|
13829
|
+
}, pauseTime);
|
|
13830
|
+
return () => clearTimeout(_timeout);
|
|
13831
|
+
}
|
|
13832
|
+
// Type the next character
|
|
13833
|
+
var timeout = setTimeout(() => {
|
|
13834
|
+
setDisplayedText(prev => {
|
|
13835
|
+
var newText = [...prev];
|
|
13836
|
+
newText[currentTextIndex] = currentText.substring(0, charIndex + 1);
|
|
13837
|
+
return newText;
|
|
13838
|
+
});
|
|
13839
|
+
setCharIndex(prev => prev + 1);
|
|
13840
|
+
}, typingSpeed);
|
|
13841
|
+
return () => clearTimeout(timeout);
|
|
13842
|
+
}, [textArray, currentTextIndex, charIndex, isComplete, onComplete, pauseTime, typingSpeed]);
|
|
13843
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, displayedText.map((text, index) => (/*#__PURE__*/React__default.createElement(React__default.Fragment, {
|
|
13844
|
+
key: index
|
|
13845
|
+
}, text, showCursor && index === currentTextIndex && !isComplete && (/*#__PURE__*/React__default.createElement(appStudio.Text, {
|
|
13846
|
+
as: "span",
|
|
13847
|
+
display: "inline-block",
|
|
13848
|
+
width: "0.1em",
|
|
13849
|
+
height: "1em",
|
|
13850
|
+
backgroundColor: cursorColor,
|
|
13851
|
+
style: Object.assign({
|
|
13852
|
+
animation: 'blink 1s step-end infinite',
|
|
13853
|
+
verticalAlign: 'text-bottom',
|
|
13854
|
+
marginLeft: '1px'
|
|
13855
|
+
}, textStyle)
|
|
13856
|
+
}))))));
|
|
13857
|
+
};
|
|
13858
|
+
|
|
13859
|
+
var _excluded$M = ["children", "highlightText", "highlightStyle", "highlightColor", "highlightSecondaryColor", "size", "centered", "views", "highlightAnimate", "animate", "highlightTypewriter", "highlightTypewriterDuration"];
|
|
13860
|
+
function escapeRegExp(string) {
|
|
13861
|
+
return string.replace(/[.*+?^${}()|[\\]\\/g, '\\$&');
|
|
13862
|
+
}
|
|
13863
|
+
var TitleView = _ref => {
|
|
13864
|
+
var {
|
|
13865
|
+
children,
|
|
13866
|
+
highlightText,
|
|
13867
|
+
highlightStyle = 'background',
|
|
13868
|
+
highlightColor = 'theme.primary',
|
|
13869
|
+
highlightSecondaryColor,
|
|
13870
|
+
size = 'xl',
|
|
13871
|
+
centered = false,
|
|
13872
|
+
views,
|
|
13873
|
+
highlightAnimate,
|
|
13874
|
+
animate,
|
|
13875
|
+
highlightTypewriter: propHighlightTypewriter = false,
|
|
13876
|
+
highlightTypewriterDuration = 3000
|
|
13877
|
+
} = _ref,
|
|
13878
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$M);
|
|
13879
|
+
var {
|
|
13880
|
+
ref,
|
|
13881
|
+
inView
|
|
13882
|
+
} = appStudio.useInView();
|
|
13883
|
+
var {
|
|
13884
|
+
getColor,
|
|
13885
|
+
themeMode: ctxMode
|
|
13886
|
+
} = appStudio.useTheme();
|
|
13887
|
+
var themeMode = props.themeMode || ctxMode;
|
|
13888
|
+
// Resolve colors, handling both theme colors and direct hex values
|
|
13889
|
+
var resolveColorValue = colorValue => {
|
|
13890
|
+
// If it's already a hex color, return it directly
|
|
13891
|
+
if (colorValue.startsWith('#')) {
|
|
13892
|
+
return colorValue;
|
|
13893
|
+
}
|
|
13894
|
+
// Otherwise, use the theme's getColor function
|
|
13895
|
+
return getColor(colorValue, {
|
|
13896
|
+
themeMode
|
|
13897
|
+
});
|
|
13898
|
+
};
|
|
13899
|
+
var resolvedColor = resolveColorValue(highlightColor);
|
|
13900
|
+
var resolvedSecondary = highlightSecondaryColor ? resolveColorValue(highlightSecondaryColor) : undefined;
|
|
13901
|
+
var {
|
|
13902
|
+
finalDisplayedText,
|
|
13903
|
+
activeHighlightTarget,
|
|
13904
|
+
highlightTypewriter
|
|
13905
|
+
} = useTitleState(Object.assign({
|
|
13906
|
+
children,
|
|
13907
|
+
highlightText,
|
|
13908
|
+
_isInView: inView,
|
|
13909
|
+
highlightTypewriter: propHighlightTypewriter,
|
|
13910
|
+
highlightTypewriterDuration
|
|
13911
|
+
}, props));
|
|
13912
|
+
var fontSize = TitleSizes[size];
|
|
13913
|
+
var lineHeight = LineHeights$1[size];
|
|
13914
|
+
// Get the text to display
|
|
13915
|
+
var text = typeof finalDisplayedText === 'string' ? finalDisplayedText : typeof children === 'string' ? children : '';
|
|
13916
|
+
if (typeof text === 'string' && activeHighlightTarget) {
|
|
13917
|
+
var pattern = new RegExp("(" + escapeRegExp(Array.isArray(activeHighlightTarget) ? activeHighlightTarget.join('|') : activeHighlightTarget) + ")", 'gi');
|
|
13918
|
+
var parts = [];
|
|
13919
|
+
var lastIndex = 0;
|
|
13920
|
+
var match;
|
|
13921
|
+
while (match = pattern.exec(text)) {
|
|
13922
|
+
if (match.index > lastIndex) {
|
|
13923
|
+
parts.push(text.substring(lastIndex, match.index));
|
|
13924
|
+
}
|
|
13925
|
+
parts.push({
|
|
13926
|
+
highlight: true,
|
|
13927
|
+
text: match[0]
|
|
13928
|
+
});
|
|
13929
|
+
lastIndex = match.index + match[0].length;
|
|
13930
|
+
}
|
|
13931
|
+
if (lastIndex < text.length) {
|
|
13932
|
+
parts.push(text.substring(lastIndex));
|
|
13933
|
+
}
|
|
13934
|
+
return /*#__PURE__*/React__default.createElement(appStudio.Element, Object.assign({
|
|
13935
|
+
ref: ref,
|
|
13936
|
+
as: "h1",
|
|
13937
|
+
fontSize: fontSize,
|
|
13938
|
+
lineHeight: lineHeight + "px",
|
|
13939
|
+
fontWeight: "bold",
|
|
13940
|
+
textAlign: centered ? 'center' : 'left',
|
|
13941
|
+
animate: inView ? animate : undefined
|
|
13942
|
+
}, views == null ? void 0 : views.container, props), parts.map((part, idx) => typeof part === 'string' ? part : (/*#__PURE__*/React__default.createElement(appStudio.Text, Object.assign({
|
|
13943
|
+
key: part.text + "-" + idx,
|
|
13944
|
+
as: "span",
|
|
13945
|
+
display: "inline",
|
|
13946
|
+
animate: inView ? highlightAnimate : undefined
|
|
13947
|
+
}, HighlightStyles[highlightStyle](resolvedColor, resolvedSecondary), views == null ? void 0 : views.highlight), highlightTypewriter ? (/*#__PURE__*/React__default.createElement(TypewriterEffect, {
|
|
13948
|
+
text: part.text,
|
|
13949
|
+
typingSpeed: Math.max(30, highlightTypewriterDuration / (part.text.length * 10)),
|
|
13950
|
+
showCursor: true,
|
|
13951
|
+
cursorColor: "currentColor"
|
|
13952
|
+
})) : part.text))));
|
|
13953
|
+
}
|
|
13954
|
+
// If highlightStyle is provided but no highlightText, apply the style to the entire title
|
|
13955
|
+
if (highlightStyle && !activeHighlightTarget) {
|
|
13956
|
+
return /*#__PURE__*/React__default.createElement(appStudio.Element, Object.assign({
|
|
13957
|
+
ref: ref,
|
|
13958
|
+
as: "h1",
|
|
13959
|
+
fontSize: fontSize,
|
|
13960
|
+
lineHeight: lineHeight + "px",
|
|
13961
|
+
fontWeight: "bold",
|
|
13962
|
+
textAlign: centered ? 'center' : 'left',
|
|
13963
|
+
animate: inView ? animate : undefined
|
|
13964
|
+
}, views == null ? void 0 : views.container, props), /*#__PURE__*/React__default.createElement(appStudio.Text, Object.assign({
|
|
13965
|
+
as: "span",
|
|
13966
|
+
display: "inline",
|
|
13967
|
+
animate: inView ? highlightAnimate : undefined
|
|
13968
|
+
}, HighlightStyles[highlightStyle](resolvedColor, resolvedSecondary), views == null ? void 0 : views.highlight), highlightTypewriter ? (/*#__PURE__*/React__default.createElement(TypewriterEffect, {
|
|
13969
|
+
text: text,
|
|
13970
|
+
typingSpeed: Math.max(30, highlightTypewriterDuration / (text.length * 10)),
|
|
13971
|
+
showCursor: true,
|
|
13972
|
+
cursorColor: "currentColor"
|
|
13973
|
+
})) : text));
|
|
13974
|
+
}
|
|
13975
|
+
// Default case - no highlighting
|
|
13976
|
+
return /*#__PURE__*/React__default.createElement(appStudio.Element, Object.assign({
|
|
13977
|
+
ref: ref,
|
|
13978
|
+
as: "h1",
|
|
13979
|
+
fontSize: fontSize,
|
|
13980
|
+
lineHeight: lineHeight + "px",
|
|
13981
|
+
fontWeight: "bold",
|
|
13982
|
+
textAlign: centered ? 'center' : 'left',
|
|
13983
|
+
animate: inView ? animate : undefined
|
|
13984
|
+
}, views == null ? void 0 : views.container, props), text);
|
|
13985
|
+
};
|
|
13986
|
+
|
|
13987
|
+
/**
|
|
13988
|
+
* Title Component
|
|
13989
|
+
*
|
|
13990
|
+
* A component for rendering animated and highlighted titles in hero sections.
|
|
13991
|
+
*
|
|
13992
|
+
* Features:
|
|
13993
|
+
* - Text highlighting with various styles (background, underline, gradient, outline, glow)
|
|
13994
|
+
* - Multiple animation options (fade, slide, typewriter, reveal)
|
|
13995
|
+
* - Responsive sizing
|
|
13996
|
+
* - Customizable styling
|
|
13997
|
+
*
|
|
13998
|
+
* @example
|
|
13999
|
+
* // Basic usage
|
|
14000
|
+
* <Title>Welcome to Our Platform</Title>
|
|
14001
|
+
*
|
|
14002
|
+
* @example
|
|
14003
|
+
* // With highlighting
|
|
14004
|
+
* <Title highlightText="Platform" highlightStyle="background" highlightColor="theme.primary">
|
|
14005
|
+
* Welcome to Our Platform
|
|
14006
|
+
* </Title>
|
|
14007
|
+
*
|
|
14008
|
+
* @example
|
|
14009
|
+
* // With animation
|
|
14010
|
+
* <Title
|
|
14011
|
+
* animation="fadeIn"
|
|
14012
|
+
* animationDuration="1.5s"
|
|
14013
|
+
* size="2xl"
|
|
14014
|
+
* >
|
|
14015
|
+
* Animated Title
|
|
14016
|
+
* </Title>
|
|
14017
|
+
*
|
|
14018
|
+
* @example
|
|
14019
|
+
* // With multiple highlights
|
|
14020
|
+
* <Title
|
|
14021
|
+
* highlightText={["Amazing", "Features"]}
|
|
14022
|
+
* highlightStyle="gradient"
|
|
14023
|
+
* highlightColor="theme.primary"
|
|
14024
|
+
* highlightSecondaryColor="theme.secondary"
|
|
14025
|
+
* >
|
|
14026
|
+
* Discover our Amazing Product with Great Features
|
|
14027
|
+
* </Title>
|
|
14028
|
+
*/
|
|
14029
|
+
var TitleComponent = props => {
|
|
14030
|
+
return /*#__PURE__*/React__default.createElement(TitleView, Object.assign({}, props));
|
|
14031
|
+
};
|
|
14032
|
+
var Title = TitleComponent;
|
|
14033
|
+
|
|
13330
14034
|
// Declares the useToggleState function which takes defaultToggled parameter to initialize the toggle state.
|
|
13331
14035
|
var useToggleState = defaultToggled => {
|
|
13332
14036
|
// Creates a stateful value isHovered for tracking hover state and a function setIsHovered to update that state, initially false.
|
|
@@ -13342,7 +14046,7 @@ var useToggleState = defaultToggled => {
|
|
|
13342
14046
|
};
|
|
13343
14047
|
};
|
|
13344
14048
|
|
|
13345
|
-
var _excluded$
|
|
14049
|
+
var _excluded$N = ["children", "shape", "variant", "isHovered", "setIsHovered", "isDisabled", "isToggle", "setIsToggled", "onToggle", "views"];
|
|
13346
14050
|
var ToggleView = _ref => {
|
|
13347
14051
|
var {
|
|
13348
14052
|
children,
|
|
@@ -13356,7 +14060,7 @@ var ToggleView = _ref => {
|
|
|
13356
14060
|
onToggle,
|
|
13357
14061
|
views
|
|
13358
14062
|
} = _ref,
|
|
13359
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
14063
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$N);
|
|
13360
14064
|
var toggleColor = !isDisabled ? 'color.trueGray.400' : 'theme.disabled';
|
|
13361
14065
|
var isActive = !!(isToggle || isHovered);
|
|
13362
14066
|
var toggleVariants = {
|
|
@@ -13399,7 +14103,7 @@ var ToggleView = _ref => {
|
|
|
13399
14103
|
}, toggleVariants[variant], props, views == null ? void 0 : views.container), children);
|
|
13400
14104
|
};
|
|
13401
14105
|
|
|
13402
|
-
var _excluded$
|
|
14106
|
+
var _excluded$O = ["children", "shape", "variant", "isDisabled", "isToggled", "onToggle"];
|
|
13403
14107
|
// Destructuring properties from ToggleProps to be used within the ToggleComponent.
|
|
13404
14108
|
var ToggleComponent = _ref => {
|
|
13405
14109
|
var {
|
|
@@ -13411,7 +14115,7 @@ var ToggleComponent = _ref => {
|
|
|
13411
14115
|
isToggled = false,
|
|
13412
14116
|
onToggle
|
|
13413
14117
|
} = _ref,
|
|
13414
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
14118
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$O);
|
|
13415
14119
|
// Initializing toggle state and set state functions using the custom hook useToggleState.
|
|
13416
14120
|
var {
|
|
13417
14121
|
isHovered,
|
|
@@ -13802,7 +14506,7 @@ var getDropdownPosition = function getDropdownPosition(side, align) {
|
|
|
13802
14506
|
return positions[side];
|
|
13803
14507
|
};
|
|
13804
14508
|
|
|
13805
|
-
var _excluded$
|
|
14509
|
+
var _excluded$P = ["children", "views"],
|
|
13806
14510
|
_excluded2$d = ["items", "side", "align", "views"],
|
|
13807
14511
|
_excluded3$9 = ["item", "views"],
|
|
13808
14512
|
_excluded4$8 = ["views"],
|
|
@@ -13840,7 +14544,7 @@ var DropdownMenuTrigger = _ref2 => {
|
|
|
13840
14544
|
children,
|
|
13841
14545
|
views
|
|
13842
14546
|
} = _ref2,
|
|
13843
|
-
props = _objectWithoutPropertiesLoose(_ref2, _excluded$
|
|
14547
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$P);
|
|
13844
14548
|
var {
|
|
13845
14549
|
isOpen,
|
|
13846
14550
|
setIsOpen
|
|
@@ -14000,7 +14704,7 @@ var DropdownMenuView = _ref6 => {
|
|
|
14000
14704
|
}));
|
|
14001
14705
|
};
|
|
14002
14706
|
|
|
14003
|
-
var _excluded$
|
|
14707
|
+
var _excluded$Q = ["trigger", "items", "size", "variant", "side", "align", "defaultOpen", "views"];
|
|
14004
14708
|
/**
|
|
14005
14709
|
* DropdownMenu component for displaying a menu when clicking on a trigger element.
|
|
14006
14710
|
*/
|
|
@@ -14015,7 +14719,7 @@ var DropdownMenuComponent = _ref => {
|
|
|
14015
14719
|
defaultOpen = false,
|
|
14016
14720
|
views
|
|
14017
14721
|
} = _ref,
|
|
14018
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
14722
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$Q);
|
|
14019
14723
|
var {
|
|
14020
14724
|
isOpen,
|
|
14021
14725
|
setIsOpen,
|
|
@@ -14213,7 +14917,7 @@ var useRect = ref => {
|
|
|
14213
14917
|
return rect;
|
|
14214
14918
|
};
|
|
14215
14919
|
|
|
14216
|
-
var _excluded$
|
|
14920
|
+
var _excluded$R = ["children", "views", "asChild"],
|
|
14217
14921
|
_excluded2$e = ["children", "views", "side", "align", "sideOffset", "style", "backgroundColor", "borderRadius", "boxShadow", "padding", "minWidth", "maxWidth"];
|
|
14218
14922
|
// Create context for the HoverCard
|
|
14219
14923
|
var HoverCardContext = /*#__PURE__*/React.createContext({
|
|
@@ -14252,7 +14956,7 @@ var HoverCardTrigger = _ref2 => {
|
|
|
14252
14956
|
views,
|
|
14253
14957
|
asChild = false
|
|
14254
14958
|
} = _ref2,
|
|
14255
|
-
props = _objectWithoutPropertiesLoose(_ref2, _excluded$
|
|
14959
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$R);
|
|
14256
14960
|
var {
|
|
14257
14961
|
openCard,
|
|
14258
14962
|
closeCard,
|
|
@@ -14339,7 +15043,7 @@ var HoverCardContent = _ref3 => {
|
|
|
14339
15043
|
}, views == null ? void 0 : views.container, props), children);
|
|
14340
15044
|
};
|
|
14341
15045
|
|
|
14342
|
-
var _excluded$
|
|
15046
|
+
var _excluded$S = ["children", "views", "openDelay", "closeDelay"];
|
|
14343
15047
|
/**
|
|
14344
15048
|
* HoverCard component displays floating content when hovering over a trigger element.
|
|
14345
15049
|
* Supports configurable open and close delays for a smoother user experience.
|
|
@@ -14351,7 +15055,7 @@ var HoverCardComponent = _ref => {
|
|
|
14351
15055
|
openDelay,
|
|
14352
15056
|
closeDelay
|
|
14353
15057
|
} = _ref,
|
|
14354
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
15058
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$S);
|
|
14355
15059
|
var hoverCardState = useHoverCardState({
|
|
14356
15060
|
openDelay,
|
|
14357
15061
|
closeDelay
|
|
@@ -14481,7 +15185,7 @@ var getMenubarContentPosition = orientation => {
|
|
|
14481
15185
|
};
|
|
14482
15186
|
};
|
|
14483
15187
|
|
|
14484
|
-
var _excluded$
|
|
15188
|
+
var _excluded$T = ["children", "orientation", "size", "variant", "views"];
|
|
14485
15189
|
// Create context for the Menubar
|
|
14486
15190
|
var MenubarContext = /*#__PURE__*/React.createContext({
|
|
14487
15191
|
activeMenuId: null,
|
|
@@ -14515,7 +15219,7 @@ var MenubarRoot = _ref2 => {
|
|
|
14515
15219
|
variant = 'default',
|
|
14516
15220
|
views
|
|
14517
15221
|
} = _ref2,
|
|
14518
|
-
props = _objectWithoutPropertiesLoose(_ref2, _excluded$
|
|
15222
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$T);
|
|
14519
15223
|
var Container = orientation === 'horizontal' ? appStudio.Horizontal : appStudio.Vertical;
|
|
14520
15224
|
return /*#__PURE__*/React__default.createElement(Container, Object.assign({
|
|
14521
15225
|
role: "menubar",
|
|
@@ -14701,7 +15405,7 @@ var MenubarView = _ref8 => {
|
|
|
14701
15405
|
})))))));
|
|
14702
15406
|
};
|
|
14703
15407
|
|
|
14704
|
-
var _excluded$
|
|
15408
|
+
var _excluded$U = ["items", "orientation", "size", "variant", "defaultActiveMenuId", "defaultOpenMenuId", "views"];
|
|
14705
15409
|
/**
|
|
14706
15410
|
* Menubar component for creating horizontal or vertical menu bars with dropdown menus.
|
|
14707
15411
|
*/
|
|
@@ -14715,7 +15419,7 @@ var MenubarComponent = _ref => {
|
|
|
14715
15419
|
defaultOpenMenuId = null,
|
|
14716
15420
|
views
|
|
14717
15421
|
} = _ref,
|
|
14718
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
15422
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$U);
|
|
14719
15423
|
var {
|
|
14720
15424
|
activeMenuId,
|
|
14721
15425
|
setActiveMenuId,
|
|
@@ -14871,7 +15575,7 @@ var DisabledButtonStyles = {
|
|
|
14871
15575
|
}
|
|
14872
15576
|
};
|
|
14873
15577
|
|
|
14874
|
-
var _excluded$
|
|
15578
|
+
var _excluded$V = ["currentPage", "totalPages", "onPageChange", "pageSize", "pageSizeOptions", "onPageSizeChange", "showPageSizeSelector", "showPageInfo", "maxPageButtons", "showFirstLastButtons", "size", "variant", "shape", "visiblePageNumbers", "views"];
|
|
14875
15579
|
var PaginationView = _ref => {
|
|
14876
15580
|
var {
|
|
14877
15581
|
currentPage,
|
|
@@ -14902,7 +15606,7 @@ var PaginationView = _ref => {
|
|
|
14902
15606
|
visiblePageNumbers,
|
|
14903
15607
|
views
|
|
14904
15608
|
} = _ref,
|
|
14905
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
15609
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$V);
|
|
14906
15610
|
var handlePageChange = page => {
|
|
14907
15611
|
if (page < 1 || page > totalPages || page === currentPage) {
|
|
14908
15612
|
return;
|
|
@@ -15021,7 +15725,7 @@ var PaginationView = _ref => {
|
|
|
15021
15725
|
}, option.label))))));
|
|
15022
15726
|
};
|
|
15023
15727
|
|
|
15024
|
-
var _excluded$
|
|
15728
|
+
var _excluded$W = ["currentPage", "totalPages", "onPageChange", "pageSize", "pageSizeOptions", "onPageSizeChange", "showPageSizeSelector", "showPageInfo", "maxPageButtons", "showFirstLastButtons", "size", "variant", "shape", "views"];
|
|
15025
15729
|
/**
|
|
15026
15730
|
* Pagination component for navigating through pages of content.
|
|
15027
15731
|
*/
|
|
@@ -15042,7 +15746,7 @@ var PaginationComponent = _ref => {
|
|
|
15042
15746
|
shape = 'rounded',
|
|
15043
15747
|
views
|
|
15044
15748
|
} = _ref,
|
|
15045
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
15749
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$W);
|
|
15046
15750
|
var {
|
|
15047
15751
|
visiblePageNumbers
|
|
15048
15752
|
} = usePaginationState(currentPage, totalPages, maxPageButtons);
|
|
@@ -15112,7 +15816,7 @@ var DefaultSeparatorStyles = {
|
|
|
15112
15816
|
}
|
|
15113
15817
|
};
|
|
15114
15818
|
|
|
15115
|
-
var _excluded$
|
|
15819
|
+
var _excluded$X = ["orientation", "variant", "thickness", "color", "spacing", "label", "decorative", "views", "themeMode"];
|
|
15116
15820
|
var SeparatorView = _ref => {
|
|
15117
15821
|
var {
|
|
15118
15822
|
orientation = 'horizontal',
|
|
@@ -15124,7 +15828,7 @@ var SeparatorView = _ref => {
|
|
|
15124
15828
|
decorative = false,
|
|
15125
15829
|
views
|
|
15126
15830
|
} = _ref,
|
|
15127
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
15831
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$X);
|
|
15128
15832
|
// Access theme if needed for future enhancements
|
|
15129
15833
|
var {
|
|
15130
15834
|
themeMode
|
|
@@ -15362,7 +16066,7 @@ var SidebarTransitions = {
|
|
|
15362
16066
|
bounce: 'width 0.3s cubic-bezier(0.68, -0.55, 0.27, 1.55), transform 0.3s cubic-bezier(0.68, -0.55, 0.27, 1.55)'
|
|
15363
16067
|
};
|
|
15364
16068
|
|
|
15365
|
-
var _excluded$
|
|
16069
|
+
var _excluded$Y = ["children", "showToggleButton", "views"],
|
|
15366
16070
|
_excluded2$f = ["children", "views"],
|
|
15367
16071
|
_excluded3$a = ["children", "views"],
|
|
15368
16072
|
_excluded4$9 = ["children", "position", "size", "variant", "fixed", "hasBackdrop", "expandedWidth", "collapsedWidth", "breakpointBehavior", "elevation", "transitionPreset", "ariaLabel", "isExpanded", "isMobile", "collapse", "views", "themeMode"];
|
|
@@ -15395,7 +16099,7 @@ var SidebarHeader = _ref2 => {
|
|
|
15395
16099
|
showToggleButton = true,
|
|
15396
16100
|
views
|
|
15397
16101
|
} = _ref2,
|
|
15398
|
-
props = _objectWithoutPropertiesLoose(_ref2, _excluded$
|
|
16102
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$Y);
|
|
15399
16103
|
var {
|
|
15400
16104
|
isExpanded,
|
|
15401
16105
|
toggleExpanded,
|
|
@@ -15550,7 +16254,7 @@ var SidebarView = _ref5 => {
|
|
|
15550
16254
|
}))));
|
|
15551
16255
|
};
|
|
15552
16256
|
|
|
15553
|
-
var _excluded$
|
|
16257
|
+
var _excluded$Z = ["children", "position", "size", "variant", "defaultExpanded", "expanded", "onExpandedChange", "fixed", "hasBackdrop", "showToggleButton", "expandedWidth", "collapsedWidth", "breakpoint", "breakpointBehavior", "views"];
|
|
15554
16258
|
/**
|
|
15555
16259
|
* Sidebar component for creating collapsible, themeable and customizable sidebars.
|
|
15556
16260
|
*/
|
|
@@ -15572,7 +16276,7 @@ var SidebarComponent = _ref => {
|
|
|
15572
16276
|
breakpointBehavior = 'overlay',
|
|
15573
16277
|
views
|
|
15574
16278
|
} = _ref,
|
|
15575
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
16279
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$Z);
|
|
15576
16280
|
var {
|
|
15577
16281
|
isExpanded,
|
|
15578
16282
|
toggleExpanded,
|
|
@@ -16037,7 +16741,7 @@ var HandleIconStyles = {
|
|
|
16037
16741
|
}
|
|
16038
16742
|
};
|
|
16039
16743
|
|
|
16040
|
-
var _excluded$
|
|
16744
|
+
var _excluded$_ = ["children", "id", "defaultSize", "minSize", "maxSize", "collapsible", "defaultCollapsed", "onCollapseChange", "views"],
|
|
16041
16745
|
_excluded2$g = ["id", "position", "disabled", "withVisualIndicator", "withCollapseButton", "collapseTarget", "views"],
|
|
16042
16746
|
_excluded3$b = ["children", "orientation", "size", "variant", "defaultSizes", "minSize", "maxSize", "collapsible", "containerRef", "autoSaveId", "views"];
|
|
16043
16747
|
// Create context for the Resizable component
|
|
@@ -16082,7 +16786,7 @@ var ResizablePanel = _ref2 => {
|
|
|
16082
16786
|
onCollapseChange,
|
|
16083
16787
|
views
|
|
16084
16788
|
} = _ref2,
|
|
16085
|
-
props = _objectWithoutPropertiesLoose(_ref2, _excluded$
|
|
16789
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$_);
|
|
16086
16790
|
var {
|
|
16087
16791
|
orientation,
|
|
16088
16792
|
registerPanel,
|
|
@@ -16297,7 +17001,7 @@ var ResizableView = _ref4 => {
|
|
|
16297
17001
|
}, ResizableOrientations[orientation], views == null ? void 0 : views.container, props), children);
|
|
16298
17002
|
};
|
|
16299
17003
|
|
|
16300
|
-
var _excluded
|
|
17004
|
+
var _excluded$$ = ["children", "orientation", "size", "variant", "defaultSizes", "onSizesChange", "minSize", "maxSize", "collapsible", "autoSaveId", "storage", "keyboardResizeBy", "views"];
|
|
16301
17005
|
/**
|
|
16302
17006
|
* Resizable component for creating resizable panel groups and layouts.
|
|
16303
17007
|
*/
|
|
@@ -16317,7 +17021,7 @@ var ResizableComponent = _ref => {
|
|
|
16317
17021
|
keyboardResizeBy = 10,
|
|
16318
17022
|
views
|
|
16319
17023
|
} = _ref,
|
|
16320
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded
|
|
17024
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$$);
|
|
16321
17025
|
var {
|
|
16322
17026
|
isResizing,
|
|
16323
17027
|
setIsResizing,
|
|
@@ -17085,7 +17789,7 @@ var CommandFooterStyles = {
|
|
|
17085
17789
|
color: 'color.gray.500'
|
|
17086
17790
|
};
|
|
17087
17791
|
|
|
17088
|
-
var _excluded$
|
|
17792
|
+
var _excluded$10 = ["value", "onValueChange", "placeholder", "views"],
|
|
17089
17793
|
_excluded2$h = ["children", "views"],
|
|
17090
17794
|
_excluded3$c = ["heading", "children", "views"],
|
|
17091
17795
|
_excluded4$a = ["item", "selected", "onSelect", "views"],
|
|
@@ -17117,7 +17821,7 @@ var CommandInput = _ref2 => {
|
|
|
17117
17821
|
placeholder = 'Type a command or search...',
|
|
17118
17822
|
views
|
|
17119
17823
|
} = _ref2,
|
|
17120
|
-
props = _objectWithoutPropertiesLoose(_ref2, _excluded$
|
|
17824
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$10);
|
|
17121
17825
|
var inputRef = React.useRef(null);
|
|
17122
17826
|
// Focus input when component mounts
|
|
17123
17827
|
React__default.useEffect(() => {
|
|
@@ -17300,7 +18004,7 @@ var CommandView = _ref7 => {
|
|
|
17300
18004
|
})))), footer && (/*#__PURE__*/React__default.createElement(appStudio.View, Object.assign({}, CommandFooterStyles, views == null ? void 0 : views.footer), footer)))));
|
|
17301
18005
|
};
|
|
17302
18006
|
|
|
17303
|
-
var _excluded$
|
|
18007
|
+
var _excluded$11 = ["open", "onOpenChange", "groups", "commands", "placeholder", "size", "variant", "filter", "emptyState", "footer", "views"];
|
|
17304
18008
|
/**
|
|
17305
18009
|
* Command component for displaying a command palette with search functionality.
|
|
17306
18010
|
*/
|
|
@@ -17318,7 +18022,7 @@ var CommandComponent = _ref => {
|
|
|
17318
18022
|
footer,
|
|
17319
18023
|
views
|
|
17320
18024
|
} = _ref,
|
|
17321
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
18025
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$11);
|
|
17322
18026
|
var {
|
|
17323
18027
|
search,
|
|
17324
18028
|
setSearch,
|
|
@@ -17605,7 +18309,7 @@ var getArrowStyles = position => {
|
|
|
17605
18309
|
}
|
|
17606
18310
|
};
|
|
17607
18311
|
|
|
17608
|
-
var _excluded
|
|
18312
|
+
var _excluded$12 = ["children", "views", "asChild"],
|
|
17609
18313
|
_excluded2$i = ["children", "views"],
|
|
17610
18314
|
_excluded3$d = ["content", "children", "position", "align", "size", "variant", "showArrow", "views", "themeMode"];
|
|
17611
18315
|
// Create context for the Tooltip
|
|
@@ -17641,7 +18345,7 @@ var TooltipTrigger = _ref2 => {
|
|
|
17641
18345
|
views,
|
|
17642
18346
|
asChild = false
|
|
17643
18347
|
} = _ref2,
|
|
17644
|
-
props = _objectWithoutPropertiesLoose(_ref2, _excluded
|
|
18348
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$12);
|
|
17645
18349
|
var {
|
|
17646
18350
|
openTooltip,
|
|
17647
18351
|
closeTooltip,
|
|
@@ -17734,7 +18438,7 @@ var TooltipView = _ref4 => {
|
|
|
17734
18438
|
}, TooltipSizes[size], TooltipVariants[variant], positionStyles, views == null ? void 0 : views.content), typeof content === 'string' ? (/*#__PURE__*/React__default.createElement(appStudio.Text, Object.assign({}, views == null ? void 0 : views.text), content)) : content, showArrow && /*#__PURE__*/React__default.createElement(appStudio.View, Object.assign({}, arrowStyles, views == null ? void 0 : views.arrow)))));
|
|
17735
18439
|
};
|
|
17736
18440
|
|
|
17737
|
-
var _excluded$
|
|
18441
|
+
var _excluded$13 = ["content", "children", "position", "align", "size", "variant", "openDelay", "closeDelay", "showArrow", "defaultOpen", "isDisabled", "views"];
|
|
17738
18442
|
/**
|
|
17739
18443
|
* Tooltip component for displaying additional information when hovering over an element.
|
|
17740
18444
|
* Supports configurable positions, delays, and styling.
|
|
@@ -17754,7 +18458,7 @@ var TooltipComponent = _ref => {
|
|
|
17754
18458
|
isDisabled = false,
|
|
17755
18459
|
views
|
|
17756
18460
|
} = _ref,
|
|
17757
|
-
props = _objectWithoutPropertiesLoose(_ref, _excluded$
|
|
18461
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$13);
|
|
17758
18462
|
var tooltipState = useTooltipState({
|
|
17759
18463
|
defaultOpen,
|
|
17760
18464
|
openDelay,
|
|
@@ -17795,6 +18499,7 @@ exports.Card = Card;
|
|
|
17795
18499
|
exports.Carousel = Carousel;
|
|
17796
18500
|
exports.Chart = Chart;
|
|
17797
18501
|
exports.ChartIcon = ChartIcon;
|
|
18502
|
+
exports.CheckIcon = CheckIcon;
|
|
17798
18503
|
exports.Checkbox = Checkbox;
|
|
17799
18504
|
exports.ChevronIcon = ChevronIcon;
|
|
17800
18505
|
exports.ClockIcon = ClockIcon;
|
|
@@ -17804,6 +18509,7 @@ exports.CloudIcon = CloudIcon;
|
|
|
17804
18509
|
exports.ComboBox = ComboBox;
|
|
17805
18510
|
exports.Command = Command;
|
|
17806
18511
|
exports.ContextMenu = ContextMenu;
|
|
18512
|
+
exports.CookieConsent = CookieConsent;
|
|
17807
18513
|
exports.CopyIcon = CopyIcon;
|
|
17808
18514
|
exports.CountryPicker = CountryPicker;
|
|
17809
18515
|
exports.CropIcon = CropIcon;
|
|
@@ -17837,6 +18543,7 @@ exports.FormikSlider = FormikSlider;
|
|
|
17837
18543
|
exports.FormikSwitch = FormikSwitch;
|
|
17838
18544
|
exports.FormikTextArea = FormikTextArea;
|
|
17839
18545
|
exports.FormikTextField = FormikTextField;
|
|
18546
|
+
exports.GiftIcon = GiftIcon;
|
|
17840
18547
|
exports.HeartIcon = HeartIcon;
|
|
17841
18548
|
exports.HelpIcon = HelpIcon;
|
|
17842
18549
|
exports.HomeIcon = HomeIcon;
|
|
@@ -17882,6 +18589,7 @@ exports.Separator = Separator;
|
|
|
17882
18589
|
exports.SettingsIcon = SettingsIcon;
|
|
17883
18590
|
exports.ShapeIcon = ShapeIcon;
|
|
17884
18591
|
exports.ShareIcon = ShareIcon;
|
|
18592
|
+
exports.ShieldIcon = ShieldIcon;
|
|
17885
18593
|
exports.Sidebar = Sidebar;
|
|
17886
18594
|
exports.Slider = Slider;
|
|
17887
18595
|
exports.SliderIcon = SliderIcon;
|
|
@@ -17898,6 +18606,7 @@ exports.TextField = TextField;
|
|
|
17898
18606
|
exports.TextIcon = TextIcon;
|
|
17899
18607
|
exports.ThreadsIcon = ThreadsIcon;
|
|
17900
18608
|
exports.TickIcon = TickIcon;
|
|
18609
|
+
exports.Title = Title;
|
|
17901
18610
|
exports.Toast = Toast;
|
|
17902
18611
|
exports.Toggle = Toggle;
|
|
17903
18612
|
exports.ToggleGroup = ToggleGroup;
|