@fluidattacks/design 3.1.11 → 3.1.12
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/_commonjsHelpers-C6fGbg64.mjs +6 -0
- package/dist/components/@core/index.js +18 -1
- package/dist/components/accordion/accordion-content/index.js +9 -1
- package/dist/components/accordion/index.js +21 -1
- package/dist/components/alert/index.js +111 -4
- package/dist/components/button/index.js +18 -1
- package/dist/components/card/card-header/index.js +14 -1
- package/dist/components/card/card-with-image/index.js +18 -1
- package/dist/components/card/card-with-input/index.js +57 -3
- package/dist/components/card/card-with-selector/index.js +16 -1
- package/dist/components/card/card-with-switch/index.js +12 -1
- package/dist/components/card/index.js +12 -1
- package/dist/components/carousel/index.js +36 -10
- package/dist/components/checkbox/index.js +84 -3
- package/dist/components/cloud-image/index.js +8 -1
- package/dist/components/code-snippet/index.js +27 -1
- package/dist/components/code-snippet/location-code/index.js +125 -1
- package/dist/components/colors/index.js +9 -1
- package/dist/components/confirm-dialog/index.js +23 -1
- package/dist/components/container/index.js +27 -3
- package/dist/components/content-card/category-tag/index.js +13 -1
- package/dist/components/content-card/event-date/index.js +18 -1
- package/dist/components/content-card/index.js +63 -3
- package/dist/components/content-card-carousel/index.js +15 -1
- package/dist/components/content-card-carousel/scroll-buttons/index.js +9 -1
- package/dist/components/divider/index.js +10 -1
- package/dist/components/empty-state/empty-button/index.js +6 -1
- package/dist/components/empty-state/index.js +21 -8
- package/dist/components/file-preview/index.js +15 -3
- package/dist/components/form/index.js +26 -3
- package/dist/components/grid-container/index.js +26 -5
- package/dist/components/group-selector/index.js +26 -1
- package/dist/components/group-selector/option-container/index.js +12 -1
- package/dist/components/icon/index.js +42 -4
- package/dist/components/icon-button/index.js +27 -3
- package/dist/components/indicator-card/index.js +15 -1
- package/dist/components/info-sidebar/index.js +16 -1
- package/dist/components/inputs/fields/combobox/index.js +26 -1
- package/dist/components/inputs/fields/combobox/option/index.js +8 -1
- package/dist/components/inputs/fields/date/calendar/cell/index.js +16 -1
- package/dist/components/inputs/fields/date/calendar/grid/index.js +15 -1
- package/dist/components/inputs/fields/date/calendar/header/index.js +16 -1
- package/dist/components/inputs/fields/date/calendar/index.js +15 -1
- package/dist/components/inputs/fields/date/index.js +18 -1
- package/dist/components/inputs/fields/date-range/calendar/index.js +16 -1
- package/dist/components/inputs/fields/date-range/index.js +28 -3
- package/dist/components/inputs/fields/date-time/calendar/index.js +31 -5
- package/dist/components/inputs/fields/date-time/index.js +18 -1
- package/dist/components/inputs/fields/editable/index.js +16 -1
- package/dist/components/inputs/fields/input/index.js +13 -1
- package/dist/components/inputs/fields/input-file/index.js +24 -4
- package/dist/components/inputs/fields/input-tags/index.js +14 -2
- package/dist/components/inputs/fields/number/index.js +10 -1
- package/dist/components/inputs/fields/number-range/index.js +11 -1
- package/dist/components/inputs/fields/phone/index.js +414 -11
- package/dist/components/inputs/fields/text-area/index.js +13 -1
- package/dist/components/inputs/index.js +28 -1
- package/dist/components/inputs/label/index.js +12 -1
- package/dist/components/inputs/outline-container/index.js +18 -1
- package/dist/components/inputs/utils/action-button/index.js +10 -1
- package/dist/components/inputs/utils/calendar-button/index.js +13 -1
- package/dist/components/inputs/utils/date-selector/index.js +8 -1
- package/dist/components/inputs/utils/date-time-field/index.js +32 -1
- package/dist/components/inputs/utils/dialog/index.js +11 -1
- package/dist/components/inputs/utils/number-field/index.js +13 -1
- package/dist/components/inputs/utils/popover/index.js +13 -1
- package/dist/components/interactive-card/icon/index.js +7 -1
- package/dist/components/interactive-card/index.js +15 -1
- package/dist/components/language-selector/index.js +13 -1
- package/dist/components/language-selector/item-list/index.js +8 -1
- package/dist/components/link/index.js +52 -7
- package/dist/components/list-item/index.js +16 -1
- package/dist/components/little-flag/index.js +15 -3
- package/dist/components/loading/index.js +28 -14
- package/dist/components/logo/index.js +7 -1
- package/dist/components/logo-carousel/index.js +10 -4
- package/dist/components/lottie/index.js +15 -3
- package/dist/components/menu/index.js +23 -1
- package/dist/components/message-banner/index.js +21 -4
- package/dist/components/modal/index.js +19 -1
- package/dist/components/modal/modal-confirm/index.js +10 -1
- package/dist/components/modal/modal-footer/index.js +16 -1
- package/dist/components/modal/modal-header/index.js +25 -1
- package/dist/components/notification/index.js +68 -5
- package/dist/components/notification-sign/index.js +26 -6
- package/dist/components/number-input/index.js +25 -7
- package/dist/components/oauth-selector/index.js +26 -1
- package/dist/components/oauth-selector/option-container/index.js +15 -1
- package/dist/components/plan-card/index.js +84 -5
- package/dist/components/plan-card/recommended-tag/index.js +10 -1
- package/dist/components/pop-up/description/index.js +13 -1
- package/dist/components/pop-up/index.js +23 -1
- package/dist/components/premium-feature/index.js +45 -3
- package/dist/components/priority-score/index.js +14 -1
- package/dist/components/progress/index.js +23 -3
- package/dist/components/progress-bar/index.js +95 -5
- package/dist/components/radio-button/index.js +88 -3
- package/dist/components/scroll-button/index.js +20 -2
- package/dist/components/search/index.js +63 -7
- package/dist/components/search-bar/index.js +32 -1
- package/dist/components/search-bar/item-searching/index.js +10 -1
- package/dist/components/severity-badge/index.js +14 -1
- package/dist/components/severity-overview/badge/index.js +18 -1
- package/dist/components/severity-overview/index.js +7 -1
- package/dist/components/show-on-hover/index.js +25 -3
- package/dist/components/slide-out-menu/index.js +2009 -3
- package/dist/components/slide-out-menu/menu-item/index.js +15 -1
- package/dist/components/slider/index.js +93 -7
- package/dist/components/slider/thumb/index.js +10 -1
- package/dist/components/step-lapse/index.js +95 -9
- package/dist/components/table-button/index.js +56 -3
- package/dist/components/tabs/fixed-tabs/index.js +9 -1
- package/dist/components/tabs/index.js +14 -1
- package/dist/components/tabs/tab/index.js +8 -1
- package/dist/components/tag/index.js +116 -3
- package/dist/components/timeline/card/index.js +9 -1
- package/dist/components/timeline/index.js +7 -1
- package/dist/components/toggle/index.js +45 -14
- package/dist/components/toggle-buttons/index.js +74 -5
- package/dist/components/tooltip/index.js +13 -1
- package/dist/components/tour/index.js +2481 -4
- package/dist/components/typography/heading/index.js +9 -1
- package/dist/components/typography/index.js +8 -1
- package/dist/components/typography/span/index.js +9 -1
- package/dist/components/typography/text/index.js +9 -1
- package/dist/components/web-form/index.js +59 -7
- package/dist/hooks/index.js +13 -1
- package/dist/index-38JqtnAI.mjs +122 -0
- package/dist/index-B5yoGFs6.mjs +54 -0
- package/dist/index-BLbKylyw.mjs +209 -0
- package/dist/{index-C0_LPuYU.mjs → index-Bu448Tz2.mjs} +22 -22
- package/dist/index-BwFnfaRh.mjs +2310 -0
- package/dist/index-Co_k0WFk.mjs +75 -0
- package/dist/index-Cu7uUMlx.mjs +82 -0
- package/dist/index-D-lcuEHY.mjs +1018 -0
- package/dist/index-DrfjITyT.mjs +61 -0
- package/dist/index.js +206 -1
- package/dist/styles-7_q7nHce.mjs +110 -0
- package/dist/styles-BA0WIQL-.mjs +74 -0
- package/dist/styles-C3cZmKVJ.mjs +131 -0
- package/dist/styles-CI-I6joH.mjs +144 -0
- package/dist/styles-Cx93EcVo.mjs +76 -0
- package/dist/styles-D85YYIjM.mjs +131 -0
- package/dist/styles-EIbGRPlk.mjs +106 -0
- package/dist/styles-Q1VXuWI7.mjs +65 -0
- package/dist/styles-fH2c4cfc.mjs +77 -0
- package/dist/{styles-BAhpqi6C.mjs → styles-lSVV9kjn.mjs} +28 -28
- package/dist/use-carousel-CvRxi2FI.mjs +17 -0
- package/dist/use-click-outside-BtZLIoU1.mjs +18 -0
- package/dist/use-cloudinary-image-fG7ODNgr.mjs +611 -0
- package/dist/use-modal-CkrZ-_-M.mjs +14 -0
- package/dist/use-search-DpLNvt7Q.mjs +12 -0
- package/dist/utils-CQvBF-wY.mjs +4 -0
- package/package.json +1 -1
- package/dist/_commonjsHelpers-C37NGDzP.js +0 -1
- package/dist/_commonjsHelpers-D6CrkqQz.mjs +0 -6
- package/dist/index-BH27NQKA.mjs +0 -2311
- package/dist/index-Bcw2vW_n.mjs +0 -75
- package/dist/index-C8zdgAVH.mjs +0 -82
- package/dist/index-CA_9DXWd.js +0 -5
- package/dist/index-CmylnDrF.js +0 -14
- package/dist/index-DUMgwAbO.js +0 -26
- package/dist/index-DpQYiwGu.js +0 -5
- package/dist/index-Dy8ZUIYs.js +0 -5
- package/dist/index-JPf5Yzg6.js +0 -17
- package/dist/index-OBZtKZuT.mjs +0 -1021
- package/dist/index-SsXlDjK4.mjs +0 -122
- package/dist/index-TKLFHcRp.js +0 -18
- package/dist/index-TnyKqJHo.mjs +0 -61
- package/dist/index-Yr95Cb7Z.mjs +0 -54
- package/dist/index-h9-U5wxq.mjs +0 -209
- package/dist/index-qCiUU4sZ.js +0 -9
- package/dist/index-qe0nJwzl.js +0 -15
- package/dist/styles--Elze-LV.js +0 -3
- package/dist/styles-3pR4Xdvy.js +0 -33
- package/dist/styles-59h91S9m.mjs +0 -65
- package/dist/styles-BCwLWpC3.mjs +0 -126
- package/dist/styles-BJ7-0I5X.mjs +0 -74
- package/dist/styles-BKObp9bh.mjs +0 -76
- package/dist/styles-BWVdbvFu.js +0 -5
- package/dist/styles-Bl-CstrT.js +0 -5
- package/dist/styles-Bn42XCW5.js +0 -7
- package/dist/styles-C2CoGJl7.js +0 -33
- package/dist/styles-CNzziAXG.js +0 -5
- package/dist/styles-CdD9waPD.js +0 -29
- package/dist/styles-CnKTwnFk.mjs +0 -110
- package/dist/styles-D4R-eerv.mjs +0 -77
- package/dist/styles-DNIIhyRC.mjs +0 -144
- package/dist/styles-DV8yOaqV.mjs +0 -131
- package/dist/styles-DYoftbd3.js +0 -42
- package/dist/styles-DlmKLhPh.js +0 -7
- package/dist/styles-be8gOdgy.mjs +0 -106
- package/dist/use-carousel-64dKFW4E.js +0 -1
- package/dist/use-carousel-D7xeL3YZ.mjs +0 -17
- package/dist/use-click-outside-BqkLISED.js +0 -1
- package/dist/use-click-outside-C4Z4pdiW.mjs +0 -18
- package/dist/use-cloudinary-image-DKMl7jbx.mjs +0 -612
- package/dist/use-cloudinary-image-YMMafagv.js +0 -1
- package/dist/use-modal-CNbLSSQb.mjs +0 -14
- package/dist/use-modal-_bYY6M_n.js +0 -1
- package/dist/use-search-75ip5xR-.mjs +0 -12
- package/dist/use-search-DeL4UDMh.js +0 -1
- package/dist/utils-C2whpEd3.js +0 -1
- package/dist/utils-Da0qL35u.mjs +0 -4
|
@@ -1,5 +1,95 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
import { jsxs as h, jsx as l } from "react/jsx-runtime";
|
|
2
|
+
import { styled as p } from "styled-components";
|
|
3
|
+
import { v as g } from "../../utils-CQvBF-wY.mjs";
|
|
4
|
+
import "../../styles-C3cZmKVJ.mjs";
|
|
5
|
+
import { Container as d } from "../container/index.js";
|
|
6
|
+
import "../typography/heading/index.js";
|
|
7
|
+
import "../typography/span/index.js";
|
|
8
|
+
import { Text as $ } from "../typography/text/index.js";
|
|
9
|
+
const { getVariant: m } = g((n) => ({ compliance: `
|
|
10
|
+
display: inline-flex;
|
|
11
|
+
|
|
12
|
+
&.horizontal {
|
|
13
|
+
height: ${n.spacing[0.75]};
|
|
14
|
+
}
|
|
15
|
+
&.vertical {
|
|
16
|
+
width: ${n.spacing[0.75]};
|
|
17
|
+
}
|
|
18
|
+
`, default: `
|
|
19
|
+
display: inline-flex;
|
|
20
|
+
|
|
21
|
+
&.horizontal {
|
|
22
|
+
height: ${n.spacing[0.5]};
|
|
23
|
+
}
|
|
24
|
+
&.vertical {
|
|
25
|
+
width: ${n.spacing[0.5]};
|
|
26
|
+
}
|
|
27
|
+
.progress-bar {
|
|
28
|
+
background-color: ${n.palette.primary[500]};
|
|
29
|
+
}
|
|
30
|
+
`, progressIndicator: `
|
|
31
|
+
display: flex;
|
|
32
|
+
|
|
33
|
+
&.horizontal {
|
|
34
|
+
height: ${n.spacing[0.125]};
|
|
35
|
+
}
|
|
36
|
+
&.vertical {
|
|
37
|
+
width: ${n.spacing[0.125]};
|
|
38
|
+
}
|
|
39
|
+
.progress-bar {
|
|
40
|
+
background-color: ${n.palette.primary[500]};
|
|
41
|
+
}
|
|
42
|
+
`, progressIndicatorError: `
|
|
43
|
+
display: flex;
|
|
44
|
+
|
|
45
|
+
&.horizontal {
|
|
46
|
+
height: ${n.spacing[0.125]};
|
|
47
|
+
}
|
|
48
|
+
&.vertical {
|
|
49
|
+
width: ${n.spacing[0.125]};
|
|
50
|
+
}
|
|
51
|
+
.progress-bar {
|
|
52
|
+
background-color: ${n.palette.error[200]};
|
|
53
|
+
}
|
|
54
|
+
`, small: `
|
|
55
|
+
color: ${n.palette.primary[500]};
|
|
56
|
+
display: inline-flex;
|
|
57
|
+
|
|
58
|
+
&.horizontal {
|
|
59
|
+
height: ${n.spacing[0.25]};
|
|
60
|
+
}
|
|
61
|
+
&.vertical {
|
|
62
|
+
width: ${n.spacing[0.25]};
|
|
63
|
+
}
|
|
64
|
+
.progress-bar {
|
|
65
|
+
background-color: ${n.palette.primary[500]};
|
|
66
|
+
}
|
|
67
|
+
` })), u = p.div`
|
|
68
|
+
${({ theme: n, $minWidth: r, $orientation: e, $rounded: t, $variant: i }) => `
|
|
69
|
+
background-color: ${n.palette.gray[100]};
|
|
70
|
+
border-radius: ${t ? "100px" : "unset"};
|
|
71
|
+
${e === "horizontal" ? "min-width" : "min-height"}: ${r}px;
|
|
72
|
+
${e === "horizontal" ? "" : "height: 100%;"}
|
|
73
|
+
|
|
74
|
+
${m(n, i)}
|
|
75
|
+
|
|
76
|
+
`}
|
|
77
|
+
`, x = p.div`
|
|
78
|
+
${({ theme: n, $percentage: r, $rounded: e, $variant: t }) => `
|
|
79
|
+
display: inline-flex;
|
|
80
|
+
width: ${r}%;
|
|
81
|
+
max-width: 100%;
|
|
82
|
+
min-width: 0%;
|
|
83
|
+
height: 100%;
|
|
84
|
+
border-radius: ${e ? "100px" : "unset"};
|
|
85
|
+
border-end-end-radius: ${e && r < 100 ? "0" : "inherit"};
|
|
86
|
+
border-start-end-radius: ${e && r < 100 ? "0" : "inherit"};
|
|
87
|
+
background-color: ${t === "compliance" ? ((i, a) => a < 50 ? i.palette.error[500] : a < 80 ? i.palette.warning[500] : i.palette.success[500])(n, r) : "inherit"};
|
|
88
|
+
`}
|
|
89
|
+
`, I = ({ minWidth: n = 100, percentage: r, percentageLocation: e = "right", showPercentage: t = !1, orientation: i = "horizontal", rounded: a = !0, variant: s = "default" }) => {
|
|
90
|
+
const o = t && e === "left", c = t ? l(d, { alignItems: "center", display: "flex", justify: o ? "flex-end" : "flex-start", width: "40px", children: l($, { ml: 0.5, mr: o ? 0.5 : 0, size: "sm", children: `${r}%` }) }) : null;
|
|
91
|
+
return h(d, { alignItems: "center", display: "inline-flex", flexDirection: o ? "row-reverse" : "row", height: i === "horizontal" ? "auto" : "100%", maxWidth: o ? `${n + 43}px` : void 0, minWidth: o ? `${n + 43}px` : void 0, textAlign: "end", children: [l(u, { $minWidth: n, $orientation: i, $rounded: a, $variant: s, className: i, children: l(x, { $percentage: r, $rounded: a, $variant: s, className: "progress-bar" }) }), c] });
|
|
92
|
+
};
|
|
93
|
+
export {
|
|
94
|
+
I as ProgressBar
|
|
95
|
+
};
|
|
@@ -1,3 +1,88 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { jsxs as s, jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as h } from "react";
|
|
3
|
+
import { styled as r } from "styled-components";
|
|
4
|
+
const k = r.label`
|
|
5
|
+
${({ theme: n }) => `
|
|
6
|
+
align-items: center;
|
|
7
|
+
display: flex;
|
|
8
|
+
color: ${n.palette.gray[600]};
|
|
9
|
+
cursor: pointer;
|
|
10
|
+
font-family: ${n.typography.type.primary};
|
|
11
|
+
font-size: ${n.typography.text.sm};
|
|
12
|
+
font-weight: ${n.typography.weight.regular};
|
|
13
|
+
gap: ${n.spacing[0.5]};
|
|
14
|
+
line-height: ${n.typography.text.lg};
|
|
15
|
+
text-align: left;
|
|
16
|
+
position: relative;
|
|
17
|
+
|
|
18
|
+
&[aria-disabled="true"] {
|
|
19
|
+
color: ${n.palette.gray[300]};
|
|
20
|
+
cursor: not-allowed;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
input {
|
|
24
|
+
position: absolute;
|
|
25
|
+
opacity: 0;
|
|
26
|
+
cursor: pointer;
|
|
27
|
+
width: 0;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.checkmark {
|
|
31
|
+
position: relative;
|
|
32
|
+
top: 0;
|
|
33
|
+
left: 0;
|
|
34
|
+
height: 16px;
|
|
35
|
+
width: 16px;
|
|
36
|
+
background-color: ${n.palette.white};
|
|
37
|
+
border-radius: 50%;
|
|
38
|
+
border: 1px solid ${n.palette.gray[600]};
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
input:disabled ~ .checkmark {
|
|
42
|
+
border: 1px solid ${n.palette.gray[300]};
|
|
43
|
+
background-color: ${n.palette.white};
|
|
44
|
+
cursor: not-allowed;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
input:not(:disabled):checked ~ .checkmark {
|
|
48
|
+
background-color: ${n.palette.white};
|
|
49
|
+
border: 1px solid ${n.palette.primary[500]};
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
input:not(:disabled):hover ~ .checkmark {
|
|
53
|
+
background-color: ${n.palette.white};
|
|
54
|
+
box-shadow: 0 0 0 4px ${n.palette.gray[100]};
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
input:not(:disabled):hover:checked ~ .checkmark {
|
|
58
|
+
background-color: ${n.palette.white};
|
|
59
|
+
box-shadow: 0 0 0 4px ${n.palette.primary[50]};
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.checkmark::after {
|
|
63
|
+
content: "";
|
|
64
|
+
position: absolute;
|
|
65
|
+
display: none;
|
|
66
|
+
top: 3px;
|
|
67
|
+
left: 3px;
|
|
68
|
+
width: 8px;
|
|
69
|
+
height: 8px;
|
|
70
|
+
border-radius: 50%;
|
|
71
|
+
background: ${n.palette.primary[500]};
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
input:checked ~ .checkmark::after {
|
|
75
|
+
display: block;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
input:disabled:checked ~ .checkmark::after {
|
|
79
|
+
background-color: ${n.palette.gray[300]};
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
`}
|
|
83
|
+
`, u = r.span.attrs({ className: "checkmark" })``, y = h(function({ defaultChecked: n = !1, disabled: e = !1, label: o, name: a, onChange: i, onClick: l, value: p, ...d }, c) {
|
|
84
|
+
return s(k, { "aria-disabled": e, "aria-label": a, role: "radiogroup", children: [t("input", { "aria-checked": n, "aria-disabled": e, "aria-label": a, defaultChecked: n, disabled: e, name: a, onChange: i, onClick: l, ref: c, type: "radio", value: p, ...d }), t(u, {}), o ?? null] });
|
|
85
|
+
});
|
|
86
|
+
export {
|
|
87
|
+
y as RadioButton
|
|
88
|
+
};
|
|
@@ -1,6 +1,24 @@
|
|
|
1
|
-
|
|
1
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { useState as l, useEffect as a, useCallback as m } from "react";
|
|
3
|
+
import { styled as d } from "styled-components";
|
|
4
|
+
import { IconButton as p } from "../icon-button/index.js";
|
|
5
|
+
const u = d.div.attrs({ className: "comp-scroll-up" })`
|
|
2
6
|
bottom: 15px;
|
|
3
7
|
position: fixed;
|
|
4
8
|
right: 140px;
|
|
5
9
|
z-index: 100;
|
|
6
|
-
|
|
10
|
+
`, v = ({ scrollerId: t = "dashboard", visibleAt: s = 500 }) => {
|
|
11
|
+
const [e, i] = l(!1), [o, c] = l(null);
|
|
12
|
+
a(() => {
|
|
13
|
+
c(document.getElementById(t)), o == null || o.addEventListener("scroll", () => {
|
|
14
|
+
i(o.scrollTop > s);
|
|
15
|
+
});
|
|
16
|
+
}, [o, t, s]);
|
|
17
|
+
const n = m(() => {
|
|
18
|
+
o == null || o.scrollTo({ behavior: "smooth", top: 0 });
|
|
19
|
+
}, [o]);
|
|
20
|
+
return e ? r(u, { children: r(p, { height: "40px", icon: "arrow-up", iconSize: "sm", id: "scroll-up", onClick: n, width: "40px" }) }) : null;
|
|
21
|
+
};
|
|
22
|
+
export {
|
|
23
|
+
v as ScrollUpButton
|
|
24
|
+
};
|
|
@@ -1,7 +1,63 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
import { jsxs as l, jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import { u } from "../../index-D-lcuEHY.mjs";
|
|
3
|
+
import { isEmpty as x } from "lodash";
|
|
4
|
+
import { forwardRef as $, useState as b, useCallback as v, Fragment as w } from "react";
|
|
5
|
+
import { styled as r, useTheme as k } from "styled-components";
|
|
6
|
+
import { Icon as S } from "../icon/index.js";
|
|
7
|
+
import { IconButton as p } from "../icon-button/index.js";
|
|
8
|
+
import { u as z } from "../../use-click-outside-BtZLIoU1.mjs";
|
|
9
|
+
const C = r.input`
|
|
10
|
+
${({ theme: e }) => `
|
|
11
|
+
background: none;
|
|
12
|
+
border: none !important;
|
|
13
|
+
box-shadow: none;
|
|
14
|
+
box-sizing: border-box;
|
|
15
|
+
color: ${e.palette.gray[800]};
|
|
16
|
+
font-family: ${e.typography.type.primary};
|
|
17
|
+
font-size: ${e.typography.text.sm};
|
|
18
|
+
outline: none;
|
|
19
|
+
width: 100%;
|
|
20
|
+
|
|
21
|
+
&::placeholder {
|
|
22
|
+
color: ${e.palette.gray[400]};
|
|
23
|
+
}
|
|
24
|
+
`}
|
|
25
|
+
`, T = r.div`
|
|
26
|
+
${({ theme: e }) => `
|
|
27
|
+
align-items: center;
|
|
28
|
+
background-color: ${e.palette.white};
|
|
29
|
+
border: 1px solid ${e.palette.gray[300]};
|
|
30
|
+
border-radius: ${e.spacing[0.5]};
|
|
31
|
+
display: flex;
|
|
32
|
+
height: 40px;
|
|
33
|
+
gap: ${e.spacing[0.5]};
|
|
34
|
+
padding: ${e.spacing[0.5]};
|
|
35
|
+
width: 100%;
|
|
36
|
+
|
|
37
|
+
&:hover {
|
|
38
|
+
border-color: ${e.palette.gray[600]};
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
&:focus-within {
|
|
42
|
+
border: 2px solid ${e.palette.black};
|
|
43
|
+
}
|
|
44
|
+
`}
|
|
45
|
+
`, j = r.div`
|
|
46
|
+
${({ theme: e }) => `
|
|
47
|
+
background-color: ${e.palette.white};
|
|
48
|
+
border-radius: ${e.spacing[0.5]};
|
|
49
|
+
width: 250px;
|
|
50
|
+
`}
|
|
51
|
+
`, G = $(function({ name: e, smallSearch: c = !1, value: a, ...g }, m) {
|
|
52
|
+
const o = k(), [d, i] = b(!1), { refs: t, floatingStyles: f } = u(), h = v(() => {
|
|
53
|
+
i((y) => !y);
|
|
54
|
+
}, []);
|
|
55
|
+
z(t.floating.current, () => {
|
|
56
|
+
i(!1);
|
|
57
|
+
}, !0);
|
|
58
|
+
const s = l(T, { children: [n(S, { icon: "magnifying-glass", iconColor: o.palette.gray[700], iconSize: "xs", iconType: "fa-light" }), n(C, { ...g, id: e, name: e, ref: m, value: a }), !x(a) && n(p, { icon: "xmark", iconColor: o.palette.gray[300], iconSize: "xs", iconType: "fa-light", px: 0.25, py: 0.25, type: "reset", variant: "ghost" })] });
|
|
59
|
+
return c ? l(w, { children: [n(p, { border: `1px solid ${o.palette.gray[300]} !important`, icon: "magnifying-glass", iconSize: "xs", iconType: "fa-light", onClick: h, ref: t.setReference, variant: "ghost" }), d ? n(j, { ref: t.setFloating, style: f, children: s }) : void 0] }) : s;
|
|
60
|
+
});
|
|
61
|
+
export {
|
|
62
|
+
G as Search
|
|
63
|
+
};
|
|
@@ -1 +1,32 @@
|
|
|
1
|
-
|
|
1
|
+
import { jsxs as i, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { useState as y, useRef as S, useCallback as l } from "react";
|
|
3
|
+
import { S as D, a as H, b as W, c as j, d as m, I as p } from "../../index-BLbKylyw.mjs";
|
|
4
|
+
import { Button as A } from "../button/index.js";
|
|
5
|
+
import { M as B } from "../../index-BwFnfaRh.mjs";
|
|
6
|
+
import { theme as f } from "../colors/index.js";
|
|
7
|
+
import { Icon as z } from "../icon/index.js";
|
|
8
|
+
import { Heading as R } from "../typography/heading/index.js";
|
|
9
|
+
import "../typography/span/index.js";
|
|
10
|
+
import { Text as h } from "../typography/text/index.js";
|
|
11
|
+
import { u as q } from "../../use-click-outside-BtZLIoU1.mjs";
|
|
12
|
+
const F = [{ hit: { slug: "/services/continuous-hacking/", title: "Continuous Hacking" }, icon: "infinity" }, { hit: { slug: "/platform/", title: "Platform" }, icon: "sidebar" }, { hit: { slug: "/plans/", title: "Plans" }, icon: "star-christmas" }, { hit: { slug: "/blog/", title: "Blog" }, icon: "pen-line" }], C = { hit: { slug: "/contact-us/", title: "Contact Support" }, icon: "envelope" }, Y = ({ items: n, placeholder: b = "Search", refine: d, query: v }) => {
|
|
13
|
+
const [o, k] = y(v), [w, u] = y(!1), g = S(null), a = S(null), s = o.length >= 2, r = l((t) => {
|
|
14
|
+
k(t), d(t);
|
|
15
|
+
}, [d]), c = l(() => {
|
|
16
|
+
r("");
|
|
17
|
+
}, [r]), I = l(() => {
|
|
18
|
+
u(!0);
|
|
19
|
+
}, []), N = l((t) => {
|
|
20
|
+
r(t.currentTarget.value);
|
|
21
|
+
}, [r]), P = l((t) => {
|
|
22
|
+
t.preventDefault(), t.stopPropagation(), c(), a.current && a.current.focus();
|
|
23
|
+
}, [c]), $ = l((t) => {
|
|
24
|
+
t.preventDefault(), t.stopPropagation(), a.current && a.current.blur();
|
|
25
|
+
}, []);
|
|
26
|
+
return q(g.current, () => {
|
|
27
|
+
c(), u(!1);
|
|
28
|
+
}, !0), i(D, { ref: g, children: [i(H, { action: "", noValidate: !0, onReset: P, onSubmit: $, role: "search", children: [i("div", { className: "flex gap-2 w-full", children: [e("div", { className: "h-10 p-2", children: e(z, { icon: "magnifying-glass", iconSize: "sm", iconType: "fa-light" }) }), e(W, { autoCapitalize: "off", autoComplete: "off", autoCorrect: "off", maxLength: 512, onChange: N, onFocus: I, placeholder: b, ref: a, spellCheck: !1, type: "search", value: o })] }), s && e(j, { type: "reset", children: e(z, { icon: "xmark", iconSize: "sm", iconType: "fa-light" }) })] }), w && o.length < 2 && i(m, { children: [e(h, { color: f.palette.gray[400], fontWeight: "bold", lineSpacing: 1.5, size: "md", sizeSm: "sm", children: "Suggested" }), e("div", { className: "flex flex-col items-start self-stretch", children: F.map(({ hit: t, icon: x }, T) => e(p, { hit: t, icon: x, showIcon: !0 }, `${x}-${T}`)) }), e(h, { color: f.palette.gray[400], fontWeight: "bold", lineSpacing: 1.5, size: "md", sizeSm: "sm", children: "Can’t find what you’re looking for?" }), e(p, { hit: C.hit, icon: C.icon, showIcon: !0 })] }), s && n.length > 0 && i(m, { $showHits: s, children: [e(h, { color: f.palette.gray[400], fontWeight: "bold", lineSpacing: 1.5, size: "md", sizeSm: "sm", children: "Results" }), e("div", { className: "flex flex-col items-start self-stretch", children: n.map((t) => e(p, { hit: t }, t.objectID)) })] }), s && n.length === 0 && e(m, { $empty: n.length === 0, children: i("div", { className: "items-center flex flex-col gap-4 py-[90px] w-full", children: [e(B, { height: 96, publicId: "airs/search-bar/empty-state-icon", width: 96 }), e(R, { display: "flex", size: "sm", sizeSm: "xs", textAlign: "center", children: "No results found" }), i(h, { display: "flex", lineSpacing: 1.5, size: "md", sizeSm: "sm", textAlign: "center", children: [`“${o}” did not match.`, e("br", {}), "Please try again."] }), e(A, { onClick: c, variant: "secondary", children: "Clear search" })] }) })] });
|
|
29
|
+
};
|
|
30
|
+
export {
|
|
31
|
+
Y as SearchBar
|
|
32
|
+
};
|
|
@@ -1 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
import "react/jsx-runtime";
|
|
2
|
+
import { I } from "../../../index-BLbKylyw.mjs";
|
|
3
|
+
import "../../colors/index.js";
|
|
4
|
+
import "../../icon/index.js";
|
|
5
|
+
import "../../typography/heading/index.js";
|
|
6
|
+
import "../../typography/span/index.js";
|
|
7
|
+
import "../../typography/text/index.js";
|
|
8
|
+
export {
|
|
9
|
+
I as ItemSearching
|
|
10
|
+
};
|
|
@@ -1 +1,14 @@
|
|
|
1
|
-
|
|
1
|
+
import { jsxs as d, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { useTheme as n } from "styled-components";
|
|
3
|
+
import { theme as e } from "../colors/index.js";
|
|
4
|
+
import { Container as l } from "../container/index.js";
|
|
5
|
+
import "../typography/heading/index.js";
|
|
6
|
+
import "../typography/span/index.js";
|
|
7
|
+
import { Text as a } from "../typography/text/index.js";
|
|
8
|
+
const x = { critical: { bgColor: e.palette.primary[700], colorL: e.palette.gray[800], colorR: e.palette.white }, disable: { bgColor: e.palette.gray[200], colorL: e.palette.gray[400], colorR: e.palette.gray[400] }, high: { bgColor: e.palette.error[500], colorL: e.palette.gray[800], colorR: e.palette.white }, low: { bgColor: e.palette.warning[200], colorL: e.palette.gray[800], colorR: e.palette.gray[800] }, medium: { bgColor: e.palette.warning[500], colorL: e.palette.gray[800], colorR: e.palette.gray[800] } }, L = ({ textL: r, textR: p, variant: i }) => {
|
|
9
|
+
const s = n(), { bgColor: t, colorL: c, colorR: g } = x[i];
|
|
10
|
+
return d(l, { alignItems: "flex-start", display: "inline-flex", children: [r ? o(l, { alignItems: "center", bgColor: s.palette.white, border: `1px solid ${t}`, borderRadius: "4px 0px 0px 4px", display: "flex", justify: "center", padding: [0, 0.25, 0, 0.25], children: o(a, { color: c, size: "xs", children: r }) }) : void 0, o(l, { alignItems: "center", bgColor: t, border: `1px solid ${t}`, borderRadius: r ? "0px 4px 4px 0px" : "4px", display: "flex", padding: r ? [0, 0.25, 0, 0.125] : [0, 0.25, 0, 0.25], pb: 0.125, pl: 0.125, pr: 0.125, pt: 0.125, children: o(a, { color: g, size: "xs", children: p }) })] });
|
|
11
|
+
};
|
|
12
|
+
export {
|
|
13
|
+
L as SeverityBadge
|
|
14
|
+
};
|
|
@@ -1 +1,18 @@
|
|
|
1
|
-
|
|
1
|
+
import { jsxs as f, jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { capitalize as m } from "lodash";
|
|
3
|
+
import { theme as e } from "../../colors/index.js";
|
|
4
|
+
import { Container as s } from "../../container/index.js";
|
|
5
|
+
import { T as C } from "../../../index-D-lcuEHY.mjs";
|
|
6
|
+
import "../../typography/heading/index.js";
|
|
7
|
+
import "../../typography/span/index.js";
|
|
8
|
+
import { Text as d } from "../../typography/text/index.js";
|
|
9
|
+
const j = ({ variant: r, value: a }) => {
|
|
10
|
+
const { iconColor: x, iconText: h, iconTextColor: g, textColor: y } = ((i, o) => {
|
|
11
|
+
const l = { critical: e.palette.primary[700], high: e.palette.error[500], low: e.palette.warning[200], medium: e.palette.warning[500], none: e.palette.gray[200] }, p = { disabled: e.palette.gray[400], enabled: e.palette.gray[800] }, c = { critical: e.palette.white, high: e.palette.white, low: e.palette.gray[800], medium: e.palette.gray[800], none: e.palette.gray[400] };
|
|
12
|
+
return { iconColor: o < 1 ? l.none : l[i], iconText: m(i.charAt(0)), iconTextColor: o < 1 ? c.none : c[i], textColor: o < 1 ? p.disabled : p.enabled };
|
|
13
|
+
})(r, a), n = m(r.charAt(0)) + r.slice(1);
|
|
14
|
+
return f(s, { alignItems: "center", display: "inline-flex", gap: 0.5, minWidth: "43px", children: [t(C, { id: n, place: "top", tip: n, children: t(s, { alignItems: "center", bgColor: x, borderRadius: "4px", cursor: "pointer", display: "flex", height: "22px", maxWidth: "22px", minWidth: "22px", children: t(d, { color: g, size: "sm", textAlign: "center", children: h }) }) }), t(d, { color: y, size: "sm", children: a })] });
|
|
15
|
+
};
|
|
16
|
+
export {
|
|
17
|
+
j as SeverityOverviewBadge
|
|
18
|
+
};
|
|
@@ -1 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
import { jsxs as l, jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import { SeverityOverviewBadge as a } from "./badge/index.js";
|
|
3
|
+
import { Container as n } from "../container/index.js";
|
|
4
|
+
const c = ({ critical: e, high: r, medium: t, low: v }) => l(n, { alignItems: "center", display: "inline-flex", gap: 1, children: [i(a, { value: e, variant: "critical" }), i(a, { value: r, variant: "high" }), i(a, { value: t, variant: "medium" }), i(a, { value: v, variant: "low" })] });
|
|
5
|
+
export {
|
|
6
|
+
c as SeverityOverview
|
|
7
|
+
};
|
|
@@ -1,3 +1,25 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { jsxs as o, jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import { styled as r } from "styled-components";
|
|
3
|
+
import { Container as s } from "../container/index.js";
|
|
4
|
+
const t = r.div`
|
|
5
|
+
${({ theme: n }) => `
|
|
6
|
+
border-radius: ${n.spacing[0.25]};
|
|
7
|
+
cursor: pointer;
|
|
8
|
+
display: flex;
|
|
9
|
+
gap: ${n.spacing[0.5]};
|
|
10
|
+
justify-content: end;
|
|
11
|
+
position: relative;
|
|
12
|
+
z-index: 20;
|
|
13
|
+
|
|
14
|
+
&:hover {
|
|
15
|
+
background-color: ${n.palette.gray[100]};
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
&:hover > div {
|
|
19
|
+
display: block;
|
|
20
|
+
}
|
|
21
|
+
`}
|
|
22
|
+
`, p = ({ visibleElement: n, hiddenElement: e }) => o(t, { children: [n, i(s, { display: "none", position: "absolute", top: "100%", zIndex: 10, children: e })] });
|
|
23
|
+
export {
|
|
24
|
+
p as ShowOnHover
|
|
25
|
+
};
|