Duyuru: Yeni ana harita stili yakında Google Haritalar Platformu'nda kullanıma sunulacak. Harita stilinde yapılan bu güncelleme, yeni bir varsayılan renk paleti, modernleştirilmiş raptiyeler ve harita deneyimleri ile kullanılabilirlik açısından iyileştirmeler içeriyor. Tüm harita stilleri Mart 2025'te otomatik olarak güncellenecektir. Kullanılabilirlik ve özelliği daha erken etkinleştirme hakkında daha fazla bilgi için Google Haritalar Platformu için yeni harita stili başlıklı makaleyi inceleyin.
Yerleşik JSON stil beyanları aracılığıyla aşağıdakilere özelleştirilmiş stil uygulayabilirsiniz:
Varsayılan harita.
Kullanıcının tek bir harita çerçevesinde geçiş yapabileceği harita türleri.
Özelliklere stiller belirtme
Bir haritadaki farklı özelliklere ve öğelere stil uygulamak için haritanın nasıl stillendirileceğini tanımlayan bir MapTypeStyle
nesne dizisi oluşturun.
Dizi aşağıdaki biçimdedir:
varstylesArray=[{featureType:'',elementType:'',stylers:[{color:''},{visibility:''},// Add any stylers you need.]},{featureType:'',// Add the stylers you need.}]
featureType, elementType ve stylers için kullanılabilen tüm değerlerin listesi JSON stili referansında verilmiştir.
Aşağıda, koyu arka planda (ör. koyu mod) açık renkli metin ve simgelerin kullanıldığı örnek bir varsayılan harita gösterilmektedir. Kod örneğini görmek için Tarzlandırılmış Haritalar - Gece Modu kod örneği başlıklı makaleyi inceleyin.
Varsayılan haritanın stillerini değiştirmek için aşağıdaki durumlarda MapOptions nesnesinde haritanın styles özelliğini stil dizinize ayarlayın:
Haritanızı oluşturun.
Veya Map.setOptions yöntemini çağırırken.
Etiketler ve yollar üzerinde yapılan değişiklikler; arazi, uydu, karma ve varsayılan yol haritası türleri dahil tüm harita türlerini etkiler.
Harita türüne stil uygulama
Aşağıda, haritanın sol üst kısmındaki kontrol panelinde Stillendirilmiş Harita adlı bir harita türü gösterilmektedir. Kod örneğini görmek için Tarzlandırılmış Harita Türleri başlıklı makaleyi inceleyin.
Stillendirilmiş bir harita türü oluşturmak için stil dizisini bir StyledMapType nesnesine ayarlayın. Yeni bir stilize harita türü oluşturmak, varsayılan harita türlerinin stilini etkilemez.
[[["Anlaması kolay","easyToUnderstand","thumb-up"],["Sorunumu çözdü","solvedMyProblem","thumb-up"],["Diğer","otherUp","thumb-up"]],[["İhtiyacım olan bilgiler yok","missingTheInformationINeed","thumb-down"],["Çok karmaşık / çok fazla adım var","tooComplicatedTooManySteps","thumb-down"],["Güncel değil","outOfDate","thumb-down"],["Çeviri sorunu","translationIssue","thumb-down"],["Örnek veya kod sorunu","samplesCodeIssue","thumb-down"],["Diğer","otherDown","thumb-down"]],["Son güncelleme tarihi: 2025-02-25 UTC."],[[["Customize the appearance of your maps using embedded JSON style declarations for the default map and selectable map types."],["Style features and elements within the map by creating an array of `MapTypeStyle` objects defining the desired appearance, with the `featureType`, `elementType`, and `stylers` properties determining specific modifications."],["Utilize the Maps Platform Styling Wizard to quickly generate JSON styling objects, simplifying the process of creating custom map styles."],["Apply styles to the default map by setting the `styles` property in the `MapOptions` object during map creation or by using the `Map.setOptions` method."],["Create styled map types by setting the style array to a `StyledMapType` object, enabling the addition of custom map styles without impacting the default map types."]]],["Custom styling for maps can be applied via embedded JSON style declarations to default maps or user-switchable map types. Create an array of `MapTypeStyle` objects specifying `featureType`, `elementType`, and `stylers` to define styling. For consistent styling across apps, use cloud customization with a map ID. Use the Maps Platform Styling Wizard to quickly generate JSON styling or apply styles by setting the map's `styles` property within the `MapOptions` object or the `Map.setOptions` method.\n"]]