From 547ea6d6879686be93d4949e0d6d0839b4268d67 Mon Sep 17 00:00:00 2001 From: bniwredyc Date: Tue, 4 Apr 2023 02:09:56 +0200 Subject: [PATCH] build fix, lint, minor fix --- .stylelintrc | 4 +--- src/components/Article/CommentsTree.tsx | 6 +++--- src/components/Article/FullArticle.tsx | 4 ++-- src/components/Editor/EditorBubbleMenu/EditorBubbleMenu.tsx | 2 +- src/components/Nav/ProfilePopup.tsx | 2 +- src/components/_shared/Button/Button.tsx | 4 ++-- 6 files changed, 10 insertions(+), 12 deletions(-) diff --git a/.stylelintrc b/.stylelintrc index 72b7b9e9..5d37490d 100644 --- a/.stylelintrc +++ b/.stylelintrc @@ -1,8 +1,6 @@ { "extends": [ - "stylelint-config-standard-scss", - "stylelint-config-prettier-scss", - "stylelint-config-css-modules" + "stylelint-config-standard-scss" ], "plugins": [ "stylelint-order", diff --git a/src/components/Article/CommentsTree.tsx b/src/components/Article/CommentsTree.tsx index 2ef2cf52..1a2d8b83 100644 --- a/src/components/Article/CommentsTree.tsx +++ b/src/components/Article/CommentsTree.tsx @@ -125,7 +125,7 @@ export const CommentsTree = (props: Props) => { onClick={() => { setCommentsOrder('newOnly') }} - className={styles.commentsViewSwitcherButton} + class={styles.commentsViewSwitcherButton} /> @@ -136,7 +136,7 @@ export const CommentsTree = (props: Props) => { onClick={() => { setCommentsOrder('createdAt') }} - className={styles.commentsViewSwitcherButton} + class={styles.commentsViewSwitcherButton} />
  • @@ -146,7 +146,7 @@ export const CommentsTree = (props: Props) => { onClick={() => { setCommentsOrder('rating') }} - className={styles.commentsViewSwitcherButton} + class={styles.commentsViewSwitcherButton} />
  • diff --git a/src/components/Article/FullArticle.tsx b/src/components/Article/FullArticle.tsx index 6600c160..f3abaa45 100644 --- a/src/components/Article/FullArticle.tsx +++ b/src/components/Article/FullArticle.tsx @@ -1,7 +1,7 @@ import { capitalize, formatDate } from '../../utils' import { Icon } from '../_shared/Icon' import { AuthorCard } from '../Author/Card' -import { createEffect, createMemo, createSignal, For, Match, onMount, Show, Switch } from 'solid-js' +import { createMemo, createSignal, For, Match, onMount, Show, Switch } from 'solid-js' import type { Author, Shout } from '../../graphql/types.gen' import MD from './MD' import { SharePopup } from './SharePopup' @@ -13,7 +13,7 @@ import { useSession } from '../../context/session' import VideoPlayer from './VideoPlayer' import Slider from '../_shared/Slider' import { getPagePath } from '@nanostores/router' -import { router, useRouter } from '../../stores/router' +import { router } from '../../stores/router' import { useReactions } from '../../context/reactions' import { Title } from '@solidjs/meta' import { useLocalize } from '../../context/localize' diff --git a/src/components/Editor/EditorBubbleMenu/EditorBubbleMenu.tsx b/src/components/Editor/EditorBubbleMenu/EditorBubbleMenu.tsx index 4a6df829..352da9a8 100644 --- a/src/components/Editor/EditorBubbleMenu/EditorBubbleMenu.tsx +++ b/src/components/Editor/EditorBubbleMenu/EditorBubbleMenu.tsx @@ -18,7 +18,7 @@ export const EditorBubbleMenu = (props: BubbleMenuProps) => { const [listBubbleOpen, setListBubbleOpen] = createSignal(false) const [linkEditorOpen, setLinkEditorOpen] = createSignal(false) - const isActive = (name: string, attributes?: {}) => + const isActive = (name: string, attributes?: unknown) => createEditorTransaction( () => props.editor, (editor) => { diff --git a/src/components/Nav/ProfilePopup.tsx b/src/components/Nav/ProfilePopup.tsx index 7eed9739..f20d988d 100644 --- a/src/components/Nav/ProfilePopup.tsx +++ b/src/components/Nav/ProfilePopup.tsx @@ -29,7 +29,7 @@ export const ProfilePopup = (props: ProfilePopupProps) => { {t('Subscriptions')}
  • - + {t('Comments')}
  • diff --git a/src/components/_shared/Button/Button.tsx b/src/components/_shared/Button/Button.tsx index 382cba8c..1b26811b 100644 --- a/src/components/_shared/Button/Button.tsx +++ b/src/components/_shared/Button/Button.tsx @@ -10,7 +10,7 @@ type Props = { loading?: boolean disabled?: boolean onClick?: () => void - className?: string | '' + class?: string } export const Button = (props: Props) => { @@ -26,7 +26,7 @@ export const Button = (props: Props) => { { [styles.loading]: props.loading }, - props.className + props.class )} > {props.value}