@skbkontur/react-ui 6.4.2 → 6.4.3-5e1c3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/Calendar/DayCellView.styles.js +1 -1
- package/components/Calendar/DayCellView.styles.js.map +1 -1
- package/components/DateRangePicker/DateRangePicker.styles.js +1 -1
- package/components/DateRangePicker/DateRangePicker.styles.js.map +1 -1
- package/components/FileUploader/FileUploader.styles.js +3 -3
- package/components/FileUploader/FileUploader.styles.js.map +1 -1
- package/components/FileUploader/FileUploaderFile.styles.js +2 -2
- package/components/FileUploader/FileUploaderFile.styles.js.map +1 -1
- package/components/FileUploader/FileUploaderFileList/FileUploaderFileList.styles.js +3 -3
- package/components/FileUploader/FileUploaderFileList/FileUploaderFileList.styles.js.map +1 -1
- package/components/FxInput/FxInput.js +1 -1
- package/components/FxInput/FxInput.js.map +1 -1
- package/components/MenuItem/MenuItem.js +9 -3
- package/components/MenuItem/MenuItem.js.map +1 -1
- package/components/MenuItem/MenuItem.styles.js +3 -3
- package/components/MenuItem/MenuItem.styles.js.map +1 -1
- package/components/SidePage/SidePage.d.ts +4 -0
- package/components/SidePage/SidePage.js +17 -1
- package/components/SidePage/SidePage.js.map +1 -1
- package/components/SidePage/SidePageContext.d.ts +2 -0
- package/components/SidePage/SidePageContext.js.map +1 -1
- package/components/SidePage/SidePageFooter.js +4 -1
- package/components/SidePage/SidePageFooter.js.map +1 -1
- package/components/SidePage/SidePageHeader.d.ts +1 -0
- package/components/SidePage/SidePageHeader.js +10 -1
- package/components/SidePage/SidePageHeader.js.map +1 -1
- package/components/Tabs/Tab.d.ts +16 -4
- package/components/Tabs/Tab.js.map +1 -1
- package/components/Tabs/Tab.styles.js +4 -4
- package/components/Tabs/Tab.styles.js.map +1 -1
- package/components/Toggle/Toggle.styles.js +1 -1
- package/components/Toggle/Toggle.styles.js.map +1 -1
- package/components/Token/Token.styles.js +2 -2
- package/components/Token/Token.styles.js.map +1 -1
- package/internal/DateSelect/DateSelect.styles.js +1 -1
- package/internal/DateSelect/DateSelect.styles.js.map +1 -1
- package/internal/themes/BasicTheme.d.ts +40 -0
- package/internal/themes/BasicTheme.js +72 -0
- package/internal/themes/BasicTheme.js.map +1 -1
- package/internal/themes/DarkTheme6_0.js +19 -0
- package/internal/themes/DarkTheme6_0.js.map +1 -1
- package/internal/themes/DarkTheme6_5.d.ts +1 -0
- package/internal/themes/DarkTheme6_5.js +87 -0
- package/internal/themes/DarkTheme6_5.js.map +1 -0
- package/internal/themes/LightTheme6_5.d.ts +1 -0
- package/internal/themes/LightTheme6_5.js +87 -0
- package/internal/themes/LightTheme6_5.js.map +1 -0
- package/lib/theming/ThemeVersions.d.ts +1 -1
- package/lib/theming/ThemeVersions.js.map +1 -1
- package/lib/theming/themes/DarkTheme.d.ts +1 -0
- package/lib/theming/themes/DarkTheme.js +3 -1
- package/lib/theming/themes/DarkTheme.js.map +1 -1
- package/lib/theming/themes/LightTheme.d.ts +1 -0
- package/lib/theming/themes/LightTheme.js +3 -1
- package/lib/theming/themes/LightTheme.js.map +1 -1
- package/package.json +1 -1
|
@@ -11,7 +11,7 @@ export var getStyles = memoizeGetStyles(function (_a) {
|
|
|
11
11
|
return css(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n flex: 1 1 ", ";\n height: ", ";\n "], ["\n flex: 1 1 ", ";\n height: ", ";\n "])), t.calendarCellWidth, t.calendarCellHeight);
|
|
12
12
|
},
|
|
13
13
|
day: function (t) {
|
|
14
|
-
return css(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n ", ";\n width: 100%;\n height: 100%;\n\n background: ", ";\n border: 1px solid transparent;\n font-size: ", ";\n padding: 0;\n text-align: center;\n user-select: none;\n position: relative;\n line-height: ", ";\n border-radius: ", ";\n transition:\n 0.15s ease background-color,\n 0.15s ease opacity;\n\n // Expand the clickable area\n &:before {\n content: '';\n position: absolute;\n left: -1px;\n top: -1px;\n width: calc(100% + 2px);\n height: calc(100% + 2px);\n }\n\n @media (hover: hover) {\n &:hover {\n background-color: ", ";\n color: ", ";\n cursor: pointer;\n }\n }\n\n &:disabled {\n opacity: 0.5;\n pointer-events: none;\n }\n &:active:
|
|
14
|
+
return css(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n ", ";\n width: 100%;\n height: 100%;\n\n background: ", ";\n border: 1px solid transparent;\n font-size: ", ";\n padding: 0;\n text-align: center;\n user-select: none;\n position: relative;\n line-height: ", ";\n border-radius: ", ";\n transition:\n 0.15s ease background-color,\n 0.15s ease opacity;\n\n // Expand the clickable area\n &:before {\n content: '';\n position: absolute;\n left: -1px;\n top: -1px;\n width: calc(100% + 2px);\n height: calc(100% + 2px);\n }\n\n @media (hover: hover) {\n &:hover {\n background-color: ", ";\n color: ", ";\n cursor: pointer;\n }\n }\n\n &:disabled {\n opacity: 0.5;\n pointer-events: none;\n }\n &:active:enabled:not([data-visual-state-selected]) {\n background-color: ", ";\n color: ", ";\n }\n "], ["\n ", ";\n width: 100%;\n height: 100%;\n\n background: ", ";\n border: 1px solid transparent;\n font-size: ", ";\n padding: 0;\n text-align: center;\n user-select: none;\n position: relative;\n line-height: ", ";\n border-radius: ", ";\n transition:\n 0.15s ease background-color,\n 0.15s ease opacity;\n\n // Expand the clickable area\n &:before {\n content: '';\n position: absolute;\n left: -1px;\n top: -1px;\n width: calc(100% + 2px);\n height: calc(100% + 2px);\n }\n\n @media (hover: hover) {\n &:hover {\n background-color: ", ";\n color: ", ";\n cursor: pointer;\n }\n }\n\n &:disabled {\n opacity: 0.5;\n pointer-events: none;\n }\n &:active:enabled:not([data-visual-state-selected]) {\n background-color: ", ";\n color: ", ";\n }\n "])), resetButton(), t.calendarCellBg, t.calendarCellFontSize, t.calendarCellLineHeight, t.calendarCellBorderRadius, t.calendarCellHoverBgColor, t.calendarCellHoverColor, t.calendarCellPressedBgColor, t.calendarCellActiveHoverColor);
|
|
15
15
|
},
|
|
16
16
|
selected: function (t) {
|
|
17
17
|
return css(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n background-color: ", ";\n color: ", ";\n "], ["\n background-color: ", ";\n color: ", ";\n "])), t.calendarCellSelectedBgColor, t.calendarCellSelectedFontColor);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DayCellView.styles.js","sourceRoot":"","sources":["DayCellView.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AACzD,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAGhE,MAAM,CAAC,IAAM,SAAS,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;IAAgB,OAAA,CAAC;QAC/D,IAAI,YAAC,CAAQ;YACX,OAAO,GAAG,uHAAA,oBACI,EAAmB,mBACrB,EAAoB,SAC/B,KAFa,CAAC,CAAC,iBAAiB,EACrB,CAAC,CAAC,kBAAkB,EAC9B;QACJ,CAAC;QACD,GAAG,YAAC,CAAQ;YACV,OAAO,GAAG,
|
|
1
|
+
{"version":3,"file":"DayCellView.styles.js","sourceRoot":"","sources":["DayCellView.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AACzD,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAGhE,MAAM,CAAC,IAAM,SAAS,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;IAAgB,OAAA,CAAC;QAC/D,IAAI,YAAC,CAAQ;YACX,OAAO,GAAG,uHAAA,oBACI,EAAmB,mBACrB,EAAoB,SAC/B,KAFa,CAAC,CAAC,iBAAiB,EACrB,CAAC,CAAC,kBAAkB,EAC9B;QACJ,CAAC;QACD,GAAG,YAAC,CAAQ;YACV,OAAO,GAAG,2hCAAA,UACN,EAAa,kEAID,EAAgB,4DAEjB,EAAsB,2HAKpB,EAAwB,0BACtB,EAA0B,6YAiBnB,EAA0B,sBACrC,EAAwB,gOAUf,EAA4B,oBACvC,EAA8B,kBAE1C,KA3CG,WAAW,EAAE,EAID,CAAC,CAAC,cAAc,EAEjB,CAAC,CAAC,oBAAoB,EAKpB,CAAC,CAAC,sBAAsB,EACtB,CAAC,CAAC,wBAAwB,EAiBnB,CAAC,CAAC,wBAAwB,EACrC,CAAC,CAAC,sBAAsB,EAUf,CAAC,CAAC,0BAA0B,EACvC,CAAC,CAAC,4BAA4B,EAEzC;QACJ,CAAC;QAED,QAAQ,YAAC,CAAQ;YACf,OAAO,GAAG,8HAAA,4BACY,EAA6B,kBACxC,EAA+B,SACzC,KAFqB,CAAC,CAAC,2BAA2B,EACxC,CAAC,CAAC,6BAA6B,EACxC;QACJ,CAAC;QAED,WAAW,YAAC,CAAQ;YAClB,OAAO,GAAG,4MAAA,kFAGgB,EAA6B,sBACxC,EAA+B,6BAG7C,KAJyB,CAAC,CAAC,2BAA2B,EACxC,CAAC,CAAC,6BAA6B,EAG5C;QACJ,CAAC;QAED,OAAO,YAAC,CAAQ;YACd,OAAO,GAAG,+FAAA,iBACC,EAA0B,SACpC,KADU,CAAC,CAAC,wBAAwB,EACnC;QACJ,CAAC;QAED,YAAY,YAAC,CAAQ;YACnB,OAAO,GAAG,mIAAA,qDAES,EAAyB,SAC3C,KADkB,CAAC,CAAC,uBAAuB,EAC1C;QACJ,CAAC;KACF,CAAC;AArF8D,CAqF9D,CAAC,CAAC","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\n\nimport { resetButton } from '../../lib/styles/Mixins.js';\nimport { memoizeGetStyles } from '../../lib/theming/Emotion.js';\nimport type { Theme } from '../../lib/theming/Theme.js';\n\nexport const getStyles = memoizeGetStyles(({ css }: Emotion) => ({\n cell(t: Theme) {\n return css`\n flex: 1 1 ${t.calendarCellWidth};\n height: ${t.calendarCellHeight};\n `;\n },\n day(t: Theme) {\n return css`\n ${resetButton()};\n width: 100%;\n height: 100%;\n\n background: ${t.calendarCellBg};\n border: 1px solid transparent;\n font-size: ${t.calendarCellFontSize};\n padding: 0;\n text-align: center;\n user-select: none;\n position: relative;\n line-height: ${t.calendarCellLineHeight};\n border-radius: ${t.calendarCellBorderRadius};\n transition:\n 0.15s ease background-color,\n 0.15s ease opacity;\n\n // Expand the clickable area\n &:before {\n content: '';\n position: absolute;\n left: -1px;\n top: -1px;\n width: calc(100% + 2px);\n height: calc(100% + 2px);\n }\n\n @media (hover: hover) {\n &:hover {\n background-color: ${t.calendarCellHoverBgColor};\n color: ${t.calendarCellHoverColor};\n cursor: pointer;\n }\n }\n\n &:disabled {\n opacity: 0.5;\n pointer-events: none;\n }\n &:active:enabled:not([data-visual-state-selected]) {\n background-color: ${t.calendarCellPressedBgColor};\n color: ${t.calendarCellActiveHoverColor};\n }\n `;\n },\n\n selected(t: Theme) {\n return css`\n background-color: ${t.calendarCellSelectedBgColor};\n color: ${t.calendarCellSelectedFontColor};\n `;\n },\n\n selected6_1(t: Theme) {\n return css`\n @media (hover: hover) {\n &:hover {\n background-color: ${t.calendarCellSelectedBgColor};\n color: ${t.calendarCellSelectedFontColor};\n }\n }\n `;\n },\n\n weekend(t: Theme) {\n return css`\n color: ${t.calendarCellWeekendColor};\n `;\n },\n\n todayCaption(t: Theme) {\n return css`\n padding-bottom: 2px;\n border-bottom: ${t.calendarCellTodayBorder};\n `;\n },\n}));\n"]}
|
|
@@ -35,7 +35,7 @@ export var getStyles = memoizeGetStyles(function (_a) {
|
|
|
35
35
|
return css(templateObject_9 || (templateObject_9 = __makeTemplateObject(["\n background: ", ";\n "], ["\n background: ", ";\n "])), t.rangeCalendarCellBg);
|
|
36
36
|
},
|
|
37
37
|
rangeCalendarDayHoverInPeriod: function (t) {
|
|
38
|
-
return css(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n @media (hover: hover) {\n &:hover [data-tid=", "] {\n background: ", ";\n }\n }\n "], ["\n @media (hover: hover) {\n &:hover [data-tid=", "] {\n background: ", ";\n }\n }\n "])), CalendarDataTids.dayCell, t.rangeCalendarCellHoverBg);
|
|
38
|
+
return css(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n @media (hover: hover) {\n &:hover [data-tid=", "] {\n background: ", ";\n }\n }\n\n & [data-tid=", "]:active:enabled:not([data-visual-state-selected]) {\n background: ", ";\n }\n "], ["\n @media (hover: hover) {\n &:hover [data-tid=", "] {\n background: ", ";\n }\n }\n\n & [data-tid=", "]:active:enabled:not([data-visual-state-selected]) {\n background: ", ";\n }\n "])), CalendarDataTids.dayCell, t.rangeCalendarCellHoverBg, CalendarDataTids.dayCell, t.calendarCellPressedBgColor);
|
|
39
39
|
},
|
|
40
40
|
buttonWrap: function () {
|
|
41
41
|
return css(templateObject_11 || (templateObject_11 = __makeTemplateObject(["\n display: flex;\n margin: 8px;\n\n > * {\n flex-grow: 1;\n }\n\n > *:not(:first-child) {\n margin-left: 8px;\n }\n "], ["\n display: flex;\n margin: 8px;\n\n > * {\n flex-grow: 1;\n }\n\n > *:not(:first-child) {\n margin-left: 8px;\n }\n "])));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DateRangePicker.styles.js","sourceRoot":"","sources":["DateRangePicker.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAGhE,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAExD,MAAM,CAAC,IAAM,SAAS,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;IAAgB,OAAA,CAAC;QAC/D,IAAI,YAAC,CAAQ;YACX,OAAO,GAAG,0MAAA,0EAGC,EAAkB,2DAK5B,KALU,CAAC,CAAC,gBAAgB,EAK3B;QACJ,CAAC;QACD,iBAAiB,YAAC,CAAQ;YACxB,OAAO,GAAG,qGAAA,qBACK,EAAoE,WAClF,KADc,QAAQ,CAAC,CAAC,CAAC,iBAAiB,CAAC,GAAG,CAAC,GAAG,QAAQ,CAAC,CAAC,CAAC,gBAAgB,CAAC,GAAG,CAAC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C,OAAO,EAC5B,CAAC,CAAC,wBAAwB,EAI9B,gBAAgB,CAAC,OAAO,EACtB,CAAC,CAAC,0BAA0B,EAE5C;QACJ,CAAC;QACD,UAAU;YACR,OAAO,GAAG,2OAAA,sKAWT,KAAC;QACJ,CAAC;KACF,CAAC;AA1G8D,CA0G9D,CAAC,CAAC;AAEJ,MAAM,UAAU,WAAW,CAAC,CAAQ,EAAE,IAAe;IACnD,QAAQ,IAAI,EAAE,CAAC;QACb,KAAK,OAAO;YACV,OAAO,CAAC,CAAC,aAAa,CAAC;QACzB,KAAK,QAAQ;YACX,OAAO,CAAC,CAAC,cAAc,CAAC;QAC1B,KAAK,OAAO,CAAC;QACb;YACE,OAAO,CAAC,CAAC,aAAa,CAAC;IAC3B,CAAC;AACH,CAAC","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\n\nimport { memoizeGetStyles } from '../../lib/theming/Emotion.js';\nimport type { Theme } from '../../lib/theming/Theme.js';\nimport type { SizeProp } from '../../lib/types/props.js';\nimport { CalendarDataTids } from '../Calendar/index.js';\n\nexport const getStyles = memoizeGetStyles(({ css }: Emotion) => ({\n root(t: Theme) {\n return css`\n display: inline-flex;\n align-items: center;\n color: ${t.textColorDefault};\n\n & > * {\n flex: 1 1 50%;\n }\n `;\n },\n inputWrapperWidth(t: Theme) {\n return css`\n min-width: ${parseInt(t.calendarCellWidth) * 7 + parseInt(t.calendarPaddingX) * 2}px;\n `;\n },\n inputWrapperWidthFull() {\n return css`\n width: 100%;\n `;\n },\n inputVisuallyFocus(t: Theme) {\n return css`\n box-shadow: ${t.inputFocusShadow};\n `;\n },\n calendarWrapper(t: Theme) {\n return css`\n box-shadow: ${t.pickerShadow};\n display: inline-block;\n font-size: 0;\n z-index: 1000;\n touch-action: none;\n `;\n },\n calendarWidthAuto() {\n return css`\n width: auto;\n `;\n },\n rangeCalendarDay() {\n return css`\n width: 100%;\n height: 100%;\n `;\n },\n rangeCalendarDayEnd(t: Theme) {\n return css`\n position: relative;\n\n &:before {\n content: '';\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background: ${t.rangeCalendarCellEndBg};\n border-radius: ${t.calendarCellBorderRadius};\n }\n\n [data-tid=${CalendarDataTids.dayCell}] {\n color: ${t.rangeCalendarCellEndColor};\n\n @media (hover: hover) {\n &:hover {\n color: ${t.rangeCalendarCellEndColor};\n background: none;\n }\n }\n }\n `;\n },\n rangeCalendarDayInHoveredPeriod(t: Theme) {\n return css`\n background: ${t.rangeCalendarCellBg};\n `;\n },\n rangeCalendarDayHoverInPeriod(t: Theme) {\n return css`\n @media (hover: hover) {\n &:hover [data-tid=${CalendarDataTids.dayCell}] {\n background: ${t.rangeCalendarCellHoverBg};\n }\n }\n\n & [data-tid=${CalendarDataTids.dayCell}]:active:enabled:not([data-visual-state-selected]) {\n background: ${t.calendarCellPressedBgColor};\n }\n `;\n },\n buttonWrap() {\n return css`\n display: flex;\n margin: 8px;\n\n > * {\n flex-grow: 1;\n }\n\n > *:not(:first-child) {\n margin-left: 8px;\n }\n `;\n },\n}));\n\nexport function getFontSize(t: Theme, size?: SizeProp): string {\n switch (size) {\n case 'large':\n return t.fontSizeLarge;\n case 'medium':\n return t.fontSizeMedium;\n case 'small':\n default:\n return t.fontSizeSmall;\n }\n}\n"]}
|
|
@@ -62,16 +62,16 @@ export var getJsStyles = memoizeGetStyles(function (_a) {
|
|
|
62
62
|
return css(templateObject_17 || (templateObject_17 = __makeTemplateObject(["\n border: ", " solid ", ";\n box-shadow: 0px 0px 0px 1px ", ";\n "], ["\n border: ", " solid ", ";\n box-shadow: 0px 0px 0px 1px ", ";\n "])), t.fileUploaderBorderWidth, t.fileUploaderBorderColorWarning, t.fileUploaderBorderColorWarning);
|
|
63
63
|
},
|
|
64
64
|
warningFile: function (t) {
|
|
65
|
-
return css(templateObject_18 || (templateObject_18 = __makeTemplateObject(["\n background: ", ";\n color: ", ";\n &:hover {\n background: ", ";\n }\n "], ["\n background: ", ";\n color: ", ";\n &:hover {\n background: ", ";\n }\n "])), t.fileUploaderWarningBgColor, t.fileUploaderValidationTextColor, t.fileUploaderWarningBgHoverColor);
|
|
65
|
+
return css(templateObject_18 || (templateObject_18 = __makeTemplateObject(["\n background: ", ";\n transition: background-color ", " ", ";\n color: ", ";\n &:hover {\n background: ", ";\n }\n &:active {\n background: ", ";\n }\n "], ["\n background: ", ";\n transition: background-color ", " ", ";\n color: ", ";\n &:hover {\n background: ", ";\n }\n &:active {\n background: ", ";\n }\n "])), t.fileUploaderWarningBgColor, t.transitionDuration, t.transitionTimingFunction, t.fileUploaderValidationTextColor, t.fileUploaderWarningBgHoverColor, t.fileUploaderWarningBgPressedColor);
|
|
66
66
|
},
|
|
67
67
|
errorButton: function (t) {
|
|
68
68
|
return css(templateObject_19 || (templateObject_19 = __makeTemplateObject(["\n border: ", " solid ", ";\n box-shadow: 0px 0px 0px 1px ", ";\n "], ["\n border: ", " solid ", ";\n box-shadow: 0px 0px 0px 1px ", ";\n "])), t.fileUploaderBorderWidth, t.fileUploaderBorderColorError, t.fileUploaderBorderColorError);
|
|
69
69
|
},
|
|
70
70
|
errorFile: function (t) {
|
|
71
|
-
return css(templateObject_20 || (templateObject_20 = __makeTemplateObject(["\n background: ", ";\n color: ", ";\n &:hover {\n background: ", ";\n }\n "], ["\n background: ", ";\n color: ", ";\n &:hover {\n background: ", ";\n }\n "])), t.fileUploaderErrorBgColor, t.fileUploaderValidationTextColor, t.fileUploaderErrorBgHoverColor);
|
|
71
|
+
return css(templateObject_20 || (templateObject_20 = __makeTemplateObject(["\n background: ", ";\n transition: background-color ", " ", ";\n color: ", ";\n &:hover {\n background: ", ";\n }\n &:active {\n background: ", ";\n }\n "], ["\n background: ", ";\n transition: background-color ", " ", ";\n color: ", ";\n &:hover {\n background: ", ";\n }\n &:active {\n background: ", ";\n }\n "])), t.fileUploaderErrorBgColor, t.transitionDuration, t.transitionTimingFunction, t.fileUploaderValidationTextColor, t.fileUploaderErrorBgHoverColor, t.fileUploaderErrorBgPressedColor);
|
|
72
72
|
},
|
|
73
73
|
hovered: function (t) {
|
|
74
|
-
return css(templateObject_21 || (templateObject_21 = __makeTemplateObject(["\n background: ", ";\n "], ["\n background: ", ";\n "])), t.fileUploaderHoveredBg);
|
|
74
|
+
return css(templateObject_21 || (templateObject_21 = __makeTemplateObject(["\n background: ", ";\n transition: background-color ", " ", ";\n\n &:active {\n background: ", ";\n }\n "], ["\n background: ", ";\n transition: background-color ", " ", ";\n\n &:active {\n background: ", ";\n }\n "])), t.fileUploaderHoveredBg, t.transitionDuration, t.transitionTimingFunction, t.fileUploaderActiveBg);
|
|
75
75
|
},
|
|
76
76
|
linkHovered: function (t) {
|
|
77
77
|
return css(templateObject_22 || (templateObject_22 = __makeTemplateObject(["\n text-decoration: ", ";\n "], ["\n text-decoration: ", ";\n "])), t.fileUploaderLinkHoverTextDecoration);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileUploader.styles.js","sourceRoot":"","sources":["FileUploader.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAC;AAExE,OAAO,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAC;AAEjE,MAAM,CAAC,IAAM,aAAa,GAAG,MAAM,CAAC,eAAe,CAAC,CAAC;IACnD,aAAa,EAAE,iBAAiB;CACjC,CAAC,CAAC;AACH,MAAM,CAAC,IAAM,WAAW,GAAG,gBAAgB,CAAC,UAAC,EAA2B;QAAzB,GAAG,SAAA,EAAE,SAAS,eAAA;IAC3D,IAAM,SAAS,GAAG,UAAC,CAAQ;QACzB,OAAO,SAAS,6PAAA,8CAEY,EAAiB,0DAGhB,EAAiB,0DAGlB,EAAiB,kBAE5C,KAR2B,CAAC,CAAC,eAAe,EAGhB,CAAC,CAAC,eAAe,EAGlB,CAAC,CAAC,eAAe,EAE3C;IACJ,CAAC,CAAC;IACF,OAAO;QACL,IAAI,YAAC,CAAQ;YACX,OAAO,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D,WACF,KANG,qBAAqB,CACrB,CAAC,CAAC,0BAA0B,EAC5B,CAAC,CAAC,4BAA4B,EAC9B,CAAC,CAAC,6BAA6B,EAC/B,CAAC,CAAC,6BAA6B,CAChC,EACD;QACJ,CAAC;QACD,SAAS,YAAC,CAAQ;YAChB,OAAO,GAAG,8FAAA,YACN,EAKD,WACF,KANG,qBAAqB,CACrB,CAAC,CAAC,yBAAyB,EAC3B,CAAC,CAAC,2BAA2B,EAC7B,CAAC,CAAC,4BAA4B,EAC9B,CAAC,CAAC,4BAA4B,CAC/B,EACD;QACJ,CAAC;QAED,aAAa;YACX,OAAO,GAAG,gHAAA,2CAET,KAAC;QACJ,CAAC;QAED,OAAO;YACL,OAAO,GAAG,0TAAA,qPAST,KAAC;QACJ,CAAC;QAED,gBAAgB;YACd,OAAO,GAAG,gKAAA,2FAIT,KAAC;QACJ,CAAC;KACF,CAAC;AACJ,CAAC,CAAC,CAAC","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\n\nimport { memoizeGetStyles, prefix } from '../../lib/theming/Emotion.js';\nimport type { Theme } from '../../lib/theming/Theme.js';\nimport { fileUploaderSizeMixin } from './FileUploader.mixins.js';\n\nexport const globalClasses = prefix('file-uploader')({\n afterLinkText: 'after-link-text',\n});\nexport const getJsStyles = memoizeGetStyles(({ css, keyframes }: Emotion) => {\n const calcPulse = (t: Theme) => {\n return keyframes`\n 0% {\n box-shadow: 0 0 0 1px ${t.inputBlinkColor};\n }\n 95% {\n box-shadow: 0 0 0 10px ${t.inputBlinkColor};\n }\n 100% {\n box-shadow: 0 0 0 1px ${t.inputBlinkColor};\n }\n `;\n };\n return {\n root(t: Theme) {\n return css`\n display: inline-flex;\n flex-wrap: wrap;\n position: relative;\n border-radius: ${t.fileUploaderBorderRadius};\n line-height: ${t.fileUploaderLineHeightSmall};\n font-size: ${t.fileUploaderFontSizeSmall};\n color: ${t.fileUploaderTextColorDefault};\n background-color: ${t.fileUploaderBg};\n `;\n },\n uploadButton(t: Theme) {\n return css`\n width: 100%;\n position: relative;\n display: inline-flex;\n align-items: center;\n border: ${t.fileUploaderBorderWidth} ${t.fileUploaderBorderStyle} ${t.fileUploaderBorderColor};\n box-sizing: border-box;\n border-radius: ${t.fileUploaderBorderRadius};\n outline: none;\n cursor: pointer;\n transition:\n background-color ${t.transitionDuration} ${t.transitionTimingFunction},\n border-color ${t.transitionDuration} ${t.transitionTimingFunction};\n background-color: ${t.fileUploaderUploadButtonBg};\n `;\n },\n\n uploadButtonFocus(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorFocus};\n box-shadow: 0px 0px 0px 1px ${t.fileUploaderBorderColorFocus};\n `;\n },\n\n uploadButtonWithFile(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid transparent;\n background: none;\n `;\n },\n\n uploadButtonIconGapSmall(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapSmall};\n `;\n },\n\n uploadButtonIconGapMedium(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapMedium};\n `;\n },\n\n uploadButtonIconGapLarge(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapLarge};\n `;\n },\n\n dragOver(t: Theme) {\n return css`\n border: 1px solid ${t.fileUploaderDragOverBorderColor};\n border-radius: ${t.fileUploaderBorderRadius};\n box-shadow: ${t.fileUploaderDragOverShadow};\n `;\n },\n\n windowDragOver(t: Theme) {\n return css`\n border-radius: ${t.fileUploaderBorderRadius};\n animation: ${calcPulse(t)} 1.5s infinite;\n `;\n },\n\n contentInnerSmall(t: Theme) {\n return css`\n width: calc(100% - ${t.inputIconSizeSmall} - ${t.fileUploaderIconGapSmall});\n `;\n },\n\n contentInnerMedium(t: Theme) {\n return css`\n width: calc(100% - ${t.inputIconSizeMedium} - ${t.fileUploaderIconGapMedium});\n `;\n },\n\n contentInnerLarge(t: Theme) {\n return css`\n width: calc(100% - ${t.inputIconSizeLarge} - ${t.fileUploaderIconGapLarge});\n `;\n },\n\n visuallyHidden() {\n return css`\n position: absolute;\n width: 1px;\n height: 1px;\n margin: -1px;\n border: 0;\n padding: 0;\n white-space: nowrap;\n clip-path: inset(100%);\n clip: rect(0 0 0 0);\n overflow: hidden;\n `;\n },\n\n afterLinkText() {\n return css`\n display: inline;\n `;\n },\n\n afterLinkText_HasFiles() {\n return css`\n display: flex;\n justify-content: space-between;\n flex: 1 1 auto;\n height: 100%;\n `;\n },\n\n warningButton(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorWarning};\n box-shadow: 0px 0px 0px 1px ${t.fileUploaderBorderColorWarning};\n `;\n },\n\n warningFile(t: Theme) {\n return css`\n background: ${t.fileUploaderWarningBgColor};\n color: ${t.fileUploaderValidationTextColor};\n &:hover {\n background: ${t.fileUploaderWarningBgHoverColor};\n }\n `;\n },\n\n errorButton(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorError};\n box-shadow: 0px 0px 0px 1px ${t.fileUploaderBorderColorError};\n `;\n },\n\n errorFile(t: Theme) {\n return css`\n background: ${t.fileUploaderErrorBgColor};\n color: ${t.fileUploaderValidationTextColor};\n &:hover {\n background: ${t.fileUploaderErrorBgHoverColor};\n }\n `;\n },\n\n hovered(t: Theme) {\n return css`\n background: ${t.fileUploaderHoveredBg};\n `;\n },\n\n linkHovered(t: Theme) {\n return css`\n text-decoration: ${t.fileUploaderLinkHoverTextDecoration};\n `;\n },\n\n disabled(t: Theme) {\n return css`\n cursor: default;\n color: ${t.fileUploaderDisabledTextColor};\n box-shadow: none;\n background-clip: ${t.fileUploaderDisabledBgClip};\n\n .${globalClasses.afterLinkText} {\n color: ${t.fileUploaderDisabledTextColor};\n }\n `;\n },\n\n disabledBackground(t: Theme) {\n return css`\n background: ${t.fileUploaderDisabledBg};\n border: ${t.fileUploaderDisabledBorder};\n `;\n },\n\n icon(t: Theme) {\n return css`\n display: inline-block;\n color: ${t.fileUploaderIconColor};\n `;\n },\n\n iconDisabled(t: Theme) {\n return css`\n color: ${t.fileUploaderDisabledIconColor};\n `;\n },\n\n link(t: Theme) {\n return css`\n outline: none;\n text-decoration: none;\n color: ${t.fileUploaderLinkColor};\n `;\n },\n\n linkDisabled(t: Theme) {\n return css`\n color: ${t.fileUploaderDisabledLinkColor};\n &:hover {\n text-decoration: none;\n }\n `;\n },\n\n singleFile() {\n return css`\n width: 100%;\n height: inherit;\n `;\n },\n\n iconSmall(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeSmall};\n line-height: ${t.fileUploaderLineHeightSmall};\n `;\n },\n\n iconMedium(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeMedium};\n line-height: ${t.fileUploaderLineHeightMedium};\n `;\n },\n\n iconLarge(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeLarge};\n line-height: ${t.fileUploaderLineHeightLarge};\n `;\n },\n };\n});\n\nexport const getJsRowStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n root() {\n return css`\n width: 100%;\n `;\n },\n\n uploadButtonWithFile(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid transparent;\n background: none;\n `;\n },\n\n uploadButton() {\n return css`\n justify-content: space-between;\n `;\n },\n\n uploadButtonWrapper() {\n return css`\n height: inherit;\n width: 100%;\n `;\n },\n\n uploadButtonIconGapSmall(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapSmall};\n `;\n },\n\n uploadButtonIconGapMedium(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapMedium};\n `;\n },\n\n uploadButtonIconGapLarge(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapLarge};\n `;\n },\n\n sizeSmall(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeSmall,\n t.fileUploaderLineHeightSmall,\n t.fileUploaderPaddingXSmall,\n t.fileUploaderPaddingYSmall,\n )};\n `;\n },\n\n sizeMedium(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeMedium,\n t.fileUploaderLineHeightMedium,\n t.fileUploaderPaddingXMedium,\n t.fileUploaderPaddingYMedium,\n )};\n `;\n },\n\n sizeLarge(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeLarge,\n t.fileUploaderLineHeightLarge,\n t.fileUploaderPaddingXLarge,\n t.fileUploaderPaddingYLarge,\n )};\n `;\n },\n\n content() {\n return css`\n display: block;\n width: 100%;\n height: 100%;\n overflow: hidden;\n text-overflow: ellipsis;\n `;\n },\n\n contentWithFiles() {\n return css`\n display: flex;\n align-items: center;\n `;\n },\n };\n});\n\nexport const getJsTileStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n uploadButton() {\n return css`\n height: 100%;\n justify-content: center;\n flex-direction: column;\n `;\n },\n\n uploadButtonWrapper() {\n return css`\n box-sizing: border-box;\n `;\n },\n\n uploadButtonWrapperSmall(t: Theme) {\n return css`\n width: ${t.fileUploaderTileWidthSmall};\n min-height: ${t.fileUploaderTileMinHeightSmall};\n height: auto;\n `;\n },\n\n uploadButtonWrapperMedium(t: Theme) {\n return css`\n width: ${t.fileUploaderTileWidthMedium};\n min-height: ${t.fileUploaderTileMinHeightMedium};\n height: auto;\n `;\n },\n\n uploadButtonWrapperLarge(t: Theme) {\n return css`\n width: ${t.fileUploaderTileWidthLarge};\n min-height: ${t.fileUploaderTileMinHeightLarge};\n height: auto;\n `;\n },\n\n uploadButtonWrapperEmptyFileSmall(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingSmall};\n height: ${t.fileUploaderTileMinHeightSmall};\n `;\n },\n\n uploadButtonWrapperEmptyFileMedium(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingMedium};\n height: ${t.fileUploaderTileMinHeightMedium};\n `;\n },\n\n uploadButtonWrapperEmptyFileLarge(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingLarge};\n height: ${t.fileUploaderTileMinHeightLarge};\n `;\n },\n\n uploadButtonWithFile(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid transparent;\n background: none;\n justify-content: start;\n `;\n },\n\n uploadButtonIconGapSmall(t: Theme) {\n return css`\n margin-bottom: ${t.inputIconGapSmall};\n `;\n },\n\n uploadButtonIconGapMedium(t: Theme) {\n return css`\n margin-bottom: ${t.inputIconGapMedium};\n `;\n },\n\n uploadButtonIconGapLarge(t: Theme) {\n return css`\n margin-bottom: ${t.inputIconGapLarge};\n `;\n },\n\n uploadButtonTileWithFileSmall(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingSmall};\n `;\n },\n\n uploadButtonTileWithFileMedium(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingMedium};\n `;\n },\n\n uploadButtonTileWithFileLarge(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingLarge};\n `;\n },\n\n sizeSmall(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeSmall,\n t.fileUploaderLineHeightSmall,\n t.fileUploaderTilePaddingSmall,\n t.fileUploaderTilePaddingSmall,\n )};\n `;\n },\n\n sizeMedium(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeMedium,\n t.fileUploaderLineHeightMedium,\n t.fileUploaderTilePaddingMedium,\n t.fileUploaderTilePaddingMedium,\n )};\n `;\n },\n sizeLarge(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeLarge,\n t.fileUploaderLineHeightLarge,\n t.fileUploaderTilePaddingLarge,\n t.fileUploaderTilePaddingLarge,\n )};\n `;\n },\n\n verticalAlign() {\n return css`\n vertical-align: middle;\n `;\n },\n\n content() {\n return css`\n display: block;\n width: 100%;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: normal;\n overflow-wrap: break-word;\n word-wrap: break-word;\n text-align: center;\n `;\n },\n\n contentWithFiles() {\n return css`\n display: flex;\n align-items: flex-start;\n height: 100%;\n `;\n },\n };\n});\n"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OAAO,GAAG,8FAAA,YACN,EAKD,WACF,KANG,qBAAqB,CACrB,CAAC,CAAC,yBAAyB,EAC3B,CAAC,CAAC,2BAA2B,EAC7B,CAAC,CAAC,4BAA4B,EAC9B,CAAC,CAAC,4BAA4B,CAC/B,EACD;QACJ,CAAC;QAED,aAAa;YACX,OAAO,GAAG,gHAAA,2CAET,KAAC;QACJ,CAAC;QAED,OAAO;YACL,OAAO,GAAG,0TAAA,qPAST,KAAC;QACJ,CAAC;QAED,gBAAgB;YACd,OAAO,GAAG,gKAAA,2FAIT,KAAC;QACJ,CAAC;KACF,CAAC;AACJ,CAAC,CAAC,CAAC","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\n\nimport { memoizeGetStyles, prefix } from '../../lib/theming/Emotion.js';\nimport type { Theme } from '../../lib/theming/Theme.js';\nimport { fileUploaderSizeMixin } from './FileUploader.mixins.js';\n\nexport const globalClasses = prefix('file-uploader')({\n afterLinkText: 'after-link-text',\n});\nexport const getJsStyles = memoizeGetStyles(({ css, keyframes }: Emotion) => {\n const calcPulse = (t: Theme) => {\n return keyframes`\n 0% {\n box-shadow: 0 0 0 1px ${t.inputBlinkColor};\n }\n 95% {\n box-shadow: 0 0 0 10px ${t.inputBlinkColor};\n }\n 100% {\n box-shadow: 0 0 0 1px ${t.inputBlinkColor};\n }\n `;\n };\n return {\n root(t: Theme) {\n return css`\n display: inline-flex;\n flex-wrap: wrap;\n position: relative;\n border-radius: ${t.fileUploaderBorderRadius};\n line-height: ${t.fileUploaderLineHeightSmall};\n font-size: ${t.fileUploaderFontSizeSmall};\n color: ${t.fileUploaderTextColorDefault};\n background-color: ${t.fileUploaderBg};\n `;\n },\n uploadButton(t: Theme) {\n return css`\n width: 100%;\n position: relative;\n display: inline-flex;\n align-items: center;\n border: ${t.fileUploaderBorderWidth} ${t.fileUploaderBorderStyle} ${t.fileUploaderBorderColor};\n box-sizing: border-box;\n border-radius: ${t.fileUploaderBorderRadius};\n outline: none;\n cursor: pointer;\n transition:\n background-color ${t.transitionDuration} ${t.transitionTimingFunction},\n border-color ${t.transitionDuration} ${t.transitionTimingFunction};\n background-color: ${t.fileUploaderUploadButtonBg};\n `;\n },\n\n uploadButtonFocus(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorFocus};\n box-shadow: 0px 0px 0px 1px ${t.fileUploaderBorderColorFocus};\n `;\n },\n\n uploadButtonWithFile(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid transparent;\n background: none;\n `;\n },\n\n uploadButtonIconGapSmall(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapSmall};\n `;\n },\n\n uploadButtonIconGapMedium(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapMedium};\n `;\n },\n\n uploadButtonIconGapLarge(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapLarge};\n `;\n },\n\n dragOver(t: Theme) {\n return css`\n border: 1px solid ${t.fileUploaderDragOverBorderColor};\n border-radius: ${t.fileUploaderBorderRadius};\n box-shadow: ${t.fileUploaderDragOverShadow};\n `;\n },\n\n windowDragOver(t: Theme) {\n return css`\n border-radius: ${t.fileUploaderBorderRadius};\n animation: ${calcPulse(t)} 1.5s infinite;\n `;\n },\n\n contentInnerSmall(t: Theme) {\n return css`\n width: calc(100% - ${t.inputIconSizeSmall} - ${t.fileUploaderIconGapSmall});\n `;\n },\n\n contentInnerMedium(t: Theme) {\n return css`\n width: calc(100% - ${t.inputIconSizeMedium} - ${t.fileUploaderIconGapMedium});\n `;\n },\n\n contentInnerLarge(t: Theme) {\n return css`\n width: calc(100% - ${t.inputIconSizeLarge} - ${t.fileUploaderIconGapLarge});\n `;\n },\n\n visuallyHidden() {\n return css`\n position: absolute;\n width: 1px;\n height: 1px;\n margin: -1px;\n border: 0;\n padding: 0;\n white-space: nowrap;\n clip-path: inset(100%);\n clip: rect(0 0 0 0);\n overflow: hidden;\n `;\n },\n\n afterLinkText() {\n return css`\n display: inline;\n `;\n },\n\n afterLinkText_HasFiles() {\n return css`\n display: flex;\n justify-content: space-between;\n flex: 1 1 auto;\n height: 100%;\n `;\n },\n\n warningButton(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorWarning};\n box-shadow: 0px 0px 0px 1px ${t.fileUploaderBorderColorWarning};\n `;\n },\n\n warningFile(t: Theme) {\n return css`\n background: ${t.fileUploaderWarningBgColor};\n transition: background-color ${t.transitionDuration} ${t.transitionTimingFunction};\n color: ${t.fileUploaderValidationTextColor};\n &:hover {\n background: ${t.fileUploaderWarningBgHoverColor};\n }\n &:active {\n background: ${t.fileUploaderWarningBgPressedColor};\n }\n `;\n },\n\n errorButton(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorError};\n box-shadow: 0px 0px 0px 1px ${t.fileUploaderBorderColorError};\n `;\n },\n\n errorFile(t: Theme) {\n return css`\n background: ${t.fileUploaderErrorBgColor};\n transition: background-color ${t.transitionDuration} ${t.transitionTimingFunction};\n color: ${t.fileUploaderValidationTextColor};\n &:hover {\n background: ${t.fileUploaderErrorBgHoverColor};\n }\n &:active {\n background: ${t.fileUploaderErrorBgPressedColor};\n }\n `;\n },\n\n hovered(t: Theme) {\n return css`\n background: ${t.fileUploaderHoveredBg};\n transition: background-color ${t.transitionDuration} ${t.transitionTimingFunction};\n\n &:active {\n background: ${t.fileUploaderActiveBg};\n }\n `;\n },\n\n linkHovered(t: Theme) {\n return css`\n text-decoration: ${t.fileUploaderLinkHoverTextDecoration};\n `;\n },\n\n disabled(t: Theme) {\n return css`\n cursor: default;\n color: ${t.fileUploaderDisabledTextColor};\n box-shadow: none;\n background-clip: ${t.fileUploaderDisabledBgClip};\n\n .${globalClasses.afterLinkText} {\n color: ${t.fileUploaderDisabledTextColor};\n }\n `;\n },\n\n disabledBackground(t: Theme) {\n return css`\n background: ${t.fileUploaderDisabledBg};\n border: ${t.fileUploaderDisabledBorder};\n `;\n },\n\n icon(t: Theme) {\n return css`\n display: inline-block;\n color: ${t.fileUploaderIconColor};\n `;\n },\n\n iconDisabled(t: Theme) {\n return css`\n color: ${t.fileUploaderDisabledIconColor};\n `;\n },\n\n link(t: Theme) {\n return css`\n outline: none;\n text-decoration: none;\n color: ${t.fileUploaderLinkColor};\n `;\n },\n\n linkDisabled(t: Theme) {\n return css`\n color: ${t.fileUploaderDisabledLinkColor};\n &:hover {\n text-decoration: none;\n }\n `;\n },\n\n singleFile() {\n return css`\n width: 100%;\n height: inherit;\n `;\n },\n\n iconSmall(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeSmall};\n line-height: ${t.fileUploaderLineHeightSmall};\n `;\n },\n\n iconMedium(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeMedium};\n line-height: ${t.fileUploaderLineHeightMedium};\n `;\n },\n\n iconLarge(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeLarge};\n line-height: ${t.fileUploaderLineHeightLarge};\n `;\n },\n };\n});\n\nexport const getJsRowStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n root() {\n return css`\n width: 100%;\n `;\n },\n\n uploadButtonWithFile(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid transparent;\n background: none;\n `;\n },\n\n uploadButton() {\n return css`\n justify-content: space-between;\n `;\n },\n\n uploadButtonWrapper() {\n return css`\n height: inherit;\n width: 100%;\n `;\n },\n\n uploadButtonIconGapSmall(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapSmall};\n `;\n },\n\n uploadButtonIconGapMedium(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapMedium};\n `;\n },\n\n uploadButtonIconGapLarge(t: Theme) {\n return css`\n margin-right: ${t.inputIconGapLarge};\n `;\n },\n\n sizeSmall(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeSmall,\n t.fileUploaderLineHeightSmall,\n t.fileUploaderPaddingXSmall,\n t.fileUploaderPaddingYSmall,\n )};\n `;\n },\n\n sizeMedium(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeMedium,\n t.fileUploaderLineHeightMedium,\n t.fileUploaderPaddingXMedium,\n t.fileUploaderPaddingYMedium,\n )};\n `;\n },\n\n sizeLarge(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeLarge,\n t.fileUploaderLineHeightLarge,\n t.fileUploaderPaddingXLarge,\n t.fileUploaderPaddingYLarge,\n )};\n `;\n },\n\n content() {\n return css`\n display: block;\n width: 100%;\n height: 100%;\n overflow: hidden;\n text-overflow: ellipsis;\n `;\n },\n\n contentWithFiles() {\n return css`\n display: flex;\n align-items: center;\n `;\n },\n };\n});\n\nexport const getJsTileStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n uploadButton() {\n return css`\n height: 100%;\n justify-content: center;\n flex-direction: column;\n `;\n },\n\n uploadButtonWrapper() {\n return css`\n box-sizing: border-box;\n `;\n },\n\n uploadButtonWrapperSmall(t: Theme) {\n return css`\n width: ${t.fileUploaderTileWidthSmall};\n min-height: ${t.fileUploaderTileMinHeightSmall};\n height: auto;\n `;\n },\n\n uploadButtonWrapperMedium(t: Theme) {\n return css`\n width: ${t.fileUploaderTileWidthMedium};\n min-height: ${t.fileUploaderTileMinHeightMedium};\n height: auto;\n `;\n },\n\n uploadButtonWrapperLarge(t: Theme) {\n return css`\n width: ${t.fileUploaderTileWidthLarge};\n min-height: ${t.fileUploaderTileMinHeightLarge};\n height: auto;\n `;\n },\n\n uploadButtonWrapperEmptyFileSmall(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingSmall};\n height: ${t.fileUploaderTileMinHeightSmall};\n `;\n },\n\n uploadButtonWrapperEmptyFileMedium(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingMedium};\n height: ${t.fileUploaderTileMinHeightMedium};\n `;\n },\n\n uploadButtonWrapperEmptyFileLarge(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingLarge};\n height: ${t.fileUploaderTileMinHeightLarge};\n `;\n },\n\n uploadButtonWithFile(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid transparent;\n background: none;\n justify-content: start;\n `;\n },\n\n uploadButtonIconGapSmall(t: Theme) {\n return css`\n margin-bottom: ${t.inputIconGapSmall};\n `;\n },\n\n uploadButtonIconGapMedium(t: Theme) {\n return css`\n margin-bottom: ${t.inputIconGapMedium};\n `;\n },\n\n uploadButtonIconGapLarge(t: Theme) {\n return css`\n margin-bottom: ${t.inputIconGapLarge};\n `;\n },\n\n uploadButtonTileWithFileSmall(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingSmall};\n `;\n },\n\n uploadButtonTileWithFileMedium(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingMedium};\n `;\n },\n\n uploadButtonTileWithFileLarge(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingLarge};\n `;\n },\n\n sizeSmall(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeSmall,\n t.fileUploaderLineHeightSmall,\n t.fileUploaderTilePaddingSmall,\n t.fileUploaderTilePaddingSmall,\n )};\n `;\n },\n\n sizeMedium(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeMedium,\n t.fileUploaderLineHeightMedium,\n t.fileUploaderTilePaddingMedium,\n t.fileUploaderTilePaddingMedium,\n )};\n `;\n },\n sizeLarge(t: Theme) {\n return css`\n ${fileUploaderSizeMixin(\n t.fileUploaderFontSizeLarge,\n t.fileUploaderLineHeightLarge,\n t.fileUploaderTilePaddingLarge,\n t.fileUploaderTilePaddingLarge,\n )};\n `;\n },\n\n verticalAlign() {\n return css`\n vertical-align: middle;\n `;\n },\n\n content() {\n return css`\n display: block;\n width: 100%;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: normal;\n overflow-wrap: break-word;\n word-wrap: break-word;\n text-align: center;\n `;\n },\n\n contentWithFiles() {\n return css`\n display: flex;\n align-items: flex-start;\n height: 100%;\n `;\n },\n };\n});\n"]}
|
|
@@ -34,7 +34,7 @@ export var getJsStyles = memoizeGetStyles(function (_a) {
|
|
|
34
34
|
return css(templateObject_9 || (templateObject_9 = __makeTemplateObject(["\n width: ", ";\n margin-right: ", ";\n font-size: ", ";\n line-height: ", ";\n "], ["\n width: ", ";\n margin-right: ", ";\n font-size: ", ";\n line-height: ", ";\n "])), t.fileUploaderFileSizeWidthLarge, t.fileUploaderFileSizeMarginLarge, t.fileUploaderFontSizeLarge, t.fileUploaderLineHeightLarge);
|
|
35
35
|
},
|
|
36
36
|
icon: function (t) {
|
|
37
|
-
return css(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n position: absolute;\n top: ", ";\n right: ", ";\n display: flex;\n flex: 1 0 auto;\n align-items: center;\n justify-content: center;\n width: ", ";\n border-radius: ", ";\n cursor: pointer;\n text-align: center;\n outline: none;\n &:hover {\n background: ", ";\n }\n &:active {\n background: ", ";\n }\n "], ["\n position: absolute;\n top: ", ";\n right: ", ";\n display: flex;\n flex: 1 0 auto;\n align-items: center;\n justify-content: center;\n width: ", ";\n border-radius: ", ";\n cursor: pointer;\n text-align: center;\n outline: none;\n &:hover {\n background: ", ";\n }\n &:active {\n background: ", ";\n }\n "])), t.fileUploaderIconGapSmall, t.fileUploaderIconGapSmall, t.fileUploaderTileIconSizeSmall, t.fileUploaderBorderRadius, t.fileUploaderHoveredBg, t.fileUploaderActiveBg);
|
|
37
|
+
return css(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n position: absolute;\n top: ", ";\n right: ", ";\n display: flex;\n flex: 1 0 auto;\n align-items: center;\n justify-content: center;\n width: ", ";\n border-radius: ", ";\n cursor: pointer;\n text-align: center;\n outline: none;\n transition: background-color ", " ", ";\n &:hover {\n background: ", ";\n }\n &:active {\n background: ", ";\n }\n "], ["\n position: absolute;\n top: ", ";\n right: ", ";\n display: flex;\n flex: 1 0 auto;\n align-items: center;\n justify-content: center;\n width: ", ";\n border-radius: ", ";\n cursor: pointer;\n text-align: center;\n outline: none;\n transition: background-color ", " ", ";\n &:hover {\n background: ", ";\n }\n &:active {\n background: ", ";\n }\n "])), t.fileUploaderIconGapSmall, t.fileUploaderIconGapSmall, t.fileUploaderTileIconSizeSmall, t.fileUploaderBorderRadius, t.transitionDuration, t.transitionTimingFunction, t.fileUploaderHoveredBg, t.fileUploaderActiveBg);
|
|
38
38
|
},
|
|
39
39
|
disabledFileTypeIconSvg: function (t) {
|
|
40
40
|
return css(templateObject_11 || (templateObject_11 = __makeTemplateObject(["\n svg {\n fill: ", " !important;\n }\n "], ["\n svg {\n fill: ", " !important;\n }\n "])), t.fileUploaderDisabledFileTypeIcon);
|
|
@@ -110,7 +110,7 @@ export var getJsTileStyles = memoizeGetStyles(function (_a) {
|
|
|
110
110
|
return css(templateObject_31 || (templateObject_31 = __makeTemplateObject(["\n flex-direction: column;\n align-items: center;\n height: inherit;\n "], ["\n flex-direction: column;\n align-items: center;\n height: inherit;\n "])));
|
|
111
111
|
},
|
|
112
112
|
iconAction: function (t) {
|
|
113
|
-
return css(templateObject_32 || (templateObject_32 = __makeTemplateObject(["\n border-radius: ", ";\n opacity: 0;\n background: ", ";\n\n &:hover {\n background: ", ";\n }\n\n &:active {\n background: ", ";\n }\n "], ["\n border-radius: ", ";\n opacity: 0;\n background: ", ";\n\n &:hover {\n background: ", ";\n }\n\n &:active {\n background: ", ";\n }\n "])), t.fileUploaderBorderRadius, t.fileUploaderTileIconColorBg, t.fileUploaderTileIconHoverColorBg, t.fileUploaderTileIconActiveColorBg);
|
|
113
|
+
return css(templateObject_32 || (templateObject_32 = __makeTemplateObject(["\n border-radius: ", ";\n opacity: 0;\n background: ", ";\n transition: background-color ", " ", ";\n\n &:hover {\n background: ", ";\n }\n\n &:active {\n background: ", ";\n }\n "], ["\n border-radius: ", ";\n opacity: 0;\n background: ", ";\n transition: background-color ", " ", ";\n\n &:hover {\n background: ", ";\n }\n\n &:active {\n background: ", ";\n }\n "])), t.fileUploaderBorderRadius, t.fileUploaderTileIconColorBg, t.transitionDuration, t.transitionTimingFunction, t.fileUploaderTileIconHoverColorBg, t.fileUploaderTileIconActiveColorBg);
|
|
114
114
|
},
|
|
115
115
|
iconActionShow: function () {
|
|
116
116
|
return css(templateObject_33 || (templateObject_33 = __makeTemplateObject(["\n opacity: 1;\n "], ["\n opacity: 1;\n "])));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileUploaderFile.styles.js","sourceRoot":"","sources":["FileUploaderFile.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAGhE,MAAM,CAAC,IAAM,WAAW,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;IAAgB,OAAA,CAAC;QACjE,IAAI;YACF,OAAO,GAAG,uHAAA,oDAGT,KAAC;QACJ,CAAC;QAED,OAAO;YACL,OAAO,GAAG,mJAAA,gFAIT,KAAC;QACJ,CAAC;QAED,mBAAmB,YAAC,CAAQ;YAC1B,OAAO,GAAG,+FAAA,iBACC,EAA4B,SACtC,KADU,CAAC,CAAC,0BAA0B,EACrC;QACJ,CAAC;QAED,qBAAqB,YAAC,CAAQ;YAC5B,OAAO,GAAG,+FAAA,iBACC,EAA8B,SACxC,KADU,CAAC,CAAC,4BAA4B,EACvC;QACJ,CAAC;QAED,SAAS;YACP,OAAO,GAAG,oKAAA,iGAKT,KAAC;QACJ,CAAC;QAED,IAAI,YAAC,CAAQ;YACX,OAAO,GAAG,4HAAA,uBACO,EAAgC,gCAEhD,KAFgB,CAAC,CAAC,8BAA8B,EAE/C;QACJ,CAAC;QAED,SAAS,YAAC,CAAQ;YAChB,OAAO,GAAG,4KAAA,iBACC,EAAgC,yBACzB,EAAiC,sBACpC,EAA2B,wBACzB,EAA6B,SAC7C,KAJU,CAAC,CAAC,8BAA8B,EACzB,CAAC,CAAC,+BAA+B,EACpC,CAAC,CAAC,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J,CAAC;QAED,IAAI,YAAC,CAAQ;YACX,OAAO,GAAG,8MAAA,0CAEE,EAA0B,gFAG3B,EAAqB,WAC/B,KAJW,CAAC,CAAC,wBAAwB,EAG3B,CAAC,CAAC,mBAAmB,EAC9B;QACJ,CAAC;QAED,IAAI;YACF,OAAO,GAAG,+NAAA,0JAQT,KAAC;QACJ,CAAC;QAED,SAAS;YACP,OAAO,GAAG,8HAAA,yDAGT,KAAC;QACJ,CAAC;QAED,YAAY,YAAC,CAAQ;YACnB,IAAM,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,2BAA2B,CAAC,GAAG,CAAC,CAAC;YAC9D,OAAO,GAAG,4GAAA,wBACM,EAAS,aACxB,KADe,SAAS,EACvB;QACJ,CAAC;QAED,aAAa,YAAC,CAAQ;YACpB,IAAM,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,4BAA4B,CAAC,GAAG,CAAC,CAAC;YAC/D,OAAO,GAAG,4GAAA,wBACM,EAAS,aACxB,KADe,SAAS,EACvB;QACJ,CAAC;QAED,YAAY,YAAC,CAAQ;YACnB,IAAM,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,2BAA2B,CAAC,GAAG,CAAC,CAAC;YAC9D,OAAO,GAAG,4GAAA,wBACM,EAAS,aACxB,KADe,SAAS,EACvB;QACJ,CAAC;QAED,QAAQ,YAAC,CAAQ;YACf,OAAO,GAAG,+HAAA,6CAEC,EAA+B,WACzC,KADU,CAAC,CAAC,6BAA6B,EACxC;QACJ,CAAC;KACF,CAAC;AACJ,CAAC,CAAC,CAAC","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\n\nimport { memoizeGetStyles } from '../../lib/theming/Emotion.js';\nimport type { Theme } from '../../lib/theming/Theme.js';\n\nexport const getJsStyles = memoizeGetStyles(({ css }: Emotion) => ({\n root() {\n return css`\n width: 100%;\n height: inherit;\n `;\n },\n\n content() {\n return css`\n display: flex;\n width: 100%;\n align-items: baseline;\n `;\n },\n\n validationTextError(t: Theme) {\n return css`\n color: ${t.fileUploaderErrorTextColor};\n `;\n },\n\n validationTextWarning(t: Theme) {\n return css`\n color: ${t.fileUploaderWarningTextColor};\n `;\n },\n\n nameBlock() {\n return css`\n display: flex;\n flex-wrap: wrap;\n flex: 1 1 100%;\n width: 100%;\n `;\n },\n\n size(t: Theme) {\n return css`\n margin-left: ${t.fileUploaderFileSizeMarginLeft};\n flex: 1 0 auto;\n `;\n },\n\n sizeSmall(t: Theme) {\n return css`\n width: ${t.fileUploaderFileSizeWidthSmall};\n margin-right: ${t.fileUploaderFileSizeMarginSmall};\n font-size: ${t.fileUploaderFontSizeSmall};\n line-height: ${t.fileUploaderLineHeightSmall};\n `;\n },\n\n sizeMedium(t: Theme) {\n return css`\n width: ${t.fileUploaderFileSizeWidthMedium};\n margin-right: ${t.fileUploaderFileSizeMarginMedium};\n font-size: ${t.fileUploaderFontSizeMedium};\n line-height: ${t.fileUploaderLineHeightMedium};\n `;\n },\n\n sizeLarge(t: Theme) {\n return css`\n width: ${t.fileUploaderFileSizeWidthLarge};\n margin-right: ${t.fileUploaderFileSizeMarginLarge};\n font-size: ${t.fileUploaderFontSizeLarge};\n line-height: ${t.fileUploaderLineHeightLarge};\n `;\n },\n\n icon(t: Theme) {\n return css`\n position: absolute;\n top: ${t.fileUploaderIconGapSmall};\n right: ${t.fileUploaderIconGapSmall};\n display: flex;\n flex: 1 0 auto;\n align-items: center;\n justify-content: center;\n width: ${t.fileUploaderTileIconSizeSmall};\n border-radius: ${t.fileUploaderBorderRadius};\n cursor: pointer;\n text-align: center;\n outline: none;\n &:hover {\n background: ${t.fileUploaderHoveredBg};\n }\n &:active {\n background: ${t.fileUploaderActiveBg};\n }\n `;\n },\n\n disabledFileTypeIconSvg(t: Theme) {\n return css`\n svg {\n fill: ${t.fileUploaderDisabledFileTypeIcon} !important;\n }\n `;\n },\n\n fileTypeIconMultiple() {\n return css`\n margin-left: 0;\n `;\n },\n\n contentSmall(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeSmall};\n line-height: ${t.fileUploaderLineHeightSmall};\n `;\n },\n\n contentMedium(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeMedium};\n line-height: ${t.fileUploaderLineHeightMedium};\n `;\n },\n\n contentLarge(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeLarge};\n line-height: ${t.fileUploaderLineHeightLarge};\n `;\n },\n}));\n\nexport const getJsRowStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n content() {\n return css`\n flex-direction: row;\n `;\n },\n\n contentSmall(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderFileIconSizeSmall};\n `;\n },\n\n contentMedium(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderFileIconSizeMedium};\n `;\n },\n\n contentLarge(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderFileIconSizeMedium};\n `;\n },\n\n iconSmall(t: Theme) {\n return css`\n height: ${t.fileUploaderFileIconSizeSmall};\n width: ${t.fileUploaderFileIconSizeSmall};\n `;\n },\n\n iconMedium(t: Theme) {\n return css`\n height: ${t.fileUploaderFileIconSizeMedium};\n width: ${t.fileUploaderFileIconSizeMedium};\n `;\n },\n\n iconLarge(t: Theme) {\n return css`\n height: ${t.fileUploaderFileIconSizeLarge};\n width: ${t.fileUploaderFileIconSizeLarge};\n `;\n },\n\n fileTypeIconSmall(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderIconGapSmall};\n `;\n },\n\n fileTypeIconMedium(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderIconGapMedium};\n `;\n },\n\n fileTypeIconLarge(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderIconGapLarge};\n `;\n },\n\n iconColor(t: Theme) {\n return css`\n color: ${t.fileUploaderIconColor};\n &:hover {\n color: ${t.fileUploaderIconHoverColor};\n }\n `;\n },\n\n size(t: Theme) {\n return css`\n margin-left: ${t.fileUploaderIconGapSmall};\n color: ${t.fileUploaderDisabledColor};\n `;\n },\n\n name() {\n return css`\n flex: 1 1 100%;\n overflow: hidden;\n `;\n },\n\n nameBlock() {\n return css`\n flex: 1 1 100%;\n `;\n },\n\n disabled(t: Theme) {\n return css`\n cursor: default;\n color: ${t.fileUploaderDisabledTextColor};\n `;\n },\n };\n});\n\nexport const getJsTileStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n content() {\n return css`\n flex-direction: column;\n align-items: center;\n height: inherit;\n `;\n },\n\n iconAction(t: Theme) {\n return css`\n border-radius: ${t.fileUploaderBorderRadius};\n opacity: 0;\n background: ${t.fileUploaderTileIconColorBg};\n\n &:hover {\n background: ${t.fileUploaderTileIconHoverColorBg};\n }\n\n &:active {\n background: ${t.fileUploaderTileIconActiveColorBg};\n }\n `;\n },\n\n iconActionShow() {\n return css`\n opacity: 1;\n `;\n },\n\n iconSmall(t: Theme) {\n return css`\n width: ${t.fileUploaderTileIconSizeSmall};\n height: ${t.fileUploaderTileIconSizeSmall};\n padding: ${t.fileUploaderTileIconActionPaddingSmall};\n top: ${t.fileUploaderTileIconActionPositionSmall};\n right: ${t.fileUploaderTileIconActionPositionSmall};\n `;\n },\n\n iconMedium(t: Theme) {\n return css`\n width: ${t.fileUploaderTileIconSizeMedium};\n height: ${t.fileUploaderTileIconSizeMedium};\n padding: ${t.fileUploaderTileIconActionPaddingMedium};\n top: ${t.fileUploaderTileIconActionPositionMedium};\n right: ${t.fileUploaderTileIconActionPositionMedium};\n `;\n },\n\n iconLarge(t: Theme) {\n return css`\n width: ${t.fileUploaderTileIconSizeLarge};\n height: ${t.fileUploaderTileIconSizeLarge};\n padding: ${t.fileUploaderTileIconActionPaddingLarge};\n top: ${t.fileUploaderTileIconActionPositionLarge};\n right: ${t.fileUploaderTileIconActionPositionLarge};\n `;\n },\n\n fileTypeIcon(t: Theme) {\n return css`\n width: 100%;\n border: 1px solid ${t.fileUploaderDisabledBorderColor};\n border-radius: ${t.fileUploaderBorderRadius};\n box-sizing: border-box;\n display: flex;\n align-items: center;\n justify-content: center;\n `;\n },\n\n fileTypeIconPreview() {\n return css`\n background-position: top;\n background-size: cover;\n background-repeat: no-repeat;\n `;\n },\n\n fileTypeIconSmall(t: Theme) {\n return css`\n margin-bottom: ${t.fileUploaderIconGapSmall};\n height: ${t.fileUploaderTileTypeIconHeightSmall};\n `;\n },\n\n fileTypeIconMedium(t: Theme) {\n return css`\n margin-bottom: ${t.fileUploaderIconGapMedium};\n height: ${t.fileUploaderTileTypeIconHeightMedium};\n `;\n },\n\n fileTypeIconLarge(t: Theme) {\n return css`\n margin-bottom: ${t.fileUploaderIconGapLarge};\n height: ${t.fileUploaderTileTypeIconHeightLarge};\n `;\n },\n\n disabledFileTypeIcon(t: Theme) {\n return css`\n box-shadow: none;\n background: ${t.fileUploaderDisabledBg};\n `;\n },\n\n sizeDisabled(t: Theme) {\n return css`\n color: ${t.fileUploaderDisabledIconColor};\n `;\n },\n\n errorFileTypeIcon(t: Theme) {\n return css`\n background: ${t.fileUploaderErrorBgColor};\n border: 1px solid ${t.fileUploaderErrorBgColor};\n `;\n },\n\n warningFileTypeIcon(t: Theme) {\n return css`\n background: ${t.fileUploaderWarningBgColor};\n border: 1px solid ${t.fileUploaderWarningBgColor};\n `;\n },\n\n iconColor(t: Theme) {\n return css`\n color: ${t.fileUploaderTileIconColor};\n &:hover {\n color: ${t.fileUploaderTileIconHoverColor};\n }\n `;\n },\n\n size(t: Theme) {\n return css`\n width: 100%;\n margin: ${t.fileUploaderIconGapSmall} 0 0;\n overflow: hidden;\n text-align: center;\n color: ${t.clearCrossIconColor};\n `;\n },\n\n name() {\n return css`\n flex: 1 1 100%;\n word-break: break-all;\n height: 100%;\n\n span {\n word-break: break-word;\n }\n `;\n },\n\n nameBlock() {\n return css`\n flex: 0;\n text-align: center;\n `;\n },\n\n contentSmall(t: Theme) {\n const maxHeight = parseInt(t.fileUploaderLineHeightSmall) * 2;\n return css`\n max-height: ${maxHeight}px;\n `;\n },\n\n contentMedium(t: Theme) {\n const maxHeight = parseInt(t.fileUploaderLineHeightMedium) * 2;\n return css`\n max-height: ${maxHeight}px;\n `;\n },\n\n contentLarge(t: Theme) {\n const maxHeight = parseInt(t.fileUploaderLineHeightLarge) * 2;\n return css`\n max-height: ${maxHeight}px;\n `;\n },\n\n disabled(t: Theme) {\n return css`\n cursor: default;\n color: ${t.fileUploaderDisabledIconColor};\n `;\n },\n };\n});\n"]}
|
|
1
|
+
{"version":3,"file":"FileUploaderFile.styles.js","sourceRoot":"","sources":["FileUploaderFile.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAGhE,MAAM,CAAC,IAAM,WAAW,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;IAAgB,OAAA,CAAC;QACjE,IAAI;YACF,OAAO,GAAG,uHAAA,oDAGT,KAAC;QACJ,CAAC;QAED,OAAO;YACL,OAAO,GAAG,mJAAA,gFAIT,KAAC;QACJ,CAAC;QAED,mBAAmB,YAAC,CAAQ;YAC1B,OAAO,GAAG,+FAAA,iBACC,EAA4B,SACtC,KADU,CAAC,CAAC,0BAA0B,EACrC;QACJ,CAAC;QAED,qBAAqB,YAAC,CAAQ;YAC5B,OAAO,GAAG,+FAAA,iBACC,EAA8B,SACxC,KADU,CAAC,CAAC,4BAA4B,EACvC;QACJ,CAAC;QAED,SAAS;YACP,OAAO,GAAG,oKAAA,iGAKT,KAAC;QACJ,CAAC;QAED,IAAI,YAAC,CAAQ;YACX,OAAO,GAAG,4HAAA,uBACO,EAAgC,gCAEhD,KAFgB,CAAC,CAAC,8BAA8B,EAE/C;QACJ,CAAC;QAED,SAAS,YAAC,CAAQ;YAChB,OAAO,GAAG,4KAAA,iBACC,EAAgC,yBACzB,EAAiC,sBACpC,EAA2B,wBACzB,EAA6B,SAC7C,KAJU,CAAC,CAAC,8BAA8B,EACzB,CAAC,CAAC,+BAA+B,EACpC,CAAC,CAAC,yBAAyB,EACzB,CAAC,CAAC,2BAA2B,EAC5C;QACJ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AAO,GAAG,2JAAA,mBACC,EAA2B,yCAEzB,EAAgC,sBAE5C,KAJU,CAAC,CAAC,yBAAyB,EAEzB,CAAC,CAAC,8BAA8B,EAE3C;QACJ,CAAC;QAED,IAAI,YAAC,CAAQ;YACX,OAAO,GAAG,8MAAA,0CAEE,EAA0B,gFAG3B,EAAqB,WAC/B,KAJW,CAAC,CAAC,wBAAwB,EAG3B,CAAC,CAAC,mBAAmB,EAC9B;QACJ,CAAC;QAED,IAAI;YACF,OAAO,GAAG,+NAAA,0JAQT,KAAC;QACJ,CAAC;QAED,SAAS;YACP,OAAO,GAAG,8HAAA,yDAGT,KAAC;QACJ,CAAC;QAED,YAAY,YAAC,CAAQ;YACnB,IAAM,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,2BAA2B,CAAC,GAAG,CAAC,CAAC;YAC9D,OAAO,GAAG,4GAAA,wBACM,EAAS,aACxB,KADe,SAAS,EACvB;QACJ,CAAC;QAED,aAAa,YAAC,CAAQ;YACpB,IAAM,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,4BAA4B,CAAC,GAAG,CAAC,CAAC;YAC/D,OAAO,GAAG,4GAAA,wBACM,EAAS,aACxB,KADe,SAAS,EACvB;QACJ,CAAC;QAED,YAAY,YAAC,CAAQ;YACnB,IAAM,SAAS,GAAG,QAAQ,CAAC,CAAC,CAAC,2BAA2B,CAAC,GAAG,CAAC,CAAC;YAC9D,OAAO,GAAG,4GAAA,wBACM,EAAS,aACxB,KADe,SAAS,EACvB;QACJ,CAAC;QAED,QAAQ,YAAC,CAAQ;YACf,OAAO,GAAG,+HAAA,6CAEC,EAA+B,WACzC,KADU,CAAC,CAAC,6BAA6B,EACxC;QACJ,CAAC;KACF,CAAC;AACJ,CAAC,CAAC,CAAC","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\n\nimport { memoizeGetStyles } from '../../lib/theming/Emotion.js';\nimport type { Theme } from '../../lib/theming/Theme.js';\n\nexport const getJsStyles = memoizeGetStyles(({ css }: Emotion) => ({\n root() {\n return css`\n width: 100%;\n height: inherit;\n `;\n },\n\n content() {\n return css`\n display: flex;\n width: 100%;\n align-items: baseline;\n `;\n },\n\n validationTextError(t: Theme) {\n return css`\n color: ${t.fileUploaderErrorTextColor};\n `;\n },\n\n validationTextWarning(t: Theme) {\n return css`\n color: ${t.fileUploaderWarningTextColor};\n `;\n },\n\n nameBlock() {\n return css`\n display: flex;\n flex-wrap: wrap;\n flex: 1 1 100%;\n width: 100%;\n `;\n },\n\n size(t: Theme) {\n return css`\n margin-left: ${t.fileUploaderFileSizeMarginLeft};\n flex: 1 0 auto;\n `;\n },\n\n sizeSmall(t: Theme) {\n return css`\n width: ${t.fileUploaderFileSizeWidthSmall};\n margin-right: ${t.fileUploaderFileSizeMarginSmall};\n font-size: ${t.fileUploaderFontSizeSmall};\n line-height: ${t.fileUploaderLineHeightSmall};\n `;\n },\n\n sizeMedium(t: Theme) {\n return css`\n width: ${t.fileUploaderFileSizeWidthMedium};\n margin-right: ${t.fileUploaderFileSizeMarginMedium};\n font-size: ${t.fileUploaderFontSizeMedium};\n line-height: ${t.fileUploaderLineHeightMedium};\n `;\n },\n\n sizeLarge(t: Theme) {\n return css`\n width: ${t.fileUploaderFileSizeWidthLarge};\n margin-right: ${t.fileUploaderFileSizeMarginLarge};\n font-size: ${t.fileUploaderFontSizeLarge};\n line-height: ${t.fileUploaderLineHeightLarge};\n `;\n },\n\n icon(t: Theme) {\n return css`\n position: absolute;\n top: ${t.fileUploaderIconGapSmall};\n right: ${t.fileUploaderIconGapSmall};\n display: flex;\n flex: 1 0 auto;\n align-items: center;\n justify-content: center;\n width: ${t.fileUploaderTileIconSizeSmall};\n border-radius: ${t.fileUploaderBorderRadius};\n cursor: pointer;\n text-align: center;\n outline: none;\n transition: background-color ${t.transitionDuration} ${t.transitionTimingFunction};\n &:hover {\n background: ${t.fileUploaderHoveredBg};\n }\n &:active {\n background: ${t.fileUploaderActiveBg};\n }\n `;\n },\n\n disabledFileTypeIconSvg(t: Theme) {\n return css`\n svg {\n fill: ${t.fileUploaderDisabledFileTypeIcon} !important;\n }\n `;\n },\n\n fileTypeIconMultiple() {\n return css`\n margin-left: 0;\n `;\n },\n\n contentSmall(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeSmall};\n line-height: ${t.fileUploaderLineHeightSmall};\n `;\n },\n\n contentMedium(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeMedium};\n line-height: ${t.fileUploaderLineHeightMedium};\n `;\n },\n\n contentLarge(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeLarge};\n line-height: ${t.fileUploaderLineHeightLarge};\n `;\n },\n}));\n\nexport const getJsRowStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n content() {\n return css`\n flex-direction: row;\n `;\n },\n\n contentSmall(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderFileIconSizeSmall};\n `;\n },\n\n contentMedium(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderFileIconSizeMedium};\n `;\n },\n\n contentLarge(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderFileIconSizeMedium};\n `;\n },\n\n iconSmall(t: Theme) {\n return css`\n height: ${t.fileUploaderFileIconSizeSmall};\n width: ${t.fileUploaderFileIconSizeSmall};\n `;\n },\n\n iconMedium(t: Theme) {\n return css`\n height: ${t.fileUploaderFileIconSizeMedium};\n width: ${t.fileUploaderFileIconSizeMedium};\n `;\n },\n\n iconLarge(t: Theme) {\n return css`\n height: ${t.fileUploaderFileIconSizeLarge};\n width: ${t.fileUploaderFileIconSizeLarge};\n `;\n },\n\n fileTypeIconSmall(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderIconGapSmall};\n `;\n },\n\n fileTypeIconMedium(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderIconGapMedium};\n `;\n },\n\n fileTypeIconLarge(t: Theme) {\n return css`\n margin-right: ${t.fileUploaderIconGapLarge};\n `;\n },\n\n iconColor(t: Theme) {\n return css`\n color: ${t.fileUploaderIconColor};\n &:hover {\n color: ${t.fileUploaderIconHoverColor};\n }\n `;\n },\n\n size(t: Theme) {\n return css`\n margin-left: ${t.fileUploaderIconGapSmall};\n color: ${t.fileUploaderDisabledColor};\n `;\n },\n\n name() {\n return css`\n flex: 1 1 100%;\n overflow: hidden;\n `;\n },\n\n nameBlock() {\n return css`\n flex: 1 1 100%;\n `;\n },\n\n disabled(t: Theme) {\n return css`\n cursor: default;\n color: ${t.fileUploaderDisabledTextColor};\n `;\n },\n };\n});\n\nexport const getJsTileStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n content() {\n return css`\n flex-direction: column;\n align-items: center;\n height: inherit;\n `;\n },\n\n iconAction(t: Theme) {\n return css`\n border-radius: ${t.fileUploaderBorderRadius};\n opacity: 0;\n background: ${t.fileUploaderTileIconColorBg};\n transition: background-color ${t.transitionDuration} ${t.transitionTimingFunction};\n\n &:hover {\n background: ${t.fileUploaderTileIconHoverColorBg};\n }\n\n &:active {\n background: ${t.fileUploaderTileIconActiveColorBg};\n }\n `;\n },\n\n iconActionShow() {\n return css`\n opacity: 1;\n `;\n },\n\n iconSmall(t: Theme) {\n return css`\n width: ${t.fileUploaderTileIconSizeSmall};\n height: ${t.fileUploaderTileIconSizeSmall};\n padding: ${t.fileUploaderTileIconActionPaddingSmall};\n top: ${t.fileUploaderTileIconActionPositionSmall};\n right: ${t.fileUploaderTileIconActionPositionSmall};\n `;\n },\n\n iconMedium(t: Theme) {\n return css`\n width: ${t.fileUploaderTileIconSizeMedium};\n height: ${t.fileUploaderTileIconSizeMedium};\n padding: ${t.fileUploaderTileIconActionPaddingMedium};\n top: ${t.fileUploaderTileIconActionPositionMedium};\n right: ${t.fileUploaderTileIconActionPositionMedium};\n `;\n },\n\n iconLarge(t: Theme) {\n return css`\n width: ${t.fileUploaderTileIconSizeLarge};\n height: ${t.fileUploaderTileIconSizeLarge};\n padding: ${t.fileUploaderTileIconActionPaddingLarge};\n top: ${t.fileUploaderTileIconActionPositionLarge};\n right: ${t.fileUploaderTileIconActionPositionLarge};\n `;\n },\n\n fileTypeIcon(t: Theme) {\n return css`\n width: 100%;\n border: 1px solid ${t.fileUploaderDisabledBorderColor};\n border-radius: ${t.fileUploaderBorderRadius};\n box-sizing: border-box;\n display: flex;\n align-items: center;\n justify-content: center;\n `;\n },\n\n fileTypeIconPreview() {\n return css`\n background-position: top;\n background-size: cover;\n background-repeat: no-repeat;\n `;\n },\n\n fileTypeIconSmall(t: Theme) {\n return css`\n margin-bottom: ${t.fileUploaderIconGapSmall};\n height: ${t.fileUploaderTileTypeIconHeightSmall};\n `;\n },\n\n fileTypeIconMedium(t: Theme) {\n return css`\n margin-bottom: ${t.fileUploaderIconGapMedium};\n height: ${t.fileUploaderTileTypeIconHeightMedium};\n `;\n },\n\n fileTypeIconLarge(t: Theme) {\n return css`\n margin-bottom: ${t.fileUploaderIconGapLarge};\n height: ${t.fileUploaderTileTypeIconHeightLarge};\n `;\n },\n\n disabledFileTypeIcon(t: Theme) {\n return css`\n box-shadow: none;\n background: ${t.fileUploaderDisabledBg};\n `;\n },\n\n sizeDisabled(t: Theme) {\n return css`\n color: ${t.fileUploaderDisabledIconColor};\n `;\n },\n\n errorFileTypeIcon(t: Theme) {\n return css`\n background: ${t.fileUploaderErrorBgColor};\n border: 1px solid ${t.fileUploaderErrorBgColor};\n `;\n },\n\n warningFileTypeIcon(t: Theme) {\n return css`\n background: ${t.fileUploaderWarningBgColor};\n border: 1px solid ${t.fileUploaderWarningBgColor};\n `;\n },\n\n iconColor(t: Theme) {\n return css`\n color: ${t.fileUploaderTileIconColor};\n &:hover {\n color: ${t.fileUploaderTileIconHoverColor};\n }\n `;\n },\n\n size(t: Theme) {\n return css`\n width: 100%;\n margin: ${t.fileUploaderIconGapSmall} 0 0;\n overflow: hidden;\n text-align: center;\n color: ${t.clearCrossIconColor};\n `;\n },\n\n name() {\n return css`\n flex: 1 1 100%;\n word-break: break-all;\n height: 100%;\n\n span {\n word-break: break-word;\n }\n `;\n },\n\n nameBlock() {\n return css`\n flex: 0;\n text-align: center;\n `;\n },\n\n contentSmall(t: Theme) {\n const maxHeight = parseInt(t.fileUploaderLineHeightSmall) * 2;\n return css`\n max-height: ${maxHeight}px;\n `;\n },\n\n contentMedium(t: Theme) {\n const maxHeight = parseInt(t.fileUploaderLineHeightMedium) * 2;\n return css`\n max-height: ${maxHeight}px;\n `;\n },\n\n contentLarge(t: Theme) {\n const maxHeight = parseInt(t.fileUploaderLineHeightLarge) * 2;\n return css`\n max-height: ${maxHeight}px;\n `;\n },\n\n disabled(t: Theme) {\n return css`\n cursor: default;\n color: ${t.fileUploaderDisabledIconColor};\n `;\n },\n };\n});\n"]}
|
|
@@ -7,7 +7,7 @@ export var getJsStyles = memoizeGetStyles(function (_a) {
|
|
|
7
7
|
var css = _a.css;
|
|
8
8
|
return {
|
|
9
9
|
fileWrapper: function (t) {
|
|
10
|
-
return css(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n position: relative;\n width: 100%;\n height: max-content;\n display: flex;\n align-items: center;\n box-sizing: border-box;\n border-radius: ", ";\n border: ", " solid transparent;\n box-shadow: 0 0 0 1px transparent;\n cursor: pointer;\n\n &::before {\n position: absolute;\n content: ' ';\n width: 100%;\n height: 100%;\n border-radius: ", ";\n border: ", " solid transparent;\n box-shadow: 0 0 0 1px transparent;\n top: -1px;\n left: -1px;\n z-index: -1;\n }\n "], ["\n position: relative;\n width: 100%;\n height: max-content;\n display: flex;\n align-items: center;\n box-sizing: border-box;\n border-radius: ", ";\n border: ", " solid transparent;\n box-shadow: 0 0 0 1px transparent;\n cursor: pointer;\n\n &::before {\n position: absolute;\n content: ' ';\n width: 100%;\n height: 100%;\n border-radius: ", ";\n border: ", " solid transparent;\n box-shadow: 0 0 0 1px transparent;\n top: -1px;\n left: -1px;\n z-index: -1;\n }\n "])), t.fileUploaderBorderRadius, t.fileUploaderBorderWidth, t.fileUploaderBorderRadius, t.fileUploaderBorderWidth);
|
|
10
|
+
return css(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n position: relative;\n width: 100%;\n height: max-content;\n display: flex;\n align-items: center;\n box-sizing: border-box;\n border-radius: ", ";\n border: ", " solid transparent;\n box-shadow: 0 0 0 1px transparent;\n cursor: pointer;\n transition: background-color ", " ", ";\n\n &:active {\n background: ", ";\n }\n\n &::before {\n position: absolute;\n content: ' ';\n width: 100%;\n height: 100%;\n border-radius: ", ";\n border: ", " solid transparent;\n box-shadow: 0 0 0 1px transparent;\n top: -1px;\n left: -1px;\n z-index: -1;\n }\n "], ["\n position: relative;\n width: 100%;\n height: max-content;\n display: flex;\n align-items: center;\n box-sizing: border-box;\n border-radius: ", ";\n border: ", " solid transparent;\n box-shadow: 0 0 0 1px transparent;\n cursor: pointer;\n transition: background-color ", " ", ";\n\n &:active {\n background: ", ";\n }\n\n &::before {\n position: absolute;\n content: ' ';\n width: 100%;\n height: 100%;\n border-radius: ", ";\n border: ", " solid transparent;\n box-shadow: 0 0 0 1px transparent;\n top: -1px;\n left: -1px;\n z-index: -1;\n }\n "])), t.fileUploaderBorderRadius, t.fileUploaderBorderWidth, t.transitionDuration, t.transitionTimingFunction, t.fileUploaderActiveBg, t.fileUploaderBorderRadius, t.fileUploaderBorderWidth);
|
|
11
11
|
},
|
|
12
12
|
fileWrapperFocus: function (t) {
|
|
13
13
|
return css(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n border: ", " solid ", ";\n box-shadow: 0 0 0 1px ", ";\n "], ["\n border: ", " solid ", ";\n box-shadow: 0 0 0 1px ", ";\n "])), t.fileUploaderBorderWidth, t.fileUploaderBorderColorFocus, t.fileUploaderBorderColorFocus);
|
|
@@ -16,10 +16,10 @@ export var getJsStyles = memoizeGetStyles(function (_a) {
|
|
|
16
16
|
return css(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n background: ", ";\n border-color: ", ";\n "], ["\n background: ", ";\n border-color: ", ";\n "])), t.fileUploaderHoveredBg, t.fileUploaderHoveredBorderColor);
|
|
17
17
|
},
|
|
18
18
|
warningFile: function (t) {
|
|
19
|
-
return css(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n background: ", ";\n color: ", ";\n &:hover {\n background: ", ";\n border-radius: ", ";\n }\n &::before {\n background: ", ";\n }\n "], ["\n background: ", ";\n color: ", ";\n &:hover {\n background: ", ";\n border-radius: ", ";\n }\n &::before {\n background: ", ";\n }\n "])), t.fileUploaderWarningBgColor, t.fileUploaderValidationTextColor, t.fileUploaderWarningBgHoverColor, t.fileUploaderBorderRadius, t.fileUploaderWarningBgColor);
|
|
19
|
+
return css(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n background: ", ";\n color: ", ";\n transition: background-color ", " ", ";\n &:hover {\n background: ", ";\n border-radius: ", ";\n }\n &:active {\n background: ", ";\n }\n &::before {\n background: ", ";\n }\n "], ["\n background: ", ";\n color: ", ";\n transition: background-color ", " ", ";\n &:hover {\n background: ", ";\n border-radius: ", ";\n }\n &:active {\n background: ", ";\n }\n &::before {\n background: ", ";\n }\n "])), t.fileUploaderWarningBgColor, t.fileUploaderValidationTextColor, t.transitionDuration, t.transitionTimingFunction, t.fileUploaderWarningBgHoverColor, t.fileUploaderBorderRadius, t.fileUploaderWarningBgPressedColor, t.fileUploaderWarningBgColor);
|
|
20
20
|
},
|
|
21
21
|
errorFile: function (t) {
|
|
22
|
-
return css(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n background: ", ";\n color: ", ";\n &:hover {\n background: ", ";\n border-radius: ", ";\n }\n &::before {\n background: ", ";\n }\n "], ["\n background: ", ";\n color: ", ";\n &:hover {\n background: ", ";\n border-radius: ", ";\n }\n &::before {\n background: ", ";\n }\n "])), t.fileUploaderErrorBgColor, t.fileUploaderValidationTextColor, t.fileUploaderErrorBgHoverColor, t.fileUploaderBorderRadius, t.fileUploaderErrorBgColor);
|
|
22
|
+
return css(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n background: ", ";\n color: ", ";\n transition: background-color ", " ", ";\n &:hover {\n background: ", ";\n border-radius: ", ";\n }\n &:active {\n background: ", ";\n }\n &::before {\n background: ", ";\n }\n "], ["\n background: ", ";\n color: ", ";\n transition: background-color ", " ", ";\n &:hover {\n background: ", ";\n border-radius: ", ";\n }\n &:active {\n background: ", ";\n }\n &::before {\n background: ", ";\n }\n "])), t.fileUploaderErrorBgColor, t.fileUploaderValidationTextColor, t.transitionDuration, t.transitionTimingFunction, t.fileUploaderErrorBgHoverColor, t.fileUploaderBorderRadius, t.fileUploaderErrorBgPressedColor, t.fileUploaderErrorBgColor);
|
|
23
23
|
},
|
|
24
24
|
removeBorderTopRadius: function () {
|
|
25
25
|
return css(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n &::before {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n }\n "], ["\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n &::before {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n }\n "])));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileUploaderFileList.styles.js","sourceRoot":"","sources":["FileUploaderFileList.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AAGnE,MAAM,CAAC,IAAM,WAAW,GAAG,gBAAgB,CAAC,UAAC,EAAgB;QAAd,GAAG,SAAA;IAChD,OAAO;QACL,WAAW,YAAC,CAAQ;YAClB,OAAO,GAAG,2sBAAA,mMAOS,EAA0B,qBACjC,EAAyB,sPAShB,EAA0B,uBACjC,EAAyB,2JAMtC,KAjBkB,CAAC,CAAC,wBAAwB,EACjC,CAAC,CAAC,uBAAuB,EAShB,CAAC,CAAC,wBAAwB,EACjC,CAAC,CAAC,uBAAuB,EAMrC;QACJ,CAAC;QAED,gBAAgB,YAAC,CAAQ;YACvB,OAAO,GAAG,oJAAA,oBACE,EAAyB,SAAU,EAA8B,mCACnD,EAA8B,WACvD,KAFW,CAAC,CAAC,uBAAuB,EAAU,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,EAA4B,WACtC,KAFY,CAAC,CAAC,gCAAgC,EACpC,CAAC,CAAC,0BAA0B,EACrC;QACJ,CAAC;QAED,iBAAiB,YAAC,CAAQ;YACxB,OAAO,GAAG,oJAAA,qBACG,EAAmC,oBACrC,EAA6B,qBAC5B,EAA8B,WACzC,KAHY,CAAC,CAAC,iCAAiC,EACrC,CAAC,CAAC,2BAA2B,EAC5B,CAAC,CAAC,4BAA4B,EACxC;QACJ,CAAC;QAED,gBAAgB,YAAC,CAAQ;YACvB,OAAO,GAAG,oJAAA,qBACG,EAAkC,oBACpC,EAA4B,qBAC3B,EAA6B,WACxC,KAHY,CAAC,CAAC,gCAAgC,EACpC,CAAC,CAAC,0BAA0B,EAC3B,CAAC,CAAC,2BAA2B,EACvC;QACJ,CAAC;QAED,cAAc,YAAC,CAAQ;YACrB,OAAO,GAAG,+LAAA,oBACE,EAAyB,SAAU,EAA8B,4BAC1D,EAA0B,8CACnB,EAA8B,WACvD,KAHW,CAAC,CAAC,uBAAuB,EAAU,CAAC,CAAC,4BAA4B,EAC1D,CAAC,CAAC,wBAAwB,EACnB,CAAC,CAAC,4BAA4B,EACtD;QACJ,CAAC;QAED,gBAAgB,YAAC,CAAQ;YACvB,OAAO,GAAG,+LAAA,oBACE,EAAyB,SAAU,EAAgC,4BAC5D,EAA0B,8CACnB,EAAgC,WACzD,KAHW,CAAC,CAAC,uBAAuB,EAAU,CAAC,CAAC,8BAA8B,EAC5D,CAAC,CAAC,wBAAwB,EACnB,CAAC,CAAC,8BAA8B,EACxD;QACJ,CAAC;KACF,CAAC;AACJ,CAAC,CAAC,CAAC","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\n\nimport { memoizeGetStyles } from '../../../lib/theming/Emotion.js';\nimport type { Theme } from '../../../lib/theming/Theme.js';\n\nexport const getJsStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n fileWrapper(t: Theme) {\n return css`\n position: relative;\n width: 100%;\n height: max-content;\n display: flex;\n align-items: center;\n box-sizing: border-box;\n border-radius: ${t.fileUploaderBorderRadius};\n border: ${t.fileUploaderBorderWidth} solid transparent;\n box-shadow: 0 0 0 1px transparent;\n cursor: pointer;\n\n &::before {\n position: absolute;\n content: ' ';\n width: 100%;\n height: 100%;\n border-radius: ${t.fileUploaderBorderRadius};\n border: ${t.fileUploaderBorderWidth} solid transparent;\n box-shadow: 0 0 0 1px transparent;\n top: -1px;\n left: -1px;\n z-index: -1;\n }\n `;\n },\n\n fileWrapperFocus(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorFocus};\n box-shadow: 0 0 0 1px ${t.fileUploaderBorderColorFocus};\n `;\n },\n\n fileWrapperHover(t: Theme) {\n return css`\n background: ${t.fileUploaderHoveredBg};\n border-color: ${t.fileUploaderHoveredBorderColor};\n `;\n },\n\n warningFile(t: Theme) {\n return css`\n background: ${t.fileUploaderWarningBgColor};\n color: ${t.fileUploaderValidationTextColor};\n &:hover {\n background: ${t.fileUploaderWarningBgHoverColor};\n border-radius: ${t.fileUploaderBorderRadius};\n }\n &::before {\n background: ${t.fileUploaderWarningBgColor};\n }\n `;\n },\n\n errorFile(t: Theme) {\n return css`\n background: ${t.fileUploaderErrorBgColor};\n color: ${t.fileUploaderValidationTextColor};\n &:hover {\n background: ${t.fileUploaderErrorBgHoverColor};\n border-radius: ${t.fileUploaderBorderRadius};\n }\n &::before {\n background: ${t.fileUploaderErrorBgColor};\n }\n `;\n },\n\n removeBorderTopRadius() {\n return css`\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n &::before {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n }\n `;\n },\n\n removeBorderBottomRadius() {\n return css`\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n &::before {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n }\n `;\n },\n\n summary(t: Theme) {\n return css`\n display: flex;\n border-bottom: 1px solid ${t.tabColorHover};\n margin-bottom: ${t.fileUploaderListGap};\n order: -1;\n width: 100%;\n box-sizing: border-box;\n `;\n },\n\n summaryErrorText(t: Theme) {\n return css`\n color: ${t.fileUploaderErrorTextColor};\n margin-right: ${t.fileUploaderListSummaryTextGap};\n `;\n },\n\n summaryWarningText(t: Theme) {\n return css`\n color: ${t.fileUploaderWarningTextColor};\n `;\n },\n\n summarySmall(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeSmall};\n line-height: ${t.fileUploaderLineHeightSmall};\n padding: ${t.fileUploaderPaddingYSmall} ${t.fileUploaderPaddingXSmall};\n `;\n },\n\n summaryMedium(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeMedium};\n line-height: ${t.fileUploaderLineHeightMedium};\n padding: ${t.fileUploaderPaddingYMedium} ${t.fileUploaderPaddingXMedium};\n `;\n },\n\n summaryLarge(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeLarge};\n line-height: ${t.fileUploaderLineHeightLarge};\n padding: ${t.fileUploaderPaddingYLarge} ${t.fileUploaderPaddingXLarge};\n `;\n },\n };\n});\n\nexport const getJsRowStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n file() {\n return css`\n width: 100%;\n `;\n },\n\n fileListWrapper(t: Theme) {\n return css`\n display: block;\n width: 100%;\n margin-top: ${t.fileUploaderListGap};\n `;\n },\n\n fileWrapperSmall(t: Theme) {\n return css`\n padding: ${t.fileUploaderPaddingYSmall} ${t.fileUploaderPaddingXSmall};\n `;\n },\n\n fileWrapperMedium(t: Theme) {\n return css`\n padding: ${t.fileUploaderPaddingYMedium} ${t.fileUploaderPaddingXMedium};\n `;\n },\n\n fileWrapperLarge(t: Theme) {\n return css`\n padding: ${t.fileUploaderPaddingYLarge} ${t.fileUploaderPaddingXLarge};\n `;\n },\n\n errorFileFocus(t: Theme) {\n return css`\n background: ${t.fileUploaderErrorBgHoverColor};\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorError};\n border-radius: ${t.fileUploaderBorderRadius} !important;\n box-shadow: 0 0 0 1px ${t.fileUploaderBorderColorError};\n `;\n },\n\n warningFileFocus(t: Theme) {\n return css`\n background: ${t.fileUploaderWarningBgHoverColor};\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorWarning};\n border-radius: ${t.fileUploaderBorderRadius} !important;\n box-shadow: 0 0 0 1px ${t.fileUploaderBorderColorWarning};\n `;\n },\n };\n});\n\nexport const getJsTileStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n file() {\n return css`\n width: 100%;\n height: 100%;\n `;\n },\n\n fileListWrapper() {\n return css`\n display: contents;\n `;\n },\n\n fileWrapperSmall(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingSmall};\n width: ${t.fileUploaderTileWidthSmall};\n `;\n },\n\n fileWrapperMedium(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingMedium};\n width: ${t.fileUploaderTileWidthMedium};\n height: ${t.fileUploaderTileHeightMedium};\n `;\n },\n\n fileWrapperLarge(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingLarge};\n width: ${t.fileUploaderTileWidthLarge};\n height: ${t.fileUploaderTileHeightLarge};\n `;\n },\n\n errorFileFocus(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorError};\n border-radius: ${t.fileUploaderBorderRadius} !important;\n box-shadow: 0 0 0 1px ${t.fileUploaderBorderColorError};\n `;\n },\n\n warningFileFocus(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorWarning};\n border-radius: ${t.fileUploaderBorderRadius} !important;\n box-shadow: 0 0 0 1px ${t.fileUploaderBorderColorWarning};\n `;\n },\n };\n});\n"]}
|
|
1
|
+
{"version":3,"file":"FileUploaderFileList.styles.js","sourceRoot":"","sources":["FileUploaderFileList.styles.ts"],"names":[],"mappings":";;;;AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AAGnE,MAAM,CAAC,IAAM,WA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pC,CAAC,CAAC,0BAA0B,EAC3B,CAAC,CAAC,2BAA2B,EACvC;QACJ,CAAC;QAED,cAAc,YAAC,CAAQ;YACrB,OAAO,GAAG,+LAAA,oBACE,EAAyB,SAAU,EAA8B,4BAC1D,EAA0B,8CACnB,EAA8B,WACvD,KAHW,CAAC,CAAC,uBAAuB,EAAU,CAAC,CAAC,4BAA4B,EAC1D,CAAC,CAAC,wBAAwB,EACnB,CAAC,CAAC,4BAA4B,EACtD;QACJ,CAAC;QAED,gBAAgB,YAAC,CAAQ;YACvB,OAAO,GAAG,+LAAA,oBACE,EAAyB,SAAU,EAAgC,4BAC5D,EAA0B,8CACnB,EAAgC,WACzD,KAHW,CAAC,CAAC,uBAAuB,EAAU,CAAC,CAAC,8BAA8B,EAC5D,CAAC,CAAC,wBAAwB,EACnB,CAAC,CAAC,8BAA8B,EACxD;QACJ,CAAC;KACF,CAAC;AACJ,CAAC,CAAC,CAAC","sourcesContent":["import type { Emotion } from '@emotion/css/create-instance';\n\nimport { memoizeGetStyles } from '../../../lib/theming/Emotion.js';\nimport type { Theme } from '../../../lib/theming/Theme.js';\n\nexport const getJsStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n fileWrapper(t: Theme) {\n return css`\n position: relative;\n width: 100%;\n height: max-content;\n display: flex;\n align-items: center;\n box-sizing: border-box;\n border-radius: ${t.fileUploaderBorderRadius};\n border: ${t.fileUploaderBorderWidth} solid transparent;\n box-shadow: 0 0 0 1px transparent;\n cursor: pointer;\n transition: background-color ${t.transitionDuration} ${t.transitionTimingFunction};\n\n &:active {\n background: ${t.fileUploaderActiveBg};\n }\n\n &::before {\n position: absolute;\n content: ' ';\n width: 100%;\n height: 100%;\n border-radius: ${t.fileUploaderBorderRadius};\n border: ${t.fileUploaderBorderWidth} solid transparent;\n box-shadow: 0 0 0 1px transparent;\n top: -1px;\n left: -1px;\n z-index: -1;\n }\n `;\n },\n\n fileWrapperFocus(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorFocus};\n box-shadow: 0 0 0 1px ${t.fileUploaderBorderColorFocus};\n `;\n },\n\n fileWrapperHover(t: Theme) {\n return css`\n background: ${t.fileUploaderHoveredBg};\n border-color: ${t.fileUploaderHoveredBorderColor};\n `;\n },\n\n warningFile(t: Theme) {\n return css`\n background: ${t.fileUploaderWarningBgColor};\n color: ${t.fileUploaderValidationTextColor};\n transition: background-color ${t.transitionDuration} ${t.transitionTimingFunction};\n &:hover {\n background: ${t.fileUploaderWarningBgHoverColor};\n border-radius: ${t.fileUploaderBorderRadius};\n }\n &:active {\n background: ${t.fileUploaderWarningBgPressedColor};\n }\n &::before {\n background: ${t.fileUploaderWarningBgColor};\n }\n `;\n },\n\n errorFile(t: Theme) {\n return css`\n background: ${t.fileUploaderErrorBgColor};\n color: ${t.fileUploaderValidationTextColor};\n transition: background-color ${t.transitionDuration} ${t.transitionTimingFunction};\n &:hover {\n background: ${t.fileUploaderErrorBgHoverColor};\n border-radius: ${t.fileUploaderBorderRadius};\n }\n &:active {\n background: ${t.fileUploaderErrorBgPressedColor};\n }\n &::before {\n background: ${t.fileUploaderErrorBgColor};\n }\n `;\n },\n\n removeBorderTopRadius() {\n return css`\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n &::before {\n border-top-right-radius: 0;\n border-top-left-radius: 0;\n }\n `;\n },\n\n removeBorderBottomRadius() {\n return css`\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n &::before {\n border-bottom-right-radius: 0;\n border-bottom-left-radius: 0;\n }\n `;\n },\n\n summary(t: Theme) {\n return css`\n display: flex;\n border-bottom: 1px solid ${t.tabColorHover};\n margin-bottom: ${t.fileUploaderListGap};\n order: -1;\n width: 100%;\n box-sizing: border-box;\n `;\n },\n\n summaryErrorText(t: Theme) {\n return css`\n color: ${t.fileUploaderErrorTextColor};\n margin-right: ${t.fileUploaderListSummaryTextGap};\n `;\n },\n\n summaryWarningText(t: Theme) {\n return css`\n color: ${t.fileUploaderWarningTextColor};\n `;\n },\n\n summarySmall(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeSmall};\n line-height: ${t.fileUploaderLineHeightSmall};\n padding: ${t.fileUploaderPaddingYSmall} ${t.fileUploaderPaddingXSmall};\n `;\n },\n\n summaryMedium(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeMedium};\n line-height: ${t.fileUploaderLineHeightMedium};\n padding: ${t.fileUploaderPaddingYMedium} ${t.fileUploaderPaddingXMedium};\n `;\n },\n\n summaryLarge(t: Theme) {\n return css`\n font-size: ${t.fileUploaderFontSizeLarge};\n line-height: ${t.fileUploaderLineHeightLarge};\n padding: ${t.fileUploaderPaddingYLarge} ${t.fileUploaderPaddingXLarge};\n `;\n },\n };\n});\n\nexport const getJsRowStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n file() {\n return css`\n width: 100%;\n `;\n },\n\n fileListWrapper(t: Theme) {\n return css`\n display: block;\n width: 100%;\n margin-top: ${t.fileUploaderListGap};\n `;\n },\n\n fileWrapperSmall(t: Theme) {\n return css`\n padding: ${t.fileUploaderPaddingYSmall} ${t.fileUploaderPaddingXSmall};\n `;\n },\n\n fileWrapperMedium(t: Theme) {\n return css`\n padding: ${t.fileUploaderPaddingYMedium} ${t.fileUploaderPaddingXMedium};\n `;\n },\n\n fileWrapperLarge(t: Theme) {\n return css`\n padding: ${t.fileUploaderPaddingYLarge} ${t.fileUploaderPaddingXLarge};\n `;\n },\n\n errorFileFocus(t: Theme) {\n return css`\n background: ${t.fileUploaderErrorBgHoverColor};\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorError};\n border-radius: ${t.fileUploaderBorderRadius} !important;\n box-shadow: 0 0 0 1px ${t.fileUploaderBorderColorError};\n `;\n },\n\n warningFileFocus(t: Theme) {\n return css`\n background: ${t.fileUploaderWarningBgHoverColor};\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorWarning};\n border-radius: ${t.fileUploaderBorderRadius} !important;\n box-shadow: 0 0 0 1px ${t.fileUploaderBorderColorWarning};\n `;\n },\n };\n});\n\nexport const getJsTileStyles = memoizeGetStyles(({ css }: Emotion) => {\n return {\n file() {\n return css`\n width: 100%;\n height: 100%;\n `;\n },\n\n fileListWrapper() {\n return css`\n display: contents;\n `;\n },\n\n fileWrapperSmall(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingSmall};\n width: ${t.fileUploaderTileWidthSmall};\n `;\n },\n\n fileWrapperMedium(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingMedium};\n width: ${t.fileUploaderTileWidthMedium};\n height: ${t.fileUploaderTileHeightMedium};\n `;\n },\n\n fileWrapperLarge(t: Theme) {\n return css`\n padding: ${t.fileUploaderTileFilePaddingLarge};\n width: ${t.fileUploaderTileWidthLarge};\n height: ${t.fileUploaderTileHeightLarge};\n `;\n },\n\n errorFileFocus(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorError};\n border-radius: ${t.fileUploaderBorderRadius} !important;\n box-shadow: 0 0 0 1px ${t.fileUploaderBorderColorError};\n `;\n },\n\n warningFileFocus(t: Theme) {\n return css`\n border: ${t.fileUploaderBorderWidth} solid ${t.fileUploaderBorderColorWarning};\n border-radius: ${t.fileUploaderBorderRadius} !important;\n box-shadow: 0 0 0 1px ${t.fileUploaderBorderColorWarning};\n `;\n },\n };\n});\n"]}
|
|
@@ -116,7 +116,7 @@ var FxInput = /** @class */ (function (_super) {
|
|
|
116
116
|
var size = _this.size;
|
|
117
117
|
var commonInputProps = __assign({ corners: corners, size: size, width: '100%', ref: _this.refInput }, rest);
|
|
118
118
|
if (type === 'currency') {
|
|
119
|
-
return (React.createElement(CurrencyInput, __assign({}, commonInputProps, { signed: signed, integerDigits: integerDigits, fractionDigits: fractionDigits, value: value, onValueChange: _this.props.onValueChange })));
|
|
119
|
+
return (React.createElement(CurrencyInput, __assign({}, commonInputProps, { signed: signed, integerDigits: integerDigits, fractionDigits: fractionDigits, hideTrailingZeros: hideTrailingZeros, value: value, onValueChange: _this.props.onValueChange })));
|
|
120
120
|
}
|
|
121
121
|
if (mask) {
|
|
122
122
|
return (React.createElement(MaskedInput, __assign({}, commonInputProps, { leftIcon: _this.getLeftIcon(props), align: "right", mask: mask, maskChar: maskChar, formatChars: formatChars, alwaysShowMask: alwaysShowMask, value: value, onValueChange: _this.props.onValueChange })));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FxInput.js","sourceRoot":"","sources":["FxInput.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,OAAO,MAAM,SAAS,CAAC;AAE9B,OAAO,EAAE,aAAa,EAAE,MAAM,uCAAuC,CAAC;AAGtE,OAAO,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAEnE,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AACvD,OAAO,EAAE,QAAQ,EAAE,MAAM,iCAAiC,CAAC;AAE3D,OAAO,EAAE,YAAY,EAAE,MAAM,mCAAmC,CAAC;AAGjE,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE1D,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAE1C,OAAO,EAAE,WAAW,EAAyB,MAAM,yBAAyB,CAAC;AAC7E,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAyCzD,MAAM,CAAC,IAAM,eAAe,GAAG;IAC7B,IAAI,EAAE,eAAe;CACb,CAAC;AAKX;;;GAGG;AAGH;IAA6B,2BAA6B;IAA1D;;QAaU,WAAK,GAAiC,IAAI,CAAC;QAE3C,cAAQ,GAAG,iBAAiB,C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,CAAC,aAAa,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;IACtC,CAAC;IAEM,oCAAkB,GAAzB;QACE,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;IACtC,CAAC;IAEM,wBAAM,GAAb;QAAA,iBAaC;QAZC,OAAO,CACL,oBAAC,YAAY,CAAC,QAAQ,QACnB,UAAC,KAAK;YACL,KAAI,CAAC,KAAK,GAAG,KAAK,CAAC;YACnB,OAAO,CACL,oBAAC,aAAa,aAAC,WAAW,EAAE,KAAI,CAAC,WAAW,IAAM,KAAI,CAAC,QAAQ,EAAE,GAC9D,KAAI,CAAC,UAAU,CACF,CACjB,CAAC;QACJ,CAAC,CACqB,CACzB,CAAC;IACJ,CAAC;;IA7Ca,2BAAmB,GAAG,SAAS,AAAZ,CAAa;IAChC,mBAAW,GAAG,SAAS,AAAZ,CAAa;IAExB,oBAAY,GAAiB;QACzC,KAAK,EAAE,GAAG;QACV,IAAI,EAAE,MAAM;QACZ,KAAK,EAAE,EAAE;QACT,IAAI,EAAE,KAAK;KACZ,AALyB,CAKxB;IATS,OAAO;QAFnB,QAAQ;QACR,QAAQ;OACI,OAAO,CAqLnB;IAAD,cAAC;CAAA,AArLD,CAA6B,KAAK,CAAC,SAAS,GAqL3C;SArLY,OAAO","sourcesContent":["import type { AriaAttributes } from 'react';\nimport React from 'react';\nimport warning from 'warning';\n\nimport { CommonWrapper } from '../../internal/CommonWrapper/index.js';\nimport type { CommonProps, CommonWrapperRestProps } from '../../internal/CommonWrapper/types.js';\nimport type { DefaultizedProps } from '../../lib/createPropsGetter.js';\nimport { createPropsGetter } from '../../lib/createPropsGetter.js';\nimport type { TGetRootNode, TSetRootNode } from '../../lib/rootNode//rootNodeDecorator.js';\nimport { rootNode } from '../../lib/rootNode/index.js';\nimport { withSize } from '../../lib/size/SizeDecorator.js';\nimport type { Theme } from '../../lib/theming/Theme.js';\nimport { ThemeContext } from '../../lib/theming/ThemeContext.js';\nimport type { SizeProp } from '../../lib/types/props.js';\nimport type { Override } from '../../typings/utility-types.js';\nimport { CurrencyInput } from '../CurrencyInput/index.js';\nimport type { CurrencyInputProps } from '../CurrencyInput/index.js';\nimport { Group } from '../Group/index.js';\nimport { Input } from '../Input/index.js';\nimport type { InputProps } from '../Input/Input.js';\nimport { MaskedInput, type MaskedInputProps } from '../MaskedInput/index.js';\nimport { FxInputRestoreBtn } from './FxInputRestoreBtn.js';\nimport { MathFunctionIcon } from './MathFunctionIcon.js';\n\nexport interface FxInputProps\n extends\n Pick<AriaAttributes, 'aria-label'>,\n CommonProps,\n Pick<Partial<MaskedInputProps>, 'alwaysShowMask' | 'mask' | 'maskChar' | 'formatChars'>,\n Override<\n Omit<CurrencyInputProps, 'alwaysShowMask' | 'mask' | 'maskChar' | 'formatChars'>,\n {\n /** Управляет видимостью кнопки Restore:\n * - true — кнопка Restore не отображается. Значение в поле является автоматически рассчитанным.\n * - false — кнопка Restore отображается в поле. Значение в поле считается отредактированным. */\n auto?: boolean;\n\n /** Тип поля. */\n type?: 'currency' | InputProps['type'];\n\n /** Событие нажатия на кнопку Restore. */\n onRestore?: () => void;\n\n /** Событие изменения value. */\n onValueChange: CurrencyInputProps['onValueChange'] | InputProps['onValueChange'];\n\n /** Значение поля. */\n value?: string | number;\n\n /** Задаёт ref поля. */\n refInput?: (element: CurrencyInput | Input | null) => void;\n\n /** Убирает лишние нули после запятой. */\n hideTrailingZeros?: boolean;\n\n /** Атрибут aria-label кнопке Restore. */\n buttonAriaLabel?: AriaAttributes['aria-label'];\n\n /** @ignore */\n corners?: React.CSSProperties;\n }\n > {}\n\nexport const FxInputDataTids = {\n root: 'FxInput__root',\n} as const;\n\ntype DefaultProps = Required<Pick<FxInputProps, 'width' | 'type' | 'value' | 'auto'>>;\ntype DefaultizedFxInputProps = DefaultizedProps<FxInputProps, DefaultProps>;\n\n/** В автополе можно вывести автоматически рассчитанное цифровое значение. В него можно передавать итог любого вычисления, например, сумму других полей, процент или более сложную функцию.\n *\n * У поля есть иконка математической формулы и кнопка Restore — с её помощью пользователь может вернуть исходное значение, если редактировал поле. Видимость кнопки и поведение при нажатии нужно прописывать в компоненте самостоятельно.\n */\n@rootNode\n@withSize\nexport class FxInput extends React.Component<FxInputProps> {\n public static __KONTUR_REACT_UI__ = 'FxInput';\n public static displayName = 'FxInput';\n\n public static defaultProps: DefaultProps = {\n width: 250,\n type: 'text',\n value: '',\n auto: false,\n };\n\n private theme!: Theme;\n private size!: SizeProp;\n private input: Input | CurrencyInput | null = null;\n\n private getProps = createPropsGetter(FxInput.defaultProps);\n public getRootNode!: TGetRootNode;\n private setRootNode!: TSetRootNode;\n\n private validateProps(props: FxInputProps) {\n if (props.type === 'currency' && props.mask !== undefined) {\n warning(false, '[FxInput]: Prop \"mask\" is not supported when type=\"currency\"');\n }\n }\n\n public componentDidMount() {\n this.validateProps(this.getProps());\n }\n\n public componentDidUpdate() {\n this.validateProps(this.getProps());\n }\n\n public render(): React.JSX.Element {\n return (\n <ThemeContext.Consumer>\n {(theme) => {\n this.theme = theme;\n return (\n <CommonWrapper rootNodeRef={this.setRootNode} {...this.getProps()}>\n {this.renderMain}\n </CommonWrapper>\n );\n }}\n </ThemeContext.Consumer>\n );\n }\n\n public renderMain = (props: CommonWrapperRestProps<DefaultizedFxInputProps>): React.JSX.Element => {\n const button = props.auto ? null : (\n <FxInputRestoreBtn\n size={props.size}\n onRestore={props.onRestore}\n corners={props.corners}\n disabled={props.disabled}\n borderless={props.borderless}\n aria-label={props.buttonAriaLabel}\n />\n );\n\n return (\n <Group data-tid={FxInputDataTids.root} width={props.width}>\n {button}\n {this.getInput(props)}\n </Group>\n );\n };\n\n /** Программно устанавливает фокус на поле.\n * Появляется фокусная рамка, элемент получает клавиатурные события и воспринимается как текущий элемент для чтения скринридерами.\n * @public\n */\n public focus = (): void => {\n if (this.input) {\n this.input.focus();\n }\n };\n\n /** Программно снимает фокус с кнопки.\n * @public\n */\n public blur = (): void => {\n if (this.input) {\n this.input.blur();\n }\n };\n\n private refInput = (element: Input | CurrencyInput | null) => {\n this.input = element;\n\n if (this.props.refInput) {\n this.props.refInput(this.input);\n }\n };\n\n private getLeftIcon = (props: FxInputProps) => {\n if (!props.auto) {\n return null;\n }\n\n const iconSizes: Record<SizeProp, number> = {\n small: parseInt(this.theme.inputIconSizeSmall),\n medium: parseInt(this.theme.inputIconSizeMedium),\n large: parseInt(this.theme.inputIconSizeLarge),\n };\n const size = this.size;\n\n return <MathFunctionIcon size={iconSizes[size]} />;\n };\n\n private getInput = (props: FxInputProps) => {\n const {\n type,\n onRestore,\n auto,\n refInput,\n value,\n width,\n size: _size,\n mask,\n maskChar,\n formatChars,\n alwaysShowMask,\n signed,\n integerDigits,\n fractionDigits,\n hideTrailingZeros,\n buttonAriaLabel,\n corners: originalCorners,\n ...rest\n } = props;\n const corners: InputProps['corners'] = auto\n ? originalCorners\n : { borderBottomLeftRadius: 0, borderTopLeftRadius: 0, ...originalCorners };\n const size = this.size;\n const commonInputProps = {\n corners,\n size,\n width: '100%',\n ref: this.refInput,\n ...rest,\n };\n\n if (type === 'currency') {\n return (\n <CurrencyInput\n {...commonInputProps}\n signed={signed}\n integerDigits={integerDigits}\n fractionDigits={fractionDigits}\n value={value as CurrencyInputProps['value']}\n onValueChange={this.props.onValueChange as CurrencyInputProps['onValueChange']}\n />\n );\n }\n if (mask) {\n return (\n <MaskedInput\n {...commonInputProps}\n leftIcon={this.getLeftIcon(props)}\n align=\"right\"\n mask={mask}\n maskChar={maskChar}\n formatChars={formatChars}\n alwaysShowMask={alwaysShowMask}\n value={value as MaskedInputProps['value']}\n onValueChange={this.props.onValueChange as MaskedInputProps['onValueChange']}\n />\n );\n }\n return (\n <Input\n {...commonInputProps}\n leftIcon={this.getLeftIcon(props)}\n align=\"right\"\n type={type}\n value={value as InputProps['value']}\n onValueChange={this.props.onValueChange as InputProps['onValueChange']}\n />\n );\n };\n}\n"]}
|
|
1
|
+
{"version":3,"file":"FxInput.js","source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K,GAAG,KAAK,CAAC;YACnB,OAAO,CACL,oBAAC,aAAa,aAAC,WAAW,EAAE,KAAI,CAAC,WAAW,IAAM,KAAI,CAAC,QAAQ,EAAE,GAC9D,KAAI,CAAC,UAAU,CACF,CACjB,CAAC;QACJ,CAAC,CACqB,CACzB,CAAC;IACJ,CAAC;;IA7Ca,2BAAmB,GAAG,SAAS,AAAZ,CAAa;IAChC,mBAAW,GAAG,SAAS,AAAZ,CAAa;IAExB,oBAAY,GAAiB;QACzC,KAAK,EAAE,GAAG;QACV,IAAI,EAAE,MAAM;QACZ,KAAK,EAAE,EAAE;QACT,IAAI,EAAE,KAAK;KACZ,AALyB,CAKxB;IATS,OAAO;QAFnB,QAAQ;QACR,QAAQ;OACI,OAAO,CAsLnB;IAAD,cAAC;CAAA,AAtLD,CAA6B,KAAK,CAAC,SAAS,GAsL3C;SAtLY,OAAO","sourcesContent":["import type { AriaAttributes } from 'react';\nimport React from 'react';\nimport warning from 'warning';\n\nimport { CommonWrapper } from '../../internal/CommonWrapper/index.js';\nimport type { CommonProps, CommonWrapperRestProps } from '../../internal/CommonWrapper/types.js';\nimport type { DefaultizedProps } from '../../lib/createPropsGetter.js';\nimport { createPropsGetter } from '../../lib/createPropsGetter.js';\nimport type { TGetRootNode, TSetRootNode } from '../../lib/rootNode//rootNodeDecorator.js';\nimport { rootNode } from '../../lib/rootNode/index.js';\nimport { withSize } from '../../lib/size/SizeDecorator.js';\nimport type { Theme } from '../../lib/theming/Theme.js';\nimport { ThemeContext } from '../../lib/theming/ThemeContext.js';\nimport type { SizeProp } from '../../lib/types/props.js';\nimport type { Override } from '../../typings/utility-types.js';\nimport { CurrencyInput } from '../CurrencyInput/index.js';\nimport type { CurrencyInputProps } from '../CurrencyInput/index.js';\nimport { Group } from '../Group/index.js';\nimport { Input } from '../Input/index.js';\nimport type { InputProps } from '../Input/Input.js';\nimport { MaskedInput, type MaskedInputProps } from '../MaskedInput/index.js';\nimport { FxInputRestoreBtn } from './FxInputRestoreBtn.js';\nimport { MathFunctionIcon } from './MathFunctionIcon.js';\n\nexport interface FxInputProps\n extends\n Pick<AriaAttributes, 'aria-label'>,\n CommonProps,\n Pick<Partial<MaskedInputProps>, 'alwaysShowMask' | 'mask' | 'maskChar' | 'formatChars'>,\n Override<\n Omit<CurrencyInputProps, 'alwaysShowMask' | 'mask' | 'maskChar' | 'formatChars'>,\n {\n /** Управляет видимостью кнопки Restore:\n * - true — кнопка Restore не отображается. Значение в поле является автоматически рассчитанным.\n * - false — кнопка Restore отображается в поле. Значение в поле считается отредактированным. */\n auto?: boolean;\n\n /** Тип поля. */\n type?: 'currency' | InputProps['type'];\n\n /** Событие нажатия на кнопку Restore. */\n onRestore?: () => void;\n\n /** Событие изменения value. */\n onValueChange: CurrencyInputProps['onValueChange'] | InputProps['onValueChange'];\n\n /** Значение поля. */\n value?: string | number;\n\n /** Задаёт ref поля. */\n refInput?: (element: CurrencyInput | Input | null) => void;\n\n /** Убирает лишние нули после запятой. */\n hideTrailingZeros?: boolean;\n\n /** Атрибут aria-label кнопке Restore. */\n buttonAriaLabel?: AriaAttributes['aria-label'];\n\n /** @ignore */\n corners?: React.CSSProperties;\n }\n > {}\n\nexport const FxInputDataTids = {\n root: 'FxInput__root',\n} as const;\n\ntype DefaultProps = Required<Pick<FxInputProps, 'width' | 'type' | 'value' | 'auto'>>;\ntype DefaultizedFxInputProps = DefaultizedProps<FxInputProps, DefaultProps>;\n\n/** В автополе можно вывести автоматически рассчитанное цифровое значение. В него можно передавать итог любого вычисления, например, сумму других полей, процент или более сложную функцию.\n *\n * У поля есть иконка математической формулы и кнопка Restore — с её помощью пользователь может вернуть исходное значение, если редактировал поле. Видимость кнопки и поведение при нажатии нужно прописывать в компоненте самостоятельно.\n */\n@rootNode\n@withSize\nexport class FxInput extends React.Component<FxInputProps> {\n public static __KONTUR_REACT_UI__ = 'FxInput';\n public static displayName = 'FxInput';\n\n public static defaultProps: DefaultProps = {\n width: 250,\n type: 'text',\n value: '',\n auto: false,\n };\n\n private theme!: Theme;\n private size!: SizeProp;\n private input: Input | CurrencyInput | null = null;\n\n private getProps = createPropsGetter(FxInput.defaultProps);\n public getRootNode!: TGetRootNode;\n private setRootNode!: TSetRootNode;\n\n private validateProps(props: FxInputProps) {\n if (props.type === 'currency' && props.mask !== undefined) {\n warning(false, '[FxInput]: Prop \"mask\" is not supported when type=\"currency\"');\n }\n }\n\n public componentDidMount() {\n this.validateProps(this.getProps());\n }\n\n public componentDidUpdate() {\n this.validateProps(this.getProps());\n }\n\n public render(): React.JSX.Element {\n return (\n <ThemeContext.Consumer>\n {(theme) => {\n this.theme = theme;\n return (\n <CommonWrapper rootNodeRef={this.setRootNode} {...this.getProps()}>\n {this.renderMain}\n </CommonWrapper>\n );\n }}\n </ThemeContext.Consumer>\n );\n }\n\n public renderMain = (props: CommonWrapperRestProps<DefaultizedFxInputProps>): React.JSX.Element => {\n const button = props.auto ? null : (\n <FxInputRestoreBtn\n size={props.size}\n onRestore={props.onRestore}\n corners={props.corners}\n disabled={props.disabled}\n borderless={props.borderless}\n aria-label={props.buttonAriaLabel}\n />\n );\n\n return (\n <Group data-tid={FxInputDataTids.root} width={props.width}>\n {button}\n {this.getInput(props)}\n </Group>\n );\n };\n\n /** Программно устанавливает фокус на поле.\n * Появляется фокусная рамка, элемент получает клавиатурные события и воспринимается как текущий элемент для чтения скринридерами.\n * @public\n */\n public focus = (): void => {\n if (this.input) {\n this.input.focus();\n }\n };\n\n /** Программно снимает фокус с кнопки.\n * @public\n */\n public blur = (): void => {\n if (this.input) {\n this.input.blur();\n }\n };\n\n private refInput = (element: Input | CurrencyInput | null) => {\n this.input = element;\n\n if (this.props.refInput) {\n this.props.refInput(this.input);\n }\n };\n\n private getLeftIcon = (props: FxInputProps) => {\n if (!props.auto) {\n return null;\n }\n\n const iconSizes: Record<SizeProp, number> = {\n small: parseInt(this.theme.inputIconSizeSmall),\n medium: parseInt(this.theme.inputIconSizeMedium),\n large: parseInt(this.theme.inputIconSizeLarge),\n };\n const size = this.size;\n\n return <MathFunctionIcon size={iconSizes[size]} />;\n };\n\n private getInput = (props: FxInputProps) => {\n const {\n type,\n onRestore,\n auto,\n refInput,\n value,\n width,\n size: _size,\n mask,\n maskChar,\n formatChars,\n alwaysShowMask,\n signed,\n integerDigits,\n fractionDigits,\n hideTrailingZeros,\n buttonAriaLabel,\n corners: originalCorners,\n ...rest\n } = props;\n const corners: InputProps['corners'] = auto\n ? originalCorners\n : { borderBottomLeftRadius: 0, borderTopLeftRadius: 0, ...originalCorners };\n const size = this.size;\n const commonInputProps = {\n corners,\n size,\n width: '100%',\n ref: this.refInput,\n ...rest,\n };\n\n if (type === 'currency') {\n return (\n <CurrencyInput\n {...commonInputProps}\n signed={signed}\n integerDigits={integerDigits}\n fractionDigits={fractionDigits}\n hideTrailingZeros={hideTrailingZeros}\n value={value as CurrencyInputProps['value']}\n onValueChange={this.props.onValueChange as CurrencyInputProps['onValueChange']}\n />\n );\n }\n if (mask) {\n return (\n <MaskedInput\n {...commonInputProps}\n leftIcon={this.getLeftIcon(props)}\n align=\"right\"\n mask={mask}\n maskChar={maskChar}\n formatChars={formatChars}\n alwaysShowMask={alwaysShowMask}\n value={value as MaskedInputProps['value']}\n onValueChange={this.props.onValueChange as MaskedInputProps['onValueChange']}\n />\n );\n }\n return (\n <Input\n {...commonInputProps}\n leftIcon={this.getLeftIcon(props)}\n align=\"right\"\n type={type}\n value={value as InputProps['value']}\n onValueChange={this.props.onValueChange as InputProps['onValueChange']}\n />\n );\n };\n}\n"]}
|
|
@@ -289,21 +289,27 @@ var MenuItem = /** @class */ (function (_super) {
|
|
|
289
289
|
};
|
|
290
290
|
Object.defineProperty(MenuItem.prototype, "activeState", {
|
|
291
291
|
get: function () {
|
|
292
|
-
|
|
292
|
+
if (this.isSelected) {
|
|
293
|
+
return 'selected';
|
|
294
|
+
}
|
|
295
|
+
if (this.state.highlighted) {
|
|
296
|
+
return 'hover';
|
|
297
|
+
}
|
|
298
|
+
return this.props.state;
|
|
293
299
|
},
|
|
294
300
|
enumerable: false,
|
|
295
301
|
configurable: true
|
|
296
302
|
});
|
|
297
303
|
Object.defineProperty(MenuItem.prototype, "isHover", {
|
|
298
304
|
get: function () {
|
|
299
|
-
return (this.state.highlighted || this.props.state === 'hover') && !this.props.disabled;
|
|
305
|
+
return !this.isSelected && (this.state.highlighted || this.props.state === 'hover') && !this.props.disabled;
|
|
300
306
|
},
|
|
301
307
|
enumerable: false,
|
|
302
308
|
configurable: true
|
|
303
309
|
});
|
|
304
310
|
Object.defineProperty(MenuItem.prototype, "isSelected", {
|
|
305
311
|
get: function () {
|
|
306
|
-
return this.props.state === 'selected' && !this.
|
|
312
|
+
return this.props.state === 'selected' && !this.props.disabled;
|
|
307
313
|
},
|
|
308
314
|
enumerable: false,
|
|
309
315
|
configurable: true
|