@digipair/skill-keycloak 0.66.1 → 0.66.3

Sign up to get free protection for your applications and to get access to all the features.
package/index.cjs.js CHANGED
@@ -16714,15 +16714,6 @@ let KeycloakService = class KeycloakService {
16714
16714
  setTimeout(async () => {
16715
16715
  await executePinsList(${JSON.stringify(this.prepareBrowserPinsSettings('browserLoad', browserLoad))}, context);
16716
16716
  }, 1);
16717
-
16718
- window.addEventListener('beforeunload', async (event) => {
16719
- const showConfirmationMessage = await executePinsList(${JSON.stringify(this.prepareBrowserPinsSettings('confirmBeforeUnload', confirmBeforeUnload))}, context);
16720
-
16721
- if (showConfirmationMessage) {
16722
- event.preventDefault();
16723
- event.returnValue = '';
16724
- }
16725
- });
16726
16717
  </script>
16727
16718
 
16728
16719
  ${ssr ? await this.pins2html(body, context) : ''}
package/index.esm.js CHANGED
@@ -23907,14 +23907,14 @@ function indent(str, spaces) {
23907
23907
  var match = parseIdentifier(input, i1, namePart) || namePart && parseAdditionalSymbol(input, i1) || maybeSpace && parseSpaces(input, i1);
23908
23908
  // match is required
23909
23909
  if (!match) {
23910
- return nextMatch = nextMatch1, tokens = tokens1, i = i1, {
23910
+ return nextMatch = nextMatch1, i = i1, tokens = tokens1, {
23911
23911
  v: nextMatch1
23912
23912
  };
23913
23913
  }
23914
23914
  var token = match.token, offset = match.offset;
23915
23915
  i1 += offset;
23916
23916
  if (token === " ") {
23917
- return nextMatch = nextMatch1, tokens = tokens1, i = i1, "continue";
23917
+ return nextMatch = nextMatch1, i = i1, tokens = tokens1, "continue";
23918
23918
  }
23919
23919
  tokens1 = _to_consumable_array$3(tokens1).concat([
23920
23920
  token
@@ -23933,7 +23933,7 @@ function indent(str, spaces) {
23933
23933
  if (contextKeys.some(function(el) {
23934
23934
  return el.startsWith(name);
23935
23935
  })) {
23936
- return nextMatch = nextMatch1, tokens = tokens1, i = i1, "continue";
23936
+ return nextMatch = nextMatch1, i = i1, tokens = tokens1, "continue";
23937
23937
  }
23938
23938
  if (dateTimeIdentifiers.some(function(el) {
23939
23939
  return el === name;
@@ -23952,9 +23952,9 @@ function indent(str, spaces) {
23952
23952
  if (dateTimeIdentifiers.some(function(el) {
23953
23953
  return el.startsWith(name);
23954
23954
  })) {
23955
- return nextMatch = nextMatch1, tokens = tokens1, i = i1, "continue";
23955
+ return nextMatch = nextMatch1, i = i1, tokens = tokens1, "continue";
23956
23956
  }
23957
- return nextMatch = nextMatch1, tokens = tokens1, i = i1, {
23957
+ return nextMatch = nextMatch1, i = i1, tokens = tokens1, {
23958
23958
  v: nextMatch1
23959
23959
  };
23960
23960
  };
@@ -27884,12 +27884,12 @@ const applyTemplate = (value, context)=>{
27884
27884
  };
27885
27885
  const executePins = async (settingsOrigin, context = {})=>{
27886
27886
  var _settings_conditions, _settings_conditions1;
27887
- let settings = await preparePinsSettings(settingsOrigin, context);
27887
+ let settings = preparePinsSettings(settingsOrigin, context);
27888
27888
  const alias = _config.ALIAS.find((alias)=>settings.library.split(':')[0] === alias.name);
27889
27889
  const config = context.config || {};
27890
27890
  let version = (config.VERSIONS || {})[settings.library] || 'latest';
27891
27891
  if (alias) {
27892
- settings = await preparePinsSettings(_extends({}, settings, alias), {
27892
+ settings = preparePinsSettings(_extends({}, settings, alias), {
27893
27893
  settings: _extends({}, settings, {
27894
27894
  version,
27895
27895
  library: settings.library.substring(alias.name.length + 1)
@@ -27916,7 +27916,7 @@ const executePins = async (settingsOrigin, context = {})=>{
27916
27916
  parent: context.parent
27917
27917
  }
27918
27918
  });
27919
- const itemSettings = await preparePinsSettings(itemSettingsOrigin, itemContext);
27919
+ const itemSettings = preparePinsSettings(itemSettingsOrigin, itemContext);
27920
27920
  if (typeof ((_itemSettings_conditions = itemSettings.conditions) == null ? void 0 : _itemSettings_conditions.if) !== 'undefined' && !itemSettings.conditions.if) {
27921
27921
  continue;
27922
27922
  }
@@ -27945,7 +27945,6 @@ const executePins = async (settingsOrigin, context = {})=>{
27945
27945
  };
27946
27946
  const executePinsList = async (pinsSettingsList, context)=>{
27947
27947
  let previous = {};
27948
- // parcourir tous les pins
27949
27948
  for(let i = 0; i < pinsSettingsList.length; i++){
27950
27949
  const settings = pinsSettingsList[i];
27951
27950
  try {
@@ -27969,10 +27968,10 @@ const generateElementFromPins = async (pinsSettings, parent, context, document =
27969
27968
  import: true
27970
27969
  })=>{
27971
27970
  var _settings_conditions, _settings_conditions1;
27972
- let settings = await preparePinsSettings(pinsSettings, context);
27971
+ let settings = preparePinsSettings(pinsSettings, context);
27973
27972
  const alias = _config.ALIAS.find((alias)=>settings.library.split(':')[0] === alias.name);
27974
27973
  if (alias) {
27975
- settings = await preparePinsSettings(_extends({}, settings, alias), {
27974
+ settings = preparePinsSettings(_extends({}, settings, alias), {
27976
27975
  settings
27977
27976
  });
27978
27977
  }
@@ -28039,14 +28038,14 @@ const generateElementFromPins = async (pinsSettings, parent, context, document =
28039
28038
  }
28040
28039
  return element;
28041
28040
  };
28042
- const preparePinsSettings = async (settings, context)=>{
28041
+ const preparePinsSettings = (settings, context)=>{
28043
28042
  const localContext = _extends({}, context, {
28044
28043
  variables: context.variables || {},
28045
28044
  conditions: context.conditions || {}
28046
28045
  });
28047
28046
  const conditions = {};
28048
28047
  for (const [key, value] of Object.entries(settings.conditions || {})){
28049
- conditions[key] = await applyTemplate(value, localContext);
28048
+ conditions[key] = applyTemplate(value, localContext);
28050
28049
  }
28051
28050
  const properties = {};
28052
28051
  for (const [key, value] of Object.entries(settings.properties || {})){
@@ -44742,15 +44741,6 @@ let KeycloakService = class KeycloakService {
44742
44741
  setTimeout(async () => {
44743
44742
  await executePinsList(${JSON.stringify(this.prepareBrowserPinsSettings('browserLoad', browserLoad))}, context);
44744
44743
  }, 1);
44745
-
44746
- window.addEventListener('beforeunload', async (event) => {
44747
- const showConfirmationMessage = await executePinsList(${JSON.stringify(this.prepareBrowserPinsSettings('confirmBeforeUnload', confirmBeforeUnload))}, context);
44748
-
44749
- if (showConfirmationMessage) {
44750
- event.preventDefault();
44751
- event.returnValue = '';
44752
- }
44753
- });
44754
44744
  </script>
44755
44745
 
44756
44746
  ${ssr ? await this.pins2html(body, context) : ''}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@digipair/skill-keycloak",
3
- "version": "0.66.1",
3
+ "version": "0.66.3",
4
4
  "dependencies": {
5
5
  "jsdom": "^25.0.1"
6
6
  },