chromia 0.0.2 → 0.0.4

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 (147) hide show
  1. package/{src → dist}/icons/AddImageIcon.svelte +22 -28
  2. package/{src → dist}/icons/AddSquareIcon.svelte +22 -28
  3. package/{src → dist}/icons/AlertCircleIcon.svelte +22 -28
  4. package/{src → dist}/icons/AnnotationXIcon.svelte +22 -28
  5. package/{src → dist}/icons/ArrowCalendarIcon.svelte +22 -28
  6. package/{src → dist}/icons/ArrowLeftIcon.svelte +22 -28
  7. package/{src → dist}/icons/ArrowSwitchIcon.svelte +22 -28
  8. package/{src → dist}/icons/ArrowUpIcon.svelte +22 -28
  9. package/{src → dist}/icons/BellIcon.svelte +22 -28
  10. package/{src → dist}/icons/BezierIcon.svelte +22 -28
  11. package/{src → dist}/icons/CalendarIcon.svelte +22 -28
  12. package/{src → dist}/icons/CameraIcon.svelte +22 -28
  13. package/{src → dist}/icons/CertificateIcon.svelte +22 -28
  14. package/{src → dist}/icons/CheckCircleIcon.svelte +22 -28
  15. package/{src → dist}/icons/CheckIcon.svelte +22 -28
  16. package/{src → dist}/icons/ChevronDownIcon.svelte +22 -28
  17. package/{src → dist}/icons/ChevronUpIcon.svelte +22 -28
  18. package/{src → dist}/icons/ClockIcon.svelte +22 -28
  19. package/{src → dist}/icons/CloseIcon.svelte +22 -28
  20. package/{src → dist}/icons/CollectionIcon.svelte +22 -28
  21. package/{src → dist}/icons/CopyIcon.svelte +22 -28
  22. package/{src → dist}/icons/EditIcon.svelte +22 -28
  23. package/dist/icons/EyeClosedIcon.svelte +82 -0
  24. package/dist/icons/EyeClosedIcon.svelte.d.ts +22 -0
  25. package/dist/icons/EyeOpenIcon.svelte +82 -0
  26. package/dist/icons/EyeOpenIcon.svelte.d.ts +22 -0
  27. package/{src → dist}/icons/FavoriteIcon.svelte +22 -28
  28. package/{src → dist}/icons/FilterIcon.svelte +22 -28
  29. package/{src → dist}/icons/FlameIcon.svelte +22 -28
  30. package/{src → dist}/icons/FolderIcon.svelte +22 -28
  31. package/{src → dist}/icons/FolderPlusIcon.svelte +22 -28
  32. package/{src → dist}/icons/GridIcon.svelte +22 -28
  33. package/{src → dist}/icons/HourglassIcon.svelte +22 -28
  34. package/dist/icons/Icon.svelte +82 -0
  35. package/dist/icons/Icon.svelte.d.ts +22 -0
  36. package/{src → dist}/icons/LockIcon.svelte +22 -28
  37. package/{src → dist}/icons/LogoutIcon.svelte +22 -28
  38. package/{src → dist}/icons/MenuIcon.svelte +22 -28
  39. package/{src → dist}/icons/NoFolder.svelte +22 -28
  40. package/{src → dist}/icons/NotificationIcon.svelte +22 -28
  41. package/{src → dist}/icons/OverlapIcon.svelte +22 -28
  42. package/{src → dist}/icons/SearchIcon.svelte +22 -28
  43. package/{src → dist}/icons/SendIcon.svelte +22 -28
  44. package/{src → dist}/icons/TeamUserIcon.svelte +22 -28
  45. package/{src → dist}/icons/TrashIcon.svelte +22 -28
  46. package/{src → dist}/icons/UploadIcon.svelte +22 -28
  47. package/{src → dist}/icons/UserProfileIcon.svelte +22 -28
  48. package/dist/index.d.ts +47 -42
  49. package/dist/index.js +45 -42
  50. package/dist/types/IconProps.d.ts +9 -0
  51. package/dist/types/IconProps.js +1 -0
  52. package/package.json +1 -1
  53. package/.gitignore +0 -11
  54. package/.npmrc +0 -1
  55. package/.svelte-kit/__package__/index.d.ts +0 -42
  56. package/.svelte-kit/__package__/index.js +0 -42
  57. package/.svelte-kit/ambient.d.ts +0 -389
  58. package/.svelte-kit/generated/client/app.js +0 -19
  59. package/.svelte-kit/generated/client/matchers.js +0 -1
  60. package/.svelte-kit/generated/client/nodes/0.js +0 -1
  61. package/.svelte-kit/generated/client/nodes/1.js +0 -1
  62. package/.svelte-kit/generated/client/nodes/2.js +0 -1
  63. package/.svelte-kit/generated/client-optimized/app.js +0 -19
  64. package/.svelte-kit/generated/client-optimized/matchers.js +0 -1
  65. package/.svelte-kit/generated/client-optimized/nodes/0.js +0 -1
  66. package/.svelte-kit/generated/client-optimized/nodes/1.js +0 -1
  67. package/.svelte-kit/generated/client-optimized/nodes/2.js +0 -1
  68. package/.svelte-kit/generated/root.svelte +0 -57
  69. package/.svelte-kit/generated/server/internal.js +0 -30
  70. package/.svelte-kit/non-ambient.d.ts +0 -25
  71. package/.svelte-kit/output/client/.vite/manifest.json +0 -71
  72. package/.svelte-kit/output/client/_app/immutable/chunks/index.fwz0P8IJ.js +0 -1
  73. package/.svelte-kit/output/client/_app/immutable/chunks/scheduler.k-kUyWhY.js +0 -1
  74. package/.svelte-kit/output/client/_app/immutable/chunks/singletons.BTKERuC0.js +0 -1
  75. package/.svelte-kit/output/client/_app/immutable/entry/app.WGYaKRLN.js +0 -7
  76. package/.svelte-kit/output/client/_app/immutable/entry/start.aC2tJUKM.js +0 -4
  77. package/.svelte-kit/output/client/_app/immutable/nodes/0.TPefyB_B.js +0 -1
  78. package/.svelte-kit/output/client/_app/immutable/nodes/1.YWupMHx9.js +0 -1
  79. package/.svelte-kit/output/client/_app/immutable/nodes/2.sCXEpvk1.js +0 -1
  80. package/.svelte-kit/output/client/_app/version.json +0 -1
  81. package/.svelte-kit/output/client/favicon.png +0 -0
  82. package/.svelte-kit/output/server/.vite/manifest.json +0 -52
  83. package/.svelte-kit/output/server/chunks/internal.js +0 -211
  84. package/.svelte-kit/output/server/chunks/ssr.js +0 -117
  85. package/.svelte-kit/output/server/entries/fallbacks/error.svelte.js +0 -31
  86. package/.svelte-kit/output/server/entries/fallbacks/layout.svelte.js +0 -7
  87. package/.svelte-kit/output/server/entries/pages/_page.svelte.js +0 -7
  88. package/.svelte-kit/output/server/index.js +0 -3052
  89. package/.svelte-kit/output/server/internal.js +0 -10
  90. package/.svelte-kit/output/server/manifest-full.js +0 -34
  91. package/.svelte-kit/output/server/manifest.js +0 -34
  92. package/.svelte-kit/output/server/nodes/0.js +0 -8
  93. package/.svelte-kit/output/server/nodes/1.js +0 -8
  94. package/.svelte-kit/output/server/nodes/2.js +0 -8
  95. package/.svelte-kit/tsconfig.json +0 -46
  96. package/.svelte-kit/types/route_meta_data.json +0 -3
  97. package/.svelte-kit/types/src/routes/$types.d.ts +0 -22
  98. package/src/app.d.ts +0 -13
  99. package/src/app.html +0 -12
  100. package/src/lib/index.ts +0 -44
  101. package/src/routes/+page.svelte +0 -0
  102. package/static/favicon.png +0 -0
  103. package/svelte.config.js +0 -18
  104. package/tsconfig.json +0 -15
  105. package/vite.config.ts +0 -6
  106. package/yarn.lock +0 -1082
  107. /package/{src → dist}/icons/AddImageIcon.svelte.d.ts +0 -0
  108. /package/{src → dist}/icons/AddSquareIcon.svelte.d.ts +0 -0
  109. /package/{src → dist}/icons/AlertCircleIcon.svelte.d.ts +0 -0
  110. /package/{src → dist}/icons/AnnotationXIcon.svelte.d.ts +0 -0
  111. /package/{src → dist}/icons/ArrowCalendarIcon.svelte.d.ts +0 -0
  112. /package/{src → dist}/icons/ArrowLeftIcon.svelte.d.ts +0 -0
  113. /package/{src → dist}/icons/ArrowSwitchIcon.svelte.d.ts +0 -0
  114. /package/{src → dist}/icons/ArrowUpIcon.svelte.d.ts +0 -0
  115. /package/{src → dist}/icons/BellIcon.svelte.d.ts +0 -0
  116. /package/{src → dist}/icons/BezierIcon.svelte.d.ts +0 -0
  117. /package/{src → dist}/icons/CalendarIcon.svelte.d.ts +0 -0
  118. /package/{src → dist}/icons/CameraIcon.svelte.d.ts +0 -0
  119. /package/{src → dist}/icons/CertificateIcon.svelte.d.ts +0 -0
  120. /package/{src → dist}/icons/CheckCircleIcon.svelte.d.ts +0 -0
  121. /package/{src → dist}/icons/CheckIcon.svelte.d.ts +0 -0
  122. /package/{src → dist}/icons/ChevronDownIcon.svelte.d.ts +0 -0
  123. /package/{src → dist}/icons/ChevronUpIcon.svelte.d.ts +0 -0
  124. /package/{src → dist}/icons/ClockIcon.svelte.d.ts +0 -0
  125. /package/{src → dist}/icons/CloseIcon.svelte.d.ts +0 -0
  126. /package/{src → dist}/icons/CollectionIcon.svelte.d.ts +0 -0
  127. /package/{src → dist}/icons/CopyIcon.svelte.d.ts +0 -0
  128. /package/{src → dist}/icons/EditIcon.svelte.d.ts +0 -0
  129. /package/{src → dist}/icons/FavoriteIcon.svelte.d.ts +0 -0
  130. /package/{src → dist}/icons/FilterIcon.svelte.d.ts +0 -0
  131. /package/{src → dist}/icons/FlameIcon.svelte.d.ts +0 -0
  132. /package/{src → dist}/icons/FolderIcon.svelte.d.ts +0 -0
  133. /package/{src → dist}/icons/FolderPlusIcon.svelte.d.ts +0 -0
  134. /package/{src → dist}/icons/GridIcon.svelte.d.ts +0 -0
  135. /package/{src → dist}/icons/HourglassIcon.svelte.d.ts +0 -0
  136. /package/{src → dist}/icons/LockIcon.svelte.d.ts +0 -0
  137. /package/{src → dist}/icons/LogoutIcon.svelte.d.ts +0 -0
  138. /package/{src → dist}/icons/MenuIcon.svelte.d.ts +0 -0
  139. /package/{src → dist}/icons/NoFolder.svelte.d.ts +0 -0
  140. /package/{src → dist}/icons/NotificationIcon.svelte.d.ts +0 -0
  141. /package/{src → dist}/icons/OverlapIcon.svelte.d.ts +0 -0
  142. /package/{src → dist}/icons/SearchIcon.svelte.d.ts +0 -0
  143. /package/{src → dist}/icons/SendIcon.svelte.d.ts +0 -0
  144. /package/{src → dist}/icons/TeamUserIcon.svelte.d.ts +0 -0
  145. /package/{src → dist}/icons/TrashIcon.svelte.d.ts +0 -0
  146. /package/{src → dist}/icons/UploadIcon.svelte.d.ts +0 -0
  147. /package/{src → dist}/icons/UserProfileIcon.svelte.d.ts +0 -0
