Skip to content

Commit

Permalink
Merge branch 'main' into akul/add-system-theme-option
Browse files Browse the repository at this point in the history
  • Loading branch information
akulsr0 authored Jun 27, 2024
2 parents f2cabb3 + fc25047 commit cc86347
Show file tree
Hide file tree
Showing 97 changed files with 30,169 additions and 29,118 deletions.
551 changes: 281 additions & 270 deletions .eleventy.js

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ jobs:
run: npm run install:playground
- name: Lint Files
run: npm run lint
- name: Check Formatting
run: npm run fmt:check
- name: Run build
run: npm run build
- name: Validate Internal Links
Expand Down
38 changes: 19 additions & 19 deletions .markdownlint.json
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
{
"default": true,
"MD004": {
"style": "asterisk"
},
"MD009": false,
"MD012": false,
"MD013": false,
"MD014": false,
"MD025": false,
"MD026": false,
"MD033": false,
"MD034": false,
"MD040": false,
"MD041": false,
"MD047": false,
"MD049": {
"style": "asterisk"
}
}
"default": true,
"MD004": {
"style": "asterisk"
},
"MD009": false,
"MD012": false,
"MD013": false,
"MD014": false,
"MD025": false,
"MD026": false,
"MD033": false,
"MD034": false,
"MD040": false,
"MD041": false,
"MD047": false,
"MD049": {
"style": "asterisk"
}
}
12 changes: 12 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
*
!*/
!*.js
!*.jsx
!*.json
!*.scss
_site
package-lock.json
src/_data/*.json
*-polyfill.js
*-ponyfill*.js
*.min.js
14 changes: 14 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"useTabs": true,
"tabWidth": 4,
"arrowParens": "avoid",
"overrides": [
{
"files": ["*.json"],
"options": {
"tabWidth": 2,
"useTabs": false
}
}
]
}
56 changes: 32 additions & 24 deletions .stylelintrc.js
Original file line number Diff line number Diff line change
@@ -1,28 +1,36 @@
"use strict";

module.exports = {
extends: ["stylelint-config-standard-scss"],
rules: {
"alpha-value-notation": "number",
"at-rule-empty-line-before": null,
"color-function-notation": "legacy",
"color-hex-case": null,
"custom-property-empty-line-before": null,
"custom-property-pattern": null,
"declaration-block-no-duplicate-properties": [true, {
ignore: ["consecutive-duplicates-with-different-values"]
}],
"declaration-block-no-redundant-longhand-properties": null,
"declaration-block-no-shorthand-property-overrides": null,
"hue-degree-notation": "number",
indentation: 4,
"max-line-length": null,
"no-descending-specificity": null,
"number-leading-zero": null,
"number-no-trailing-zeros": null,
"property-no-unknown": null,
"property-no-vendor-prefix": null,
"selector-class-pattern": null,
"value-keyword-case": null
}
extends: ["stylelint-config-standard-scss"],
rules: {
"alpha-value-notation": "number",
"at-rule-empty-line-before": null,
"color-function-notation": "legacy",
"color-hex-case": null,
"custom-property-empty-line-before": null,
"custom-property-pattern": null,
"declaration-block-no-duplicate-properties": [
true,
{
ignore: ["consecutive-duplicates-with-different-values"],
},
],
"declaration-block-no-redundant-longhand-properties": null,
"declaration-block-no-shorthand-property-overrides": null,
"hue-degree-notation": "number",
indentation: null,
"declaration-colon-newline-after": null,
"selector-descendant-combinator-no-non-space": null,
"selector-combinator-space-before": null,
"value-list-comma-newline-after": null,
"max-line-length": null,
"scss/operator-no-newline-after": null,
"no-descending-specificity": null,
"number-leading-zero": null,
"number-no-trailing-zeros": null,
"property-no-unknown": null,
"property-no-vendor-prefix": null,
"selector-class-pattern": null,
"value-keyword-case": null,
},
};
177 changes: 90 additions & 87 deletions eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

const eslintConfigESLintBase = require("eslint-config-eslint/base");
const eslintConfigESLintCJS = require("eslint-config-eslint/cjs");
const eslintConfigESLintFormatting = require("eslint-config-eslint/formatting");
const globals = require("globals");
const reactPlugin = require("eslint-plugin-react");
const reactRecommended = require("eslint-plugin-react/configs/recommended");
Expand All @@ -13,95 +12,99 @@ const { fixupPluginRules } = require("@eslint/compat");
const playgroundFiles = "src/playground/**/*.{js,jsx}";

