@upstart.gg/sdk 0.0.129 → 0.0.131
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.
- package/dist/shared/ai/schemas.d.ts +13 -0
- package/dist/shared/ai/schemas.d.ts.map +1 -0
- package/dist/shared/ai/schemas.js +3 -0
- package/dist/shared/ai/types.d.ts +164 -0
- package/dist/shared/ai/types.d.ts.map +1 -0
- package/dist/shared/{chunk-EJGNYD4V.js → ai/types.js} +0 -1
- package/dist/shared/ajv.d.ts +2 -1
- package/dist/shared/ajv.d.ts.map +1 -1
- package/dist/shared/ajv.js +1 -1
- package/dist/shared/attributes.d.ts +300 -12
- package/dist/shared/attributes.d.ts.map +1 -1
- package/dist/shared/attributes.js +1 -1
- package/dist/shared/brick-manifest.d.ts +3 -1
- package/dist/shared/brick-manifest.d.ts.map +1 -1
- package/dist/shared/brick-manifest.js +1 -1
- package/dist/shared/bricks/manifests/accordion.manifest.d.ts +4 -3
- package/dist/shared/bricks/manifests/accordion.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/accordion.manifest.js +1 -1
- package/dist/shared/bricks/manifests/all-manifests.d.ts +4 -1
- package/dist/shared/bricks/manifests/all-manifests.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/all-manifests.js +1 -1
- package/dist/shared/bricks/manifests/box.manifest.d.ts +6 -4
- package/dist/shared/bricks/manifests/box.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/box.manifest.js +1 -1
- package/dist/shared/bricks/manifests/button.manifest.d.ts +4 -3
- package/dist/shared/bricks/manifests/button.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/button.manifest.js +1 -1
- package/dist/shared/bricks/manifests/card.manifest.d.ts +6 -5
- package/dist/shared/bricks/manifests/card.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/card.manifest.js +1 -1
- package/dist/shared/bricks/manifests/carousel.manifest.d.ts +6 -5
- package/dist/shared/bricks/manifests/carousel.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/carousel.manifest.js +1 -1
- package/dist/shared/bricks/manifests/footer.manifest.d.ts +40 -5
- package/dist/shared/bricks/manifests/footer.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/footer.manifest.js +1 -1
- package/dist/shared/bricks/manifests/form.manifest.d.ts +6 -5
- package/dist/shared/bricks/manifests/form.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/form.manifest.js +1 -1
- package/dist/shared/bricks/manifests/hero.manifest.d.ts +4 -3
- package/dist/shared/bricks/manifests/hero.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/hero.manifest.js +1 -1
- package/dist/shared/bricks/manifests/html.manifest.d.ts +3 -2
- package/dist/shared/bricks/manifests/html.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/html.manifest.js +1 -1
- package/dist/shared/bricks/manifests/icon.manifest.d.ts +3 -2
- package/dist/shared/bricks/manifests/icon.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/icon.manifest.js +1 -1
- package/dist/shared/bricks/manifests/image.manifest.d.ts +10 -6
- package/dist/shared/bricks/manifests/image.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/image.manifest.js +1 -1
- package/dist/shared/bricks/manifests/images-gallery.manifest.d.ts +7 -6
- package/dist/shared/bricks/manifests/images-gallery.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/images-gallery.manifest.js +1 -1
- package/dist/shared/bricks/manifests/map.manifest.d.ts +5 -4
- package/dist/shared/bricks/manifests/map.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/map.manifest.js +1 -1
- package/dist/shared/bricks/manifests/navbar.manifest.d.ts +42 -8
- package/dist/shared/bricks/manifests/navbar.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/navbar.manifest.js +1 -1
- package/dist/shared/bricks/manifests/sidebar.manifest.d.ts +4 -3
- package/dist/shared/bricks/manifests/sidebar.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/sidebar.manifest.js +1 -1
- package/dist/shared/bricks/manifests/social-links.manifest.d.ts +5 -4
- package/dist/shared/bricks/manifests/social-links.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/social-links.manifest.js +1 -1
- package/dist/shared/bricks/manifests/spacer.manifest.d.ts +3 -2
- package/dist/shared/bricks/manifests/spacer.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/spacer.manifest.js +1 -1
- package/dist/shared/bricks/manifests/testimonials.manifest.d.ts +6 -5
- package/dist/shared/bricks/manifests/testimonials.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/testimonials.manifest.js +1 -1
- package/dist/shared/bricks/manifests/text.manifest.d.ts +4 -3
- package/dist/shared/bricks/manifests/text.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/text.manifest.js +1 -1
- package/dist/shared/bricks/manifests/video.manifest.d.ts +4 -3
- package/dist/shared/bricks/manifests/video.manifest.d.ts.map +1 -1
- package/dist/shared/bricks/manifests/video.manifest.js +1 -1
- package/dist/shared/bricks/props/align.d.ts.map +1 -1
- package/dist/shared/bricks/props/align.js +1 -1
- package/dist/shared/bricks/props/background.d.ts +6 -9
- package/dist/shared/bricks/props/background.d.ts.map +1 -1
- package/dist/shared/bricks/props/background.js +1 -1
- package/dist/shared/bricks/props/border.d.ts.map +1 -1
- package/dist/shared/bricks/props/border.js +1 -1
- package/dist/shared/bricks/props/color-preset.d.ts +3 -4
- package/dist/shared/bricks/props/color-preset.d.ts.map +1 -1
- package/dist/shared/bricks/props/color-preset.js +1 -1
- package/dist/shared/bricks/props/color.js +1 -1
- package/dist/shared/bricks/props/common.d.ts +6 -6
- package/dist/shared/bricks/props/common.d.ts.map +1 -1
- package/dist/shared/bricks/props/common.js +1 -1
- package/dist/shared/bricks/props/css-length.d.ts.map +1 -1
- package/dist/shared/bricks/props/css-length.js +1 -1
- package/dist/shared/bricks/props/datasource.d.ts +1 -1
- package/dist/shared/bricks/props/datasource.js +1 -1
- package/dist/shared/bricks/props/date.d.ts.map +1 -1
- package/dist/shared/bricks/props/date.js +1 -1
- package/dist/shared/bricks/props/direction.d.ts.map +1 -1
- package/dist/shared/bricks/props/direction.js +1 -1
- package/dist/shared/bricks/props/dynamic.d.ts.map +1 -1
- package/dist/shared/bricks/props/dynamic.js +1 -1
- package/dist/shared/bricks/props/effects.d.ts +0 -1
- package/dist/shared/bricks/props/effects.d.ts.map +1 -1
- package/dist/shared/bricks/props/effects.js +1 -1
- package/dist/shared/bricks/props/file.d.ts.map +1 -1
- package/dist/shared/bricks/props/file.js +1 -1
- package/dist/shared/bricks/props/geolocation.js +1 -1
- package/dist/shared/bricks/props/helpers.d.ts +2 -2
- package/dist/shared/bricks/props/helpers.js +1 -1
- package/dist/shared/bricks/props/image.d.ts +4 -4
- package/dist/shared/bricks/props/image.d.ts.map +1 -1
- package/dist/shared/bricks/props/image.js +1 -1
- package/dist/shared/bricks/props/position.d.ts +0 -2
- package/dist/shared/bricks/props/position.d.ts.map +1 -1
- package/dist/shared/bricks/props/position.js +1 -1
- package/dist/shared/bricks/props/string.js +1 -1
- package/dist/shared/bricks/props/tags.d.ts.map +1 -1
- package/dist/shared/bricks/props/tags.js +1 -1
- package/dist/shared/bricks/props/text.js +1 -1
- package/dist/shared/bricks/props/types.d.ts +1 -2
- package/dist/shared/bricks/props/types.d.ts.map +1 -1
- package/dist/shared/bricks.d.ts +189 -18
- package/dist/shared/bricks.d.ts.map +1 -1
- package/dist/shared/bricks.js +1 -1
- package/dist/shared/chunk-2CYAFF56.js +3 -0
- package/dist/shared/chunk-2NLDX5FG.js +3 -0
- package/dist/shared/chunk-3FPFR5RA.js +3 -0
- package/dist/shared/chunk-3P36LG6T.js +3 -0
- package/dist/shared/chunk-3QOAHMV4.js +5 -0
- package/dist/shared/chunk-4GIZ6WSG.js +3 -0
- package/dist/shared/chunk-5WY7LYXK.js +3 -0
- package/dist/shared/chunk-5X5SX5N7.js +4 -0
- package/dist/shared/chunk-6L3Z5SZQ.js +3 -0
- package/dist/shared/{chunk-UU2MSQXY.js → chunk-6PGAWO4H.js} +1 -1
- package/dist/shared/chunk-6R76KIHZ.js +3 -0
- package/dist/shared/chunk-7UBMXMNJ.js +3 -0
- package/dist/shared/chunk-AB3IMRXZ.js +3 -0
- package/dist/shared/chunk-AMQAGDFH.js +3 -0
- package/dist/shared/chunk-ARMM6B47.js +3 -0
- package/dist/shared/chunk-ARYG4XMX.js +3 -0
- package/dist/shared/chunk-AZHH3XJJ.js +3 -0
- package/dist/shared/chunk-COT2ROEH.js +34 -0
- package/dist/shared/chunk-DHSWVVMI.js +3 -0
- package/dist/shared/chunk-DKNOZLA6.js +3 -0
- package/dist/shared/chunk-EVDZ2KND.js +6 -0
- package/dist/shared/chunk-F4JNKU7J.js +3 -0
- package/dist/shared/chunk-GC5OWY2Z.js +3 -0
- package/dist/shared/chunk-GXNHF6J5.js +3 -0
- package/dist/shared/chunk-HP7CZB2F.js +3 -0
- package/dist/shared/chunk-HSRXUIVM.js +3 -0
- package/dist/shared/chunk-ILIWVWHC.js +8 -0
- package/dist/shared/chunk-JRCVYDCD.js +3 -0
- package/dist/shared/chunk-L2HOZVBC.js +3 -0
- package/dist/shared/chunk-LEWKHCRI.js +3 -0
- package/dist/shared/chunk-LT4CW2F7.js +3 -0
- package/dist/shared/chunk-MVCVVKBY.js +3 -0
- package/dist/shared/chunk-NKIEDT7V.js +3 -0
- package/dist/shared/chunk-NQKXDMQ5.js +3 -0
- package/dist/shared/chunk-NXIF3UMD.js +3 -0
- package/dist/shared/chunk-PW5HRVMD.js +3 -0
- package/dist/shared/chunk-PZYX3ACO.js +3 -0
- package/dist/shared/chunk-QDJQAZIA.js +8 -0
- package/dist/shared/chunk-QGFQA7OZ.js +4 -0
- package/dist/shared/chunk-RJZZWCBD.js +3 -0
- package/dist/shared/chunk-SAJY7H6N.js +3 -0
- package/dist/shared/chunk-SFDRAHYP.js +3 -0
- package/dist/shared/chunk-STDCM2KD.js +3 -0
- package/dist/shared/chunk-TCTVRT4O.js +3 -0
- package/dist/shared/chunk-TH5SONR6.js +3 -0
- package/dist/shared/chunk-UCR2UZOY.js +3 -0
- package/dist/shared/chunk-UDQWYGSO.js +3 -0
- package/dist/shared/{chunk-LSPN22SI.js → chunk-URRCKLAS.js} +3 -3
- package/dist/shared/{chunk-OIOYMECS.js → chunk-US53TNMK.js} +1 -1
- package/dist/shared/chunk-VDX2J22H.js +3 -0
- package/dist/shared/chunk-VE3S4LGT.js +3 -0
- package/dist/shared/chunk-VK26ZZFR.js +3 -0
- package/dist/shared/chunk-VLXZMESE.js +3 -0
- package/dist/shared/chunk-WAML3IGZ.js +3 -0
- package/dist/shared/chunk-WXKRIUTA.js +3 -0
- package/dist/shared/chunk-X62OEAE6.js +3 -0
- package/dist/shared/chunk-XED6ARVN.js +3 -0
- package/dist/shared/chunk-Y3X4F4YJ.js +3 -0
- package/dist/shared/chunk-Z4YKRLOX.js +3 -0
- package/dist/shared/context.d.ts +6 -15
- package/dist/shared/context.d.ts.map +1 -1
- package/dist/shared/datarecords/external/airtable/handler.d.ts +24 -7
- package/dist/shared/datarecords/external/airtable/handler.d.ts.map +1 -1
- package/dist/shared/datarecords/external/airtable/handler.js +3 -0
- package/dist/shared/datarecords/external/airtable/oauth/config.js +3 -0
- package/dist/shared/datarecords/external/airtable/types.d.ts +40 -0
- package/dist/shared/datarecords/external/airtable/types.d.ts.map +1 -0
- package/dist/shared/datarecords/external/airtable/types.js +3 -0
- package/dist/shared/datarecords/external/generic-webhook/handler.js +3 -0
- package/dist/shared/datarecords/external/generic-webhook/options.js +3 -0
- package/dist/shared/datarecords/external/google/sheets/client.d.ts +14 -0
- package/dist/shared/datarecords/external/google/sheets/client.d.ts.map +1 -0
- package/dist/shared/datarecords/external/google/sheets/client.js +3 -0
- package/dist/shared/datarecords/external/google/sheets/handler.d.ts +27 -5
- package/dist/shared/datarecords/external/google/sheets/handler.d.ts.map +1 -1
- package/dist/shared/datarecords/external/google/sheets/handler.js +7 -0
- package/dist/shared/datarecords/external/google/sheets/{options.d.ts → types.d.ts} +1 -1
- package/dist/shared/datarecords/external/google/sheets/types.d.ts.map +1 -0
- package/dist/shared/datarecords/external/google/sheets/types.js +3 -0
- package/dist/shared/datarecords/external/notion/handler.d.ts +31 -0
- package/dist/shared/datarecords/external/notion/handler.d.ts.map +1 -0
- package/dist/shared/datarecords/external/notion/handler.js +3 -0
- package/dist/shared/datarecords/external/notion/oauth/config.js +3 -0
- package/dist/shared/datarecords/external/notion/{options.d.ts → types.d.ts} +11 -1
- package/dist/shared/datarecords/external/notion/types.d.ts.map +1 -0
- package/dist/shared/datarecords/external/notion/types.js +3 -0
- package/dist/shared/datarecords/types.d.ts +17 -18
- package/dist/shared/datarecords/types.d.ts.map +1 -1
- package/dist/shared/datarecords/types.js +1 -1
- package/dist/shared/datarecords.d.ts +2 -2
- package/dist/shared/datarecords.d.ts.map +1 -1
- package/dist/shared/datarecords.js +1 -1
- package/dist/shared/datasources/external/facebook/posts/fetcher.js +3 -0
- package/dist/shared/datasources/external/facebook/posts/schema.js +3 -0
- package/dist/shared/datasources/external/http-json/fetcher.js +3 -0
- package/dist/shared/datasources/external/http-json/options.js +3 -0
- package/dist/shared/datasources/external/http-json/schema.js +3 -0
- package/dist/shared/datasources/external/instagram/feed/fetcher.js +3 -0
- package/dist/shared/datasources/external/instagram/feed/schema.js +3 -0
- package/dist/shared/datasources/external/mastodon/account/fetcher.js +3 -0
- package/dist/shared/datasources/external/mastodon/account/schema.js +3 -0
- package/dist/shared/datasources/external/mastodon/options.js +3 -0
- package/dist/shared/datasources/external/mastodon/status/fetcher.js +3 -0
- package/dist/shared/datasources/external/mastodon/status/sample.array.js +3 -0
- package/dist/shared/datasources/external/mastodon/status/sample.single.js +3 -0
- package/dist/shared/datasources/external/mastodon/status/schema.d.ts.map +1 -1
- package/dist/shared/datasources/external/mastodon/status/schema.js +3 -0
- package/dist/shared/datasources/external/meta/options.js +3 -0
- package/dist/shared/datasources/external/rss/fetcher.js +3 -0
- package/dist/shared/datasources/external/rss/options.js +3 -0
- package/dist/shared/datasources/external/rss/schema.js +3 -0
- package/dist/shared/datasources/external/threads/media/fetcher.js +3 -0
- package/dist/shared/datasources/external/threads/media/schema.js +3 -0
- package/dist/shared/datasources/external/tiktok/video/fetcher.js +3 -0
- package/dist/shared/datasources/external/tiktok/video/options.js +3 -0
- package/dist/shared/datasources/external/tiktok/video/schema.js +3 -0
- package/dist/shared/datasources/external/youtube/list/fetcher.js +3 -0
- package/dist/shared/datasources/external/youtube/list/options.js +3 -0
- package/dist/shared/datasources/external/youtube/list/schema.js +3 -0
- package/dist/shared/datasources/fetcher.js +2 -0
- package/dist/shared/datasources/internal/blog/schema.js +3 -0
- package/dist/shared/datasources/internal/changelog/schema.js +3 -0
- package/dist/shared/datasources/internal/contact-info/schema.js +3 -0
- package/dist/shared/datasources/internal/cv/schema.js +3 -0
- package/dist/shared/datasources/internal/faq/schema.js +3 -0
- package/dist/shared/datasources/internal/job-board/schema.js +3 -0
- package/dist/shared/datasources/internal/links/schema.js +3 -0
- package/dist/shared/datasources/internal/recipes/schema.js +3 -0
- package/dist/shared/datasources/internal/restaurant/schema.js +3 -0
- package/dist/shared/datasources/samples.js +3 -0
- package/dist/shared/datasources/schemas.d.ts +0 -49
- package/dist/shared/datasources/schemas.d.ts.map +1 -1
- package/dist/shared/datasources/schemas.js +1 -1
- package/dist/shared/datasources/types.d.ts +53 -130
- package/dist/shared/datasources/types.d.ts.map +1 -1
- package/dist/shared/datasources/types.js +1 -1
- package/dist/shared/datasources/utils.js +3 -0
- package/dist/shared/datasources.d.ts +7 -4
- package/dist/shared/datasources.d.ts.map +1 -1
- package/dist/shared/datasources.js +1 -1
- package/dist/shared/errors.js +1 -1
- package/dist/shared/images.d.ts +1 -12
- package/dist/shared/images.d.ts.map +1 -1
- package/dist/shared/images.js +1 -1
- package/dist/shared/index.js +3 -0
- package/dist/shared/manifest.js +3 -0
- package/dist/shared/page.d.ts +155 -50
- package/dist/shared/page.d.ts.map +1 -1
- package/dist/shared/page.js +1 -1
- package/dist/shared/site.d.ts +322 -113
- package/dist/shared/site.d.ts.map +1 -1
- package/dist/shared/site.js +1 -1
- package/dist/shared/sitemap.d.ts +313 -13
- package/dist/shared/sitemap.d.ts.map +1 -1
- package/dist/shared/sitemap.js +1 -1
- package/dist/shared/social-icons.js +3 -0
- package/dist/shared/theme.d.ts +41 -4
- package/dist/shared/theme.d.ts.map +1 -1
- package/dist/shared/theme.js +1 -1
- package/dist/shared/utils/invariant.js +1 -1
- package/dist/shared/utils/llm.d.ts +19 -0
- package/dist/shared/utils/llm.d.ts.map +1 -0
- package/dist/shared/utils/llm.js +3 -0
- package/dist/shared/utils/schema.d.ts +6 -1
- package/dist/shared/utils/schema.d.ts.map +1 -1
- package/dist/shared/utils/schema.js +1 -1
- package/dist/shared/utils/tests/schema.test.d.ts +2 -0
- package/dist/shared/utils/tests/schema.test.d.ts.map +1 -0
- package/dist/shared/utils/typed-ref.d.ts +1 -6
- package/dist/shared/utils/typed-ref.d.ts.map +1 -1
- package/dist/shared/utils/typed-ref.js +1 -1
- package/package.json +19 -19
- package/src/shared/ai/schemas.ts +33 -0
- package/src/shared/ai/types.ts +151 -0
- package/src/shared/ajv.ts +123 -0
- package/src/shared/analytics/init.ts +14 -0
- package/src/shared/analytics/track.ts +21 -0
- package/src/shared/analytics/types.ts +13 -0
- package/src/shared/attributes.ts +396 -0
- package/src/shared/brick-manifest.ts +119 -0
- package/src/shared/bricks/manifests/accordion.manifest.ts +482 -0
- package/src/shared/bricks/manifests/all-manifests.ts +121 -0
- package/src/shared/bricks/manifests/box.manifest.ts +551 -0
- package/src/shared/bricks/manifests/button.manifest.ts +208 -0
- package/src/shared/bricks/manifests/card.manifest.ts +320 -0
- package/src/shared/bricks/manifests/carousel.manifest.ts +708 -0
- package/src/shared/bricks/manifests/footer.manifest.ts +509 -0
- package/src/shared/bricks/manifests/form.manifest.ts +226 -0
- package/src/shared/bricks/manifests/hero.manifest.ts +365 -0
- package/src/shared/bricks/manifests/html.manifest.ts +127 -0
- package/src/shared/bricks/manifests/icon.manifest.ts +164 -0
- package/src/shared/bricks/manifests/image.manifest.ts +378 -0
- package/src/shared/bricks/manifests/images-gallery.manifest.ts +822 -0
- package/src/shared/bricks/manifests/map.manifest.ts +215 -0
- package/src/shared/bricks/manifests/navbar.manifest.ts +361 -0
- package/src/shared/bricks/manifests/sidebar.manifest.ts +88 -0
- package/src/shared/bricks/manifests/social-links.manifest.ts +497 -0
- package/src/shared/bricks/manifests/spacer.manifest.ts +54 -0
- package/src/shared/bricks/manifests/testimonials.manifest.ts +480 -0
- package/src/shared/bricks/manifests/tests/header.manifest.test.ts +10 -0
- package/src/shared/bricks/manifests/text.manifest.ts +245 -0
- package/src/shared/bricks/manifests/video.manifest.ts +115 -0
- package/src/shared/bricks/props/align.ts +63 -0
- package/src/shared/bricks/props/background.ts +79 -0
- package/src/shared/bricks/props/boolean.ts +7 -0
- package/src/shared/bricks/props/border.ts +86 -0
- package/src/shared/bricks/props/color-preset.ts +390 -0
- package/src/shared/bricks/props/color.ts +40 -0
- package/src/shared/bricks/props/common.ts +64 -0
- package/src/shared/bricks/props/css-length.ts +32 -0
- package/src/shared/bricks/props/datarecord.ts +11 -0
- package/src/shared/bricks/props/datasource.ts +82 -0
- package/src/shared/bricks/props/date.ts +21 -0
- package/src/shared/bricks/props/direction.ts +21 -0
- package/src/shared/bricks/props/dynamic.ts +112 -0
- package/src/shared/bricks/props/effects.ts +71 -0
- package/src/shared/bricks/props/enum.ts +38 -0
- package/src/shared/bricks/props/file.ts +10 -0
- package/src/shared/bricks/props/geolocation.ts +36 -0
- package/src/shared/bricks/props/helpers.ts +73 -0
- package/src/shared/bricks/props/image.ts +96 -0
- package/src/shared/bricks/props/number.ts +8 -0
- package/src/shared/bricks/props/position.ts +11 -0
- package/src/shared/bricks/props/string.ts +72 -0
- package/src/shared/bricks/props/tags.ts +26 -0
- package/src/shared/bricks/props/tests/background.test.ts +90 -0
- package/src/shared/bricks/props/tests/border.test.ts +12 -0
- package/src/shared/bricks/props/tests/effects.test.ts +37 -0
- package/src/shared/bricks/props/tests/helpers.test.ts +98 -0
- package/src/shared/bricks/props/tests/image.test.ts +71 -0
- package/src/shared/bricks/props/tests/string.test.ts +80 -0
- package/src/shared/bricks/props/text.ts +107 -0
- package/src/shared/bricks/props/types.ts +72 -0
- package/src/shared/bricks.ts +1237 -0
- package/src/shared/context.ts +32 -0
- package/src/shared/datarecords/external/airtable/handler.ts +501 -0
- package/src/shared/datarecords/external/airtable/oauth/config.ts +11 -0
- package/src/shared/datarecords/external/airtable/types.ts +63 -0
- package/src/shared/datarecords/external/generic-webhook/handler.ts +10 -0
- package/src/shared/datarecords/external/generic-webhook/options.ts +13 -0
- package/src/shared/datarecords/external/google/oauth/config.ts +30 -0
- package/src/shared/datarecords/external/google/sheets/client.ts +112 -0
- package/src/shared/datarecords/external/google/sheets/handler.ts +253 -0
- package/src/shared/datarecords/external/google/sheets/types.ts +10 -0
- package/src/shared/datarecords/external/notion/handler.ts +469 -0
- package/src/shared/datarecords/external/notion/oauth/config.ts +7 -0
- package/src/shared/datarecords/external/notion/types.ts +28 -0
- package/src/shared/datarecords/types.ts +165 -0
- package/src/shared/datarecords.ts +5 -0
- package/src/shared/datasources/README.md +3 -0
- package/src/shared/datasources/external/facebook/posts/fetcher.ts +52 -0
- package/src/shared/datasources/external/facebook/posts/sample.ts +35 -0
- package/src/shared/datasources/external/facebook/posts/schema.ts +33 -0
- package/src/shared/datasources/external/facebook/posts/tests/fetcher.test.ts +73 -0
- package/src/shared/datasources/external/http-json/fetcher.ts +31 -0
- package/src/shared/datasources/external/http-json/options.ts +8 -0
- package/src/shared/datasources/external/http-json/schema.ts +6 -0
- package/src/shared/datasources/external/http-json/tests/fetcher.test.ts +70 -0
- package/src/shared/datasources/external/instagram/feed/fetcher.ts +33 -0
- package/src/shared/datasources/external/instagram/feed/sample.ts +22 -0
- package/src/shared/datasources/external/instagram/feed/schema.ts +23 -0
- package/src/shared/datasources/external/instagram/feed/tests/fetcher.test.ts +64 -0
- package/src/shared/datasources/external/mastodon/account/fetcher.ts +24 -0
- package/src/shared/datasources/external/mastodon/account/sample.ts +33 -0
- package/src/shared/datasources/external/mastodon/account/schema.ts +45 -0
- package/src/shared/datasources/external/mastodon/account/tests/fetcher.test.ts +47 -0
- package/src/shared/datasources/external/mastodon/options.ts +6 -0
- package/src/shared/datasources/external/mastodon/status/fetcher.ts +35 -0
- package/src/shared/datasources/external/mastodon/status/sample.array.ts +59 -0
- package/src/shared/datasources/external/mastodon/status/sample.single.ts +55 -0
- package/src/shared/datasources/external/mastodon/status/schema.ts +125 -0
- package/src/shared/datasources/external/mastodon/status/tests/fetcher.test.ts +74 -0
- package/src/shared/datasources/external/meta/oauth/config.ts +16 -0
- package/src/shared/datasources/external/meta/options.ts +7 -0
- package/src/shared/datasources/external/rss/fetcher.ts +31 -0
- package/src/shared/datasources/external/rss/options.ts +7 -0
- package/src/shared/datasources/external/rss/sample.ts +22 -0
- package/src/shared/datasources/external/rss/schema.ts +42 -0
- package/src/shared/datasources/external/threads/media/fetcher.ts +53 -0
- package/src/shared/datasources/external/threads/media/sample.ts +44 -0
- package/src/shared/datasources/external/threads/media/schema.ts +37 -0
- package/src/shared/datasources/external/tiktok/oauth/config.ts +17 -0
- package/src/shared/datasources/external/tiktok/video/fetcher.ts +39 -0
- package/src/shared/datasources/external/tiktok/video/options.ts +8 -0
- package/src/shared/datasources/external/tiktok/video/sample.ts +26 -0
- package/src/shared/datasources/external/tiktok/video/schema.ts +27 -0
- package/src/shared/datasources/external/youtube/list/fetcher.ts +37 -0
- package/src/shared/datasources/external/youtube/list/options.ts +11 -0
- package/src/shared/datasources/external/youtube/list/sample.ts +33 -0
- package/src/shared/datasources/external/youtube/list/schema.ts +38 -0
- package/src/shared/datasources/external/youtube/oauth/config.ts +15 -0
- package/src/shared/datasources/fetcher.ts +16 -0
- package/src/shared/datasources/internal/blog/schema.ts +69 -0
- package/src/shared/datasources/internal/changelog/schema.ts +48 -0
- package/src/shared/datasources/internal/contact-info/schema.ts +20 -0
- package/src/shared/datasources/internal/cv/schema.ts +217 -0
- package/src/shared/datasources/internal/faq/schema.ts +27 -0
- package/src/shared/datasources/internal/job-board/schema.ts +228 -0
- package/src/shared/datasources/internal/links/schema.ts +15 -0
- package/src/shared/datasources/internal/recipes/schema.ts +42 -0
- package/src/shared/datasources/internal/restaurant/schema.ts +225 -0
- package/src/shared/datasources/samples.ts +26 -0
- package/src/shared/datasources/schemas.ts +48 -0
- package/src/shared/datasources/types.ts +490 -0
- package/src/shared/datasources/utils.ts +17 -0
- package/src/shared/datasources.ts +57 -0
- package/src/shared/env.ts +23 -0
- package/src/shared/errors.ts +1 -0
- package/src/shared/images.ts +44 -0
- package/src/shared/index.ts +3 -0
- package/src/shared/layout-constants.ts +19 -0
- package/src/shared/manifest.ts +50 -0
- package/src/shared/oauth.ts +16 -0
- package/src/shared/page.ts +36 -0
- package/src/shared/prompt.ts +9 -0
- package/src/shared/responsive.ts +5 -0
- package/src/shared/site.ts +59 -0
- package/src/shared/sitemap.ts +98 -0
- package/src/shared/social-icons.ts +307 -0
- package/src/shared/tests/attributes.test.ts +31 -0
- package/src/shared/theme.ts +244 -0
- package/src/shared/themes/README.md +34 -0
- package/src/shared/themes/color-system.ts +146 -0
- package/src/shared/themes/tests/color-system.test.ts +170 -0
- package/src/shared/utils/canvas-data-uri.ts +2 -0
- package/src/shared/utils/invariant.ts +25 -0
- package/src/shared/utils/json-date.ts +8 -0
- package/src/shared/utils/llm.ts +282 -0
- package/src/shared/utils/merge.ts +12 -0
- package/src/shared/utils/object-hash.ts +7 -0
- package/src/shared/utils/schema.ts +359 -0
- package/src/shared/utils/string-enum.ts +12 -0
- package/src/shared/utils/tests/schema.test.ts +724 -0
- package/src/shared/utils/try-catch.ts +12 -0
- package/src/shared/utils/typed-ref.ts +53 -0
- package/dist/shared/bricks/props/container.d.ts +0 -11
- package/dist/shared/bricks/props/container.d.ts.map +0 -1
- package/dist/shared/bricks/props/container.js +0 -3
- package/dist/shared/bricks/props/gap.d.ts +0 -9
- package/dist/shared/bricks/props/gap.d.ts.map +0 -1
- package/dist/shared/bricks/props/gap.js +0 -3
- package/dist/shared/bricks/props/padding.d.ts +0 -5
- package/dist/shared/bricks/props/padding.d.ts.map +0 -1
- package/dist/shared/bricks/props/padding.js +0 -3
- package/dist/shared/bricks/props/tests/padding.d.ts +0 -2
- package/dist/shared/bricks/props/tests/padding.d.ts.map +0 -1
- package/dist/shared/chunk-2IYSJYNE.js +0 -3
- package/dist/shared/chunk-3EM3B4DX.js +0 -3
- package/dist/shared/chunk-4TH3C76A.js +0 -3
- package/dist/shared/chunk-5N6MBJJ4.js +0 -3
- package/dist/shared/chunk-6FITVVZX.js +0 -3
- package/dist/shared/chunk-6K3KZDFC.js +0 -3
- package/dist/shared/chunk-6WCGUAQN.js +0 -3
- package/dist/shared/chunk-7DMUDZ4H.js +0 -3
- package/dist/shared/chunk-ACVLF55Q.js +0 -3
- package/dist/shared/chunk-AQPN5SE2.js +0 -3
- package/dist/shared/chunk-BZGNY7LB.js +0 -3
- package/dist/shared/chunk-C2S243PB.js +0 -8
- package/dist/shared/chunk-C3VGP4CA.js +0 -3
- package/dist/shared/chunk-CT3EI7YN.js +0 -3
- package/dist/shared/chunk-DQXDGV67.js +0 -3
- package/dist/shared/chunk-E22E4XWE.js +0 -3
- package/dist/shared/chunk-ETYYRWLK.js +0 -3
- package/dist/shared/chunk-EYPREFMH.js +0 -3
- package/dist/shared/chunk-FKNNTHWX.js +0 -5
- package/dist/shared/chunk-HHO3ONTQ.js +0 -3
- package/dist/shared/chunk-I46VBMLF.js +0 -3
- package/dist/shared/chunk-IIFTGWFZ.js +0 -3
- package/dist/shared/chunk-JS4K5JRM.js +0 -5
- package/dist/shared/chunk-KHFNN4P3.js +0 -3
- package/dist/shared/chunk-LFQZRGHS.js +0 -3
- package/dist/shared/chunk-LGP6GWIY.js +0 -3
- package/dist/shared/chunk-NLEWXPVM.js +0 -3
- package/dist/shared/chunk-NNI225RG.js +0 -3
- package/dist/shared/chunk-QISTDGPP.js +0 -3
- package/dist/shared/chunk-QSZWDE3D.js +0 -3
- package/dist/shared/chunk-RGLVKILY.js +0 -3
- package/dist/shared/chunk-SLRU4CT6.js +0 -4
- package/dist/shared/chunk-T3LIA4YB.js +0 -3
- package/dist/shared/chunk-T4LMBG2G.js +0 -3
- package/dist/shared/chunk-TATG6SFZ.js +0 -3
- package/dist/shared/chunk-TF3JVVRU.js +0 -3
- package/dist/shared/chunk-TTTXV7TJ.js +0 -6
- package/dist/shared/chunk-TWBY2GOR.js +0 -3
- package/dist/shared/chunk-UHF6IEKV.js +0 -3
- package/dist/shared/chunk-UMHXXXVP.js +0 -3
- package/dist/shared/chunk-VGRYSAXA.js +0 -3
- package/dist/shared/chunk-VPFCY4DH.js +0 -3
- package/dist/shared/chunk-VTBI7WX3.js +0 -3
- package/dist/shared/chunk-VZPXXFVX.js +0 -3
- package/dist/shared/chunk-WU6Q4WYD.js +0 -3
- package/dist/shared/chunk-X43MB5WD.js +0 -3
- package/dist/shared/chunk-YBGPPF7T.js +0 -3
- package/dist/shared/chunk-ZQGNYK5I.js +0 -8
- package/dist/shared/chunk-ZTDUXSWH.js +0 -3
- package/dist/shared/datarecords/external/airtable/elements.d.ts +0 -21
- package/dist/shared/datarecords/external/airtable/elements.d.ts.map +0 -1
- package/dist/shared/datarecords/external/airtable/options.d.ts +0 -10
- package/dist/shared/datarecords/external/airtable/options.d.ts.map +0 -1
- package/dist/shared/datarecords/external/google/sheets/options.d.ts.map +0 -1
- package/dist/shared/datarecords/external/notion/options.d.ts.map +0 -1
- package/dist/shared/utils/schema-resolver.d.ts +0 -3
- package/dist/shared/utils/schema-resolver.d.ts.map +0 -1
- package/dist/shared/utils/schema-resolver.js +0 -3
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
import { Type } from "@sinclair/typebox";
|
|
2
|
+
import { RxButton } from "react-icons/rx";
|
|
3
|
+
import { defineBrickManifest } from "~/shared/brick-manifest";
|
|
4
|
+
import { defineProps } from "../props/helpers";
|
|
5
|
+
import { string, urlOrPageIdRef } from "../props/string";
|
|
6
|
+
import type { BrickProps } from "../props/types";
|
|
7
|
+
import { borderRef, roundingRef } from "../props/border";
|
|
8
|
+
import { fontSizeRef } from "../props/text";
|
|
9
|
+
import { colorPresetRef } from "../props/color-preset";
|
|
10
|
+
|
|
11
|
+
export const manifest = defineBrickManifest({
|
|
12
|
+
type: "button",
|
|
13
|
+
name: "Button",
|
|
14
|
+
category: "basic",
|
|
15
|
+
description: "A button",
|
|
16
|
+
aiInstructions:
|
|
17
|
+
"A clickable button that can link to a URL or a page within the site. It can be styled with different colors, font sizes, and border radii. Don't use it in forms since forms have their own submit button.",
|
|
18
|
+
resizable: "horizontal",
|
|
19
|
+
icon: RxButton,
|
|
20
|
+
minWidth: {
|
|
21
|
+
desktop: 120,
|
|
22
|
+
mobile: 120,
|
|
23
|
+
},
|
|
24
|
+
defaultWidth: {
|
|
25
|
+
mobile: "100%",
|
|
26
|
+
},
|
|
27
|
+
props: defineProps(
|
|
28
|
+
{
|
|
29
|
+
colorPreset: Type.Optional(
|
|
30
|
+
colorPresetRef({
|
|
31
|
+
default: { color: "primary-500" },
|
|
32
|
+
title: "Color",
|
|
33
|
+
"ui:default-gradient-direction": "bg-gradient-to-b",
|
|
34
|
+
}),
|
|
35
|
+
),
|
|
36
|
+
label: string("Label", { default: "My button", metadata: { category: "content" } }),
|
|
37
|
+
fontSize: Type.Optional(
|
|
38
|
+
fontSizeRef({
|
|
39
|
+
title: "Font size",
|
|
40
|
+
description: "The font size of the button text.",
|
|
41
|
+
default: "text-base",
|
|
42
|
+
"ui:responsive": "desktop",
|
|
43
|
+
"ui:no-extra-large-sizes": true,
|
|
44
|
+
}),
|
|
45
|
+
),
|
|
46
|
+
rounding: Type.Optional(
|
|
47
|
+
roundingRef({
|
|
48
|
+
default: "rounded-md",
|
|
49
|
+
}),
|
|
50
|
+
),
|
|
51
|
+
border: Type.Optional(borderRef({ default: { width: "border-0" }, "ui:responsive": "desktop" })),
|
|
52
|
+
link: urlOrPageIdRef({
|
|
53
|
+
title: "Link",
|
|
54
|
+
"ui:placeholder": "https://example.com",
|
|
55
|
+
metadata: { category: "content" },
|
|
56
|
+
}),
|
|
57
|
+
},
|
|
58
|
+
{ noGrow: true },
|
|
59
|
+
),
|
|
60
|
+
});
|
|
61
|
+
|
|
62
|
+
export type Manifest = typeof manifest;
|
|
63
|
+
|
|
64
|
+
export const examples: {
|
|
65
|
+
description: string;
|
|
66
|
+
type: string;
|
|
67
|
+
props: BrickProps<Manifest>["brick"]["props"];
|
|
68
|
+
}[] = [
|
|
69
|
+
{
|
|
70
|
+
description: "Primary button, full width, linking to an external URL",
|
|
71
|
+
type: "button",
|
|
72
|
+
props: {
|
|
73
|
+
label: "Click me",
|
|
74
|
+
link: "https://example.com",
|
|
75
|
+
colorPreset: { color: "primary-500" },
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
description: "Secondary button, block width, linking to a page id",
|
|
80
|
+
type: "button",
|
|
81
|
+
props: {
|
|
82
|
+
label: "Go to page",
|
|
83
|
+
link: "page-id-123",
|
|
84
|
+
colorPreset: { color: "secondary-500" },
|
|
85
|
+
},
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
description: "Neutral colored button with large text and rounded corners and external link",
|
|
89
|
+
type: "button",
|
|
90
|
+
props: {
|
|
91
|
+
label: "Submit",
|
|
92
|
+
fontSize: "text-lg",
|
|
93
|
+
rounding: "rounded-full",
|
|
94
|
+
link: "https://example.com",
|
|
95
|
+
colorPreset: { color: "neutral-500" },
|
|
96
|
+
},
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
description: "Dynamic label from a page query alias named 'employee'",
|
|
100
|
+
type: "button",
|
|
101
|
+
props: {
|
|
102
|
+
label: "Go to profile of {{employee.name}}",
|
|
103
|
+
link: "/employees/{{employee.$slug}}",
|
|
104
|
+
fontSize: "text-lg",
|
|
105
|
+
rounding: "rounded-full",
|
|
106
|
+
colorPreset: { color: "neutral-500" },
|
|
107
|
+
},
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
description: "Accent colored call-to-action button with medium text and subtle border",
|
|
111
|
+
type: "button",
|
|
112
|
+
props: {
|
|
113
|
+
label: "Get Started",
|
|
114
|
+
link: "/signup",
|
|
115
|
+
fontSize: "text-base",
|
|
116
|
+
rounding: "rounded-lg",
|
|
117
|
+
colorPreset: { color: "accent-600" },
|
|
118
|
+
border: { width: "border", color: "border-accent-700" },
|
|
119
|
+
},
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
description: "Small text button with sharp corners for minimal design",
|
|
123
|
+
type: "button",
|
|
124
|
+
props: {
|
|
125
|
+
label: "Learn More",
|
|
126
|
+
link: "/about",
|
|
127
|
+
fontSize: "text-sm",
|
|
128
|
+
rounding: "rounded-none",
|
|
129
|
+
colorPreset: { color: "primary-400" },
|
|
130
|
+
},
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
description: "Large download button with thick border and rounded corners",
|
|
134
|
+
type: "button",
|
|
135
|
+
props: {
|
|
136
|
+
label: "Download Now",
|
|
137
|
+
link: "https://download.example.com/file.zip",
|
|
138
|
+
fontSize: "text-xl",
|
|
139
|
+
rounding: "rounded-xl",
|
|
140
|
+
colorPreset: { color: "secondary-600" },
|
|
141
|
+
border: { width: "border-2", color: "border-secondary-800" },
|
|
142
|
+
},
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
description: "Contact button with neutral colors and medium border radius",
|
|
146
|
+
type: "button",
|
|
147
|
+
props: {
|
|
148
|
+
label: "Contact Us",
|
|
149
|
+
link: "/contact",
|
|
150
|
+
fontSize: "text-base",
|
|
151
|
+
rounding: "rounded-md",
|
|
152
|
+
colorPreset: { color: "neutral-600" },
|
|
153
|
+
border: { width: "border", color: "border-neutral-400" },
|
|
154
|
+
},
|
|
155
|
+
},
|
|
156
|
+
{
|
|
157
|
+
description: "Newsletter signup button with gradient background and full rounding",
|
|
158
|
+
type: "button",
|
|
159
|
+
props: {
|
|
160
|
+
label: "Subscribe to Newsletter",
|
|
161
|
+
link: "/newsletter",
|
|
162
|
+
fontSize: "text-lg",
|
|
163
|
+
rounding: "rounded-full",
|
|
164
|
+
colorPreset: {
|
|
165
|
+
color: "primary-500",
|
|
166
|
+
gradientDirection: "bg-gradient-to-r",
|
|
167
|
+
},
|
|
168
|
+
},
|
|
169
|
+
},
|
|
170
|
+
{
|
|
171
|
+
description: "Shop now button with accent colors and extra large text",
|
|
172
|
+
type: "button",
|
|
173
|
+
props: {
|
|
174
|
+
label: "Shop Now",
|
|
175
|
+
link: "/shop",
|
|
176
|
+
fontSize: "text-xl",
|
|
177
|
+
rounding: "rounded-lg",
|
|
178
|
+
colorPreset: { color: "accent-500" },
|
|
179
|
+
},
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
description: "Dynamic product button using product query data",
|
|
183
|
+
type: "button",
|
|
184
|
+
props: {
|
|
185
|
+
label: "Buy {{product.name}} - ${{product.price}}",
|
|
186
|
+
link: "/products/{{product.id}}/purchase",
|
|
187
|
+
fontSize: "text-base",
|
|
188
|
+
rounding: "rounded-md",
|
|
189
|
+
colorPreset: { color: "primary-600" },
|
|
190
|
+
border: { width: "border", color: "border-primary-800" },
|
|
191
|
+
},
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
description: "Event registration button with secondary gradient and medium text",
|
|
195
|
+
type: "button",
|
|
196
|
+
props: {
|
|
197
|
+
label: "Register for Event",
|
|
198
|
+
link: "/events/register",
|
|
199
|
+
fontSize: "text-base",
|
|
200
|
+
rounding: "rounded-lg",
|
|
201
|
+
colorPreset: {
|
|
202
|
+
color: "secondary-500",
|
|
203
|
+
gradientDirection: "bg-gradient-to-br",
|
|
204
|
+
},
|
|
205
|
+
border: { width: "border", color: "border-secondary-300" },
|
|
206
|
+
},
|
|
207
|
+
},
|
|
208
|
+
];
|
|
@@ -0,0 +1,320 @@
|
|
|
1
|
+
import { defineBrickManifest } from "~/shared/brick-manifest";
|
|
2
|
+
import { defineProps } from "../props/helpers";
|
|
3
|
+
import { textContentRef } from "../props/text";
|
|
4
|
+
import { BsCardText } from "react-icons/bs";
|
|
5
|
+
import { imageRef } from "../props/image";
|
|
6
|
+
import { type Static, Type } from "@sinclair/typebox";
|
|
7
|
+
import type { BrickProps } from "../props/types";
|
|
8
|
+
import { shadowRef } from "../props/effects";
|
|
9
|
+
import { borderRef, roundingRef } from "../props/border";
|
|
10
|
+
import { colorPresetRef } from "../props/color-preset";
|
|
11
|
+
import { loopRef } from "../props/dynamic";
|
|
12
|
+
import { StringEnum } from "~/shared/utils/string-enum";
|
|
13
|
+
|
|
14
|
+
export const manifest = defineBrickManifest({
|
|
15
|
+
type: "card",
|
|
16
|
+
name: "Card",
|
|
17
|
+
description: "A card that can have a title, image, and content.",
|
|
18
|
+
aiInstructions:
|
|
19
|
+
"Use this brick to create cards that contain an image, title, and text content. Cards are useful for displaying information in a concise and visually appealing way.",
|
|
20
|
+
icon: BsCardText,
|
|
21
|
+
defaultWidth: { desktop: "400px", mobile: "100%" },
|
|
22
|
+
minWidth: { desktop: 300 },
|
|
23
|
+
minHeight: { mobile: 200, desktop: 200 },
|
|
24
|
+
maxWidth: { desktop: 650 },
|
|
25
|
+
props: defineProps({
|
|
26
|
+
colorPreset: Type.Optional(
|
|
27
|
+
colorPresetRef({
|
|
28
|
+
title: "Color preset",
|
|
29
|
+
default: { color: "base-100" },
|
|
30
|
+
}),
|
|
31
|
+
),
|
|
32
|
+
|
|
33
|
+
cardImage: Type.Optional(
|
|
34
|
+
imageRef({
|
|
35
|
+
"ui:responsive": "desktop",
|
|
36
|
+
metadata: {
|
|
37
|
+
category: "content",
|
|
38
|
+
},
|
|
39
|
+
}),
|
|
40
|
+
),
|
|
41
|
+
imagePosition: Type.Optional(
|
|
42
|
+
StringEnum(["top", "middle", "bottom", "left", "right"], {
|
|
43
|
+
enumNames: ["Top", "Middle", "Bottom", "Left", "Right"],
|
|
44
|
+
title: "Image Position",
|
|
45
|
+
description: "Where the image should be placed in the card",
|
|
46
|
+
default: "top",
|
|
47
|
+
"ui:responsive": "desktop",
|
|
48
|
+
metadata: {
|
|
49
|
+
category: "content",
|
|
50
|
+
filter: (manifestProps: Manifest["props"], formData: Static<Manifest["props"]>) => {
|
|
51
|
+
return !!formData.cardImage?.src;
|
|
52
|
+
},
|
|
53
|
+
},
|
|
54
|
+
}),
|
|
55
|
+
),
|
|
56
|
+
noTitle: Type.Optional(
|
|
57
|
+
Type.Boolean({
|
|
58
|
+
title: "No Title",
|
|
59
|
+
description: "Whether to hide the card title",
|
|
60
|
+
default: false,
|
|
61
|
+
"ui:responsive": "desktop",
|
|
62
|
+
}),
|
|
63
|
+
),
|
|
64
|
+
title: Type.Optional(textContentRef({ title: "Title" })),
|
|
65
|
+
text: Type.Optional(textContentRef({ title: "Text" })),
|
|
66
|
+
rounding: Type.Optional(
|
|
67
|
+
roundingRef({
|
|
68
|
+
default: "rounded-md",
|
|
69
|
+
}),
|
|
70
|
+
),
|
|
71
|
+
border: Type.Optional(
|
|
72
|
+
borderRef({
|
|
73
|
+
// default: { width: "border", color: "border-base-300" },
|
|
74
|
+
}),
|
|
75
|
+
),
|
|
76
|
+
shadow: Type.Optional(
|
|
77
|
+
shadowRef({
|
|
78
|
+
default: "shadow-sm",
|
|
79
|
+
}),
|
|
80
|
+
),
|
|
81
|
+
loop: Type.Optional(loopRef()),
|
|
82
|
+
}),
|
|
83
|
+
});
|
|
84
|
+
|
|
85
|
+
export type Manifest = typeof manifest;
|
|
86
|
+
|
|
87
|
+
export const examples: {
|
|
88
|
+
description: string;
|
|
89
|
+
type: string;
|
|
90
|
+
props: BrickProps<Manifest>["brick"]["props"];
|
|
91
|
+
}[] = [
|
|
92
|
+
{
|
|
93
|
+
description: "A simple card with a title and content",
|
|
94
|
+
type: "card",
|
|
95
|
+
props: {
|
|
96
|
+
title: "Card Title",
|
|
97
|
+
text: "This is the body of the card.",
|
|
98
|
+
},
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
description: "Product card with image on the left",
|
|
102
|
+
type: "card",
|
|
103
|
+
props: {
|
|
104
|
+
cardImage: {
|
|
105
|
+
src: "https://via.placeholder.com/200x200",
|
|
106
|
+
alt: "Product image",
|
|
107
|
+
},
|
|
108
|
+
title: "Premium Headphones",
|
|
109
|
+
text: "High-quality wireless headphones with noise cancellation and 30-hour battery life.",
|
|
110
|
+
},
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
description: "Feature card with large padding and background",
|
|
114
|
+
type: "card",
|
|
115
|
+
props: {
|
|
116
|
+
title: "Key Feature",
|
|
117
|
+
text: "This feature provides exceptional value and enhances user experience significantly.",
|
|
118
|
+
},
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
description: "Blog post card with image at the bottom",
|
|
122
|
+
type: "card",
|
|
123
|
+
props: {
|
|
124
|
+
title: "The Future of Technology",
|
|
125
|
+
text: "Exploring emerging trends and innovations that will shape our digital landscape in the coming decade.",
|
|
126
|
+
cardImage: {
|
|
127
|
+
src: "https://via.placeholder.com/400x200",
|
|
128
|
+
alt: "Technology concept",
|
|
129
|
+
},
|
|
130
|
+
},
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
description: "Testimonial card with right-side image",
|
|
134
|
+
type: "card",
|
|
135
|
+
props: {
|
|
136
|
+
title: "Customer Review",
|
|
137
|
+
text: '"This product exceeded my expectations. The quality is outstanding and the customer service is top-notch!"',
|
|
138
|
+
cardImage: {
|
|
139
|
+
src: "https://via.placeholder.com/150x150",
|
|
140
|
+
alt: "Customer photo",
|
|
141
|
+
},
|
|
142
|
+
},
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
description: "Minimal centered card without image",
|
|
146
|
+
type: "card",
|
|
147
|
+
props: {
|
|
148
|
+
title: "Simple Announcement",
|
|
149
|
+
text: "Important updates will be posted here regularly.",
|
|
150
|
+
},
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
description: "Event card with multiple variants",
|
|
154
|
+
type: "card",
|
|
155
|
+
props: {
|
|
156
|
+
cardImage: {
|
|
157
|
+
src: "https://via.placeholder.com/400x250",
|
|
158
|
+
alt: "Event venue",
|
|
159
|
+
},
|
|
160
|
+
title: "Annual Conference 2025",
|
|
161
|
+
text: "Join us for three days of inspiring talks, networking opportunities, and hands-on workshops.",
|
|
162
|
+
},
|
|
163
|
+
},
|
|
164
|
+
{
|
|
165
|
+
description: "News article card with compact layout",
|
|
166
|
+
type: "card",
|
|
167
|
+
props: {
|
|
168
|
+
cardImage: {
|
|
169
|
+
src: "https://via.placeholder.com/120x120",
|
|
170
|
+
alt: "News thumbnail",
|
|
171
|
+
},
|
|
172
|
+
title: "Breaking News Update",
|
|
173
|
+
text: "Latest developments in the ongoing story with expert analysis and community reactions.",
|
|
174
|
+
},
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
description: "Call-to-action card with prominent styling",
|
|
178
|
+
type: "card",
|
|
179
|
+
props: {
|
|
180
|
+
title: "Get Started Today",
|
|
181
|
+
text: "Transform your workflow with our powerful tools. Sign up now and get 30 days free!",
|
|
182
|
+
},
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
description: "Dynamic product card using products query with pricing and details",
|
|
186
|
+
type: "card",
|
|
187
|
+
props: {
|
|
188
|
+
cardImage: {
|
|
189
|
+
src: "{{products.image}}",
|
|
190
|
+
alt: "{{products.name}}",
|
|
191
|
+
},
|
|
192
|
+
title: "{{products.name}}",
|
|
193
|
+
text: "{{products.description}}<br><strong>Price: ${{products.price}}</strong><br>Category: {{products.category}}",
|
|
194
|
+
colorPreset: { color: "primary-50" },
|
|
195
|
+
border: { width: "border", color: "border-primary-200" },
|
|
196
|
+
rounding: "rounded-lg",
|
|
197
|
+
shadow: "shadow-md",
|
|
198
|
+
loop: {
|
|
199
|
+
over: "products",
|
|
200
|
+
},
|
|
201
|
+
},
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
description: "Employee profile card using teamMembers query with contact information",
|
|
205
|
+
type: "card",
|
|
206
|
+
props: {
|
|
207
|
+
cardImage: {
|
|
208
|
+
src: "{{teamMembers.photo}}",
|
|
209
|
+
alt: "Photo of {{teamMembers.fullName}}",
|
|
210
|
+
},
|
|
211
|
+
imagePosition: "top",
|
|
212
|
+
title: "{{teamMembers.fullName}}",
|
|
213
|
+
text: "<strong>{{teamMembers.position}}</strong><br>{{teamMembers.department}}<br>Email: {{teamMembers.email}}<br>Phone: {{teamMembers.phone}}",
|
|
214
|
+
colorPreset: { color: "neutral-100" },
|
|
215
|
+
rounding: "rounded-xl",
|
|
216
|
+
shadow: "shadow-lg",
|
|
217
|
+
loop: {
|
|
218
|
+
over: "teamMembers",
|
|
219
|
+
},
|
|
220
|
+
},
|
|
221
|
+
},
|
|
222
|
+
{
|
|
223
|
+
description: "Blog post card using blogPosts query with author and date",
|
|
224
|
+
type: "card",
|
|
225
|
+
props: {
|
|
226
|
+
cardImage: {
|
|
227
|
+
src: "{{blogPosts.featuredImage}}",
|
|
228
|
+
alt: "{{blogPosts.title}}",
|
|
229
|
+
},
|
|
230
|
+
imagePosition: "top",
|
|
231
|
+
title: "{{blogPosts.title}}",
|
|
232
|
+
text: "{{blogPosts.excerpt}}<br><br><em>By {{blogPosts.author}} • {{blogPosts.publishDate}}</em><br>Tags: {{blogPosts.tags}}",
|
|
233
|
+
colorPreset: { color: "secondary-50" },
|
|
234
|
+
border: { width: "border", color: "border-secondary-300" },
|
|
235
|
+
rounding: "rounded-md",
|
|
236
|
+
shadow: "shadow-sm",
|
|
237
|
+
loop: {
|
|
238
|
+
over: "blogPosts",
|
|
239
|
+
},
|
|
240
|
+
},
|
|
241
|
+
},
|
|
242
|
+
{
|
|
243
|
+
description: "Event listing card using upcomingEvents query with venue details",
|
|
244
|
+
type: "card",
|
|
245
|
+
props: {
|
|
246
|
+
cardImage: {
|
|
247
|
+
src: "{{upcomingEvents.banner}}",
|
|
248
|
+
alt: "{{upcomingEvents.title}}",
|
|
249
|
+
},
|
|
250
|
+
imagePosition: "top",
|
|
251
|
+
title: "{{upcomingEvents.title}}",
|
|
252
|
+
text: "<strong>{{upcomingEvents.date}} at {{upcomingEvents.time}}</strong><br>{{upcomingEvents.venue}}, {{upcomingEvents.city}}<br><br>{{upcomingEvents.description}}<br><br>Tickets: ${{upcomingEvents.price}}",
|
|
253
|
+
colorPreset: { color: "accent-100" },
|
|
254
|
+
border: { width: "border-2", color: "border-accent-400" },
|
|
255
|
+
rounding: "rounded-lg",
|
|
256
|
+
shadow: "shadow-md",
|
|
257
|
+
loop: {
|
|
258
|
+
over: "upcomingEvents",
|
|
259
|
+
},
|
|
260
|
+
},
|
|
261
|
+
},
|
|
262
|
+
{
|
|
263
|
+
description: "Testimonial card using customerReviews query with ratings",
|
|
264
|
+
type: "card",
|
|
265
|
+
props: {
|
|
266
|
+
cardImage: {
|
|
267
|
+
src: "{{customerReviews.customerPhoto}}",
|
|
268
|
+
alt: "{{customerReviews.customerName}}",
|
|
269
|
+
},
|
|
270
|
+
imagePosition: "left",
|
|
271
|
+
title: "{{customerReviews.customerName}}",
|
|
272
|
+
text: '"{{customerReviews.review}}"<br><br><strong>Rating: {{customerReviews.rating}}/5 stars</strong><br>{{customerReviews.company}} • {{customerReviews.position}}',
|
|
273
|
+
colorPreset: { color: "neutral-50" },
|
|
274
|
+
rounding: "rounded-xl",
|
|
275
|
+
shadow: "shadow-lg",
|
|
276
|
+
loop: {
|
|
277
|
+
over: "customerReviews",
|
|
278
|
+
},
|
|
279
|
+
},
|
|
280
|
+
},
|
|
281
|
+
{
|
|
282
|
+
description: "Service offering card using companyServices query with pricing tiers",
|
|
283
|
+
type: "card",
|
|
284
|
+
props: {
|
|
285
|
+
cardImage: {
|
|
286
|
+
src: "{{companyServices.icon}}",
|
|
287
|
+
alt: "{{companyServices.serviceName}}",
|
|
288
|
+
},
|
|
289
|
+
imagePosition: "top",
|
|
290
|
+
title: "{{companyServices.serviceName}}",
|
|
291
|
+
text: "{{companyServices.description}}<br><br><strong>Starting at ${{companyServices.startingPrice}}</strong><br>Duration: {{companyServices.duration}}<br>Includes: {{companyServices.features}}",
|
|
292
|
+
colorPreset: { color: "primary-100" },
|
|
293
|
+
border: { width: "border", color: "border-primary-300" },
|
|
294
|
+
rounding: "rounded-lg",
|
|
295
|
+
shadow: "shadow-md",
|
|
296
|
+
loop: {
|
|
297
|
+
over: "companyServices",
|
|
298
|
+
},
|
|
299
|
+
},
|
|
300
|
+
},
|
|
301
|
+
{
|
|
302
|
+
description: "Portfolio project card using portfolioWork query with project details",
|
|
303
|
+
type: "card",
|
|
304
|
+
props: {
|
|
305
|
+
cardImage: {
|
|
306
|
+
src: "{{portfolioWork.thumbnail}}",
|
|
307
|
+
alt: "{{portfolioWork.projectName}}",
|
|
308
|
+
},
|
|
309
|
+
imagePosition: "top",
|
|
310
|
+
title: "{{portfolioWork.projectName}}",
|
|
311
|
+
text: "<strong>Client:</strong> {{portfolioWork.clientName}}<br><strong>Year:</strong> {{portfolioWork.year}}<br><strong>Category:</strong> {{portfolioWork.category}}<br><br>{{portfolioWork.description}}",
|
|
312
|
+
colorPreset: { color: "secondary-100" },
|
|
313
|
+
rounding: "rounded-md",
|
|
314
|
+
shadow: "shadow-sm",
|
|
315
|
+
loop: {
|
|
316
|
+
over: "portfolioWork",
|
|
317
|
+
},
|
|
318
|
+
},
|
|
319
|
+
},
|
|
320
|
+
];
|