carta-controller 5.1.1 → 6.0.0-beta.1.0.3

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.
@@ -1,239 +1,251 @@
1
1
  body {
2
- background-color: #f6f8fa;
3
- font-family: "Roboto", sans-serif;
4
- -webkit-font-smoothing: antialiased;
5
- -moz-osx-font-smoothing: grayscale;
2
+ background-color: #f6f8fa;
3
+ font-family: "Roboto", sans-serif;
4
+ -webkit-font-smoothing: antialiased;
5
+ -moz-osx-font-smoothing: grayscale;
6
6
  }
7
7
 
8
8
  .center {
9
- margin: 0;
10
- position: absolute;
11
- top: 50%;
12
- left: 50%;
13
- -ms-transform: translate(-50%, -50%);
14
- transform: translate(-50%, -50%);
9
+ margin: 0;
10
+ position: absolute;
11
+ top: 50%;
12
+ left: 50%;
13
+ -ms-transform: translate(-50%, -50%);
14
+ transform: translate(-50%, -50%);
15
15
  }
16
16
 
17
17
  .blurred {
18
- transition: 100ms;
19
- filter: blur(16px);
18
+ transition: 100ms;
19
+ filter: blur(16px);
20
20
  }
21
21
 
22
22
  .signin-dialog {
23
- background-color: #ffffff;
24
- width: 640px;
25
- border-radius: 3px;
26
- border: 0;
27
- padding-top: 0;
28
- margin: 20px auto 0 auto;
29
- box-shadow: 0 0 15px 0 rgba(16, 22, 26, .05), 0 18px 46px 0 rgba(16, 22, 26, .05);
23
+ background-color: #ffffff;
24
+ width: 640px;
25
+ border-radius: 3px;
26
+ border: 0;
27
+ padding-top: 0;
28
+ margin: 20px auto 0 auto;
29
+ box-shadow:
30
+ 0 0 15px 0 rgba(16, 22, 26, 0.05),
31
+ 0 18px 46px 0 rgba(16, 22, 26, 0.05);
30
32
  }
31
33
 
32
34
  .logo {
33
- display: flex;
34
- justify-content: center;
35
- height: 90px;
36
- padding-top: 30px;
37
- margin: 0 -20px 15px 0;
35
+ display: flex;
36
+ justify-content: center;
37
+ height: 90px;
38
+ padding-top: 30px;
39
+ margin: 0 -20px 15px 0;
38
40
  }
39
41
 
40
42
  .spacer {
41
- width: 0px;
43
+ width: 0px;
42
44
  }
43
45
 
44
46
  .titletext {
45
- display: block;
46
- text-align: left;
47
- font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", Icons16, sans-serif;
48
- margin: 23px 40px auto 10px;
49
- color: #123A6F;
50
- line-height: 21px;
51
- font-size: 32px;
52
- font-weight: bold;
47
+ display: block;
48
+ text-align: left;
49
+ font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", Icons16, sans-serif;
50
+ margin: 23px 40px auto 10px;
51
+ color: #123a6f;
52
+ line-height: 21px;
53
+ font-size: 32px;
54
+ font-weight: bold;
53
55
  }
54
56
 
55
- @supports (-moz-appearance:none) {
57
+ @supports (-moz-appearance: none) {
56
58
  .titletext {
57
- width: 280%;
58
- }
59
- .spacer {
60
- width: 70%;
61
- }
59
+ width: 280%;
60
+ }
61
+ .spacer {
62
+ width: 70%;
63
+ }
62
64
  }
63
65
 
64
66
  .bodytext {
65
- text-align: center;
66
- font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", Icons16, sans-serif;
67
- margin: 30px auto 10px auto;
68
- font-size: 14px;
69
- line-height: 18px;
70
- color: #505b66;
67
+ text-align: center;
68
+ font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", Icons16, sans-serif;
69
+ margin: 30px auto 10px auto;
70
+ font-size: 14px;
71
+ line-height: 18px;
72
+ color: #505b66;
71
73
  }
