@widergy/utilitygo-smart-bill-web 1.7.3 → 1.10.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.
Files changed (135) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/dist/components/Advice/index.js +1 -2
  3. package/dist/components/Advice/styles.module.scss +2 -1
  4. package/dist/components/Amount/index.js +2 -2
  5. package/dist/components/Amount/styles.module.scss +10 -2
  6. package/dist/components/BarChart/constants.js +19 -3
  7. package/dist/components/BarChart/index.js +70 -101
  8. package/dist/components/BarChart/styles.module.scss +71 -0
  9. package/dist/components/BarChart/utils.js +31 -15
  10. package/dist/components/BillCalculation/components/ConceptCard/index.js +28 -9
  11. package/dist/components/BillCalculation/components/ConceptCard/styles.module.scss +16 -6
  12. package/dist/components/BillCalculation/index.js +10 -5
  13. package/dist/components/BillCalculation/utils.js +14 -9
  14. package/dist/components/BillSummary/components/BilledConcepts/components/Concept/index.js +11 -18
  15. package/dist/components/BillSummary/components/BilledConcepts/components/Concept/styles.module.scss +1 -5
  16. package/dist/components/BillSummary/components/BilledConcepts/components/PieChartContainer/constants.js +9 -3
  17. package/dist/components/BillSummary/components/BilledConcepts/components/PieChartContainer/index.js +21 -28
  18. package/dist/components/BillSummary/components/BilledConcepts/components/PieChartContainer/styles.module.scss +2 -2
  19. package/dist/components/BillSummary/components/BilledConcepts/constants.js +1 -1
  20. package/dist/components/BillSummary/components/BilledConcepts/index.js +8 -3
  21. package/dist/components/BillSummary/components/BilledConcepts/styles.module.scss +1 -1
  22. package/dist/components/BillSummary/components/BilledConcepts/utils.js +20 -6
  23. package/dist/components/BillSummary/styles.module.scss +2 -3
  24. package/dist/components/ConsumptionComparison/components/ComparisonTable/components/DataLine/index.js +3 -3
  25. package/dist/components/ConsumptionComparison/components/ComparisonTable/components/DataLine/styles.module.scss +4 -2
  26. package/dist/components/ConsumptionComparison/components/ComparisonTable/components/Season/index.js +3 -3
  27. package/dist/components/ConsumptionComparison/components/ComparisonTable/constants.js +61 -37
  28. package/dist/components/ConsumptionComparison/components/ComparisonTable/styles.module.scss +14 -6
  29. package/dist/components/ConsumptionComparison/components/ComparisonTable/utils.js +4 -2
  30. package/dist/components/ConsumptionComparison/components/ConsumptionAdvice/index.js +2 -5
  31. package/dist/components/ConsumptionComparison/components/ConsumptionAdvice/styles.module.scss +4 -5
  32. package/dist/components/ConsumptionComparison/components/PercentageComparison/index.js +4 -3
  33. package/dist/components/ConsumptionComparison/components/PercentageComparison/styles.module.scss +3 -12
  34. package/dist/components/ConsumptionComparison/index.js +9 -11
  35. package/dist/components/ConsumptionComparison/styles.module.scss +5 -4
  36. package/dist/components/ConsumptionEnergyDetails/components/ConsumptionEnergyComparison/index.js +26 -2
  37. package/dist/components/ConsumptionEnergyDetails/components/ConsumptionEnergyComparison/styles.module.scss +2 -0
  38. package/dist/components/ConsumptionEnergyDetails/components/PercentageComparison/styles.module.scss +1 -1
  39. package/dist/components/ConsumptionEnergyDetails/index.js +21 -11
  40. package/dist/components/ConsumptionEnergyDetails/styles.module.scss +13 -1
  41. package/dist/components/ConsumptionIncluded/components/TimelineRow/components/Card/index.js +61 -42
  42. package/dist/components/ConsumptionIncluded/components/TimelineRow/components/Card/styles.module.scss +33 -20
  43. package/dist/components/ConsumptionIncluded/components/TimelineRow/components/Card/utils.js +24 -0
  44. package/dist/components/ConsumptionIncluded/components/TimelineRow/components/HeaderConsumption/index.js +13 -19
  45. package/dist/components/ConsumptionIncluded/components/TimelineRow/components/HeaderConsumption/styles.module.scss +3 -6
  46. package/dist/components/ConsumptionIncluded/components/TimelineRow/components/HeaderSettlement/index.js +7 -9
  47. package/dist/components/ConsumptionIncluded/components/TimelineRow/index.js +11 -3
  48. package/dist/components/ConsumptionIncluded/components/TimelineRow/styles.module.scss +10 -13
  49. package/dist/components/ConsumptionIncluded/styles.module.scss +5 -0
  50. package/dist/components/ConsumptionIncluded/utils.js +6 -6
  51. package/dist/components/ConsumptionPeriod/components/ConsumptionSummary/components/ReadingRow/styles.module.scss +2 -0
  52. package/dist/components/ConsumptionPeriod/components/ConsumptionSummary/index.js +8 -6
  53. package/dist/components/ConsumptionPeriod/components/ConsumptionSummary/styles.module.scss +16 -4
  54. package/dist/components/ConsumptionPeriod/components/HistoryGraph/index.js +1 -7
  55. package/dist/components/ConsumptionPeriod/components/Reading/index.js +26 -9
  56. package/dist/components/ConsumptionPeriod/components/Reading/styles.module.scss +13 -8
  57. package/dist/components/ConsumptionPeriod/styles.module.scss +11 -10
  58. package/dist/components/Date/index.js +2 -2
  59. package/dist/components/Date/styles.module.scss +3 -0
  60. package/dist/components/DebtState/styles.module.scss +1 -1
  61. package/dist/components/IconAndDetails/index.js +4 -1
  62. package/dist/components/IconAndDetails/styles.module.scss +2 -2
  63. package/dist/components/Magnitude/index.js +6 -5
  64. package/dist/components/Magnitude/styles.module.scss +5 -5
  65. package/dist/components/MainBillData/components/BillAlert/components/BillParticularConditions/index.js +5 -5
  66. package/dist/components/MainBillData/components/BillAlert/styles.module.scss +5 -3
  67. package/dist/components/MainBillData/components/BillBody/components/ClientData/index.js +13 -13
  68. package/dist/components/MainBillData/components/BillBody/components/ClientData/styles.module.scss +3 -3
  69. package/dist/components/MainBillData/components/BillBody/components/ReadingDetails/styles.module.scss +1 -1
  70. package/dist/components/MainBillData/components/BillBody/styles.module.scss +4 -3
  71. package/dist/components/MainBillData/components/BillHeader/components/TypeAndNumber/index.js +3 -2
  72. package/dist/components/MainBillData/components/BillHeader/components/TypeAndNumber/styles.module.scss +7 -3
  73. package/dist/components/MainBillData/components/BillHeader/index.js +2 -2
  74. package/dist/components/MainBillData/components/BillHeader/styles.module.scss +10 -9
  75. package/dist/components/MainBillData/styles.module.scss +0 -1
  76. package/dist/components/Period/index.js +39 -11
  77. package/dist/components/Period/styles.module.scss +13 -4
  78. package/dist/components/PowerProgresBar/components/PowerConsumption/index.js +2 -3
  79. package/dist/components/PowerProgresBar/index.js +3 -4
  80. package/dist/components/RatesDefinition/components/BillRate/components/RatePrices/index.js +6 -17
  81. package/dist/components/RatesDefinition/components/BillRate/components/RatePrices/styles.module.scss +8 -3
  82. package/dist/components/RatesDefinition/components/BillRate/index.js +10 -11
  83. package/dist/components/RatesDefinition/components/BillRate/styles.module.scss +8 -29
  84. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/Category/index.js +9 -5
  85. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/Category/styles.module.scss +12 -18
  86. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/components/Bars/components/Stage/components/SubStage/index.js +4 -3
  87. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/components/Bars/components/Stage/index.js +13 -62
  88. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/components/Bars/components/Stage/styles.module.scss +2 -6
  89. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/components/Bars/index.js +1 -0
  90. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/components/Indicator/components/IndicatorLabel/index.js +18 -12
  91. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/components/Indicator/components/IndicatorLabel/styles.module.scss +7 -3
  92. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/components/Indicator/index.js +23 -14
  93. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/components/Indicator/styles.module.scss +6 -19
  94. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/components/Indicator/utils.js +35 -1
  95. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/components/LegendItem/index.js +80 -0
  96. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/components/LegendItem/styles.module.scss +57 -0
  97. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/constants.js +17 -9
  98. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/styles.module.scss +2 -1
  99. package/dist/components/RatesDefinition/components/CategoryByConsumption/components/RateStagesGraph/utils.js +1 -1
  100. package/dist/components/RatesDefinition/components/CategoryByConsumption/index.js +61 -7
  101. package/dist/components/RatesDefinition/components/CategoryByConsumption/styles.module.scss +20 -4
  102. package/dist/components/RatesDefinition/components/PurchasedRate/index.js +12 -22
  103. package/dist/components/RatesDefinition/components/PurchasedRate/styles.module.scss +14 -44
  104. package/dist/components/RatesDefinition/index.js +16 -12
  105. package/dist/components/RatesDefinition/styles.module.scss +38 -10
  106. package/dist/components/StyledAmount/constants.js +0 -45
  107. package/dist/components/StyledAmount/index.js +5 -14
  108. package/dist/components/StyledAmount/styles.module.scss +14 -8
  109. package/dist/components/WithContextApi/index.js +9 -1
  110. package/dist/constants/deviceSizes.js +1 -1
  111. package/dist/index.js +28 -15
  112. package/dist/shared/Context/index.js +1 -1
  113. package/dist/shared/constants/aliases.js +532 -10
  114. package/dist/shared/constants/components.js +3 -1
  115. package/dist/shared/constants/consumptions.js +1 -1
  116. package/dist/shared/constants/readings.js +1 -1
  117. package/dist/shared/constants/stagesGraph.js +1 -1
  118. package/dist/shared/types/assetsTypes.js +1 -30
  119. package/dist/shared/types/billDataTypes.js +1 -1
  120. package/dist/shared/types/componentsTypes.js +4 -2
  121. package/dist/shared/types/rateStagesTypes.js +1 -1
  122. package/dist/shared/utils/consumptions.js +3 -3
  123. package/dist/shared/utils/context.js +3 -1
  124. package/dist/shared/utils/periods.js +1 -1
  125. package/dist/shared/utils/readings.js +1 -1
  126. package/dist/shared/utils/stagesGraph.js +1 -1
  127. package/dist/utils.js +1 -1
  128. package/package.json +2 -3
  129. package/dist/components/BarChart/components/CustomBar/index.js +0 -111
  130. package/dist/components/BarChart/components/CustomLabelText/index.js +0 -48
  131. package/dist/components/BarChart/components/CustomXAxisLabel/index.js +0 -58
  132. package/dist/components/BarChart/styles.js +0 -90
  133. package/dist/components/BillSummary/components/BilledConcepts/components/PieChartContainer/utils.js +0 -27
  134. package/dist/components/BillSummary/components/Rate/index.js +0 -56
  135. package/dist/components/BillSummary/components/Rate/styles.module.scss +0 -43
