@saasquatch/mint-components 1.5.0-113 → 1.5.0-117
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/CHANGELOG.md +82 -15
- package/dist/cjs/{GenericTableView-f947b749.js → GenericTableView-ed381b89.js} +7 -6
- package/dist/cjs/{ShadowViewAddon-79dd6c07.js → ShadowViewAddon-60ca6e6c.js} +242 -179
- package/dist/cjs/{global-633d1fb7.js → global-13123238.js} +1 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/mint-components.cjs.js +2 -2
- package/dist/cjs/{sqm-big-stat_30.cjs.entry.js → sqm-big-stat_31.cjs.entry.js} +198 -154
- package/dist/cjs/sqm-empty_5.cjs.entry.js +3 -2
- package/dist/cjs/{sqm-hero-view-a13795c0.js → sqm-hero-view-3b0d45d0.js} +1 -0
- package/dist/cjs/sqm-hero.cjs.entry.js +1 -1
- package/dist/cjs/sqm-leaderboard-rank.cjs.entry.js +1 -1
- package/dist/cjs/{sqm-portal-container-view-d101032e.js → sqm-portal-container-view-5ea913a8.js} +2 -1
- package/dist/cjs/{sqm-portal-email-verification-view-c32a55d6.js → sqm-portal-email-verification-view-535ae80c.js} +2 -2
- package/dist/cjs/sqm-portal-email-verification.cjs.entry.js +3 -3
- package/dist/cjs/{sqm-portal-footer-view-cac67bc9.js → sqm-portal-footer-view-3c62d7a6.js} +1 -1
- package/dist/cjs/sqm-portal-footer.cjs.entry.js +2 -2
- package/dist/cjs/{sqm-portal-forgot-password-view-10c0b54f.js → sqm-portal-forgot-password-view-02b046e1.js} +1 -1
- package/dist/cjs/sqm-portal-forgot-password.cjs.entry.js +2 -2
- package/dist/cjs/{sqm-portal-profile-view-72c40619.js → sqm-portal-profile-view-12c9cd73.js} +3 -3
- package/dist/cjs/sqm-portal-profile.cjs.entry.js +4 -4
- package/dist/cjs/{sqm-portal-reset-password-view-1fdc957e.js → sqm-portal-reset-password-view-20df8d45.js} +1 -1
- package/dist/cjs/sqm-portal-reset-password.cjs.entry.js +2 -2
- package/dist/cjs/{sqm-portal-section-view-186a5f7e.js → sqm-portal-section-view-f3c8475a.js} +1 -0
- package/dist/cjs/{sqm-portal-verify-email-view-4c78e231.js → sqm-portal-verify-email-view-1b07a1ba.js} +1 -1
- package/dist/cjs/sqm-portal-verify-email.cjs.entry.js +2 -2
- package/dist/cjs/sqm-referral-table_11.cjs.entry.js +27 -10
- package/dist/cjs/sqm-rewards-table-customer-note-cell.cjs.entry.js +1 -1
- package/dist/cjs/sqm-rewards-table_9.cjs.entry.js +37 -21
- package/dist/cjs/sqm-stencilbook.cjs.entry.js +252 -115
- package/dist/cjs/sqm-text-span-view-c54af22c.js +59 -0
- package/dist/cjs/sqm-text-span.cjs.entry.js +1 -1
- package/dist/collection/components/sqm-big-stat/UseBigStat.stories.js +15 -3
- package/dist/collection/components/sqm-big-stat/sqm-big-stat-view.js +1 -0
- package/dist/collection/components/sqm-big-stat/sqm-big-stat.js +3 -3
- package/dist/collection/components/sqm-big-stat/useBigStat.js +1 -1
- package/dist/collection/components/sqm-card-feed/sqm-card-feed-view.js +1 -0
- package/dist/collection/components/sqm-hero/sqm-hero-view.js +1 -0
- package/dist/collection/components/sqm-hero-image/sqm-hero-image-view.js +9 -2
- package/dist/collection/components/sqm-image/sqm-image-view.js +1 -0
- package/dist/collection/components/sqm-leaderboard/UseLeaderboard.stories.js +2 -2
- package/dist/collection/components/sqm-leaderboard/sqm-leaderboard-view.js +0 -5
- package/dist/collection/components/sqm-portal-container/PortalContainer.stories.js +72 -0
- package/dist/collection/components/sqm-portal-container/sqm-portal-container-view.js +2 -1
- package/dist/collection/components/sqm-portal-container/sqm-portal-container.js +26 -0
- package/dist/collection/components/sqm-referral-card/sqm-referral-card-view.js +40 -38
- package/dist/collection/components/sqm-referral-iframe/sqm-referral-iframe-view.js +1 -0
- package/dist/collection/components/sqm-referral-table/ReferralTable.stories.js +1 -1
- package/dist/collection/components/sqm-referral-table/cells/sqm-referral-table-rewards-cell.js +0 -1
- package/dist/collection/components/sqm-referral-table/columns/sqm-referral-table-rewards-column.js +10 -1
- package/dist/collection/components/sqm-referral-table/columns/sqm-referral-table-status-column.js +5 -1
- package/dist/collection/components/sqm-referral-table/sqm-referral-table.js +12 -10
- package/dist/collection/components/sqm-reward-exchange-list/RewardExchangeListData.js +1 -1
- package/dist/collection/components/sqm-reward-exchange-list/sqm-reward-exchange-list-view.js +1 -1
- package/dist/collection/components/sqm-reward-exchange-list/sqm-reward-exchange-list.js +11 -9
- package/dist/collection/components/sqm-rewards-table/RewardsTableCell.stories.js +10 -10
- package/dist/collection/components/sqm-rewards-table/cells/sqm-rewards-table-reward-cell.js +9 -25
- package/dist/collection/components/sqm-rewards-table/columns/sqm-rewards-table-reward-column.js +7 -27
- package/dist/collection/components/sqm-rewards-table/columns/sqm-rewards-table-source-column.js +3 -0
- package/dist/collection/components/sqm-rewards-table/columns/sqm-rewards-table-status-column.js +1 -1
- package/dist/collection/components/sqm-rewards-table/sqm-rewards-table.js +14 -9
- package/dist/collection/components/sqm-rewards-table/useRewardsTable.js +7 -1
- package/dist/collection/components/sqm-scroll/Scroll.stories.js +14 -23
- package/dist/collection/components/sqm-scroll/sqm-scroll.js +102 -147
- package/dist/collection/components/sqm-share-button/ShareButton.stories.js +8 -8
- package/dist/collection/components/sqm-share-button/sqm-share-button-view.js +29 -29
- package/dist/collection/components/sqm-share-button/sqm-share-button.js +21 -21
- package/dist/collection/components/sqm-share-code/ShareCode.stories.js +2 -2
- package/dist/collection/components/sqm-share-code/sqm-share-code.js +7 -7
- package/dist/collection/components/sqm-share-code/useShareCode.js +1 -1
- package/dist/collection/components/sqm-share-link/ShareLink.stories.js +3 -3
- package/dist/collection/components/sqm-share-link/UseShareLink.stories.js +3 -3
- package/dist/collection/components/sqm-share-link/sqm-share-link-view.js +1 -1
- package/dist/collection/components/sqm-share-link/sqm-share-link.js +4 -4
- package/dist/collection/components/sqm-stat-container/sqm-stat-container-view.js +1 -0
- package/dist/collection/components/sqm-stencilbook/sqm-stencilbook.js +2 -0
- package/dist/collection/components/sqm-tabs/sqm-tabs.js +1 -1
- package/dist/collection/components/sqm-task-card/DetailsView.js +1 -1
- package/dist/collection/components/sqm-task-card/progress-bar/SVGs.js +7 -0
- package/dist/collection/components/sqm-task-card/progress-bar/progress-bar-view.js +52 -50
- package/dist/collection/components/sqm-task-card/sqm-task-card-view.js +18 -10
- package/dist/collection/components/sqm-task-card/sqm-task-card.js +3 -1
- package/dist/collection/components/sqm-text-span/sqm-text-span-view.js +42 -42
- package/dist/collection/components/sqm-timeline/sqm-timeline-entry-view.js +77 -0
- package/dist/collection/components/sqm-timeline/sqm-timeline-entry.js +1 -80
- package/dist/collection/components/sqm-timeline/sqm-timeline.js +0 -18
- package/dist/collection/components/sqm-titled-section/sqm-portal-section-view.js +1 -0
- package/dist/collection/global/styles.js +1 -0
- package/dist/collection/global/styles.ts +1 -0
- package/dist/collection/stories/NewPortal.stories.js +2 -2
- package/dist/collection/stories/PortalTemplates.stories.js +0 -7
- package/dist/collection/stories/Widget.stories.js +49 -0
- package/dist/collection/tables/GenericTableView.js +7 -6
- package/dist/esm/{GenericTableView-6b7b537b.js → GenericTableView-6924630b.js} +7 -6
- package/dist/esm/{ShadowViewAddon-9c382e30.js → ShadowViewAddon-3347acdb.js} +242 -180
- package/dist/esm/{global-7d4eb5e5.js → global-9bff4920.js} +1 -0
- package/dist/esm/loader.js +2 -2
- package/dist/esm/mint-components.js +2 -2
- package/dist/esm/{sqm-big-stat_30.entry.js → sqm-big-stat_31.entry.js} +199 -156
- package/dist/esm/sqm-empty_5.entry.js +3 -2
- package/dist/esm/{sqm-hero-view-5ea17052.js → sqm-hero-view-8e70916e.js} +1 -0
- package/dist/esm/sqm-hero.entry.js +1 -1
- package/dist/esm/sqm-leaderboard-rank.entry.js +1 -1
- package/dist/esm/{sqm-portal-container-view-dea0cdcc.js → sqm-portal-container-view-46929235.js} +2 -1
- package/dist/esm/{sqm-portal-email-verification-view-86e3ff2e.js → sqm-portal-email-verification-view-1d7eca0a.js} +2 -2
- package/dist/esm/sqm-portal-email-verification.entry.js +3 -3
- package/dist/esm/{sqm-portal-footer-view-d6a43c4d.js → sqm-portal-footer-view-df66904d.js} +1 -1
- package/dist/esm/sqm-portal-footer.entry.js +2 -2
- package/dist/esm/{sqm-portal-forgot-password-view-fa088f83.js → sqm-portal-forgot-password-view-6b99a1ad.js} +1 -1
- package/dist/esm/sqm-portal-forgot-password.entry.js +2 -2
- package/dist/esm/{sqm-portal-profile-view-c34e781b.js → sqm-portal-profile-view-b96b89a3.js} +3 -3
- package/dist/esm/sqm-portal-profile.entry.js +4 -4
- package/dist/esm/{sqm-portal-reset-password-view-73e14282.js → sqm-portal-reset-password-view-2c0da51c.js} +1 -1
- package/dist/esm/sqm-portal-reset-password.entry.js +2 -2
- package/dist/esm/{sqm-portal-section-view-88a80af9.js → sqm-portal-section-view-61dbb8a9.js} +1 -0
- package/dist/esm/{sqm-portal-verify-email-view-cbf1cfdc.js → sqm-portal-verify-email-view-0d005914.js} +1 -1
- package/dist/esm/sqm-portal-verify-email.entry.js +2 -2
- package/dist/esm/sqm-referral-table_11.entry.js +27 -10
- package/dist/esm/sqm-rewards-table-customer-note-cell.entry.js +1 -1
- package/dist/esm/sqm-rewards-table_9.entry.js +37 -21
- package/dist/esm/sqm-stencilbook.entry.js +248 -111
- package/dist/esm/sqm-text-span-view-c8793d61.js +57 -0
- package/dist/esm/sqm-text-span.entry.js +1 -1
- package/dist/esm-es5/GenericTableView-6924630b.js +1 -0
- package/dist/esm-es5/ShadowViewAddon-3347acdb.js +1 -0
- package/dist/esm-es5/{global-7d4eb5e5.js → global-9bff4920.js} +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/mint-components.js +1 -1
- package/dist/esm-es5/sqm-big-stat_31.entry.js +1 -0
- package/dist/esm-es5/sqm-empty_5.entry.js +1 -1
- package/dist/esm-es5/{sqm-hero-view-5ea17052.js → sqm-hero-view-8e70916e.js} +0 -0
- package/dist/esm-es5/sqm-hero.entry.js +1 -1
- package/dist/esm-es5/sqm-leaderboard-rank.entry.js +1 -1
- package/dist/esm-es5/sqm-portal-container-view-46929235.js +1 -0
- package/dist/esm-es5/{sqm-portal-email-verification-view-86e3ff2e.js → sqm-portal-email-verification-view-1d7eca0a.js} +1 -1
- package/dist/esm-es5/sqm-portal-email-verification.entry.js +1 -1
- package/dist/esm-es5/{sqm-portal-footer-view-d6a43c4d.js → sqm-portal-footer-view-df66904d.js} +1 -1
- package/dist/esm-es5/sqm-portal-footer.entry.js +1 -1
- package/dist/esm-es5/{sqm-portal-forgot-password-view-fa088f83.js → sqm-portal-forgot-password-view-6b99a1ad.js} +1 -1
- package/dist/esm-es5/sqm-portal-forgot-password.entry.js +1 -1
- package/dist/esm-es5/{sqm-portal-profile-view-c34e781b.js → sqm-portal-profile-view-b96b89a3.js} +1 -1
- package/dist/esm-es5/sqm-portal-profile.entry.js +1 -1
- package/dist/esm-es5/{sqm-portal-reset-password-view-73e14282.js → sqm-portal-reset-password-view-2c0da51c.js} +1 -1
- package/dist/esm-es5/sqm-portal-reset-password.entry.js +1 -1
- package/dist/esm-es5/{sqm-portal-section-view-88a80af9.js → sqm-portal-section-view-61dbb8a9.js} +0 -0
- package/dist/esm-es5/{sqm-portal-verify-email-view-cbf1cfdc.js → sqm-portal-verify-email-view-0d005914.js} +1 -1
- package/dist/esm-es5/sqm-portal-verify-email.entry.js +1 -1
- package/dist/esm-es5/sqm-referral-table_11.entry.js +1 -1
- package/dist/esm-es5/sqm-rewards-table-customer-note-cell.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/p-179988b5.js → esm-es5/sqm-text-span-view-c8793d61.js} +1 -1
- package/dist/esm-es5/sqm-text-span.entry.js +1 -1
- package/dist/mint-components/global/styles.ts +1 -0
- package/dist/mint-components/mint-components.esm.js +1 -1
- package/dist/mint-components/mint-components.js +1 -1
- package/dist/mint-components/{p-e08f5f8e.js → p-00c0fd3c.js} +0 -0
- package/dist/mint-components/{p-49667de1.system.entry.js → p-07b18f4a.system.entry.js} +1 -1
- package/dist/mint-components/{p-f31a3a08.system.entry.js → p-099d949d.system.entry.js} +1 -1
- package/dist/mint-components/{p-ce0ec1c4.system.js → p-1830b02e.system.js} +1 -1
- package/dist/mint-components/p-1e57c649.entry.js +9 -0
- package/dist/mint-components/p-23a3e161.entry.js +1 -0
- package/dist/mint-components/{p-3dbd3303.entry.js → p-258dc62f.entry.js} +1 -1
- package/dist/mint-components/{p-1c3c2ddb.system.js → p-26b42a93.system.js} +1 -1
- package/dist/mint-components/{p-147440c3.js → p-2ec8c64c.js} +0 -0
- package/dist/mint-components/{p-e82076e4.system.js → p-2ef43b0b.system.js} +1 -1
- package/dist/mint-components/{p-91951a0a.system.entry.js → p-3295bcea.system.entry.js} +1 -1
- package/dist/mint-components/{p-d7736049.system.entry.js → p-32b9d246.system.entry.js} +1 -1
- package/dist/mint-components/p-33159b8f.entry.js +99 -0
- package/dist/mint-components/p-39928661.system.entry.js +1 -0
- package/dist/mint-components/{p-96bbb28a.system.entry.js → p-3bb7f637.system.entry.js} +1 -1
- package/dist/mint-components/{p-6b43e4cc.system.js → p-3bf4f950.system.js} +1 -1
- package/dist/mint-components/{p-53af4433.system.js → p-3cf449ba.system.js} +0 -0
- package/dist/mint-components/{p-fe0d7472.entry.js → p-4556231d.entry.js} +1 -1
- package/dist/mint-components/{p-759df017.system.entry.js → p-4fdc7713.system.entry.js} +1 -1
- package/dist/mint-components/{p-6a87a09f.entry.js → p-5c35a4e6.entry.js} +1 -1
- package/dist/mint-components/p-5c71ba83.js +268 -0
- package/dist/mint-components/{p-8d7ae057.system.entry.js → p-60abe71f.system.entry.js} +1 -1
- package/dist/mint-components/p-6660f97d.system.js +1 -0
- package/dist/mint-components/p-6faceb79.system.entry.js +1 -0
- package/dist/mint-components/{p-eb61462d.entry.js → p-710dd330.entry.js} +12 -12
- package/dist/mint-components/{p-1959da16.system.js → p-73e64749.system.js} +1 -1
- package/dist/mint-components/{p-4f4bdfad.system.entry.js → p-79e4c06a.system.entry.js} +1 -1
- package/dist/mint-components/{p-3bdc5918.js → p-7b074331.js} +1 -1
- package/dist/mint-components/{p-4a1b7d35.js → p-7fe7dbb0.js} +1 -1
- package/dist/mint-components/{p-d264d1a0.system.js → p-80845175.system.js} +1 -1
- package/dist/mint-components/{p-200ffff7.entry.js → p-96f571e5.entry.js} +1 -1
- package/dist/mint-components/p-99e7434e.js +1 -0
- package/dist/mint-components/{p-93e15034.entry.js → p-9dee36f6.entry.js} +1 -1
- package/dist/mint-components/{p-16023c39.system.entry.js → p-a35ce12b.system.entry.js} +1 -1
- package/dist/mint-components/{p-2af6bb32.system.entry.js → p-a36892ea.system.entry.js} +1 -1
- package/dist/mint-components/p-a82df645.system.entry.js +1 -0
- package/dist/mint-components/{p-55b6147d.js → p-abc7fa04.js} +1 -1
- package/dist/mint-components/p-ad741ee2.system.entry.js +1 -0
- package/dist/mint-components/p-aebee81d.system.js +1 -0
- package/dist/mint-components/{p-3e65453b.system.js → p-b756428e.system.js} +0 -0
- package/dist/mint-components/{p-1d1e9197.js → p-ba597021.js} +1 -1
- package/dist/mint-components/p-bb630f90.system.js +1 -0
- package/dist/mint-components/p-c887a653.system.js +1 -0
- package/dist/mint-components/{p-d33eb961.js → p-c8cb3674.js} +1 -1
- package/dist/mint-components/{p-20e8567f.entry.js → p-ca696a40.entry.js} +1 -1
- package/dist/mint-components/{p-1204f7df.entry.js → p-cfe3ceb7.entry.js} +1 -1
- package/dist/mint-components/{p-a8141e7b.entry.js → p-d073aead.entry.js} +1 -1
- package/dist/mint-components/p-db46fe90.js +1 -0
- package/dist/mint-components/{p-fcd096b3.entry.js → p-dc0b8fdb.entry.js} +1 -1
- package/dist/mint-components/{p-ce8b1b36.system.js → p-e2cb443e.system.js} +1 -1
- package/dist/mint-components/{p-72a798c3.entry.js → p-e3fff405.entry.js} +1 -1
- package/dist/mint-components/p-ec5633b8.js +1 -0
- package/dist/mint-components/p-ec77261d.system.js +1 -0
- package/dist/mint-components/{p-e57bb617.entry.js → p-ee1684ae.entry.js} +1 -1
- package/dist/mint-components/{p-c5314bbc.js → p-eff88c3d.js} +1 -1
- package/dist/mint-components/p-f34dd1c1.js +1 -0
- package/dist/mint-components/{p-72296718.system.entry.js → p-f72dc3a5.system.entry.js} +1 -1
- package/dist/types/components/sqm-big-stat/UseBigStat.stories.d.ts +24 -0
- package/dist/types/components/sqm-portal-container/PortalContainer.stories.d.ts +6 -0
- package/dist/types/components/sqm-portal-container/sqm-portal-container-view.d.ts +1 -0
- package/dist/types/components/sqm-portal-container/sqm-portal-container.d.ts +6 -0
- package/dist/types/components/sqm-referral-table/sqm-referral-table.d.ts +2 -3
- package/dist/types/components/sqm-reward-exchange-list/RewardExchangeListData.d.ts +19 -19
- package/dist/types/components/sqm-reward-exchange-list/sqm-reward-exchange-list-view.d.ts +1 -1
- package/dist/types/components/sqm-reward-exchange-list/sqm-reward-exchange-list.d.ts +6 -4
- package/dist/types/components/sqm-reward-exchange-list/useRewardExchangeList.d.ts +1 -1
- package/dist/types/components/sqm-rewards-table/cells/sqm-rewards-table-reward-cell.d.ts +0 -1
- package/dist/types/components/sqm-rewards-table/columns/sqm-rewards-table-reward-column.d.ts +0 -4
- package/dist/types/components/sqm-rewards-table/sqm-rewards-table.d.ts +7 -4
- package/dist/types/components/sqm-scroll/Scroll.stories.d.ts +1 -0
- package/dist/types/components/sqm-scroll/sqm-scroll.d.ts +56 -8
- package/dist/types/components/sqm-share-button/sqm-share-button-view.d.ts +6 -6
- package/dist/types/components/sqm-share-button/sqm-share-button.d.ts +9 -9
- package/dist/types/components/sqm-share-code/sqm-share-code.d.ts +2 -2
- package/dist/types/components/sqm-share-code/useShareCode.d.ts +2 -2
- package/dist/types/components/sqm-share-link/sqm-share-link-view.d.ts +1 -1
- package/dist/types/components/sqm-share-link/sqm-share-link.d.ts +1 -1
- package/dist/types/components/sqm-share-link/useShareLink.d.ts +1 -1
- package/dist/types/components/sqm-tabs/sqm-tabs.d.ts +1 -1
- package/dist/types/components/sqm-task-card/progress-bar/SVGs.d.ts +1 -0
- package/dist/types/components/sqm-task-card/progress-bar/progress-bar-view.d.ts +1 -0
- package/dist/types/components/sqm-task-card/sqm-task-card.d.ts +2 -0
- package/dist/types/components/sqm-timeline/sqm-timeline-entry-view.d.ts +9 -0
- package/dist/types/components.d.ts +172 -78
- package/dist/types/global/styles.d.ts +1 -1
- package/dist/types/stories/Widget.stories.d.ts +22 -0
- package/grapesjs/grapesjs.js +1 -1
- package/package.json +1 -1
- package/dist/cjs/sqm-stat-container-view-8aaf6cb8.js +0 -52
- package/dist/cjs/sqm-stat-container.cjs.entry.js +0 -36
- package/dist/cjs/sqm-text-span-view-f101dedf.js +0 -59
- package/dist/esm/sqm-stat-container-view-226b6496.js +0 -50
- package/dist/esm/sqm-stat-container.entry.js +0 -32
- package/dist/esm/sqm-text-span-view-7e61c95c.js +0 -57
- package/dist/esm-es5/GenericTableView-6b7b537b.js +0 -1
- package/dist/esm-es5/ShadowViewAddon-9c382e30.js +0 -1
- package/dist/esm-es5/sqm-big-stat_30.entry.js +0 -1
- package/dist/esm-es5/sqm-portal-container-view-dea0cdcc.js +0 -1
- package/dist/esm-es5/sqm-stat-container-view-226b6496.js +0 -1
- package/dist/esm-es5/sqm-stat-container.entry.js +0 -1
- package/dist/esm-es5/sqm-text-span-view-7e61c95c.js +0 -1
- package/dist/mint-components/p-1a786c17.js +0 -1
- package/dist/mint-components/p-1b71a09e.system.entry.js +0 -1
- package/dist/mint-components/p-1cd23e56.system.entry.js +0 -1
- package/dist/mint-components/p-2c5d7a20.js +0 -268
- package/dist/mint-components/p-3f88f8eb.system.js +0 -1
- package/dist/mint-components/p-45581e0b.entry.js +0 -9
- package/dist/mint-components/p-48161ba8.js +0 -1
- package/dist/mint-components/p-4e0ce80b.js +0 -1
- package/dist/mint-components/p-546ee840.entry.js +0 -1
- package/dist/mint-components/p-55f3d841.system.js +0 -1
- package/dist/mint-components/p-78df4d2d.system.js +0 -1
- package/dist/mint-components/p-8bcaafaf.system.js +0 -1
- package/dist/mint-components/p-9e4f0169.system.entry.js +0 -1
- package/dist/mint-components/p-a44b64d5.js +0 -1
- package/dist/mint-components/p-ac303785.system.js +0 -1
- package/dist/mint-components/p-b359d5a5.entry.js +0 -1
- package/dist/mint-components/p-bb497e73.entry.js +0 -93
- package/dist/mint-components/p-c5086d90.system.js +0 -1
- package/dist/mint-components/p-e16186c0.system.entry.js +0 -1
- package/dist/mint-components/p-e2731437.system.entry.js +0 -1
|
@@ -1,51 +1,51 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
2
|
import { createStyleSheet } from "../../styling/JSS";
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
const vanillaStyle = `
|
|
3
|
+
const style = {
|
|
4
|
+
p: {
|
|
5
|
+
"font-size": "var(--sl-font-size-small)",
|
|
6
|
+
"font-weight": "400",
|
|
7
|
+
color: "var(--sl-color-gray-800)",
|
|
8
|
+
margin: "0",
|
|
9
|
+
},
|
|
10
|
+
subtext: {
|
|
11
|
+
"font-size": "var(--sl-font-size-x-small)",
|
|
12
|
+
"font-weight": "400",
|
|
13
|
+
color: "var(--sl-color-gray-600)",
|
|
14
|
+
margin: "0",
|
|
15
|
+
},
|
|
16
|
+
h1: {
|
|
17
|
+
"font-size": "var(--sl-font-size-xx-large)",
|
|
18
|
+
"font-weight": "600",
|
|
19
|
+
color: "var(--sl-color-gray-800)",
|
|
20
|
+
margin: "0",
|
|
21
|
+
},
|
|
22
|
+
h2: {
|
|
23
|
+
"font-size": "var(--sl-font-size-x-large)",
|
|
24
|
+
"font-weight": "600",
|
|
25
|
+
color: "var(--sl-color-gray-800)",
|
|
26
|
+
margin: "0",
|
|
27
|
+
},
|
|
28
|
+
h3: {
|
|
29
|
+
"font-size": "var(--sl-font-size-large)",
|
|
30
|
+
"font-weight": "600",
|
|
31
|
+
color: "var(--sl-color-gray-800)",
|
|
32
|
+
margin: "0",
|
|
33
|
+
},
|
|
34
|
+
h4: {
|
|
35
|
+
"font-size": "13px",
|
|
36
|
+
"font-weight": "600",
|
|
37
|
+
color: "var(--sl-color-gray-800)",
|
|
38
|
+
margin: "0",
|
|
39
|
+
},
|
|
40
|
+
};
|
|
41
|
+
const sheet = createStyleSheet(style);
|
|
42
|
+
const styleString = sheet.toString();
|
|
43
|
+
const vanillaStyle = `
|
|
45
44
|
sqm-text-span {
|
|
46
45
|
display: inline;
|
|
47
46
|
}
|
|
48
47
|
`;
|
|
48
|
+
export function TextSpanView(props, children) {
|
|
49
49
|
return (h("span", { class: sheet.classes[props.type] },
|
|
50
50
|
h("style", { type: "text/css" },
|
|
51
51
|
vanillaStyle,
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { h } from "@stencil/core";
|
|
2
|
+
import { createStyleSheet } from "../../styling/JSS";
|
|
3
|
+
import { Circle, Gift } from "./SVGs";
|
|
4
|
+
const style = {
|
|
5
|
+
TimelineReward: {
|
|
6
|
+
color: "var(--sl-color-neutral-900)",
|
|
7
|
+
lineHeight: "var(--sl-line-height-dense)",
|
|
8
|
+
"& .container": {
|
|
9
|
+
display: "flex",
|
|
10
|
+
},
|
|
11
|
+
"& .line": {
|
|
12
|
+
display: "none",
|
|
13
|
+
color: "transparent",
|
|
14
|
+
userSelect: "none",
|
|
15
|
+
background: "var(--sl-color-primary-300)",
|
|
16
|
+
width: "4px",
|
|
17
|
+
borderRadius: "4px",
|
|
18
|
+
margin: "-2px",
|
|
19
|
+
position: "relative",
|
|
20
|
+
left: "12px",
|
|
21
|
+
top: "34px",
|
|
22
|
+
},
|
|
23
|
+
"& .step": {
|
|
24
|
+
display: "flex",
|
|
25
|
+
},
|
|
26
|
+
"& .icon": {
|
|
27
|
+
position: "relative",
|
|
28
|
+
top: "4px",
|
|
29
|
+
zIndex: "1",
|
|
30
|
+
color: "var(--sl-color-primary-300)",
|
|
31
|
+
marginRight: "var(--sl-spacing-large)",
|
|
32
|
+
},
|
|
33
|
+
"& .reward": {
|
|
34
|
+
marginRight: "var(--sl-spacing-x-small)",
|
|
35
|
+
fontSize: "var(--sl-font-size-x-large)",
|
|
36
|
+
fontWeight: "var(--sl-font-weight-semibold)",
|
|
37
|
+
},
|
|
38
|
+
"& .unit": {
|
|
39
|
+
textTransform: "uppercase",
|
|
40
|
+
fontSize: "var(--sl-font-size-small)",
|
|
41
|
+
},
|
|
42
|
+
"& .description": {
|
|
43
|
+
fontSize: "var(--sl-font-size-medium)",
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
};
|
|
47
|
+
const sheet = createStyleSheet(style);
|
|
48
|
+
const styleString = sheet.toString();
|
|
49
|
+
const vanillaStyle = `
|
|
50
|
+
:host{
|
|
51
|
+
display: block;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
:host(:not(:last-of-type)) .line {
|
|
55
|
+
display: block;
|
|
56
|
+
}
|
|
57
|
+
`;
|
|
58
|
+
export function TimelineEntryView(props) {
|
|
59
|
+
var _a;
|
|
60
|
+
const timeline_icon = (_a = props.icon) !== null && _a !== void 0 ? _a : props.iconState;
|
|
61
|
+
return (h("div", { class: sheet.classes.TimelineReward },
|
|
62
|
+
h("style", { type: "text/css" },
|
|
63
|
+
styleString,
|
|
64
|
+
vanillaStyle),
|
|
65
|
+
h("div", { class: "container" },
|
|
66
|
+
h("div", { class: "line" }, "/"),
|
|
67
|
+
h("div", { class: "step" },
|
|
68
|
+
timeline_icon === "gift" && (h("div", { class: "icon" },
|
|
69
|
+
h(Gift, null))),
|
|
70
|
+
timeline_icon === "circle" && (h("div", { class: "icon" },
|
|
71
|
+
h(Circle, null))),
|
|
72
|
+
h("div", null,
|
|
73
|
+
h("div", null,
|
|
74
|
+
h("span", { class: "reward" }, props.reward),
|
|
75
|
+
h("span", { class: "unit" }, props.unit)),
|
|
76
|
+
h("div", { class: "description" }, props.desc))))));
|
|
77
|
+
}
|
|
@@ -1,19 +1,14 @@
|
|
|
1
1
|
import { withHooks } from "@saasquatch/stencil-hooks";
|
|
2
2
|
import { Component, h, Method, Prop, State } from "@stencil/core";
|
|
3
|
-
import { createStyleSheet } from "../../styling/JSS";
|
|
4
3
|
import { useRequestRerender } from "../../tables/re-render";
|
|
5
4
|
import { getProps } from "../../utils/utils";
|
|
6
|
-
import {
|
|
5
|
+
import { TimelineEntryView } from "./sqm-timeline-entry-view";
|
|
7
6
|
/**
|
|
8
7
|
* @uiName Timeline Entry
|
|
9
8
|
*/
|
|
10
9
|
export class TimelineReward {
|
|
11
10
|
constructor() {
|
|
12
11
|
this.ignored = true;
|
|
13
|
-
// @State() line: boolean = false;
|
|
14
|
-
// @Method() async setLine(value: boolean) {
|
|
15
|
-
// this.line = value;
|
|
16
|
-
// }
|
|
17
12
|
this.iconState = "gift";
|
|
18
13
|
withHooks(this);
|
|
19
14
|
}
|
|
@@ -141,77 +136,3 @@ export class TimelineReward {
|
|
|
141
136
|
}
|
|
142
137
|
}; }
|
|
143
138
|
}
|
|
144
|
-
function TimelineEntryView(props) {
|
|
145
|
-
var _a;
|
|
146
|
-
const style = {
|
|
147
|
-
TimelineReward: {
|
|
148
|
-
color: "var(--sl-color-neutral-900)",
|
|
149
|
-
lineHeight: "var(--sl-line-height-dense)",
|
|
150
|
-
"& .container": {
|
|
151
|
-
display: "flex",
|
|
152
|
-
},
|
|
153
|
-
"& .line": {
|
|
154
|
-
display: "none",
|
|
155
|
-
color: "transparent",
|
|
156
|
-
userSelect: "none",
|
|
157
|
-
background: "var(--sl-color-primary-300)",
|
|
158
|
-
width: "4px",
|
|
159
|
-
borderRadius: "4px",
|
|
160
|
-
margin: "-2px",
|
|
161
|
-
position: "relative",
|
|
162
|
-
left: "12px",
|
|
163
|
-
top: "34px",
|
|
164
|
-
},
|
|
165
|
-
"& .step": {
|
|
166
|
-
display: "flex",
|
|
167
|
-
},
|
|
168
|
-
"& .icon": {
|
|
169
|
-
position: "relative",
|
|
170
|
-
top: "4px",
|
|
171
|
-
zIndex: "1",
|
|
172
|
-
color: "var(--sl-color-primary-300)",
|
|
173
|
-
marginRight: "var(--sl-spacing-large)",
|
|
174
|
-
},
|
|
175
|
-
"& .reward": {
|
|
176
|
-
marginRight: "var(--sl-spacing-x-small)",
|
|
177
|
-
fontSize: "var(--sl-font-size-x-large)",
|
|
178
|
-
fontWeight: "var(--sl-font-weight-semibold)",
|
|
179
|
-
},
|
|
180
|
-
"& .unit": {
|
|
181
|
-
textTransform: "uppercase",
|
|
182
|
-
fontSize: "var(--sl-font-size-small)",
|
|
183
|
-
},
|
|
184
|
-
"& .description": {
|
|
185
|
-
fontSize: "var(--sl-font-size-medium)",
|
|
186
|
-
},
|
|
187
|
-
},
|
|
188
|
-
};
|
|
189
|
-
const sheet = createStyleSheet(style);
|
|
190
|
-
const styleString = sheet.toString();
|
|
191
|
-
const vanillaStyle = `
|
|
192
|
-
:host{
|
|
193
|
-
display: block;
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
:host(:not(:last-child)) .line {
|
|
197
|
-
display: block;
|
|
198
|
-
}
|
|
199
|
-
`;
|
|
200
|
-
const timeline_icon = (_a = props.icon) !== null && _a !== void 0 ? _a : props.iconState;
|
|
201
|
-
return (h("div", { class: sheet.classes.TimelineReward },
|
|
202
|
-
h("style", { type: "text/css" },
|
|
203
|
-
styleString,
|
|
204
|
-
vanillaStyle),
|
|
205
|
-
h("div", { class: "container" },
|
|
206
|
-
h("div", { class: "line" }, "/"),
|
|
207
|
-
h("div", { class: "step" },
|
|
208
|
-
timeline_icon === "gift" && (h("div", { class: "icon" },
|
|
209
|
-
h(Gift, null))),
|
|
210
|
-
timeline_icon === "circle" && (h("div", { class: "icon" },
|
|
211
|
-
h(Circle, null))),
|
|
212
|
-
h("div", null,
|
|
213
|
-
h("div", null,
|
|
214
|
-
h("span", { class: "reward" }, props.reward),
|
|
215
|
-
h("span", { class: "unit" }, props.unit)),
|
|
216
|
-
h("div", { class: "description" }, props.desc))))));
|
|
217
|
-
}
|
|
@@ -35,24 +35,6 @@ export class Timeline {
|
|
|
35
35
|
::slotted(*:not(:only-child):not(:last-child)) {
|
|
36
36
|
margin-bottom: var(--sl-spacing-xx-large);
|
|
37
37
|
}
|
|
38
|
-
|
|
39
|
-
// ::slotted(*:not(:only-child):not(:first-child)) * {
|
|
40
|
-
// background: yellow;
|
|
41
|
-
// }
|
|
42
|
-
|
|
43
|
-
// ::slotted(*:not(:only-child):not(:first-child))::before {
|
|
44
|
-
// display: block;
|
|
45
|
-
// content: "";
|
|
46
|
-
// position: relative;
|
|
47
|
-
// height: 65px;
|
|
48
|
-
// width: 4px;
|
|
49
|
-
// top: -15px;
|
|
50
|
-
// left: 50px;
|
|
51
|
-
// margin-top: -44px;
|
|
52
|
-
// margin-bottom: -15px;
|
|
53
|
-
// border-radius: 4px;
|
|
54
|
-
// background: red;
|
|
55
|
-
// }
|
|
56
38
|
`;
|
|
57
39
|
return (h("div", null,
|
|
58
40
|
h("style", { type: "text/css" }, vanillaStyle),
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
2
|
import { createStyleSheet } from "../../styling/JSS";
|
|
3
3
|
export function PortalSectionView(props) {
|
|
4
|
+
// Due to sole usage of props, not feasiable to move out of render function
|
|
4
5
|
const style = {
|
|
5
6
|
LabelContainer: {
|
|
6
7
|
"margin-bottom": props.labelMargin === "none"
|
|
@@ -466,6 +466,7 @@ html {
|
|
|
466
466
|
--sl-shadow-large: 0 2px 8px #0d131e1a;
|
|
467
467
|
--sl-shadow-x-large: 0 4px 16px #0d131e1a;
|
|
468
468
|
/** LV: Could use the Anvil spacing rules, but probably not necessary **/
|
|
469
|
+
--sl-spacing-none: 0rem;
|
|
469
470
|
--sl-spacing-xxx-small: 0.125rem;
|
|
470
471
|
--sl-spacing-xx-small: 0.25rem;
|
|
471
472
|
--sl-spacing-x-small: 0.5rem;
|
|
@@ -467,6 +467,7 @@ html {
|
|
|
467
467
|
--sl-shadow-large: 0 2px 8px #0d131e1a;
|
|
468
468
|
--sl-shadow-x-large: 0 4px 16px #0d131e1a;
|
|
469
469
|
/** LV: Could use the Anvil spacing rules, but probably not necessary **/
|
|
470
|
+
--sl-spacing-none: 0rem;
|
|
470
471
|
--sl-spacing-xxx-small: 0.125rem;
|
|
471
472
|
--sl-spacing-xx-small: 0.25rem;
|
|
472
473
|
--sl-spacing-x-small: 0.5rem;
|
|
@@ -65,14 +65,14 @@ export const Dashboard = () => {
|
|
|
65
65
|
shareString: "https://ssqt.co/johnsmithrox",
|
|
66
66
|
open: false,
|
|
67
67
|
disabled: false,
|
|
68
|
-
|
|
68
|
+
tooltipText: "Share link copied",
|
|
69
69
|
onClick: () => console.log("Share link copied"),
|
|
70
70
|
};
|
|
71
71
|
const sharecodeProps = {
|
|
72
72
|
shareString: "JOHNSMITH1",
|
|
73
73
|
open: false,
|
|
74
74
|
disabled: false,
|
|
75
|
-
|
|
75
|
+
tooltipText: "Share code copied",
|
|
76
76
|
onClick: () => console.log("Share code copied"),
|
|
77
77
|
};
|
|
78
78
|
const twitterButtonProps = {
|
|
@@ -32,13 +32,6 @@ import { navigation } from "@saasquatch/component-boilerplate";
|
|
|
32
32
|
export default {
|
|
33
33
|
title: "Templates / Portal",
|
|
34
34
|
};
|
|
35
|
-
// slot="footer"
|
|
36
|
-
// support-email="john@foodservicerewards.com"
|
|
37
|
-
// terms-link="example.com"
|
|
38
|
-
// faq-link="example.com"
|
|
39
|
-
// padding="large"
|
|
40
|
-
// show-powered-by="false"
|
|
41
|
-
// powered-by-link="https://www.saasquatch.com/"
|
|
42
35
|
function useTemplate(templateString) {
|
|
43
36
|
const [editedTemplate, setEditedTemplate] = useState(templateString);
|
|
44
37
|
const [previewTemplate, setPreviewTemplate] = useState(templateString);
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { useState } from "@saasquatch/universal-hooks";
|
|
2
|
+
import { h } from "@stencil/core";
|
|
3
|
+
import { createHookStory } from "../components/sqm-stencilbook/HookStoryAddon";
|
|
4
|
+
import referralWidget from "../templates/ReferralWidget.html";
|
|
5
|
+
import monoWidget from "../templates/MonoWidget.html";
|
|
6
|
+
import loyaltyWidget from "../templates/LoyaltyWidget.html";
|
|
7
|
+
export default {
|
|
8
|
+
title: "Templates / Widgets",
|
|
9
|
+
};
|
|
10
|
+
// slot="footer"
|
|
11
|
+
// support-email="john@foodservicerewards.com"
|
|
12
|
+
// terms-link="example.com"
|
|
13
|
+
// faq-link="example.com"
|
|
14
|
+
// padding="large"
|
|
15
|
+
// show-powered-by="false"
|
|
16
|
+
// powered-by-link="https://www.saasquatch.com/"
|
|
17
|
+
function useTemplate(templateString) {
|
|
18
|
+
const [editedTemplate, setEditedTemplate] = useState(templateString);
|
|
19
|
+
const [previewTemplate, setPreviewTemplate] = useState(templateString);
|
|
20
|
+
return {
|
|
21
|
+
states: { previewTemplate, editedTemplate },
|
|
22
|
+
callbacks: { setEditedTemplate, setPreviewTemplate },
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
function Buttons({ callbacks, states, template }) {
|
|
26
|
+
return (h("div", null,
|
|
27
|
+
h("button", { onClick: () => callbacks.setPreviewTemplate(states.editedTemplate) }, "Update Preview"),
|
|
28
|
+
h("button", { style: { marginLeft: "10px" }, onClick: () => callbacks.setPreviewTemplate(template) }, "Preview Dashboard")));
|
|
29
|
+
}
|
|
30
|
+
function DefaultTemplateView(props) {
|
|
31
|
+
const { states, callbacks } = props;
|
|
32
|
+
return (h("div", { style: { height: "50vh" } },
|
|
33
|
+
h("textarea", { style: { width: "100%", height: "300px" }, onChange: (e) => callbacks.setEditedTemplate(e.target.value) }, states.editedTemplate),
|
|
34
|
+
h(Buttons, { states: states, callbacks: callbacks, template: props.template }),
|
|
35
|
+
h("br", null),
|
|
36
|
+
h("div", { innerHTML: states.previewTemplate })));
|
|
37
|
+
}
|
|
38
|
+
export const ReferralWidget = createHookStory(() => {
|
|
39
|
+
const { states, callbacks } = useTemplate(referralWidget);
|
|
40
|
+
return (h(DefaultTemplateView, { states: states, callbacks: callbacks, template: referralWidget }));
|
|
41
|
+
});
|
|
42
|
+
export const MonoWidget = createHookStory(() => {
|
|
43
|
+
const { states, callbacks } = useTemplate(monoWidget);
|
|
44
|
+
return (h(DefaultTemplateView, { states: states, callbacks: callbacks, template: monoWidget }));
|
|
45
|
+
});
|
|
46
|
+
export const Loyalty = createHookStory(() => {
|
|
47
|
+
const { states, callbacks } = useTemplate(loyaltyWidget);
|
|
48
|
+
return (h(DefaultTemplateView, { states: states, callbacks: callbacks, template: loyaltyWidget }));
|
|
49
|
+
});
|
|
@@ -8,9 +8,9 @@ export function GenericTableView(props) {
|
|
|
8
8
|
const hiddenCols = data.hiddenColumns && data.hiddenColumns.split(",").map(Number);
|
|
9
9
|
const mobile = "@media (max-width: " + data.mdBreakpoint + "px)";
|
|
10
10
|
const tablet = `@media (min-width: ${Boolean(rows.length < 2) ? data.mdBreakpoint : data.smBreakpoint}px) and (max-width: ${data.mdBreakpoint}px)`;
|
|
11
|
+
// Due to mobile media queries being dependant on props, not feasiable to move out of render function
|
|
11
12
|
const style = {
|
|
12
13
|
Table: {
|
|
13
|
-
// borderCollapse: "collapse",
|
|
14
14
|
tableLayout: "fixed",
|
|
15
15
|
width: "100%",
|
|
16
16
|
"& th": {
|
|
@@ -43,7 +43,6 @@ export function GenericTableView(props) {
|
|
|
43
43
|
},
|
|
44
44
|
"& td": {
|
|
45
45
|
display: "grid",
|
|
46
|
-
gridTemplateColumns: "0.5fr 0.5fr",
|
|
47
46
|
borderTop: "none",
|
|
48
47
|
padding: "0",
|
|
49
48
|
marginBottom: "var(--sl-spacing-medium)",
|
|
@@ -84,9 +83,8 @@ export function GenericTableView(props) {
|
|
|
84
83
|
};
|
|
85
84
|
const sheet = createStyleSheet(style);
|
|
86
85
|
const styleString = sheet.toString();
|
|
87
|
-
if (show === "empty")
|
|
88
|
-
return
|
|
89
|
-
}
|
|
86
|
+
if (show === "empty")
|
|
87
|
+
return elements.emptyElement;
|
|
90
88
|
return (h("div", null,
|
|
91
89
|
h("style", { type: "text/css" }, styleString),
|
|
92
90
|
h("table", { class: sheet.classes.Table },
|
|
@@ -98,7 +96,10 @@ export function GenericTableView(props) {
|
|
|
98
96
|
return (h("tr", { style: {
|
|
99
97
|
borderTop: `${!data.textOverrides.showLabels && i === 0 ? "none" : ""}`,
|
|
100
98
|
}, part: "table-row" }, row.map((cell, j) => {
|
|
101
|
-
return (h("td", { class: (hiddenCols === null || hiddenCols === void 0 ? void 0 : hiddenCols.includes(j)) ? "hidden" : "", "data-label": columns[j] + ":"
|
|
99
|
+
return (h("td", { class: (hiddenCols === null || hiddenCols === void 0 ? void 0 : hiddenCols.includes(j)) ? "hidden" : "", "data-label": columns[j] + ":", style: {
|
|
100
|
+
gridTemplateColumns: (hiddenCols === null || hiddenCols === void 0 ? void 0 : hiddenCols.includes(j)) ? "1fr"
|
|
101
|
+
: "0.5fr 0.5fr",
|
|
102
|
+
} }, cell));
|
|
102
103
|
})));
|
|
103
104
|
})))),
|
|
104
105
|
h("div", { class: sheet.classes.ButtonContainer, part: states.namespace + "-button-wrapper" },
|
|
@@ -9,9 +9,9 @@ function GenericTableView(props) {
|
|
|
9
9
|
const hiddenCols = data.hiddenColumns && data.hiddenColumns.split(",").map(Number);
|
|
10
10
|
const mobile = "@media (max-width: " + data.mdBreakpoint + "px)";
|
|
11
11
|
const tablet = `@media (min-width: ${Boolean(rows.length < 2) ? data.mdBreakpoint : data.smBreakpoint}px) and (max-width: ${data.mdBreakpoint}px)`;
|
|
12
|
+
// Due to mobile media queries being dependant on props, not feasiable to move out of render function
|
|
12
13
|
const style = {
|
|
13
14
|
Table: {
|
|
14
|
-
// borderCollapse: "collapse",
|
|
15
15
|
tableLayout: "fixed",
|
|
16
16
|
width: "100%",
|
|
17
17
|
"& th": {
|
|
@@ -44,7 +44,6 @@ function GenericTableView(props) {
|
|
|
44
44
|
},
|
|
45
45
|
"& td": {
|
|
46
46
|
display: "grid",
|
|
47
|
-
gridTemplateColumns: "0.5fr 0.5fr",
|
|
48
47
|
borderTop: "none",
|
|
49
48
|
padding: "0",
|
|
50
49
|
marginBottom: "var(--sl-spacing-medium)",
|
|
@@ -85,9 +84,8 @@ function GenericTableView(props) {
|
|
|
85
84
|
};
|
|
86
85
|
const sheet = createStyleSheet(style);
|
|
87
86
|
const styleString = sheet.toString();
|
|
88
|
-
if (show === "empty")
|
|
89
|
-
return
|
|
90
|
-
}
|
|
87
|
+
if (show === "empty")
|
|
88
|
+
return elements.emptyElement;
|
|
91
89
|
return (h("div", null,
|
|
92
90
|
h("style", { type: "text/css" }, styleString),
|
|
93
91
|
h("table", { class: sheet.classes.Table },
|
|
@@ -99,7 +97,10 @@ function GenericTableView(props) {
|
|
|
99
97
|
return (h("tr", { style: {
|
|
100
98
|
borderTop: `${!data.textOverrides.showLabels && i === 0 ? "none" : ""}`,
|
|
101
99
|
}, part: "table-row" }, row.map((cell, j) => {
|
|
102
|
-
return (h("td", { class: (hiddenCols === null || hiddenCols === void 0 ? void 0 : hiddenCols.includes(j)) ? "hidden" : "", "data-label": columns[j] + ":"
|
|
100
|
+
return (h("td", { class: (hiddenCols === null || hiddenCols === void 0 ? void 0 : hiddenCols.includes(j)) ? "hidden" : "", "data-label": columns[j] + ":", style: {
|
|
101
|
+
gridTemplateColumns: (hiddenCols === null || hiddenCols === void 0 ? void 0 : hiddenCols.includes(j)) ? "1fr"
|
|
102
|
+
: "0.5fr 0.5fr",
|
|
103
|
+
} }, cell));
|
|
103
104
|
})));
|
|
104
105
|
})))),
|
|
105
106
|
h("div", { class: sheet.classes.ButtonContainer, part: states.namespace + "-button-wrapper" },
|