@sanvika/auth 2.5.0 → 2.5.1
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/dist/index.js +3 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -143,6 +143,7 @@ styleInject("@keyframes snvk-shimmer {\n 0% {\n background-position: 200% 0;
|
|
|
143
143
|
|
|
144
144
|
// SanvikaAccountButton.jsx
|
|
145
145
|
import { jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
146
|
+
var S_AUTH_URL2 = "https://accounts.sanvikaproduction.com";
|
|
146
147
|
var SanvikaAccountButtonErrorBoundary = class extends Component {
|
|
147
148
|
constructor(props) {
|
|
148
149
|
super(props);
|
|
@@ -273,8 +274,8 @@ function SanvikaAccountButtonContent({
|
|
|
273
274
|
setImgError(false);
|
|
274
275
|
}
|
|
275
276
|
if (!isAuthenticated || loading) {
|
|
276
|
-
const { clientId, redirectUri
|
|
277
|
-
const authorizeUrl = clientId && redirectUri ? `${
|
|
277
|
+
const { clientId, redirectUri } = auth;
|
|
278
|
+
const authorizeUrl = clientId && redirectUri ? `${S_AUTH_URL2}/authorize?client_id=${encodeURIComponent(clientId)}&redirect_uri=${encodeURIComponent(redirectUri)}` : `${S_AUTH_URL2}/authorize`;
|
|
278
279
|
return /* @__PURE__ */ jsxs(
|
|
279
280
|
"button",
|
|
280
281
|
{
|