Simple Implementation In Stroybook Of SearchInput

By the way, I added *~ to .gitignore, which are the backups of emacs editor.
See the Storybook of SearchInput.
Problems:
* I found no way to separate the heading of the search results from the first item. Do we have to write a complete new component for this?
* The incoming data must by sorted by type before passed to the component. I added keys searchType and firstType, to identify the type (post/user) (may be as a locale) and to know when I have to place the heading.
This commit is contained in:
Moriz Wahl 2019-11-17 00:01:44 +01:00
parent f9678a7512
commit 595320dd1b

View File

@ -99,6 +99,8 @@ export const results = [
{
id: '7b654f72-f4da-4315-8bed-39de0859754b',
searchType: 'Users',
avatar:
'https://steamcdn-a.akamaihd.net/steamcommunity/public/images/avatars/db/dbc9e03ebcc384b920c31542af2d27dd8eea9dc2_full.jpg',
name: 'Tonya Mohr',
label: 'Tonya Mohr',
slug: 'tonya-mohr',