A React Native app for the ultimate thinking partner.

fix(knowledge): improve search bar and header visibility

- Show 'Search memory blocks...' only in Core Memory tab
- Remove redundant 'Archival Memory' header
- Add + button to archival memory search bar for creating passages
- Remove search bar from Files tab

+49 -48
+49 -48
App.tsx
··· 2210 2210 </TouchableOpacity> 2211 2211 </View> 2212 2212 2213 - {/* Search bar */} 2214 - <View style={styles.memorySearchContainer}> 2215 - <Ionicons name="search" size={20} color={theme.colors.text.tertiary} style={styles.memorySearchIcon} /> 2216 - <TextInput 2217 - style={[styles.memorySearchInput, { 2218 - color: theme.colors.text.primary, 2219 - backgroundColor: theme.colors.background.tertiary, 2220 - borderColor: theme.colors.border.primary, 2221 - }]} 2222 - placeholder="Search memory blocks..." 2223 - placeholderTextColor={theme.colors.text.tertiary} 2224 - value={memorySearchQuery} 2225 - onChangeText={setMemorySearchQuery} 2226 - /> 2227 - </View> 2213 + {/* Search bar - only for Core Memory tab */} 2214 + {knowledgeTab === 'core' && ( 2215 + <View style={styles.memorySearchContainer}> 2216 + <Ionicons name="search" size={20} color={theme.colors.text.tertiary} style={styles.memorySearchIcon} /> 2217 + <TextInput 2218 + style={[styles.memorySearchInput, { 2219 + color: theme.colors.text.primary, 2220 + backgroundColor: theme.colors.background.tertiary, 2221 + borderColor: theme.colors.border.primary, 2222 + }]} 2223 + placeholder="Search memory blocks..." 2224 + placeholderTextColor={theme.colors.text.tertiary} 2225 + value={memorySearchQuery} 2226 + onChangeText={setMemorySearchQuery} 2227 + /> 2228 + </View> 2229 + )} 2228 2230 2229 2231 {/* Knowledge blocks grid */} 2230 2232 <View style={styles.memoryBlocksGrid}> ··· 2299 2301 ) : knowledgeTab === 'archival' ? ( 2300 2302 /* Archival Memory view */ 2301 2303 <> 2302 - <View style={{ flexDirection: 'row', justifyContent: 'space-between', alignItems: 'center', paddingHorizontal: 8, paddingVertical: 12 }}> 2303 - <Text style={[styles.memorySectionTitle, { color: theme.colors.text.secondary, marginBottom: 0 }]}>Archival Memory</Text> 2304 - <TouchableOpacity 2305 - onPress={() => setIsCreatingPassage(true)} 2306 - style={{ padding: 4 }} 2307 - > 2308 - <Ionicons name="add-circle-outline" size={24} color={theme.colors.text.primary} /> 2309 - </TouchableOpacity> 2310 - </View> 2311 - 2312 - {/* Semantic Search bar */} 2313 - <View style={styles.memorySearchContainer}> 2314 - <Ionicons name="search" size={20} color={theme.colors.text.tertiary} style={styles.memorySearchIcon} /> 2315 - <TextInput 2316 - style={[styles.memorySearchInput, { 2317 - color: theme.colors.text.primary, 2318 - backgroundColor: theme.colors.background.tertiary, 2319 - borderColor: theme.colors.border.primary, 2320 - }]} 2321 - placeholder="Search passages (semantic)..." 2322 - placeholderTextColor={theme.colors.text.tertiary} 2323 - value={passageSearchQuery} 2324 - onChangeText={setPassageSearchQuery} 2325 - onSubmitEditing={() => loadPassages(true)} 2326 - /> 2327 - {passageSearchQuery && ( 2304 + {/* Semantic Search bar with Add button */} 2305 + <View style={{ paddingHorizontal: 16, paddingVertical: 8 }}> 2306 + <View style={styles.memorySearchContainer}> 2307 + <Ionicons name="search" size={20} color={theme.colors.text.tertiary} style={styles.memorySearchIcon} /> 2308 + <TextInput 2309 + style={[styles.memorySearchInput, { 2310 + color: theme.colors.text.primary, 2311 + backgroundColor: theme.colors.background.tertiary, 2312 + borderColor: theme.colors.border.primary, 2313 + paddingRight: passageSearchQuery ? 80 : 50, 2314 + }]} 2315 + placeholder="Search passages (semantic)..." 2316 + placeholderTextColor={theme.colors.text.tertiary} 2317 + value={passageSearchQuery} 2318 + onChangeText={setPassageSearchQuery} 2319 + onSubmitEditing={() => loadPassages(true)} 2320 + /> 2321 + {passageSearchQuery && ( 2322 + <TouchableOpacity 2323 + style={{ position: 'absolute', right: 56, padding: 8 }} 2324 + onPress={() => { 2325 + setPassageSearchQuery(''); 2326 + loadPassages(true); 2327 + }} 2328 + > 2329 + <Ionicons name="close-circle" size={20} color={theme.colors.text.tertiary} /> 2330 + </TouchableOpacity> 2331 + )} 2328 2332 <TouchableOpacity 2329 - style={{ position: 'absolute', right: 28, padding: 8 }} 2330 - onPress={() => { 2331 - setPassageSearchQuery(''); 2332 - loadPassages(true); 2333 - }} 2333 + style={{ position: 'absolute', right: 16, padding: 8 }} 2334 + onPress={() => setIsCreatingPassage(true)} 2334 2335 > 2335 - <Ionicons name="close-circle" size={20} color={theme.colors.text.tertiary} /> 2336 + <Ionicons name="add-circle-outline" size={24} color={theme.colors.text.primary} /> 2336 2337 </TouchableOpacity> 2337 - )} 2338 + </View> 2338 2339 </View> 2339 2340 {isLoadingPassages ? ( 2340 2341 <View style={styles.memoryLoadingContainer}>