@churchapps/apphelper 0.4.6 → 0.4.8
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/CHUMS_COMPONENT_EXTRACTION_CANDIDATES.md +210 -0
- package/COMPONENT_USAGE_REPORT.md +322 -0
- package/dist/components/header/SecondaryMenu.js +3 -3
- package/dist/components/header/SecondaryMenu.js.map +1 -1
- package/dist/components/index.d.ts +0 -2
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +1 -5
- package/dist/components/index.js.map +1 -1
- package/dist/helpers/FileHelper.d.ts +1 -1
- package/dist/helpers/FileHelper.d.ts.map +1 -1
- package/dist/helpers/FileHelper.js +2 -6
- package/dist/helpers/FileHelper.js.map +1 -1
- package/dist/index.d.ts +0 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +0 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/components/header/SecondaryMenu.tsx +3 -3
- package/src/components/index.tsx +0 -2
- package/src/helpers/FileHelper.ts +3 -6
- package/src/index.ts +0 -1
- package/dist/components/CreatePerson.d.ts +0 -15
- package/dist/components/CreatePerson.d.ts.map +0 -1
- package/dist/components/CreatePerson.js +0 -100
- package/dist/components/CreatePerson.js.map +0 -1
- package/dist/components/PersonAdd.d.ts +0 -16
- package/dist/components/PersonAdd.d.ts.map +0 -1
- package/dist/components/PersonAdd.js +0 -52
- package/dist/components/PersonAdd.js.map +0 -1
- package/dist/donationComponents/DonationPage.d.ts +0 -11
- package/dist/donationComponents/DonationPage.d.ts.map +0 -1
- package/dist/donationComponents/DonationPage.js +0 -149
- package/dist/donationComponents/DonationPage.js.map +0 -1
- package/dist/donationComponents/components/BankForm.d.ts +0 -14
- package/dist/donationComponents/components/BankForm.d.ts.map +0 -1
- package/dist/donationComponents/components/BankForm.js +0 -125
- package/dist/donationComponents/components/BankForm.js.map +0 -1
- package/dist/donationComponents/components/CardForm.d.ts +0 -13
- package/dist/donationComponents/components/CardForm.d.ts.map +0 -1
- package/dist/donationComponents/components/CardForm.js +0 -122
- package/dist/donationComponents/components/CardForm.js.map +0 -1
- package/dist/donationComponents/components/DonationForm.d.ts +0 -15
- package/dist/donationComponents/components/DonationForm.d.ts.map +0 -1
- package/dist/donationComponents/components/DonationForm.js +0 -200
- package/dist/donationComponents/components/DonationForm.js.map +0 -1
- package/dist/donationComponents/components/FundDonation.d.ts +0 -12
- package/dist/donationComponents/components/FundDonation.d.ts.map +0 -1
- package/dist/donationComponents/components/FundDonation.js +0 -32
- package/dist/donationComponents/components/FundDonation.js.map +0 -1
- package/dist/donationComponents/components/FundDonations.d.ts +0 -11
- package/dist/donationComponents/components/FundDonations.d.ts.map +0 -1
- package/dist/donationComponents/components/FundDonations.js +0 -33
- package/dist/donationComponents/components/FundDonations.js.map +0 -1
- package/dist/donationComponents/components/NonAuthDonation.d.ts +0 -12
- package/dist/donationComponents/components/NonAuthDonation.d.ts.map +0 -1
- package/dist/donationComponents/components/NonAuthDonation.js +0 -27
- package/dist/donationComponents/components/NonAuthDonation.js.map +0 -1
- package/dist/donationComponents/components/NonAuthDonationInner.d.ts +0 -12
- package/dist/donationComponents/components/NonAuthDonationInner.d.ts.map +0 -1
- package/dist/donationComponents/components/NonAuthDonationInner.js +0 -276
- package/dist/donationComponents/components/NonAuthDonationInner.js.map +0 -1
- package/dist/donationComponents/components/PaymentMethods.d.ts +0 -14
- package/dist/donationComponents/components/PaymentMethods.d.ts.map +0 -1
- package/dist/donationComponents/components/PaymentMethods.js +0 -86
- package/dist/donationComponents/components/PaymentMethods.js.map +0 -1
- package/dist/donationComponents/components/RecurringDonations.d.ts +0 -10
- package/dist/donationComponents/components/RecurringDonations.d.ts.map +0 -1
- package/dist/donationComponents/components/RecurringDonations.js +0 -93
- package/dist/donationComponents/components/RecurringDonations.js.map +0 -1
- package/dist/donationComponents/components/RecurringDonationsEdit.d.ts +0 -11
- package/dist/donationComponents/components/RecurringDonationsEdit.d.ts.map +0 -1
- package/dist/donationComponents/components/RecurringDonationsEdit.js +0 -66
- package/dist/donationComponents/components/RecurringDonationsEdit.js.map +0 -1
- package/dist/donationComponents/components/index.d.ts +0 -10
- package/dist/donationComponents/components/index.d.ts.map +0 -1
- package/dist/donationComponents/components/index.js +0 -22
- package/dist/donationComponents/components/index.js.map +0 -1
- package/dist/donationComponents/index.d.ts +0 -4
- package/dist/donationComponents/index.d.ts.map +0 -1
- package/dist/donationComponents/index.js +0 -10
- package/dist/donationComponents/index.js.map +0 -1
- package/dist/donationComponents/modals/DonationPreviewModal.d.ts +0 -15
- package/dist/donationComponents/modals/DonationPreviewModal.d.ts.map +0 -1
- package/dist/donationComponents/modals/DonationPreviewModal.js +0 -33
- package/dist/donationComponents/modals/DonationPreviewModal.js.map +0 -1
- package/src/components/CreatePerson.tsx +0 -135
- package/src/components/PersonAdd.tsx +0 -81
- package/src/donationComponents/DonationPage.tsx +0 -214
- package/src/donationComponents/components/BankForm.tsx +0 -161
- package/src/donationComponents/components/CardForm.tsx +0 -106
- package/src/donationComponents/components/DonationForm.tsx +0 -255
- package/src/donationComponents/components/FundDonation.tsx +0 -58
- package/src/donationComponents/components/FundDonations.tsx +0 -44
- package/src/donationComponents/components/NonAuthDonation.tsx +0 -33
- package/src/donationComponents/components/NonAuthDonationInner.tsx +0 -295
- package/src/donationComponents/components/PaymentMethods.tsx +0 -137
- package/src/donationComponents/components/RecurringDonations.tsx +0 -123
- package/src/donationComponents/components/RecurringDonationsEdit.tsx +0 -95
- package/src/donationComponents/components/index.tsx +0 -9
- package/src/donationComponents/index.ts +0 -3
- package/src/donationComponents/modals/DonationPreviewModal.tsx +0 -68
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
# ChumsApp Component Extraction Candidates
|
|
2
|
+
|
|
3
|
+
Generated on: 2025-07-04
|
|
4
|
+
|
|
5
|
+
## Executive Summary
|
|
6
|
+
|
|
7
|
+
This document identifies AppHelper components that are only used by ChumsApp and recommends their extraction to reduce AppHelper's scope and improve architectural separation. The analysis focuses on components that represent CHUMS-specific business logic rather than general church management functionality.
|
|
8
|
+
|
|
9
|
+
## Extraction Candidates
|
|
10
|
+
|
|
11
|
+
### 🟢 Strong Candidates for Extraction
|
|
12
|
+
|
|
13
|
+
#### 1. Person Management Components
|
|
14
|
+
**Components**: `PersonAdd`, `CreatePerson`
|
|
15
|
+
**Used by**: ChumsApp only
|
|
16
|
+
**Size**: 2 components
|
|
17
|
+
|
|
18
|
+
**Business Logic**:
|
|
19
|
+
- Person search and addition to groups/households
|
|
20
|
+
- CHUMS-specific membership management workflows
|
|
21
|
+
- Integration with MembershipApi for person operations
|
|
22
|
+
- Group-specific filtering and validation logic
|
|
23
|
+
|
|
24
|
+
**Benefits of Extraction**:
|
|
25
|
+
- Moves CHUMS-specific membership logic to CHUMS
|
|
26
|
+
- Reduces AppHelper's dependency on MembershipApi patterns
|
|
27
|
+
- Allows CHUMS team to iterate on person management independently
|
|
28
|
+
|
|
29
|
+
**Migration Effort**: Low - self-contained components with minimal dependencies
|
|
30
|
+
|
|
31
|
+
---
|
|
32
|
+
|
|
33
|
+
#### 2. Complete Donation Management System
|
|
34
|
+
**Components**:
|
|
35
|
+
- `DonationPage` (main donation interface)
|
|
36
|
+
- `FundDonations` (fund management)
|
|
37
|
+
- `FundDonation` (individual fund component)
|
|
38
|
+
- All components in `/donationComponents/`:
|
|
39
|
+
- `DonationForm`, `NonAuthDonation`, `NonAuthDonationInner`
|
|
40
|
+
- `PaymentMethods`, `RecurringDonations`, `RecurringDonationsEdit`
|
|
41
|
+
- `BankForm`, `CardForm`, `FormCardPayment`
|
|
42
|
+
- `DonationPreviewModal`
|
|
43
|
+
|
|
44
|
+
**Used by**: ChumsApp only (B1App uses different donation components)
|
|
45
|
+
**Size**: ~13 components + entire donation module
|
|
46
|
+
|
|
47
|
+
**Business Logic**:
|
|
48
|
+
- Complete Stripe payment processing workflow
|
|
49
|
+
- Recurring donation management
|
|
50
|
+
- Fund-based donation allocation
|
|
51
|
+
- CHUMS-specific donation reporting and history
|
|
52
|
+
- Payment method management and storage
|
|
53
|
+
|
|
54
|
+
**Benefits of Extraction**:
|
|
55
|
+
- **Massive size reduction** for AppHelper (removes entire donation module)
|
|
56
|
+
- Eliminates Stripe dependencies from AppHelper
|
|
57
|
+
- Allows CHUMS-specific donation features without affecting other apps
|
|
58
|
+
- Reduces bundle size for non-donation apps (B1App, LessonsApp)
|
|
59
|
+
- Cleaner separation between different donation workflows (CHUMS vs B1)
|
|
60
|
+
|
|
61
|
+
**Migration Effort**: Medium - requires moving entire module and updating imports
|
|
62
|
+
|
|
63
|
+
---
|
|
64
|
+
|
|
65
|
+
### 🟡 Moderate Candidates (Recommend Keeping)
|
|
66
|
+
|
|
67
|
+
#### 3. Notes/Messaging System
|
|
68
|
+
**Components**: `Notes`, `Note`, `AddNote`, `Conversation`, `Conversations`, `NewConversation`
|
|
69
|
+
**Used by**: ChumsApp only currently
|
|
70
|
+
**Size**: 6 components
|
|
71
|
+
|
|
72
|
+
**Analysis**:
|
|
73
|
+
- **Business Logic**: Generic messaging/conversation functionality
|
|
74
|
+
- **API Integration**: Uses MessagingApi (separate microservice)
|
|
75
|
+
- **Reusability**: High potential for use by other church apps
|
|
76
|
+
- **Current State**: Only used by CHUMS but architecturally generic
|
|
77
|
+
|
|
78
|
+
**Recommendation**: **Keep in AppHelper**
|
|
79
|
+
**Reasoning**: Messaging is a universal need across church applications. The MessagingApi already provides good separation of concerns.
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
#### 4. Reporting Infrastructure
|
|
84
|
+
**Components**: `ReportWithFilter`, `ReportFilter`, `ReportFilterField`, `ReportOutput`, `ChartReport`, `TableReport`, `TreeReport`
|
|
85
|
+
**Used by**: ChumsApp only currently
|
|
86
|
+
**Size**: 7 components
|
|
87
|
+
|
|
88
|
+
**Analysis**:
|
|
89
|
+
- **Business Logic**: Generic reporting with filtering capabilities
|
|
90
|
+
- **API Integration**: Uses ReportingApi (separate microservice)
|
|
91
|
+
- **Reusability**: High potential for other apps' reporting needs
|
|
92
|
+
- **Architecture**: Well-abstracted reporting infrastructure
|
|
93
|
+
|
|
94
|
+
**Recommendation**: **Keep in AppHelper**
|
|
95
|
+
**Reasoning**: Reporting is universal church management functionality that other apps will likely need.
|
|
96
|
+
|
|
97
|
+
---
|
|
98
|
+
|
|
99
|
+
## Impact Analysis
|
|
100
|
+
|
|
101
|
+
### AppHelper Size Reduction
|
|
102
|
+
- **Total components to extract**: 15 components (PersonAdd/CreatePerson + entire donation system)
|
|
103
|
+
- **Percentage reduction**: ~29% of total components (15 out of 51)
|
|
104
|
+
- **Bundle size impact**: Significant reduction due to removal of Stripe and donation logic
|
|
105
|
+
|
|
106
|
+
### Dependency Cleanup
|
|
107
|
+
**Dependencies to remove from AppHelper**:
|
|
108
|
+
- Stripe payment processing libraries
|
|
109
|
+
- CHUMS-specific MembershipApi patterns
|
|
110
|
+
- Donation-related TypeScript interfaces
|
|
111
|
+
- Payment method validation logic
|
|
112
|
+
|
|
113
|
+
### Breaking Changes
|
|
114
|
+
**Projects affected**: ChumsApp only
|
|
115
|
+
**Migration required**:
|
|
116
|
+
- Update imports in ChumsApp
|
|
117
|
+
- Move components to ChumsApp's component directory
|
|
118
|
+
- Update build processes to include new components
|
|
119
|
+
|
|
120
|
+
---
|
|
121
|
+
|
|
122
|
+
## Recommended Extraction Strategy
|
|
123
|
+
|
|
124
|
+
### Phase 1: Donation System Migration
|
|
125
|
+
1. **Create donation module in ChumsApp**
|
|
126
|
+
- Copy all donation components to `src/donationComponents/`
|
|
127
|
+
- Update internal imports to use local components
|
|
128
|
+
- Test donation functionality in ChumsApp
|
|
129
|
+
|
|
130
|
+
2. **Update ChumsApp imports**
|
|
131
|
+
- Replace `@churchapps/apphelper` donation imports with local imports
|
|
132
|
+
- Verify all donation workflows still function
|
|
133
|
+
|
|
134
|
+
3. **Remove from AppHelper**
|
|
135
|
+
- Delete donation components from AppHelper
|
|
136
|
+
- Remove Stripe dependencies
|
|
137
|
+
- Update AppHelper exports
|
|
138
|
+
- Publish new AppHelper version
|
|
139
|
+
|
|
140
|
+
### Phase 2: Person Management Migration
|
|
141
|
+
1. **Move person components to ChumsApp**
|
|
142
|
+
- Copy `PersonAdd` and `CreatePerson` to ChumsApp
|
|
143
|
+
- Update imports in ChumsApp files
|
|
144
|
+
|
|
145
|
+
2. **Test and validate**
|
|
146
|
+
- Ensure person management workflows still work
|
|
147
|
+
- Verify no regression in membership features
|
|
148
|
+
|
|
149
|
+
3. **Clean up AppHelper**
|
|
150
|
+
- Remove person components
|
|
151
|
+
- Update exports
|
|
152
|
+
- Publish updated version
|
|
153
|
+
|
|
154
|
+
### Phase 3: Validation and Cleanup
|
|
155
|
+
1. **Verify other projects**
|
|
156
|
+
- Ensure B1App, LessonsApp, etc. still work with new AppHelper
|
|
157
|
+
- Update any accidentally broken imports
|
|
158
|
+
|
|
159
|
+
2. **Documentation update**
|
|
160
|
+
- Update component usage documentation
|
|
161
|
+
- Create migration guide for teams
|
|
162
|
+
|
|
163
|
+
---
|
|
164
|
+
|
|
165
|
+
## Benefits Summary
|
|
166
|
+
|
|
167
|
+
### For AppHelper
|
|
168
|
+
- **Smaller bundle size**: Removes ~29% of components
|
|
169
|
+
- **Cleaner scope**: Focuses on truly shared church management components
|
|
170
|
+
- **Fewer dependencies**: Removes Stripe and CHUMS-specific integrations
|
|
171
|
+
- **Better maintainability**: Less complex codebase
|
|
172
|
+
|
|
173
|
+
### For ChumsApp
|
|
174
|
+
- **Faster iteration**: Can modify donation and person management without affecting other apps
|
|
175
|
+
- **Direct control**: Full ownership of CHUMS-specific business logic
|
|
176
|
+
- **Customization freedom**: Can add CHUMS-specific features without AppHelper constraints
|
|
177
|
+
|
|
178
|
+
### For Other Projects
|
|
179
|
+
- **Smaller downloads**: Don't download unused donation code
|
|
180
|
+
- **Fewer dependencies**: Less bloat from CHUMS-specific functionality
|
|
181
|
+
- **Cleaner imports**: Only import actually relevant components
|
|
182
|
+
|
|
183
|
+
---
|
|
184
|
+
|
|
185
|
+
## Risk Assessment
|
|
186
|
+
|
|
187
|
+
### Low Risk
|
|
188
|
+
- Person management extraction (small, self-contained)
|
|
189
|
+
- Well-tested existing functionality
|
|
190
|
+
|
|
191
|
+
### Medium Risk
|
|
192
|
+
- Donation system extraction (large codebase move)
|
|
193
|
+
- Multiple component dependencies
|
|
194
|
+
- Stripe integration complexity
|
|
195
|
+
|
|
196
|
+
### Mitigation Strategies
|
|
197
|
+
- **Gradual migration**: Move components in phases
|
|
198
|
+
- **Thorough testing**: Test all donation workflows after migration
|
|
199
|
+
- **Rollback plan**: Keep original components until migration is fully validated
|
|
200
|
+
- **Documentation**: Clear migration guide for future reference
|
|
201
|
+
|
|
202
|
+
---
|
|
203
|
+
|
|
204
|
+
## Conclusion
|
|
205
|
+
|
|
206
|
+
The donation management system represents the largest opportunity for extraction, removing a significant amount of CHUMS-specific code from AppHelper while providing clear architectural benefits. The person management components are smaller but equally CHUMS-specific and should also be extracted.
|
|
207
|
+
|
|
208
|
+
The messaging and reporting systems, while currently only used by CHUMS, represent generic church management functionality that other applications will likely need and should remain in AppHelper.
|
|
209
|
+
|
|
210
|
+
**Recommended Action**: Proceed with extraction of donation system and person management components, prioritizing the donation system due to its size and impact.
|
|
@@ -0,0 +1,322 @@
|
|
|
1
|
+
# @churchapps/apphelper Component Usage Report
|
|
2
|
+
|
|
3
|
+
Generated on: 2025-07-04
|
|
4
|
+
|
|
5
|
+
## Executive Summary
|
|
6
|
+
|
|
7
|
+
This report analyzes the usage of @churchapps/apphelper components across active projects in the LCS ecosystem. The package exports 34 React components, 14 helper utilities, and numerous TypeScript interfaces.
|
|
8
|
+
|
|
9
|
+
**Note**: As of this report, donation management components (15 components) and person management components (2 components) have been moved from AppHelper to ChumsApp for better architectural separation.
|
|
10
|
+
|
|
11
|
+
### Projects Using @churchapps/apphelper
|
|
12
|
+
|
|
13
|
+
| Project | Version | Location | Primary Use Case |
|
|
14
|
+
|---------|---------|----------|------------------|
|
|
15
|
+
| **B1App** | 0.4.1 | `/mnt/e/LCS/B1/B1App/` | Main B1 platform application |
|
|
16
|
+
| **ChumsApp** | 0.4.7 | `/mnt/e/LCS/Chums/ChumsApp/` | Church management system |
|
|
17
|
+
| **ChumsTransfer** | 0.4.7 | `/mnt/e/LCS/Chums/ChumsTransfer/` | Church data transfer tool |
|
|
18
|
+
| **LessonsApp** | ^0.3.46 | `/mnt/e/LCS/Lessons/LessonsApp/` | Lessons management |
|
|
19
|
+
| **ChurchAppsWeb** | 0.0.5 | `/mnt/e/LCS/ChurchApps/ChurchAppsWeb/` | ChurchApps web platform |
|
|
20
|
+
|
|
21
|
+
## Component Usage Matrix
|
|
22
|
+
|
|
23
|
+
**Legend**:
|
|
24
|
+
- ✅ = Used from @churchapps/apphelper
|
|
25
|
+
- 🏠 = Moved to local project (no longer in AppHelper)
|
|
26
|
+
- ❌ = Not used
|
|
27
|
+
|
|
28
|
+
### Core UI Components
|
|
29
|
+
|
|
30
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
31
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
32
|
+
| **DisplayBox** | ✅ | ✅ | ✅ | ✅ | ❌ |
|
|
33
|
+
| **Loading** | ✅ | ✅ | ❌ | ✅ | ❌ |
|
|
34
|
+
| **SmallButton** | ✅ | ✅ | ❌ | ✅ | ❌ |
|
|
35
|
+
| **InputBox** | ✅ | ✅ | ❌ | ✅ | ❌ |
|
|
36
|
+
| **ErrorMessages** | ✅ | ✅ | ❌ | ✅ | ❌ |
|
|
37
|
+
| **Banner** | ✅ | ✅ | ❌ | ✅ | ❌ |
|
|
38
|
+
| **ExportLink** | ✅ | ✅ | ❌ | ❌ | ❌ |
|
|
39
|
+
| **HelpIcon** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
40
|
+
| **TabPanel** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
41
|
+
|
|
42
|
+
### Authentication Components
|
|
43
|
+
|
|
44
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
45
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
46
|
+
| **LoginPage** | ✅ | ✅ | ✅ | ✅ | ✅ |
|
|
47
|
+
| **LogoutPage** | ✅ | ✅ | ✅ | ✅ | ❌ |
|
|
48
|
+
| **Register** | ❌ | ❌ | ❌ | ✅ | ✅ |
|
|
49
|
+
|
|
50
|
+
### Form & Input Components
|
|
51
|
+
|
|
52
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
53
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
54
|
+
| **CreatePerson** | ❌ | 🏠 | ❌ | ❌ | ❌ |
|
|
55
|
+
| **PersonAdd** | ❌ | 🏠 | ❌ | ❌ | ❌ |
|
|
56
|
+
| **FormSubmissionEdit** | ✅ | ✅ | ❌ | ❌ | ❌ |
|
|
57
|
+
| **QuestionEdit** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
58
|
+
| **ImageEditor** | ✅ | ✅ | ❌ | ❌ | ❌ |
|
|
59
|
+
| **IconPicker** | ✅ | ❌ | ❌ | ❌ | ❌ |
|
|
60
|
+
|
|
61
|
+
### Rich Text Components
|
|
62
|
+
|
|
63
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
64
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
65
|
+
| **MarkdownEditor** | ✅ | ✅ | ❌ | ✅ | ❌ |
|
|
66
|
+
| **MarkdownPreview** | ✅ | ✅ | ❌ | ❌ | ❌ |
|
|
67
|
+
| **MarkdownPreviewLight** | ✅ | ❌ | ❌ | ✅ | ❌ |
|
|
68
|
+
|
|
69
|
+
### Communication Components
|
|
70
|
+
|
|
71
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
72
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
73
|
+
| **Conversations** | ✅ | ❌ | ❌ | ❌ | ❌ |
|
|
74
|
+
| **Conversation** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
75
|
+
| **Notes** | ❌ | ✅ | ❌ | ❌ | ❌ |
|
|
76
|
+
| **Note** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
77
|
+
| **AddNote** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
78
|
+
| **NewPrivateMessage** | ✅ | ❌ | ❌ | ❌ | ❌ |
|
|
79
|
+
| **PrivateMessageDetails** | ✅ | ❌ | ❌ | ❌ | ❌ |
|
|
80
|
+
| **NewConversation** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
81
|
+
|
|
82
|
+
### Donation Components
|
|
83
|
+
|
|
84
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
85
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
86
|
+
| **DonationPage** | ❌ | 🏠 | ❌ | ❌ | ❌ |
|
|
87
|
+
| **DonationForm** | ✅ | 🏠 | ❌ | ❌ | ❌ |
|
|
88
|
+
| **NonAuthDonation** | ✅ | 🏠 | ❌ | ❌ | ❌ |
|
|
89
|
+
| **NonAuthDonationInner** | ❌ | 🏠 | ❌ | ❌ | ❌ |
|
|
90
|
+
| **PaymentMethods** | ✅ | 🏠 | ❌ | ❌ | ❌ |
|
|
91
|
+
| **RecurringDonations** | ✅ | 🏠 | ❌ | ❌ | ❌ |
|
|
92
|
+
| **RecurringDonationsEdit** | ❌ | 🏠 | ❌ | ❌ | ❌ |
|
|
93
|
+
| **FundDonations** | ❌ | 🏠 | ❌ | ❌ | ❌ |
|
|
94
|
+
| **FundDonation** | ❌ | 🏠 | ❌ | ❌ | ❌ |
|
|
95
|
+
| **BankForm** | ❌ | 🏠 | ❌ | ❌ | ❌ |
|
|
96
|
+
| **CardForm** | ❌ | 🏠 | ❌ | ❌ | ❌ |
|
|
97
|
+
| **FormCardPayment** | ❌ | 🏠 | ❌ | ❌ | ❌ |
|
|
98
|
+
| **DonationPreviewModal** | ❌ | 🏠 | ❌ | ❌ | ❌ |
|
|
99
|
+
|
|
100
|
+
### Gallery & Media Components
|
|
101
|
+
|
|
102
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
103
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
104
|
+
| **GalleryModal** | ✅ | ❌ | ❌ | ❌ | ❌ |
|
|
105
|
+
| **StockPhotos** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
106
|
+
| **B1ShareModal** | ✅ | ❌ | ❌ | ✅ | ❌ |
|
|
107
|
+
|
|
108
|
+
### Support Components
|
|
109
|
+
|
|
110
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
111
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
112
|
+
| **FloatingSupport** | ❌ | ❌ | ❌ | ✅ | ✅ |
|
|
113
|
+
| **SupportModal** | ❌ | ❌ | ❌ | ✅ | ❌ |
|
|
114
|
+
| **SupportDrawer** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
115
|
+
|
|
116
|
+
### Reporting Components
|
|
117
|
+
|
|
118
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
119
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
120
|
+
| **ReportWithFilter** | ❌ | ✅ | ❌ | ❌ | ❌ |
|
|
121
|
+
| **ReportFilter** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
122
|
+
| **ReportFilterField** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
123
|
+
| **ReportOutput** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
124
|
+
| **ChartReport** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
125
|
+
| **TableReport** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
126
|
+
| **TreeReport** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
127
|
+
|
|
128
|
+
### Header & Navigation Components
|
|
129
|
+
|
|
130
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
131
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
132
|
+
| **SiteHeader** | ✅ | ✅ | ❌ | ✅ | ❌ |
|
|
133
|
+
| **PrimaryMenu** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
134
|
+
| **SecondaryMenu** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
135
|
+
| **SecondaryMenuAlt** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
136
|
+
| **NavItem** | ❌ | ❌ | ❌ | ✅ | ❌ |
|
|
137
|
+
|
|
138
|
+
### Wrapper Components
|
|
139
|
+
|
|
140
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
141
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
142
|
+
| **SiteWrapper** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
143
|
+
| **AppList** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
144
|
+
| **ChurchList** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
145
|
+
| **UserMenu** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
146
|
+
| **Drawers** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
147
|
+
| **Notifications** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
148
|
+
| **PrivateMessages** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
149
|
+
| **TabPanel** (wrapper) | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
150
|
+
|
|
151
|
+
### Page Components
|
|
152
|
+
|
|
153
|
+
| Component | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
154
|
+
|-----------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
155
|
+
| **Forgot** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
156
|
+
| **Login** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
157
|
+
| **LoginSetPassword** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
158
|
+
| **SelectChurchModal** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
159
|
+
| **SelectChurchRegister** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
160
|
+
| **SelectChurchSearch** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
161
|
+
| **SelectableChurch** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
162
|
+
|
|
163
|
+
## Helper Utilities Usage
|
|
164
|
+
|
|
165
|
+
| Helper | B1App | ChumsApp | ChumsTransfer | LessonsApp | ChurchAppsWeb |
|
|
166
|
+
|--------|:-----:|:--------:|:-------------:|:----------:|:-------------:|
|
|
167
|
+
| **ApiHelper** | ✅ | ✅ | ✅ | ✅ | ✅ |
|
|
168
|
+
| **UserHelper** | ✅ | ✅ | ✅ | ✅ | ✅ |
|
|
169
|
+
| **ArrayHelper** | ✅ | ✅ | ✅ | ✅ | ❌ |
|
|
170
|
+
| **DateHelper** | ✅ | ✅ | ❌ | ✅ | ❌ |
|
|
171
|
+
| **PersonHelper** | ✅ | ✅ | ✅ | ❌ | ❌ |
|
|
172
|
+
| **CurrencyHelper** | ✅ | ✅ | ❌ | ❌ | ❌ |
|
|
173
|
+
| **AppearanceHelper** | ✅ | ❌ | ❌ | ❌ | ❌ |
|
|
174
|
+
| **AnalyticsHelper** | ✅ | ✅ | ❌ | ✅ | ✅ |
|
|
175
|
+
| **ErrorHelper** | ✅ | ✅ | ❌ | ✅ | ❌ |
|
|
176
|
+
| **CommonEnvironmentHelper** | ✅ | ✅ | ✅ | ✅ | ✅ |
|
|
177
|
+
| **UniqueIdHelper** | ✅ | ✅ | ❌ | ❌ | ❌ |
|
|
178
|
+
| **SlugHelper** | ✅ | ❌ | ❌ | ✅ | ❌ |
|
|
179
|
+
| **EventHelper** | ✅ | ❌ | ❌ | ❌ | ❌ |
|
|
180
|
+
| **SocketHelper** | ✅ | ❌ | ❌ | ❌ | ❌ |
|
|
181
|
+
| **Locale** | ✅ | ✅ | ✅ | ✅ | ❌ |
|
|
182
|
+
| **DonationHelper** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
183
|
+
| **FileHelper** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
184
|
+
| **ReportHelper** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
185
|
+
| **createEmotionCache** | ❌ | ❌ | ❌ | ❌ | ❌ |
|
|
186
|
+
|
|
187
|
+
## Component Usage Analysis
|
|
188
|
+
|
|
189
|
+
The following analysis shows component usage patterns, distinguishing between external project usage and internal AppHelper usage:
|
|
190
|
+
|
|
191
|
+
### Components Used Internally by AppHelper (22 total)
|
|
192
|
+
|
|
193
|
+
These components are not directly imported by external projects but are used internally by other AppHelper components:
|
|
194
|
+
|
|
195
|
+
#### Core UI Components (4)
|
|
196
|
+
- **HelpIcon** - Used by `DisplayBox` and `InputBox` components
|
|
197
|
+
- **TabPanel** - Used by `UserMenu` and `GalleryModal` components
|
|
198
|
+
- **QuestionEdit** - Used by `FormSubmissionEdit` component
|
|
199
|
+
- **FormCardPayment** - Used by `QuestionEdit` component
|
|
200
|
+
|
|
201
|
+
#### Notes & Communication Components (4)
|
|
202
|
+
- **Note** - Used by `Notes` component
|
|
203
|
+
- **AddNote** - Used by `Notes` and `NewPrivateMessage` components
|
|
204
|
+
- **Conversation** - Used by `Conversations` component
|
|
205
|
+
- **NewConversation** - Used by `Conversations` component
|
|
206
|
+
|
|
207
|
+
#### Moved Components (17)
|
|
208
|
+
These components have been moved to ChumsApp and are no longer part of AppHelper:
|
|
209
|
+
- **Donation Components (13)**: DonationPage, DonationForm, NonAuthDonation, NonAuthDonationInner, PaymentMethods, RecurringDonations, RecurringDonationsEdit, FundDonations, FundDonation, BankForm, CardForm, FormCardPayment, DonationPreviewModal
|
|
210
|
+
- **Person Management (2)**: PersonAdd, CreatePerson
|
|
211
|
+
|
|
212
|
+
#### Gallery Components (1)
|
|
213
|
+
- **StockPhotos** - Used by `GalleryModal` component
|
|
214
|
+
|
|
215
|
+
#### Header Components (4)
|
|
216
|
+
- **SupportDrawer** - Used by `SiteHeader` component
|
|
217
|
+
- **PrimaryMenu** - Used by `SiteHeader` component
|
|
218
|
+
- **SecondaryMenu** - Used by `SiteHeader` component
|
|
219
|
+
- **SecondaryMenuAlt** - Used by `SiteHeader` component
|
|
220
|
+
|
|
221
|
+
#### Reporting Components (6)
|
|
222
|
+
- **ReportFilter** - Used by `ReportWithFilter` component
|
|
223
|
+
- **ReportFilterField** - Used by `ReportFilter` component
|
|
224
|
+
- **ReportOutput** - Used by `ReportWithFilter` component
|
|
225
|
+
- **ChartReport** - Used by `ReportOutput` component
|
|
226
|
+
- **TableReport** - Used by `ReportOutput` component
|
|
227
|
+
- **TreeReport** - Used by `ReportOutput` component
|
|
228
|
+
|
|
229
|
+
#### Wrapper Components (5)
|
|
230
|
+
- **UserMenu** - Used by `SiteHeader` and `SiteWrapper` components
|
|
231
|
+
- **AppList** - Used by `UserMenu` component
|
|
232
|
+
- **ChurchList** - Used by `UserMenu` component
|
|
233
|
+
- **Notifications** - Used by `UserMenu` component
|
|
234
|
+
- **PrivateMessages** - Used by `UserMenu` component
|
|
235
|
+
- **Drawers** - Used by `SiteWrapper` component
|
|
236
|
+
|
|
237
|
+
#### Page Components (8)
|
|
238
|
+
- **Forgot** - Used by `LoginPage` component
|
|
239
|
+
- **Login** - Used by `LoginPage` component
|
|
240
|
+
- **LoginSetPassword** - Used by `LoginPage` component
|
|
241
|
+
- **SelectChurchModal** - Used by `LoginPage` component
|
|
242
|
+
- **SelectChurchRegister** - Used by `SelectChurchSearch` component
|
|
243
|
+
- **SelectChurchSearch** - Used by `SelectChurchSearch` component
|
|
244
|
+
- **SelectableChurch** - Used by `SelectChurchSearch` component
|
|
245
|
+
|
|
246
|
+
### Truly Unused Components (1 total)
|
|
247
|
+
|
|
248
|
+
Only one component appears to have no usage either externally or internally:
|
|
249
|
+
- **SiteWrapper** - Main site wrapper component (not used by any external projects or internal components)
|
|
250
|
+
|
|
251
|
+
### Moved Components Summary (17 total)
|
|
252
|
+
|
|
253
|
+
The following components have been extracted from AppHelper and moved to ChumsApp for better architectural separation:
|
|
254
|
+
|
|
255
|
+
#### Donation Management System (13 components)
|
|
256
|
+
- **Main Components**: DonationPage, DonationForm, NonAuthDonation
|
|
257
|
+
- **Payment Processing**: PaymentMethods, BankForm, CardForm, FormCardPayment
|
|
258
|
+
- **Fund Management**: FundDonations, FundDonation
|
|
259
|
+
- **Recurring Donations**: RecurringDonations, RecurringDonationsEdit
|
|
260
|
+
- **Internal Components**: NonAuthDonationInner, DonationPreviewModal
|
|
261
|
+
|
|
262
|
+
#### Person Management (2 components)
|
|
263
|
+
- **PersonAdd** - Add person to groups/systems
|
|
264
|
+
- **CreatePerson** - Create new person records
|
|
265
|
+
|
|
266
|
+
These components are now maintained within ChumsApp, allowing for faster iteration on CHUMS-specific functionality while reducing AppHelper's bundle size and complexity.
|
|
267
|
+
|
|
268
|
+
### Unused Helper Utilities (4 total)
|
|
269
|
+
1. **DonationHelper** - Donation-related utilities
|
|
270
|
+
2. **FileHelper** - File handling utilities
|
|
271
|
+
3. **ReportHelper** - Reporting utilities
|
|
272
|
+
4. **createEmotionCache** - Emotion cache creation
|
|
273
|
+
|
|
274
|
+
## Key Insights
|
|
275
|
+
|
|
276
|
+
1. **Core Components**: The most widely used components are `DisplayBox`, `Loading`, `SmallButton`, `InputBox`, and `ErrorMessages`, which appear in most active projects.
|
|
277
|
+
|
|
278
|
+
2. **Authentication**: All projects use `LoginPage`, making it the most universally adopted component. `LogoutPage` is used by all except ChurchAppsWeb.
|
|
279
|
+
|
|
280
|
+
3. **Project-Specific Usage**:
|
|
281
|
+
- **B1App**: Uses the widest variety of components including donations, communications, and rich media
|
|
282
|
+
- **ChumsApp**: Focuses on forms, reporting, and person management
|
|
283
|
+
- **LessonsApp**: Uses support components uniquely among all projects
|
|
284
|
+
- **ChumsTransfer & ChurchAppsWeb**: Minimal usage, primarily authentication
|
|
285
|
+
|
|
286
|
+
4. **Component Architecture**: AppHelper demonstrates excellent internal component composition with 22 components (65%) used internally by other components, showing a well-structured component hierarchy where complex components are built from simpler, focused components.
|
|
287
|
+
|
|
288
|
+
5. **External vs Internal Usage**: Only 11 out of 34 components (32%) are directly imported by external projects, while 22 components (65%) serve as internal building blocks. Only 1 component (3%) appears to be truly unused.
|
|
289
|
+
|
|
290
|
+
6. **Successful Component Extraction**: 17 components (50% of the original 51) have been successfully moved from AppHelper to ChumsApp, including the entire donation management system and person management components. This extraction significantly reduced AppHelper's bundle size and improved architectural separation.
|
|
291
|
+
|
|
292
|
+
7. **Helper Utilities**: `ApiHelper` and `UserHelper` are universally used across all projects, while specialized helpers like `DonationHelper` and `FileHelper` remain unused.
|
|
293
|
+
|
|
294
|
+
## Recommendations
|
|
295
|
+
|
|
296
|
+
1. **✅ COMPLETED: Component Extraction**: Successfully moved 17 CHUMS-specific components to ChumsApp, including:
|
|
297
|
+
- Complete donation management system (13 components)
|
|
298
|
+
- Person management components (2 components)
|
|
299
|
+
- Achieved 50% reduction in AppHelper component count (51 → 34)
|
|
300
|
+
- Eliminated Stripe dependencies from AppHelper
|
|
301
|
+
- Improved architectural separation
|
|
302
|
+
|
|
303
|
+
2. **Maintain Component Architecture**: The current component composition strategy is excellent, with most components serving as internal building blocks. This architecture should be preserved as it promotes reusability and maintainability.
|
|
304
|
+
|
|
305
|
+
3. **Documentation Enhancement**:
|
|
306
|
+
- Document the internal component hierarchy to help developers understand the composition patterns
|
|
307
|
+
- Create examples for the 11 externally-used components to promote adoption
|
|
308
|
+
- Add architecture diagrams showing component dependencies
|
|
309
|
+
- Document the successful component extraction process for future reference
|
|
310
|
+
|
|
311
|
+
4. **Minimal Cleanup**: Only `SiteWrapper` appears to be truly unused and could be considered for deprecation if confirmed to have no purpose.
|
|
312
|
+
|
|
313
|
+
5. **Helper Utilities Review**: The 4 unused helper utilities (`DonationHelper`, `FileHelper`, `ReportHelper`, `createEmotionCache`) could be evaluated for removal if they serve no purpose.
|
|
314
|
+
|
|
315
|
+
6. **External Adoption**: Consider promoting usage of high-level components like:
|
|
316
|
+
- `SiteHeader` for consistent navigation
|
|
317
|
+
- `FloatingSupport` and `SupportModal` for user assistance
|
|
318
|
+
- Rich text components (`MarkdownEditor`, `MarkdownPreview`) for content management
|
|
319
|
+
|
|
320
|
+
7. **Component Export Strategy**: With the reduced component count (34 vs original 51), the public API surface is now more manageable. Consider whether all remaining components need to be exported, or if some internal-only components could be kept private.
|
|
321
|
+
|
|
322
|
+
8. **Monitor ChumsApp Integration**: Validate that the moved components work correctly in ChumsApp and that the donation/person management workflows function as expected.
|
|
@@ -6,11 +6,11 @@ const material_1 = require("@mui/material");
|
|
|
6
6
|
const SecondaryMenu = (props) => {
|
|
7
7
|
const getItems = () => {
|
|
8
8
|
const result = [];
|
|
9
|
-
props.menuItems.forEach(item => {
|
|
9
|
+
props.menuItems.forEach((item, index) => {
|
|
10
10
|
if (item.label === props.label)
|
|
11
|
-
result.push((0, jsx_runtime_1.jsx)(material_1.Chip, { onClick: () => props.onNavigate(item.url), label: item.label, component: "a", variant: "filled", clickable: true, style: { backgroundColor: "var(--c1d2)", color: "#FFF", fontSize: 16 } }));
|
|
11
|
+
result.push((0, jsx_runtime_1.jsx)(material_1.Chip, { onClick: () => props.onNavigate(item.url), label: item.label, component: "a", variant: "filled", clickable: true, style: { backgroundColor: "var(--c1d2)", color: "#FFF", fontSize: 16 } }, index));
|
|
12
12
|
else
|
|
13
|
-
result.push((0, jsx_runtime_1.jsx)("a", { href: "about:blank", onClick: (e) => { e.preventDefault(); props.onNavigate(item.url); }, style: { color: "#FFF", textDecoration: "none", marginLeft: 10, marginRight: 10 }, children: item.label }));
|
|
13
|
+
result.push((0, jsx_runtime_1.jsx)("a", { href: "about:blank", onClick: (e) => { e.preventDefault(); props.onNavigate(item.url); }, style: { color: "#FFF", textDecoration: "none", marginLeft: 10, marginRight: 10 }, children: item.label }, index));
|
|
14
14
|
});
|
|
15
15
|
return result;
|
|
16
16
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SecondaryMenu.js","sourceRoot":"","sources":["../../../src/components/header/SecondaryMenu.tsx"],"names":[],"mappings":";;;;AAAA,4CAAqC;AAQ9B,MAAM,aAAa,GAAE,CAAC,KAAW,EAAE,EAAE;IAE1C,MAAM,QAAQ,GAAG,GAAG,EAAE;QACpB,MAAM,MAAM,GAAS,EAAE,CAAC;QACxB,KAAK,CAAC,SAAS,CAAC,OAAO,CAAC,IAAI,
|
|
1
|
+
{"version":3,"file":"SecondaryMenu.js","sourceRoot":"","sources":["../../../src/components/header/SecondaryMenu.tsx"],"names":[],"mappings":";;;;AAAA,4CAAqC;AAQ9B,MAAM,aAAa,GAAE,CAAC,KAAW,EAAE,EAAE;IAE1C,MAAM,QAAQ,GAAG,GAAG,EAAE;QACpB,MAAM,MAAM,GAAS,EAAE,CAAC;QACxB,KAAK,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE;YACtC,IAAI,IAAI,CAAC,KAAK,KAAK,KAAK,CAAC,KAAK;gBAAE,MAAM,CAAC,IAAI,CAAC,uBAAC,eAAI,IAAa,OAAO,EAAE,GAAG,EAAE,CAAC,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,KAAK,EAAE,IAAI,CAAC,KAAK,EAAE,SAAS,EAAC,GAAG,EAAC,OAAO,EAAC,QAAQ,EAAC,SAAS,QAAC,KAAK,EAAE,EAAC,eAAe,EAAC,aAAa,EAAE,KAAK,EAAC,MAAM,EAAE,QAAQ,EAAC,EAAE,EAAC,IAA/K,KAAK,CAA8K,CAAC,CAAC;;gBACvO,MAAM,CAAC,IAAI,CAAC,8BAAe,IAAI,EAAC,aAAa,EAAC,OAAO,EAAE,CAAC,CAAC,EAAE,EAAE,GAAG,CAAC,CAAC,cAAc,EAAE,CAAC,CAAC,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,GAAG,CAAC,CAAA,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,KAAK,EAAC,MAAM,EAAE,cAAc,EAAE,MAAM,EAAE,UAAU,EAAC,EAAE,EAAE,WAAW,EAAC,EAAE,EAAC,YAAG,IAAI,CAAC,KAAK,IAAxL,KAAK,CAAwL,CAAC,CAAC;QAC1N,CAAC,CAAC,CAAC;QACH,OAAO,MAAM,CAAC;IAChB,CAAC,CAAA;IAED,OAAO,CAAC,gCAAK,EAAE,EAAC,eAAe,YAC5B,QAAQ,EAAE,GACP,CAAC,CAAA;AACT,CAAC,CAAA;AAdY,QAAA,aAAa,iBAczB"}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
export { CreatePerson } from "./CreatePerson";
|
|
2
1
|
export { ErrorMessages } from "./ErrorMessages";
|
|
3
2
|
export { ExportLink } from "./ExportLink";
|
|
4
3
|
export { DisplayBox } from "./DisplayBox";
|
|
@@ -10,7 +9,6 @@ export { IconPicker } from "./iconPicker/IconPicker";
|
|
|
10
9
|
export { InputBox } from "./InputBox";
|
|
11
10
|
export { Loading } from "./Loading";
|
|
12
11
|
export { Notes } from "./notes/Notes";
|
|
13
|
-
export { PersonAdd } from "./PersonAdd";
|
|
14
12
|
export { QuestionEdit } from "./QuestionEdit";
|
|
15
13
|
export { SmallButton } from "./SmallButton";
|
|
16
14
|
export { SupportModal } from "./SupportModal";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/components/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/components/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrD,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtC,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AACjE,OAAO,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAC;AACnE,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC;AAC1B,cAAc,kBAAkB,CAAC;AACjC,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC"}
|
package/dist/components/index.js
CHANGED
|
@@ -14,9 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
exports.B1ShareModal = exports.MarkdownPreview = exports.MarkdownEditor = exports.SupportModal = exports.SmallButton = exports.QuestionEdit = exports.
|
|
18
|
-
var CreatePerson_1 = require("./CreatePerson");
|
|
19
|
-
Object.defineProperty(exports, "CreatePerson", { enumerable: true, get: function () { return CreatePerson_1.CreatePerson; } });
|
|
17
|
+
exports.B1ShareModal = exports.MarkdownPreview = exports.MarkdownEditor = exports.SupportModal = exports.SmallButton = exports.QuestionEdit = exports.Notes = exports.Loading = exports.InputBox = exports.IconPicker = exports.ImageEditor = exports.HelpIcon = exports.FormSubmissionEdit = exports.FloatingSupport = exports.DisplayBox = exports.ExportLink = exports.ErrorMessages = void 0;
|
|
20
18
|
var ErrorMessages_1 = require("./ErrorMessages");
|
|
21
19
|
Object.defineProperty(exports, "ErrorMessages", { enumerable: true, get: function () { return ErrorMessages_1.ErrorMessages; } });
|
|
22
20
|
var ExportLink_1 = require("./ExportLink");
|
|
@@ -39,8 +37,6 @@ var Loading_1 = require("./Loading");
|
|
|
39
37
|
Object.defineProperty(exports, "Loading", { enumerable: true, get: function () { return Loading_1.Loading; } });
|
|
40
38
|
var Notes_1 = require("./notes/Notes");
|
|
41
39
|
Object.defineProperty(exports, "Notes", { enumerable: true, get: function () { return Notes_1.Notes; } });
|
|
42
|
-
var PersonAdd_1 = require("./PersonAdd");
|
|
43
|
-
Object.defineProperty(exports, "PersonAdd", { enumerable: true, get: function () { return PersonAdd_1.PersonAdd; } });
|
|
44
40
|
var QuestionEdit_1 = require("./QuestionEdit");
|
|
45
41
|
Object.defineProperty(exports, "QuestionEdit", { enumerable: true, get: function () { return QuestionEdit_1.QuestionEdit; } });
|
|
46
42
|
var SmallButton_1 = require("./SmallButton");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/components/index.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/components/index.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,iDAAgD;AAAvC,8GAAA,aAAa,OAAA;AACtB,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,qDAAoD;AAA3C,kHAAA,eAAe,OAAA;AACxB,2DAA0D;AAAjD,wHAAA,kBAAkB,OAAA;AAC3B,uCAAsC;AAA7B,oGAAA,QAAQ,OAAA;AACjB,6CAA4C;AAAnC,0GAAA,WAAW,OAAA;AACpB,sDAAqD;AAA5C,wGAAA,UAAU,OAAA;AACnB,uCAAsC;AAA7B,oGAAA,QAAQ,OAAA;AACjB,qCAAoC;AAA3B,kGAAA,OAAO,OAAA;AAChB,uCAAsC;AAA7B,8FAAA,KAAK,OAAA;AACd,+CAA8C;AAArC,4GAAA,YAAY,OAAA;AACrB,6CAA4C;AAAnC,0GAAA,WAAW,OAAA;AACpB,+CAA8C;AAArC,4GAAA,YAAY,OAAA;AACrB,kEAAiE;AAAxD,gHAAA,cAAc,OAAA;AACvB,oEAAmE;AAA1D,kHAAA,eAAe,OAAA;AACxB,+CAA8C;AAArC,4GAAA,YAAY,OAAA;AAErB,4CAA0B;AAC1B,4CAA0B;AAC1B,mDAAiC;AACjC,0CAAwB;AACxB,8CAA4B;AAC5B,2CAAyB"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export declare class FileHelper {
|
|
2
|
-
static postPresignedFile: (presigned: any, uploadedFile: File, progressCallback: (percent: number) => void
|
|
2
|
+
static postPresignedFile: (presigned: any, uploadedFile: File, progressCallback: (percent: number) => void) => Promise<import("axios").AxiosResponse<any, any>>;
|
|
3
3
|
static dataURLtoBlob(dataurl: string): Blob;
|
|
4
4
|
}
|
|
5
5
|
//# sourceMappingURL=FileHelper.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileHelper.d.ts","sourceRoot":"","sources":["../../src/helpers/FileHelper.ts"],"names":[],"mappings":"AAEA,qBAAa,UAAU;
|
|
1
|
+
{"version":3,"file":"FileHelper.d.ts","sourceRoot":"","sources":["../../src/helpers/FileHelper.ts"],"names":[],"mappings":"AAEA,qBAAa,UAAU;IAErB,MAAM,CAAC,iBAAiB,GAAI,WAAW,GAAG,EAAE,cAAc,IAAI,EAAE,kBAAkB,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,sDAgBzG;IAEF,MAAM,CAAC,aAAa,CAAC,OAAO,EAAE,MAAM;CAQrC"}
|
|
@@ -15,8 +15,7 @@ class FileHelper {
|
|
|
15
15
|
}
|
|
16
16
|
}
|
|
17
17
|
exports.FileHelper = FileHelper;
|
|
18
|
-
FileHelper.postPresignedFile = (presigned, uploadedFile, progressCallback
|
|
19
|
-
const axiosToUse = axiosInstance || axios_1.default;
|
|
18
|
+
FileHelper.postPresignedFile = (presigned, uploadedFile, progressCallback) => {
|
|
20
19
|
const formData = new FormData();
|
|
21
20
|
//formData.append("key", presigned.key); //no longer needed with new aws sdk
|
|
22
21
|
formData.append("acl", "public-read");
|
|
@@ -30,9 +29,6 @@ FileHelper.postPresignedFile = (presigned, uploadedFile, progressCallback, axios
|
|
|
30
29
|
progressCallback(Math.round((100 * data.loaded) / data.total));
|
|
31
30
|
}
|
|
32
31
|
};
|
|
33
|
-
|
|
34
|
-
console.log("axios: ", axiosToUse);
|
|
35
|
-
console.log("axios tyeof: ", typeof axiosToUse.post);
|
|
36
|
-
return axiosToUse.post(presigned.url, formData, axiosConfig);
|
|
32
|
+
return axios_1.default.post(presigned.url, formData, axiosConfig);
|
|
37
33
|
};
|
|
38
34
|
//# sourceMappingURL=FileHelper.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileHelper.js","sourceRoot":"","sources":["../../src/helpers/FileHelper.ts"],"names":[],"mappings":";;;;;;AAAA,kDAA0B;AAE1B,MAAa,UAAU;
|
|
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,CAAC;YACX,KAAK,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;QAChC,CAAC;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,4EAA4E;IAC5E,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"}
|