mirror of
https://github.com/felipegcoutinho/openmonetis.git
synced 2026-05-09 02:51:46 +00:00
16 lines
460 B
TypeScript
16 lines
460 B
TypeScript
import type { Note } from "@/components/anotacoes/types";
|
|
import type { DashboardNote } from "@/lib/dashboard/notes";
|
|
|
|
export const mapDashboardNoteToNote = (note: DashboardNote): Note => ({
|
|
id: note.id,
|
|
title: note.title,
|
|
description: note.description,
|
|
type: note.type,
|
|
tasks: note.tasks,
|
|
arquivada: note.arquivada,
|
|
createdAt: note.createdAt,
|
|
});
|
|
|
|
export const mapDashboardNotesToNotes = (notes: DashboardNote[]) =>
|
|
notes.map(mapDashboardNoteToNote);
|