@rpg-engine/long-bow 0.8.160 → 0.8.162
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.
- package/dist/components/Marketplace/BuyOrderRows.d.ts +11 -0
- package/dist/components/Marketplace/GroupedRowContainer.d.ts +7 -0
- package/dist/components/Pager.d.ts +1 -0
- package/dist/components/shared/ItemRowWrapper.d.ts +3 -0
- package/dist/long-bow.cjs.development.js +336 -203
- package/dist/long-bow.cjs.development.js.map +1 -1
- package/dist/long-bow.cjs.production.min.js +1 -1
- package/dist/long-bow.cjs.production.min.js.map +1 -1
- package/dist/long-bow.esm.js +336 -204
- package/dist/long-bow.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/Marketplace/BlueprintSearchModal.tsx +68 -29
- package/src/components/Marketplace/BlueprintTable.tsx +30 -21
- package/src/components/Marketplace/BuyOrderRows.tsx +53 -16
- package/src/components/Marketplace/BuyPanel.tsx +140 -114
- package/src/components/Marketplace/GroupedRowContainer.tsx +86 -0
- package/src/components/Marketplace/MarketplaceRows.tsx +24 -125
- package/src/components/Pager.tsx +13 -5
- package/src/components/Store/Store.tsx +22 -18
- package/src/components/Store/StoreItemRow.tsx +28 -33
- package/src/components/Store/sections/StoreItemsSection.tsx +7 -13
- package/src/components/Store/sections/StorePacksSection.tsx +19 -21
- package/src/components/shared/ItemRowWrapper.tsx +22 -0
- package/src/stories/Features/trading/Marketplace.stories.tsx +18 -5
|
@@ -29,12 +29,15 @@ var ShoppingBag = require('pixelarticons/react/ShoppingBag');
|
|
|
29
29
|
var ShoppingCart = require('pixelarticons/react/ShoppingCart');
|
|
30
30
|
var Store$1 = require('pixelarticons/react/Store');
|
|
31
31
|
var Wallet = require('pixelarticons/react/Wallet');
|
|
32
|
+
var SortVertical = require('pixelarticons/react/SortVertical');
|
|
32
33
|
var Search = require('pixelarticons/react/Search');
|
|
33
34
|
var Delete = require('pixelarticons/react/Delete');
|
|
34
35
|
require('rpgui/rpgui.css');
|
|
35
36
|
require('rpgui/rpgui.min.js');
|
|
36
|
-
var SortVertical = require('pixelarticons/react/SortVertical');
|
|
37
37
|
var Coins = require('pixelarticons/react/Coins');
|
|
38
|
+
var Box = require('pixelarticons/react/Box');
|
|
39
|
+
var Crown = require('pixelarticons/react/Crown');
|
|
40
|
+
var Gift = require('pixelarticons/react/Gift');
|
|
38
41
|
var capitalize = _interopDefault(require('lodash/capitalize'));
|
|
39
42
|
|
|
40
43
|
function _arrayLikeToArray(r, a) {
|
|
@@ -44504,9 +44507,13 @@ var Pager = function Pager(_ref) {
|
|
|
44504
44507
|
var totalItems = _ref.totalItems,
|
|
44505
44508
|
currentPage = _ref.currentPage,
|
|
44506
44509
|
itemsPerPage = _ref.itemsPerPage,
|
|
44507
|
-
onPageChange = _ref.onPageChange
|
|
44510
|
+
onPageChange = _ref.onPageChange,
|
|
44511
|
+
_ref$compact = _ref.compact,
|
|
44512
|
+
compact = _ref$compact === void 0 ? false : _ref$compact;
|
|
44508
44513
|
var totalPages = Math.ceil(totalItems / itemsPerPage);
|
|
44509
|
-
return React__default.createElement(Container$A, null, React__default.createElement("p", null, "Total items: ", totalItems), React__default.createElement(PagerContainer,
|
|
44514
|
+
return React__default.createElement(Container$A, null, !compact && React__default.createElement("p", null, "Total items: ", totalItems), React__default.createElement(PagerContainer, {
|
|
44515
|
+
"$compact": compact
|
|
44516
|
+
}, React__default.createElement("button", {
|
|
44510
44517
|
disabled: currentPage === 1,
|
|
44511
44518
|
onPointerDown: function onPointerDown() {
|
|
44512
44519
|
return onPageChange(Math.max(currentPage - 1, 1));
|
|
@@ -44527,7 +44534,19 @@ var Container$A = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
44527
44534
|
var PagerContainer = /*#__PURE__*/styled__default.div.withConfig({
|
|
44528
44535
|
displayName: "Pager__PagerContainer",
|
|
44529
44536
|
componentId: "sc-1ekmf50-1"
|
|
44530
|
-
})(["display:flex;justify-content:center;align-items:center;gap:5px;p{margin:0;}div{color:white;}button{width:
|
|
44537
|
+
})(["display:flex;justify-content:center;align-items:center;gap:5px;p{margin:0;}div{color:white;", "}button{width:", " !important;height:", " !important;font-size:", " !important;background-color:", ";border:none;border-radius:5px;color:white;:hover{background-color:", ";}:disabled{opacity:0.5;}&.active{background-color:", ";font-weight:bold;color:black;}}"], function (_ref2) {
|
|
44538
|
+
var $compact = _ref2.$compact;
|
|
44539
|
+
return $compact && "\n font-size: 0.55rem !important;\n padding: 2px 6px !important;\n min-width: unset !important;\n ";
|
|
44540
|
+
}, function (_ref3) {
|
|
44541
|
+
var $compact = _ref3.$compact;
|
|
44542
|
+
return $compact ? '24px' : '40px';
|
|
44543
|
+
}, function (_ref4) {
|
|
44544
|
+
var $compact = _ref4.$compact;
|
|
44545
|
+
return $compact ? '24px' : '40px';
|
|
44546
|
+
}, function (_ref5) {
|
|
44547
|
+
var $compact = _ref5.$compact;
|
|
44548
|
+
return $compact ? '0.55rem' : 'inherit';
|
|
44549
|
+
}, uiColors.darkGray, uiColors.lightGray, uiColors.orange);
|
|
44531
44550
|
|
|
44532
44551
|
var Tabs = function Tabs(_ref) {
|
|
44533
44552
|
var options = _ref.options,
|
|
@@ -44583,24 +44602,25 @@ var BlueprintTable = function BlueprintTable(_ref) {
|
|
|
44583
44602
|
atlasJSON: atlasJSON,
|
|
44584
44603
|
atlasIMG: atlasIMG,
|
|
44585
44604
|
spriteKey: blueprint.texturePath || blueprint.key,
|
|
44586
|
-
width:
|
|
44587
|
-
height:
|
|
44588
|
-
imgScale:
|
|
44605
|
+
width: 24,
|
|
44606
|
+
height: 24,
|
|
44607
|
+
imgScale: 1.5,
|
|
44589
44608
|
centered: true
|
|
44590
44609
|
})), React__default.createElement(ColName, null, React__default.createElement(BlueprintName, null, blueprint.name), (blueprint.type || blueprint.subType) && React__default.createElement(BlueprintMeta, null, [blueprint.type, blueprint.subType].filter(Boolean).filter(function (v, i, arr) {
|
|
44591
44610
|
return arr.indexOf(v) === i;
|
|
44592
44611
|
}).join(' · '))), React__default.createElement(ColType, null, React__default.createElement(TypeText, null, blueprint.type), blueprint.subType && blueprint.subType !== blueprint.type && React__default.createElement(SubTypeText, null, blueprint.subType)), React__default.createElement(ColTier, null, "T", blueprint.tier));
|
|
44593
44612
|
}));
|
|
44594
44613
|
};
|
|
44595
|
-
var tableRowBase = "\n display: grid;\n grid-template-columns:
|
|
44614
|
+
var tableRowBase = "\n display: grid;\n grid-template-columns: 28px 1fr 100px 40px;\n align-items: center;\n gap: 6px;\n padding: 3px 8px;\n";
|
|
44615
|
+
var mobileRowOverride = "\n @media (max-width: 600px) {\n padding: 1px 6px;\n gap: 4px;\n }\n";
|
|
44596
44616
|
var ResultsHeader = /*#__PURE__*/styled__default.div.withConfig({
|
|
44597
44617
|
displayName: "BlueprintTable__ResultsHeader",
|
|
44598
44618
|
componentId: "sc-1ysxhx2-0"
|
|
44599
|
-
})(["", " background:rgba(0,0,0,0.4);border-bottom:1px solid rgba(255,255,255,0.1);position:sticky;top:0;z-index:1
|
|
44619
|
+
})(["", " ", " background:rgba(0,0,0,0.4);border-bottom:1px solid rgba(255,255,255,0.1);position:sticky;top:0;z-index:1;&& > *{font-size:0.48rem !important;color:#555 !important;text-transform:uppercase;letter-spacing:1px;}"], tableRowBase, mobileRowOverride);
|
|
44600
44620
|
var ResultRow = /*#__PURE__*/styled__default.div.withConfig({
|
|
44601
44621
|
displayName: "BlueprintTable__ResultRow",
|
|
44602
44622
|
componentId: "sc-1ysxhx2-1"
|
|
44603
|
-
})(["", " border-bottom:1px solid rgba(255,255,255,0.04);cursor:", ";transition:background 0.1s;&:hover{background:", ";}&:last-child{border-bottom:none;}"], tableRowBase, function (p) {
|
|
44623
|
+
})(["", " ", " border-bottom:1px solid rgba(255,255,255,0.04);cursor:", ";transition:background 0.1s;&:hover{background:", ";}&:last-child{border-bottom:none;}"], tableRowBase, mobileRowOverride, function (p) {
|
|
44604
44624
|
return p.$selectable ? 'pointer' : 'default';
|
|
44605
44625
|
}, function (p) {
|
|
44606
44626
|
return p.$selectable ? 'rgba(245, 158, 11, 0.08)' : 'none';
|
|
@@ -44608,7 +44628,7 @@ var ResultRow = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
44608
44628
|
var SpriteWrapper$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
44609
44629
|
displayName: "BlueprintTable__SpriteWrapper",
|
|
44610
44630
|
componentId: "sc-1ysxhx2-2"
|
|
44611
|
-
})(["display:flex;align-items:center;justify-content:center;width:
|
|
44631
|
+
})(["display:flex;align-items:center;justify-content:center;width:28px;height:24px;"]);
|
|
44612
44632
|
var ColName = /*#__PURE__*/styled__default.div.withConfig({
|
|
44613
44633
|
displayName: "BlueprintTable__ColName",
|
|
44614
44634
|
componentId: "sc-1ysxhx2-3"
|
|
@@ -44616,11 +44636,11 @@ var ColName = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
44616
44636
|
var BlueprintName = /*#__PURE__*/styled__default.span.withConfig({
|
|
44617
44637
|
displayName: "BlueprintTable__BlueprintName",
|
|
44618
44638
|
componentId: "sc-1ysxhx2-4"
|
|
44619
|
-
})(["font-size:0.
|
|
44639
|
+
})(["font-size:0.6rem !important;color:#e5e7eb !important;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;"]);
|
|
44620
44640
|
var BlueprintMeta = /*#__PURE__*/styled__default.span.withConfig({
|
|
44621
44641
|
displayName: "BlueprintTable__BlueprintMeta",
|
|
44622
44642
|
componentId: "sc-1ysxhx2-5"
|
|
44623
|
-
})(["font-size:0.
|
|
44643
|
+
})(["font-size:0.5rem !important;color:#f59e0b !important;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;"]);
|
|
44624
44644
|
var ColType = /*#__PURE__*/styled__default.div.withConfig({
|
|
44625
44645
|
displayName: "BlueprintTable__ColType",
|
|
44626
44646
|
componentId: "sc-1ysxhx2-6"
|
|
@@ -44628,15 +44648,15 @@ var ColType = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
44628
44648
|
var TypeText = /*#__PURE__*/styled__default.span.withConfig({
|
|
44629
44649
|
displayName: "BlueprintTable__TypeText",
|
|
44630
44650
|
componentId: "sc-1ysxhx2-7"
|
|
44631
|
-
})(["font-size:0.
|
|
44651
|
+
})(["font-size:0.52rem !important;color:#9ca3af !important;"]);
|
|
44632
44652
|
var SubTypeText = /*#__PURE__*/styled__default.span.withConfig({
|
|
44633
44653
|
displayName: "BlueprintTable__SubTypeText",
|
|
44634
44654
|
componentId: "sc-1ysxhx2-8"
|
|
44635
|
-
})(["font-size:0.
|
|
44655
|
+
})(["font-size:0.46rem !important;color:#f59e0b !important;"]);
|
|
44636
44656
|
var ColTier = /*#__PURE__*/styled__default.div.withConfig({
|
|
44637
44657
|
displayName: "BlueprintTable__ColTier",
|
|
44638
44658
|
componentId: "sc-1ysxhx2-9"
|
|
44639
|
-
})(["font-size:0.
|
|
44659
|
+
})(["font-size:0.6rem !important;color:#f59e0b !important;text-align:center;"]);
|
|
44640
44660
|
|
|
44641
44661
|
var BLUEPRINTS_PER_PAGE = 10;
|
|
44642
44662
|
var scaleIn = /*#__PURE__*/styled.keyframes(["from{transform:scale(0.85);opacity:0;}to{transform:scale(1);opacity:1;}"]);
|
|
@@ -44688,6 +44708,9 @@ var BlueprintSearchModal = function BlueprintSearchModal(_ref) {
|
|
|
44688
44708
|
var _useState3 = React.useState(''),
|
|
44689
44709
|
selectedSubType = _useState3[0],
|
|
44690
44710
|
setSelectedSubType = _useState3[1];
|
|
44711
|
+
var _useState4 = React.useState(false),
|
|
44712
|
+
showFilters = _useState4[0],
|
|
44713
|
+
setShowFilters = _useState4[1];
|
|
44691
44714
|
var searchNameRef = React.useRef(searchName);
|
|
44692
44715
|
var selectedTypeRef = React.useRef(selectedType);
|
|
44693
44716
|
var selectedSubTypeRef = React.useRef(selectedSubType);
|
|
@@ -44764,7 +44787,19 @@ var BlueprintSearchModal = function BlueprintSearchModal(_ref) {
|
|
|
44764
44787
|
placeholder: "Search by name...",
|
|
44765
44788
|
onFocus: disableHotkeys,
|
|
44766
44789
|
onBlur: enableHotkeys
|
|
44767
|
-
})
|
|
44790
|
+
}), React__default.createElement(FilterButton$1, {
|
|
44791
|
+
type: "button",
|
|
44792
|
+
"$active": showFilters,
|
|
44793
|
+
onPointerDown: function onPointerDown() {
|
|
44794
|
+
return setShowFilters(function (v) {
|
|
44795
|
+
return !v;
|
|
44796
|
+
});
|
|
44797
|
+
},
|
|
44798
|
+
"aria-label": "Toggle filters"
|
|
44799
|
+
}, React__default.createElement(SortVertical.SortVertical, {
|
|
44800
|
+
width: 16,
|
|
44801
|
+
height: 16
|
|
44802
|
+
}))), showFilters && React__default.createElement(FiltersRow, null, React__default.createElement(StyledDropdown$3, {
|
|
44768
44803
|
key: "type-" + selectedType,
|
|
44769
44804
|
options: typeOptions,
|
|
44770
44805
|
onChange: handleTypeChange,
|
|
@@ -44781,12 +44816,13 @@ var BlueprintSearchModal = function BlueprintSearchModal(_ref) {
|
|
|
44781
44816
|
atlasJSON: atlasJSON,
|
|
44782
44817
|
atlasIMG: atlasIMG,
|
|
44783
44818
|
onSelect: onSelect
|
|
44784
|
-
})), isLoading && React__default.createElement(LoadingOverlay, null, React__default.createElement(LoadingText, null, "Loading..."))), React__default.createElement(
|
|
44819
|
+
})), isLoading && React__default.createElement(LoadingOverlay, null, React__default.createElement(LoadingText, null, "Loading..."))), React__default.createElement(Pager, {
|
|
44820
|
+
compact: true,
|
|
44785
44821
|
totalItems: totalCount,
|
|
44786
44822
|
currentPage: currentPage,
|
|
44787
44823
|
itemsPerPage: BLUEPRINTS_PER_PAGE,
|
|
44788
44824
|
onPageChange: handlePageChange
|
|
44789
|
-
}))))
|
|
44825
|
+
}))));
|
|
44790
44826
|
};
|
|
44791
44827
|
var Overlay$4 = /*#__PURE__*/styled__default.div.withConfig({
|
|
44792
44828
|
displayName: "BlueprintSearchModal__Overlay",
|
|
@@ -44799,7 +44835,7 @@ var ModalContainer$2 = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
44799
44835
|
var ModalContent$2 = /*#__PURE__*/styled__default.div.withConfig({
|
|
44800
44836
|
displayName: "BlueprintSearchModal__ModalContent",
|
|
44801
44837
|
componentId: "sc-i7bssq-2"
|
|
44802
|
-
})(["background:#1a1a2e;border:2px solid #f59e0b;border-radius:8px;padding:20px 24px;width:600px;max-width:90%;display:flex;flex-direction:column;gap:12px;pointer-events:auto;animation:", " 0.15s ease-out;"], scaleIn);
|
|
44838
|
+
})(["background:#1a1a2e;border:2px solid #f59e0b;border-radius:8px;padding:20px 24px;width:600px;max-width:90%;max-height:90dvh;display:flex;flex-direction:column;gap:12px;overflow:hidden;pointer-events:auto;animation:", " 0.15s ease-out;@media (max-width:950px){max-width:96%;max-height:95dvh;min-height:75dvh;padding:14px 16px;gap:8px;}"], scaleIn);
|
|
44803
44839
|
var Header$8 = /*#__PURE__*/styled__default.div.withConfig({
|
|
44804
44840
|
displayName: "BlueprintSearchModal__Header",
|
|
44805
44841
|
componentId: "sc-i7bssq-3"
|
|
@@ -44820,40 +44856,49 @@ var StyledInput$2 = /*#__PURE__*/styled__default(Input).withConfig({
|
|
|
44820
44856
|
displayName: "BlueprintSearchModal__StyledInput",
|
|
44821
44857
|
componentId: "sc-i7bssq-7"
|
|
44822
44858
|
})(["flex:1;"]);
|
|
44859
|
+
var FilterButton$1 = /*#__PURE__*/styled__default.button.withConfig({
|
|
44860
|
+
displayName: "BlueprintSearchModal__FilterButton",
|
|
44861
|
+
componentId: "sc-i7bssq-8"
|
|
44862
|
+
})(["flex-shrink:0;width:28px;height:28px;border-radius:6px;border:1px solid ", ";background:", ";color:", ";cursor:pointer;display:flex;align-items:center;justify-content:center;transition:color 0.15s,border-color 0.15s,background 0.15s;&:hover{color:#f59e0b;border-color:rgba(245,158,11,0.45);}"], function (_ref2) {
|
|
44863
|
+
var $active = _ref2.$active;
|
|
44864
|
+
return $active ? 'rgba(245, 158, 11, 0.55)' : 'rgba(255, 255, 255, 0.08)';
|
|
44865
|
+
}, function (_ref3) {
|
|
44866
|
+
var $active = _ref3.$active;
|
|
44867
|
+
return $active ? 'rgba(245, 158, 11, 0.14)' : 'rgba(255, 255, 255, 0.03)';
|
|
44868
|
+
}, function (_ref4) {
|
|
44869
|
+
var $active = _ref4.$active;
|
|
44870
|
+
return $active ? '#f59e0b' : '#ccc';
|
|
44871
|
+
});
|
|
44823
44872
|
var FiltersRow = /*#__PURE__*/styled__default.div.withConfig({
|
|
44824
44873
|
displayName: "BlueprintSearchModal__FiltersRow",
|
|
44825
|
-
componentId: "sc-i7bssq-
|
|
44874
|
+
componentId: "sc-i7bssq-9"
|
|
44826
44875
|
})(["display:grid;grid-template-columns:1fr 1fr;gap:8px;"]);
|
|
44827
44876
|
var StyledDropdown$3 = /*#__PURE__*/styled__default(Dropdown).withConfig({
|
|
44828
44877
|
displayName: "BlueprintSearchModal__StyledDropdown",
|
|
44829
|
-
componentId: "sc-i7bssq-
|
|
44878
|
+
componentId: "sc-i7bssq-10"
|
|
44830
44879
|
})(["margin:0px !important;width:100% !important;"]);
|
|
44831
44880
|
var ResultsWrapper = /*#__PURE__*/styled__default.div.withConfig({
|
|
44832
44881
|
displayName: "BlueprintSearchModal__ResultsWrapper",
|
|
44833
|
-
componentId: "sc-i7bssq-
|
|
44834
|
-
})(["position:relative;overflow-y:auto;height:
|
|
44882
|
+
componentId: "sc-i7bssq-11"
|
|
44883
|
+
})(["position:relative;overflow-y:auto;flex:1;min-height:80px;display:flex;flex-direction:column;background:rgba(0,0,0,0.2);border:1px solid rgba(255,255,255,0.05);border-radius:4px;"]);
|
|
44835
44884
|
var ResultsContent = /*#__PURE__*/styled__default.div.withConfig({
|
|
44836
44885
|
displayName: "BlueprintSearchModal__ResultsContent",
|
|
44837
|
-
componentId: "sc-i7bssq-
|
|
44886
|
+
componentId: "sc-i7bssq-12"
|
|
44838
44887
|
})(["opacity:", ";transition:opacity 0.15s ease;"], function (p) {
|
|
44839
44888
|
return p.$dimmed ? 0.4 : 1;
|
|
44840
44889
|
});
|
|
44841
44890
|
var LoadingOverlay = /*#__PURE__*/styled__default.div.withConfig({
|
|
44842
44891
|
displayName: "BlueprintSearchModal__LoadingOverlay",
|
|
44843
|
-
componentId: "sc-i7bssq-
|
|
44892
|
+
componentId: "sc-i7bssq-13"
|
|
44844
44893
|
})(["position:absolute;inset:0;display:flex;align-items:center;justify-content:center;pointer-events:none;"]);
|
|
44845
44894
|
var LoadingText = /*#__PURE__*/styled__default.span.withConfig({
|
|
44846
44895
|
displayName: "BlueprintSearchModal__LoadingText",
|
|
44847
|
-
componentId: "sc-i7bssq-
|
|
44896
|
+
componentId: "sc-i7bssq-14"
|
|
44848
44897
|
})(["font-size:0.55rem;color:#f59e0b;text-transform:uppercase;letter-spacing:1px;"]);
|
|
44849
44898
|
var EmptyState$2 = /*#__PURE__*/styled__default.div.withConfig({
|
|
44850
44899
|
displayName: "BlueprintSearchModal__EmptyState",
|
|
44851
|
-
componentId: "sc-i7bssq-14"
|
|
44852
|
-
})(["display:flex;align-items:center;justify-content:center;height:100%;font-size:0.55rem;color:#666;text-transform:uppercase;letter-spacing:1px;"]);
|
|
44853
|
-
var PagerContainer$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
44854
|
-
displayName: "BlueprintSearchModal__PagerContainer",
|
|
44855
44900
|
componentId: "sc-i7bssq-15"
|
|
44856
|
-
})(["display:flex;justify-content:center;
|
|
44901
|
+
})(["display:flex;align-items:center;justify-content:center;flex:1;font-size:0.55rem;color:#666;text-transform:uppercase;letter-spacing:1px;"]);
|
|
44857
44902
|
|
|
44858
44903
|
var SegmentedToggle = function SegmentedToggle(_ref) {
|
|
44859
44904
|
var options = _ref.options,
|
|
@@ -45064,6 +45109,58 @@ var CancelButton$1 = /*#__PURE__*/styled__default.button.withConfig({
|
|
|
45064
45109
|
componentId: "sc-6bghe9-17"
|
|
45065
45110
|
})(["flex:1;background:rgba(255,255,255,0.05);border:1px solid rgba(255,255,255,0.1);color:#ccc;border-radius:4px;padding:8px 12px;font-size:0.5rem;font-family:'Press Start 2P',cursive;cursor:pointer;text-transform:uppercase;letter-spacing:0.5px;transition:background 0.1s,border-color 0.1s;pointer-events:auto;&:hover{background:rgba(255,255,255,0.08);border-color:rgba(255,255,255,0.15);}"]);
|
|
45066
45111
|
|
|
45112
|
+
var GroupedRowContainer = function GroupedRowContainer(_ref) {
|
|
45113
|
+
var mainRow = _ref.mainRow,
|
|
45114
|
+
subRows = _ref.subRows,
|
|
45115
|
+
_ref$badgeLabel = _ref.badgeLabel,
|
|
45116
|
+
badgeLabel = _ref$badgeLabel === void 0 ? 'offers' : _ref$badgeLabel;
|
|
45117
|
+
var _useState = React.useState(false),
|
|
45118
|
+
expanded = _useState[0],
|
|
45119
|
+
setExpanded = _useState[1];
|
|
45120
|
+
var hasMultiple = subRows.length > 0;
|
|
45121
|
+
var totalCount = subRows.length + 1;
|
|
45122
|
+
return React__default.createElement(GroupWrapper, null, React__default.createElement(GroupHeader, {
|
|
45123
|
+
"$clickable": hasMultiple,
|
|
45124
|
+
onClick: hasMultiple ? function () {
|
|
45125
|
+
return setExpanded(function (e) {
|
|
45126
|
+
return !e;
|
|
45127
|
+
});
|
|
45128
|
+
} : undefined
|
|
45129
|
+
}, mainRow, hasMultiple && React__default.createElement(GroupMeta, null, React__default.createElement(OfferBadge, null, totalCount, " ", badgeLabel), React__default.createElement(Chevron, {
|
|
45130
|
+
"$expanded": expanded
|
|
45131
|
+
}, "\u25B8"))), expanded && React__default.createElement(SubRows, null, subRows));
|
|
45132
|
+
};
|
|
45133
|
+
var GroupWrapper = /*#__PURE__*/styled__default.div.withConfig({
|
|
45134
|
+
displayName: "GroupedRowContainer__GroupWrapper",
|
|
45135
|
+
componentId: "sc-12q03tq-0"
|
|
45136
|
+
})(["margin-bottom:2px;"]);
|
|
45137
|
+
var GroupHeader = /*#__PURE__*/styled__default.div.withConfig({
|
|
45138
|
+
displayName: "GroupedRowContainer__GroupHeader",
|
|
45139
|
+
componentId: "sc-12q03tq-1"
|
|
45140
|
+
})(["position:relative;cursor:", ";"], function (_ref2) {
|
|
45141
|
+
var $clickable = _ref2.$clickable;
|
|
45142
|
+
return $clickable ? 'pointer' : 'default';
|
|
45143
|
+
});
|
|
45144
|
+
var GroupMeta = /*#__PURE__*/styled__default.div.withConfig({
|
|
45145
|
+
displayName: "GroupedRowContainer__GroupMeta",
|
|
45146
|
+
componentId: "sc-12q03tq-2"
|
|
45147
|
+
})(["position:absolute;right:180px;top:50%;transform:translateY(-50%);display:flex;align-items:center;gap:6px;pointer-events:none;"]);
|
|
45148
|
+
var OfferBadge = /*#__PURE__*/styled__default.span.withConfig({
|
|
45149
|
+
displayName: "GroupedRowContainer__OfferBadge",
|
|
45150
|
+
componentId: "sc-12q03tq-3"
|
|
45151
|
+
})(["font-family:'Press Start 2P',cursive;font-size:0.5rem;color:rgba(255,255,255,0.5);background:rgba(255,255,255,0.08);padding:2px 6px;border-radius:8px;white-space:nowrap;"]);
|
|
45152
|
+
var Chevron = /*#__PURE__*/styled__default.span.withConfig({
|
|
45153
|
+
displayName: "GroupedRowContainer__Chevron",
|
|
45154
|
+
componentId: "sc-12q03tq-4"
|
|
45155
|
+
})(["display:inline-block;font-size:0.7rem;color:rgba(255,255,255,0.4);transition:transform 0.2s ease;transform:rotate(", ");"], function (_ref3) {
|
|
45156
|
+
var $expanded = _ref3.$expanded;
|
|
45157
|
+
return $expanded ? '90deg' : '0deg';
|
|
45158
|
+
});
|
|
45159
|
+
var SubRows = /*#__PURE__*/styled__default.div.withConfig({
|
|
45160
|
+
displayName: "GroupedRowContainer__SubRows",
|
|
45161
|
+
componentId: "sc-12q03tq-5"
|
|
45162
|
+
})(["margin-left:12px;padding-left:8px;border-left:2px solid rgba(245,158,11,0.25);> div > div{background:rgba(0,0,0,0.4);}"]);
|
|
45163
|
+
|
|
45067
45164
|
var LabelPill = function LabelPill(_ref) {
|
|
45068
45165
|
var children = _ref.children,
|
|
45069
45166
|
_ref$background = _ref.background,
|
|
@@ -45324,19 +45421,18 @@ var BuyOrderRow = function BuyOrderRow(_ref) {
|
|
|
45324
45421
|
background: "rgba(34, 197, 94, 0.16)",
|
|
45325
45422
|
borderColor: "rgba(34, 197, 94, 0.4)",
|
|
45326
45423
|
color: "#bbf7d0"
|
|
45327
|
-
}, requestTagLabel),
|
|
45328
|
-
background: rarityGlow != null ? rarityGlow : 'rgba(255,255,255,0.1)',
|
|
45329
|
-
borderColor: "rgba(255,255,255,0.08)",
|
|
45330
|
-
color: "#fff"
|
|
45331
|
-
}, buyOrder.itemRarity), isOwn && React__default.createElement(LabelPill, {
|
|
45424
|
+
}, requestTagLabel), isOwn && React__default.createElement(LabelPill, {
|
|
45332
45425
|
background: STATUS_COLORS[buyOrder.status],
|
|
45333
45426
|
borderColor: "transparent",
|
|
45334
45427
|
color: "#fff"
|
|
45335
|
-
}, formatStatusLabel(buyOrder.status)), timeRemaining && React__default.createElement(
|
|
45428
|
+
}, formatStatusLabel(buyOrder.status)), timeRemaining && React__default.createElement(SimpleTooltip, {
|
|
45429
|
+
content: "Expires in",
|
|
45430
|
+
direction: "top"
|
|
45431
|
+
}, React__default.createElement(LabelPill, {
|
|
45336
45432
|
background: "rgba(255,255,255,0.08)",
|
|
45337
45433
|
borderColor: "rgba(255,255,255,0.08)",
|
|
45338
45434
|
color: "#fff"
|
|
45339
|
-
}, timeRemaining)))), isOwn && buyOrder.status === shared.MarketplaceBuyOrderStatus.Active && onCancel && React__default.createElement(ActionSection, null, React__default.createElement(CTAButton, {
|
|
45435
|
+
}, timeRemaining))))), isOwn && buyOrder.status === shared.MarketplaceBuyOrderStatus.Active && onCancel && React__default.createElement(ActionSection, null, React__default.createElement(CTAButton, {
|
|
45340
45436
|
icon: React__default.createElement(Delete.Delete, {
|
|
45341
45437
|
width: 18,
|
|
45342
45438
|
height: 18
|
|
@@ -45358,6 +45454,33 @@ var BuyOrderRow = function BuyOrderRow(_ref) {
|
|
|
45358
45454
|
}
|
|
45359
45455
|
})));
|
|
45360
45456
|
};
|
|
45457
|
+
var GroupedBuyOrderRow = function GroupedBuyOrderRow(_ref2) {
|
|
45458
|
+
var bestOrder = _ref2.bestOrder,
|
|
45459
|
+
otherOrders = _ref2.otherOrders,
|
|
45460
|
+
atlasJSON = _ref2.atlasJSON,
|
|
45461
|
+
atlasIMG = _ref2.atlasIMG,
|
|
45462
|
+
isOwn = _ref2.isOwn,
|
|
45463
|
+
onCancel = _ref2.onCancel,
|
|
45464
|
+
onFulfill = _ref2.onFulfill,
|
|
45465
|
+
showRequestTag = _ref2.showRequestTag;
|
|
45466
|
+
var makeRow = function makeRow(order) {
|
|
45467
|
+
return React__default.createElement(BuyOrderRow, {
|
|
45468
|
+
key: order._id,
|
|
45469
|
+
buyOrder: order,
|
|
45470
|
+
atlasJSON: atlasJSON,
|
|
45471
|
+
atlasIMG: atlasIMG,
|
|
45472
|
+
isOwn: isOwn,
|
|
45473
|
+
onCancel: onCancel,
|
|
45474
|
+
onFulfill: onFulfill,
|
|
45475
|
+
showRequestTag: showRequestTag
|
|
45476
|
+
});
|
|
45477
|
+
};
|
|
45478
|
+
return React__default.createElement(GroupedRowContainer, {
|
|
45479
|
+
mainRow: makeRow(bestOrder),
|
|
45480
|
+
subRows: otherOrders.map(makeRow),
|
|
45481
|
+
badgeLabel: "requests"
|
|
45482
|
+
});
|
|
45483
|
+
};
|
|
45361
45484
|
// ── Styled components matching MarketplaceRows layout ──
|
|
45362
45485
|
var RowWrapper = /*#__PURE__*/styled__default.div.withConfig({
|
|
45363
45486
|
displayName: "BuyOrderRows__RowWrapper",
|
|
@@ -45374,8 +45497,8 @@ var SpriteContainer$3 = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
45374
45497
|
var RarityGlow = /*#__PURE__*/styled__default.div.withConfig({
|
|
45375
45498
|
displayName: "BuyOrderRows__RarityGlow",
|
|
45376
45499
|
componentId: "sc-zz5s5j-3"
|
|
45377
|
-
})(["width:32px;height:32px;", ""], function (
|
|
45378
|
-
var $color =
|
|
45500
|
+
})(["width:32px;height:32px;", ""], function (_ref3) {
|
|
45501
|
+
var $color = _ref3.$color;
|
|
45379
45502
|
return $color ? "\n border-color: " + $color + ";\n box-shadow: 0 0 5px 8px " + $color + " inset, 0 0 8px 6px " + $color + ";\n " : '';
|
|
45380
45503
|
});
|
|
45381
45504
|
var SpritePlaceholder = /*#__PURE__*/styled__default.div.withConfig({
|
|
@@ -45745,6 +45868,15 @@ var ConfirmRow = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
45745
45868
|
componentId: "sc-86ottl-13"
|
|
45746
45869
|
})(["display:flex;justify-content:center;margin-top:4px;"]);
|
|
45747
45870
|
|
|
45871
|
+
var ItemRowWrapper = /*#__PURE__*/styled__default.div.withConfig({
|
|
45872
|
+
displayName: "ItemRowWrapper",
|
|
45873
|
+
componentId: "sc-5g2skk-0"
|
|
45874
|
+
})(["display:flex;align-items:center;justify-content:space-between;padding:0.6rem 1rem;margin-bottom:4px;background:", ";border:1px solid rgba(255,255,255,0.05);border-radius:6px;border-left:4px solid ", ";transition:all 0.2s ease-in-out;&:hover{background:rgba(245,158,11,0.08);border-color:rgba(245,158,11,0.2);border-left-color:#f59e0b;box-shadow:0 4px 12px rgba(0,0,0,0.2);transform:translateY(-1px);}"], function (p) {
|
|
45875
|
+
return p.$isHighlighted ? 'rgba(255, 215, 0, 0.08)' : 'rgba(0, 0, 0, 0.25)';
|
|
45876
|
+
}, function (p) {
|
|
45877
|
+
return p.$isHighlighted ? '#ffd700' : 'transparent';
|
|
45878
|
+
});
|
|
45879
|
+
|
|
45748
45880
|
var MarketplaceRows = function MarketplaceRows(_ref) {
|
|
45749
45881
|
var atlasJSON = _ref.atlasJSON,
|
|
45750
45882
|
atlasIMG = _ref.atlasIMG,
|
|
@@ -45760,7 +45892,7 @@ var MarketplaceRows = function MarketplaceRows(_ref) {
|
|
|
45760
45892
|
var renderGems = function renderGems(item) {
|
|
45761
45893
|
return item.attachedGems && onRenderGems(item);
|
|
45762
45894
|
};
|
|
45763
|
-
return React__default.createElement(
|
|
45895
|
+
return React__default.createElement(ItemRowWrapper, null, React__default.createElement(ItemSection$1, null, React__default.createElement(SpriteContainer$4, null, React__default.createElement(ItemInfoWrapper, {
|
|
45764
45896
|
item: item,
|
|
45765
45897
|
atlasIMG: atlasIMG,
|
|
45766
45898
|
atlasJSON: atlasJSON,
|
|
@@ -45832,31 +45964,7 @@ var GroupedMarketplaceRow = function GroupedMarketplaceRow(_ref2) {
|
|
|
45832
45964
|
characterId = _ref2.characterId,
|
|
45833
45965
|
onBuy = _ref2.onBuy,
|
|
45834
45966
|
onDCCoinClick = _ref2.onDCCoinClick;
|
|
45835
|
-
var
|
|
45836
|
-
expanded = _useState[0],
|
|
45837
|
-
setExpanded = _useState[1];
|
|
45838
|
-
var totalOffers = otherListings.length + 1;
|
|
45839
|
-
var hasMultiple = otherListings.length > 0;
|
|
45840
|
-
return React__default.createElement(GroupWrapper, null, React__default.createElement(GroupHeader, {
|
|
45841
|
-
onClick: hasMultiple ? function () {
|
|
45842
|
-
return setExpanded(!expanded);
|
|
45843
|
-
} : undefined,
|
|
45844
|
-
clickable: hasMultiple
|
|
45845
|
-
}, React__default.createElement(MarketplaceRows, {
|
|
45846
|
-
atlasIMG: atlasIMG,
|
|
45847
|
-
atlasJSON: atlasJSON,
|
|
45848
|
-
item: bestListing.item,
|
|
45849
|
-
itemPrice: bestListing.price,
|
|
45850
|
-
dcEquivalentPrice: dcToGoldSwapRate > 0 ? getDCEquivalentPrice(bestListing.price) : undefined,
|
|
45851
|
-
equipmentSet: equipmentSet,
|
|
45852
|
-
onMarketPlaceItemBuy: function onMarketPlaceItemBuy() {
|
|
45853
|
-
return onBuy(bestListing._id);
|
|
45854
|
-
},
|
|
45855
|
-
onDCCoinClick: onDCCoinClick,
|
|
45856
|
-
disabled: bestListing.owner === characterId
|
|
45857
|
-
}), hasMultiple && React__default.createElement(GroupMeta, null, React__default.createElement(OfferBadge, null, totalOffers, " offers"), React__default.createElement(Chevron, {
|
|
45858
|
-
expanded: expanded
|
|
45859
|
-
}, "\u25B8"))), expanded && React__default.createElement(SubRows, null, otherListings.map(function (listing) {
|
|
45967
|
+
var makeRow = function makeRow(listing) {
|
|
45860
45968
|
return React__default.createElement(MarketplaceRows, {
|
|
45861
45969
|
key: listing._id,
|
|
45862
45970
|
atlasIMG: atlasIMG,
|
|
@@ -45871,115 +45979,86 @@ var GroupedMarketplaceRow = function GroupedMarketplaceRow(_ref2) {
|
|
|
45871
45979
|
onDCCoinClick: onDCCoinClick,
|
|
45872
45980
|
disabled: listing.owner === characterId
|
|
45873
45981
|
});
|
|
45874
|
-
}
|
|
45982
|
+
};
|
|
45983
|
+
return React__default.createElement(GroupedRowContainer, {
|
|
45984
|
+
mainRow: makeRow(bestListing),
|
|
45985
|
+
subRows: otherListings.map(makeRow),
|
|
45986
|
+
badgeLabel: "offers"
|
|
45987
|
+
});
|
|
45875
45988
|
};
|
|
45876
|
-
var GroupWrapper = /*#__PURE__*/styled__default.div.withConfig({
|
|
45877
|
-
displayName: "MarketplaceRows__GroupWrapper",
|
|
45878
|
-
componentId: "sc-wmpr1o-0"
|
|
45879
|
-
})(["margin-bottom:2px;"]);
|
|
45880
|
-
var GroupHeader = /*#__PURE__*/styled__default.div.withConfig({
|
|
45881
|
-
displayName: "MarketplaceRows__GroupHeader",
|
|
45882
|
-
componentId: "sc-wmpr1o-1"
|
|
45883
|
-
})(["position:relative;cursor:", ";"], function (_ref3) {
|
|
45884
|
-
var clickable = _ref3.clickable;
|
|
45885
|
-
return clickable ? 'pointer' : 'default';
|
|
45886
|
-
});
|
|
45887
|
-
var GroupMeta = /*#__PURE__*/styled__default.div.withConfig({
|
|
45888
|
-
displayName: "MarketplaceRows__GroupMeta",
|
|
45889
|
-
componentId: "sc-wmpr1o-2"
|
|
45890
|
-
})(["position:absolute;right:180px;top:50%;transform:translateY(-50%);display:flex;align-items:center;gap:6px;pointer-events:none;"]);
|
|
45891
|
-
var OfferBadge = /*#__PURE__*/styled__default.span.withConfig({
|
|
45892
|
-
displayName: "MarketplaceRows__OfferBadge",
|
|
45893
|
-
componentId: "sc-wmpr1o-3"
|
|
45894
|
-
})(["font-family:'Press Start 2P',cursive;font-size:0.5rem;color:rgba(255,255,255,0.5);background:rgba(255,255,255,0.08);padding:2px 6px;border-radius:8px;white-space:nowrap;"]);
|
|
45895
|
-
var Chevron = /*#__PURE__*/styled__default.span.withConfig({
|
|
45896
|
-
displayName: "MarketplaceRows__Chevron",
|
|
45897
|
-
componentId: "sc-wmpr1o-4"
|
|
45898
|
-
})(["display:inline-block;font-size:0.7rem;color:rgba(255,255,255,0.4);transition:transform 0.2s ease;transform:rotate(", ");"], function (_ref4) {
|
|
45899
|
-
var expanded = _ref4.expanded;
|
|
45900
|
-
return expanded ? '90deg' : '0deg';
|
|
45901
|
-
});
|
|
45902
|
-
var SubRows = /*#__PURE__*/styled__default.div.withConfig({
|
|
45903
|
-
displayName: "MarketplaceRows__SubRows",
|
|
45904
|
-
componentId: "sc-wmpr1o-5"
|
|
45905
|
-
})(["margin-left:12px;padding-left:8px;border-left:2px solid rgba(245,158,11,0.25);> div > div{background:rgba(0,0,0,0.4);}"]);
|
|
45906
|
-
var MarketplaceWrapper = /*#__PURE__*/styled__default.div.withConfig({
|
|
45907
|
-
displayName: "MarketplaceRows__MarketplaceWrapper",
|
|
45908
|
-
componentId: "sc-wmpr1o-6"
|
|
45909
|
-
})(["display:flex;align-items:center;justify-content:space-between;padding:0.6rem 1rem;margin-bottom:4px;background:rgba(0,0,0,0.25);border:1px solid rgba(255,255,255,0.05);border-radius:6px;border-left:4px solid transparent;transition:all 0.2s ease-in-out;&:hover{background:rgba(245,158,11,0.08);border-color:rgba(245,158,11,0.2);border-left-color:#f59e0b;box-shadow:0 4px 12px rgba(0,0,0,0.2);transform:translateY(-1px);}"]);
|
|
45910
45989
|
var ItemSection$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
45911
45990
|
displayName: "MarketplaceRows__ItemSection",
|
|
45912
|
-
componentId: "sc-wmpr1o-
|
|
45991
|
+
componentId: "sc-wmpr1o-0"
|
|
45913
45992
|
})(["display:flex;align-items:center;gap:0.75rem;flex:1;min-width:0;"]);
|
|
45914
45993
|
var SpriteContainer$4 = /*#__PURE__*/styled__default.div.withConfig({
|
|
45915
45994
|
displayName: "MarketplaceRows__SpriteContainer",
|
|
45916
|
-
componentId: "sc-wmpr1o-
|
|
45995
|
+
componentId: "sc-wmpr1o-1"
|
|
45917
45996
|
})(["position:relative;flex-shrink:0;min-width:44px;"]);
|
|
45918
45997
|
var ItemDetails$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
45919
45998
|
displayName: "MarketplaceRows__ItemDetails",
|
|
45920
|
-
componentId: "sc-wmpr1o-
|
|
45999
|
+
componentId: "sc-wmpr1o-2"
|
|
45921
46000
|
})(["display:flex;flex-direction:column;gap:0.2rem;min-width:0;margin-left:1rem;"]);
|
|
45922
46001
|
var ItemName$2 = /*#__PURE__*/styled__default.div.withConfig({
|
|
45923
46002
|
displayName: "MarketplaceRows__ItemName",
|
|
45924
|
-
componentId: "sc-wmpr1o-
|
|
46003
|
+
componentId: "sc-wmpr1o-3"
|
|
45925
46004
|
})(["font-family:'Press Start 2P',cursive;font-size:0.65rem;color:#ffffff;"]);
|
|
45926
46005
|
var PriceRow = /*#__PURE__*/styled__default.div.withConfig({
|
|
45927
46006
|
displayName: "MarketplaceRows__PriceRow",
|
|
45928
|
-
componentId: "sc-wmpr1o-
|
|
46007
|
+
componentId: "sc-wmpr1o-4"
|
|
45929
46008
|
})(["display:flex;flex-direction:row;align-items:center;gap:0.5rem;margin-top:0.2rem;"]);
|
|
45930
46009
|
var GoldPriceRow$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
45931
46010
|
displayName: "MarketplaceRows__GoldPriceRow",
|
|
45932
|
-
componentId: "sc-wmpr1o-
|
|
46011
|
+
componentId: "sc-wmpr1o-5"
|
|
45933
46012
|
})(["display:flex;align-items:center;gap:0.3rem;"]);
|
|
45934
46013
|
var GoldIcon$1 = /*#__PURE__*/styled__default.span.withConfig({
|
|
45935
46014
|
displayName: "MarketplaceRows__GoldIcon",
|
|
45936
|
-
componentId: "sc-wmpr1o-
|
|
46015
|
+
componentId: "sc-wmpr1o-6"
|
|
45937
46016
|
})(["display:flex;align-items:center;justify-content:center;position:relative;top:-0.6rem;left:-0.5rem;"]);
|
|
45938
46017
|
var GoldPrice$1 = /*#__PURE__*/styled__default.span.withConfig({
|
|
45939
46018
|
displayName: "MarketplaceRows__GoldPrice",
|
|
45940
|
-
componentId: "sc-wmpr1o-
|
|
46019
|
+
componentId: "sc-wmpr1o-7"
|
|
45941
46020
|
})(["font-family:'Press Start 2P',cursive;font-size:0.6rem !important;color:#fef08a;line-height:1;"]);
|
|
45942
46021
|
var DCPriceRow = /*#__PURE__*/styled__default.div.withConfig({
|
|
45943
46022
|
displayName: "MarketplaceRows__DCPriceRow",
|
|
45944
|
-
componentId: "sc-wmpr1o-
|
|
45945
|
-
})(["display:flex;align-items:center;gap:0.3rem;margin-left:0.5rem;cursor:", ";border-radius:4px;transition:opacity 0.15s;&:hover{opacity:", ";}"], function (
|
|
45946
|
-
var $clickable =
|
|
46023
|
+
componentId: "sc-wmpr1o-8"
|
|
46024
|
+
})(["display:flex;align-items:center;gap:0.3rem;margin-left:0.5rem;cursor:", ";border-radius:4px;transition:opacity 0.15s;&:hover{opacity:", ";}"], function (_ref3) {
|
|
46025
|
+
var $clickable = _ref3.$clickable;
|
|
45947
46026
|
return $clickable ? 'pointer' : 'default';
|
|
45948
|
-
}, function (
|
|
45949
|
-
var $clickable =
|
|
46027
|
+
}, function (_ref4) {
|
|
46028
|
+
var $clickable = _ref4.$clickable;
|
|
45950
46029
|
return $clickable ? '0.75' : '1';
|
|
45951
46030
|
});
|
|
45952
46031
|
var DCCoinWrapper = /*#__PURE__*/styled__default.span.withConfig({
|
|
45953
46032
|
displayName: "MarketplaceRows__DCCoinWrapper",
|
|
45954
|
-
componentId: "sc-wmpr1o-
|
|
46033
|
+
componentId: "sc-wmpr1o-9"
|
|
45955
46034
|
})(["display:flex;align-items:center;justify-content:center;position:relative;top:-0.6rem;left:-0.5rem;"]);
|
|
45956
46035
|
var DCPrice = /*#__PURE__*/styled__default.span.withConfig({
|
|
45957
46036
|
displayName: "MarketplaceRows__DCPrice",
|
|
45958
|
-
componentId: "sc-wmpr1o-
|
|
46037
|
+
componentId: "sc-wmpr1o-10"
|
|
45959
46038
|
})(["font-family:'Press Start 2P',cursive;font-size:0.6rem !important;color:rgba(254,240,138,0.65);white-space:nowrap;"]);
|
|
45960
46039
|
var ActionSection$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
45961
46040
|
displayName: "MarketplaceRows__ActionSection",
|
|
45962
|
-
componentId: "sc-wmpr1o-
|
|
46041
|
+
componentId: "sc-wmpr1o-11"
|
|
45963
46042
|
})(["flex-shrink:0;margin-left:0.75rem;"]);
|
|
45964
46043
|
var QuantityContainer = /*#__PURE__*/styled__default.p.withConfig({
|
|
45965
46044
|
displayName: "MarketplaceRows__QuantityContainer",
|
|
45966
|
-
componentId: "sc-wmpr1o-
|
|
46045
|
+
componentId: "sc-wmpr1o-12"
|
|
45967
46046
|
})(["position:absolute;display:block;top:15px;left:-8px;font-size:", " !important;"], uiFonts.size.xsmall);
|
|
45968
46047
|
var GemContainer = /*#__PURE__*/styled__default.p.withConfig({
|
|
45969
46048
|
displayName: "MarketplaceRows__GemContainer",
|
|
45970
|
-
componentId: "sc-wmpr1o-
|
|
46049
|
+
componentId: "sc-wmpr1o-13"
|
|
45971
46050
|
})(["position:absolute;display:block;top:-5px;left:-10px;font-size:", " !important;"], uiFonts.size.xsmall);
|
|
45972
46051
|
var RarityContainer$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
45973
46052
|
displayName: "MarketplaceRows__RarityContainer",
|
|
45974
|
-
componentId: "sc-wmpr1o-
|
|
45975
|
-
})(["border-color:", ";box-shadow:", " inset,", ";width:32px;height:32px;"], function (
|
|
45976
|
-
var item =
|
|
46053
|
+
componentId: "sc-wmpr1o-14"
|
|
46054
|
+
})(["border-color:", ";box-shadow:", " inset,", ";width:32px;height:32px;"], function (_ref5) {
|
|
46055
|
+
var item = _ref5.item;
|
|
45977
46056
|
return rarityColor(item);
|
|
45978
|
-
}, function (
|
|
45979
|
-
var item =
|
|
46057
|
+
}, function (_ref6) {
|
|
46058
|
+
var item = _ref6.item;
|
|
45980
46059
|
return "0 0 5px 8px " + rarityColor(item);
|
|
45981
|
-
}, function (
|
|
45982
|
-
var item =
|
|
46060
|
+
}, function (_ref7) {
|
|
46061
|
+
var item = _ref7.item;
|
|
45983
46062
|
return "0 0 8px 6px " + rarityColor(item);
|
|
45984
46063
|
});
|
|
45985
46064
|
|
|
@@ -46148,9 +46227,34 @@ var BuyPanel = function BuyPanel(_ref) {
|
|
|
46148
46227
|
return true;
|
|
46149
46228
|
});
|
|
46150
46229
|
}, [name, openBuyOrders, price, selectedRarity]);
|
|
46230
|
+
var groupedBuyOrders = React.useMemo(function () {
|
|
46231
|
+
var groups = new Map();
|
|
46232
|
+
for (var _iterator2 = _createForOfIteratorHelperLoose(visibleBuyOrders), _step2; !(_step2 = _iterator2()).done;) {
|
|
46233
|
+
var order = _step2.value;
|
|
46234
|
+
var key = order.itemBlueprintKey;
|
|
46235
|
+
if (!groups.has(key)) groups.set(key, []);
|
|
46236
|
+
groups.get(key).push(order);
|
|
46237
|
+
}
|
|
46238
|
+
return Array.from(groups.values()).map(function (group) {
|
|
46239
|
+
var sorted = [].concat(group).sort(function (a, b) {
|
|
46240
|
+
return b.maxPrice - a.maxPrice;
|
|
46241
|
+
});
|
|
46242
|
+
return {
|
|
46243
|
+
bestOrder: sorted[0],
|
|
46244
|
+
otherOrders: sorted.slice(1)
|
|
46245
|
+
};
|
|
46246
|
+
}).sort(function (a, b) {
|
|
46247
|
+
var totalGold = function totalGold(g) {
|
|
46248
|
+
return [g.bestOrder].concat(g.otherOrders).reduce(function (sum, o) {
|
|
46249
|
+
return sum + o.maxPrice;
|
|
46250
|
+
}, 0);
|
|
46251
|
+
};
|
|
46252
|
+
return totalGold(b) - totalGold(a);
|
|
46253
|
+
});
|
|
46254
|
+
}, [visibleBuyOrders]);
|
|
46151
46255
|
var showSellSection = browseMode === 'sell';
|
|
46152
46256
|
var showBuySection = browseMode === 'buy';
|
|
46153
|
-
var hasVisibleContent = showSellSection && groupedItems.length > 0 || showBuySection &&
|
|
46257
|
+
var hasVisibleContent = showSellSection && groupedItems.length > 0 || showBuySection && groupedBuyOrders.length > 0;
|
|
46154
46258
|
return React__default.createElement(React__default.Fragment, null, buyingItemId && buyingItem && hasDCBalance && React__default.createElement(MarketplaceBuyModal, {
|
|
46155
46259
|
goldPrice: buyingItem.price,
|
|
46156
46260
|
dcEquivalentPrice: getDCEquivalentPrice(buyingItem.price),
|
|
@@ -46201,7 +46305,7 @@ var BuyPanel = function BuyPanel(_ref) {
|
|
|
46201
46305
|
onBlur: enableHotkeys,
|
|
46202
46306
|
onFocus: disableHotkeys,
|
|
46203
46307
|
className: "search-input"
|
|
46204
|
-
})), React__default.createElement(FilterButton$
|
|
46308
|
+
})), React__default.createElement(FilterButton$2, {
|
|
46205
46309
|
type: "button",
|
|
46206
46310
|
"$active": showFilters,
|
|
46207
46311
|
onClick: function onClick() {
|
|
@@ -46213,7 +46317,9 @@ var BuyPanel = function BuyPanel(_ref) {
|
|
|
46213
46317
|
height: 18
|
|
46214
46318
|
}))), showFilters && React__default.createElement(OptionsWrapper, {
|
|
46215
46319
|
showFilters: showFilters
|
|
46216
|
-
}, React__default.createElement(WrapperContainer$1,
|
|
46320
|
+
}, React__default.createElement(WrapperContainer$1, {
|
|
46321
|
+
"$sell": showSellSection
|
|
46322
|
+
}, showSellSection && React__default.createElement(StyledDropdown$5, {
|
|
46217
46323
|
options: itemTypeOptions,
|
|
46218
46324
|
onChange: onChangeType,
|
|
46219
46325
|
width: "100%"
|
|
@@ -46224,11 +46330,11 @@ var BuyPanel = function BuyPanel(_ref) {
|
|
|
46224
46330
|
onChangeRarity(value);
|
|
46225
46331
|
},
|
|
46226
46332
|
width: "100%"
|
|
46227
|
-
}), React__default.createElement(StyledDropdown$5, {
|
|
46333
|
+
}), showSellSection && React__default.createElement(StyledDropdown$5, {
|
|
46228
46334
|
options: orderByOptions,
|
|
46229
46335
|
onChange: onChangeOrder,
|
|
46230
46336
|
width: "100%"
|
|
46231
|
-
})), React__default.createElement(FilterInputsWrapper, null, React__default.createElement("div", null, React__default.createElement("p", null, "Main level"), React__default.createElement("div", {
|
|
46337
|
+
})), React__default.createElement(FilterInputsWrapper, null, showSellSection && React__default.createElement("div", null, React__default.createElement("p", null, "Main level"), React__default.createElement("div", {
|
|
46232
46338
|
className: "input-group"
|
|
46233
46339
|
}, React__default.createElement(Input, {
|
|
46234
46340
|
onChange: function onChange(e) {
|
|
@@ -46252,7 +46358,7 @@ var BuyPanel = function BuyPanel(_ref) {
|
|
|
46252
46358
|
min: 0,
|
|
46253
46359
|
onBlur: enableHotkeys,
|
|
46254
46360
|
onFocus: disableHotkeys
|
|
46255
|
-
}))), React__default.createElement("div", null, React__default.createElement("p", null, "Secondary level"), React__default.createElement("div", {
|
|
46361
|
+
}))), showSellSection && React__default.createElement("div", null, React__default.createElement("p", null, "Secondary level"), React__default.createElement("div", {
|
|
46256
46362
|
className: "input-group"
|
|
46257
46363
|
}, React__default.createElement(Input, {
|
|
46258
46364
|
onChange: function onChange(e) {
|
|
@@ -46319,14 +46425,16 @@ var BuyPanel = function BuyPanel(_ref) {
|
|
|
46319
46425
|
onBuy: setBuyingItemId,
|
|
46320
46426
|
onDCCoinClick: onDCCoinClick
|
|
46321
46427
|
});
|
|
46322
|
-
})), showBuySection && React__default.createElement(MarketSection, null, React__default.createElement(SectionHeader, null, React__default.createElement(SectionTitle$2, null, "Buy Requests"), React__default.createElement(SectionMeta, null,
|
|
46323
|
-
|
|
46324
|
-
|
|
46325
|
-
|
|
46428
|
+
})), showBuySection && React__default.createElement(MarketSection, null, React__default.createElement(SectionHeader, null, React__default.createElement(SectionTitle$2, null, "Buy Requests"), React__default.createElement(SectionMeta, null, groupedBuyOrders.length, " groups")), groupedBuyOrders.length === 0 ? React__default.createElement(SectionEmpty, null, "No public buy requests found.") : groupedBuyOrders.map(function (_ref3) {
|
|
46429
|
+
var bestOrder = _ref3.bestOrder,
|
|
46430
|
+
otherOrders = _ref3.otherOrders;
|
|
46431
|
+
return React__default.createElement(GroupedBuyOrderRow, {
|
|
46432
|
+
key: bestOrder._id,
|
|
46433
|
+
bestOrder: bestOrder,
|
|
46434
|
+
otherOrders: otherOrders,
|
|
46326
46435
|
atlasJSON: atlasJSON,
|
|
46327
46436
|
atlasIMG: atlasIMG,
|
|
46328
|
-
onFulfill: setFulfillingBuyOrderId
|
|
46329
|
-
showRequestTag: true
|
|
46437
|
+
onFulfill: setFulfillingBuyOrderId
|
|
46330
46438
|
});
|
|
46331
46439
|
})))), React__default.createElement(PagerFooter, null, showSellSection && totalItems > itemsPerPage && React__default.createElement(Pager, {
|
|
46332
46440
|
totalItems: totalItems,
|
|
@@ -46348,17 +46456,17 @@ var SearchField = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
46348
46456
|
displayName: "BuyPanel__SearchField",
|
|
46349
46457
|
componentId: "sc-1si8t7i-1"
|
|
46350
46458
|
})(["min-width:0;input.search-input{height:10px;width:100%;}"]);
|
|
46351
|
-
var FilterButton$
|
|
46459
|
+
var FilterButton$2 = /*#__PURE__*/styled__default.button.withConfig({
|
|
46352
46460
|
displayName: "BuyPanel__FilterButton",
|
|
46353
46461
|
componentId: "sc-1si8t7i-2"
|
|
46354
|
-
})(["width:36px;height:36px;border-radius:8px;border:1px solid ", ";background:", ";color:", ";cursor:pointer;display:flex;align-items:center;justify-content:center;transition:color 0.15s,border-color 0.15s,background 0.15s;&:hover{color:#f59e0b;border-color:rgba(245,158,11,0.45);}"], function (
|
|
46355
|
-
var $active = _ref3.$active;
|
|
46356
|
-
return $active ? 'rgba(245, 158, 11, 0.55)' : 'rgba(255, 255, 255, 0.08)';
|
|
46357
|
-
}, function (_ref4) {
|
|
46462
|
+
})(["width:36px;height:36px;border-radius:8px;border:1px solid ", ";background:", ";color:", ";cursor:pointer;display:flex;align-items:center;justify-content:center;transition:color 0.15s,border-color 0.15s,background 0.15s;&:hover{color:#f59e0b;border-color:rgba(245,158,11,0.45);}"], function (_ref4) {
|
|
46358
46463
|
var $active = _ref4.$active;
|
|
46359
|
-
return $active ? 'rgba(245, 158, 11, 0.
|
|
46464
|
+
return $active ? 'rgba(245, 158, 11, 0.55)' : 'rgba(255, 255, 255, 0.08)';
|
|
46360
46465
|
}, function (_ref5) {
|
|
46361
46466
|
var $active = _ref5.$active;
|
|
46467
|
+
return $active ? 'rgba(245, 158, 11, 0.14)' : 'rgba(255, 255, 255, 0.03)';
|
|
46468
|
+
}, function (_ref6) {
|
|
46469
|
+
var $active = _ref6.$active;
|
|
46362
46470
|
return $active ? '#f59e0b' : '#ccc';
|
|
46363
46471
|
});
|
|
46364
46472
|
var BrowseModeRow = /*#__PURE__*/styled__default.div.withConfig({
|
|
@@ -46368,18 +46476,21 @@ var BrowseModeRow = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
46368
46476
|
var OptionsWrapper = /*#__PURE__*/styled__default.div.withConfig({
|
|
46369
46477
|
displayName: "BuyPanel__OptionsWrapper",
|
|
46370
46478
|
componentId: "sc-1si8t7i-4"
|
|
46371
|
-
})(["width:95%;margin:0 auto;background:rgba(0,0,0,0.15);border-radius:4px;border:1px solid rgba(255,255,255,0.05);padding:10px;display:flex;flex-direction:column;gap:", ";"], function (
|
|
46372
|
-
var showFilters =
|
|
46479
|
+
})(["width:95%;margin:0 auto;background:rgba(0,0,0,0.15);border-radius:4px;border:1px solid rgba(255,255,255,0.05);padding:10px;display:flex;flex-direction:column;gap:", ";"], function (_ref7) {
|
|
46480
|
+
var showFilters = _ref7.showFilters;
|
|
46373
46481
|
return showFilters ? '15px' : '0';
|
|
46374
46482
|
});
|
|
46375
46483
|
var FilterInputsWrapper = /*#__PURE__*/styled__default.div.withConfig({
|
|
46376
46484
|
displayName: "BuyPanel__FilterInputsWrapper",
|
|
46377
46485
|
componentId: "sc-1si8t7i-5"
|
|
46378
|
-
})(["display:grid;grid-template-columns:repeat(
|
|
46486
|
+
})(["display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:15px;color:white;> div{display:flex;flex-direction:column;gap:5px;}p{margin:0;font-size:0.65rem;color:#aaa;text-transform:uppercase;letter-spacing:1px;}.input-group{display:flex;align-items:center;gap:5px;input{width:100%;height:10px;}}.separator-icon{flex-shrink:0;color:rgba(255,255,255,0.3);}"]);
|
|
46379
46487
|
var WrapperContainer$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
46380
46488
|
displayName: "BuyPanel__WrapperContainer",
|
|
46381
46489
|
componentId: "sc-1si8t7i-6"
|
|
46382
|
-
})(["display:grid;grid-template-columns:
|
|
46490
|
+
})(["display:grid;grid-template-columns:", ";gap:15px;.rpgui-content .rpgui-dropdown-imp-header{padding:0px 10px 0 !important;}"], function (_ref8) {
|
|
46491
|
+
var $sell = _ref8.$sell;
|
|
46492
|
+
return $sell ? 'repeat(3, 1fr)' : 'minmax(0, 200px)';
|
|
46493
|
+
});
|
|
46383
46494
|
var ItemComponentScrollWrapper$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
46384
46495
|
displayName: "BuyPanel__ItemComponentScrollWrapper",
|
|
46385
46496
|
componentId: "sc-1si8t7i-7"
|
|
@@ -46521,7 +46632,7 @@ var HistoryPanel = function HistoryPanel(_ref) {
|
|
|
46521
46632
|
}))), React__default.createElement(GoldAmount, {
|
|
46522
46633
|
"$type": tx.type
|
|
46523
46634
|
}, getGoldSign(tx.type), tx.goldAmount, "g"))));
|
|
46524
|
-
})), React__default.createElement(PagerContainer$
|
|
46635
|
+
})), React__default.createElement(PagerContainer$1, null, React__default.createElement(Pager, {
|
|
46525
46636
|
totalItems: totalCount,
|
|
46526
46637
|
currentPage: currentPage,
|
|
46527
46638
|
itemsPerPage: itemsPerPage,
|
|
@@ -46629,7 +46740,7 @@ var EmptyState$4 = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
46629
46740
|
displayName: "HistoryPanel__EmptyState",
|
|
46630
46741
|
componentId: "sc-74mioa-20"
|
|
46631
46742
|
})(["display:flex;align-items:center;justify-content:center;height:45px;font-size:0.5rem;color:#555;text-transform:uppercase;letter-spacing:1px;background:rgba(0,0,0,0.15);border-radius:4px;"]);
|
|
46632
|
-
var PagerContainer$
|
|
46743
|
+
var PagerContainer$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
46633
46744
|
displayName: "HistoryPanel__PagerContainer",
|
|
46634
46745
|
componentId: "sc-74mioa-21"
|
|
46635
46746
|
})(["display:flex;justify-content:center;margin-top:4px;"]);
|
|
@@ -47100,9 +47211,9 @@ var Marketplace = function Marketplace(props) {
|
|
|
47100
47211
|
}), activeTab === 'wallet' && showWalletTab && walletProps && React__default.createElement(DCWalletContent, Object.assign({}, walletProps)), activeTab === 'settings' && React__default.createElement(MarketplaceSettingsPanel, {
|
|
47101
47212
|
acceptedCurrency: acceptedCurrency,
|
|
47102
47213
|
onAcceptedCurrencyChange: handleCurrencyChange
|
|
47103
|
-
}), showSharedPager && React__default.createElement(PagerContainer$
|
|
47214
|
+
}), showSharedPager && React__default.createElement(PagerContainer$2, null, React__default.createElement(Pager, Object.assign({}, props))));
|
|
47104
47215
|
};
|
|
47105
|
-
var PagerContainer$
|
|
47216
|
+
var PagerContainer$2 = /*#__PURE__*/styled__default.div.withConfig({
|
|
47106
47217
|
displayName: "Marketplace__PagerContainer",
|
|
47107
47218
|
componentId: "sc-h904b1-0"
|
|
47108
47219
|
})(["display:flex;justify-content:center;align-items:center;width:95%;margin:6px auto 0 auto;padding:4px 10px;"]);
|
|
@@ -70108,9 +70219,9 @@ var StoreItemRow = function StoreItemRow(_ref) {
|
|
|
70108
70219
|
resetQuantity();
|
|
70109
70220
|
}
|
|
70110
70221
|
};
|
|
70111
|
-
return React__default.createElement(
|
|
70222
|
+
return React__default.createElement(ItemRowWrapper, {
|
|
70112
70223
|
"$isHighlighted": ((_item$store = item.store) == null ? void 0 : _item$store.isHighlighted) || false
|
|
70113
|
-
}, React__default.createElement(ItemIconContainer$2, null, React__default.createElement(SpriteFromAtlas, {
|
|
70224
|
+
}, React__default.createElement(LeftSection, null, React__default.createElement(ItemIconContainer$2, null, React__default.createElement(SpriteFromAtlas, {
|
|
70114
70225
|
atlasJSON: atlasJSON,
|
|
70115
70226
|
atlasIMG: atlasIMG,
|
|
70116
70227
|
spriteKey: item.texturePath,
|
|
@@ -70118,7 +70229,7 @@ var StoreItemRow = function StoreItemRow(_ref) {
|
|
|
70118
70229
|
height: 32,
|
|
70119
70230
|
imgScale: 2,
|
|
70120
70231
|
centered: true
|
|
70121
|
-
})), React__default.createElement(ItemDetails$5, null, React__default.createElement(ItemName$6, null, item.name), React__default.createElement(ItemPrice$1, null, "$", item.price, item.dcPrice ? " \xB7 " + item.dcPrice.toLocaleString() + " DC" : ''), React__default.createElement(ItemDescription, null, item.description)), React__default.createElement(Controls$1, null, showTextInput ? React__default.createElement(TextInput, {
|
|
70232
|
+
})), React__default.createElement(ItemDetails$5, null, React__default.createElement(ItemName$6, null, item.name), React__default.createElement(ItemPrice$1, null, "$", item.price, item.dcPrice ? " \xB7 " + item.dcPrice.toLocaleString() + " DC" : ''), React__default.createElement(ItemDescription, null, item.description))), React__default.createElement(Controls$1, null, showTextInput ? React__default.createElement(TextInput, {
|
|
70122
70233
|
type: "text",
|
|
70123
70234
|
value: textInputValue,
|
|
70124
70235
|
placeholder: textInputPlaceholder,
|
|
@@ -70149,14 +70260,10 @@ var StoreItemRow = function StoreItemRow(_ref) {
|
|
|
70149
70260
|
disabled: !hasRequiredAccount
|
|
70150
70261
|
})));
|
|
70151
70262
|
};
|
|
70152
|
-
var
|
|
70153
|
-
displayName: "
|
|
70263
|
+
var LeftSection = /*#__PURE__*/styled__default.div.withConfig({
|
|
70264
|
+
displayName: "StoreItemRow__LeftSection",
|
|
70154
70265
|
componentId: "sc-ptotuo-0"
|
|
70155
|
-
})(["display:flex;align-items:center;gap:0.75rem;
|
|
70156
|
-
return props.$isHighlighted ? 'rgba(255, 215, 0, 0.1)' : 'transparent';
|
|
70157
|
-
}, function (props) {
|
|
70158
|
-
return props.$isHighlighted ? '3px solid #ffd700' : '3px solid transparent';
|
|
70159
|
-
});
|
|
70266
|
+
})(["display:flex;align-items:center;gap:0.75rem;flex:1;min-width:0;"]);
|
|
70160
70267
|
var ItemIconContainer$2 = /*#__PURE__*/styled__default.div.withConfig({
|
|
70161
70268
|
displayName: "StoreItemRow__ItemIconContainer",
|
|
70162
70269
|
componentId: "sc-ptotuo-1"
|
|
@@ -70249,6 +70356,7 @@ var StoreItemsSection = function StoreItemsSection(_ref) {
|
|
|
70249
70356
|
var _useStoreFiltering = useStoreFiltering(items),
|
|
70250
70357
|
searchQuery = _useStoreFiltering.searchQuery,
|
|
70251
70358
|
setSearchQuery = _useStoreFiltering.setSearchQuery,
|
|
70359
|
+
selectedCategory = _useStoreFiltering.selectedCategory,
|
|
70252
70360
|
setSelectedCategory = _useStoreFiltering.setSelectedCategory,
|
|
70253
70361
|
categoryOptions = _useStoreFiltering.categoryOptions,
|
|
70254
70362
|
filteredItems = _useStoreFiltering.filteredItems;
|
|
@@ -70290,13 +70398,18 @@ var StoreItemsSection = function StoreItemsSection(_ref) {
|
|
|
70290
70398
|
value: searchQuery,
|
|
70291
70399
|
onChange: setSearchQuery,
|
|
70292
70400
|
placeholder: "Search items..."
|
|
70293
|
-
})), React__default.createElement(
|
|
70294
|
-
options: categoryOptions
|
|
70295
|
-
|
|
70296
|
-
|
|
70297
|
-
|
|
70298
|
-
|
|
70299
|
-
|
|
70401
|
+
})), React__default.createElement(SegmentedToggle, {
|
|
70402
|
+
options: categoryOptions.map(function (opt) {
|
|
70403
|
+
return {
|
|
70404
|
+
id: opt.value,
|
|
70405
|
+
label: opt.option
|
|
70406
|
+
};
|
|
70407
|
+
}),
|
|
70408
|
+
activeId: selectedCategory,
|
|
70409
|
+
onChange: function onChange(id) {
|
|
70410
|
+
return setSelectedCategory(id);
|
|
70411
|
+
}
|
|
70412
|
+
})), React__default.createElement(ScrollableContent, {
|
|
70300
70413
|
items: filteredItems,
|
|
70301
70414
|
renderItem: renderStoreItem,
|
|
70302
70415
|
emptyMessage: "No items match your filters.",
|
|
@@ -70316,10 +70429,6 @@ var SearchBarContainer$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
70316
70429
|
displayName: "StoreItemsSection__SearchBarContainer",
|
|
70317
70430
|
componentId: "sc-l6f466-2"
|
|
70318
70431
|
})(["flex:0.75;"]);
|
|
70319
|
-
var DropdownContainer$2 = /*#__PURE__*/styled__default.div.withConfig({
|
|
70320
|
-
displayName: "StoreItemsSection__DropdownContainer",
|
|
70321
|
-
componentId: "sc-l6f466-3"
|
|
70322
|
-
})(["flex:0.25;min-width:140px;"]);
|
|
70323
70432
|
|
|
70324
70433
|
var usePackFiltering = function usePackFiltering(packs) {
|
|
70325
70434
|
var _useState = React.useState(''),
|
|
@@ -70376,7 +70485,7 @@ var StorePacksSection = function StorePacksSection(_ref) {
|
|
|
70376
70485
|
onClick: function onClick() {
|
|
70377
70486
|
return onSelectPack == null ? void 0 : onSelectPack(pack);
|
|
70378
70487
|
}
|
|
70379
|
-
}, React__default.createElement(PackIconContainer, null, renderPackIcon(pack)), React__default.createElement(PackDetails, null, React__default.createElement(PackName, null, pack.title), React__default.createElement(PackPrice, null, "$", pack.priceUSD), pack.description && React__default.createElement(PackDescription, null, pack.description)), React__default.createElement(Controls$2, null, React__default.createElement(CTAButton, {
|
|
70488
|
+
}, React__default.createElement(LeftSection$1, null, React__default.createElement(PackIconContainer, null, renderPackIcon(pack)), React__default.createElement(PackDetails, null, React__default.createElement(PackName, null, pack.title), React__default.createElement(PackPrice, null, "$", pack.priceUSD), pack.description && React__default.createElement(PackDescription, null, pack.description))), React__default.createElement(Controls$2, null, React__default.createElement(CTAButton, {
|
|
70380
70489
|
icon: React__default.createElement(fa.FaCartPlus, null),
|
|
70381
70490
|
label: "Add",
|
|
70382
70491
|
onClick: function onClick(e) {
|
|
@@ -70398,33 +70507,37 @@ var StorePacksSection = function StorePacksSection(_ref) {
|
|
|
70398
70507
|
maxHeight: "420px"
|
|
70399
70508
|
});
|
|
70400
70509
|
};
|
|
70401
|
-
var PackRow = /*#__PURE__*/styled__default.
|
|
70510
|
+
var PackRow = /*#__PURE__*/styled__default(ItemRowWrapper).withConfig({
|
|
70402
70511
|
displayName: "StorePacksSection__PackRow",
|
|
70403
70512
|
componentId: "sc-ulazq3-0"
|
|
70404
|
-
})(["
|
|
70513
|
+
})(["cursor:pointer;"]);
|
|
70514
|
+
var LeftSection$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
70515
|
+
displayName: "StorePacksSection__LeftSection",
|
|
70516
|
+
componentId: "sc-ulazq3-1"
|
|
70517
|
+
})(["display:flex;align-items:center;gap:0.75rem;flex:1;min-width:0;"]);
|
|
70405
70518
|
var PackIconContainer = /*#__PURE__*/styled__default.div.withConfig({
|
|
70406
70519
|
displayName: "StorePacksSection__PackIconContainer",
|
|
70407
|
-
componentId: "sc-ulazq3-
|
|
70520
|
+
componentId: "sc-ulazq3-2"
|
|
70408
70521
|
})(["width:40px;height:40px;flex-shrink:0;display:flex;align-items:center;justify-content:center;img{width:100%;height:100%;object-fit:cover;}"]);
|
|
70409
70522
|
var PackDetails = /*#__PURE__*/styled__default.div.withConfig({
|
|
70410
70523
|
displayName: "StorePacksSection__PackDetails",
|
|
70411
|
-
componentId: "sc-ulazq3-
|
|
70524
|
+
componentId: "sc-ulazq3-3"
|
|
70412
70525
|
})(["flex:1;display:flex;flex-direction:column;gap:0.25rem;min-width:0;"]);
|
|
70413
70526
|
var PackName = /*#__PURE__*/styled__default.div.withConfig({
|
|
70414
70527
|
displayName: "StorePacksSection__PackName",
|
|
70415
|
-
componentId: "sc-ulazq3-
|
|
70528
|
+
componentId: "sc-ulazq3-4"
|
|
70416
70529
|
})(["font-family:'Press Start 2P',cursive;font-size:0.75rem;color:#ffffff;"]);
|
|
70417
70530
|
var PackPrice = /*#__PURE__*/styled__default.div.withConfig({
|
|
70418
70531
|
displayName: "StorePacksSection__PackPrice",
|
|
70419
|
-
componentId: "sc-ulazq3-
|
|
70532
|
+
componentId: "sc-ulazq3-5"
|
|
70420
70533
|
})(["font-family:'Press Start 2P',cursive;font-size:0.625rem;color:#fef08a;"]);
|
|
70421
70534
|
var PackDescription = /*#__PURE__*/styled__default.div.withConfig({
|
|
70422
70535
|
displayName: "StorePacksSection__PackDescription",
|
|
70423
|
-
componentId: "sc-ulazq3-
|
|
70536
|
+
componentId: "sc-ulazq3-6"
|
|
70424
70537
|
})(["font-family:'Press Start 2P',cursive;font-size:0.625rem;color:rgba(255,255,255,0.7);line-height:1.4;"]);
|
|
70425
70538
|
var Controls$2 = /*#__PURE__*/styled__default.div.withConfig({
|
|
70426
70539
|
displayName: "StorePacksSection__Controls",
|
|
70427
|
-
componentId: "sc-ulazq3-
|
|
70540
|
+
componentId: "sc-ulazq3-7"
|
|
70428
70541
|
})(["display:flex;align-items:center;flex-shrink:0;"]);
|
|
70429
70542
|
|
|
70430
70543
|
var StoreItemDetails = function StoreItemDetails(_ref) {
|
|
@@ -70497,6 +70610,7 @@ var Actions = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
70497
70610
|
})(["margin-top:auto;padding-top:1rem;border-top:1px solid rgba(255,255,255,0.1);"]);
|
|
70498
70611
|
|
|
70499
70612
|
var Store = function Store(_ref) {
|
|
70613
|
+
var _tabsMap$activeTab;
|
|
70500
70614
|
var items = _ref.items,
|
|
70501
70615
|
_ref$packs = _ref.packs,
|
|
70502
70616
|
packs = _ref$packs === void 0 ? [] : _ref$packs,
|
|
@@ -70634,6 +70748,10 @@ var Store = function Store(_ref) {
|
|
|
70634
70748
|
premium: {
|
|
70635
70749
|
id: 'premium',
|
|
70636
70750
|
title: 'Premium',
|
|
70751
|
+
icon: React__default.createElement(Crown.Crown, {
|
|
70752
|
+
width: 18,
|
|
70753
|
+
height: 18
|
|
70754
|
+
}),
|
|
70637
70755
|
content: React__default.createElement(StorePacksSection, {
|
|
70638
70756
|
packs: packs.filter(function (pack) {
|
|
70639
70757
|
return pack.priceUSD >= 9.99;
|
|
@@ -70647,6 +70765,10 @@ var Store = function Store(_ref) {
|
|
|
70647
70765
|
packs: {
|
|
70648
70766
|
id: 'packs',
|
|
70649
70767
|
title: packsTabLabel,
|
|
70768
|
+
icon: React__default.createElement(Gift.Gift, {
|
|
70769
|
+
width: 18,
|
|
70770
|
+
height: 18
|
|
70771
|
+
}),
|
|
70650
70772
|
content: customPacksContent != null ? customPacksContent : React__default.createElement(StorePacksSection, {
|
|
70651
70773
|
packs: hidePremiumTab ? packs : packs.filter(function (pack) {
|
|
70652
70774
|
return pack.priceUSD < 9.99;
|
|
@@ -70660,6 +70782,10 @@ var Store = function Store(_ref) {
|
|
|
70660
70782
|
items: {
|
|
70661
70783
|
id: 'items',
|
|
70662
70784
|
title: 'Items',
|
|
70785
|
+
icon: React__default.createElement(Box.Box, {
|
|
70786
|
+
width: 18,
|
|
70787
|
+
height: 18
|
|
70788
|
+
}),
|
|
70663
70789
|
content: React__default.createElement(StoreItemsSection, {
|
|
70664
70790
|
items: filteredItems.items,
|
|
70665
70791
|
onAddToCart: handleAddToCart,
|
|
@@ -70672,12 +70798,13 @@ var Store = function Store(_ref) {
|
|
|
70672
70798
|
wallet: {
|
|
70673
70799
|
id: 'wallet',
|
|
70674
70800
|
title: 'Wallet',
|
|
70801
|
+
icon: React__default.createElement(Wallet.Wallet, {
|
|
70802
|
+
width: 18,
|
|
70803
|
+
height: 18
|
|
70804
|
+
}),
|
|
70675
70805
|
content: customWalletContent != null ? customWalletContent : null
|
|
70676
70806
|
}
|
|
70677
70807
|
};
|
|
70678
|
-
var tabs = availableTabIds.map(function (id) {
|
|
70679
|
-
return tabsMap[id];
|
|
70680
|
-
});
|
|
70681
70808
|
return React__default.createElement(DraggableContainer, {
|
|
70682
70809
|
title: "Store",
|
|
70683
70810
|
onCloseButton: onClose,
|
|
@@ -70740,18 +70867,19 @@ var Store = function Store(_ref) {
|
|
|
70740
70867
|
icon: React__default.createElement(fa.FaShoppingCart, null),
|
|
70741
70868
|
label: getTotalItems() + " items ($" + getTotalPrice().toFixed(2) + ")",
|
|
70742
70869
|
onClick: openCart
|
|
70743
|
-
}))), React__default.createElement(MainContent$1, null, React__default.createElement(
|
|
70744
|
-
|
|
70745
|
-
|
|
70746
|
-
|
|
70747
|
-
|
|
70748
|
-
|
|
70749
|
-
|
|
70750
|
-
|
|
70870
|
+
}))), React__default.createElement(MainContent$1, null, React__default.createElement(Tabs, {
|
|
70871
|
+
options: availableTabIds.map(function (id) {
|
|
70872
|
+
return {
|
|
70873
|
+
id: id,
|
|
70874
|
+
label: tabsMap[id].title,
|
|
70875
|
+
icon: tabsMap[id].icon
|
|
70876
|
+
};
|
|
70877
|
+
}),
|
|
70878
|
+
activeTabId: activeTab,
|
|
70751
70879
|
onTabChange: function onTabChange(tabId) {
|
|
70752
70880
|
return setActiveTab(tabId);
|
|
70753
70881
|
}
|
|
70754
|
-
})), cartItems.length > 0 && React__default.createElement(Footer$2, null, React__default.createElement(CartSummary, null, React__default.createElement(CartInfo, null, React__default.createElement("span", null, "Items in cart:"), React__default.createElement("span", null, getTotalItems())), React__default.createElement(CartInfo, null, React__default.createElement("span", null, "Total:"), React__default.createElement("span", null, "$", getTotalPrice().toFixed(2)))), React__default.createElement(CTAButton, {
|
|
70882
|
+
}), React__default.createElement(TabContent, null, (_tabsMap$activeTab = tabsMap[activeTab]) == null ? void 0 : _tabsMap$activeTab.content)), cartItems.length > 0 && React__default.createElement(Footer$2, null, React__default.createElement(CartSummary, null, React__default.createElement(CartInfo, null, React__default.createElement("span", null, "Items in cart:"), React__default.createElement("span", null, getTotalItems())), React__default.createElement(CartInfo, null, React__default.createElement("span", null, "Total:"), React__default.createElement("span", null, "$", getTotalPrice().toFixed(2)))), React__default.createElement(CTAButton, {
|
|
70755
70883
|
icon: React__default.createElement(fa.FaShoppingCart, null),
|
|
70756
70884
|
label: "Proceed to Checkout ($" + getTotalPrice().toFixed(2) + ")",
|
|
70757
70885
|
onClick: openCart,
|
|
@@ -70777,26 +70905,30 @@ var CartButton = /*#__PURE__*/styled__default.div.withConfig({
|
|
|
70777
70905
|
var MainContent$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
70778
70906
|
displayName: "Store__MainContent",
|
|
70779
70907
|
componentId: "sc-64dj00-4"
|
|
70780
|
-
})(["flex:1;display:flex;flex-direction:column;min-height:0;overflow:hidden
|
|
70908
|
+
})(["flex:1;display:flex;flex-direction:column;min-height:0;overflow:hidden;"]);
|
|
70909
|
+
var TabContent = /*#__PURE__*/styled__default.div.withConfig({
|
|
70910
|
+
displayName: "Store__TabContent",
|
|
70911
|
+
componentId: "sc-64dj00-5"
|
|
70912
|
+
})(["flex:1;overflow-y:auto;padding-right:0.5rem;"]);
|
|
70781
70913
|
var Footer$2 = /*#__PURE__*/styled__default.div.withConfig({
|
|
70782
70914
|
displayName: "Store__Footer",
|
|
70783
|
-
componentId: "sc-64dj00-
|
|
70915
|
+
componentId: "sc-64dj00-6"
|
|
70784
70916
|
})(["display:flex;flex-direction:column;gap:1rem;padding:1rem;border-top:2px solid #f59e0b;background:rgba(0,0,0,0.2);flex-shrink:0;"]);
|
|
70785
70917
|
var CartSummary = /*#__PURE__*/styled__default.div.withConfig({
|
|
70786
70918
|
displayName: "Store__CartSummary",
|
|
70787
|
-
componentId: "sc-64dj00-
|
|
70919
|
+
componentId: "sc-64dj00-7"
|
|
70788
70920
|
})(["display:flex;flex-direction:column;gap:0.5rem;"]);
|
|
70789
70921
|
var CartInfo = /*#__PURE__*/styled__default.div.withConfig({
|
|
70790
70922
|
displayName: "Store__CartInfo",
|
|
70791
|
-
componentId: "sc-64dj00-
|
|
70923
|
+
componentId: "sc-64dj00-8"
|
|
70792
70924
|
})(["display:flex;align-items:center;gap:0.75rem;font-family:'Press Start 2P',cursive;font-size:0.75rem;color:#ffffff;span:last-child{color:#fef08a;}"]);
|
|
70793
70925
|
var LoadingMessage$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
70794
70926
|
displayName: "Store__LoadingMessage",
|
|
70795
|
-
componentId: "sc-64dj00-
|
|
70927
|
+
componentId: "sc-64dj00-9"
|
|
70796
70928
|
})(["text-align:center;color:", ";padding:2rem;"], uiColors.white);
|
|
70797
70929
|
var ErrorMessage$3 = /*#__PURE__*/styled__default.div.withConfig({
|
|
70798
70930
|
displayName: "Store__ErrorMessage",
|
|
70799
|
-
componentId: "sc-64dj00-
|
|
70931
|
+
componentId: "sc-64dj00-10"
|
|
70800
70932
|
})(["text-align:center;color:", ";padding:2rem;"], uiColors.red);
|
|
70801
70933
|
|
|
70802
70934
|
var PaymentMethodModal = function PaymentMethodModal(_ref) {
|
|
@@ -71088,7 +71220,7 @@ var TradingItemRow = function TradingItemRow(_ref) {
|
|
|
71088
71220
|
}
|
|
71089
71221
|
return null;
|
|
71090
71222
|
};
|
|
71091
|
-
return React__default.createElement(ItemWrapper$
|
|
71223
|
+
return React__default.createElement(ItemWrapper$1, null, React__default.createElement(ItemIconContainer$3, null, React__default.createElement(SpriteContainer$6, null, React__default.createElement(ItemInfoWrapper, {
|
|
71092
71224
|
atlasIMG: atlasIMG,
|
|
71093
71225
|
atlasJSON: atlasJSON,
|
|
71094
71226
|
equipmentSet: equipmentSet,
|
|
@@ -71148,7 +71280,7 @@ var StyledArrow = /*#__PURE__*/styled__default(SelectArrow).withConfig({
|
|
|
71148
71280
|
displayName: "TradingItemRow__StyledArrow",
|
|
71149
71281
|
componentId: "sc-mja0b5-0"
|
|
71150
71282
|
})(["margin:0 1.5rem;"]);
|
|
71151
|
-
var ItemWrapper$
|
|
71283
|
+
var ItemWrapper$1 = /*#__PURE__*/styled__default.div.withConfig({
|
|
71152
71284
|
displayName: "TradingItemRow__ItemWrapper",
|
|
71153
71285
|
componentId: "sc-mja0b5-1"
|
|
71154
71286
|
})(["width:100%;display:flex;justify-content:space-between;margin-bottom:0.5rem;padding:0.25rem;&:hover{background-color:", ";}"], uiColors.darkGray);
|
|
@@ -71507,6 +71639,7 @@ exports.EquipmentSlotSpriteByType = EquipmentSlotSpriteByType;
|
|
|
71507
71639
|
exports.ErrorBoundary = ErrorBoundary;
|
|
71508
71640
|
exports.FriendList = FriendList;
|
|
71509
71641
|
exports.GemSelector = GemSelector;
|
|
71642
|
+
exports.GroupedBuyOrderRow = GroupedBuyOrderRow;
|
|
71510
71643
|
exports.GroupedMarketplaceRow = GroupedMarketplaceRow;
|
|
71511
71644
|
exports.HISTORY_ITEMS_PER_PAGE = HISTORY_ITEMS_PER_PAGE;
|
|
71512
71645
|
exports.HistoryDialog = HistoryDialog;
|