@rpg-engine/long-bow 0.2.72 → 0.2.73
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/index.d.ts +5 -4
- package/dist/long-bow.cjs.development.js +105 -104
- 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 +105 -105
- package/dist/long-bow.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/index.tsx +5 -4
package/dist/long-bow.esm.js
CHANGED
|
@@ -28520,92 +28520,6 @@ var ItemsContainer = /*#__PURE__*/styled.div.withConfig({
|
|
|
28520
28520
|
componentId: "sc-15y5p9l-0"
|
|
28521
28521
|
})(["max-width:280px;display:flex;justify-content:center;flex-wrap:wrap;"]);
|
|
28522
28522
|
|
|
28523
|
-
var ItemSelector = function ItemSelector(_ref) {
|
|
28524
|
-
var atlasIMG = _ref.atlasIMG,
|
|
28525
|
-
atlasJSON = _ref.atlasJSON,
|
|
28526
|
-
options = _ref.options,
|
|
28527
|
-
onClose = _ref.onClose,
|
|
28528
|
-
onSelect = _ref.onSelect;
|
|
28529
|
-
var _useState = useState(),
|
|
28530
|
-
selectedValue = _useState[0],
|
|
28531
|
-
setSelectedValue = _useState[1];
|
|
28532
|
-
var handleClick = function handleClick() {
|
|
28533
|
-
var element = document.querySelector("input[name='test']:checked");
|
|
28534
|
-
var elementValue = element.value;
|
|
28535
|
-
setSelectedValue(elementValue);
|
|
28536
|
-
};
|
|
28537
|
-
useEffect(function () {
|
|
28538
|
-
if (selectedValue) {
|
|
28539
|
-
onSelect(selectedValue);
|
|
28540
|
-
}
|
|
28541
|
-
}, [selectedValue]);
|
|
28542
|
-
return React.createElement(DraggableContainer, {
|
|
28543
|
-
type: RPGUIContainerTypes.Framed,
|
|
28544
|
-
width: "500px",
|
|
28545
|
-
cancelDrag: ".equipment-container-body .arrow-selector",
|
|
28546
|
-
onCloseButton: function onCloseButton() {
|
|
28547
|
-
if (onClose) {
|
|
28548
|
-
onClose();
|
|
28549
|
-
}
|
|
28550
|
-
}
|
|
28551
|
-
}, React.createElement("div", {
|
|
28552
|
-
style: {
|
|
28553
|
-
width: '100%'
|
|
28554
|
-
}
|
|
28555
|
-
}, React.createElement(Title$2, null, 'Harvesting instruments'), React.createElement(Subtitle$1, null, 'Use the tool, you need it'), React.createElement("hr", {
|
|
28556
|
-
className: "golden"
|
|
28557
|
-
})), React.createElement(RadioInputScroller$1, null, options == null ? void 0 : options.map(function (option, index) {
|
|
28558
|
-
return React.createElement(RadioOptionsWrapper$1, {
|
|
28559
|
-
key: index
|
|
28560
|
-
}, React.createElement(SpriteAtlasWrapper$1, null, React.createElement(SpriteFromAtlas, {
|
|
28561
|
-
atlasIMG: atlasIMG,
|
|
28562
|
-
atlasJSON: atlasJSON,
|
|
28563
|
-
spriteKey: option.imageKey,
|
|
28564
|
-
imgScale: 3
|
|
28565
|
-
})), React.createElement("div", null, React.createElement("input", {
|
|
28566
|
-
className: "rpgui-radio",
|
|
28567
|
-
type: "radio",
|
|
28568
|
-
value: option.name,
|
|
28569
|
-
name: "test"
|
|
28570
|
-
}), React.createElement("label", {
|
|
28571
|
-
onClick: handleClick,
|
|
28572
|
-
style: {
|
|
28573
|
-
display: 'flex',
|
|
28574
|
-
alignItems: 'center'
|
|
28575
|
-
}
|
|
28576
|
-
}, option.name, " ", React.createElement("br", null), option.description)));
|
|
28577
|
-
})), React.createElement(ButtonWrapper$1, null, React.createElement(Button, {
|
|
28578
|
-
buttonType: ButtonTypes.RPGUIButton,
|
|
28579
|
-
onClick: onClose
|
|
28580
|
-
}, "Cancel"), React.createElement(Button, {
|
|
28581
|
-
buttonType: ButtonTypes.RPGUIButton
|
|
28582
|
-
}, "Select")));
|
|
28583
|
-
};
|
|
28584
|
-
var Title$2 = /*#__PURE__*/styled.h1.withConfig({
|
|
28585
|
-
displayName: "ItemSelector__Title",
|
|
28586
|
-
componentId: "sc-gptoxp-0"
|
|
28587
|
-
})(["font-size:0.6rem;color:yellow !important;"]);
|
|
28588
|
-
var Subtitle$1 = /*#__PURE__*/styled.h1.withConfig({
|
|
28589
|
-
displayName: "ItemSelector__Subtitle",
|
|
28590
|
-
componentId: "sc-gptoxp-1"
|
|
28591
|
-
})(["font-size:0.4rem;color:yellow !important;"]);
|
|
28592
|
-
var RadioInputScroller$1 = /*#__PURE__*/styled.div.withConfig({
|
|
28593
|
-
displayName: "ItemSelector__RadioInputScroller",
|
|
28594
|
-
componentId: "sc-gptoxp-2"
|
|
28595
|
-
})(["padding-left:15px;padding-top:10px;width:100%;margin-top:1rem;align-items:center;margin-left:20px;align-items:flex-start;overflow-y:scroll;height:360px;"]);
|
|
28596
|
-
var SpriteAtlasWrapper$1 = /*#__PURE__*/styled.div.withConfig({
|
|
28597
|
-
displayName: "ItemSelector__SpriteAtlasWrapper",
|
|
28598
|
-
componentId: "sc-gptoxp-3"
|
|
28599
|
-
})(["margin-right:40px;"]);
|
|
28600
|
-
var RadioOptionsWrapper$1 = /*#__PURE__*/styled.div.withConfig({
|
|
28601
|
-
displayName: "ItemSelector__RadioOptionsWrapper",
|
|
28602
|
-
componentId: "sc-gptoxp-4"
|
|
28603
|
-
})(["display:flex;align-items:stretch;margin-bottom:40px;"]);
|
|
28604
|
-
var ButtonWrapper$1 = /*#__PURE__*/styled.div.withConfig({
|
|
28605
|
-
displayName: "ItemSelector__ButtonWrapper",
|
|
28606
|
-
componentId: "sc-gptoxp-5"
|
|
28607
|
-
})(["display:flex;justify-content:space-around;padding-top:20px;width:100%;"]);
|
|
28608
|
-
|
|
28609
28523
|
var ListMenu = function ListMenu(_ref) {
|
|
28610
28524
|
var options = _ref.options,
|
|
28611
28525
|
onSelected = _ref.onSelected,
|
|
@@ -28741,7 +28655,7 @@ var QuestInfo = function QuestInfo(_ref) {
|
|
|
28741
28655
|
onTouchStart: onRightClick
|
|
28742
28656
|
}), React.createElement(QuestContainer, null, React.createElement(TitleContainer$1, {
|
|
28743
28657
|
className: "drag-handler"
|
|
28744
|
-
}, React.createElement(Title$
|
|
28658
|
+
}, React.createElement(Title$2, null, React.createElement(Thumbnail, {
|
|
28745
28659
|
src: quests[currentIndex].thumbnail || img$9
|
|
28746
28660
|
}), quests[currentIndex].title), React.createElement(QuestSplitDiv, null, React.createElement("hr", {
|
|
28747
28661
|
className: "golden"
|
|
@@ -28760,7 +28674,7 @@ var QuestInfo = function QuestInfo(_ref) {
|
|
|
28760
28674
|
}, button.title);
|
|
28761
28675
|
})))) : React.createElement(QuestsContainer, null, React.createElement(QuestContainer, null, React.createElement(TitleContainer$1, {
|
|
28762
28676
|
className: "drag-handler"
|
|
28763
|
-
}, React.createElement(Title$
|
|
28677
|
+
}, React.createElement(Title$2, null, React.createElement(Thumbnail, {
|
|
28764
28678
|
src: quests[0].thumbnail || img$9
|
|
28765
28679
|
}), quests[0].title), React.createElement(QuestSplitDiv, null, React.createElement("hr", {
|
|
28766
28680
|
className: "golden"
|
|
@@ -28807,7 +28721,7 @@ var TitleContainer$1 = /*#__PURE__*/styled.div.withConfig({
|
|
|
28807
28721
|
displayName: "QuestInfo__TitleContainer",
|
|
28808
28722
|
componentId: "sc-15s2boc-6"
|
|
28809
28723
|
})(["width:100%;display:flex;flex-wrap:wrap;justify-content:flex-start;align-items:center;margin-top:1rem;"]);
|
|
28810
|
-
var Title$
|
|
28724
|
+
var Title$2 = /*#__PURE__*/styled.h1.withConfig({
|
|
28811
28725
|
displayName: "QuestInfo__Title",
|
|
28812
28726
|
componentId: "sc-15s2boc-7"
|
|
28813
28727
|
})(["color:white;z-index:22;font-size:", " !important;color:", " !important;"], uiFonts.size.medium, uiColors.yellow);
|
|
@@ -28829,7 +28743,7 @@ var QuestList = function QuestList(_ref) {
|
|
|
28829
28743
|
style: {
|
|
28830
28744
|
width: '100%'
|
|
28831
28745
|
}
|
|
28832
|
-
}, React.createElement(Title$
|
|
28746
|
+
}, React.createElement(Title$3, null, "Quests"), React.createElement("hr", {
|
|
28833
28747
|
className: "golden"
|
|
28834
28748
|
}), React.createElement(QuestListContainer, null, quests ? quests.map(function (quest, i) {
|
|
28835
28749
|
return React.createElement("div", {
|
|
@@ -28850,7 +28764,7 @@ var QuestDraggableContainer$1 = /*#__PURE__*/styled(DraggableContainer).withConf
|
|
|
28850
28764
|
displayName: "QuestList__QuestDraggableContainer",
|
|
28851
28765
|
componentId: "sc-1a2vx6q-0"
|
|
28852
28766
|
})([".container-close{top:10px;right:10px;}.quest-title{text-align:left;margin-left:44px;margin-top:20px;color:yellow;}.quest-desc{margin-top:12px;margin-left:44px;}.rpgui-progress{min-width:80%;margin:0 auto;}"]);
|
|
28853
|
-
var Title$
|
|
28767
|
+
var Title$3 = /*#__PURE__*/styled.h1.withConfig({
|
|
28854
28768
|
displayName: "QuestList__Title",
|
|
28855
28769
|
componentId: "sc-1a2vx6q-1"
|
|
28856
28770
|
})(["z-index:22;font-size:", " !important;color:yellow !important;"], uiFonts.size.medium);
|
|
@@ -28863,6 +28777,15 @@ var NoQuestContainer = /*#__PURE__*/styled.div.withConfig({
|
|
|
28863
28777
|
componentId: "sc-1a2vx6q-3"
|
|
28864
28778
|
})(["text-align:center;p{margin-top:5px;}"]);
|
|
28865
28779
|
|
|
28780
|
+
//@ts-ignore
|
|
28781
|
+
var _RPGUI = RPGUI;
|
|
28782
|
+
var RPGUIRoot = function RPGUIRoot(_ref) {
|
|
28783
|
+
var children = _ref.children;
|
|
28784
|
+
return React.createElement("div", {
|
|
28785
|
+
className: "rpgui-content"
|
|
28786
|
+
}, children);
|
|
28787
|
+
};
|
|
28788
|
+
|
|
28866
28789
|
var InputRadio = function InputRadio(_ref) {
|
|
28867
28790
|
var name = _ref.name,
|
|
28868
28791
|
items = _ref.items,
|
|
@@ -28895,15 +28818,6 @@ var InputRadio = function InputRadio(_ref) {
|
|
|
28895
28818
|
}));
|
|
28896
28819
|
};
|
|
28897
28820
|
|
|
28898
|
-
//@ts-ignore
|
|
28899
|
-
var _RPGUI = RPGUI;
|
|
28900
|
-
var RPGUIRoot = function RPGUIRoot(_ref) {
|
|
28901
|
-
var children = _ref.children;
|
|
28902
|
-
return React.createElement("div", {
|
|
28903
|
-
className: "rpgui-content"
|
|
28904
|
-
}, children);
|
|
28905
|
-
};
|
|
28906
|
-
|
|
28907
28821
|
var RangeSliderType;
|
|
28908
28822
|
(function (RangeSliderType) {
|
|
28909
28823
|
RangeSliderType["Slider"] = "rpgui-slider";
|
|
@@ -29339,7 +29253,7 @@ var TradingMenu = function TradingMenu(_ref) {
|
|
|
29339
29253
|
style: {
|
|
29340
29254
|
width: '100%'
|
|
29341
29255
|
}
|
|
29342
|
-
}, React.createElement(Title$
|
|
29256
|
+
}, React.createElement(Title$4, null, Capitalize(type), " Menu"), React.createElement("hr", {
|
|
29343
29257
|
className: "golden"
|
|
29344
29258
|
})), React.createElement(TradingComponentScrollWrapper, null, traderItems.map(function (tradeItem, index) {
|
|
29345
29259
|
var _qtyMap$get;
|
|
@@ -29352,7 +29266,7 @@ var TradingMenu = function TradingMenu(_ref) {
|
|
|
29352
29266
|
traderItem: tradeItem,
|
|
29353
29267
|
selectedQty: (_qtyMap$get = qtyMap.get(tradeItem.key)) != null ? _qtyMap$get : 0
|
|
29354
29268
|
}));
|
|
29355
|
-
})), React.createElement(GoldWrapper, null, React.createElement("p", null, "Available Gold:"), React.createElement("p", null, "$", characterAvailableGold)), React.createElement(TotalWrapper, null, React.createElement("p", null, "Total:"), React.createElement("p", null, "$", sum)), !hasGoldForSale() ? React.createElement(AlertWrapper, null, React.createElement("p", null, " Sorry, not enough money.")) : React.createElement(GoldWrapper, null, React.createElement("p", null, "Final Gold:"), React.createElement("p", null, "$", getFinalGold())), React.createElement(ButtonWrapper$
|
|
29269
|
+
})), React.createElement(GoldWrapper, null, React.createElement("p", null, "Available Gold:"), React.createElement("p", null, "$", characterAvailableGold)), React.createElement(TotalWrapper, null, React.createElement("p", null, "Total:"), React.createElement("p", null, "$", sum)), !hasGoldForSale() ? React.createElement(AlertWrapper, null, React.createElement("p", null, " Sorry, not enough money.")) : React.createElement(GoldWrapper, null, React.createElement("p", null, "Final Gold:"), React.createElement("p", null, "$", getFinalGold())), React.createElement(ButtonWrapper$1, null, React.createElement(Button, {
|
|
29356
29270
|
buttonType: ButtonTypes.RPGUIButton,
|
|
29357
29271
|
disabled: !hasGoldForSale(),
|
|
29358
29272
|
onClick: function onClick() {
|
|
@@ -29365,7 +29279,7 @@ var TradingMenu = function TradingMenu(_ref) {
|
|
|
29365
29279
|
}
|
|
29366
29280
|
}, "Cancel"))));
|
|
29367
29281
|
};
|
|
29368
|
-
var Title$
|
|
29282
|
+
var Title$4 = /*#__PURE__*/styled.h1.withConfig({
|
|
29369
29283
|
displayName: "TradingMenu__Title",
|
|
29370
29284
|
componentId: "sc-1wjsz1l-0"
|
|
29371
29285
|
})(["z-index:22;font-size:0.6rem;color:yellow !important;"]);
|
|
@@ -29389,7 +29303,7 @@ var AlertWrapper = /*#__PURE__*/styled.div.withConfig({
|
|
|
29389
29303
|
displayName: "TradingMenu__AlertWrapper",
|
|
29390
29304
|
componentId: "sc-1wjsz1l-5"
|
|
29391
29305
|
})(["margin-top:1rem;display:flex;width:100%;justify-content:center;height:20px;p{color:red !important;}"]);
|
|
29392
|
-
var ButtonWrapper$
|
|
29306
|
+
var ButtonWrapper$1 = /*#__PURE__*/styled.div.withConfig({
|
|
29393
29307
|
displayName: "TradingMenu__ButtonWrapper",
|
|
29394
29308
|
componentId: "sc-1wjsz1l-6"
|
|
29395
29309
|
})(["display:flex;justify-content:space-around;padding-top:20px;width:100%;margin-top:1rem;"]);
|
|
@@ -29410,5 +29324,91 @@ var Container$i = /*#__PURE__*/styled.div.withConfig({
|
|
|
29410
29324
|
return props.maxLines;
|
|
29411
29325
|
});
|
|
29412
29326
|
|
|
29413
|
-
|
|
29327
|
+
var ItemSelector = function ItemSelector(_ref) {
|
|
29328
|
+
var atlasIMG = _ref.atlasIMG,
|
|
29329
|
+
atlasJSON = _ref.atlasJSON,
|
|
29330
|
+
options = _ref.options,
|
|
29331
|
+
onClose = _ref.onClose,
|
|
29332
|
+
onSelect = _ref.onSelect;
|
|
29333
|
+
var _useState = useState(),
|
|
29334
|
+
selectedValue = _useState[0],
|
|
29335
|
+
setSelectedValue = _useState[1];
|
|
29336
|
+
var handleClick = function handleClick() {
|
|
29337
|
+
var element = document.querySelector("input[name='test']:checked");
|
|
29338
|
+
var elementValue = element.value;
|
|
29339
|
+
setSelectedValue(elementValue);
|
|
29340
|
+
};
|
|
29341
|
+
useEffect(function () {
|
|
29342
|
+
if (selectedValue) {
|
|
29343
|
+
onSelect(selectedValue);
|
|
29344
|
+
}
|
|
29345
|
+
}, [selectedValue]);
|
|
29346
|
+
return React.createElement(DraggableContainer, {
|
|
29347
|
+
type: RPGUIContainerTypes.Framed,
|
|
29348
|
+
width: "500px",
|
|
29349
|
+
cancelDrag: ".equipment-container-body .arrow-selector",
|
|
29350
|
+
onCloseButton: function onCloseButton() {
|
|
29351
|
+
if (onClose) {
|
|
29352
|
+
onClose();
|
|
29353
|
+
}
|
|
29354
|
+
}
|
|
29355
|
+
}, React.createElement("div", {
|
|
29356
|
+
style: {
|
|
29357
|
+
width: '100%'
|
|
29358
|
+
}
|
|
29359
|
+
}, React.createElement(Title$5, null, 'Harvesting instruments'), React.createElement(Subtitle$1, null, 'Use the tool, you need it'), React.createElement("hr", {
|
|
29360
|
+
className: "golden"
|
|
29361
|
+
})), React.createElement(RadioInputScroller$1, null, options == null ? void 0 : options.map(function (option, index) {
|
|
29362
|
+
return React.createElement(RadioOptionsWrapper$1, {
|
|
29363
|
+
key: index
|
|
29364
|
+
}, React.createElement(SpriteAtlasWrapper$1, null, React.createElement(SpriteFromAtlas, {
|
|
29365
|
+
atlasIMG: atlasIMG,
|
|
29366
|
+
atlasJSON: atlasJSON,
|
|
29367
|
+
spriteKey: option.imageKey,
|
|
29368
|
+
imgScale: 3
|
|
29369
|
+
})), React.createElement("div", null, React.createElement("input", {
|
|
29370
|
+
className: "rpgui-radio",
|
|
29371
|
+
type: "radio",
|
|
29372
|
+
value: option.name,
|
|
29373
|
+
name: "test"
|
|
29374
|
+
}), React.createElement("label", {
|
|
29375
|
+
onClick: handleClick,
|
|
29376
|
+
style: {
|
|
29377
|
+
display: 'flex',
|
|
29378
|
+
alignItems: 'center'
|
|
29379
|
+
}
|
|
29380
|
+
}, option.name, " ", React.createElement("br", null), option.description)));
|
|
29381
|
+
})), React.createElement(ButtonWrapper$2, null, React.createElement(Button, {
|
|
29382
|
+
buttonType: ButtonTypes.RPGUIButton,
|
|
29383
|
+
onClick: onClose
|
|
29384
|
+
}, "Cancel"), React.createElement(Button, {
|
|
29385
|
+
buttonType: ButtonTypes.RPGUIButton
|
|
29386
|
+
}, "Select")));
|
|
29387
|
+
};
|
|
29388
|
+
var Title$5 = /*#__PURE__*/styled.h1.withConfig({
|
|
29389
|
+
displayName: "ItemSelector__Title",
|
|
29390
|
+
componentId: "sc-gptoxp-0"
|
|
29391
|
+
})(["font-size:0.6rem;color:yellow !important;"]);
|
|
29392
|
+
var Subtitle$1 = /*#__PURE__*/styled.h1.withConfig({
|
|
29393
|
+
displayName: "ItemSelector__Subtitle",
|
|
29394
|
+
componentId: "sc-gptoxp-1"
|
|
29395
|
+
})(["font-size:0.4rem;color:yellow !important;"]);
|
|
29396
|
+
var RadioInputScroller$1 = /*#__PURE__*/styled.div.withConfig({
|
|
29397
|
+
displayName: "ItemSelector__RadioInputScroller",
|
|
29398
|
+
componentId: "sc-gptoxp-2"
|
|
29399
|
+
})(["padding-left:15px;padding-top:10px;width:100%;margin-top:1rem;align-items:center;margin-left:20px;align-items:flex-start;overflow-y:scroll;height:360px;"]);
|
|
29400
|
+
var SpriteAtlasWrapper$1 = /*#__PURE__*/styled.div.withConfig({
|
|
29401
|
+
displayName: "ItemSelector__SpriteAtlasWrapper",
|
|
29402
|
+
componentId: "sc-gptoxp-3"
|
|
29403
|
+
})(["margin-right:40px;"]);
|
|
29404
|
+
var RadioOptionsWrapper$1 = /*#__PURE__*/styled.div.withConfig({
|
|
29405
|
+
displayName: "ItemSelector__RadioOptionsWrapper",
|
|
29406
|
+
componentId: "sc-gptoxp-4"
|
|
29407
|
+
})(["display:flex;align-items:stretch;margin-bottom:40px;"]);
|
|
29408
|
+
var ButtonWrapper$2 = /*#__PURE__*/styled.div.withConfig({
|
|
29409
|
+
displayName: "ItemSelector__ButtonWrapper",
|
|
29410
|
+
componentId: "sc-gptoxp-5"
|
|
29411
|
+
})(["display:flex;justify-content:space-around;padding-top:20px;width:100%;"]);
|
|
29412
|
+
|
|
29413
|
+
export { Button, ButtonTypes, CharacterSelection, Chat, CheckButton, CraftBook, DraggableContainer, Dropdown, DropdownSelectorContainer, DynamicText, EquipmentSet, ErrorBoundary, HistoryDialog, ImgSide, Input, InputRadio, ItemContainer, ItemSelector, ItemSlot, ListMenu, NPCDialog, NPCDialogType, NPCMultiDialog, ProgressBar, PropertySelect, QuestInfo, QuestList, QuestionDialog, RPGUIContainer, RPGUIContainerTypes, RPGUIRoot, RangeSlider, RangeSliderType, SkillProgressBar, SkillsContainer, SpriteFromAtlas, TextArea, TimeWidget, TradingMenu, Truncate, _RPGUI, useEventListener };
|
|
29414
29414
|
//# sourceMappingURL=long-bow.esm.js.map
|