@managesome/eposmatic-toolkit 0.2.220 → 0.2.221

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.
@@ -883,6 +883,9 @@ const getLegacyItemReportHead = ({ monochrome, width, zeroPadding }) => {
883
883
  function getLegacyItemReportBody({ categoriesChannel, itemsChannels, modifiersChannel, currency_symbol, from, to, tenantName, menuName, itemNetAmount, count, isFilterApplied, monochrome, showRevenue, }) {
884
884
  // ======================>>>><<<<=====================
885
885
  const shouldShowRevenue = showRevenue ?? true;
886
+ const dealTextColor = monochrome ? '#000000' : '#9e9e9e';
887
+ const dealBadgeColor = monochrome ? '#000000' : '#f1c24a';
888
+ const dealMetaColor = monochrome ? '#000000' : '#777';
886
889
  let itemSales = '';
887
890
  if (itemsChannels != null && itemsChannels.length > 0) {
888
891
  let categoryItems = '';
@@ -895,9 +898,9 @@ function getLegacyItemReportBody({ categoriesChannel, itemsChannels, modifiersCh
895
898
  const hasDeal = dealCount > 0;
896
899
  for (const subItem of item.subChannels) {
897
900
  const isReferenced = subItem.referenceId != null;
898
- const nameStyle = isReferenced ? 'color:#9e9e9e;font-style:italic;' : '';
901
+ const nameStyle = isReferenced ? `color:${dealTextColor};font-style:italic;` : '';
899
902
  const dealBadge = isReferenced
900
- ? '<span style="border:1px solid #f1c24a;color:#f1c24a;border-radius:10px;padding:2px 6px;margin-left:6px;font-size:12px;">Deal Item</span>'
903
+ ? `<span style="border:1px solid ${dealBadgeColor};color:${dealBadgeColor};border-radius:10px;padding:2px 6px;margin-left:6px;font-size:12px;">Deal Item</span>`
901
904
  : '';
902
905
  subItems += `<div class="css-1oxswqj-askk">
903
906
  <div class="css-1qfrzlclkjs" style="margin-left: ${subItem.level * 30}px;"></div>
@@ -919,14 +922,14 @@ function getLegacyItemReportBody({ categoriesChannel, itemsChannels, modifiersCh
919
922
  <h6 class="css-zfkluy-jskk">${item.count}</h6>
920
923
  <h6 class="css-21997j-jskk">${item.name}</h6>
921
924
  ${hasDeal
922
- ? `<p class="css-1jq5hv-jskk" style="color:#777;font-size:10px;line-height:12px;display:block;margin-top:2px;">Individual: ${individualCount} • Deal: ${dealCount}</p>`
925
+ ? `<p class="css-1jq5hv-jskk" style="color:${dealMetaColor};font-size:10px;line-height:12px;display:block;margin-top:2px;">Individual: ${individualCount} • Deal: ${dealCount}</p>`
923
926
  : ''}
924
927
  </div>
925
928
  ${shouldShowRevenue && item.grossAmount > 0
926
929
  ? `<h6 class="css-1z023sx-jskk">${(0, common_1.localeAmount)(currency_symbol, item.grossAmount)}</h6>`
927
930
  : ''}
928
931
  ${shouldShowRevenue && hasDeal && item.grossAmount > 0
929
- ? `<p class="css-1jq5hv-jskk" style="color:#777;font-size:10px;line-height:12px;display:block;margin-top:2px;">Individual revenue</p>`
932
+ ? `<p class="css-1jq5hv-jskk" style="color:${dealMetaColor};font-size:10px;line-height:12px;display:block;margin-top:2px;">Individual revenue</p>`
930
933
  : ''}
931
934
  </div>
932
935
  ${subItems}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@managesome/eposmatic-toolkit",
3
- "version": "0.2.220",
3
+ "version": "0.2.221",
4
4
  "description": "A Toolkit Library for Eposmatic",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",