diff options
| author | anika-ahluwalia <anika.ahluwalia@gmail.com> | 2020-08-02 18:20:59 -0500 |
|---|---|---|
| committer | anika-ahluwalia <anika.ahluwalia@gmail.com> | 2020-08-02 18:20:59 -0500 |
| commit | ac177d7b9a01075fbf1ad1c327c7625d95569afb (patch) | |
| tree | ea89bf577df1afa960109f2b741dee3faec450c5 /src/client/views/collections/collectionFreeForm | |
| parent | f818303cb164b471805075226cba5451f35b27a2 (diff) | |
bug fixes found with sally
Diffstat (limited to 'src/client/views/collections/collectionFreeForm')
| -rw-r--r-- | src/client/views/collections/collectionFreeForm/PropertiesView.scss | 24 | ||||
| -rw-r--r-- | src/client/views/collections/collectionFreeForm/PropertiesView.tsx | 33 |
2 files changed, 39 insertions, 18 deletions
diff --git a/src/client/views/collections/collectionFreeForm/PropertiesView.scss b/src/client/views/collections/collectionFreeForm/PropertiesView.scss index a96716659..7df56115f 100644 --- a/src/client/views/collections/collectionFreeForm/PropertiesView.scss +++ b/src/client/views/collections/collectionFreeForm/PropertiesView.scss @@ -60,6 +60,10 @@ padding-left: 8px; background-color: rgb(51, 51, 51); + &:hover { + cursor: pointer; + } + .propertiesView-settings-title-icon { float: right; right: 0; @@ -94,6 +98,10 @@ padding-left: 8px; background-color: rgb(51, 51, 51); + &:hover { + cursor: pointer; + } + .propertiesView-sharing-title-icon { float: right; right: 0; @@ -127,6 +135,10 @@ padding-left: 8px; background-color: rgb(51, 51, 51); + &:hover { + cursor: pointer; + } + .propertiesView-appearance-title-icon { float: right; right: 0; @@ -160,6 +172,10 @@ padding-left: 8px; background-color: rgb(51, 51, 51); + &:hover { + cursor: pointer; + } + .propertiesView-transform-title-icon { float: right; right: 0; @@ -287,6 +303,10 @@ padding-left: 8px; background-color: rgb(51, 51, 51); + &:hover { + cursor: pointer; + } + .propertiesView-fields-title-name { font-size: 12.5px; font-weight: bold; @@ -362,6 +382,10 @@ padding-left: 8px; background-color: rgb(51, 51, 51); + &:hover { + cursor: pointer; + } + .propertiesView-layout-title-icon { float: right; right: 0; diff --git a/src/client/views/collections/collectionFreeForm/PropertiesView.tsx b/src/client/views/collections/collectionFreeForm/PropertiesView.tsx index 73f0f1bdd..0168c825f 100644 --- a/src/client/views/collections/collectionFreeForm/PropertiesView.tsx +++ b/src/client/views/collections/collectionFreeForm/PropertiesView.tsx @@ -205,7 +205,7 @@ export class PropertiesView extends React.Component<PropertiesViewProps> { } } - + @undoBatch setKeyValue = (value: string) => { if (this.selectedDoc && this.dataDoc) { const doc = this.layoutFields ? Doc.Layout(this.selectedDoc) : this.dataDoc; @@ -266,9 +266,14 @@ export class PropertiesView extends React.Component<PropertiesViewProps> { } } + @undoBatch + changePermissions = (e: any, user: string) => { + SharingManager.Instance.shareFromPropertiesSidebar(user, e.currentTarget.value as SharingPermissions, this.selectedDoc!); + } + getPermissionsSelect(user: string) { return <select className="permissions-select" - onChange={e => SharingManager.Instance.shareFromPropertiesSidebar(user, e.currentTarget.value as SharingPermissions, this.selectedDoc!)}> + onChange={e => this.changePermissions(e, user)}> {Object.values(SharingPermissions).map(permission => { return ( <option key={permission} value={permission} selected={this.selectedDoc![`ACL-${user.replace(".", "_")}`] === permission}> @@ -344,6 +349,7 @@ export class PropertiesView extends React.Component<PropertiesViewProps> { />; } + @undoBatch @action toggleCheckbox = () => { this.layoutFields = !this.layoutFields; @@ -359,6 +365,7 @@ export class PropertiesView extends React.Component<PropertiesViewProps> { SetValue={this.setTitle} />; } + @undoBatch @action setTitle = (value: string) => { if (this.dataDoc) { @@ -370,13 +377,6 @@ export class PropertiesView extends React.Component<PropertiesViewProps> { } - - - - - - - @undoBatch @action rotate = (angle: number) => { @@ -739,9 +739,13 @@ export class PropertiesView extends React.Component<PropertiesViewProps> { if (!this.selectedDoc) { return <div className="propertiesView" style={{ width: this.props.width }}> - <div className="propertiesView-title" style={{ width: this.props.width, paddingLeft: 6 }}> + <div className="propertiesView-title" style={{ width: this.props.width }}> No Document Selected - </div> </div>; + <div className="propertiesView-title-icon" onPointerDown={this.props.onDown}> + <FontAwesomeIcon icon="times" color="black" size="xs" /> + </div> + </div> + </div>; } const novice = Doc.UserDoc().noviceMode; @@ -783,9 +787,6 @@ export class PropertiesView extends React.Component<PropertiesViewProps> { </div> : null} </div> - - - {this.isInk ? <div className="propertiesView-appearance"> <div className="propertiesView-appearance-title" onPointerDown={() => runInAction(() => { this.openAppearance = !this.openAppearance; })} @@ -814,10 +815,6 @@ export class PropertiesView extends React.Component<PropertiesViewProps> { </div> : null} </div> : null} - - - - <div className="propertiesView-fields"> <div className="propertiesView-fields-title" onPointerDown={() => runInAction(() => { this.openFields = !this.openFields; })} |
