se-design 1.0.62 → 1.0.63-dev
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/assets/icons/ai-off.svg +4 -4
- package/dist/assets/style.css +1 -1
- package/dist/components/Banner/index.d.ts +1 -0
- package/dist/components/Checkbox/index.d.ts +5 -0
- package/dist/components/InfoTooltip/index.d.ts +1 -5
- package/dist/index182.js +5 -5
- package/dist/index22.js +66 -65
- package/dist/index22.js.map +1 -1
- package/dist/index224.js +1 -1
- package/dist/index225.js +1 -1
- package/dist/index226.js +21 -9
- package/dist/index226.js.map +1 -1
- package/dist/index227.js +18 -9
- package/dist/index227.js.map +1 -1
- package/dist/index228.js +9 -4
- package/dist/index228.js.map +1 -1
- package/dist/index229.js +10 -170
- package/dist/index229.js.map +1 -1
- package/dist/index230.js +5 -11
- package/dist/index230.js.map +1 -1
- package/dist/index231.js +170 -22
- package/dist/index231.js.map +1 -1
- package/dist/index232.js +11 -19
- package/dist/index232.js.map +1 -1
- package/dist/index29.js +38 -36
- package/dist/index29.js.map +1 -1
- package/dist/index60.js +39 -45
- package/dist/index60.js.map +1 -1
- package/dist/index71.js +1 -1
- package/dist/index71.js.map +1 -1
- package/package.json +1 -1
package/dist/index60.js
CHANGED
|
@@ -1,60 +1,54 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { Popover as
|
|
1
|
+
import i, { useState as p, useCallback as v, useEffect as E } from "react";
|
|
2
|
+
import { Popover as y } from "./index18.js";
|
|
3
3
|
/* empty css */
|
|
4
|
-
function
|
|
5
|
-
return
|
|
6
|
-
for (var
|
|
7
|
-
var
|
|
8
|
-
for (var e in
|
|
4
|
+
function d() {
|
|
5
|
+
return d = Object.assign ? Object.assign.bind() : function(n) {
|
|
6
|
+
for (var o = 1; o < arguments.length; o++) {
|
|
7
|
+
var t = arguments[o];
|
|
8
|
+
for (var e in t) ({}).hasOwnProperty.call(t, e) && (n[e] = t[e]);
|
|
9
9
|
}
|
|
10
|
-
return
|
|
11
|
-
},
|
|
10
|
+
return n;
|
|
11
|
+
}, d.apply(null, arguments);
|
|
12
12
|
}
|
|
13
|
-
const
|
|
14
|
-
label:
|
|
15
|
-
children:
|
|
16
|
-
iconColor:
|
|
17
|
-
|
|
18
|
-
isDisabled: r = !1,
|
|
13
|
+
const w = ({
|
|
14
|
+
label: n,
|
|
15
|
+
children: o,
|
|
16
|
+
iconColor: t = "var(--color-blue-500)",
|
|
17
|
+
isDisabled: e = !1,
|
|
19
18
|
noPadding: u = !1
|
|
20
19
|
}) => {
|
|
21
|
-
const [
|
|
22
|
-
|
|
20
|
+
const [f, r] = p(!1), [m, s] = p(!1), l = f || m, c = v((a) => {
|
|
21
|
+
a.key === "Escape" && (r(!1), s(!1), a.stopImmediatePropagation());
|
|
23
22
|
}, []);
|
|
24
|
-
|
|
25
|
-
if (
|
|
26
|
-
return document.addEventListener("keydown",
|
|
27
|
-
}, [
|
|
28
|
-
const
|
|
29
|
-
onMouseEnter: () =>
|
|
30
|
-
onMouseLeave: () =>
|
|
31
|
-
onFocus: (
|
|
32
|
-
|
|
33
|
-
},
|
|
34
|
-
onBlur: () => i(!1)
|
|
23
|
+
E(() => {
|
|
24
|
+
if (l)
|
|
25
|
+
return document.addEventListener("keydown", c), () => document.removeEventListener("keydown", c);
|
|
26
|
+
}, [l, c]);
|
|
27
|
+
const g = {
|
|
28
|
+
onMouseEnter: () => r(!0),
|
|
29
|
+
onMouseLeave: () => r(!1),
|
|
30
|
+
onFocus: () => s(!0),
|
|
31
|
+
onBlur: () => s(!1)
|
|
35
32
|
};
|
|
36
|
-
return /* @__PURE__ */
|
|
37
|
-
className:
|
|
38
|
-
},
|
|
33
|
+
return /* @__PURE__ */ i.createElement("div", d({
|
|
34
|
+
className: e ? "se-design-info-tooltip-wrapper-disabled" : ""
|
|
35
|
+
}, e ? {} : g), /* @__PURE__ */ i.createElement(y, {
|
|
39
36
|
position: "bottom-center",
|
|
40
|
-
isPopoverOpen:
|
|
41
|
-
onPopoverToggle: (
|
|
42
|
-
|
|
37
|
+
isPopoverOpen: l,
|
|
38
|
+
onPopoverToggle: (a) => {
|
|
39
|
+
a || (r(!1), s(!1));
|
|
43
40
|
},
|
|
44
|
-
renderPopoverSrcElement: () => /* @__PURE__ */
|
|
45
|
-
className: `se-design-info-tooltip-src ${u ? "no-padding" : ""} ${
|
|
41
|
+
renderPopoverSrcElement: () => /* @__PURE__ */ i.createElement("div", {
|
|
42
|
+
className: `se-design-info-tooltip-src ${u ? "no-padding" : ""} ${e ? "se-design-info-tooltip-disabled" : ""}`,
|
|
46
43
|
style: {
|
|
47
|
-
"--info-tooltip-icon-color":
|
|
48
|
-
|
|
49
|
-
"--info-tooltip-hover-bg": e
|
|
50
|
-
} : {},
|
|
51
|
-
cursor: r ? "not-allowed" : "pointer"
|
|
44
|
+
"--info-tooltip-icon-color": t,
|
|
45
|
+
cursor: e ? "not-allowed" : "pointer"
|
|
52
46
|
}
|
|
53
|
-
},
|
|
54
|
-
renderPopoverContents: () => /* @__PURE__ */
|
|
47
|
+
}, o),
|
|
48
|
+
renderPopoverContents: () => /* @__PURE__ */ i.createElement("div", {
|
|
55
49
|
className: "se-design-info-tooltip-content",
|
|
56
50
|
"data-automation-id": "se-design-info-tooltip-content"
|
|
57
|
-
},
|
|
51
|
+
}, n),
|
|
58
52
|
isWithPortal: !0,
|
|
59
53
|
noBorder: !0,
|
|
60
54
|
disableClickToggle: !0,
|
|
@@ -65,6 +59,6 @@ const I = ({
|
|
|
65
59
|
}));
|
|
66
60
|
};
|
|
67
61
|
export {
|
|
68
|
-
|
|
62
|
+
w as InfoTooltip
|
|
69
63
|
};
|
|
70
64
|
//# sourceMappingURL=index60.js.map
|
package/dist/index60.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index60.js","sources":["../src/components/InfoTooltip/index.tsx"],"sourcesContent":["import React, { useState, useEffect, useCallback } from 'react';\nimport { Popover } from '../Popover';\nimport './styles.scss';\n\nexport interface InfoTooltipProps {\n label: string;\n children: React.ReactNode;\n iconColor?: string;\n
|
|
1
|
+
{"version":3,"file":"index60.js","sources":["../src/components/InfoTooltip/index.tsx"],"sourcesContent":["import React, { useState, useEffect, useCallback } from 'react';\nimport { Popover } from '../Popover';\nimport './styles.scss';\n\nexport interface InfoTooltipProps {\n label: string;\n children: React.ReactNode;\n iconColor?: string;\n isDisabled?: boolean;\n /**\n * Remove padding from tooltip wrapper (useful for precise alignment)\n */\n noPadding?: boolean;\n}\n\nexport const InfoTooltip = ({\n label,\n children,\n iconColor = 'var(--color-blue-500)',\n isDisabled = false,\n noPadding = false\n}: InfoTooltipProps) => {\n const [isHovered, setIsHovered] = useState(false);\n const [isFocused, setIsFocused] = useState(false);\n\n // Show tooltip on hover OR focus (for keyboard accessibility)\n const isOpen = isHovered || isFocused;\n\n // Global Escape key handler (W3C WAI-ARIA tooltip pattern requirement)\n const handleEscapeKey = useCallback((event: KeyboardEvent) => {\n if (event.key === 'Escape') {\n setIsHovered(false);\n setIsFocused(false);\n // Prevent other handlers (e.g., modal) from also closing - \"innermost first\" pattern\n event.stopImmediatePropagation();\n }\n }, []);\n\n useEffect(() => {\n if (isOpen) {\n document.addEventListener('keydown', handleEscapeKey);\n return () => document.removeEventListener('keydown', handleEscapeKey);\n }\n }, [isOpen, handleEscapeKey]);\n\n const interactionHandlers = {\n onMouseEnter: () => setIsHovered(true),\n onMouseLeave: () => setIsHovered(false),\n onFocus: () => setIsFocused(true),\n onBlur: () => setIsFocused(false)\n };\n\n return (\n <div\n className={isDisabled ? 'se-design-info-tooltip-wrapper-disabled' : ''}\n {...(isDisabled ? {} : interactionHandlers)}\n >\n <Popover\n position={'bottom-center'}\n isPopoverOpen={isOpen}\n onPopoverToggle={(open) => {\n // Sync popover state changes (e.g., Escape key) back to component state\n if (!open) {\n setIsHovered(false);\n setIsFocused(false);\n }\n }}\n renderPopoverSrcElement={() => (\n <div\n className={`se-design-info-tooltip-src ${noPadding ? 'no-padding' : ''} ${isDisabled ? 'se-design-info-tooltip-disabled' : ''}`}\n style={\n {\n '--info-tooltip-icon-color': iconColor,\n cursor: isDisabled ? 'not-allowed' : 'pointer'\n } as React.CSSProperties\n }\n >\n {children}\n </div>\n )}\n renderPopoverContents={() => (\n <div className=\"se-design-info-tooltip-content\" data-automation-id=\"se-design-info-tooltip-content\">\n {label}\n </div>\n )}\n isWithPortal\n noBorder\n disableClickToggle\n popoverContentStyleProperty={{\n zIndex: 2000,\n backgroundColor: ''\n }}\n />\n </div>\n );\n};\n"],"names":["InfoTooltip","label","children","iconColor","isDisabled","noPadding","isHovered","setIsHovered","useState","isFocused","setIsFocused","isOpen","handleEscapeKey","useCallback","event","key","stopImmediatePropagation","useEffect","document","addEventListener","removeEventListener","interactionHandlers","onMouseEnter","onMouseLeave","onFocus","onBlur","React","createElement","_extends","className","Popover","position","isPopoverOpen","onPopoverToggle","open","renderPopoverSrcElement","style","cursor","renderPopoverContents","isWithPortal","noBorder","disableClickToggle","popoverContentStyleProperty","zIndex","backgroundColor"],"mappings":";;;;;;;;;;;;AAeO,MAAMA,IAAcA,CAAC;AAAA,EAC1BC,OAAAA;AAAAA,EACAC,UAAAA;AAAAA,EACAC,WAAAA,IAAY;AAAA,EACZC,YAAAA,IAAa;AAAA,EACbC,WAAAA,IAAY;AACI,MAAM;AACtB,QAAM,CAACC,GAAWC,CAAY,IAAIC,EAAS,EAAK,GAC1C,CAACC,GAAWC,CAAY,IAAIF,EAAS,EAAK,GAG1CG,IAASL,KAAaG,GAGtBG,IAAkBC,EAAY,CAACC,MAAyB;AAC5D,IAAIA,EAAMC,QAAQ,aAChBR,EAAa,EAAK,GAClBG,EAAa,EAAK,GAElBI,EAAME,yBAAAA;AAAAA,EAEV,GAAG,CAAA,CAAE;AAELC,EAAAA,EAAU,MAAM;AACd,QAAIN;AACFO,sBAASC,iBAAiB,WAAWP,CAAe,GAC7C,MAAMM,SAASE,oBAAoB,WAAWR,CAAe;AAAA,EAExE,GAAG,CAACD,GAAQC,CAAe,CAAC;AAE5B,QAAMS,IAAsB;AAAA,IAC1BC,cAAcA,MAAMf,EAAa,EAAI;AAAA,IACrCgB,cAAcA,MAAMhB,EAAa,EAAK;AAAA,IACtCiB,SAASA,MAAMd,EAAa,EAAI;AAAA,IAChCe,QAAQA,MAAMf,EAAa,EAAK;AAAA,EAAA;AAGlC,SACEgB,gBAAAA,EAAAC,cAAA,OAAAC,EAAA;AAAA,IACEC,WAAWzB,IAAa,4CAA4C;AAAA,EAAA,GAC/DA,IAAa,CAAA,IAAKiB,CAAmB,GAE1CK,gBAAAA,EAAAC,cAACG,GAAO;AAAA,IACNC,UAAU;AAAA,IACVC,eAAerB;AAAAA,IACfsB,iBAAkBC,CAAAA,MAAS;AAEzB,MAAKA,MACH3B,EAAa,EAAK,GAClBG,EAAa,EAAK;AAAA,IAEtB;AAAA,IACAyB,yBAAyBA,MACvBT,gBAAAA,EAAAC,cAAA,OAAA;AAAA,MACEE,WAAW,8BAA8BxB,IAAY,eAAe,EAAE,IAAID,IAAa,oCAAoC,EAAE;AAAA,MAC7HgC,OACE;AAAA,QACE,6BAA6BjC;AAAAA,QAC7BkC,QAAQjC,IAAa,gBAAgB;AAAA,MAAA;AAAA,IACvC,GAGDF,CACE;AAAA,IAEPoC,uBAAuBA,MACrBZ,gBAAAA,EAAAC,cAAA,OAAA;AAAA,MAAKE,WAAU;AAAA,MAAiC,sBAAmB;AAAA,IAAA,GAChE5B,CACE;AAAA,IAEPsC,cAAY;AAAA,IACZC,UAAQ;AAAA,IACRC,oBAAkB;AAAA,IAClBC,6BAA6B;AAAA,MAC3BC,QAAQ;AAAA,MACRC,iBAAiB;AAAA,IAAA;AAAA,EACnB,CACD,CACE;AAET;"}
|
package/dist/index71.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const L = "data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3crect%20width='32'%20height='32'%20rx='16'%20fill='
|
|
1
|
+
const L = "data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3crect%20width='32'%20height='32'%20rx='16'%20fill='%233A91DA'/%3e%3cpath%20d='M11.0179%2013.3597L12.27%2010.855L13.5222%2013.3597C13.9204%2014.1563%2014.5662%2014.8021%2015.3627%2015.2004L17.8682%2016.4531L15.3627%2017.7059C14.5662%2018.1041%2013.9204%2018.75%2013.5222%2019.5465L12.27%2022.0513L11.0179%2019.5465C10.6197%2018.75%209.97387%2018.1041%209.17738%2017.7059L6.67188%2016.4531L9.17738%2015.2004C9.97387%2014.8021%2010.6197%2014.1563%2011.0179%2013.3597Z'%20fill='%23CFE7FA'/%3e%3cpath%20d='M19.0178%207.18859L19.4704%206.2832L19.923%207.18859C20.3212%207.98511%2020.967%208.63098%2021.7635%209.02923L22.6694%209.48215L21.7635%209.93506C20.967%2010.3333%2020.3212%2010.9792%2019.923%2011.7757L19.4704%2012.6811L19.0178%2011.7757C18.6196%2010.9792%2017.9738%2010.3333%2017.1773%209.93506L16.2715%209.48215L17.1773%209.02923C17.9738%208.63098%2018.6196%207.98511%2019.0178%207.18859Z'%20fill='%23CFE7FA'/%3e%3cpath%20d='M19.0178%2021.3561L19.4704%2020.4507L19.923%2021.3561C20.3212%2022.1526%2020.967%2022.7985%2021.7635%2023.1967L22.6694%2023.6496L21.7635%2024.1025C20.967%2024.5008%2020.3212%2025.1467%2019.923%2025.9432L19.4704%2026.8486L19.0178%2025.9432C18.6196%2025.1467%2017.9738%2024.5008%2017.1773%2024.1025L16.2715%2023.6496L17.1773%2023.1967C17.9738%2022.7985%2018.6196%2022.1526%2019.0178%2021.3561Z'%20fill='%23CFE7FA'/%3e%3c/svg%3e";
|
|
2
2
|
export {
|
|
3
3
|
L as default
|
|
4
4
|
};
|
package/dist/index71.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index71.js","sources":["../src/assets/icons/ai-off.svg?url"],"sourcesContent":["export default \"data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3crect%20width='32'%20height='32'%20rx='16'%20fill='
|
|
1
|
+
{"version":3,"file":"index71.js","sources":["../src/assets/icons/ai-off.svg?url"],"sourcesContent":["export default \"data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3crect%20width='32'%20height='32'%20rx='16'%20fill='%233A91DA'/%3e%3cpath%20d='M11.0179%2013.3597L12.27%2010.855L13.5222%2013.3597C13.9204%2014.1563%2014.5662%2014.8021%2015.3627%2015.2004L17.8682%2016.4531L15.3627%2017.7059C14.5662%2018.1041%2013.9204%2018.75%2013.5222%2019.5465L12.27%2022.0513L11.0179%2019.5465C10.6197%2018.75%209.97387%2018.1041%209.17738%2017.7059L6.67188%2016.4531L9.17738%2015.2004C9.97387%2014.8021%2010.6197%2014.1563%2011.0179%2013.3597Z'%20fill='%23CFE7FA'/%3e%3cpath%20d='M19.0178%207.18859L19.4704%206.2832L19.923%207.18859C20.3212%207.98511%2020.967%208.63098%2021.7635%209.02923L22.6694%209.48215L21.7635%209.93506C20.967%2010.3333%2020.3212%2010.9792%2019.923%2011.7757L19.4704%2012.6811L19.0178%2011.7757C18.6196%2010.9792%2017.9738%2010.3333%2017.1773%209.93506L16.2715%209.48215L17.1773%209.02923C17.9738%208.63098%2018.6196%207.98511%2019.0178%207.18859Z'%20fill='%23CFE7FA'/%3e%3cpath%20d='M19.0178%2021.3561L19.4704%2020.4507L19.923%2021.3561C20.3212%2022.1526%2020.967%2022.7985%2021.7635%2023.1967L22.6694%2023.6496L21.7635%2024.1025C20.967%2024.5008%2020.3212%2025.1467%2019.923%2025.9432L19.4704%2026.8486L19.0178%2025.9432C18.6196%2025.1467%2017.9738%2024.5008%2017.1773%2024.1025L16.2715%2023.6496L17.1773%2023.1967C17.9738%2022.7985%2018.6196%2022.1526%2019.0178%2021.3561Z'%20fill='%23CFE7FA'/%3e%3c/svg%3e\""],"names":["__vite_glob_0_0"],"mappings":"AAAA,MAAAA,IAAe;"}
|