@xsolla/xui-drag-drop-uploader 0.163.0 → 0.164.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -18,6 +18,8 @@ interface DragDropUploaderProps extends ThemeOverrideProps {
18
18
  title?: React.ReactNode;
19
19
  /** Supporting text in the drop area. Set to `null` to hide it. */
20
20
  description?: React.ReactNode;
21
+ /** Icon shown above the title in the drop area. */
22
+ icon?: React.ReactNode;
21
23
  /** Error message shown below the drop area; also switches to error styling. */
22
24
  errorMessage?: string;
23
25
  /** Controlled file list. */
package/native/index.d.ts CHANGED
@@ -18,6 +18,8 @@ interface DragDropUploaderProps extends ThemeOverrideProps {
18
18
  title?: React.ReactNode;
19
19
  /** Supporting text in the drop area. Set to `null` to hide it. */
20
20
  description?: React.ReactNode;
21
+ /** Icon shown above the title in the drop area. */
22
+ icon?: React.ReactNode;
21
23
  /** Error message shown below the drop area; also switches to error styling. */
22
24
  errorMessage?: string;
23
25
  /** Controlled file list. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xsolla/xui-drag-drop-uploader",
3
- "version": "0.163.0",
3
+ "version": "0.164.0",
4
4
  "main": "./web/index.js",
5
5
  "module": "./web/index.mjs",
6
6
  "types": "./web/index.d.ts",
@@ -13,9 +13,9 @@
13
13
  "test:coverage": "vitest run --coverage"
14
14
  },
15
15
  "dependencies": {
16
- "@xsolla/xui-core": "0.163.0",
17
- "@xsolla/xui-icons-base": "0.163.0",
18
- "@xsolla/xui-primitives-core": "0.163.0"
16
+ "@xsolla/xui-core": "0.164.0",
17
+ "@xsolla/xui-icons-base": "0.164.0",
18
+ "@xsolla/xui-primitives-core": "0.164.0"
19
19
  },
20
20
  "peerDependencies": {
21
21
  "react": ">=16.8.0"
package/web/index.d.mts CHANGED
@@ -18,6 +18,8 @@ interface DragDropUploaderProps extends ThemeOverrideProps {
18
18
  title?: React.ReactNode;
19
19
  /** Supporting text in the drop area. Set to `null` to hide it. */
20
20
  description?: React.ReactNode;
21
+ /** Icon shown above the title in the drop area. */
22
+ icon?: React.ReactNode;
21
23
  /** Error message shown below the drop area; also switches to error styling. */
22
24
  errorMessage?: string;
23
25
  /** Controlled file list. */
package/web/index.d.ts CHANGED
@@ -18,6 +18,8 @@ interface DragDropUploaderProps extends ThemeOverrideProps {
18
18
  title?: React.ReactNode;
19
19
  /** Supporting text in the drop area. Set to `null` to hide it. */
20
20
  description?: React.ReactNode;
21
+ /** Icon shown above the title in the drop area. */
22
+ icon?: React.ReactNode;
21
23
  /** Error message shown below the drop area; also switches to error styling. */
22
24
  errorMessage?: string;
23
25
  /** Controlled file list. */
package/web/index.js CHANGED
@@ -350,6 +350,7 @@ var DragDropUploader = (0, import_react3.forwardRef)(
350
350
  size = "sm",
351
351
  title = DEFAULT_TITLE,
352
352
  description = DEFAULT_DESCRIPTION,
353
+ icon,
353
354
  errorMessage,
354
355
  files,
355
356
  defaultFiles = [],
@@ -532,7 +533,7 @@ var DragDropUploader = (0, import_react3.forwardRef)(
532
533
  backgroundColor,
533
534
  ...webAreaProps,
534
535
  children: [
535
- /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Box, { ...isWeb && { "aria-hidden": "true" }, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_xui_icons_base.FileExportOu, { size: sizing.iconSize, color: iconColor }) }),
536
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Box, { ...isWeb && { "aria-hidden": "true" }, children: icon ?? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_xui_icons_base.FileUploadIn, { size: sizing.iconSize, color: iconColor }) }),
536
537
  (title || description) && /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
537
538
  Box,
538
539
  {
package/web/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/index.tsx","../../src/DragDropUploader.tsx","../../../../foundation/primitives-web/src/Box.tsx","../../../../foundation/primitives-web/src/filterDOMProps.ts","../../../../../node_modules/@emotion/memoize/dist/memoize.esm.js","../../../../../node_modules/@emotion/is-prop-valid/dist/is-prop-valid.esm.js","../../../../foundation/primitives-web/src/Text.tsx","../../../../foundation/primitives-web/src/index.tsx"],"sourcesContent":["export * from \"./DragDropUploader\";\n","import React, { forwardRef, useRef, useState } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, isWeb } from \"@xsolla/xui-primitives\";\nimport { useId, useResolvedTheme } from \"@xsolla/xui-core\";\nimport { FileExportOu, FileText, TrashCan } from \"@xsolla/xui-icons-base\";\nimport type {\n DragDropUploaderFile,\n DragDropUploaderProps,\n DragDropUploaderSize,\n DragDropUploaderVisualState,\n} from \"./types\";\n\nexport type {\n DragDropUploaderFile,\n DragDropUploaderProps,\n DragDropUploaderSize,\n DragDropUploaderVisualState,\n} from \"./types\";\n\nconst DEFAULT_TITLE = \"Click or drag file to this area to upload\";\nconst DEFAULT_DESCRIPTION = \"PDF, DOC, DOCX up to 10MB\";\n\nconst formatFileSize = (size: number) => {\n if (size < 1024) return `${size}B`;\n if (size < 1024 * 1024) return `${Math.round(size / 1024)}KB`;\n return `${Math.round(size / (1024 * 1024))}MB`;\n};\n\nconst normalizeFiles = (files: File[]) =>\n files.map((file) => ({\n name: file.name,\n size: file.size,\n mimeType: file.type || undefined,\n file,\n }));\n\ntype DragDropUploaderSizing = {\n width: number;\n rootGap: number;\n radius: number;\n borderWidth: number;\n areaHeight: number;\n areaPadding: number;\n areaGap: number;\n iconSize: number;\n textGap: number;\n titleFontSize: number;\n titleLineHeight: number;\n descriptionFontSize: number;\n descriptionLineHeight: number;\n errorFontSize: number;\n errorLineHeight: number;\n listGap: number;\n itemGap: number;\n itemPaddingVertical: number;\n itemPaddingLeft: number;\n itemPaddingRight: number;\n itemIconWrapperSize: number;\n itemIconSize: number;\n itemTitleFontSize: number;\n itemTitleLineHeight: number;\n itemDescriptionFontSize: number;\n itemDescriptionLineHeight: number;\n removeIconSize: number;\n};\n\nexport const DragDropUploader = forwardRef<\n HTMLInputElement,\n DragDropUploaderProps\n>(\n (\n {\n size = \"sm\",\n title = DEFAULT_TITLE,\n description = DEFAULT_DESCRIPTION,\n errorMessage,\n files,\n defaultFiles = [],\n accept,\n multiple = false,\n disabled = false,\n loading = false,\n width,\n visualState,\n onFilesChange,\n onDropFiles,\n onRemoveFile,\n testID,\n themeMode,\n themeProductContext,\n },\n ref\n ) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const inputRef = useRef<HTMLInputElement>(null);\n const [internalFiles, setInternalFiles] =\n useState<DragDropUploaderFile[]>(defaultFiles);\n const [isHover, setIsHover] = useState(false);\n const [isDragActive, setIsDragActive] = useState(false);\n\n React.useImperativeHandle(\n ref,\n () => inputRef.current as HTMLInputElement,\n []\n );\n\n const isControlled = files !== undefined;\n const selectedFiles = isControlled ? files : internalFiles;\n const hasError = !!errorMessage;\n const isDisabled = disabled || loading;\n const sizing = (\n theme.sizing as typeof theme.sizing & {\n dragDropUploader: (\n size: DragDropUploaderSize\n ) => DragDropUploaderSizing;\n }\n ).dragDropUploader(size);\n const inputColors = theme.colors.control.input;\n const focusColors = theme.colors.control.focus;\n const alertBorder = theme.colors.control.alert.border;\n const alertText = theme.colors.content.alert.primary;\n const rootWidth = width ?? sizing.width;\n const reactId = useId();\n const baseId = `drag-drop-uploader-${reactId.replace(/[^a-zA-Z0-9-]/g, \"\")}`;\n const descriptionId = `${baseId}-description`;\n const errorId = `${baseId}-error`;\n\n let state: DragDropUploaderVisualState = \"default\";\n if (isDisabled) state = \"disabled\";\n else if (hasError) state = \"error\";\n else if (isDragActive) state = \"drag\";\n else if (isHover) state = \"hover\";\n if (visualState) state = visualState;\n\n const setNextFiles = (\n nextFiles: DragDropUploaderFile[],\n pickedFiles?: DragDropUploaderFile[]\n ) => {\n if (!isControlled) setInternalFiles(nextFiles);\n onDropFiles?.(pickedFiles ?? nextFiles);\n onFilesChange?.(nextFiles);\n };\n\n const appendFiles = (pickedFiles: DragDropUploaderFile[]) => {\n if (pickedFiles.length === 0) return;\n const nextFiles = multiple\n ? [...selectedFiles, ...pickedFiles]\n : pickedFiles.slice(0, 1);\n setNextFiles(nextFiles, pickedFiles);\n };\n\n const removeFile = (index: number) => {\n const file = selectedFiles[index];\n if (!file || isDisabled) return;\n const nextFiles = selectedFiles.filter(\n (_, itemIndex) => itemIndex !== index\n );\n if (!isControlled) setInternalFiles(nextFiles);\n onRemoveFile?.(file, index);\n onFilesChange?.(nextFiles);\n if (isWeb && inputRef.current) inputRef.current.value = \"\";\n };\n\n const handleClick = () => {\n if (!isWeb || isDisabled) return;\n inputRef.current?.click();\n };\n\n const handleFileChange = (event: React.ChangeEvent<HTMLInputElement>) => {\n const nextFiles = Array.from(event.target.files ?? []);\n event.target.value = \"\";\n appendFiles(normalizeFiles(nextFiles));\n };\n\n const handleDragOver = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n if (!isDisabled) setIsDragActive(true);\n };\n\n const handleDragLeave = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n setIsDragActive(false);\n };\n\n const handleDrop = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n setIsDragActive(false);\n if (isDisabled) return;\n appendFiles(normalizeFiles(Array.from(event.dataTransfer.files ?? [])));\n };\n\n let backgroundColor = inputColors.bg;\n let borderColor = inputColors.border;\n let titleColor = inputColors.text;\n let descriptionColor = inputColors.placeholder;\n let iconColor = theme.colors.content.brand.primary;\n\n switch (state) {\n case \"hover\":\n backgroundColor = inputColors.bgHover;\n borderColor = inputColors.border;\n break;\n case \"drag\":\n backgroundColor = focusColors.bg;\n borderColor = focusColors.border;\n break;\n case \"disabled\":\n backgroundColor = inputColors.bgDisable;\n borderColor = inputColors.borderDisable;\n titleColor = inputColors.textDisable;\n descriptionColor = inputColors.textDisable;\n iconColor = inputColors.textDisable;\n break;\n case \"error\":\n borderColor = alertBorder;\n break;\n }\n\n const describedBy =\n [description ? descriptionId : null, errorMessage ? errorId : null]\n .filter(Boolean)\n .join(\" \") || undefined;\n\n const webAreaProps = isWeb\n ? {\n \"aria-describedby\": describedBy,\n \"aria-disabled\": isDisabled || undefined,\n \"aria-invalid\": hasError || undefined,\n onMouseEnter: () => {\n if (!isDisabled) setIsHover(true);\n },\n onMouseLeave: () => setIsHover(false),\n onDragOver: handleDragOver,\n onDragLeave: handleDragLeave,\n onDrop: handleDrop,\n style: {\n boxSizing: \"border-box\" as const,\n cursor: isDisabled ? \"not-allowed\" : \"pointer\",\n outline: \"none\",\n transition: \"background-color 0.15s ease, border-color 0.15s ease\",\n },\n }\n : {};\n\n return (\n <Box\n testID={testID || \"drag-drop-uploader\"}\n flexDirection=\"column\"\n gap={sizing.rootGap}\n alignItems=\"flex-start\"\n width={rootWidth}\n >\n {isWeb && (\n <input\n type=\"file\"\n ref={inputRef}\n accept={accept}\n multiple={multiple}\n onChange={handleFileChange}\n style={{ display: \"none\" }}\n disabled={isDisabled}\n tabIndex={-1}\n aria-hidden=\"true\"\n data-testid=\"drag-drop-uploader__input\"\n />\n )}\n\n <Box\n as={isWeb ? \"button\" : \"div\"}\n disabled={isDisabled}\n data-testid=\"drag-drop-uploader__area\"\n onPress={handleClick}\n flexDirection=\"column\"\n alignItems=\"center\"\n justifyContent=\"center\"\n width=\"100%\"\n height={sizing.areaHeight}\n gap={sizing.areaGap}\n padding={sizing.areaPadding}\n borderRadius={sizing.radius}\n borderWidth={sizing.borderWidth}\n borderColor={borderColor}\n borderStyle=\"dashed\"\n backgroundColor={backgroundColor}\n {...webAreaProps}\n >\n <Box {...(isWeb && { \"aria-hidden\": \"true\" })}>\n <FileExportOu size={sizing.iconSize} color={iconColor} />\n </Box>\n\n {(title || description) && (\n <Box\n flexDirection=\"column\"\n gap={sizing.textGap}\n width=\"100%\"\n alignItems=\"center\"\n >\n {title &&\n (typeof title === \"string\" ? (\n <Text\n color={titleColor}\n fontSize={sizing.titleFontSize}\n lineHeight={sizing.titleLineHeight}\n fontWeight=\"500\"\n textAlign=\"center\"\n numberOfLines={2}\n >\n {title}\n </Text>\n ) : (\n <Box>{title}</Box>\n ))}\n\n {description &&\n (typeof description === \"string\" ? (\n <Text\n id={descriptionId}\n color={descriptionColor}\n fontSize={sizing.descriptionFontSize}\n lineHeight={sizing.descriptionLineHeight}\n textAlign=\"center\"\n numberOfLines={2}\n >\n {description}\n </Text>\n ) : (\n <Box id={descriptionId}>{description}</Box>\n ))}\n </Box>\n )}\n </Box>\n\n {errorMessage && (\n <Text\n id={errorId}\n role=\"alert\"\n data-testid=\"drag-drop-uploader__error\"\n color={alertText}\n fontSize={sizing.errorFontSize}\n lineHeight={sizing.errorLineHeight}\n >\n {errorMessage}\n </Text>\n )}\n\n {selectedFiles.length > 0 && (\n <Box\n data-testid=\"drag-drop-uploader__list\"\n flexDirection=\"column\"\n gap={sizing.listGap}\n width=\"100%\"\n >\n {selectedFiles.map((file, index) => (\n <Box\n key={`${file.name}-${index}`}\n data-testid=\"drag-drop-uploader__file\"\n flexDirection=\"row\"\n alignItems=\"center\"\n gap={sizing.itemGap}\n width=\"100%\"\n paddingVertical={sizing.itemPaddingVertical}\n paddingLeft={sizing.itemPaddingLeft}\n paddingRight={sizing.itemPaddingRight}\n borderRadius={sizing.radius}\n borderWidth={sizing.borderWidth}\n borderColor={inputColors.border}\n backgroundColor={inputColors.bg}\n style={isWeb ? { boxSizing: \"border-box\" } : undefined}\n >\n <Box\n alignItems=\"center\"\n justifyContent=\"center\"\n width={sizing.itemIconWrapperSize}\n height={sizing.itemIconWrapperSize}\n borderRadius={sizing.radius}\n backgroundColor={theme.colors.overlay.mono}\n {...(isWeb && { \"aria-hidden\": \"true\" })}\n >\n <FileText\n size={sizing.itemIconSize}\n color={inputColors.placeholder}\n />\n </Box>\n\n <Box flexDirection=\"column\" gap={2} flex={1} minWidth={0}>\n <Text\n color={inputColors.text}\n fontSize={sizing.itemTitleFontSize}\n lineHeight={sizing.itemTitleLineHeight}\n numberOfLines={1}\n style={\n isWeb\n ? {\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }\n : undefined\n }\n >\n {file.name}\n </Text>\n <Text\n color={inputColors.placeholder}\n fontSize={sizing.itemDescriptionFontSize}\n lineHeight={sizing.itemDescriptionLineHeight}\n numberOfLines={1}\n >\n {formatFileSize(file.size)}\n </Text>\n </Box>\n\n <Box\n as={isWeb ? \"button\" : \"div\"}\n data-testid=\"drag-drop-uploader__remove\"\n aria-label={`Remove ${file.name}`}\n disabled={isDisabled}\n onPress={(event?: { stopPropagation?: () => void }) => {\n event?.stopPropagation?.();\n removeFile(index);\n }}\n padding={0}\n alignItems=\"center\"\n justifyContent=\"center\"\n style={\n isWeb\n ? {\n border: \"none\",\n background: \"transparent\",\n cursor: isDisabled ? \"not-allowed\" : \"pointer\",\n }\n : undefined\n }\n >\n <TrashCan\n size={sizing.removeIconSize}\n color={inputColors.placeholder}\n />\n </Box>\n </Box>\n ))}\n </Box>\n )}\n </Box>\n );\n }\n);\n\nDragDropUploader.displayName = \"DragDropUploader\";\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport type { BoxProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledBox = styled(FilteredDiv)<BoxProps>`\n display: flex;\n box-sizing: border-box;\n background-color: ${(props) => props.backgroundColor || \"transparent\"};\n border-color: ${(props) => props.borderColor || \"transparent\"};\n border-width: ${(props) =>\n typeof props.borderWidth === \"number\"\n ? `${props.borderWidth}px`\n : props.borderWidth || 0};\n\n ${(props) =>\n props.borderBottomWidth !== undefined &&\n `\n border-bottom-width: ${typeof props.borderBottomWidth === \"number\" ? `${props.borderBottomWidth}px` : props.borderBottomWidth};\n border-bottom-color: ${props.borderBottomColor || props.borderColor || \"transparent\"};\n border-bottom-style: solid;\n `}\n ${(props) =>\n props.borderTopWidth !== undefined &&\n `\n border-top-width: ${typeof props.borderTopWidth === \"number\" ? `${props.borderTopWidth}px` : props.borderTopWidth};\n border-top-color: ${props.borderTopColor || props.borderColor || \"transparent\"};\n border-top-style: solid;\n `}\n ${(props) =>\n props.borderLeftWidth !== undefined &&\n `\n border-left-width: ${typeof props.borderLeftWidth === \"number\" ? `${props.borderLeftWidth}px` : props.borderLeftWidth};\n border-left-color: ${props.borderLeftColor || props.borderColor || \"transparent\"};\n border-left-style: solid;\n `}\n ${(props) =>\n props.borderRightWidth !== undefined &&\n `\n border-right-width: ${typeof props.borderRightWidth === \"number\" ? `${props.borderRightWidth}px` : props.borderRightWidth};\n border-right-color: ${props.borderRightColor || props.borderColor || \"transparent\"};\n border-right-style: solid;\n `}\n\n border-style: ${(props) =>\n props.borderStyle ||\n (props.borderWidth ||\n props.borderBottomWidth ||\n props.borderTopWidth ||\n props.borderLeftWidth ||\n props.borderRightWidth\n ? \"solid\"\n : \"none\")};\n border-radius: ${(props) =>\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius || 0};\n height: ${(props) =>\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height || \"auto\"};\n width: ${(props) =>\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width || \"auto\"};\n min-width: ${(props) =>\n typeof props.minWidth === \"number\"\n ? `${props.minWidth}px`\n : props.minWidth || \"auto\"};\n min-height: ${(props) =>\n typeof props.minHeight === \"number\"\n ? `${props.minHeight}px`\n : props.minHeight || \"auto\"};\n max-width: ${(props) =>\n typeof props.maxWidth === \"number\"\n ? `${props.maxWidth}px`\n : props.maxWidth || \"none\"};\n max-height: ${(props) =>\n typeof props.maxHeight === \"number\"\n ? `${props.maxHeight}px`\n : props.maxHeight || \"none\"};\n\n padding: ${(props) =>\n typeof props.padding === \"number\"\n ? `${props.padding}px`\n : props.padding || 0};\n ${(props) =>\n props.paddingHorizontal &&\n `\n padding-left: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n padding-right: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n `}\n ${(props) =>\n props.paddingVertical &&\n `\n padding-top: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n padding-bottom: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n `}\n ${(props) =>\n props.paddingTop !== undefined &&\n `padding-top: ${typeof props.paddingTop === \"number\" ? `${props.paddingTop}px` : props.paddingTop};`}\n ${(props) =>\n props.paddingBottom !== undefined &&\n `padding-bottom: ${typeof props.paddingBottom === \"number\" ? `${props.paddingBottom}px` : props.paddingBottom};`}\n ${(props) =>\n props.paddingLeft !== undefined &&\n `padding-left: ${typeof props.paddingLeft === \"number\" ? `${props.paddingLeft}px` : props.paddingLeft};`}\n ${(props) =>\n props.paddingRight !== undefined &&\n `padding-right: ${typeof props.paddingRight === \"number\" ? `${props.paddingRight}px` : props.paddingRight};`}\n\n margin: ${(props) =>\n typeof props.margin === \"number\" ? `${props.margin}px` : props.margin || 0};\n ${(props) =>\n props.marginTop !== undefined &&\n `margin-top: ${typeof props.marginTop === \"number\" ? `${props.marginTop}px` : props.marginTop};`}\n ${(props) =>\n props.marginBottom !== undefined &&\n `margin-bottom: ${typeof props.marginBottom === \"number\" ? `${props.marginBottom}px` : props.marginBottom};`}\n ${(props) =>\n props.marginLeft !== undefined &&\n `margin-left: ${typeof props.marginLeft === \"number\" ? `${props.marginLeft}px` : props.marginLeft};`}\n ${(props) =>\n props.marginRight !== undefined &&\n `margin-right: ${typeof props.marginRight === \"number\" ? `${props.marginRight}px` : props.marginRight};`}\n\n flex-direction: ${(props) => props.flexDirection || \"column\"};\n flex-wrap: ${(props) => props.flexWrap || \"nowrap\"};\n align-items: ${(props) => props.alignItems || \"stretch\"};\n justify-content: ${(props) => props.justifyContent || \"flex-start\"};\n cursor: ${(props) =>\n props.cursor\n ? props.cursor\n : props.onClick || props.onPress\n ? \"pointer\"\n : \"inherit\"};\n position: ${(props) => props.position || \"static\"};\n top: ${(props) =>\n typeof props.top === \"number\" ? `${props.top}px` : props.top};\n bottom: ${(props) =>\n typeof props.bottom === \"number\" ? `${props.bottom}px` : props.bottom};\n left: ${(props) =>\n typeof props.left === \"number\" ? `${props.left}px` : props.left};\n right: ${(props) =>\n typeof props.right === \"number\" ? `${props.right}px` : props.right};\n flex: ${(props) => props.flex};\n flex-shrink: ${(props) => props.flexShrink ?? 1};\n gap: ${(props) =>\n typeof props.gap === \"number\" ? `${props.gap}px` : props.gap || 0};\n align-self: ${(props) => props.alignSelf || \"auto\"};\n overflow: ${(props) => props.overflow || \"visible\"};\n overflow-x: ${(props) => props.overflowX || \"visible\"};\n overflow-y: ${(props) => props.overflowY || \"visible\"};\n z-index: ${(props) => props.zIndex};\n opacity: ${(props) => (props.disabled ? 0.5 : 1)};\n pointer-events: ${(props) => (props.disabled ? \"none\" : \"auto\")};\n\n &:hover {\n ${(props) =>\n props.hoverStyle?.backgroundColor &&\n `background-color: ${props.hoverStyle.backgroundColor};`}\n ${(props) =>\n props.hoverStyle?.borderColor &&\n `border-color: ${props.hoverStyle.borderColor};`}\n }\n\n &:active {\n ${(props) =>\n props.pressStyle?.backgroundColor &&\n `background-color: ${props.pressStyle.backgroundColor};`}\n }\n`;\n\nexport const Box = React.forwardRef<\n HTMLDivElement | HTMLButtonElement,\n BoxProps\n>(\n (\n {\n children,\n onPress,\n onKeyDown,\n onKeyUp,\n role,\n \"aria-label\": ariaLabel,\n \"aria-labelledby\": ariaLabelledBy,\n \"aria-current\": ariaCurrent,\n \"aria-disabled\": ariaDisabled,\n \"aria-live\": ariaLive,\n \"aria-busy\": ariaBusy,\n \"aria-describedby\": ariaDescribedBy,\n \"aria-expanded\": ariaExpanded,\n \"aria-haspopup\": ariaHasPopup,\n \"aria-pressed\": ariaPressed,\n \"aria-controls\": ariaControls,\n tabIndex,\n as,\n src,\n alt,\n onError,\n onLoad,\n type,\n disabled,\n id,\n testID,\n \"data-testid\": dataTestId,\n ...props\n },\n ref\n ) => {\n // Handle as=\"img\" for rendering images with proper border-radius\n if (as === \"img\" && src) {\n return (\n <img\n src={src}\n alt={alt || \"\"}\n onError={onError}\n onLoad={onLoad}\n style={{\n display: \"block\",\n objectFit: \"cover\",\n width:\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width,\n height:\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height,\n borderRadius:\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius,\n position: props.position,\n top: typeof props.top === \"number\" ? `${props.top}px` : props.top,\n left:\n typeof props.left === \"number\" ? `${props.left}px` : props.left,\n right:\n typeof props.right === \"number\"\n ? `${props.right}px`\n : props.right,\n bottom:\n typeof props.bottom === \"number\"\n ? `${props.bottom}px`\n : props.bottom,\n ...props.style,\n }}\n />\n );\n }\n\n return (\n <StyledBox\n ref={ref}\n elementType={as}\n id={id}\n type={as === \"button\" ? type || \"button\" : undefined}\n disabled={as === \"button\" ? disabled : undefined}\n onClick={onPress}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n role={role}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n aria-current={ariaCurrent}\n aria-disabled={ariaDisabled}\n aria-busy={ariaBusy}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n aria-haspopup={ariaHasPopup}\n aria-pressed={ariaPressed}\n aria-controls={ariaControls}\n aria-live={ariaLive}\n tabIndex={tabIndex !== undefined ? tabIndex : undefined}\n data-testid={dataTestId || testID}\n {...props}\n >\n {children}\n </StyledBox>\n );\n }\n);\n\nBox.displayName = \"Box\";\n","import React from \"react\";\nimport isPropValid from \"@emotion/is-prop-valid\";\n\n// Props that @emotion/is-prop-valid incorrectly treats as valid HTML.\n// These are React Native or component-specific props that match\n// valid HTML patterns (on* event handlers, SVG attributes).\nexport const ADDITIONAL_BLOCKED_PROPS = new Set([\n // RN-only event handlers (pass isPropValid's on* pattern)\n \"onPress\",\n \"onChangeText\",\n \"onLayout\",\n \"onMoveShouldSetResponder\",\n \"onResponderGrant\",\n \"onResponderMove\",\n \"onResponderRelease\",\n \"onResponderTerminate\",\n // SVG attributes that pass isPropValid\n \"strokeWidth\",\n // CSS properties that pass isPropValid but are used as component props\n \"overflow\",\n \"cursor\",\n \"fontSize\",\n \"fontWeight\",\n \"fontFamily\",\n \"textDecoration\",\n]);\n\nfunction shouldForwardProp(key: string): boolean {\n if (ADDITIONAL_BLOCKED_PROPS.has(key)) return false;\n return isPropValid(key);\n}\n\n/**\n * Creates a React component that renders the given HTML tag\n * but filters out non-HTML props before they reach the DOM.\n *\n * Uses @emotion/is-prop-valid (same library styled-components v4\n * uses internally) to automatically block invalid HTML attributes,\n * plus a small blocklist for false positives (RN on* handlers, SVG attrs).\n *\n * Usage: `const FilteredDiv = createFilteredElement(\"div\");`\n * Then: `const StyledBox = styled(FilteredDiv)<BoxProps>\\`...\\`;`\n *\n * styled-components can still read ALL props for CSS interpolation,\n * but only valid HTML attributes are forwarded to the DOM element.\n */\nexport function createFilteredElement(defaultTag: string) {\n const Component = React.forwardRef<HTMLElement, Record<string, unknown>>(\n ({ children, elementType, ...props }, ref) => {\n const Tag = (elementType as string) || defaultTag;\n const htmlProps: Record<string, unknown> = {};\n for (const key of Object.keys(props)) {\n if (shouldForwardProp(key)) {\n htmlProps[key] = props[key];\n }\n }\n return React.createElement(\n Tag,\n { ref, ...htmlProps },\n children as React.ReactNode\n );\n }\n );\n Component.displayName = `Filtered(${defaultTag})`;\n return Component;\n}\n","function memoize(fn) {\n var cache = {};\n return function (arg) {\n if (cache[arg] === undefined) cache[arg] = fn(arg);\n return cache[arg];\n };\n}\n\nexport default memoize;\n","import memoize from '@emotion/memoize';\n\nvar reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/; // https://esbench.com/bench/5bfee68a4cd7e6009ef61d23\n\nvar index = memoize(function (prop) {\n return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111\n /* o */\n && prop.charCodeAt(1) === 110\n /* n */\n && prop.charCodeAt(2) < 91;\n}\n/* Z+1 */\n);\n\nexport default index;\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredSpan = createFilteredElement(\"span\");\n\nconst StyledText = styled(FilteredSpan)<TextProps>`\n color: ${(props) => props.color || \"inherit\"};\n font-size: ${(props) =>\n typeof props.fontSize === \"number\"\n ? `${props.fontSize}px`\n : props.fontSize || \"inherit\"};\n font-weight: ${(props) => props.fontWeight || \"normal\"};\n font-family: ${(props) =>\n props.fontFamily ||\n '\"Aktiv Grotesk\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif'};\n line-height: ${(props) =>\n typeof props.lineHeight === \"number\"\n ? `${props.lineHeight}px`\n : props.lineHeight || \"inherit\"};\n white-space: ${(props) => props.whiteSpace || \"normal\"};\n text-align: ${(props) => props.textAlign || \"inherit\"};\n text-decoration: ${(props) => props.textDecoration || \"none\"};\n`;\n\nexport const Text: React.FC<TextProps> = ({\n style,\n className,\n id,\n role,\n testID,\n \"data-testid\": dataTestId,\n numberOfLines: _numberOfLines,\n ...props\n}) => {\n return (\n <StyledText\n {...props}\n style={style}\n className={className}\n id={id}\n role={role}\n data-testid={dataTestId || testID}\n />\n );\n};\n","export * from \"./Box\";\nexport * from \"./Text\";\nexport * from \"./Spinner\";\nexport * from \"./Icon\";\nexport * from \"./Divider\";\nexport * from \"./Input\";\nexport * from \"./TextArea\";\nexport * from \"./LinearGradient\";\n\nexport const isWeb = true;\nexport const isNative = false;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,gBAAoD;;;ACApD,IAAAC,gBAAkB;AAClB,+BAAmB;;;ACDnB,mBAAkB;;;ACAlB,SAAS,QAAQ,IAAI;AACnB,MAAI,QAAQ,CAAC;AACb,SAAO,SAAU,KAAK;AACpB,QAAI,MAAM,GAAG,MAAM,OAAW,OAAM,GAAG,IA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A;AAAA,wBAGN;AAAA,0BAAC;AAAA;AAAA,4BACC,MAAM,OAAO;AAAA,4BACb,OAAO,YAAY;AAAA;AAAA,wBACrB;AAAA;AAAA,oBACF;AAAA;AAAA;AAAA,gBApFK,GAAG,KAAK,IAAI,IAAIA,MAAK;AAAA,cAqF5B,CACD;AAAA;AAAA,UACH;AAAA;AAAA;AAAA,IAEJ;AAAA,EAEJ;AACF;AAEA,iBAAiB,cAAc;","names":["import_react","import_react","React","styled","React","import_styled_components","import_jsx_runtime","styled","import_jsx_runtime","React","index"]}
1
+ {"version":3,"sources":["../../src/index.tsx","../../src/DragDropUploader.tsx","../../../../foundation/primitives-web/src/Box.tsx","../../../../foundation/primitives-web/src/filterDOMProps.ts","../../../../../node_modules/@emotion/memoize/dist/memoize.esm.js","../../../../../node_modules/@emotion/is-prop-valid/dist/is-prop-valid.esm.js","../../../../foundation/primitives-web/src/Text.tsx","../../../../foundation/primitives-web/src/index.tsx"],"sourcesContent":["export * from \"./DragDropUploader\";\n","import React, { forwardRef, useRef, useState } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, isWeb } from \"@xsolla/xui-primitives\";\nimport { useId, useResolvedTheme } from \"@xsolla/xui-core\";\nimport { FileText, FileUploadIn, TrashCan } from \"@xsolla/xui-icons-base\";\nimport type {\n DragDropUploaderFile,\n DragDropUploaderProps,\n DragDropUploaderSize,\n DragDropUploaderVisualState,\n} from \"./types\";\n\nexport type {\n DragDropUploaderFile,\n DragDropUploaderProps,\n DragDropUploaderSize,\n DragDropUploaderVisualState,\n} from \"./types\";\n\nconst DEFAULT_TITLE = \"Click or drag file to this area to upload\";\nconst DEFAULT_DESCRIPTION = \"PDF, DOC, DOCX up to 10MB\";\n\nconst formatFileSize = (size: number) => {\n if (size < 1024) return `${size}B`;\n if (size < 1024 * 1024) return `${Math.round(size / 1024)}KB`;\n return `${Math.round(size / (1024 * 1024))}MB`;\n};\n\nconst normalizeFiles = (files: File[]) =>\n files.map((file) => ({\n name: file.name,\n size: file.size,\n mimeType: file.type || undefined,\n file,\n }));\n\ntype DragDropUploaderSizing = {\n width: number;\n rootGap: number;\n radius: number;\n borderWidth: number;\n areaHeight: number;\n areaPadding: number;\n areaGap: number;\n iconSize: number;\n textGap: number;\n titleFontSize: number;\n titleLineHeight: number;\n descriptionFontSize: number;\n descriptionLineHeight: number;\n errorFontSize: number;\n errorLineHeight: number;\n listGap: number;\n itemGap: number;\n itemPaddingVertical: number;\n itemPaddingLeft: number;\n itemPaddingRight: number;\n itemIconWrapperSize: number;\n itemIconSize: number;\n itemTitleFontSize: number;\n itemTitleLineHeight: number;\n itemDescriptionFontSize: number;\n itemDescriptionLineHeight: number;\n removeIconSize: number;\n};\n\nexport const DragDropUploader = forwardRef<\n HTMLInputElement,\n DragDropUploaderProps\n>(\n (\n {\n size = \"sm\",\n title = DEFAULT_TITLE,\n description = DEFAULT_DESCRIPTION,\n icon,\n errorMessage,\n files,\n defaultFiles = [],\n accept,\n multiple = false,\n disabled = false,\n loading = false,\n width,\n visualState,\n onFilesChange,\n onDropFiles,\n onRemoveFile,\n testID,\n themeMode,\n themeProductContext,\n },\n ref\n ) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const inputRef = useRef<HTMLInputElement>(null);\n const [internalFiles, setInternalFiles] =\n useState<DragDropUploaderFile[]>(defaultFiles);\n const [isHover, setIsHover] = useState(false);\n const [isDragActive, setIsDragActive] = useState(false);\n\n React.useImperativeHandle(\n ref,\n () => inputRef.current as HTMLInputElement,\n []\n );\n\n const isControlled = files !== undefined;\n const selectedFiles = isControlled ? files : internalFiles;\n const hasError = !!errorMessage;\n const isDisabled = disabled || loading;\n const sizing = (\n theme.sizing as typeof theme.sizing & {\n dragDropUploader: (\n size: DragDropUploaderSize\n ) => DragDropUploaderSizing;\n }\n ).dragDropUploader(size);\n const inputColors = theme.colors.control.input;\n const focusColors = theme.colors.control.focus;\n const alertBorder = theme.colors.control.alert.border;\n const alertText = theme.colors.content.alert.primary;\n const rootWidth = width ?? sizing.width;\n const reactId = useId();\n const baseId = `drag-drop-uploader-${reactId.replace(/[^a-zA-Z0-9-]/g, \"\")}`;\n const descriptionId = `${baseId}-description`;\n const errorId = `${baseId}-error`;\n\n let state: DragDropUploaderVisualState = \"default\";\n if (isDisabled) state = \"disabled\";\n else if (hasError) state = \"error\";\n else if (isDragActive) state = \"drag\";\n else if (isHover) state = \"hover\";\n if (visualState) state = visualState;\n\n const setNextFiles = (\n nextFiles: DragDropUploaderFile[],\n pickedFiles?: DragDropUploaderFile[]\n ) => {\n if (!isControlled) setInternalFiles(nextFiles);\n onDropFiles?.(pickedFiles ?? nextFiles);\n onFilesChange?.(nextFiles);\n };\n\n const appendFiles = (pickedFiles: DragDropUploaderFile[]) => {\n if (pickedFiles.length === 0) return;\n const nextFiles = multiple\n ? [...selectedFiles, ...pickedFiles]\n : pickedFiles.slice(0, 1);\n setNextFiles(nextFiles, pickedFiles);\n };\n\n const removeFile = (index: number) => {\n const file = selectedFiles[index];\n if (!file || isDisabled) return;\n const nextFiles = selectedFiles.filter(\n (_, itemIndex) => itemIndex !== index\n );\n if (!isControlled) setInternalFiles(nextFiles);\n onRemoveFile?.(file, index);\n onFilesChange?.(nextFiles);\n if (isWeb && inputRef.current) inputRef.current.value = \"\";\n };\n\n const handleClick = () => {\n if (!isWeb || isDisabled) return;\n inputRef.current?.click();\n };\n\n const handleFileChange = (event: React.ChangeEvent<HTMLInputElement>) => {\n const nextFiles = Array.from(event.target.files ?? []);\n event.target.value = \"\";\n appendFiles(normalizeFiles(nextFiles));\n };\n\n const handleDragOver = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n if (!isDisabled) setIsDragActive(true);\n };\n\n const handleDragLeave = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n setIsDragActive(false);\n };\n\n const handleDrop = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n setIsDragActive(false);\n if (isDisabled) return;\n appendFiles(normalizeFiles(Array.from(event.dataTransfer.files ?? [])));\n };\n\n let backgroundColor = inputColors.bg;\n let borderColor = inputColors.border;\n let titleColor = inputColors.text;\n let descriptionColor = inputColors.placeholder;\n let iconColor = theme.colors.content.brand.primary;\n\n switch (state) {\n case \"hover\":\n backgroundColor = inputColors.bgHover;\n borderColor = inputColors.border;\n break;\n case \"drag\":\n backgroundColor = focusColors.bg;\n borderColor = focusColors.border;\n break;\n case \"disabled\":\n backgroundColor = inputColors.bgDisable;\n borderColor = inputColors.borderDisable;\n titleColor = inputColors.textDisable;\n descriptionColor = inputColors.textDisable;\n iconColor = inputColors.textDisable;\n break;\n case \"error\":\n borderColor = alertBorder;\n break;\n }\n\n const describedBy =\n [description ? descriptionId : null, errorMessage ? errorId : null]\n .filter(Boolean)\n .join(\" \") || undefined;\n\n const webAreaProps = isWeb\n ? {\n \"aria-describedby\": describedBy,\n \"aria-disabled\": isDisabled || undefined,\n \"aria-invalid\": hasError || undefined,\n onMouseEnter: () => {\n if (!isDisabled) setIsHover(true);\n },\n onMouseLeave: () => setIsHover(false),\n onDragOver: handleDragOver,\n onDragLeave: handleDragLeave,\n onDrop: handleDrop,\n style: {\n boxSizing: \"border-box\" as const,\n cursor: isDisabled ? \"not-allowed\" : \"pointer\",\n outline: \"none\",\n transition: \"background-color 0.15s ease, border-color 0.15s ease\",\n },\n }\n : {};\n\n return (\n <Box\n testID={testID || \"drag-drop-uploader\"}\n flexDirection=\"column\"\n gap={sizing.rootGap}\n alignItems=\"flex-start\"\n width={rootWidth}\n >\n {isWeb && (\n <input\n type=\"file\"\n ref={inputRef}\n accept={accept}\n multiple={multiple}\n onChange={handleFileChange}\n style={{ display: \"none\" }}\n disabled={isDisabled}\n tabIndex={-1}\n aria-hidden=\"true\"\n data-testid=\"drag-drop-uploader__input\"\n />\n )}\n\n <Box\n as={isWeb ? \"button\" : \"div\"}\n disabled={isDisabled}\n data-testid=\"drag-drop-uploader__area\"\n onPress={handleClick}\n flexDirection=\"column\"\n alignItems=\"center\"\n justifyContent=\"center\"\n width=\"100%\"\n height={sizing.areaHeight}\n gap={sizing.areaGap}\n padding={sizing.areaPadding}\n borderRadius={sizing.radius}\n borderWidth={sizing.borderWidth}\n borderColor={borderColor}\n borderStyle=\"dashed\"\n backgroundColor={backgroundColor}\n {...webAreaProps}\n >\n <Box {...(isWeb && { \"aria-hidden\": \"true\" })}>\n {icon ?? <FileUploadIn size={sizing.iconSize} color={iconColor} />}\n </Box>\n\n {(title || description) && (\n <Box\n flexDirection=\"column\"\n gap={sizing.textGap}\n width=\"100%\"\n alignItems=\"center\"\n >\n {title &&\n (typeof title === \"string\" ? (\n <Text\n color={titleColor}\n fontSize={sizing.titleFontSize}\n lineHeight={sizing.titleLineHeight}\n fontWeight=\"500\"\n textAlign=\"center\"\n numberOfLines={2}\n >\n {title}\n </Text>\n ) : (\n <Box>{title}</Box>\n ))}\n\n {description &&\n (typeof description === \"string\" ? (\n <Text\n id={descriptionId}\n color={descriptionColor}\n fontSize={sizing.descriptionFontSize}\n lineHeight={sizing.descriptionLineHeight}\n textAlign=\"center\"\n numberOfLines={2}\n >\n {description}\n </Text>\n ) : (\n <Box id={descriptionId}>{description}</Box>\n ))}\n </Box>\n )}\n </Box>\n\n {errorMessage && (\n <Text\n id={errorId}\n role=\"alert\"\n data-testid=\"drag-drop-uploader__error\"\n color={alertText}\n fontSize={sizing.errorFontSize}\n lineHeight={sizing.errorLineHeight}\n >\n {errorMessage}\n </Text>\n )}\n\n {selectedFiles.length > 0 && (\n <Box\n data-testid=\"drag-drop-uploader__list\"\n flexDirection=\"column\"\n gap={sizing.listGap}\n width=\"100%\"\n >\n {selectedFiles.map((file, index) => (\n <Box\n key={`${file.name}-${index}`}\n data-testid=\"drag-drop-uploader__file\"\n flexDirection=\"row\"\n alignItems=\"center\"\n gap={sizing.itemGap}\n width=\"100%\"\n paddingVertical={sizing.itemPaddingVertical}\n paddingLeft={sizing.itemPaddingLeft}\n paddingRight={sizing.itemPaddingRight}\n borderRadius={sizing.radius}\n borderWidth={sizing.borderWidth}\n borderColor={inputColors.border}\n backgroundColor={inputColors.bg}\n style={isWeb ? { boxSizing: \"border-box\" } : undefined}\n >\n <Box\n alignItems=\"center\"\n justifyContent=\"center\"\n width={sizing.itemIconWrapperSize}\n height={sizing.itemIconWrapperSize}\n borderRadius={sizing.radius}\n backgroundColor={theme.colors.overlay.mono}\n {...(isWeb && { \"aria-hidden\": \"true\" })}\n >\n <FileText\n size={sizing.itemIconSize}\n color={inputColors.placeholder}\n />\n </Box>\n\n <Box flexDirection=\"column\" gap={2} flex={1} minWidth={0}>\n <Text\n color={inputColors.text}\n fontSize={sizing.itemTitleFontSize}\n lineHeight={sizing.itemTitleLineHeight}\n numberOfLines={1}\n style={\n isWeb\n ? {\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }\n : undefined\n }\n >\n {file.name}\n </Text>\n <Text\n color={inputColors.placeholder}\n fontSize={sizing.itemDescriptionFontSize}\n lineHeight={sizing.itemDescriptionLineHeight}\n numberOfLines={1}\n >\n {formatFileSize(file.size)}\n </Text>\n </Box>\n\n <Box\n as={isWeb ? \"button\" : \"div\"}\n data-testid=\"drag-drop-uploader__remove\"\n aria-label={`Remove ${file.name}`}\n disabled={isDisabled}\n onPress={(event?: { stopPropagation?: () => void }) => {\n event?.stopPropagation?.();\n removeFile(index);\n }}\n padding={0}\n alignItems=\"center\"\n justifyContent=\"center\"\n style={\n isWeb\n ? {\n border: \"none\",\n background: \"transparent\",\n cursor: isDisabled ? \"not-allowed\" : \"pointer\",\n }\n : undefined\n }\n >\n <TrashCan\n size={sizing.removeIconSize}\n color={inputColors.placeholder}\n />\n </Box>\n </Box>\n ))}\n </Box>\n )}\n </Box>\n );\n }\n);\n\nDragDropUploader.displayName = \"DragDropUploader\";\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport type { BoxProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledBox = styled(FilteredDiv)<BoxProps>`\n display: flex;\n box-sizing: border-box;\n background-color: ${(props) => props.backgroundColor || \"transparent\"};\n border-color: ${(props) => props.borderColor || \"transparent\"};\n border-width: ${(props) =>\n typeof props.borderWidth === \"number\"\n ? `${props.borderWidth}px`\n : props.borderWidth || 0};\n\n ${(props) =>\n props.borderBottomWidth !== undefined &&\n `\n border-bottom-width: ${typeof props.borderBottomWidth === \"number\" ? `${props.borderBottomWidth}px` : props.borderBottomWidth};\n border-bottom-color: ${props.borderBottomColor || props.borderColor || \"transparent\"};\n border-bottom-style: solid;\n `}\n ${(props) =>\n props.borderTopWidth !== undefined &&\n `\n border-top-width: ${typeof props.borderTopWidth === \"number\" ? `${props.borderTopWidth}px` : props.borderTopWidth};\n border-top-color: ${props.borderTopColor || props.borderColor || \"transparent\"};\n border-top-style: solid;\n `}\n ${(props) =>\n props.borderLeftWidth !== undefined &&\n `\n border-left-width: ${typeof props.borderLeftWidth === \"number\" ? `${props.borderLeftWidth}px` : props.borderLeftWidth};\n border-left-color: ${props.borderLeftColor || props.borderColor || \"transparent\"};\n border-left-style: solid;\n `}\n ${(props) =>\n props.borderRightWidth !== undefined &&\n `\n border-right-width: ${typeof props.borderRightWidth === \"number\" ? `${props.borderRightWidth}px` : props.borderRightWidth};\n border-right-color: ${props.borderRightColor || props.borderColor || \"transparent\"};\n border-right-style: solid;\n `}\n\n border-style: ${(props) =>\n props.borderStyle ||\n (props.borderWidth ||\n props.borderBottomWidth ||\n props.borderTopWidth ||\n props.borderLeftWidth ||\n props.borderRightWidth\n ? \"solid\"\n : \"none\")};\n border-radius: ${(props) =>\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius || 0};\n height: ${(props) =>\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height || \"auto\"};\n width: ${(props) =>\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width || \"auto\"};\n min-width: ${(props) =>\n typeof props.minWidth === \"number\"\n ? `${props.minWidth}px`\n : props.minWidth || \"auto\"};\n min-height: ${(props) =>\n typeof props.minHeight === \"number\"\n ? `${props.minHeight}px`\n : props.minHeight || \"auto\"};\n max-width: ${(props) =>\n typeof props.maxWidth === \"number\"\n ? `${props.maxWidth}px`\n : props.maxWidth || \"none\"};\n max-height: ${(props) =>\n typeof props.maxHeight === \"number\"\n ? `${props.maxHeight}px`\n : props.maxHeight || \"none\"};\n\n padding: ${(props) =>\n typeof props.padding === \"number\"\n ? `${props.padding}px`\n : props.padding || 0};\n ${(props) =>\n props.paddingHorizontal &&\n `\n padding-left: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n padding-right: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n `}\n ${(props) =>\n props.paddingVertical &&\n `\n padding-top: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n padding-bottom: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n `}\n ${(props) =>\n props.paddingTop !== undefined &&\n `padding-top: ${typeof props.paddingTop === \"number\" ? `${props.paddingTop}px` : props.paddingTop};`}\n ${(props) =>\n props.paddingBottom !== undefined &&\n `padding-bottom: ${typeof props.paddingBottom === \"number\" ? `${props.paddingBottom}px` : props.paddingBottom};`}\n ${(props) =>\n props.paddingLeft !== undefined &&\n `padding-left: ${typeof props.paddingLeft === \"number\" ? `${props.paddingLeft}px` : props.paddingLeft};`}\n ${(props) =>\n props.paddingRight !== undefined &&\n `padding-right: ${typeof props.paddingRight === \"number\" ? `${props.paddingRight}px` : props.paddingRight};`}\n\n margin: ${(props) =>\n typeof props.margin === \"number\" ? `${props.margin}px` : props.margin || 0};\n ${(props) =>\n props.marginTop !== undefined &&\n `margin-top: ${typeof props.marginTop === \"number\" ? `${props.marginTop}px` : props.marginTop};`}\n ${(props) =>\n props.marginBottom !== undefined &&\n `margin-bottom: ${typeof props.marginBottom === \"number\" ? `${props.marginBottom}px` : props.marginBottom};`}\n ${(props) =>\n props.marginLeft !== undefined &&\n `margin-left: ${typeof props.marginLeft === \"number\" ? `${props.marginLeft}px` : props.marginLeft};`}\n ${(props) =>\n props.marginRight !== undefined &&\n `margin-right: ${typeof props.marginRight === \"number\" ? `${props.marginRight}px` : props.marginRight};`}\n\n flex-direction: ${(props) => props.flexDirection || \"column\"};\n flex-wrap: ${(props) => props.flexWrap || \"nowrap\"};\n align-items: ${(props) => props.alignItems || \"stretch\"};\n justify-content: ${(props) => props.justifyContent || \"flex-start\"};\n cursor: ${(props) =>\n props.cursor\n ? props.cursor\n : props.onClick || props.onPress\n ? \"pointer\"\n : \"inherit\"};\n position: ${(props) => props.position || \"static\"};\n top: ${(props) =>\n typeof props.top === \"number\" ? `${props.top}px` : props.top};\n bottom: ${(props) =>\n typeof props.bottom === \"number\" ? `${props.bottom}px` : props.bottom};\n left: ${(props) =>\n typeof props.left === \"number\" ? `${props.left}px` : props.left};\n right: ${(props) =>\n typeof props.right === \"number\" ? `${props.right}px` : props.right};\n flex: ${(props) => props.flex};\n flex-shrink: ${(props) => props.flexShrink ?? 1};\n gap: ${(props) =>\n typeof props.gap === \"number\" ? `${props.gap}px` : props.gap || 0};\n align-self: ${(props) => props.alignSelf || \"auto\"};\n overflow: ${(props) => props.overflow || \"visible\"};\n overflow-x: ${(props) => props.overflowX || \"visible\"};\n overflow-y: ${(props) => props.overflowY || \"visible\"};\n z-index: ${(props) => props.zIndex};\n opacity: ${(props) => (props.disabled ? 0.5 : 1)};\n pointer-events: ${(props) => (props.disabled ? \"none\" : \"auto\")};\n\n &:hover {\n ${(props) =>\n props.hoverStyle?.backgroundColor &&\n `background-color: ${props.hoverStyle.backgroundColor};`}\n ${(props) =>\n props.hoverStyle?.borderColor &&\n `border-color: ${props.hoverStyle.borderColor};`}\n }\n\n &:active {\n ${(props) =>\n props.pressStyle?.backgroundColor &&\n `background-color: ${props.pressStyle.backgroundColor};`}\n }\n`;\n\nexport const Box = React.forwardRef<\n HTMLDivElement | HTMLButtonElement,\n BoxProps\n>(\n (\n {\n children,\n onPress,\n onKeyDown,\n onKeyUp,\n role,\n \"aria-label\": ariaLabel,\n \"aria-labelledby\": ariaLabelledBy,\n \"aria-current\": ariaCurrent,\n \"aria-disabled\": ariaDisabled,\n \"aria-live\": ariaLive,\n \"aria-busy\": ariaBusy,\n \"aria-describedby\": ariaDescribedBy,\n \"aria-expanded\": ariaExpanded,\n \"aria-haspopup\": ariaHasPopup,\n \"aria-pressed\": ariaPressed,\n \"aria-controls\": ariaControls,\n tabIndex,\n as,\n src,\n alt,\n onError,\n onLoad,\n type,\n disabled,\n id,\n testID,\n \"data-testid\": dataTestId,\n ...props\n },\n ref\n ) => {\n // Handle as=\"img\" for rendering images with proper border-radius\n if (as === \"img\" && src) {\n return (\n <img\n src={src}\n alt={alt || \"\"}\n onError={onError}\n onLoad={onLoad}\n style={{\n display: \"block\",\n objectFit: \"cover\",\n width:\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width,\n height:\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height,\n borderRadius:\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius,\n position: props.position,\n top: typeof props.top === \"number\" ? `${props.top}px` : props.top,\n left:\n typeof props.left === \"number\" ? `${props.left}px` : props.left,\n right:\n typeof props.right === \"number\"\n ? `${props.right}px`\n : props.right,\n bottom:\n typeof props.bottom === \"number\"\n ? `${props.bottom}px`\n : props.bottom,\n ...props.style,\n }}\n />\n );\n }\n\n return (\n <StyledBox\n ref={ref}\n elementType={as}\n id={id}\n type={as === \"button\" ? type || \"button\" : undefined}\n disabled={as === \"button\" ? disabled : undefined}\n onClick={onPress}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n role={role}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n aria-current={ariaCurrent}\n aria-disabled={ariaDisabled}\n aria-busy={ariaBusy}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n aria-haspopup={ariaHasPopup}\n aria-pressed={ariaPressed}\n aria-controls={ariaControls}\n aria-live={ariaLive}\n tabIndex={tabIndex !== undefined ? tabIndex : undefined}\n data-testid={dataTestId || testID}\n {...props}\n >\n {children}\n </StyledBox>\n );\n }\n);\n\nBox.displayName = \"Box\";\n","import React from \"react\";\nimport isPropValid from \"@emotion/is-prop-valid\";\n\n// Props that @emotion/is-prop-valid incorrectly treats as valid HTML.\n// These are React Native or component-specific props that match\n// valid HTML patterns (on* event handlers, SVG attributes).\nexport const ADDITIONAL_BLOCKED_PROPS = new Set([\n // RN-only event handlers (pass isPropValid's on* pattern)\n \"onPress\",\n \"onChangeText\",\n \"onLayout\",\n \"onMoveShouldSetResponder\",\n \"onResponderGrant\",\n \"onResponderMove\",\n \"onResponderRelease\",\n \"onResponderTerminate\",\n // SVG attributes that pass isPropValid\n \"strokeWidth\",\n // CSS properties that pass isPropValid but are used as component props\n \"overflow\",\n \"cursor\",\n \"fontSize\",\n \"fontWeight\",\n \"fontFamily\",\n \"textDecoration\",\n]);\n\nfunction shouldForwardProp(key: string): boolean {\n if (ADDITIONAL_BLOCKED_PROPS.has(key)) return false;\n return isPropValid(key);\n}\n\n/**\n * Creates a React component that renders the given HTML tag\n * but filters out non-HTML props before they reach the DOM.\n *\n * Uses @emotion/is-prop-valid (same library styled-components v4\n * uses internally) to automatically block invalid HTML attributes,\n * plus a small blocklist for false positives (RN on* handlers, SVG attrs).\n *\n * Usage: `const FilteredDiv = createFilteredElement(\"div\");`\n * Then: `const StyledBox = styled(FilteredDiv)<BoxProps>\\`...\\`;`\n *\n * styled-components can still read ALL props for CSS interpolation,\n * but only valid HTML attributes are forwarded to the DOM element.\n */\nexport function createFilteredElement(defaultTag: string) {\n const Component = React.forwardRef<HTMLElement, Record<string, unknown>>(\n ({ children, elementType, ...props }, ref) => {\n const Tag = (elementType as string) || defaultTag;\n const htmlProps: Record<string, unknown> = {};\n for (const key of Object.keys(props)) {\n if (shouldForwardProp(key)) {\n htmlProps[key] = props[key];\n }\n }\n return React.createElement(\n Tag,\n { ref, ...htmlProps },\n children as React.ReactNode\n );\n }\n );\n Component.displayName = `Filtered(${defaultTag})`;\n return Component;\n}\n","function memoize(fn) {\n var cache = {};\n return function (arg) {\n if (cache[arg] === undefined) cache[arg] = fn(arg);\n return cache[arg];\n };\n}\n\nexport default memoize;\n","import memoize from '@emotion/memoize';\n\nvar reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/; // https://esbench.com/bench/5bfee68a4cd7e6009ef61d23\n\nvar index = memoize(function (prop) {\n return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111\n /* o */\n && prop.charCodeAt(1) === 110\n /* n */\n && prop.charCodeAt(2) < 91;\n}\n/* Z+1 */\n);\n\nexport default index;\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredSpan = createFilteredElement(\"span\");\n\nconst StyledText = styled(FilteredSpan)<TextProps>`\n color: ${(props) => props.color || \"inherit\"};\n font-size: ${(props) =>\n typeof props.fontSize === \"number\"\n ? `${props.fontSize}px`\n : props.fontSize || \"inherit\"};\n font-weight: ${(props) => props.fontWeight || \"normal\"};\n font-family: ${(props) =>\n props.fontFamily ||\n '\"Aktiv Grotesk\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif'};\n line-height: ${(props) =>\n typeof props.lineHeight === \"number\"\n ? `${props.lineHeight}px`\n : props.lineHeight || \"inherit\"};\n white-space: ${(props) => props.whiteSpace || \"normal\"};\n text-align: ${(props) => props.textAlign || \"inherit\"};\n text-decoration: ${(props) => props.textDecoration || \"none\"};\n`;\n\nexport const Text: React.FC<TextProps> = ({\n style,\n className,\n id,\n role,\n testID,\n \"data-testid\": dataTestId,\n numberOfLines: _numberOfLines,\n ...props\n}) => {\n return (\n <StyledText\n {...props}\n style={style}\n className={className}\n id={id}\n role={role}\n data-testid={dataTestId || testID}\n />\n );\n};\n","export * from \"./Box\";\nexport * from \"./Text\";\nexport * from \"./Spinner\";\nexport * from \"./Icon\";\nexport * from \"./Divider\";\nexport * from \"./Input\";\nexport * from \"./TextArea\";\nexport * from \"./LinearGradient\";\n\nexport const isWeb = true;\nexport const isNative = false;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,gBAAoD;;;ACApD,IAAAC,gBAAkB;AAClB,+BAAmB;;;ACDnB,mBAAkB;;;ACAlB,SAAS,QAAQ,IAAI;AACnB,MAAI,QAAQ,CAAC;AACb,SAAO,SAAU,KAAK;AACpB,QAAI,MAAM,GAAG,MAAM,OAAW,OAAM,GAAG,IAAI,GAAG,GAAG;AACjD,WAAO,MAAM,GAAG;AAAA,EAClB;AACF;AAEA,IAAO,sBAAQ;;;ACNf,IAAI,kBAAkB;AAEtB,IAAI,QAAQ;AAAA,EAAQ,SAAU,MAAM;AAClC,WAAO,gBAAgB,KAAK,IAAI,KAAK,KAAK,WAAW,CAAC,MAAM,OAEzD,KAAK,WAAW,CAAC,MAAM,OAEvB,KAAK,WAAW,CAAC,IAAI;AAAA,EAC1B;AAAA;AAEA;AAEA,IAAO,4BAAQ;;;AFRR,IAAM,2BAA2B,oBAAI,IAAI;AAAA;AAAA,EAE9C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA,EAEA;AAAA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,CAAC;AAED,SAAS,kBAAkB,KAAsB;AAC/C,MAAI,yBAAyB,IAAI,GAAG,EAAG,QAAO;AAC9C,SAAO,0BAAY,GAAG;AACxB;AAgBO,SAAS,sBAAsB,YAAoB;AACxD,QAAM,YAAY,aAAAC,QAAM;AAAA,IACtB,CAAC,EAAE,UAAU,aAAa,GAAG,MAA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jB,YAAY,OAAO;AAAA,0BACnB,eAAe;AAAA,0BAEd,yBAAe,KAAK,IAAI;AAAA;AAAA,sBAC3B;AAAA,uBACF;AAAA,oBAEA;AAAA,sBAAC;AAAA;AAAA,wBACC,IAAI,QAAQ,WAAW;AAAA,wBACvB,eAAY;AAAA,wBACZ,cAAY,UAAU,KAAK,IAAI;AAAA,wBAC/B,UAAU;AAAA,wBACV,SAAS,CAAC,UAA6C;AACrD,iCAAO,kBAAkB;AACzB,qCAAWA,MAAK;AAAA,wBAClB;AAAA,wBACA,SAAS;AAAA,wBACT,YAAW;AAAA,wBACX,gBAAe;AAAA,wBACf,OACE,QACI;AAAA,0BACE,QAAQ;AAAA,0BACR,YAAY;AAAA,0BACZ,QAAQ,aAAa,gBAAgB;AAAA,wBACvC,IACA;AAAA,wBAGN;AAAA,0BAAC;AAAA;AAAA,4BACC,MAAM,OAAO;AAAA,4BACb,OAAO,YAAY;AAAA;AAAA,wBACrB;AAAA;AAAA,oBACF;AAAA;AAAA;AAAA,gBApFK,GAAG,KAAK,IAAI,IAAIA,MAAK;AAAA,cAqF5B,CACD;AAAA;AAAA,UACH;AAAA;AAAA;AAAA,IAEJ;AAAA,EAEJ;AACF;AAEA,iBAAiB,cAAc;","names":["import_react","import_react","React","styled","React","import_styled_components","import_jsx_runtime","styled","import_jsx_runtime","React","index"]}
package/web/index.mjs CHANGED
@@ -294,7 +294,7 @@ var isWeb = true;
294
294
 
295
295
  // src/DragDropUploader.tsx
296
296
  import { useId, useResolvedTheme } from "@xsolla/xui-core";
297
- import { FileExportOu, FileText, TrashCan } from "@xsolla/xui-icons-base";
297
+ import { FileText, FileUploadIn, TrashCan } from "@xsolla/xui-icons-base";
298
298
  import { jsx as jsx3, jsxs } from "react/jsx-runtime";
299
299
  var DEFAULT_TITLE = "Click or drag file to this area to upload";
300
300
  var DEFAULT_DESCRIPTION = "PDF, DOC, DOCX up to 10MB";
@@ -314,6 +314,7 @@ var DragDropUploader = forwardRef(
314
314
  size = "sm",
315
315
  title = DEFAULT_TITLE,
316
316
  description = DEFAULT_DESCRIPTION,
317
+ icon,
317
318
  errorMessage,
318
319
  files,
319
320
  defaultFiles = [],
@@ -496,7 +497,7 @@ var DragDropUploader = forwardRef(
496
497
  backgroundColor,
497
498
  ...webAreaProps,
498
499
  children: [
499
- /* @__PURE__ */ jsx3(Box, { ...isWeb && { "aria-hidden": "true" }, children: /* @__PURE__ */ jsx3(FileExportOu, { size: sizing.iconSize, color: iconColor }) }),
500
+ /* @__PURE__ */ jsx3(Box, { ...isWeb && { "aria-hidden": "true" }, children: icon ?? /* @__PURE__ */ jsx3(FileUploadIn, { size: sizing.iconSize, color: iconColor }) }),
500
501
  (title || description) && /* @__PURE__ */ jsxs(
501
502
  Box,
502
503
  {
package/web/index.mjs.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/DragDropUploader.tsx","../../../../foundation/primitives-web/src/Box.tsx","../../../../foundation/primitives-web/src/filterDOMProps.ts","../../../../../node_modules/@emotion/memoize/dist/memoize.esm.js","../../../../../node_modules/@emotion/is-prop-valid/dist/is-prop-valid.esm.js","../../../../foundation/primitives-web/src/Text.tsx","../../../../foundation/primitives-web/src/index.tsx"],"sourcesContent":["import React, { forwardRef, useRef, useState } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, isWeb } from \"@xsolla/xui-primitives\";\nimport { useId, useResolvedTheme } from \"@xsolla/xui-core\";\nimport { FileExportOu, FileText, TrashCan } from \"@xsolla/xui-icons-base\";\nimport type {\n DragDropUploaderFile,\n DragDropUploaderProps,\n DragDropUploaderSize,\n DragDropUploaderVisualState,\n} from \"./types\";\n\nexport type {\n DragDropUploaderFile,\n DragDropUploaderProps,\n DragDropUploaderSize,\n DragDropUploaderVisualState,\n} from \"./types\";\n\nconst DEFAULT_TITLE = \"Click or drag file to this area to upload\";\nconst DEFAULT_DESCRIPTION = \"PDF, DOC, DOCX up to 10MB\";\n\nconst formatFileSize = (size: number) => {\n if (size < 1024) return `${size}B`;\n if (size < 1024 * 1024) return `${Math.round(size / 1024)}KB`;\n return `${Math.round(size / (1024 * 1024))}MB`;\n};\n\nconst normalizeFiles = (files: File[]) =>\n files.map((file) => ({\n name: file.name,\n size: file.size,\n mimeType: file.type || undefined,\n file,\n }));\n\ntype DragDropUploaderSizing = {\n width: number;\n rootGap: number;\n radius: number;\n borderWidth: number;\n areaHeight: number;\n areaPadding: number;\n areaGap: number;\n iconSize: number;\n textGap: number;\n titleFontSize: number;\n titleLineHeight: number;\n descriptionFontSize: number;\n descriptionLineHeight: number;\n errorFontSize: number;\n errorLineHeight: number;\n listGap: number;\n itemGap: number;\n itemPaddingVertical: number;\n itemPaddingLeft: number;\n itemPaddingRight: number;\n itemIconWrapperSize: number;\n itemIconSize: number;\n itemTitleFontSize: number;\n itemTitleLineHeight: number;\n itemDescriptionFontSize: number;\n itemDescriptionLineHeight: number;\n removeIconSize: number;\n};\n\nexport const DragDropUploader = forwardRef<\n HTMLInputElement,\n DragDropUploaderProps\n>(\n (\n {\n size = \"sm\",\n title = DEFAULT_TITLE,\n description = DEFAULT_DESCRIPTION,\n errorMessage,\n files,\n defaultFiles = [],\n accept,\n multiple = false,\n disabled = false,\n loading = false,\n width,\n visualState,\n onFilesChange,\n onDropFiles,\n onRemoveFile,\n testID,\n themeMode,\n themeProductContext,\n },\n ref\n ) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const inputRef = useRef<HTMLInputElement>(null);\n const [internalFiles, setInternalFiles] =\n useState<DragDropUploaderFile[]>(defaultFiles);\n const [isHover, setIsHover] = useState(false);\n const [isDragActive, setIsDragActive] = useState(false);\n\n React.useImperativeHandle(\n ref,\n () => inputRef.current as HTMLInputElement,\n []\n );\n\n const isControlled = files !== undefined;\n const selectedFiles = isControlled ? files : internalFiles;\n const hasError = !!errorMessage;\n const isDisabled = disabled || loading;\n const sizing = (\n theme.sizing as typeof theme.sizing & {\n dragDropUploader: (\n size: DragDropUploaderSize\n ) => DragDropUploaderSizing;\n }\n ).dragDropUploader(size);\n const inputColors = theme.colors.control.input;\n const focusColors = theme.colors.control.focus;\n const alertBorder = theme.colors.control.alert.border;\n const alertText = theme.colors.content.alert.primary;\n const rootWidth = width ?? sizing.width;\n const reactId = useId();\n const baseId = `drag-drop-uploader-${reactId.replace(/[^a-zA-Z0-9-]/g, \"\")}`;\n const descriptionId = `${baseId}-description`;\n const errorId = `${baseId}-error`;\n\n let state: DragDropUploaderVisualState = \"default\";\n if (isDisabled) state = \"disabled\";\n else if (hasError) state = \"error\";\n else if (isDragActive) state = \"drag\";\n else if (isHover) state = \"hover\";\n if (visualState) state = visualState;\n\n const setNextFiles = (\n nextFiles: DragDropUploaderFile[],\n pickedFiles?: DragDropUploaderFile[]\n ) => {\n if (!isControlled) setInternalFiles(nextFiles);\n onDropFiles?.(pickedFiles ?? nextFiles);\n onFilesChange?.(nextFiles);\n };\n\n const appendFiles = (pickedFiles: DragDropUploaderFile[]) => {\n if (pickedFiles.length === 0) return;\n const nextFiles = multiple\n ? [...selectedFiles, ...pickedFiles]\n : pickedFiles.slice(0, 1);\n setNextFiles(nextFiles, pickedFiles);\n };\n\n const removeFile = (index: number) => {\n const file = selectedFiles[index];\n if (!file || isDisabled) return;\n const nextFiles = selectedFiles.filter(\n (_, itemIndex) => itemIndex !== index\n );\n if (!isControlled) setInternalFiles(nextFiles);\n onRemoveFile?.(file, index);\n onFilesChange?.(nextFiles);\n if (isWeb && inputRef.current) inputRef.current.value = \"\";\n };\n\n const handleClick = () => {\n if (!isWeb || isDisabled) return;\n inputRef.current?.click();\n };\n\n const handleFileChange = (event: React.ChangeEvent<HTMLInputElement>) => {\n const nextFiles = Array.from(event.target.files ?? []);\n event.target.value = \"\";\n appendFiles(normalizeFiles(nextFiles));\n };\n\n const handleDragOver = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n if (!isDisabled) setIsDragActive(true);\n };\n\n const handleDragLeave = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n setIsDragActive(false);\n };\n\n const handleDrop = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n setIsDragActive(false);\n if (isDisabled) return;\n appendFiles(normalizeFiles(Array.from(event.dataTransfer.files ?? [])));\n };\n\n let backgroundColor = inputColors.bg;\n let borderColor = inputColors.border;\n let titleColor = inputColors.text;\n let descriptionColor = inputColors.placeholder;\n let iconColor = theme.colors.content.brand.primary;\n\n switch (state) {\n case \"hover\":\n backgroundColor = inputColors.bgHover;\n borderColor = inputColors.border;\n break;\n case \"drag\":\n backgroundColor = focusColors.bg;\n borderColor = focusColors.border;\n break;\n case \"disabled\":\n backgroundColor = inputColors.bgDisable;\n borderColor = inputColors.borderDisable;\n titleColor = inputColors.textDisable;\n descriptionColor = inputColors.textDisable;\n iconColor = inputColors.textDisable;\n break;\n case \"error\":\n borderColor = alertBorder;\n break;\n }\n\n const describedBy =\n [description ? descriptionId : null, errorMessage ? errorId : null]\n .filter(Boolean)\n .join(\" \") || undefined;\n\n const webAreaProps = isWeb\n ? {\n \"aria-describedby\": describedBy,\n \"aria-disabled\": isDisabled || undefined,\n \"aria-invalid\": hasError || undefined,\n onMouseEnter: () => {\n if (!isDisabled) setIsHover(true);\n },\n onMouseLeave: () => setIsHover(false),\n onDragOver: handleDragOver,\n onDragLeave: handleDragLeave,\n onDrop: handleDrop,\n style: {\n boxSizing: \"border-box\" as const,\n cursor: isDisabled ? \"not-allowed\" : \"pointer\",\n outline: \"none\",\n transition: \"background-color 0.15s ease, border-color 0.15s ease\",\n },\n }\n : {};\n\n return (\n <Box\n testID={testID || \"drag-drop-uploader\"}\n flexDirection=\"column\"\n gap={sizing.rootGap}\n alignItems=\"flex-start\"\n width={rootWidth}\n >\n {isWeb && (\n <input\n type=\"file\"\n ref={inputRef}\n accept={accept}\n multiple={multiple}\n onChange={handleFileChange}\n style={{ display: \"none\" }}\n disabled={isDisabled}\n tabIndex={-1}\n aria-hidden=\"true\"\n data-testid=\"drag-drop-uploader__input\"\n />\n )}\n\n <Box\n as={isWeb ? \"button\" : \"div\"}\n disabled={isDisabled}\n data-testid=\"drag-drop-uploader__area\"\n onPress={handleClick}\n flexDirection=\"column\"\n alignItems=\"center\"\n justifyContent=\"center\"\n width=\"100%\"\n height={sizing.areaHeight}\n gap={sizing.areaGap}\n padding={sizing.areaPadding}\n borderRadius={sizing.radius}\n borderWidth={sizing.borderWidth}\n borderColor={borderColor}\n borderStyle=\"dashed\"\n backgroundColor={backgroundColor}\n {...webAreaProps}\n >\n <Box {...(isWeb && { \"aria-hidden\": \"true\" })}>\n <FileExportOu size={sizing.iconSize} color={iconColor} />\n </Box>\n\n {(title || description) && (\n <Box\n flexDirection=\"column\"\n gap={sizing.textGap}\n width=\"100%\"\n alignItems=\"center\"\n >\n {title &&\n (typeof title === \"string\" ? (\n <Text\n color={titleColor}\n fontSize={sizing.titleFontSize}\n lineHeight={sizing.titleLineHeight}\n fontWeight=\"500\"\n textAlign=\"center\"\n numberOfLines={2}\n >\n {title}\n </Text>\n ) : (\n <Box>{title}</Box>\n ))}\n\n {description &&\n (typeof description === \"string\" ? (\n <Text\n id={descriptionId}\n color={descriptionColor}\n fontSize={sizing.descriptionFontSize}\n lineHeight={sizing.descriptionLineHeight}\n textAlign=\"center\"\n numberOfLines={2}\n >\n {description}\n </Text>\n ) : (\n <Box id={descriptionId}>{description}</Box>\n ))}\n </Box>\n )}\n </Box>\n\n {errorMessage && (\n <Text\n id={errorId}\n role=\"alert\"\n data-testid=\"drag-drop-uploader__error\"\n color={alertText}\n fontSize={sizing.errorFontSize}\n lineHeight={sizing.errorLineHeight}\n >\n {errorMessage}\n </Text>\n )}\n\n {selectedFiles.length > 0 && (\n <Box\n data-testid=\"drag-drop-uploader__list\"\n flexDirection=\"column\"\n gap={sizing.listGap}\n width=\"100%\"\n >\n {selectedFiles.map((file, index) => (\n <Box\n key={`${file.name}-${index}`}\n data-testid=\"drag-drop-uploader__file\"\n flexDirection=\"row\"\n alignItems=\"center\"\n gap={sizing.itemGap}\n width=\"100%\"\n paddingVertical={sizing.itemPaddingVertical}\n paddingLeft={sizing.itemPaddingLeft}\n paddingRight={sizing.itemPaddingRight}\n borderRadius={sizing.radius}\n borderWidth={sizing.borderWidth}\n borderColor={inputColors.border}\n backgroundColor={inputColors.bg}\n style={isWeb ? { boxSizing: \"border-box\" } : undefined}\n >\n <Box\n alignItems=\"center\"\n justifyContent=\"center\"\n width={sizing.itemIconWrapperSize}\n height={sizing.itemIconWrapperSize}\n borderRadius={sizing.radius}\n backgroundColor={theme.colors.overlay.mono}\n {...(isWeb && { \"aria-hidden\": \"true\" })}\n >\n <FileText\n size={sizing.itemIconSize}\n color={inputColors.placeholder}\n />\n </Box>\n\n <Box flexDirection=\"column\" gap={2} flex={1} minWidth={0}>\n <Text\n color={inputColors.text}\n fontSize={sizing.itemTitleFontSize}\n lineHeight={sizing.itemTitleLineHeight}\n numberOfLines={1}\n style={\n isWeb\n ? {\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }\n : undefined\n }\n >\n {file.name}\n </Text>\n <Text\n color={inputColors.placeholder}\n fontSize={sizing.itemDescriptionFontSize}\n lineHeight={sizing.itemDescriptionLineHeight}\n numberOfLines={1}\n >\n {formatFileSize(file.size)}\n </Text>\n </Box>\n\n <Box\n as={isWeb ? \"button\" : \"div\"}\n data-testid=\"drag-drop-uploader__remove\"\n aria-label={`Remove ${file.name}`}\n disabled={isDisabled}\n onPress={(event?: { stopPropagation?: () => void }) => {\n event?.stopPropagation?.();\n removeFile(index);\n }}\n padding={0}\n alignItems=\"center\"\n justifyContent=\"center\"\n style={\n isWeb\n ? {\n border: \"none\",\n background: \"transparent\",\n cursor: isDisabled ? \"not-allowed\" : \"pointer\",\n }\n : undefined\n }\n >\n <TrashCan\n size={sizing.removeIconSize}\n color={inputColors.placeholder}\n />\n </Box>\n </Box>\n ))}\n </Box>\n )}\n </Box>\n );\n }\n);\n\nDragDropUploader.displayName = \"DragDropUploader\";\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport type { BoxProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledBox = styled(FilteredDiv)<BoxProps>`\n display: flex;\n box-sizing: border-box;\n background-color: ${(props) => props.backgroundColor || \"transparent\"};\n border-color: ${(props) => props.borderColor || \"transparent\"};\n border-width: ${(props) =>\n typeof props.borderWidth === \"number\"\n ? `${props.borderWidth}px`\n : props.borderWidth || 0};\n\n ${(props) =>\n props.borderBottomWidth !== undefined &&\n `\n border-bottom-width: ${typeof props.borderBottomWidth === \"number\" ? `${props.borderBottomWidth}px` : props.borderBottomWidth};\n border-bottom-color: ${props.borderBottomColor || props.borderColor || \"transparent\"};\n border-bottom-style: solid;\n `}\n ${(props) =>\n props.borderTopWidth !== undefined &&\n `\n border-top-width: ${typeof props.borderTopWidth === \"number\" ? `${props.borderTopWidth}px` : props.borderTopWidth};\n border-top-color: ${props.borderTopColor || props.borderColor || \"transparent\"};\n border-top-style: solid;\n `}\n ${(props) =>\n props.borderLeftWidth !== undefined &&\n `\n border-left-width: ${typeof props.borderLeftWidth === \"number\" ? `${props.borderLeftWidth}px` : props.borderLeftWidth};\n border-left-color: ${props.borderLeftColor || props.borderColor || \"transparent\"};\n border-left-style: solid;\n `}\n ${(props) =>\n props.borderRightWidth !== undefined &&\n `\n border-right-width: ${typeof props.borderRightWidth === \"number\" ? `${props.borderRightWidth}px` : props.borderRightWidth};\n border-right-color: ${props.borderRightColor || props.borderColor || \"transparent\"};\n border-right-style: solid;\n `}\n\n border-style: ${(props) =>\n props.borderStyle ||\n (props.borderWidth ||\n props.borderBottomWidth ||\n props.borderTopWidth ||\n props.borderLeftWidth ||\n props.borderRightWidth\n ? \"solid\"\n : \"none\")};\n border-radius: ${(props) =>\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius || 0};\n height: ${(props) =>\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height || \"auto\"};\n width: ${(props) =>\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width || \"auto\"};\n min-width: ${(props) =>\n typeof props.minWidth === \"number\"\n ? `${props.minWidth}px`\n : props.minWidth || \"auto\"};\n min-height: ${(props) =>\n typeof props.minHeight === \"number\"\n ? `${props.minHeight}px`\n : props.minHeight || \"auto\"};\n max-width: ${(props) =>\n typeof props.maxWidth === \"number\"\n ? `${props.maxWidth}px`\n : props.maxWidth || \"none\"};\n max-height: ${(props) =>\n typeof props.maxHeight === \"number\"\n ? `${props.maxHeight}px`\n : props.maxHeight || \"none\"};\n\n padding: ${(props) =>\n typeof props.padding === \"number\"\n ? `${props.padding}px`\n : props.padding || 0};\n ${(props) =>\n props.paddingHorizontal &&\n `\n padding-left: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n padding-right: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n `}\n ${(props) =>\n props.paddingVertical &&\n `\n padding-top: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n padding-bottom: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n `}\n ${(props) =>\n props.paddingTop !== undefined &&\n `padding-top: ${typeof props.paddingTop === \"number\" ? `${props.paddingTop}px` : props.paddingTop};`}\n ${(props) =>\n props.paddingBottom !== undefined &&\n `padding-bottom: ${typeof props.paddingBottom === \"number\" ? `${props.paddingBottom}px` : props.paddingBottom};`}\n ${(props) =>\n props.paddingLeft !== undefined &&\n `padding-left: ${typeof props.paddingLeft === \"number\" ? `${props.paddingLeft}px` : props.paddingLeft};`}\n ${(props) =>\n props.paddingRight !== undefined &&\n `padding-right: ${typeof props.paddingRight === \"number\" ? `${props.paddingRight}px` : props.paddingRight};`}\n\n margin: ${(props) =>\n typeof props.margin === \"number\" ? `${props.margin}px` : props.margin || 0};\n ${(props) =>\n props.marginTop !== undefined &&\n `margin-top: ${typeof props.marginTop === \"number\" ? `${props.marginTop}px` : props.marginTop};`}\n ${(props) =>\n props.marginBottom !== undefined &&\n `margin-bottom: ${typeof props.marginBottom === \"number\" ? `${props.marginBottom}px` : props.marginBottom};`}\n ${(props) =>\n props.marginLeft !== undefined &&\n `margin-left: ${typeof props.marginLeft === \"number\" ? `${props.marginLeft}px` : props.marginLeft};`}\n ${(props) =>\n props.marginRight !== undefined &&\n `margin-right: ${typeof props.marginRight === \"number\" ? `${props.marginRight}px` : props.marginRight};`}\n\n flex-direction: ${(props) => props.flexDirection || \"column\"};\n flex-wrap: ${(props) => props.flexWrap || \"nowrap\"};\n align-items: ${(props) => props.alignItems || \"stretch\"};\n justify-content: ${(props) => props.justifyContent || \"flex-start\"};\n cursor: ${(props) =>\n props.cursor\n ? props.cursor\n : props.onClick || props.onPress\n ? \"pointer\"\n : \"inherit\"};\n position: ${(props) => props.position || \"static\"};\n top: ${(props) =>\n typeof props.top === \"number\" ? `${props.top}px` : props.top};\n bottom: ${(props) =>\n typeof props.bottom === \"number\" ? `${props.bottom}px` : props.bottom};\n left: ${(props) =>\n typeof props.left === \"number\" ? `${props.left}px` : props.left};\n right: ${(props) =>\n typeof props.right === \"number\" ? `${props.right}px` : props.right};\n flex: ${(props) => props.flex};\n flex-shrink: ${(props) => props.flexShrink ?? 1};\n gap: ${(props) =>\n typeof props.gap === \"number\" ? `${props.gap}px` : props.gap || 0};\n align-self: ${(props) => props.alignSelf || \"auto\"};\n overflow: ${(props) => props.overflow || \"visible\"};\n overflow-x: ${(props) => props.overflowX || \"visible\"};\n overflow-y: ${(props) => props.overflowY || \"visible\"};\n z-index: ${(props) => props.zIndex};\n opacity: ${(props) => (props.disabled ? 0.5 : 1)};\n pointer-events: ${(props) => (props.disabled ? \"none\" : \"auto\")};\n\n &:hover {\n ${(props) =>\n props.hoverStyle?.backgroundColor &&\n `background-color: ${props.hoverStyle.backgroundColor};`}\n ${(props) =>\n props.hoverStyle?.borderColor &&\n `border-color: ${props.hoverStyle.borderColor};`}\n }\n\n &:active {\n ${(props) =>\n props.pressStyle?.backgroundColor &&\n `background-color: ${props.pressStyle.backgroundColor};`}\n }\n`;\n\nexport const Box = React.forwardRef<\n HTMLDivElement | HTMLButtonElement,\n BoxProps\n>(\n (\n {\n children,\n onPress,\n onKeyDown,\n onKeyUp,\n role,\n \"aria-label\": ariaLabel,\n \"aria-labelledby\": ariaLabelledBy,\n \"aria-current\": ariaCurrent,\n \"aria-disabled\": ariaDisabled,\n \"aria-live\": ariaLive,\n \"aria-busy\": ariaBusy,\n \"aria-describedby\": ariaDescribedBy,\n \"aria-expanded\": ariaExpanded,\n \"aria-haspopup\": ariaHasPopup,\n \"aria-pressed\": ariaPressed,\n \"aria-controls\": ariaControls,\n tabIndex,\n as,\n src,\n alt,\n onError,\n onLoad,\n type,\n disabled,\n id,\n testID,\n \"data-testid\": dataTestId,\n ...props\n },\n ref\n ) => {\n // Handle as=\"img\" for rendering images with proper border-radius\n if (as === \"img\" && src) {\n return (\n <img\n src={src}\n alt={alt || \"\"}\n onError={onError}\n onLoad={onLoad}\n style={{\n display: \"block\",\n objectFit: \"cover\",\n width:\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width,\n height:\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height,\n borderRadius:\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius,\n position: props.position,\n top: typeof props.top === \"number\" ? `${props.top}px` : props.top,\n left:\n typeof props.left === \"number\" ? `${props.left}px` : props.left,\n right:\n typeof props.right === \"number\"\n ? `${props.right}px`\n : props.right,\n bottom:\n typeof props.bottom === \"number\"\n ? `${props.bottom}px`\n : props.bottom,\n ...props.style,\n }}\n />\n );\n }\n\n return (\n <StyledBox\n ref={ref}\n elementType={as}\n id={id}\n type={as === \"button\" ? type || \"button\" : undefined}\n disabled={as === \"button\" ? disabled : undefined}\n onClick={onPress}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n role={role}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n aria-current={ariaCurrent}\n aria-disabled={ariaDisabled}\n aria-busy={ariaBusy}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n aria-haspopup={ariaHasPopup}\n aria-pressed={ariaPressed}\n aria-controls={ariaControls}\n aria-live={ariaLive}\n tabIndex={tabIndex !== undefined ? tabIndex : undefined}\n data-testid={dataTestId || testID}\n {...props}\n >\n {children}\n </StyledBox>\n );\n }\n);\n\nBox.displayName = \"Box\";\n","import React from \"react\";\nimport isPropValid from \"@emotion/is-prop-valid\";\n\n// Props that @emotion/is-prop-valid incorrectly treats as valid HTML.\n// These are React Native or component-specific props that match\n// valid HTML patterns (on* event handlers, SVG attributes).\nexport const ADDITIONAL_BLOCKED_PROPS = new Set([\n // RN-only event handlers (pass isPropValid's on* pattern)\n \"onPress\",\n \"onChangeText\",\n \"onLayout\",\n \"onMoveShouldSetResponder\",\n \"onResponderGrant\",\n \"onResponderMove\",\n \"onResponderRelease\",\n \"onResponderTerminate\",\n // SVG attributes that pass isPropValid\n \"strokeWidth\",\n // CSS properties that pass isPropValid but are used as component props\n \"overflow\",\n \"cursor\",\n \"fontSize\",\n \"fontWeight\",\n \"fontFamily\",\n \"textDecoration\",\n]);\n\nfunction shouldForwardProp(key: string): boolean {\n if (ADDITIONAL_BLOCKED_PROPS.has(key)) return false;\n return isPropValid(key);\n}\n\n/**\n * Creates a React component that renders the given HTML tag\n * but filters out non-HTML props before they reach the DOM.\n *\n * Uses @emotion/is-prop-valid (same library styled-components v4\n * uses internally) to automatically block invalid HTML attributes,\n * plus a small blocklist for false positives (RN on* handlers, SVG attrs).\n *\n * Usage: `const FilteredDiv = createFilteredElement(\"div\");`\n * Then: `const StyledBox = styled(FilteredDiv)<BoxProps>\\`...\\`;`\n *\n * styled-components can still read ALL props for CSS interpolation,\n * but only valid HTML attributes are forwarded to the DOM element.\n */\nexport function createFilteredElement(defaultTag: string) {\n const Component = React.forwardRef<HTMLElement, Record<string, unknown>>(\n ({ children, elementType, ...props }, ref) => {\n const Tag = (elementType as string) || defaultTag;\n const htmlProps: Record<string, unknown> = {};\n for (const key of Object.keys(props)) {\n if (shouldForwardProp(key)) {\n htmlProps[key] = props[key];\n }\n }\n return React.createElement(\n Tag,\n { ref, ...htmlProps },\n children as React.ReactNode\n );\n }\n );\n Component.displayName = `Filtered(${defaultTag})`;\n return Component;\n}\n","function memoize(fn) {\n var cache = {};\n return function (arg) {\n if (cache[arg] === undefined) cache[arg] = fn(arg);\n return cache[arg];\n };\n}\n\nexport default memoize;\n","import memoize from '@emotion/memoize';\n\nvar reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/; // https://esbench.com/bench/5bfee68a4cd7e6009ef61d23\n\nvar index = memoize(function (prop) {\n return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111\n /* o */\n && prop.charCodeAt(1) === 110\n /* n */\n && prop.charCodeAt(2) < 91;\n}\n/* Z+1 */\n);\n\nexport default index;\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredSpan = createFilteredElement(\"span\");\n\nconst StyledText = styled(FilteredSpan)<TextProps>`\n color: ${(props) => props.color || \"inherit\"};\n font-size: ${(props) =>\n typeof props.fontSize === \"number\"\n ? `${props.fontSize}px`\n : props.fontSize || \"inherit\"};\n font-weight: ${(props) => props.fontWeight || \"normal\"};\n font-family: ${(props) =>\n props.fontFamily ||\n '\"Aktiv Grotesk\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif'};\n line-height: ${(props) =>\n typeof props.lineHeight === \"number\"\n ? `${props.lineHeight}px`\n : props.lineHeight || \"inherit\"};\n white-space: ${(props) => props.whiteSpace || \"normal\"};\n text-align: ${(props) => props.textAlign || \"inherit\"};\n text-decoration: ${(props) => props.textDecoration || \"none\"};\n`;\n\nexport const Text: React.FC<TextProps> = ({\n style,\n className,\n id,\n role,\n testID,\n \"data-testid\": dataTestId,\n numberOfLines: _numberOfLines,\n ...props\n}) => {\n return (\n <StyledText\n {...props}\n style={style}\n className={className}\n id={id}\n role={role}\n data-testid={dataTestId || testID}\n />\n );\n};\n","export * from \"./Box\";\nexport * from \"./Text\";\nexport * from \"./Spinner\";\nexport * from \"./Icon\";\nexport * from \"./Divider\";\nexport * from \"./Input\";\nexport * from \"./TextArea\";\nexport * from \"./LinearGradient\";\n\nexport const isWeb = true;\nexport const isNative = false;\n"],"mappings":";AAAA,OAAOA,UAAS,YAAY,QAAQ,gBAAgB;;;ACApD,OAAOC,YAAW;AAClB,OAAO,YAAY;;;ACDnB,OAAO,WAAW;;;ACAlB,SAAS,QAAQ,IAAI;AACnB,MAAI,QAAQ,CAAC;AACb,SAAO,SAAU,KAAK;AACpB,QAAI,MAAM,GAAG,MAAM,OAAW,OAAM,GAAG,IAAI,GAAG,GAAG;AACjD,WAAO,MAAM,GAAG;AAAA,EAClB;AACF;AAEA,IAAO,sBAAQ;;;ACNf,IAAI,kBAAkB;AAEtB,IAAI,QAAQ;AAAA,EAAQ,SAAU,MAAM;AAClC,WAAO,gBAAgB,KAAK,IAAI,KAAK,KAAK,WAAW,CAAC,MAAM,OAEzD,KAAK,WAAW,CAAC,MAAM,OAEvB,KAAK,WAAW,CAAC,IAAI;AAAA,EAC1B;AAAA;AAEA;AAEA,IAAO,4BAAQ;;;AFRR,IAAM,2BAA2B,oBAAI,IAAI;AAAA;AAAA,EAE9C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA,EAEA;AAAA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,CAAC;AAED,SAAS,kBAAkB,KAAsB;AAC/C,MAAI,yBAAyB,IAAI,GAAG,EAAG,QAAO;AAC9C,SAAO,0BAAY,GAAG;AACxB;AAgBO,SAAS,sBAAsB,YAAoB;AACxD,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;AAAA,0BACd,IACA;AAAA,0BAGL,eAAK;AAAA;AAAA,sBACR;AAAA,sBACA,gBAAAA;AAAA,wBAAC;AAAA;AAAA,0BACC,OAAO,YAAY;AAAA,0BACnB,UAAU,OAAO;AAAA,0BACjB,YAAY,OAAO;AAAA,0BACnB,eAAe;AAAA,0BAEd,yBAAe,KAAK,IAAI;AAAA;AAAA,sBAC3B;AAAA,uBACF;AAAA,oBAEA,gBAAAA;AAAA,sBAAC;AAAA;AAAA,wBACC,IAAI,QAAQ,WAAW;AAAA,wBACvB,eAAY;AAAA,wBACZ,cAAY,UAAU,KAAK,IAAI;AAAA,wBAC/B,UAAU;AAAA,wBACV,SAAS,CAAC,UAA6C;AACrD,iCAAO,kBAAkB;AACzB,qCAAWE,MAAK;AAAA,wBAClB;AAAA,wBACA,SAAS;AAAA,wBACT,YAAW;AAAA,wBACX,gBAAe;AAAA,wBACf,OACE,QACI;AAAA,0BACE,QAAQ;AAAA,0BACR,YAAY;AAAA,0BACZ,QAAQ,aAAa,gBAAgB;AAAA,wBACvC,IACA;AAAA,wBAGN,0BAAAF;AAAA,0BAAC;AAAA;AAAA,4BACC,MAAM,OAAO;AAAA,4BACb,OAAO,YAAY;AAAA;AAAA,wBACrB;AAAA;AAAA,oBACF;AAAA;AAAA;AAAA,gBApFK,GAAG,KAAK,IAAI,IAAIE,MAAK;AAAA,cAqF5B,CACD;AAAA;AAAA,UACH;AAAA;AAAA;AAAA,IAEJ;AAAA,EAEJ;AACF;AAEA,iBAAiB,cAAc;","names":["React","React","React","styled","jsx","styled","jsx","React","index"]}
1
+ {"version":3,"sources":["../../src/DragDropUploader.tsx","../../../../foundation/primitives-web/src/Box.tsx","../../../../foundation/primitives-web/src/filterDOMProps.ts","../../../../../node_modules/@emotion/memoize/dist/memoize.esm.js","../../../../../node_modules/@emotion/is-prop-valid/dist/is-prop-valid.esm.js","../../../../foundation/primitives-web/src/Text.tsx","../../../../foundation/primitives-web/src/index.tsx"],"sourcesContent":["import React, { forwardRef, useRef, useState } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, isWeb } from \"@xsolla/xui-primitives\";\nimport { useId, useResolvedTheme } from \"@xsolla/xui-core\";\nimport { FileText, FileUploadIn, TrashCan } from \"@xsolla/xui-icons-base\";\nimport type {\n DragDropUploaderFile,\n DragDropUploaderProps,\n DragDropUploaderSize,\n DragDropUploaderVisualState,\n} from \"./types\";\n\nexport type {\n DragDropUploaderFile,\n DragDropUploaderProps,\n DragDropUploaderSize,\n DragDropUploaderVisualState,\n} from \"./types\";\n\nconst DEFAULT_TITLE = \"Click or drag file to this area to upload\";\nconst DEFAULT_DESCRIPTION = \"PDF, DOC, DOCX up to 10MB\";\n\nconst formatFileSize = (size: number) => {\n if (size < 1024) return `${size}B`;\n if (size < 1024 * 1024) return `${Math.round(size / 1024)}KB`;\n return `${Math.round(size / (1024 * 1024))}MB`;\n};\n\nconst normalizeFiles = (files: File[]) =>\n files.map((file) => ({\n name: file.name,\n size: file.size,\n mimeType: file.type || undefined,\n file,\n }));\n\ntype DragDropUploaderSizing = {\n width: number;\n rootGap: number;\n radius: number;\n borderWidth: number;\n areaHeight: number;\n areaPadding: number;\n areaGap: number;\n iconSize: number;\n textGap: number;\n titleFontSize: number;\n titleLineHeight: number;\n descriptionFontSize: number;\n descriptionLineHeight: number;\n errorFontSize: number;\n errorLineHeight: number;\n listGap: number;\n itemGap: number;\n itemPaddingVertical: number;\n itemPaddingLeft: number;\n itemPaddingRight: number;\n itemIconWrapperSize: number;\n itemIconSize: number;\n itemTitleFontSize: number;\n itemTitleLineHeight: number;\n itemDescriptionFontSize: number;\n itemDescriptionLineHeight: number;\n removeIconSize: number;\n};\n\nexport const DragDropUploader = forwardRef<\n HTMLInputElement,\n DragDropUploaderProps\n>(\n (\n {\n size = \"sm\",\n title = DEFAULT_TITLE,\n description = DEFAULT_DESCRIPTION,\n icon,\n errorMessage,\n files,\n defaultFiles = [],\n accept,\n multiple = false,\n disabled = false,\n loading = false,\n width,\n visualState,\n onFilesChange,\n onDropFiles,\n onRemoveFile,\n testID,\n themeMode,\n themeProductContext,\n },\n ref\n ) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const inputRef = useRef<HTMLInputElement>(null);\n const [internalFiles, setInternalFiles] =\n useState<DragDropUploaderFile[]>(defaultFiles);\n const [isHover, setIsHover] = useState(false);\n const [isDragActive, setIsDragActive] = useState(false);\n\n React.useImperativeHandle(\n ref,\n () => inputRef.current as HTMLInputElement,\n []\n );\n\n const isControlled = files !== undefined;\n const selectedFiles = isControlled ? files : internalFiles;\n const hasError = !!errorMessage;\n const isDisabled = disabled || loading;\n const sizing = (\n theme.sizing as typeof theme.sizing & {\n dragDropUploader: (\n size: DragDropUploaderSize\n ) => DragDropUploaderSizing;\n }\n ).dragDropUploader(size);\n const inputColors = theme.colors.control.input;\n const focusColors = theme.colors.control.focus;\n const alertBorder = theme.colors.control.alert.border;\n const alertText = theme.colors.content.alert.primary;\n const rootWidth = width ?? sizing.width;\n const reactId = useId();\n const baseId = `drag-drop-uploader-${reactId.replace(/[^a-zA-Z0-9-]/g, \"\")}`;\n const descriptionId = `${baseId}-description`;\n const errorId = `${baseId}-error`;\n\n let state: DragDropUploaderVisualState = \"default\";\n if (isDisabled) state = \"disabled\";\n else if (hasError) state = \"error\";\n else if (isDragActive) state = \"drag\";\n else if (isHover) state = \"hover\";\n if (visualState) state = visualState;\n\n const setNextFiles = (\n nextFiles: DragDropUploaderFile[],\n pickedFiles?: DragDropUploaderFile[]\n ) => {\n if (!isControlled) setInternalFiles(nextFiles);\n onDropFiles?.(pickedFiles ?? nextFiles);\n onFilesChange?.(nextFiles);\n };\n\n const appendFiles = (pickedFiles: DragDropUploaderFile[]) => {\n if (pickedFiles.length === 0) return;\n const nextFiles = multiple\n ? [...selectedFiles, ...pickedFiles]\n : pickedFiles.slice(0, 1);\n setNextFiles(nextFiles, pickedFiles);\n };\n\n const removeFile = (index: number) => {\n const file = selectedFiles[index];\n if (!file || isDisabled) return;\n const nextFiles = selectedFiles.filter(\n (_, itemIndex) => itemIndex !== index\n );\n if (!isControlled) setInternalFiles(nextFiles);\n onRemoveFile?.(file, index);\n onFilesChange?.(nextFiles);\n if (isWeb && inputRef.current) inputRef.current.value = \"\";\n };\n\n const handleClick = () => {\n if (!isWeb || isDisabled) return;\n inputRef.current?.click();\n };\n\n const handleFileChange = (event: React.ChangeEvent<HTMLInputElement>) => {\n const nextFiles = Array.from(event.target.files ?? []);\n event.target.value = \"\";\n appendFiles(normalizeFiles(nextFiles));\n };\n\n const handleDragOver = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n if (!isDisabled) setIsDragActive(true);\n };\n\n const handleDragLeave = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n setIsDragActive(false);\n };\n\n const handleDrop = (event: React.DragEvent) => {\n event.preventDefault();\n event.stopPropagation();\n setIsDragActive(false);\n if (isDisabled) return;\n appendFiles(normalizeFiles(Array.from(event.dataTransfer.files ?? [])));\n };\n\n let backgroundColor = inputColors.bg;\n let borderColor = inputColors.border;\n let titleColor = inputColors.text;\n let descriptionColor = inputColors.placeholder;\n let iconColor = theme.colors.content.brand.primary;\n\n switch (state) {\n case \"hover\":\n backgroundColor = inputColors.bgHover;\n borderColor = inputColors.border;\n break;\n case \"drag\":\n backgroundColor = focusColors.bg;\n borderColor = focusColors.border;\n break;\n case \"disabled\":\n backgroundColor = inputColors.bgDisable;\n borderColor = inputColors.borderDisable;\n titleColor = inputColors.textDisable;\n descriptionColor = inputColors.textDisable;\n iconColor = inputColors.textDisable;\n break;\n case \"error\":\n borderColor = alertBorder;\n break;\n }\n\n const describedBy =\n [description ? descriptionId : null, errorMessage ? errorId : null]\n .filter(Boolean)\n .join(\" \") || undefined;\n\n const webAreaProps = isWeb\n ? {\n \"aria-describedby\": describedBy,\n \"aria-disabled\": isDisabled || undefined,\n \"aria-invalid\": hasError || undefined,\n onMouseEnter: () => {\n if (!isDisabled) setIsHover(true);\n },\n onMouseLeave: () => setIsHover(false),\n onDragOver: handleDragOver,\n onDragLeave: handleDragLeave,\n onDrop: handleDrop,\n style: {\n boxSizing: \"border-box\" as const,\n cursor: isDisabled ? \"not-allowed\" : \"pointer\",\n outline: \"none\",\n transition: \"background-color 0.15s ease, border-color 0.15s ease\",\n },\n }\n : {};\n\n return (\n <Box\n testID={testID || \"drag-drop-uploader\"}\n flexDirection=\"column\"\n gap={sizing.rootGap}\n alignItems=\"flex-start\"\n width={rootWidth}\n >\n {isWeb && (\n <input\n type=\"file\"\n ref={inputRef}\n accept={accept}\n multiple={multiple}\n onChange={handleFileChange}\n style={{ display: \"none\" }}\n disabled={isDisabled}\n tabIndex={-1}\n aria-hidden=\"true\"\n data-testid=\"drag-drop-uploader__input\"\n />\n )}\n\n <Box\n as={isWeb ? \"button\" : \"div\"}\n disabled={isDisabled}\n data-testid=\"drag-drop-uploader__area\"\n onPress={handleClick}\n flexDirection=\"column\"\n alignItems=\"center\"\n justifyContent=\"center\"\n width=\"100%\"\n height={sizing.areaHeight}\n gap={sizing.areaGap}\n padding={sizing.areaPadding}\n borderRadius={sizing.radius}\n borderWidth={sizing.borderWidth}\n borderColor={borderColor}\n borderStyle=\"dashed\"\n backgroundColor={backgroundColor}\n {...webAreaProps}\n >\n <Box {...(isWeb && { \"aria-hidden\": \"true\" })}>\n {icon ?? <FileUploadIn size={sizing.iconSize} color={iconColor} />}\n </Box>\n\n {(title || description) && (\n <Box\n flexDirection=\"column\"\n gap={sizing.textGap}\n width=\"100%\"\n alignItems=\"center\"\n >\n {title &&\n (typeof title === \"string\" ? (\n <Text\n color={titleColor}\n fontSize={sizing.titleFontSize}\n lineHeight={sizing.titleLineHeight}\n fontWeight=\"500\"\n textAlign=\"center\"\n numberOfLines={2}\n >\n {title}\n </Text>\n ) : (\n <Box>{title}</Box>\n ))}\n\n {description &&\n (typeof description === \"string\" ? (\n <Text\n id={descriptionId}\n color={descriptionColor}\n fontSize={sizing.descriptionFontSize}\n lineHeight={sizing.descriptionLineHeight}\n textAlign=\"center\"\n numberOfLines={2}\n >\n {description}\n </Text>\n ) : (\n <Box id={descriptionId}>{description}</Box>\n ))}\n </Box>\n )}\n </Box>\n\n {errorMessage && (\n <Text\n id={errorId}\n role=\"alert\"\n data-testid=\"drag-drop-uploader__error\"\n color={alertText}\n fontSize={sizing.errorFontSize}\n lineHeight={sizing.errorLineHeight}\n >\n {errorMessage}\n </Text>\n )}\n\n {selectedFiles.length > 0 && (\n <Box\n data-testid=\"drag-drop-uploader__list\"\n flexDirection=\"column\"\n gap={sizing.listGap}\n width=\"100%\"\n >\n {selectedFiles.map((file, index) => (\n <Box\n key={`${file.name}-${index}`}\n data-testid=\"drag-drop-uploader__file\"\n flexDirection=\"row\"\n alignItems=\"center\"\n gap={sizing.itemGap}\n width=\"100%\"\n paddingVertical={sizing.itemPaddingVertical}\n paddingLeft={sizing.itemPaddingLeft}\n paddingRight={sizing.itemPaddingRight}\n borderRadius={sizing.radius}\n borderWidth={sizing.borderWidth}\n borderColor={inputColors.border}\n backgroundColor={inputColors.bg}\n style={isWeb ? { boxSizing: \"border-box\" } : undefined}\n >\n <Box\n alignItems=\"center\"\n justifyContent=\"center\"\n width={sizing.itemIconWrapperSize}\n height={sizing.itemIconWrapperSize}\n borderRadius={sizing.radius}\n backgroundColor={theme.colors.overlay.mono}\n {...(isWeb && { \"aria-hidden\": \"true\" })}\n >\n <FileText\n size={sizing.itemIconSize}\n color={inputColors.placeholder}\n />\n </Box>\n\n <Box flexDirection=\"column\" gap={2} flex={1} minWidth={0}>\n <Text\n color={inputColors.text}\n fontSize={sizing.itemTitleFontSize}\n lineHeight={sizing.itemTitleLineHeight}\n numberOfLines={1}\n style={\n isWeb\n ? {\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }\n : undefined\n }\n >\n {file.name}\n </Text>\n <Text\n color={inputColors.placeholder}\n fontSize={sizing.itemDescriptionFontSize}\n lineHeight={sizing.itemDescriptionLineHeight}\n numberOfLines={1}\n >\n {formatFileSize(file.size)}\n </Text>\n </Box>\n\n <Box\n as={isWeb ? \"button\" : \"div\"}\n data-testid=\"drag-drop-uploader__remove\"\n aria-label={`Remove ${file.name}`}\n disabled={isDisabled}\n onPress={(event?: { stopPropagation?: () => void }) => {\n event?.stopPropagation?.();\n removeFile(index);\n }}\n padding={0}\n alignItems=\"center\"\n justifyContent=\"center\"\n style={\n isWeb\n ? {\n border: \"none\",\n background: \"transparent\",\n cursor: isDisabled ? \"not-allowed\" : \"pointer\",\n }\n : undefined\n }\n >\n <TrashCan\n size={sizing.removeIconSize}\n color={inputColors.placeholder}\n />\n </Box>\n </Box>\n ))}\n </Box>\n )}\n </Box>\n );\n }\n);\n\nDragDropUploader.displayName = \"DragDropUploader\";\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport type { BoxProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledBox = styled(FilteredDiv)<BoxProps>`\n display: flex;\n box-sizing: border-box;\n background-color: ${(props) => props.backgroundColor || \"transparent\"};\n border-color: ${(props) => props.borderColor || \"transparent\"};\n border-width: ${(props) =>\n typeof props.borderWidth === \"number\"\n ? `${props.borderWidth}px`\n : props.borderWidth || 0};\n\n ${(props) =>\n props.borderBottomWidth !== undefined &&\n `\n border-bottom-width: ${typeof props.borderBottomWidth === \"number\" ? `${props.borderBottomWidth}px` : props.borderBottomWidth};\n border-bottom-color: ${props.borderBottomColor || props.borderColor || \"transparent\"};\n border-bottom-style: solid;\n `}\n ${(props) =>\n props.borderTopWidth !== undefined &&\n `\n border-top-width: ${typeof props.borderTopWidth === \"number\" ? `${props.borderTopWidth}px` : props.borderTopWidth};\n border-top-color: ${props.borderTopColor || props.borderColor || \"transparent\"};\n border-top-style: solid;\n `}\n ${(props) =>\n props.borderLeftWidth !== undefined &&\n `\n border-left-width: ${typeof props.borderLeftWidth === \"number\" ? `${props.borderLeftWidth}px` : props.borderLeftWidth};\n border-left-color: ${props.borderLeftColor || props.borderColor || \"transparent\"};\n border-left-style: solid;\n `}\n ${(props) =>\n props.borderRightWidth !== undefined &&\n `\n border-right-width: ${typeof props.borderRightWidth === \"number\" ? `${props.borderRightWidth}px` : props.borderRightWidth};\n border-right-color: ${props.borderRightColor || props.borderColor || \"transparent\"};\n border-right-style: solid;\n `}\n\n border-style: ${(props) =>\n props.borderStyle ||\n (props.borderWidth ||\n props.borderBottomWidth ||\n props.borderTopWidth ||\n props.borderLeftWidth ||\n props.borderRightWidth\n ? \"solid\"\n : \"none\")};\n border-radius: ${(props) =>\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius || 0};\n height: ${(props) =>\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height || \"auto\"};\n width: ${(props) =>\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width || \"auto\"};\n min-width: ${(props) =>\n typeof props.minWidth === \"number\"\n ? `${props.minWidth}px`\n : props.minWidth || \"auto\"};\n min-height: ${(props) =>\n typeof props.minHeight === \"number\"\n ? `${props.minHeight}px`\n : props.minHeight || \"auto\"};\n max-width: ${(props) =>\n typeof props.maxWidth === \"number\"\n ? `${props.maxWidth}px`\n : props.maxWidth || \"none\"};\n max-height: ${(props) =>\n typeof props.maxHeight === \"number\"\n ? `${props.maxHeight}px`\n : props.maxHeight || \"none\"};\n\n padding: ${(props) =>\n typeof props.padding === \"number\"\n ? `${props.padding}px`\n : props.padding || 0};\n ${(props) =>\n props.paddingHorizontal &&\n `\n padding-left: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n padding-right: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n `}\n ${(props) =>\n props.paddingVertical &&\n `\n padding-top: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n padding-bottom: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n `}\n ${(props) =>\n props.paddingTop !== undefined &&\n `padding-top: ${typeof props.paddingTop === \"number\" ? `${props.paddingTop}px` : props.paddingTop};`}\n ${(props) =>\n props.paddingBottom !== undefined &&\n `padding-bottom: ${typeof props.paddingBottom === \"number\" ? `${props.paddingBottom}px` : props.paddingBottom};`}\n ${(props) =>\n props.paddingLeft !== undefined &&\n `padding-left: ${typeof props.paddingLeft === \"number\" ? `${props.paddingLeft}px` : props.paddingLeft};`}\n ${(props) =>\n props.paddingRight !== undefined &&\n `padding-right: ${typeof props.paddingRight === \"number\" ? `${props.paddingRight}px` : props.paddingRight};`}\n\n margin: ${(props) =>\n typeof props.margin === \"number\" ? `${props.margin}px` : props.margin || 0};\n ${(props) =>\n props.marginTop !== undefined &&\n `margin-top: ${typeof props.marginTop === \"number\" ? `${props.marginTop}px` : props.marginTop};`}\n ${(props) =>\n props.marginBottom !== undefined &&\n `margin-bottom: ${typeof props.marginBottom === \"number\" ? `${props.marginBottom}px` : props.marginBottom};`}\n ${(props) =>\n props.marginLeft !== undefined &&\n `margin-left: ${typeof props.marginLeft === \"number\" ? `${props.marginLeft}px` : props.marginLeft};`}\n ${(props) =>\n props.marginRight !== undefined &&\n `margin-right: ${typeof props.marginRight === \"number\" ? `${props.marginRight}px` : props.marginRight};`}\n\n flex-direction: ${(props) => props.flexDirection || \"column\"};\n flex-wrap: ${(props) => props.flexWrap || \"nowrap\"};\n align-items: ${(props) => props.alignItems || \"stretch\"};\n justify-content: ${(props) => props.justifyContent || \"flex-start\"};\n cursor: ${(props) =>\n props.cursor\n ? props.cursor\n : props.onClick || props.onPress\n ? \"pointer\"\n : \"inherit\"};\n position: ${(props) => props.position || \"static\"};\n top: ${(props) =>\n typeof props.top === \"number\" ? `${props.top}px` : props.top};\n bottom: ${(props) =>\n typeof props.bottom === \"number\" ? `${props.bottom}px` : props.bottom};\n left: ${(props) =>\n typeof props.left === \"number\" ? `${props.left}px` : props.left};\n right: ${(props) =>\n typeof props.right === \"number\" ? `${props.right}px` : props.right};\n flex: ${(props) => props.flex};\n flex-shrink: ${(props) => props.flexShrink ?? 1};\n gap: ${(props) =>\n typeof props.gap === \"number\" ? `${props.gap}px` : props.gap || 0};\n align-self: ${(props) => props.alignSelf || \"auto\"};\n overflow: ${(props) => props.overflow || \"visible\"};\n overflow-x: ${(props) => props.overflowX || \"visible\"};\n overflow-y: ${(props) => props.overflowY || \"visible\"};\n z-index: ${(props) => props.zIndex};\n opacity: ${(props) => (props.disabled ? 0.5 : 1)};\n pointer-events: ${(props) => (props.disabled ? \"none\" : \"auto\")};\n\n &:hover {\n ${(props) =>\n props.hoverStyle?.backgroundColor &&\n `background-color: ${props.hoverStyle.backgroundColor};`}\n ${(props) =>\n props.hoverStyle?.borderColor &&\n `border-color: ${props.hoverStyle.borderColor};`}\n }\n\n &:active {\n ${(props) =>\n props.pressStyle?.backgroundColor &&\n `background-color: ${props.pressStyle.backgroundColor};`}\n }\n`;\n\nexport const Box = React.forwardRef<\n HTMLDivElement | HTMLButtonElement,\n BoxProps\n>(\n (\n {\n children,\n onPress,\n onKeyDown,\n onKeyUp,\n role,\n \"aria-label\": ariaLabel,\n \"aria-labelledby\": ariaLabelledBy,\n \"aria-current\": ariaCurrent,\n \"aria-disabled\": ariaDisabled,\n \"aria-live\": ariaLive,\n \"aria-busy\": ariaBusy,\n \"aria-describedby\": ariaDescribedBy,\n \"aria-expanded\": ariaExpanded,\n \"aria-haspopup\": ariaHasPopup,\n \"aria-pressed\": ariaPressed,\n \"aria-controls\": ariaControls,\n tabIndex,\n as,\n src,\n alt,\n onError,\n onLoad,\n type,\n disabled,\n id,\n testID,\n \"data-testid\": dataTestId,\n ...props\n },\n ref\n ) => {\n // Handle as=\"img\" for rendering images with proper border-radius\n if (as === \"img\" && src) {\n return (\n <img\n src={src}\n alt={alt || \"\"}\n onError={onError}\n onLoad={onLoad}\n style={{\n display: \"block\",\n objectFit: \"cover\",\n width:\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width,\n height:\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height,\n borderRadius:\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius,\n position: props.position,\n top: typeof props.top === \"number\" ? `${props.top}px` : props.top,\n left:\n typeof props.left === \"number\" ? `${props.left}px` : props.left,\n right:\n typeof props.right === \"number\"\n ? `${props.right}px`\n : props.right,\n bottom:\n typeof props.bottom === \"number\"\n ? `${props.bottom}px`\n : props.bottom,\n ...props.style,\n }}\n />\n );\n }\n\n return (\n <StyledBox\n ref={ref}\n elementType={as}\n id={id}\n type={as === \"button\" ? type || \"button\" : undefined}\n disabled={as === \"button\" ? disabled : undefined}\n onClick={onPress}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n role={role}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n aria-current={ariaCurrent}\n aria-disabled={ariaDisabled}\n aria-busy={ariaBusy}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n aria-haspopup={ariaHasPopup}\n aria-pressed={ariaPressed}\n aria-controls={ariaControls}\n aria-live={ariaLive}\n tabIndex={tabIndex !== undefined ? tabIndex : undefined}\n data-testid={dataTestId || testID}\n {...props}\n >\n {children}\n </StyledBox>\n );\n }\n);\n\nBox.displayName = \"Box\";\n","import React from \"react\";\nimport isPropValid from \"@emotion/is-prop-valid\";\n\n// Props that @emotion/is-prop-valid incorrectly treats as valid HTML.\n// These are React Native or component-specific props that match\n// valid HTML patterns (on* event handlers, SVG attributes).\nexport const ADDITIONAL_BLOCKED_PROPS = new Set([\n // RN-only event handlers (pass isPropValid's on* pattern)\n \"onPress\",\n \"onChangeText\",\n \"onLayout\",\n \"onMoveShouldSetResponder\",\n \"onResponderGrant\",\n \"onResponderMove\",\n \"onResponderRelease\",\n \"onResponderTerminate\",\n // SVG attributes that pass isPropValid\n \"strokeWidth\",\n // CSS properties that pass isPropValid but are used as component props\n \"overflow\",\n \"cursor\",\n \"fontSize\",\n \"fontWeight\",\n \"fontFamily\",\n \"textDecoration\",\n]);\n\nfunction shouldForwardProp(key: string): boolean {\n if (ADDITIONAL_BLOCKED_PROPS.has(key)) return false;\n return isPropValid(key);\n}\n\n/**\n * Creates a React component that renders the given HTML tag\n * but filters out non-HTML props before they reach the DOM.\n *\n * Uses @emotion/is-prop-valid (same library styled-components v4\n * uses internally) to automatically block invalid HTML attributes,\n * plus a small blocklist for false positives (RN on* handlers, SVG attrs).\n *\n * Usage: `const FilteredDiv = createFilteredElement(\"div\");`\n * Then: `const StyledBox = styled(FilteredDiv)<BoxProps>\\`...\\`;`\n *\n * styled-components can still read ALL props for CSS interpolation,\n * but only valid HTML attributes are forwarded to the DOM element.\n */\nexport function createFilteredElement(defaultTag: string) {\n const Component = React.forwardRef<HTMLElement, Record<string, unknown>>(\n ({ children, elementType, ...props }, ref) => {\n const Tag = (elementType as string) || defaultTag;\n const htmlProps: Record<string, unknown> = {};\n for (const key of Object.keys(props)) {\n if (shouldForwardProp(key)) {\n htmlProps[key] = props[key];\n }\n }\n return React.createElement(\n Tag,\n { ref, ...htmlProps },\n children as React.ReactNode\n );\n }\n );\n Component.displayName = `Filtered(${defaultTag})`;\n return Component;\n}\n","function memoize(fn) {\n var cache = {};\n return function (arg) {\n if (cache[arg] === undefined) cache[arg] = fn(arg);\n return cache[arg];\n };\n}\n\nexport default memoize;\n","import memoize from '@emotion/memoize';\n\nvar reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/; // https://esbench.com/bench/5bfee68a4cd7e6009ef61d23\n\nvar index = memoize(function (prop) {\n return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111\n /* o */\n && prop.charCodeAt(1) === 110\n /* n */\n && prop.charCodeAt(2) < 91;\n}\n/* Z+1 */\n);\n\nexport default index;\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredSpan = createFilteredElement(\"span\");\n\nconst StyledText = styled(FilteredSpan)<TextProps>`\n color: ${(props) => props.color || \"inherit\"};\n font-size: ${(props) =>\n typeof props.fontSize === \"number\"\n ? `${props.fontSize}px`\n : props.fontSize || \"inherit\"};\n font-weight: ${(props) => props.fontWeight || \"normal\"};\n font-family: ${(props) =>\n props.fontFamily ||\n '\"Aktiv Grotesk\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif'};\n line-height: ${(props) =>\n typeof props.lineHeight === \"number\"\n ? `${props.lineHeight}px`\n : props.lineHeight || \"inherit\"};\n white-space: ${(props) => props.whiteSpace || \"normal\"};\n text-align: ${(props) => props.textAlign || \"inherit\"};\n text-decoration: ${(props) => props.textDecoration || \"none\"};\n`;\n\nexport const Text: React.FC<TextProps> = ({\n style,\n className,\n id,\n role,\n testID,\n \"data-testid\": dataTestId,\n numberOfLines: _numberOfLines,\n ...props\n}) => {\n return (\n <StyledText\n {...props}\n style={style}\n className={className}\n id={id}\n role={role}\n data-testid={dataTestId || testID}\n />\n );\n};\n","export * from \"./Box\";\nexport * from \"./Text\";\nexport * from \"./Spinner\";\nexport * from \"./Icon\";\nexport * from \"./Divider\";\nexport * from \"./Input\";\nexport * from \"./TextArea\";\nexport * from \"./LinearGradient\";\n\nexport const isWeb = true;\nexport const isNative = false;\n"],"mappings":";AAAA,OAAOA,UAAS,YAAY,QAAQ,gBAAgB;;;ACApD,OAAOC,YAAW;AAClB,OAAO,YAAY;;;ACDnB,OAAO,WAAW;;;ACAlB,SAAS,QAAQ,IAAI;AACnB,MAAI,QAAQ,CAAC;AACb,SAAO,SAAU,KAAK;AACpB,QAAI,MAAM,GAAG,MAAM,OAAW,OAAM,GAAG,IAAI,GAAG,GAAG;AACjD,WAAO,MAAM,GAAG;AAAA,EAClB;AACF;AAEA,IAAO,sBAAQ;;;ACNf,IAAI,kBAAkB;AAEtB,IAAI,QAAQ;AAAA,EAAQ,SAAU,MAAM;AAClC,WAAO,gBAAgB,KAAK,IAAI,KAAK,KAAK,WAAW,CAAC,M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