Skip to content

Commit

Permalink
fix(eslint-plugin): formating
Browse files Browse the repository at this point in the history
  • Loading branch information
gabrielmfern committed Dec 18, 2023
1 parent 12f22ae commit c478a17
Show file tree
Hide file tree
Showing 136 changed files with 646 additions and 590 deletions.
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
dist/
caniemail
11 changes: 5 additions & 6 deletions packages/eslint-plugin/codegen/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
## What is this?

This is a folder used to generate the eslint rules based on the metadata on the markdown
This is a folder used to generate the eslint rules based on the metadata on the markdown
for each specific possible feature of email templates.

> [!NOTE]
Expand All @@ -9,9 +9,9 @@ for each specific possible feature of email templates.
## How can I run this?

### 1. Clone caniemail
### 1. Clone caniemail

Before you run, you might have cloned the React Email repository without the
Before you run, you might have cloned the React Email repository without the
caniemail submodule here so you will need to run:

```sh
Expand All @@ -26,7 +26,7 @@ pnpm generate-rules

## What is this `manual-changes.patch`?

Every time the codegen runs it will try to generate the rules based on guesses of
Every time the codegen runs it will try to generate the rules based on guesses of
what type of rule they are supposed to be. Lots of times this guess will fail
and this is the way we are currently using to apply the changes and keep track
of them in a good way.
Expand All @@ -36,5 +36,4 @@ of them in a good way.
Currently the way we are using for modifying it is to open it up manually and add
the changes we need to the `manual-changes.patch` this may not be the best way
for changing it so if you have any better ideas about this please open a issue, PR or discussion
for us to talk about it.

for us to talk about it.
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ export async function generateNoUnsupportedStyleRules() {
`import { createNoStylePropertyRule } from "../../utils/create-no-style-property-rule";
export default createNoStylePropertyRule(
'${cssFeatureName}',
"${cssFeatureName}",
${supportPercetange * 100},
'https://www.caniemail.com/features/${featureNamePrefixed}/'
"https://www.caniemail.com/features/${featureNamePrefixed}/"
);
`,
);
Expand All @@ -34,9 +34,9 @@ export default createNoStylePropertyRule(
`import { createNoStyleValueKeywordRule } from "../../utils/create-no-style-value-keyword-rule";
export default createNoStyleValueKeywordRule(
'${cssFeatureName}',
"${cssFeatureName}",
${supportPercetange * 100},
'https://www.caniemail.com/features/${featureNamePrefixed}/'
"https://www.caniemail.com/features/${featureNamePrefixed}/"
);
`,
);
Expand Down
2 changes: 1 addition & 1 deletion packages/eslint-plugin/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ plugins: ['@react-email'],
extends: ['plugin:@react-email/recommended']
```

