@alfalab/core-components-calendar-with-skeleton 6.0.1 → 6.0.3
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/Component.d.ts +1 -1
- package/Component.js.map +1 -1
- package/cssm/Component.d.ts +1 -1
- package/cssm/Component.js.map +1 -1
- package/cssm/index.module.css +1 -1
- package/esm/Component.d.ts +1 -1
- package/esm/Component.js.map +1 -1
- package/esm/index.css +12 -12
- package/esm/index.module.css.js +1 -1
- package/esm/index.module.css.js.map +1 -1
- package/index.css +12 -12
- package/index.module.css.js +1 -1
- package/index.module.css.js.map +1 -1
- package/modern/Component.d.ts +1 -1
- package/modern/Component.js.map +1 -1
- package/modern/index.css +12 -12
- package/modern/index.module.css.js +1 -1
- package/modern/index.module.css.js.map +1 -1
- package/moderncssm/Component.d.ts +1 -1
- package/moderncssm/Component.js.map +1 -1
- package/moderncssm/index.module.css +10 -1
- package/package.json +5 -5
- package/src/Component.tsx +4 -1
- package/src/index.module.css +1 -1
package/Component.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { CalendarDesktopProps } from '@alfalab/core-components-calendar/desktop';
|
|
2
|
+
import { type CalendarDesktopProps } from '@alfalab/core-components-calendar/desktop';
|
|
3
3
|
export declare type CalendarWithSkeletonProps = CalendarDesktopProps & {
|
|
4
4
|
/**
|
|
5
5
|
* Флаг включения анимации скелета
|
package/Component.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Component.js","sources":["src/Component.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport cn from 'classnames';\n\nimport {
|
|
1
|
+
{"version":3,"file":"Component.js","sources":["src/Component.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport cn from 'classnames';\n\nimport {\n CalendarDesktop,\n type CalendarDesktopProps,\n} from '@alfalab/core-components-calendar/desktop';\nimport { Skeleton } from '@alfalab/core-components-skeleton';\n\nimport styles from './index.module.css';\n\nexport type CalendarWithSkeletonProps = CalendarDesktopProps & {\n /**\n * Флаг включения анимации скелета\n */\n animate?: boolean;\n\n /**\n * Флаг управлением видимостью календаря\n */\n calendarVisible?: boolean;\n};\n\nexport const CalendarWithSkeleton = forwardRef<HTMLDivElement, CalendarWithSkeletonProps>(\n ({ calendarVisible = true, animate = true, className, ...restProps }, ref) => {\n const skeletonProps = { visible: true, animate };\n\n return (\n <div\n className={cn(styles.component, className, {\n [styles.calendarVisible]: calendarVisible,\n })}\n >\n {calendarVisible && <CalendarDesktop ref={ref} responsive={true} {...restProps} />}\n\n <CSSTransition\n in={!calendarVisible}\n timeout={200}\n unmountOnExit={true}\n classNames={styles}\n >\n <div className={styles.skeleton} ref={calendarVisible ? undefined : ref}>\n <Skeleton {...skeletonProps} className={styles.header} />\n\n <Skeleton {...skeletonProps} className={styles.weekDays} />\n\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n </div>\n </CSSTransition>\n </div>\n );\n },\n);\n\nCalendarWithSkeleton.displayName = 'CalendarWithSkeleton';\n"],"names":["forwardRef","__rest","React","cn","styles","CalendarDesktop","__assign","CSSTransition","Skeleton"],"mappings":";;;;;;;;;;;;;;;;;IAwBa,oBAAoB,GAAGA,gBAAU,CAC1C,UAAC,EAAmE,EAAE,GAAG,EAAA;;IAAtE,IAAA,EAAA,GAAA,EAAA,CAAA,eAAsB,EAAtB,eAAe,GAAA,EAAA,KAAA,MAAA,GAAG,IAAI,GAAA,EAAA,EAAE,eAAc,EAAd,OAAO,mBAAG,IAAI,GAAA,EAAA,EAAE,SAAS,GAAA,EAAA,CAAA,SAAA,EAAK,SAAS,GAAAC,YAAA,CAAA,EAAA,EAAj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CAAC,GAAG,EAAI,CAAA,CAAA;gBACtDF,sBAAC,CAAA,aAAA,CAAAM,+BAAQ,qBAAK,aAAa,EAAA,EAAE,SAAS,EAAEJ,YAAM,CAAC,GAAG,EAAI,CAAA,CAAA;gBACtDF,sBAAC,CAAA,aAAA,CAAAM,+BAAQ,qBAAK,aAAa,EAAA,EAAE,SAAS,EAAEJ,YAAM,CAAC,GAAG,EAAI,CAAA,CAAA;AACtD,gBAAAF,sBAAA,CAAA,aAAA,CAACM,+BAAQ,EAAAF,cAAA,CAAA,EAAA,EAAK,aAAa,EAAA,EAAE,SAAS,EAAEF,YAAM,CAAC,GAAG,EAAI,CAAA,CAAA,CACpD,CACM,CACd;AAEd,CAAC;AAGL,oBAAoB,CAAC,WAAW,GAAG,sBAAsB;;;;"}
|
package/cssm/Component.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { CalendarDesktopProps } from '@alfalab/core-components-calendar/cssm/desktop';
|
|
2
|
+
import { type CalendarDesktopProps } from '@alfalab/core-components-calendar/cssm/desktop';
|
|
3
3
|
export declare type CalendarWithSkeletonProps = CalendarDesktopProps & {
|
|
4
4
|
/**
|
|
5
5
|
* Флаг включения анимации скелета
|
package/cssm/Component.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Component.js","sources":["../src/Component.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport cn from 'classnames';\n\nimport {
|
|
1
|
+
{"version":3,"file":"Component.js","sources":["../src/Component.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport cn from 'classnames';\n\nimport {\n CalendarDesktop,\n type CalendarDesktopProps,\n} from '@alfalab/core-components-calendar/desktop';\nimport { Skeleton } from '@alfalab/core-components-skeleton';\n\nimport styles from './index.module.css';\n\nexport type CalendarWithSkeletonProps = CalendarDesktopProps & {\n /**\n * Флаг включения анимации скелета\n */\n animate?: boolean;\n\n /**\n * Флаг управлением видимостью календаря\n */\n calendarVisible?: boolean;\n};\n\nexport const CalendarWithSkeleton = forwardRef<HTMLDivElement, CalendarWithSkeletonProps>(\n ({ calendarVisible = true, animate = true, className, ...restProps }, ref) => {\n const skeletonProps = { visible: true, animate };\n\n return (\n <div\n className={cn(styles.component, className, {\n [styles.calendarVisible]: calendarVisible,\n })}\n >\n {calendarVisible && <CalendarDesktop ref={ref} responsive={true} {...restProps} />}\n\n <CSSTransition\n in={!calendarVisible}\n timeout={200}\n unmountOnExit={true}\n classNames={styles}\n >\n <div className={styles.skeleton} ref={calendarVisible ? undefined : ref}>\n <Skeleton {...skeletonProps} className={styles.header} />\n\n <Skeleton {...skeletonProps} className={styles.weekDays} />\n\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n </div>\n </CSSTransition>\n </div>\n );\n },\n);\n\nCalendarWithSkeleton.displayName = 'CalendarWithSkeleton';\n"],"names":["forwardRef","__rest","React","cn","styles","CalendarDesktop","__assign","CSSTransition","Skeleton"],"mappings":";;;;;;;;;;;;;;;;;;IAwBa,oBAAoB,GAAGA,gBAAU,CAC1C,UAAC,EAAmE,EAAE,GAAG,EAAA;;IAAtE,IAAA,EAAA,GAAA,EAAA,CAAA,eAAsB,EAAtB,eAAe,GAAA,EAAA,KAAA,MAAA,GAAG,IAAI,GAAA,EAAA,EAAE,eAAc,EAAd,OAAO,mBAAG,IAAI,GAAA,EAAA,EAAE,SAAS,GAAA,EAAA,CAAA,SAAA,EAAK,SAAS,GAAAC,YAAA,CAAA,EAAA,EAAjE,2CAAmE,CAAF;IAC9D,IAAM,aAAa,GAAG,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAA,OAAA,EAAE;IAEhD,QACIC,sBACI,CAAA,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M,CAAC,GAAG,EAAI,CAAA,CAAA;gBACtDF,sBAAC,CAAA,aAAA,CAAAM,aAAQ,qBAAK,aAAa,EAAA,EAAE,SAAS,EAAEJ,uBAAM,CAAC,GAAG,EAAI,CAAA,CAAA;AACtD,gBAAAF,sBAAA,CAAA,aAAA,CAACM,aAAQ,EAAAF,cAAA,CAAA,EAAA,EAAK,aAAa,EAAA,EAAE,SAAS,EAAEF,uBAAM,CAAC,GAAG,EAAI,CAAA,CAAA,CACpD,CACM,CACd;AAEd,CAAC;AAGL,oBAAoB,CAAC,WAAW,GAAG,sBAAsB;;;;"}
|
package/cssm/index.module.css
CHANGED
package/esm/Component.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { CalendarDesktopProps } from '@alfalab/core-components-calendar/esm/desktop';
|
|
2
|
+
import { type CalendarDesktopProps } from '@alfalab/core-components-calendar/esm/desktop';
|
|
3
3
|
export declare type CalendarWithSkeletonProps = CalendarDesktopProps & {
|
|
4
4
|
/**
|
|
5
5
|
* Флаг включения анимации скелета
|
package/esm/Component.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Component.js","sources":["../src/Component.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport cn from 'classnames';\n\nimport {
|
|
1
|
+
{"version":3,"file":"Component.js","sources":["../src/Component.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport cn from 'classnames';\n\nimport {\n CalendarDesktop,\n type CalendarDesktopProps,\n} from '@alfalab/core-components-calendar/desktop';\nimport { Skeleton } from '@alfalab/core-components-skeleton';\n\nimport styles from './index.module.css';\n\nexport type CalendarWithSkeletonProps = CalendarDesktopProps & {\n /**\n * Флаг включения анимации скелета\n */\n animate?: boolean;\n\n /**\n * Флаг управлением видимостью календаря\n */\n calendarVisible?: boolean;\n};\n\nexport const CalendarWithSkeleton = forwardRef<HTMLDivElement, CalendarWithSkeletonProps>(\n ({ calendarVisible = true, animate = true, className, ...restProps }, ref) => {\n const skeletonProps = { visible: true, animate };\n\n return (\n <div\n className={cn(styles.component, className, {\n [styles.calendarVisible]: calendarVisible,\n })}\n >\n {calendarVisible && <CalendarDesktop ref={ref} responsive={true} {...restProps} />}\n\n <CSSTransition\n in={!calendarVisible}\n timeout={200}\n unmountOnExit={true}\n classNames={styles}\n >\n <div className={styles.skeleton} ref={calendarVisible ? undefined : ref}>\n <Skeleton {...skeletonProps} className={styles.header} />\n\n <Skeleton {...skeletonProps} className={styles.weekDays} />\n\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n </div>\n </CSSTransition>\n </div>\n );\n },\n);\n\nCalendarWithSkeleton.displayName = 'CalendarWithSkeleton';\n"],"names":[],"mappings":";;;;;;;;IAwBa,oBAAoB,GAAG,UAAU,CAC1C,UAAC,EAAmE,EAAE,GAAG,EAAA;;IAAtE,IAAA,EAAA,GAAA,EAAA,CAAA,eAAsB,EAAtB,eAAe,GAAA,EAAA,KAAA,MAAA,GAAG,IAAI,GAAA,EAAA,EAAE,eAAc,EAAd,OAAO,mBAAG,IAAI,GAAA,EAAA,EAAE,SAAS,GAAA,EAAA,CAAA,SAAA,EAAK,SAAS,GAAA,MAAA,CAAA,EAAA,EAAjE,2CAAmE,CAAF;IAC9D,IAAM,aAAa,GAAG,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAA,OAAA,EAAE;IAEhD,QACI,KACI,CAAA,aAAA,CAAA,KAAA,EAAA,EAAA,SAAS,EAAE,EAAE,CAAC,MAAM,CAAC,SAAS,EAAE,SAAS,GAAA,EAAA,GAAA,EAAA;AACrC,YAAA,EAAA,CAAC,MAAM,CAAC,eAAe,CAAA,GAAG,eAAe;AA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,SAAS,EAAE,MAAM,CAAC,GAAG,EAAI,CAAA,CAAA,CACpD,CACM,CACd;AAEd,CAAC;AAGL,oBAAoB,CAAC,WAAW,GAAG,sBAAsB;;;;"}
|
package/esm/index.css
CHANGED
|
@@ -9,13 +9,13 @@
|
|
|
9
9
|
} :root {
|
|
10
10
|
--calendar-height: 344px;
|
|
11
11
|
--calendar-width: 344px;
|
|
12
|
-
} .calendar-with-
|
|
12
|
+
} .calendar-with-skeleton__component_nr1na {
|
|
13
13
|
width: var(--calendar-width);
|
|
14
14
|
height: var(--calendar-height);
|
|
15
15
|
position: relative;
|
|
16
|
-
} .calendar-with-
|
|
16
|
+
} .calendar-with-skeleton__calendarVisible_nr1na {
|
|
17
17
|
height: auto;
|
|
18
|
-
} .calendar-with-
|
|
18
|
+
} .calendar-with-skeleton__skeleton_nr1na {
|
|
19
19
|
display: flex;
|
|
20
20
|
flex-direction: column;
|
|
21
21
|
padding: var(--gap-16);
|
|
@@ -29,20 +29,20 @@
|
|
|
29
29
|
height: 100%;
|
|
30
30
|
background-color: var(--color-light-modal-bg-primary);
|
|
31
31
|
background-clip: content-box;
|
|
32
|
-
} .calendar-with-
|
|
32
|
+
} .calendar-with-skeleton__header_nr1na {
|
|
33
33
|
height: 48px;
|
|
34
34
|
margin-bottom: var(--gap-20);
|
|
35
|
-
} .calendar-with-
|
|
35
|
+
} .calendar-with-skeleton__weekDays_nr1na {
|
|
36
36
|
height: 12px;
|
|
37
37
|
margin-bottom: var(--gap-16);
|
|
38
|
-
} .calendar-with-
|
|
39
|
-
height: 32px
|
|
40
|
-
} .calendar-with-
|
|
38
|
+
} .calendar-with-skeleton__row_nr1na {
|
|
39
|
+
height: 32px;
|
|
40
|
+
} .calendar-with-skeleton__row_nr1na + .calendar-with-skeleton__row_nr1na {
|
|
41
41
|
margin-top: 10px;
|
|
42
|
-
} .calendar-with-
|
|
43
|
-
.calendar-with-
|
|
44
|
-
.calendar-with-
|
|
42
|
+
} .calendar-with-skeleton__enter_nr1na,
|
|
43
|
+
.calendar-with-skeleton__enterActive_nr1na,
|
|
44
|
+
.calendar-with-skeleton__exit_nr1na {
|
|
45
45
|
opacity: 1;
|
|
46
|
-
} .calendar-with-
|
|
46
|
+
} .calendar-with-skeleton__exitActive_nr1na {
|
|
47
47
|
opacity: 0;
|
|
48
48
|
}
|
package/esm/index.module.css.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import './index.css';
|
|
2
2
|
|
|
3
|
-
var styles = {"component":"calendar-with-
|
|
3
|
+
var styles = {"component":"calendar-with-skeleton__component_nr1na","calendarVisible":"calendar-with-skeleton__calendarVisible_nr1na","skeleton":"calendar-with-skeleton__skeleton_nr1na","header":"calendar-with-skeleton__header_nr1na","weekDays":"calendar-with-skeleton__weekDays_nr1na","row":"calendar-with-skeleton__row_nr1na","enter":"calendar-with-skeleton__enter_nr1na","enterActive":"calendar-with-skeleton__enterActive_nr1na","exit":"calendar-with-skeleton__exit_nr1na","exitActive":"calendar-with-skeleton__exitActive_nr1na"};
|
|
4
4
|
|
|
5
5
|
export { styles as default };
|
|
6
6
|
//# sourceMappingURL=index.module.css.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/index.css';\n@import '../../calendar/src/vars.css';\n\n.component {\n width: var(--calendar-width);\n height: var(--calendar-height);\n position: relative;\n}\n\n.calendarVisible {\n height: auto;\n}\n\n.skeleton {\n display: flex;\n flex-direction: column;\n padding: var(--gap-16);\n pointer-events: all;\n box-sizing: border-box;\n position: absolute;\n transition: 0.2s ease;\n left: var(--gap-0);\n top: var(--gap-0);\n width: 100%;\n height: 100%;\n background-color: var(--color-light-modal-bg-primary);\n background-clip: content-box;\n}\n\n.header {\n height: 48px;\n margin-bottom: var(--gap-20);\n}\n\n.weekDays {\n height: 12px;\n margin-bottom: var(--gap-16);\n}\n\n.row {\n height: 32px;\n\n & + .row {\n margin-top: 10px;\n }\n}\n\n.enter,\n.enterActive,\n.exit {\n opacity: 1;\n}\n\n.exitActive {\n opacity: 0;\n}\n"],"names":[],"mappings":";;AAEgB,aAAe,CAAC,WAAW,CAAC,yCAAyC,CAAC,iBAAiB,CAAC,+CAA+C,CAAC,UAAU,CAAC,wCAAwC,CAAC,QAAQ,CAAC,sCAAsC,CAAC,UAAU,CAAC,wCAAwC,CAAC,KAAK,CAAC,mCAAmC,CAAC,OAAO,CAAC,qCAAqC,CAAC,aAAa,CAAC,2CAA2C,CAAC,MAAM,CAAC,oCAAoC,CAAC,YAAY,CAAC,0CAA0C,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/no-typography-index.css';\n@import '../../calendar/src/vars.css';\n\n.component {\n width: var(--calendar-width);\n height: var(--calendar-height);\n position: relative;\n}\n\n.calendarVisible {\n height: auto;\n}\n\n.skeleton {\n display: flex;\n flex-direction: column;\n padding: var(--gap-16);\n pointer-events: all;\n box-sizing: border-box;\n position: absolute;\n transition: 0.2s ease;\n left: var(--gap-0);\n top: var(--gap-0);\n width: 100%;\n height: 100%;\n background-color: var(--color-light-modal-bg-primary);\n background-clip: content-box;\n}\n\n.header {\n height: 48px;\n margin-bottom: var(--gap-20);\n}\n\n.weekDays {\n height: 12px;\n margin-bottom: var(--gap-16);\n}\n\n.row {\n height: 32px;\n\n & + .row {\n margin-top: 10px;\n }\n}\n\n.enter,\n.enterActive,\n.exit {\n opacity: 1;\n}\n\n.exitActive {\n opacity: 0;\n}\n"],"names":[],"mappings":";;AAEgB,aAAe,CAAC,WAAW,CAAC,yCAAyC,CAAC,iBAAiB,CAAC,+CAA+C,CAAC,UAAU,CAAC,wCAAwC,CAAC,QAAQ,CAAC,sCAAsC,CAAC,UAAU,CAAC,wCAAwC,CAAC,KAAK,CAAC,mCAAmC,CAAC,OAAO,CAAC,qCAAqC,CAAC,aAAa,CAAC,2CAA2C,CAAC,MAAM,CAAC,oCAAoC,CAAC,YAAY,CAAC,0CAA0C,CAAC;;;;"}
|
package/index.css
CHANGED
|
@@ -9,13 +9,13 @@
|
|
|
9
9
|
} :root {
|
|
10
10
|
--calendar-height: 344px;
|
|
11
11
|
--calendar-width: 344px;
|
|
12
|
-
} .calendar-with-
|
|
12
|
+
} .calendar-with-skeleton__component_nr1na {
|
|
13
13
|
width: var(--calendar-width);
|
|
14
14
|
height: var(--calendar-height);
|
|
15
15
|
position: relative;
|
|
16
|
-
} .calendar-with-
|
|
16
|
+
} .calendar-with-skeleton__calendarVisible_nr1na {
|
|
17
17
|
height: auto;
|
|
18
|
-
} .calendar-with-
|
|
18
|
+
} .calendar-with-skeleton__skeleton_nr1na {
|
|
19
19
|
display: flex;
|
|
20
20
|
flex-direction: column;
|
|
21
21
|
padding: var(--gap-16);
|
|
@@ -29,20 +29,20 @@
|
|
|
29
29
|
height: 100%;
|
|
30
30
|
background-color: var(--color-light-modal-bg-primary);
|
|
31
31
|
background-clip: content-box;
|
|
32
|
-
} .calendar-with-
|
|
32
|
+
} .calendar-with-skeleton__header_nr1na {
|
|
33
33
|
height: 48px;
|
|
34
34
|
margin-bottom: var(--gap-20);
|
|
35
|
-
} .calendar-with-
|
|
35
|
+
} .calendar-with-skeleton__weekDays_nr1na {
|
|
36
36
|
height: 12px;
|
|
37
37
|
margin-bottom: var(--gap-16);
|
|
38
|
-
} .calendar-with-
|
|
39
|
-
height: 32px
|
|
40
|
-
} .calendar-with-
|
|
38
|
+
} .calendar-with-skeleton__row_nr1na {
|
|
39
|
+
height: 32px;
|
|
40
|
+
} .calendar-with-skeleton__row_nr1na + .calendar-with-skeleton__row_nr1na {
|
|
41
41
|
margin-top: 10px;
|
|
42
|
-
} .calendar-with-
|
|
43
|
-
.calendar-with-
|
|
44
|
-
.calendar-with-
|
|
42
|
+
} .calendar-with-skeleton__enter_nr1na,
|
|
43
|
+
.calendar-with-skeleton__enterActive_nr1na,
|
|
44
|
+
.calendar-with-skeleton__exit_nr1na {
|
|
45
45
|
opacity: 1;
|
|
46
|
-
} .calendar-with-
|
|
46
|
+
} .calendar-with-skeleton__exitActive_nr1na {
|
|
47
47
|
opacity: 0;
|
|
48
48
|
}
|
package/index.module.css.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
require('./index.css');
|
|
4
4
|
|
|
5
|
-
var styles = {"component":"calendar-with-
|
|
5
|
+
var styles = {"component":"calendar-with-skeleton__component_nr1na","calendarVisible":"calendar-with-skeleton__calendarVisible_nr1na","skeleton":"calendar-with-skeleton__skeleton_nr1na","header":"calendar-with-skeleton__header_nr1na","weekDays":"calendar-with-skeleton__weekDays_nr1na","row":"calendar-with-skeleton__row_nr1na","enter":"calendar-with-skeleton__enter_nr1na","enterActive":"calendar-with-skeleton__enterActive_nr1na","exit":"calendar-with-skeleton__exit_nr1na","exitActive":"calendar-with-skeleton__exitActive_nr1na"};
|
|
6
6
|
|
|
7
7
|
module.exports = styles;
|
|
8
8
|
//# sourceMappingURL=index.module.css.js.map
|
package/index.module.css.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/index.css';\n@import '../../calendar/src/vars.css';\n\n.component {\n width: var(--calendar-width);\n height: var(--calendar-height);\n position: relative;\n}\n\n.calendarVisible {\n height: auto;\n}\n\n.skeleton {\n display: flex;\n flex-direction: column;\n padding: var(--gap-16);\n pointer-events: all;\n box-sizing: border-box;\n position: absolute;\n transition: 0.2s ease;\n left: var(--gap-0);\n top: var(--gap-0);\n width: 100%;\n height: 100%;\n background-color: var(--color-light-modal-bg-primary);\n background-clip: content-box;\n}\n\n.header {\n height: 48px;\n margin-bottom: var(--gap-20);\n}\n\n.weekDays {\n height: 12px;\n margin-bottom: var(--gap-16);\n}\n\n.row {\n height: 32px;\n\n & + .row {\n margin-top: 10px;\n }\n}\n\n.enter,\n.enterActive,\n.exit {\n opacity: 1;\n}\n\n.exitActive {\n opacity: 0;\n}\n"],"names":[],"mappings":";;;;AAEgB,aAAe,CAAC,WAAW,CAAC,yCAAyC,CAAC,iBAAiB,CAAC,+CAA+C,CAAC,UAAU,CAAC,wCAAwC,CAAC,QAAQ,CAAC,sCAAsC,CAAC,UAAU,CAAC,wCAAwC,CAAC,KAAK,CAAC,mCAAmC,CAAC,OAAO,CAAC,qCAAqC,CAAC,aAAa,CAAC,2CAA2C,CAAC,MAAM,CAAC,oCAAoC,CAAC,YAAY,CAAC,0CAA0C,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/no-typography-index.css';\n@import '../../calendar/src/vars.css';\n\n.component {\n width: var(--calendar-width);\n height: var(--calendar-height);\n position: relative;\n}\n\n.calendarVisible {\n height: auto;\n}\n\n.skeleton {\n display: flex;\n flex-direction: column;\n padding: var(--gap-16);\n pointer-events: all;\n box-sizing: border-box;\n position: absolute;\n transition: 0.2s ease;\n left: var(--gap-0);\n top: var(--gap-0);\n width: 100%;\n height: 100%;\n background-color: var(--color-light-modal-bg-primary);\n background-clip: content-box;\n}\n\n.header {\n height: 48px;\n margin-bottom: var(--gap-20);\n}\n\n.weekDays {\n height: 12px;\n margin-bottom: var(--gap-16);\n}\n\n.row {\n height: 32px;\n\n & + .row {\n margin-top: 10px;\n }\n}\n\n.enter,\n.enterActive,\n.exit {\n opacity: 1;\n}\n\n.exitActive {\n opacity: 0;\n}\n"],"names":[],"mappings":";;;;AAEgB,aAAe,CAAC,WAAW,CAAC,yCAAyC,CAAC,iBAAiB,CAAC,+CAA+C,CAAC,UAAU,CAAC,wCAAwC,CAAC,QAAQ,CAAC,sCAAsC,CAAC,UAAU,CAAC,wCAAwC,CAAC,KAAK,CAAC,mCAAmC,CAAC,OAAO,CAAC,qCAAqC,CAAC,aAAa,CAAC,2CAA2C,CAAC,MAAM,CAAC,oCAAoC,CAAC,YAAY,CAAC,0CAA0C,CAAC;;;;"}
|
package/modern/Component.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { CalendarDesktopProps } from '@alfalab/core-components-calendar/modern/desktop';
|
|
2
|
+
import { type CalendarDesktopProps } from '@alfalab/core-components-calendar/modern/desktop';
|
|
3
3
|
export declare type CalendarWithSkeletonProps = CalendarDesktopProps & {
|
|
4
4
|
/**
|
|
5
5
|
* Флаг включения анимации скелета
|
package/modern/Component.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Component.js","sources":["../src/Component.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport cn from 'classnames';\n\nimport {
|
|
1
|
+
{"version":3,"file":"Component.js","sources":["../src/Component.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport cn from 'classnames';\n\nimport {\n CalendarDesktop,\n type CalendarDesktopProps,\n} from '@alfalab/core-components-calendar/desktop';\nimport { Skeleton } from '@alfalab/core-components-skeleton';\n\nimport styles from './index.module.css';\n\nexport type CalendarWithSkeletonProps = CalendarDesktopProps & {\n /**\n * Флаг включения анимации скелета\n */\n animate?: boolean;\n\n /**\n * Флаг управлением видимостью календаря\n */\n calendarVisible?: boolean;\n};\n\nexport const CalendarWithSkeleton = forwardRef<HTMLDivElement, CalendarWithSkeletonProps>(\n ({ calendarVisible = true, animate = true, className, ...restProps }, ref) => {\n const skeletonProps = { visible: true, animate };\n\n return (\n <div\n className={cn(styles.component, className, {\n [styles.calendarVisible]: calendarVisible,\n })}\n >\n {calendarVisible && <CalendarDesktop ref={ref} responsive={true} {...restProps} />}\n\n <CSSTransition\n in={!calendarVisible}\n timeout={200}\n unmountOnExit={true}\n classNames={styles}\n >\n <div className={styles.skeleton} ref={calendarVisible ? undefined : ref}>\n <Skeleton {...skeletonProps} className={styles.header} />\n\n <Skeleton {...skeletonProps} className={styles.weekDays} />\n\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n </div>\n </CSSTransition>\n </div>\n );\n },\n);\n\nCalendarWithSkeleton.displayName = 'CalendarWithSkeleton';\n"],"names":[],"mappings":";;;;;;;AAwBa,MAAA,oBAAoB,GAAG,UAAU,CAC1C,CAAC,EAAE,eAAe,GAAG,IAAI,EAAE,OAAO,GAAG,IAAI,EAAE,SAAS,EAAE,GAAG,SAAS,EAAE,EAAE,GAAG,KAAI;IACzE,MAAM,aAAa,GAAG,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE;IAEhD,QACI,KACI,CAAA,aAAA,CAAA,KAAA,EAAA,EAAA,SAAS,EAAE,EAAE,CAAC,MAAM,CAAC,SAAS,EAAE,SAAS,EAAE;AACvC,YAAA,CAAC,MAAM,CAAC,eAAe,GAAG,eAAe;SAC5C,CAAC,EAAA;AAED,QAAA,eAAe,IAAI,KAAA,CAAA,aAAA,CAAC,eAAe,EAAA,EAAC,GAAG,EAAE,GAAG,EAAE,UAAU,EAAE,IAAI,EAAA,GAAM,SAAS,EAAI,CAAA;AAElF,QAAA,KAAA,CAAA,aAAA,CAAC,aAAa,EACV,EAAA,EAAE,EAAE,CAAC,eAAe,EACpB,OAAO,EAAE,GAAG,EACZ,aAAa,EAAE,IAAI,EACnB,UAAU,EAAE,MAAM,EAAA;AAElB,YAAA,KAAA,CAAA,aAAA,CAAA,KAAA,EAAA,EAAK,SAAS,EAAE,MAAM,CAAC,QAAQ,EAAE,GAAG,EAAE,eAAe,GAAG,SAAS,GAAG,GAAG,EAAA;gBACnE,KAAC,CAAA,aAAA,CAAA,QAAQ,OAAK,aAAa,EAAE,SAAS,EAAE,MAAM,CAAC,MAAM,EAAI,CAAA;gBAEzD,KAAC,CAAA,aAAA,CAAA,QAAQ,OAAK,aAAa,EAAE,SAAS,EAAE,MAAM,CAAC,QAAQ,EAAI,CAAA;gBAE3D,KAAC,CAAA,aAAA,CAAA,QAAQ,OAAK,aAAa,EAAE,SAAS,EAAE,MAAM,CAAC,GAAG,EAAI,CAAA;gBACtD,KAAC,CAAA,aAAA,CAAA,QAAQ,OAAK,aAAa,EAAE,SAAS,EAAE,MAAM,CAAC,GAAG,EAAI,CAAA;gBACtD,KAAC,CAAA,aAAA,CAAA,QAAQ,OAAK,aAAa,EAAE,SAAS,EAAE,MAAM,CAAC,GAAG,EAAI,CAAA;gBACtD,KAAC,CAAA,aAAA,CAAA,QAAQ,OAAK,aAAa,EAAE,SAAS,EAAE,MAAM,CAAC,GAAG,EAAI,CAAA;AACtD,gBAAA,KAAA,CAAA,aAAA,CAAC,QAAQ,EAAA,EAAA,GAAK,aAAa,EAAE,SAAS,EAAE,MAAM,CAAC,GAAG,EAAI,CAAA,CACpD,CACM,CACd;AAEd,CAAC;AAGL,oBAAoB,CAAC,WAAW,GAAG,sBAAsB;;;;"}
|
package/modern/index.css
CHANGED
|
@@ -9,13 +9,13 @@
|
|
|
9
9
|
} :root {
|
|
10
10
|
--calendar-height: 344px;
|
|
11
11
|
--calendar-width: 344px;
|
|
12
|
-
} .calendar-with-
|
|
12
|
+
} .calendar-with-skeleton__component_nr1na {
|
|
13
13
|
width: var(--calendar-width);
|
|
14
14
|
height: var(--calendar-height);
|
|
15
15
|
position: relative;
|
|
16
|
-
} .calendar-with-
|
|
16
|
+
} .calendar-with-skeleton__calendarVisible_nr1na {
|
|
17
17
|
height: auto;
|
|
18
|
-
} .calendar-with-
|
|
18
|
+
} .calendar-with-skeleton__skeleton_nr1na {
|
|
19
19
|
display: flex;
|
|
20
20
|
flex-direction: column;
|
|
21
21
|
padding: var(--gap-16);
|
|
@@ -29,20 +29,20 @@
|
|
|
29
29
|
height: 100%;
|
|
30
30
|
background-color: var(--color-light-modal-bg-primary);
|
|
31
31
|
background-clip: content-box;
|
|
32
|
-
} .calendar-with-
|
|
32
|
+
} .calendar-with-skeleton__header_nr1na {
|
|
33
33
|
height: 48px;
|
|
34
34
|
margin-bottom: var(--gap-20);
|
|
35
|
-
} .calendar-with-
|
|
35
|
+
} .calendar-with-skeleton__weekDays_nr1na {
|
|
36
36
|
height: 12px;
|
|
37
37
|
margin-bottom: var(--gap-16);
|
|
38
|
-
} .calendar-with-
|
|
39
|
-
height: 32px
|
|
40
|
-
} .calendar-with-
|
|
38
|
+
} .calendar-with-skeleton__row_nr1na {
|
|
39
|
+
height: 32px;
|
|
40
|
+
} .calendar-with-skeleton__row_nr1na + .calendar-with-skeleton__row_nr1na {
|
|
41
41
|
margin-top: 10px;
|
|
42
|
-
} .calendar-with-
|
|
43
|
-
.calendar-with-
|
|
44
|
-
.calendar-with-
|
|
42
|
+
} .calendar-with-skeleton__enter_nr1na,
|
|
43
|
+
.calendar-with-skeleton__enterActive_nr1na,
|
|
44
|
+
.calendar-with-skeleton__exit_nr1na {
|
|
45
45
|
opacity: 1;
|
|
46
|
-
} .calendar-with-
|
|
46
|
+
} .calendar-with-skeleton__exitActive_nr1na {
|
|
47
47
|
opacity: 0;
|
|
48
48
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import './index.css';
|
|
2
2
|
|
|
3
|
-
const styles = {"component":"calendar-with-
|
|
3
|
+
const styles = {"component":"calendar-with-skeleton__component_nr1na","calendarVisible":"calendar-with-skeleton__calendarVisible_nr1na","skeleton":"calendar-with-skeleton__skeleton_nr1na","header":"calendar-with-skeleton__header_nr1na","weekDays":"calendar-with-skeleton__weekDays_nr1na","row":"calendar-with-skeleton__row_nr1na","enter":"calendar-with-skeleton__enter_nr1na","enterActive":"calendar-with-skeleton__enterActive_nr1na","exit":"calendar-with-skeleton__exit_nr1na","exitActive":"calendar-with-skeleton__exitActive_nr1na"};
|
|
4
4
|
|
|
5
5
|
export { styles as default };
|
|
6
6
|
//# sourceMappingURL=index.module.css.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/index.css';\n@import '../../calendar/src/vars.css';\n\n.component {\n width: var(--calendar-width);\n height: var(--calendar-height);\n position: relative;\n}\n\n.calendarVisible {\n height: auto;\n}\n\n.skeleton {\n display: flex;\n flex-direction: column;\n padding: var(--gap-16);\n pointer-events: all;\n box-sizing: border-box;\n position: absolute;\n transition: 0.2s ease;\n left: var(--gap-0);\n top: var(--gap-0);\n width: 100%;\n height: 100%;\n background-color: var(--color-light-modal-bg-primary);\n background-clip: content-box;\n}\n\n.header {\n height: 48px;\n margin-bottom: var(--gap-20);\n}\n\n.weekDays {\n height: 12px;\n margin-bottom: var(--gap-16);\n}\n\n.row {\n height: 32px;\n\n & + .row {\n margin-top: 10px;\n }\n}\n\n.enter,\n.enterActive,\n.exit {\n opacity: 1;\n}\n\n.exitActive {\n opacity: 0;\n}\n"],"names":[],"mappings":";;AAEgB,eAAe,CAAC,WAAW,CAAC,yCAAyC,CAAC,iBAAiB,CAAC,+CAA+C,CAAC,UAAU,CAAC,wCAAwC,CAAC,QAAQ,CAAC,sCAAsC,CAAC,UAAU,CAAC,wCAAwC,CAAC,KAAK,CAAC,mCAAmC,CAAC,OAAO,CAAC,qCAAqC,CAAC,aAAa,CAAC,2CAA2C,CAAC,MAAM,CAAC,oCAAoC,CAAC,YAAY,CAAC,0CAA0C,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"index.module.css.js","sources":["src/index.module.css"],"sourcesContent":["@import '@alfalab/core-components-vars/src/no-typography-index.css';\n@import '../../calendar/src/vars.css';\n\n.component {\n width: var(--calendar-width);\n height: var(--calendar-height);\n position: relative;\n}\n\n.calendarVisible {\n height: auto;\n}\n\n.skeleton {\n display: flex;\n flex-direction: column;\n padding: var(--gap-16);\n pointer-events: all;\n box-sizing: border-box;\n position: absolute;\n transition: 0.2s ease;\n left: var(--gap-0);\n top: var(--gap-0);\n width: 100%;\n height: 100%;\n background-color: var(--color-light-modal-bg-primary);\n background-clip: content-box;\n}\n\n.header {\n height: 48px;\n margin-bottom: var(--gap-20);\n}\n\n.weekDays {\n height: 12px;\n margin-bottom: var(--gap-16);\n}\n\n.row {\n height: 32px;\n\n & + .row {\n margin-top: 10px;\n }\n}\n\n.enter,\n.enterActive,\n.exit {\n opacity: 1;\n}\n\n.exitActive {\n opacity: 0;\n}\n"],"names":[],"mappings":";;AAEgB,eAAe,CAAC,WAAW,CAAC,yCAAyC,CAAC,iBAAiB,CAAC,+CAA+C,CAAC,UAAU,CAAC,wCAAwC,CAAC,QAAQ,CAAC,sCAAsC,CAAC,UAAU,CAAC,wCAAwC,CAAC,KAAK,CAAC,mCAAmC,CAAC,OAAO,CAAC,qCAAqC,CAAC,aAAa,CAAC,2CAA2C,CAAC,MAAM,CAAC,oCAAoC,CAAC,YAAY,CAAC,0CAA0C,CAAC;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { CalendarDesktopProps } from '@alfalab/core-components-calendar/moderncssm/desktop';
|
|
2
|
+
import { type CalendarDesktopProps } from '@alfalab/core-components-calendar/moderncssm/desktop';
|
|
3
3
|
export declare type CalendarWithSkeletonProps = CalendarDesktopProps & {
|
|
4
4
|
/**
|
|
5
5
|
* Флаг включения анимации скелета
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Component.js","sources":["../src/Component.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport cn from 'classnames';\n\nimport {
|
|
1
|
+
{"version":3,"file":"Component.js","sources":["../src/Component.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { CSSTransition } from 'react-transition-group';\nimport cn from 'classnames';\n\nimport {\n CalendarDesktop,\n type CalendarDesktopProps,\n} from '@alfalab/core-components-calendar/desktop';\nimport { Skeleton } from '@alfalab/core-components-skeleton';\n\nimport styles from './index.module.css';\n\nexport type CalendarWithSkeletonProps = CalendarDesktopProps & {\n /**\n * Флаг включения анимации скелета\n */\n animate?: boolean;\n\n /**\n * Флаг управлением видимостью календаря\n */\n calendarVisible?: boolean;\n};\n\nexport const CalendarWithSkeleton = forwardRef<HTMLDivElement, CalendarWithSkeletonProps>(\n ({ calendarVisible = true, animate = true, className, ...restProps }, ref) => {\n const skeletonProps = { visible: true, animate };\n\n return (\n <div\n className={cn(styles.component, className, {\n [styles.calendarVisible]: calendarVisible,\n })}\n >\n {calendarVisible && <CalendarDesktop ref={ref} responsive={true} {...restProps} />}\n\n <CSSTransition\n in={!calendarVisible}\n timeout={200}\n unmountOnExit={true}\n classNames={styles}\n >\n <div className={styles.skeleton} ref={calendarVisible ? undefined : ref}>\n <Skeleton {...skeletonProps} className={styles.header} />\n\n <Skeleton {...skeletonProps} className={styles.weekDays} />\n\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n <Skeleton {...skeletonProps} className={styles.row} />\n </div>\n </CSSTransition>\n </div>\n );\n },\n);\n\nCalendarWithSkeleton.displayName = 'CalendarWithSkeleton';\n"],"names":[],"mappings":";;;;;;;AAwBa,MAAA,oBAAoB,GAAG,UAAU,CAC1C,CAAC,EAAE,eAAe,GAAG,IAAI,EAAE,OAAO,GAAG,IAAI,EAAE,SAAS,EAAE,GAAG,SAAS,EAAE,EAAE,GAAG,KAAI;IACzE,MAAM,aAAa,GAAG,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE;IAEhD,QACI,KACI,CAAA,aAAA,CAAA,KAAA,EAAA,EAAA,SAAS,EAAE,EAAE,CAAC,MAAM,CAAC,SAAS,EAAE,SAAS,EAAE;AACvC,YAAA,CAAC,MAAM,CAAC,eAAe,GAAG,eAAe;SAC5C,CAAC,EAAA;AAED,QAAA,eAAe,IAAI,KAAA,CAAA,aAAA,CA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|
3
3
|
--calendar-width: 344px;
|
|
4
4
|
}
|
|
5
|
+
|
|
5
6
|
.component {
|
|
6
7
|
width: var(--calendar-width);
|
|
7
8
|
height: var(--calendar-height);
|
|
8
9
|
position: relative;
|
|
9
10
|
}
|
|
11
|
+
|
|
10
12
|
.calendarVisible {
|
|
11
13
|
height: auto;
|
|
12
14
|
}
|
|
15
|
+
|
|
13
16
|
.skeleton {
|
|
14
17
|
display: flex;
|
|
15
18
|
flex-direction: column;
|
|
@@ -25,25 +28,31 @@
|
|
|
25
28
|
background-color: var(--color-light-modal-bg-primary);
|
|
26
29
|
background-clip: content-box;
|
|
27
30
|
}
|
|
31
|
+
|
|
28
32
|
.header {
|
|
29
33
|
height: 48px;
|
|
30
34
|
margin-bottom: var(--gap-20);
|
|
31
35
|
}
|
|
36
|
+
|
|
32
37
|
.weekDays {
|
|
33
38
|
height: 12px;
|
|
34
39
|
margin-bottom: var(--gap-16);
|
|
35
40
|
}
|
|
41
|
+
|
|
36
42
|
.row {
|
|
37
|
-
height: 32px
|
|
43
|
+
height: 32px;
|
|
38
44
|
}
|
|
45
|
+
|
|
39
46
|
.row + .row {
|
|
40
47
|
margin-top: 10px;
|
|
41
48
|
}
|
|
49
|
+
|
|
42
50
|
.enter,
|
|
43
51
|
.enterActive,
|
|
44
52
|
.exit {
|
|
45
53
|
opacity: 1;
|
|
46
54
|
}
|
|
55
|
+
|
|
47
56
|
.exitActive {
|
|
48
57
|
opacity: 0;
|
|
49
58
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alfalab/core-components-calendar-with-skeleton",
|
|
3
|
-
"version": "6.0.
|
|
3
|
+
"version": "6.0.3",
|
|
4
4
|
"description": "CalendarWithSkeleton component",
|
|
5
5
|
"keywords": [],
|
|
6
6
|
"license": "MIT",
|
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
"main": "index.js",
|
|
11
11
|
"module": "./esm/index.js",
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@alfalab/core-components-calendar": "^8.0.
|
|
14
|
-
"@alfalab/core-components-skeleton": "^6.0.
|
|
13
|
+
"@alfalab/core-components-calendar": "^8.0.3",
|
|
14
|
+
"@alfalab/core-components-skeleton": "^6.0.1",
|
|
15
15
|
"classnames": "^2.5.1",
|
|
16
16
|
"react-transition-group": "^4.4.5",
|
|
17
17
|
"tslib": "^2.4.0"
|
|
@@ -24,6 +24,6 @@
|
|
|
24
24
|
"access": "public",
|
|
25
25
|
"directory": "dist"
|
|
26
26
|
},
|
|
27
|
-
"themesVersion": "14.1.
|
|
28
|
-
"varsVersion": "10.1.
|
|
27
|
+
"themesVersion": "14.1.3",
|
|
28
|
+
"varsVersion": "10.1.1"
|
|
29
29
|
}
|
package/src/Component.tsx
CHANGED
|
@@ -2,7 +2,10 @@ import React, { forwardRef } from 'react';
|
|
|
2
2
|
import { CSSTransition } from 'react-transition-group';
|
|
3
3
|
import cn from 'classnames';
|
|
4
4
|
|
|
5
|
-
import {
|
|
5
|
+
import {
|
|
6
|
+
CalendarDesktop,
|
|
7
|
+
type CalendarDesktopProps,
|
|
8
|
+
} from '@alfalab/core-components-calendar/desktop';
|
|
6
9
|
import { Skeleton } from '@alfalab/core-components-skeleton';
|
|
7
10
|
|
|
8
11
|
import styles from './index.module.css';
|
package/src/index.module.css
CHANGED