Merge b99ca963c0 into release/next-js

This commit is contained in:
janeway-bot 2021-02-12 05:13:11 +04:00 committed by GitHub
commit bbc8f4c456
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 18 additions and 10 deletions

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:197e7c205c783e80008434a1975d8f1e86e1bd8c5d6ab2ca9273cf4749529b08
size 9218537
oid sha256:016d6672c471304c7c728913b169a9a938d3fcb1a5f0d47e92e1c1c9ebde8d92
size 9282017

View File

@ -117,7 +117,6 @@
!=(contact(last-updated *@da) u.old(last-updated *@da))
==
[~ state]
=. last-updated.contact now.bowl
:- (send-diff [%add ship contact] =(ship our.bowl))
state(rolodex (~(put by rolodex) ship contact))
::
@ -132,15 +131,17 @@
state(rolodex (~(del by rolodex) ship))
::
++ handle-edit
|= [=ship =edit-field:store]
|= [=ship =edit-field:store timestamp=@da]
|^
^- (quip card _state)
=/ old (~(got by rolodex) ship)
?: (lte timestamp last-updated.old)
[~ state]
=/ contact (edit-contact old edit-field)
?: =(old contact)
[~ state]
=. last-updated.contact now.bowl
:- (send-diff [%edit ship edit-field] =(ship our.bowl))
=. last-updated.contact timestamp
:- (send-diff [%edit ship edit-field timestamp] =(ship our.bowl))
state(rolodex (~(put by rolodex) ship contact))
::
++ edit-contact

View File

@ -5,7 +5,7 @@
/- glob
/+ default-agent, verb, dbug
|%
++ hash 0v7.d72b8.89c7k.vn1je.k3gvs.qr60j
++ hash 0v1.grvkp.m0c8p.i7s2g.p5mje.im0qo
+$ state-0 [%0 hash=@uv glob=(unit (each glob:glob tid=@ta))]
+$ all-states
$% state-0

View File

@ -24,6 +24,6 @@
<div id="portal-root"></div>
<script src="/~landscape/js/channel.js"></script>
<script src="/~landscape/js/session.js"></script>
<script src="/~landscape/js/bundle/index.6c6f14401abf27359ea5.js"></script>
<script src="/~landscape/js/bundle/index.6aee6f22bd32ebb85e0c.js"></script>
</body>
</html>

View File

@ -42,6 +42,7 @@
%- pairs
:~ [%ship (ship ship.upd)]
[%edit-field (edit edit-field.upd)]
[%timestamp (time timestamp.upd)]
==
::
%allow
@ -140,6 +141,7 @@
%- ot
:~ [%ship (su ;~(pfix sig fed:ag))]
[%edit-field edit]
[%timestamp di]
==
::
++ beings

View File

@ -32,7 +32,7 @@
$% [%initial =rolodex is-public=?]
[%add =ship =contact]
[%remove =ship]
[%edit =ship =edit-field]
[%edit =ship =edit-field timestamp=@da]
[%allow =beings]
[%disallow =beings]
[%set-public public=?]

View File

@ -6,6 +6,7 @@ import { GroupPolicy, Resource } from '~/types/group-update';
export default class ContactsApi extends BaseApi<StoreState> {
add(ship: Patp, contact: any) {
contact['last-updated'] = Date.now();
return this.storeAction({ add: { ship, contact } });
}
@ -25,11 +26,11 @@ export default class ContactsApi extends BaseApi<StoreState> {
{add-group: {ship, name}}
{remove-group: {ship, name}}
*/
console.log(ship, editField);
return this.storeAction({
edit: {
ship,
'edit-field': editField,
timestamp: Date.now()
},
});
}

View File

@ -75,6 +75,7 @@ const otherIndex = function() {
other.push(result('My Channels', '/~landscape/home', 'home', null));
other.push(result('Notifications', '/~notifications', 'inbox', null));
other.push(result('Profile and Settings', `/~profile/~${window.ship}`, 'profile', null));
other.push(result('Messages', '/~landscape/messages', 'messages', null));
other.push(result('Log Out', '/~/logout', 'logout', null));
return other;

View File

@ -65,6 +65,7 @@ export function ImageInput(props: ImageInputProps) {
{canUpload && (
<>
<Button
type="button"
ml={1}
border={1}
borderColor="lightGray"

View File

@ -56,6 +56,8 @@ export class OmniboxResult extends Component {
graphic = <Icon display='inline-block' verticalAlign='middle' icon='Home' mr='2' size='18px' color={iconFill} />;
} else if (icon === 'notifications') {
graphic = <Icon display='inline-block' verticalAlign='middle' icon='Inbox' mr='2' size='18px' color={iconFill} />;
} else if (icon === 'messages') {
graphic = <Icon display='inline-block' verticalAlign='middle' icon='Users' mr='2' size='18px' color={iconFill} />;
} else {
graphic = <Icon display='inline-block' icon='NullIcon' verticalAlign="middle" mr='2' size="16px" color={iconFill} />;
}