@@ -1,33 +1,27 @@
1
- <script lang="ts">
2
- interface GradientObj {
3
- colors: [string, string];
4
- direction: "top" | "right" | "bottom" | "left";
5
- }
6
- export let color = "#000";
7
- export let gradient: GradientObj = {
8
- colors: ["", ""],
9
- direction: "bottom",
10
- };
11
- export let size: string = "1rem";
12
- export let weight: number = 1;
13
-
14
- const getGradientDirection = (direction: string) => {
15
- switch (direction) {
16
- case "top":
17
- return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
18
- case "right":
19
- return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
20
- case "bottom":
21
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
22
- case "left":
23
- return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
24
- default:
25
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
26
- }
27
- };
1
+ <script>export let color = "#000";
2
+ export let gradient = {
3
+ colors: ["", ""],
4
+ direction: "bottom"
5
+ };
6
+ export let size = "1rem";
7
+ export let weight = 1;
8
+ const getGradientDirection = (direction) => {
9
+ switch (direction) {
10
+ case "top":
11
+ return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
12
+ case "right":
13
+ return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
14
+ case "bottom":
15
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
16
+ case "left":
17
+ return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
18
+ default:
19
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
20
+ }
21
+ };
28
22
  </script>
29
23
 
30
- {#if gradient !== undefined}
24
+ {#if gradient.colors[1] !== ""}
31
25
  <svg
32
26
  xmlns="http://www.w3.org/2000/svg"
33
27
  style="width: {size}; height: {size};"
@@ -1,34 +1,28 @@
1
1
 
2
- <script lang="ts">
3
- interface GradientObj {
4
- colors: [string, string];
5
- direction: "top" | "right" | "bottom" | "left";
6
- }
7
- export let color = "#000";
8
- export let gradient: GradientObj = {
9
- colors: ["", ""],
10
- direction: "bottom",
11
- };
12
- export let size: string = "1rem";
13
- export let weight: number = 1;
14
-
15
- const getGradientDirection = (direction: string) => {
16
- switch (direction) {
17
- case "top":
18
- return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
19
- case "right":
20
- return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
21
- case "bottom":
22
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
23
- case "left":
24
- return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
25
- default:
26
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
27
- }
28
- };
2
+ <script>export let color = "#000";
3
+ export let gradient = {
4
+ colors: ["", ""],
5
+ direction: "bottom"
6
+ };
7
+ export let size = "1rem";
8
+ export let weight = 1;
9
+ const getGradientDirection = (direction) => {
10
+ switch (direction) {
11
+ case "top":
12
+ return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
13
+ case "right":
14
+ return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
15
+ case "bottom":
16
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
17
+ case "left":
18
+ return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
19
+ default:
20
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
21
+ }
22
+ };
29
23
  </script>
30
24
 
31
- {#if gradient !== undefined}
25
+ {#if gradient.colors[1] !== ""}
32
26
  <svg
33
27
  xmlns="http://www.w3.org/2000/svg"
34
28
  style="width: {size}; height: {size};"
@@ -1,34 +1,28 @@
1
1
 
2
- <script lang="ts">
3
- interface GradientObj {
4
- colors: [string, string];
5
- direction: "top" | "right" | "bottom" | "left";
6
- }
7
- export let color = "#000";
8
- export let gradient: GradientObj = {
9
- colors: ["", ""],
10
- direction: "bottom",
11
- };
12
- export let size: string = "1rem";
13
- export let weight: number = 1;
14
-
15
- const getGradientDirection = (direction: string) => {
16
- switch (direction) {
17
- case "top":
18
- return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
19
- case "right":
20
- return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
21
- case "bottom":
22
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
23
- case "left":
24
- return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
25
- default:
26
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
27
- }
28
- };
2
+ <script>export let color = "#000";
3
+ export let gradient = {
4
+ colors: ["", ""],
5
+ direction: "bottom"
6
+ };
7
+ export let size = "1rem";
8
+ export let weight = 1;
9
+ const getGradientDirection = (direction) => {
10
+ switch (direction) {
11
+ case "top":
12
+ return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
13
+ case "right":
14
+ return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
15
+ case "bottom":
16
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
17
+ case "left":
18
+ return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
19
+ default:
20
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
21
+ }
22
+ };
29
23
  </script>
30
24
 
31
- {#if gradient !== undefined}
25
+ {#if gradient.colors[1] !== ""}
32
26
  <svg
33
27
  xmlns="http://www.w3.org/2000/svg"
34
28
  style="width: {size}; height: {size};"
@@ -1,34 +1,28 @@
1
1
 
2
- <script lang="ts">
3
- interface GradientObj {
4
- colors: [string, string];
5
- direction: "top" | "right" | "bottom" | "left";
6
- }
7
- export let color = "#000";
8
- export let gradient: GradientObj = {
9
- colors: ["", ""],
10
- direction: "bottom",
11
- };
12
- export let size: string = "1rem";
13
- export let weight: number = 1;
14
-
15
- const getGradientDirection = (direction: string) => {
16
- switch (direction) {
17
- case "top":
18
- return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
19
- case "right":
20
- return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
21
- case "bottom":
22
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
23
- case "left":
24
- return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
25
- default:
26
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
27
- }
28
- };
2
+ <script>export let color = "#000";
3
+ export let gradient = {
4
+ colors: ["", ""],
5
+ direction: "bottom"
6
+ };
7
+ export let size = "1rem";
8
+ export let weight = 1;
9
+ const getGradientDirection = (direction) => {
10
+ switch (direction) {
11
+ case "top":
12
+ return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
13
+ case "right":
14
+ return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
15
+ case "bottom":
16
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
17
+ case "left":
18
+ return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
19
+ default:
20
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
21
+ }
22
+ };
29
23
  </script>
30
24
 
31
- {#if gradient !== undefined}
25
+ {#if gradient.colors[1] !== ""}
32
26
  <svg
33
27
  xmlns="http://www.w3.org/2000/svg"
34
28
  style="width: {size}; height: {size};"
@@ -1,34 +1,28 @@
1
1
 
2
- <script lang="ts">
3
- interface GradientObj {
4
- colors: [string, string];
5
- direction: "top" | "right" | "bottom" | "left";
6
- }
7
- export let color = "#000";
8
- export let gradient: GradientObj = {
9
- colors: ["", ""],
10
- direction: "bottom",
11
- };
12
- export let size: string = "1rem";
13
- export let weight: number = 1;
14
-
15
- const getGradientDirection = (direction: string) => {
16
- switch (direction) {
17
- case "top":
18
- return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
19
- case "right":
20
- return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
21
- case "bottom":
22
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
23
- case "left":
24
- return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
25
- default:
26
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
27
- }
28
- };
2
+ <script>export let color = "#000";
3
+ export let gradient = {
4
+ colors: ["", ""],
5
+ direction: "bottom"
6
+ };
7
+ export let size = "1rem";
8
+ export let weight = 1;
9
+ const getGradientDirection = (direction) => {
10
+ switch (direction) {
11
+ case "top":
12
+ return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
13
+ case "right":
14
+ return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
15
+ case "bottom":
16
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
17
+ case "left":
18
+ return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
19
+ default:
20
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
21
+ }
22
+ };
29
23
  </script>
30
24
 
31
- {#if gradient !== undefined}
25
+ {#if gradient.colors[1] !== ""}
32
26
  <svg
33
27
  xmlns="http://www.w3.org/2000/svg"
34
28
  style="width: {size}; height: {size};"
@@ -1,34 +1,28 @@
1
1
 
2
- <script lang="ts">
3
- interface GradientObj {
4
- colors: [string, string];
5
- direction: "top" | "right" | "bottom" | "left";
6
- }
7
- export let color = "#000";
8
- export let gradient: GradientObj = {
9
- colors: ["", ""],
10
- direction: "bottom",
11
- };
12
- export let size: string = "1rem";
13
- export let weight: number = 1;
14
-
15
- const getGradientDirection = (direction: string) => {
16
- switch (direction) {
17
- case "top":
18
- return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
19
- case "right":
20
- return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
21
- case "bottom":
22
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
23
- case "left":
24
- return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
25
- default:
26
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
27
- }
28
- };
2
+ <script>export let color = "#000";
3
+ export let gradient = {
4
+ colors: ["", ""],
5
+ direction: "bottom"
6
+ };
7
+ export let size = "1rem";
8
+ export let weight = 1;
9
+ const getGradientDirection = (direction) => {
10
+ switch (direction) {
11
+ case "top":
12
+ return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
13
+ case "right":
14
+ return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
15
+ case "bottom":
16
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
17
+ case "left":
18
+ return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
19
+ default:
20
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
21
+ }
22
+ };
29
23
  </script>
30
24
 
31
- {#if gradient !== undefined}
25
+ {#if gradient.colors[1] !== ""}
32
26
  <svg
33
27
  xmlns="http://www.w3.org/2000/svg"
34
28
  style="width: {size}; height: {size};"
@@ -1,34 +1,28 @@
1
1
 
2
- <script lang="ts">
3
- interface GradientObj {
4
- colors: [string, string];
5
- direction: "top" | "right" | "bottom" | "left";
6
- }
7
- export let color = "#000";
8
- export let gradient: GradientObj = {
9
- colors: ["", ""],
10
- direction: "bottom",
11
- };
12
- export let size: string = "1rem";
13
- export let weight: number = 1;
14
-
15
- const getGradientDirection = (direction: string) => {
16
- switch (direction) {
17
- case "top":
18
- return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
19
- case "right":
20
- return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
21
- case "bottom":
22
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
23
- case "left":
24
- return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
25
- default:
26
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
27
- }
28
- };
2
+ <script>export let color = "#000";
3
+ export let gradient = {
4
+ colors: ["", ""],
5
+ direction: "bottom"
6
+ };
7
+ export let size = "1rem";
8
+ export let weight = 1;
9
+ const getGradientDirection = (direction) => {
10
+ switch (direction) {
11
+ case "top":
12
+ return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
13
+ case "right":
14
+ return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
15
+ case "bottom":
16
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
17
+ case "left":
18
+ return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
19
+ default:
20
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
21
+ }
22
+ };
29
23
  </script>
30
24
 
31
- {#if gradient !== undefined}
25
+ {#if gradient.colors[1] !== ""}
32
26
  <svg
33
27
  xmlns="http://www.w3.org/2000/svg"
34
28
  style="width: {size}; height: {size};"
@@ -1,34 +1,28 @@
1
1
 
2
- <script lang="ts">
3
- interface GradientObj {
4
- colors: [string, string];
5
- direction: "top" | "right" | "bottom" | "left";
6
- }
7
- export let color = "#000";
8
- export let gradient: GradientObj = {
9
- colors: ["", ""],
10
- direction: "bottom",
11
- };
12
- export let size: string = "1rem";
13
- export let weight: number = 1;
14
-
15
- const getGradientDirection = (direction: string) => {
16
- switch (direction) {
17
- case "top":
18
- return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
19
- case "right":
20
- return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
21
- case "bottom":
22
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
23
- case "left":
24
- return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
25
- default:
26
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
27
- }
28
- };
2
+ <script>export let color = "#000";
3
+ export let gradient = {
4
+ colors: ["", ""],
5
+ direction: "bottom"
6
+ };
7
+ export let size = "1rem";
8
+ export let weight = 1;
9
+ const getGradientDirection = (direction) => {
10
+ switch (direction) {
11
+ case "top":
12
+ return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
13
+ case "right":
14
+ return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
15
+ case "bottom":
16
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
17
+ case "left":
18
+ return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
19
+ default:
20
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
21
+ }
22
+ };
29
23
  </script>
30
24
 
31
- {#if gradient !== undefined}
25
+ {#if gradient.colors[1] !== ""}
32
26
  <svg
33
27
  xmlns="http://www.w3.org/2000/svg"
34
28
  style="width: {size}; height: {size};"
@@ -1,34 +1,28 @@
1
1
 
2
- <script lang="ts">
3
- interface GradientObj {
4
- colors: [string, string];
5
- direction: "top" | "right" | "bottom" | "left";
6
- }
7
- export let color = "#000";
8
- export let gradient: GradientObj = {
9
- colors: ["", ""],
10
- direction: "bottom",
11
- };
12
- export let size: string = "1rem";
13
- export let weight: number = 1;
14
-
15
- const getGradientDirection = (direction: string) => {
16
- switch (direction) {
17
- case "top":
18
- return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
19
- case "right":
20
- return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
21
- case "bottom":
22
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
23
- case "left":
24
- return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
25
- default:
26
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
27
- }
28
- };
2
+ <script>export let color = "#000";
3
+ export let gradient = {
4
+ colors: ["", ""],
5
+ direction: "bottom"
6
+ };
7
+ export let size = "1rem";
8
+ export let weight = 1;
9
+ const getGradientDirection = (direction) => {
10
+ switch (direction) {
11
+ case "top":
12
+ return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
13
+ case "right":
14
+ return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
15
+ case "bottom":
16
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
17
+ case "left":
18
+ return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
19
+ default:
20
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
21
+ }
22
+ };
29
23
  </script>
30
24
 
31
- {#if gradient !== undefined}
25
+ {#if gradient.colors[1] !== ""}
32
26
  <svg
33
27
  xmlns="http://www.w3.org/2000/svg"
34
28
  style="width: {size}; height: {size};"
@@ -1,34 +1,28 @@
1
1
 
2
- <script lang="ts">
3
- interface GradientObj {
4
- colors: [string, string];
5
- direction: "top" | "right" | "bottom" | "left";
6
- }
7
- export let color = "#000";
8
- export let gradient: GradientObj = {
9
- colors: ["", ""],
10
- direction: "bottom",
11
- };
12
- export let size: string = "1rem";
13
- export let weight: number = 1;
14
-
15
- const getGradientDirection = (direction: string) => {
16
- switch (direction) {
17
- case "top":
18
- return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
19
- case "right":
20
- return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
21
- case "bottom":
22
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
23
- case "left":
24
- return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
25
- default:
26
- return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
27
- }
28
- };
2
+ <script>export let color = "#000";
3
+ export let gradient = {
4
+ colors: ["", ""],
5
+ direction: "bottom"
6
+ };
7
+ export let size = "1rem";
8
+ export let weight = 1;
9
+ const getGradientDirection = (direction) => {
10
+ switch (direction) {
11
+ case "top":
12
+ return { x1: "0%", y1: "100%", x2: "0%", y2: "0%" };
13
+ case "right":
14
+ return { x1: "0%", y1: "0%", x2: "100%", y2: "0%" };
15
+ case "bottom":
16
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
17
+ case "left":
18
+ return { x1: "100%", y1: "0%", x2: "0%", y2: "0%" };
19
+ default:
20
+ return { x1: "0%", y1: "0%", x2: "0%", y2: "100%" };
21
+ }
22
+ };
29
23
  </script>
30
24
 
31
- {#if gradient !== undefined}
25
+ {#if gradient.colors[1] !== ""}
32
26
  <svg
33
27
  xmlns="http://www.w3.org/2000/svg"
34
28
  style="width: {size}; height: {size};"