mirror of
https://github.com/edufeed-org/edufeed-web.git
synced 2025-12-07 23:34:34 +00:00
disable some logs, prettify add-resource
This commit is contained in:
parent
058d212109
commit
bdd0f4f1e6
4 changed files with 30 additions and 11 deletions
6
.gitignore
vendored
6
.gitignore
vendored
|
|
@ -13,3 +13,9 @@
|
|||
|
||||
# shadow-cljs cache, port files
|
||||
/.shadow-cljs/
|
||||
|
||||
/.clj-kondo/
|
||||
/.calva/
|
||||
/.lsp/
|
||||
|
||||
/dev/
|
||||
|
|
|
|||
|
|
@ -2666,6 +2666,10 @@ details.collapse summary::-webkit-details-marker {
|
|||
margin-top: 0.75rem;
|
||||
}
|
||||
|
||||
.mt-6 {
|
||||
margin-top: 1.5rem;
|
||||
}
|
||||
|
||||
.flex {
|
||||
display: flex;
|
||||
}
|
||||
|
|
@ -2788,6 +2792,12 @@ details.collapse summary::-webkit-details-marker {
|
|||
margin-bottom: calc(1rem * var(--tw-space-y-reverse));
|
||||
}
|
||||
|
||||
.space-y-2 > :not([hidden]) ~ :not([hidden]) {
|
||||
--tw-space-y-reverse: 0;
|
||||
margin-top: calc(0.5rem * calc(1 - var(--tw-space-y-reverse)));
|
||||
margin-bottom: calc(0.5rem * var(--tw-space-y-reverse));
|
||||
}
|
||||
|
||||
.truncate {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
|
|
|
|||
|
|
@ -115,8 +115,8 @@
|
|||
#_(d-id-not-in-deleted-list-ids (get-d-id-from-tags (:tags %)) deleted-lists))
|
||||
events)
|
||||
most-recent-lists (most-recent-by-d-tag all-lists)]
|
||||
(.log js/console "all lists: " (clj->js all-lists))
|
||||
(.log js/console "most recent lists: " (clj->js most-recent-lists))
|
||||
#_(.log js/console "all lists: " (clj->js all-lists))
|
||||
#_(.log js/console "most recent lists: " (clj->js most-recent-lists))
|
||||
most-recent-lists)))
|
||||
|
||||
(re-frame/reg-sub
|
||||
|
|
|
|||
|
|
@ -15,7 +15,8 @@
|
|||
:uri uri
|
||||
:author author})]
|
||||
(fn []
|
||||
[:form {:on-submit (fn [e]
|
||||
[:form {:class "flex flex-col space-y-4"
|
||||
:on-submit (fn [e]
|
||||
(.preventDefault e)
|
||||
;; do something with the state @s
|
||||
)}
|
||||
|
|
@ -46,12 +47,14 @@
|
|||
(defn add-resource-by-json []
|
||||
(let [s (reagent/atom {:json-string ""})]
|
||||
(fn []
|
||||
[:form {:on-submit (fn [e] (.preventDefault e))}
|
||||
[:textarea {:on-change (fn [e]
|
||||
(swap! s assoc :json-string (-> e .-target .-value)))}]
|
||||
[:button {:class "btn btn-warning"
|
||||
:on-click #(re-frame/dispatch [::events/convert-amb-and-publish-as-nostr-event (:json-string @s)])}
|
||||
"Publish as Nostr Event"]])))
|
||||
[:div
|
||||
[:p "Paste an AMB object"]
|
||||
[:form {:on-submit (fn [e] (.preventDefault e))}
|
||||
[:textarea {:on-change (fn [e]
|
||||
(swap! s assoc :json-string (-> e .-target .-value)))}]
|
||||
[:button {:class "btn btn-warning"
|
||||
:on-click #(re-frame/dispatch [::events/convert-amb-and-publish-as-nostr-event (:json-string @s)])}
|
||||
"Publish as Nostr Event"]]])))
|
||||
|
||||
;; TODO try again using xhrio
|
||||
(defn add-resosurce-by-uri []
|
||||
|
|
@ -425,11 +428,11 @@
|
|||
:class "collapse collapse-arrow border-base-300 bg-base-200 border"}
|
||||
[:div
|
||||
{:class "collapse-title text-xl font-medium"}
|
||||
"Focus me to see content"]
|
||||
"Advanced Options"]
|
||||
[:div
|
||||
{:class "collapse-content"}
|
||||
[add-resource-by-json]
|
||||
[add-resosurce-by-uri]]]])
|
||||
#_[add-resosurce-by-uri]]]])
|
||||
|
||||
(defmethod routes/panels :add-resource-panel [] [add-resource-panel])
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue