Compare commits

...

2 Commits

Author SHA1 Message Date
Matthias Nannt
8459faed55 solve merge conflict 2025-06-18 13:44:14 +02:00
Piyush Jain
c4a32bce4f switch staging to internal lb 2025-05-26 19:39:34 +05:30
19 changed files with 47 additions and 52 deletions

View File

@@ -125,7 +125,7 @@ export const OnboardingSetupInstructions = ({
</div>
) : activeTab === "html" ? (
<div className="prose prose-slate">
<p className="-mb-1 mt-6 text-sm text-slate-700">
<p className="mt-6 -mb-1 text-sm text-slate-700">
{t("environments.connect.insert_this_code_into_the_head_tag_of_your_website")}
</p>
<div>

View File

@@ -46,7 +46,7 @@ const Page = async (props: ConnectPageProps) => {
channel={channel}
/>
<Button
className="absolute right-5 top-5 !mt-0 text-slate-500 hover:text-slate-700"
className="absolute top-5 right-5 !mt-0 text-slate-500 hover:text-slate-700"
variant="ghost"
asChild>
<Link href={`/environments/${environment.id}`}>

View File

@@ -266,7 +266,7 @@ export const MainNavigation = ({
size="icon"
onClick={toggleSidebar}
className={cn(
"rounded-xl bg-slate-50 p-1 text-slate-600 transition-all hover:bg-slate-100 focus:outline-none focus:ring-0 focus:ring-transparent"
"rounded-xl bg-slate-50 p-1 text-slate-600 transition-all hover:bg-slate-100 focus:ring-0 focus:ring-transparent focus:outline-none"
)}>
{isCollapsed ? (
<PanelLeftOpenIcon strokeWidth={1.5} />

View File

@@ -156,7 +156,7 @@ export const ShareEmbedSurvey = ({
<Badge
size="tiny"
type="success"
className="absolute right-3 top-3"
className="absolute top-3 right-3"
text={t("common.new")}
/>
</button>

View File

@@ -38,7 +38,7 @@ export const SummaryDropOffs = ({ dropOff, survey }: SummaryDropOffsProps) => {
</TooltipProvider>
</div>
<div className="px-4 text-right md:px-6">{t("environments.surveys.summary.impressions")}</div>
<div className="px-4 text-right md:mr-1 md:pl-6 md:pr-6">
<div className="px-4 text-right md:mr-1 md:pr-6 md:pl-6">
{t("environments.surveys.summary.drop_offs")}
</div>
</div>
@@ -63,10 +63,10 @@ export const SummaryDropOffs = ({ dropOff, survey }: SummaryDropOffsProps) => {
)}
</p>
</div>
<div className="whitespace-pre-wrap px-4 py-2 text-right font-mono font-medium md:px-6">
<div className="px-4 py-2 text-right font-mono font-medium whitespace-pre-wrap md:px-6">
{quesDropOff.ttc > 0 ? (quesDropOff.ttc / 1000).toFixed(2) + "s" : "N/A"}
</div>
<div className="whitespace-pre-wrap px-4 py-2 text-right font-mono font-medium md:px-6">
<div className="px-4 py-2 text-right font-mono font-medium whitespace-pre-wrap md:px-6">
{quesDropOff.impressions}
</div>
<div className="px-4 py-2 text-right md:px-6">

View File

@@ -87,7 +87,7 @@ export const ResultsShareButton = ({ survey, publicDomain }: ResultsShareButtonP
<DropdownMenuTrigger
asChild
className="focus:bg-muted cursor-pointer border border-slate-200 outline-none hover:border-slate-300">
<div className="min-w-auto h-auto rounded-md border bg-white p-3 sm:flex sm:min-w-[7rem] sm:px-6 sm:py-3">
<div className="h-auto min-w-auto rounded-md border bg-white p-3 sm:flex sm:min-w-[7rem] sm:px-6 sm:py-3">
<div className="hidden w-full items-center justify-between sm:flex">
<span className="text-sm text-slate-700">
{t("environments.surveys.summary.share_results")}

View File

@@ -63,7 +63,7 @@ export const SurveyStatusDropdown = ({
<>
{survey.status === "draft" ? (
<div className="flex items-center">
<p className="text-sm italic text-slate-600">{t("common.draft")}</p>
<p className="text-sm text-slate-600 italic">{t("common.draft")}</p>
</div>
) : (
<Select

View File

@@ -10,7 +10,7 @@ export const SignupWithoutVerificationSuccessPage = async ({ searchParams }) =>
return (
<FormWrapper>
<h1 className="leading-2 mb-4 text-center font-bold">
<h1 className="mb-4 text-center leading-2 font-bold">
{t("auth.signup_without_verification_success.user_successfully_created")}
</h1>
<p className="text-center text-sm">

View File

@@ -15,7 +15,7 @@ export const VerificationRequestedPage = async ({ searchParams }) => {
return (
<FormWrapper>
<>
<h1 className="leading-2 mb-4 text-center text-lg font-semibold text-slate-900">
<h1 className="mb-4 text-center text-lg leading-2 font-semibold text-slate-900">
{t("auth.verification-requested.please_confirm_your_email_address")}
</h1>
<p className="text-center text-sm text-slate-700">

View File

@@ -314,7 +314,7 @@ function AttributeSegmentFilter({
}}
value={attrKeyValue}>
<SelectTrigger
className="flex w-auto items-center justify-center whitespace-nowrap bg-white capitalize"
className="flex w-auto items-center justify-center bg-white whitespace-nowrap capitalize"
hideArrow>
<SelectValue>
<div className={cn("flex items-center gap-2", !isCapitalized(attrKeyValue ?? "") && "lowercase")}>
@@ -496,7 +496,7 @@ function PersonSegmentFilter({
}}
value={personIdentifier}>
<SelectTrigger
className="flex w-auto items-center justify-center whitespace-nowrap bg-white capitalize"
className="flex w-auto items-center justify-center bg-white whitespace-nowrap capitalize"
hideArrow>
<SelectValue>
<div className="flex items-center gap-1 lowercase">
@@ -647,7 +647,7 @@ function SegmentSegmentFilter({
}}
value={currentSegment?.id}>
<SelectTrigger
className="flex w-auto items-center justify-center whitespace-nowrap bg-white capitalize"
className="flex w-auto items-center justify-center bg-white whitespace-nowrap capitalize"
hideArrow>
<div className="flex items-center gap-1">
<Users2Icon className="h-4 w-4 text-sm" />

View File

@@ -232,7 +232,7 @@ export function EditLanguage({
))}
</>
) : (
<p className="text-sm italic text-slate-500">
<p className="text-sm text-slate-500 italic">
{t("environments.project.languages.no_language_found")}
</p>
)}

View File

@@ -60,11 +60,7 @@ const getRatingContent = (scale: string, i: number, range: number, isColorCoding
);
}
if (scale === "number") {
return (
<Text className="m-0 h-[44px] text-center text-[14px] leading-[44px]">
{i + 1}
</Text>
);
return <Text className="m-0 h-[44px] text-center text-[14px] leading-[44px]">{i + 1}</Text>;
}
if (scale === "star") {
return <Text className="m-auto text-3xl"></Text>;
@@ -98,8 +94,8 @@ export async function PreviewEmailTemplate({
case TSurveyQuestionTypeEnum.Consent:
return (
<EmailTemplateWrapper styling={styling} surveyUrl={url}>
<Text className="text-question-color m-0 block text-base font-semibold leading-6">{headline}</Text>
<Container className="text-question-color m-0 text-sm font-normal leading-6">
<Text className="text-question-color m-0 block text-base leading-6 font-semibold">{headline}</Text>
<Container className="text-question-color m-0 text-sm leading-6 font-normal">
<div
className="m-0 p-0"
dangerouslySetInnerHTML={{
@@ -185,8 +181,8 @@ export async function PreviewEmailTemplate({
case TSurveyQuestionTypeEnum.CTA:
return (
<EmailTemplateWrapper styling={styling} surveyUrl={url}>
<Text className="text-question-color m-0 block text-base font-semibold leading-6">{headline}</Text>
<Container className="text-question-color ml-0 mt-2 text-sm font-normal leading-6">
<Text className="text-question-color m-0 block text-base leading-6 font-semibold">{headline}</Text>
<Container className="text-question-color mt-2 ml-0 text-sm leading-6 font-normal">
<div
className="m-0 p-0"
dangerouslySetInnerHTML={{
@@ -232,8 +228,8 @@ export async function PreviewEmailTemplate({
{ "rounded-l-lg border-l": i === 0 },
{ "rounded-r-lg": i === firstQuestion.range - 1 },
firstQuestion.isColorCodingEnabled &&
firstQuestion.scale === "number" &&
`border border-t-[6px] border-t-${getRatingNumberOptionColor(firstQuestion.range, i + 1)}`,
firstQuestion.scale === "number" &&
`border border-t-[6px] border-t-${getRatingNumberOptionColor(firstQuestion.range, i + 1)}`,
firstQuestion.scale === "star" && "border-transparent"
)}
href={`${urlWithPrefilling}${firstQuestion.id}=${(i + 1).toString()}`}
@@ -325,13 +321,13 @@ export async function PreviewEmailTemplate({
{firstQuestion.choices.map((choice) =>
firstQuestion.allowMulti ? (
<Img
className="rounded-custom mb-1 mr-1 inline-block h-[140px] w-[220px]"
className="rounded-custom mr-1 mb-1 inline-block h-[140px] w-[220px]"
key={choice.id}
src={choice.imageUrl}
/>
) : (
<Link
className="rounded-custom mb-1 mr-1 inline-block h-[140px] w-[220px]"
className="rounded-custom mr-1 mb-1 inline-block h-[140px] w-[220px]"
href={`${urlWithPrefilling}${firstQuestion.id}=${choice.id}`}
key={choice.id}
target="_blank">
@@ -379,11 +375,11 @@ export async function PreviewEmailTemplate({
<Container className="mx-0">
<Section className="w-full table-auto">
<Row>
<Column className="w-40 break-words px-4 py-2" />
<Column className="w-40 px-4 py-2 break-words" />
{firstQuestion.columns.map((column) => {
return (
<Column
className="text-question-color max-w-40 break-words px-4 py-2 text-center"
className="text-question-color max-w-40 px-4 py-2 text-center break-words"
key={getLocalizedValue(column, "default")}>
{getLocalizedValue(column, "default")}
</Column>
@@ -395,7 +391,7 @@ export async function PreviewEmailTemplate({
<Row
className={`${rowIndex % 2 === 0 ? "bg-input-color" : ""} rounded-custom`}
key={getLocalizedValue(row, "default")}>
<Column className="w-40 break-words px-4 py-2">
<Column className="w-40 px-4 py-2 break-words">
{getLocalizedValue(row, "default")}
</Column>
{firstQuestion.columns.map((_) => {

View File

@@ -220,7 +220,7 @@ export const RecallWrapper = ({
}
parts.push(
<span
className="z-30 flex h-fit cursor-pointer justify-center whitespace-pre rounded-md bg-slate-100 text-sm text-transparent"
className="z-30 flex h-fit cursor-pointer justify-center rounded-md bg-slate-100 text-sm whitespace-pre text-transparent"
key={`recall-${parts.length}`}>
{"@" + label}
</span>
@@ -255,7 +255,7 @@ export const RecallWrapper = ({
<Button
variant="ghost"
type="button"
className="absolute right-2 top-full z-[1] flex h-6 cursor-pointer items-center rounded-b-lg rounded-t-none bg-slate-100 px-2.5 py-0 text-xs hover:bg-slate-200"
className="absolute top-full right-2 z-[1] flex h-6 cursor-pointer items-center rounded-t-none rounded-b-lg bg-slate-100 px-2.5 py-0 text-xs hover:bg-slate-200"
onClick={(e) => {
e.preventDefault();
setShowFallbackInput(true);

View File

@@ -82,7 +82,7 @@ export const LinkSurveyWrapper = ({
{!styling.isLogoHidden && project.logo?.url && <ClientLogo projectLogo={project.logo} />}
<div className="h-full w-full max-w-4xl space-y-6 px-1.5">
{isPreview && (
<div className="fixed left-0 top-0 flex w-full items-center justify-between bg-slate-600 p-2 px-4 text-center text-sm text-white shadow-sm">
<div className="fixed top-0 left-0 flex w-full items-center justify-between bg-slate-600 p-2 px-4 text-center text-sm text-white shadow-sm">
<div />
Survey Preview 👀
<ResetProgressButton onClick={handleResetSurvey} />

View File

@@ -31,7 +31,7 @@ vi.mock("@/modules/ui/components/checkbox", () => ({
id={id}
data-testid={id}
name={props.name}
className="mr-2 h-4 w-4 appearance-none border-slate-300 checked:border-transparent checked:bg-slate-500 checked:after:bg-slate-500 checked:hover:bg-slate-500 focus:ring-2 focus:ring-slate-500 focus:ring-opacity-50"
className="focus:ring-opacity-50 mr-2 h-4 w-4 appearance-none border-slate-300 checked:border-transparent checked:bg-slate-500 checked:after:bg-slate-500 checked:hover:bg-slate-500 focus:ring-2 focus:ring-slate-500"
onChange={(e) => {
// Call onCheckedChange with the checked state
onCheckedChange && onCheckedChange(e.target.checked);

View File

@@ -105,11 +105,11 @@ export const CopySurveyForm = ({ defaultProjects, survey, onCancel, setOpen }: I
field.onChange([...field.value, environment.id]);
}
}}
className="mr-2 h-4 w-4 appearance-none border-slate-300 checked:border-transparent checked:bg-slate-500 checked:after:bg-slate-500 checked:hover:bg-slate-500 focus:ring-2 focus:ring-slate-500 focus:ring-opacity-50"
className="focus:ring-opacity-50 mr-2 h-4 w-4 appearance-none border-slate-300 checked:border-transparent checked:bg-slate-500 checked:after:bg-slate-500 checked:hover:bg-slate-500 focus:ring-2 focus:ring-slate-500"
id={environment.id}
/>
<Label htmlFor={environment.id}>
<p className="text-sm font-medium capitalize text-slate-900">
<p className="text-sm font-medium text-slate-900 capitalize">
{environment.type}
</p>
</Label>
@@ -128,8 +128,8 @@ export const CopySurveyForm = ({ defaultProjects, survey, onCancel, setOpen }: I
);
})}
</div>
<div className="fixed bottom-0 left-0 right-0 z-10 flex w-full justify-end space-x-2 bg-white">
<div className="flex w-full justify-end pb-4 pr-4">
<div className="fixed right-0 bottom-0 left-0 z-10 flex w-full justify-end space-x-2 bg-white">
<div className="flex w-full justify-end pr-4 pb-4">
<Button type="button" onClick={onCancel} variant="ghost">
{t("common.cancel")}
</Button>

View File

@@ -72,7 +72,7 @@ export const SurveyCard = ({
</div>
<div
className={cn(
"col-span-1 flex w-fit items-center gap-2 whitespace-nowrap rounded-full py-1 pl-1 pr-2 text-sm text-slate-800",
"col-span-1 flex w-fit items-center gap-2 rounded-full py-1 pr-2 pl-1 text-sm whitespace-nowrap text-slate-800",
surveyStatusLabel === "Scheduled" && "bg-slate-200",
surveyStatusLabel === "In Progress" && "bg-emerald-50",
surveyStatusLabel === "Completed" && "bg-slate-200",
@@ -81,23 +81,23 @@ export const SurveyCard = ({
)}>
<SurveyStatusIndicator status={survey.status} /> {surveyStatusLabel}{" "}
</div>
<div className="col-span-1 max-w-full overflow-hidden text-ellipsis whitespace-nowrap text-sm text-slate-600">
<div className="col-span-1 max-w-full overflow-hidden text-sm text-ellipsis whitespace-nowrap text-slate-600">
{survey.responseCount}
</div>
<div className="col-span-1 flex justify-between">
<SurveyTypeIndicator type={survey.type} />
</div>
<div className="col-span-1 max-w-full overflow-hidden text-ellipsis whitespace-nowrap text-sm text-slate-600">
<div className="col-span-1 max-w-full overflow-hidden text-sm text-ellipsis whitespace-nowrap text-slate-600">
{convertDateString(survey.createdAt.toString())}
</div>
<div className="col-span-1 max-w-full overflow-hidden text-ellipsis whitespace-nowrap text-sm text-slate-600">
<div className="col-span-1 max-w-full overflow-hidden text-sm text-ellipsis whitespace-nowrap text-slate-600">
{timeSince(survey.updatedAt.toString(), locale)}
</div>
<div className="col-span-1 max-w-full overflow-hidden text-ellipsis whitespace-nowrap text-sm text-slate-600">
<div className="col-span-1 max-w-full overflow-hidden text-sm text-ellipsis whitespace-nowrap text-slate-600">
{survey.creator ? survey.creator.name : "-"}
</div>
</div>
<button className="absolute right-3 top-3.5" onClick={(e) => e.stopPropagation()}>
<button className="absolute top-3.5 right-3" onClick={(e) => e.stopPropagation()}>
<SurveyDropDownMenu
survey={survey}
key={`surveys-${survey.id}`}

View File

@@ -132,10 +132,9 @@ externalSecret:
ingress:
annotations:
alb.ingress.kubernetes.io/certificate-arn: {{ requiredEnv "FORMBRICKS_INGRESS_CERT_ARN" }}
alb.ingress.kubernetes.io/group.name: formbricks-stage
alb.ingress.kubernetes.io/group.name: internal
alb.ingress.kubernetes.io/healthcheck-path: /health
alb.ingress.kubernetes.io/listen-ports: '[{"HTTP": 80}, {"HTTPS": 443}]'
alb.ingress.kubernetes.io/scheme: internet-facing
alb.ingress.kubernetes.io/ssl-policy: ELBSecurityPolicy-TLS13-1-2-Res-2021-06
alb.ingress.kubernetes.io/ssl-redirect: "443"
alb.ingress.kubernetes.io/target-type: ip

View File

@@ -189,7 +189,7 @@ export function RankingQuestion({
handleItemClick(item);
}}
type="button"
aria-label={`Select ${getLocalizedValue(item.label,languageCode)} for ranking`}
aria-label={`Select ${getLocalizedValue(item.label, languageCode)} for ranking`}
className="fb-flex fb-gap-x-4 fb-px-4 fb-items-center fb-grow fb-h-full group text-left focus:outline-none">
<span
className={cn(
@@ -207,13 +207,13 @@ export function RankingQuestion({
{isSorted ? (
<div className="fb-flex fb-flex-col fb-h-full fb-grow-0 fb-border-l fb-border-border">
<button
tabIndex={isFirst?-1:0}
tabIndex={isFirst ? -1 : 0}
type="button"
onClick={(e) => {
e.preventDefault();
handleMove(item.id, "up");
}}
aria-label={`Move ${getLocalizedValue(item.label,languageCode)} up`}
aria-label={`Move ${getLocalizedValue(item.label, languageCode)} up`}
className={cn(
"fb-px-2 fb-flex fb-flex-1 fb-items-center fb-justify-center",
isFirst
@@ -236,7 +236,7 @@ export function RankingQuestion({
</svg>
</button>
<button
tabIndex={isLast?-1:0}
tabIndex={isLast ? -1 : 0}
type="button"
onClick={(e) => {
e.preventDefault();
@@ -248,7 +248,7 @@ export function RankingQuestion({
? "fb-opacity-30 fb-cursor-not-allowed"
: "hover:fb-bg-black/5 fb-rounded-br-custom fb-transition-colors"
)}
aria-label={`Move ${getLocalizedValue(item.label,languageCode)} down`}
aria-label={`Move ${getLocalizedValue(item.label, languageCode)} down`}
disabled={isLast}>
<svg
xmlns="http://www.w3.org/2000/svg"