@rpg-engine/long-bow 0.8.168 → 0.8.170

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.
@@ -16,5 +16,6 @@ export interface IManagmentPanelProps {
16
16
  disableHotkeys?: () => void;
17
17
  onMoneyWithdraw: () => void;
18
18
  currentPage: number;
19
+ dcToGoldSwapRate?: number;
19
20
  }
20
21
  export declare const ManagmentPanel: React.FC<IManagmentPanelProps>;
@@ -45916,11 +45916,7 @@ var MarketplaceRows = function MarketplaceRows(_ref) {
45916
45916
  maxLines: 1,
45917
45917
  maxWidth: "200px",
45918
45918
  fontSize: "10px"
45919
- }, item.name), acceptedCurrency === shared.MarketplaceAcceptedCurrency.Dc && React__default.createElement(CurrencyBadge, {
45920
- "$color": "#a78bfa"
45921
- }, "DC only"), acceptedCurrency === shared.MarketplaceAcceptedCurrency.Gold && React__default.createElement(CurrencyBadge, {
45922
- "$color": "#fef08a"
45923
- }, "Gold only")), React__default.createElement(PriceRow, null, acceptedCurrency !== shared.MarketplaceAcceptedCurrency.Dc && React__default.createElement(GoldPriceRow$1, null, React__default.createElement(GoldIcon$1, null, React__default.createElement(SimpleTooltip, {
45919
+ }, item.name)), React__default.createElement(PriceRow, null, acceptedCurrency !== shared.MarketplaceAcceptedCurrency.Dc && React__default.createElement(GoldPriceRow$1, null, React__default.createElement(GoldIcon$1, null, React__default.createElement(SimpleTooltip, {
45924
45920
  content: "Gold Coin",
45925
45921
  direction: "top"
45926
45922
  }, React__default.createElement(SpriteFromAtlas, {
@@ -46057,27 +46053,17 @@ var GemContainer = /*#__PURE__*/styled__default.p.withConfig({
46057
46053
  displayName: "MarketplaceRows__GemContainer",
46058
46054
  componentId: "sc-wmpr1o-13"
46059
46055
  })(["position:absolute;display:block;top:-5px;left:-10px;font-size:", " !important;"], uiFonts.size.xsmall);
46060
- var CurrencyBadge = /*#__PURE__*/styled__default.span.withConfig({
46061
- displayName: "MarketplaceRows__CurrencyBadge",
46062
- componentId: "sc-wmpr1o-14"
46063
- })(["display:inline-block;margin-left:6px;padding:1px 4px;font-family:'Press Start 2P',cursive;font-size:0.38rem;color:", ";border:1px solid ", ";border-radius:3px;opacity:0.85;vertical-align:middle;text-transform:uppercase;letter-spacing:0.5px;"], function (_ref5) {
46064
- var $color = _ref5.$color;
46065
- return $color;
46066
- }, function (_ref6) {
46067
- var $color = _ref6.$color;
46068
- return $color;
46069
- });
46070
46056
  var RarityContainer$1 = /*#__PURE__*/styled__default.div.withConfig({
46071
46057
  displayName: "MarketplaceRows__RarityContainer",
46072
- componentId: "sc-wmpr1o-15"
46073
- })(["border-color:", ";box-shadow:", " inset,", ";width:32px;height:32px;"], function (_ref7) {
46074
- var item = _ref7.item;
46058
+ componentId: "sc-wmpr1o-14"
46059
+ })(["border-color:", ";box-shadow:", " inset,", ";width:32px;height:32px;"], function (_ref5) {
46060
+ var item = _ref5.item;
46075
46061
  return rarityColor(item);
46076
- }, function (_ref8) {
46077
- var item = _ref8.item;
46062
+ }, function (_ref6) {
46063
+ var item = _ref6.item;
46078
46064
  return "0 0 5px 8px " + rarityColor(item);
46079
- }, function (_ref9) {
46080
- var item = _ref9.item;
46065
+ }, function (_ref7) {
46066
+ var item = _ref7.item;
46081
46067
  return "0 0 8px 6px " + rarityColor(item);
46082
46068
  });
46083
46069
 
@@ -46845,7 +46831,9 @@ var ManagmentPanel = function ManagmentPanel(_ref) {
46845
46831
  enableHotkeys = _ref.enableHotkeys,
46846
46832
  disableHotkeys = _ref.disableHotkeys,
46847
46833
  onMoneyWithdraw = _ref.onMoneyWithdraw,
46848
- currentPage = _ref.currentPage;
46834
+ currentPage = _ref.currentPage,
46835
+ _ref$dcToGoldSwapRate = _ref.dcToGoldSwapRate,
46836
+ dcToGoldSwapRate = _ref$dcToGoldSwapRate === void 0 ? 0 : _ref$dcToGoldSwapRate;
46849
46837
  var _useState = React.useState(''),
46850
46838
  price = _useState[0],
46851
46839
  setPrice = _useState[1];
@@ -46945,7 +46933,7 @@ var ManagmentPanel = function ManagmentPanel(_ref) {
46945
46933
  },
46946
46934
  type: "button"
46947
46935
  }, opt.label);
46948
- }))))), React__default.createElement(InnerOptionsWrapper, null, React__default.createElement(SectionLabel$1, {
46936
+ }), listingCurrency !== shared.MarketplaceAcceptedCurrency.Gold && price && Number(price) > 0 && React__default.createElement(DCPreview, null, shared.formatDCAmount(shared.goldToDC(Number(price))), " DC"))))), React__default.createElement(InnerOptionsWrapper, null, React__default.createElement(SectionLabel$1, {
46949
46937
  style: {
46950
46938
  marginBottom: '8px'
46951
46939
  }
@@ -46981,14 +46969,18 @@ var ManagmentPanel = function ManagmentPanel(_ref) {
46981
46969
  var item = _ref2.item,
46982
46970
  price = _ref2.price,
46983
46971
  _id = _ref2._id,
46984
- listingCurrency = _ref2.acceptedCurrency;
46972
+ itemCurrency = _ref2.acceptedCurrency;
46973
+ var currency = itemCurrency || shared.MarketplaceAcceptedCurrency.GoldOrDc;
46974
+ var isDcOnly = currency === shared.MarketplaceAcceptedCurrency.Dc;
46975
+ var showDcPrice = isDcOnly || dcToGoldSwapRate > 0 && currency !== shared.MarketplaceAcceptedCurrency.Gold;
46985
46976
  return React__default.createElement(MarketplaceRows, {
46986
46977
  key: item.key + "_" + index,
46987
46978
  atlasIMG: atlasIMG,
46988
46979
  atlasJSON: atlasJSON,
46989
46980
  item: item,
46990
46981
  itemPrice: price,
46991
- acceptedCurrency: listingCurrency,
46982
+ dcEquivalentPrice: showDcPrice ? shared.goldToDC(price) : undefined,
46983
+ acceptedCurrency: currency,
46992
46984
  equipmentSet: equipmentSet,
46993
46985
  onMarketPlaceItemRemove: setRemovingItemId.bind(null, _id)
46994
46986
  });
@@ -47075,6 +47067,10 @@ var CurrencyToggleButton = /*#__PURE__*/styled__default.button.withConfig({
47075
47067
  var $active = _ref7.$active;
47076
47068
  return $active ? '#f59e0b' : '#ddd';
47077
47069
  });
47070
+ var DCPreview = /*#__PURE__*/styled__default.span.withConfig({
47071
+ displayName: "ManagmentPanel__DCPreview",
47072
+ componentId: "sc-1yyi6jn-16"
47073
+ })(["font-family:'Press Start 2P',cursive !important;font-size:0.4rem !important;color:rgba(167,139,250,0.8) !important;white-space:nowrap;margin-left:auto;"]);
47078
47074
 
47079
47075
  var CURRENCY_OPTIONS = [{
47080
47076
  value: shared.MarketplaceAcceptedCurrency.GoldOrDc,