@upstart.gg/sdk 0.0.104 → 0.0.106

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 (254) hide show
  1. package/dist/shared/ajv.d.ts +2 -0
  2. package/dist/shared/ajv.d.ts.map +1 -1
  3. package/dist/shared/ajv.js +1 -1
  4. package/dist/shared/attributes.js +1 -1
  5. package/dist/shared/brick-manifest.js +1 -1
  6. package/dist/shared/bricks/manifests/accordion.manifest.js +1 -1
  7. package/dist/shared/bricks/manifests/all-manifests.js +1 -1
  8. package/dist/shared/bricks/manifests/button.manifest.js +1 -1
  9. package/dist/shared/bricks/manifests/card.manifest.js +1 -1
  10. package/dist/shared/bricks/manifests/carousel.manifest.js +1 -1
  11. package/dist/shared/bricks/manifests/container.manifest.js +1 -1
  12. package/dist/shared/bricks/manifests/divider.manifest.js +1 -1
  13. package/dist/shared/bricks/manifests/footer.manifest.d.ts +1 -1
  14. package/dist/shared/bricks/manifests/footer.manifest.d.ts.map +1 -1
  15. package/dist/shared/bricks/manifests/footer.manifest.js +1 -1
  16. package/dist/shared/bricks/manifests/form.manifest.js +1 -1
  17. package/dist/shared/bricks/manifests/hero.manifest.js +1 -1
  18. package/dist/shared/bricks/manifests/icon.manifest.js +1 -1
  19. package/dist/shared/bricks/manifests/image.manifest.js +1 -1
  20. package/dist/shared/bricks/manifests/images-gallery.manifest.js +1 -1
  21. package/dist/shared/bricks/manifests/map.manifest.js +1 -1
  22. package/dist/shared/bricks/manifests/navbar.manifest.js +1 -1
  23. package/dist/shared/bricks/manifests/sidebar.manifest.js +1 -1
  24. package/dist/shared/bricks/manifests/social-links.manifest.js +1 -1
  25. package/dist/shared/bricks/manifests/testimonials.manifest.js +1 -1
  26. package/dist/shared/bricks/manifests/text.manifest.js +1 -1
  27. package/dist/shared/bricks/manifests/timeline.manifest.js +1 -1
  28. package/dist/shared/bricks/manifests/video.manifest.js +1 -1
  29. package/dist/shared/bricks/props/border.d.ts.map +1 -1
  30. package/dist/shared/bricks/props/border.js +1 -1
  31. package/dist/shared/bricks/props/container.js +1 -1
  32. package/dist/shared/bricks/props/effects.js +1 -1
  33. package/dist/shared/bricks.d.ts.map +1 -1
  34. package/dist/shared/bricks.js +1 -1
  35. package/dist/shared/{chunk-TCZBR3ZU.js → chunk-2DI5SIVV.js} +1 -1
  36. package/dist/shared/{chunk-O22VV7YR.js → chunk-33FU4KGU.js} +1 -1
  37. package/dist/shared/{chunk-WCNVFVDK.js → chunk-3ZGRY444.js} +1 -1
  38. package/dist/shared/{chunk-CUCUHPQ7.js → chunk-6OKXZL6R.js} +1 -1
  39. package/dist/shared/chunk-7E67XSKP.js +3 -0
  40. package/dist/shared/{chunk-LJQXN32B.js → chunk-AMGHA7QH.js} +1 -1
  41. package/dist/shared/{chunk-QALNFBY7.js → chunk-DC5DWF7B.js} +1 -1
  42. package/dist/shared/{chunk-I43NIQ2K.js → chunk-DY2YCYZ6.js} +1 -1
  43. package/dist/shared/{chunk-CEXHD4BO.js → chunk-E4UAVLKC.js} +2 -2
  44. package/dist/shared/{chunk-ZFTWLZ3G.js → chunk-EHH677K5.js} +1 -1
  45. package/dist/shared/{chunk-POYVTV5F.js → chunk-FD3KX2U7.js} +1 -1
  46. package/dist/shared/chunk-G3JO5DM5.js +3 -0
  47. package/dist/shared/{chunk-I5S2MPPR.js → chunk-H7OYUKBW.js} +1 -1
  48. package/dist/shared/{chunk-ATVHWZSA.js → chunk-HBM4DPIW.js} +1 -1
  49. package/dist/shared/chunk-HIBTEX2T.js +3 -0
  50. package/dist/shared/{chunk-E2EBTWJI.js → chunk-I3HSLGFA.js} +1 -1
  51. package/dist/shared/{chunk-UISES3HA.js → chunk-IXJX7EQ3.js} +1 -1
  52. package/dist/shared/{chunk-5IEGQ7YT.js → chunk-JAAPJQNK.js} +1 -1
  53. package/dist/shared/{chunk-UK6H3FDX.js → chunk-JDBVMPSI.js} +1 -1
  54. package/dist/shared/{chunk-F6MLW6DO.js → chunk-JH3NRO6M.js} +1 -1
  55. package/dist/shared/{chunk-ZNVRYEO7.js → chunk-L3TKLJKK.js} +1 -1
  56. package/dist/shared/{chunk-TEPFFY32.js → chunk-LOFXGDAK.js} +1 -1
  57. package/dist/shared/chunk-O3FJP65T.js +3 -0
  58. package/dist/shared/{chunk-7L3UOEMR.js → chunk-PX7QSNLO.js} +1 -1
  59. package/dist/shared/{chunk-22KRCQK5.js → chunk-U76JDFWJ.js} +1 -1
  60. package/dist/shared/{chunk-CW5FWW5W.js → chunk-UYZP24VV.js} +1 -1
  61. package/dist/shared/chunk-X42WBJTN.js +3 -0
  62. package/dist/shared/{chunk-OQIFFJ7I.js → chunk-XB3X4P3I.js} +1 -1
  63. package/dist/shared/chunk-XDCGA4WT.js +3 -0
  64. package/dist/shared/chunk-YGHBFXR6.js +3 -0
  65. package/dist/shared/{chunk-WEQRYCPD.js → chunk-ZWYLKIBI.js} +1 -1
  66. package/dist/shared/datasources/external/rss/fetcher.d.ts +1 -1
  67. package/dist/shared/datasources/external/rss/fetcher.d.ts.map +1 -1
  68. package/dist/shared/images.js +1 -1
  69. package/dist/shared/page.js +1 -1
  70. package/dist/shared/responsive.js +1 -1
  71. package/dist/shared/site.js +1 -1
  72. package/dist/shared/sitemap.js +1 -1
  73. package/dist/shared/theme.js +1 -1
  74. package/dist/shared/utils/schema.d.ts +6 -8
  75. package/dist/shared/utils/schema.d.ts.map +1 -1
  76. package/dist/shared/utils/schema.js +1 -1
  77. package/package.json +5 -9
  78. package/dist/shared/chunk-F63ANNAK.js +0 -3
  79. package/dist/shared/chunk-GPKRRX3D.js +0 -3
  80. package/dist/shared/chunk-HQQYIKTE.js +0 -3
  81. package/dist/shared/chunk-JFDOR3UH.js +0 -3
  82. package/dist/shared/chunk-OD2PRCLH.js +0 -3
  83. package/dist/shared/chunk-PK6UAFPW.js +0 -3
  84. package/dist/shared/chunk-VDHLON5R.js +0 -3
  85. package/src/node/cli/api.ts +0 -101
  86. package/src/node/cli/commands/cmd-build.ts +0 -64
  87. package/src/node/cli/commands/login/cmd-login.ts +0 -111
  88. package/src/node/cli/commands/logout/cmd-logout.ts +0 -11
  89. package/src/node/cli/commands/publish/cmd-publish.ts +0 -135
  90. package/src/node/cli/commands/publish/parse-gitignore.ts +0 -278
  91. package/src/node/cli/commands/publish/uploader.ts +0 -333
  92. package/src/node/cli/constants.ts +0 -14
  93. package/src/node/cli/is-logged-in.ts +0 -28
  94. package/src/node/cli/program.ts +0 -77
  95. package/src/node/cli/store.ts +0 -64
  96. package/src/node/cli/tests/api.test.ts +0 -161
  97. package/src/node/cli/types.ts +0 -34
  98. package/src/node/cli/utils.ts +0 -20
  99. package/src/node/shared/config.ts +0 -69
  100. package/src/node/shared/logger.ts +0 -44
  101. package/src/shared/ajv.ts +0 -103
  102. package/src/shared/analytics/init.ts +0 -14
  103. package/src/shared/analytics/track.ts +0 -21
  104. package/src/shared/analytics/types.ts +0 -13
  105. package/src/shared/attributes.ts +0 -211
  106. package/src/shared/brick-manifest.ts +0 -110
  107. package/src/shared/bricks/manifests/accordion.manifest.ts +0 -179
  108. package/src/shared/bricks/manifests/all-manifests.ts +0 -92
  109. package/src/shared/bricks/manifests/button.manifest.ts +0 -145
  110. package/src/shared/bricks/manifests/card.manifest.ts +0 -269
  111. package/src/shared/bricks/manifests/carousel.manifest.ts +0 -106
  112. package/src/shared/bricks/manifests/container.manifest.ts +0 -357
  113. package/src/shared/bricks/manifests/divider.manifest.ts +0 -121
  114. package/src/shared/bricks/manifests/footer.manifest.ts +0 -487
  115. package/src/shared/bricks/manifests/form.manifest.ts +0 -112
  116. package/src/shared/bricks/manifests/hero.manifest.ts +0 -132
  117. package/src/shared/bricks/manifests/icon.manifest.ts +0 -130
  118. package/src/shared/bricks/manifests/image.manifest.ts +0 -203
  119. package/src/shared/bricks/manifests/images-gallery.manifest.ts +0 -227
  120. package/src/shared/bricks/manifests/map.manifest.ts +0 -75
  121. package/src/shared/bricks/manifests/navbar.manifest.ts +0 -344
  122. package/src/shared/bricks/manifests/sidebar.manifest.ts +0 -90
  123. package/src/shared/bricks/manifests/social-links.manifest.ts +0 -370
  124. package/src/shared/bricks/manifests/testimonials.manifest.ts +0 -397
  125. package/src/shared/bricks/manifests/tests/header.manifest.test.ts +0 -10
  126. package/src/shared/bricks/manifests/text.manifest.ts +0 -164
  127. package/src/shared/bricks/manifests/timeline.manifest.ts +0 -456
  128. package/src/shared/bricks/manifests/video.manifest.ts +0 -59
  129. package/src/shared/bricks/props/_style-presets.ts +0 -352
  130. package/src/shared/bricks/props/align.ts +0 -59
  131. package/src/shared/bricks/props/background.ts +0 -118
  132. package/src/shared/bricks/props/boolean.ts +0 -11
  133. package/src/shared/bricks/props/border.ts +0 -84
  134. package/src/shared/bricks/props/color.ts +0 -24
  135. package/src/shared/bricks/props/common.ts +0 -37
  136. package/src/shared/bricks/props/container.ts +0 -356
  137. package/src/shared/bricks/props/css-length.ts +0 -25
  138. package/src/shared/bricks/props/datasource.ts +0 -60
  139. package/src/shared/bricks/props/date.ts +0 -24
  140. package/src/shared/bricks/props/effects.ts +0 -123
  141. package/src/shared/bricks/props/enum.ts +0 -42
  142. package/src/shared/bricks/props/file.ts +0 -12
  143. package/src/shared/bricks/props/geolocation.ts +0 -30
  144. package/src/shared/bricks/props/helpers.ts +0 -101
  145. package/src/shared/bricks/props/image.ts +0 -90
  146. package/src/shared/bricks/props/number.ts +0 -16
  147. package/src/shared/bricks/props/padding.ts +0 -21
  148. package/src/shared/bricks/props/position.ts +0 -27
  149. package/src/shared/bricks/props/preset.ts +0 -136
  150. package/src/shared/bricks/props/string.ts +0 -56
  151. package/src/shared/bricks/props/tests/align.test.ts +0 -37
  152. package/src/shared/bricks/props/tests/background.test.ts +0 -102
  153. package/src/shared/bricks/props/tests/border.test.ts +0 -38
  154. package/src/shared/bricks/props/tests/effects.test.ts +0 -37
  155. package/src/shared/bricks/props/tests/helpers.test.ts +0 -133
  156. package/src/shared/bricks/props/tests/image.test.ts +0 -71
  157. package/src/shared/bricks/props/tests/padding.ts +0 -12
  158. package/src/shared/bricks/props/tests/string.test.ts +0 -79
  159. package/src/shared/bricks/props/text.ts +0 -66
  160. package/src/shared/bricks/props/types.ts +0 -57
  161. package/src/shared/bricks.ts +0 -232
  162. package/src/shared/context.ts +0 -39
  163. package/src/shared/datarecords/external/airtable/handler.ts +0 -21
  164. package/src/shared/datarecords/external/airtable/options.ts +0 -22
  165. package/src/shared/datarecords/external/generic-webhook/handler.ts +0 -10
  166. package/src/shared/datarecords/external/generic-webhook/options.ts +0 -13
  167. package/src/shared/datarecords/external/google/oauth/config.ts +0 -30
  168. package/src/shared/datarecords/external/google/sheets/handler.ts +0 -26
  169. package/src/shared/datarecords/external/google/sheets/options.ts +0 -9
  170. package/src/shared/datarecords/types.ts +0 -120
  171. package/src/shared/datarecords.ts +0 -5
  172. package/src/shared/datasources/README.md +0 -3
  173. package/src/shared/datasources/external/facebook/posts/fetcher.ts +0 -52
  174. package/src/shared/datasources/external/facebook/posts/sample.ts +0 -35
  175. package/src/shared/datasources/external/facebook/posts/schema.ts +0 -33
  176. package/src/shared/datasources/external/facebook/posts/tests/fetcher.test.ts +0 -73
  177. package/src/shared/datasources/external/http-json/fetcher.ts +0 -28
  178. package/src/shared/datasources/external/http-json/options.ts +0 -12
  179. package/src/shared/datasources/external/http-json/schema.ts +0 -6
  180. package/src/shared/datasources/external/http-json/tests/fetcher.test.ts +0 -70
  181. package/src/shared/datasources/external/instagram/feed/fetcher.ts +0 -33
  182. package/src/shared/datasources/external/instagram/feed/sample.ts +0 -22
  183. package/src/shared/datasources/external/instagram/feed/schema.ts +0 -23
  184. package/src/shared/datasources/external/instagram/feed/tests/fetcher.test.ts +0 -64
  185. package/src/shared/datasources/external/mastodon/account/fetcher.ts +0 -24
  186. package/src/shared/datasources/external/mastodon/account/sample.ts +0 -33
  187. package/src/shared/datasources/external/mastodon/account/schema.ts +0 -45
  188. package/src/shared/datasources/external/mastodon/account/tests/fetcher.test.ts +0 -47
  189. package/src/shared/datasources/external/mastodon/options.ts +0 -11
  190. package/src/shared/datasources/external/mastodon/status/fetcher.ts +0 -35
  191. package/src/shared/datasources/external/mastodon/status/sample.array.ts +0 -59
  192. package/src/shared/datasources/external/mastodon/status/sample.single.ts +0 -55
  193. package/src/shared/datasources/external/mastodon/status/schema.ts +0 -130
  194. package/src/shared/datasources/external/mastodon/status/tests/fetcher.test.ts +0 -74
  195. package/src/shared/datasources/external/meta/oauth/config.ts +0 -16
  196. package/src/shared/datasources/external/meta/options.ts +0 -11
  197. package/src/shared/datasources/external/rss/fetcher.ts +0 -29
  198. package/src/shared/datasources/external/rss/options.ts +0 -11
  199. package/src/shared/datasources/external/rss/sample.ts +0 -22
  200. package/src/shared/datasources/external/rss/schema.ts +0 -42
  201. package/src/shared/datasources/external/threads/media/fetcher.ts +0 -53
  202. package/src/shared/datasources/external/threads/media/sample.ts +0 -44
  203. package/src/shared/datasources/external/threads/media/schema.ts +0 -37
  204. package/src/shared/datasources/external/tiktok/oauth/config.ts +0 -17
  205. package/src/shared/datasources/external/tiktok/video/fetcher.ts +0 -39
  206. package/src/shared/datasources/external/tiktok/video/options.ts +0 -12
  207. package/src/shared/datasources/external/tiktok/video/sample.ts +0 -26
  208. package/src/shared/datasources/external/tiktok/video/schema.ts +0 -27
  209. package/src/shared/datasources/external/youtube/list/fetcher.ts +0 -37
  210. package/src/shared/datasources/external/youtube/list/options.ts +0 -15
  211. package/src/shared/datasources/external/youtube/list/sample.ts +0 -33
  212. package/src/shared/datasources/external/youtube/list/schema.ts +0 -38
  213. package/src/shared/datasources/external/youtube/oauth/config.ts +0 -15
  214. package/src/shared/datasources/fetcher.ts +0 -17
  215. package/src/shared/datasources/internal/blog/schema.ts +0 -69
  216. package/src/shared/datasources/internal/changelog/schema.ts +0 -48
  217. package/src/shared/datasources/internal/contact-info/schema.ts +0 -20
  218. package/src/shared/datasources/internal/cv/schema.ts +0 -217
  219. package/src/shared/datasources/internal/faq/schema.ts +0 -27
  220. package/src/shared/datasources/internal/job-board/schema.ts +0 -228
  221. package/src/shared/datasources/internal/links/schema.ts +0 -15
  222. package/src/shared/datasources/internal/recipes/schema.ts +0 -42
  223. package/src/shared/datasources/internal/restaurant/schema.ts +0 -225
  224. package/src/shared/datasources/provider-options.ts +0 -7
  225. package/src/shared/datasources/samples.ts +0 -26
  226. package/src/shared/datasources/schemas.ts +0 -45
  227. package/src/shared/datasources/types.ts +0 -276
  228. package/src/shared/datasources/utils.ts +0 -16
  229. package/src/shared/datasources.ts +0 -42
  230. package/src/shared/env.ts +0 -23
  231. package/src/shared/errors.ts +0 -1
  232. package/src/shared/images.ts +0 -44
  233. package/src/shared/index.ts +0 -3
  234. package/src/shared/layout-constants.ts +0 -25
  235. package/src/shared/manifest.ts +0 -50
  236. package/src/shared/oauth.ts +0 -16
  237. package/src/shared/page.ts +0 -61
  238. package/src/shared/prompt.ts +0 -9
  239. package/src/shared/responsive.ts +0 -5
  240. package/src/shared/site.ts +0 -97
  241. package/src/shared/sitemap.ts +0 -66
  242. package/src/shared/social-icons.ts +0 -307
  243. package/src/shared/tests/attributes.test.ts +0 -37
  244. package/src/shared/theme.ts +0 -245
  245. package/src/shared/themes/README.md +0 -34
  246. package/src/shared/themes/color-system.ts +0 -127
  247. package/src/shared/utils/canvas-data-uri.ts +0 -2
  248. package/src/shared/utils/invariant.ts +0 -25
  249. package/src/shared/utils/json-date.ts +0 -8
  250. package/src/shared/utils/merge.ts +0 -12
  251. package/src/shared/utils/object-hash.ts +0 -7
  252. package/src/shared/utils/schema.ts +0 -35
  253. package/src/shared/utils/try-catch.ts +0 -12
  254. package/src/shared/utils/typed-ref.ts +0 -41
