@@ -94,77 +94,76 @@ function FeaturedPlantersSlider({
94
94
onScroll = { debounce ( onScroll , 70 ) }
95
95
>
96
96
{ planters . map ( ( planter ) => (
97
- < Tooltip
98
- key = { planter . id }
99
- title = { showAppropiateToolTipName ( planter ) }
100
- classes = { {
101
- tooltip : classes . toolTip ,
102
- } }
103
- >
104
- < Card
97
+ < Link href = { link ( planter . id ) } key = { `featured-planter-${ planter . id } ` } >
98
+ < Tooltip
105
99
key = { planter . id }
106
- elevation = { 8 }
107
- sx = { {
108
- transition : 'all .5s' ,
109
- scrollSnapAlign : 'center' ,
110
- scrollBehavior : 'smooth' ,
111
- // position: 'relative',
112
- padding : ( theme ) => theme . spacing ( 5 ) ,
113
- borderRadius : ( theme ) => theme . spacing ( 4 ) ,
114
- overflow : 'initial' ,
115
- cursor : 'pointer' ,
116
- bgcolor : ( t ) =>
117
- t . palette . mode === 'light'
118
- ? d3
119
- . color ( t . palette [ color ] . main )
120
- . copy ( { opacity : 0.2 } )
121
- . formatRgb ( )
122
- : d3
123
- . color ( t . palette [ color ] . main )
124
- . copy ( { opacity : 0.4 } )
125
- . formatRgb ( ) ,
100
+ title = { showAppropiateToolTipName ( planter ) }
101
+ classes = { {
102
+ tooltip : classes . toolTip ,
126
103
} }
127
104
>
128
- < CardMedia
129
- onClick = { ( ) => {
130
- window . location . href = link ( planter . id ) ;
131
- } }
132
- component = "img"
133
- image = "https://treetracker-production.nyc3.digitaloceanspaces.com/2019.07.10.18.32.42_b4fad89a-10b6-40cc-a134-0085d0e581d2_IMG_20190710_183201_8089920786231467340.jpg"
134
- alt = "tree"
105
+ < Card
106
+ key = { planter . id }
107
+ elevation = { 8 }
135
108
sx = { {
136
- width : 136 ,
137
- height : 136 ,
138
- borderWidth : 4 ,
139
- borderStyle : 'solid' ,
140
- borderColor : ( t ) => t . palette . background . paper ,
141
- boxSizing : 'border-box' ,
142
- borderRadius : '50%' ,
143
- transition : 'transform .5s' ,
109
+ transition : 'all .5s' ,
110
+ scrollSnapAlign : 'center' ,
111
+ scrollBehavior : 'smooth' ,
112
+ // position: 'relative',
113
+ padding : ( theme ) => theme . spacing ( 5 ) ,
114
+ borderRadius : ( theme ) => theme . spacing ( 4 ) ,
115
+ overflow : 'initial' ,
116
+ cursor : 'pointer' ,
117
+ bgcolor : ( t ) =>
118
+ t . palette . mode === 'light'
119
+ ? d3
120
+ . color ( t . palette [ color ] . main )
121
+ . copy ( { opacity : 0.2 } )
122
+ . formatRgb ( )
123
+ : d3
124
+ . color ( t . palette [ color ] . main )
125
+ . copy ( { opacity : 0.4 } )
126
+ . formatRgb ( ) ,
144
127
} }
145
- />
146
- { false && (
147
- < CardContent >
148
- < Typography
149
- variant = "h6"
150
- sx = { {
151
- fontSize : '20px' ,
152
- marginTop : 4 ,
153
- wordBreak : 'break-all' ,
154
- } }
155
- align = "center"
156
- >
157
- < Link href = { link ( planter . id ) } >
158
- { planter . first_name }
159
-
160
- { ( planter . last_name && planter . last_name . slice ( 0 , 1 ) ) ||
161
- '' }
162
- </ Link >
163
- </ Typography >
164
- </ CardContent >
165
- ) }
166
- </ Card >
167
- </ Tooltip >
128
+ >
129
+ < CardMedia
130
+ component = "img"
131
+ image = "https://treetracker-production.nyc3.digitaloceanspaces.com/2019.07.10.18.32.42_b4fad89a-10b6-40cc-a134-0085d0e581d2_IMG_20190710_183201_8089920786231467340.jpg"
132
+ alt = "tree"
133
+ sx = { {
134
+ width : 136 ,
135
+ height : 136 ,
136
+ borderWidth : 4 ,
137
+ borderStyle : 'solid' ,
138
+ borderColor : ( t ) => t . palette . background . paper ,
139
+ boxSizing : 'border-box' ,
140
+ borderRadius : '50%' ,
141
+ transition : 'transform .5s' ,
142
+ } }
143
+ />
144
+ { false && (
145
+ < CardContent >
146
+ < Typography
147
+ variant = "h6"
148
+ sx = { {
149
+ fontSize : '20px' ,
150
+ marginTop : 4 ,
151
+ wordBreak : 'break-all' ,
152
+ } }
153
+ align = "center"
154
+ >
155
+ < Link href = { link ( planter . id ) } >
156
+ { planter . first_name }
157
+
158
+ { ( planter . last_name && planter . last_name . slice ( 0 , 1 ) ) ||
159
+ '' }
160
+ </ Link >
161
+ </ Typography >
162
+ </ CardContent >
163
+ ) }
164
+ </ Card >
165
+ </ Tooltip >
166
+ </ Link >
168
167
) ) }
169
168
</ Grid >
170
169
0 commit comments