-export const DialogProjectUpdate = (props: DialogProjectProps) =>
- <FormDialog
- dialogTitle='Edit Project'
- formFields={ProjectEditFields}
+const styles: StyleRulesCallback<CssRules> = theme => ({
+ propertiesForm: {
+ marginTop: theme.spacing.unit * 2,
+ marginBottom: theme.spacing.unit * 2,
+ },
+ description: {
+ marginTop: theme.spacing.unit * 2,
+ marginBottom: theme.spacing.unit * 2,
+ },
+});
+
+type DialogProjectProps = WithDialogProps<{sourcePanel: GroupClass}> & InjectedFormProps<ProjectUpdateFormDialogData>;
+
+export const DialogProjectUpdate = (props: DialogProjectProps) => {
+ let title = 'Edit Project';
+ const sourcePanel = props.data.sourcePanel || '';
+
+ if (sourcePanel === GroupClass.ROLE) {
+ title = 'Edit Group';
+ }
+
+ return <FormDialog
+ dialogTitle={title}
+ formFields={ProjectEditFields as any}