glitch-soc/mastodon

View on GitHub

Showing 4,885 of 4,885 total issues

Similar blocks of code found in 2 locations. Consider refactoring.
Open

export const Search: React.FC<{
singleColumn: boolean;
initialValue?: string;
}> = ({ singleColumn, initialValue }) => {
const intl = useIntl();
app/javascript/mastodon/features/compose/components/search.tsx on lines 60..593

Similar blocks of code found in 2 locations. Consider refactoring.
Open

export const Search: React.FC<{
singleColumn: boolean;
initialValue?: string;
}> = ({ singleColumn, initialValue }) => {
const intl = useIntl();
app/javascript/flavours/glitch/features/compose/components/search.tsx on lines 60..593

Similar blocks of code found in 2 locations. Consider refactoring.
Open

export const Profile: React.FC<{
multiColumn?: boolean;
}> = ({ multiColumn }) => {
const account = useAppSelector((state) =>
me ? state.accounts.get(me) : undefined,
Severity: Major
Found in app/javascript/mastodon/features/onboarding/profile.tsx and 1 other location - About 1 wk to fix
app/javascript/flavours/glitch/features/onboarding/profile.tsx on lines 50..330

Similar blocks of code found in 2 locations. Consider refactoring.
Open

export const Profile: React.FC<{
multiColumn?: boolean;
}> = ({ multiColumn }) => {
const account = useAppSelector((state) =>
me ? state.accounts.get(me) : undefined,
app/javascript/mastodon/features/onboarding/profile.tsx on lines 50..330

Similar blocks of code found in 2 locations. Consider refactoring.
Open

export default class Card extends PureComponent {
 
static propTypes = {
card: ImmutablePropTypes.map,
onOpenMedia: PropTypes.func.isRequired,
Severity: Major
Found in app/javascript/mastodon/features/status/components/card.jsx and 1 other location - About 1 wk to fix
app/javascript/flavours/glitch/features/status/components/card.jsx on lines 50..241

Similar blocks of code found in 2 locations. Consider refactoring.
Open

export default class Card extends PureComponent {
 
static propTypes = {
card: ImmutablePropTypes.map,
onOpenMedia: PropTypes.func.isRequired,
app/javascript/mastodon/features/status/components/card.jsx on lines 61..252

Similar blocks of code found in 2 locations. Consider refactoring.
Open

export const Notifications: React.FC<{
columnId?: string;
multiColumn?: boolean;
}> = ({ columnId, multiColumn }) => {
const intl = useIntl();
Severity: Major
Found in app/javascript/mastodon/features/notifications_v2/index.tsx and 1 other location - About 1 wk to fix
app/javascript/flavours/glitch/features/notifications_v2/index.tsx on lines 62..341

Similar blocks of code found in 2 locations. Consider refactoring.
Open

export const Notifications: React.FC<{
columnId?: string;
multiColumn?: boolean;
}> = ({ columnId, multiColumn }) => {
const intl = useIntl();
app/javascript/mastodon/features/notifications_v2/index.tsx on lines 62..341

Similar blocks of code found in 2 locations. Consider refactoring.
Open

const LoginForm: React.FC<{
resourceUrl: string;
}> = ({ resourceUrl }) => {
const intl = useIntl();
const [value, setValue] = useState(
app/javascript/flavours/glitch/features/interaction_modal/index.tsx on lines 133..406

Similar blocks of code found in 2 locations. Consider refactoring.
Open

const LoginForm: React.FC<{
resourceUrl: string;
}> = ({ resourceUrl }) => {
const intl = useIntl();
const [value, setValue] = useState(
app/javascript/mastodon/features/interaction_modal/index.tsx on lines 133..406

Identical blocks of code found in 2 locations. Consider refactoring.
Open

export default class AutosuggestInput extends ImmutablePureComponent {
 
static propTypes = {
value: PropTypes.string,
suggestions: ImmutablePropTypes.list,
app/javascript/mastodon/components/autosuggest_input.jsx on lines 40..235

Identical blocks of code found in 2 locations. Consider refactoring.
Open

export default class AutosuggestInput extends ImmutablePureComponent {
 
static propTypes = {
value: PropTypes.string,
suggestions: ImmutablePropTypes.list,
Severity: Major
Found in app/javascript/mastodon/components/autosuggest_input.jsx and 1 other location - About 1 wk to fix
app/javascript/flavours/glitch/components/autosuggest_input.jsx on lines 40..235

Similar blocks of code found in 2 locations. Consider refactoring.
Open

const LanguageDropdownMenu: React.FC<{
value: string;
guess?: string;
onClose: () => void;
onChange: (arg0: string) => void;
app/javascript/mastodon/features/compose/components/language_dropdown.tsx on lines 58..323

Similar blocks of code found in 2 locations. Consider refactoring.
Open

const LanguageDropdownMenu: React.FC<{
value: string;
guess?: string;
onClose: () => void;
onChange: (arg0: string) => void;
app/javascript/flavours/glitch/features/compose/components/language_dropdown.tsx on lines 58..323

Similar blocks of code found in 2 locations. Consider refactoring.
Open

export const AltTextModal = forwardRef<ModalRef, Props & Partial<RestoreProps>>(
({ mediaId, previousDescription, previousPosition, onClose }, ref) => {
const intl = useIntl();
const dispatch = useAppDispatch();
const media = useAppSelector((state) =>
Severity: Major
Found in app/javascript/mastodon/features/alt_text_modal/index.tsx and 1 other location - About 1 wk to fix
app/javascript/flavours/glitch/features/alt_text_modal/index.tsx on lines 255..503

Similar blocks of code found in 2 locations. Consider refactoring.
Open

export const AltTextModal = forwardRef<ModalRef, Props & Partial<RestoreProps>>(
({ mediaId, previousDescription, previousPosition, onClose }, ref) => {
const intl = useIntl();
const dispatch = useAppDispatch();
const media = useAppSelector((state) =>
app/javascript/mastodon/features/alt_text_modal/index.tsx on lines 255..503

Similar blocks of code found in 2 locations. Consider refactoring.
Open

class HashtagTimeline extends PureComponent {
disconnects = [];
 
static propTypes = {
identity: identityContextPropShape,
Severity: Major
Found in app/javascript/mastodon/features/hashtag_timeline/index.jsx and 1 other location - About 1 wk to fix
app/javascript/flavours/glitch/features/hashtag_timeline/index.jsx on lines 29..201

Similar blocks of code found in 2 locations. Consider refactoring.
Open

class HashtagTimeline extends PureComponent {
disconnects = [];
 
static propTypes = {
identity: identityContextPropShape,
app/javascript/mastodon/features/hashtag_timeline/index.jsx on lines 29..201

Similar blocks of code found in 2 locations. Consider refactoring.
Open

render () {
const { src, intl, alt, lang, editable, autoPlay, sensitive, blurhash, matchedFilters } = this.props;
const { paused, volume, currentTime, duration, buffer, dragging, revealed } = this.state;
const progress = Math.min((currentTime / duration) * 100, 100);
const muted = this.state.muted || volume === 0;
Severity: Major
Found in app/javascript/mastodon/features/audio/index.jsx and 1 other location - About 1 wk to fix
app/javascript/flavours/glitch/features/audio/index.jsx on lines 481..590

Similar blocks of code found in 2 locations. Consider refactoring.
Open

render () {
const { src, intl, alt, lang, editable, autoPlay, sensitive, blurhash, matchedFilters } = this.props;
const { paused, volume, currentTime, duration, buffer, dragging, revealed } = this.state;
const progress = Math.min((currentTime / duration) * 100, 100);
const muted = this.state.muted || volume === 0;
Severity: Major
Found in app/javascript/flavours/glitch/features/audio/index.jsx and 1 other location - About 1 wk to fix
app/javascript/mastodon/features/audio/index.jsx on lines 475..584
Severity
Category
Status
Source
Language