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(docs): act-1490 - added getfeedback widget #1588

Merged
merged 3 commits into from
Sep 30, 2024
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
3 changes: 3 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,14 @@ on:
required: true
SENTRY_KEY:
required: true
GF_SURVEY_KEY:
required: true

env:
SEGMENT_ANALYTICS_KEY: ${{ secrets.SEGMENT_ANALYTICS_KEY }}
LD_CLIENT_ID: ${{ secrets.LD_CLIENT_ID }}
SENTRY_KEY: ${{ secrets.SENTRY_KEY }}
GF_SURVEY_KEY: ${{ secrets.GF_SURVEY_KEY }}

jobs:
build:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/case.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,14 @@ on:
required: true
SENTRY_KEY:
required: true
GF_SURVEY_KEY:
required: true

env:
SEGMENT_ANALYTICS_KEY: ${{ secrets.SEGMENT_ANALYTICS_KEY }}
LD_CLIENT_ID: ${{ secrets.LD_CLIENT_ID }}
SENTRY_KEY: ${{ secrets.SENTRY_KEY }}
GF_SURVEY_KEY: ${{ secrets.GF_SURVEY_KEY }}

jobs:
case:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,14 @@ on:
required: true
SENTRY_KEY:
required: true
GF_SURVEY_KEY:
required: true

env:
SEGMENT_ANALYTICS_KEY: ${{ secrets.SEGMENT_ANALYTICS_KEY }}
LD_CLIENT_ID: ${{ secrets.LD_CLIENT_ID }}
SENTRY_KEY: ${{ secrets.SENTRY_KEY }}
GF_SURVEY_KEY: ${{ secrets.GF_SURVEY_KEY }}

jobs:
lint:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ jobs:
SEGMENT_ANALYTICS_KEY: ${{ secrets.SEGMENT_ANALYTICS_DEV_KEY }}
LD_CLIENT_ID: ${{ secrets.LD_CLIENT_ID }}
SENTRY_KEY: ${{ secrets.SENTRY_KEY }}
GF_SURVEY_KEY: ${{ secrets.GF_SURVEY_KEY }}

lint:
name: Lint
Expand All @@ -34,6 +35,7 @@ jobs:
SEGMENT_ANALYTICS_KEY: ${{ secrets.SEGMENT_ANALYTICS_DEV_KEY }}
LD_CLIENT_ID: ${{ secrets.LD_CLIENT_ID }}
SENTRY_KEY: ${{ secrets.SENTRY_KEY }}
GF_SURVEY_KEY: ${{ secrets.GF_SURVEY_KEY }}

case:
name: Case
Expand All @@ -42,6 +44,7 @@ jobs:
SEGMENT_ANALYTICS_KEY: ${{ secrets.SEGMENT_ANALYTICS_DEV_KEY }}
LD_CLIENT_ID: ${{ secrets.LD_CLIENT_ID }}
SENTRY_KEY: ${{ secrets.SENTRY_KEY }}
GF_SURVEY_KEY: ${{ secrets.GF_SURVEY_KEY }}

all-jobs-completed:
name: All jobs completed
Expand Down
1 change: 1 addition & 0 deletions docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ const config = {
VERCEL_ENV: process.env.VERCEL_ENV,
DASHBOARD_PREVIEW_URL: process.env.DASHBOARD_PREVIEW_URL,
SENTRY_KEY: process.env.SENTRY_KEY,
GF_SURVEY_KEY: process.env.GF_SURVEY_KEY,
},

trailingSlash: true,
Expand Down
4 changes: 4 additions & 0 deletions src/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,10 @@ svg {
margin-bottom: -2rem;
}

.usabilla_live_button_container {
display: none !important;
}

.getfeedback-hidden {
display: none !important;
}
Expand Down
6 changes: 6 additions & 0 deletions src/theme/Root.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import React, {
import { Provider as AlertProvider } from "react-alert";
import useDocusaurusContext from "@docusaurus/useDocusaurusContext";
import BrowserOnly from "@docusaurus/BrowserOnly";
import siteConfig from "@generated/docusaurus.config";
import { AlertTemplate, options } from "@site/src/components/Alert";
import { MetaMaskSDK, SDKProvider } from "@metamask/sdk";
import {
Expand Down Expand Up @@ -129,9 +130,14 @@ export const LoginProvider = ({ children }) => {
} catch (e) {}
};

const { GF_SURVEY_KEY } = siteConfig.customFields;

useEffect(() => {
const provider = sdk?.getProvider();
setMetaMaskProvider(provider);
if ((window as any)?.usabilla && window?.innerWidth > 1720) {
(window as any)?.usabilla?.load("w.usabilla.com", GF_SURVEY_KEY);
}
}, []);

useEffect(() => {
Expand Down
Loading