How to remove padding from Popup? · Issue #716 - GitHub
文章推薦指數: 80 %
react-map-gl render a Mapbox popup component. If you want to use customized styles, you can override mapbox pop styles.
Skiptocontent
{{message}}
visgl
/
react-map-gl
Public
Notifications
Fork
1.2k
Star
6.6k
Code
Issues
11
Pullrequests
5
Discussions
Actions
Security
Insights
More
Code
Issues
Pullrequests
Discussions
Actions
Security
Insights
Newissue
Haveaquestionaboutthisproject?SignupforafreeGitHubaccounttoopenanissueandcontactitsmaintainersandthecommunity.
Pickausername
EmailAddress
Password
SignupforGitHub
Byclicking“SignupforGitHub”,youagreetoourtermsofserviceand
privacystatement.We’lloccasionallysendyouaccountrelatedemails.
AlreadyonGitHub?
Signin
toyouraccount
Jumptobottom
HowtoremovepaddingfromPopup?
#716
Closed
juiceoopenedthisissue
Feb5,2019
·2comments
Closed
HowtoremovepaddingfromPopup?
#716
juiceoopenedthisissue
Feb5,2019
·2comments
Comments
Copylink
juiceo
commented
Feb5,2019
•
edited
Isthereawaytoremovethepadding(and/orbackgroundcolor)fromthePopupcomponent(withoutoverridingthecssstyleinmystylesheet)?SayIwantedtomakethebackgroundofmypopupsred:
Thetextwasupdatedsuccessfully,buttheseerrorswereencountered:
Allreactions
Copylink
Collaborator
xintongxia
commented
Feb6,2019
react-map-glrenderaMapboxpopupcomponent.
Ifyouwanttousecustomizedstyles,youcanoverridemapboxpopstyles.
Youcanreferthisdocandsearchpopup.
Thefollowingmightbehelpful.
.mapboxgl-popup-content{
background:red;
}
.mapboxgl-popup-tip{
background:red;
}
❤️
1
itzjustalanreactedwithheartemoji
Allreactions
❤️
1reaction
Sorry,somethingwentwrong.
Pessimistress
closedthisascompleted
Jun12,2019
Copylink
disambiguator
commented
Jun25,2019
•
edited
Areyouallopentoallowingdynamicstylingofpopupsthroughinlinestyling?Thiscurrentsolutiondoesn'tworkforusbecausewedecidepopupcolorprogrammaticallybasedontheelementbeinghoveredover.
IwouldloveasolutionsimilartothewaytipSizeisabletobepassedin,forexample:
延伸文章資訊
- 1How to display Popups on a Mapbox Map in React
This tutorial will be covering how to display popups on a Mapbox map in a React app with the reac...
- 2How to remove padding from Popup? · Issue #716 - GitHub
react-map-gl render a Mapbox popup component. If you want to use customized styles, you can overr...
- 3How to display Popups on a Mapbox Map - Morioh
import ReactMapGL, {Marker, Popup } from 'react-map-gl'; const CustomPopup = ({index, marker, clo...
- 4Popup - react-map-gl
A string indicating the part of the popup that should be positioned closest to the coordinate, se...
- 5react-map-gl.Popup JavaScript and Node.js code examples
Best JavaScript code snippets using react-map-gl.Popup(Showing top 3 results out of 315). origin:...