@@ -4,67 +4,37 @@
4
4
  @import '../../../../scss/variables/_fontSizes.scss';
5
5
 
6
6
  .container {
7
- background-color: $white;
8
- border: 1px solid $borders-gray;
9
- border-radius: $default-container-border-radius;
7
+ align-items: center;
8
+ border-right: 1px solid $borders-gray;
10
9
  display: flex;
11
10
  flex-flow: column;
12
- min-width: 180px;
13
- padding: $default-container-padding;
14
-
15
- @media #{$desktop} {
16
- margin-right: 10px;
17
- }
11
+ gap: 16px;
12
+ padding: 16px;
13
+ justify-content: center;
14
+ min-width: 50%;
18
15
 
19
16
  @media #{$tablet-mobile} {
17
+ border-bottom: 1px solid $borders-gray;
18
+ border-right: none;
20
19
  margin-bottom: 10px;
20
+ min-width: auto;
21
21
  }
22
22
  }
23
23
 
24
- .title {
25
- margin-bottom: 15px;
24
+ .rateAndCategoryContainer {
25
+ flex-direction: column-reverse;
26
26
  }
27
27
 
28
28
  .data {
29
29
  align-items: center;
30
30
  display: flex;
31
31
  flex-flow: column;
32
+ gap: 24px;
32
33
  height: 100%;
33
- justify-content: flex-end;
34
-
35
- @media #{$tablet-mobile} {
36
- flex-flow: row;
37
- position: relative;
38
- }
39
- }
40
-
41
- .rateAndDescription {
42
- align-items: center;
43
- display: flex;
44
- flex-direction: column;
45
- margin: 0 auto 24px;
46
-
47
- @media #{$tablet-mobile} {
48
- margin: 0 auto;
49
- }
50
- }
51
-
52
- .purchasedRate {
53
- font-size: $purchased-rate-font-size;
54
- }
55
-
56
- .description {
57
- @media #{$tablet-mobile} {
58
- display: none;
59
- }
34
+ justify-content: space-between;
60
35
  }
