// @flow
import * as React from 'react'
import {TextInput, StyleSheet} from 'react-native'
import * as c from '@frogpond/colors'
import {AllHtmlEntities} from 'html-entities'

const entities = new AllHtmlEntities()

const styles = StyleSheet.create({
	text: {
		color: c.black,
		backgroundColor: c.white,
		paddingHorizontal: 15,
		paddingTop: 10,
		paddingBottom: 10,
	},
})

export const SelectableCell = ({text}: {text: string}) => (
	<TextInput
		dataDetectorTypes="all"
		editable={false}
		multiline={true}
		style={styles.text}
		value={entities.decode(text)}
	/>
)

@@ -125,94 +125,8 @@
 ors'
-%0Aimport %7BAllHtmlEntities%7D from 'html-entities'%0A%0Aconst entities = new AllHtmlEntities()
 %0A%0Aco
@@ -456,29 +456,12 @@
 ue=%7B
-entities.decode(
 text
-)
 %7D%0A%09/

remove entity decoding from SelectableCell