{
  "name": "Label",
  "category": "Utility",
  "subcategory": null,
  "description": "Form label that links to a control via for/id.",
  "thumbnail": "/preview-cards/label.png",
  "hasDocsPage": true,
  "nugetPackage": "Lumeo",
  "files": [
    "UI/Label/Label.razor"
  ],
  "dependencies": [],
  "packageDependencies": [],
  "cssVars": [
    "--color-foreground"
  ],
  "api": {
    "name": "Label",
    "category": "Utility",
    "subcategory": null,
    "description": "Form label that links to a control via for/id.",
    "nugetPackage": "Lumeo",
    "files": [
      "UI/Label/Label.razor"
    ],
    "namespace": "Lumeo",
    "inheritsFrom": null,
    "implements": [],
    "parameters": [
      {
        "name": "ChildContent",
        "type": "RenderFragment?",
        "default": null,
        "description": null,
        "isCascading": false,
        "captureUnmatched": false
      },
      {
        "name": "For",
        "type": "string?",
        "default": null,
        "description": null,
        "isCascading": false,
        "captureUnmatched": false
      },
      {
        "name": "Class",
        "type": "string?",
        "default": null,
        "description": null,
        "isCascading": false,
        "captureUnmatched": false
      },
      {
        "name": "AdditionalAttributes",
        "type": "Dictionary<string, object>?",
        "default": null,
        "description": null,
        "isCascading": false,
        "captureUnmatched": true
      }
    ],
    "events": [],
    "enums": [],
    "records": [],
    "cssVars": [
      "--color-foreground"
    ],
    "examples": [
      {
        "title": "Default",
        "code": "<Label>Email address</Label>\n<Input Type=\"email\" Placeholder=\"you@example.com\" />"
      },
      {
        "title": "Required Field",
        "code": "<Stack Gap=\"2\">\n    <Flex Gap=\"1\" Align=\"center\">\n        <Label>Email address</Label>\n        <Lumeo.Text As=\"span\" Size=\"sm\" Color=\"destructive\">*</Lumeo.Text>\n    </Flex>\n    <Input type=\"email\" placeholder=\"you@example.com\" />\n    <Lumeo.Text Size=\"xs\" Color=\"muted\">We'll never share your email.</Lumeo.Text>\n</Stack>\n<Stack Gap=\"2\">\n    <Flex Align=\"center\" Justify=\"between\">\n        <Label>Password</Label>\n        <a href=\"#\" class=\"text-xs text-primary hover:underline\">Forgot password?</a>\n    </Flex>\n    <Input type=\"password\" placeholder=\"••••••••\" />\n</Stack>"
      },
      {
        "title": "Multiple Fields",
        "code": "<Stack Gap=\"2\">\n    <Label>First name</Label>\n    <Input Placeholder=\"John\" />\n</Stack>\n<Flex Gap=\"2\" Align=\"center\">\n    <Checkbox @bind-Checked=\"_agreed\" />\n    <Label>I agree to the terms and conditions</Label>\n</Flex>"
      }
    ],
    "subComponents": {},
    "parseFailed": false,
    "parseError": null
  },
  "$schema": "https://lumeo.nativ.sh/registry-component-schema.json",
  "key": "label",
  "docsUrl": "https://lumeo.nativ.sh/components/label",
  "sourceUrl": [
    {
      "file": "UI/Label/Label.razor",
      "url": "https://github.com/Brain2k-0005/Lumeo/tree/master/src/Lumeo/UI/Label/Label.razor"
    }
  ],
  "source": [
    {
      "path": "UI/Label/Label.razor",
      "content": "@namespace Lumeo\n\n<label for=\"@For\" class=\"@CssClass\" @attributes=\"AdditionalAttributes\">\n    @ChildContent\n</label>\n\n@code {\n    [Parameter] public RenderFragment? ChildContent { get; set; }\n    [Parameter] public string? For { get; set; }\n    [Parameter] public string? Class { get; set; }\n    [Parameter(CaptureUnmatchedValues = true)] public Dictionary<string, object>? AdditionalAttributes { get; set; }\n\n    private string CssClass => $\"text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70 {Class}\".Trim();\n}\n"
    }
  ],
  "slots": [
    {
      "name": "ChildContent",
      "owner": "Label",
      "type": "RenderFragment?",
      "description": null
    }
  ],
  "serviceDependencies": [],
  "cascadingDependencies": [],
  "relatedComponents": [],
  "keyboardInteractions": [],
  "tests": [
    "tests/Lumeo.Docs.Tests/Services/NavConfigServiceTests.cs",
    "tests/Lumeo.Tests/Components/BottomNav/BottomNavAnimatedTests.cs",
    "tests/Lumeo.Tests/Components/BottomNav/BottomNavItemCursorTests.cs",
    "tests/Lumeo.Tests/Components/BottomNav/BottomNavItemTests.cs",
    "tests/Lumeo.Tests/Components/Cascader/CascaderTests.cs",
    "tests/Lumeo.Tests/Components/Checkbox/CheckboxTests.cs",
    "tests/Lumeo.Tests/Components/ContextMenu/ContextMenuTests.cs",
    "tests/Lumeo.Tests/Components/DropdownMenu/DropdownMenuTests.cs",
    "tests/Lumeo.Tests/Components/FileUpload/FileUploadTests.cs",
    "tests/Lumeo.Tests/Components/Filter/FilterPillTests.cs",
    "tests/Lumeo.Tests/Components/Form/FormTests.cs",
    "tests/Lumeo.Tests/Components/Gauge/GaugeTests.cs",
    "tests/Lumeo.Tests/Components/KpiCard/KpiCardTests.cs",
    "tests/Lumeo.Tests/Components/Label/LabelTests.cs",
    "tests/Lumeo.Tests/Components/Menubar/MenubarTests.cs",
    "tests/Lumeo.Tests/Components/QueryBuilder/QueryBuilderTests.cs",
    "tests/Lumeo.Tests/Components/Segmented/SegmentedTests.cs",
    "tests/Lumeo.Tests/Components/SparkCard/SparkCardTests.cs",
    "tests/Lumeo.Tests/Components/SpeedDial/SpeedDialTests.cs",
    "tests/Lumeo.Tests/Components/Spinner/SpinnerTests.cs",
    "tests/Lumeo.Tests/Components/Switch/SwitchCursorTests.cs",
    "tests/Lumeo.Tests/Components/TreeSelect/TreeSelectTests.cs"
  ],
  "mdSummary": "# Label\n\nForm label that links to a control via for/id.\n\n**Package:** `Lumeo` · **Category:** Utility\n**Docs:** https://lumeo.nativ.sh/components/label\n\n## Parameters\n| Owner | Name | Type | Default | Description |\n|---|---|---|---|---|\n| Label | ChildContent | `RenderFragment?` | `` |  |\n| Label | For | `string?` | `` |  |\n| Label | Class | `string?` | `` |  |\n| Label | AdditionalAttributes | `Dictionary<string, object>?` | `` |  |\n\n## Slots\n- `ChildContent` (Label) — RenderFragment slot\n\n## Events\n- (none)\n\n## Sub-components\n- (none)\n\n## Cascading values it expects\n- (none)\n\n## Services it injects\n- (none)\n\n## Keyboard\n—\n\n## Example\n```razor\n<Label />\n```\n\n## CSS variables\n`--color-foreground`\n\n## Files\n- `UI/Label/Label.razor`\n"
}