@rpg-engine/long-bow 0.4.81 → 0.4.83

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.
@@ -15756,13 +15756,15 @@ var MarketplaceRows = function MarketplaceRows(_ref) {
15756
15756
  onMarketPlaceItemBuy = _ref.onMarketPlaceItemBuy,
15757
15757
  onMarketPlaceItemRemove = _ref.onMarketPlaceItemRemove,
15758
15758
  disabled = _ref.disabled;
15759
- return React.createElement(MarketplaceWrapper, null, React.createElement(ItemInfoWrapper, {
15759
+ return React.createElement(MarketplaceWrapper, null, React.createElement(ItemIconContainer, null, React.createElement(SpriteContainer, null, React.createElement(ItemInfoWrapper, {
15760
15760
  item: item,
15761
15761
  atlasIMG: atlasIMG,
15762
15762
  atlasJSON: atlasJSON,
15763
15763
  equipmentSet: equipmentSet,
15764
15764
  scale: scale
15765
- }, React.createElement(ItemIconContainer, null, React.createElement(SpriteContainer, null, React.createElement(SpriteFromAtlas, {
15765
+ }, React.createElement(RarityContainer, {
15766
+ item: item
15767
+ }, React.createElement(SpriteFromAtlas, {
15766
15768
  atlasIMG: atlasIMG,
15767
15769
  atlasJSON: atlasJSON,
15768
15770
  spriteKey: getItemTextureKeyPath({
@@ -15772,11 +15774,11 @@ var MarketplaceRows = function MarketplaceRows(_ref) {
15772
15774
  isStackable: item.isStackable
15773
15775
  }, atlasJSON),
15774
15776
  imgScale: 2
15775
- }), React.createElement(QuantityContainer, null, item.stackQty && item.stackQty > 1 && "x" + Math.round(item.stackQty * 10) / 10)), React.createElement(PriceValue, null, React.createElement("p", null, React.createElement(Ellipsis, {
15777
+ })), React.createElement(QuantityContainer, null, item.stackQty && item.stackQty > 1 && "x" + Math.round(item.stackQty * 10) / 10))), React.createElement(PriceValue, null, React.createElement("p", null, React.createElement(Ellipsis, {
15776
15778
  maxLines: 1,
15777
15779
  maxWidth: "200px",
15778
15780
  fontSize: "10px"
15779
- }, item.name))))), React.createElement(Flex$1, null, React.createElement(ItemIconContainer, null, React.createElement(SpriteContainer, null, React.createElement(SpriteFromAtlas, {
15781
+ }, item.name)))), React.createElement(Flex$1, null, React.createElement(ItemIconContainer, null, React.createElement(GoldContainer, null, React.createElement(SpriteFromAtlas, {
15780
15782
  atlasIMG: atlasIMG,
15781
15783
  atlasJSON: atlasJSON,
15782
15784
  spriteKey: "others/gold-coin-qty-5.png",
@@ -15811,18 +15813,35 @@ var ItemIconContainer = /*#__PURE__*/styled.div.withConfig({
15811
15813
  displayName: "MarketplaceRows__ItemIconContainer",
15812
15814
  componentId: "sc-wmpr1o-3"
15813
15815
  })(["display:flex;justify-content:flex-start;align-items:center;"]);
15814
- var SpriteContainer = /*#__PURE__*/styled.div.withConfig({
15815
- displayName: "MarketplaceRows__SpriteContainer",
15816
+ var GoldContainer = /*#__PURE__*/styled.div.withConfig({
15817
+ displayName: "MarketplaceRows__GoldContainer",
15816
15818
  componentId: "sc-wmpr1o-4"
15817
15819
  })(["position:relative;top:-0.5rem;left:0.5rem;"]);
15820
+ var SpriteContainer = /*#__PURE__*/styled.div.withConfig({
15821
+ displayName: "MarketplaceRows__SpriteContainer",
15822
+ componentId: "sc-wmpr1o-5"
15823
+ })(["position:relative;left:0.5rem;"]);
15818
15824
  var PriceValue = /*#__PURE__*/styled.div.withConfig({
15819
15825
  displayName: "MarketplaceRows__PriceValue",
15820
- componentId: "sc-wmpr1o-5"
15826
+ componentId: "sc-wmpr1o-6"
15821
15827
  })(["margin-left:40px;"]);
15822
15828
  var ButtonContainer$1 = /*#__PURE__*/styled.div.withConfig({
15823
15829
  displayName: "MarketplaceRows__ButtonContainer",
15824
- componentId: "sc-wmpr1o-6"
15830
+ componentId: "sc-wmpr1o-7"
15825
15831
  })(["margin:auto;"]);
15832
+ var RarityContainer = /*#__PURE__*/styled.div.withConfig({
15833
+ displayName: "MarketplaceRows__RarityContainer",
15834
+ componentId: "sc-wmpr1o-8"
15835
+ })(["border-color:", ";box-shadow:", " inset,", ";width:32px;height:32px;"], function (_ref2) {
15836
+ var item = _ref2.item;
15837
+ return rarityColor(item);
15838
+ }, function (_ref3) {
15839
+ var item = _ref3.item;
15840
+ return "0 0 5px 8px " + rarityColor(item);
15841
+ }, function (_ref4) {
15842
+ var item = _ref4.item;
15843
+ return "0 0 8px 6px " + rarityColor(item);
15844
+ });
15826
15845
 
15827
15846
  var OrderByType;
15828
15847
  (function (OrderByType) {
@@ -15854,7 +15873,7 @@ var orderByOptions = /*#__PURE__*/Object.values(OrderByType).flatMap(function (o
15854
15873
  transform: 'translateY(-2px)',
15855
15874
  display: 'inline-block'
15856
15875
  }
15857
- }, "\u2193"))
15876
+ }, "\u2191"))
15858
15877
  }, {
15859
15878
  id: index * 2 + 2,
15860
15879
  value: '-' + orderBy.toLowerCase(),
@@ -15863,7 +15882,7 @@ var orderByOptions = /*#__PURE__*/Object.values(OrderByType).flatMap(function (o
15863
15882
  transform: 'translateY(-2px)',
15864
15883
  display: 'inline-block'
15865
15884
  }
15866
- }, "\u2191"))
15885
+ }, "\u2193"))
15867
15886
  }];
15868
15887
  });
15869
15888
 
@@ -15882,7 +15901,8 @@ var BuyPanel = function BuyPanel(_ref) {
15882
15901
  onMarketPlaceItemBuy = _ref.onMarketPlaceItemBuy,
15883
15902
  characterId = _ref.characterId,
15884
15903
  enableHotkeys = _ref.enableHotkeys,
15885
- disableHotkeys = _ref.disableHotkeys;
15904
+ disableHotkeys = _ref.disableHotkeys,
15905
+ currentPage = _ref.currentPage;
15886
15906
  var _useState = useState(''),
15887
15907
  name = _useState[0],
15888
15908
  setName = _useState[1];
@@ -15898,6 +15918,11 @@ var BuyPanel = function BuyPanel(_ref) {
15898
15918
  var _useState5 = useState(null),
15899
15919
  buyingItemId = _useState5[0],
15900
15920
  setBuyingItemId = _useState5[1];
15921
+ var itemsContainer = useRef(null);
15922
+ useEffect(function () {
15923
+ var _itemsContainer$curre;
15924
+ (_itemsContainer$curre = itemsContainer.current) == null ? void 0 : _itemsContainer$curre.scrollTo(0, 0);
15925
+ }, [currentPage]);
15901
15926
  return React.createElement(React.Fragment, null, buyingItemId && React.createElement(ConfirmModal, {
15902
15927
  onClose: setBuyingItemId.bind(null, null),
15903
15928
  onConfirm: function onConfirm() {
@@ -15990,7 +16015,8 @@ var BuyPanel = function BuyPanel(_ref) {
15990
16015
  onChange: onChangeOrder,
15991
16016
  width: "100%"
15992
16017
  }))), React.createElement(ItemComponentScrollWrapper, {
15993
- id: "MarketContainer"
16018
+ id: "MarketContainer",
16019
+ ref: itemsContainer
15994
16020
  }, items == null ? void 0 : items.map(function (_ref2, index) {
15995
16021
  var item = _ref2.item,
15996
16022
  price = _ref2.price,
@@ -16046,7 +16072,8 @@ var ManagmentPanel = function ManagmentPanel(_ref) {
16046
16072
  onAddItemToMarketplace = _ref.onAddItemToMarketplace,
16047
16073
  enableHotkeys = _ref.enableHotkeys,
16048
16074
  disableHotkeys = _ref.disableHotkeys,
16049
- onMoneyWithdraw = _ref.onMoneyWithdraw;
16075
+ onMoneyWithdraw = _ref.onMoneyWithdraw,
16076
+ currentPage = _ref.currentPage;
16050
16077
  var _useState = useState(''),
16051
16078
  name = _useState[0],
16052
16079
  setName = _useState[1];
@@ -16059,6 +16086,11 @@ var ManagmentPanel = function ManagmentPanel(_ref) {
16059
16086
  var _useState4 = useState(null),
16060
16087
  removingItemId = _useState4[0],
16061
16088
  setRemovingItemId = _useState4[1];
16089
+ var itemsContainer = useRef(null);
16090
+ useEffect(function () {
16091
+ var _itemsContainer$curre;
16092
+ (_itemsContainer$curre = itemsContainer.current) == null ? void 0 : _itemsContainer$curre.scrollTo(0, 0);
16093
+ }, [currentPage]);
16062
16094
  return React.createElement(React.Fragment, null, isCreatingOffer && React.createElement(ConfirmModal, {
16063
16095
  onClose: setIsCreatingOffer.bind(null, false),
16064
16096
  onConfirm: function onConfirm() {
@@ -16125,7 +16157,8 @@ var ManagmentPanel = function ManagmentPanel(_ref) {
16125
16157
  return availableGold > 0 && onMoneyWithdraw();
16126
16158
  }
16127
16159
  }, "Withdraw")))), React.createElement(ItemComponentScrollWrapper$1, {
16128
- id: "MarketContainer"
16160
+ id: "MarketContainer",
16161
+ ref: itemsContainer
16129
16162
  }, items == null ? void 0 : items.map(function (_ref2, index) {
16130
16163
  var item = _ref2.item,
16131
16164
  price = _ref2.price,