@saasquatch/mint-components 1.15.0-17 → 1.15.0-19
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/cjs/{ShadowViewAddon-974f6839.js → ShadowViewAddon-d958d324.js} +1 -1
- package/dist/cjs/{global-19fe8600.js → global-f06aabc0.js} +70 -2
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/mint-components.cjs.js +2 -2
- package/dist/cjs/sqm-banking-info-form_17.cjs.entry.js +2 -2
- package/dist/cjs/sqm-big-stat_41.cjs.entry.js +12 -3
- package/dist/cjs/sqm-email-verification.cjs.entry.js +1 -1
- package/dist/cjs/sqm-empty_4.cjs.entry.js +1 -1
- package/dist/cjs/{sqm-invoice-table-view-55066ec6.js → sqm-invoice-table-view-431faed1.js} +1 -1
- package/dist/cjs/sqm-leaderboard-rank.cjs.entry.js +1 -1
- package/dist/cjs/{sqm-navigation-sidebar-item-view-6f35d2ee.js → sqm-navigation-sidebar-item-view-5dfd2b52.js} +17 -6
- package/dist/cjs/sqm-navigation-sidebar-item.cjs.entry.js +25 -2
- package/dist/cjs/{sqm-navigation-sidebar-view-17111896.js → sqm-navigation-sidebar-view-38a5227a.js} +16 -6
- package/dist/cjs/sqm-navigation-sidebar.cjs.entry.js +19 -3
- package/dist/cjs/sqm-pagination_3.cjs.entry.js +14 -4
- package/dist/cjs/{sqm-portal-email-verification-view-9f7b86a9.js → sqm-portal-email-verification-view-969cf926.js} +1 -1
- package/dist/cjs/sqm-portal-email-verification.cjs.entry.js +2 -2
- package/dist/cjs/{sqm-portal-profile-view-e77710f0.js → sqm-portal-profile-view-96e936cf.js} +1 -1
- package/dist/cjs/sqm-portal-profile.cjs.entry.js +2 -2
- package/dist/cjs/sqm-referral-table_11.cjs.entry.js +1 -1
- package/dist/cjs/sqm-rewards-table_9.cjs.entry.js +1 -1
- package/dist/cjs/sqm-stencilbook.cjs.entry.js +7 -7
- package/dist/collection/components/sqm-big-stat/sqm-big-stat.js +2 -2
- package/dist/collection/components/sqm-divided-layout/sqm-divided-layout-view.js +4 -1
- package/dist/collection/components/sqm-divided-layout/sqm-divided-layout.js +30 -0
- package/dist/collection/components/sqm-navigation-sidebar/sqm-navigation-sidebar-view.js +16 -6
- package/dist/collection/components/sqm-navigation-sidebar/sqm-navigation-sidebar.js +83 -5
- package/dist/collection/components/sqm-navigation-sidebar-item/sqm-navigation-sidebar-item-view.js +17 -6
- package/dist/collection/components/sqm-navigation-sidebar-item/sqm-navigation-sidebar-item.js +233 -1
- package/dist/collection/components/sqm-navigation-sidebar-item/useNavigationSidebarItem.js +9 -1
- package/dist/collection/components/sqm-pagination/sqm-pagination-view.js +3 -3
- package/dist/collection/components/sqm-pagination/sqm-pagination.js +43 -0
- package/dist/collection/global/styles.js +70 -2
- package/dist/collection/global/styles.ts +70 -2
- package/dist/esm/{ShadowViewAddon-6a9f6e48.js → ShadowViewAddon-28c8307e.js} +1 -1
- package/dist/esm/{global-9d6f3bbe.js → global-5e65213d.js} +70 -2
- package/dist/esm/loader.js +2 -2
- package/dist/esm/mint-components.js +2 -2
- package/dist/esm/sqm-banking-info-form_17.entry.js +2 -2
- package/dist/esm/sqm-big-stat_41.entry.js +12 -3
- package/dist/esm/sqm-email-verification.entry.js +1 -1
- package/dist/esm/sqm-empty_4.entry.js +1 -1
- package/dist/esm/{sqm-invoice-table-view-fda573e4.js → sqm-invoice-table-view-a2c45ff7.js} +1 -1
- package/dist/esm/sqm-leaderboard-rank.entry.js +1 -1
- package/dist/esm/{sqm-navigation-sidebar-item-view-8f1c72bc.js → sqm-navigation-sidebar-item-view-9cc0f695.js} +17 -6
- package/dist/esm/sqm-navigation-sidebar-item.entry.js +25 -2
- package/dist/esm/{sqm-navigation-sidebar-view-9d802b78.js → sqm-navigation-sidebar-view-f898265a.js} +16 -6
- package/dist/esm/sqm-navigation-sidebar.entry.js +20 -4
- package/dist/esm/sqm-pagination_3.entry.js +14 -4
- package/dist/esm/{sqm-portal-email-verification-view-14f1c22c.js → sqm-portal-email-verification-view-56a69db0.js} +1 -1
- package/dist/esm/sqm-portal-email-verification.entry.js +2 -2
- package/dist/esm/{sqm-portal-profile-view-41116f1d.js → sqm-portal-profile-view-5cf91770.js} +1 -1
- package/dist/esm/sqm-portal-profile.entry.js +2 -2
- package/dist/esm/sqm-referral-table_11.entry.js +1 -1
- package/dist/esm/sqm-rewards-table_9.entry.js +1 -1
- package/dist/esm/sqm-stencilbook.entry.js +7 -7
- package/dist/esm-es5/{ShadowViewAddon-6a9f6e48.js → ShadowViewAddon-28c8307e.js} +1 -1
- package/dist/esm-es5/{global-9d6f3bbe.js → global-5e65213d.js} +4 -4
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/mint-components.js +1 -1
- package/dist/esm-es5/sqm-banking-info-form_17.entry.js +1 -1
- package/dist/esm-es5/sqm-big-stat_41.entry.js +1 -1
- package/dist/esm-es5/sqm-email-verification.entry.js +1 -1
- package/dist/esm-es5/sqm-empty_4.entry.js +1 -1
- package/dist/esm-es5/{sqm-invoice-table-view-fda573e4.js → sqm-invoice-table-view-a2c45ff7.js} +1 -1
- package/dist/esm-es5/sqm-leaderboard-rank.entry.js +1 -1
- package/dist/esm-es5/sqm-navigation-sidebar-item-view-9cc0f695.js +1 -0
- package/dist/esm-es5/sqm-navigation-sidebar-item.entry.js +1 -1
- package/dist/esm-es5/sqm-navigation-sidebar-view-f898265a.js +1 -0
- package/dist/esm-es5/sqm-navigation-sidebar.entry.js +1 -1
- package/dist/esm-es5/sqm-pagination_3.entry.js +1 -1
- package/dist/esm-es5/{sqm-portal-email-verification-view-14f1c22c.js → sqm-portal-email-verification-view-56a69db0.js} +1 -1
- package/dist/esm-es5/sqm-portal-email-verification.entry.js +1 -1
- package/dist/esm-es5/{sqm-portal-profile-view-41116f1d.js → sqm-portal-profile-view-5cf91770.js} +1 -1
- package/dist/esm-es5/sqm-portal-profile.entry.js +1 -1
- package/dist/esm-es5/sqm-referral-table_11.entry.js +1 -1
- package/dist/esm-es5/sqm-rewards-table_9.entry.js +1 -1
- package/dist/esm-es5/sqm-stencilbook.entry.js +1 -1
- package/dist/mint-components/global/styles.ts +70 -2
- package/dist/mint-components/mint-components.esm.js +1 -1
- package/dist/mint-components/mint-components.js +1 -1
- package/dist/mint-components/{p-afbb3f73.entry.js → p-03622801.entry.js} +1 -1
- package/dist/mint-components/{p-52858682.system.js → p-05f785fb.system.js} +1 -1
- package/dist/mint-components/{p-868daffd.system.entry.js → p-125a798a.system.entry.js} +1 -1
- package/dist/mint-components/p-16c16702.js +1 -0
- package/dist/mint-components/p-1a6725c1.system.entry.js +1 -0
- package/dist/mint-components/{p-320d3c31.entry.js → p-1b983c86.entry.js} +1 -1
- package/dist/mint-components/{p-28b011a0.js → p-1e7e8dd2.js} +1 -1
- package/dist/mint-components/{p-45bb63c7.system.entry.js → p-26d60973.system.entry.js} +1 -1
- package/dist/mint-components/{p-8119a65e.system.entry.js → p-2d0163d2.system.entry.js} +1 -1
- package/dist/mint-components/{p-4027c743.system.entry.js → p-317264ac.system.entry.js} +1 -1
- package/dist/mint-components/{p-776260e8.js → p-37e86ead.js} +10 -10
- package/dist/mint-components/p-386c82ba.entry.js +13 -0
- package/dist/mint-components/{p-81d6479a.system.js → p-437c4eac.system.js} +1 -1
- package/dist/mint-components/p-46a672e4.entry.js +1 -0
- package/dist/mint-components/{p-82d04fd3.entry.js → p-48b3ef9c.entry.js} +1 -1
- package/dist/mint-components/p-4a3359aa.entry.js +1 -0
- package/dist/mint-components/p-5b1b2c10.system.entry.js +1 -0
- package/dist/mint-components/p-5d407714.system.entry.js +1 -0
- package/dist/mint-components/p-5e617dd6.system.js +1 -0
- package/dist/mint-components/{p-dce51a2e.system.entry.js → p-6131a44f.system.entry.js} +1 -1
- package/dist/mint-components/{p-1ae6c418.entry.js → p-61af919f.entry.js} +1 -1
- package/dist/mint-components/{p-72263a72.js → p-62a04a06.js} +1 -1
- package/dist/mint-components/p-66a2b1a4.js +1 -0
- package/dist/mint-components/{p-8d9328dd.entry.js → p-69e017e1.entry.js} +2 -2
- package/dist/mint-components/{p-12536a1f.system.entry.js → p-749cb346.system.entry.js} +1 -1
- package/dist/mint-components/{p-642b0650.system.js → p-773e2418.system.js} +9 -9
- package/dist/mint-components/p-861d4824.entry.js +13 -0
- package/dist/mint-components/p-9f2edf59.system.js +1 -0
- package/dist/mint-components/p-9f35f2b5.system.entry.js +1 -0
- package/dist/mint-components/{p-3d8c4dd2.entry.js → p-a041f0dc.entry.js} +7 -7
- package/dist/mint-components/{p-6d8f7c71.js → p-a34ac378.js} +1 -1
- package/dist/mint-components/{p-3c96533f.js → p-b1c78ed4.js} +1 -1
- package/dist/mint-components/{p-d30919cd.entry.js → p-be3ffc17.entry.js} +1 -1
- package/dist/mint-components/{p-4d91a1d6.system.js → p-d24a881e.system.js} +1 -1
- package/dist/mint-components/p-dbec319d.system.js +1 -0
- package/dist/mint-components/{p-b385c9f0.system.entry.js → p-e977ff3b.system.entry.js} +1 -1
- package/dist/mint-components/{p-8ab87bd4.entry.js → p-eadd9d56.entry.js} +1 -1
- package/dist/mint-components/{p-17da19a2.system.js → p-ebae139f.system.js} +1 -1
- package/dist/mint-components/{p-1b7e6ee9.entry.js → p-f189d803.entry.js} +1 -1
- package/dist/mint-components/{p-f9da2c34.system.entry.js → p-f5023fd8.system.entry.js} +1 -1
- package/dist/mint-components/{p-ead64a3d.system.entry.js → p-fb85fbb0.system.entry.js} +1 -1
- package/dist/types/components/sqm-big-stat/sqm-big-stat.d.ts +2 -2
- package/dist/types/components/sqm-divided-layout/sqm-divided-layout-view.d.ts +2 -0
- package/dist/types/components/sqm-divided-layout/sqm-divided-layout.d.ts +6 -0
- package/dist/types/components/sqm-navigation-sidebar/sqm-navigation-sidebar-view.d.ts +1 -0
- package/dist/types/components/sqm-navigation-sidebar/sqm-navigation-sidebar.d.ts +14 -0
- package/dist/types/components/sqm-navigation-sidebar-item/sqm-navigation-sidebar-item-view.d.ts +8 -0
- package/dist/types/components/sqm-navigation-sidebar-item/sqm-navigation-sidebar-item.d.ts +57 -0
- package/dist/types/components/sqm-pagination/sqm-pagination-view.d.ts +1 -0
- package/dist/types/components/sqm-pagination/sqm-pagination.d.ts +9 -0
- package/dist/types/components.d.ts +171 -4
- package/dist/types/global/styles.d.ts +1 -1
- package/docs/docs.docx +0 -0
- package/docs/raisins.json +1 -1
- package/grapesjs/grapesjs.js +1 -1
- package/package.json +1 -1
- package/dist/esm-es5/sqm-navigation-sidebar-item-view-8f1c72bc.js +0 -1
- package/dist/esm-es5/sqm-navigation-sidebar-view-9d802b78.js +0 -1
- package/dist/mint-components/p-094b3b54.system.entry.js +0 -1
- package/dist/mint-components/p-141bf5c1.system.entry.js +0 -1
- package/dist/mint-components/p-24db5c70.js +0 -1
- package/dist/mint-components/p-38e5c429.system.js +0 -1
- package/dist/mint-components/p-3db34d68.js +0 -1
- package/dist/mint-components/p-420554af.system.entry.js +0 -1
- package/dist/mint-components/p-635d5ef2.system.js +0 -1
- package/dist/mint-components/p-7ab21e4d.entry.js +0 -1
- package/dist/mint-components/p-7e3d84a3.entry.js +0 -13
- package/dist/mint-components/p-9abb9ab0.entry.js +0 -13
- package/dist/mint-components/p-b12e132b.system.entry.js +0 -1
- package/dist/mint-components/p-e6f50ffd.entry.js +0 -1
- package/dist/mint-components/p-ee06426a.system.js +0 -1
|
@@ -9,7 +9,7 @@ const cjs = require('./cjs-1066ec21.js');
|
|
|
9
9
|
const utils = require('./utils-6847bc06.js');
|
|
10
10
|
require('./JSS-8503a151.js');
|
|
11
11
|
require('./mixins-f7e0377a.js');
|
|
12
|
-
const sqmNavigationSidebarItemView = require('./sqm-navigation-sidebar-item-view-
|
|
12
|
+
const sqmNavigationSidebarItemView = require('./sqm-navigation-sidebar-item-view-5dfd2b52.js');
|
|
13
13
|
|
|
14
14
|
function useNavigationSidebarItem(props) {
|
|
15
15
|
const currentPage = index_module.kn();
|
|
@@ -20,14 +20,29 @@ function useNavigationSidebarItem(props) {
|
|
|
20
20
|
data: {
|
|
21
21
|
label: props.label,
|
|
22
22
|
icon: props.icon,
|
|
23
|
-
path: props.path
|
|
23
|
+
path: props.path,
|
|
24
24
|
},
|
|
25
|
+
backgroundColor: props.backgroundColor,
|
|
26
|
+
backgroundHoverColor: props.backgroundHoverColor,
|
|
27
|
+
textColor: props.textColor,
|
|
28
|
+
textHoverColor: props.textHoverColor,
|
|
29
|
+
borderRadius: props.borderRadius,
|
|
30
|
+
backgroundFocusedColor: props.backgroundFocusedColor,
|
|
31
|
+
textFocusedColor: props.textFocusedColor,
|
|
32
|
+
padding: props.padding,
|
|
25
33
|
};
|
|
26
34
|
}
|
|
27
35
|
|
|
28
36
|
const NavigationSidebarItem = class {
|
|
29
37
|
constructor(hostRef) {
|
|
30
38
|
index.registerInstance(this, hostRef);
|
|
39
|
+
/**
|
|
40
|
+
* @uiName Padding
|
|
41
|
+
* @uiType string
|
|
42
|
+
* @uiEnum ["none", "xxx-small", "xx-small", "x-small", "small", "medium", "large", "x-large", "xx-large", "xxx-large", "xxxx-large"]
|
|
43
|
+
* @uiEnumNames ["None", "XXX-Small", "XX-Small", "X-Small", "Small", "Medium", "Large", "X-Large", "XX-Large", "XXX-Large", "XXXX-Large"]
|
|
44
|
+
*/
|
|
45
|
+
this.padding = "x-small";
|
|
31
46
|
stencilHooks_module.h$1(this);
|
|
32
47
|
}
|
|
33
48
|
disconnectedCallback() { }
|
|
@@ -47,6 +62,14 @@ function useSidebarItemDemo(props) {
|
|
|
47
62
|
label: props.label || "Dashboard",
|
|
48
63
|
icon: props.icon || "house",
|
|
49
64
|
},
|
|
65
|
+
backgroundColor: props.backgroundColor,
|
|
66
|
+
backgroundHoverColor: props.backgroundHoverColor,
|
|
67
|
+
textColor: props.textColor,
|
|
68
|
+
textHoverColor: props.textHoverColor,
|
|
69
|
+
borderRadius: props.borderRadius,
|
|
70
|
+
backgroundFocusedColor: props.backgroundFocusedColor,
|
|
71
|
+
textFocusedColor: props.textFocusedColor,
|
|
72
|
+
padding: props.padding,
|
|
50
73
|
}, props.demoData || {}, { arrayMerge: (_, a) => a });
|
|
51
74
|
}
|
|
52
75
|
|
package/dist/cjs/{sqm-navigation-sidebar-view-17111896.js → sqm-navigation-sidebar-view-38a5227a.js}
RENAMED
|
@@ -2,7 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
const index = require('./index-a29c60ef.js');
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
function NavigationSidebarView(props, children) {
|
|
6
|
+
const vanillaStyle = `
|
|
6
7
|
|
|
7
8
|
* {
|
|
8
9
|
padding: 0;
|
|
@@ -10,6 +11,16 @@ const vanillaStyle = `
|
|
|
10
11
|
box-sizing: border-box;
|
|
11
12
|
}
|
|
12
13
|
|
|
14
|
+
.container {
|
|
15
|
+
background: var(--sqm-portal-background);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.menu-items {
|
|
19
|
+
display: flex;
|
|
20
|
+
flex-direction: column;
|
|
21
|
+
gap: 10px;
|
|
22
|
+
}
|
|
23
|
+
|
|
13
24
|
@keyframes slideIn {
|
|
14
25
|
0% {
|
|
15
26
|
left: -350px;
|
|
@@ -61,12 +72,12 @@ const vanillaStyle = `
|
|
|
61
72
|
flex-direction: column;
|
|
62
73
|
z-index: 100;
|
|
63
74
|
}
|
|
64
|
-
.menu-items {
|
|
75
|
+
.menu-items {
|
|
65
76
|
display: none;
|
|
66
77
|
padding: 20px;
|
|
67
78
|
border-right: 1px solid #eaeaea;
|
|
68
79
|
padding-top: 60px;
|
|
69
|
-
background:
|
|
80
|
+
background: var(--sqm-portal-background);
|
|
70
81
|
width: 100vw;
|
|
71
82
|
height: 100vh;
|
|
72
83
|
position: absolute;
|
|
@@ -130,7 +141,7 @@ const vanillaStyle = `
|
|
|
130
141
|
.toggler:checked ~ .hamburger > .line:nth-child(2),
|
|
131
142
|
.toggler:checked ~ .hamburger > .line:nth-child(3) {
|
|
132
143
|
width: 75%;
|
|
133
|
-
border-bottom: 3px solid
|
|
144
|
+
border-bottom: 3px solid ${props.mobileMenuColor};
|
|
134
145
|
margin: 0;
|
|
135
146
|
}
|
|
136
147
|
|
|
@@ -140,11 +151,10 @@ const vanillaStyle = `
|
|
|
140
151
|
height: 4px;
|
|
141
152
|
width: 100%;
|
|
142
153
|
margin-bottom: 3px;
|
|
143
|
-
border-bottom: 5px solid
|
|
154
|
+
border-bottom: 5px solid ${props.mobileMenuColor};
|
|
144
155
|
}
|
|
145
156
|
}
|
|
146
157
|
`;
|
|
147
|
-
function NavigationSidebarView(props, children) {
|
|
148
158
|
return (index.h("div", { class: "container", part: "sqm-base" },
|
|
149
159
|
index.h("style", null, vanillaStyle),
|
|
150
160
|
index.h("input", Object.assign({ type: "checkbox", class: "toggler" }, props)),
|
|
@@ -5,21 +5,31 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
const index = require('./index-a29c60ef.js');
|
|
6
6
|
const stencilHooks_module = require('./stencil-hooks.module-3a336b0f.js');
|
|
7
7
|
const index_module = require('./index.module-ee84433d.js');
|
|
8
|
-
const
|
|
8
|
+
const cjs = require('./cjs-1066ec21.js');
|
|
9
|
+
const sqmNavigationSidebarView = require('./sqm-navigation-sidebar-view-38a5227a.js');
|
|
9
10
|
|
|
10
11
|
const NavigationSidebar = class {
|
|
11
12
|
constructor(hostRef) {
|
|
12
13
|
index.registerInstance(this, hostRef);
|
|
13
14
|
this.ignored = true;
|
|
15
|
+
/**
|
|
16
|
+
* @uiName Text color
|
|
17
|
+
* @uiWidget color
|
|
18
|
+
* @format color
|
|
19
|
+
* @uiGroup Style
|
|
20
|
+
*/
|
|
21
|
+
this.mobileMenuColor = "var(--sqm-text, #444445)";
|
|
14
22
|
stencilHooks_module.h$1(this);
|
|
15
23
|
}
|
|
16
24
|
disconnectedCallback() { }
|
|
17
25
|
render() {
|
|
18
|
-
const props =
|
|
26
|
+
const props = index_module.isDemo()
|
|
27
|
+
? useDemoNavigationSidebar(this)
|
|
28
|
+
: useNavigationSidebar(this);
|
|
19
29
|
return (index.h(sqmNavigationSidebarView.NavigationSidebarView, Object.assign({}, props), index.h("slot", null)));
|
|
20
30
|
}
|
|
21
31
|
};
|
|
22
|
-
function useNavigationSidebar() {
|
|
32
|
+
function useNavigationSidebar(props) {
|
|
23
33
|
const location = index_module.kn();
|
|
24
34
|
const programId = index_module.H();
|
|
25
35
|
const [checked, setChecked] = stencilHooks_module.useState(false);
|
|
@@ -31,9 +41,15 @@ function useNavigationSidebar() {
|
|
|
31
41
|
setChecked(e.target.checked);
|
|
32
42
|
}
|
|
33
43
|
return {
|
|
44
|
+
mobileMenuColor: props.mobileMenuColor,
|
|
34
45
|
checked,
|
|
35
46
|
onClick,
|
|
36
47
|
};
|
|
37
48
|
}
|
|
49
|
+
function useDemoNavigationSidebar(props) {
|
|
50
|
+
return cjs.cjs({
|
|
51
|
+
mobileMenuColor: props.mobileMenuColor,
|
|
52
|
+
}, props.demoData || {}, { arrayMerge: (_, a) => a });
|
|
53
|
+
}
|
|
38
54
|
|
|
39
55
|
exports.sqm_navigation_sidebar = NavigationSidebar;
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-a29c60ef.js');
|
|
6
6
|
const stencilHooks_module = require('./stencil-hooks.module-3a336b0f.js');
|
|
7
|
-
const global = require('./global-
|
|
7
|
+
const global = require('./global-f06aabc0.js');
|
|
8
8
|
const index_module = require('./index.module-ee84433d.js');
|
|
9
9
|
const cjs = require('./cjs-1066ec21.js');
|
|
10
10
|
const utils = require('./utils-6847bc06.js');
|
|
@@ -29,7 +29,7 @@ const style = {
|
|
|
29
29
|
const sheet = JSS.createStyleSheet(style);
|
|
30
30
|
const styleString = sheet.toString();
|
|
31
31
|
function PaginationView(props) {
|
|
32
|
-
const { states, callbacks, text } = props;
|
|
32
|
+
const { states, callbacks, text, buttonType } = props;
|
|
33
33
|
const { onNext, onPrev } = callbacks;
|
|
34
34
|
const { currentPage, totalPages, loading } = states;
|
|
35
35
|
if (totalPages === 1)
|
|
@@ -37,10 +37,10 @@ function PaginationView(props) {
|
|
|
37
37
|
return (index.h("span", { class: sheet.classes.Container, part: "sqm-base" },
|
|
38
38
|
index.h("style", { type: "text/css" }, styleString),
|
|
39
39
|
!loading && (index.h(index.Fragment, null,
|
|
40
|
-
index.h("sl-button", { onClick: onPrev, part: "sqm-pagination-button", circle: true, disabled: currentPage === 1 },
|
|
40
|
+
index.h("sl-button", { exportparts: `base: ${props.buttonType === "primary" ? "primary" : "secondary"}button-base`, onClick: onPrev, part: "sqm-pagination-button", circle: true, disabled: currentPage === 1 },
|
|
41
41
|
index.h("sl-icon", { name: "chevron-left", label: "Previous Page" })),
|
|
42
42
|
index.h("div", { class: sheet.classes.TextContainer }, text.paginationText))),
|
|
43
|
-
index.h("sl-button", { onClick: onNext, part: "sqm-pagination-button", circle: true, disabled: currentPage === totalPages },
|
|
43
|
+
index.h("sl-button", { exportparts: `base: ${props.buttonType === "primary" ? "primary" : "secondary"}button-base`, onClick: onNext, part: "sqm-pagination-button", circle: true, disabled: currentPage === totalPages },
|
|
44
44
|
index.h("sl-icon", { name: "chevron-right", label: "Previous Page" }))));
|
|
45
45
|
}
|
|
46
46
|
|
|
@@ -79,6 +79,15 @@ const Pagination = class {
|
|
|
79
79
|
* @uiName Pagination text
|
|
80
80
|
*/
|
|
81
81
|
this.paginationText = "{currentPage} of {totalPages}";
|
|
82
|
+
/**
|
|
83
|
+
* The type of the button (primary or secondary) that will be used to copy the link.
|
|
84
|
+
* @uiName Button Type
|
|
85
|
+
* @uiType string
|
|
86
|
+
* @uiEnum ["primary", "secondary"]
|
|
87
|
+
* @uiEnumNames ["Primary", "Secondary"]
|
|
88
|
+
* @uiGroup Style
|
|
89
|
+
*/
|
|
90
|
+
this.buttonType = "secondary";
|
|
82
91
|
stencilHooks_module.h$1(this);
|
|
83
92
|
}
|
|
84
93
|
disconnectedCallback() { }
|
|
@@ -97,6 +106,7 @@ function useDemoPagination(props) {
|
|
|
97
106
|
totalPages: 5,
|
|
98
107
|
loading: false,
|
|
99
108
|
},
|
|
109
|
+
buttonType: props.buttonType,
|
|
100
110
|
callbacks: {
|
|
101
111
|
onNext: () => setCurrentPage(currentPage + 1),
|
|
102
112
|
onPrev: () => setCurrentPage(currentPage - 1),
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
const index = require('./index-a29c60ef.js');
|
|
4
|
-
const global = require('./global-
|
|
4
|
+
const global = require('./global-f06aabc0.js');
|
|
5
5
|
const JSS = require('./JSS-8503a151.js');
|
|
6
6
|
const mixins = require('./mixins-f7e0377a.js');
|
|
7
7
|
const sqmTextSpanView = require('./sqm-text-span-view-56e48a78.js');
|
|
@@ -4,13 +4,13 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-a29c60ef.js');
|
|
6
6
|
const stencilHooks_module = require('./stencil-hooks.module-3a336b0f.js');
|
|
7
|
-
require('./global-
|
|
7
|
+
require('./global-f06aabc0.js');
|
|
8
8
|
const index_module = require('./index.module-ee84433d.js');
|
|
9
9
|
const cjs = require('./cjs-1066ec21.js');
|
|
10
10
|
require('./JSS-8503a151.js');
|
|
11
11
|
require('./mixins-f7e0377a.js');
|
|
12
12
|
require('./sqm-text-span-view-56e48a78.js');
|
|
13
|
-
const sqmPortalEmailVerificationView = require('./sqm-portal-email-verification-view-
|
|
13
|
+
const sqmPortalEmailVerificationView = require('./sqm-portal-email-verification-view-969cf926.js');
|
|
14
14
|
|
|
15
15
|
function usePortalEmailVerification(props) {
|
|
16
16
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
package/dist/cjs/{sqm-portal-profile-view-e77710f0.js → sqm-portal-profile-view-96e936cf.js}
RENAMED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
const index = require('./index-a29c60ef.js');
|
|
4
|
-
const global = require('./global-
|
|
4
|
+
const global = require('./global-f06aabc0.js');
|
|
5
5
|
const JSS = require('./JSS-8503a151.js');
|
|
6
6
|
const sqmTextSpanView = require('./sqm-text-span-view-56e48a78.js');
|
|
7
7
|
|
|
@@ -4,13 +4,13 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-a29c60ef.js');
|
|
6
6
|
const stencilHooks_module = require('./stencil-hooks.module-3a336b0f.js');
|
|
7
|
-
require('./global-
|
|
7
|
+
require('./global-f06aabc0.js');
|
|
8
8
|
const index_module = require('./index.module-ee84433d.js');
|
|
9
9
|
const cjs = require('./cjs-1066ec21.js');
|
|
10
10
|
const utils = require('./utils-6847bc06.js');
|
|
11
11
|
require('./JSS-8503a151.js');
|
|
12
12
|
require('./sqm-text-span-view-56e48a78.js');
|
|
13
|
-
const sqmPortalProfileView = require('./sqm-portal-profile-view-
|
|
13
|
+
const sqmPortalProfileView = require('./sqm-portal-profile-view-96e936cf.js');
|
|
14
14
|
const utilities = require('./utilities-78f5e169.js');
|
|
15
15
|
|
|
16
16
|
const GET_USER = index_module.dist.gql `
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-a29c60ef.js');
|
|
6
6
|
const stencilHooks_module = require('./stencil-hooks.module-3a336b0f.js');
|
|
7
|
-
const global = require('./global-
|
|
7
|
+
const global = require('./global-f06aabc0.js');
|
|
8
8
|
const index_module = require('./index.module-ee84433d.js');
|
|
9
9
|
const cjs = require('./cjs-1066ec21.js');
|
|
10
10
|
const utils = require('./utils-6847bc06.js');
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-a29c60ef.js');
|
|
6
6
|
const stencilHooks_module = require('./stencil-hooks.module-3a336b0f.js');
|
|
7
|
-
const global = require('./global-
|
|
7
|
+
const global = require('./global-f06aabc0.js');
|
|
8
8
|
const index_module = require('./index.module-ee84433d.js');
|
|
9
9
|
const cjs = require('./cjs-1066ec21.js');
|
|
10
10
|
const utils = require('./utils-6847bc06.js');
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-a29c60ef.js');
|
|
6
6
|
const stencilHooks_module = require('./stencil-hooks.module-3a336b0f.js');
|
|
7
|
-
require('./global-
|
|
7
|
+
require('./global-f06aabc0.js');
|
|
8
8
|
const index_module = require('./index.module-ee84433d.js');
|
|
9
9
|
require('./cjs-1066ec21.js');
|
|
10
10
|
require('./utils-6847bc06.js');
|
|
@@ -22,22 +22,22 @@ require('./index-8c6255f5.js');
|
|
|
22
22
|
const emailRegistrationView = require('./email-registration-view-55b378dc.js');
|
|
23
23
|
const sqmLeaderboardRankView = require('./sqm-leaderboard-rank-view-d39a55d8.js');
|
|
24
24
|
const sqmLogoutCurrentUserView = require('./sqm-logout-current-user-view-11d57c12.js');
|
|
25
|
-
const sqmNavigationSidebarView = require('./sqm-navigation-sidebar-view-
|
|
26
|
-
const sqmNavigationSidebarItemView = require('./sqm-navigation-sidebar-item-view-
|
|
27
|
-
const sqmPortalEmailVerificationView = require('./sqm-portal-email-verification-view-
|
|
25
|
+
const sqmNavigationSidebarView = require('./sqm-navigation-sidebar-view-38a5227a.js');
|
|
26
|
+
const sqmNavigationSidebarItemView = require('./sqm-navigation-sidebar-item-view-5dfd2b52.js');
|
|
27
|
+
const sqmPortalEmailVerificationView = require('./sqm-portal-email-verification-view-969cf926.js');
|
|
28
28
|
const sqmPortalForgotPasswordView = require('./sqm-portal-forgot-password-view-b986086e.js');
|
|
29
29
|
const sqmPortalLoginView = require('./sqm-portal-login-view-84e99287.js');
|
|
30
30
|
const sqmBaseRegistrationFormView = require('./sqm-base-registration-form-view-1b2440c3.js');
|
|
31
31
|
const sqmPortalRegistrationFormView = require('./sqm-portal-registration-form-view-4377d849.js');
|
|
32
|
-
const sqmPortalProfileView = require('./sqm-portal-profile-view-
|
|
32
|
+
const sqmPortalProfileView = require('./sqm-portal-profile-view-96e936cf.js');
|
|
33
33
|
require('./utilities-78f5e169.js');
|
|
34
34
|
const sqmPortalResetPasswordView = require('./sqm-portal-reset-password-view-52fc50fe.js');
|
|
35
35
|
const sqmPortalVerifyEmailView = require('./sqm-portal-verify-email-view-4f837226.js');
|
|
36
36
|
require('./ErrorView-b2fcf954.js');
|
|
37
37
|
const sqmQrCodeView = require('./sqm-qr-code-view-3da9ed28.js');
|
|
38
|
-
const ShadowViewAddon = require('./ShadowViewAddon-
|
|
38
|
+
const ShadowViewAddon = require('./ShadowViewAddon-d958d324.js');
|
|
39
39
|
const sqmPortalContainerView = require('./sqm-portal-container-view-4f15143a.js');
|
|
40
|
-
const sqmInvoiceTableView = require('./sqm-invoice-table-view-
|
|
40
|
+
const sqmInvoiceTableView = require('./sqm-invoice-table-view-431faed1.js');
|
|
41
41
|
|
|
42
42
|
/**
|
|
43
43
|
* lodash (Custom Build) <https://lodash.com/>
|
|
@@ -233,7 +233,7 @@ export class BigStat {
|
|
|
233
233
|
"optional": true,
|
|
234
234
|
"docs": {
|
|
235
235
|
"tags": [{
|
|
236
|
-
"text": "Stat font
|
|
236
|
+
"text": "Stat font weight",
|
|
237
237
|
"name": "uiName"
|
|
238
238
|
}, {
|
|
239
239
|
"text": "Style",
|
|
@@ -245,7 +245,7 @@ export class BigStat {
|
|
|
245
245
|
"text": "[\"Thin\", \"Extra Light\", \"Light\", \"Normal\", \"Medium\", \"Semi Bold\", \"Bold\", \"Extra Bold\", \"Heavy\"]",
|
|
246
246
|
"name": "uiEnumNames"
|
|
247
247
|
}],
|
|
248
|
-
"text": "Font
|
|
248
|
+
"text": "Font weight of the stat text"
|
|
249
249
|
},
|
|
250
250
|
"attribute": "stat-font-weight",
|
|
251
251
|
"reflect": false
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
2
|
import { createStyleSheet } from "../../styling/JSS";
|
|
3
3
|
export function DividedLayoutView(props, children) {
|
|
4
|
+
console.log("background color is ", props.backgroundColor);
|
|
4
5
|
const getBorder = () => {
|
|
5
6
|
if (props.direction === "row") {
|
|
6
7
|
return { "border-right": props.dividerStyle || "1px solid #EAEAEA" };
|
|
@@ -11,6 +12,7 @@ export function DividedLayoutView(props, children) {
|
|
|
11
12
|
};
|
|
12
13
|
const style = {
|
|
13
14
|
LayoutContainer: {
|
|
15
|
+
background: props.backgroundColor,
|
|
14
16
|
display: "contents",
|
|
15
17
|
// First style applies when shadow DOM is disabled, second applies when shadow DOM is enabled
|
|
16
18
|
"& > :not(:last-child)": {
|
|
@@ -26,7 +28,8 @@ export function DividedLayoutView(props, children) {
|
|
|
26
28
|
flex: 1;
|
|
27
29
|
box-sizing: border-box;
|
|
28
30
|
flex-direction: ${props.direction};
|
|
29
|
-
background-color: var(--sqm-
|
|
31
|
+
background-color: var(--sqm-portal-background);
|
|
32
|
+
color: var(--sqm-text);
|
|
30
33
|
overflow-x: clip;
|
|
31
34
|
${props.direction === "column"
|
|
32
35
|
? "width: 100%; max-width: var(--sqm-portal-main-width);"
|
|
@@ -18,6 +18,12 @@ export class DividedLayout {
|
|
|
18
18
|
* @uiName Border style
|
|
19
19
|
*/
|
|
20
20
|
this.dividerStyle = "1px solid #EAEAEA";
|
|
21
|
+
/**
|
|
22
|
+
* Background color of the divider
|
|
23
|
+
* @uiName Divider Background Color
|
|
24
|
+
* @uiWidget color
|
|
25
|
+
*/
|
|
26
|
+
this.backgroundColor = "#FFFFFF";
|
|
21
27
|
withHooks(this);
|
|
22
28
|
}
|
|
23
29
|
disconnectedCallback() { }
|
|
@@ -100,6 +106,30 @@ export class DividedLayout {
|
|
|
100
106
|
"attribute": "divider-style",
|
|
101
107
|
"reflect": false,
|
|
102
108
|
"defaultValue": "\"1px solid #EAEAEA\""
|
|
109
|
+
},
|
|
110
|
+
"backgroundColor": {
|
|
111
|
+
"type": "string",
|
|
112
|
+
"mutable": false,
|
|
113
|
+
"complexType": {
|
|
114
|
+
"original": "string",
|
|
115
|
+
"resolved": "string",
|
|
116
|
+
"references": {}
|
|
117
|
+
},
|
|
118
|
+
"required": false,
|
|
119
|
+
"optional": true,
|
|
120
|
+
"docs": {
|
|
121
|
+
"tags": [{
|
|
122
|
+
"text": "Divider Background Color",
|
|
123
|
+
"name": "uiName"
|
|
124
|
+
}, {
|
|
125
|
+
"text": "color",
|
|
126
|
+
"name": "uiWidget"
|
|
127
|
+
}],
|
|
128
|
+
"text": "Background color of the divider"
|
|
129
|
+
},
|
|
130
|
+
"attribute": "background-color",
|
|
131
|
+
"reflect": false,
|
|
132
|
+
"defaultValue": "\"#FFFFFF\""
|
|
103
133
|
}
|
|
104
134
|
}; }
|
|
105
135
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
|
-
|
|
2
|
+
export function NavigationSidebarView(props, children) {
|
|
3
|
+
const vanillaStyle = `
|
|
3
4
|
|
|
4
5
|
* {
|
|
5
6
|
padding: 0;
|
|
@@ -7,6 +8,16 @@ const vanillaStyle = `
|
|
|
7
8
|
box-sizing: border-box;
|
|
8
9
|
}
|
|
9
10
|
|
|
11
|
+
.container {
|
|
12
|
+
background: var(--sqm-portal-background);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.menu-items {
|
|
16
|
+
display: flex;
|
|
17
|
+
flex-direction: column;
|
|
18
|
+
gap: 10px;
|
|
19
|
+
}
|
|
20
|
+
|
|
10
21
|
@keyframes slideIn {
|
|
11
22
|
0% {
|
|
12
23
|
left: -350px;
|
|
@@ -58,12 +69,12 @@ const vanillaStyle = `
|
|
|
58
69
|
flex-direction: column;
|
|
59
70
|
z-index: 100;
|
|
60
71
|
}
|
|
61
|
-
.menu-items {
|
|
72
|
+
.menu-items {
|
|
62
73
|
display: none;
|
|
63
74
|
padding: 20px;
|
|
64
75
|
border-right: 1px solid #eaeaea;
|
|
65
76
|
padding-top: 60px;
|
|
66
|
-
background:
|
|
77
|
+
background: var(--sqm-portal-background);
|
|
67
78
|
width: 100vw;
|
|
68
79
|
height: 100vh;
|
|
69
80
|
position: absolute;
|
|
@@ -127,7 +138,7 @@ const vanillaStyle = `
|
|
|
127
138
|
.toggler:checked ~ .hamburger > .line:nth-child(2),
|
|
128
139
|
.toggler:checked ~ .hamburger > .line:nth-child(3) {
|
|
129
140
|
width: 75%;
|
|
130
|
-
border-bottom: 3px solid
|
|
141
|
+
border-bottom: 3px solid ${props.mobileMenuColor};
|
|
131
142
|
margin: 0;
|
|
132
143
|
}
|
|
133
144
|
|
|
@@ -137,11 +148,10 @@ const vanillaStyle = `
|
|
|
137
148
|
height: 4px;
|
|
138
149
|
width: 100%;
|
|
139
150
|
margin-bottom: 3px;
|
|
140
|
-
border-bottom: 5px solid
|
|
151
|
+
border-bottom: 5px solid ${props.mobileMenuColor};
|
|
141
152
|
}
|
|
142
153
|
}
|
|
143
154
|
`;
|
|
144
|
-
export function NavigationSidebarView(props, children) {
|
|
145
155
|
return (h("div", { class: "container", part: "sqm-base" },
|
|
146
156
|
h("style", null, vanillaStyle),
|
|
147
157
|
h("input", Object.assign({ type: "checkbox", class: "toggler" }, props)),
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { useCurrentPage, useProgramId, } from "@saasquatch/component-boilerplate";
|
|
1
|
+
import { isDemo, useCurrentPage, useProgramId, } from "@saasquatch/component-boilerplate";
|
|
2
2
|
import { withHooks } from "@saasquatch/stencil-hooks";
|
|
3
3
|
import { useEffect, useState } from "@saasquatch/universal-hooks";
|
|
4
|
-
import { Component, h, State } from "@stencil/core";
|
|
5
|
-
import { NavigationSidebarView } from "./sqm-navigation-sidebar-view";
|
|
4
|
+
import { Component, h, Prop, State } from "@stencil/core";
|
|
5
|
+
import { NavigationSidebarView, } from "./sqm-navigation-sidebar-view";
|
|
6
|
+
import deepmerge from "deepmerge";
|
|
6
7
|
/**
|
|
7
8
|
* @uiName Microsite Sidebar
|
|
8
9
|
* @validParents ["div","sqm-divided-layout","template","sqm-portal-container","sqm-brand"]
|
|
@@ -12,21 +13,92 @@ import { NavigationSidebarView } from "./sqm-navigation-sidebar-view";
|
|
|
12
13
|
export class NavigationSidebar {
|
|
13
14
|
constructor() {
|
|
14
15
|
this.ignored = true;
|
|
16
|
+
/**
|
|
17
|
+
* @uiName Text color
|
|
18
|
+
* @uiWidget color
|
|
19
|
+
* @format color
|
|
20
|
+
* @uiGroup Style
|
|
21
|
+
*/
|
|
22
|
+
this.mobileMenuColor = "var(--sqm-text, #444445)";
|
|
15
23
|
withHooks(this);
|
|
16
24
|
}
|
|
17
25
|
disconnectedCallback() { }
|
|
18
26
|
render() {
|
|
19
|
-
const props =
|
|
27
|
+
const props = isDemo()
|
|
28
|
+
? useDemoNavigationSidebar(this)
|
|
29
|
+
: useNavigationSidebar(this);
|
|
20
30
|
return (h(NavigationSidebarView, Object.assign({}, props),
|
|
21
31
|
h("slot", null)));
|
|
22
32
|
}
|
|
23
33
|
static get is() { return "sqm-navigation-sidebar"; }
|
|
24
34
|
static get encapsulation() { return "shadow"; }
|
|
35
|
+
static get properties() { return {
|
|
36
|
+
"mobileMenuColor": {
|
|
37
|
+
"type": "string",
|
|
38
|
+
"mutable": false,
|
|
39
|
+
"complexType": {
|
|
40
|
+
"original": "string",
|
|
41
|
+
"resolved": "string",
|
|
42
|
+
"references": {}
|
|
43
|
+
},
|
|
44
|
+
"required": false,
|
|
45
|
+
"optional": true,
|
|
46
|
+
"docs": {
|
|
47
|
+
"tags": [{
|
|
48
|
+
"text": "Text color",
|
|
49
|
+
"name": "uiName"
|
|
50
|
+
}, {
|
|
51
|
+
"text": "color",
|
|
52
|
+
"name": "uiWidget"
|
|
53
|
+
}, {
|
|
54
|
+
"text": "color",
|
|
55
|
+
"name": "format"
|
|
56
|
+
}, {
|
|
57
|
+
"text": "Style",
|
|
58
|
+
"name": "uiGroup"
|
|
59
|
+
}],
|
|
60
|
+
"text": ""
|
|
61
|
+
},
|
|
62
|
+
"attribute": "mobile-menu-color",
|
|
63
|
+
"reflect": false,
|
|
64
|
+
"defaultValue": "\"var(--sqm-text, #444445)\""
|
|
65
|
+
},
|
|
66
|
+
"demoData": {
|
|
67
|
+
"type": "unknown",
|
|
68
|
+
"mutable": false,
|
|
69
|
+
"complexType": {
|
|
70
|
+
"original": "DemoData<NavigationSidebarViewProps>",
|
|
71
|
+
"resolved": "{ onClick?: (e: MouseEvent) => void; checked?: boolean; mobileMenuColor?: string; }",
|
|
72
|
+
"references": {
|
|
73
|
+
"DemoData": {
|
|
74
|
+
"location": "import",
|
|
75
|
+
"path": "../../global/demo"
|
|
76
|
+
},
|
|
77
|
+
"NavigationSidebarViewProps": {
|
|
78
|
+
"location": "import",
|
|
79
|
+
"path": "./sqm-navigation-sidebar-view"
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
},
|
|
83
|
+
"required": false,
|
|
84
|
+
"optional": true,
|
|
85
|
+
"docs": {
|
|
86
|
+
"tags": [{
|
|
87
|
+
"text": undefined,
|
|
88
|
+
"name": "undocumented"
|
|
89
|
+
}, {
|
|
90
|
+
"text": "object",
|
|
91
|
+
"name": "uiType"
|
|
92
|
+
}],
|
|
93
|
+
"text": ""
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
}; }
|
|
25
97
|
static get states() { return {
|
|
26
98
|
"ignored": {}
|
|
27
99
|
}; }
|
|
28
100
|
}
|
|
29
|
-
function useNavigationSidebar() {
|
|
101
|
+
function useNavigationSidebar(props) {
|
|
30
102
|
const location = useCurrentPage();
|
|
31
103
|
const programId = useProgramId();
|
|
32
104
|
const [checked, setChecked] = useState(false);
|
|
@@ -38,7 +110,13 @@ function useNavigationSidebar() {
|
|
|
38
110
|
setChecked(e.target.checked);
|
|
39
111
|
}
|
|
40
112
|
return {
|
|
113
|
+
mobileMenuColor: props.mobileMenuColor,
|
|
41
114
|
checked,
|
|
42
115
|
onClick,
|
|
43
116
|
};
|
|
44
117
|
}
|
|
118
|
+
function useDemoNavigationSidebar(props) {
|
|
119
|
+
return deepmerge({
|
|
120
|
+
mobileMenuColor: props.mobileMenuColor,
|
|
121
|
+
}, props.demoData || {}, { arrayMerge: (_, a) => a });
|
|
122
|
+
}
|
package/dist/collection/components/sqm-navigation-sidebar-item/sqm-navigation-sidebar-item-view.js
CHANGED
|
@@ -4,21 +4,32 @@ import { gap } from "../../global/mixins";
|
|
|
4
4
|
import { navigation } from "@saasquatch/component-boilerplate";
|
|
5
5
|
export function NavigationSidebarItemView(props) {
|
|
6
6
|
const { states, data } = props;
|
|
7
|
+
const backgroundColor = props.backgroundColor || "var(--sqm-portal-background)";
|
|
8
|
+
const backgroundHoverColor = props.backgroundHoverColor || "var(--sl-color-gray-50)";
|
|
9
|
+
const backgroundFocusedColor = props.backgroundFocusedColor || "var(--sl-color-gray-200)";
|
|
10
|
+
const textFocusedColor = props.textFocusedColor || "var(--sqm-text)";
|
|
7
11
|
const style = {
|
|
8
12
|
ItemContainer: {
|
|
9
13
|
display: "flex",
|
|
10
|
-
"background-color": `${states.active ?
|
|
11
|
-
|
|
12
|
-
|
|
14
|
+
"background-color": `${states.active ? backgroundFocusedColor : backgroundColor}`,
|
|
15
|
+
borderRadius: props.borderRadius
|
|
16
|
+
? `${props.borderRadius}px`
|
|
17
|
+
: "var(--sl-border-radius-large)",
|
|
18
|
+
padding: `var(--sl-spacing-${props.padding})`,
|
|
13
19
|
"text-decoration": "none",
|
|
14
|
-
color:
|
|
20
|
+
color: states.active
|
|
21
|
+
? textFocusedColor
|
|
22
|
+
: props.textColor || "var(--sqm-text)",
|
|
15
23
|
"align-items": "center",
|
|
16
24
|
...gap({ direction: "row", size: "var(--sl-font-size-small)" }),
|
|
17
25
|
"&:hover": {
|
|
18
26
|
cursor: "pointer",
|
|
19
27
|
background: states.active
|
|
20
|
-
?
|
|
21
|
-
:
|
|
28
|
+
? backgroundFocusedColor
|
|
29
|
+
: backgroundHoverColor,
|
|
30
|
+
color: states.active
|
|
31
|
+
? textFocusedColor
|
|
32
|
+
: props.textHoverColor || "var(--sqm-text)",
|
|
22
33
|
},
|
|
23
34
|
},
|
|
24
35
|
Label: {
|