catchup-library-web 2.6.12 → 2.6.14

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "catchup-library-web",
3
- "version": "2.6.12",
3
+ "version": "2.6.14",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {
@@ -7,6 +7,7 @@ const StartButton = ({
7
7
  size,
8
8
  onClick,
9
9
  disabled,
10
+ icon,
10
11
  }: IButtonProps) => {
11
12
  const [loading, setLoading] = useState(false);
12
13
 
@@ -22,28 +23,28 @@ const StartButton = ({
22
23
  let currentHeightClassName;
23
24
  let currentLoadingSize;
24
25
  if (size === "small") {
25
- currentHeightClassName = "h-8";
26
- currentLoadingSize = 14;
27
- } else if (size === "medium") {
28
26
  currentHeightClassName = "h-10";
29
27
  currentLoadingSize = 16;
30
- } else if (size === "large") {
28
+ } else if (size === "medium") {
31
29
  currentHeightClassName = "h-12";
32
30
  currentLoadingSize = 18;
31
+ } else if (size === "large") {
32
+ currentHeightClassName = "h-14";
33
+ currentLoadingSize = 20;
33
34
  } else if (size === "unlimited") {
34
- currentLoadingSize = 14;
35
- currentHeightClassName = "h-8";
35
+ currentHeightClassName = "h-10";
36
+ currentLoadingSize = 16;
36
37
  }
37
38
 
38
39
  return (
39
40
  <button
40
- className={`px-8 py-2.5 bg-gradient-to-r from-catchup-green to-catchup-hover-green text-catchup-white font-bold text-lg rounded-catchup-full shadow-card ${
41
+ className={`px-8 py-2 bg-gradient-to-r from-catchup-green to-catchup-hover-green text-catchup-white font-bold text-lg rounded-catchup-full shadow-card ${
41
42
  loading
42
43
  ? ""
43
44
  : disabled
44
- ? "opacity-50"
45
- : "hover:from-catchup-hover-green hover:to-catchup-green hover:shadow-full-card hover:scale-105"
46
- } transition-all duration-300 transform ${currentHeightClassName}`}
45
+ ? "opacity-50"
46
+ : "hover:from-catchup-hover-green hover:to-catchup-green hover:shadow-full-card hover:scale-105"
47
+ } transition-all duration-300 transform ${currentHeightClassName || ""}`}
47
48
  onClick={internalOnClick}
48
49
  >
49
50
  {loading ? (
@@ -55,6 +56,7 @@ const StartButton = ({
55
56
  />
56
57
  ) : (
57
58
  <div className="flex flex-row justify-center items-center gap-x-2">
59
+ {icon ? <span>{icon}</span> : null}
58
60
  <p>{title}</p>
59
61
  </div>
60
62
  )}
@@ -6,4 +6,5 @@ export interface IButtonProps {
6
6
  iconPosition?: string;
7
7
  textOnly?: boolean;
8
8
  iconOnly?: boolean;
9
+ icon?: string;
9
10
  }