mirror of
https://github.com/urbit/shrub.git
synced 2024-11-24 13:06:09 +03:00
updating messages view
This commit is contained in:
parent
67e68b36be
commit
a9724601e9
@ -50,9 +50,9 @@
|
||||
;form.fr.jc.g1.createchat.w70
|
||||
::=hx-sync "closest div:queue last"
|
||||
=hx-post "/neo/hawk{pt}?stud=messenger-diff"
|
||||
=head "new-groupchat"
|
||||
=hx-target "find button .loading"
|
||||
=hx-swap "outerHTML"
|
||||
=hx-target "find button .loading"
|
||||
=head "new-groupchat"
|
||||
;input.grow.border.p2.br1.grow
|
||||
=id "name-input"
|
||||
=name "name"
|
||||
@ -68,7 +68,6 @@
|
||||
;span.loading
|
||||
;+ loading.feather-icons
|
||||
==
|
||||
:: ==
|
||||
==
|
||||
==
|
||||
::
|
||||
@ -109,11 +108,12 @@
|
||||
;span.hidden: no dms
|
||||
?: (lte 3 (lent pith))
|
||||
;h1.hidden: {<pith>}
|
||||
=/ ship +:;;([%p @p] `(list iota)`(rear pith))
|
||||
^- manx
|
||||
;a.br1.hover.b0.fr.jb.wf.border
|
||||
=href "/neo/hawk{(pith-tape here.bowl)}{(pith-tape pith)}"
|
||||
=hx-swap "innerHTML"
|
||||
;h3.s-1.p2: {(scow %tas ;;(@tas -.pith))}
|
||||
;h3.s-1.p2: {<+:;;([%p @p] (rear pith))>}
|
||||
;h3.s-1.p2: {<ship>}
|
||||
==
|
||||
==
|
||||
;div.fc.ac.g2.wf
|
||||
|
10
pkg/arvo/neo/cod/std/src/con/node-message.hoon
Normal file
10
pkg/arvo/neo/cod/std/src/con/node-message.hoon
Normal file
@ -0,0 +1,10 @@
|
||||
/@ node
|
||||
/@ message
|
||||
/- manx-utils
|
||||
:- [%node %$ %message]
|
||||
|= nod=node
|
||||
^- message
|
||||
=/ text (~(vol manx-utils nod) "text")
|
||||
=/ ship (slav %p (~(vol manx-utils nod) "ship"))
|
||||
=/ date (slav %da (~(vol manx-utils nod) "date"))
|
||||
[ship date text]
|
@ -3,26 +3,20 @@
|
||||
:- [%txt %$ %htmx]
|
||||
|= =txt
|
||||
|= =bowl:neo
|
||||
:: ;form.fc.p2.wf.hf.relative
|
||||
:: =here (en-tape:pith:neo here.bowl)
|
||||
:: =hx-post "/neo/hawk{(en-tape:pith:neo here.bowl)}?stud=txt&refresh"
|
||||
:: =hx-trigger "input changed delay:0.4s from:find textarea"
|
||||
:: =hx-swap "none"
|
||||
:: ;div.htmx-indicator.absolute
|
||||
:: =style "top: 15px; right: 15px"
|
||||
:: ;+ loading.feather-icons
|
||||
:: ==
|
||||
:: ;textarea.wf.p2.bd1.br1.grow
|
||||
:: =autocomplete "off"
|
||||
:: =rows "4"
|
||||
:: =name "text"
|
||||
:: =oninput "this.setAttribute('value', this.value);"
|
||||
:: ; {(trip (@t txt))}
|
||||
:: ==
|
||||
;div.fc.g2.border.p3.br1
|
||||
;div.fr.ac.jb
|
||||
;p.s-2.f3: {(scow %p our.bowl)}
|
||||
;p.s-2.f3: now
|
||||
;form.fc.p2.wf.hf.relative
|
||||
=here (en-tape:pith:neo here.bowl)
|
||||
=hx-post "/neo/hawk{(en-tape:pith:neo here.bowl)}?stud=txt&refresh"
|
||||
=hx-trigger "input changed delay:0.4s from:find textarea"
|
||||
=hx-swap "none"
|
||||
;div.htmx-indicator.absolute
|
||||
=style "top: 15px; right: 15px"
|
||||
;+ loading.feather-icons
|
||||
==
|
||||
;textarea.wf.p2.bd1.br1.grow
|
||||
=autocomplete "off"
|
||||
=rows "4"
|
||||
=name "text"
|
||||
=oninput "this.setAttribute('value', this.value);"
|
||||
; {(trip (@t txt))}
|
||||
==
|
||||
;p: {(trip (@t txt))}
|
||||
==
|
||||
|
@ -51,10 +51,10 @@
|
||||
|= [=bowl:neo location=pith]
|
||||
^- manx
|
||||
;form.fc.g2
|
||||
=hx-post "{(en-tape:pith:neo :(welp /neo/hawk here.bowl location))}?stud=txt"
|
||||
=hx-swap "beforebegin"
|
||||
=hx-post "{(en-tape:pith:neo :(welp /neo/hawk here.bowl location))}?stud=message"
|
||||
=hx-swap "outerHTML swap:5s"
|
||||
=hx-on-submit "this.reset()"
|
||||
=hx-target "this"
|
||||
=hx-target "find button .loading"
|
||||
=head "msg"
|
||||
=id "render-sender"
|
||||
;textarea.p2.border.br1
|
||||
@ -66,6 +66,16 @@
|
||||
=autocomplete "off"
|
||||
;
|
||||
==
|
||||
;input.hidden
|
||||
=name "ship"
|
||||
=value (scow %p our.bowl)
|
||||
;
|
||||
==
|
||||
;input.hidden
|
||||
=name "date"
|
||||
=value (scow %da now.bowl)
|
||||
;
|
||||
==
|
||||
;button.p2.b1.br1.bd1.wfc.hover.loader
|
||||
;span.loaded.s2: create
|
||||
;span.loading
|
||||
|
Loading…
Reference in New Issue
Block a user