@bikdotai/bik-component-library 0.0.772-test.13 → 0.0.773-0

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.
Files changed (103) hide show
  1. package/dist/cjs/components/TablePagination/TablePaginationCard.d.ts +1 -1
  2. package/dist/cjs/components/WhatsAppTextEditor/CustomEditor.styled.d.ts +3 -3
  3. package/dist/cjs/components/WhatsAppTextEditor/WhatsAppTextEditorHeader.d.ts +1 -1
  4. package/dist/cjs/components/analytics-card/AnalyticsCard.styled.d.ts +2 -2
  5. package/dist/cjs/components/analytics-chips-and-dropdowns/CommonStyles.d.ts +5 -5
  6. package/dist/cjs/components/analytics-chips-and-dropdowns/chart/LineChart/LineChart.styled.d.ts +3 -3
  7. package/dist/cjs/components/analytics-chips-and-dropdowns/chart/heatmap/HeatMapStyled.d.ts +8 -8
  8. package/dist/cjs/components/analytics-chips-and-dropdowns/chart/heatmap/HeatMapVertical.d.ts +1 -1
  9. package/dist/cjs/components/analytics-chips-and-dropdowns/chart/linearChipGroupedChart/LinearChipGroupedChart.styled.d.ts +5 -5
  10. package/dist/cjs/components/analytics-chips-and-dropdowns/chart/scoreBlock/ScoreBlock.styled.d.ts +5 -5
  11. package/dist/cjs/components/banner/Banner.styled.d.ts +20 -20
  12. package/dist/cjs/components/bik-layout/CommonStyles.d.ts +17 -17
  13. package/dist/cjs/components/bik-layout/MockMenus.d.ts +0 -1
  14. package/dist/cjs/components/button/Button.styled.d.ts +1 -1
  15. package/dist/cjs/components/card-selection-modal/CardSelectionModal.styled.d.ts +2 -2
  16. package/dist/cjs/components/carousel-secondary/CarouselSecondary.style.d.ts +6 -6
  17. package/dist/cjs/components/checkList/CheckList.styled.d.ts +1 -1
  18. package/dist/cjs/components/colourInput/ColourInput.styled.d.ts +2 -2
  19. package/dist/cjs/components/country-code-picker/CountryCodePicker.styled.d.ts +2 -2
  20. package/dist/cjs/components/country-code-picker/CountryPicker.styled.d.ts +2 -2
  21. package/dist/cjs/components/custom-date-time/CustomDateTime.styled.d.ts +1 -1
  22. package/dist/cjs/components/dashboard-review-popup/DashboardReviewPopUp.styled.d.ts +2 -2
  23. package/dist/cjs/components/dashboard-review-popup/components/FiveStar.styled.d.ts +2 -2
  24. package/dist/cjs/components/dashboard-review-popup/components/Form.styled.d.ts +6 -6
  25. package/dist/cjs/components/datePicker/DatePicker.styled.d.ts +4 -4
  26. package/dist/cjs/components/discount-modal/DiscountModal.styled.d.ts +5 -5
  27. package/dist/cjs/components/input/Input.styled.d.ts +4 -4
  28. package/dist/cjs/components/list-item/ListItem.styled.d.ts +1 -1
  29. package/dist/cjs/components/modals/modal.styled.d.ts +4 -4
  30. package/dist/cjs/components/pagination/Pagination.styled.d.ts +1 -1
  31. package/dist/cjs/components/plans/SubscriptionPlanSelector.d.ts +2 -2
  32. package/dist/cjs/components/plans/SubscriptionPlanStyled.d.ts +2 -2
  33. package/dist/cjs/components/product-picker/ProductPicker.styled.d.ts +2 -2
  34. package/dist/cjs/components/progress-bar/ProgressBarComponent.d.ts +1 -1
  35. package/dist/cjs/components/radioList/RadioList.styled.d.ts +1 -1
  36. package/dist/cjs/components/shimmer/ShimmerComponent/ShimmerStyled.d.ts +2 -2
  37. package/dist/cjs/components/states-modal/StateModalComponent.d.ts +0 -1
  38. package/dist/cjs/components/states-modal/StateModalComponent.js +1 -9
  39. package/dist/cjs/components/switch/Switch.d.ts +3 -3
  40. package/dist/cjs/components/tabs/Tabs.styles.d.ts +5 -5
  41. package/dist/cjs/components/tag/Tag.d.ts +1 -1
  42. package/dist/cjs/components/tag/Tag.js +1 -1
  43. package/dist/cjs/components/tag/Tag.stories.d.ts +5 -5
  44. package/dist/cjs/components/tag/Tag.styled.d.ts +3 -1
  45. package/dist/cjs/components/tag/Tag.styled.js +1 -1
  46. package/dist/cjs/components/tag/model.d.ts +10 -0
  47. package/dist/cjs/components/template-context-mapper/modalElements/EditMediaModal.js +1 -1
  48. package/dist/cjs/components/testimonial-card/TestimonialCard.style.d.ts +9 -9
  49. package/dist/cjs/components/toaster/Toaster.styled.d.ts +1 -1
  50. package/dist/esm/components/TablePagination/TablePaginationCard.d.ts +1 -1
  51. package/dist/esm/components/WhatsAppTextEditor/CustomEditor.styled.d.ts +3 -3
  52. package/dist/esm/components/WhatsAppTextEditor/WhatsAppTextEditorHeader.d.ts +1 -1
  53. package/dist/esm/components/analytics-card/AnalyticsCard.styled.d.ts +2 -2
  54. package/dist/esm/components/analytics-chips-and-dropdowns/CommonStyles.d.ts +5 -5
  55. package/dist/esm/components/analytics-chips-and-dropdowns/chart/LineChart/LineChart.styled.d.ts +3 -3
  56. package/dist/esm/components/analytics-chips-and-dropdowns/chart/heatmap/HeatMapStyled.d.ts +8 -8
  57. package/dist/esm/components/analytics-chips-and-dropdowns/chart/heatmap/HeatMapVertical.d.ts +1 -1
  58. package/dist/esm/components/analytics-chips-and-dropdowns/chart/linearChipGroupedChart/LinearChipGroupedChart.styled.d.ts +5 -5
  59. package/dist/esm/components/analytics-chips-and-dropdowns/chart/scoreBlock/ScoreBlock.styled.d.ts +5 -5
  60. package/dist/esm/components/banner/Banner.styled.d.ts +20 -20
  61. package/dist/esm/components/bik-layout/CommonStyles.d.ts +17 -17
  62. package/dist/esm/components/bik-layout/MockMenus.d.ts +0 -1
  63. package/dist/esm/components/button/Button.styled.d.ts +1 -1
  64. package/dist/esm/components/card-selection-modal/CardSelectionModal.styled.d.ts +2 -2
  65. package/dist/esm/components/carousel-secondary/CarouselSecondary.style.d.ts +6 -6
  66. package/dist/esm/components/checkList/CheckList.styled.d.ts +1 -1
  67. package/dist/esm/components/colourInput/ColourInput.styled.d.ts +2 -2
  68. package/dist/esm/components/country-code-picker/CountryCodePicker.styled.d.ts +2 -2
  69. package/dist/esm/components/country-code-picker/CountryPicker.styled.d.ts +2 -2
  70. package/dist/esm/components/custom-date-time/CustomDateTime.styled.d.ts +1 -1
  71. package/dist/esm/components/dashboard-review-popup/DashboardReviewPopUp.styled.d.ts +2 -2
  72. package/dist/esm/components/dashboard-review-popup/components/FiveStar.styled.d.ts +2 -2
  73. package/dist/esm/components/dashboard-review-popup/components/Form.styled.d.ts +6 -6
  74. package/dist/esm/components/datePicker/DatePicker.styled.d.ts +4 -4
  75. package/dist/esm/components/discount-modal/DiscountModal.styled.d.ts +5 -5
  76. package/dist/esm/components/input/Input.styled.d.ts +4 -4
  77. package/dist/esm/components/list-item/ListItem.styled.d.ts +1 -1
  78. package/dist/esm/components/modals/modal.styled.d.ts +4 -4
  79. package/dist/esm/components/pagination/Pagination.styled.d.ts +1 -1
  80. package/dist/esm/components/plans/SubscriptionPlanSelector.d.ts +2 -2
  81. package/dist/esm/components/plans/SubscriptionPlanStyled.d.ts +2 -2
  82. package/dist/esm/components/product-picker/ProductPicker.styled.d.ts +2 -2
  83. package/dist/esm/components/progress-bar/ProgressBarComponent.d.ts +1 -1
  84. package/dist/esm/components/radioList/RadioList.styled.d.ts +1 -1
  85. package/dist/esm/components/shimmer/ShimmerComponent/ShimmerStyled.d.ts +2 -2
  86. package/dist/esm/components/states-modal/StateModalComponent.d.ts +0 -1
  87. package/dist/esm/components/states-modal/StateModalComponent.js +1 -9
  88. package/dist/esm/components/switch/Switch.d.ts +3 -3
  89. package/dist/esm/components/tabs/Tabs.styles.d.ts +5 -5
  90. package/dist/esm/components/tag/Tag.d.ts +1 -1
  91. package/dist/esm/components/tag/Tag.js +1 -1
  92. package/dist/esm/components/tag/Tag.stories.d.ts +5 -5
  93. package/dist/esm/components/tag/Tag.styled.d.ts +3 -1
  94. package/dist/esm/components/tag/Tag.styled.js +1 -1
  95. package/dist/esm/components/tag/model.d.ts +10 -0
  96. package/dist/esm/components/template-context-mapper/modalElements/EditMediaModal.js +1 -1
  97. package/dist/esm/components/testimonial-card/TestimonialCard.style.d.ts +9 -9
  98. package/dist/esm/components/toaster/Toaster.styled.d.ts +1 -1
  99. package/package.json +2 -2
  100. package/dist/cjs/assets/icons/archive-icon.svg.js +0 -1
  101. package/dist/cjs/assets/icons/unarchive.svg.js +0 -1
  102. package/dist/esm/assets/icons/archive-icon.svg.js +0 -1
  103. package/dist/esm/assets/icons/unarchive.svg.js +0 -1
@@ -1,11 +1,11 @@
1
1
  /// <reference types="react" />
2
2
  export declare const StyledCountryOption: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
6
6
  export declare const StyledCountryPickerContainer: import("@emotion/styled").StyledComponent<{
7
7
  theme?: import("@emotion/react").Theme | undefined;
8
- as?: import("react").ElementType<any> | undefined;
8
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
9
9
  } & {
10
10
  height?: string | undefined;
11
11
  disabled?: boolean | undefined;
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
2
  export declare const CustomDateTimeStyle: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1,9 +1,9 @@
1
1
  /// <reference types="react" />
2
2
  export declare const Container: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
6
6
  export declare const CrossIconHolder: import("@emotion/styled").StyledComponent<{
7
7
  theme?: import("@emotion/react").Theme | undefined;
8
- as?: import("react").ElementType<any> | undefined;
8
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
9
9
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1,9 +1,9 @@
1
1
  /// <reference types="react" />
2
2
  export declare const Container: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
6
6
  export declare const Button: import("@emotion/styled").StyledComponent<{
7
7
  theme?: import("@emotion/react").Theme | undefined;
8
- as?: import("react").ElementType<any> | undefined;
8
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
9
9
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1,27 +1,27 @@
1
1
  /// <reference types="react" />
2
2
  export declare const Container: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
6
6
  export declare const StarWrapper: import("@emotion/styled").StyledComponent<{
7
7
  theme?: import("@emotion/react").Theme | undefined;
8
- as?: import("react").ElementType<any> | undefined;
8
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
9
9
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
10
10
  export declare const Chip: import("@emotion/styled").StyledComponent<{
11
11
  theme?: import("@emotion/react").Theme | undefined;
12
- as?: import("react").ElementType<any> | undefined;
12
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
13
13
  } & {
14
14
  selected?: boolean | undefined;
15
15
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
16
16
  export declare const Wrapper: import("@emotion/styled").StyledComponent<{
17
17
  theme?: import("@emotion/react").Theme | undefined;
18
- as?: import("react").ElementType<any> | undefined;
18
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
19
19
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
20
20
  export declare const TextArea: import("@emotion/styled").StyledComponent<{
21
21
  theme?: import("@emotion/react").Theme | undefined;
22
- as?: import("react").ElementType<any> | undefined;
22
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
23
23
  }, import("react").DetailedHTMLProps<import("react").TextareaHTMLAttributes<HTMLTextAreaElement>, HTMLTextAreaElement>, {}>;
24
24
  export declare const Button: import("@emotion/styled").StyledComponent<{
25
25
  theme?: import("@emotion/react").Theme | undefined;
26
- as?: import("react").ElementType<any> | undefined;
26
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
27
27
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1,19 +1,19 @@
1
1
  /// <reference types="react" />
2
2
  export declare const PickerContainer: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  } & {
6
6
  selectRange: boolean;
7
7
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
8
8
  export declare const TimePickerContainer: import("@emotion/styled").StyledComponent<{
9
9
  theme?: import("@emotion/react").Theme | undefined;
10
- as?: import("react").ElementType<any> | undefined;
10
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
11
11
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
12
12
  export declare const TimeInputWrapper: import("@emotion/styled").StyledComponent<{
13
13
  theme?: import("@emotion/react").Theme | undefined;
14
- as?: import("react").ElementType<any> | undefined;
14
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
15
15
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
16
16
  export declare const TimeLabel: import("@emotion/styled").StyledComponent<{
17
17
  theme?: import("@emotion/react").Theme | undefined;
18
- as?: import("react").ElementType<any> | undefined;
18
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
19
19
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1,23 +1,23 @@
1
1
  /// <reference types="react" />
2
2
  export declare const CouponTypeContainerStyled: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  } & {
6
6
  selectedDiv: number;
7
7
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
8
8
  export declare const StaticCouponContainerStyled: import("@emotion/styled").StyledComponent<{
9
9
  theme?: import("@emotion/react").Theme | undefined;
10
- as?: import("react").ElementType<any> | undefined;
10
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
11
11
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
12
12
  export declare const DynamicCouponContainer: import("@emotion/styled").StyledComponent<{
13
13
  theme?: import("@emotion/react").Theme | undefined;
14
- as?: import("react").ElementType<any> | undefined;
14
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
15
15
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
16
16
  export declare const StyledDiscountDialogueContainer: import("@emotion/styled").StyledComponent<{
17
17
  theme?: import("@emotion/react").Theme | undefined;
18
- as?: import("react").ElementType<any> | undefined;
18
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
19
19
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
20
20
  export declare const VariablePickerContainer: import("@emotion/styled").StyledComponent<{
21
21
  theme?: import("@emotion/react").Theme | undefined;
22
- as?: import("react").ElementType<any> | undefined;
22
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
23
23
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -2,7 +2,7 @@
2
2
  import { InputStateI, InputTypeI, InputVariant } from "./Input";
3
3
  export declare const InputWrapper: import("@emotion/styled").StyledComponent<{
4
4
  theme?: import("@emotion/react").Theme | undefined;
5
- as?: import("react").ElementType<any> | undefined;
5
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
6
6
  } & {
7
7
  width?: string | undefined;
8
8
  height?: string | undefined;
@@ -16,7 +16,7 @@ export declare const InputWrapper: import("@emotion/styled").StyledComponent<{
16
16
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
17
17
  export declare const IconHolder: import("@emotion/styled").StyledComponent<{
18
18
  theme?: import("@emotion/react").Theme | undefined;
19
- as?: import("react").ElementType<any> | undefined;
19
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
20
20
  } & {
21
21
  isLeft?: boolean | undefined;
22
22
  iconSize?: string | undefined;
@@ -57,7 +57,7 @@ export declare const InputContainerSmall: import("@emotion/styled").StyledCompon
57
57
  }, {}, {}>;
58
58
  export declare const InputHeader: import("@emotion/styled").StyledComponent<{
59
59
  theme?: import("@emotion/react").Theme | undefined;
60
- as?: import("react").ElementType<any> | undefined;
60
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
61
61
  } & {
62
62
  invalid?: boolean | undefined;
63
63
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -91,7 +91,7 @@ export declare const InputFooter: import("@emotion/styled").StyledComponent<{
91
91
  }, {}, {}>;
92
92
  export declare const RootContainer: import("@emotion/styled").StyledComponent<{
93
93
  theme?: import("@emotion/react").Theme | undefined;
94
- as?: import("react").ElementType<any> | undefined;
94
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
95
95
  } & {
96
96
  width?: string | undefined;
97
97
  height?: string | undefined;
@@ -2,7 +2,7 @@
2
2
  import type { Variant } from './ListItem';
3
3
  export declare const ListItem: import("@emotion/styled").StyledComponent<{
4
4
  theme?: import("@emotion/react").Theme | undefined;
5
- as?: import("react").ElementType<any> | undefined;
5
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
6
6
  } & {
7
7
  variant: Variant;
8
8
  borderBottom?: string | undefined;
@@ -1,23 +1,23 @@
1
1
  /// <reference types="react" />
2
2
  export declare const RootContainer: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  } & {
6
6
  zIndex?: number | undefined;
7
7
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
8
8
  export declare const CentralContainer: import("@emotion/styled").StyledComponent<{
9
9
  theme?: import("@emotion/react").Theme | undefined;
10
- as?: import("react").ElementType<any> | undefined;
10
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
11
11
  } & {
12
12
  width?: string | undefined;
13
13
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
14
14
  export declare const CloseButtonContainer: import("@emotion/styled").StyledComponent<{
15
15
  theme?: import("@emotion/react").Theme | undefined;
16
- as?: import("react").ElementType<any> | undefined;
16
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
17
17
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
18
18
  export declare const CloseButtonWithTimer: import("@emotion/styled").StyledComponent<{
19
19
  theme?: import("@emotion/react").Theme | undefined;
20
- as?: import("react").ElementType<any> | undefined;
20
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
21
21
  } & {
22
22
  timerExists?: boolean | undefined;
23
23
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
2
  export declare const Pagination: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -30,11 +30,11 @@ type Props = {
30
30
  };
31
31
  export declare const HeaderWrapper: import("@emotion/styled").StyledComponent<{
32
32
  theme?: import("@emotion/react").Theme | undefined;
33
- as?: import("react").ElementType<any> | undefined;
33
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
34
34
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
35
35
  export declare const BottomWrapper: import("@emotion/styled").StyledComponent<{
36
36
  theme?: import("@emotion/react").Theme | undefined;
37
- as?: import("react").ElementType<any> | undefined;
37
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
38
38
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
39
39
  export declare const defaultTabs: {
40
40
  key: string;
@@ -1,14 +1,14 @@
1
1
  /// <reference types="react" />
2
2
  export declare const SubscriptionPlanStyled: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  } & {
6
6
  isSelected: boolean;
7
7
  isManifestPlan?: boolean | undefined;
8
8
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
9
9
  export declare const NewSubscriptionStyled: import("@emotion/styled").StyledComponent<{
10
10
  theme?: import("@emotion/react").Theme | undefined;
11
- as?: import("react").ElementType<any> | undefined;
11
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
12
12
  } & {
13
13
  showMostPopularChip: boolean;
14
14
  height?: string | undefined;
@@ -1,9 +1,9 @@
1
1
  /// <reference types="react" />
2
2
  export declare const StyledZeroState: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
6
6
  export declare const StyledProductPickerContainer: import("@emotion/styled").StyledComponent<{
7
7
  theme?: import("@emotion/react").Theme | undefined;
8
- as?: import("react").ElementType<any> | undefined;
8
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
9
9
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -8,7 +8,7 @@ export interface ProgressBarProps {
8
8
  export declare const ProgressBarComponent: (props: ProgressBarProps) => import("react/jsx-runtime").JSX.Element;
9
9
  export declare const ProgressCompletedBar: import("@emotion/styled").StyledComponent<{
10
10
  theme?: import("@emotion/react").Theme | undefined;
11
- as?: import("react").ElementType<any> | undefined;
11
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
12
12
  } & {
13
13
  color: string;
14
14
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
2
  export declare const RadioListStyled: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  export declare const ShimmerStyled: import("@emotion/styled").StyledComponent<{
3
3
  theme?: import("@emotion/react").Theme | undefined;
4
- as?: import("react").ElementType<any> | undefined;
4
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
5
5
  } & {
6
6
  isBrand?: boolean | undefined;
7
7
  direction?: "row" | "column" | undefined;
@@ -9,7 +9,7 @@ export declare const ShimmerStyled: import("@emotion/styled").StyledComponent<{
9
9
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
10
10
  export declare const ShimmerComponentStyled: import("@emotion/styled").StyledComponent<{
11
11
  theme?: import("@emotion/react").Theme | undefined;
12
- as?: import("react").ElementType<any> | undefined;
12
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
13
13
  } & {
14
14
  isBrand?: boolean | undefined;
15
15
  height: number;
@@ -7,7 +7,6 @@ export type StateModalComponentProps = {
7
7
  heading: string;
8
8
  subline: string;
9
9
  icon?: JSX.Element;
10
- iconType?: string;
11
10
  isButtonEnabled: boolean;
12
11
  type?: ButtonTypes;
13
12
  buttonText?: string;
@@ -1,9 +1 @@
1
- import{jsx as t,Fragment as e}from"react/jsx-runtime";import{useState as n}from"react";import{ComponentZindex as o}from"../../constants/zindex.js";import s from"../../assets/icons/errorIcon.svg.js";import i from"../../assets/icons/successIcon.svg.js";import r from"../../assets/icons/warningIcon.svg.js";import c from"../../assets/icons/archive-icon.svg.js";import a from"../../assets/icons/unarchive.svg.js";import{StyledModal as d}from"../modals/styledModal.js";import{Spinner as m}from"../spinner/Spinner.js";import{COLORS as l}from"../../constants/Theme.js";import{StateInterface as u,StateComponent as p}from"../states/StateComponent.js";import h from"styled-components";import{MacroStatus as g}from"@bikdotai/bik-models/crm/models/macros";const f=l=>{const h=()=>{if(l.iconType===g.LIVE)return t(I,{children:t(c,{height:40,width:40})});if(l.iconType===g.ARCHIVED)return t(I,{children:t(a,{height:40,width:40})});switch(f){case u.SUCCESS:return t(i,{});case u.WARNING:return t(r,{});case u.ERROR:return t(s,{});case u.LOADING:return t(m,{size:"large"});default:return t(e,{})}},{states:f,heading:j,subline:y,icon:b=h(),isButtonEnabled:x,type:C,buttonText:T,onButtonClick:B,leadingIcon:O,width:v,zIndex:w,headerImage:k,iconHeight:A,iconWidth:E,closeButtonType:S,secondaryButtonText:D}=l,[L,N]=n(!0);return t(d,Object.assign({"data-test":l["data-test"],open:L,onClose:function(){l.onClose&&l.onClose(),N(!1)},closeOnOutsideClick:!(f===u.LOADING),centralContainerStyles:{display:"flex",alignItems:"center",justifyContent:"center",width:v},hideCrossButton:f===u.LOADING,zIndex:w||o.STATE_MODAL},{children:t(p,Object.assign({states:f,heading:j,subline:y,isButtonEnabled:x,leadingIcon:O,type:C,buttonText:T,onButtonClick:B,icon:b,width:v||400,headerImage:k,iconHeight:A,iconWidth:E,closeButtonType:S,secondaryButtonText:D},{children:l.children}))}))},I=h.div`
2
- display: flex;
3
- align-items: center;
4
- justify-content: center;
5
- width: 64px;
6
- height: 64px;
7
- background-color: ${l.background.base};
8
- border-radius: 32px;
9
- `;export{f as StateModalComponent};
1
+ import{jsx as t}from"react/jsx-runtime";import{useState as e}from"react";import{ComponentZindex as n}from"../../constants/zindex.js";import o from"../../assets/icons/errorIcon.svg.js";import s from"../../assets/icons/successIcon.svg.js";import i from"../../assets/icons/warningIcon.svg.js";import{StyledModal as r}from"../modals/styledModal.js";import{Spinner as c}from"../spinner/Spinner.js";import{StateInterface as a,StateComponent as d}from"../states/StateComponent.js";const l=l=>{const m=()=>p==a.SUCCESS?t(s,{}):p==a.WARNING?t(i,{}):p==a.ERROR?t(o,{}):p===a.LOADING?t(c,{size:"large"}):void 0,{states:p,heading:u,subline:g,icon:h=m(),isButtonEnabled:I,type:f,buttonText:C,onButtonClick:j,leadingIcon:x,width:y,zIndex:B,headerImage:O,iconHeight:b,iconWidth:T,closeButtonType:S,secondaryButtonText:A}=l,[E,N]=e(!0);return t(r,Object.assign({"data-test":l["data-test"],open:E,onClose:function(){l.onClose&&l.onClose(),N(!1)},closeOnOutsideClick:!(p===a.LOADING),centralContainerStyles:{display:"flex",alignItems:"center",justifyContent:"center",width:y},hideCrossButton:p===a.LOADING,zIndex:B||n.STATE_MODAL},{children:t(d,Object.assign({states:p,heading:u,subline:g,isButtonEnabled:I,leadingIcon:x,type:f,buttonText:C,onButtonClick:j,icon:h,width:y||400,headerImage:O,iconHeight:b,iconWidth:T,closeButtonType:S,secondaryButtonText:A},{children:l.children}))}))};export{l as StateModalComponent};
@@ -3,7 +3,7 @@ import { SwitchColorProps, SwitchProps } from './Switch.d';
3
3
  export declare const Switch: import("react").ForwardRefExoticComponent<SwitchProps & import("react").RefAttributes<HTMLButtonElement>>;
4
4
  export declare const SwitchContainer: import("@emotion/styled").StyledComponent<{
5
5
  theme?: import("@emotion/react").Theme | undefined;
6
- as?: import("react").ElementType<any> | undefined;
6
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
7
7
  } & {
8
8
  trackLength: number;
9
9
  trackHeight: number;
@@ -16,7 +16,7 @@ export declare const SwitchContainer: import("@emotion/styled").StyledComponent<
16
16
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
17
17
  export declare const Thumb: import("@emotion/styled").StyledComponent<{
18
18
  theme?: import("@emotion/react").Theme | undefined;
19
- as?: import("react").ElementType<any> | undefined;
19
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
20
20
  } & {
21
21
  value: boolean;
22
22
  duration: number;
@@ -24,7 +24,7 @@ export declare const Thumb: import("@emotion/styled").StyledComponent<{
24
24
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
25
25
  export declare const Loader: import("@emotion/styled").StyledComponent<{
26
26
  theme?: import("@emotion/react").Theme | undefined;
27
- as?: import("react").ElementType<any> | undefined;
27
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
28
28
  } & {
29
29
  value: boolean;
30
30
  trackColor: SwitchColorProps;
@@ -2,17 +2,17 @@
2
2
  import { TabItemProps, TabItemTextProps } from './Tabs.model';
3
3
  export declare const TabHeader: import("@emotion/styled").StyledComponent<{
4
4
  theme?: import("@emotion/react").Theme | undefined;
5
- as?: import("react").ElementType<any> | undefined;
5
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
6
6
  } & {
7
7
  bgColor?: string | undefined;
8
8
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
9
9
  export declare const TabItem: import("@emotion/styled").StyledComponent<{
10
10
  theme?: import("@emotion/react").Theme | undefined;
11
- as?: import("react").ElementType<any> | undefined;
11
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
12
12
  } & TabItemProps, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
13
13
  export declare const TrailingNumberContainer: import("@emotion/styled").StyledComponent<{
14
14
  theme?: import("@emotion/react").Theme | undefined;
15
- as?: import("react").ElementType<any> | undefined;
15
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
16
16
  } & {
17
17
  selected: boolean;
18
18
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -30,9 +30,9 @@ export declare const TabItemText: import("@emotion/styled").StyledComponent<{
30
30
  } & TabItemTextProps, {}, {}>;
31
31
  export declare const EmptyTab: import("@emotion/styled").StyledComponent<{
32
32
  theme?: import("@emotion/react").Theme | undefined;
33
- as?: import("react").ElementType<any> | undefined;
33
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
34
34
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
35
35
  export declare const RightComponent: import("@emotion/styled").StyledComponent<{
36
36
  theme?: import("@emotion/react").Theme | undefined;
37
- as?: import("react").ElementType<any> | undefined;
37
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
38
38
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1,5 +1,5 @@
1
1
  import { TagProps } from './model';
2
2
  export declare const Tag: {
3
- ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, }: TagProps): import("react/jsx-runtime").JSX.Element;
3
+ ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, backgroundColor, borderRadius, }: TagProps): import("react/jsx-runtime").JSX.Element;
4
4
  displayName: string;
5
5
  };
@@ -1 +1 @@
1
- import{jsx as e,jsxs as i}from"react/jsx-runtime";import n from"react";import{Tooltip as t}from"../tooltips/Tooltip.js";import{AiBodyCaption as a,BodyCaption as r}from"../TypographyStyle.js";import{ValidTagTypeMap as c}from"./model.js";import{Tag as s}from"./Tag.styled.js";import{getTagIconColor as o}from"./themes.js";const l=l=>{let{tagText:g,LeadingIcon:d,TrailingIcon:m,onLeadingIconClicked:p,leadingIconId:b,trailingIconId:j,onTrailingIconClicked:O,theme:h="light",type:u="neutral",variant:f="regular",version:I,cursor:T,alignIcon:y,noBorder:w,tagHtmlText:N,contentPadding:k,leadingIconTooltip:C,trailingIconTooltip:L,tagColor:x,numberOfLines:v}=l,E=g;const $=h;let B=u;c[f][u]||(B="neutral"),"circle"===f&&"number"==typeof E&&E>99&&(E="99+");const P={height:"compressed"===f?12:16,width:"compressed"===f?12:16,color:o(h,B),style:{display:"block"}};return e(s,Object.assign({cursor:T,theme:$,type:u,variant:f,version:I,alignIcon:y,noBorder:w,contentPadding:k},{children:i("div",Object.assign({className:"container"},{children:[d&&(C?e(t,Object.assign({},C,{children:e("button",Object.assign({className:"icon-leading",onClick:p,id:`${b}-wrapper`||"leading-icon-wrapper"},{children:n.createElement(d,Object.assign(Object.assign({},P),{id:b||"leading-icon"}))}))})):e("button",Object.assign({className:"icon-leading",onClick:p,id:`${b}-wrapper`||"leading-icon-wrapper"},{children:n.createElement(d,Object.assign(Object.assign({},P),{id:b||"leading-icon"}))}))),N&&("ai"===u&&"light"===h?e(a,Object.assign({numberOfLines:v},{children:N})):e(r,Object.assign({className:"text",numberOfLines:v},{children:N}))),!N&&""!==E&&("ai"===u&&"light"===h?e(a,Object.assign({numberOfLines:v},{children:E})):e(r,Object.assign({className:"text",color:x,numberOfLines:v},{children:E}))),m&&(L?e(t,Object.assign({},L,{children:e("button",Object.assign({className:"icon-trailing",onClick:O,id:`${j}-wrapper`||"trailing-icon-wrapper"},{children:n.createElement(m,Object.assign(Object.assign({},P),{id:j||"trailing-icon"}))}))})):e("button",Object.assign({className:"icon-trailing",onClick:O,id:`${j}-wrapper`||"trailing-icon-wrapper"},{children:n.createElement(m,Object.assign(Object.assign({},P),{id:j||"trailing-icon"}))})))]}))}))};l.displayName="Tag";export{l as Tag};
1
+ import{jsx as e,jsxs as i}from"react/jsx-runtime";import n from"react";import{Tooltip as r}from"../tooltips/Tooltip.js";import{AiBodyCaption as t,BodyCaption as a}from"../TypographyStyle.js";import{ValidTagTypeMap as c}from"./model.js";import{Tag as o}from"./Tag.styled.js";import{getTagIconColor as s}from"./themes.js";const l=l=>{let{tagText:g,LeadingIcon:d,TrailingIcon:m,onLeadingIconClicked:p,leadingIconId:b,trailingIconId:j,onTrailingIconClicked:O,theme:h="light",type:u="neutral",variant:f="regular",version:I,cursor:T,alignIcon:y,noBorder:k,tagHtmlText:w,contentPadding:C,leadingIconTooltip:N,trailingIconTooltip:L,tagColor:x,numberOfLines:v,backgroundColor:E,borderRadius:$}=l,B=g;const P=h;let R=u;c[f][u]||(R="neutral"),"circle"===f&&"number"==typeof B&&B>99&&(B="99+");const H={height:"compressed"===f?12:16,width:"compressed"===f?12:16,color:s(h,R),style:{display:"block"}};return e(o,Object.assign({cursor:T,theme:P,type:u,variant:f,version:I,alignIcon:y,noBorder:k,contentPadding:C,backgroundColor:E,borderRadius:$},{children:i("div",Object.assign({className:"container"},{children:[d&&(N?e(r,Object.assign({},N,{children:e("button",Object.assign({className:"icon-leading",onClick:p,id:`${b}-wrapper`||"leading-icon-wrapper"},{children:n.createElement(d,Object.assign(Object.assign({},H),{id:b||"leading-icon"}))}))})):e("button",Object.assign({className:"icon-leading",onClick:p,id:`${b}-wrapper`||"leading-icon-wrapper"},{children:n.createElement(d,Object.assign(Object.assign({},H),{id:b||"leading-icon"}))}))),w&&("ai"===u&&"light"===h?e(t,Object.assign({numberOfLines:v},{children:w})):e(a,Object.assign({className:"text",numberOfLines:v},{children:w}))),!w&&""!==B&&("ai"===u&&"light"===h?e(t,Object.assign({numberOfLines:v},{children:B})):e(a,Object.assign({className:"text",color:x,numberOfLines:v},{children:B}))),m&&(L?e(r,Object.assign({},L,{children:e("button",Object.assign({className:"icon-trailing",onClick:O,id:`${j}-wrapper`||"trailing-icon-wrapper"},{children:n.createElement(m,Object.assign(Object.assign({},H),{id:j||"trailing-icon"}))}))})):e("button",Object.assign({className:"icon-trailing",onClick:O,id:`${j}-wrapper`||"trailing-icon-wrapper"},{children:n.createElement(m,Object.assign(Object.assign({},H),{id:j||"trailing-icon"}))})))]}))}))};l.displayName="Tag";export{l as Tag};
@@ -1,22 +1,22 @@
1
1
  import { ComponentMeta, ComponentStory } from '@storybook/react';
2
2
  declare const _default: ComponentMeta<{
3
- ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, }: import("./model").TagProps): import("react/jsx-runtime").JSX.Element;
3
+ ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, backgroundColor, borderRadius, }: import("./model").TagProps): import("react/jsx-runtime").JSX.Element;
4
4
  displayName: string;
5
5
  }>;
6
6
  export default _default;
7
7
  export declare const Default: ComponentStory<{
8
- ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, }: import("./model").TagProps): import("react/jsx-runtime").JSX.Element;
8
+ ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, backgroundColor, borderRadius, }: import("./model").TagProps): import("react/jsx-runtime").JSX.Element;
9
9
  displayName: string;
10
10
  }>;
11
11
  export declare const WithIcons: ComponentStory<{
12
- ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, }: import("./model").TagProps): import("react/jsx-runtime").JSX.Element;
12
+ ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, backgroundColor, borderRadius, }: import("./model").TagProps): import("react/jsx-runtime").JSX.Element;
13
13
  displayName: string;
14
14
  }>;
15
15
  export declare const WithIconTooltips: ComponentStory<{
16
- ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, }: import("./model").TagProps): import("react/jsx-runtime").JSX.Element;
16
+ ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, backgroundColor, borderRadius, }: import("./model").TagProps): import("react/jsx-runtime").JSX.Element;
17
17
  displayName: string;
18
18
  }>;
19
19
  export declare const DarkTheme: ComponentStory<{
20
- ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, }: import("./model").TagProps): import("react/jsx-runtime").JSX.Element;
20
+ ({ tagText, LeadingIcon, TrailingIcon, onLeadingIconClicked, leadingIconId, trailingIconId, onTrailingIconClicked, theme, type, variant, version, cursor, alignIcon, noBorder, tagHtmlText, contentPadding, leadingIconTooltip, trailingIconTooltip, tagColor, numberOfLines, backgroundColor, borderRadius, }: import("./model").TagProps): import("react/jsx-runtime").JSX.Element;
21
21
  displayName: string;
22
22
  }>;
@@ -2,7 +2,7 @@
2
2
  import { TagTheme, TagType, TagVariant } from './model';
3
3
  export declare const Tag: import("@emotion/styled").StyledComponent<{
4
4
  theme?: import("@emotion/react").Theme | undefined;
5
- as?: import("react").ElementType<any> | undefined;
5
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
6
6
  } & {
7
7
  theme: TagTheme;
8
8
  type: TagType;
@@ -12,4 +12,6 @@ export declare const Tag: import("@emotion/styled").StyledComponent<{
12
12
  alignIcon?: string | undefined;
13
13
  noBorder?: boolean | undefined;
14
14
  contentPadding?: number | undefined;
15
+ backgroundColor?: string | undefined;
16
+ borderRadius?: string | number | undefined;
15
17
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1 +1 @@
1
- import c from"@emotion/styled/base";import{getPadding as l,getBackgroundColor as b,generateBorder as d,getTextColor as g}from"./themes.js";const n=c("div","production"===process.env.NODE_ENV?{target:"e930jd90"}:{target:"e930jd90",label:"Tag"})("cursor:",(c=>{var l;return null!==(l=c.cursor)&&void 0!==l?l:"default"}),";",(c=>"regular"===c.variant?"display: block;\n\t\t min-height: 26px;\n\t\t":"min-height: 20px;")," .container{display:flex;align-items:",(c=>c.alignIcon?c.alignIcon:"center"),";gap:6px;padding:",(c=>l(c.variant)),";padding:",(c=>c.contentPadding?c.contentPadding:l(c.variant)),"px;background:",(c=>b(c.theme,c.type)),";border-radius:",(c=>"regular"===c.variant?"4px":"12px"),";",(c=>!c.noBorder&&"light"===c.theme&&`border: ${"2.0"===c.version?.5:1}px solid ${d(c.type,c.theme)};`)," .text{color:",(c=>g(c.theme,c.type)),";}.icon-trailing{all:unset;display:flex;}.icon-leading{all:unset;display:flex;}}"+("production"===process.env.NODE_ENV?"":"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlRhZy5zdHlsZWQudHN4Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUU4QiIsImZpbGUiOiJUYWcuc3R5bGVkLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBzdHlsZWQgZnJvbSAnQGVtb3Rpb24vc3R5bGVkJztcclxuaW1wb3J0IHsgZ2VuZXJhdGVCb3JkZXIsIGdldEJhY2tncm91bmRDb2xvciwgZ2V0UGFkZGluZywgZ2V0VGV4dENvbG9yLCB9IGZyb20gJy4vdGhlbWVzJztcclxuZXhwb3J0IGNvbnN0IFRhZyA9IHN0eWxlZC5kaXYgYFxuXHRjdXJzb3I6ICR7KHByb3BzKSA9PiB7IHZhciBfYTsgcmV0dXJuIChfYSA9IHByb3BzLmN1cnNvcikgIT09IG51bGwgJiYgX2EgIT09IHZvaWQgMCA/IF9hIDogJ2RlZmF1bHQnOyB9fTtcblx0JHsocHJvcHMpID0+IHByb3BzLnZhcmlhbnQgPT09ICdyZWd1bGFyJ1xyXG4gICAgPyBgZGlzcGxheTogYmxvY2s7XG5cdFx0ICAgICBtaW4taGVpZ2h0OiAyNnB4O1xuXHRcdGBcclxuICAgIDogYG1pbi1oZWlnaHQ6IDIwcHg7YH1cblx0LmNvbnRhaW5lciB7XG5cdFx0ZGlzcGxheTogZmxleDtcblx0XHRhbGlnbi1pdGVtczogJHsocHJvcHMpID0+IChwcm9wcy5hbGlnbkljb24gPyBwcm9wcy5hbGlnbkljb24gOiAnY2VudGVyJyl9O1xuXHRcdGdhcDogNnB4O1xuXHRcdHBhZGRpbmc6ICR7KHByb3BzKSA9PiBnZXRQYWRkaW5nKHByb3BzLnZhcmlhbnQpfTtcblx0XHRwYWRkaW5nOiAkeyhwcm9wcykgPT4gcHJvcHMuY29udGVudFBhZGRpbmdcclxuICAgID8gcHJvcHMuY29udGVudFBhZGRpbmdcclxuICAgIDogZ2V0UGFkZGluZyhwcm9wcy52YXJpYW50KX1weDtcblx0XHRiYWNrZ3JvdW5kOiAkeyhwcm9wcykgPT4gZ2V0QmFja2dyb3VuZENvbG9yKHByb3BzLnRoZW1lLCBwcm9wcy50eXBlKX07XG5cblx0XHRib3JkZXItcmFkaXVzOiAkeyhwcm9wcykgPT4gKHByb3BzLnZhcmlhbnQgPT09ICdyZWd1bGFyJyA/ICc0cHgnIDogJzEycHgnKX07XG5cblx0XHQkeyhwcm9wcykgPT4gIXByb3BzLm5vQm9yZGVyICYmXHJcbiAgICBwcm9wcy50aGVtZSA9PT0gJ2xpZ2h0JyAmJlxyXG4gICAgYGJvcmRlcjogJHtwcm9wcy52ZXJzaW9uID09PSAnMi4wJyA/IDAuNSA6IDF9cHggc29saWQgJHtnZW5lcmF0ZUJvcmRlcihwcm9wcy50eXBlLCBwcm9wcy50aGVtZSl9O2B9XG5cblx0XHQudGV4dCB7XG5cdFx0XHRjb2xvcjogJHsocHJvcHMpID0+IGdldFRleHRDb2xvcihwcm9wcy50aGVtZSwgcHJvcHMudHlwZSl9O1xuXHRcdH1cblxuXHRcdC5pY29uLXRyYWlsaW5nIHtcblx0XHRcdGFsbDogdW5zZXQ7XG5cdFx0XHRkaXNwbGF5OiBmbGV4O1xuXHRcdH1cblxuXHRcdC5pY29uLWxlYWRpbmcge1xuXHRcdFx0YWxsOiB1bnNldDtcblx0XHRcdGRpc3BsYXk6IGZsZXg7XG5cdFx0fVxuXHR9XG5gO1xyXG4vLyMgc291cmNlTWFwcGluZ1VSTD1UYWcuc3R5bGVkLmpzLm1hcCJdfQ== */"));export{n as Tag};
1
+ import c from"@emotion/styled/base";import{getPadding as b,getBackgroundColor as d,generateBorder as l,getTextColor as g}from"./themes.js";const I=c("div","production"===process.env.NODE_ENV?{target:"e930jd90"}:{target:"e930jd90",label:"Tag"})("cursor:",(c=>{var b;return null!==(b=c.cursor)&&void 0!==b?b:"default"}),";",(c=>"regular"===c.variant?"display: block;\n\t\t min-height: 26px;\n\t\t":"min-height: 20px;")," .container{display:flex;align-items:",(c=>c.alignIcon?c.alignIcon:"center"),";gap:6px;padding:",(c=>b(c.variant)),";padding:",(c=>c.contentPadding?c.contentPadding:b(c.variant)),"px;background:",(c=>{var b;return null!==(b=c.backgroundColor)&&void 0!==b?b:d(c.theme,c.type)}),";border-radius:",(c=>void 0!==c.borderRadius?"number"==typeof c.borderRadius?`${c.borderRadius}px`:c.borderRadius:"regular"===c.variant?"4px":"12px"),";",(c=>!c.noBorder&&"light"===c.theme&&`border: ${"2.0"===c.version?.5:1}px solid ${l(c.type,c.theme)};`)," .text{color:",(c=>g(c.theme,c.type)),";}.icon-trailing{all:unset;display:flex;}.icon-leading{all:unset;display:flex;}}"+("production"===process.env.NODE_ENV?"":"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlRhZy5zdHlsZWQudHN4Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUU4QiIsImZpbGUiOiJUYWcuc3R5bGVkLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBzdHlsZWQgZnJvbSAnQGVtb3Rpb24vc3R5bGVkJztcclxuaW1wb3J0IHsgZ2VuZXJhdGVCb3JkZXIsIGdldEJhY2tncm91bmRDb2xvciwgZ2V0UGFkZGluZywgZ2V0VGV4dENvbG9yLCB9IGZyb20gJy4vdGhlbWVzJztcclxuZXhwb3J0IGNvbnN0IFRhZyA9IHN0eWxlZC5kaXYgYFxuXHRjdXJzb3I6ICR7KHByb3BzKSA9PiB7IHZhciBfYTsgcmV0dXJuIChfYSA9IHByb3BzLmN1cnNvcikgIT09IG51bGwgJiYgX2EgIT09IHZvaWQgMCA/IF9hIDogJ2RlZmF1bHQnOyB9fTtcblx0JHsocHJvcHMpID0+IHByb3BzLnZhcmlhbnQgPT09ICdyZWd1bGFyJ1xyXG4gICAgPyBgZGlzcGxheTogYmxvY2s7XG5cdFx0ICAgICBtaW4taGVpZ2h0OiAyNnB4O1xuXHRcdGBcclxuICAgIDogYG1pbi1oZWlnaHQ6IDIwcHg7YH1cblx0LmNvbnRhaW5lciB7XG5cdFx0ZGlzcGxheTogZmxleDtcblx0XHRhbGlnbi1pdGVtczogJHsocHJvcHMpID0+IChwcm9wcy5hbGlnbkljb24gPyBwcm9wcy5hbGlnbkljb24gOiAnY2VudGVyJyl9O1xuXHRcdGdhcDogNnB4O1xuXHRcdHBhZGRpbmc6ICR7KHByb3BzKSA9PiBnZXRQYWRkaW5nKHByb3BzLnZhcmlhbnQpfTtcblx0XHRwYWRkaW5nOiAkeyhwcm9wcykgPT4gcHJvcHMuY29udGVudFBhZGRpbmdcclxuICAgID8gcHJvcHMuY29udGVudFBhZGRpbmdcclxuICAgIDogZ2V0UGFkZGluZyhwcm9wcy52YXJpYW50KX1weDtcblx0XHRiYWNrZ3JvdW5kOiAkeyhwcm9wcykgPT4geyB2YXIgX2E7IHJldHVybiAoX2EgPSBwcm9wcy5iYWNrZ3JvdW5kQ29sb3IpICE9PSBudWxsICYmIF9hICE9PSB2b2lkIDAgPyBfYSA6IGdldEJhY2tncm91bmRDb2xvcihwcm9wcy50aGVtZSwgcHJvcHMudHlwZSk7IH19O1xuXG5cdFx0Ym9yZGVyLXJhZGl1czogJHsocHJvcHMpID0+IHByb3BzLmJvcmRlclJhZGl1cyAhPT0gdW5kZWZpbmVkXHJcbiAgICA/IHR5cGVvZiBwcm9wcy5ib3JkZXJSYWRpdXMgPT09ICdudW1iZXInXHJcbiAgICAgICAgPyBgJHtwcm9wcy5ib3JkZXJSYWRpdXN9cHhgXHJcbiAgICAgICAgOiBwcm9wcy5ib3JkZXJSYWRpdXNcclxuICAgIDogcHJvcHMudmFyaWFudCA9PT0gJ3JlZ3VsYXInXHJcbiAgICAgICAgPyAnNHB4J1xyXG4gICAgICAgIDogJzEycHgnfTtcblxuXHRcdCR7KHByb3BzKSA9PiAhcHJvcHMubm9Cb3JkZXIgJiZcclxuICAgIHByb3BzLnRoZW1lID09PSAnbGlnaHQnICYmXHJcbiAgICBgYm9yZGVyOiAke3Byb3BzLnZlcnNpb24gPT09ICcyLjAnID8gMC41IDogMX1weCBzb2xpZCAke2dlbmVyYXRlQm9yZGVyKHByb3BzLnR5cGUsIHByb3BzLnRoZW1lKX07YH1cblxuXHRcdC50ZXh0IHtcblx0XHRcdGNvbG9yOiAkeyhwcm9wcykgPT4gZ2V0VGV4dENvbG9yKHByb3BzLnRoZW1lLCBwcm9wcy50eXBlKX07XG5cdFx0fVxuXG5cdFx0Lmljb24tdHJhaWxpbmcge1xuXHRcdFx0YWxsOiB1bnNldDtcblx0XHRcdGRpc3BsYXk6IGZsZXg7XG5cdFx0fVxuXG5cdFx0Lmljb24tbGVhZGluZyB7XG5cdFx0XHRhbGw6IHVuc2V0O1xuXHRcdFx0ZGlzcGxheTogZmxleDtcblx0XHR9XG5cdH1cbmA7XHJcbi8vIyBzb3VyY2VNYXBwaW5nVVJMPVRhZy5zdHlsZWQuanMubWFwIl19 */"));export{I as Tag};
@@ -100,4 +100,14 @@ export interface TagProps extends React.BaseHTMLAttributes<HTMLDivElement> {
100
100
  contentPadding?: number;
101
101
  tagColor?: string;
102
102
  numberOfLines?: number;
103
+ /**
104
+ * Override the computed background color of the tag container.
105
+ * @default undefined (uses theme/type color)
106
+ */
107
+ backgroundColor?: string;
108
+ /**
109
+ * Override the border-radius of the tag container.
110
+ * @default undefined (uses variant-based radius: 4px for regular, 12px otherwise)
111
+ */
112
+ borderRadius?: string | number;
103
113
  }
@@ -1 +1 @@
1
- import{jsx as e,Fragment as t,jsxs as o}from"react/jsx-runtime";import i from"../../../assets/icons/arrow_back.svg.js";import a from"../../../assets/icons/info.svg.js";import"../../curtain/CurtainHelper.js";import{PickerType as r}from"../../variable-picker-v3/model.js";import{useState as s,useEffect as l}from"react";import{Button as n}from"../../button/Button.js";import{BikImageCropper as p}from"../../image-cropper/BikImageCropper.js";import"../../image-compress/ImageCompress.js";import"../../states/StateComponent.js";import"../../../_virtual/_tslib.js";import"../../states-modal/StateModalComponent.js";import"../../modals/styledModal.js";import{InputWithVariables as d}from"../../input-with-vars/InputWithVariables.js";import{PureSpinner as m}from"../../spinner/Spinner.js";import"../../template-preview/TemplatePreview.js";import"../../template-preview/WhatsApp/WhatsAppLikePreview.js";import"../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js";import{DEFAULT_THEME as c,COLORS as g}from"../../../constants/Theme.js";import{HEADER_TYPES as h}from"../../template-preview/models/TemplateMeta.js";import{POD as u}from"../../template-preview/models/WhatsAppTemplate.js";import"../../template-preview/models/Channels.js";import{TitleRegular as f,TitleMedium as v,BodySecondary as b,BodyCaption as j}from"../../TypographyStyle.js";import{validateURL as y}from"../../../utils/validator.js";import x from"../../../assets/icons/file.svg.js";import C from"../../../assets/icons/filePdf.svg.js";import I from"../../../assets/icons/image.svg.js";import M from"../../../assets/icons/upload.svg.js";import{useTemplateModalContext as w}from"../context/templateModalContext.js";import{isVariable as k}from"../utils/validateIsUrl.js";const E=E=>{let{setOpenEditMedia:O,mediaComponentFormat:A,variableListForImage:V,openEditMedia:T,uploadMedia:B,fileRef:D,useEditWhatsappTemplateMediaResponse:P,skipAddVariable:U}=E;const{pod:L,setHideCrossButton:G,setHideFooterButton:R}=w(),[W,S]=s(""),[H,$]=s(void 0),[F,_]=s(!1),[N,q]=s("");let z;if(l((()=>(R(!0),()=>{R(!1)})),[]),l((()=>{const e=document.querySelector('[class*="ModalWrapper"]');e&&$(e)}),[P.loading]),z=A===h.IMAGE?"image/png, image/jpeg":A===h.VIDEO?"video/mp4":"application/pdf",!T)return e(t,{});const J=()=>A===h.IMAGE?"Image":A===h.VIDEO?"Video":"Document";return o(t,{children:[o("div",Object.assign({style:{display:"flex",gap:"10px",alignItems:"center",marginBottom:"16px"}},{children:[e(i,{onClick:e=>{e.stopPropagation(),O(!1),S("")},style:{cursor:"pointer"},width:16,height:16}),e(f,{children:"Update Media"})]})),o("div",Object.assign({style:{position:"relative",padding:16,borderRadius:4,border:F?`1px dashed ${c.colorsV2.stroke.negative.vibrant}`:`1px dashed ${c.colorsV2.stroke.primary}`,backgroundColor:c.colorsV2.surface.subdued,width:"100%",height:"100%",alignItems:"center",display:P.loading?"flex":"initial"}},{children:[o("div",Object.assign({style:{marginBottom:24,display:"flex",justifyContent:"center",flexDirection:"column",alignItems:"center",gap:16}},{children:[P.loading?e(m,{width:"40px",height:"40px",color:g.content.brand}):e("div",Object.assign({style:{height:64,width:64,borderRadius:"100%",display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:c.colorsV2.background.base}},{children:A===h.IMAGE?e(I,{width:40,height:40}):A===h.VIDEO?e(x,{width:40,height:40}):e(C,{width:40,height:40})})),e(v,{children:P.loading?"Upload in progress...":A===h.IMAGE?"Upload an image":A===h.VIDEO?"Upload a video":"Upload a document"}),e(b,Object.assign({color:g.content.secondary},{children:P.loading?`Your ${A.toLowerCase()} is getting loaded. This may take a couple of minutes.`:A===h.IMAGE?"JPEG/ PNG format • Max 5MB":A===h.VIDEO?"MP4 format video • Max 16MB":"PDF format document • Max 100MB"}))]})),!P.loading&&o(t,{children:[e("div",Object.assign({style:{display:"flex",flexDirection:"column",gap:"6px"}},{children:e(d,{labelText:`${J()} URL`,onPickerToggle:e=>{G(!!e)},pickerType:r.EMBEDDED,portalElement:null!=H?H:document.body,noMaxCharCheck:!0,allowMix:!1,onChange:e=>{q(e.actualValue),_(!1)},showVarHeader:!0,varHeaderText:"Select variable",errorMessage:W,prevVariable:{actualValue:"",variableType:"string"},variablesList:V,placeHolder:U?"Enter URL":"Enter URL/Add variable",showAddButton:L!==u.CAMPAIGN||!U&&A===h.IMAGE})})),o("div",Object.assign({style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:"4px",marginBottom:"12px"}},{children:[e("hr",{style:{height:"2px",flex:.5,backgroundColor:"black"}}),e(j,{children:"Or upload media from device"}),e("hr",{style:{height:"2px",flex:.5,backgroundColor:"black"}})]})),e("div",Object.assign({style:{display:"flex",width:"100%"}},{children:e(n,{matchParentWidth:!0,buttonText:"Upload",buttonType:"dashBold",LeadingIcon:M,onClick:()=>{B(),_(!1)},size:"medium"})}))]}),F&&o("div",Object.assign({style:{position:"absolute",display:"flex",alignItems:"center",bottom:-24,left:0,gap:4}},{children:[e(a,{width:16,height:16,color:g.content.negative}),e(j,Object.assign({style:{color:g.content.negative}},{children:`Select ${J()}`}))]}))]})),!P.loading&&e("div",Object.assign({style:{display:"flex",justifyContent:"flex-end",marginTop:8}},{children:e(n,{buttonText:`Add ${J()}`,onClick:()=>{N?y(N)||k(N)?(B(N),O(!1),S(""),_(!1)):S("Enter valid URL"):_(!0)}})})),e("input",{ref:D,style:{display:"none"},type:"file",onChange:P.handleImageUpload,accept:z}),!!P.selectedImage&&e(p,{aspectRatio:15/8,src:P.selectedImage,onCropComplete:P.onCropComplete,onCancel:()=>{P.setLoading(!1),P.setSelectedImage(""),D.current&&(D.current.value="")}})]})};export{E as default};
1
+ import{jsx as e,Fragment as t,jsxs as i}from"react/jsx-runtime";import o from"../../../assets/icons/arrow_back.svg.js";import a from"../../../assets/icons/info.svg.js";import"../../curtain/CurtainHelper.js";import{PickerType as r}from"../../variable-picker-v3/model.js";import{useState as s,useEffect as l}from"react";import{Button as n}from"../../button/Button.js";import{BikImageCropper as p}from"../../image-cropper/BikImageCropper.js";import"../../image-compress/ImageCompress.js";import"../../states/StateComponent.js";import"../../../_virtual/_tslib.js";import"../../../constants/zindex.js";import"../../modals/styledModal.js";import{PureSpinner as d}from"../../spinner/Spinner.js";import{InputWithVariables as m}from"../../input-with-vars/InputWithVariables.js";import"../../template-preview/TemplatePreview.js";import"../../template-preview/WhatsApp/WhatsAppLikePreview.js";import"../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js";import{DEFAULT_THEME as c,COLORS as g}from"../../../constants/Theme.js";import{HEADER_TYPES as h}from"../../template-preview/models/TemplateMeta.js";import{POD as u}from"../../template-preview/models/WhatsAppTemplate.js";import"../../template-preview/models/Channels.js";import{TitleRegular as f,TitleMedium as v,BodySecondary as b,BodyCaption as j}from"../../TypographyStyle.js";import{validateURL as y}from"../../../utils/validator.js";import x from"../../../assets/icons/file.svg.js";import C from"../../../assets/icons/filePdf.svg.js";import I from"../../../assets/icons/image.svg.js";import M from"../../../assets/icons/upload.svg.js";import{useTemplateModalContext as w}from"../context/templateModalContext.js";import{isVariable as k}from"../utils/validateIsUrl.js";const E=E=>{let{setOpenEditMedia:O,mediaComponentFormat:A,variableListForImage:V,openEditMedia:T,uploadMedia:B,fileRef:D,useEditWhatsappTemplateMediaResponse:P,skipAddVariable:U}=E;const{pod:L,setHideCrossButton:G,setHideFooterButton:R}=w(),[W,S]=s(""),[H,$]=s(void 0),[F,_]=s(!1),[z,N]=s("");let q;if(l((()=>(R(!0),()=>{R(!1)})),[]),l((()=>{const e=document.querySelector('[class*="ModalWrapper"]');e&&$(e)}),[P.loading]),q=A===h.IMAGE?"image/png, image/jpeg":A===h.VIDEO?"video/mp4":"application/pdf",!T)return e(t,{});const J=()=>A===h.IMAGE?"Image":A===h.VIDEO?"Video":"Document";return i(t,{children:[i("div",Object.assign({style:{display:"flex",gap:"10px",alignItems:"center",marginBottom:"16px"}},{children:[e(o,{onClick:e=>{e.stopPropagation(),O(!1),S("")},style:{cursor:"pointer"},width:16,height:16}),e(f,{children:"Update Media"})]})),i("div",Object.assign({style:{position:"relative",padding:16,borderRadius:4,border:F?`1px dashed ${c.colorsV2.stroke.negative.vibrant}`:`1px dashed ${c.colorsV2.stroke.primary}`,backgroundColor:c.colorsV2.surface.subdued,width:"100%",height:"100%",alignItems:"center",display:P.loading?"flex":"initial"}},{children:[i("div",Object.assign({style:{marginBottom:24,display:"flex",justifyContent:"center",flexDirection:"column",alignItems:"center",gap:16}},{children:[P.loading?e(d,{width:"40px",height:"40px",color:g.content.brand}):e("div",Object.assign({style:{height:64,width:64,borderRadius:"100%",display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:c.colorsV2.background.base}},{children:A===h.IMAGE?e(I,{width:40,height:40}):A===h.VIDEO?e(x,{width:40,height:40}):e(C,{width:40,height:40})})),e(v,{children:P.loading?"Upload in progress...":A===h.IMAGE?"Upload an image":A===h.VIDEO?"Upload a video":"Upload a document"}),e(b,Object.assign({color:g.content.secondary},{children:P.loading?`Your ${A.toLowerCase()} is getting loaded. This may take a couple of minutes.`:A===h.IMAGE?"JPEG/ PNG format • Max 5MB":A===h.VIDEO?"MP4 format video • Max 16MB":"PDF format document • Max 100MB"}))]})),!P.loading&&i(t,{children:[e("div",Object.assign({style:{display:"flex",flexDirection:"column",gap:"6px"}},{children:e(m,{labelText:`${J()} URL`,onPickerToggle:e=>{G(!!e)},pickerType:r.EMBEDDED,portalElement:null!=H?H:document.body,noMaxCharCheck:!0,allowMix:!1,onChange:e=>{N(e.actualValue),_(!1)},showVarHeader:!0,varHeaderText:"Select variable",errorMessage:W,prevVariable:{actualValue:"",variableType:"string"},variablesList:V,placeHolder:U?"Enter URL":"Enter URL/Add variable",showAddButton:L!==u.CAMPAIGN||!U&&A===h.IMAGE})})),i("div",Object.assign({style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:"4px",marginBottom:"12px"}},{children:[e("hr",{style:{height:"2px",flex:.5,backgroundColor:"black"}}),e(j,{children:"Or upload media from device"}),e("hr",{style:{height:"2px",flex:.5,backgroundColor:"black"}})]})),e("div",Object.assign({style:{display:"flex",width:"100%"}},{children:e(n,{matchParentWidth:!0,buttonText:"Upload",buttonType:"dashBold",LeadingIcon:M,onClick:()=>{B(),_(!1)},size:"medium"})}))]}),F&&i("div",Object.assign({style:{position:"absolute",display:"flex",alignItems:"center",bottom:-24,left:0,gap:4}},{children:[e(a,{width:16,height:16,color:g.content.negative}),e(j,Object.assign({style:{color:g.content.negative}},{children:`Select ${J()}`}))]}))]})),!P.loading&&e("div",Object.assign({style:{display:"flex",justifyContent:"flex-end",marginTop:8}},{children:e(n,{buttonText:`Add ${J()}`,onClick:()=>{z?y(z)||k(z)?(B(z),O(!1),S(""),_(!1)):S("Enter valid URL"):_(!0)}})})),e("input",{ref:D,style:{display:"none"},type:"file",onChange:P.handleImageUpload,accept:q}),!!P.selectedImage&&e(p,{aspectRatio:15/8,src:P.selectedImage,onCropComplete:P.onCropComplete,onCancel:()=>{P.setLoading(!1),P.setSelectedImage(""),D.current&&(D.current.value="")}})]})};export{E as default};