From 7bcc5c454866431830941b79039432f66507a7ad Mon Sep 17 00:00:00 2001 From: zomars Date: Tue, 12 Jul 2022 11:50:04 -0600 Subject: [PATCH] eslint react/jsx-curly-brace-presence --- .../components/AdditionalCalendarSelector.tsx | 2 +- .../components/DestinationCalendarSelector.tsx | 2 +- apps/web/components/Embed.tsx | 2 +- apps/web/components/auth/SAMLLogin.tsx | 2 +- apps/web/components/booking/AvailableTimes.tsx | 2 +- .../web/components/dialog/EditLocationDialog.tsx | 6 +++--- apps/web/components/team/TeamSettings.tsx | 4 ++-- .../components/team/TeamSettingsRightSidebar.tsx | 2 +- .../team/UpgradeToFlexibleProModal.tsx | 2 +- .../ui/UsernameAvailability/PremiumTextfield.tsx | 12 ++++++------ .../UsernameAvailability/UsernameTextfield.tsx | 10 +++++----- .../components/webhook/WebhookTestDisclosure.tsx | 2 +- apps/web/ee/components/saml/Configuration.tsx | 2 +- apps/web/pages/apps/[slug]/index.tsx | 4 ++-- apps/web/pages/auth/login.tsx | 2 +- apps/web/pages/event-types/[type].tsx | 16 +++++++--------- apps/web/pages/settings/billing.tsx | 4 ++-- apps/web/pages/settings/profile.tsx | 4 +--- apps/web/pages/success.tsx | 2 +- apps/web/pages/video/meeting-ended/[uid].tsx | 2 +- .../pages/video/meeting-not-started/[uid].tsx | 2 +- .../giphy/components/SelectGifInput.tsx | 2 +- .../vital/components/AppConfiguration.tsx | 6 ++---- .../wipemycalother/components/confirmDialog.tsx | 2 +- packages/app-store/zapier/pages/setup/index.tsx | 4 ++-- packages/config/eslint-preset.js | 1 + packages/emails/src/components/BaseEmailHtml.tsx | 8 ++++---- packages/emails/src/components/EmailBodyLogo.tsx | 2 +- .../emails/src/components/EmailCommonDivider.tsx | 2 +- packages/emails/src/components/EmailHead.tsx | 4 +--- packages/ui/Dropdown.tsx | 2 +- packages/ui/Switch.tsx | 2 +- 32 files changed, 57 insertions(+), 64 deletions(-) diff --git a/apps/web/components/AdditionalCalendarSelector.tsx b/apps/web/components/AdditionalCalendarSelector.tsx index 4a19957229..192aff0df2 100644 --- a/apps/web/components/AdditionalCalendarSelector.tsx +++ b/apps/web/components/AdditionalCalendarSelector.tsx @@ -50,7 +50,7 @@ const AdditionalCalendarSelector = ({ isLoading }: AdditionalCalendarSelectorPro })); return ( openEmbedModal()}> diff --git a/apps/web/components/auth/SAMLLogin.tsx b/apps/web/components/auth/SAMLLogin.tsx index 8ada1fa96e..76f7c75c8c 100644 --- a/apps/web/components/auth/SAMLLogin.tsx +++ b/apps/web/components/auth/SAMLLogin.tsx @@ -34,7 +34,7 @@ export default function SAMLLogin(props: Props) {
) : ( diff --git a/apps/web/components/dialog/EditLocationDialog.tsx b/apps/web/components/dialog/EditLocationDialog.tsx index 5823a59f8e..a17bbc6d45 100644 --- a/apps/web/components/dialog/EditLocationDialog.tsx +++ b/apps/web/components/dialog/EditLocationDialog.tsx @@ -245,7 +245,7 @@ export const EditLocationDialog = (props: ISetLocationDialog) => { id="wherebylink" placeholder="https://www.whereby.com/cal" required - className={"block w-full rounded-sm border-gray-300 text-sm"} + className="block w-full rounded-sm border-gray-300 text-sm" defaultValue={ defaultValues ? defaultValues.find( @@ -292,7 +292,7 @@ export const EditLocationDialog = (props: ISetLocationDialog) => { id="aroundlink" placeholder="https://www.around.co/rick" required - className={"block w-full rounded-sm border-gray-300 text-sm"} + className="block w-full rounded-sm border-gray-300 text-sm" defaultValue={ defaultValues ? defaultValues.find( @@ -339,7 +339,7 @@ export const EditLocationDialog = (props: ISetLocationDialog) => { id="aroundlink" placeholder="https://www.riverside.fm/studio/rick" required - className={"block w-full rounded-sm border-gray-300 text-sm"} + className="block w-full rounded-sm border-gray-300 text-sm" defaultValue={ defaultValues ? defaultValues.find( diff --git a/apps/web/components/team/TeamSettings.tsx b/apps/web/components/team/TeamSettings.tsx index 17829892a7..1410660d2c 100644 --- a/apps/web/components/team/TeamSettings.tsx +++ b/apps/web/components/team/TeamSettings.tsx @@ -92,7 +92,7 @@ export default function TeamSettings(props: Props) { id="team-url" addOnLeading={ - {process.env.NEXT_PUBLIC_WEBSITE_URL}/{"team/"} + {process.env.NEXT_PUBLIC_WEBSITE_URL}/team/ } ref={teamUrlRef} @@ -140,7 +140,7 @@ export default function TeamSettings(props: Props) {
diff --git a/apps/web/components/team/TeamSettingsRightSidebar.tsx b/apps/web/components/team/TeamSettingsRightSidebar.tsx index 57aaffe15b..e4c857f595 100644 --- a/apps/web/components/team/TeamSettingsRightSidebar.tsx +++ b/apps/web/components/team/TeamSettingsRightSidebar.tsx @@ -120,7 +120,7 @@ export default function TeamSettingsRightSidebar(props: { team: TeamWithMembers; {props.team?.id && props.role !== MembershipRole.MEMBER && (
- {"View Availability"} + View Availability

See your team members availability at a glance.

diff --git a/apps/web/components/team/UpgradeToFlexibleProModal.tsx b/apps/web/components/team/UpgradeToFlexibleProModal.tsx index f963274fc5..19ec8d3925 100644 --- a/apps/web/components/team/UpgradeToFlexibleProModal.tsx +++ b/apps/web/components/team/UpgradeToFlexibleProModal.tsx @@ -50,7 +50,7 @@ export function UpgradeToFlexibleProModal(props: Props) { setErrorMessage(null); }}> - {"Upgrade Now"} + Upgrade Now diff --git a/apps/web/components/ui/UsernameAvailability/PremiumTextfield.tsx b/apps/web/components/ui/UsernameAvailability/PremiumTextfield.tsx index 5b75d96063..938b9a8f96 100644 --- a/apps/web/components/ui/UsernameAvailability/PremiumTextfield.tsx +++ b/apps/web/components/ui/UsernameAvailability/PremiumTextfield.tsx @@ -181,7 +181,7 @@ const PremiumTextfield = (props: ICustomUsernameProps) => { return ( <>
- +
{
{
- + {usernameChangeCondition && usernameChangeCondition !== UsernameChangeStatusEnum.NORMAL && (

{usernameChangeCondition === UsernameChangeStatusEnum.UPGRADE && diff --git a/apps/web/components/ui/UsernameAvailability/UsernameTextfield.tsx b/apps/web/components/ui/UsernameAvailability/UsernameTextfield.tsx index fd887e7d5a..a75de8b515 100644 --- a/apps/web/components/ui/UsernameAvailability/UsernameTextfield.tsx +++ b/apps/web/components/ui/UsernameAvailability/UsernameTextfield.tsx @@ -107,7 +107,7 @@ const UsernameTextfield = (props: ICustomUsernameProps) => { return ( <>

- +
{
setOpen(!open)}> - + {t("webhook_test")} diff --git a/apps/web/ee/components/saml/Configuration.tsx b/apps/web/ee/components/saml/Configuration.tsx index ee4dc96311..7778b647da 100644 --- a/apps/web/ee/components/saml/Configuration.tsx +++ b/apps/web/ee/components/saml/Configuration.tsx @@ -104,7 +104,7 @@ export default function SAMLConfiguration({ {samlConfig ? ( <> - + {samlConfig ? samlConfig : ""} diff --git a/apps/web/pages/apps/[slug]/index.tsx b/apps/web/pages/apps/[slug]/index.tsx index ab8f67010d..62bb5e2c27 100644 --- a/apps/web/pages/apps/[slug]/index.tsx +++ b/apps/web/pages/apps/[slug]/index.tsx @@ -42,7 +42,7 @@ const components = { loading="eager" layout="fixed" objectFit="contain" - objectPosition={"center center"} + objectPosition="center center" width={573} height={382} /> @@ -52,7 +52,7 @@ const components = { alt="" layout="responsive" objectFit="contain" - objectPosition={"center center"} + objectPosition="center center" width={573} height={382} /> diff --git a/apps/web/pages/auth/login.tsx b/apps/web/pages/auth/login.tsx index baf48621c8..1558bbbaa3 100644 --- a/apps/web/pages/auth/login.tsx +++ b/apps/web/pages/auth/login.tsx @@ -175,7 +175,7 @@ export default function Login({
- { - - } +
diff --git a/apps/web/pages/settings/billing.tsx b/apps/web/pages/settings/billing.tsx index 98895ad305..9b2ff2cef2 100644 --- a/apps/web/pages/settings/billing.tsx +++ b/apps/web/pages/settings/billing.tsx @@ -44,7 +44,7 @@ export default function Billing() { title={t("plan_description", { plan: data.plan })} description={t("plan_upgrade_invitation")} className="mb-4"> -
+ @@ -53,7 +53,7 @@ export default function Billing() { )} - + diff --git a/apps/web/pages/settings/profile.tsx b/apps/web/pages/settings/profile.tsx index a5d711c565..824dfc3ac3 100644 --- a/apps/web/pages/settings/profile.tsx +++ b/apps/web/pages/settings/profile.tsx @@ -51,9 +51,7 @@ function HideBrandingInput(props: { hideBrandingRef: RefObject type="checkbox" ref={props.hideBrandingRef} defaultChecked={isBrandingHidden(user)} - className={ - "h-4 w-4 rounded-sm border-gray-300 text-neutral-900 focus:ring-neutral-800 disabled:opacity-50" - } + className="h-4 w-4 rounded-sm border-gray-300 text-neutral-900 focus:ring-neutral-800 disabled:opacity-50" onClick={(e) => { if (!e.currentTarget.checked || user.plan !== "FREE") { return; diff --git a/apps/web/pages/success.tsx b/apps/web/pages/success.tsx index e2c8a967e2..ad55ee383c 100644 --- a/apps/web/pages/success.tsx +++ b/apps/web/pages/success.tsx @@ -302,7 +302,7 @@ export default function Success(props: SuccessProps) { )}> {giphyImage && !needsConfirmation && ( // eslint-disable-next-line @next/next/no-img-element - {"Gif + Gif from Giphy )} {!giphyImage && !needsConfirmation && !isCancelled && ( diff --git a/apps/web/pages/video/meeting-ended/[uid].tsx b/apps/web/pages/video/meeting-ended/[uid].tsx index 4b05a5bc1e..163e1b7c7d 100644 --- a/apps/web/pages/video/meeting-ended/[uid].tsx +++ b/apps/web/pages/video/meeting-ended/[uid].tsx @@ -26,7 +26,7 @@ export default function MeetingUnavailable(props: inferSSRProps - +
diff --git a/apps/web/pages/video/meeting-not-started/[uid].tsx b/apps/web/pages/video/meeting-not-started/[uid].tsx index 4fcbb5a12c..a790a5ad4a 100644 --- a/apps/web/pages/video/meeting-not-started/[uid].tsx +++ b/apps/web/pages/video/meeting-not-started/[uid].tsx @@ -27,7 +27,7 @@ export default function MeetingNotStarted(props: inferSSRProps - +
diff --git a/packages/app-store/giphy/components/SelectGifInput.tsx b/packages/app-store/giphy/components/SelectGifInput.tsx index 739aa1f00e..199571a51c 100644 --- a/packages/app-store/giphy/components/SelectGifInput.tsx +++ b/packages/app-store/giphy/components/SelectGifInput.tsx @@ -19,7 +19,7 @@ export default function SelectGifInput(props: ISelectGifInput) {
{selectedGif && (
- {"Selected + Selected Gif Image
)}
diff --git a/packages/app-store/vital/components/AppConfiguration.tsx b/packages/app-store/vital/components/AppConfiguration.tsx index c1a9ca1b0f..4b89bc8ed9 100644 --- a/packages/app-store/vital/components/AppConfiguration.tsx +++ b/packages/app-store/vital/components/AppConfiguration.tsx @@ -129,7 +129,7 @@ const AppConfiguration = (props: IAppConfigurationProps) => { {t("vital_app_trigger", { ns: "vital" })}
-
+
{ setSleepValue(Number(e.currentTarget.value)); setTouchedForm(true); }} - className={ - "pr-12shadow-sm mt-1 block w-full rounded-sm border border-gray-300 py-2 pl-6 focus:border-neutral-500 focus:outline-none focus:ring-neutral-500 sm:text-sm" - } + className="pr-12shadow-sm mt-1 block w-full rounded-sm border border-gray-300 py-2 pl-6 focus:border-neutral-500 focus:outline-none focus:ring-neutral-500 sm:text-sm" />

{t("vital_app_hours", { ns: "vital" })} diff --git a/packages/app-store/wipemycalother/components/confirmDialog.tsx b/packages/app-store/wipemycalother/components/confirmDialog.tsx index f5b6d46411..57abb22b1d 100644 --- a/packages/app-store/wipemycalother/components/confirmDialog.tsx +++ b/packages/app-store/wipemycalother/components/confirmDialog.tsx @@ -87,7 +87,7 @@ export const ConfirmDialog = (props: IConfirmDialogWipe) => {

- +

This will cancel all upcoming meetings from:
{" "} diff --git a/packages/app-store/zapier/pages/setup/index.tsx b/packages/app-store/zapier/pages/setup/index.tsx index 05c47484a1..bb309a41e0 100644 --- a/packages/app-store/zapier/pages/setup/index.tsx +++ b/packages/app-store/zapier/pages/setup/index.tsx @@ -111,7 +111,7 @@ export default function ZapierSetup(props: IZapierSetupProps) {

  • You're set!
  • - +
    @@ -121,7 +121,7 @@ export default function ZapierSetup(props: IZapierSetupProps) {
    {t("install_zapier_app")}
    - +
    diff --git a/packages/config/eslint-preset.js b/packages/config/eslint-preset.js index 72950a9848..95a4fda02f 100644 --- a/packages/config/eslint-preset.js +++ b/packages/config/eslint-preset.js @@ -16,6 +16,7 @@ module.exports = { "@next/next/no-img-element": "off", "@next/next/no-html-link-for-pages": "off", "jsx-a11y/role-supports-aria-props": "off", // @see https://github.com/vercel/next.js/issues/27989#issuecomment-897638654 + "react/jsx-curly-brace-presence": ["error", { props: "never", children: "never" }], }, overrides: [ { diff --git a/packages/emails/src/components/BaseEmailHtml.tsx b/packages/emails/src/components/BaseEmailHtml.tsx index 80f0424e0b..e7f4c86b49 100644 --- a/packages/emails/src/components/BaseEmailHtml.tsx +++ b/packages/emails/src/components/BaseEmailHtml.tsx @@ -10,7 +10,7 @@ import Row from "./Row"; const Html = (props: { children: React.ReactNode }) => ( <> - `} /> + {props.children} ); @@ -103,7 +103,7 @@ export const BaseEmailHtml = (props: {
    - `} /> +
    @@ -175,12 +175,12 @@ export const BaseEmailHtml = (props: {
    )} - `} /> +
    - `} /> +
    diff --git a/packages/emails/src/components/EmailBodyLogo.tsx b/packages/emails/src/components/EmailBodyLogo.tsx index 0cd38e2a3b..277937f6e9 100644 --- a/packages/emails/src/components/EmailBodyLogo.tsx +++ b/packages/emails/src/components/EmailBodyLogo.tsx @@ -70,7 +70,7 @@ const EmailBodyLogo = () => {
    - `} /> +
    diff --git a/packages/emails/src/components/EmailCommonDivider.tsx b/packages/emails/src/components/EmailCommonDivider.tsx index 38a1f98535..31a97553d1 100644 --- a/packages/emails/src/components/EmailCommonDivider.tsx +++ b/packages/emails/src/components/EmailCommonDivider.tsx @@ -60,7 +60,7 @@ const EmailCommonDivider = ({ {children}
    - `} /> +
    diff --git a/packages/emails/src/components/EmailHead.tsx b/packages/emails/src/components/EmailHead.tsx index 484fa0031b..631f3fc6fe 100644 --- a/packages/emails/src/components/EmailHead.tsx +++ b/packages/emails/src/components/EmailHead.tsx @@ -45,9 +45,7 @@ const EmailHead = ({ title = "" }) => { } `} - `} - /> + `} /> diff --git a/packages/ui/Dropdown.tsx b/packages/ui/Dropdown.tsx index 0fec9801f0..476a1c9082 100644 --- a/packages/ui/Dropdown.tsx +++ b/packages/ui/Dropdown.tsx @@ -29,7 +29,7 @@ export const DropdownMenuContent = forwardRef {children} diff --git a/packages/ui/Switch.tsx b/packages/ui/Switch.tsx index 2704fe64e8..77cf1ef722 100644 --- a/packages/ui/Switch.tsx +++ b/packages/ui/Switch.tsx @@ -16,7 +16,7 @@ const Switch = ( {label && (