Skip to content

Commit

Permalink
Merge pull request #887 from trey-wallis/dev
Browse files Browse the repository at this point in the history
8.15.4
  • Loading branch information
decaf-dev authored Nov 28, 2023
2 parents 4c6f435 + e08eeb2 commit 5362e0c
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@
"fundingUrl": {
"Buymeacoffee": "https://www.buymeacoffee.com/treywallis"
},
"version": "8.15.3"
"version": "8.15.4"
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "obsidian-dataloom",
"version": "8.15.3",
"version": "8.15.4",
"description": "Weave together data from diverse sources into different views. Inspired by Excel Spreadsheets and Notion.so.",
"main": "main.js",
"scripts": {
Expand Down
9 changes: 8 additions & 1 deletion src/shared/frontmatter/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,14 @@ export const deserializeFrontmatterForCell = (

//The formatterValue will return either YYYY-MM-DD or YYYY-MM-DDTHH:MM
//the date object will take this in as local time as output an ISO string
const dateString = frontmatterValue;
let dateString = frontmatterValue;

//2023-12-12 will be intrepreted in UTC time by `new Date()` if it doesn't have a timestamp
//so we need to add a time
const DATE_WITHOUT_TIME_REGEX = /^\d{4}-\d{2}-\d{2}$/;
if (dateString.match(DATE_WITHOUT_TIME_REGEX)) {
dateString += "T00:00:00";
}
const newCell = createDateCell(id, {
dateTime: new Date(dateString).toISOString(),
});
Expand Down
3 changes: 2 additions & 1 deletion versions.json
Original file line number Diff line number Diff line change
Expand Up @@ -152,5 +152,6 @@
"8.15.0": "1.4.0",
"8.15.1": "1.4.0",
"8.15.2": "1.4.0",
"8.15.3": "1.4.0"
"8.15.3": "1.4.0",
"8.15.4": "1.4.0"
}

0 comments on commit 5362e0c

Please sign in to comment.