- {illustration?.content ? illustration.content : 'Default Title'}
+ className="flex w-full justify-center px-4 py-2 my-4 font-semibold text-medium bg-gray-300 hover:bg-gray-500 text-white rounded-md shadow-sm"
+ onClick={() => { navigator.clipboard.writeText(illustration.content) }}>
Copy Illustration Content}
+
+ {illustration?.content ? illustration.content : 'No Content'}
@@ -112,49 +146,86 @@ export default function IllustrationWrapper() {
-
-
-
-
Illustration Usage:
- {/* <% unless @places.empty? %>
- <% @places.each do |p| %>
- <% unless p.place.blank? %><%= p.place %>, <% end %><% unless p.location.blank? %><%= p.location %> - <% end %><% unless p.used.blank? %><%= p.used.strftime("%m/%d/%Y") %><% end %>
- <% end %>
- <% end %> */}
- {/*
-
-
-{/* <%= form_with(model: Place, id: :places_form) do |form| %> */}
- {/*
-
- {/* <%= form.text_field :place, id: :place_place, class: "form-control", placeholder: "Place" %> */}
- {/*
-
-
-
- {/* <%= form.text_field :location, id: :place_location, class: "form-control", placeholder: "Location" %> */}
- {/*
-
-
-
- {/* <%= form.text_field :used, id: :place_used, class: "form-control", value: Time.now.strftime("%m/%d/%Y") %> */}
- {/*
-
-
- {/* <% end %>
+ >
+ }
+ {!editIllustration &&
+ <>
+
+ Illustration Use:
+
+
+ {illustration && illustration?.places.length > 0 ? illustration.places.map((p, index) => (
-
*/}
+
+ {p.place}, {p.location} - {p.used}
+ handleDeletePlace(p)}
+ className='rounded-md p-2 font-semibold text-sm bg-red-300 hover:bg-red-500 text-white shadow-sm inline-flex items-center'>
+
+
+ ))
+ :
+
No places found.
+ }
+
+}
)
}
diff --git a/frontend/yarn.lock b/frontend/yarn.lock
index d4d591e..17c4801 100644
--- a/frontend/yarn.lock
+++ b/frontend/yarn.lock
@@ -1092,6 +1092,11 @@ damerau-levenshtein@^1.0.8:
resolved "https://registry.npmjs.org/damerau-levenshtein/-/damerau-levenshtein-1.0.8.tgz"
integrity sha512-sdQSFB7+llfUcQHUQO3+B8ERRj0Oa4w9POWMI/puGtuf7gFywGmkaLCElnudfTiKZV+NvHqL0ifzdrI8Ro7ESA==
+date-fns@^2.29.3:
+ version "2.29.3"
+ resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-2.29.3.tgz#27402d2fc67eb442b511b70bbdf98e6411cd68a8"
+ integrity sha512-dDCnyH2WnnKusqvZZ6+jA1O51Ibt8ZMRNkDZdyAyK4YfbDwa/cEmuztzG5pk6hqlp9aSBPYcjOlktquahGwGeA==
+
debug@^3.2.7:
version "3.2.7"
resolved "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz"