Some more fixes
This commit is contained in:
parent
99fce5e395
commit
e6ec03acff
|
|
@ -101,15 +101,9 @@ const AvailabilityViewer = ({ times, people, table }: AvailabilityViewerProps) =
|
||||||
people: peopleHere,
|
people: peopleHere,
|
||||||
})
|
})
|
||||||
}}
|
}}
|
||||||
onMouseDown={e => {
|
onClick={() => {
|
||||||
setTooltip({
|
const clipboardMessage = `${t('group.clipboard_message', { date: cell.label })}:\n${peopleHere.join(', ')}`
|
||||||
anchor: e.currentTarget,
|
navigator.clipboard.writeText(clipboardMessage);
|
||||||
available: `${peopleHere.length} / ${filteredPeople.length} ${t('available')}`,
|
|
||||||
date: cell.label,
|
|
||||||
people: peopleHere,
|
|
||||||
})
|
|
||||||
let text2Clipboard = t("copy.message") + cell.label + ":\n" + peopleHere.join(';\n') + ";";
|
|
||||||
navigator.clipboard.writeText(text2Clipboard);
|
|
||||||
}}
|
}}
|
||||||
onMouseLeave={() => setTooltip(undefined)}
|
onMouseLeave={() => setTooltip(undefined)}
|
||||||
|
|
||||||
|
|
@ -141,7 +135,6 @@ const AvailabilityViewer = ({ times, people, table }: AvailabilityViewerProps) =
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<span className={styles.info}>{t('group.info1')}</span>
|
<span className={styles.info}>{t('group.info1')}</span>
|
||||||
<span className={styles.info}>{t('group.info3')}</span>
|
|
||||||
{people.length > 1 && <>
|
{people.length > 1 && <>
|
||||||
<span className={styles.info}>{t('group.info2')}</span>
|
<span className={styles.info}>{t('group.info2')}</span>
|
||||||
<div className={styles.people}>
|
<div className={styles.people}>
|
||||||
|
|
|
||||||
|
|
@ -48,15 +48,9 @@
|
||||||
|
|
||||||
"group": {
|
"group": {
|
||||||
"legend_tooltip": "Click to highlight highest availability",
|
"legend_tooltip": "Click to highlight highest availability",
|
||||||
"info1": "Hover or tap the calendar below to see who is available",
|
"info1": "Hover or tap the calendar below to see who is available, and click to copy details about a time slot",
|
||||||
"info2": "Click the names below to view people individually",
|
"info2": "Click the names below to view people individually",
|
||||||
"info3": "Click on a time slot to copy a list of people who are available then"
|
"clipboard_message": "People available on {{date}}"
|
||||||
|
|
||||||
},
|
|
||||||
|
|
||||||
"copy": {
|
|
||||||
"alert": "List of available people copied to clipboard!",
|
|
||||||
"message": "List of available people at "
|
|
||||||
},
|
},
|
||||||
|
|
||||||
"you": {
|
"you": {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue