@magmamath/students-features 1.8.4 → 1.8.5-rc.1
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/commonjs/features/chatbot/components/ChatInput/FreeText/ChatTextInput.js.map +1 -1
- package/dist/commonjs/features/profile/Profile.js +90 -0
- package/dist/commonjs/features/profile/Profile.js.map +1 -0
- package/dist/commonjs/features/profile/components/actions/ProfileActions.js +70 -0
- package/dist/commonjs/features/profile/components/actions/ProfileActions.js.map +1 -0
- package/dist/commonjs/features/profile/components/cards/ProfileCard.js +57 -0
- package/dist/commonjs/features/profile/components/cards/ProfileCard.js.map +1 -0
- package/dist/commonjs/features/profile/components/info/AccountInfoCard.js +91 -0
- package/dist/commonjs/features/profile/components/info/AccountInfoCard.js.map +1 -0
- package/dist/commonjs/features/profile/components/modals/JoinClassModal.js +190 -0
- package/dist/commonjs/features/profile/components/modals/JoinClassModal.js.map +1 -0
- package/dist/commonjs/features/profile/components/modals/LogoutConfirmModal.js +61 -0
- package/dist/commonjs/features/profile/components/modals/LogoutConfirmModal.js.map +1 -0
- package/dist/commonjs/features/profile/components/modals/TranslationLanguageModal.js +128 -0
- package/dist/commonjs/features/profile/components/modals/TranslationLanguageModal.js.map +1 -0
- package/dist/commonjs/features/profile/components/settings/LanguageSettingsCard.js +22 -0
- package/dist/commonjs/features/profile/components/settings/LanguageSettingsCard.js.map +1 -0
- package/dist/commonjs/features/profile/components/settings/PreferencesCard.js +69 -0
- package/dist/commonjs/features/profile/components/settings/PreferencesCard.js.map +1 -0
- package/dist/commonjs/features/profile/components/settings/SettingRow.js +48 -0
- package/dist/commonjs/features/profile/components/settings/SettingRow.js.map +1 -0
- package/dist/commonjs/features/profile/components/settings/TextSettingsCard.js +77 -0
- package/dist/commonjs/features/profile/components/settings/TextSettingsCard.js.map +1 -0
- package/dist/commonjs/features/profile/components/settings/TextSizeSlider.js +119 -0
- package/dist/commonjs/features/profile/components/settings/TextSizeSlider.js.map +1 -0
- package/dist/commonjs/features/profile/components/settings/TextToSpeechRow.js +37 -0
- package/dist/commonjs/features/profile/components/settings/TextToSpeechRow.js.map +1 -0
- package/dist/commonjs/features/profile/components/settings/TranslationLanguageRow.js +62 -0
- package/dist/commonjs/features/profile/components/settings/TranslationLanguageRow.js.map +1 -0
- package/dist/commonjs/features/profile/context/ProfileContext.js +18 -0
- package/dist/commonjs/features/profile/context/ProfileContext.js.map +1 -0
- package/dist/commonjs/features/profile/index.js +80 -0
- package/dist/commonjs/features/profile/index.js.map +1 -0
- package/dist/commonjs/features/profile/model/ProfileApi.js +15 -0
- package/dist/commonjs/features/profile/model/ProfileApi.js.map +1 -0
- package/dist/commonjs/features/profile/model/ProfileJoinClassModel.js +60 -0
- package/dist/commonjs/features/profile/model/ProfileJoinClassModel.js.map +1 -0
- package/dist/commonjs/features/profile/model/ProfileLanguageModel.js +30 -0
- package/dist/commonjs/features/profile/model/ProfileLanguageModel.js.map +1 -0
- package/dist/commonjs/features/profile/model/ProfileModel.js +53 -0
- package/dist/commonjs/features/profile/model/ProfileModel.js.map +1 -0
- package/dist/commonjs/features/profile/model/profileModal.types.js +6 -0
- package/dist/commonjs/features/profile/model/profileModal.types.js.map +1 -0
- package/dist/commonjs/features/profile/shared/JoinClassError.js +16 -0
- package/dist/commonjs/features/profile/shared/JoinClassError.js.map +1 -0
- package/dist/commonjs/features/profile/shared/profile.constants.js +29 -0
- package/dist/commonjs/features/profile/shared/profile.constants.js.map +1 -0
- package/dist/commonjs/features/profile/shared/profile.helpers.js +40 -0
- package/dist/commonjs/features/profile/shared/profile.helpers.js.map +1 -0
- package/dist/commonjs/features/profile/shared/profile.types.js +6 -0
- package/dist/commonjs/features/profile/shared/profile.types.js.map +1 -0
- package/dist/commonjs/index.js +12 -0
- package/dist/commonjs/index.js.map +1 -1
- package/dist/commonjs/shared/hooks/useKeyboardOffset.js +54 -0
- package/dist/commonjs/shared/hooks/useKeyboardOffset.js.map +1 -0
- package/dist/module/features/chatbot/components/ChatInput/FreeText/ChatTextInput.js.map +1 -1
- package/dist/module/features/profile/Profile.js +84 -0
- package/dist/module/features/profile/Profile.js.map +1 -0
- package/dist/module/features/profile/components/actions/ProfileActions.js +64 -0
- package/dist/module/features/profile/components/actions/ProfileActions.js.map +1 -0
- package/dist/module/features/profile/components/cards/ProfileCard.js +51 -0
- package/dist/module/features/profile/components/cards/ProfileCard.js.map +1 -0
- package/dist/module/features/profile/components/info/AccountInfoCard.js +85 -0
- package/dist/module/features/profile/components/info/AccountInfoCard.js.map +1 -0
- package/dist/module/features/profile/components/modals/JoinClassModal.js +183 -0
- package/dist/module/features/profile/components/modals/JoinClassModal.js.map +1 -0
- package/dist/module/features/profile/components/modals/LogoutConfirmModal.js +55 -0
- package/dist/module/features/profile/components/modals/LogoutConfirmModal.js.map +1 -0
- package/dist/module/features/profile/components/modals/TranslationLanguageModal.js +122 -0
- package/dist/module/features/profile/components/modals/TranslationLanguageModal.js.map +1 -0
- package/dist/module/features/profile/components/settings/LanguageSettingsCard.js +16 -0
- package/dist/module/features/profile/components/settings/LanguageSettingsCard.js.map +1 -0
- package/dist/module/features/profile/components/settings/PreferencesCard.js +63 -0
- package/dist/module/features/profile/components/settings/PreferencesCard.js.map +1 -0
- package/dist/module/features/profile/components/settings/SettingRow.js +42 -0
- package/dist/module/features/profile/components/settings/SettingRow.js.map +1 -0
- package/dist/module/features/profile/components/settings/TextSettingsCard.js +71 -0
- package/dist/module/features/profile/components/settings/TextSettingsCard.js.map +1 -0
- package/dist/module/features/profile/components/settings/TextSizeSlider.js +112 -0
- package/dist/module/features/profile/components/settings/TextSizeSlider.js.map +1 -0
- package/dist/module/features/profile/components/settings/TextToSpeechRow.js +31 -0
- package/dist/module/features/profile/components/settings/TextToSpeechRow.js.map +1 -0
- package/dist/module/features/profile/components/settings/TranslationLanguageRow.js +56 -0
- package/dist/module/features/profile/components/settings/TranslationLanguageRow.js.map +1 -0
- package/dist/module/features/profile/context/ProfileContext.js +13 -0
- package/dist/module/features/profile/context/ProfileContext.js.map +1 -0
- package/dist/module/features/profile/index.js +11 -0
- package/dist/module/features/profile/index.js.map +1 -0
- package/dist/module/features/profile/model/ProfileApi.js +10 -0
- package/dist/module/features/profile/model/ProfileApi.js.map +1 -0
- package/dist/module/features/profile/model/ProfileJoinClassModel.js +55 -0
- package/dist/module/features/profile/model/ProfileJoinClassModel.js.map +1 -0
- package/dist/module/features/profile/model/ProfileLanguageModel.js +25 -0
- package/dist/module/features/profile/model/ProfileLanguageModel.js.map +1 -0
- package/dist/module/features/profile/model/ProfileModel.js +48 -0
- package/dist/module/features/profile/model/ProfileModel.js.map +1 -0
- package/dist/module/features/profile/model/profileModal.types.js +4 -0
- package/dist/module/features/profile/model/profileModal.types.js.map +1 -0
- package/dist/module/features/profile/shared/JoinClassError.js +11 -0
- package/dist/module/features/profile/shared/JoinClassError.js.map +1 -0
- package/dist/module/features/profile/shared/profile.constants.js +25 -0
- package/dist/module/features/profile/shared/profile.constants.js.map +1 -0
- package/dist/module/features/profile/shared/profile.helpers.js +32 -0
- package/dist/module/features/profile/shared/profile.helpers.js.map +1 -0
- package/dist/module/features/profile/shared/profile.types.js +4 -0
- package/dist/module/features/profile/shared/profile.types.js.map +1 -0
- package/dist/module/index.js +1 -0
- package/dist/module/index.js.map +1 -1
- package/dist/module/shared/hooks/useKeyboardOffset.js +49 -0
- package/dist/module/shared/hooks/useKeyboardOffset.js.map +1 -0
- package/dist/typescript/commonjs/features/chatbot/components/ChatInput/FreeText/ChatTextInput.d.ts.map +1 -1
- package/dist/typescript/commonjs/features/profile/Profile.d.ts +6 -0
- package/dist/typescript/commonjs/features/profile/Profile.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/__tests__/ProfileModel.test.d.ts +2 -0
- package/dist/typescript/commonjs/features/profile/__tests__/ProfileModel.test.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/__tests__/profile.helpers.test.d.ts +2 -0
- package/dist/typescript/commonjs/features/profile/__tests__/profile.helpers.test.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/actions/ProfileActions.d.ts +3 -0
- package/dist/typescript/commonjs/features/profile/components/actions/ProfileActions.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/cards/ProfileCard.d.ts +10 -0
- package/dist/typescript/commonjs/features/profile/components/cards/ProfileCard.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/info/AccountInfoCard.d.ts +3 -0
- package/dist/typescript/commonjs/features/profile/components/info/AccountInfoCard.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/modals/JoinClassModal.d.ts +4 -0
- package/dist/typescript/commonjs/features/profile/components/modals/JoinClassModal.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/modals/LogoutConfirmModal.d.ts +4 -0
- package/dist/typescript/commonjs/features/profile/components/modals/LogoutConfirmModal.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/modals/TranslationLanguageModal.d.ts +4 -0
- package/dist/typescript/commonjs/features/profile/components/modals/TranslationLanguageModal.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/settings/LanguageSettingsCard.d.ts +3 -0
- package/dist/typescript/commonjs/features/profile/components/settings/LanguageSettingsCard.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/settings/PreferencesCard.d.ts +3 -0
- package/dist/typescript/commonjs/features/profile/components/settings/PreferencesCard.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/settings/SettingRow.d.ts +11 -0
- package/dist/typescript/commonjs/features/profile/components/settings/SettingRow.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/settings/TextSettingsCard.d.ts +3 -0
- package/dist/typescript/commonjs/features/profile/components/settings/TextSettingsCard.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/settings/TextSizeSlider.d.ts +8 -0
- package/dist/typescript/commonjs/features/profile/components/settings/TextSizeSlider.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/settings/TextToSpeechRow.d.ts +3 -0
- package/dist/typescript/commonjs/features/profile/components/settings/TextToSpeechRow.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/components/settings/TranslationLanguageRow.d.ts +3 -0
- package/dist/typescript/commonjs/features/profile/components/settings/TranslationLanguageRow.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/context/ProfileContext.d.ts +13 -0
- package/dist/typescript/commonjs/features/profile/context/ProfileContext.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/index.d.ts +12 -0
- package/dist/typescript/commonjs/features/profile/index.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/model/ProfileApi.d.ts +11 -0
- package/dist/typescript/commonjs/features/profile/model/ProfileApi.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/model/ProfileJoinClassModel.d.ts +14 -0
- package/dist/typescript/commonjs/features/profile/model/ProfileJoinClassModel.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/model/ProfileLanguageModel.d.ts +13 -0
- package/dist/typescript/commonjs/features/profile/model/ProfileLanguageModel.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/model/ProfileModel.d.ts +26 -0
- package/dist/typescript/commonjs/features/profile/model/ProfileModel.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/model/profileModal.types.d.ts +14 -0
- package/dist/typescript/commonjs/features/profile/model/profileModal.types.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/shared/JoinClassError.d.ts +5 -0
- package/dist/typescript/commonjs/features/profile/shared/JoinClassError.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/shared/profile.constants.d.ts +20 -0
- package/dist/typescript/commonjs/features/profile/shared/profile.constants.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/shared/profile.helpers.d.ts +6 -0
- package/dist/typescript/commonjs/features/profile/shared/profile.helpers.d.ts.map +1 -0
- package/dist/typescript/commonjs/features/profile/shared/profile.types.d.ts +27 -0
- package/dist/typescript/commonjs/features/profile/shared/profile.types.d.ts.map +1 -0
- package/dist/typescript/commonjs/index.d.ts +1 -0
- package/dist/typescript/commonjs/index.d.ts.map +1 -1
- package/dist/typescript/commonjs/shared/hooks/useKeyboardOffset.d.ts +11 -0
- package/dist/typescript/commonjs/shared/hooks/useKeyboardOffset.d.ts.map +1 -0
- package/dist/typescript/module/features/chatbot/components/ChatInput/FreeText/ChatTextInput.d.ts.map +1 -1
- package/dist/typescript/module/features/profile/Profile.d.ts +6 -0
- package/dist/typescript/module/features/profile/Profile.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/__tests__/ProfileModel.test.d.ts +2 -0
- package/dist/typescript/module/features/profile/__tests__/ProfileModel.test.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/__tests__/profile.helpers.test.d.ts +2 -0
- package/dist/typescript/module/features/profile/__tests__/profile.helpers.test.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/actions/ProfileActions.d.ts +3 -0
- package/dist/typescript/module/features/profile/components/actions/ProfileActions.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/cards/ProfileCard.d.ts +10 -0
- package/dist/typescript/module/features/profile/components/cards/ProfileCard.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/info/AccountInfoCard.d.ts +3 -0
- package/dist/typescript/module/features/profile/components/info/AccountInfoCard.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/modals/JoinClassModal.d.ts +4 -0
- package/dist/typescript/module/features/profile/components/modals/JoinClassModal.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/modals/LogoutConfirmModal.d.ts +4 -0
- package/dist/typescript/module/features/profile/components/modals/LogoutConfirmModal.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/modals/TranslationLanguageModal.d.ts +4 -0
- package/dist/typescript/module/features/profile/components/modals/TranslationLanguageModal.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/settings/LanguageSettingsCard.d.ts +3 -0
- package/dist/typescript/module/features/profile/components/settings/LanguageSettingsCard.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/settings/PreferencesCard.d.ts +3 -0
- package/dist/typescript/module/features/profile/components/settings/PreferencesCard.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/settings/SettingRow.d.ts +11 -0
- package/dist/typescript/module/features/profile/components/settings/SettingRow.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/settings/TextSettingsCard.d.ts +3 -0
- package/dist/typescript/module/features/profile/components/settings/TextSettingsCard.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/settings/TextSizeSlider.d.ts +8 -0
- package/dist/typescript/module/features/profile/components/settings/TextSizeSlider.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/settings/TextToSpeechRow.d.ts +3 -0
- package/dist/typescript/module/features/profile/components/settings/TextToSpeechRow.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/components/settings/TranslationLanguageRow.d.ts +3 -0
- package/dist/typescript/module/features/profile/components/settings/TranslationLanguageRow.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/context/ProfileContext.d.ts +13 -0
- package/dist/typescript/module/features/profile/context/ProfileContext.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/index.d.ts +12 -0
- package/dist/typescript/module/features/profile/index.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/model/ProfileApi.d.ts +11 -0
- package/dist/typescript/module/features/profile/model/ProfileApi.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/model/ProfileJoinClassModel.d.ts +14 -0
- package/dist/typescript/module/features/profile/model/ProfileJoinClassModel.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/model/ProfileLanguageModel.d.ts +13 -0
- package/dist/typescript/module/features/profile/model/ProfileLanguageModel.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/model/ProfileModel.d.ts +26 -0
- package/dist/typescript/module/features/profile/model/ProfileModel.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/model/profileModal.types.d.ts +14 -0
- package/dist/typescript/module/features/profile/model/profileModal.types.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/shared/JoinClassError.d.ts +5 -0
- package/dist/typescript/module/features/profile/shared/JoinClassError.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/shared/profile.constants.d.ts +20 -0
- package/dist/typescript/module/features/profile/shared/profile.constants.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/shared/profile.helpers.d.ts +6 -0
- package/dist/typescript/module/features/profile/shared/profile.helpers.d.ts.map +1 -0
- package/dist/typescript/module/features/profile/shared/profile.types.d.ts +27 -0
- package/dist/typescript/module/features/profile/shared/profile.types.d.ts.map +1 -0
- package/dist/typescript/module/index.d.ts +1 -0
- package/dist/typescript/module/index.d.ts.map +1 -1
- package/dist/typescript/module/shared/hooks/useKeyboardOffset.d.ts +11 -0
- package/dist/typescript/module/shared/hooks/useKeyboardOffset.d.ts.map +1 -0
- package/package.json +4 -2
- package/src/features/chatbot/components/ChatInput/FreeText/ChatTextInput.tsx +0 -1
- package/src/features/profile/Profile.tsx +83 -0
- package/src/features/profile/__tests__/ProfileModel.test.ts +99 -0
- package/src/features/profile/__tests__/profile.helpers.test.ts +57 -0
- package/src/features/profile/components/actions/ProfileActions.tsx +68 -0
- package/src/features/profile/components/cards/ProfileCard.tsx +53 -0
- package/src/features/profile/components/info/AccountInfoCard.tsx +74 -0
- package/src/features/profile/components/modals/JoinClassModal.tsx +180 -0
- package/src/features/profile/components/modals/LogoutConfirmModal.tsx +64 -0
- package/src/features/profile/components/modals/TranslationLanguageModal.tsx +126 -0
- package/src/features/profile/components/settings/LanguageSettingsCard.tsx +16 -0
- package/src/features/profile/components/settings/PreferencesCard.tsx +67 -0
- package/src/features/profile/components/settings/SettingRow.tsx +42 -0
- package/src/features/profile/components/settings/TextSettingsCard.tsx +64 -0
- package/src/features/profile/components/settings/TextSizeSlider.tsx +117 -0
- package/src/features/profile/components/settings/TextToSpeechRow.tsx +29 -0
- package/src/features/profile/components/settings/TranslationLanguageRow.tsx +60 -0
- package/src/features/profile/context/ProfileContext.tsx +24 -0
- package/src/features/profile/index.ts +11 -0
- package/src/features/profile/model/ProfileApi.ts +23 -0
- package/src/features/profile/model/ProfileJoinClassModel.ts +58 -0
- package/src/features/profile/model/ProfileLanguageModel.ts +26 -0
- package/src/features/profile/model/ProfileModel.ts +57 -0
- package/src/features/profile/model/profileModal.types.ts +16 -0
- package/src/features/profile/shared/JoinClassError.ts +7 -0
- package/src/features/profile/shared/profile.constants.ts +23 -0
- package/src/features/profile/shared/profile.helpers.ts +36 -0
- package/src/features/profile/shared/profile.types.ts +34 -0
- package/src/i18n/.generated/schema.json +9 -1
- package/src/index.ts +1 -0
- package/src/shared/hooks/useKeyboardOffset.ts +57 -0
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.TranslationLanguageRow = void 0;
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
|
+
var _effectorReact = require("effector-react");
|
|
9
|
+
var _reactNative = require("react-native");
|
|
10
|
+
var _reactNativeUi = require("@magmamath/react-native-ui");
|
|
11
|
+
var _studentsQa = require("@magmamath/students-qa");
|
|
12
|
+
var _i18n = require("../../../../i18n/i18n.js");
|
|
13
|
+
var _ProfileContext = require("../../context/ProfileContext.js");
|
|
14
|
+
var _SettingRow = require("./SettingRow.js");
|
|
15
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
16
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
17
|
+
const ICON_SIZE = 20;
|
|
18
|
+
const TranslationLanguageRow = () => {
|
|
19
|
+
const t = (0, _i18n.useText)();
|
|
20
|
+
const {
|
|
21
|
+
model,
|
|
22
|
+
onOpenTranslationModal
|
|
23
|
+
} = (0, _ProfileContext.useProfile)();
|
|
24
|
+
const settings = (0, _effectorReact.useUnit)(model.$settings);
|
|
25
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_SettingRow.SettingRow, {
|
|
26
|
+
icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeUi.GlobeIcon, {
|
|
27
|
+
size: ICON_SIZE,
|
|
28
|
+
color: _reactNativeUi.COLORS.NEUTRAL_7
|
|
29
|
+
}),
|
|
30
|
+
label: t('profile.translationLanguage'),
|
|
31
|
+
style: styles.settingRow,
|
|
32
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeUi.FilterDropdown, {
|
|
33
|
+
variant: _reactNativeUi.FilterDropdownVariant.SECONDARY,
|
|
34
|
+
size: _reactNativeUi.FilterDropdownSize.MEDIUM,
|
|
35
|
+
value: settings.translationLanguage ?? undefined,
|
|
36
|
+
placeholder: t('profile.selectLanguage'),
|
|
37
|
+
disabled: settings.isTranslationLocked,
|
|
38
|
+
onPress: onOpenTranslationModal,
|
|
39
|
+
accessibilityLabel: t('profile.translationLanguage'),
|
|
40
|
+
testID: _studentsQa.TEST_IDS.PROFILE_LANGUAGE_SELECTOR,
|
|
41
|
+
style: {
|
|
42
|
+
text: styles.filterLabel,
|
|
43
|
+
container: styles.filterContainer
|
|
44
|
+
}
|
|
45
|
+
})
|
|
46
|
+
});
|
|
47
|
+
};
|
|
48
|
+
exports.TranslationLanguageRow = TranslationLanguageRow;
|
|
49
|
+
const styles = _reactNative.StyleSheet.create({
|
|
50
|
+
settingRow: {
|
|
51
|
+
paddingVertical: 0
|
|
52
|
+
},
|
|
53
|
+
filterLabel: {
|
|
54
|
+
color: _reactNativeUi.COLORS.NEUTRAL_7,
|
|
55
|
+
fontSize: 16,
|
|
56
|
+
fontWeight: '400'
|
|
57
|
+
},
|
|
58
|
+
filterContainer: {
|
|
59
|
+
maxWidth: 231
|
|
60
|
+
}
|
|
61
|
+
});
|
|
62
|
+
//# sourceMappingURL=TranslationLanguageRow.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_effectorReact","_reactNative","_reactNativeUi","_studentsQa","_i18n","_ProfileContext","_SettingRow","_jsxRuntime","e","__esModule","default","ICON_SIZE","TranslationLanguageRow","t","useText","model","onOpenTranslationModal","useProfile","settings","useUnit","$settings","jsx","SettingRow","icon","GlobeIcon","size","color","COLORS","NEUTRAL_7","label","style","styles","settingRow","children","FilterDropdown","variant","FilterDropdownVariant","SECONDARY","FilterDropdownSize","MEDIUM","value","translationLanguage","undefined","placeholder","disabled","isTranslationLocked","onPress","accessibilityLabel","testID","TEST_IDS","PROFILE_LANGUAGE_SELECTOR","text","filterLabel","container","filterContainer","exports","StyleSheet","create","paddingVertical","fontSize","fontWeight","maxWidth"],"sourceRoot":"../../../../../../src","sources":["features/profile/components/settings/TranslationLanguageRow.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,cAAA,GAAAD,OAAA;AACA,IAAAE,YAAA,GAAAF,OAAA;AACA,IAAAG,cAAA,GAAAH,OAAA;AAOA,IAAAI,WAAA,GAAAJ,OAAA;AAEA,IAAAK,KAAA,GAAAL,OAAA;AACA,IAAAM,eAAA,GAAAN,OAAA;AACA,IAAAO,WAAA,GAAAP,OAAA;AAAyC,IAAAQ,WAAA,GAAAR,OAAA;AAAA,SAAAD,uBAAAU,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAEzC,MAAMG,SAAS,GAAG,EAAE;AAEb,MAAMC,sBAAsB,GAAGA,CAAA,KAAM;EAC1C,MAAMC,CAAC,GAAG,IAAAC,aAAO,EAAC,CAAC;EACnB,MAAM;IAAEC,KAAK;IAAEC;EAAuB,CAAC,GAAG,IAAAC,0BAAU,EAAC,CAAC;EACtD,MAAMC,QAAQ,GAAG,IAAAC,sBAAO,EAACJ,KAAK,CAACK,SAAS,CAAC;EAEzC,oBACE,IAAAb,WAAA,CAAAc,GAAA,EAACf,WAAA,CAAAgB,UAAU;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Property(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.ProfileProvider = void 0;
|
|
7
|
+
exports.useProfile = useProfile;
|
|
8
|
+
var _react = require("react");
|
|
9
|
+
const ProfileContext = /*#__PURE__*/(0, _react.createContext)(null);
|
|
10
|
+
function useProfile() {
|
|
11
|
+
const value = (0, _react.useContext)(ProfileContext);
|
|
12
|
+
if (!value) {
|
|
13
|
+
throw new Error('useProfile must be used within ProfileProvider');
|
|
14
|
+
}
|
|
15
|
+
return value;
|
|
16
|
+
}
|
|
17
|
+
const ProfileProvider = exports.ProfileProvider = ProfileContext.Provider;
|
|
18
|
+
//# sourceMappingURL=ProfileContext.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","require","ProfileContext","createContext","useProfile","value","useContext","Error","ProfileProvider","exports","Provider"],"sourceRoot":"../../../../../src","sources":["features/profile/context/ProfileContext.tsx"],"mappings":";;;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AAaA,MAAMC,cAAc,gBAAG,IAAAC,oBAAa,EAA6B,IAAI,CAAC;AAE/D,SAASC,UAAUA,CAAA,EAAwB;EAChD,MAAMC,KAAK,GAAG,IAAAC,iBAAU,EAACJ,cAAc,CAAC;EACxC,IAAI,CAACG,KAAK,EAAE;IACV,MAAM,IAAIE,KAAK,CAAC,gDAAgD,CAAC;EACnE;EACA,OAAOF,KAAK;AACd;AAEO,MAAMG,eAAe,GAAAC,OAAA,CAAAD,eAAA,GAAGN,cAAc,CAACQ,QAAQ","ignoreList":[]}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
var _exportNames = {
|
|
7
|
+
Profile: true,
|
|
8
|
+
ProfileModel: true,
|
|
9
|
+
TranslationLanguageModal: true,
|
|
10
|
+
JoinClassModal: true,
|
|
11
|
+
LogoutConfirmModal: true,
|
|
12
|
+
JoinClassError: true
|
|
13
|
+
};
|
|
14
|
+
Object.defineProperty(exports, "JoinClassError", {
|
|
15
|
+
enumerable: true,
|
|
16
|
+
get: function () {
|
|
17
|
+
return _JoinClassError.JoinClassError;
|
|
18
|
+
}
|
|
19
|
+
});
|
|
20
|
+
Object.defineProperty(exports, "JoinClassModal", {
|
|
21
|
+
enumerable: true,
|
|
22
|
+
get: function () {
|
|
23
|
+
return _JoinClassModal.JoinClassModal;
|
|
24
|
+
}
|
|
25
|
+
});
|
|
26
|
+
Object.defineProperty(exports, "LogoutConfirmModal", {
|
|
27
|
+
enumerable: true,
|
|
28
|
+
get: function () {
|
|
29
|
+
return _LogoutConfirmModal.LogoutConfirmModal;
|
|
30
|
+
}
|
|
31
|
+
});
|
|
32
|
+
Object.defineProperty(exports, "Profile", {
|
|
33
|
+
enumerable: true,
|
|
34
|
+
get: function () {
|
|
35
|
+
return _Profile.Profile;
|
|
36
|
+
}
|
|
37
|
+
});
|
|
38
|
+
Object.defineProperty(exports, "ProfileModel", {
|
|
39
|
+
enumerable: true,
|
|
40
|
+
get: function () {
|
|
41
|
+
return _ProfileModel.ProfileModel;
|
|
42
|
+
}
|
|
43
|
+
});
|
|
44
|
+
Object.defineProperty(exports, "TranslationLanguageModal", {
|
|
45
|
+
enumerable: true,
|
|
46
|
+
get: function () {
|
|
47
|
+
return _TranslationLanguageModal.TranslationLanguageModal;
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
var _Profile = require("./Profile.js");
|
|
51
|
+
var _ProfileModel = require("./model/ProfileModel.js");
|
|
52
|
+
var _TranslationLanguageModal = require("./components/modals/TranslationLanguageModal.js");
|
|
53
|
+
var _JoinClassModal = require("./components/modals/JoinClassModal.js");
|
|
54
|
+
var _LogoutConfirmModal = require("./components/modals/LogoutConfirmModal.js");
|
|
55
|
+
var _JoinClassError = require("./shared/JoinClassError.js");
|
|
56
|
+
var _profileTypes = require("./shared/profile.types.js");
|
|
57
|
+
Object.keys(_profileTypes).forEach(function (key) {
|
|
58
|
+
if (key === "default" || key === "__esModule") return;
|
|
59
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
60
|
+
if (key in exports && exports[key] === _profileTypes[key]) return;
|
|
61
|
+
Object.defineProperty(exports, key, {
|
|
62
|
+
enumerable: true,
|
|
63
|
+
get: function () {
|
|
64
|
+
return _profileTypes[key];
|
|
65
|
+
}
|
|
66
|
+
});
|
|
67
|
+
});
|
|
68
|
+
var _profileConstants = require("./shared/profile.constants.js");
|
|
69
|
+
Object.keys(_profileConstants).forEach(function (key) {
|
|
70
|
+
if (key === "default" || key === "__esModule") return;
|
|
71
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
72
|
+
if (key in exports && exports[key] === _profileConstants[key]) return;
|
|
73
|
+
Object.defineProperty(exports, key, {
|
|
74
|
+
enumerable: true,
|
|
75
|
+
get: function () {
|
|
76
|
+
return _profileConstants[key];
|
|
77
|
+
}
|
|
78
|
+
});
|
|
79
|
+
});
|
|
80
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_Profile","require","_ProfileModel","_TranslationLanguageModal","_JoinClassModal","_LogoutConfirmModal","_JoinClassError","_profileTypes","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","_profileConstants"],"sourceRoot":"../../../../src","sources":["features/profile/index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,QAAA,GAAAC,OAAA;AACA,IAAAC,aAAA,GAAAD,OAAA;AAGA,IAAAE,yBAAA,GAAAF,OAAA;AACA,IAAAG,eAAA,GAAAH,OAAA;AACA,IAAAI,mBAAA,GAAAJ,OAAA;AAEA,IAAAK,eAAA,GAAAL,OAAA;AACA,IAAAM,aAAA,GAAAN,OAAA;AAAAO,MAAA,CAAAC,IAAA,CAAAF,aAAA,EAAAG,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAJ,aAAA,CAAAI,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAZ,aAAA,CAAAI,GAAA;IAAA;EAAA;AAAA;AACA,IAAAS,iBAAA,GAAAnB,OAAA;AAAAO,MAAA,CAAAC,IAAA,CAAAW,iBAAA,EAAAV,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAS,iBAAA,CAAAT,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAC,iBAAA,CAAAT,GAAA;IAAA;EAAA;AAAA","ignoreList":[]}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.ProfileApi = void 0;
|
|
7
|
+
var _effector = require("effector");
|
|
8
|
+
class ProfileApi {
|
|
9
|
+
constructor(props) {
|
|
10
|
+
this.updateSettingsFx = (0, _effector.createEffect)(props.updateSettings);
|
|
11
|
+
this.joinClassFx = (0, _effector.createEffect)(props.joinClass);
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
exports.ProfileApi = ProfileApi;
|
|
15
|
+
//# sourceMappingURL=ProfileApi.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_effector","require","ProfileApi","constructor","props","updateSettingsFx","createEffect","updateSettings","joinClassFx","joinClass","exports"],"sourceRoot":"../../../../../src","sources":["features/profile/model/ProfileApi.ts"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AAcO,MAAMC,UAAU,CAAC;EAItBC,WAAWA,CAACC,KAAsB,EAAE;IAClC,IAAI,CAACC,gBAAgB,GAAG,IAAAC,sBAAY,EAACF,KAAK,CAACG,cAAc,CAAC;IAC1D,IAAI,CAACC,WAAW,GAAG,IAAAF,sBAAY,EAACF,KAAK,CAACK,SAAS,CAAC;EAClD;AACF;AAACC,OAAA,CAAAR,UAAA,GAAAA,UAAA","ignoreList":[]}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.ProfileJoinClassModel = void 0;
|
|
7
|
+
var _effector = require("effector");
|
|
8
|
+
var _JoinClassError = require("../shared/JoinClassError.js");
|
|
9
|
+
var _profileConstants = require("../shared/profile.constants.js");
|
|
10
|
+
var _profileHelpers = require("../shared/profile.helpers.js");
|
|
11
|
+
class ProfileJoinClassModel {
|
|
12
|
+
reset = (0, _effector.createEvent)();
|
|
13
|
+
setCode = (0, _effector.createEvent)();
|
|
14
|
+
submit = (0, _effector.createEvent)();
|
|
15
|
+
$code = (0, _effector.restore)(this.setCode, '').reset(this.reset);
|
|
16
|
+
$isComplete = this.$code.map(code => code.length === _profileConstants.CLASS_CODE_LENGTH);
|
|
17
|
+
constructor(api, notify) {
|
|
18
|
+
this.api = api;
|
|
19
|
+
this.notify = notify;
|
|
20
|
+
this.init();
|
|
21
|
+
}
|
|
22
|
+
init() {
|
|
23
|
+
const notifyFx = (0, _effector.createEffect)(this.notify);
|
|
24
|
+
(0, _effector.sample)({
|
|
25
|
+
clock: this.submit,
|
|
26
|
+
source: this.$code,
|
|
27
|
+
filter: code => code.length === _profileConstants.CLASS_CODE_LENGTH,
|
|
28
|
+
fn: classCode => ({
|
|
29
|
+
classCode
|
|
30
|
+
}),
|
|
31
|
+
target: this.api.joinClassFx
|
|
32
|
+
});
|
|
33
|
+
(0, _effector.sample)({
|
|
34
|
+
clock: this.api.joinClassFx.done,
|
|
35
|
+
fn: ({
|
|
36
|
+
result
|
|
37
|
+
}) => ({
|
|
38
|
+
status: _profileConstants.JoinClassStatus.SUCCESS,
|
|
39
|
+
message: (0, _profileHelpers.getJoinClassSuccessMessage)(result.name)
|
|
40
|
+
}),
|
|
41
|
+
target: notifyFx
|
|
42
|
+
});
|
|
43
|
+
(0, _effector.sample)({
|
|
44
|
+
clock: this.api.joinClassFx.fail,
|
|
45
|
+
fn: ({
|
|
46
|
+
error
|
|
47
|
+
}) => ({
|
|
48
|
+
status: _profileConstants.JoinClassStatus.ERROR,
|
|
49
|
+
message: (0, _profileHelpers.getJoinClassErrorMessage)(error instanceof _JoinClassError.JoinClassError ? error.code : null)
|
|
50
|
+
}),
|
|
51
|
+
target: notifyFx
|
|
52
|
+
});
|
|
53
|
+
(0, _effector.sample)({
|
|
54
|
+
clock: this.api.joinClassFx.done,
|
|
55
|
+
target: this.reset
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
exports.ProfileJoinClassModel = ProfileJoinClassModel;
|
|
60
|
+
//# sourceMappingURL=ProfileJoinClassModel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_effector","require","_JoinClassError","_profileConstants","_profileHelpers","ProfileJoinClassModel","reset","createEvent","setCode","submit","$code","restore","$isComplete","map","code","length","CLASS_CODE_LENGTH","constructor","api","notify","init","notifyFx","createEffect","sample","clock","source","filter","fn","classCode","target","joinClassFx","done","result","status","JoinClassStatus","SUCCESS","message","getJoinClassSuccessMessage","name","fail","error","ERROR","getJoinClassErrorMessage","JoinClassError","exports"],"sourceRoot":"../../../../../src","sources":["features/profile/model/ProfileJoinClassModel.ts"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AAEA,IAAAC,eAAA,GAAAD,OAAA;AACA,IAAAE,iBAAA,GAAAF,OAAA;AACA,IAAAG,eAAA,GAAAH,OAAA;AAIO,MAAMI,qBAAqB,CAAC;EACjBC,KAAK,GAAG,IAAAC,qBAAW,EAAC,CAAC;EACrBC,OAAO,GAAG,IAAAD,qBAAW,EAAS,CAAC;EAC/BE,MAAM,GAAG,IAAAF,qBAAW,EAAC,CAAC;EAEtBG,KAAK,GAAG,IAAAC,iBAAO,EAAC,IAAI,CAACH,OAAO,EAAE,EAAE,CAAC,CAACF,KAAK,CAAC,IAAI,CAACA,KAAK,CAAC;EACnDM,WAAW,GAAG,IAAI,CAACF,KAAK,CAACG,GAAG,CAAEC,IAAI,IAAKA,IAAI,CAACC,MAAM,KAAKC,mCAAiB,CAAC;EAEzFC,WAAWA,CACQC,GAAe,EACfC,MAAuB,EACxC;IAAA,KAFiBD,GAAe,GAAfA,GAAe;IAAA,KACfC,MAAuB,GAAvBA,MAAuB;IAExC,IAAI,CAACC,IAAI,CAAC,CAAC;EACb;EAEQA,IAAIA,CAAA,EAAG;IACb,MAAMC,QAAQ,GAAG,IAAAC,sBAAY,EAAC,IAAI,CAACH,MAAM,CAAC;IAE1C,IAAAI,gBAAM,EAAC;MACLC,KAAK,EAAE,IAAI,CAACf,MAAM;MAClBgB,MAAM,EAAE,IAAI,CAACf,KAAK;MAClBgB,MAAM,EAAGZ,IAAI,IAAKA,IAAI,CAACC,MAAM,KAAKC,mCAAiB;MACnDW,EAAE,EAAGC,SAAS,KAAM;QAAEA;MAAU,CAAC,CAAC;MAClCC,MAAM,EAAE,IAAI,CAACX,GAAG,CAACY;IACnB,CAAC,CAAC;IAEF,IAAAP,gBAAM,EAAC;MACLC,KAAK,EAAE,IAAI,CAACN,GAAG,CAACY,WAAW,CAACC,IAAI;MAChCJ,EAAE,EAAEA,CAAC;QAAEK;MAAO,CAAC,MAAM;QACnBC,MAAM,EAAEC,iCAAe,CAACC,OAAO;QAC/BC,OAAO,EAAE,IAAAC,0CAA0B,EAACL,MAAM,CAACM,IAAI;MACjD,CAAC,CAAC;MACFT,MAAM,EAAER;IACV,CAAC,CAAC;IAEF,IAAAE,gBAAM,EAAC;MACLC,KAAK,EAAE,IAAI,CAACN,GAAG,CAACY,WAAW,CAACS,IAAI;MAChCZ,EAAE,EAAEA,CAAC;QAAEa;MAAM,CAAC,MAAM;QAClBP,MAAM,EAAEC,iCAAe,CAACO,KAAK;QAC7BL,OAAO,EAAE,IAAAM,wCAAwB,EAACF,KAAK,YAAYG,8BAAc,GAAGH,KAAK,CAAC1B,IAAI,GAAG,IAAI;MACvF,CAAC,CAAC;MACFe,MAAM,EAAER;IACV,CAAC,CAAC;IAEF,IAAAE,gBAAM,EAAC;MACLC,KAAK,EAAE,IAAI,CAACN,GAAG,CAACY,WAAW,CAACC,IAAI;MAChCF,MAAM,EAAE,IAAI,CAACvB;IACf,CAAC,CAAC;EACJ;AACF;AAACsC,OAAA,CAAAvC,qBAAA,GAAAA,qBAAA","ignoreList":[]}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.ProfileLanguageModel = void 0;
|
|
7
|
+
var _effector = require("effector");
|
|
8
|
+
var _profileHelpers = require("../shared/profile.helpers.js");
|
|
9
|
+
class ProfileLanguageModel {
|
|
10
|
+
reset = (0, _effector.createEvent)();
|
|
11
|
+
setSearch = (0, _effector.createEvent)();
|
|
12
|
+
selectLanguage = (0, _effector.createEvent)();
|
|
13
|
+
$search = (0, _effector.restore)(this.setSearch, '').reset(this.reset);
|
|
14
|
+
$languages = this.$search.map(search => (0, _profileHelpers.getAvailableLanguages)(search));
|
|
15
|
+
constructor(api) {
|
|
16
|
+
this.api = api;
|
|
17
|
+
this.init();
|
|
18
|
+
}
|
|
19
|
+
init() {
|
|
20
|
+
(0, _effector.sample)({
|
|
21
|
+
clock: this.selectLanguage,
|
|
22
|
+
fn: translationLanguage => ({
|
|
23
|
+
translationLanguage
|
|
24
|
+
}),
|
|
25
|
+
target: this.api.updateSettingsFx
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
exports.ProfileLanguageModel = ProfileLanguageModel;
|
|
30
|
+
//# sourceMappingURL=ProfileLanguageModel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_effector","require","_profileHelpers","ProfileLanguageModel","reset","createEvent","setSearch","selectLanguage","$search","restore","$languages","map","search","getAvailableLanguages","constructor","api","init","sample","clock","fn","translationLanguage","target","updateSettingsFx","exports"],"sourceRoot":"../../../../../src","sources":["features/profile/model/ProfileLanguageModel.ts"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AAGA,IAAAC,eAAA,GAAAD,OAAA;AAGO,MAAME,oBAAoB,CAAC;EAChBC,KAAK,GAAG,IAAAC,qBAAW,EAAC,CAAC;EACrBC,SAAS,GAAG,IAAAD,qBAAW,EAAS,CAAC;EACjCE,cAAc,GAAG,IAAAF,qBAAW,EAAkB,CAAC;EAE/CG,OAAO,GAAG,IAAAC,iBAAO,EAAC,IAAI,CAACH,SAAS,EAAE,EAAE,CAAC,CAACF,KAAK,CAAC,IAAI,CAACA,KAAK,CAAC;EACvDM,UAAU,GAAG,IAAI,CAACF,OAAO,CAACG,GAAG,CAAEC,MAAM,IAAK,IAAAC,qCAAqB,EAACD,MAAM,CAAC,CAAC;EAExFE,WAAWA,CAAkBC,GAAe,EAAE;IAAA,KAAjBA,GAAe,GAAfA,GAAe;IAC1C,IAAI,CAACC,IAAI,CAAC,CAAC;EACb;EAEQA,IAAIA,CAAA,EAAG;IACb,IAAAC,gBAAM,EAAC;MACLC,KAAK,EAAE,IAAI,CAACX,cAAc;MAC1BY,EAAE,EAAGC,mBAAmB,KAAM;QAAEA;MAAoB,CAAC,CAAC;MACtDC,MAAM,EAAE,IAAI,CAACN,GAAG,CAACO;IACnB,CAAC,CAAC;EACJ;AACF;AAACC,OAAA,CAAApB,oBAAA,GAAAA,oBAAA","ignoreList":[]}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.ProfileModel = void 0;
|
|
7
|
+
var _effector = require("effector");
|
|
8
|
+
var _ProfileApi = require("./ProfileApi.js");
|
|
9
|
+
var _ProfileJoinClassModel = require("./ProfileJoinClassModel.js");
|
|
10
|
+
var _ProfileLanguageModel = require("./ProfileLanguageModel.js");
|
|
11
|
+
class ProfileModel {
|
|
12
|
+
setTextToSpeech = (0, _effector.createEvent)();
|
|
13
|
+
setTextSize = (0, _effector.createEvent)();
|
|
14
|
+
setCanvasType = (0, _effector.createEvent)();
|
|
15
|
+
constructor({
|
|
16
|
+
api,
|
|
17
|
+
notify,
|
|
18
|
+
$user,
|
|
19
|
+
$settings
|
|
20
|
+
}) {
|
|
21
|
+
this.api = new _ProfileApi.ProfileApi(api);
|
|
22
|
+
this.joinClass = new _ProfileJoinClassModel.ProfileJoinClassModel(this.api, notify);
|
|
23
|
+
this.language = new _ProfileLanguageModel.ProfileLanguageModel(this.api);
|
|
24
|
+
this.$user = $user;
|
|
25
|
+
this.$settings = $settings;
|
|
26
|
+
this.init();
|
|
27
|
+
}
|
|
28
|
+
init() {
|
|
29
|
+
(0, _effector.sample)({
|
|
30
|
+
clock: this.setTextToSpeech,
|
|
31
|
+
fn: textToSpeech => ({
|
|
32
|
+
textToSpeech
|
|
33
|
+
}),
|
|
34
|
+
target: this.api.updateSettingsFx
|
|
35
|
+
});
|
|
36
|
+
(0, _effector.sample)({
|
|
37
|
+
clock: this.setTextSize,
|
|
38
|
+
fn: textSize => ({
|
|
39
|
+
textSize
|
|
40
|
+
}),
|
|
41
|
+
target: this.api.updateSettingsFx
|
|
42
|
+
});
|
|
43
|
+
(0, _effector.sample)({
|
|
44
|
+
clock: this.setCanvasType,
|
|
45
|
+
fn: canvasType => ({
|
|
46
|
+
canvasType
|
|
47
|
+
}),
|
|
48
|
+
target: this.api.updateSettingsFx
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
exports.ProfileModel = ProfileModel;
|
|
53
|
+
//# sourceMappingURL=ProfileModel.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_effector","require","_ProfileApi","_ProfileJoinClassModel","_ProfileLanguageModel","ProfileModel","setTextToSpeech","createEvent","setTextSize","setCanvasType","constructor","api","notify","$user","$settings","ProfileApi","joinClass","ProfileJoinClassModel","language","ProfileLanguageModel","init","sample","clock","fn","textToSpeech","target","updateSettingsFx","textSize","canvasType","exports"],"sourceRoot":"../../../../../src","sources":["features/profile/model/ProfileModel.ts"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AAIA,IAAAC,WAAA,GAAAD,OAAA;AACA,IAAAE,sBAAA,GAAAF,OAAA;AACA,IAAAG,qBAAA,GAAAH,OAAA;AASO,MAAMI,YAAY,CAAC;EAKRC,eAAe,GAAG,IAAAC,qBAAW,EAAU,CAAC;EACxCC,WAAW,GAAG,IAAAD,qBAAW,EAAS,CAAC;EACnCE,aAAa,GAAG,IAAAF,qBAAW,EAAoB,CAAC;EAKhEG,WAAWA,CAAC;IAAEC,GAAG;IAAEC,MAAM;IAAEC,KAAK;IAAEC;EAA6B,CAAC,EAAE;IAChE,IAAI,CAACH,GAAG,GAAG,IAAII,sBAAU,CAACJ,GAAG,CAAC;IAC9B,IAAI,CAACK,SAAS,GAAG,IAAIC,4CAAqB,CAAC,IAAI,CAACN,GAAG,EAAEC,MAAM,CAAC;IAC5D,IAAI,CAACM,QAAQ,GAAG,IAAIC,0CAAoB,CAAC,IAAI,CAACR,GAAG,CAAC;IAClD,IAAI,CAACE,KAAK,GAAGA,KAAK;IAClB,IAAI,CAACC,SAAS,GAAGA,SAAS;IAE1B,IAAI,CAACM,IAAI,CAAC,CAAC;EACb;EAEQA,IAAIA,CAAA,EAAG;IACb,IAAAC,gBAAM,EAAC;MACLC,KAAK,EAAE,IAAI,CAAChB,eAAe;MAC3BiB,EAAE,EAAGC,YAAY,KAAM;QAAEA;MAAa,CAAC,CAAC;MACxCC,MAAM,EAAE,IAAI,CAACd,GAAG,CAACe;IACnB,CAAC,CAAC;IAEF,IAAAL,gBAAM,EAAC;MACLC,KAAK,EAAE,IAAI,CAACd,WAAW;MACvBe,EAAE,EAAGI,QAAQ,KAAM;QAAEA;MAAS,CAAC,CAAC;MAChCF,MAAM,EAAE,IAAI,CAACd,GAAG,CAACe;IACnB,CAAC,CAAC;IAEF,IAAAL,gBAAM,EAAC;MACLC,KAAK,EAAE,IAAI,CAACb,aAAa;MACzBc,EAAE,EAAGK,UAAU,KAAM;QAAEA;MAAW,CAAC,CAAC;MACpCH,MAAM,EAAE,IAAI,CAACd,GAAG,CAACe;IACnB,CAAC,CAAC;EACJ;AACF;AAACG,OAAA,CAAAxB,YAAA,GAAAA,YAAA","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../../../../src","sources":["features/profile/model/profileModal.types.ts"],"mappings":"","ignoreList":[]}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.JoinClassError = void 0;
|
|
7
|
+
// Carries the backend error code so the library can map it to a message without parsing HTTP errors.
|
|
8
|
+
class JoinClassError extends Error {
|
|
9
|
+
constructor(code) {
|
|
10
|
+
super(code === null ? 'Join class failed' : `Join class failed (code ${code})`);
|
|
11
|
+
this.code = code;
|
|
12
|
+
this.name = 'JoinClassError';
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
exports.JoinClassError = JoinClassError;
|
|
16
|
+
//# sourceMappingURL=JoinClassError.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["JoinClassError","Error","constructor","code","name","exports"],"sourceRoot":"../../../../../src","sources":["features/profile/shared/JoinClassError.ts"],"mappings":";;;;;;AAAA;AACO,MAAMA,cAAc,SAASC,KAAK,CAAC;EACxCC,WAAWA,CAAiBC,IAAmB,EAAE;IAC/C,KAAK,CAACA,IAAI,KAAK,IAAI,GAAG,mBAAmB,GAAG,2BAA2BA,IAAI,GAAG,CAAC;IAAA,KADrDA,IAAmB,GAAnBA,IAAmB;IAE7C,IAAI,CAACC,IAAI,GAAG,gBAAgB;EAC9B;AACF;AAACC,OAAA,CAAAL,cAAA,GAAAA,cAAA","ignoreList":[]}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.TEXT_SIZE = exports.ProfileCanvasType = exports.JoinClassStatus = exports.JoinClassErrorCode = exports.CLASS_CODE_LENGTH = void 0;
|
|
7
|
+
let ProfileCanvasType = exports.ProfileCanvasType = /*#__PURE__*/function (ProfileCanvasType) {
|
|
8
|
+
ProfileCanvasType[ProfileCanvasType["DRAWING"] = 1] = "DRAWING";
|
|
9
|
+
ProfileCanvasType[ProfileCanvasType["SPREADSHEET"] = 2] = "SPREADSHEET";
|
|
10
|
+
return ProfileCanvasType;
|
|
11
|
+
}({});
|
|
12
|
+
const TEXT_SIZE = exports.TEXT_SIZE = {
|
|
13
|
+
MIN: 16,
|
|
14
|
+
MAX: 32,
|
|
15
|
+
STEP: 4
|
|
16
|
+
};
|
|
17
|
+
const CLASS_CODE_LENGTH = exports.CLASS_CODE_LENGTH = 6;
|
|
18
|
+
let JoinClassStatus = exports.JoinClassStatus = /*#__PURE__*/function (JoinClassStatus) {
|
|
19
|
+
JoinClassStatus["SUCCESS"] = "success";
|
|
20
|
+
JoinClassStatus["ERROR"] = "error";
|
|
21
|
+
return JoinClassStatus;
|
|
22
|
+
}({});
|
|
23
|
+
let JoinClassErrorCode = exports.JoinClassErrorCode = /*#__PURE__*/function (JoinClassErrorCode) {
|
|
24
|
+
JoinClassErrorCode[JoinClassErrorCode["CLASS_NOT_FOUND"] = 1021] = "CLASS_NOT_FOUND";
|
|
25
|
+
JoinClassErrorCode[JoinClassErrorCode["ALREADY_JOINED"] = 1030] = "ALREADY_JOINED";
|
|
26
|
+
JoinClassErrorCode[JoinClassErrorCode["OTHER_DISTRICT"] = 1035] = "OTHER_DISTRICT";
|
|
27
|
+
return JoinClassErrorCode;
|
|
28
|
+
}({});
|
|
29
|
+
//# sourceMappingURL=profile.constants.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["ProfileCanvasType","exports","TEXT_SIZE","MIN","MAX","STEP","CLASS_CODE_LENGTH","JoinClassStatus","JoinClassErrorCode"],"sourceRoot":"../../../../../src","sources":["features/profile/shared/profile.constants.ts"],"mappings":";;;;;;IAAYA,iBAAiB,GAAAC,OAAA,CAAAD,iBAAA,0BAAjBA,iBAAiB;EAAjBA,iBAAiB,CAAjBA,iBAAiB;EAAjBA,iBAAiB,CAAjBA,iBAAiB;EAAA,OAAjBA,iBAAiB;AAAA;AAKtB,MAAME,SAAS,GAAAD,OAAA,CAAAC,SAAA,GAAG;EACvBC,GAAG,EAAE,EAAE;EACPC,GAAG,EAAE,EAAE;EACPC,IAAI,EAAE;AACR,CAAU;AAEH,MAAMC,iBAAiB,GAAAL,OAAA,CAAAK,iBAAA,GAAG,CAAC;AAAA,IAEtBC,eAAe,GAAAN,OAAA,CAAAM,eAAA,0BAAfA,eAAe;EAAfA,eAAe;EAAfA,eAAe;EAAA,OAAfA,eAAe;AAAA;AAAA,IAKfC,kBAAkB,GAAAP,OAAA,CAAAO,kBAAA,0BAAlBA,kBAAkB;EAAlBA,kBAAkB,CAAlBA,kBAAkB;EAAlBA,kBAAkB,CAAlBA,kBAAkB;EAAlBA,kBAAkB,CAAlBA,kBAAkB;EAAA,OAAlBA,kBAAkB;AAAA","ignoreList":[]}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.snapTextSize = exports.getJoinClassSuccessMessage = exports.getJoinClassErrorMessage = exports.getAvailableLanguages = void 0;
|
|
7
|
+
var _frontendConfig = require("@magmamath/frontend-config");
|
|
8
|
+
var _i18n = require("../../../i18n/i18n.js");
|
|
9
|
+
var _profileConstants = require("./profile.constants.js");
|
|
10
|
+
const getAvailableLanguages = search => {
|
|
11
|
+
const prioritySet = new Set(_frontendConfig.PRIORITY_LANGUAGES);
|
|
12
|
+
const otherLanguages = Object.values(_frontendConfig.Language).filter(language => !_frontendConfig.LANGUAGES_CONFIG[language]?.baseName && !prioritySet.has(language));
|
|
13
|
+
const allLanguages = [..._frontendConfig.PRIORITY_LANGUAGES, ...otherLanguages];
|
|
14
|
+
if (!search) return allLanguages;
|
|
15
|
+
const query = search.toLowerCase();
|
|
16
|
+
return allLanguages.filter(language => language.toLowerCase().includes(query));
|
|
17
|
+
};
|
|
18
|
+
exports.getAvailableLanguages = getAvailableLanguages;
|
|
19
|
+
const snapTextSize = value => {
|
|
20
|
+
const {
|
|
21
|
+
MIN,
|
|
22
|
+
MAX,
|
|
23
|
+
STEP
|
|
24
|
+
} = _profileConstants.TEXT_SIZE;
|
|
25
|
+
const clamped = Math.min(MAX, Math.max(MIN, value));
|
|
26
|
+
return Math.round((clamped - MIN) / STEP) * STEP + MIN;
|
|
27
|
+
};
|
|
28
|
+
exports.snapTextSize = snapTextSize;
|
|
29
|
+
const JOIN_CLASS_ERROR_KEYS = {
|
|
30
|
+
[_profileConstants.JoinClassErrorCode.CLASS_NOT_FOUND]: 'profile.joinClassErrorNotFound',
|
|
31
|
+
[_profileConstants.JoinClassErrorCode.ALREADY_JOINED]: 'profile.joinClassErrorAlreadyJoined',
|
|
32
|
+
[_profileConstants.JoinClassErrorCode.OTHER_DISTRICT]: 'profile.joinClassErrorOtherDistrict'
|
|
33
|
+
};
|
|
34
|
+
const getJoinClassSuccessMessage = className => (0, _i18n.getText)('profile.joinClassSuccess', {
|
|
35
|
+
className
|
|
36
|
+
});
|
|
37
|
+
exports.getJoinClassSuccessMessage = getJoinClassSuccessMessage;
|
|
38
|
+
const getJoinClassErrorMessage = code => (0, _i18n.getText)(code !== null && JOIN_CLASS_ERROR_KEYS[code] || 'profile.joinClassErrorDefault');
|
|
39
|
+
exports.getJoinClassErrorMessage = getJoinClassErrorMessage;
|
|
40
|
+
//# sourceMappingURL=profile.helpers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_frontendConfig","require","_i18n","_profileConstants","getAvailableLanguages","search","prioritySet","Set","PRIORITY_LANGUAGES","otherLanguages","Object","values","Language","filter","language","LANGUAGES_CONFIG","baseName","has","allLanguages","query","toLowerCase","includes","exports","snapTextSize","value","MIN","MAX","STEP","TEXT_SIZE","clamped","Math","min","max","round","JOIN_CLASS_ERROR_KEYS","JoinClassErrorCode","CLASS_NOT_FOUND","ALREADY_JOINED","OTHER_DISTRICT","getJoinClassSuccessMessage","className","getText","getJoinClassErrorMessage","code"],"sourceRoot":"../../../../../src","sources":["features/profile/shared/profile.helpers.ts"],"mappings":";;;;;;AAAA,IAAAA,eAAA,GAAAC,OAAA;AAEA,IAAAC,KAAA,GAAAD,OAAA;AACA,IAAAE,iBAAA,GAAAF,OAAA;AAEO,MAAMG,qBAAqB,GAAIC,MAAe,IAAiB;EACpE,MAAMC,WAAW,GAAG,IAAIC,GAAG,CAAWC,kCAAkB,C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,OAAA,CAAAiB,0BAAA,GAAAA,0BAAA;AAE7C,MAAMG,wBAAwB,GAAIC,IAAmB,IAC1D,IAAAF,aAAO,EAAEE,IAAI,KAAK,IAAI,IAAIT,qBAAqB,CAACS,IAAI,CAAC,IAAK,+BAA+B,CAAC;AAAArB,OAAA,CAAAoB,wBAAA,GAAAA,wBAAA","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../../../../src","sources":["features/profile/shared/profile.types.ts"],"mappings":"","ignoreList":[]}
|
package/dist/commonjs/index.js
CHANGED
|
@@ -217,4 +217,16 @@ Object.keys(_index17).forEach(function (key) {
|
|
|
217
217
|
}
|
|
218
218
|
});
|
|
219
219
|
});
|
|
220
|
+
var _index18 = require("./features/profile/index.js");
|
|
221
|
+
Object.keys(_index18).forEach(function (key) {
|
|
222
|
+
if (key === "default" || key === "__esModule") return;
|
|
223
|
+
if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
|
|
224
|
+
if (key in exports && exports[key] === _index18[key]) return;
|
|
225
|
+
Object.defineProperty(exports, key, {
|
|
226
|
+
enumerable: true,
|
|
227
|
+
get: function () {
|
|
228
|
+
return _index18[key];
|
|
229
|
+
}
|
|
230
|
+
});
|
|
231
|
+
});
|
|
220
232
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_helpers","require","_index","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","_index2","_index3","_index4","_index5","_index6","_index7","_index8","_index9","_index10","_index11","_index12","_index13","_index14","_index15","_index16","_index17"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":";;;;;;;;;;;;;;AAAA,IAAAA,QAAA,GAAAC,OAAA;AACA,IAAAC,MAAA,GAAAD,OAAA;AAAAE,MAAA,CAAAC,IAAA,CAAAF,MAAA,EAAAG,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,G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B,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAgB,QAAA,CAAAxB,GAAA;IAAA;EAAA;AAAA","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["_helpers","require","_index","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","_index2","_index3","_index4","_index5","_index6","_index7","_index8","_index9","_index10","_index11","_index12","_index13","_index14","_index15","_index16","_index17","_index18"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":";;;;;;;;;;;;;;AAAA,IAAAA,QAAA,GAAAC,OAAA;AACA,IAAAC,MAAA,GAAAD,OAAA;AAAAE,MAAA,CAAAC,IAAA,CAAAF,MAAA,EAAAG,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAJ,MAAA,CAAAI,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,CAAA;MAAA,OAAAZ,MAAA,CAAAI,GAAA;IAAA;EAAA;AAAA;AACA,IAAAS,OAAA,GAAAd,OAAA;AAAAE,MAAA,CAAAC,IAAA,CAAAW,OAAA,EAAAV,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAS,OAAA,CAAAT,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;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
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.useKeyboardOffset = void 0;
|
|
7
|
+
var _react = require("react");
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _commonConstants = require("../common.constants.js");
|
|
10
|
+
const SHOW_EVENT = _reactNative.Platform.OS === 'ios' ? 'keyboardWillShow' : 'keyboardDidShow';
|
|
11
|
+
const HIDE_EVENT = _reactNative.Platform.OS === 'ios' ? 'keyboardWillHide' : 'keyboardDidHide';
|
|
12
|
+
const ANIMATION_DURATION = 220;
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Returns an animated value tracking the on-screen keyboard height.
|
|
16
|
+
*
|
|
17
|
+
* - native: subscribes to the platform `Keyboard` events.
|
|
18
|
+
* - web: reads `visualViewport`, so it only reacts to a *virtual* keyboard
|
|
19
|
+
* (mobile browsers). A physical desktop keyboard never shrinks the viewport,
|
|
20
|
+
* so the value stays 0 and nothing moves.
|
|
21
|
+
*/
|
|
22
|
+
const useKeyboardOffset = () => {
|
|
23
|
+
const keyboardHeight = (0, _react.useRef)(new _reactNative.Animated.Value(0)).current;
|
|
24
|
+
(0, _react.useEffect)(() => {
|
|
25
|
+
const animateTo = toValue => _reactNative.Animated.timing(keyboardHeight, {
|
|
26
|
+
toValue,
|
|
27
|
+
duration: ANIMATION_DURATION,
|
|
28
|
+
useNativeDriver: !_commonConstants.isWeb
|
|
29
|
+
}).start();
|
|
30
|
+
if (_commonConstants.isWeb) {
|
|
31
|
+
const viewport = window.visualViewport;
|
|
32
|
+
if (!viewport) return;
|
|
33
|
+
const update = () => {
|
|
34
|
+
const overlap = Math.max(0, window.innerHeight - viewport.height - viewport.offsetTop);
|
|
35
|
+
animateTo(overlap);
|
|
36
|
+
};
|
|
37
|
+
viewport.addEventListener('resize', update);
|
|
38
|
+
viewport.addEventListener('scroll', update);
|
|
39
|
+
return () => {
|
|
40
|
+
viewport.removeEventListener('resize', update);
|
|
41
|
+
viewport.removeEventListener('scroll', update);
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
const showSub = _reactNative.Keyboard.addListener(SHOW_EVENT, event => animateTo(event.endCoordinates.height));
|
|
45
|
+
const hideSub = _reactNative.Keyboard.addListener(HIDE_EVENT, () => animateTo(0));
|
|
46
|
+
return () => {
|
|
47
|
+
showSub.remove();
|
|
48
|
+
hideSub.remove();
|
|
49
|
+
};
|
|
50
|
+
}, [keyboardHeight]);
|
|
51
|
+
return keyboardHeight;
|
|
52
|
+
};
|
|
53
|
+
exports.useKeyboardOffset = useKeyboardOffset;
|
|
54
|
+
//# sourceMappingURL=useKeyboardOffset.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","require","_reactNative","_commonConstants","SHOW_EVENT","Platform","OS","HIDE_EVENT","ANIMATION_DURATION","useKeyboardOffset","keyboardHeight","useRef","Animated","Value","current","useEffect","animateTo","toValue","timing","duration","useNativeDriver","isWeb","start","viewport","window","visualViewport","update","overlap","Math","max","innerHeight","height","offsetTop","addEventListener","removeEventListener","showSub","Keyboard","addListener","event","endCoordinates","hideSub","remove","exports"],"sourceRoot":"../../../../src","sources":["shared/hooks/useKeyboardOffset.ts"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAEA,IAAAE,gBAAA,GAAAF,OAAA;AAEA,MAAMG,UAAU,GAAGC,qBAAQ,CAACC,EAAE,KAAK,KAAK,GAAG,kBAAkB,GAAG,iBAAiB;AACjF,MAAMC,UAAU,GAAGF,qBAAQ,CAACC,EAAE,KAAK,KAAK,GAAG,kBAAkB,GAAG,iBAAiB;AACjF,MAAME,kBAAkB,GAAG,GAAG;;AAE9B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAMC,iBAAiB,GAAGA,CAAA,KAAM;EACrC,MAAMC,cAAc,GAAG,IAAAC,aAAM,EAAC,IAAIC,qBAA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