@xsolla/xui-calendar 0.210.0 → 0.211.1
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.
- package/native/index.js +51 -22
- package/native/index.js.map +1 -1
- package/native/index.mjs +63 -34
- package/native/index.mjs.map +1 -1
- package/package.json +7 -7
- package/web/index.js +53 -24
- package/web/index.js.map +1 -1
- package/web/index.mjs +65 -36
- package/web/index.mjs.map +1 -1
package/web/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/index.tsx","../../src/Calendar.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/textTruncation.ts","../../src/CalendarHeader.tsx","../../src/utils.ts","../../src/CalendarGrid.tsx","../../src/CalendarChips.tsx","../../src/DualCalendar.tsx"],"sourcesContent":["export * from \"./Calendar\";\nexport * from \"./DualCalendar\";\nexport * from \"./CalendarHeader\";\nexport * from \"./CalendarGrid\";\nexport * from \"./CalendarChips\";\nexport * from \"./types\";\nexport * from \"./utils\";\n","import { forwardRef, useCallback, useEffect, useState } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme } from \"@xsolla/xui-core\";\nimport { addMonths, subDays, subMonths, startOfDay } from \"date-fns\";\nimport { CalendarHeader } from \"./CalendarHeader\";\nimport { CalendarGrid } from \"./CalendarGrid\";\nimport { CalendarChips } from \"./CalendarChips\";\nimport type { CalendarProps } from \"./types\";\n\nexport const Calendar = forwardRef<any, CalendarProps>(\n (\n {\n locale = \"enUS\",\n onChange,\n startDate,\n endDate,\n selectedDate,\n selectsRange = false,\n contextMenuMaxHeight,\n topContent,\n bottomContent,\n chips,\n activeChip,\n onChipSelect,\n testID,\n minDate,\n maxDate,\n firstDayOfWeek = 0,\n month,\n initialMonth,\n themeMode,\n themeProductContext,\n },\n ref\n ) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n\n const [currentMonth, setCurrentMonth] = useState<Date>(\n (month || initialMonth || selectedDate || startDate || new Date()) as Date\n );\n const [selectedStartDate, setSelectedStartDate] = useState<\n Date | null | undefined\n >(startDate);\n const [selectedEndDate, setSelectedEndDate] = useState<\n Date | null | undefined\n >(endDate);\n const [locSelectedDate, setLocSelectedDate] = useState<\n Date | null | undefined\n >(selectedDate);\n const [selectingRange, setSelectingRange] = useState<Date | null>(null);\n\n useEffect(() => {\n setSelectedStartDate(startDate);\n setSelectedEndDate(endDate);\n setLocSelectedDate(selectedDate);\n if (month !== undefined) {\n setCurrentMonth(month);\n }\n }, [startDate, endDate, selectedDate, month]);\n\n const handleChange = useCallback(\n (date: Date) => {\n const newDate = new Date(\n date.getFullYear(),\n date.getMonth(),\n date.getDate()\n );\n\n if (!selectsRange) {\n setLocSelectedDate(newDate);\n onChange?.(newDate);\n } else {\n if (!selectedStartDate || (selectedStartDate && selectedEndDate)) {\n setSelectedStartDate(newDate);\n setSelectedEndDate(null);\n setSelectingRange(newDate);\n onChange?.([newDate, null]);\n } else {\n const start =\n selectedStartDate < newDate ? selectedStartDate : newDate;\n const end =\n selectedStartDate < newDate ? newDate : selectedStartDate;\n setSelectedStartDate(start);\n setSelectedEndDate(end);\n setSelectingRange(null);\n onChange?.([start, end]);\n }\n }\n },\n [onChange, selectsRange, selectedStartDate, selectedEndDate]\n );\n\n const decreaseMonth = useCallback(\n () => setCurrentMonth((prev) => subMonths(prev, 1)),\n []\n );\n const increaseMonth = useCallback(\n () => setCurrentMonth((prev) => addMonths(prev, 1)),\n []\n );\n const changeMonth = useCallback(\n (m: number) =>\n setCurrentMonth((prev) => new Date(prev.getFullYear(), m, 1)),\n []\n );\n const changeYear = useCallback(\n (y: number) => setCurrentMonth((prev) => new Date(y, prev.getMonth(), 1)),\n []\n );\n\n const handleChipSelect = useCallback(\n (value: string | null) => {\n onChipSelect?.(value);\n\n const chip = chips?.find((c) => c.value === value);\n if (!chip || chip.days === undefined) return;\n\n const today = startOfDay(new Date());\n\n if (chip.days === 0) {\n if (selectsRange) {\n setSelectedStartDate(today);\n setSelectedEndDate(today);\n setSelectingRange(null);\n onChange?.([today, today]);\n } else {\n setLocSelectedDate(today);\n onChange?.(today);\n }\n setCurrentMonth(today);\n return;\n }\n\n const start = subDays(today, chip.days);\n if (selectsRange) {\n setSelectedStartDate(start);\n setSelectedEndDate(today);\n setSelectingRange(null);\n onChange?.([start, today]);\n } else {\n setLocSelectedDate(start);\n onChange?.(start);\n }\n setCurrentMonth(start);\n },\n [chips, selectsRange, onChange, onChipSelect]\n );\n\n return (\n <Box\n ref={ref}\n testID={testID}\n backgroundColor={theme.colors.layer.float}\n borderRadius={theme.shape.contextMenu.md.borderRadius}\n padding={16}\n overflow=\"hidden\"\n style={{\n boxShadow:\n \"0px 2px 3px 0px rgba(7, 7, 8, 0.2), 0px 6px 10px 4px rgba(7, 7, 8, 0.1)\",\n width: 312,\n }}\n >\n {topContent?.({ close: () => {} })}\n\n {chips && chips.length > 0 && (\n <CalendarChips\n chips={chips}\n activeChip={activeChip}\n onChipSelect={handleChipSelect}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n )}\n\n <CalendarHeader\n monthDate={currentMonth}\n decreaseMonth={decreaseMonth}\n increaseMonth={increaseMonth}\n changeYear={changeYear}\n changeMonth={changeMonth}\n locale={locale}\n minDate={minDate}\n maxDate={maxDate}\n contextMenuMaxHeight={contextMenuMaxHeight}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n\n <CalendarGrid\n currentMonth={currentMonth}\n locale={locale}\n firstDayOfWeek={firstDayOfWeek}\n selectsRange={selectsRange}\n minDate={minDate}\n maxDate={maxDate}\n startDate={selectedStartDate}\n endDate={selectedEndDate}\n selectedDate={locSelectedDate}\n selectingRange={selectingRange}\n onDayPress={handleChange}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n\n {bottomContent?.({ close: () => {} })}\n </Box>\n );\n }\n);\n\nCalendar.displayName = \"Calendar\";\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 /* Only emit overflow-x/y when explicitly set. Defaulting them to\n visible after overflow would override the shorthand and break\n clipping (e.g. OtherCard bottom-right promo image). */\n overflow: ${(props) => props.overflow || \"visible\"};\n ${(props) =>\n props.overflowX != null ? `overflow-x: ${props.overflowX};` : \"\"}\n ${(props) =>\n props.overflowY != null ? `overflow-y: ${props.overflowY};` : \"\"}\n z-index: ${(props) => props.zIndex};\n opacity: ${(props) =>\n props.opacity != null ? props.opacity : props.disabled ? 0.5 : 1};\n pointer-events: ${(props) => (props.disabled ? \"none\" : \"auto\")};\n\n /* \\`background\\` is emitted before \\`background-color\\` so a caller passing\n both still gets backgroundColor as the winner. Use the shorthand for a\n layered fill (e.g. an overlay tint over a resting surface colour), which\n a single background-color cannot express. */\n &:hover {\n ${(props) =>\n props.hoverStyle?.background &&\n `background: ${props.hoverStyle.background};`}\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?.background &&\n `background: ${props.pressStyle.background};`}\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 data-testid={dataTestId || testID}\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 \"opacity\",\n \"cursor\",\n \"fontSize\",\n \"fontWeight\",\n \"fontFamily\",\n \"textDecoration\",\n // Cross-platform layout prop that Text consumes as CSS, never as an\n // attribute. Pinned explicitly because it is now spread into the styled\n // component rather than destructured away before it can reach the DOM.\n \"numberOfLines\",\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\";\nimport { truncationStyles } from \"./textTruncation\";\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 /* Keep last: single-line truncation has to win over white-space above. */\n ${(props) => truncationStyles(props.numberOfLines)}\n`;\n\nexport const Text: React.FC<TextProps> = ({\n style,\n className,\n id,\n role,\n testID,\n \"data-testid\": dataTestId,\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","/**\n * Web implementation of the cross-platform `numberOfLines` text prop.\n *\n * Native maps `numberOfLines` straight onto `RNText`. A web `<span>` has no\n * equivalent, so emit the CSS that produces the same result.\n *\n * Two details matter for the single-line case:\n * - `text-overflow` only takes effect on a block container, so the inline\n * `<span>` is promoted to `display: block` and capped at `max-width: 100%`.\n * - `min-width: 0` lets the text shrink below its own content width when it\n * sits in a flex row. Without it a `nowrap` label keeps its full intrinsic\n * width and pushes its siblings (icons, chevrons) out of a fixed-width field.\n *\n * Returns an empty string when there is nothing to clamp, so the declaration\n * block stays untouched for the majority of callers.\n */\nexport const truncationStyles = (numberOfLines?: number): string => {\n if (!numberOfLines || numberOfLines < 1) return \"\";\n\n if (numberOfLines === 1) {\n return `\n display: block;\n max-width: 100%;\n min-width: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n `;\n }\n\n return `\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: ${numberOfLines};\n line-clamp: ${numberOfLines};\n max-width: 100%;\n min-width: 0;\n overflow: hidden;\n `;\n};\n","import React, { useCallback, useMemo } from \"react\";\nimport { IconButton } from \"@xsolla/xui-button\";\nimport { Select } from \"@xsolla/xui-select\";\nimport { ArrowLeft, ArrowRight } from \"@xsolla/xui-icons-base\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box } from \"@xsolla/xui-primitives\";\nimport { getMonthInLocale } from \"./utils\";\nimport type { CalendarHeaderProps } from \"./types\";\n\nconst months = [\n \"january\",\n \"february\",\n \"march\",\n \"april\",\n \"may\",\n \"june\",\n \"july\",\n \"august\",\n \"september\",\n \"october\",\n \"november\",\n \"december\",\n];\n\nexport const CalendarHeader: React.FC<CalendarHeaderProps> = ({\n monthDate,\n decreaseMonth,\n increaseMonth,\n changeYear,\n changeMonth,\n prevMonthButtonDisabled,\n nextMonthButtonDisabled,\n locale,\n minDate,\n maxDate,\n contextMenuMaxHeight,\n testID,\n themeMode,\n themeProductContext,\n}) => {\n const handleChangeMonth = useCallback(\n (value: any) => {\n changeMonth(months.indexOf(value as string));\n },\n [changeMonth]\n );\n\n const handleChangeYear = useCallback(\n (value: any) => {\n changeYear(parseInt(value as string, 10));\n },\n [changeYear]\n );\n\n const monthOptions = useMemo(() => {\n return months.map((month, index) => ({\n label: getMonthInLocale(index, locale),\n value: month,\n }));\n }, [locale]);\n\n const yearOptions = useMemo(() => {\n const options = [];\n const yearStart = minDate ? minDate.getFullYear() : 1900;\n const yearEnd = maxDate\n ? maxDate.getFullYear()\n : new Date().getFullYear() + 100;\n for (let i = yearEnd; i >= yearStart; i--) {\n options.push({ value: i.toString(), label: i.toString() });\n }\n return options;\n }, [minDate, maxDate]);\n\n return (\n <Box\n testID={testID}\n width=\"100%\"\n flexDirection=\"row\"\n justifyContent=\"space-between\"\n alignItems=\"center\"\n marginBottom={16}\n gap={8}\n >\n <IconButton\n size=\"xs\"\n tone=\"mono\"\n variant=\"tertiary\"\n onPress={decreaseMonth}\n disabled={prevMonthButtonDisabled}\n icon={<ArrowLeft size={16} />}\n aria-label=\"Previous month\"\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n\n <Box flexDirection=\"row\" flex={1} gap={4}>\n <Box flex={1.5}>\n <Select\n value={months[monthDate.getMonth()]}\n onChange={handleChangeMonth}\n options={monthOptions}\n size=\"sm\"\n maxHeight={contextMenuMaxHeight}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n </Box>\n <Box flex={1}>\n <Select\n value={monthDate.getFullYear().toString()}\n onChange={handleChangeYear}\n options={yearOptions}\n size=\"sm\"\n maxHeight={contextMenuMaxHeight}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n </Box>\n </Box>\n\n <IconButton\n size=\"xs\"\n tone=\"mono\"\n variant=\"tertiary\"\n onPress={increaseMonth}\n disabled={nextMonthButtonDisabled}\n icon={<ArrowRight size={16} />}\n aria-label=\"Next month\"\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n </Box>\n );\n};\n","import { format, setMonth } from \"date-fns\";\nimport * as locales from \"date-fns/locale\";\nimport type { CalendarLocaleType } from \"./types\";\n\nconst defaultLocale = \"enUS\";\n\nexport function formatDate(\n date: Date,\n formatStr: string,\n locale: CalendarLocaleType = defaultLocale\n) {\n const localeObj = locales[locale] || locales[defaultLocale];\n\n return format(date, formatStr, {\n locale: localeObj,\n });\n}\n\nexport function getMonthInLocale(\n month: number,\n locale: CalendarLocaleType = defaultLocale\n) {\n return formatDate(setMonth(new Date(), month), \"LLLL\", locale);\n}\n","import React, { useMemo, useCallback } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme } from \"@xsolla/xui-core\";\nimport {\n addDays,\n eachDayOfInterval,\n endOfDay,\n endOfMonth,\n endOfWeek,\n format,\n isAfter,\n isBefore,\n isSameDay,\n isSameMonth,\n isToday,\n isWithinInterval,\n startOfDay,\n startOfMonth,\n startOfWeek,\n} from \"date-fns\";\nimport * as locales from \"date-fns/locale\";\nimport type { CalendarGridProps } from \"./types\";\n\n/** Width of a single day cell. */\nconst DAY_CELL_WIDTH = 40;\n/**\n * Natural width of the 7-column grid. The header and week rows are pinned to\n * this so the cells sit flush against each other: a range highlight has to read\n * as one continuous band, which it cannot do if the row distributes slack\n * between the cells. See FEP-834.\n */\nconst GRID_WIDTH = DAY_CELL_WIDTH * 7;\n\nexport const CalendarGrid: React.FC<CalendarGridProps> = ({\n currentMonth,\n locale = \"enUS\",\n firstDayOfWeek = 0,\n selectsRange = false,\n minDate,\n maxDate,\n startDate,\n endDate,\n selectedDate,\n selectingRange,\n onDayPress,\n testID,\n themeMode,\n themeProductContext,\n}) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const localeObj = (locales as any)[locale] || locales.enUS;\n\n const monthStart = startOfMonth(currentMonth);\n const monthEnd = endOfMonth(currentMonth);\n const weekStartsOn = (firstDayOfWeek ?? 0) as any;\n const calendarStart = startOfWeek(monthStart, { weekStartsOn });\n const calendarEnd = endOfWeek(monthEnd, { weekStartsOn });\n\n const days = eachDayOfInterval({ start: calendarStart, end: calendarEnd });\n\n const weekDays = useMemo(() => {\n return Array.from({ length: 7 }, (_, i) => {\n const day = addDays(calendarStart, i);\n return format(day, \"EEEEEE\", { locale: localeObj });\n });\n }, [calendarStart, localeObj]);\n\n const weeks = useMemo(() => {\n const weekArray: Date[][] = [];\n for (let i = 0; i < days.length; i += 7) {\n weekArray.push(days.slice(i, i + 7));\n }\n return weekArray;\n }, [days]);\n\n const isDateDisabled = useCallback(\n (date: Date) => {\n if (minDate && isBefore(date, startOfDay(minDate))) return true;\n if (maxDate && isAfter(date, endOfDay(maxDate))) return true;\n return false;\n },\n [minDate, maxDate]\n );\n\n const isDateInRange = useCallback(\n (date: Date) => {\n if (!selectsRange || !startDate) return false;\n const rangeEnd = endDate || selectingRange;\n if (!rangeEnd) return false;\n const start = startDate < rangeEnd ? startDate : rangeEnd;\n const end = startDate < rangeEnd ? rangeEnd : startDate;\n return isWithinInterval(date, {\n start: startOfDay(start),\n end: endOfDay(end),\n });\n },\n [selectsRange, startDate, endDate, selectingRange]\n );\n\n return (\n <Box testID={testID}>\n <Box\n flexDirection=\"row\"\n justifyContent=\"flex-start\"\n width={GRID_WIDTH}\n marginBottom={8}\n >\n {weekDays.map((day, i) => (\n <Box key={i} width={DAY_CELL_WIDTH} alignItems=\"center\">\n <Text\n fontSize={12}\n fontWeight=\"600\"\n color={theme.colors.content.tertiary}\n >\n {day.toUpperCase()}\n </Text>\n </Box>\n ))}\n </Box>\n\n <Box gap={2}>\n {weeks.map((week, i) => (\n <Box\n key={i}\n flexDirection=\"row\"\n justifyContent=\"flex-start\"\n width={GRID_WIDTH}\n >\n {week.map((day, j) => {\n const isOutsideMonth = !isSameMonth(day, currentMonth);\n const isSelected =\n (!selectsRange &&\n selectedDate &&\n isSameDay(day, selectedDate)) ||\n (selectsRange &&\n startDate &&\n endDate &&\n isSameDay(day, startDate) &&\n isSameDay(day, endDate));\n const isRangeStart =\n selectsRange && startDate && isSameDay(day, startDate);\n const isRangeEnd =\n selectsRange && endDate && isSameDay(day, endDate);\n const inRange = isDateInRange(day);\n const today = isToday(day);\n const disabled = isDateDisabled(day);\n\n let bgColor = \"transparent\";\n let textColor = theme.colors.content.primary;\n\n if (isSelected || isRangeStart || isRangeEnd) {\n bgColor = theme.colors.background.brand.primary;\n textColor = theme.colors.content.on.brand;\n } else if (inRange) {\n bgColor = theme.colors.overlay.brand;\n } else if (today) {\n bgColor = theme.colors.overlay.mono;\n }\n\n if (isOutsideMonth || disabled) {\n textColor = theme.colors.content.tertiary;\n }\n\n return (\n <Box\n key={j}\n width={DAY_CELL_WIDTH}\n height={32}\n alignItems=\"center\"\n justifyContent=\"center\"\n borderTopLeftRadius={isSelected || isRangeStart ? 4 : 0}\n borderTopRightRadius={isSelected || isRangeEnd ? 4 : 0}\n borderBottomLeftRadius={isSelected || isRangeStart ? 4 : 0}\n borderBottomRightRadius={isSelected || isRangeEnd ? 4 : 0}\n backgroundColor={bgColor}\n cursor={disabled || isOutsideMonth ? \"default\" : \"pointer\"}\n onPress={() =>\n !disabled && !isOutsideMonth && onDayPress?.(day)\n }\n hoverStyle={\n !disabled &&\n !isOutsideMonth &&\n !isSelected &&\n !isRangeStart &&\n !isRangeEnd\n ? { backgroundColor: theme.colors.overlay.mono }\n : undefined\n }\n >\n <Text\n color={textColor}\n fontSize={14}\n fontWeight={\n isSelected || isRangeStart || isRangeEnd ? \"600\" : \"400\"\n }\n >\n {format(day, \"d\")}\n </Text>\n </Box>\n );\n })}\n </Box>\n ))}\n </Box>\n </Box>\n );\n};\n","import React from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box } from \"@xsolla/xui-primitives\";\nimport { Tag } from \"@xsolla/xui-tag\";\nimport type { CalendarChipsProps } from \"./types\";\n\nexport const CalendarChips: React.FC<CalendarChipsProps> = ({\n chips,\n activeChip,\n onChipSelect,\n testID,\n themeMode,\n themeProductContext,\n}) => {\n if (!chips || chips.length === 0) return null;\n\n return (\n <Box\n testID={testID}\n flexDirection=\"row\"\n flexWrap=\"wrap\"\n gap={8}\n marginBottom={16}\n >\n {chips.map((chip) => {\n const isActive = activeChip === chip.value;\n return (\n <Box\n key={chip.value}\n onPress={() => onChipSelect?.(chip.value)}\n cursor=\"pointer\"\n >\n <Tag\n size=\"sm\"\n tone={isActive ? \"brand\" : \"primary\"}\n type={isActive ? \"solid\" : \"outlined\"}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n >\n {chip.label}\n </Tag>\n </Box>\n );\n })}\n </Box>\n );\n};\n","import { forwardRef, useCallback, useEffect, useState } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme } from \"@xsolla/xui-core\";\nimport { addMonths, subDays, subMonths, startOfDay } from \"date-fns\";\nimport { CalendarHeader } from \"./CalendarHeader\";\nimport { CalendarGrid } from \"./CalendarGrid\";\nimport { CalendarChips } from \"./CalendarChips\";\nimport type { DualCalendarProps } from \"./types\";\n\nexport const DualCalendar = forwardRef<any, DualCalendarProps>(\n (\n {\n locale = \"enUS\",\n onChange,\n startDate,\n endDate,\n contextMenuMaxHeight,\n topContent,\n bottomContent,\n chips,\n activeChip,\n onChipSelect,\n testID,\n minDate,\n maxDate,\n firstDayOfWeek = 0,\n month,\n initialMonth,\n themeMode,\n themeProductContext,\n },\n ref\n ) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n\n const [leftMonth, setLeftMonth] = useState<Date>(\n (month || initialMonth || startDate || new Date()) as Date\n );\n const [selectedStartDate, setSelectedStartDate] = useState<\n Date | null | undefined\n >(startDate);\n const [selectedEndDate, setSelectedEndDate] = useState<\n Date | null | undefined\n >(endDate);\n const [selectingRange, setSelectingRange] = useState<Date | null>(null);\n\n const rightMonth = addMonths(leftMonth, 1);\n\n useEffect(() => {\n setSelectedStartDate(startDate);\n setSelectedEndDate(endDate);\n if (month !== undefined) {\n setLeftMonth(month);\n }\n }, [startDate, endDate, month]);\n\n const handleDayPress = useCallback(\n (date: Date) => {\n const newDate = new Date(\n date.getFullYear(),\n date.getMonth(),\n date.getDate()\n );\n\n if (!selectedStartDate || (selectedStartDate && selectedEndDate)) {\n setSelectedStartDate(newDate);\n setSelectedEndDate(null);\n setSelectingRange(newDate);\n onChange?.([newDate, null]);\n } else {\n const start =\n selectedStartDate < newDate ? selectedStartDate : newDate;\n const end = selectedStartDate < newDate ? newDate : selectedStartDate;\n setSelectedStartDate(start);\n setSelectedEndDate(end);\n setSelectingRange(null);\n onChange?.([start, end]);\n }\n },\n [onChange, selectedStartDate, selectedEndDate]\n );\n\n const decreaseLeftMonth = useCallback(\n () => setLeftMonth((prev) => subMonths(prev, 1)),\n []\n );\n const increaseLeftMonth = useCallback(\n () => setLeftMonth((prev) => addMonths(prev, 1)),\n []\n );\n const changeLeftMonth = useCallback(\n (m: number) => setLeftMonth((prev) => new Date(prev.getFullYear(), m, 1)),\n []\n );\n const changeLeftYear = useCallback(\n (y: number) => setLeftMonth((prev) => new Date(y, prev.getMonth(), 1)),\n []\n );\n\n const decreaseRightMonth = useCallback(\n () => setLeftMonth((prev) => subMonths(prev, 1)),\n []\n );\n const increaseRightMonth = useCallback(\n () => setLeftMonth((prev) => addMonths(prev, 1)),\n []\n );\n const changeRightMonth = useCallback(\n (m: number) => setLeftMonth(new Date(rightMonth.getFullYear(), m - 1, 1)),\n [rightMonth]\n );\n const changeRightYear = useCallback(\n (y: number) => setLeftMonth(new Date(y, rightMonth.getMonth() - 1, 1)),\n [rightMonth]\n );\n\n const handleChipSelect = useCallback(\n (value: string | null) => {\n onChipSelect?.(value);\n\n const chip = chips?.find((c) => c.value === value);\n if (!chip || chip.days === undefined) return;\n\n const today = startOfDay(new Date());\n\n if (chip.days === 0) {\n setSelectedStartDate(today);\n setSelectedEndDate(today);\n setSelectingRange(null);\n setLeftMonth(today);\n onChange?.([today, today]);\n return;\n }\n\n const start = subDays(today, chip.days);\n setSelectedStartDate(start);\n setSelectedEndDate(today);\n setSelectingRange(null);\n setLeftMonth(start);\n onChange?.([start, today]);\n },\n [chips, onChange, onChipSelect]\n );\n\n return (\n <Box\n ref={ref}\n testID={testID}\n backgroundColor={theme.colors.layer.float}\n borderRadius={theme.shape.contextMenu.md.borderRadius}\n padding={16}\n overflow=\"hidden\"\n style={{\n boxShadow:\n \"0px 2px 3px 0px rgba(7, 7, 8, 0.2), 0px 6px 10px 4px rgba(7, 7, 8, 0.1)\",\n width: 624,\n }}\n >\n {topContent?.({ close: () => {} })}\n\n {chips && chips.length > 0 && (\n <CalendarChips\n chips={chips}\n activeChip={activeChip}\n onChipSelect={handleChipSelect}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n )}\n\n <Box flexDirection=\"row\" gap={16}>\n <Box flex={1}>\n <CalendarHeader\n monthDate={leftMonth}\n decreaseMonth={decreaseLeftMonth}\n increaseMonth={increaseLeftMonth}\n changeYear={changeLeftYear}\n changeMonth={changeLeftMonth}\n locale={locale}\n minDate={minDate}\n maxDate={maxDate}\n contextMenuMaxHeight={contextMenuMaxHeight}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n\n <CalendarGrid\n currentMonth={leftMonth}\n locale={locale}\n firstDayOfWeek={firstDayOfWeek}\n selectsRange\n minDate={minDate}\n maxDate={maxDate}\n startDate={selectedStartDate}\n endDate={selectedEndDate}\n selectingRange={selectingRange}\n onDayPress={handleDayPress}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n </Box>\n\n <Box flex={1}>\n <CalendarHeader\n monthDate={rightMonth}\n decreaseMonth={decreaseRightMonth}\n increaseMonth={increaseRightMonth}\n changeYear={changeRightYear}\n changeMonth={changeRightMonth}\n locale={locale}\n minDate={minDate}\n maxDate={maxDate}\n contextMenuMaxHeight={contextMenuMaxHeight}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n\n <CalendarGrid\n currentMonth={rightMonth}\n locale={locale}\n firstDayOfWeek={firstDayOfWeek}\n selectsRange\n minDate={minDate}\n maxDate={maxDate}\n startDate={selectedStartDate}\n endDate={selectedEndDate}\n selectingRange={selectingRange}\n onDayPress={handleDayPress}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n </Box>\n </Box>\n\n {bottomContent?.({ close: () => {} })}\n </Box>\n );\n }\n);\n\nDualCalendar.displayName = \"DualCalendar\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,gBAA6D;;;ACA7D,IAAAC,gBA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A,kBACA;AAAA,kBACA;AAAA;AAAA,cACF;AAAA,cAEA;AAAA,gBAAC;AAAA;AAAA,kBACC,cAAc;AAAA,kBACd;AAAA,kBACA;AAAA,kBACA,cAAY;AAAA,kBACZ;AAAA,kBACA;AAAA,kBACA,WAAW;AAAA,kBACX,SAAS;AAAA,kBACT;AAAA,kBACA,YAAY;AAAA,kBACZ;AAAA,kBACA;AAAA;AAAA,cACF;AAAA,eACF;AAAA,aACF;AAAA,UAEC,gBAAgB,EAAE,OAAO,MAAM;AAAA,UAAC,EAAE,CAAC;AAAA;AAAA;AAAA,IACtC;AAAA,EAEJ;AACF;AAEA,aAAa,cAAc;","names":["import_react","import_react","React","Tag","styled","React","import_styled_components","import_jsx_runtime","styled","import_xui_core","import_date_fns","import_react","import_jsx_runtime","index","import_react","import_date_fns","locales","import_jsx_runtime","import_jsx_runtime","import_jsx_runtime","import_react","import_xui_core","import_date_fns","import_jsx_runtime"]}
|
|
1
|
+
{"version":3,"sources":["../../src/index.tsx","../../src/Calendar.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/textTruncation.ts","../../src/CalendarHeader.tsx","../../src/utils.ts","../../src/CalendarGrid.tsx","../../src/CalendarChips.tsx","../../src/DualCalendar.tsx"],"sourcesContent":["export * from \"./Calendar\";\nexport * from \"./DualCalendar\";\nexport * from \"./CalendarHeader\";\nexport * from \"./CalendarGrid\";\nexport * from \"./CalendarChips\";\nexport * from \"./types\";\nexport * from \"./utils\";\n","import { forwardRef, useCallback, useEffect, useState } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme } from \"@xsolla/xui-core\";\nimport { addMonths, subDays, subMonths, startOfDay } from \"date-fns\";\nimport { CalendarHeader } from \"./CalendarHeader\";\nimport { CalendarGrid } from \"./CalendarGrid\";\nimport { CalendarChips } from \"./CalendarChips\";\nimport type { CalendarProps } from \"./types\";\n\nexport const Calendar = forwardRef<any, CalendarProps>(\n (\n {\n locale = \"enUS\",\n onChange,\n startDate,\n endDate,\n selectedDate,\n selectsRange = false,\n contextMenuMaxHeight,\n topContent,\n bottomContent,\n chips,\n activeChip,\n onChipSelect,\n testID,\n minDate,\n maxDate,\n firstDayOfWeek = 0,\n month,\n initialMonth,\n themeMode,\n themeProductContext,\n },\n ref\n ) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n\n const [currentMonth, setCurrentMonth] = useState<Date>(\n (month || initialMonth || selectedDate || startDate || new Date()) as Date\n );\n const [selectedStartDate, setSelectedStartDate] = useState<\n Date | null | undefined\n >(startDate);\n const [selectedEndDate, setSelectedEndDate] = useState<\n Date | null | undefined\n >(endDate);\n const [locSelectedDate, setLocSelectedDate] = useState<\n Date | null | undefined\n >(selectedDate);\n const [selectingRange, setSelectingRange] = useState<Date | null>(null);\n\n useEffect(() => {\n setSelectedStartDate(startDate);\n setSelectedEndDate(endDate);\n setLocSelectedDate(selectedDate);\n if (month !== undefined) {\n setCurrentMonth(month);\n }\n }, [startDate, endDate, selectedDate, month]);\n\n const handleChange = useCallback(\n (date: Date) => {\n const newDate = new Date(\n date.getFullYear(),\n date.getMonth(),\n date.getDate()\n );\n\n if (!selectsRange) {\n setLocSelectedDate(newDate);\n onChange?.(newDate);\n } else {\n if (!selectedStartDate || (selectedStartDate && selectedEndDate)) {\n setSelectedStartDate(newDate);\n setSelectedEndDate(null);\n setSelectingRange(newDate);\n onChange?.([newDate, null]);\n } else {\n const start =\n selectedStartDate < newDate ? selectedStartDate : newDate;\n const end =\n selectedStartDate < newDate ? newDate : selectedStartDate;\n setSelectedStartDate(start);\n setSelectedEndDate(end);\n setSelectingRange(null);\n onChange?.([start, end]);\n }\n }\n },\n [onChange, selectsRange, selectedStartDate, selectedEndDate]\n );\n\n const decreaseMonth = useCallback(\n () => setCurrentMonth((prev) => subMonths(prev, 1)),\n []\n );\n const increaseMonth = useCallback(\n () => setCurrentMonth((prev) => addMonths(prev, 1)),\n []\n );\n const changeMonth = useCallback(\n (m: number) =>\n setCurrentMonth((prev) => new Date(prev.getFullYear(), m, 1)),\n []\n );\n const changeYear = useCallback(\n (y: number) => setCurrentMonth((prev) => new Date(y, prev.getMonth(), 1)),\n []\n );\n\n const handleChipSelect = useCallback(\n (value: string | null) => {\n onChipSelect?.(value);\n\n const chip = chips?.find((c) => c.value === value);\n if (!chip || chip.days === undefined) return;\n\n const today = startOfDay(new Date());\n\n if (chip.days === 0) {\n if (selectsRange) {\n setSelectedStartDate(today);\n setSelectedEndDate(today);\n setSelectingRange(null);\n onChange?.([today, today]);\n } else {\n setLocSelectedDate(today);\n onChange?.(today);\n }\n setCurrentMonth(today);\n return;\n }\n\n const start = subDays(today, chip.days);\n if (selectsRange) {\n setSelectedStartDate(start);\n setSelectedEndDate(today);\n setSelectingRange(null);\n onChange?.([start, today]);\n } else {\n setLocSelectedDate(start);\n onChange?.(start);\n }\n setCurrentMonth(start);\n },\n [chips, selectsRange, onChange, onChipSelect]\n );\n\n return (\n <Box\n ref={ref}\n testID={testID}\n backgroundColor={theme.colors.layer.float}\n borderRadius={theme.shape.contextMenu.md.borderRadius}\n padding={16}\n overflow=\"hidden\"\n style={{\n boxShadow:\n \"0px 2px 3px 0px rgba(7, 7, 8, 0.2), 0px 6px 10px 4px rgba(7, 7, 8, 0.1)\",\n width: 312,\n }}\n >\n {topContent?.({ close: () => {} })}\n\n {chips && chips.length > 0 && (\n <CalendarChips\n chips={chips}\n activeChip={activeChip}\n onChipSelect={handleChipSelect}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n )}\n\n <CalendarHeader\n monthDate={currentMonth}\n decreaseMonth={decreaseMonth}\n increaseMonth={increaseMonth}\n changeYear={changeYear}\n changeMonth={changeMonth}\n locale={locale}\n minDate={minDate}\n maxDate={maxDate}\n contextMenuMaxHeight={contextMenuMaxHeight}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n\n <CalendarGrid\n currentMonth={currentMonth}\n locale={locale}\n firstDayOfWeek={firstDayOfWeek}\n selectsRange={selectsRange}\n minDate={minDate}\n maxDate={maxDate}\n startDate={selectedStartDate}\n endDate={selectedEndDate}\n selectedDate={locSelectedDate}\n selectingRange={selectingRange}\n onDayPress={handleChange}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n\n {bottomContent?.({ close: () => {} })}\n </Box>\n );\n }\n);\n\nCalendar.displayName = \"Calendar\";\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 /* Only emit overflow-x/y when explicitly set. Defaulting them to\n visible after overflow would override the shorthand and break\n clipping (e.g. OtherCard bottom-right promo image). */\n overflow: ${(props) => props.overflow || \"visible\"};\n ${(props) =>\n props.overflowX != null ? `overflow-x: ${props.overflowX};` : \"\"}\n ${(props) =>\n props.overflowY != null ? `overflow-y: ${props.overflowY};` : \"\"}\n z-index: ${(props) => props.zIndex};\n opacity: ${(props) =>\n props.opacity != null ? props.opacity : props.disabled ? 0.5 : 1};\n pointer-events: ${(props) => (props.disabled ? \"none\" : \"auto\")};\n\n /* \\`background\\` is emitted before \\`background-color\\` so a caller passing\n both still gets backgroundColor as the winner. Use the shorthand for a\n layered fill (e.g. an overlay tint over a resting surface colour), which\n a single background-color cannot express. */\n &:hover {\n ${(props) =>\n props.hoverStyle?.background &&\n `background: ${props.hoverStyle.background};`}\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?.background &&\n `background: ${props.pressStyle.background};`}\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 data-testid={dataTestId || testID}\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 \"opacity\",\n \"cursor\",\n \"fontSize\",\n \"fontWeight\",\n \"fontFamily\",\n \"textDecoration\",\n // Cross-platform layout prop that Text consumes as CSS, never as an\n // attribute. Pinned explicitly because it is now spread into the styled\n // component rather than destructured away before it can reach the DOM.\n \"numberOfLines\",\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\";\nimport { truncationStyles } from \"./textTruncation\";\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 /* Keep last: single-line truncation has to win over white-space above. */\n ${(props) => truncationStyles(props.numberOfLines)}\n`;\n\nexport const Text: React.FC<TextProps> = ({\n style,\n className,\n id,\n role,\n testID,\n \"data-testid\": dataTestId,\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","/**\n * Web implementation of the cross-platform `numberOfLines` text prop.\n *\n * Native maps `numberOfLines` straight onto `RNText`. A web `<span>` has no\n * equivalent, so emit the CSS that produces the same result.\n *\n * Two details matter for the single-line case:\n * - `text-overflow` only takes effect on a block container, so the inline\n * `<span>` is promoted to `display: block` and capped at `max-width: 100%`.\n * - `min-width: 0` lets the text shrink below its own content width when it\n * sits in a flex row. Without it a `nowrap` label keeps its full intrinsic\n * width and pushes its siblings (icons, chevrons) out of a fixed-width field.\n *\n * Returns an empty string when there is nothing to clamp, so the declaration\n * block stays untouched for the majority of callers.\n */\nexport const truncationStyles = (numberOfLines?: number): string => {\n if (!numberOfLines || numberOfLines < 1) return \"\";\n\n if (numberOfLines === 1) {\n return `\n display: block;\n max-width: 100%;\n min-width: 0;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n `;\n }\n\n return `\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: ${numberOfLines};\n line-clamp: ${numberOfLines};\n max-width: 100%;\n min-width: 0;\n overflow: hidden;\n `;\n};\n","import React, { useCallback, useMemo } from \"react\";\nimport { IconButton } from \"@xsolla/xui-button\";\nimport { Select } from \"@xsolla/xui-select\";\nimport { ArrowLeft, ArrowRight } from \"@xsolla/xui-icons-base\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box } from \"@xsolla/xui-primitives\";\nimport { getMonthInLocale } from \"./utils\";\nimport type { CalendarHeaderProps } from \"./types\";\n\nconst months = [\n \"january\",\n \"february\",\n \"march\",\n \"april\",\n \"may\",\n \"june\",\n \"july\",\n \"august\",\n \"september\",\n \"october\",\n \"november\",\n \"december\",\n];\n\nexport const CalendarHeader: React.FC<CalendarHeaderProps> = ({\n monthDate,\n decreaseMonth,\n increaseMonth,\n changeYear,\n changeMonth,\n prevMonthButtonDisabled,\n nextMonthButtonDisabled,\n locale,\n minDate,\n maxDate,\n contextMenuMaxHeight,\n testID,\n themeMode,\n themeProductContext,\n}) => {\n const handleChangeMonth = useCallback(\n (value: any) => {\n changeMonth(months.indexOf(value as string));\n },\n [changeMonth]\n );\n\n const handleChangeYear = useCallback(\n (value: any) => {\n changeYear(parseInt(value as string, 10));\n },\n [changeYear]\n );\n\n const monthOptions = useMemo(() => {\n return months.map((month, index) => ({\n label: getMonthInLocale(index, locale),\n value: month,\n }));\n }, [locale]);\n\n const yearOptions = useMemo(() => {\n const options = [];\n const yearStart = minDate ? minDate.getFullYear() : 1900;\n const yearEnd = maxDate\n ? maxDate.getFullYear()\n : new Date().getFullYear() + 100;\n for (let i = yearEnd; i >= yearStart; i--) {\n options.push({ value: i.toString(), label: i.toString() });\n }\n return options;\n }, [minDate, maxDate]);\n\n return (\n <Box\n testID={testID}\n width=\"100%\"\n flexDirection=\"row\"\n justifyContent=\"space-between\"\n alignItems=\"center\"\n marginBottom={16}\n gap={8}\n >\n <IconButton\n size=\"xs\"\n tone=\"mono\"\n variant=\"tertiary\"\n onPress={decreaseMonth}\n disabled={prevMonthButtonDisabled}\n icon={<ArrowLeft size={16} />}\n aria-label=\"Previous month\"\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n\n <Box flexDirection=\"row\" flex={1} gap={4}>\n <Box flex={1.5}>\n <Select\n value={months[monthDate.getMonth()]}\n onChange={handleChangeMonth}\n options={monthOptions}\n size=\"sm\"\n maxHeight={contextMenuMaxHeight}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n </Box>\n <Box flex={1}>\n <Select\n value={monthDate.getFullYear().toString()}\n onChange={handleChangeYear}\n options={yearOptions}\n size=\"sm\"\n maxHeight={contextMenuMaxHeight}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n </Box>\n </Box>\n\n <IconButton\n size=\"xs\"\n tone=\"mono\"\n variant=\"tertiary\"\n onPress={increaseMonth}\n disabled={nextMonthButtonDisabled}\n icon={<ArrowRight size={16} />}\n aria-label=\"Next month\"\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n </Box>\n );\n};\n","import { format, setMonth } from \"date-fns\";\nimport * as locales from \"date-fns/locale\";\nimport type { CalendarLocaleType } from \"./types\";\n\nconst defaultLocale = \"enUS\";\n\nexport function formatDate(\n date: Date,\n formatStr: string,\n locale: CalendarLocaleType = defaultLocale\n) {\n const localeObj = locales[locale] || locales[defaultLocale];\n\n return format(date, formatStr, {\n locale: localeObj,\n });\n}\n\nexport function getMonthInLocale(\n month: number,\n locale: CalendarLocaleType = defaultLocale\n) {\n return formatDate(setMonth(new Date(), month), \"LLLL\", locale);\n}\n","import React, { useMemo, useCallback, useState } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme } from \"@xsolla/xui-core\";\nimport {\n addDays,\n eachDayOfInterval,\n endOfDay,\n endOfMonth,\n endOfWeek,\n format,\n isAfter,\n isBefore,\n isSameDay,\n isSameMonth,\n isToday,\n isWithinInterval,\n startOfDay,\n startOfMonth,\n startOfWeek,\n} from \"date-fns\";\nimport * as locales from \"date-fns/locale\";\nimport type { CalendarGridProps } from \"./types\";\n\n/** Width of a single day cell. */\nconst DAY_CELL_WIDTH = 40;\n/**\n * Natural width of the 7-column grid. The header and week rows are pinned to\n * this so the cells sit flush against each other: a range highlight has to read\n * as one continuous band, which it cannot do if the row distributes slack\n * between the cells. See FEP-834.\n */\nconst GRID_WIDTH = DAY_CELL_WIDTH * 7;\n\nexport const CalendarGrid: React.FC<CalendarGridProps> = ({\n currentMonth,\n locale = \"enUS\",\n firstDayOfWeek = 0,\n selectsRange = false,\n minDate,\n maxDate,\n startDate,\n endDate,\n selectedDate,\n selectingRange,\n onDayPress,\n testID,\n themeMode,\n themeProductContext,\n}) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const localeObj = (locales as any)[locale] || locales.enUS;\n const [hoveredKey, setHoveredKey] = useState<string | null>(null);\n\n const monthStart = startOfMonth(currentMonth);\n const monthEnd = endOfMonth(currentMonth);\n const weekStartsOn = (firstDayOfWeek ?? 0) as any;\n const calendarStart = startOfWeek(monthStart, { weekStartsOn });\n const calendarEnd = endOfWeek(monthEnd, { weekStartsOn });\n\n const days = eachDayOfInterval({ start: calendarStart, end: calendarEnd });\n\n const weekDays = useMemo(() => {\n return Array.from({ length: 7 }, (_, i) => {\n const day = addDays(calendarStart, i);\n return format(day, \"EEEEEE\", { locale: localeObj });\n });\n }, [calendarStart, localeObj]);\n\n const weeks = useMemo(() => {\n const weekArray: Date[][] = [];\n for (let i = 0; i < days.length; i += 7) {\n weekArray.push(days.slice(i, i + 7));\n }\n return weekArray;\n }, [days]);\n\n const isDateDisabled = useCallback(\n (date: Date) => {\n if (minDate && isBefore(date, startOfDay(minDate))) return true;\n if (maxDate && isAfter(date, endOfDay(maxDate))) return true;\n return false;\n },\n [minDate, maxDate]\n );\n\n const isDateInRange = useCallback(\n (date: Date) => {\n if (!selectsRange || !startDate) return false;\n const rangeEnd = endDate || selectingRange;\n if (!rangeEnd) return false;\n const start = startDate < rangeEnd ? startDate : rangeEnd;\n const end = startDate < rangeEnd ? rangeEnd : startDate;\n return isWithinInterval(date, {\n start: startOfDay(start),\n end: endOfDay(end),\n });\n },\n [selectsRange, startDate, endDate, selectingRange]\n );\n\n return (\n <Box testID={testID}>\n <Box\n flexDirection=\"row\"\n justifyContent=\"flex-start\"\n width={GRID_WIDTH}\n marginBottom={8}\n >\n {weekDays.map((day, i) => (\n <Box key={i} width={DAY_CELL_WIDTH} alignItems=\"center\">\n <Text\n fontSize={12}\n fontWeight=\"600\"\n color={theme.colors.content.tertiary}\n >\n {day.toUpperCase()}\n </Text>\n </Box>\n ))}\n </Box>\n\n <Box gap={2}>\n {weeks.map((week, i) => (\n <Box\n key={i}\n flexDirection=\"row\"\n justifyContent=\"flex-start\"\n width={GRID_WIDTH}\n >\n {week.map((day, j) => {\n const dayKey = format(day, \"yyyy-MM-dd\");\n const isOutsideMonth = !isSameMonth(day, currentMonth);\n const isSelected =\n (!selectsRange &&\n selectedDate &&\n isSameDay(day, selectedDate)) ||\n (selectsRange &&\n startDate &&\n endDate &&\n isSameDay(day, startDate) &&\n isSameDay(day, endDate));\n const isRangeStart =\n selectsRange && startDate && isSameDay(day, startDate);\n const isRangeEnd =\n selectsRange && endDate && isSameDay(day, endDate);\n const inRange = isDateInRange(day);\n const today = isToday(day);\n const disabled = isDateDisabled(day);\n const isHoverable =\n !disabled && !isOutsideMonth && !isSelected && !isRangeStart && !isRangeEnd;\n const isHovered = isHoverable && hoveredKey === dayKey;\n\n let bgColor = \"transparent\";\n let textColor = theme.colors.content.primary;\n\n if (isSelected || isRangeStart || isRangeEnd || inRange) {\n bgColor = theme.colors.control.check.bg;\n textColor = theme.colors.control.check.icon;\n } else if (isHovered || today) {\n bgColor = theme.colors.control.check.bgHover;\n textColor = theme.colors.control.check.icon;\n } else if (isOutsideMonth || disabled) {\n textColor = theme.colors.control.text.disable;\n }\n\n return (\n <Box\n key={j}\n width={DAY_CELL_WIDTH}\n height={32}\n alignItems=\"center\"\n justifyContent=\"center\"\n borderTopLeftRadius={isSelected || isRangeStart ? 4 : 0}\n borderTopRightRadius={isSelected || isRangeEnd ? 4 : 0}\n borderBottomLeftRadius={isSelected || isRangeStart ? 4 : 0}\n borderBottomRightRadius={isSelected || isRangeEnd ? 4 : 0}\n backgroundColor={bgColor}\n cursor={disabled || isOutsideMonth ? \"default\" : \"pointer\"}\n onPress={() =>\n !disabled && !isOutsideMonth && onDayPress?.(day)\n }\n onMouseEnter={() =>\n isHoverable && setHoveredKey(dayKey)\n }\n onMouseLeave={() =>\n setHoveredKey((current) =>\n current === dayKey ? null : current\n )\n }\n hoverStyle={\n isHoverable\n ? { backgroundColor: theme.colors.control.check.bgHover }\n : undefined\n }\n >\n <Text\n color={textColor}\n fontSize={14}\n fontWeight={\n isSelected || isRangeStart || isRangeEnd ? \"600\" : \"400\"\n }\n >\n {format(day, \"d\")}\n </Text>\n </Box>\n );\n })}\n </Box>\n ))}\n </Box>\n </Box>\n );\n};\n","import React from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme } from \"@xsolla/xui-core\";\nimport type { CalendarChipsProps } from \"./types\";\n\nexport const CalendarChips: React.FC<CalendarChipsProps> = ({\n chips,\n activeChip,\n onChipSelect,\n testID,\n themeMode,\n themeProductContext,\n}) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const toggleColors = theme.colors.control.toggleButton;\n // Tag's sizing scale is a compact-chip scale; toggleButtonGroup's is a\n // full-button scale and renders oversized here. Only the colors come\n // from the toggle-button tokens (to match the Figma selected/hover states).\n const sizeStyles = theme.sizing.tag(\"sm\");\n const borderWidth = sizeStyles.borderWidth;\n\n if (!chips || chips.length === 0) return null;\n\n return (\n <Box\n testID={testID}\n flexDirection=\"row\"\n flexWrap=\"wrap\"\n gap={8}\n marginBottom={16}\n >\n {chips.map((chip) => {\n const isActive = activeChip === chip.value;\n const bgColor = isActive ? toggleColors.bgActive : toggleColors.bg;\n const textColor = isActive ? toggleColors.textActive : toggleColors.text;\n const borderColor = isActive\n ? toggleColors.borderActive\n : toggleColors.border;\n\n return (\n <Box\n key={chip.value}\n as=\"button\"\n role=\"radio\"\n aria-checked={isActive}\n testID={chip.value}\n onPress={() => onChipSelect?.(chip.value)}\n height={sizeStyles.height}\n paddingHorizontal={sizeStyles.padding}\n alignItems=\"center\"\n justifyContent=\"center\"\n backgroundColor={bgColor}\n borderWidth={borderWidth}\n borderColor={borderColor}\n borderStyle=\"solid\"\n borderRadius={sizeStyles.radius}\n cursor=\"pointer\"\n hoverStyle={\n !isActive\n ? {\n backgroundColor: toggleColors.bgHover,\n borderColor: toggleColors.borderHover,\n }\n : undefined\n }\n >\n <Text\n color={textColor}\n fontSize={sizeStyles.fontSize}\n fontWeight=\"400\"\n whiteSpace=\"nowrap\"\n >\n {chip.label}\n </Text>\n </Box>\n );\n })}\n </Box>\n );\n};\n","import { forwardRef, useCallback, useEffect, useState } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme } from \"@xsolla/xui-core\";\nimport { addMonths, subDays, subMonths, startOfDay } from \"date-fns\";\nimport { CalendarHeader } from \"./CalendarHeader\";\nimport { CalendarGrid } from \"./CalendarGrid\";\nimport { CalendarChips } from \"./CalendarChips\";\nimport type { DualCalendarProps } from \"./types\";\n\nexport const DualCalendar = forwardRef<any, DualCalendarProps>(\n (\n {\n locale = \"enUS\",\n onChange,\n startDate,\n endDate,\n contextMenuMaxHeight,\n topContent,\n bottomContent,\n chips,\n activeChip,\n onChipSelect,\n testID,\n minDate,\n maxDate,\n firstDayOfWeek = 0,\n month,\n initialMonth,\n themeMode,\n themeProductContext,\n },\n ref\n ) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n\n const [leftMonth, setLeftMonth] = useState<Date>(\n (month || initialMonth || startDate || new Date()) as Date\n );\n const [selectedStartDate, setSelectedStartDate] = useState<\n Date | null | undefined\n >(startDate);\n const [selectedEndDate, setSelectedEndDate] = useState<\n Date | null | undefined\n >(endDate);\n const [selectingRange, setSelectingRange] = useState<Date | null>(null);\n\n const rightMonth = addMonths(leftMonth, 1);\n\n useEffect(() => {\n setSelectedStartDate(startDate);\n setSelectedEndDate(endDate);\n if (month !== undefined) {\n setLeftMonth(month);\n }\n }, [startDate, endDate, month]);\n\n const handleDayPress = useCallback(\n (date: Date) => {\n const newDate = new Date(\n date.getFullYear(),\n date.getMonth(),\n date.getDate()\n );\n\n if (!selectedStartDate || (selectedStartDate && selectedEndDate)) {\n setSelectedStartDate(newDate);\n setSelectedEndDate(null);\n setSelectingRange(newDate);\n onChange?.([newDate, null]);\n } else {\n const start =\n selectedStartDate < newDate ? selectedStartDate : newDate;\n const end = selectedStartDate < newDate ? newDate : selectedStartDate;\n setSelectedStartDate(start);\n setSelectedEndDate(end);\n setSelectingRange(null);\n onChange?.([start, end]);\n }\n },\n [onChange, selectedStartDate, selectedEndDate]\n );\n\n const decreaseLeftMonth = useCallback(\n () => setLeftMonth((prev) => subMonths(prev, 1)),\n []\n );\n const increaseLeftMonth = useCallback(\n () => setLeftMonth((prev) => addMonths(prev, 1)),\n []\n );\n const changeLeftMonth = useCallback(\n (m: number) => setLeftMonth((prev) => new Date(prev.getFullYear(), m, 1)),\n []\n );\n const changeLeftYear = useCallback(\n (y: number) => setLeftMonth((prev) => new Date(y, prev.getMonth(), 1)),\n []\n );\n\n const decreaseRightMonth = useCallback(\n () => setLeftMonth((prev) => subMonths(prev, 1)),\n []\n );\n const increaseRightMonth = useCallback(\n () => setLeftMonth((prev) => addMonths(prev, 1)),\n []\n );\n const changeRightMonth = useCallback(\n (m: number) => setLeftMonth(new Date(rightMonth.getFullYear(), m - 1, 1)),\n [rightMonth]\n );\n const changeRightYear = useCallback(\n (y: number) => setLeftMonth(new Date(y, rightMonth.getMonth() - 1, 1)),\n [rightMonth]\n );\n\n const handleChipSelect = useCallback(\n (value: string | null) => {\n onChipSelect?.(value);\n\n const chip = chips?.find((c) => c.value === value);\n if (!chip || chip.days === undefined) return;\n\n const today = startOfDay(new Date());\n\n if (chip.days === 0) {\n setSelectedStartDate(today);\n setSelectedEndDate(today);\n setSelectingRange(null);\n setLeftMonth(today);\n onChange?.([today, today]);\n return;\n }\n\n const start = subDays(today, chip.days);\n setSelectedStartDate(start);\n setSelectedEndDate(today);\n setSelectingRange(null);\n setLeftMonth(start);\n onChange?.([start, today]);\n },\n [chips, onChange, onChipSelect]\n );\n\n return (\n <Box\n ref={ref}\n testID={testID}\n backgroundColor={theme.colors.layer.float}\n borderRadius={theme.shape.contextMenu.md.borderRadius}\n padding={16}\n overflow=\"hidden\"\n style={{\n boxShadow:\n \"0px 2px 3px 0px rgba(7, 7, 8, 0.2), 0px 6px 10px 4px rgba(7, 7, 8, 0.1)\",\n width: 624,\n }}\n >\n {topContent?.({ close: () => {} })}\n\n {chips && chips.length > 0 && (\n <CalendarChips\n chips={chips}\n activeChip={activeChip}\n onChipSelect={handleChipSelect}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n )}\n\n <Box flexDirection=\"row\" gap={16}>\n <Box flex={1}>\n <CalendarHeader\n monthDate={leftMonth}\n decreaseMonth={decreaseLeftMonth}\n increaseMonth={increaseLeftMonth}\n changeYear={changeLeftYear}\n changeMonth={changeLeftMonth}\n locale={locale}\n minDate={minDate}\n maxDate={maxDate}\n contextMenuMaxHeight={contextMenuMaxHeight}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n\n <CalendarGrid\n currentMonth={leftMonth}\n locale={locale}\n firstDayOfWeek={firstDayOfWeek}\n selectsRange\n minDate={minDate}\n maxDate={maxDate}\n startDate={selectedStartDate}\n endDate={selectedEndDate}\n selectingRange={selectingRange}\n onDayPress={handleDayPress}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n </Box>\n\n <Box flex={1}>\n <CalendarHeader\n monthDate={rightMonth}\n decreaseMonth={decreaseRightMonth}\n increaseMonth={increaseRightMonth}\n changeYear={changeRightYear}\n changeMonth={changeRightMonth}\n locale={locale}\n minDate={minDate}\n maxDate={maxDate}\n contextMenuMaxHeight={contextMenuMaxHeight}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n\n <CalendarGrid\n currentMonth={rightMonth}\n locale={locale}\n firstDayOfWeek={firstDayOfWeek}\n selectsRange\n minDate={minDate}\n maxDate={maxDate}\n startDate={selectedStartDate}\n endDate={selectedEndDate}\n selectingRange={selectingRange}\n onDayPress={handleDayPress}\n themeMode={themeMode}\n themeProductContext={themeProductContext}\n />\n </Box>\n </Box>\n\n {bottomContent?.({ close: () => {} })}\n </Box>\n );\n }\n);\n\nDualCalendar.displayName = \"DualCalendar\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,gBAA6D;;;ACA7D,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,G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A,UACF;AAAA,UAGF,8CAAC,OAAI,eAAc,OAAM,KAAK,IAC5B;AAAA,0DAAC,OAAI,MAAM,GACT;AAAA;AAAA,gBAAC;AAAA;AAAA,kBACC,WAAW;AAAA,kBACX,eAAe;AAAA,kBACf,eAAe;AAAA,kBACf,YAAY;AAAA,kBACZ,aAAa;AAAA,kBACb;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA;AAAA,cACF;AAAA,cAEA;AAAA,gBAAC;AAAA;AAAA,kBACC,cAAc;AAAA,kBACd;AAAA,kBACA;AAAA,kBACA,cAAY;AAAA,kBACZ;AAAA,kBACA;AAAA,kBACA,WAAW;AAAA,kBACX,SAAS;AAAA,kBACT;AAAA,kBACA,YAAY;AAAA,kBACZ;AAAA,kBACA;AAAA;AAAA,cACF;AAAA,eACF;AAAA,YAEA,8CAAC,OAAI,MAAM,GACT;AAAA;AAAA,gBAAC;AAAA;AAAA,kBACC,WAAW;AAAA,kBACX,eAAe;AAAA,kBACf,eAAe;AAAA,kBACf,YAAY;AAAA,kBACZ,aAAa;AAAA,kBACb;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA,kBACA;AAAA;AAAA,cACF;AAAA,cAEA;AAAA,gBAAC;AAAA;AAAA,kBACC,cAAc;AAAA,kBACd;AAAA,kBACA;AAAA,kBACA,cAAY;AAAA,kBACZ;AAAA,kBACA;AAAA,kBACA,WAAW;AAAA,kBACX,SAAS;AAAA,kBACT;AAAA,kBACA,YAAY;AAAA,kBACZ;AAAA,kBACA;AAAA;AAAA,cACF;AAAA,eACF;AAAA,aACF;AAAA,UAEC,gBAAgB,EAAE,OAAO,MAAM;AAAA,UAAC,EAAE,CAAC;AAAA;AAAA;AAAA,IACtC;AAAA,EAEJ;AACF;AAEA,aAAa,cAAc;","names":["import_react","import_react","React","styled","React","import_styled_components","import_jsx_runtime","styled","import_xui_core","import_date_fns","import_react","import_jsx_runtime","index","import_react","import_date_fns","locales","import_jsx_runtime","import_xui_core","import_jsx_runtime","import_jsx_runtime","import_react","import_xui_core","import_date_fns","import_jsx_runtime"]}
|
package/web/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// src/Calendar.tsx
|
|
2
|
-
import { forwardRef, useCallback as useCallback3, useEffect, useState } from "react";
|
|
2
|
+
import { forwardRef, useCallback as useCallback3, useEffect, useState as useState2 } from "react";
|
|
3
3
|
|
|
4
4
|
// ../../foundation/primitives-web/src/Box.tsx
|
|
5
5
|
import React2 from "react";
|
|
@@ -61,7 +61,7 @@ function shouldForwardProp(key) {
|
|
|
61
61
|
function createFilteredElement(defaultTag) {
|
|
62
62
|
const Component = React.forwardRef(
|
|
63
63
|
({ children, elementType, ...props }, ref) => {
|
|
64
|
-
const
|
|
64
|
+
const Tag = elementType || defaultTag;
|
|
65
65
|
const htmlProps = {};
|
|
66
66
|
for (const key of Object.keys(props)) {
|
|
67
67
|
if (shouldForwardProp(key)) {
|
|
@@ -69,7 +69,7 @@ function createFilteredElement(defaultTag) {
|
|
|
69
69
|
}
|
|
70
70
|
}
|
|
71
71
|
return React.createElement(
|
|
72
|
-
|
|
72
|
+
Tag,
|
|
73
73
|
{ ref, ...htmlProps },
|
|
74
74
|
children
|
|
75
75
|
);
|
|
@@ -333,7 +333,7 @@ var Text = ({
|
|
|
333
333
|
};
|
|
334
334
|
|
|
335
335
|
// src/Calendar.tsx
|
|
336
|
-
import { useResolvedTheme as
|
|
336
|
+
import { useResolvedTheme as useResolvedTheme3 } from "@xsolla/xui-core";
|
|
337
337
|
import { addMonths, subDays, subMonths, startOfDay as startOfDay2 } from "date-fns";
|
|
338
338
|
|
|
339
339
|
// src/CalendarHeader.tsx
|
|
@@ -486,7 +486,7 @@ var CalendarHeader = ({
|
|
|
486
486
|
};
|
|
487
487
|
|
|
488
488
|
// src/CalendarGrid.tsx
|
|
489
|
-
import { useMemo as useMemo2, useCallback as useCallback2 } from "react";
|
|
489
|
+
import { useMemo as useMemo2, useCallback as useCallback2, useState } from "react";
|
|
490
490
|
import { useResolvedTheme } from "@xsolla/xui-core";
|
|
491
491
|
import {
|
|
492
492
|
addDays,
|
|
@@ -527,6 +527,7 @@ var CalendarGrid = ({
|
|
|
527
527
|
}) => {
|
|
528
528
|
const { theme } = useResolvedTheme({ themeMode, themeProductContext });
|
|
529
529
|
const localeObj = locales2[locale] || locales2.enUS;
|
|
530
|
+
const [hoveredKey, setHoveredKey] = useState(null);
|
|
530
531
|
const monthStart = startOfMonth(currentMonth);
|
|
531
532
|
const monthEnd = endOfMonth(currentMonth);
|
|
532
533
|
const weekStartsOn = firstDayOfWeek ?? 0;
|
|
@@ -594,6 +595,7 @@ var CalendarGrid = ({
|
|
|
594
595
|
justifyContent: "flex-start",
|
|
595
596
|
width: GRID_WIDTH,
|
|
596
597
|
children: week.map((day, j) => {
|
|
598
|
+
const dayKey = format2(day, "yyyy-MM-dd");
|
|
597
599
|
const isOutsideMonth = !isSameMonth(day, currentMonth);
|
|
598
600
|
const isSelected = !selectsRange && selectedDate && isSameDay(day, selectedDate) || selectsRange && startDate && endDate && isSameDay(day, startDate) && isSameDay(day, endDate);
|
|
599
601
|
const isRangeStart = selectsRange && startDate && isSameDay(day, startDate);
|
|
@@ -601,18 +603,18 @@ var CalendarGrid = ({
|
|
|
601
603
|
const inRange = isDateInRange(day);
|
|
602
604
|
const today = isToday(day);
|
|
603
605
|
const disabled = isDateDisabled(day);
|
|
606
|
+
const isHoverable = !disabled && !isOutsideMonth && !isSelected && !isRangeStart && !isRangeEnd;
|
|
607
|
+
const isHovered = isHoverable && hoveredKey === dayKey;
|
|
604
608
|
let bgColor = "transparent";
|
|
605
609
|
let textColor = theme.colors.content.primary;
|
|
606
|
-
if (isSelected || isRangeStart || isRangeEnd) {
|
|
607
|
-
bgColor = theme.colors.
|
|
608
|
-
textColor = theme.colors.
|
|
609
|
-
} else if (
|
|
610
|
-
bgColor = theme.colors.
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
if (isOutsideMonth || disabled) {
|
|
615
|
-
textColor = theme.colors.content.tertiary;
|
|
610
|
+
if (isSelected || isRangeStart || isRangeEnd || inRange) {
|
|
611
|
+
bgColor = theme.colors.control.check.bg;
|
|
612
|
+
textColor = theme.colors.control.check.icon;
|
|
613
|
+
} else if (isHovered || today) {
|
|
614
|
+
bgColor = theme.colors.control.check.bgHover;
|
|
615
|
+
textColor = theme.colors.control.check.icon;
|
|
616
|
+
} else if (isOutsideMonth || disabled) {
|
|
617
|
+
textColor = theme.colors.control.text.disable;
|
|
616
618
|
}
|
|
617
619
|
return /* @__PURE__ */ jsx4(
|
|
618
620
|
Box,
|
|
@@ -628,7 +630,11 @@ var CalendarGrid = ({
|
|
|
628
630
|
backgroundColor: bgColor,
|
|
629
631
|
cursor: disabled || isOutsideMonth ? "default" : "pointer",
|
|
630
632
|
onPress: () => !disabled && !isOutsideMonth && onDayPress?.(day),
|
|
631
|
-
|
|
633
|
+
onMouseEnter: () => isHoverable && setHoveredKey(dayKey),
|
|
634
|
+
onMouseLeave: () => setHoveredKey(
|
|
635
|
+
(current) => current === dayKey ? null : current
|
|
636
|
+
),
|
|
637
|
+
hoverStyle: isHoverable ? { backgroundColor: theme.colors.control.check.bgHover } : void 0,
|
|
632
638
|
children: /* @__PURE__ */ jsx4(
|
|
633
639
|
Text,
|
|
634
640
|
{
|
|
@@ -649,7 +655,7 @@ var CalendarGrid = ({
|
|
|
649
655
|
};
|
|
650
656
|
|
|
651
657
|
// src/CalendarChips.tsx
|
|
652
|
-
import {
|
|
658
|
+
import { useResolvedTheme as useResolvedTheme2 } from "@xsolla/xui-core";
|
|
653
659
|
import { jsx as jsx5 } from "react/jsx-runtime";
|
|
654
660
|
var CalendarChips = ({
|
|
655
661
|
chips,
|
|
@@ -659,6 +665,10 @@ var CalendarChips = ({
|
|
|
659
665
|
themeMode,
|
|
660
666
|
themeProductContext
|
|
661
667
|
}) => {
|
|
668
|
+
const { theme } = useResolvedTheme2({ themeMode, themeProductContext });
|
|
669
|
+
const toggleColors = theme.colors.control.toggleButton;
|
|
670
|
+
const sizeStyles = theme.sizing.tag("sm");
|
|
671
|
+
const borderWidth = sizeStyles.borderWidth;
|
|
662
672
|
if (!chips || chips.length === 0) return null;
|
|
663
673
|
return /* @__PURE__ */ jsx5(
|
|
664
674
|
Box,
|
|
@@ -670,19 +680,38 @@ var CalendarChips = ({
|
|
|
670
680
|
marginBottom: 16,
|
|
671
681
|
children: chips.map((chip) => {
|
|
672
682
|
const isActive = activeChip === chip.value;
|
|
683
|
+
const bgColor = isActive ? toggleColors.bgActive : toggleColors.bg;
|
|
684
|
+
const textColor = isActive ? toggleColors.textActive : toggleColors.text;
|
|
685
|
+
const borderColor = isActive ? toggleColors.borderActive : toggleColors.border;
|
|
673
686
|
return /* @__PURE__ */ jsx5(
|
|
674
687
|
Box,
|
|
675
688
|
{
|
|
689
|
+
as: "button",
|
|
690
|
+
role: "radio",
|
|
691
|
+
"aria-checked": isActive,
|
|
692
|
+
testID: chip.value,
|
|
676
693
|
onPress: () => onChipSelect?.(chip.value),
|
|
694
|
+
height: sizeStyles.height,
|
|
695
|
+
paddingHorizontal: sizeStyles.padding,
|
|
696
|
+
alignItems: "center",
|
|
697
|
+
justifyContent: "center",
|
|
698
|
+
backgroundColor: bgColor,
|
|
699
|
+
borderWidth,
|
|
700
|
+
borderColor,
|
|
701
|
+
borderStyle: "solid",
|
|
702
|
+
borderRadius: sizeStyles.radius,
|
|
677
703
|
cursor: "pointer",
|
|
704
|
+
hoverStyle: !isActive ? {
|
|
705
|
+
backgroundColor: toggleColors.bgHover,
|
|
706
|
+
borderColor: toggleColors.borderHover
|
|
707
|
+
} : void 0,
|
|
678
708
|
children: /* @__PURE__ */ jsx5(
|
|
679
|
-
|
|
709
|
+
Text,
|
|
680
710
|
{
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
themeProductContext,
|
|
711
|
+
color: textColor,
|
|
712
|
+
fontSize: sizeStyles.fontSize,
|
|
713
|
+
fontWeight: "400",
|
|
714
|
+
whiteSpace: "nowrap",
|
|
686
715
|
children: chip.label
|
|
687
716
|
}
|
|
688
717
|
)
|
|
@@ -719,14 +748,14 @@ var Calendar = forwardRef(
|
|
|
719
748
|
themeMode,
|
|
720
749
|
themeProductContext
|
|
721
750
|
}, ref) => {
|
|
722
|
-
const { theme } =
|
|
723
|
-
const [currentMonth, setCurrentMonth] =
|
|
751
|
+
const { theme } = useResolvedTheme3({ themeMode, themeProductContext });
|
|
752
|
+
const [currentMonth, setCurrentMonth] = useState2(
|
|
724
753
|
month || initialMonth || selectedDate || startDate || /* @__PURE__ */ new Date()
|
|
725
754
|
);
|
|
726
|
-
const [selectedStartDate, setSelectedStartDate] =
|
|
727
|
-
const [selectedEndDate, setSelectedEndDate] =
|
|
728
|
-
const [locSelectedDate, setLocSelectedDate] =
|
|
729
|
-
const [selectingRange, setSelectingRange] =
|
|
755
|
+
const [selectedStartDate, setSelectedStartDate] = useState2(startDate);
|
|
756
|
+
const [selectedEndDate, setSelectedEndDate] = useState2(endDate);
|
|
757
|
+
const [locSelectedDate, setLocSelectedDate] = useState2(selectedDate);
|
|
758
|
+
const [selectingRange, setSelectingRange] = useState2(null);
|
|
730
759
|
useEffect(() => {
|
|
731
760
|
setSelectedStartDate(startDate);
|
|
732
761
|
setSelectedEndDate(endDate);
|
|
@@ -882,8 +911,8 @@ var Calendar = forwardRef(
|
|
|
882
911
|
Calendar.displayName = "Calendar";
|
|
883
912
|
|
|
884
913
|
// src/DualCalendar.tsx
|
|
885
|
-
import { forwardRef as forwardRef2, useCallback as useCallback4, useEffect as useEffect2, useState as
|
|
886
|
-
import { useResolvedTheme as
|
|
914
|
+
import { forwardRef as forwardRef2, useCallback as useCallback4, useEffect as useEffect2, useState as useState3 } from "react";
|
|
915
|
+
import { useResolvedTheme as useResolvedTheme4 } from "@xsolla/xui-core";
|
|
887
916
|
import { addMonths as addMonths2, subDays as subDays2, subMonths as subMonths2, startOfDay as startOfDay3 } from "date-fns";
|
|
888
917
|
import { jsx as jsx7, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
889
918
|
var DualCalendar = forwardRef2(
|
|
@@ -907,13 +936,13 @@ var DualCalendar = forwardRef2(
|
|
|
907
936
|
themeMode,
|
|
908
937
|
themeProductContext
|
|
909
938
|
}, ref) => {
|
|
910
|
-
const { theme } =
|
|
911
|
-
const [leftMonth, setLeftMonth] =
|
|
939
|
+
const { theme } = useResolvedTheme4({ themeMode, themeProductContext });
|
|
940
|
+
const [leftMonth, setLeftMonth] = useState3(
|
|
912
941
|
month || initialMonth || startDate || /* @__PURE__ */ new Date()
|
|
913
942
|
);
|
|
914
|
-
const [selectedStartDate, setSelectedStartDate] =
|
|
915
|
-
const [selectedEndDate, setSelectedEndDate] =
|
|
916
|
-
const [selectingRange, setSelectingRange] =
|
|
943
|
+
const [selectedStartDate, setSelectedStartDate] = useState3(startDate);
|
|
944
|
+
const [selectedEndDate, setSelectedEndDate] = useState3(endDate);
|
|
945
|
+
const [selectingRange, setSelectingRange] = useState3(null);
|
|
917
946
|
const rightMonth = addMonths2(leftMonth, 1);
|
|
918
947
|
useEffect2(() => {
|
|
919
948
|
setSelectedStartDate(startDate);
|