GuidesComponentsdiary

DiaryCard.TaskIcon

The DiaryCard.TaskIcon component displays a measurement type icon. It is inherited from the Tile module's TaskIcon and exposed on DiaryCard for convenience.

  • Stable unknown
  • Release candidate since 1.16.1-rc.3
  • Development since 1.16.1-dev.2111+9796905

The DiaryCard.TaskIcon component displays a measurement type icon. It is inherited from the Tile module's TaskIcon and exposed on DiaryCard for convenience.

Basic Example

import { MeasurementTypeKey } from "@ovok/core/next";
import { DiaryCard } from "@ovok/native";
import * as React from "react";

const BasicDiaryCardTaskIconExample = () => {
  return (
    <DiaryCard.TaskIcon measurementTypeKey={MeasurementTypeKey.bodyWeight} />
  );
};

export default BasicDiaryCardTaskIconExample;

Props

Every prop, with its type and description, is listed in the @ovok/native/diary API reference.

Styling

Theme Colors Used

  • theme.colors.primary - Default icon color when color is not provided

If the measurement key has no bundled SVG mapping, the component returns null; it does not render a generic placeholder. The core key used for the urine-analysis icon is MeasurementTypeKey.uricAcid; a separate urineAnalysis name is not mapped and will therefore render nothing.

Last updated on

On this page