Activating or deactivating certain rules as you may prefer. These rules are mostly generated
Activating or deactivating certain rules as you may prefer. These rules are mostly generated
with metadata taken from [caniemail](https://www.caniemail.com/).

### 2. Run eslint
Expand Down
2 changes: 1 addition & 1 deletion packages/eslint-plugin/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ const rules: ESLint.Plugin["rules"] = {
};

const recommendedRules: Partial<Linter.RulesRecord> = {
"react/jsx-key": "off"
"react/jsx-key": "off",
};

for (const ruleName of Object.keys(rules)) {
Expand Down
250 changes: 125 additions & 125 deletions packages/eslint-plugin/src/rules/generated/index.ts
Original file line number Diff line number Diff line change
@@ -1,127 +1,127 @@
import noHtmlWbr from './no-html-wbr';
import noHtmlVideo from './no-html-video';
import noHtmlTextarea from './no-html-textarea';
import noHtmlTarget from './no-html-target';
import noHtmlSvg from './no-html-svg';
import noHtmlSrcset from './no-html-srcset';
import noHtmlSemantics from './no-html-semantics';
import noHtmlSelect from './no-html-select';
import noHtmlRuby from './no-html-ruby';
import noHtmlRt from './no-html-rt';
import noHtmlRp from './no-html-rp';
import noHtmlRole from './no-html-role';
import noHtmlRequired from './no-html-required';
import noHtmlProgress from './no-html-progress';
import noHtmlPicture from './no-html-picture';
import noHtmlObject from './no-html-object';
import noHtmlMeter from './no-html-meter';
import noHtmlMarquee from './no-html-marquee';
import noHtmlLoadingAttribute from './no-html-loading-attribute';
import noHtmlLink from './no-html-link';
import noHtmlLang from './no-html-lang';
import noHtmlInputText from './no-html-input-text';
import noHtmlInputSubmit from './no-html-input-submit';
import noHtmlInputReset from './no-html-input-reset';
import noHtmlInputRadio from './no-html-input-radio';
import noHtmlInputHidden from './no-html-input-hidden';
import noHtmlInputCheckbox from './no-html-input-checkbox';
import noHtmlForm from './no-html-form';
import noHtmlDoctype from './no-html-doctype';
import noHtmlDialog from './no-html-dialog';
import noHtmlDfn from './no-html-dfn';
import noHtmlButtonSubmit from './no-html-button-submit';
import noHtmlButtonReset from './no-html-button-reset';
import noHtmlBody from './no-html-body';
import noHtmlBdi from './no-html-bdi';
import noHtmlBase from './no-html-base';
import noHtmlAudio from './no-html-audio';
import noHtmlAriaLive from './no-html-aria-live';
import noHtmlAriaLabelledby from './no-html-aria-labelledby';
import noHtmlAriaLabel from './no-html-aria-label';
import noHtmlAriaHidden from './no-html-aria-hidden';
import noHtmlAriaDescribedby from './no-html-aria-describedby';
import noHtmlAnchorLinks from './no-html-anchor-links';
import noHtmlAbbr from './no-html-abbr';
import noCssWritingMode from './no-css-writing-mode';
import noCssWordBreak from './no-css-word-break';
import noCssVisibility from './no-css-visibility';
import noCssUnitVmin from './no-css-unit-vmin';
import noCssUnitVmax from './no-css-unit-vmax';
import noCssUnitVh from './no-css-unit-vh';
import noCssUnitRem from './no-css-unit-rem';
import noCssUnitInitial from './no-css-unit-initial';
import noCssUnitCh from './no-css-unit-ch';
import noCssUnitCalc from './no-css-unit-calc';
import noCssTransform from './no-css-transform';
import noCssTextUnderlineOffset from './no-css-text-underline-offset';
import noCssTextShadow from './no-css-text-shadow';
import noCssTextOverflow from './no-css-text-overflow';
import noCssTextEmphasis from './no-css-text-emphasis';
import noCssTextEmphasisPosition from './no-css-text-emphasis-position';
import noCssTextDecorationThickness from './no-css-text-decoration-thickness';
import noCssTextDecorationColor from './no-css-text-decoration-color';
import noCssTextAlignLast from './no-css-text-align-last';
import noCssTableLayout from './no-css-table-layout';
import noCssTabSize from './no-css-tab-size';
import noCssScrollSnap from './no-css-scroll-snap';
import noCssRgba from './no-css-rgba';
import noCssRadialGradient from './no-css-radial-gradient';
import noCssPosition from './no-css-position';
import noCssPaddingInlineStartEnd from './no-css-padding-inline-start-end';
import noCssPaddingInlineBlock from './no-css-padding-inline-block';
import noCssPaddingBlockStartEnd from './no-css-padding-block-start-end';
import noCssOverflowWrap from './no-css-overflow-wrap';
import noCssOutlineOffset from './no-css-outline-offset';
import noCssOpacity from './no-css-opacity';
import noCssObjectPosition from './no-css-object-position';
import noCssObjectFit from './no-css-object-fit';
import noCssModernColor from './no-css-modern-color';
import noCssMixBlendMode from './no-css-mix-blend-mode';
import noCssMinInlineSize from './no-css-min-inline-size';
import noCssMaxBlockSize from './no-css-max-block-size';
import noCssMarginInline from './no-css-margin-inline';
import noCssMarginInlineStartEnd from './no-css-margin-inline-start-end';
import noCssMarginInlineBlock from './no-css-margin-inline-block';
import noCssMarginBlockStartEnd from './no-css-margin-block-start-end';
import noCssListStyleImage from './no-css-list-style-image';
import noCssLinearGradient from './no-css-linear-gradient';
import noCssLeftRightTopBottom from './no-css-left-right-top-bottom';
import noCssJustifyContent from './no-css-justify-content';
import noCssIntrinsicSize from './no-css-intrinsic-size';
import noCssImportant from './no-css-important';
import noCssHyphens from './no-css-hyphens';
import noCssGridTemplate from './no-css-grid-template';
import noCssGap from './no-css-gap';
import noCssFunctionMin from './no-css-function-min';
import noCssFunctionMax from './no-css-function-max';
import noCssFunctionClamp from './no-css-function-clamp';
import noCssFontKerning from './no-css-font-kerning';
import noCssFlexWrap from './no-css-flex-wrap';
import noCssFlexDirection from './no-css-flex-direction';
import noCssFilter from './no-css-filter';
import noCssDisplayGrid from './no-css-display-grid';
import noCssDisplayFlex from './no-css-display-flex';
import noCssConicGradient from './no-css-conic-gradient';
import noCssColumnLayoutProperties from './no-css-column-layout-properties';
import noCssColumnCount from './no-css-column-count';
import noCssClipPath from './no-css-clip-path';
import noCssBoxSizing from './no-css-box-sizing';
import noCssBoxShadow from './no-css-box-shadow';
import noCssBorderRadius from './no-css-border-radius';
import noCssBorderRadiusLogical from './no-css-border-radius-logical';
import noCssBorderInlineBlock from './no-css-border-inline-block';
import noCssBorderInlineBlockLonghand from './no-css-border-inline-block-longhand';
import noCssBorderInlineBlockIndividual from './no-css-border-inline-block-individual';
import noCssBorderImage from './no-css-border-image';
import noCssBlockInlineSize from './no-css-block-inline-size';
import noCssBackgroundOrigin from './no-css-background-origin';
import noCssBackgroundImage from './no-css-background-image';
import noCssBackgroundClip from './no-css-background-clip';
import noCssBackgroundBlendMode from './no-css-background-blend-mode';
import noCssAspectRatio from './no-css-aspect-ratio';
import noCssAnimation from './no-css-animation';
import noCssAlignItems from './no-css-align-items';
import noCssAccentColor from './no-css-accent-color';
import noHtmlWbr from "./no-html-wbr";
import noHtmlVideo from "./no-html-video";
import noHtmlTextarea from "./no-html-textarea";
import noHtmlTarget from "./no-html-target";
import noHtmlSvg from "./no-html-svg";
import noHtmlSrcset from "./no-html-srcset";
import noHtmlSemantics from "./no-html-semantics";
import noHtmlSelect from "./no-html-select";
import noHtmlRuby from "./no-html-ruby";
import noHtmlRt from "./no-html-rt";
import noHtmlRp from "./no-html-rp";
import noHtmlRole from "./no-html-role";
import noHtmlRequired from "./no-html-required";
import noHtmlProgress from "./no-html-progress";
import noHtmlPicture from "./no-html-picture";
import noHtmlObject from "./no-html-object";
import noHtmlMeter from "./no-html-meter";
import noHtmlMarquee from "./no-html-marquee";
import noHtmlLoadingAttribute from "./no-html-loading-attribute";
import noHtmlLink from "./no-html-link";
import noHtmlLang from "./no-html-lang";
import noHtmlInputText from "./no-html-input-text";
import noHtmlInputSubmit from "./no-html-input-submit";
import noHtmlInputReset from "./no-html-input-reset";
import noHtmlInputRadio from "./no-html-input-radio";
import noHtmlInputHidden from "./no-html-input-hidden";
import noHtmlInputCheckbox from "./no-html-input-checkbox";
import noHtmlForm from "./no-html-form";
import noHtmlDoctype from "./no-html-doctype";
import noHtmlDialog from "./no-html-dialog";
import noHtmlDfn from "./no-html-dfn";
import noHtmlButtonSubmit from "./no-html-button-submit";
import noHtmlButtonReset from "./no-html-button-reset";
import noHtmlBody from "./no-html-body";
import noHtmlBdi from "./no-html-bdi";
import noHtmlBase from "./no-html-base";
import noHtmlAudio from "./no-html-audio";
import noHtmlAriaLive from "./no-html-aria-live";
import noHtmlAriaLabelledby from "./no-html-aria-labelledby";
import noHtmlAriaLabel from "./no-html-aria-label";
import noHtmlAriaHidden from "./no-html-aria-hidden";
import noHtmlAriaDescribedby from "./no-html-aria-describedby";
import noHtmlAnchorLinks from "./no-html-anchor-links";
import noHtmlAbbr from "./no-html-abbr";
import noCssWritingMode from "./no-css-writing-mode";
import noCssWordBreak from "./no-css-word-break";
import noCssVisibility from "./no-css-visibility";
import noCssUnitVmin from "./no-css-unit-vmin";
import noCssUnitVmax from "./no-css-unit-vmax";
import noCssUnitVh from "./no-css-unit-vh";
import noCssUnitRem from "./no-css-unit-rem";
import noCssUnitInitial from "./no-css-unit-initial";
import noCssUnitCh from "./no-css-unit-ch";
import noCssUnitCalc from "./no-css-unit-calc";
import noCssTransform from "./no-css-transform";
import noCssTextUnderlineOffset from "./no-css-text-underline-offset";
import noCssTextShadow from "./no-css-text-shadow";
import noCssTextOverflow from "./no-css-text-overflow";
import noCssTextEmphasis from "./no-css-text-emphasis";
import noCssTextEmphasisPosition from "./no-css-text-emphasis-position";
import noCssTextDecorationThickness from "./no-css-text-decoration-thickness";
import noCssTextDecorationColor from "./no-css-text-decoration-color";
import noCssTextAlignLast from "./no-css-text-align-last";
import noCssTableLayout from "./no-css-table-layout";
import noCssTabSize from "./no-css-tab-size";
import noCssScrollSnap from "./no-css-scroll-snap";
import noCssRgba from "./no-css-rgba";
import noCssRadialGradient from "./no-css-radial-gradient";
import noCssPosition from "./no-css-position";
import noCssPaddingInlineStartEnd from "./no-css-padding-inline-start-end";
import noCssPaddingInlineBlock from "./no-css-padding-inline-block";
import noCssPaddingBlockStartEnd from "./no-css-padding-block-start-end";
import noCssOverflowWrap from "./no-css-overflow-wrap";
import noCssOutlineOffset from "./no-css-outline-offset";
import noCssOpacity from "./no-css-opacity";
import noCssObjectPosition from "./no-css-object-position";
import noCssObjectFit from "./no-css-object-fit";
import noCssModernColor from "./no-css-modern-color";
import noCssMixBlendMode from "./no-css-mix-blend-mode";
import noCssMinInlineSize from "./no-css-min-inline-size";
import noCssMaxBlockSize from "./no-css-max-block-size";
import noCssMarginInline from "./no-css-margin-inline";
import noCssMarginInlineStartEnd from "./no-css-margin-inline-start-end";
import noCssMarginInlineBlock from "./no-css-margin-inline-block";
import noCssMarginBlockStartEnd from "./no-css-margin-block-start-end";
import noCssListStyleImage from "./no-css-list-style-image";
import noCssLinearGradient from "./no-css-linear-gradient";
import noCssLeftRightTopBottom from "./no-css-left-right-top-bottom";
import noCssJustifyContent from "./no-css-justify-content";
import noCssIntrinsicSize from "./no-css-intrinsic-size";
import noCssImportant from "./no-css-important";
import noCssHyphens from "./no-css-hyphens";
import noCssGridTemplate from "./no-css-grid-template";
import noCssGap from "./no-css-gap";
import noCssFunctionMin from "./no-css-function-min";
import noCssFunctionMax from "./no-css-function-max";
import noCssFunctionClamp from "./no-css-function-clamp";
import noCssFontKerning from "./no-css-font-kerning";
import noCssFlexWrap from "./no-css-flex-wrap";
import noCssFlexDirection from "./no-css-flex-direction";
import noCssFilter from "./no-css-filter";
import noCssDisplayGrid from "./no-css-display-grid";
import noCssDisplayFlex from "./no-css-display-flex";
import noCssConicGradient from "./no-css-conic-gradient";
import noCssColumnLayoutProperties from "./no-css-column-layout-properties";
import noCssColumnCount from "./no-css-column-count";
import noCssClipPath from "./no-css-clip-path";
import noCssBoxSizing from "./no-css-box-sizing";
import noCssBoxShadow from "./no-css-box-shadow";
import noCssBorderRadius from "./no-css-border-radius";
import noCssBorderRadiusLogical from "./no-css-border-radius-logical";
import noCssBorderInlineBlock from "./no-css-border-inline-block";
import noCssBorderInlineBlockLonghand from "./no-css-border-inline-block-longhand";
import noCssBorderInlineBlockIndividual from "./no-css-border-inline-block-individual";
import noCssBorderImage from "./no-css-border-image";
import noCssBlockInlineSize from "./no-css-block-inline-size";
import noCssBackgroundOrigin from "./no-css-background-origin";
import noCssBackgroundImage from "./no-css-background-image";
import noCssBackgroundClip from "./no-css-background-clip";
import noCssBackgroundBlendMode from "./no-css-background-blend-mode";
import noCssAspectRatio from "./no-css-aspect-ratio";
import noCssAnimation from "./no-css-animation";
import noCssAlignItems from "./no-css-align-items";
import noCssAccentColor from "./no-css-accent-color";

export { noCssAccentColor };
export { noCssAlignItems };
Expand Down Expand Up @@ -246,4 +246,4 @@ export { noHtmlSvg };
export { noHtmlTarget };
export { noHtmlTextarea };
export { noHtmlVideo };
export { noHtmlWbr };
export { noHtmlWbr };
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { createNoStylePropertyRule } from "../../utils/create-no-style-property-rule";

export default createNoStylePropertyRule(
'accent-color',
15.555555555555555,
'https://www.caniemail.com/features/css-accent-color/'
"accent-color",
15.555555555555555,
"https://www.caniemail.com/features/css-accent-color/",
);
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { createNoStylePropertyRule } from "../../utils/create-no-style-property-rule";

export default createNoStylePropertyRule(
'align-items',
62.745098039215684,
'https://www.caniemail.com/features/css-align-items/'
"align-items",
62.745098039215684,
"https://www.caniemail.com/features/css-align-items/",
);
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { createNoStylePropertyRule } from "../../utils/create-no-style-property-rule";

export default createNoStylePropertyRule(
'animation',
30.851063829787233,
'https://www.caniemail.com/features/css-animation/'
"animation",
30.851063829787233,
"https://www.caniemail.com/features/css-animation/",
);
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { createNoStylePropertyRule } from "../../utils/create-no-style-property-rule";

export default createNoStylePropertyRule(
'aspect-ratio',
34,
'https://www.caniemail.com/features/css-aspect-ratio/'
"aspect-ratio",
34,
"https://www.caniemail.com/features/css-aspect-ratio/",
);
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { createNoStylePropertyRule } from "../../utils/create-no-style-property-rule";

export default createNoStylePropertyRule(
'background-blend-mode',
63.829787234042556,
'https://www.caniemail.com/features/css-background-blend-mode/'
"background-blend-mode",
63.829787234042556,
"https://www.caniemail.com/features/css-background-blend-mode/",
);
Loading

0 comments on commit c478a17

Please sign in to comment.