Faster incremental builds

This commit is contained in:
Fedor Indutny
2025-10-06 12:23:41 -07:00
committed by GitHub
parent 7ab12f3d7a
commit 780f39c285
130 changed files with 1479 additions and 1450 deletions

View File

@@ -16,7 +16,7 @@ import {
canDisplayImage,
isImageAttachment,
isVideoAttachment,
} from '../../types/Attachment.js';
} from '../../util/Attachment.js';
export type Props<T extends AttachmentForUIType | AttachmentDraftType> =
Readonly<{

View File

@@ -4,7 +4,7 @@
import React from 'react';
import classNames from 'classnames';
import { useEscapeHandling } from '../../hooks/useEscapeHandling.js';
import { getSuggestedFilename } from '../../types/Attachment.js';
import { getSuggestedFilename } from '../../util/Attachment.js';
import { IMAGE_PNG, type MIMEType } from '../../types/MIME.js';
export type PropsType = {

View File

@@ -13,7 +13,7 @@ import {
getImageDimensionsForTimeline,
defaultBlurHash,
isDownloadable,
} from '../../types/Attachment.js';
} from '../../util/Attachment.js';
import * as Errors from '../../types/errors.js';
import { createLogger } from '../../logging/log.js';
import { useReducedMotion } from '../../hooks/useReducedMotion.js';

View File

@@ -12,7 +12,7 @@ import {
defaultBlurHash,
isIncremental,
isReadyToView,
} from '../../types/Attachment.js';
} from '../../util/Attachment.js';
import { SpinnerV2 } from '../SpinnerV2.js';
import { useUndownloadableMediaHandler } from '../../hooks/useUndownloadableMediaHandler.js';

View File

@@ -17,7 +17,7 @@ import {
import { pngUrl, squareStickerUrl } from '../../storybook/Fixtures.js';
import { fakeAttachment } from '../../test-helpers/fakeAttachment.js';
import { strictAssert } from '../../util/assert.js';
import { isDownloadable } from '../../types/Attachment.js';
import { isDownloadable } from '../../util/Attachment.js';
const { i18n } = window.SignalContext;

View File

@@ -17,7 +17,7 @@ import {
isDownloadable,
isIncremental,
isVideoAttachment,
} from '../../types/Attachment.js';
} from '../../util/Attachment.js';
import { Image, CurveType } from './Image.js';

View File

@@ -53,6 +53,7 @@ import type { WidthBreakpoint } from '../_util.js';
import { OutgoingGiftBadgeModal } from '../OutgoingGiftBadgeModal.js';
import { createLogger } from '../../logging/log.js';
import { StoryViewModeType } from '../../types/Stories.js';
import { GiftBadgeStates } from '../../types/GiftBadgeStates.js';
import type {
AttachmentForUIType,
AttachmentType,
@@ -71,7 +72,7 @@ import {
isImageAttachment,
isPlayed,
isVideo,
} from '../../types/Attachment.js';
} from '../../util/Attachment.js';
import type { EmbeddedContactForUIType } from '../../types/EmbeddedContact.js';
import { getIncrement } from '../../util/timer.js';
@@ -208,13 +209,6 @@ export type AudioAttachmentProps = {
onCorrupted(): void;
};
export enum GiftBadgeStates {
Unopened = 'Unopened',
Opened = 'Opened',
Redeemed = 'Redeemed',
Failed = 'Failed',
}
export type GiftBadgeType =
| {
state:

View File

@@ -11,7 +11,7 @@ import type { LocalizerType } from '../../types/Util.js';
import type { AttachmentForUIType } from '../../types/Attachment.js';
import type { MessageStatusType } from '../../types/message/MessageStatus.js';
import type { PushPanelForConversationActionType } from '../../state/ducks/conversations.js';
import { isDownloaded } from '../../types/Attachment.js';
import { isDownloaded } from '../../util/Attachment.js';
import type { DirectionType } from './Message.js';
import type { ComputePeaksResult } from '../VoiceNotesPlaybackContext.js';

View File

@@ -4,7 +4,7 @@
import type { KeyboardEvent } from 'react';
import React from 'react';
import type { AttachmentType } from '../../types/Attachment.js';
import { canBeDownloaded, isDownloaded } from '../../types/Attachment.js';
import { canBeDownloaded, isDownloaded } from '../../util/Attachment.js';
import type { ShowConversationType } from '../../state/ducks/conversations.js';
import type { HydratedBodyRangesType } from '../../types/BodyRange.js';
import type { LocalizerType } from '../../types/Util.js';

View File

@@ -11,7 +11,7 @@ import { LinkPreviewDate } from './LinkPreviewDate.js';
import type { LinkPreviewForUIType } from '../../types/message/LinkPreviews.js';
import type { LocalizerType } from '../../types/Util.js';
import { getClassNamesFor } from '../../util/getClassNamesFor.js';
import { isImageAttachment } from '../../types/Attachment.js';
import { isImageAttachment } from '../../util/Attachment.js';
import { isCallLink } from '../../types/LinkPreview.js';
import { Avatar } from '../Avatar.js';
import { getColorForCallLink } from '../../util/getColorForCallLink.js';

View File

@@ -13,7 +13,7 @@ import { EmojiPicker } from '../emoji/EmojiPicker.js';
import type { AudioAttachmentProps } from './Message.js';
import type { Props } from './TimelineMessage.js';
import { TimelineMessage } from './TimelineMessage.js';
import { GiftBadgeStates, TextDirection } from './Message.js';
import { TextDirection } from './Message.js';
import {
AUDIO_MP3,
IMAGE_JPEG,
@@ -33,6 +33,7 @@ import { getDefaultConversation } from '../../test-helpers/getDefaultConversatio
import { WidthBreakpoint } from '../_util.js';
import { DAY, HOUR, MINUTE, SECOND } from '../../util/durations/index.js';
import { ContactFormType } from '../../types/EmbeddedContact.js';
import { GiftBadgeStates } from '../../types/GiftBadgeStates.js';
import { generateAci } from '../../types/ServiceId.js';
import {

View File

@@ -15,7 +15,7 @@ import { ContextMenuTrigger } from 'react-contextmenu';
import { createPortal } from 'react-dom';
import { Manager, Popper, Reference } from 'react-popper';
import type { PreventOverflowModifier } from '@popperjs/core/lib/modifiers/preventOverflow.js';
import { isDownloaded } from '../../types/Attachment.js';
import { isDownloaded } from '../../util/Attachment.js';
import type { LocalizerType } from '../../types/I18N.js';
import { handleOutsideClick } from '../../util/handleOutsideClick.js';
import { offsetDistanceModifier } from '../../util/popperUtil.js';

View File

@@ -16,7 +16,7 @@ import {
defaultBlurHash,
isGIF,
isVideoAttachment,
} from '../../../types/Attachment.js';
} from '../../../util/Attachment.js';
import { ImageOrBlurhash } from '../../ImageOrBlurhash.js';
import { SpinnerV2 } from '../../SpinnerV2.js';
import { tw } from '../../../axo/tw.js';