keycloakify 9.4.0-rc.16 → 9.4.0-rc.17

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,3 +1,2 @@
1
- import { BASE_URL } from "./BASE_URL";
2
- export const isStorybook = BASE_URL.startsWith(".");
1
+ export const isStorybook = typeof window === "object" && Object.keys(window).find(key => key.startsWith("__STORYBOOK")) !== undefined;
3
2
  //# sourceMappingURL=isStorybook.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"isStorybook.js","sourceRoot":"","sources":["../src/lib/isStorybook.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,MAAM,CAAC,MAAM,WAAW,GAAG,QAAQ,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC"}
1
+ {"version":3,"file":"isStorybook.js","sourceRoot":"","sources":["../src/lib/isStorybook.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,WAAW,GAAG,OAAO,MAAM,KAAK,QAAQ,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC,KAAK,SAAS,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "keycloakify",
3
- "version": "9.4.0-rc.16",
3
+ "version": "9.4.0-rc.17",
4
4
  "description": "Create Keycloak themes using React",
5
5
  "repository": {
6
6
  "type": "git",
@@ -1,3 +1 @@
1
- import { BASE_URL } from "./BASE_URL";
2
-
3
- export const isStorybook = BASE_URL.startsWith(".");
1
+ export const isStorybook = typeof window === "object" && Object.keys(window).find(key => key.startsWith("__STORYBOOK")) !== undefined;