keycloakify 5.3.2 → 5.4.2
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 +12 -0
- package/bin/build-keycloak-theme/generateFtl/ftl_object_to_js_code_declaring_an_object.ftl +30 -1
- package/lib/getKcContext/KcContextBase.d.ts +3 -3
- package/package.json +6 -10
- package/src/bin/build-keycloak-theme/generateFtl/ftl_object_to_js_code_declaring_an_object.ftl +30 -1
- package/src/lib/getKcContext/KcContextBase.ts +3 -3
- package/bin/tools/createOctokit.d.ts +0 -5
- package/bin/tools/createOctokit.js +0 -21
- package/bin/tools/createOctokit.js.map +0 -1
- package/src/bin/tools/createOctokit.ts +0 -7
package/CHANGELOG.md
CHANGED
@@ -124,9 +124,11 @@ ${ftl_object_to_js_code_declaring_an_object(.data_model, [])?no_esc};
|
|
124
124
|
) || (
|
125
125
|
<#-- https://github.com/InseeFrLab/keycloakify/pull/65#issuecomment-991896344 (reports with saml-post-form.ftl) -->
|
126
126
|
<#-- https://github.com/InseeFrLab/keycloakify/issues/91#issue-1212319466 (reports with error.ftl and Kc18) -->
|
127
|
+
<#-- https://github.com/InseeFrLab/keycloakify/issues/109#issuecomment-1134610163 -->
|
127
128
|
key == "loginAction" &&
|
128
129
|
are_same_path(path, ["url"]) &&
|
129
|
-
["saml-post-form.ftl", "error.ftl"]?seq_contains(pageId)
|
130
|
+
["saml-post-form.ftl", "error.ftl", "info.ftl"]?seq_contains(pageId) &&
|
131
|
+
!(auth?has_content && auth.showTryAnotherWayLink())
|
130
132
|
) || (
|
131
133
|
["contextData", "idpConfig", "idp", "authenticationSession"]?seq_contains(key) &&
|
132
134
|
are_same_path(path, ["brokerContext"]) &&
|
@@ -152,6 +154,33 @@ ${ftl_object_to_js_code_declaring_an_object(.data_model, [])?no_esc};
|
|
152
154
|
</#attempt>
|
153
155
|
|
154
156
|
</#if>
|
157
|
+
|
158
|
+
<#if key == "showUsername" && are_same_path(path, ["auth"])>
|
159
|
+
<#attempt>
|
160
|
+
<#return auth.showUsername()?c>
|
161
|
+
<#recover>
|
162
|
+
<#local out_seq += ["/*Couldn't evaluate auth.showUsername()*/"]>
|
163
|
+
<#continue>
|
164
|
+
</#attempt>
|
165
|
+
</#if>
|
166
|
+
|
167
|
+
<#if key == "showResetCredentials" && are_same_path(path, ["auth"])>
|
168
|
+
<#attempt>
|
169
|
+
<#return auth.showResetCredentials()?c>
|
170
|
+
<#recover>
|
171
|
+
<#local out_seq += ["/*Couldn't evaluate auth.showResetCredentials()*/"]>
|
172
|
+
<#continue>
|
173
|
+
</#attempt>
|
174
|
+
</#if>
|
175
|
+
|
176
|
+
<#if key == "showTryAnotherWayLink" && are_same_path(path, ["auth"])>
|
177
|
+
<#attempt>
|
178
|
+
<#return auth.showTryAnotherWayLink()?c>
|
179
|
+
<#recover>
|
180
|
+
<#local out_seq += ["/*Couldn't evaluate auth.showTryAnotherWayLink()*/"]>
|
181
|
+
<#continue>
|
182
|
+
</#attempt>
|
183
|
+
</#if>
|
155
184
|
|
156
185
|
<#attempt>
|
157
186
|
<#if !object[key]??>
|
@@ -32,9 +32,9 @@ export declare namespace KcContextBase {
|
|
32
32
|
currentLanguageTag: KcLanguageTag;
|
33
33
|
};
|
34
34
|
auth?: {
|
35
|
-
showUsername
|
36
|
-
showResetCredentials
|
37
|
-
showTryAnotherWayLink
|
35
|
+
showUsername?: boolean;
|
36
|
+
showResetCredentials?: boolean;
|
37
|
+
showTryAnotherWayLink?: boolean;
|
38
38
|
attemptedUsername?: string;
|
39
39
|
};
|
40
40
|
scripts: string[];
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "keycloakify",
|
3
|
-
"version": "5.
|
3
|
+
"version": "5.4.2",
|
4
4
|
"description": "Keycloak theme generator for Reacts app",
|
5
5
|
"repository": {
|
6
6
|
"type": "git",
|
@@ -43,7 +43,6 @@
|
|
43
43
|
"src/bin/promptKeycloakVersion.ts",
|
44
44
|
"src/bin/tools/NpmModuleVersion.ts",
|
45
45
|
"src/bin/tools/crawl.ts",
|
46
|
-
"src/bin/tools/createOctokit.ts",
|
47
46
|
"src/bin/tools/downloadAndUnzip.ts",
|
48
47
|
"src/bin/tools/getProjectRoot.ts",
|
49
48
|
"src/bin/tools/grant-exec-perms.ts",
|
@@ -150,9 +149,6 @@
|
|
150
149
|
"bin/tools/crawl.d.ts",
|
151
150
|
"bin/tools/crawl.js",
|
152
151
|
"bin/tools/crawl.js.map",
|
153
|
-
"bin/tools/createOctokit.d.ts",
|
154
|
-
"bin/tools/createOctokit.js",
|
155
|
-
"bin/tools/createOctokit.js.map",
|
156
152
|
"bin/tools/downloadAndUnzip.d.ts",
|
157
153
|
"bin/tools/downloadAndUnzip.js",
|
158
154
|
"bin/tools/downloadAndUnzip.js.map",
|
@@ -338,7 +334,7 @@
|
|
338
334
|
"homepage": "https://github.com/garronej/keycloakify",
|
339
335
|
"peerDependencies": {
|
340
336
|
"@emotion/react": "^11.4.1",
|
341
|
-
"react": "^16.8.0 || ^17.0.0"
|
337
|
+
"react": "^16.8.0 || ^17.0.0 || ^18.0.0"
|
342
338
|
},
|
343
339
|
"devDependencies": {
|
344
340
|
"@emotion/react": "^11.4.1",
|
@@ -358,14 +354,14 @@
|
|
358
354
|
"@octokit/rest": "^18.12.0",
|
359
355
|
"cheerio": "^1.0.0-rc.5",
|
360
356
|
"cli-select": "^1.1.2",
|
361
|
-
"evt": "2.0.0-beta.
|
357
|
+
"evt": "2.0.0-beta.43",
|
362
358
|
"memoizee": "^0.4.15",
|
363
359
|
"minimal-polyfills": "^2.2.1",
|
364
360
|
"path-browserify": "^1.0.1",
|
365
|
-
"powerhooks": "^0.
|
361
|
+
"powerhooks": "^0.17.1",
|
366
362
|
"react-markdown": "^5.0.3",
|
367
363
|
"scripting-tools": "^0.19.13",
|
368
|
-
"tsafe": "^0.
|
369
|
-
"tss-react": "^3.
|
364
|
+
"tsafe": "^0.10.0",
|
365
|
+
"tss-react": "^3.7.0"
|
370
366
|
}
|
371
367
|
}
|
package/src/bin/build-keycloak-theme/generateFtl/ftl_object_to_js_code_declaring_an_object.ftl
CHANGED
@@ -124,9 +124,11 @@ ${ftl_object_to_js_code_declaring_an_object(.data_model, [])?no_esc};
|
|
124
124
|
) || (
|
125
125
|
<#-- https://github.com/InseeFrLab/keycloakify/pull/65#issuecomment-991896344 (reports with saml-post-form.ftl) -->
|
126
126
|
<#-- https://github.com/InseeFrLab/keycloakify/issues/91#issue-1212319466 (reports with error.ftl and Kc18) -->
|
127
|
+
<#-- https://github.com/InseeFrLab/keycloakify/issues/109#issuecomment-1134610163 -->
|
127
128
|
key == "loginAction" &&
|
128
129
|
are_same_path(path, ["url"]) &&
|
129
|
-
["saml-post-form.ftl", "error.ftl"]?seq_contains(pageId)
|
130
|
+
["saml-post-form.ftl", "error.ftl", "info.ftl"]?seq_contains(pageId) &&
|
131
|
+
!(auth?has_content && auth.showTryAnotherWayLink())
|
130
132
|
) || (
|
131
133
|
["contextData", "idpConfig", "idp", "authenticationSession"]?seq_contains(key) &&
|
132
134
|
are_same_path(path, ["brokerContext"]) &&
|
@@ -152,6 +154,33 @@ ${ftl_object_to_js_code_declaring_an_object(.data_model, [])?no_esc};
|
|
152
154
|
</#attempt>
|
153
155
|
|
154
156
|
</#if>
|
157
|
+
|
158
|
+
<#if key == "showUsername" && are_same_path(path, ["auth"])>
|
159
|
+
<#attempt>
|
160
|
+
<#return auth.showUsername()?c>
|
161
|
+
<#recover>
|
162
|
+
<#local out_seq += ["/*Couldn't evaluate auth.showUsername()*/"]>
|
163
|
+
<#continue>
|
164
|
+
</#attempt>
|
165
|
+
</#if>
|
166
|
+
|
167
|
+
<#if key == "showResetCredentials" && are_same_path(path, ["auth"])>
|
168
|
+
<#attempt>
|
169
|
+
<#return auth.showResetCredentials()?c>
|
170
|
+
<#recover>
|
171
|
+
<#local out_seq += ["/*Couldn't evaluate auth.showResetCredentials()*/"]>
|
172
|
+
<#continue>
|
173
|
+
</#attempt>
|
174
|
+
</#if>
|
175
|
+
|
176
|
+
<#if key == "showTryAnotherWayLink" && are_same_path(path, ["auth"])>
|
177
|
+
<#attempt>
|
178
|
+
<#return auth.showTryAnotherWayLink()?c>
|
179
|
+
<#recover>
|
180
|
+
<#local out_seq += ["/*Couldn't evaluate auth.showTryAnotherWayLink()*/"]>
|
181
|
+
<#continue>
|
182
|
+
</#attempt>
|
183
|
+
</#if>
|
155
184
|
|
156
185
|
<#attempt>
|
157
186
|
<#if !object[key]??>
|
@@ -52,9 +52,9 @@ export declare namespace KcContextBase {
|
|
52
52
|
currentLanguageTag: KcLanguageTag;
|
53
53
|
};
|
54
54
|
auth?: {
|
55
|
-
showUsername
|
56
|
-
showResetCredentials
|
57
|
-
showTryAnotherWayLink
|
55
|
+
showUsername?: boolean;
|
56
|
+
showResetCredentials?: boolean;
|
57
|
+
showTryAnotherWayLink?: boolean;
|
58
58
|
attemptedUsername?: string;
|
59
59
|
};
|
60
60
|
scripts: string[];
|
@@ -1,5 +0,0 @@
|
|
1
|
-
export declare function createOctokit(params: {
|
2
|
-
github_token: string;
|
3
|
-
}): import("@octokit/core").Octokit & {
|
4
|
-
paginate: import("@octokit/plugin-paginate-rest").PaginateInterface;
|
5
|
-
} & import("@octokit/plugin-rest-endpoint-methods/dist-types/generated/method-types").RestEndpointMethods & import("@octokit/plugin-rest-endpoint-methods/dist-types/types").Api;
|
@@ -1,21 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
var __assign = (this && this.__assign) || function () {
|
3
|
-
__assign = Object.assign || function(t) {
|
4
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
5
|
-
s = arguments[i];
|
6
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
7
|
-
t[p] = s[p];
|
8
|
-
}
|
9
|
-
return t;
|
10
|
-
};
|
11
|
-
return __assign.apply(this, arguments);
|
12
|
-
};
|
13
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
14
|
-
exports.createOctokit = void 0;
|
15
|
-
var rest_1 = require("@octokit/rest");
|
16
|
-
function createOctokit(params) {
|
17
|
-
var github_token = params.github_token;
|
18
|
-
return new rest_1.Octokit(__assign({}, (github_token !== "" ? { "auth": github_token } : {})));
|
19
|
-
}
|
20
|
-
exports.createOctokit = createOctokit;
|
21
|
-
//# sourceMappingURL=createOctokit.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"createOctokit.js","sourceRoot":"","sources":["../../src/bin/tools/createOctokit.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,sCAAwC;AAExC,SAAgB,aAAa,CAAC,MAAgC;IAClD,IAAA,YAAY,GAAK,MAAM,aAAX,CAAY;IAEhC,OAAO,IAAI,cAAO,cAAM,CAAC,YAAY,KAAK,EAAE,CAAC,CAAC,CAAC,EAAE,MAAM,EAAE,YAAY,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,EAAG,CAAC;AACrF,CAAC;AAJD,sCAIC"}
|