Restore compact tracker action row and dedupe action widgets
This commit is contained in:
@@ -881,23 +881,23 @@ function ensureTrackerActionsContainer(container) {
|
|||||||
).filter((node) => node && node.parentElement && node.parentElement !== actionsContainer);
|
).filter((node) => node && node.parentElement && node.parentElement !== actionsContainer);
|
||||||
orphanActions.forEach((node) => actionsContainer.appendChild(node));
|
orphanActions.forEach((node) => actionsContainer.appendChild(node));
|
||||||
|
|
||||||
// Keep action row last so status/content remains on its own row.
|
const aiWrappers = Array.from(actionsContainer.querySelectorAll('.fb-tracker-ai-wrapper'));
|
||||||
if (actionsContainer.parentElement === container) {
|
aiWrappers.slice(1).forEach((duplicate) => duplicate.remove());
|
||||||
container.appendChild(actionsContainer);
|
|
||||||
}
|
const webAppLinks = Array.from(actionsContainer.querySelectorAll('.fb-tracker-webapp-link'));
|
||||||
|
webAppLinks.slice(1).forEach((duplicate) => duplicate.remove());
|
||||||
|
|
||||||
actionsContainer.style.cssText = `
|
actionsContainer.style.cssText = `
|
||||||
margin-left: 0;
|
margin-left: auto;
|
||||||
margin-top: 4px;
|
margin-top: 0;
|
||||||
display: flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: flex-start;
|
justify-content: flex-end;
|
||||||
gap: 8px;
|
gap: 8px;
|
||||||
flex-wrap: wrap;
|
flex-wrap: nowrap;
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
width: 100%;
|
|
||||||
max-width: 100%;
|
max-width: 100%;
|
||||||
flex: 0 0 100%;
|
flex: 0 1 auto;
|
||||||
`;
|
`;
|
||||||
|
|
||||||
return actionsContainer;
|
return actionsContainer;
|
||||||
|
|||||||
Reference in New Issue
Block a user