@rpg-engine/long-bow 0.5.65 → 0.5.67
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/AsyncDropdown.d.ts +13 -0
- package/dist/components/Dropdown.d.ts +0 -2
- package/dist/components/ImageCarousel/SimpleImageCarousel.d.ts +2 -3
- package/dist/index.d.ts +1 -0
- package/dist/long-bow.cjs.development.js +222 -142
- 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 +223 -144
- package/dist/long-bow.esm.js.map +1 -1
- package/package.json +3 -2
- package/src/assets/images/backpack.png +0 -0
- package/src/assets/images/depot.png +0 -0
- package/src/components/AsyncDropdown.tsx +127 -0
- package/src/components/Dropdown.tsx +2 -18
- package/src/components/ImageCarousel/SimpleImageCarousel.tsx +33 -40
- package/src/index.tsx +1 -0
- package/src/stories/Dropdown.stories.tsx +2 -2
- package/src/stories/SimpleImageCarousel.stories.tsx +3 -2
package/dist/long-bow.esm.js
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import React, {
|
|
1
|
+
import React, { useState, useEffect, Component, useRef, useContext, createContext, useMemo, useCallback, Fragment } from 'react';
|
|
2
|
+
import { BeatLoader } from 'react-spinners';
|
|
2
3
|
import styled, { keyframes } from 'styled-components';
|
|
4
|
+
import { v4 } from 'uuid';
|
|
3
5
|
import { GRID_WIDTH, GRID_HEIGHT, ShortcutType, getItemTextureKeyPath, ItemRarities, ItemContainerType, ItemType, DepotSocketEvents, ItemSocketEvents, ItemSocketEventsDisplayLabels, ActionsForInventory, ActionsForEquipmentSet, ActionsForLoot, ActionsForMapContainer, ItemSubType, ItemSlotType, isMobileOrTablet, CharacterClass, getSPForLevel, getXPForLevel, PeriodOfDay, UserAccountTypes } from '@rpg-engine/shared';
|
|
4
6
|
import dayjs from 'dayjs';
|
|
5
7
|
import { ErrorBoundary as ErrorBoundary$1 } from 'react-error-boundary';
|
|
@@ -8,12 +10,125 @@ import Draggable from 'react-draggable';
|
|
|
8
10
|
import ReactDOM from 'react-dom';
|
|
9
11
|
import { camelCase } from 'lodash-es';
|
|
10
12
|
import { observer } from 'mobx-react-lite';
|
|
11
|
-
import { v4 } from 'uuid';
|
|
12
13
|
import { AiFillCaretRight } from 'react-icons/ai';
|
|
13
14
|
import 'rpgui/rpgui.css';
|
|
14
15
|
import 'rpgui/rpgui.min.js';
|
|
15
16
|
import capitalize from 'lodash-es/capitalize';
|
|
16
17
|
|
|
18
|
+
var uiColors = {
|
|
19
|
+
lightGray: '#888',
|
|
20
|
+
gray: '#4E4A4E',
|
|
21
|
+
darkGray: '#3e3e3e',
|
|
22
|
+
darkYellow: '#FFC857',
|
|
23
|
+
yellow: '#FFFF00',
|
|
24
|
+
orange: '#D27D2C',
|
|
25
|
+
cardinal: '#C5283D',
|
|
26
|
+
red: '#D04648',
|
|
27
|
+
darkRed: '#442434',
|
|
28
|
+
raisinBlack: '#191923',
|
|
29
|
+
navyBlue: '#0E79B2',
|
|
30
|
+
purple: '#6833A3',
|
|
31
|
+
darkPurple: '#522761',
|
|
32
|
+
blue: '#597DCE',
|
|
33
|
+
darkBlue: '#30346D',
|
|
34
|
+
brown: '#854C30',
|
|
35
|
+
lightGreen: '#66cd1c',
|
|
36
|
+
brownGreen: '#346524',
|
|
37
|
+
white: '#fff'
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
var AsyncDropdown = function AsyncDropdown(_ref) {
|
|
41
|
+
var _options$, _options$find, _options$2;
|
|
42
|
+
var options = _ref.options,
|
|
43
|
+
width = _ref.width,
|
|
44
|
+
onChange = _ref.onChange,
|
|
45
|
+
defaultValue = _ref.defaultValue;
|
|
46
|
+
var dropdownId = v4();
|
|
47
|
+
var _useState = useState(defaultValue || (options == null ? void 0 : (_options$ = options[0]) == null ? void 0 : _options$.value)),
|
|
48
|
+
selectedValue = _useState[0],
|
|
49
|
+
setSelectedValue = _useState[1];
|
|
50
|
+
var _useState2 = useState((options == null ? void 0 : (_options$find = options.find(function (option) {
|
|
51
|
+
return option.value === defaultValue;
|
|
52
|
+
})) == null ? void 0 : _options$find.option) || (options == null ? void 0 : (_options$2 = options[0]) == null ? void 0 : _options$2.option)),
|
|
53
|
+
selectedOption = _useState2[0],
|
|
54
|
+
setSelectedOption = _useState2[1];
|
|
55
|
+
var _useState3 = useState(false),
|
|
56
|
+
opened = _useState3[0],
|
|
57
|
+
setOpened = _useState3[1];
|
|
58
|
+
useEffect(function () {
|
|
59
|
+
if (defaultValue) {
|
|
60
|
+
var _options$find2;
|
|
61
|
+
setSelectedValue(defaultValue);
|
|
62
|
+
setSelectedOption( //@ts-ignore
|
|
63
|
+
options == null ? void 0 : (_options$find2 = options.find(function (option) {
|
|
64
|
+
return option.value === defaultValue;
|
|
65
|
+
})) == null ? void 0 : _options$find2.option);
|
|
66
|
+
} else if ((options == null ? void 0 : options.length) > 0) {
|
|
67
|
+
setSelectedValue(options[0].value);
|
|
68
|
+
setSelectedOption(options[0].option);
|
|
69
|
+
}
|
|
70
|
+
}, [options, defaultValue]);
|
|
71
|
+
var handleSelection = function handleSelection(value, option) {
|
|
72
|
+
if (value !== selectedValue) {
|
|
73
|
+
setSelectedValue(value);
|
|
74
|
+
setSelectedOption(option);
|
|
75
|
+
onChange(value);
|
|
76
|
+
}
|
|
77
|
+
};
|
|
78
|
+
return React.createElement(Container, {
|
|
79
|
+
onMouseLeave: function onMouseLeave() {
|
|
80
|
+
return setOpened(false);
|
|
81
|
+
},
|
|
82
|
+
width: width
|
|
83
|
+
}, React.createElement(DropdownSelect, {
|
|
84
|
+
id: "dropdown-" + dropdownId,
|
|
85
|
+
className: "rpgui-dropdown-imp rpgui-dropdown-imp-header",
|
|
86
|
+
onPointerUp: function onPointerUp() {
|
|
87
|
+
return setOpened(function (prev) {
|
|
88
|
+
return !prev;
|
|
89
|
+
});
|
|
90
|
+
}
|
|
91
|
+
}, React.createElement(DropdownDisplay, null, React.createElement(DropdownLabel, null, "\u25BC"), " ", selectedOption, !options.length && React.createElement(BeatLoader, {
|
|
92
|
+
size: 4,
|
|
93
|
+
color: uiColors.white
|
|
94
|
+
}))), React.createElement(DropdownOptions, {
|
|
95
|
+
className: "rpgui-dropdown-imp",
|
|
96
|
+
opened: opened
|
|
97
|
+
}, options == null ? void 0 : options.map(function (option) {
|
|
98
|
+
return React.createElement("li", {
|
|
99
|
+
key: option.id,
|
|
100
|
+
onPointerUp: function onPointerUp() {
|
|
101
|
+
handleSelection(option.value, option.option);
|
|
102
|
+
setOpened(false);
|
|
103
|
+
}
|
|
104
|
+
}, option.option);
|
|
105
|
+
})));
|
|
106
|
+
};
|
|
107
|
+
var DropdownDisplay = /*#__PURE__*/styled.span.withConfig({
|
|
108
|
+
displayName: "AsyncDropdown__DropdownDisplay",
|
|
109
|
+
componentId: "sc-lk409c-0"
|
|
110
|
+
})(["display:flex;flex-wrap:wrap;justify-content:start;align-items:center;"]);
|
|
111
|
+
var DropdownLabel = /*#__PURE__*/styled.label.withConfig({
|
|
112
|
+
displayName: "AsyncDropdown__DropdownLabel",
|
|
113
|
+
componentId: "sc-lk409c-1"
|
|
114
|
+
})(["margin-right:0.5rem;"]);
|
|
115
|
+
var Container = /*#__PURE__*/styled.div.withConfig({
|
|
116
|
+
displayName: "AsyncDropdown__Container",
|
|
117
|
+
componentId: "sc-lk409c-2"
|
|
118
|
+
})(["position:relative;width:", ";"], function (props) {
|
|
119
|
+
return props.width || '100%';
|
|
120
|
+
});
|
|
121
|
+
var DropdownSelect = /*#__PURE__*/styled.p.withConfig({
|
|
122
|
+
displayName: "AsyncDropdown__DropdownSelect",
|
|
123
|
+
componentId: "sc-lk409c-3"
|
|
124
|
+
})(["width:100%;box-sizing:border-box;label{display:inline-block;transform:translateY(-2px);}"]);
|
|
125
|
+
var DropdownOptions = /*#__PURE__*/styled.ul.withConfig({
|
|
126
|
+
displayName: "AsyncDropdown__DropdownOptions",
|
|
127
|
+
componentId: "sc-lk409c-4"
|
|
128
|
+
})(["position:absolute;width:100%;max-height:300px;overflow-y:auto;display:", ";box-sizing:border-box;@media (max-width:768px){padding:8px 0;}"], function (props) {
|
|
129
|
+
return props.opened ? 'block' : 'none';
|
|
130
|
+
});
|
|
131
|
+
|
|
17
132
|
function _extends() {
|
|
18
133
|
_extends = Object.assign ? Object.assign.bind() : function (target) {
|
|
19
134
|
for (var i = 1; i < arguments.length; i++) {
|
|
@@ -122,7 +237,7 @@ var SpriteFromAtlas = function SpriteFromAtlas(_ref) {
|
|
|
122
237
|
console.error("SpriteFromAtlas: Could not find sprite with key " + spriteKey + " in atlasJSON.");
|
|
123
238
|
return null;
|
|
124
239
|
}
|
|
125
|
-
return React.createElement(Container, {
|
|
240
|
+
return React.createElement(Container$1, {
|
|
126
241
|
width: width,
|
|
127
242
|
height: height,
|
|
128
243
|
hasHover: grayScale,
|
|
@@ -140,7 +255,7 @@ var SpriteFromAtlas = function SpriteFromAtlas(_ref) {
|
|
|
140
255
|
borderRadius: borderRadius
|
|
141
256
|
}));
|
|
142
257
|
};
|
|
143
|
-
var Container = /*#__PURE__*/styled.div.withConfig({
|
|
258
|
+
var Container$1 = /*#__PURE__*/styled.div.withConfig({
|
|
144
259
|
displayName: "SpriteFromAtlas__Container",
|
|
145
260
|
componentId: "sc-1lpani8-0"
|
|
146
261
|
})(["width:", "px;height:", "px;", ""], function (props) {
|
|
@@ -12356,7 +12471,7 @@ var Ellipsis = function Ellipsis(_ref) {
|
|
|
12356
12471
|
maxWidth = _ref.maxWidth,
|
|
12357
12472
|
fontSize = _ref.fontSize,
|
|
12358
12473
|
center = _ref.center;
|
|
12359
|
-
return React.createElement(Container$
|
|
12474
|
+
return React.createElement(Container$2, {
|
|
12360
12475
|
maxWidth: maxWidth,
|
|
12361
12476
|
fontSize: fontSize,
|
|
12362
12477
|
center: center
|
|
@@ -12364,7 +12479,7 @@ var Ellipsis = function Ellipsis(_ref) {
|
|
|
12364
12479
|
className: "ellipsis-" + maxLines + "-lines"
|
|
12365
12480
|
}, children));
|
|
12366
12481
|
};
|
|
12367
|
-
var Container$
|
|
12482
|
+
var Container$2 = /*#__PURE__*/styled.span.withConfig({
|
|
12368
12483
|
displayName: "Ellipsis__Container",
|
|
12369
12484
|
componentId: "sc-ysrlju-0"
|
|
12370
12485
|
})(["display:block;margin:0;.ellipsis-1-lines{display:block;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;max-width:", ";font-size:", ";", "}.ellipsis-2-lines{display:block;display:-webkit-box;max-width:", "px;height:25px;margin:0 auto;line-height:1;-webkit-line-clamp:2;-webkit-box-orient:vertical;text-overflow:ellipsis;overflow:hidden;font-size:", ";}.ellipsis-3-lines{display:block;display:-webkit-box;max-width:", "px;height:43px;margin:0 auto;line-height:1;-webkit-line-clamp:3;-webkit-box-orient:vertical;text-overflow:ellipsis;overflow:hidden;font-size:", ";}"], function (props) {
|
|
@@ -12413,7 +12528,7 @@ var PropertySelect = function PropertySelect(_ref) {
|
|
|
12413
12528
|
}
|
|
12414
12529
|
return '';
|
|
12415
12530
|
};
|
|
12416
|
-
return React.createElement(Container$
|
|
12531
|
+
return React.createElement(Container$3, null, React.createElement(TextOverlay, null, React.createElement("p", null, React.createElement(Item, null, React.createElement(Ellipsis, {
|
|
12417
12532
|
maxLines: 1,
|
|
12418
12533
|
maxWidth: "60%",
|
|
12419
12534
|
center: true
|
|
@@ -12435,7 +12550,7 @@ var TextOverlay = /*#__PURE__*/styled.div.withConfig({
|
|
|
12435
12550
|
displayName: "PropertySelect__TextOverlay",
|
|
12436
12551
|
componentId: "sc-12uqx6s-1"
|
|
12437
12552
|
})(["width:100%;position:relative;"]);
|
|
12438
|
-
var Container$
|
|
12553
|
+
var Container$3 = /*#__PURE__*/styled.div.withConfig({
|
|
12439
12554
|
displayName: "PropertySelect__Container",
|
|
12440
12555
|
componentId: "sc-12uqx6s-2"
|
|
12441
12556
|
})(["position:relative;display:flex;flex-direction:column;justify-content:start;align-items:flex-start;min-width:100px;width:40%;"]);
|
|
@@ -12472,7 +12587,7 @@ var CharacterSelection = function CharacterSelection(_ref) {
|
|
|
12472
12587
|
useEffect(function () {
|
|
12473
12588
|
setSelectedValue(propertySelectValues[0]);
|
|
12474
12589
|
}, [availableCharacters]);
|
|
12475
|
-
return React.createElement(Container$
|
|
12590
|
+
return React.createElement(Container$4, null, selectedSpriteKey && atlasIMG && atlasJSON && React.createElement(ErrorBoundary, null, React.createElement(SpriteFromAtlas, {
|
|
12476
12591
|
spriteKey: selectedSpriteKey,
|
|
12477
12592
|
atlasIMG: atlasIMG,
|
|
12478
12593
|
atlasJSON: atlasJSON,
|
|
@@ -12494,7 +12609,7 @@ var CharacterSelection = function CharacterSelection(_ref) {
|
|
|
12494
12609
|
}
|
|
12495
12610
|
}));
|
|
12496
12611
|
};
|
|
12497
|
-
var Container$
|
|
12612
|
+
var Container$4 = /*#__PURE__*/styled.div.withConfig({
|
|
12498
12613
|
displayName: "CharacterSelection__Container",
|
|
12499
12614
|
componentId: "sc-b34498-0"
|
|
12500
12615
|
})(["display:flex;flex-direction:column;align-items:center;image-rendering:pixelated;"]);
|
|
@@ -12635,28 +12750,6 @@ var Button$1 = /*#__PURE__*/styled.button.withConfig({
|
|
|
12635
12750
|
return buttonBackgroundColor;
|
|
12636
12751
|
});
|
|
12637
12752
|
|
|
12638
|
-
var uiColors = {
|
|
12639
|
-
lightGray: '#888',
|
|
12640
|
-
gray: '#4E4A4E',
|
|
12641
|
-
darkGray: '#3e3e3e',
|
|
12642
|
-
darkYellow: '#FFC857',
|
|
12643
|
-
yellow: '#FFFF00',
|
|
12644
|
-
orange: '#D27D2C',
|
|
12645
|
-
cardinal: '#C5283D',
|
|
12646
|
-
red: '#D04648',
|
|
12647
|
-
darkRed: '#442434',
|
|
12648
|
-
raisinBlack: '#191923',
|
|
12649
|
-
navyBlue: '#0E79B2',
|
|
12650
|
-
purple: '#6833A3',
|
|
12651
|
-
darkPurple: '#522761',
|
|
12652
|
-
blue: '#597DCE',
|
|
12653
|
-
darkBlue: '#30346D',
|
|
12654
|
-
brown: '#854C30',
|
|
12655
|
-
lightGreen: '#66cd1c',
|
|
12656
|
-
brownGreen: '#346524',
|
|
12657
|
-
white: '#fff'
|
|
12658
|
-
};
|
|
12659
|
-
|
|
12660
12753
|
var SearchCharacter = function SearchCharacter(_ref) {
|
|
12661
12754
|
var onChangeCharacterName = _ref.onChangeCharacterName,
|
|
12662
12755
|
onBlur = _ref.onBlur,
|
|
@@ -12973,13 +13066,13 @@ var RPGUIContainer = function RPGUIContainer(_ref) {
|
|
|
12973
13066
|
width = _ref$width === void 0 ? '50%' : _ref$width,
|
|
12974
13067
|
height = _ref.height,
|
|
12975
13068
|
className = _ref.className;
|
|
12976
|
-
return React.createElement(Container$
|
|
13069
|
+
return React.createElement(Container$5, {
|
|
12977
13070
|
width: width,
|
|
12978
13071
|
height: height || 'auto',
|
|
12979
13072
|
className: "rpgui-container " + type + " " + className
|
|
12980
13073
|
}, children);
|
|
12981
13074
|
};
|
|
12982
|
-
var Container$
|
|
13075
|
+
var Container$5 = /*#__PURE__*/styled.div.withConfig({
|
|
12983
13076
|
displayName: "RPGUIContainer__Container",
|
|
12984
13077
|
componentId: "sc-a7heha-0"
|
|
12985
13078
|
})(["height:", ";width:", ";display:flex;flex-wrap:wrap;image-rendering:pixelated;"], function (props) {
|
|
@@ -13038,7 +13131,7 @@ var ChatDeprecated = function ChatDeprecated(_ref) {
|
|
|
13038
13131
|
}, onRenderMessageLines(emitter, createdAt, message));
|
|
13039
13132
|
}) : React.createElement(MessageText, null, "No messages available.");
|
|
13040
13133
|
};
|
|
13041
|
-
return React.createElement(Container$
|
|
13134
|
+
return React.createElement(Container$6, null, React.createElement(CustomContainer, {
|
|
13042
13135
|
type: RPGUIContainerTypes.FramedGrey,
|
|
13043
13136
|
width: width,
|
|
13044
13137
|
height: height,
|
|
@@ -13076,7 +13169,7 @@ var ChatDeprecated = function ChatDeprecated(_ref) {
|
|
|
13076
13169
|
id: "chat-send-button"
|
|
13077
13170
|
}, "Send"))))));
|
|
13078
13171
|
};
|
|
13079
|
-
var Container$
|
|
13172
|
+
var Container$6 = /*#__PURE__*/styled.div.withConfig({
|
|
13080
13173
|
displayName: "ChatDeprecated__Container",
|
|
13081
13174
|
componentId: "sc-fuuod3-0"
|
|
13082
13175
|
})(["position:relative;"]);
|
|
@@ -13412,7 +13505,7 @@ var DraggableContainer = function DraggableContainer(_ref) {
|
|
|
13412
13505
|
},
|
|
13413
13506
|
defaultPosition: initialPosition,
|
|
13414
13507
|
scale: scale
|
|
13415
|
-
}, React.createElement(Container$
|
|
13508
|
+
}, React.createElement(Container$7, {
|
|
13416
13509
|
ref: draggableRef,
|
|
13417
13510
|
width: width,
|
|
13418
13511
|
height: height || 'auto',
|
|
@@ -13427,7 +13520,7 @@ var DraggableContainer = function DraggableContainer(_ref) {
|
|
|
13427
13520
|
onPointerDown: onCloseButton
|
|
13428
13521
|
}, "X"), children));
|
|
13429
13522
|
};
|
|
13430
|
-
var Container$
|
|
13523
|
+
var Container$7 = /*#__PURE__*/styled.div.withConfig({
|
|
13431
13524
|
displayName: "DraggableContainer__Container",
|
|
13432
13525
|
componentId: "sc-184mpyl-0"
|
|
13433
13526
|
})(["height:", ";width:", ";display:flex;flex-wrap:wrap;image-rendering:pixelated;&.rpgui-container{padding-top:1.5rem;}"], function (props) {
|
|
@@ -13498,11 +13591,11 @@ var countItemFromInventory = function countItemFromInventory(itemKey, inventory)
|
|
|
13498
13591
|
var modalRoot = /*#__PURE__*/document.getElementById('modal-root');
|
|
13499
13592
|
var ModalPortal = function ModalPortal(_ref) {
|
|
13500
13593
|
var children = _ref.children;
|
|
13501
|
-
return ReactDOM.createPortal(React.createElement(Container$
|
|
13594
|
+
return ReactDOM.createPortal(React.createElement(Container$8, {
|
|
13502
13595
|
className: "rpgui-content"
|
|
13503
13596
|
}, children), modalRoot);
|
|
13504
13597
|
};
|
|
13505
|
-
var Container$
|
|
13598
|
+
var Container$8 = /*#__PURE__*/styled.div.withConfig({
|
|
13506
13599
|
displayName: "ModalPortal__Container",
|
|
13507
13600
|
componentId: "sc-dgmp04-0"
|
|
13508
13601
|
})(["position:static !important;"]);
|
|
@@ -13637,7 +13730,7 @@ var RelativeListMenu = function RelativeListMenu(_ref) {
|
|
|
13637
13730
|
document.removeEventListener('clickOutside', function (_e) {});
|
|
13638
13731
|
};
|
|
13639
13732
|
}, []);
|
|
13640
|
-
return React.createElement(ModalPortal, null, React.createElement(Container$
|
|
13733
|
+
return React.createElement(ModalPortal, null, React.createElement(Container$9, Object.assign({
|
|
13641
13734
|
fontSize: fontSize,
|
|
13642
13735
|
ref: ref
|
|
13643
13736
|
}, pos), React.createElement("ul", {
|
|
@@ -13654,7 +13747,7 @@ var RelativeListMenu = function RelativeListMenu(_ref) {
|
|
|
13654
13747
|
}, (params == null ? void 0 : params.text) || 'No text');
|
|
13655
13748
|
}))));
|
|
13656
13749
|
};
|
|
13657
|
-
var Container$
|
|
13750
|
+
var Container$9 = /*#__PURE__*/styled.div.withConfig({
|
|
13658
13751
|
displayName: "RelativeListMenu__Container",
|
|
13659
13752
|
componentId: "sc-7hohf-0"
|
|
13660
13753
|
})(["position:absolute;top:", "px;left:", "px;display:flex;flex-direction:column;width:max-content;justify-content:start;align-items:flex-start;li{font-size:", "em;}"], function (props) {
|
|
@@ -13684,7 +13777,7 @@ var MobileItemTooltip = function MobileItemTooltip(_ref) {
|
|
|
13684
13777
|
var _ref$current;
|
|
13685
13778
|
(_ref$current = ref.current) == null ? void 0 : _ref$current.classList.add('fadeOut');
|
|
13686
13779
|
};
|
|
13687
|
-
return React.createElement(ModalPortal, null, React.createElement(Container$
|
|
13780
|
+
return React.createElement(ModalPortal, null, React.createElement(Container$a, {
|
|
13688
13781
|
ref: ref,
|
|
13689
13782
|
onTouchEnd: function onTouchEnd() {
|
|
13690
13783
|
handleFadeOut();
|
|
@@ -13712,7 +13805,7 @@ var MobileItemTooltip = function MobileItemTooltip(_ref) {
|
|
|
13712
13805
|
}, option.text);
|
|
13713
13806
|
}))));
|
|
13714
13807
|
};
|
|
13715
|
-
var Container$
|
|
13808
|
+
var Container$a = /*#__PURE__*/styled.div.withConfig({
|
|
13716
13809
|
displayName: "MobileItemTooltip__Container",
|
|
13717
13810
|
componentId: "sc-ku4p1j-0"
|
|
13718
13811
|
})(["position:absolute;z-index:100;left:0;top:0;width:100vw;height:100vh;background-color:rgba(0 0 0 / 0.5);display:flex;justify-content:center;align-items:center;gap:0.5rem;transition:opacity 0.08s;animation:fadeIn 0.1s forwards;@keyframes fadeIn{0%{opacity:0;}100%{opacity:0.92;}}@keyframes fadeOut{0%{opacity:0.92;}100%{opacity:0;}}&.fadeOut{animation:fadeOut 0.1s forwards;}@media (max-width:640px){flex-direction:column;}"]);
|
|
@@ -14112,7 +14205,7 @@ var ItemSlot = /*#__PURE__*/observer(function (_ref) {
|
|
|
14112
14205
|
setDraggingItem(item);
|
|
14113
14206
|
}
|
|
14114
14207
|
};
|
|
14115
|
-
return React.createElement(Container$
|
|
14208
|
+
return React.createElement(Container$b, {
|
|
14116
14209
|
isDraggingItem: !!draggingItem,
|
|
14117
14210
|
item: item,
|
|
14118
14211
|
className: "rpgui-icon empty-slot",
|
|
@@ -14190,7 +14283,7 @@ var ItemSlot = /*#__PURE__*/observer(function (_ref) {
|
|
|
14190
14283
|
setIsTooltipVisible: setTooltipVisible
|
|
14191
14284
|
}));
|
|
14192
14285
|
});
|
|
14193
|
-
var Container$
|
|
14286
|
+
var Container$b = /*#__PURE__*/styled.div.withConfig({
|
|
14194
14287
|
displayName: "ItemSlot__Container",
|
|
14195
14288
|
componentId: "sc-l2j5ef-0"
|
|
14196
14289
|
})(["margin:0.1rem;.react-draggable-dragging{opacity:", ";}position:relative;.sprite-from-atlas-img--item{position:relative;top:1.5rem;left:1.5rem;border-color:", ";box-shadow:", " inset,", ";}&::before{content:'';position:absolute;top:0;left:0;width:100%;height:100%;z-index:1;border-radius:12px;pointer-events:none;animation:", ";@keyframes bg-color-change{0%{background-color:rgba(255 255 255 / 0.5);}50%{background-color:transparent;}100%{background-color:rgba(255 255 255 / 0.5);}}}"], function (_ref2) {
|
|
@@ -14306,7 +14399,7 @@ var ItemInfo = function ItemInfo(_ref) {
|
|
|
14306
14399
|
});
|
|
14307
14400
|
};
|
|
14308
14401
|
var skillName = (_item$minRequirements = item.minRequirements) == null ? void 0 : (_item$minRequirements2 = _item$minRequirements.skill) == null ? void 0 : _item$minRequirements2.name;
|
|
14309
|
-
return React.createElement(Container$
|
|
14402
|
+
return React.createElement(Container$c, {
|
|
14310
14403
|
item: item
|
|
14311
14404
|
}, React.createElement(Header, null, React.createElement("div", null, React.createElement(Title$1, null, item.name), item.rarity !== 'Common' && React.createElement(Rarity, {
|
|
14312
14405
|
item: item
|
|
@@ -14320,7 +14413,7 @@ var ItemInfo = function ItemInfo(_ref) {
|
|
|
14320
14413
|
"$isSpecial": true
|
|
14321
14414
|
}, "Two handed"), React.createElement(Description, null, item.description), item.maxStackSize && item.maxStackSize !== 1 && React.createElement(StackInfo, null, "x", Math.round(((_item$stackQty = item.stackQty) != null ? _item$stackQty : 1) * 100) / 100, "(", item.maxStackSize, ")"), renderMissingStatistic().length > 0 && React.createElement(MissingStatistics, null, React.createElement(Statistic, null, "Equipped Diff"), itemToCompare && renderMissingStatistic()));
|
|
14322
14415
|
};
|
|
14323
|
-
var Container$
|
|
14416
|
+
var Container$c = /*#__PURE__*/styled.div.withConfig({
|
|
14324
14417
|
displayName: "ItemInfo__Container",
|
|
14325
14418
|
componentId: "sc-1xm4q8k-0"
|
|
14326
14419
|
})(["color:white;background-color:#222;border-radius:5px;padding:0.5rem;font-size:", ";border:3px solid ", ";height:max-content;width:18rem;@media (max-width:640px){width:80vw;}"], uiFonts.size.small, function (_ref2) {
|
|
@@ -14466,7 +14559,7 @@ var ItemTooltip = function ItemTooltip(_ref) {
|
|
|
14466
14559
|
}
|
|
14467
14560
|
return;
|
|
14468
14561
|
}, []);
|
|
14469
|
-
return React.createElement(ModalPortal, null, React.createElement(Container$
|
|
14562
|
+
return React.createElement(ModalPortal, null, React.createElement(Container$d, {
|
|
14470
14563
|
ref: ref
|
|
14471
14564
|
}, React.createElement(ItemInfoDisplay, {
|
|
14472
14565
|
item: item,
|
|
@@ -14475,7 +14568,7 @@ var ItemTooltip = function ItemTooltip(_ref) {
|
|
|
14475
14568
|
equipmentSet: equipmentSet
|
|
14476
14569
|
})));
|
|
14477
14570
|
};
|
|
14478
|
-
var Container$
|
|
14571
|
+
var Container$d = /*#__PURE__*/styled.div.withConfig({
|
|
14479
14572
|
displayName: "ItemTooltip__Container",
|
|
14480
14573
|
componentId: "sc-11d9r7x-0"
|
|
14481
14574
|
})(["position:absolute;z-index:100;pointer-events:none;left:0;top:0;opacity:0;transition:opacity 0.08s;"]);
|
|
@@ -14793,12 +14886,9 @@ var ItemTypes = /*#__PURE__*/styled.div.withConfig({
|
|
|
14793
14886
|
var Dropdown = function Dropdown(_ref) {
|
|
14794
14887
|
var options = _ref.options,
|
|
14795
14888
|
width = _ref.width,
|
|
14796
|
-
onChange = _ref.onChange
|
|
14797
|
-
defaultValue = _ref.defaultValue,
|
|
14798
|
-
_ref$triggerChangeOnM = _ref.triggerChangeOnMount,
|
|
14799
|
-
triggerChangeOnMount = _ref$triggerChangeOnM === void 0 ? true : _ref$triggerChangeOnM;
|
|
14889
|
+
onChange = _ref.onChange;
|
|
14800
14890
|
var dropdownId = v4();
|
|
14801
|
-
var _useState = useState(
|
|
14891
|
+
var _useState = useState(''),
|
|
14802
14892
|
selectedValue = _useState[0],
|
|
14803
14893
|
setSelectedValue = _useState[1];
|
|
14804
14894
|
var _useState2 = useState(''),
|
|
@@ -14827,27 +14917,16 @@ var Dropdown = function Dropdown(_ref) {
|
|
|
14827
14917
|
}
|
|
14828
14918
|
}, [options]);
|
|
14829
14919
|
useEffect(function () {
|
|
14830
|
-
if (
|
|
14831
|
-
var option = options.find(function (o) {
|
|
14832
|
-
return o.value === defaultValue;
|
|
14833
|
-
});
|
|
14834
|
-
if (option) {
|
|
14835
|
-
setSelectedValue(option.value);
|
|
14836
|
-
setSelectedOption(option.option);
|
|
14837
|
-
}
|
|
14838
|
-
}
|
|
14839
|
-
}, [defaultValue]);
|
|
14840
|
-
useEffect(function () {
|
|
14841
|
-
if (selectedValue && triggerChangeOnMount) {
|
|
14920
|
+
if (selectedValue) {
|
|
14842
14921
|
onChange(selectedValue);
|
|
14843
14922
|
}
|
|
14844
14923
|
}, [selectedValue]);
|
|
14845
|
-
return React.createElement(Container$
|
|
14924
|
+
return React.createElement(Container$e, {
|
|
14846
14925
|
onMouseLeave: function onMouseLeave() {
|
|
14847
14926
|
return setOpened(false);
|
|
14848
14927
|
},
|
|
14849
14928
|
width: width
|
|
14850
|
-
}, React.createElement(DropdownSelect, {
|
|
14929
|
+
}, React.createElement(DropdownSelect$1, {
|
|
14851
14930
|
id: "dropdown-" + dropdownId,
|
|
14852
14931
|
className: "rpgui-dropdown-imp rpgui-dropdown-imp-header",
|
|
14853
14932
|
onPointerUp: function onPointerUp() {
|
|
@@ -14855,7 +14934,7 @@ var Dropdown = function Dropdown(_ref) {
|
|
|
14855
14934
|
return !prev;
|
|
14856
14935
|
});
|
|
14857
14936
|
}
|
|
14858
|
-
}, React.createElement("label", null, "\u25BC"), " ", selectedOption), React.createElement(DropdownOptions, {
|
|
14937
|
+
}, React.createElement("label", null, "\u25BC"), " ", selectedOption), React.createElement(DropdownOptions$1, {
|
|
14859
14938
|
className: "rpgui-dropdown-imp",
|
|
14860
14939
|
opened: opened
|
|
14861
14940
|
}, options.map(function (option) {
|
|
@@ -14869,17 +14948,17 @@ var Dropdown = function Dropdown(_ref) {
|
|
|
14869
14948
|
}, option.option);
|
|
14870
14949
|
})));
|
|
14871
14950
|
};
|
|
14872
|
-
var Container$
|
|
14951
|
+
var Container$e = /*#__PURE__*/styled.div.withConfig({
|
|
14873
14952
|
displayName: "Dropdown__Container",
|
|
14874
14953
|
componentId: "sc-8arn65-0"
|
|
14875
14954
|
})(["position:relative;width:", ";"], function (props) {
|
|
14876
14955
|
return props.width || '100%';
|
|
14877
14956
|
});
|
|
14878
|
-
var DropdownSelect = /*#__PURE__*/styled.p.withConfig({
|
|
14957
|
+
var DropdownSelect$1 = /*#__PURE__*/styled.p.withConfig({
|
|
14879
14958
|
displayName: "Dropdown__DropdownSelect",
|
|
14880
14959
|
componentId: "sc-8arn65-1"
|
|
14881
14960
|
})(["width:100%;box-sizing:border-box;label{display:inline-block;transform:translateY(-2px);}"]);
|
|
14882
|
-
var DropdownOptions = /*#__PURE__*/styled.ul.withConfig({
|
|
14961
|
+
var DropdownOptions$1 = /*#__PURE__*/styled.ul.withConfig({
|
|
14883
14962
|
displayName: "Dropdown__DropdownOptions",
|
|
14884
14963
|
componentId: "sc-8arn65-2"
|
|
14885
14964
|
})(["position:absolute;width:100%;max-height:300px;overflow-y:auto;display:", ";box-sizing:border-box;@media (max-width:768px){padding:8px 0;}"], function (props) {
|
|
@@ -14981,7 +15060,7 @@ var DraggedItem = function DraggedItem(_ref) {
|
|
|
14981
15060
|
var centeredX = x - OFFSET;
|
|
14982
15061
|
var centeredY = y - OFFSET;
|
|
14983
15062
|
var stackInfo = onRenderStackInfo((_item$_id = item == null ? void 0 : item._id) != null ? _item$_id : '', (_item$stackQty = item == null ? void 0 : item.stackQty) != null ? _item$stackQty : 0);
|
|
14984
|
-
return React.createElement(Container$
|
|
15063
|
+
return React.createElement(Container$f, null, React.createElement(SpriteContainer, {
|
|
14985
15064
|
x: centeredX,
|
|
14986
15065
|
y: centeredY
|
|
14987
15066
|
}, React.createElement(SpriteFromAtlas, {
|
|
@@ -14999,7 +15078,7 @@ var DraggedItem = function DraggedItem(_ref) {
|
|
|
14999
15078
|
}), stackInfo));
|
|
15000
15079
|
};
|
|
15001
15080
|
var pulse = "\n @keyframes pulse {\n 0%, 100% {\n transform: scale(1) rotate(-3deg);\n }\n 50% {\n transform: scale(0.95) rotate(-3deg);\n }\n }\n";
|
|
15002
|
-
var Container$
|
|
15081
|
+
var Container$f = /*#__PURE__*/styled.div.withConfig({
|
|
15003
15082
|
displayName: "DraggedItem__Container",
|
|
15004
15083
|
componentId: "sc-mlzzcp-0"
|
|
15005
15084
|
})(["position:relative;"]);
|
|
@@ -15392,7 +15471,7 @@ var NPCDialogText = function NPCDialogText(_ref) {
|
|
|
15392
15471
|
var _useState2 = useState(false),
|
|
15393
15472
|
showGoNextIndicator = _useState2[0],
|
|
15394
15473
|
setShowGoNextIndicator = _useState2[1];
|
|
15395
|
-
return React.createElement(Container$
|
|
15474
|
+
return React.createElement(Container$g, null, React.createElement(DynamicText, {
|
|
15396
15475
|
text: (textChunks == null ? void 0 : textChunks[chunkIndex]) || '',
|
|
15397
15476
|
onFinish: function onFinish() {
|
|
15398
15477
|
setShowGoNextIndicator(true);
|
|
@@ -15410,7 +15489,7 @@ var NPCDialogText = function NPCDialogText(_ref) {
|
|
|
15410
15489
|
}
|
|
15411
15490
|
}));
|
|
15412
15491
|
};
|
|
15413
|
-
var Container$
|
|
15492
|
+
var Container$g = /*#__PURE__*/styled.div.withConfig({
|
|
15414
15493
|
displayName: "NPCDialogText__Container",
|
|
15415
15494
|
componentId: "sc-1cxkdh9-0"
|
|
15416
15495
|
})([""]);
|
|
@@ -15562,7 +15641,7 @@ var QuestionDialog = function QuestionDialog(_ref) {
|
|
|
15562
15641
|
return null;
|
|
15563
15642
|
});
|
|
15564
15643
|
};
|
|
15565
|
-
return React.createElement(Container$
|
|
15644
|
+
return React.createElement(Container$h, null, React.createElement(QuestionContainer, null, React.createElement(DynamicText, {
|
|
15566
15645
|
text: currentQuestion.text,
|
|
15567
15646
|
onStart: function onStart() {
|
|
15568
15647
|
return setCanShowAnswers(false);
|
|
@@ -15572,7 +15651,7 @@ var QuestionDialog = function QuestionDialog(_ref) {
|
|
|
15572
15651
|
}
|
|
15573
15652
|
})), canShowAnswers && React.createElement(AnswersContainer, null, onRenderCurrentAnswers()));
|
|
15574
15653
|
};
|
|
15575
|
-
var Container$
|
|
15654
|
+
var Container$h = /*#__PURE__*/styled.div.withConfig({
|
|
15576
15655
|
displayName: "QuestionDialog__Container",
|
|
15577
15656
|
componentId: "sc-bxc5u0-0"
|
|
15578
15657
|
})(["display:flex;word-break:break-all;box-sizing:border-box;justify-content:flex-start;align-items:flex-start;flex-wrap:wrap;"]);
|
|
@@ -15633,7 +15712,7 @@ var NPCDialog = function NPCDialog(_ref) {
|
|
|
15633
15712
|
}
|
|
15634
15713
|
})), type === NPCDialogType.TextAndThumbnail && React.createElement(ThumbnailContainer, null, React.createElement(NPCThumbnail, {
|
|
15635
15714
|
src: imagePath || img$7
|
|
15636
|
-
}))) : React.createElement(React.Fragment, null, React.createElement(Container$
|
|
15715
|
+
}))) : React.createElement(React.Fragment, null, React.createElement(Container$i, null, React.createElement(TextContainer$1, {
|
|
15637
15716
|
flex: type === NPCDialogType.TextAndThumbnail ? '70%' : '100%'
|
|
15638
15717
|
}, React.createElement(NPCDialogText, {
|
|
15639
15718
|
type: type,
|
|
@@ -15647,7 +15726,7 @@ var NPCDialog = function NPCDialog(_ref) {
|
|
|
15647
15726
|
src: imagePath || img$7
|
|
15648
15727
|
})))));
|
|
15649
15728
|
};
|
|
15650
|
-
var Container$
|
|
15729
|
+
var Container$i = /*#__PURE__*/styled.div.withConfig({
|
|
15651
15730
|
displayName: "NPCDialog__Container",
|
|
15652
15731
|
componentId: "sc-1b4aw74-0"
|
|
15653
15732
|
})(["display:flex;width:100%;height:100%;box-sizing:border-box;justify-content:center;align-items:flex-start;position:relative;"]);
|
|
@@ -15704,7 +15783,7 @@ var NPCMultiDialog = function NPCMultiDialog(_ref) {
|
|
|
15704
15783
|
type: RPGUIContainerTypes.FramedGold,
|
|
15705
15784
|
width: '50%',
|
|
15706
15785
|
height: '180px'
|
|
15707
|
-
}, React.createElement(React.Fragment, null, React.createElement(Container$
|
|
15786
|
+
}, React.createElement(React.Fragment, null, React.createElement(Container$j, null, ((_textAndTypeArray$sli = textAndTypeArray[slide]) == null ? void 0 : _textAndTypeArray$sli.imageSide) === 'right' && React.createElement(React.Fragment, null, React.createElement(TextContainer$2, {
|
|
15708
15787
|
flex: '70%'
|
|
15709
15788
|
}, React.createElement(NPCDialogText, {
|
|
15710
15789
|
onStartStep: function onStartStep() {
|
|
@@ -15746,7 +15825,7 @@ var NPCMultiDialog = function NPCMultiDialog(_ref) {
|
|
|
15746
15825
|
src: img$6
|
|
15747
15826
|
}))), ")"));
|
|
15748
15827
|
};
|
|
15749
|
-
var Container$
|
|
15828
|
+
var Container$j = /*#__PURE__*/styled.div.withConfig({
|
|
15750
15829
|
displayName: "NPCMultiDialog__Container",
|
|
15751
15830
|
componentId: "sc-rvu5wg-0"
|
|
15752
15831
|
})(["display:flex;width:100%;height:100%;box-sizing:border-box;justify-content:center;align-items:flex-start;position:relative;"]);
|
|
@@ -15932,8 +16011,7 @@ var CloseButton$3 = /*#__PURE__*/styled.div.withConfig({
|
|
|
15932
16011
|
})(["position:absolute;top:3px;right:0px;color:white;z-index:22;font-size:1.5rem;@media (max-width:950px){font-size:1.7rem;padding:12px;}"]);
|
|
15933
16012
|
|
|
15934
16013
|
var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
15935
|
-
var
|
|
15936
|
-
imagesSrc = _ref.imagesSrc,
|
|
16014
|
+
var images = _ref.images,
|
|
15937
16015
|
styles = _ref.styles,
|
|
15938
16016
|
_ref$autoCycle = _ref.autoCycle,
|
|
15939
16017
|
autoCycle = _ref$autoCycle === void 0 ? false : _ref$autoCycle,
|
|
@@ -15944,42 +16022,43 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
15944
16022
|
var _useState = useState(0),
|
|
15945
16023
|
currentImage = _useState[0],
|
|
15946
16024
|
setCurrentImage = _useState[1];
|
|
15947
|
-
var
|
|
16025
|
+
var _useState2 = useState(null),
|
|
16026
|
+
autoCycleId = _useState2[0],
|
|
16027
|
+
setAutoCycleId = _useState2[1];
|
|
16028
|
+
var handleLeftClick = function handleLeftClick() {
|
|
16029
|
+
setCurrentImage(function (prevImage) {
|
|
16030
|
+
return (prevImage - 1 + images.length) % images.length;
|
|
16031
|
+
});
|
|
16032
|
+
if (stopAutoCyclingOnInteraction && autoCycleId) {
|
|
16033
|
+
clearInterval(autoCycleId);
|
|
16034
|
+
setAutoCycleId(null);
|
|
16035
|
+
}
|
|
16036
|
+
};
|
|
16037
|
+
var handleRightClick = function handleRightClick() {
|
|
16038
|
+
setCurrentImage(function (prevImage) {
|
|
16039
|
+
return (prevImage + 1) % images.length;
|
|
16040
|
+
});
|
|
16041
|
+
if (stopAutoCyclingOnInteraction && autoCycleId) {
|
|
16042
|
+
clearInterval(autoCycleId);
|
|
16043
|
+
setAutoCycleId(null);
|
|
16044
|
+
}
|
|
16045
|
+
};
|
|
15948
16046
|
useEffect(function () {
|
|
15949
|
-
|
|
15950
|
-
|
|
15951
|
-
|
|
15952
|
-
|
|
15953
|
-
|
|
15954
|
-
return;
|
|
15955
|
-
}
|
|
15956
|
-
handleRightClick(true);
|
|
16047
|
+
if (autoCycle) {
|
|
16048
|
+
var id = setInterval(function () {
|
|
16049
|
+
setCurrentImage(function (prevImage) {
|
|
16050
|
+
return (prevImage + 1) % images.length;
|
|
16051
|
+
});
|
|
15957
16052
|
}, autoCycleDelay);
|
|
16053
|
+
setAutoCycleId(id);
|
|
15958
16054
|
}
|
|
15959
16055
|
return function () {
|
|
15960
|
-
if (
|
|
15961
|
-
clearInterval(
|
|
16056
|
+
if (autoCycleId) {
|
|
16057
|
+
clearInterval(autoCycleId);
|
|
15962
16058
|
}
|
|
15963
16059
|
};
|
|
15964
|
-
}, [autoCycle, autoCycleDelay]);
|
|
15965
|
-
var
|
|
15966
|
-
isInteracted.current = true;
|
|
15967
|
-
setCurrentImage(function (oldImage) {
|
|
15968
|
-
return oldImage === 0 ? imagesSrc.length - 1 : oldImage - 1;
|
|
15969
|
-
});
|
|
15970
|
-
};
|
|
15971
|
-
var handleRightClick = function handleRightClick(isAutomatedClick) {
|
|
15972
|
-
if (isAutomatedClick === void 0) {
|
|
15973
|
-
isAutomatedClick = false;
|
|
15974
|
-
}
|
|
15975
|
-
if (!isAutomatedClick) {
|
|
15976
|
-
isInteracted.current = true;
|
|
15977
|
-
}
|
|
15978
|
-
setCurrentImage(function (oldImage) {
|
|
15979
|
-
return oldImage === imagesSrc.length - 1 ? 0 : oldImage + 1;
|
|
15980
|
-
});
|
|
15981
|
-
};
|
|
15982
|
-
var hasMoreThanOneImage = imagesSrc.length > 1;
|
|
16060
|
+
}, [autoCycle, autoCycleDelay, images.length]);
|
|
16061
|
+
var hasMoreThanOneImage = images.length > 1;
|
|
15983
16062
|
return React.createElement(ImageContainer, {
|
|
15984
16063
|
style: styles
|
|
15985
16064
|
}, hasMoreThanOneImage && React.createElement(CustomLeftArrow, {
|
|
@@ -15990,8 +16069,8 @@ var SimpleImageCarousel = function SimpleImageCarousel(_ref) {
|
|
|
15990
16069
|
onPointerDown: handleRightClick
|
|
15991
16070
|
}), React.createElement(Carousel, null, React.createElement(FadeInCarouselImg, {
|
|
15992
16071
|
key: currentImage,
|
|
15993
|
-
src:
|
|
15994
|
-
alt:
|
|
16072
|
+
src: images[currentImage],
|
|
16073
|
+
alt: "Image " + currentImage
|
|
15995
16074
|
})));
|
|
15996
16075
|
};
|
|
15997
16076
|
var ImageContainer = /*#__PURE__*/styled.div.withConfig({
|
|
@@ -16174,7 +16253,7 @@ var ShortcutsSetter = function ShortcutsSetter(_ref) {
|
|
|
16174
16253
|
}
|
|
16175
16254
|
return null;
|
|
16176
16255
|
};
|
|
16177
|
-
return React.createElement(Container$
|
|
16256
|
+
return React.createElement(Container$k, null, React.createElement("p", null, "Shortcuts:"), React.createElement(List, {
|
|
16178
16257
|
id: "shortcuts_list"
|
|
16179
16258
|
}, Array.from({
|
|
16180
16259
|
length: 12
|
|
@@ -16192,7 +16271,7 @@ var ShortcutsSetter = function ShortcutsSetter(_ref) {
|
|
|
16192
16271
|
}, getContent(i));
|
|
16193
16272
|
})));
|
|
16194
16273
|
};
|
|
16195
|
-
var Container$
|
|
16274
|
+
var Container$k = /*#__PURE__*/styled.div.withConfig({
|
|
16196
16275
|
displayName: "ShortcutsSetter__Container",
|
|
16197
16276
|
componentId: "sc-xuouuf-0"
|
|
16198
16277
|
})(["p{margin:0;margin-left:0.5rem;font-size:10px;}width:100%;"]);
|
|
@@ -16685,7 +16764,7 @@ var ListMenu = function ListMenu(_ref) {
|
|
|
16685
16764
|
onSelected = _ref.onSelected,
|
|
16686
16765
|
x = _ref.x,
|
|
16687
16766
|
y = _ref.y;
|
|
16688
|
-
return React.createElement(Container$
|
|
16767
|
+
return React.createElement(Container$l, {
|
|
16689
16768
|
x: x,
|
|
16690
16769
|
y: y
|
|
16691
16770
|
}, React.createElement("ul", {
|
|
@@ -16702,7 +16781,7 @@ var ListMenu = function ListMenu(_ref) {
|
|
|
16702
16781
|
}, (params == null ? void 0 : params.text) || 'No text');
|
|
16703
16782
|
})));
|
|
16704
16783
|
};
|
|
16705
|
-
var Container$
|
|
16784
|
+
var Container$l = /*#__PURE__*/styled.div.withConfig({
|
|
16706
16785
|
displayName: "ListMenu__Container",
|
|
16707
16786
|
componentId: "sc-i9097t-0"
|
|
16708
16787
|
})(["display:flex;flex-direction:column;width:100%;justify-content:start;align-items:flex-start;position:absolute;top:", "px;left:", "px;li{font-size:", ";}"], function (props) {
|
|
@@ -16721,7 +16800,7 @@ var Pager = function Pager(_ref) {
|
|
|
16721
16800
|
itemsPerPage = _ref.itemsPerPage,
|
|
16722
16801
|
onPageChange = _ref.onPageChange;
|
|
16723
16802
|
var totalPages = Math.ceil(totalItems / itemsPerPage);
|
|
16724
|
-
return React.createElement(Container$
|
|
16803
|
+
return React.createElement(Container$m, null, React.createElement("p", null, "Total items: ", totalItems), React.createElement(PagerContainer, null, React.createElement("button", {
|
|
16725
16804
|
disabled: currentPage === 1,
|
|
16726
16805
|
onPointerDown: function onPointerDown() {
|
|
16727
16806
|
return onPageChange(Math.max(currentPage - 1, 1));
|
|
@@ -16735,7 +16814,7 @@ var Pager = function Pager(_ref) {
|
|
|
16735
16814
|
}
|
|
16736
16815
|
}, '>')));
|
|
16737
16816
|
};
|
|
16738
|
-
var Container$
|
|
16817
|
+
var Container$m = /*#__PURE__*/styled.div.withConfig({
|
|
16739
16818
|
displayName: "Pager__Container",
|
|
16740
16819
|
componentId: "sc-1ekmf50-0"
|
|
16741
16820
|
})(["display:flex;flex-direction:column;align-items:center;p{margin:0;font-size:", ";}"], uiFonts.size.xsmall);
|
|
@@ -16748,7 +16827,7 @@ var ConfirmModal = function ConfirmModal(_ref) {
|
|
|
16748
16827
|
var onConfirm = _ref.onConfirm,
|
|
16749
16828
|
onClose = _ref.onClose,
|
|
16750
16829
|
message = _ref.message;
|
|
16751
|
-
return React.createElement(ModalPortal, null, React.createElement(Background, null), React.createElement(Container$
|
|
16830
|
+
return React.createElement(ModalPortal, null, React.createElement(Background, null), React.createElement(Container$n, {
|
|
16752
16831
|
onPointerDown: onClose
|
|
16753
16832
|
}, React.createElement(DraggableContainer, {
|
|
16754
16833
|
width: "auto",
|
|
@@ -16771,7 +16850,7 @@ var Background = /*#__PURE__*/styled.div.withConfig({
|
|
|
16771
16850
|
displayName: "ConfirmModal__Background",
|
|
16772
16851
|
componentId: "sc-11qkyu1-0"
|
|
16773
16852
|
})(["position:absolute;width:100%;height:100%;background-color:#000000;opacity:0.5;left:0;top:0;z-index:1000;"]);
|
|
16774
|
-
var Container$
|
|
16853
|
+
var Container$n = /*#__PURE__*/styled.div.withConfig({
|
|
16775
16854
|
displayName: "ConfirmModal__Container",
|
|
16776
16855
|
componentId: "sc-11qkyu1-1"
|
|
16777
16856
|
})(["position:absolute;width:100%;height:100%;left:0;top:0;display:flex;justify-content:center;align-items:center;z-index:1001;"]);
|
|
@@ -17736,7 +17815,7 @@ var ProgressBar = function ProgressBar(_ref) {
|
|
|
17736
17815
|
}
|
|
17737
17816
|
return value * 100 / max;
|
|
17738
17817
|
};
|
|
17739
|
-
return React.createElement(Container$
|
|
17818
|
+
return React.createElement(Container$o, {
|
|
17740
17819
|
className: "rpgui-progress",
|
|
17741
17820
|
"data-value": calculatePercentageValue(max, value) / 100,
|
|
17742
17821
|
"data-rpguitype": "progress",
|
|
@@ -17766,7 +17845,7 @@ var TextOverlay$1 = /*#__PURE__*/styled.div.withConfig({
|
|
|
17766
17845
|
displayName: "ProgressBar__TextOverlay",
|
|
17767
17846
|
componentId: "sc-qa6fzh-1"
|
|
17768
17847
|
})(["width:100%;position:relative;"]);
|
|
17769
|
-
var Container$
|
|
17848
|
+
var Container$o = /*#__PURE__*/styled.div.withConfig({
|
|
17770
17849
|
displayName: "ProgressBar__Container",
|
|
17771
17850
|
componentId: "sc-qa6fzh-2"
|
|
17772
17851
|
})(["display:flex;flex-direction:column;min-width:", "px;width:", "%;justify-content:start;align-items:flex-start;", " @media (max-width:950px){transform:scale(", ");}"], function (props) {
|
|
@@ -17948,9 +18027,9 @@ var NoQuestContainer = /*#__PURE__*/styled.div.withConfig({
|
|
|
17948
18027
|
|
|
17949
18028
|
var RPGUIScrollbar = function RPGUIScrollbar(_ref) {
|
|
17950
18029
|
var children = _ref.children;
|
|
17951
|
-
return React.createElement(Container$
|
|
18030
|
+
return React.createElement(Container$p, null, children);
|
|
17952
18031
|
};
|
|
17953
|
-
var Container$
|
|
18032
|
+
var Container$p = /*#__PURE__*/styled.div.withConfig({
|
|
17954
18033
|
displayName: "RPGUIScrollbar__Container",
|
|
17955
18034
|
componentId: "sc-p3msmb-0"
|
|
17956
18035
|
})([".rpgui-content ::-webkit-scrollbar,.rpgui-content::-webkit-scrollbar{width:25px !important;}.rpgui-content ::-webkit-scrollbar-track,.rpgui-content::-webkit-scrollbar-track{background-size:25px 60px !important;}"]);
|
|
@@ -18128,7 +18207,7 @@ var SimpleProgressBar = function SimpleProgressBar(_ref) {
|
|
|
18128
18207
|
bgColor = _ref$bgColor === void 0 ? 'red' : _ref$bgColor,
|
|
18129
18208
|
_ref$margin = _ref.margin,
|
|
18130
18209
|
margin = _ref$margin === void 0 ? 20 : _ref$margin;
|
|
18131
|
-
return React.createElement(Container$
|
|
18210
|
+
return React.createElement(Container$q, {
|
|
18132
18211
|
className: "simple-progress-bar"
|
|
18133
18212
|
}, React.createElement(ProgressBarContainer, {
|
|
18134
18213
|
margin: margin
|
|
@@ -18137,7 +18216,7 @@ var SimpleProgressBar = function SimpleProgressBar(_ref) {
|
|
|
18137
18216
|
bgColor: bgColor
|
|
18138
18217
|
}))));
|
|
18139
18218
|
};
|
|
18140
|
-
var Container$
|
|
18219
|
+
var Container$q = /*#__PURE__*/styled.div.withConfig({
|
|
18141
18220
|
displayName: "SimpleProgressBar__Container",
|
|
18142
18221
|
componentId: "sc-mbeil3-0"
|
|
18143
18222
|
})(["display:flex;justify-content:center;align-items:center;width:100%;"]);
|
|
@@ -18431,7 +18510,7 @@ var SpellInfo = function SpellInfo(_ref) {
|
|
|
18431
18510
|
castingType = spell.castingType,
|
|
18432
18511
|
cooldown = spell.cooldown,
|
|
18433
18512
|
maxDistanceGrid = spell.maxDistanceGrid;
|
|
18434
|
-
return React.createElement(Container$
|
|
18513
|
+
return React.createElement(Container$r, null, React.createElement(Header$1, null, React.createElement("div", null, React.createElement(Title$9, null, name), React.createElement(Type$1, null, magicWords))), React.createElement(Statistic$1, null, React.createElement("div", {
|
|
18435
18514
|
className: "label"
|
|
18436
18515
|
}, "Casting Type:"), React.createElement("div", {
|
|
18437
18516
|
className: "value"
|
|
@@ -18457,7 +18536,7 @@ var SpellInfo = function SpellInfo(_ref) {
|
|
|
18457
18536
|
className: "value"
|
|
18458
18537
|
}, requiredItem))), React.createElement(Description$2, null, description));
|
|
18459
18538
|
};
|
|
18460
|
-
var Container$
|
|
18539
|
+
var Container$r = /*#__PURE__*/styled.div.withConfig({
|
|
18461
18540
|
displayName: "SpellInfo__Container",
|
|
18462
18541
|
componentId: "sc-4hbw3q-0"
|
|
18463
18542
|
})(["color:white;background-color:#222;border-radius:5px;padding:0.5rem;font-size:", ";border:3px solid ", ";height:max-content;width:30rem;@media (max-width:580px){width:80vw;}"], uiFonts.size.small, uiColors.lightGray);
|
|
@@ -18511,7 +18590,7 @@ var MobileSpellTooltip = function MobileSpellTooltip(_ref) {
|
|
|
18511
18590
|
var _ref$current;
|
|
18512
18591
|
(_ref$current = ref.current) == null ? void 0 : _ref$current.classList.add('fadeOut');
|
|
18513
18592
|
};
|
|
18514
|
-
return React.createElement(ModalPortal, null, React.createElement(Container$
|
|
18593
|
+
return React.createElement(ModalPortal, null, React.createElement(Container$s, {
|
|
18515
18594
|
ref: ref,
|
|
18516
18595
|
onTouchEnd: function onTouchEnd() {
|
|
18517
18596
|
handleFadeOut();
|
|
@@ -18536,7 +18615,7 @@ var MobileSpellTooltip = function MobileSpellTooltip(_ref) {
|
|
|
18536
18615
|
}, option.text);
|
|
18537
18616
|
}))));
|
|
18538
18617
|
};
|
|
18539
|
-
var Container$
|
|
18618
|
+
var Container$s = /*#__PURE__*/styled.div.withConfig({
|
|
18540
18619
|
displayName: "MobileSpellTooltip__Container",
|
|
18541
18620
|
componentId: "sc-6p7uvr-0"
|
|
18542
18621
|
})(["position:absolute;z-index:100;left:0;top:0;width:100vw;height:100vh;background-color:rgba(0 0 0 / 0.5);display:flex;justify-content:center;align-items:center;gap:0.5rem;transition:opacity 0.08s;animation:fadeIn 0.1s forwards;@keyframes fadeIn{0%{opacity:0;}100%{opacity:0.92;}}@keyframes fadeOut{0%{opacity:0.92;}100%{opacity:0;}}&.fadeOut{animation:fadeOut 0.1s forwards;}@media (max-width:580px){flex-direction:column;}"]);
|
|
@@ -18577,13 +18656,13 @@ var MagicTooltip = function MagicTooltip(_ref) {
|
|
|
18577
18656
|
}
|
|
18578
18657
|
return;
|
|
18579
18658
|
}, []);
|
|
18580
|
-
return React.createElement(ModalPortal, null, React.createElement(Container$
|
|
18659
|
+
return React.createElement(ModalPortal, null, React.createElement(Container$t, {
|
|
18581
18660
|
ref: ref
|
|
18582
18661
|
}, React.createElement(SpellInfoDisplay, {
|
|
18583
18662
|
spell: spell
|
|
18584
18663
|
})));
|
|
18585
18664
|
};
|
|
18586
|
-
var Container$
|
|
18665
|
+
var Container$t = /*#__PURE__*/styled.div.withConfig({
|
|
18587
18666
|
displayName: "SpellTooltip__Container",
|
|
18588
18667
|
componentId: "sc-1go0gwg-0"
|
|
18589
18668
|
})(["position:absolute;z-index:100;pointer-events:none;left:0;top:0;opacity:0;transition:opacity 0.08s;"]);
|
|
@@ -18643,7 +18722,7 @@ var Spell = function Spell(_ref) {
|
|
|
18643
18722
|
var IMAGE_SCALE = 2;
|
|
18644
18723
|
return React.createElement(SpellInfoWrapper, {
|
|
18645
18724
|
spell: spell
|
|
18646
|
-
}, React.createElement(Container$
|
|
18725
|
+
}, React.createElement(Container$u, {
|
|
18647
18726
|
onPointerUp: onPointerUp == null ? void 0 : onPointerUp.bind(null, spellKey),
|
|
18648
18727
|
isSettingShortcut: isSettingShortcut && !disabled,
|
|
18649
18728
|
className: "spell"
|
|
@@ -18662,7 +18741,7 @@ var Spell = function Spell(_ref) {
|
|
|
18662
18741
|
className: "mana"
|
|
18663
18742
|
}, manaCost))));
|
|
18664
18743
|
};
|
|
18665
|
-
var Container$
|
|
18744
|
+
var Container$u = /*#__PURE__*/styled.button.withConfig({
|
|
18666
18745
|
displayName: "Spell__Container",
|
|
18667
18746
|
componentId: "sc-j96fa2-0"
|
|
18668
18747
|
})(["display:block;background:none;border:2px solid transparent;border-radius:1rem;width:100%;display:flex;gap:1rem;align-items:center;padding:0 1rem;text-align:left;position:relative;animation:", ";@keyframes border-color-change{0%{border-color:", ";}50%{border-color:transparent;}100%{border-color:", ";}}&:hover,&:focus{background-color:", ";}&:active{background:none;}"], function (_ref2) {
|
|
@@ -18741,7 +18820,7 @@ var Spellbook = function Spellbook(_ref) {
|
|
|
18741
18820
|
height: "inherit",
|
|
18742
18821
|
cancelDrag: "#spellbook-search, #shortcuts_list, .spell",
|
|
18743
18822
|
scale: scale
|
|
18744
|
-
}, React.createElement(Container$
|
|
18823
|
+
}, React.createElement(Container$v, null, React.createElement(Title$b, null, "Learned Spells"), React.createElement(ShortcutsSetter, {
|
|
18745
18824
|
setSettingShortcutIndex: setSettingShortcutIndex,
|
|
18746
18825
|
settingShortcutIndex: settingShortcutIndex,
|
|
18747
18826
|
shortcuts: shortcuts,
|
|
@@ -18777,7 +18856,7 @@ var Title$b = /*#__PURE__*/styled.h1.withConfig({
|
|
|
18777
18856
|
displayName: "Spellbook__Title",
|
|
18778
18857
|
componentId: "sc-r02nfq-0"
|
|
18779
18858
|
})(["font-size:", " !important;margin-bottom:0 !important;"], uiFonts.size.large);
|
|
18780
|
-
var Container$
|
|
18859
|
+
var Container$v = /*#__PURE__*/styled.div.withConfig({
|
|
18781
18860
|
displayName: "Spellbook__Container",
|
|
18782
18861
|
componentId: "sc-r02nfq-1"
|
|
18783
18862
|
})(["width:100%;height:100%;color:white;display:flex;flex-direction:column;"]);
|
|
@@ -19123,11 +19202,11 @@ var Truncate = function Truncate(_ref) {
|
|
|
19123
19202
|
var _ref$maxLines = _ref.maxLines,
|
|
19124
19203
|
maxLines = _ref$maxLines === void 0 ? 1 : _ref$maxLines,
|
|
19125
19204
|
children = _ref.children;
|
|
19126
|
-
return React.createElement(Container$
|
|
19205
|
+
return React.createElement(Container$w, {
|
|
19127
19206
|
maxLines: maxLines
|
|
19128
19207
|
}, children);
|
|
19129
19208
|
};
|
|
19130
|
-
var Container$
|
|
19209
|
+
var Container$w = /*#__PURE__*/styled.div.withConfig({
|
|
19131
19210
|
displayName: "Truncate__Container",
|
|
19132
19211
|
componentId: "sc-6x00qb-0"
|
|
19133
19212
|
})(["display:-webkit-box;max-width:100%;max-height:100%;-webkit-line-clamp:", ";-webkit-box-orient:vertical;overflow:hidden;"], function (props) {
|
|
@@ -19220,5 +19299,5 @@ var ButtonWrapper$3 = /*#__PURE__*/styled.div.withConfig({
|
|
|
19220
19299
|
componentId: "sc-gptoxp-5"
|
|
19221
19300
|
})(["display:flex;justify-content:space-around;padding-top:20px;width:100%;"]);
|
|
19222
19301
|
|
|
19223
|
-
export { Button, ButtonTypes, CharacterSelection, Chat, ChatDeprecated, ChatRevamp, CheckButton, CircularController, CraftBook, DraggableContainer, Dropdown, DropdownSelectorContainer, DynamicText, EquipmentSet, EquipmentSlotSpriteByType, ErrorBoundary, FriendList, HistoryDialog, ImageCarousel, ImgSide, Input, InputRadio$1 as InputRadio, ItemContainer$1 as ItemContainer, ItemSelector, ItemSlot, Leaderboard, ListMenu, Marketplace, MarketplaceRows, NPCDialog, NPCDialogType, NPCMultiDialog, PartyCreate, PartyDashboard, PartyInvite, PartyManager, PartyManagerRow, PartyRow, PlayersRow, ProgressBar, PropertySelect, QuestInfo, QuestList, QuestionDialog, RPGUIContainer, RPGUIContainerTypes, RPGUIRoot, RangeSlider, RangeSliderType, Shortcuts, SimpleImageCarousel, SkillProgressBar, SkillsContainer, Spellbook, SpriteFromAtlas, TextArea, TimeWidget, TradingMenu, Truncate, _RPGUI, mockedPartyManager, mockedPartyRows, mockedPlayersRows, mockedPlayersRows2, useEventListener };
|
|
19302
|
+
export { AsyncDropdown, Button, ButtonTypes, CharacterSelection, Chat, ChatDeprecated, ChatRevamp, CheckButton, CircularController, CraftBook, DraggableContainer, Dropdown, DropdownSelectorContainer, DynamicText, EquipmentSet, EquipmentSlotSpriteByType, ErrorBoundary, FriendList, HistoryDialog, ImageCarousel, ImgSide, Input, InputRadio$1 as InputRadio, ItemContainer$1 as ItemContainer, ItemSelector, ItemSlot, Leaderboard, ListMenu, Marketplace, MarketplaceRows, NPCDialog, NPCDialogType, NPCMultiDialog, PartyCreate, PartyDashboard, PartyInvite, PartyManager, PartyManagerRow, PartyRow, PlayersRow, ProgressBar, PropertySelect, QuestInfo, QuestList, QuestionDialog, RPGUIContainer, RPGUIContainerTypes, RPGUIRoot, RangeSlider, RangeSliderType, Shortcuts, SimpleImageCarousel, SkillProgressBar, SkillsContainer, Spellbook, SpriteFromAtlas, TextArea, TimeWidget, TradingMenu, Truncate, _RPGUI, mockedPartyManager, mockedPartyRows, mockedPlayersRows, mockedPlayersRows2, useEventListener };
|
|
19224
19303
|
//# sourceMappingURL=long-bow.esm.js.map
|