72
74
 
73
75
  .loggedin {
74
- font-size: 13px;
75
- margin: 20px auto -7px auto;
76
+ font-size: 13px;
77
+ margin: 20px auto -7px auto;
76
78
  }
77
79
 
78
80
  .banner {
79
- padding: 20px;
80
- display: block;
81
- margin: 0 auto 0 auto;
82
- vertical-align: top;
81
+ padding: 20px;
82
+ display: block;
83
+ margin: 0 auto 0 auto;
84
+ vertical-align: top;
83
85
  }
84
86
 
85
87
  .footer {
86
- text-align: center;
87
- font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", Icons16, sans-serif;
88
- font-size: 13px;
89
- line-height: 18px;
90
- margin-top: 25px;
91
- color: #000000;
92
- }
93
-
94
- input[type=text], input[type=password] {
95
- font-size: 14px;
96
- font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", Icons16, sans-serif;
97
- color: #245282;
98
- width: 480px;
99
- background-color: rgba(120, 131, 142, .4);
100
- border: hidden;
101
- border-radius: 3px;
102
- padding: 15px 15px;
103
- margin: 12px auto 0 auto;
104
- display: inline-block;
105
- box-sizing: border-box;
88
+ text-align: center;
89
+ font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", Icons16, sans-serif;
90
+ font-size: 13px;
91
+ line-height: 18px;
92
+ margin-top: 25px;
93
+ color: #000000;
94
+ }
95
+
96
+ input[type="text"],
97
+ input[type="password"] {
98
+ font-size: 14px;
99
+ font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", Icons16, sans-serif;
100
+ color: #245282;
101
+ width: 480px;
102
+ background-color: rgba(120, 131, 142, 0.4);
103
+ border: hidden;
104
+ border-radius: 3px;
105
+ padding: 15px 15px;
106
+ margin: 12px auto 0 auto;
107
+ display: inline-block;
108
+ box-sizing: border-box;
106
109
  }
107
110
 
108
111
  ::placeholder {
109
- font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", Icons16, sans-serif;
110
- font-size: 14px;
111
- color: #FFFFFF;
112
+ font-family: Roboto, -apple-system, BlinkMacSystemFont, "Segoe UI", Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", Icons16, sans-serif;
113
+ font-size: 14px;
114
+ color: #ffffff;
112
115
  }
113
116
 
114
117
  button {
115
- border-radius: 3px;
116
- text-transform: uppercase;
117
- color: #FFFFFF;
118
- font-size: 14px;
119
- padding: 15px;
120
- margin: 15px auto 0 auto;
121
- border: 0;
122
- cursor: pointer;
123
- width: 220px;
124
- transition: 100ms;
118
+ border-radius: 3px;
119
+ text-transform: uppercase;
120
+ color: #ffffff;
121
+ font-size: 14px;
122
+ padding: 15px;
123
+ margin: 15px auto 0 auto;
124
+ border: 0;
125
+ cursor: pointer;
126
+ width: 220px;
127
+ transition: 100ms;
125
128
  }
126
129
 
127
130
  .button-signin {
128
- background: #2c649e;
131
+ background: #2c649e;
129
132
  }
130
133
 
