Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add column name to related records #2264

Merged
merged 4 commits into from
Sep 17, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/components/BrowserCell/BrowserCell.react.js
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ export default class BrowserCell extends Component {
cl.forEach((column, field) => {
if (column.targetClass !== pointerClassName) { return; }
relatedRecordsMenuItem.items.push({
text: className, callback: () => {
text: `${className}`, subtext: `${field}`, callback: () => {
let relatedObject = value;
if (this.props.field === 'objectId') {
relatedObject = new Parse.Object(pointerClassName);
Expand Down
1 change: 1 addition & 0 deletions src/components/ContextMenu/ContextMenu.react.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ const MenuSection = ({ level, items, path, setPath, hide }) => {
}}
>
{item.text}
{item.subtext && <span> - {item.subtext}</span>}
</li>
);
})}
Expand Down
3 changes: 3 additions & 0 deletions src/components/ContextMenu/ContextMenu.scss
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
cursor: pointer;
white-space: nowrap;
padding: 0 30px 0 10px;
span {
color: #A2A6B1
}
}

li:hover {
Expand Down