@selfcommunity/react-ui 0.7.0-alpha.346 → 0.7.0-alpha.347
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/lib/cjs/components/Categories/Categories.js +10 -11
- package/lib/cjs/components/Categories/Skeleton.d.ts +3 -3
- package/lib/cjs/components/Categories/Skeleton.js +9 -10
- package/lib/cjs/components/Categories/constants.d.ts +1 -0
- package/lib/cjs/components/Categories/constants.js +4 -0
- package/lib/cjs/components/CategoriesPopularWidget/CategoriesPopularWidget.js +12 -14
- package/lib/cjs/components/CategoriesPopularWidget/Skeleton.d.ts +2 -2
- package/lib/cjs/components/CategoriesPopularWidget/Skeleton.js +7 -10
- package/lib/cjs/components/CategoriesPopularWidget/constants.d.ts +1 -0
- package/lib/cjs/components/CategoriesPopularWidget/constants.js +4 -0
- package/lib/cjs/components/CategoriesSuggestionWidget/CategoriesSuggestionWidget.js +13 -15
- package/lib/cjs/components/CategoriesSuggestionWidget/Skeleton.d.ts +3 -3
- package/lib/cjs/components/CategoriesSuggestionWidget/Skeleton.js +9 -12
- package/lib/cjs/components/CategoriesSuggestionWidget/constants.d.ts +1 -0
- package/lib/cjs/components/CategoriesSuggestionWidget/constants.js +4 -0
- package/lib/cjs/components/Category/Category.js +9 -10
- package/lib/cjs/components/Category/Skeleton.d.ts +2 -2
- package/lib/cjs/components/Category/Skeleton.js +12 -13
- package/lib/cjs/components/Category/constants.d.ts +1 -0
- package/lib/cjs/components/Category/constants.js +4 -0
- package/lib/esm/components/Categories/Categories.js +3 -4
- package/lib/esm/components/Categories/Skeleton.d.ts +3 -3
- package/lib/esm/components/Categories/Skeleton.js +7 -8
- package/lib/esm/components/Categories/constants.d.ts +1 -0
- package/lib/esm/components/Categories/constants.js +1 -0
- package/lib/esm/components/CategoriesPopularWidget/CategoriesPopularWidget.js +3 -5
- package/lib/esm/components/CategoriesPopularWidget/Skeleton.d.ts +2 -2
- package/lib/esm/components/CategoriesPopularWidget/Skeleton.js +6 -9
- package/lib/esm/components/CategoriesPopularWidget/constants.d.ts +1 -0
- package/lib/esm/components/CategoriesPopularWidget/constants.js +1 -0
- package/lib/esm/components/CategoriesSuggestionWidget/CategoriesSuggestionWidget.js +4 -6
- package/lib/esm/components/CategoriesSuggestionWidget/Skeleton.d.ts +3 -3
- package/lib/esm/components/CategoriesSuggestionWidget/Skeleton.js +7 -10
- package/lib/esm/components/CategoriesSuggestionWidget/constants.d.ts +1 -0
- package/lib/esm/components/CategoriesSuggestionWidget/constants.js +1 -0
- package/lib/esm/components/Category/Category.js +3 -4
- package/lib/esm/components/Category/Skeleton.d.ts +2 -2
- package/lib/esm/components/Category/Skeleton.js +6 -7
- package/lib/esm/components/Category/constants.d.ts +1 -0
- package/lib/esm/components/Category/constants.js +1 -0
- package/lib/umd/react-ui.js +1 -1
- package/package.json +2 -2
|
@@ -14,19 +14,18 @@ const system_1 = require("@mui/system");
|
|
|
14
14
|
const Errors_1 = require("../../constants/Errors");
|
|
15
15
|
const utils_1 = require("@selfcommunity/utils");
|
|
16
16
|
const HiddenPlaceholder_1 = tslib_1.__importDefault(require("../../shared/HiddenPlaceholder"));
|
|
17
|
-
const
|
|
17
|
+
const constants_1 = require("./constants");
|
|
18
18
|
const classes = {
|
|
19
|
-
root: `${PREFIX}-root`,
|
|
20
|
-
filters: `${PREFIX}-filter`,
|
|
21
|
-
categories: `${PREFIX}-categories`,
|
|
22
|
-
category: `${PREFIX}-category`,
|
|
23
|
-
noResults: `${PREFIX}-no-results`
|
|
19
|
+
root: `${constants_1.PREFIX}-root`,
|
|
20
|
+
filters: `${constants_1.PREFIX}-filter`,
|
|
21
|
+
categories: `${constants_1.PREFIX}-categories`,
|
|
22
|
+
category: `${constants_1.PREFIX}-category`,
|
|
23
|
+
noResults: `${constants_1.PREFIX}-no-results`
|
|
24
24
|
};
|
|
25
25
|
const Root = (0, styles_1.styled)(material_1.Box, {
|
|
26
|
-
name: PREFIX,
|
|
27
|
-
slot: 'Root'
|
|
28
|
-
|
|
29
|
-
})(({ theme }) => ({}));
|
|
26
|
+
name: constants_1.PREFIX,
|
|
27
|
+
slot: 'Root'
|
|
28
|
+
})(() => ({}));
|
|
30
29
|
/**
|
|
31
30
|
* > API documentation for the Community-JS Categories component. Learn about the available props and the CSS API.
|
|
32
31
|
*
|
|
@@ -57,7 +56,7 @@ function Categories(inProps) {
|
|
|
57
56
|
// PROPS
|
|
58
57
|
const props = (0, system_1.useThemeProps)({
|
|
59
58
|
props: inProps,
|
|
60
|
-
name: PREFIX
|
|
59
|
+
name: constants_1.PREFIX
|
|
61
60
|
});
|
|
62
61
|
const { className, CategoryComponent = Category_1.default, CategoryComponentProps = { variant: 'outlined', ButtonBaseProps: { disableRipple: true, component: material_1.Box } }, CategoriesSkeletonComponent = Skeleton_1.default, CategoriesSkeletonProps = {}, showFilters = true, filters, handleFilterCategories, prefetchedCategories = [] } = props, rest = tslib_1.__rest(props, ["className", "CategoryComponent", "CategoryComponentProps", "CategoriesSkeletonComponent", "CategoriesSkeletonProps", "showFilters", "filters", "handleFilterCategories", "prefetchedCategories"]);
|
|
63
62
|
// STATE
|
|
@@ -21,14 +21,14 @@ export interface CategoriesSkeletonProps {
|
|
|
21
21
|
|
|
22
22
|
#### Component Name
|
|
23
23
|
|
|
24
|
-
The name `
|
|
24
|
+
The name `SCCategories-skeleton-root` can be used when providing style overrides in the theme.
|
|
25
25
|
|
|
26
26
|
#### CSS
|
|
27
27
|
|
|
28
28
|
|Rule Name|Global class|Description|
|
|
29
29
|
|---|---|---|
|
|
30
|
-
|root|.
|
|
31
|
-
|categories|.
|
|
30
|
+
|root|.SCCategories-skeleton-root|Styles applied to the root element.|
|
|
31
|
+
|categories|.SCCategories-categories|Styles applied to the categories' element.|
|
|
32
32
|
*
|
|
33
33
|
*/
|
|
34
34
|
export default function CategoriesSkeleton(inProps: CategoriesSkeletonProps): JSX.Element;
|
|
@@ -6,16 +6,15 @@ const styles_1 = require("@mui/material/styles");
|
|
|
6
6
|
const material_1 = require("@mui/material");
|
|
7
7
|
const Skeleton_1 = tslib_1.__importDefault(require("../Category/Skeleton"));
|
|
8
8
|
const classnames_1 = tslib_1.__importDefault(require("classnames"));
|
|
9
|
-
const
|
|
9
|
+
const constants_1 = require("./constants");
|
|
10
10
|
const classes = {
|
|
11
|
-
root: `${PREFIX}-root`,
|
|
12
|
-
categories: `${PREFIX}-categories`
|
|
11
|
+
root: `${constants_1.PREFIX}-skeleton-root`,
|
|
12
|
+
categories: `${constants_1.PREFIX}-categories`
|
|
13
13
|
};
|
|
14
14
|
const Root = (0, styles_1.styled)(material_1.Box, {
|
|
15
|
-
name: PREFIX,
|
|
16
|
-
slot: '
|
|
17
|
-
|
|
18
|
-
})(({ theme }) => ({}));
|
|
15
|
+
name: constants_1.PREFIX,
|
|
16
|
+
slot: 'SkeletonRoot'
|
|
17
|
+
})(() => ({}));
|
|
19
18
|
/**
|
|
20
19
|
* > API documentation for the Community-JS Categories Skeleton component. Learn about the available props and the CSS API.
|
|
21
20
|
|
|
@@ -27,14 +26,14 @@ const Root = (0, styles_1.styled)(material_1.Box, {
|
|
|
27
26
|
|
|
28
27
|
#### Component Name
|
|
29
28
|
|
|
30
|
-
The name `
|
|
29
|
+
The name `SCCategories-skeleton-root` can be used when providing style overrides in the theme.
|
|
31
30
|
|
|
32
31
|
#### CSS
|
|
33
32
|
|
|
34
33
|
|Rule Name|Global class|Description|
|
|
35
34
|
|---|---|---|
|
|
36
|
-
|root|.
|
|
37
|
-
|categories|.
|
|
35
|
+
|root|.SCCategories-skeleton-root|Styles applied to the root element.|
|
|
36
|
+
|categories|.SCCategories-categories|Styles applied to the categories' element.|
|
|
38
37
|
*
|
|
39
38
|
*/
|
|
40
39
|
function CategoriesSkeleton(inProps) {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const PREFIX = "SCCategories";
|
|
@@ -18,24 +18,22 @@ const system_1 = require("@mui/system");
|
|
|
18
18
|
const HiddenPlaceholder_1 = tslib_1.__importDefault(require("../../shared/HiddenPlaceholder"));
|
|
19
19
|
const react_core_1 = require("@selfcommunity/react-core");
|
|
20
20
|
const widget_1 = require("../../utils/widget");
|
|
21
|
-
const
|
|
21
|
+
const constants_1 = require("./constants");
|
|
22
22
|
const classes = {
|
|
23
|
-
root: `${PREFIX}-root`,
|
|
24
|
-
title: `${PREFIX}-title`,
|
|
25
|
-
noResults: `${PREFIX}-no-results`,
|
|
26
|
-
showMore: `${PREFIX}-show-more`,
|
|
27
|
-
dialogRoot: `${PREFIX}-dialog-root`,
|
|
28
|
-
endMessage: `${PREFIX}-end-message`
|
|
23
|
+
root: `${constants_1.PREFIX}-root`,
|
|
24
|
+
title: `${constants_1.PREFIX}-title`,
|
|
25
|
+
noResults: `${constants_1.PREFIX}-no-results`,
|
|
26
|
+
showMore: `${constants_1.PREFIX}-show-more`,
|
|
27
|
+
dialogRoot: `${constants_1.PREFIX}-dialog-root`,
|
|
28
|
+
endMessage: `${constants_1.PREFIX}-end-message`
|
|
29
29
|
};
|
|
30
30
|
const Root = (0, styles_1.styled)(Widget_1.default, {
|
|
31
|
-
name: PREFIX,
|
|
32
|
-
slot: 'Root'
|
|
33
|
-
overridesResolver: (props, styles) => styles.root
|
|
31
|
+
name: constants_1.PREFIX,
|
|
32
|
+
slot: 'Root'
|
|
34
33
|
})(() => ({}));
|
|
35
34
|
const DialogRoot = (0, styles_1.styled)(BaseDialog_1.default, {
|
|
36
|
-
name: PREFIX,
|
|
37
|
-
slot: '
|
|
38
|
-
overridesResolver: (props, styles) => styles.dialogRoot
|
|
35
|
+
name: constants_1.PREFIX,
|
|
36
|
+
slot: 'DialogRoot'
|
|
39
37
|
})(() => ({}));
|
|
40
38
|
/**
|
|
41
39
|
* > API documentation for the Community-JS Categories Popular widget component. Learn about the available props and the CSS API.
|
|
@@ -69,7 +67,7 @@ function CategoriesPopularWidget(inProps) {
|
|
|
69
67
|
// PROPS
|
|
70
68
|
const props = (0, system_1.useThemeProps)({
|
|
71
69
|
props: inProps,
|
|
72
|
-
name: PREFIX
|
|
70
|
+
name: constants_1.PREFIX
|
|
73
71
|
});
|
|
74
72
|
const { autoHide = true, limit = 3, className, CategoryProps = {}, cacheStrategy = utils_1.CacheStrategies.CACHE_FIRST, onHeightChange, onStateChange, DialogProps = {}, categoryId } = props, // Removed from root DOM
|
|
75
73
|
rest = tslib_1.__rest(props, ["autoHide", "limit", "className", "CategoryProps", "cacheStrategy", "onHeightChange", "onStateChange", "DialogProps", "categoryId"]);
|
|
@@ -9,13 +9,13 @@
|
|
|
9
9
|
|
|
10
10
|
#### Component Name
|
|
11
11
|
|
|
12
|
-
The name `
|
|
12
|
+
The name `SCCategoriesPopularWidget-skeleton-root` can be used when providing style overrides in the theme.
|
|
13
13
|
|
|
14
14
|
#### CSS
|
|
15
15
|
|
|
16
16
|
|Rule Name|Global class|Description|
|
|
17
17
|
|---|---|---|
|
|
18
|
-
|root|.
|
|
18
|
+
|root|.SCCategoriesPopularWidget-skeleton-root|Styles applied to the root element.|
|
|
19
19
|
*
|
|
20
20
|
*/
|
|
21
21
|
export default function CategoriesPopularSkeleton(props: any): JSX.Element;
|
|
@@ -4,17 +4,14 @@ const tslib_1 = require("tslib");
|
|
|
4
4
|
const react_1 = tslib_1.__importDefault(require("react"));
|
|
5
5
|
const Skeleton_1 = tslib_1.__importDefault(require("../CategoriesSuggestionWidget/Skeleton"));
|
|
6
6
|
const styles_1 = require("@mui/material/styles");
|
|
7
|
-
const
|
|
7
|
+
const constants_1 = require("./constants");
|
|
8
8
|
const classes = {
|
|
9
|
-
root: `${PREFIX}-root`
|
|
9
|
+
root: `${constants_1.PREFIX}-skeleton-root`
|
|
10
10
|
};
|
|
11
11
|
const Root = (0, styles_1.styled)(Skeleton_1.default, {
|
|
12
|
-
name: PREFIX,
|
|
13
|
-
slot: '
|
|
14
|
-
|
|
15
|
-
})(({ theme }) => ({
|
|
16
|
-
marginBottom: theme.spacing(2)
|
|
17
|
-
}));
|
|
12
|
+
name: constants_1.PREFIX,
|
|
13
|
+
slot: 'SkeletonRoot'
|
|
14
|
+
})(() => ({}));
|
|
18
15
|
/**
|
|
19
16
|
* > API documentation for the Community-JS Categories Popular Skeleton component. Learn about the available props and the CSS API.
|
|
20
17
|
|
|
@@ -26,13 +23,13 @@ const Root = (0, styles_1.styled)(Skeleton_1.default, {
|
|
|
26
23
|
|
|
27
24
|
#### Component Name
|
|
28
25
|
|
|
29
|
-
The name `
|
|
26
|
+
The name `SCCategoriesPopularWidget-skeleton-root` can be used when providing style overrides in the theme.
|
|
30
27
|
|
|
31
28
|
#### CSS
|
|
32
29
|
|
|
33
30
|
|Rule Name|Global class|Description|
|
|
34
31
|
|---|---|---|
|
|
35
|
-
|root|.
|
|
32
|
+
|root|.SCCategoriesPopularWidget-skeleton-root|Styles applied to the root element.|
|
|
36
33
|
*
|
|
37
34
|
*/
|
|
38
35
|
function CategoriesPopularSkeleton(props) {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const PREFIX = "SCCategoriesPopularWidget";
|
|
@@ -18,24 +18,22 @@ const widget_1 = require("../../utils/widget");
|
|
|
18
18
|
const BaseDialog_1 = tslib_1.__importDefault(require("../../shared/BaseDialog"));
|
|
19
19
|
const Errors_1 = require("../../constants/Errors");
|
|
20
20
|
const InfiniteScroll_1 = tslib_1.__importDefault(require("../../shared/InfiniteScroll"));
|
|
21
|
-
const
|
|
21
|
+
const constants_1 = require("./constants");
|
|
22
22
|
const classes = {
|
|
23
|
-
root: `${PREFIX}-root`,
|
|
24
|
-
title: `${PREFIX}-title`,
|
|
25
|
-
noResults: `${PREFIX}-no-results`,
|
|
26
|
-
showMore: `${PREFIX}-show-more`,
|
|
27
|
-
dialogRoot: `${PREFIX}-dialog-root`,
|
|
28
|
-
endMessage: `${PREFIX}-end-message`
|
|
23
|
+
root: `${constants_1.PREFIX}-root`,
|
|
24
|
+
title: `${constants_1.PREFIX}-title`,
|
|
25
|
+
noResults: `${constants_1.PREFIX}-no-results`,
|
|
26
|
+
showMore: `${constants_1.PREFIX}-show-more`,
|
|
27
|
+
dialogRoot: `${constants_1.PREFIX}-dialog-root`,
|
|
28
|
+
endMessage: `${constants_1.PREFIX}-end-message`
|
|
29
29
|
};
|
|
30
30
|
const Root = (0, styles_1.styled)(Widget_1.default, {
|
|
31
|
-
name: PREFIX,
|
|
32
|
-
slot: 'Root'
|
|
33
|
-
|
|
34
|
-
})(({ theme }) => ({}));
|
|
31
|
+
name: constants_1.PREFIX,
|
|
32
|
+
slot: 'Root'
|
|
33
|
+
})(() => ({}));
|
|
35
34
|
const DialogRoot = (0, styles_1.styled)(BaseDialog_1.default, {
|
|
36
|
-
name: PREFIX,
|
|
37
|
-
slot: '
|
|
38
|
-
overridesResolver: (props, styles) => styles.dialogRoot
|
|
35
|
+
name: constants_1.PREFIX,
|
|
36
|
+
slot: 'DialogRoot'
|
|
39
37
|
})(() => ({}));
|
|
40
38
|
/**
|
|
41
39
|
* > API documentation for the Community-JS Categories Suggestion component. Learn about the available props and the CSS API.
|
|
@@ -68,7 +66,7 @@ function CategoriesSuggestionWidget(inProps) {
|
|
|
68
66
|
// PROPS
|
|
69
67
|
const props = (0, system_1.useThemeProps)({
|
|
70
68
|
props: inProps,
|
|
71
|
-
name: PREFIX
|
|
69
|
+
name: constants_1.PREFIX
|
|
72
70
|
});
|
|
73
71
|
const { autoHide = true, limit = 3, className, CategoryProps = {}, cacheStrategy = utils_1.CacheStrategies.NETWORK_ONLY, onHeightChange, onStateChange, DialogProps = {}, categoryId } = props, // Removed from root DOM
|
|
74
72
|
rest = tslib_1.__rest(props, ["autoHide", "limit", "className", "CategoryProps", "cacheStrategy", "onHeightChange", "onStateChange", "DialogProps", "categoryId"]);
|
|
@@ -9,14 +9,14 @@
|
|
|
9
9
|
|
|
10
10
|
#### Component Name
|
|
11
11
|
|
|
12
|
-
The name `
|
|
12
|
+
The name `SCCategoriesSuggestionWidget-skeleton-root` can be used when providing style overrides in the theme.
|
|
13
13
|
|
|
14
14
|
#### CSS
|
|
15
15
|
|
|
16
16
|
|Rule Name|Global class|Description|
|
|
17
17
|
|---|---|---|
|
|
18
|
-
|root|.
|
|
19
|
-
|list|.
|
|
18
|
+
|root|.SCCategoriesSuggestionWidget-skeleton-root|Styles applied to the root element.|
|
|
19
|
+
|list|.SCCategoriesSuggestionWidget-list|Styles applied to the list element.|
|
|
20
20
|
*
|
|
21
21
|
*/
|
|
22
22
|
export default function CategoriesSuggestionWidgetSkeleton(props: any): JSX.Element;
|
|
@@ -7,18 +7,15 @@ const styles_1 = require("@mui/material/styles");
|
|
|
7
7
|
const Skeleton_1 = tslib_1.__importDefault(require("../Category/Skeleton"));
|
|
8
8
|
const Widget_1 = tslib_1.__importDefault(require("../Widget"));
|
|
9
9
|
const material_1 = require("@mui/material");
|
|
10
|
-
const
|
|
10
|
+
const constants_1 = require("./constants");
|
|
11
11
|
const classes = {
|
|
12
|
-
root: `${PREFIX}-root`,
|
|
13
|
-
list: `${PREFIX}-list`
|
|
12
|
+
root: `${constants_1.PREFIX}-skeleton-root`,
|
|
13
|
+
list: `${constants_1.PREFIX}-list`
|
|
14
14
|
};
|
|
15
15
|
const Root = (0, styles_1.styled)(Widget_1.default, {
|
|
16
|
-
name: PREFIX,
|
|
17
|
-
slot: '
|
|
18
|
-
|
|
19
|
-
})(({ theme }) => ({
|
|
20
|
-
marginBottom: theme.spacing(2)
|
|
21
|
-
}));
|
|
16
|
+
name: constants_1.PREFIX,
|
|
17
|
+
slot: 'SkeletonRoot'
|
|
18
|
+
})(() => ({}));
|
|
22
19
|
/**
|
|
23
20
|
* > API documentation for the Community-JS Categories Suggestion Widget Skeleton component. Learn about the available props and the CSS API.
|
|
24
21
|
|
|
@@ -30,14 +27,14 @@ const Root = (0, styles_1.styled)(Widget_1.default, {
|
|
|
30
27
|
|
|
31
28
|
#### Component Name
|
|
32
29
|
|
|
33
|
-
The name `
|
|
30
|
+
The name `SCCategoriesSuggestionWidget-skeleton-root` can be used when providing style overrides in the theme.
|
|
34
31
|
|
|
35
32
|
#### CSS
|
|
36
33
|
|
|
37
34
|
|Rule Name|Global class|Description|
|
|
38
35
|
|---|---|---|
|
|
39
|
-
|root|.
|
|
40
|
-
|list|.
|
|
36
|
+
|root|.SCCategoriesSuggestionWidget-skeleton-root|Styles applied to the root element.|
|
|
37
|
+
|list|.SCCategoriesSuggestionWidget-list|Styles applied to the list element.|
|
|
41
38
|
*
|
|
42
39
|
*/
|
|
43
40
|
function CategoriesSuggestionWidgetSkeleton(props) {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const PREFIX = "SCCategoriesSuggestionWidget";
|
|
@@ -11,24 +11,23 @@ const react_intl_1 = require("react-intl");
|
|
|
11
11
|
const classnames_1 = tslib_1.__importDefault(require("classnames"));
|
|
12
12
|
const system_1 = require("@mui/system");
|
|
13
13
|
const BaseItemButton_1 = tslib_1.__importDefault(require("../../shared/BaseItemButton"));
|
|
14
|
+
const constants_1 = require("./constants");
|
|
14
15
|
const messages = (0, react_intl_1.defineMessages)({
|
|
15
16
|
categoryFollowers: {
|
|
16
17
|
id: 'ui.category.categoryFollowers',
|
|
17
18
|
defaultMessage: 'ui.category.categoryFollowers'
|
|
18
19
|
}
|
|
19
20
|
});
|
|
20
|
-
const PREFIX = 'SCCategory';
|
|
21
21
|
const classes = {
|
|
22
|
-
root: `${PREFIX}-root`,
|
|
23
|
-
categoryImage: `${PREFIX}-category-image`,
|
|
24
|
-
title: `${PREFIX}-title`,
|
|
25
|
-
actions: `${PREFIX}-actions`
|
|
22
|
+
root: `${constants_1.PREFIX}-root`,
|
|
23
|
+
categoryImage: `${constants_1.PREFIX}-category-image`,
|
|
24
|
+
title: `${constants_1.PREFIX}-title`,
|
|
25
|
+
actions: `${constants_1.PREFIX}-actions`
|
|
26
26
|
};
|
|
27
27
|
const Root = (0, styles_1.styled)(BaseItemButton_1.default, {
|
|
28
|
-
name: PREFIX,
|
|
29
|
-
slot: 'Root'
|
|
30
|
-
|
|
31
|
-
})(({ theme }) => ({}));
|
|
28
|
+
name: constants_1.PREFIX,
|
|
29
|
+
slot: 'Root'
|
|
30
|
+
})(() => ({}));
|
|
32
31
|
/**
|
|
33
32
|
* > API documentation for the Community-JS Category component. Learn about the available props and the CSS API.
|
|
34
33
|
*
|
|
@@ -58,7 +57,7 @@ function Category(inProps) {
|
|
|
58
57
|
// PROPS
|
|
59
58
|
const props = (0, system_1.useThemeProps)({
|
|
60
59
|
props: inProps,
|
|
61
|
-
name: PREFIX
|
|
60
|
+
name: constants_1.PREFIX
|
|
62
61
|
});
|
|
63
62
|
const { categoryId = null, category = null, className = null, elevation, autoHide = false, categoryFollowButtonProps = {}, showFollowers = true, ButtonBaseProps = null } = props, rest = tslib_1.__rest(props, ["categoryId", "category", "className", "elevation", "autoHide", "categoryFollowButtonProps", "showFollowers", "ButtonBaseProps"]);
|
|
64
63
|
// CONTEXT
|
|
@@ -9,13 +9,13 @@
|
|
|
9
9
|
|
|
10
10
|
#### Component Name
|
|
11
11
|
|
|
12
|
-
The name `
|
|
12
|
+
The name `SCCategory-skeleton-root` can be used when providing style overrides in the theme.
|
|
13
13
|
|
|
14
14
|
#### CSS
|
|
15
15
|
|
|
16
16
|
|Rule Name|Global class|Description|
|
|
17
17
|
|---|---|---|
|
|
18
|
-
|root|.
|
|
18
|
+
|root|.SCCategory-skeleton-root|Styles applied to the root element.|
|
|
19
19
|
*
|
|
20
20
|
*/
|
|
21
21
|
export default function CategorySkeleton(props: any): JSX.Element;
|
|
@@ -6,20 +6,19 @@ const styles_1 = require("@mui/material/styles");
|
|
|
6
6
|
const Skeleton_1 = tslib_1.__importDefault(require("@mui/material/Skeleton"));
|
|
7
7
|
const material_1 = require("@mui/material");
|
|
8
8
|
const BaseItem_1 = tslib_1.__importDefault(require("../../shared/BaseItem"));
|
|
9
|
-
const
|
|
9
|
+
const constants_1 = require("./constants");
|
|
10
10
|
const classes = {
|
|
11
|
-
root: `${PREFIX}-root`,
|
|
12
|
-
image: `${PREFIX}-image`,
|
|
13
|
-
primary: `${PREFIX}-primary`,
|
|
14
|
-
secondary: `${PREFIX}-secondary`,
|
|
15
|
-
button: `${PREFIX}-button`,
|
|
16
|
-
action: `${PREFIX}-action`
|
|
11
|
+
root: `${constants_1.PREFIX}-skeleton-root`,
|
|
12
|
+
image: `${constants_1.PREFIX}-image`,
|
|
13
|
+
primary: `${constants_1.PREFIX}-primary`,
|
|
14
|
+
secondary: `${constants_1.PREFIX}-secondary`,
|
|
15
|
+
button: `${constants_1.PREFIX}-button`,
|
|
16
|
+
action: `${constants_1.PREFIX}-action`
|
|
17
17
|
};
|
|
18
18
|
const Root = (0, styles_1.styled)(BaseItem_1.default, {
|
|
19
|
-
name: PREFIX,
|
|
20
|
-
slot: '
|
|
21
|
-
|
|
22
|
-
})(({ theme }) => ({}));
|
|
19
|
+
name: constants_1.PREFIX,
|
|
20
|
+
slot: 'SkeletonRoot'
|
|
21
|
+
})(() => ({}));
|
|
23
22
|
/**
|
|
24
23
|
* > API documentation for the Community-JS Category Skeleton component. Learn about the available props and the CSS API.
|
|
25
24
|
|
|
@@ -31,13 +30,13 @@ const Root = (0, styles_1.styled)(BaseItem_1.default, {
|
|
|
31
30
|
|
|
32
31
|
#### Component Name
|
|
33
32
|
|
|
34
|
-
The name `
|
|
33
|
+
The name `SCCategory-skeleton-root` can be used when providing style overrides in the theme.
|
|
35
34
|
|
|
36
35
|
#### CSS
|
|
37
36
|
|
|
38
37
|
|Rule Name|Global class|Description|
|
|
39
38
|
|---|---|---|
|
|
40
|
-
|root|.
|
|
39
|
+
|root|.SCCategory-skeleton-root|Styles applied to the root element.|
|
|
41
40
|
*
|
|
42
41
|
*/
|
|
43
42
|
function CategorySkeleton(props) {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const PREFIX = "SCCategory";
|
|
@@ -12,7 +12,7 @@ import { useThemeProps } from '@mui/system';
|
|
|
12
12
|
import { SCOPE_SC_UI } from '../../constants/Errors';
|
|
13
13
|
import { Logger } from '@selfcommunity/utils';
|
|
14
14
|
import HiddenPlaceholder from '../../shared/HiddenPlaceholder';
|
|
15
|
-
|
|
15
|
+
import { PREFIX } from './constants';
|
|
16
16
|
const classes = {
|
|
17
17
|
root: `${PREFIX}-root`,
|
|
18
18
|
filters: `${PREFIX}-filter`,
|
|
@@ -22,9 +22,8 @@ const classes = {
|
|
|
22
22
|
};
|
|
23
23
|
const Root = styled(Box, {
|
|
24
24
|
name: PREFIX,
|
|
25
|
-
slot: 'Root'
|
|
26
|
-
|
|
27
|
-
})(({ theme }) => ({}));
|
|
25
|
+
slot: 'Root'
|
|
26
|
+
})(() => ({}));
|
|
28
27
|
/**
|
|
29
28
|
* > API documentation for the Community-JS Categories component. Learn about the available props and the CSS API.
|
|
30
29
|
*
|
|
@@ -21,14 +21,14 @@ export interface CategoriesSkeletonProps {
|
|
|
21
21
|
|
|
22
22
|
#### Component Name
|
|
23
23
|
|
|
24
|
-
The name `
|
|
24
|
+
The name `SCCategories-skeleton-root` can be used when providing style overrides in the theme.
|
|
25
25
|
|
|
26
26
|
#### CSS
|
|
27
27
|
|
|
28
28
|
|Rule Name|Global class|Description|
|
|
29
29
|
|---|---|---|
|
|
30
|
-
|root|.
|
|
31
|
-
|categories|.
|
|
30
|
+
|root|.SCCategories-skeleton-root|Styles applied to the root element.|
|
|
31
|
+
|categories|.SCCategories-categories|Styles applied to the categories' element.|
|
|
32
32
|
*
|
|
33
33
|
*/
|
|
34
34
|
export default function CategoriesSkeleton(inProps: CategoriesSkeletonProps): JSX.Element;
|
|
@@ -4,16 +4,15 @@ import { styled } from '@mui/material/styles';
|
|
|
4
4
|
import { Box, Grid } from '@mui/material';
|
|
5
5
|
import CategorySkeleton from '../Category/Skeleton';
|
|
6
6
|
import classNames from 'classnames';
|
|
7
|
-
|
|
7
|
+
import { PREFIX } from './constants';
|
|
8
8
|
const classes = {
|
|
9
|
-
root: `${PREFIX}-root`,
|
|
9
|
+
root: `${PREFIX}-skeleton-root`,
|
|
10
10
|
categories: `${PREFIX}-categories`
|
|
11
11
|
};
|
|
12
12
|
const Root = styled(Box, {
|
|
13
13
|
name: PREFIX,
|
|
14
|
-
slot: '
|
|
15
|
-
|
|
16
|
-
})(({ theme }) => ({}));
|
|
14
|
+
slot: 'SkeletonRoot'
|
|
15
|
+
})(() => ({}));
|
|
17
16
|
/**
|
|
18
17
|
* > API documentation for the Community-JS Categories Skeleton component. Learn about the available props and the CSS API.
|
|
19
18
|
|
|
@@ -25,14 +24,14 @@ const Root = styled(Box, {
|
|
|
25
24
|
|
|
26
25
|
#### Component Name
|
|
27
26
|
|
|
28
|
-
The name `
|
|
27
|
+
The name `SCCategories-skeleton-root` can be used when providing style overrides in the theme.
|
|
29
28
|
|
|
30
29
|
#### CSS
|
|
31
30
|
|
|
32
31
|
|Rule Name|Global class|Description|
|
|
33
32
|
|---|---|---|
|
|
34
|
-
|root|.
|
|
35
|
-
|categories|.
|
|
33
|
+
|root|.SCCategories-skeleton-root|Styles applied to the root element.|
|
|
34
|
+
|categories|.SCCategories-categories|Styles applied to the categories' element.|
|
|
36
35
|
*
|
|
37
36
|
*/
|
|
38
37
|
export default function CategoriesSkeleton(inProps) {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const PREFIX = "SCCategories";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const PREFIX = 'SCCategories';
|
|
@@ -16,7 +16,7 @@ import { useThemeProps } from '@mui/system';
|
|
|
16
16
|
import HiddenPlaceholder from '../../shared/HiddenPlaceholder';
|
|
17
17
|
import { SCCache, SCPreferences, SCPreferencesContext, SCUserContext } from '@selfcommunity/react-core';
|
|
18
18
|
import { actionWidgetTypes, dataWidgetReducer, stateWidgetInitializer } from '../../utils/widget';
|
|
19
|
-
|
|
19
|
+
import { PREFIX } from './constants';
|
|
20
20
|
const classes = {
|
|
21
21
|
root: `${PREFIX}-root`,
|
|
22
22
|
title: `${PREFIX}-title`,
|
|
@@ -27,13 +27,11 @@ const classes = {
|
|
|
27
27
|
};
|
|
28
28
|
const Root = styled(Widget, {
|
|
29
29
|
name: PREFIX,
|
|
30
|
-
slot: 'Root'
|
|
31
|
-
overridesResolver: (props, styles) => styles.root
|
|
30
|
+
slot: 'Root'
|
|
32
31
|
})(() => ({}));
|
|
33
32
|
const DialogRoot = styled(BaseDialog, {
|
|
34
33
|
name: PREFIX,
|
|
35
|
-
slot: '
|
|
36
|
-
overridesResolver: (props, styles) => styles.dialogRoot
|
|
34
|
+
slot: 'DialogRoot'
|
|
37
35
|
})(() => ({}));
|
|
38
36
|
/**
|
|
39
37
|
* > API documentation for the Community-JS Categories Popular widget component. Learn about the available props and the CSS API.
|
|
@@ -9,13 +9,13 @@
|
|
|
9
9
|
|
|
10
10
|
#### Component Name
|
|
11
11
|
|
|
12
|
-
The name `
|
|
12
|
+
The name `SCCategoriesPopularWidget-skeleton-root` can be used when providing style overrides in the theme.
|
|
13
13
|
|
|
14
14
|
#### CSS
|
|
15
15
|
|
|
16
16
|
|Rule Name|Global class|Description|
|
|
17
17
|
|---|---|---|
|
|
18
|
-
|root|.
|
|
18
|
+
|root|.SCCategoriesPopularWidget-skeleton-root|Styles applied to the root element.|
|
|
19
19
|
*
|
|
20
20
|
*/
|
|
21
21
|
export default function CategoriesPopularSkeleton(props: any): JSX.Element;
|
|
@@ -1,17 +1,14 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import CategoriesSuggestionWidgetSkeleton from '../CategoriesSuggestionWidget/Skeleton';
|
|
3
3
|
import { styled } from '@mui/material/styles';
|
|
4
|
-
|
|
4
|
+
import { PREFIX } from './constants';
|
|
5
5
|
const classes = {
|
|
6
|
-
root: `${PREFIX}-root`
|
|
6
|
+
root: `${PREFIX}-skeleton-root`
|
|
7
7
|
};
|
|
8
8
|
const Root = styled(CategoriesSuggestionWidgetSkeleton, {
|
|
9
9
|
name: PREFIX,
|
|
10
|
-
slot: '
|
|
11
|
-
|
|
12
|
-
})(({ theme }) => ({
|
|
13
|
-
marginBottom: theme.spacing(2)
|
|
14
|
-
}));
|
|
10
|
+
slot: 'SkeletonRoot'
|
|
11
|
+
})(() => ({}));
|
|
15
12
|
/**
|
|
16
13
|
* > API documentation for the Community-JS Categories Popular Skeleton component. Learn about the available props and the CSS API.
|
|
17
14
|
|
|
@@ -23,13 +20,13 @@ const Root = styled(CategoriesSuggestionWidgetSkeleton, {
|
|
|
23
20
|
|
|
24
21
|
#### Component Name
|
|
25
22
|
|
|
26
|
-
The name `
|
|
23
|
+
The name `SCCategoriesPopularWidget-skeleton-root` can be used when providing style overrides in the theme.
|
|
27
24
|
|
|
28
25
|
#### CSS
|
|
29
26
|
|
|
30
27
|
|Rule Name|Global class|Description|
|
|
31
28
|
|---|---|---|
|
|
32
|
-
|root|.
|
|
29
|
+
|root|.SCCategoriesPopularWidget-skeleton-root|Styles applied to the root element.|
|
|
33
30
|
*
|
|
34
31
|
*/
|
|
35
32
|
export default function CategoriesPopularSkeleton(props) {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const PREFIX = "SCCategoriesPopularWidget";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const PREFIX = 'SCCategoriesPopularWidget';
|