pull/5051/head
bunsenstraat 4 months ago
parent 9633a7047b
commit d45d89cd09
  1. 2
      libs/remix-ui/git/src/components/gitui.tsx
  2. 2
      libs/remix-ui/git/src/lib/listeners.ts
  3. 92
      libs/remix-ui/git/src/types/index.ts

@ -121,7 +121,7 @@ export const GitUI = (props: IGitUi) => {
useEffect(() => {
const panelName = Object.keys(gitUIPanels)
.filter(k => gitUIPanels[k] === activePanel);
if(!(panelName && panelName[0])) return
if (!(panelName && panelName[0])) return
sendToMatomo(gitMatomoEventTypes.OPENPANEL, [panelName && panelName[0]])
}, [activePanel])

@ -163,7 +163,7 @@ export const setCallBacks = (viewPlugin: Plugin, gitDispatcher: React.Dispatch<g
})
plugin.on('dgit' as any, 'openPanel', async (panel: string) => {
setAtivePanel(panel)
})

@ -143,8 +143,8 @@ export interface repositoriesInput { token: string, page?: number, per_page?: nu
export interface statusInput { ref: string, filepaths?: string[] }
export const dGitProfile: LibraryProfile<IGitApi> = {
name: 'dgitApi',
methods: ['clone', 'branches', 'remotes', 'getCommitChanges', 'log', 'remotecommits'],
name: 'dgitApi',
methods: ['clone', 'branches', 'remotes', 'getCommitChanges', 'log', 'remotecommits'],
}
export interface customGitApi extends IRemixApi {
@ -266,53 +266,53 @@ export type remoteBranch = {
}
export const defaultGitState: gitState = {
currentBranch: { name: "", remote: { name: "", url: "" } },
currentHead: "",
commits: [],
branch: "",
canCommit: true,
branches: [],
remotes: [],
defaultRemote: null,
fileStatusResult: [],
staged: [],
untracked: [],
deleted: [],
modified: [],
allchangesnotstaged: [],
canUseApp: true,
loading: false,
storage: {
used: 0,
total: 0,
available: 0,
percentUsed: 0,
enabled: false
},
reponame: "",
repositories: [],
remoteBranches: [],
commitChanges: [],
remoteBranchCommits: {},
localBranchCommits: {},
branchDifferences: {},
syncStatus: syncStatus.none,
localCommitCount: 0,
remoteCommitCount: 0,
upstream: null,
gitHubUser: {} as GitHubUser,
userEmails: [] as userEmails,
gitHubScopes: [],
gitHubAccessToken: "",
log: []
currentBranch: { name: "", remote: { name: "", url: "" } },
currentHead: "",
commits: [],
branch: "",
canCommit: true,
branches: [],
remotes: [],
defaultRemote: null,
fileStatusResult: [],
staged: [],
untracked: [],
deleted: [],
modified: [],
allchangesnotstaged: [],
canUseApp: true,
loading: false,
storage: {
used: 0,
total: 0,
available: 0,
percentUsed: 0,
enabled: false
},
reponame: "",
repositories: [],
remoteBranches: [],
commitChanges: [],
remoteBranchCommits: {},
localBranchCommits: {},
branchDifferences: {},
syncStatus: syncStatus.none,
localCommitCount: 0,
remoteCommitCount: 0,
upstream: null,
gitHubUser: {} as GitHubUser,
userEmails: [] as userEmails,
gitHubScopes: [],
gitHubAccessToken: "",
log: []
}
export const defaultLoaderState: loaderState = {
branches: false,
commits: false,
sourcecontrol: false,
remotes: false,
plugin: false
branches: false,
commits: false,
sourcecontrol: false,
remotes: false,
plugin: false
}
export type fileStatusResult = {

Loading…
Cancel
Save