module.exports = [
{
ignores: [
"_site/**",
"src/assets/js/**",
"src/_data/**",
"src/_11ty/**"
]
},
{
ignores: [
"_site/**",
"src/assets/js/**",
"src/_data/**",
"src/_11ty/**",
],
},

eslintConfigESLintFormatting,
...eslintConfigESLintCJS.map(config => ({
...config,
ignores: [playgroundFiles],
})),
{
rules: {
"n/no-extraneous-require": [
"error",
{
allowModules: ["luxon"],
},
],
},
ignores: [playgroundFiles],
},

...eslintConfigESLintCJS.map(config => ({
...config,
ignores: [playgroundFiles]
})),
{
rules: {
"n/no-extraneous-require": ["error", {
allowModules: ["luxon"]
}]
},
ignores: [playgroundFiles]
},
{
files: ["tools/**/*.js"],
rules: {
"no-console": "off",
"n/no-process-exit": "off",
},
},

{
files: ["tools/**/*.js"],
rules: {
"no-console": "off",
"n/no-process-exit": "off"
}
},
// Playground
...eslintConfigESLintBase.map(config => ({
...config,
files: [playgroundFiles],
})),
{
files: [playgroundFiles],
plugins: {
react: fixupPluginRules(reactPlugin),
"jsx-a11y": fixupPluginRules(jsxA11yPlugin),
"react-hooks": fixupPluginRules(reactHooksPlugin),
},
settings: {
react: {
version: "16.8.6",
},
},
languageOptions: {
parserOptions: {
ecmaFeatures: {
jsx: true,
},
},
sourceType: "module",
globals: {
...globals.browser,
...globals.es2021,
},
},
rules: {
...reactRecommended.rules,
...jsxA11yPlugin.configs.recommended.rules,
"react/jsx-no-useless-fragment": "error",
"react/jsx-no-target-blank": "error",

// Playground
...eslintConfigESLintBase.map(config => ({
...config,
files: [playgroundFiles]
})),
{
files: [playgroundFiles],
plugins: {
react: fixupPluginRules(reactPlugin),
"jsx-a11y": fixupPluginRules(jsxA11yPlugin),
"react-hooks": fixupPluginRules(reactHooksPlugin)
},
settings: {
react: {
version: "16.8.6"
}
},
languageOptions: {
parserOptions: {
ecmaFeatures: {
jsx: true
}
},
sourceType: "module",
globals: {
...globals.browser,
...globals.es2021
}
},
rules: {
...reactRecommended.rules,
...jsxA11yPlugin.configs.recommended.rules,
"react/jsx-no-useless-fragment": "error",
"react/jsx-no-target-blank": "error",
// Disable rules that the codebase doesn't currently follow.
// It might be a good idea to enable these in the future.
"jsx-a11y/no-onchange": "off",
"react/prop-types": "off",
"jsdoc/require-jsdoc": "off",
"react-hooks/rules-of-hooks": "error",
"react-hooks/exhaustive-deps": "warn",
"func-style": "off",
},
},

// Disable rules that the codebase doesn't currently follow.
// It might be a good idea to enable these in the future.
"jsx-a11y/no-onchange": "off",
"react/prop-types": "off",
"jsdoc/require-jsdoc": "off",
"react-hooks/rules-of-hooks": "error",
"react-hooks/exhaustive-deps": "warn",
"func-style": "off"
}
},

// Disable rules that the codebase doesn't currently follow.
// It might be a good idea to enable these in the future.
{
rules: {
"jsdoc/require-jsdoc": "off",
"jsdoc/require-returns": "off",
"jsdoc/require-param-description": "off",
"jsdoc/require-param-type": "off",
"jsdoc/no-bad-blocks": ["error", {
ignore: ["__PURE__"]
}]
}
}
// Disable rules that the codebase doesn't currently follow.
// It might be a good idea to enable these in the future.
{
rules: {
"jsdoc/require-jsdoc": "off",
"jsdoc/require-returns": "off",
"jsdoc/require-param-description": "off",
"jsdoc/require-param-type": "off",
"jsdoc/no-bad-blocks": [
"error",
{
ignore: ["__PURE__"],
},
],
},
},
];
Loading

0 comments on commit cc86347

Please sign in to comment.