@rpg-engine/long-bow 0.8.200 → 0.8.203

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.
@@ -40966,7 +40966,9 @@ var NPCDialogText = function NPCDialogText(_ref) {
40966
40966
  onClose = _ref.onClose,
40967
40967
  onEndStep = _ref.onEndStep,
40968
40968
  onStartStep = _ref.onStartStep,
40969
- type = _ref.type;
40969
+ type = _ref.type,
40970
+ _ref$isTranslated = _ref.isTranslated,
40971
+ isTranslated = _ref$isTranslated === void 0 ? false : _ref$isTranslated;
40970
40972
  var windowSize = useRef([window.innerWidth, window.innerHeight]);
40971
40973
  function maxCharacters(width) {
40972
40974
  // Set the font size to 16 pixels
@@ -40984,6 +40986,9 @@ var NPCDialogText = function NPCDialogText(_ref) {
40984
40986
  var _useState = useState(0),
40985
40987
  chunkIndex = _useState[0],
40986
40988
  setChunkIndex = _useState[1];
40989
+ useEffect(function () {
40990
+ setChunkIndex(0);
40991
+ }, [text]);
40987
40992
  var onHandleSpacePress = function onHandleSpacePress(event) {
40988
40993
  if (event.code === 'Space') {
40989
40994
  goToNextStep();
@@ -41009,7 +41014,14 @@ var NPCDialogText = function NPCDialogText(_ref) {
41009
41014
  var _useState2 = useState(false),
41010
41015
  showGoNextIndicator = _useState2[0],
41011
41016
  setShowGoNextIndicator = _useState2[1];
41012
- return React.createElement(Container$o, null, React.createElement(DynamicText, {
41017
+ useEffect(function () {
41018
+ setShowGoNextIndicator(isTranslated);
41019
+ if (isTranslated) {
41020
+ onStartStep && onStartStep();
41021
+ onEndStep && onEndStep();
41022
+ }
41023
+ }, [chunkIndex, isTranslated, onEndStep, onStartStep, text]);
41024
+ return React.createElement(Container$o, null, isTranslated ? React.createElement(TextContainer$1, null, (textChunks == null ? void 0 : textChunks[chunkIndex]) || '') : React.createElement(DynamicText, {
41013
41025
  text: (textChunks == null ? void 0 : textChunks[chunkIndex]) || '',
41014
41026
  onFinish: function onFinish() {
41015
41027
  setShowGoNextIndicator(true);
@@ -41020,7 +41032,7 @@ var NPCDialogText = function NPCDialogText(_ref) {
41020
41032
  onStartStep && onStartStep();
41021
41033
  }
41022
41034
  }), showGoNextIndicator && React.createElement(PressSpaceIndicator, {
41023
- right: type === NPCDialogType.TextOnly ? '1rem' : '10.5rem',
41035
+ right: type === 'TextOnly' ? '1rem' : '10.5rem',
41024
41036
  src: IS_MOBILE_OR_TABLET ? img$5 : img$6,
41025
41037
  onPointerDown: function onPointerDown() {
41026
41038
  goToNextStep();
@@ -41031,9 +41043,13 @@ var Container$o = /*#__PURE__*/styled.div.withConfig({
41031
41043
  displayName: "NPCDialogText__Container",
41032
41044
  componentId: "sc-1cxkdh9-0"
41033
41045
  })([""]);
41046
+ var TextContainer$1 = /*#__PURE__*/styled.p.withConfig({
41047
+ displayName: "NPCDialogText__TextContainer",
41048
+ componentId: "sc-1cxkdh9-1"
41049
+ })(["font-size:0.7rem !important;color:white;text-shadow:1px 1px 0px #000000;letter-spacing:1.2px;word-break:normal;"]);
41034
41050
  var PressSpaceIndicator = /*#__PURE__*/styled.img.withConfig({
41035
41051
  displayName: "NPCDialogText__PressSpaceIndicator",
41036
- componentId: "sc-1cxkdh9-1"
41052
+ componentId: "sc-1cxkdh9-2"
41037
41053
  })(["position:absolute;right:", ";bottom:1rem;height:20.7px;image-rendering:-webkit-optimize-contrast;"], function (_ref2) {
41038
41054
  var right = _ref2.right;
41039
41055
  return right;
@@ -41230,6 +41246,8 @@ var NPCDialog = function NPCDialog(_ref) {
41230
41246
  type = _ref.type,
41231
41247
  _onClose = _ref.onClose,
41232
41248
  imagePath = _ref.imagePath,
41249
+ _ref$isTranslated = _ref.isTranslated,
41250
+ isTranslated = _ref$isTranslated === void 0 ? false : _ref$isTranslated,
41233
41251
  _ref$isQuestionDialog = _ref.isQuestionDialog,
41234
41252
  isQuestionDialog = _ref$isQuestionDialog === void 0 ? false : _ref$isQuestionDialog,
41235
41253
  questions = _ref.questions,
@@ -41238,7 +41256,7 @@ var NPCDialog = function NPCDialog(_ref) {
41238
41256
  type: RPGUIContainerTypes.FramedGold,
41239
41257
  width: isQuestionDialog ? '600px' : '80%',
41240
41258
  height: '180px'
41241
- }, isQuestionDialog && questions && answers ? React.createElement(React.Fragment, null, React.createElement(TextContainer$1, {
41259
+ }, isQuestionDialog && questions && answers ? React.createElement(React.Fragment, null, React.createElement(TextContainer$2, {
41242
41260
  flex: type === NPCDialogType.TextAndThumbnail ? '70%' : '100%'
41243
41261
  }, React.createElement(QuestionDialog, {
41244
41262
  questions: questions,
@@ -41252,11 +41270,12 @@ var NPCDialog = function NPCDialog(_ref) {
41252
41270
  src: imagePath || img$7
41253
41271
  }))) : React.createElement(React.Fragment, null, React.createElement(Container$q, null, React.createElement(CloseIcon, {
41254
41272
  onPointerDown: _onClose
41255
- }, "X"), React.createElement(TextContainer$1, {
41273
+ }, "X"), React.createElement(TextContainer$2, {
41256
41274
  flex: type === NPCDialogType.TextAndThumbnail ? '70%' : '100%'
41257
41275
  }, React.createElement(NPCDialogText, {
41258
41276
  type: type,
41259
41277
  text: text || 'No text provided.',
41278
+ isTranslated: isTranslated,
41260
41279
  onClose: function onClose() {
41261
41280
  if (_onClose) {
41262
41281
  _onClose();
@@ -41274,7 +41293,7 @@ var CloseIcon = /*#__PURE__*/styled.p.withConfig({
41274
41293
  displayName: "NPCDialog__CloseIcon",
41275
41294
  componentId: "sc-1b4aw74-1"
41276
41295
  })(["position:absolute;top:-1.5rem;right:-0.4rem;cursor:pointer;color:white;font-size:1.1rem !important;"]);
41277
- var TextContainer$1 = /*#__PURE__*/styled.div.withConfig({
41296
+ var TextContainer$2 = /*#__PURE__*/styled.div.withConfig({
41278
41297
  displayName: "NPCDialog__TextContainer",
41279
41298
  componentId: "sc-1b4aw74-2"
41280
41299
  })(["flex:", " 0 0;width:355px;"], function (_ref2) {
@@ -41327,7 +41346,7 @@ var NPCMultiDialog = function NPCMultiDialog(_ref) {
41327
41346
  type: RPGUIContainerTypes.FramedGold,
41328
41347
  width: '50%',
41329
41348
  height: '180px'
41330
- }, React.createElement(React.Fragment, null, React.createElement(Container$r, null, ((_textAndTypeArray$sli = textAndTypeArray[slide]) == null ? void 0 : _textAndTypeArray$sli.imageSide) === 'right' && React.createElement(React.Fragment, null, React.createElement(TextContainer$2, {
41349
+ }, React.createElement(React.Fragment, null, React.createElement(Container$r, null, ((_textAndTypeArray$sli = textAndTypeArray[slide]) == null ? void 0 : _textAndTypeArray$sli.imageSide) === 'right' && React.createElement(React.Fragment, null, React.createElement(TextContainer$3, {
41331
41350
  flex: '70%'
41332
41351
  }, React.createElement(NPCDialogText, {
41333
41352
  onStartStep: function onStartStep() {
@@ -41349,7 +41368,7 @@ var NPCMultiDialog = function NPCMultiDialog(_ref) {
41349
41368
  src: img$6
41350
41369
  })), textAndTypeArray[slide].imageSide === 'left' && React.createElement(React.Fragment, null, React.createElement(ThumbnailContainer$1, null, React.createElement(NPCThumbnail$1, {
41351
41370
  src: textAndTypeArray[slide].imagePath || img$7
41352
- })), React.createElement(TextContainer$2, {
41371
+ })), React.createElement(TextContainer$3, {
41353
41372
  flex: '70%'
41354
41373
  }, React.createElement(NPCDialogText, {
41355
41374
  onStartStep: function onStartStep() {
@@ -41373,7 +41392,7 @@ var Container$r = /*#__PURE__*/styled.div.withConfig({
41373
41392
  displayName: "NPCMultiDialog__Container",
41374
41393
  componentId: "sc-rvu5wg-0"
41375
41394
  })(["display:flex;width:100%;height:100%;box-sizing:border-box;justify-content:center;align-items:flex-start;position:relative;"]);
41376
- var TextContainer$2 = /*#__PURE__*/styled.div.withConfig({
41395
+ var TextContainer$3 = /*#__PURE__*/styled.div.withConfig({
41377
41396
  displayName: "NPCMultiDialog__TextContainer",
41378
41397
  componentId: "sc-rvu5wg-1"
41379
41398
  })(["flex:", " 0 0;width:355px;"], function (_ref2) {
@@ -48784,7 +48803,7 @@ var PartyRow = function PartyRow(_ref) {
48784
48803
  playerQty = _ref.playerQty,
48785
48804
  isInvited = _ref.isInvited,
48786
48805
  partyName = _ref.partyName;
48787
- return React.createElement(PartyWrapper, null, React.createElement(TextContainer$3, null, partyName), React.createElement(TextContainer$3, null, charName), React.createElement(TextContainer$3, null, charClass), React.createElement(TextContainer$3, null, charLevel), React.createElement(TextContainer$3, null, playerQty, "/5"), isInvited ? React.createElement(React.Fragment, null, React.createElement(Button, {
48806
+ return React.createElement(PartyWrapper, null, React.createElement(TextContainer$4, null, partyName), React.createElement(TextContainer$4, null, charName), React.createElement(TextContainer$4, null, charClass), React.createElement(TextContainer$4, null, charLevel), React.createElement(TextContainer$4, null, playerQty, "/5"), isInvited ? React.createElement(React.Fragment, null, React.createElement(Button, {
48788
48807
  buttonType: ButtonTypes.RPGUIButton
48789
48808
  }, "Accept"), React.createElement("div", {
48790
48809
  className: "cancel-button"
@@ -48798,7 +48817,7 @@ var PartyWrapper = /*#__PURE__*/styled.div.withConfig({
48798
48817
  displayName: "PartyRows__PartyWrapper",
48799
48818
  componentId: "sc-xzuhrw-0"
48800
48819
  })(["width:100%;display:flex;align-items:center;justify-content:space-around;.cancel-button{filter:grayscale(0.7);}"]);
48801
- var TextContainer$3 = /*#__PURE__*/styled.div.withConfig({
48820
+ var TextContainer$4 = /*#__PURE__*/styled.div.withConfig({
48802
48821
  displayName: "PartyRows__TextContainer",
48803
48822
  componentId: "sc-xzuhrw-1"
48804
48823
  })(["color:", ";"], uiColors.white);
@@ -48854,15 +48873,15 @@ var PlayersRow = function PlayersRow(_ref) {
48854
48873
  charClass = _ref.charClass,
48855
48874
  charLevel = _ref.charLevel,
48856
48875
  isNotInvited = _ref.isNotInvited;
48857
- return React.createElement(PartyWrapper$1, null, React.createElement(TextContainer$4, null, charName), React.createElement(TextContainer$4, null, charClass), React.createElement(TextContainer$4, null, charLevel), isNotInvited ? React.createElement(React.Fragment, null, React.createElement(Button, {
48876
+ return React.createElement(PartyWrapper$1, null, React.createElement(TextContainer$5, null, charName), React.createElement(TextContainer$5, null, charClass), React.createElement(TextContainer$5, null, charLevel), isNotInvited ? React.createElement(React.Fragment, null, React.createElement(Button, {
48858
48877
  buttonType: ButtonTypes.RPGUIButton
48859
- }, "Invite")) : React.createElement(TextContainer$4, null, "Invited"));
48878
+ }, "Invite")) : React.createElement(TextContainer$5, null, "Invited"));
48860
48879
  };
48861
48880
  var PartyWrapper$1 = /*#__PURE__*/styled.div.withConfig({
48862
48881
  displayName: "PlayersRows__PartyWrapper",
48863
48882
  componentId: "sc-1ji7yc1-0"
48864
48883
  })(["width:100%;display:flex;align-items:center;justify-content:space-around;flex-direction:row;flex:auto;"]);
48865
- var TextContainer$4 = /*#__PURE__*/styled.div.withConfig({
48884
+ var TextContainer$5 = /*#__PURE__*/styled.div.withConfig({
48866
48885
  displayName: "PlayersRows__TextContainer",
48867
48886
  componentId: "sc-1ji7yc1-1"
48868
48887
  })(["color:", ";flex:auto;margin:auto;"], uiColors.white);
@@ -48931,10 +48950,10 @@ var PartyManagerRow = function PartyManagerRow(_ref) {
48931
48950
  onChangeLeader = _ref.onChangeLeader;
48932
48951
  var isCurrentUser = id === userId;
48933
48952
  var canRemove = leaderId === userId || isCurrentUser;
48934
- return React.createElement(PartyWrapper$2, null, React.createElement(TextContainer$5, null, React.createElement(Ellipsis, {
48953
+ return React.createElement(PartyWrapper$2, null, React.createElement(TextContainer$6, null, React.createElement(Ellipsis, {
48935
48954
  maxLines: 1,
48936
48955
  maxWidth: "300px"
48937
- }, charName, " ", isCurrentUser ? '(You)' : '', " ", isLeader ? '(Leader)' : '')), React.createElement(TextContainer$5, null, React.createElement(Ellipsis, {
48956
+ }, charName, " ", isCurrentUser ? '(You)' : '', " ", isLeader ? '(Leader)' : '')), React.createElement(TextContainer$6, null, React.createElement(Ellipsis, {
48938
48957
  maxLines: 1,
48939
48958
  maxWidth: "300px"
48940
48959
  }, charClass)), React.createElement(ButtonContainer$3, null, canRemove && React.createElement(HighlightedText, {
@@ -48951,7 +48970,7 @@ var PartyWrapper$2 = /*#__PURE__*/styled.div.withConfig({
48951
48970
  displayName: "PartyManagerRows__PartyWrapper",
48952
48971
  componentId: "sc-uqajew-0"
48953
48972
  })(["display:grid;grid-template-columns:2fr 1fr 1fr;align-items:center;padding:0.5rem;min-height:50px;box-sizing:border-box;width:100%;border-bottom:1px solid ", ";&:hover{background-color:", ";cursor:pointer;}"], uiColors.darkGray, uiColors.darkGray);
48954
- var TextContainer$5 = /*#__PURE__*/styled.div.withConfig({
48973
+ var TextContainer$6 = /*#__PURE__*/styled.div.withConfig({
48955
48974
  displayName: "PartyManagerRows__TextContainer",
48956
48975
  componentId: "sc-uqajew-1"
48957
48976
  })(["color:", ";overflow:hidden;white-space:nowrap;text-overflow:ellipsis;"], uiColors.white);
@@ -74428,7 +74447,9 @@ var TutorialStepper = /*#__PURE__*/React.memo(function (_ref) {
74428
74447
  var lessons = _ref.lessons,
74429
74448
  onLessonFinish = _ref.onLessonFinish,
74430
74449
  onStepChange = _ref.onStepChange,
74431
- imageStyle = _ref.imageStyle;
74450
+ imageStyle = _ref.imageStyle,
74451
+ _ref$isTranslated = _ref.isTranslated,
74452
+ isTranslated = _ref$isTranslated === void 0 ? false : _ref$isTranslated;
74432
74453
  var generateLessons = useMemo(function () {
74433
74454
  return lessons.map(function (lesson, index) {
74434
74455
  return {
@@ -74459,13 +74480,13 @@ var TutorialStepper = /*#__PURE__*/React.memo(function (_ref) {
74459
74480
  dangerouslySetInnerHTML: {
74460
74481
  __html: lesson.body
74461
74482
  }
74462
- }), lesson.text && React.createElement(DynamicText, {
74483
+ }), lesson.text && (isTranslated ? React.createElement(LessonText, null, lesson.text) : React.createElement(DynamicText, {
74463
74484
  text: lesson.text
74464
- }))),
74485
+ })))),
74465
74486
  id: index
74466
74487
  };
74467
74488
  });
74468
- }, [lessons, imageStyle]);
74489
+ }, [lessons, imageStyle, isTranslated]);
74469
74490
  return React.createElement(Container$T, null, React.createElement(Stepper, {
74470
74491
  steps: generateLessons,
74471
74492
  finalCTAButton: {
@@ -74484,25 +74505,29 @@ var LessonBody = /*#__PURE__*/styled.div.withConfig({
74484
74505
  displayName: "TutorialStepper__LessonBody",
74485
74506
  componentId: "sc-7tgzv2-1"
74486
74507
  })([""]);
74508
+ var LessonText = /*#__PURE__*/styled.p.withConfig({
74509
+ displayName: "TutorialStepper__LessonText",
74510
+ componentId: "sc-7tgzv2-2"
74511
+ })(["font-size:0.7rem !important;color:white;text-shadow:1px 1px 0px #000000;letter-spacing:1.2px;word-break:normal;"]);
74487
74512
  var Container$T = /*#__PURE__*/styled.div.withConfig({
74488
74513
  displayName: "TutorialStepper__Container",
74489
- componentId: "sc-7tgzv2-2"
74514
+ componentId: "sc-7tgzv2-3"
74490
74515
  })(["width:80%;max-width:600px;@media (max-width:600px){width:95%;}"]);
74491
74516
  var LessonFooter = /*#__PURE__*/styled.div.withConfig({
74492
74517
  displayName: "TutorialStepper__LessonFooter",
74493
- componentId: "sc-7tgzv2-3"
74518
+ componentId: "sc-7tgzv2-4"
74494
74519
  })(["margin-top:1rem;"]);
74495
74520
  var LessonImage = /*#__PURE__*/styled.div.withConfig({
74496
74521
  displayName: "TutorialStepper__LessonImage",
74497
- componentId: "sc-7tgzv2-4"
74522
+ componentId: "sc-7tgzv2-5"
74498
74523
  })(["display:flex;justify-content:center;align-items:center;width:100%;max-width:500px;margin:auto;img{width:100%;height:auto;object-fit:contain;border-radius:10px;}"]);
74499
74524
  var LessonTitle = /*#__PURE__*/styled.h1.withConfig({
74500
74525
  displayName: "TutorialStepper__LessonTitle",
74501
- componentId: "sc-7tgzv2-5"
74526
+ componentId: "sc-7tgzv2-6"
74502
74527
  })(["color:", " !important;font-size:0.8rem !important;"], uiColors.yellow);
74503
74528
  var LessonContainer = /*#__PURE__*/styled.div.withConfig({
74504
74529
  displayName: "TutorialStepper__LessonContainer",
74505
- componentId: "sc-7tgzv2-6"
74530
+ componentId: "sc-7tgzv2-7"
74506
74531
  })(["display:flex;flex-direction:column;justify-content:space-between;min-height:200px;p{font-size:0.7rem !important;}"]);
74507
74532
 
74508
74533
  export { ActionButtons, AsyncDropdown, BLUEPRINTS_PER_PAGE, BUY_ORDERS_PER_PAGE, BlueprintSearchModal, Button, ButtonTypes, BuyOrderPanel, BuyOrderRow, CTAButton, CartView, CharacterDetailModal, CharacterListingForm, CharacterListingModal, CharacterMarketplacePanel, CharacterMarketplaceRows, CharacterSelection, CharacterSkinSelectionModal, Chat, ChatDeprecated, ChatRevamp, CheckButton, CheckItem, CircularController, ConfirmModal, CountdownTimer, CraftBook, DCRateStrip, DCWalletContent, DCWalletModal, DailyTasks, DraggableContainer, Dropdown, DropdownSelectorContainer, DynamicText, EquipmentSet, EquipmentSlotSpriteByType, ErrorBoundary, FeaturedBanner, FriendList, GemSelector, GroupedBuyOrderRow, GroupedCharacterMarketplaceRow, GroupedMarketplaceRow, HISTORY_ITEMS_PER_PAGE, HistoryDialog, HistoryPanel, ImageCarousel, ImgSide, InformationCenter, Input, InputRadio, InternalTabs, ItemContainer$1 as ItemContainer, ItemPropertySimpleHandler, ItemQuantitySelectorModal, ItemSelector, ItemSlot, JoystickDPad, Leaderboard, ListMenu, LoginStreakPanel, Marketplace, MarketplaceBuyModal, MarketplaceRows, MarketplaceSettingsPanel, MetadataCollector, MultitabType, MyCharacterListingsPanel, NPCDialog, NPCDialogType, NPCMultiDialog, Pagination, PartyCreate, PartyDashboard, PartyInvite, PartyManager, PartyManagerRow, PartyRow, PaymentMethodModal, PlayersRow, ProgressBar$1 as ProgressBar, PropertySelect, PurchaseSuccess, QuantitySelectorModal, QuestInfo, QuestList, QuestionDialog, RPGUIContainer, RPGUIContainerTypes, RPGUIRoot, RadioCircle$2 as RadioCircle, RadioOption$1 as RadioOption, RadioOptionLabel, RadioOptionSub, RangeSlider, RangeSliderType, SelectArrow, Shortcuts, SimpleImageCarousel, SkillProgressBar, SkillsContainer, SocialModal, Spellbook, SpriteFromAtlas, Stepper, Store, StoreBadges, StoreRedeemSection, TRANSACTION_TYPE_FILTER_ALL, TabBody, Table, TableCell, TableHeader, TableRow, TabsContainer$1 as TabsContainer, TextArea, TimeWidget, Tooltip, TradingMenu, Truncate, TrustBar, TutorialStepper, UserActionLink, _RPGUI, formatQuestStatus, formatQuestText, getMockedPlayersRowsLeader, getMockedPlayersRowsNotLeader, getQuestStatusColor, mockedPartyManager, mockedPartyRows, mockedPlayersRows, mockedPlayersRows2, useEventListener, useStoreCart };