@itcase/ui 1.8.18 → 1.8.21
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/dist/Avatar_cjs_CiQ14ufF.js +240 -0
- package/dist/Avatar_es_No9vSqji.js +236 -0
- package/dist/{Button_cjs_DjCsrrlr.js → Button_cjs_CnStmeGt.js} +12 -4
- package/dist/{Button_es_CHDT0-8K.js → Button_es_BV1bepl1.js} +12 -4
- package/dist/{ChipsGroup_cjs_CTpMiyQb.js → ChipsGroup_cjs_CL00pWKy.js} +2 -2
- package/dist/{ChipsGroup_es_CP_xm25C.js → ChipsGroup_es_Ciln2otW.js} +2 -2
- package/dist/{DatePicker_cjs_DPtOL1eW.js → DatePicker_cjs_DGgkpGbI.js} +4 -4
- package/dist/{DatePicker_es_DCuzMD0T.js → DatePicker_es_BIOyGm22.js} +4 -4
- package/dist/{DropdownItem_cjs_DW0UXopm.js → DropdownItem_cjs_DT-zspEr.js} +15 -15
- package/dist/{DropdownItem_es_vuNthDPa.js → DropdownItem_es_BJLFqVuH.js} +15 -15
- package/dist/{Group_cjs_DFmNT5Mq.js → Group_cjs_Cwt0gWk4.js} +10 -3
- package/dist/{Group_es_CRGwi5XI.js → Group_es_CYW2Hquh.js} +10 -3
- package/dist/{Image_cjs_DuIBtUq5.js → Image_cjs_CCWqbNn4.js} +11 -3
- package/dist/{Image_es_CSzHhlA1.js → Image_es_DZUVp0FS.js} +11 -3
- package/dist/{Label_cjs_mw4pHZR1.js → Label_cjs_Cqcf6ffp.js} +2 -2
- package/dist/{Label_es_CiPEDFcR.js → Label_es_CeNdA70T.js} +2 -2
- package/dist/Link_cjs_BlXrJ15R.js +303 -0
- package/dist/Link_es_CyJn7NFb.js +298 -0
- package/dist/{Loader_cjs_DZbIy6Ko.js → Loader_cjs_3VRzFLI2.js} +14 -2
- package/dist/{Loader_es_SHdP0IkA.js → Loader_es_DEYowVdU.js} +14 -2
- package/dist/Text_cjs_DPhKj3wf.js +68 -0
- package/dist/{Text_es_D012qJ8s.js → Text_es_BRb3qqKM.js} +8 -3
- package/dist/{Tooltip_cjs_BKOjNMkt.js → Tooltip_cjs_Cq5kuaIK.js} +480 -17
- package/dist/{Tooltip_es_C7zstTA2.js → Tooltip_es_D0PSqI2c.js} +480 -17
- package/dist/cjs/components/Accordion.js +3 -3
- package/dist/cjs/components/Avatar.js +13 -236
- package/dist/cjs/components/AvatarStack.js +35 -0
- package/dist/cjs/components/Badge.js +3 -3
- package/dist/cjs/components/Breadcrumbs.js +3 -3
- package/dist/cjs/components/Button.js +5 -5
- package/dist/cjs/components/Cell.js +4 -4
- package/dist/cjs/components/Checkbox.js +1 -1
- package/dist/cjs/components/Chips.js +4 -4
- package/dist/cjs/components/Choice.js +6 -6
- package/dist/cjs/components/CookiesWarning.js +13 -6
- package/dist/cjs/components/DatePeriod.js +8 -8
- package/dist/cjs/components/DatePicker.js +7 -7
- package/dist/cjs/components/Drawer.js +26 -2
- package/dist/cjs/components/Dropdown.js +5 -2
- package/dist/cjs/components/Group.js +1 -1
- package/dist/cjs/components/Icon.js +3 -3
- package/dist/cjs/components/Image.js +2 -2
- package/dist/cjs/components/InputPassword.js +226 -46
- package/dist/cjs/components/Label.js +4 -4
- package/dist/cjs/components/Link.js +1 -1
- package/dist/cjs/components/List.js +1 -1
- package/dist/cjs/components/Loader.js +2 -2
- package/dist/cjs/components/Logo.js +1 -1
- package/dist/cjs/components/MenuItem.js +2 -2
- package/dist/cjs/components/Modal.js +6 -6
- package/dist/cjs/components/ModalSheetBottom.js +7 -0
- package/dist/cjs/components/Notification.js +1 -1
- package/dist/cjs/components/Pagination.js +11 -9
- package/dist/cjs/components/Panel.js +2 -2
- package/dist/cjs/components/Radio.js +1 -1
- package/dist/cjs/components/Response.js +227 -183
- package/dist/cjs/components/Search.js +126 -13
- package/dist/cjs/components/Segmented.js +1 -1
- package/dist/cjs/components/Select.js +4 -4
- package/dist/cjs/components/Swiper.js +3 -3
- package/dist/cjs/components/Switch.js +238 -3
- package/dist/cjs/components/Tab.js +3 -3
- package/dist/cjs/components/Text.js +1 -1
- package/dist/cjs/components/Tile.js +240 -5
- package/dist/cjs/components/Title.js +3 -3
- package/dist/cjs/components/Tooltip.js +3 -3
- package/dist/components/Accordion.js +3 -3
- package/dist/components/Avatar.js +10 -237
- package/dist/components/AvatarStack.js +33 -0
- package/dist/components/Badge.js +3 -3
- package/dist/components/Breadcrumbs.js +3 -3
- package/dist/components/Button.js +5 -5
- package/dist/components/Cell.js +4 -4
- package/dist/components/Checkbox.js +1 -1
- package/dist/components/Chips.js +4 -4
- package/dist/components/Choice.js +6 -6
- package/dist/components/CookiesWarning.js +13 -7
- package/dist/components/DatePeriod.js +8 -8
- package/dist/components/DatePicker.js +7 -7
- package/dist/components/Drawer.js +26 -2
- package/dist/components/Dropdown.js +5 -2
- package/dist/components/Group.js +1 -1
- package/dist/components/Icon.js +3 -3
- package/dist/components/Image.js +2 -2
- package/dist/components/InputPassword.js +226 -45
- package/dist/components/Label.js +4 -4
- package/dist/components/Link.js +1 -1
- package/dist/components/List.js +1 -1
- package/dist/components/Loader.js +2 -2
- package/dist/components/Logo.js +1 -1
- package/dist/components/MenuItem.js +2 -2
- package/dist/components/Modal.js +6 -6
- package/dist/components/ModalSheetBottom.js +7 -1
- package/dist/components/Notification.js +1 -1
- package/dist/components/Pagination.js +11 -9
- package/dist/components/Panel.js +2 -2
- package/dist/components/Radio.js +1 -1
- package/dist/components/Response.js +227 -183
- package/dist/components/Search.js +126 -13
- package/dist/components/Segmented.js +1 -1
- package/dist/components/Select.js +4 -4
- package/dist/components/Swiper.js +3 -3
- package/dist/components/Switch.js +238 -3
- package/dist/components/Tab.js +3 -3
- package/dist/components/Text.js +1 -1
- package/dist/components/Tile.js +240 -5
- package/dist/components/Title.js +3 -3
- package/dist/components/Tooltip.js +3 -3
- package/dist/css/components/AvatarStack/AvatarStack.css +67 -0
- package/dist/css/components/Group/Group.css +6 -10
- package/dist/css/components/Icon/Icon.css +132 -8
- package/dist/css/components/Modal/Modal.css +20 -0
- package/dist/css/components/Text/Text.css +0 -9
- package/dist/css/styles/border-color/border-color_hover.css +6 -8
- package/dist/css/styles/fill/fill_active.css +19 -9
- package/dist/css/styles/fill/fill_active_hover.css +19 -0
- package/dist/css/styles/fill/fill_hover.css +19 -0
- package/dist/css/styles/text-color/text-color_active.css +17 -0
- package/dist/css/styles/text-color/text-color_active_hover.css +40 -0
- package/dist/stories/index.stories.js +49 -0
- package/dist/stories/useDevicePropsGenerator.mdx +76 -102
- package/dist/stories/useMediaQueries.mdx +32 -7
- package/dist/stories/useStyles.mdx +50 -2
- package/dist/types/components/AvatarStack/AvatarStack.d.ts +3 -0
- package/dist/types/components/AvatarStack/AvatarStack.interface.d.ts +9 -0
- package/dist/types/components/AvatarStack/index.d.ts +2 -0
- package/dist/types/components/Button/appearance/buttonDanger.d.ts +8 -0
- package/dist/types/components/CookiesWarning/CookiesWarning.appearance.d.ts +5 -0
- package/dist/types/components/CookiesWarning/index.d.ts +2 -1
- package/dist/types/components/Drawer/appearance/drawerSurface.d.ts +25 -0
- package/dist/types/components/Dropdown/appearance/dropdownAccent.d.ts +0 -6
- package/dist/types/components/Dropdown/appearance/dropdownSurface.d.ts +5 -0
- package/dist/types/components/InputPassword/InputPassword.appearance.d.ts +2 -3
- package/dist/types/components/InputPassword/InputPassword.interface.d.ts +4 -11
- package/dist/types/components/InputPassword/appearance/inputPasswordAccent.d.ts +20 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordDanger.d.ts +7 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordDisabled.d.ts +20 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordError.d.ts +11 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordInfo.d.ts +21 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordPrimary.d.ts +8 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordRequire.d.ts +20 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordSecondary.d.ts +8 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordSize.d.ts +59 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordStyle.d.ts +16 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordSuccess.d.ts +11 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordSurface.d.ts +25 -0
- package/dist/types/components/InputPassword/appearance/inputPasswordWarning.d.ts +11 -0
- package/dist/types/components/InputPassword/index.d.ts +1 -1
- package/dist/types/components/Link/appearance/linkAccent.d.ts +20 -0
- package/dist/types/components/Link/appearance/linkDanger.d.ts +7 -0
- package/dist/types/components/Link/appearance/linkDisabled.d.ts +20 -0
- package/dist/types/components/Link/appearance/linkError.d.ts +11 -0
- package/dist/types/components/Link/appearance/linkInfo.d.ts +21 -0
- package/dist/types/components/Link/appearance/linkPrimary.d.ts +8 -0
- package/dist/types/components/Link/appearance/linkRequire.d.ts +20 -0
- package/dist/types/components/Link/appearance/linkSecondary.d.ts +8 -0
- package/dist/types/components/Link/appearance/linkSize.d.ts +59 -0
- package/dist/types/components/Link/appearance/linkStyle.d.ts +16 -0
- package/dist/types/components/Link/appearance/linkSuccess.d.ts +11 -0
- package/dist/types/components/Link/appearance/linkSurface.d.ts +25 -0
- package/dist/types/components/Link/appearance/linkWarning.d.ts +11 -0
- package/dist/types/components/Loader/Loader.appearance.d.ts +3 -2
- package/dist/types/components/Loader/Loader.interface.d.ts +16 -17
- package/dist/types/components/Loader/appearance/loaderSize.d.ts +12 -0
- package/dist/types/components/ModalSheetBottom/ModalSheetBottom.appearance.d.ts +5 -0
- package/dist/types/components/ModalSheetBottom/index.d.ts +1 -0
- package/dist/types/components/Pagination/appearance/paginationSize.d.ts +8 -0
- package/dist/types/components/Pagination/appearance/paginationSurface.d.ts +2 -0
- package/dist/types/components/Response/Response.appearance.d.ts +2 -2
- package/dist/types/components/Response/appearance/responseAccent.d.ts +20 -0
- package/dist/types/components/Response/appearance/responseDanger.d.ts +7 -0
- package/dist/types/components/Response/appearance/responseDisabled.d.ts +20 -0
- package/dist/types/components/Response/appearance/responseError.d.ts +11 -0
- package/dist/types/components/Response/appearance/responseInfo.d.ts +21 -0
- package/dist/types/components/Response/appearance/responsePrimary.d.ts +8 -0
- package/dist/types/components/Response/appearance/responseRequire.d.ts +20 -0
- package/dist/types/components/Response/appearance/responseSecondary.d.ts +8 -0
- package/dist/types/components/Response/appearance/responseSize.d.ts +59 -0
- package/dist/types/components/Response/appearance/responseStyle.d.ts +16 -0
- package/dist/types/components/Response/appearance/responseSuccess.d.ts +11 -0
- package/dist/types/components/Response/appearance/responseSurface.d.ts +25 -0
- package/dist/types/components/Response/appearance/responseWarning.d.ts +11 -0
- package/dist/types/components/Search/appearance/searchDefault.d.ts +24 -0
- package/dist/types/components/Search/appearance/searchDisabled.d.ts +20 -0
- package/dist/types/components/Search/appearance/searchError.d.ts +20 -0
- package/dist/types/components/Search/appearance/searchRequire.d.ts +20 -0
- package/dist/types/components/Search/appearance/searchSize.d.ts +18 -8
- package/dist/types/components/Search/appearance/searchSuccess.d.ts +20 -0
- package/dist/types/components/Switch/Switch.appearance.d.ts +1 -1
- package/dist/types/components/Switch/appearance/switchAccent.d.ts +20 -0
- package/dist/types/components/Switch/appearance/switchDanger.d.ts +7 -0
- package/dist/types/components/Switch/appearance/switchDisabled.d.ts +20 -0
- package/dist/types/components/Switch/appearance/switchError.d.ts +11 -0
- package/dist/types/components/Switch/appearance/switchInfo.d.ts +21 -0
- package/dist/types/components/Switch/appearance/switchPrimary.d.ts +8 -0
- package/dist/types/components/Switch/appearance/switchRequire.d.ts +20 -0
- package/dist/types/components/Switch/appearance/switchSecondary.d.ts +8 -0
- package/dist/types/components/Switch/appearance/switchSize.d.ts +59 -0
- package/dist/types/components/Switch/appearance/switchStyle.d.ts +16 -0
- package/dist/types/components/Switch/appearance/switchSuccess.d.ts +11 -0
- package/dist/types/components/Switch/appearance/switchSurface.d.ts +25 -0
- package/dist/types/components/Switch/appearance/switchWarning.d.ts +11 -0
- package/dist/types/components/Tile/appearance/tileAccent.d.ts +20 -0
- package/dist/types/components/Tile/appearance/tileDanger.d.ts +7 -0
- package/dist/types/components/Tile/appearance/tileDisabled.d.ts +20 -0
- package/dist/types/components/Tile/appearance/tileError.d.ts +11 -0
- package/dist/types/components/Tile/appearance/tileInfo.d.ts +21 -0
- package/dist/types/components/Tile/appearance/tilePrimary.d.ts +8 -0
- package/dist/types/components/Tile/appearance/tileRequire.d.ts +20 -0
- package/dist/types/components/Tile/appearance/tileSecondary.d.ts +8 -0
- package/dist/types/components/Tile/appearance/tileSize.d.ts +59 -0
- package/dist/types/components/Tile/appearance/tileStyle.d.ts +16 -0
- package/dist/types/components/Tile/appearance/tileSuccess.d.ts +11 -0
- package/dist/types/components/Tile/appearance/tileSurface.d.ts +25 -0
- package/dist/types/components/Tile/appearance/tileWarning.d.ts +11 -0
- package/dist/types/components/Title/Title.appearance.d.ts +2 -2
- package/dist/types/components/Title/Title.interface.d.ts +3 -3
- package/dist/types/components/Title/appearance/titleAccent.d.ts +20 -0
- package/dist/types/components/Title/appearance/titleDanger.d.ts +7 -0
- package/dist/types/components/Title/appearance/titleDisabled.d.ts +20 -0
- package/dist/types/components/Title/appearance/titleError.d.ts +11 -0
- package/dist/types/components/Title/appearance/titleInfo.d.ts +21 -0
- package/dist/types/components/Title/appearance/titlePrimary.d.ts +8 -0
- package/dist/types/components/Title/appearance/titleRequire.d.ts +20 -0
- package/dist/types/components/Title/appearance/titleSecondary.d.ts +8 -0
- package/dist/types/components/Title/appearance/titleSize.d.ts +59 -0
- package/dist/types/components/Title/appearance/titleStyle.d.ts +16 -0
- package/dist/types/components/Title/appearance/titleSuccess.d.ts +11 -0
- package/dist/types/components/Title/appearance/titleSurface.d.ts +25 -0
- package/dist/types/components/Title/appearance/titleWarning.d.ts +11 -0
- package/dist/types/components/Tooltip/Tooltip.appearance.d.ts +1 -1
- package/dist/types/components/Tooltip/appearance/tooltipAccent.d.ts +20 -0
- package/dist/types/components/Tooltip/appearance/tooltipDanger.d.ts +7 -0
- package/dist/types/components/Tooltip/appearance/tooltipDisabled.d.ts +20 -0
- package/dist/types/components/Tooltip/appearance/tooltipError.d.ts +11 -0
- package/dist/types/components/Tooltip/appearance/tooltipInfo.d.ts +21 -0
- package/dist/types/components/Tooltip/appearance/tooltipPrimary.d.ts +8 -0
- package/dist/types/components/Tooltip/appearance/tooltipRequire.d.ts +20 -0
- package/dist/types/components/Tooltip/appearance/tooltipSecondary.d.ts +8 -0
- package/dist/types/components/Tooltip/appearance/tooltipSize.d.ts +59 -0
- package/dist/types/components/Tooltip/appearance/tooltipStyle.d.ts +16 -0
- package/dist/types/components/Tooltip/appearance/tooltipSuccess.d.ts +11 -0
- package/dist/types/components/Tooltip/appearance/tooltipSurface.d.ts +25 -0
- package/dist/types/components/Tooltip/appearance/tooltipWarning.d.ts +11 -0
- package/package.json +11 -11
- package/dist/Link_cjs_yht44xJv.js +0 -68
- package/dist/Link_es_DkW06IM-.js +0 -63
- package/dist/Text_cjs_iL1l_7V1.js +0 -63
- package/dist/stories/Pagination.mdx +0 -11
- package/dist/stories/Tile.mdx +0 -11
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@itcase/ui",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.21",
|
|
4
4
|
"description": "UI components (Modal, Loader, Popup, etc)",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Modal",
|
|
@@ -96,22 +96,22 @@
|
|
|
96
96
|
},
|
|
97
97
|
"dependencies": {
|
|
98
98
|
"@emotion/is-prop-valid": "^1.3.1",
|
|
99
|
-
"@itcase/common": "^1.2.
|
|
99
|
+
"@itcase/common": "^1.2.26",
|
|
100
100
|
"@itcase/config": "^1.0.47",
|
|
101
101
|
"@itcase/icons": "^1.1.1",
|
|
102
|
-
"@itcase/storybook-config": "^1.1.
|
|
102
|
+
"@itcase/storybook-config": "^1.1.13",
|
|
103
103
|
"@itcase/tokens-am": "^1.1.9",
|
|
104
104
|
"@itcase/tokens-baikal": "^1.1.9",
|
|
105
|
-
"@itcase/types": "^1.0.
|
|
106
|
-
"@itcase/tokens-palette": "^1.1.
|
|
105
|
+
"@itcase/types": "^1.0.4",
|
|
106
|
+
"@itcase/tokens-palette": "^1.1.11",
|
|
107
107
|
"clsx": "^2.1.1",
|
|
108
108
|
"date-fns": "^4.1.0",
|
|
109
109
|
"eslint-import-resolver-alias": "^1.1.2",
|
|
110
110
|
"eslint-plugin-import": "^2.31.0",
|
|
111
|
-
"framer-motion": "^12.
|
|
111
|
+
"framer-motion": "^12.16.0",
|
|
112
112
|
"js-cookie": "^3.0.5",
|
|
113
113
|
"lodash": "^4.17.21",
|
|
114
|
-
"motion": "^12.
|
|
114
|
+
"motion": "^12.16.0",
|
|
115
115
|
"rc-slider": "^11.1.8",
|
|
116
116
|
"react": "^18.3.1",
|
|
117
117
|
"react-dadata": "^2.27.4",
|
|
@@ -131,12 +131,12 @@
|
|
|
131
131
|
"uuid": "^11.1.0"
|
|
132
132
|
},
|
|
133
133
|
"devDependencies": {
|
|
134
|
-
"@babel/core": "^7.27.
|
|
134
|
+
"@babel/core": "^7.27.4",
|
|
135
135
|
"@babel/preset-env": "^7.27.2",
|
|
136
136
|
"@babel/preset-react": "^7.27.1",
|
|
137
137
|
"@commitlint/cli": "^19.8.1",
|
|
138
138
|
"@commitlint/config-conventional": "^19.8.1",
|
|
139
|
-
"@itcase/lint": "^1.1.
|
|
139
|
+
"@itcase/lint": "^1.1.10",
|
|
140
140
|
"@rollup/plugin-alias": "^5.1.1",
|
|
141
141
|
"@rollup/plugin-babel": "^6.0.4",
|
|
142
142
|
"@rollup/plugin-commonjs": "^28.0.3",
|
|
@@ -161,7 +161,7 @@
|
|
|
161
161
|
"babel-plugin-react-docgen": "^4.2.1",
|
|
162
162
|
"babel-plugin-transform-react-remove-prop-types": "^0.4.24",
|
|
163
163
|
"conventional-changelog-conventionalcommits": "^9.0.0",
|
|
164
|
-
"eslint": "9.
|
|
164
|
+
"eslint": "9.28.0",
|
|
165
165
|
"husky": "^9.1.7",
|
|
166
166
|
"lint-staged": "^16.1.0",
|
|
167
167
|
"npm": "^11.4.1",
|
|
@@ -176,7 +176,7 @@
|
|
|
176
176
|
"rollup-preserve-directives": "^1.1.3",
|
|
177
177
|
"semantic-release": "^24.2.5",
|
|
178
178
|
"storybook": "^8.6.14",
|
|
179
|
-
"stylelint": "^16.
|
|
179
|
+
"stylelint": "^16.20.0",
|
|
180
180
|
"typescript": "^5.8.3"
|
|
181
181
|
}
|
|
182
182
|
}
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var tslib_es6 = require('./tslib.es6_cjs_CCZ3TN_7.js');
|
|
4
|
-
var jsxRuntime = require('react/jsx-runtime');
|
|
5
|
-
var React = require('react');
|
|
6
|
-
var clsx = require('clsx');
|
|
7
|
-
var useDevicePropsGenerator = require('./cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
8
|
-
var useStyles = require('./cjs/hooks/useStyles/useStyles.js');
|
|
9
|
-
|
|
10
|
-
var linkAppearance = {
|
|
11
|
-
dev: {},
|
|
12
|
-
};
|
|
13
|
-
|
|
14
|
-
var linkConfig = {
|
|
15
|
-
appearance: linkAppearance,
|
|
16
|
-
LinkComponent: 'a',
|
|
17
|
-
setAppearance: function (appearanceConfig) {
|
|
18
|
-
linkConfig.appearance = appearanceConfig;
|
|
19
|
-
},
|
|
20
|
-
setLinkComponent: function (newComponent) {
|
|
21
|
-
linkConfig.LinkComponent = newComponent;
|
|
22
|
-
},
|
|
23
|
-
};
|
|
24
|
-
function Link(props) {
|
|
25
|
-
var className = props.className, appearance = props.appearance, text = props.text, href = props.href, link = props.link, LinkComponent = props.LinkComponent, rel = props.rel, style = props.style, target = props.target, _a = props.underline, underline = _a === void 0 ? 'underline' : _a, before = props.before, after = props.after, onClick = props.onClick, onMouseDown = props.onMouseDown, children = props.children;
|
|
26
|
-
var appearanceConfig = appearance === null || appearance === void 0 ? void 0 : appearance.split(' ').reduce(function (resultConfig, appearanceKey) {
|
|
27
|
-
var _a;
|
|
28
|
-
return (tslib_es6.__assign(tslib_es6.__assign({}, resultConfig), (_a = linkConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
29
|
-
}, {});
|
|
30
|
-
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
31
|
-
var directionClass = propsGenerator.directionClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, borderColorClass = propsGenerator.borderColorClass, borderColorHoverClass = propsGenerator.borderColorHoverClass, borderTypeClass = propsGenerator.borderTypeClass, borderWidthClass = propsGenerator.borderWidthClass, textColorClass = propsGenerator.textColorClass, textColorHoverClass = propsGenerator.textColorHoverClass, textGradientClass = propsGenerator.textGradientClass, textStyleClass = propsGenerator.textStyleClass, textWeightClass = propsGenerator.textWeightClass, heightClass = propsGenerator.heightClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, svgFillClass = propsGenerator.svgFillClass, svgFillHoverClass = propsGenerator.svgFillHoverClass, widthClass = propsGenerator.widthClass;
|
|
32
|
-
// @ts-expect-error
|
|
33
|
-
var styles = useStyles.useStyles(props).styles;
|
|
34
|
-
return (jsxRuntime.jsxs(LinkWrapper, { className: clsx(className, 'link', widthClass && "width_".concat(widthClass), heightClass && "height_".concat(heightClass), directionClass && "link_direction_".concat(directionClass), sizeClass && "text_size_".concat(sizeClass), svgFillClass && "svg_fill_".concat(svgFillClass), svgFillHoverClass && "svg_fill_hover_".concat(svgFillHoverClass), underline && "link_underline_".concat(underline), 'text', (textColorClass ||
|
|
35
|
-
textColorHoverClass ||
|
|
36
|
-
textGradientClass ||
|
|
37
|
-
textStyleClass ||
|
|
38
|
-
textWeightClass) &&
|
|
39
|
-
'text', textColorClass && "text-color_".concat(textColorClass), textColorHoverClass && "text-color_hover_".concat(textColorHoverClass), textGradientClass && "text-gradient_".concat(textGradientClass), textStyleClass && "text-style_".concat(textStyleClass), textWeightClass && "text-weight_".concat(textWeightClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), shapeClass && "link_shape_".concat(shapeClass)), Component: LinkComponent, href: href || link, rel: rel, style: Object.assign({}, styles, style), target: target, onClick: onClick, onMouseDown: onMouseDown, children: [before, children || text, after] }));
|
|
40
|
-
}
|
|
41
|
-
// Wrapper with "Link" by condition
|
|
42
|
-
function LinkWrapper(props) {
|
|
43
|
-
var Component = props.Component, DefaultComponent = props.DefaultComponent, href = props.href, rel = props.rel, target = props.target, children = props.children, otherProps = tslib_es6.__rest(props, ["Component", "DefaultComponent", "href", "rel", "target", "children"]);
|
|
44
|
-
if (href) {
|
|
45
|
-
// If href passed, make link-wrapper
|
|
46
|
-
var LinkComponent = Component || linkConfig.LinkComponent;
|
|
47
|
-
if (LinkComponent) {
|
|
48
|
-
return (jsxRuntime.jsx(LinkComponent, tslib_es6.__assign({ href: href, rel: rel, target: target }, otherProps, { children: children })));
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
else if (DefaultComponent) {
|
|
52
|
-
// If has default "Component" - render it
|
|
53
|
-
return jsxRuntime.jsx(DefaultComponent, tslib_es6.__assign({}, otherProps, { children: children }));
|
|
54
|
-
}
|
|
55
|
-
// Return children and pass current props to
|
|
56
|
-
return React.Children.toArray(children)
|
|
57
|
-
.filter(Boolean)
|
|
58
|
-
.map(function (child) {
|
|
59
|
-
return React.isValidElement(child)
|
|
60
|
-
? React.cloneElement(child, otherProps)
|
|
61
|
-
: child;
|
|
62
|
-
});
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
exports.Link = Link;
|
|
66
|
-
exports.LinkWrapper = LinkWrapper;
|
|
67
|
-
exports.linkAppearance = linkAppearance;
|
|
68
|
-
exports.linkConfig = linkConfig;
|
package/dist/Link_es_DkW06IM-.js
DELETED
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import { b as __rest, _ as __assign } from './tslib.es6_es_Bwu1Cn-t.js';
|
|
2
|
-
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
3
|
-
import React from 'react';
|
|
4
|
-
import clsx from 'clsx';
|
|
5
|
-
import { useDevicePropsGenerator } from './hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
6
|
-
import { useStyles } from './hooks/useStyles/useStyles.js';
|
|
7
|
-
|
|
8
|
-
var linkAppearance = {
|
|
9
|
-
dev: {},
|
|
10
|
-
};
|
|
11
|
-
|
|
12
|
-
var linkConfig = {
|
|
13
|
-
appearance: linkAppearance,
|
|
14
|
-
LinkComponent: 'a',
|
|
15
|
-
setAppearance: function (appearanceConfig) {
|
|
16
|
-
linkConfig.appearance = appearanceConfig;
|
|
17
|
-
},
|
|
18
|
-
setLinkComponent: function (newComponent) {
|
|
19
|
-
linkConfig.LinkComponent = newComponent;
|
|
20
|
-
},
|
|
21
|
-
};
|
|
22
|
-
function Link(props) {
|
|
23
|
-
var className = props.className, appearance = props.appearance, text = props.text, href = props.href, link = props.link, LinkComponent = props.LinkComponent, rel = props.rel, style = props.style, target = props.target, _a = props.underline, underline = _a === void 0 ? 'underline' : _a, before = props.before, after = props.after, onClick = props.onClick, onMouseDown = props.onMouseDown, children = props.children;
|
|
24
|
-
var appearanceConfig = appearance === null || appearance === void 0 ? void 0 : appearance.split(' ').reduce(function (resultConfig, appearanceKey) {
|
|
25
|
-
var _a;
|
|
26
|
-
return (__assign(__assign({}, resultConfig), (_a = linkConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
27
|
-
}, {});
|
|
28
|
-
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
29
|
-
var directionClass = propsGenerator.directionClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, borderColorClass = propsGenerator.borderColorClass, borderColorHoverClass = propsGenerator.borderColorHoverClass, borderTypeClass = propsGenerator.borderTypeClass, borderWidthClass = propsGenerator.borderWidthClass, textColorClass = propsGenerator.textColorClass, textColorHoverClass = propsGenerator.textColorHoverClass, textGradientClass = propsGenerator.textGradientClass, textStyleClass = propsGenerator.textStyleClass, textWeightClass = propsGenerator.textWeightClass, heightClass = propsGenerator.heightClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, svgFillClass = propsGenerator.svgFillClass, svgFillHoverClass = propsGenerator.svgFillHoverClass, widthClass = propsGenerator.widthClass;
|
|
30
|
-
// @ts-expect-error
|
|
31
|
-
var styles = useStyles(props).styles;
|
|
32
|
-
return (jsxs(LinkWrapper, { className: clsx(className, 'link', widthClass && "width_".concat(widthClass), heightClass && "height_".concat(heightClass), directionClass && "link_direction_".concat(directionClass), sizeClass && "text_size_".concat(sizeClass), svgFillClass && "svg_fill_".concat(svgFillClass), svgFillHoverClass && "svg_fill_hover_".concat(svgFillHoverClass), underline && "link_underline_".concat(underline), 'text', (textColorClass ||
|
|
33
|
-
textColorHoverClass ||
|
|
34
|
-
textGradientClass ||
|
|
35
|
-
textStyleClass ||
|
|
36
|
-
textWeightClass) &&
|
|
37
|
-
'text', textColorClass && "text-color_".concat(textColorClass), textColorHoverClass && "text-color_hover_".concat(textColorHoverClass), textGradientClass && "text-gradient_".concat(textGradientClass), textStyleClass && "text-style_".concat(textStyleClass), textWeightClass && "text-weight_".concat(textWeightClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), shapeClass && "link_shape_".concat(shapeClass)), Component: LinkComponent, href: href || link, rel: rel, style: Object.assign({}, styles, style), target: target, onClick: onClick, onMouseDown: onMouseDown, children: [before, children || text, after] }));
|
|
38
|
-
}
|
|
39
|
-
// Wrapper with "Link" by condition
|
|
40
|
-
function LinkWrapper(props) {
|
|
41
|
-
var Component = props.Component, DefaultComponent = props.DefaultComponent, href = props.href, rel = props.rel, target = props.target, children = props.children, otherProps = __rest(props, ["Component", "DefaultComponent", "href", "rel", "target", "children"]);
|
|
42
|
-
if (href) {
|
|
43
|
-
// If href passed, make link-wrapper
|
|
44
|
-
var LinkComponent = Component || linkConfig.LinkComponent;
|
|
45
|
-
if (LinkComponent) {
|
|
46
|
-
return (jsx(LinkComponent, __assign({ href: href, rel: rel, target: target }, otherProps, { children: children })));
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
else if (DefaultComponent) {
|
|
50
|
-
// If has default "Component" - render it
|
|
51
|
-
return jsx(DefaultComponent, __assign({}, otherProps, { children: children }));
|
|
52
|
-
}
|
|
53
|
-
// Return children and pass current props to
|
|
54
|
-
return React.Children.toArray(children)
|
|
55
|
-
.filter(Boolean)
|
|
56
|
-
.map(function (child) {
|
|
57
|
-
return React.isValidElement(child)
|
|
58
|
-
? React.cloneElement(child, otherProps)
|
|
59
|
-
: child;
|
|
60
|
-
});
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
export { Link as L, LinkWrapper as a, linkAppearance as b, linkConfig as l };
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var tslib_es6 = require('./tslib.es6_cjs_CCZ3TN_7.js');
|
|
4
|
-
var jsxRuntime = require('react/jsx-runtime');
|
|
5
|
-
var clsx = require('clsx');
|
|
6
|
-
var useDevicePropsGenerator = require('./cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
7
|
-
var useStyles = require('./cjs/hooks/useStyles/useStyles.js');
|
|
8
|
-
|
|
9
|
-
var textAppearanceSize = {
|
|
10
|
-
sizeXXL: {
|
|
11
|
-
size: 'xxl',
|
|
12
|
-
labelTextSize: 'xxl',
|
|
13
|
-
},
|
|
14
|
-
sizeXL: {
|
|
15
|
-
size: 'xl',
|
|
16
|
-
labelTextSize: 'l',
|
|
17
|
-
},
|
|
18
|
-
sizeL: {
|
|
19
|
-
size: 'l',
|
|
20
|
-
labelTextSize: 'l',
|
|
21
|
-
},
|
|
22
|
-
sizeM: {
|
|
23
|
-
size: 'm',
|
|
24
|
-
labelTextSize: 'm',
|
|
25
|
-
},
|
|
26
|
-
sizeS: {
|
|
27
|
-
size: 's',
|
|
28
|
-
labelTextSize: 's',
|
|
29
|
-
},
|
|
30
|
-
sizeXS: {
|
|
31
|
-
size: 'xs',
|
|
32
|
-
labelTextSize: 'xs',
|
|
33
|
-
},
|
|
34
|
-
sizeXXS: {
|
|
35
|
-
size: 'xxs',
|
|
36
|
-
labelTextSize: 'xs',
|
|
37
|
-
},
|
|
38
|
-
};
|
|
39
|
-
|
|
40
|
-
var textAppearance = tslib_es6.__assign({}, textAppearanceSize);
|
|
41
|
-
|
|
42
|
-
var textConfig = {
|
|
43
|
-
appearance: textAppearance,
|
|
44
|
-
setAppearance: function (appearanceConfig) {
|
|
45
|
-
textConfig.appearance = appearanceConfig;
|
|
46
|
-
},
|
|
47
|
-
};
|
|
48
|
-
function Text(props) {
|
|
49
|
-
var className = props.className, type = props.type, appearance = props.appearance, cursor = props.cursor, dataTestId = props.dataTestId, dataTour = props.dataTour, htmlFor = props.htmlFor, _a = props.tag, Tag = _a === void 0 ? 'span' : _a, before = props.before, after = props.after, isSkeleton = props.isSkeleton, onClick = props.onClick, onDoubleClick = props.onDoubleClick, children = props.children;
|
|
50
|
-
var appearanceConfig = appearance === null || appearance === void 0 ? void 0 : appearance.split(' ').reduce(function (resultConfig, appearanceKey) {
|
|
51
|
-
var _a;
|
|
52
|
-
return (tslib_es6.__assign(tslib_es6.__assign({}, resultConfig), (_a = textConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
53
|
-
}, {});
|
|
54
|
-
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
55
|
-
var textAlignClass = propsGenerator.textAlignClass, textColorActiveClass = propsGenerator.textColorActiveClass, textColorClass = propsGenerator.textColorClass, textColorGradientClass = propsGenerator.textColorGradientClass, textColorHoverClass = propsGenerator.textColorHoverClass, textStyleClass = propsGenerator.textStyleClass, textTruncateClass = propsGenerator.textTruncateClass, textWeightClass = propsGenerator.textWeightClass, textWrapClass = propsGenerator.textWrapClass, cursorClass = propsGenerator.cursorClass, sizeClass = propsGenerator.sizeClass, widthClass = propsGenerator.widthClass;
|
|
56
|
-
// @ts-expect-error
|
|
57
|
-
var textStyles = useStyles.useStyles(props).styles;
|
|
58
|
-
return (jsxRuntime.jsxs(Tag, { className: clsx(className, 'text', sizeClass && "text_size_".concat(sizeClass), textWeightClass && "text-weight_".concat(textWeightClass), textAlignClass && "text-align_".concat(textAlignClass), textColorClass && "text-color_".concat(textColorClass), textColorActiveClass && "text-color_active_".concat(textColorActiveClass), textColorHoverClass && "text-color_hover_".concat(textColorHoverClass), textColorGradientClass && "text-gradient_".concat(textColorGradientClass), textStyleClass && "text-style_".concat(textStyleClass), textWrapClass && "word-wrap_".concat(textWrapClass), textTruncateClass && "text-truncate_".concat(textTruncateClass), type && "text_type_".concat(type), isSkeleton && 'text_skeleton', widthClass && "width_".concat(widthClass), cursorClass && "cursor_".concat(cursorClass), onClick && (cursor || 'cursor_type_pointer')), "data-test-id": dataTestId, "data-tour": dataTour, htmlFor: htmlFor, style: textStyles, onClick: onClick, onDoubleClick: onDoubleClick, children: [before, children, after] }));
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
exports.Text = Text;
|
|
62
|
-
exports.textAppearance = textAppearance;
|
|
63
|
-
exports.textConfig = textConfig;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { Canvas, Meta } from '@storybook/blocks'
|
|
2
|
-
|
|
3
|
-
import * as PaginationStories from '../stories/Pagination.stories.tsx'
|
|
4
|
-
|
|
5
|
-
<Meta of={PaginationStories} />
|
|
6
|
-
|
|
7
|
-
# Pagination
|
|
8
|
-
|
|
9
|
-
## Default
|
|
10
|
-
|
|
11
|
-
<Canvas sourceState="shown" of={PaginationStories.Default} />
|
package/dist/stories/Tile.mdx
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { Meta, Story } from '@storybook/blocks'
|
|
2
|
-
|
|
3
|
-
import * as TileStories from '../stories/Tile.stories.tsx'
|
|
4
|
-
|
|
5
|
-
<Meta title="Molecules / Tile" />
|
|
6
|
-
|
|
7
|
-
# Tile
|
|
8
|
-
|
|
9
|
-
`Tile` - это карточка, на которой находится вся ключевая информация, более детальная отобразится при клике на нее.
|
|
10
|
-
|
|
11
|
-
<Story of={TileStories.Normal} />
|