-
Notifications
You must be signed in to change notification settings - Fork 679
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Significant changes to use ReactJS extensively.
1. Replace the current layout library wcDocker with ReactJS based rc-dock. #6479 2. Have close buttons on individual panel tabs instead of common. #2821 3. Changes in the context menu on panel tabs - Add close, close all and close others menu items. #5394 4. Allow closing all the tabs, including SQL and Properties. #4733 5. Changes in docking behaviour of different tabs based on user requests and remove lock layout menu. 6. Fix an issue where the scroll position of panels was not remembered on Firefox. #2986 7. Reset layout now will not require page refresh and is done spontaneously. 8. Use the zustand store for storing preferences instead of plain JS objects. This will help reflecting preferences immediately. 9. The above fix incorrect format (no indent) of SQL stored functions/procedures. #6720 10. New version check is moved to an async request now instead of app start to improve startup performance. 11. Remove jQuery and Bootstrap completely. 12. Replace jasmine and karma test runner with jest. Migrate all the JS test cases to jest. This will save time in writing and debugging JS tests. 13. Other important code improvements and cleanup.
- Loading branch information
1 parent
6d55564
commit 862f101
Showing
373 changed files
with
11,155 additions
and
14,842 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -36,4 +36,4 @@ jobs: | |
- name: Run the tests | ||
run: | | ||
cd web | ||
yarn run test:karma-once | ||
yarn run test:js-once |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"presets": [["@babel/preset-env", {"modules": "commonjs", "useBuiltIns": "usage", "corejs": 3}], "@babel/preset-react", "@babel/preset-typescript"], | ||
"plugins": ["@babel/plugin-proposal-class-properties", "@babel/proposal-object-rest-spread", "@babel/plugin-transform-runtime"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
const webpackShimAlias = require('./webpack.shim').resolveAlias; | ||
|
||
const webpackAliasToJestModules = ()=>{ | ||
const ret = { | ||
'\\.svg': '<rootDir>/regression/javascript/__mocks__/svg.js' | ||
}; | ||
Object.keys(webpackShimAlias).forEach((an)=>{ | ||
// eg - sources: ./pgadmin/static/js/ to '^sources/(.*)$': '<rootDir>/pgadmin/static/js/$1' | ||
let ap = webpackShimAlias[an].replace(__dirname, '<rootDir>'); | ||
if(ap.endsWith('/')) { | ||
ret[`^${an}/(.*)$`] = ap + '$1'; | ||
return; | ||
} | ||
ret[`^${an}$`] = ap; | ||
}); | ||
|
||
// Overrides | ||
ret['^translations$'] = '<rootDir>/regression/javascript/fake_translations'; | ||
ret['^pgadmin.browser.messages$'] = '<rootDir>/regression/javascript/fake_messages'; | ||
ret['^pgadmin.browser.endpoints$'] = '<rootDir>/regression/javascript/fake_endpoints'; | ||
ret['^pgadmin.browser.translations$'] = '<rootDir>/regression/javascript/fake_translations'; | ||
ret['^pgadmin.user_management.current_user$'] = '<rootDir>/regression/javascript/fake_current_user'; | ||
ret['^pgadmin.server.supported_servers$'] = '<rootDir>/regression/javascript/fake_supported_servers'; | ||
|
||
const sources = ret['^sources/(.*)$']; | ||
delete ret['^sources/(.*)$']; | ||
|
||
ret['^sources/pgadmin$'] = '<rootDir>/regression/javascript/fake_pgadmin'; | ||
ret['^sources/gettext$'] = '<rootDir>/regression/javascript/fake_gettext'; | ||
ret['^sources/(.*)$'] = sources; | ||
|
||
// Only for tests | ||
ret['^pgadmin.schema.dir/(.*)$'] = '<rootDir>/pgadmin/browser/server_groups/servers/databases/schemas/static/js/$1'; | ||
ret['^browser/(.*)$'] = '<rootDir>/pgadmin/browser/static/js/$1'; | ||
|
||
return ret; | ||
}; | ||
|
||
module.exports = { | ||
'roots': ['<rootDir>/pgadmin/', '<rootDir>/regression/javascript'], | ||
'moduleFileExtensions': ['js', 'jsx', 'ts', 'tsx'], | ||
'moduleNameMapper': webpackAliasToJestModules(), | ||
'transform': { | ||
'^.+\\.(js|jsx|mjs|cjs|ts|tsx)$': 'babel-jest', | ||
}, | ||
'setupFilesAfterEnv': [ | ||
'<rootDir>/regression/javascript/setup-jest.js', | ||
], | ||
'testMatch': [ | ||
'<rootDir>/regression/javascript/**/*{spec,test}.{js,jsx,ts,tsx}' | ||
], | ||
'testEnvironment': 'jsdom', | ||
'transformIgnorePatterns': [ | ||
'[/\\\\]node_modules[/\\\\](?!react-dnd|dnd-core|@react-dnd).+\\.(js|jsx|mjs|cjs|ts|tsx)$', | ||
'^.+\\.module\\.(css|sass|scss)$' | ||
] | ||
}; |
Oops, something went wrong.