Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump ra-keycloak from 1.0.1 to 2.0.0 #586

Closed
wants to merge 1 commit into from

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Oct 28, 2024

Bumps ra-keycloak from 1.0.1 to 2.0.0.

Release notes

Sourced from ra-keycloak's releases.

2.0.0

  • Upgrade react-admin to v5
  • Upgrade keycloak-js to v26
  • Remove prop-types

Breaking changes

The setup has been drastically simplified:

-import React, { useState, useRef, useEffect } from 'react';
+import React from 'react';
import { Admin } from 'react-admin';
import simpleRestProvider from 'ra-data-simple-rest';
import Keycloak, {
    KeycloakConfig,
    KeycloakTokenParsed,
    KeycloakInitOptions,
} from 'keycloak-js';
-import { keycloakAuthProvider, httpClient } from 'ra-keycloak';
+import { keycloakAuthProvider, httpClient, LoginPage } from 'ra-keycloak';
const config: KeycloakConfig = {
url: '$KEYCLOAK_URL',
realm: '$KEYCLOAK_REALM',
clientId: '$KEYCLOAK_CLIENT_ID',
};
-const initOptions: KeycloakInitOptions = { onLoad: 'login-required' };
+const initOptions: KeycloakInitOptions = { onLoad: 'check-sso' };
// here you can implement the permission mapping logic for react-admin
const getPermissions = (decoded: KeycloakTokenParsed) => {
const roles = decoded?.realm_access?.roles;
if (!roles) {
return false;
}
if (roles.includes('admin')) return 'admin';
if (roles.includes('user')) return 'user';
return false;
};
const App = () => {

const [keycloak, setKeycloak] = useState<Keycloak>(undefined);
const authProvider = useRef<AuthProvider>(undefined);
const dataProvider = useRef<DataProvider>(undefined);


const keycloakClient = new Keycloak(config);
const authProvider = keycloakAuthProvider(keycloakClient, {

   initOptions,



   onPermissions: getPermissions,



</tr></table>

... (truncated)

Changelog

Sourced from ra-keycloak's changelog.

2.0.0

  • Upgrade react-admin to v5
  • Upgrade keycloak-js to v26
  • Remove prop-types

Breaking changes

The setup has been drastically simplified:

-import React, { useState, useRef, useEffect } from 'react';
+import React from 'react';
import { Admin } from 'react-admin';
import simpleRestProvider from 'ra-data-simple-rest';
import Keycloak, {
    KeycloakConfig,
    KeycloakTokenParsed,
    KeycloakInitOptions,
} from 'keycloak-js';
-import { keycloakAuthProvider, httpClient } from 'ra-keycloak';
+import { keycloakAuthProvider, httpClient, LoginPage } from 'ra-keycloak';
const config: KeycloakConfig = {
url: '$KEYCLOAK_URL',
realm: '$KEYCLOAK_REALM',
clientId: '$KEYCLOAK_CLIENT_ID',
};
-const initOptions: KeycloakInitOptions = { onLoad: 'login-required' };
+const initOptions: KeycloakInitOptions = { onLoad: 'check-sso' };
// here you can implement the permission mapping logic for react-admin
const getPermissions = (decoded: KeycloakTokenParsed) => {
const roles = decoded?.realm_access?.roles;
if (!roles) {
return false;
}
if (roles.includes('admin')) return 'admin';
if (roles.includes('user')) return 'user';
return false;
};
const App = () => {

const [keycloak, setKeycloak] = useState<Keycloak>(undefined);
const authProvider = useRef<AuthProvider>(undefined);
const dataProvider = useRef<DataProvider>(undefined);


const keycloakClient = new Keycloak(config);
const authProvider = keycloakAuthProvider(keycloakClient, {

   initOptions,



</tr></table>

... (truncated)

Commits
  • 5b898d2 Merge pull request #10 from marmelab/keycloak-v2-changelog
  • 0f8ed7b Add last comment
  • 687bd58 Apply suggestions from code review
  • 07af25d Update changelog for v2
  • d3fa97d Merge pull request #9 from marmelab/upgrade-to-ra-v5
  • a99d7d6 fix redirect loop
  • 6f3354b Cleanup isAuthenticated
  • 9079531 Fix redirect from auth callback
  • 4e20135 Fix custom route datagrid usage
  • 65c1caa Fix vite config, getPermissions, anonymous custom route
  • Additional commits viewable in compare view
Maintainer changes

This version was pushed to npm by djhi, a new releaser for ra-keycloak since your current version.


Dependabot compatibility score

You can trigger a rebase of this PR by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Note
Automatic rebases have been disabled on this pull request as it has been open for over 30 days.

@dependabot dependabot bot added the dependencies Pull requests that update a dependency file label Oct 28, 2024
@dependabot dependabot bot force-pushed the dependabot/npm_and_yarn/ra-keycloak-2.0.0 branch 2 times, most recently from 3799ffc to 05288af Compare November 11, 2024 15:07
@dependabot dependabot bot force-pushed the dependabot/npm_and_yarn/ra-keycloak-2.0.0 branch from 05288af to d1061eb Compare November 12, 2024 10:37
@dependabot dependabot bot force-pushed the dependabot/npm_and_yarn/ra-keycloak-2.0.0 branch 3 times, most recently from 7087138 to e7bb962 Compare November 26, 2024 16:11
@vdegraaf
Copy link
Collaborator

vdegraaf commented Jan 9, 2025

@dependabot rebase

Bumps [ra-keycloak](https://github.com/marmelab/ra-keycloak) from 1.0.1 to 2.0.0.
- [Release notes](https://github.com/marmelab/ra-keycloak/releases)
- [Changelog](https://github.com/marmelab/ra-keycloak/blob/main/CHANGELOG.md)
- [Commits](marmelab/ra-keycloak@v1.0.1...v2.0.0)

---
updated-dependencies:
- dependency-name: ra-keycloak
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot force-pushed the dependabot/npm_and_yarn/ra-keycloak-2.0.0 branch from e7bb962 to cf627a7 Compare January 9, 2025 13:34
@alimpens alimpens closed this Jan 13, 2025
Copy link
Contributor Author

dependabot bot commented on behalf of github Jan 13, 2025

OK, I won't notify you again about this release, but will get in touch when a new version is available. If you'd rather skip all updates until the next major or minor version, let me know by commenting @dependabot ignore this major version or @dependabot ignore this minor version. You can also ignore all major, minor, or patch releases for a dependency by adding an ignore condition with the desired update_types to your config file.

If you change your mind, just re-open this PR and I'll resolve any conflicts on it.

@dependabot dependabot bot deleted the dependabot/npm_and_yarn/ra-keycloak-2.0.0 branch January 13, 2025 15:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file
Development

Successfully merging this pull request may close these issues.

2 participants