@trackunit/react-components 0.1.124 → 0.1.126
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/051071830dacb5a2.svg +36 -0
- package/143a6e982b3d1ec9.svg +59 -0
- package/8df3d27593b5fba4.svg +70 -0
- package/building_error.cjs +181 -0
- package/building_error.js +159 -0
- package/index.cjs +98 -37
- package/index.js +99 -39
- package/package.json +1 -1
- package/road_block.cjs +244 -0
- package/road_block.js +222 -0
- package/src/components/EmptyState/EmptyState.d.ts +29 -0
- package/src/components/EmptyState/EmptyState.variants.d.ts +2 -0
- package/src/components/EmptyState/images/index.d.ts +4 -0
- package/src/components/index.d.ts +1 -0
- package/wall_construction.cjs +308 -0
- package/wall_construction.js +286 -0
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { forwardRef } from 'react';
|
|
3
|
+
|
|
4
|
+
var _path, _path2, _path3, _path4, _path5, _path6, _path7, _path8, _path9, _path10, _path11, _path12, _path13, _path14, _path15, _path16, _path17, _path18, _path19, _path20, _path21;
|
|
5
|
+
var _excluded = ["title", "titleId"];
|
|
6
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
7
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
8
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
9
|
+
var SvgBuildingError = (_ref, ref) => {
|
|
10
|
+
var {
|
|
11
|
+
title,
|
|
12
|
+
titleId
|
|
13
|
+
} = _ref,
|
|
14
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
15
|
+
return /*#__PURE__*/React.createElement("svg", _extends({
|
|
16
|
+
width: 200,
|
|
17
|
+
height: 200,
|
|
18
|
+
viewBox: "0 0 200 200",
|
|
19
|
+
fill: "none",
|
|
20
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
21
|
+
ref: ref,
|
|
22
|
+
"aria-labelledby": titleId
|
|
23
|
+
}, props), title ? /*#__PURE__*/React.createElement("title", {
|
|
24
|
+
id: titleId
|
|
25
|
+
}, title) : null, _path || (_path = /*#__PURE__*/React.createElement("path", {
|
|
26
|
+
d: "M101.922 194C146.105 194 181.922 158.183 181.922 114C181.922 69.8172 146.105 34 101.922 34C57.7391 34 21.9219 69.8172 21.9219 114C21.9219 158.183 57.7391 194 101.922 194Z",
|
|
27
|
+
fill: "#F1F5F9"
|
|
28
|
+
})), _path2 || (_path2 = /*#__PURE__*/React.createElement("path", {
|
|
29
|
+
d: "M80.2002 54C80.2002 54.5304 79.9895 55.0391 79.6144 55.4142C79.2393 55.7893 78.7306 56 78.2002 56H66.2002C65.6698 56 65.1611 55.7893 64.786 55.4142C64.4109 55.0391 64.2002 54.5304 64.2002 54V48H80.2002V54Z",
|
|
30
|
+
fill: "#E2E8F0",
|
|
31
|
+
stroke: "#334155",
|
|
32
|
+
strokeWidth: 2,
|
|
33
|
+
strokeLinecap: "round",
|
|
34
|
+
strokeLinejoin: "round"
|
|
35
|
+
})), _path3 || (_path3 = /*#__PURE__*/React.createElement("path", {
|
|
36
|
+
d: "M50.208 92L72.208 76L94.208 92H50.208Z",
|
|
37
|
+
stroke: "#334155",
|
|
38
|
+
strokeWidth: 2,
|
|
39
|
+
strokeLinecap: "round",
|
|
40
|
+
strokeLinejoin: "round"
|
|
41
|
+
})), _path4 || (_path4 = /*#__PURE__*/React.createElement("path", {
|
|
42
|
+
d: "M72.208 76C74.4171 76 76.208 74.2091 76.208 72C76.208 69.7909 74.4171 68 72.208 68C69.9989 68 68.208 69.7909 68.208 72C68.208 74.2091 69.9989 76 72.208 76Z",
|
|
43
|
+
fill: "white",
|
|
44
|
+
stroke: "#334155",
|
|
45
|
+
strokeWidth: 2,
|
|
46
|
+
strokeLinecap: "round",
|
|
47
|
+
strokeLinejoin: "round"
|
|
48
|
+
})), _path5 || (_path5 = /*#__PURE__*/React.createElement("path", {
|
|
49
|
+
d: "M72.208 56V68",
|
|
50
|
+
stroke: "#334155",
|
|
51
|
+
strokeWidth: 2,
|
|
52
|
+
strokeLinecap: "round",
|
|
53
|
+
strokeLinejoin: "round"
|
|
54
|
+
})), _path6 || (_path6 = /*#__PURE__*/React.createElement("path", {
|
|
55
|
+
d: "M133.922 187.342C138.101 185.517 142.116 183.336 145.922 180.824V48H133.922V187.342Z",
|
|
56
|
+
fill: "white"
|
|
57
|
+
})), _path7 || (_path7 = /*#__PURE__*/React.createElement("path", {
|
|
58
|
+
d: "M145.922 180.824V48H133.922V187.342",
|
|
59
|
+
stroke: "#334155",
|
|
60
|
+
strokeWidth: 2,
|
|
61
|
+
strokeLinecap: "round",
|
|
62
|
+
strokeLinejoin: "round"
|
|
63
|
+
})), _path8 || (_path8 = /*#__PURE__*/React.createElement("path", {
|
|
64
|
+
d: "M133.922 48L145.922 60L133.922 72L145.922 84L133.922 96L145.922 108L133.922 120L145.922 132L133.922 144L145.922 156L133.922 168L145.922 180",
|
|
65
|
+
stroke: "#334155",
|
|
66
|
+
strokeWidth: 2,
|
|
67
|
+
strokeLinecap: "round",
|
|
68
|
+
strokeLinejoin: "round"
|
|
69
|
+
})), _path9 || (_path9 = /*#__PURE__*/React.createElement("path", {
|
|
70
|
+
d: "M146.208 20H134.208V36H146.208V20Z",
|
|
71
|
+
fill: "white",
|
|
72
|
+
stroke: "#334155",
|
|
73
|
+
strokeWidth: 2,
|
|
74
|
+
strokeLinecap: "round",
|
|
75
|
+
strokeLinejoin: "round"
|
|
76
|
+
})), _path10 || (_path10 = /*#__PURE__*/React.createElement("path", {
|
|
77
|
+
d: "M26.6219 48C26.424 48 26.2306 47.9412 26.0661 47.8312C25.9016 47.7212 25.7735 47.5649 25.6979 47.382C25.6223 47.1991 25.6027 46.998 25.6415 46.8039C25.6803 46.6099 25.7758 46.4317 25.9159 46.292L36.1999 36H168.2V48H26.6219Z",
|
|
78
|
+
fill: "white",
|
|
79
|
+
stroke: "#334155",
|
|
80
|
+
strokeWidth: 2,
|
|
81
|
+
strokeLinecap: "round",
|
|
82
|
+
strokeLinejoin: "round"
|
|
83
|
+
})), _path11 || (_path11 = /*#__PURE__*/React.createElement("path", {
|
|
84
|
+
d: "M146.208 20L140.208 6L134.208 20H146.208Z",
|
|
85
|
+
fill: "white",
|
|
86
|
+
stroke: "#334155",
|
|
87
|
+
strokeWidth: 2,
|
|
88
|
+
strokeLinecap: "round",
|
|
89
|
+
strokeLinejoin: "round"
|
|
90
|
+
})), _path12 || (_path12 = /*#__PURE__*/React.createElement("path", {
|
|
91
|
+
d: "M182.2 46C182.2 46.5304 181.989 47.0391 181.614 47.4142C181.239 47.7893 180.73 48 180.2 48H168.2V36C168.2 35.4696 168.41 34.9609 168.785 34.5858C169.161 34.2107 169.669 34 170.2 34H182.2V46Z",
|
|
92
|
+
fill: "#E2E8F0",
|
|
93
|
+
stroke: "#334155",
|
|
94
|
+
strokeWidth: 2,
|
|
95
|
+
strokeLinecap: "round",
|
|
96
|
+
strokeLinejoin: "round"
|
|
97
|
+
})), _path13 || (_path13 = /*#__PURE__*/React.createElement("path", {
|
|
98
|
+
d: "M60.208 36L140.208 6L182.208 34",
|
|
99
|
+
stroke: "#334155",
|
|
100
|
+
strokeWidth: 2,
|
|
101
|
+
strokeLinecap: "round",
|
|
102
|
+
strokeLinejoin: "round"
|
|
103
|
+
})), _path14 || (_path14 = /*#__PURE__*/React.createElement("path", {
|
|
104
|
+
d: "M146.208 20L134.208 33.836",
|
|
105
|
+
stroke: "#334155",
|
|
106
|
+
strokeWidth: 2,
|
|
107
|
+
strokeLinecap: "round",
|
|
108
|
+
strokeLinejoin: "round"
|
|
109
|
+
})), _path15 || (_path15 = /*#__PURE__*/React.createElement("path", {
|
|
110
|
+
d: "M36.208 36L48.208 48L60.208 36L72.208 48L84.208 36L96.208 48L108.208 36L120.208 48L132.208 36L144.208 48L156.208 36L168.208 48",
|
|
111
|
+
stroke: "#334155",
|
|
112
|
+
strokeWidth: 2,
|
|
113
|
+
strokeLinecap: "round",
|
|
114
|
+
strokeLinejoin: "round"
|
|
115
|
+
})), _path16 || (_path16 = /*#__PURE__*/React.createElement("path", {
|
|
116
|
+
d: "M118.14 92H23.992C20.5678 92 17.792 94.7758 17.792 98.2V165.494C17.792 168.918 20.5678 171.694 23.992 171.694H118.14C121.564 171.694 124.34 168.918 124.34 165.494V98.2C124.34 94.7758 121.564 92 118.14 92Z",
|
|
117
|
+
fill: "#E2E8F0",
|
|
118
|
+
stroke: "#334155",
|
|
119
|
+
strokeWidth: 2,
|
|
120
|
+
strokeLinecap: "round",
|
|
121
|
+
strokeLinejoin: "round"
|
|
122
|
+
})), _path17 || (_path17 = /*#__PURE__*/React.createElement("path", {
|
|
123
|
+
d: "M118.14 92H23.9996C22.3553 92 20.7783 92.6532 19.6156 93.8159C18.4528 94.9787 17.7996 96.5557 17.7996 98.2V106.75H124.34V98.2C124.34 96.5557 123.686 94.9787 122.524 93.8159C121.361 92.6532 119.784 92 118.14 92Z",
|
|
124
|
+
fill: "white",
|
|
125
|
+
stroke: "#334155",
|
|
126
|
+
strokeWidth: 2,
|
|
127
|
+
strokeLinecap: "round",
|
|
128
|
+
strokeLinejoin: "round"
|
|
129
|
+
})), _path18 || (_path18 = /*#__PURE__*/React.createElement("path", {
|
|
130
|
+
d: "M27.0922 102.436C28.8043 102.436 30.1922 101.048 30.1922 99.3361C30.1922 97.624 28.8043 96.2361 27.0922 96.2361C25.3801 96.2361 23.9922 97.624 23.9922 99.3361C23.9922 101.048 25.3801 102.436 27.0922 102.436Z",
|
|
131
|
+
fill: "#E2E8F0",
|
|
132
|
+
stroke: "#334155",
|
|
133
|
+
strokeWidth: 2,
|
|
134
|
+
strokeLinejoin: "round"
|
|
135
|
+
})), _path19 || (_path19 = /*#__PURE__*/React.createElement("path", {
|
|
136
|
+
d: "M37.8002 102.436C39.5123 102.436 40.9002 101.048 40.9002 99.3361C40.9002 97.624 39.5123 96.2361 37.8002 96.2361C36.0881 96.2361 34.7002 97.624 34.7002 99.3361C34.7002 101.048 36.0881 102.436 37.8002 102.436Z",
|
|
137
|
+
fill: "#E2E8F0",
|
|
138
|
+
stroke: "#334155",
|
|
139
|
+
strokeWidth: 2,
|
|
140
|
+
strokeLinejoin: "round"
|
|
141
|
+
})), _path20 || (_path20 = /*#__PURE__*/React.createElement("path", {
|
|
142
|
+
d: "M48.5058 102.436C50.2178 102.436 51.6058 101.048 51.6058 99.3361C51.6058 97.624 50.2178 96.2361 48.5058 96.2361C46.7937 96.2361 45.4058 97.624 45.4058 99.3361C45.4058 101.048 46.7937 102.436 48.5058 102.436Z",
|
|
143
|
+
fill: "#E2E8F0",
|
|
144
|
+
stroke: "#334155",
|
|
145
|
+
strokeWidth: 2,
|
|
146
|
+
strokeLinejoin: "round"
|
|
147
|
+
})), _path21 || (_path21 = /*#__PURE__*/React.createElement("path", {
|
|
148
|
+
d: "M82.5722 154.45C81.8565 154.451 81.1478 154.31 80.4869 154.036C79.8261 153.761 79.2262 153.358 78.7222 152.85L71.0662 145.2L63.4002 152.854C62.8944 153.359 62.2941 153.76 61.6335 154.034C60.9728 154.307 60.2648 154.448 59.5498 154.448C58.1057 154.447 56.721 153.873 55.7002 152.852C54.6794 151.831 54.1061 150.446 54.1064 149.002C54.1068 147.558 54.6808 146.173 55.7022 145.152L63.3582 137.498L55.7022 129.842C54.6808 128.821 54.1068 127.436 54.1064 125.992C54.1061 124.548 54.6794 123.163 55.7002 122.142C56.721 121.121 58.1057 120.547 59.5498 120.546C60.9938 120.546 62.3788 121.119 63.4002 122.14L71.0662 129.8L78.7222 122.142C79.2252 121.624 79.8261 121.212 80.49 120.928C81.1538 120.645 81.8674 120.496 82.5892 120.491C83.311 120.486 84.0266 120.625 84.6944 120.899C85.3623 121.172 85.969 121.576 86.4793 122.087C86.9897 122.597 87.3934 123.204 87.6671 123.872C87.9409 124.54 88.0791 125.256 88.0738 125.977C88.0685 126.699 87.9197 127.413 87.6362 128.076C87.3526 128.74 86.94 129.341 86.4222 129.844L78.7662 137.5L86.4222 145.154C87.1831 145.916 87.7013 146.886 87.9111 147.942C88.1209 148.999 88.0131 150.093 87.6011 151.088C87.1891 152.083 86.4916 152.934 85.5965 153.532C84.7014 154.131 83.649 154.449 82.5722 154.45Z",
|
|
149
|
+
fill: "white",
|
|
150
|
+
stroke: "#334155",
|
|
151
|
+
strokeWidth: 2,
|
|
152
|
+
strokeLinecap: "round",
|
|
153
|
+
strokeLinejoin: "round"
|
|
154
|
+
})));
|
|
155
|
+
};
|
|
156
|
+
var ForwardRef = /*#__PURE__*/forwardRef(SvgBuildingError);
|
|
157
|
+
var building_error = "data:image/svg+xml,%3Csvg%20width%3D%22200%22%20height%3D%22200%22%20viewBox%3D%220%200%20200%20200%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M101.922%20194C146.105%20194%20181.922%20158.183%20181.922%20114C181.922%2069.8172%20146.105%2034%20101.922%2034C57.7391%2034%2021.9219%2069.8172%2021.9219%20114C21.9219%20158.183%2057.7391%20194%20101.922%20194Z%22%20fill%3D%22%23F1F5F9%22%2F%3E%3Cpath%20d%3D%22M80.2002%2054C80.2002%2054.5304%2079.9895%2055.0391%2079.6144%2055.4142C79.2393%2055.7893%2078.7306%2056%2078.2002%2056H66.2002C65.6698%2056%2065.1611%2055.7893%2064.786%2055.4142C64.4109%2055.0391%2064.2002%2054.5304%2064.2002%2054V48H80.2002V54Z%22%20fill%3D%22%23E2E8F0%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M50.208%2092L72.208%2076L94.208%2092H50.208Z%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M72.208%2076C74.4171%2076%2076.208%2074.2091%2076.208%2072C76.208%2069.7909%2074.4171%2068%2072.208%2068C69.9989%2068%2068.208%2069.7909%2068.208%2072C68.208%2074.2091%2069.9989%2076%2072.208%2076Z%22%20fill%3D%22white%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M72.208%2056V68%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M133.922%20187.342C138.101%20185.517%20142.116%20183.336%20145.922%20180.824V48H133.922V187.342Z%22%20fill%3D%22white%22%2F%3E%3Cpath%20d%3D%22M145.922%20180.824V48H133.922V187.342%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M133.922%2048L145.922%2060L133.922%2072L145.922%2084L133.922%2096L145.922%20108L133.922%20120L145.922%20132L133.922%20144L145.922%20156L133.922%20168L145.922%20180%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M146.208%2020H134.208V36H146.208V20Z%22%20fill%3D%22white%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M26.6219%2048C26.424%2048%2026.2306%2047.9412%2026.0661%2047.8312C25.9016%2047.7212%2025.7735%2047.5649%2025.6979%2047.382C25.6223%2047.1991%2025.6027%2046.998%2025.6415%2046.8039C25.6803%2046.6099%2025.7758%2046.4317%2025.9159%2046.292L36.1999%2036H168.2V48H26.6219Z%22%20fill%3D%22white%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M146.208%2020L140.208%206L134.208%2020H146.208Z%22%20fill%3D%22white%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M182.2%2046C182.2%2046.5304%20181.989%2047.0391%20181.614%2047.4142C181.239%2047.7893%20180.73%2048%20180.2%2048H168.2V36C168.2%2035.4696%20168.41%2034.9609%20168.785%2034.5858C169.161%2034.2107%20169.669%2034%20170.2%2034H182.2V46Z%22%20fill%3D%22%23E2E8F0%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M60.208%2036L140.208%206L182.208%2034%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M146.208%2020L134.208%2033.836%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M36.208%2036L48.208%2048L60.208%2036L72.208%2048L84.208%2036L96.208%2048L108.208%2036L120.208%2048L132.208%2036L144.208%2048L156.208%2036L168.208%2048%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M118.14%2092H23.992C20.5678%2092%2017.792%2094.7758%2017.792%2098.2V165.494C17.792%20168.918%2020.5678%20171.694%2023.992%20171.694H118.14C121.564%20171.694%20124.34%20168.918%20124.34%20165.494V98.2C124.34%2094.7758%20121.564%2092%20118.14%2092Z%22%20fill%3D%22%23E2E8F0%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M118.14%2092H23.9996C22.3553%2092%2020.7783%2092.6532%2019.6156%2093.8159C18.4528%2094.9787%2017.7996%2096.5557%2017.7996%2098.2V106.75H124.34V98.2C124.34%2096.5557%20123.686%2094.9787%20122.524%2093.8159C121.361%2092.6532%20119.784%2092%20118.14%2092Z%22%20fill%3D%22white%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M27.0922%20102.436C28.8043%20102.436%2030.1922%20101.048%2030.1922%2099.3361C30.1922%2097.624%2028.8043%2096.2361%2027.0922%2096.2361C25.3801%2096.2361%2023.9922%2097.624%2023.9922%2099.3361C23.9922%20101.048%2025.3801%20102.436%2027.0922%20102.436Z%22%20fill%3D%22%23E2E8F0%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M37.8002%20102.436C39.5123%20102.436%2040.9002%20101.048%2040.9002%2099.3361C40.9002%2097.624%2039.5123%2096.2361%2037.8002%2096.2361C36.0881%2096.2361%2034.7002%2097.624%2034.7002%2099.3361C34.7002%20101.048%2036.0881%20102.436%2037.8002%20102.436Z%22%20fill%3D%22%23E2E8F0%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M48.5058%20102.436C50.2178%20102.436%2051.6058%20101.048%2051.6058%2099.3361C51.6058%2097.624%2050.2178%2096.2361%2048.5058%2096.2361C46.7937%2096.2361%2045.4058%2097.624%2045.4058%2099.3361C45.4058%20101.048%2046.7937%20102.436%2048.5058%20102.436Z%22%20fill%3D%22%23E2E8F0%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M82.5722%20154.45C81.8565%20154.451%2081.1478%20154.31%2080.4869%20154.036C79.8261%20153.761%2079.2262%20153.358%2078.7222%20152.85L71.0662%20145.2L63.4002%20152.854C62.8944%20153.359%2062.2941%20153.76%2061.6335%20154.034C60.9728%20154.307%2060.2648%20154.448%2059.5498%20154.448C58.1057%20154.447%2056.721%20153.873%2055.7002%20152.852C54.6794%20151.831%2054.1061%20150.446%2054.1064%20149.002C54.1068%20147.558%2054.6808%20146.173%2055.7022%20145.152L63.3582%20137.498L55.7022%20129.842C54.6808%20128.821%2054.1068%20127.436%2054.1064%20125.992C54.1061%20124.548%2054.6794%20123.163%2055.7002%20122.142C56.721%20121.121%2058.1057%20120.547%2059.5498%20120.546C60.9938%20120.546%2062.3788%20121.119%2063.4002%20122.14L71.0662%20129.8L78.7222%20122.142C79.2252%20121.624%2079.8261%20121.212%2080.49%20120.928C81.1538%20120.645%2081.8674%20120.496%2082.5892%20120.491C83.311%20120.486%2084.0266%20120.625%2084.6944%20120.899C85.3623%20121.172%2085.969%20121.576%2086.4793%20122.087C86.9897%20122.597%2087.3934%20123.204%2087.6671%20123.872C87.9409%20124.54%2088.0791%20125.256%2088.0738%20125.977C88.0685%20126.699%2087.9197%20127.413%2087.6362%20128.076C87.3526%20128.74%2086.94%20129.341%2086.4222%20129.844L78.7662%20137.5L86.4222%20145.154C87.1831%20145.916%2087.7013%20146.886%2087.9111%20147.942C88.1209%20148.999%2088.0131%20150.093%2087.6011%20151.088C87.1891%20152.083%2086.4916%20152.934%2085.5965%20153.532C84.7014%20154.131%2083.649%20154.449%2082.5722%20154.45Z%22%20fill%3D%22white%22%20stroke%3D%22%23334155%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3C%2Fsvg%3E";
|
|
158
|
+
|
|
159
|
+
export { ForwardRef as ReactComponent, building_error as default };
|
package/index.cjs
CHANGED
|
@@ -86,6 +86,16 @@ function __rest$1(s, e) {
|
|
|
86
86
|
t[p[i]] = s[p[i]];
|
|
87
87
|
}
|
|
88
88
|
return t;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
function __awaiter(thisArg, _arguments, P, generator) {
|
|
92
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
93
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
94
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
95
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
96
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
97
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
98
|
+
});
|
|
89
99
|
}
|
|
90
100
|
|
|
91
101
|
const cvaSpinner = cssClassVarianceUtilities.cvaMerge([
|
|
@@ -18820,6 +18830,93 @@ const Drawer = ({ open, onClose = () => { }, children, disableOverlay = false, p
|
|
|
18820
18830
|
jsxRuntime.jsx(jsxRuntime.Fragment, {})) }));
|
|
18821
18831
|
};
|
|
18822
18832
|
|
|
18833
|
+
const cvaSkeletonLine = cssClassVarianceUtilities.cvaMerge([
|
|
18834
|
+
"rounded-md",
|
|
18835
|
+
"h-3",
|
|
18836
|
+
"opacity-20",
|
|
18837
|
+
"animate-pulse",
|
|
18838
|
+
"bg-black/50",
|
|
18839
|
+
"bg-auto",
|
|
18840
|
+
"bg-gradient-to-r",
|
|
18841
|
+
"from-black/0",
|
|
18842
|
+
"via-black/50",
|
|
18843
|
+
"to-black/20",
|
|
18844
|
+
]);
|
|
18845
|
+
|
|
18846
|
+
/**
|
|
18847
|
+
* Display placeholder lines before the data gets loaded to reduce load-time frustration.
|
|
18848
|
+
*/
|
|
18849
|
+
const SkeletonLines = React.memo(({ margin = "10px 0", lines = 1, height, width = "100%", className, dataTestId }) => {
|
|
18850
|
+
const skeletonLines = [];
|
|
18851
|
+
const getWidth = (index) => {
|
|
18852
|
+
if (width instanceof Array) {
|
|
18853
|
+
return width[index] || "100%";
|
|
18854
|
+
}
|
|
18855
|
+
return width;
|
|
18856
|
+
};
|
|
18857
|
+
const getHeight = (index) => {
|
|
18858
|
+
if (height instanceof Array) {
|
|
18859
|
+
return height[index] || "auto";
|
|
18860
|
+
}
|
|
18861
|
+
return height;
|
|
18862
|
+
};
|
|
18863
|
+
for (let i = 0; i < lines; i++) {
|
|
18864
|
+
skeletonLines.push(jsxRuntime.jsx("div", { "data-testid": dataTestId !== null && dataTestId !== void 0 ? dataTestId : "skeleton-lines", "data-type": "loading-skeleton-line", className: cvaSkeletonLine({ className }), style: { height: getHeight(i), width: getWidth(i), margin: lines > 1 ? margin : "" }, children: lines > 1 && jsxRuntime.jsx(jsxRuntime.Fragment, { children: "\u00A0" }) }, i));
|
|
18865
|
+
}
|
|
18866
|
+
// eslint-disable-next-line react/jsx-no-useless-fragment
|
|
18867
|
+
return jsxRuntime.jsx(jsxRuntime.Fragment, { children: skeletonLines });
|
|
18868
|
+
});
|
|
18869
|
+
|
|
18870
|
+
const containerStyles = cssClassVarianceUtilities.cvaMerge(["flex flex-col items-center gap-5 p-12 text-center justify-center h-full"]);
|
|
18871
|
+
const textStyles = cssClassVarianceUtilities.cvaMerge(["flex flex-col items-center gap-2"]);
|
|
18872
|
+
|
|
18873
|
+
var WorkerWithSign = "8df3d27593b5fba4.svg";
|
|
18874
|
+
|
|
18875
|
+
/**
|
|
18876
|
+
* Component representing an empty state.
|
|
18877
|
+
* Use this component when there is no data to display or when an error occurs.
|
|
18878
|
+
*
|
|
18879
|
+
*
|
|
18880
|
+
* @param {EmptyStateProps} props props
|
|
18881
|
+
* @returns {JSX.Element} component
|
|
18882
|
+
* @example
|
|
18883
|
+
* <EmptyState
|
|
18884
|
+
* title="No results found"
|
|
18885
|
+
* description="Try changing your search criteria"
|
|
18886
|
+
* altText="No results found"
|
|
18887
|
+
* image="BUILDING_ERROR"
|
|
18888
|
+
* />
|
|
18889
|
+
*/
|
|
18890
|
+
const EmptyState = ({ title, description, altText, image, customImageSrc, action, loading, dataTestId, className, }) => {
|
|
18891
|
+
const [imageSource, setImageSource] = React.useState(WorkerWithSign);
|
|
18892
|
+
React.useEffect(() => {
|
|
18893
|
+
const lazyLoadImage = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
18894
|
+
let importedImage = null;
|
|
18895
|
+
switch (image) {
|
|
18896
|
+
case "WORKER_WITH_SIGN":
|
|
18897
|
+
importedImage = WorkerWithSign;
|
|
18898
|
+
break;
|
|
18899
|
+
case "ROAD_BLOCK":
|
|
18900
|
+
importedImage = (yield Promise.resolve().then(function () { return require('./road_block.cjs'); })).default;
|
|
18901
|
+
break;
|
|
18902
|
+
case "BUILDING_ERROR":
|
|
18903
|
+
importedImage = (yield Promise.resolve().then(function () { return require('./building_error.cjs'); })).default;
|
|
18904
|
+
break;
|
|
18905
|
+
case "WALL_CONSTRUCTION":
|
|
18906
|
+
importedImage = (yield Promise.resolve().then(function () { return require('./wall_construction.cjs'); })).default;
|
|
18907
|
+
break;
|
|
18908
|
+
default:
|
|
18909
|
+
importedImage = WorkerWithSign;
|
|
18910
|
+
}
|
|
18911
|
+
setImageSource(importedImage);
|
|
18912
|
+
});
|
|
18913
|
+
if (!customImageSrc && image) {
|
|
18914
|
+
lazyLoadImage();
|
|
18915
|
+
}
|
|
18916
|
+
}, [customImageSrc, image]);
|
|
18917
|
+
return (jsxRuntime.jsx("div", { className: `${containerStyles()} ${className}`, "data-testid": dataTestId !== null && dataTestId !== void 0 ? dataTestId : "empty-state", children: loading ? (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(Spinner, { dataTestId: "spinner", size: "large", centering: "centered" }), jsxRuntime.jsx(SkeletonLines, { dataTestId: "skeleton-lines", width: 50 })] })) : (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx("img", { src: customImageSrc ? customImageSrc : imageSource, alt: altText }), jsxRuntime.jsxs("div", { className: textStyles(), children: [jsxRuntime.jsx(Heading, { variant: "secondary", children: title }), jsxRuntime.jsx(Text, { align: "center", children: description })] }), action] })) }));
|
|
18918
|
+
};
|
|
18919
|
+
|
|
18823
18920
|
/**
|
|
18824
18921
|
* The external link component is used to link to an external page outside the Trackunit Manager.
|
|
18825
18922
|
*
|
|
@@ -37089,43 +37186,6 @@ const PageHeader = ({ className, dataTestId, action, showLoading, description, l
|
|
|
37089
37186
|
return (jsxRuntime.jsxs("div", { className: cvaPageHeader({ className: `${className} tu-page-header` }), "data-testid": dataTestId, children: [jsxRuntime.jsxs("div", { className: cvaPageHeaderHeadingAccessoriesContainer(), "data-testid": dataTestId && `${dataTestId}-heading-container`, children: [jsxRuntime.jsxs("div", { className: cvaPageHeaderHeadingContainer(), children: [backTo && (jsxRuntime.jsx(IconButton, { to: backTo, color: "tertiary", variant: "transparent", size: "small", icon: jsxRuntime.jsx(Icon, { name: "ArrowLeftIcon" }) })), jsxRuntime.jsx("h1", { className: cvaPageHeaderHeading(), "data-testid": dataTestId && `${dataTestId}-heading`, children: title }), description && !showLoading && (jsxRuntime.jsx(Tip, { dataTestId: dataTestId && `${dataTestId}-tip`, iconProps: { name: "QuestionMarkCircleIcon" }, link: link, children: description }))] }), tag && !showLoading && jsxRuntime.jsx(Tag, { dataTestId: dataTestId, children: tag }), showLoading && jsxRuntime.jsx(Spinner, { dataTestId: dataTestId && `${dataTestId}-spinner`, centering: "vertically" }), action] }), jsxRuntime.jsx("div", { className: cvaPageHeaderChildContainer(), children: children })] }));
|
|
37090
37187
|
};
|
|
37091
37188
|
|
|
37092
|
-
const cvaSkeletonLine = cssClassVarianceUtilities.cvaMerge([
|
|
37093
|
-
"rounded-md",
|
|
37094
|
-
"h-3",
|
|
37095
|
-
"opacity-20",
|
|
37096
|
-
"animate-pulse",
|
|
37097
|
-
"bg-black/50",
|
|
37098
|
-
"bg-auto",
|
|
37099
|
-
"bg-gradient-to-r",
|
|
37100
|
-
"from-black/0",
|
|
37101
|
-
"via-black/50",
|
|
37102
|
-
"to-black/20",
|
|
37103
|
-
]);
|
|
37104
|
-
|
|
37105
|
-
/**
|
|
37106
|
-
* Display placeholder lines before the data gets loaded to reduce load-time frustration.
|
|
37107
|
-
*/
|
|
37108
|
-
const SkeletonLines = React.memo(({ margin = "10px 0", lines = 1, height, width = "100%", className, dataTestId }) => {
|
|
37109
|
-
const skeletonLines = [];
|
|
37110
|
-
const getWidth = (index) => {
|
|
37111
|
-
if (width instanceof Array) {
|
|
37112
|
-
return width[index] || "100%";
|
|
37113
|
-
}
|
|
37114
|
-
return width;
|
|
37115
|
-
};
|
|
37116
|
-
const getHeight = (index) => {
|
|
37117
|
-
if (height instanceof Array) {
|
|
37118
|
-
return height[index] || "auto";
|
|
37119
|
-
}
|
|
37120
|
-
return height;
|
|
37121
|
-
};
|
|
37122
|
-
for (let i = 0; i < lines; i++) {
|
|
37123
|
-
skeletonLines.push(jsxRuntime.jsx("div", { "data-testid": dataTestId !== null && dataTestId !== void 0 ? dataTestId : "skeleton-lines", "data-type": "loading-skeleton-line", className: cvaSkeletonLine({ className }), style: { height: getHeight(i), width: getWidth(i), margin: lines > 1 ? margin : "" }, children: lines > 1 && jsxRuntime.jsx(jsxRuntime.Fragment, { children: "\u00A0" }) }, i));
|
|
37124
|
-
}
|
|
37125
|
-
// eslint-disable-next-line react/jsx-no-useless-fragment
|
|
37126
|
-
return jsxRuntime.jsx(jsxRuntime.Fragment, { children: skeletonLines });
|
|
37127
|
-
});
|
|
37128
|
-
|
|
37129
37189
|
const cvaPagination = cssClassVarianceUtilities.cvaMerge(["flex", "items-center", "gap-1"]);
|
|
37130
37190
|
const cvaPaginationText = cssClassVarianceUtilities.cvaMerge("whitespace-nowrap");
|
|
37131
37191
|
|
|
@@ -39206,6 +39266,7 @@ exports.DayPickerPopover = DayPickerPopover;
|
|
|
39206
39266
|
exports.DayRangePicker = DayRangePicker;
|
|
39207
39267
|
exports.DensityContainer = DensityContainer;
|
|
39208
39268
|
exports.Drawer = Drawer;
|
|
39269
|
+
exports.EmptyState = EmptyState;
|
|
39209
39270
|
exports.ExternalLink = ExternalLink;
|
|
39210
39271
|
exports.FilterListMapLayout = FilterListMapLayout;
|
|
39211
39272
|
exports.FullWidthRepeatingLayout = FullWidthRepeatingLayout;
|
package/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
2
2
|
import * as React from 'react';
|
|
3
|
-
import React__default, { useRef, useCallback, useEffect, useState, useLayoutEffect, useMemo, createContext, forwardRef, useContext, isValidElement, cloneElement, Children, useReducer,
|
|
3
|
+
import React__default, { useRef, useCallback, useEffect, useState, useLayoutEffect, useMemo, createContext, forwardRef, useContext, isValidElement, cloneElement, memo, Children, useReducer, Component } from 'react';
|
|
4
4
|
import { tw, tws } from '@trackunit/tailwind-styled-components';
|
|
5
5
|
import { cvaMerge } from '@trackunit/css-class-variance-utilities';
|
|
6
6
|
import { HeroIconsArray, heroIconLookup, TrackunitSolidIconsArray, TrackunitOutlineIconsArray, trackunitIconLookup } from '@trackunit/ui-icons';
|
|
@@ -59,6 +59,16 @@ function __rest$1(s, e) {
|
|
|
59
59
|
t[p[i]] = s[p[i]];
|
|
60
60
|
}
|
|
61
61
|
return t;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
function __awaiter(thisArg, _arguments, P, generator) {
|
|
65
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
66
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
67
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
68
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
69
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
70
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
71
|
+
});
|
|
62
72
|
}
|
|
63
73
|
|
|
64
74
|
const cvaSpinner = cvaMerge([
|
|
@@ -18793,6 +18803,93 @@ const Drawer = ({ open, onClose = () => { }, children, disableOverlay = false, p
|
|
|
18793
18803
|
jsx(Fragment, {})) }));
|
|
18794
18804
|
};
|
|
18795
18805
|
|
|
18806
|
+
const cvaSkeletonLine = cvaMerge([
|
|
18807
|
+
"rounded-md",
|
|
18808
|
+
"h-3",
|
|
18809
|
+
"opacity-20",
|
|
18810
|
+
"animate-pulse",
|
|
18811
|
+
"bg-black/50",
|
|
18812
|
+
"bg-auto",
|
|
18813
|
+
"bg-gradient-to-r",
|
|
18814
|
+
"from-black/0",
|
|
18815
|
+
"via-black/50",
|
|
18816
|
+
"to-black/20",
|
|
18817
|
+
]);
|
|
18818
|
+
|
|
18819
|
+
/**
|
|
18820
|
+
* Display placeholder lines before the data gets loaded to reduce load-time frustration.
|
|
18821
|
+
*/
|
|
18822
|
+
const SkeletonLines = memo(({ margin = "10px 0", lines = 1, height, width = "100%", className, dataTestId }) => {
|
|
18823
|
+
const skeletonLines = [];
|
|
18824
|
+
const getWidth = (index) => {
|
|
18825
|
+
if (width instanceof Array) {
|
|
18826
|
+
return width[index] || "100%";
|
|
18827
|
+
}
|
|
18828
|
+
return width;
|
|
18829
|
+
};
|
|
18830
|
+
const getHeight = (index) => {
|
|
18831
|
+
if (height instanceof Array) {
|
|
18832
|
+
return height[index] || "auto";
|
|
18833
|
+
}
|
|
18834
|
+
return height;
|
|
18835
|
+
};
|
|
18836
|
+
for (let i = 0; i < lines; i++) {
|
|
18837
|
+
skeletonLines.push(jsx("div", { "data-testid": dataTestId !== null && dataTestId !== void 0 ? dataTestId : "skeleton-lines", "data-type": "loading-skeleton-line", className: cvaSkeletonLine({ className }), style: { height: getHeight(i), width: getWidth(i), margin: lines > 1 ? margin : "" }, children: lines > 1 && jsx(Fragment, { children: "\u00A0" }) }, i));
|
|
18838
|
+
}
|
|
18839
|
+
// eslint-disable-next-line react/jsx-no-useless-fragment
|
|
18840
|
+
return jsx(Fragment, { children: skeletonLines });
|
|
18841
|
+
});
|
|
18842
|
+
|
|
18843
|
+
const containerStyles = cvaMerge(["flex flex-col items-center gap-5 p-12 text-center justify-center h-full"]);
|
|
18844
|
+
const textStyles = cvaMerge(["flex flex-col items-center gap-2"]);
|
|
18845
|
+
|
|
18846
|
+
var WorkerWithSign = "8df3d27593b5fba4.svg";
|
|
18847
|
+
|
|
18848
|
+
/**
|
|
18849
|
+
* Component representing an empty state.
|
|
18850
|
+
* Use this component when there is no data to display or when an error occurs.
|
|
18851
|
+
*
|
|
18852
|
+
*
|
|
18853
|
+
* @param {EmptyStateProps} props props
|
|
18854
|
+
* @returns {JSX.Element} component
|
|
18855
|
+
* @example
|
|
18856
|
+
* <EmptyState
|
|
18857
|
+
* title="No results found"
|
|
18858
|
+
* description="Try changing your search criteria"
|
|
18859
|
+
* altText="No results found"
|
|
18860
|
+
* image="BUILDING_ERROR"
|
|
18861
|
+
* />
|
|
18862
|
+
*/
|
|
18863
|
+
const EmptyState = ({ title, description, altText, image, customImageSrc, action, loading, dataTestId, className, }) => {
|
|
18864
|
+
const [imageSource, setImageSource] = useState(WorkerWithSign);
|
|
18865
|
+
useEffect(() => {
|
|
18866
|
+
const lazyLoadImage = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
18867
|
+
let importedImage = null;
|
|
18868
|
+
switch (image) {
|
|
18869
|
+
case "WORKER_WITH_SIGN":
|
|
18870
|
+
importedImage = WorkerWithSign;
|
|
18871
|
+
break;
|
|
18872
|
+
case "ROAD_BLOCK":
|
|
18873
|
+
importedImage = (yield import('./road_block.js')).default;
|
|
18874
|
+
break;
|
|
18875
|
+
case "BUILDING_ERROR":
|
|
18876
|
+
importedImage = (yield import('./building_error.js')).default;
|
|
18877
|
+
break;
|
|
18878
|
+
case "WALL_CONSTRUCTION":
|
|
18879
|
+
importedImage = (yield import('./wall_construction.js')).default;
|
|
18880
|
+
break;
|
|
18881
|
+
default:
|
|
18882
|
+
importedImage = WorkerWithSign;
|
|
18883
|
+
}
|
|
18884
|
+
setImageSource(importedImage);
|
|
18885
|
+
});
|
|
18886
|
+
if (!customImageSrc && image) {
|
|
18887
|
+
lazyLoadImage();
|
|
18888
|
+
}
|
|
18889
|
+
}, [customImageSrc, image]);
|
|
18890
|
+
return (jsx("div", { className: `${containerStyles()} ${className}`, "data-testid": dataTestId !== null && dataTestId !== void 0 ? dataTestId : "empty-state", children: loading ? (jsxs(Fragment, { children: [jsx(Spinner, { dataTestId: "spinner", size: "large", centering: "centered" }), jsx(SkeletonLines, { dataTestId: "skeleton-lines", width: 50 })] })) : (jsxs(Fragment, { children: [jsx("img", { src: customImageSrc ? customImageSrc : imageSource, alt: altText }), jsxs("div", { className: textStyles(), children: [jsx(Heading, { variant: "secondary", children: title }), jsx(Text, { align: "center", children: description })] }), action] })) }));
|
|
18891
|
+
};
|
|
18892
|
+
|
|
18796
18893
|
/**
|
|
18797
18894
|
* The external link component is used to link to an external page outside the Trackunit Manager.
|
|
18798
18895
|
*
|
|
@@ -37062,43 +37159,6 @@ const PageHeader = ({ className, dataTestId, action, showLoading, description, l
|
|
|
37062
37159
|
return (jsxs("div", { className: cvaPageHeader({ className: `${className} tu-page-header` }), "data-testid": dataTestId, children: [jsxs("div", { className: cvaPageHeaderHeadingAccessoriesContainer(), "data-testid": dataTestId && `${dataTestId}-heading-container`, children: [jsxs("div", { className: cvaPageHeaderHeadingContainer(), children: [backTo && (jsx(IconButton, { to: backTo, color: "tertiary", variant: "transparent", size: "small", icon: jsx(Icon, { name: "ArrowLeftIcon" }) })), jsx("h1", { className: cvaPageHeaderHeading(), "data-testid": dataTestId && `${dataTestId}-heading`, children: title }), description && !showLoading && (jsx(Tip, { dataTestId: dataTestId && `${dataTestId}-tip`, iconProps: { name: "QuestionMarkCircleIcon" }, link: link, children: description }))] }), tag && !showLoading && jsx(Tag, { dataTestId: dataTestId, children: tag }), showLoading && jsx(Spinner, { dataTestId: dataTestId && `${dataTestId}-spinner`, centering: "vertically" }), action] }), jsx("div", { className: cvaPageHeaderChildContainer(), children: children })] }));
|
|
37063
37160
|
};
|
|
37064
37161
|
|
|
37065
|
-
const cvaSkeletonLine = cvaMerge([
|
|
37066
|
-
"rounded-md",
|
|
37067
|
-
"h-3",
|
|
37068
|
-
"opacity-20",
|
|
37069
|
-
"animate-pulse",
|
|
37070
|
-
"bg-black/50",
|
|
37071
|
-
"bg-auto",
|
|
37072
|
-
"bg-gradient-to-r",
|
|
37073
|
-
"from-black/0",
|
|
37074
|
-
"via-black/50",
|
|
37075
|
-
"to-black/20",
|
|
37076
|
-
]);
|
|
37077
|
-
|
|
37078
|
-
/**
|
|
37079
|
-
* Display placeholder lines before the data gets loaded to reduce load-time frustration.
|
|
37080
|
-
*/
|
|
37081
|
-
const SkeletonLines = memo(({ margin = "10px 0", lines = 1, height, width = "100%", className, dataTestId }) => {
|
|
37082
|
-
const skeletonLines = [];
|
|
37083
|
-
const getWidth = (index) => {
|
|
37084
|
-
if (width instanceof Array) {
|
|
37085
|
-
return width[index] || "100%";
|
|
37086
|
-
}
|
|
37087
|
-
return width;
|
|
37088
|
-
};
|
|
37089
|
-
const getHeight = (index) => {
|
|
37090
|
-
if (height instanceof Array) {
|
|
37091
|
-
return height[index] || "auto";
|
|
37092
|
-
}
|
|
37093
|
-
return height;
|
|
37094
|
-
};
|
|
37095
|
-
for (let i = 0; i < lines; i++) {
|
|
37096
|
-
skeletonLines.push(jsx("div", { "data-testid": dataTestId !== null && dataTestId !== void 0 ? dataTestId : "skeleton-lines", "data-type": "loading-skeleton-line", className: cvaSkeletonLine({ className }), style: { height: getHeight(i), width: getWidth(i), margin: lines > 1 ? margin : "" }, children: lines > 1 && jsx(Fragment, { children: "\u00A0" }) }, i));
|
|
37097
|
-
}
|
|
37098
|
-
// eslint-disable-next-line react/jsx-no-useless-fragment
|
|
37099
|
-
return jsx(Fragment, { children: skeletonLines });
|
|
37100
|
-
});
|
|
37101
|
-
|
|
37102
37162
|
const cvaPagination = cvaMerge(["flex", "items-center", "gap-1"]);
|
|
37103
37163
|
const cvaPaginationText = cvaMerge("whitespace-nowrap");
|
|
37104
37164
|
|
|
@@ -39164,4 +39224,4 @@ const ContentGridArea = tw.article `
|
|
|
39164
39224
|
tu-layout-area-content
|
|
39165
39225
|
`;
|
|
39166
39226
|
|
|
39167
|
-
export { Alert, Badge, Button$1 as Button, Card, CardBody, CardFooter, CardHeader, Collapse, ContentGridArea, CopyableText, DayPicker, DayPickerPopover, DayRangePicker, DensityContainer, Drawer, ExternalLink, FilterListMapLayout, FullWidthRepeatingLayout, GridArea, Heading, Icon, IconButton, Indicator, IntrinsicallyResponsiveGrid, MenuItem, MenuList, MinTopFullContentLayout, Modal, ModalBackdrop, MoreMenu, NavGridArea, PageHeader, Pagination, Popover, PopoverContent, PopoverTitle, PopoverTrigger, Prompt, ROLE_CARD, SectionHeader, Sidebar, SkeletonLines, Spacer, Spinner, StarButton, Tag, Text, Timeline, TimelineElement, Tip, TitleGridArea, TitleNavContentLayout, Tooltip, ValueBar, cvaButton, cvaButtonSpinner, cvaClickable, cvaIconButtonContainer, cvaIndicator, cvaIndicatorIcon, cvaIndicatorIconBackground, cvaIndicatorLabel, cvaIndicatorPing, cvaMenuItem, cvaMenuItemLabel, cvaMenuItemPrefix, cvaMenuItemSuffix, docs, getDevicePixelRatio, getValueBarColorByValue, useClickOutside, useContainerProps, useDebounce, useDevicePixelRatio, useHover, useIsFirstRender, useLocalStorage, useLocalStorageReducer, useModal, usePopoverContext, usePrompt, useResize, useTimeout };
|
|
39227
|
+
export { Alert, Badge, Button$1 as Button, Card, CardBody, CardFooter, CardHeader, Collapse, ContentGridArea, CopyableText, DayPicker, DayPickerPopover, DayRangePicker, DensityContainer, Drawer, EmptyState, ExternalLink, FilterListMapLayout, FullWidthRepeatingLayout, GridArea, Heading, Icon, IconButton, Indicator, IntrinsicallyResponsiveGrid, MenuItem, MenuList, MinTopFullContentLayout, Modal, ModalBackdrop, MoreMenu, NavGridArea, PageHeader, Pagination, Popover, PopoverContent, PopoverTitle, PopoverTrigger, Prompt, ROLE_CARD, SectionHeader, Sidebar, SkeletonLines, Spacer, Spinner, StarButton, Tag, Text, Timeline, TimelineElement, Tip, TitleGridArea, TitleNavContentLayout, Tooltip, ValueBar, cvaButton, cvaButtonSpinner, cvaClickable, cvaIconButtonContainer, cvaIndicator, cvaIndicatorIcon, cvaIndicatorIconBackground, cvaIndicatorLabel, cvaIndicatorPing, cvaMenuItem, cvaMenuItemLabel, cvaMenuItemPrefix, cvaMenuItemSuffix, docs, getDevicePixelRatio, getValueBarColorByValue, useClickOutside, useContainerProps, useDebounce, useDevicePixelRatio, useHover, useIsFirstRender, useLocalStorage, useLocalStorageReducer, useModal, usePopoverContext, usePrompt, useResize, useTimeout };
|