opus-toolkit-components 1.5.6 → 1.5.7
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/lib/opus-components.main.js +161 -193
- package/lib/opus-components.main.js.map +1 -1
- package/package.json +11 -3
|
@@ -2,25 +2,6 @@
|
|
|
2
2
|
/******/ "use strict";
|
|
3
3
|
/******/ var __webpack_modules__ = ({
|
|
4
4
|
|
|
5
|
-
/***/ 20:
|
|
6
|
-
/***/ ((__unused_webpack_module, exports, __webpack_require__) => {
|
|
7
|
-
|
|
8
|
-
var __webpack_unused_export__;
|
|
9
|
-
/**
|
|
10
|
-
* @license React
|
|
11
|
-
* react-jsx-runtime.production.min.js
|
|
12
|
-
*
|
|
13
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
14
|
-
*
|
|
15
|
-
* This source code is licensed under the MIT license found in the
|
|
16
|
-
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/
|
|
18
|
-
var f=__webpack_require__(206),k=Symbol.for("react.element"),l=Symbol.for("react.fragment"),m=Object.prototype.hasOwnProperty,n=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,p={key:!0,ref:!0,__self:!0,__source:!0};
|
|
19
|
-
function q(c,a,g){var b,d={},e=null,h=null;void 0!==g&&(e=""+g);void 0!==a.key&&(e=""+a.key);void 0!==a.ref&&(h=a.ref);for(b in a)m.call(a,b)&&!p.hasOwnProperty(b)&&(d[b]=a[b]);if(c&&c.defaultProps)for(b in a=c.defaultProps,a)void 0===d[b]&&(d[b]=a[b]);return{$$typeof:k,type:c,key:e,ref:h,props:d,_owner:n.current}}__webpack_unused_export__=l;exports.jsx=q;exports.jsxs=q;
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
/***/ }),
|
|
23
|
-
|
|
24
5
|
/***/ 56:
|
|
25
6
|
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
26
7
|
|
|
@@ -580,19 +561,6 @@ ___CSS_LOADER_EXPORT___.push([module.id, ``, "",{"version":3,"sources":[],"names
|
|
|
580
561
|
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (___CSS_LOADER_EXPORT___);
|
|
581
562
|
|
|
582
563
|
|
|
583
|
-
/***/ }),
|
|
584
|
-
|
|
585
|
-
/***/ 848:
|
|
586
|
-
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
if (true) {
|
|
591
|
-
module.exports = __webpack_require__(20);
|
|
592
|
-
} else // removed by dead control flow
|
|
593
|
-
{}
|
|
594
|
-
|
|
595
|
-
|
|
596
564
|
/***/ }),
|
|
597
565
|
|
|
598
566
|
/***/ 908:
|
|
@@ -1148,8 +1116,8 @@ function ChevronDownIcon({
|
|
|
1148
1116
|
}
|
|
1149
1117
|
const ChevronDownIcon_ForwardRef = /*#__PURE__*/ external_commonjs_react_commonjs2_react_amd_react_root_React_.forwardRef(ChevronDownIcon);
|
|
1150
1118
|
/* harmony default export */ const esm_ChevronDownIcon = (ChevronDownIcon_ForwardRef);
|
|
1151
|
-
|
|
1152
|
-
|
|
1119
|
+
;// external "react/jsx-runtime"
|
|
1120
|
+
const jsx_runtime_namespaceObject = require("react/jsx-runtime");
|
|
1153
1121
|
;// ./src/components/Pills/Pill.jsx
|
|
1154
1122
|
|
|
1155
1123
|
|
|
@@ -1170,9 +1138,9 @@ const Pill = _ref => {
|
|
|
1170
1138
|
} = _ref;
|
|
1171
1139
|
const baseClasses = 'inline-flex items-center gap-1 text-xs font-medium px-3 py-1 rounded-full';
|
|
1172
1140
|
const statusClass = statusClasses[status] || statusClasses.info;
|
|
1173
|
-
return /*#__PURE__*/(0,
|
|
1141
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("span", {
|
|
1174
1142
|
className: "".concat(baseClasses, " ").concat(statusClass, " ").concat(className),
|
|
1175
|
-
children: [Icon && /*#__PURE__*/(0,
|
|
1143
|
+
children: [Icon && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Icon, {
|
|
1176
1144
|
className: "w-4 h-4"
|
|
1177
1145
|
}), text]
|
|
1178
1146
|
});
|
|
@@ -1238,7 +1206,7 @@ function Text(_ref) {
|
|
|
1238
1206
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
1239
1207
|
const Component = as || elementMap[variant] || "p";
|
|
1240
1208
|
const variantClass = variantMap[variant] || variantMap.body;
|
|
1241
|
-
return /*#__PURE__*/(0,
|
|
1209
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Component, _objectSpread(_objectSpread({
|
|
1242
1210
|
className: "".concat(variantClass, " ").concat(color, " ").concat(className),
|
|
1243
1211
|
"data-cy": getDataCy({
|
|
1244
1212
|
name,
|
|
@@ -1291,48 +1259,48 @@ const Accordion = _ref => {
|
|
|
1291
1259
|
setInternalActiveIndex(activeIndex);
|
|
1292
1260
|
}
|
|
1293
1261
|
}, [activeIndex]);
|
|
1294
|
-
return /*#__PURE__*/(0,
|
|
1262
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
1295
1263
|
id: "accordion-".concat(index),
|
|
1296
1264
|
className: "accordion w-full border border-[--color-stroke] shadow-lg ".concat(disabled ? "pointer-events-none opacity-50" : "", " rounded-lg"),
|
|
1297
|
-
children: [/*#__PURE__*/(0,
|
|
1265
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
1298
1266
|
className: "accordion-item",
|
|
1299
|
-
children: /*#__PURE__*/(0,
|
|
1267
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
1300
1268
|
onClick: !isPreview && !isLocked ? toggle : null,
|
|
1301
1269
|
className: "accordion-header flex items-center justify-between rounded-t-lg bg-[--color-accordion-header] ".concat(isActive || isPreview ? "" : "rounded-b-lg", " hover: ").concat(!isLocked ? "cursor-pointer" : null, " "),
|
|
1302
|
-
children: [/*#__PURE__*/(0,
|
|
1270
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
1303
1271
|
className: "flex items-center justify-between gap-2",
|
|
1304
|
-
children: /*#__PURE__*/(0,
|
|
1272
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
1305
1273
|
as: "h2",
|
|
1306
1274
|
variant: "h2",
|
|
1307
1275
|
className: "text-h4 mx-4 my-2 text-[--color-text-strong]",
|
|
1308
1276
|
children: title
|
|
1309
1277
|
})
|
|
1310
|
-
}), /*#__PURE__*/(0,
|
|
1278
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
1311
1279
|
className: "flex items-center gap-4",
|
|
1312
|
-
children: [isPill && /*#__PURE__*/(0,
|
|
1280
|
+
children: [isPill && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Pills_Pill, {
|
|
1313
1281
|
text: pillText,
|
|
1314
1282
|
status: pillStatus,
|
|
1315
1283
|
icon: pillIcon
|
|
1316
|
-
}), /*#__PURE__*/(0,
|
|
1284
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
1317
1285
|
className: "border-0 ".concat(!isLocked && "cursor-pointer border-l-2", " border-solid border-[--color-stroke] p-4"),
|
|
1318
1286
|
onClick: !isLocked ? toggle : null // toggle only here
|
|
1319
1287
|
,
|
|
1320
|
-
children: isPreview && !isLocked ? /*#__PURE__*/(0,
|
|
1288
|
+
children: isPreview && !isLocked ? /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(esm_PencilSquareIcon, {
|
|
1321
1289
|
className: "h-5 w-5 text-[--color-text-strong]",
|
|
1322
1290
|
onClick: e => {
|
|
1323
1291
|
e.stopPropagation(); // prevent toggle from firing on pencil click
|
|
1324
1292
|
onExitPreview(); // trigger exit preview
|
|
1325
1293
|
}
|
|
1326
|
-
}) : !isLocked ? /*#__PURE__*/(0,
|
|
1294
|
+
}) : !isLocked ? /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(esm_ChevronDownIcon, {
|
|
1327
1295
|
className: "h-4 w-4 transform text-[--color-text-strong] transition-transform ".concat(isActive ? "rotate-180" : "rotate-0")
|
|
1328
1296
|
}) : null
|
|
1329
1297
|
})]
|
|
1330
1298
|
})]
|
|
1331
1299
|
})
|
|
1332
|
-
}, index), isActive && /*#__PURE__*/(0,
|
|
1300
|
+
}, index), isActive && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
1333
1301
|
className: "accordion-body rounded-b-lg border-0 border-t-2 border-solid border-[--color-stroke] bg-[--color-accordion-body] p-3 text-[--color-text-weak]",
|
|
1334
1302
|
children: content
|
|
1335
|
-
}), isPreview && activeIndex !== index && /*#__PURE__*/(0,
|
|
1303
|
+
}), isPreview && activeIndex !== index && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
1336
1304
|
className: "accordion-body rounded-b-lg border-0 border-t-2 border-solid border-[--color-stroke] bg-[--color-accordion-body] p-3 text-[--color-text-weak]",
|
|
1337
1305
|
children: preview
|
|
1338
1306
|
})]
|
|
@@ -4217,7 +4185,7 @@ function Button(_ref) {
|
|
|
4217
4185
|
|
|
4218
4186
|
// Main button class names
|
|
4219
4187
|
const classNames = " \n ".concat(state === "disabled" || isSaving ? disabledStyles : rankStyles[rank] || rankStyles.primary, "\n group \n transition \n ease-in-out \n duration-700 \n rounded-md\n hover:shadow-lg\n px-5 \n py-1.5 \n text-").concat(size, " \n flex \n items-center \n justify-center \n whitespace-nowrap // Prevents text wrapping\n ").concat(isFullWidth ? "w-full" : "", "\n ").concat(className, "\n ");
|
|
4220
|
-
return /*#__PURE__*/(0,
|
|
4188
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("button", {
|
|
4221
4189
|
type: type,
|
|
4222
4190
|
title: title,
|
|
4223
4191
|
name: name,
|
|
@@ -4230,14 +4198,14 @@ function Button(_ref) {
|
|
|
4230
4198
|
}),
|
|
4231
4199
|
onClick: !isSaving && state !== "disabled" ? onClick : null,
|
|
4232
4200
|
disabled: isSaving || state === "disabled",
|
|
4233
|
-
children: [isSaving ? /*#__PURE__*/(0,
|
|
4201
|
+
children: [isSaving ? /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(AiOutlineLoading3Quarters, {
|
|
4234
4202
|
className: iconClassNames
|
|
4235
|
-
}) : iconPosition === "left" && Icon && /*#__PURE__*/(0,
|
|
4203
|
+
}) : iconPosition === "left" && Icon && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Icon, {
|
|
4236
4204
|
className: iconClassNames
|
|
4237
|
-
}), /*#__PURE__*/(0,
|
|
4205
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("span", {
|
|
4238
4206
|
className: isSaving ? "ml-2" : "",
|
|
4239
4207
|
children: isSaving ? savingText : text
|
|
4240
|
-
}), !isSaving && iconPosition === "right" && Icon && /*#__PURE__*/(0,
|
|
4208
|
+
}), !isSaving && iconPosition === "right" && Icon && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Icon, {
|
|
4241
4209
|
className: iconClassNames
|
|
4242
4210
|
})]
|
|
4243
4211
|
});
|
|
@@ -4266,7 +4234,7 @@ function Card(_ref) {
|
|
|
4266
4234
|
};
|
|
4267
4235
|
const resolvedIntent = intent || 'default';
|
|
4268
4236
|
const cardClasses = dist_clsx('p-5', 'rounded-lg', 'shadow-lg', 'border-2 border-solid border-[--color-stroke]', intentClasses[resolvedIntent], className);
|
|
4269
|
-
return /*#__PURE__*/(0,
|
|
4237
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
4270
4238
|
className: cardClasses,
|
|
4271
4239
|
children: children
|
|
4272
4240
|
});
|
|
@@ -4314,27 +4282,27 @@ const Input = /*#__PURE__*/(0,external_commonjs_react_commonjs2_react_amd_react_
|
|
|
4314
4282
|
} = _ref;
|
|
4315
4283
|
const inputClasses = "".concat(className, " flex items-center rounded-md bg-[--color-input-bg] border ").concat(isValid ? 'border-[--color-stroke]' : 'border-utilRed1000', " text-md font-normal text-[--color-text-strong] ").concat(disabled ? 'opacity-50 cursor-not-allowed' : '');
|
|
4316
4284
|
const iconClasses = "h-5 w-5 ".concat(isAnimated ? 'transition-transform duration-200 group-focus-within:scale-125' : '', " text-[--color-text-weak]");
|
|
4317
|
-
return /*#__PURE__*/(0,
|
|
4285
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
4318
4286
|
className: "flex flex-col mb-4",
|
|
4319
|
-
children: [/*#__PURE__*/(0,
|
|
4287
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)(Text, {
|
|
4320
4288
|
as: "label",
|
|
4321
4289
|
variant: "label",
|
|
4322
4290
|
htmlFor: name,
|
|
4323
4291
|
className: "mb-1 flex items-center",
|
|
4324
|
-
children: [label, required && /*#__PURE__*/(0,
|
|
4292
|
+
children: [label, required && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
4325
4293
|
as: "span",
|
|
4326
4294
|
variant: "small",
|
|
4327
4295
|
className: "text-[--color-util-red] ml-1",
|
|
4328
4296
|
children: "*"
|
|
4329
4297
|
})]
|
|
4330
|
-
}), /*#__PURE__*/(0,
|
|
4298
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
4331
4299
|
className: "".concat(inputClasses, " relative"),
|
|
4332
|
-
children: [Icon && iconPosition === 'left' && /*#__PURE__*/(0,
|
|
4300
|
+
children: [Icon && iconPosition === 'left' && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("span", {
|
|
4333
4301
|
className: "absolute left-3 flex items-center pointer-events-none",
|
|
4334
|
-
children: /*#__PURE__*/(0,
|
|
4302
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Icon, {
|
|
4335
4303
|
className: iconClasses
|
|
4336
4304
|
})
|
|
4337
|
-
}), /*#__PURE__*/(0,
|
|
4305
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("input", {
|
|
4338
4306
|
id: name,
|
|
4339
4307
|
ref: ref,
|
|
4340
4308
|
className: "w-full ".concat(Icon ? iconPosition === 'left' ? 'pl-10' : 'pr-10' : '', " bg-[--color-input-bg] border-none focus:ring-0 focus:outline-none rounded-md py-2 px-3"),
|
|
@@ -4353,13 +4321,13 @@ const Input = /*#__PURE__*/(0,external_commonjs_react_commonjs2_react_amd_react_
|
|
|
4353
4321
|
}),
|
|
4354
4322
|
"aria-invalid": !isValid,
|
|
4355
4323
|
"aria-describedby": !isValid ? "".concat(name, "-error") : undefined
|
|
4356
|
-
}), Icon && iconPosition === 'right' && /*#__PURE__*/(0,
|
|
4324
|
+
}), Icon && iconPosition === 'right' && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("span", {
|
|
4357
4325
|
className: "absolute right-3 flex items-center pointer-events-none",
|
|
4358
|
-
children: /*#__PURE__*/(0,
|
|
4326
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Icon, {
|
|
4359
4327
|
className: iconClasses
|
|
4360
4328
|
})
|
|
4361
4329
|
})]
|
|
4362
|
-
}), !isValid && /*#__PURE__*/(0,
|
|
4330
|
+
}), !isValid && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
4363
4331
|
as: "span",
|
|
4364
4332
|
variant: "small",
|
|
4365
4333
|
id: "".concat(name, "-error"),
|
|
@@ -4492,18 +4460,18 @@ function DatePicker(_ref) {
|
|
|
4492
4460
|
inputRef.current.showPicker();
|
|
4493
4461
|
}
|
|
4494
4462
|
};
|
|
4495
|
-
return /*#__PURE__*/(0,
|
|
4463
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
4496
4464
|
className: "relative flex flex-col mb-4",
|
|
4497
|
-
children: [/*#__PURE__*/(0,
|
|
4465
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)(Text, {
|
|
4498
4466
|
as: "label",
|
|
4499
4467
|
variant: "label",
|
|
4500
4468
|
htmlFor: name,
|
|
4501
4469
|
className: "mb-1",
|
|
4502
|
-
children: [label, required && /*#__PURE__*/(0,
|
|
4470
|
+
children: [label, required && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("span", {
|
|
4503
4471
|
className: "text-[--color-util-red] ml-1",
|
|
4504
4472
|
children: "*"
|
|
4505
4473
|
})]
|
|
4506
|
-
}), /*#__PURE__*/(0,
|
|
4474
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("input", {
|
|
4507
4475
|
type: "date",
|
|
4508
4476
|
id: name,
|
|
4509
4477
|
name: name,
|
|
@@ -4520,16 +4488,16 @@ function DatePicker(_ref) {
|
|
|
4520
4488
|
"aria-invalid": !isValid,
|
|
4521
4489
|
"aria-describedby": !isValid ? "".concat(name, "-error") : undefined,
|
|
4522
4490
|
className: "w-full py-2 px-3 pr-10 rounded-md bg-[--color-input-bg] border ".concat(isValid ? 'border-[--color-stroke]' : 'border-[--color-util-red]', " text-md font-normal text-[--color-text-strong] ").concat(disabled ? 'opacity-50 cursor-not-allowed' : '', " ").concat(className)
|
|
4523
|
-
}), /*#__PURE__*/(0,
|
|
4491
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("button", {
|
|
4524
4492
|
type: "button",
|
|
4525
4493
|
onClick: handleIconClick,
|
|
4526
4494
|
className: "absolute top-1/2 mt-1 right-3 transform datepicker-icon-button",
|
|
4527
4495
|
"aria-label": "Open date picker",
|
|
4528
4496
|
disabled: disabled,
|
|
4529
|
-
children: /*#__PURE__*/(0,
|
|
4497
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(esm_CalendarIcon, {
|
|
4530
4498
|
className: "w-5 h-5 ".concat(disabled ? 'text-[--color-text-disabled]' : 'text-[--color-text-weak] hover:text-[--color-primary-btn-hover]', " transition")
|
|
4531
4499
|
})
|
|
4532
|
-
}), !isValid && /*#__PURE__*/(0,
|
|
4500
|
+
}), !isValid && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
4533
4501
|
as: "span",
|
|
4534
4502
|
id: "".concat(name, "-error"),
|
|
4535
4503
|
variant: "small",
|
|
@@ -4582,26 +4550,26 @@ const RadioButton = _ref => {
|
|
|
4582
4550
|
};
|
|
4583
4551
|
onChange === null || onChange === void 0 || onChange(event);
|
|
4584
4552
|
};
|
|
4585
|
-
return /*#__PURE__*/(0,
|
|
4553
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
4586
4554
|
className: "mb-4 flex flex-col ".concat(className),
|
|
4587
|
-
children: [/*#__PURE__*/(0,
|
|
4555
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)(Text, {
|
|
4588
4556
|
as: "label",
|
|
4589
4557
|
variant: "label",
|
|
4590
4558
|
className: "mb-2 flex items-center text-[--color-text-strong]",
|
|
4591
|
-
children: [label, required && /*#__PURE__*/(0,
|
|
4559
|
+
children: [label, required && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
4592
4560
|
as: "span",
|
|
4593
4561
|
variant: "small",
|
|
4594
4562
|
className: "ml-1 text-[--color-util-red]",
|
|
4595
4563
|
children: "*"
|
|
4596
4564
|
})]
|
|
4597
|
-
}), /*#__PURE__*/(0,
|
|
4565
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
4598
4566
|
className: "flex flex-wrap gap-4 md:flex-nowrap md:gap-0 md:space-x-4",
|
|
4599
4567
|
children: options.map(option => {
|
|
4600
4568
|
const id = "".concat(name, "-").concat(option.value);
|
|
4601
|
-
return /*#__PURE__*/(0,
|
|
4569
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("label", {
|
|
4602
4570
|
htmlFor: id,
|
|
4603
4571
|
className: "mb-1 flex items-center whitespace-break-spaces rounded-lg border px-4 py-2 text-center transition duration-200 hover:border-[--color-primary-btn] ".concat(selectedValue === option.value ? "border-[--color-stroke] bg-[--color-primary-btn] text-[--color-white]" : "bg-[--color-input-bg] text-[--color-text-strong] ".concat(!isValid && selectedValue === "" ? "border-[--color-util-red]" : "border-[--color-stroke]"), " ").concat(disabled ? "cursor-not-allowed opacity-50" : "cursor-pointer"),
|
|
4604
|
-
children: [/*#__PURE__*/(0,
|
|
4572
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("input", {
|
|
4605
4573
|
id: id,
|
|
4606
4574
|
type: "radio",
|
|
4607
4575
|
tabIndex: tabIndex,
|
|
@@ -4621,7 +4589,7 @@ const RadioButton = _ref => {
|
|
|
4621
4589
|
}), option.label]
|
|
4622
4590
|
}, option.value);
|
|
4623
4591
|
})
|
|
4624
|
-
}), !isValid && /*#__PURE__*/(0,
|
|
4592
|
+
}), !isValid && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
4625
4593
|
as: "span",
|
|
4626
4594
|
variant: "small",
|
|
4627
4595
|
id: "".concat(name, "-error"),
|
|
@@ -4652,11 +4620,11 @@ function Checkbox(_ref) {
|
|
|
4652
4620
|
const id = "checkbox-".concat(name);
|
|
4653
4621
|
const errorId = "".concat(id, "-error");
|
|
4654
4622
|
const showError = !isValid && errorMessage;
|
|
4655
|
-
return /*#__PURE__*/(0,
|
|
4623
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
4656
4624
|
className: "flex flex-col mb-4",
|
|
4657
|
-
children: [/*#__PURE__*/(0,
|
|
4625
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
4658
4626
|
className: "flex items-center",
|
|
4659
|
-
children: [/*#__PURE__*/(0,
|
|
4627
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("input", {
|
|
4660
4628
|
id: id,
|
|
4661
4629
|
type: "checkbox",
|
|
4662
4630
|
name: name,
|
|
@@ -4675,13 +4643,13 @@ function Checkbox(_ref) {
|
|
|
4675
4643
|
accentColor: 'var(--color-primary-btn)'
|
|
4676
4644
|
},
|
|
4677
4645
|
className: "\n mr-2 \n rounded-sm\n ".concat(disabled ? 'opacity-50 cursor-not-allowed' : 'cursor-pointer')
|
|
4678
|
-
}), /*#__PURE__*/(0,
|
|
4646
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
4679
4647
|
variant: "label",
|
|
4680
4648
|
as: "label",
|
|
4681
4649
|
htmlFor: id,
|
|
4682
4650
|
children: label
|
|
4683
4651
|
})]
|
|
4684
|
-
}), !isValid && errorMessage && /*#__PURE__*/(0,
|
|
4652
|
+
}), !isValid && errorMessage && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
4685
4653
|
id: errorId,
|
|
4686
4654
|
variant: "small",
|
|
4687
4655
|
as: "span",
|
|
@@ -4734,25 +4702,25 @@ function Table(_ref) {
|
|
|
4734
4702
|
headCellClassName = '',
|
|
4735
4703
|
rowKeyExtractor = (row, index) => index
|
|
4736
4704
|
} = _ref;
|
|
4737
|
-
return /*#__PURE__*/(0,
|
|
4705
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
4738
4706
|
className: "wrapper w-full ".concat(className),
|
|
4739
|
-
children: /*#__PURE__*/(0,
|
|
4707
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("table", {
|
|
4740
4708
|
className: "\r min-w-full \r table-auto \r text-left \r border-collapse \r table",
|
|
4741
|
-
children: [/*#__PURE__*/(0,
|
|
4709
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("thead", {
|
|
4742
4710
|
className: "hidden sm:table-header-group",
|
|
4743
|
-
children: /*#__PURE__*/(0,
|
|
4711
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("tr", {
|
|
4744
4712
|
className: "bg-[--color-table-head-bg] ".concat(headRowClassName),
|
|
4745
|
-
children: data.map(column => /*#__PURE__*/(0,
|
|
4713
|
+
children: data.map(column => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("th", {
|
|
4746
4714
|
className: "\n border-b border-[--color-stroke] \n py-2 px-4 \n text-sm font-normal text-[--color-table-head-txt] ".concat(headCellClassName),
|
|
4747
4715
|
children: column.header
|
|
4748
4716
|
}, column.key))
|
|
4749
4717
|
})
|
|
4750
|
-
}), /*#__PURE__*/(0,
|
|
4718
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("tbody", {
|
|
4751
4719
|
children: rows.map((row, index) => {
|
|
4752
4720
|
const backgroundClass = index % 2 === 0 ? 'bg-[--color-table-row-bg-even]' : 'bg-[--color-table-row-bg-odd]';
|
|
4753
|
-
return /*#__PURE__*/(0,
|
|
4721
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("tr", {
|
|
4754
4722
|
className: "block \n sm:table-row \n mb-4 sm:mb-0 \n rounded-lg sm:rounded-none \n border sm:border-0 border-[--color-stroke] \n p-4 sm:p-0 \n shadow-sm sm:shadow-none \n hover:bg-[--color-table-row-bg-hover] ".concat(backgroundClass, " ").concat(rowClassName),
|
|
4755
|
-
children: data.map(column => /*#__PURE__*/(0,
|
|
4723
|
+
children: data.map(column => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("td", {
|
|
4756
4724
|
className: "\n block sm:table-cell \n lg:px-4 lg:py-2 \n text-sm text-[--color-text-weak] ".concat(cellClassName),
|
|
4757
4725
|
"data-label": column.header,
|
|
4758
4726
|
children: column.render ? column.render(row) : row[column.key]
|
|
@@ -13346,25 +13314,25 @@ function Dropdown(_ref) {
|
|
|
13346
13314
|
};
|
|
13347
13315
|
onChange === null || onChange === void 0 || onChange(event);
|
|
13348
13316
|
};
|
|
13349
|
-
return /*#__PURE__*/(0,
|
|
13317
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
13350
13318
|
className: "flex flex-col mb-4 ".concat(className),
|
|
13351
|
-
children: [/*#__PURE__*/(0,
|
|
13319
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)(Text, {
|
|
13352
13320
|
as: "label",
|
|
13353
13321
|
variant: "label",
|
|
13354
13322
|
className: "mb-1",
|
|
13355
13323
|
htmlFor: name,
|
|
13356
|
-
children: [label, required && /*#__PURE__*/(0,
|
|
13324
|
+
children: [label, required && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("span", {
|
|
13357
13325
|
className: "ml-1 text-[--color-util-red]",
|
|
13358
13326
|
children: "*"
|
|
13359
13327
|
})]
|
|
13360
|
-
}), /*#__PURE__*/(0,
|
|
13328
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(lo, {
|
|
13361
13329
|
children: _ref2 => {
|
|
13362
13330
|
let {
|
|
13363
13331
|
open
|
|
13364
13332
|
} = _ref2;
|
|
13365
|
-
return /*#__PURE__*/(0,
|
|
13333
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
13366
13334
|
className: "relative",
|
|
13367
|
-
children: [/*#__PURE__*/(0,
|
|
13335
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)(ft, {
|
|
13368
13336
|
id: name,
|
|
13369
13337
|
name: name,
|
|
13370
13338
|
title: title,
|
|
@@ -13377,27 +13345,27 @@ function Dropdown(_ref) {
|
|
|
13377
13345
|
dataCy
|
|
13378
13346
|
}),
|
|
13379
13347
|
className: inputClasses,
|
|
13380
|
-
children: [/*#__PURE__*/(0,
|
|
13348
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
13381
13349
|
className: "flex items-center gap-2",
|
|
13382
|
-
children: [Icon && /*#__PURE__*/(0,
|
|
13350
|
+
children: [Icon && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Icon, {
|
|
13383
13351
|
className: "h-5 w-5 text-[--color-text-weak]"
|
|
13384
|
-
}), /*#__PURE__*/(0,
|
|
13352
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("span", {
|
|
13385
13353
|
children: selectedItem ? selectedItem.label : placeholder
|
|
13386
13354
|
})]
|
|
13387
|
-
}), /*#__PURE__*/(0,
|
|
13355
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(solid_esm_ChevronDownIcon, {
|
|
13388
13356
|
"aria-hidden": "true",
|
|
13389
13357
|
className: "ml-3 mr-1 h-5 w-5 text-[--color-text-strong] bg-transparent transition-transform duration-200 ".concat(open ? 'rotate-180' : 'rotate-0')
|
|
13390
13358
|
})]
|
|
13391
|
-
}), !disabled && /*#__PURE__*/(0,
|
|
13359
|
+
}), !disabled && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(yt, {
|
|
13392
13360
|
className: "\r absolute \r left-0 \r z-10 \r mt-2 \r w-[100%] \r origin-top-right \r rounded-md \r bg-[--color-primary-bg] \r shadow-lg \r ring-1 \r ring-[--color-stroke] \r ring-opacity-1 \r focus:outline-none \r max-h-48 \r overflow-y-auto\r ",
|
|
13393
|
-
children: /*#__PURE__*/(0,
|
|
13361
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
13394
13362
|
className: "py-1",
|
|
13395
|
-
children: items.map((item, index) => /*#__PURE__*/(0,
|
|
13363
|
+
children: items.map((item, index) => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(gt, {
|
|
13396
13364
|
children: _ref3 => {
|
|
13397
13365
|
let {
|
|
13398
13366
|
active
|
|
13399
13367
|
} = _ref3;
|
|
13400
|
-
return /*#__PURE__*/(0,
|
|
13368
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("button", {
|
|
13401
13369
|
type: "button",
|
|
13402
13370
|
onClick: () => handleSelect(item),
|
|
13403
13371
|
className: "block w-full px-4 py-2 text-left text-sm text-[--color-text-strong] ".concat(active ? 'bg-[--color-input-bg]' : ''),
|
|
@@ -13409,7 +13377,7 @@ function Dropdown(_ref) {
|
|
|
13409
13377
|
})]
|
|
13410
13378
|
});
|
|
13411
13379
|
}
|
|
13412
|
-
}), !isValid && /*#__PURE__*/(0,
|
|
13380
|
+
}), !isValid && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
13413
13381
|
as: "span",
|
|
13414
13382
|
variant: "small",
|
|
13415
13383
|
id: "".concat(name, "-error"),
|
|
@@ -13468,19 +13436,19 @@ const Navbar = _ref => {
|
|
|
13468
13436
|
className = "",
|
|
13469
13437
|
maxWidth = "1200px"
|
|
13470
13438
|
} = _ref;
|
|
13471
|
-
return /*#__PURE__*/(0,
|
|
13439
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("nav", {
|
|
13472
13440
|
className: "navbar w-full bg-[--color-primary-bg] p-4 shadow-lg ".concat(className),
|
|
13473
|
-
children: /*#__PURE__*/(0,
|
|
13441
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
13474
13442
|
className: "mx-auto flex w-full items-center justify-between",
|
|
13475
13443
|
style: {
|
|
13476
13444
|
maxWidth
|
|
13477
13445
|
},
|
|
13478
|
-
children: [/*#__PURE__*/(0,
|
|
13446
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("img", {
|
|
13479
13447
|
src: logo || (c247_icon_only_png_default()),
|
|
13480
13448
|
srcSet: "".concat((c247_icon_only_png_default()), " 1x, ").concat((c247_icon_only_2x_png_default()), " 2x"),
|
|
13481
13449
|
alt: "Navbar Logo",
|
|
13482
13450
|
className: "nav-logo h-10 w-auto"
|
|
13483
|
-
}), /*#__PURE__*/(0,
|
|
13451
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
13484
13452
|
className: "right-content text-[--color-text-strong]",
|
|
13485
13453
|
children: children
|
|
13486
13454
|
})]
|
|
@@ -13507,17 +13475,17 @@ function Loader(_ref) {
|
|
|
13507
13475
|
customLoader,
|
|
13508
13476
|
className = ''
|
|
13509
13477
|
} = _ref;
|
|
13510
|
-
return isLoading && /*#__PURE__*/(0,
|
|
13478
|
+
return isLoading && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
13511
13479
|
className: "fixed inset-0 z-50 flex items-center justify-center",
|
|
13512
|
-
children: [/*#__PURE__*/(0,
|
|
13480
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
13513
13481
|
className: "absolute inset-0 bg-[--color-primary-bg] opacity-70"
|
|
13514
|
-
}), /*#__PURE__*/(0,
|
|
13482
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
13515
13483
|
className: "relative z-10 flex flex-col items-center",
|
|
13516
|
-
children: [customLoader ? customLoader : /*#__PURE__*/(0,
|
|
13484
|
+
children: [customLoader ? customLoader : /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("img", {
|
|
13517
13485
|
src: (c247_loader_gif_default()),
|
|
13518
13486
|
alt: "Loading",
|
|
13519
13487
|
className: "h-60"
|
|
13520
|
-
}), /*#__PURE__*/(0,
|
|
13488
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
13521
13489
|
variant: "h4",
|
|
13522
13490
|
className: "mt-4 animate-pulse text-center",
|
|
13523
13491
|
children: loaderText
|
|
@@ -13581,43 +13549,43 @@ const Modal = _ref => {
|
|
|
13581
13549
|
|
|
13582
13550
|
// ✅ Conditional render *after* hooks
|
|
13583
13551
|
if (!isOpen) return null;
|
|
13584
|
-
return /*#__PURE__*/(0,
|
|
13552
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
13585
13553
|
className: "fixed inset-0 z-50 flex items-center justify-center bg-black bg-opacity-50",
|
|
13586
|
-
children: /*#__PURE__*/(0,
|
|
13554
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
13587
13555
|
role: "dialog",
|
|
13588
13556
|
"aria-modal": "true",
|
|
13589
13557
|
"aria-labelledby": "modal-title",
|
|
13590
13558
|
"aria-describedby": "modal-description",
|
|
13591
13559
|
className: "relative w-11/12 max-w-fit rounded-lg bg-[--color-primary-bg] p-6 shadow-xl ".concat(className),
|
|
13592
|
-
children: [isLoading && /*#__PURE__*/(0,
|
|
13560
|
+
children: [isLoading && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
13593
13561
|
className: "absolute inset-0 z-10 flex flex-col items-center justify-center rounded-lg bg-[--color-primary-bg] ".concat(isLoading ? "opacity-1" : "pointer-events-none opacity-0"),
|
|
13594
|
-
children: /*#__PURE__*/(0,
|
|
13562
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Loader, {
|
|
13595
13563
|
isLoading: true,
|
|
13596
13564
|
loaderText: loaderText,
|
|
13597
13565
|
className: "relative z-20 h-[110px] w-[150px]"
|
|
13598
13566
|
})
|
|
13599
|
-
}), /*#__PURE__*/(0,
|
|
13567
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
13600
13568
|
className: "relative z-0 flex justify-end pb-3",
|
|
13601
|
-
children: /*#__PURE__*/(0,
|
|
13569
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("button", {
|
|
13602
13570
|
onClick: onClose,
|
|
13603
13571
|
className: "text-[--color-text-strong] hover:cursor-pointer",
|
|
13604
13572
|
"aria-label": "Close modal",
|
|
13605
|
-
children: /*#__PURE__*/(0,
|
|
13573
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(esm_XMarkIcon, {
|
|
13606
13574
|
width: "24px",
|
|
13607
13575
|
className: "text-[--color-text-strong]"
|
|
13608
13576
|
})
|
|
13609
13577
|
})
|
|
13610
|
-
}), /*#__PURE__*/(0,
|
|
13578
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
13611
13579
|
className: "relative z-0 border-b border-[--color-stroke] pb-4 text-[--color-text-strong] ".concat(headerClassName),
|
|
13612
|
-
children: /*#__PURE__*/(0,
|
|
13580
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
13613
13581
|
id: "modal-title",
|
|
13614
13582
|
children: header
|
|
13615
13583
|
})
|
|
13616
|
-
}), /*#__PURE__*/(0,
|
|
13584
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
13617
13585
|
id: "modal-description",
|
|
13618
13586
|
className: "relative z-0 my-4 text-[--color-text-weak]",
|
|
13619
13587
|
children: body
|
|
13620
|
-
}), /*#__PURE__*/(0,
|
|
13588
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
13621
13589
|
className: "relative z-0 text-[--color-text-weak] ".concat(footerClassName),
|
|
13622
13590
|
children: footer
|
|
13623
13591
|
})]
|
|
@@ -13669,31 +13637,31 @@ const CookieBanner = _ref => {
|
|
|
13669
13637
|
}
|
|
13670
13638
|
}, [imageLoaded, render]);
|
|
13671
13639
|
if (!render) return null;
|
|
13672
|
-
return /*#__PURE__*/(0,
|
|
13640
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)(Card, {
|
|
13673
13641
|
intent: intent,
|
|
13674
13642
|
className: "items-center justify-between space-x-4 p-4 transition-all duration-300 ease-in-out md:flex ".concat(show ? "translate-y-0 opacity-100" : "translate-y-3 opacity-0", " "),
|
|
13675
|
-
children: [/*#__PURE__*/(0,
|
|
13643
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
13676
13644
|
className: "items-center md:flex",
|
|
13677
|
-
children: [/*#__PURE__*/(0,
|
|
13645
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
13678
13646
|
className: "flex-shrink-1 mr-4",
|
|
13679
|
-
children: /*#__PURE__*/(0,
|
|
13647
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("img", {
|
|
13680
13648
|
src: logo || (footer_logo_group_png_default()),
|
|
13681
13649
|
srcSet: "".concat((footer_logo_group_png_default()), " 1x, ").concat((footer_logo_group_2x_png_default()), " 2x"),
|
|
13682
13650
|
alt: "C247 Logo",
|
|
13683
13651
|
className: "w-full object-contain",
|
|
13684
13652
|
onLoad: () => setImageLoaded(true)
|
|
13685
13653
|
})
|
|
13686
|
-
}), /*#__PURE__*/(0,
|
|
13654
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("p", {
|
|
13687
13655
|
className: "mr-4",
|
|
13688
13656
|
children: policyTxt
|
|
13689
13657
|
})]
|
|
13690
|
-
}), /*#__PURE__*/(0,
|
|
13658
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
13691
13659
|
className: "flex items-center space-x-4",
|
|
13692
|
-
children: [/*#__PURE__*/(0,
|
|
13660
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Button, {
|
|
13693
13661
|
rank: "primary",
|
|
13694
13662
|
text: "Accept",
|
|
13695
13663
|
onClick: onAccept
|
|
13696
|
-
}), /*#__PURE__*/(0,
|
|
13664
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Button, {
|
|
13697
13665
|
rank: "secondary",
|
|
13698
13666
|
text: linkTxt,
|
|
13699
13667
|
onClick: e => {
|
|
@@ -22306,16 +22274,16 @@ function Icon_toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var
|
|
|
22306
22274
|
|
|
22307
22275
|
|
|
22308
22276
|
|
|
22309
|
-
const C247Billing = props => /*#__PURE__*/(0,
|
|
22310
|
-
const C247Dashboard = props => /*#__PURE__*/(0,
|
|
22311
|
-
const C247Deployment = props => /*#__PURE__*/(0,
|
|
22312
|
-
const C247Form = props => /*#__PURE__*/(0,
|
|
22313
|
-
const C247Planner = props => /*#__PURE__*/(0,
|
|
22314
|
-
const C247Reports = props => /*#__PURE__*/(0,
|
|
22315
|
-
const C247Screening = props => /*#__PURE__*/(0,
|
|
22316
|
-
const C247Settings = props => /*#__PURE__*/(0,
|
|
22317
|
-
const C247Support = props => /*#__PURE__*/(0,
|
|
22318
|
-
const C247Tasks = props => /*#__PURE__*/(0,
|
|
22277
|
+
const C247Billing = props => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(billing_icon_svg_namespaceObject.ReactComponent, Icon_objectSpread({}, props));
|
|
22278
|
+
const C247Dashboard = props => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(dashboard_icon_svg_namespaceObject.ReactComponent, Icon_objectSpread({}, props));
|
|
22279
|
+
const C247Deployment = props => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(deployment_icon_svg_namespaceObject.ReactComponent, Icon_objectSpread({}, props));
|
|
22280
|
+
const C247Form = props => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(form_icon_svg_namespaceObject.ReactComponent, Icon_objectSpread({}, props));
|
|
22281
|
+
const C247Planner = props => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(planner_icon_svg_namespaceObject.ReactComponent, Icon_objectSpread({}, props));
|
|
22282
|
+
const C247Reports = props => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(reports_icon_svg_namespaceObject.ReactComponent, Icon_objectSpread({}, props));
|
|
22283
|
+
const C247Screening = props => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(screening_icon_svg_namespaceObject.ReactComponent, Icon_objectSpread({}, props));
|
|
22284
|
+
const C247Settings = props => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(settings_icon_svg_namespaceObject.ReactComponent, Icon_objectSpread({}, props));
|
|
22285
|
+
const C247Support = props => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(support_icon_svg_namespaceObject.ReactComponent, Icon_objectSpread({}, props));
|
|
22286
|
+
const C247Tasks = props => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(task_manage_icon_svg_namespaceObject.ReactComponent, Icon_objectSpread({}, props));
|
|
22319
22287
|
;// ./src/components/Icon/Icon.jsx
|
|
22320
22288
|
// Icon.jsx
|
|
22321
22289
|
|
|
@@ -22343,7 +22311,7 @@ const Icon = _ref => {
|
|
|
22343
22311
|
} = _ref;
|
|
22344
22312
|
const IconComponent = library === "hero" ? esm_namespaceObject[name] : Icon_namespaceObject[name];
|
|
22345
22313
|
if (!IconComponent) return null;
|
|
22346
|
-
return /*#__PURE__*/(0,
|
|
22314
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(IconComponent, {
|
|
22347
22315
|
className: className,
|
|
22348
22316
|
width: size,
|
|
22349
22317
|
height: size,
|
|
@@ -22374,23 +22342,23 @@ function SidebarItem(_ref) {
|
|
|
22374
22342
|
onClick
|
|
22375
22343
|
} = _ref,
|
|
22376
22344
|
props = SidebarItem_objectWithoutProperties(_ref, SidebarItem_excluded);
|
|
22377
|
-
return /*#__PURE__*/(0,
|
|
22345
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)(Component, SidebarItem_objectSpread(SidebarItem_objectSpread({
|
|
22378
22346
|
onClick: onClick,
|
|
22379
22347
|
className: "group relative flex cursor-pointer items-center justify-between p-4 transition-all duration-500 ease-in-out ".concat(active ? "bg-[--color-primary-hover]" : "", " ")
|
|
22380
22348
|
}, props), {}, {
|
|
22381
|
-
children: [/*#__PURE__*/(0,
|
|
22349
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
22382
22350
|
className: "absolute left-0 top-0 h-full w-[5px] rounded-r transition-all duration-500 ease-in-out ".concat(active ? "bg-[--color-brand-primary]" : "bg-transparent group-hover:bg-[--color-brand-primary]", " ")
|
|
22383
|
-
}), /*#__PURE__*/(0,
|
|
22351
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
22384
22352
|
className: "relative flex items-center gap-3",
|
|
22385
|
-
children: [menu.iconProps && /*#__PURE__*/(0,
|
|
22353
|
+
children: [menu.iconProps && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
22386
22354
|
className: "relative flex items-center",
|
|
22387
|
-
children: [/*#__PURE__*/(0,
|
|
22355
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Icon_Icon, SidebarItem_objectSpread({}, menu.iconProps)), !open && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("span", {
|
|
22388
22356
|
className: "absolute left-full top-1/2 ml-2 -translate-y-1/2 whitespace-nowrap rounded bg-[--color-primary-bg] px-2 py-1 text-xs text-[--color-text-strong] opacity-0 transition-opacity duration-300 group-hover:opacity-100",
|
|
22389
22357
|
children: menu.name
|
|
22390
22358
|
})]
|
|
22391
|
-
}), /*#__PURE__*/(0,
|
|
22359
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
22392
22360
|
className: "overflow-hidden whitespace-nowrap transition-all duration-500 ease-in-out ".concat(open ? "ml-2 w-auto translate-y-0 opacity-100" : "ml-0 w-0 translate-y-2 opacity-0", " "),
|
|
22393
|
-
children: /*#__PURE__*/(0,
|
|
22361
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
22394
22362
|
as: "span",
|
|
22395
22363
|
variant: "label",
|
|
22396
22364
|
children: menu.name
|
|
@@ -22420,34 +22388,34 @@ function SidebarGroup(_ref) {
|
|
|
22420
22388
|
toggleSidebar
|
|
22421
22389
|
} = _ref;
|
|
22422
22390
|
const [expanded, setExpanded] = (0,external_commonjs_react_commonjs2_react_amd_react_root_React_.useState)(false);
|
|
22423
|
-
return /*#__PURE__*/(0,
|
|
22424
|
-
children: [/*#__PURE__*/(0,
|
|
22391
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
22392
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
22425
22393
|
className: "group relative flex cursor-pointer items-center justify-between p-4 transition-all duration-500 ease-in-out",
|
|
22426
22394
|
onClick: () => {
|
|
22427
22395
|
if (!open) toggleSidebar(true);
|
|
22428
22396
|
setExpanded(!expanded);
|
|
22429
22397
|
},
|
|
22430
|
-
children: [/*#__PURE__*/(0,
|
|
22398
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
22431
22399
|
className: "absolute left-0 top-0 h-full w-[5px] rounded-r transition-all duration-300 ease-in-out ".concat(expanded || activeItem === menu.key ? "bg-[--color-brand-primary]" : "bg-[--color-stroke] group-hover:bg-[--color-brand-primary]", " ")
|
|
22432
|
-
}), /*#__PURE__*/(0,
|
|
22400
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
22433
22401
|
className: "flex items-center gap-3",
|
|
22434
|
-
children: [menu.iconProps && /*#__PURE__*/(0,
|
|
22402
|
+
children: [menu.iconProps && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Icon_Icon, SidebarGroup_objectSpread({}, menu.iconProps)), !open && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("span", {
|
|
22435
22403
|
className: "absolute left-full top-1/2 ml-2 -translate-y-1/2 whitespace-nowrap rounded bg-[--color-primary-bg] px-2 py-1 text-xs text-[--color-text-strong] opacity-0 transition-opacity duration-300 group-hover:opacity-100",
|
|
22436
22404
|
children: menu.name
|
|
22437
|
-
}), /*#__PURE__*/(0,
|
|
22405
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
22438
22406
|
className: "overflow-hidden whitespace-nowrap transition-all duration-500 ease-in-out ".concat(open ? "ml-2 w-auto translate-y-0 opacity-100" : "ml-0 w-0 translate-y-2 opacity-0", " "),
|
|
22439
|
-
children: /*#__PURE__*/(0,
|
|
22407
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
22440
22408
|
as: "span",
|
|
22441
22409
|
variant: "label",
|
|
22442
22410
|
children: menu.name
|
|
22443
22411
|
})
|
|
22444
22412
|
})]
|
|
22445
|
-
}), open && /*#__PURE__*/(0,
|
|
22413
|
+
}), open && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(esm_ChevronDownIcon, {
|
|
22446
22414
|
className: "h-4 w-4 transition-transform duration-300 ".concat(expanded ? "rotate-180" : "")
|
|
22447
22415
|
})]
|
|
22448
|
-
}), /*#__PURE__*/(0,
|
|
22416
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
22449
22417
|
className: "ml-10 mt-1 overflow-hidden transition-all duration-300 ease-in-out ".concat(expanded && open ? "max-h-96 opacity-100" : "max-h-0 opacity-0"),
|
|
22450
|
-
children: menu.children.map(child => /*#__PURE__*/(0,
|
|
22418
|
+
children: menu.children.map(child => /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(SidebarItem, {
|
|
22451
22419
|
menu: child,
|
|
22452
22420
|
open: open,
|
|
22453
22421
|
active: activeItem === child.key,
|
|
@@ -22476,7 +22444,7 @@ function Link(_ref) {
|
|
|
22476
22444
|
} = _ref,
|
|
22477
22445
|
props = Link_objectWithoutProperties(_ref, Link_excluded);
|
|
22478
22446
|
const isExternal = href.startsWith("http");
|
|
22479
|
-
return /*#__PURE__*/(0,
|
|
22447
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("a", Link_objectSpread(Link_objectSpread({
|
|
22480
22448
|
href: href,
|
|
22481
22449
|
target: newTab || isExternal ? "_blank" : undefined,
|
|
22482
22450
|
rel: newTab || isExternal ? "noopener noreferrer" : undefined,
|
|
@@ -22496,21 +22464,21 @@ function ProfileCard(_ref) {
|
|
|
22496
22464
|
href
|
|
22497
22465
|
} = _ref;
|
|
22498
22466
|
const Wrapper = href ? Link : "div";
|
|
22499
|
-
return /*#__PURE__*/(0,
|
|
22467
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)(Wrapper, {
|
|
22500
22468
|
href: href,
|
|
22501
22469
|
className: "flex items-center rounded-lg border-2 border-[--color-stroke] px-4 py-2 transition-all ".concat(href ? "cursor-pointer hover:border-[--color-primary] hover:bg-[--color-primary-bg-hover]" : "", " "),
|
|
22502
22470
|
"data-cy": "profileCard",
|
|
22503
|
-
children: [/*#__PURE__*/(0,
|
|
22504
|
-
children: [/*#__PURE__*/(0,
|
|
22471
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
22472
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
22505
22473
|
variant: "body",
|
|
22506
22474
|
as: "p",
|
|
22507
22475
|
children: user.name
|
|
22508
|
-
}), /*#__PURE__*/(0,
|
|
22476
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Text, {
|
|
22509
22477
|
variant: "caption",
|
|
22510
22478
|
as: "p",
|
|
22511
22479
|
children: user.role
|
|
22512
22480
|
})]
|
|
22513
|
-
}), /*#__PURE__*/(0,
|
|
22481
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(esm_IdentificationIcon, {
|
|
22514
22482
|
className: "ml-4 h-6 w-6 text-gray-500"
|
|
22515
22483
|
})]
|
|
22516
22484
|
});
|
|
@@ -22524,13 +22492,13 @@ function SidebarProfile(_ref) {
|
|
|
22524
22492
|
open,
|
|
22525
22493
|
href
|
|
22526
22494
|
} = _ref;
|
|
22527
|
-
return /*#__PURE__*/(0,
|
|
22495
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
22528
22496
|
className: "mt-auto flex items-center gap-3 p-2 pb-4",
|
|
22529
|
-
children: [/*#__PURE__*/(0,
|
|
22497
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("img", {
|
|
22530
22498
|
src: user.avatar,
|
|
22531
22499
|
alt: "profile",
|
|
22532
22500
|
className: "h-8 w-8 rounded-full"
|
|
22533
|
-
}), open && /*#__PURE__*/(0,
|
|
22501
|
+
}), open && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(ProfileCard, {
|
|
22534
22502
|
user: user,
|
|
22535
22503
|
href: href,
|
|
22536
22504
|
variant: "sidebar"
|
|
@@ -22588,75 +22556,75 @@ function Sidebar(_ref) {
|
|
|
22588
22556
|
onSearchChange
|
|
22589
22557
|
} = _ref;
|
|
22590
22558
|
const [open, setOpen] = (0,external_commonjs_react_commonjs2_react_amd_react_root_React_.useState)(false);
|
|
22591
|
-
return /*#__PURE__*/(0,
|
|
22559
|
+
return /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
22592
22560
|
className: "flex",
|
|
22593
|
-
children: [/*#__PURE__*/(0,
|
|
22561
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
22594
22562
|
className: " ".concat(open ? "w-[20rem]" : "w-[3rem]", " transition-width flex min-h-screen flex-col rounded bg-[--color-primary-bg] text-[--color-text-strong] duration-300 ease-in-out"),
|
|
22595
|
-
children: [/*#__PURE__*/(0,
|
|
22563
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
22596
22564
|
className: "flex items-center justify-between p-3 pr-0",
|
|
22597
|
-
children: [/*#__PURE__*/(0,
|
|
22565
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("img", {
|
|
22598
22566
|
src: logo || (c247_icon_only_png_default()),
|
|
22599
22567
|
srcSet: "".concat((c247_icon_only_png_default()), " 1x, ").concat((c247_icon_only_2x_png_default()), " 2x"),
|
|
22600
22568
|
alt: "C247 Logo",
|
|
22601
22569
|
className: "sidebar-logo w-75 object-contain"
|
|
22602
|
-
}), /*#__PURE__*/(0,
|
|
22570
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("button", {
|
|
22603
22571
|
className: "duration-400 rounded-l-lg bg-[--color-primary-btn] p-2 transition-all ease-in-out hover:bg-[--color-primary-btn-hover] focus:outline-none ".concat(open ? "translate-x-0 opacity-100" : "translate-x-4 opacity-0", " "),
|
|
22604
22572
|
onClick: () => setOpen(!open),
|
|
22605
|
-
children: /*#__PURE__*/(0,
|
|
22573
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(esm_ArrowLeftIcon, {
|
|
22606
22574
|
className: "h-5 w-5 text-[--color-white]"
|
|
22607
22575
|
})
|
|
22608
22576
|
})]
|
|
22609
|
-
}), !open && /*#__PURE__*/(0,
|
|
22577
|
+
}), !open && /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("button", {
|
|
22610
22578
|
className: "p-3 transition-all duration-700 ease-in-out focus:outline-none",
|
|
22611
22579
|
onClick: () => setOpen(!open),
|
|
22612
|
-
children: /*#__PURE__*/(0,
|
|
22580
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(esm_Bars3Icon, {
|
|
22613
22581
|
className: "h-6 w-6 text-[--color-text-strong] hover:text-[--color-primary-hover]"
|
|
22614
22582
|
})
|
|
22615
|
-
}), /*#__PURE__*/(0,
|
|
22583
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("nav", {
|
|
22616
22584
|
className: "mt-2 flex-1 space-y-1",
|
|
22617
|
-
children: [/*#__PURE__*/(0,
|
|
22585
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
22618
22586
|
className: "border-b-solid border-b-2 border-[--color-stroke] px-3 pb-2",
|
|
22619
|
-
children: open ? /*#__PURE__*/(0,
|
|
22587
|
+
children: open ? /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsxs)("div", {
|
|
22620
22588
|
className: "flex items-center gap-3 rounded bg-[--color-primary-bg-hover]",
|
|
22621
|
-
children: [/*#__PURE__*/(0,
|
|
22589
|
+
children: [/*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(esm_MagnifyingGlassIcon, {
|
|
22622
22590
|
className: "mb-2 h-6 w-6 text-[--color-text-strong]"
|
|
22623
|
-
}), /*#__PURE__*/(0,
|
|
22591
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(Inputs_Input, {
|
|
22624
22592
|
type: "text",
|
|
22625
22593
|
placeholder: "Search\u2026",
|
|
22626
22594
|
className: "mb-0",
|
|
22627
22595
|
value: searchValue,
|
|
22628
22596
|
onChange: e => onSearchChange === null || onSearchChange === void 0 ? void 0 : onSearchChange(e.target.value)
|
|
22629
22597
|
})]
|
|
22630
|
-
}) : /*#__PURE__*/(0,
|
|
22598
|
+
}) : /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("button", {
|
|
22631
22599
|
className: "transition-all duration-700 ease-in-out focus:outline-none",
|
|
22632
22600
|
onClick: () => setOpen(true),
|
|
22633
|
-
children: /*#__PURE__*/(0,
|
|
22601
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(esm_MagnifyingGlassIcon, {
|
|
22634
22602
|
className: "h-6 w-6 text-[--color-text-strong] hover:text-[--color-primary-hover]"
|
|
22635
22603
|
})
|
|
22636
22604
|
})
|
|
22637
|
-
}), /*#__PURE__*/(0,
|
|
22605
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
22638
22606
|
className: "menu-item-container",
|
|
22639
|
-
children: menus.map(menu => menu.children ? /*#__PURE__*/(0,
|
|
22607
|
+
children: menus.map(menu => menu.children ? /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(SidebarGroup, {
|
|
22640
22608
|
menu: menu,
|
|
22641
22609
|
open: open,
|
|
22642
22610
|
activeItem: activeItem,
|
|
22643
22611
|
onItemClick: onItemClick,
|
|
22644
22612
|
toggleSidebar: setOpen
|
|
22645
|
-
}, menu.id || menu.name) : /*#__PURE__*/(0,
|
|
22613
|
+
}, menu.id || menu.name) : /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(SidebarItem, {
|
|
22646
22614
|
menu: menu,
|
|
22647
22615
|
open: open,
|
|
22648
22616
|
active: activeItem === menu.key,
|
|
22649
22617
|
onClick: () => onItemClick(menu.key)
|
|
22650
22618
|
}, menu.id || menu.name))
|
|
22651
22619
|
})]
|
|
22652
|
-
}), /*#__PURE__*/(0,
|
|
22620
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)(SidebarProfile, {
|
|
22653
22621
|
user: user,
|
|
22654
22622
|
open: open,
|
|
22655
22623
|
href: "/users/".concat(user.id)
|
|
22656
22624
|
})]
|
|
22657
|
-
}), /*#__PURE__*/(0,
|
|
22625
|
+
}), /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("div", {
|
|
22658
22626
|
className: "flex-1 p-6",
|
|
22659
|
-
children: /*#__PURE__*/(0,
|
|
22627
|
+
children: /*#__PURE__*/(0,jsx_runtime_namespaceObject.jsx)("h1", {
|
|
22660
22628
|
className: "text-2xl font-bold text-[--color-text-strong]",
|
|
22661
22629
|
children: "Dashboard Content"
|
|
22662
22630
|
})
|