[ARVADOS-WORKBENCH2] updated: 1.2.0-762-gf2997d7

Git user git at public.curoverse.com
Tue Oct 30 08:35:04 EDT 2018


Summary of changes:
 .../sharing-dialog/people-select.tsx                 | 20 +++++++++++---------
 .../sharing-invitation-form-component.tsx            |  1 -
 2 files changed, 11 insertions(+), 10 deletions(-)

       via  f2997d75147187ccf0bc29d61e2af5a375a23e61 (commit)
      from  986ff42ab49d2fd9a2da53fcc0f08a7933719b64 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit f2997d75147187ccf0bc29d61e2af5a375a23e61
Author: Michal Klobukowski <michal.klobukowski at contractors.roche.com>
Date:   Tue Oct 30 13:34:50 2018 +0100

    Improve people select styles and behaviour
    
    Feature #14365
    
    Arvados-DCO-1.1-Signed-off-by: Michal Klobukowski <michal.klobukowski at contractors.roche.com>

diff --git a/src/views-components/sharing-dialog/people-select.tsx b/src/views-components/sharing-dialog/people-select.tsx
index f49d171..2aada00 100644
--- a/src/views-components/sharing-dialog/people-select.tsx
+++ b/src/views-components/sharing-dialog/people-select.tsx
@@ -9,7 +9,7 @@ import { connect, DispatchProp } from 'react-redux';
 import { ServiceRepository } from '~/services/services';
 import { FilterBuilder } from '../../services/api/filter-builder';
 import { debounce } from 'debounce';
-import { ListItemText } from '@material-ui/core';
+import { ListItemText, Typography } from '@material-ui/core';
 import { noop } from 'lodash/fp';
 
 export interface Person {
@@ -67,7 +67,7 @@ export const PeopleSelect = connect()(
         renderSuggestion({ firstName, lastName, email }: UserResource) {
             return (
                 <ListItemText>
-                    {`${firstName} ${lastName} <<${email}>>`}
+                    <Typography noWrap>{`${firstName} ${lastName} <<${email}>>`}</Typography>
                 </ListItemText>
             );
         }
@@ -78,13 +78,15 @@ export const PeopleSelect = connect()(
         }
 
         handleCreate = () => {
-            const { onCreate = noop } = this.props;
-            this.setState({ value: '', suggestions: [] });
-            onCreate({
-                email: '',
-                name: '',
-                uuid: this.state.value,
-            });
+            const { onCreate } = this.props;
+            if (onCreate) {
+                this.setState({ value: '', suggestions: [] });
+                onCreate({
+                    email: '',
+                    name: '',
+                    uuid: this.state.value,
+                });
+            }
         }
 
         handleSelect = ({ email, firstName, lastName, uuid }: UserResource) => {
diff --git a/src/views-components/sharing-dialog/sharing-invitation-form-component.tsx b/src/views-components/sharing-dialog/sharing-invitation-form-component.tsx
index eafa480..5aec8fe 100644
--- a/src/views-components/sharing-dialog/sharing-invitation-form-component.tsx
+++ b/src/views-components/sharing-dialog/sharing-invitation-form-component.tsx
@@ -27,7 +27,6 @@ const InvitedPeopleField = () =>
 const InvitedPeopleFieldComponent = ({ fields }: WrappedFieldArrayProps<Person>) =>
     <PeopleSelect
         items={fields.getAll() || []}
-        onCreate={fields.push}
         onSelect={fields.push}
         onDelete={fields.remove} />;
 

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list