@lobehub/ui
Version:
Lobe UI is an open-source UI component library for building AIGC web apps
12 lines (10 loc) • 306 B
JavaScript
import dayjs from "dayjs";
//#region src/List/ListItem/time.ts
const getChatItemTime = (updateAt) => {
const time = dayjs(updateAt);
if (time.isSame(dayjs(), "day")) return time.format("HH:mm");
return time.format("MM-DD");
};
//#endregion
export { getChatItemTime };
//# sourceMappingURL=time.mjs.map