Merge branch 'master' into statusbar-updates

pull/5370/head
Joseph Izang 5 months ago committed by GitHub
commit cbf5131c45
  1. 10
      apps/remix-ide/src/app.js
  2. 3
      apps/remix-ide/src/app/files/fileManager.ts
  3. 26
      apps/remix-ide/src/app/plugins/matomo.ts
  4. 3
      apps/remix-ide/src/remixAppManager.js

@ -56,6 +56,7 @@ import { xtermPlugin } from './app/plugins/electron/xtermPlugin'
import { ripgrepPlugin } from './app/plugins/electron/ripgrepPlugin' import { ripgrepPlugin } from './app/plugins/electron/ripgrepPlugin'
import { compilerLoaderPlugin, compilerLoaderPluginDesktop } from './app/plugins/electron/compilerLoaderPlugin' import { compilerLoaderPlugin, compilerLoaderPluginDesktop } from './app/plugins/electron/compilerLoaderPlugin'
import { GitPlugin } from './app/plugins/git' import { GitPlugin } from './app/plugins/git'
import { Matomo } from './app/plugins/matomo'
import {SolCoder} from './app/plugins/solcoderAI' import {SolCoder} from './app/plugins/solcoderAI'
@ -223,6 +224,9 @@ class AppComponent {
//---- git //---- git
const git = new GitPlugin() const git = new GitPlugin()
//---- matomo
const matomo = new Matomo()
//---------------- Solidity UML Generator ------------------------- //---------------- Solidity UML Generator -------------------------
const solidityumlgen = new SolidityUmlGen(appManager) const solidityumlgen = new SolidityUmlGen(appManager)
@ -357,7 +361,8 @@ class AppComponent {
templates, templates,
solcoder, solcoder,
git, git,
pluginStateLogger pluginStateLogger,
matomo
]) ])
//---- fs plugin //---- fs plugin
@ -476,7 +481,8 @@ class AppComponent {
'network', 'network',
'web3Provider', 'web3Provider',
'offsetToLineColumnConverter', 'offsetToLineColumnConverter',
'pluginStateLogger' 'pluginStateLogger',
'matomo'
]) ])
await this.appManager.activatePlugin(['mainPanel', 'menuicons', 'tabs']) await this.appManager.activatePlugin(['mainPanel', 'menuicons', 'tabs'])
await this.appManager.activatePlugin(['statusBar']) await this.appManager.activatePlugin(['statusBar'])

@ -25,7 +25,8 @@ const profile = {
methods: ['closeAllFiles', 'closeFile', 'file', 'exists', 'open', 'writeFile', 'writeMultipleFiles', 'writeFileNoRewrite', methods: ['closeAllFiles', 'closeFile', 'file', 'exists', 'open', 'writeFile', 'writeMultipleFiles', 'writeFileNoRewrite',
'readFile', 'copyFile', 'copyDir', 'rename', 'mkdir', 'readdir', 'dirList', 'fileList', 'remove', 'getCurrentFile', 'getFile', 'readFile', 'copyFile', 'copyDir', 'rename', 'mkdir', 'readdir', 'dirList', 'fileList', 'remove', 'getCurrentFile', 'getFile',
'getFolder', 'setFile', 'switchFile', 'refresh', 'getProviderOf', 'getProviderByName', 'getPathFromUrl', 'getUrlFromPath', 'getFolder', 'setFile', 'switchFile', 'refresh', 'getProviderOf', 'getProviderByName', 'getPathFromUrl', 'getUrlFromPath',
'saveCurrentFile', 'setBatchFiles', 'isGitRepo', 'isFile', 'isDirectory', 'hasGitSubmodule', 'copyFolderToJson', 'diff' 'saveCurrentFile', 'setBatchFiles', 'isGitRepo', 'isFile', 'isDirectory', 'hasGitSubmodule', 'copyFolderToJson', 'diff',
'hasGitSubmodules'
], ],
kind: 'file-system' kind: 'file-system'
} }

@ -0,0 +1,26 @@
'use strict'
import { Plugin } from '@remixproject/engine'
const _paq = window._paq = window._paq || []
const profile = {
name: 'matomo',
description: 'send analytics to Matomo',
methods: ['track'],
events: [''],
version: '1.0.0'
}
const allowedPlugins = ['LearnEth', 'etherscan', 'vyper', 'circuit-compiler', 'doc-gen', 'doc-viewer', 'solhint', 'walletconnect', 'scriptRunner']
export class Matomo extends Plugin {
constructor() {
super(profile)
}
async track(data: string[]) {
if (!allowedPlugins.includes(this.currentRequest.from)) return
_paq.push(data)
}
}

@ -81,7 +81,8 @@ let requiredModules = [ // services + layout views + system views
'dgit', 'dgit',
'pinnedPanel', 'pinnedPanel',
'pluginStateLogger', 'pluginStateLogger',
'remixGuide' 'remixGuide',
'matomo'
] ]

Loading…
Cancel
Save