{
  "accessibility" : [
    "One element per pin. Its label is the title, or the marker text when there is no title; clusters read \"132 places\" (after the title if there is one).",
    "A selected pin has the `.isSelected` trait; selection is also visible by size, outline and the title, not by colour.",
    "The marker grows with Dynamic Type (`@ScaledMetric`)."
  ],
  "category" : "maps",
  "changelog" : [
    {
      "changes" : [
        "Release 1.1.0: see the project changelog."
      ],
      "date" : "2026-12-03",
      "version" : "1.1.0"
    },
    {
      "changes" : [
        "Initial release."
      ],
      "date" : "2026-12-02",
      "version" : "1.0.0"
    }
  ],
  "dependencies" : [
    {
      "id" : "glass-foundation",
      "version" : "1.1.0"
    }
  ],
  "description" : "Configurable marker with selection and an accessible label; clustering is left to the map engine.",
  "examples" : [
    {
      "code" : "import SwiftUI\nimport SPGlassKit\n\npublic struct GlassMapPinExample: GlassExample {\n    public static let componentID = \"glass-map-pin\"\n\n    private struct Place: Identifiable {\n        let id: String\n        let title: String\n        let content: GlassMapPinContent\n        let tint: GlassColorToken\n        /// Position in the unit square of the placeholder map.\n        let position: UnitPoint\n    }\n\n    /// Fictitious places.\n    private let places = [\n        Place(id: \"cafe\", title: \"Café Exemple\", content: .symbol(\"cup.and.saucer.fill\"), tint: .primary, position: UnitPoint(x: 0.25, y: 0.3)),\n        Place(id: \"museum\", title: \"Musée fictif des très longs noms de lieux\", content: .symbol(\"building.columns.fill\"), tint: .accent, position: UnitPoint(x: 0.7, y: 0.25)),\n        Place(id: \"price\", title: \"Listing A-12\", content: .text(\"$1.2M\"), tint: .success, position: UnitPoint(x: 0.5, y: 0.55)),\n        Place(id: \"warning\", title: \"Road works\", content: .symbol(\"exclamationmark.triangle.fill\"), tint: .warning, position: UnitPoint(x: 0.2, y: 0.75)),\n    ]\n    @State private var selection: String? = \"cafe\"\n\n    public init() {}\n\n    public var body: some View {\n        GeometryReader { proxy in\n            SampleMapBackdrop()\n                .overlay {\n                    ForEach(places) { place in\n                        Button {\n                            selection = selection == place.id ? nil : place.id\n                        } label: {\n                            GlassMapPin(place.content, title: place.title, tint: place.tint, isSelected: selection == place.id)\n                        }\n                        .buttonStyle(.plain)\n                        .position(x: proxy.size.width * place.position.x, y: proxy.size.height * place.position.y)\n                    }\n                    // Cluster markers: the count comes from the map engine, the pin only formats it.\n                    GlassMapPin(clusterCount: 12)\n                        .position(x: proxy.size.width * 0.8, y: proxy.size.height * 0.6)\n                    GlassMapPin(clusterCount: 1_340, title: \"Downtown\")\n                        .position(x: proxy.size.width * 0.75, y: proxy.size.height * 0.8)\n                }\n        }\n    }\n}\n\n#Preview(\"GlassMapPin\") { GlassMapPinExample().glassTheme(.solar) }\n",
      "title" : "GlassMapPin example"
    }
  ],
  "files" : [
    {
      "bytes" : 11563,
      "path" : "Maps/Maps/GlassMapPin.swift",
      "sha256" : "34af5140ae297212878beab2ce798ee4baf6648fe78db8c9614231a674621742"
    }
  ],
  "frameworks" : [

  ],
  "id" : "glass-map-pin",
  "kind" : "content-component",
  "license" : "MIT",
  "minimumOS" : {
    "iOS" : "26.0",
    "iPadOS" : "26.0",
    "macOS" : "26.0"
  },
  "name" : "GlassMapPin",
  "platforms" : [
    "iOS",
    "iPadOS",
    "macOS"
  ],
  "schemaVersion" : 1,
  "sha256" : "f1805be9265fc65d493483854e13663458f2659af70be918179ffb9ee83a0263",
  "symbols" : [
    "GlassMapPinContent",
    "GlassMapPinFormatting",
    "GlassMapPinLayout",
    "GlassMapPinShape",
    "GlassMapPin"
  ],
  "version" : "1.1.0"
}
