@turnipxenon/pineapple 2.10.0 → 3.0.0-alpha-3

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.
Files changed (223) hide show
  1. package/dist/assets/icons/icon-check-dark-contrast.svg +1 -0
  2. package/dist/assets/icons/icon-check-light-contrast.svg +1 -0
  3. package/dist/assets/icons/icon-contrast.svg +1 -0
  4. package/dist/assets/icons/icon-copy-dark-contrast.svg +1 -0
  5. package/dist/assets/icons/icon-copy-light-contrast.svg +1 -0
  6. package/dist/assets/icons/icon-dark-mode.svg +1 -0
  7. package/dist/assets/icons/icon-light-mode.svg +1 -0
  8. package/dist/assets/icons/icon-settings.svg +1 -0
  9. package/dist/components/Card.svelte +43 -41
  10. package/dist/components/Card.svelte.d.ts +11 -24
  11. package/dist/components/CarouselElement.svelte +15 -8
  12. package/dist/components/CarouselElement.svelte.d.ts +7 -18
  13. package/dist/components/ElementVisbilityDetector.svelte +23 -14
  14. package/dist/components/ElementVisbilityDetector.svelte.d.ts +6 -17
  15. package/dist/components/LazyAsset.svelte +93 -65
  16. package/dist/components/LazyAsset.svelte.d.ts +9 -19
  17. package/dist/components/PineappleSlideToggle.svelte +28 -10
  18. package/dist/components/PineappleSlideToggle.svelte.d.ts +9 -19
  19. package/dist/components/RandomizedBackground.svelte +46 -27
  20. package/dist/components/RandomizedBackground.svelte.d.ts +5 -15
  21. package/dist/components/RandomizedImage.svelte +15 -8
  22. package/dist/components/RandomizedImage.svelte.d.ts +6 -16
  23. package/dist/components/StickyElement.svelte +25 -16
  24. package/dist/components/StickyElement.svelte.d.ts +6 -17
  25. package/dist/components/ToggleableContent.svelte +88 -59
  26. package/dist/components/ToggleableContent.svelte.d.ts +6 -17
  27. package/dist/components/blog_template/BlogTemplate.svelte +45 -25
  28. package/dist/components/blog_template/BlogTemplate.svelte.d.ts +9 -20
  29. package/dist/components/blog_template/BlogTemplateInner.svelte +11 -3
  30. package/dist/components/blog_template/BlogTemplateInner.svelte.d.ts +6 -17
  31. package/dist/components/chip/Chip.svelte +33 -57
  32. package/dist/components/chip/Chip.svelte.d.ts +7 -18
  33. package/dist/components/combo_box/ComboBox.svelte +10 -4
  34. package/dist/components/combo_box/ComboBox.svelte.d.ts +6 -16
  35. package/dist/components/combo_box/ComboBoxWithButton.svelte +16 -9
  36. package/dist/components/combo_box/ComboBoxWithButton.svelte.d.ts +7 -17
  37. package/dist/components/combo_box/combo-box.postcss +2 -2
  38. package/dist/components/dialog_manager/DialogManager.d.ts +0 -1
  39. package/dist/components/dialog_manager/DialogManagerStore.d.ts +0 -1
  40. package/dist/components/dialog_manager/DialogManagerStore.js +1 -1
  41. package/dist/components/dialog_overlay/DialogOverlay.svelte +42 -34
  42. package/dist/components/dialog_overlay/DialogOverlay.svelte.d.ts +3 -14
  43. package/dist/components/index.d.ts +1 -1
  44. package/dist/components/index.js +1 -1
  45. package/dist/components/layouts/SeaweedBaseLayout.svelte +80 -43
  46. package/dist/components/layouts/SeaweedBaseLayout.svelte.d.ts +8 -21
  47. package/dist/components/navigation_component/NavigationComponent.svelte +52 -141
  48. package/dist/components/navigation_component/NavigationComponent.svelte.d.ts +17 -26
  49. package/dist/components/navigation_component/NavigationControl.svelte +52 -103
  50. package/dist/components/navigation_component/NavigationControl.svelte.d.ts +7 -17
  51. package/dist/components/overrideable_meta/OverridableMeta.svelte +37 -22
  52. package/dist/components/overrideable_meta/OverridableMeta.svelte.d.ts +9 -19
  53. package/dist/components/pineapple/PineappleBaseLayout.svelte +132 -188
  54. package/dist/components/pineapple/PineappleBaseLayout.svelte.d.ts +6 -17
  55. package/dist/components/pineapple/toast/DefaultToastBody.svelte +14 -16
  56. package/dist/components/pineapple/toast/DefaultToastBody.svelte.d.ts +7 -17
  57. package/dist/components/pineapple/toast/Toast.d.ts +0 -1
  58. package/dist/components/pineapple/toast/Toast.svelte +92 -64
  59. package/dist/components/pineapple/toast/Toast.svelte.d.ts +3 -14
  60. package/dist/components/pineapple/toast/custom-toast/TestCustomToast.svelte.d.ts +22 -19
  61. package/dist/paraglide/messages/_index.d.ts +2 -0
  62. package/dist/paraglide/messages/_index.js +3 -0
  63. package/dist/paraglide/messages/example_message.d.ts +5 -0
  64. package/dist/paraglide/messages/example_message.js +39 -0
  65. package/dist/paraglide/messages/settings.d.ts +3 -0
  66. package/dist/paraglide/messages/settings.js +38 -0
  67. package/dist/paraglide/messages.d.ts +2 -0
  68. package/dist/paraglide/messages.js +4 -0
  69. package/dist/paraglide/registry.d.ts +21 -0
  70. package/dist/paraglide/registry.js +31 -0
  71. package/dist/paraglide/runtime.d.ts +400 -0
  72. package/dist/paraglide/runtime.js +1060 -0
  73. package/dist/paraglide/server.d.ts +64 -0
  74. package/dist/paraglide/server.js +161 -0
  75. package/dist/scripts/util/FileManagement.d.ts +1 -1
  76. package/dist/store.d.ts +0 -1
  77. package/dist/styles/app.css +144 -0
  78. package/dist/styles/turnip-theme.css +327 -0
  79. package/dist/template/seaweed/CreateUrlForm.svelte +59 -41
  80. package/dist/template/seaweed/CreateUrlForm.svelte.d.ts +8 -15
  81. package/dist/template/seaweed/SeaweedTemplate.svelte +244 -195
  82. package/dist/template/seaweed/SeaweedTemplate.svelte.d.ts +28 -25
  83. package/dist/template/seaweed/ToastSettings.d.ts +15 -0
  84. package/dist/template/seaweed/ToastSettings.js +1 -0
  85. package/dist/template/seaweed/entries/ChefWings.svelte +37 -39
  86. package/dist/template/seaweed/entries/ChefWings.svelte.d.ts +5 -15
  87. package/dist/template/seaweed/entries/CustomizedYarnspinner.svelte +32 -24
  88. package/dist/template/seaweed/entries/CustomizedYarnspinner.svelte.d.ts +5 -15
  89. package/dist/template/seaweed/entries/Hepcat.svelte +58 -49
  90. package/dist/template/seaweed/entries/Hepcat.svelte.d.ts +5 -15
  91. package/dist/template/seaweed/entries/Pengi.svelte +51 -43
  92. package/dist/template/seaweed/entries/Pengi.svelte.d.ts +5 -15
  93. package/dist/template/seaweed/entries/Soulwork.svelte +44 -36
  94. package/dist/template/seaweed/entries/Soulwork.svelte.d.ts +5 -15
  95. package/dist/template/seaweed/entries/ThisWebpage.svelte +47 -38
  96. package/dist/template/seaweed/entries/ThisWebpage.svelte.d.ts +5 -15
  97. package/dist/template/seaweed/entries/WorkExperience.svelte +109 -92
  98. package/dist/template/seaweed/entries/WorkExperience.svelte.d.ts +6 -16
  99. package/dist/template/seaweed/entries/Workset.svelte +51 -42
  100. package/dist/template/seaweed/entries/Workset.svelte.d.ts +5 -15
  101. package/dist/template/seaweed/entry_order_config/EntryOrderConfig.svelte +169 -259
  102. package/dist/template/seaweed/entry_order_config/EntryOrderConfig.svelte.d.ts +10 -21
  103. package/dist/template/seaweed/seaweed.postcss +1 -9
  104. package/dist/{theme.postcss → theme.css} +1 -4
  105. package/dist/ui/components/FourPartCard.svelte +47 -0
  106. package/dist/ui/components/FourPartCard.svelte.d.ts +10 -0
  107. package/dist/ui/components/ModalBase.svelte +75 -0
  108. package/dist/ui/components/ModalBase.svelte.d.ts +8 -0
  109. package/dist/ui/components/SocialSection.svelte +87 -0
  110. package/dist/ui/components/SocialSection.svelte.d.ts +9 -0
  111. package/dist/ui/components/index.d.ts +3 -0
  112. package/dist/ui/components/index.js +3 -0
  113. package/dist/ui/components/randomized-background/RandomizedBackground.svelte +87 -0
  114. package/dist/ui/components/randomized-background/RandomizedBackground.svelte.d.ts +6 -0
  115. package/dist/ui/components/randomized-background/RandomizedImage.svelte +42 -0
  116. package/dist/ui/components/randomized-background/RandomizedImage.svelte.d.ts +7 -0
  117. package/dist/ui/elements/CodeBlock/CodeBlock.svelte +65 -0
  118. package/dist/ui/elements/CodeBlock/CodeBlock.svelte.d.ts +5 -0
  119. package/dist/ui/elements/CodeBlock/CodeBlockProps.d.ts +11 -0
  120. package/dist/ui/elements/CodeBlock/CodeBlockProps.js +1 -0
  121. package/dist/ui/elements/CodeBlock/index.d.ts +2 -0
  122. package/dist/ui/elements/CodeBlock/index.js +2 -0
  123. package/dist/ui/elements/ColorScheme.d.ts +10 -0
  124. package/dist/ui/elements/ColorScheme.js +11 -0
  125. package/dist/ui/elements/GeneralUIProps.d.ts +12 -0
  126. package/dist/ui/elements/GeneralUIProps.js +1 -0
  127. package/dist/ui/elements/ImageIcon.svelte +54 -0
  128. package/dist/ui/elements/ImageIcon.svelte.d.ts +6 -0
  129. package/dist/ui/elements/OnBackground.d.ts +3 -0
  130. package/dist/ui/elements/OnBackground.js +4 -0
  131. package/dist/ui/elements/PineappleSwitch.svelte +29 -0
  132. package/dist/ui/elements/PineappleSwitch.svelte.d.ts +10 -0
  133. package/dist/ui/elements/TextLink.svelte +17 -0
  134. package/dist/ui/elements/TextLink.svelte.d.ts +8 -0
  135. package/dist/ui/elements/WrapperProps.d.ts +4 -0
  136. package/dist/ui/elements/WrapperProps.js +1 -0
  137. package/dist/ui/elements/index.d.ts +10 -0
  138. package/dist/ui/elements/index.js +10 -0
  139. package/dist/ui/elements/pinya-button/component.svelte +47 -0
  140. package/dist/ui/elements/pinya-button/component.svelte.d.ts +4 -0
  141. package/dist/ui/elements/pinya-button/index.d.ts +2 -0
  142. package/dist/ui/elements/pinya-button/index.js +2 -0
  143. package/dist/ui/elements/pinya-button/props.d.ts +13 -0
  144. package/dist/ui/elements/pinya-button/props.js +6 -0
  145. package/dist/ui/elements/pinya-card/component.svelte +21 -0
  146. package/dist/ui/elements/pinya-card/component.svelte.d.ts +7 -0
  147. package/dist/ui/elements/pinya-card/index.d.ts +2 -0
  148. package/dist/ui/elements/pinya-card/index.js +2 -0
  149. package/dist/ui/elements/pinya-card/props.d.ts +10 -0
  150. package/dist/ui/elements/pinya-card/props.js +1 -0
  151. package/dist/ui/elements/pinya-combobox/PinyaCombobox.svelte +35 -0
  152. package/dist/ui/elements/pinya-combobox/PinyaCombobox.svelte.d.ts +18 -0
  153. package/dist/ui/elements/pinya-combobox/PinyaComboboxProps.d.ts +18 -0
  154. package/dist/ui/elements/pinya-combobox/PinyaComboboxProps.js +1 -0
  155. package/dist/ui/elements/text-chip/TextChip.svelte +15 -0
  156. package/dist/ui/elements/text-chip/TextChip.svelte.d.ts +4 -0
  157. package/dist/ui/elements/text-chip/TextChipProps.d.ts +4 -0
  158. package/dist/ui/elements/text-chip/TextChipProps.js +1 -0
  159. package/dist/ui/elements/text-chip/index.d.ts +2 -0
  160. package/dist/ui/elements/text-chip/index.js +2 -0
  161. package/dist/ui/modules/index.d.ts +2 -0
  162. package/dist/ui/modules/index.js +2 -0
  163. package/dist/ui/modules/modals/general-settings/GeneralSettingsModal.svelte +110 -0
  164. package/dist/ui/modules/modals/general-settings/GeneralSettingsModal.svelte.d.ts +4 -0
  165. package/dist/ui/modules/modals/general-settings/LanguagePicker.svelte +38 -0
  166. package/dist/ui/modules/modals/general-settings/LanguagePicker.svelte.d.ts +3 -0
  167. package/dist/ui/modules/projects/Hepcat.svelte +71 -0
  168. package/dist/ui/modules/projects/Hepcat.svelte.d.ts +22 -0
  169. package/dist/ui/modules/projects/Pengi.svelte +60 -0
  170. package/dist/ui/modules/projects/Pengi.svelte.d.ts +22 -0
  171. package/dist/ui/modules/projects/Soulwork.svelte +55 -0
  172. package/dist/ui/modules/projects/Soulwork.svelte.d.ts +22 -0
  173. package/dist/ui/modules/projects/ThisWebpage.svelte +62 -0
  174. package/dist/ui/modules/projects/ThisWebpage.svelte.d.ts +22 -0
  175. package/dist/ui/modules/projects/index.d.ts +4 -0
  176. package/dist/ui/modules/projects/index.js +4 -0
  177. package/dist/ui/modules/seaweed/ChumBucket.svelte +86 -0
  178. package/dist/ui/modules/seaweed/ChumBucket.svelte.d.ts +3 -0
  179. package/dist/ui/modules/seaweed/index.d.ts +3 -0
  180. package/dist/ui/modules/seaweed/index.js +4 -0
  181. package/dist/ui/templates/PinyaBase.svelte +48 -0
  182. package/dist/ui/templates/PinyaBase.svelte.d.ts +7 -0
  183. package/dist/ui/templates/confirmation-modal/component.svelte +47 -0
  184. package/dist/ui/templates/confirmation-modal/component.svelte.d.ts +4 -0
  185. package/dist/ui/templates/confirmation-modal/index.d.ts +2 -0
  186. package/dist/ui/templates/confirmation-modal/index.js +2 -0
  187. package/dist/ui/templates/confirmation-modal/props.d.ts +10 -0
  188. package/dist/ui/templates/confirmation-modal/props.js +1 -0
  189. package/dist/ui/templates/index.d.ts +4 -0
  190. package/dist/ui/templates/index.js +4 -0
  191. package/dist/ui/templates/pinya-page-layout/component.svelte +120 -0
  192. package/dist/ui/templates/pinya-page-layout/component.svelte.d.ts +9 -0
  193. package/dist/ui/templates/pinya-page-layout/index.d.ts +2 -0
  194. package/dist/ui/templates/pinya-page-layout/index.js +2 -0
  195. package/dist/ui/templates/pinya-page-layout/runes.svelte.d.ts +7 -0
  196. package/dist/ui/templates/pinya-page-layout/runes.svelte.js +3 -0
  197. package/dist/ui/templates/seaweed-layout/EntryGroup.svelte +89 -0
  198. package/dist/ui/templates/seaweed-layout/EntryGroup.svelte.d.ts +4 -0
  199. package/dist/ui/templates/seaweed-layout/EntryOrderConfig2.svelte +45 -0
  200. package/dist/ui/templates/seaweed-layout/EntryOrderConfig2.svelte.d.ts +9 -0
  201. package/dist/ui/templates/seaweed-layout/ProjectComponentProps.d.ts +4 -0
  202. package/dist/ui/templates/seaweed-layout/ProjectComponentProps.js +1 -0
  203. package/dist/ui/templates/seaweed-layout/ProjectGroupConfig.svelte +316 -0
  204. package/dist/ui/templates/seaweed-layout/ProjectGroupConfig.svelte.d.ts +14 -0
  205. package/dist/ui/templates/seaweed-layout/SeaweedLayout.md +4 -0
  206. package/dist/ui/templates/seaweed-layout/SeaweedLayout.svelte +196 -0
  207. package/dist/ui/templates/seaweed-layout/SeaweedLayout.svelte.d.ts +4 -0
  208. package/dist/ui/templates/seaweed-layout/index.d.ts +4 -0
  209. package/dist/ui/templates/seaweed-layout/index.js +4 -0
  210. package/dist/ui/templates/seaweed-layout/props.d.ts +25 -0
  211. package/dist/ui/templates/seaweed-layout/props.js +1 -0
  212. package/dist/util/util.d.ts +1 -0
  213. package/dist/util/util.js +9 -0
  214. package/package.json +37 -20
  215. package/src/lib/styles/app.css +144 -0
  216. package/src/lib/theme.css +114 -0
  217. package/dist/app.postcss +0 -212
  218. package/dist/components/SocialSection.svelte +0 -166
  219. package/dist/components/SocialSection.svelte.d.ts +0 -31
  220. package/dist/postcss.d.ts +0 -3
  221. package/dist/styles/DefaultGridContainer.css +0 -61
  222. package/dist/template/seaweed/ChumBucket.svelte +0 -87
  223. package/dist/template/seaweed/ChumBucket.svelte.d.ts +0 -14