61
36
 
62
37
  .link {
38
+ color: $primary;
63
39
  text-decoration: underline;
64
-
65
- @media #{$tablet-mobile} {
66
- bottom: 8px;
67
- position: absolute;
68
- right: 0;
69
- }
70
40
  }
@@ -27,6 +27,8 @@ var _WithContextApi = _interopRequireDefault(require("../WithContextApi"));
27
27
 
28
28
  var _Advice = _interopRequireDefault(require("../Advice"));
29
29
 
30
+ var _aliases = require("../../shared/constants/aliases");
31
+
30
32
  var _CategoryByConsumption = _interopRequireDefault(require("./components/CategoryByConsumption"));
31
33
 
32
34
  var _PurchasedRate = _interopRequireDefault(require("./components/PurchasedRate"));
@@ -45,38 +47,40 @@ var RatesDefinition = function RatesDefinition(_ref) {
45
47
  var description = (0, _seamlessImmutable.getIn)(billData, ['client', 'rate', 'description']);
46
48
  var fixedCharge = (0, _rates.getCharge)(billData, _rates2.CHARGE_TYPES.FIXED).amount;
47
49
  var variableCharge = (0, _rates.getCharge)(billData, _rates2.CHARGE_TYPES.VARIABLE).amount;
50
+ var Label = contextApiInfo.Label;
48
51
  var currentPeriod = (0, _periods.getCurrentPeriod)(billData);
49
52
  var currentConsumption = (0, _consumptions.getCurrentConsumption)(currentPeriod, _consumptions2.ENERGY_TYPES.ACTIVE);
50
53
  var _contextApiInfo$confi = contextApiInfo.config.texts.ratesDefinition,
51
54
  adviceTitle = _contextApiInfo$confi.adviceTitle,
52
- adviceText = _contextApiInfo$confi.adviceText;
55
+ adviceText = _contextApiInfo$confi.adviceText,
56
+ rateDataTitle = _contextApiInfo$confi.rateDataTitle;
53
57
  return /*#__PURE__*/_react.default.createElement("div", {
54
58
  className: _stylesModule.default.container
55
- }, /*#__PURE__*/_react.default.createElement(_PurchasedRate.default, {
56
- rate: rate,
57
- classes: {
58
- container: _stylesModule.default.hiddenDesktop
59
- },
60
- billData: billData
61
- }), /*#__PURE__*/_react.default.createElement(_CategoryByConsumption.default, {
59
+ }, /*#__PURE__*/_react.default.createElement(_CategoryByConsumption.default, {
62
60
  value: currentConsumption.value,
63
61
  unit: currentConsumption.unit,
64
62
  category: category
65
63
  }), /*#__PURE__*/_react.default.createElement("div", {
64
+ className: _stylesModule.default.bottomData
65
+ }, /*#__PURE__*/_react.default.createElement("div", {
66
+ className: _stylesModule.default.rateDataContainer
67
+ }, /*#__PURE__*/_react.default.createElement("div", {
68
+ className: _stylesModule.default.rateDataTitle
69
+ }, /*#__PURE__*/_react.default.createElement(Label, {
70
+ alias: _aliases.TITLE
71
+ }, rateDataTitle)), /*#__PURE__*/_react.default.createElement("div", {
66
72
  className: _stylesModule.default.rateData
67
73
  }, /*#__PURE__*/_react.default.createElement(_PurchasedRate.default, {
68
74
  rate: rate,
75
+ category: category,
69
76
  description: description,
70
- classes: {
71
- container: _stylesModule.default.hiddenMobile
72
- },
73
77
  billData: billData
74
78
  }), /*#__PURE__*/_react.default.createElement(_BillRate.default, {
75
79
  rate: rate,
76
80
  category: category,
77
81
  fixedCharge: fixedCharge,
78
82
  variableCharge: variableCharge
79
- }), adviceTitle && adviceText && /*#__PURE__*/_react.default.createElement(_Advice.default, {
83
+ }))), adviceTitle && adviceText && /*#__PURE__*/_react.default.createElement(_Advice.default, {
80
84
  title: adviceTitle,
81
85
  contentText: adviceText
82
86
  })));
@@ -7,28 +7,56 @@
7
7
  flex-flow: column;
8
8
  }
9
9
 
10
- .rateData {
10
+ .bottomData {
11
11
  display: flex;
12
- justify-content: center;
13
- width: 100%;
12
+ height: 260px;
14
13
 
15
- @media #{$desktop} {
16
- max-height: 200px;
14
+ @media #{$tablet-mobile} {
15
+ flex-direction: column;
16
+ height: auto;
17
17
  }
18
+ }
19
+
20
+ .rateDataTitle {
21
+ align-items: center;
22
+ display: flex;
23
+ height: min-content;
24
+ border-bottom: 1px solid $borders-gray;
25
+ padding: 16px;
18
26
 
19
27
  @media #{$tablet-mobile} {
20
- flex-flow: column;
28
+ justify-content: center;
21
29
  }
22
30
  }
