{
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "$id": "https://paramlet.com/tools/cabinet-light-mount/schema.json",
 "title": "Under-cabinet & puck light mount — parameters",
 "description": "Generate 3D-printable angled tilt brackets (0–45°) for magnetic LED bars (23–26 cm) and retention rings for Ø76 mm puck lights with unobstructed motion-sensor windows. All lengths are millimetres. Unknown keys are rejected; out-of-range values are rejected by the URL and API and clamped when a project file is opened.",
 "x-tool": "cabinet-light-mount",
 "x-toolVersion": "1.1.1",
 "x-specVersion": "1.0",
 "x-apiVersion": "1",
 "x-groups": [
  {
   "id": "light",
   "title": "Light dimensions (measure to confirm)"
  },
  {
   "id": "mount",
   "title": "Bracket & angle"
  },
  {
   "id": "look",
   "title": "Colour"
  }
 ],
 "x-presets": {
  "note": "Choosing a preset resets every key marked x-resetOnPreset to its default and then applies the preset values.",
  "items": [
   {
    "id": "measure-your-own",
    "title": "Measure your own cabinet light",
    "description": "Generic under-cabinet LED bar tilt clips or round puck ring: measure your light first.",
    "values": {
     "lightType": "bar",
     "barLength": 260,
     "barWidth": 40,
     "barThickness": 10,
     "tiltDeg": 30,
     "color": "#c85a32"
    }
   },
   {
    "id": "fits-gritin-26cm-motion-bar",
    "title": "Fits Gritin 26 cm Motion Cabinet Light",
    "description": "Listing dims 260×40×10 mm — measure to confirm before printing. Not affiliated with or endorsed by Gritin.",
    "values": {
     "lightType": "bar",
     "barLength": 260,
     "barWidth": 40,
     "barThickness": 10,
     "tiltDeg": 30,
     "color": "#2a7f76"
    }
   },
   {
    "id": "fits-23cm-motion-bar",
    "title": "Fits 23 cm Motion LED Cabinet Bar",
    "description": "Listing dims 230×35×14 mm — measure to confirm before printing. Not affiliated with or endorsed by the light manufacturer.",
    "values": {
     "lightType": "bar",
     "barLength": 230,
     "barWidth": 35,
     "barThickness": 14,
     "tiltDeg": 30,
     "color": "#d4a024"
    }
   },
   {
    "id": "fits-76mm-puck-light",
    "title": "Fits HELPLEX 76 mm LED Puck Light",
    "description": "Listing dims Ø76.2×25 mm — measure to confirm before printing. Not affiliated with or endorsed by HELPLEX.",
    "values": {
     "lightType": "puck",
     "puckDia": 76.2,
     "puckHeight": 25,
     "tiltDeg": 0,
     "color": "#3b5b8c"
    }
   }
  ]
 },
 "x-coreParams": {
  "exportFormat": {
   "type": "string",
   "title": "File format",
   "description": "3mf = 3MF (mm); stl = STL files in a zip (mm)",
   "x-group": "download",
   "x-role": "core.exportFormat",
   "x-unit": "none",
   "x-agentSafe": true,
   "enum": [
    "3mf",
    "stl"
   ],
   "default": "3mf"
  },
  "exportTol": {
   "type": "number",
   "title": "Mesh precision",
   "description": "Simplification tolerance in mm (0 = original mesh).",
   "x-group": "download",
   "x-role": "core.exportTolerance",
   "x-unit": "mm",
   "x-agentSafe": true,
   "enum": [
    0,
    0.01,
    0.02
   ],
   "default": 0.02
  },
  "units": {
   "type": "string",
   "title": "Units shown",
   "description": "Display only: mm or inches (1 in = 25.4 mm). Stored values, the API and exports are always mm.",
   "x-group": "view",
   "x-role": "core.displayUnits",
   "x-unit": "none",
   "x-agentSafe": true,
   "enum": [
    "mm",
    "in"
   ],
   "x-enumTitles": {
    "mm": "Millimetres",
    "in": "Inches"
   },
   "default": "mm"
  },
  "massUnits": {
   "type": "string",
   "title": "Weight shown in",
   "description": "Display only: grams or ounces (1 oz = 28.3495 g). Stored values, the API and exports are always grams.",
   "x-group": "view",
   "x-role": "core.displayMassUnits",
   "x-unit": "none",
   "x-agentSafe": true,
   "enum": [
    "g",
    "oz"
   ],
   "x-enumTitles": {
    "g": "Grams",
    "oz": "Ounces"
   },
   "default": "g"
  }
 },
 "type": "object",
 "properties": {
  "lightType": {
   "type": "string",
   "enum": [
    "bar",
    "puck"
   ],
   "x-enumTitles": {
    "bar": "Linear LED bar (2 end clips)",
    "puck": "Round puck light ring"
   },
   "title": "Light style",
   "description": "Bar: two clips for the ends of a linear LED bar, leaning forward. Puck: a ring that a round light drops into.",
   "x-group": "light",
   "x-agentSafe": true,
   "x-label-lv": "Lampas tips",
   "default": "bar"
  },
  "barLength": {
   "type": "number",
   "minimum": 100,
   "maximum": 500,
   "multipleOf": 5,
   "title": "Bar length (reference)",
   "description": "For your record only: the clips do not depend on the length of the bar.",
   "x-group": "light",
   "x-unit": "mm",
   "x-visibleIf": {
    "lightType": "bar"
   },
   "x-agentSafe": true,
   "x-label-lv": "Stieņa garums",
   "default": 260
  },
  "barWidth": {
   "type": "number",
   "minimum": 18,
   "maximum": 70,
   "x-step": 0.5,
   "title": "Bar width (measure)",
   "description": "Width of the bar, across its cross-section. The cradle is made 0.6 mm wider.",
   "x-group": "light",
   "x-unit": "mm",
   "x-visibleIf": {
    "lightType": "bar"
   },
   "x-agentSafe": true,
   "x-label-lv": "Stieņa platums (izmēri)",
   "default": 40
  },
  "barThickness": {
   "type": "number",
   "minimum": 6,
   "maximum": 28,
   "x-step": 0.5,
   "title": "Bar thickness (measure)",
   "description": "Thickness of the bar. The cradle leaves 4 mm of room above it.",
   "x-group": "light",
   "x-unit": "mm",
   "x-visibleIf": {
    "lightType": "bar"
   },
   "x-agentSafe": true,
   "x-label-lv": "Stieņa biezums (izmēri)",
   "default": 10
  },
  "puckDia": {
   "type": "number",
   "minimum": 45,
   "maximum": 110,
   "x-step": 0.2,
   "title": "Puck diameter (measure)",
   "description": "Diameter of the round light. The ring is made 0.6 mm wider, so the light drops in.",
   "x-group": "light",
   "x-unit": "mm",
   "x-visibleIf": {
    "lightType": "puck"
   },
   "x-agentSafe": true,
   "x-label-lv": "Ripas diametrs (izmēri)",
   "default": 76.2
  },
  "puckHeight": {
   "type": "number",
   "minimum": 12,
   "maximum": 40,
   "x-step": 0.5,
   "title": "Puck height (measure)",
   "description": "Height of the round light. The ring wraps around 60 % of it, at most 14 mm.",
   "x-group": "light",
   "x-unit": "mm",
   "x-visibleIf": {
    "lightType": "puck"
   },
   "x-agentSafe": true,
   "x-label-lv": "Ripas augstums",
   "default": 25
  },
  "tiltDeg": {
   "type": "number",
   "minimum": 0,
   "maximum": 45,
   "multipleOf": 5,
   "title": "Tilt angle",
   "description": "How far the cradle turns the bar from the foot. 30° aims the light at the worktop in front instead of straight down; 45° is the limit.",
   "x-group": "mount",
   "x-unit": "deg",
   "x-visibleIf": {
    "lightType": "bar"
   },
   "x-agentSafe": true,
   "x-label-lv": "Slīpuma leņķis",
   "default": 30
  },
  "material": {
   "type": "string",
   "enum": [
    "petg",
    "pla"
   ],
   "x-enumTitles": {
    "petg": "PETG (recommended for kitchen)",
    "pla": "PLA"
   },
   "title": "Filament",
   "description": "PETG next to a kettle, a hob or steam. PLA softens at about 55 °C.",
   "x-group": "mount",
   "x-role": "core.printMaterial",
   "x-agentSafe": true,
   "x-label-lv": "Filaments",
   "default": "petg"
  },
  "wallCount": {
   "type": "integer",
   "minimum": 2,
   "maximum": 6,
   "multipleOf": 1,
   "title": "Perimeter walls",
   "description": "Perimeter lines. Three are enough: the clips carry nothing but the light.",
   "x-group": "mount",
   "x-unit": "count",
   "x-role": "print.wallCount",
   "x-agentSafe": true,
   "x-label-lv": "Sienu skaits",
   "default": 3
  },
  "infill": {
   "type": "integer",
   "minimum": 5,
   "maximum": 100,
   "multipleOf": 5,
   "title": "Infill",
   "description": "15 to 20 % is enough. More walls help the clips more than more infill.",
   "x-group": "mount",
   "x-unit": "pct",
   "x-role": "print.infill",
   "x-agentSafe": true,
   "x-label-lv": "Aizpildījums",
   "default": 20
  },
  "color": {
   "type": "string",
   "pattern": "^#[0-9a-fA-F]{6}$",
   "title": "Colour",
   "description": "Colour of the clips or the ring. White disappears under a light cupboard, black under a dark one.",
   "x-group": "look",
   "x-role": "core.previewColor",
   "x-agentSafe": true,
   "x-label-lv": "Krāsa",
   "default": "#c5c9cc"
  }
 },
 "additionalProperties": false,
 "recommended_materials": [
  {
   "id": "petg-filament-1kg",
   "title": "PETG Filament 1.75 mm (1 kg) — heat-resistant & durable",
   "why": "Stronger and more heat-resistant than PLA for molds, jigs and outdoor parts.",
   "url": "https://paramlet.com/go/petg-filament-1kg?src=agent",
   "relation": "material",
   "disclosure": "Affiliate link (Amazon Associates, tag paramlet-21)"
  },
  {
   "id": "pla-matte-filament",
   "title": "Matte PLA Filament 1.75 mm (1 kg) — smooth surface finish",
   "why": "Clean matte finish for decorative vases, ornaments and candle holders.",
   "url": "https://paramlet.com/go/pla-matte-filament?src=agent",
   "relation": "material",
   "disclosure": "Affiliate link (Amazon Associates, tag paramlet-21)"
  }
 ]
}