-
Notifications
You must be signed in to change notification settings - Fork 44
[SDK-431] notification-buttons-overflow-with-large-text #859
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: emb-ootb/master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -88,7 +88,6 @@ export const Embedded = () => { | |
|
|
||
| return ( | ||
| <SafeAreaView style={styles.container}> | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The changes that I made to this file is just so that the example page is not so crowded |
||
| <Text style={styles.title}>Embedded</Text> | ||
| {!Iterable.embeddedManager.isEnabled && ( | ||
| <View style={styles.warningContainer}> | ||
| <Text style={styles.warningText}> | ||
|
|
@@ -97,12 +96,9 @@ export const Embedded = () => { | |
| </Text> | ||
| </View> | ||
| )} | ||
| <Text style={styles.subtitle}> | ||
| Enter placement IDs to fetch embedded messages | ||
| </Text> | ||
| <View style={styles.utilitySection}> | ||
| <View style={styles.viewTypeSelector}> | ||
| <Text style={styles.text}>Select View Type:</Text> | ||
| <Text style={styles.viewTypeLabel}>View:</Text> | ||
| <View style={styles.viewTypeButtons}> | ||
| <TouchableOpacity | ||
| style={[ | ||
|
|
@@ -164,28 +160,43 @@ export const Embedded = () => { | |
| </TouchableOpacity> | ||
| </View> | ||
| </View> | ||
| <TouchableOpacity style={styles.button} onPress={syncEmbeddedMessages}> | ||
| <Text style={styles.buttonText}>Sync messages</Text> | ||
| </TouchableOpacity> | ||
| <TouchableOpacity style={styles.button} onPress={startEmbeddedSession}> | ||
| <Text style={styles.buttonText}>Start session</Text> | ||
| </TouchableOpacity> | ||
| <TouchableOpacity style={styles.button} onPress={endEmbeddedSession}> | ||
| <Text style={styles.buttonText}>End session</Text> | ||
| </TouchableOpacity> | ||
| <TouchableOpacity style={styles.button} onPress={openConfigEditor}> | ||
| <Text style={styles.buttonText}>Set view config</Text> | ||
| <View style={styles.sessionButtonsRow}> | ||
| <TouchableOpacity | ||
| style={[styles.compactUtilityButton, styles.sessionButtonHalf]} | ||
| onPress={syncEmbeddedMessages} | ||
| > | ||
| <Text style={styles.compactUtilityButtonText}>Sync</Text> | ||
| </TouchableOpacity> | ||
| <TouchableOpacity | ||
| style={[styles.compactUtilityButton, styles.sessionButtonHalf]} | ||
| onPress={startEmbeddedSession} | ||
| > | ||
| <Text style={styles.compactUtilityButtonText}>Start session</Text> | ||
| </TouchableOpacity> | ||
| <TouchableOpacity | ||
| style={[styles.compactUtilityButton, styles.sessionButtonHalf]} | ||
| onPress={endEmbeddedSession} | ||
| > | ||
| <Text style={styles.compactUtilityButtonText}>End session</Text> | ||
| </TouchableOpacity> | ||
| </View> | ||
| <TouchableOpacity style={styles.compactUtilityButton} onPress={openConfigEditor}> | ||
| <Text style={styles.compactUtilityButtonText}>Set view config</Text> | ||
| </TouchableOpacity> | ||
| <View style={styles.inputContainer}> | ||
| <Text style={styles.text}>Placement IDs (comma-separated):</Text> | ||
| <TextInput | ||
| style={styles.textInput} | ||
| placeholder="e.g., 1, 2, 3" | ||
| placeholderTextColor="#999" | ||
| value={placementIdsInput} | ||
| onChangeText={setPlacementIdsInput} | ||
| keyboardType="numbers-and-punctuation" | ||
| /> | ||
| <View style={styles.placementIdsRow}> | ||
| <Text style={styles.placementIdsLabel}> | ||
| Placement IDs{'\n'}(comma-separated): | ||
| </Text> | ||
| <TextInput | ||
| style={styles.placementIdsInput} | ||
| placeholder="e.g., 1, 2, 3" | ||
| placeholderTextColor="#999" | ||
| value={placementIdsInput} | ||
| onChangeText={setPlacementIdsInput} | ||
| keyboardType="numbers-and-punctuation" | ||
| /> | ||
| </View> | ||
| <TouchableOpacity style={styles.button} onPress={getEmbeddedMessages}> | ||
| <Text style={styles.buttonText}> | ||
| Get messages for placement ids | ||
|
|
@@ -227,7 +238,7 @@ export const Embedded = () => { | |
| </View> | ||
| </View> | ||
| </Modal> | ||
| <View style={styles.hr} /> | ||
| <View style={styles.embeddedHr} /> | ||
| <ScrollView> | ||
| <View style={styles.embeddedSection}> | ||
| {embeddedMessages.map((message) => ( | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -34,7 +34,7 @@ export const styles = StyleSheet.create({ | |
| }, | ||
| buttonText: { | ||
| fontSize: 14, | ||
| fontWeight: '400', | ||
| fontWeight: '700', | ||
| lineHeight: 20, | ||
|
Comment on lines
35
to
38
|
||
| paddingHorizontal: 12, | ||
| paddingVertical: 8, | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -98,6 +98,8 @@ export const IterableEmbeddedNotification = ({ | |
| key={button.id} | ||
| > | ||
| <Text | ||
| ellipsizeMode="tail" | ||
| numberOfLines={1} | ||
| style={[ | ||
|
Comment on lines
100
to
103
|
||
| styles.buttonText, | ||
| { color: textColor } as TextStyle, | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor formatting inconsistency:
container:{is missing a space after the colon. Other style objects in the example app usekey: {(e.g., Commerce.styles.ts). Update tocontainer: {to keep formatting consistent and avoid churn in future diffs.