@bigbinary/neeto-github-frontend 2.2.2 → 2.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -0
- package/package.json +53 -51
- package/dist/NeetoGithubNanoContainer.js +0 -25
- package/dist/NeetoGithubNanoContainer.js.map +0 -1
- package/dist/NeetoGithubNanoPane.js +0 -105
- package/dist/NeetoGithubNanoPane.js.map +0 -1
- package/dist/cjs/NeetoGithubNanoContainer.js +0 -31
- package/dist/cjs/NeetoGithubNanoContainer.js.map +0 -1
- package/dist/cjs/NeetoGithubNanoPane.js +0 -126
- package/dist/cjs/NeetoGithubNanoPane.js.map +0 -1
- package/dist/cjs/index.js +0 -35
- package/dist/cjs/index.js.map +0 -1
- package/dist/index-C71Qp9QM.js +0 -483
- package/dist/index-C71Qp9QM.js.map +0 -1
- package/dist/index-DelA1uHU.js +0 -487
- package/dist/index-DelA1uHU.js.map +0 -1
- package/dist/index.js +0 -28
- package/dist/index.js.map +0 -1
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## 1.0.2
|
|
4
|
+
|
|
5
|
+
- Changed column name for repository table.
|
|
6
|
+
- Updated Redirect URI logic. Host application can skip redirect route.
|
|
7
|
+
- Security: **BREAKING** Used [JWT](https://github.com/jwt/ruby-jwt) to transfer data securely to GitHub OAuth. (#17)
|
|
8
|
+
|
|
9
|
+
Note: A Private-Public key pair is required to be stored in the environment variables from this release. Please refer [here](https://github.com/bigbinary/neeto-github-integration-engine#add-jwt-private-and-public-keys) for instructions.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bigbinary/neeto-github-frontend",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.4",
|
|
4
4
|
"repository": "neeto-github-nano",
|
|
5
5
|
"author": "BigBinary",
|
|
6
6
|
"files": [
|
|
@@ -46,67 +46,68 @@
|
|
|
46
46
|
}
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
|
-
"@babel/core": "
|
|
50
|
-
"@babel/eslint-parser": "7.
|
|
51
|
-
"@babel/plugin-transform-runtime": "
|
|
52
|
-
"@babel/preset-env": "7.
|
|
53
|
-
"@babel/preset-react": "7.
|
|
54
|
-
"@babel/preset-typescript": "
|
|
55
|
-
"@babel/runtime": "7.
|
|
49
|
+
"@babel/core": "7.26.0",
|
|
50
|
+
"@babel/eslint-parser": "7.25.9",
|
|
51
|
+
"@babel/plugin-transform-runtime": "7.25.9",
|
|
52
|
+
"@babel/preset-env": "7.26.0",
|
|
53
|
+
"@babel/preset-react": "7.25.9",
|
|
54
|
+
"@babel/preset-typescript": "7.26.0",
|
|
55
|
+
"@babel/runtime": "7.26.0",
|
|
56
56
|
"@bigbinary/babel-preset-neeto": "^1.0.3",
|
|
57
|
-
"@bigbinary/eslint-plugin-neeto": "1.5.
|
|
58
|
-
"@bigbinary/neeto-cist": "1.0.
|
|
59
|
-
"@bigbinary/neeto-commons-frontend": "4.
|
|
60
|
-
"@bigbinary/neeto-filters-frontend": "4.3.
|
|
61
|
-
"@bigbinary/neeto-icons": "1.20.
|
|
62
|
-
"@bigbinary/neeto-molecules": "3.
|
|
63
|
-
"@bigbinary/neetoui": "8.2.
|
|
57
|
+
"@bigbinary/eslint-plugin-neeto": "1.5.7",
|
|
58
|
+
"@bigbinary/neeto-cist": "1.0.15",
|
|
59
|
+
"@bigbinary/neeto-commons-frontend": "4.13.23",
|
|
60
|
+
"@bigbinary/neeto-filters-frontend": "4.3.15",
|
|
61
|
+
"@bigbinary/neeto-icons": "1.20.26",
|
|
62
|
+
"@bigbinary/neeto-molecules": "3.15.38",
|
|
63
|
+
"@bigbinary/neetoui": "8.2.65",
|
|
64
64
|
"@emotion/is-prop-valid": "1.2.0",
|
|
65
65
|
"@faker-js/faker": "8.2.0",
|
|
66
|
-
"@honeybadger-io/js": "
|
|
67
|
-
"@honeybadger-io/react": "
|
|
68
|
-
"@rollup/plugin-alias": "5.
|
|
66
|
+
"@honeybadger-io/js": "6.10.1",
|
|
67
|
+
"@honeybadger-io/react": "6.1.25",
|
|
68
|
+
"@rollup/plugin-alias": "5.1.1",
|
|
69
69
|
"@rollup/plugin-babel": "6.0.4",
|
|
70
70
|
"@rollup/plugin-commonjs": "25.0.7",
|
|
71
|
-
"@rollup/plugin-json": "6.0
|
|
72
|
-
"@rollup/plugin-node-resolve": "15.
|
|
71
|
+
"@rollup/plugin-json": "6.1.0",
|
|
72
|
+
"@rollup/plugin-node-resolve": "15.3.0",
|
|
73
73
|
"@rollup/plugin-replace": "5.0.4",
|
|
74
74
|
"@svgr/rollup": "8.1.0",
|
|
75
|
-
"@tanstack/react-query": "5.
|
|
76
|
-
"@tanstack/react-query-devtools": "5.
|
|
77
|
-
"antd": "5.
|
|
75
|
+
"@tanstack/react-query": "5.59.20",
|
|
76
|
+
"@tanstack/react-query-devtools": "5.59.20",
|
|
77
|
+
"antd": "5.22.0",
|
|
78
78
|
"autoprefixer": "^10.4.5",
|
|
79
|
-
"axios": "1.7.
|
|
79
|
+
"axios": "1.7.7",
|
|
80
80
|
"babel-loader": "^8.2.5",
|
|
81
81
|
"babel-plugin-istanbul": "^6.1.1",
|
|
82
82
|
"babel-plugin-js-logger": "1.0.17",
|
|
83
83
|
"babel-plugin-macros": "3.1.0",
|
|
84
|
+
"babel-plugin-module-resolver": "^5.0.0",
|
|
84
85
|
"babel-plugin-preval": "^5.1.0",
|
|
85
86
|
"babel-plugin-transform-react-remove-prop-types": "0.4.24",
|
|
86
87
|
"babel-preset-react": "6.24.1",
|
|
87
88
|
"babel-preset-typescript": "^7.0.0-alpha.19",
|
|
88
89
|
"browserify-zlib": "0.2.0",
|
|
89
90
|
"buffer": "^6.0.3",
|
|
90
|
-
"classnames": "2.
|
|
91
|
-
"crypto-browserify": "
|
|
91
|
+
"classnames": "2.5.1",
|
|
92
|
+
"crypto-browserify": "3.12.1",
|
|
92
93
|
"css-loader": "6.8.1",
|
|
93
94
|
"dompurify": "^2.4.0",
|
|
94
95
|
"dotenv-webpack": "^8.0.1",
|
|
95
96
|
"eslint": "8.14.0",
|
|
96
97
|
"eslint-config-prettier": "8.5.0",
|
|
97
98
|
"eslint-plugin-cypress": "2.12.1",
|
|
98
|
-
"eslint-plugin-import": "2.
|
|
99
|
+
"eslint-plugin-import": "2.31.0",
|
|
99
100
|
"eslint-plugin-jam3": "0.2.3",
|
|
100
101
|
"eslint-plugin-json": "3.1.0",
|
|
101
102
|
"eslint-plugin-prettier": "4.0.0",
|
|
102
103
|
"eslint-plugin-promise": "6.0.0",
|
|
103
|
-
"eslint-plugin-react": "7.
|
|
104
|
+
"eslint-plugin-react": "7.37.2",
|
|
104
105
|
"eslint-plugin-react-hooks": "4.5.0",
|
|
105
106
|
"eslint-plugin-security": "^1.7.1",
|
|
106
107
|
"eslint-plugin-sonarjs": "^0.21.0",
|
|
107
108
|
"eslint-plugin-unused-imports": "2.0.0",
|
|
108
109
|
"eslint-plugin-xss": "^0.1.12",
|
|
109
|
-
"formik": "2.
|
|
110
|
+
"formik": "2.4.6",
|
|
110
111
|
"html-webpack-plugin": "5.5.3",
|
|
111
112
|
"https-browserify": "1.0.0",
|
|
112
113
|
"husky": "7.0.4",
|
|
@@ -118,7 +119,7 @@
|
|
|
118
119
|
"mixpanel-browser": "2.47.0",
|
|
119
120
|
"os-browserify": "0.3.0",
|
|
120
121
|
"path-browserify": "^1.0.1",
|
|
121
|
-
"postcss": "
|
|
122
|
+
"postcss": "8.4.49",
|
|
122
123
|
"postcss-import": "^15.0.0",
|
|
123
124
|
"postcss-loader": "^7.0.1",
|
|
124
125
|
"postcss-preset-env": "7.8.2",
|
|
@@ -134,7 +135,7 @@
|
|
|
134
135
|
"react-router-dom": "5.3.3",
|
|
135
136
|
"react-toastify": "8.0.2",
|
|
136
137
|
"react_ujs": "^3.1.1",
|
|
137
|
-
"rollup": "
|
|
138
|
+
"rollup": "4.25.0",
|
|
138
139
|
"rollup-plugin-analyzer": "4.0.0",
|
|
139
140
|
"rollup-plugin-cleaner": "1.0.0",
|
|
140
141
|
"rollup-plugin-peer-deps-external": "2.2.4",
|
|
@@ -146,12 +147,12 @@
|
|
|
146
147
|
"stream-browserify": "^3.0.0",
|
|
147
148
|
"stream-http": "3.2.0",
|
|
148
149
|
"style-loader": "^3.3.1",
|
|
149
|
-
"tailwindcss": "
|
|
150
|
+
"tailwindcss": "3.4.14",
|
|
150
151
|
"tty-browserify": "0.0.1",
|
|
151
152
|
"url": "^0.11.0",
|
|
152
153
|
"util": "^0.12.5",
|
|
153
154
|
"vm-browserify": "1.1.2",
|
|
154
|
-
"webpack": "5.
|
|
155
|
+
"webpack": "5.94.0",
|
|
155
156
|
"webpack-assets-manifest": "5.1.0",
|
|
156
157
|
"webpack-cli": "5.1.4",
|
|
157
158
|
"webpack-dev-server": "4.15.1",
|
|
@@ -159,24 +160,24 @@
|
|
|
159
160
|
"zustand": "4.3.2"
|
|
160
161
|
},
|
|
161
162
|
"peerDependencies": {
|
|
162
|
-
"@babel/runtime": "7.
|
|
163
|
-
"@bigbinary/neeto-cist": "1.0.
|
|
164
|
-
"@bigbinary/neeto-commons-frontend": "4.
|
|
165
|
-
"@bigbinary/neeto-filters-frontend": "4.3.
|
|
166
|
-
"@bigbinary/neeto-icons": "1.20.
|
|
167
|
-
"@bigbinary/neeto-molecules": "3.
|
|
168
|
-
"@bigbinary/neetoui": "8.2.
|
|
169
|
-
"@honeybadger-io/js": "
|
|
170
|
-
"@honeybadger-io/react": "
|
|
171
|
-
"@tanstack/react-query": "5.
|
|
172
|
-
"@tanstack/react-query-devtools": "5.
|
|
173
|
-
"antd": "5.
|
|
174
|
-
"axios": "1.7.
|
|
163
|
+
"@babel/runtime": "7.26.0",
|
|
164
|
+
"@bigbinary/neeto-cist": "1.0.15",
|
|
165
|
+
"@bigbinary/neeto-commons-frontend": "4.13.23",
|
|
166
|
+
"@bigbinary/neeto-filters-frontend": "4.3.15",
|
|
167
|
+
"@bigbinary/neeto-icons": "1.20.26",
|
|
168
|
+
"@bigbinary/neeto-molecules": "3.15.38",
|
|
169
|
+
"@bigbinary/neetoui": "8.2.65",
|
|
170
|
+
"@honeybadger-io/js": "6.10.1",
|
|
171
|
+
"@honeybadger-io/react": "6.1.25",
|
|
172
|
+
"@tanstack/react-query": "5.59.20",
|
|
173
|
+
"@tanstack/react-query-devtools": "5.59.20",
|
|
174
|
+
"antd": "5.22.0",
|
|
175
|
+
"axios": "1.7.7",
|
|
175
176
|
"buffer": "^6.0.3",
|
|
176
|
-
"classnames": "2.
|
|
177
|
-
"crypto-browserify": "
|
|
177
|
+
"classnames": "2.5.1",
|
|
178
|
+
"crypto-browserify": "3.12.1",
|
|
178
179
|
"dompurify": "^2.4.0",
|
|
179
|
-
"formik": "2.
|
|
180
|
+
"formik": "2.4.6",
|
|
180
181
|
"https-browserify": "1.0.0",
|
|
181
182
|
"i18next": "22.5.1",
|
|
182
183
|
"js-logger": "1.6.1",
|
|
@@ -194,7 +195,7 @@
|
|
|
194
195
|
"source-map-loader": "4.0.1",
|
|
195
196
|
"stream-browserify": "^3.0.0",
|
|
196
197
|
"stream-http": "3.2.0",
|
|
197
|
-
"tailwindcss": "
|
|
198
|
+
"tailwindcss": "3.4.14",
|
|
198
199
|
"tty-browserify": "0.0.1",
|
|
199
200
|
"url": "^0.11.0",
|
|
200
201
|
"util": "^0.12.5",
|
|
@@ -208,11 +209,12 @@
|
|
|
208
209
|
"string-width": "4.1.0"
|
|
209
210
|
},
|
|
210
211
|
"engines": {
|
|
211
|
-
"node": ">=
|
|
212
|
+
"node": ">=22.13",
|
|
212
213
|
"npm": ">=9",
|
|
213
214
|
"yarn": ">=1.22"
|
|
214
215
|
},
|
|
215
216
|
"dependencies": {
|
|
217
|
+
"@babel/plugin-syntax-dynamic-import": "^7.8.3",
|
|
216
218
|
"babel-plugin-transform-imports": "^2.0.0",
|
|
217
219
|
"react-router-nav-prompt": "0.4.1"
|
|
218
220
|
}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import 'classnames';
|
|
2
|
-
import '@bigbinary/neeto-commons-frontend/initializers';
|
|
3
|
-
import '@bigbinary/neetoui/Spinner';
|
|
4
|
-
export { N as default } from './index-C71Qp9QM.js';
|
|
5
|
-
import 'react/jsx-runtime';
|
|
6
|
-
import '@tanstack/react-query';
|
|
7
|
-
import 'ramda';
|
|
8
|
-
import 'axios';
|
|
9
|
-
import '@bigbinary/neeto-commons-frontend/constants';
|
|
10
|
-
import '@bigbinary/neeto-commons-frontend/react-utils';
|
|
11
|
-
import '@bigbinary/neeto-icons/misc/Github';
|
|
12
|
-
import '@bigbinary/neetoui/Typography';
|
|
13
|
-
import '@bigbinary/neeto-icons/Building';
|
|
14
|
-
import '@bigbinary/neetoui/Avatar';
|
|
15
|
-
import '@bigbinary/neetoui/Button';
|
|
16
|
-
import '@bigbinary/neeto-icons/Plus';
|
|
17
|
-
import '@bigbinary/neeto-icons/Settings';
|
|
18
|
-
import '@babel/runtime/helpers/slicedToArray';
|
|
19
|
-
import 'react';
|
|
20
|
-
import '@bigbinary/neeto-cist';
|
|
21
|
-
import '@bigbinary/neeto-molecules/Search';
|
|
22
|
-
import 'react-i18next';
|
|
23
|
-
import '@bigbinary/neeto-icons/Lock';
|
|
24
|
-
import '@bigbinary/neeto-molecules/DateFormat';
|
|
25
|
-
//# sourceMappingURL=NeetoGithubNanoContainer.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NeetoGithubNanoContainer.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,105 +0,0 @@
|
|
|
1
|
-
import { useRef } from 'react';
|
|
2
|
-
import { findBy, isPresent, noop } from '@bigbinary/neeto-cist';
|
|
3
|
-
import Pane from '@bigbinary/neetoui/Pane';
|
|
4
|
-
import Typography from '@bigbinary/neetoui/Typography';
|
|
5
|
-
import { useTranslation } from 'react-i18next';
|
|
6
|
-
import { n, u as useFetchGithubRepositories, N as NeetoGithubNanoContainer } from './index-C71Qp9QM.js';
|
|
7
|
-
import { globalProps } from '@bigbinary/neeto-commons-frontend/initializers';
|
|
8
|
-
import * as qs from 'qs';
|
|
9
|
-
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
10
|
-
import 'classnames';
|
|
11
|
-
import '@bigbinary/neetoui/Spinner';
|
|
12
|
-
import '@tanstack/react-query';
|
|
13
|
-
import 'ramda';
|
|
14
|
-
import 'axios';
|
|
15
|
-
import '@bigbinary/neeto-commons-frontend/constants';
|
|
16
|
-
import '@bigbinary/neeto-commons-frontend/react-utils';
|
|
17
|
-
import '@bigbinary/neeto-icons/misc/Github';
|
|
18
|
-
import '@bigbinary/neeto-icons/Building';
|
|
19
|
-
import '@bigbinary/neetoui/Avatar';
|
|
20
|
-
import '@bigbinary/neetoui/Button';
|
|
21
|
-
import '@bigbinary/neeto-icons/Plus';
|
|
22
|
-
import '@bigbinary/neeto-icons/Settings';
|
|
23
|
-
import '@babel/runtime/helpers/slicedToArray';
|
|
24
|
-
import '@bigbinary/neeto-molecules/Search';
|
|
25
|
-
import '@bigbinary/neeto-icons/Lock';
|
|
26
|
-
import '@bigbinary/neeto-molecules/DateFormat';
|
|
27
|
-
|
|
28
|
-
var css = ".neeto-github-modal-pane-wrapper{width:min(100%,1280px)}@media (min-width:768px){.neeto-github-modal-pane-wrapper{width:min(90%,1280px)}}@media (min-width:1024px){.neeto-github-modal-pane-wrapper{width:min(60%,1280px)}}\n/*# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImFwcC9qYXZhc2NyaXB0L3N0eWxlc2hlZXRzL2NvbXBvbmVudHMvcGFuZS5zY3NzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLGlDQUNFLHNCQUNGLENBQ0UseUJBSEYsaUNBSUkscUJBRUYsQ0FDRixDQUFFLDBCQVBGLGlDQVFJLHFCQUdGLENBQ0YiLCJzb3VyY2VzQ29udGVudCI6WyIubmVldG8tZ2l0aHViLW1vZGFsLXBhbmUtd3JhcHBlciB7XG4gIHdpZHRoOiBtaW4oMTAwJSwgMTI4MHB4KTtcblxuICBAc2NyZWVuIG1kIHtcbiAgICB3aWR0aDogbWluKDkwJSwgMTI4MHB4KTtcbiAgfVxuXG4gIEBzY3JlZW4gbGcge1xuICAgIHdpZHRoOiBtaW4oNjAlLCAxMjgwcHgpO1xuICB9XG59XG4iXX0= */";
|
|
29
|
-
n(css,{});
|
|
30
|
-
|
|
31
|
-
var _globalProps$organiza;
|
|
32
|
-
var newInstallationParams = qs.stringify({
|
|
33
|
-
integrator_id: globalProps === null || globalProps === void 0 ? void 0 : (_globalProps$organiza = globalProps.organization) === null || _globalProps$organiza === void 0 ? void 0 : _globalProps$organiza.id,
|
|
34
|
-
integrator_type: "Organization",
|
|
35
|
-
redirect_path: "/projects/new"
|
|
36
|
-
});
|
|
37
|
-
var NEW_INSTALLATION_URL = "/github_integrations/app_installations/new?".concat(newInstallationParams);
|
|
38
|
-
var TROUBLESHOOT_URL = "https://render.com/docs/github#troubleshooting";
|
|
39
|
-
|
|
40
|
-
var NeetoGithubNanoPane = function NeetoGithubNanoPane(_ref) {
|
|
41
|
-
var isOpen = _ref.isOpen,
|
|
42
|
-
onClose = _ref.onClose,
|
|
43
|
-
_ref$isConnecting = _ref.isConnecting,
|
|
44
|
-
isConnecting = _ref$isConnecting === void 0 ? false : _ref$isConnecting,
|
|
45
|
-
_ref$isConnected = _ref.isConnected,
|
|
46
|
-
isConnected = _ref$isConnected === void 0 ? false : _ref$isConnected,
|
|
47
|
-
_ref$installationUrl = _ref.installationUrl,
|
|
48
|
-
installationUrl = _ref$installationUrl === void 0 ? NEW_INSTALLATION_URL : _ref$installationUrl,
|
|
49
|
-
_ref$troubleshootUrl = _ref.troubleshootUrl,
|
|
50
|
-
troubleshootUrl = _ref$troubleshootUrl === void 0 ? TROUBLESHOOT_URL : _ref$troubleshootUrl,
|
|
51
|
-
_ref$onConnect = _ref.onConnect,
|
|
52
|
-
onConnect = _ref$onConnect === void 0 ? noop : _ref$onConnect,
|
|
53
|
-
_ref$projects = _ref.projects,
|
|
54
|
-
projects = _ref$projects === void 0 ? [] : _ref$projects,
|
|
55
|
-
_ref$title = _ref.title,
|
|
56
|
-
title = _ref$title === void 0 ? "" : _ref$title;
|
|
57
|
-
var _useTranslation = useTranslation(),
|
|
58
|
-
t = _useTranslation.t;
|
|
59
|
-
var initialFocusRef = useRef(null);
|
|
60
|
-
var _useFetchGithubReposi = useFetchGithubRepositories({
|
|
61
|
-
isConnected: isOpen && isConnected
|
|
62
|
-
}),
|
|
63
|
-
_useFetchGithubReposi2 = _useFetchGithubReposi.data,
|
|
64
|
-
_useFetchGithubReposi3 = _useFetchGithubReposi2 === void 0 ? {} : _useFetchGithubReposi2,
|
|
65
|
-
_useFetchGithubReposi4 = _useFetchGithubReposi3.repositories,
|
|
66
|
-
repositories = _useFetchGithubReposi4 === void 0 ? [] : _useFetchGithubReposi4,
|
|
67
|
-
_useFetchGithubReposi5 = _useFetchGithubReposi3.accounts,
|
|
68
|
-
accounts = _useFetchGithubReposi5 === void 0 ? [] : _useFetchGithubReposi5,
|
|
69
|
-
isPaneLoading = _useFetchGithubReposi.isLoading;
|
|
70
|
-
var paneRepositories = repositories.filter(function (repository) {
|
|
71
|
-
return !findBy({
|
|
72
|
-
repository: repository.fullName
|
|
73
|
-
}, projects);
|
|
74
|
-
});
|
|
75
|
-
var paneAccounts = isConnected ? accounts : [];
|
|
76
|
-
return /*#__PURE__*/jsxs(Pane, {
|
|
77
|
-
initialFocusRef: initialFocusRef,
|
|
78
|
-
isOpen: isOpen,
|
|
79
|
-
onClose: onClose,
|
|
80
|
-
className: "neeto-github-modal-pane-wrapper",
|
|
81
|
-
size: "large",
|
|
82
|
-
children: [/*#__PURE__*/jsx(Pane.Header, {
|
|
83
|
-
children: /*#__PURE__*/jsx(Typography, {
|
|
84
|
-
style: "h2",
|
|
85
|
-
children: isPresent(title) ? title : t("neetoGithub.modal.title")
|
|
86
|
-
})
|
|
87
|
-
}), /*#__PURE__*/jsx(Pane.Body, {
|
|
88
|
-
children: /*#__PURE__*/jsx(NeetoGithubNanoContainer, {
|
|
89
|
-
installationUrl: installationUrl,
|
|
90
|
-
isConnected: isConnected,
|
|
91
|
-
isConnecting: isConnecting,
|
|
92
|
-
isPaneLoading: isPaneLoading,
|
|
93
|
-
onConnect: onConnect,
|
|
94
|
-
paneAccounts: paneAccounts,
|
|
95
|
-
paneRepositories: paneRepositories,
|
|
96
|
-
troubleshootUrl: troubleshootUrl,
|
|
97
|
-
isPane: true,
|
|
98
|
-
shouldFetchRepositories: false
|
|
99
|
-
})
|
|
100
|
-
})]
|
|
101
|
-
});
|
|
102
|
-
};
|
|
103
|
-
|
|
104
|
-
export { NeetoGithubNanoPane as default };
|
|
105
|
-
//# sourceMappingURL=NeetoGithubNanoPane.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NeetoGithubNanoPane.js","sources":["../app/javascript/src/components/NeetoGithubNanoPane/constants.js","../app/javascript/src/components/NeetoGithubNanoPane/index.jsx"],"sourcesContent":["import { globalProps } from \"neetocommons/initializers\";\nimport * as qs from \"qs\";\n\nconst newInstallationParams = qs.stringify({\n integrator_id: globalProps?.organization?.id,\n integrator_type: \"Organization\",\n redirect_path: \"/projects/new\",\n});\n\nexport const NEW_INSTALLATION_URL = `/github_integrations/app_installations/new?${newInstallationParams}`;\nexport const TROUBLESHOOT_URL =\n \"https://render.com/docs/github#troubleshooting\";\n","import { useRef } from \"react\";\n\nimport { findBy, isPresent, noop } from \"neetocist\";\nimport { Pane, Typography } from \"neetoui\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { useFetchGithubRepositories } from \"hooks/reactQuery/useGithubAccountsApi\";\nimport NeetoGithubNanoContainer from \"src/components/NeetoGithubNanoContainer\";\n// eslint-disable-next-line import/extensions\nimport \"stylesheets/components/pane.scss\";\n\nimport { NEW_INSTALLATION_URL, TROUBLESHOOT_URL } from \"./constants\";\n\nconst NeetoGithubNanoPane = ({\n isOpen,\n onClose,\n isConnecting = false,\n isConnected = false,\n installationUrl = NEW_INSTALLATION_URL,\n troubleshootUrl = TROUBLESHOOT_URL,\n onConnect = noop,\n projects = [],\n title = \"\",\n}) => {\n const { t } = useTranslation();\n\n const initialFocusRef = useRef(null);\n\n const {\n data: { repositories = [], accounts = [] } = {},\n isLoading: isPaneLoading,\n } = useFetchGithubRepositories({ isConnected: isOpen && isConnected });\n\n const paneRepositories = repositories.filter(\n repository => !findBy({ repository: repository.fullName }, projects)\n );\n\n const paneAccounts = isConnected ? accounts : [];\n\n return (\n <Pane\n {...{ initialFocusRef, isOpen, onClose }}\n className=\"neeto-github-modal-pane-wrapper\"\n size=\"large\"\n >\n <Pane.Header>\n <Typography style=\"h2\">\n {isPresent(title) ? title : t(\"neetoGithub.modal.title\")}\n </Typography>\n </Pane.Header>\n <Pane.Body>\n <NeetoGithubNanoContainer\n {...{\n installationUrl,\n isConnected,\n isConnecting,\n isPaneLoading,\n onConnect,\n paneAccounts,\n paneRepositories,\n troubleshootUrl,\n }}\n isPane\n shouldFetchRepositories={false}\n />\n </Pane.Body>\n </Pane>\n );\n};\n\nexport default NeetoGithubNanoPane;\n"],"names":["newInstallationParams","qs","stringify","integrator_id","globalProps","_globalProps$organiza","organization","id","integrator_type","redirect_path","NEW_INSTALLATION_URL","concat","TROUBLESHOOT_URL","NeetoGithubNanoPane","_ref","isOpen","onClose","_ref$isConnecting","isConnecting","_ref$isConnected","isConnected","_ref$installationUrl","installationUrl","_ref$troubleshootUrl","troubleshootUrl","_ref$onConnect","onConnect","noop","_ref$projects","projects","_ref$title","title","_useTranslation","useTranslation","t","initialFocusRef","useRef","_useFetchGithubReposi","useFetchGithubRepositories","_useFetchGithubReposi2","data","_useFetchGithubReposi3","_useFetchGithubReposi4","repositories","_useFetchGithubReposi5","accounts","isPaneLoading","isLoading","paneRepositories","filter","repository","findBy","fullName","paneAccounts","_jsxs","Pane","className","size","children","_jsx","Header","Typography","style","isPresent","Body","NeetoGithubNanoContainer","isPane","shouldFetchRepositories"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,IAAMA,qBAAqB,GAAGC,EAAE,CAACC,SAAS,CAAC;AACzCC,EAAAA,aAAa,EAAEC,WAAW,KAAXA,IAAAA,IAAAA,WAAW,wBAAAC,qBAAA,GAAXD,WAAW,CAAEE,YAAY,MAAAD,IAAAA,IAAAA,qBAAA,KAAzBA,KAAAA,CAAAA,GAAAA,KAAAA,CAAAA,GAAAA,qBAAA,CAA2BE,EAAE;AAC5CC,EAAAA,eAAe,EAAE,cAAc;AAC/BC,EAAAA,aAAa,EAAE,eAAA;AACjB,CAAC,CAAC,CAAA;AAEK,IAAMC,oBAAoB,GAAA,6CAAA,CAAAC,MAAA,CAAiDX,qBAAqB,CAAE,CAAA;AAClG,IAAMY,gBAAgB,GAC3B,gDAAgD;;ACElD,IAAMC,mBAAmB,GAAG,SAAtBA,mBAAmBA,CAAAC,IAAA,EAUnB;AAAA,EAAA,IATJC,MAAM,GAAAD,IAAA,CAANC,MAAM;IACNC,OAAO,GAAAF,IAAA,CAAPE,OAAO;IAAAC,iBAAA,GAAAH,IAAA,CACPI,YAAY;AAAZA,IAAAA,YAAY,GAAAD,iBAAA,KAAG,KAAA,CAAA,GAAA,KAAK,GAAAA,iBAAA;IAAAE,gBAAA,GAAAL,IAAA,CACpBM,WAAW;AAAXA,IAAAA,WAAW,GAAAD,gBAAA,KAAG,KAAA,CAAA,GAAA,KAAK,GAAAA,gBAAA;IAAAE,oBAAA,GAAAP,IAAA,CACnBQ,eAAe;AAAfA,IAAAA,eAAe,GAAAD,oBAAA,KAAGX,KAAAA,CAAAA,GAAAA,oBAAoB,GAAAW,oBAAA;IAAAE,oBAAA,GAAAT,IAAA,CACtCU,eAAe;AAAfA,IAAAA,eAAe,GAAA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ontend/initializers');
|
|
5
|
-
require('@bigbinary/neetoui/Spinner');
|
|
6
|
-
var NeetoGithubNanoContainer = require('../index-DelA1uHU.js');
|
|
7
|
-
require('react/jsx-runtime');
|
|
8
|
-
require('@tanstack/react-query');
|
|
9
|
-
require('ramda');
|
|
10
|
-
require('axios');
|
|
11
|
-
require('@bigbinary/neeto-commons-frontend/constants');
|
|
12
|
-
require('@bigbinary/neeto-commons-frontend/react-utils');
|
|
13
|
-
require('@bigbinary/neeto-icons/misc/Github');
|
|
14
|
-
require('@bigbinary/neetoui/Typography');
|
|
15
|
-
require('@bigbinary/neeto-icons/Building');
|
|
16
|
-
require('@bigbinary/neetoui/Avatar');
|
|
17
|
-
require('@bigbinary/neetoui/Button');
|
|
18
|
-
require('@bigbinary/neeto-icons/Plus');
|
|
19
|
-
require('@bigbinary/neeto-icons/Settings');
|
|
20
|
-
require('@babel/runtime/helpers/slicedToArray');
|
|
21
|
-
require('react');
|
|
22
|
-
require('@bigbinary/neeto-cist');
|
|
23
|
-
require('@bigbinary/neeto-molecules/Search');
|
|
24
|
-
require('react-i18next');
|
|
25
|
-
require('@bigbinary/neeto-icons/Lock');
|
|
26
|
-
require('@bigbinary/neeto-molecules/DateFormat');
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
module.exports = NeetoGithubNanoContainer.NeetoGithubNanoContainer;
|
|
31
|
-
//# sourceMappingURL=NeetoGithubNanoContainer.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NeetoGithubNanoContainer.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,126 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var react = require('react');
|
|
4
|
-
var neetoCist = require('@bigbinary/neeto-cist');
|
|
5
|
-
var Pane = require('@bigbinary/neetoui/Pane');
|
|
6
|
-
var Typography = require('@bigbinary/neetoui/Typography');
|
|
7
|
-
var reactI18next = require('react-i18next');
|
|
8
|
-
var NeetoGithubNanoContainer = require('../index-DelA1uHU.js');
|
|
9
|
-
var initializers = require('@bigbinary/neeto-commons-frontend/initializers');
|
|
10
|
-
var qs = require('qs');
|
|
11
|
-
var jsxRuntime = require('react/jsx-runtime');
|
|
12
|
-
require('classnames');
|
|
13
|
-
require('@bigbinary/neetoui/Spinner');
|
|
14
|
-
require('@tanstack/react-query');
|
|
15
|
-
require('ramda');
|
|
16
|
-
require('axios');
|
|
17
|
-
require('@bigbinary/neeto-commons-frontend/constants');
|
|
18
|
-
require('@bigbinary/neeto-commons-frontend/react-utils');
|
|
19
|
-
require('@bigbinary/neeto-icons/misc/Github');
|
|
20
|
-
require('@bigbinary/neeto-icons/Building');
|
|
21
|
-
require('@bigbinary/neetoui/Avatar');
|
|
22
|
-
require('@bigbinary/neetoui/Button');
|
|
23
|
-
require('@bigbinary/neeto-icons/Plus');
|
|
24
|
-
require('@bigbinary/neeto-icons/Settings');
|
|
25
|
-
require('@babel/runtime/helpers/slicedToArray');
|
|
26
|
-
require('@bigbinary/neeto-molecules/Search');
|
|
27
|
-
require('@bigbinary/neeto-icons/Lock');
|
|
28
|
-
require('@bigbinary/neeto-molecules/DateFormat');
|
|
29
|
-
|
|
30
|
-
function _interopNamespaceDefault(e) {
|
|
31
|
-
var n = Object.create(null);
|
|
32
|
-
if (e) {
|
|
33
|
-
Object.keys(e).forEach(function (k) {
|
|
34
|
-
if (k !== 'default') {
|
|
35
|
-
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
36
|
-
Object.defineProperty(n, k, d.get ? d : {
|
|
37
|
-
enumerable: true,
|
|
38
|
-
get: function () { return e[k]; }
|
|
39
|
-
});
|
|
40
|
-
}
|
|
41
|
-
});
|
|
42
|
-
}
|
|
43
|
-
n.default = e;
|
|
44
|
-
return Object.freeze(n);
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
var qs__namespace = /*#__PURE__*/_interopNamespaceDefault(qs);
|
|
48
|
-
|
|
49
|
-
var css = ".neeto-github-modal-pane-wrapper{width:min(100%,1280px)}@media (min-width:768px){.neeto-github-modal-pane-wrapper{width:min(90%,1280px)}}@media (min-width:1024px){.neeto-github-modal-pane-wrapper{width:min(60%,1280px)}}\n/*# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImFwcC9qYXZhc2NyaXB0L3N0eWxlc2hlZXRzL2NvbXBvbmVudHMvcGFuZS5zY3NzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLGlDQUNFLHNCQUNGLENBQ0UseUJBSEYsaUNBSUkscUJBRUYsQ0FDRixDQUFFLDBCQVBGLGlDQVFJLHFCQUdGLENBQ0YiLCJzb3VyY2VzQ29udGVudCI6WyIubmVldG8tZ2l0aHViLW1vZGFsLXBhbmUtd3JhcHBlciB7XG4gIHdpZHRoOiBtaW4oMTAwJSwgMTI4MHB4KTtcblxuICBAc2NyZWVuIG1kIHtcbiAgICB3aWR0aDogbWluKDkwJSwgMTI4MHB4KTtcbiAgfVxuXG4gIEBzY3JlZW4gbGcge1xuICAgIHdpZHRoOiBtaW4oNjAlLCAxMjgwcHgpO1xuICB9XG59XG4iXX0= */";
|
|
50
|
-
NeetoGithubNanoContainer.n(css,{});
|
|
51
|
-
|
|
52
|
-
var _globalProps$organiza;
|
|
53
|
-
var newInstallationParams = qs__namespace.stringify({
|
|
54
|
-
integrator_id: initializers.globalProps === null || initializers.globalProps === void 0 ? void 0 : (_globalProps$organiza = initializers.globalProps.organization) === null || _globalProps$organiza === void 0 ? void 0 : _globalProps$organiza.id,
|
|
55
|
-
integrator_type: "Organization",
|
|
56
|
-
redirect_path: "/projects/new"
|
|
57
|
-
});
|
|
58
|
-
var NEW_INSTALLATION_URL = "/github_integrations/app_installations/new?".concat(newInstallationParams);
|
|
59
|
-
var TROUBLESHOOT_URL = "https://render.com/docs/github#troubleshooting";
|
|
60
|
-
|
|
61
|
-
var NeetoGithubNanoPane = function NeetoGithubNanoPane(_ref) {
|
|
62
|
-
var isOpen = _ref.isOpen,
|
|
63
|
-
onClose = _ref.onClose,
|
|
64
|
-
_ref$isConnecting = _ref.isConnecting,
|
|
65
|
-
isConnecting = _ref$isConnecting === void 0 ? false : _ref$isConnecting,
|
|
66
|
-
_ref$isConnected = _ref.isConnected,
|
|
67
|
-
isConnected = _ref$isConnected === void 0 ? false : _ref$isConnected,
|
|
68
|
-
_ref$installationUrl = _ref.installationUrl,
|
|
69
|
-
installationUrl = _ref$installationUrl === void 0 ? NEW_INSTALLATION_URL : _ref$installationUrl,
|
|
70
|
-
_ref$troubleshootUrl = _ref.troubleshootUrl,
|
|
71
|
-
troubleshootUrl = _ref$troubleshootUrl === void 0 ? TROUBLESHOOT_URL : _ref$troubleshootUrl,
|
|
72
|
-
_ref$onConnect = _ref.onConnect,
|
|
73
|
-
onConnect = _ref$onConnect === void 0 ? neetoCist.noop : _ref$onConnect,
|
|
74
|
-
_ref$projects = _ref.projects,
|
|
75
|
-
projects = _ref$projects === void 0 ? [] : _ref$projects,
|
|
76
|
-
_ref$title = _ref.title,
|
|
77
|
-
title = _ref$title === void 0 ? "" : _ref$title;
|
|
78
|
-
var _useTranslation = reactI18next.useTranslation(),
|
|
79
|
-
t = _useTranslation.t;
|
|
80
|
-
var initialFocusRef = react.useRef(null);
|
|
81
|
-
var _useFetchGithubReposi = NeetoGithubNanoContainer.useFetchGithubRepositories({
|
|
82
|
-
isConnected: isOpen && isConnected
|
|
83
|
-
}),
|
|
84
|
-
_useFetchGithubReposi2 = _useFetchGithubReposi.data,
|
|
85
|
-
_useFetchGithubReposi3 = _useFetchGithubReposi2 === void 0 ? {} : _useFetchGithubReposi2,
|
|
86
|
-
_useFetchGithubReposi4 = _useFetchGithubReposi3.repositories,
|
|
87
|
-
repositories = _useFetchGithubReposi4 === void 0 ? [] : _useFetchGithubReposi4,
|
|
88
|
-
_useFetchGithubReposi5 = _useFetchGithubReposi3.accounts,
|
|
89
|
-
accounts = _useFetchGithubReposi5 === void 0 ? [] : _useFetchGithubReposi5,
|
|
90
|
-
isPaneLoading = _useFetchGithubReposi.isLoading;
|
|
91
|
-
var paneRepositories = repositories.filter(function (repository) {
|
|
92
|
-
return !neetoCist.findBy({
|
|
93
|
-
repository: repository.fullName
|
|
94
|
-
}, projects);
|
|
95
|
-
});
|
|
96
|
-
var paneAccounts = isConnected ? accounts : [];
|
|
97
|
-
return /*#__PURE__*/jsxRuntime.jsxs(Pane, {
|
|
98
|
-
initialFocusRef: initialFocusRef,
|
|
99
|
-
isOpen: isOpen,
|
|
100
|
-
onClose: onClose,
|
|
101
|
-
className: "neeto-github-modal-pane-wrapper",
|
|
102
|
-
size: "large",
|
|
103
|
-
children: [/*#__PURE__*/jsxRuntime.jsx(Pane.Header, {
|
|
104
|
-
children: /*#__PURE__*/jsxRuntime.jsx(Typography, {
|
|
105
|
-
style: "h2",
|
|
106
|
-
children: neetoCist.isPresent(title) ? title : t("neetoGithub.modal.title")
|
|
107
|
-
})
|
|
108
|
-
}), /*#__PURE__*/jsxRuntime.jsx(Pane.Body, {
|
|
109
|
-
children: /*#__PURE__*/jsxRuntime.jsx(NeetoGithubNanoContainer.NeetoGithubNanoContainer, {
|
|
110
|
-
installationUrl: installationUrl,
|
|
111
|
-
isConnected: isConnected,
|
|
112
|
-
isConnecting: isConnecting,
|
|
113
|
-
isPaneLoading: isPaneLoading,
|
|
114
|
-
onConnect: onConnect,
|
|
115
|
-
paneAccounts: paneAccounts,
|
|
116
|
-
paneRepositories: paneRepositories,
|
|
117
|
-
troubleshootUrl: troubleshootUrl,
|
|
118
|
-
isPane: true,
|
|
119
|
-
shouldFetchRepositories: false
|
|
120
|
-
})
|
|
121
|
-
})]
|
|
122
|
-
});
|
|
123
|
-
};
|
|
124
|
-
|
|
125
|
-
module.exports = NeetoGithubNanoPane;
|
|
126
|
-
//# sourceMappingURL=NeetoGithubNanoPane.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NeetoGithubNanoPane.js","sources":["../../app/javascript/src/components/NeetoGithubNanoPane/constants.js","../../app/javascript/src/components/NeetoGithubNanoPane/index.jsx"],"sourcesContent":["import { globalProps } from \"neetocommons/initializers\";\nimport * as qs from \"qs\";\n\nconst newInstallationParams = qs.stringify({\n integrator_id: globalProps?.organization?.id,\n integrator_type: \"Organization\",\n redirect_path: \"/projects/new\",\n});\n\nexport const NEW_INSTALLATION_URL = `/github_integrations/app_installations/new?${newInstallationParams}`;\nexport const TROUBLESHOOT_URL =\n \"https://render.com/docs/github#troubleshooting\";\n","import { useRef } from \"react\";\n\nimport { findBy, isPresent, noop } from \"neetocist\";\nimport { Pane, Typography } from \"neetoui\";\nimport { useTranslation } from \"react-i18next\";\n\nimport { useFetchGithubRepositories } from \"hooks/reactQuery/useGithubAccountsApi\";\nimport NeetoGithubNanoContainer from \"src/components/NeetoGithubNanoContainer\";\n// eslint-disable-next-line import/extensions\nimport \"stylesheets/components/pane.scss\";\n\nimport { NEW_INSTALLATION_URL, TROUBLESHOOT_URL } from \"./constants\";\n\nconst NeetoGithubNanoPane = ({\n isOpen,\n onClose,\n isConnecting = false,\n isConnected = false,\n installationUrl = NEW_INSTALLATION_URL,\n troubleshootUrl = TROUBLESHOOT_URL,\n onConnect = noop,\n projects = [],\n title = \"\",\n}) => {\n const { t } = useTranslation();\n\n const initialFocusRef = useRef(null);\n\n const {\n data: { repositories = [], accounts = [] } = {},\n isLoading: isPaneLoading,\n } = useFetchGithubRepositories({ isConnected: isOpen && isConnected });\n\n const paneRepositories = repositories.filter(\n repository => !findBy({ repository: repository.fullName }, projects)\n );\n\n const paneAccounts = isConnected ? accounts : [];\n\n return (\n <Pane\n {...{ initialFocusRef, isOpen, onClose }}\n className=\"neeto-github-modal-pane-wrapper\"\n size=\"large\"\n >\n <Pane.Header>\n <Typography style=\"h2\">\n {isPresent(title) ? title : t(\"neetoGithub.modal.title\")}\n </Typography>\n </Pane.Header>\n <Pane.Body>\n <NeetoGithubNanoContainer\n {...{\n installationUrl,\n isConnected,\n isConnecting,\n isPaneLoading,\n onConnect,\n paneAccounts,\n paneRepositories,\n troubleshootUrl,\n }}\n isPane\n shouldFetchRepositories={false}\n />\n </Pane.Body>\n </Pane>\n );\n};\n\nexport default NeetoGithubNanoPane;\n"],"names":["newInstallationParams","qs","stringify","integrator_id","globalProps","_globalProps$organiza","organization","id","integrator_type","redirect_path","NEW_INSTALLATION_URL","concat","TROUBLESHOOT_URL","NeetoGithubNanoPane","_ref","isOpen","onClose","_ref$isConnecting","isConnecting","_ref$isConnected","isConnected","_ref$installationUrl","installationUrl","_ref$troubleshootUrl","troubleshootUrl","_ref$onConnect","onConnect","noop","_ref$projects","projects","_ref$title","title","_useTranslation","useTranslation","t","initialFocusRef","useRef","_useFetchGithubReposi","useFetchGithubRepositories","_useFetchGithubReposi2","data","_useFetchGithubReposi3","_useFetchGithubReposi4","repositories","_useFetchGithubReposi5","accounts","isPaneLoading","isLoading","paneRepositories","filter","repository","findBy","fullName","paneAccounts","_jsxs","Pane","className","size","children","_jsx","Header","Typography","style","isPresent","Body","NeetoGithubNanoContainer","isPane","shouldFetchRepositories"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGA,IAAMA,qBAAqB,GAAGC,aAAE,CAACC,SAAS,CAAC;AACzCC,EAAAA,aAAa,EAAEC,wBAAW,KAAXA,IAAAA,IAAAA,wBAAW,wBAAAC,qBAAA,GAAXD,wBAAW,CAAEE,YAAY,MAAAD,IAAAA,IAAAA,qBAAA,KAAzBA,KAAAA,CAAAA,GAAAA,KAAAA,CAAAA,GAAAA,qBAAA,CAA2BE,EAAE;AAC5CC,EAAAA,eAAe,EAAE,cAAc;AAC/BC,EAAAA,aAAa,EAAE,eAAA;AACjB,CAAC,CAAC,CAAA;AAEK,IAAMC,oBAAoB,GAAA,6CAAA,CAAAC,MAAA,CAAiDX,qBAAqB,CAAE,CAAA;AAClG,IAAMY,gBA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AAC,eACdyB,cAAA,CAACJ,IAAI,CAACS,IAAI,EAAA;MAAAN,QAAA,eACRC,cAAA,CAACM,iDAAwB,EAAA;AAErB3C,QAAAA,eAAe,EAAfA,eAAe;AACfF,QAAAA,WAAW,EAAXA,WAAW;AACXF,QAAAA,YAAY,EAAZA,YAAY;AACZ4B,QAAAA,aAAa,EAAbA,aAAa;AACbpB,QAAAA,SAAS,EAATA,SAAS;AACT2B,QAAAA,YAAY,EAAZA,YAAY;AACZL,QAAAA,gBAAgB,EAAhBA,gBAAgB;AAChBxB,QAAAA,eAAe,EAAfA,eAAe;QAEjB0C,MAAM,EAAA,IAAA;AACNC,QAAAA,uBAAuB,EAAE,KAAA;OAC1B,CAAA;AAAC,KACO,CAAC,CAAA;AAAA,GACR,CAAC,CAAA;AAEX;;;;"}
|
package/dist/cjs/index.js
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var NeetoGithubNanoContainer = require('../index-DelA1uHU.js');
|
|
4
|
-
var NeetoGithubNanoPane = require('./NeetoGithubNanoPane.js');
|
|
5
|
-
require('classnames');
|
|
6
|
-
require('@bigbinary/neeto-commons-frontend/initializers');
|
|
7
|
-
require('@bigbinary/neetoui/Spinner');
|
|
8
|
-
require('@tanstack/react-query');
|
|
9
|
-
require('ramda');
|
|
10
|
-
require('axios');
|
|
11
|
-
require('@bigbinary/neeto-commons-frontend/constants');
|
|
12
|
-
require('@bigbinary/neeto-commons-frontend/react-utils');
|
|
13
|
-
require('@bigbinary/neeto-icons/misc/Github');
|
|
14
|
-
require('@bigbinary/neetoui/Typography');
|
|
15
|
-
require('react/jsx-runtime');
|
|
16
|
-
require('@bigbinary/neeto-icons/Building');
|
|
17
|
-
require('@bigbinary/neetoui/Avatar');
|
|
18
|
-
require('@bigbinary/neetoui/Button');
|
|
19
|
-
require('@bigbinary/neeto-icons/Plus');
|
|
20
|
-
require('@bigbinary/neeto-icons/Settings');
|
|
21
|
-
require('@babel/runtime/helpers/slicedToArray');
|
|
22
|
-
require('react');
|
|
23
|
-
require('@bigbinary/neeto-cist');
|
|
24
|
-
require('@bigbinary/neeto-molecules/Search');
|
|
25
|
-
require('react-i18next');
|
|
26
|
-
require('@bigbinary/neeto-icons/Lock');
|
|
27
|
-
require('@bigbinary/neeto-molecules/DateFormat');
|
|
28
|
-
require('@bigbinary/neetoui/Pane');
|
|
29
|
-
require('qs');
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
exports.NeetoGithubNanoContainer = NeetoGithubNanoContainer.NeetoGithubNanoContainer;
|
|
34
|
-
exports.NeetoGithubNanoPane = NeetoGithubNanoPane;
|
|
35
|
-
//# sourceMappingURL=index.js.map
|
package/dist/cjs/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|