Skip to content

Commit

Permalink
Replaced help button (#1544)
Browse files Browse the repository at this point in the history
* Replaced help button

* Removed Help Beacon from codebase

* additional vercel configuration to prevent minification

* widget through app

* widget through app 2

* trying widgetloader

* trying widgetloader fixed string

* hosted widget loader

* cleaned up code
  • Loading branch information
WissenIstNacht authored Feb 24, 2021
1 parent 477f2c8 commit 1f16b0f
Show file tree
Hide file tree
Showing 15 changed files with 50 additions and 969 deletions.
3 changes: 0 additions & 3 deletions src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ import { PermissionsProvider } from './contexts/PermissionsContext'
import { IdentityProvider } from './components/IdentityManager/IdentityManager'
import { LocalIdentityModalProvider } from './components/LocalIdentityModal/LocalIdentityModalManager'
import LocalIdentityModal from './components/LocalIdentityModal/LocalIdentityModal'
import HelpScoutBeacon from './components/HelpScoutBeacon/HelpScoutBeacon'
import GlobalPreferences from './components/GlobalPreferences/GlobalPreferences'
import CustomToast from './components/CustomToast/CustomToast'
import OrgView from './components/OrgView/OrgView'
Expand Down Expand Up @@ -402,8 +401,6 @@ class App extends React.Component {
apps={appsWithIdentifiers}
wrapper={wrapper}
/>

<HelpScoutBeacon apps={apps} />
</ActivityProvider>
</FavoriteDaosProvider>
</LocalIdentityModalProvider>
Expand Down
3 changes: 0 additions & 3 deletions src/components/CustomToast/CustomToast.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
import React from 'react'
import PropTypes from 'prop-types'
import { GU, ToastHub, useViewport } from '@aragon/ui'
import { useHelpScout } from '../HelpScoutBeacon/useHelpScout'

const TIMEOUT_TOAST = 4000

function CustomToast({ children }) {
const { below } = useViewport()
const { optedOut } = useHelpScout()
return (
<ToastHub
shift={optedOut ? 0 : below('medium') ? 5.5 * GU : 6.5 * GU}
timeout={TIMEOUT_TOAST}
>
{children}
Expand Down
2 changes: 0 additions & 2 deletions src/components/Error/ErrorScreen.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import React from 'react'
import PropTypes from 'prop-types'
import { Card, GU, useTheme, useViewport } from '@aragon/ui'
import HelpScoutBeacon from '../HelpScoutBeacon/HelpScoutBeacon'
import HomeButton from '../HomeButton/HomeButton'

import eagleSvg from '../../assets/eagle.svg'
Expand Down Expand Up @@ -57,7 +56,6 @@ function ErrorScreen({ children }) {
{children}
</Container>
</div>
<HelpScoutBeacon apps={[]} />
</div>
)
}
Expand Down
6 changes: 1 addition & 5 deletions src/components/GlobalPreferences/GlobalPreferences.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,23 +20,20 @@ import { useRouting } from '../../routing'
import Network from './Network/Network'
import Notifications from './Notifications/Notifications'
import CustomLabels from './CustomLabels/CustomLabels'
import HelpAndFeedback from './HelpAndFeedback/HelpAndFeedback'
import SharedIdentities from './SharedIdentities/SharedIdentities'
import useSharedLink from './SharedIdentities/useSharedLink'

const SECTIONS = new Map([
['custom-labels', 'Custom Labels'],
['network', 'Network'],
['notifications', 'Notifications'],
['help-and-feedback', 'Help and feedback'],
['notifications', 'Notifications']
])
const SECTION_PATHS = Array.from(SECTIONS.keys())
const SECTION_VALUES = Array.from(SECTIONS.values())

const CUSTOM_LABELS_INDEX = 0
const NETWORK_INDEX = 1
const NOTIFICATIONS_INDEX = 2
const HELP_AND_FEEDBACK_INDEX = 3

const AnimatedDiv = animated.div

Expand Down Expand Up @@ -136,7 +133,6 @@ function GlobalPreferencesContent({
navigationIndex={2}
/>
)}
{sectionIndex === HELP_AND_FEEDBACK_INDEX && <HelpAndFeedback />}
</main>
</React.Fragment>
)}
Expand Down
136 changes: 0 additions & 136 deletions src/components/GlobalPreferences/HelpAndFeedback/HelpAndFeedback.js

This file was deleted.

Binary file not shown.
68 changes: 0 additions & 68 deletions src/components/HelpScoutBeacon/BeaconHeadScripts.js

This file was deleted.

Loading

0 comments on commit 1f16b0f

Please sign in to comment.