23
31
 
24
- .hiddenDesktop {
32
+ .rateDataContainer {
33
+ background-color: $white;
34
+ border: 1px solid $borders-gray;
35
+ border-radius: $default-container-border-radius;
36
+ display: flex;
37
+ flex-direction: column;
38
+ height: 100%;
39
+ min-width: 546px;
40
+
25
41
  @media #{$desktop} {
26
- display: none;
42
+ margin-right: 16px;
43
+ }
44
+
45
+ @media #{$tablet-mobile} {
46
+ flex-flow: column;
47
+ margin-bottom: 16px;
48
+ min-width: auto;
49
+ width: 100%;
27
50
  }
28
51
  }
29
52
 
30
- .hiddenMobile {
53
+ .rateData {
54
+ display: flex;
55
+ flex-direction: row;
56
+ height: 100%;
57
+ width: 100%;
58
+
31
59
  @media #{$tablet-mobile} {
32
- display: none;
60
+ flex-direction: column;
33
61
  }
34
62
  }
@@ -11,67 +11,22 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
11
11
 
12
12
  var VARIANTS = {
13
13
  small: {
14
- currencyLabel: {
15
- small: true
16
- },
17
- integerLabel: {
18
- small: true
19
- },
20
- decimalLabel: {
21
- xsmall: true
22
- },
23
14
  currencyLabelStyle: _stylesModule.default.smallCurrency,
24
15
  decimalLabelStyle: _stylesModule.default.smallDecimalPart
25
16
  },
26
17
  medium: {
27
- currencyLabel: {
28
- medium: true
29
- },
30
- integerLabel: {
31
- medium: true
32
- },
33
- decimalLabel: {
34
- xsmall: true
35
- },
36
18
  currencyLabelStyle: _stylesModule.default.mediumCurrency,
37
19
  decimalLabelStyle: _stylesModule.default.mediumDecimalPart
38
20
  },
39
21
  large: {
40
- currencyLabel: {
41
- large: true
42
- },
43
- integerLabel: {
44
- large: true
45
- },
46
- decimalLabel: {
47
- xxsmall: true
48
- },
49
22
  currencyLabelStyle: _stylesModule.default.largeCurrency,
50
23
  decimalLabelStyle: _stylesModule.default.largeDecimalPart
51
24
  },
52
25
  xlarge: {
53
- currencyLabel: {
54
- xlarge: true
55
- },
56
- integerLabel: {
57
- xlarge: true
58
- },
59
- decimalLabel: {
60
- xsmall: true
61
- },
62
26
  currencyLabelStyle: _stylesModule.default.mediumCurrency,
63
27
  decimalLabelStyle: _stylesModule.default.mediumDecimalPart
64
28
  },
65
29
  title: {
66
- currencyLabel: {
67
- title: true
68
- },
69
- integerLabel: {
70
- title: true
71
- },
72
- decimalLabel: {
73
- medium: true
74
- },
75
30
  currencyLabelStyle: _stylesModule.default.titleCurrency,
76
31
  decimalLabelStyle: _stylesModule.default.titleDecimalPart
77
32
  }
@@ -21,8 +21,6 @@ var _stylesModule = _interopRequireDefault(require("./styles.module.scss"));
21
21
 
22
22
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
23
23
 
24
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
25
-
26
24
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
27
25
 
28
26
  function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
@@ -51,10 +49,7 @@ var StyledAmount = function StyledAmount(_ref) {
51
49
  var Label = contextApiInfo.Label;
52
50
  var _VARIANTS$variant = _constants.VARIANTS[variant],
53
51
  currencyLabelStyle = _VARIANTS$variant.currencyLabelStyle,
54
- decimalLabelStyle = _VARIANTS$variant.decimalLabelStyle,
55
- currencyLabel = _VARIANTS$variant.currencyLabel,
56
- integerLabel = _VARIANTS$variant.integerLabel,
57
- decimalLabel = _VARIANTS$variant.decimalLabel;
52
+ decimalLabelStyle = _VARIANTS$variant.decimalLabelStyle;
58
53
 
59
54
  var _ref2 = amount !== null && amount !== undefined && (0, _numeral.default)(amount).format(amountFormat).split(splitChar) || ['-', '-'],
60
55
  _ref3 = _slicedToArray(_ref2, 2),
@@ -63,15 +58,15 @@ var StyledAmount = function StyledAmount(_ref) {
63
58
 
64
59
  return /*#__PURE__*/_react.default.createElement("div", {
65
60
  className: _stylesModule.default.container
66
- }, /*#__PURE__*/_react.default.createElement(Label, _extends({
61
+ }, /*#__PURE__*/_react.default.createElement(Label, {
67
62
  alias: alias,
68
63
  className: currencyLabelStyle
69
- }, currencyLabel), currency), /*#__PURE__*/_react.default.createElement(Label, _extends({
64
+ }, currency), /*#__PURE__*/_react.default.createElement(Label, {
70
65
  alias: alias
71
- }, integerLabel), integerPart), /*#__PURE__*/_react.default.createElement(Label, _extends({
66
+ }, integerPart), /*#__PURE__*/_react.default.createElement(Label, {
72
67
  alias: aliasDecimal,
73
68
  className: decimalLabelStyle
74
- }, decimalLabel), decimalPart));
69
+ }, decimalPart));
75
70
  };
