Compare commits

...

368 Commits

Author SHA1 Message Date
pandeymangg
474ae4478f formssssS 2024-05-24 23:04:05 +05:30
pandeymangg
a01107521e fix: FormProvider 2024-05-24 15:05:48 +05:30
pandeymangg
2e17e70c00 fix: isDirty changes with react hook form 2024-05-24 13:49:00 +05:30
pandeymangg
641b597ddc isDirty 2024-05-24 12:11:30 +05:30
pandeymangg
b6986e5470 Merge branch 'main' into fix/product-settings-form 2024-05-23 11:30:45 +05:30
pandeymangg
82a5eed6e5 fix: Form element 2024-05-23 11:28:16 +05:30
pandeymangg
0f20a4460f fix: placement form 2024-05-23 10:41:33 +05:30
pandeymangg
95ae35a3b5 fix: adds form component and refactors the current approach 2024-05-23 10:19:05 +05:30
Matti Nannt
27b37a5f27 fix: convert number attributes to strings automatically (#2679) 2024-05-22 17:48:02 +02:00
Dhruwang Jariwala
c37d3ae0f9 fix: ui issues (#2665) 2024-05-22 14:03:17 +00:00
Matti Nannt
e69bb3501d docs: update advanced docker update steps (#2678) 2024-05-22 15:22:30 +02:00
pandeymangg
ddd91607b1 Merge branch 'main' into fix/product-settings-form 2024-05-22 18:46:32 +05:30
pandeymangg
325eeb10ef fix: look and feel settings react hook form 2024-05-22 18:34:44 +05:30
Matti Nannt
eda9c00548 fix: migration instructions to 2.0 (#2676) 2024-05-22 14:35:11 +02:00
Jonas Höbenreich
6a7e0d3ecb fix: set "desktop" as default device type (#2675) 2024-05-22 12:11:25 +00:00
Anshuman Pandey
48859facf4 fix: formbricks init error (#2633)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-05-22 12:07:17 +00:00
Matti Nannt
732b8b599f fix: docker file shouldn't check npm registry on runtime (#2663) 2024-05-21 13:39:51 +02:00
Johannes
00ad4c3895 fix: fix links to integrations on docs (#2664) 2024-05-21 11:57:24 +02:00
Dhruwang Jariwala
4858bdd838 fix: rating question and updated attribute labels on person page (#2657)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-05-20 15:02:28 +00:00
Shubham Palriwala
eee78a79d9 fix: navbar on mobile docs for grouped features (#2658)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-05-20 14:57:18 +00:00
Johannes
aa890affc9 fix: update links for integrations (#2659) 2024-05-20 16:45:41 +02:00
Anshuman Pandey
10aed2d9d8 fix: UI fixes (#2653)
Co-authored-by: Johannes <johannes@formbricks.com>
2024-05-20 09:11:18 +00:00
Matthias Nannt
4d78b904b8 chore: update formbricks version number 2024-05-17 15:25:00 +02:00
Matti Nannt
473cc7334b chore: upgrade npm dependencies (#2645) 2024-05-17 15:14:45 +02:00
Dhruwang Jariwala
afdcac2465 fix: Shuffled choices issue (#2639) 2024-05-17 09:18:32 +00:00
Piyush Gupta
e539ac82f3 fix: Multiple File Uploads in a row put all the files at the beginning (#2637) 2024-05-17 07:43:18 +00:00
Piyush Gupta
c2fbb20787 fix: survey overview is throwing a server-side error (#2638) 2024-05-17 07:02:40 +00:00
Dhruwang Jariwala
084307bdb2 fix: input color issue on rating questio (#2641) 2024-05-17 06:50:54 +00:00
Shubham Palriwala
fd78cec5ac fix: define postgres super user password for v2 runs (#2623) 2024-05-17 06:37:22 +00:00
Anshuman Pandey
0b87d35877 fix: data migration for styling fixes (#2640) 2024-05-16 18:03:21 +00:00
Anshuman Pandey
9849a96f32 fix: handles error in json input parsing in the management endpoints (#2634) 2024-05-16 15:36:46 +00:00
Anshuman Pandey
b5287f7f01 fix: modal z-index (#2626) 2024-05-15 09:48:07 +00:00
Piyush Gupta
11888f3e38 chore: Replace default exports/imports with module exports (#2617) 2024-05-14 14:17:49 +00:00
Anshuman Pandey
d2b27b046b fix: removes @headless-ui/react and moves modal to radix (#2608)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-05-14 13:08:46 +00:00
Johannes
8f4f26c143 chore: add upgrade hint in docs (#2616) 2024-05-14 13:07:57 +00:00
Anshuman Pandey
514d0a9e5a fix: limit the number of attribute classes per environment (#2613)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-05-14 11:57:36 +00:00
Anshuman Pandey
bc99f15094 feat: replaces dnd with dnd-kit (#2564)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-05-14 11:50:53 +00:00
Matti Nannt
ba0b68cbfb fix: update setup instructions in onboarding for formbricks 2.0 (#2615) 2024-05-14 12:55:29 +02:00
Anshuman Pandey
fb33005051 fix: disable formbricks error state in debug mode (#2580)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-05-14 08:30:18 +00:00
Anshuman Pandey
5da9091aee fix: multi and single select questions (#2606) 2024-05-14 08:26:26 +00:00
Piyush Gupta
a91a5e7014 docs: adds docs changes due to actions refactoring and inlineTriggers removal (#2593) 2024-05-13 14:56:23 +00:00
Dhruwang Jariwala
87a623a796 fix: zindex issue on respone page (#2611) 2024-05-13 14:42:02 +00:00
Johannes
ed75089ee0 fix: remove white label info from docs (#2610) 2024-05-13 10:21:03 +00:00
Dhruwang Jariwala
a04e031f9e fix: blank preview issue (#2605)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-05-10 13:58:28 +00:00
Dhruwang Jariwala
3c91dd52a0 fix: other option not working in multiSelect multi question (#2607) 2024-05-10 13:54:23 +00:00
Johannes
c282f630c4 fix: docs hover color dark mode (#2604) 2024-05-10 13:53:29 +00:00
Piyush Gupta
49bf9ec8a9 fix: adds search filter for value selection in logic editor (#2584)
Co-authored-by: Johannes <johannes@formbricks.com>
2024-05-10 13:10:11 +00:00
Anshuman Pandey
2b74054f4b fix: svg and links (#2603) 2024-05-10 08:57:33 +00:00
Matthias Nannt
64793132c7 fix: docker release cosign error 2024-05-09 18:59:57 +02:00
Johannes
ed946da338 remove FAQ to fix build error 2024-05-09 18:45:42 +02:00
Jatin
95f8c2b49f feat: added hardownload icon (#2574)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-05-09 16:23:31 +00:00
Johannes
5fb97008f3 fix: Fix broken links in docs (#2599) 2024-05-09 16:04:50 +00:00
Dhruwang Jariwala
555f5c3ea0 fix: added timeout before response submission for rating and NPS question (#2594)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-05-09 15:46:10 +00:00
Johannes
50407498ec feat: Formbricks App Redesign (#2581)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
2024-05-09 15:30:44 +00:00
Frank Mendez
556ee870b1 fix: incorrect format note in multiple best practices page (#2595) 2024-05-09 14:55:00 +00:00
Matti Nannt
0cad316fca chore: update npm dependencies (#2591) 2024-05-09 12:02:35 +02:00
Dhruwang Jariwala
d98df5ed3b fix: close survey button on centerd app survey (#2587) 2024-05-08 13:06:32 +00:00
Matti Nannt
e718217ec4 chore: add v2.0 data migration (#2589) 2024-05-07 19:45:56 +02:00
Dhruwang Jariwala
d4dea7c2cc fix: logo alignment in email (#2566) 2024-05-07 13:49:14 +00:00
Piyush Gupta
6bfd02794d feat: Refactor Triggers and combine Action Classes and Inline Triggers (#2562)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-05-07 13:47:41 +00:00
Piyush Gupta
b016d80cb2 feat: adds enterprise license check (#2431)
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
Co-authored-by: Anshuman Pandey <54475686+pandeymangg@users.noreply.github.com>
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-05-07 13:36:20 +00:00
Piyush Gupta
f529f5eda3 fix: Adds Thank You card loading (#2585)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-05-07 13:15:59 +00:00
Dhruwang Jariwala
3a1683eebd feat: Slick card look (#2531)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-05-07 12:42:48 +00:00
Shubham Palriwala
2ca38b1918 feat: revamp docker compose with new env vars & formatting (#2583)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-05-07 12:34:35 +00:00
Dhruwang Jariwala
82504e54b1 fix: recall not working on thank you card (#2586) 2024-05-07 12:20:39 +00:00
Matthias Nannt
61d8970420 release formbricks-js 2.0 stable 2024-05-07 12:54:42 +02:00
Matti Nannt
5c265aacb9 feat: full docs revamp for Formbricks 2.0 (#2568)
Co-authored-by: ShubhamPalriwala <spalriwalau@gmail.com>
2024-05-07 11:06:42 +02:00
Matthias Nannt
bb2c884150 Merge latest changes and release formbricks-js beta 2024-05-07 09:53:49 +02:00
Dhruwang Jariwala
7c388c975a fix: image uploader on welcome card (#2576) 2024-05-06 14:38:50 +00:00
Matthias Nannt
fc18950885 release js 2.0.0-beta.2 2024-05-06 14:27:15 +02:00
Piyush Gupta
386436ad5f fix: fixes survey createdBy filtering for null createdBy surveys (#2577) 2024-05-06 11:55:45 +00:00
Dhruwang Jariwala
328579f530 fix: migration for default translation missing in welcome card headline (#2533)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-05-06 10:53:46 +00:00
Anshuman Pandey
bc28936b2a fix: types resolution (#2563) 2024-05-06 08:37:18 +00:00
Giovanni Cascio
a9a09f3d24 fix: use localized question headline when extracting survey details (#2569)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-05-03 15:20:48 +00:00
Anshuman Pandey
8a2d196319 fix: adds z-index to modal close button (#2570) 2024-05-03 09:28:55 +00:00
Dhruwang Jariwala
e707713385 fix: Button label issue (#2549)
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
2024-05-02 10:24:56 +00:00
Anshuman Pandey
fc150170d0 fix: email embed styles (#2554)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-05-02 06:21:29 +00:00
Matthias Nannt
0e102ead33 release formbricks-js 2.0 beta 1 2024-04-30 17:49:01 +02:00
Johannes
1cba959d9b chore: replace img with next Image (#2558) 2024-04-30 14:42:09 +00:00
Anshuman Pandey
2c2d3839f9 fix: segment filtering (#2561) 2024-04-30 12:14:40 +00:00
Johannes
fb5474f61e chore: made logos move (#2560) 2024-04-30 10:45:40 +00:00
Anshuman Pandey
518d6cc336 fix: bundles api package with js-core (#2557)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-04-30 10:45:16 +00:00
Anshuman Pandey
2262370354 fix: app surveys internal server error (#2556) 2024-04-30 07:41:54 +00:00
Matti Nannt
48afdd1639 chore: move attributes to people page (#2555) 2024-04-29 17:29:47 +02:00
Anshuman Pandey
fc5adde0a9 chore: removes date picker question code from sideloading (#2550)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-04-29 14:43:13 +00:00
Dhruwang Jariwala
ff78e63b24 fix: restored Add logo button (#2537) 2024-04-29 14:38:27 +00:00
Dhruwang Jariwala
8b5443671c fix: Matrix Validation UX (#2551) 2024-04-29 13:17:18 +00:00
Anshuman Pandey
8ef6dc0a07 fix: global error handling js package (#2553) 2024-04-29 13:11:11 +00:00
Johannes
686031e61a fix: tweak saving UI (#2546)
Co-authored-by: Dhruwang <dhruwangjariwala18@gmail.com>
2024-04-29 10:40:43 +00:00
Piyush Gupta
e95a8c760c feat: Enable Prefilling of several values (#2482)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
2024-04-29 08:59:28 +00:00
Dhruwang Jariwala
7751a3fcfd feat: Keyboard usability for matrix and date question (#2514)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-29 07:42:36 +00:00
Likhiya Uttam
5baa2369b4 fix: Note formatting in Link Survey Data Prefilling (#2548) 2024-04-29 06:52:07 +00:00
Anshuman Pandey
f5236426ee fix: survey switch (#2547) 2024-04-26 20:33:07 +00:00
Johannes
a6568ea539 fix: Mobile height inconsistencies (#2540)
Co-authored-by: Dhruwang <dhruwangjariwala18@gmail.com>
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-04-26 16:04:03 +00:00
Jonas Höbenreich
460c046f0a docs: Quickstart frontend developer docs (#2510) 2024-04-26 18:21:33 +02:00
Shubham Palriwala
d41d60d877 docs: recontact options for in-app surveys (#2525)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-26 18:13:49 +02:00
Shubham Palriwala
c517eff308 docs: add email embedding of link surveys (#2532)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-26 15:56:07 +00:00
Shubham Palriwala
0f99a59ea5 docs: improve google sheet integration self hosting guide (#2536)
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-26 15:45:00 +00:00
Shubham Palriwala
3836b529fd docs: metadata for responses (#2522)
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-26 17:55:34 +02:00
Matti Nannt
15e6e60b62 fix: cached functions return dates as strings (#2541)
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
2024-04-26 15:18:10 +00:00
Johannes
5856a77064 chore: increase tooltip area (#2544) 2024-04-26 16:50:45 +02:00
Johannes
1192936be2 fix: update EE docs (#2545) 2024-04-26 16:49:49 +02:00
Jonas Höbenreich
4c351f8461 fix: Fix S3 credential checks (#2513)
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
2024-04-26 11:24:34 +00:00
Matti Nannt
c6c6c31d6d chore: remove service-revalidation-interval to simplify caching (#2539) 2024-04-26 09:09:45 +00:00
Anshuman Pandey
19cf9972d6 fix: product cache revalidation on product create (#2538) 2024-04-26 08:38:44 +00:00
Matthias Nannt
7b789904f8 chore: update survey types wording 2024-04-26 08:24:06 +02:00
Matthias Nannt
7c8754fd6b fix: attributeClass cache revalidation 2024-04-25 20:51:35 +02:00
Matti Nannt
6392a54592 chore: use attributeClass service in updateAttributes function (#2535) 2024-04-25 20:33:50 +02:00
Anshuman Pandey
7cbdadd90e fix: attribute service not filtering by environmentId (#2534) 2024-04-25 17:11:56 +00:00
Matti Nannt
183d32784f chore: handle people and attributes separately to improve sync performance (#2476)
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
2024-04-25 16:16:52 +00:00
Dhruwang Jariwala
5ff6e88b3b chore: Transactional emails to React email (#2349)
Co-authored-by: Piyush Gupta <piyushguptaa2z123@gmail.com>
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-04-25 13:04:10 +00:00
Piyush Gupta
db5efd3b8c fix: Call-to-Action statistics do not work as expected (#2457)
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-25 11:40:42 +00:00
Johannes
ad9ddb61cf fix: link blocking next buttons on mobile (#2530) 2024-04-25 10:14:05 +00:00
Matti Nannt
97c66e7a75 chore: update npm dependencies (#2528) 2024-04-25 10:07:56 +02:00
Dhruwang Jariwala
7fdee99974 fix: Max height (#2477)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-25 07:41:27 +00:00
Anshuman Pandey
4e57807a52 fix: fixes segment not getting saved bug (#2527) 2024-04-25 07:23:46 +00:00
Matthias Nannt
bb2499f1dc chore: update web npm dependencies 2024-04-24 20:20:02 +02:00
Vidhi Kapadia
2da2758255 feat: Added Unsplash API for image backgrounds (#2341)
Co-authored-by: ShubhamPalriwala <spalriwalau@gmail.com>
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-24 14:38:35 +00:00
Johannes
b322f014ab chore: add logo and upgrade footer (#2519) 2024-04-24 14:17:48 +00:00
Matthias Nannt
d408d42f00 chore: reduce Vercel memory limit 2024-04-24 16:28:31 +02:00
Matti Nannt
27875deb44 fix: display count in summary only updating with new response (#2524) 2024-04-24 16:17:24 +02:00
Dhruwang Jariwala
dcc98b671e chore: Link survey mobile view (#2493)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-24 14:03:54 +00:00
Piyush Gupta
4f5acbcddc fix: skip onboarding on invite and signup refactoring (#2507)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-24 13:50:04 +00:00
Piyush Gupta
a9bf8fcdaa fix: adds loader in the thankyou card while response submission (#2520)
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-24 13:28:38 +00:00
Shubham Palriwala
87f2f8d870 docs: revamp API docs with Postman (#2518)
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-24 12:59:28 +00:00
Matti Nannt
4ae38546f0 chore: limit remote action storing to userTargeting plan (#2521) 2024-04-24 14:56:05 +02:00
Dhruwang Jariwala
68c6dad26b chore: Adds save button to question Id input and refactored survey saving/publishing logic (#2488)
Co-authored-by: Piyush Gupta <piyushguptaa2z123@gmail.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-24 05:37:32 +00:00
Dhruwang Jariwala
3f9ff9c59b fix: picture select grow icon opacity issue (#2504)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-23 14:59:53 +00:00
Anshuman Pandey
86c8da3494 fix: Backwards compatibility for js/sync endpoint (#2516) 2024-04-23 14:05:50 +00:00
Shubham Palriwala
4ac60db896 docs: (Client Action API) mention user should pre-exist when creating action (#2500) 2024-04-23 14:02:36 +00:00
Shubham Palriwala
7ca4aee9a7 fix: remove unused description in createAttribute, updateSurvey to use params surveyId (#2515) 2024-04-23 13:55:08 +00:00
Anshuman Pandey
0e6cfbfaa5 feat: website surveys (#2423)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-04-23 13:21:28 +00:00
Matti Nannt
4f0edcd473 chore: update kamal instance hosts (#2509) 2024-04-23 09:56:34 +02:00
Matti Nannt
855342c1d1 chore: scale kamal instance (#2508) 2024-04-23 09:30:36 +02:00
Prashnta Pandey
dbcc030480 docs: Missing new line in management API docs (#2506) 2024-04-23 04:46:45 +00:00
Piyush Gupta
dc2ce17aa0 fix: remove or reupload avatar bug (#2502)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-22 15:51:07 +00:00
Matti Nannt
e2d5727cfc fix: display create leads to survey rerender (#2505) 2024-04-22 17:53:31 +02:00
Matti Nannt
f86e7c6738 fix: rate-limiting when using a load balancer (#2501) 2024-04-22 17:13:07 +02:00
Matti Nannt
d1aec18776 chore: add forth instance to kamal (#2503) 2024-04-22 16:02:01 +02:00
Dhruwang Jariwala
2ff17c2b22 docs: Event listener doc (#2432)
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: S P <spalriwalau@gmail.com>
2024-04-22 12:22:13 +00:00
Olasunkanmi Balogun
c9a8d022b4 feat: update best hotjar alternative article (#2459)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-22 08:52:19 +00:00
Matti Nannt
1307e42078 chore: add third kamal instance (#2499) 2024-04-22 10:17:07 +02:00
Johannes
5f40f8913b fix: remove double team switch, update route (#2479)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-04-22 07:30:52 +00:00
Piyush Gupta
4ee27f9618 fix: adds try...catch in all services (#2494)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-04-22 07:15:37 +00:00
Matti Nannt
ed509d3a9a chore: deactivate github action crons (#2498) 2024-04-22 08:56:51 +02:00
Anshuman Pandey
34ebfe4fd8 fix: fixes js package proxy (#2490) 2024-04-19 13:32:27 +00:00
Anshuman Pandey
e48ddbad5d fix: userId migration (#2453) 2024-04-19 12:53:41 +00:00
Matti Nannt
c6f9a6cdfc fix: legacy survey redirect links from formbricks.com (#2491) 2024-04-19 12:49:47 +00:00
Matti Nannt
e6ee81a683 chore: run kamal setup behind load balancer with multiple instances (#2480) 2024-04-19 14:48:22 +02:00
Anshuman Pandey
82853c8a07 fix: fixes form submission (#2492) 2024-04-19 09:43:07 +00:00
Anshuman Pandey
06f2d85f8e fix: handles errors while loading surveys pkg (#2489) 2024-04-19 07:08:13 +00:00
Johannes
687e12ad9b fix: fix-logo (#2485) 2024-04-18 20:11:39 +00:00
Matti Nannt
bb2d7b7a00 fix: legal footer overlaying buttons on smaller screens (#2484) 2024-04-18 18:37:56 +02:00
Anshuman Pandey
83b9400479 fix: structured clone (#2483) 2024-04-18 16:06:22 +00:00
Anshuman Pandey
0b26475934 fix: polyfills structuredClone (#2478) 2024-04-18 14:20:12 +00:00
Shubham Palriwala
505c1d0223 fix: secure send embed preview email action & show env id in email body (#2475) 2024-04-18 13:26:13 +02:00
Johannes
8e31710604 fix: remove the --save flag because deprecated (#2474)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-04-18 10:22:21 +00:00
Shubham Palriwala
b3883e8c9a fix: email previews to only be sent to the session user (#2473) 2024-04-18 12:11:08 +02:00
Johannes
d3f566237f chore: add yarn command (#2472) 2024-04-18 12:02:42 +02:00
Matti Nannt
49fe0dab67 chore: improve validation error logging (#2471) 2024-04-18 11:42:48 +02:00
Shubham Palriwala
0c86df1ce1 fix: rename airbase to airtable (#2470) 2024-04-18 09:26:30 +00:00
Piyush Gupta
e475179884 feat: added logic to show tags for viewer role (#2454) 2024-04-18 09:23:20 +00:00
Matti Nannt
b7299a6d31 fix: formbricks-com build errors (#2469) 2024-04-18 11:19:37 +02:00
Anshuman Pandey
9508db92f3 fix: fixes shortUrl not defined in metadata (#2468) 2024-04-18 08:03:07 +00:00
Dhruwang Jariwala
7f438afc30 fix: survey jumping to 3rd question with prefilling (#2421)
Co-authored-by: Piyush Gupta <piyushguptaa2z123@gmail.com>
2024-04-18 08:00:48 +00:00
Anik Dhabal Babu
1ddd1cfc3d feat: Ability to invite team members in bulk (#2424)
Co-authored-by: Dhruwang Jariwala <67850763+Dhruwang@users.noreply.github.com>
Co-authored-by: Dhruwang <dhruwangjariwala18@gmail.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-04-18 03:49:42 +00:00
Johannes
d22eab1548 chore: add Google disclosure to privacy policy (#2466)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-04-17 16:29:46 +00:00
Shubham Palriwala
2fca750931 fix: overlay & close on click outside to work in survey preview (#2436) 2024-04-17 15:31:31 +00:00
Matti Nannt
294b67a6cc chore: update npm dependencies (#2464) 2024-04-17 13:34:38 +02:00
Dhruwang Jariwala
e8e701c567 fix: The play() request was interrupted by a call to pause() (#2465) 2024-04-17 10:41:33 +00:00
Gideon Mohr
4fc8ee8181 fix: Pass only supported properties of account to CreateAccount (#2445)
Co-authored-by: Shubham Palriwala <spalriwalau@gmail.com>
2024-04-17 08:26:14 +00:00
Piyush Gupta
74b4be99a4 fix: single survey card rerenders on tag add or delete (#2461)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-17 08:19:18 +00:00
Dhruwang Jariwala
1bd9b8a485 fix: single select logic issue (#2458)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-04-17 04:14:37 +00:00
Matti Nannt
4b1652655b chore: move cacheHandler to a conditional import (#2463) 2024-04-16 18:14:40 +02:00
Matti Nannt
b114e4797e chore: use CUSTOM_CACHE_DISABLED env instead of vercel specific env (#2462) 2024-04-16 17:01:10 +02:00
Anshuman Pandey
5add263e6f fix: data migration and cleanup for userId attribute (#2400)
Co-authored-by: Dhruwang Jariwala <67850763+Dhruwang@users.noreply.github.com>
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-04-15 12:52:12 +00:00
Jonas Höbenreich
529144fe36 chore: Improve Debug messages (#2451) 2024-04-15 12:47:51 +00:00
Piyush Gupta
c2ea2716d3 feat: Add load more button to MultipleChoiceSummary component (#2449) 2024-04-15 10:34:59 +00:00
Shubham Palriwala
933ea87456 docs: fix S3_BUCKET_NAME env var in docs (#2448) 2024-04-15 10:05:29 +00:00
Matti Nannt
31e595972d chore: increase service revalidation interval to 24 hours (#2446) 2024-04-14 09:57:24 +02:00
Matti Nannt
27ba9114df chore: simplify action indexes (#2442) 2024-04-13 11:32:48 +02:00
Matti Nannt
a068a2176b chore: remove ecs workflow from repo (#2438) 2024-04-12 17:38:41 +02:00
Matti Nannt
008fafabf7 chore: increase kamal pgbouncer pool size to 100 (#2437) 2024-04-12 17:35:51 +02:00
Piyush Gupta
f07dffab07 fix: OpenTextSummary no longer has "Show more" button (#2427)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-12 15:28:05 +00:00
Johannes
fa0cadb166 fix: ui tweaks slack integration (#2428) 2024-04-12 11:09:35 +00:00
Shubham Palriwala
8ef74fdaff fix: constants timeframe in seconds (#2434) 2024-04-12 13:10:20 +02:00
Shubham Palriwala
1b5d3c216f feat: allow manual trigger of kamal deploy (#2430) 2024-04-12 09:55:11 +02:00
Shubham Palriwala
ee15c2676c feat: shared cache for next caching (#2426) 2024-04-11 19:05:49 +00:00
Naitik Kapadia
04e43725d1 feat: New Question Type Address (#2162)
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Dhruwang Jariwala <67850763+Dhruwang@users.noreply.github.com>
Co-authored-by: Dhruwang <dhruwangjariwala18@gmail.com>
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-04-11 13:30:11 +00:00
Piyush Gupta
4100949bf6 feat: Add Server-side Filtering to the Surveys Page (#2277)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
Co-authored-by: Dhruwang Jariwala <67850763+Dhruwang@users.noreply.github.com>
2024-04-11 03:54:15 +00:00
nikunj
bfb6012048 fix: Implement validation to remove cyclic logic (#2417)
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-04-10 15:42:32 +00:00
Dhruwang Jariwala
425d970e38 fix: nps and rating validation issue with mls (#2419)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-04-10 13:31:18 +00:00
Shubham Palriwala
24bde119cb feat: web builds across GitHub Action are cross branch now (#2410) 2024-04-10 12:06:37 +00:00
Johannes
668c74f3d6 chore: move multi-lang up on lp (#2422) 2024-04-10 11:46:34 +00:00
Shubham Palriwala
b153acaede fix: allow survey embeddings on other webpages (#2420) 2024-04-09 14:59:39 +00:00
Shubham Palriwala
18d3985e06 feat: docsearch integration (#2392)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-04-09 14:50:10 +00:00
Shubham Palriwala
95fe94fb7f fix: hide logo in branded link surveys (#2412)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-09 12:14:15 +00:00
M. Palanikannan
74829183ea feat: Slack Integration (#2125)
Co-authored-by: Henit Chobisa <chobisa.henit@gmail.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Piyush Gupta <piyushguptaa2z123@gmail.com>
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-04-09 12:12:25 +00:00
Piyush Gupta
ff60ff9e0b feat: Add response filtering for meta data (#2363)
Co-authored-by: Dhruwang Jariwala <67850763+Dhruwang@users.noreply.github.com>
Co-authored-by: Dhruwang <dhruwangjariwala18@gmail.com>
2024-04-09 10:37:58 +00:00
Parth Gupta
27ce171dc3 fix: Remove unnecessary loader in actions tab (#2371)
Co-authored-by: ShubhamPalriwala <spalriwalau@gmail.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-09 09:48:52 +00:00
Piyush Gupta
496d1b3c2e fix: Unsaved Changes Confirm even though changes were saved (#2372)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-09 09:24:59 +00:00
Piyush Gupta
015d4c7663 chore: Simpler Sharing Page [Concept] (#2361)
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
2024-04-09 08:57:28 +00:00
Naitik Kapadia
214917cdb8 fix: Preview for short urls (#2174)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Shubham Palriwala <spalriwalau@gmail.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-09 08:21:21 +00:00
Olasunkanmi Balogun
bfa0130672 feat: download-able feedback icons (#2276)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-08 15:00:50 +00:00
Dhruwang Jariwala
25b41b4d3a feat: profile image remove (#2411)
Co-authored-by: Sebastian Goscinski <sebiweise20@gmail.com>
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-04-08 11:58:25 +00:00
Shubham Palriwala
f93c5b3c55 fix: e2e tests, make welcomeCard.headline optional, remove console logs (#2374) 2024-04-08 09:37:09 +00:00
Matti Nannt
08ce026c7a feat: add survey schedule option (#2386)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Piyush Gupta <piyushguptaa2z123@gmail.com>
2024-04-08 09:36:06 +00:00
Shubham Palriwala
c44c0b83e3 fix: add MIGRATE_DATABASE_URL in kamal configs (#2407) 2024-04-08 09:32:05 +02:00
Stuart Malt
425d3819d7 fix: curl example message for update survey by id (#2405)
Co-authored-by: Shubham Palriwala <spalriwalau@gmail.com>
2024-04-08 07:12:59 +00:00
Shubham Palriwala
de82762aeb fix: product logo is received null from prisma if not set (#2404) 2024-04-08 06:04:32 +00:00
Shubham Palriwala
4cd23e62bb feat: load surveys package on-the-fly in web-app (#2375)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-04-08 06:03:24 +00:00
Matti Nannt
62da30246a chore: update npm dependencies (#2403) 2024-04-05 18:47:36 +02:00
Anshuman Pandey
1e81b1df8e fix: vercel build (#2394)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-04-05 16:07:47 +00:00
Matti Nannt
35d0d65022 chore: increase kamal pgbouncer connection pool (#2402) 2024-04-05 17:34:43 +02:00
Matti Nannt
37568f333e feat: add sentry sourcemap support to Dockerfile (#2401) 2024-04-05 17:16:39 +02:00
Manish Singh Bisht
160b3f6353 feat: Branded Link Surveys (#2262)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Shubham Palriwala <spalriwalau@gmail.com>
2024-04-05 11:20:39 +00:00
Dhruwang Jariwala
171469e26a fix: replace survey link display div with input field (#2389)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-05 09:48:00 +00:00
Johannes
bd5f5032f8 chore: remove auto capping surveys (#2395) 2024-04-05 09:45:01 +00:00
Johannes
9b27d6f84b fix: responsiveness of loading skeleton on link survey (#2396) 2024-04-05 09:35:19 +00:00
Dhruwang Jariwala
91822c6ced fix: issues in multi select, rating and nps questions (#2397)
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-05 09:33:04 +00:00
Matti Nannt
d36e5615a7 chore: increase healthcheck max_attempts in kamal (#2398) 2024-04-05 10:17:24 +02:00
Dhruwang Jariwala
7e6fe63f6a feat: Video upload (#2351)
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-05 04:40:52 +00:00
Dhruwang Jariwala
9f7cb7c1b9 fix: onboarding issues (#2373)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-04 21:26:09 +00:00
Shubham Palriwala
9e06dde2fc fix: use MIGRATE_DB_URL if present else fallback to DB_URL in migrate:deploy (#2390) 2024-04-04 12:24:55 +00:00
Shubham Palriwala
3a8aced70d feat: same origin header & password max length to prevent clickjackingg & DoS (#2370)
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
2024-04-04 11:47:53 +00:00
Matti Nannt
8d675bb91c chore: remove REDIS_CLIENT_URL from kamal (#2388) 2024-04-04 11:43:24 +02:00
Dhruwang Jariwala
f2c6bfd80f fix: Survey editor tweaks (#2378)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-04 09:10:19 +00:00
Dhruwang Jariwala
bc86249047 fix: recall not working with prefilled answer (#2379)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-04 08:45:13 +00:00
dependabot[bot]
2a35feb127 chore(deps-dev): bump the npm_and_yarn group across 1 directory with 1 update (#2387)
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-04-04 08:18:47 +00:00
Matti Nannt
1e0c90ca6f feat: add pgbouncer to kamal setup (#2382)
Co-authored-by: ShubhamPalriwala <spalriwalau@gmail.com>
2024-04-04 07:18:16 +00:00
Anshuman Pandey
d94e003244 fix: adds action to response meta (#2381) 2024-04-03 13:35:08 +00:00
Shubham Palriwala
2463ed8500 feat: add kamal setup workflow (#2380) 2024-04-03 09:12:20 +02:00
Shubham Palriwala
20eb679842 feat: use redis for rate limiting & next caching to resolve memory issues (#2078)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-04-02 14:46:43 +00:00
Shubham Palriwala
c8ab6644bf chore: cleanup css console log (#2376) 2024-04-02 12:48:54 +00:00
Shubham Palriwala
98e0006f88 docs: in-app & link multi language surveys (#2350)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
2024-04-02 12:35:31 +00:00
Anshuman Pandey
ec5f6301d3 fix: relative image urls (#2369)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-04-01 14:02:38 +00:00
Dhruwang Jariwala
5dc9a4da2f feat: Matrix question (#2271)
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Shubham Palriwala <spalriwalau@gmail.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-04-01 12:39:47 +00:00
Johannes
c33892b41b fix: change title (#2367) 2024-04-01 11:40:49 +00:00
Matti Nannt
cebc386de3 fix: error due to unused import (#2368) 2024-03-30 19:14:12 +00:00
Matti Nannt
4c118784be fix: date format transformation causing sync error (#2366) 2024-03-30 16:11:55 +01:00
Anshuman Pandey
85e5828cc8 fix: hotfix for sync validation errors (#2364) 2024-03-29 16:06:51 +00:00
Dhruwang Jariwala
dfb1f86ddb fix: show responses in summary that doesn't fit the current schema (#2318)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-28 16:27:00 +00:00
Laurens Nienhaus
6004505502 docs: 1.6 upgrade docs & mitigation steps (#2295)
Co-authored-by: laurens <>
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-28 17:13:26 +01:00
Matti Nannt
6122d88469 fix: packages api endpoint on vercel (#2359) 2024-03-28 15:59:28 +00:00
Anshuman Pandey
f15a4b237d fix: s3-cache (#2362) 2024-03-28 15:38:25 +00:00
Johannes
a1e9425a3e chore: Author page for blog (SEO) (#2356) 2024-03-28 13:07:24 +00:00
Shubham Palriwala
7219402aad docs: wsl2 postgres side note on local setup (#2347) 2024-03-28 10:34:32 +00:00
Shubham Palriwala
0f95f1c98c feat: Revamp @formbricks/js package (#2299)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-28 10:32:08 +00:00
Anshuman Pandey
a9e45c0086 fix: background tabs fixed (#2348) 2024-03-28 09:41:00 +00:00
Matti Nannt
dddc730ef4 fix: migration image name in migration docs (#2346) 2024-03-27 17:56:07 +01:00
Piyush Gupta
b99b499cde feat: No responses due to filter state (#2283)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-27 14:22:24 +00:00
Piyush Gupta
784930d9fc fix: first question preview in share embed modal (#2284) 2024-03-27 14:18:57 +00:00
Matti Nannt
54fe0081ae fix: remove survey autofocus in iframe, improve accessibility of question components (#2345) 2024-03-27 14:17:29 +00:00
Johannes
52a41dc458 docs: add ecs blog article (#2344) 2024-03-27 11:02:58 +00:00
Matti Nannt
f2dc157d54 chore: optimize sync endpoint performance (#2342) 2024-03-26 20:16:43 +00:00
nikunj
a70810cb91 feat: display URL in metadata (#2329)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-26 16:14:36 +00:00
Matti Nannt
a1e5060518 fix: displayPercentage not working for inline-triggers (#2340) 2024-03-26 16:00:24 +00:00
nikunj
46f062e81d fix: Profile image showing incorrectly (#2307)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-25 14:34:59 +00:00
Dhruwang Jariwala
b7ba2e09ef fix: Allow all URL-safe characters in hidden field Id/ questionId (#2250) 2024-03-25 14:12:05 +00:00
Johannes
855685fedd chore: add link (#2333) 2024-03-25 13:57:06 +00:00
Matti Nannt
1a15d3f6f9 fix: question header in csv export (#2331) 2024-03-25 12:35:29 +00:00
Dhruwang Jariwala
7a93af3f25 fix: discard formatting on paste in Lexical Editor (#2315) 2024-03-25 12:34:55 +00:00
Shubham Palriwala
6451bc5833 docs: startAt for Link Surveys (#2317) 2024-03-25 12:33:46 +00:00
Dhruwang Jariwala
308e889c85 fix: sort team and product names alphabetically (#2316) 2024-03-25 12:32:13 +00:00
Shubham Palriwala
69227bd91e docs: advanced targeting (#2325)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-25 10:14:13 +00:00
Piyush Gupta
1a21f40e5d fix: Summary view proportions don't add up to 100% (#2314) 2024-03-25 09:08:16 +00:00
Matti Nannt
18f1bc5490 fix: remove pino to fix Vercel deployment (#2328) 2024-03-25 08:50:33 +00:00
Shubham Palriwala
dadc337955 feat: pino logger for formbricks (#2296)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-22 13:21:44 +00:00
Johannes
b72cda05c1 chore: add advanced targeting blog and remove /learn (#2324) 2024-03-22 11:16:35 +00:00
Matti Nannt
520d6bee78 chore: increase service caching period to 3 hours (#2323) 2024-03-22 11:11:14 +01:00
Matti Nannt
4dcf4612b3 fix: webhooks page breaking with too many surveys in the env (#2322) 2024-03-22 10:02:59 +00:00
Anshuman Pandey
fa370c6900 feat: Advanced Custom Styling (#2182)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-22 09:50:16 +00:00
cosark
f5ef6b9c02 docs: Add RepoCloud Deployment Option to Readme (#2266)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-21 15:56:51 +01:00
Matti Nannt
cf8e22779a fix: Formbricks client route check errors if not enabled (#2311) 2024-03-21 14:23:27 +00:00
Jonas Höbenreich
10ac00940a fix: Docs footer link points to blog (#2306)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-21 13:15:30 +00:00
Dhruwang Jariwala
00beeb0501 fix: recall parsing in emails and improvements in response pipeline (#2187)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
Co-authored-by: Shubham Palriwala <spalriwalau@gmail.com>
2024-03-21 13:03:13 +00:00
Matti Nannt
db63d98b00 fix: add route change listener to formbricks integration (#2309) 2024-03-21 12:23:51 +00:00
Dhruwang Jariwala
3c80eb35d2 fix: Skip onboarding for invite (#2246) 2024-03-21 11:40:02 +00:00
Shubham Palriwala
96b6b53301 fix: blog post - formbricks is actively developed (#2304) 2024-03-21 10:56:01 +00:00
Shubham Palriwala
4dc5ace3f8 feat: redirect user to email verification page if not done (#2241) 2024-03-21 10:43:01 +00:00
Dhruwang Jariwala
26b8c4c7d5 fix: subheader validation (#2303) 2024-03-21 10:02:14 +00:00
Johannes
90f978bcd6 fix: increase pricing clarity (#2302) 2024-03-21 10:17:53 +01:00
Johannes
917847b5da chore: Blog post on remove branding (#2300) 2024-03-21 07:48:01 +00:00
Dhruwang Jariwala
f22e3fd549 fix: added migration script to fix range in rating question (#2298)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-20 20:20:10 +00:00
Dhruwang Jariwala
7b2cf9f3d8 fix: translate survey and migration script (#2290)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-20 17:37:01 +00:00
Matti Nannt
33f5da8c94 fix: unable to create actionClass due to caching issue (#2297) 2024-03-20 15:35:08 +00:00
Piyush Gupta
4a9f77f56a fix: integration and prefiling bug fix (#2293) 2024-03-20 14:33:07 +00:00
Matti Nannt
a99b53ae32 fix: pull surveys package from formbricks cloud as a hotfix (#2292) 2024-03-20 13:34:14 +01:00
Dhruwang Jariwala
1925382980 fix: archived attribute issue (#2275) 2024-03-20 11:13:49 +00:00
Piyush Gupta
d982ebca9d fix: make delete button more visible (#2291) 2024-03-20 11:12:30 +00:00
Dhruwang Jariwala
5810f9517e fix: verify email issues (#2281) 2024-03-19 19:46:07 +00:00
Matti Nannt
8f18e05075 fix: caching issue with translate surveys (#2288) 2024-03-19 19:36:28 +00:00
Matti Nannt
c611ed5cfe chore: change caching revalidation interval to 30minutes (#2286) 2024-03-19 20:18:42 +01:00
Matti Nannt
65dedfe500 chore: npm version upgrade 1.7.1 (#2285) 2024-03-19 13:35:11 +01:00
Matti Nannt
f494661235 fix: complex surveys not accepted in surveys management endpoint (#2282) 2024-03-19 12:10:18 +00:00
Shubham Palriwala
4abe080db2 fix: /api/js endpoint to work on vercel (#2242) 2024-03-19 09:46:09 +00:00
Matti Nannt
6c84850a7e fix: unable to save legacy surveys (#2280) 2024-03-19 09:06:18 +00:00
Matti Nannt
63708ec92b fix: Increase multilanguage data migration timeout (#2278) 2024-03-18 19:32:01 +00:00
Dhruwang Jariwala
8b5328aa74 feat: Multi language Surveys (#1630)
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
2024-03-18 19:02:18 +00:00
Shubham Palriwala
5c9e59b136 feat: expiresAt should only update on sync in js package (#2253)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-18 12:17:00 +00:00
Shubham Palriwala
7123a620c2 fix: add option to disable rate limitng in kamal (#2274)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-18 10:43:28 +01:00
Shubham Palriwala
6609b57084 fix: add nextauth url to kamal (#2272) 2024-03-18 09:53:55 +01:00
Matti Nannt
9123e3c866 chore: prepare kamal for production (#2263) 2024-03-16 08:02:06 +00:00
Jonas Höbenreich
92d0c6bce6 chore: small improvements (#2254)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-15 16:40:12 +00:00
Shubham Palriwala
ae3f1885c2 feat: add onboarding responses to user profiling in posthog (#2261) 2024-03-15 16:16:47 +00:00
Shubham Palriwala
3ca6ec8b56 chore: remove passing of build time env vars (#2236) 2024-03-15 16:15:18 +00:00
Jonas Höbenreich
83a46d7313 fix: fix on-the-fly url trigger always triggering IMPORTANT (#2256)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-15 15:24:23 +00:00
Piyush Gupta
b55b37b874 fix: fixes e2e tests (#2259) 2024-03-15 14:44:52 +00:00
Johannes
c76bcecca0 fix: remove duplicate text (#2257) 2024-03-15 12:53:40 +00:00
Johannes
3776397468 fix: lp cases (#2252) 2024-03-15 10:08:51 +00:00
Piyush Gupta
4704c4a077 fix: command dropdown breaking (#2249) 2024-03-15 10:07:38 +00:00
Shubham Palriwala
034ca1d639 fix: animated backgrounds in ios to not have video controls (#2251) 2024-03-15 09:50:24 +00:00
Johannes
e5862a2064 chore: new sub LPs, updated LP (#2207)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-15 09:16:48 +00:00
Matti Nannt
0332a2efe3 chore: add cache headers to og endpoint (#2240) 2024-03-14 14:24:23 +00:00
Kanishk Rawat
be8e461f55 chore: update Requestly url in OSS Friends (#2239) 2024-03-14 14:06:56 +00:00
Piyush Gupta
722ee68b4c feat: Paginated Surveys Management API (#2198) 2024-03-14 13:59:58 +00:00
Shubham Palriwala
e4078a3307 feat: opentelemetry integration (#2235)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-14 13:59:49 +00:00
Matti Nannt
907a9dc563 chore: rename github actions for simplification (#2238) 2024-03-14 13:46:41 +00:00
Piyush Gupta
f6df94081d feat: Add Server-side pagination to Surveys List (#2197)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-14 13:45:31 +00:00
talboren
2436192995 chore: add Keep to OSS friends (#2229)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-03-14 13:32:15 +00:00
Matti Nannt
f54e2e032a chore: update formbricks-com dependencies (#2237) 2024-03-14 13:17:13 +00:00
Piyush Gupta
1a28660dfd feat: added image link (#2228)
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-03-14 09:38:29 +00:00
Matti Nannt
f98a57582a chore: prepare 1.6.1 release (#2232) 2024-03-13 15:35:51 +00:00
David Septimus
0cc365261e feat: improve configurability for upload storage (#2144)
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-13 14:57:13 +00:00
Anshuman Pandey
6f78049c1f fix: fixes authorization checks for update product server action (#2231) 2024-03-13 13:31:22 +00:00
Piyush Gupta
2f11aa6c14 feat: adds response count indicator (#2213)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-13 10:18:37 +00:00
Dhruwang Jariwala
09cb61ae1e fix: display email instead of id (#2202)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-13 09:16:57 +00:00
Dhruwang Jariwala
65a152e518 fix: survey background image upload issue (#2222)
Co-authored-by: pandeymangg <anshuman.pandey9999@gmail.com>
2024-03-13 09:13:05 +00:00
Dhruwang Jariwala
92d88271d7 fix: scroll to bottom when other option is selected (#2204) 2024-03-13 09:11:40 +00:00
Dhruwang Jariwala
a56c354e84 fix: Incorrect created_at value while duplicating a survey (#2217)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-13 09:10:09 +00:00
Dhruwang Jariwala
29a9b7e23e fix: Autoclose issue (#2216) 2024-03-13 09:06:57 +00:00
Shubham Palriwala
94a419249b fix: font usage in surveys package (#2220) 2024-03-13 09:04:54 +00:00
Shubham Palriwala
12907c9061 feat: support for supercronic in arm images (#2224) 2024-03-13 09:02:11 +00:00
Shubham Palriwala
0aa468f8f3 fix: (e2e) API surveys after icons changed (#2225) 2024-03-13 09:01:37 +00:00
Shubham Palriwala
91447e1502 docs: remove old debug functionality in params (#2226) 2024-03-13 09:01:11 +00:00
Shubham Palriwala
84ea14820a docs: azure sso integration (#2227) 2024-03-13 08:04:20 +00:00
Piyush Gupta
8fb472c37c fix: rating quese style hotfix (#2223) 2024-03-13 07:57:56 +00:00
Naitik Kapadia
6efb6d4e7b feat: Ability to startAt specific question (#2175)
Co-authored-by: Piyush Gupta <piyushguptaa2z123@gmail.com>
2024-03-12 12:34:40 +00:00
Dhruwang Jariwala
99da20f831 chore: replaced Heroicons with corresponding lucide-react icons (#2221) 2024-03-12 12:29:21 +00:00
Shubham Palriwala
52d1dc9ed9 fix: e2e tests breaking in main (#2219)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-12 11:55:10 +00:00
JianJroh
5633bb18ef fix: use fileURLToPath to get correct file path on windows (#2147)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-12 11:53:39 +00:00
Piyush Gupta
b2cb0ecff3 fix: rating question options size (#2206)
Co-authored-by: Johannes <johannes@formbricks.com>
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-03-11 19:12:26 +00:00
Piyush Gupta
2089b339b4 fix: added checks on unauthorized server actions (#2218)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-11 14:16:47 +00:00
Piyush Gupta
2e83adc846 feat: adds skeleton loader (#2214) 2024-03-11 11:21:25 +00:00
Matti Nannt
189cbcecd7 chore: dockerfile needs no internet access to run (#2215) 2024-03-11 11:01:12 +00:00
Shubham Palriwala
5aebde79e7 docs: remove old debug functionality (#2212) 2024-03-11 10:21:55 +00:00
Piyush Gupta
5cce4a1db4 fix: display count change on date filter (#2208) 2024-03-11 08:33:49 +00:00
Piyush Gupta
c6ff74f166 fix: added sanitizeString util helper (#2209) 2024-03-09 06:47:37 +00:00
Shubham Palriwala
e8aad9f469 fix: remove unset env vars from kamal & gh action (#2210) 2024-03-08 13:30:18 +00:00
Shubham Palriwala
455a061f35 feat: kamal deployment integration (#2178) 2024-03-08 12:04:58 +00:00
Piyush Gupta
a9f35df278 fix: download responses not working (#2205) 2024-03-08 10:32:36 +00:00
Dhruwang Jariwala
82124a8b1c fix: lint warnings (#2201) 2024-03-07 14:41:33 +00:00
Dhruwang Jariwala
f3f93faf1d fix: Add button to link editor (#2200)
Co-authored-by: Johannes <72809645+jobenjada@users.noreply.github.com>
2024-03-07 14:41:02 +00:00
Piyush Gupta
57d117eb98 fix: Smiley Rating Question on iPhone / WebKit (#2195) 2024-03-07 11:18:47 +00:00
Piyush Gupta
d01b293a27 feat: Move Response Summary Server-side (#2160)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-06 11:53:21 +00:00
Shubham Palriwala
a9f5289672 feat: tests for survey API endpoints & fix survey create API input params (#2013)
Co-authored-by: Matti Nannt <mail@matthiasnannt.com>
2024-03-06 11:10:35 +00:00
Matti Nannt
1df1419827 chore: remove s3 check from health check for now (#2194) 2024-03-06 08:49:28 +00:00
Dhruwang Jariwala
f20a0d2ff7 fix: confirm modal on back button (#2189) 2024-03-06 07:42:32 +00:00
Johannes
b9e5a6f9b9 fix: onboarding skips + track sdk setup success (#2191) 2024-03-06 07:37:32 +00:00
Matti Nannt
b2eaf1f6a3 chore: remove posthog tracking from auth and share (#2190) 2024-03-05 14:41:50 +00:00
Matti Nannt
a873974f0d chore: improve db indexes with segmentId index (#2192) 2024-03-05 14:23:08 +00:00
Matti Nannt
09974e1a10 fix: action cacheClass cache not getting revalidation after deleting (#2188) 2024-03-05 12:04:36 +00:00
Piyush Gupta
45d5980527 fix: rating icon bug in safari (#2183)
Co-authored-by: Matthias Nannt <mail@matthiasnannt.com>
2024-03-05 10:30:59 +00:00
Piyush Gupta
73a25a412c fix: Call to Action question bug (#2184) 2024-03-05 09:44:41 +00:00
Matti Nannt
f0647ce240 fix: only get first page of surveys for survey list (#2186) 2024-03-05 08:45:08 +00:00
Anshuman Pandey
7c09dd9d10 fix: refetch server data when share embed modal is closed (#2185) 2024-03-05 08:10:49 +00:00
Matti Nannt
c5bdbc89ca fix: multiple surveys might be showing at the same time (#2179) 2024-03-04 11:15:06 +00:00
Dhruwang Jariwala
673832a7e1 fix: CORS error while using iframes (#2176) 2024-03-04 10:54:36 +00:00
2052 changed files with 55579 additions and 53910 deletions

View File

@@ -12,8 +12,8 @@
// Configure properties specific to VS Code.
"vscode": {
// Add the IDs of extensions you want installed when the container is created.
"extensions": ["dbaeumer.vscode-eslint"],
},
"extensions": ["dbaeumer.vscode-eslint"]
}
},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
@@ -25,5 +25,5 @@
"postAttachCommand": "pnpm dev --filter=web... --filter=demo...",
// Comment out to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
"remoteUser": "node",
"remoteUser": "node"
}

View File

@@ -56,11 +56,14 @@ SMTP_PASSWORD=smtpPassword
# Uncomment the variables you would like to use and customize the values.
# Custom local storage path for file uploads
#UPLOADS_DIR=
##############
# S3 STORAGE #
##############
# S3 Storage is required for the file uplaod in serverless environments like Vercel
# S3 Storage is required for the file upload in serverless environments like Vercel
S3_ACCESS_KEY=
S3_SECRET_KEY=
S3_REGION=
@@ -144,6 +147,10 @@ GOOGLE_SHEETS_REDIRECT_URL=
# Oauth credentials for Airtable integration
AIRTABLE_CLIENT_ID=
# Oauth credentials for Slack integration
SLACK_CLIENT_ID=
SLACK_CLIENT_SECRET=
# Enterprise License Key
ENTERPRISE_LICENSE_KEY=
@@ -162,3 +169,15 @@ ENTERPRISE_LICENSE_KEY=
# Ignore Rate Limiting across the Formbricks app
# RATE_LIMITING_DISABLED=1
# OpenTelemetry URL for tracing
# OPENTELEMETRY_LISTENER_URL=http://localhost:4318/v1/traces
# Unsplash API Key
UNSPLASH_ACCESS_KEY=
# The below is used for Next Caching (uses In-Memory from Next Cache if not provided)
# REDIS_URL:
# The below is used for Rate Limiting (uses In-Memory LRU Cache if not provided) (You can use a service like Webdis for this)
# REDIS_HTTP_URL:

View File

@@ -32,6 +32,7 @@ Fixes # (issue)
- [ ] Removed all `console.logs`
- [ ] Merged the latest changes from main onto my branch with `git pull origin main`
- [ ] My changes don't cause any responsiveness issues
- [ ] First PR at Formbricks? [Please sign the CLA!](https://cla-assistant.io/formbricks/formbricks) Without it we wont be able to merge it 🙏
### Appreciated

View File

@@ -1,11 +1,21 @@
name: Build & Cache Web App
on:
workflow_dispatch:
inputs:
e2e_testing_mode:
description: "Set E2E Testing Mode"
required: false
default: "0"
runs:
using: "composite"
steps:
- name: Checkout repo
uses: actions/checkout@v3
- uses: ./.github/actions/dangerous-git-checkout
- name: Cache Build
uses: actions/cache@v3
id: cache-build
@@ -13,13 +23,12 @@ runs:
cache-name: prod-build
key-1: ${{ hashFiles('pnpm-lock.yaml') }}
key-2: ${{ hashFiles('apps/**/**.[jt]s', 'apps/**/**.[jt]sx', 'packages/**/**.[jt]s', 'packages/**/**.[jt]sx', '!**/node_modules') }}
key-3: ${{ github.event.pull_request.number || github.ref }}
with:
path: |
${{ github.workspace }}/apps/web/.next
**/.turbo/**
**/dist/**
key: ${{ runner.os }}-${{ env.cache-name }}-${{ env.key-1 }}-${{ env.key-2 }}-${{ env.key-3 }}
key: ${{ runner.os }}-${{ env.cache-name }}-${{ env.key-1 }}-${{ env.key-2 }}
- name: Setup Node.js 20.x
uses: actions/setup-node@v3
@@ -40,10 +49,16 @@ runs:
run: cp .env.example .env
shell: bash
- name: Add E2E Testing Mode
run: |
echo "E2E_TESTING=${{ inputs.e2e_testing_mode }}" >> $GITHUB_ENV
shell: bash
- name: Generate Random ENCRYPTION_KEY
run: |
SECRET=$(openssl rand -hex 32)
echo "ENCRYPTION_KEY=$SECRET" >> $GITHUB_ENV
echo "ENTERPRISE_LICENSE_KEY=$SECRET" >> $GITHUB_ENV
shell: bash
- run: |

View File

@@ -1,26 +0,0 @@
name: Build formbricks-com
on:
workflow_call:
jobs:
build:
name: Build Formbricks-com
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- name: Checkout repo
uses: actions/checkout@v3
- name: Setup Node.js 20.x
uses: actions/setup-node@v3
with:
node-version: 20.x
- name: Install pnpm
uses: pnpm/action-setup@v2
- name: Install dependencies
run: pnpm install --config.platform=linux --config.architecture=x64
- name: Build Formbricks-com
run: pnpm build --filter=formbricks-com...

View File

@@ -1,11 +1,12 @@
name: Cron - reportUsageToStripe
name: Cron - Report usage to Stripe
on:
workflow_dispatch:
# "Scheduled workflows run on the latest commit on the default or base branch."
# — https://docs.github.com/en/actions/learn-github-actions/events-that-trigger-workflows#schedule
schedule:
# This will run the job at 20:00 UTC every day of every month.
- cron: "0 20 * * *"
# schedule:
# This will run the job at 20:00 UTC every day of every month.
# - cron: "0 20 * * *"
jobs:
cron-reportUsageToStripe:
env:

View File

@@ -1,11 +1,12 @@
name: Cron - closeOnDate
name: Cron - Survey status update
on:
workflow_dispatch:
# "Scheduled workflows run on the latest commit on the default or base branch."
# — https://docs.github.com/en/actions/learn-github-actions/events-that-trigger-workflows#schedule
schedule:
# Runs “At 00:00.” (see https://crontab.guru)
- cron: "0 0 * * *"
# schedule:
# Runs “At 00:00.” (see https://crontab.guru)
# - cron: "0 0 * * *"
jobs:
cron-weeklySummary:
env:
@@ -16,7 +17,7 @@ jobs:
- name: cURL request
if: ${{ env.APP_URL && env.CRON_SECRET }}
run: |
curl ${{ env.APP_URL }}/api/cron/close_surveys \
curl ${{ env.APP_URL }}/api/cron/survey-status \
-X POST \
-H 'content-type: application/json' \
-H 'x-api-key: ${{ env.CRON_SECRET }}' \

View File

@@ -1,11 +1,12 @@
name: Cron - weeklySummary
name: Cron - Weekly summary
on:
workflow_dispatch:
# "Scheduled workflows run on the latest commit on the default or base branch."
# — https://docs.github.com/en/actions/learn-github-actions/events-that-trigger-workflows#schedule
schedule:
# Runs “At 08:00 on Monday.” (see https://crontab.guru)
- cron: "0 8 * * 1"
# schedule:
# Runs “At 08:00 on Monday.” (see https://crontab.guru)
# - cron: "0 8 * * 1"
jobs:
cron-weeklySummary:
env:
@@ -16,7 +17,7 @@ jobs:
- name: cURL request
if: ${{ env.APP_URL && env.CRON_SECRET }}
run: |
curl ${{ env.APP_URL }}/api/cron/weekly_summary \
curl ${{ env.APP_URL }}/api/cron/weekly-summary \
-X POST \
-H 'content-type: application/json' \
-H 'x-api-key: ${{ env.CRON_SECRET }}' \

View File

@@ -13,6 +13,8 @@ jobs:
- name: Build & Cache Web Binaries
uses: ./.github/actions/cache-build-web
with:
e2e_testing_mode: "1"
- name: Install pnpm
uses: pnpm/action-setup@v2

View File

@@ -1,129 +0,0 @@
name: ECS
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
on:
push:
branches: [main]
workflow_dispatch: # Add manual trigger support
env:
REGISTRY: ghcr.io
IMAGE_NAME: formbricks/formbricks-experimental
DATABASE_URL: "postgresql://postgres:postgres@localhost:5432/formbricks?schema=public"
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
id-token: write # Only necessary for sigstore/fulcio outside PRs
steps:
- name: Generate Secrets
run: |
echo "NEXTAUTH_SECRET=$(openssl rand -hex 32)" >> $GITHUB_ENV
echo "ENCRYPTION_KEY=$(openssl rand -hex 32)" >> $GITHUB_ENV
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Depot CLI
uses: depot/setup-action@v1
# https://github.com/sigstore/cosign-installer
- name: Install cosign
uses: sigstore/cosign-installer@6e04d228eb30da1757ee4e1dd75a0ec73a653e06 #v3.1.1
with:
cosign-release: "v2.1.1"
# https://github.com/docker/login-action
- name: Log into registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
# Extract metadata (tags, labels) for Docker
# https://github.com/docker/metadata-action
- name: Extract Docker metadata
id: meta
uses: docker/metadata-action@v5 # v5.0.0
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: |
type=sha,format=long
# Build and push Docker image with Buildx
# https://github.com/docker/build-push-action
- name: Build and push Docker image
id: build-and-push
uses: depot/build-push-action@v1
env:
NEXT_PUBLIC_SENTRY_DSN: ${{ secrets.NEXT_PUBLIC_SENTRY_DSN }}
with:
project: tw0fqmsx3c
token: ${{ secrets.DEPOT_PROJECT_TOKEN }}
context: .
file: ./apps/web/Dockerfile
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
build-args: |
NEXTAUTH_SECRET=${{ env.NEXTAUTH_SECRET }}
DATABASE_URL=${{ env.DATABASE_URL }}
ENCRYPTION_KEY=${{ env.ENCRYPTION_KEY }}
NEXT_PUBLIC_SENTRY_DSN=${{ env.NEXT_PUBLIC_SENTRY_DSN }}
- name: Sign the images with GitHub OIDC Token
env:
DIGEST: ${{ steps.build-and-push.outputs.digest }}
TAGS: ${{ steps.meta.outputs.tags }}
run: |
images=""
for tag in ${TAGS}; do
images+="${tag}@${DIGEST} "
done
cosign sign --yes ${images}
outputs:
image_tag_sha: ${{ steps.meta.outputs.tags }}
deploy:
needs: build
runs-on: ubuntu-latest
steps:
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Download task definition
run: |
aws ecs describe-task-definition --task-definition prod-webapp-ecs-service --query taskDefinition > task-definition.json
- name: Fill in the new image ID in the Amazon ECS task definition
id: task-def
uses: aws-actions/amazon-ecs-render-task-definition@v1
with:
task-definition: task-definition.json
container-name: prod-webapp-container
image: ${{ needs.build.outputs.image_tag_sha }}
- name: Deploy Amazon ECS task definition
uses: aws-actions/amazon-ecs-deploy-task-definition@v1
with:
task-definition: ${{ steps.task-def.outputs.task-definition }}
service: prod-webapp-ecs-service
cluster: prod-core-infra-ecs-cluster
wait-for-service-stability: true

View File

@@ -1,7 +1,7 @@
name: PR Update
on:
pull_request_target:
pull_request:
branches:
- main
merge_group:
@@ -30,7 +30,7 @@ jobs:
- "!(**.md|.github/CODEOWNERS)"
test:
name: Run Tests
name: Run Unit Tests
needs: [changes]
if: ${{ needs.changes.outputs.has-files-requiring-all-checks == 'true' }}
uses: ./.github/workflows/test.yml
@@ -58,6 +58,7 @@ jobs:
secrets: inherit
required:
name: PR Check Summary
needs: [lint, test, build, e2e-test]
if: always()
runs-on: ubuntu-latest

View File

@@ -33,9 +33,7 @@ jobs:
- name: Install cosign
if: github.event_name != 'pull_request'
uses: sigstore/cosign-installer@6e04d228eb30da1757ee4e1dd75a0ec73a653e06 #v3.1.1
with:
cosign-release: "v2.1.1"
uses: sigstore/cosign-installer@v3.5.0
- name: Log in to GitHub Container Registry
uses: docker/login-action@v3

View File

@@ -1,9 +1,4 @@
name: Docker
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
name: Docker Release to GitHub
on:
workflow_dispatch:
@@ -31,16 +26,6 @@ jobs:
id-token: write
steps:
- name: Generate Random NEXTAUTH_SECRET
run: |
SECRET=$(openssl rand -hex 32)
echo "NEXTAUTH_SECRET=$SECRET" >> $GITHUB_ENV
- name: Generate Random ENCRYPTION_KEY
run: |
SECRET=$(openssl rand -hex 32)
echo "ENCRYPTION_KEY=$SECRET" >> $GITHUB_ENV
- name: Checkout repository
uses: actions/checkout@v3
@@ -51,9 +36,7 @@ jobs:
# https://github.com/sigstore/cosign-installer
- name: Install cosign
if: github.event_name != 'pull_request'
uses: sigstore/cosign-installer@6e04d228eb30da1757ee4e1dd75a0ec73a653e06 #v3.1.1
with:
cosign-release: "v2.1.1"
uses: sigstore/cosign-installer@v3.5.0
# Login against a Docker registry except on PR
# https://github.com/docker/login-action
@@ -65,6 +48,17 @@ jobs:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Set tags based on event type
id: set-tags
run: |
if [[ "${{ github.event_name }}" == "push" ]]; then
if [[ "${{ github.ref }}" == refs/tags/v* ]]; then
echo "::set-output name=tags::latest,${{ github.ref }}"
fi
elif [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then
echo "::set-output name=tags::experimental"
fi
# Extract metadata (tags, labels) for Docker
# https://github.com/docker/metadata-action
- name: Extract Docker metadata
@@ -72,6 +66,7 @@ jobs:
uses: docker/metadata-action@v5 # v5.0.0
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: ${{ steps.set-tags.outputs.tags }}
# Build and push Docker image with Buildx (don't push on PR)
# https://github.com/docker/build-push-action
@@ -89,10 +84,6 @@ jobs:
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
build-args: |
NEXTAUTH_SECRET=${{ env.NEXTAUTH_SECRET }}
DATABASE_URL=${{ env.DATABASE_URL }}
ENCRYPTION_KEY=${{ env.ENCRYPTION_KEY }}
# Sign the resulting Docker image digest except on PRs.
# This will only write to the public Rekor transparency log when the Docker

View File

@@ -1,58 +0,0 @@
name: Release on Dockerhub
on:
push:
tags:
- "v*"
jobs:
release-image-on-dockerhub:
name: Release on Dockerhub
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
DATABASE_URL: "postgresql://postgres:postgres@localhost:5432/formbricks?schema=public"
steps:
- name: Generate Random NEXTAUTH_SECRET
run: |
SECRET=$(openssl rand -hex 32)
echo "NEXTAUTH_SECRET=$SECRET" >> $GITHUB_ENV
- name: Generate Random ENCRYPTION_KEY
run: |
SECRET=$(openssl rand -hex 32)
echo "ENCRYPTION_KEY=$SECRET" >> $GITHUB_ENV
- name: Checkout Repo
uses: actions/checkout@v2
- name: Log in to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Get Release Tag
id: extract_release_tag
run: |
TAG=${{ github.ref }}
TAG=${TAG#refs/tags/v}
echo "RELEASE_TAG=$TAG" >> $GITHUB_ENV
- name: Build and push Docker image
uses: docker/build-push-action@v4
with:
context: .
file: ./apps/web/Dockerfile
push: true
tags: |
${{ secrets.DOCKER_USERNAME }}/formbricks:${{ env.RELEASE_TAG }}
${{ secrets.DOCKER_USERNAME }}/formbricks:latest
build-args: |
NEXTAUTH_SECRET=${{ env.NEXTAUTH_SECRET }}
DATABASE_URL=${{ env.DATABASE_URL }}
ENCRYPTION_KEY=${{ env.ENCRYPTION_KEY }}

View File

@@ -3,7 +3,7 @@ on:
workflow_call:
jobs:
build:
name: Tests
name: Unit Tests
runs-on: ubuntu-latest
timeout-minutes: 15

4
.gitignore vendored
View File

@@ -54,3 +54,7 @@ Zone.Identifier
# uploads
packages/lib/uploads
# Vite Timestamps
vite.config.*.timestamp-*

14
.kamal/hooks/post-deploy.sample Executable file
View File

@@ -0,0 +1,14 @@
#!/bin/sh
# A sample post-deploy hook
#
# These environment variables are available:
# KAMAL_RECORDED_AT
# KAMAL_PERFORMER
# KAMAL_VERSION
# KAMAL_HOSTS
# KAMAL_ROLE (if set)
# KAMAL_DESTINATION (if set)
# KAMAL_RUNTIME
echo "$KAMAL_PERFORMER deployed $KAMAL_VERSION to $KAMAL_DESTINATION in $KAMAL_RUNTIME seconds"

View File

@@ -0,0 +1,3 @@
#!/bin/sh
echo "Rebooted Traefik on $KAMAL_HOSTS"

51
.kamal/hooks/pre-build.sample Executable file
View File

@@ -0,0 +1,51 @@
#!/bin/sh
# A sample pre-build hook
#
# Checks:
# 1. We have a clean checkout
# 2. A remote is configured
# 3. The branch has been pushed to the remote
# 4. The version we are deploying matches the remote
#
# These environment variables are available:
# KAMAL_RECORDED_AT
# KAMAL_PERFORMER
# KAMAL_VERSION
# KAMAL_HOSTS
# KAMAL_ROLE (if set)
# KAMAL_DESTINATION (if set)
if [ -n "$(git status --porcelain)" ]; then
echo "Git checkout is not clean, aborting..." >&2
git status --porcelain >&2
exit 1
fi
first_remote=$(git remote)
if [ -z "$first_remote" ]; then
echo "No git remote set, aborting..." >&2
exit 1
fi
current_branch=$(git branch --show-current)
if [ -z "$current_branch" ]; then
echo "Not on a git branch, aborting..." >&2
exit 1
fi
remote_head=$(git ls-remote $first_remote --tags $current_branch | cut -f1)
if [ -z "$remote_head" ]; then
echo "Branch not pushed to remote, aborting..." >&2
exit 1
fi
if [ "$KAMAL_VERSION" != "$remote_head" ]; then
echo "Version ($KAMAL_VERSION) does not match remote HEAD ($remote_head), aborting..." >&2
exit 1
fi
exit 0

47
.kamal/hooks/pre-connect.sample Executable file
View File

@@ -0,0 +1,47 @@
#!/usr/bin/env ruby
# A sample pre-connect check
#
# Warms DNS before connecting to hosts in parallel
#
# These environment variables are available:
# KAMAL_RECORDED_AT
# KAMAL_PERFORMER
# KAMAL_VERSION
# KAMAL_HOSTS
# KAMAL_ROLE (if set)
# KAMAL_DESTINATION (if set)
# KAMAL_RUNTIME
hosts = ENV["KAMAL_HOSTS"].split(",")
results = nil
max = 3
elapsed = Benchmark.realtime do
results = hosts.map do |host|
Thread.new do
tries = 1
begin
Socket.getaddrinfo(host, 0, Socket::AF_UNSPEC, Socket::SOCK_STREAM, nil, Socket::AI_CANONNAME)
rescue SocketError
if tries < max
puts "Retrying DNS warmup: #{host}"
tries += 1
sleep rand
retry
else
puts "DNS warmup failed: #{host}"
host
end
end
tries
end
end.map(&:value)
end
retries = results.sum - hosts.size
nopes = results.count { |r| r == max }
puts "Prewarmed %d DNS lookups in %.2f sec: %d retries, %d failures" % [ hosts.size, elapsed, retries, nopes ]

109
.kamal/hooks/pre-deploy.sample Executable file
View File

@@ -0,0 +1,109 @@
#!/usr/bin/env ruby
# A sample pre-deploy hook
#
# Checks the Github status of the build, waiting for a pending build to complete for up to 720 seconds.
#
# Fails unless the combined status is "success"
#
# These environment variables are available:
# KAMAL_RECORDED_AT
# KAMAL_PERFORMER
# KAMAL_VERSION
# KAMAL_HOSTS
# KAMAL_COMMAND
# KAMAL_SUBCOMMAND
# KAMAL_ROLE (if set)
# KAMAL_DESTINATION (if set)
# Only check the build status for production deployments
if ENV["KAMAL_COMMAND"] == "rollback" || ENV["KAMAL_DESTINATION"] != "production"
exit 0
end
require "bundler/inline"
# true = install gems so this is fast on repeat invocations
gemfile(true, quiet: true) do
source "https://rubygems.org"
gem "octokit"
gem "faraday-retry"
end
MAX_ATTEMPTS = 72
ATTEMPTS_GAP = 10
def exit_with_error(message)
$stderr.puts message
exit 1
end
class GithubStatusChecks
attr_reader :remote_url, :git_sha, :github_client, :combined_status
def initialize
@remote_url = `git config --get remote.origin.url`.strip.delete_prefix("https://github.com/")
@git_sha = `git rev-parse HEAD`.strip
@github_client = Octokit::Client.new(access_token: ENV["GITHUB_TOKEN"])
refresh!
end
def refresh!
@combined_status = github_client.combined_status(remote_url, git_sha)
end
def state
combined_status[:state]
end
def first_status_url
first_status = combined_status[:statuses].find { |status| status[:state] == state }
first_status && first_status[:target_url]
end
def complete_count
combined_status[:statuses].count { |status| status[:state] != "pending"}
end
def total_count
combined_status[:statuses].count
end
def current_status
if total_count > 0
"Completed #{complete_count}/#{total_count} checks, see #{first_status_url} ..."
else
"Build not started..."
end
end
end
$stdout.sync = true
puts "Checking build status..."
attempts = 0
checks = GithubStatusChecks.new
begin
loop do
case checks.state
when "success"
puts "Checks passed, see #{checks.first_status_url}"
exit 0
when "failure"
exit_with_error "Checks failed, see #{checks.first_status_url}"
when "pending"
attempts += 1
end
exit_with_error "Checks are still pending, gave up after #{MAX_ATTEMPTS * ATTEMPTS_GAP} seconds" if attempts == MAX_ATTEMPTS
puts checks.current_status
sleep(ATTEMPTS_GAP)
checks.refresh!
end
rescue Octokit::NotFound
exit_with_error "Build status could not be found"
end

View File

@@ -0,0 +1,3 @@
#!/bin/sh
echo "Rebooting Traefik on $KAMAL_HOSTS..."

View File

@@ -138,6 +138,12 @@ You can deploy Formbricks on [Railway](https://railway.app) using the button bel
[![Deploy on Railway](https://railway.app/button.svg)](https://railway.app/new/template/PPDzCd)
##### RepoCloud
Or you can also deploy Formbricks on [RepoCloud](https://repocloud.io) using the button below.
[![Deploy on RepoCloud](https://d16t0pc4846x52.cloudfront.net/deploy.png)](https://repocloud.io/details/?app_id=254)
<a id="development"></a>
## 👨‍💻 Development
@@ -218,7 +224,7 @@ Additional to the AGPL licensed Formbricks core, this repository contains code l
### White-Labeling Formbricks and Other Licensing Needs
If you have other licensing requirements such as White-Labeling please [send us an email](mailto:hola@formbricks.com).
We currently do not offer Formbricks white-labeled. Any other needs? [Send us an email](mailto:hola@formbricks.com).
### Why charge for Enterprise Features?

View File

@@ -1,6 +1,6 @@
import Sidebar from "./Sidebar";
import { Sidebar } from "./Sidebar";
export default function LayoutApp({ children }: { children: React.ReactNode }) {
export const LayoutApp = ({ children }: { children: React.ReactNode }) => {
return (
<div className="min-h-full">
{/* Static sidebar for desktop */}
@@ -10,4 +10,4 @@ export default function LayoutApp({ children }: { children: React.ReactNode }) {
<div className="flex flex-1 flex-col lg:pl-64">{children}</div>
</div>
);
}
};

View File

@@ -1,31 +1,32 @@
import { classNames } from "@/lib/utils";
import {
ClockIcon,
CogIcon,
CreditCardIcon,
DocumentChartBarIcon,
FileBarChartIcon,
HelpCircleIcon,
HomeIcon,
QuestionMarkCircleIcon,
ScaleIcon,
ShieldCheckIcon,
UserGroupIcon,
} from "@heroicons/react/24/outline";
UsersIcon,
} from "lucide-react";
import { classNames } from "../lib/utils";
const navigation = [
{ name: "Home", href: "#", icon: HomeIcon, current: true },
{ name: "History", href: "#", icon: ClockIcon, current: false },
{ name: "Balances", href: "#", icon: ScaleIcon, current: false },
{ name: "Cards", href: "#", icon: CreditCardIcon, current: false },
{ name: "Recipients", href: "#", icon: UserGroupIcon, current: false },
{ name: "Reports", href: "#", icon: DocumentChartBarIcon, current: false },
{ name: "Recipients", href: "#", icon: UsersIcon, current: false },
{ name: "Reports", href: "#", icon: FileBarChartIcon, current: false },
];
const secondaryNavigation = [
{ name: "Settings", href: "#", icon: CogIcon },
{ name: "Help", href: "#", icon: QuestionMarkCircleIcon },
{ name: "Help", href: "#", icon: HelpCircleIcon },
{ name: "Privacy", href: "#", icon: ShieldCheckIcon },
];
export default function Sidebar({}) {
export const Sidebar = () => {
return (
<div className="flex flex-grow flex-col overflow-y-auto bg-cyan-700 pb-4 pt-5">
<nav
@@ -62,4 +63,4 @@ export default function Sidebar({}) {
</nav>
</div>
);
}
};

View File

@@ -0,0 +1,29 @@
import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "@formbricks/ui/Select";
interface SurveySwitchProps {
value: "website" | "app";
formbricks: any;
}
export const SurveySwitch = ({ value, formbricks }: SurveySwitchProps) => {
return (
<Select
value={value}
onValueChange={(v) => {
formbricks.logout();
window.location.href = `/${v}`;
}}>
<SelectTrigger className="w-[180px] px-4">
<SelectValue placeholder="Theme" />
</SelectTrigger>
<SelectContent>
<SelectItem value="website" className="h-10 px-4 hover:bg-slate-100">
Website Surveys
</SelectItem>
<SelectItem value="app" className="hover:bg-slate-10 h-10 px-4">
App Surveys
</SelectItem>
</SelectContent>
</Select>
);
};

View File

@@ -1,3 +1,3 @@
export function classNames(...classes: any) {
export const classNames = (...classes: any) => {
return classes.filter(Boolean).join(" ");
}
};

View File

@@ -1,6 +1,7 @@
/** @type {import('next').NextConfig} */
const nextConfig = {
reactStrictMode: true,
transpilePackages: ["@formbricks/ui"],
async redirects() {
return [
{

View File

@@ -12,12 +12,14 @@
},
"dependencies": {
"@formbricks/js": "workspace:*",
"@heroicons/react": "^2.1.1",
"next": "14.1.1",
"react": "18.2.0",
"react-dom": "18.2.0"
"@formbricks/ui": "workspace:*",
"lucide-react": "^0.378.0",
"next": "14.2.3",
"react": "18.3.1",
"react-dom": "18.3.1"
},
"devDependencies": {
"eslint-config-formbricks": "workspace:*"
"eslint-config-formbricks": "workspace:*",
"@formbricks/tsconfig": "workspace:*"
}
}

View File

@@ -3,7 +3,7 @@ import Head from "next/head";
import "../styles/globals.css";
export default function App({ Component, pageProps }: AppProps) {
const App = ({ Component, pageProps }: AppProps) => {
return (
<>
<Head>
@@ -18,4 +18,6 @@ export default function App({ Component, pageProps }: AppProps) {
<Component {...pageProps} />
</>
);
}
};
export default App;

View File

@@ -1,6 +1,6 @@
import { Head, Html, Main, NextScript } from "next/document";
export default function Document() {
const Document = () => {
return (
<Html lang="en" className="h-full bg-slate-50">
<Head />
@@ -10,4 +10,6 @@ export default function Document() {
</body>
</Html>
);
}
};
export default Document;

View File

@@ -2,13 +2,14 @@ import Image from "next/image";
import { useRouter } from "next/router";
import { useEffect, useState } from "react";
import formbricks from "@formbricks/js";
import formbricks from "@formbricks/js/app";
import { SurveySwitch } from "../../components/SurveySwitch";
import fbsetup from "../../public/fb-setup.png";
declare const window: any;
export default function AppPage({}) {
const AppPage = ({}) => {
const [darkMode, setDarkMode] = useState(false);
const router = useRouter();
@@ -21,17 +22,32 @@ export default function AppPage({}) {
}, [darkMode]);
useEffect(() => {
// enable Formbricks debug mode by adding formbricksDebug=true GET parameter
const addFormbricksDebugParam = () => {
const urlParams = new URLSearchParams(window.location.search);
if (!urlParams.has("formbricksDebug")) {
urlParams.set("formbricksDebug", "true");
const newUrl = `${window.location.pathname}?${urlParams.toString()}`;
window.history.replaceState({}, "", newUrl);
}
};
addFormbricksDebugParam();
if (process.env.NEXT_PUBLIC_FORMBRICKS_ENVIRONMENT_ID && process.env.NEXT_PUBLIC_FORMBRICKS_API_HOST) {
const isUserId = window.location.href.includes("userId=true");
const attributes = isUserId ? { "Init Attribute 1": "eight", "Init Attribute 2": "two" } : undefined;
const userId = isUserId ? "THIS-IS-A-VERY-LONG-USER-ID-FOR-TESTING" : undefined;
const userId = "THIS-IS-A-VERY-LONG-USER-ID-FOR-TESTING";
const userInitAttributes = {
language: "de",
"Init Attribute 1": "eight",
"Init Attribute 2": "two",
};
formbricks.init({
environmentId: process.env.NEXT_PUBLIC_FORMBRICKS_ENVIRONMENT_ID,
apiHost: process.env.NEXT_PUBLIC_FORMBRICKS_API_HOST,
userId,
attributes,
attributes: userInitAttributes,
});
window.formbricks = formbricks;
}
// Connect next.js router to Formbricks
@@ -48,15 +64,19 @@ export default function AppPage({}) {
return (
<div className="h-screen bg-white px-12 py-6 dark:bg-slate-800">
<div className="flex flex-col justify-between md:flex-row">
<div>
<h1 className="text-2xl font-bold text-slate-900 dark:text-white">
Formbricks In-product Survey Demo App
</h1>
<p className="text-slate-700 dark:text-slate-300">
This app helps you test your in-app surveys. You can create and test user actions, create and
update user attributes, etc.
</p>
<div className="flex items-center gap-2">
<SurveySwitch value="app" formbricks={formbricks} />
<div>
<h1 className="text-2xl font-bold text-slate-900 dark:text-white">
Formbricks In-product Survey Demo App
</h1>
<p className="text-slate-700 dark:text-slate-300">
This app helps you test your app surveys. You can create and test user actions, create and
update user attributes, etc.
</p>
</div>
</div>
<button
className="mt-2 rounded-lg bg-slate-200 px-6 py-1 dark:bg-slate-700 dark:text-slate-100"
onClick={() => setDarkMode(!darkMode)}>
@@ -69,7 +89,7 @@ export default function AppPage({}) {
<div className="rounded-lg border border-slate-300 bg-slate-100 p-6 dark:border-slate-600 dark:bg-slate-900">
<h3 className="text-lg font-semibold text-slate-900 dark:text-white">1. Setup .env</h3>
<p className="text-slate-700 dark:text-slate-300">
Copy the environment ID of your Formbricks app to the env variable in demo/.env
Copy the environment ID of your Formbricks app to the env variable in /apps/demo/.env
</p>
<Image src={fbsetup} alt="fb setup" className="mt-4 rounded" priority />
@@ -80,7 +100,7 @@ export default function AppPage({}) {
{process.env.NEXT_PUBLIC_FORMBRICKS_ENVIRONMENT_ID}
</strong>
<span className="relative ml-2 flex h-3 w-3">
<span className="absolute inline-flex h-full w-full animate-ping rounded-full bg-green-400 opacity-75"></span>
<span className="absolute inline-flex h-full w-full animate-ping rounded-full bg-green-500 opacity-75"></span>
<span className="relative inline-flex h-3 w-3 rounded-full bg-green-500"></span>
</span>
</div>
@@ -99,7 +119,7 @@ export default function AppPage({}) {
</div>
<div className="md:grid md:grid-cols-3">
<div className="col-span-3 rounded-lg border border-slate-300 bg-slate-100 p-6 dark:border-slate-600 dark:bg-slate-800">
<div className="col-span-3 self-start rounded-lg border border-slate-300 bg-slate-100 p-6 dark:border-slate-600 dark:bg-slate-800">
<h3 className="text-lg font-semibold dark:text-white">
Reset person / pull data from Formbricks app
</h3>
@@ -120,26 +140,6 @@ export default function AppPage({}) {
</p>
</div>
<div className="p-6">
<div>
<button
className="mb-4 rounded-lg bg-slate-800 px-6 py-3 text-white hover:bg-slate-700 dark:bg-slate-700 dark:hover:bg-slate-600"
onClick={() => {
formbricks.track("Code Action");
}}>
Code Action
</button>
</div>
<div>
<p className="text-xs text-slate-700 dark:text-slate-300">
This button sends a{" "}
<a href="https://formbricks.com/docs/actions/code" className="underline" target="_blank">
Code Action
</a>{" "}
to the Formbricks API called &apos;Code Action&apos;. You will find it in the Actions Tab.
</p>
</div>
</div>
<div className="p-6">
<div>
<button className="mb-4 rounded-lg bg-slate-800 px-6 py-3 text-white hover:bg-slate-700 dark:bg-slate-700 dark:hover:bg-slate-600">
@@ -234,43 +234,10 @@ export default function AppPage({}) {
</p>
</div>
</div>
<div className="p-6">
{router.query.userId === "true" ? (
<div>
<button
onClick={() => {
window.location.href = "/app";
}}
className="mb-4 rounded-lg bg-slate-800 px-6 py-3 text-white hover:bg-slate-700 dark:bg-slate-700 dark:hover:bg-slate-600">
Deactivate User Identification
</button>
</div>
) : (
<div>
<button
onClick={() => {
window.location.href = "/app?userId=true";
}}
className="mb-4 rounded-lg bg-slate-800 px-6 py-3 text-white hover:bg-slate-700 dark:bg-slate-700 dark:hover:bg-slate-600">
Activate User Identification
</button>
</div>
)}
<div>
<p className="text-xs text-slate-700 dark:text-slate-300">
This button activates/deactivates{" "}
<a
href="https://formbricks.com/docs/attributes/identify-users"
target="_blank"
className="underline dark:text-blue-500">
user identification
</a>{" "}
with the userId &apos;THIS-IS-A-VERY-LONG-USER-ID-FOR-TESTING&apos;
</p>
</div>
</div>
</div>
</div>
</div>
);
}
};
export default AppPage;

View File

@@ -0,0 +1,144 @@
import Image from "next/image";
import { useRouter } from "next/router";
import { useEffect, useState } from "react";
import formbricks from "@formbricks/js/website";
import { SurveySwitch } from "../../components/SurveySwitch";
import fbsetup from "../../public/fb-setup.png";
declare const window: any;
const AppPage = ({}) => {
const [darkMode, setDarkMode] = useState(false);
const router = useRouter();
useEffect(() => {
if (darkMode) {
document.body.classList.add("dark");
} else {
document.body.classList.remove("dark");
}
}, [darkMode]);
useEffect(() => {
// enable Formbricks debug mode by adding formbricksDebug=true GET parameter
const addFormbricksDebugParam = () => {
const urlParams = new URLSearchParams(window.location.search);
if (!urlParams.has("formbricksDebug")) {
urlParams.set("formbricksDebug", "true");
const newUrl = `${window.location.pathname}?${urlParams.toString()}`;
window.history.replaceState({}, "", newUrl);
}
};
addFormbricksDebugParam();
if (process.env.NEXT_PUBLIC_FORMBRICKS_ENVIRONMENT_ID && process.env.NEXT_PUBLIC_FORMBRICKS_API_HOST) {
const defaultAttributes = {
language: "de",
};
formbricks.init({
environmentId: process.env.NEXT_PUBLIC_FORMBRICKS_ENVIRONMENT_ID,
apiHost: process.env.NEXT_PUBLIC_FORMBRICKS_API_HOST,
attributes: defaultAttributes,
});
}
// Connect next.js router to Formbricks
if (process.env.NEXT_PUBLIC_FORMBRICKS_ENVIRONMENT_ID && process.env.NEXT_PUBLIC_FORMBRICKS_API_HOST) {
const handleRouteChange = formbricks?.registerRouteChange;
router.events.on("routeChangeComplete", handleRouteChange);
return () => {
router.events.off("routeChangeComplete", handleRouteChange);
};
}
});
return (
<div className="h-screen bg-white px-12 py-6 dark:bg-slate-800">
<div className="flex flex-col items-center justify-between md:flex-row">
<div className="flex items-center gap-2">
<SurveySwitch value="website" formbricks={formbricks} />
<div>
<h1 className="text-2xl font-bold text-slate-900 dark:text-white">
Formbricks Website Survey Demo App
</h1>
<p className="text-slate-700 dark:text-slate-300">
This app helps you test your app surveys. You can create and test user actions, create and
update user attributes, etc.
</p>
</div>
</div>
<button
className="mt-2 rounded-lg bg-slate-200 px-6 py-1 dark:bg-slate-700 dark:text-slate-100"
onClick={() => setDarkMode(!darkMode)}>
{darkMode ? "Toggle Light Mode" : "Toggle Dark Mode"}
</button>
</div>
<div className="my-4 grid grid-cols-1 gap-6 md:grid-cols-2">
<div>
<div className="rounded-lg border border-slate-300 bg-slate-100 p-6 dark:border-slate-600 dark:bg-slate-900">
<h3 className="text-lg font-semibold text-slate-900 dark:text-white">1. Setup .env</h3>
<p className="text-slate-700 dark:text-slate-300">
Copy the environment ID of your Formbricks app to the env variable in /apps/demo/.env
</p>
<Image src={fbsetup} alt="fb setup" className="mt-4 rounded" priority />
<div className="mt-4 flex-col items-start text-sm text-slate-700 sm:flex sm:items-center sm:text-base dark:text-slate-300">
<p className="mb-1 sm:mb-0 sm:mr-2">You&apos;re connected with env:</p>
<div className="flex items-center">
<strong className="w-32 truncate sm:w-auto">
{process.env.NEXT_PUBLIC_FORMBRICKS_ENVIRONMENT_ID}
</strong>
<span className="relative ml-2 flex h-3 w-3">
<span className="absolute inline-flex h-full w-full animate-ping rounded-full bg-green-500 opacity-75"></span>
<span className="relative inline-flex h-3 w-3 rounded-full bg-green-500"></span>
</span>
</div>
</div>
</div>
<div className="mt-4 rounded-lg border border-slate-300 bg-slate-100 p-6 dark:border-slate-600 dark:bg-slate-900">
<h3 className="text-lg font-semibold text-slate-900 dark:text-white">2. Widget Logs</h3>
<p className="text-slate-700 dark:text-slate-300">
Look at the logs to understand how the widget works.{" "}
<strong className="dark:text-white">Open your browser console</strong> to see the logs.
</p>
{/* <div className="max-h-[40vh] overflow-y-auto py-4">
<LogsContainer />
</div> */}
</div>
</div>
<div className="md:grid md:grid-cols-3">
<div className="col-span-3 self-start rounded-lg border border-slate-300 bg-slate-100 p-6 dark:border-slate-600 dark:bg-slate-800">
<h3 className="text-lg font-semibold dark:text-white">
Reset person / pull data from Formbricks app
</h3>
<p className="text-slate-700 dark:text-slate-300">
On formbricks.reset() the local state will <strong>be deleted</strong> and formbricks gets{" "}
<strong>reinitialized</strong>.
</p>
<button
className="my-4 rounded-lg bg-slate-500 px-6 py-3 text-white hover:bg-slate-700 dark:bg-slate-700 dark:hover:bg-slate-600"
onClick={() => {
formbricks.reset();
}}>
Reset
</button>
<p className="text-xs text-slate-700 dark:text-slate-300">
If you made a change in Formbricks app and it does not seem to work, hit &apos;Reset&apos; and
try again.
</p>
</div>
</div>
</div>
</div>
);
};
export default AppPage;

View File

@@ -1,23 +1,5 @@
{
"compilerOptions": {
"target": "es5",
"lib": ["dom", "dom.iterable", "esnext"],
"allowJs": true,
"skipLibCheck": true,
"strict": true,
"forceConsistentCasingInFileNames": true,
"noEmit": true,
"esModuleInterop": true,
"module": "esnext",
"moduleResolution": "node",
"resolveJsonModule": true,
"isolatedModules": true,
"jsx": "preserve",
"incremental": true,
"paths": {
"@/*": ["./*"]
}
},
"extends": "@formbricks/tsconfig/nextjs.json",
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx"],
"exclude": ["node_modules"]
}

View File

@@ -4,3 +4,7 @@ NEXT_PUBLIC_FORMBRICKS_COM_DOCS_FEEDBACK_SURVEY_ID=
# Strapi API Key
STRAPI_API_KEY=
NEXT_PUBLIC_DOCSEARCH_APP_ID=
NEXT_PUBLIC_DOCSEARCH_API_KEY=
NEXT_PUBLIC_DOCSEARCH_INDEX_NAME=

View File

@@ -35,3 +35,4 @@ yarn-error.log*
next-env.d.ts
public/sitemap*.xml
public/robots.txt

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

View File

@@ -0,0 +1,116 @@
import { MdxImage } from "@/components/MdxImage";
import I1 from "./images/I1.webp";
import I2 from "./images/I2.webp";
export const metadata = {
title: "Using Actions in Formbricks | Fine-tuning User Moments",
description:
"Dive deep into how actions in Formbricks help products and teams to engage users at precise moments in their journey. Discover the power of actions, from coding to no-code setups, to refine user targeting and generate richer, more detailed user insights.",
};
#### App Surveys
# Actions & Targeting
Understanding user thoughts and feelings at critical moments in their journey is pivotal. To achieve this, Formbricks uses user-centric actions that trigger surveys at precisely the right time. Actions are essentially notifications sent from your application to Formbricks when predefined user activities occur, making it possible to gather insights during key interactions.
<Note>
Ensure that youve **initialized Formbricks with a userId** to fully utilize this feature along with other
app survey capabilities.
</Note>
## **How Do Actions Work?**
Actions in Formbricks App Surveys are deeply integrated with user activities within your app. When a user performs a specified action, the Formbricks widget detects this activity and can present a survey to that specific user if the trigger conditions match of that survey, while also recording the event. This capability ensures that surveys are not only triggered at the right time but are also tailored to the users recent interactions within the app. You can set up these actions through a user-friendly No-Code interface within the Formbricks dashboard.
## **Why Are Actions Useful?**
Actions are invaluable for enhancing survey relevance and effectiveness:
- **Personalized Engagement**: Surveys triggered by user actions ensure content is highly relevant and engaging, matching each users current context.
- **User Attributes**: By tying surveys to specific user attributes, such as activity levels or feature usage, you can customize the survey experience to reflect individual user profiles.
- **User Segments**: Analyze action data to create detailed user segments, targeting specific groups with surveys that are pertinent to their behaviors or interactions within the app.
- **User Targeting**: Precise targeting based on user actions and attributes ensures that surveys are shown only to users who meet certain criteria, enhancing the relevance and effectiveness of each survey.
## **Setting Up No-Code Actions**
Formbricks offers an intuitive No-Code interface that allows you to configure actions without needing to write any code.
To add a No-Code Action:
1. Visit the Formbricks Dashboard & switch to the Actions tab:
<MdxImage
src={I1}
alt="setup checklist ui of survey popup for app surveys"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
2. Now click on “Add Action”
<MdxImage
src={I2}
alt="setup checklist ui of survey popup for app surveys"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
Here are three types of No-Code actions you can set up:
### **1. Page URL Action**
This action is triggered when a user visits a specific page within your application. You can define the URL match conditions as follows:
- **exactMatch**: Triggers the action when the URL exactly matches the specified string.
- **contains**: Activates when the URL contains the specified substring.
- **startsWith**: Fires when the URL starts with the specified string.
- **endsWith**: Executes when the URL ends with the specified string.
- **notMatch**: Triggers when the URL does not match the specified condition.
- **notContains**: Activates when the URL does not contain the specified substring.
### **2. innerText Action**
Checks if the innerText of a clicked HTML element, like a button label, matches a specific text. This action allows you to display a survey based on text interactions within your application.
### **3. CSS Selector Action**
This action verifies if a clicked HTML element matches a provided CSS selector, such as a class, ID, or any other CSS selector used in your website. It enables survey triggers based on element interactions.
<Note>You can have an action use combination of the 3 types as you wish</Note>
## **Setting Up Code Actions**
For more granular control, you can implement actions directly in your codebase:
1. **Configure the Action**: First, add the action via the Formbricks web interface to make it available for survey configuration.
After that you can fire an action using `formbricks.track()`
2. **Track an Action**: Use formbricks.track() to send an action event to Formbricks.
<Col>
<CodeGroup title="Track an action">
```javascript
formbricks.track("Action Name");
```
</CodeGroup>
</Col>
Here is an example of how to fire an action when a user clicks a button:
<Col>
<CodeGroup title="Track Button Click">
```javascript
const handleClick = () => {
formbricks.track("Button Clicked");
};
return <button onClick={handleClick}>Click Me</button>;
```
</CodeGroup>
</Col>
This documentation frames actions around user interactions, emphasizing the connection between the user's activities and the survey experience. By leveraging user-centric actions, you can create highly targeted and timely surveys that resonate with users and yield valuable insights.

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View File

@@ -0,0 +1,94 @@
import { MdxImage } from "@/components/MdxImage";
import { ResponsiveVideo } from "@/components/ResponsiveVideo";
import GermansGpt from "./germans-gpt.webp";
import Hni from "./hni.webp";
import PowerUsers from "./power-users.webp";
import RideHailing from "./ride-hailing.webp";
import UpsellMiro from "./upsell-miro.webp";
export const metadata = {
title: "Advanced Targeting in Surveys | Formbricks",
description:
"Advanced Targeting allows you to show surveys to just the right group of people. You can target surveys based on user attributes, user events, metadata , literally anything! This helps you get more relevant feedback and make data-driven decisions. All of this without writing a single line of code.",
};
#### App Surveys
# Advanced Targeting
Advanced Targeting allows you to show surveys to the right group of people. You can target surveys based on user attributes, user events, and more instead of spraying and praying. This helps you get more relevant feedback and make data-driven decisions. All of this without writing a single line of code.
<ResponsiveVideo title="Formbricks Multi-language Surveys"
src="https://www.youtube-nocookie.com/embed/0BQp6N4cXzU?si=KeBM7G7Ch1xtrsOm&amp;controls=0" />
## How to setup Advanced Targeting
<Note>
Advanced Targeting is available on the Pro plan! Don't worry, you just need to enter your credit card
details to start the freemium plan.
</Note>
1. On the Formbricks dashboard, click on **People** tab from the top navigation bar.
2. Switch to the **Segments** tab & click on **Create Segment**.
3. Give your segment a title & a description to help you remember what this segment is about.
4. Now click on the **Add Filter** button to add a filter. You can filter based on actions, user attributes, other segments, devices, and more.
5. To group a set of filters together, click on the Three Dots icon on the right side of the filter and click on **Create Group**.
6. Try playing around with different filters & conditions that we have provided to see how the segment size changes.
7. Once you are happy with the segment, click on **Save Segment**.
8. Now, when you create a survey, you can select this segment to target your survey to.
## Examples:
1. Let's say you want to upsell to: Miro, Loom, Figma, Slack and Asana.
<MdxImage
src={UpsellMiro}
alt="Upselling Opportunity"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
2. Post-experience surveying for a ride hailing app where users who have taken more than 1 ride are shown a survey.
<MdxImage
src={RideHailing}
alt="Ride Hailing Targeting"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
3. Target High Value users who have $100k+ in their bank account, own 20+ stocks, and have are an active user.
<MdxImage
src={Hni}
alt="Target Active High Net Worth Individuals"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
4. Target Germans on mobile phones who have regenerated chatGPT answers frequently in the last quarter and did so today.
<MdxImage
src={GermansGpt}
alt="Target Germans on Mobile Phones who have regenerated chatGPT answers frequently in the last quarter and did so today"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
5. Sneak Peak: How we at Formbricks automate inviting power users to chat with us
<MdxImage
src={PowerUsers}
alt="Automate inviting power users to chat with us at Formbricks"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

View File

@@ -1,11 +1,10 @@
import logoHtml from "@/images/logos/html5.svg";
import logoNextjs from "@/images/logos/nextjs.svg";
import logoReactJs from "@/images/logos/reactjs.svg";
import logoVueJs from "@/images/logos/vuejs.svg";
import { Button } from "@/components/Button";
import logoHtml from "@/images/frameworks/html5.svg";
import logoNextjs from "@/images/frameworks/nextjs.svg";
import logoReactJs from "@/images/frameworks/reactjs.svg";
import logoVueJs from "@/images/frameworks/vuejs.svg";
import Image from "next/image";
import { Button } from "./Button";
const libraries = [
{
href: "#html",
@@ -34,7 +33,7 @@ const libraries = [
},
];
export function Libraries() {
export const Libraries = () => {
return (
<div className="my-16 xl:max-w-none">
<div className="not-prose mt-4 grid grid-cols-1 gap-x-6 gap-y-10 border-slate-900/5 sm:grid-cols-2 xl:max-w-none xl:grid-cols-3 dark:border-white/5">
@@ -58,4 +57,4 @@ export function Libraries() {
</div>
</div>
);
}
};

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

View File

@@ -1,10 +1,10 @@
import { Libraries } from "@/components/docs/Libraries";
import Image from "next/image";
import { MdxImage } from "@/components/MdxImage";
import SetupChecklist from "./env-id.webp";
import ReactApp from "./react-in-app-survey-app-popup-form.webp";
import WidgetConnected from "./widget-connected.webp";
import WidgetNotConnected from "./widget-not-connected.webp";
import { Libraries } from "./components/Libraries";
import ReactApp from "./images/react-in-app-survey-app-popup-form.webp";
import WidgetConnected from "./images/widget-connected.webp";
import WidgetNotConnected from "./images/widget-not-connected.webp";
export const metadata = {
title: "Integrate Formbricks: Comprehensive Framework Guide & Integration Tutorial",
@@ -14,8 +14,8 @@ export const metadata = {
# Framework Guides
One can integrate Formbricks into their app using multiple options! Checkout the options below that we provide! If you are looking
for something else, please [join our Discord!](https://formbricks.com/discord) and we would be glad to help. {{ className: 'lead' }}
One can integrate Formbricks App Survey SDK into their app using multiple options! Checkout the options below that we provide! If you are looking
for something else, please [join our Discord!](https://formbricks.com/discord) and we would be glad to help.
<Libraries />
@@ -25,15 +25,8 @@ for something else, please [join our Discord!](https://formbricks.com/discord) a
Before getting started, make sure you have:
1. A web application in your desired framework is set up and running.
2. A Formbricks account with access to your environment ID and API host. You can find these in the **Setup Checklist** in the Settings:
<Image
src={SetupChecklist}
alt="Step 2 - Setup Checklist"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
1. A web application (behind your user authentication system) in your desired framework is set up and running.
2. A Formbricks account with access to your environment ID and API host. You can find these in the **Setup Checklist** in the Settings.
---
@@ -46,7 +39,11 @@ All you need to do is copy a `<script>` tag to your HTML head, and thats abou
```html {{ title: 'index.html' }}
<!-- START Formbricks Surveys -->
<script type="text/javascript">
!function(){var t=document.createElement("script");t.type="text/javascript",t.async=!0,t.src="https://unpkg.com/@formbricks/js@^1.6.0/dist/index.umd.js";var e=document.getElementsByTagName("script")[0];e.parentNode.insertBefore(t,e),setTimeout(function(){window.formbricks.init({environmentId: "<your-environment-id>", apiHost: "<api-host>"})},500)}();
!function(){
var apiHost = "https://app.formbricks.com";
var environmentId = "<your-environment-id>";
var userId = "<your-user-id>";
var t=document.createElement("script");t.type="text/javascript",t.async=!0,t.src=apiHost+"/api/packages/app";var e=document.getElementsByTagName("script")[0];e.parentNode.insertBefore(t,e),setTimeout(function(){window.formbricks.init({environmentId: environmentId, apiHost: apiHost, userId: userId})},500)}();
</script>
<!-- END Formbricks Surveys -->
```
@@ -58,11 +55,12 @@ All you need to do is copy a `<script>` tag to your HTML head, and thats abou
<Property name="environment-id" type="string">
Formbricks Environment ID.
</Property>
</Properties>
<Properties>
<Property name="api-host" type="string">
URL of the hosted Formbricks instance.
</Property>
<Property name="userId" type="string">
User ID of the user who has active session.
</Property>
</Properties>
Refer to our [Example HTML project](https://github.com/formbricks/examples/tree/main/html) for more help! Now visit the [Validate your Setup](#validate-your-setup) section to verify your setup!
@@ -76,7 +74,7 @@ Install the Formbricks SDK using one of the package managers ie `npm`,`pnpm`,`ya
<Col>
<CodeGroup title="Install Formbricks JS library">
```shell {{ title: 'npm' }}
npm install --save @formbricks/js
npm install @formbricks/js
```
```shell {{ title: 'pnpm' }}
pnpm add @formbricks/js
@@ -93,13 +91,13 @@ Now, update your App.js/ts file to initialise Formbricks.
```js
// other imports
import formbricks from "@formbricks/js";
import formbricks from "@formbricks/js/app";
if (typeof window !== "undefined") {
formbricks.init({
environmentId: "<environment-id>",
apiHost: "<api-host>",
debug: true, // remove when in production
userId: "<user-id>",
});
}
@@ -118,24 +116,14 @@ export default App;
<Property name="environment-id" type="string">
Formbricks Environment ID.
</Property>
</Properties>
<Properties>
<Property name="api-host" type="string">
URL of the hosted Formbricks instance.
</Property>
<Property name="userId" type="string">
User ID of the user who has active session.
</Property>
</Properties>
### What are we doing here?
The app initializes 'formbricks' when it's loaded in a browser environment (due to the typeof window !== "undefined" check) and then renders your components or content.
<Image
src={ReactApp}
alt="In app survey in React app for micro surveys"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
Refer to our [Example ReactJs project](https://github.com/formbricks/examples/tree/main/reactjs) for more help! Now visit the [Validate your Setup](#validate-your-setup) section to verify your setup!
---
@@ -154,7 +142,7 @@ Code snippets for the integration for both conventions are provided to further a
<Col>
<CodeGroup title="Install Formbricks JS library">
```shell {{ title: 'npm' }}
npm install --save @formbricks/js
npm install @formbricks/js
```
```shell {{ title: 'pnpm' }}
pnpm add @formbricks/js
@@ -165,35 +153,40 @@ yarn add @formbricks/js
</CodeGroup>
</Col>
### App Directory
<Col>
<CodeGroup title="app/formbricks.tsx">
```tsx {{title: 'Typescript'}}
"use client";
import formbricks from "@formbricks/js";
import { usePathname, useSearchParams } from "next/navigation";
import { useEffect } from "react";
import formbricks from "@formbricks/js/app";
export default function FormbricksProvider() {
const pathname = usePathname();
const searchParams = useSearchParams();
useEffect(() => {
formbricks.init({
environmentId: "<environment-id>",
apiHost: "<api-host>",
debug: true, // remove when in production
});
}, []);
useEffect(() => {
formbricks.init({
environmentId: "<environment-id>",
apiHost: "<api-host>",
userId: "<user-id>",
});
}, []);
useEffect(() => {
formbricks?.registerRouteChange();
}, [pathname, searchParams]);
useEffect(() => {
formbricks?.registerRouteChange();
}, [pathname, searchParams]);
return null;
return null;
}
```
````
</CodeGroup>
<CodeGroup title="app/layout.tsx">
@@ -209,7 +202,7 @@ export default function RootLayout({ children }: { children: React.ReactNode })
</html>
);
}
````
```
</CodeGroup>
</Col>
@@ -226,13 +219,13 @@ Refer to our [Example NextJS App Directory project](https://github.com/formbrick
import { useRouter } from "next/router";
import { useEffect } from "react";
import formbricks from "@formbricks/js";
import formbricks from "@formbricks/js/app";
if (typeof window !== "undefined") {
formbricks.init({
environmentId: "<environment-id>",
apiHost: "<api-host>",
debug: true, // remove when in production
userId: "<user-id>",
});
}
@@ -262,24 +255,15 @@ Refer to our [Example NextJS Pages Directory project](https://github.com/formbri
<Property name="environment-id" type="string">
Formbricks Environment ID.
</Property>
</Properties>
<Properties>
<Property name="api-host" type="string">
URL of the hosted Formbricks instance.
</Property>
</Properties>
### Optional Customizations to be Made
<Properties>
<Property name="debug" type="boolean">
Whether you want to see debug messages from Formbricks on your client-side console.
<Property name="userId" type="string">
User ID of the user who has active session.
</Property>
</Properties>
### What are we doing here?
First we need to initialize the Formbricks SDK, making sure it only runs on the client side.
First we initialize the Formbricks SDK, ensuring that it only runs on the client side.
To connect the Next.js router to Formbricks and ensure the SDK can keep track of every page change, we are registering the route change event.
Now visit the [Validate your Setup](#validate-your-setup) section to verify your setup!
@@ -294,7 +278,7 @@ We will make sure the SDK is only loaded and used on the client side, as it's no
<Col>
<CodeGroup title="Install Formbricks JS library">
```shell {{ title: 'npm' }}
npm install --save @formbricks/js
npm install @formbricks/js
````
```shell {{ title: 'pnpm' }}
@@ -310,12 +294,13 @@ yarn add @formbricks/js
<CodeGroup title="src/formbricks.js">
```js
import formbricks from "@formbricks/js";
import formbricks from "@formbricks/js/app";
if (typeof window !== "undefined") {
formbricks.init({
environmentId: "<environment-id>",
apiHost: "<api-host>",
userId: "<user-id>",
});
}
@@ -356,13 +341,8 @@ router.afterEach((to, from) => {
<Property name="api-host" type="string">
URL of the hosted Formbricks instance.
</Property>
</Properties>
### Optional Customizations to be Made
<Properties>
<Property name="debug" type="boolean">
Whether you want to see debug messages from Formbricks on your client-side console.
<Property name="userId" type="string">
User ID of the user who has active session.
</Property>
</Properties>
@@ -372,7 +352,7 @@ Refer to our [Example VueJs project](https://github.com/formbricks/examples/tree
Once you have completed the steps above, you can validate your setup by checking the **Setup Checklist** in the Settings. Your widget status indicator should go from this:
<Image
<MdxImage
src={WidgetNotConnected}
alt="Widget isnt connected"
quality="100"
@@ -381,7 +361,7 @@ Once you have completed the steps above, you can validate your setup by checking
To this:
<Image
<MdxImage
src={WidgetConnected}
alt="Widget is connected"
quality="100"
@@ -396,10 +376,9 @@ Enabling Formbricks debug mode in your browser is a useful troubleshooting step
To activate Formbricks debug mode:
1. **In Your Integration Code:**
1. **Via URL Parameter:**
- Locate the initialization code for Formbricks in your application (HTML, ReactJS, NextJS, VueJS).
- Set the `debug` option to `true` when initializing Formbricks.
- Enable debug mode mode by adding `?formbricksDebug=true` to your application's URL (e.g. `https://example.com?formbricksDebug=true` or `https://example.com?page=123&formbricksDebug=true`). This parameter will enable debugging for the current page.
2. **View Debug Logs:**
@@ -413,66 +392,21 @@ To activate Formbricks debug mode:
- **Safari:** Press `Option + Command + C` to open the developer tools and navigate to the "Console" tab.
- **Edge:** Press `F12` or right-click, select "Inspect Element," and go to the "Console" tab.
3. **Via URL Parameter:**
- For quick activation, add `?formbricksDebug=true` to your application's URL.
This parameter will enable debugging for the current session.
### Common Use Cases
Debug mode is beneficial for scenarios such as:
- Verifying Formbricks functionality.
- Identifying integration issues.
- Verifying Formbricks initialization.
- Identifying survey trigger issues.
- Troubleshooting unexpected behavior.
### Debug Log Messages
Specific debug log messages may provide insights into:
Debug log messages provide insights into:
- API calls and responses.
- Event tracking and form interactions.
- Integration errors.
**Note:** Disable debugging in production to prevent unnecessary logs and improve performance.
## Overwrite CSS Styles for In-App Surveys
You can overwrite the default CSS styles for the in-app surveys by adding the following CSS to your global CSS file (eg. `globals.css`):
Make sure that you do not change the CSS variable names as they are used by Formbricks to identify the CSS variables. You can change the values to your liking. We have filled in some sample values for you to change according to your desired appearance.
<Col>
<CodeGroup title="Overwrite Formbricks CSS">
```css
/* Formbricks CSS */
--fb-brand-color: red;
--fb-brand-text-color: white;
--fb-border-color: green;
--fb-border-color-highlight: rgb(13, 13, 12);
--fb-focus-color: red;
--fb-heading-color: yellow;
--fb-subheading-color: green;
--fb-info-text-color: orange;
--fb-signature-text-color: blue;
--fb-survey-background-color: black;
--fb-accent-background-color: rgb(13, 13, 12);
--fb-accent-background-color-selected: red;
--fb-placeholder-color: white;
--fb-shadow-color: var(--fb-brand-color);
--fb-rating-fill: rgb(13, 13, 12);
--fb-rating-hover: green;
--fb-back-btn-border: blue;
--fb-submit-btn-border: transparent;
--fb-rating-selected: black;
```
</CodeGroup>
</Col>
We have an example of this in our [Demo project](https://github.com/formbricks/formbricks/blob/main/apps/demo/styles/globals.css.) here.
- Event tracking, survey triggers and form interactions.
- Initialization errors.
**Cant figure it out? [Join our Discord!](https://formbricks.com/discord)**

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 41 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 23 KiB

View File

@@ -0,0 +1,117 @@
import { MdxImage } from "@/components/MdxImage";
import I1 from "./images/I1.webp";
import I2 from "./images/I2.webp";
import I3 from "./images/I3.webp";
import I4 from "./images/I4.webp";
import I5 from "./images/I5.webp";
import I6 from "./images/I6.webp";
import I7 from "./images/I7.webp";
import I8 from "./images/I8.webp";
export const metadata = {
title: "Formbricks Quickstart Guide: App Surveys Made Easier & Faster",
description:
"Formbricks is the easiest way to create and manage app surveys. This quickstart guide will show you how to create your first app survey in under 5 minutes.",
};
#### App Surveys
# Quickstart
App surveys have 6-10x better conversion rates than emailed out surveys. This tutorial explains how to run an app survey in your web app in 10 to 15 minutes. Lets go!
<Note>
App Surveys are ideal for websites that **have a user authentication** system. If you are looking to run
surveys on your public facing website, head over to the [Website Surveys Quickstart
Guide](/website-surveys/quickstart).
</Note>
1. **Create a free Formbricks Cloud account**: While you can [self-host](/self-hosting/deployment) Formbricks, but the quickest and easiest way to get started is with the free Cloud plan. Just [sign up here](https://app.formbricks.com/auth/signup) and you'll be guided to our onboarding like below:
<Note>
Website & App Surveys have the same integration process. The difference will come when we setup our survey.
</Note>
<MdxImage
src={I1}
alt="Choose website survey from survey type"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl "
/>
2. **Connect your App/Website**: Once you get through a couple of onboarding steps, youll be asked to connect your app or website. This is where youll find the code snippet for both HTML as well as the npm package which you need to embed in your app:
<MdxImage
src={I2}
alt="Code snippet for connecting app with Formbricks"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
Paste the code snippet in your app and reload the page. You should now see the Formbricks widget in the lower right corner of your app! The integration is now complete.
<MdxImage
src={I3}
alt="App connected with Formbricks"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
Onboarding is complete! Now lets create our first survey as you should see templates to choose from after clicking on **Next**:
<MdxImage
src={I4}
alt="Choose a survey template"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
3. **Create your first survey**: To be able to see a survey in your app, you need to create one. Well choose one of the templates and head over to the survey settings:
Pick the Survey Type as **App Survey**.
<MdxImage
src={I5}
alt="Survey settings for app survey"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
4. **Set Trigger for the Survey**: Scroll down to Survey Trigger and click on **+ Add action**, choose **New Session**. This will cause this survey to appear when the Formbricks Widget tracks a new user session:
<MdxImage
src={I6}
alt="Survey trigger settings for app survey"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
5. **Set Recontact Options for debugging**: In Recontact Options we choose the following settings, so that we can play around with the survey more easily. By default, each survey will be shown only once to each user to prevent survey fatigue:
<Note>
Please change this setting later on after testing your survey to prevent survey fatigue for your users.
</Note>
<MdxImage
src={I7}
alt="Recontact options for app survey"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
6. **Publish your survey**: Now hit **Publish** and youll be forwarded to the Summary Page. This is where youll find the responses to this survey.
<MdxImage
src={I8}
alt="Survey published successfully"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
---
- We offer framework guides for various frontend tech, head over to the the [App Survey Framework Guides](/app-survey/framework-guides) to get started with your app survey.
- Head over to our App Survey SDK documentation to get started with the [App Survey JS SDK](/developer-docs/app-survey-sdk).
Still struggling or something not working as expected? [Join our Discord!](https://formbricks.com/discord) and we'd be glad to assist you!

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 39 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

View File

@@ -0,0 +1,107 @@
import { MdxImage } from "@/components/MdxImage";
import AppSurvey from "./app-survey.webp";
import GlobalWaitTime from "./global-wait-time.webp";
import IgnoreWaitTime from "./ignore-wait-time.webp";
import SurveyRecontact from "./survey-recontact.webp";
export const metadata = {
title: "Recontact Options in Formbricks: When to show a survey again to a user",
description:
"Explore how to configure Recontact options in Formbricks to control the frequency of survey exposure to users, ensuring effective feedback collection without compromising user experience.",
};
#### App Surveys
# Recontact Options
Recontact options in Formbricks enable you to manage how often and under what conditions a survey is shown to a user. This feature is crucial for balancing effective feedback collection with a positive user experience by preventing survey fatigue.
## When do Recontact Options come into play?
Recontact options are the last layer of the logic that determines if a survey is shown to the current user. The logic goes as follows:
1. Targeting: Does the current user targeted to fill out this survey? If yes...
2. Trigger: Is the survey triggered? If yes...
3. **Recontact Options:** Should the survey be shown (again) to this user? That's dependent on:
- Did the user see any survey recently (meaning, has Global Waiting Time passed)?
- Did the user see this specific survey already?
- How many times did the user see this specific survey already?
- Has the user already responded to this survey?
As you can see, there are a lot of different cases to cover. Let's have a closer look 👇
## Recontact Options
<Note>By default, a survey is shown to each user only once.</Note>
You can adjust the default behavior by modifying the Recontact Options for each survey in the settings:
1. Open the Survey Editor for the survey you want to see & modify the Recontact Options for.
2. Select the Settings Tab.
3. Ensure your Survey type is set to **App Survey**.
<MdxImage
src={AppSurvey}
alt="Choose Survey Type as App Survey"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
4. Scroll down to the Recontact Options section.
Available Recontact Options include:
- **Show only once**: (default) Displays the survey a single time, regardless of whether it was completed.
- **Until they Submit a Response**: If tareting matches and trigger fires, Formbricks keeps showing the survey until the user submits a response.
- **Keep Showing while Conditions Match**: Always shows the survey while specific conditions are met. Useful for continuous feedback collection, such as in [Docs Feedback Survey](/best-practices/docs-feedback) or the [Feedback Box](/best-practices/feedback-box).
<MdxImage
src={SurveyRecontact}
alt="Choose Recontanct Options for the Survey"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
## Product-wide Global Waiting Time
The Global Waiting Time is a universal blocker to make sure that no user sees too many surveys. This is particularly helpful when several teams of large organisations use Formbricks at the same time.
<Note>The default Global Waiting Time is set to 7 days.</Note>
To adjust the Global Waiting Time:
1. Visit Formbricks Settings
2. Go to Product Settings
3. Find the **Recontact Waiting Time** section
4. Modify the interval (in days) as needed.
<MdxImage
src={GlobalWaitTime}
alt="Formbricks Product-Wide Wait Time"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
## Overriding Global Waiting Time for a Specific Survey
For specific surveys, you may need to override the default waiting time. Below is how you can do that:
1. In the Survey Editor, access the Settings Tab.
2. Find the Ignore Waiting Time between Surveys toggle under Recontact Options.
3. Enable this toggle to bypass the global setting.
4. Set a custom recontact period:
- **Always Show Survey**: Displays the survey whenever triggered, ignoring the waiting time.
- **Wait `X` days before showing this survey again**: Sets a specific interval before the survey can be shown again.
<MdxImage
src={IgnoreWaitTime}
alt="Ignore Global Waiting Time for a Specific Survey"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
---
Still struggling or something not working as expected? [Join our Discord!](https://formbricks.com/discord) and we'd be glad to assist you!

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

View File

@@ -1,10 +1,10 @@
export const metadata = {
title: "Identifying Users in Formbricks In-App Surveys",
title: "Identifying Users in Formbricks App Surveys",
description:
"Dive into the importance of user identification in surveys. Boost your survey response rates and target the right users with Formbricks.",
};
#### In-App Surveys
#### App Surveys
# User Identification
@@ -12,6 +12,11 @@ User Identification helps you to not only segment your users but also to see mor
### Understanding Identified vs Unidentified Users
<Note>
Formbricks App Surveys can **only be used with identified users**. If you are looking to run surveys on your
public-facing website, head over to the [Website Surveys](/website-surveys/quickstart) section.
</Note>
In Formbricks, understanding the distinction between identified and unidentified users is crucial for effective survey segmentation and targeted feedback collection.
| Feature | Unidentified Users | Identified Users |
@@ -25,36 +30,18 @@ In Formbricks, understanding the distinction between identified and unidentified
| Recommended for **public-facing websites** | ✅ | ❌ |
| Recommended for **web apps after login** | ❌ | ✅ |
## Unidentified Users
Unidentified users are those without a specific userId set. Surveys can still be presented to these users based on trigger actions, but without the granularity of user-specific targeting.
This method is recommended for public-facing websites where users are not required to log in.
<Col>
<CodeGroup title="Initialization without a user ID">
```javascript
formbricks.init({
environmentId: "<environment-id>",
apiHost: "<api-host>",
});
```
</CodeGroup>
</Col>
## Identified Users
Identified users are those for whom specific information has been set, notably the userId. This identification allows for more precise targeting of surveys and a deeper understanding of the feedback provided. When enabled, all information specified by you and all actions are sent to Formbricks.
This method is recommended for applications where users are required to log in and will often return.
**Setting the User ID:**
To identify a user, set the `userId` in the Formbricks initialization call. The userId should be a unique string, such as a database ID or an email address. This is essential for the user to be visible on the Formbricks dashboard.
### Setting User ID
To enable the User identification feature you need to set the `userId` in the init() call of Formbricks. Only when the `userId` is set the person will be visible in the Formbricks dashboard. The `userId` can be any string and it's best to use the default identifier you use in your app (e.g. unique id from database or the email address if it's unique) but you can also anonymize these as long as they are unique for every user.
<Col>
<CodeGroup title="Initialization with a user ID">
<CodeGroup title="Setting User ID">
```javascript
formbricks.init({
@@ -67,8 +54,63 @@ formbricks.init({
</CodeGroup>
</Col>
**Logging Out Users:**
When a user logs out of your application, ensure they are also logged out of Formbricks. This prevents the association of their activities with the wrong user profile.
### Enhanced Initialization with User Attributes
In addition to setting the `userId`, Formbricks allows you to set user attributes right at the initialization. This ensures that your user data is seamlessly integrated from the start. Here's how you can include user attributes in the `init()` function:
<Col>
<CodeGroup title="Enhanced Initialization with User Attributes">
```javascript
formbricks.init({
environmentId: "<environment-id>",
apiHost: "<api-host>",
userId: "<user_id>",
attributes: {
// your custom attributes
Plan: "premium",
},
});
```
</CodeGroup>
</Col>
## Setting Custom User Attributes
You can use the setAttribute function to set any custom attribute for the user (e.g. name, plan, etc.):
<Note>
Please note that the number of different attribute classes (e.g., "Plan," "First Name," etc.) is currently
limited to 150 attributes per environment.
</Note>
<Col>
<CodeGroup title="Setting Custom Attributes">
```javascript
formbricks.setAttribute("Plan", "free");
```
</CodeGroup>
</Col>
Generally speaking, the setAttribute function works like this:
<Col>
<CodeGroup title="Setting Custom Attributes">
```javascript
formbricks.setAttribute("attribute_key", "attribute_value");
```
</CodeGroup>
</Col>
Where `attributeName` is the name of the attribute you want to set, and `attributeValue` is the value of the attribute you want to set.
### Logging Out Users
When a user logs out of your webpage, make sure to log them out of Formbricks as well. This will prevent new activity from being associated with an incorrect user. Use the logout function:
<Col>
<CodeGroup title="Logging out User">
@@ -79,8 +121,3 @@ formbricks.logout();
</CodeGroup>
</Col>
<Note>
To set other custom attributes for a user, view our <a href="/docs/in-app-surveys/attributes">Attributes</a>{" "}
documentation.
</Note>

View File

@@ -1,5 +1,4 @@
import DemoPreview from "@/components/dummyUI/DemoPreview";
import Image from "next/image";
import { MdxImage } from "@/components/MdxImage";
import ChangeText from "./change-text.webp";
import CreateChurnFlow from "./create-cancel-flow.webp";
@@ -26,10 +25,6 @@ Churn is hard, but can teach you a lot. Whenever a user decides that your produc
The Churn Survey is among the most effective ways to identify weaknesses in your offering. People were willing to pay but now are not anymore: What changed? Lets find out!
## Preview
<DemoPreview template="Churn Survey" />
## Formbricks Approach
- Ask at exactly the right point in time
@@ -46,10 +41,9 @@ To run the Churn Survey in your app you want to proceed as follows:
4. Prevent that churn!
<Note>
## Formbricks Widget running?
We assume that you have already installed the Formbricks Widget in your web
app. Its required to display messages and surveys in your app. If not, please follow the [Quick Start Guide
(takes 15mins max.)](/docs/getting-started/quickstart-in-app-survey)
## Formbricks Widget running?
We assume that you have already installed the Formbricks Widget in your web app. Its required to display messages and surveys in your app. If not, please follow the [Quick Start Guide
(takes 15mins max.)](/app-surveys/quickstart)
</Note>
### 1. Create new Churn Survey
@@ -58,7 +52,7 @@ If you don't have an account yet, create one at [app.formbricks.com](https://app
Click on "Create Survey" and choose the template “Churn Survey”:
<Image
<MdxImage
src={CreateChurnFlow}
alt="Create churn survey by template"
quality="100"
@@ -69,7 +63,7 @@ Click on "Create Survey" and choose the template “Churn Survey”:
Youre free to update the question and answer options. However, based on our experience, we suggest giving the provided template a go 😊
<Image
<MdxImage
src={ChangeText}
alt="Change text content"
quality="100"
@@ -90,7 +84,7 @@ To create the trigger for your Churn Survey, you have two options to choose from
1. **Trigger by innerText:** You likely have a “Cancel Subscription” button in your app. You can setup a user Action with the according `innerText` to trigger the survey, like so:
<Image
<MdxImage
src={TriggerInnerText}
alt="Set the trigger by inner Text"
quality="100"
@@ -99,7 +93,7 @@ To create the trigger for your Churn Survey, you have two options to choose from
2. **Trigger by CSS Selector:** In case you have more than one button saying “Cancel Subscription” in your app and only want to display the survey when one of them is clicked, you want to be more specific. The best way to do that is to give this button the HTML `id=“cancel-subscription”` and set your user action up like so:
<Image
<MdxImage
src={TriggerCSS}
alt="Set the trigger by CSS Selector"
quality="100"
@@ -108,7 +102,7 @@ To create the trigger for your Churn Survey, you have two options to choose from
3. **Trigger by pageURL:** Lastly, you could also display your survey on a subpage “/subscription-cancelled” where you forward users once they cancelled the trial subscription. You can then create a user Action with the type `pageURL` with the following settings:
<Image
<MdxImage
src={TriggerPageUrl}
alt="Set the trigger by page URL"
quality="100"
@@ -117,18 +111,17 @@ To create the trigger for your Churn Survey, you have two options to choose from
Whenever a user visits this page, matches the filter conditions above and the recontact options (below) the survey will be displayed ✅
Here is our complete [Actions manual](/docs/actions/why) covering [Code](/docs/actions/code) and [No-Code](/docs/actions/no-code) Actions.
Here is our complete [Actions manual](/actions/why) covering [Code](/actions/code) and [No-Code](/actions/no-code) Actions.
<Note>
## Pre-churn flow coming soon
Were currently building full-screen survey pop-ups. Youll be able to prevent
## Pre-churn flow coming soon Were currently building full-screen survey pop-ups. Youll be able to prevent
users from closing the survey unless they respond to it. Its certainly debatable if you want that but you
could force them to click through the survey before letting them cancel 🤷
</Note>
### 5. Select Action in the “When to ask” card
<Image
<MdxImage
src={SelectAction}
alt="Select feedback button action"
quality="100"
@@ -139,7 +132,7 @@ Here is our complete [Actions manual](/docs/actions/why) covering [Code](/docs/a
Lastly, scroll down to “Recontact Options”. Here you have to choose the correct settings to make sure you milk these super valuable insights. You want to make sure that this survey is always displayed, no matter if the user has already seen a survey in the past days:
<Image
<MdxImage
src={RecontactOptions}
alt="Set recontact options"
quality="100"
@@ -150,7 +143,7 @@ These settings make sure the survey is always displayed, when a user wants to Ca
### 7. Congrats! Youre ready to publish your survey 💃
<Image
<MdxImage
src={PublishSurvey}
alt="Publish survey"
quality="100"
@@ -158,10 +151,8 @@ These settings make sure the survey is always displayed, when a user wants to Ca
/>
<Note>
## Formbricks Widget running?
You need to have the Formbricks Widget installed to display the Churn Survey
in your app. Please follow [this tutorial (Step 4 onwards)](/docs/getting-started/quickstart-in-app-survey)
to install the widget.
## Formbricks Widget running? You need to have the Formbricks Widget installed to display the Churn Survey
in your app. Please follow [this tutorial (Step 4 onwards)](/app-surveys/quickstart) to install the widget.
</Note>
###

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 55 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

View File

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 17 KiB

View File

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 24 KiB

View File

Before

Width:  |  Height:  |  Size: 5.0 KiB

After

Width:  |  Height:  |  Size: 5.0 KiB

View File

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 14 KiB

View File

@@ -1,14 +1,13 @@
import Image from "next/image";
import { MdxImage } from "@/components/MdxImage";
import DocsFeedback from "@/components/docs/DocsFeedback";
import AddAction from "./add-action.webp";
import ChangeId from "./change-id.webp";
import CopyIds from "./copy-ids.webp";
import DocsNavi from "./docs-navi.webp";
import DocsTemplate from "./docs-template.webp";
import SelectNonevent from "./select-nonevent.webp";
import SelectAction from "./select-action.webp";
import SurveyTrigger from "./survey-trigger.webp";
import SwitchToDev from "./switch-to-dev.webp";
import WhenToAsk from "./when-to-ask.webp";
import CopyIds from "./copy-ids.webp";
export const metadata = {
title:
@@ -27,10 +26,6 @@ Docs Feedback allows you to measure how clear your documentation is.
Unlike yourself, your users don't spend 5-7 days per week thinking about your product. To fight the "Curse of Knowledge" you have to measure how clear your docs are.
## Preview
<DocsFeedback />
## Installation
To get this running, you'll need a bit of time. Here are the steps we're going through:
@@ -46,7 +41,7 @@ To get this running, you'll need a bit of time. Here are the steps we're going t
2. In the Menu (top right) you see that you can switch between a “Development” and a “Production” environment. These are two separate environments so your test data doesnt mess up the insights from prod. Switch to “Development”:
<Image
<MdxImage
src={SwitchToDev}
alt="switch to dev environment"
quality="100"
@@ -55,7 +50,7 @@ To get this running, you'll need a bit of time. Here are the steps we're going t
3. Then, create a survey using the template “Docs Feedback”:
<Image
<MdxImage
src={DocsTemplate}
alt="select docs template"
quality="100"
@@ -64,7 +59,7 @@ To get this running, you'll need a bit of time. Here are the steps we're going t
4. Change the Internal Question ID of the first question to **“isHelpful”** to make your life easier 😉
<Image
<MdxImage
src={ChangeId}
alt="switch to dev environment"
quality="100"
@@ -78,10 +73,10 @@ To get this running, you'll need a bit of time. Here are the steps we're going t
choices accordingly. They have to be identical to the frontend we're building in the next step.
</Note>
6. Click on “Continue to Settings or select the audience tab manually. Scroll down to “When to ask” and create a new Action:
6. Click on “Continue to Settings or select the audience tab manually. Scroll down to “Survey Trigger” and create a new Action:
<Image
src={WhenToAsk}
<MdxImage
src={SurveyTrigger}
alt="set up when to ask card"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
@@ -89,18 +84,12 @@ To get this running, you'll need a bit of time. Here are the steps we're going t
7. Our goal is to create an event that never fires. This is a bit nonsensical because it is a workaround. Stick with me 😃 Fill the action out like on the screenshot:
<Image
src={AddAction}
alt="add action"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
className="rounded"
/>
<MdxImage src={AddAction} alt="add action" quality="100" className="max-w-full rounded-lg sm:max-w-3xl" />
8. Select the Non-Event in the dropdown. Now you see that the “Publish survey” button is active. Publish your survey 🤝
<Image
src={SelectNonevent}
<MdxImage
src={SelectAction}
alt="select nonevent"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
@@ -128,28 +117,25 @@ This allows us to capture and analyze partial feedback where the user is not wil
2. Likely, you have a template file or similar which renders the navigation at the bottom of the page:
<Image
src={DocsNavi}
alt="doc navigation"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
className="rounded"
/>
<MdxImage src={DocsNavi} alt="doc navigation" quality="100" className="max-w-full rounded-lg sm:max-w-3xl" />
Locate that file. We are using the [Tailwind Template “Syntax”](https://tailwindui.com/templates/syntax) for our docs. Here is our [Layout.tsx](https://github.com/formbricks/formbricks/blob/main/apps/formbricks-com/components/docs/Layout.tsx) file.
3. Write the frontend code for the widget. Here is the full component (we break it down right below):
<Col>
<CodeGroup title="Entire Widget">
```tsx
import { useState } from "react";
import { handleFeedbackSubmit, updateFeedback } from "../../lib/handleFeedbackSubmit";
import { Popover, PopoverTrigger, PopoverContent } from "@formbricks/ui/Popover";
import { Button } from "@formbricks/ui/Button";
import { useRouter } from "next/router";
import { useState } from "react";
export default function DocsFeedback() {
import { Button } from "@formbricks/ui/Button";
import { Popover, PopoverContent, PopoverTrigger } from "@formbricks/ui/Popover";
import { handleFeedbackSubmit, updateFeedback } from "../../lib/handleFeedbackSubmit";
export const DocsFeedback = () => {
const router = useRouter();
const [isOpen, setIsOpen] = useState(false);
const [sharedFeedback, setSharedFeedback] = useState(false);
@@ -213,7 +199,7 @@ export default function DocsFeedback() {
)}
</div>
);
}
};
```
</CodeGroup>
@@ -221,6 +207,7 @@ export default function DocsFeedback() {
**Lets break it down!**
Setting the local states and getting the current URL:
<Col>
<CodeGroup title="State Management">
@@ -311,9 +298,10 @@ return (
</Col>
## 3. Connecting to the Formbricks API
The last step is to hook up your sparkling new frontend to the Formbricks API. To do so, we followed the “[Create Response](/docs/api/client/responses#create-a-response)” and “[Update Response](/docs/api/client/responses#update-a-response)” pages in our docs.
The last step is to hook up your sparkling new frontend to the Formbricks API. To do so, we followed the “[Create Response](/api/client/responses#create-a-response)” and “[Update Response](/api/client/responses#update-a-response)” pages in our docs.
Here is the code for the `handleFeedbackSubmit` function with comments:
<Col>
<CodeGroup title="handleFeedbackSubmit() function definition">
@@ -412,9 +400,10 @@ Before you roll it out in production, you want to test it. To do so, you need tw
When you are on the survey detail page, youll find both of them in the URL:
<Image src={CopyIds} alt="copy IDs" quality="100" className="max-w-full rounded-lg sm:max-w-3xl" />
<MdxImage src={CopyIds} alt="copy IDs" quality="100" className="max-w-full rounded-lg sm:max-w-3xl" />
Now, you have to replace the IDs and the API host accordingly in your `handleFeedbackSubmit`:
<Col>
<CodeGroup title="Replace the ID and API accordingly">

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

View File

Before

Width:  |  Height:  |  Size: 8.4 KiB

After

Width:  |  Height:  |  Size: 8.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

View File

Before

Width:  |  Height:  |  Size: 25 KiB

After

Width:  |  Height:  |  Size: 25 KiB

View File

@@ -1,8 +1,7 @@
import DemoPreview from "@/components/dummyUI/DemoPreview";
import Image from "next/image";
import { MdxImage } from "@/components/MdxImage";
import ActionCSS from "./action-css.webp";
import ActionText from "./action-text.webp";
import ActionText from "./action-innertext.webp";
import ChangeText from "./change-text.webp";
import CreateSurvey from "./create-survey.webp";
import Publish from "./publish.webp";
@@ -25,10 +24,6 @@ Following up on specific features only makes sense with very targeted surveys. F
Product analytics never tell you why a feature is used - and why not. Following up on specific features with highly relevant questions is a great way to gather feedback and improve your product.
## Preview
<DemoPreview template="Feature Chaser" />
## Formbricks Approach
- Trigger survey at exactly the right point in the user journey
@@ -43,10 +38,9 @@ To run the Feature Chaser survey in your app you want to proceed as follows:
2. Setup a user action to display survey at the right point in time
<Note>
## Formbricks Widget running?
We assume that you have already installed the Formbricks Widget in your web
app. Its required to display messages and surveys in your app. If not, please follow the [Quick Start Guide
(takes 15mins max.)](/docs/getting-started/quickstart-in-app-survey)
## Formbricks Widget running?
We assume that you have already installed the Formbricks Widget in your web wapp. Its required to display messages and surveys in your app. If not, please follow the [Quick Start Guide
(takes 15mins max.)](/app-surveys/quickstart)
</Note>
### 1. Create new Feature Chaser
@@ -55,7 +49,7 @@ If you don't have an account yet, create one at [app.formbricks.com](https://app
Click on "Create Survey" and choose the template “Feature Chaser”:
<Image
<MdxImage
src={CreateSurvey}
alt="Create survey by template"
quality="100"
@@ -66,7 +60,7 @@ Click on "Create Survey" and choose the template “Feature Chaser”:
The questions you want to ask are dependent on your feature and can be very specific. In the template, we suggest a high-level check on how easy it was for the user to achieve their goal. We also add an opportunity to provide context:
<Image
<MdxImage
src={ChangeText}
alt="Change text content"
quality="100"
@@ -79,13 +73,13 @@ Save, and move over to where the magic happens: The “Audience” tab.
Before setting the right trigger, you need to identify a user action in your app which signals, that they have just used the feature you want to understand better. In most cases, it is clicking a specific button in your product.
You can create [Code Actions](/docs/actions/code) and [No Code Actions](/docs/actions/no-code) to follow users through your app. In this example, we will create a No Code Action.
You can create [Code Actions](/actions/code) and [No Code Actions](/actions/no-code) to follow users through your app. In this example, we will create a No Code Action.
There are two ways to track a button:
1. **Trigger by innerText:** You might have a button with a unique text at the end of your feature e.g. "Export Report". You can setup a user Action with the according `innerText` to trigger the survey, like so:
<Image
<MdxImage
src={ActionText}
alt="Set the trigger by inner Text"
quality="100"
@@ -94,18 +88,18 @@ There are two ways to track a button:
2. **Trigger by CSS Selector:** In case you have more than one button saying “Export Report” in your app and only want to display the survey when one of them is clicked, you want to be more specific. The best way to do that is to give this button the HTML `id=“export-report-featurename”` and set your user action up like so:
<Image
<MdxImage
src={ActionCSS}
alt="Set the trigger by CSS Selector"
quality="100"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
Please follow our [Actions manual](/docs/actions/why) for an in-depth description of how Actions work.
Please follow our [Actions manual](/actions/why) for an in-depth description of how Actions work.
### 4. Select Action in the “When to ask” card
<Image
<MdxImage
src={SelectAction}
alt="Select PMF trigger button action"
quality="100"
@@ -116,7 +110,7 @@ Please follow our [Actions manual](/docs/actions/why) for an in-depth descriptio
Lastly, scroll down to “Recontact Options”. Here you have full freedom to decide who you want to ask. Generally, you only want to ask every user once and prevent survey fatigue. It's up to you to decide if you want to ask again, when the user did not yet reply:
<Image
<MdxImage
src={RecontactOptions}
alt="Set recontact options"
quality="100"
@@ -125,13 +119,11 @@ Lastly, scroll down to “Recontact Options”. Here you have full freedom to de
### 7. Congrats! Youre ready to publish your survey 💃
<Image src={Publish} alt="Publish survey" quality="100" className="max-w-full rounded-lg sm:max-w-3xl" />
<MdxImage src={Publish} alt="Publish survey" quality="100" className="max-w-full rounded-lg sm:max-w-3xl" />
<Note>
## Formbricks Widget running?
You need to have the Formbricks Widget installed to display the Feature Chaser
in your app. Please follow [this tutorial (Step 4 onwards)](/docs/getting-started/quickstart-in-app-survey)
to install the widget.
## Formbricks Widget running? You need to have the Formbricks Widget installed to display the Feature Chaser
in your app. Please follow [this tutorial (Step 4 onwards)](/app-surveys/quickstart) to install the widget.
</Note>
###

View File

Before

Width:  |  Height:  |  Size: 29 KiB

After

Width:  |  Height:  |  Size: 29 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 36 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

View File

@@ -1,19 +1,19 @@
import { MdxImage } from "@/components/MdxImage";
import Link from "next/link";
import Image from "next/image";
import DemoPreview from "@/components/dummyUI/DemoPreview";
import ActionCSS from "./action-css.webp";
import ActionText from "./action-innertext.webp";
import AddAction from "./add-action.webp";
import AddCSSAction from "./add-css-action.webp";
import AddHTMLAction from "./add-html-action.webp";
import ChangeTextContent from "./change-text-content.webp";
import CreateFeedbackBox from "./create-feedback-box-by-template.webp";
import PublishSurvey from "./publish-survey.webp";
import SelectAction from "./select-feedback-button-action.webp";
import SelectAction from "./select-action.webp";
import RecontactOptions from "./set-recontact-options.webp";
export const metadata = {
title: "Implementing the Feedback Box with Formbricks: A Step-by-Step Tutorial",
description: "Unlock user insights effortlessly! Discover how to set up the Feedback Box in your app using Formbricks, allowing your users to provide real-time feedback. Follow our comprehensive guide to enhance user experience and respond rapidly to feedback",
description:
"Unlock user insights effortlessly! Discover how to set up the Feedback Box in your app using Formbricks, allowing your users to provide real-time feedback. Follow our comprehensive guide to enhance user experience and respond rapidly to feedback",
};
#### Best Practices
@@ -26,10 +26,6 @@ The Feedback Box gives your users a direct channel to share their feedback and f
A low friction way to gather feedback helps catching even the smallest points of frustration in user experiences. Use automations to react rapidly and make users feel heard.
## Preview
<DemoPreview template="Feedback Box" />
## Formbricks Approach
- Make it easy: 2 clicks to share feedback
@@ -49,81 +45,74 @@ If you don't have an account yet, create one at [app.formbricks.com](https://app
Then, create a new survey and look for the "Feedback Box" template:
<Image
<MdxImage
src={CreateFeedbackBox}
alt="Create feedback box by template"
quality="100"
className="rounded-lg max-w-full sm:max-w-3xl"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
### 2. Update question content
Change the questions and answer options according to your preference:
<Image
<MdxImage
src={ChangeTextContent}
alt="Change text content"
quality="100"
className="rounded-lg max-w-full sm:max-w-3xl"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
### 3. Create user action to trigger Feedback Box:
Go to the “Audience” tab, find the “When to send” card and choose “Add Action”. We will now use our super cool No-Code User Action Tracker:
<Image src={AddAction} alt="Add action" quality="100" className="rounded-lg max-w-full sm:max-w-3xl" />
<Note>
## You can also add actions in your code
You can also create [Code Actions](/docs/actions/code) using `formbricks.track("Eventname")` - they will automatically
appear in your Actions overview as long as the SDK is embedded.
</Note>
<MdxImage src={AddAction} alt="Add action" quality="100" className="max-w-full rounded-lg sm:max-w-3xl" />
We have two options to track the Feedback Button in your application: innerText and CSS-Selector:
1. **innerText:** This means that whenever a user clicks any HTML item in your app which has an `innerText` of `Feedback` the Feedback Box will be displayed.
2. **CSS-Selector:** This means that when an element with a specific CSS-Selector like `#feedback-button` is clicked, your Feedback Box is triggered.
<div className="grid grid-cols-2 space-x-2 max-w-full sm:max-w-3xl">
<Image src={AddHTMLAction} alt="Add HTML action" quality="100" className="rounded-lg" />
<Image src={AddCSSAction} alt="Add CSS action" quality="100" className="rounded-lg" />
<div className="grid max-w-full grid-cols-2 space-x-2 sm:max-w-3xl">
<MdxImage src={ActionText} alt="Add HTML action" quality="100" className="rounded-lg" />
<MdxImage src={ActionCSS} alt="Add CSS action" quality="100" className="rounded-lg" />
</div>
### 4. Select action in the “When to ask” card
<Image
<MdxImage
src={SelectAction}
alt="Select feedback button action"
quality="100"
className="rounded-lg max-w-full sm:max-w-3xl"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
### 5. Set Recontact Options correctly
Scroll down to “Recontact Options”. Here you have to choose the right settings so that the Feedback Box pops up every time the user action is performed. (Our default is that every user sees every survey only once):
<Image
<MdxImage
src={RecontactOptions}
alt="Set recontact options"
quality="100"
className="rounded-lg max-w-full sm:max-w-3xl"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
### 6. Youre ready publish your survey!
<Image
<MdxImage
src={PublishSurvey}
alt="Publish survey"
quality="100"
className="rounded-lg max-w-full sm:max-w-3xl"
className="max-w-full rounded-lg sm:max-w-3xl"
/>
## Setting up the Widget
<Note>
## Formbricks Widget running?
You need to have the Formbricks Widget installed to display the Feedback Box in your app. Please follow [this
tutorial (Step 4 onwards)](/docs/getting-started/quickstart-in-app-survey) to install the widget.
## Formbricks Widget running? You need to have the Formbricks Widget installed to display the Feedback Box
in your app. Please follow [this tutorial (Step 4 onwards)](/app-surveys/quickstart) to install the widget.
</Note>
### &nbsp;

Some files were not shown because too many files have changed in this diff Show More