Skip to content

Commit

Permalink
Merge branch 'develop' into ja/theme-switcher
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesacklin authored Nov 24, 2024
2 parents 67ffecb + fa3a49c commit 25f3c98
Show file tree
Hide file tree
Showing 22 changed files with 328 additions and 59 deletions.
2 changes: 1 addition & 1 deletion apps/tlon-mobile/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ android {
targetSdkVersion rootProject.ext.targetSdkVersion
compileSdk rootProject.ext.compileSdkVersion
versionCode 108
versionName "4.2.1"
versionName "4.2.2"

buildConfigField("boolean", "REACT_NATIVE_UNSTABLE_USE_RUNTIME_SCHEDULER_ALWAYS", (findProperty("reactNative.unstable_useRuntimeSchedulerAlways") ?: true).toString())
}
Expand Down
8 changes: 4 additions & 4 deletions apps/tlon-mobile/ios/Landscape.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1427,7 +1427,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 4.2.1;
MARKETING_VERSION = 4.2.2;
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
Expand Down Expand Up @@ -1465,7 +1465,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 4.2.1;
MARKETING_VERSION = 4.2.2;
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
Expand Down Expand Up @@ -1689,7 +1689,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 4.2.1;
MARKETING_VERSION = 4.2.2;
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
Expand Down Expand Up @@ -1732,7 +1732,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 4.2.1;
MARKETING_VERSION = 4.2.2;
OTHER_LDFLAGS = (
"$(inherited)",
"-ObjC",
Expand Down
51 changes: 39 additions & 12 deletions desk/app/expose.hoon
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,16 @@
:: then visit in the browser:
:: /expose/that/reference/as/copied/123456789
::
/- c=cite, d=channels, co=contacts
/- c=cite, d=channels, co=contacts-0
/+ u=channel-utils, hutils=http-utils,
dbug, verb
::
/= page /app/expose/page
/= widget /app/expose/widget
::
|%
+$ state-0
$: %0
+$ state-1
$: %1
open=(set cite:c)
==
::
Expand Down Expand Up @@ -79,7 +79,7 @@
%+ verb |
^- agent:gall
::
=| state-0
=| state-1
=* state -
|_ =bowl:gall
+* this .
Expand All @@ -88,18 +88,43 @@
:_ this
:~ [%pass /eyre/connect %arvo %e %connect [~ /expose] dap.bowl]
[%pass /channels %agent [our.bowl %channels] %watch /v1]
[%pass /contacts %agent [our.bowl %contacts] %watch /contact]
[%pass /contacts/news %agent [our.bowl %contacts] %watch /news]
==
::
++ on-save !>(state)
++ on-load
|= ole=vase
|^ |= ole=vase
^- (quip card _this)
=. state !<(state-0 ole)
:_ this
:: we must defer refreshing the cache because rendering scries
=+ !<(old=versioned-state ole)
=+ ver=-.old
=? old ?=(%0 -.old) old(- %1)
?> ?=(%1 -.old)
=. state old
=/ caz=(list card)
:: we must defer refreshing the cache because rendering scries
::
[%pass /refresh %arvo %b %wait now.bowl]~
:: leave obsolete %contacts endpoint and connect
::
=? caz ?=(%0 ver)
%+ weld caz
^- (list card)
:~ [%pass /contacts %agent [our.bowl %contacts] %leave ~]
:: leave %conacts (sic) agent sub
[%pass /contacts %agent [our.bowl %conacts] %leave ~]
[%pass /contacts/news %agent [our.bowl %contacts] %watch /news]
==
[caz this]
::
[%pass /refresh %arvo %b %wait now.bowl]~
+$ versioned-state
$% state-1
state-0
==
+$ state-0
$: %0
open=(set cite:c)
==
--
::
++ on-poke
|= [=mark =vase]
Expand Down Expand Up @@ -254,10 +279,10 @@
==
==
::
[%contacts ~]
[%contacts %news ~]
?- -.sign
%poke-ack !!
%kick [[%pass /contacts %agent [our.bowl %conacts] %watch /contact]~ this]
%kick [[%pass /contacts/news %agent [our.bowl %contacts] %watch /news]~ this]
::
%watch-ack
?~ p.sign [~ this]
Expand All @@ -274,6 +299,8 @@
:: fresh(er), we should just set an hourly timer that re-render the
:: entire cache.
::
=+ !<(=news-0:co q.cage.sign)
?. =(our.bowl who.news-0) `this
:_ this
%+ weld
(refresh-widget:e bowl open)
Expand Down
4 changes: 2 additions & 2 deletions desk/app/expose/page.hoon
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
:: expose page: rendering for content pages
::
/- c=cite, d=channels, co=contacts
/- c=cite, d=channels, co=contacts-0
/+ u=channel-utils
::
/= r /app/expose/render
Expand All @@ -10,7 +10,7 @@
++ render
|= [=bowl:gall =nest:g:c msg=post:d]
^- (unit manx)
=/ aco=(unit contact:co)
=/ aco=(unit contact-0:co)
(get-contact:co bowl author.msg)
::
::TODO if we render replies then we can "unroll" whole chat threads too (:
Expand Down
4 changes: 2 additions & 2 deletions desk/app/expose/render.hoon
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
:: expose render: rendering utilities for pages & the widget
::
/- co=contacts
/- co=contacts-0
/+ sigil
::
|%
++ author
=/ link=(unit @t) ~
|= [=bowl:gall author=ship]
^- manx
=/ aco=(unit contact:co)
=/ aco=(unit contact-0:co)
(get-contact:co bowl author)
|^ ::TODO we should just have a bunch of manx construction helpers
:: for stuff like this
Expand Down
59 changes: 45 additions & 14 deletions desk/app/profile.hoon
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,16 @@
:: other apps can poke this agent with widgets of their own, and the user
:: can choose which widgets to display on their public page.
::
/- contacts-0
/- co=contacts-0
/+ dbug, verb, sigil, hutils=http-utils
/= stock-widgets /app/profile/widgets
::
/* style-shared %css /app/profile/style/shared/css
/* style-page %css /app/profile/style/page/css
::
|%
+$ state-0
$: %0
+$ state-1
$: %1
bound=_|
::
widgets=(map desk (map term widget))
Expand Down Expand Up @@ -44,7 +44,7 @@
+$ card $+(card card:agent:gall)
--
::
|_ [=bowl:gall state-0]
|_ [=bowl:gall state-1]
+* this .
state +<+
++ bind
Expand Down Expand Up @@ -175,8 +175,8 @@
::
++ render-page
^- manx
=/ ours=(unit contact-0:contacts-0)
(get-contact:contacts-0 bowl our.bowl)
=/ ours=(unit contact-0:co)
(get-contact:co bowl our.bowl)
|^ ;html
;+ head
;+ body
Expand Down Expand Up @@ -255,7 +255,7 @@
%- agent:dbug
%+ verb |
::
=| state-0
=| state-1
=* state -
^- agent:gall
|_ =bowl:gall
Expand All @@ -266,15 +266,15 @@
::NOTE we special-case the "internal" widgets
=. layout [[%groups %profile] [%groups %join-button] [%groups %profile-bio] ~]
:_ this
:~ [%pass /contacts/ours %agent [our.bowl %contacts] %watch /contact]
:~ [%pass /contacts/news %agent [our.bowl %contacts] %watch /news]
[%pass /refresh %arvo %b %wait now.bowl]
==
::
++ on-save
!>(state)
::
++ on-load
|= ole=vase
|^ |= ole=vase
^- (quip card _this)
:: a different %profile agent has been spotted in the wild. it was not
:: compatible with the kelvin at which this agent was first released, made
Expand All @@ -287,10 +287,38 @@
?=(^ ((soft ,[%0 (map path mime) (set @p) (unit @t)]) q.ole))
==
on-init
=. state !<(state-0 ole)
:: delay, so we don't end up scrying during load
=+ !<(old=versioned-state ole)
=+ ver=-.old
=? old ?=(%0 -.old) old(- %1)
?> ?=(%1 -.old)
=. state old
::
=/ caz=(list card)
:: delay, so we don't end up scrying during load
[%pass /refresh %arvo %b %wait now.bowl]~
:: leave obsolete %contacts endpoint and connect
::
=? caz ?=(%0 ver)
%+ weld caz
^- (list card)
:~ [%pass /contacts/ours %agent [our.bowl %contacts] %leave ~]
[%pass /contacts/news %agent [our.bowl %contacts] %watch /news]
==
[caz this]
::
[[%pass /refresh %arvo %b %wait now.bowl]~ this]
+$ versioned-state
$% state-1
state-0
==
+$ state-0
$: %0
bound=_|
::
widgets=(map desk (map term widget))
layout=(list [=desk =term])
tlon-cta=?
==
--
::
++ on-poke
|= [=mark =vase]
Expand Down Expand Up @@ -328,7 +356,7 @@
?. ?=(%live +<.egg-any)
~& [dap.bowl %egg-any-not-live]
[~ this]
(on-load -:!>(*state-0) +>.old-state.egg-any)
(on-load -:!>(*state-1) +>.old-state.egg-any)
==
==
::
Expand All @@ -343,7 +371,10 @@
|= [=wire =sign:agent:gall]
~| wire=wire
?+ wire ~|(%strange-wire !!)
[%contacts %ours ~]
[%contacts %news ~]
?. ?=(%fact -.sign) `this
=+ !<(=news-0:co q.cage.sign)
?. =(our.bowl who.news-0) `this
=^ caz state update-group-widgets:do
[caz this]
==
Expand Down
10 changes: 5 additions & 5 deletions desk/app/profile/widgets.hoon
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
:: profile: construct stock widgets
::
/- contacts-0
/- co=contacts-0
/+ sigil
::
|= =bowl:gall
=/ ours=(unit contact-0:contacts-0)
=, contacts-0
=/ ours=(unit contact-0:co)
=, co
::NOTE we scry for the full rolodex, because we are not guaranteed to
:: have an entry for ourselves, and contacts doesn't expose a "safe"
:: (as in crashless) endpoint for checking
Expand Down Expand Up @@ -160,7 +160,7 @@
=src "{(trip u.avatar.u.ours)}"
=alt "Avatar";
=/ value=@ux ?~(ours 0x0 color.u.ours)
=/ color=tape ((x-co:co 6) value)
=/ color=tape ((x-co:^co 6) value)
;div.profile-headline-avatar-sigil(style "background-color: #{color}")
;+ %. our.bowl
%_ sigil
Expand Down Expand Up @@ -192,7 +192,7 @@
=src "{(trip u.avatar.u.ours)}"
=alt "Avatar";
=/ value=@ux ?~(ours 0x0 color.u.ours)
=/ color=tape ((x-co:co 6) value)
=/ color=tape ((x-co:^co 6) value)
;div.profile-headline-avatar-sigil(style "background-color: #{color}")
;+ %. our.bowl
%_ sigil
Expand Down
2 changes: 1 addition & 1 deletion desk/desk.docket-0
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
info+'Start, host, and cultivate communities. Own your communications, organize your resources, and share documents. Tlon is a decentralized platform that offers a full, communal suite of tools for messaging, writing and sharing media with others.'
color+0xde.dede
image+'https://bootstrap.urbit.org/tlon.svg?v=1'
glob-http+['https://bootstrap.urbit.org/glob-0v2.0sojn.dfu5p.k01gq.vuid2.pni63.glob' 0v2.0sojn.dfu5p.k01gq.vuid2.pni63]
glob-http+['https://bootstrap.urbit.org/glob-0v3.kb628.u97k6.jqbce.0ob0l.acjt8.glob' 0v3.kb628.u97k6.jqbce.0ob0l.acjt8]
base+'groups'
version+[6 4 2]
website+'https://tlon.io'
Expand Down
2 changes: 1 addition & 1 deletion desk/sur/activity.hoon
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@
[%group-kick & |]
[%group-join & |]
[%group-role & |]
[%contact | &]
[%contact | |]
==
++ old-volumes
^~
Expand Down
Loading

0 comments on commit 25f3c98

Please sign in to comment.