76
71
 
77
72
  StyledAmount.propTypes = {
@@ -80,10 +75,6 @@ StyledAmount.propTypes = {
80
75
  amount: _propTypes.number,
81
76
  amountFormat: _propTypes.string,
82
77
  splitChar: _propTypes.string,
83
- primary: _propTypes.bool,
84
- white: _propTypes.bool,
85
- bold: _propTypes.bool,
86
- semibold: _propTypes.bool,
87
78
  alias: _propTypes.string,
88
79
  aliasDecimal: _propTypes.string,
89
80
  variant: _propTypes.string
@@ -1,36 +1,42 @@
1
+ $title-gap: 4px;
2
+
1
3
  .container {
2
4
  align-items: flex-start;
3
5
  display: flex;
4
6
  }
5
7
 
6
8
  .smallCurrency {
7
- margin-right: 2px;
9
+ margin-right: 4px;
8
10
  }
9
11
 
10
12
  .smallDecimalPart {
11
- margin-left: 2px;
13
+ margin-left: 4px;
14
+ margin-top: -6px;
12
15
  }
13
16
 
14
17
  .mediumCurrency {
15
- margin-right: 5px;
18
+ margin-right: 4px;
16
19
  }
17
20
 
18
21
  .mediumDecimalPart {
19
- margin-left: 1px;
22
+ margin-top: -4px;
23
+ margin-left: 4px;
20
24
  }
21
25
 
22
26
  .largeCurrency {
23
- margin-right: 5px;
27
+ margin-right: 4px;
24
28
  }
25
29
 
26
30
  .largeDecimalPart {
27
- margin-left: 1px;
31
+ margin-top: -4px;
32
+ margin-left: 4px;
28
33
  }
29
34
 
30
35
  .titleCurrency {
31
- margin-right: 10px;
36
+ margin-right: $title-gap;
32
37
  }
33
38
 
34
39
  .titleDecimalPart {
35
- margin-top: 4px;
40
+ margin-top: 5px;
41
+ margin-left: $title-gap;
36
42
  }
@@ -7,6 +7,8 @@ exports.default = void 0;
7
7
 
8
8
  var _react = _interopRequireDefault(require("react"));
9
9
 
10
+ var _aliases = require("../../shared/constants/aliases");
11
+
10
12
  var _Context = require("../../shared/Context");
11
13
 
12
14
  var _context = require("../../shared/utils/context");
@@ -29,10 +31,16 @@ var withContextApi = function withContextApi(retrieveStyle) {
29
31
  return /*#__PURE__*/_react.default.createElement(_Context.SmartBillConsumer, null, function (contextApiInfo) {
30
32
  var infoWithUnpackedComponents = _objectSpread(_objectSpread({}, contextApiInfo), (0, _context.unpackComponents)(contextApiInfo));
31
33
 
34
+ var infoWithDefaultColors = _objectSpread(_objectSpread({}, infoWithUnpackedComponents), {}, {
35
+ config: _objectSpread({
36
+ colors: contextApiInfo.colors || _aliases.DEFAULT_COLORS
37
+ }, contextApiInfo.config)
38
+ });
39
+
32
40
  delete infoWithUnpackedComponents.components;
33
41
  return /*#__PURE__*/_react.default.createElement(_layout.default, _extends({}, props, {
34
42
  Component: Component,
35
- contextApiInfo: infoWithUnpackedComponents,
43
+ contextApiInfo: infoWithDefaultColors,
36
44
  retrieveStyle: retrieveStyle
37
45
  }));
38
46
  });
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.TabletMobileViewport = exports.DefaultViewport = exports.MobileViewport = exports.TabletViewport = exports.DesktopViewport = exports.TABLET = exports.MOBILE = exports.DESKTOP = exports.HDBreakpoint = exports.FullHDBreakpoint = exports.MobileBreakpoint = exports.TabletBreakpoint = void 0;
6
+ exports.TabletViewport = exports.TabletMobileViewport = exports.TabletBreakpoint = exports.TABLET = exports.MobileViewport = exports.MobileBreakpoint = exports.MOBILE = exports.HDBreakpoint = exports.FullHDBreakpoint = exports.DesktopViewport = exports.DefaultViewport = exports.DESKTOP = void 0;
7
7
 
8
8
  var _react = _interopRequireDefault(require("react"));
9
9
 
package/dist/index.js CHANGED
@@ -5,30 +5,26 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
5
5
  Object.defineProperty(exports, "__esModule", {
6
6
  value: true
7
7
  });
8
- Object.defineProperty(exports, "SmartBillProvider", {
9
- enumerable: true,
10
- get: function get() {
11
- return _SmartBillProvider.default;
12
- }
13
- });
14
- Object.defineProperty(exports, "MainBillData", {
8
+ exports.Aliases = void 0;
9
+ Object.defineProperty(exports, "BillCalculation", {
15
10
  enumerable: true,
16
11
  get: function get() {
17
- return _MainBillData.default;
12
+ return _BillCalculation.default;
18
13
  }
19
14
  });
20
- Object.defineProperty(exports, "ConsumptionPeriod", {
15
+ Object.defineProperty(exports, "BillSummary", {
21
16
  enumerable: true,
22
17
  get: function get() {
23
- return _ConsumptionPeriod.default;
18
+ return _BillSummary.default;
24
19
  }
25
20
  });
26
- Object.defineProperty(exports, "BillCalculation", {
21
+ Object.defineProperty(exports, "ColorAliases", {
27
22
  enumerable: true,
28
23
  get: function get() {
29
- return _BillCalculation.default;
24
+ return Aliases.COLORS;
30
25
  }
31
26
  });
27
+ exports.ComponentNames = void 0;
32
28
  Object.defineProperty(exports, "ConsumptionComparison", {
33
29
  enumerable: true,
34
30
  get: function get() {
@@ -41,16 +37,34 @@ Object.defineProperty(exports, "ConsumptionIncluded", {
41
37
  return _ConsumptionIncluded.default;
42
38
  }
43
39
  });
40
+ Object.defineProperty(exports, "ConsumptionPeriod", {
41
+ enumerable: true,
42
+ get: function get() {
43
+ return _ConsumptionPeriod.default;
44
+ }
45
+ });
46
+ Object.defineProperty(exports, "DefaultLabelProps", {
47
+ enumerable: true,
48
+ get: function get() {
49
+ return Aliases.DEFAULT_PROPS;
50
+ }
51
+ });
52
+ Object.defineProperty(exports, "MainBillData", {
53
+ enumerable: true,
54
+ get: function get() {
55
+ return _MainBillData.default;
56
+ }
57
+ });
44
58
  Object.defineProperty(exports, "RatesDefinition", {
45
59
  enumerable: true,
46
60
  get: function get() {
47
61
  return _RatesDefinition.default;
48
62
  }
49
63
  });
50
- Object.defineProperty(exports, "BillSummary", {
64
+ Object.defineProperty(exports, "SmartBillProvider", {
51
65
  enumerable: true,
52
66
  get: function get() {
53
- return _BillSummary.default;
67
+ return _SmartBillProvider.default;
54
68
  }
55
69
  });
56
70
  Object.defineProperty(exports, "billDataTypes", {
@@ -65,7 +79,6 @@ Object.defineProperty(exports, "rateStagesTypes", {
65
79
  return _rateStagesTypes.rateStagesTypes;
66
80
  }
67
81
  });
68
- exports.Aliases = exports.ComponentNames = void 0;
69
82
 
70
83
  var _SmartBillProvider = _interopRequireDefault(require("./components/SmartBillProvider"));
71
84
 
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.SmartBillConsumer = exports.SmartBillProvider = void 0;
6
+ exports.SmartBillProvider = exports.SmartBillConsumer = void 0;
7
7
 
8
8
  var _react = _interopRequireDefault(require("react"));
9
9