diff --git a/src/components/base/SideBar/SideBarListItem.js b/src/components/base/SideBar/SideBarListItem.js index cc5e508b..1374d1c1 100644 --- a/src/components/base/SideBar/SideBarListItem.js +++ b/src/components/base/SideBar/SideBarListItem.js @@ -31,7 +31,6 @@ class SideBarListItem extends PureComponent { } = this.props return ( { return String(o) } -const logClicks = !__DEV__ || process.env.DEBUG_CLICK_ELEMENT const logRedux = !__DEV__ || process.env.DEBUG_ACTION const logTabkey = __DEV__ || process.env.DEBUG_TAB_KEY export default { - // tracks the user interactions (click, input focus/blur, what else?) - - onClickElement: (role: string, roleData: ?Object) => { - const label = `👆 ${role}` - if (roleData) { - if (logClicks) { - console.log(label, roleData) - } - addLog('click', label, roleData) - } else { - if (logClicks) { - console.log(label) - } - addLog('click', label, roleData) - } - }, - // tracks Redux actions (NB not all actions are serializable) onReduxAction: (action: Object) => { diff --git a/src/renderer/init.js b/src/renderer/init.js index 1806aff1..2afa5483 100644 --- a/src/renderer/init.js +++ b/src/renderer/init.js @@ -85,34 +85,12 @@ async function init() { const libcoreVersion = await libcoreGetVersion.send().toPromise() logger.log('libcore', libcoreVersion) - // DOM elements can have a data-role that identify the UI entity - // and that allow us to track interactions with this. - window.addEventListener('click', ({ target }) => { - const { dataset } = target - if (dataset) { - const { role, roledata } = dataset - if (role) { - logger.onClickElement(role, roledata) - } - } - }) - window.addEventListener('keydown', (e: SyntheticKeyboardEvent) => { if (e.which === TAB_KEY) { if (!isGlobalTabEnabled()) enableGlobalTab() logger.onTabKey(document.activeElement) } }) - - window.addEventListener('click', ({ target }) => { - const { dataset } = target - if (dataset) { - const { role, roledata } = dataset - if (role) { - logger.onClickElement(role, roledata) - } - } - }) } }