Skip to content

Commit

Permalink
Merge pull request #651 from thepolicylab-projectportals/issue-455
Browse files Browse the repository at this point in the history
feat: enable images in project description text
  • Loading branch information
JRWallace committed Nov 6, 2023
2 parents 0c0b28a + f6dabe9 commit 4979d72
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 15 deletions.
33 changes: 18 additions & 15 deletions packages/example-site/content/project/completed-project.json
Original file line number Diff line number Diff line change
@@ -1,26 +1,29 @@
{
"requirement": "example requirement",
"topics": [
"example-topic"
],
"agency": "example agency",
"keyDates": "example keyDates",
"summary": "example summary that is also testing the media folder. \n\n![A watercolor painting of a cat laying in some leaves.](/image/cat.jpg \"Cat\")",
"question": "Hello world (from json)?",
"mainContact": "first-contact",
"created": "2023-10-13T16:07:13.466Z",
"endDate": "2016-12-15",
"fundingInfo": "example fundingInfo",
"opportunityCloses": "2022-10-28",
"startDate": "2022-06-17",
"expertise": "example expertise",
"status": "completed",
"statusOfData": "example statusOfData",
"projectTeam": [
"second-contact",
"first-contact"
],
"title": "completed 1",
"agency": "example agency",
"deliverable": "example deliverable",
"description": "example description",
"emailContent": "example emailContent",
"endDate": "2016-12-15",
"expertise": "example expertise",
"fundingInfo": "example fundingInfo",
"keyDates": "example keyDates",
"lastModified": "2022-08-31T20:33:19.394Z",
"opportunityCloses": "2022-10-28",
"purpose": "example purpose",
"requirement": "example requirement",
"startDate": "2022-06-17",
"status": "completed",
"statusOfData": "example statusOfData",
"summary": "example summary",
"topics": ["example-topic"]
}
"lastModified": "2023-10-13T21:29:52.403Z",
"deliverable": "example deliverable"
}
Binary file added packages/example-site/static/image/cat.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions packages/project-portal-content-netlify/src/cms/cms.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ CMS.init({
folder: "content/project",
extension: "json",
create: true,
media_folder: "/static/image",
public_folder: "/image",
identifier_field: "title",
sortable_fields: ["title", "status", "lastModified"],
preview_path: "project/{{slug}}",
Expand Down

0 comments on commit 4979d72

Please sign in to comment.