Updating with a suggestion from Andrew kingston, adding row/rows to sentences about one->many relationships so that singular/plural english makes sense.

This commit is contained in:
mike12345567 2021-03-02 11:10:26 +00:00
parent a353d22068
commit 2975ed39e0
1 changed files with 8 additions and 9 deletions

View File

@ -158,19 +158,19 @@
if (!linkTable) { if (!linkTable) {
return null return null
} }
const thisName = truncate(table.name, { length: 20 }), const thisName = truncate(table.name, { length: 15 }),
linkName = truncate(linkTable.name, { length: 20 }) linkName = truncate(linkTable.name, { length: 15 })
return [ return [
{ {
name: `Many ${thisName} has many ${linkName}`, name: `Many ${thisName} rows has many ${linkName} rows`,
value: RelationshipTypes.MANY_TO_MANY, value: RelationshipTypes.MANY_TO_MANY,
}, },
{ {
name: `One ${thisName} has many ${linkName}`, name: `One ${thisName} row has many ${linkName} rows`,
value: RelationshipTypes.ONE_TO_MANY, value: RelationshipTypes.ONE_TO_MANY,
}, },
{ {
name: `Many ${thisName} has one ${linkName}`, name: `Many ${thisName} rows has one ${linkName} row`,
value: RelationshipTypes.MANY_TO_ONE, value: RelationshipTypes.MANY_TO_ONE,
}, },
] ]
@ -339,15 +339,14 @@
.rel-type-center { .rel-type-center {
font-weight: 500; font-weight: 500;
color: var(--grey-6); color: var(--grey-6);
margin-right: 8px; margin-right: 6px;
margin-left: 8px; margin-left: 6px;
padding: 1px 3px 1px 3px; padding: 1px 3px 1px 3px;
background: var(--grey-3); background: var(--grey-3);
border-radius: 2px; border-radius: 2px;
} }
.radio-button-labels { .radio-button-labels {
display: flex; margin-top: 2px;
align-items: center;
} }
</style> </style>