-
Notifications
You must be signed in to change notification settings - Fork 214
Expand file tree
/
Copy pathsearch-suggestions.js
More file actions
149 lines (149 loc) · 4.25 KB
/
search-suggestions.js
File metadata and controls
149 lines (149 loc) · 4.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
/*
* Copyright (c) 2021, salesforce.com, inc.
* All rights reserved.
* SPDX-License-Identifier: BSD-3-Clause
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/BSD-3-Clause
*/
export default {
baseStyle: {
container: {
padding: 6,
spacing: 0
},
sectionHeader: {
fontWeight: 200,
margin: '2 0 1 0',
paddingLeft: 12,
color: 'gray.500',
fontSize: 'sm',
lineHeight: 1.2
},
phraseContainer: {
margin: '2 0 1 0',
paddingLeft: 12
},
suggestionsContainer: {
spacing: 0
},
suggestionsBox: {
mx: '-16px'
// borderBottom: '1px solid',
// borderColor: 'gray.200'
},
suggestionButton: {
width: 'full',
fontSize: 'md',
marginTop: 0,
variant: 'menu-link',
style: {
justifyContent: 'flex-start',
padding: '8px 12px'
}
},
imageContainer: {
width: 10,
height: 10,
marginRight: 4,
borderRadius: 'full',
background: 'transparent',
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
overflow: 'hidden'
},
suggestionImage: {
boxSize: 10,
borderRadius: 'full',
objectFit: 'cover',
background: '#f3f3f3'
},
textContainer: {
textAlign: 'left'
},
suggestionName: {
fontWeight: '500',
as: 'span'
},
brandName: {
fontWeight: '700',
as: 'span'
},
categoryParent: {
as: 'span',
color: 'gray.500',
fontSize: 'sm'
},
badgeGroup: {
position: 'absolute',
top: 2,
left: 2
},
askAssistantBanner: {
// Mobile: rounded top corners, full-bleed into container padding, internal padding 24px (no 100vw = no horizontal scroll)
// Desktop: same full-bleed
borderRadius: {base: 'md', md: 0},
borderTopLeftRadius: {base: 'md', md: 0},
borderTopRightRadius: {base: 'md', md: 0},
padding: {base: '14px 24px', md: '14px 30%'},
margin: 0,
marginBottom: {base: 0, md: -6},
marginLeft: -6,
width: 'calc(100% + 48px)',
boxSizing: 'border-box',
cursor: 'pointer',
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
gap: 3,
color: 'gray.800',
minHeight: '56px',
background:
'linear-gradient(to right, #E0EDFC 0%, #E8E5FC 40%, #F5E5ED 70%, #E8E5FC 100%)',
_hover: {
background:
'linear-gradient(to right, #C7DCFC 0%, #DDD6FC 40%, #F0C9DE 70%, #DDD6FC 100%)'
}
},
askAssistantBannerContent: {
display: 'flex',
flexDirection: 'column',
flex: 1,
minWidth: 0,
padding: 0,
justifyContent: 'center',
alignItems: 'flex-start',
textAlign: 'left'
},
askAssistantBannerTitleRow: {
display: 'flex',
alignItems: 'center',
justifyContent: 'space-between',
gap: 2,
width: '100%'
},
askAssistantBannerTitle: {
fontSize: 'md',
lineHeight: 1.25,
color: 'gray.800',
textAlign: 'left'
},
askAssistantBannerDescription: {
fontSize: 'sm',
color: 'gray.600',
marginTop: '2px',
textAlign: 'left'
},
askAssistantBannerIcon: {
flexShrink: 0,
padding: 0,
display: 'flex',
alignItems: 'center',
transform: 'translateY(-50%)'
},
askAssistantBannerArrow: {
flexShrink: 0,
display: 'flex',
alignItems: 'center'
}
}
}