feat(hubspot-integration): refine HubSpot widget styling and add account setup skip functionality

- Enhanced CSS targeting for HubSpot widget elements to prevent interference with the Worklenz app UI.
- Introduced a new function to allow users to bypass team member validation during account setup, improving user experience.
- Updated the button click handler to utilize the new skip functionality for a smoother setup process.
This commit is contained in:
chamikaJ
2025-07-28 16:12:12 +05:30
parent 76adb89caf
commit 2082934cd5
2 changed files with 19 additions and 5 deletions

View File

@@ -105,12 +105,21 @@ class HubSpotManager {
filter: invert(1) hue-rotate(180deg) !important;
}
/* Additional targeting for widget launcher and chat bubble */
div[class*="shadow-2xl"],
div[class*="widget-align"],
div[style*="position: fixed"] {
/* More specific targeting for HubSpot widget elements only - avoid affecting app UI */
div[class*="shadow-2xl"][class*="widget-align"]:not([class*="ant-"]),
div[style*="position: fixed"][id*="hubspot"]:not([class*="ant-"]),
div[style*="position: fixed"][class*="widget"]:not([class*="ant-"]) {
filter: invert(1) hue-rotate(180deg) !important;
}
/* Ensure Worklenz app elements are not affected by HubSpot styles */
.ant-menu,
.ant-menu *,
[class*="settings"],
[class*="sidebar"],
.worklenz-app *:not([id*="hubspot"]):not([class*="widget"]) {
filter: none !important;
}
`;
document.head.appendChild(style);
}

View File

@@ -214,6 +214,11 @@ const AccountSetup: React.FC = () => {
}
};
const handleSkipMembers = async () => {
// Bypass all validation and complete setup without team members
await completeAccountSetup(true);
};
const completeAccountSetupWithTemplate = async () => {
try {
await saveSurveyData(); // Save survey data first
@@ -592,7 +597,7 @@ const AccountSetup: React.FC = () => {
type="link"
className="p-0 font-medium"
style={{ color: token.colorTextTertiary }}
onClick={() => completeAccountSetup(true)}
onClick={handleSkipMembers}
>
{t('skipForNow')}
</Button>