@star-insure/sdk 5.0.7 → 5.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/filter/Action.d.ts +1 -1
- package/dist/sdk.cjs.development.js +6 -1
- package/dist/sdk.cjs.development.js.map +1 -1
- package/dist/sdk.cjs.production.min.js +1 -1
- package/dist/sdk.cjs.production.min.js.map +1 -1
- package/dist/sdk.esm.js +6 -1
- package/dist/sdk.esm.js.map +1 -1
- package/dist/types/api/auth.d.ts +1 -0
- package/dist/types/misc/index.d.ts +2 -0
- package/package.json +1 -1
- package/src/components/filter/Action.tsx +5 -2
- package/src/types/api/auth.ts +1 -0
- package/src/types/misc/index.ts +2 -0
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { TPageHeaderAction } from "../../types";
|
|
3
|
-
export default function Action({ title, href, as, target, type, onClick, shortcutKey, actions }: TPageHeaderAction): JSX.Element;
|
|
3
|
+
export default function Action({ title, href, as, target, type, onClick, shortcutKey, backgroundColor, textColor, actions }: TPageHeaderAction): JSX.Element;
|
|
@@ -2623,9 +2623,14 @@ function Action(_ref) {
|
|
|
2623
2623
|
_ref$onClick = _ref.onClick,
|
|
2624
2624
|
_onClick = _ref$onClick === void 0 ? function () {} : _ref$onClick,
|
|
2625
2625
|
shortcutKey = _ref.shortcutKey,
|
|
2626
|
+
backgroundColor = _ref.backgroundColor,
|
|
2627
|
+
textColor = _ref.textColor,
|
|
2626
2628
|
actions = _ref.actions;
|
|
2627
2629
|
|
|
2628
|
-
var
|
|
2630
|
+
var backgroundColorClass = backgroundColor ? "bg-" + backgroundColor : 'bg-white';
|
|
2631
|
+
var textColorClass = textColor ? "text-" + textColor : '';
|
|
2632
|
+
var colorClass = (backgroundColorClass + " " + textColorClass).trim();
|
|
2633
|
+
var className = colorClass + ' rounded-full font-bold px-4 py-1.5 text-sm whitespace-nowrap hover:bg-gray-100 hover:border-gray-400 transition-colors border border-gray-300';
|
|
2629
2634
|
var tooltipId = "action-" + title;
|
|
2630
2635
|
var tooltipContent = shortcutKey ? "Ctrl + " + shortcutKey : undefined;
|
|
2631
2636
|
var actionButtonRef = React__default.useRef(null);
|