opus-toolkit-components 0.4.9 → 0.5.1
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.
|
@@ -716,6 +716,7 @@ function Button(_ref) {
|
|
|
716
716
|
// Optional animation for icon hover
|
|
717
717
|
className = '',
|
|
718
718
|
// Accepts additional custom class
|
|
719
|
+
title = '',
|
|
719
720
|
onClick
|
|
720
721
|
} = _ref;
|
|
721
722
|
// Define styles for button ranks
|
|
@@ -737,6 +738,8 @@ function Button(_ref) {
|
|
|
737
738
|
const classNames = "\n ".concat(state === 'disabled' ? disabledStyles : rankStyles[rank] || rankStyles.primary, "\n group\n transition \n ease-in-out \n duration-700 \n rounded-lg \n px-6 \n py-2 \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 ");
|
|
738
739
|
return /*#__PURE__*/external_react_default().createElement("button", {
|
|
739
740
|
type: type,
|
|
741
|
+
title: title,
|
|
742
|
+
"aria-label": title,
|
|
740
743
|
className: classNames,
|
|
741
744
|
onClick: state === 'disabled' ? null : onClick,
|
|
742
745
|
disabled: state === 'disabled'
|
|
@@ -9451,17 +9454,13 @@ const XMarkIcon_ForwardRef = /*#__PURE__*/ external_react_.forwardRef(XMarkIcon)
|
|
|
9451
9454
|
;// ./src/components/Modals/Modal.js
|
|
9452
9455
|
|
|
9453
9456
|
|
|
9454
|
-
|
|
9455
9457
|
const Modal = _ref => {
|
|
9456
9458
|
let {
|
|
9457
9459
|
isOpen,
|
|
9458
|
-
title,
|
|
9459
|
-
text,
|
|
9460
9460
|
onClose,
|
|
9461
|
-
|
|
9462
|
-
|
|
9463
|
-
|
|
9464
|
-
secondaryAction // Props for the secondary button
|
|
9461
|
+
header,
|
|
9462
|
+
body,
|
|
9463
|
+
footer
|
|
9465
9464
|
} = _ref;
|
|
9466
9465
|
if (!isOpen) return null;
|
|
9467
9466
|
return /*#__PURE__*/external_react_default().createElement("div", {
|
|
@@ -9477,13 +9476,9 @@ const Modal = _ref => {
|
|
|
9477
9476
|
width: "24px"
|
|
9478
9477
|
}))), /*#__PURE__*/external_react_default().createElement("div", {
|
|
9479
9478
|
className: "border-b border-greyLight100 pb-4"
|
|
9480
|
-
}, /*#__PURE__*/external_react_default().createElement("
|
|
9481
|
-
className: "
|
|
9482
|
-
},
|
|
9483
|
-
className: "mt-4"
|
|
9484
|
-
}, children), /*#__PURE__*/external_react_default().createElement("div", {
|
|
9485
|
-
className: "mt-6 flex justify-end gap-2"
|
|
9486
|
-
}, secondaryAction && /*#__PURE__*/external_react_default().createElement(Button, secondaryAction), primaryAction && /*#__PURE__*/external_react_default().createElement(Button, primaryAction))));
|
|
9479
|
+
}, header), /*#__PURE__*/external_react_default().createElement("div", {
|
|
9480
|
+
className: "my-2"
|
|
9481
|
+
}, body), /*#__PURE__*/external_react_default().createElement("div", null, footer)));
|
|
9487
9482
|
};
|
|
9488
9483
|
/* harmony default export */ const Modals_Modal = (Modal);
|
|
9489
9484
|
;// ./src/index.js
|
|
@@ -9501,4 +9496,4 @@ const Modal = _ref => {
|
|
|
9501
9496
|
/******/ })()
|
|
9502
9497
|
;
|
|
9503
9498
|
});
|
|
9504
|
-
//# sourceMappingURL=main.
|
|
9499
|
+
//# sourceMappingURL=main.d2a239456950f848f305.js.map
|