Display trigger word in slash command autocomplete (#2078)
This commit is contained in:
parent
688d6579d0
commit
c13081ad34
2 changed files with 1 additions and 4 deletions
|
|
@ -124,7 +124,6 @@ export default class SlashSuggestion extends Component {
|
|||
|
||||
renderItem = ({item}) => (
|
||||
<SlashSuggestionItem
|
||||
displayName={item.display_name}
|
||||
description={item.auto_complete_desc}
|
||||
hint={item.auto_complete_hint}
|
||||
onPress={this.completeSuggestion}
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@ import {changeOpacity, makeStyleSheetFromTheme} from 'app/utils/theme';
|
|||
|
||||
export default class SlashSuggestionItem extends PureComponent {
|
||||
static propTypes = {
|
||||
displayName: PropTypes.string,
|
||||
description: PropTypes.string,
|
||||
hint: PropTypes.string,
|
||||
onPress: PropTypes.func.isRequired,
|
||||
|
|
@ -27,7 +26,6 @@ export default class SlashSuggestionItem extends PureComponent {
|
|||
|
||||
render() {
|
||||
const {
|
||||
displayName,
|
||||
description,
|
||||
hint,
|
||||
theme,
|
||||
|
|
@ -41,7 +39,7 @@ export default class SlashSuggestionItem extends PureComponent {
|
|||
onPress={this.completeSuggestion}
|
||||
style={style.row}
|
||||
>
|
||||
<Text style={style.suggestionName}>{`/${displayName || trigger} ${hint}`}</Text>
|
||||
<Text style={style.suggestionName}>{`/${trigger} ${hint}`}</Text>
|
||||
<Text style={style.suggestionDescription}>{description}</Text>
|
||||
</TouchableOpacity>
|
||||
);
|
||||
|
|
|
|||
Loading…
Reference in a new issue