@@ -1,487 +0,0 @@
1
- import { Type } from "@sinclair/typebox";
2
- import { defineBrickManifest } from "~/shared/brick-manifest";
3
- import { array, defineProps, group, optional } from "../props/helpers";
4
- import { number } from "../props/number";
5
- import { string, urlOrPageId, urlOrPageIdRef } from "../props/string";
6
- import { VscLayoutPanelOff } from "react-icons/vsc";
7
- import { image, imageRef } from "../props/image";
8
- import { preset } from "../props/preset";
9
- import type { BrickProps } from "../props/types";
10
- import type { FC } from "react";
11
- import { backgroundColorRef } from "../props/background";
12
-
13
- export const manifest = defineBrickManifest({
14
- type: "footer",
15
- kind: "widget",
16
- name: "Footer",
17
- description: "A footer with links and an optional logo",
18
- icon: VscLayoutPanelOff,
19
- props: defineProps({
20
- variants: Type.Array(
21
- Type.Union(
22
- [
23
- Type.Literal("logo-left", { title: "Logo on the left", description: "Logo on the left" }),
24
- Type.Literal("logo-right", { title: "Logo on the right", description: "Logo on the right" }),
25
- Type.Literal("logo-center", { title: "Logo on the center", description: "Logo at center" }),
26
- Type.Literal("multiple-rows", {
27
- title: "Span on multiple rows.",
28
- description: "Span on multiple rows. Use when there a a lot of links sections",
29
- }),
30
- ],
31
- {
32
- title: "Variant",
33
- description: "Footer variants.",
34
- },
35
- ),
36
- ),
37
- backgroundColor: optional(backgroundColorRef()),
38
- logo: optional(imageRef({ title: "Logo" })),
39
- linksSections: array(
40
- Type.Object({
41
- sectionTitle: string("Links Section title"),
42
- row: optional(number("Row", 0, { description: "Row number of the section" })),
43
- links: array(
44
- Type.Object({
45
- title: string("Title"),
46
- url: urlOrPageIdRef(),
47
- column: optional(number("Column", 1)),
48
- }),
49
- ),
50
- }),
51
- ),
52
- }),
53
- });
54
-
55
- export type Manifest = typeof manifest;
56
-
57
- export const examples: {
58
- description: string;
59
- type: string;
60
- props: BrickProps<Manifest>["brick"]["props"];
61
- }[] = [
62
- {
63
- description: "Simple footer with logo on the left",
64
- type: "footer",
65
- props: {
66
- variants: ["logo-left"],
67
- backgroundColor: "#f8f9fa",
68
- logo: {
69
- src: "https://via.placeholder.com/120x40.png?text=Logo",
70
- alt: "Company logo",
71
- },
72
- linksSections: [
73
- {
74
- sectionTitle: "Quick Links",
75
- links: [
76
- { title: "Home", url: "/" },
77
- { title: "About", url: "/about" },
78
- { title: "Contact", url: "/contact" },
79
- ],
80
- },
81
- {
82
- sectionTitle: "Legal",
83
- links: [
84
- { title: "Privacy Policy", url: "/privacy" },
85
- { title: "Terms of Service", url: "/terms" },
86
- ],
87
- },
88
- ],
89
- },
90
- },
91
- {
92
- description: "Corporate footer with centered logo",
93
- type: "footer",
94
- props: {
95
- variants: ["logo-center"],
96
- backgroundColor: "#2c3e50",
97
- logo: {
98
- src: "https://via.placeholder.com/150x50.png?text=Corporate",
99
- alt: "Corporate logo",
100
- },
101
- linksSections: [
102
- {
103
- sectionTitle: "Products",
104
- links: [
105
- { title: "Software Solutions", url: "/products/software" },
106
- { title: "Consulting", url: "/products/consulting" },
107
- { title: "Support", url: "/products/support" },
108
- { title: "Training", url: "/products/training" },
109
- ],
110
- },
111
- {
112
- sectionTitle: "Company",
113
- links: [
114
- { title: "About Us", url: "/about" },
115
- { title: "Careers", url: "/careers" },
116
- { title: "News", url: "/news" },
117
- { title: "Investors", url: "/investors" },
118
- ],
119
- },
120
- {
121
- sectionTitle: "Resources",
122
- links: [
123
- { title: "Documentation", url: "/docs" },
124
- { title: "API Reference", url: "/api" },
125
- { title: "Community", url: "/community" },
126
- { title: "Blog", url: "/blog" },
127
- ],
128
- },
129
- ],
130
- },
131
- },
132
- {
133
- description: "E-commerce footer with logo on the right",
134
- type: "footer",
135
- props: {
136
- variants: ["logo-right"],
137
- backgroundColor: "#ffffff",
138
- logo: {
139
- src: "https://via.placeholder.com/140x45.png?text=Shop",
140
- alt: "Shop logo",
141
- },
142
- linksSections: [
143
- {
144
- sectionTitle: "Shop",
145
- links: [
146
- { title: "All Products", url: "/products" },
147
- { title: "New Arrivals", url: "/new" },
148
- { title: "Sale", url: "/sale" },
149
- { title: "Gift Cards", url: "/gift-cards" },
150
- ],
151
- },
152
- {
153
- sectionTitle: "Customer Service",
154
- links: [
155
- { title: "Help Center", url: "/help" },
156
- { title: "Returns", url: "/returns" },
157
- { title: "Shipping Info", url: "/shipping" },
158
- { title: "Size Guide", url: "/size-guide" },
159
- ],
160
- },
161
- {
162
- sectionTitle: "Account",
163
- links: [
164
- { title: "My Account", url: "/account" },
165
- { title: "Order History", url: "/orders" },
166
- { title: "Wishlist", url: "/wishlist" },
167
- ],
168
- },
169
- ],
170
- },
171
- },
172
- {
173
- description: "Large organization footer with multiple rows",
174
- type: "footer",
175
- props: {
176
- variants: ["logo-center", "multiple-rows"],
177
- backgroundColor: "#1a1a1a",
178
- logo: {
179
- src: "https://via.placeholder.com/180x60.png?text=Enterprise",
180
- alt: "Enterprise logo",
181
- },
182
- linksSections: [
183
- {
184
- sectionTitle: "Products & Services",
185
- row: 0,
186
- links: [
187
- { title: "Cloud Solutions", url: "/cloud", column: 1 },
188
- { title: "Data Analytics", url: "/analytics", column: 1 },
189
- { title: "AI & Machine Learning", url: "/ai", column: 1 },
190
- { title: "Cybersecurity", url: "/security", column: 2 },
191
- { title: "DevOps Tools", url: "/devops", column: 2 },
192
- { title: "IoT Platform", url: "/iot", column: 2 },
193
- ],
194
- },
195
- {
196
- sectionTitle: "Industries",
197
- row: 0,
198
- links: [
199
- { title: "Healthcare", url: "/industries/healthcare", column: 3 },
200
- { title: "Finance", url: "/industries/finance", column: 3 },
201
- { title: "Retail", url: "/industries/retail", column: 3 },
202
- { title: "Manufacturing", url: "/industries/manufacturing", column: 4 },
203
- { title: "Education", url: "/industries/education", column: 4 },
204
- { title: "Government", url: "/industries/government", column: 4 },
205
- ],
206
- },
207
- {
208
- sectionTitle: "Resources",
209
- row: 1,
210
- links: [
211
- { title: "Documentation", url: "/docs", column: 1 },
212
- { title: "API Reference", url: "/api", column: 1 },
213
- { title: "Tutorials", url: "/tutorials", column: 1 },
214
- { title: "Webinars", url: "/webinars", column: 2 },
215
- { title: "White Papers", url: "/whitepapers", column: 2 },
216
- { title: "Case Studies", url: "/case-studies", column: 2 },
217
- ],
218
- },
219
- {
220
- sectionTitle: "Support & Community",
221
- row: 1,
222
- links: [
223
- { title: "Help Center", url: "/help", column: 3 },
224
- { title: "Community Forum", url: "/forum", column: 3 },
225
- { title: "Contact Support", url: "/support", column: 3 },
226
- { title: "Service Status", url: "/status", column: 4 },
227
- { title: "Partner Portal", url: "/partners", column: 4 },
228
- { title: "Developer Hub", url: "/developers", column: 4 },
229
- ],
230
- },
231
- ],
232
- },
233
- },
234
- {
235
- description: "Startup footer with minimal links and left logo",
236
- type: "footer",
237
- props: {
238
- variants: ["logo-left"],
239
- backgroundColor: "#f5f5f5",
240
- logo: {
241
- src: "https://via.placeholder.com/100x35.png?text=Startup",
242
- alt: "Startup logo",
243
- },
244
- linksSections: [
245
- {
246
- sectionTitle: "Company",
247
- links: [
248
- { title: "About", url: "/about" },
249
- { title: "Team", url: "/team" },
250
- { title: "Jobs", url: "/jobs" },
251
- ],
252
- },
253
- {
254
- sectionTitle: "Product",
255
- links: [
256
- { title: "Features", url: "/features" },
257
- { title: "Pricing", url: "/pricing" },
258
- { title: "Demo", url: "/demo" },
259
- ],
260
- },
261
- {
262
- sectionTitle: "Support",
263
- links: [
264
- { title: "Help", url: "/help" },
265
- { title: "Contact", url: "/contact" },
266
- ],
267
- },
268
- ],
269
- },
270
- },
271
- {
272
- description: "Agency footer with centered logo and creative sections",
273
- type: "footer",
274
- props: {
275
- variants: ["logo-center"],
276
- backgroundColor: "#6366f1",
277
- logo: {
278
- src: "https://via.placeholder.com/130x45.png?text=Agency",
279
- alt: "Creative agency logo",
280
- },
281
- linksSections: [
282
- {
283
- sectionTitle: "Services",
284
- links: [
285
- { title: "Web Design", url: "/services/web-design" },
286
- { title: "Branding", url: "/services/branding" },
287
- { title: "Digital Marketing", url: "/services/marketing" },
288
- { title: "Photography", url: "/services/photography" },
289
- ],
290
- },
291
- {
292
- sectionTitle: "Portfolio",
293
- links: [
294
- { title: "Recent Work", url: "/portfolio" },
295
- { title: "Case Studies", url: "/case-studies" },
296
- { title: "Client Reviews", url: "/reviews" },
297
- ],
298
- },
299
- {
300
- sectionTitle: "Connect",
301
- links: [
302
- { title: "Contact Us", url: "/contact" },
303
- { title: "Get Quote", url: "/quote" },
304
- { title: "Newsletter", url: "/newsletter" },
305
- ],
306
- },
307
- ],
308
- },
309
- },
310
- {
311
- description: "SaaS platform footer with comprehensive links",
312
- type: "footer",
313
- props: {
314
- variants: ["logo-left", "multiple-rows"],
315
- backgroundColor: "#0f172a",
316
- logo: {
317
- src: "https://via.placeholder.com/160x50.png?text=SaaS+Platform",
318
- alt: "SaaS platform logo",
319
- },
320
- linksSections: [
321
- {
322
- sectionTitle: "Platform",
323
- row: 0,
324
- links: [
325
- { title: "Dashboard", url: "/dashboard", column: 1 },
326
- { title: "Analytics", url: "/analytics", column: 1 },
327
- { title: "Integrations", url: "/integrations", column: 1 },
328
- { title: "API", url: "/api", column: 1 },
329
- ],
330
- },
331
- {
332
- sectionTitle: "Solutions",
333
- row: 0,
334
- links: [
335
- { title: "For Startups", url: "/solutions/startups", column: 2 },
336
- { title: "For Enterprise", url: "/solutions/enterprise", column: 2 },
337
- { title: "For Agencies", url: "/solutions/agencies", column: 2 },
338
- { title: "For Developers", url: "/solutions/developers", column: 2 },
339
- ],
340
- },
341
- {
342
- sectionTitle: "Resources",
343
- row: 1,
344
- links: [
345
- { title: "Blog", url: "/blog", column: 1 },
346
- { title: "Documentation", url: "/docs", column: 1 },
347
- { title: "Help Center", url: "/help", column: 1 },
348
- { title: "Community", url: "/community", column: 1 },
349
- ],
350
- },
351
- {
352
- sectionTitle: "Company",
353
- row: 1,
354
- links: [
355
- { title: "About Us", url: "/about", column: 2 },
356
- { title: "Careers", url: "/careers", column: 2 },
357
- { title: "Press", url: "/press", column: 2 },
358
- { title: "Legal", url: "/legal", column: 2 },
359
- ],
360
- },
361
- ],
362
- },
363
- },
364
- {
365
- description: "Non-profit footer with mission-focused links",
366
- type: "footer",
367
- props: {
368
- variants: ["logo-center"],
369
- backgroundColor: "#059669",
370
- logo: {
371
- src: "https://via.placeholder.com/140x50.png?text=Non+Profit",
372
- alt: "Non-profit organization logo",
373
- },
374
- linksSections: [
375
- {
376
- sectionTitle: "Our Work",
377
- links: [
378
- { title: "Programs", url: "/programs" },
379
- { title: "Impact", url: "/impact" },
380
- { title: "Success Stories", url: "/stories" },
381
- { title: "Research", url: "/research" },
382
- ],
383
- },
384
- {
385
- sectionTitle: "Get Involved",
386
- links: [
387
- { title: "Donate", url: "/donate" },
388
- { title: "Volunteer", url: "/volunteer" },
389
- { title: "Events", url: "/events" },
390
- { title: "Partner with Us", url: "/partnerships" },
391
- ],
392
- },
393
- {
394
- sectionTitle: "About",
395
- links: [
396
- { title: "Our Mission", url: "/mission" },
397
- { title: "Leadership", url: "/leadership" },
398
- { title: "Annual Reports", url: "/reports" },
399
- { title: "Contact", url: "/contact" },
400
- ],
401
- },
402
- ],
403
- },
404
- },
405
- {
406
- description: "Tech blog footer with right-aligned logo",
407
- type: "footer",
408
- props: {
409
- variants: ["logo-right"],
410
- backgroundColor: "#111827",
411
- logo: {
412
- src: "https://via.placeholder.com/120x40.png?text=Tech+Blog",
413
- alt: "Tech blog logo",
414
- },
415
- linksSections: [
416
- {
417
- sectionTitle: "Categories",
418
- links: [
419
- { title: "Web Development", url: "/category/web-dev" },
420
- { title: "AI & ML", url: "/category/ai-ml" },
421
- { title: "DevOps", url: "/category/devops" },
422
- { title: "Mobile", url: "/category/mobile" },
423
- ],
424
- },
425
- {
426
- sectionTitle: "Popular",
427
- links: [
428
- { title: "Latest Posts", url: "/latest" },
429
- { title: "Trending", url: "/trending" },
430
- { title: "Best of 2024", url: "/best-2024" },
431
- { title: "Tutorials", url: "/tutorials" },
432
- ],
433
- },
434
- {
435
- sectionTitle: "Community",
436
- links: [
437
- { title: "Newsletter", url: "/newsletter" },
438
- { title: "Discord", url: "/discord" },
439
- { title: "Contributors", url: "/contributors" },
440
- { title: "Write for Us", url: "/write" },
441
- ],
442
- },
443
- ],
444
- },
445
- },
446
- {
447
- description: "Restaurant footer with location and menu links",
448
- type: "footer",
449
- props: {
450
- variants: ["logo-center"],
451
- backgroundColor: "#7c2d12",
452
- logo: {
453
- src: "https://via.placeholder.com/150x60.png?text=Restaurant",
454
- alt: "Restaurant logo",
455
- },
456
- linksSections: [
457
- {
458
- sectionTitle: "Menu",
459
- links: [
460
- { title: "Appetizers", url: "/menu/appetizers" },
461
- { title: "Main Courses", url: "/menu/mains" },
462
- { title: "Desserts", url: "/menu/desserts" },
463
- { title: "Beverages", url: "/menu/drinks" },
464
- ],
465
- },
466
- {
467
- sectionTitle: "Services",
468
- links: [
469
- { title: "Reservations", url: "/reservations" },
470
- { title: "Catering", url: "/catering" },
471
- { title: "Private Events", url: "/events" },
472
- { title: "Gift Cards", url: "/gift-cards" },
473
- ],
474
- },
475
- {
476
- sectionTitle: "Info",
477
- links: [
478
- { title: "About Us", url: "/about" },
479
- { title: "Location", url: "/location" },
480
- { title: "Hours", url: "/hours" },
481
- { title: "Contact", url: "/contact" },
482
- ],
483
- },
484
- ],
485
- },
486
- },
487
- ];
@@ -1,112 +0,0 @@
1
- import { defineBrickManifest } from "~/shared/brick-manifest";
2
- import { defineProps, optional, prop } from "../props/helpers";
3
- import { FaWpforms } from "react-icons/fa6";
4
- import { Type } from "@sinclair/typebox";
5
- import { string } from "../props/string";
6
- import type { BrickProps } from "../props/types";
7
- import { StringDecoder } from "node:string_decoder";
8
- import { StringEnum } from "~/shared/utils/schema";
9
- import type { FC } from "react";
10
- import { paddingRef } from "../props/padding";
11
- import { backgroundColorRef } from "../props/background";
12
- import { colorRef } from "../props/color";
13
-
14
- export const manifest = defineBrickManifest({
15
- type: "form",
16
- kind: "widget",
17
- name: "Form",
18
- description: "A form element",
19
- aiInstructions: `The form brick automatically renders form fields based on the datarecord id provided in the props.
20
- There is no need to define the form fields manually and the form does not accept any children`,
21
- isContainer: false,
22
- icon: FaWpforms,
23
- props: defineProps({
24
- title: optional(string("Title", "My form", { description: "The title of the form" })),
25
- intro: optional(string("Intro", undefined, { description: "The intro text of the form" })),
26
- datarecordId: string("Datarecord ID", undefined, {
27
- description: "The ID of the datarecord to use to generate the form fields",
28
- }),
29
- padding: optional(paddingRef),
30
- backgroundColor: optional(backgroundColorRef()),
31
- color: optional(colorRef()),
32
- align: optional(
33
- prop({
34
- title: "Alignment",
35
- description: "The alignment of the form fields. Default is vertical",
36
- schema: StringEnum(["vertical", "horizontal"], {
37
- default: "vertical",
38
- title: "Form alignment",
39
- description: "Choose between vertical or horizontal alignment for the form fields",
40
- }),
41
- }),
42
- ),
43
- }),
44
- });
45
-
46
- export type Manifest = typeof manifest;
47
- export const examples: {
48
- description: string;
49
- type: string;
50
- props: BrickProps<Manifest>["brick"]["props"];
51
- }[] = [
52
- {
53
- description: "Basic contact form",
54
- type: "form",
55
- props: {
56
- title: "Contact Us",
57
- intro: "We'd love to hear from you. Send us a message and we'll respond as soon as possible.",
58
- align: "vertical",
59
- datarecordId: "contacts",
60
- },
61
- },
62
- {
63
- description: "User registration form",
64
- type: "form",
65
- props: {
66
- title: "Create Account",
67
- intro: "Join our platform and start your journey today.",
68
- align: "vertical",
69
- datarecordId: "user-registration",
70
- },
71
- },
72
- {
73
- description: "Newsletter subscription form (horizontal)",
74
- type: "form",
75
- props: {
76
- title: "Stay Updated",
77
- intro: "Subscribe to our newsletter for the latest updates and exclusive content.",
78
- align: "horizontal",
79
- datarecordId: "newsletter-subscription",
80
- },
81
- },
82
- {
83
- description: "Event registration form",
84
- type: "form",
85
- props: {
86
- title: "Conference Registration",
87
- intro: "Register for the Annual Tech Conference 2025. Early bird pricing ends soon!",
88
- align: "vertical",
89
- datarecordId: "event-registration",
90
- },
91
- },
92
- {
93
- description: "Job application form",
94
- type: "form",
95
- props: {
96
- title: "Apply for Position",
97
- intro: "We're excited to learn more about you! Please fill out this application form completely.",
98
- align: "vertical",
99
- datarecordId: "job-application",
100
- },
101
- },
102
- {
103
- description: "Customer feedback form",
104
- type: "form",
105
- props: {
106
- title: "Share Your Feedback",
107
- intro: "Your opinion matters to us. Help us improve our products and services.",
108
- align: "vertical",
109
- datarecordId: "customer-feedback",
110
- },
111
- },
112
- ];