@churchapps/apphelper 0.0.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/.eslintignore +4 -0
- package/.eslintrc.json +22 -0
- package/LICENSE +21 -0
- package/README.md +16 -0
- package/dist/components/CreatePerson.d.ts +9 -0
- package/dist/components/CreatePerson.d.ts.map +1 -0
- package/dist/components/CreatePerson.js +80 -0
- package/dist/components/CreatePerson.js.map +1 -0
- package/dist/components/DisplayBox.d.ts +16 -0
- package/dist/components/DisplayBox.d.ts.map +1 -0
- package/dist/components/DisplayBox.js +48 -0
- package/dist/components/DisplayBox.js.map +1 -0
- package/dist/components/ErrorMessages.d.ts +7 -0
- package/dist/components/ErrorMessages.d.ts.map +1 -0
- package/dist/components/ErrorMessages.js +47 -0
- package/dist/components/ErrorMessages.js.map +1 -0
- package/dist/components/ExportLink.d.ts +10 -0
- package/dist/components/ExportLink.d.ts.map +1 -0
- package/dist/components/ExportLink.js +70 -0
- package/dist/components/ExportLink.js.map +1 -0
- package/dist/components/FloatingSupport.d.ts +7 -0
- package/dist/components/FloatingSupport.d.ts.map +1 -0
- package/dist/components/FloatingSupport.js +18 -0
- package/dist/components/FloatingSupport.js.map +1 -0
- package/dist/components/FormSubmissionEdit.d.ts +18 -0
- package/dist/components/FormSubmissionEdit.d.ts.map +1 -0
- package/dist/components/FormSubmissionEdit.js +125 -0
- package/dist/components/FormSubmissionEdit.js.map +1 -0
- package/dist/components/HelpIcon.d.ts +7 -0
- package/dist/components/HelpIcon.d.ts.map +1 -0
- package/dist/components/HelpIcon.js +12 -0
- package/dist/components/HelpIcon.js.map +1 -0
- package/dist/components/ImageEditor.d.ts +15 -0
- package/dist/components/ImageEditor.d.ts.map +1 -0
- package/dist/components/ImageEditor.js +109 -0
- package/dist/components/ImageEditor.js.map +1 -0
- package/dist/components/InputBox.d.ts +24 -0
- package/dist/components/InputBox.d.ts.map +1 -0
- package/dist/components/InputBox.js +59 -0
- package/dist/components/InputBox.js.map +1 -0
- package/dist/components/Loading.d.ts +10 -0
- package/dist/components/Loading.d.ts.map +1 -0
- package/dist/components/Loading.js +34 -0
- package/dist/components/Loading.js.map +1 -0
- package/dist/components/PersonAdd.d.ts +15 -0
- package/dist/components/PersonAdd.d.ts.map +1 -0
- package/dist/components/PersonAdd.js +84 -0
- package/dist/components/PersonAdd.js.map +1 -0
- package/dist/components/QuestionEdit.d.ts +11 -0
- package/dist/components/QuestionEdit.d.ts.map +1 -0
- package/dist/components/QuestionEdit.js +76 -0
- package/dist/components/QuestionEdit.js.map +1 -0
- package/dist/components/SmallButton.d.ts +14 -0
- package/dist/components/SmallButton.d.ts.map +1 -0
- package/dist/components/SmallButton.js +31 -0
- package/dist/components/SmallButton.js.map +1 -0
- package/dist/components/SupportModal.d.ts +8 -0
- package/dist/components/SupportModal.d.ts.map +1 -0
- package/dist/components/SupportModal.js +47 -0
- package/dist/components/SupportModal.js.map +1 -0
- package/dist/components/TabPanel.d.ts +9 -0
- package/dist/components/TabPanel.d.ts.map +1 -0
- package/dist/components/TabPanel.js +24 -0
- package/dist/components/TabPanel.js.map +1 -0
- package/dist/components/gallery/GalleryModal.d.ts +9 -0
- package/dist/components/gallery/GalleryModal.d.ts.map +1 -0
- package/dist/components/gallery/GalleryModal.js +108 -0
- package/dist/components/gallery/GalleryModal.js.map +1 -0
- package/dist/components/gallery/StockPhotos.d.ts +9 -0
- package/dist/components/gallery/StockPhotos.d.ts.map +1 -0
- package/dist/components/gallery/StockPhotos.js +82 -0
- package/dist/components/gallery/StockPhotos.js.map +1 -0
- package/dist/components/index.d.ts +18 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/index.js +51 -0
- package/dist/components/index.js.map +1 -0
- package/dist/components/markdownEditor/Editor.d.ts +12 -0
- package/dist/components/markdownEditor/Editor.d.ts.map +1 -0
- package/dist/components/markdownEditor/Editor.js +106 -0
- package/dist/components/markdownEditor/Editor.js.map +1 -0
- package/dist/components/markdownEditor/MarkdownEditor.d.ts +11 -0
- package/dist/components/markdownEditor/MarkdownEditor.d.ts.map +1 -0
- package/dist/components/markdownEditor/MarkdownEditor.js +39 -0
- package/dist/components/markdownEditor/MarkdownEditor.js.map +1 -0
- package/dist/components/markdownEditor/MarkdownModal.d.ts +9 -0
- package/dist/components/markdownEditor/MarkdownModal.d.ts.map +1 -0
- package/dist/components/markdownEditor/MarkdownModal.js +58 -0
- package/dist/components/markdownEditor/MarkdownModal.js.map +1 -0
- package/dist/components/markdownEditor/MarkdownPreview.d.ts +8 -0
- package/dist/components/markdownEditor/MarkdownPreview.d.ts.map +1 -0
- package/dist/components/markdownEditor/MarkdownPreview.js +35 -0
- package/dist/components/markdownEditor/MarkdownPreview.js.map +1 -0
- package/dist/components/markdownEditor/plugins/AutoLinkPlugin.d.ts +3 -0
- package/dist/components/markdownEditor/plugins/AutoLinkPlugin.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/AutoLinkPlugin.js +35 -0
- package/dist/components/markdownEditor/plugins/AutoLinkPlugin.js.map +1 -0
- package/dist/components/markdownEditor/plugins/ControlledEditorPlugin.d.ts +8 -0
- package/dist/components/markdownEditor/plugins/ControlledEditorPlugin.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/ControlledEditorPlugin.js +20 -0
- package/dist/components/markdownEditor/plugins/ControlledEditorPlugin.js.map +1 -0
- package/dist/components/markdownEditor/plugins/ListMaxIndentLevelPlugin.d.ts +2 -0
- package/dist/components/markdownEditor/plugins/ListMaxIndentLevelPlugin.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/ListMaxIndentLevelPlugin.js +46 -0
- package/dist/components/markdownEditor/plugins/ListMaxIndentLevelPlugin.js.map +1 -0
- package/dist/components/markdownEditor/plugins/MarkdownTransformers.d.ts +12 -0
- package/dist/components/markdownEditor/plugins/MarkdownTransformers.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/MarkdownTransformers.js +85 -0
- package/dist/components/markdownEditor/plugins/MarkdownTransformers.js.map +1 -0
- package/dist/components/markdownEditor/plugins/ReadOnlyPlugin.d.ts +6 -0
- package/dist/components/markdownEditor/plugins/ReadOnlyPlugin.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/ReadOnlyPlugin.js +13 -0
- package/dist/components/markdownEditor/plugins/ReadOnlyPlugin.js.map +1 -0
- package/dist/components/markdownEditor/plugins/ToolbarPlugin.d.ts +8 -0
- package/dist/components/markdownEditor/plugins/ToolbarPlugin.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/ToolbarPlugin.js +324 -0
- package/dist/components/markdownEditor/plugins/ToolbarPlugin.js.map +1 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNode.d.ts +27 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNode.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNode.js +158 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNode.js.map +1 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNodePlugin.d.ts +4 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNodePlugin.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNodePlugin.js +18 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNodePlugin.js.map +1 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNodeTransformer.d.ts +3 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNodeTransformer.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNodeTransformer.js +67 -0
- package/dist/components/markdownEditor/plugins/customLink/CustomLinkNodeTransformer.js.map +1 -0
- package/dist/components/markdownEditor/plugins/customLink/FloatingLinkEditor.d.ts +5 -0
- package/dist/components/markdownEditor/plugins/customLink/FloatingLinkEditor.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/customLink/FloatingLinkEditor.js +212 -0
- package/dist/components/markdownEditor/plugins/customLink/FloatingLinkEditor.js.map +1 -0
- package/dist/components/markdownEditor/plugins/customLink/FloatingLinkEditor.types.d.ts +11 -0
- package/dist/components/markdownEditor/plugins/customLink/FloatingLinkEditor.types.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/customLink/FloatingLinkEditor.types.js +3 -0
- package/dist/components/markdownEditor/plugins/customLink/FloatingLinkEditor.types.js.map +1 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiNode.d.ts +24 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiNode.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiNode.js +63 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiNode.js.map +1 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiNodeTransform.d.ts +4 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiNodeTransform.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiNodeTransform.js +35 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiNodeTransform.js.map +1 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiPickerPlugin.d.ts +10 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiPickerPlugin.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiPickerPlugin.js +99 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojiPickerPlugin.js.map +1 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojisPlugin.d.ts +11 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojisPlugin.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojisPlugin.js +55 -0
- package/dist/components/markdownEditor/plugins/emoji/EmojisPlugin.js.map +1 -0
- package/dist/components/markdownEditor/plugins/index.d.ts +7 -0
- package/dist/components/markdownEditor/plugins/index.d.ts.map +1 -0
- package/dist/components/markdownEditor/plugins/index.js +16 -0
- package/dist/components/markdownEditor/plugins/index.js.map +1 -0
- package/dist/components/markdownEditor/theme.d.ts +66 -0
- package/dist/components/markdownEditor/theme.d.ts.map +1 -0
- package/dist/components/markdownEditor/theme.js +69 -0
- package/dist/components/markdownEditor/theme.js.map +1 -0
- package/dist/components/material/AppList.d.ts +9 -0
- package/dist/components/material/AppList.d.ts.map +1 -0
- package/dist/components/material/AppList.js +21 -0
- package/dist/components/material/AppList.js.map +1 -0
- package/dist/components/material/ChurchList.d.ts +9 -0
- package/dist/components/material/ChurchList.d.ts.map +1 -0
- package/dist/components/material/ChurchList.js +25 -0
- package/dist/components/material/ChurchList.js.map +1 -0
- package/dist/components/material/NavItem.d.ts +14 -0
- package/dist/components/material/NavItem.d.ts.map +1 -0
- package/dist/components/material/NavItem.js +36 -0
- package/dist/components/material/NavItem.js.map +1 -0
- package/dist/components/material/NewPrivateMessage.d.ts +10 -0
- package/dist/components/material/NewPrivateMessage.d.ts.map +1 -0
- package/dist/components/material/NewPrivateMessage.js +96 -0
- package/dist/components/material/NewPrivateMessage.js.map +1 -0
- package/dist/components/material/PrivateMessageDetails.d.ts +10 -0
- package/dist/components/material/PrivateMessageDetails.d.ts.map +1 -0
- package/dist/components/material/PrivateMessageDetails.js +18 -0
- package/dist/components/material/PrivateMessageDetails.js.map +1 -0
- package/dist/components/material/PrivateMessages.d.ts +8 -0
- package/dist/components/material/PrivateMessages.d.ts.map +1 -0
- package/dist/components/material/PrivateMessages.js +105 -0
- package/dist/components/material/PrivateMessages.js.map +1 -0
- package/dist/components/material/SiteWrapper.d.ts +14 -0
- package/dist/components/material/SiteWrapper.d.ts.map +1 -0
- package/dist/components/material/SiteWrapper.js +120 -0
- package/dist/components/material/SiteWrapper.js.map +1 -0
- package/dist/components/material/UserMenu.d.ts +14 -0
- package/dist/components/material/UserMenu.d.ts.map +1 -0
- package/dist/components/material/UserMenu.js +98 -0
- package/dist/components/material/UserMenu.js.map +1 -0
- package/dist/components/material/iconPicker/IconNamesList.d.ts +3 -0
- package/dist/components/material/iconPicker/IconNamesList.d.ts.map +1 -0
- package/dist/components/material/iconPicker/IconNamesList.js +2241 -0
- package/dist/components/material/iconPicker/IconNamesList.js.map +1 -0
- package/dist/components/material/iconPicker/IconPicker.d.ts +7 -0
- package/dist/components/material/iconPicker/IconPicker.d.ts.map +1 -0
- package/dist/components/material/iconPicker/IconPicker.js +136 -0
- package/dist/components/material/iconPicker/IconPicker.js.map +1 -0
- package/dist/components/material/index.d.ts +6 -0
- package/dist/components/material/index.d.ts.map +1 -0
- package/dist/components/material/index.js +14 -0
- package/dist/components/material/index.js.map +1 -0
- package/dist/components/notes/AddNote.d.ts +12 -0
- package/dist/components/notes/AddNote.d.ts.map +1 -0
- package/dist/components/notes/AddNote.js +123 -0
- package/dist/components/notes/AddNote.js.map +1 -0
- package/dist/components/notes/Conversation.d.ts +11 -0
- package/dist/components/notes/Conversation.d.ts.map +1 -0
- package/dist/components/notes/Conversation.js +85 -0
- package/dist/components/notes/Conversation.js.map +1 -0
- package/dist/components/notes/Conversations.d.ts +11 -0
- package/dist/components/notes/Conversations.d.ts.map +1 -0
- package/dist/components/notes/Conversations.js +64 -0
- package/dist/components/notes/Conversations.js.map +1 -0
- package/dist/components/notes/NewConversation.d.ts +13 -0
- package/dist/components/notes/NewConversation.d.ts.map +1 -0
- package/dist/components/notes/NewConversation.js +86 -0
- package/dist/components/notes/NewConversation.js.map +1 -0
- package/dist/components/notes/Note.d.ts +9 -0
- package/dist/components/notes/Note.d.ts.map +1 -0
- package/dist/components/notes/Note.js +58 -0
- package/dist/components/notes/Note.js.map +1 -0
- package/dist/components/notes/Notes.d.ts +11 -0
- package/dist/components/notes/Notes.d.ts.map +1 -0
- package/dist/components/notes/Notes.js +59 -0
- package/dist/components/notes/Notes.js.map +1 -0
- package/dist/components/reporting/ChartReport.d.ts +9 -0
- package/dist/components/reporting/ChartReport.d.ts.map +1 -0
- package/dist/components/reporting/ChartReport.js +93 -0
- package/dist/components/reporting/ChartReport.js.map +1 -0
- package/dist/components/reporting/ReportFilter.d.ts +10 -0
- package/dist/components/reporting/ReportFilter.d.ts.map +1 -0
- package/dist/components/reporting/ReportFilter.js +54 -0
- package/dist/components/reporting/ReportFilter.js.map +1 -0
- package/dist/components/reporting/ReportFilterField.d.ts +10 -0
- package/dist/components/reporting/ReportFilterField.d.ts.map +1 -0
- package/dist/components/reporting/ReportFilterField.js +167 -0
- package/dist/components/reporting/ReportFilterField.js.map +1 -0
- package/dist/components/reporting/ReportOutput.d.ts +8 -0
- package/dist/components/reporting/ReportOutput.d.ts.map +1 -0
- package/dist/components/reporting/ReportOutput.js +95 -0
- package/dist/components/reporting/ReportOutput.js.map +1 -0
- package/dist/components/reporting/ReportWithFilter.d.ts +8 -0
- package/dist/components/reporting/ReportWithFilter.d.ts.map +1 -0
- package/dist/components/reporting/ReportWithFilter.js +67 -0
- package/dist/components/reporting/ReportWithFilter.js.map +1 -0
- package/dist/components/reporting/TableReport.d.ts +9 -0
- package/dist/components/reporting/TableReport.d.ts.map +1 -0
- package/dist/components/reporting/TableReport.js +50 -0
- package/dist/components/reporting/TableReport.js.map +1 -0
- package/dist/components/reporting/TreeReport.d.ts +9 -0
- package/dist/components/reporting/TreeReport.d.ts.map +1 -0
- package/dist/components/reporting/TreeReport.js +104 -0
- package/dist/components/reporting/TreeReport.js.map +1 -0
- package/dist/components/reporting/index.d.ts +5 -0
- package/dist/components/reporting/index.d.ts.map +1 -0
- package/dist/components/reporting/index.js +12 -0
- package/dist/components/reporting/index.js.map +1 -0
- package/dist/donationComponents/DonationPage.d.ts +9 -0
- package/dist/donationComponents/DonationPage.d.ts.map +1 -0
- package/dist/donationComponents/DonationPage.js +128 -0
- package/dist/donationComponents/DonationPage.js.map +1 -0
- package/dist/donationComponents/components/BankForm.d.ts +14 -0
- package/dist/donationComponents/components/BankForm.d.ts.map +1 -0
- package/dist/donationComponents/components/BankForm.js +161 -0
- package/dist/donationComponents/components/BankForm.js.map +1 -0
- package/dist/donationComponents/components/CardForm.d.ts +13 -0
- package/dist/donationComponents/components/CardForm.d.ts.map +1 -0
- package/dist/donationComponents/components/CardForm.js +128 -0
- package/dist/donationComponents/components/CardForm.js.map +1 -0
- package/dist/donationComponents/components/DonationForm.d.ts +14 -0
- package/dist/donationComponents/components/DonationForm.d.ts.map +1 -0
- package/dist/donationComponents/components/DonationForm.js +227 -0
- package/dist/donationComponents/components/DonationForm.js.map +1 -0
- package/dist/donationComponents/components/FundDonation.d.ts +11 -0
- package/dist/donationComponents/components/FundDonation.d.ts.map +1 -0
- package/dist/donationComponents/components/FundDonation.js +37 -0
- package/dist/donationComponents/components/FundDonation.js.map +1 -0
- package/dist/donationComponents/components/FundDonations.d.ts +10 -0
- package/dist/donationComponents/components/FundDonations.d.ts.map +1 -0
- package/dist/donationComponents/components/FundDonations.js +35 -0
- package/dist/donationComponents/components/FundDonations.js.map +1 -0
- package/dist/donationComponents/components/NonAuthDonation.d.ts +11 -0
- package/dist/donationComponents/components/NonAuthDonation.d.ts.map +1 -0
- package/dist/donationComponents/components/NonAuthDonation.js +40 -0
- package/dist/donationComponents/components/NonAuthDonation.js.map +1 -0
- package/dist/donationComponents/components/NonAuthDonationInner.d.ts +11 -0
- package/dist/donationComponents/components/NonAuthDonationInner.d.ts.map +1 -0
- package/dist/donationComponents/components/NonAuthDonationInner.js +246 -0
- package/dist/donationComponents/components/NonAuthDonationInner.js.map +1 -0
- package/dist/donationComponents/components/PaymentMethods.d.ts +14 -0
- package/dist/donationComponents/components/PaymentMethods.d.ts.map +1 -0
- package/dist/donationComponents/components/PaymentMethods.js +113 -0
- package/dist/donationComponents/components/PaymentMethods.js.map +1 -0
- package/dist/donationComponents/components/RecurringDonations.d.ts +10 -0
- package/dist/donationComponents/components/RecurringDonations.d.ts.map +1 -0
- package/dist/donationComponents/components/RecurringDonations.js +118 -0
- package/dist/donationComponents/components/RecurringDonations.js.map +1 -0
- package/dist/donationComponents/components/RecurringDonationsEdit.d.ts +11 -0
- package/dist/donationComponents/components/RecurringDonationsEdit.d.ts.map +1 -0
- package/dist/donationComponents/components/RecurringDonationsEdit.js +81 -0
- package/dist/donationComponents/components/RecurringDonationsEdit.js.map +1 -0
- package/dist/donationComponents/components/index.d.ts +10 -0
- package/dist/donationComponents/components/index.d.ts.map +1 -0
- package/dist/donationComponents/components/index.js +22 -0
- package/dist/donationComponents/components/index.js.map +1 -0
- package/dist/donationComponents/modals/DonationPreviewModal.d.ts +15 -0
- package/dist/donationComponents/modals/DonationPreviewModal.d.ts.map +1 -0
- package/dist/donationComponents/modals/DonationPreviewModal.js +73 -0
- package/dist/donationComponents/modals/DonationPreviewModal.js.map +1 -0
- package/dist/helpers/AnalyticsHelper.d.ts +7 -0
- package/dist/helpers/AnalyticsHelper.d.ts.map +1 -0
- package/dist/helpers/AnalyticsHelper.js +39 -0
- package/dist/helpers/AnalyticsHelper.js.map +1 -0
- package/dist/helpers/ApiHelper.d.ts +18 -0
- package/dist/helpers/ApiHelper.d.ts.map +1 -0
- package/dist/helpers/ApiHelper.js +145 -0
- package/dist/helpers/ApiHelper.js.map +1 -0
- package/dist/helpers/AppearanceHelper.d.ts +19 -0
- package/dist/helpers/AppearanceHelper.d.ts.map +1 -0
- package/dist/helpers/AppearanceHelper.js +64 -0
- package/dist/helpers/AppearanceHelper.js.map +1 -0
- package/dist/helpers/ArrayHelper.d.ts +12 -0
- package/dist/helpers/ArrayHelper.d.ts.map +1 -0
- package/dist/helpers/ArrayHelper.js +88 -0
- package/dist/helpers/ArrayHelper.js.map +1 -0
- package/dist/helpers/CommonEnvironmentHelper.d.ts +20 -0
- package/dist/helpers/CommonEnvironmentHelper.d.ts.map +1 -0
- package/dist/helpers/CommonEnvironmentHelper.js +82 -0
- package/dist/helpers/CommonEnvironmentHelper.js.map +1 -0
- package/dist/helpers/CurrencyHelper.d.ts +4 -0
- package/dist/helpers/CurrencyHelper.d.ts.map +1 -0
- package/dist/helpers/CurrencyHelper.js +15 -0
- package/dist/helpers/CurrencyHelper.js.map +1 -0
- package/dist/helpers/DateHelper.d.ts +19 -0
- package/dist/helpers/DateHelper.d.ts.map +1 -0
- package/dist/helpers/DateHelper.js +108 -0
- package/dist/helpers/DateHelper.js.map +1 -0
- package/dist/helpers/DonationHelper.d.ts +8 -0
- package/dist/helpers/DonationHelper.d.ts.map +1 -0
- package/dist/helpers/DonationHelper.js +33 -0
- package/dist/helpers/DonationHelper.js.map +1 -0
- package/dist/helpers/ErrorHelper.d.ts +13 -0
- package/dist/helpers/ErrorHelper.d.ts.map +1 -0
- package/dist/helpers/ErrorHelper.js +34 -0
- package/dist/helpers/ErrorHelper.js.map +1 -0
- package/dist/helpers/EventHelper.d.ts +11 -0
- package/dist/helpers/EventHelper.d.ts.map +1 -0
- package/dist/helpers/EventHelper.js +47 -0
- package/dist/helpers/EventHelper.js.map +1 -0
- package/dist/helpers/FileHelper.d.ts +5 -0
- package/dist/helpers/FileHelper.d.ts.map +1 -0
- package/dist/helpers/FileHelper.js +34 -0
- package/dist/helpers/FileHelper.js.map +1 -0
- package/dist/helpers/PersonHelper.d.ts +11 -0
- package/dist/helpers/PersonHelper.d.ts.map +1 -0
- package/dist/helpers/PersonHelper.js +53 -0
- package/dist/helpers/PersonHelper.js.map +1 -0
- package/dist/helpers/SocketHelper.d.ts +16 -0
- package/dist/helpers/SocketHelper.d.ts.map +1 -0
- package/dist/helpers/SocketHelper.js +87 -0
- package/dist/helpers/SocketHelper.js.map +1 -0
- package/dist/helpers/Themes.d.ts +9 -0
- package/dist/helpers/Themes.d.ts.map +1 -0
- package/dist/helpers/Themes.js +16 -0
- package/dist/helpers/Themes.js.map +1 -0
- package/dist/helpers/UniqueIdHelper.d.ts +9 -0
- package/dist/helpers/UniqueIdHelper.d.ts.map +1 -0
- package/dist/helpers/UniqueIdHelper.js +37 -0
- package/dist/helpers/UniqueIdHelper.js.map +1 -0
- package/dist/helpers/UserHelper.d.ts +14 -0
- package/dist/helpers/UserHelper.d.ts.map +1 -0
- package/dist/helpers/UserHelper.js +68 -0
- package/dist/helpers/UserHelper.js.map +1 -0
- package/dist/helpers/createEmotionCache.d.ts +2 -0
- package/dist/helpers/createEmotionCache.d.ts.map +1 -0
- package/dist/helpers/createEmotionCache.js +21 -0
- package/dist/helpers/createEmotionCache.js.map +1 -0
- package/dist/helpers/index.d.ts +16 -0
- package/dist/helpers/index.d.ts.map +1 -0
- package/dist/helpers/index.js +47 -0
- package/dist/helpers/index.js.map +1 -0
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/index.d.ts.map +1 -0
- package/dist/hooks/index.js +6 -0
- package/dist/hooks/index.js.map +1 -0
- package/dist/hooks/useMountedState.d.ts +2 -0
- package/dist/hooks/useMountedState.d.ts.map +1 -0
- package/dist/hooks/useMountedState.js +17 -0
- package/dist/hooks/useMountedState.js.map +1 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +25 -0
- package/dist/index.js.map +1 -0
- package/dist/interfaces/Access.d.ts +131 -0
- package/dist/interfaces/Access.d.ts.map +1 -0
- package/dist/interfaces/Access.js +3 -0
- package/dist/interfaces/Access.js.map +1 -0
- package/dist/interfaces/Attendance.d.ts +45 -0
- package/dist/interfaces/Attendance.d.ts.map +1 -0
- package/dist/interfaces/Attendance.js +3 -0
- package/dist/interfaces/Attendance.js.map +1 -0
- package/dist/interfaces/Content.d.ts +86 -0
- package/dist/interfaces/Content.d.ts.map +1 -0
- package/dist/interfaces/Content.js +3 -0
- package/dist/interfaces/Content.js.map +1 -0
- package/dist/interfaces/Doing.d.ts +50 -0
- package/dist/interfaces/Doing.d.ts.map +1 -0
- package/dist/interfaces/Doing.js +3 -0
- package/dist/interfaces/Doing.js.map +1 -0
- package/dist/interfaces/Donation.d.ts +138 -0
- package/dist/interfaces/Donation.d.ts.map +1 -0
- package/dist/interfaces/Donation.js +24 -0
- package/dist/interfaces/Donation.js.map +1 -0
- package/dist/interfaces/Error.d.ts +17 -0
- package/dist/interfaces/Error.d.ts.map +1 -0
- package/dist/interfaces/Error.js +4 -0
- package/dist/interfaces/Error.js.map +1 -0
- package/dist/interfaces/Membership.d.ts +172 -0
- package/dist/interfaces/Membership.d.ts.map +1 -0
- package/dist/interfaces/Membership.js +3 -0
- package/dist/interfaces/Membership.js.map +1 -0
- package/dist/interfaces/Messaging.d.ts +59 -0
- package/dist/interfaces/Messaging.d.ts.map +1 -0
- package/dist/interfaces/Messaging.js +3 -0
- package/dist/interfaces/Messaging.js.map +1 -0
- package/dist/interfaces/Permissions.d.ts +159 -0
- package/dist/interfaces/Permissions.d.ts.map +1 -0
- package/dist/interfaces/Permissions.js +67 -0
- package/dist/interfaces/Permissions.js.map +1 -0
- package/dist/interfaces/Reporting.d.ts +45 -0
- package/dist/interfaces/Reporting.d.ts.map +1 -0
- package/dist/interfaces/Reporting.js +3 -0
- package/dist/interfaces/Reporting.js.map +1 -0
- package/dist/interfaces/UserContextInterface.d.ts +13 -0
- package/dist/interfaces/UserContextInterface.d.ts.map +1 -0
- package/dist/interfaces/UserContextInterface.js +3 -0
- package/dist/interfaces/UserContextInterface.js.map +1 -0
- package/dist/interfaces/index.d.ts +11 -0
- package/dist/interfaces/index.d.ts.map +1 -0
- package/dist/interfaces/index.js +28 -0
- package/dist/interfaces/index.js.map +1 -0
- package/dist/pageComponents/LoginPage.d.ts +22 -0
- package/dist/pageComponents/LoginPage.d.ts.map +1 -0
- package/dist/pageComponents/LoginPage.js +287 -0
- package/dist/pageComponents/LoginPage.js.map +1 -0
- package/dist/pageComponents/LogoutPage.d.ts +8 -0
- package/dist/pageComponents/LogoutPage.d.ts.map +1 -0
- package/dist/pageComponents/LogoutPage.js +26 -0
- package/dist/pageComponents/LogoutPage.js.map +1 -0
- package/dist/pageComponents/components/Forgot.d.ts +8 -0
- package/dist/pageComponents/components/Forgot.d.ts.map +1 -0
- package/dist/pageComponents/components/Forgot.js +70 -0
- package/dist/pageComponents/components/Forgot.js.map +1 -0
- package/dist/pageComponents/components/Login.d.ts +13 -0
- package/dist/pageComponents/components/Login.d.ts.map +1 -0
- package/dist/pageComponents/components/Login.js +57 -0
- package/dist/pageComponents/components/Login.js.map +1 -0
- package/dist/pageComponents/components/LoginSetPassword.d.ts +13 -0
- package/dist/pageComponents/components/LoginSetPassword.d.ts.map +1 -0
- package/dist/pageComponents/components/LoginSetPassword.js +68 -0
- package/dist/pageComponents/components/LoginSetPassword.js.map +1 -0
- package/dist/pageComponents/components/Register.d.ts +12 -0
- package/dist/pageComponents/components/Register.d.ts.map +1 -0
- package/dist/pageComponents/components/Register.js +105 -0
- package/dist/pageComponents/components/Register.js.map +1 -0
- package/dist/pageComponents/components/SelectChurchModal.d.ts +13 -0
- package/dist/pageComponents/components/SelectChurchModal.d.ts.map +1 -0
- package/dist/pageComponents/components/SelectChurchModal.js +33 -0
- package/dist/pageComponents/components/SelectChurchModal.js.map +1 -0
- package/dist/pageComponents/components/SelectChurchRegister.d.ts +11 -0
- package/dist/pageComponents/components/SelectChurchRegister.d.ts.map +1 -0
- package/dist/pageComponents/components/SelectChurchRegister.js +114 -0
- package/dist/pageComponents/components/SelectChurchRegister.js.map +1 -0
- package/dist/pageComponents/components/SelectChurchSearch.d.ts +10 -0
- package/dist/pageComponents/components/SelectChurchSearch.d.ts.map +1 -0
- package/dist/pageComponents/components/SelectChurchSearch.js +61 -0
- package/dist/pageComponents/components/SelectChurchSearch.js.map +1 -0
- package/dist/pageComponents/components/SelectableChurch.d.ts +9 -0
- package/dist/pageComponents/components/SelectableChurch.d.ts.map +1 -0
- package/dist/pageComponents/components/SelectableChurch.js +31 -0
- package/dist/pageComponents/components/SelectableChurch.js.map +1 -0
- package/dist/pageComponents/index.d.ts +4 -0
- package/dist/pageComponents/index.d.ts.map +1 -0
- package/dist/pageComponents/index.js +10 -0
- package/dist/pageComponents/index.js.map +1 -0
- package/package.json +77 -0
- package/src/components/CreatePerson.tsx +80 -0
- package/src/components/DisplayBox.tsx +68 -0
- package/src/components/ErrorMessages.tsx +26 -0
- package/src/components/ExportLink.tsx +61 -0
- package/src/components/FloatingSupport.tsx +16 -0
- package/src/components/FormSubmissionEdit.tsx +122 -0
- package/src/components/HelpIcon.tsx +10 -0
- package/src/components/ImageEditor.tsx +126 -0
- package/src/components/InputBox.tsx +73 -0
- package/src/components/Loading.tsx +29 -0
- package/src/components/PersonAdd.tsx +75 -0
- package/src/components/QuestionEdit.tsx +62 -0
- package/src/components/SmallButton.tsx +39 -0
- package/src/components/SupportModal.tsx +26 -0
- package/src/components/TabPanel.tsx +34 -0
- package/src/components/gallery/GalleryModal.tsx +102 -0
- package/src/components/gallery/StockPhotos.tsx +74 -0
- package/src/components/index.tsx +18 -0
- package/src/components/markdownEditor/Editor.tsx +132 -0
- package/src/components/markdownEditor/MarkdownEditor.tsx +16 -0
- package/src/components/markdownEditor/MarkdownModal.tsx +46 -0
- package/src/components/markdownEditor/MarkdownPreview.tsx +14 -0
- package/src/components/markdownEditor/editor.css +787 -0
- package/src/components/markdownEditor/images/emoji/1F600.png +0 -0
- package/src/components/markdownEditor/images/emoji/1F641.png +0 -0
- package/src/components/markdownEditor/images/emoji/1F642.png +0 -0
- package/src/components/markdownEditor/images/emoji/2764.png +0 -0
- package/src/components/markdownEditor/images/icons/arrow-clockwise.svg +4 -0
- package/src/components/markdownEditor/images/icons/arrow-counterclockwise.svg +4 -0
- package/src/components/markdownEditor/images/icons/chat-square-quote.svg +4 -0
- package/src/components/markdownEditor/images/icons/chevron-down.svg +3 -0
- package/src/components/markdownEditor/images/icons/code.svg +3 -0
- package/src/components/markdownEditor/images/icons/journal-code.svg +5 -0
- package/src/components/markdownEditor/images/icons/journal-text.svg +5 -0
- package/src/components/markdownEditor/images/icons/justify.svg +3 -0
- package/src/components/markdownEditor/images/icons/link.svg +4 -0
- package/src/components/markdownEditor/images/icons/list-ol.svg +4 -0
- package/src/components/markdownEditor/images/icons/list-ul.svg +3 -0
- package/src/components/markdownEditor/images/icons/pencil-fill.svg +3 -0
- package/src/components/markdownEditor/images/icons/text-center.svg +3 -0
- package/src/components/markdownEditor/images/icons/text-left.svg +3 -0
- package/src/components/markdownEditor/images/icons/text-paragraph.svg +3 -0
- package/src/components/markdownEditor/images/icons/text-right.svg +3 -0
- package/src/components/markdownEditor/images/icons/type-bold.svg +3 -0
- package/src/components/markdownEditor/images/icons/type-h1.svg +3 -0
- package/src/components/markdownEditor/images/icons/type-h2.svg +3 -0
- package/src/components/markdownEditor/images/icons/type-h3.svg +3 -0
- package/src/components/markdownEditor/images/icons/type-h4.svg +13 -0
- package/src/components/markdownEditor/images/icons/type-italic.svg +3 -0
- package/src/components/markdownEditor/images/icons/type-strikethrough.svg +3 -0
- package/src/components/markdownEditor/images/icons/type-underline.svg +3 -0
- package/src/components/markdownEditor/plugins/AutoLinkPlugin.tsx +35 -0
- package/src/components/markdownEditor/plugins/ControlledEditorPlugin.tsx +24 -0
- package/src/components/markdownEditor/plugins/ListMaxIndentLevelPlugin.tsx +68 -0
- package/src/components/markdownEditor/plugins/MarkdownTransformers.ts +106 -0
- package/src/components/markdownEditor/plugins/ReadOnlyPlugin.tsx +15 -0
- package/src/components/markdownEditor/plugins/ToolbarPlugin.tsx +401 -0
- package/src/components/markdownEditor/plugins/customLink/CustomLinkNode.tsx +224 -0
- package/src/components/markdownEditor/plugins/customLink/CustomLinkNodePlugin.tsx +32 -0
- package/src/components/markdownEditor/plugins/customLink/CustomLinkNodeTransformer.tsx +102 -0
- package/src/components/markdownEditor/plugins/customLink/FloatingLinkEditor.tsx +243 -0
- package/src/components/markdownEditor/plugins/customLink/FloatingLinkEditor.types.ts +11 -0
- package/src/components/markdownEditor/plugins/emoji/EmojiNode.tsx +95 -0
- package/src/components/markdownEditor/plugins/emoji/EmojiNodeTransform.ts +41 -0
- package/src/components/markdownEditor/plugins/emoji/EmojiPickerPlugin.tsx +152 -0
- package/src/components/markdownEditor/plugins/emoji/EmojisPlugin.tsx +65 -0
- package/src/components/markdownEditor/plugins/index.ts +6 -0
- package/src/components/markdownEditor/theme.ts +65 -0
- package/src/components/material/AppList.tsx +20 -0
- package/src/components/material/ChurchList.tsx +22 -0
- package/src/components/material/NavItem.tsx +41 -0
- package/src/components/material/NewPrivateMessage.tsx +103 -0
- package/src/components/material/PrivateMessageDetails.tsx +23 -0
- package/src/components/material/PrivateMessages.tsx +87 -0
- package/src/components/material/SiteWrapper.tsx +140 -0
- package/src/components/material/UserMenu.tsx +141 -0
- package/src/components/material/iconPicker/IconNamesList.ts +2240 -0
- package/src/components/material/iconPicker/IconPicker.tsx +153 -0
- package/src/components/material/index.tsx +5 -0
- package/src/components/notes/AddNote.tsx +90 -0
- package/src/components/notes/Conversation.tsx +82 -0
- package/src/components/notes/Conversations.tsx +58 -0
- package/src/components/notes/NewConversation.tsx +78 -0
- package/src/components/notes/Note.tsx +44 -0
- package/src/components/notes/Notes.tsx +52 -0
- package/src/components/reporting/ChartReport.tsx +98 -0
- package/src/components/reporting/ReportFilter.tsx +54 -0
- package/src/components/reporting/ReportFilterField.tsx +160 -0
- package/src/components/reporting/ReportOutput.tsx +79 -0
- package/src/components/reporting/ReportWithFilter.tsx +70 -0
- package/src/components/reporting/TableReport.tsx +57 -0
- package/src/components/reporting/TreeReport.tsx +111 -0
- package/src/components/reporting/index.ts +4 -0
- package/src/donationComponents/DonationPage.tsx +136 -0
- package/src/donationComponents/components/BankForm.tsx +159 -0
- package/src/donationComponents/components/CardForm.tsx +104 -0
- package/src/donationComponents/components/DonationForm.tsx +228 -0
- package/src/donationComponents/components/FundDonation.tsx +49 -0
- package/src/donationComponents/components/FundDonations.tsx +39 -0
- package/src/donationComponents/components/NonAuthDonation.tsx +31 -0
- package/src/donationComponents/components/NonAuthDonationInner.tsx +208 -0
- package/src/donationComponents/components/PaymentMethods.tsx +135 -0
- package/src/donationComponents/components/RecurringDonations.tsx +121 -0
- package/src/donationComponents/components/RecurringDonationsEdit.tsx +93 -0
- package/src/donationComponents/components/index.tsx +9 -0
- package/src/donationComponents/modals/DonationPreviewModal.tsx +66 -0
- package/src/helpers/AnalyticsHelper.ts +33 -0
- package/src/helpers/ApiHelper.ts +125 -0
- package/src/helpers/AppearanceHelper.ts +69 -0
- package/src/helpers/ArrayHelper.ts +81 -0
- package/src/helpers/CommonEnvironmentHelper.ts +80 -0
- package/src/helpers/CurrencyHelper.ts +10 -0
- package/src/helpers/DateHelper.ts +108 -0
- package/src/helpers/DonationHelper.ts +26 -0
- package/src/helpers/ErrorHelper.ts +36 -0
- package/src/helpers/EventHelper.ts +52 -0
- package/src/helpers/FileHelper.ts +31 -0
- package/src/helpers/PersonHelper.ts +60 -0
- package/src/helpers/SocketHelper.ts +76 -0
- package/src/helpers/Themes.ts +14 -0
- package/src/helpers/UniqueIdHelper.ts +36 -0
- package/src/helpers/UserHelper.ts +59 -0
- package/src/helpers/createEmotionCache.ts +17 -0
- package/src/helpers/index.ts +15 -0
- package/src/hooks/index.ts +1 -0
- package/src/hooks/useMountedState.ts +16 -0
- package/src/index.ts +6 -0
- package/src/interfaces/Access.ts +24 -0
- package/src/interfaces/Attendance.ts +8 -0
- package/src/interfaces/Content.ts +10 -0
- package/src/interfaces/Doing.ts +24 -0
- package/src/interfaces/Donation.ts +45 -0
- package/src/interfaces/Error.ts +17 -0
- package/src/interfaces/Membership.ts +51 -0
- package/src/interfaces/Messaging.ts +20 -0
- package/src/interfaces/Permissions.ts +68 -0
- package/src/interfaces/Reporting.ts +7 -0
- package/src/interfaces/UserContextInterface.ts +13 -0
- package/src/interfaces/index.ts +12 -0
- package/src/pageComponents/LoginPage.tsx +244 -0
- package/src/pageComponents/LogoutPage.tsx +28 -0
- package/src/pageComponents/components/Forgot.tsx +79 -0
- package/src/pageComponents/components/Login.tsx +54 -0
- package/src/pageComponents/components/LoginSetPassword.tsx +63 -0
- package/src/pageComponents/components/Register.tsx +107 -0
- package/src/pageComponents/components/SelectChurchModal.tsx +41 -0
- package/src/pageComponents/components/SelectChurchRegister.tsx +88 -0
- package/src/pageComponents/components/SelectChurchSearch.tsx +69 -0
- package/src/pageComponents/components/SelectableChurch.tsx +38 -0
- package/src/pageComponents/index.ts +3 -0
- package/tsconfig.json +35 -0
- package/tslint.json +15 -0
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.EventHelper = void 0;
|
|
4
|
+
const rrule_1 = require("rrule");
|
|
5
|
+
class EventHelper {
|
|
6
|
+
}
|
|
7
|
+
exports.EventHelper = EventHelper;
|
|
8
|
+
EventHelper.getRange = (event, startDate, endDate) => {
|
|
9
|
+
const start = new Date(event.start);
|
|
10
|
+
const rrule = EventHelper.getFullRRule(event);
|
|
11
|
+
const dates = rrule.between(startDate, endDate);
|
|
12
|
+
dates.forEach(d => {
|
|
13
|
+
d.setHours(start.getHours());
|
|
14
|
+
d.setMinutes(start.getMinutes());
|
|
15
|
+
d.setSeconds(start.getSeconds());
|
|
16
|
+
});
|
|
17
|
+
return dates;
|
|
18
|
+
};
|
|
19
|
+
EventHelper.getFullRRule = (event) => {
|
|
20
|
+
let rrule = rrule_1.RRule.fromString(event.recurrenceRule);
|
|
21
|
+
rrule.options.dtstart = new Date(event.start);
|
|
22
|
+
console.log("START", rrule.options.dtstart, event.start, rrule);
|
|
23
|
+
return rrule;
|
|
24
|
+
};
|
|
25
|
+
EventHelper.removeExcludeDates = (events) => {
|
|
26
|
+
var _a;
|
|
27
|
+
for (let i = events.length - 1; i >= 0; i--) {
|
|
28
|
+
if (((_a = events[i].exceptionDates) === null || _a === void 0 ? void 0 : _a.length) > 0) {
|
|
29
|
+
const parsedDates = events[i].exceptionDates.map(d => new Date(d).toISOString());
|
|
30
|
+
//console.log("Compare", events[i].start.toISOString(), parsedDates, parsedDates.indexOf(events[i].start.toISOString()));
|
|
31
|
+
if (parsedDates.indexOf(events[i].start.toISOString()) > -1)
|
|
32
|
+
events.splice(i, 1);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
EventHelper.getPartialRRuleString = (options) => {
|
|
37
|
+
const parts = new rrule_1.RRule(options).toString().split("RRULE:");
|
|
38
|
+
const result = parts.length === 2 ? parts[1] : "";
|
|
39
|
+
console.log("getPartialRRuleString", options, new rrule_1.RRule(options).toString(), result);
|
|
40
|
+
return result;
|
|
41
|
+
};
|
|
42
|
+
EventHelper.cleanRule = (options) => {
|
|
43
|
+
options.byhour = undefined;
|
|
44
|
+
options.byminute = undefined;
|
|
45
|
+
options.bysecond = undefined;
|
|
46
|
+
};
|
|
47
|
+
//# sourceMappingURL=EventHelper.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"EventHelper.js","sourceRoot":"","sources":["../../src/helpers/EventHelper.ts"],"names":[],"mappings":";;;AACA,iCAAwC;AAGxC,MAAa,WAAW;;AAAxB,kCA+CC;AA7CQ,oBAAQ,GAAG,CAAC,KAAoB,EAAE,SAAc,EAAE,OAAY,EAAE,EAAE;IACvE,MAAM,KAAK,GAAG,IAAI,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IACpC,MAAM,KAAK,GAAG,WAAW,CAAC,YAAY,CAAC,KAAK,CAAC,CAAC;IAE9C,MAAM,KAAK,GAAG,KAAK,CAAC,OAAO,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC;IAEhD,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE;QAChB,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC;QAC7B,CAAC,CAAC,UAAU,CAAC,KAAK,CAAC,UAAU,EAAE,CAAC,CAAC;QACjC,CAAC,CAAC,UAAU,CAAC,KAAK,CAAC,UAAU,EAAE,CAAC,CAAC;IACnC,CAAC,CAAC,CAAA;IACF,OAAO,KAAK,CAAC;AACf,CAAC,CAAA;AAEM,wBAAY,GAAG,CAAC,KAAoB,EAAE,EAAE;IAC7C,IAAI,KAAK,GAAG,aAAK,CAAC,UAAU,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC;IACnD,KAAK,CAAC,OAAO,CAAC,OAAO,GAAG,IAAI,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IAC9C,OAAO,CAAC,GAAG,CAAC,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AG,CAAC,OAAqB,EAAE,EAAE;IAC3C,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC;IAC3B,OAAO,CAAC,QAAQ,GAAG,SAAS,CAAC;IAC7B,OAAO,CAAC,QAAQ,GAAG,SAAS,CAAC;AAC/B,CAAC,CAAA"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare class FileHelper {
|
|
2
|
+
static postPresignedFile: (presigned: any, uploadedFile: File, progressCallback: (percent: number) => void) => Promise<import("axios").AxiosResponse<any, any>>;
|
|
3
|
+
static dataURLtoBlob(dataurl: string): Blob;
|
|
4
|
+
}
|
|
5
|
+
//# sourceMappingURL=FileHelper.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"FileHelper.d.ts","sourceRoot":"","sources":["../../src/helpers/FileHelper.ts"],"names":[],"mappings":"AAEA,qBAAa,UAAU;IAErB,MAAM,CAAC,iBAAiB,cAAe,GAAG,gBAAgB,IAAI,8BAA8B,MAAM,KAAK,IAAI,sDAgBzG;IAEF,MAAM,CAAC,aAAa,CAAC,OAAO,EAAE,MAAM;CAQrC"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.FileHelper = void 0;
|
|
7
|
+
const axios_1 = __importDefault(require("axios"));
|
|
8
|
+
class FileHelper {
|
|
9
|
+
static dataURLtoBlob(dataurl) {
|
|
10
|
+
let arr = dataurl.split(","), mime = arr[0].match(/:(.*?);/)[1], bstr = atob(arr[1]), n = bstr.length, u8arr = new Uint8Array(n);
|
|
11
|
+
while (n--) {
|
|
12
|
+
u8arr[n] = bstr.charCodeAt(n);
|
|
13
|
+
}
|
|
14
|
+
return new Blob([u8arr], { type: mime });
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
exports.FileHelper = FileHelper;
|
|
18
|
+
FileHelper.postPresignedFile = (presigned, uploadedFile, progressCallback) => {
|
|
19
|
+
const formData = new FormData();
|
|
20
|
+
formData.append("key", presigned.key);
|
|
21
|
+
formData.append("acl", "public-read");
|
|
22
|
+
formData.append("Content-Type", uploadedFile.type);
|
|
23
|
+
for (const property in presigned.fields)
|
|
24
|
+
formData.append(property, presigned.fields[property]);
|
|
25
|
+
formData.append("file", uploadedFile);
|
|
26
|
+
const axiosConfig = {
|
|
27
|
+
headers: { "Content-Type": "multipart/form-data" },
|
|
28
|
+
onUploadProgress: (data) => {
|
|
29
|
+
progressCallback(Math.round((100 * data.loaded) / data.total));
|
|
30
|
+
}
|
|
31
|
+
};
|
|
32
|
+
return axios_1.default.post(presigned.url, formData, axiosConfig);
|
|
33
|
+
};
|
|
34
|
+
//# sourceMappingURL=FileHelper.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"FileHelper.js","sourceRoot":"","sources":["../../src/helpers/FileHelper.ts"],"names":[],"mappings":";;;;;;AAAA,kDAA0B;AAE1B,MAAa,UAAU;IAoBrB,MAAM,CAAC,aAAa,CAAC,OAAe;QAClC,IAAI,GAAG,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,IAAI,GAAG,GAAG,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,EAC7D,IAAI,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,MAAM,EAAE,KAAK,GAAG,IAAI,UAAU,CAAC,CAAC,CAAC,CAAC;QAClE,OAAO,CAAC,EAAE,EAAE;YACV,KAAK,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;SAC/B;QACD,OAAO,IAAI,IAAI,CAAC,CAAC,KAAK,CAAC,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC;IAC3C,CAAC;;AA3BH,gCA4BC;AA1BQ,4BAAiB,GAAG,CAAC,SAAc,EAAE,YAAkB,EAAE,gBAA2C,EAAE,EAAE;IAC7G,MAAM,QAAQ,GAAG,IAAI,QAAQ,EAAE,CAAC;IAChC,QAAQ,CAAC,MAAM,CAAC,KAAK,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IACtC,QAAQ,CAAC,MAAM,CAAC,KAAK,EAAE,aAAa,CAAC,CAAC;IACtC,QAAQ,CAAC,MAAM,CAAC,cAAc,EAAE,YAAY,CAAC,IAAI,CAAC,CAAC;IACnD,KAAK,MAAM,QAAQ,IAAI,SAAS,CAAC,MAAM;QAAE,QAAQ,CAAC,MAAM,CAAC,QAAQ,EAAE,SAAS,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC/F,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,YAAY,CAAC,CAAC;IAEtC,MAAM,WAAW,GAAG;QAClB,OAAO,EAAE,EAAE,cAAc,EAAE,qBAAqB,EAAE;QAClD,gBAAgB,EAAE,CAAC,IAAS,EAAE,EAAE;YAC9B,gBAAgB,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,GAAG,GAAG,IAAI,CAAC,MAAM,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC;QACjE,CAAC;KACF,CAAC;IAEF,OAAO,eAAK,CAAC,IAAI,CAAC,SAAS,CAAC,GAAG,EAAE,QAAQ,EAAE,WAAW,CAAC,CAAC;AAC1D,CAAC,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { PersonInterface, ContactInfoInterface } from "../interfaces";
|
|
2
|
+
export declare class PersonHelper {
|
|
3
|
+
static getPhotoUrl(person: PersonInterface): string;
|
|
4
|
+
static getAge(birthdate: Date): string;
|
|
5
|
+
static getDisplayName(firstName: string, lastName: string, nickName: string): string;
|
|
6
|
+
static compareAddress(address1: ContactInfoInterface, address2: ContactInfoInterface): boolean;
|
|
7
|
+
static addressToString(address: ContactInfoInterface): string;
|
|
8
|
+
static changeOnlyAddress(contactInfo1: ContactInfoInterface, contactInfo2: ContactInfoInterface): ContactInfoInterface;
|
|
9
|
+
static checkAddressAvailabilty(person: PersonInterface): boolean;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=PersonHelper.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PersonHelper.d.ts","sourceRoot":"","sources":["../../src/helpers/PersonHelper.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC;AAGtE,qBAAa,YAAY;IAEvB,MAAM,CAAC,WAAW,CAAC,MAAM,EAAE,eAAe;IAK1C,MAAM,CAAC,MAAM,CAAC,SAAS,EAAE,IAAI,GAAG,MAAM;IAUtC,MAAM,CAAC,cAAc,CAAC,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,GAAG,MAAM;WAKtE,cAAc,CAAC,QAAQ,EAAE,oBAAoB,EAAE,QAAQ,EAAE,oBAAoB,GAAG,OAAO;WAUvF,eAAe,CAAC,OAAO,EAAE,oBAAoB,GAAG,MAAM;WAItD,iBAAiB,CAAC,YAAY,EAAE,oBAAoB,EAAE,YAAY,EAAE,oBAAoB,GAAG,oBAAoB;WAa/G,uBAAuB,CAAC,MAAM,EAAE,eAAe,GAAG,OAAO;CAOxE"}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PersonHelper = void 0;
|
|
4
|
+
const CommonEnvironmentHelper_1 = require("./CommonEnvironmentHelper");
|
|
5
|
+
class PersonHelper {
|
|
6
|
+
static getPhotoUrl(person) {
|
|
7
|
+
var _a;
|
|
8
|
+
if (!(person === null || person === void 0 ? void 0 : person.photo))
|
|
9
|
+
return "/images/sample-profile.png";
|
|
10
|
+
else
|
|
11
|
+
return ((_a = person === null || person === void 0 ? void 0 : person.photo) === null || _a === void 0 ? void 0 : _a.startsWith("data:image/png;base64,")) ? person.photo : CommonEnvironmentHelper_1.CommonEnvironmentHelper.ContentRoot + person.photo;
|
|
12
|
+
}
|
|
13
|
+
static getAge(birthdate) {
|
|
14
|
+
if (birthdate !== undefined && birthdate !== null) {
|
|
15
|
+
let ageDifMs = Date.now() - new Date(birthdate).getTime();
|
|
16
|
+
let ageDate = new Date(ageDifMs);
|
|
17
|
+
let years = Math.abs(ageDate.getUTCFullYear() - 1970);
|
|
18
|
+
return years + " years";
|
|
19
|
+
}
|
|
20
|
+
else
|
|
21
|
+
return "";
|
|
22
|
+
}
|
|
23
|
+
static getDisplayName(firstName, lastName, nickName) {
|
|
24
|
+
if (nickName !== undefined && nickName !== null && nickName.length > 0)
|
|
25
|
+
return firstName + ' "' + nickName + '" ' + lastName;
|
|
26
|
+
else
|
|
27
|
+
return firstName + " " + lastName;
|
|
28
|
+
}
|
|
29
|
+
static compareAddress(address1, address2) {
|
|
30
|
+
const displayAddress1 = this.addressToString(address1).trim();
|
|
31
|
+
const displayAddress2 = this.addressToString(address2).trim();
|
|
32
|
+
if (displayAddress1 !== displayAddress2) {
|
|
33
|
+
return true;
|
|
34
|
+
}
|
|
35
|
+
return false;
|
|
36
|
+
}
|
|
37
|
+
static addressToString(address) {
|
|
38
|
+
return `${address.address1 || ""} ${address.address2 || ""} ${address.city || ""}${(address.city && address.state) ? "," : ""} ${address.state || ""} ${address.zip || ""}`;
|
|
39
|
+
}
|
|
40
|
+
static changeOnlyAddress(contactInfo1, contactInfo2) {
|
|
41
|
+
const updatedAddress = Object.assign(Object.assign({}, contactInfo1), { address1: contactInfo2.address1, address2: contactInfo2.address2, city: contactInfo2.city, state: contactInfo2.state, zip: contactInfo2.zip });
|
|
42
|
+
return updatedAddress;
|
|
43
|
+
}
|
|
44
|
+
static checkAddressAvailabilty(person) {
|
|
45
|
+
const addressString = this.addressToString(person.contactInfo).trim();
|
|
46
|
+
if (addressString !== "") {
|
|
47
|
+
return true;
|
|
48
|
+
}
|
|
49
|
+
return false;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
exports.PersonHelper = PersonHelper;
|
|
53
|
+
//# sourceMappingURL=PersonHelper.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PersonHelper.js","sourceRoot":"","sources":["../../src/helpers/PersonHelper.ts"],"names":[],"mappings":";;;AACA,uEAAoE;AAEpE,MAAa,YAAY;IAEvB,MAAM,CAAC,WAAW,CAAC,MAAuB;;QACxC,IAAI,CAAC,CAAA,MAAM,aAAN,MAAM,uBAAN,MAAM,CAAE,KAAK,CAAA;YAAE,OAAO,4BAA4B,CAAA;;YAClD,OAAO,CAAA,MAAA,MAAM,aAAN,MAAM,uBAAN,MAAM,CAAE,KAAK,0CAAE,UAAU,CAAC,wBAAwB,CAAC,EAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,iDAAuB,CAAC,WAAW,GAAG,MAAM,CAAC,KAAK,CAAC;IACtI,CAAC;IAED,MAAM,CAAC,MAAM,CAAC,SAAe;QAC3B,IAAI,SAAS,KAAK,SAAS,IAAI,SAAS,KAAK,IAAI,EAAE;YACjD,IAAI,QAAQ,GAAG,IAAI,CAAC,GAAG,EAAE,GAAG,IAAI,IAAI,CAAC,SAAS,CAAC,CAAC,OAAO,EAAE,CAAC;YAC1D,IAAI,OAAO,GAAG,IAAI,IAAI,CAAC,QAAQ,CAAC,CAAC;YACjC,IAAI,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC,OAAO,CAAC,cAAc,EAAE,GAAG,IAAI,CAAC,CAAC;YACtD,OAAO,KAAK,GAAG,QAAQ,CAAC;SACzB;;YACI,OAAO,EAAE,CAAC;IACjB,CAAC;IAED,MAAM,CAAC,cAAc,CAAC,SAAiB,EAAE,QAAgB,EAAE,QAAgB;QACzE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AEM,MAAM,CAAC,uBAAuB,CAAC,MAAuB;QAC3D,MAAM,aAAa,GAAW,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,IAAI,EAAE,CAAC;QAC9E,IAAI,aAAa,KAAK,EAAE,EAAE;YACxB,OAAO,IAAI,CAAC;SACb;QACD,OAAO,KAAK,CAAC;IACf,CAAC;CACF;AAxDD,oCAwDC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { SocketActionHandlerInterface, SocketPayloadInterface } from "../interfaces";
|
|
2
|
+
export declare class SocketHelper {
|
|
3
|
+
static socket: WebSocket;
|
|
4
|
+
static socketId: string;
|
|
5
|
+
static actionHandlers: SocketActionHandlerInterface[];
|
|
6
|
+
private static userIdChurchId;
|
|
7
|
+
static setUserChurch: (uc: {
|
|
8
|
+
userId: string;
|
|
9
|
+
churchId: string;
|
|
10
|
+
}) => void;
|
|
11
|
+
static createAlertConnection: () => void;
|
|
12
|
+
static init: () => Promise<void>;
|
|
13
|
+
static addHandler: (action: string, id: string, handleMessage: (data: any) => void) => void;
|
|
14
|
+
static handleMessage: (payload: SocketPayloadInterface) => void;
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=SocketHelper.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SocketHelper.d.ts","sourceRoot":"","sources":["../../src/helpers/SocketHelper.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiD,4BAA4B,EAAE,sBAAsB,EAAuB,MAAM,eAAe,CAAC;AAKzJ,qBAAa,YAAY;IACvB,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC;IACzB,MAAM,CAAC,QAAQ,EAAE,MAAM,CAAC;IACxB,MAAM,CAAC,cAAc,EAAE,4BAA4B,EAAE,CAAM;IAC3D,OAAO,CAAC,MAAM,CAAC,cAAc,CAA8D;IAE3F,MAAM,CAAC,aAAa,OAAQ;QAAC,MAAM,EAAC,MAAM,CAAC;QAAC,QAAQ,EAAC,MAAM,CAAA;KAAC,UAK3D;IAED,MAAM,CAAC,qBAAqB,aAK3B;IAED,MAAM,CAAC,IAAI,sBA8BV;IAED,MAAM,CAAC,UAAU,WAAY,MAAM,MAAM,MAAM,wBAAwB,GAAG,KAAK,IAAI,UAIlF;IAED,MAAM,CAAC,aAAa,YAAa,sBAAsB,UAUtD;CAEF"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
var _a;
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.SocketHelper = void 0;
|
|
14
|
+
const ApiHelper_1 = require("./ApiHelper");
|
|
15
|
+
const ArrayHelper_1 = require("./ArrayHelper");
|
|
16
|
+
const CommonEnvironmentHelper_1 = require("./CommonEnvironmentHelper");
|
|
17
|
+
class SocketHelper {
|
|
18
|
+
}
|
|
19
|
+
exports.SocketHelper = SocketHelper;
|
|
20
|
+
_a = SocketHelper;
|
|
21
|
+
SocketHelper.actionHandlers = [];
|
|
22
|
+
SocketHelper.userIdChurchId = { userId: "", churchId: "" };
|
|
23
|
+
SocketHelper.setUserChurch = (uc) => {
|
|
24
|
+
if ((uc === null || uc === void 0 ? void 0 : uc.churchId) && uc.userId && uc.churchId !== _a.userIdChurchId.churchId && uc.userId !== _a.userIdChurchId.userId) {
|
|
25
|
+
_a.userIdChurchId = uc;
|
|
26
|
+
_a.createAlertConnection();
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
SocketHelper.createAlertConnection = () => {
|
|
30
|
+
if (_a.userIdChurchId.userId) {
|
|
31
|
+
const connection = { conversationId: "alerts", churchId: _a.userIdChurchId.churchId, displayName: "Test", socketId: _a.socketId, userId: _a.userIdChurchId.userId };
|
|
32
|
+
ApiHelper_1.ApiHelper.postAnonymous("/connections", [connection], "MessagingApi");
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
SocketHelper.init = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
36
|
+
if (_a.socket !== undefined && _a.socket.readyState !== _a.socket.OPEN) {
|
|
37
|
+
try {
|
|
38
|
+
_a.socket.close();
|
|
39
|
+
}
|
|
40
|
+
catch (e) {
|
|
41
|
+
console.log(e);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
yield new Promise((resolve) => {
|
|
45
|
+
_a.socket = new WebSocket(CommonEnvironmentHelper_1.CommonEnvironmentHelper.MessagingApiSocket);
|
|
46
|
+
_a.socket.onmessage = (event) => {
|
|
47
|
+
const payload = JSON.parse(event.data);
|
|
48
|
+
_a.handleMessage(payload);
|
|
49
|
+
};
|
|
50
|
+
_a.socket.onopen = (e) => __awaiter(void 0, void 0, void 0, function* () {
|
|
51
|
+
_a.socket.send("getId"); //not sure this is needed. It auto-sends socketId on connect
|
|
52
|
+
setTimeout(() => { resolve(null); }, 500);
|
|
53
|
+
});
|
|
54
|
+
_a.socket.onclose = (e) => __awaiter(void 0, void 0, void 0, function* () {
|
|
55
|
+
//SocketHelper.events.disconnectHandler();
|
|
56
|
+
setTimeout(() => {
|
|
57
|
+
//Silently reconnect
|
|
58
|
+
if (_a.socket.readyState === _a.socket.CLOSED) {
|
|
59
|
+
_a.init().then(() => {
|
|
60
|
+
_a.createAlertConnection();
|
|
61
|
+
_a.handleMessage({ action: "reconnect", data: null });
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
}, 1000);
|
|
65
|
+
//SocketHelper.handleMessage({ action: "disconnect", data: null })
|
|
66
|
+
});
|
|
67
|
+
});
|
|
68
|
+
});
|
|
69
|
+
SocketHelper.addHandler = (action, id, handleMessage) => {
|
|
70
|
+
const existing = ArrayHelper_1.ArrayHelper.getOne(_a.actionHandlers, "id", id);
|
|
71
|
+
if (existing !== null)
|
|
72
|
+
existing.handleMessage = handleMessage;
|
|
73
|
+
else
|
|
74
|
+
_a.actionHandlers.push({ action, id, handleMessage });
|
|
75
|
+
};
|
|
76
|
+
SocketHelper.handleMessage = (payload) => {
|
|
77
|
+
//console.log("MESSAGE", payload)
|
|
78
|
+
if (payload.action === "socketId") {
|
|
79
|
+
_a.socketId = payload.data;
|
|
80
|
+
}
|
|
81
|
+
else {
|
|
82
|
+
ArrayHelper_1.ArrayHelper.getAll(_a.actionHandlers, "action", payload.action).forEach((handler) => {
|
|
83
|
+
handler.handleMessage(payload.data);
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
};
|
|
87
|
+
//# sourceMappingURL=SocketHelper.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SocketHelper.js","sourceRoot":"","sources":["../../src/helpers/SocketHelper.ts"],"names":[],"mappings":";;;;;;;;;;;;;AACA,2CAAwC;AACxC,+CAA4C;AAC5C,uEAAoE;AAEpE,MAAa,YAAY;;AAAzB,oCAsEC;;AAnEQ,2BAAc,GAAmC,EAAE,AAArC,CAAsC;AAC5C,2BAAc,GAAqC,EAAC,MAAM,EAAC,EAAE,EAAE,QAAQ,EAAC,EAAE,EAAC,AAA7D,CAA8D;AAEpF,0BAAa,GAAG,CAAC,EAAoC,EAAE,EAAE;IAC9D,IAAI,CAAA,EAAE,aAAF,EAAE,uBAAF,EAAE,CAAE,QAAQ,KAAI,EAAE,CAAC,MAAM,IAAI,EAAE,CAAC,QAAQ,KAAG,EAAI,CAAC,cAAc,CAAC,QAAQ,IAAI,EAAE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G,CAAC,OAA+B,EAAE,EAAE;IACzD,iCAAiC;IACjC,IAAI,OAAO,CAAC,MAAM,KAAG,UAAU,EAAE;QAC/B,EAAY,CAAC,QAAQ,GAAG,OAAO,CAAC,IAAI,CAAC;KACtC;SACI;QACH,yBAAW,CAAC,MAAM,CAAC,EAAY,CAAC,cAAc,EAAE,QAAQ,EAAE,OAAO,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;YAC5F,OAAO,CAAC,aAAa,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;QACtC,CAAC,CAAC,CAAC;KACJ;AACH,CAAC,AAVmB,CAUnB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Themes.d.ts","sourceRoot":"","sources":["../../src/helpers/Themes.ts"],"names":[],"mappings":"AAEA,qBAAa,MAAM;IACjB,MAAM,CAAC,SAAS,gCAMb;IAEH,MAAM,CAAC,WAAW;;;;MAA4E;CAE/F"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Themes = void 0;
|
|
4
|
+
const material_1 = require("@mui/material");
|
|
5
|
+
class Themes {
|
|
6
|
+
}
|
|
7
|
+
exports.Themes = Themes;
|
|
8
|
+
Themes.BaseTheme = (0, material_1.createTheme)({
|
|
9
|
+
palette: { secondary: { main: "#444444" } },
|
|
10
|
+
components: {
|
|
11
|
+
MuiTextField: { defaultProps: { margin: "normal" } },
|
|
12
|
+
MuiFormControl: { defaultProps: { margin: "normal" } }
|
|
13
|
+
}
|
|
14
|
+
});
|
|
15
|
+
Themes.NavBarStyle = { "& .selected .MuiListItemButton-root": { backgroundColor: "#333333" } };
|
|
16
|
+
//# sourceMappingURL=Themes.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Themes.js","sourceRoot":"","sources":["../../src/helpers/Themes.ts"],"names":[],"mappings":";;;AAAA,4CAA4C;AAE5C,MAAa,MAAM;;AAAnB,wBAWC;AAVQ,gBAAS,GAAG,IAAA,sBAAW,EAAC;IAC7B,OAAO,EAAE,EAAE,SAAS,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,EAAE;IAC3C,UAAU,EAAE;QACV,YAAY,EAAE,EAAE,YAAY,EAAE,EAAE,MAAM,EAAE,QAAQ,EAAE,EAAE;QACpD,cAAc,EAAE,EAAE,YAAY,EAAE,EAAE,MAAM,EAAE,QAAQ,EAAE,EAAE;KACvD;CACF,CAAC,CAAC;AAEI,kBAAW,GAAG,EAAE,qCAAqC,EAAE,EAAE,eAAe,EAAE,SAAS,EAAE,EAAE,CAAA"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export declare class UniqueIdHelper {
|
|
2
|
+
static chars: string[];
|
|
3
|
+
static alphanumericChars: string[];
|
|
4
|
+
static isMissing(obj: any): boolean;
|
|
5
|
+
static shortId(): string;
|
|
6
|
+
static generateAlphanumeric(): string;
|
|
7
|
+
static generate(charList: string[], length: number): string;
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=UniqueIdHelper.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"UniqueIdHelper.d.ts","sourceRoot":"","sources":["../../src/helpers/UniqueIdHelper.ts"],"names":[],"mappings":"AAAA,qBAAa,cAAc;IAEzB,MAAM,CAAC,KAAK,WAGA;IAEZ,MAAM,CAAC,iBAAiB,WAEiC;WAE3C,SAAS,CAAC,GAAG,EAAE,GAAG;WAMlB,OAAO;WAIP,oBAAoB;WAIpB,QAAQ,CAAC,QAAQ,EAAE,MAAM,EAAE,EAAE,MAAM,EAAE,MAAM;CAU1D"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UniqueIdHelper = void 0;
|
|
4
|
+
class UniqueIdHelper {
|
|
5
|
+
static isMissing(obj) {
|
|
6
|
+
if (obj === undefined || obj === null)
|
|
7
|
+
return true;
|
|
8
|
+
else if (obj.toString() === "")
|
|
9
|
+
return true;
|
|
10
|
+
else
|
|
11
|
+
return false;
|
|
12
|
+
}
|
|
13
|
+
static shortId() {
|
|
14
|
+
return this.generate(UniqueIdHelper.chars, 11);
|
|
15
|
+
}
|
|
16
|
+
static generateAlphanumeric() {
|
|
17
|
+
return this.generate(UniqueIdHelper.alphanumericChars, 11);
|
|
18
|
+
}
|
|
19
|
+
static generate(charList, length) {
|
|
20
|
+
let result = "";
|
|
21
|
+
for (let i = 0; i < length; i++) {
|
|
22
|
+
const idx = Math.floor(Math.random() * charList.length);
|
|
23
|
+
const c = charList[idx];
|
|
24
|
+
result += c;
|
|
25
|
+
}
|
|
26
|
+
return result;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
exports.UniqueIdHelper = UniqueIdHelper;
|
|
30
|
+
UniqueIdHelper.chars = ["A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z",
|
|
31
|
+
"a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z",
|
|
32
|
+
"0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "0",
|
|
33
|
+
"-", "_"];
|
|
34
|
+
UniqueIdHelper.alphanumericChars = ["A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z",
|
|
35
|
+
"a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z",
|
|
36
|
+
"0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "0"];
|
|
37
|
+
//# sourceMappingURL=UniqueIdHelper.js.map
|
|
@@ -0,0 +1 @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AE,GAAG;IAChI,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { UserInterface, UserContextInterface, IPermission, PersonInterface, LoginUserChurchInterface } from "../interfaces";
|
|
2
|
+
export declare class UserHelper {
|
|
3
|
+
static currentUserChurch: LoginUserChurchInterface;
|
|
4
|
+
static userChurches: LoginUserChurchInterface[];
|
|
5
|
+
static user: UserInterface;
|
|
6
|
+
static churchChanged: boolean;
|
|
7
|
+
static person: PersonInterface;
|
|
8
|
+
static selectChurch: (context?: UserContextInterface, churchId?: string, keyName?: string) => Promise<void>;
|
|
9
|
+
static setupApiHelper(userChurch: LoginUserChurchInterface): void;
|
|
10
|
+
static setupApiHelperNoChurch(user: LoginUserChurchInterface): void;
|
|
11
|
+
static checkAccess({ api, contentType, action }: IPermission): boolean;
|
|
12
|
+
static createAppUrl(appUrl: string, returnUrl: string): string;
|
|
13
|
+
}
|
|
14
|
+
//# sourceMappingURL=UserHelper.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"UserHelper.d.ts","sourceRoot":"","sources":["../../src/helpers/UserHelper.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,WAAW,EAAE,eAAe,EAAE,wBAAwB,EAAE,MAAM,eAAe,CAAC;AAE5H,qBAAa,UAAU;IACrB,MAAM,CAAC,iBAAiB,EAAE,wBAAwB,CAAC;IACnD,MAAM,CAAC,YAAY,EAAE,wBAAwB,EAAE,CAAC;IAChD,MAAM,CAAC,IAAI,EAAE,aAAa,CAAC;IAC3B,MAAM,CAAC,aAAa,EAAE,OAAO,CAAS;IACtC,MAAM,CAAC,MAAM,EAAE,eAAe,CAAC;IAE/B,MAAM,CAAC,YAAY,aAAoB,oBAAoB,aAAa,MAAM,YAAY,MAAM,mBAoB/F;IAED,MAAM,CAAC,cAAc,CAAC,UAAU,EAAE,wBAAwB;IAK1D,MAAM,CAAC,sBAAsB,CAAC,IAAI,EAAE,wBAAwB;IAI5D,MAAM,CAAC,WAAW,CAAC,EAAE,GAAG,EAAE,WAAW,EAAE,MAAM,EAAE,EAAE,WAAW,GAAG,OAAO;IAYtE,MAAM,CAAC,YAAY,CAAC,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM;CAKtD"}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
var _a;
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
exports.UserHelper = void 0;
|
|
14
|
+
const ApiHelper_1 = require("./ApiHelper");
|
|
15
|
+
class UserHelper {
|
|
16
|
+
static setupApiHelper(userChurch) {
|
|
17
|
+
ApiHelper_1.ApiHelper.setDefaultPermissions(userChurch.jwt);
|
|
18
|
+
userChurch.apis.forEach(api => { ApiHelper_1.ApiHelper.setPermissions(api.keyName, api.jwt, api.permissions); });
|
|
19
|
+
}
|
|
20
|
+
static setupApiHelperNoChurch(user) {
|
|
21
|
+
ApiHelper_1.ApiHelper.setDefaultPermissions(user.jwt);
|
|
22
|
+
}
|
|
23
|
+
static checkAccess({ api, contentType, action }) {
|
|
24
|
+
const permissions = ApiHelper_1.ApiHelper.getConfig(api).permisssions;
|
|
25
|
+
let result = false;
|
|
26
|
+
if (permissions !== undefined) {
|
|
27
|
+
permissions.forEach(element => {
|
|
28
|
+
if (element.contentType === contentType && element.action === action)
|
|
29
|
+
result = true;
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
return result;
|
|
33
|
+
}
|
|
34
|
+
static createAppUrl(appUrl, returnUrl) {
|
|
35
|
+
const jwt = ApiHelper_1.ApiHelper.getConfig("MembershipApi").jwt;
|
|
36
|
+
return `${appUrl}/login/?jwt=${jwt}&returnUrl=${returnUrl}`;
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
exports.UserHelper = UserHelper;
|
|
40
|
+
_a = UserHelper;
|
|
41
|
+
UserHelper.churchChanged = false;
|
|
42
|
+
UserHelper.selectChurch = (context, churchId, keyName) => __awaiter(void 0, void 0, void 0, function* () {
|
|
43
|
+
let userChurch = null;
|
|
44
|
+
if (churchId) {
|
|
45
|
+
_a.userChurches.forEach(uc => {
|
|
46
|
+
if (uc.church.id === churchId)
|
|
47
|
+
userChurch = uc;
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
else if (keyName)
|
|
51
|
+
_a.userChurches.forEach(uc => { if (uc.church.subDomain === keyName)
|
|
52
|
+
userChurch = uc; });
|
|
53
|
+
else
|
|
54
|
+
userChurch = _a.userChurches[0];
|
|
55
|
+
if (!userChurch)
|
|
56
|
+
return;
|
|
57
|
+
else {
|
|
58
|
+
_a.currentUserChurch = userChurch;
|
|
59
|
+
_a.setupApiHelper(_a.currentUserChurch);
|
|
60
|
+
// TODO - remove context code from here and perform the logic in the component itself.
|
|
61
|
+
if (context) {
|
|
62
|
+
if (context.userChurch !== null)
|
|
63
|
+
_a.churchChanged = true;
|
|
64
|
+
context.setUserChurch(_a.currentUserChurch);
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
});
|
|
68
|
+
//# sourceMappingURL=UserHelper.js.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AAC;;AAtDH,gCAuDC;;AAnDQ,wBAAa,GAAY,KAAK,AAAjB,CAAkB;AAG/B,uBAAY,GAAG,CAAO,OAA8B,EAAE,QAAiB,EAAE,OAAgB,EAAE,EAAE;IAClG,IAAI,UAAU,GAAG,IAAI,CAAC;IAEtB,IAAI,QAAQ,EAAE;QACZ,EAAU,CAAC,YAAY,CAAC,OAAO,CAAC,EAAE,CAAC,EAAE;YACnC,IAAI,EAAE,CAAC,MAAM,CAAC,EAAE,KAAK,QAAQ;gBAAE,UAAU,GAAG,EAAE,CAAC;QACjD,CAAC,CAAC,CAAC;KACJ;SACI,IAAI,OAAO;QAAE,EAAU,CAAC,YAAY,CAAC,OAAO,CAAC,EAAE,CAAC,EAAE,GAAG,IAAI,EAAE,CAAC,MAAM,CAAC,SAAS,KAAK,OAAO;YAAE,UAAU,GAAG,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;;QAC9G,UAAU,GAAG,EAAU,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC;IAC7C,IAAI,CAAC,UAAU;QAAE,OAAO;SACnB;QACH,EAAU,CAAC,iBAAiB,GAAG,UAAU,CAAC;QAC1C,EAAU,CAAC,cAAc,CAAC,EAAU,CAAC,iBAAiB,CAAC,CAAC;QACxD,sFAAsF;QACtF,IAAI,OAAO,EAAE;YACX,IAAI,OAAO,CAAC,UAAU,KAAK,IAAI;gBAAE,EAAU,CAAC,aAAa,GAAG,IAAI,CAAC;YACjE,OAAO,CAAC,aAAa,CAAC,EAAU,CAAC,iBAAiB,CAAC,CAAC;SACrD;KACF;AACH,CAAC,CAAA,AApBkB,CAoBlB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"createEmotionCache.d.ts","sourceRoot":"","sources":["../../src/helpers/createEmotionCache.ts"],"names":[],"mappings":"AAOA,wBAAgB,kBAAkB,0CASjC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.createEmotionCache = void 0;
|
|
7
|
+
const cache_1 = __importDefault(require("@emotion/cache"));
|
|
8
|
+
const isBrowser = typeof document !== "undefined";
|
|
9
|
+
// On the client side, Create a meta tag at the top of the <head> and set it as insertionPoint.
|
|
10
|
+
// This assures that MUI styles are loaded first.
|
|
11
|
+
// It allows developers to easily override MUI styles with other styling solutions, like CSS modules.
|
|
12
|
+
function createEmotionCache() {
|
|
13
|
+
let insertionPoint;
|
|
14
|
+
if (isBrowser) {
|
|
15
|
+
const emotionInsertionPoint = document.querySelector('meta[name="emotion-insertion-point"]');
|
|
16
|
+
insertionPoint = emotionInsertionPoint !== null && emotionInsertionPoint !== void 0 ? emotionInsertionPoint : undefined;
|
|
17
|
+
}
|
|
18
|
+
return (0, cache_1.default)({ key: "mui-style", insertionPoint });
|
|
19
|
+
}
|
|
20
|
+
exports.createEmotionCache = createEmotionCache;
|
|
21
|
+
//# sourceMappingURL=createEmotionCache.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"createEmotionCache.js","sourceRoot":"","sources":["../../src/helpers/createEmotionCache.ts"],"names":[],"mappings":";;;;;;AAAA,2DAAyC;AAEzC,MAAM,SAAS,GAAG,OAAO,QAAQ,KAAK,WAAW,CAAC;AAElD,+FAA+F;AAC/F,iDAAiD;AACjD,qGAAqG;AACrG,SAAgB,kBAAkB;IAChC,IAAI,cAAc,CAAC;IAEnB,IAAI,SAAS,EAAE;QACb,MAAM,qBAAqB,GAAG,QAAQ,CAAC,aAAa,CAAkB,sCAAsC,CAAC,CAAC;QAC9G,cAAc,GAAG,qBAAqB,aAArB,qBAAqB,cAArB,qBAAqB,GAAI,SAAS,CAAC;KACrD;IAED,OAAO,IAAA,eAAW,EAAC,EAAE,GAAG,EAAE,WAAW,EAAE,cAAc,EAAE,CAAC,CAAC;AAC3D,CAAC;AATD,gDASC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export * from "@churchapps/helpers";
|
|
2
|
+
export { AnalyticsHelper } from "./AnalyticsHelper";
|
|
3
|
+
export { ApiHelper } from "./ApiHelper";
|
|
4
|
+
export { ArrayHelper } from "./ArrayHelper";
|
|
5
|
+
export { CommonEnvironmentHelper } from "./CommonEnvironmentHelper";
|
|
6
|
+
export { CurrencyHelper } from "./CurrencyHelper";
|
|
7
|
+
export { DateHelper } from "./DateHelper";
|
|
8
|
+
export { FileHelper } from "./FileHelper";
|
|
9
|
+
export { PersonHelper } from "./PersonHelper";
|
|
10
|
+
export { Themes } from "./Themes";
|
|
11
|
+
export { UserHelper } from "./UserHelper";
|
|
12
|
+
export { UniqueIdHelper } from "./UniqueIdHelper";
|
|
13
|
+
export { createEmotionCache } from "./createEmotionCache";
|
|
14
|
+
export { DonationHelper } from "./DonationHelper";
|
|
15
|
+
export { AppearanceInterface, AppearanceHelper } from "./AppearanceHelper";
|
|
16
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/helpers/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC;AACpE,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAA;AACjD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAA;AAC7C,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAA;AACjC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAClD,OAAO,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
exports.AppearanceHelper = exports.DonationHelper = exports.createEmotionCache = exports.UniqueIdHelper = exports.UserHelper = exports.Themes = exports.PersonHelper = exports.FileHelper = exports.DateHelper = exports.CurrencyHelper = exports.CommonEnvironmentHelper = exports.ArrayHelper = exports.ApiHelper = exports.AnalyticsHelper = void 0;
|
|
18
|
+
__exportStar(require("@churchapps/helpers"), exports);
|
|
19
|
+
var AnalyticsHelper_1 = require("./AnalyticsHelper");
|
|
20
|
+
Object.defineProperty(exports, "AnalyticsHelper", { enumerable: true, get: function () { return AnalyticsHelper_1.AnalyticsHelper; } });
|
|
21
|
+
var ApiHelper_1 = require("./ApiHelper");
|
|
22
|
+
Object.defineProperty(exports, "ApiHelper", { enumerable: true, get: function () { return ApiHelper_1.ApiHelper; } });
|
|
23
|
+
var ArrayHelper_1 = require("./ArrayHelper");
|
|
24
|
+
Object.defineProperty(exports, "ArrayHelper", { enumerable: true, get: function () { return ArrayHelper_1.ArrayHelper; } });
|
|
25
|
+
var CommonEnvironmentHelper_1 = require("./CommonEnvironmentHelper");
|
|
26
|
+
Object.defineProperty(exports, "CommonEnvironmentHelper", { enumerable: true, get: function () { return CommonEnvironmentHelper_1.CommonEnvironmentHelper; } });
|
|
27
|
+
var CurrencyHelper_1 = require("./CurrencyHelper");
|
|
28
|
+
Object.defineProperty(exports, "CurrencyHelper", { enumerable: true, get: function () { return CurrencyHelper_1.CurrencyHelper; } });
|
|
29
|
+
var DateHelper_1 = require("./DateHelper");
|
|
30
|
+
Object.defineProperty(exports, "DateHelper", { enumerable: true, get: function () { return DateHelper_1.DateHelper; } });
|
|
31
|
+
var FileHelper_1 = require("./FileHelper");
|
|
32
|
+
Object.defineProperty(exports, "FileHelper", { enumerable: true, get: function () { return FileHelper_1.FileHelper; } });
|
|
33
|
+
var PersonHelper_1 = require("./PersonHelper");
|
|
34
|
+
Object.defineProperty(exports, "PersonHelper", { enumerable: true, get: function () { return PersonHelper_1.PersonHelper; } });
|
|
35
|
+
var Themes_1 = require("./Themes");
|
|
36
|
+
Object.defineProperty(exports, "Themes", { enumerable: true, get: function () { return Themes_1.Themes; } });
|
|
37
|
+
var UserHelper_1 = require("./UserHelper");
|
|
38
|
+
Object.defineProperty(exports, "UserHelper", { enumerable: true, get: function () { return UserHelper_1.UserHelper; } });
|
|
39
|
+
var UniqueIdHelper_1 = require("./UniqueIdHelper");
|
|
40
|
+
Object.defineProperty(exports, "UniqueIdHelper", { enumerable: true, get: function () { return UniqueIdHelper_1.UniqueIdHelper; } });
|
|
41
|
+
var createEmotionCache_1 = require("./createEmotionCache");
|
|
42
|
+
Object.defineProperty(exports, "createEmotionCache", { enumerable: true, get: function () { return createEmotionCache_1.createEmotionCache; } });
|
|
43
|
+
var DonationHelper_1 = require("./DonationHelper");
|
|
44
|
+
Object.defineProperty(exports, "DonationHelper", { enumerable: true, get: function () { return DonationHelper_1.DonationHelper; } });
|
|
45
|
+
var AppearanceHelper_1 = require("./AppearanceHelper");
|
|
46
|
+
Object.defineProperty(exports, "AppearanceHelper", { enumerable: true, get: function () { return AppearanceHelper_1.AppearanceHelper; } });
|
|
47
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/helpers/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,sDAAoC;AACpC,qDAAoD;AAA3C,kHAAA,eAAe,OAAA;AACxB,yCAAwC;AAA/B,sGAAA,SAAS,OAAA;AAClB,6CAA4C;AAAnC,0GAAA,WAAW,OAAA;AACpB,qEAAoE;AAA3D,kIAAA,uBAAuB,OAAA;AAChC,mDAAiD;AAAxC,gHAAA,cAAc,OAAA;AACvB,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,+CAA6C;AAApC,4GAAA,YAAY,OAAA;AACrB,mCAAiC;AAAxB,gGAAA,MAAM,OAAA;AACf,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,mDAAkD;AAAzC,gHAAA,cAAc,OAAA;AACvB,2DAA0D;AAAjD,wHAAA,kBAAkB,OAAA;AAC3B,mDAAkD;AAAzC,gHAAA,cAAc,OAAA;AACvB,uDAA2E;AAA7C,oHAAA,gBAAgB,OAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/hooks/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.useMountedState = void 0;
|
|
4
|
+
var useMountedState_1 = require("./useMountedState");
|
|
5
|
+
Object.defineProperty(exports, "useMountedState", { enumerable: true, get: function () { return useMountedState_1.useMountedState; } });
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/hooks/index.ts"],"names":[],"mappings":";;;AAAA,qDAAoD;AAA3C,kHAAA,eAAe,OAAA"}
|