= {
+ about: {
+ [DEFAULT_LOCALE]: lazy(() => import('@/translations/pages/en/About')),
+ ru: lazy(() => import('@/translations/pages/ru/About')),
+ },
+ 'encumbrance-reference': {
+ [DEFAULT_LOCALE]: lazy(
+ () => import('@/translations/pages/en/EncumbranceReference'),
+ ),
+ ru: lazy(() => import('@/translations/pages/ru/EncumbranceReference')),
+ },
+}
+
+export default contentComponents
diff --git a/src/translations/pages/en/About.tsx b/src/translations/pages/en/About.tsx
new file mode 100644
index 00000000..286f7988
--- /dev/null
+++ b/src/translations/pages/en/About.tsx
@@ -0,0 +1,162 @@
+import React from 'react'
+
+const About = () => {
+ return (
+ <>
+
+
+
+ This is an online inventory and equipment tool for the LotFP TTRPG
+ system. It allows tracking of encumbrance and movement speed.
+
+
+ I created the Princess Helper to provide a convenient way to play from
+ a phone or computer, quickly create inventory, and calculate
+ encumbrance and movement speed. The inventory can be shared, it is
+ saved between page refreshes, and there is an export and import
+ feature.
+
+
+ Features list
+
+ -
+ Lists of equipment including armor, weapons, miscellaneous items,
+ and some tips about these items.
+
+ -
+ Calculation
+
+ - Encumbrance
+ - Movement
+ - Terrain and weather adjustments
+
+
+ - Custom equipment entries
+ -
+ Inventory is saved in locale storage and survives the page reload
+
+ - State can be exported and imported
+
+
+ - Languages support
+ - Responsive layout, mobile devices support
+ -
+ Equipment sets
+
+ - By class
+ - Common
+ - Random
+
+
+
+
+
+ The full list of features is available on the{' '}
+
+ project page
+
+ . Currently, it does not include mounts, animals, or firearms. I plan
+ to revisit this after a [short] break.
+
+
+
+
+
+
+ I used the{' '}
+
+ LotFP Rules & Magic Free Version
+ {' '}
+ rulebook and resources from{' '}
+
+ Basic Fantasy RPG
+
+ , specifically the Equipment Emporium (r24) for the details on
+ Miscellaneous Equipment.
+
+
+ I also expanded the Weapons list, adding specific items for Great,
+ Medium, Small, and Minor weapons to enhance clarity.
+
+
+
+
+
+ I'd love to hear that you're using the app in your games.
+
+
+
+ For feedback, bug reports, feature requests, typos in translations
+ (some are machine-translated), or other comments, visit{' '}
+
+ Princess Helpers on GitHub
+
+ .
+ You may suggest translation at the same page. If you
+ find GitHub challenging but have enthusiasm, write to me on Telegram.
+
+
+ If you enjoy the tool, feel free to share it, star it on GitHub, hack
+ it,{' '}
+
+ buy me a coffee
+ {' '}
+ (I will spend that money on role-playing games; your name would be
+ added to the contributors list).
+
+
+ >
+ )
+}
+
+export default About
diff --git a/src/translations/pages/en/EncumbranceReference.tsx b/src/translations/pages/en/EncumbranceReference.tsx
new file mode 100644
index 00000000..dcea048d
--- /dev/null
+++ b/src/translations/pages/en/EncumbranceReference.tsx
@@ -0,0 +1,205 @@
+import React from 'react'
+
+const EncumbranceReference = () => {
+ return (
+ <>
+
+
+ Encumbrance quick reference
+
+ What counts towards encumbrance
+
+ -
+ Armor: Chain and plate armors add encumbrance
+ points but are not included in the regular equipment count.
+
+ -
+ Items: Carrying 6 or more different items adds
+ encumbrance points, with additional points for every 5 items beyond
+ the initial 6. Weapons included.
+
+ -
+ Oversized Items: Great and two-handed weapons, or
+ any item requiring two hands or as tall as the character, count as
+ oversized items and each adds encumbrance points.
+
+ -
+ Coins: 100 any coins count as 1 regular item.
+
+ -
+ Small items of the same type (e.g., arrows, spikes) count as one
+ item.
+
+
+
+ What does not count
+
+ - Worn items like cloaks, jewelry, and backpacks.
+ - Very small items, at the Referee's discretion.
+
+
+ How to count
+
+ -
+ Chain or Plate Armor: +1 or +2 points respectively.
+
+ -
+ Carrying Items: +1 point for every 5 items beyond
+ the first 5. Dwarves can carry an additional 5 items (10 in total)
+ before encumbrance penalties apply.
+
+ -
+ Oversized Items: +1 point per oversized item.
+
+
+
+
+ Show encumbrance and movement tables
+
+
+
+
+ Points |
+ Encumbrance |
+ Exploration |
+ Combat |
+ Run |
+
+
+
+
+ 0–1 |
+ Unencumbered |
+ 120' |
+ 40' |
+ 120' |
+
+
+ 2 |
+ Lightly Encumbered |
+ 90' |
+ 30' |
+ 90' |
+
+
+ 3 |
+ Heavily Encumbered |
+ 60' |
+ 20' |
+ 60' |
+
+
+ 4 |
+ Severely Encumbered |
+ 30' |
+ 10' |
+ 30' |
+
+
+ 5+ |
+ Over Encumbered |
+ 0' |
+ 0' |
+ 0' |
+
+
+
+
+
+ The terrain type alters the rate:
+
+
+
+
+ Terrain |
+ Adjustment |
+
+
+
+
+ Jungle, Mountains, Swamp |
+ ×⅓ |
+
+
+ Desert, Forest, Hills |
+ ×½ |
+
+
+ Clear, Plains, Trail |
+ ×⅔ |
+
+
+ Road |
+ ×1 |
+
+
+
+
+
+ Bad weather also affects travel:
+
+
+
+
+ Conditions |
+ Adjustment |
+
+
+
+
+ High Winds or Precipitation |
+ ×½ |
+
+
+ Storm Conditions |
+ ×⅓ |
+
+
+
+
+
+
+ Effects
+
+ -
+ Specialist must be unencumbered to use any class
+ abilities involving movement without penalty, or suffer a one point
+ skill penalty for level of encumbrance.
+
+ -
+ Magic-Users cannot cast spells if they are more
+ than Lightly encumbered. Elves cannot cast spells
+ if they are more than Heavily encumbered.
+
+
+
+
+
+ Encumbrance Units and Points:
+
+ -
+ Encumbrance Points: These are used to determine the
+ encumbrance level of a character. Taken from the core book.
+
+ -
+ Encumbrance Units: Smaller divisions of encumbrance
+ points, with 1 encumbrance unit being 1/5 of a point. All elements
+ in the system have a weight expressed in e.u.
+
+
+
+ Special Rules:
+
+ -
+ Coins Encumbrance: 100 coins count as 1 regular
+ item or 1 e.u. This option can be disabled in the Wallet settings.
+
+
+
+ >
+ )
+}
+
+export default EncumbranceReference
diff --git a/src/translations/pages/ru/About.tsx b/src/translations/pages/ru/About.tsx
new file mode 100644
index 00000000..18e3fd3f
--- /dev/null
+++ b/src/translations/pages/ru/About.tsx
@@ -0,0 +1,135 @@
+import React from 'react'
+
+const About = () => {
+ return (
+ <>
+
+
+
+ Учёт инвентаря и снаряжения, нагрузки и скорости в НРИ-системе LotFP.
+
+
+ Я написал Princess Helpers, чтобы был удобный способ играть с телефона
+ или компьютера, быстро создавать инвентарь и рассчитывать нагрузку и
+ скорость передвижения. Инвентарь можно расшарить, он сохраняется между
+ обновлениями страницы, есть функция экспорта и импорта.
+
+
+ Список функций
+
+ -
+ Списки снаряжения, включая броню, оружие, различные предметы, а
+ также некоторые детали этих предметов.
+
+ -
+ Подсчёт
+
+ - Нагрузка
+ - Передвижение
+ - Корректировки для местности и погоды
+
+
+ - Кастомные предметы для инвентаря
+ -
+ Инвентарь сохраняется в локальном хранилище браузера и сохраняется
+ при перезагрузке страницы
+
+
+ - Поддержка языков
+ - Адаптивный дизайн, поддержка мобильных устройств
+ -
+ Наборы снаряжения
+
+ - По классу
+ - Общие
+ - Случайные
+
+
+
+
+
+ Полный список функций доступен на{' '}
+
+ странице проекта
+
+ . Сейчас нет поддержки вьючных животных и езды верхом, а также
+ огнестрельного оружия. Я планирую вернуться к этому после некоторого
+ перерыва.
+
+
+
+
+
+
+ Дайте знать, если вы используете приложение в своих играх, я буду рад
+ услышать обратную связь.
+
+
+
+ Для обратной связи, сообщений об ошибках, запросов, опечаток в
+ переводах (некоторый перевод — машинный, я мог что-то пропустить) или
+ других комментариев:{' '}
+
+ Princess Helpers на GitHub
+
+ .
+ Вы можете предложить перевод на той же странице. Если
+ тяжело с GitHub, но есть энтузиазм, напишите в Телеграме.
+
+
+ Если вам нравится проект, поделитесь им, поставьте звезду на GitHub,
+ хакните его,{' '}
+
+ купите мне кофе
+ {' '}
+ (я потрачу эти деньги на настольные ролевые игры; ваше имя будет
+ добавлено в почётный список где-нибудь здесь).
+
+
+ >
+ )
+}
+
+export default About
diff --git a/src/translations/pages/ru/EncumbranceReference.tsx b/src/translations/pages/ru/EncumbranceReference.tsx
new file mode 100644
index 00000000..dcea048d
--- /dev/null
+++ b/src/translations/pages/ru/EncumbranceReference.tsx
@@ -0,0 +1,205 @@
+import React from 'react'
+
+const EncumbranceReference = () => {
+ return (
+ <>
+
+
+ Encumbrance quick reference
+
+ What counts towards encumbrance
+
+ -
+ Armor: Chain and plate armors add encumbrance
+ points but are not included in the regular equipment count.
+
+ -
+ Items: Carrying 6 or more different items adds
+ encumbrance points, with additional points for every 5 items beyond
+ the initial 6. Weapons included.
+
+ -
+ Oversized Items: Great and two-handed weapons, or
+ any item requiring two hands or as tall as the character, count as
+ oversized items and each adds encumbrance points.
+
+ -
+ Coins: 100 any coins count as 1 regular item.
+
+ -
+ Small items of the same type (e.g., arrows, spikes) count as one
+ item.
+
+
+
+ What does not count
+
+ - Worn items like cloaks, jewelry, and backpacks.
+ - Very small items, at the Referee's discretion.
+
+
+ How to count
+
+ -
+ Chain or Plate Armor: +1 or +2 points respectively.
+
+ -
+ Carrying Items: +1 point for every 5 items beyond
+ the first 5. Dwarves can carry an additional 5 items (10 in total)
+ before encumbrance penalties apply.
+
+ -
+ Oversized Items: +1 point per oversized item.
+
+
+
+
+ Show encumbrance and movement tables
+
+
+
+
+ Points |
+ Encumbrance |
+ Exploration |
+ Combat |
+ Run |
+
+
+
+
+ 0–1 |
+ Unencumbered |
+ 120' |
+ 40' |
+ 120' |
+
+
+ 2 |
+ Lightly Encumbered |
+ 90' |
+ 30' |
+ 90' |
+
+
+ 3 |
+ Heavily Encumbered |
+ 60' |
+ 20' |
+ 60' |
+
+
+ 4 |
+ Severely Encumbered |
+ 30' |
+ 10' |
+ 30' |
+
+
+ 5+ |
+ Over Encumbered |
+ 0' |
+ 0' |
+ 0' |
+
+
+
+
+
+ The terrain type alters the rate:
+
+
+
+
+ Terrain |
+ Adjustment |
+
+
+
+
+ Jungle, Mountains, Swamp |
+ ×⅓ |
+
+
+ Desert, Forest, Hills |
+ ×½ |
+
+
+ Clear, Plains, Trail |
+ ×⅔ |
+
+
+ Road |
+ ×1 |
+
+
+
+
+
+ Bad weather also affects travel:
+
+
+
+
+ Conditions |
+ Adjustment |
+
+
+
+
+ High Winds or Precipitation |
+ ×½ |
+
+
+ Storm Conditions |
+ ×⅓ |
+
+
+
+
+
+
+ Effects
+
+ -
+ Specialist must be unencumbered to use any class
+ abilities involving movement without penalty, or suffer a one point
+ skill penalty for level of encumbrance.
+
+ -
+ Magic-Users cannot cast spells if they are more
+ than Lightly encumbered. Elves cannot cast spells
+ if they are more than Heavily encumbered.
+
+
+
+
+
+ Encumbrance Units and Points:
+
+ -
+ Encumbrance Points: These are used to determine the
+ encumbrance level of a character. Taken from the core book.
+
+ -
+ Encumbrance Units: Smaller divisions of encumbrance
+ points, with 1 encumbrance unit being 1/5 of a point. All elements
+ in the system have a weight expressed in e.u.
+
+
+
+ Special Rules:
+
+ -
+ Coins Encumbrance: 100 coins count as 1 regular
+ item or 1 e.u. This option can be disabled in the Wallet settings.
+
+
+
+ >
+ )
+}
+
+export default EncumbranceReference
diff --git a/src/translations/utils.ts b/src/translations/utils.ts
index ee228edf..b4ca2e89 100644
--- a/src/translations/utils.ts
+++ b/src/translations/utils.ts
@@ -1,7 +1,11 @@
import type { Messages } from '@lingui/core'
import { i18n } from '@lingui/core'
import { useRouter } from 'next/router'
-import { useEffect } from 'react'
+import { type ComponentType, useEffect } from 'react'
+
+import type { LOCALE_SHORT } from '@/translations/languages'
+import { DEFAULT_LOCALE } from '@/translations/languages'
+import contentComponents from '@/translations/pages/contentComponents'
export async function loadCatalog(locale: string) {
const catalog = await import(`@lingui/loader!./locales/${locale}.po`)
@@ -34,3 +38,15 @@ export function useLinguiInit(messages: Messages) {
return i18n
}
+
+export const getTranslatedPageContent = (
+ pageName: string,
+ locale: LOCALE_SHORT,
+): ComponentType => {
+ const pageEntry = contentComponents[pageName]
+ if (!pageEntry) {
+ throw new Error(`Unknown page name: ${pageName}`)
+ }
+
+ return (pageEntry[locale] || pageEntry[DEFAULT_LOCALE]) as ComponentType
+}