{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "Meter Row component",
  "devDependencies": [],
  "digest": "0.1.0",
  "files": [
    {
      "content": "<!-- Code generated by packages/kit-compose/src/organisms.ts from packages/compose-gen/specs (compose-gen organism emitters on kit-compose). DO NOT EDIT. -->\n<!--\n  A name, a value caption and a progress bar (completeness by section, issues by rule, stock by warehouse). With\n  `href` the whole row is a link.\n-->\n<script lang=\"ts\">\nexport type MeterRowProps = {\n  label: string;\n  value: number;\n  caption: string;\n  hint?: string;\n  href?: string;\n  class?: string;\n};\n</script>\n\n<script setup lang=\"ts\">\nimport Box from \"../compose/Box.vue\";\nimport Link from \"../compose/Link.vue\";\nimport Progress from \"../compose/Progress.vue\";\nimport Text from \"../compose/Text.vue\";\nimport { cn, urlOf } from \"../utils\";\n\nconst { label, value, caption, hint, href, class: className } = defineProps<MeterRowProps>();\n</script>\n\n<template>\n  <Box :class=\"cn('min-w-0', className)\" data-slot=\"meter-row\">\n    <Link v-if=\"href\"\n      :href=\"urlOf(href)\"\n      variant=\"block\"\n      class=\"flex min-w-0 flex-col gap-2 rounded p-2 text-foreground no-underline hover:bg-muted\"\n    >\n      <Box class=\"flex items-baseline justify-between gap-4\">\n        <Text class=\"m-0 min-w-0 truncate text-sm font-bold text-foreground\">\n          {{ label }}\n        </Text>\n        <Text class=\"m-0 shrink-0 text-xs font-semibold tabular-nums text-muted-foreground\">\n          {{ caption }}\n        </Text>\n      </Box>\n      <Progress :value=\"(value == null ? undefined : String(value))\" max=\"100\" :aria-label=\"label\" />\n      <Text v-if=\"hint\" class=\"m-0 text-xs font-medium text-muted-foreground\">\n        {{ hint }}\n      </Text>\n    </Link>\n    <Box v-else class=\"flex min-w-0 flex-col gap-2 p-2\">\n      <Box class=\"flex items-baseline justify-between gap-4\">\n        <Text class=\"m-0 min-w-0 truncate text-sm font-bold text-foreground\">\n          {{ label }}\n        </Text>\n        <Text class=\"m-0 shrink-0 text-xs font-semibold tabular-nums text-muted-foreground\">\n          {{ caption }}\n        </Text>\n      </Box>\n      <Progress :value=\"(value == null ? undefined : String(value))\" max=\"100\" :aria-label=\"label\" />\n      <Text v-if=\"hint\" class=\"m-0 text-xs font-medium text-muted-foreground\">\n        {{ hint }}\n      </Text>\n    </Box>\n  </Box>\n</template>\n",
      "path": "components/meter-row.vue",
      "target": "components/meter-row.vue"
    }
  ],
  "meta": {
    "category": "components",
    "kind": "component",
    "tags": [
      "vue",
      "component"
    ]
  },
  "name": "meter-row",
  "registryDependencies": [
    "box",
    "link",
    "progress",
    "text",
    "utils"
  ],
  "runtime": "vue",
  "title": "Meter Row",
  "type": "registry:component"
}
