@umituz/react-native-settings 4.20.58 → 4.20.59
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/.github/ISSUE_TEMPLATE/bug_report.md +51 -0
- package/.github/ISSUE_TEMPLATE/documentation.md +52 -0
- package/.github/ISSUE_TEMPLATE/feature_request.md +63 -0
- package/.github/PULL_REQUEST_TEMPLATE.md +84 -0
- package/AI_AGENT_GUIDELINES.md +367 -0
- package/ARCHITECTURE.md +246 -0
- package/CHANGELOG.md +67 -0
- package/CODE_OF_CONDUCT.md +75 -0
- package/CONTRIBUTING.md +107 -0
- package/DOCUMENTATION_MIGRATION.md +319 -0
- package/DOCUMENTATION_TEMPLATE.md +155 -0
- package/LICENSE +21 -0
- package/README.md +321 -498
- package/SECURITY.md +98 -0
- package/SETTINGS_SCREEN_GUIDE.md +185 -0
- package/TESTING.md +358 -0
- package/package.json +13 -2
- package/src/application/README.md +85 -271
- package/src/domains/about/README.md +85 -440
- package/src/domains/about/presentation/hooks/README.md +93 -348
- package/src/domains/appearance/README.md +95 -584
- package/src/domains/appearance/hooks/README.md +95 -303
- package/src/domains/appearance/infrastructure/services/README.md +83 -397
- package/src/domains/appearance/presentation/components/README.md +95 -489
- package/src/domains/cloud-sync/README.md +73 -439
- package/src/domains/cloud-sync/presentation/components/README.md +95 -493
- package/src/domains/dev/README.md +71 -457
- package/src/domains/disclaimer/README.md +77 -411
- package/src/domains/disclaimer/presentation/components/README.md +95 -392
- package/src/domains/faqs/README.md +86 -574
- package/src/domains/feedback/README.md +79 -553
- package/src/domains/feedback/presentation/hooks/README.md +93 -426
- package/src/domains/legal/README.md +88 -537
- package/src/domains/rating/README.md +73 -440
- package/src/domains/rating/presentation/components/README.md +95 -475
- package/src/domains/video-tutorials/README.md +77 -470
- package/src/domains/video-tutorials/presentation/components/README.md +95 -431
- package/src/infrastructure/README.md +78 -425
- package/src/infrastructure/repositories/README.md +88 -420
- package/src/infrastructure/services/README.md +74 -460
- package/src/presentation/components/README.md +97 -480
- package/src/presentation/components/SettingsErrorBoundary/README.md +48 -436
- package/src/presentation/components/SettingsFooter/README.md +48 -427
- package/src/presentation/components/SettingsItemCard/README.md +152 -391
- package/src/presentation/components/SettingsItemCard/STRATEGY.md +164 -0
- package/src/presentation/components/SettingsSection/README.md +47 -401
- package/src/presentation/hooks/README.md +95 -389
- package/src/presentation/hooks/mutations/README.md +99 -376
- package/src/presentation/hooks/queries/README.md +111 -353
- package/src/presentation/navigation/README.md +70 -502
- package/src/presentation/navigation/components/README.md +70 -295
- package/src/presentation/navigation/hooks/README.md +75 -367
- package/src/presentation/navigation/utils/README.md +100 -380
- package/src/presentation/screens/README.md +53 -504
- package/src/presentation/screens/components/SettingsContent/README.md +53 -382
- package/src/presentation/screens/components/SettingsHeader/README.md +48 -303
- package/src/presentation/screens/components/sections/CustomSettingsList/README.md +47 -359
- package/src/presentation/screens/components/sections/FeatureSettingsSection/README.md +81 -176
- package/src/presentation/screens/components/sections/IdentitySettingsSection/README.md +40 -297
- package/src/presentation/screens/components/sections/ProfileSectionLoader/README.md +47 -451
- package/src/presentation/screens/components/sections/SupportSettingsSection/README.md +45 -361
- package/src/presentation/screens/hooks/README.md +64 -354
- package/src/presentation/screens/types/README.md +79 -409
- package/src/presentation/screens/utils/README.md +65 -255
|
@@ -1,394 +1,97 @@
|
|
|
1
1
|
# Disclaimer Components
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
}}
|
|
99
|
-
acceptText="I Agree"
|
|
100
|
-
closeText="Decline"
|
|
101
|
-
/>
|
|
102
|
-
```
|
|
103
|
-
|
|
104
|
-
### DisclaimerSetting
|
|
105
|
-
|
|
106
|
-
Combined card + modal component for integrated disclaimer display.
|
|
107
|
-
|
|
108
|
-
```tsx
|
|
109
|
-
import { DisclaimerSetting } from '@umituz/react-native-settings';
|
|
110
|
-
|
|
111
|
-
function DisclaimerSettingExample() {
|
|
112
|
-
return (
|
|
113
|
-
<DisclaimerSetting
|
|
114
|
-
title="Legal Disclaimer"
|
|
115
|
-
message="Important legal information"
|
|
116
|
-
fullText="Full disclaimer text here..."
|
|
117
|
-
onAccept={() => saveAcceptance()}
|
|
118
|
-
/>
|
|
119
|
-
);
|
|
120
|
-
}
|
|
121
|
-
```
|
|
122
|
-
|
|
123
|
-
#### Props
|
|
124
|
-
|
|
125
|
-
| Prop | Type | Default | Description |
|
|
126
|
-
|------|------|---------|-------------|
|
|
127
|
-
| `title` | `string` | **Required** | Disclaimer title |
|
|
128
|
-
| `message` | `string` | **Required** | Short message |
|
|
129
|
-
| `fullText` | `string` | **Required** | Full disclaimer text |
|
|
130
|
-
| `onAccept` | `() => void` | **Required** | Accept handler |
|
|
131
|
-
| `icon` | `IconName` | `'warning-outline'` | Icon name |
|
|
132
|
-
| `showOnce` | `boolean` | `false` | Show only once |
|
|
133
|
-
| `storageKey` | `string` | `'disclaimer'` | Storage key |
|
|
134
|
-
|
|
135
|
-
#### Example
|
|
136
|
-
|
|
137
|
-
```tsx
|
|
138
|
-
<DisclaimerSetting
|
|
139
|
-
title="Privacy Notice"
|
|
140
|
-
message="We care about your privacy"
|
|
141
|
-
fullText="This is the full privacy policy text..."
|
|
142
|
-
onAccept={() => {
|
|
143
|
-
AsyncStorage.setItem('privacy-accepted', 'true');
|
|
144
|
-
}}
|
|
145
|
-
showOnce={true}
|
|
146
|
-
storageKey="privacy-disclaimer-2024"
|
|
147
|
-
/>
|
|
148
|
-
```
|
|
149
|
-
|
|
150
|
-
### DisclaimerScreen
|
|
151
|
-
|
|
152
|
-
Dedicated screen component for comprehensive disclaimers.
|
|
153
|
-
|
|
154
|
-
```tsx
|
|
155
|
-
import { DisclaimerScreen } from '@umituz/react-native-settings';
|
|
156
|
-
|
|
157
|
-
function DisclaimerStack() {
|
|
158
|
-
return (
|
|
159
|
-
<Stack.Screen
|
|
160
|
-
name="Disclaimer"
|
|
161
|
-
component={DisclaimerScreen}
|
|
162
|
-
options={{ title: 'Disclaimer' }}
|
|
163
|
-
initialParams={{
|
|
164
|
-
title: 'Legal Disclaimer',
|
|
165
|
-
message: 'Full disclaimer content...',
|
|
166
|
-
}}
|
|
167
|
-
/>
|
|
168
|
-
);
|
|
169
|
-
}
|
|
170
|
-
```
|
|
171
|
-
|
|
172
|
-
#### Props
|
|
173
|
-
|
|
174
|
-
| Prop | Type | Default | Description |
|
|
175
|
-
|------|------|---------|-------------|
|
|
176
|
-
| `route` | `RouteProp` | **Required** | Route with params |
|
|
177
|
-
| `navigation` | `NavigationProp` | **Required** | Navigation object |
|
|
178
|
-
|
|
179
|
-
#### Route Params
|
|
180
|
-
|
|
181
|
-
```typescript
|
|
182
|
-
interface DisclaimerScreenParams {
|
|
183
|
-
title: string;
|
|
184
|
-
message: string;
|
|
185
|
-
showAccept?: boolean;
|
|
186
|
-
onAccept?: () => void;
|
|
187
|
-
}
|
|
188
|
-
```
|
|
189
|
-
|
|
190
|
-
## Examples
|
|
191
|
-
|
|
192
|
-
### One-Time Disclaimer
|
|
193
|
-
|
|
194
|
-
```tsx
|
|
195
|
-
function OneTimeDisclaimer() {
|
|
196
|
-
const [hasAccepted, setHasAccepted] = useState(false);
|
|
197
|
-
|
|
198
|
-
useEffect(() => {
|
|
199
|
-
AsyncStorage.getItem('disclaimer-accepted').then(value => {
|
|
200
|
-
setHasAccepted(!!value);
|
|
201
|
-
});
|
|
202
|
-
}, []);
|
|
203
|
-
|
|
204
|
-
const handleAccept = async () => {
|
|
205
|
-
await AsyncStorage.setItem('disclaimer-accepted', new Date().toISOString());
|
|
206
|
-
setHasAccepted(true);
|
|
207
|
-
};
|
|
208
|
-
|
|
209
|
-
if (hasAccepted) {
|
|
210
|
-
return null;
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
return (
|
|
214
|
-
<DisclaimerModal
|
|
215
|
-
visible={!hasAccepted}
|
|
216
|
-
title="Welcome!"
|
|
217
|
-
message="Please read and accept our disclaimer"
|
|
218
|
-
fullText="Full disclaimer text..."
|
|
219
|
-
onClose={() => {}}
|
|
220
|
-
onAccept={handleAccept}
|
|
221
|
-
acceptText="I Accept"
|
|
222
|
-
/>
|
|
223
|
-
);
|
|
224
|
-
}
|
|
225
|
-
```
|
|
226
|
-
|
|
227
|
-
### Versioned Disclaimer
|
|
228
|
-
|
|
229
|
-
```tsx
|
|
230
|
-
function VersionedDisclaimer() {
|
|
231
|
-
const DISCLAIMER_VERSION = '2.0';
|
|
232
|
-
|
|
233
|
-
const checkDisclaimer = async () => {
|
|
234
|
-
const acceptedVersion = await AsyncStorage.getItem('disclaimer-version');
|
|
235
|
-
return acceptedVersion === DISCLAIMER_VERSION;
|
|
236
|
-
};
|
|
237
|
-
|
|
238
|
-
const acceptDisclaimer = async () => {
|
|
239
|
-
await AsyncStorage.setItem('disclaimer-version', DISCLAIMER_VERSION);
|
|
240
|
-
};
|
|
241
|
-
|
|
242
|
-
return (
|
|
243
|
-
<DisclaimerSetting
|
|
244
|
-
title="Updated Disclaimer"
|
|
245
|
-
message="Our disclaimer has been updated"
|
|
246
|
-
fullText="New disclaimer content..."
|
|
247
|
-
onAccept={acceptDisclaimer}
|
|
248
|
-
/>
|
|
249
|
-
);
|
|
250
|
-
}
|
|
251
|
-
```
|
|
252
|
-
|
|
253
|
-
### Conditional Disclaimer
|
|
254
|
-
|
|
255
|
-
```tsx
|
|
256
|
-
function ConditionalDisclaimer({ featureEnabled }) {
|
|
257
|
-
if (!featureEnabled) {
|
|
258
|
-
return (
|
|
259
|
-
<DisclaimerCard
|
|
260
|
-
title="Feature Unavailable"
|
|
261
|
-
message="This feature is not available in your region"
|
|
262
|
-
icon="lock-closed-outline"
|
|
263
|
-
onPress={() => {}}
|
|
264
|
-
/>
|
|
265
|
-
);
|
|
266
|
-
}
|
|
267
|
-
|
|
268
|
-
return <FeatureContent />;
|
|
269
|
-
}
|
|
270
|
-
```
|
|
271
|
-
|
|
272
|
-
### Multiple Disclaimers
|
|
273
|
-
|
|
274
|
-
```tsx
|
|
275
|
-
function DisclaimerStack() {
|
|
276
|
-
return (
|
|
277
|
-
<View>
|
|
278
|
-
<DisclaimerSetting
|
|
279
|
-
title="Privacy Policy"
|
|
280
|
-
message="We value your privacy"
|
|
281
|
-
fullText="Privacy policy..."
|
|
282
|
-
onAccept={() => {}}
|
|
283
|
-
storageKey="privacy"
|
|
284
|
-
/>
|
|
285
|
-
|
|
286
|
-
<DisclaimerSetting
|
|
287
|
-
title="Terms of Service"
|
|
288
|
-
message="Please read our terms"
|
|
289
|
-
fullText="Terms of service..."
|
|
290
|
-
onAccept={() => {}}
|
|
291
|
-
storageKey="terms"
|
|
292
|
-
/>
|
|
293
|
-
|
|
294
|
-
<DisclaimerSetting
|
|
295
|
-
title="Beta Warning"
|
|
296
|
-
message="This is beta software"
|
|
297
|
-
fullText="Beta warning..."
|
|
298
|
-
onAccept={() => {}}
|
|
299
|
-
storageKey="beta"
|
|
300
|
-
/>
|
|
301
|
-
</View>
|
|
302
|
-
);
|
|
303
|
-
}
|
|
304
|
-
```
|
|
305
|
-
|
|
306
|
-
## Internationalization
|
|
307
|
-
|
|
308
|
-
### Translation Keys
|
|
309
|
-
|
|
310
|
-
```typescript
|
|
311
|
-
// Translation keys used
|
|
312
|
-
disclaimer.title = 'Disclaimer';
|
|
313
|
-
disclaimer.message = 'Important legal information';
|
|
314
|
-
disclaimer.accept = 'I Accept';
|
|
315
|
-
disclaimer.decline = 'Decline';
|
|
316
|
-
disclaimer.close = 'Close';
|
|
317
|
-
```
|
|
318
|
-
|
|
319
|
-
### Usage with i18n
|
|
320
|
-
|
|
321
|
-
```tsx
|
|
322
|
-
import { useTranslation } from 'react-i18next';
|
|
323
|
-
|
|
324
|
-
function LocalizedDisclaimer() {
|
|
325
|
-
const { t } = useTranslation();
|
|
326
|
-
|
|
327
|
-
return (
|
|
328
|
-
<DisclaimerModal
|
|
329
|
-
visible={visible}
|
|
330
|
-
title={t('disclaimer.title')}
|
|
331
|
-
message={t('disclaimer.message')}
|
|
332
|
-
fullText={t('disclaimer.fullText')}
|
|
333
|
-
onClose={() => setVisible(false)}
|
|
334
|
-
onAccept={() => accept()}
|
|
335
|
-
acceptText={t('disclaimer.accept')}
|
|
336
|
-
closeText={t('disclaimer.decline')}
|
|
337
|
-
/>
|
|
338
|
-
);
|
|
339
|
-
}
|
|
340
|
-
```
|
|
341
|
-
|
|
342
|
-
## Styling
|
|
343
|
-
|
|
344
|
-
### Custom Card Styles
|
|
345
|
-
|
|
346
|
-
```tsx
|
|
347
|
-
<DisclaimerCard
|
|
348
|
-
title="Custom Warning"
|
|
349
|
-
message="This is a custom styled disclaimer"
|
|
350
|
-
style={{
|
|
351
|
-
backgroundColor: '#FFF3E0',
|
|
352
|
-
borderLeftWidth: 4,
|
|
353
|
-
borderLeftColor: '#FF9800',
|
|
354
|
-
padding: 16,
|
|
355
|
-
}}
|
|
356
|
-
/>
|
|
357
|
-
```
|
|
358
|
-
|
|
359
|
-
### Custom Modal Styles
|
|
360
|
-
|
|
361
|
-
```tsx
|
|
362
|
-
<DisclaimerModal
|
|
363
|
-
visible={visible}
|
|
364
|
-
title="Disclaimer"
|
|
365
|
-
message="Content..."
|
|
366
|
-
containerStyle={{
|
|
367
|
-
backgroundColor: 'rgba(0, 0, 0, 0.8)',
|
|
368
|
-
}}
|
|
369
|
-
contentStyle={{
|
|
370
|
-
backgroundColor: 'white',
|
|
371
|
-
borderRadius: 16,
|
|
372
|
-
padding: 24,
|
|
373
|
-
}}
|
|
374
|
-
/>
|
|
375
|
-
```
|
|
376
|
-
|
|
377
|
-
## Best Practices
|
|
378
|
-
|
|
379
|
-
1. **Clarity**: Use clear, concise language
|
|
380
|
-
2. **Visibility**: Make disclaimers prominent
|
|
381
|
-
3. **Acceptance**: Require explicit acceptance
|
|
382
|
-
4. **Storage**: Store acceptance properly
|
|
383
|
-
5. **Versions**: Version your disclaimers
|
|
384
|
-
6. **Updates**: Handle disclaimer updates
|
|
385
|
-
7. **Legal**: Ensure legal compliance
|
|
386
|
-
|
|
387
|
-
## Related
|
|
388
|
-
|
|
389
|
-
- **Disclaimer Domain**: Disclaimer domain documentation
|
|
390
|
-
- **Legal Domain**: Legal documents and policies
|
|
391
|
-
|
|
392
|
-
## License
|
|
393
|
-
|
|
394
|
-
MIT
|
|
3
|
+
## Purpose
|
|
4
|
+
|
|
5
|
+
Components for displaying legal disclaimers, warnings, and important information to users. Provides flexible options for showing disclaimers as cards, modals, or integrated settings with acceptance tracking.
|
|
6
|
+
|
|
7
|
+
## File Paths
|
|
8
|
+
|
|
9
|
+
- **DisclaimerCard**: `/Users/umituz/Desktop/github/umituz/apps/artificial_intelligence/npm-packages/react-native-settings/src/domains/disclaimer/presentation/components/DisclaimerCard.tsx`
|
|
10
|
+
- **DisclaimerModal**: `/Users/umituz/Desktop/github/umituz/apps/artificial_intelligence/npm-packages/react-native-settings/src/domains/disclaimer/presentation/components/DisclaimerModal.tsx`
|
|
11
|
+
- **DisclaimerSetting**: `/Users/umituz/Desktop/github/umituz/apps/artificial_intelligence/npm-packages/react-native-settings/src/domains/disclaimer/presentation/components/DisclaimerSetting.tsx`
|
|
12
|
+
- **DisclaimerScreen**: `/Users/umituz/Desktop/github/umituz/apps/artificial_intelligence/npm-packages/react-native-settings/src/domains/disclaimer/presentation/screens/DisclaimerScreen.tsx`
|
|
13
|
+
|
|
14
|
+
## Strategy
|
|
15
|
+
|
|
16
|
+
1. **Progressive Disclosure**: Uses compact cards for summary information with expand/collapse functionality, showing full details only when users explicitly request them via modals or dedicated screens.
|
|
17
|
+
|
|
18
|
+
2. **Acceptance Tracking**: Implements storage-based tracking of user acceptance, allowing one-time or versioned disclaimers that don't repeatedly show to users who have already accepted.
|
|
19
|
+
|
|
20
|
+
3. **Flexible Display Options**: Provides multiple component variants (card, modal, setting, screen) to accommodate different UX requirements and legal compliance needs.
|
|
21
|
+
|
|
22
|
+
4. **Legal Compliance**: Designed to support various legal scenarios including terms of service, privacy policies, beta warnings, and regional restrictions with proper acceptance handling.
|
|
23
|
+
|
|
24
|
+
5. **Internationalization Ready**: Supports translation keys and localized content to display disclaimers in user's preferred language, essential for global apps.
|
|
25
|
+
|
|
26
|
+
## Restrictions
|
|
27
|
+
|
|
28
|
+
### ❌ DO NOT
|
|
29
|
+
|
|
30
|
+
- Hide critical legal information behind multiple taps
|
|
31
|
+
- Use confusing or ambiguous language
|
|
32
|
+
- Bypass acceptance tracking for required disclaimers
|
|
33
|
+
- Display disclaimers that are hard to read or dismiss
|
|
34
|
+
- Mix different disclaimer types inappropriately
|
|
35
|
+
|
|
36
|
+
### ❌ NEVER
|
|
37
|
+
|
|
38
|
+
- Allow users to proceed without accepting required disclaimers
|
|
39
|
+
- Store acceptance without reliable persistence mechanism
|
|
40
|
+
- Show outdated or superseded disclaimer versions
|
|
41
|
+
- Use dark patterns to trick users into acceptance
|
|
42
|
+
- Display illegal or unenforceable disclaimer content
|
|
43
|
+
|
|
44
|
+
### ❌ AVOID
|
|
45
|
+
|
|
46
|
+
- Overly long disclaimer text (break into sections)
|
|
47
|
+
- Technical jargon that average users don't understand
|
|
48
|
+
- Aggressive or alarming icon choices
|
|
49
|
+
- Blocking app usage for non-critical disclaimers
|
|
50
|
+
- Showing disclaimers too frequently
|
|
51
|
+
|
|
52
|
+
## Rules
|
|
53
|
+
|
|
54
|
+
### ✅ ALWAYS
|
|
55
|
+
|
|
56
|
+
- Use clear, concise language in disclaimers
|
|
57
|
+
- Require explicit acceptance for legal disclaimers
|
|
58
|
+
- Store acceptance reliably using AsyncStorage
|
|
59
|
+
- Provide easy access to full disclaimer text
|
|
60
|
+
- Allow users to review disclaimers anytime
|
|
61
|
+
|
|
62
|
+
### ✅ MUST
|
|
63
|
+
|
|
64
|
+
- Show disclaimers before relevant features are used
|
|
65
|
+
- Include accept/decline options for modal disclaimers
|
|
66
|
+
- Version disclaimers to track updates
|
|
67
|
+
- Provide legal contact information
|
|
68
|
+
- Comply with regional legal requirements
|
|
69
|
+
|
|
70
|
+
### ✅ SHOULD
|
|
71
|
+
|
|
72
|
+
- Use showOnce for one-time acknowledgments
|
|
73
|
+
- Implement version checking for updated disclaimers
|
|
74
|
+
- Group related disclaimers together
|
|
75
|
+
- Use appropriate warning levels (info, warning, error)
|
|
76
|
+
- Provide translations for all user-facing text
|
|
77
|
+
- Test disclaimer flows thoroughly
|
|
78
|
+
|
|
79
|
+
## AI Agent Guidelines
|
|
80
|
+
|
|
81
|
+
1. **Component Selection**: Use DisclaimerCard for non-critical notices and summaries. Use DisclaimerModal for required legal acceptance (terms, privacy). Use DisclaimerSetting for optional features or beta warnings. Use DisclaimerScreen for comprehensive legal documents.
|
|
82
|
+
|
|
83
|
+
2. **Acceptance Strategy**: For required legal disclaimers (terms, privacy), block app or feature usage until accepted. Use version checking to show updated disclaimers only when content changes. For non-critical notices, use showOnce to avoid annoying users.
|
|
84
|
+
|
|
85
|
+
3. **Storage Best Practices**: Use AsyncStorage with unique keys for each disclaimer. Include version numbers in storage keys (e.g., "privacy-2024-01"). Store acceptance timestamp to track when users agreed. Clear storage when app is uninstalled.
|
|
86
|
+
|
|
87
|
+
4. **Content Organization**: Break long legal documents into sections with clear headings. Use formatting (bold, lists) to improve readability. Consider providing a summary with link to full text. Ensure font sizes are readable (minimum 14px).
|
|
88
|
+
|
|
89
|
+
5. **User Experience**: Make acceptance actions clear (use "I Agree" / "I Accept" rather than "OK"). Provide a way to decline with clear consequences. Don't block the entire app for minor disclaimers - allow access to other features. Consider showing disclaimers at appropriate times (onboarding, before specific features).
|
|
90
|
+
|
|
91
|
+
## Reference
|
|
92
|
+
|
|
93
|
+
- **Card Component**: `/Users/umituz/Desktop/github/umituz/apps/artificial_intelligence/npm-packages/react-native-settings/src/domains/disclaimer/presentation/components/DisclaimerCard.tsx`
|
|
94
|
+
- **Modal Component**: `/Users/umituz/Desktop/github/umituz/apps/artificial_intelligence/npm-packages/react-native-settings/src/domains/disclaimer/presentation/components/DisclaimerModal.tsx`
|
|
95
|
+
- **Setting Component**: `/Users/umituz/Desktop/github/umituz/apps/artificial_intelligence/npm-packages/react-native-settings/src/domains/disclaimer/presentation/components/DisclaimerSetting.tsx`
|
|
96
|
+
- **Screen Component**: `/Users/umituz/Desktop/github/umituz/apps/artificial_intelligence/npm-packages/react-native-settings/src/domains/disclaimer/presentation/screens/DisclaimerScreen.tsx`
|
|
97
|
+
- **Disclaimer Components**: `/Users/umituz/Desktop/github/umituz/apps/artificial_intelligence/npm-packages/react-native-settings/src/domains/disclaimer/presentation/components/`
|