131
- .button-signin:hover, .button-signin:active, .button-signin:focus {
132
- background: #245282;
134
+ .button-signin:hover,
135
+ .button-signin:active,
136
+ .button-signin:focus {
137
+ background: #245282;
133
138
  }
134
139
 
135
140
  .button-newsession {
136
- background: #469765;
141
+ background: #469765;
137
142
  }
138
143
 
139
- .button-newsession:hover, .button-newsession:active, .button-newsession:focus {
140
- background: #397d53;
144
+ .button-newsession:hover,
145
+ .button-newsession:active,
146
+ .button-newsession:focus {
147
+ background: #397d53;
141
148
  }
142
149
 
143
150
  .button-restart {
144
- background: #ca453f;
151
+ background: #ca453f;
145
152
  }
146
153
 
147
- .button-restart:hover, .button-restart:active .button-restart:focus {
148
- background: #b03d37;
154
+ .button-restart:hover,
155
+ .button-restart:active .button-restart:focus {
156
+ background: #b03d37;
149
157
  }
150
158
 
151
159
  .button-restart:disabled {
152
- color: rgba(120, 131, 142, .3);
153
- background: rgba(120, 131, 142, .3);
154
- cursor: not-allowed;
160
+ color: rgba(120, 131, 142, 0.3);
161
+ background: rgba(120, 131, 142, 0.3);
162
+ cursor: not-allowed;
155
163
  }
156
164
 
157
165
  .button-logs {
158
- background: #964582;
166
+ background: #964582;
159
167
  }
160
168
 
161
- .button-logs:hover, .button-logs:active, .button-logs:focus {
162
- background: #7d396c;
169
+ .button-logs:hover,
170
+ .button-logs:active,
171
+ .button-logs:focus {
172
+ background: #7d396c;
163
173
  }
164
174
 
165
175
  .button-logs:disabled {
166
- color: rgba(120, 131, 142, .3);
167
- background: rgba(120, 131, 142, .3);
168
- cursor: not-allowed;
176
+ color: rgba(120, 131, 142, 0.3);
177
+ background: rgba(120, 131, 142, 0.3);
178
+ cursor: not-allowed;
169
179
  }
170
180
 
171
181
  .button-logout {
172
- background: #2c649e;
182
+ background: #2c649e;
173
183
  }
174
184
 
175
- .button-logout:hover, .button-logout:active, .button-logout:focus {
176
- background: #245282;
185
+ .button-logout:hover,
186
+ .button-logout:active,
187
+ .button-logout:focus {
188
+ background: #245282;
177
189
  }
178
190
 
179
191
  .formcontainer {
180
- text-align: center;
181
- padding-top: 0;
182
- padding-bottom: 30px;
183
- margin: 0 auto 0 auto;
192
+ text-align: center;
193
+ padding-top: 0;
194
+ padding-bottom: 30px;
195
+ margin: 0 auto 0 auto;
184
196
  }
185
197
 
186
198
  .sso-buttons {
187
- padding-bottom: 15px;
199
+ padding-bottom: 15px;
188
200
 
189
- display: flex;
190
- justify-content: center;
191
- align-items: center;
201
+ display: flex;
202
+ justify-content: center;
203
+ align-items: center;
192
204
  }
193
205
 
194
206
  .sso-buttons .g_id_signin div {
195
- margin: 0 auto;
207
+ margin: 0 auto;
196
208
  }
197
209
 
198
210
  a {
199
- color: #000000;
211
+ color: #000000;
200
212
  }
201
213
 
202
214
  #log-modal {
203
- display: none;
204
- background: rgba(3, 17, 3, 0.8);
205
- position: absolute;
206
- top: 0;
207
- bottom: 0;
208
- left: 0;
209
- right: 0;
210
- border-radius: 3px;
211
- border: 0;
212
- margin: 20px;
215
+ display: none;
216
+ background: rgba(3, 17, 3, 0.8);
217
+ position: absolute;
218
+ top: 0;
219
+ bottom: 0;
220
+ left: 0;
221
+ right: 0;
222
+ border-radius: 3px;
223
+ border: 0;
224
+ margin: 20px;
213
225
  }
214
226
 
215
227
  #log-output {
216
- margin: 20px;
217
- color: #bbbbbb;
218
- overflow: auto;
219
- font-family: Courier, monospace;
220
- font-size: 12px;
221
- white-space: nowrap;
222
- line-height: 16px;
223
- height: calc(100% - 150px);
228
+ margin: 20px;
229
+ color: #bbbbbb;
230
+ overflow: auto;
231
+ font-family: Courier, monospace;
232
+ font-size: 12px;
233
+ white-space: nowrap;
234
+ line-height: 16px;
235
+ height: calc(100% - 150px);
224
236
  }
225
237
 
226
238
  .log-buttons {
227
- position: absolute;
228
- bottom: 0;
229
- margin: 0;
230
- left: 50%;
231
- -ms-transform: translate(-50%, -50%);
232
- transform: translate(-50%, -50%);
233
- display: flex;
239
+ position: absolute;
240
+ bottom: 0;
241
+ margin: 0;
242
+ left: 50%;
243
+ -ms-transform: translate(-50%, -50%);
244
+ transform: translate(-50%, -50%);
245
+ display: flex;
234
246
  }
235
247
 
236
248
  .log-buttons .button {
237
- margin-left: 10px;
238
- margin-right: 10px;
239
- }
249
+ margin-left: 10px;
250
+ margin-right: 10px;
251
+ }
@@ -1,8 +1,6 @@
1
- import * as fs from "fs";
2
- import {expect, test, vi} from 'vitest';
1
+ import {expect, test, vi} from "vitest";
3
2
  import {populateUserMap} from "../src/auth/external";
4
- import { logger } from '../src/util';
5
- import winston from 'winston';
3
+ import {logger} from "../src/util";
6
4
 
7
5
  const userMapString = `
8
6
  # foo
@@ -16,32 +14,35 @@ jane janeuser # comment about Jane
16
14
  badline
17
15
  badlinewithcomment # comment
18
16
 
19
- `
17
+ `;
20
18
 
21
- vi.mock('fs', () => ({
22
- readFileSync: vi.fn((file_name) => {
19
+ vi.mock("fs", () => ({
20
+ readFileSync: vi.fn(_file_name => {
23
21
  return userMapString;
24
22
  })
25
- }))
23
+ }));
26
24
 
27
25
  const logWarn = vi.spyOn(logger, "warning").mockImplementation(vi.fn());
28
26
  const logInfo = vi.spyOn(logger, "info").mockImplementation(vi.fn());
29
27
 
30
- test('Parse user mapping table file', () => {
28
+ test("Parse user mapping table file", () => {
31
29
  const userMaps = new Map();
32
30
  const expectedMaps = new Map([
33
- ["test_issuer", new Map([
34
- ["alice", "aliceuser"],
35
- ["Bob", "bobuser"],
36
- ["carol", "caroluser"],
37
- ["emma", "emmauser"],
38
- ["Rosalind Franklin", "rfranklin"],
39
- ["jane", "janeuser"]
40
- ])]
31
+ [
32
+ "test_issuer",
33
+ new Map([
34
+ ["alice", "aliceuser"],
35
+ ["Bob", "bobuser"],
36
+ ["carol", "caroluser"],
37
+ ["emma", "emmauser"],
38
+ ["Rosalind Franklin", "rfranklin"],
39
+ ["jane", "janeuser"]
40
+ ])
41
+ ]
41
42
  ]);
42
43
 
43
44
  populateUserMap(userMaps, "test_issuer", "dummy path");
44
-
45
+
45
46
  expect(userMaps).toStrictEqual(expectedMaps);
46
47
  expect(logWarn).toHaveBeenNthCalledWith(1, "Ignoring malformed usermap line: badline");
47
48
  expect(logWarn).toHaveBeenNthCalledWith(2, "Ignoring malformed usermap line: badlinewithcomment");
package/.prettierrc.json DELETED
@@ -1,18 +0,0 @@
1
- {
2
- "arrowParens": "avoid",
3
- "bracketSpacing": false,
4
- "embeddedLanguageFormatting": "auto",
5
- "htmlWhitespaceSensitivity": "css",
6
- "insertPragma": false,
7
- "bracketSameLine": false,
8
- "jsxSingleQuote": false,
9
- "proseWrap": "preserve",
10
- "quoteProps": "as-needed",
11
- "requirePragma": false,
12
- "semi": true,
13
- "singleQuote": false,
14
- "trailingComma": "none",
15
- "useTabs": false,
16
- "printWidth": 240,
17
- "tabWidth": 4
18
- }