nsarrazin commited on
Commit
db9d593
·
1 Parent(s): e1c53b8

refactor: update publicConfig checks for HuggingChat in modals and nav menu

Browse files
src/lib/components/DisclaimerModal.svelte CHANGED
@@ -62,7 +62,7 @@
62
  class="flex w-full flex-wrap items-center justify-center whitespace-nowrap rounded-full border-2 border-black bg-black px-5 py-2 text-lg font-semibold text-gray-100 transition-colors hover:bg-gray-900"
63
  >
64
  Sign in
65
- {#if publicConfig.PUBLIC_APP_NAME === "HuggingChat"}
66
  <span class="flex items-center">
67
  &nbsp;with <LogoHuggingFaceBorderless classNames="text-xl mr-1 ml-1.5 flex-none" /> Hugging
68
  Face
 
62
  class="flex w-full flex-wrap items-center justify-center whitespace-nowrap rounded-full border-2 border-black bg-black px-5 py-2 text-lg font-semibold text-gray-100 transition-colors hover:bg-gray-900"
63
  >
64
  Sign in
65
+ {#if publicConfig.isHuggingChat}
66
  <span class="flex items-center">
67
  &nbsp;with <LogoHuggingFaceBorderless classNames="text-xl mr-1 ml-1.5 flex-none" /> Hugging
68
  Face
src/lib/components/LoginModal.svelte CHANGED
@@ -39,7 +39,7 @@
39
  class="flex w-full flex-wrap items-center justify-center whitespace-nowrap rounded-full bg-black px-5 py-2 text-center text-lg font-semibold text-gray-100 transition-colors hover:bg-gray-900"
40
  >
41
  Sign in
42
- {#if publicConfig.PUBLIC_APP_NAME === "HuggingChat"}
43
  <span class="flex items-center">
44
  &nbsp;with <LogoHuggingFaceBorderless classNames="text-xl mr-1 ml-1.5" /> Hugging Face
45
  </span>
 
39
  class="flex w-full flex-wrap items-center justify-center whitespace-nowrap rounded-full bg-black px-5 py-2 text-center text-lg font-semibold text-gray-100 transition-colors hover:bg-gray-900"
40
  >
41
  Sign in
42
+ {#if publicConfig.isHuggingChat}
43
  <span class="flex items-center">
44
  &nbsp;with <LogoHuggingFaceBorderless classNames="text-xl mr-1 ml-1.5" /> Hugging Face
45
  </span>
src/lib/components/NavMenu.svelte CHANGED
@@ -217,7 +217,7 @@
217
  >
218
  Settings
219
  </a>
220
- {#if publicConfig.PUBLIC_APP_NAME === "HuggingChat"}
221
  <a
222
  href="{base}/privacy"
223
  class="flex h-9 flex-none items-center gap-1.5 rounded-lg pl-2.5 pr-2 text-gray-500 hover:bg-gray-100 dark:text-gray-400 dark:hover:bg-gray-700"
 
217
  >
218
  Settings
219
  </a>
220
+ {#if publicConfig.isHuggingChat}
221
  <a
222
  href="{base}/privacy"
223
  class="flex h-9 flex-none items-center gap-1.5 rounded-lg pl-2.5 pr-2 text-gray-500 hover:bg-gray-100 dark:text-gray-400 dark:hover:bg-gray-700"