@@ -0,0 +1,47 @@
1
+ <script lang="ts">
2
+ import { ColorScheme } from '..';
3
+ import { ButtonVariant, type PinyaButtonProps } from './props';
4
+
5
+ let {
6
+ children,
7
+ colorScheme = ColorScheme.Primary,
8
+ paddingClass = '',
9
+ buttonVariant = ButtonVariant.Default,
10
+ colorClass = '',
11
+ ...props
12
+ }: PinyaButtonProps = $props();
13
+
14
+ paddingClass = paddingClass
15
+ ? paddingClass
16
+ : (
17
+ buttonVariant === ButtonVariant.Image
18
+ ? 'pl-3 pr-3 pt-2 pb-2'
19
+ : 'pl-3 pr-3'
20
+ );
21
+
22
+ const chooseTailwindClass = () => {
23
+ switch (colorScheme) {
24
+ case ColorScheme.Custom:
25
+ return colorClass;
26
+ case ColorScheme.Warning:
27
+ return 'bg-warning-700 dark:bg-warning-400 text-secondary-0 dark:text-secondary-950 hover:brightness-110';
28
+ case ColorScheme.Surface:
29
+ return 'bg-surface-700 dark:bg-surface-600 text-surface-50-950 hover:brightness-110';
30
+ default:
31
+ console.error(`Unimplemented color scheme: ${colorScheme.toString()}`);
32
+ // eslint-disable-next-line no-fallthrough
33
+ case ColorScheme.Primary:
34
+ return 'bg-primary-400-600 text-secondary-950 dark:text-secondary-0 hover:brightness-110';
35
+ }
36
+ };
37
+
38
+ const tailwindClass = chooseTailwindClass();
39
+ </script>
40
+
41
+ <button
42
+ {...props}
43
+ class:small-icon-button={buttonVariant === ButtonVariant.SmallIcon}
44
+ class={`btn rounded-2xl text-xl font-bold ${tailwindClass} ${paddingClass}`}
45
+ >
46
+ {@render children()}
47
+ </button>
@@ -0,0 +1,4 @@
1
+ import { type PinyaButtonProps } from './props';
2
+ declare const Component: import("svelte").Component<PinyaButtonProps, {}, "">;
3
+ type Component = ReturnType<typeof Component>;
4
+ export default Component;
@@ -0,0 +1,2 @@
1
+ export { default as PinyaButton } from './component.svelte';
2
+ export * from './props';
@@ -0,0 +1,2 @@
1
+ export { default as PinyaButton } from './component.svelte';
2
+ export * from './props';
@@ -0,0 +1,13 @@
1
+ import type { HTMLButtonAttributes } from 'svelte/elements';
2
+ import type { GeneralUIProps } from '../GeneralUIProps';
3
+ import type { WrapperProps } from '../WrapperProps';
4
+ export declare enum ButtonVariant {
5
+ Default = 0,
6
+ Image = 1,
7
+ SmallIcon = 2
8
+ }
9
+ export type PinyaButtonProps = WrapperProps & HTMLButtonAttributes & GeneralUIProps & {
10
+ paddingClass?: string;
11
+ buttonVariant?: ButtonVariant;
12
+ colorClass?: string;
13
+ };
@@ -0,0 +1,6 @@
1
+ export var ButtonVariant;
2
+ (function (ButtonVariant) {
3
+ ButtonVariant[ButtonVariant["Default"] = 0] = "Default";
4
+ ButtonVariant[ButtonVariant["Image"] = 1] = "Image";
5
+ ButtonVariant[ButtonVariant["SmallIcon"] = 2] = "SmallIcon";
6
+ })(ButtonVariant || (ButtonVariant = {}));
@@ -0,0 +1,21 @@
1
+ <script lang="ts">/**
2
+ * When with texts, wrap the text content inside a div so flex wont apply
3
+ */
4
+ import type { PinyaCardProps } from "./props";
5
+
6
+ let {
7
+ paddingClass = "pt-[1lh] pb-[1lh] pl-16 pr-16",
8
+ flexClass = "flex flex-col",
9
+ widthClass = "max-w-md",
10
+ borderClass = "border-[2px] border-primary-500 dark:border-0",
11
+ marginClass = "",
12
+ className,
13
+ children
14
+ }: PinyaCardProps = $props();
15
+ </script>
16
+
17
+ <div
18
+ class={`card bg-surface-200 dark:bg-surface-900 w-full text-start rounded-xl ${paddingClass} ${flexClass} ${className} ${widthClass} ${borderClass} ${marginClass}`}
19
+ >
20
+ {@render children?.()}
21
+ </div>
@@ -0,0 +1,7 @@
1
+ /**
2
+ * When with texts, wrap the text content inside a div so flex wont apply
3
+ */
4
+ import type { PinyaCardProps } from "./props";
5
+ declare const Component: import("svelte").Component<PinyaCardProps, {}, "">;
6
+ type Component = ReturnType<typeof Component>;
7
+ export default Component;
@@ -0,0 +1,2 @@
1
+ export { default as PinyaCard } from "./component.svelte";
2
+ export * from "./props";
@@ -0,0 +1,2 @@
1
+ export { default as PinyaCard } from "./component.svelte";
2
+ export * from "./props";
@@ -0,0 +1,10 @@
1
+ import type { WrapperProps } from '..';
2
+ export interface PinyaCardProps extends WrapperProps {
3
+ paddingClass?: string;
4
+ className?: string;
5
+ flexClass?: string;
6
+ widthClass?: string;
7
+ borderClass?: string;
8
+ marginClass?: string;
9
+ includeDataNoSnippet?: boolean;
10
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,35 @@
1
+ <script lang="ts" generics="T extends string">
2
+ import { Combobox } from '@skeletonlabs/skeleton-svelte';
3
+ import { getLocale, localizeHref } from '../../../paraglide/runtime';
4
+ import type { PinyaComboboxProps, ValueChangeDetails } from "./PinyaComboboxProps";
5
+
6
+ let {
7
+ contentZIndex = 'auto',
8
+ value = $bindable(),
9
+ onValueChange = () => {},
10
+ onValueChangeBase = undefined,
11
+ ...props
12
+ }: PinyaComboboxProps<T> = $props();
13
+
14
+ const onValueChangeBaseImpl = (e: ValueChangeDetails<T>) => {
15
+ value = e.value as T[];
16
+ onValueChange(e);
17
+ };
18
+ </script>
19
+
20
+ <Combobox
21
+ width="w-full"
22
+ labelText="text-md"
23
+ inputGroupBase="w-full flex items-center border-primary-500 border-2 rounded-xl"
24
+ inputGroupInput="grow bg-transparent border-0 dark:placeholder-surface-50 pl-4"
25
+ inputGroupButton="size-[3rem]"
26
+ inputGroupArrow="size-[2rem] m-auto"
27
+ contentBackground="bg-surface-100-900 border-primary-500 border-2"
28
+ zIndex={contentZIndex}
29
+ optionActive="bg-secondary-400-600"
30
+ optionHover="hover:brightness-75 dark:hover:brightness-125"
31
+ optionClasses='aria-selected:brightness-75 aria-selected:dark:brightness-125'
32
+ onValueChange={onValueChangeBase ?? onValueChangeBaseImpl}
33
+ {value}
34
+ {...props}
35
+ />
@@ -0,0 +1,18 @@
1
+ import type { PinyaComboboxProps } from "./PinyaComboboxProps";
2
+ declare class __sveltets_Render<T extends string> {
3
+ props(): PinyaComboboxProps<T>;
4
+ events(): {};
5
+ slots(): {};
6
+ bindings(): "value";
7
+ exports(): {};
8
+ }
9
+ interface $$IsomorphicComponent {
10
+ new <T extends string>(options: import('svelte').ComponentConstructorOptions<ReturnType<__sveltets_Render<T>['props']>>): import('svelte').SvelteComponent<ReturnType<__sveltets_Render<T>['props']>, ReturnType<__sveltets_Render<T>['events']>, ReturnType<__sveltets_Render<T>['slots']>> & {
11
+ $$bindings?: ReturnType<__sveltets_Render<T>['bindings']>;
12
+ } & ReturnType<__sveltets_Render<T>['exports']>;
13
+ <T extends string>(internal: unknown, props: ReturnType<__sveltets_Render<T>['props']> & {}): ReturnType<__sveltets_Render<T>['exports']>;
14
+ z_$$bindings?: ReturnType<__sveltets_Render<any>['bindings']>;
15
+ }
16
+ declare const PinyaCombobox: $$IsomorphicComponent;
17
+ type PinyaCombobox<T extends string> = InstanceType<typeof PinyaCombobox<T>>;
18
+ export default PinyaCombobox;
@@ -0,0 +1,18 @@
1
+ export interface GenericComboboxItem<T extends string> {
2
+ label: string;
3
+ value: T;
4
+ }
5
+ export interface ValueChangeDetails<T extends string> {
6
+ value: string[];
7
+ items: T[];
8
+ }
9
+ export interface PinyaComboboxProps<T extends string> {
10
+ data: GenericComboboxItem<T>[];
11
+ defaultValue: T[];
12
+ value: T[];
13
+ label: string;
14
+ placeholder: string;
15
+ onValueChange?: (selectedList: ValueChangeDetails<T>) => void;
16
+ onValueChangeBase?: (selectedList: ValueChangeDetails<T>) => void;
17
+ contentZIndex?: string;
18
+ }
@@ -0,0 +1,15 @@
1
+ <script lang="ts">
2
+ import type { TextChipProps } from "./TextChipProps";
3
+
4
+ let { children, queryClass = "" }: TextChipProps = $props();
5
+ </script>
6
+
7
+ <span class={`chip text-chip font-bold pointer-events-none ${queryClass}`}>{@render children()}</span>
8
+
9
+ <style>
10
+ /*noinspection CssUnusedSymbol*/
11
+ :global(.highlight-chip.text-chip) {
12
+ background-color: var(--color-secondary-500) /* oklch(55.6% 0 0deg) = #737373 */;
13
+ color: var(--color-secondary-contrast-500) /* var(--color-secondary-contrast-light) */;
14
+ }
15
+ </style>
@@ -0,0 +1,4 @@
1
+ import type { TextChipProps } from "./TextChipProps";
2
+ declare const TextChip: import("svelte").Component<TextChipProps, {}, "">;
3
+ type TextChip = ReturnType<typeof TextChip>;
4
+ export default TextChip;
@@ -0,0 +1,4 @@
1
+ import type { WrapperProps } from "../index";
2
+ export interface TextChipProps extends WrapperProps {
3
+ queryClass?: string;
4
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,2 @@
1
+ export { default as TextChip } from "./TextChip.svelte";
2
+ export * from "./TextChipProps";
@@ -0,0 +1,2 @@
1
+ export { default as TextChip } from "./TextChip.svelte";
2
+ export * from "./TextChipProps";
@@ -0,0 +1,2 @@
1
+ export * from "./seaweed";
2
+ export * from "./projects";
@@ -0,0 +1,2 @@
1
+ export * from "./seaweed";
2
+ export * from "./projects";
@@ -0,0 +1,110 @@
1
+ <script lang="ts">
2
+ import type { ModalProps } from 'svelte-modals';
3
+ import { setMode, userPrefersMode } from 'mode-watcher';
4
+
5
+ import { m } from '../../../../paraglide/messages';
6
+ import ModalBase from '../../../components/ModalBase.svelte';
7
+ import DarkIcon from '../../../../assets/icons/icon-dark-mode.svg';
8
+ import LightIcon from '../../../../assets/icons/icon-light-mode.svg';
9
+ import ConstrastIcon from '../../../../assets/icons/icon-contrast.svg';
10
+ import LanguagePicker from './LanguagePicker.svelte';
11
+
12
+ let props: ModalProps = $props();
13
+
14
+
15
+ interface ToggleItem {
16
+ key: 'light' | 'dark' | 'system'
17
+ imageSrc: string,
18
+ label: string,
19
+ }
20
+
21
+ const modes: ToggleItem[] = [
22
+ { key: 'light', imageSrc: LightIcon, label: 'Light' },
23
+ { key: 'dark', imageSrc: DarkIcon, label: 'Dark' },
24
+ { key: 'system', imageSrc: ConstrastIcon, label: 'System' }
25
+ ];
26
+
27
+ let selectedItem: ToggleItem = $state(modes[0]);
28
+
29
+ // when mode is edited outside, adjust toggle button
30
+ // do not use runes here because we only want explicit changes outside
31
+ // our control here!
32
+ userPrefersMode.subscribe((value) => {
33
+ const si = modes.find(m => m.key === value);
34
+ if (selectedItem !== si && si) {
35
+ selectedItem = si;
36
+ }
37
+ });
38
+
39
+ // when mode is changed inside the button, adjust the mode
40
+ $effect(() => {
41
+ switch (selectedItem?.key) {
42
+ case 'dark':
43
+ setMode('dark');
44
+ break;
45
+ case 'light':
46
+ setMode('light');
47
+ break;
48
+ case 'system':
49
+ setMode('system');
50
+ break;
51
+ default:
52
+ break;
53
+ }
54
+ });
55
+ </script>
56
+
57
+ <ModalBase {...props}>
58
+ <div class="wrapper">
59
+ <h2>{m.settings()}</h2>
60
+
61
+ <fieldset class="btn-group border-primary-500 border-2 flex-col p-2 md:flex-row">
62
+ <legend class="bg-surface-100-900 pl-4 pr-4">Mode</legend>
63
+ {#each modes as mode (mode)}
64
+ <button
65
+ type="button"
66
+ title={mode.label}
67
+ class={`btn pt-3 pb-3 hover:brightness-125
68
+ ${mode.key === selectedItem.key ? 'bg-secondary-400 dark:bg-secondary-800' : 'preset-outlined-primary-300-700'}
69
+ `}
70
+ onclick={() => { setMode(mode.key) }}
71
+ >
72
+ <img
73
+ src={mode.imageSrc}
74
+ aria-hidden="true"
75
+ alt=""
76
+ class={`icon
77
+ ${mode.key === selectedItem.key ? 'reverse' : ''}
78
+ `}
79
+ >
80
+ {mode.label}
81
+ </button>
82
+ {/each}
83
+ </fieldset>
84
+
85
+ <LanguagePicker />
86
+
87
+ <div class="actions">
88
+ <button class="btn preset-filled-primary-400-600 text-surface-100" onclick={() => props.close()}
89
+ title="Close modal">
90
+ Close
91
+ </button>
92
+ </div>
93
+ </div>
94
+ </ModalBase>
95
+
96
+ <style>
97
+ .actions {
98
+ display: flex;
99
+ flex-direction: row-reverse;
100
+ margin-top: 1.4lh;
101
+ }
102
+
103
+ .wrapper {
104
+ display: flex;
105
+ flex-direction: column;
106
+ justify-content: start;
107
+ text-align: start;
108
+ gap: 1lh;
109
+ }
110
+ </style>
@@ -0,0 +1,4 @@
1
+ import type { ModalProps } from 'svelte-modals';
2
+ declare const GeneralSettingsModal: import("svelte").Component<ModalProps<any>, {}, "">;
3
+ type GeneralSettingsModal = ReturnType<typeof GeneralSettingsModal>;
4
+ export default GeneralSettingsModal;
@@ -0,0 +1,38 @@
1
+ <script lang="ts">
2
+ import { getLocale, localizeHref } from "../../../../paraglide/runtime";
3
+ import PinyaCombobox from "../../../elements/pinya-combobox/PinyaCombobox.svelte";
4
+
5
+ interface ComboxData {
6
+ label: string;
7
+ value: "en" | "fr" | "tl";
8
+ }
9
+
10
+ const comboboxData: ComboxData[] = [
11
+ { label: "English", value: "en" },
12
+ { label: "French", value: "fr" },
13
+ { label: "Tagalog", value: "tl" }
14
+ ];
15
+
16
+ let selectedCountry = $state([getLocale()]);
17
+
18
+ interface ValueDetail {
19
+ value: string[];
20
+ }
21
+
22
+ const onValueChange = (e: ValueDetail) => {
23
+ const data = comboboxData.find((d) => d.value === e.value[0]);
24
+ if (data) {
25
+ selectedCountry = [data.value];
26
+ location.href = localizeHref("./", { locale: data.value });
27
+ }
28
+ };
29
+ </script>
30
+
31
+ <PinyaCombobox
32
+ data={comboboxData}
33
+ value={selectedCountry}
34
+ defaultValue={selectedCountry}
35
+ label="Select Language"
36
+ placeholder="Select Language"
37
+ {onValueChange}
38
+ />
@@ -0,0 +1,3 @@
1
+ declare const LanguagePicker: import("svelte").Component<Record<string, never>, {}, "">;
2
+ type LanguagePicker = ReturnType<typeof LanguagePicker>;
3
+ export default LanguagePicker;
@@ -0,0 +1,71 @@
1
+ <script module lang="ts">
2
+ import HeaderHepCat from "../../../assets/temp/header-hep-cat.mp4";
3
+ import BitbucketIcon from "../../../assets/icons/bitbucket-icon.svg";
4
+ import type { ProjectComponentProps } from "../../templates/seaweed-layout/ProjectComponentProps";
5
+ import { FourPartCard } from "../../components/index.js";
6
+ import { ButtonVariant, ImageIcon, PinyaButton } from "../../elements/index.js";
7
+ import { ItchLogoHotLink } from "../../../consts.js";
8
+
9
+ const key = "Hepcat";
10
+ export { component, key };
11
+ </script>
12
+
13
+ {#snippet component(props: ProjectComponentProps)}
14
+ <FourPartCard>
15
+ {#snippet headerCover()}
16
+ <video playsinline autoplay muted loop preload="none" id="hepcat-video" class="game-video-cover">
17
+ <source src={HeaderHepCat} type="video/mp4">
18
+ </video>
19
+ {/snippet}
20
+
21
+ {#snippet header()}
22
+ <h3>Hepcat</h3>
23
+
24
+ <blockquote>
25
+ "Cats, Jazz, and a little bit of Death. What more could anyone ask for?"
26
+ </blockquote>
27
+ {/snippet}
28
+
29
+
30
+ <p>This is a course project made by a team of six for <a
31
+ href="https://sites.google.com/ualberta.ca/cmput250/">CMPUT 250</a>, and it won <a
32
+ href="https://webdocs.cs.ualberta.ca/~nathanst/certificate/">Game of the year.</a>
33
+ </p>
34
+
35
+ <p>
36
+ Hep Cat is a <span class="qt-rhythm">rhythm</span> game made in <a
37
+ href="https://www.rpgmakerweb.com/products/programs/rpg-maker-mv" target="_blank"
38
+ class='qt-rpgmaker'>
39
+ RPG Maker MV</a> with the help of additional custom-made <span class='qt-js'>Javascript</span>
40
+ plugins. I
41
+ wrote the rhythm game plugin's framework. For this plugin to work, I
42
+ had to write a <span class='qt-python'>Python</span> script that parses osu! files
43
+ into readable JSON
44
+ files.
45
+ </p>
46
+
47
+
48
+ <section class="game-link-section">
49
+ <PinyaButton
50
+ buttonVariant={ButtonVariant.Image}
51
+ title="https://bitbucket.org/egginchicken/hep-cat/src/master/"
52
+ onclick={()=> window.open("https://bitbucket.org/egginchicken/hep-cat/src/master/")}>
53
+ <ImageIcon alt="bitbucket icon" src={BitbucketIcon} />
54
+ </PinyaButton>
55
+ <PinyaButton
56
+ buttonVariant={ButtonVariant.Image}
57
+ title="https://just-a-phantom.itch.io/hep-cat"
58
+ onclick={()=> window.open("https://just-a-phantom.itch.io/hep-cat")}>
59
+ <ImageIcon alt="itch.io icon" src={ItchLogoHotLink}></ImageIcon>
60
+ </PinyaButton>
61
+ </section>
62
+ </FourPartCard>
63
+ {/snippet}
64
+
65
+
66
+ <style>
67
+ #hepcat-video {
68
+ object-position: top;
69
+ max-height: 64rem;
70
+ }
71
+ </style>
@@ -0,0 +1,22 @@
1
+ import type { ProjectComponentProps } from "../../templates/seaweed-layout/ProjectComponentProps";
2
+ declare const key = "Hepcat";
3
+ export { component, key };
4
+ declare const component: (props: ProjectComponentProps) => ReturnType<import("svelte").Snippet>;
5
+ interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
6
+ new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
7
+ $$bindings?: Bindings;
8
+ } & Exports;
9
+ (internal: unknown, props: {
10
+ $$events?: Events;
11
+ $$slots?: Slots;
12
+ }): Exports & {
13
+ $set?: any;
14
+ $on?: any;
15
+ };
16
+ z_$$bindings?: Bindings;
17
+ }
18
+ declare const Hepcat: $$__sveltets_2_IsomorphicComponent<Record<string, never>, {
19
+ [evt: string]: CustomEvent<any>;
20
+ }, {}, {}, string>;
21
+ type Hepcat = InstanceType<typeof Hepcat>;
22
+ export default Hepcat;
@@ -0,0 +1,60 @@
1
+ <script module lang="ts">
2
+ import HeaderPengi from "../../../assets/temp/header-pengi.mp4";
3
+ import GithubIcon from "../../../assets/icons/github-mark.svg";
4
+ import type { ProjectComponentProps } from "../../templates/index";
5
+ import { FourPartCard } from "../../components/index.js";
6
+ import { ButtonVariant, ImageIcon, PinyaButton } from "../../elements/index.js";
7
+ import { ItchLogoHotLink } from "../../../consts.js";
8
+
9
+ const key = "Pengi";
10
+ export { component, key };
11
+ </script>
12
+
13
+ {#snippet component(props: ProjectComponentProps)}
14
+ <FourPartCard>
15
+ {#snippet headerCover()}
16
+ <video class="rounded-t-xl max-h-64 not-prose object-cover w-full" playsinline autoplay muted loop preload="none">
17
+ video unavailable. original video contains pengi gameplay showing the dynamic dialog
18
+ layout and character animation.
19
+ <source src={HeaderPengi} type="video/mp4">
20
+ </video>
21
+ {/snippet}
22
+
23
+ {#snippet header()}
24
+ <h3>Pengi</h3>
25
+
26
+ <blockquote>
27
+ Well well, quite the dreamer, aren’t you? Might be hard to get in... costs a lot of
28
+ money...
29
+ </blockquote>
30
+ {/snippet}
31
+
32
+ <p>
33
+ Pengi is a text-based adventure made in <span class='qt-unity'>Unity</span> (<span class='qt-cs'>C#</span>). I
34
+ acted as the sole
35
+ programmer for the team. Most of the work revolves around UI and creating <a
36
+ href="https://yarnspinner.dev/" target="_blank">YarnSpinner</a> commands for writers
37
+ to use to create expressive stage directions in the script.
38
+ </p>
39
+
40
+ <section class="game-link-section">
41
+ <PinyaButton
42
+ buttonVariant={ButtonVariant.Image}
43
+ aria-label="Click to go to Project Pengi in Github"
44
+ title="https://github.com/GreenTea-M/ProjectPengi"
45
+ onclick={() => window.open("https://github.com/GreenTea-M/ProjectPengi")}
46
+ >
47
+ <ImageIcon alt="" aria-hidden="true" src={GithubIcon} />
48
+ </PinyaButton>
49
+ <PinyaButton
50
+ buttonVariant={ButtonVariant.Image}
51
+ aria-label="Click to go to Project Pengi in Itch.io"
52
+ title="https://turnipxenon.itch.io/pengi"
53
+ onclick={() => window.open("https://turnipxenon.itch.io/pengi")}
54
+ >
55
+ <ImageIcon alt="" aria-hidden="true" src={ItchLogoHotLink} />
56
+ </PinyaButton>
57
+ </section>
58
+
59
+ </FourPartCard>
60
+ {/snippet}
@@ -0,0 +1,22 @@
1
+ import type { ProjectComponentProps } from "../../templates/index";
2
+ declare const key = "Pengi";
3
+ export { component, key };
4
+ declare const component: (props: ProjectComponentProps) => ReturnType<import("svelte").Snippet>;
5
+ interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
6
+ new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
7
+ $$bindings?: Bindings;
8
+ } & Exports;
9
+ (internal: unknown, props: {
10
+ $$events?: Events;
11
+ $$slots?: Slots;
12
+ }): Exports & {
13
+ $set?: any;
14
+ $on?: any;
15
+ };
16
+ z_$$bindings?: Bindings;
17
+ }
18
+ declare const Pengi: $$__sveltets_2_IsomorphicComponent<Record<string, never>, {
19
+ [evt: string]: CustomEvent<any>;
20
+ }, {}, {}, string>;
21
+ type Pengi = InstanceType<typeof Pengi>;
22
+ export default Pengi;
@@ -0,0 +1,55 @@
1
+ <script module lang="ts">
2
+ import HeaderSoulwork from '../../../assets/temp/header-soulwork.mp4';
3
+ import GithubIcon from '../../../assets/icons/github-mark.svg';
4
+ import type { ProjectComponentProps } from "../../templates/index";
5
+ import { FourPartCard } from "../../components/index";
6
+ import { ButtonVariant, ImageIcon, PinyaButton } from "../../elements/index.js";
7
+ import { ItchLogoHotLink } from "../../../consts.js";
8
+
9
+ const key = "Soulwork";
10
+ export { component, key };
11
+ </script>
12
+
13
+ {#snippet component(props: ProjectComponentProps)}
14
+ <FourPartCard>
15
+ {#snippet headerCover()}
16
+ <video
17
+ playsinline autoplay muted loop preload="none"
18
+ class="game-video-cover"
19
+ >
20
+ <source src={HeaderSoulwork} type="video/mp4">
21
+ </video>
22
+ {/snippet}
23
+
24
+ {#snippet header()}
25
+ <h1>Soulwork</h1>
26
+ {/snippet}
27
+
28
+ <p>
29
+ Soulwork is a 2D platforming game that uses unique physics to solve puzzle-based levels.
30
+ This project is a Time to Game Jam entry, restricting game development to be under 48
31
+ hours.
32
+ </p>
33
+ <p>
34
+ I helped make the level designing tools used by the designers to drag-and-drop objects
35
+ on the stage. I also helped program the unique physics-based gameplay mechanic. This was
36
+ was made in <span class="qt-unity">Unity</span> written using <span class="qt-cs">C#</span>.
37
+ </p>
38
+
39
+
40
+ <section class="game-link-section">
41
+ <PinyaButton
42
+ buttonVariant={ButtonVariant.Image}
43
+ title="https://github.com/Zeyu-Li/Clockwork"
44
+ onclick={()=> window.open("https://github.com/Zeyu-Li/Clockwork")}>
45
+ <ImageIcon alt="github icon" src={GithubIcon} />
46
+ </PinyaButton>
47
+ <PinyaButton
48
+ buttonVariant={ButtonVariant.Image}
49
+ title="https://itch.io/jam/time-to-game-jam-gadec-fall-game-jam/rate/514331"
50
+ onclick={()=> window.open("https://itch.io/jam/time-to-game-jam-gadec-fall-game-jam/rate/514331")}>
51
+ <ImageIcon alt="itch.io icon" src={ItchLogoHotLink} />
52
+ </PinyaButton>
53
+ </section>
54
+ </FourPartCard>
55
+ {/snippet}